summaryrefslogtreecommitdiffstats
path: root/contrib/binutils
diff options
context:
space:
mode:
authorobrien <obrien@FreeBSD.org>2004-06-16 05:45:41 +0000
committerobrien <obrien@FreeBSD.org>2004-06-16 05:45:41 +0000
commitabfa7c9435b930b7b0628c3d5aecb3d2bd2939ae (patch)
tree1b1eca723e1299baef96baf728843d50abdf24a8 /contrib/binutils
parented2b7f732a9e0add59e9276fb35caeac694ca2c7 (diff)
parent2504df11e1275f63f4c53377bf91eee996360cb5 (diff)
downloadFreeBSD-src-abfa7c9435b930b7b0628c3d5aecb3d2bd2939ae.zip
FreeBSD-src-abfa7c9435b930b7b0628c3d5aecb3d2bd2939ae.tar.gz
This commit was generated by cvs2svn to compensate for changes in r130561,
which included commits to RCS files with non-trunk default branches.
Diffstat (limited to 'contrib/binutils')
-rw-r--r--contrib/binutils/ChangeLog1516
-rw-r--r--contrib/binutils/MAINTAINERS24
-rw-r--r--contrib/binutils/Makefile.def210
-rw-r--r--contrib/binutils/Makefile.in25105
-rw-r--r--contrib/binutils/Makefile.tpl1435
-rw-r--r--contrib/binutils/README-maintainer-mode2
-rw-r--r--contrib/binutils/bfd/ChangeLog5639
-rw-r--r--contrib/binutils/bfd/ChangeLog-000116
-rw-r--r--contrib/binutils/bfd/ChangeLog-020311405
-rw-r--r--contrib/binutils/bfd/Makefile.am257
-rw-r--r--contrib/binutils/bfd/Makefile.in282
-rw-r--r--contrib/binutils/bfd/acinclude.m416
-rw-r--r--contrib/binutils/bfd/aclocal.m471
-rw-r--r--contrib/binutils/bfd/aout-arm.c48
-rw-r--r--contrib/binutils/bfd/aout-encap.c7
-rw-r--r--contrib/binutils/bfd/aout-target.h38
-rw-r--r--contrib/binutils/bfd/aoutf1.h55
-rw-r--r--contrib/binutils/bfd/aoutx.h985
-rw-r--r--contrib/binutils/bfd/archive.c624
-rw-r--r--contrib/binutils/bfd/archive64.c84
-rw-r--r--contrib/binutils/bfd/archures.c345
-rw-r--r--contrib/binutils/bfd/bfd-in.h603
-rw-r--r--contrib/binutils/bfd/bfd-in2.h2134
-rw-r--r--contrib/binutils/bfd/bfd.c586
-rw-r--r--contrib/binutils/bfd/bfdio.c442
-rw-r--r--contrib/binutils/bfd/bfdwin.c251
-rw-r--r--contrib/binutils/bfd/binary.c82
-rw-r--r--contrib/binutils/bfd/bout.c1579
-rw-r--r--contrib/binutils/bfd/cache.c78
-rw-r--r--contrib/binutils/bfd/coff-alpha.c297
-rw-r--r--contrib/binutils/bfd/coff-arm.c427
-rw-r--r--contrib/binutils/bfd/coff-aux.c24
-rw-r--r--contrib/binutils/bfd/coff-i386.c69
-rw-r--r--contrib/binutils/bfd/coff-ia64.c10
-rw-r--r--contrib/binutils/bfd/coff-ppc.c874
-rw-r--r--contrib/binutils/bfd/coff-rs6000.c1919
-rw-r--r--contrib/binutils/bfd/coff-sparc.c54
-rw-r--r--contrib/binutils/bfd/coff64-rs6000.c1046
-rw-r--r--contrib/binutils/bfd/coffcode.h1091
-rw-r--r--contrib/binutils/bfd/coffgen.c164
-rw-r--r--contrib/binutils/bfd/cofflink.c985
-rw-r--r--contrib/binutils/bfd/coffswap.h85
-rwxr-xr-xcontrib/binutils/bfd/config.bfd362
-rw-r--r--contrib/binutils/bfd/config.in29
-rwxr-xr-xcontrib/binutils/bfd/configure1501
-rw-r--r--contrib/binutils/bfd/configure.host42
-rw-r--r--contrib/binutils/bfd/configure.in212
-rw-r--r--contrib/binutils/bfd/corefile.c59
-rw-r--r--contrib/binutils/bfd/cpu-alpha.c12
-rw-r--r--contrib/binutils/bfd/cpu-arc.c14
-rw-r--r--contrib/binutils/bfd/cpu-arm.c316
-rw-r--r--contrib/binutils/bfd/cpu-i386.c10
-rw-r--r--contrib/binutils/bfd/cpu-ia64-opc.c25
-rw-r--r--contrib/binutils/bfd/cpu-ia64.c6
-rw-r--r--contrib/binutils/bfd/cpu-powerpc.c48
-rw-r--r--contrib/binutils/bfd/cpu-rs6000.c13
-rw-r--r--contrib/binutils/bfd/cpu-s390.c4
-rw-r--r--contrib/binutils/bfd/cpu-sparc.c20
-rw-r--r--contrib/binutils/bfd/dep-in.sed1
-rw-r--r--contrib/binutils/bfd/doc/ChangeLog552
-rw-r--r--contrib/binutils/bfd/doc/ChangeLog-9103594
-rw-r--r--contrib/binutils/bfd/doc/Makefile.am27
-rw-r--r--contrib/binutils/bfd/doc/Makefile.in37
-rw-r--r--contrib/binutils/bfd/doc/aoutx.texi6
-rw-r--r--contrib/binutils/bfd/doc/archive.texi7
-rw-r--r--contrib/binutils/bfd/doc/archures.texi184
-rw-r--r--contrib/binutils/bfd/doc/bfd.texinfo392
-rw-r--r--contrib/binutils/bfd/doc/bfdint.texi44
-rw-r--r--contrib/binutils/bfd/doc/bfdio.texi41
-rw-r--r--contrib/binutils/bfd/doc/bfdt.texi221
-rw-r--r--contrib/binutils/bfd/doc/bfdwin.texi2
-rw-r--r--contrib/binutils/bfd/doc/cache.texi10
-rw-r--r--contrib/binutils/bfd/doc/chew.c7
-rw-r--r--contrib/binutils/bfd/doc/coffcode.texi51
-rw-r--r--contrib/binutils/bfd/doc/core.texi10
-rw-r--r--contrib/binutils/bfd/doc/fdl.texi366
-rw-r--r--contrib/binutils/bfd/doc/format.texi13
-rw-r--r--contrib/binutils/bfd/doc/hash.texi12
-rw-r--r--contrib/binutils/bfd/doc/init.texi2
-rw-r--r--contrib/binutils/bfd/doc/libbfd.texi126
-rw-r--r--contrib/binutils/bfd/doc/linker.texi12
-rw-r--r--contrib/binutils/bfd/doc/mmo.texi365
-rw-r--r--contrib/binutils/bfd/doc/opncls.texi188
-rw-r--r--contrib/binutils/bfd/doc/reloc.texi443
-rw-r--r--contrib/binutils/bfd/doc/section.texi134
-rw-r--r--contrib/binutils/bfd/doc/syms.texi85
-rw-r--r--contrib/binutils/bfd/doc/targets.texi364
-rw-r--r--contrib/binutils/bfd/dwarf1.c78
-rw-r--r--contrib/binutils/bfd/dwarf2.c715
-rw-r--r--contrib/binutils/bfd/ecoff.c521
-rw-r--r--contrib/binutils/bfd/ecofflink.c492
-rw-r--r--contrib/binutils/bfd/ecoffswap.h237
-rw-r--r--contrib/binutils/bfd/efi-app-ia32.c4
-rw-r--r--contrib/binutils/bfd/efi-app-ia64.c4
-rw-r--r--contrib/binutils/bfd/elf-bfd.h1374
-rw-r--r--contrib/binutils/bfd/elf-eh-frame.c549
-rw-r--r--contrib/binutils/bfd/elf-strtab.c279
-rw-r--r--contrib/binutils/bfd/elf32-arc.c43
-rw-r--r--contrib/binutils/bfd/elf32-arm.h1847
-rw-r--r--contrib/binutils/bfd/elf32-gen.c25
-rw-r--r--contrib/binutils/bfd/elf32-ppc.c6085
-rw-r--r--contrib/binutils/bfd/elf32-s390.c2138
-rw-r--r--contrib/binutils/bfd/elf32-sparc.c2594
-rw-r--r--contrib/binutils/bfd/elf64-gen.c25
-rw-r--r--contrib/binutils/bfd/elf64-ppc.c6637
-rw-r--r--contrib/binutils/bfd/elf64-ppc.h36
-rw-r--r--contrib/binutils/bfd/elf64-s390.c2164
-rw-r--r--contrib/binutils/bfd/elf64-sparc.c763
-rw-r--r--contrib/binutils/bfd/elf64-x86-64.c1456
-rw-r--r--contrib/binutils/bfd/elfarm-nabi.c238
-rw-r--r--contrib/binutils/bfd/elfarm-oabi.c126
-rw-r--r--contrib/binutils/bfd/elfcode.h810
-rw-r--r--contrib/binutils/bfd/elfcore.h148
-rw-r--r--contrib/binutils/bfd/elflink.c8726
-rw-r--r--contrib/binutils/bfd/elfxx-ia64.c2407
-rw-r--r--contrib/binutils/bfd/elfxx-target.h149
-rw-r--r--contrib/binutils/bfd/format.c158
-rw-r--r--contrib/binutils/bfd/gen-aout.c2
-rw-r--r--contrib/binutils/bfd/genlink.h14
-rw-r--r--contrib/binutils/bfd/hash.c55
-rw-r--r--contrib/binutils/bfd/i386aout.c11
-rw-r--r--contrib/binutils/bfd/i386linux.c105
-rw-r--r--contrib/binutils/bfd/ieee.c1198
-rw-r--r--contrib/binutils/bfd/ihex.c136
-rw-r--r--contrib/binutils/bfd/init.c6
-rw-r--r--contrib/binutils/bfd/libaout.h211
-rw-r--r--contrib/binutils/bfd/libbfd-in.h502
-rw-r--r--contrib/binutils/bfd/libbfd.c1153
-rw-r--r--contrib/binutils/bfd/libbfd.h773
-rw-r--r--contrib/binutils/bfd/libcoff-in.h98
-rw-r--r--contrib/binutils/bfd/libcoff.h147
-rw-r--r--contrib/binutils/bfd/libecoff.h84
-rw-r--r--contrib/binutils/bfd/libieee.h12
-rw-r--r--contrib/binutils/bfd/libpei.h52
-rw-r--r--contrib/binutils/bfd/linker.c945
-rw-r--r--contrib/binutils/bfd/merge.c413
-rw-r--r--contrib/binutils/bfd/netbsd-core.c105
-rw-r--r--contrib/binutils/bfd/netbsd.h8
-rw-r--r--contrib/binutils/bfd/opncls.c742
-rw-r--r--contrib/binutils/bfd/osf-core.c64
-rw-r--r--contrib/binutils/bfd/pe-arm.c4
-rw-r--r--contrib/binutils/bfd/pe-i386.c2
-rw-r--r--contrib/binutils/bfd/peXXigen.c249
-rw-r--r--contrib/binutils/bfd/peicode.h156
-rw-r--r--contrib/binutils/bfd/po/BLD-POTFILES.in1
-rw-r--r--contrib/binutils/bfd/po/Make-in24
-rw-r--r--contrib/binutils/bfd/po/SRC-POTFILES.in101
-rw-r--r--contrib/binutils/bfd/po/bfd.pot1722
-rw-r--r--contrib/binutils/bfd/ppcboot.c48
-rw-r--r--contrib/binutils/bfd/ptrace-core.c78
-rw-r--r--contrib/binutils/bfd/reloc.c977
-rw-r--r--contrib/binutils/bfd/reloc16.c105
-rw-r--r--contrib/binutils/bfd/rs6000-core.c26
-rw-r--r--contrib/binutils/bfd/sco5-core.c146
-rw-r--r--contrib/binutils/bfd/section.c332
-rw-r--r--contrib/binutils/bfd/simple.c257
-rw-r--r--contrib/binutils/bfd/sparclinux.c448
-rw-r--r--contrib/binutils/bfd/sparcnetbsd.c3
-rw-r--r--contrib/binutils/bfd/srec.c189
-rw-r--r--contrib/binutils/bfd/stabs.c178
-rw-r--r--contrib/binutils/bfd/sunos.c372
-rw-r--r--contrib/binutils/bfd/syms.c325
-rw-r--r--contrib/binutils/bfd/sysdep.h2
-rw-r--r--contrib/binutils/bfd/targets.c509
-rw-r--r--contrib/binutils/bfd/tekhex.c76
-rw-r--r--contrib/binutils/bfd/trad-core.c92
-rw-r--r--contrib/binutils/bfd/version.h4
-rw-r--r--contrib/binutils/bfd/xcoff-target.h22
-rw-r--r--contrib/binutils/bfd/xcofflink.c867
-rw-r--r--contrib/binutils/binutils/ChangeLog2932
-rw-r--r--contrib/binutils/binutils/ChangeLog-00012060
-rw-r--r--contrib/binutils/binutils/ChangeLog-02032181
-rw-r--r--contrib/binutils/binutils/ChangeLog-91974
-rw-r--r--contrib/binutils/binutils/ChangeLog-98992
-rw-r--r--contrib/binutils/binutils/MAINTAINERS60
-rw-r--r--contrib/binutils/binutils/Makefile.am69
-rw-r--r--contrib/binutils/binutils/Makefile.in81
-rw-r--r--contrib/binutils/binutils/NEWS51
-rw-r--r--contrib/binutils/binutils/README77
-rw-r--r--contrib/binutils/binutils/acinclude.m42
-rw-r--r--contrib/binutils/binutils/aclocal.m418
-rw-r--r--contrib/binutils/binutils/addr2line.c71
-rw-r--r--contrib/binutils/binutils/ar.c382
-rw-r--r--contrib/binutils/binutils/arlex.l6
-rw-r--r--contrib/binutils/binutils/arparse.y10
-rw-r--r--contrib/binutils/binutils/arsup.c70
-rw-r--r--contrib/binutils/binutils/arsup.h36
-rw-r--r--contrib/binutils/binutils/binemul.c79
-rw-r--r--contrib/binutils/binutils/binemul.h32
-rw-r--r--contrib/binutils/binutils/bucomm.c268
-rw-r--r--contrib/binutils/binutils/bucomm.h70
-rw-r--r--contrib/binutils/binutils/budbg.h26
-rw-r--r--contrib/binutils/binutils/budemang.c6
-rw-r--r--contrib/binutils/binutils/budemang.h4
-rw-r--r--contrib/binutils/binutils/coffdump.c68
-rw-r--r--contrib/binutils/binutils/coffgrok.c81
-rw-r--r--contrib/binutils/binutils/coffgrok.h2
-rw-r--r--contrib/binutils/binutils/config.in12
-rwxr-xr-xcontrib/binutils/binutils/configure993
-rw-r--r--contrib/binutils/binutils/configure.in34
-rw-r--r--contrib/binutils/binutils/cxxfilt.c291
-rw-r--r--contrib/binutils/binutils/debug.c907
-rw-r--r--contrib/binutils/binutils/debug.h312
-rw-r--r--contrib/binutils/binutils/deflex.l36
-rw-r--r--contrib/binutils/binutils/dep-in.sed1
-rw-r--r--contrib/binutils/binutils/dlltool.c833
-rw-r--r--contrib/binutils/binutils/dlltool.h32
-rw-r--r--contrib/binutils/binutils/dllwrap.c63
-rw-r--r--contrib/binutils/binutils/doc/Makefile.am28
-rw-r--r--contrib/binutils/binutils/doc/Makefile.in31
-rw-r--r--contrib/binutils/binutils/doc/addr2line.111
-rw-r--r--contrib/binutils/binutils/doc/ar.113
-rw-r--r--contrib/binutils/binutils/doc/binutils.texi932
-rw-r--r--contrib/binutils/binutils/doc/cxxfilt.man53
-rw-r--r--contrib/binutils/binutils/doc/dlltool.127
-rw-r--r--contrib/binutils/binutils/doc/fdl.texi368
-rw-r--r--contrib/binutils/binutils/doc/nm.117
-rw-r--r--contrib/binutils/binutils/doc/objcopy.1161
-rw-r--r--contrib/binutils/binutils/doc/objdump.1127
-rw-r--r--contrib/binutils/binutils/doc/ranlib.111
-rw-r--r--contrib/binutils/binutils/doc/readelf.153
-rw-r--r--contrib/binutils/binutils/doc/size.113
-rw-r--r--contrib/binutils/binutils/doc/strings.121
-rw-r--r--contrib/binutils/binutils/doc/strip.1114
-rw-r--r--contrib/binutils/binutils/filemode.c23
-rw-r--r--contrib/binutils/binutils/ieee.c2297
-rw-r--r--contrib/binutils/binutils/objcopy.c1437
-rw-r--r--contrib/binutils/binutils/objdump.c2304
-rw-r--r--contrib/binutils/binutils/po/Make-in24
-rw-r--r--contrib/binutils/binutils/po/POTFILES.in1
-rw-r--r--contrib/binutils/binutils/po/binutils.pot1583
-rw-r--r--contrib/binutils/binutils/prdbg.c1876
-rw-r--r--contrib/binutils/binutils/rclex.c351
-rw-r--r--contrib/binutils/binutils/rclex.l34
-rw-r--r--contrib/binutils/binutils/rdcoff.c226
-rw-r--r--contrib/binutils/binutils/rddbg.c134
-rw-r--r--contrib/binutils/binutils/readelf.c4594
-rw-r--r--contrib/binutils/binutils/rename.c35
-rw-r--r--contrib/binutils/binutils/resbin.c274
-rw-r--r--contrib/binutils/binutils/rescoff.c63
-rw-r--r--contrib/binutils/binutils/resrc.c397
-rw-r--r--contrib/binutils/binutils/size.c105
-rw-r--r--contrib/binutils/binutils/srconv.c286
-rw-r--r--contrib/binutils/binutils/stabs.c1694
-rw-r--r--contrib/binutils/binutils/sysdump.c127
-rw-r--r--contrib/binutils/binutils/unwind-ia64.c219
-rw-r--r--contrib/binutils/binutils/unwind-ia64.h14
-rw-r--r--contrib/binutils/binutils/version.c32
-rw-r--r--contrib/binutils/binutils/wrstabs.c787
-rw-r--r--contrib/binutils/config-ml.in134
-rwxr-xr-xcontrib/binutils/config.guess351
-rw-r--r--contrib/binutils/config.if86
-rwxr-xr-xcontrib/binutils/config.sub218
-rwxr-xr-xcontrib/binutils/configure5441
-rw-r--r--contrib/binutils/configure.in1607
-rw-r--r--contrib/binutils/gas/CONTRIBUTORS5
-rw-r--r--contrib/binutils/gas/ChangeLog3098
-rw-r--r--contrib/binutils/gas/ChangeLog-02037519
-rw-r--r--contrib/binutils/gas/ChangeLog-92956
-rw-r--r--contrib/binutils/gas/Makefile.am351
-rw-r--r--contrib/binutils/gas/Makefile.in1200
-rw-r--r--contrib/binutils/gas/NEWS490
-rw-r--r--contrib/binutils/gas/README43
-rw-r--r--contrib/binutils/gas/acinclude.m46
-rw-r--r--contrib/binutils/gas/aclocal.m41142
-rw-r--r--contrib/binutils/gas/app.c224
-rw-r--r--contrib/binutils/gas/as.c569
-rw-r--r--contrib/binutils/gas/as.h140
-rw-r--r--contrib/binutils/gas/atof-generic.c20
-rw-r--r--contrib/binutils/gas/bignum-copy.c9
-rw-r--r--contrib/binutils/gas/bignum.h4
-rw-r--r--contrib/binutils/gas/bit_fix.h2
-rw-r--r--contrib/binutils/gas/cgen.c87
-rw-r--r--contrib/binutils/gas/cgen.h53
-rw-r--r--contrib/binutils/gas/cond.c94
-rw-r--r--contrib/binutils/gas/config.in15
-rw-r--r--contrib/binutils/gas/config/obj-aout.c79
-rw-r--r--contrib/binutils/gas/config/obj-aout.h16
-rw-r--r--contrib/binutils/gas/config/obj-coff.c33
-rw-r--r--contrib/binutils/gas/config/obj-coff.h68
-rw-r--r--contrib/binutils/gas/config/obj-ecoff.c82
-rw-r--r--contrib/binutils/gas/config/obj-ecoff.h6
-rw-r--r--contrib/binutils/gas/config/obj-elf.c765
-rw-r--r--contrib/binutils/gas/config/obj-elf.h59
-rw-r--r--contrib/binutils/gas/config/obj-ieee.c8
-rw-r--r--contrib/binutils/gas/config/obj-ieee.h9
-rw-r--r--contrib/binutils/gas/config/obj-multi.h7
-rw-r--r--contrib/binutils/gas/config/tc-alpha.c670
-rw-r--r--contrib/binutils/gas/config/tc-alpha.h77
-rw-r--r--contrib/binutils/gas/config/tc-arc.c80
-rw-r--r--contrib/binutils/gas/config/tc-arc.h10
-rw-r--r--contrib/binutils/gas/config/tc-arm.c3615
-rw-r--r--contrib/binutils/gas/config/tc-arm.h209
-rw-r--r--contrib/binutils/gas/config/tc-ia64.c1084
-rw-r--r--contrib/binutils/gas/config/tc-ia64.h73
-rw-r--r--contrib/binutils/gas/config/tc-ppc.c1110
-rw-r--r--contrib/binutils/gas/config/tc-ppc.h82
-rw-r--r--contrib/binutils/gas/config/tc-s390.c579
-rw-r--r--contrib/binutils/gas/config/tc-s390.h61
-rw-r--r--contrib/binutils/gas/config/tc-sparc.c275
-rw-r--r--contrib/binutils/gas/config/tc-sparc.h97
-rw-r--r--contrib/binutils/gas/config/te-generic.h2
-rw-r--r--contrib/binutils/gas/config/te-pe.h2
-rw-r--r--contrib/binutils/gas/config/te-ppcnw.h2
-rw-r--r--contrib/binutils/gas/dep-in.sed4
-rw-r--r--contrib/binutils/gas/depend.c21
-rw-r--r--contrib/binutils/gas/doc/Makefile.am18
-rw-r--r--contrib/binutils/gas/doc/Makefile.in624
-rw-r--r--contrib/binutils/gas/doc/all.texi5
-rw-r--r--contrib/binutils/gas/doc/as.texinfo935
-rw-r--r--contrib/binutils/gas/doc/c-alpha.texi22
-rw-r--r--contrib/binutils/gas/doc/c-arm.texi88
-rw-r--r--contrib/binutils/gas/doc/c-i386.texi5
-rw-r--r--contrib/binutils/gas/doc/c-ia64.texi14
-rw-r--r--contrib/binutils/gas/doc/c-ppc.texi22
-rw-r--r--contrib/binutils/gas/doc/c-sh.texi48
-rw-r--r--contrib/binutils/gas/doc/c-sparc.texi2
-rw-r--r--contrib/binutils/gas/doc/gasver.texi1
-rw-r--r--contrib/binutils/gas/doc/h8.texi4
-rw-r--r--contrib/binutils/gas/doc/internals.texi163
-rw-r--r--contrib/binutils/gas/dw2gencfi.c1042
-rw-r--r--contrib/binutils/gas/dw2gencfi.h52
-rw-r--r--contrib/binutils/gas/dwarf2dbg.c507
-rw-r--r--contrib/binutils/gas/dwarf2dbg.h36
-rw-r--r--contrib/binutils/gas/ecoff.c400
-rw-r--r--contrib/binutils/gas/ecoff.h64
-rw-r--r--contrib/binutils/gas/ehopt.c22
-rw-r--r--contrib/binutils/gas/emul.h10
-rw-r--r--contrib/binutils/gas/expr.c181
-rw-r--r--contrib/binutils/gas/expr.h43
-rw-r--r--contrib/binutils/gas/flonum-copy.c4
-rw-r--r--contrib/binutils/gas/flonum-mult.c6
-rw-r--r--contrib/binutils/gas/flonum.h16
-rw-r--r--contrib/binutils/gas/frags.c109
-rw-r--r--contrib/binutils/gas/frags.h63
-rw-r--r--contrib/binutils/gas/hash.c59
-rw-r--r--contrib/binutils/gas/hash.h28
-rw-r--r--contrib/binutils/gas/input-file.c74
-rw-r--r--contrib/binutils/gas/input-file.h18
-rw-r--r--contrib/binutils/gas/input-scrub.c55
-rw-r--r--contrib/binutils/gas/itbl-ops.c40
-rw-r--r--contrib/binutils/gas/itbl-ops.h33
-rw-r--r--contrib/binutils/gas/listing.c280
-rw-r--r--contrib/binutils/gas/listing.h30
-rw-r--r--contrib/binutils/gas/macro.c176
-rw-r--r--contrib/binutils/gas/macro.h50
-rw-r--r--contrib/binutils/gas/messages.c126
-rw-r--r--contrib/binutils/gas/obj.h77
-rw-r--r--contrib/binutils/gas/output-file.c36
-rw-r--r--contrib/binutils/gas/output-file.h6
-rw-r--r--contrib/binutils/gas/po/Make-in24
-rw-r--r--contrib/binutils/gas/po/POTFILES.in18
-rw-r--r--contrib/binutils/gas/po/gas.pot6032
-rw-r--r--contrib/binutils/gas/read.c971
-rw-r--r--contrib/binutils/gas/read.h188
-rw-r--r--contrib/binutils/gas/sb.c61
-rw-r--r--contrib/binutils/gas/sb.h32
-rw-r--r--contrib/binutils/gas/stabs.c51
-rw-r--r--contrib/binutils/gas/subsegs.c62
-rw-r--r--contrib/binutils/gas/subsegs.h6
-rw-r--r--contrib/binutils/gas/symbols.c537
-rw-r--r--contrib/binutils/gas/symbols.h198
-rw-r--r--contrib/binutils/gas/tc.h56
-rw-r--r--contrib/binutils/gas/write.c995
-rw-r--r--contrib/binutils/gas/write.h50
-rw-r--r--contrib/binutils/include/ChangeLog692
-rw-r--r--contrib/binutils/include/ansidecl.h41
-rw-r--r--contrib/binutils/include/aout/ChangeLog80
-rw-r--r--contrib/binutils/include/aout/aout64.h187
-rw-r--r--contrib/binutils/include/aout/stab.def29
-rw-r--r--contrib/binutils/include/bfdlink.h421
-rw-r--r--contrib/binutils/include/coff/ChangeLog1089
-rw-r--r--contrib/binutils/include/coff/arm.h2
-rw-r--r--contrib/binutils/include/coff/ecoff.h67
-rw-r--r--contrib/binutils/include/coff/internal.h10
-rw-r--r--contrib/binutils/include/coff/pe.h52
-rw-r--r--contrib/binutils/include/coff/sh.h4
-rw-r--r--contrib/binutils/include/coff/ti.h45
-rw-r--r--contrib/binutils/include/demangle.h376
-rw-r--r--contrib/binutils/include/dis-asm.h241
-rw-r--r--contrib/binutils/include/elf/ChangeLog1557
-rw-r--r--contrib/binutils/include/elf/ChangeLog-91031914
-rw-r--r--contrib/binutils/include/elf/arm.h4
-rw-r--r--contrib/binutils/include/elf/common.h418
-rw-r--r--contrib/binutils/include/elf/dwarf2.h116
-rw-r--r--contrib/binutils/include/elf/external.h15
-rw-r--r--contrib/binutils/include/elf/frv.h19
-rw-r--r--contrib/binutils/include/elf/h8.h6
-rw-r--r--contrib/binutils/include/elf/i370.h26
-rw-r--r--contrib/binutils/include/elf/ia64.h64
-rw-r--r--contrib/binutils/include/elf/internal.h73
-rw-r--r--contrib/binutils/include/elf/ip2k.h62
-rw-r--r--contrib/binutils/include/elf/iq2000.h58
-rw-r--r--contrib/binutils/include/elf/m32r.h101
-rw-r--r--contrib/binutils/include/elf/m68hc11.h55
-rw-r--r--contrib/binutils/include/elf/mips.h26
-rw-r--r--contrib/binutils/include/elf/mmix.h19
-rw-r--r--contrib/binutils/include/elf/mn10300.h17
-rw-r--r--contrib/binutils/include/elf/msp430.h56
-rw-r--r--contrib/binutils/include/elf/ppc.h236
-rw-r--r--contrib/binutils/include/elf/ppc64.h156
-rw-r--r--contrib/binutils/include/elf/reloc-macros.h23
-rw-r--r--contrib/binutils/include/elf/s390.h54
-rw-r--r--contrib/binutils/include/elf/sh.h146
-rw-r--r--contrib/binutils/include/elf/sparc.h31
-rw-r--r--contrib/binutils/include/elf/v850.h60
-rw-r--r--contrib/binutils/include/elf/x86-64.h24
-rw-r--r--contrib/binutils/include/elf/xstormy16.h6
-rw-r--r--contrib/binutils/include/elf/xtensa.h88
-rw-r--r--contrib/binutils/include/fibheap.h5
-rw-r--r--contrib/binutils/include/floatformat.h22
-rw-r--r--contrib/binutils/include/getopt.h144
-rw-r--r--contrib/binutils/include/hashtab.h31
-rw-r--r--contrib/binutils/include/libiberty.h24
-rw-r--r--contrib/binutils/include/obstack.h40
-rw-r--r--contrib/binutils/include/opcode/ChangeLog2776
-rw-r--r--contrib/binutils/include/opcode/ChangeLog-91033102
-rw-r--r--contrib/binutils/include/opcode/alpha.h7
-rw-r--r--contrib/binutils/include/opcode/arc.h323
-rw-r--r--contrib/binutils/include/opcode/cgen.h199
-rw-r--r--contrib/binutils/include/opcode/convex.h1707
-rw-r--r--contrib/binutils/include/opcode/i386.h39
-rw-r--r--contrib/binutils/include/opcode/ia64.h13
-rw-r--r--contrib/binutils/include/opcode/np1.h422
-rw-r--r--contrib/binutils/include/opcode/pn.h282
-rw-r--r--contrib/binutils/include/opcode/ppc.h93
-rw-r--r--contrib/binutils/include/opcode/s390.h19
-rw-r--r--contrib/binutils/include/opcode/sparc.h23
-rw-r--r--contrib/binutils/include/partition.h4
-rw-r--r--contrib/binutils/include/safe-ctype.h18
-rw-r--r--contrib/binutils/include/splay-tree.h25
-rwxr-xr-xcontrib/binutils/install-sh167
-rw-r--r--contrib/binutils/ld/ChangeLog4975
-rw-r--r--contrib/binutils/ld/ChangeLog-00013376
-rw-r--r--contrib/binutils/ld/ChangeLog-02033580
-rw-r--r--contrib/binutils/ld/ChangeLog-91972
-rw-r--r--contrib/binutils/ld/Makefile.am542
-rw-r--r--contrib/binutils/ld/NEWS45
-rw-r--r--contrib/binutils/ld/README3
-rw-r--r--contrib/binutils/ld/aclocal.m418
-rw-r--r--contrib/binutils/ld/config.in9
-rwxr-xr-xcontrib/binutils/ld/configure972
-rw-r--r--contrib/binutils/ld/configure.in44
-rw-r--r--contrib/binutils/ld/deffile.h57
-rw-r--r--contrib/binutils/ld/deffilep.y384
-rw-r--r--contrib/binutils/ld/dep-in.sed1
-rw-r--r--contrib/binutils/ld/emulparams/arcelf.sh11
-rw-r--r--contrib/binutils/ld/emulparams/armelf.sh4
-rw-r--r--contrib/binutils/ld/emulparams/armelf_linux.sh5
-rw-r--r--contrib/binutils/ld/emulparams/armelf_oabi.sh3
-rw-r--r--contrib/binutils/ld/emulparams/armpe.sh4
-rw-r--r--contrib/binutils/ld/emulparams/elf32_sparc.sh1
-rw-r--r--contrib/binutils/ld/emulparams/elf32b4300.sh10
-rw-r--r--contrib/binutils/ld/emulparams/elf32bmip.sh37
-rwxr-xr-xcontrib/binutils/ld/emulparams/elf32bmipn32.sh22
-rwxr-xr-xcontrib/binutils/ld/emulparams/elf32bsmip.sh3
-rw-r--r--contrib/binutils/ld/emulparams/elf32ebmip.sh2
-rw-r--r--contrib/binutils/ld/emulparams/elf32elmip.sh2
-rw-r--r--contrib/binutils/ld/emulparams/elf32l4300.sh4
-rw-r--r--contrib/binutils/ld/emulparams/elf32lmip.sh7
-rwxr-xr-xcontrib/binutils/ld/emulparams/elf32lsmip.sh2
-rw-r--r--contrib/binutils/ld/emulparams/elf32ppc.sh29
-rw-r--r--contrib/binutils/ld/emulparams/elf64_ia64.sh18
-rw-r--r--contrib/binutils/ld/emulparams/elf64_ia64_fbsd.sh2
-rw-r--r--contrib/binutils/ld/emulparams/elf64_s390.sh35
-rw-r--r--contrib/binutils/ld/emulparams/elf64_sparc.sh45
-rwxr-xr-xcontrib/binutils/ld/emulparams/elf64bmip.sh23
-rw-r--r--contrib/binutils/ld/emulparams/elf64ppc.sh44
-rw-r--r--contrib/binutils/ld/emulparams/elf_i386.sh1
-rw-r--r--contrib/binutils/ld/emulparams/elf_s390.sh2
-rw-r--r--contrib/binutils/ld/emulparams/elf_x86_64.sh34
-rw-r--r--contrib/binutils/ld/emulparams/sh.sh8
-rw-r--r--contrib/binutils/ld/emulparams/shl.sh2
-rwxr-xr-xcontrib/binutils/ld/emulparams/shlelf.sh2
-rw-r--r--contrib/binutils/ld/emulparams/vanilla.sh4
-rw-r--r--contrib/binutils/ld/emulparams/vsta.sh8
-rw-r--r--contrib/binutils/ld/emultempl/alphaelf.em80
-rw-r--r--contrib/binutils/ld/emultempl/armcoff.em134
-rw-r--r--contrib/binutils/ld/emultempl/armelf.em66
-rw-r--r--contrib/binutils/ld/emultempl/armelf_oabi.em54
-rw-r--r--contrib/binutils/ld/emultempl/generic.em46
-rw-r--r--contrib/binutils/ld/emultempl/ia64elf.em62
-rw-r--r--contrib/binutils/ld/emultempl/linux.em90
-rw-r--r--contrib/binutils/ld/emultempl/needrelax.em10
-rw-r--r--contrib/binutils/ld/emultempl/netbsd.em13
-rw-r--r--contrib/binutils/ld/emultempl/pe.em982
-rw-r--r--contrib/binutils/ld/emultempl/ppc64elf.em279
-rw-r--r--contrib/binutils/ld/emultempl/sunos.em185
-rw-r--r--contrib/binutils/ld/emultempl/ticoff.em101
-rw-r--r--contrib/binutils/ld/emultempl/vanilla.em19
-rw-r--r--contrib/binutils/ld/fdl.texi367
-rw-r--r--contrib/binutils/ld/gen-doc.texi5
-rwxr-xr-xcontrib/binutils/ld/genscripts.sh231
-rw-r--r--contrib/binutils/ld/h8-doc.texi2
-rw-r--r--contrib/binutils/ld/ld.h103
-rw-r--r--contrib/binutils/ld/ld.texinfo1465
-rw-r--r--contrib/binutils/ld/ldcref.c152
-rw-r--r--contrib/binutils/ld/ldctor.c69
-rw-r--r--contrib/binutils/ld/ldctor.h13
-rw-r--r--contrib/binutils/ld/ldemul.c136
-rw-r--r--contrib/binutils/ld/ldemul.h173
-rw-r--r--contrib/binutils/ld/ldexp.c406
-rw-r--r--contrib/binutils/ld/ldexp.h89
-rw-r--r--contrib/binutils/ld/ldfile.c279
-rw-r--r--contrib/binutils/ld/ldfile.h42
-rw-r--r--contrib/binutils/ld/ldgram.y168
-rw-r--r--contrib/binutils/ld/ldint.texinfo4
-rw-r--r--contrib/binutils/ld/ldlang.c2224
-rw-r--r--contrib/binutils/ld/ldlang.h405
-rw-r--r--contrib/binutils/ld/ldlex.h34
-rw-r--r--contrib/binutils/ld/ldlex.l140
-rw-r--r--contrib/binutils/ld/ldmain.c781
-rw-r--r--contrib/binutils/ld/ldmain.h23
-rw-r--r--contrib/binutils/ld/ldmisc.c244
-rw-r--r--contrib/binutils/ld/ldmisc.h27
-rw-r--r--contrib/binutils/ld/ldver.c4
-rw-r--r--contrib/binutils/ld/ldver.h4
-rw-r--r--contrib/binutils/ld/ldver.texi1
-rw-r--r--contrib/binutils/ld/ldwrite.c133
-rw-r--r--contrib/binutils/ld/ldwrite.h7
-rw-r--r--contrib/binutils/ld/lexsup.c563
-rw-r--r--contrib/binutils/ld/mri.c126
-rw-r--r--contrib/binutils/ld/mri.h28
-rw-r--r--contrib/binutils/ld/pe-dll.c810
-rw-r--r--contrib/binutils/ld/pe-dll.h42
-rw-r--r--contrib/binutils/ld/scripttempl/armcoff.sc4
-rw-r--r--contrib/binutils/ld/scripttempl/elf.sc27
-rw-r--r--contrib/binutils/ld/scripttempl/pe.sc15
-rw-r--r--contrib/binutils/ld/sysdep.h29
-rw-r--r--contrib/binutils/libiberty/ChangeLog965
-rw-r--r--contrib/binutils/libiberty/Makefile.in841
-rw-r--r--contrib/binutils/libiberty/README5
-rw-r--r--contrib/binutils/libiberty/aclocal.m4122
-rw-r--r--contrib/binutils/libiberty/argv.c6
-rw-r--r--contrib/binutils/libiberty/asprintf.c4
-rw-r--r--contrib/binutils/libiberty/calloc.c3
-rw-r--r--contrib/binutils/libiberty/config.in378
-rw-r--r--contrib/binutils/libiberty/config.table4
-rwxr-xr-xcontrib/binutils/libiberty/configure7991
-rw-r--r--contrib/binutils/libiberty/copysign.c8
-rw-r--r--contrib/binutils/libiberty/cp-demangle.c6842
-rw-r--r--contrib/binutils/libiberty/cp-demangle.h139
-rw-r--r--contrib/binutils/libiberty/cp-demint.c241
-rw-r--r--contrib/binutils/libiberty/cplus-dem.c480
-rw-r--r--contrib/binutils/libiberty/fibheap.c4
-rw-r--r--contrib/binutils/libiberty/floatformat.c303
-rw-r--r--contrib/binutils/libiberty/functions.texi237
-rw-r--r--contrib/binutils/libiberty/getcwd.c2
-rw-r--r--contrib/binutils/libiberty/getopt.c1056
-rw-r--r--contrib/binutils/libiberty/getopt1.c190
-rw-r--r--contrib/binutils/libiberty/getpwd.c3
-rw-r--r--contrib/binutils/libiberty/hashtab.c255
-rw-r--r--contrib/binutils/libiberty/hex.c21
-rw-r--r--contrib/binutils/libiberty/lbasename.c20
-rw-r--r--contrib/binutils/libiberty/libiberty.texi4
-rw-r--r--contrib/binutils/libiberty/lrealpath.c128
-rw-r--r--contrib/binutils/libiberty/maint-tool25
-rw-r--r--contrib/binutils/libiberty/make-relative-prefix.c396
-rw-r--r--contrib/binutils/libiberty/md5.c114
-rw-r--r--contrib/binutils/libiberty/memchr.c2
-rw-r--r--contrib/binutils/libiberty/memcmp.c8
-rw-r--r--contrib/binutils/libiberty/memcpy.c9
-rw-r--r--contrib/binutils/libiberty/memmove.c4
-rw-r--r--contrib/binutils/libiberty/memset.c8
-rw-r--r--contrib/binutils/libiberty/physmem.c305
-rw-r--r--contrib/binutils/libiberty/regex.c118
-rw-r--r--contrib/binutils/libiberty/rename.c5
-rw-r--r--contrib/binutils/libiberty/safe-ctype.c147
-rw-r--r--contrib/binutils/libiberty/sigsetmask.c4
-rw-r--r--contrib/binutils/libiberty/splay-tree.c10
-rw-r--r--contrib/binutils/libiberty/strcasecmp.c2
-rw-r--r--contrib/binutils/libiberty/strdup.c23
-rw-r--r--contrib/binutils/libiberty/strerror.c3
-rw-r--r--contrib/binutils/libiberty/strncasecmp.c2
-rw-r--r--contrib/binutils/libiberty/strncmp.c2
-rw-r--r--contrib/binutils/libiberty/strsignal.c2
-rw-r--r--contrib/binutils/libiberty/strstr.c4
-rw-r--r--contrib/binutils/libiberty/vasprintf.c25
-rw-r--r--contrib/binutils/libiberty/vfprintf.c3
-rw-r--r--contrib/binutils/libiberty/vprintf.c4
-rw-r--r--contrib/binutils/libiberty/vsprintf.c6
-rw-r--r--contrib/binutils/libiberty/xatexit.c2
-rw-r--r--contrib/binutils/libiberty/xmalloc.c2
-rw-r--r--contrib/binutils/libtool.m416
-rw-r--r--contrib/binutils/ltcf-c.sh2
-rw-r--r--contrib/binutils/ltcf-cxx.sh29
-rw-r--r--contrib/binutils/ltcf-gcj.sh8
-rwxr-xr-xcontrib/binutils/ltconfig28
-rw-r--r--contrib/binutils/missing166
-rwxr-xr-xcontrib/binutils/mkinstalldirs113
-rw-r--r--contrib/binutils/opcodes/ChangeLog3001
-rw-r--r--contrib/binutils/opcodes/ChangeLog-00012224
-rw-r--r--contrib/binutils/opcodes/ChangeLog-02032110
-rw-r--r--contrib/binutils/opcodes/Makefile.am231
-rw-r--r--contrib/binutils/opcodes/Makefile.in239
-rw-r--r--contrib/binutils/opcodes/aclocal.m418
-rw-r--r--contrib/binutils/opcodes/alpha-opc.c17
-rw-r--r--contrib/binutils/opcodes/arc-opc.c6
-rw-r--r--contrib/binutils/opcodes/arm-dis.c469
-rw-r--r--contrib/binutils/opcodes/arm-opc.h235
-rw-r--r--contrib/binutils/opcodes/cgen-asm.c94
-rw-r--r--contrib/binutils/opcodes/cgen-asm.in33
-rw-r--r--contrib/binutils/opcodes/cgen-dis.c58
-rw-r--r--contrib/binutils/opcodes/cgen-dis.in108
-rw-r--r--contrib/binutils/opcodes/cgen-ibld.in136
-rw-r--r--contrib/binutils/opcodes/cgen-opc.c129
-rw-r--r--contrib/binutils/opcodes/cgen.sh21
-rw-r--r--contrib/binutils/opcodes/config.in9
-rwxr-xr-xcontrib/binutils/opcodes/configure851
-rw-r--r--contrib/binutils/opcodes/configure.in7
-rw-r--r--contrib/binutils/opcodes/dep-in.sed1
-rw-r--r--contrib/binutils/opcodes/dis-buf.c11
-rw-r--r--contrib/binutils/opcodes/dis-init.c43
-rw-r--r--contrib/binutils/opcodes/disassemble.c58
-rw-r--r--contrib/binutils/opcodes/i386-dis.c736
-rw-r--r--contrib/binutils/opcodes/ia64-asmtab.c11789
-rw-r--r--contrib/binutils/opcodes/ia64-dis.c4
-rw-r--r--contrib/binutils/opcodes/ia64-gen.c1225
-rw-r--r--contrib/binutils/opcodes/ia64-ic.tbl28
-rw-r--r--contrib/binutils/opcodes/ia64-opc-a.c567
-rw-r--r--contrib/binutils/opcodes/ia64-opc-b.c495
-rw-r--r--contrib/binutils/opcodes/ia64-opc-d.c42
-rw-r--r--contrib/binutils/opcodes/ia64-opc-f.c1062
-rw-r--r--contrib/binutils/opcodes/ia64-opc-i.c172
-rw-r--r--contrib/binutils/opcodes/ia64-opc-m.c863
-rw-r--r--contrib/binutils/opcodes/ia64-opc-x.c90
-rw-r--r--contrib/binutils/opcodes/ia64-opc.c88
-rw-r--r--contrib/binutils/opcodes/ia64-opc.h1
-rw-r--r--contrib/binutils/opcodes/ia64-raw.tbl8
-rw-r--r--contrib/binutils/opcodes/ia64-waw.tbl7
-rw-r--r--contrib/binutils/opcodes/po/Make-in24
-rw-r--r--contrib/binutils/opcodes/po/POTFILES.in31
-rw-r--r--contrib/binutils/opcodes/po/opcodes.pot486
-rw-r--r--contrib/binutils/opcodes/ppc-dis.c113
-rw-r--r--contrib/binutils/opcodes/ppc-opc.c2578
-rw-r--r--contrib/binutils/opcodes/s390-dis.c8
-rw-r--r--contrib/binutils/opcodes/s390-mkopc.c90
-rw-r--r--contrib/binutils/opcodes/s390-opc.c81
-rw-r--r--contrib/binutils/opcodes/s390-opc.txt1411
-rw-r--r--contrib/binutils/opcodes/sh-dis.c180
-rw-r--r--contrib/binutils/opcodes/sh-opc.h615
-rw-r--r--contrib/binutils/opcodes/sparc-dis.c104
-rw-r--r--contrib/binutils/opcodes/sparc-opc.c14
-rwxr-xr-xcontrib/binutils/symlink-tree25
644 files changed, 199910 insertions, 102159 deletions
diff --git a/contrib/binutils/ChangeLog b/contrib/binutils/ChangeLog
index 9f39349..f054da6 100644
--- a/contrib/binutils/ChangeLog
+++ b/contrib/binutils/ChangeLog
@@ -1,3 +1,1353 @@
+2004-05-06 Daniel Jacobowitz <dan@debian.org>
+
+ * src-release (do-tar): Add directories to the tar file.
+
+2004-05-06 Daniel Jacobowitz <dan@debian.org>
+
+ Merge from mainline:
+ 2004-04-15 James E Wilson <wilson@specifixinc.com>
+ * Makefile.tpl (configure-[+module+], configure-gcc,
+ configure-stage1-gcc, configure-stage2-gcc, configure-stage3-gcc):
+ Set and export LDFLAGS.
+ * Makefile.in: Regenerate.
+
+2004-04-19 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
+
+ * configure.in (mips*-*-irix5*): Enable ld.
+ * configure: Regenerate.
+
+2004-04-09 Daniel Jacobowitz <drow@mvista.com>
+
+ Merge from mainline:
+ 2004-03-25 Stan Shebs <shebs@apple.com>
+ Remove MPW support, no longer used.
+ * mpw-README, mpw-build.in, mpw-config.in, mpw-configure,
+ mpw-install: Remove files.
+ * src-release (DEVO_SUPPORT): Remove names of removed files.
+ * MAINTAINERS: Likewise.
+
+ 2004-02-28 Andrew Cagney <cagney@redhat.com>
+ * src-release (CVS_NAMES): Define.
+ (do-tar, do-tar): Prune $(CVS_NAMES).
+
+ 2004-02-23 Andrew Cagney <cagney@redhat.com>
+ * texinfo/texinfo.tex: Update from version 2003-02-03.16 to
+ 2004-02-19.09.
+
+ 2004-02-19 Andrew Cagney <cagney@redhat.com>
+ * config.guess: Update from version 2003-06-12 to 2004-02-16.
+ * config.sub: Update from version 2003-06-13 to 2004-02-16.
+
+2004-02-11 David Edelsohn <edelsohn@gnu.org>
+
+ * configure.in (powerpc-*-aix*): Add target-libada to noconfigdirs.
+ (rs6000-*-aix*): Same.
+ * configure: Regenerate.
+
+2004-02-11 Kelley Cook <kcook@gcc.gnu.org>
+
+ * configure.in (host): Add in missing $noconfigdirs to defines.
+ * configure: Regenerate.
+
+2004-02-10 Arnaud Charlet <charlet@act-europe.fr>,
+ Nathanael Nerode <neroden@gcc.gnu.org>
+
+ PR ada/6637, PR ada/5911
+ Merge with libada-branch:
+ * configure.in, Makefile.tpl, Makefile.def: Add target-libada,
+ with appropriate dependencies. Add --enable-libada configure switch.
+ * configure, Makefile.in: Regenerate.
+
+2004-02-05 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
+
+ * configure.in: Don't pass --with-stabs on IRIX 5 either.
+ * configure: Regenerate.
+
+2004-02-02 Jeff Johnston <jjohnstn@redhat.com>
+
+ * COPYING.NEWLIB: Update Red Hat license to 2004.
+
+2004-01-23 DJ Delorie <dj@redhat.com>
+
+ * Makefile.def (target_modules) [libiberty]: Don't stage.
+ * Makefile.in: Rebuilt.
+
+2004-01-23 Jeff Johnston <jjohnstn@redhat.com>
+
+ * COPYING.NEWLIB: Update to include copyrights for new
+ iconv code.
+
+2004-01-15 Andrew Cagney <cagney@redhat.com>
+
+ * src-release: Update copyright year.
+ (do-proto-toplev): Configure using i686-pc-linux-gnu.
+ (NEWLIB_SUPPORT_DIRS): Delete macro.
+ (newlib.tar.bz2): Delete rule.
+
+2004-01-14 Loren J. Rittle <ljrittle@acm.org>
+
+ * Makefile.def (target_modules) [libtermcap, libiberty, zlib]: Stage.
+ * Makefile.tpl (configure-target-[+module+]): Support stage.
+ * Makefile.in: Rebuilt.
+
+2003-01-14 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * gettext.m4: Quote names of macros to be defined by AC_DEFUN
+ throughout.
+
+2004-01-04 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * configure.in: Use ./config.cache, not config.cache.
+ * configure: Regenerate.
+ * Makefile.tpl: Special-casing not needed for GCC any more.
+ * Makefile.in: Regenerate.
+
+ * configure.in: Don't share a cache file for host dirs.
+ * configure: Regenerate.
+
+ * config-ml.in: Don't mess with the cache file.
+
+2004-01-03 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Make GCC use a separate config.cache.
+ * Makefile.in: Regenerate.
+
+ PR bootstrap/11932, PR bootstrap/11933
+ (I don't know if it will fix either of them, but it relates
+ to them.)
+ * configure.in: Don't use shared config.cache for target
+ directories.
+ * configure: Regenerate.
+
+2003-12-31 Roger Sayle <roger@eyesopen.com>
+
+ * configure.in (ia64*-*-hpux*): Disable building java libraries.
+ * configure: Regenerated.
+
+2003-12-21 Bernardo Innocenti <bernie@develer.com>
+
+ * configure.in (*-*-uclinux): Exclude newlib, libgloss and rda.
+ * configure: Regenerated.
+
+2003-12-19 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ Port change over from GCC:
+ 2003-11-20 Kelley Cook <kcook@gcc.gnu.org>
+ * Makefile.tpl (BASE_FLAGS_TO_PASS): Pass along CONFIG_SHELL.
+ (configure-build-[+module+], configure-[+module+]): Likewise.
+ (configure-target-[+module+], configure-gcc, config.status): Likewise.
+ * Makefile.in: Regenerate.
+
+2003-12-08 Thomas Fitzsimmons <fitzsim@redhat.com>
+
+ * configure.in (raw_libstdcxx_flags): Remove the leading space.
+ * configure: Regenerate.
+
+2003-11-27 Jeff Johnston <jjohnstn@redhat.com>
+
+ * COPYING.NEWLIB: Add license info for long long routines added to
+ stdlib.
+
+2003-11-14 Arnaud Charlet <charlet@act-europe.fr>
+
+ * Makefile.tpl (EXTRA_GCC_FLAGS): Pass BOOT_ADAFLAGS.
+ * Makefile.in: Regenerate.
+
+2003-10-20 Phil Edwards <phil@codesourcery.com>
+
+ * configure.in (*-*-vxworks): Add target-libiberty to noconfdirs.
+ * configure: Regenerate.
+
+2003-10-13 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Make GCC_FLAGS_TO_PASS a superset of
+ HOST_FLAGS_TO_PASS.
+ * Makefile.in: Regenerate.
+
+2003-10-05 Mohan Embar <gnustuff@thisiscool.com>
+
+ * configure.in: Allow explicit specification of CFLAGS_FOR_BUILD.
+ * configure: Rebuilt
+ * Makefile.tpl: Use CFLAGS_FOR_BUILD computed by configure
+ * Makefile.in: Rebuilt
+
+2003-10-03 H.J. Lu <hongjiu.lu@intel.com>
+
+ * ltconfig (sys_lib_search_path_spec): Fix a typo for HPUX.
+
+2003-10-01 Phil Edwards <pme@gcc.gnu.org>
+
+ * config-ml.in: Use ac_configure_args directly instead of
+ ml_arguments. Only set ml_norecursion if --no[-]recursion is
+ actually seen.
+
+2003-10-01 Eric Botcazou <ebotcazou@libertysurf.fr>
+
+ * config-ml.in: Propagate INSTALL variables.
+
+2003-09-21 Daniel Jacobowitz <drow@mvista.com>
+
+ * configure.in: Pass a computed --program-transform-name
+ to subconfigures.
+ * configure: Regenerated.
+
+2003-09-20 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Don't pass down obsolete ENQUIRE variable.
+ * Makefile.in: Regenerate.
+
+ * Makefile.tpl: Don't pass (unused) DLLTOOL or WINDRES to gcc.
+ * Makefile.in: Regenerate.
+
+2003-09-17 Daniel Jacobowitz <drow@mvista.com>
+
+ * configure.in (TOPLEVEL_CONFIGURE_ARGUMENTS, baseargs): Fix
+ quoting.
+ * configure: Regenerated.
+
+2003-09-12 Michael Chastain <mec@shout.net>
+
+ Fix PR gdb/857.
+ * src-release (do-proto-topleve): Remove junk files
+ intl/config.cache, intl/config.status,
+ intl/config.h, intl/stamp-h.
+
+2003-09-14 Andrew Cagney <cagney@redhat.com>
+
+ * src-release (dejagnu.tar): New target.
+ (dejagnu.tar.bz2): Recursively call "gdb-taz" rule.
+ (do-djunpack): Use $(PACKAGE) for the package name.
+
+2003-09-04 DJ Delorie <dj@redhat.com>
+
+ * configure: Regenerate.
+
+2003-09-04 Robert Millan <robertmh@gnu.org>
+
+ * configure.in: Match GNU/KFreeBSD with new kfreebsd*-gnu triplet.
+
+2003-09-02 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * configure.in: Ensure arguments to sed are properly spaced.
+ * configure: Regenerate.
+
+2003-08-28 Daniel Jacobowitz <drow@mvista.com>
+
+ Merge from gcc:
+ 2003-07-20 Phil Edwards <pme@gcc.gnu.org>
+ * install-sh: Update to newer upstream versions (associated with
+ aclocal 1.7).
+ * missing: Likewise, plus $1Help2man -> $1 typo fix.
+
+2003-08-27 Daniel Jacobowitz <drow@mvista.com>
+
+ * configure.in: Set RAW_CXX_FOR_TARGET if unset.
+ * configure: Regenerated.
+
+2003-08-23 Phil Edwards <pme@gcc.gnu.org>
+
+ * configure.in: Use newline instead of semicolon when assuming
+ shell arguments in a for loop.
+ * configure: Regenerated.
+
+2003-08-20 Geoffrey Keating <geoffk@apple.com>
+
+ PR 8180
+ * configure.in: When testing with_libs and with_headers, treat
+ 'no' as unset. Based on a patch by Dan Kegel <dank@kegel.com>.
+ * configure: Regenerate.
+
+ * configure.in (TOPLEVEL_CONFIGURE_ARGUMENTS): Quote properly for
+ make, shell, etc.
+ (baseargs): Likewise.
+ * configure: Regenerate.
+
+2003-08-19 Geoffrey Keating <geoffk@apple.com>
+
+ * configure.in: Disable libgcj for darwin not on powerpc.
+ * configure: Rebuild.
+
+2003-08-15 Michael Chastain <mec@shout.net>
+
+ * src-release (do-proto-toplev): Remove junk files
+ dejagnu/example/calc/config.status,
+ dejagnu/example/calc/config.log.
+
+2003-08-14 Alexandre Duret-Lutz <adl@gnu.org>
+
+ * config-ml.in, symlink-tree: Add license.
+
+2003-08-01 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ Merge from gcc:
+
+ 2003-08-01 Matt Kraai <kraai@alumni.cmu.edu>
+ * Makefile.tpl (check, check-c++): Express dependencies using
+ dependencies rather than commands.
+ * Makefile.in: Regenerate.
+
+ 2003-07-31 Geoffrey Keating <geoffk@apple.com>
+ * Makefile.tpl (libsubdir): Use gcc instead of gcc-lib.
+ * Makefile.in: Update.
+
+2003-08-01 Andrew Cagney <cagney@redhat.com>
+
+ * configure.in (noconfigdirs): Do not add GDB when m32r-*-*.
+ * configure: Ditto.
+
+2003-07-30 Andreas Tobler <a.tobler@schweiz.ch>
+
+ * configure.in: Enable libgcj for darwin.
+ * configure: Rebuild.
+
+2003-07-29 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * mkinstalldirs: Import autoconf 2.57 / automake 1.7 version.
+
+2003-07-27 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Use 'mkinstalldirs' rather than 'mkdir' when
+ creating target and build subdirs to build all parent dirs as needed.
+ * Makefile.in: Rebuild.
+ * configure.in: Don't build dirs explicitly here.
+ * configure: Rebuild.
+
+2003-07-22 Alexandre Oliva <aoliva@redhat.com>
+
+ * Makefile.tpl (all-make): Depend on intl.
+ * Makefile.in: Rebuilt.
+
+2003-07-16 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * config.if: Remove unused libc_interface determination.
+
+2003-07-14 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.in: Regenerate, correctly this time.
+
+2003-07-13 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Set INSTALL and friends using autoconf. Remove
+ unused INSTALL_PROGRAM_ARGS.
+ * configure.in: Use AC_PROG_INSTALL.
+ * Makefile.in: Regenerate.
+ * configure: Regenerate.
+
+2003-07-10 Alexandre Oliva <aoliva@redhat.com>
+
+ * configure: Rebuilt.
+ 2001-09-26 Alexandre Oliva <aoliva@redhat.com>
+ * configure.in (noconfigdirs) [am33_2.0-*-linux*]: Don't build
+ newlib nor libgloss.
+ Wed May 9 10:07:19 2001 Alexandre Oliva <aoliva@redhat.com>
+ * configure.in (am33_2.0-*-linux*): Added.
+
+2003-07-09 Bob Wilson <bob.wilson@acm.org>
+
+ * configure.in: Add ${libgcj} to noconfigdirs for xtensa-*-* targets.
+ * configure: Regenerate.
+
+2003-07-06 H.J. Lu <hongjiu.lu@intel.com>
+
+ * config-ml.in: Replace PWD with PWD_COMMAND.
+ * Makefile.tpl: Likewise.
+ * Makefile.in: Regenerated.
+
+2003-06-27 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * configure.in: Clean up config-lang.in handling. Delete
+ useless assignment to "subdirs".
+ * configure: Regenerate.
+
+2003-06-26 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * configure.in: Rename 'target_libs' to 'target_libraries'.
+ Remove useless reference to 'target_libs'.
+ * configure: Regenerate.
+
+2003-06-23 Keith Seitz <kseitz@sources.redhat.com>
+
+ * Makefile.tpl: Add maybe-configure-itcl to configure-gdb.
+ * Makefile.in: Regenerate.
+
+2003-06-23 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.def: Introduce flags_to_pass.
+ * Makefile.tpl: Generate BASE_FLAGS_TO_PASS using it.
+ * Makefile.in: Regenerate.
+
+2003-06-23 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * configure.in (noconfigdirs) <cris-*-*>: Disable target-newlib
+ and target-libgloss.
+ <d30v-*-*, fr30-*-*, i960-*-*, m32r-*-*>: Disable gdb.
+ <h8300*-*-*>: Disable libf2c and ${libgcj}.
+ * configure: Regenerate.
+
+2003-06-17 Benjamin Kosnik <bkoz@redhat.com>
+
+ * configure.in: Update testsuite_flags to new location.
+ * configure. Regenerate.
+
+2003-06-18 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Remove BUILD_CC stuff.
+ * Makefile.in: Regenerate.
+
+2003-06-14 H.J. Lu <hongjiu.lu@intel.com>
+
+ * config.guess: Update to 2003-06-12 version.
+ * config.sub: Update to 2003-06-13 version.
+
+2003-06-12 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * MAINTAINERS: Add myself as MIPS co-maintainer.
+
+2003-06-12 H.J. Lu <hongjiu.lu@intel.com>
+
+ * config.guess: Update to 2003-06-06 version.
+ * config.sub: Update to 2003-06-06 version.
+
+2003-06-11 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
+
+ * configure.in: Don't pass --with-stabs for mips*-sgi-irix6*o32.
+ * configure. Regenerate.
+
+2003-06-10 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * configure.in: Disable serial configure by default.
+ * configure: Regenerate.
+ * Makefile.tpl: Abolish .NOTPARALLEL.
+ * Makefile.in: Regenerate.
+
+ * Makefile.tpl: Replace {build,host,target}_canonical by
+ {build,host,target}.
+ * Makefile.in: Regenerate.
+
+ * Makefile.tpl: Fix stupid pasto.
+ * Makefile.in: Regenerate.
+
+2003-06-09 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Remove bogus conditional.
+ * Makefile.in: Regenerate.
+
+2003-06-03 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Make 'recursive targets' using autogen rather
+ than shell loop. Remove duplicate 'clean' targets and false
+ comments.
+ * Makefile.def: Add systematic dependencies to 'recursive' targets.
+ Add systematic method of specifying missing targets in subdirs.
+ Add copyright boilerplate.
+ * Makefile.in: Regenerate.
+ * configure.in: Add 'recursive targets' to maybe list.
+ * configure: Regenerate.
+
+ * Makefile.tpl: Rename [+target+] to [+make_target+].
+ * Makefile.def: Rename 'target' to 'make_target'.
+
+2003-05-30 Nick Clifton <nickc@redhat.com>
+
+ * README-maintainer-mode: Update URL for locating blessed config
+ tools.
+
+2003-05-29 Robert Millan <rmh@debian.org>
+
+ * ltconfig: Import this patch and modify for use with current
+ version of ltconfig:
+
+ 2003-05-21 Bruno Haible <bruno@clisp.org>
+
+ * libtool.m4 (AC_LIBTOOL_SYS_DYNAMIC_LINKER): Add support for
+ GNU/FreeBSD.
+
+2003-05-28 DJ Delorie <dj@redhat.com>
+
+ * Makefile.tpl: Make maybe-check-gcc .PHONY.
+ * Makefile.in: Regenerate.
+
+2003-05-28 Jeff Johnston <jjohnstn@redhat.com>
+
+ * COPYING.NEWLIB: Add license info for newlib/libc/sys/linux/stdlib.
+
+2003-05-21 DJ Delorie <dj@redhat.com>
+
+ * Makefile.tpl (configure-target-libiberty): Depend only on gcc, not
+ newlib or libgloss.
+ * Makefile.in: Regenerate.
+
+2003-05-21 DJ Delorie <dj@redhat.com>
+
+ * Makefile.tpl: Add missing empty maybe-check-gcc target.
+ * Makefile.in: Regenerate.
+
+2003-05-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * configure.in: Use curly braces in the definition of tooldir.
+ * configure: Regenerate.
+
+2003-05-19 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * configure.in: Switch more things to use maybe dependencies.
+ * Makefile.tpl: Switch more things to use maybe dependencies.
+ Factor out common code from autogen IF statements.
+ * configure: Regenerate.
+ * Makefile.in: Regenerate.
+
+2003-05-14 Kelley Cook <kelleycook@wideopenwest.com>
+
+ * configure.in: Accept i[3456789]86 for machine type.
+ * configure: Regenerate.
+
+2003-05-18 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * configure.in: Switch more things to use maybe dependencies.
+ Rearrange a little. Use GCC_TOPLEV_SUBDIRS.
+ * configure: Regenerate.
+ * Makefile.tpl: Switch more things to use maybe dependencies.
+ * Makefile.in: Regenerate.
+
+2003-05-16 Andreas Schwab <schwab@suse.de>
+
+ * Makefile.tpl (install-opcodes): Define.
+ * Makefile.in: Rebuild.
+
+2003-05-13 Andreas Jaeger <aj@suse.de>
+
+ * config.guess: Update to 2003-05-09 version.
+ * config.sub: Update to 2003-05-09 version.
+
+2003-05-13 Michael Eager <eager@mvista.com>
+
+ * configure.in: Correct sed script so that options in quotes are not
+ deleted.
+ * configure: Rebuild.
+
+2003-05-12 Corinna Vinschen <corinna@vinschen.de>
+
+ * configure.in (FLAGS_FOR_TARGET): Remove $$s/newlib/libc/sys/cygwin
+ and $$s/newlib/libc/sys/cygwin32 include paths.
+ * configure: Ditto.
+
+2003-05-05 H.J. Lu <hjl@gnu.org>
+
+ * config-ml.in: Restored from gcc repository.
+
+2003-05-02 Chris Demetriou <cgd@broadcom.com>
+
+ * Makefile.tpl: Require "makeinfo" from texinfo 4.2 or later.
+ * Makefile.in: Regenerate.
+
+2003-04-27 Daniel Jacobowitz <drow@mvista.com>
+
+ * src-release (DEVO_SUPPORT): Add src-release, Makefile.tpl,
+ and Makefile.def.
+
+2003-04-27 Daniel Jacobowitz <drow@mvista.com>
+
+ * Makefile.tpl: Clean $(BUILD_SUBDIR).
+ * Makefile.in: Regenerated.
+
+2003-04-18 Gerald Pfeifer <pfeifer@dbai.tuwien.ac.at>
+
+ * Makefile.tpl (MAKEINFOFLAGS): Default to --split-size=5000000.
+ * Makefile.in: Regenerate.
+
+2003-04-18 Jakub Jelinek <jakub@redhat.com>
+
+ * configure.in (powerpc64*-*-linux*): Remove.
+ * configure: Rebuilt.
+
+2003-04-17 Phil Edwards <pme@gcc.gnu.org>
+
+ * Makefile.tpl (GCC_STRAP_TARGETS): New variable containing all the
+ previous bootstrap targets, plus bubblestrap, quickstrap, cleanstrap,
+ and restrap.
+ * Makefile.in: Regenerate.
+
+2003-04-16 Richard Earnshaw <rearnsha@arm.com>
+
+ * configure.in (arm-*-netbsdelf*): Enable building java libraries.
+ * configure: Regenerated.
+
+2003-04-11 Alexandre Oliva <aoliva@redhat.com>
+
+ * libtool.m4 (lt_cv_deplibs_check_method): Use pass_all on mips*.
+ * */configure: Rebuilt.
+
+2003-03-14 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Move .NOEXPORT, MAKEOVERRIDES back down.
+ * Makefile.in: Regenerate.
+
+2003-03-14 Michael Chastain <mec@shout.net>
+
+ * Makefile.in: Regenerate with correct Makefile.def.
+
+2003-03-12 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Move .NOEXPORT, MAKEOVERRIDES up. Delete unused
+ Make macro.
+ * Makefile.in: Regenerate.
+ * configure.in: Clean up gxx_include_dir logic.
+ * configure: Regenerate.
+
+2003-03-09 Franz Sirl <Franz.Sirl-kernel@lauterbach.com>
+
+ * configure.in (gxx_include_dir): Fix typo.
+ * configure: Regenerated.
+
+2003-03-06 Andrew Cagney <cagney@redhat.com>
+
+ * texinfo/texinfo.tex: Import version 2003-02-03.16.
+
+2003-03-04 Daniel Jacobowitz <drow@mvista.com>
+
+ * configure.in: Include $(build_tooldir)/sys-include in
+ FLAGS_FOR_TARGET.
+ * configure: Regenerated.
+
+2003-03-04 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Reindent.
+ * Makefile.in: Regenerate.
+ * configure.in: Reindent. Don't set unused variables.
+ * configure: Regenerate.
+
+ * Makefile.tpl: Always pass down RANLIB.
+ * Makefile.in: Regenerate.
+
+ * Makefile.tpl: Don't set unused enable_shared, enable_threads macros.
+ * Makefile.in: Regenerate.
+ * configure.in: Remove unused logic relating to --enable-shared
+ and --enable-threads. Remove bogus comments. Remove redundant
+ noconfigdirs.
+ * configure: Regenerate.
+
+ * configure.in: Replace ${libstdcxx_version} by its value.
+ Remove reference to mh-dgux.
+ * configure: Regenerate.
+
+2003-02-28 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Rearrange.
+ * Makefile.in: Regenerate.
+
+2003-02-25 Nick Clifton <nickc@redhat.com>
+
+ * configure: Remove site-file supprot - it is obsolete.
+
+2003-02-24 Uwe Stieber <uwe@wwws.de>
+
+ * configure.in: Add support for kaOS as cross build target system.
+ * configure: Regenerated.
+
+2003-02-20 Sean McNeil <sean@blue.mcneil.com>
+
+ * Makefile.tpl: Add definition of CPPFLAGS to pass into
+ configure-target-* as some target builds may require additional
+ flags for preprocessor tests.
+ * Makefile.in: Regenerated.
+
+2003-02-19 Alexandre Oliva <aoliva@redhat.com>
+
+ * libtool.m4 (LD): Append -melf* option to LD on IRIX with GNU ld.
+ * ltconfig: Handle it.
+ * ltcf-cxx.sh: Use with_gnu_ld passed as a shell variable instead of
+ auto-detecting it.
+
+2003-02-19 Alexandre Oliva <aoliva@redhat.com>
+
+ * ltcf-cxx.sh: Replace $linker_flags with $compiler_flags wherever
+ it is used as argument to $CC.
+ * ltcf-gcj.sh: Likewise.
+
+2003-02-19 Alexandre Oliva <aoliva@redhat.com>
+
+ * configure.in: Introduce --enable-maintainer-mode.
+ * configure: Rebuilt.
+ * Makefile.tpl (Makefile.in, configure): Enable dependencies only
+ for maintainer mode.
+ * Makefile.in: Rebuilt.
+
+2003-02-19 Andrew Cagney <ac131313@redhat.com>
+
+ * configure: Regenerate using autoconf 2.13.
+
+2003-02-19 Alan Modra <amodra@bigpond.net.au>
+
+ * config.guess: Import latest version.
+ * config.sub: Import latest version.
+
+2003-02-18 Jason Merrill <jason@redhat.com>
+
+ * Makefile.tpl (check-c++): Allow parallelism.
+
+2003-02-17 Andrew Cagney <ac131313@redhat.com>
+
+ * configure: Regenerate using autoconf 000227.
+
+2003-02-15 Geoffrey Keating <geoffk@apple.com>
+
+ * configure.in (*-*-darwin*): Rename from powerpc*-*-darwin*,
+ don't configure target-libobjc.
+ * configure: Regenerate.
+
+2003-02-14 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
+
+ * Makefile.tpl (RANLIB): Define.
+ * Makefile.in: Regenerate.
+
+2003-02-06 Keith R Seitz <keiths@redhat.com>
+
+ * Makefile.def: Remove "snavigator", "grep", and "db" modules.
+ * Makefile.tpl: Remove "all-snavigator" and "all-grep".
+ * Makefile.in: Regenerated.
+ * configure.in: Remove all traces of snavigator, db, and grep.
+ * configure: Regenerated.
+
+2003-01-31 Frank Ch. Eigler <fche@redhat.com>
+
+ * Makefile.tpl (all-sid): Add libiberty/bfd/opcodes dependencies.
+ * Makefile.in: Regenerated.
+
+2003-01-30 Alexandre Oliva <aoliva@redhat.com>
+
+ * config.if: Copy from GCC.
+
+2003-01-27 Phil Edwards <pme@gcc.gnu.org>
+
+ * configure.in: Revert 24Jan change.
+ * configure: Regenerate.
+
+2003-01-23 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * configure.in: Revert previous change.
+ * configure: Regenerate.
+
+2003-01-23 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * configure.in: Make rda native-only.
+ * configure: Regenerate.
+
+2003-01-19 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * configure.in: Add missing \.
+ * configure: Rebuilt.
+
+2003-01-17 Jakub Jelinek <jakub@redhat.com>
+
+ * configure.in (baseargs): Avoid using \| in sed regular
+ expressions.
+ * configure: Rebuilt.
+
+2003-01-16 Jakub Jelinek <jakub@redhat.com>
+
+ * configure.in (baseargs): Remove all supported forms of
+ --cache-file, --srcdir, --host, --build and --target options
+ from argument lists.
+ * configure: Rebuilt.
+
+2003-01-15 Alexandre Oliva <aoliva@redhat.com>
+
+ * configure.in (noconfigdirs): Don't skip gas on IRIX 6.
+ * configure: Rebuilt.
+
+2003-01-09 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * configure.in: Substitute TOPLEVEL_CONFIGURE_ARGUMENTS.
+ * Makefile.tpl: Pass TOPLEVEL_CONFIGURE_ARGUMENTS to gcc.
+ * Makefile.in: Regenerate.
+ * configure: Regenerate.
+
+2003-01-09 Christian Cornelssen <ccorn@cs.tu-berlin.de>
+
+ * Makefile.tpl (BASE_FLAGS_TO_PASS): Also pass DESTDIR.
+ (install-info, dir.info): Prepend $(DESTDIR) to $(infodir).
+ * Makefile.in: Regenerate.
+
+2003-01-09 Alexandre Oliva <aoliva@redhat.com>
+
+ * configure.in: Remove Makefile in build, host and target modules
+ unless configure was run with --no-recursion.
+ * configure: Rebuilt.
+
+2003-01-08 Chris Demetriou <cgd@broadcom.com>
+
+ * config.guess: Update to 2003-01-03 version.
+ * config.sub: Update to 2003-01-03 version.
+
+2003-01-07 Christopher Faylor <cgf@redhat.com>
+
+ * configure: Regenerate with proper autoconf 2.13.
+
+2003-01-07 Christopher Faylor <cgf@redhat.com>
+
+ * configure.in: Add AC_PREREQ for consistency.
+ * configure: Regenerate.
+
+2003-01-06 Andrew Cagney <ac131313@redhat.com>
+
+ * configure.in (GDB_TK): Add tcl directories conditional on
+ gdb/gdbtk directory being present.
+ * configure: Regenerate.
+
+2003-01-04 John David Anglin <dave.anglin@nrc.ca>
+
+ * configure.in (LD): Improve test for gcc. Try to set LD to the ld used
+ by gcc if LD is not defined and we are not doing a Canadian Cross.
+ * configure: Rebuilt.
+
+2003-01-01 Daniel Jacobowitz <drow@mvista.com>
+
+ * src-release (ETC_SUPPORT): Add fdl.texi and texi2pod.pl.
+
+2002-12-31 Tom Tromey <tromey@redhat.com>
+
+ * Makefile.in: Rebuilt.
+ * Makefile.def (target_modules) [libffi]: Allow installation.
+
+2002-12-31 Andreas Schwab <schwab@suse.de>
+
+ * configure.in: Fix use of $program_transform_name.
+ * configure: Regenerated.
+
+2002-12-30 Daniel Jacobowitz <drow@mvista.com>
+
+ * configure.in (baseargs): Don't remove first configure argument.
+ * configure: Regenerated.
+
+2002-12-29 Alexandre Oliva <aoliva@redhat.com>
+
+ * Makefile.tpl (local-distclean): Don't remove...
+ (multilib.ts): ... this. Moved into...
+ (multilib.out): ... this. Don't use sub-make.
+ ($(BUILD_SUBDIR)/[+module+]/Makefile, [+module+]/Makefile,
+ $(TARGET_SUBDIR)/[+module+]/Makefile, gcc/Makefile): Moved into...
+ (configure-build-[+module+], configure-[+module+],
+ configure-target-[+module+], configure-gcc): ... these. Test
+ for Makefile existence. Drop config.status from dependencies.
+ * Makefile.in: Rebuilt.
+ * configure.in: Move gcc-version-trigger to the end of
+ ac_configure_args. Add comments to maybedep.tmp and
+ serdep.tmp. Introduce --disable-serial-configure. Remove
+ nonopt from baseargs, matching and removing corresponding
+ whitespace while at it.
+ * configure: Rebuilt.
+
+2002-12-28 Alexandre Oliva <aoliva@redhat.com>
+
+ * configure.in (host_configargs): Replace reference to
+ no-longer-defined buildopts with --build=${build_alias}.
+ * configure: Rebuilt.
+
+2002-12-28 Alexandre Oliva <aoliva@redhat.com>
+
+ * Makefile.tpl ($(NOTPARALLEL)): Move to the end. Bring uses of
+ program_transform_name to standard idiom.
+ (AUTOGEN, AUTOCONF): Define.
+ (Makefile.in): Use $(AUTOGEN).
+ (Makefile): Depend on config.status, and use autoconf-style rule to
+ build it. Move original commands to...
+ (config.status): ... this new target.
+ (configure): Add $(srcdir). Depend on config/acx.m4. Use
+ $(AUTOCONF).
+ * Makefile.in: Rebuilt.
+
+2002-12-28 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Fix dramatic bustage due to change in
+ program_transform_name.
+ * Makefile.in: Regenerate.
+
+ * configure.in: Remove unnecessary PATH setting.
+ * configure: Regnerate.
+
+ * configure.in: Don't default to unprefixed tools unless
+ the native tools will work.
+ * configure: Regenerate.
+
+ * configure.in: Convert to autoconf script. Blow away lots
+ of now-redundant Makefile fragments.
+ * configure: Generate using Autoconf.
+ * Makefile.tpl: Rewrite to reflect autoconfiscation.
+ * Makefile.in: Regenerate.
+
+2002-12-27 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * configure: Remove unneeded 'export's. Make CC_FOR_TARGET,
+ CXX_FOR_TARGET, GCJ_FOR_TARGET substituted in configure.in only.
+
+ * ChangeLog: Move a couple of entries from here to winsup/cygwin,
+ where they belong.
+
+2002-12-24 Andreas Schwab <schwab@suse.de>
+
+ * Makefile.tpl (multilib.out): Fix missing space.
+ * Makefile.in: Regenerate.
+
+2002-12-23 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Use shared multilib.out. Use move-if-change for it.
+ Convert (cd foo; make) to (cd foo && make). Clean up multilib.out.
+ * Makefile.in: Regenerate.
+ * configure.in: Remove unnecessary leftovers.
+
+2002-12-21 Geoffrey Keating <geoffk@apple.com>
+
+ * configure.in (extra_ranlibflags_for_target): New variable.
+ (*-*-darwin): Add -c to ranlib commands.
+ * configure (tooldir): Handle extra_ranlibflags_for_target.
+
+2002-12-20 Jeff Johnston <jjohnstn@redhat.com>
+
+ * COPYING.NEWLIB: Updated.
+ * COPYING.LIBGLOSS: Ditto.
+
+2002-12-19 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Revert HJL's change.
+ * Makefile.in: Regenerated.
+ * configure.in: Put build_prefix before $(BUILD_SUBDIR) here, and
+ always.
+
+2002-12-19 Andreas Schwab <schwab@suse.de>
+
+ * Makefile.tpl, configure.in: Substitute libstdcxx_incdir.
+ * Makefile.in: Regenerate.
+
+2002-12-18 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.tpl: Add @build_prefix@ before $(BUILD_SUBDIR).
+ * Makefile.in: Regenerated.
+
+ * configure.in (build_prefix): New. Substitute.
+
+2002-12-18 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Don't let real targets depend on phony targets.
+ * Makefile.in: Regenerate.
+
+ * Makefile.tpl (do-info): Depend on maybe-all-texinfo, not all-texinfo.
+ * Makefile.in: Regenerate.
+
+2002-12-16 Jason Merrill <jason@redhat.com>
+
+ * Makefile.tpl (all-gcc): Use 'make quickstrap' if there was a
+ previous 'make bootstrap'.
+ * Makefile.in: Regenerate.
+
+2002-12-17 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * configure.in (noconfigdirs) [mmix-*-*]: Disable libgloss and gdb.
+
+2002-12-13 Jason Merrill <jason@redhat.com>
+
+ * Makefile.tpl (check-gcc-c++): Renamed from check-c++. Don't run
+ library tests.
+ (check-c++): Just depend on it and check-target-libstdc++-v3.
+ * Makefile.in: Regenerate.
+
+2002-12-13 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * configure.in, Makefile.tpl, Makefile.def: Remove tclX.
+ * Makefile.in: Regenerate.
+
+2002-12-12 Jeff Johnston <jjohnstn@redhat.com>
+
+ * COPYING.NEWLIB: Update list of alternate Regent of California
+ licenses and discuss official revoking of advertising clause.
+ * COPYING.LIBGLOSS: Ditto.
+
+2002-12-12 Alexandre Oliva <aoliva@redhat.com>
+
+ * Makefile.tpl (configure-target-rda): Depend on $(ALL_GCC_C).
+ * Makefile.in: Rebuilt.
+
+2002-12-10 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * configure: Fix bug put in by gremlins.
+
+ * Makefile.tpl: Substitute more autoconfily.
+ * configure: Substitute more autoconfily.
+ * Makefile.in: Regenerate.
+
+2002-12-08 Andrew Cagney <ac131313@redhat.com>
+
+ * Makefile.tpl (all-sim): Depend on maybe-configure-gdb.
+ * Makefile.in (all-sim): Ditto.
+
+2002-12-06 DJ Delorie <dj@redhat.com>
+
+ * Makefile.tpl: Change configure dependencies to not have real
+ targets depend on phony targets.
+
+2002-12-05 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * configure.in: Revert unintentional change.
+
+ * src-release: Configure host subdirs.
+
+ * Makefile.tpl: Change dependency for */multilib.out so that
+ it works when gcc isn't in the tree.
+
+ * configure.in: Substitute more.
+ * configure: Run subconfigures from the Makefile.
+ * Makefile.tpl: Run subconfigures from the Makefile; add a few
+ convenience targets. Make sure gcc isn't rebuilt after bootstrap.
+
+2002-12-03 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Add targets for configuring host subdirs in Makefile,
+ and corresponding dependencies.
+ * Makefile.in: Regenerate.
+
+ * configure.in (host_tools): Order binutils, gas and ld for
+ convenience in running the testsuites.
+
+ * Makefile.tpl: Introduce rules to serialize subconfigure runs.
+ * Makefile.in: Regenerate.
+ * configure.in: Introduce rules to serialize subconfigure runs.
+
+ * configure.in: Introduce BASE_CC_FOR_TARGET.
+ * Makefile.tpl: Reorganize and comment. Introduce HOST_CONFIGARGS.
+ Realize configure-build-* targets. Realize configure-target-* targets.
+ * Makefile.in: Regenerate.
+
+2002-12-02 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * configure: Move gcc_version_trigger stuff from here...
+ * configure.in: ...to here.
+
+ * configure.in: Separate subconfigure options added by this file from
+ options given by the user. Add machinery to put args for host
+ subconfigures into the Makefile.
+
+ * Makefile.tpl: Remove 'vault' targets.
+ * Makefile.tpl: Reorder and comment dependencies.
+ * Makefile.in: Regenerate.
+
+2002-11-28 Geoffrey Keating <geoffk@apple.com>
+
+ * configure.in: Move host-specific darwin noconfigdirs into
+ the host-specific section.
+
+2002-12-02 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Restore bkorb's style patch, accidentally lost
+ during replay.
+ * Makefile.in: Regenerate.
+
+ (finishing slow-motion replay)
+ * configure: Remove skip-this-dir support.
+ * Makefile.tpl: Remove skip-this-dir support.
+
+ * Makefile.tpl: Remove leftover support for non-autoconfiscated
+ subdirectories.
+ * Makefile.in: Regenerate.
+
+ * Makefile.tpl: Strip out useless setting of 'dir'.
+ * Makefile.in: Regenerate.
+
+2002-12-02 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ (finishing slow-motion replay)
+ * configure.in: Fix deeply stupid bug.
+
+ * configure.in: Introduce RAW_CXX_FOR_TARGET and simplify embedded
+ shell code in CXX_FOR_TARGET
+ * Makefile.def: Introduce raw_cxx.
+ * Makefile.tpl: Use raw_cxx to select between CXX_FOR_TARGET and
+ RAW_CXX_FOR_TARGET.
+ * Makefile.in: Regenerate.
+
+2002-12-02 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ (finishing slow-motion replay)
+ * Makefile.tpl: Remove unnecessary ifs.
+ * Makefile.in: Regenerate.
+
+ * Makefile.tpl: Implement soft dependency machinery. Maybe-ize
+ dependencies. Maybe-ize build-libiberty. Create dummy install
+ targets for 'no_install' modules.
+ * configure: Move GDB_TK substitution to configure.in. Move
+ build_modules stuff to configure.in.
+ * configure.in: Implement soft dependency machinery. Maybe-ize
+ GDB_TK, rearrange slightly. Move build_modules stuff from configure.
+ * Makefile.in: Regenerate.
+
+2002-12-01 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ (continuing slow-motion replay)
+ * Makefile.tpl: Make all-target, install-target behave similarly
+ to all, install (only hitting configured targets). Eliminate
+ unused macro defintions.
+
+ * Makefile.tpl: Add all-gcc: all-build-libiberty dependency when
+ build != host.
+
+ * Makefile.tpl: Add all-gcc: all-libiberty dependency.
+
+ * ltcf-c.sh, ltcf-gcj.sh, Makefile.tpl: Correct BUILD/HOST confusion.
+
+ * configure.in: Produce lists of subdir targets we're actually
+ configuring. Remove references to "dosrel".
+ * Makefile.tpl: Let configure set which subdir targets are hit.
+ Remove install-cross; clean up install; remove ALL. Remove
+ references to "dosrel". Remove "EXTRA_TARGET_HOST" hackery.
+ Autogenerate host module targets. Remove empty dependency lines
+ and redundant dependency; rearrange slightly.
+ * Makefile.def: Add host-side libtermcap, utils.
+
+ * Makefile.in: Regenerate.
+
+2002-12-01 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ (Continuing slow-motion replay)
+ * Makefile.def: Add list of recursive targets to autogenerate.
+ Add build_modules.
+ * Makefile.tpl: Autogenerate do-* targets. Autogenerate *-target-*
+ targets. Autogenerate *-build-* targets.
+ * Makefile.in: Regenerate.
+
+2002-11-30 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ (Continuing slow-motion replay)
+ * configure: More autoconf-style substitutions.
+ * Makefile.tpl: More autoconf-style substitutions.
+ * Makefile.in: Regenerate.
+
+2002-11-30 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ (Continuing slow-motion replay)
+ * configure: Substitute more variables in a more autoconf-friendly
+ way. Simplify slightly.
+ * Makefile.tpl: Make more variables substitutable in an
+ autoconf-friendly way.
+ * Makefile.in: Regenerate.
+
+2002-11-29 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ (Continuing slow-motion replay)
+ * configure.in (v810*): Remove special setting of tools.
+
+ * configure: Add support for extra required flags for ar or nm.
+ * configure.in (aix4.3+): Use above support for target-specific
+ issues, rather than using config/mt-aix43.
+
+2002-11-29 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ (Starting slow-motion replay merge from gcc 3.4 b-i-b branch)
+ * configure: Remove 'removing', which doesn't work. Replace $subdir
+ with . everywhere. Replace $subdirs with ''. Replace $makesrcdir
+ with $srcdir. Reformat indentation. Substitute some variables
+ formerly hard-coded in the Makefile for build=host.
+ * Makefile.tpl: Autogenerate more; make more autoconf-friendly.
+ * Makefile.def: Autogenerate more.
+ * Makefile.in: Regenerate.
+
+2002-11-13 Bruce Korb <bkorb@gnu.org>
+
+ * Makefile.tpl: syntactic cleanup
+
+2002-11-04 Kevin Buettner <kevinb@redhat.com>
+
+ * Makefile.def (host_modules): Add rda.
+ * Makefile.in: Regenerate.
+ * configure.in (target_tool): Add target-rda to list.
+
+2002-10-25 Phil Edwards <pme@gcc.gnu.org>
+
+ * Makefile.tpl (bootstrap): Add bubblestrap, quickstrap, cleanstrap,
+ and restrap targets to this rule.
+ * Makefile.in: Regenerate.
+
+2002-10-24 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * configure.in (i[3456]86-*-linux*): Add check to disable
+ ${libgcj} for glibc1.
+
+2002-10-07 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * configure.in: Add tic4x target.
+
+2002-10-03 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Make SET_LIB_PATH substitution more autoconfy.
+ * Makefile.tpl: Make RPATH_ENVVAR substitution more autoconfy.
+ * configure.in: Make SET_LIB_PATH substitution more autoconfy.
+ * configure.in: Make RPATH_ENVVAR substitution more autoconfy.
+ * Makefile.in: Regenerate.
+
+2002-10-02 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Eliminate reference to all-gui, all-libproc.
+ * Makefile.in: Regenerate.
+
+ * Makefile.def: Remove order dependency comments.
+ * Makefile.tpl: Add explicit install-install dependencies.
+ * Makefile.in: Regenerate.
+
+ * Makefile.tpl: Remove material now in src-release. (Finally!)
+ * Makefile.in: Regenerate.
+
+ * configure: Restore my original patch by syncing with gcc version.
+
+ * Bring following over from gcc:
+
+2002-09-30 Ulrich Weigand <uweigand@de.ibm.com>
+
+ * configure.in (s390*-*-linux*): Enable libgcj.
+
+2002-10-02 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.in: Regenerate. This really ought to fix things. :sigh:
+
+2002-10-02 Alan Modra <amodra@bigpond.net.au>
+
+ * configure: Move stray lines back to where they belong.
+
+2002-10-01 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Insert configure-target target, for src-release.
+
+ * configure: Finish reverting change which Andrew Cagney started
+ reverting. Should fix bustage.
+
+ * src-release (BINUTILS_SUPPORT_DIRS): Add cpu directory.
+ * src-release: New file. Contains material for making net
+ releases for gdb, binutils, et al., formerly in Makefile.in.
+
+2002-09-30 Nick Clifton <nickc@redhat.com>
+
+ * cpu: New top level directory. Intended to hold input files for
+ CGEN which have FSF copyright assignment.
+ * Makefile.in (BINUTILS_SUPPORT_DIRS): Add cpu directory.
+
+2002-09-29 Andrew Cagney <ac131313@redhat.com>
+
+ Revert below (note that src does not contain Makefile.tpl):
+ * Makefile.tpl: Make subsituted variables more autoconfy.
+ * Makefile.in: Regenerate.
+
+2002-09-29 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * configure: Revert accidentally applied changes.
+
+ * Makefile.tpl: Make more autoconf-friendly.
+ * Makefile.in: Regenerate.
+ * configure: Make substitution more autoconf-like.
+
+2002-09-28 Richard Earnshaw <rearnsha@arm.com>
+
+ * configure.in (arm-*-coff, strongarm-*-coff, xscale-*-coff): Use a
+ single entry to handle all these.
+ (arm-*-elf, strongarm-*-elf, xscale-*-elf): Likewise. Also enable
+ libjava on arm-*-elf.
+
+2002-09-27 Geoffrey Keating <geoffk@apple.com>
+
+ * configure.in (powerpc-*-darwin*): Don't configure BFD, TK, or the
+ things that depend on them.
+
+2002-09-25 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Make subsituted variables more autoconfy.
+ * Makefile.in: Regenerate.
+ * configure: Make seds more autoconfy.
+
+2002-09-25 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.tpl: Rewrite substituted lines to look autoconfy.
+ * Makefile.in: Regenerate.
+ * configure.in: Rewrite sed statements to look autoconfy.
+
+ * Makefile.tpl: Autogenerate *-target-* lists, dependencies of
+ all-target-foo on configure-target-foo.
+ * Makefile.def: Ditto.
+ * Makefile.in: Rebuild.
+
+2002-09-22 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * Makefile.def: New file.
+ * Makefile.tpl: New file.
+ * Makefile.in: Generate from Makefile.tpl with 'autogen Makefile.def'.
+
+ * configure.in: Minor rearrangement. Simplify tests.
+
+2002-09-23 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * configure.in (with_headers): Skip copy if value is "yes".
+ (with_libs): Likewise.
+
+2002-09-20 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * configure.in (*-*-netbsd*): Use noconfigdirs, not skipdirs.
+ * configure.in (sh*-*-pe*): Ditto.
+ * configure.in (mips*-*-pe*): Ditto.
+ * configure.in (*arm-wince-pe): Ditto.
+
+ * configure.in: Rearrange.
+
+2002-09-12 Nick Clifton <nickc@redhat.com>
+
+ * Import these changes from the config master repository:
+
+ 2002-09-05 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * config.sub: Add tic4x target.
+
+ 2002-09-03 Ben Elliston <bje@redhat.com>
+
+ * config.guess: Detect NSR-D machines for nsr-tandem-nsk.
+ Reported by <Duncan_Stodart@insession.com>.
+
+2002-09-10 Jeff Johnston <jjohnstn@redhat.com>
+
+ * COPYING.NEWLIB: More updates.
+
+2002-09-09 Jeff Johnston <jjohnstn@redhat.com>
+
+ * COPYING.NEWLIB: Update.
+
+2002-08-23 Andrew Cagney <ac131313@redhat.com>
+
+ * texinfo/texinfo.tex: Import version 2002-06-04.06.
+
+ * config.guess: Import version 2002-08-23.
+ * config.sub: Import version 2002-08-22.
+
+2002-08-20 Alexandre Oliva <aoliva@redhat.com>
+
+ * Makefile.in (GCC_FOR_TARGET): Prepend STAGE_CC_WRAPPER.
+ * configure.in (CC_FOR_TARGET, GCJ_FOR_TARGET, CXX_FOR_TARGET,
+ CXX_FOR_TARGET_FOR_RECURSIVE_MAKE): Likewise.
+
+2002-08-06 Federico G. Schwindt <fgsch@olimpo.com.br>
+
+ * configure.in (hppa*-*-openbsd*): Treat like hppa*-*-*elf*.
+
+2002-08-04 H.J. Lu (hjl@gnu.org)
+
+ * configure.in (mips*-*-linux*): Don't skip target-libffi.
+
+2002-07-31 Alan Modra <amodra@bigpond.net.au>
+
+ * configure.in: Move generic linux case to end. Copy generic
+ linux noconfigdirs to mips*-*-linux* entry and new
+ powerpc64*-*-linux* entry. Add target-libffi for the latter.
+
+2002-07-19 Chris Demetriou <cgd@broadcom.com>
+
+ * MAINTAINERS: Clarify on config.guess and config.sub, and add
+ one instance of them which was missed to the list to update.
+
+2002-07-16 Chris Demetriou <cgd@broadcom.com>
+
+ * config.guess: Update to 2002-07-09 version.
+ * config.sub: Update to 2002-07-03 version.
+
2002-07-11 Nathanael Nerode <neroden@gcc.gnu.org>
* configure.in: Remove two redundant tests.
@@ -32,7 +1382,7 @@
2002-07-03 Nick Clifton <nickc@cambridge.redhat.com>
* contrib: New directory. Created to contain a copy of the
- texi2pod.pl script so that it is in the same place as the version in
+ texi2pod.pl script so that it is in the same place as the version in
the FSF GCC sources.
2002-07-02 Nathanael Nerode <neroden@gcc.gnu.org>
@@ -248,7 +1598,7 @@
* configure.in (target_libs): Remove target-libchill.
Do not compute CHILL_FOR_TARGET.
* libchill: Remove directory.
-
+
2002-04-15 DJ Delorie <dj@redhat.com>
* Makefile.in, configure.in, configure: Sync with gcc, entries
@@ -611,7 +1961,7 @@ Wed Sep 13 11:11:29 2000 Jeffrey A Law (law@cygnus.com)
* configure.in: Re-enable all references to libg++ and librx.
2002-04-09 Loren James Rittle <rittle@labs.mot.com>
-
+
* configure.in: Add *-*-freebsd* configurations.
2002-04-07 Andrew Cagney <ac131313@redhat.com>
@@ -763,7 +2113,7 @@ Wed Sep 13 11:11:29 2000 Jeffrey A Law (law@cygnus.com)
libiberty.
Import this patch from gcc:
-
+
2000-12-09 Laurynas Biveinis <lauras@softhome.net>
* symlink-tree: handle DOS-style absolute paths.
@@ -913,7 +2263,7 @@ Wed Sep 13 11:11:29 2000 Jeffrey A Law (law@cygnus.com)
Fri Jun 8 11:14:02 2001 Andrew Cagney <cagney@b1.cygnus.com>
* Makefile.in (VER): When present, extract the version number from
- the file version.in.
+ the file version.in.
2001-06-08 Alexandre Oliva <aoliva@redhat.com>, Jeff Sturm <jsturm@one-point.com>
@@ -1788,8 +3138,6 @@ Fri Apr 2 15:11:32 1999 H.J. Lu (hjl@gnu.org)
Thu Mar 18 00:17:50 1999 Mark Elbrecht <snowball3@usa.net>
- * config/mh-go32: Delete.
- * config/mh-djgpp: New. Renamed from mh-go32.
* configure.in (pc-msdosdjgpp): Set host_makefile_frag to
config/mh-djgpp.
@@ -1840,7 +3188,6 @@ Wed Mar 10 17:39:09 1999 Drew Moseley <dmoseley@cygnus.com>
1999-02-24 Stan Shebs <shebs@andros.cygnus.com>
* configure.in (*-*-windows*): Remove, no longer used.
- * config/mh-windows: Ditto.
1999-02-19 Ben Elliston <bje@cygnus.com>
@@ -1906,7 +3253,6 @@ Wed Mar 10 17:39:09 1999 Drew Moseley <dmoseley@cygnus.com>
* config.guess: Add support for i386-pc-interix.
* config.sub: Likewise.
* configure.in: Likewise.
- * config/mh-interix: New file.
1999-01-18 Christopher Faylor <cgf@cygnus.com>
@@ -1919,7 +3265,6 @@ Wed Mar 10 17:39:09 1999 Drew Moseley <dmoseley@cygnus.com>
* configure.in: makefile stub for cygwin target is probably
unnecessary. Remove it for now.
- * config/mt-cygwin: Remove.
1998-12-30 Christopher Faylor <cgf@cygnus.com>
@@ -1927,7 +3272,6 @@ Wed Mar 10 17:39:09 1999 Drew Moseley <dmoseley@cygnus.com>
target as well as the host.
* config.guess: Allow mixed case in cygwin uname output.
* Makefile.in: Add libtermcap target.
- * config/mt-cygwin: New file. libtermcap target info.
1998-12-23 Jeffrey A Law (law@cygnus.com)
@@ -2658,11 +4002,6 @@ Fri Feb 6 01:33:52 1998 Manfred Hollstein <manfred@s-direktnet.de>
* configure: Emit a definition for the new macro enable_shared
into each Makefile.
- * config/mh-sparcpic (PICFLAG): Define to properly according
- to current multilib configuration.
- * config/mt-sparcpic (PICFLAG_FOR_TARGET): Define to properly
- according to current multilib configuration.
-
Thu Feb 5 17:01:12 1998 Jason Molenda (crash@bugshack.cygnus.com)
* configure.in (host_tools, native_only): Add libtool.
@@ -2780,7 +4119,6 @@ Sun Jan 4 01:06:55 1998 Mumit Khan <khan@xraylith.wisc.edu>
* config.sub: Add mingw32 support.
* configure.in: Likewise.
- * config/mh-mingw32: New file.
Sat Jan 3 12:11:05 1998 Franz Sirl <franz.sirl-kernel@lauterbach.com>
@@ -2998,8 +4336,6 @@ Thu Sep 18 15:37:42 1997 Andrew Cagney <cagney@b1.cygnus.com>
1997-09-15 02:37 Ulrich Drepper <drepper@cygnus.com>
- * config/mt-linux: Define CXXFLAGS to make sure -fvtable-thunks is
- used.
* configure.in: Name Linux target fragment.
* configure: Rewrite so that project Makefile fragment is inserted
@@ -3009,10 +4345,6 @@ Tue Sep 16 09:55:07 1997 Andrew Cagney <cagney@b1.cygnus.com>
* Makefile.in (install-itcl): Install tcl first.
-Sun Sep 14 20:53:42 1997 Geoffrey Noer <noer@cygnus.com>
-
- * config/mh-cygwin32: ok to build split texinfo files
-
Fri Sep 12 16:19:20 1997 Geoffrey Noer <noer@cygnus.com>
* configure.in: remove bison from noconfigdirs for Cygwin32 host
@@ -3745,7 +5077,6 @@ Tue Oct 29 16:41:31 1996 Doug Evans <dje@canuck.cygnus.com>
Mon Oct 28 17:32:46 1996 Stu Grossman (grossman@critters.cygnus.com)
* configure.in: Exclude mmalloc from i386-windows.
- * config/mh-windows: Add rules for building MSVC makefiles.
Thu Oct 24 09:22:46 1996 Stu Grossman (grossman@critters.cygnus.com)
@@ -3761,8 +5092,6 @@ Thu Oct 24 09:02:07 1996 Stu Grossman (grossman@critters.cygnus.com)
* Makefile.in (FLAGS_TO_PASS): Add $(HOST_FLAGS) to allow the
host to add it's own flags.
- * config/mh-windows (HOST_FLAGS): Set srcroot, which is needed
- for MSVC build procedure.
Tue Oct 22 15:20:26 1996 Ian Lance Taylor <ian@cygnus.com>
@@ -3813,7 +5142,7 @@ Wed Oct 9 06:06:46 1996 Jeffrey A Law (law@cygnus.com)
Tue Oct 8 08:32:48 1996 Stu Grossman (grossman@critters.cygnus.com)
- * configure.in config/mh-windows: Add support for windows host
+ * configure.in: Add support for windows host
(that is a build done under the Microsoft build environment).
Tue Oct 8 10:39:08 1996 Ian Lance Taylor <ian@cygnus.com>
@@ -3886,26 +5215,10 @@ Mon Sep 16 17:00:52 1996 Ian Lance Taylor <ian@cygnus.com>
* configure.in: Use a single line for host_tools and native_only.
-Tue Sep 16 09:55:07 1997 Andrew Cagney <cagney@b1.cygnus.com>
-
- * Makefile.in (install-itcl): Install tcl first.
-
-Sun Sep 14 20:53:42 1997 Geoffrey Noer <noer@cygnus.com>
-
- * config/mh-cygwin32: ok to build split texinfo files
-
-Fri Sep 12 16:19:20 1997 Geoffrey Noer <noer@cygnus.com>
-
- * configure.in: remove bison from noconfigdirs for Cygwin32 host
-
Mon Sep 9 12:21:30 1996 Doug Evans <dje@canuck.cygnus.com>
* config.sub, configure.in: Add entries for m32r.
-Mon Sep 8 20:46:20 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * config.guess: Merge with FSF.
-
Thu Sep 5 13:52:47 1996 Tom Tromey <tromey@creche.cygnus.com>
* Makefile.in (inet-install): Don't run install-gzip.
@@ -3963,11 +5276,6 @@ Mon Aug 12 13:15:13 1996 Michael Meissner <meissner@tiktok.cygnus.com>
* Makefile.in (CONFIGURE_TARGET_MODULES): If target compiler does
not support --print-multi-lib, don't abort.
-Sun Aug 11 20:51:50 1996 Stu Grossman (grossman@critters.cygnus.com)
-
- * config/mh-cygwin32 (CFLAGS): Define _WIN32 to be compatible
- with normal Windows compilation environment.
-
Thu Aug 8 12:18:59 1996 Klaus Kaempf <kkaempf@progis.de>
* make-all.com: Run config-a-gas.
@@ -4608,12 +5916,6 @@ Mon Dec 4 12:38:15 1995 Ian Lance Taylor <ian@cygnus.com>
* configure: Ignore new autoconf configure options.
-Thu Nov 30 14:45:25 1995 J.T. Conklin <jtc@rtl.cygnus.com>
-
- * config/mt-v810 (CC_FOR_TARGET): Add -ansi flag. NEC compiler
- defaults to K&R mode, but doesn't have varargs.h, so we have to
- compile in ANSI mode.
-
Thu Nov 30 16:57:33 1995 Per Bothner <bothner@wombat.gnu.ai.mit.edu>
* config.guess: Recognize Pentium under SCO.
@@ -4622,8 +5924,6 @@ Thu Nov 30 16:57:33 1995 Per Bothner <bothner@wombat.gnu.ai.mit.edu>
Wed Nov 29 13:49:08 1995 J.T. Conklin <jtc@rtl.cygnus.com>
* configure.in (noconfigdirs): Disable target-libio on v810-*-*.
- * config/mt-v810 (CC_FOR_TARGET, AS_FOR_TARGET, AR_FOR_TARGET,
- RANLIB_FOR_TARGET): Set as appropriate for NEC v810 toolchain.
Wed Nov 29 12:12:01 1995 Ian Lance Taylor <ian@cygnus.com>
@@ -4692,10 +5992,6 @@ Wed Nov 15 11:45:23 1995 Ian Lance Taylor <ian@cygnus.com>
* configure: Handle LD and LD_FOR_TARGET when configuring a
Canadian Cross.
-Tue Nov 14 15:03:12 1995 Jason Molenda (crash@phydeaux.cygnus.com)
-
- * config/mh-i386win32: add LD_FOR_TARGET.
-
Tue Nov 14 14:56:11 1995 Jason Molenda (crash@phydeaux.cygnus.com)
* configure.in (target_libs): add target-winsup.
@@ -5034,10 +6330,6 @@ Mon Sep 18 23:08:26 1995 J.T. Conklin <jtc@rtl.cygnus.com>
* configure.in (noconfigdirs): Disable bfd, binutils, gas, gcc,
gdb, ld and opcodes on v810-*-*.
-Sat Sep 16 18:31:08 PDT 1995 Angela Marie Thomas <angela@cygnus.com>
-
- * config/mh-ncrsvr43: Removed AR_FLAGS
-
Tue Sep 12 18:03:31 1995 Ian Lance Taylor <ian@cygnus.com>
* Makefile.in (DO_X): Change do-realclean to do-maintainer-clean.
@@ -5217,8 +6509,6 @@ Mon Jun 5 18:26:36 1995 Jason Merrill <jason@phydeaux.cygnus.com>
(FLAGS_TO_PASS): Pass them.
(EXTRA_TARGET_FLAGS): Ditto.
- * config/m?-*pic: Define PICFLAG* instead of LIB*FLAGS*.
-
Wed May 31 22:27:42 1995 Jim Wilson <wilson@chestnut.cygnus.com>
* Makefile.in (all-libg++): Depend on all-libstdc++.
@@ -5382,17 +6672,12 @@ Thu Mar 30 13:51:43 1995 Ian Lance Taylor <ian@cygnus.com>
Tue Mar 28 14:47:34 1995 Jason Molenda (crash@phydeaux.cygnus.com)
- build-all.mk,config/mh-solaris: revert these two changes:
+ Revert this change:
Tue Mar 30 10:03:09 1993 Ian Lance Taylor (ian@cygnus.com)
* build-all.mk: Use CC=cc -Xs on Solaris.
- Mon Mar 29 19:59:26 1993 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
-
- * config/mh-solaris: SunPRO C needs -Xs to be able to get a
- working xmakefile for Emacs.
-
Tue Mar 21 10:43:32 1995 Jim Kingdon (kingdon@lioth.cygnus.com)
* glob/*: Removed. Schauer's 24 Feb 1994 readline change made us
@@ -5531,7 +6816,7 @@ Sat Nov 5 18:43:30 1994 Jason Merrill (jason@phydeaux.cygnus.com)
(BASE_FLAGS_TO_PASS): Pass them.
(EXTRA_TARGET_FLAGS): Ditto.
- * configure.in, config/m[th]-*pic: Support --enable-shared.
+ * configure.in: Support --enable-shared.
Sat Nov 5 15:44:00 1994 Per Bothner <bothner@kalessin.cygnus.com>
@@ -5989,7 +7274,6 @@ Fri May 6 14:19:25 1994 Steve Chamberlain (sac@cygnus.com)
(HOST_CC, HOST_PREFIX, HOST_PREFIX_1): Undefine, they should
be set by incoming names or templates.
(INSTALL_LAST): New rule.
- * config/mh-go32: New fragment.
Thu May 5 17:35:05 1994 Stan Shebs (shebs@andros.cygnus.com)
@@ -5997,8 +7281,6 @@ Thu May 5 17:35:05 1994 Stan Shebs (shebs@andros.cygnus.com)
Thu May 5 20:06:45 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
- * config/mh-lynxrs6k: Renamed from mh-lynxosrs6k, to make it
- unique in 8.3 naming schemes.
* configure.in (appdirs): New variable. Currently empty, but will
be used in gas distribution. If nonempty, lists a set of
directories at least one of which must get configured, or top
@@ -6230,10 +7512,6 @@ Wed Feb 2 14:53:05 1994 Jim Kingdon (kingdon@lioth.cygnus.com)
* Makefile.in, test-build.mk: Remove MUNCH_NM; it was only needed
for GDB and GDB has been fixed to not need it.
-Mon Jan 31 18:40:55 1994 Stu Grossman (grossman at cygnus.com)
-
- * config/mh-lynxosrs6k: Account for lack of ranlib!
-
Sun Jan 30 17:58:06 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
* config.guess: Recognize vax hosts.
@@ -6319,7 +7597,6 @@ Thu Dec 2 14:35:54 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
libg++ or libio for any Alpha target.
* configure.in (mips*-sgi-irix5*): New target; use mh-irix5.
- * config/mh-irix5. New file for Irix 5.
Wed Dec 1 17:00:33 1993 Jason Merrill (jason@deneb.cygnus.com)
@@ -6488,10 +7765,6 @@ Fri Oct 8 14:15:39 1993 Ken Raeburn (raeburn@cygnus.com)
* config.sub: Accept linux*coff and linux*elf as operating
systems.
-Tue Oct 7 14:24:41 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * ltmain.sh: Handle symlinks in generated script.
-
Thu Oct 7 12:57:19 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
* config.sub: Recognize mips64, and mips3 as an alias for it.
@@ -6516,27 +7789,11 @@ Mon Oct 4 16:15:09 1993 david d `zoo' zuhn (zoo@rtl.cygnus.com)
--with options (but still pass them down on the command line,
if they were explicitly specified).
-Wed Oct 1 13:11:27 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * configure: Handle autoconf style directory options: --bindir,
- --datadir, --includedir, --infodir, --libdir, --libexecdir,
- --mandir, --oldincludedir, --sbindir, --sharedstatedir,
- --sysconfdir.
- * Makefile.in (sbindir, libexecdir, sysconfdir): New variables.
- (sharedstatedir, localstatedir, oldincludedir): New variables.
- (BASE_FLAGS_TO_PASS): Pass down bindir, datadir, includedir,
- infodir, libdir, libexecdir, localstatedir, mandir, oldincludedir,
- sbindir, sharedstatedir, and sysconfdir.
-
Fri Sep 24 19:11:13 1993 david d `zoo' zuhn (zoo@rtl.cygnus.com)
* configure: substitute SHELL value in Makefile.in with
${CONFIG_SHELL}
-Wed Sep 24 15:18:32 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * ltmain.sh: Tweak shell pattern to avoid bug in NetBSD /bin/sh.
-
Thu Sep 23 18:05:13 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
* configure.in: Build gas, ld, and binutils for *-*-sysv4* and
@@ -7030,8 +8287,6 @@ Sat Apr 17 17:19:50 1993 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
* configure.in: rename m88k-motorola-m88kbcs to m88k-motorola-sysv
- * config/mh-delta88: remove extraneous GCC references
-
Tue Apr 13 16:52:16 1993 Brendan Kehoe (brendan@lisa.cygnus.com)
* Makefile.in (PRMS): Set back to all-prms.
@@ -7107,8 +8362,7 @@ Wed Mar 31 21:20:58 1993 K. Richard Pixley (rich@rtl.cygnus.com)
Wed Mar 31 12:31:56 1993 Ian Lance Taylor (ian@cygnus.com)
- * build-all.mk, config/mh-irix4: Bump -XNh value to 1500 to match
- gcc requirements.
+ * build-all.mk: Bump -XNh value to 1500 to match gcc requirements.
* Makefile.in: Complete overhaul to merge many almost identical
targets.
@@ -7126,13 +8380,6 @@ Tue Mar 30 10:03:09 1993 Ian Lance Taylor (ian@cygnus.com)
* build-all.mk: Use CC=cc -Xs on Solaris.
-Mon Mar 29 19:59:26 1993 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
-
- * config/mh-sun3: cc needs -J to compile cp-parse.c correctly
-
- * config/mh-solaris: SunPRO C needs -Xs to be able to get a
- working xmakefile for Emacs.
-
Thu Mar 25 15:14:30 1993 Fred Fish (fnf@cygnus.com)
* Makefile.in: Incorporate changes suggested by wilson@cygnus.com
@@ -7226,7 +8473,6 @@ Tue Mar 2 21:15:58 1993 Fred Fish (fnf@cygnus.com)
(Ultrix 2.2 support from Michael Rendell <michael@mercury.cs.mun.ca>)
* configure.in (vax-*-ultrix2*): Add Ultrix 2.2 triplet.
* config.guess: Change 'VAX*:ULTRIX:*:*' to 'VAX*:ULTRIX*:*:*'.
- * config/mh-vaxult2: New file.
Tue Mar 2 18:11:03 1993 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
@@ -7396,8 +8642,6 @@ Sat Jan 23 20:32:01 1993 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
* Makefile.in: define and pass down X11_LIB
- * config/mh-sco: define X11_LIB to the mess that SCO ODT requires
-
Sat Jan 23 13:49:40 1993 Per Bothner (bothner@cygnus.com)
* guess-systype: Renamed to ...
@@ -7460,8 +8704,6 @@ Sun Jan 3 15:15:09 1993 Steve Chamberlain (sac@thepub.cygnus.com)
Tue Dec 29 15:06:00 1992 Ian Lance Taylor (ian@cygnus.com)
- * config/mh-sco: Don't override BISON definition.
-
* build-all.mk: If canonhost is i386-unknown-sco3.2v4, change it
to i386-sco3.2v4. Set TARGETS and CFLAGS for i386-sco3.2v4.
(all-cygnus, native, build-cygnus): Make
@@ -7526,10 +8768,6 @@ Fri Dec 11 20:18:02 1992 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
* Makefile.in: m4 depends on libiberty
-Mon Dec 7 06:43:27 1992 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
-
- * config/mh-sco: don't default $(CC) to gcc
-
Thu Dec 3 21:52:11 1992 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
* configure.in: add m4, textutils, fileutils, sed, shellutils,
@@ -7542,14 +8780,6 @@ Mon Nov 30 14:54:34 1992 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
* configure.in: use mh-sun for all *-sun-* hosts
- * config/mh-solaris: rework standard X location to use
- $OPENWINHOME, if defined.
-
- * config/mh-sun: handle X11 include locations
-
- * config/mh-decstation: define NeedFunctionPrototypes to 0, to
- work around dain-bramaged DECwindows include files
-
Fri Nov 27 18:35:54 1992 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
* Makefile.in: define flags for X11 include files and library file
@@ -7557,9 +8787,6 @@ Fri Nov 27 18:35:54 1992 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
* build-all.mk: added a 'native' target, to 3stage the native toolchain
- * config/{mh-hpux,mh-solaris}: define the "standard" locations for
- the vendor supplied X11 headers and libraries
-
Sun Nov 22 18:59:13 1992 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
* configure.in: start building libg++ for HP-UX targets
@@ -7816,11 +9043,6 @@ Tue Aug 4 01:12:43 1992 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
* configure.texi, standards.texi: fix INFO-DIR-ENTRY
-Mon Aug 3 15:41:28 1992 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
-
- * config/mh-solaris: removed the -xs from CFLAGS (let the people
- with Sun's C compiler deal with it themselved)
-
Mon Aug 3 00:34:17 1992 Fred Fish (fnf@cygnus.com)
* config.sub (ncr3000): Change i386 to i486.
@@ -7865,11 +9087,6 @@ Thu Jul 16 16:05:28 1992 K. Richard Pixley (rich@rtl.cygnus.com)
* .cvsignore: ignore some stuff that comes from test-build.mk.
-Wed Jul 8 00:01:30 1992 Stu Grossman (grossman at cygnus.com)
-
- * config/mh-solaris: Use -xs when compiling so that Sun-C puts
- a symbol-table into the executable.
-
Tue Jul 7 00:24:52 1992 Fred Fish (fnf@cygnus.com)
* config.sub: Add es1800 (m68k-ericsson-es1800).
@@ -7893,11 +9110,6 @@ Fri Jun 19 15:19:40 1992 Stu Grossman (grossman at cygnus.com)
* config.sub: HPPA merge.
-Mon Jun 15 12:31:52 1992 Fred Fish (fnf@cygnus.com)
-
- * config/mh-ncr3000 (INSTALL): Don't use /usr/ucb/install,
- it is broken on ncr 3000's.
-
Sun Jun 14 10:29:19 1992 John Gilmore (gnu at cygnus.com)
* Makefile.in: Replace all-bison with all-byacc in all
@@ -7907,10 +9119,6 @@ Fri Jun 12 22:21:57 1992 John Gilmore (gnu at cygnus.com)
* config.sub: Add sun4sol2 => sparc-sun-solaris2.
-Tue Jun 9 17:18:11 1992 Fred Fish (fnf at cygnus.com)
-
- * config/{mh-ncr3000, mh-sysv4}: Add INSTALL.
-
Thu Jun 4 12:07:32 1992 Mark Eichin (eichin@cygnus.com)
* Makefile.in: make gprof rules similar to byacc rules (instead of
@@ -8008,8 +9216,6 @@ Wed Apr 22 18:06:55 1992 K. Richard Pixley (rich@rtl.cygnus.com)
Wed Apr 22 14:38:34 1992 Fred Fish (fnf@cygnus.com)
- * config/mh-delta88, config/mh-ncr3000: Replace MINUS_G with
- CFLAGS per new configuration strategy.
* configure: Test for existance of files before trying to mv
them, to avoid numerous non-existance messages.
@@ -8171,7 +9377,7 @@ Thu Mar 5 21:45:07 1992 K. Richard Pixley (rich@sendai)
Thu Mar 5 12:05:58 1992 Stu Grossman (grossman at cygnus.com)
- * config.sub configure.in config/mh-irix4 gdb/configure.in
+ * config.sub configure.in gdb/configure.in
gdb/mips-tdep.c gdb/mipsread.c gdb/procfs.c gdb/signame.h
gdb/tm-irix3.h gdb/tm-mips.h gdb/xm-irix4.h gdb/config/mt-irix3
gdb/config/mh-irix4 texinfo/configure.in: Port to SGI Irix-4.x.
@@ -8232,7 +9438,7 @@ Fri Jan 31 02:27:32 1992 John Gilmore (gnu at cygnus.com)
Thu Jan 30 16:17:30 1992 Stu Grossman (grossman at cygnus.com)
- * bfd/configure.in, config/mh-sco, gdb/config/mh-i386sco,
+ * bfd/configure.in, gdb/config/mh-i386sco,
gdb/config/mt-i386v32, gdb/configure.in, readline/configure.in:
Fix SCO configuration stuff.
diff --git a/contrib/binutils/MAINTAINERS b/contrib/binutils/MAINTAINERS
index 104b815..7194268 100644
--- a/contrib/binutils/MAINTAINERS
+++ b/contrib/binutils/MAINTAINERS
@@ -4,12 +4,12 @@ Please do not make ChangeLog entries.
COPYING, COPYING.LIB, README
http://gnu.org.
-Makefile.in; configure; configure.in
+Makefile.in; configure; configure.in; src-release
Please notify the following of any committed patches.
binutils@sources.redhat.com
gdb-patches@sources.redhat.com
-bfd/; binutils/; gas/; gprof/; ld/; opcodes/; BFD's part of include/
+bfd/; binutils/; gas/; gprof/; ld/; opcodes/; cpu/; BFD's part of include/
binutils: http://sources.redhat.com/binutils/
Patches to binutils@sources.redhat.com.
Please notify the following of any interface changes:
@@ -21,24 +21,25 @@ cgen/; cgen parts of opcodes/, sim/ & include/
May need separate opcodes/ or sim/ approval for
commits of regenerated files there.
-config.guess; config.sub; dejagnu/config.guess;
+config.guess; config.sub; dejagnu/config.guess; dejagnu/config.sub;
readline/support/config.sub; readline/support/config.guess
config: http://savannah.gnu.org/projects/config
Patches to config-patches@gnu.org.
Changes need to be done in tandem with the official CONFIG
sources or submitted to the master file maintainer and brought
- in via a merge.
+ in via a merge. When updating any of these files, please be
+ sure to update all of them.
Please notify the following of any committed patches:
binutils@sources.redhat.com
gdb-patches@sources.redhat.com
dejagnu/
- Send all patches to:
- http://www.gnu.org/software/dejagnu/
- mail:bug-dejagnu@gnu.org
- For changes to the local repostory, send them to
- gdb-patches@sources.redhat.com when generic; and sid@,
- binutils@, gcc@, etc. for sub-components.
+ dejagnu: http://www.gnu.org/software/dejagnu/
+ Patches to bug-dejagnu@gnu.org
+ Avoid making changes to the local repository; please send
+ patches upstream. Important and approved patches can be
+ checked into the src repository, otheriwse patches will be
+ imported from the next release.
gdb/; mmalloc/; readline/; sim/; GDB's part of include/ & dejagnu/
gdb: http://sources.redhat.com/gdb/
@@ -99,8 +100,7 @@ winsup/
General discussion cygwin@sources.redhat.com.
See also winsup/MAINTAINERS.
-expect/; config-ml.in; mpw-README; mpw-build.in; mpw-config.in;
-mpw-configure; mpw-install; setup.com; missing; makefile.vms; utils/;
+expect/; config-ml.in; setup.com; missing; makefile.vms; utils/;
config/; config.if; makefile.vms; missing; ylwrap; mkdep; etc/;
install-sh; intl/
Ask DJ Delorie <dj@redhat.com> after reading the libiberty entry.
diff --git a/contrib/binutils/Makefile.def b/contrib/binutils/Makefile.def
new file mode 100644
index 0000000..5a68098
--- /dev/null
+++ b/contrib/binutils/Makefile.def
@@ -0,0 +1,210 @@
+#! /usr/bin/autogen
+AutoGen definitions Makefile.tpl;
+
+// Makefile.in is generated from Makefile.tpl by 'autogen Makefile.def'.
+// This file was originally written by Nathanael Nerode.
+//
+// Copyright 2002, 2003 Free Software Foundation
+//
+// This file is free software; you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by
+// the Free Software Foundation; either version 2 of the License, or
+// (at your option) any later version.
+//
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with this program; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+
+
+// "missing" indicates that that module doesn't supply
+// that recursive target in its Makefile.
+
+build_modules= { module= libiberty; };
+
+host_modules= { module= ash; };
+host_modules= { module= autoconf; };
+host_modules= { module= automake; };
+host_modules= { module= bash; };
+host_modules= { module= bfd; };
+host_modules= { module= opcodes; };
+host_modules= { module= binutils; };
+host_modules= { module= bison; no_check_cross= true; };
+host_modules= { module= byacc; no_check_cross= true; };
+host_modules= { module= bzip2; };
+host_modules= { module= dejagnu; };
+host_modules= { module= diff; };
+host_modules= { module= dosutils; no_check= true; };
+host_modules= { module= etc; };
+host_modules= { module= fastjar; no_check_cross= true; };
+host_modules= { module= fileutils; };
+host_modules= { module= findutils; };
+host_modules= { module= find; };
+host_modules= { module= flex; no_check_cross= true; };
+host_modules= { module= gas; };
+host_modules= { module= gawk; };
+host_modules= { module= gettext; };
+host_modules= { module= gnuserv; };
+host_modules= { module= gprof; };
+host_modules= { module= gzip; };
+host_modules= { module= hello; };
+host_modules= { module= indent; };
+host_modules= { module= intl; };
+host_modules= { module= tcl;
+ missing=mostlyclean; };
+host_modules= { module= itcl; };
+host_modules= { module= ld; };
+host_modules= { module= libgui; };
+host_modules= { module= libiberty; };
+host_modules= { module= libtool; };
+host_modules= { module= m4; };
+host_modules= { module= make; };
+host_modules= { module= mmalloc; no_check=true; };
+host_modules= { module= patch; };
+host_modules= { module= perl; };
+host_modules= { module= prms; };
+host_modules= { module= rcs; };
+host_modules= { module= readline; };
+host_modules= { module= release; no_install= true; no_check= true; };
+host_modules= { module= recode; };
+host_modules= { module= sed; };
+host_modules= { module= send-pr; };
+host_modules= { module= shellutils; };
+host_modules= { module= sid; };
+host_modules= { module= sim; };
+host_modules= { module= tar; };
+host_modules= { module= texinfo; no_install= true; };
+host_modules= { module= textutils; };
+host_modules= { module= time; };
+host_modules= { module= uudecode; };
+host_modules= { module= wdiff; };
+host_modules= { module= zip; no_check_cross=true; };
+host_modules= { module= zlib; no_install=true; no_check=true; };
+host_modules= { module= gdb; with_x=true; };
+host_modules= { module= expect; with_x=true; };
+host_modules= { module= guile; with_x=true; };
+host_modules= { module= tk; with_x=true; };
+host_modules= { module= tix; with_x=true; };
+host_modules= { module= libtermcap; no_check=true;
+ missing=mostlyclean;
+ missing=clean;
+ missing=distclean;
+ missing=maintainer-clean; };
+host_modules= { module= utils; no_check=true; };
+
+target_modules = { module= libstdc++-v3; raw_cxx=true; };
+target_modules = { module= newlib; };
+target_modules = { module= libf2c; };
+target_modules = { module= libobjc; };
+target_modules = { module= libtermcap; no_check=true; stage=true;
+ missing=mostlyclean;
+ missing=clean;
+ missing=distclean;
+ missing=maintainer-clean; };
+target_modules = { module= winsup; };
+target_modules = { module= libgloss; no_check=true; };
+target_modules = { module= libiberty; };
+target_modules = { module= gperf; };
+target_modules = { module= examples; no_check=true; no_install=true; };
+target_modules = { module= libffi; };
+target_modules = { module= libjava; raw_cxx=true; };
+target_modules = { module= zlib; stage=true; };
+target_modules = { module= boehm-gc; };
+target_modules = { module= qthreads; };
+target_modules = { module= rda; };
+target_modules = { module= libada; };
+
+// These are (some of) the make targets to be done in each subdirectory.
+// Not all; these are the ones which don't have special options.
+// "depend" indicates that a target depends on another target uniformly
+// for each subdirectory. There can be several such lines per target.
+recursive_targets = { make_target= info;
+ depend=configure; };
+recursive_targets = { make_target= dvi;
+ depend=configure; };
+recursive_targets = { make_target= TAGS;
+ depend=configure; };
+recursive_targets = { make_target= install-info;
+ depend=configure;
+ depend=info; };
+recursive_targets = { make_target= installcheck;
+ depend=configure; };
+recursive_targets = { make_target= mostlyclean; };
+recursive_targets = { make_target= clean; };
+recursive_targets = { make_target= distclean; };
+recursive_targets = { make_target= maintainer-clean; };
+
+// Flags which need to be passed down.
+
+// Directories etc.
+flags_to_pass = { flag= DESTDIR ; };
+flags_to_pass = { flag= RPATH_ENVVAR ; };
+flags_to_pass = { flag= TARGET_SUBDIR ; };
+flags_to_pass = { flag= bindir ; };
+flags_to_pass = { flag= datadir ; };
+flags_to_pass = { flag= exec_prefix ; };
+flags_to_pass = { flag= includedir ; };
+flags_to_pass = { flag= infodir ; };
+flags_to_pass = { flag= libdir ; };
+flags_to_pass = { flag= libexecdir ; };
+flags_to_pass = { flag= lispdir ; };
+flags_to_pass = { flag= libstdcxx_incdir ; };
+flags_to_pass = { flag= libsubdir ; };
+flags_to_pass = { flag= localstatedir ; };
+flags_to_pass = { flag= mandir ; };
+flags_to_pass = { flag= oldincludedir ; };
+flags_to_pass = { flag= prefix ; };
+flags_to_pass = { flag= sbindir ; };
+flags_to_pass = { flag= sharedstatedir ; };
+flags_to_pass = { flag= sysconfdir ; };
+flags_to_pass = { flag= tooldir ; };
+flags_to_pass = { flag= build_tooldir ; };
+flags_to_pass = { flag= gxx_include_dir ; };
+flags_to_pass = { flag= gcc_version ; };
+flags_to_pass = { flag= gcc_version_trigger ; };
+flags_to_pass = { flag= target_alias ; };
+
+// Build tools
+flags_to_pass = { flag= BISON ; };
+flags_to_pass = { flag= CC_FOR_BUILD ; };
+flags_to_pass = { flag= CXX_FOR_BUILD ; };
+flags_to_pass = { flag= EXPECT ; };
+flags_to_pass = { flag= INSTALL ; };
+flags_to_pass = { flag= INSTALL_DATA ; };
+flags_to_pass = { flag= INSTALL_PROGRAM ; };
+flags_to_pass = { flag= INSTALL_SCRIPT ; };
+flags_to_pass = { flag= LEX ; };
+flags_to_pass = { flag= M4 ; };
+flags_to_pass = { flag= MAKE ; };
+flags_to_pass = { flag= RUNTEST ; };
+flags_to_pass = { flag= RUNTESTFLAGS ; };
+flags_to_pass = { flag= SHELL ; };
+flags_to_pass = { flag= YACC ; };
+
+// Host tools
+flags_to_pass = { flag= AR_FLAGS ; };
+flags_to_pass = { flag= CFLAGS ; };
+flags_to_pass = { flag= CXXFLAGS ; };
+flags_to_pass = { flag= LDFLAGS ; };
+flags_to_pass = { flag= LIBCFLAGS ; };
+flags_to_pass = { flag= LIBCXXFLAGS ; };
+
+// Target tools
+flags_to_pass = { flag= AR_FOR_TARGET ; };
+flags_to_pass = { flag= AS_FOR_TARGET ; };
+flags_to_pass = { flag= CC_FOR_TARGET ; };
+flags_to_pass = { flag= CFLAGS_FOR_TARGET ; };
+flags_to_pass = { flag= CXX_FOR_TARGET ; };
+flags_to_pass = { flag= CXXFLAGS_FOR_TARGET ; };
+flags_to_pass = { flag= DLLTOOL_FOR_TARGET ; };
+flags_to_pass = { flag= GCJ_FOR_TARGET ; };
+flags_to_pass = { flag= LD_FOR_TARGET ; };
+flags_to_pass = { flag= LIBCFLAGS_FOR_TARGET ; };
+flags_to_pass = { flag= LIBCXXFLAGS_FOR_TARGET ; };
+flags_to_pass = { flag= NM_FOR_TARGET ; };
+flags_to_pass = { flag= RANLIB_FOR_TARGET ; };
+flags_to_pass = { flag= WINDRES_FOR_TARGET ; };
diff --git a/contrib/binutils/Makefile.in b/contrib/binutils/Makefile.in
index c3caa1d..2acda01 100644
--- a/contrib/binutils/Makefile.in
+++ b/contrib/binutils/Makefile.in
@@ -1,7 +1,9 @@
+
+# Makefile.in is generated from Makefile.tpl by 'autogen Makefile.def'.
#
# Makefile for directory with subdirs to build.
# Copyright (C) 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
-# 1999, 2000, 2001, 2002 Free Software Foundation
+# 1999, 2000, 2001, 2002, 2003 Free Software Foundation
#
# This file is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -18,36 +20,37 @@
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
-# Tell GNU make 3.79 not to run the top level in parallel. This
-# prevents contention for $builddir/$target/config.cache, as well
-# as minimizing scatter in file system caches.
-NOTPARALLEL = .NOTPARALLEL
-$(NOTPARALLEL):
-
-srcdir = .
+# -------------------------------
+# Standard Autoconf-set variables
+# -------------------------------
+VPATH=@srcdir@
-prefix = /usr/local
-exec_prefix = $(prefix)
+build_alias=@build_alias@
+build=@build@
+host_alias=@host_alias@
+host=@host@
+target_alias=@target_alias@
+target=@target@
-bindir=${exec_prefix}/bin
-sbindir=${exec_prefix}/sbin
-libexecdir=${exec_prefix}/libexec
-datadir=${prefix}/share
-sysconfdir=${prefix}/etc
-sharedstatedir=${prefix}/com
-localstatedir=${prefix}/var
-libdir=${exec_prefix}/lib
-includedir=${prefix}/include
-oldincludedir=/usr/include
-infodir=${prefix}/info
-mandir=${prefix}/man
-gxx_include_dir=${includedir}/g++
+program_transform_name = @program_transform_name@
-tooldir = $(exec_prefix)/$(target_alias)
-build_tooldir = $(exec_prefix)/$(target_alias)
+prefix = @prefix@
+exec_prefix = @exec_prefix@
-program_transform_name =
+srcdir = @srcdir@
+bindir = @bindir@
+sbindir = @sbindir@
+libexecdir = @libexecdir@
+datadir = @datadir@
+sysconfdir = @sysconfdir@
+sharedstatedir = @sharedstatedir@
+localstatedir = @localstatedir@
+libdir = @libdir@
+includedir = @includedir@
+oldincludedir = @oldincludedir@
+infodir = @infodir@
+mandir = @mandir@
man1dir = $(mandir)/man1
man2dir = $(mandir)/man2
man3dir = $(mandir)/man3
@@ -57,88 +60,107 @@ man6dir = $(mandir)/man6
man7dir = $(mandir)/man7
man8dir = $(mandir)/man8
man9dir = $(mandir)/man9
-infodir = $(prefix)/info
-includedir = $(prefix)/include
-# Directory in which the compiler finds executables, libraries, etc.
-libsubdir = $(libdir)/gcc-lib/$(target_alias)/$(gcc_version)
-GDB_NLM_DEPS =
-SHELL = /bin/sh
+INSTALL = @INSTALL@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_DATA = @INSTALL_DATA@
-# pwd command to use. Allow user to override default by setting PWDCMD in
-# the environment to account for automounters. The make variable must not
-# be called PWDCMD, otherwise the value set here is passed to make
-# subprocesses and overrides the setting from the user's environment.
-PWD = $${PWDCMD-pwd}
+# -------------------------------------------------
+# Miscellaneous non-standard autoconf-set variables
+# -------------------------------------------------
-# INSTALL_PROGRAM_ARGS is changed by configure.in to use -x for a
-# cygwin host.
-INSTALL_PROGRAM_ARGS =
+links=@configlinks@
+# The file containing GCC's version number.
+gcc_version_trigger = @gcc_version_trigger@
+gcc_version = @gcc_version@
-INSTALL = $(SHELL) $$s/install-sh -c
-INSTALL_PROGRAM = $(INSTALL) $(INSTALL_PROGRAM_ARGS)
-INSTALL_SCRIPT = $(INSTALL)
-INSTALL_DATA = $(INSTALL) -m 644
+# The gcc driver likes to know the arguments it was configured with.
+TOPLEVEL_CONFIGURE_ARGUMENTS=@TOPLEVEL_CONFIGURE_ARGUMENTS@
-INSTALL_DOSREL = install-dosrel-fake
+gxx_include_dir = @gxx_include_dir@
+libstdcxx_incdir = @libstdcxx_incdir@
-AS = as
-AR = ar
-AR_FLAGS = rc
-CC = cc
+tooldir = @tooldir@
+build_tooldir = @build_tooldir@
-# Special variables passed down in EXTRA_GCC_FLAGS. They are defined
-# here so that they can be overridden by Makefile fragments.
-HOST_CC = $(CC_FOR_BUILD)
-BUILD_PREFIX =
-BUILD_PREFIX_1 = loser-
+# Directory in which the compiler finds executables, libraries, etc.
+libsubdir = $(libdir)/gcc/$(target_alias)/$(gcc_version)
+GDB_NLM_DEPS =
-# These flag values are normally overridden by the configure script.
-CFLAGS = -g
-CXXFLAGS = -g -O2
+# This is the name of the environment variable used for the path to
+# the libraries.
+RPATH_ENVVAR = @RPATH_ENVVAR@
-LDFLAGS =
-LIBCFLAGS = $(CFLAGS)
-CFLAGS_FOR_BUILD = $(CFLAGS)
-# During gcc bootstrap, if we use some random cc for stage1 then
-# CFLAGS will be just -g. We want to ensure that TARGET libraries
-# (which we know are built with gcc) are built with optimizations so
-# prepend -O2 when setting CFLAGS_FOR_TARGET.
-CFLAGS_FOR_TARGET = -O2 $(CFLAGS)
-LDFLAGS_FOR_TARGET =
-LIBCFLAGS_FOR_TARGET = $(CFLAGS_FOR_TARGET)
-PICFLAG =
-PICFLAG_FOR_TARGET =
+# This is set by configure to REALLY_SET_LIB_PATH if --enable-shared
+# was used.
+SET_LIB_PATH = @SET_LIB_PATH@
-CXX = c++
+# configure.in sets SET_LIB_PATH to this if --enable-shared was used.
+# Some platforms don't like blank entries, so we remove duplicate,
+# leading and trailing colons.
+REALLY_SET_LIB_PATH = \
+ $(RPATH_ENVVAR)=`echo "$(HOST_LIB_PATH):$(TARGET_LIB_PATH):$$$(RPATH_ENVVAR)" | sed 's,::*,:,g;s,^:*,,;s,:*$$,,'`; export $(RPATH_ENVVAR);
-# Use -O2 to stress test the compiler.
-LIBCXXFLAGS = $(CXXFLAGS) -fno-implicit-templates
-CXXFLAGS_FOR_TARGET = $(CXXFLAGS)
-LIBCXXFLAGS_FOR_TARGET = $(CXXFLAGS_FOR_TARGET) -fno-implicit-templates
+# This is the list of directories to be built for the build system.
+BUILD_CONFIGDIRS = libiberty
+# Build programs are put under this directory.
+BUILD_SUBDIR = @build_subdir@
+# This is set by the configure script to the arguments to use when configuring
+# directories built for the build system.
+BUILD_CONFIGARGS = @build_configargs@
+
+# This is the list of directories to built for the host system.
+SUBDIRS = @configdirs@
+# This is set by the configure script to the arguments to use when configuring
+# directories built for the host system.
+HOST_CONFIGARGS = @host_configargs@
+
+# This is set by the configure script to the list of directories which
+# should be built using the target tools.
+TARGET_CONFIGDIRS = @target_configdirs@
+# Target libraries are put under this directory:
+TARGET_SUBDIR = @target_subdir@
+# This is set by the configure script to the arguments to use when configuring
+# directories built for the target.
+TARGET_CONFIGARGS = @target_configargs@
-DLLTOOL = dlltool
-WINDRES = windres
+# ----------------------------------------------
+# Programs producing files for the BUILD machine
+# ----------------------------------------------
-NM = nm
+SHELL = @config_shell@
-LD = ld
+# pwd command to use. Allow user to override default by setting PWDCMD in
+# the environment to account for automounters. The make variable must not
+# be called PWDCMD, otherwise the value set here is passed to make
+# subprocesses and overrides the setting from the user's environment.
+# Don't use PWD since it is a common shell environment variable and we
+# don't want to corrupt it.
+PWD_COMMAND = $${PWDCMD-pwd}
-BZIPPROG = bzip2
-MD5PROG = md5sum
+# compilers to use to create programs which must be run in the build
+# environment.
+CC_FOR_BUILD = @CC_FOR_BUILD@
+CFLAGS_FOR_BUILD = @CFLAGS_FOR_BUILD@
-# These values are substituted by configure.
-DEFAULT_YACC = yacc
-DEFAULT_LEX = lex
-DEFAULT_M4 = m4
+CXX_FOR_BUILD = $(CXX)
-BISON = `if [ -f $$r/bison/bison ] ; then \
+# Special variables passed down in EXTRA_GCC_FLAGS. They are defined
+# here so that they can be overridden by Makefile fragments.
+BUILD_PREFIX = @BUILD_PREFIX@
+BUILD_PREFIX_1 = @BUILD_PREFIX_1@
+
+BISON=@BISON@
+USUAL_BISON = `if [ -f $$r/bison/bison ] ; then \
echo $$r/bison/bison -L $$s/bison/ ; \
else \
echo bison ; \
fi`
-YACC = `if [ -f $$r/bison/bison ] ; then \
+DEFAULT_YACC = @DEFAULT_YACC@
+YACC=@YACC@
+USUAL_YACC = `if [ -f $$r/bison/bison ] ; then \
echo $$r/bison/bison -y -L $$s/bison/ ; \
elif [ -f $$r/byacc/byacc ] ; then \
echo $$r/byacc/byacc ; \
@@ -146,26 +168,31 @@ YACC = `if [ -f $$r/bison/bison ] ; then \
echo ${DEFAULT_YACC} ; \
fi`
-LEX = `if [ -f $$r/flex/flex ] ; \
+DEFAULT_LEX = @DEFAULT_LEX@
+LEX=@LEX@
+USUAL_LEX = `if [ -f $$r/flex/flex ] ; \
then echo $$r/flex/flex ; \
else echo ${DEFAULT_LEX} ; fi`
+DEFAULT_M4 = @DEFAULT_M4@
M4 = `if [ -f $$r/m4/m4 ] ; \
then echo $$r/m4/m4 ; \
else echo ${DEFAULT_M4} ; fi`
-# For an installed makeinfo, we require it to be from texinfo 4 or
+# For an installed makeinfo, we require it to be from texinfo 4.2 or
# higher, else we use the "missing" dummy.
-MAKEINFO = `if [ -f $$r/texinfo/makeinfo/makeinfo ] ; \
+MAKEINFO=@MAKEINFO@
+USUAL_MAKEINFO = `if [ -f $$r/texinfo/makeinfo/makeinfo ] ; \
then echo $$r/texinfo/makeinfo/makeinfo ; \
else if (makeinfo --version \
- | egrep 'texinfo[^0-9]*([1-3][0-9]|[4-9])') >/dev/null 2>&1; \
+ | egrep 'texinfo[^0-9]*([1-3][0-9]|4\.[2-9]|[5-9])') >/dev/null 2>&1; \
then echo makeinfo; else echo $$s/missing makeinfo; fi; fi`
# This just becomes part of the MAKEINFO definition passed down to
# sub-makes. It lets flags be given on the command line while still
# using the makeinfo from the object tree.
-MAKEINFOFLAGS =
+# (Default to avoid splitting info files by setting the threshold high.)
+MAKEINFOFLAGS = --split-size=5000000
EXPECT = `if [ -f $$r/expect/expect ] ; \
then echo $$r/expect/expect ; \
@@ -175,227 +202,192 @@ RUNTEST = `if [ -f $$s/dejagnu/runtest ] ; \
then echo $$s/dejagnu/runtest ; \
else echo runtest ; fi`
+# ---------------------------------------------
+# Programs producing files for the HOST machine
+# ---------------------------------------------
-# compilers to use to create programs which must be run in the build
-# environment.
-CC_FOR_BUILD = $(CC)
-CXX_FOR_BUILD = $(CXX)
+# This is the list of directories that may be needed in RPATH_ENVVAR
+# so that programs built for the host machine work.
+HOST_LIB_PATH = $$r/bfd:$$r/opcodes
-SUBDIRS = "this is set via configure, don't edit this"
-OTHERS =
+AS = @AS@
-# This is set by the configure script to the list of directories which
-# should be built using the target tools.
-TARGET_CONFIGDIRS = libiberty libgloss $(SPECIAL_LIBS) newlib winsup opcodes libf2c libobjc
+AR = @AR@
+AR_FLAGS = rc
-# Target libraries are put under this directory:
-# Changed by configure to $(target_alias) if cross.
-TARGET_SUBDIR = .
+CC = @CC@
+CFLAGS = @CFLAGS@
+LIBCFLAGS = $(CFLAGS)
-BUILD_CONFIGDIRS = libiberty
-BUILD_SUBDIR = .
+CXX = @CXX@
+CXXFLAGS = @CXXFLAGS@
+LIBCXXFLAGS = $(CXXFLAGS) -fno-implicit-templates
-# This is set by the configure script to the arguments to use when configuring
-# directories built for the target.
-TARGET_CONFIGARGS =
+DLLTOOL = @DLLTOOL@
-# This is set by the configure script to the arguments to use when configuring
-# directories built for the build system.
-BUILD_CONFIGARGS =
+NM = @NM@
-# This is set by configure to REALLY_SET_LIB_PATH if --enable-shared
-# was used.
-SET_LIB_PATH =
+LD = @LD@
+LDFLAGS =
-# This is the name of the environment variable used for the path to
-# the libraries. This may be changed by configure.in.
-RPATH_ENVVAR = LD_LIBRARY_PATH
+RANLIB = @RANLIB@
-# This is the list of directories that may be needed in RPATH_ENVVAR
-# so that programs built for the host machine work.
-HOST_LIB_PATH = $$r/bfd:$$r/opcodes
+WINDRES = @WINDRES@
+
+PICFLAG =
+
+# -----------------------------------------------
+# Programs producing files for the TARGET machine
+# -----------------------------------------------
# This is the list of directories that may be needed in RPATH_ENVVAR
# so that prorgams built for the target machine work.
TARGET_LIB_PATH = $$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs:
-# configure.in sets SET_LIB_PATH to this if --enable-shared was used.
-# Some platforms don't like blank entries, so we remove duplicate,
-# leading and trailing colons.
-REALLY_SET_LIB_PATH = \
- $(RPATH_ENVVAR)=`echo "$(HOST_LIB_PATH):$(TARGET_LIB_PATH):$$$(RPATH_ENVVAR)" | sed 's,::*,:,g;s,^:*,,;s,:*$$,,'`; export $(RPATH_ENVVAR);
-
-ALL = all.normal
-INSTALL_TARGET = installdirs \
- install-gcc \
- $(INSTALL_MODULES) \
- $(INSTALL_TARGET_MODULES) \
- $(INSTALL_X11_MODULES) \
- $(INSTALL_DOSREL)
-
-INSTALL_TARGET_CROSS = installdirs \
- install-gcc-cross \
- $(INSTALL_MODULES) \
- $(INSTALL_TARGET_MODULES) \
- $(INSTALL_X11_MODULES) \
- $(INSTALL_DOSREL)
-
-# Should be substed by configure.in
-FLAGS_FOR_TARGET =
-CC_FOR_TARGET =
-CXX_FOR_TARGET =
-CXX_FOR_TARGET_FOR_RECURSIVE_MAKE =
-GCJ_FOR_TARGET =
+FLAGS_FOR_TARGET = @FLAGS_FOR_TARGET@
-# If GCC_FOR_TARGET is not overriden on the command line, then this
-# variable is passed down to the gcc Makefile, where it is used to
-# build libgcc2.a. We define it here so that it can itself be
-# overridden on the command line.
-GCC_FOR_TARGET = $$r/gcc/xgcc -B$$r/gcc/ $(FLAGS_FOR_TARGET)
+AR_FOR_TARGET=@AR_FOR_TARGET@
+USUAL_AR_FOR_TARGET = ` \
+ if [ -f $$r/binutils/ar ] ; then \
+ echo $$r/binutils/ar ; \
+ else \
+ if [ '$(host)' = '$(target)' ] ; then \
+ echo $(AR); \
+ else \
+ echo ar | sed '$(program_transform_name)' ; \
+ fi; \
+ fi`
-AS_FOR_TARGET = ` \
+AS_FOR_TARGET=@AS_FOR_TARGET@
+USUAL_AS_FOR_TARGET = ` \
if [ -f $$r/gas/as-new ] ; then \
echo $$r/gas/as-new ; \
elif [ -f $$r/gcc/xgcc ]; then \
$(CC_FOR_TARGET) -print-prog-name=as ; \
else \
- if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
+ if [ '$(host)' = '$(target)' ] ; then \
echo $(AS); \
else \
- t='$(program_transform_name)'; echo as | sed -e 's/x/x/' $$t ; \
+ echo as | sed '$(program_transform_name)' ; \
fi; \
fi`
-LD_FOR_TARGET = ` \
- if [ -f $$r/ld/ld-new ] ; then \
- echo $$r/ld/ld-new ; \
- elif [ -f $$r/gcc/xgcc ]; then \
- $(CC_FOR_TARGET) -print-prog-name=ld ; \
- else \
- if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
- echo $(LD); \
- else \
- t='$(program_transform_name)'; echo ld | sed -e 's/x/x/' $$t ; \
- fi; \
- fi`
+CC_FOR_TARGET = @CC_FOR_TARGET@
+# During gcc bootstrap, if we use some random cc for stage1 then
+# CFLAGS will be just -g. We want to ensure that TARGET libraries
+# (which we know are built with gcc) are built with optimizations so
+# prepend -O2 when setting CFLAGS_FOR_TARGET.
+CFLAGS_FOR_TARGET = -O2 $(CFLAGS)
+# If GCC_FOR_TARGET is not overriden on the command line, then this
+# variable is passed down to the gcc Makefile, where it is used to
+# build libgcc2.a. We define it here so that it can itself be
+# overridden on the command line.
+GCC_FOR_TARGET=@GCC_FOR_TARGET@
+USUAL_GCC_FOR_TARGET = $(STAGE_CC_WRAPPER) $$r/gcc/xgcc -B$$r/gcc/ $(FLAGS_FOR_TARGET)
+LIBCFLAGS_FOR_TARGET = $(CFLAGS_FOR_TARGET)
-DLLTOOL_FOR_TARGET = ` \
+CXX_FOR_TARGET = @CXX_FOR_TARGET@
+RAW_CXX_FOR_TARGET = @RAW_CXX_FOR_TARGET@
+CXX_FOR_TARGET_FOR_RECURSIVE_MAKE = @CXX_FOR_TARGET_FOR_RECURSIVE_MAKE@
+RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE = @RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE@
+CXXFLAGS_FOR_TARGET = $(CXXFLAGS)
+LIBCXXFLAGS_FOR_TARGET = $(CXXFLAGS_FOR_TARGET) -fno-implicit-templates
+
+DLLTOOL_FOR_TARGET=@DLLTOOL_FOR_TARGET@
+USUAL_DLLTOOL_FOR_TARGET = ` \
if [ -f $$r/binutils/dlltool ] ; then \
echo $$r/binutils/dlltool ; \
else \
- if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
+ if [ '$(host)' = '$(target)' ] ; then \
echo $(DLLTOOL); \
else \
- t='$(program_transform_name)'; echo dlltool | sed -e 's/x/x/' $$t ; \
+ echo dlltool | sed '$(program_transform_name)' ; \
fi; \
fi`
-WINDRES_FOR_TARGET = ` \
- if [ -f $$r/binutils/windres ] ; then \
- echo $$r/binutils/windres ; \
+GCJ_FOR_TARGET = @GCJ_FOR_TARGET@
+
+LD_FOR_TARGET=@LD_FOR_TARGET@
+USUAL_LD_FOR_TARGET = ` \
+ if [ -f $$r/ld/ld-new ] ; then \
+ echo $$r/ld/ld-new ; \
+ elif [ -f $$r/gcc/xgcc ]; then \
+ $(CC_FOR_TARGET) -print-prog-name=ld ; \
else \
- if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
- echo $(WINDRES); \
+ if [ '$(host)' = '$(target)' ] ; then \
+ echo $(LD); \
else \
- t='$(program_transform_name)'; echo windres | sed -e 's/x/x/' $$t ; \
+ echo ld | sed '$(program_transform_name)' ; \
fi; \
fi`
-AR_FOR_TARGET = ` \
- if [ -f $$r/binutils/ar ] ; then \
- echo $$r/binutils/ar ; \
+LDFLAGS_FOR_TARGET =
+
+NM_FOR_TARGET=@NM_FOR_TARGET@
+USUAL_NM_FOR_TARGET = ` \
+ if [ -f $$r/binutils/nm-new ] ; then \
+ echo $$r/binutils/nm-new ; \
+ elif [ -f $$r/gcc/xgcc ]; then \
+ $(CC_FOR_TARGET) -print-prog-name=nm ; \
else \
- if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
- echo $(AR); \
+ if [ '$(host)' = '$(target)' ] ; then \
+ echo $(NM); \
else \
- t='$(program_transform_name)'; echo ar | sed -e 's/x/x/' $$t ; \
+ echo nm | sed '$(program_transform_name)' ; \
fi; \
fi`
-RANLIB_FOR_TARGET = ` \
+RANLIB_FOR_TARGET=@RANLIB_FOR_TARGET@
+USUAL_RANLIB_FOR_TARGET = ` \
if [ -f $$r/binutils/ranlib ] ; then \
echo $$r/binutils/ranlib ; \
else \
- if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
+ if [ '$(host)' = '$(target)' ] ; then \
if [ x'$(RANLIB)' != x ]; then \
echo $(RANLIB); \
else \
echo ranlib; \
fi; \
else \
- t='$(program_transform_name)'; echo ranlib | sed -e 's/x/x/' $$t ; \
+ echo ranlib | sed '$(program_transform_name)' ; \
fi; \
fi`
-NM_FOR_TARGET = ` \
- if [ -f $$r/binutils/nm-new ] ; then \
- echo $$r/binutils/nm-new ; \
- elif [ -f $$r/gcc/xgcc ]; then \
- $(CC_FOR_TARGET) -print-prog-name=nm ; \
+WINDRES_FOR_TARGET=@WINDRES_FOR_TARGET@
+USUAL_WINDRES_FOR_TARGET = ` \
+ if [ -f $$r/binutils/windres ] ; then \
+ echo $$r/binutils/windres ; \
else \
- if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
- echo $(NM); \
+ if [ '$(host)' = '$(target)' ] ; then \
+ echo $(WINDRES); \
else \
- t='$(program_transform_name)'; echo nm | sed -e 's/x/x/' $$t ; \
+ echo windres | sed '$(program_transform_name)' ; \
fi; \
fi`
+PICFLAG_FOR_TARGET =
+
+# ------------------------------------
+# Miscellaneous targets and flag lists
+# ------------------------------------
+
# The first rule in the file had better be this one. Don't put any above it.
# This lives here to allow makefile fragments to contain dependencies.
all: all.normal
.PHONY: all
-# These can be overridden by config/mt-*.
-# The _TARGET_ is because they're specified in mt-foo.
-# The _HOST_ is because they're programs that run on the host.
-EXTRA_TARGET_HOST_ALL_MODULES =
-EXTRA_TARGET_HOST_INSTALL_MODULES =
-EXTRA_TARGET_HOST_CHECK_MODULES =
-
#### host and target specific makefile fragments come in here.
+@target_makefile_frag@
+@alphaieee_frag@
+@ospace_frag@
+@host_makefile_frag@
###
# Flags to pass down to all sub-makes.
-# Please keep these in alphabetical order.
BASE_FLAGS_TO_PASS = \
- "AR_FLAGS=$(AR_FLAGS)" \
- "AR_FOR_TARGET=$(AR_FOR_TARGET)" \
- "AS_FOR_TARGET=$(AS_FOR_TARGET)" \
- "BISON=$(BISON)" \
- "CC_FOR_BUILD=$(CC_FOR_BUILD)" \
- "CC_FOR_TARGET=$(CC_FOR_TARGET)" \
- "CFLAGS=$(CFLAGS)" \
- "CFLAGS_FOR_TARGET=$(CFLAGS_FOR_TARGET)" \
- "GCJ_FOR_TARGET=$(GCJ_FOR_TARGET)" \
- "CXX_FOR_BUILD=$(CXX_FOR_BUILD)" \
- "CXXFLAGS=$(CXXFLAGS)" \
- "CXXFLAGS_FOR_TARGET=$(CXXFLAGS_FOR_TARGET)" \
- "CXX_FOR_TARGET=$(CXX_FOR_TARGET)" \
- "DLLTOOL_FOR_TARGET=$(DLLTOOL_FOR_TARGET)" \
- "INSTALL=$(INSTALL)" \
- "INSTALL_DATA=$(INSTALL_DATA)" \
- "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
- "INSTALL_SCRIPT=$(INSTALL_SCRIPT)" \
- "LDFLAGS=$(LDFLAGS)" \
- "LEX=$(LEX)" \
- "LD_FOR_TARGET=$(LD_FOR_TARGET)" \
- "LIBCFLAGS=$(LIBCFLAGS)" \
- "LIBCFLAGS_FOR_TARGET=$(LIBCFLAGS_FOR_TARGET)" \
- "LIBCXXFLAGS=$(LIBCXXFLAGS)" \
- "LIBCXXFLAGS_FOR_TARGET=$(LIBCXXFLAGS_FOR_TARGET)" \
- "M4=$(M4)" \
- "MAKE=$(MAKE)" \
- "MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)" \
- "NM_FOR_TARGET=$(NM_FOR_TARGET)" \
- "RANLIB_FOR_TARGET=$(RANLIB_FOR_TARGET)" \
+ "DESTDIR=$(DESTDIR)" \
"RPATH_ENVVAR=$(RPATH_ENVVAR)" \
- "SHELL=$(SHELL)" \
- "EXPECT=$(EXPECT)" \
- "RUNTEST=$(RUNTEST)" \
- "RUNTESTFLAGS=$(RUNTESTFLAGS)" \
"TARGET_SUBDIR=$(TARGET_SUBDIR)" \
- "WINDRES_FOR_TARGET=$(WINDRES_FOR_TARGET)" \
- "YACC=$(YACC)" \
"bindir=$(bindir)" \
"datadir=$(datadir)" \
"exec_prefix=$(exec_prefix)" \
@@ -418,7 +410,44 @@ BASE_FLAGS_TO_PASS = \
"gxx_include_dir=$(gxx_include_dir)" \
"gcc_version=$(gcc_version)" \
"gcc_version_trigger=$(gcc_version_trigger)" \
- "target_alias=$(target_alias)"
+ "target_alias=$(target_alias)" \
+ "BISON=$(BISON)" \
+ "CC_FOR_BUILD=$(CC_FOR_BUILD)" \
+ "CXX_FOR_BUILD=$(CXX_FOR_BUILD)" \
+ "EXPECT=$(EXPECT)" \
+ "INSTALL=$(INSTALL)" \
+ "INSTALL_DATA=$(INSTALL_DATA)" \
+ "INSTALL_PROGRAM=$(INSTALL_PROGRAM)" \
+ "INSTALL_SCRIPT=$(INSTALL_SCRIPT)" \
+ "LEX=$(LEX)" \
+ "M4=$(M4)" \
+ "MAKE=$(MAKE)" \
+ "RUNTEST=$(RUNTEST)" \
+ "RUNTESTFLAGS=$(RUNTESTFLAGS)" \
+ "SHELL=$(SHELL)" \
+ "YACC=$(YACC)" \
+ "AR_FLAGS=$(AR_FLAGS)" \
+ "CFLAGS=$(CFLAGS)" \
+ "CXXFLAGS=$(CXXFLAGS)" \
+ "LDFLAGS=$(LDFLAGS)" \
+ "LIBCFLAGS=$(LIBCFLAGS)" \
+ "LIBCXXFLAGS=$(LIBCXXFLAGS)" \
+ "AR_FOR_TARGET=$(AR_FOR_TARGET)" \
+ "AS_FOR_TARGET=$(AS_FOR_TARGET)" \
+ "CC_FOR_TARGET=$(CC_FOR_TARGET)" \
+ "CFLAGS_FOR_TARGET=$(CFLAGS_FOR_TARGET)" \
+ "CXX_FOR_TARGET=$(CXX_FOR_TARGET)" \
+ "CXXFLAGS_FOR_TARGET=$(CXXFLAGS_FOR_TARGET)" \
+ "DLLTOOL_FOR_TARGET=$(DLLTOOL_FOR_TARGET)" \
+ "GCJ_FOR_TARGET=$(GCJ_FOR_TARGET)" \
+ "LD_FOR_TARGET=$(LD_FOR_TARGET)" \
+ "LIBCFLAGS_FOR_TARGET=$(LIBCFLAGS_FOR_TARGET)" \
+ "LIBCXXFLAGS_FOR_TARGET=$(LIBCXXFLAGS_FOR_TARGET)" \
+ "NM_FOR_TARGET=$(NM_FOR_TARGET)" \
+ "RANLIB_FOR_TARGET=$(RANLIB_FOR_TARGET)" \
+ "WINDRES_FOR_TARGET=$(WINDRES_FOR_TARGET)" \
+ "CONFIG_SHELL=$(SHELL)" \
+ "MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)"
# For any flags above that may contain shell code that varies from one
# target library to another. When doing recursive invocations of the
@@ -426,11 +455,11 @@ BASE_FLAGS_TO_PASS = \
# so we pass these variables down unchanged. They must not contain
# single nor double quotes.
RECURSE_FLAGS = \
- CXX_FOR_TARGET='$(CXX_FOR_TARGET_FOR_RECURSIVE_MAKE)'
+ CXX_FOR_TARGET='$(CXX_FOR_TARGET_FOR_RECURSIVE_MAKE)' \
+ RAW_CXX_FOR_TARGET='$(RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE)' \
# Flags to pass down to most sub-makes, in which we're building with
# the host environment.
-# If any variables are added here, they must be added to do-*, below.
EXTRA_HOST_FLAGS = \
'AR=$(AR)' \
'AS=$(AS)' \
@@ -439,7 +468,7 @@ EXTRA_HOST_FLAGS = \
'DLLTOOL=$(DLLTOOL)' \
'LD=$(LD)' \
'NM=$(NM)' \
- "`echo 'RANLIB=$(RANLIB)' | sed -e s/.*=$$/XFOO=/`" \
+ 'RANLIB=$(RANLIB)' \
'WINDRES=$(WINDRES)'
FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_HOST_FLAGS)
@@ -459,7 +488,6 @@ X11_FLAGS_TO_PASS = \
# Flags to pass down to makes which are built with the target environment.
# The double $ decreases the length of the command line; the variables
# are set in BASE_FLAGS_TO_PASS, and the sub-make will expand them.
-# If any variables are added here, they must be added to do-*, below.
EXTRA_TARGET_FLAGS = \
'AR=$$(AR_FOR_TARGET)' \
'AS=$$(AS_FOR_TARGET)' \
@@ -481,20 +509,11 @@ TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)
# unfortunately needs the native compiler and the target ar and
# ranlib.
# If any variables are added here, they must be added to do-*, below.
-# The HOST_* variables are a special case, which are used for the gcc
+# The BUILD_* variables are a special case, which are used for the gcc
# cross-building scheme.
EXTRA_GCC_FLAGS = \
- 'AR=$(AR)' \
- 'AS=$(AS)' \
- 'CC=$(CC)' \
- 'CXX=$(CXX)' \
- 'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
- 'HOST_CC=$(CC_FOR_BUILD)' \
'BUILD_PREFIX=$(BUILD_PREFIX)' \
'BUILD_PREFIX_1=$(BUILD_PREFIX_1)' \
- 'NM=$(NM)' \
- "`echo 'RANLIB=$(RANLIB)' | sed -e s/.*=$$/XFOO=/`" \
- 'WINDRES=$$(WINDRES_FOR_TARGET)' \
"GCC_FOR_TARGET=$(GCC_FOR_TARGET)" \
"CFLAGS_FOR_BUILD=$(CFLAGS_FOR_BUILD)" \
"`echo 'LANGUAGES=$(LANGUAGES)' | sed -e s/.*=$$/XFOO=/`" \
@@ -503,489 +522,16912 @@ EXTRA_GCC_FLAGS = \
"`echo 'LIBGCC2_CFLAGS=$(LIBGCC2_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
"`echo 'LIBGCC2_DEBUG_CFLAGS=$(LIBGCC2_DEBUG_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
"`echo 'LIBGCC2_INCLUDES=$(LIBGCC2_INCLUDES)' | sed -e s/.*=$$/XFOO=/`" \
- "`echo 'ENQUIRE=$(ENQUIRE)' | sed -e s/.*=$$/XFOO=/`" \
"`echo 'STAGE1_CFLAGS=$(STAGE1_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
- "`echo 'BOOT_CFLAGS=$(BOOT_CFLAGS)' | sed -e s/.*=$$/XFOO=/`"
-
-GCC_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_GCC_FLAGS)
-
-# This is a list of the targets for all of the modules which are compiled
-# using the build machine's native compiler. Configure edits the second
-# macro for build!=host builds.
-ALL_BUILD_MODULES_LIST = \
- all-build-libiberty
-ALL_BUILD_MODULES =
-
-# This is a list of the configure targets for all of the modules which
-# are compiled using the native tools.
-CONFIGURE_BUILD_MODULES = \
- configure-build-libiberty
-
-# This is a list of the targets for all of the modules which are compiled
-# using $(FLAGS_TO_PASS).
-ALL_MODULES = \
- all-ash \
- all-autoconf \
- all-automake \
- all-bash \
- all-bfd \
- all-binutils \
- all-bison \
- all-byacc \
- all-bzip2 \
- all-db \
- all-dejagnu \
- all-diff \
- all-dosutils \
- all-etc \
- all-fastjar \
- all-fileutils \
- all-findutils \
- all-find \
- all-flex \
- all-gas \
- all-gawk \
- all-gettext \
- all-gnuserv \
- all-gprof \
- all-grep \
- all-gzip \
- all-hello \
- all-indent \
- all-intl \
- all-itcl \
- all-ld \
- all-libgui \
- all-libiberty \
- all-libtool \
- all-m4 \
- all-make \
- all-mmalloc \
- all-opcodes \
- all-patch \
- all-perl \
- all-prms \
- all-rcs \
- all-readline \
- all-release \
- all-recode \
- all-sed \
- all-send-pr \
- all-shellutils \
- all-sid \
- all-sim \
- all-snavigator \
- all-tar \
- all-tcl \
- all-texinfo \
- all-textutils \
- all-time \
- all-uudecode \
- all-wdiff \
- all-zip \
- all-zlib \
- $(EXTRA_TARGET_HOST_ALL_MODULES)
-
-# This is a list of the check targets for all of the modules which are
-# compiled using $(FLAGS_TO_PASS).
-#
-# The list is in two parts. The first lists those tools which
-# are tested as part of the host's native tool-chain, and not
-# tested in a cross configuration.
-NATIVE_CHECK_MODULES = \
- check-bison \
- check-byacc \
- check-fastjar \
- check-flex \
- check-zip
-
-CROSS_CHECK_MODULES = \
- check-ash \
- check-autoconf \
- check-automake \
- check-bash \
- check-bfd \
- check-binutils \
- check-bzip2 \
- check-db \
- check-dejagnu \
- check-diff \
- check-etc \
- check-fileutils \
- check-findutils \
- check-find \
- check-gas \
- check-gawk \
- check-gettext \
- check-gnuserv \
- check-gprof \
- check-grep \
- check-gzip \
- check-hello \
- check-indent \
- check-intl \
- check-itcl \
- check-ld \
- check-libgui \
- check-libiberty \
- check-libtool \
- check-m4 \
- check-make \
- check-mmcheckoc \
- check-opcodes \
- check-patch \
- check-perl \
- check-prms \
- check-rcs \
- check-readline \
- check-recode \
- check-sed \
- check-send-pr \
- check-shellutils \
- check-snavigator \
- check-sid \
- check-sim \
- check-tar \
- check-tcl \
- check-texinfo \
- check-textutils \
- check-time \
- check-uudecode \
- check-wdiff \
- $(EXTRA_TARGET_HOST_CHECK_MODULES)
-
-CHECK_MODULES=$(NATIVE_CHECK_MODULES) $(CROSS_CHECK_MODULES)
-
-# This is a list of the install targets for all of the modules which are
-# compiled using $(FLAGS_TO_PASS).
-# We put install-opcodes before install-binutils because the installed
-# binutils might be on PATH, and they might need the shared opcodes
-# library.
-# We put install-tcl before install-itcl because itcl wants to run a
-# program on installation which uses the Tcl libraries.
-INSTALL_MODULES = \
- install-ash \
- install-autoconf \
- install-automake \
- install-bash \
- install-bfd \
- install-bzip2 \
- install-opcodes \
- install-binutils \
- install-bison \
- install-byacc \
- install-db \
- install-dejagnu \
- install-diff \
- install-dosutils \
- install-etc \
- install-fastjar \
- install-fileutils \
- install-findutils \
- install-find \
- install-flex \
- install-gas \
- install-gawk \
- install-gettext \
- install-gnuserv \
- install-gprof \
- install-grep \
- install-gzip \
- install-hello \
- install-indent \
- install-intl \
- install-tcl \
- install-itcl \
- install-ld \
- install-libgui \
- install-libiberty \
- install-libtool \
- install-m4 \
- install-make \
- install-mmalloc \
- install-patch \
- install-perl \
- install-prms \
- install-rcs \
- install-readline \
- install-recode \
- install-sed \
- install-send-pr \
- install-shellutils \
- install-sid \
- install-sim \
- install-snavigator \
- install-tar \
- install-textutils \
- install-time \
- install-uudecode \
- install-wdiff \
- install-zip \
- $(EXTRA_TARGET_HOST_INSTALL_MODULES)
-
-# This is a list of the targets for all of the modules which are compiled
-# using $(X11_FLAGS_TO_PASS).
-ALL_X11_MODULES = \
- all-gdb \
- all-expect \
- all-guile \
- all-tclX \
- all-tk \
- all-tix
-
-# This is a list of the check targets for all of the modules which are
-# compiled using $(X11_FLAGS_TO_PASS).
-CHECK_X11_MODULES = \
- check-gdb \
- check-guile \
- check-expect \
- check-tclX \
- check-tk \
- check-tix
-
-# This is a list of the install targets for all the modules which are
-# compiled using $(X11_FLAGS_TO_PASS).
-INSTALL_X11_MODULES = \
- install-gdb \
- install-guile \
- install-expect \
- install-tclX \
- install-tk \
- install-tix
-
-# This is a list of the targets for all of the modules which are compiled
-# using $(TARGET_FLAGS_TO_PASS).
-ALL_TARGET_MODULES = \
- all-target-libstdc++-v3 \
- all-target-newlib \
- all-target-libf2c \
- all-target-libobjc \
- all-target-libtermcap \
- all-target-winsup \
- all-target-libgloss \
- all-target-libiberty \
- all-target-gperf \
- all-target-examples \
- all-target-libffi \
- all-target-libjava \
- all-target-zlib \
- all-target-boehm-gc \
- all-target-qthreads
-
-# This is a list of the configure targets for all of the modules which
-# are compiled using the target tools.
-CONFIGURE_TARGET_MODULES = \
- configure-target-libstdc++-v3 \
- configure-target-newlib \
- configure-target-libf2c \
- configure-target-libobjc \
- configure-target-libtermcap \
- configure-target-winsup \
- configure-target-libgloss \
- configure-target-libiberty \
- configure-target-gperf \
- configure-target-examples \
- configure-target-libffi \
- configure-target-libjava \
- configure-target-zlib \
- configure-target-boehm-gc \
- configure-target-qthreads
-
-# This is a list of the check targets for all of the modules which are
-# compiled using $(TARGET_FLAGS_TO_PASS).
-CHECK_TARGET_MODULES = \
- check-target-libstdc++-v3 \
- check-target-newlib \
- check-target-libf2c \
- check-target-libobjc \
- check-target-winsup \
- check-target-libiberty \
- check-target-libffi \
- check-target-libjava \
- check-target-zlib \
- check-target-boehm-gc \
- check-target-qthreads \
- check-target-gperf
-
-# This is a list of the install targets for all of the modules which are
-# compiled using $(TARGET_FLAGS_TO_PASS).
-INSTALL_TARGET_MODULES = \
- install-target-libstdc++-v3 \
- install-target-newlib \
- install-target-libf2c \
- install-target-libobjc \
- install-target-libtermcap \
- install-target-winsup \
- install-target-libgloss \
- install-target-libiberty \
- install-target-libjava \
- install-target-zlib \
- install-target-boehm-gc \
- install-target-qthreads \
- install-target-gperf
-
-# This is a list of the targets for which we can do a clean-{target}.
-CLEAN_MODULES = \
- clean-ash \
- clean-autoconf \
- clean-automake \
- clean-bash \
- clean-bfd \
- clean-binutils \
- clean-bison \
- clean-byacc \
- clean-bzip2 \
- clean-db \
- clean-dejagnu \
- clean-diff \
- clean-dosutils \
- clean-etc \
- clean-fastjar \
- clean-fileutils \
- clean-findutils \
- clean-find \
- clean-flex \
- clean-gas \
- clean-gawk \
- clean-gettext \
- clean-gnuserv \
- clean-gprof \
- clean-grep \
- clean-gzip \
- clean-hello \
- clean-indent \
- clean-intl \
- clean-itcl \
- clean-ld \
- clean-libgui \
- clean-libiberty \
- clean-libtool \
- clean-m4 \
- clean-make \
- clean-mmalloc \
- clean-opcodes \
- clean-patch \
- clean-perl \
- clean-prms \
- clean-rcs \
- clean-readline \
- clean-release \
- clean-recode \
- clean-sed \
- clean-send-pr \
- clean-shellutils \
- clean-sid \
- clean-sim \
- clean-snavigator \
- clean-tar \
- clean-tcl \
- clean-texinfo \
- clean-textutils \
- clean-time \
- clean-uudecode \
- clean-wdiff \
- clean-zip \
- clean-zlib
-
-# All of the target modules that can be cleaned
-CLEAN_TARGET_MODULES = \
- clean-target-libstdc++-v3 \
- clean-target-newlib \
- clean-target-libf2c \
- clean-target-libobjc \
- clean-target-winsup \
- clean-target-libgloss \
- clean-target-libiberty \
- clean-target-gperf \
- clean-target-examples \
- clean-target-libffi \
- clean-target-libjava \
- clean-target-zlib \
- clean-target-boehm-gc \
- clean-target-qthreads
-
-# All of the x11 modules that can be cleaned
-CLEAN_X11_MODULES = \
- clean-gdb \
- clean-expect \
- clean-guile \
- clean-tclX \
- clean-tk \
- clean-tix
+ "`echo 'BOOT_CFLAGS=$(BOOT_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
+ "`echo 'BOOT_ADAFLAGS=$(BOOT_ADAFLAGS)' | sed -e s/.*=$$/XFOO=/`"
+
+GCC_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_HOST_FLAGS) $(EXTRA_GCC_FLAGS)
+
+.PHONY: configure-host
+configure-host: maybe-configure-gcc \
+ maybe-configure-ash \
+ maybe-configure-autoconf \
+ maybe-configure-automake \
+ maybe-configure-bash \
+ maybe-configure-bfd \
+ maybe-configure-opcodes \
+ maybe-configure-binutils \
+ maybe-configure-bison \
+ maybe-configure-byacc \
+ maybe-configure-bzip2 \
+ maybe-configure-dejagnu \
+ maybe-configure-diff \
+ maybe-configure-dosutils \
+ maybe-configure-etc \
+ maybe-configure-fastjar \
+ maybe-configure-fileutils \
+ maybe-configure-findutils \
+ maybe-configure-find \
+ maybe-configure-flex \
+ maybe-configure-gas \
+ maybe-configure-gawk \
+ maybe-configure-gettext \
+ maybe-configure-gnuserv \
+ maybe-configure-gprof \
+ maybe-configure-gzip \
+ maybe-configure-hello \
+ maybe-configure-indent \
+ maybe-configure-intl \
+ maybe-configure-tcl \
+ maybe-configure-itcl \
+ maybe-configure-ld \
+ maybe-configure-libgui \
+ maybe-configure-libiberty \
+ maybe-configure-libtool \
+ maybe-configure-m4 \
+ maybe-configure-make \
+ maybe-configure-mmalloc \
+ maybe-configure-patch \
+ maybe-configure-perl \
+ maybe-configure-prms \
+ maybe-configure-rcs \
+ maybe-configure-readline \
+ maybe-configure-release \
+ maybe-configure-recode \
+ maybe-configure-sed \
+ maybe-configure-send-pr \
+ maybe-configure-shellutils \
+ maybe-configure-sid \
+ maybe-configure-sim \
+ maybe-configure-tar \
+ maybe-configure-texinfo \
+ maybe-configure-textutils \
+ maybe-configure-time \
+ maybe-configure-uudecode \
+ maybe-configure-wdiff \
+ maybe-configure-zip \
+ maybe-configure-zlib \
+ maybe-configure-gdb \
+ maybe-configure-expect \
+ maybe-configure-guile \
+ maybe-configure-tk \
+ maybe-configure-tix \
+ maybe-configure-libtermcap \
+ maybe-configure-utils
+.PHONY: configure-target
+configure-target: \
+ maybe-configure-target-libstdc++-v3 \
+ maybe-configure-target-newlib \
+ maybe-configure-target-libf2c \
+ maybe-configure-target-libobjc \
+ maybe-configure-target-libtermcap \
+ maybe-configure-target-winsup \
+ maybe-configure-target-libgloss \
+ maybe-configure-target-libiberty \
+ maybe-configure-target-gperf \
+ maybe-configure-target-examples \
+ maybe-configure-target-libffi \
+ maybe-configure-target-libjava \
+ maybe-configure-target-zlib \
+ maybe-configure-target-boehm-gc \
+ maybe-configure-target-qthreads \
+ maybe-configure-target-rda \
+ maybe-configure-target-libada
# The target built for a native build.
.PHONY: all.normal
-all.normal: \
- $(ALL_BUILD_MODULES) \
- $(ALL_MODULES) \
- $(ALL_X11_MODULES) \
- $(ALL_TARGET_MODULES) \
- all-gcc
+all.normal: @all_build_modules@ all-host all-target
+
+.PHONY: all-host
+all-host: maybe-all-gcc \
+ maybe-all-ash \
+ maybe-all-autoconf \
+ maybe-all-automake \
+ maybe-all-bash \
+ maybe-all-bfd \
+ maybe-all-opcodes \
+ maybe-all-binutils \
+ maybe-all-bison \
+ maybe-all-byacc \
+ maybe-all-bzip2 \
+ maybe-all-dejagnu \
+ maybe-all-diff \
+ maybe-all-dosutils \
+ maybe-all-etc \
+ maybe-all-fastjar \
+ maybe-all-fileutils \
+ maybe-all-findutils \
+ maybe-all-find \
+ maybe-all-flex \
+ maybe-all-gas \
+ maybe-all-gawk \
+ maybe-all-gettext \
+ maybe-all-gnuserv \
+ maybe-all-gprof \
+ maybe-all-gzip \
+ maybe-all-hello \
+ maybe-all-indent \
+ maybe-all-intl \
+ maybe-all-tcl \
+ maybe-all-itcl \
+ maybe-all-ld \
+ maybe-all-libgui \
+ maybe-all-libiberty \
+ maybe-all-libtool \
+ maybe-all-m4 \
+ maybe-all-make \
+ maybe-all-mmalloc \
+ maybe-all-patch \
+ maybe-all-perl \
+ maybe-all-prms \
+ maybe-all-rcs \
+ maybe-all-readline \
+ maybe-all-release \
+ maybe-all-recode \
+ maybe-all-sed \
+ maybe-all-send-pr \
+ maybe-all-shellutils \
+ maybe-all-sid \
+ maybe-all-sim \
+ maybe-all-tar \
+ maybe-all-texinfo \
+ maybe-all-textutils \
+ maybe-all-time \
+ maybe-all-uudecode \
+ maybe-all-wdiff \
+ maybe-all-zip \
+ maybe-all-zlib \
+ maybe-all-gdb \
+ maybe-all-expect \
+ maybe-all-guile \
+ maybe-all-tk \
+ maybe-all-tix \
+ maybe-all-libtermcap \
+ maybe-all-utils
+.PHONY: all-target
+all-target: \
+ maybe-all-target-libstdc++-v3 \
+ maybe-all-target-newlib \
+ maybe-all-target-libf2c \
+ maybe-all-target-libobjc \
+ maybe-all-target-libtermcap \
+ maybe-all-target-winsup \
+ maybe-all-target-libgloss \
+ maybe-all-target-libiberty \
+ maybe-all-target-gperf \
+ maybe-all-target-examples \
+ maybe-all-target-libffi \
+ maybe-all-target-libjava \
+ maybe-all-target-zlib \
+ maybe-all-target-boehm-gc \
+ maybe-all-target-qthreads \
+ maybe-all-target-rda \
+ maybe-all-target-libada
# Do a target for all the subdirectories. A ``make do-X'' will do a
# ``make X'' in all subdirectories (because, in general, there is a
# dependency (below) of X upon do-X, a ``make X'' will also do this,
# but it may do additional work as well).
-# This target ensures that $(BASE_FLAGS_TO_PASS) appears only once,
-# because it is so large that it can easily overflow the command line
-# length limit on some systems.
-DO_X = \
- do-clean \
- do-distclean \
- do-dvi \
- do-info \
- do-install-info \
- do-installcheck \
- do-mostlyclean \
- do-maintainer-clean \
- do-TAGS
-.PHONY: $(DO_X)
-$(DO_X):
- @target=`echo $@ | sed -e 's/^do-//'`; \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
- $(SET_LIB_PATH) \
- for i in $(SUBDIRS) -dummy-; do \
- if [ -f ./$$i/Makefile ]; then \
- case $$i in \
- gcc) \
- for flag in $(EXTRA_GCC_FLAGS); do \
- eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
- done; \
- ;; \
- *) \
- for flag in $(EXTRA_HOST_FLAGS); do \
- eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
- done; \
- ;; \
- esac ; \
- if (cd ./$$i; \
- $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
- "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
- "`echo \"RANLIB=$${RANLIB}\" | sed -e 's/.*=$$/XFOO=/'`" \
- "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
- $${target}); \
- then true; else exit 1; fi; \
- else true; fi; \
- done
- @target=`echo $@ | sed -e 's/^do-//'`; \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
- $(SET_LIB_PATH) \
- for i in $(TARGET_CONFIGDIRS) -dummy-; do \
- if [ -f $(TARGET_SUBDIR)/$$i/Makefile ]; then \
- for flag in $(EXTRA_TARGET_FLAGS); do \
- eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
- done; \
- if (cd $(TARGET_SUBDIR)/$$i; \
- $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
- "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
- "`echo \"RANLIB=$${RANLIB}\" | sed -e 's/.*=$$/XFOO=/'`" \
- "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
- $${target}); \
- then true; else exit 1; fi; \
- else true; fi; \
- done
+
+.PHONY: do-info
+do-info: info-host info-target
+
+.PHONY: info-host
+info-host: maybe-info-gcc \
+ maybe-info-ash \
+ maybe-info-autoconf \
+ maybe-info-automake \
+ maybe-info-bash \
+ maybe-info-bfd \
+ maybe-info-opcodes \
+ maybe-info-binutils \
+ maybe-info-bison \
+ maybe-info-byacc \
+ maybe-info-bzip2 \
+ maybe-info-dejagnu \
+ maybe-info-diff \
+ maybe-info-dosutils \
+ maybe-info-etc \
+ maybe-info-fastjar \
+ maybe-info-fileutils \
+ maybe-info-findutils \
+ maybe-info-find \
+ maybe-info-flex \
+ maybe-info-gas \
+ maybe-info-gawk \
+ maybe-info-gettext \
+ maybe-info-gnuserv \
+ maybe-info-gprof \
+ maybe-info-gzip \
+ maybe-info-hello \
+ maybe-info-indent \
+ maybe-info-intl \
+ maybe-info-tcl \
+ maybe-info-itcl \
+ maybe-info-ld \
+ maybe-info-libgui \
+ maybe-info-libiberty \
+ maybe-info-libtool \
+ maybe-info-m4 \
+ maybe-info-make \
+ maybe-info-mmalloc \
+ maybe-info-patch \
+ maybe-info-perl \
+ maybe-info-prms \
+ maybe-info-rcs \
+ maybe-info-readline \
+ maybe-info-release \
+ maybe-info-recode \
+ maybe-info-sed \
+ maybe-info-send-pr \
+ maybe-info-shellutils \
+ maybe-info-sid \
+ maybe-info-sim \
+ maybe-info-tar \
+ maybe-info-texinfo \
+ maybe-info-textutils \
+ maybe-info-time \
+ maybe-info-uudecode \
+ maybe-info-wdiff \
+ maybe-info-zip \
+ maybe-info-zlib \
+ maybe-info-gdb \
+ maybe-info-expect \
+ maybe-info-guile \
+ maybe-info-tk \
+ maybe-info-tix \
+ maybe-info-libtermcap \
+ maybe-info-utils
+
+.PHONY: info-target
+info-target: \
+ maybe-info-target-libstdc++-v3 \
+ maybe-info-target-newlib \
+ maybe-info-target-libf2c \
+ maybe-info-target-libobjc \
+ maybe-info-target-libtermcap \
+ maybe-info-target-winsup \
+ maybe-info-target-libgloss \
+ maybe-info-target-libiberty \
+ maybe-info-target-gperf \
+ maybe-info-target-examples \
+ maybe-info-target-libffi \
+ maybe-info-target-libjava \
+ maybe-info-target-zlib \
+ maybe-info-target-boehm-gc \
+ maybe-info-target-qthreads \
+ maybe-info-target-rda \
+ maybe-info-target-libada
+
+# GCC, the eternal special case
+.PHONY: maybe-info-gcc info-gcc
+maybe-info-gcc:
+info-gcc: \
+ configure-gcc
+ @[ -f ./gcc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_GCC_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in gcc" ; \
+ (cd gcc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+# Host modules.
+
+.PHONY: maybe-info-ash info-ash
+maybe-info-ash:
+
+info-ash: \
+ configure-ash
+ @[ -f ./ash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in ash" ; \
+ (cd ash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-autoconf info-autoconf
+maybe-info-autoconf:
+
+info-autoconf: \
+ configure-autoconf
+ @[ -f ./autoconf/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in autoconf" ; \
+ (cd autoconf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-automake info-automake
+maybe-info-automake:
+
+info-automake: \
+ configure-automake
+ @[ -f ./automake/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in automake" ; \
+ (cd automake && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-bash info-bash
+maybe-info-bash:
+
+info-bash: \
+ configure-bash
+ @[ -f ./bash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in bash" ; \
+ (cd bash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-bfd info-bfd
+maybe-info-bfd:
+
+info-bfd: \
+ configure-bfd
+ @[ -f ./bfd/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in bfd" ; \
+ (cd bfd && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-opcodes info-opcodes
+maybe-info-opcodes:
+
+info-opcodes: \
+ configure-opcodes
+ @[ -f ./opcodes/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in opcodes" ; \
+ (cd opcodes && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-binutils info-binutils
+maybe-info-binutils:
+
+info-binutils: \
+ configure-binutils
+ @[ -f ./binutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in binutils" ; \
+ (cd binutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-bison info-bison
+maybe-info-bison:
+
+info-bison: \
+ configure-bison
+ @[ -f ./bison/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in bison" ; \
+ (cd bison && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-byacc info-byacc
+maybe-info-byacc:
+
+info-byacc: \
+ configure-byacc
+ @[ -f ./byacc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in byacc" ; \
+ (cd byacc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-bzip2 info-bzip2
+maybe-info-bzip2:
+
+info-bzip2: \
+ configure-bzip2
+ @[ -f ./bzip2/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in bzip2" ; \
+ (cd bzip2 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-dejagnu info-dejagnu
+maybe-info-dejagnu:
+
+info-dejagnu: \
+ configure-dejagnu
+ @[ -f ./dejagnu/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in dejagnu" ; \
+ (cd dejagnu && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-diff info-diff
+maybe-info-diff:
+
+info-diff: \
+ configure-diff
+ @[ -f ./diff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in diff" ; \
+ (cd diff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-dosutils info-dosutils
+maybe-info-dosutils:
+
+info-dosutils: \
+ configure-dosutils
+ @[ -f ./dosutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in dosutils" ; \
+ (cd dosutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-etc info-etc
+maybe-info-etc:
+
+info-etc: \
+ configure-etc
+ @[ -f ./etc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in etc" ; \
+ (cd etc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-fastjar info-fastjar
+maybe-info-fastjar:
+
+info-fastjar: \
+ configure-fastjar
+ @[ -f ./fastjar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in fastjar" ; \
+ (cd fastjar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-fileutils info-fileutils
+maybe-info-fileutils:
+
+info-fileutils: \
+ configure-fileutils
+ @[ -f ./fileutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in fileutils" ; \
+ (cd fileutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-findutils info-findutils
+maybe-info-findutils:
+
+info-findutils: \
+ configure-findutils
+ @[ -f ./findutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in findutils" ; \
+ (cd findutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-find info-find
+maybe-info-find:
+
+info-find: \
+ configure-find
+ @[ -f ./find/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in find" ; \
+ (cd find && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-flex info-flex
+maybe-info-flex:
+
+info-flex: \
+ configure-flex
+ @[ -f ./flex/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in flex" ; \
+ (cd flex && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-gas info-gas
+maybe-info-gas:
+
+info-gas: \
+ configure-gas
+ @[ -f ./gas/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in gas" ; \
+ (cd gas && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-gawk info-gawk
+maybe-info-gawk:
+
+info-gawk: \
+ configure-gawk
+ @[ -f ./gawk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in gawk" ; \
+ (cd gawk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-gettext info-gettext
+maybe-info-gettext:
+
+info-gettext: \
+ configure-gettext
+ @[ -f ./gettext/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in gettext" ; \
+ (cd gettext && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-gnuserv info-gnuserv
+maybe-info-gnuserv:
+
+info-gnuserv: \
+ configure-gnuserv
+ @[ -f ./gnuserv/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in gnuserv" ; \
+ (cd gnuserv && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-gprof info-gprof
+maybe-info-gprof:
+
+info-gprof: \
+ configure-gprof
+ @[ -f ./gprof/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in gprof" ; \
+ (cd gprof && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-gzip info-gzip
+maybe-info-gzip:
+
+info-gzip: \
+ configure-gzip
+ @[ -f ./gzip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in gzip" ; \
+ (cd gzip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-hello info-hello
+maybe-info-hello:
+
+info-hello: \
+ configure-hello
+ @[ -f ./hello/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in hello" ; \
+ (cd hello && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-indent info-indent
+maybe-info-indent:
+
+info-indent: \
+ configure-indent
+ @[ -f ./indent/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in indent" ; \
+ (cd indent && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-intl info-intl
+maybe-info-intl:
+
+info-intl: \
+ configure-intl
+ @[ -f ./intl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in intl" ; \
+ (cd intl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-tcl info-tcl
+maybe-info-tcl:
+
+info-tcl: \
+ configure-tcl
+ @[ -f ./tcl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in tcl" ; \
+ (cd tcl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-itcl info-itcl
+maybe-info-itcl:
+
+info-itcl: \
+ configure-itcl
+ @[ -f ./itcl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in itcl" ; \
+ (cd itcl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-ld info-ld
+maybe-info-ld:
+
+info-ld: \
+ configure-ld
+ @[ -f ./ld/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in ld" ; \
+ (cd ld && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-libgui info-libgui
+maybe-info-libgui:
+
+info-libgui: \
+ configure-libgui
+ @[ -f ./libgui/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in libgui" ; \
+ (cd libgui && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-libiberty info-libiberty
+maybe-info-libiberty:
+
+info-libiberty: \
+ configure-libiberty
+ @[ -f ./libiberty/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in libiberty" ; \
+ (cd libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-libtool info-libtool
+maybe-info-libtool:
+
+info-libtool: \
+ configure-libtool
+ @[ -f ./libtool/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in libtool" ; \
+ (cd libtool && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-m4 info-m4
+maybe-info-m4:
+
+info-m4: \
+ configure-m4
+ @[ -f ./m4/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in m4" ; \
+ (cd m4 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-make info-make
+maybe-info-make:
+
+info-make: \
+ configure-make
+ @[ -f ./make/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in make" ; \
+ (cd make && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-mmalloc info-mmalloc
+maybe-info-mmalloc:
+
+info-mmalloc: \
+ configure-mmalloc
+ @[ -f ./mmalloc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in mmalloc" ; \
+ (cd mmalloc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-patch info-patch
+maybe-info-patch:
+
+info-patch: \
+ configure-patch
+ @[ -f ./patch/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in patch" ; \
+ (cd patch && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-perl info-perl
+maybe-info-perl:
+
+info-perl: \
+ configure-perl
+ @[ -f ./perl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in perl" ; \
+ (cd perl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-prms info-prms
+maybe-info-prms:
+
+info-prms: \
+ configure-prms
+ @[ -f ./prms/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in prms" ; \
+ (cd prms && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-rcs info-rcs
+maybe-info-rcs:
+
+info-rcs: \
+ configure-rcs
+ @[ -f ./rcs/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in rcs" ; \
+ (cd rcs && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-readline info-readline
+maybe-info-readline:
+
+info-readline: \
+ configure-readline
+ @[ -f ./readline/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in readline" ; \
+ (cd readline && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-release info-release
+maybe-info-release:
+
+info-release: \
+ configure-release
+ @[ -f ./release/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in release" ; \
+ (cd release && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-recode info-recode
+maybe-info-recode:
+
+info-recode: \
+ configure-recode
+ @[ -f ./recode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in recode" ; \
+ (cd recode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-sed info-sed
+maybe-info-sed:
+
+info-sed: \
+ configure-sed
+ @[ -f ./sed/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in sed" ; \
+ (cd sed && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-send-pr info-send-pr
+maybe-info-send-pr:
+
+info-send-pr: \
+ configure-send-pr
+ @[ -f ./send-pr/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in send-pr" ; \
+ (cd send-pr && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-shellutils info-shellutils
+maybe-info-shellutils:
+
+info-shellutils: \
+ configure-shellutils
+ @[ -f ./shellutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in shellutils" ; \
+ (cd shellutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-sid info-sid
+maybe-info-sid:
+
+info-sid: \
+ configure-sid
+ @[ -f ./sid/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in sid" ; \
+ (cd sid && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-sim info-sim
+maybe-info-sim:
+
+info-sim: \
+ configure-sim
+ @[ -f ./sim/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in sim" ; \
+ (cd sim && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-tar info-tar
+maybe-info-tar:
+
+info-tar: \
+ configure-tar
+ @[ -f ./tar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in tar" ; \
+ (cd tar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-texinfo info-texinfo
+maybe-info-texinfo:
+
+info-texinfo: \
+ configure-texinfo
+ @[ -f ./texinfo/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in texinfo" ; \
+ (cd texinfo && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-textutils info-textutils
+maybe-info-textutils:
+
+info-textutils: \
+ configure-textutils
+ @[ -f ./textutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in textutils" ; \
+ (cd textutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-time info-time
+maybe-info-time:
+
+info-time: \
+ configure-time
+ @[ -f ./time/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in time" ; \
+ (cd time && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-uudecode info-uudecode
+maybe-info-uudecode:
+
+info-uudecode: \
+ configure-uudecode
+ @[ -f ./uudecode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in uudecode" ; \
+ (cd uudecode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-wdiff info-wdiff
+maybe-info-wdiff:
+
+info-wdiff: \
+ configure-wdiff
+ @[ -f ./wdiff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in wdiff" ; \
+ (cd wdiff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-zip info-zip
+maybe-info-zip:
+
+info-zip: \
+ configure-zip
+ @[ -f ./zip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in zip" ; \
+ (cd zip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-zlib info-zlib
+maybe-info-zlib:
+
+info-zlib: \
+ configure-zlib
+ @[ -f ./zlib/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in zlib" ; \
+ (cd zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-gdb info-gdb
+maybe-info-gdb:
+
+info-gdb: \
+ configure-gdb
+ @[ -f ./gdb/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in gdb" ; \
+ (cd gdb && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-expect info-expect
+maybe-info-expect:
+
+info-expect: \
+ configure-expect
+ @[ -f ./expect/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in expect" ; \
+ (cd expect && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-guile info-guile
+maybe-info-guile:
+
+info-guile: \
+ configure-guile
+ @[ -f ./guile/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in guile" ; \
+ (cd guile && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-tk info-tk
+maybe-info-tk:
+
+info-tk: \
+ configure-tk
+ @[ -f ./tk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in tk" ; \
+ (cd tk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-tix info-tix
+maybe-info-tix:
+
+info-tix: \
+ configure-tix
+ @[ -f ./tix/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in tix" ; \
+ (cd tix && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-libtermcap info-libtermcap
+maybe-info-libtermcap:
+
+info-libtermcap: \
+ configure-libtermcap
+ @[ -f ./libtermcap/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in libtermcap" ; \
+ (cd libtermcap && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-utils info-utils
+maybe-info-utils:
+
+info-utils: \
+ configure-utils
+ @[ -f ./utils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing info in utils" ; \
+ (cd utils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+
+# Target modules.
+
+.PHONY: maybe-info-target-libstdc++-v3 info-target-libstdc++-v3
+maybe-info-target-libstdc++-v3:
+
+info-target-libstdc++-v3: \
+ configure-target-libstdc++-v3
+ @[ -f $(TARGET_SUBDIR)/libstdc++-v3/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing info in $(TARGET_SUBDIR)/libstdc++-v3" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libstdc++-v3 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-target-newlib info-target-newlib
+maybe-info-target-newlib:
+
+info-target-newlib: \
+ configure-target-newlib
+ @[ -f $(TARGET_SUBDIR)/newlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing info in $(TARGET_SUBDIR)/newlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/newlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-target-libf2c info-target-libf2c
+maybe-info-target-libf2c:
+
+info-target-libf2c: \
+ configure-target-libf2c
+ @[ -f $(TARGET_SUBDIR)/libf2c/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing info in $(TARGET_SUBDIR)/libf2c" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libf2c && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-target-libobjc info-target-libobjc
+maybe-info-target-libobjc:
+
+info-target-libobjc: \
+ configure-target-libobjc
+ @[ -f $(TARGET_SUBDIR)/libobjc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing info in $(TARGET_SUBDIR)/libobjc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libobjc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-target-libtermcap info-target-libtermcap
+maybe-info-target-libtermcap:
+
+info-target-libtermcap: \
+ configure-target-libtermcap
+ @[ -f $(TARGET_SUBDIR)/libtermcap/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing info in $(TARGET_SUBDIR)/libtermcap" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libtermcap && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-target-winsup info-target-winsup
+maybe-info-target-winsup:
+
+info-target-winsup: \
+ configure-target-winsup
+ @[ -f $(TARGET_SUBDIR)/winsup/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing info in $(TARGET_SUBDIR)/winsup" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/winsup && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-target-libgloss info-target-libgloss
+maybe-info-target-libgloss:
+
+info-target-libgloss: \
+ configure-target-libgloss
+ @[ -f $(TARGET_SUBDIR)/libgloss/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing info in $(TARGET_SUBDIR)/libgloss" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libgloss && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-target-libiberty info-target-libiberty
+maybe-info-target-libiberty:
+
+info-target-libiberty: \
+ configure-target-libiberty
+ @[ -f $(TARGET_SUBDIR)/libiberty/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing info in $(TARGET_SUBDIR)/libiberty" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-target-gperf info-target-gperf
+maybe-info-target-gperf:
+
+info-target-gperf: \
+ configure-target-gperf
+ @[ -f $(TARGET_SUBDIR)/gperf/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing info in $(TARGET_SUBDIR)/gperf" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/gperf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-target-examples info-target-examples
+maybe-info-target-examples:
+
+info-target-examples: \
+ configure-target-examples
+ @[ -f $(TARGET_SUBDIR)/examples/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing info in $(TARGET_SUBDIR)/examples" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/examples && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-target-libffi info-target-libffi
+maybe-info-target-libffi:
+
+info-target-libffi: \
+ configure-target-libffi
+ @[ -f $(TARGET_SUBDIR)/libffi/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing info in $(TARGET_SUBDIR)/libffi" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libffi && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-target-libjava info-target-libjava
+maybe-info-target-libjava:
+
+info-target-libjava: \
+ configure-target-libjava
+ @[ -f $(TARGET_SUBDIR)/libjava/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing info in $(TARGET_SUBDIR)/libjava" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libjava && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-target-zlib info-target-zlib
+maybe-info-target-zlib:
+
+info-target-zlib: \
+ configure-target-zlib
+ @[ -f $(TARGET_SUBDIR)/zlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing info in $(TARGET_SUBDIR)/zlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-target-boehm-gc info-target-boehm-gc
+maybe-info-target-boehm-gc:
+
+info-target-boehm-gc: \
+ configure-target-boehm-gc
+ @[ -f $(TARGET_SUBDIR)/boehm-gc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing info in $(TARGET_SUBDIR)/boehm-gc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/boehm-gc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-target-qthreads info-target-qthreads
+maybe-info-target-qthreads:
+
+info-target-qthreads: \
+ configure-target-qthreads
+ @[ -f $(TARGET_SUBDIR)/qthreads/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing info in $(TARGET_SUBDIR)/qthreads" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/qthreads && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-target-rda info-target-rda
+maybe-info-target-rda:
+
+info-target-rda: \
+ configure-target-rda
+ @[ -f $(TARGET_SUBDIR)/rda/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing info in $(TARGET_SUBDIR)/rda" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/rda && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+.PHONY: maybe-info-target-libada info-target-libada
+maybe-info-target-libada:
+
+info-target-libada: \
+ configure-target-libada
+ @[ -f $(TARGET_SUBDIR)/libada/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing info in $(TARGET_SUBDIR)/libada" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libada && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ info) \
+ || exit 1
+
+
+
+.PHONY: do-dvi
+do-dvi: dvi-host dvi-target
+
+.PHONY: dvi-host
+dvi-host: maybe-dvi-gcc \
+ maybe-dvi-ash \
+ maybe-dvi-autoconf \
+ maybe-dvi-automake \
+ maybe-dvi-bash \
+ maybe-dvi-bfd \
+ maybe-dvi-opcodes \
+ maybe-dvi-binutils \
+ maybe-dvi-bison \
+ maybe-dvi-byacc \
+ maybe-dvi-bzip2 \
+ maybe-dvi-dejagnu \
+ maybe-dvi-diff \
+ maybe-dvi-dosutils \
+ maybe-dvi-etc \
+ maybe-dvi-fastjar \
+ maybe-dvi-fileutils \
+ maybe-dvi-findutils \
+ maybe-dvi-find \
+ maybe-dvi-flex \
+ maybe-dvi-gas \
+ maybe-dvi-gawk \
+ maybe-dvi-gettext \
+ maybe-dvi-gnuserv \
+ maybe-dvi-gprof \
+ maybe-dvi-gzip \
+ maybe-dvi-hello \
+ maybe-dvi-indent \
+ maybe-dvi-intl \
+ maybe-dvi-tcl \
+ maybe-dvi-itcl \
+ maybe-dvi-ld \
+ maybe-dvi-libgui \
+ maybe-dvi-libiberty \
+ maybe-dvi-libtool \
+ maybe-dvi-m4 \
+ maybe-dvi-make \
+ maybe-dvi-mmalloc \
+ maybe-dvi-patch \
+ maybe-dvi-perl \
+ maybe-dvi-prms \
+ maybe-dvi-rcs \
+ maybe-dvi-readline \
+ maybe-dvi-release \
+ maybe-dvi-recode \
+ maybe-dvi-sed \
+ maybe-dvi-send-pr \
+ maybe-dvi-shellutils \
+ maybe-dvi-sid \
+ maybe-dvi-sim \
+ maybe-dvi-tar \
+ maybe-dvi-texinfo \
+ maybe-dvi-textutils \
+ maybe-dvi-time \
+ maybe-dvi-uudecode \
+ maybe-dvi-wdiff \
+ maybe-dvi-zip \
+ maybe-dvi-zlib \
+ maybe-dvi-gdb \
+ maybe-dvi-expect \
+ maybe-dvi-guile \
+ maybe-dvi-tk \
+ maybe-dvi-tix \
+ maybe-dvi-libtermcap \
+ maybe-dvi-utils
+
+.PHONY: dvi-target
+dvi-target: \
+ maybe-dvi-target-libstdc++-v3 \
+ maybe-dvi-target-newlib \
+ maybe-dvi-target-libf2c \
+ maybe-dvi-target-libobjc \
+ maybe-dvi-target-libtermcap \
+ maybe-dvi-target-winsup \
+ maybe-dvi-target-libgloss \
+ maybe-dvi-target-libiberty \
+ maybe-dvi-target-gperf \
+ maybe-dvi-target-examples \
+ maybe-dvi-target-libffi \
+ maybe-dvi-target-libjava \
+ maybe-dvi-target-zlib \
+ maybe-dvi-target-boehm-gc \
+ maybe-dvi-target-qthreads \
+ maybe-dvi-target-rda \
+ maybe-dvi-target-libada
+
+# GCC, the eternal special case
+.PHONY: maybe-dvi-gcc dvi-gcc
+maybe-dvi-gcc:
+dvi-gcc: \
+ configure-gcc
+ @[ -f ./gcc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_GCC_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in gcc" ; \
+ (cd gcc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+# Host modules.
+
+.PHONY: maybe-dvi-ash dvi-ash
+maybe-dvi-ash:
+
+dvi-ash: \
+ configure-ash
+ @[ -f ./ash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in ash" ; \
+ (cd ash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-autoconf dvi-autoconf
+maybe-dvi-autoconf:
+
+dvi-autoconf: \
+ configure-autoconf
+ @[ -f ./autoconf/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in autoconf" ; \
+ (cd autoconf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-automake dvi-automake
+maybe-dvi-automake:
+
+dvi-automake: \
+ configure-automake
+ @[ -f ./automake/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in automake" ; \
+ (cd automake && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-bash dvi-bash
+maybe-dvi-bash:
+
+dvi-bash: \
+ configure-bash
+ @[ -f ./bash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in bash" ; \
+ (cd bash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-bfd dvi-bfd
+maybe-dvi-bfd:
+
+dvi-bfd: \
+ configure-bfd
+ @[ -f ./bfd/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in bfd" ; \
+ (cd bfd && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-opcodes dvi-opcodes
+maybe-dvi-opcodes:
+
+dvi-opcodes: \
+ configure-opcodes
+ @[ -f ./opcodes/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in opcodes" ; \
+ (cd opcodes && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-binutils dvi-binutils
+maybe-dvi-binutils:
+
+dvi-binutils: \
+ configure-binutils
+ @[ -f ./binutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in binutils" ; \
+ (cd binutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-bison dvi-bison
+maybe-dvi-bison:
+
+dvi-bison: \
+ configure-bison
+ @[ -f ./bison/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in bison" ; \
+ (cd bison && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-byacc dvi-byacc
+maybe-dvi-byacc:
+
+dvi-byacc: \
+ configure-byacc
+ @[ -f ./byacc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in byacc" ; \
+ (cd byacc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-bzip2 dvi-bzip2
+maybe-dvi-bzip2:
+
+dvi-bzip2: \
+ configure-bzip2
+ @[ -f ./bzip2/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in bzip2" ; \
+ (cd bzip2 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-dejagnu dvi-dejagnu
+maybe-dvi-dejagnu:
+
+dvi-dejagnu: \
+ configure-dejagnu
+ @[ -f ./dejagnu/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in dejagnu" ; \
+ (cd dejagnu && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-diff dvi-diff
+maybe-dvi-diff:
+
+dvi-diff: \
+ configure-diff
+ @[ -f ./diff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in diff" ; \
+ (cd diff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-dosutils dvi-dosutils
+maybe-dvi-dosutils:
+
+dvi-dosutils: \
+ configure-dosutils
+ @[ -f ./dosutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in dosutils" ; \
+ (cd dosutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-etc dvi-etc
+maybe-dvi-etc:
+
+dvi-etc: \
+ configure-etc
+ @[ -f ./etc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in etc" ; \
+ (cd etc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-fastjar dvi-fastjar
+maybe-dvi-fastjar:
+
+dvi-fastjar: \
+ configure-fastjar
+ @[ -f ./fastjar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in fastjar" ; \
+ (cd fastjar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-fileutils dvi-fileutils
+maybe-dvi-fileutils:
+
+dvi-fileutils: \
+ configure-fileutils
+ @[ -f ./fileutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in fileutils" ; \
+ (cd fileutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-findutils dvi-findutils
+maybe-dvi-findutils:
+
+dvi-findutils: \
+ configure-findutils
+ @[ -f ./findutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in findutils" ; \
+ (cd findutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-find dvi-find
+maybe-dvi-find:
+
+dvi-find: \
+ configure-find
+ @[ -f ./find/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in find" ; \
+ (cd find && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-flex dvi-flex
+maybe-dvi-flex:
+
+dvi-flex: \
+ configure-flex
+ @[ -f ./flex/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in flex" ; \
+ (cd flex && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-gas dvi-gas
+maybe-dvi-gas:
+
+dvi-gas: \
+ configure-gas
+ @[ -f ./gas/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in gas" ; \
+ (cd gas && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-gawk dvi-gawk
+maybe-dvi-gawk:
+
+dvi-gawk: \
+ configure-gawk
+ @[ -f ./gawk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in gawk" ; \
+ (cd gawk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-gettext dvi-gettext
+maybe-dvi-gettext:
+
+dvi-gettext: \
+ configure-gettext
+ @[ -f ./gettext/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in gettext" ; \
+ (cd gettext && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-gnuserv dvi-gnuserv
+maybe-dvi-gnuserv:
+
+dvi-gnuserv: \
+ configure-gnuserv
+ @[ -f ./gnuserv/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in gnuserv" ; \
+ (cd gnuserv && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-gprof dvi-gprof
+maybe-dvi-gprof:
+
+dvi-gprof: \
+ configure-gprof
+ @[ -f ./gprof/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in gprof" ; \
+ (cd gprof && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-gzip dvi-gzip
+maybe-dvi-gzip:
+
+dvi-gzip: \
+ configure-gzip
+ @[ -f ./gzip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in gzip" ; \
+ (cd gzip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-hello dvi-hello
+maybe-dvi-hello:
+
+dvi-hello: \
+ configure-hello
+ @[ -f ./hello/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in hello" ; \
+ (cd hello && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-indent dvi-indent
+maybe-dvi-indent:
+
+dvi-indent: \
+ configure-indent
+ @[ -f ./indent/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in indent" ; \
+ (cd indent && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-intl dvi-intl
+maybe-dvi-intl:
+
+dvi-intl: \
+ configure-intl
+ @[ -f ./intl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in intl" ; \
+ (cd intl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-tcl dvi-tcl
+maybe-dvi-tcl:
+
+dvi-tcl: \
+ configure-tcl
+ @[ -f ./tcl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in tcl" ; \
+ (cd tcl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-itcl dvi-itcl
+maybe-dvi-itcl:
+
+dvi-itcl: \
+ configure-itcl
+ @[ -f ./itcl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in itcl" ; \
+ (cd itcl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-ld dvi-ld
+maybe-dvi-ld:
+
+dvi-ld: \
+ configure-ld
+ @[ -f ./ld/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in ld" ; \
+ (cd ld && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-libgui dvi-libgui
+maybe-dvi-libgui:
+
+dvi-libgui: \
+ configure-libgui
+ @[ -f ./libgui/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in libgui" ; \
+ (cd libgui && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-libiberty dvi-libiberty
+maybe-dvi-libiberty:
+
+dvi-libiberty: \
+ configure-libiberty
+ @[ -f ./libiberty/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in libiberty" ; \
+ (cd libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-libtool dvi-libtool
+maybe-dvi-libtool:
+
+dvi-libtool: \
+ configure-libtool
+ @[ -f ./libtool/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in libtool" ; \
+ (cd libtool && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-m4 dvi-m4
+maybe-dvi-m4:
+
+dvi-m4: \
+ configure-m4
+ @[ -f ./m4/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in m4" ; \
+ (cd m4 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-make dvi-make
+maybe-dvi-make:
+
+dvi-make: \
+ configure-make
+ @[ -f ./make/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in make" ; \
+ (cd make && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-mmalloc dvi-mmalloc
+maybe-dvi-mmalloc:
+
+dvi-mmalloc: \
+ configure-mmalloc
+ @[ -f ./mmalloc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in mmalloc" ; \
+ (cd mmalloc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-patch dvi-patch
+maybe-dvi-patch:
+
+dvi-patch: \
+ configure-patch
+ @[ -f ./patch/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in patch" ; \
+ (cd patch && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-perl dvi-perl
+maybe-dvi-perl:
+
+dvi-perl: \
+ configure-perl
+ @[ -f ./perl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in perl" ; \
+ (cd perl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-prms dvi-prms
+maybe-dvi-prms:
+
+dvi-prms: \
+ configure-prms
+ @[ -f ./prms/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in prms" ; \
+ (cd prms && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-rcs dvi-rcs
+maybe-dvi-rcs:
+
+dvi-rcs: \
+ configure-rcs
+ @[ -f ./rcs/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in rcs" ; \
+ (cd rcs && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-readline dvi-readline
+maybe-dvi-readline:
+
+dvi-readline: \
+ configure-readline
+ @[ -f ./readline/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in readline" ; \
+ (cd readline && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-release dvi-release
+maybe-dvi-release:
+
+dvi-release: \
+ configure-release
+ @[ -f ./release/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in release" ; \
+ (cd release && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-recode dvi-recode
+maybe-dvi-recode:
+
+dvi-recode: \
+ configure-recode
+ @[ -f ./recode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in recode" ; \
+ (cd recode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-sed dvi-sed
+maybe-dvi-sed:
+
+dvi-sed: \
+ configure-sed
+ @[ -f ./sed/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in sed" ; \
+ (cd sed && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-send-pr dvi-send-pr
+maybe-dvi-send-pr:
+
+dvi-send-pr: \
+ configure-send-pr
+ @[ -f ./send-pr/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in send-pr" ; \
+ (cd send-pr && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-shellutils dvi-shellutils
+maybe-dvi-shellutils:
+
+dvi-shellutils: \
+ configure-shellutils
+ @[ -f ./shellutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in shellutils" ; \
+ (cd shellutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-sid dvi-sid
+maybe-dvi-sid:
+
+dvi-sid: \
+ configure-sid
+ @[ -f ./sid/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in sid" ; \
+ (cd sid && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-sim dvi-sim
+maybe-dvi-sim:
+
+dvi-sim: \
+ configure-sim
+ @[ -f ./sim/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in sim" ; \
+ (cd sim && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-tar dvi-tar
+maybe-dvi-tar:
+
+dvi-tar: \
+ configure-tar
+ @[ -f ./tar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in tar" ; \
+ (cd tar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-texinfo dvi-texinfo
+maybe-dvi-texinfo:
+
+dvi-texinfo: \
+ configure-texinfo
+ @[ -f ./texinfo/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in texinfo" ; \
+ (cd texinfo && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-textutils dvi-textutils
+maybe-dvi-textutils:
+
+dvi-textutils: \
+ configure-textutils
+ @[ -f ./textutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in textutils" ; \
+ (cd textutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-time dvi-time
+maybe-dvi-time:
+
+dvi-time: \
+ configure-time
+ @[ -f ./time/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in time" ; \
+ (cd time && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-uudecode dvi-uudecode
+maybe-dvi-uudecode:
+
+dvi-uudecode: \
+ configure-uudecode
+ @[ -f ./uudecode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in uudecode" ; \
+ (cd uudecode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-wdiff dvi-wdiff
+maybe-dvi-wdiff:
+
+dvi-wdiff: \
+ configure-wdiff
+ @[ -f ./wdiff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in wdiff" ; \
+ (cd wdiff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-zip dvi-zip
+maybe-dvi-zip:
+
+dvi-zip: \
+ configure-zip
+ @[ -f ./zip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in zip" ; \
+ (cd zip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-zlib dvi-zlib
+maybe-dvi-zlib:
+
+dvi-zlib: \
+ configure-zlib
+ @[ -f ./zlib/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in zlib" ; \
+ (cd zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-gdb dvi-gdb
+maybe-dvi-gdb:
+
+dvi-gdb: \
+ configure-gdb
+ @[ -f ./gdb/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in gdb" ; \
+ (cd gdb && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-expect dvi-expect
+maybe-dvi-expect:
+
+dvi-expect: \
+ configure-expect
+ @[ -f ./expect/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in expect" ; \
+ (cd expect && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-guile dvi-guile
+maybe-dvi-guile:
+
+dvi-guile: \
+ configure-guile
+ @[ -f ./guile/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in guile" ; \
+ (cd guile && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-tk dvi-tk
+maybe-dvi-tk:
+
+dvi-tk: \
+ configure-tk
+ @[ -f ./tk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in tk" ; \
+ (cd tk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-tix dvi-tix
+maybe-dvi-tix:
+
+dvi-tix: \
+ configure-tix
+ @[ -f ./tix/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in tix" ; \
+ (cd tix && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-libtermcap dvi-libtermcap
+maybe-dvi-libtermcap:
+
+dvi-libtermcap: \
+ configure-libtermcap
+ @[ -f ./libtermcap/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in libtermcap" ; \
+ (cd libtermcap && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-utils dvi-utils
+maybe-dvi-utils:
+
+dvi-utils: \
+ configure-utils
+ @[ -f ./utils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing dvi in utils" ; \
+ (cd utils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+
+# Target modules.
+
+.PHONY: maybe-dvi-target-libstdc++-v3 dvi-target-libstdc++-v3
+maybe-dvi-target-libstdc++-v3:
+
+dvi-target-libstdc++-v3: \
+ configure-target-libstdc++-v3
+ @[ -f $(TARGET_SUBDIR)/libstdc++-v3/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing dvi in $(TARGET_SUBDIR)/libstdc++-v3" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libstdc++-v3 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-target-newlib dvi-target-newlib
+maybe-dvi-target-newlib:
+
+dvi-target-newlib: \
+ configure-target-newlib
+ @[ -f $(TARGET_SUBDIR)/newlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing dvi in $(TARGET_SUBDIR)/newlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/newlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-target-libf2c dvi-target-libf2c
+maybe-dvi-target-libf2c:
+
+dvi-target-libf2c: \
+ configure-target-libf2c
+ @[ -f $(TARGET_SUBDIR)/libf2c/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing dvi in $(TARGET_SUBDIR)/libf2c" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libf2c && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-target-libobjc dvi-target-libobjc
+maybe-dvi-target-libobjc:
+
+dvi-target-libobjc: \
+ configure-target-libobjc
+ @[ -f $(TARGET_SUBDIR)/libobjc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing dvi in $(TARGET_SUBDIR)/libobjc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libobjc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-target-libtermcap dvi-target-libtermcap
+maybe-dvi-target-libtermcap:
+
+dvi-target-libtermcap: \
+ configure-target-libtermcap
+ @[ -f $(TARGET_SUBDIR)/libtermcap/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing dvi in $(TARGET_SUBDIR)/libtermcap" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libtermcap && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-target-winsup dvi-target-winsup
+maybe-dvi-target-winsup:
+
+dvi-target-winsup: \
+ configure-target-winsup
+ @[ -f $(TARGET_SUBDIR)/winsup/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing dvi in $(TARGET_SUBDIR)/winsup" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/winsup && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-target-libgloss dvi-target-libgloss
+maybe-dvi-target-libgloss:
+
+dvi-target-libgloss: \
+ configure-target-libgloss
+ @[ -f $(TARGET_SUBDIR)/libgloss/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing dvi in $(TARGET_SUBDIR)/libgloss" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libgloss && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-target-libiberty dvi-target-libiberty
+maybe-dvi-target-libiberty:
+
+dvi-target-libiberty: \
+ configure-target-libiberty
+ @[ -f $(TARGET_SUBDIR)/libiberty/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing dvi in $(TARGET_SUBDIR)/libiberty" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-target-gperf dvi-target-gperf
+maybe-dvi-target-gperf:
+
+dvi-target-gperf: \
+ configure-target-gperf
+ @[ -f $(TARGET_SUBDIR)/gperf/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing dvi in $(TARGET_SUBDIR)/gperf" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/gperf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-target-examples dvi-target-examples
+maybe-dvi-target-examples:
+
+dvi-target-examples: \
+ configure-target-examples
+ @[ -f $(TARGET_SUBDIR)/examples/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing dvi in $(TARGET_SUBDIR)/examples" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/examples && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-target-libffi dvi-target-libffi
+maybe-dvi-target-libffi:
+
+dvi-target-libffi: \
+ configure-target-libffi
+ @[ -f $(TARGET_SUBDIR)/libffi/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing dvi in $(TARGET_SUBDIR)/libffi" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libffi && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-target-libjava dvi-target-libjava
+maybe-dvi-target-libjava:
+
+dvi-target-libjava: \
+ configure-target-libjava
+ @[ -f $(TARGET_SUBDIR)/libjava/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing dvi in $(TARGET_SUBDIR)/libjava" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libjava && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-target-zlib dvi-target-zlib
+maybe-dvi-target-zlib:
+
+dvi-target-zlib: \
+ configure-target-zlib
+ @[ -f $(TARGET_SUBDIR)/zlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing dvi in $(TARGET_SUBDIR)/zlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-target-boehm-gc dvi-target-boehm-gc
+maybe-dvi-target-boehm-gc:
+
+dvi-target-boehm-gc: \
+ configure-target-boehm-gc
+ @[ -f $(TARGET_SUBDIR)/boehm-gc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing dvi in $(TARGET_SUBDIR)/boehm-gc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/boehm-gc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-target-qthreads dvi-target-qthreads
+maybe-dvi-target-qthreads:
+
+dvi-target-qthreads: \
+ configure-target-qthreads
+ @[ -f $(TARGET_SUBDIR)/qthreads/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing dvi in $(TARGET_SUBDIR)/qthreads" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/qthreads && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-target-rda dvi-target-rda
+maybe-dvi-target-rda:
+
+dvi-target-rda: \
+ configure-target-rda
+ @[ -f $(TARGET_SUBDIR)/rda/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing dvi in $(TARGET_SUBDIR)/rda" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/rda && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+.PHONY: maybe-dvi-target-libada dvi-target-libada
+maybe-dvi-target-libada:
+
+dvi-target-libada: \
+ configure-target-libada
+ @[ -f $(TARGET_SUBDIR)/libada/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing dvi in $(TARGET_SUBDIR)/libada" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libada && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ dvi) \
+ || exit 1
+
+
+
+.PHONY: do-TAGS
+do-TAGS: TAGS-host TAGS-target
+
+.PHONY: TAGS-host
+TAGS-host: maybe-TAGS-gcc \
+ maybe-TAGS-ash \
+ maybe-TAGS-autoconf \
+ maybe-TAGS-automake \
+ maybe-TAGS-bash \
+ maybe-TAGS-bfd \
+ maybe-TAGS-opcodes \
+ maybe-TAGS-binutils \
+ maybe-TAGS-bison \
+ maybe-TAGS-byacc \
+ maybe-TAGS-bzip2 \
+ maybe-TAGS-dejagnu \
+ maybe-TAGS-diff \
+ maybe-TAGS-dosutils \
+ maybe-TAGS-etc \
+ maybe-TAGS-fastjar \
+ maybe-TAGS-fileutils \
+ maybe-TAGS-findutils \
+ maybe-TAGS-find \
+ maybe-TAGS-flex \
+ maybe-TAGS-gas \
+ maybe-TAGS-gawk \
+ maybe-TAGS-gettext \
+ maybe-TAGS-gnuserv \
+ maybe-TAGS-gprof \
+ maybe-TAGS-gzip \
+ maybe-TAGS-hello \
+ maybe-TAGS-indent \
+ maybe-TAGS-intl \
+ maybe-TAGS-tcl \
+ maybe-TAGS-itcl \
+ maybe-TAGS-ld \
+ maybe-TAGS-libgui \
+ maybe-TAGS-libiberty \
+ maybe-TAGS-libtool \
+ maybe-TAGS-m4 \
+ maybe-TAGS-make \
+ maybe-TAGS-mmalloc \
+ maybe-TAGS-patch \
+ maybe-TAGS-perl \
+ maybe-TAGS-prms \
+ maybe-TAGS-rcs \
+ maybe-TAGS-readline \
+ maybe-TAGS-release \
+ maybe-TAGS-recode \
+ maybe-TAGS-sed \
+ maybe-TAGS-send-pr \
+ maybe-TAGS-shellutils \
+ maybe-TAGS-sid \
+ maybe-TAGS-sim \
+ maybe-TAGS-tar \
+ maybe-TAGS-texinfo \
+ maybe-TAGS-textutils \
+ maybe-TAGS-time \
+ maybe-TAGS-uudecode \
+ maybe-TAGS-wdiff \
+ maybe-TAGS-zip \
+ maybe-TAGS-zlib \
+ maybe-TAGS-gdb \
+ maybe-TAGS-expect \
+ maybe-TAGS-guile \
+ maybe-TAGS-tk \
+ maybe-TAGS-tix \
+ maybe-TAGS-libtermcap \
+ maybe-TAGS-utils
+
+.PHONY: TAGS-target
+TAGS-target: \
+ maybe-TAGS-target-libstdc++-v3 \
+ maybe-TAGS-target-newlib \
+ maybe-TAGS-target-libf2c \
+ maybe-TAGS-target-libobjc \
+ maybe-TAGS-target-libtermcap \
+ maybe-TAGS-target-winsup \
+ maybe-TAGS-target-libgloss \
+ maybe-TAGS-target-libiberty \
+ maybe-TAGS-target-gperf \
+ maybe-TAGS-target-examples \
+ maybe-TAGS-target-libffi \
+ maybe-TAGS-target-libjava \
+ maybe-TAGS-target-zlib \
+ maybe-TAGS-target-boehm-gc \
+ maybe-TAGS-target-qthreads \
+ maybe-TAGS-target-rda \
+ maybe-TAGS-target-libada
+
+# GCC, the eternal special case
+.PHONY: maybe-TAGS-gcc TAGS-gcc
+maybe-TAGS-gcc:
+TAGS-gcc: \
+ configure-gcc
+ @[ -f ./gcc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_GCC_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in gcc" ; \
+ (cd gcc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+# Host modules.
+
+.PHONY: maybe-TAGS-ash TAGS-ash
+maybe-TAGS-ash:
+
+TAGS-ash: \
+ configure-ash
+ @[ -f ./ash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in ash" ; \
+ (cd ash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-autoconf TAGS-autoconf
+maybe-TAGS-autoconf:
+
+TAGS-autoconf: \
+ configure-autoconf
+ @[ -f ./autoconf/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in autoconf" ; \
+ (cd autoconf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-automake TAGS-automake
+maybe-TAGS-automake:
+
+TAGS-automake: \
+ configure-automake
+ @[ -f ./automake/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in automake" ; \
+ (cd automake && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-bash TAGS-bash
+maybe-TAGS-bash:
+
+TAGS-bash: \
+ configure-bash
+ @[ -f ./bash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in bash" ; \
+ (cd bash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-bfd TAGS-bfd
+maybe-TAGS-bfd:
+
+TAGS-bfd: \
+ configure-bfd
+ @[ -f ./bfd/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in bfd" ; \
+ (cd bfd && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-opcodes TAGS-opcodes
+maybe-TAGS-opcodes:
+
+TAGS-opcodes: \
+ configure-opcodes
+ @[ -f ./opcodes/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in opcodes" ; \
+ (cd opcodes && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-binutils TAGS-binutils
+maybe-TAGS-binutils:
+
+TAGS-binutils: \
+ configure-binutils
+ @[ -f ./binutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in binutils" ; \
+ (cd binutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-bison TAGS-bison
+maybe-TAGS-bison:
+
+TAGS-bison: \
+ configure-bison
+ @[ -f ./bison/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in bison" ; \
+ (cd bison && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-byacc TAGS-byacc
+maybe-TAGS-byacc:
+
+TAGS-byacc: \
+ configure-byacc
+ @[ -f ./byacc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in byacc" ; \
+ (cd byacc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-bzip2 TAGS-bzip2
+maybe-TAGS-bzip2:
+
+TAGS-bzip2: \
+ configure-bzip2
+ @[ -f ./bzip2/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in bzip2" ; \
+ (cd bzip2 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-dejagnu TAGS-dejagnu
+maybe-TAGS-dejagnu:
+
+TAGS-dejagnu: \
+ configure-dejagnu
+ @[ -f ./dejagnu/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in dejagnu" ; \
+ (cd dejagnu && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-diff TAGS-diff
+maybe-TAGS-diff:
+
+TAGS-diff: \
+ configure-diff
+ @[ -f ./diff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in diff" ; \
+ (cd diff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-dosutils TAGS-dosutils
+maybe-TAGS-dosutils:
+
+TAGS-dosutils: \
+ configure-dosutils
+ @[ -f ./dosutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in dosutils" ; \
+ (cd dosutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-etc TAGS-etc
+maybe-TAGS-etc:
+
+TAGS-etc: \
+ configure-etc
+ @[ -f ./etc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in etc" ; \
+ (cd etc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-fastjar TAGS-fastjar
+maybe-TAGS-fastjar:
+
+TAGS-fastjar: \
+ configure-fastjar
+ @[ -f ./fastjar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in fastjar" ; \
+ (cd fastjar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-fileutils TAGS-fileutils
+maybe-TAGS-fileutils:
+
+TAGS-fileutils: \
+ configure-fileutils
+ @[ -f ./fileutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in fileutils" ; \
+ (cd fileutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-findutils TAGS-findutils
+maybe-TAGS-findutils:
+
+TAGS-findutils: \
+ configure-findutils
+ @[ -f ./findutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in findutils" ; \
+ (cd findutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-find TAGS-find
+maybe-TAGS-find:
+
+TAGS-find: \
+ configure-find
+ @[ -f ./find/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in find" ; \
+ (cd find && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-flex TAGS-flex
+maybe-TAGS-flex:
+
+TAGS-flex: \
+ configure-flex
+ @[ -f ./flex/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in flex" ; \
+ (cd flex && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-gas TAGS-gas
+maybe-TAGS-gas:
+
+TAGS-gas: \
+ configure-gas
+ @[ -f ./gas/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in gas" ; \
+ (cd gas && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-gawk TAGS-gawk
+maybe-TAGS-gawk:
+
+TAGS-gawk: \
+ configure-gawk
+ @[ -f ./gawk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in gawk" ; \
+ (cd gawk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-gettext TAGS-gettext
+maybe-TAGS-gettext:
+
+TAGS-gettext: \
+ configure-gettext
+ @[ -f ./gettext/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in gettext" ; \
+ (cd gettext && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-gnuserv TAGS-gnuserv
+maybe-TAGS-gnuserv:
+
+TAGS-gnuserv: \
+ configure-gnuserv
+ @[ -f ./gnuserv/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in gnuserv" ; \
+ (cd gnuserv && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-gprof TAGS-gprof
+maybe-TAGS-gprof:
+
+TAGS-gprof: \
+ configure-gprof
+ @[ -f ./gprof/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in gprof" ; \
+ (cd gprof && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-gzip TAGS-gzip
+maybe-TAGS-gzip:
+
+TAGS-gzip: \
+ configure-gzip
+ @[ -f ./gzip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in gzip" ; \
+ (cd gzip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-hello TAGS-hello
+maybe-TAGS-hello:
+
+TAGS-hello: \
+ configure-hello
+ @[ -f ./hello/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in hello" ; \
+ (cd hello && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-indent TAGS-indent
+maybe-TAGS-indent:
+
+TAGS-indent: \
+ configure-indent
+ @[ -f ./indent/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in indent" ; \
+ (cd indent && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-intl TAGS-intl
+maybe-TAGS-intl:
+
+TAGS-intl: \
+ configure-intl
+ @[ -f ./intl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in intl" ; \
+ (cd intl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-tcl TAGS-tcl
+maybe-TAGS-tcl:
+
+TAGS-tcl: \
+ configure-tcl
+ @[ -f ./tcl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in tcl" ; \
+ (cd tcl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-itcl TAGS-itcl
+maybe-TAGS-itcl:
+
+TAGS-itcl: \
+ configure-itcl
+ @[ -f ./itcl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in itcl" ; \
+ (cd itcl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-ld TAGS-ld
+maybe-TAGS-ld:
+
+TAGS-ld: \
+ configure-ld
+ @[ -f ./ld/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in ld" ; \
+ (cd ld && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-libgui TAGS-libgui
+maybe-TAGS-libgui:
+
+TAGS-libgui: \
+ configure-libgui
+ @[ -f ./libgui/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in libgui" ; \
+ (cd libgui && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-libiberty TAGS-libiberty
+maybe-TAGS-libiberty:
+
+TAGS-libiberty: \
+ configure-libiberty
+ @[ -f ./libiberty/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in libiberty" ; \
+ (cd libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-libtool TAGS-libtool
+maybe-TAGS-libtool:
+
+TAGS-libtool: \
+ configure-libtool
+ @[ -f ./libtool/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in libtool" ; \
+ (cd libtool && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-m4 TAGS-m4
+maybe-TAGS-m4:
+
+TAGS-m4: \
+ configure-m4
+ @[ -f ./m4/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in m4" ; \
+ (cd m4 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-make TAGS-make
+maybe-TAGS-make:
+
+TAGS-make: \
+ configure-make
+ @[ -f ./make/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in make" ; \
+ (cd make && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-mmalloc TAGS-mmalloc
+maybe-TAGS-mmalloc:
+
+TAGS-mmalloc: \
+ configure-mmalloc
+ @[ -f ./mmalloc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in mmalloc" ; \
+ (cd mmalloc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-patch TAGS-patch
+maybe-TAGS-patch:
+
+TAGS-patch: \
+ configure-patch
+ @[ -f ./patch/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in patch" ; \
+ (cd patch && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-perl TAGS-perl
+maybe-TAGS-perl:
+
+TAGS-perl: \
+ configure-perl
+ @[ -f ./perl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in perl" ; \
+ (cd perl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-prms TAGS-prms
+maybe-TAGS-prms:
+
+TAGS-prms: \
+ configure-prms
+ @[ -f ./prms/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in prms" ; \
+ (cd prms && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-rcs TAGS-rcs
+maybe-TAGS-rcs:
+
+TAGS-rcs: \
+ configure-rcs
+ @[ -f ./rcs/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in rcs" ; \
+ (cd rcs && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-readline TAGS-readline
+maybe-TAGS-readline:
+
+TAGS-readline: \
+ configure-readline
+ @[ -f ./readline/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in readline" ; \
+ (cd readline && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-release TAGS-release
+maybe-TAGS-release:
+
+TAGS-release: \
+ configure-release
+ @[ -f ./release/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in release" ; \
+ (cd release && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-recode TAGS-recode
+maybe-TAGS-recode:
+
+TAGS-recode: \
+ configure-recode
+ @[ -f ./recode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in recode" ; \
+ (cd recode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-sed TAGS-sed
+maybe-TAGS-sed:
+
+TAGS-sed: \
+ configure-sed
+ @[ -f ./sed/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in sed" ; \
+ (cd sed && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-send-pr TAGS-send-pr
+maybe-TAGS-send-pr:
+
+TAGS-send-pr: \
+ configure-send-pr
+ @[ -f ./send-pr/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in send-pr" ; \
+ (cd send-pr && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-shellutils TAGS-shellutils
+maybe-TAGS-shellutils:
+
+TAGS-shellutils: \
+ configure-shellutils
+ @[ -f ./shellutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in shellutils" ; \
+ (cd shellutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-sid TAGS-sid
+maybe-TAGS-sid:
+
+TAGS-sid: \
+ configure-sid
+ @[ -f ./sid/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in sid" ; \
+ (cd sid && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-sim TAGS-sim
+maybe-TAGS-sim:
+
+TAGS-sim: \
+ configure-sim
+ @[ -f ./sim/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in sim" ; \
+ (cd sim && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-tar TAGS-tar
+maybe-TAGS-tar:
+
+TAGS-tar: \
+ configure-tar
+ @[ -f ./tar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in tar" ; \
+ (cd tar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-texinfo TAGS-texinfo
+maybe-TAGS-texinfo:
+
+TAGS-texinfo: \
+ configure-texinfo
+ @[ -f ./texinfo/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in texinfo" ; \
+ (cd texinfo && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-textutils TAGS-textutils
+maybe-TAGS-textutils:
+
+TAGS-textutils: \
+ configure-textutils
+ @[ -f ./textutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in textutils" ; \
+ (cd textutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-time TAGS-time
+maybe-TAGS-time:
+
+TAGS-time: \
+ configure-time
+ @[ -f ./time/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in time" ; \
+ (cd time && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-uudecode TAGS-uudecode
+maybe-TAGS-uudecode:
+
+TAGS-uudecode: \
+ configure-uudecode
+ @[ -f ./uudecode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in uudecode" ; \
+ (cd uudecode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-wdiff TAGS-wdiff
+maybe-TAGS-wdiff:
+
+TAGS-wdiff: \
+ configure-wdiff
+ @[ -f ./wdiff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in wdiff" ; \
+ (cd wdiff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-zip TAGS-zip
+maybe-TAGS-zip:
+
+TAGS-zip: \
+ configure-zip
+ @[ -f ./zip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in zip" ; \
+ (cd zip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-zlib TAGS-zlib
+maybe-TAGS-zlib:
+
+TAGS-zlib: \
+ configure-zlib
+ @[ -f ./zlib/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in zlib" ; \
+ (cd zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-gdb TAGS-gdb
+maybe-TAGS-gdb:
+
+TAGS-gdb: \
+ configure-gdb
+ @[ -f ./gdb/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in gdb" ; \
+ (cd gdb && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-expect TAGS-expect
+maybe-TAGS-expect:
+
+TAGS-expect: \
+ configure-expect
+ @[ -f ./expect/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in expect" ; \
+ (cd expect && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-guile TAGS-guile
+maybe-TAGS-guile:
+
+TAGS-guile: \
+ configure-guile
+ @[ -f ./guile/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in guile" ; \
+ (cd guile && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-tk TAGS-tk
+maybe-TAGS-tk:
+
+TAGS-tk: \
+ configure-tk
+ @[ -f ./tk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in tk" ; \
+ (cd tk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-tix TAGS-tix
+maybe-TAGS-tix:
+
+TAGS-tix: \
+ configure-tix
+ @[ -f ./tix/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in tix" ; \
+ (cd tix && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-libtermcap TAGS-libtermcap
+maybe-TAGS-libtermcap:
+
+TAGS-libtermcap: \
+ configure-libtermcap
+ @[ -f ./libtermcap/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in libtermcap" ; \
+ (cd libtermcap && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-utils TAGS-utils
+maybe-TAGS-utils:
+
+TAGS-utils: \
+ configure-utils
+ @[ -f ./utils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing TAGS in utils" ; \
+ (cd utils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+
+# Target modules.
+
+.PHONY: maybe-TAGS-target-libstdc++-v3 TAGS-target-libstdc++-v3
+maybe-TAGS-target-libstdc++-v3:
+
+TAGS-target-libstdc++-v3: \
+ configure-target-libstdc++-v3
+ @[ -f $(TARGET_SUBDIR)/libstdc++-v3/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing TAGS in $(TARGET_SUBDIR)/libstdc++-v3" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libstdc++-v3 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-target-newlib TAGS-target-newlib
+maybe-TAGS-target-newlib:
+
+TAGS-target-newlib: \
+ configure-target-newlib
+ @[ -f $(TARGET_SUBDIR)/newlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing TAGS in $(TARGET_SUBDIR)/newlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/newlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-target-libf2c TAGS-target-libf2c
+maybe-TAGS-target-libf2c:
+
+TAGS-target-libf2c: \
+ configure-target-libf2c
+ @[ -f $(TARGET_SUBDIR)/libf2c/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing TAGS in $(TARGET_SUBDIR)/libf2c" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libf2c && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-target-libobjc TAGS-target-libobjc
+maybe-TAGS-target-libobjc:
+
+TAGS-target-libobjc: \
+ configure-target-libobjc
+ @[ -f $(TARGET_SUBDIR)/libobjc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing TAGS in $(TARGET_SUBDIR)/libobjc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libobjc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-target-libtermcap TAGS-target-libtermcap
+maybe-TAGS-target-libtermcap:
+
+TAGS-target-libtermcap: \
+ configure-target-libtermcap
+ @[ -f $(TARGET_SUBDIR)/libtermcap/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing TAGS in $(TARGET_SUBDIR)/libtermcap" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libtermcap && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-target-winsup TAGS-target-winsup
+maybe-TAGS-target-winsup:
+
+TAGS-target-winsup: \
+ configure-target-winsup
+ @[ -f $(TARGET_SUBDIR)/winsup/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing TAGS in $(TARGET_SUBDIR)/winsup" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/winsup && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-target-libgloss TAGS-target-libgloss
+maybe-TAGS-target-libgloss:
+
+TAGS-target-libgloss: \
+ configure-target-libgloss
+ @[ -f $(TARGET_SUBDIR)/libgloss/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing TAGS in $(TARGET_SUBDIR)/libgloss" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libgloss && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-target-libiberty TAGS-target-libiberty
+maybe-TAGS-target-libiberty:
+
+TAGS-target-libiberty: \
+ configure-target-libiberty
+ @[ -f $(TARGET_SUBDIR)/libiberty/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing TAGS in $(TARGET_SUBDIR)/libiberty" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-target-gperf TAGS-target-gperf
+maybe-TAGS-target-gperf:
+
+TAGS-target-gperf: \
+ configure-target-gperf
+ @[ -f $(TARGET_SUBDIR)/gperf/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing TAGS in $(TARGET_SUBDIR)/gperf" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/gperf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-target-examples TAGS-target-examples
+maybe-TAGS-target-examples:
+
+TAGS-target-examples: \
+ configure-target-examples
+ @[ -f $(TARGET_SUBDIR)/examples/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing TAGS in $(TARGET_SUBDIR)/examples" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/examples && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-target-libffi TAGS-target-libffi
+maybe-TAGS-target-libffi:
+
+TAGS-target-libffi: \
+ configure-target-libffi
+ @[ -f $(TARGET_SUBDIR)/libffi/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing TAGS in $(TARGET_SUBDIR)/libffi" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libffi && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-target-libjava TAGS-target-libjava
+maybe-TAGS-target-libjava:
+
+TAGS-target-libjava: \
+ configure-target-libjava
+ @[ -f $(TARGET_SUBDIR)/libjava/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing TAGS in $(TARGET_SUBDIR)/libjava" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libjava && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-target-zlib TAGS-target-zlib
+maybe-TAGS-target-zlib:
+
+TAGS-target-zlib: \
+ configure-target-zlib
+ @[ -f $(TARGET_SUBDIR)/zlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing TAGS in $(TARGET_SUBDIR)/zlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-target-boehm-gc TAGS-target-boehm-gc
+maybe-TAGS-target-boehm-gc:
+
+TAGS-target-boehm-gc: \
+ configure-target-boehm-gc
+ @[ -f $(TARGET_SUBDIR)/boehm-gc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing TAGS in $(TARGET_SUBDIR)/boehm-gc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/boehm-gc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-target-qthreads TAGS-target-qthreads
+maybe-TAGS-target-qthreads:
+
+TAGS-target-qthreads: \
+ configure-target-qthreads
+ @[ -f $(TARGET_SUBDIR)/qthreads/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing TAGS in $(TARGET_SUBDIR)/qthreads" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/qthreads && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-target-rda TAGS-target-rda
+maybe-TAGS-target-rda:
+
+TAGS-target-rda: \
+ configure-target-rda
+ @[ -f $(TARGET_SUBDIR)/rda/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing TAGS in $(TARGET_SUBDIR)/rda" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/rda && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+.PHONY: maybe-TAGS-target-libada TAGS-target-libada
+maybe-TAGS-target-libada:
+
+TAGS-target-libada: \
+ configure-target-libada
+ @[ -f $(TARGET_SUBDIR)/libada/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing TAGS in $(TARGET_SUBDIR)/libada" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libada && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ TAGS) \
+ || exit 1
+
+
+
+.PHONY: do-install-info
+do-install-info: install-info-host install-info-target
+
+.PHONY: install-info-host
+install-info-host: maybe-install-info-gcc \
+ maybe-install-info-ash \
+ maybe-install-info-autoconf \
+ maybe-install-info-automake \
+ maybe-install-info-bash \
+ maybe-install-info-bfd \
+ maybe-install-info-opcodes \
+ maybe-install-info-binutils \
+ maybe-install-info-bison \
+ maybe-install-info-byacc \
+ maybe-install-info-bzip2 \
+ maybe-install-info-dejagnu \
+ maybe-install-info-diff \
+ maybe-install-info-dosutils \
+ maybe-install-info-etc \
+ maybe-install-info-fastjar \
+ maybe-install-info-fileutils \
+ maybe-install-info-findutils \
+ maybe-install-info-find \
+ maybe-install-info-flex \
+ maybe-install-info-gas \
+ maybe-install-info-gawk \
+ maybe-install-info-gettext \
+ maybe-install-info-gnuserv \
+ maybe-install-info-gprof \
+ maybe-install-info-gzip \
+ maybe-install-info-hello \
+ maybe-install-info-indent \
+ maybe-install-info-intl \
+ maybe-install-info-tcl \
+ maybe-install-info-itcl \
+ maybe-install-info-ld \
+ maybe-install-info-libgui \
+ maybe-install-info-libiberty \
+ maybe-install-info-libtool \
+ maybe-install-info-m4 \
+ maybe-install-info-make \
+ maybe-install-info-mmalloc \
+ maybe-install-info-patch \
+ maybe-install-info-perl \
+ maybe-install-info-prms \
+ maybe-install-info-rcs \
+ maybe-install-info-readline \
+ maybe-install-info-release \
+ maybe-install-info-recode \
+ maybe-install-info-sed \
+ maybe-install-info-send-pr \
+ maybe-install-info-shellutils \
+ maybe-install-info-sid \
+ maybe-install-info-sim \
+ maybe-install-info-tar \
+ maybe-install-info-texinfo \
+ maybe-install-info-textutils \
+ maybe-install-info-time \
+ maybe-install-info-uudecode \
+ maybe-install-info-wdiff \
+ maybe-install-info-zip \
+ maybe-install-info-zlib \
+ maybe-install-info-gdb \
+ maybe-install-info-expect \
+ maybe-install-info-guile \
+ maybe-install-info-tk \
+ maybe-install-info-tix \
+ maybe-install-info-libtermcap \
+ maybe-install-info-utils
+
+.PHONY: install-info-target
+install-info-target: \
+ maybe-install-info-target-libstdc++-v3 \
+ maybe-install-info-target-newlib \
+ maybe-install-info-target-libf2c \
+ maybe-install-info-target-libobjc \
+ maybe-install-info-target-libtermcap \
+ maybe-install-info-target-winsup \
+ maybe-install-info-target-libgloss \
+ maybe-install-info-target-libiberty \
+ maybe-install-info-target-gperf \
+ maybe-install-info-target-examples \
+ maybe-install-info-target-libffi \
+ maybe-install-info-target-libjava \
+ maybe-install-info-target-zlib \
+ maybe-install-info-target-boehm-gc \
+ maybe-install-info-target-qthreads \
+ maybe-install-info-target-rda \
+ maybe-install-info-target-libada
+
+# GCC, the eternal special case
+.PHONY: maybe-install-info-gcc install-info-gcc
+maybe-install-info-gcc:
+install-info-gcc: \
+ configure-gcc \
+ info-gcc
+ @[ -f ./gcc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_GCC_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in gcc" ; \
+ (cd gcc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+# Host modules.
+
+.PHONY: maybe-install-info-ash install-info-ash
+maybe-install-info-ash:
+
+install-info-ash: \
+ configure-ash \
+ info-ash
+ @[ -f ./ash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in ash" ; \
+ (cd ash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-autoconf install-info-autoconf
+maybe-install-info-autoconf:
+
+install-info-autoconf: \
+ configure-autoconf \
+ info-autoconf
+ @[ -f ./autoconf/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in autoconf" ; \
+ (cd autoconf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-automake install-info-automake
+maybe-install-info-automake:
+
+install-info-automake: \
+ configure-automake \
+ info-automake
+ @[ -f ./automake/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in automake" ; \
+ (cd automake && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-bash install-info-bash
+maybe-install-info-bash:
+
+install-info-bash: \
+ configure-bash \
+ info-bash
+ @[ -f ./bash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in bash" ; \
+ (cd bash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-bfd install-info-bfd
+maybe-install-info-bfd:
+
+install-info-bfd: \
+ configure-bfd \
+ info-bfd
+ @[ -f ./bfd/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in bfd" ; \
+ (cd bfd && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-opcodes install-info-opcodes
+maybe-install-info-opcodes:
+
+install-info-opcodes: \
+ configure-opcodes \
+ info-opcodes
+ @[ -f ./opcodes/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in opcodes" ; \
+ (cd opcodes && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-binutils install-info-binutils
+maybe-install-info-binutils:
+
+install-info-binutils: \
+ configure-binutils \
+ info-binutils
+ @[ -f ./binutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in binutils" ; \
+ (cd binutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-bison install-info-bison
+maybe-install-info-bison:
+
+install-info-bison: \
+ configure-bison \
+ info-bison
+ @[ -f ./bison/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in bison" ; \
+ (cd bison && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-byacc install-info-byacc
+maybe-install-info-byacc:
+
+install-info-byacc: \
+ configure-byacc \
+ info-byacc
+ @[ -f ./byacc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in byacc" ; \
+ (cd byacc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-bzip2 install-info-bzip2
+maybe-install-info-bzip2:
+
+install-info-bzip2: \
+ configure-bzip2 \
+ info-bzip2
+ @[ -f ./bzip2/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in bzip2" ; \
+ (cd bzip2 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-dejagnu install-info-dejagnu
+maybe-install-info-dejagnu:
+
+install-info-dejagnu: \
+ configure-dejagnu \
+ info-dejagnu
+ @[ -f ./dejagnu/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in dejagnu" ; \
+ (cd dejagnu && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-diff install-info-diff
+maybe-install-info-diff:
+
+install-info-diff: \
+ configure-diff \
+ info-diff
+ @[ -f ./diff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in diff" ; \
+ (cd diff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-dosutils install-info-dosutils
+maybe-install-info-dosutils:
+
+install-info-dosutils: \
+ configure-dosutils \
+ info-dosutils
+ @[ -f ./dosutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in dosutils" ; \
+ (cd dosutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-etc install-info-etc
+maybe-install-info-etc:
+
+install-info-etc: \
+ configure-etc \
+ info-etc
+ @[ -f ./etc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in etc" ; \
+ (cd etc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-fastjar install-info-fastjar
+maybe-install-info-fastjar:
+
+install-info-fastjar: \
+ configure-fastjar \
+ info-fastjar
+ @[ -f ./fastjar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in fastjar" ; \
+ (cd fastjar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-fileutils install-info-fileutils
+maybe-install-info-fileutils:
+
+install-info-fileutils: \
+ configure-fileutils \
+ info-fileutils
+ @[ -f ./fileutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in fileutils" ; \
+ (cd fileutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-findutils install-info-findutils
+maybe-install-info-findutils:
+
+install-info-findutils: \
+ configure-findutils \
+ info-findutils
+ @[ -f ./findutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in findutils" ; \
+ (cd findutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-find install-info-find
+maybe-install-info-find:
+
+install-info-find: \
+ configure-find \
+ info-find
+ @[ -f ./find/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in find" ; \
+ (cd find && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-flex install-info-flex
+maybe-install-info-flex:
+
+install-info-flex: \
+ configure-flex \
+ info-flex
+ @[ -f ./flex/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in flex" ; \
+ (cd flex && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-gas install-info-gas
+maybe-install-info-gas:
+
+install-info-gas: \
+ configure-gas \
+ info-gas
+ @[ -f ./gas/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in gas" ; \
+ (cd gas && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-gawk install-info-gawk
+maybe-install-info-gawk:
+
+install-info-gawk: \
+ configure-gawk \
+ info-gawk
+ @[ -f ./gawk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in gawk" ; \
+ (cd gawk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-gettext install-info-gettext
+maybe-install-info-gettext:
+
+install-info-gettext: \
+ configure-gettext \
+ info-gettext
+ @[ -f ./gettext/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in gettext" ; \
+ (cd gettext && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-gnuserv install-info-gnuserv
+maybe-install-info-gnuserv:
+
+install-info-gnuserv: \
+ configure-gnuserv \
+ info-gnuserv
+ @[ -f ./gnuserv/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in gnuserv" ; \
+ (cd gnuserv && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-gprof install-info-gprof
+maybe-install-info-gprof:
+
+install-info-gprof: \
+ configure-gprof \
+ info-gprof
+ @[ -f ./gprof/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in gprof" ; \
+ (cd gprof && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-gzip install-info-gzip
+maybe-install-info-gzip:
+
+install-info-gzip: \
+ configure-gzip \
+ info-gzip
+ @[ -f ./gzip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in gzip" ; \
+ (cd gzip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-hello install-info-hello
+maybe-install-info-hello:
+
+install-info-hello: \
+ configure-hello \
+ info-hello
+ @[ -f ./hello/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in hello" ; \
+ (cd hello && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-indent install-info-indent
+maybe-install-info-indent:
+
+install-info-indent: \
+ configure-indent \
+ info-indent
+ @[ -f ./indent/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in indent" ; \
+ (cd indent && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-intl install-info-intl
+maybe-install-info-intl:
+
+install-info-intl: \
+ configure-intl \
+ info-intl
+ @[ -f ./intl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in intl" ; \
+ (cd intl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-tcl install-info-tcl
+maybe-install-info-tcl:
+
+install-info-tcl: \
+ configure-tcl \
+ info-tcl
+ @[ -f ./tcl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in tcl" ; \
+ (cd tcl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-itcl install-info-itcl
+maybe-install-info-itcl:
+
+install-info-itcl: \
+ configure-itcl \
+ info-itcl
+ @[ -f ./itcl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in itcl" ; \
+ (cd itcl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-ld install-info-ld
+maybe-install-info-ld:
+
+install-info-ld: \
+ configure-ld \
+ info-ld
+ @[ -f ./ld/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in ld" ; \
+ (cd ld && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-libgui install-info-libgui
+maybe-install-info-libgui:
+
+install-info-libgui: \
+ configure-libgui \
+ info-libgui
+ @[ -f ./libgui/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in libgui" ; \
+ (cd libgui && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-libiberty install-info-libiberty
+maybe-install-info-libiberty:
+
+install-info-libiberty: \
+ configure-libiberty \
+ info-libiberty
+ @[ -f ./libiberty/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in libiberty" ; \
+ (cd libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-libtool install-info-libtool
+maybe-install-info-libtool:
+
+install-info-libtool: \
+ configure-libtool \
+ info-libtool
+ @[ -f ./libtool/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in libtool" ; \
+ (cd libtool && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-m4 install-info-m4
+maybe-install-info-m4:
+
+install-info-m4: \
+ configure-m4 \
+ info-m4
+ @[ -f ./m4/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in m4" ; \
+ (cd m4 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-make install-info-make
+maybe-install-info-make:
+
+install-info-make: \
+ configure-make \
+ info-make
+ @[ -f ./make/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in make" ; \
+ (cd make && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-mmalloc install-info-mmalloc
+maybe-install-info-mmalloc:
+
+install-info-mmalloc: \
+ configure-mmalloc \
+ info-mmalloc
+ @[ -f ./mmalloc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in mmalloc" ; \
+ (cd mmalloc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-patch install-info-patch
+maybe-install-info-patch:
+
+install-info-patch: \
+ configure-patch \
+ info-patch
+ @[ -f ./patch/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in patch" ; \
+ (cd patch && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-perl install-info-perl
+maybe-install-info-perl:
+
+install-info-perl: \
+ configure-perl \
+ info-perl
+ @[ -f ./perl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in perl" ; \
+ (cd perl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-prms install-info-prms
+maybe-install-info-prms:
+
+install-info-prms: \
+ configure-prms \
+ info-prms
+ @[ -f ./prms/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in prms" ; \
+ (cd prms && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-rcs install-info-rcs
+maybe-install-info-rcs:
+
+install-info-rcs: \
+ configure-rcs \
+ info-rcs
+ @[ -f ./rcs/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in rcs" ; \
+ (cd rcs && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-readline install-info-readline
+maybe-install-info-readline:
+
+install-info-readline: \
+ configure-readline \
+ info-readline
+ @[ -f ./readline/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in readline" ; \
+ (cd readline && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-release install-info-release
+maybe-install-info-release:
+
+install-info-release: \
+ configure-release \
+ info-release
+ @[ -f ./release/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in release" ; \
+ (cd release && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-recode install-info-recode
+maybe-install-info-recode:
+
+install-info-recode: \
+ configure-recode \
+ info-recode
+ @[ -f ./recode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in recode" ; \
+ (cd recode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-sed install-info-sed
+maybe-install-info-sed:
+
+install-info-sed: \
+ configure-sed \
+ info-sed
+ @[ -f ./sed/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in sed" ; \
+ (cd sed && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-send-pr install-info-send-pr
+maybe-install-info-send-pr:
+
+install-info-send-pr: \
+ configure-send-pr \
+ info-send-pr
+ @[ -f ./send-pr/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in send-pr" ; \
+ (cd send-pr && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-shellutils install-info-shellutils
+maybe-install-info-shellutils:
+
+install-info-shellutils: \
+ configure-shellutils \
+ info-shellutils
+ @[ -f ./shellutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in shellutils" ; \
+ (cd shellutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-sid install-info-sid
+maybe-install-info-sid:
+
+install-info-sid: \
+ configure-sid \
+ info-sid
+ @[ -f ./sid/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in sid" ; \
+ (cd sid && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-sim install-info-sim
+maybe-install-info-sim:
+
+install-info-sim: \
+ configure-sim \
+ info-sim
+ @[ -f ./sim/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in sim" ; \
+ (cd sim && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-tar install-info-tar
+maybe-install-info-tar:
+
+install-info-tar: \
+ configure-tar \
+ info-tar
+ @[ -f ./tar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in tar" ; \
+ (cd tar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-texinfo install-info-texinfo
+maybe-install-info-texinfo:
+
+install-info-texinfo: \
+ configure-texinfo \
+ info-texinfo
+ @[ -f ./texinfo/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in texinfo" ; \
+ (cd texinfo && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-textutils install-info-textutils
+maybe-install-info-textutils:
+
+install-info-textutils: \
+ configure-textutils \
+ info-textutils
+ @[ -f ./textutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in textutils" ; \
+ (cd textutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-time install-info-time
+maybe-install-info-time:
+
+install-info-time: \
+ configure-time \
+ info-time
+ @[ -f ./time/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in time" ; \
+ (cd time && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-uudecode install-info-uudecode
+maybe-install-info-uudecode:
+
+install-info-uudecode: \
+ configure-uudecode \
+ info-uudecode
+ @[ -f ./uudecode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in uudecode" ; \
+ (cd uudecode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-wdiff install-info-wdiff
+maybe-install-info-wdiff:
+
+install-info-wdiff: \
+ configure-wdiff \
+ info-wdiff
+ @[ -f ./wdiff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in wdiff" ; \
+ (cd wdiff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-zip install-info-zip
+maybe-install-info-zip:
+
+install-info-zip: \
+ configure-zip \
+ info-zip
+ @[ -f ./zip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in zip" ; \
+ (cd zip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-zlib install-info-zlib
+maybe-install-info-zlib:
+
+install-info-zlib: \
+ configure-zlib \
+ info-zlib
+ @[ -f ./zlib/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in zlib" ; \
+ (cd zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-gdb install-info-gdb
+maybe-install-info-gdb:
+
+install-info-gdb: \
+ configure-gdb \
+ info-gdb
+ @[ -f ./gdb/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in gdb" ; \
+ (cd gdb && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-expect install-info-expect
+maybe-install-info-expect:
+
+install-info-expect: \
+ configure-expect \
+ info-expect
+ @[ -f ./expect/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in expect" ; \
+ (cd expect && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-guile install-info-guile
+maybe-install-info-guile:
+
+install-info-guile: \
+ configure-guile \
+ info-guile
+ @[ -f ./guile/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in guile" ; \
+ (cd guile && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-tk install-info-tk
+maybe-install-info-tk:
+
+install-info-tk: \
+ configure-tk \
+ info-tk
+ @[ -f ./tk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in tk" ; \
+ (cd tk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-tix install-info-tix
+maybe-install-info-tix:
+
+install-info-tix: \
+ configure-tix \
+ info-tix
+ @[ -f ./tix/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in tix" ; \
+ (cd tix && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-libtermcap install-info-libtermcap
+maybe-install-info-libtermcap:
+
+install-info-libtermcap: \
+ configure-libtermcap \
+ info-libtermcap
+ @[ -f ./libtermcap/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in libtermcap" ; \
+ (cd libtermcap && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-utils install-info-utils
+maybe-install-info-utils:
+
+install-info-utils: \
+ configure-utils \
+ info-utils
+ @[ -f ./utils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing install-info in utils" ; \
+ (cd utils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+
+# Target modules.
+
+.PHONY: maybe-install-info-target-libstdc++-v3 install-info-target-libstdc++-v3
+maybe-install-info-target-libstdc++-v3:
+
+install-info-target-libstdc++-v3: \
+ configure-target-libstdc++-v3 \
+ info-target-libstdc++-v3
+ @[ -f $(TARGET_SUBDIR)/libstdc++-v3/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing install-info in $(TARGET_SUBDIR)/libstdc++-v3" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libstdc++-v3 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-target-newlib install-info-target-newlib
+maybe-install-info-target-newlib:
+
+install-info-target-newlib: \
+ configure-target-newlib \
+ info-target-newlib
+ @[ -f $(TARGET_SUBDIR)/newlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing install-info in $(TARGET_SUBDIR)/newlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/newlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-target-libf2c install-info-target-libf2c
+maybe-install-info-target-libf2c:
+
+install-info-target-libf2c: \
+ configure-target-libf2c \
+ info-target-libf2c
+ @[ -f $(TARGET_SUBDIR)/libf2c/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing install-info in $(TARGET_SUBDIR)/libf2c" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libf2c && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-target-libobjc install-info-target-libobjc
+maybe-install-info-target-libobjc:
+
+install-info-target-libobjc: \
+ configure-target-libobjc \
+ info-target-libobjc
+ @[ -f $(TARGET_SUBDIR)/libobjc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing install-info in $(TARGET_SUBDIR)/libobjc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libobjc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-target-libtermcap install-info-target-libtermcap
+maybe-install-info-target-libtermcap:
+
+install-info-target-libtermcap: \
+ configure-target-libtermcap \
+ info-target-libtermcap
+ @[ -f $(TARGET_SUBDIR)/libtermcap/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing install-info in $(TARGET_SUBDIR)/libtermcap" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libtermcap && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-target-winsup install-info-target-winsup
+maybe-install-info-target-winsup:
+
+install-info-target-winsup: \
+ configure-target-winsup \
+ info-target-winsup
+ @[ -f $(TARGET_SUBDIR)/winsup/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing install-info in $(TARGET_SUBDIR)/winsup" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/winsup && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-target-libgloss install-info-target-libgloss
+maybe-install-info-target-libgloss:
+
+install-info-target-libgloss: \
+ configure-target-libgloss \
+ info-target-libgloss
+ @[ -f $(TARGET_SUBDIR)/libgloss/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing install-info in $(TARGET_SUBDIR)/libgloss" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libgloss && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-target-libiberty install-info-target-libiberty
+maybe-install-info-target-libiberty:
+
+install-info-target-libiberty: \
+ configure-target-libiberty \
+ info-target-libiberty
+ @[ -f $(TARGET_SUBDIR)/libiberty/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing install-info in $(TARGET_SUBDIR)/libiberty" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-target-gperf install-info-target-gperf
+maybe-install-info-target-gperf:
+
+install-info-target-gperf: \
+ configure-target-gperf \
+ info-target-gperf
+ @[ -f $(TARGET_SUBDIR)/gperf/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing install-info in $(TARGET_SUBDIR)/gperf" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/gperf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-target-examples install-info-target-examples
+maybe-install-info-target-examples:
+
+install-info-target-examples: \
+ configure-target-examples \
+ info-target-examples
+ @[ -f $(TARGET_SUBDIR)/examples/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing install-info in $(TARGET_SUBDIR)/examples" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/examples && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-target-libffi install-info-target-libffi
+maybe-install-info-target-libffi:
+
+install-info-target-libffi: \
+ configure-target-libffi \
+ info-target-libffi
+ @[ -f $(TARGET_SUBDIR)/libffi/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing install-info in $(TARGET_SUBDIR)/libffi" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libffi && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-target-libjava install-info-target-libjava
+maybe-install-info-target-libjava:
+
+install-info-target-libjava: \
+ configure-target-libjava \
+ info-target-libjava
+ @[ -f $(TARGET_SUBDIR)/libjava/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing install-info in $(TARGET_SUBDIR)/libjava" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libjava && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-target-zlib install-info-target-zlib
+maybe-install-info-target-zlib:
+
+install-info-target-zlib: \
+ configure-target-zlib \
+ info-target-zlib
+ @[ -f $(TARGET_SUBDIR)/zlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing install-info in $(TARGET_SUBDIR)/zlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-target-boehm-gc install-info-target-boehm-gc
+maybe-install-info-target-boehm-gc:
+
+install-info-target-boehm-gc: \
+ configure-target-boehm-gc \
+ info-target-boehm-gc
+ @[ -f $(TARGET_SUBDIR)/boehm-gc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing install-info in $(TARGET_SUBDIR)/boehm-gc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/boehm-gc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-target-qthreads install-info-target-qthreads
+maybe-install-info-target-qthreads:
+
+install-info-target-qthreads: \
+ configure-target-qthreads \
+ info-target-qthreads
+ @[ -f $(TARGET_SUBDIR)/qthreads/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing install-info in $(TARGET_SUBDIR)/qthreads" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/qthreads && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-target-rda install-info-target-rda
+maybe-install-info-target-rda:
+
+install-info-target-rda: \
+ configure-target-rda \
+ info-target-rda
+ @[ -f $(TARGET_SUBDIR)/rda/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing install-info in $(TARGET_SUBDIR)/rda" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/rda && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+.PHONY: maybe-install-info-target-libada install-info-target-libada
+maybe-install-info-target-libada:
+
+install-info-target-libada: \
+ configure-target-libada \
+ info-target-libada
+ @[ -f $(TARGET_SUBDIR)/libada/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing install-info in $(TARGET_SUBDIR)/libada" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libada && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ install-info) \
+ || exit 1
+
+
+
+.PHONY: do-installcheck
+do-installcheck: installcheck-host installcheck-target
+
+.PHONY: installcheck-host
+installcheck-host: maybe-installcheck-gcc \
+ maybe-installcheck-ash \
+ maybe-installcheck-autoconf \
+ maybe-installcheck-automake \
+ maybe-installcheck-bash \
+ maybe-installcheck-bfd \
+ maybe-installcheck-opcodes \
+ maybe-installcheck-binutils \
+ maybe-installcheck-bison \
+ maybe-installcheck-byacc \
+ maybe-installcheck-bzip2 \
+ maybe-installcheck-dejagnu \
+ maybe-installcheck-diff \
+ maybe-installcheck-dosutils \
+ maybe-installcheck-etc \
+ maybe-installcheck-fastjar \
+ maybe-installcheck-fileutils \
+ maybe-installcheck-findutils \
+ maybe-installcheck-find \
+ maybe-installcheck-flex \
+ maybe-installcheck-gas \
+ maybe-installcheck-gawk \
+ maybe-installcheck-gettext \
+ maybe-installcheck-gnuserv \
+ maybe-installcheck-gprof \
+ maybe-installcheck-gzip \
+ maybe-installcheck-hello \
+ maybe-installcheck-indent \
+ maybe-installcheck-intl \
+ maybe-installcheck-tcl \
+ maybe-installcheck-itcl \
+ maybe-installcheck-ld \
+ maybe-installcheck-libgui \
+ maybe-installcheck-libiberty \
+ maybe-installcheck-libtool \
+ maybe-installcheck-m4 \
+ maybe-installcheck-make \
+ maybe-installcheck-mmalloc \
+ maybe-installcheck-patch \
+ maybe-installcheck-perl \
+ maybe-installcheck-prms \
+ maybe-installcheck-rcs \
+ maybe-installcheck-readline \
+ maybe-installcheck-release \
+ maybe-installcheck-recode \
+ maybe-installcheck-sed \
+ maybe-installcheck-send-pr \
+ maybe-installcheck-shellutils \
+ maybe-installcheck-sid \
+ maybe-installcheck-sim \
+ maybe-installcheck-tar \
+ maybe-installcheck-texinfo \
+ maybe-installcheck-textutils \
+ maybe-installcheck-time \
+ maybe-installcheck-uudecode \
+ maybe-installcheck-wdiff \
+ maybe-installcheck-zip \
+ maybe-installcheck-zlib \
+ maybe-installcheck-gdb \
+ maybe-installcheck-expect \
+ maybe-installcheck-guile \
+ maybe-installcheck-tk \
+ maybe-installcheck-tix \
+ maybe-installcheck-libtermcap \
+ maybe-installcheck-utils
+
+.PHONY: installcheck-target
+installcheck-target: \
+ maybe-installcheck-target-libstdc++-v3 \
+ maybe-installcheck-target-newlib \
+ maybe-installcheck-target-libf2c \
+ maybe-installcheck-target-libobjc \
+ maybe-installcheck-target-libtermcap \
+ maybe-installcheck-target-winsup \
+ maybe-installcheck-target-libgloss \
+ maybe-installcheck-target-libiberty \
+ maybe-installcheck-target-gperf \
+ maybe-installcheck-target-examples \
+ maybe-installcheck-target-libffi \
+ maybe-installcheck-target-libjava \
+ maybe-installcheck-target-zlib \
+ maybe-installcheck-target-boehm-gc \
+ maybe-installcheck-target-qthreads \
+ maybe-installcheck-target-rda \
+ maybe-installcheck-target-libada
+
+# GCC, the eternal special case
+.PHONY: maybe-installcheck-gcc installcheck-gcc
+maybe-installcheck-gcc:
+installcheck-gcc: \
+ configure-gcc
+ @[ -f ./gcc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_GCC_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in gcc" ; \
+ (cd gcc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+# Host modules.
+
+.PHONY: maybe-installcheck-ash installcheck-ash
+maybe-installcheck-ash:
+
+installcheck-ash: \
+ configure-ash
+ @[ -f ./ash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in ash" ; \
+ (cd ash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-autoconf installcheck-autoconf
+maybe-installcheck-autoconf:
+
+installcheck-autoconf: \
+ configure-autoconf
+ @[ -f ./autoconf/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in autoconf" ; \
+ (cd autoconf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-automake installcheck-automake
+maybe-installcheck-automake:
+
+installcheck-automake: \
+ configure-automake
+ @[ -f ./automake/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in automake" ; \
+ (cd automake && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-bash installcheck-bash
+maybe-installcheck-bash:
+
+installcheck-bash: \
+ configure-bash
+ @[ -f ./bash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in bash" ; \
+ (cd bash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-bfd installcheck-bfd
+maybe-installcheck-bfd:
+
+installcheck-bfd: \
+ configure-bfd
+ @[ -f ./bfd/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in bfd" ; \
+ (cd bfd && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-opcodes installcheck-opcodes
+maybe-installcheck-opcodes:
+
+installcheck-opcodes: \
+ configure-opcodes
+ @[ -f ./opcodes/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in opcodes" ; \
+ (cd opcodes && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-binutils installcheck-binutils
+maybe-installcheck-binutils:
+
+installcheck-binutils: \
+ configure-binutils
+ @[ -f ./binutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in binutils" ; \
+ (cd binutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-bison installcheck-bison
+maybe-installcheck-bison:
+
+installcheck-bison: \
+ configure-bison
+ @[ -f ./bison/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in bison" ; \
+ (cd bison && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-byacc installcheck-byacc
+maybe-installcheck-byacc:
+
+installcheck-byacc: \
+ configure-byacc
+ @[ -f ./byacc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in byacc" ; \
+ (cd byacc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-bzip2 installcheck-bzip2
+maybe-installcheck-bzip2:
+
+installcheck-bzip2: \
+ configure-bzip2
+ @[ -f ./bzip2/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in bzip2" ; \
+ (cd bzip2 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-dejagnu installcheck-dejagnu
+maybe-installcheck-dejagnu:
+
+installcheck-dejagnu: \
+ configure-dejagnu
+ @[ -f ./dejagnu/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in dejagnu" ; \
+ (cd dejagnu && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-diff installcheck-diff
+maybe-installcheck-diff:
+
+installcheck-diff: \
+ configure-diff
+ @[ -f ./diff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in diff" ; \
+ (cd diff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-dosutils installcheck-dosutils
+maybe-installcheck-dosutils:
+
+installcheck-dosutils: \
+ configure-dosutils
+ @[ -f ./dosutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in dosutils" ; \
+ (cd dosutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-etc installcheck-etc
+maybe-installcheck-etc:
+
+installcheck-etc: \
+ configure-etc
+ @[ -f ./etc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in etc" ; \
+ (cd etc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-fastjar installcheck-fastjar
+maybe-installcheck-fastjar:
+
+installcheck-fastjar: \
+ configure-fastjar
+ @[ -f ./fastjar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in fastjar" ; \
+ (cd fastjar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-fileutils installcheck-fileutils
+maybe-installcheck-fileutils:
+
+installcheck-fileutils: \
+ configure-fileutils
+ @[ -f ./fileutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in fileutils" ; \
+ (cd fileutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-findutils installcheck-findutils
+maybe-installcheck-findutils:
+
+installcheck-findutils: \
+ configure-findutils
+ @[ -f ./findutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in findutils" ; \
+ (cd findutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-find installcheck-find
+maybe-installcheck-find:
+
+installcheck-find: \
+ configure-find
+ @[ -f ./find/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in find" ; \
+ (cd find && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-flex installcheck-flex
+maybe-installcheck-flex:
+
+installcheck-flex: \
+ configure-flex
+ @[ -f ./flex/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in flex" ; \
+ (cd flex && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-gas installcheck-gas
+maybe-installcheck-gas:
+
+installcheck-gas: \
+ configure-gas
+ @[ -f ./gas/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in gas" ; \
+ (cd gas && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-gawk installcheck-gawk
+maybe-installcheck-gawk:
+
+installcheck-gawk: \
+ configure-gawk
+ @[ -f ./gawk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in gawk" ; \
+ (cd gawk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-gettext installcheck-gettext
+maybe-installcheck-gettext:
+
+installcheck-gettext: \
+ configure-gettext
+ @[ -f ./gettext/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in gettext" ; \
+ (cd gettext && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-gnuserv installcheck-gnuserv
+maybe-installcheck-gnuserv:
+
+installcheck-gnuserv: \
+ configure-gnuserv
+ @[ -f ./gnuserv/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in gnuserv" ; \
+ (cd gnuserv && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-gprof installcheck-gprof
+maybe-installcheck-gprof:
+
+installcheck-gprof: \
+ configure-gprof
+ @[ -f ./gprof/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in gprof" ; \
+ (cd gprof && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-gzip installcheck-gzip
+maybe-installcheck-gzip:
+
+installcheck-gzip: \
+ configure-gzip
+ @[ -f ./gzip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in gzip" ; \
+ (cd gzip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-hello installcheck-hello
+maybe-installcheck-hello:
+
+installcheck-hello: \
+ configure-hello
+ @[ -f ./hello/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in hello" ; \
+ (cd hello && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-indent installcheck-indent
+maybe-installcheck-indent:
+
+installcheck-indent: \
+ configure-indent
+ @[ -f ./indent/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in indent" ; \
+ (cd indent && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-intl installcheck-intl
+maybe-installcheck-intl:
+
+installcheck-intl: \
+ configure-intl
+ @[ -f ./intl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in intl" ; \
+ (cd intl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-tcl installcheck-tcl
+maybe-installcheck-tcl:
+
+installcheck-tcl: \
+ configure-tcl
+ @[ -f ./tcl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in tcl" ; \
+ (cd tcl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-itcl installcheck-itcl
+maybe-installcheck-itcl:
+
+installcheck-itcl: \
+ configure-itcl
+ @[ -f ./itcl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in itcl" ; \
+ (cd itcl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-ld installcheck-ld
+maybe-installcheck-ld:
+
+installcheck-ld: \
+ configure-ld
+ @[ -f ./ld/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in ld" ; \
+ (cd ld && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-libgui installcheck-libgui
+maybe-installcheck-libgui:
+
+installcheck-libgui: \
+ configure-libgui
+ @[ -f ./libgui/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in libgui" ; \
+ (cd libgui && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-libiberty installcheck-libiberty
+maybe-installcheck-libiberty:
+
+installcheck-libiberty: \
+ configure-libiberty
+ @[ -f ./libiberty/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in libiberty" ; \
+ (cd libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-libtool installcheck-libtool
+maybe-installcheck-libtool:
+
+installcheck-libtool: \
+ configure-libtool
+ @[ -f ./libtool/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in libtool" ; \
+ (cd libtool && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-m4 installcheck-m4
+maybe-installcheck-m4:
+
+installcheck-m4: \
+ configure-m4
+ @[ -f ./m4/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in m4" ; \
+ (cd m4 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-make installcheck-make
+maybe-installcheck-make:
+
+installcheck-make: \
+ configure-make
+ @[ -f ./make/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in make" ; \
+ (cd make && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-mmalloc installcheck-mmalloc
+maybe-installcheck-mmalloc:
+
+installcheck-mmalloc: \
+ configure-mmalloc
+ @[ -f ./mmalloc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in mmalloc" ; \
+ (cd mmalloc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-patch installcheck-patch
+maybe-installcheck-patch:
+
+installcheck-patch: \
+ configure-patch
+ @[ -f ./patch/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in patch" ; \
+ (cd patch && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-perl installcheck-perl
+maybe-installcheck-perl:
+
+installcheck-perl: \
+ configure-perl
+ @[ -f ./perl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in perl" ; \
+ (cd perl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-prms installcheck-prms
+maybe-installcheck-prms:
+
+installcheck-prms: \
+ configure-prms
+ @[ -f ./prms/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in prms" ; \
+ (cd prms && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-rcs installcheck-rcs
+maybe-installcheck-rcs:
+
+installcheck-rcs: \
+ configure-rcs
+ @[ -f ./rcs/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in rcs" ; \
+ (cd rcs && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-readline installcheck-readline
+maybe-installcheck-readline:
+
+installcheck-readline: \
+ configure-readline
+ @[ -f ./readline/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in readline" ; \
+ (cd readline && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-release installcheck-release
+maybe-installcheck-release:
+
+installcheck-release: \
+ configure-release
+ @[ -f ./release/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in release" ; \
+ (cd release && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-recode installcheck-recode
+maybe-installcheck-recode:
+
+installcheck-recode: \
+ configure-recode
+ @[ -f ./recode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in recode" ; \
+ (cd recode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-sed installcheck-sed
+maybe-installcheck-sed:
+
+installcheck-sed: \
+ configure-sed
+ @[ -f ./sed/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in sed" ; \
+ (cd sed && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-send-pr installcheck-send-pr
+maybe-installcheck-send-pr:
+
+installcheck-send-pr: \
+ configure-send-pr
+ @[ -f ./send-pr/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in send-pr" ; \
+ (cd send-pr && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-shellutils installcheck-shellutils
+maybe-installcheck-shellutils:
+
+installcheck-shellutils: \
+ configure-shellutils
+ @[ -f ./shellutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in shellutils" ; \
+ (cd shellutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-sid installcheck-sid
+maybe-installcheck-sid:
+
+installcheck-sid: \
+ configure-sid
+ @[ -f ./sid/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in sid" ; \
+ (cd sid && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-sim installcheck-sim
+maybe-installcheck-sim:
+
+installcheck-sim: \
+ configure-sim
+ @[ -f ./sim/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in sim" ; \
+ (cd sim && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-tar installcheck-tar
+maybe-installcheck-tar:
+
+installcheck-tar: \
+ configure-tar
+ @[ -f ./tar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in tar" ; \
+ (cd tar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-texinfo installcheck-texinfo
+maybe-installcheck-texinfo:
+
+installcheck-texinfo: \
+ configure-texinfo
+ @[ -f ./texinfo/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in texinfo" ; \
+ (cd texinfo && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-textutils installcheck-textutils
+maybe-installcheck-textutils:
+
+installcheck-textutils: \
+ configure-textutils
+ @[ -f ./textutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in textutils" ; \
+ (cd textutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-time installcheck-time
+maybe-installcheck-time:
+
+installcheck-time: \
+ configure-time
+ @[ -f ./time/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in time" ; \
+ (cd time && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-uudecode installcheck-uudecode
+maybe-installcheck-uudecode:
+
+installcheck-uudecode: \
+ configure-uudecode
+ @[ -f ./uudecode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in uudecode" ; \
+ (cd uudecode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-wdiff installcheck-wdiff
+maybe-installcheck-wdiff:
+
+installcheck-wdiff: \
+ configure-wdiff
+ @[ -f ./wdiff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in wdiff" ; \
+ (cd wdiff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-zip installcheck-zip
+maybe-installcheck-zip:
+
+installcheck-zip: \
+ configure-zip
+ @[ -f ./zip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in zip" ; \
+ (cd zip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-zlib installcheck-zlib
+maybe-installcheck-zlib:
+
+installcheck-zlib: \
+ configure-zlib
+ @[ -f ./zlib/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in zlib" ; \
+ (cd zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-gdb installcheck-gdb
+maybe-installcheck-gdb:
+
+installcheck-gdb: \
+ configure-gdb
+ @[ -f ./gdb/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in gdb" ; \
+ (cd gdb && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-expect installcheck-expect
+maybe-installcheck-expect:
+
+installcheck-expect: \
+ configure-expect
+ @[ -f ./expect/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in expect" ; \
+ (cd expect && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-guile installcheck-guile
+maybe-installcheck-guile:
+
+installcheck-guile: \
+ configure-guile
+ @[ -f ./guile/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in guile" ; \
+ (cd guile && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-tk installcheck-tk
+maybe-installcheck-tk:
+
+installcheck-tk: \
+ configure-tk
+ @[ -f ./tk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in tk" ; \
+ (cd tk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-tix installcheck-tix
+maybe-installcheck-tix:
+
+installcheck-tix: \
+ configure-tix
+ @[ -f ./tix/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in tix" ; \
+ (cd tix && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-libtermcap installcheck-libtermcap
+maybe-installcheck-libtermcap:
+
+installcheck-libtermcap: \
+ configure-libtermcap
+ @[ -f ./libtermcap/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in libtermcap" ; \
+ (cd libtermcap && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-utils installcheck-utils
+maybe-installcheck-utils:
+
+installcheck-utils: \
+ configure-utils
+ @[ -f ./utils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing installcheck in utils" ; \
+ (cd utils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+
+# Target modules.
+
+.PHONY: maybe-installcheck-target-libstdc++-v3 installcheck-target-libstdc++-v3
+maybe-installcheck-target-libstdc++-v3:
+
+installcheck-target-libstdc++-v3: \
+ configure-target-libstdc++-v3
+ @[ -f $(TARGET_SUBDIR)/libstdc++-v3/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing installcheck in $(TARGET_SUBDIR)/libstdc++-v3" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libstdc++-v3 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-target-newlib installcheck-target-newlib
+maybe-installcheck-target-newlib:
+
+installcheck-target-newlib: \
+ configure-target-newlib
+ @[ -f $(TARGET_SUBDIR)/newlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing installcheck in $(TARGET_SUBDIR)/newlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/newlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-target-libf2c installcheck-target-libf2c
+maybe-installcheck-target-libf2c:
+
+installcheck-target-libf2c: \
+ configure-target-libf2c
+ @[ -f $(TARGET_SUBDIR)/libf2c/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing installcheck in $(TARGET_SUBDIR)/libf2c" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libf2c && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-target-libobjc installcheck-target-libobjc
+maybe-installcheck-target-libobjc:
+
+installcheck-target-libobjc: \
+ configure-target-libobjc
+ @[ -f $(TARGET_SUBDIR)/libobjc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing installcheck in $(TARGET_SUBDIR)/libobjc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libobjc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-target-libtermcap installcheck-target-libtermcap
+maybe-installcheck-target-libtermcap:
+
+installcheck-target-libtermcap: \
+ configure-target-libtermcap
+ @[ -f $(TARGET_SUBDIR)/libtermcap/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing installcheck in $(TARGET_SUBDIR)/libtermcap" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libtermcap && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-target-winsup installcheck-target-winsup
+maybe-installcheck-target-winsup:
+
+installcheck-target-winsup: \
+ configure-target-winsup
+ @[ -f $(TARGET_SUBDIR)/winsup/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing installcheck in $(TARGET_SUBDIR)/winsup" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/winsup && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-target-libgloss installcheck-target-libgloss
+maybe-installcheck-target-libgloss:
+
+installcheck-target-libgloss: \
+ configure-target-libgloss
+ @[ -f $(TARGET_SUBDIR)/libgloss/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing installcheck in $(TARGET_SUBDIR)/libgloss" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libgloss && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-target-libiberty installcheck-target-libiberty
+maybe-installcheck-target-libiberty:
+
+installcheck-target-libiberty: \
+ configure-target-libiberty
+ @[ -f $(TARGET_SUBDIR)/libiberty/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing installcheck in $(TARGET_SUBDIR)/libiberty" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-target-gperf installcheck-target-gperf
+maybe-installcheck-target-gperf:
+
+installcheck-target-gperf: \
+ configure-target-gperf
+ @[ -f $(TARGET_SUBDIR)/gperf/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing installcheck in $(TARGET_SUBDIR)/gperf" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/gperf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-target-examples installcheck-target-examples
+maybe-installcheck-target-examples:
+
+installcheck-target-examples: \
+ configure-target-examples
+ @[ -f $(TARGET_SUBDIR)/examples/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing installcheck in $(TARGET_SUBDIR)/examples" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/examples && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-target-libffi installcheck-target-libffi
+maybe-installcheck-target-libffi:
+
+installcheck-target-libffi: \
+ configure-target-libffi
+ @[ -f $(TARGET_SUBDIR)/libffi/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing installcheck in $(TARGET_SUBDIR)/libffi" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libffi && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-target-libjava installcheck-target-libjava
+maybe-installcheck-target-libjava:
+
+installcheck-target-libjava: \
+ configure-target-libjava
+ @[ -f $(TARGET_SUBDIR)/libjava/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing installcheck in $(TARGET_SUBDIR)/libjava" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libjava && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-target-zlib installcheck-target-zlib
+maybe-installcheck-target-zlib:
+
+installcheck-target-zlib: \
+ configure-target-zlib
+ @[ -f $(TARGET_SUBDIR)/zlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing installcheck in $(TARGET_SUBDIR)/zlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-target-boehm-gc installcheck-target-boehm-gc
+maybe-installcheck-target-boehm-gc:
+
+installcheck-target-boehm-gc: \
+ configure-target-boehm-gc
+ @[ -f $(TARGET_SUBDIR)/boehm-gc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing installcheck in $(TARGET_SUBDIR)/boehm-gc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/boehm-gc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-target-qthreads installcheck-target-qthreads
+maybe-installcheck-target-qthreads:
+
+installcheck-target-qthreads: \
+ configure-target-qthreads
+ @[ -f $(TARGET_SUBDIR)/qthreads/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing installcheck in $(TARGET_SUBDIR)/qthreads" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/qthreads && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-target-rda installcheck-target-rda
+maybe-installcheck-target-rda:
+
+installcheck-target-rda: \
+ configure-target-rda
+ @[ -f $(TARGET_SUBDIR)/rda/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing installcheck in $(TARGET_SUBDIR)/rda" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/rda && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+.PHONY: maybe-installcheck-target-libada installcheck-target-libada
+maybe-installcheck-target-libada:
+
+installcheck-target-libada: \
+ configure-target-libada
+ @[ -f $(TARGET_SUBDIR)/libada/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing installcheck in $(TARGET_SUBDIR)/libada" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libada && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ installcheck) \
+ || exit 1
+
+
+
+.PHONY: do-mostlyclean
+do-mostlyclean: mostlyclean-host mostlyclean-target
+
+.PHONY: mostlyclean-host
+mostlyclean-host: maybe-mostlyclean-gcc \
+ maybe-mostlyclean-ash \
+ maybe-mostlyclean-autoconf \
+ maybe-mostlyclean-automake \
+ maybe-mostlyclean-bash \
+ maybe-mostlyclean-bfd \
+ maybe-mostlyclean-opcodes \
+ maybe-mostlyclean-binutils \
+ maybe-mostlyclean-bison \
+ maybe-mostlyclean-byacc \
+ maybe-mostlyclean-bzip2 \
+ maybe-mostlyclean-dejagnu \
+ maybe-mostlyclean-diff \
+ maybe-mostlyclean-dosutils \
+ maybe-mostlyclean-etc \
+ maybe-mostlyclean-fastjar \
+ maybe-mostlyclean-fileutils \
+ maybe-mostlyclean-findutils \
+ maybe-mostlyclean-find \
+ maybe-mostlyclean-flex \
+ maybe-mostlyclean-gas \
+ maybe-mostlyclean-gawk \
+ maybe-mostlyclean-gettext \
+ maybe-mostlyclean-gnuserv \
+ maybe-mostlyclean-gprof \
+ maybe-mostlyclean-gzip \
+ maybe-mostlyclean-hello \
+ maybe-mostlyclean-indent \
+ maybe-mostlyclean-intl \
+ maybe-mostlyclean-tcl \
+ maybe-mostlyclean-itcl \
+ maybe-mostlyclean-ld \
+ maybe-mostlyclean-libgui \
+ maybe-mostlyclean-libiberty \
+ maybe-mostlyclean-libtool \
+ maybe-mostlyclean-m4 \
+ maybe-mostlyclean-make \
+ maybe-mostlyclean-mmalloc \
+ maybe-mostlyclean-patch \
+ maybe-mostlyclean-perl \
+ maybe-mostlyclean-prms \
+ maybe-mostlyclean-rcs \
+ maybe-mostlyclean-readline \
+ maybe-mostlyclean-release \
+ maybe-mostlyclean-recode \
+ maybe-mostlyclean-sed \
+ maybe-mostlyclean-send-pr \
+ maybe-mostlyclean-shellutils \
+ maybe-mostlyclean-sid \
+ maybe-mostlyclean-sim \
+ maybe-mostlyclean-tar \
+ maybe-mostlyclean-texinfo \
+ maybe-mostlyclean-textutils \
+ maybe-mostlyclean-time \
+ maybe-mostlyclean-uudecode \
+ maybe-mostlyclean-wdiff \
+ maybe-mostlyclean-zip \
+ maybe-mostlyclean-zlib \
+ maybe-mostlyclean-gdb \
+ maybe-mostlyclean-expect \
+ maybe-mostlyclean-guile \
+ maybe-mostlyclean-tk \
+ maybe-mostlyclean-tix \
+ maybe-mostlyclean-libtermcap \
+ maybe-mostlyclean-utils
+
+.PHONY: mostlyclean-target
+mostlyclean-target: \
+ maybe-mostlyclean-target-libstdc++-v3 \
+ maybe-mostlyclean-target-newlib \
+ maybe-mostlyclean-target-libf2c \
+ maybe-mostlyclean-target-libobjc \
+ maybe-mostlyclean-target-libtermcap \
+ maybe-mostlyclean-target-winsup \
+ maybe-mostlyclean-target-libgloss \
+ maybe-mostlyclean-target-libiberty \
+ maybe-mostlyclean-target-gperf \
+ maybe-mostlyclean-target-examples \
+ maybe-mostlyclean-target-libffi \
+ maybe-mostlyclean-target-libjava \
+ maybe-mostlyclean-target-zlib \
+ maybe-mostlyclean-target-boehm-gc \
+ maybe-mostlyclean-target-qthreads \
+ maybe-mostlyclean-target-rda \
+ maybe-mostlyclean-target-libada
+
+# GCC, the eternal special case
+.PHONY: maybe-mostlyclean-gcc mostlyclean-gcc
+maybe-mostlyclean-gcc:
+mostlyclean-gcc:
+ @[ -f ./gcc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_GCC_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in gcc" ; \
+ (cd gcc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+# Host modules.
+
+.PHONY: maybe-mostlyclean-ash mostlyclean-ash
+maybe-mostlyclean-ash:
+
+mostlyclean-ash:
+ @[ -f ./ash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in ash" ; \
+ (cd ash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-autoconf mostlyclean-autoconf
+maybe-mostlyclean-autoconf:
+
+mostlyclean-autoconf:
+ @[ -f ./autoconf/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in autoconf" ; \
+ (cd autoconf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-automake mostlyclean-automake
+maybe-mostlyclean-automake:
+
+mostlyclean-automake:
+ @[ -f ./automake/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in automake" ; \
+ (cd automake && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-bash mostlyclean-bash
+maybe-mostlyclean-bash:
+
+mostlyclean-bash:
+ @[ -f ./bash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in bash" ; \
+ (cd bash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-bfd mostlyclean-bfd
+maybe-mostlyclean-bfd:
+
+mostlyclean-bfd:
+ @[ -f ./bfd/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in bfd" ; \
+ (cd bfd && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-opcodes mostlyclean-opcodes
+maybe-mostlyclean-opcodes:
+
+mostlyclean-opcodes:
+ @[ -f ./opcodes/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in opcodes" ; \
+ (cd opcodes && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-binutils mostlyclean-binutils
+maybe-mostlyclean-binutils:
+
+mostlyclean-binutils:
+ @[ -f ./binutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in binutils" ; \
+ (cd binutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-bison mostlyclean-bison
+maybe-mostlyclean-bison:
+
+mostlyclean-bison:
+ @[ -f ./bison/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in bison" ; \
+ (cd bison && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-byacc mostlyclean-byacc
+maybe-mostlyclean-byacc:
+
+mostlyclean-byacc:
+ @[ -f ./byacc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in byacc" ; \
+ (cd byacc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-bzip2 mostlyclean-bzip2
+maybe-mostlyclean-bzip2:
+
+mostlyclean-bzip2:
+ @[ -f ./bzip2/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in bzip2" ; \
+ (cd bzip2 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-dejagnu mostlyclean-dejagnu
+maybe-mostlyclean-dejagnu:
+
+mostlyclean-dejagnu:
+ @[ -f ./dejagnu/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in dejagnu" ; \
+ (cd dejagnu && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-diff mostlyclean-diff
+maybe-mostlyclean-diff:
+
+mostlyclean-diff:
+ @[ -f ./diff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in diff" ; \
+ (cd diff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-dosutils mostlyclean-dosutils
+maybe-mostlyclean-dosutils:
+
+mostlyclean-dosutils:
+ @[ -f ./dosutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in dosutils" ; \
+ (cd dosutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-etc mostlyclean-etc
+maybe-mostlyclean-etc:
+
+mostlyclean-etc:
+ @[ -f ./etc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in etc" ; \
+ (cd etc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-fastjar mostlyclean-fastjar
+maybe-mostlyclean-fastjar:
+
+mostlyclean-fastjar:
+ @[ -f ./fastjar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in fastjar" ; \
+ (cd fastjar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-fileutils mostlyclean-fileutils
+maybe-mostlyclean-fileutils:
+
+mostlyclean-fileutils:
+ @[ -f ./fileutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in fileutils" ; \
+ (cd fileutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-findutils mostlyclean-findutils
+maybe-mostlyclean-findutils:
+
+mostlyclean-findutils:
+ @[ -f ./findutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in findutils" ; \
+ (cd findutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-find mostlyclean-find
+maybe-mostlyclean-find:
+
+mostlyclean-find:
+ @[ -f ./find/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in find" ; \
+ (cd find && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-flex mostlyclean-flex
+maybe-mostlyclean-flex:
+
+mostlyclean-flex:
+ @[ -f ./flex/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in flex" ; \
+ (cd flex && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-gas mostlyclean-gas
+maybe-mostlyclean-gas:
+
+mostlyclean-gas:
+ @[ -f ./gas/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in gas" ; \
+ (cd gas && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-gawk mostlyclean-gawk
+maybe-mostlyclean-gawk:
+
+mostlyclean-gawk:
+ @[ -f ./gawk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in gawk" ; \
+ (cd gawk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-gettext mostlyclean-gettext
+maybe-mostlyclean-gettext:
+
+mostlyclean-gettext:
+ @[ -f ./gettext/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in gettext" ; \
+ (cd gettext && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-gnuserv mostlyclean-gnuserv
+maybe-mostlyclean-gnuserv:
+
+mostlyclean-gnuserv:
+ @[ -f ./gnuserv/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in gnuserv" ; \
+ (cd gnuserv && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-gprof mostlyclean-gprof
+maybe-mostlyclean-gprof:
+
+mostlyclean-gprof:
+ @[ -f ./gprof/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in gprof" ; \
+ (cd gprof && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-gzip mostlyclean-gzip
+maybe-mostlyclean-gzip:
+
+mostlyclean-gzip:
+ @[ -f ./gzip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in gzip" ; \
+ (cd gzip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-hello mostlyclean-hello
+maybe-mostlyclean-hello:
+
+mostlyclean-hello:
+ @[ -f ./hello/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in hello" ; \
+ (cd hello && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-indent mostlyclean-indent
+maybe-mostlyclean-indent:
+
+mostlyclean-indent:
+ @[ -f ./indent/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in indent" ; \
+ (cd indent && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-intl mostlyclean-intl
+maybe-mostlyclean-intl:
+
+mostlyclean-intl:
+ @[ -f ./intl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in intl" ; \
+ (cd intl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-tcl mostlyclean-tcl
+maybe-mostlyclean-tcl:
+
+# tcl doesn't support mostlyclean.
+mostlyclean-tcl:
+
+
+.PHONY: maybe-mostlyclean-itcl mostlyclean-itcl
+maybe-mostlyclean-itcl:
+
+mostlyclean-itcl:
+ @[ -f ./itcl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in itcl" ; \
+ (cd itcl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-ld mostlyclean-ld
+maybe-mostlyclean-ld:
+
+mostlyclean-ld:
+ @[ -f ./ld/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in ld" ; \
+ (cd ld && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-libgui mostlyclean-libgui
+maybe-mostlyclean-libgui:
+
+mostlyclean-libgui:
+ @[ -f ./libgui/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in libgui" ; \
+ (cd libgui && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-libiberty mostlyclean-libiberty
+maybe-mostlyclean-libiberty:
+
+mostlyclean-libiberty:
+ @[ -f ./libiberty/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in libiberty" ; \
+ (cd libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-libtool mostlyclean-libtool
+maybe-mostlyclean-libtool:
+
+mostlyclean-libtool:
+ @[ -f ./libtool/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in libtool" ; \
+ (cd libtool && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-m4 mostlyclean-m4
+maybe-mostlyclean-m4:
+
+mostlyclean-m4:
+ @[ -f ./m4/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in m4" ; \
+ (cd m4 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-make mostlyclean-make
+maybe-mostlyclean-make:
+
+mostlyclean-make:
+ @[ -f ./make/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in make" ; \
+ (cd make && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-mmalloc mostlyclean-mmalloc
+maybe-mostlyclean-mmalloc:
+
+mostlyclean-mmalloc:
+ @[ -f ./mmalloc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in mmalloc" ; \
+ (cd mmalloc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-patch mostlyclean-patch
+maybe-mostlyclean-patch:
+
+mostlyclean-patch:
+ @[ -f ./patch/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in patch" ; \
+ (cd patch && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-perl mostlyclean-perl
+maybe-mostlyclean-perl:
+
+mostlyclean-perl:
+ @[ -f ./perl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in perl" ; \
+ (cd perl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-prms mostlyclean-prms
+maybe-mostlyclean-prms:
+
+mostlyclean-prms:
+ @[ -f ./prms/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in prms" ; \
+ (cd prms && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-rcs mostlyclean-rcs
+maybe-mostlyclean-rcs:
+
+mostlyclean-rcs:
+ @[ -f ./rcs/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in rcs" ; \
+ (cd rcs && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-readline mostlyclean-readline
+maybe-mostlyclean-readline:
+
+mostlyclean-readline:
+ @[ -f ./readline/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in readline" ; \
+ (cd readline && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-release mostlyclean-release
+maybe-mostlyclean-release:
+
+mostlyclean-release:
+ @[ -f ./release/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in release" ; \
+ (cd release && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-recode mostlyclean-recode
+maybe-mostlyclean-recode:
+
+mostlyclean-recode:
+ @[ -f ./recode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in recode" ; \
+ (cd recode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-sed mostlyclean-sed
+maybe-mostlyclean-sed:
+
+mostlyclean-sed:
+ @[ -f ./sed/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in sed" ; \
+ (cd sed && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-send-pr mostlyclean-send-pr
+maybe-mostlyclean-send-pr:
+
+mostlyclean-send-pr:
+ @[ -f ./send-pr/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in send-pr" ; \
+ (cd send-pr && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-shellutils mostlyclean-shellutils
+maybe-mostlyclean-shellutils:
+
+mostlyclean-shellutils:
+ @[ -f ./shellutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in shellutils" ; \
+ (cd shellutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-sid mostlyclean-sid
+maybe-mostlyclean-sid:
+
+mostlyclean-sid:
+ @[ -f ./sid/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in sid" ; \
+ (cd sid && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-sim mostlyclean-sim
+maybe-mostlyclean-sim:
+
+mostlyclean-sim:
+ @[ -f ./sim/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in sim" ; \
+ (cd sim && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-tar mostlyclean-tar
+maybe-mostlyclean-tar:
+
+mostlyclean-tar:
+ @[ -f ./tar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in tar" ; \
+ (cd tar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-texinfo mostlyclean-texinfo
+maybe-mostlyclean-texinfo:
+
+mostlyclean-texinfo:
+ @[ -f ./texinfo/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in texinfo" ; \
+ (cd texinfo && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-textutils mostlyclean-textutils
+maybe-mostlyclean-textutils:
+
+mostlyclean-textutils:
+ @[ -f ./textutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in textutils" ; \
+ (cd textutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-time mostlyclean-time
+maybe-mostlyclean-time:
+
+mostlyclean-time:
+ @[ -f ./time/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in time" ; \
+ (cd time && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-uudecode mostlyclean-uudecode
+maybe-mostlyclean-uudecode:
+
+mostlyclean-uudecode:
+ @[ -f ./uudecode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in uudecode" ; \
+ (cd uudecode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-wdiff mostlyclean-wdiff
+maybe-mostlyclean-wdiff:
+
+mostlyclean-wdiff:
+ @[ -f ./wdiff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in wdiff" ; \
+ (cd wdiff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-zip mostlyclean-zip
+maybe-mostlyclean-zip:
+
+mostlyclean-zip:
+ @[ -f ./zip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in zip" ; \
+ (cd zip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-zlib mostlyclean-zlib
+maybe-mostlyclean-zlib:
+
+mostlyclean-zlib:
+ @[ -f ./zlib/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in zlib" ; \
+ (cd zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-gdb mostlyclean-gdb
+maybe-mostlyclean-gdb:
+
+mostlyclean-gdb:
+ @[ -f ./gdb/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in gdb" ; \
+ (cd gdb && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-expect mostlyclean-expect
+maybe-mostlyclean-expect:
+
+mostlyclean-expect:
+ @[ -f ./expect/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in expect" ; \
+ (cd expect && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-guile mostlyclean-guile
+maybe-mostlyclean-guile:
+
+mostlyclean-guile:
+ @[ -f ./guile/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in guile" ; \
+ (cd guile && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-tk mostlyclean-tk
+maybe-mostlyclean-tk:
+
+mostlyclean-tk:
+ @[ -f ./tk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in tk" ; \
+ (cd tk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-tix mostlyclean-tix
+maybe-mostlyclean-tix:
+
+mostlyclean-tix:
+ @[ -f ./tix/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in tix" ; \
+ (cd tix && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-libtermcap mostlyclean-libtermcap
+maybe-mostlyclean-libtermcap:
+
+# libtermcap doesn't support mostlyclean.
+mostlyclean-libtermcap:
+
+
+.PHONY: maybe-mostlyclean-utils mostlyclean-utils
+maybe-mostlyclean-utils:
+
+mostlyclean-utils:
+ @[ -f ./utils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing mostlyclean in utils" ; \
+ (cd utils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+
+# Target modules.
+
+.PHONY: maybe-mostlyclean-target-libstdc++-v3 mostlyclean-target-libstdc++-v3
+maybe-mostlyclean-target-libstdc++-v3:
+
+mostlyclean-target-libstdc++-v3:
+ @[ -f $(TARGET_SUBDIR)/libstdc++-v3/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing mostlyclean in $(TARGET_SUBDIR)/libstdc++-v3" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libstdc++-v3 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-target-newlib mostlyclean-target-newlib
+maybe-mostlyclean-target-newlib:
+
+mostlyclean-target-newlib:
+ @[ -f $(TARGET_SUBDIR)/newlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing mostlyclean in $(TARGET_SUBDIR)/newlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/newlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-target-libf2c mostlyclean-target-libf2c
+maybe-mostlyclean-target-libf2c:
+
+mostlyclean-target-libf2c:
+ @[ -f $(TARGET_SUBDIR)/libf2c/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing mostlyclean in $(TARGET_SUBDIR)/libf2c" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libf2c && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-target-libobjc mostlyclean-target-libobjc
+maybe-mostlyclean-target-libobjc:
+
+mostlyclean-target-libobjc:
+ @[ -f $(TARGET_SUBDIR)/libobjc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing mostlyclean in $(TARGET_SUBDIR)/libobjc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libobjc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-target-libtermcap mostlyclean-target-libtermcap
+maybe-mostlyclean-target-libtermcap:
+
+# libtermcap doesn't support mostlyclean.
+mostlyclean-target-libtermcap:
+
+
+.PHONY: maybe-mostlyclean-target-winsup mostlyclean-target-winsup
+maybe-mostlyclean-target-winsup:
+
+mostlyclean-target-winsup:
+ @[ -f $(TARGET_SUBDIR)/winsup/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing mostlyclean in $(TARGET_SUBDIR)/winsup" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/winsup && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-target-libgloss mostlyclean-target-libgloss
+maybe-mostlyclean-target-libgloss:
+
+mostlyclean-target-libgloss:
+ @[ -f $(TARGET_SUBDIR)/libgloss/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing mostlyclean in $(TARGET_SUBDIR)/libgloss" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libgloss && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-target-libiberty mostlyclean-target-libiberty
+maybe-mostlyclean-target-libiberty:
+
+mostlyclean-target-libiberty:
+ @[ -f $(TARGET_SUBDIR)/libiberty/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing mostlyclean in $(TARGET_SUBDIR)/libiberty" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-target-gperf mostlyclean-target-gperf
+maybe-mostlyclean-target-gperf:
+
+mostlyclean-target-gperf:
+ @[ -f $(TARGET_SUBDIR)/gperf/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing mostlyclean in $(TARGET_SUBDIR)/gperf" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/gperf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-target-examples mostlyclean-target-examples
+maybe-mostlyclean-target-examples:
+
+mostlyclean-target-examples:
+ @[ -f $(TARGET_SUBDIR)/examples/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing mostlyclean in $(TARGET_SUBDIR)/examples" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/examples && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-target-libffi mostlyclean-target-libffi
+maybe-mostlyclean-target-libffi:
+
+mostlyclean-target-libffi:
+ @[ -f $(TARGET_SUBDIR)/libffi/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing mostlyclean in $(TARGET_SUBDIR)/libffi" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libffi && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-target-libjava mostlyclean-target-libjava
+maybe-mostlyclean-target-libjava:
+
+mostlyclean-target-libjava:
+ @[ -f $(TARGET_SUBDIR)/libjava/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing mostlyclean in $(TARGET_SUBDIR)/libjava" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libjava && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-target-zlib mostlyclean-target-zlib
+maybe-mostlyclean-target-zlib:
+
+mostlyclean-target-zlib:
+ @[ -f $(TARGET_SUBDIR)/zlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing mostlyclean in $(TARGET_SUBDIR)/zlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-target-boehm-gc mostlyclean-target-boehm-gc
+maybe-mostlyclean-target-boehm-gc:
+
+mostlyclean-target-boehm-gc:
+ @[ -f $(TARGET_SUBDIR)/boehm-gc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing mostlyclean in $(TARGET_SUBDIR)/boehm-gc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/boehm-gc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-target-qthreads mostlyclean-target-qthreads
+maybe-mostlyclean-target-qthreads:
+
+mostlyclean-target-qthreads:
+ @[ -f $(TARGET_SUBDIR)/qthreads/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing mostlyclean in $(TARGET_SUBDIR)/qthreads" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/qthreads && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-target-rda mostlyclean-target-rda
+maybe-mostlyclean-target-rda:
+
+mostlyclean-target-rda:
+ @[ -f $(TARGET_SUBDIR)/rda/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing mostlyclean in $(TARGET_SUBDIR)/rda" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/rda && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+.PHONY: maybe-mostlyclean-target-libada mostlyclean-target-libada
+maybe-mostlyclean-target-libada:
+
+mostlyclean-target-libada:
+ @[ -f $(TARGET_SUBDIR)/libada/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing mostlyclean in $(TARGET_SUBDIR)/libada" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libada && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ mostlyclean) \
+ || exit 1
+
+
+
+.PHONY: do-clean
+do-clean: clean-host clean-target
+
+.PHONY: clean-host
+clean-host: maybe-clean-gcc \
+ maybe-clean-ash \
+ maybe-clean-autoconf \
+ maybe-clean-automake \
+ maybe-clean-bash \
+ maybe-clean-bfd \
+ maybe-clean-opcodes \
+ maybe-clean-binutils \
+ maybe-clean-bison \
+ maybe-clean-byacc \
+ maybe-clean-bzip2 \
+ maybe-clean-dejagnu \
+ maybe-clean-diff \
+ maybe-clean-dosutils \
+ maybe-clean-etc \
+ maybe-clean-fastjar \
+ maybe-clean-fileutils \
+ maybe-clean-findutils \
+ maybe-clean-find \
+ maybe-clean-flex \
+ maybe-clean-gas \
+ maybe-clean-gawk \
+ maybe-clean-gettext \
+ maybe-clean-gnuserv \
+ maybe-clean-gprof \
+ maybe-clean-gzip \
+ maybe-clean-hello \
+ maybe-clean-indent \
+ maybe-clean-intl \
+ maybe-clean-tcl \
+ maybe-clean-itcl \
+ maybe-clean-ld \
+ maybe-clean-libgui \
+ maybe-clean-libiberty \
+ maybe-clean-libtool \
+ maybe-clean-m4 \
+ maybe-clean-make \
+ maybe-clean-mmalloc \
+ maybe-clean-patch \
+ maybe-clean-perl \
+ maybe-clean-prms \
+ maybe-clean-rcs \
+ maybe-clean-readline \
+ maybe-clean-release \
+ maybe-clean-recode \
+ maybe-clean-sed \
+ maybe-clean-send-pr \
+ maybe-clean-shellutils \
+ maybe-clean-sid \
+ maybe-clean-sim \
+ maybe-clean-tar \
+ maybe-clean-texinfo \
+ maybe-clean-textutils \
+ maybe-clean-time \
+ maybe-clean-uudecode \
+ maybe-clean-wdiff \
+ maybe-clean-zip \
+ maybe-clean-zlib \
+ maybe-clean-gdb \
+ maybe-clean-expect \
+ maybe-clean-guile \
+ maybe-clean-tk \
+ maybe-clean-tix \
+ maybe-clean-libtermcap \
+ maybe-clean-utils
+
+.PHONY: clean-target
+clean-target: \
+ maybe-clean-target-libstdc++-v3 \
+ maybe-clean-target-newlib \
+ maybe-clean-target-libf2c \
+ maybe-clean-target-libobjc \
+ maybe-clean-target-libtermcap \
+ maybe-clean-target-winsup \
+ maybe-clean-target-libgloss \
+ maybe-clean-target-libiberty \
+ maybe-clean-target-gperf \
+ maybe-clean-target-examples \
+ maybe-clean-target-libffi \
+ maybe-clean-target-libjava \
+ maybe-clean-target-zlib \
+ maybe-clean-target-boehm-gc \
+ maybe-clean-target-qthreads \
+ maybe-clean-target-rda \
+ maybe-clean-target-libada
+
+# GCC, the eternal special case
+.PHONY: maybe-clean-gcc clean-gcc
+maybe-clean-gcc:
+clean-gcc:
+ @[ -f ./gcc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_GCC_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in gcc" ; \
+ (cd gcc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+# Host modules.
+
+.PHONY: maybe-clean-ash clean-ash
+maybe-clean-ash:
+
+clean-ash:
+ @[ -f ./ash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in ash" ; \
+ (cd ash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-autoconf clean-autoconf
+maybe-clean-autoconf:
+
+clean-autoconf:
+ @[ -f ./autoconf/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in autoconf" ; \
+ (cd autoconf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-automake clean-automake
+maybe-clean-automake:
+
+clean-automake:
+ @[ -f ./automake/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in automake" ; \
+ (cd automake && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-bash clean-bash
+maybe-clean-bash:
+
+clean-bash:
+ @[ -f ./bash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in bash" ; \
+ (cd bash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-bfd clean-bfd
+maybe-clean-bfd:
+
+clean-bfd:
+ @[ -f ./bfd/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in bfd" ; \
+ (cd bfd && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-opcodes clean-opcodes
+maybe-clean-opcodes:
+
+clean-opcodes:
+ @[ -f ./opcodes/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in opcodes" ; \
+ (cd opcodes && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-binutils clean-binutils
+maybe-clean-binutils:
+
+clean-binutils:
+ @[ -f ./binutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in binutils" ; \
+ (cd binutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-bison clean-bison
+maybe-clean-bison:
+
+clean-bison:
+ @[ -f ./bison/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in bison" ; \
+ (cd bison && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-byacc clean-byacc
+maybe-clean-byacc:
+
+clean-byacc:
+ @[ -f ./byacc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in byacc" ; \
+ (cd byacc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-bzip2 clean-bzip2
+maybe-clean-bzip2:
+
+clean-bzip2:
+ @[ -f ./bzip2/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in bzip2" ; \
+ (cd bzip2 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-dejagnu clean-dejagnu
+maybe-clean-dejagnu:
+
+clean-dejagnu:
+ @[ -f ./dejagnu/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in dejagnu" ; \
+ (cd dejagnu && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-diff clean-diff
+maybe-clean-diff:
+
+clean-diff:
+ @[ -f ./diff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in diff" ; \
+ (cd diff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-dosutils clean-dosutils
+maybe-clean-dosutils:
+
+clean-dosutils:
+ @[ -f ./dosutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in dosutils" ; \
+ (cd dosutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-etc clean-etc
+maybe-clean-etc:
+
+clean-etc:
+ @[ -f ./etc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in etc" ; \
+ (cd etc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-fastjar clean-fastjar
+maybe-clean-fastjar:
+
+clean-fastjar:
+ @[ -f ./fastjar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in fastjar" ; \
+ (cd fastjar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-fileutils clean-fileutils
+maybe-clean-fileutils:
+
+clean-fileutils:
+ @[ -f ./fileutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in fileutils" ; \
+ (cd fileutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-findutils clean-findutils
+maybe-clean-findutils:
+
+clean-findutils:
+ @[ -f ./findutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in findutils" ; \
+ (cd findutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-find clean-find
+maybe-clean-find:
+
+clean-find:
+ @[ -f ./find/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in find" ; \
+ (cd find && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-flex clean-flex
+maybe-clean-flex:
+
+clean-flex:
+ @[ -f ./flex/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in flex" ; \
+ (cd flex && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-gas clean-gas
+maybe-clean-gas:
+
+clean-gas:
+ @[ -f ./gas/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in gas" ; \
+ (cd gas && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-gawk clean-gawk
+maybe-clean-gawk:
+
+clean-gawk:
+ @[ -f ./gawk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in gawk" ; \
+ (cd gawk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-gettext clean-gettext
+maybe-clean-gettext:
+
+clean-gettext:
+ @[ -f ./gettext/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in gettext" ; \
+ (cd gettext && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-gnuserv clean-gnuserv
+maybe-clean-gnuserv:
+
+clean-gnuserv:
+ @[ -f ./gnuserv/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in gnuserv" ; \
+ (cd gnuserv && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-gprof clean-gprof
+maybe-clean-gprof:
+
+clean-gprof:
+ @[ -f ./gprof/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in gprof" ; \
+ (cd gprof && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-gzip clean-gzip
+maybe-clean-gzip:
+
+clean-gzip:
+ @[ -f ./gzip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in gzip" ; \
+ (cd gzip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-hello clean-hello
+maybe-clean-hello:
+
+clean-hello:
+ @[ -f ./hello/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in hello" ; \
+ (cd hello && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-indent clean-indent
+maybe-clean-indent:
+
+clean-indent:
+ @[ -f ./indent/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in indent" ; \
+ (cd indent && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-intl clean-intl
+maybe-clean-intl:
+
+clean-intl:
+ @[ -f ./intl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in intl" ; \
+ (cd intl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-tcl clean-tcl
+maybe-clean-tcl:
+
+clean-tcl:
+ @[ -f ./tcl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in tcl" ; \
+ (cd tcl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-itcl clean-itcl
+maybe-clean-itcl:
+
+clean-itcl:
+ @[ -f ./itcl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in itcl" ; \
+ (cd itcl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-ld clean-ld
+maybe-clean-ld:
+
+clean-ld:
+ @[ -f ./ld/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in ld" ; \
+ (cd ld && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-libgui clean-libgui
+maybe-clean-libgui:
+
+clean-libgui:
+ @[ -f ./libgui/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in libgui" ; \
+ (cd libgui && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-libiberty clean-libiberty
+maybe-clean-libiberty:
+
+clean-libiberty:
+ @[ -f ./libiberty/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in libiberty" ; \
+ (cd libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-libtool clean-libtool
+maybe-clean-libtool:
+
+clean-libtool:
+ @[ -f ./libtool/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in libtool" ; \
+ (cd libtool && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-m4 clean-m4
+maybe-clean-m4:
+
+clean-m4:
+ @[ -f ./m4/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in m4" ; \
+ (cd m4 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-make clean-make
+maybe-clean-make:
+
+clean-make:
+ @[ -f ./make/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in make" ; \
+ (cd make && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-mmalloc clean-mmalloc
+maybe-clean-mmalloc:
+
+clean-mmalloc:
+ @[ -f ./mmalloc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in mmalloc" ; \
+ (cd mmalloc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-patch clean-patch
+maybe-clean-patch:
+
+clean-patch:
+ @[ -f ./patch/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in patch" ; \
+ (cd patch && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-perl clean-perl
+maybe-clean-perl:
+
+clean-perl:
+ @[ -f ./perl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in perl" ; \
+ (cd perl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-prms clean-prms
+maybe-clean-prms:
+
+clean-prms:
+ @[ -f ./prms/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in prms" ; \
+ (cd prms && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-rcs clean-rcs
+maybe-clean-rcs:
+
+clean-rcs:
+ @[ -f ./rcs/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in rcs" ; \
+ (cd rcs && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-readline clean-readline
+maybe-clean-readline:
+
+clean-readline:
+ @[ -f ./readline/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in readline" ; \
+ (cd readline && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-release clean-release
+maybe-clean-release:
+
+clean-release:
+ @[ -f ./release/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in release" ; \
+ (cd release && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-recode clean-recode
+maybe-clean-recode:
+
+clean-recode:
+ @[ -f ./recode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in recode" ; \
+ (cd recode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-sed clean-sed
+maybe-clean-sed:
+
+clean-sed:
+ @[ -f ./sed/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in sed" ; \
+ (cd sed && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-send-pr clean-send-pr
+maybe-clean-send-pr:
+
+clean-send-pr:
+ @[ -f ./send-pr/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in send-pr" ; \
+ (cd send-pr && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-shellutils clean-shellutils
+maybe-clean-shellutils:
+
+clean-shellutils:
+ @[ -f ./shellutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in shellutils" ; \
+ (cd shellutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-sid clean-sid
+maybe-clean-sid:
+
+clean-sid:
+ @[ -f ./sid/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in sid" ; \
+ (cd sid && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-sim clean-sim
+maybe-clean-sim:
+
+clean-sim:
+ @[ -f ./sim/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in sim" ; \
+ (cd sim && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-tar clean-tar
+maybe-clean-tar:
+
+clean-tar:
+ @[ -f ./tar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in tar" ; \
+ (cd tar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-texinfo clean-texinfo
+maybe-clean-texinfo:
+
+clean-texinfo:
+ @[ -f ./texinfo/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in texinfo" ; \
+ (cd texinfo && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-textutils clean-textutils
+maybe-clean-textutils:
+
+clean-textutils:
+ @[ -f ./textutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in textutils" ; \
+ (cd textutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-time clean-time
+maybe-clean-time:
+
+clean-time:
+ @[ -f ./time/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in time" ; \
+ (cd time && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-uudecode clean-uudecode
+maybe-clean-uudecode:
+
+clean-uudecode:
+ @[ -f ./uudecode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in uudecode" ; \
+ (cd uudecode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-wdiff clean-wdiff
+maybe-clean-wdiff:
+
+clean-wdiff:
+ @[ -f ./wdiff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in wdiff" ; \
+ (cd wdiff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-zip clean-zip
+maybe-clean-zip:
+
+clean-zip:
+ @[ -f ./zip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in zip" ; \
+ (cd zip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-zlib clean-zlib
+maybe-clean-zlib:
+
+clean-zlib:
+ @[ -f ./zlib/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in zlib" ; \
+ (cd zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-gdb clean-gdb
+maybe-clean-gdb:
+
+clean-gdb:
+ @[ -f ./gdb/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in gdb" ; \
+ (cd gdb && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-expect clean-expect
+maybe-clean-expect:
+
+clean-expect:
+ @[ -f ./expect/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in expect" ; \
+ (cd expect && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-guile clean-guile
+maybe-clean-guile:
+
+clean-guile:
+ @[ -f ./guile/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in guile" ; \
+ (cd guile && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-tk clean-tk
+maybe-clean-tk:
+
+clean-tk:
+ @[ -f ./tk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in tk" ; \
+ (cd tk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-tix clean-tix
+maybe-clean-tix:
+
+clean-tix:
+ @[ -f ./tix/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in tix" ; \
+ (cd tix && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-libtermcap clean-libtermcap
+maybe-clean-libtermcap:
+
+# libtermcap doesn't support clean.
+clean-libtermcap:
+
+
+.PHONY: maybe-clean-utils clean-utils
+maybe-clean-utils:
+
+clean-utils:
+ @[ -f ./utils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing clean in utils" ; \
+ (cd utils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+
+# Target modules.
+
+.PHONY: maybe-clean-target-libstdc++-v3 clean-target-libstdc++-v3
+maybe-clean-target-libstdc++-v3:
+
+clean-target-libstdc++-v3:
+ @[ -f $(TARGET_SUBDIR)/libstdc++-v3/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing clean in $(TARGET_SUBDIR)/libstdc++-v3" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libstdc++-v3 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-target-newlib clean-target-newlib
+maybe-clean-target-newlib:
+
+clean-target-newlib:
+ @[ -f $(TARGET_SUBDIR)/newlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing clean in $(TARGET_SUBDIR)/newlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/newlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-target-libf2c clean-target-libf2c
+maybe-clean-target-libf2c:
+
+clean-target-libf2c:
+ @[ -f $(TARGET_SUBDIR)/libf2c/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing clean in $(TARGET_SUBDIR)/libf2c" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libf2c && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-target-libobjc clean-target-libobjc
+maybe-clean-target-libobjc:
+
+clean-target-libobjc:
+ @[ -f $(TARGET_SUBDIR)/libobjc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing clean in $(TARGET_SUBDIR)/libobjc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libobjc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-target-libtermcap clean-target-libtermcap
+maybe-clean-target-libtermcap:
+
+# libtermcap doesn't support clean.
+clean-target-libtermcap:
+
+
+.PHONY: maybe-clean-target-winsup clean-target-winsup
+maybe-clean-target-winsup:
+
+clean-target-winsup:
+ @[ -f $(TARGET_SUBDIR)/winsup/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing clean in $(TARGET_SUBDIR)/winsup" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/winsup && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-target-libgloss clean-target-libgloss
+maybe-clean-target-libgloss:
+
+clean-target-libgloss:
+ @[ -f $(TARGET_SUBDIR)/libgloss/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing clean in $(TARGET_SUBDIR)/libgloss" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libgloss && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-target-libiberty clean-target-libiberty
+maybe-clean-target-libiberty:
+
+clean-target-libiberty:
+ @[ -f $(TARGET_SUBDIR)/libiberty/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing clean in $(TARGET_SUBDIR)/libiberty" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-target-gperf clean-target-gperf
+maybe-clean-target-gperf:
+
+clean-target-gperf:
+ @[ -f $(TARGET_SUBDIR)/gperf/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing clean in $(TARGET_SUBDIR)/gperf" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/gperf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-target-examples clean-target-examples
+maybe-clean-target-examples:
+
+clean-target-examples:
+ @[ -f $(TARGET_SUBDIR)/examples/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing clean in $(TARGET_SUBDIR)/examples" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/examples && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-target-libffi clean-target-libffi
+maybe-clean-target-libffi:
+
+clean-target-libffi:
+ @[ -f $(TARGET_SUBDIR)/libffi/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing clean in $(TARGET_SUBDIR)/libffi" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libffi && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-target-libjava clean-target-libjava
+maybe-clean-target-libjava:
+
+clean-target-libjava:
+ @[ -f $(TARGET_SUBDIR)/libjava/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing clean in $(TARGET_SUBDIR)/libjava" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libjava && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-target-zlib clean-target-zlib
+maybe-clean-target-zlib:
+
+clean-target-zlib:
+ @[ -f $(TARGET_SUBDIR)/zlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing clean in $(TARGET_SUBDIR)/zlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-target-boehm-gc clean-target-boehm-gc
+maybe-clean-target-boehm-gc:
+
+clean-target-boehm-gc:
+ @[ -f $(TARGET_SUBDIR)/boehm-gc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing clean in $(TARGET_SUBDIR)/boehm-gc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/boehm-gc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-target-qthreads clean-target-qthreads
+maybe-clean-target-qthreads:
+
+clean-target-qthreads:
+ @[ -f $(TARGET_SUBDIR)/qthreads/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing clean in $(TARGET_SUBDIR)/qthreads" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/qthreads && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-target-rda clean-target-rda
+maybe-clean-target-rda:
+
+clean-target-rda:
+ @[ -f $(TARGET_SUBDIR)/rda/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing clean in $(TARGET_SUBDIR)/rda" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/rda && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+.PHONY: maybe-clean-target-libada clean-target-libada
+maybe-clean-target-libada:
+
+clean-target-libada:
+ @[ -f $(TARGET_SUBDIR)/libada/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing clean in $(TARGET_SUBDIR)/libada" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libada && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ clean) \
+ || exit 1
+
+
+
+.PHONY: do-distclean
+do-distclean: distclean-host distclean-target
+
+.PHONY: distclean-host
+distclean-host: maybe-distclean-gcc \
+ maybe-distclean-ash \
+ maybe-distclean-autoconf \
+ maybe-distclean-automake \
+ maybe-distclean-bash \
+ maybe-distclean-bfd \
+ maybe-distclean-opcodes \
+ maybe-distclean-binutils \
+ maybe-distclean-bison \
+ maybe-distclean-byacc \
+ maybe-distclean-bzip2 \
+ maybe-distclean-dejagnu \
+ maybe-distclean-diff \
+ maybe-distclean-dosutils \
+ maybe-distclean-etc \
+ maybe-distclean-fastjar \
+ maybe-distclean-fileutils \
+ maybe-distclean-findutils \
+ maybe-distclean-find \
+ maybe-distclean-flex \
+ maybe-distclean-gas \
+ maybe-distclean-gawk \
+ maybe-distclean-gettext \
+ maybe-distclean-gnuserv \
+ maybe-distclean-gprof \
+ maybe-distclean-gzip \
+ maybe-distclean-hello \
+ maybe-distclean-indent \
+ maybe-distclean-intl \
+ maybe-distclean-tcl \
+ maybe-distclean-itcl \
+ maybe-distclean-ld \
+ maybe-distclean-libgui \
+ maybe-distclean-libiberty \
+ maybe-distclean-libtool \
+ maybe-distclean-m4 \
+ maybe-distclean-make \
+ maybe-distclean-mmalloc \
+ maybe-distclean-patch \
+ maybe-distclean-perl \
+ maybe-distclean-prms \
+ maybe-distclean-rcs \
+ maybe-distclean-readline \
+ maybe-distclean-release \
+ maybe-distclean-recode \
+ maybe-distclean-sed \
+ maybe-distclean-send-pr \
+ maybe-distclean-shellutils \
+ maybe-distclean-sid \
+ maybe-distclean-sim \
+ maybe-distclean-tar \
+ maybe-distclean-texinfo \
+ maybe-distclean-textutils \
+ maybe-distclean-time \
+ maybe-distclean-uudecode \
+ maybe-distclean-wdiff \
+ maybe-distclean-zip \
+ maybe-distclean-zlib \
+ maybe-distclean-gdb \
+ maybe-distclean-expect \
+ maybe-distclean-guile \
+ maybe-distclean-tk \
+ maybe-distclean-tix \
+ maybe-distclean-libtermcap \
+ maybe-distclean-utils
+
+.PHONY: distclean-target
+distclean-target: \
+ maybe-distclean-target-libstdc++-v3 \
+ maybe-distclean-target-newlib \
+ maybe-distclean-target-libf2c \
+ maybe-distclean-target-libobjc \
+ maybe-distclean-target-libtermcap \
+ maybe-distclean-target-winsup \
+ maybe-distclean-target-libgloss \
+ maybe-distclean-target-libiberty \
+ maybe-distclean-target-gperf \
+ maybe-distclean-target-examples \
+ maybe-distclean-target-libffi \
+ maybe-distclean-target-libjava \
+ maybe-distclean-target-zlib \
+ maybe-distclean-target-boehm-gc \
+ maybe-distclean-target-qthreads \
+ maybe-distclean-target-rda \
+ maybe-distclean-target-libada
+
+# GCC, the eternal special case
+.PHONY: maybe-distclean-gcc distclean-gcc
+maybe-distclean-gcc:
+distclean-gcc:
+ @[ -f ./gcc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_GCC_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in gcc" ; \
+ (cd gcc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+# Host modules.
+
+.PHONY: maybe-distclean-ash distclean-ash
+maybe-distclean-ash:
+
+distclean-ash:
+ @[ -f ./ash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in ash" ; \
+ (cd ash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-autoconf distclean-autoconf
+maybe-distclean-autoconf:
+
+distclean-autoconf:
+ @[ -f ./autoconf/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in autoconf" ; \
+ (cd autoconf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-automake distclean-automake
+maybe-distclean-automake:
+
+distclean-automake:
+ @[ -f ./automake/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in automake" ; \
+ (cd automake && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-bash distclean-bash
+maybe-distclean-bash:
+
+distclean-bash:
+ @[ -f ./bash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in bash" ; \
+ (cd bash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-bfd distclean-bfd
+maybe-distclean-bfd:
+
+distclean-bfd:
+ @[ -f ./bfd/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in bfd" ; \
+ (cd bfd && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-opcodes distclean-opcodes
+maybe-distclean-opcodes:
+
+distclean-opcodes:
+ @[ -f ./opcodes/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in opcodes" ; \
+ (cd opcodes && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-binutils distclean-binutils
+maybe-distclean-binutils:
+
+distclean-binutils:
+ @[ -f ./binutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in binutils" ; \
+ (cd binutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-bison distclean-bison
+maybe-distclean-bison:
+
+distclean-bison:
+ @[ -f ./bison/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in bison" ; \
+ (cd bison && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-byacc distclean-byacc
+maybe-distclean-byacc:
+
+distclean-byacc:
+ @[ -f ./byacc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in byacc" ; \
+ (cd byacc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-bzip2 distclean-bzip2
+maybe-distclean-bzip2:
+
+distclean-bzip2:
+ @[ -f ./bzip2/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in bzip2" ; \
+ (cd bzip2 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-dejagnu distclean-dejagnu
+maybe-distclean-dejagnu:
+
+distclean-dejagnu:
+ @[ -f ./dejagnu/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in dejagnu" ; \
+ (cd dejagnu && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-diff distclean-diff
+maybe-distclean-diff:
+
+distclean-diff:
+ @[ -f ./diff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in diff" ; \
+ (cd diff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-dosutils distclean-dosutils
+maybe-distclean-dosutils:
+
+distclean-dosutils:
+ @[ -f ./dosutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in dosutils" ; \
+ (cd dosutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-etc distclean-etc
+maybe-distclean-etc:
+
+distclean-etc:
+ @[ -f ./etc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in etc" ; \
+ (cd etc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-fastjar distclean-fastjar
+maybe-distclean-fastjar:
+
+distclean-fastjar:
+ @[ -f ./fastjar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in fastjar" ; \
+ (cd fastjar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-fileutils distclean-fileutils
+maybe-distclean-fileutils:
+
+distclean-fileutils:
+ @[ -f ./fileutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in fileutils" ; \
+ (cd fileutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-findutils distclean-findutils
+maybe-distclean-findutils:
+
+distclean-findutils:
+ @[ -f ./findutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in findutils" ; \
+ (cd findutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-find distclean-find
+maybe-distclean-find:
+
+distclean-find:
+ @[ -f ./find/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in find" ; \
+ (cd find && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-flex distclean-flex
+maybe-distclean-flex:
+
+distclean-flex:
+ @[ -f ./flex/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in flex" ; \
+ (cd flex && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-gas distclean-gas
+maybe-distclean-gas:
+
+distclean-gas:
+ @[ -f ./gas/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in gas" ; \
+ (cd gas && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-gawk distclean-gawk
+maybe-distclean-gawk:
+
+distclean-gawk:
+ @[ -f ./gawk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in gawk" ; \
+ (cd gawk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-gettext distclean-gettext
+maybe-distclean-gettext:
+
+distclean-gettext:
+ @[ -f ./gettext/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in gettext" ; \
+ (cd gettext && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-gnuserv distclean-gnuserv
+maybe-distclean-gnuserv:
+
+distclean-gnuserv:
+ @[ -f ./gnuserv/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in gnuserv" ; \
+ (cd gnuserv && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-gprof distclean-gprof
+maybe-distclean-gprof:
+
+distclean-gprof:
+ @[ -f ./gprof/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in gprof" ; \
+ (cd gprof && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-gzip distclean-gzip
+maybe-distclean-gzip:
+
+distclean-gzip:
+ @[ -f ./gzip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in gzip" ; \
+ (cd gzip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-hello distclean-hello
+maybe-distclean-hello:
+
+distclean-hello:
+ @[ -f ./hello/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in hello" ; \
+ (cd hello && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-indent distclean-indent
+maybe-distclean-indent:
+
+distclean-indent:
+ @[ -f ./indent/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in indent" ; \
+ (cd indent && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-intl distclean-intl
+maybe-distclean-intl:
+
+distclean-intl:
+ @[ -f ./intl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in intl" ; \
+ (cd intl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-tcl distclean-tcl
+maybe-distclean-tcl:
+
+distclean-tcl:
+ @[ -f ./tcl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in tcl" ; \
+ (cd tcl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-itcl distclean-itcl
+maybe-distclean-itcl:
+
+distclean-itcl:
+ @[ -f ./itcl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in itcl" ; \
+ (cd itcl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-ld distclean-ld
+maybe-distclean-ld:
+
+distclean-ld:
+ @[ -f ./ld/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in ld" ; \
+ (cd ld && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-libgui distclean-libgui
+maybe-distclean-libgui:
+
+distclean-libgui:
+ @[ -f ./libgui/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in libgui" ; \
+ (cd libgui && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-libiberty distclean-libiberty
+maybe-distclean-libiberty:
+
+distclean-libiberty:
+ @[ -f ./libiberty/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in libiberty" ; \
+ (cd libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-libtool distclean-libtool
+maybe-distclean-libtool:
+
+distclean-libtool:
+ @[ -f ./libtool/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in libtool" ; \
+ (cd libtool && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-m4 distclean-m4
+maybe-distclean-m4:
+
+distclean-m4:
+ @[ -f ./m4/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in m4" ; \
+ (cd m4 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-make distclean-make
+maybe-distclean-make:
+
+distclean-make:
+ @[ -f ./make/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in make" ; \
+ (cd make && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-mmalloc distclean-mmalloc
+maybe-distclean-mmalloc:
+
+distclean-mmalloc:
+ @[ -f ./mmalloc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in mmalloc" ; \
+ (cd mmalloc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-patch distclean-patch
+maybe-distclean-patch:
+
+distclean-patch:
+ @[ -f ./patch/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in patch" ; \
+ (cd patch && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-perl distclean-perl
+maybe-distclean-perl:
+
+distclean-perl:
+ @[ -f ./perl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in perl" ; \
+ (cd perl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-prms distclean-prms
+maybe-distclean-prms:
+
+distclean-prms:
+ @[ -f ./prms/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in prms" ; \
+ (cd prms && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-rcs distclean-rcs
+maybe-distclean-rcs:
+
+distclean-rcs:
+ @[ -f ./rcs/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in rcs" ; \
+ (cd rcs && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-readline distclean-readline
+maybe-distclean-readline:
+
+distclean-readline:
+ @[ -f ./readline/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in readline" ; \
+ (cd readline && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-release distclean-release
+maybe-distclean-release:
+
+distclean-release:
+ @[ -f ./release/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in release" ; \
+ (cd release && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-recode distclean-recode
+maybe-distclean-recode:
+
+distclean-recode:
+ @[ -f ./recode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in recode" ; \
+ (cd recode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-sed distclean-sed
+maybe-distclean-sed:
+
+distclean-sed:
+ @[ -f ./sed/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in sed" ; \
+ (cd sed && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-send-pr distclean-send-pr
+maybe-distclean-send-pr:
+
+distclean-send-pr:
+ @[ -f ./send-pr/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in send-pr" ; \
+ (cd send-pr && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-shellutils distclean-shellutils
+maybe-distclean-shellutils:
+
+distclean-shellutils:
+ @[ -f ./shellutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in shellutils" ; \
+ (cd shellutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-sid distclean-sid
+maybe-distclean-sid:
+
+distclean-sid:
+ @[ -f ./sid/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in sid" ; \
+ (cd sid && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-sim distclean-sim
+maybe-distclean-sim:
+
+distclean-sim:
+ @[ -f ./sim/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in sim" ; \
+ (cd sim && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-tar distclean-tar
+maybe-distclean-tar:
+
+distclean-tar:
+ @[ -f ./tar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in tar" ; \
+ (cd tar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-texinfo distclean-texinfo
+maybe-distclean-texinfo:
+
+distclean-texinfo:
+ @[ -f ./texinfo/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in texinfo" ; \
+ (cd texinfo && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-textutils distclean-textutils
+maybe-distclean-textutils:
+
+distclean-textutils:
+ @[ -f ./textutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in textutils" ; \
+ (cd textutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-time distclean-time
+maybe-distclean-time:
+
+distclean-time:
+ @[ -f ./time/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in time" ; \
+ (cd time && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-uudecode distclean-uudecode
+maybe-distclean-uudecode:
+
+distclean-uudecode:
+ @[ -f ./uudecode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in uudecode" ; \
+ (cd uudecode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-wdiff distclean-wdiff
+maybe-distclean-wdiff:
+
+distclean-wdiff:
+ @[ -f ./wdiff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in wdiff" ; \
+ (cd wdiff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-zip distclean-zip
+maybe-distclean-zip:
+
+distclean-zip:
+ @[ -f ./zip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in zip" ; \
+ (cd zip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-zlib distclean-zlib
+maybe-distclean-zlib:
+
+distclean-zlib:
+ @[ -f ./zlib/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in zlib" ; \
+ (cd zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-gdb distclean-gdb
+maybe-distclean-gdb:
+
+distclean-gdb:
+ @[ -f ./gdb/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in gdb" ; \
+ (cd gdb && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-expect distclean-expect
+maybe-distclean-expect:
+
+distclean-expect:
+ @[ -f ./expect/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in expect" ; \
+ (cd expect && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-guile distclean-guile
+maybe-distclean-guile:
+
+distclean-guile:
+ @[ -f ./guile/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in guile" ; \
+ (cd guile && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-tk distclean-tk
+maybe-distclean-tk:
+
+distclean-tk:
+ @[ -f ./tk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in tk" ; \
+ (cd tk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-tix distclean-tix
+maybe-distclean-tix:
+
+distclean-tix:
+ @[ -f ./tix/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in tix" ; \
+ (cd tix && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-libtermcap distclean-libtermcap
+maybe-distclean-libtermcap:
+
+# libtermcap doesn't support distclean.
+distclean-libtermcap:
+
+
+.PHONY: maybe-distclean-utils distclean-utils
+maybe-distclean-utils:
+
+distclean-utils:
+ @[ -f ./utils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing distclean in utils" ; \
+ (cd utils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+
+# Target modules.
+
+.PHONY: maybe-distclean-target-libstdc++-v3 distclean-target-libstdc++-v3
+maybe-distclean-target-libstdc++-v3:
+
+distclean-target-libstdc++-v3:
+ @[ -f $(TARGET_SUBDIR)/libstdc++-v3/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing distclean in $(TARGET_SUBDIR)/libstdc++-v3" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libstdc++-v3 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-target-newlib distclean-target-newlib
+maybe-distclean-target-newlib:
+
+distclean-target-newlib:
+ @[ -f $(TARGET_SUBDIR)/newlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing distclean in $(TARGET_SUBDIR)/newlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/newlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-target-libf2c distclean-target-libf2c
+maybe-distclean-target-libf2c:
+
+distclean-target-libf2c:
+ @[ -f $(TARGET_SUBDIR)/libf2c/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing distclean in $(TARGET_SUBDIR)/libf2c" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libf2c && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-target-libobjc distclean-target-libobjc
+maybe-distclean-target-libobjc:
+
+distclean-target-libobjc:
+ @[ -f $(TARGET_SUBDIR)/libobjc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing distclean in $(TARGET_SUBDIR)/libobjc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libobjc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-target-libtermcap distclean-target-libtermcap
+maybe-distclean-target-libtermcap:
+
+# libtermcap doesn't support distclean.
+distclean-target-libtermcap:
+
+
+.PHONY: maybe-distclean-target-winsup distclean-target-winsup
+maybe-distclean-target-winsup:
+
+distclean-target-winsup:
+ @[ -f $(TARGET_SUBDIR)/winsup/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing distclean in $(TARGET_SUBDIR)/winsup" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/winsup && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-target-libgloss distclean-target-libgloss
+maybe-distclean-target-libgloss:
+
+distclean-target-libgloss:
+ @[ -f $(TARGET_SUBDIR)/libgloss/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing distclean in $(TARGET_SUBDIR)/libgloss" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libgloss && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-target-libiberty distclean-target-libiberty
+maybe-distclean-target-libiberty:
+
+distclean-target-libiberty:
+ @[ -f $(TARGET_SUBDIR)/libiberty/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing distclean in $(TARGET_SUBDIR)/libiberty" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-target-gperf distclean-target-gperf
+maybe-distclean-target-gperf:
+
+distclean-target-gperf:
+ @[ -f $(TARGET_SUBDIR)/gperf/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing distclean in $(TARGET_SUBDIR)/gperf" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/gperf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-target-examples distclean-target-examples
+maybe-distclean-target-examples:
+
+distclean-target-examples:
+ @[ -f $(TARGET_SUBDIR)/examples/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing distclean in $(TARGET_SUBDIR)/examples" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/examples && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-target-libffi distclean-target-libffi
+maybe-distclean-target-libffi:
+
+distclean-target-libffi:
+ @[ -f $(TARGET_SUBDIR)/libffi/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing distclean in $(TARGET_SUBDIR)/libffi" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libffi && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-target-libjava distclean-target-libjava
+maybe-distclean-target-libjava:
+
+distclean-target-libjava:
+ @[ -f $(TARGET_SUBDIR)/libjava/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing distclean in $(TARGET_SUBDIR)/libjava" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libjava && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-target-zlib distclean-target-zlib
+maybe-distclean-target-zlib:
+
+distclean-target-zlib:
+ @[ -f $(TARGET_SUBDIR)/zlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing distclean in $(TARGET_SUBDIR)/zlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-target-boehm-gc distclean-target-boehm-gc
+maybe-distclean-target-boehm-gc:
+
+distclean-target-boehm-gc:
+ @[ -f $(TARGET_SUBDIR)/boehm-gc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing distclean in $(TARGET_SUBDIR)/boehm-gc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/boehm-gc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-target-qthreads distclean-target-qthreads
+maybe-distclean-target-qthreads:
+
+distclean-target-qthreads:
+ @[ -f $(TARGET_SUBDIR)/qthreads/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing distclean in $(TARGET_SUBDIR)/qthreads" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/qthreads && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-target-rda distclean-target-rda
+maybe-distclean-target-rda:
+
+distclean-target-rda:
+ @[ -f $(TARGET_SUBDIR)/rda/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing distclean in $(TARGET_SUBDIR)/rda" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/rda && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+.PHONY: maybe-distclean-target-libada distclean-target-libada
+maybe-distclean-target-libada:
+
+distclean-target-libada:
+ @[ -f $(TARGET_SUBDIR)/libada/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing distclean in $(TARGET_SUBDIR)/libada" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libada && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ distclean) \
+ || exit 1
+
+
+
+.PHONY: do-maintainer-clean
+do-maintainer-clean: maintainer-clean-host maintainer-clean-target
+
+.PHONY: maintainer-clean-host
+maintainer-clean-host: maybe-maintainer-clean-gcc \
+ maybe-maintainer-clean-ash \
+ maybe-maintainer-clean-autoconf \
+ maybe-maintainer-clean-automake \
+ maybe-maintainer-clean-bash \
+ maybe-maintainer-clean-bfd \
+ maybe-maintainer-clean-opcodes \
+ maybe-maintainer-clean-binutils \
+ maybe-maintainer-clean-bison \
+ maybe-maintainer-clean-byacc \
+ maybe-maintainer-clean-bzip2 \
+ maybe-maintainer-clean-dejagnu \
+ maybe-maintainer-clean-diff \
+ maybe-maintainer-clean-dosutils \
+ maybe-maintainer-clean-etc \
+ maybe-maintainer-clean-fastjar \
+ maybe-maintainer-clean-fileutils \
+ maybe-maintainer-clean-findutils \
+ maybe-maintainer-clean-find \
+ maybe-maintainer-clean-flex \
+ maybe-maintainer-clean-gas \
+ maybe-maintainer-clean-gawk \
+ maybe-maintainer-clean-gettext \
+ maybe-maintainer-clean-gnuserv \
+ maybe-maintainer-clean-gprof \
+ maybe-maintainer-clean-gzip \
+ maybe-maintainer-clean-hello \
+ maybe-maintainer-clean-indent \
+ maybe-maintainer-clean-intl \
+ maybe-maintainer-clean-tcl \
+ maybe-maintainer-clean-itcl \
+ maybe-maintainer-clean-ld \
+ maybe-maintainer-clean-libgui \
+ maybe-maintainer-clean-libiberty \
+ maybe-maintainer-clean-libtool \
+ maybe-maintainer-clean-m4 \
+ maybe-maintainer-clean-make \
+ maybe-maintainer-clean-mmalloc \
+ maybe-maintainer-clean-patch \
+ maybe-maintainer-clean-perl \
+ maybe-maintainer-clean-prms \
+ maybe-maintainer-clean-rcs \
+ maybe-maintainer-clean-readline \
+ maybe-maintainer-clean-release \
+ maybe-maintainer-clean-recode \
+ maybe-maintainer-clean-sed \
+ maybe-maintainer-clean-send-pr \
+ maybe-maintainer-clean-shellutils \
+ maybe-maintainer-clean-sid \
+ maybe-maintainer-clean-sim \
+ maybe-maintainer-clean-tar \
+ maybe-maintainer-clean-texinfo \
+ maybe-maintainer-clean-textutils \
+ maybe-maintainer-clean-time \
+ maybe-maintainer-clean-uudecode \
+ maybe-maintainer-clean-wdiff \
+ maybe-maintainer-clean-zip \
+ maybe-maintainer-clean-zlib \
+ maybe-maintainer-clean-gdb \
+ maybe-maintainer-clean-expect \
+ maybe-maintainer-clean-guile \
+ maybe-maintainer-clean-tk \
+ maybe-maintainer-clean-tix \
+ maybe-maintainer-clean-libtermcap \
+ maybe-maintainer-clean-utils
+
+.PHONY: maintainer-clean-target
+maintainer-clean-target: \
+ maybe-maintainer-clean-target-libstdc++-v3 \
+ maybe-maintainer-clean-target-newlib \
+ maybe-maintainer-clean-target-libf2c \
+ maybe-maintainer-clean-target-libobjc \
+ maybe-maintainer-clean-target-libtermcap \
+ maybe-maintainer-clean-target-winsup \
+ maybe-maintainer-clean-target-libgloss \
+ maybe-maintainer-clean-target-libiberty \
+ maybe-maintainer-clean-target-gperf \
+ maybe-maintainer-clean-target-examples \
+ maybe-maintainer-clean-target-libffi \
+ maybe-maintainer-clean-target-libjava \
+ maybe-maintainer-clean-target-zlib \
+ maybe-maintainer-clean-target-boehm-gc \
+ maybe-maintainer-clean-target-qthreads \
+ maybe-maintainer-clean-target-rda \
+ maybe-maintainer-clean-target-libada
+
+# GCC, the eternal special case
+.PHONY: maybe-maintainer-clean-gcc maintainer-clean-gcc
+maybe-maintainer-clean-gcc:
+maintainer-clean-gcc:
+ @[ -f ./gcc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_GCC_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in gcc" ; \
+ (cd gcc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+# Host modules.
+
+.PHONY: maybe-maintainer-clean-ash maintainer-clean-ash
+maybe-maintainer-clean-ash:
+
+maintainer-clean-ash:
+ @[ -f ./ash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in ash" ; \
+ (cd ash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-autoconf maintainer-clean-autoconf
+maybe-maintainer-clean-autoconf:
+
+maintainer-clean-autoconf:
+ @[ -f ./autoconf/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in autoconf" ; \
+ (cd autoconf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-automake maintainer-clean-automake
+maybe-maintainer-clean-automake:
+
+maintainer-clean-automake:
+ @[ -f ./automake/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in automake" ; \
+ (cd automake && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-bash maintainer-clean-bash
+maybe-maintainer-clean-bash:
+
+maintainer-clean-bash:
+ @[ -f ./bash/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in bash" ; \
+ (cd bash && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-bfd maintainer-clean-bfd
+maybe-maintainer-clean-bfd:
+
+maintainer-clean-bfd:
+ @[ -f ./bfd/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in bfd" ; \
+ (cd bfd && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-opcodes maintainer-clean-opcodes
+maybe-maintainer-clean-opcodes:
+
+maintainer-clean-opcodes:
+ @[ -f ./opcodes/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in opcodes" ; \
+ (cd opcodes && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-binutils maintainer-clean-binutils
+maybe-maintainer-clean-binutils:
+
+maintainer-clean-binutils:
+ @[ -f ./binutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in binutils" ; \
+ (cd binutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-bison maintainer-clean-bison
+maybe-maintainer-clean-bison:
+
+maintainer-clean-bison:
+ @[ -f ./bison/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in bison" ; \
+ (cd bison && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-byacc maintainer-clean-byacc
+maybe-maintainer-clean-byacc:
+
+maintainer-clean-byacc:
+ @[ -f ./byacc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in byacc" ; \
+ (cd byacc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-bzip2 maintainer-clean-bzip2
+maybe-maintainer-clean-bzip2:
+
+maintainer-clean-bzip2:
+ @[ -f ./bzip2/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in bzip2" ; \
+ (cd bzip2 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-dejagnu maintainer-clean-dejagnu
+maybe-maintainer-clean-dejagnu:
+
+maintainer-clean-dejagnu:
+ @[ -f ./dejagnu/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in dejagnu" ; \
+ (cd dejagnu && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-diff maintainer-clean-diff
+maybe-maintainer-clean-diff:
+
+maintainer-clean-diff:
+ @[ -f ./diff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in diff" ; \
+ (cd diff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-dosutils maintainer-clean-dosutils
+maybe-maintainer-clean-dosutils:
+
+maintainer-clean-dosutils:
+ @[ -f ./dosutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in dosutils" ; \
+ (cd dosutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-etc maintainer-clean-etc
+maybe-maintainer-clean-etc:
+
+maintainer-clean-etc:
+ @[ -f ./etc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in etc" ; \
+ (cd etc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-fastjar maintainer-clean-fastjar
+maybe-maintainer-clean-fastjar:
+
+maintainer-clean-fastjar:
+ @[ -f ./fastjar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in fastjar" ; \
+ (cd fastjar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-fileutils maintainer-clean-fileutils
+maybe-maintainer-clean-fileutils:
+
+maintainer-clean-fileutils:
+ @[ -f ./fileutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in fileutils" ; \
+ (cd fileutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-findutils maintainer-clean-findutils
+maybe-maintainer-clean-findutils:
+
+maintainer-clean-findutils:
+ @[ -f ./findutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in findutils" ; \
+ (cd findutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-find maintainer-clean-find
+maybe-maintainer-clean-find:
+
+maintainer-clean-find:
+ @[ -f ./find/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in find" ; \
+ (cd find && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-flex maintainer-clean-flex
+maybe-maintainer-clean-flex:
+
+maintainer-clean-flex:
+ @[ -f ./flex/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in flex" ; \
+ (cd flex && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-gas maintainer-clean-gas
+maybe-maintainer-clean-gas:
+
+maintainer-clean-gas:
+ @[ -f ./gas/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in gas" ; \
+ (cd gas && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-gawk maintainer-clean-gawk
+maybe-maintainer-clean-gawk:
+
+maintainer-clean-gawk:
+ @[ -f ./gawk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in gawk" ; \
+ (cd gawk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-gettext maintainer-clean-gettext
+maybe-maintainer-clean-gettext:
+
+maintainer-clean-gettext:
+ @[ -f ./gettext/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in gettext" ; \
+ (cd gettext && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-gnuserv maintainer-clean-gnuserv
+maybe-maintainer-clean-gnuserv:
+
+maintainer-clean-gnuserv:
+ @[ -f ./gnuserv/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in gnuserv" ; \
+ (cd gnuserv && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-gprof maintainer-clean-gprof
+maybe-maintainer-clean-gprof:
+
+maintainer-clean-gprof:
+ @[ -f ./gprof/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in gprof" ; \
+ (cd gprof && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-gzip maintainer-clean-gzip
+maybe-maintainer-clean-gzip:
+
+maintainer-clean-gzip:
+ @[ -f ./gzip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in gzip" ; \
+ (cd gzip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-hello maintainer-clean-hello
+maybe-maintainer-clean-hello:
+
+maintainer-clean-hello:
+ @[ -f ./hello/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in hello" ; \
+ (cd hello && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-indent maintainer-clean-indent
+maybe-maintainer-clean-indent:
+
+maintainer-clean-indent:
+ @[ -f ./indent/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in indent" ; \
+ (cd indent && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-intl maintainer-clean-intl
+maybe-maintainer-clean-intl:
+
+maintainer-clean-intl:
+ @[ -f ./intl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in intl" ; \
+ (cd intl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-tcl maintainer-clean-tcl
+maybe-maintainer-clean-tcl:
+
+maintainer-clean-tcl:
+ @[ -f ./tcl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in tcl" ; \
+ (cd tcl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-itcl maintainer-clean-itcl
+maybe-maintainer-clean-itcl:
+
+maintainer-clean-itcl:
+ @[ -f ./itcl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in itcl" ; \
+ (cd itcl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-ld maintainer-clean-ld
+maybe-maintainer-clean-ld:
+
+maintainer-clean-ld:
+ @[ -f ./ld/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in ld" ; \
+ (cd ld && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-libgui maintainer-clean-libgui
+maybe-maintainer-clean-libgui:
+
+maintainer-clean-libgui:
+ @[ -f ./libgui/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in libgui" ; \
+ (cd libgui && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-libiberty maintainer-clean-libiberty
+maybe-maintainer-clean-libiberty:
+
+maintainer-clean-libiberty:
+ @[ -f ./libiberty/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in libiberty" ; \
+ (cd libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-libtool maintainer-clean-libtool
+maybe-maintainer-clean-libtool:
+
+maintainer-clean-libtool:
+ @[ -f ./libtool/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in libtool" ; \
+ (cd libtool && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-m4 maintainer-clean-m4
+maybe-maintainer-clean-m4:
+
+maintainer-clean-m4:
+ @[ -f ./m4/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in m4" ; \
+ (cd m4 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-make maintainer-clean-make
+maybe-maintainer-clean-make:
+
+maintainer-clean-make:
+ @[ -f ./make/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in make" ; \
+ (cd make && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-mmalloc maintainer-clean-mmalloc
+maybe-maintainer-clean-mmalloc:
+
+maintainer-clean-mmalloc:
+ @[ -f ./mmalloc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in mmalloc" ; \
+ (cd mmalloc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-patch maintainer-clean-patch
+maybe-maintainer-clean-patch:
+
+maintainer-clean-patch:
+ @[ -f ./patch/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in patch" ; \
+ (cd patch && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-perl maintainer-clean-perl
+maybe-maintainer-clean-perl:
+
+maintainer-clean-perl:
+ @[ -f ./perl/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in perl" ; \
+ (cd perl && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-prms maintainer-clean-prms
+maybe-maintainer-clean-prms:
+
+maintainer-clean-prms:
+ @[ -f ./prms/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in prms" ; \
+ (cd prms && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-rcs maintainer-clean-rcs
+maybe-maintainer-clean-rcs:
+
+maintainer-clean-rcs:
+ @[ -f ./rcs/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in rcs" ; \
+ (cd rcs && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-readline maintainer-clean-readline
+maybe-maintainer-clean-readline:
+
+maintainer-clean-readline:
+ @[ -f ./readline/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in readline" ; \
+ (cd readline && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-release maintainer-clean-release
+maybe-maintainer-clean-release:
+
+maintainer-clean-release:
+ @[ -f ./release/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in release" ; \
+ (cd release && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-recode maintainer-clean-recode
+maybe-maintainer-clean-recode:
+
+maintainer-clean-recode:
+ @[ -f ./recode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in recode" ; \
+ (cd recode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-sed maintainer-clean-sed
+maybe-maintainer-clean-sed:
+
+maintainer-clean-sed:
+ @[ -f ./sed/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in sed" ; \
+ (cd sed && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-send-pr maintainer-clean-send-pr
+maybe-maintainer-clean-send-pr:
+
+maintainer-clean-send-pr:
+ @[ -f ./send-pr/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in send-pr" ; \
+ (cd send-pr && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-shellutils maintainer-clean-shellutils
+maybe-maintainer-clean-shellutils:
+
+maintainer-clean-shellutils:
+ @[ -f ./shellutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in shellutils" ; \
+ (cd shellutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-sid maintainer-clean-sid
+maybe-maintainer-clean-sid:
+
+maintainer-clean-sid:
+ @[ -f ./sid/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in sid" ; \
+ (cd sid && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-sim maintainer-clean-sim
+maybe-maintainer-clean-sim:
+
+maintainer-clean-sim:
+ @[ -f ./sim/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in sim" ; \
+ (cd sim && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-tar maintainer-clean-tar
+maybe-maintainer-clean-tar:
+
+maintainer-clean-tar:
+ @[ -f ./tar/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in tar" ; \
+ (cd tar && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-texinfo maintainer-clean-texinfo
+maybe-maintainer-clean-texinfo:
+
+maintainer-clean-texinfo:
+ @[ -f ./texinfo/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in texinfo" ; \
+ (cd texinfo && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-textutils maintainer-clean-textutils
+maybe-maintainer-clean-textutils:
+
+maintainer-clean-textutils:
+ @[ -f ./textutils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in textutils" ; \
+ (cd textutils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-time maintainer-clean-time
+maybe-maintainer-clean-time:
+
+maintainer-clean-time:
+ @[ -f ./time/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in time" ; \
+ (cd time && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-uudecode maintainer-clean-uudecode
+maybe-maintainer-clean-uudecode:
+
+maintainer-clean-uudecode:
+ @[ -f ./uudecode/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in uudecode" ; \
+ (cd uudecode && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-wdiff maintainer-clean-wdiff
+maybe-maintainer-clean-wdiff:
+
+maintainer-clean-wdiff:
+ @[ -f ./wdiff/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in wdiff" ; \
+ (cd wdiff && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-zip maintainer-clean-zip
+maybe-maintainer-clean-zip:
+
+maintainer-clean-zip:
+ @[ -f ./zip/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in zip" ; \
+ (cd zip && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-zlib maintainer-clean-zlib
+maybe-maintainer-clean-zlib:
+
+maintainer-clean-zlib:
+ @[ -f ./zlib/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in zlib" ; \
+ (cd zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-gdb maintainer-clean-gdb
+maybe-maintainer-clean-gdb:
+
+maintainer-clean-gdb:
+ @[ -f ./gdb/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in gdb" ; \
+ (cd gdb && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-expect maintainer-clean-expect
+maybe-maintainer-clean-expect:
+
+maintainer-clean-expect:
+ @[ -f ./expect/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in expect" ; \
+ (cd expect && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-guile maintainer-clean-guile
+maybe-maintainer-clean-guile:
+
+maintainer-clean-guile:
+ @[ -f ./guile/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in guile" ; \
+ (cd guile && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-tk maintainer-clean-tk
+maybe-maintainer-clean-tk:
+
+maintainer-clean-tk:
+ @[ -f ./tk/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in tk" ; \
+ (cd tk && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-tix maintainer-clean-tix
+maybe-maintainer-clean-tix:
+
+maintainer-clean-tix:
+ @[ -f ./tix/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in tix" ; \
+ (cd tix && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-libtermcap maintainer-clean-libtermcap
+maybe-maintainer-clean-libtermcap:
+
+# libtermcap doesn't support maintainer-clean.
+maintainer-clean-libtermcap:
+
+
+.PHONY: maybe-maintainer-clean-utils maintainer-clean-utils
+maybe-maintainer-clean-utils:
+
+maintainer-clean-utils:
+ @[ -f ./utils/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing maintainer-clean in utils" ; \
+ (cd utils && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+
+# Target modules.
+
+.PHONY: maybe-maintainer-clean-target-libstdc++-v3 maintainer-clean-target-libstdc++-v3
+maybe-maintainer-clean-target-libstdc++-v3:
+
+maintainer-clean-target-libstdc++-v3:
+ @[ -f $(TARGET_SUBDIR)/libstdc++-v3/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing maintainer-clean in $(TARGET_SUBDIR)/libstdc++-v3" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libstdc++-v3 && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-target-newlib maintainer-clean-target-newlib
+maybe-maintainer-clean-target-newlib:
+
+maintainer-clean-target-newlib:
+ @[ -f $(TARGET_SUBDIR)/newlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing maintainer-clean in $(TARGET_SUBDIR)/newlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/newlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-target-libf2c maintainer-clean-target-libf2c
+maybe-maintainer-clean-target-libf2c:
+
+maintainer-clean-target-libf2c:
+ @[ -f $(TARGET_SUBDIR)/libf2c/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing maintainer-clean in $(TARGET_SUBDIR)/libf2c" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libf2c && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-target-libobjc maintainer-clean-target-libobjc
+maybe-maintainer-clean-target-libobjc:
+
+maintainer-clean-target-libobjc:
+ @[ -f $(TARGET_SUBDIR)/libobjc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing maintainer-clean in $(TARGET_SUBDIR)/libobjc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libobjc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-target-libtermcap maintainer-clean-target-libtermcap
+maybe-maintainer-clean-target-libtermcap:
+
+# libtermcap doesn't support maintainer-clean.
+maintainer-clean-target-libtermcap:
+
+
+.PHONY: maybe-maintainer-clean-target-winsup maintainer-clean-target-winsup
+maybe-maintainer-clean-target-winsup:
+
+maintainer-clean-target-winsup:
+ @[ -f $(TARGET_SUBDIR)/winsup/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing maintainer-clean in $(TARGET_SUBDIR)/winsup" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/winsup && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-target-libgloss maintainer-clean-target-libgloss
+maybe-maintainer-clean-target-libgloss:
+
+maintainer-clean-target-libgloss:
+ @[ -f $(TARGET_SUBDIR)/libgloss/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing maintainer-clean in $(TARGET_SUBDIR)/libgloss" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libgloss && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-target-libiberty maintainer-clean-target-libiberty
+maybe-maintainer-clean-target-libiberty:
+
+maintainer-clean-target-libiberty:
+ @[ -f $(TARGET_SUBDIR)/libiberty/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing maintainer-clean in $(TARGET_SUBDIR)/libiberty" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libiberty && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-target-gperf maintainer-clean-target-gperf
+maybe-maintainer-clean-target-gperf:
+
+maintainer-clean-target-gperf:
+ @[ -f $(TARGET_SUBDIR)/gperf/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing maintainer-clean in $(TARGET_SUBDIR)/gperf" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/gperf && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-target-examples maintainer-clean-target-examples
+maybe-maintainer-clean-target-examples:
+
+maintainer-clean-target-examples:
+ @[ -f $(TARGET_SUBDIR)/examples/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing maintainer-clean in $(TARGET_SUBDIR)/examples" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/examples && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-target-libffi maintainer-clean-target-libffi
+maybe-maintainer-clean-target-libffi:
+
+maintainer-clean-target-libffi:
+ @[ -f $(TARGET_SUBDIR)/libffi/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing maintainer-clean in $(TARGET_SUBDIR)/libffi" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libffi && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-target-libjava maintainer-clean-target-libjava
+maybe-maintainer-clean-target-libjava:
+
+maintainer-clean-target-libjava:
+ @[ -f $(TARGET_SUBDIR)/libjava/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing maintainer-clean in $(TARGET_SUBDIR)/libjava" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libjava && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-target-zlib maintainer-clean-target-zlib
+maybe-maintainer-clean-target-zlib:
+
+maintainer-clean-target-zlib:
+ @[ -f $(TARGET_SUBDIR)/zlib/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing maintainer-clean in $(TARGET_SUBDIR)/zlib" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/zlib && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-target-boehm-gc maintainer-clean-target-boehm-gc
+maybe-maintainer-clean-target-boehm-gc:
+
+maintainer-clean-target-boehm-gc:
+ @[ -f $(TARGET_SUBDIR)/boehm-gc/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing maintainer-clean in $(TARGET_SUBDIR)/boehm-gc" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/boehm-gc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-target-qthreads maintainer-clean-target-qthreads
+maybe-maintainer-clean-target-qthreads:
+
+maintainer-clean-target-qthreads:
+ @[ -f $(TARGET_SUBDIR)/qthreads/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing maintainer-clean in $(TARGET_SUBDIR)/qthreads" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/qthreads && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-target-rda maintainer-clean-target-rda
+maybe-maintainer-clean-target-rda:
+
+maintainer-clean-target-rda:
+ @[ -f $(TARGET_SUBDIR)/rda/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing maintainer-clean in $(TARGET_SUBDIR)/rda" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/rda && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+.PHONY: maybe-maintainer-clean-target-libada maintainer-clean-target-libada
+maybe-maintainer-clean-target-libada:
+
+maintainer-clean-target-libada:
+ @[ -f $(TARGET_SUBDIR)/libada/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing maintainer-clean in $(TARGET_SUBDIR)/libada" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/libada && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ maintainer-clean) \
+ || exit 1
+
+
+
# Here are the targets which correspond to the do-X targets.
@@ -996,13 +17438,14 @@ info: do-info
installcheck: do-installcheck
dvi: do-dvi
-# Make sure makeinfo is built before we do a `make info'.
-do-info: all-texinfo
+# Make sure makeinfo is built before we do a `make info', if we're
+# in fact building texinfo.
+do-info: maybe-all-texinfo
install-info: do-install-info dir.info
- s=`cd $(srcdir); ${PWD}`; export s; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
if [ -f dir.info ] ; then \
- $(INSTALL_DATA) dir.info $(infodir)/dir.info ; \
+ $(INSTALL_DATA) dir.info $(DESTDIR)$(infodir)/dir.info ; \
else true ; fi
local-clean:
@@ -1010,9 +17453,11 @@ local-clean:
local-distclean:
-rm -f Makefile config.status config.cache mh-frag mt-frag
+ -rm -f multilib.out multilib.tmp maybedep.tmp serdep.tmp
-if [ "$(TARGET_SUBDIR)" != "." ]; then \
rm -rf $(TARGET_SUBDIR); \
else true; fi
+ -rm -rf $(BUILD_SUBDIR)
-rm -f texinfo/po/Makefile texinfo/po/Makefile.in texinfo/info/Makefile
-rm -f texinfo/doc/Makefile texinfo/po/POTFILES
-rmdir texinfo/doc texinfo/info texinfo/intl texinfo/lib 2>/dev/null
@@ -1030,33 +17475,8 @@ maintainer-clean: local-maintainer-clean do-maintainer-clean local-clean
maintainer-clean: local-distclean
realclean: maintainer-clean
-# This rule is used to clean specific modules.
-.PHONY: $(CLEAN_MODULES) $(CLEAN_X11_MODULES) clean-gcc
-$(CLEAN_MODULES) $(CLEAN_X11_MODULES) clean-gcc:
- @dir=`echo $@ | sed -e 's/clean-//'`; \
- if [ -f ./$${dir}/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
- $(SET_LIB_PATH) \
- (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) clean); \
- else \
- true; \
- fi
-
-.PHONY: $(CLEAN_TARGET_MODULES)
-$(CLEAN_TARGET_MODULES):
- @dir=`echo $@ | sed -e 's/clean-target-//'`; \
- rm -f $(TARGET_SUBDIR)/$${dir}/multilib.out $(TARGET_SUBDIR)/$${dir}/tmpmulti.out; \
- if [ -f $(TARGET_SUBDIR)/$${dir}/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
- $(SET_LIB_PATH) \
- (cd $(TARGET_SUBDIR)/$${dir}; $(MAKE) $(TARGET_FLAGS_TO_PASS) clean); \
- else \
- true; \
- fi
-
-clean-target: $(CLEAN_TARGET_MODULES) clean-target-libgcc
+# Extra dependency for clean-target, owing to the mixed nature of gcc
+clean-target: clean-target-libgcc
clean-target-libgcc:
test ! -d gcc/libgcc || \
(cd gcc/libgcc && find . -type d -print) | \
@@ -1066,13 +17486,91 @@ clean-target-libgcc:
# Check target.
.PHONY: check do-check
-check:
- $(MAKE) do-check NOTPARALLEL=parallel-ok
+check: do-check
-do-check: $(CHECK_MODULES) \
- $(CHECK_TARGET_MODULES) \
- $(CHECK_X11_MODULES) \
- check-gcc
+# Only include modules actually being configured and built.
+do-check: maybe-check-gcc \
+ maybe-check-ash \
+ maybe-check-autoconf \
+ maybe-check-automake \
+ maybe-check-bash \
+ maybe-check-bfd \
+ maybe-check-opcodes \
+ maybe-check-binutils \
+ maybe-check-bison \
+ maybe-check-byacc \
+ maybe-check-bzip2 \
+ maybe-check-dejagnu \
+ maybe-check-diff \
+ maybe-check-dosutils \
+ maybe-check-etc \
+ maybe-check-fastjar \
+ maybe-check-fileutils \
+ maybe-check-findutils \
+ maybe-check-find \
+ maybe-check-flex \
+ maybe-check-gas \
+ maybe-check-gawk \
+ maybe-check-gettext \
+ maybe-check-gnuserv \
+ maybe-check-gprof \
+ maybe-check-gzip \
+ maybe-check-hello \
+ maybe-check-indent \
+ maybe-check-intl \
+ maybe-check-tcl \
+ maybe-check-itcl \
+ maybe-check-ld \
+ maybe-check-libgui \
+ maybe-check-libiberty \
+ maybe-check-libtool \
+ maybe-check-m4 \
+ maybe-check-make \
+ maybe-check-mmalloc \
+ maybe-check-patch \
+ maybe-check-perl \
+ maybe-check-prms \
+ maybe-check-rcs \
+ maybe-check-readline \
+ maybe-check-release \
+ maybe-check-recode \
+ maybe-check-sed \
+ maybe-check-send-pr \
+ maybe-check-shellutils \
+ maybe-check-sid \
+ maybe-check-sim \
+ maybe-check-tar \
+ maybe-check-texinfo \
+ maybe-check-textutils \
+ maybe-check-time \
+ maybe-check-uudecode \
+ maybe-check-wdiff \
+ maybe-check-zip \
+ maybe-check-zlib \
+ maybe-check-gdb \
+ maybe-check-expect \
+ maybe-check-guile \
+ maybe-check-tk \
+ maybe-check-tix \
+ maybe-check-libtermcap \
+ maybe-check-utils \
+ maybe-check-target-libstdc++-v3 \
+ maybe-check-target-newlib \
+ maybe-check-target-libf2c \
+ maybe-check-target-libobjc \
+ maybe-check-target-libtermcap \
+ maybe-check-target-winsup \
+ maybe-check-target-libgloss \
+ maybe-check-target-libiberty \
+ maybe-check-target-gperf \
+ maybe-check-target-examples \
+ maybe-check-target-libffi \
+ maybe-check-target-libjava \
+ maybe-check-target-zlib \
+ maybe-check-target-boehm-gc \
+ maybe-check-target-qthreads \
+ maybe-check-target-rda \
+ maybe-check-target-libada
# Automated reporting of test results.
@@ -1097,34 +17595,172 @@ mail-report-with-warnings.log: warning.log
# Installation targets.
-.PHONY: install install-cross uninstall source-vault binary-vault vault-install
-install: $(INSTALL_TARGET)
-install-cross: $(INSTALL_TARGET_CROSS)
+.PHONY: install uninstall
+install: installdirs install-host install-target
-uninstall:
- @echo "the uninstall target is not supported in this tree"
+.PHONY: install-host-nogcc
+install-host-nogcc: \
+ maybe-install-ash \
+ maybe-install-autoconf \
+ maybe-install-automake \
+ maybe-install-bash \
+ maybe-install-bfd \
+ maybe-install-opcodes \
+ maybe-install-binutils \
+ maybe-install-bison \
+ maybe-install-byacc \
+ maybe-install-bzip2 \
+ maybe-install-dejagnu \
+ maybe-install-diff \
+ maybe-install-dosutils \
+ maybe-install-etc \
+ maybe-install-fastjar \
+ maybe-install-fileutils \
+ maybe-install-findutils \
+ maybe-install-find \
+ maybe-install-flex \
+ maybe-install-gas \
+ maybe-install-gawk \
+ maybe-install-gettext \
+ maybe-install-gnuserv \
+ maybe-install-gprof \
+ maybe-install-gzip \
+ maybe-install-hello \
+ maybe-install-indent \
+ maybe-install-intl \
+ maybe-install-tcl \
+ maybe-install-itcl \
+ maybe-install-ld \
+ maybe-install-libgui \
+ maybe-install-libiberty \
+ maybe-install-libtool \
+ maybe-install-m4 \
+ maybe-install-make \
+ maybe-install-mmalloc \
+ maybe-install-patch \
+ maybe-install-perl \
+ maybe-install-prms \
+ maybe-install-rcs \
+ maybe-install-readline \
+ maybe-install-release \
+ maybe-install-recode \
+ maybe-install-sed \
+ maybe-install-send-pr \
+ maybe-install-shellutils \
+ maybe-install-sid \
+ maybe-install-sim \
+ maybe-install-tar \
+ maybe-install-texinfo \
+ maybe-install-textutils \
+ maybe-install-time \
+ maybe-install-uudecode \
+ maybe-install-wdiff \
+ maybe-install-zip \
+ maybe-install-zlib \
+ maybe-install-gdb \
+ maybe-install-expect \
+ maybe-install-guile \
+ maybe-install-tk \
+ maybe-install-tix \
+ maybe-install-libtermcap \
+ maybe-install-utils
-source-vault:
- $(MAKE) -f ./release/Build-A-Release \
- host=$(host_alias) source-vault
+.PHONY: install-host
+install-host: maybe-install-gcc \
+ maybe-install-ash \
+ maybe-install-autoconf \
+ maybe-install-automake \
+ maybe-install-bash \
+ maybe-install-bfd \
+ maybe-install-opcodes \
+ maybe-install-binutils \
+ maybe-install-bison \
+ maybe-install-byacc \
+ maybe-install-bzip2 \
+ maybe-install-dejagnu \
+ maybe-install-diff \
+ maybe-install-dosutils \
+ maybe-install-etc \
+ maybe-install-fastjar \
+ maybe-install-fileutils \
+ maybe-install-findutils \
+ maybe-install-find \
+ maybe-install-flex \
+ maybe-install-gas \
+ maybe-install-gawk \
+ maybe-install-gettext \
+ maybe-install-gnuserv \
+ maybe-install-gprof \
+ maybe-install-gzip \
+ maybe-install-hello \
+ maybe-install-indent \
+ maybe-install-intl \
+ maybe-install-tcl \
+ maybe-install-itcl \
+ maybe-install-ld \
+ maybe-install-libgui \
+ maybe-install-libiberty \
+ maybe-install-libtool \
+ maybe-install-m4 \
+ maybe-install-make \
+ maybe-install-mmalloc \
+ maybe-install-patch \
+ maybe-install-perl \
+ maybe-install-prms \
+ maybe-install-rcs \
+ maybe-install-readline \
+ maybe-install-release \
+ maybe-install-recode \
+ maybe-install-sed \
+ maybe-install-send-pr \
+ maybe-install-shellutils \
+ maybe-install-sid \
+ maybe-install-sim \
+ maybe-install-tar \
+ maybe-install-texinfo \
+ maybe-install-textutils \
+ maybe-install-time \
+ maybe-install-uudecode \
+ maybe-install-wdiff \
+ maybe-install-zip \
+ maybe-install-zlib \
+ maybe-install-gdb \
+ maybe-install-expect \
+ maybe-install-guile \
+ maybe-install-tk \
+ maybe-install-tix \
+ maybe-install-libtermcap \
+ maybe-install-utils
-binary-vault:
- $(MAKE) -f ./release/Build-A-Release \
- host=$(host_alias) target=$(target_alias)
+.PHONY: install-target
+install-target: \
+ maybe-install-target-libstdc++-v3 \
+ maybe-install-target-newlib \
+ maybe-install-target-libf2c \
+ maybe-install-target-libobjc \
+ maybe-install-target-libtermcap \
+ maybe-install-target-winsup \
+ maybe-install-target-libgloss \
+ maybe-install-target-libiberty \
+ maybe-install-target-gperf \
+ maybe-install-target-examples \
+ maybe-install-target-libffi \
+ maybe-install-target-libjava \
+ maybe-install-target-zlib \
+ maybe-install-target-boehm-gc \
+ maybe-install-target-qthreads \
+ maybe-install-target-rda \
+ maybe-install-target-libada
-vault-install:
- @if [ -f ./release/vault-install ] ; then \
- ./release/vault-install $(host_alias) $(target_alias) ; \
- else \
- true ; \
- fi
+uninstall:
+ @echo "the uninstall target is not supported in this tree"
.PHONY: install.all
install.all: install-no-fixedincludes
@if [ -f ./gcc/Makefile ] ; then \
- r=`${PWD}` ; export r ; \
+ r=`${PWD_COMMAND}` ; export r ; \
$(SET_LIB_PATH) \
- (cd ./gcc; \
+ (cd ./gcc && \
$(MAKE) $(FLAGS_TO_PASS) install-headers) ; \
else \
true ; \
@@ -1133,402 +17769,5913 @@ install.all: install-no-fixedincludes
# install-no-fixedincludes is used because Cygnus can not distribute
# the fixed header files.
.PHONY: install-no-fixedincludes
-install-no-fixedincludes: \
- installdirs \
- $(INSTALL_MODULES) \
- $(INSTALL_TARGET_MODULES) \
- $(INSTALL_X11_MODULES) \
- gcc-no-fixedincludes
+install-no-fixedincludes: installdirs install-host-nogcc \
+ install-target gcc-no-fixedincludes
-# Install the gcc headers files, but not the fixed include files,
-# which Cygnus is not allowed to distribute. This rule is very
-# dependent on the workings of the gcc Makefile.in.
-.PHONY: gcc-no-fixedincludes
-gcc-no-fixedincludes:
- @if [ -f ./gcc/Makefile ]; then \
- rm -rf gcc/tmp-include; \
- mv gcc/include gcc/tmp-include 2>/dev/null; \
- mkdir gcc/include; \
- cp $(srcdir)/gcc/gsyslimits.h gcc/include/syslimits.h; \
- touch gcc/stmp-fixinc gcc/include/fixed; \
- rm -f gcc/stmp-headers gcc/stmp-int-hdrs; \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}` ; export s; \
- $(SET_LIB_PATH) \
- (cd ./gcc; \
- $(MAKE) $(GCC_FLAGS_TO_PASS) install); \
- rm -rf gcc/include; \
- mv gcc/tmp-include gcc/include 2>/dev/null; \
- else true; fi
+### other supporting targets
-# This rule is used to build the modules which are built with the
-# build machine's native compiler.
-.PHONY: $(ALL_BUILD_MODULES)
-$(ALL_BUILD_MODULES):
- dir=`echo $@ | sed -e 's/all-build-//'`; \
- if [ -f ./$${dir}/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
- (cd $(BUILD_SUBDIR)/$${dir} && $(MAKE) all); \
- else \
- true; \
+MAKEDIRS= \
+ $(DESTDIR)$(prefix) \
+ $(DESTDIR)$(exec_prefix)
+.PHONY: installdirs
+installdirs: mkinstalldirs
+ $(SHELL) $(srcdir)/mkinstalldirs $(MAKEDIRS)
+
+dir.info: do-install-info
+ if [ -f $(srcdir)/texinfo/gen-info-dir ] ; then \
+ $(srcdir)/texinfo/gen-info-dir $(DESTDIR)$(infodir) $(srcdir)/texinfo/dir.info-template > dir.info.new ; \
+ mv -f dir.info.new dir.info ; \
+ else true ; \
fi
-# This rule is used to configure the modules which are built with the
-# native tools.
-.PHONY: $(CONFIGURE_BUILD_MODULES)
-$(CONFIGURE_BUILD_MODULES):
- @dir=`echo $@ | sed -e 's/configure-build-//'`; \
- if [ ! -d $(BUILD_SUBDIR) ]; then \
- true; \
- elif [ -f $(BUILD_SUBDIR)/$${dir}/Makefile ] ; then \
- true; \
- elif echo " $(BUILD_CONFIGDIRS) " | grep " $${dir} " >/dev/null 2>&1; then \
- if [ -d $(srcdir)/$${dir} ]; then \
- [ -d $(BUILD_SUBDIR)/$${dir} ] || mkdir $(BUILD_SUBDIR)/$${dir};\
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
- AR="$(AR_FOR_BUILD)"; export AR; \
- AS="$(AS_FOR_BUILD)"; export AS; \
- CC="$(CC_FOR_BUILD)"; export CC; \
- CFLAGS="$(CFLAGS_FOR_BUILD)"; export CFLAGS; \
- CXX="$(CXX_FOR_BUILD)"; export CXX; \
- CXXFLAGS="$(CXXFLAGS_FOR_BUILD)"; export CXXFLAGS; \
- GCJ="$(GCJ_FOR_BUILD)"; export GCJ; \
- DLLTOOL="$(DLLTOOL_FOR_BUILD)"; export DLLTOOL; \
- LD="$(LD_FOR_BUILD)"; export LD; \
- LDFLAGS="$(LDFLAGS_FOR_BUILD)"; export LDFLAGS; \
- NM="$(NM_FOR_BUILD)"; export NM; \
- RANLIB="$(RANLIB_FOR_BUILD)"; export RANLIB; \
- WINDRES="$(WINDRES_FOR_BUILD)"; export WINDRES; \
- echo Configuring in $(BUILD_SUBDIR)/$${dir}; \
- cd "$(BUILD_SUBDIR)/$${dir}" || exit 1; \
- case $(srcdir) in \
- /* | [A-Za-z]:[\\/]*) \
- topdir=$(srcdir) ;; \
- *) \
- case "$(BUILD_SUBDIR)" in \
+dist:
+ @echo "Building a full distribution of this tree isn't done"
+ @echo "via 'make dist'. Check out the etc/ subdirectory"
+
+etags tags: TAGS
+
+# Right now this just builds TAGS in each subdirectory. emacs19 has the
+# ability to use several tags files at once, so there is probably no need
+# to combine them into one big TAGS file (like CVS 1.3 does). We could
+# (if we felt like it) have this Makefile write a piece of elisp which
+# the user could load to tell emacs19 where all the TAGS files we just
+# built are.
+TAGS: do-TAGS
+
+# --------------------------------------
+# Modules which run on the build machine
+# --------------------------------------
+
+.PHONY: configure-build-libiberty maybe-configure-build-libiberty
+maybe-configure-build-libiberty:
+configure-build-libiberty:
+ @test ! -f $(BUILD_SUBDIR)/libiberty/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(BUILD_SUBDIR)/libiberty ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ AR="$(AR_FOR_BUILD)"; export AR; \
+ AS="$(AS_FOR_BUILD)"; export AS; \
+ CC="$(CC_FOR_BUILD)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_BUILD)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX_FOR_BUILD)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_BUILD)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_BUILD)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_BUILD)"; export DLLTOOL; \
+ LD="$(LD_FOR_BUILD)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_BUILD)"; export LDFLAGS; \
+ NM="$(NM_FOR_BUILD)"; export NM; \
+ RANLIB="$(RANLIB_FOR_BUILD)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_BUILD)"; export WINDRES; \
+ echo Configuring in $(BUILD_SUBDIR)/libiberty; \
+ cd "$(BUILD_SUBDIR)/libiberty" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(BUILD_SUBDIR)" in \
.) topdir="../$(srcdir)" ;; \
*) topdir="../../$(srcdir)" ;; \
- esac ;; \
- esac; \
- if [ "$(srcdir)" = "." ] ; then \
- if [ "$(BUILD_SUBDIR)" != "." ] ; then \
- if $(SHELL) $$s/symlink-tree $${topdir}/$${dir} "no-such-file" ; then \
- if [ -f Makefile ]; then \
- if $(MAKE) distclean; then \
- true; \
- else \
- exit 1; \
- fi; \
- else \
- true; \
- fi; \
- else \
- exit 1; \
- fi; \
+ esac ;; \
+ esac; \
+ if [ "$(srcdir)" = "." ] ; then \
+ if [ "$(BUILD_SUBDIR)" != "." ] ; then \
+ if $(SHELL) $$s/symlink-tree $${topdir}/libiberty "no-such-file" ; then \
+ if [ -f Makefile ]; then \
+ if $(MAKE) distclean; then \
+ true; \
+ else \
+ exit 1; \
+ fi; \
else \
- true; \
+ true; \
fi; \
- srcdiroption="--srcdir=."; \
- libsrcdir="."; \
else \
- srcdiroption="--srcdir=$${topdir}/$${dir}"; \
- libsrcdir="$$s/$${dir}"; \
- fi; \
- if [ -f $${libsrcdir}/configure ] ; then \
- rm -f no-such-file skip-this-dir; \
- CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
- $(BUILD_CONFIGARGS) $${srcdiroption} \
- --with-build-subdir="$(BUILD_SUBDIR)"; \
- else \
- rm -f no-such-file skip-this-dir; \
- CONFIG_SITE=no-such-file $(SHELL) $$s/configure \
- $(BUILD_CONFIGARGS) $${srcdiroption} \
- --with-build-subdir="$(BUILD_SUBDIR)"; \
- fi || exit 1; \
- if [ -f skip-this-dir ] ; then \
- sh skip-this-dir; \
- rm -f skip-this-dir; \
- cd ..; rmdir $${dir} || true; \
- else \
- true; \
+ exit 1; \
fi; \
else \
true; \
fi; \
+ srcdiroption="--srcdir=."; \
+ libsrcdir="."; \
else \
- true; \
+ srcdiroption="--srcdir=$${topdir}/libiberty"; \
+ libsrcdir="$$s/libiberty"; \
+ fi; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(BUILD_CONFIGARGS) $${srcdiroption} \
+ --with-build-subdir="$(BUILD_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-build-libiberty maybe-all-build-libiberty
+maybe-all-build-libiberty:
+all-build-libiberty: configure-build-libiberty
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ (cd $(BUILD_SUBDIR)/libiberty && $(MAKE) all)
+
+
+# --------------------------------------
+# Modules which run on the host machine
+# --------------------------------------
+
+.PHONY: configure-ash maybe-configure-ash
+maybe-configure-ash:
+configure-ash:
+ @test ! -f ash/Makefile || exit 0; \
+ [ -d ash ] || mkdir ash; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in ash; \
+ cd ash || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/ash"; \
+ libsrcdir="$$s/ash";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/ash"; \
+ libsrcdir="$$s/ash";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-ash maybe-all-ash
+maybe-all-ash:
+all-ash: configure-ash
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd ash && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-ash maybe-check-ash
+maybe-check-ash:
+
+check-ash:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd ash && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-ash maybe-install-ash
+maybe-install-ash:
+
+install-ash: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd ash && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-autoconf maybe-configure-autoconf
+maybe-configure-autoconf:
+configure-autoconf:
+ @test ! -f autoconf/Makefile || exit 0; \
+ [ -d autoconf ] || mkdir autoconf; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in autoconf; \
+ cd autoconf || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/autoconf"; \
+ libsrcdir="$$s/autoconf";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/autoconf"; \
+ libsrcdir="$$s/autoconf";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-autoconf maybe-all-autoconf
+maybe-all-autoconf:
+all-autoconf: configure-autoconf
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd autoconf && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-autoconf maybe-check-autoconf
+maybe-check-autoconf:
+
+check-autoconf:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd autoconf && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-autoconf maybe-install-autoconf
+maybe-install-autoconf:
+
+install-autoconf: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd autoconf && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-automake maybe-configure-automake
+maybe-configure-automake:
+configure-automake:
+ @test ! -f automake/Makefile || exit 0; \
+ [ -d automake ] || mkdir automake; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in automake; \
+ cd automake || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/automake"; \
+ libsrcdir="$$s/automake";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/automake"; \
+ libsrcdir="$$s/automake";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-automake maybe-all-automake
+maybe-all-automake:
+all-automake: configure-automake
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd automake && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-automake maybe-check-automake
+maybe-check-automake:
+
+check-automake:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd automake && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-automake maybe-install-automake
+maybe-install-automake:
+
+install-automake: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd automake && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-bash maybe-configure-bash
+maybe-configure-bash:
+configure-bash:
+ @test ! -f bash/Makefile || exit 0; \
+ [ -d bash ] || mkdir bash; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in bash; \
+ cd bash || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/bash"; \
+ libsrcdir="$$s/bash";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/bash"; \
+ libsrcdir="$$s/bash";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-bash maybe-all-bash
+maybe-all-bash:
+all-bash: configure-bash
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd bash && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-bash maybe-check-bash
+maybe-check-bash:
+
+check-bash:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd bash && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-bash maybe-install-bash
+maybe-install-bash:
+
+install-bash: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd bash && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-bfd maybe-configure-bfd
+maybe-configure-bfd:
+configure-bfd:
+ @test ! -f bfd/Makefile || exit 0; \
+ [ -d bfd ] || mkdir bfd; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in bfd; \
+ cd bfd || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/bfd"; \
+ libsrcdir="$$s/bfd";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/bfd"; \
+ libsrcdir="$$s/bfd";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-bfd maybe-all-bfd
+maybe-all-bfd:
+all-bfd: configure-bfd
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd bfd && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-bfd maybe-check-bfd
+maybe-check-bfd:
+
+check-bfd:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd bfd && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-bfd maybe-install-bfd
+maybe-install-bfd:
+
+install-bfd: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd bfd && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-opcodes maybe-configure-opcodes
+maybe-configure-opcodes:
+configure-opcodes:
+ @test ! -f opcodes/Makefile || exit 0; \
+ [ -d opcodes ] || mkdir opcodes; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in opcodes; \
+ cd opcodes || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/opcodes"; \
+ libsrcdir="$$s/opcodes";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/opcodes"; \
+ libsrcdir="$$s/opcodes";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-opcodes maybe-all-opcodes
+maybe-all-opcodes:
+all-opcodes: configure-opcodes
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd opcodes && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-opcodes maybe-check-opcodes
+maybe-check-opcodes:
+
+check-opcodes:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd opcodes && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-opcodes maybe-install-opcodes
+maybe-install-opcodes:
+
+install-opcodes: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd opcodes && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-binutils maybe-configure-binutils
+maybe-configure-binutils:
+configure-binutils:
+ @test ! -f binutils/Makefile || exit 0; \
+ [ -d binutils ] || mkdir binutils; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in binutils; \
+ cd binutils || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/binutils"; \
+ libsrcdir="$$s/binutils";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/binutils"; \
+ libsrcdir="$$s/binutils";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-binutils maybe-all-binutils
+maybe-all-binutils:
+all-binutils: configure-binutils
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd binutils && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-binutils maybe-check-binutils
+maybe-check-binutils:
+
+check-binutils:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd binutils && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-binutils maybe-install-binutils
+maybe-install-binutils:
+
+install-binutils: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd binutils && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-bison maybe-configure-bison
+maybe-configure-bison:
+configure-bison:
+ @test ! -f bison/Makefile || exit 0; \
+ [ -d bison ] || mkdir bison; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in bison; \
+ cd bison || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/bison"; \
+ libsrcdir="$$s/bison";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/bison"; \
+ libsrcdir="$$s/bison";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-bison maybe-all-bison
+maybe-all-bison:
+all-bison: configure-bison
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd bison && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-bison maybe-check-bison
+maybe-check-bison:
+
+# This module is only tested in a native toolchain.
+check-bison:
+ @if [ '$(host)' = '$(target)' ] ; then \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd bison && $(MAKE) $(FLAGS_TO_PASS) check); \
fi
-# This rule is used to build the modules which use FLAGS_TO_PASS. To
-# build a target all-X means to cd to X and make all.
-#
-# all-gui, and all-libproc are handled specially because
-# they are still experimental, and if they fail to build, that
-# shouldn't stop "make all".
-.PHONY: $(ALL_MODULES) all-gui all-libproc
-$(ALL_MODULES) all-gui all-libproc:
- @dir=`echo $@ | sed -e 's/all-//'`; \
- if [ -f ./$${dir}/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
+
+.PHONY: install-bison maybe-install-bison
+maybe-install-bison:
+
+install-bison: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd bison && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-byacc maybe-configure-byacc
+maybe-configure-byacc:
+configure-byacc:
+ @test ! -f byacc/Makefile || exit 0; \
+ [ -d byacc ] || mkdir byacc; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in byacc; \
+ cd byacc || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/byacc"; \
+ libsrcdir="$$s/byacc";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/byacc"; \
+ libsrcdir="$$s/byacc";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-byacc maybe-all-byacc
+maybe-all-byacc:
+all-byacc: configure-byacc
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd byacc && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-byacc maybe-check-byacc
+maybe-check-byacc:
+
+# This module is only tested in a native toolchain.
+check-byacc:
+ @if [ '$(host)' = '$(target)' ] ; then \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
$(SET_LIB_PATH) \
- (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) all); \
- else \
- true; \
+ (cd byacc && $(MAKE) $(FLAGS_TO_PASS) check); \
fi
-# These rules are used to check the modules which use FLAGS_TO_PASS.
-# To build a target check-X means to cd to X and make check. Some
-# modules are only tested in a native toolchain.
-
-.PHONY: $(CHECK_MODULES) $(NATIVE_CHECK_MODULES) $(CROSS_CHECK_MODULES)
-$(NATIVE_CHECK_MODULES):
- @if [ '$(host_canonical)' = '$(target_canonical)' ] ; then \
- dir=`echo $@ | sed -e 's/check-//'`; \
- if [ -f ./$${dir}/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
- $(SET_LIB_PATH) \
- (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) check); \
- else \
- true; \
- fi; \
+
+.PHONY: install-byacc maybe-install-byacc
+maybe-install-byacc:
+
+install-byacc: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd byacc && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-bzip2 maybe-configure-bzip2
+maybe-configure-bzip2:
+configure-bzip2:
+ @test ! -f bzip2/Makefile || exit 0; \
+ [ -d bzip2 ] || mkdir bzip2; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in bzip2; \
+ cd bzip2 || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/bzip2"; \
+ libsrcdir="$$s/bzip2";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/bzip2"; \
+ libsrcdir="$$s/bzip2";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-bzip2 maybe-all-bzip2
+maybe-all-bzip2:
+all-bzip2: configure-bzip2
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd bzip2 && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-bzip2 maybe-check-bzip2
+maybe-check-bzip2:
+
+check-bzip2:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd bzip2 && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-bzip2 maybe-install-bzip2
+maybe-install-bzip2:
+
+install-bzip2: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd bzip2 && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-dejagnu maybe-configure-dejagnu
+maybe-configure-dejagnu:
+configure-dejagnu:
+ @test ! -f dejagnu/Makefile || exit 0; \
+ [ -d dejagnu ] || mkdir dejagnu; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in dejagnu; \
+ cd dejagnu || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/dejagnu"; \
+ libsrcdir="$$s/dejagnu";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/dejagnu"; \
+ libsrcdir="$$s/dejagnu";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-dejagnu maybe-all-dejagnu
+maybe-all-dejagnu:
+all-dejagnu: configure-dejagnu
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd dejagnu && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-dejagnu maybe-check-dejagnu
+maybe-check-dejagnu:
+
+check-dejagnu:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd dejagnu && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-dejagnu maybe-install-dejagnu
+maybe-install-dejagnu:
+
+install-dejagnu: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd dejagnu && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-diff maybe-configure-diff
+maybe-configure-diff:
+configure-diff:
+ @test ! -f diff/Makefile || exit 0; \
+ [ -d diff ] || mkdir diff; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in diff; \
+ cd diff || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/diff"; \
+ libsrcdir="$$s/diff";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/diff"; \
+ libsrcdir="$$s/diff";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-diff maybe-all-diff
+maybe-all-diff:
+all-diff: configure-diff
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd diff && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-diff maybe-check-diff
+maybe-check-diff:
+
+check-diff:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd diff && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-diff maybe-install-diff
+maybe-install-diff:
+
+install-diff: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd diff && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-dosutils maybe-configure-dosutils
+maybe-configure-dosutils:
+configure-dosutils:
+ @test ! -f dosutils/Makefile || exit 0; \
+ [ -d dosutils ] || mkdir dosutils; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in dosutils; \
+ cd dosutils || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/dosutils"; \
+ libsrcdir="$$s/dosutils";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/dosutils"; \
+ libsrcdir="$$s/dosutils";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-dosutils maybe-all-dosutils
+maybe-all-dosutils:
+all-dosutils: configure-dosutils
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd dosutils && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-dosutils maybe-check-dosutils
+maybe-check-dosutils:
+
+check-dosutils:
+
+
+.PHONY: install-dosutils maybe-install-dosutils
+maybe-install-dosutils:
+
+install-dosutils: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd dosutils && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-etc maybe-configure-etc
+maybe-configure-etc:
+configure-etc:
+ @test ! -f etc/Makefile || exit 0; \
+ [ -d etc ] || mkdir etc; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in etc; \
+ cd etc || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/etc"; \
+ libsrcdir="$$s/etc";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/etc"; \
+ libsrcdir="$$s/etc";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-etc maybe-all-etc
+maybe-all-etc:
+all-etc: configure-etc
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd etc && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-etc maybe-check-etc
+maybe-check-etc:
+
+check-etc:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd etc && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-etc maybe-install-etc
+maybe-install-etc:
+
+install-etc: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd etc && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-fastjar maybe-configure-fastjar
+maybe-configure-fastjar:
+configure-fastjar:
+ @test ! -f fastjar/Makefile || exit 0; \
+ [ -d fastjar ] || mkdir fastjar; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in fastjar; \
+ cd fastjar || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/fastjar"; \
+ libsrcdir="$$s/fastjar";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/fastjar"; \
+ libsrcdir="$$s/fastjar";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-fastjar maybe-all-fastjar
+maybe-all-fastjar:
+all-fastjar: configure-fastjar
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd fastjar && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-fastjar maybe-check-fastjar
+maybe-check-fastjar:
+
+# This module is only tested in a native toolchain.
+check-fastjar:
+ @if [ '$(host)' = '$(target)' ] ; then \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd fastjar && $(MAKE) $(FLAGS_TO_PASS) check); \
fi
-$(CROSS_CHECK_MODULES):
- @dir=`echo $@ | sed -e 's/check-//'`; \
- if [ -f ./$${dir}/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
+
+.PHONY: install-fastjar maybe-install-fastjar
+maybe-install-fastjar:
+
+install-fastjar: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd fastjar && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-fileutils maybe-configure-fileutils
+maybe-configure-fileutils:
+configure-fileutils:
+ @test ! -f fileutils/Makefile || exit 0; \
+ [ -d fileutils ] || mkdir fileutils; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in fileutils; \
+ cd fileutils || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/fileutils"; \
+ libsrcdir="$$s/fileutils";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/fileutils"; \
+ libsrcdir="$$s/fileutils";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-fileutils maybe-all-fileutils
+maybe-all-fileutils:
+all-fileutils: configure-fileutils
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd fileutils && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-fileutils maybe-check-fileutils
+maybe-check-fileutils:
+
+check-fileutils:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd fileutils && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-fileutils maybe-install-fileutils
+maybe-install-fileutils:
+
+install-fileutils: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd fileutils && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-findutils maybe-configure-findutils
+maybe-configure-findutils:
+configure-findutils:
+ @test ! -f findutils/Makefile || exit 0; \
+ [ -d findutils ] || mkdir findutils; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in findutils; \
+ cd findutils || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/findutils"; \
+ libsrcdir="$$s/findutils";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/findutils"; \
+ libsrcdir="$$s/findutils";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-findutils maybe-all-findutils
+maybe-all-findutils:
+all-findutils: configure-findutils
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd findutils && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-findutils maybe-check-findutils
+maybe-check-findutils:
+
+check-findutils:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd findutils && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-findutils maybe-install-findutils
+maybe-install-findutils:
+
+install-findutils: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd findutils && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-find maybe-configure-find
+maybe-configure-find:
+configure-find:
+ @test ! -f find/Makefile || exit 0; \
+ [ -d find ] || mkdir find; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in find; \
+ cd find || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/find"; \
+ libsrcdir="$$s/find";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/find"; \
+ libsrcdir="$$s/find";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-find maybe-all-find
+maybe-all-find:
+all-find: configure-find
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd find && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-find maybe-check-find
+maybe-check-find:
+
+check-find:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd find && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-find maybe-install-find
+maybe-install-find:
+
+install-find: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd find && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-flex maybe-configure-flex
+maybe-configure-flex:
+configure-flex:
+ @test ! -f flex/Makefile || exit 0; \
+ [ -d flex ] || mkdir flex; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in flex; \
+ cd flex || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/flex"; \
+ libsrcdir="$$s/flex";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/flex"; \
+ libsrcdir="$$s/flex";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-flex maybe-all-flex
+maybe-all-flex:
+all-flex: configure-flex
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd flex && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-flex maybe-check-flex
+maybe-check-flex:
+
+# This module is only tested in a native toolchain.
+check-flex:
+ @if [ '$(host)' = '$(target)' ] ; then \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
$(SET_LIB_PATH) \
- (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) check); \
- else \
- true; \
+ (cd flex && $(MAKE) $(FLAGS_TO_PASS) check); \
fi
-# This rule is used to install the modules which use FLAGS_TO_PASS.
-# To build a target install-X means to cd to X and make install.
-.PHONY: $(INSTALL_MODULES)
-$(INSTALL_MODULES): installdirs
- @dir=`echo $@ | sed -e 's/install-//'`; \
- if [ -f ./$${dir}/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
+
+.PHONY: install-flex maybe-install-flex
+maybe-install-flex:
+
+install-flex: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd flex && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-gas maybe-configure-gas
+maybe-configure-gas:
+configure-gas:
+ @test ! -f gas/Makefile || exit 0; \
+ [ -d gas ] || mkdir gas; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in gas; \
+ cd gas || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/gas"; \
+ libsrcdir="$$s/gas";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/gas"; \
+ libsrcdir="$$s/gas";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-gas maybe-all-gas
+maybe-all-gas:
+all-gas: configure-gas
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gas && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-gas maybe-check-gas
+maybe-check-gas:
+
+check-gas:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gas && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-gas maybe-install-gas
+maybe-install-gas:
+
+install-gas: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gas && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-gawk maybe-configure-gawk
+maybe-configure-gawk:
+configure-gawk:
+ @test ! -f gawk/Makefile || exit 0; \
+ [ -d gawk ] || mkdir gawk; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in gawk; \
+ cd gawk || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/gawk"; \
+ libsrcdir="$$s/gawk";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/gawk"; \
+ libsrcdir="$$s/gawk";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-gawk maybe-all-gawk
+maybe-all-gawk:
+all-gawk: configure-gawk
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gawk && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-gawk maybe-check-gawk
+maybe-check-gawk:
+
+check-gawk:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gawk && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-gawk maybe-install-gawk
+maybe-install-gawk:
+
+install-gawk: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gawk && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-gettext maybe-configure-gettext
+maybe-configure-gettext:
+configure-gettext:
+ @test ! -f gettext/Makefile || exit 0; \
+ [ -d gettext ] || mkdir gettext; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in gettext; \
+ cd gettext || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/gettext"; \
+ libsrcdir="$$s/gettext";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/gettext"; \
+ libsrcdir="$$s/gettext";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-gettext maybe-all-gettext
+maybe-all-gettext:
+all-gettext: configure-gettext
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gettext && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-gettext maybe-check-gettext
+maybe-check-gettext:
+
+check-gettext:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gettext && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-gettext maybe-install-gettext
+maybe-install-gettext:
+
+install-gettext: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gettext && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-gnuserv maybe-configure-gnuserv
+maybe-configure-gnuserv:
+configure-gnuserv:
+ @test ! -f gnuserv/Makefile || exit 0; \
+ [ -d gnuserv ] || mkdir gnuserv; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in gnuserv; \
+ cd gnuserv || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/gnuserv"; \
+ libsrcdir="$$s/gnuserv";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/gnuserv"; \
+ libsrcdir="$$s/gnuserv";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-gnuserv maybe-all-gnuserv
+maybe-all-gnuserv:
+all-gnuserv: configure-gnuserv
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gnuserv && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-gnuserv maybe-check-gnuserv
+maybe-check-gnuserv:
+
+check-gnuserv:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gnuserv && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-gnuserv maybe-install-gnuserv
+maybe-install-gnuserv:
+
+install-gnuserv: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gnuserv && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-gprof maybe-configure-gprof
+maybe-configure-gprof:
+configure-gprof:
+ @test ! -f gprof/Makefile || exit 0; \
+ [ -d gprof ] || mkdir gprof; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in gprof; \
+ cd gprof || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/gprof"; \
+ libsrcdir="$$s/gprof";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/gprof"; \
+ libsrcdir="$$s/gprof";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-gprof maybe-all-gprof
+maybe-all-gprof:
+all-gprof: configure-gprof
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gprof && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-gprof maybe-check-gprof
+maybe-check-gprof:
+
+check-gprof:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gprof && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-gprof maybe-install-gprof
+maybe-install-gprof:
+
+install-gprof: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gprof && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-gzip maybe-configure-gzip
+maybe-configure-gzip:
+configure-gzip:
+ @test ! -f gzip/Makefile || exit 0; \
+ [ -d gzip ] || mkdir gzip; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in gzip; \
+ cd gzip || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/gzip"; \
+ libsrcdir="$$s/gzip";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/gzip"; \
+ libsrcdir="$$s/gzip";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-gzip maybe-all-gzip
+maybe-all-gzip:
+all-gzip: configure-gzip
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gzip && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-gzip maybe-check-gzip
+maybe-check-gzip:
+
+check-gzip:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gzip && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-gzip maybe-install-gzip
+maybe-install-gzip:
+
+install-gzip: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gzip && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-hello maybe-configure-hello
+maybe-configure-hello:
+configure-hello:
+ @test ! -f hello/Makefile || exit 0; \
+ [ -d hello ] || mkdir hello; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in hello; \
+ cd hello || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/hello"; \
+ libsrcdir="$$s/hello";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/hello"; \
+ libsrcdir="$$s/hello";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-hello maybe-all-hello
+maybe-all-hello:
+all-hello: configure-hello
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd hello && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-hello maybe-check-hello
+maybe-check-hello:
+
+check-hello:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd hello && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-hello maybe-install-hello
+maybe-install-hello:
+
+install-hello: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd hello && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-indent maybe-configure-indent
+maybe-configure-indent:
+configure-indent:
+ @test ! -f indent/Makefile || exit 0; \
+ [ -d indent ] || mkdir indent; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in indent; \
+ cd indent || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/indent"; \
+ libsrcdir="$$s/indent";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/indent"; \
+ libsrcdir="$$s/indent";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-indent maybe-all-indent
+maybe-all-indent:
+all-indent: configure-indent
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd indent && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-indent maybe-check-indent
+maybe-check-indent:
+
+check-indent:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd indent && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-indent maybe-install-indent
+maybe-install-indent:
+
+install-indent: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd indent && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-intl maybe-configure-intl
+maybe-configure-intl:
+configure-intl:
+ @test ! -f intl/Makefile || exit 0; \
+ [ -d intl ] || mkdir intl; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in intl; \
+ cd intl || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/intl"; \
+ libsrcdir="$$s/intl";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/intl"; \
+ libsrcdir="$$s/intl";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-intl maybe-all-intl
+maybe-all-intl:
+all-intl: configure-intl
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd intl && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-intl maybe-check-intl
+maybe-check-intl:
+
+check-intl:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd intl && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-intl maybe-install-intl
+maybe-install-intl:
+
+install-intl: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd intl && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-tcl maybe-configure-tcl
+maybe-configure-tcl:
+configure-tcl:
+ @test ! -f tcl/Makefile || exit 0; \
+ [ -d tcl ] || mkdir tcl; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in tcl; \
+ cd tcl || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/tcl"; \
+ libsrcdir="$$s/tcl";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/tcl"; \
+ libsrcdir="$$s/tcl";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-tcl maybe-all-tcl
+maybe-all-tcl:
+all-tcl: configure-tcl
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd tcl && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-tcl maybe-check-tcl
+maybe-check-tcl:
+
+check-tcl:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd tcl && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-tcl maybe-install-tcl
+maybe-install-tcl:
+
+install-tcl: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd tcl && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-itcl maybe-configure-itcl
+maybe-configure-itcl:
+configure-itcl:
+ @test ! -f itcl/Makefile || exit 0; \
+ [ -d itcl ] || mkdir itcl; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in itcl; \
+ cd itcl || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/itcl"; \
+ libsrcdir="$$s/itcl";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/itcl"; \
+ libsrcdir="$$s/itcl";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-itcl maybe-all-itcl
+maybe-all-itcl:
+all-itcl: configure-itcl
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd itcl && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-itcl maybe-check-itcl
+maybe-check-itcl:
+
+check-itcl:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd itcl && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-itcl maybe-install-itcl
+maybe-install-itcl:
+
+install-itcl: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd itcl && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-ld maybe-configure-ld
+maybe-configure-ld:
+configure-ld:
+ @test ! -f ld/Makefile || exit 0; \
+ [ -d ld ] || mkdir ld; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in ld; \
+ cd ld || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/ld"; \
+ libsrcdir="$$s/ld";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/ld"; \
+ libsrcdir="$$s/ld";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-ld maybe-all-ld
+maybe-all-ld:
+all-ld: configure-ld
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd ld && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-ld maybe-check-ld
+maybe-check-ld:
+
+check-ld:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd ld && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-ld maybe-install-ld
+maybe-install-ld:
+
+install-ld: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd ld && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-libgui maybe-configure-libgui
+maybe-configure-libgui:
+configure-libgui:
+ @test ! -f libgui/Makefile || exit 0; \
+ [ -d libgui ] || mkdir libgui; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in libgui; \
+ cd libgui || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/libgui"; \
+ libsrcdir="$$s/libgui";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/libgui"; \
+ libsrcdir="$$s/libgui";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-libgui maybe-all-libgui
+maybe-all-libgui:
+all-libgui: configure-libgui
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd libgui && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-libgui maybe-check-libgui
+maybe-check-libgui:
+
+check-libgui:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd libgui && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-libgui maybe-install-libgui
+maybe-install-libgui:
+
+install-libgui: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd libgui && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-libiberty maybe-configure-libiberty
+maybe-configure-libiberty:
+configure-libiberty:
+ @test ! -f libiberty/Makefile || exit 0; \
+ [ -d libiberty ] || mkdir libiberty; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in libiberty; \
+ cd libiberty || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/libiberty"; \
+ libsrcdir="$$s/libiberty";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/libiberty"; \
+ libsrcdir="$$s/libiberty";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-libiberty maybe-all-libiberty
+maybe-all-libiberty:
+all-libiberty: configure-libiberty
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd libiberty && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-libiberty maybe-check-libiberty
+maybe-check-libiberty:
+
+check-libiberty:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd libiberty && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-libiberty maybe-install-libiberty
+maybe-install-libiberty:
+
+install-libiberty: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd libiberty && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-libtool maybe-configure-libtool
+maybe-configure-libtool:
+configure-libtool:
+ @test ! -f libtool/Makefile || exit 0; \
+ [ -d libtool ] || mkdir libtool; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in libtool; \
+ cd libtool || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/libtool"; \
+ libsrcdir="$$s/libtool";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/libtool"; \
+ libsrcdir="$$s/libtool";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-libtool maybe-all-libtool
+maybe-all-libtool:
+all-libtool: configure-libtool
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd libtool && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-libtool maybe-check-libtool
+maybe-check-libtool:
+
+check-libtool:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd libtool && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-libtool maybe-install-libtool
+maybe-install-libtool:
+
+install-libtool: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd libtool && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-m4 maybe-configure-m4
+maybe-configure-m4:
+configure-m4:
+ @test ! -f m4/Makefile || exit 0; \
+ [ -d m4 ] || mkdir m4; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in m4; \
+ cd m4 || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/m4"; \
+ libsrcdir="$$s/m4";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/m4"; \
+ libsrcdir="$$s/m4";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-m4 maybe-all-m4
+maybe-all-m4:
+all-m4: configure-m4
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd m4 && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-m4 maybe-check-m4
+maybe-check-m4:
+
+check-m4:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd m4 && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-m4 maybe-install-m4
+maybe-install-m4:
+
+install-m4: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd m4 && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-make maybe-configure-make
+maybe-configure-make:
+configure-make:
+ @test ! -f make/Makefile || exit 0; \
+ [ -d make ] || mkdir make; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in make; \
+ cd make || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/make"; \
+ libsrcdir="$$s/make";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/make"; \
+ libsrcdir="$$s/make";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-make maybe-all-make
+maybe-all-make:
+all-make: configure-make
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd make && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-make maybe-check-make
+maybe-check-make:
+
+check-make:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd make && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-make maybe-install-make
+maybe-install-make:
+
+install-make: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd make && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-mmalloc maybe-configure-mmalloc
+maybe-configure-mmalloc:
+configure-mmalloc:
+ @test ! -f mmalloc/Makefile || exit 0; \
+ [ -d mmalloc ] || mkdir mmalloc; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in mmalloc; \
+ cd mmalloc || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/mmalloc"; \
+ libsrcdir="$$s/mmalloc";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/mmalloc"; \
+ libsrcdir="$$s/mmalloc";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-mmalloc maybe-all-mmalloc
+maybe-all-mmalloc:
+all-mmalloc: configure-mmalloc
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd mmalloc && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-mmalloc maybe-check-mmalloc
+maybe-check-mmalloc:
+
+check-mmalloc:
+
+
+.PHONY: install-mmalloc maybe-install-mmalloc
+maybe-install-mmalloc:
+
+install-mmalloc: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd mmalloc && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-patch maybe-configure-patch
+maybe-configure-patch:
+configure-patch:
+ @test ! -f patch/Makefile || exit 0; \
+ [ -d patch ] || mkdir patch; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in patch; \
+ cd patch || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/patch"; \
+ libsrcdir="$$s/patch";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/patch"; \
+ libsrcdir="$$s/patch";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-patch maybe-all-patch
+maybe-all-patch:
+all-patch: configure-patch
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd patch && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-patch maybe-check-patch
+maybe-check-patch:
+
+check-patch:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd patch && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-patch maybe-install-patch
+maybe-install-patch:
+
+install-patch: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd patch && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-perl maybe-configure-perl
+maybe-configure-perl:
+configure-perl:
+ @test ! -f perl/Makefile || exit 0; \
+ [ -d perl ] || mkdir perl; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in perl; \
+ cd perl || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/perl"; \
+ libsrcdir="$$s/perl";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/perl"; \
+ libsrcdir="$$s/perl";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-perl maybe-all-perl
+maybe-all-perl:
+all-perl: configure-perl
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd perl && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-perl maybe-check-perl
+maybe-check-perl:
+
+check-perl:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd perl && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-perl maybe-install-perl
+maybe-install-perl:
+
+install-perl: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd perl && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-prms maybe-configure-prms
+maybe-configure-prms:
+configure-prms:
+ @test ! -f prms/Makefile || exit 0; \
+ [ -d prms ] || mkdir prms; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in prms; \
+ cd prms || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/prms"; \
+ libsrcdir="$$s/prms";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/prms"; \
+ libsrcdir="$$s/prms";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-prms maybe-all-prms
+maybe-all-prms:
+all-prms: configure-prms
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd prms && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-prms maybe-check-prms
+maybe-check-prms:
+
+check-prms:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd prms && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-prms maybe-install-prms
+maybe-install-prms:
+
+install-prms: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd prms && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-rcs maybe-configure-rcs
+maybe-configure-rcs:
+configure-rcs:
+ @test ! -f rcs/Makefile || exit 0; \
+ [ -d rcs ] || mkdir rcs; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in rcs; \
+ cd rcs || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/rcs"; \
+ libsrcdir="$$s/rcs";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/rcs"; \
+ libsrcdir="$$s/rcs";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-rcs maybe-all-rcs
+maybe-all-rcs:
+all-rcs: configure-rcs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd rcs && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-rcs maybe-check-rcs
+maybe-check-rcs:
+
+check-rcs:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd rcs && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-rcs maybe-install-rcs
+maybe-install-rcs:
+
+install-rcs: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd rcs && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-readline maybe-configure-readline
+maybe-configure-readline:
+configure-readline:
+ @test ! -f readline/Makefile || exit 0; \
+ [ -d readline ] || mkdir readline; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in readline; \
+ cd readline || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/readline"; \
+ libsrcdir="$$s/readline";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/readline"; \
+ libsrcdir="$$s/readline";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-readline maybe-all-readline
+maybe-all-readline:
+all-readline: configure-readline
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd readline && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-readline maybe-check-readline
+maybe-check-readline:
+
+check-readline:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd readline && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-readline maybe-install-readline
+maybe-install-readline:
+
+install-readline: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd readline && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-release maybe-configure-release
+maybe-configure-release:
+configure-release:
+ @test ! -f release/Makefile || exit 0; \
+ [ -d release ] || mkdir release; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in release; \
+ cd release || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/release"; \
+ libsrcdir="$$s/release";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/release"; \
+ libsrcdir="$$s/release";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-release maybe-all-release
+maybe-all-release:
+all-release: configure-release
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd release && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-release maybe-check-release
+maybe-check-release:
+
+check-release:
+
+
+.PHONY: install-release maybe-install-release
+maybe-install-release:
+
+install-release:
+
+
+.PHONY: configure-recode maybe-configure-recode
+maybe-configure-recode:
+configure-recode:
+ @test ! -f recode/Makefile || exit 0; \
+ [ -d recode ] || mkdir recode; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in recode; \
+ cd recode || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/recode"; \
+ libsrcdir="$$s/recode";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/recode"; \
+ libsrcdir="$$s/recode";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-recode maybe-all-recode
+maybe-all-recode:
+all-recode: configure-recode
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd recode && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-recode maybe-check-recode
+maybe-check-recode:
+
+check-recode:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd recode && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-recode maybe-install-recode
+maybe-install-recode:
+
+install-recode: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd recode && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-sed maybe-configure-sed
+maybe-configure-sed:
+configure-sed:
+ @test ! -f sed/Makefile || exit 0; \
+ [ -d sed ] || mkdir sed; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in sed; \
+ cd sed || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/sed"; \
+ libsrcdir="$$s/sed";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/sed"; \
+ libsrcdir="$$s/sed";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-sed maybe-all-sed
+maybe-all-sed:
+all-sed: configure-sed
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd sed && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-sed maybe-check-sed
+maybe-check-sed:
+
+check-sed:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd sed && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-sed maybe-install-sed
+maybe-install-sed:
+
+install-sed: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd sed && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-send-pr maybe-configure-send-pr
+maybe-configure-send-pr:
+configure-send-pr:
+ @test ! -f send-pr/Makefile || exit 0; \
+ [ -d send-pr ] || mkdir send-pr; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in send-pr; \
+ cd send-pr || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/send-pr"; \
+ libsrcdir="$$s/send-pr";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/send-pr"; \
+ libsrcdir="$$s/send-pr";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-send-pr maybe-all-send-pr
+maybe-all-send-pr:
+all-send-pr: configure-send-pr
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd send-pr && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-send-pr maybe-check-send-pr
+maybe-check-send-pr:
+
+check-send-pr:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd send-pr && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-send-pr maybe-install-send-pr
+maybe-install-send-pr:
+
+install-send-pr: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd send-pr && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-shellutils maybe-configure-shellutils
+maybe-configure-shellutils:
+configure-shellutils:
+ @test ! -f shellutils/Makefile || exit 0; \
+ [ -d shellutils ] || mkdir shellutils; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in shellutils; \
+ cd shellutils || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/shellutils"; \
+ libsrcdir="$$s/shellutils";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/shellutils"; \
+ libsrcdir="$$s/shellutils";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-shellutils maybe-all-shellutils
+maybe-all-shellutils:
+all-shellutils: configure-shellutils
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd shellutils && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-shellutils maybe-check-shellutils
+maybe-check-shellutils:
+
+check-shellutils:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd shellutils && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-shellutils maybe-install-shellutils
+maybe-install-shellutils:
+
+install-shellutils: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd shellutils && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-sid maybe-configure-sid
+maybe-configure-sid:
+configure-sid:
+ @test ! -f sid/Makefile || exit 0; \
+ [ -d sid ] || mkdir sid; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in sid; \
+ cd sid || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/sid"; \
+ libsrcdir="$$s/sid";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/sid"; \
+ libsrcdir="$$s/sid";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-sid maybe-all-sid
+maybe-all-sid:
+all-sid: configure-sid
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd sid && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-sid maybe-check-sid
+maybe-check-sid:
+
+check-sid:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd sid && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-sid maybe-install-sid
+maybe-install-sid:
+
+install-sid: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd sid && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-sim maybe-configure-sim
+maybe-configure-sim:
+configure-sim:
+ @test ! -f sim/Makefile || exit 0; \
+ [ -d sim ] || mkdir sim; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in sim; \
+ cd sim || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/sim"; \
+ libsrcdir="$$s/sim";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/sim"; \
+ libsrcdir="$$s/sim";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-sim maybe-all-sim
+maybe-all-sim:
+all-sim: configure-sim
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd sim && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-sim maybe-check-sim
+maybe-check-sim:
+
+check-sim:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd sim && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-sim maybe-install-sim
+maybe-install-sim:
+
+install-sim: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd sim && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-tar maybe-configure-tar
+maybe-configure-tar:
+configure-tar:
+ @test ! -f tar/Makefile || exit 0; \
+ [ -d tar ] || mkdir tar; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in tar; \
+ cd tar || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/tar"; \
+ libsrcdir="$$s/tar";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/tar"; \
+ libsrcdir="$$s/tar";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-tar maybe-all-tar
+maybe-all-tar:
+all-tar: configure-tar
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd tar && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-tar maybe-check-tar
+maybe-check-tar:
+
+check-tar:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd tar && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-tar maybe-install-tar
+maybe-install-tar:
+
+install-tar: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd tar && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-texinfo maybe-configure-texinfo
+maybe-configure-texinfo:
+configure-texinfo:
+ @test ! -f texinfo/Makefile || exit 0; \
+ [ -d texinfo ] || mkdir texinfo; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in texinfo; \
+ cd texinfo || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/texinfo"; \
+ libsrcdir="$$s/texinfo";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/texinfo"; \
+ libsrcdir="$$s/texinfo";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-texinfo maybe-all-texinfo
+maybe-all-texinfo:
+all-texinfo: configure-texinfo
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd texinfo && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-texinfo maybe-check-texinfo
+maybe-check-texinfo:
+
+check-texinfo:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd texinfo && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-texinfo maybe-install-texinfo
+maybe-install-texinfo:
+
+install-texinfo:
+
+
+.PHONY: configure-textutils maybe-configure-textutils
+maybe-configure-textutils:
+configure-textutils:
+ @test ! -f textutils/Makefile || exit 0; \
+ [ -d textutils ] || mkdir textutils; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in textutils; \
+ cd textutils || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/textutils"; \
+ libsrcdir="$$s/textutils";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/textutils"; \
+ libsrcdir="$$s/textutils";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-textutils maybe-all-textutils
+maybe-all-textutils:
+all-textutils: configure-textutils
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd textutils && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-textutils maybe-check-textutils
+maybe-check-textutils:
+
+check-textutils:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd textutils && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-textutils maybe-install-textutils
+maybe-install-textutils:
+
+install-textutils: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd textutils && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-time maybe-configure-time
+maybe-configure-time:
+configure-time:
+ @test ! -f time/Makefile || exit 0; \
+ [ -d time ] || mkdir time; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in time; \
+ cd time || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/time"; \
+ libsrcdir="$$s/time";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/time"; \
+ libsrcdir="$$s/time";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-time maybe-all-time
+maybe-all-time:
+all-time: configure-time
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd time && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-time maybe-check-time
+maybe-check-time:
+
+check-time:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd time && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-time maybe-install-time
+maybe-install-time:
+
+install-time: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd time && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-uudecode maybe-configure-uudecode
+maybe-configure-uudecode:
+configure-uudecode:
+ @test ! -f uudecode/Makefile || exit 0; \
+ [ -d uudecode ] || mkdir uudecode; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in uudecode; \
+ cd uudecode || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/uudecode"; \
+ libsrcdir="$$s/uudecode";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/uudecode"; \
+ libsrcdir="$$s/uudecode";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-uudecode maybe-all-uudecode
+maybe-all-uudecode:
+all-uudecode: configure-uudecode
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd uudecode && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-uudecode maybe-check-uudecode
+maybe-check-uudecode:
+
+check-uudecode:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd uudecode && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-uudecode maybe-install-uudecode
+maybe-install-uudecode:
+
+install-uudecode: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd uudecode && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-wdiff maybe-configure-wdiff
+maybe-configure-wdiff:
+configure-wdiff:
+ @test ! -f wdiff/Makefile || exit 0; \
+ [ -d wdiff ] || mkdir wdiff; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in wdiff; \
+ cd wdiff || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/wdiff"; \
+ libsrcdir="$$s/wdiff";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/wdiff"; \
+ libsrcdir="$$s/wdiff";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-wdiff maybe-all-wdiff
+maybe-all-wdiff:
+all-wdiff: configure-wdiff
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd wdiff && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-wdiff maybe-check-wdiff
+maybe-check-wdiff:
+
+check-wdiff:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd wdiff && $(MAKE) $(FLAGS_TO_PASS) check)
+
+
+.PHONY: install-wdiff maybe-install-wdiff
+maybe-install-wdiff:
+
+install-wdiff: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd wdiff && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-zip maybe-configure-zip
+maybe-configure-zip:
+configure-zip:
+ @test ! -f zip/Makefile || exit 0; \
+ [ -d zip ] || mkdir zip; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in zip; \
+ cd zip || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/zip"; \
+ libsrcdir="$$s/zip";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/zip"; \
+ libsrcdir="$$s/zip";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-zip maybe-all-zip
+maybe-all-zip:
+all-zip: configure-zip
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd zip && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-zip maybe-check-zip
+maybe-check-zip:
+
+# This module is only tested in a native toolchain.
+check-zip:
+ @if [ '$(host)' = '$(target)' ] ; then \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
$(SET_LIB_PATH) \
- (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) install); \
- else \
- true; \
+ (cd zip && $(MAKE) $(FLAGS_TO_PASS) check); \
fi
-# This rule is used to configure the modules which are built with the
-# target tools.
-.PHONY: $(CONFIGURE_TARGET_MODULES)
-$(CONFIGURE_TARGET_MODULES):
- @dir=`echo $@ | sed -e 's/configure-target-//'`; \
- if [ -d $(TARGET_SUBDIR)/$${dir} ]; then \
- r=`${PWD}`; export r; \
- $(CC_FOR_TARGET) --print-multi-lib > $(TARGET_SUBDIR)/$${dir}/tmpmulti.out 2> /dev/null; \
- if [ -s $(TARGET_SUBDIR)/$${dir}/tmpmulti.out ]; then \
- if [ -f $(TARGET_SUBDIR)/$${dir}/multilib.out ]; then \
- if cmp $(TARGET_SUBDIR)/$${dir}/multilib.out $(TARGET_SUBDIR)/$${dir}/tmpmulti.out > /dev/null; then \
- rm -f $(TARGET_SUBDIR)/$${dir}/tmpmulti.out; \
+
+.PHONY: install-zip maybe-install-zip
+maybe-install-zip:
+
+install-zip: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd zip && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-zlib maybe-configure-zlib
+maybe-configure-zlib:
+configure-zlib:
+ @test ! -f zlib/Makefile || exit 0; \
+ [ -d zlib ] || mkdir zlib; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in zlib; \
+ cd zlib || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/zlib"; \
+ libsrcdir="$$s/zlib";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/zlib"; \
+ libsrcdir="$$s/zlib";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-zlib maybe-all-zlib
+maybe-all-zlib:
+all-zlib: configure-zlib
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd zlib && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-zlib maybe-check-zlib
+maybe-check-zlib:
+
+check-zlib:
+
+
+.PHONY: install-zlib maybe-install-zlib
+maybe-install-zlib:
+
+install-zlib:
+
+
+.PHONY: configure-gdb maybe-configure-gdb
+maybe-configure-gdb:
+configure-gdb:
+ @test ! -f gdb/Makefile || exit 0; \
+ [ -d gdb ] || mkdir gdb; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in gdb; \
+ cd gdb || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/gdb"; \
+ libsrcdir="$$s/gdb";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/gdb"; \
+ libsrcdir="$$s/gdb";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-gdb maybe-all-gdb
+maybe-all-gdb:
+all-gdb: configure-gdb
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gdb && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) all)
+
+.PHONY: check-gdb maybe-check-gdb
+maybe-check-gdb:
+
+check-gdb:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gdb && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) check)
+
+
+.PHONY: install-gdb maybe-install-gdb
+maybe-install-gdb:
+
+install-gdb: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gdb && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-expect maybe-configure-expect
+maybe-configure-expect:
+configure-expect:
+ @test ! -f expect/Makefile || exit 0; \
+ [ -d expect ] || mkdir expect; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in expect; \
+ cd expect || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/expect"; \
+ libsrcdir="$$s/expect";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/expect"; \
+ libsrcdir="$$s/expect";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-expect maybe-all-expect
+maybe-all-expect:
+all-expect: configure-expect
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd expect && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) all)
+
+.PHONY: check-expect maybe-check-expect
+maybe-check-expect:
+
+check-expect:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd expect && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) check)
+
+
+.PHONY: install-expect maybe-install-expect
+maybe-install-expect:
+
+install-expect: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd expect && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-guile maybe-configure-guile
+maybe-configure-guile:
+configure-guile:
+ @test ! -f guile/Makefile || exit 0; \
+ [ -d guile ] || mkdir guile; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in guile; \
+ cd guile || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/guile"; \
+ libsrcdir="$$s/guile";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/guile"; \
+ libsrcdir="$$s/guile";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-guile maybe-all-guile
+maybe-all-guile:
+all-guile: configure-guile
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd guile && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) all)
+
+.PHONY: check-guile maybe-check-guile
+maybe-check-guile:
+
+check-guile:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd guile && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) check)
+
+
+.PHONY: install-guile maybe-install-guile
+maybe-install-guile:
+
+install-guile: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd guile && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-tk maybe-configure-tk
+maybe-configure-tk:
+configure-tk:
+ @test ! -f tk/Makefile || exit 0; \
+ [ -d tk ] || mkdir tk; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in tk; \
+ cd tk || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/tk"; \
+ libsrcdir="$$s/tk";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/tk"; \
+ libsrcdir="$$s/tk";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-tk maybe-all-tk
+maybe-all-tk:
+all-tk: configure-tk
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd tk && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) all)
+
+.PHONY: check-tk maybe-check-tk
+maybe-check-tk:
+
+check-tk:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd tk && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) check)
+
+
+.PHONY: install-tk maybe-install-tk
+maybe-install-tk:
+
+install-tk: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd tk && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-tix maybe-configure-tix
+maybe-configure-tix:
+configure-tix:
+ @test ! -f tix/Makefile || exit 0; \
+ [ -d tix ] || mkdir tix; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in tix; \
+ cd tix || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/tix"; \
+ libsrcdir="$$s/tix";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/tix"; \
+ libsrcdir="$$s/tix";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-tix maybe-all-tix
+maybe-all-tix:
+all-tix: configure-tix
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd tix && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) all)
+
+.PHONY: check-tix maybe-check-tix
+maybe-check-tix:
+
+check-tix:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd tix && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) check)
+
+
+.PHONY: install-tix maybe-install-tix
+maybe-install-tix:
+
+install-tix: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd tix && $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-libtermcap maybe-configure-libtermcap
+maybe-configure-libtermcap:
+configure-libtermcap:
+ @test ! -f libtermcap/Makefile || exit 0; \
+ [ -d libtermcap ] || mkdir libtermcap; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in libtermcap; \
+ cd libtermcap || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/libtermcap"; \
+ libsrcdir="$$s/libtermcap";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/libtermcap"; \
+ libsrcdir="$$s/libtermcap";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-libtermcap maybe-all-libtermcap
+maybe-all-libtermcap:
+all-libtermcap: configure-libtermcap
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd libtermcap && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-libtermcap maybe-check-libtermcap
+maybe-check-libtermcap:
+
+check-libtermcap:
+
+
+.PHONY: install-libtermcap maybe-install-libtermcap
+maybe-install-libtermcap:
+
+install-libtermcap: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd libtermcap && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-utils maybe-configure-utils
+maybe-configure-utils:
+configure-utils:
+ @test ! -f utils/Makefile || exit 0; \
+ [ -d utils ] || mkdir utils; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in utils; \
+ cd utils || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/utils"; \
+ libsrcdir="$$s/utils";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/utils"; \
+ libsrcdir="$$s/utils";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-utils maybe-all-utils
+maybe-all-utils:
+all-utils: configure-utils
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd utils && $(MAKE) $(FLAGS_TO_PASS) all)
+
+.PHONY: check-utils maybe-check-utils
+maybe-check-utils:
+
+check-utils:
+
+
+.PHONY: install-utils maybe-install-utils
+maybe-install-utils:
+
+install-utils: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd utils && $(MAKE) $(FLAGS_TO_PASS) install)
+
+
+
+# ---------------------------------------
+# Modules which run on the target machine
+# ---------------------------------------
+
+.PHONY: configure-target-libstdc++-v3 maybe-configure-target-libstdc++-v3
+maybe-configure-target-libstdc++-v3:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/libstdc++-v3/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libstdc++-v3 ; \
+ rm -f $(TARGET_SUBDIR)/libstdc++-v3/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/libstdc++-v3/multilib.out
+
+configure-target-libstdc++-v3: $(TARGET_SUBDIR)/libstdc++-v3/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/libstdc++-v3/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libstdc++-v3 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
+ CXX_FOR_TARGET="$(RAW_CXX_FOR_TARGET)"; export CXX_FOR_TARGET; \
+ CXX="$(RAW_CXX_FOR_TARGET)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/libstdc++-v3; \
+ cd "$(TARGET_SUBDIR)/libstdc++-v3" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/libstdc++-v3"; \
+ libsrcdir="$$s/libstdc++-v3"; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-target-libstdc++-v3 maybe-all-target-libstdc++-v3
+maybe-all-target-libstdc++-v3:
+all-target-libstdc++-v3: configure-target-libstdc++-v3
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libstdc++-v3 && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) 'CXX=$$(RAW_CXX_FOR_TARGET)' 'CXX_FOR_TARGET=$$(RAW_CXX_FOR_TARGET)' all)
+
+.PHONY: check-target-libstdc++-v3 maybe-check-target-libstdc++-v3
+maybe-check-target-libstdc++-v3:
+
+check-target-libstdc++-v3:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libstdc++-v3 && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) 'CXX=$$(RAW_CXX_FOR_TARGET)' 'CXX_FOR_TARGET=$$(RAW_CXX_FOR_TARGET)' check)
+
+
+.PHONY: install-target-libstdc++-v3 maybe-install-target-libstdc++-v3
+maybe-install-target-libstdc++-v3:
+
+install-target-libstdc++-v3: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libstdc++-v3 && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-target-newlib maybe-configure-target-newlib
+maybe-configure-target-newlib:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/newlib/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/newlib ; \
+ rm -f $(TARGET_SUBDIR)/newlib/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/newlib/multilib.out
+
+configure-target-newlib: $(TARGET_SUBDIR)/newlib/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/newlib/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/newlib ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
+ CXX="$(CXX_FOR_TARGET)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/newlib; \
+ cd "$(TARGET_SUBDIR)/newlib" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/newlib"; \
+ libsrcdir="$$s/newlib"; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-target-newlib maybe-all-target-newlib
+maybe-all-target-newlib:
+all-target-newlib: configure-target-newlib
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/newlib && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) all)
+
+.PHONY: check-target-newlib maybe-check-target-newlib
+maybe-check-target-newlib:
+
+check-target-newlib:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/newlib && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) check)
+
+
+.PHONY: install-target-newlib maybe-install-target-newlib
+maybe-install-target-newlib:
+
+install-target-newlib: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/newlib && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-target-libf2c maybe-configure-target-libf2c
+maybe-configure-target-libf2c:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/libf2c/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libf2c ; \
+ rm -f $(TARGET_SUBDIR)/libf2c/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/libf2c/multilib.out
+
+configure-target-libf2c: $(TARGET_SUBDIR)/libf2c/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/libf2c/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libf2c ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
+ CXX="$(CXX_FOR_TARGET)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/libf2c; \
+ cd "$(TARGET_SUBDIR)/libf2c" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/libf2c"; \
+ libsrcdir="$$s/libf2c"; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-target-libf2c maybe-all-target-libf2c
+maybe-all-target-libf2c:
+all-target-libf2c: configure-target-libf2c
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libf2c && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) all)
+
+.PHONY: check-target-libf2c maybe-check-target-libf2c
+maybe-check-target-libf2c:
+
+check-target-libf2c:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libf2c && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) check)
+
+
+.PHONY: install-target-libf2c maybe-install-target-libf2c
+maybe-install-target-libf2c:
+
+install-target-libf2c: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libf2c && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-target-libobjc maybe-configure-target-libobjc
+maybe-configure-target-libobjc:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/libobjc/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libobjc ; \
+ rm -f $(TARGET_SUBDIR)/libobjc/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/libobjc/multilib.out
+
+configure-target-libobjc: $(TARGET_SUBDIR)/libobjc/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/libobjc/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libobjc ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
+ CXX="$(CXX_FOR_TARGET)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/libobjc; \
+ cd "$(TARGET_SUBDIR)/libobjc" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/libobjc"; \
+ libsrcdir="$$s/libobjc"; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-target-libobjc maybe-all-target-libobjc
+maybe-all-target-libobjc:
+all-target-libobjc: configure-target-libobjc
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libobjc && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) all)
+
+.PHONY: check-target-libobjc maybe-check-target-libobjc
+maybe-check-target-libobjc:
+
+check-target-libobjc:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libobjc && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) check)
+
+
+.PHONY: install-target-libobjc maybe-install-target-libobjc
+maybe-install-target-libobjc:
+
+install-target-libobjc: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libobjc && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-target-libtermcap maybe-configure-target-libtermcap
+maybe-configure-target-libtermcap:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/libtermcap/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libtermcap ; \
+ rm -f $(TARGET_SUBDIR)/libtermcap/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/libtermcap/multilib.out
+
+configure-target-libtermcap: $(TARGET_SUBDIR)/libtermcap/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/libtermcap/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libtermcap ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
+ CXX="$(CXX_FOR_TARGET)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/libtermcap; \
+ cd "$(TARGET_SUBDIR)/libtermcap" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \
+ if [ "$(srcdir)" = "." ] ; then \
+ if [ "$(TARGET_SUBDIR)" != "." ] ; then \
+ if $(SHELL) $$s/symlink-tree $${topdir}/libtermcap "no-such-file" ; then \
+ if [ -f Makefile ]; then \
+ if $(MAKE) distclean; then \
+ true; \
+ else \
+ exit 1; \
+ fi; \
else \
- echo "Multilibs changed for $${dir}, reconfiguring"; \
- rm -f $(TARGET_SUBDIR)/$${dir}/multilib.out $(TARGET_SUBDIR)/$${dir}/Makefile; \
- mv $(TARGET_SUBDIR)/$${dir}/tmpmulti.out $(TARGET_SUBDIR)/$${dir}/multilib.out; \
+ true; \
fi; \
else \
- mv $(TARGET_SUBDIR)/$${dir}/tmpmulti.out $(TARGET_SUBDIR)/$${dir}/multilib.out; \
+ exit 1; \
fi; \
+ else \
+ true; \
fi; \
- fi; exit 0 # break command into two pieces
- @dir=`echo $@ | sed -e 's/configure-target-//'`; \
- if [ ! -d $(TARGET_SUBDIR) ]; then \
- true; \
- elif [ -f $(TARGET_SUBDIR)/$${dir}/Makefile ] ; then \
- true; \
- elif echo " $(TARGET_CONFIGDIRS) " | grep " $${dir} " >/dev/null 2>&1; then \
- if [ -d $(srcdir)/$${dir} ]; then \
- [ -d $(TARGET_SUBDIR)/$${dir} ] || mkdir $(TARGET_SUBDIR)/$${dir};\
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
- $(SET_LIB_PATH) \
- AR="$(AR_FOR_TARGET)"; export AR; \
- AS="$(AS_FOR_TARGET)"; export AS; \
- CC="$(CC_FOR_TARGET)"; export CC; \
- CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
- CXX="$(CXX_FOR_TARGET)"; export CXX; \
- CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
- GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
- DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
- LD="$(LD_FOR_TARGET)"; export LD; \
- LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
- NM="$(NM_FOR_TARGET)"; export NM; \
- RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
- WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
- echo Configuring in $(TARGET_SUBDIR)/$${dir}; \
- cd "$(TARGET_SUBDIR)/$${dir}" || exit 1; \
- case $(srcdir) in \
- /* | [A-Za-z]:[\\/]*) \
- topdir=$(srcdir) ;; \
- *) \
- case "$(TARGET_SUBDIR)" in \
+ srcdiroption="--srcdir=."; \
+ libsrcdir="."; \
+ else \
+ srcdiroption="--srcdir=$${topdir}/libtermcap"; \
+ libsrcdir="$$s/libtermcap"; \
+ fi; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-target-libtermcap maybe-all-target-libtermcap
+maybe-all-target-libtermcap:
+all-target-libtermcap: configure-target-libtermcap
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libtermcap && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) all)
+
+.PHONY: check-target-libtermcap maybe-check-target-libtermcap
+maybe-check-target-libtermcap:
+
+# Dummy target for uncheckable module.
+check-target-libtermcap:
+
+
+.PHONY: install-target-libtermcap maybe-install-target-libtermcap
+maybe-install-target-libtermcap:
+
+install-target-libtermcap: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libtermcap && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-target-winsup maybe-configure-target-winsup
+maybe-configure-target-winsup:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/winsup/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/winsup ; \
+ rm -f $(TARGET_SUBDIR)/winsup/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/winsup/multilib.out
+
+configure-target-winsup: $(TARGET_SUBDIR)/winsup/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/winsup/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/winsup ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
+ CXX="$(CXX_FOR_TARGET)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/winsup; \
+ cd "$(TARGET_SUBDIR)/winsup" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/winsup"; \
+ libsrcdir="$$s/winsup"; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-target-winsup maybe-all-target-winsup
+maybe-all-target-winsup:
+all-target-winsup: configure-target-winsup
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/winsup && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) all)
+
+.PHONY: check-target-winsup maybe-check-target-winsup
+maybe-check-target-winsup:
+
+check-target-winsup:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/winsup && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) check)
+
+
+.PHONY: install-target-winsup maybe-install-target-winsup
+maybe-install-target-winsup:
+
+install-target-winsup: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/winsup && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-target-libgloss maybe-configure-target-libgloss
+maybe-configure-target-libgloss:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/libgloss/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libgloss ; \
+ rm -f $(TARGET_SUBDIR)/libgloss/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/libgloss/multilib.out
+
+configure-target-libgloss: $(TARGET_SUBDIR)/libgloss/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/libgloss/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libgloss ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
+ CXX="$(CXX_FOR_TARGET)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/libgloss; \
+ cd "$(TARGET_SUBDIR)/libgloss" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/libgloss"; \
+ libsrcdir="$$s/libgloss"; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-target-libgloss maybe-all-target-libgloss
+maybe-all-target-libgloss:
+all-target-libgloss: configure-target-libgloss
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libgloss && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) all)
+
+.PHONY: check-target-libgloss maybe-check-target-libgloss
+maybe-check-target-libgloss:
+
+# Dummy target for uncheckable module.
+check-target-libgloss:
+
+
+.PHONY: install-target-libgloss maybe-install-target-libgloss
+maybe-install-target-libgloss:
+
+install-target-libgloss: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libgloss && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-target-libiberty maybe-configure-target-libiberty
+maybe-configure-target-libiberty:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/libiberty/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libiberty ; \
+ rm -f $(TARGET_SUBDIR)/libiberty/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/libiberty/multilib.out
+
+configure-target-libiberty: $(TARGET_SUBDIR)/libiberty/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/libiberty/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libiberty ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
+ CXX="$(CXX_FOR_TARGET)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/libiberty; \
+ cd "$(TARGET_SUBDIR)/libiberty" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/libiberty"; \
+ libsrcdir="$$s/libiberty"; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-target-libiberty maybe-all-target-libiberty
+maybe-all-target-libiberty:
+all-target-libiberty: configure-target-libiberty
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libiberty && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) all)
+
+.PHONY: check-target-libiberty maybe-check-target-libiberty
+maybe-check-target-libiberty:
+
+check-target-libiberty:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libiberty && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) check)
+
+
+.PHONY: install-target-libiberty maybe-install-target-libiberty
+maybe-install-target-libiberty:
+
+install-target-libiberty: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libiberty && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-target-gperf maybe-configure-target-gperf
+maybe-configure-target-gperf:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/gperf/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/gperf ; \
+ rm -f $(TARGET_SUBDIR)/gperf/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/gperf/multilib.out
+
+configure-target-gperf: $(TARGET_SUBDIR)/gperf/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/gperf/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/gperf ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
+ CXX="$(CXX_FOR_TARGET)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/gperf; \
+ cd "$(TARGET_SUBDIR)/gperf" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/gperf"; \
+ libsrcdir="$$s/gperf"; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-target-gperf maybe-all-target-gperf
+maybe-all-target-gperf:
+all-target-gperf: configure-target-gperf
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/gperf && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) all)
+
+.PHONY: check-target-gperf maybe-check-target-gperf
+maybe-check-target-gperf:
+
+check-target-gperf:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/gperf && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) check)
+
+
+.PHONY: install-target-gperf maybe-install-target-gperf
+maybe-install-target-gperf:
+
+install-target-gperf: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/gperf && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-target-examples maybe-configure-target-examples
+maybe-configure-target-examples:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/examples/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/examples ; \
+ rm -f $(TARGET_SUBDIR)/examples/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/examples/multilib.out
+
+configure-target-examples: $(TARGET_SUBDIR)/examples/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/examples/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/examples ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
+ CXX="$(CXX_FOR_TARGET)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/examples; \
+ cd "$(TARGET_SUBDIR)/examples" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/examples"; \
+ libsrcdir="$$s/examples"; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-target-examples maybe-all-target-examples
+maybe-all-target-examples:
+all-target-examples: configure-target-examples
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/examples && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) all)
+
+.PHONY: check-target-examples maybe-check-target-examples
+maybe-check-target-examples:
+
+# Dummy target for uncheckable module.
+check-target-examples:
+
+
+.PHONY: install-target-examples maybe-install-target-examples
+maybe-install-target-examples:
+
+# Dummy target for uninstallable.
+install-target-examples:
+
+
+.PHONY: configure-target-libffi maybe-configure-target-libffi
+maybe-configure-target-libffi:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/libffi/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libffi ; \
+ rm -f $(TARGET_SUBDIR)/libffi/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/libffi/multilib.out
+
+configure-target-libffi: $(TARGET_SUBDIR)/libffi/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/libffi/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libffi ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
+ CXX="$(CXX_FOR_TARGET)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/libffi; \
+ cd "$(TARGET_SUBDIR)/libffi" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
.) topdir="../$(srcdir)" ;; \
*) topdir="../../$(srcdir)" ;; \
- esac ;; \
- esac; \
- if [ "$(srcdir)" = "." ] ; then \
- if [ "$(TARGET_SUBDIR)" != "." ] ; then \
- if $(SHELL) $$s/symlink-tree $${topdir}/$${dir} "no-such-file" ; then \
- if [ -f Makefile ]; then \
- if $(MAKE) distclean; then \
- true; \
- else \
- exit 1; \
- fi; \
- else \
- true; \
- fi; \
- else \
- exit 1; \
- fi; \
+ esac ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/libffi"; \
+ libsrcdir="$$s/libffi"; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-target-libffi maybe-all-target-libffi
+maybe-all-target-libffi:
+all-target-libffi: configure-target-libffi
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libffi && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) all)
+
+.PHONY: check-target-libffi maybe-check-target-libffi
+maybe-check-target-libffi:
+
+check-target-libffi:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libffi && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) check)
+
+
+.PHONY: install-target-libffi maybe-install-target-libffi
+maybe-install-target-libffi:
+
+install-target-libffi: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libffi && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-target-libjava maybe-configure-target-libjava
+maybe-configure-target-libjava:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/libjava/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libjava ; \
+ rm -f $(TARGET_SUBDIR)/libjava/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/libjava/multilib.out
+
+configure-target-libjava: $(TARGET_SUBDIR)/libjava/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/libjava/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libjava ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
+ CXX_FOR_TARGET="$(RAW_CXX_FOR_TARGET)"; export CXX_FOR_TARGET; \
+ CXX="$(RAW_CXX_FOR_TARGET)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/libjava; \
+ cd "$(TARGET_SUBDIR)/libjava" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/libjava"; \
+ libsrcdir="$$s/libjava"; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-target-libjava maybe-all-target-libjava
+maybe-all-target-libjava:
+all-target-libjava: configure-target-libjava
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libjava && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) 'CXX=$$(RAW_CXX_FOR_TARGET)' 'CXX_FOR_TARGET=$$(RAW_CXX_FOR_TARGET)' all)
+
+.PHONY: check-target-libjava maybe-check-target-libjava
+maybe-check-target-libjava:
+
+check-target-libjava:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libjava && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) 'CXX=$$(RAW_CXX_FOR_TARGET)' 'CXX_FOR_TARGET=$$(RAW_CXX_FOR_TARGET)' check)
+
+
+.PHONY: install-target-libjava maybe-install-target-libjava
+maybe-install-target-libjava:
+
+install-target-libjava: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libjava && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-target-zlib maybe-configure-target-zlib
+maybe-configure-target-zlib:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/zlib/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/zlib ; \
+ rm -f $(TARGET_SUBDIR)/zlib/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/zlib/multilib.out
+
+configure-target-zlib: $(TARGET_SUBDIR)/zlib/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/zlib/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/zlib ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
+ CXX="$(CXX_FOR_TARGET)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/zlib; \
+ cd "$(TARGET_SUBDIR)/zlib" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \
+ if [ "$(srcdir)" = "." ] ; then \
+ if [ "$(TARGET_SUBDIR)" != "." ] ; then \
+ if $(SHELL) $$s/symlink-tree $${topdir}/zlib "no-such-file" ; then \
+ if [ -f Makefile ]; then \
+ if $(MAKE) distclean; then \
+ true; \
+ else \
+ exit 1; \
+ fi; \
else \
- true; \
+ true; \
fi; \
- srcdiroption="--srcdir=."; \
- libsrcdir="."; \
else \
- srcdiroption="--srcdir=$${topdir}/$${dir}"; \
- libsrcdir="$$s/$${dir}"; \
- fi; \
- if [ -f $${libsrcdir}/configure ] ; then \
- rm -f no-such-file skip-this-dir; \
- CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
- $(TARGET_CONFIGARGS) $${srcdiroption} \
- --with-target-subdir="$(TARGET_SUBDIR)"; \
- else \
- rm -f no-such-file skip-this-dir; \
- CONFIG_SITE=no-such-file $(SHELL) $$s/configure \
- $(TARGET_CONFIGARGS) $${srcdiroption} \
- --with-target-subdir="$(TARGET_SUBDIR)"; \
- fi || exit 1; \
- if [ -f skip-this-dir ] ; then \
- sh skip-this-dir; \
- rm -f skip-this-dir; \
- cd ..; rmdir $${dir} || true; \
- else \
- true; \
+ exit 1; \
fi; \
else \
true; \
fi; \
+ srcdiroption="--srcdir=."; \
+ libsrcdir="."; \
else \
- true; \
- fi
+ srcdiroption="--srcdir=$${topdir}/zlib"; \
+ libsrcdir="$$s/zlib"; \
+ fi; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
-# This rule is used to build the modules which use TARGET_FLAGS_TO_PASS.
-# To build a target all-X means to cd to X and make all.
-.PHONY: $(ALL_TARGET_MODULES)
-$(ALL_TARGET_MODULES):
- @dir=`echo $@ | sed -e 's/all-target-//'`; \
- if [ -f $(TARGET_SUBDIR)/$${dir}/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
- $(SET_LIB_PATH) \
- (cd $(TARGET_SUBDIR)/$${dir}; \
- $(MAKE) $(TARGET_FLAGS_TO_PASS) all); \
- else \
- true; \
- fi
+.PHONY: all-target-zlib maybe-all-target-zlib
+maybe-all-target-zlib:
+all-target-zlib: configure-target-zlib
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/zlib && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) all)
-# This rule is used to check the modules which use TARGET_FLAGS_TO_PASS.
-# To build a target install-X means to cd to X and make install.
-.PHONY: $(CHECK_TARGET_MODULES)
-$(CHECK_TARGET_MODULES):
- @dir=`echo $@ | sed -e 's/check-target-//'`; \
- if [ -f $(TARGET_SUBDIR)/$${dir}/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
- $(SET_LIB_PATH) \
- (cd $(TARGET_SUBDIR)/$${dir}; \
- $(MAKE) $(TARGET_FLAGS_TO_PASS) check);\
- else \
- true; \
- fi
+.PHONY: check-target-zlib maybe-check-target-zlib
+maybe-check-target-zlib:
-# This rule is used to install the modules which use
-# TARGET_FLAGS_TO_PASS. To build a target install-X means to cd to X
-# and make install.
-.PHONY: $(INSTALL_TARGET_MODULES)
-$(INSTALL_TARGET_MODULES): installdirs
- @dir=`echo $@ | sed -e 's/install-target-//'`; \
- if [ -f $(TARGET_SUBDIR)/$${dir}/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
- $(SET_LIB_PATH) \
- (cd $(TARGET_SUBDIR)/$${dir}; \
- $(MAKE) $(TARGET_FLAGS_TO_PASS) install); \
- else \
- true; \
- fi
+check-target-zlib:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/zlib && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) check)
-# This rule is used to build the modules which use X11_FLAGS_TO_PASS.
-# To build a target all-X means to cd to X and make all.
-.PHONY: $(ALL_X11_MODULES)
-$(ALL_X11_MODULES):
- @dir=`echo $@ | sed -e 's/all-//'`; \
- if [ -f ./$${dir}/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
- $(SET_LIB_PATH) \
- (cd $${dir}; \
- $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) all); \
- else \
- true; \
- fi
-# This rule is used to check the modules which use X11_FLAGS_TO_PASS.
-# To build a target check-X means to cd to X and make all.
-.PHONY: $(CHECK_X11_MODULES)
-$(CHECK_X11_MODULES):
- @dir=`echo $@ | sed -e 's/check-//'`; \
- if [ -f ./$${dir}/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
- $(SET_LIB_PATH) \
- (cd $${dir}; \
- $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) check); \
- else \
- true; \
- fi
+.PHONY: install-target-zlib maybe-install-target-zlib
+maybe-install-target-zlib:
-# This rule is used to install the modules which use X11_FLAGS_TO_PASS.
-# To build a target install-X means to cd to X and make install.
-.PHONY: $(INSTALL_X11_MODULES)
-$(INSTALL_X11_MODULES): installdirs
- @dir=`echo $@ | sed -e 's/install-//'`; \
- if [ -f ./$${dir}/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
- $(SET_LIB_PATH) \
- (cd $${dir}; \
- $(MAKE) $(FLAGS_TO_PASS) $(X11_FLAGS_TO_PASS) install); \
- else \
- true; \
- fi
+install-target-zlib: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/zlib && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-target-boehm-gc maybe-configure-target-boehm-gc
+maybe-configure-target-boehm-gc:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/boehm-gc/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/boehm-gc ; \
+ rm -f $(TARGET_SUBDIR)/boehm-gc/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/boehm-gc/multilib.out
+
+configure-target-boehm-gc: $(TARGET_SUBDIR)/boehm-gc/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/boehm-gc/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/boehm-gc ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
+ CXX="$(CXX_FOR_TARGET)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/boehm-gc; \
+ cd "$(TARGET_SUBDIR)/boehm-gc" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/boehm-gc"; \
+ libsrcdir="$$s/boehm-gc"; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-target-boehm-gc maybe-all-target-boehm-gc
+maybe-all-target-boehm-gc:
+all-target-boehm-gc: configure-target-boehm-gc
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/boehm-gc && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) all)
+
+.PHONY: check-target-boehm-gc maybe-check-target-boehm-gc
+maybe-check-target-boehm-gc:
+
+check-target-boehm-gc:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/boehm-gc && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) check)
+
+
+.PHONY: install-target-boehm-gc maybe-install-target-boehm-gc
+maybe-install-target-boehm-gc:
+
+install-target-boehm-gc: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/boehm-gc && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-target-qthreads maybe-configure-target-qthreads
+maybe-configure-target-qthreads:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/qthreads/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/qthreads ; \
+ rm -f $(TARGET_SUBDIR)/qthreads/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/qthreads/multilib.out
+
+configure-target-qthreads: $(TARGET_SUBDIR)/qthreads/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/qthreads/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/qthreads ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
+ CXX="$(CXX_FOR_TARGET)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/qthreads; \
+ cd "$(TARGET_SUBDIR)/qthreads" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/qthreads"; \
+ libsrcdir="$$s/qthreads"; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-target-qthreads maybe-all-target-qthreads
+maybe-all-target-qthreads:
+all-target-qthreads: configure-target-qthreads
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/qthreads && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) all)
+
+.PHONY: check-target-qthreads maybe-check-target-qthreads
+maybe-check-target-qthreads:
+
+check-target-qthreads:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/qthreads && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) check)
+
+
+.PHONY: install-target-qthreads maybe-install-target-qthreads
+maybe-install-target-qthreads:
+
+install-target-qthreads: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/qthreads && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-target-rda maybe-configure-target-rda
+maybe-configure-target-rda:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/rda/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/rda ; \
+ rm -f $(TARGET_SUBDIR)/rda/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/rda/multilib.out
+
+configure-target-rda: $(TARGET_SUBDIR)/rda/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/rda/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/rda ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
+ CXX="$(CXX_FOR_TARGET)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/rda; \
+ cd "$(TARGET_SUBDIR)/rda" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/rda"; \
+ libsrcdir="$$s/rda"; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-target-rda maybe-all-target-rda
+maybe-all-target-rda:
+all-target-rda: configure-target-rda
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/rda && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) all)
+
+.PHONY: check-target-rda maybe-check-target-rda
+maybe-check-target-rda:
+
+check-target-rda:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/rda && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) check)
+
+
+.PHONY: install-target-rda maybe-install-target-rda
+maybe-install-target-rda:
+
+install-target-rda: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/rda && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) install)
+
+
+.PHONY: configure-target-libada maybe-configure-target-libada
+maybe-configure-target-libada:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/libada/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libada ; \
+ rm -f $(TARGET_SUBDIR)/libada/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/libada/multilib.out
+
+configure-target-libada: $(TARGET_SUBDIR)/libada/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/libada/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/libada ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \
+ CXX="$(CXX_FOR_TARGET)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/libada; \
+ cd "$(TARGET_SUBDIR)/libada" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \
+ srcdiroption="--srcdir=$${topdir}/libada"; \
+ libsrcdir="$$s/libada"; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-target-libada maybe-all-target-libada
+maybe-all-target-libada:
+all-target-libada: configure-target-libada
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libada && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) all)
+
+.PHONY: check-target-libada maybe-check-target-libada
+maybe-check-target-libada:
+
+check-target-libada:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libada && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) check)
+
+
+.PHONY: install-target-libada maybe-install-target-libada
+maybe-install-target-libada:
+
+install-target-libada: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/libada && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) install)
+
+
+
+# ----------
+# GCC module
+# ----------
+
+# Unfortunately, while gcc _should_ be a host module,
+# libgcc is a target module, and gen* programs are
+# build modules. So GCC is a sort of hybrid.
# gcc is the only module which uses GCC_FLAGS_TO_PASS.
-.PHONY: all-gcc
-all-gcc:
- @if [ -f ./gcc/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
+# Don't use shared host config.cache, as it will confuse later
+# directories; GCC wants slightly different values for some
+# precious variables. *sigh*
+.PHONY: configure-gcc maybe-configure-gcc
+maybe-configure-gcc:
+configure-gcc:
+ @test ! -f gcc/Makefile || exit 0; \
+ [ -d gcc ] || mkdir gcc; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ TOPLEVEL_CONFIGURE_ARGUMENTS="$(TOPLEVEL_CONFIGURE_ARGUMENTS)"; export TOPLEVEL_CONFIGURE_ARGUMENTS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in gcc; \
+ cd gcc || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/gcc"; \
+ libsrcdir="$$s/gcc";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/gcc"; \
+ libsrcdir="$$s/gcc";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+# Don't 'make all' in gcc if it's already been made by 'bootstrap'; that
+# causes trouble. This wart will be fixed eventually by moving
+# the bootstrap behavior to this file.
+.PHONY: all-gcc maybe-all-gcc
+maybe-all-gcc:
+all-gcc: configure-gcc
+ @if [ -f gcc/stage_last ] ; then \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
$(SET_LIB_PATH) \
- (cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) all); \
+ (cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) quickstrap); \
else \
- true; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) all); \
fi
# Building GCC uses some tools for rebuilding "source" files
@@ -1541,543 +23688,293 @@ all-gcc:
# In theory, on an SMP all those dependencies can be resolved
# in parallel.
#
-.PHONY: bootstrap bootstrap-lean bootstrap2 bootstrap2-lean bootstrap3 bootstrap3-lean bootstrap4 bootstrap4-lean
-bootstrap bootstrap-lean bootstrap2 bootstrap2-lean bootstrap3 bootstrap3-lean bootstrap4 bootstrap4-lean: all-bootstrap
- @r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
+GCC_STRAP_TARGETS = bootstrap bootstrap-lean bootstrap2 bootstrap2-lean bootstrap3 bootstrap3-lean bootstrap4 bootstrap4-lean bubblestrap quickstrap cleanstrap restrap
+.PHONY: $(GCC_STRAP_TARGETS)
+$(GCC_STRAP_TARGETS): all-bootstrap configure-gcc
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
$(SET_LIB_PATH) \
echo "Bootstrapping the compiler"; \
cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) $@
- @r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
case "$@" in \
*bootstrap4-lean ) \
- msg="Comparing stage3 and stage4 of the compiler"; \
- compare=compare3-lean ;; \
- *bootstrap4 ) msg="Comparing stage3 and stage4 of the compiler"; \
- compare=compare3 ;; \
- *-lean ) msg="Comparing stage2 and stage3 of the compiler"; \
- compare=compare-lean ;; \
- * ) msg="Comparing stage2 and stage3 of the compiler"; \
- compare=compare ;; \
+ msg="Comparing stage3 and stage4 of the compiler"; \
+ compare=compare3-lean ;; \
+ *bootstrap4 ) \
+ msg="Comparing stage3 and stage4 of the compiler"; \
+ compare=compare3 ;; \
+ *-lean ) \
+ msg="Comparing stage2 and stage3 of the compiler"; \
+ compare=compare-lean ;; \
+ * ) \
+ msg="Comparing stage2 and stage3 of the compiler"; \
+ compare=compare ;; \
esac; \
$(SET_LIB_PATH) \
echo "$$msg"; \
cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) $$compare
- @r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}` ; export s; \
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
$(SET_LIB_PATH) \
echo "Building runtime libraries"; \
$(MAKE) $(BASE_FLAGS_TO_PASS) $(RECURSE_FLAGS) all
+profiledbootstrap: all-bootstrap configure-gcc
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Bootstrapping the compiler"; \
+ cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) stageprofile_build
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
+ $(SET_LIB_PATH) \
+ echo "Building runtime libraries and training compiler"; \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) $(RECURSE_FLAGS) all
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Building feedback based compiler"; \
+ cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) stagefeedback_build
+
.PHONY: cross
cross: all-texinfo all-bison all-byacc all-binutils all-gas all-ld
- @r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
$(SET_LIB_PATH) \
echo "Building the C and C++ compiler"; \
cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) LANGUAGES="c c++"
- @r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}` ; export s; \
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
$(SET_LIB_PATH) \
echo "Building runtime libraries"; \
$(MAKE) $(BASE_FLAGS_TO_PASS) $(RECURSE_FLAGS) \
LANGUAGES="c c++" all
-.PHONY: check-gcc
+.PHONY: check-gcc maybe-check-gcc
+maybe-check-gcc:
check-gcc:
@if [ -f ./gcc/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
$(SET_LIB_PATH) \
- (cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) check); \
+ (cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) check); \
else \
true; \
fi
-.PHONY: check-c++
-check-c++:
+.PHONY: check-gcc-c++
+check-gcc-c++:
@if [ -f ./gcc/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
$(SET_LIB_PATH) \
- (cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) check-c++); \
- $(MAKE) check-target-libstdc++-v3; \
+ (cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) check-c++); \
else \
true; \
- fi
+ fi
+
+.PHONY: check-c++
+check-c++: check-target-libstdc++-v3 check-gcc-c++
-.PHONY: install-gcc
+.PHONY: install-gcc maybe-install-gcc
+maybe-install-gcc:
install-gcc:
@if [ -f ./gcc/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
$(SET_LIB_PATH) \
- (cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) install); \
+ (cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) install); \
else \
true; \
fi
-.PHONY: install-gcc-cross
-install-gcc-cross:
- @if [ -f ./gcc/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
- $(SET_LIB_PATH) \
- (cd gcc; $(MAKE) $(GCC_FLAGS_TO_PASS) LANGUAGES="c c++" install); \
- else \
- true; \
- fi
-# EXPERIMENTAL STUFF
-# This rule is used to install the modules which use FLAGS_TO_PASS.
-# To build a target install-X means to cd to X and make install.
-.PHONY: install-dosrel
-install-dosrel: installdirs info
- @dir=`echo $@ | sed -e 's/install-//'`; \
- if [ -f ./$${dir}/Makefile ] ; then \
- r=`${PWD}`; export r; \
- s=`cd $(srcdir); ${PWD}`; export s; \
+# Install the gcc headers files, but not the fixed include files,
+# which Cygnus is not allowed to distribute. This rule is very
+# dependent on the workings of the gcc Makefile.in.
+.PHONY: gcc-no-fixedincludes
+gcc-no-fixedincludes:
+ @if [ -f ./gcc/Makefile ]; then \
+ rm -rf gcc/tmp-include; \
+ mv gcc/include gcc/tmp-include 2>/dev/null; \
+ mkdir gcc/include; \
+ cp $(srcdir)/gcc/gsyslimits.h gcc/include/syslimits.h; \
+ touch gcc/stmp-fixinc gcc/include/fixed; \
+ rm -f gcc/stmp-headers gcc/stmp-int-hdrs; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
$(SET_LIB_PATH) \
- (cd $${dir}; $(MAKE) $(FLAGS_TO_PASS) install); \
- else \
- true; \
- fi
+ (cd ./gcc && \
+ $(MAKE) $(GCC_FLAGS_TO_PASS) install); \
+ rm -rf gcc/include; \
+ mv gcc/tmp-include gcc/include 2>/dev/null; \
+ else true; fi
-install-dosrel-fake:
-
-ALL_GCC = all-gcc
-ALL_GCC_C = $(ALL_GCC) all-target-newlib all-target-libgloss
-ALL_GCC_CXX = $(ALL_GCC_C) all-target-libstdc++-v3
-
-# This is a list of inter-dependencies among modules.
-all-ash:
-all-autoconf: all-m4 all-texinfo
-all-automake: all-m4 all-texinfo
-all-bash:
-all-bfd: all-libiberty all-intl
-all-binutils: all-libiberty all-opcodes all-bfd all-flex all-bison all-byacc all-intl
-all-bison: all-texinfo
-configure-target-boehm-gc: $(ALL_GCC_C) configure-target-qthreads
-all-target-boehm-gc: configure-target-boehm-gc
-all-byacc:
-all-bzip2:
-all-db:
-all-dejagnu: all-tcl all-expect all-tk
-all-diff: all-libiberty
-all-etc:
-configure-target-examples: $(ALL_GCC_C)
-all-target-examples: configure-target-examples
-all-expect: all-tcl all-tk
-all-fileutils: all-libiberty
-all-findutils:
-all-find:
-all-flex: all-libiberty all-bison all-byacc
-all-gas: all-libiberty all-opcodes all-bfd all-intl
-all-gawk:
-all-gcc: all-bison all-byacc all-binutils all-gas all-ld all-zlib
-all-bootstrap: all-libiberty all-texinfo all-bison all-byacc all-binutils all-gas all-ld all-zlib
-GDB_TK = all-tk all-tcl all-itcl all-tix all-libgui
-all-gdb: all-libiberty all-opcodes all-bfd all-mmalloc all-readline all-bison all-byacc all-sim $(gdbnlmrequirements) $(GDB_TK)
-all-gettext:
-all-gnuserv:
-configure-target-gperf: $(ALL_GCC_CXX)
-all-target-gperf: configure-target-gperf all-target-libiberty all-target-libstdc++-v3
-all-gprof: all-libiberty all-bfd all-opcodes all-intl
-all-grep: all-libiberty
-all-gui: all-gdb all-libproc
-all-guile:
-all-gzip: all-libiberty
-all-hello: all-libiberty
-all-indent:
-all-intl:
-all-itcl: all-tcl all-tk
-all-ld: all-libiberty all-bfd all-opcodes all-bison all-byacc all-flex all-intl
-configure-target-libgloss: $(ALL_GCC)
-all-target-libgloss: configure-target-libgloss configure-target-newlib
-all-libgui: all-tcl all-tk all-itcl
-all-libiberty:
+# --------------------------------------
+# Dependencies between different modules
+# --------------------------------------
-all-build-libiberty: configure-build-libiberty
+# There are two types of dependencies here: 'hard' dependencies, where one
+# module simply won't build without the other; and 'soft' dependencies, where
+# if the depended-on module is missing, the depending module will do without
+# or find a substitute somewhere (perhaps installed). Soft dependencies
+# are specified by depending on a 'maybe-' target. If you're not sure,
+# it's safer to use a soft dependency.
-configure-target-libffi: $(ALL_GCC_C)
-all-target-libffi: configure-target-libffi
-configure-target-libjava: $(ALL_GCC_C) configure-target-zlib configure-target-boehm-gc configure-target-qthreads configure-target-libffi
-all-target-libjava: configure-target-libjava all-fastjar all-target-zlib all-target-boehm-gc all-target-qthreads all-target-libffi
-configure-target-libstdc++-v3: $(ALL_GCC_C)
-all-target-libstdc++-v3: configure-target-libstdc++-v3 all-target-libiberty
-all-libtool:
+# Host modules specific to gcc.
+# GCC needs to identify certain tools.
+# GCC also needs the information exported by the intl configure script.
+configure-gcc: maybe-configure-intl maybe-configure-binutils maybe-configure-gas maybe-configure-ld maybe-configure-bison maybe-configure-flex
+all-gcc: maybe-all-libiberty maybe-all-intl maybe-all-bison maybe-all-byacc maybe-all-binutils maybe-all-gas maybe-all-ld maybe-all-zlib
+# This is a slightly kludgy method of getting dependencies on
+# all-build-libiberty correct; it would be better to build it every time.
+all-gcc: maybe-all-build-libiberty
+all-bootstrap: maybe-all-libiberty maybe-all-intl maybe-all-texinfo maybe-all-bison maybe-all-byacc maybe-all-binutils maybe-all-gas maybe-all-ld maybe-all-zlib
+
+# Host modules specific to gdb.
+# GDB needs to know that the simulator is being built.
+configure-gdb: maybe-configure-itcl maybe-configure-tcl maybe-configure-tk maybe-configure-sim
+GDB_TK = @GDB_TK@
+all-gdb: maybe-all-libiberty maybe-all-opcodes maybe-all-bfd maybe-all-mmalloc maybe-all-readline maybe-all-bison maybe-all-byacc maybe-all-sim $(gdbnlmrequirements) $(GDB_TK)
+install-gdb: maybe-install-tcl maybe-install-tk maybe-install-itcl maybe-install-tix maybe-install-libgui
+configure-libgui: maybe-configure-tcl maybe-configure-tk
+all-libgui: maybe-all-tcl maybe-all-tk maybe-all-itcl
+
+# Host modules specific to binutils.
+configure-bfd: configure-libiberty
+all-bfd: maybe-all-libiberty maybe-all-intl
+all-binutils: maybe-all-libiberty maybe-all-opcodes maybe-all-bfd maybe-all-flex maybe-all-bison maybe-all-byacc maybe-all-intl
+# We put install-opcodes before install-binutils because the installed
+# binutils might be on PATH, and they might need the shared opcodes
+# library.
+install-binutils: maybe-install-opcodes
+# libopcodes depends on libbfd
+install-opcodes: maybe-install-bfd
+all-gas: maybe-all-libiberty maybe-all-opcodes maybe-all-bfd maybe-all-intl
+all-gprof: maybe-all-libiberty maybe-all-bfd maybe-all-opcodes maybe-all-intl
+all-ld: maybe-all-libiberty maybe-all-bfd maybe-all-opcodes maybe-all-bison maybe-all-byacc maybe-all-flex maybe-all-intl
+all-opcodes: maybe-all-bfd maybe-all-libiberty
+
+# Other host modules in the 'src' repository.
+all-dejagnu: maybe-all-tcl maybe-all-expect maybe-all-tk
+configure-expect: maybe-configure-tcl maybe-configure-tk
+all-expect: maybe-all-tcl maybe-all-tk
+configure-itcl: maybe-configure-tcl maybe-configure-tk
+all-itcl: maybe-all-tcl maybe-all-tk
+# We put install-tcl before install-itcl because itcl wants to run a
+# program on installation which uses the Tcl libraries.
+install-itcl: maybe-install-tcl
+all-sid: maybe-all-libiberty maybe-all-bfd maybe-all-opcodes maybe-all-tcl maybe-all-tk
+install-sid: maybe-install-tcl maybe-install-tk
+all-sim: maybe-all-libiberty maybe-all-bfd maybe-all-opcodes maybe-all-readline maybe-configure-gdb
+configure-tk: maybe-configure-tcl
+all-tk: maybe-all-tcl
+configure-tix: maybe-configure-tcl maybe-configure-tk
+all-tix: maybe-all-tcl maybe-all-tk
+all-texinfo: maybe-all-libiberty
+
+# Other host modules. Warning, these are not well tested.
+all-autoconf: maybe-all-m4 maybe-all-texinfo
+all-automake: maybe-all-m4 maybe-all-texinfo
+all-bison: maybe-all-texinfo
+all-diff: maybe-all-libiberty
+all-fastjar: maybe-all-zlib maybe-all-libiberty
+all-fileutils: maybe-all-libiberty
+all-flex: maybe-all-libiberty maybe-all-bison maybe-all-byacc
+all-gzip: maybe-all-libiberty
+all-hello: maybe-all-libiberty
+all-m4: maybe-all-libiberty maybe-all-texinfo
+all-make: maybe-all-libiberty maybe-all-intl
+all-patch: maybe-all-libiberty
+all-prms: maybe-all-libiberty
+all-recode: maybe-all-libiberty
+all-sed: maybe-all-libiberty
+all-send-pr: maybe-all-prms
+all-tar: maybe-all-libiberty
+all-uudecode: maybe-all-libiberty
+
+ALL_GCC = maybe-all-gcc
+ALL_GCC_C = $(ALL_GCC) maybe-all-target-newlib maybe-all-target-libgloss
+ALL_GCC_CXX = $(ALL_GCC_C) maybe-all-target-libstdc++-v3
+
+# Target modules specific to gcc.
+configure-target-boehm-gc: $(ALL_GCC_C) maybe-configure-target-qthreads
+configure-target-fastjar: maybe-configure-target-zlib
+all-target-fastjar: maybe-all-target-zlib maybe-all-target-libiberty
configure-target-libf2c: $(ALL_GCC_C)
-all-target-libf2c: configure-target-libf2c all-target-libiberty
+all-target-libf2c: maybe-all-target-libiberty
+configure-target-libffi: $(ALL_GCC_C)
+configure-target-libjava: $(ALL_GCC_C) maybe-configure-target-zlib maybe-configure-target-boehm-gc maybe-configure-target-qthreads maybe-configure-target-libffi
+all-target-libjava: maybe-all-fastjar maybe-all-target-zlib maybe-all-target-boehm-gc maybe-all-target-qthreads maybe-all-target-libffi
configure-target-libobjc: $(ALL_GCC_C)
-all-target-libobjc: configure-target-libobjc all-target-libiberty
-all-m4: all-libiberty all-texinfo
-all-make: all-libiberty
-all-mmalloc:
-configure-target-newlib: $(ALL_GCC)
-all-target-newlib: configure-target-newlib
+all-target-libobjc: maybe-all-target-libiberty
+configure-target-libstdc++-v3: $(ALL_GCC_C)
+all-target-libstdc++-v3: maybe-all-target-libiberty
+configure-target-zlib: $(ALL_GCC_C)
+
+# Target modules in the 'src' repository.
+configure-target-examples: $(ALL_GCC_C)
+configure-target-libgloss: $(ALL_GCC)
+all-target-libgloss: maybe-configure-target-newlib
+configure-target-libiberty: $(ALL_GCC)
configure-target-libtermcap: $(ALL_GCC_C)
-all-target-libtermcap: configure-target-libtermcap
-all-opcodes: all-bfd all-libiberty
-all-patch: all-libiberty
-all-perl:
-all-prms: all-libiberty
-configure-target-qthreads: $(ALL_GCC_C)
-all-target-qthreads: configure-target-qthreads
-all-rcs:
-all-readline:
-all-recode: all-libiberty
-all-sed: all-libiberty
-all-send-pr: all-prms
-all-shellutils:
-all-sid: all-tcl all-tk
-all-sim: all-libiberty all-bfd all-opcodes all-readline
-all-snavigator: all-tcl all-tk all-itcl all-tix all-db all-grep all-libgui
-all-tar: all-libiberty
-all-tcl:
-all-tclX: all-tcl all-tk
-all-tk: all-tcl
-all-texinfo: all-libiberty
-all-textutils:
-all-time:
-all-tix: all-tcl all-tk
-all-wdiff:
+configure-target-newlib: $(ALL_GCC)
+configure-target-rda: $(ALL_GCC_C)
configure-target-winsup: $(ALL_GCC_C)
-all-target-winsup: all-target-libiberty all-target-libtermcap configure-target-winsup
-all-uudecode: all-libiberty
-all-zip:
-all-zlib:
-configure-target-zlib: $(ALL_GCC_C)
-all-target-zlib: configure-target-zlib
-all-fastjar: all-zlib all-libiberty
-configure-target-fastjar: configure-target-zlib
-all-target-fastjar: configure-target-fastjar all-target-zlib all-target-libiberty
-configure-target-libiberty: $(ALL_GCC_C)
-all-target-libiberty: configure-target-libiberty
-all-target: $(ALL_TARGET_MODULES)
-install-target: $(INSTALL_TARGET_MODULES)
-install-gdb: install-tcl install-tk install-itcl install-tix install-libgui
-install-sid: install-tcl install-tk
-### other supporting targets
+all-target-winsup: maybe-all-target-libiberty maybe-all-target-libtermcap
-MAKEDIRS= \
- $(DESTDIR)$(prefix) \
- $(DESTDIR)$(exec_prefix)
-.PHONY: installdirs
-installdirs: mkinstalldirs
- $(SHELL) $(srcdir)/mkinstalldirs $(MAKEDIRS)
+# Other target modules. Warning, these are not well tested.
+configure-target-gperf: $(ALL_GCC_CXX)
+all-target-gperf: maybe-all-target-libiberty maybe-all-target-libstdc++-v3
+configure-target-qthreads: $(ALL_GCC_C)
-dir.info: do-install-info
- if [ -f $(srcdir)/texinfo/gen-info-dir ] ; then \
- $(srcdir)/texinfo/gen-info-dir $(infodir) $(srcdir)/texinfo/dir.info-template > dir.info.new ; \
- mv -f dir.info.new dir.info ; \
- else true ; \
- fi
+# Dependencies of maybe-foo on foo. These are used because, for example,
+# all-gcc only depends on all-gas if gas is present and being configured.
+@maybe_dependencies@
-dist:
- @echo "Building a full distribution of this tree isn't done"
- @echo "via 'make dist'. Check out the etc/ subdirectory"
+# Serialization dependencies. Host configures don't work well in parallel to
+# each other, due to contention over config.cache. Target configures and
+# build configures are similar.
+@serialization_dependencies@
-etags tags: TAGS
+# --------------------------------
+# Regenerating top level configury
+# --------------------------------
-# Right now this just builds TAGS in each subdirectory. emacs19 has the
-# ability to use several tags files at once, so there is probably no need
-# to combine them into one big TAGS file (like CVS 1.3 does). We could
-# (if we felt like it) have this Makefile write a piece of elisp which
-# the user could load to tell emacs19 where all the TAGS files we just
-# built are.
-TAGS: do-TAGS
+# Multilib.out tells target dirs what multilibs they should build.
+# There is really only one copy. We use the 'timestamp' method to
+# work around various timestamp bugs on some systems.
+# We use move-if-change so that it's only considered updated when it
+# actually changes, because it has to depend on a phony target.
+multilib.out: maybe-all-gcc
+ @r=`${PWD_COMMAND}`; export r; \
+ echo "Checking multilib configuration..."; \
+ $(CC_FOR_TARGET) --print-multi-lib > multilib.tmp 2> /dev/null ; \
+ $(SHELL) $(srcdir)/move-if-change multilib.tmp multilib.out ; \
-# with the gnu make, this is done automatically.
+# Rebuilding Makefile.in, using autogen.
+AUTOGEN = autogen
+$(srcdir)/Makefile.in: @MAINT@ $(srcdir)/Makefile.tpl $(srcdir)/Makefile.def
+ cd $(srcdir) && $(AUTOGEN) Makefile.def
-Makefile: Makefile.in configure.in $(host_makefile_frag) $(target_makefile_frag) $(gcc_version_trigger)
- $(SHELL) ./config.status
+# Rebuilding Makefile.
+Makefile: $(srcdir)/Makefile.in config.status
+ CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
-#
-# Support for building net releases
-
-# Files in devo used in any net release.
-# ChangeLog omitted because it may refer to files which are not in this
-# distribution (perhaps it would be better to include it anyway).
-DEVO_SUPPORT= README Makefile.in configure configure.in \
- config.guess config.if config.sub config move-if-change \
- mpw-README mpw-build.in mpw-config.in mpw-configure mpw-install \
- COPYING COPYING.LIB install-sh config-ml.in symlink-tree \
- mkinstalldirs ltconfig ltmain.sh missing ylwrap \
- libtool.m4 gettext.m4 ltcf-c.sh ltcf-cxx.sh ltcf-gcj.sh
-
-# Files in devo/etc used in any net release.
-# ChangeLog omitted because it may refer to files which are not in this
-# distribution (perhaps it would be better to include it anyway).
-ETC_SUPPORT= Makefile.in configure configure.in standards.texi \
- make-stds.texi standards.info* configure.texi configure.info* \
- configbuild.* configdev.*
-
-
-# When you use `make setup-dirs' or `make taz' you should always redefine
-# this macro.
-SUPPORT_FILES = list-of-support-files-for-tool-in-question
-
-# NOTE: No double quotes in the below. It is used within shell script
-# as VER="$(VER)"
-VER = ` if grep 'AM_INIT_AUTOMAKE.*BFD_VERSION' $(TOOL)/configure.in >/dev/null 2>&1; then \
- sed < bfd/configure.in -n 's/AM_INIT_AUTOMAKE[^,]*, *\([^)]*\))/\1/p'; \
- elif grep AM_INIT_AUTOMAKE $(TOOL)/configure.in >/dev/null 2>&1; then \
- sed < $(TOOL)/configure.in -n 's/AM_INIT_AUTOMAKE[^,]*, *\([^)]*\))/\1/p'; \
- elif test -f $(TOOL)/version.in; then \
- head -1 $(TOOL)/version.in; \
- elif grep VERSION $(TOOL)/Makefile.in > /dev/null 2>&1; then \
- sed < $(TOOL)/Makefile.in -n 's/^VERSION *= *//p'; \
- else \
- echo VERSION; \
- fi`
-PACKAGE = $(TOOL)
-
-.PHONY: taz
-taz: $(DEVO_SUPPORT) $(SUPPORT_FILES) texinfo/texinfo.tex
- $(MAKE) -f Makefile.in do-proto-toplev \
- TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(SUPPORT_FILES)"
- $(MAKE) -f Makefile.in do-md5sum \
- TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(SUPPORT_FILES)"
- $(MAKE) -f Makefile.in do-tar \
- TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(SUPPORT_FILES)"
- $(MAKE) -f Makefile.in do-bz2 \
- TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(SUPPORT_FILES)"
-
-.PHONY: gdb-tar
-gdb-tar: $(DEVO_SUPPORT) $(SUPPORT_FILES) texinfo/texinfo.tex
- $(MAKE) -f Makefile.in do-proto-toplev \
- TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(SUPPORT_FILES)"
- $(MAKE) -f Makefile.in do-md5sum \
- TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(SUPPORT_FILES)"
- $(MAKE) -f Makefile.in do-djunpack \
- TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(SUPPORT_FILES)"
- $(MAKE) -f Makefile.in do-tar \
- TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(SUPPORT_FILES)"
-
-.PHONY: gdb-taz
-gdb-taz: gdb-tar $(DEVO_SUPPORT) $(SUPPORT_FILES) texinfo/texinfo.tex
- $(MAKE) -f Makefile.in gdb-tar \
- TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(SUPPORT_FILES)"
- $(MAKE) -f Makefile.in do-bz2 \
- TOOL=$(TOOL) PACKAGE="$(PACKAGE)" VER="$(VER)" \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(SUPPORT_FILES)"
-
-.PHONY: do-proto-toplev
-do-proto-toplev: $(DEVO_SUPPORT) $(SUPPORT_FILES) texinfo/texinfo.tex
- echo "==> Making $(PACKAGE)-$(VER)/"
- # Take out texinfo from a few places.
- sed -e '/^all\.normal: /s/\all-texinfo //' \
- -e '/^ install-texinfo /d' \
- <Makefile.in >tmp
- mv -f tmp Makefile.in
- #
- ./configure sun4
- [ -z "$(CONFIGURE_TARGET_MODULES)" ] \
- || $(MAKE) $(CONFIGURE_TARGET_MODULES) \
- ALL_GCC="" ALL_GCC_C="" ALL_GCC_CXX="" \
- CC_FOR_TARGET="$(CC)" CXX_FOR_TARGET="$(CXX)"
- # Make links, and run "make diststuff" or "make info" when needed.
- rm -rf proto-toplev ; mkdir proto-toplev
- set -e ; dirs="$(TOOL) $(DEVO_SUPPORT) $(SUPPORT_FILES)" ; \
- for d in $$dirs ; do \
- if [ -d $$d ]; then \
- if [ ! -f $$d/Makefile ] ; then true ; \
- elif grep '^diststuff:' $$d/Makefile >/dev/null ; then \
- (cd $$d ; $(MAKE) diststuff ) || exit 1 ; \
- elif grep '^info:' $$d/Makefile >/dev/null ; then \
- (cd $$d ; $(MAKE) info ) || exit 1 ; \
- fi ; \
- if [ -d $$d/proto-$$d.dir ]; then \
- ln -s ../$$d/proto-$$d.dir proto-toplev/$$d ; \
- else \
- ln -s ../$$d proto-toplev/$$d ; \
- fi ; \
- else ln -s ../$$d proto-toplev/$$d ; fi ; \
- done
- cd etc && $(MAKE) info
- $(MAKE) distclean
- #
- mkdir proto-toplev/etc
- (cd proto-toplev/etc; \
- for i in $(ETC_SUPPORT); do \
- ln -s ../../etc/$$i . ; \
- done)
- #
- # Take out texinfo from configurable dirs
- rm proto-toplev/configure.in
- sed -e '/^host_tools=/s/texinfo //' \
- <configure.in >proto-toplev/configure.in
- #
- mkdir proto-toplev/texinfo
- ln -s ../../texinfo/texinfo.tex proto-toplev/texinfo/
- if test -r texinfo/util/tex3patch ; then \
- mkdir proto-toplev/texinfo/util && \
- ln -s ../../../texinfo/util/tex3patch proto-toplev/texinfo/util ; \
- else true; fi
- chmod -R og=u . || chmod og=u `find . -print`
- #
- # Create .gmo files from .po files.
- for f in `find . -name '*.po' -type f -print`; do \
- msgfmt -o `echo $$f | sed -e 's/\.po$$/.gmo/'` $$f ; \
- done
- #
- -rm -f $(PACKAGE)-$(VER)
- ln -s proto-toplev $(PACKAGE)-$(VER)
-
-.PHONY: do-tar
-do-tar:
- echo "==> Making $(PACKAGE)-$(VER).tar"
- -rm -f $(PACKAGE)-$(VER).tar
- find $(PACKAGE)-$(VER) -follow -name CVS -prune -o -type f -print \
- | tar cTfh - $(PACKAGE)-$(VER).tar
-
-.PHONY: do-bz2
-do-bz2:
- echo "==> Bzipping $(PACKAGE)-$(VER).tar.bz2"
- -rm -f $(PACKAGE)-$(VER).tar.bz2
- $(BZIPPROG) -v -9 $(PACKAGE)-$(VER).tar
-
-.PHONY: do-md5sum
-do-md5sum:
- echo "==> Adding md5 checksum to top-level directory"
- cd proto-toplev && find * -follow -name CVS -prune -o -type f -print \
- | xargs $(MD5PROG) > ../md5.sum
- mv md5.sum proto-toplev
-
-.PHONY: do-djunpack
-do-djunpack:
- echo "==> Adding updated djunpack.bat to top-level directory"
- echo - 's /gdb-[0-9\.]*/gdb-'"$(VER)"'/'
- sed < djunpack.bat > djunpack.new \
- -e 's/gdb-[0-9][0-9\.]*/gdb-'"$(VER)"'/'
- mv djunpack.new djunpack.bat
- -rm -f proto-toplev/djunpack.bat
- ln -s ../djunpack.bat proto-toplev/djunpack.bat
-
-TEXINFO_SUPPORT= texinfo/texinfo.tex
-DIST_SUPPORT= $(DEVO_SUPPORT) $(TEXINFO_SUPPORT)
-
-.PHONY: gas.tar.bz2
-GAS_SUPPORT_DIRS= bfd include libiberty opcodes intl setup.com makefile.vms mkdep
-gas.tar.bz2: $(DIST_SUPPORT) $(GAS_SUPPORT_DIRS) gas
- $(MAKE) -f Makefile.in taz TOOL=gas \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(GAS_SUPPORT_DIRS)"
-
-# The FSF "binutils" release includes gprof and ld.
-.PHONY: binutils.tar.bz2
-BINUTILS_SUPPORT_DIRS= bfd gas include libiberty opcodes ld gprof intl setup.com makefile.vms mkdep
-binutils.tar.bz2: $(DIST_SUPPORT) $(BINUTILS_SUPPORT_DIRS) binutils
- $(MAKE) -f Makefile.in taz TOOL=binutils \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(BINUTILS_SUPPORT_DIRS)"
-
-.PHONY: gas+binutils.tar.bz2
-GASB_SUPPORT_DIRS= $(GAS_SUPPORT_DIRS) binutils ld gprof
-gas+binutils.tar.bz2: $(DIST_SUPPORT) $(GASB_SUPPORT_DIRS) gas
- $(MAKE) -f Makefile.in taz TOOL=gas \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(GASB_SUPPORT_DIRS)"
-
-GNATS_SUPPORT_DIRS=include libiberty send-pr
-gnats.tar.bz2: $(DIST_SUPPORT) $(GNATS_SUPPORT_DIRS) gnats
- $(MAKE) -f Makefile.in taz TOOL=gnats \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(GNATS_SUPPORT_DIRS)"
-
-.PHONY: gdb.tar.bz2
-GDB_SUPPORT_DIRS= bfd include libiberty mmalloc opcodes readline sim utils intl
-gdb.tar.bz2: $(DIST_SUPPORT) $(GDB_SUPPORT_DIRS) gdb
- $(MAKE) -f Makefile.in gdb-taz TOOL=gdb \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(GDB_SUPPORT_DIRS)"
-.PHONY: gdb.tar
-gdb.tar: $(DIST_SUPPORT) $(GDB_SUPPORT_DIRS) gdb
- $(MAKE) -f Makefile.in gdb-tar TOOL=gdb \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(GDB_SUPPORT_DIRS)"
-
-DEJAGNU_SUPPORT_DIRS= tcl expect libiberty
-.PHONY: dejagnu.tar.bz2
-dejagnu.tar.bz2: $(DIST_SUPPORT) $(DEJAGNU_SUPPORT_DIRS) dejagnu
- $(MAKE) -f Makefile.in taz TOOL=dejagnu \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(DEJAGNU_SUPPORT_DIRS)"
-
-.PHONY: gdb+dejagnu.tar.bz2
-GDBD_SUPPORT_DIRS= $(GDB_SUPPORT_DIRS) tcl expect dejagnu
-gdb+dejagnu.tar.bz2: $(DIST_SUPPORT) $(GDBD_SUPPORT_DIRS) gdb
- $(MAKE) -f Makefile.in gdb-taz TOOL=gdb PACKAGE=gdb+dejagnu \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(GDBD_SUPPORT_DIRS)"
-.PHONY: gdb+dejagnu.tar
-gdb+dejagnu.tar: $(DIST_SUPPORT) $(GDBD_SUPPORT_DIRS) gdb
- $(MAKE) -f Makefile.in gdb-tar TOOL=gdb PACKAGE=gdb+dejagnu \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(GDBD_SUPPORT_DIRS)"
-
-.PHONY: insight.tar.bz2
-INSIGHT_SUPPORT_DIRS= $(GDB_SUPPORT_DIRS) tcl tk itcl tix libgui
-insight.tar.bz2: $(DIST_SUPPORT) $(GDB_SUPPORT_DIRS) gdb
- $(MAKE) -f Makefile.in gdb-taz TOOL=gdb PACKAGE=insight \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(INSIGHT_SUPPORT_DIRS)"
-.PHONY: insight.tar
-insight.tar: $(DIST_SUPPORT) $(GDB_SUPPORT_DIRS) gdb
- $(MAKE) -f Makefile.in gdb-tar TOOL=gdb PACKAGE=insight \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(INSIGHT_SUPPORT_DIRS)"
-
-.PHONY: insight+dejagnu.tar.bz2
-INSIGHTD_SUPPORT_DIRS= $(INSIGHT_SUPPORT_DIRS) expect dejagnu
-insight+dejagnu.tar.bz2: $(DIST_SUPPORT) $(INSIGHTD_SUPPORT_DIRS) gdb
- $(MAKE) -f Makefile.in gdb-taz TOOL=gdb PACKAGE="insight+dejagnu" \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(INSIGHTD_SUPPORT_DIRS)"
-.PHONY: insight+dejagnu.tar
-insight+dejagnu.tar: $(DIST_SUPPORT) $(INSIGHTD_SUPPORT_DIRS) gdb
- $(MAKE) -f Makefile.in gdb-tar TOOL=gdb PACKAGE="insight+dejagnu" \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(INSIGHTD_SUPPORT_DIRS)"
-
-.PHONY: newlib.tar.bz2
-NEWLIB_SUPPORT_DIRS=libgloss
-# taz configures for the sun4 target which won't configure newlib.
-# We need newlib configured so that the .info files are made.
-# Unfortunately, it is not enough to just configure newlib separately:
-# taz will build the .info files but since SUBDIRS won't contain newlib,
-# distclean won't be run (leaving Makefile, config.status, and the tmp files
-# used in building the .info files, eg: *.def, *.ref).
-# The problem isn't solvable however without a lot of extra work because
-# target libraries are built in subdir $(target_alias) which gets nuked during
-# the make distclean. For now punt on the issue of shipping newlib info files
-# with newlib net releases and wait for a day when some native target (sun4?)
-# supports newlib (if only minimally).
-newlib.tar.bz2: $(DIST_SUPPORT) $(NEWLIB_SUPPORT_DIRS) newlib
- $(MAKE) -f Makefile.in taz TOOL=newlib \
- MD5PROG="$(MD5PROG)" \
- SUPPORT_FILES="$(NEWLIB_SUPPORT_DIRS)" \
- DEVO_SUPPORT="$(DEVO_SUPPORT) COPYING.NEWLIB" newlib
+config.status: configure $(gcc_version_trigger)
+ CONFIG_SHELL="$(SHELL)" $(SHELL) ./config.status --recheck
+
+# Rebuilding configure.
+AUTOCONF = autoconf
+$(srcdir)/configure: @MAINT@ $(srcdir)/configure.in $(srcdir)/config/acx.m4
+ cd $(srcdir) && $(AUTOCONF)
+
+# ------------------------------
+# Special directives to GNU Make
+# ------------------------------
+# Don't pass command-line variables to submakes.
.NOEXPORT:
MAKEOVERRIDES=
diff --git a/contrib/binutils/Makefile.tpl b/contrib/binutils/Makefile.tpl
new file mode 100644
index 0000000..3a7750c
--- /dev/null
+++ b/contrib/binutils/Makefile.tpl
@@ -0,0 +1,1435 @@
+[+ AutoGen5 template -*- Mode: Makefile -*-
+in
++]
+
+# Makefile.in is generated from Makefile.tpl by 'autogen Makefile.def'.
+#
+# Makefile for directory with subdirs to build.
+# Copyright (C) 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
+# 1999, 2000, 2001, 2002, 2003 Free Software Foundation
+#
+# This file is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+#
+
+# -------------------------------
+# Standard Autoconf-set variables
+# -------------------------------
+VPATH=@srcdir@
+
+build_alias=@build_alias@
+build=@build@
+host_alias=@host_alias@
+host=@host@
+target_alias=@target_alias@
+target=@target@
+
+program_transform_name = @program_transform_name@
+
+prefix = @prefix@
+exec_prefix = @exec_prefix@
+
+srcdir = @srcdir@
+
+bindir = @bindir@
+sbindir = @sbindir@
+libexecdir = @libexecdir@
+datadir = @datadir@
+sysconfdir = @sysconfdir@
+sharedstatedir = @sharedstatedir@
+localstatedir = @localstatedir@
+libdir = @libdir@
+includedir = @includedir@
+oldincludedir = @oldincludedir@
+infodir = @infodir@
+mandir = @mandir@
+man1dir = $(mandir)/man1
+man2dir = $(mandir)/man2
+man3dir = $(mandir)/man3
+man4dir = $(mandir)/man4
+man5dir = $(mandir)/man5
+man6dir = $(mandir)/man6
+man7dir = $(mandir)/man7
+man8dir = $(mandir)/man8
+man9dir = $(mandir)/man9
+
+INSTALL = @INSTALL@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_DATA = @INSTALL_DATA@
+
+# -------------------------------------------------
+# Miscellaneous non-standard autoconf-set variables
+# -------------------------------------------------
+
+links=@configlinks@
+# The file containing GCC's version number.
+gcc_version_trigger = @gcc_version_trigger@
+gcc_version = @gcc_version@
+
+# The gcc driver likes to know the arguments it was configured with.
+TOPLEVEL_CONFIGURE_ARGUMENTS=@TOPLEVEL_CONFIGURE_ARGUMENTS@
+
+gxx_include_dir = @gxx_include_dir@
+libstdcxx_incdir = @libstdcxx_incdir@
+
+tooldir = @tooldir@
+build_tooldir = @build_tooldir@
+
+# Directory in which the compiler finds executables, libraries, etc.
+libsubdir = $(libdir)/gcc/$(target_alias)/$(gcc_version)
+GDB_NLM_DEPS =
+
+# This is the name of the environment variable used for the path to
+# the libraries.
+RPATH_ENVVAR = @RPATH_ENVVAR@
+
+# This is set by configure to REALLY_SET_LIB_PATH if --enable-shared
+# was used.
+SET_LIB_PATH = @SET_LIB_PATH@
+
+# configure.in sets SET_LIB_PATH to this if --enable-shared was used.
+# Some platforms don't like blank entries, so we remove duplicate,
+# leading and trailing colons.
+REALLY_SET_LIB_PATH = \
+ $(RPATH_ENVVAR)=`echo "$(HOST_LIB_PATH):$(TARGET_LIB_PATH):$$$(RPATH_ENVVAR)" | sed 's,::*,:,g;s,^:*,,;s,:*$$,,'`; export $(RPATH_ENVVAR);
+
+# This is the list of directories to be built for the build system.
+BUILD_CONFIGDIRS = libiberty
+# Build programs are put under this directory.
+BUILD_SUBDIR = @build_subdir@
+# This is set by the configure script to the arguments to use when configuring
+# directories built for the build system.
+BUILD_CONFIGARGS = @build_configargs@
+
+# This is the list of directories to built for the host system.
+SUBDIRS = @configdirs@
+# This is set by the configure script to the arguments to use when configuring
+# directories built for the host system.
+HOST_CONFIGARGS = @host_configargs@
+
+# This is set by the configure script to the list of directories which
+# should be built using the target tools.
+TARGET_CONFIGDIRS = @target_configdirs@
+# Target libraries are put under this directory:
+TARGET_SUBDIR = @target_subdir@
+# This is set by the configure script to the arguments to use when configuring
+# directories built for the target.
+TARGET_CONFIGARGS = @target_configargs@
+
+# ----------------------------------------------
+# Programs producing files for the BUILD machine
+# ----------------------------------------------
+
+SHELL = @config_shell@
+
+# pwd command to use. Allow user to override default by setting PWDCMD in
+# the environment to account for automounters. The make variable must not
+# be called PWDCMD, otherwise the value set here is passed to make
+# subprocesses and overrides the setting from the user's environment.
+# Don't use PWD since it is a common shell environment variable and we
+# don't want to corrupt it.
+PWD_COMMAND = $${PWDCMD-pwd}
+
+# compilers to use to create programs which must be run in the build
+# environment.
+CC_FOR_BUILD = @CC_FOR_BUILD@
+CFLAGS_FOR_BUILD = @CFLAGS_FOR_BUILD@
+
+CXX_FOR_BUILD = $(CXX)
+
+# Special variables passed down in EXTRA_GCC_FLAGS. They are defined
+# here so that they can be overridden by Makefile fragments.
+BUILD_PREFIX = @BUILD_PREFIX@
+BUILD_PREFIX_1 = @BUILD_PREFIX_1@
+
+BISON=@BISON@
+USUAL_BISON = `if [ -f $$r/bison/bison ] ; then \
+ echo $$r/bison/bison -L $$s/bison/ ; \
+ else \
+ echo bison ; \
+ fi`
+
+DEFAULT_YACC = @DEFAULT_YACC@
+YACC=@YACC@
+USUAL_YACC = `if [ -f $$r/bison/bison ] ; then \
+ echo $$r/bison/bison -y -L $$s/bison/ ; \
+ elif [ -f $$r/byacc/byacc ] ; then \
+ echo $$r/byacc/byacc ; \
+ else \
+ echo ${DEFAULT_YACC} ; \
+ fi`
+
+DEFAULT_LEX = @DEFAULT_LEX@
+LEX=@LEX@
+USUAL_LEX = `if [ -f $$r/flex/flex ] ; \
+ then echo $$r/flex/flex ; \
+ else echo ${DEFAULT_LEX} ; fi`
+
+DEFAULT_M4 = @DEFAULT_M4@
+M4 = `if [ -f $$r/m4/m4 ] ; \
+ then echo $$r/m4/m4 ; \
+ else echo ${DEFAULT_M4} ; fi`
+
+# For an installed makeinfo, we require it to be from texinfo 4.2 or
+# higher, else we use the "missing" dummy.
+MAKEINFO=@MAKEINFO@
+USUAL_MAKEINFO = `if [ -f $$r/texinfo/makeinfo/makeinfo ] ; \
+ then echo $$r/texinfo/makeinfo/makeinfo ; \
+ else if (makeinfo --version \
+ | egrep 'texinfo[^0-9]*([1-3][0-9]|4\.[2-9]|[5-9])') >/dev/null 2>&1; \
+ then echo makeinfo; else echo $$s/missing makeinfo; fi; fi`
+
+# This just becomes part of the MAKEINFO definition passed down to
+# sub-makes. It lets flags be given on the command line while still
+# using the makeinfo from the object tree.
+# (Default to avoid splitting info files by setting the threshold high.)
+MAKEINFOFLAGS = --split-size=5000000
+
+EXPECT = `if [ -f $$r/expect/expect ] ; \
+ then echo $$r/expect/expect ; \
+ else echo expect ; fi`
+
+RUNTEST = `if [ -f $$s/dejagnu/runtest ] ; \
+ then echo $$s/dejagnu/runtest ; \
+ else echo runtest ; fi`
+
+# ---------------------------------------------
+# Programs producing files for the HOST machine
+# ---------------------------------------------
+
+# This is the list of directories that may be needed in RPATH_ENVVAR
+# so that programs built for the host machine work.
+HOST_LIB_PATH = $$r/bfd:$$r/opcodes
+
+AS = @AS@
+
+AR = @AR@
+AR_FLAGS = rc
+
+CC = @CC@
+CFLAGS = @CFLAGS@
+LIBCFLAGS = $(CFLAGS)
+
+CXX = @CXX@
+CXXFLAGS = @CXXFLAGS@
+LIBCXXFLAGS = $(CXXFLAGS) -fno-implicit-templates
+
+DLLTOOL = @DLLTOOL@
+
+NM = @NM@
+
+LD = @LD@
+LDFLAGS =
+
+RANLIB = @RANLIB@
+
+WINDRES = @WINDRES@
+
+PICFLAG =
+
+# -----------------------------------------------
+# Programs producing files for the TARGET machine
+# -----------------------------------------------
+
+# This is the list of directories that may be needed in RPATH_ENVVAR
+# so that prorgams built for the target machine work.
+TARGET_LIB_PATH = $$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs:
+
+FLAGS_FOR_TARGET = @FLAGS_FOR_TARGET@
+
+AR_FOR_TARGET=@AR_FOR_TARGET@
+USUAL_AR_FOR_TARGET = ` \
+ if [ -f $$r/binutils/ar ] ; then \
+ echo $$r/binutils/ar ; \
+ else \
+ if [ '$(host)' = '$(target)' ] ; then \
+ echo $(AR); \
+ else \
+ echo ar | sed '$(program_transform_name)' ; \
+ fi; \
+ fi`
+
+AS_FOR_TARGET=@AS_FOR_TARGET@
+USUAL_AS_FOR_TARGET = ` \
+ if [ -f $$r/gas/as-new ] ; then \
+ echo $$r/gas/as-new ; \
+ elif [ -f $$r/gcc/xgcc ]; then \
+ $(CC_FOR_TARGET) -print-prog-name=as ; \
+ else \
+ if [ '$(host)' = '$(target)' ] ; then \
+ echo $(AS); \
+ else \
+ echo as | sed '$(program_transform_name)' ; \
+ fi; \
+ fi`
+
+CC_FOR_TARGET = @CC_FOR_TARGET@
+# During gcc bootstrap, if we use some random cc for stage1 then
+# CFLAGS will be just -g. We want to ensure that TARGET libraries
+# (which we know are built with gcc) are built with optimizations so
+# prepend -O2 when setting CFLAGS_FOR_TARGET.
+CFLAGS_FOR_TARGET = -O2 $(CFLAGS)
+# If GCC_FOR_TARGET is not overriden on the command line, then this
+# variable is passed down to the gcc Makefile, where it is used to
+# build libgcc2.a. We define it here so that it can itself be
+# overridden on the command line.
+GCC_FOR_TARGET=@GCC_FOR_TARGET@
+USUAL_GCC_FOR_TARGET = $(STAGE_CC_WRAPPER) $$r/gcc/xgcc -B$$r/gcc/ $(FLAGS_FOR_TARGET)
+LIBCFLAGS_FOR_TARGET = $(CFLAGS_FOR_TARGET)
+
+CXX_FOR_TARGET = @CXX_FOR_TARGET@
+RAW_CXX_FOR_TARGET = @RAW_CXX_FOR_TARGET@
+CXX_FOR_TARGET_FOR_RECURSIVE_MAKE = @CXX_FOR_TARGET_FOR_RECURSIVE_MAKE@
+RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE = @RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE@
+CXXFLAGS_FOR_TARGET = $(CXXFLAGS)
+LIBCXXFLAGS_FOR_TARGET = $(CXXFLAGS_FOR_TARGET) -fno-implicit-templates
+
+DLLTOOL_FOR_TARGET=@DLLTOOL_FOR_TARGET@
+USUAL_DLLTOOL_FOR_TARGET = ` \
+ if [ -f $$r/binutils/dlltool ] ; then \
+ echo $$r/binutils/dlltool ; \
+ else \
+ if [ '$(host)' = '$(target)' ] ; then \
+ echo $(DLLTOOL); \
+ else \
+ echo dlltool | sed '$(program_transform_name)' ; \
+ fi; \
+ fi`
+
+GCJ_FOR_TARGET = @GCJ_FOR_TARGET@
+
+LD_FOR_TARGET=@LD_FOR_TARGET@
+USUAL_LD_FOR_TARGET = ` \
+ if [ -f $$r/ld/ld-new ] ; then \
+ echo $$r/ld/ld-new ; \
+ elif [ -f $$r/gcc/xgcc ]; then \
+ $(CC_FOR_TARGET) -print-prog-name=ld ; \
+ else \
+ if [ '$(host)' = '$(target)' ] ; then \
+ echo $(LD); \
+ else \
+ echo ld | sed '$(program_transform_name)' ; \
+ fi; \
+ fi`
+
+LDFLAGS_FOR_TARGET =
+
+NM_FOR_TARGET=@NM_FOR_TARGET@
+USUAL_NM_FOR_TARGET = ` \
+ if [ -f $$r/binutils/nm-new ] ; then \
+ echo $$r/binutils/nm-new ; \
+ elif [ -f $$r/gcc/xgcc ]; then \
+ $(CC_FOR_TARGET) -print-prog-name=nm ; \
+ else \
+ if [ '$(host)' = '$(target)' ] ; then \
+ echo $(NM); \
+ else \
+ echo nm | sed '$(program_transform_name)' ; \
+ fi; \
+ fi`
+
+RANLIB_FOR_TARGET=@RANLIB_FOR_TARGET@
+USUAL_RANLIB_FOR_TARGET = ` \
+ if [ -f $$r/binutils/ranlib ] ; then \
+ echo $$r/binutils/ranlib ; \
+ else \
+ if [ '$(host)' = '$(target)' ] ; then \
+ if [ x'$(RANLIB)' != x ]; then \
+ echo $(RANLIB); \
+ else \
+ echo ranlib; \
+ fi; \
+ else \
+ echo ranlib | sed '$(program_transform_name)' ; \
+ fi; \
+ fi`
+
+WINDRES_FOR_TARGET=@WINDRES_FOR_TARGET@
+USUAL_WINDRES_FOR_TARGET = ` \
+ if [ -f $$r/binutils/windres ] ; then \
+ echo $$r/binutils/windres ; \
+ else \
+ if [ '$(host)' = '$(target)' ] ; then \
+ echo $(WINDRES); \
+ else \
+ echo windres | sed '$(program_transform_name)' ; \
+ fi; \
+ fi`
+
+PICFLAG_FOR_TARGET =
+
+# ------------------------------------
+# Miscellaneous targets and flag lists
+# ------------------------------------
+
+# The first rule in the file had better be this one. Don't put any above it.
+# This lives here to allow makefile fragments to contain dependencies.
+all: all.normal
+.PHONY: all
+
+#### host and target specific makefile fragments come in here.
+@target_makefile_frag@
+@alphaieee_frag@
+@ospace_frag@
+@host_makefile_frag@
+###
+
+# Flags to pass down to all sub-makes.
+BASE_FLAGS_TO_PASS = [+ FOR flags_to_pass +]\
+ "[+flag+]=$([+flag+])" [+ ENDFOR flags_to_pass +]\
+ "CONFIG_SHELL=$(SHELL)" \
+ "MAKEINFO=$(MAKEINFO) $(MAKEINFOFLAGS)"
+
+# For any flags above that may contain shell code that varies from one
+# target library to another. When doing recursive invocations of the
+# top-level Makefile, we don't want the outer make to evaluate them,
+# so we pass these variables down unchanged. They must not contain
+# single nor double quotes.
+RECURSE_FLAGS = \
+ CXX_FOR_TARGET='$(CXX_FOR_TARGET_FOR_RECURSIVE_MAKE)' \
+ RAW_CXX_FOR_TARGET='$(RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE)' \
+
+# Flags to pass down to most sub-makes, in which we're building with
+# the host environment.
+EXTRA_HOST_FLAGS = \
+ 'AR=$(AR)' \
+ 'AS=$(AS)' \
+ 'CC=$(CC)' \
+ 'CXX=$(CXX)' \
+ 'DLLTOOL=$(DLLTOOL)' \
+ 'LD=$(LD)' \
+ 'NM=$(NM)' \
+ 'RANLIB=$(RANLIB)' \
+ 'WINDRES=$(WINDRES)'
+
+FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_HOST_FLAGS)
+
+# Flags that are concerned with the location of the X11 include files
+# and library files
+#
+# NOTE: until the top-level is getting the values via autoconf, it only
+# causes problems to have this top-level Makefile overriding the autoconf-set
+# values in child directories. Only variables that don't conflict with
+# autoconf'ed ones should be passed by X11_FLAGS_TO_PASS for now.
+#
+X11_FLAGS_TO_PASS = \
+ 'X11_EXTRA_CFLAGS=$(X11_EXTRA_CFLAGS)' \
+ 'X11_EXTRA_LIBS=$(X11_EXTRA_LIBS)'
+
+# Flags to pass down to makes which are built with the target environment.
+# The double $ decreases the length of the command line; the variables
+# are set in BASE_FLAGS_TO_PASS, and the sub-make will expand them.
+EXTRA_TARGET_FLAGS = \
+ 'AR=$$(AR_FOR_TARGET)' \
+ 'AS=$$(AS_FOR_TARGET)' \
+ 'CC=$$(CC_FOR_TARGET)' \
+ 'CFLAGS=$$(CFLAGS_FOR_TARGET)' \
+ 'CXX=$$(CXX_FOR_TARGET)' \
+ 'CXXFLAGS=$$(CXXFLAGS_FOR_TARGET)' \
+ 'DLLTOOL=$$(DLLTOOL_FOR_TARGET)' \
+ 'LD=$$(LD_FOR_TARGET)' \
+ 'LIBCFLAGS=$$(LIBCFLAGS_FOR_TARGET)' \
+ 'LIBCXXFLAGS=$$(LIBCXXFLAGS_FOR_TARGET)' \
+ 'NM=$$(NM_FOR_TARGET)' \
+ 'RANLIB=$$(RANLIB_FOR_TARGET)' \
+ 'WINDRES=$$(WINDRES_FOR_TARGET)'
+
+TARGET_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_TARGET_FLAGS)
+
+# Flags to pass down to gcc. gcc builds a library, libgcc.a, so it
+# unfortunately needs the native compiler and the target ar and
+# ranlib.
+# If any variables are added here, they must be added to do-*, below.
+# The BUILD_* variables are a special case, which are used for the gcc
+# cross-building scheme.
+EXTRA_GCC_FLAGS = \
+ 'BUILD_PREFIX=$(BUILD_PREFIX)' \
+ 'BUILD_PREFIX_1=$(BUILD_PREFIX_1)' \
+ "GCC_FOR_TARGET=$(GCC_FOR_TARGET)" \
+ "CFLAGS_FOR_BUILD=$(CFLAGS_FOR_BUILD)" \
+ "`echo 'LANGUAGES=$(LANGUAGES)' | sed -e s/.*=$$/XFOO=/`" \
+ "`echo 'STMP_FIXPROTO=$(STMP_FIXPROTO)' | sed -e s/.*=$$/XFOO=/`" \
+ "`echo 'LIMITS_H_TEST=$(LIMITS_H_TEST)' | sed -e s/.*=$$/XFOO=/`" \
+ "`echo 'LIBGCC2_CFLAGS=$(LIBGCC2_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
+ "`echo 'LIBGCC2_DEBUG_CFLAGS=$(LIBGCC2_DEBUG_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
+ "`echo 'LIBGCC2_INCLUDES=$(LIBGCC2_INCLUDES)' | sed -e s/.*=$$/XFOO=/`" \
+ "`echo 'STAGE1_CFLAGS=$(STAGE1_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
+ "`echo 'BOOT_CFLAGS=$(BOOT_CFLAGS)' | sed -e s/.*=$$/XFOO=/`" \
+ "`echo 'BOOT_ADAFLAGS=$(BOOT_ADAFLAGS)' | sed -e s/.*=$$/XFOO=/`"
+
+GCC_FLAGS_TO_PASS = $(BASE_FLAGS_TO_PASS) $(EXTRA_HOST_FLAGS) $(EXTRA_GCC_FLAGS)
+
+.PHONY: configure-host
+configure-host: maybe-configure-gcc [+
+ FOR host_modules +] \
+ maybe-configure-[+module+][+
+ ENDFOR host_modules +]
+.PHONY: configure-target
+configure-target: [+
+ FOR target_modules +] \
+ maybe-configure-target-[+module+][+
+ ENDFOR target_modules +]
+
+# The target built for a native build.
+.PHONY: all.normal
+all.normal: @all_build_modules@ all-host all-target
+
+.PHONY: all-host
+all-host: maybe-all-gcc [+
+ FOR host_modules +] \
+ maybe-all-[+module+][+
+ ENDFOR host_modules +]
+.PHONY: all-target
+all-target: [+
+ FOR target_modules +] \
+ maybe-all-target-[+module+][+
+ ENDFOR target_modules +]
+
+# Do a target for all the subdirectories. A ``make do-X'' will do a
+# ``make X'' in all subdirectories (because, in general, there is a
+# dependency (below) of X upon do-X, a ``make X'' will also do this,
+# but it may do additional work as well).
+[+ FOR recursive_targets +]
+.PHONY: do-[+make_target+]
+do-[+make_target+]: [+make_target+]-host [+make_target+]-target
+
+.PHONY: [+make_target+]-host
+[+make_target+]-host: maybe-[+make_target+]-gcc [+
+ FOR host_modules +] \
+ maybe-[+make_target+]-[+module+][+
+ ENDFOR host_modules +]
+
+.PHONY: [+make_target+]-target
+[+make_target+]-target: [+
+ FOR target_modules +] \
+ maybe-[+make_target+]-target-[+module+][+
+ ENDFOR target_modules +]
+
+# GCC, the eternal special case
+.PHONY: maybe-[+make_target+]-gcc [+make_target+]-gcc
+maybe-[+make_target+]-gcc:
+[+make_target+]-gcc: [+
+ FOR depend +]\
+ [+depend+]-gcc [+
+ ENDFOR depend +]
+ @[ -f ./gcc/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_GCC_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing [+make_target+] in gcc" ; \
+ (cd gcc && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ [+make_target+]) \
+ || exit 1
+
+# Host modules.
+[+ FOR host_modules +]
+.PHONY: maybe-[+make_target+]-[+module+] [+make_target+]-[+module+]
+maybe-[+make_target+]-[+module+]:
+[+ IF (match-value? = "missing" (get "make_target") ) +]
+# [+module+] doesn't support [+make_target+].
+[+make_target+]-[+module+]:
+[+ ELSE +]
+[+make_target+]-[+module+]: [+
+ FOR depend +]\
+ [+depend+]-[+module+] [+
+ ENDFOR depend +]
+ @[ -f ./[+module+]/Makefile ] || exit 0; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ for flag in $(EXTRA_HOST_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ echo "Doing [+make_target+] in [+module+]" ; \
+ (cd [+module+] && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ [+make_target+]) \
+ || exit 1
+[+ ENDIF +]
+[+ ENDFOR host_modules +]
+
+# Target modules.
+[+ FOR target_modules +]
+.PHONY: maybe-[+make_target+]-target-[+module+] [+make_target+]-target-[+module+]
+maybe-[+make_target+]-target-[+module+]:
+[+ IF (match-value? = "missing" (get "make_target") ) +]
+# [+module+] doesn't support [+make_target+].
+[+make_target+]-target-[+module+]:
+[+ ELSE +]
+[+make_target+]-target-[+module+]: [+
+ FOR depend +]\
+ [+depend+]-target-[+module+] [+
+ ENDFOR depend +]
+ @[ -f $(TARGET_SUBDIR)/[+module+]/Makefile ] || exit 0 ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Doing [+make_target+] in $(TARGET_SUBDIR)/[+module+]" ; \
+ for flag in $(EXTRA_TARGET_FLAGS); do \
+ eval `echo "$$flag" | sed -e "s|^\([^=]*\)=\(.*\)|\1='\2'; export \1|"`; \
+ done; \
+ (cd $(TARGET_SUBDIR)/[+module+] && \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) "AR=$${AR}" "AS=$${AS}" \
+ "CC=$${CC}" "CXX=$${CXX}" "LD=$${LD}" "NM=$${NM}" \
+ "RANLIB=$${RANLIB}" \
+ "DLLTOOL=$${DLLTOOL}" "WINDRES=$${WINDRES}" \
+ [+make_target+]) \
+ || exit 1
+[+ ENDIF +]
+[+ ENDFOR target_modules +]
+[+ ENDFOR recursive_targets +]
+
+# Here are the targets which correspond to the do-X targets.
+
+.PHONY: info installcheck dvi install-info
+.PHONY: clean distclean mostlyclean maintainer-clean realclean
+.PHONY: local-clean local-distclean local-maintainer-clean
+info: do-info
+installcheck: do-installcheck
+dvi: do-dvi
+
+# Make sure makeinfo is built before we do a `make info', if we're
+# in fact building texinfo.
+do-info: maybe-all-texinfo
+
+install-info: do-install-info dir.info
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ if [ -f dir.info ] ; then \
+ $(INSTALL_DATA) dir.info $(DESTDIR)$(infodir)/dir.info ; \
+ else true ; fi
+
+local-clean:
+ -rm -f *.a TEMP errs core *.o *~ \#* TAGS *.E *.log
+
+local-distclean:
+ -rm -f Makefile config.status config.cache mh-frag mt-frag
+ -rm -f multilib.out multilib.tmp maybedep.tmp serdep.tmp
+ -if [ "$(TARGET_SUBDIR)" != "." ]; then \
+ rm -rf $(TARGET_SUBDIR); \
+ else true; fi
+ -rm -rf $(BUILD_SUBDIR)
+ -rm -f texinfo/po/Makefile texinfo/po/Makefile.in texinfo/info/Makefile
+ -rm -f texinfo/doc/Makefile texinfo/po/POTFILES
+ -rmdir texinfo/doc texinfo/info texinfo/intl texinfo/lib 2>/dev/null
+ -rmdir texinfo/makeinfo texinfo/po texinfo/util 2>/dev/null
+ -rmdir fastjar gcc libiberty texinfo zlib 2>/dev/null
+
+local-maintainer-clean:
+ @echo "This command is intended for maintainers to use;"
+ @echo "it deletes files that may require special tools to rebuild."
+
+clean: do-clean local-clean
+mostlyclean: do-mostlyclean local-clean
+distclean: do-distclean local-clean local-distclean
+maintainer-clean: local-maintainer-clean do-maintainer-clean local-clean
+maintainer-clean: local-distclean
+realclean: maintainer-clean
+
+# Extra dependency for clean-target, owing to the mixed nature of gcc
+clean-target: clean-target-libgcc
+clean-target-libgcc:
+ test ! -d gcc/libgcc || \
+ (cd gcc/libgcc && find . -type d -print) | \
+ while read d; do rm -f gcc/$$d/libgcc.a || : ; done
+ -rm -rf gcc/libgcc
+
+# Check target.
+
+.PHONY: check do-check
+check: do-check
+
+# Only include modules actually being configured and built.
+do-check: maybe-check-gcc [+
+ FOR host_modules +] \
+ maybe-check-[+module+][+
+ ENDFOR host_modules +][+
+ FOR target_modules +] \
+ maybe-check-target-[+module+][+
+ ENDFOR target_modules +]
+
+# Automated reporting of test results.
+
+warning.log: build.log
+ $(srcdir)/contrib/warn_summary build.log > $@
+
+mail-report.log:
+ if test x'$(BOOT_CFLAGS)' != x''; then \
+ BOOT_CFLAGS='$(BOOT_CFLAGS)'; export BOOT_CFLAGS; \
+ fi; \
+ $(srcdir)/contrib/test_summary -t >$@
+ chmod +x $@
+ echo If you really want to send e-mail, run ./$@ now
+
+mail-report-with-warnings.log: warning.log
+ if test x'$(BOOT_CFLAGS)' != x''; then \
+ BOOT_CFLAGS='$(BOOT_CFLAGS)'; export BOOT_CFLAGS; \
+ fi; \
+ $(srcdir)/contrib/test_summary -t -i warning.log >$@
+ chmod +x $@
+ echo If you really want to send e-mail, run ./$@ now
+
+# Installation targets.
+
+.PHONY: install uninstall
+install: installdirs install-host install-target
+
+.PHONY: install-host-nogcc
+install-host-nogcc: [+
+ FOR host_modules +] \
+ maybe-install-[+module+][+
+ ENDFOR host_modules +]
+
+.PHONY: install-host
+install-host: maybe-install-gcc [+
+ FOR host_modules +] \
+ maybe-install-[+module+][+
+ ENDFOR host_modules +]
+
+.PHONY: install-target
+install-target: [+
+ FOR target_modules +] \
+ maybe-install-target-[+module+][+
+ ENDFOR target_modules +]
+
+uninstall:
+ @echo "the uninstall target is not supported in this tree"
+
+.PHONY: install.all
+install.all: install-no-fixedincludes
+ @if [ -f ./gcc/Makefile ] ; then \
+ r=`${PWD_COMMAND}` ; export r ; \
+ $(SET_LIB_PATH) \
+ (cd ./gcc && \
+ $(MAKE) $(FLAGS_TO_PASS) install-headers) ; \
+ else \
+ true ; \
+ fi
+
+# install-no-fixedincludes is used because Cygnus can not distribute
+# the fixed header files.
+.PHONY: install-no-fixedincludes
+install-no-fixedincludes: installdirs install-host-nogcc \
+ install-target gcc-no-fixedincludes
+
+### other supporting targets
+
+MAKEDIRS= \
+ $(DESTDIR)$(prefix) \
+ $(DESTDIR)$(exec_prefix)
+.PHONY: installdirs
+installdirs: mkinstalldirs
+ $(SHELL) $(srcdir)/mkinstalldirs $(MAKEDIRS)
+
+dir.info: do-install-info
+ if [ -f $(srcdir)/texinfo/gen-info-dir ] ; then \
+ $(srcdir)/texinfo/gen-info-dir $(DESTDIR)$(infodir) $(srcdir)/texinfo/dir.info-template > dir.info.new ; \
+ mv -f dir.info.new dir.info ; \
+ else true ; \
+ fi
+
+dist:
+ @echo "Building a full distribution of this tree isn't done"
+ @echo "via 'make dist'. Check out the etc/ subdirectory"
+
+etags tags: TAGS
+
+# Right now this just builds TAGS in each subdirectory. emacs19 has the
+# ability to use several tags files at once, so there is probably no need
+# to combine them into one big TAGS file (like CVS 1.3 does). We could
+# (if we felt like it) have this Makefile write a piece of elisp which
+# the user could load to tell emacs19 where all the TAGS files we just
+# built are.
+TAGS: do-TAGS
+
+# --------------------------------------
+# Modules which run on the build machine
+# --------------------------------------
+[+ FOR build_modules +]
+.PHONY: configure-build-[+module+] maybe-configure-build-[+module+]
+maybe-configure-build-[+module+]:
+configure-build-[+module+]:
+ @test ! -f $(BUILD_SUBDIR)/[+module+]/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(BUILD_SUBDIR)/[+module+] ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ AR="$(AR_FOR_BUILD)"; export AR; \
+ AS="$(AS_FOR_BUILD)"; export AS; \
+ CC="$(CC_FOR_BUILD)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_BUILD)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX_FOR_BUILD)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS_FOR_BUILD)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_BUILD)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_BUILD)"; export DLLTOOL; \
+ LD="$(LD_FOR_BUILD)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_BUILD)"; export LDFLAGS; \
+ NM="$(NM_FOR_BUILD)"; export NM; \
+ RANLIB="$(RANLIB_FOR_BUILD)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_BUILD)"; export WINDRES; \
+ echo Configuring in $(BUILD_SUBDIR)/[+module+]; \
+ cd "$(BUILD_SUBDIR)/[+module+]" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(BUILD_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \
+ if [ "$(srcdir)" = "." ] ; then \
+ if [ "$(BUILD_SUBDIR)" != "." ] ; then \
+ if $(SHELL) $$s/symlink-tree $${topdir}/[+module+] "no-such-file" ; then \
+ if [ -f Makefile ]; then \
+ if $(MAKE) distclean; then \
+ true; \
+ else \
+ exit 1; \
+ fi; \
+ else \
+ true; \
+ fi; \
+ else \
+ exit 1; \
+ fi; \
+ else \
+ true; \
+ fi; \
+ srcdiroption="--srcdir=."; \
+ libsrcdir="."; \
+ else \
+ srcdiroption="--srcdir=$${topdir}/[+module+]"; \
+ libsrcdir="$$s/[+module+]"; \
+ fi; \
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(BUILD_CONFIGARGS) $${srcdiroption} \
+ --with-build-subdir="$(BUILD_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-build-[+module+] maybe-all-build-[+module+]
+maybe-all-build-[+module+]:
+all-build-[+module+]: configure-build-[+module+]
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ (cd $(BUILD_SUBDIR)/[+module+] && $(MAKE) all)
+[+ ENDFOR build_modules +]
+
+# --------------------------------------
+# Modules which run on the host machine
+# --------------------------------------
+[+ FOR host_modules +]
+.PHONY: configure-[+module+] maybe-configure-[+module+]
+maybe-configure-[+module+]:
+configure-[+module+]:
+ @test ! -f [+module+]/Makefile || exit 0; \
+ [ -d [+module+] ] || mkdir [+module+]; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in [+module+]; \
+ cd [+module+] || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/[+module+]"; \
+ libsrcdir="$$s/[+module+]";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/[+module+]"; \
+ libsrcdir="$$s/[+module+]";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+.PHONY: all-[+module+] maybe-all-[+module+]
+maybe-all-[+module+]:
+all-[+module+]: configure-[+module+]
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd [+module+] && $(MAKE) $(FLAGS_TO_PASS)[+
+ IF with_x
+ +] $(X11_FLAGS_TO_PASS)[+
+ ENDIF with_x +] all)
+
+.PHONY: check-[+module+] maybe-check-[+module+]
+maybe-check-[+module+]:
+[+ IF no_check +]
+check-[+module+]:
+[+ ELIF no_check_cross +]
+# This module is only tested in a native toolchain.
+check-[+module+]:
+ @if [ '$(host)' = '$(target)' ] ; then \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd [+module+] && $(MAKE) $(FLAGS_TO_PASS)[+
+ IF with_x
+ +] $(X11_FLAGS_TO_PASS)[+
+ ENDIF with_x +] check); \
+ fi
+[+ ELSE check +]
+check-[+module+]:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd [+module+] && $(MAKE) $(FLAGS_TO_PASS)[+
+ IF with_x
+ +] $(X11_FLAGS_TO_PASS)[+
+ ENDIF with_x +] check)
+[+ ENDIF no_check +]
+
+.PHONY: install-[+module+] maybe-install-[+module+]
+maybe-install-[+module+]:
+[+ IF no_install +]
+install-[+module+]:
+[+ ELSE install +]
+install-[+module+]: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd [+module+] && $(MAKE) $(FLAGS_TO_PASS)[+
+ IF with_x
+ +] $(X11_FLAGS_TO_PASS)[+
+ ENDIF with_x +] install)
+[+ ENDIF no_install +]
+[+ ENDFOR host_modules +]
+
+# ---------------------------------------
+# Modules which run on the target machine
+# ---------------------------------------
+[+ FOR target_modules +]
+.PHONY: configure-target-[+module+] maybe-configure-target-[+module+]
+maybe-configure-target-[+module+]:
+
+# There's only one multilib.out. Cleverer subdirs shouldn't need it copied.
+$(TARGET_SUBDIR)/[+module+]/multilib.out: multilib.out
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/[+module+] ; \
+ rm -f $(TARGET_SUBDIR)/[+module+]/Makefile || : ; \
+ cp multilib.out $(TARGET_SUBDIR)/[+module+]/multilib.out
+
+configure-target-[+module+]: $(TARGET_SUBDIR)/[+module+]/multilib.out
+ @test ! -f $(TARGET_SUBDIR)/[+module+]/Makefile || exit 0; \
+ $(SHELL) $(srcdir)/mkinstalldirs $(TARGET_SUBDIR)/[+module+] ; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ AR="$(AR_FOR_TARGET)"; export AR; \
+ AS="$(AS_FOR_TARGET)"; export AS; \
+ CC="$(CC_FOR_TARGET)"; export CC; \
+ CFLAGS="$(CFLAGS_FOR_TARGET)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CPPFLAGS="$(CFLAGS_FOR_TARGET)"; export CPPFLAGS; \[+
+IF raw_cxx +]
+ CXX_FOR_TARGET="$(RAW_CXX_FOR_TARGET)"; export CXX_FOR_TARGET; \
+ CXX="$(RAW_CXX_FOR_TARGET)"; export CXX; \[+
+ELSE normal_cxx +]
+ CXX="$(CXX_FOR_TARGET)"; export CXX; \[+
+ENDIF raw_cxx +]
+ CXXFLAGS="$(CXXFLAGS_FOR_TARGET)"; export CXXFLAGS; \
+ GCJ="$(GCJ_FOR_TARGET)"; export GCJ; \
+ DLLTOOL="$(DLLTOOL_FOR_TARGET)"; export DLLTOOL; \
+ LD="$(LD_FOR_TARGET)"; export LD; \
+ LDFLAGS="$(LDFLAGS_FOR_TARGET)"; export LDFLAGS; \
+ NM="$(NM_FOR_TARGET)"; export NM; \
+ RANLIB="$(RANLIB_FOR_TARGET)"; export RANLIB; \
+ WINDRES="$(WINDRES_FOR_TARGET)"; export WINDRES; \
+ echo Configuring in $(TARGET_SUBDIR)/[+module+]; \
+ cd "$(TARGET_SUBDIR)/[+module+]" || exit 1; \
+ case $(srcdir) in \
+ /* | [A-Za-z]:[\\/]*) \
+ topdir=$(srcdir) ;; \
+ *) \
+ case "$(TARGET_SUBDIR)" in \
+ .) topdir="../$(srcdir)" ;; \
+ *) topdir="../../$(srcdir)" ;; \
+ esac ;; \
+ esac; \[+ IF stage +]
+ if [ "$(srcdir)" = "." ] ; then \
+ if [ "$(TARGET_SUBDIR)" != "." ] ; then \
+ if $(SHELL) $$s/symlink-tree $${topdir}/[+module+] "no-such-file" ; then \
+ if [ -f Makefile ]; then \
+ if $(MAKE) distclean; then \
+ true; \
+ else \
+ exit 1; \
+ fi; \
+ else \
+ true; \
+ fi; \
+ else \
+ exit 1; \
+ fi; \
+ else \
+ true; \
+ fi; \
+ srcdiroption="--srcdir=."; \
+ libsrcdir="."; \
+ else \[+ ENDIF stage +]
+ srcdiroption="--srcdir=$${topdir}/[+module+]"; \
+ libsrcdir="$$s/[+module+]"; \[+ IF stage +]
+ fi; \[+ ENDIF stage +]
+ rm -f no-such-file || : ; \
+ CONFIG_SITE=no-such-file $(SHELL) $${libsrcdir}/configure \
+ $(TARGET_CONFIGARGS) $${srcdiroption} \
+ --with-target-subdir="$(TARGET_SUBDIR)" \
+ || exit 1
+
+.PHONY: all-target-[+module+] maybe-all-target-[+module+]
+maybe-all-target-[+module+]:
+all-target-[+module+]: configure-target-[+module+]
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/[+module+] && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) [+
+ IF raw_cxx
+ +] 'CXX=$$(RAW_CXX_FOR_TARGET)' 'CXX_FOR_TARGET=$$(RAW_CXX_FOR_TARGET)' [+
+ ENDIF raw_cxx
+ +] all)
+
+.PHONY: check-target-[+module+] maybe-check-target-[+module+]
+maybe-check-target-[+module+]:
+[+ IF no_check +]
+# Dummy target for uncheckable module.
+check-target-[+module+]:
+[+ ELSE check +]
+check-target-[+module+]:
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/[+module+] && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) [+
+ IF raw_cxx
+ +] 'CXX=$$(RAW_CXX_FOR_TARGET)' 'CXX_FOR_TARGET=$$(RAW_CXX_FOR_TARGET)' [+
+ ENDIF raw_cxx
+ +] check)
+[+ ENDIF no_check +]
+
+.PHONY: install-target-[+module+] maybe-install-target-[+module+]
+maybe-install-target-[+module+]:
+[+ IF no_install +]
+# Dummy target for uninstallable.
+install-target-[+module+]:
+[+ ELSE install +]
+install-target-[+module+]: installdirs
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd $(TARGET_SUBDIR)/[+module+] && \
+ $(MAKE) $(TARGET_FLAGS_TO_PASS) install)
+[+ ENDIF no_install +]
+[+ ENDFOR target_modules +]
+
+# ----------
+# GCC module
+# ----------
+
+# Unfortunately, while gcc _should_ be a host module,
+# libgcc is a target module, and gen* programs are
+# build modules. So GCC is a sort of hybrid.
+
+# gcc is the only module which uses GCC_FLAGS_TO_PASS.
+# Don't use shared host config.cache, as it will confuse later
+# directories; GCC wants slightly different values for some
+# precious variables. *sigh*
+.PHONY: configure-gcc maybe-configure-gcc
+maybe-configure-gcc:
+configure-gcc:
+ @test ! -f gcc/Makefile || exit 0; \
+ [ -d gcc ] || mkdir gcc; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ CC="$(CC)"; export CC; \
+ CFLAGS="$(CFLAGS)"; export CFLAGS; \
+ CONFIG_SHELL="$(SHELL)"; export CONFIG_SHELL; \
+ CXX="$(CXX)"; export CXX; \
+ CXXFLAGS="$(CXXFLAGS)"; export CXXFLAGS; \
+ TOPLEVEL_CONFIGURE_ARGUMENTS="$(TOPLEVEL_CONFIGURE_ARGUMENTS)"; export TOPLEVEL_CONFIGURE_ARGUMENTS; \
+ AR="$(AR)"; export AR; \
+ AS="$(AS)"; export AS; \
+ CC_FOR_BUILD="$(CC_FOR_BUILD)"; export CC_FOR_BUILD; \
+ DLLTOOL="$(DLLTOOL)"; export DLLTOOL; \
+ LD="$(LD)"; export LD; \
+ LDFLAGS="$(LDFLAGS)"; export LDFLAGS; \
+ NM="$(NM)"; export NM; \
+ RANLIB="$(RANLIB)"; export RANLIB; \
+ WINDRES="$(WINDRES)"; export WINDRES; \
+ OBJCOPY="$(OBJCOPY)"; export OBJCOPY; \
+ OBJDUMP="$(OBJDUMP)"; export OBJDUMP; \
+ echo Configuring in gcc; \
+ cd gcc || exit 1; \
+ case $(srcdir) in \
+ \.) \
+ srcdiroption="--srcdir=."; \
+ libsrcdir=".";; \
+ /* | [A-Za-z]:[\\/]*) \
+ srcdiroption="--srcdir=$(srcdir)/gcc"; \
+ libsrcdir="$$s/gcc";; \
+ *) \
+ srcdiroption="--srcdir=../$(srcdir)/gcc"; \
+ libsrcdir="$$s/gcc";; \
+ esac; \
+ $(SHELL) $${libsrcdir}/configure \
+ $(HOST_CONFIGARGS) $${srcdiroption} \
+ || exit 1
+
+# Don't 'make all' in gcc if it's already been made by 'bootstrap'; that
+# causes trouble. This wart will be fixed eventually by moving
+# the bootstrap behavior to this file.
+.PHONY: all-gcc maybe-all-gcc
+maybe-all-gcc:
+all-gcc: configure-gcc
+ @if [ -f gcc/stage_last ] ; then \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) quickstrap); \
+ else \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) all); \
+ fi
+
+# Building GCC uses some tools for rebuilding "source" files
+# like texinfo, bison/byacc, etc. So we must depend on those.
+#
+# While building GCC, it may be necessary to run various target
+# programs like the assembler, linker, etc. So we depend on
+# those too.
+#
+# In theory, on an SMP all those dependencies can be resolved
+# in parallel.
+#
+GCC_STRAP_TARGETS = bootstrap bootstrap-lean bootstrap2 bootstrap2-lean bootstrap3 bootstrap3-lean bootstrap4 bootstrap4-lean bubblestrap quickstrap cleanstrap restrap
+.PHONY: $(GCC_STRAP_TARGETS)
+$(GCC_STRAP_TARGETS): all-bootstrap configure-gcc
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Bootstrapping the compiler"; \
+ cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) $@
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ case "$@" in \
+ *bootstrap4-lean ) \
+ msg="Comparing stage3 and stage4 of the compiler"; \
+ compare=compare3-lean ;; \
+ *bootstrap4 ) \
+ msg="Comparing stage3 and stage4 of the compiler"; \
+ compare=compare3 ;; \
+ *-lean ) \
+ msg="Comparing stage2 and stage3 of the compiler"; \
+ compare=compare-lean ;; \
+ * ) \
+ msg="Comparing stage2 and stage3 of the compiler"; \
+ compare=compare ;; \
+ esac; \
+ $(SET_LIB_PATH) \
+ echo "$$msg"; \
+ cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) $$compare
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
+ $(SET_LIB_PATH) \
+ echo "Building runtime libraries"; \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) $(RECURSE_FLAGS) all
+
+profiledbootstrap: all-bootstrap configure-gcc
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Bootstrapping the compiler"; \
+ cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) stageprofile_build
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
+ $(SET_LIB_PATH) \
+ echo "Building runtime libraries and training compiler"; \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) $(RECURSE_FLAGS) all
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Building feedback based compiler"; \
+ cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) stagefeedback_build
+
+.PHONY: cross
+cross: all-texinfo all-bison all-byacc all-binutils all-gas all-ld
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ echo "Building the C and C++ compiler"; \
+ cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) LANGUAGES="c c++"
+ @r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
+ $(SET_LIB_PATH) \
+ echo "Building runtime libraries"; \
+ $(MAKE) $(BASE_FLAGS_TO_PASS) $(RECURSE_FLAGS) \
+ LANGUAGES="c c++" all
+
+.PHONY: check-gcc maybe-check-gcc
+maybe-check-gcc:
+check-gcc:
+ @if [ -f ./gcc/Makefile ] ; then \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) check); \
+ else \
+ true; \
+ fi
+
+.PHONY: check-gcc-c++
+check-gcc-c++:
+ @if [ -f ./gcc/Makefile ] ; then \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) check-c++); \
+ else \
+ true; \
+ fi
+
+.PHONY: check-c++
+check-c++: check-target-libstdc++-v3 check-gcc-c++
+
+.PHONY: install-gcc maybe-install-gcc
+maybe-install-gcc:
+install-gcc:
+ @if [ -f ./gcc/Makefile ] ; then \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}`; export s; \
+ $(SET_LIB_PATH) \
+ (cd gcc && $(MAKE) $(GCC_FLAGS_TO_PASS) install); \
+ else \
+ true; \
+ fi
+
+# Install the gcc headers files, but not the fixed include files,
+# which Cygnus is not allowed to distribute. This rule is very
+# dependent on the workings of the gcc Makefile.in.
+.PHONY: gcc-no-fixedincludes
+gcc-no-fixedincludes:
+ @if [ -f ./gcc/Makefile ]; then \
+ rm -rf gcc/tmp-include; \
+ mv gcc/include gcc/tmp-include 2>/dev/null; \
+ mkdir gcc/include; \
+ cp $(srcdir)/gcc/gsyslimits.h gcc/include/syslimits.h; \
+ touch gcc/stmp-fixinc gcc/include/fixed; \
+ rm -f gcc/stmp-headers gcc/stmp-int-hdrs; \
+ r=`${PWD_COMMAND}`; export r; \
+ s=`cd $(srcdir); ${PWD_COMMAND}` ; export s; \
+ $(SET_LIB_PATH) \
+ (cd ./gcc && \
+ $(MAKE) $(GCC_FLAGS_TO_PASS) install); \
+ rm -rf gcc/include; \
+ mv gcc/tmp-include gcc/include 2>/dev/null; \
+ else true; fi
+
+# --------------------------------------
+# Dependencies between different modules
+# --------------------------------------
+
+# There are two types of dependencies here: 'hard' dependencies, where one
+# module simply won't build without the other; and 'soft' dependencies, where
+# if the depended-on module is missing, the depending module will do without
+# or find a substitute somewhere (perhaps installed). Soft dependencies
+# are specified by depending on a 'maybe-' target. If you're not sure,
+# it's safer to use a soft dependency.
+
+# Host modules specific to gcc.
+# GCC needs to identify certain tools.
+# GCC also needs the information exported by the intl configure script.
+configure-gcc: maybe-configure-intl maybe-configure-binutils maybe-configure-gas maybe-configure-ld maybe-configure-bison maybe-configure-flex
+all-gcc: maybe-all-libiberty maybe-all-intl maybe-all-bison maybe-all-byacc maybe-all-binutils maybe-all-gas maybe-all-ld maybe-all-zlib
+# This is a slightly kludgy method of getting dependencies on
+# all-build-libiberty correct; it would be better to build it every time.
+all-gcc: maybe-all-build-libiberty
+all-bootstrap: maybe-all-libiberty maybe-all-intl maybe-all-texinfo maybe-all-bison maybe-all-byacc maybe-all-binutils maybe-all-gas maybe-all-ld maybe-all-zlib
+
+# Host modules specific to gdb.
+# GDB needs to know that the simulator is being built.
+configure-gdb: maybe-configure-itcl maybe-configure-tcl maybe-configure-tk maybe-configure-sim
+GDB_TK = @GDB_TK@
+all-gdb: maybe-all-libiberty maybe-all-opcodes maybe-all-bfd maybe-all-mmalloc maybe-all-readline maybe-all-bison maybe-all-byacc maybe-all-sim $(gdbnlmrequirements) $(GDB_TK)
+install-gdb: maybe-install-tcl maybe-install-tk maybe-install-itcl maybe-install-tix maybe-install-libgui
+configure-libgui: maybe-configure-tcl maybe-configure-tk
+all-libgui: maybe-all-tcl maybe-all-tk maybe-all-itcl
+
+# Host modules specific to binutils.
+configure-bfd: configure-libiberty
+all-bfd: maybe-all-libiberty maybe-all-intl
+all-binutils: maybe-all-libiberty maybe-all-opcodes maybe-all-bfd maybe-all-flex maybe-all-bison maybe-all-byacc maybe-all-intl
+# We put install-opcodes before install-binutils because the installed
+# binutils might be on PATH, and they might need the shared opcodes
+# library.
+install-binutils: maybe-install-opcodes
+# libopcodes depends on libbfd
+install-opcodes: maybe-install-bfd
+all-gas: maybe-all-libiberty maybe-all-opcodes maybe-all-bfd maybe-all-intl
+all-gprof: maybe-all-libiberty maybe-all-bfd maybe-all-opcodes maybe-all-intl
+all-ld: maybe-all-libiberty maybe-all-bfd maybe-all-opcodes maybe-all-bison maybe-all-byacc maybe-all-flex maybe-all-intl
+all-opcodes: maybe-all-bfd maybe-all-libiberty
+
+# Other host modules in the 'src' repository.
+all-dejagnu: maybe-all-tcl maybe-all-expect maybe-all-tk
+configure-expect: maybe-configure-tcl maybe-configure-tk
+all-expect: maybe-all-tcl maybe-all-tk
+configure-itcl: maybe-configure-tcl maybe-configure-tk
+all-itcl: maybe-all-tcl maybe-all-tk
+# We put install-tcl before install-itcl because itcl wants to run a
+# program on installation which uses the Tcl libraries.
+install-itcl: maybe-install-tcl
+all-sid: maybe-all-libiberty maybe-all-bfd maybe-all-opcodes maybe-all-tcl maybe-all-tk
+install-sid: maybe-install-tcl maybe-install-tk
+all-sim: maybe-all-libiberty maybe-all-bfd maybe-all-opcodes maybe-all-readline maybe-configure-gdb
+configure-tk: maybe-configure-tcl
+all-tk: maybe-all-tcl
+configure-tix: maybe-configure-tcl maybe-configure-tk
+all-tix: maybe-all-tcl maybe-all-tk
+all-texinfo: maybe-all-libiberty
+
+# Other host modules. Warning, these are not well tested.
+all-autoconf: maybe-all-m4 maybe-all-texinfo
+all-automake: maybe-all-m4 maybe-all-texinfo
+all-bison: maybe-all-texinfo
+all-diff: maybe-all-libiberty
+all-fastjar: maybe-all-zlib maybe-all-libiberty
+all-fileutils: maybe-all-libiberty
+all-flex: maybe-all-libiberty maybe-all-bison maybe-all-byacc
+all-gzip: maybe-all-libiberty
+all-hello: maybe-all-libiberty
+all-m4: maybe-all-libiberty maybe-all-texinfo
+all-make: maybe-all-libiberty maybe-all-intl
+all-patch: maybe-all-libiberty
+all-prms: maybe-all-libiberty
+all-recode: maybe-all-libiberty
+all-sed: maybe-all-libiberty
+all-send-pr: maybe-all-prms
+all-tar: maybe-all-libiberty
+all-uudecode: maybe-all-libiberty
+
+ALL_GCC = maybe-all-gcc
+ALL_GCC_C = $(ALL_GCC) maybe-all-target-newlib maybe-all-target-libgloss
+ALL_GCC_CXX = $(ALL_GCC_C) maybe-all-target-libstdc++-v3
+
+# Target modules specific to gcc.
+configure-target-boehm-gc: $(ALL_GCC_C) maybe-configure-target-qthreads
+configure-target-fastjar: maybe-configure-target-zlib
+all-target-fastjar: maybe-all-target-zlib maybe-all-target-libiberty
+configure-target-libf2c: $(ALL_GCC_C)
+all-target-libf2c: maybe-all-target-libiberty
+configure-target-libffi: $(ALL_GCC_C)
+configure-target-libjava: $(ALL_GCC_C) maybe-configure-target-zlib maybe-configure-target-boehm-gc maybe-configure-target-qthreads maybe-configure-target-libffi
+all-target-libjava: maybe-all-fastjar maybe-all-target-zlib maybe-all-target-boehm-gc maybe-all-target-qthreads maybe-all-target-libffi
+configure-target-libobjc: $(ALL_GCC_C)
+all-target-libobjc: maybe-all-target-libiberty
+configure-target-libstdc++-v3: $(ALL_GCC_C)
+all-target-libstdc++-v3: maybe-all-target-libiberty
+configure-target-zlib: $(ALL_GCC_C)
+
+# Target modules in the 'src' repository.
+configure-target-examples: $(ALL_GCC_C)
+configure-target-libgloss: $(ALL_GCC)
+all-target-libgloss: maybe-configure-target-newlib
+configure-target-libiberty: $(ALL_GCC)
+configure-target-libtermcap: $(ALL_GCC_C)
+configure-target-newlib: $(ALL_GCC)
+configure-target-rda: $(ALL_GCC_C)
+configure-target-winsup: $(ALL_GCC_C)
+all-target-winsup: maybe-all-target-libiberty maybe-all-target-libtermcap
+
+# Other target modules. Warning, these are not well tested.
+configure-target-gperf: $(ALL_GCC_CXX)
+all-target-gperf: maybe-all-target-libiberty maybe-all-target-libstdc++-v3
+configure-target-qthreads: $(ALL_GCC_C)
+
+# Dependencies of maybe-foo on foo. These are used because, for example,
+# all-gcc only depends on all-gas if gas is present and being configured.
+@maybe_dependencies@
+
+# Serialization dependencies. Host configures don't work well in parallel to
+# each other, due to contention over config.cache. Target configures and
+# build configures are similar.
+@serialization_dependencies@
+
+# --------------------------------
+# Regenerating top level configury
+# --------------------------------
+
+# Multilib.out tells target dirs what multilibs they should build.
+# There is really only one copy. We use the 'timestamp' method to
+# work around various timestamp bugs on some systems.
+# We use move-if-change so that it's only considered updated when it
+# actually changes, because it has to depend on a phony target.
+multilib.out: maybe-all-gcc
+ @r=`${PWD_COMMAND}`; export r; \
+ echo "Checking multilib configuration..."; \
+ $(CC_FOR_TARGET) --print-multi-lib > multilib.tmp 2> /dev/null ; \
+ $(SHELL) $(srcdir)/move-if-change multilib.tmp multilib.out ; \
+
+# Rebuilding Makefile.in, using autogen.
+AUTOGEN = autogen
+$(srcdir)/Makefile.in: @MAINT@ $(srcdir)/Makefile.tpl $(srcdir)/Makefile.def
+ cd $(srcdir) && $(AUTOGEN) Makefile.def
+
+# Rebuilding Makefile.
+Makefile: $(srcdir)/Makefile.in config.status
+ CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
+
+config.status: configure $(gcc_version_trigger)
+ CONFIG_SHELL="$(SHELL)" $(SHELL) ./config.status --recheck
+
+# Rebuilding configure.
+AUTOCONF = autoconf
+$(srcdir)/configure: @MAINT@ $(srcdir)/configure.in $(srcdir)/config/acx.m4
+ cd $(srcdir) && $(AUTOCONF)
+
+# ------------------------------
+# Special directives to GNU Make
+# ------------------------------
+
+# Don't pass command-line variables to submakes.
+.NOEXPORT:
+MAKEOVERRIDES=
+
+# end of Makefile.in
diff --git a/contrib/binutils/README-maintainer-mode b/contrib/binutils/README-maintainer-mode
index fbe508f..0115a1e 100644
--- a/contrib/binutils/README-maintainer-mode
+++ b/contrib/binutils/README-maintainer-mode
@@ -3,7 +3,7 @@
Note that if you configure with --enable-maintainer-mode, you will need
special versions of automake, autoconf, libtool and gettext. You will
-find the sources for these in ftp://sourceware.cygnus.com/pub/binutils.
+find the sources for these in ftp://sources.redhat.com/pub/binutils.
Note - "make distclean" does not work with maintainer mode enabled.
The Makefiles in the some of the po/ subdirectories depend upon the
diff --git a/contrib/binutils/bfd/ChangeLog b/contrib/binutils/bfd/ChangeLog
index 6c92f76..04a27e1 100644
--- a/contrib/binutils/bfd/ChangeLog
+++ b/contrib/binutils/bfd/ChangeLog
@@ -1,4632 +1,1233 @@
-2002-11-27 David O'Brien <obrien@FreeBSD.org>
+2004-05-17 Daniel Jacobowitz <dan@debian.org>
- * elf.c (_bfd_elf_copy_private_section_data): Don't define bed.
-
-2002-11-21 Richard Henderson <rth@redhat.com>
-
- * elflink.h (elf_link_add_object_symbols): Don't overwrite the
- arch's st_other bits when merging visibilities.
- (elf_link_output_extsym): Tidy clearing of visibility field.
-
-2002-11-14 David O'Brien <obrien@FreeBSD.org>
-
- Merge from mainline:
- 2002-11-12 Thomas Moestl <tmm@FreeBSD.org>
- * elf64-sparc.c (sparc64_elf_adjust_dynamic_symbol): Correct
- references to large plt symbols.
-
-2002-11-13 Alan Modra <amodra@bigpond.net.au>
-
- Merge from mainline.
- 2002-11-07 Alan Modra <amodra@bigpond.net.au>
- * elf64-ppc.c: Comment typo fixes.
- (ppc64_elf_merge_private_bfd_data): Allow BFD_ENDIAN_UNKNOWN input.
-
-2002-11-11 Nick Clifton <nickc@redhat.com>
-
- Import this patch from mainline:
-
- 2002-09-19 Nick Clifton <nickc@redhat.com>
-
- * elflink.h (elf_fix_symbol_flags): When examining weak symbols,
- follow indirect links.
-
-2002-11-07 Daniel Jacobowitz <drow@mvista.com>
-
- * configure.in: Clear is_release on the branch after release.
-
-2002-11-07 Daniel Jacobowitz <drow@mvista.com>
-
- * configure.in: Bump version and set is_release.
+ * configure.in: Mark unreleased for post-2.15 snapshots.
* configure: Regenerate.
-2002-11-07 Nick Clifton <nickc@redhat.com>
-
- * po/da.po: Updated Danish translation.
-
-2002-11-07 Graeme Peterson <gp@qnx.com>
-
- * Makefile.am: Removed entries for elf32-i386qnx.c and
- elf32-i386qnx.lo.
- * Makefile.in: Regenerate.
- * config.bfd: Changed i[3456]86-*-nto-qnx* targ_defvec from
- bfd_elf32_i386qnx_vec to bfd_elf32_i386_vec.
- * configure.in: Removed support for bfd_elf32_i386qnx_vec.
- * configure: Regenerate.
- * elf32-i386qnx.c: Removed.
- * elf.c: Removed calls to QNX specific set_nonloadable_filepos,
- is_contained_by_filepos, and copy_private_bfd_data_p.
- * elf32-i386.c: Removed QNX specific #ifdef ELF32_I386_C_INCLUDED.
- * targets.c: Removed bfd_elf32_i386qnx_vec.
- * elfxx-target.h: Removed QNX specific elf_backend_set_nonloadable_filepos,
- elf_backend_is_contained_by_filepos, and elf_backend_copy_private_bfd_data_p.
- * elf-bfd.h: Removed QNX specific set_nonloadable_filepos,
- is_contained_by_filepos, and copy_private_bfd_data_p.
-
-2002-11-06 David O'Brien <obrien@FreeBSD.org>
- Alan Modra <amodra@bigpond.net.au>
-
- * elf64-sparc.c (sparc64_elf_relocate_section): Adjust addend of
- dynamic relocs against section symbols for the output section vma.
-
-2002-11-05 Elias Athanasopoulos <eathan@otenet.gr>
-
- * vms-gsd.c (_bfd_vms_write_gsd): Check that symbol->udata.p is
- non-NULL before dereferencing.
-
-2002-11-04 Kaz Kojima <kkojima@rr.iij4u.or.jp>
-
- * vms.c (vms_object_p): Restore the start address when returning
- NULL.
-
-2002-10-31 David O'Brien <obrien@FreeBSD.org>
-
- * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't mix
- signed and unsigned in comparison.
-
-2002-10-30 Daniel Jacobowitz <drow@mvista.com>
-
- * bfd-in2.h: Regenerated.
- * po/SRC-POTFILES.in: Regenerated.
- * po/bfd.pot: Regenerated.
-
-2002-10-30 Daniel Jacobowitz <drow@mvista.com>
+2004-05-17 Daniel Jacobowitz <dan@debian.org>
- * coffcode.h: Remove extraneous '\'.
-
-2002-10-28 Daniel Jacobowitz <drow@mvista.com>
-
- Merge from mainline:
- 2002-10-24 John David Anglin <dave@hiauly1.hia.nrc.ca>
- * aoutx.h (NAME(aout,swap_ext_reloc_in)): Cast bytes->r_index to
- unsigned int. Cast RELOC_BASE10, RELOC_BASE13 and RELOC_BASE22 to
- unsigned int.
- (NAME(aout,final_link)): Cast enum used in assignment.
- (aout_link_write_symbols): Cast enums in comparisons, int values to
- boolean, enums in assignments to int.
- (aout_link_input_section_std): Cast rel->r_index to unsigned int.
- (aout_link_input_section_ext): Likewise. Cast enums used in comparisons
- with unsigned ints.
- (aout_link_reloc_link_order): Cast enum to int in assignment.
- * archive.c (_bfd_generic_read_ar_hdr_mag): Cast result of memchr
- calls to char *.
- * bfd-in.h (bfd_set_section_vma): Cast enum true to unsigned int in
- assignment.
- * bfd-in2.h (bfd_set_section_vma): Likewise.
- * bfd.c (bfd_record_phdr): Cast enums in assignments.
- * binary.c (bfd_alloc): Cast enum to long.
- * coffgen.c (_bfd_coff_is_local_label_name): Cast return to boolean.
- * dwarf2.c (read_abbrevs): Add casts to enum types.
- (read_attribute_value): Likewise.
- (arange_add): Cast result of bfd_zalloc call.
- (comp_unit_contains_address): Return true and false.
- (comp_unit_find_nearest_line): Cast return to boolean.
- * format.c (bfd_check_format_matches, bfd_set_format): Likewise.
- * gen-aout.c: define macro '_' if not defined.
- * libbfd.c (bfd_realloc): Cast malloc and realloc to PTR.
- (bfd_bwrite): Cast bfd_realloc to bfd_byte *.
- (bfd_write_bigendian_4byte_int): Cast return to boolean.
- (bfd_seek): Cast bfd_realloc to bfd_byte *.
- (bfd_generic_is_local_label_name): Cast return to boolean.
- * libcoff.h (_bfd_coff_adjust_symndx): Remove extraneous '\'.
- * linker.c (_bfd_link_hash_newfunc): Cast bfd_hash_allocate result to
- struct bfd_hash_entry *.
- (_bfd_generic_link_hash_newfunc): likewise.
- (_bfd_generic_final_link): Cast enum to unsigned int.
- * merge.c (sec_merge_emit): Cast return to boolean.
- (merge_strings): Add casts to const unsigned char *.
- * reloc.c (bfd_get_reloc_code_name): Cast enums in comparison to int.
- (bfd_generic_get_relocated_section_content): Cast enum to unsigned int.
- * section.c (bfd_section_hash_newfunc): Cast bfd_hash_allocate result to
- struct bfd_hash_entry *.
- (bfd_set_section_content): Add cast to PTR in comparison.
- * srec.c (S3Forced): Initialize to false.
- (srec_get_symtab): Cast return value from bfd_alloc to asymbol *.
- * stabs.c (_bfd_link_section_stabs): Cast enum to int in comparisons.
- (_bfd_discard_section_stabs): Likewise. Also cast return to boolean.
- * syms.c (bfd_is_undefined_symclass): Cast return to boolean.
- (_bfd_stab_section_find_nearest_line): Cast enum to bfd_byte in
- comparisons.
-
- 2002-10-23 Jakub Jelinek <jakub@redhat.com>
- * elf64-alpha.c (elf64_alpha_check_relocs): Only put maybe_dynamic
- relocs into shared lib non-allocated reloc sections.
-
- 2002-10-23 Nathan Tallent <eraxxon@alumni.rice.edu>
- * dwarf2.c (add_line_info): Ensure that the line_info_table is
- sorted even when given an out-of-order line sequence.
- (lookup_address_in_line_info_table): When an exact VMA match is
- not found, return line information with the closest VMA.
-
- 2002-10-21 Alan Modra <amodra@bigpond.net.au>
- * targets.c (bfd_target_list): Don't return the default target twice.
-
- 2002-10-19 H.J. Lu <hjl@gnu.org>
- * elflink.h (elf_link_add_object_symbols): Correctly handle
- DT_RPATH and DT_RUNPATH.
-
- 2002-10-16 Jakub Jelinek <jakub@redhat.com>
- * config.bfd (s390-*-linux*): Add targ64_selvecs.
- (s390x-*-linux*): Add targ_selvecs.
-
- 2002-10-16 Alan Modra <amodra@bigpond.net.au>
- * elflink.h (elf_link_add_object_symbols): Error out on dynamic objects
- loaded with --just-symbols.
-
- * elf32-i386qnx.c (TARGET_LITTLE_NAME): Define.
-
- 2002-10-14 Kaz Kojima <kkojima@rr.iij4u.or.jp>
- * config.bfd (sh*eb-*-linux*, sh*-*-linux*): Add the alternative
- endian vector to targ_selvecs.
-
- 2002-10-08 H.J. Lu <hjl@gnu.org>
- * elf32-i386.c (elf_i386_relocate_section): Re-arrange the
- IE->LE transition for R_386_TLS_IE.
-
- 2002-10-07 Mark Elbrecht <snowball3@softhome.net>
- * cofflink.c (mark_relocs): Don't mark relocations in excluded
- sections.
-
- 2002-10-05 Alexandre Oliva <aoliva@redhat.com>
- * elfxx-mips.c (mips_elf_create_dynamic_relocation): Set the type
- of the other two relocations packed with a REL32 to NONE.
-
- 2002-10-02 Stephen Clarke <stephen.clarke@superh.com>
- * elf32-sh.c (elf_sh_link_hash_entry): Add gotplt_refcount.
- (sh_elf_link_hash_newfunc): Initialize it.
- (allocate_dynrelocs): Transfer gotplt refs from plt.refcount
- to got.refcount for symbols that are forced local or when
- we have direct got refs.
- (sh_elf_gc_sweep_hook): Adjust gotplt_refcount. Use it
- to correctly adjust got.refcount and plt.refcount.
- (sh_elf_copy_indirect_symbol): Copy gotplt_refcount across.
- (sh_elf_check_relocs): Increment gotplt_refcount.
-
- 2002-10-01 Jakub Jelinek <jakub@redhat.com>
- * elf32-i386.c (elf_i386_relocate_section): Fix
- movl foo@indntpoff, %eax IE->LE transition.
-
- 2002-09-28 Jason Thorpe <thorpej@wasabisystems.com>
- * elf32-vax.c (elf_vax_size_dynamic_section): Don't strip
- .got sections.
-
- 2002-09-27 Matt Thomas <matt@3am-software.com>
- * elf32-vax.c (elf_vax_check_relocs): Remove unused
- local_got_refcounts usage. Remove allocation of got slot.
- (elf_vax_gc_sweep_hook): Remove unused local_got_refcounts usage.
- Remove de-allocation of got slot.
- (elf_vax_size_dynamic_section): Fix some indentation. Add hash
- traversal for elf_vax_instantiate_got_entries. Allow empty .got
- sections to be GC'ed.
- (elf_vax_instantiate_got_entries): New function.
- (elf_vax_relocate_section): Simplify R_VAX_GOT32 handling. Remove
- tests that are now handled by elf_vax_instantiate_got_entries.
- Assert GOT entry falls within .got section size. Remove redundant
- comparisions. Fix comments.
-
- 2002-09-24 Jakub Jelinek <jakub@redhat.com>
- * elf32-sparc.c (elf32_sparc_relocate_section): Put R_SPARC_RELATIVE
- addend into r_addend, not *r_offset.
- (elf32_sparc_finish_dynamic_symbol): Likewise.
- * elf64-sparc.c (sparc64_elf_finish_dynamic_symbol): Clear xword at
- R_SPARC_RELATIVE's r_offset.
-
- 2002-08-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
- * elfxx-mips.c (mips_elf_create_dynamic_relocation): Cast signedness
- mismatch.
-
-2002-10-14 Richard Henderson <rth@redhat.com>
-
- * elf64-alpha.c (elf64_alpha_relocate_section) [BRSGP]: Increment
- VALUE, not ADDEND.
-
-2002-10-11 Alan Modra <amodra@bigpond.net.au>
-
- * coff-arm.c (record_arm_to_thumb_glue): Avoid type-punned pointers.
- (record_thumb_to_arm_glue): Likewise.
- * ecoff.c (ecoff_link_add_externals): Likewise.
- * elf32-arm.h (record_arm_to_thumb_glue): Likewise.
- (record_thumb_to_arm_glue): Likewise.
- * elf32-m32r.c (m32r_elf_add_symbol_hook): Likewise.
- * elf32-sh.c (sh_elf_create_dynamic_sections): Likewise.
- * elf32-sh64.c (sh64_elf_add_symbol_hook): Likewise.
- * elf64-alpha.c (elf64_alpha_create_dynamic_sections): Likewise.
- * elf64-ppc.c (func_desc_adjust): Likewise.
- * elf64-sh64.c (sh64_elf64_add_symbol_hook): Likewise.
- (sh64_elf64_create_dynamic_sections): Likewise.
- * elflink.c (_bfd_elf_create_got_section): Likewise.
- (_bfd_elf_create_dynamic_sections): Likewise.
- (_bfd_elf_create_linker_section): Likewise.
- * elflink.h (elf_add_default_symbol): Likewise.
- (elf_link_create_dynamic_sections): Likewise.
- (NAME(bfd_elf,size_dynamic_sections)): Likewise.
- * elfxx-ia64.c (elfNN_ia64_aix_add_symbol_hook): Likewise.
- * elfxx-mips.c (mips_elf_create_got_section): Likewise.
- (_bfd_mips_elf_add_symbol_hook): Likewise.
- (_bfd_mips_elf_create_dynamic_sections): Likewise.
- * linker.c (generic_link_add_symbol_list): Likewise.
- * xcofflink.c (xcoff_link_add_symbols): Likewise.
-
- * elfxx-ia64.c (oor_brl, oor_ip): Conditionally define.
-
- * elf64-ppc.c (edit_opd): Only zero opd syms when function is
- completely removed. Correct local sym adjustment.
-
-2002-10-08 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (edit_opd): Correct test for discarded sections.
-
-2002-10-07 Alan Modra <amodra@bigpond.net.au>
-
- * elflink.h (elf_link_input_bfd): Remove BFD_VERSION_DATE dependent
- code.
-
- * elf64-ppc.c (ppc64_elf_build_stubs): Increment .glink indx.
-
-2002-09-28 Alan Modra <amodra@bigpond.net.au>
-
- * elf.c (map_sections_to_segments): Correct test for start of
- writable section in the same page as end of read-only section.
-
-2002-09-26 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (ppc_build_one_stub): Don't build glink stubs here.
- (ppc64_elf_build_stubs): Build them here instead.
-
-2002-09-23 Daniel Jacobowitz <drow@mvista.com>
-
- Merge from mainline:
- 2002-09-23 Alan Modra <amodra@bigpond.net.au>
- * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Zero relocs
- for discarded FDEs. Remove redundant assignment.
- * elflink.h (elf_bfd_discard_info): Save edited relocs.
-
- 2002-09-23 Nathan Tallent <eraxxon@alumni.rice.edu>
- * dwarf2.c (decode_line_info): Update to correctly decode
- the (non-standard DWARF2) out-of-order address sequences
- generated by the Intel C++ 6.0 compiler for ia64-Linux.
-
- 2002-09-22 H.J. Lu <hjl@gnu.org>
- * elf64-alpha.c (elf64_alpha_merge_ind_symbols): Don't merge
- the relocation count between different .reloc sections.
-
- 2002-09-22 Mark Elbrecht <snowball3@softhome.net>
- * config.bfd: For DJGPP targets, match with any cpu and any machine.
-
- 2002-09-21 Alan Modra <amodra@bigpond.net.au>
- * elfcode.h (elf_slurp_reloc_table_from_section): Make "symcount"
- unsigned. Move "symcount" assignment out of loop.
-
- 2002-09-19 Nathan Tallent <eraxxon@alumni.rice.edu>
- * dwarf2.c (_bfd_dwarf2_find_nearest_line): If address length is
- zero, set it to 8 for (non-standard) 64-bit DWARF2 formats
- (e.g. IRIX64).
-
- 2002-09-19 Jakub Jelinek <jakub@redhat.com>
- * reloc.c (BFD_RELOC_386_TLS_TPOFF, BFD_RELOC_386_TLS_IE,
- BFD_RELOC_386_TLS_GOTIE): Add.
- * bfd-in2.h, libbfd.h: Rebuilt.
- * elf32-i386.c (elf_howto_table): Add R_386_TLS_TPOFF, R_386_TLS_IE
- and R_386_TLS_GOTIE.
- (elf_i386_reloc_type_lookup): Handle it.
- (struct elf_i386_link_hash_entry): Change tls_type type to unsigned
- char instead of enum, change GOT_* into defines.
- (GOT_TLS_IE_POS, GOT_TLS_IE_NEG, GOT_TLS_IE_BOTH): Define.
- (elf_i386_tls_transition): Handle R_386_TLS_IE and R_386_TLS_GOTIE.
- (elf_i386_check_relocs): Likewise. Avoid crash if local symbol is
- accessed both as normal and TLS symbol. Move R_386_TLS_LDM and
- R_386_PLT32 cases so that R_386_TLS_IE can fall through.
- Handle R_386_TLS_LE_32 and R_386_TLS_LE in shared libs.
- (elf_i386_gc_sweep_hook): Handle R_386_TLS_IE and R_386_TLS_GOTIE.
- Handle R_386_TLS_LE_32 and R_386_TLS_LE in shared libs.
- (allocate_dynrelocs): Allocate 2 .got and 2 .rel.got entries if
- tls_type is GOT_TLS_IE_BOTH.
- (elf_i386_size_dynamic_sections): Likewise.
- (elf_i386_relocate_section): Handle R_386_TLS_IE and R_386_TLS_GOTIE.
- Handle R_386_TLS_LE_32 and R_386_TLS_LE in shared libs.
- (elf_i386_finish_dynamic_symbol): Use tls_type & GOT_TLS_IE to catch
- all 4 GOT_TLS_* TLS types.
-
- 2002-09-18 Daniel Jacobowitz <drow@mvista.com>
- * elfcode.h (elf_slurp_reloc_table_from_section): Check
- correct relocation count.
-
- 2002-09-17 Daniel Jacobowitz <drow@mvista.com>
- * bfd-in.h (bfd_get_dynamic_symcount): Define.
- * bfd.c (struct _bfd): Add dynsymcount.
- * bfd-in2.h: Regenerated.
- * elf.c (_bfd_elf_canonicalize_dynamic_symtab): Set
- abfd->dynsymcount.
- * elfcode.h (elf_slurp_reloc_table_from_section): Check
- for overflow.
-
- 2002-09-17 Alan Modra <amodra@bigpond.net.au>
- * elf64-alpha.c (alpha_elf_size_info): Make static.
-
- 2002-09-17 Jakub Jelinek <jakub@redhat.com>
- * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Clear .got word
- even if generating R_PPC_RELATIVE reloc.
- (ppc_elf_relocate_section): Make sure relocation is performed if
- skip == -2. Clear memory at r_offset when creating dynamic
- relocation.
-
- 2002-09-16 David O'Brien <obrien@FreeBSD.org>
- * elf32-i386-fbsd.c: Always label using the EI_OSABI method.
- It is benign for FreeBSD < 4.1. Minor reformatting.
- * elf64-alpha-fbsd.c: Likewise.
-
- 2002-09-16 Nathan Tallent <eraxxon@alumni.rice.edu>
- * ecoff.c (_bfd_ecoff_slurp_symbolic_info) <ioptMax>: Fix error
- reading ECOFF information: 'ioptMax' refers to the actual *size*
- of the optimization symtab, not the number of entries.
-
- 2002-09-16 Jakub Jelinek <jakub@redhat.com>
- * elf_i386_relocate_section (R_386_TLS_TPOFF32): Negate addend.
-
- 2002-09-13 Daniel Jacobowitz <drow@mvista.com>
- * elf32-arm.h (elf32_arm_adjust_dynamic_symbol): Update
- ELF_LINK_HASH_NEEDS_PLT logic.
-
- 2002-09-11 Nick Clifton <nickc@redhat.com>
- * po/da.po: New Danish translation file.
- * configure.in (LINGUAS): Add 'da'.
+ * configure.in: Bump version to 2.15. Mark as released.
* configure: Regenerate.
- 2002-09-11 Jakub Jelinek <jakub@redhat.com>
- * elf32-i386.c (dtpoff_base, tpoff): Don't crash if tls_segment is
- NULL.
- (elf_i386_relocate_section): Return false after printing error about
- unresolvable relocation.
-
- 2002-09-11 Jeffrey Law <law@redhat.com>
- * elf32-h8300.c (elf32_h8_relax_section): Fix typo.
-
- 2002-09-06 Andrew Haley <aph@cambridge.redhat.com>
- * elf.c (_bfd_elf_find_nearest_line): Check functionname_ptr and
- line_ptr before deciding we've found a symbol.
-
- 2002-08-29 John David Anglin <dave@hiauly1.hia.nrc.ca>
- * bfd-in.h (align_power): Cast constants to bfd_vma type.
- * bfd-in2.h (align_power): Likewise.
-
- 2002-08-24 Kaz Kojima <kkojima@rr.iij4u.or.jp>
- * elf32-sh.c (sh_elf_copy_indirect_symbol): New.
- (create_got_section, allocate_dynrelocs, readonly_dynrelocs):
- Likewise.
- (struct elf_sh_pcrel_relocs_copied): Removed.
- (struct elf_sh_dyn_relocs): New.
- (struct elf_sh_link_hash_entry): Replace pcrel_relocs_copied
- field with dyn_relocs.
- (struct elf_sh_link_hash_table): Add short-cuts to get dynamic
- sections and sym_sec.
- (sh_elf_link_hash_newfunc): Clear dyn_relocs.
- (sh_elf_link_hash_table_create): Clear shorts-cuts and sym_sec.
- (sh_elf_create_dynamic_sections): Use create_got_section instead
- of _bfd_elf_create_got_section.
- (sh_elf_check_relocs): Likewise.
- (sh_elf_create_dynamic_sections): Use short-cuts to the dynamic
- sections.
- (sh_elf_adjust_dynamic_symbol, sh_elf_size_dynamic_sections,
- sh_elf_relocate_section, sh_elf_check_relocs,
- sh_elf_finish_dynamic_symbol, sh_elf_finish_dynamic_sections):
- Likewise.
- (sh_elf_adjust_dynamic_symbol): Handle nocopyreloc. Keep the
- dynamic relocations and avoiding the copy relocation when we
- didn't find any dynamic relocations in the section which has
- contents or is read-only.
- (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
- (sh_elf_size_dynamic_sections): Don't reset the size of
- .rela.got section even if dynamic_sections_created flag is off.
- Don't use sh_elf_discard_copies. Scan all input bfd and use
- allocate_dynrelocs. Call readonly_dynrelocs to determine
- whether we need DT_TEXTREL.
- (sh_elf_adjust_dynamic_symbol): Use plt.refcount to determine
- whether the symbol was never referred to.
- (sh_elf_relocate_section): Use WILL_CALL_FINISH_DYNAMIC_SYMBOL.
- (sh_elf_gc_sweep_hook): Fill with the real sweep function.
- (sh_elf_check_relocs): Call create_got_section if the short-cut
- to .got is null. Increment reference counters only instead of
- allocating space on dynamic sections here. Don't conditionalize
- uninitialized got.offset value when marking the symbol as a
- global offset table entry. Keep relocations for symbols satisfied
- by a dynamic library to avoid copy relocations for the symbol.
- Set dynobj field of an elf hash table if needed.
- (sh_elf_finish_dynamic_sections): Handle null section pointer
- correctly.
- (elf_backend_copy_indirect_symbol): Defined.
- (elf_backend_can_refcount): Defined.
-
- 2002-08-22 Nick Clifton <nickc@redhat.com>
- * po/tr.po: Updated Turkish translation.
-
- 2002-08-21 Stephen Clarke <stephen.clarke@superh.com>
- * bfd/elf32-sh.c (sh_elf_size_dynamic_sections): Zero
- initialize dynamic section.
- * bfd/elf64-sh64.c (sh64_elf64_size_dynamic_sections):
- Likewise.
-
- 2002-08-13 H.J. Lu <hjl@gnu.org>
- * elflink.h (NAME(bfd_elf,size_dynamic_sections): Don't count
- definitions in shared objects when checking symbol with
- undefined version.
-
- 2002-08-10 H.J. Lu <hjl@gnu.org>
- * elflink.h (elf_add_default_symbol): Preserve section across
- elf_merge_symbol.
-
- 2002-08-09 Nick Clifton <nickc@redhat.com>
- * po/sv.po: Updated Swedish translation.
-
- 2002-08-08 Alan Modra <amodra@bigpond.net.au>
- * elflink.h (elf_link_output_extsym): Don't output symbols from
- SEC_EXCLUDE sections.
-
- * aoutx.h (aout_link_write_symbols): Correct handling of warning syms.
-
- 2002-08-08 H.J. Lu <hjl@gnu.org>
- * elflink.h (elf_add_default_symbol): Don't warn a defintion
- overrides an indirect versioned symbol.
-
- 2002-08-07 Alan Modra <amodra@bigpond.net.au>
- * elf64-ppc.c (edit_opd): Arrange to drop symbols for discarded .opd
- entries.
-
- 2002-08-07 Jakub Jelinek <jakub@redhat.com>
- * elf32-i386.c (elf_i386_relocate_section): Fill in proper addend
- for R_386_TLS_TPOFF32 relocs against symndx 0.
-
- 2002-08-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
- * elfxx-mips.c (mips_elf_global_got_index): Avoid segfault if
- g->global_gotsym is NULL.
-
- 2002-08-06 Alan Modra <amodra@bigpond.net.au>
- * xcofflink.c (xcoff_write_global_symbol): Set n_scnum for abs_section.
-
- 2002-08-06 Alan Modra <amodra@bigpond.net.au>
- * elf64-ppc.c (ppc64_elf_howto_raw): Zero all src_mask entries.
-
- 2002-08-06 H.J. Lu <hjl@gnu.org>
- * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Check symbol
- with undefined version if needed.
- (elf_link_assign_sym_version): Match a default symbol with a
- version without definition. No need to hide the default
- definition separately.
-
- 2002-08-06 Alan Modra <amodra@bigpond.net.au>
- * coff-rs6000.c: Formatting fixes.
- (xcoff_calculate_relocation): Use PARAMS in declaration.
- (xcoff_complain_overflow): Likewise.
- (xcoff_ppc_relocate_section): Use old-style function pointer call.
- (bfd_xcoff_backend_data): Remove useless comments.
- (rs6000coff_vec): Likewise.
- (bfd_pmac_xcoff_backend_data): Likewise.
- (pmac_xcoff_vec): Likewise.
- * coff64-rs6000.c: Formatting fixes.
- (xcoff64_calculate_relocation): Use PARAMS in declaration.
- (xcoff64_ppc_relocate_section): Use old-style function pointer call.
- (bfd_xcoff_backend_data): Remove useless comments.
- (rs6000coff64_vec): Likewise.
- (bfd_xcoff_aix5_backend_data): Likewise.
- (aix5coff64_vec): Likewise.
-
- 2002-08-06 Alan Modra <amodra@bigpond.net.au>
- * coff-rs6000.c: (xcoff_rtype2howto): Don't place reloc address in
- addend.
- * coff64-rs6000.c: (xcoff64_rtype2howto): Likewise.
-
- 2002-08-06 Alan Modra <amodra@bigpond.net.au>
- * coff-rs6000.c (xcoff_howto_table): Revert some of last change to
- mask entries. Use complain_overflow_dont for R_REF.
- (xcoff_reloc_type_ba): Revert last change.
- (xcoff_reloc_type_br): Likewise.
- (xcoff_reloc_type_crel): Likewise.
- (xcoff_ppc_relocate_section): Likewise.
- * coff64-rs6000.c (xcoff64_reloc_type_br): Likewise.
- (xcoff64_ppc_relocate_section): Likewise.
- (xcoff64_howto_table): Revert some of last change to mask entries.
- Use complain_overflow_dont for R_REF.
-
- * coff-rs6000.c (xcoff_howto_table): Fix src_mask entries. Make all
- relocs with bitsize == 16 have size = 1.
- (xcoff_reloc_type_ba): Correct src_mask and dst_mask adjustment.
- (xcoff_reloc_type_br): Likewise.
- (xcoff_reloc_type_crel): Likewise.
- (xcoff_ppc_relocate_section): Set up src_mask and dst_mask correctly.
- * coff64-rs6000.c (xcoff64_reloc_type_br): Correct src_mask and
- dst_mask adjustment.
- (xcoff64_ppc_relocate_section): Set up src_mask and dst_mask correctly.
- (xcoff64_howto_table): Fix src_mask entries. Make all relocs with
- bitsize == 16 have size = 1.
-
- 2002-07-31 Nick Clifton <nickc@redhat.com>
- * bfd.c (bfd_alt_mach_code): Rename parameter 'index' to
- 'alternative' in order to avoid shadowing global symbol of the
- same name.
- * bfd-in2.h: Regenerate.
- * libbfd.h: Regenerate.
- * libcoff.h: Regenerate.
-
- 2002-07-30 Alan Modra <amodra@bigpond.net.au>
- * aoutx.h (some_aout_object_p): Clean up tdata properly on error.
- * archive.c (bfd_generic_archive_p): Likewise.
- * coff-rs6000.c (_bfd_xcoff_archive_p): Likewise.
- (_bfd_xcoff_archive_p): Use bfd_scan_vma in place of strtol.
- * coff64-rs6000.c (xcoff64_slurp_armap): Likewise.
- (xcoff64_archive_p): Likewise.
- (xcoff64_openr_next_archived_file): Likewise.
- (xcoff64_archive_p): Clean up tdata properly on error.
- * coffgen.c (coff_real_object_p): Likewise.
- (coff_object_p): Release filehdr and opthdr.
- * ecoff.c (_bfd_ecoff_archive_p): Clean up tdata properly on error.
- * ieee.c (ieee_archive_p): Likewise.
- * ihex.c (ihex_object_p): Likewise.
- (ihex_mkobject): Always allocate tdata.
- * peicode.h (pe_ILF_object_p): Release bfd_alloc'd buffer on error.
- * srec.c (srec_mkobject): Always allocate tdata.
- (srec_object_p): Clean up tdata properly on error.
- (symbolsrec_object_p): Likewise.
- * versados.c (versados_object_p): Likewise.
- * vms-misc.c (_bfd_vms_get_record): Use bfd_malloc instead of malloc,
- and bfd_realloc instead of realloc.
- (add_new_contents): Use bfd_alloc instead of bfd_malloc for sections.
- * vms.c (vms_initialize): Always allocate tdata. Use bfd_alloc in
- place of bfd_malloc, simplifying error freeing. Free hash table too.
- (vms_object_p): Clean up tdata on error.
- (vms_mkobject): Don't complain on stderr if vms_initialize fails.
- (vms_close_and_cleanup): Adjust for bfd_alloc use.
-
- 2002-07-17 Ian Rickards <irickard@arm.com>
- * dwarf2.c (concat_filename): If we can't establish the directory
- just return the filename.
-
- 2002-07-16 Alan Modra <amodra@bigpond.net.au>
- * elflink.h: Formatting fixes, tidy prototypes.
- (elf_link_assign_sym_version): Move common code out of loop.
-
- 2002-07-04 Bruno Haible <bruno@clisp.org>
- * elf32-i386.c: Don't defined ELF_ARCH etc. if this file is included
- by a target variant implementation.
- * elf64-alpha.c: Likewise.
- * elf32-i386-fbsd.c: New file.
- * elf64-alpha-fbsd.c: New file.
- * targets.c: Support bfd_elf32_i386_freebsd_vec and
- bfd_elf64_alpha_freebsd_vec.
- * configure.in: Accept the vectors bfd_elf32_i386_freebsd_vec,
- bfd_elf64_alpha_freebsd_vec.
- * Makefile.am (BFD32_BACKENDS): Add elf32-i386-fbsd.lo.
- (BFD32_BACKENDS_CFILES): Add elf32-i386-fbsd.c.
- (BFD64_BACKENDS): Add elf64-alpha-fbsd.lo.
- (BFD64_BACKENDS_CFILES): Add elf64-alpha-fbsd.c.
- (elf32-i386-fbsd.lo, elf64-alpha-fbsd.lo): Add dependencies.
- * config.bfd: For FreeBSD targets, set targ_defvec to a FreeBSD
- specific targets. Define OLD_FREEBSD_ABI_LABEL if appropriate.
-
-2002-09-21 David O'Brien <obrien@FreeBSD.org>
+2004-05-13 Joel Sherrill <joel@oarcorp.com>
- Merge from mainline:
- 2002-08-17 Andrew Cagney <ac131313@redhat.com>
- * elf.c (bfd_elf_get_elf_syms): Change type of `esym' to
- `bfd_byte'.
+ * config.bfd (or32-*-rtems*): Switch to elf.
-2002-08-26 Alan Modra <amodra@bigpond.net.au>
+2004-05-13 Nick Clifton <nickc@redhat.com>
- * coffcode.h (coff_set_arch_mach_hook): Handle W65MAGIC.
+ * po/fr.po: Updated French translation.
-2002-08-22 Alan Modra <amodra@bigpond.net.au>
+2004-05-07 Daniel Jacobowitz <dan@debian.org>
- * configure.in: Unset is_release.
+ * configure.in: Bump version to 2.14.92.
* configure: Regenerate.
- * elf-bfd.h (struct elf_backend_data): Add struct elf_backend_data
- param to elf_backend_copy_indirect_symbol.
- (_bfd_elf_link_hash_copy_indirect): Likewise.
- * elflink.h (elf_add_default_symbol, elf_fix_symbol_flags): Adjust
- calls to copy_indirect_symbol.
- * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Likewise.
- * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
- * elf32-s390.c (elf_s390_copy_indirect_symbol): Likewise.
- * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
- * elf64-s390.c (elf_s390_copy_indirect_symbol): Likewise.
- * elf64-x86-64.c (elf64_x86_64_copy_indirect_symbol): Likewise.
- * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
- * elfxx-mips.c (_bfd_mips_elf_copy_indirect_symbol): Likewise.
- * elfxx-mips.h (_bfd_mips_elf_copy_indirect_symbol): Likewise.
- * elf.c (_bfd_elf_link_hash_copy_indirect): Likewise. Properly
- test refcounts for "used" values.
-
-2002-08-15 Hans-Peter Nilsson <hp@axis.com>
-
- * elf32-cris.c (elf_cris_discard_excess_program_dynamics): Add
- missing check for whether the symbol is referenced by DSO before
- unexporting it as an unneeded dynamic symbol.
-
-2002-08-05 Daniel Jacobowitz <drow@mvista.com>
-
- * configure.in: Bump version, set is_release.
- * configure: Regenerated.
-
-2002-08-01 Daniel Jacobowitz <drow@mvista.com>
+2004-05-07 Daniel Jacobowitz <dan@debian.org>
Merge from mainline:
- 2002-07-31 Jakub Jelinek <jakub@redhat.com>
- * elf32-i386.c (elf_i386_copy_indirect_symbol): Swap tls_type
- if _bfd_elf_link_hash_copy_indirect will swap got.refcount.
-
-2002-07-30 Daniel Jacobowitz <drow@mvista.com>
+ 2004-04-16 Alan Modra <amodra@bigpond.net.au>
+ * simple.c (bfd_simple_get_relocated_section_contents): Don't
+ change reloc_done. Set and restore _cooked_size.
+ (RETURN): Delete.
+
+2004-05-07 Alexandre Oliva <aoliva@redhat.com>
+
+ * elf32-frv.c (elf32_frvfdpic_modify_segment_map): Return
+ immediately if there's no link info.
+ (elf32_frvfdpic_copy_private_bfd_data): New.
+ (bfd_elf32_bfd_copy_private_bfd_data): Use it for frvfdpic.
+
+2004-05-06 Zack Weinberg <zack@codesourcery.com>
+
+ * dwarf2.c (add_line_info): Also set info->filename to NULL if
+ filename argument is null; do not call strlen on a null pointer.
+
+2004-05-06 Daniel Jacobowitz <drow@mvista.com>
+
+ * elf32-arm.h (elf32_arm_relocate_section): Remove R_ARM_PLT32
+ special case.
+
+2004-05-05 Alexandre Oliva <aoliva@redhat.com>
+
+ * configure.in (bfd_elf32_frvfdpic_vec): New.
+ * configure: Rebuilt.
+ * targets.c (bfd_elf32_frvfdpic_vec): New.
+ * config.bfd: Enable it on frv-*-elf and frv-*-*linux*, as default
+ on the latter.
+ * elf32-frv.c: Prefix all identifiers added for FDPIC support with
+ frvfdpic instead of frv. Rearrange elf-target macros such that
+ the FDPIC-specific ones are only defined for this new target
+ vector.
+ (bfd_elf32_frvfdpic_vec): Declare.
+ (IS_FDPIC): New.
+ (elf32_frv_relocate_section): Use it to enable segment checking
+ and to control rofixup emission. Add output section vma to
+ applied relocation in non-LOAD non-ALLOC sections. Use
+ _bfd_error_handler for errors.
+ (_frv_create_got_section): Create .rel.got and .rofixup only in
+ FDPIC. Create non-dynamic _gp at .got+2048 in non-FDPIC, like the
+ linker script.
+ (elf32_frvfdpic_size_dynamic_sections): Assume FDPIC.
+ (elf32_frvfdpic_modify_segment_map): Likewise.
+ (elf32_frv_finish_dynamic_sections): New, do-nothing.
+ (elf32_frvfdpic_finish_dynamic_sections): Assume FDPIC. Improve
+ error message if we miscompute the rofixup size.
+ (frvfdpic_elf_use_relative_eh_frame): Assume FDPIC.
+ (frvfdpic_elf_encode_eh_address): Likewise.
+ (elf32_frv_check_relocs): Reject FDPIC-only relocs in non-FDPIC.
+ Record relocs only in FDPIC. Make sure _gp is defined for GPREL
+ relocs. Reject unknown relocation types.
+ (elf32_frv_object_p): Make sure target vector matches FDPIC bits.
+ (frv_elf_merge_private_bfd_data): Likewise.
+ (ELF_MAXPAGESIZE): Revert to 0x1000 for elf32-frv; keep it as
+ 0x4000 for newly-added elf32-frvfdpic.
+
+2004-05-05 Alexandre Oliva <aoliva@redhat.com>
Merge from mainline:
- 2002-07-30 Nick Clifton <nickc@redhat.com>
- * po/sv.po: Updated Swedish translation.
-
- 2002-07-30 Jakub Jelinek <jakub@redhat.com>
- * elf.c (elf_fake_sections): Fix up .tbss sh_size and sh_type.
-
- 2002-07-26 Chris Demetriou <cgd@broadcom.com>
- * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Merge ASE
- flags into resulting BFD.
-
- 2002-07-25 Alan Modra <amodra@bigpond.net.au>
- * elf-bfd.h (_bfd_elf32_link_record_local_dynamic_symbol): Define
- as elf_link_record_local_dynamic_symbol.
- (_bfd_elf64_link_record_local_dynamic_symbol): Likewise.
- (elf_link_record_local_dynamic_symbol): Declare. Now returns int.
- * elflink.h (elf_link_record_local_dynamic_symbol): Move to..
- * elflink.c: .. here. Use bfd_elf_get_elf_syms. Check whether an
- attempt is made to record a symbol in a discarded section, and
- return `2' in that case.
-
-2002-07-26 Alan Modra <amodra@bigpond.net.au>
-
- From John Reiser <jreiser@BitWagon.com>
- * elf32-i386.c (elf_i386_link_hash_table_create): Clear
- tls_ldm_got.refcount.
-
-2002-07-25 Nick Clifton <nickc@redhat.com>
-
- * po/sv.po: Updated Swedish translation.
- * po/es.po: Updated Spanish translation.
- * po/fr.po: Updated French translation.
-
-2002-07-24 Nick Clifton <nickc@redhat.com>
-
- * po/sv.po: Updated Swedish translation.
- * po/es.po: Updates Spanish translation.
-
-2002-07-23 Daniel Jacobowitz <drow@mvista.com>
-
- * configure.in: Bump version for snapshot.
- * configure: Regenerated.
-
-2002-07-23 Daniel Jacobowitz <drow@mvista.com>
-
- * po/bfd.pot: Regenerated.
-
-2002-07-23 Nick Clifton <nickc@redhat.com>
-
- * elf-bfd.h (struct elf_backend_data): Add new bitfield
- 'want_p_paddr_set_to_zero'.
- * elfxx-target.h: Set default value for want_p_paddr_set_to_zero
- to false;
- * elfxx-ia64.c: Set want_p_paddr_set_zero for HPUX target.
- * elf.c (copy_private_bfd_data): Test want_p_paddr_set_zero.
-
-2002-07-23 Gabor Keresztfalvi <keresztg@mail.com>
-
- * nlmcode.h (nlm_swap_auxiliary_headers_out): Swapped the order of
- the MeSsAgEs and CoPyRiGhT tags to make >=NW4.x NLM loaders to
- show the Copyright string.
-
-2002-07-23 Nick Clifton <nickc@redhat.com>
-
- * po/fr.po: New French translation.
- * po/sv.po: New Swedish translation.
-
-2002-07-23 Alan Modra <amodra@bigpond.net.au>
-
- * elflink.h (elf_link_input_bfd): Don't change internal symbols
- when outputting relocs.
-
-2002-07-20 Jason Thorpe <thorpej@wasabisystems.com>
-
- * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Only insert
- DT_PLTGOT into the dynamic section if there is a PLT.
-
-2002-07-19 Alan Modra <amodra@bigpond.net.au>
-
- * elfxx-ia64.c: (elfNN_ia64_modify_segment_map): Properly scan
- PT_IA_64_UNWIND segments for a given section.
-
-2002-07-16 Moritz Jodeit <moritz@jodeit.org>
-
- * peXXigen.c (_bfd_XXi_swap_aouthdr_out): Correct order of memset args.
-
-2002-07-16 Alan Modra <amodra@bigpond.net.au>
-
- * elflink.h (elf_link_input_bfd): Don't call reloc_emitter when
- reloc section size is zero. Correct reloc output location.
-
- Merge from mainline.
- 2002-07-14 H.J. Lu <hjl@gnu.org>
- * elflink.h (elf_link_assign_sym_version): Hide the default
- definition if there is a hidden versioned definition.
-
-2002-07-16 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * elf-hppa.h (elf_hppa_reloc_final_type): Use R_PARISC_PCREL16F as
- the final type for the e_fsel selector when generating PA2.0W code.
- (elf_hppa_relocate_insn): Provide support for PA2.0W 16-bit format 1
- relocations.
-
-2002-07-12 Hans-Peter Nilsson <hp@axis.com>
-
- * elf32-cris.c (cris_elf_relocate_section): Drop nonsensical
- dynamic reference test in assertion when initializing GOT with
- static contents. Just assert that there are either no dynamic
- sections, the symbol is defined in the regular objects or that the
- symbol is undef weak. Tweak comment.
- (elf_cris_finish_dynamic_symbol): Emit .got reloc for a program
- only if the symbol isn't defined in the program and isn't undef
- weak.
- (elf_cris_adjust_dynamic_symbol): Simplify condition for getting
- rid of PLT entry: only do it if the symbol isn't defined in a DSO.
- When doing so, clear ELF_LINK_HASH_NEEDS_PLT. Tweak comments.
- (elf_cris_discard_excess_program_dynamics): Don't consider
- ELF_LINK_HASH_REF_DYNAMIC when omitting .got runtime relocs.
-
-2002-07-11 Alan Modra <amodra@bigpond.net.au>
-
- * elf32-i386.c (elf_i386_relocate_section): Don't complain about
- unresolved debugging relocs in dynamic applications.
- * elf32-s390.c (elf_s390_relocate_section): Likewise.
- * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
- * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
- * elf64-s390.c (elf_s390_relocate_section): Likewise.
+ 2004-02-27 Alexandre Oliva <aoliva@redhat.com>
+ * elf-bfd.h (struct elf_backend_data): Added
+ elf_backend_can_make_relative_eh_frame,
+ elf_backend_can_make_lsda_relative_eh_frame and
+ elf_backend_encode_eh_address.
+ (_bfd_elf_encode_eh_address): Declare.
+ (_bfd_elf_can_make_relative): Declare.
+ * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Use new
+ hooks to decide whether to attempt to make_relative and
+ make_lsda_relative.
+ (_bfd_elf_write_section_eh_frame_hdr): Call encode_eh_address.
+ (_bfd_elf_can_make_relative): New.
+ (_bfd_elf_encode_eh_address): New.
+ * elf32-frv.c (frv_elf_use_relative_eh_frame): New.
+ (frv_elf_encode_eh_address): New.
+ (elf_backend_can_make_relative_eh_frame): Define.
+ (elf_backend_can_make_lsda_relative_eh_frame): Define.
+ (elf_backend_encode_eh_address): Define.
+ * elfxx-target.h
+ (elf_backend_can_make_relative_eh_frame): Define.
+ (elf_backend_can_make_lsda_relative_eh_frame): Define.
+ (elf_backend_encode_eh_address): Define.
+ (elfNN_bed): Add them.
+
+2004-04-27 Bob Wilson <bob.wilson@acm.org>
+
+ * elf32-xtensa.c (xtensa_read_table_entries): Use section _cooked_size
+ if set. Check reloc_done flag before applying relocations. Use
+ output addresses, both when applying relocations and when comparing
+ against the specified section.
+ (elf_xtensa_relocate_section): Use output address to check if dynamic
+ reloc is in a literal pool. Set section's reloc_done flag.
+
+2004-04-21 Philip Blundell <pb@nexus.co.uk>
+
+ * elf32-arm.h (elf32_arm_check_relocs): Don't output REL32
+ relocs for locally defined symbols during -shared final link.
+ (elf32_arm_final_link_relocate): Likewise.
+
+2004-04-21 Bob Wilson <bob.wilson@acm.org>
+
+ * elf32-xtensa.c (is_same_value): Add final_static_link argument and
+ require relocations against a weak symbol to reference the same
+ symbol hash entry if not a final, static link.
+ (get_cached_value, add_value_map): Add final_static_link argument.
+ (remove_literals): Pass final_static_link argument as needed.
+
+2004-04-16 Nick Clifton <nickc@redhat.com>
+
+ * bfd.c (bfd_archive_filename): Catch NULL bfd pointers.
+
+2004-04-16 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elflink.c (_bfd_elf_merge_symbol): Treat weak as strong only
+ when it is a definition.
+
+2004-04-16 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-sparc.c (elf32_sparc_relocate_section): Don't abort
+ when statically linking PIC code.
* elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
- * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
-
-2002-07-10 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (ONES): Define.
- (ppc64_elf_howto_table): Use ONES here to avoid warnings. Fill in
- missing src_mask fields. Tweak R_PPC64_NONE, R_PPC64_COPY. Fill
- in missing dst_mask fields on R_PPC64_PLT32, R_PPC64_PLTREL32.
-
- * elf64-ppc.c (ppc64_elf_get_symbol_info): Delete.
- (ppc64_elf_set_private_flags): Delete.
- (ppc64_elf_section_from_shdr): Delete.
- (ppc64_elf_merge_private_bfd_data): Remove flag checking/merging code.
- (ppc64_elf_fake_sections): Delete.
- (bfd_elf64_bfd_set_private_flags): Don't define.
- (bfd_elf64_get_symbol_info): Likewise.
- (elf_backend_section_from_shdr): Likewise.
- (elf_backend_fake_sections): Likewise.
-
-2002-07-10 Marco Walther <Marco.Walther@sun.com>
-
- * elf.c: (assign_section_numbers) Set sh_entsize for .stab only
- when not already set.
- * elf64-sparc.c: (sparc64_elf_fake_sections): New function.
- (elf_backend_fake_sections): Define.
-
-2002-07-10 Alan Modra <amodra@bigpond.net.au>
-
- * merge.c (_bfd_merge_section): Remove redundant output_section check.
- Formatting.
- (_bfd_merge_sections): Don't set SEC_EXCLUDE on unused sections.
-
-2002-07-09 Hans-Peter Nilsson <hp@axis.com>
-
- * elf32-cris.c (cris_elf_relocate_section): Move sanity-check for
- NULL sym_hashes to just before use.
- <case R_CRIS_32_GOTREL>: In test for local symbol, accept also
- symbol with non-default visibility.
- <case R_CRIS_32_GOTREL, case R_CRIS_32_PLT_GOTREL>: Ditto.
- <case R_CRIS_8_PCREL, case R_CRIS_16_PCREL, case R_CRIS_32_PCREL>:
- Ditto.
- (cris_elf_gc_sweep_hook): Only decrease h->plt.refcount for
- symbol with non-default visibility.
- (cris_elf_check_relocs): At tests for local symbol before
- increasing h->plt.refcount, also check for non-default
- visibility. Ditto when checking for local symbol to eliminate
- pc-relative runtime relocs.
-
-2002-07-08 Alan Modra <amodra@bigpond.net.au>
-
- * elf.c: Formatting.
- (IS_SOLARIS_PT_INTERP): Add p_paddr and p_memsz checks.
- (INCLUDE_SECTION_IN_SEGMENT): Remove IS_SOLARIS_PT_INTERP.
- (copy_private_bfd_data): Set p_vaddr on broken Solaris PT_INTERP
- segments.
-
-2002-07-07 Mark Mitchell <mark@codesourcery.com>
- Alan Modra <amodra@bigpond.net.au>
-
- * cofflink.c (_bfd_coff_final_link): On PE COFF systems, take into
- account the impact of relocation count overflow when computing
- section offsets.
- * coffcode.h (coff_write_relocs): Use obj_pe when deciding whether
- or not to apply the PE COFF reloc overflow handling. Fix a
- fencepost error in deciding whether or not to use that technique.
-
-2002-07-07 Alan Modra <amodra@bigpond.net.au>
-
- * elf-bfd.h (struct elf_reloc_cookie): Remove locsym_shndx,
- change type of locsyms.
- (bfd_elf_get_elf_syms): Declare.
- * elf.c (bfd_elf_get_elf_syms): New function.
- (group_signature): Use bfd_elf_get_elf_syms.
- (bfd_section_from_r_symndx): Likewise.
- * elfcode.h (elf_slurp_symbol_table): Likewise.
- * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
- (elf_link_add_object_symbols): Likewise. Reorganise to increase
- locality of various data structures. Properly free internal relocs.
- (elf_bfd_final_link): Properly free internal relocs.
- (elf_link_check_versioned_symbol): Use bfd_elf_get_elf_syms.
- (elf_link_input_bfd): Likewise.
- (elf_gc_mark): Likewise. Properly free internal relocs.
- (elf_gc_sweep): Properly free internal relocs.
- (elf_reloc_symbol_deleted_p): No need to swap syms in.
- (elf_bfd_discard_info): Use bfd_elf_get_elf_syms. Properly free
- internal relocs.
- * elf-m10200.c (mn10200_elf_relax_section): Use bfd_elf_get_elf_syms.
- Properly free possibly cached info.
- (mn10200_elf_relax_delete_bytes): Remove symbol swapping code.
- (mn10200_elf_symbol_address_p): Pass in internal syms. Remove
- symbol swapping code.
- (mn10200_elf_get_relocated_section_contents): Use bfd_elf_get_elf_syms.
- Properly free possibly cached info.
- * elf-m10300.c (mn10300_elf_relax_section): As above for elf-m10200.c.
- (mn10300_elf_relax_delete_bytes): Likewise.
- (mn10300_elf_symbol_address_p): Likewise.
- (mn10300_elf_get_relocated_section_contents): Likewise.
- * elf32-h8300.c (elf32_h8_relax_section): As above for elf-m10200.c.
- (elf32_h8_relax_delete_bytes): Likewise.
- (elf32_h8_symbol_address_p): Likewise.
- (elf32_h8_get_relocated_section_contents): Likewise.
- * elf32-m32r.c (m32r_elf_relax_section): As above for elf-m10200.c.
- (m32r_elf_relax_delete_bytes): Likewise.
- (m32r_elf_get_relocated_section_contents): Likewise.
- * elf32-sh.c (sh_elf_reloc_loop): Free section contents using
- elf_section_data to determine whether cached.
- (sh_elf_relax_section): As above for elf-m10200.c.
- (sh_elf_relax_delete_bytes): Likewise.
- (sh_elf_get_relocated_section_contents): Likewise.
- * elf32-xstormy16.c (xstormy16_elf_relax_section): As above.
- * elf64-alpha.c (elf64_alpha_relax_section): As above. Also delay
- reading of local syms.
- * elf64-mmix.c (mmix_elf_relax_section): Likewise.
- * elf64-sh64.c (sh_elf64_get_relocated_section_contents): As above.
- * elfxx-ia64.c (elfNN_ia64_relax_section): As above.
- * elfxx-mips.c (_bfd_mips_elf_check_relocs): Properly free internal
- relocs.
- * elf32-arm.h (bfd_elf32_arm_process_before_allocation): Properly
- free internal relocs and section contents. Don't read symbols.
- * elf32-hppa.c (get_local_syms): Use bfd_elf_get_elf_syms.
- (elf32_hppa_size_stubs): Don't free local syms.
- * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Delay
- reading of local syms. Use bfd_elf_get_elf_syms. Properly free
- possibly cached info.
- * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
- * elf64-hppa.c (elf64_hppa_check_relocs): Use bfd_elf_get_elf_syms.
- * elf64-ppc.c (struct ppc_link_hash_table): Delete bfd_count and
- all_local_syms.
- (get_local_syms): Delete function.
- (edit_opd): Use bfd_elf_get_elf_syms. Free on error exit. Cache
- on exit.
- (ppc64_elf_size_stubs): Use bfd_elf_get_elf_syms. Free/cache on exit.
-
-2002-07-05 Jim Wilson <wilson@redhat.com>
-
- * syms.c (decode_section_type): New.
- (bfd_decode_symclass): Call decode_section_type.
-
-2002-07-04 Jakub Jelinek <jakub@redhat.com>
-
- * merge.c (_bfd_merged_section_offset): Avoid accessing byte before
- section content start.
- Reported by Michael Schumacher <mike@hightec-rt.com>.
-
-2002-07-04 Alan Modra <amodra@bigpond.net.au>
-
- * section.c (_bfd_strip_section_from_output): Remove unnecessary
- link order code. Don't actually remove the output section here;
- Just set a flag for the linker to do so.
- * elflink.c (_bfd_elf_link_renumber_dynsyms): Test for removed
- sections when setting up output section dynsyms.
-
-2002-07-04 Alan Modra <amodra@bigpond.net.au>
-
- * elflink.h (elf_link_add_object_symbols): Revert 1999-09-02 hpux
- fudge.
- * elf.c (bfd_section_from_shdr): Work around broken hpux shared
- libs here instead.
-
-2002-07-02 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * elf64-s390.c (create_got_section): Set .got section alignment to
- 8 bytes.
- (elf_s390_check_relocs): Set .rela.dyn section alignment to 8 bytes.
-
-2002-07-02 Alan Modra <amodra@bigpond.net.au>
-
- * elf.c (_bfd_elf_reloc_type_class): Fix comment grammar.
-
-2002-07-01 Matt Thomas <matt@3am-software.com>
-
- * elf32-vax.c (elf32_vax_print_private_bfd_data): Change EF_*
- to EF_VAX_*.
-
-2002-07-01 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * elfxx-mips.c (ABI_64_P): Fix comment.
- (MIPS_ELF_OPTIONS_SECTION_NAME,MIPS_ELF_STUB_SECTION_NAME): Use the
- new section names for N64 ABI.
- (mips_elf_output_extsym): No special _gp_disp handling for NewABI.
- (mips_elf_calculate_relocation): Code formatting.
- (mips_elf_create_dynamic_relocation): Likewise.
- (_bfd_mips_elf_fake_sections): IRIX6 needs this hack, too.
- (_bfd_mips_elf_size_dynamic_sections): Handle GOT_PAGE for any NewABI.
- (_bfd_mips_elf_relocate_section): No special handling for R_MIPS_64
- in any NewABI.
- (_bfd_mips_elf_finish_dynamic_symbol): No special _gp_disp handling
- for NewABI.
- (_bfd_mips_elf_modify_segment_map): Handle any N64 ABI.
- (_bfd_mips_elf_gc_sweep_hook): NewABI GOT relocs should be handled
- here, too.
-
-2002-07-01 Andreas Schwab <schwab@suse.de>
-
- * elf64-x86-64.c (elf64_x86_64_relocate_section): Only convert
- R_X86_64_64 to R_X86_64_RELATIVE.
-
-2002-07-01 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * vaxbsd.c: New BFD backend for VAX BSD and Ultrix.
- * Makefile.am (BFD32_BACKENDS, BFD32_BACKENDS_CFILES): Add new backend.
- Run "make dep-am".
- * config.bfd (vax-*-bsd* | vax-*-ultrix*): Use vaxbsd_vec instead of
- host_aout_vec.
- * configure.in (vaxbsd_vec): Add.
- * targets.c (vaxbsd_vec): Add.
- * Makefile.in: Rebuild.
- * configure: Rebuild.
- * po/SRC-POTFILES.in: Rebuild.
-
-2002-07-01 Alan Modra <amodra@bigpond.net.au>
-
- * elflink.h (elf_gc_mark): Pass in the section whose relocs we are
- examining to gc_mark_hook, rather than the bfd.
- (elf_gc_sections): Adjust.
- * elf-bfd.h (struct elf_backend_data <gc_mark_hook>): Likewise.
- * elf-m10300.c (mn10300_elf_gc_mark_hook): Likewise.
- * elf32-arm.h (elf32_arm_gc_mark_hook): Likewise.
- * elf32-avr.c (elf32_avr_gc_mark_hook): Likewise.
- * elf32-cris.c (cris_elf_gc_mark_hook): Likewise.
- * elf32-d10v.c (elf32_d10v_gc_mark_hook): Likewise.
- * elf32-fr30.c (fr30_elf_gc_mark_hook): Likewise.
- * elf32-hppa.c (elf32_hppa_gc_mark_hook): Likewise.
- * elf32-i386.c (elf_i386_gc_mark_hook): Likewise.
- * elf32-m32r.c (m32r_elf_gc_mark_hook): Likewise.
- * elf32-m68k.c (elf_m68k_gc_mark_hook): Likewise.
- * elf32-mcore.c (mcore_elf_gc_mark_hook): Likewise.
- * elf32-openrisc.c (openrisc_elf_gc_mark_hook): Likewise.
- * elf32-ppc.c (ppc_elf_gc_mark_hook): Likewise.
- * elf32-s390.c (elf_s390_gc_mark_hook): Likewise.
- * elf32-sh.c (sh_elf_gc_mark_hook): Likewise.
- * elf32-sparc.c (elf32_sparc_gc_mark_hook): Likewise.
- * elf32-v850.c (v850_elf_gc_mark_hook): Likewise.
- * elf32-vax.c (elf_vax_gc_mark_hook): Likewise.
- * elf32-xstormy16.c (xstormy16_elf_gc_mark_hook): Likewise.
- * elf64-mmix.c (mmix_elf_gc_mark_hook): Likewise.
- * elf64-ppc.c (ppc64_elf_gc_mark_hook): Likewise.
- * elf64-s390.c (elf_s390_gc_mark_hook): Likewise.
- * elf64-sh64.c (sh_elf64_gc_mark_hook): Likewise.
- * elfxx-mips.c (_bfd_mips_elf_gc_mark_hook): Likewise.
- * elfxx-mips.h (_bfd_mips_elf_gc_mark_hook): Likewise.
- * elf64-x86-64.c (elf64_x86_64_gc_mark_hook): Likewise.
- * elf32-frv.c (elf32_frv_gc_mark_hook): Likewise. Also remove
- redundant local sym tests.
- * elf64-ppc.c (struct ppc_link_hash_entry): Add is_entry.
- (link_hash_newfunc): Init is_entry.
- (ppc64_elf_copy_indirect_symbol): Copy is_entry.
- (ppc64_elf_link_hash_table_create): Init all_local_syms.
- (create_linkage_sections): Use bfd_make_section_anyway rather than
- bfd_make_section.
- (ppc64_elf_mark_entry_syms): New function.
- (ppc64_elf_check_relocs): Don't bother testing elf_bad_symtab. Set
- up opd entry to function section map.
- (ppc64_elf_gc_mark_hook): Special case opd section relocs, and
- relocs that reference the opd section.
- (edit_opd): New function.
- (ppc64_elf_size_dynamic_sections): Call get_local_syms and edit_opd.
- (ppc64_elf_setup_section_lists): Don't calculate htab->bfd_count here.
- (get_local_syms): Do so here. Exit if we already have local syms.
- Remove bogus comment imported from elf32-hppa.c. Don't attempt to
- read local syms on non-ELF input.
- (ppc64_elf_size_stubs): Call _bfd_elf64_link_read_relocs rather
- than duplicating it's function here. Adjust free of internal
- relocs to suit.
- (ppc64_elf_relocate_section): Adjust local syms in opd section.
- * elf64-ppc.h (ppc64_elf_mark_entry_syms): Declare.
- * elf32-hppa.c (elf32_hppa_size_stubs): Call
- _bfd_elf32_link_read_relocs rather than duplicating it's function
- here. Adjust free of internal relocs to suit.
-
-2002-07-01 Andreas Jaeger <aj@suse.de>
-
- * elf64-x86-64.c (elf64_x86_64_check_relocs): Certain relocations
- are not allowed in shared libs code, enforce -fPIC.
-
-2002-06-29 Hans-Peter Nilsson <hp@bitrange.com>
-
- * mmo.c (mmo_write_loc_chunk): Don't eliminate leading and
- trailing zero-sequences when there's previous left-over data.
-
-2002-06-27 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * elf64-hppa.c (elf64_hppa_reloc_type_class): New function.
- (elf64_hppa_finish_dynamic_sections): Check other_rel_sec, dlt_rel_sec
- and opd_rel_sec in order for starting rela section. Check _raw_size.
- (elf_backend_reloc_type_class): Define.
-
-2002-06-27 Kevin Buettner <kevinb@redhat.com>
-
- * dwarf2.c (decode_line_info): Handle older, non-standard, 64-bit
- DWARF2 formats.
-
-2002-06-27 Alan Modra <amodra@bigpond.net.au>
-
- * cpu-powerpc.c: Comment on ordering of arch_info.
- * elf32-ppc.c (ppc_elf_object_p): New function.
- (elf_backend_object_p): Define.
- * elf64-ppc.c (ppc64_elf_object_p): New function.
- (elf_backend_object_p): Define.
-
-2002-06-26 Jason Thorpe <thorpej@wasabisystems.com>
-
- * configure.in (vax-*-netbsd*): Set COREFILE to netbsd-core.lo.
- * configure: Regenerate.
-2002-06-25 Jason Eckhardt <jle@rice.edu>
-
- * dwarf2.c (decode_line_info): Check unit->addr_size
- to read in the proper number of prologue bytes.
-
-2002-06-25 Nick Clifton <nickc@cambridge.redhat.com>
-
- * config.bfd (powerpc-*-aix5*): Only create a selvecs for
- aix5coff64_vec if 64-bit bfd support has been enabled.
- (powerpc64-*-aix5*): Only define if 64-bit bfd support has
- been enabled.
-
- * targets.c (_bfd_target_vector[]): Only include
- aix5coff64_vec if 64-bit bfd support has been enabled.
-
-2002-06-25 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (ppc_add_stub): Replace strcpy/strncpy with memcpy.
- * elf32-hppa.c (hppa_add_stub): Likewise.
- * elflink.c (_bfd_elf_link_record_dynamic_symbol): Likewise.
- * elflink.h (elf_add_default_symbol): Fix comment typo.
- (elf_add_default_symbol): Replace strcpy and strncpy with memcpy.
- (elf_link_add_object_symbols): Likewise.
- (elf_link_assign_sym_version): Likewise.
- * hash.c (bfd_hash_lookup): Likewise.
- * linker.c (_bfd_generic_link_add_one_symbol): Likewise.
- * section.c (bfd_get_unique_section_name): Likewise.
- * syms.c (_bfd_stab_section_find_nearest_line): Likewise.
- * elf.c (_bfd_elf_make_section_from_phdr): Likewise.
- (assign_section_numbers): Likewise.
- (_bfd_elfcore_make_pseudosection): Likewise.
- (elfcore_grok_lwpstatus): Likewise.
- (elfcore_grok_win32pstatus): Likewise.
- (elfcore_write_note): Constify input params. Use PTR instead of
- void *. Include terminating NUL in namesz. Correct padding.
- Support NULL "name" param. Use memcpy instead of strcpy.
- (elfcore_write_prpsinfo): Constify input params.
- (elfcore_write_prstatus): Likewise. Use PTR instead of void *.
- (elfcore_write_lwpstatus): Likewise.
- (elfcore_write_pstatus): Likewise.
- (elfcore_write_prfpreg): Likewise.
- (elfcore_write_prxfpreg): Likewise.
- * elf-bfd.h (elfcore_write_note): Update declaration.
- (elfcore_write_prpsinfo): Likewise.
- (elfcore_write_prstatus): Likewise.
- (elfcore_write_pstatus): Likewise.
- (elfcore_write_prfpreg): Likewise.
- (elfcore_write_prxfpreg): Likewise.
- (elfcore_write_lwpstatus): Likewise.
-
-2002-06-25 Jason Eckhardt <jle@rice.edu>
-
- * ecoff.c (ecoff_set_symbol_info): Set BSF_FUNCTION for
- symbols of type stProc and stStaticProc.
-
-2002-06-25 Nick Clifton <nickc@redhat.com>
-
- * ecoff.c: VArious formatting fixes.
-
-2002-06-25 Alan Modra <amodra@bigpond.net.au>
-
- * coff-rs6000.c (xcoff_generate_rtinit): Fix typo.
-
-2002-06-25 Alan Modra <amodra@bigpond.net.au>
-
- * aout-adobe.c: Don't compare against "true" or "false.
- * aout-target.h: Likewise.
- * aoutx.h: Likewise.
- * archive.c: Likewise.
- * bout.c: Likewise.
- * cache.c: Likewise.
- * coff-a29k.c: Likewise.
- * coff-alpha.c: Likewise.
- * coff-i386.c: Likewise.
- * coff-mips.c: Likewise.
- * coff-or32.c: Likewise.
- * coff64-rs6000.c: Likewise.
- * coffcode.h: Likewise.
- * coffgen.c: Likewise.
- * cpu-ns32k.c: Likewise.
- * ecoff.c: Likewise.
- * ecofflink.c: Likewise.
- * elf.c: Likewise.
- * elf32-arm.h: Likewise.
- * elf32-cris.c: Likewise.
- * elf32-d30v.c: Likewise.
- * elf32-i386.c: Likewise.
- * elf32-mcore.c: Likewise.
- * elf32-ppc.c: Likewise.
- * elf32-sh.c: Likewise.
- * elf32-sh64.c: Likewise.
- * elf32-v850.c: Likewise.
- * elf64-alpha.c: Likewise.
- * elf64-sh64.c: Likewise.
- * elfcode.h: Likewise.
- * elfcore.h: Likewise.
- * elflink.h: Likewise.
- * elfxx-mips.c: Likewise.
- * i386os9k.c: Likewise.
- * ieee.c: Likewise.
- * libbfd.c: Likewise.
- * linker.c: Likewise.
- * mmo.c: Likewise.
- * nlm32-alpha.c: Likewise.
- * nlm32-i386.c: Likewise.
- * nlm32-ppc.c: Likewise.
- * nlm32-sparc.c: Likewise.
- * nlmcode.h: Likewise.
- * oasys.c: Likewise.
- * pdp11.c: Likewise.
- * peicode.h: Likewise.
- * reloc.c: Likewise.
- * som.c: Likewise.
- * srec.c: Likewise.
- * tekhex.c: Likewise.
- * vms.c: Likewise.
- * xcofflink.c: Likewise.
- * elf64-sparc.c: Edit comment to not use "== false".
-
- * aoutf1.h: Don't use "? true : false".
- * ecoff.c: Likewise.
- * format.c: Likewise.
- * ieee.c: Likewise.
- * linker.c: Likewise.
- * mmo.c: Likewise.
- * oasys.c: Likewise.
-
-2002-06-23 H.J. Lu <hjl@gnu.org>
-
- * elflink.h (elf_link_add_archive_symbols): For the default
- version, check references with only one `@' first.
-
-2002-06-23 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * elf64-hppa.c (elf64_hppa_mark_milli_and_exported_functions): New
- function.
- (allocate_global_data_dlt): Don't add millicode symbols to dynamic
- symbol table.
- (allocate_global_data_opd, allocate_dynrel_entries): Likewise.
- (elf64_hppa_size_dynamic_sections): Revise to use
- elf64_hppa_mark_milli_and_exported_functions.
- (elf64_hppa_finish_dynamic_symbol): Remove code to keep millicode
- symbols out of dynamic symbol table.
-
-2002-06-23 Alan Modra <amodra@bigpond.net.au>
+2004-04-11 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
- * Makefile.in: Regenerate.
- * libbfd.h: Regenerate.
- * bfd-in2.h: Regenerate.
+ * config.bfd: Remove mips*-*-mach3* and mips*-dec-mach3* targets.
+ * configure.in: Remove mips-dec-bsd*, mips-dec-mach3*, mips-*-mach3*
+ targets amd aout_mips_big_vec, aout_mips_little_vec target vectors.
* configure: Regenerate.
- * po/SRC-POTFILES.in: Regenerate.
-
- * elflink.h: Comment typo fixes.
-
-2002-06-23 H.J. Lu <hjl@gnu.org>
-
- * elf-bfd.h (elf_link_loaded_list): New structure.
- (elf_link_hash_table): Add "loaded".
- * elf.c (_bfd_elf_link_hash_table_init): Initialize "loaded".
- * elflink.h (elf_link_check_versioned_symbol): New function.
- (elf_link_output_extsym): Call elf_link_check_versioned_symbol.
-
-2002-06-19 Nick Clifton <nickc@cambridge.redhat.com>
-
- * elflink.h (size_dynamic_sections): If the target does not
- support an ELF style hash table, return true, indicating that
- nothing needed to be done, rather than false, indicating that the
- section's size could not be computed.
-
-2002-06-18 Dave Brolley <brolley@redhat.com>
-
- From Catherine Moore, Michael Meissner, Dave Brolley:
- * po/SRC-POTFILES.in: Add cpu-frv.c and elf32-frv.c
- * targets.c: Support bfd_elf32_frv_vec.
- * reloc.c: Add FRV relocs.
- * configure.in: Add support for bfd-elf32-frv-vec.
- * config.bfd (targ_cpu): Add support for frv-*-elf.
- * archures.c: Add frv arch and machines.
- * Makefile.am (ALL_MACHINES): Add cpu-frv.lo.
- (ALL_MACHINES_CFILES): Add cpu-frv.c.
- (BFD32_BACKENDS): Add elf32-frv.lo.
- (BFD32_BACKENDS_CFILES): Add elf32-frv.c
- (cpu-frv.lo): New target.
- (elf32-frv.lo): New target.
- * cpu-frv.c: New file.
- * elf32-frv.c: New file.
-
-2002-06-18 Jakub Jelinek <jakub@redhat.com>
-
- * elfcode.h (elf_object_p): Sanity check eh_shoff == 0 implies
- e_shnum == 0.
- Only read the first section header if e_shoff is non-zero.
- Don't consider e_shstrndx if there are no sections.
-
-2002-06-17 Tom Rix <trix@redhat.com>
-
- * elf32-d10v.c (elf_d10v_howto_table): Change R_D10V_10_PCREL_R,
- R_D10V_10_PCREL_L and R_D10V_18_PCREL to use
- complain_overflow_bitfield.
-
-2002-06-17 Alan Modra <amodra@bigpond.net.au>
-
- * opncls.c (bfd_openr): Remove redundant bfd_set_error.
- (bfd_fdopenr): Likewise.
- (bfd_openstreamr): Likewise.
- (bfd_openw): Likewise.
-
- * targets.c: Sort target vecs.
- (_bfd_target_vector): Add aix5coff64_vec, bfd_elf32_sh64_vec,
- bfd_elf32_sh64l_vec, bfd_elf32_sh64lnbsd_vec,
- bfd_elf32_sh64nbsd_vec, bfd_elf64_sh64_vec, bfd_elf64_sh64l_vec,
- bfd_elf64_sh64lnbsd_vec, bfd_elf64_sh64nbsd_vec.
- * configure.in: Sort target vecs. Add m88kmach3_vec.
- * configure: Regenerate.
-
-2002-06-16 Hans-Peter Nilsson <hp@bitrange.com>
-
- * elf64-mmix.c (bpo_reloc_request_sort_fn): Use member
- bpo_reloc_no to break sort order ties, not address of items.
-2002-06-16 John David Anglin <dave@hiauly1.hia.nrc.ca>
+2004-04-09 Daniel Jacobowitz <drow@mvista.com>
- * elf-hppa.h (elf_hppa_final_link): Fix formatting in comment.
- Skip excluded sections in determing __gp value.
- (elf_hppa_final_link_relocate): Use the symbol's address in
- R_PARISC_FPTR64 relocations that don't need an opd entry.
- * elf64-hppa.c (allocate_dynrel_entries): Simplify code.
- (elf64_hppa_finalize_dynreloc): Likewise.
- (elf64_hppa_size_dynamic_sections): Move comments and fix typo.
- (elf64_hppa_finish_dynamic_symbol): Break up assert.
+ * configure.in: Update version to 2.14.91.
+ * configure: Likewise.
-2002-06-14 Sergey Grigoriev <serge@leopold.Physik.Uni-Augsburg.DE>
+2004-04-09 Daniel Jacobowitz <drow@mvista.com>
- * pei-i386.c (COFF_SECTION_ALIGNMENT_ENTRIES): Enable 16 byte
- alignment for .bss, .data and .text sections so that sse and sse2
- code will work.
- * pe-i386.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
-
-2002-06013 J"orn Rennecke <joern.rennecke@superh.com>
-
- config.bfd: Add support for sh[1234]l*-*-elf* | sh3el*-*-elf*,
- sh[1234]*-elf*.
-
-2002-06-12 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * elflink.h (elf_bfd_final_link): Improve error handling for missing
- dynamic sections.
-
- * elf64-hppa.c (allocate_global_data_opd): We don't need an opd entry
- for a symbol that has no output section.
- (allocate_dynrel_entries): Correct comment.
- (elf64_hppa_finalize_dynreloc): Likewise. Don't create an opd entry
- unless we want one.
- (elf64_hppa_finalize_opd): Prevent segfault if dyn_h is NULL.
- (elf64_hppa_finalize_dlt): Likewise. Prevent segfault for symbols
- with no section. Remove unnecessary parentheses.
-
-2002-06-11 Tom Rix <trix@redhat.com>
-
- * coffcode.h (coff_compute_section_file_positions): Add data
- section to AIX loader alignment check.
-
- * coff-rs6000.c (_bfd_xcoff_mkobject): Set default text section
- alignment to 4 bytes.
- (_bfd_xcoff_copy_private_bfd_data): Use text and data alignment
- power accessor macro.
- (do_shared_object_padding): Remove invalid assertion.
-
-2002-06-10 Richard Sandiford <rsandifo@redhat.com>
-
- * section.c (_bfd_strip_section_from_output): Set SEC_EXCLUDE
- for removed output sections.
-
-2002-06-10 Geoffrey Keating <geoffk@redhat.com>
-
- * merge.c (merge_strings): Use htab_create_alloc with calloc, not
- htab_alloc.
- * elf-strtab.c (_bfd_elf_strtab_finalize): Likewise.
-
-2002-06-08 H.J. Lu <hjl@gnu.org>
-
- * elf.c (copy_private_bfd_data): Don't cast to bfd_size_type to
- work around a long long bug in gcc 2.96 on mips.
+ Merge from mainline:
+ 2004-04-06 Daniel Jacobowitz <drow@mvista.com>
+ * elfxx-mips.c (MIPS_ELF_STUB_SECTION_NAME): Always use
+ ".MIPS.stubs".
+
+ 2004-04-05 H.J. Lu <hongjiu.lu@intel.com>
+ * elfxx-ia64.c (elfNN_ia64_size_dynamic_sections): Always
+ reserve the memory for dynamic linker
+
+ 2004-04-05 Mark Kettenis <kettenis@gnu.org>
+ * netbsd-core.c (CORE_WCOOKIE_OFFSET): New define.
+ (netbsd_core_file_p): Create a .wcookie section for OpenBSD/sparc.
+
+ 2004-04-01 Andy Chittenden <achittenden@bluearc.com>
+ * stabs.c (struct stab_link_includes_totals): Add field 'symb'
+ that keeps the characters in a B_INCL..B_EINCL range.
+ (_bfd_link_section_stabs): When computing the sum of the
+ characters in a B_INCL..B_EINCL range also keep a copy of those
+ characters. Use this information to distinguish between
+ include sections that have the same sum and the same length
+ but which are nevertheless unique.
+
+ 2004-03-31 Andy Chittenden <achittenden@bluearc.com>
+ * stabs.c (struct stab_link_includes_totals): Rename field 'total'
+ to 'sum_chars' and add field 'num_chars'.
+ (_bfd_link_section_stabs): When computing the sum of the
+ characters in a B_INCL..B_EINCL range also keep a count of the
+ number of characters. Use this information to help distinguish
+ between include sections when have the same sum but which
+ nevertheless are still unique.
+
+ 2004-03-31 Mattias Engdegård <mattias@virtutech.se>
+ * stabs.c (_bfd_link_section_stabs): Do not skip N_EXCL stabs.
+
+ 2004-03-19 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
+ * elf32-hppa.c (elf32_hppa_check_relocs): Handle R_PARISC_PCREL32.
+ (final_link_relocate): Likewise.
-2002-06-08 Jason Thorpe <thorpej@wasabisystems.com>
+ 2004-03-19 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
+ * elf-hppa.h (elf_hppa_reloc_final_type): Handle selectors for
+ R_PARISC_PCREL32 and R_PARISC_PCREL64 relocations.
+
+ 2004-03-17 Nathan Sidwell <nathan@codesourcery.com>
+ * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Correct
+ logic for null_input_bfd detection.
+
+ 2004-03-12 Nick Clifton <nickc@redhat.com>
+ Dave Murphy <wintermute2k4@ntlworld.com>
+
+ * elf32-arm.h (elf32_arm_merge_private_bfd_data): Skip most checks
+ if the input bfd does not contain any code.
+
+ 2004-03-02 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (struct frv_pic_relocs_info): Added fixups and
+ dynrelocs.
+ (_frv_count_got_plt_entries): Initialize them.
+ (frv_pic_relocs_info_find): Add insert argument. Adjust all
+ callers.
+ (frv_pic_relocs_info_for_global): Likewise.
+ (frv_pic_relocs_info_for_local): Likewise.
+ (frv_pic_merge_early_relocs_info): New.
+ (_frv_resolve_final_relocs_info): Use it in case one entry maps to
+ another.
+ (_frv_add_dyn_reloc): Add entry argument. Adjust all callers.
+ Check that we don't exceed the allocated count for entry.
+ (_frv_add_rofixup): Likewise.
+ (_frv_emit_got_relocs_plt_entries): Adjust for coding standards.
+ (elf32_frv_finish_dynamic_sections): Improve error message in case
+ we emit too few rofixup entries.
+
+ 2004-02-27 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (elf32_frv_howto_table) <R_FRV_LABEL16>: Set
+ complain_on_overflow to signed.
+
+ 2004-02-27 Jakub Jelinek <jakub@redhat.com>
+ * elf32-s390.c (allocate_dynrelocs): Use SYMBOL_REFERENCES_LOCAL
+ for pc relative relocs.
+ (elf_s390_relocate_section): Likewise.
+ * elf64-s390.c (allocate_dynrelocs): Use SYMBOL_REFERENCES_LOCAL
+ for pc relative relocs.
+ (elf_s390_relocate_section): Likewise.
- * Makefile.am (BFD32_BACKENDS): Add vax1knetbsd.lo.
- (BFD32_BACKENDS_CFILES): Add vax1knetbsd.c.
- Regenerate dependency lists.
+ 2004-02-26 H.J. Lu <hongjiu.lu@intel.com>
+ * elfxx-ia64.c (elfNN_ia64_check_relocs): Fix call to
+ count_dyn_reloc.
+
+ 2004-02-25 H.J. Lu <hongjiu.lu@intel.com>
+ * elfxx-ia64.c (elfNN_ia64_dyn_reloc_entry): Add the reltext.
+ field to track if a relocation is against readonly section.
+ (count_dyn_reloc): Take a new argument for rent->reltext.
+ (elfNN_ia64_check_relocs): Adjust call to count_dyn_reloc.
+ (get_reloc_section): Don't set ia64_info->reltext here.
+ (allocate_dynrel_entries): Set ia64_info->reltext here.
+
+ 2004-02-24 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (FRV_SYM_LOCAL): Weak undefined doesn't imply local.
+ (_frv_emit_got_relocs_plt_entries): Decay relocation to protected
+ function's descriptor to symbol+offset, and map local undefweak
+ symbol to NULL function descriptor.
+ (elf32_frv_relocate_section): Likewise.
+
+ 2004-02-21 Danny Smith <daanysmith@users.sourceforge.net>
+ * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Clear
+ IMAGE_SCN_MEM_WRITE on known sections only.
+
+ 2004-02-19 Jakub Jelinek <jakub@redhat.com>
+ * elf32-sparc.c (elf32_sparc_finish_dynamic_sections): Clear
+ .plt sh_entsize.
+
+2004-04-08 Richard Sandiford <rsandifo@redhat.com>
+
+ * elflink.c: Include libiberty.h.
+ * Makefile.am (elflink.lo): Depend on libiberty.h.
* Makefile.in: Regenerate.
- * config.bfd (vax-*-netbsdelf*, vax-*-netbsdaout*): Add
- vax1knetbsd_vec to targ_selvecs.
- * configure.in: Add vax1knetbsd_vec.
- * configure: Regenerate.
- * targets.c (_bfd_target_vector): Add vax1knetbsd_vec.
- * vax1knetbsd.c: New file.
- * vaxnetbsd.c: Update copyright years.
- (TARGET_PAGE_SIZE): Set to 0x1000.
- (DEFAULT_MID): Set to M_VAX4K_NETBSD.
-
-2002-06-08 Matt Thomas <matt@3am-software.com>
-
- * libaout.h (enum machine_type): Add M_VAX4K_NETBSD.
-
-2002-06-08 Alan Modra <amodra@bigpond.net.au>
- * elf64-sh64.c (sh64_elf64_link_output_symbol_hook): Make static.
+2004-04-08 Alan Modra <amodra@bigpond.net.au>
-2002-06-08 Alan Modra <amodra@bigpond.net.au>
+ Apply from mainline.
+ 2004-03-30 Jakub Jelinek <jakub@redhat.com>
+ * elf.c (map_sections_to_segments): Fix handling of .tbss.
- * Makefile.am: Run "make dep-am".
+ 2004-03-27 Alan Modra <amodra@bigpond.net.au>
+ * Makefile.am: Remove all mention of elflink.h.
* Makefile.in: Regenerate.
-
- * armnetbsd.c: Replace CONST with const.
- * corefile.c: Likewise.
- * elf32-dlx.c: Likewise.
- * elf64-mips.c: Likewise.
- * mmo.c: Likewise.
- * ns32knetbsd.c: Likewise.
-
- * elf64-sparc.c (sparc64_elf_add_symbol_hook): Check the hash
- table is elf64-sparc.
-
-2002-06-08 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * elfxx-mips.c (_bfd_mips_elf_relocate_section): Simplify code.
- Fix RELA addends to get not shifted in the result. Don't do special
- handling of R_MIPS_64 for NewABI.
-
-2002-06-07 Alan Modra <amodra@bigpond.net.au>
-
- * aoutx.h (NAME(aout,slurp_symbol_table)): Use bfd_zmalloc.
- (NAME(aout,slurp_reloc_table)): Likewise.
- * coff-mips.c (mips_relax_section): Use bfd_zalloc.
- * coff-rs6000.c (xcoff_write_armap_big): Use bfd_zmalloc.
- (xcoff_write_archive_contents_big): Likewise.
- (xcoff_generate_rtinit): Likewise.
- (xcoff_generate_rtinit): Likewise, and check error return.
- * coff64-rs6000.c (xcoff64_generate_rtinit): Likewise.
- * coffgen.c (coff_section_symbol): Use bfd_zalloc.
- (coff_get_normalized_symtab): Likewise.
- (coff_make_empty_symbol): Likewise.
- (bfd_coff_set_symbol_class): Likewise.
- * cofflink.c (coff_link_add_symbols): Likewise.
- * ecoff.c (_bfd_ecoff_make_empty_symbol): Likewise.
- * ecofflink.c (ecoff_write_shuffle): Use bfd_zmalloc.
- (bfd_ecoff_write_accumulated_debug): Likewise.
- * elf64-alpha.c (get_got_entry): Use bfd_zalloc.
- * i386linux.c (bfd_i386linux_size_dynamic_sections): Likewise.
- * i386lynx.c (NAME(lynx,slurp_reloc_table)): Use bfd_zmalloc.
- * ieee.c (do_with_relocs): Use bfd_zalloc.
- * m68klinux.c (bfd_m68klinux_size_dynamic_sections): Likewise.
- * pdp11.c (NAME(aout,slurp_symbol_table)): Use bfd_zmalloc.
- (NAME(aout,slurp_reloc_table)): Likewise.
- (NAME(aout,squirt_out_relocs)): Don't memset when zalloc'd.
- * reloc16.c (bfd_coff_reloc16_relax_section): Use bfd_zmalloc.
- * som.c (som_build_and_write_symbol_table): Likewise.
- (som_slurp_string_table): Likewise.
- (som_slurp_symbol_table): Likewise.
- (som_bfd_ar_write_symbol_stuff): Likewise.
- * sparclinux.c (bfd_sparclinux_size_dynamic_sections): Use bfd_zalloc.
- * sunos.c (bfd_sunos_size_dynamic_sections): Likewise.
- * tekhex.c (find_chunk): Likewise. Get rid of unused "sname".
- * vms-gsd.c (_bfd_vms_slurp_gsd): Use bfd_zmalloc.
- * xcofflink.c (xcoff_link_add_symbols): Use bfd_zalloc/bfd_zmalloc.
-
-2002-06-07 Alan Modra <amodra@bigpond.net.au>
-
- * elf-bfd.h (struct bfd_elf_section_data <group_name>): Replace with
- "group" union.
- (elf_group_name): Update.
- (elf_group_id): Define.
- (bfd_elf_set_group_contents): Declare.
- * elf.c (elf_fake_sections): Qualify use of elf_group_name.
- (set_group_contents): Rename to bfd_elf_set_group_contents. Remove
- ATTRIBUTE_UNUSED from failedptrarg. If elf_group_id is set, use
- that sym for the signature.
- (_bfd_elf_compute_section_file_positions): Don't call
- set_group_contents for "ld -r" case.
- (swap_out_syms): Use bfd_zalloc.
- * elflink.h (elf_link_add_archive_symbols): Likewise.
- (NAME(bfd_elf,size_dynamic_sections)): Likewise.
- (elf_bfd_final_link): Call bfd_elf_set_group_contents.
-
-2002-06-07 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (ppc64_elf_relocate_section): Allow unresolved
- relocs in opd for non-shared too.
-
-2002-06-06 Jeffrey Law <law@redhat.com
-
- * elf32-h8300.c (elf32_h8_relax_section): Ignore uninteresting
- relocations.
-
-2002-06-06 Nick Clifton <nickc@cambridge.redhat.com>
-
- * merge.c: Include libiberty.h.
- * elf-strtab.c: Include libiberty.h.
-
-2002-06-06 Elias Athanasopoulos <eathan@otenet.gr>
-
- * peXXigen.c (pe_print_idata): Remove unused variable.
-
-2002-06-06 David Heine <dlheine@tensilica.com>
-
- * elf.c (assign_file_positions_for_segments): Remove unallocated
- sections from the section to segment mapping for PT_LOAD segments.
- Update comment about empty loadable segments.
-
-2002-06-06 Richard Sandiford <rsandifo@redhat.com>
-
- * stabs.c (_bfd_link_section_stabs): Check that the symbol offset
- is within the .stabstr section.
-
-2002-06-06 Alan Modra <amodra@bigpond.net.au>
-
- * elf-bfd.h (struct elf_size_info <swap_symbol_in>): Function args
- are "const PTR", not "const PTR *".
- (bfd_elf32_swap_symbol_in): Likewise.
- (bfd_elf64_swap_symbol_in): Likewise.
- * elfcode.h (elf_swap_symbol_in): Change input args to const PTR.
- (elf_slurp_symbol_table): Adjust call to elf_swap_symbol_in.
- * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
- (elf_link_add_object_symbols): Likewise.
- (elf_link_record_local_dynamic_symbol): Likewise.
- (elf_link_input_bfd): Likewise.
- (elf_gc_mark): Likewise.
- (elf_reloc_symbol_deleted_p): Likewise.
- * elf-m10200.c (mn10200_elf_relax_section): Likewise.
- (mn10200_elf_relax_delete_bytes): Likewise.
- (mn10200_elf_symbol_address_p): Likewise.
- (mn10200_elf_get_relocated_section_contents): Likewise.
- * elf-m10300.c (mn10300_elf_relax_section): Likewise.
- (mn10300_elf_relax_section): Likewise.
- (mn10300_elf_relax_delete_bytes): Likewise.
- (mn10300_elf_symbol_address_p): Likewise.
- (mn10300_elf_get_relocated_section_contents): Likewise.
- * elf32-h8300.c (elf32_h8_relax_section): Likewise.
- (elf32_h8_relax_delete_bytes): Likewise.
- (elf32_h8_symbol_address_p): Likewise.
- (elf32_h8_get_relocated_section_contents): Likewise.
- * elf32-hppa.c (get_local_syms): Likewise.
- * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
- * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
- * elf32-sh.c (sh_elf_relax_section): Likewise.
- (sh_elf_relax_delete_bytes): Likewise.
- (sh_elf_get_relocated_section_contents): Likewise.
- * elf32-xstormy16.c (xstormy16_elf_relax_section): Likewise.
- * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
- * elf64-hppa.c (elf64_hppa_check_relocs): Likewise.
- * elf64-mmix.c (mmix_elf_relax_section): Likewise.
- * elf64-ppc.c (get_local_syms): Likewise.
- * elf64-sh64.c (sh_elf64_get_relocated_section_contents): Likewise.
- * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
-
-2002-06-05 J"orn Rennecke <joern.rennecke@superh.com>
-
- * config.bfd (sh64l*-*-elf*, shl*-*-elf*): New configurations.
-
-2002-06-05 Alan Modra <amodra@bigpond.net.au>
-
- * elf.c (group_signature): Swap in the whole symbol, and handle
- extracting section symbol names.
- (setup_group): Add comment.
- (set_group_contents): When called from objcopy or ld, arrange for
- section contents to be written. Write group member output section
- indices to allow objcopy to reorganize sections.
- (_bfd_elf_copy_private_section_data): Copy group info.
-
- * elf-bfd.h (struct elf_size_info): Add swap_symbol_in field.
- (bfd_elf32_swap_symbol_in): Update prototype.
- (bfd_elf64_swap_symbol_in): Likewise.
- * elfcode.h (elf_swap_symbol_in): Change input args to const PTR *.
- (elf_slurp_symbol_table): Adjust call to elf_swap_symbol_in.
- * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
- (elf_link_add_object_symbols): Likewise.
- (elf_link_record_local_dynamic_symbol): Likewise.
- (elf_link_input_bfd): Likewise.
- (elf_gc_mark): Likewise.
- (elf_reloc_symbol_deleted_p): Likewise.
- * elf-m10200.c (mn10200_elf_relax_section): Likewise.
- (mn10200_elf_relax_delete_bytes): Likewise.
- (mn10200_elf_symbol_address_p): Likewise.
- (mn10200_elf_get_relocated_section_contents): Likewise.
- * elf-m10300.c (mn10300_elf_relax_section): Likewise.
- (mn10300_elf_relax_section): Likewise.
- (mn10300_elf_relax_delete_bytes): Likewise.
- (mn10300_elf_symbol_address_p): Likewise.
- (mn10300_elf_get_relocated_section_contents): Likewise.
- * elf32-h8300.c (elf32_h8_relax_section): Likewise.
- (elf32_h8_relax_delete_bytes): Likewise.
- (elf32_h8_symbol_address_p): Likewise.
- (elf32_h8_get_relocated_section_contents): Likewise.
- * elf32-hppa.c (get_local_syms): Likewise.
- * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
- * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
- * elf32-sh.c (sh_elf_relax_section): Likewise.
- (sh_elf_relax_delete_bytes): Likewise.
- (sh_elf_get_relocated_section_contents): Likewise.
- * elf32-xstormy16.c (xstormy16_elf_relax_section): Likewise.
- * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
- * elf64-hppa.c (elf64_hppa_check_relocs): Likewise.
- * elf64-mmix.c (mmix_elf_relax_section): Likewise.
- * elf64-ppc.c (get_local_syms): Likewise.
- * elf64-sh64.c (sh_elf64_get_relocated_section_contents): Likewise.
- * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
- * elfcode.h (NAME(_bfd_elf,size_info)): Update initialiser.
- * elf64-alpha.c (alpha_elf_size_info): Likewise.
- * elf64-hppa.c (hppa64_elf_size_info): Likewise.
- * elf64-mips.c (mips_elf64_size_info): Likewise.
- * elf64-s390.c (s390_elf64_size_info): Likewise.
- * elf64-sparc.c (sparc64_elf_size_info): Likewise.
-
-2002-06-05 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
-
- * elf32-mips.c (elf32_mips_ignore_discarded_relocs): Move to...
- elfxx-mips.c (_bfd_mips_elf_ignore_discarded_relocs): ... here.
- elf64-mips.c (elf_backend_ignore_discarded_relocs): Use
- _bfd_mips_elf_ignore_discarded_relocs.
- elfxx-mips.h (_bfd_mips_elf_ignore_discarded_relocs): Declare.
-
-2002-06-05 H.J. Lu <hjl@gnu.org>
-
- * elfxx-mips.c (mips_elf_calculate_relocation): Call
- _bfd_elf_rel_local_sym for STT_SECTION relocations against
- the SEC_MERGE section.
-
-2002-06-05 Alan Modra <amodra@bigpond.net.au>
-
- * coff-alpha.c: Update copyright date.
- * coff-mips.c: Likewise.
- * xcoff-target.h: Likewise.
-
- * bfd-in.h: Remove "taken from the source" comment.
- * libbfd-in.h: Likewise.
- * libcoff-in.h: Likewise.
- * bfd-in2.h: Regenerate.
- * libbfd.h: Regenerate.
- * libcoff.h: Regenerate.
-
- * elf.c (bfd_elf_discard_group): Return true.
- * elf-bfd.h (bfd_elf_discard_group): Declare.
- * bfd-in.h (bfd_elf_discard_group): Don't declare here.
- * section.c (bfd_discard_group): Rename to bfd_generic_discard_group.
- * bfd.c (bfd_discard_group): Define.
- * targets.c (struct bfd_target): Add _bfd_discard_group.
- (BFD_JUMP_TABLE_LINK): Here too.
- * libbfd-in.h (_bfd_nolink_bfd_discard_group): Define.
- * aout-adobe.c (aout_32_bfd_discard_group): Define.
- * aout-target.h (MY_bfd_discard_group): Define.
- * aout-tic30.c (MY_bfd_discard_group): Define.
- * binary.c (binary_bfd_discard_group): Define.
- * bout.c (b_out_bfd_discard_group): Define.
- * coff-alpha.c (_bfd_ecoff_bfd_discard_group): Define.
- * coffcode.h (coff_bfd_discard_group): Define.
- * coff-mips.c (_bfd_ecoff_bfd_discard_group): Define.
- * elfxx-target.h (bfd_elfNN_bfd_discard_group): Define.
- * i386msdos.c (msdos_bfd_discard_group): Define.
- * i386os9k.c (os9k_bfd_discard_group): Define.
- * ieee.c (ieee_bfd_discard_group): Define.
- * ihex.c (ihex_bfd_discard_group): Define.
- * mmo.c (mmo_bfd_discard_group): Define.
- * nlm-target.h (nlm_bfd_discard_group): Define.
- * oasys.c (oasys_bfd_discard_group): Define.
- * ppcboot.c (ppcboot_bfd_discard_group): Define.
- * som.c (som_bfd_discard_group): Define.
- * srec.c (srec_bfd_discard_group): Define.
- * tekhex.c (tekhex_bfd_discard_group): Define.
- * versados.c (versados_bfd_discard_group): Define.
- * vms.c (vms_bfd_discard_group): Define.
- * xcoff-target.h (_bfd_xcoff_bfd_discard_group): Define.
- * coff64-rs6000.c (rs6000coff64_vec): Update initialiser.
- (aix5coff64_vec): Likewise.
- * coff-rs6000.c (rs6000coff_vec, pmac_xcoff_vec): Likewise.
-
-2002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
-
- * Makefile.am (BFD32_BACKENDS): Add elf32-sh64-com.lo.
- (BFD32_BACKENDS_CFILES): Add elf32-sh64-com.c.
- (elf32-sh64-com.lo): New dependency list.
- * Makefile.in: Regenerate.
- * configure.in (bfd_elf32_sh64_vec, bfd_elf32_sh64l_vec)
- (bfd_elf32_sh64nbsd_vec, bfd_elf32_sh64lnbsd_vec): Add
- elf32-sh64-com.lo.
- * configure: Regenerate.
- * elf32-sh64.c (sh64_address_in_cranges)
- (sh64_get_contents_type, sh64_address_is_shmedia): Move to...
- (crange_qsort_cmpb, crange_qsort_cmpl, crange_bsearch_cmpb):
- (crange_bsearch_cmpl): Prepend _bfd_sh64_ to name and move to...
- * elf32-sh64-com.c: ...here. New file.
-
-2002-06-04 Alan Modra <amodra@bigpond.net.au>
-
- * elf32-openrisc.c (openrisc_elf_gc_mark_hook): Remove
- ATTRIBUTE_UNUSED on used params.
- * elf32-vax.c (elf_vax_gc_mark_hook): Remove unnecessary checks
- before calling bfd_section_from_elf_index on local syms.
- * elf64-sh64.c (sh_elf64_gc_mark_hook): Likewise.
-
-2002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
-
- * Makefile.am (BFD32_BACKENDS): Add elf32-sh64-nbsd.lo.
- (BFD32_BACKENDS_CFILES): Add elf32-sh64-nbsd.c.
- (BFD64_BACKENDS): Add elf64-sh64-nbsd.lo.
- (BFD64_BACKENDS_CFILES): Add elf64-sh64-nbsd.c.
- (elf32-sh64-nbsd.lo, elf64-sh64-nbsd.lo): New rules.
- * Makefile.in: Regenerate.
- * config.bfd (sh5le-*-netbsd*, sh5-*-netbsd*, sh64le-*-netbsd*)
- (sh64-*-netbsd*): New targets.
- * configure.in: Add bfd_elf32_sh64nbsd_vec, bfd_elf32_sh64lnbsd_vec,
- bfd_elf64_sh64nbsd_vec, and bfd_elf64_sh64lnbsd_vec.
- * configure: Regenerate.
- * elf32-sh64-nbsd.c: New file.
- * elf64-sh64-nbsd.c: New file.
- * targets.c: Add extern decls for bfd_elf32_sh64nbsd_vec,
- bfd_elf32_sh64lnbsd_vec, bfd_elf64_sh64nbsd_vec, and
- bfd_elf64_sh64lnbsd_vec.
-
-2002-06-04 Alan Modra <amodra@bigpond.net.au>
-
- * elf.c (setup_group): Set SEC_LINK_ONCE on GRP_COMDAT groups.
- (bfd_section_from_shdr): Likewise. Set section name of group
- sections from signature.
- (group_signature): Split out from setup_group. Ensure symbol table
- is available.
- (bfd_elf_discard_group): New function.
- (_bfd_elf_make_section_from_shdr): Don't set SEC_LINK_ONCE on
- .gnu.linkonce* sections if they are members of a group.
- (set_group_contents): Set GRP_COMDAT flag.
- * section.c (bfd_discard_group): New function.
- * bfd-in.h (bfd_elf_discard_group): Declare.
- * bfd-in2.h: Regenerate.
- * elf-bfd.h (struct bfd_elf_section_data): Add linkonce_p field.
- (elf_linkonce_p): Define.
-
-2002-06-04 Alan Modra <amodra@bigpond.net.au>
-
- * elf.c (bfd_section_from_shdr): Make "name" const.
- * elf-bfd.h (elf_backend_section_from_shdr): Likewise.
- * elf32-i370.c (i370_elf_section_from_shdr): Likewise.
- * elf32-ppc.c (ppc_elf_section_from_shdr): Likewise.
- * elf32-sh64.c (sh64_backend_section_from_shdr): Likewise.
- * elf32-v850.c (v850_elf_section_from_shdr): Likewise.
- * elf64-alpha.c (elf64_alpha_section_from_shdr): Likewise.
- * elf64-hppa.c (elf64_hppa_section_from_shdr): Likewise.
- * elf64-ppc.c (ppc64_elf_section_from_shdr): Likewise.
- * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Likewise.
- * elfxx-mips.c (_bfd_mips_elf_section_from_shdr): Likewise.
- * elfxx-mips.h (_bfd_mips_elf_section_from_shdr): Likewise.
-
-2002-06-03 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
-
- * elfxx-mips.c (ABI_64_P): Use backend's data to determine the
- ABI.
-
-2002-06-02 Kazu Hirata <kazu@cs.umass.edu>
-
- * elf32-arc.c: Fix formatting.
- * elf32-arm.h: Likewise.
- * elf32-cris.c: Likewise.
- * elf32-dlx.c: Likewise.
- * elf32-hppa.c: Likewise.
- * elf32-i386.c: Likewise.
- * elf32-i386qnx.c: Likewise.
- * elf32-or32.c: Likewise.
- * elf32-s390.c: Likewise.
- * elf32-sh64.c: Likewise.
- * elf32-vax.c: Likewise.
- * elf32-xstormy16.c: Likewise.
- * elf64-alpha.c: Likewise.
- * elf64-mmix.c: Likewise.
- * elf64-ppc.c: Likewise.
- * elf64-s390.c: Likewise.
- * elf64-sh64.c: Likewise.
- * elf64-x86-64.c: Likewise.
-
-2002-06-02 Richard Henderson <rth@redhat.com>
-
- * elf64-alpha.c (elf64_alpha_relocate_section): Don't dereference
- null when there are no got entries for a symbol.
- (elf64_alpha_relax_find_tls_segment): Rearrange to avoid
- uninitialized variable warning.
-
-2002-06-01 Richard Henderson <rth@redhat.com>
-
- * elf64-alpha.c (elf64_alpha_relax_with_lituse): Don't test for
- undefined symbols here.
- (elf64_alpha_relax_section): Do it here. Also test for not
- defined in the current module.
- (elf64_alpha_relocate_section_r): Split out of ...
- (elf64_alpha_relocate_section): ... here. Don't dereference
- NULL when looking up local got entries.
-
-2002-06-01 Richard Henderson <rth@redhat.com>
-
- * elf64-alpha.c (elf64_alpha_relax_with_lituse): Reject undefined
- symbols from JSR relaxation.
- (elf64_alpha_size_plt_section_1): New.
- (elf64_alpha_calc_dynrel_sizes): Split out .rela.got bits ...
- (elf64_alpha_size_rela_got_1): ... here.
- (elf64_alpha_size_dynamic_sections): Split out .rela.got bits ...
- (elf64_alpha_size_rela_got_section): ... here.
- (elf64_alpha_size_plt_section): New.
- (elf64_alpha_relax_section): Call them.
- (elf64_alpha_size_got_sections): Remove output_bfd arg.
- (elf64_alpha_finish_dynamic_symbol): Check gotent use_count.
-
-2002-06-01 Richard Henderson <rth@redhat.com>
-
- * elf64-alpha.c (alpha_get_dtprel_base, alpha_get_tprel_base): New.
- (elf64_alpha_relocate_section): Use them. Reject LE TLS relocs
- in shared libraries. Fix DTPRELHI and TPRELHI value.
- (INSN_ADDQ, INSN_RDUNIQ): New.
- (struct alpha_relax_info): Add symtab_hdr, tls_segment, first_gotent.
- (elf64_alpha_relax_with_lituse): Return boolean. Remove irelend
- argument. Reject dynamic symbols. Use LITUSE symbolic constants.
- (elf64_alpha_relax_got_load): Rename from relax_without_lituse.
- Handle GOTDTPREL and GOTTPREL relocations.
- (elf64_alpha_relax_gprelhilo): New.
- (elf64_alpha_relax_tls_get_addr): New.
- (elf64_alpha_relax_find_tls_segment): New.
- (elf64_alpha_relax_section): Handle TLS relocations.
- (ALPHA_ELF_LINK_HASH_TLS_IE): New.
- (elf64_alpha_check_relocs): Set it.
-
-2002-06-01 Richard Henderson <rth@redhat.com>
-
- * elf64-alpha.c (elf64_alpha_relax_section): Don't store computed gp.
-
- * elf64-alpha.c (elf64_alpha_check_relocs): Fix typo on maybe_dynamic
- check; don't suppress dynamic relocs for non-allocated sections.
-
- * elf64-alpha.c: Remove dead code.
-
-2002-05-31 Alan Modra <amodra@bigpond.net.au>
-
+ * bfd-in.h (bfd_elf_discard_info): Declare.
+ (bfd_elf32_discard_info, bfd_elf64_discard_info): Delete.
* bfd-in2.h: Regenerate.
- * libbfd.h: Regenerate.
+ * elf-bfd.h (bfd_elf32_print_symbol, bfd_elf64_print_symbol,
+ bfd_elf32_link_record_dynamic_symbol,
+ bfd_elf64_link_record_dynamic_symbol,
+ _bfd_elf_link_record_dynamic_symbol, bfd_elf32_bfd_final_link,
+ bfd_elf64_bfd_final_link, elf_link_record_local_dynamic_symbol,
+ _bfd_elf32_link_record_local_dynamic_symbol,
+ _bfd_elf64_link_record_local_dynamic_symbol,
+ _bfd_elf32_gc_sections, _bfd_elf32_gc_common_finalize_got_offsets,
+ _bfd_elf32_gc_common_final_link, _bfd_elf64_gc_common_final_link,
+ _bfd_elf32_gc_record_vtinherit, _bfd_elf32_gc_record_vtentry,
+ _bfd_elf64_gc_sections, _bfd_elf64_gc_common_finalize_got_offsets,
+ _bfd_elf64_gc_record_vtinherit, _bfd_elf64_gc_record_vtentry,
+ _bfd_elf32_reloc_symbol_deleted_p,
+ _bfd_elf64_reloc_symbol_deleted_p): Delete.
+ (bfd_elf_link_record_dynamic_symbol,
+ bfd_elf_link_record_local_dynamic_symbol,
+ bfd_elf_final_link, bfd_elf_gc_sections,
+ bfd_elf_gc_record_vtinherit, bfd_elf_gc_record_vtentry,
+ bfd_elf_gc_common_finalize_got_offsets, bfd_elf_gc_common_final_link,
+ bfd_elf_reloc_symbol_deleted_p): Declare.
+ (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
+ * elf32-arm.h: Update for changed function names. Remove local
+ WILL_CALL_FINISH_DYNAMIC_SECTION define.
+ * elf-hppa.h, elf-m10300.c, elf32-cris.c, elf32-d10v.c, elf32-dlx.c,
+ * elf32-fr30.c, elf32-frv.c, elf32-h8300.c, elf32-hppa.c, elf32-i386.c,
+ * elf32-iq2000.c, elf32-m32r.c, elf32-m68hc1x.c, elf32-m68k.c,
+ * elf32-mcore.c, elf32-openrisc.c, elf32-ppc.c, elf32-s390.c,
+ * elf32-sh.c, elf32-sparc.c, elf32-v850.c, elf32-vax.c,
+ * elf32-xstormy16.c, elf32-xtensa.c, elf64-alpha.c, elf64-hppa.c,
+ * elf64-mmix.c, elf64-ppc.c, elf64-s390.c, elf64-sh64.c, elf64-sparc.c,
+ * elf64-x86-64.c, elfxx-ia64.c, elfxx-mips.c, elfxx-target.h: Likewise.
+ * elfxx-target.h (bfd_elfNN_bfd_final_link): Define.
+ (bfd_elfNN_print_symbol): Define.
+ * elfcode.h: Don't include elflink.h.
+ (elf_bfd_discard_info, elf_reloc_symbol_deleted_p,
+ elf_link_record_dynamic_symbol, elf_bfd_final_link, elf_gc_sections,
+ elf_gc_common_finalize_got_offsets, elf_gc_common_final_link,
+ elf_gc_record_vtinherit, elf_gc_record_vtentry,
+ elf_link_record_local_dynamic_symbol): Don't define.
+ * elflink.c: Update for changed function names. Move elflink.h
+ code here.
+ * elflink.h: Delete file.
* po/SRC-POTFILES.in: Regenerate.
+ * po/bfd.pot: Regenerate.
- * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Don't allocate
- space for bss .plt.
-
-2002-05-31 Graeme Peterson <gp@qnx.com>
-
- * Makefile.am (BFD32_BACKENDS): Add elf32-i386qnx.lo.
- (BFD32_BACKENDS_CFILES): Add elf32-i386qnx.c.
- Run "make dep-am".
- * Makefile.in: Regenerate.
- * config.bfd: Add i[3456]86-*-nto-qnx* support.
- * configure.in: Add bfd_elf32_i386qnx_vec support.
- * configure: Regenerate.
- * elf-bfd.h (struct elf_backend_data): Add set_nonloadable_filepos,
- is_contained_by_filepos, and copy_private_bfd_data_p.
- * elf.c (assign_file_positions_for_segments): Call backend
- set_nonloadable_filepos. Fix non-K&R call to _bfd_error_handler.
- (IS_CONTAINED_BY_FILEPOS): Define.
- (INCLUDE_SECTION_IN_SEGMENT): Also test IS_CONTAINED_BY_FILEPOS.
- (copy_private_bfd_data): Use IS_CONTAINED_BY_FILEPOS. Typo fix.
- Fix non-K&R call to _bfd_error_handler.
- (_bfd_elf_copy_private_section_data): Use backend
- copy_private_bfd_data_p.
- * elf32-i386.c: Don't include elfxx-target.h when
- ELF32_I386_C_INCLUDED is defined.
- * elf32-i386qnx.c: New QNX elf backend file.
- * elfxx-target.h: Add elf_backend_set_nonloadable_filepos,
- elf_backend_is_contained_by_filepos, and
- elf_backend_do_copy_private_bfd_data.
- * targets.c: Add bfd_target bfd_elf32_i386qnx_vec.
-
-2002-05-31 Alan Modra <amodra@bigpond.net.au>
-
- * elfarm-oabi.c (bfd_elf32_arm_add_glue_sections_to_bfd): Define.
- Move other similar defines to start of file.
-
-2002-05-30 Tom Rix <trix@redhat.com>
-
- * coff-rs6000.c (xcoff_rtype2howto): Handle 16 bit R_RBA.
- * coff64-rs6000.c (xcoff64_rtype2howto): Same.
-
-2002-05-30 Richard Henderson <rth@redhat.com>
-
- * elf64-alpha.c (ALPHA_ELF_LINK_HASH_LU_TLSGD,
- ALPHA_ELF_LINK_HASH_LU_TLSLDM, ALPHA_ELF_LINK_HASH_LU_FUNC): New.
- (ALPHA_ELF_GOT_ENTRY_RELOCS_DONE): Remove.
- (ALPHA_ELF_GOT_ENTRY_RELOCS_XLATED): Remove.
- (struct alpha_elf_got_entry): Add reloc_type, reloc_done, reloc_xlated.
- (struct alpha_elf_obj_tdata): Rename total_got_entries and
- n_local_got_entries to total_got_size and local_got_size.
- (elf64_alpha_howto, elf64_alpha_reloc_map): Update for TLS relocs.
- (alpha_got_entry_size): New.
- (elf64_alpha_relax_with_lituse): Use it.
- (elf64_alpha_relax_without_lituse): Likewise.
- (MAX_GOT_SIZE): Rename from MAX_GOT_ENTRIES.
- (get_got_entry): New.
- (elf64_alpha_check_relocs): Handle TLS relocs. Reorganize.
- (elf64_alpha_adjust_dynamic_symbol): Test LU_FUNC as a mask.
- (elf64_alpha_merge_ind_symbols): Check gotent->reloc_type.
- (elf64_alpha_can_merge_gots, elf64_alpha_merge_gots): Likewise.
- (elf64_alpha_calc_got_offsets_for_symbol): Use alpha_got_entry_size.
- (elf64_alpha_calc_got_offsets): Likewise.
- (alpha_dynamic_entries_for_reloc): New.
- (elf64_alpha_calc_dynrel_sizes): Use it.
- (elf64_alpha_size_dynamic_sections): Likewise.
- (elf64_alpha_relocate_section): Handle TLS relocations.
- * reloc.c: Add Alpha TLS relocations.
- * bfd-in2.h, libbfd.h: Rebuild.
-
-2002-05-29 Ralf Habacker <ralf.habacker@freenet.de>
-
- * peXXigen.c (pe_print_idata): Remove double printed
- import table lines; add Bound-To comment.
-
-2002-05-29 Matt Thomas <matt@3am-software.com>
-
- * Makefile.am (BFD32_BACKENDS): Add elf32-vax.lo.
- (BFD32_BACKENDS_CFILES): Add elf32-vax.c.
- (elf32-vax.lo): New rule.
- * Makefile.in: Regenerate.
- * configure.in (bfd_elf32_vax_vec)
- (vaxnetbsd_vec): New vectors.
- * configure: Regenerate.
- * config.bfd (vax-*-netbsdelf*)
- (vax-*-netbsdaout*)
- (vax-*-netbsd*): New targets.
- * elf32-vax.c: New file.
- * reloc.c: Add VAX relocations.
- * bfd-in2.h: Regenerate.
- * targets.c (_bfd_target_vector): Add bfd_elf32_vax_vec.
-
-2002-05-29 Jason Thorpe <thorpej@wasabisystems.com>
-
- * config.bfd (arm-*-netbsd*): Add bfd_elf32_littlearm_vec
- and bfd_elf32_bigarm_vec to targ_selvecs.
-
-2002-05-29 Ralf Habacker <ralf.habacker@freenet.de>
-
- * peXXigen.c (pe_print_idata): Fix seg faults on printing import tables
- with auto-imported symbols.
-
-2002-05-29 Adam Nemet <anemet@lnxw.com>
-
- * elf32-arm.h (bfd_elf32_arm_get_bfd_for_interworking): Don't add glue
- sections only record bfd.
- (bfd_elf32_arm_add_glue_sections_to_bfd): New function.
- * bfd-in.h (bfd_elf32_arm_add_glue_sections_to_bfd): Declare it.
- * bfd-in2.h: Regenerate.
-
-2002-05-28 Nick Clifton <nickc@cambridge.redhat.com>
-
- * syms.c (_bfd_stab_section_find_nearest_line): Move
- declaration and initialisation of saw_line and saw_func out of
- for loop.
-
-2002-05-29 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (ppc64_elf_get_symbol_info): New function.
- (bfd_elf64_get_symbol_info): Define.
- * elfxx-target.h (bfd_elfNN_get_symbol_info): Only define if undef.
-
-2002-05-29 Andrey Volkov <avolkov@transas.com>
-
- * cpu-h8300.c: Make default h8300 machine first in machine list.
-
-2002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
-
- * config.bfd: Added DLX configuraton.
- * Makefile.am: Added DLX configuraton.
- * configure.in: Added DLX configuraton.
- * archures.c: Add DLX architecure.
- * reloc.c: Add DLX relocs.
- * targets.c: Added DLX target vector.
- * configure: Regenerate.
- * Makefile.in: Regenreate.
- * bfd-in2.h: Regenreate.
- * elf32-dlx.c: New file: Support DLX target.
- * cpu-dlx.c: New file: Support DLX target.
-
-2002-05-25 Alan Modra <amodra@bigpond.net.au>
-
- * elf32-m68k.c (elf32_m68k_print_private_bfd_data): Formatting.
-
- * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Revert last change.
- (ppc64_elf_check_relocs): Don't set up function descriptor symbol
- strings to point inside function code sym string.
- (func_desc_adjust): Likewise.
- (ppc64_elf_hide_symbol): Rewrite code to look up function code sym.
-
-2002-05-24 Michal Ludvig <mludvig@suse.cz>
-
- * elf64-x86-64.c (elf64_x86_64_grok_prstatus): Added.
- (elf64_x86_64_grok_psinfo): Added.
-
-2002-05-24 TAMURA Kent <kent@netbsd.org>
-
- * config.bfd: Add a target for i386-netbsdpe.
-
-2002-05-24 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Don't copy is_func
- and is_func_descriptor.
- (func_desc_adjust): Hide function code sym in shared libs unless
- there is a matching exported function descriptor sym.
-
-2002-05-23 Jakub Jelinek <jakub@redhat.com>
-
- * elf.c (_bfd_elf_make_section_from_shdr): Set SEC_THREAD_LOCAL
- for symbols from SHF_TLS section.
- (_bfd_elf_print_private_bfd_data): Add PT_TLS.
- (elf_fake_sections): Set SHF_TLS for SEC_THREAD_LOCAL sections.
- (map_sections_to_segments): Build PT_TLS segment if necessary.
- (assign_file_positions_for_segments): Likewise.
- (get_program_header_size): Account for PT_TLS segment.
- (swap_out_syms): Set type of BSF_THREAD_LOCAL symbols and symbols from
- SEC_THREAD_LOCAL sections to STT_TLS.
- * reloc.c: Add 386 and IA-64 TLS relocs.
- * section.c (SEC_THREAD_LOCAL): Define.
- (SEC_CONSTRUCTOR_TEXT, SEC_CONSTRUCTOR_DATA, SEC_CONSTRUCTOR_BSS):
- Remove.
- * elflink.h (elf_link_add_object_symbols): Support .tcommon.
- (size_dynamic_sections): If DF_STATIC_TLS, set DF_FLAGS
- unconditionally.
- (struct elf_final_link_info): Add first_tls_sec.
- (elf_bfd_final_link): Set first_tls_sec.
- Compute elf_hash_table (info)->tls_segment.
- (elf_link_output_extsym): Handle STT_TLS symbols.
- (elf_link_input_bfd): Likewise.
- * syms.c (BSF_THREAD_LOCAL): Define.
- * bfd-in2.h: Rebuilt.
- * libbfd.h: Rebuilt.
- * elf32-i386.c (elf_i386_tls_transition, dtpoff_base, tpoff,
- elf_i386_mkobject, elf_i386_object_p): New functions.
- (elf_howto_table): Add TLS relocs.
- (elf_i386_reloc_type_lookup): Support TLS relocs.
- (elf_i386_info_to_howto_rel): Likewise.
- (struct elf_i386_link_hash_entry): Add tls_type.
- (struct elf_i386_obj_tdata): New.
- (elf_i386_hash_entry, elf_i386_tdata, elf_i386_local_got_tls_type):
- New macros.
- (struct elf_i386_link_hash_table): Add tls_ldm_got.
- (link_hash_newfunc): Clear tls_type.
- (elf_i386_check_relocs): Support TLS relocs.
- (elf_i386_gc_sweep_hook): Likewise.
- (allocate_dynrelocs): Likewise.
- (elf_i386_size_dynamic_sections): Likewise.
- (elf_i386_relocate_section): Likewise.
- (elf_i386_finish_dynamic_symbol): Likewise.
- (bfd_elf32_mkobject, elf_backend_object_p): Define.
- * elfxx-ia64.c (struct elfNN_ia64_dyn_sym_info): Add tprel_offset,
- dtpmod_offset, dtprel_offset, tprel_done, dtpmod_done, dtprel_done,
- want_tprel, want_dtpmod, want_dtprel.
- (elfNN_ia64_tprel_base, elfNN_ia64_dtprel_base): New functions.
- (ia64_howto_table): Add TLS relocs, rename R_IA64_LTOFF_TP22 to
- R_IA64_LTOFF_TPREL22.
- (elf_code_to_howto_index): Add TLS relocs.
- (elfNN_ia64_check_relocs): Support TLS relocs.
- (allocate_global_data_got): Account for TLS .got data.
- (allocate_dynrel_entries): Account for TLS dynamic relocations.
- (elfNN_ia64_install_value): Supprt TLS relocs.
- (set_got_entry): Support TLS relocs.
- (elfNN_ia64_relocate_section): Likewise.
-
-2002-05-23 Nick Clifton <nickc@cambridge.redhat.com>
-
- * elf32-arm.h (elf32_arm_final_link_relocate): For the Thumb
- BLX reloc round the relocation up rather than down.
- * coff-arm.c (coff_arm_relocate_section): Likewise.
-
-2002-05-21 H.J. Lu (hjl@gnu.org)
-
- * linker.c (_bfd_generic_link_add_one_symbol): Allow multiple
- definition.
-
-2002-05-22 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (ppc64_elf_size_stubs): Don't strip .branch_lt.
- (ppc64_elf_relocate_section): Handle unresolved relocs in opd.
-
-2002-05-22 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (ppc64_elf_relocate_section): Return false for
- unresolved relocs.
- (ppc64_elf_size_dynamic_sections): Check for splt NULL.
-
-2002-05-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * bfd/bfd.c (bfd_get_arch_size): Remove bfd_set_error call for
- non-ELF targets.
-
-2002-05-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * elf-bfd.h (elf_backend_emit_relocs): Change prototype to return
- an error value.
- * elflink.h (elf_link_output_relocs): Likewise. Improve error message.
- return with false on error.
- (elf_link_input_bfd): Check reloc_emitter return value.
-
-2002-05-21 Jason Thorpe <thorpej@wasabisystems.com>
-
- * config.bfd (armeb-*-netbsdelf*): New target.
-
-2002-05-20 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (ppc_build_one_stub): Point undefined function syms
- at the plt call stub.
-
-2002-05-19 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * cpu-mips.c (mips_compatible): Don't try to check machine
- compatibility.
-
-2002-05-18 Tom Rix <trix@redhat.com>
-
- * coff64-rs6000.c (_bfd_xcoff64_swap_aux_out): Fix C_FILE auxent.
-
-2002-05-17 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (ppc64_elf_info_to_howto): Formatting.
- (ppc64_elf_relocate_section): Don't warn about reloc overflow when
- we've already warned about an undefined symbol. Report more
- detail on reloc errors.
-
-2002-05-17 Alan Modra <amodra@bigpond.net.au>
-
- * acinclude.m4 (AM_INSTALL_LIBBFD): New.
- * configure.in: Invoke AM_INSTALL_LIBBFD.
- * Makefile.am (install-data-local): Revert 2002-05-13. Move to..
- (install_libbfd): .. New target.
- (uninstall_libbfd): Likewise.
- (install-bfdlibLTLIBRARIES): Likewise.
- (uninstall-bfdlibLTLIBRARIES): Likewise.
- (bfdlibdir): New.
- (bfdincludedir): New.
- (lib_LTLIBRARIES): Rename to bfdlib_LTLIBRARIES.
- * aclocal.m4: Regenerate.
- * configure: Regenerate.
- * Makefile.in: Regenerate.
-
-2002-05-17 Stuart Balfour <sbalfour@cisco.com>
-
- * hash.c (bfd_hash_lookup): Remove computation of len from inside
- hash loop.
-
-2002-05-16 Nick Clifton <nickc@cambridge.redhat.com>
-
- * config.bfd: Add targets for sh64-linux (little endian and
- big endian).
-
-2002-05-15 Laurent Pinchart <laurent.pinchart@skynet.be>
-
- * peXXigen.c (pe_print_idata): Do not assume that the first thunk
- is located in the same section as the import table. Instead
- check, and if necessary load the section containing the thunk.
-
-2002-05-15 Nick Clifton <nickc@cambridge.redhat.com>
-
- * aix5ppc-core.c (xcoff64_core_p): Replace bfd_read with
- bfd_bread.
- (xcoff64_core_file_matches_executable_p): Replace bfd_read
- with bfd_bread.
-
-2002-05-15 Alan Modra <amodra@bigpond.net.au>
-
- * aix5ppc-core.c: Warning fixes.
- * aout-adobe.c (aout_32_bfd_link_just_syms): Define.
- * aout-target.h (MY_bfd_link_just_syms): Define.
- * aout-tic30.c (MY_bfd_link_just_syms): Define.
- * bfd.c (bfd_link_just_syms): Define.
- * binary.c (binary_bfd_link_just_syms): Define.
- * bout.c (b_out_bfd_link_just_syms): Define.
- * coff-rs6000.c (rs6000coff_vec, pmac_xcoff_vec): Update initializer.
- * coff64-rs6000.c (rs6000coff64_vec, aix5coff64_vec): Likewise.
- * coffcode.h (coff_bfd_link_just_syms): Define.
- * elf-bfd.h (enum elf_link_info_type): Add ELF_INFO_TYPE_JUST_SYMS.
- (elf_discarded_section): Check for ELF_INFO_TYPE_JUST_SYMS.
- (_bfd_elf_link_just_syms): Declare.
- * elf.c (_bfd_elf_link_just_syms): New function.
- * elf-eh-frame.c (_bfd_elf_maybe_strip_eh_frame_hdr): Check that
- sections haven't already been discarded by the linker.
- * elflink.h (elf_link_add_object_symbols): Likewise for stab
- sections and SEC_MERGE sections.
- (elf_bfd_discard_info): Similarly here.
- * elfxx-target.h (bfd_elfNN_bfd_link_just_syms): Define.
- * i386msdos.c (msdos_bfd_link_just_syms): Define.
- * i386os9k.c (os9k_bfd_link_just_syms): Define.
- * ieee.c (ieee_bfd_link_just_syms): Define.
- * ihex.c (ihex_bfd_link_just_syms): Define.
- * libbfd-in.h (_bfd_nolink_bfd_link_just_syms): Define.
- (_bfd_generic_link_just_syms): Declare.
- * libecoff.h (_bfd_ecoff_bfd_link_just_syms): Define.
- * linker.c (_bfd_generic_link_just_syms): New function.
- * mmo.c (mmo_bfd_link_just_syms): Define.
- * nlm-target.h (nlm_bfd_link_just_syms): Define.
- * oasys.c (oasys_bfd_link_just_syms): Define.
- * ppcboot.c (ppcboot_bfd_link_just_syms): Define.
- * som.c (som_bfd_link_just_syms): Define.
- * srec.c (srec_bfd_link_just_syms): Define.
- * targets.c (struct bfd_target): Add _bfd_link_just_syms.
- (BFD_JUMP_TABLE_LINK): And here.
- * tekhex.c (tekhex_bfd_link_just_syms): Define.
- * versados.c (versados_bfd_link_just_syms): Define.
- * vms.c (vms_bfd_link_just_syms): Define.
- * libbfd.h: Regenerate.
- * bfd-in2.h: Regenerate.
-
-2002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * elf32-mips.c: Remove superfluous definitions copied from
- elfxx-mips.c.
- (bfd_elf32_bigmips_vec,bfd_elf32_littlemips_vec): Use the
- SGIish vectors to check the special case.
- (mips_elf_hi16_reloc): Fix comment.
- (mips_elf_got16_reloc): Likewise.
- (_bfd_mips_elf32_gprel16_reloc): Likewise.
- (elf_reloc_map): Code cleanup.
- (mips_reloc_map): Add comment.
- (bfd_elf23_bfd_reloc_type_lookup): Code cleanup.
- (mips_elf32_rtype_to_howto): Likewise.
- (mips_elf32_discard_info): Likewise.
- (elf32_mips_irix_compat): Invert logic: Only SGIish vectors
- lead to IRIX compatibility now.
-
-2002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * elfxx-mips.c: Call it IRIX, not Irix in comments.
-
-2002-05-13 Jason Thorpe <thorpej@wasabisystems.com>
-
- * config.bfd (shle-*-netbsdelf*): Add target which includes
- sh64 support.
-
-2002-05-13 David Edelsohn <edelsohn@gnu.org>
-
- * configure.in: Revert 2002-04-07. Instead, auto-configure
- HAVE_ST_C_IMPL.
- * configure: Regenerate.
- * config.in: Regenerate.
- * rs6000-core.c (CNEW_IMPL): Guard use of c_impl with HAVE_ST_C_IMPL
- or AIX_5_CORE.
-
-2002-05-11 Federico G. Schwindt <fgsch@olimpo.com.br>
-
- * configure.in (sparc*-*-openbsd*): Support sparc64-openbsd
- corefiles as well.2
- * configure: Regenerate.
-
-2002-05-13 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am (install-data-local): Install headers to
- $(exec_prefix)/include.
- * Makefile.in: Regenerate.
-
-2002-05-11 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
- Daniel Jacobowitz <drow@mvista.com>
-
- * coff-sh.c (sh_reloc_map): Map to R_SH_IMM32 for non-PE. Don't
- map BFD_RELOC_RVA.
-
-2002-05-11 Federico G. Schwindt <fgsch@olimpo.com.br>
-
- * config.bfd (alpha*-*-openbsd*, sparc64*-*-openbsd*,
- hppa*-*-openbsd*): New targets.
- * configure.in (alpha*-*-openbsd*): Set COREFILE.
- * configure: Regenerate.
-
-2002-05-10 Tom Rix <trix@redhat.com>
-
- * coff64-rs6000.c (xcoff64_reloc_type_br): New function for
- xcoff64_ppc_relocate_section.
- * coff-rs6000.c : Extern common xcoff_reloc_type functions.
- * libxcoff.h: Common xcoff_reloc_type function declaration.
-
-2002-05-10 Alan Modra <amodra@bigpond.net.au>
-
- * elf32-i386.c (elf_i386_relocate_section): Remove overflow checks
- added in 2002-05-09 commit.
-
- * elf32-hppa.c (elf32_hppa_size_stubs): Revert part of 2002-05-04,
- don't look for stubs on all undefined syms.
-
-2002-05-09 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (RA_REGISTER_MASK, RA_REGISTER_SHIFT): Delete.
- (ppc64_elf_howto_raw <R_PPC64_RELATIVE>): Not pc_relative or
- pcrel_offset.
-
- * elf32-i386.c (elf_howto_table): Comments.
- (elf_i386_relocate_section): Handle more relocs for relocatable
- linking and against SEC_MERGE sections.
-
-2002-05-08 Alan Modra <amodra@bigpond.net.au>
-
- * elf32-ppc.c (ppc_elf_create_got): New function.
- (ppc_elf_create_dynamic_sections): Call ppc_elf_create_got before
- _bfd_elf_create_dynamic_sections. Correct .plt flags.
- (ppc_elf_check_relocs): Use ppc_elf_create_got in place of
- _bfd_elf_create_got_section.
-
-2002-05-07 Alan Modra <amodra@bigpond.net.au>
-
- * elf-bfd.h (struct elf_backend_data): Add rela_normal.
- * elfxx-target.h (elf_backend_rela_normal): Define.
- (elfNN_bed): Init rela_normal.
- * elflink.h (elf_link_input_bfd <emit_relocs>): Handle adjustment
- for section symbols here if rela_normal. Simplify abs section test.
- * elf-m10200.c (mn10200_elf_relocate_section): If relocatable,
- return immediately. Remove code handling relocatable linking.
- * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
- * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
+ 2004-03-27 Alan Modra <amodra@bigpond.net.au>
+ * elf64-mmix.c (mmix_elf_relocate_section): Restore code setting
+ "name" for global syms accidentally removed in 2004-03-20 change.
+
+ 2004-03-27 Alan Modra <amodra@bigpond.net.au>
+ * elf-bfd.h (struct elf_reloc_cookie): Add r_sym_shift field.
+ * elflink.h: Replace all occurrences of sizeof (Elf_External_*)
+ where Elf_External_* is different for 64 and 32 bit, with
+ corresponding elf_size_info field.
+ (struct elf_final_link_info): Use "bfd_byte *" instead
+ of "Elf_External_Sym *" for external_syms and symbuf.
+ (elf_link_adjust_relocs): Set up r_type_mask and r_sym_shift local
+ vars and use instead of ELF_R_INFO and ELF_R_TYPE macros.
+ (struct elf_link_sort_rela): Add "sym_mask" alias for "offset".
+ (elf_link_sort_cmp1): Use sym_mask field instead of ELF_R_SYM.
+ (elf_link_sort_cmp2): Adjust.
+ (elf_link_sort_relocs): Set up r_sym_mask local var instead of
+ using ELF_R_SYM macro. Set u.sym_mask.
+ (elf_bfd_final_link): Call _bfd_elf_stringtab_init instead of macro
+ version, elf_stringtab_init. Ditto for bfd_section_from_elf_index
+ vs. section_from_elf_index. Adjust Elf_External_Sym pointer
+ arithmetic. Pass bed to elf_link_flush_output_syms. Adjust
+ Elf_External_Dyn pointer arithmentic. Use bed swap_dyn_in and
+ swap_syn_out functions. Rearrange dyn swap in/out switch.
+ (elf_link_output_sym): Adjust Elf_External_Sym pointer arithmentic.
+ Pass bed to elf_link_flush_output_syms. Use bed swap_symbol_out.
+ (elf_link_flush_output_syms): Add elf_backend_data arg.
+ (elf_link_check_versioned_symbol): Likewise.
+ (elf_link_output_extsym): Pass bed to elf_link_check_versioned_symbol.
+ Adjust Elf_External_Sym pointer arithmetic. Use bed swap_symbol_out.
+ (elf_link_input_bfd): Use bfd_section_from_elf_index. Set up
+ r_type_mask and r_sym_shift local vars and use instead of ELF_R_SYM,
+ ELF_R_TYPE and ELF_R_INFO macros.
+ (elf_reloc_link_order): Select ELF32_R_INFO or ELF64_R_INFO invocation
+ based on size rather than using ELF_R_INFO.
+ (elf_gc_mark): Set up r_sym_shift local var and use instead of
+ ELF_R_SYM macro.
+ (struct alloc_got_off_arg): New.
+ (elf_gc_common_finalize_got_offsets): Use elf_size_info instead of
+ ARCH_SIZE. Pass get entry size down to elf_gc_allocate_got_offsets.
+ (elf_gc_allocate_got_offsets): Adjust.
+ (elf_reloc_symbol_deleted_p): Usee cookie.r_sym_shift instead of
+ ELF_R_SYM. Use bfd_section_from_elf_index.
+ (elf_bfd_discard_info): Set cookie.r_sym_shift.
+ * elfcode.h (elf_stringtab_init, section_from_elf_index): Delete.
+ (elf_slurp_symbol_table): Use bfd_section_from_elf_index.
+
+ 2004-03-26 Alan Modra <amodra@bigpond.net.au>
+ * elf64-ppc.c (elf_backend_add_symbol_hook): Define.
+ (ppc64_elf_add_symbol_hook): New function.
+ * elf-bfd.h (struct elf_backend_data <elf_add_symbol_hook>): Remove
+ const from Elf_Internal_Sym param.
+ * elflink.c (elf_link_add_object_symbols): Adjust.
+ * elf-hppa.h (elf_hppa_add_symbol_hook): Adjust.
+ * elf32-frv.c (elf32_frv_add_symbol_hook): Adjust.
+ * elf32-i370.c (elf_backend_add_symbol_hook): Adjust.
+ * elf32-m32r.c (m32r_elf_add_symbol_hook): Adjust.
+ * elf32-m68hc1x.c (elf32_m68hc11_add_symbol_hook): Adjust.
+ * elf32-m68hc1x.h (elf32_m68hc11_add_symbol_hook): Adjust.
+ * elf32-ppc.c (ppc_elf_add_symbol_hook): Adjust.
+ * elf32-sh64.c (sh64_elf_add_symbol_hook): Adjust.
+ * elf32-v850.c (v850_elf_add_symbol_hook): Adjust.
+ * elf64-alpha.c (elf64_alpha_add_symbol_hook): Adjust.
+ * elf64-mmix.c (mmix_elf_add_symbol_hook): Adjust.
+ * elf64-sh64.c (sh64_elf64_add_symbol_hook): Adjust.
+ * elf64-sparc.c (sparc64_elf_add_symbol_hook): Adjust.
+ * elfxx-ia64.c (elfNN_ia64_add_symbol_hook): Adjust.
+ * elfxx-mips.c (_bfd_mips_elf_add_symbol_hook): Adjust.
+ * elfxx-mips.h (_bfd_mips_elf_add_symbol_hook): Adjust.
+
+ 2004-03-26 Alan Modra <amodra@bigpond.net.au>
+ * elfxx-target.h (bfd_elfNN_bfd_link_add_symbols): Define.
+ * elf-bfd.h (_bfd_elf_link_add_archive_symbols): Delete.
+ (_bfd_elf_sort_symbol, _bfd_elf_add_dt_needed_tag): Delete.
+ (_bfd_elf_finalize_dynstr, bfd_elf32_bfd_link_add_symbols): Delete.
+ (bfd_elf64_bfd_link_add_symbols): Delete.
+ (bfd_elf_link_add_symbols): Declare.
+ * elfcode.h (elf_bfd_link_add_symbols): Delete.
+ * elflink.c: Include safe-ctype.h.
+ (elf_add_dt_needed_tag): Rename from _bfd_elf_add_dt_needed_tag,
+ make static.
+ (elf_sort_symbol): Rename from _bfd_elf_sort_symbol, make static.
+ (elf_finalize_dynstr): Rename from _bfd_elf_finalize_dynstr, make
+ static.
+ (elf_link_add_archive_symbols): Rename from
+ _bfd_elf_link_add_archive_symbols, make static.
+ (elf_link_add_object_symbols): New function. Corresponding
+ elflink.h function converted to use elf_size_info.
+ (bfd_elf_link_add_symbols): Likewise.
+ (bfd_elf_size_dynamic_sections): Adjust.
+ * elflink.h (elf_bfd_link_add_symbols): Delete.
+ (elf_link_add_object_symbols): Delete.
+ * elf32-gen.c (elf32_generic_link_add_symbols): Call
+ bfd_elf_link_add_symbols.
+ * elf64-gen.c (elf64_generic_link_add_symbols): Likewise.
+
+ 2004-03-25 Alan Modra <amodra@bigpond.net.au>
+ * elflink.h (elf_link_add_object_symbols): Add DT_NEEDED for as-needed
+ and chained shared libs only if dynsym. Clear dynsym on forced-local.
+ * elf-bfd.h (_bfd_elf_add_dynamic_entry): Declare.
+ (bfd_elf32_add_dynamic_entry, bfd_elf64_add_dynamic_entry): Delete.
+ (_bfd_elf_add_dt_needed_tag): Declare.
+ (_bfd_elf_sort_symbol): Declare.
+ (_bfd_elf_finalize_dynstr): Declare.
+ (RELOC_FOR_GLOBAL_SYM): Formatting.
+ * elfcode.h (elf_add_dynamic_entry): Delete.
+ * elflink.c (_bfd_elf_add_dynamic_entry): New function. Corresponding
+ elflink.h function converted to use elf_size_info.
+ (_bfd_elf_add_dt_needed_tag): Likewise.
+ (_bfd_elf_sort_symbol): Likewise.
+ (_bfd_elf_finalize_dynstr): Likewise.
+ (compute_bucket_count): Likewise.
+ (bfd_elf_size_dynamic_sections): Likewise. Check result of
+ _bfd_elf_strtab_add before calling _bfd_elf_strtab_addref.
+ (elf_adjust_dynstr_offsets, elf_collect_hash_codes): Moved from..
+ * elflink.h: ..here.
+ (sort_symbol, add_dt_needed_tag): Delete.
+ (elf_add_dynamic_entry, elf_finalize_dynstr): Delete.
+ (compute_bucket_count, NAME(bfd_elf,size_dynamic_sections)): Delete.
+ Update all users.
+ * elf32-arm.h (add_dynamic_entry): Update. Remove casts.
+ * elf32-cris.c (add_dynamic_entry): Likewise.
+ * elf32-hppa.c (add_dynamic_entry): Likewise.
+ * elf32-i370.c (add_dynamic_entry): Likewise.
+ * elf32-i386.c (add_dynamic_entry): Likewise.
+ * elf32-m32r.c (add_dynamic_entry): Likewise.
+ * elf32-m68k.c (add_dynamic_entry): Likewise.
+ * elf32-ppc.c (add_dynamic_entry): Likewise.
+ * elf32-s390.c (add_dynamic_entry): Likewise.
+ * elf32-sh.c (add_dynamic_entry): Likewise.
+ * elf32-sparc.c (add_dynamic_entry): Likewise.
+ * elf32-vax.c (add_dynamic_entry): Likewise.
+ * elf32-xtensa.c (add_dynamic_entry): Likewise.
+ * elf64-alpha.c (add_dynamic_entry): Likewise.
+ * elf64-hppa.c (add_dynamic_entry): Likewise.
+ * elf64-ppc.c (add_dynamic_entry): Likewise.
+ * elf64-s390.c (add_dynamic_entry): Likewise.
+ * elf64-sparc.c (add_dynamic_entry): Likewise.
+ * elf64-x86-64.c (add_dynamic_entry): Likewise.
+ * elfxx-ia64.c (add_dynamic_entry): Likewise.
+ * elfxx-mips.c (MIPS_ELF_ADD_DYNAMIC_ENTRY): Likewise.
+ * elf-m10300.c (_bfd_mn10300_elf_size_dynamic_sections): Likewise.
+ * elf32-frv.c (elf32_frv_size_dynamic_sections): Likewise.
+ * elf64-sh64.c (sh64_elf64_size_dynamic_sections): Likewise.
+
+ 2004-03-22 Alan Modra <amodra@bigpond.net.au>
+ * elf-bfd.h (RELOC_FOR_GLOBAL_SYMBOL): Add input_bfd, input_section
+ and rel args. Group input and output args. Wrap to 80 columns.
+ * elf-m10200.c, elf-m10300.c, elf32-arm.h, elf32-avr.c,
+ elf32-cris.c, elf32-d10v.c, elf32-fr30.c, elf32-h8300.c,
+ elf32-hppa.c, elf32-i386.c, elf32-i860.c, elf32-ip2k.c,
+ elf32-iq2000.c, elf32-m68hc1x.c, elf32-m68k.c, elf32-mcore.c,
+ elf32-msp430.c, elf32-openrisc.c, elf32-ppc.c, elf32-s390.c,
+ elf32-sparc.c, elf32-v850.c, elf32-vax.c, elf32-xstormy16.c,
+ elf32-xtensa.c, elf64-alpha.c, elf64-mmix.c, elf64-ppc.c,
+ elf64-s390.c, elf64-sparc.c, elf64-x86-64.c, elfxx-ia64.c: Update
+ RELOC_FOR_GLOBAL_SYMBOL invocation.
+
+ 2004-03-20 H.J. Lu <hongjiu.lu@intel.com>
+ * elf-bfd.h (RELOC_FOR_GLOBAL_SYMBOL): Report error if
+ unresolved symbols in objects aren't allowed.
+ * elf-hppa.h (elf_hppa_relocate_section): Properly handle
+ unresolved symbols.
+ (elf_hppa_remark_useless_dynamic_symbols): Likewise.
+ (elf_hppa_unmark_useless_dynamic_symbols):
+ * elf32-frv.c (elf32_frv_relocate_section): Likewise.
+ * elf32-hppa.c (elf32_hppa_size_stubs): Likewise.
+ (elf32_hppa_relocate_section): Likewise.
* elf32-i370.c (i370_elf_relocate_section): Likewise.
+ * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
+ * elf32-sh.c (sh_elf_relocate_section): Likewise.
+ * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
+ * elfxx-mips.c (mips_elf_calculate_relocation): Likewise.
+ * elf-m10200.c (mn10200_elf_relocate_section): Use
+ RELOC_FOR_GLOBAL_SYMBOL.
+ * elf32-avr.c (elf32_avr_relocate_section): Likewise.
+ * elf32-d10v.c (elf32_d10v_relocate_section): Likewise.
+ * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
+ * elf32-h8300.c (elf32_h8_relocate_section): Likewise.
* elf32-i860.c (elf32_i860_relocate_section): Likewise.
- * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
+ * elf32-m68hc1x.c (m68hc11_get_relocation_value): Likewise.
* elf32-mcore.c (mcore_elf_relocate_section): Likewise.
+ * elf32-msp430.c (elf32_msp430_relocate_section): Likewise.
* elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
- * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
- * elf32-s390.c (elf_s390_relocate_section): Likewise.
+ * elf32-v850.c (v850_elf_relocate_section): Likewise.
* elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
- * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
- * elf64-s390.c (elf_s390_relocate_section): Likewise.
- * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
- * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
- * elf32-arm.h (elf32_arm_relocate_section): Likewise #ifndef USE_REL.
- * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
- * elf-m10200.c (elf_backend_rela_normal): Define.
- * elf-m10300.c (elf_backend_rela_normal): Define.
- * elf32-fr30.c (elf_backend_rela_normal): Define.
- * elf32-i370.c (elf_backend_rela_normal): Define.
- * elf32-i860.c (elf_backend_rela_normal): Define.
- * elf32-m68k.c (elf_backend_rela_normal): Define.
- * elf32-mcore.c (elf_backend_rela_normal): Define.
- * elf32-openrisc.c (elf_backend_rela_normal): Define.
- * elf32-ppc.c (elf_backend_rela_normal): Define.
- * elf32-s390.c (elf_backend_rela_normal): Define.
- * elf32-xstormy16.c (elf_backend_rela_normal): Define.
- * elf64-ppc.c (elf_backend_rela_normal): Define.
- * elf64-s390.c (elf_backend_rela_normal): Define.
- * elf64-x86-64.c (elf_backend_rela_normal): Define.
- * elfxx-ia64.c (elf_backend_rela_normal): Define.
- * elf32-arm.h (elf_backend_rela_normal): Define #ifndef USE_REL.
- * elf32-m32r.c (elf_backend_rela_normal): Likewise.
-
-2002-05-06 Nick Clifton <nickc@cambridge.redhat.com>
-
- * elf32-arm.h (elf32_arm_final_link_relocate): Convert
- 'reloc_signed_max' and 'reloc_signed_min' into half-word offsets.
-
-2002-05-06 Alan Modra <amodra@bigpond.net.au>
-
- * elflink.h (elf_link_input_bfd <emit_relocs>): Adjust r_offset
- when not relocatable. Fix reloc_emitter call for K&R.
-
-2002-05-04 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (ppc64_elf_relocate_section): Reinstate code
- reloading local sym addend mistakenly removed in 2002-05-01 change.
-
- * dwarf2.c (struct line_head): Make prologue_length a bfd_vma.
- (read_abbrevs): Change "offset" param to bfd_vma.
- (parse_comp_unit): Change "version" and addr_size to unsigned ints.
- Change "abbrev_offset" to bfd_vma.
- (read_indirect_string): Use correct conversion chars in error
- message format string, cast bfd_vma's to unsigned long.
- (read_abbrevs): Likewise.
- (read_attribute_value): Likewise.
- (decode_line_info): Likewise.
- (scan_unit_for_functions): Likewise.
- (parse_comp_unit): Likewise.
-
-2002-05-04 Tom Rix <trix@redhat.com>
-
- * coffswap.h (coff_swap_reloc_in): Remove XCOFF support.
- (coff_swap_reloc_out): Same.
- * coff-rs6000.c: (xcoff_swap_reloc_in): Moved from coffswap.h.
- (xcoff_swap_reloc_out): Same.
- (xcoff_rtype2howto): Renamed from _bfd_xcoff_rtype2howto. Special
- case some 16 bit relocs. Add reloc value to output.
- (xcoff_howto_table): Remove 64 bit R_POS, add 16 bit
- R_RBR. Improve names.
- (_bfd_xcoff_reloc_type_lookup): Adjust for removal of 64 bit R_POS.
- (bfd_xcoff_backend_data): Update with new reloc swap names.
- (bfd_pmac_xcoff_backend_data) : Same.
- * coff64-rs6000.c: (xcoff64_swap_reloc_in): Moved from coffswap.h.
- (xcoff64_swap_reloc_out): Same.
- (xcoff64_rtype2howto): Special case some 16 bit relocs and 32 bit
- R_POS. Add reloc value to output.
- (xcoff64_howto_table): Move 64 bit R_POS to first entry. Add 16
- bit R_RBR. Improve names, masks.
- (xcoff64_reloc_type_lookup): Adjust for move of 64 bit R_POS.
- (bfd_xcoff_backend_data): Update with new reloc swap names.
- (bfd_xcoff_aix5_backend_data) : Same.
-
-2002-05-04 Alan Modra <amodra@bigpond.net.au>
-
- * elf32-hppa.c (struct elf32_hppa_link_hash_table): Add
- bfd_count top_index, input_list, all_local_syms.
- (elf32_hppa_setup_section_lists): New function, split from
- elf32_hppa_size_stubs.
- (elf32_hppa_next_input_section): Likewise.
- (group_sections): Likewise.
- (get_local_syms): Likewise.
- (elf32_hppa_size_stubs): Adjust for split out functions. Look for
- stubs on undefined syms too.
- (elf32_hppa_set_gp): Use bfd_link_hash* instead of elf_link_hash*.
- Only access htab elf fields when we have an elf hash table.
- * elf32-hppa.h (elf32_hppa_setup_section_lists): Declare.
- (elf32_hppa_next_input_section): Declare.
-
-2002-05-04 Bob Byrnes <byrnes@curl.com>
-
- * opncls.c (_bfd_new_bfd_contained_in): Check return value of
- _bfd_new_bfd.
-
-2002-05-03 H.J. Lu (hjl@gnu.org)
-
- * elfxx-mips.c (mips_elf_link_hash_entry): Add forced_local.
- (mips_elf_link_hash_newfunc): Initialize forced_local to false.
- (mips_elf_record_global_got_symbol): Call _bfd_mips_elf_hide_symbol
- to hide a global symbol.
- (_bfd_mips_elf_hide_symbol): Return if forced_local is true. Set
- forced_local to true.
-
-2002-05-02 Richard Henderson <rth@redhat.com>
-
- * elf64-alpha.c (elf64_alpha_relocate_section): Force relative relocs
- vs SHN_UNDEF to zero.
-
-2002-05-02 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (ppc64_elf_howto_raw <R_PPC64_SECTOFF>): Change to a
- 16 bit reloc.
- <R_PPC64_SECTOFF_DS>: Likewise.
- (ppc64_elf_reloc_type_lookup): Map from BFD_RELOC_16_BASEREL to
- SECTOFF reloc.
- * elf32-ppc.c (ppc_elf_howto_raw <R_PPC_SECTOFF>): Correct.
- (ppc_elf_reloc_type_lookup): Map from BFD_RELOC_16_BASEREL to
- SECTOFF reloc.
-
- * elf64-ppc.c (ppc64_elf_addr16_ha_reloc): Delete.
- (ppc64_elf_ha_reloc): New function.
- (ppc64_elf_brtaken_reloc): New function.
- (ppc64_elf_sectoff_reloc): New function.
- (ppc64_elf_sectoff_ha_reloc): New function.
- (ppc64_elf_toc_reloc): New function.
- (ppc64_elf_toc_ha_reloc): New function.
- (ppc64_elf_toc64_reloc): New function.
- (ppc64_elf_unhandled_reloc): New function.
- (ppc64_elf_howto_raw): Use the above.
- <R_PPC64_RELATIVE>: Mark pc_relative, pcrel_offset.
- <R_PPC64_SECTOFF>: Not pc_relative or pcrel_offset. Fix dst_mask.
- <R_PPC64_SECTOFF_DS>: Likewise.
- (IS_ABSOLUTE_RELOC): Update.
- (struct ppc_link_hash_table): Add have_undefweak.
- (ppc64_elf_link_hash_table_create): Init.
- (func_desc_adjust): Set have_undefweak.
- (ppc64_elf_func_desc_adjust): Call func_desc_adjust earlier. Only
- add the .sfpr blr when have_undefweak.
- (ppc64_elf_setup_section_lists): Check hash table flavour.
- (ppc64_elf_next_input_section): Move output_section->owner test to
- ppc64elf.em.
- (ppc64_elf_set_toc): Rename to ppc64_elf_toc, remove info param
- and relocatable test. Return TOCstart and don't set elf_gp.
- (ppc64_elf_relocate_section): Correct BRTAKEN/BRNTAKEN branch
- offset calculation. Add assert on weak sym branch tweaks.
- * elf64-ppc.h (ppc64_elf_set_toc): Delete.
- (ppc64_elf_toc): Declare.
- (ppc64_elf_next_input_section): Update.
-
-2002-05-01 Alan Modra <amodra@bigpond.net.au>
-
- * syms.c (_bfd_stab_section_find_nearest_line): Don't bomb on NULL
- file_name.
-
-2002-05-01 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (CROR_151515, CROR_313131): Define.
- (ppc64_elf_relocate_section): Use them. Don't look for plt calls
- on R_PPC64_ADDR24 relocs. Require a nop or no link reg on plt
- call branches. Correct undefined weak destination.
- (ppc64_elf_func_desc_adjust): Always create at least one blr in
- .sfpr, and correct case where either only savef* or restf* is
- needed.
-
- Long branch stubs, multiple stub sections.
- * elf64-ppc.h (ppc64_elf_setup_section_lists): Declare.
- (ppc64_elf_next_input_section): Declare.
- * elf64-ppc.c: Move linker-only prototypes.
- (STUB_SUFFIX): Define.
- (enum ppc_stub_type): New.
- (struct ppc_stub_hash_entry): New.
- (struct ppc_branch_hash_entry): New.
- (struct ppc_link_hash_entry): Add stub_cache, oh.
- (struct ppc_link_hash_table): Add stub_hash_table etc. Remove
- sstub. Add sbrlt, srelbrlt, has_14bit_branch, stub_iteration.
- Rename plt_overflow to stub_error.
- (ppc_stub_hash_lookup): Define.
- (ppc_branch_hash_lookup): Define.
- (stub_hash_newfunc): New function.
- (branch_hash_newfunc): New function.
- (link_hash_newfunc): Init new fields.
- (ppc64_elf_link_hash_table_create): Likewise.
- (ppc64_elf_link_hash_table_free): New function.
- (ppc_stub_name): New function.
- (ppc_get_stub_entry): New function.
- (ppc_add_stub): New function.
- (create_linkage_sections): Use bfd_make_section_anyway. Create
- .branch_lt and .rela.branch_lt sections. Don't create .stub.
- (ppc64_elf_check_relocs): Set has_14bit_branch on R_PPC64_REL14*,
- and set up for plt call stubs. Link func and func desc syms.
- (ppc64_elf_gc_sweep_hook): Handle REL14* as per REL24.
- (func_desc_adjust): Avoid hash lookup when func desc sym available
- via shortcut, and set links when processing.
- (ppc64_elf_hide_symbol): Likewise.
- (allocate_dynrelocs): Don't allocate stub section here.
- (ppc64_elf_size_dynamic_sections): Handle sbrlt and srelbrlt.
- Remove sstub code.
- (ppc_type_of_stub): New function.
- (build_one_stub): Delete.
- (ppc_build_one_stub): New function.
- (ppc_size_one_stub): New function.
- (ppc64_elf_setup_section_lists): New function.
- (ppc64_elf_next_input_section): New function.
- (group_sections): New function.
- (get_local_syms): New function.
- (ppc64_elf_size_stubs): Rewrite.
- (ppc64_elf_build_stubs): Rewrite.
- (ppc64_elf_relocate_section): Look up stub entry for REL24
- relocs. Don't propagate REL14* to dynamic objects. Look for long
- branch stubs if REL14* or REL24 relocs won't reach.
- (bfd_elf64_bfd_link_hash_table_free): Define.
-
-2002-04-30 Mark Mitchell <mark@codesourcery.com>
-
- * bfd/config.bfd: Add support for powerpc-*-windiss.
-
-2002-04-30 Tom Rix <trix@redhat.com>
-
- * xcofflink.c (xcoff_link_add_symbols): Always copy undef C_EXT
- symbol names into the hash table.
-
-2002-04-28 Tom Rix <trix@redhat.com>
-
- * coff-rs6000.c (xcoff_calculate_relocation) : Function table for
- calulating relocations.
- (xcoff_complain_overflow) : Function table for relocation errors.
- (xcoff_ppc_relocate_section): Use relocation and complain function
- tables.
- (xcoff_complain_overflow_unsigned_func): New complain function.
- (xcoff_complain_overflow_signed_func): Same.
- (xcoff_complain_overflow_bitfield_func): Same.
- (xcoff_complain_overflow_dont_func): Same.
- (xcoff_reloc_type_crel): New recot function.
- (xcoff_reloc_type_br): Same.
- (xcoff_reloc_type_ba): Same.
- (xcoff_reloc_type_toc): Same.
- (xcoff_reloc_type_rel): Same.
- (xcoff_reloc_type_neg): Same.
- (xcoff_reloc_type_pos): Same.
- (xcoff_reloc_type_fail): Same.
- (xcoff_reloc_type_noop): Same.
- * libxcoff.h : Declare common parts for xcoff64.
- * coff64-rs6000.c (xcoff64_ppc_relocate_section): Use relocation
- and complain function tables.
-
-2002-04-28 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-x86-64.c (struct elf64_x86_64_dyn_relocs): Comment typo.
- * elf32-hppa.c (elf32_hppa_final_link): Formatting.
-
-2002-04-26 Alan Modra <amodra@bigpond.net.au>
-
- * opncls.c (bfd_make_readable): Call bfd_section_list_clear.
- * xcofflink.c (xcoff_link_add_dynamic_symbols): Likewise.
-
- * elflink.h (elf_bfd_final_link): Ensure input bfd class is the
- same as the output before calling elf_link_input_bfd.
-
- * coffcode.h (coff_compute_section_file_positions): Set
- section_tail after shuffling section list.
-
-2002-04-24 Christian Groessler <chris@groessler.org>
-
- * coff-z8k.c (extra_case): Fix R_IMM32 relocations: The
- addresses are 23bit with a special layout, not plain 32bit
- values. Prevent relocation of immediate values.
-
-2002-04-24 Chris G. Demetriou <cgd@broadcom.com>
-
- * elfxx-mips.c (_bfd_mips_elf_print_private_bfd_data): If MDMX or
- MIPS-16 ASE flags are set, print something to indicate that.
-
-2002-04-23 Alan Modra <amodra@bigpond.net.au>
-
- * elf32-hppa.c (hppa_type_of_stub): Correct and simplify condition
- under which a plt call stub is used.
- (final_link_relocate): Similarly.
- (allocate_plt_static): Clear h-plabel except when plt entry is
- exclusively used for a plabel.
- (allocate_dynrelocs): Use the above to simplify plt sizing.
- (struct elf32_hppa_link_hash_table): Add has_22bit_branch.
- (elf32_hppa_link_hash_table_create): Init.
- (BL22_RP): Define.
- (hppa_build_one_stub): Use BL22_RP if has_22bit_branch.
- (elf32_hppa_check_relocs): Set has_22bit_branch.
-
- * elf32-hppa.c (elf32_hppa_check_relocs): Remove debug message.
- (final_link_relocate): Likewise.
-
-2002-04-22 Jakub Jelinek <jakub@redhat.com>
-
- * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't build
- search table if some FDE is DW_EH_PE_aligned encoded either.
- (_bfd_elf_write_section_eh_frame): Handle terminating FDE specially.
-
-2002-04-22 Richard Smith <richard@ex-parrot.com>
- Jakub Jelinek <jakub@redhat.com>
-
- * elf-eh-frame.c (struct eh_cie_fde): Add per_encoding_relative.
- (_bfd_elf_discard_section_eh_frame): Set it for CIEs with pcrel
- encoded personality.
- (_bfd_elf_write_section_eh_frame): Adjust pcrel encoded personality
- for CIE/FDE removal.
-
-2002-04-20 Tom Rix <trix@redhat.com>
-
- * coff64-rs6000.c (_bfd_xcoff64_swap_aux_in): Fix C_FILE auxent.
-
-2002-04-20 Alan Modra <amodra@bigpond.net.au>
-
- * archures.c (bfd_lookup_arch): Move the list order comment..
- (struct bfd_arch_info): ..to where it belongs.
+ * elf64-mmix.c (mmix_elf_relocate_section): Likewise.
+
+ 2004-03-19 Alan Modra <amodra@bigpond.net.au>
+ H.J. Lu <hongjiu.lu@intel.com>
+ * elflink.c (_bfd_elf_merge_symbol): Revert last change. Move
+ type and size change code to where it was previously. Remove
+ dt_needed param. Treat old weak syms as strong if new sym is
+ from a shared lib, even when old sym is from another shared
+ lib. Remove unnecessary tests of oldweak and newweak. Correct
+ comments.
+ (_bfd_elf_add_default_symbol): Remove dt_needed param. Update
+ _bfd_elf_merge_symbol calls.
+ * elflink.h (elf_link_add_object_symbols): Update calls. Remove
+ dt_needed local var. Update comments.
+ * elf-bfd.h (_bfd_elf_merge_symbol): Update prototype.
+ (_bfd_elf_add_default_symbol): Likewise.
+ * elflink.c (_bfd_elf_merge_symbol): Reinstate code to handle
+ strong syms in one shared object overriding weak syms in another.
+
+ 2004-03-18 Alan Modra <amodra@bigpond.net.au>
+ * elf-bfd.h (struct elf_obj_tdata): Delete dt_soname field. Add
+ dyn_lib_class field. Rearrange for better packing.
+ (elf_dt_soname): Delete.
+ (elf_dyn_lib_class): Define.
+ * elf.c (bfd_elf_set_dt_needed_name): Update comment.
+ (bfd_elf_set_dt_needed_soname): Delete.
+ (bfd_elf_set_dyn_lib_class): New function.
+ * elflink.h (add_dt_needed_tag): New function. Split out from..
+ (elf_link_add_object_symbols): ..here. Rename "name" to "soname".
+ Use elf_dyn_lib_class to set dt_needed and add_needed. Move fallback
+ initialization of soname.
+ (elf_link_check_versioned_symbol): Test elf_dyn_lib_class instead of
+ elf_dt_soname.
+ * bfd-in.h (enum dynamic_lib_link_class): New.
+ (bfd_elf_set_dt_needed_soname): Delete.
+ (bfd_elf_set_dyn_lib_class): Declare.
* bfd-in2.h: Regenerate.
+ * elflink.c (_bfd_elf_merge_symbol): Rewrite weak symbol handling.
+ (_bfd_elf_add_default_symbol): Remove indirect BFD_ASSERTs.
+ * elflink.h (elf_link_add_object_symbols): Don't clear dt_needed in
+ symbol loop. Instead use add_needed to flag tag as written.
+
+ 2004-03-03 Alexandre Oliva <aoliva@redhat.com>
+ * elflink.c (bfd_elf_record_link_assignment): Mark undefweak and
+ undefined symbols as hash_new.
+
+ 2004-02-28 H.J. Lu <hongjiu.lu@intel.com>
+ * elf-bfd.h (_bfd_elf_link_add_archive_symbols): New prototype.
+ * elflink.h (is_global_data_symbol_definition): Moved to
+ elflink.c.
+ (elf_link_is_defined_archive_symbol): Likewise.
+ (elf_link_add_archive_symbols): Likewise. Renamed to
+ _bfd_elf_link_add_archive_symbols.
+ * elflink.c (elf_link_is_defined_archive_symbol): Get the size
+ of ELF symbol table entry from backend.
+ (_bfd_elf_link_add_archive_symbols): Call bfd_link_add_symbols
+ instead of elf_link_add_object_symbols.
+
+ 2004-02-27 H.J. Lu <hongjiu.lu@intel.com>
+ * elflink.h (sort_symbol): New.
+ (elf_link_add_object_symbols): Use a sorted symbol array for
+ weakdef.
+
+ 2004-02-23 Jakub Jelinek <jakub@redhat.com>
+ * elflink.h (size_dynamic_sections): If not adding DT_FLAGS and
+ DF_BIND_NOW is set in info->flags, create DT_BIND_NOW dynamic entry.
+
+ 2004-02-21 H.J. Lu <hongjiu.lu@intel.com>
+ * elflink.c (_bfd_elf_merge_symbol): Properly handle undefined
+ symbols with non-default visibility.
+
+2004-03-22 Bob Wilson <bob.wilson@acm.org>
+
+ * elf32-xtensa.c (elf_xtensa_check_relocs): Remove code to read
+ literal tables and check for relocs outside of literal pools.
+ (elf_xtensa_make_sym_local): Don't clear ELF_LINK_NON_GOT_REF flag.
+ (elf_xtensa_fix_refcounts): Don't check ELF_LINK_NON_GOT_REF or
+ set DF_TEXTREL.
+ (elf_xtensa_size_dynamic_sections): Don't add DT_TEXTREL entry.
+ (elf_xtensa_relocate_section): Read literal tables and check for
+ dynamic relocations in read-only sections and not in literal pools.
+
+2004-03-23 Alan Modra <amodra@bigpond.net.au>
+
+ PR 51.
+ * linker.c (bfd_wrapped_link_hash_lookup): Handle info->wrap_char.
+
+2004-03-22 Hans-Peter Nilsson <hp@axis.com>
+
+ * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_16_GOTPLT,
+ R_CRIS_16_GOTPLT>: Also error if there's no PLT for a symbol
+ not defined by the executable, or defined in a DSO.
+ <eliding run-time relocation of .got>: Initialize GOT entry for a
+ function symbol or ELF_LINK_HASH_NEEDS_PLT statically in an
+ executable.
+ (cris_elf_gc_sweep_hook): Improve fallthrough marking.
+ (elf_cris_try_fold_plt_to_got): Improve head comment. Do not fold
+ a PLT reloc to GOT for an executable.
+ (elf_cris_adjust_dynamic_symbol): Only fold a .got.plt entry with
+ .got for a DSO and explain why.
+ (elf_cris_discard_excess_program_dynamics): Also lose GOT-relocs
+ and unreferenced symbols for which a PLT is defined. Adjust
+ dynamic-symbol pruning correspondingly, to make sure we don't lose
+ a dynamic symbol also defined by a DSO.
+
+2004-03-17 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
+
+ * config.bfd: Switch sh-*-rtems* to ELF. Add sh-*-rtemscoff*.
+
+2004-03-16 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.c (elf_link_read_relocs_from_section): Don't use
+ NUM_SHDR_ENTRIES in end of reloc calc. Move NULL shdr check..
+ (_bfd_elf_link_read_relocs): ..to here.
+ * elf32-ppc.c (ppc_elf_relax_section): Formatting.
- * archures.c (bfd_lookup_arch): Add comment on list order.
- (bfd_default_set_arch_mach): Use bfd_lookup_arch.
- * cpu-powerpc.c (bfd_powerpc_archs): Re-order so that the default
- is always at head of list.
-
-2002-04-18 Nick Clifton <nickc@cambridge.redhat.com>
-
- * coff-arm.c (coff_thumb_pcrel_12, coff_thumb_pcrel_9,
- insert_thumb_branch, record_thumb_to_arm_glue): Suppress
- definition of these functions for ARM_WINCE builds as they are
- not used.
- (SWAP_IN_RELOC_OFFSET, SWAP_OUT_RELOC_OFFSET): Do not define
- for ARM_WINCE builds.
-
-2002-04-18 Nick Clifton <nickc@cambridge.redhat.com>
-
- * coff-arm.c (bfd_arm_process_before_allocation):
-
-2002-04-17 J"orn Rennecke <joern.rennecke@superh.com>
-
- * cpu-sh.c (scan_mach): Delete.
- (arch_info_struct): Replace scan_mach with bfd_default_scan.
- (bfd_sh_arch): Likewise.
-
-2002-04-16 Nick Clifton <nickc@cambridge.redhat.com>
-
- * ihex.c (ihex_write_object_contents): Fix check for records
- crossing 64K boundaries.
-
-2002-04-16 Alan Modra <amodra@bigpond.net.au>
-
- * elf32-m32r.c (m32r_elf_add_symbol_hook): Check the hash table
- type rather than just assuming entries are ELF.
- * elf32-sh64.c (sh64_elf_add_symbol_hook): Likewise.
- * elf64-sh64.c (sh64_elf64_add_symbol_hook): Likewise.
- * elf64-sparc.c (sparc64_elf_add_symbol_hook): Likewise.
- * elf64-mmix.c (mmix_elf_add_symbol_hook): Use bfd_link_hash_entry
- rather than elf_link_hash_entry.
-
-2002-04-15 Richard Henderson <rth@redhat.com>
-
- * elf32-mips.c (mips_elf32_object_p): Revert 0404 fragment: allow
- n32 binaries.
-
-2002-04-15 Michael Snyder <msnyder@redhat.com>
-
- * opncls.c (bfd_close): Write contents if writeable.
- Minor formatting tidy-ups.
-
-2002-04-15 Alan Modra <amodra@bigpond.net.au>
-
- * elf32-ppc.c (ppc_elf_add_symbol_hook): Check the hash table type.
-
-2002-04-12 Michael Snyder <msnyder@redhat.com>
-
- * bfd-in.h (bfd_get_section_lma): New access macro.
- Minor white-space fix-up.
-
-2002-04-12 Alan Modra <amodra@bigpond.net.au>
-
- * elf.c (prep_headers): Don't zero EI_OSABI, EI_ABIVERSION or
- header pad.
-
-2002-04-09 DJ Delorie <dj@redhat.com>
-
- * elfarm-nabi.c (elf32_arm_howto_table): Fix ABS16 masks.
-
-2002-04-09 Casper S. Hornstrup <chorns@users.sourceforge.net>
-
- * coffcode.h (coff_read_word): New.
- (coff_compute_checksum): New.
- (coff_apply_checksum): New.
- (coff_write_object_contents): Call coff_apply_checksum () to
- apply checksum to PE image.
-
-2002-04-08 Randolph Chung <tausq@debian.org>
-
- * elf32-hppa.c (hppa_unwind_entry_compare): Move to elf-hppa.h.
- (elf32_hppa_final_link): Split out sorting logic to..
- * elf-hppa.h (elf_hppa_sort_unwind): ..here.
- (elf_hppa_final_link): Call elf_hppa_sort_unwind.
-
-2002-04-07 Andrew Cagney <ac131313@redhat.com>
-
- * configure.in: Add missing ``|'' to powerpc-*-aix4.[4-9]*
- pattern.
- * configure: Re-generate.
-
-2002-04-07 Andrew Cagney <ac131313@redhat.com>
-
- * configure.in: Only define AIX_CORE_DUMPX_CORE when AIX version
- is greater or equal to 4.3.3.
+ Merge from mainline.
+ 2004-02-20 Jakub Jelinek <jakub@redhat.com>
+ * elf32-ppc.c (allocate_dynrelocs): Create dynsym for undef weak
+ symbols used in PIE relocs.
+
+2004-03-16 Alan Modra <amodra@bigpond.net.au>
+
+ * configure.in (HOST_64BIT_TYPE, HOST_U_64BIT_TYPE): Don't override
+ values selected in configure.host. Require both to be defined
+ before setting BFD_HOST_64_BIT_DEFINED. Protect assignment to
+ corresponding BFD_HOST vars with quotes.
+ <${host64}-${target64}-${want64} in *true*>: Don't exempt gcc;
+ Always require BFD_HOST_64_BIT_DEFINED.
+ <file_ptr type>: Find off_t size before emitting message. Combine
+ off_t and ftello64 conditional.
* configure: Regenerate.
- Fix PR gdb/344.
-
-2002-04-05 Hans-Peter Nilsson <hp@axis.com>
-
- * elf32-cris.c (cris_elf_howto_table) <R_CRIS_16_PCREL,
- R_CRIS_32_PCREL>: Fix typo in name.
- (cris_elf_check_relocs): Always create .rela.got here when
- R_CRIS_16_GOTPLT or R_CRIS_32_GOTPLT is seen.
- (elf_cris_adjust_gotplt_to_got): Don't create .rela.got here;
- assume it's created.
-
-2002-04-04 Daniel Jacobowitz <drow@mvista.com>
-
- * aout-adobe.c (aout_32_bfd_link_hash_table_free): Define.
- * aout-target.h (MY_bfd_link_hash_table_free): Conditionally
- define.
- * aout-tic30.c (MY_bfd_link_hash_table_free): Likewise.
- * bfd.c (bfd_link_hash_table_free): Define.
- * binary.c (binary_bfd_link_hash_table_free): Define.
- * bout.c (b_out_bfd_link_hash_table_free): Define.
- * coff-rs6000.c (rs6000coff_vec): Include
- _bfd_generic_link_hash_table_free.
- (pmac_xcoff_vec): Likewise.
- * coff64-rs6000.c (rs6000coff64_vec): Likewise.
- (aix5coff64_vec): Likewise.
- * coffcode.h (coff_bfd_link_hash_table_free): Conditionally define.
- * elf-m10300.c (elf32_mn10300_link_hash_table_free): New function.
- (bfd_elf32_bfd_link_hash_table_free): Define.
- * elf32-hppa.c (elf32_hppa_link_hash_table_free): New function.
- (bfd_elf32_bfd_link_hash_table_free): Define.
- * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_free): Conditionally
- define.
- * i386msdos.c (msdos_bfd_link_hash_table_free): Define.
- * i386os9k.c (os9k_bfd_link_hash_table_free): Define.
- * ieee.c (ieee_bfd_link_hash_table_free): Define.
- * ihex.c (ihex_bfd_link_hash_table_free): Define.
- * libbfd-in.h (_bfd_nolink_bfd_link_hash_table_free): Define.
- (_bfd_generic_link_hash_table_free): Add prototype.
- * libcoff-in.h (_bfd_xcoff_bfd_link_hash_table_free): Add prototype.
- * libecoff.h (_bfd_ecoff_bfd_link_hash_table_free): Define.
- * linker.c (_bfd_generic_link_hash_table_free): New function.
- * mmo.c (mmo_bfd_link_hash_table_free): Define.
- * nlm-target.h (nlm_bfd_link_hash_table_free): Define.
- * oasys.c (oasys_bfd_link_hash_table_free): Define.
- * ppcboot.c (ppcboot_bfd_link_hash_table_free): Define.
- * som.c (som_bfd_link_hash_table_free): Define.
- * srec.c (srec_bfd_link_hash_table_free): Define.
- * tekhex.c (tekhex_bfd_link_hash_table_free): Define.
- * versados.c (versados_bfd_link_hash_table_free): Define.
- * vms.c (vms_bfd_link_hash_table_free): New function.
- * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_free): New function.
-
- * coff-arm.c (coff_arm_link_hash_table_create): Use bfd_malloc
- instead of bfd_alloc.
- * coff-h8300.c (h8300_coff_link_hash_table_create): Likewise.
- * coff-mcore.c (coff_mcore_link_hash_table_create): Likewise.
- * coff-ppc.c (ppc_coff_link_hash_table_create): Likewise.
- * cofflink.c (_bfd_coff_link_hash_table_create): Likewise.
- * ecoff.c (_bfd_ecoff_bfd_link_hash_table_create): Likewise.
- * elf-m10300.c (elf32_mn10300_link_hash_table_create): Likewise.
- * elf.c (_bfd_elf_link_hash_table_create): Likewise.
- * elf32-arm.h (elf32_arm_link_hash_table_create): Likewise.
- * elf32-cris.c (elf_cris_link_hash_table_create): Likewise.
- * elf32-hppa.c (elf32_hppa_link_hash_table_create): Likewise.
- * elf32-i386.c (elf_i386_link_hash_table_create): Likewise.
- * elf32-m68k.c (elf_m68k_link_hash_table_create): Likewise.
- * elf32-s390.c (elf_s390_link_hash_table_create): Likewise.
- * elf32-sh.c (sh_elf_link_hash_table_create): Likewise.
- * elf64-alpha.c (elf64_alpha_bfd_link_hash_table_create): Likewise.
- * elf64-ppc.c (ppc64_elf_link_hash_table_create): Likewise.
- * elf64-s390.c (elf_s390_link_hash_table_create): Likewise.
- * elf64-sh64.c (sh64_elf64_link_hash_table_create): Likewise.
- * elf64-sparc.c (sparc64_elf_bfd_link_hash_table_create): Likewise.
- * elf64-x86-64.c (elf64_x86_64_link_hash_table_create): Likewise.
- * elfxx-mips.c (_bfd_mips_elf_link_hash_table_create): Likewise.
- * linker.c (_bfd_generic_link_hash_table_create): Likewise.
- * m68klinux.c (linux_link_hash_table_create): Likewise.
- * sparclinux.c (linux_link_hash_table_create): Likewise.
- * sunos.c (sunos_link_hash_table_create): Likewise.
- * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_create): Likewise.
-
- * targets.c: Add _bfd_link_hash_table_free to xvec.
-
- * bfd-in2.h: Regenerate.
- * libbfd.h: Regenerate.
- * libcoff.h: Regenerate.
-
-2002-04-04 Alan Modra <amodra@bigpond.net.au>
-
- * dep-in.sed: Cope with absolute paths.
- * Makefile.am (dep.sed): Subst TOPDIR, and not INCDIR.
- Run "make dep-am".
- * Makefile.in: Regenerate.
- * coff-arm.c: Fix copyright date.
- * cpu-h8300.c: Likewise.
- * cpu-i370.c: Likewise.
- * cpu-s390.c: Likewise.
- * cpu-mips.c: Likewise.
- * po/SRC-POTFILES.in: Regenerate.
-
-2002-04-04 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
- * Makefile.am: Add elfxx-mips.c to the known backends.
- (elf32-mips.lo): remove dependency to coff/external.h.
- * Makefile.in: Regenerate.
- * configure.in: Add elfxx-mips.lo to all vectors using elf32-mips.lo
- Remove elf32-mips.lo from 64 bit vectors. Update dependencies
- accordingly.
+2004-03-16 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-m32r.c (m32r_elf_create_dynamic_sections): Fix pointer
+ aliasing warning. Remove trailing whitespace throughout file.
+
+2004-03-15 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
+
+ * elf-hppa.h (elf_hppa_relocate_section): Pass input_bfd instead of
+ input_section in calls to get_dyn_name.
+ * elf64-hppa.c (get_dyn_name): Change type of first argument to "bfd *". Use section id of first section in input BFD to build dynamic name for
+ local symbols.
+ (elf64_hppa_check_relocs): Pass abfd in call to get_dyn_name.
+
+2004-03-15 Alan Modra <amodra@bigpond.net.au>
+
+ * bfd-in.h (bfd_int64_t, bfd_uint64_t): New types.
+ (BFD_HOST_64_BIT, BFD_HOST_U_64_BIT): Don't define here.
+ (bfd_getb64, bfd_getl64, bfd_get_bits): Return bfd_uint64_t.
+ (bfd_getb_signed_64, bfd_getl_signed_64): Return bfd_int64_t.
+ (bfd_putb64, bfd_putl64, bfd_put_bits): Accept bfd_uint64_t.
+ * configure.in (HOST_U_64BIT_TYPE): Set when sizeof long is 8.
+ (BFD_HOST_64_BIT_DEFINED, BFD_HOST_64_BIT, BFD_HOST_U_64_BIT): Set
+ when using long.
+ * libbfd.c (EIGHT_GAZILLION, COERCE64): Use bfd_int64_t.
+ (bfd_getb64): Return bfd_uint64_t. Enable when BFD_HOST_64_BIT.
+ (bfd_getl64, bfd_getb_signed_64, bfd_getl_signed_64): Likewise.
+ (bfd_putb64): Accept bfd_uint64_t. Enable when BFD_HOST_64_BIT.
+ (bfd_putl64, bfd_put_bits, bfd_get_bits): Likewise.
+ * dwarf2.c (struct attribute): Use bfd_int64_t and bfd_uint64_t.
+ (read_8_bytes, read_indirect_string, read_address): Likewise.
+ (read_abbrevs, parse_comp_unit): Likewise.
+ * targets.c (struct bfd_target): Likewise.
+ * aix386-core.c (NO_GET64, NO_PUT64, NO_GETS64): Define and use.
+ * hppabsd-core.c: Likewise. Formatting.
+ * hpux-core.c: Likewise.
+ * irix-core.c: Likewise.
+ * netbsd-core.c: Likewise.
+ * osf-core.c: Likewise.
+ * ptrace-core.c: Likewise.
+ * sco5-core.c: Likewise.
+ * trad-core.c: Likewise.
* configure: Regenerate.
- * elf-bfd.h: Move all MIPS ELF specific prototypes to elfxx-mips.h.
- (irix_compat_t): IRIX compatibility level, moved from elf32-mips.c.
- (elf_backend_mips_irix_compat, elf_backend_mips_rtype_to_howto): New
- MIPS specific backend functions.
- * elf32-mips.c: Moved most code to elfxx-mips.c.
- (mips_elf_hi16_reloc): Rename from _bfd_mips_elf_hi16_reloc and make
- static.
- (mips_elf_lo16_reloc): Likewise, was _bfd_mips_elf_lo16_reloc.
- (mips_elf_got16_reloc): Likewise, was _bfd_mips_elf_got16_reloc.
- (mips_elf_gprel32_reloc): Likewise, was _bfd_mips_elf_gprel32_reloc.
- (mips_elf32_rtype_to_howto): Rename from mips_rtype_to_howto. Changed
- interface to allow selection of the right REL or RELA howto table.
- (mips_elf32_object_p): Rename from _bfd_mips_elf_object_p and made
- static. Let it refuse n32 objects.
- (elf32_mips_grok_prstatus): Rename from _bfd_elf32_mips_grok_prstatus.
- (elf32_mips_grok_psinfo): Rename from _bfd_elf32_mips_grok_psinfo.
- (elf32_mips_discard_info): Rename from _bfd_elf32_mips_discard_info.
- (elf32_mips_ignore_discarded_relocs): Rename from
- _bfd_elf32_mips_ignore_discarded_relocs.
- (elf32_mips_write_section): Rename from _bfd_elf32_mips_write_section.
- (elf32_mips_irix_compat): New function, replaces IRIX_COMPAT.
- (elf_mips_howto_table_rela): Remove.
- * elf64-mips.c: Moved most code to elfxx-mips.c.
- (bfd_elf64_bfd_reloc_type_lookup): Make static.
- (mips_elf64_rtype_to_howto): New function.
- (mips_elf64_object_p): Likewise.
- (elf64_mips_irix_compat): Likewise.
- * elfxx-mips.c: New file containing common code merged together from
- elf32-mips.c and elf64-mips.c.
- * elfxx-mips.h: New file containing MIPS specific prototypes from
- elf-bfd.h.
- * elfxx-target.h: Add handling for elf_backend_mips_irix_compat and
- elf_backend_mips_rtype_to_howto.
-
-2002-04-04 Alan Modra <amodra@bigpond.net.au>
-
- * srec.c (MAXCHUNK, Chunk): Revise comments.
- (srec_write_record): Correct buffer size.
- (srec_write_header): Do without intermediate buffer.
- (srec_write_section): Validate Chunk.
- (srec_write_terminator): Pass NULL instead of dummy buffer.
- (srec_write_symbols): Pass file and symbol names directly to
- bfd_bwrite so sprintf won't overflow buffer.
-
-2002-04-03 Jakub Jelinek <jakub@redhat.com>
-
- * elf32-sparc.c (elf32_sparc_relocate_section): Don't emit dynamic
- PC relative relocs against hidden symbols.
- * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
-
-2002-04-03 Alan Modra <amodra@bigpond.net.au>
-
- * elf.c (_bfd_elf_make_section_from_shdr): When setting section
- LMAs, loop over segments until p_vaddr and p_memsz specify an
- extent enclosing the section.
-
-2002-04-02 Nick Clifton <nickc@cambridge.redhat.com>
-
- * ihex.c (ihex_write_object_contents): Do not allow records to
- cross a 64K boundary - wrap if necessary.
-
-2002-04-01 Nathan Williams <nathanw@wasabisystems.com>
-
- * elf.c (elfcore_netbsd_get_lwpid): Fix off-by-one error
- which caused the returned LWP ID to always be 0.
-
-2002-04-01 Richard Henderson <rth@redhat.com>
-
- * elf32-sparc.c (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
- (elf32_sparc_relocate_section): Use it to figure out when to
- initialize .got entries.
- * elf64-sparc.c: Similarly.
-
-2002-03-28 Alan Modra <amodra@bigpond.net.au>
-
- * linker.c (link_action): Ignore duplicate warning syms.
- (_bfd_generic_link_write_global_symbol): Follow warning symbol link.
- * elflink.h (elf_adjust_dynstr_offsets): Likewise.
- (elf_adjust_dynamic_symbol): Likewise.
- (elf_export_symbol): Likewise.
- (elf_link_find_version_dependencies): Likewise.
- (elf_link_assign_sym_version): Likewise.
- (elf_link_sec_merge_syms): Likewise.
- (elf_link_output_extsym): Likewise.
- (elf_gc_sweep_symbol): Likewise.
- (elf_gc_propagate_vtable_entries_used): Likewise.
- (elf_gc_smash_unused_vtentry_relocs): Likewise.
- (elf_gc_allocate_got_offsets): Likewise.
- (elf_collect_hash_codes): Likewise.
- * elflink.c (elf_link_renumber_hash_table_dynsyms): Likewise.
- * elf-hppa.h (elf_hppa_unmark_useless_dynamic_symbols): Likewise.
- (elf_hppa_remark_useless_dynamic_symbols): Likewise.
- * elf-m10300.c (elf32_mn10300_finish_hash_table_entry): Likewise.
- * elf32-arm.h (elf32_arm_discard_copies): Likewise.
- * elf32-cris.c (elf_cris_adjust_gotplt_to_got): Likewise.
- (elf_cris_discard_excess_dso_dynamics): Likewise.
- * elf32-hppa.c (clobber_millicode_symbols): Likewise.
- (mark_PIC_calls): Likewise.
- (allocate_plt_static): Likewise.
- (allocate_dynrelocs): Likewise.
- (readonly_dynrelocs): Likewise.
- * elf32-i386.c (allocate_dynrelocs): Likewise.
- (readonly_dynrelocs): Likewise.
- * elf32-i370.c (i370_elf_adjust_dynindx): Likewise.
- * elf32-m68k.c (elf_m68k_discard_copies): Likewise.
- * elf32-mips.c (mips_elf_output_extsym): Likewise.
- (mips_elf_sort_hash_table_f): Likewise.
- (mips_elf_check_mips16_stubs): Likewise.
- * elf32-s390.c (allocate_dynrelocs): Likewise.
- (readonly_dynrelocs): Likewise.
- * elf32-sh.c (sh_elf_discard_copies): Likewise.
- * elf32-xstormy16.c (xstormy16_relax_plt_check): Likewise.
- (xstormy16_relax_plt_realloc): Likewise.
- * elf64-alpha.c (elf64_alpha_calc_got_offsets_for_symbol): Likewise.
- (elf64_alpha_output_extsym): Likewise.
- * elf64-hppa.c (elf64_hppa_mark_exported_functions): Likewise.
- * elf64-mips.c (mips_elf64_sort_hash_table_f): Likewise.
- (mips_elf64_check_mips16_stubs): Likewise.
- (mips_elf64_output_extsym): Likewise.
- * elf64-ppc.c (func_desc_adjust): Likewise.
- (allocate_dynrelocs): Likewise.
- (readonly_dynrelocs): Likewise.
- * elf64-s390.c (allocate_dynrelocs): Likewise.
- (readonly_dynrelocs): Likewise.
- * elf64-sh64.c (sh64_elf64_discard_copies): Likewise.
- * elf64-x86-64.c (allocate_dynrelocs): Likewise.
- (readonly_dynrelocs): Likewise.
- * elfxx-ia64.c (elfNN_ia64_global_dyn_sym_thunk): Likewise.
- * aoutx.h (aout_link_write_other_symbol): Likewise.
- * cofflink.c (_bfd_coff_write_task_globals): Likewise.
- (_bfd_coff_write_global_sym): Likewise.
- * i386linux.c (linux_tally_symbols): Likewise.
- * m68klinux.c (linux_tally_symbols): Likewise.
- * sparclinux.c (linux_tally_symbols): Likewise.
- * pdp11.c (aout_link_write_other_symbol): Likewise.
- * sunos.c (sunos_scan_dynamic_symbol): Likewise.
- * xcofflink.c (xcoff_build_ldsyms): Likewise.
- (xcoff_write_global_symbol): Likewise.
-
- * cofflink.c (_bfd_coff_final_link): Formatting.
- * cpu-mips.c (mips_compatible): Make static, prototype.
- * elf32-i386.c (elf_i386_check_relocs): Formatting.
- * elf32-sh.c (sh_elf_size_dynamic_sections): Likewise.
- * elf64-alpha.c (elf64_alpha_output_extsym): Likewise.
- * elf64-mips.c (mips_elf64_sort_hash_table): Likewise.
- (mips_elf64_final_link): Likewise.
- * elflink.h (elf_link_find_version_dependencies): Remove duplicate
- prototype.
-
-2002-03-27 Nick Clifton <nickc@cambridge.redhat.com>
-
- * coff-arm.c (SWAP_IN_RELOC_OFFSET): Define.
- (SWAP_OUT_RELOC_OFFSET): Define.
-
-2002-03-27 Gregory Steuck <greg@nest.cx>
-
- * elf.c (_bfd_elf_get_symtab_upper_bound): Leave space for
- terminating NULL if empty symbol table.
- (_bfd_elf_get_dynamic_symtab_upper_bound): Likewise.
-
-2002-03-26 H.J. Lu (hjl@gnu.org)
-
- * elflink.h (elf_link_input_bfd): Revert the last change since
- the gcc exception handling isn't fixed yet.
-
-2002-03-26 H.J. Lu (hjl@gnu.org)
-
- * elflink.h (elf_link_input_bfd): Complain about relocations
- against local symbols in discarded sections.
-
-2002-03-26 Alan Modra <amodra@bigpond.net.au>
-
- * elflink.h (elf_gc_mark): Don't recurse into non-ELF sections.
-
-2002-03-23 Alan Modra <amodra@bigpond.net.au>
-
- * elf.c (_bfd_elf_make_section_from_shdr): Don't set lma based on
- section file offset for !SEC_LOAD sections.
-
-2002-03-21 Richard Earnshaw <rearnsha@arm.com>
-
- * elf32-arm.h (elf32_arm_final_link_relocate <case R_ARM_GOTOFF>,
- <case R_ARM_GOT>): Handle relocations to Thumb functions.
-
-2002-03-21 Alan Modra <amodra@bigpond.net.au>
-
- * coff64-rs6000.c (_bfd_xcoff64_put_symbol_name): Prototype.
- Whitespace changes.
- * archive.c: Update copyright date.
* bfd-in2.h: Regenerate.
- * libbfd.h: Regenerate.
- * Makefile.am: Run "make dep-am"
- * Makefile.in: Regenerate.
- * po/SRC-POTFILES.in: Regenerate.
-
-2002-03-20 Daniel Jacobowitz <drow@mvista.com>
-
- * dwarf2.c (struct funcinfo): Move up.
- (lookup_address_in_function_table): New argument function_ptr.
- Set it.
- (lookup_address_in_line_table): New argument function. If function
- is non-NULL, use it to handle ``addr'' before the first line note of
- the function.
- (comp_unit_find_nearest_line): Update and swap calls to
- lookup_address_in_function_table and lookup_address_in_line_table.
- * syms.c (_bfd_stab_section_find_nearest_line): Use the first
- N_SLINE encountered if we see an N_FUN before any N_SLINE.
-
-2002-03-20 Tom Rix <trix@redhat.com>
-
- * coff-rs6000.c (_bfd_xcoff_stat_arch_elt): Renamed from
- _bfd_xcoff_generic_stat_arch_elt. Fix format check.
- * coff64-rs6000.c : Use _bfd_xcoff_stat_arch_elt.
-
-2002-03-19 Tom Rix <trix@redhat.com>
-
- * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): Look through all
- dynamic objects in archives.
-
-2002-03-19 Hans-Peter Nilsson <hp@bitrange.com>
-
- * elflink.h (NAME(bfd_elf,record_link_assignment)): Don't set
- STT_NOTYPE symbols to STT_OBJECT.
-
-2002-03-18 Jan Hubicka <jh@suse.cz>
-
- * cpu-i386.c (bfd_x86_64_arch): Rename to "i386:x86-64"
-
-2002-03-18 Tom Rix <trix@redhat.com>
-
- * aix5ppc.core.c : New file for AIX 5 64 bit core support.
- * bfd-in.h : Add bfd_xcoff_ar_archive_set_magic declaration.
- * coff-rs6000 (do_pad) : New function for archive padding.
- (do_copy) : New function for object file copying in archives.
- (do_shared_object_padding) : New function for padding shared
- objects to their text section alignment in archives.
- (bfd_xcoff_ar_achive_set_magic) : Stub.
- (xcoff_write_armap_big) : Use do_copy and do_pad.
- (xcoff_write_archive_contents_big) : Use do_shared_object_padding,
- do_copy and do_pad.
- * coff64-rs6000.c (xcoff64_write_ojbect_contents) : Use
- bfd_xcoff_magic_number.
- (xcoff64_bad_format_hook) : New function for _bfd_bad_format_hook
- fop.
- (xcoff_backend_data_r) : Use xcoff64_bad_format_hook.
- (bfd_xcoff_aix5_backend_data) : New Aix 5 backend data.
- (aix5coff64_vec) : New Aix 5 target aix5coff64-rs6000.
- * rs6000-core.c : Update copyright date.
- * xcofflink.c (bfd_xcoff_size_dynamic_sections): Check for NULL
- csectpp.
- * coffcode.h (coff_new_section_hook) : Use new accessor macros.
- (coff_set_arch_mach_hook) : Add Aix 5 U64_TOCMAGIC magic #.
- (coff_set_flags) : Use bfd_xcoff_magic_number.
- * libxcoff.h (bfd_xcoff_is_xcoff64): Add U64_TOCMAGIC.
- * configure.in : Add powerpc-*-aix5 and rs6000-*-aix5 support.
- * Makefile.am : Same.
- * config.bfd : Same.
- * targets.c : Same.
- * configure : Regnerate.
- * Makefile.in : Same.
- * bfd-in2.h : Same.
-
-2002-03-18 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/fr.po: Updated version.
-
-2002-03-18 Alan Modra <amodra@bigpond.net.au>
-
- * libbfd.c (bfd_write_bigendian_4byte_int): Return true iff success.
- * libbfd.h: Regenerate.
- * archive.c (coff_write_armap): Pass on failures from
- bfd_write_bigendian_4byte_int.
-
-2002-03-14 H.J. Lu <hjl@gnu.org>
-
- * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set the BFD
- error to bfd_error_nonrepresentable_section for reinit_array
- section in DSO.
-
-2002-03-14 Nick Clifton <nickc@cambridge.redhat.com>
-
- * coffcode.h (coff_slurp_symbol_table): When adding BSF_WEAK flag,
- OR it in rather than replacing previously selected flags.
-
- * elfxx-target.h (TARGET_BIG_SYM): Set ar_max_namelen to 15.
- (TARGET_LITTLE_SYM): Set ar_max_namelen to 15.
-
-2002-03-14 Alan Modra <amodra@bigpond.net.au>
-
- * cpu-mips.c (mips_compatible): New. Don't check bits_per_word.
- (N): Use the above.
- * elflink.h (elf_bfd_final_link): Revert last change. Instead,
- ensure reloc size matches before calling elf_link_input_bfd.
- Add an assert to check reloc size when counting output relocs.
-
-2002-03-14 Nick Clifton <nickc@cambridge.redhat.com>
-
- * mmo.c (mmo_get_loc): Return NULL rather than false.
-
-2002-03-13 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/fr.po: Updated version.
-
-2002-03-13 Alan Modra <amodra@bigpond.net.au>
-
- * archures.c (bfd_default_compatible): Test bits_per_word.
- * cpu-i386.c (i386_compatible): Remove. Replace occurrences with
- bfd_default_compatible.
- * cpu-i370.c (i370_compatible): Likewise.
- * cpu-sparc.c (sparc_compatible): Likewise.
- * cpu-h8300.c (compatible): Test in->arch == out->arch.
-
- * elflink.h: Formatting fixes.
- (elf_link_output_extsym): Merge undefined and undef weak cases.
-
- * elflink.h (elf_bfd_final_link): Only call elf_link_input_bfd
- when word size of input matches output word size.
-
-2002-03-12 Andreas Jaeger <aj@suse.de>
-
- * cpu-i386.c (i386_compatible): New. Use it instead of
- bfd_default_compatible.
-
-2002-03-07 H.J. Lu (hjl@gnu.org)
-
- * coff-sh.c (shcoff_reloc_map): Use bfd_reloc_code_real_type
- as the type for bfd_reloc_val.
-
-2002-03-05 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * elf-hppa.h (elf_hppa_is_dynamic_loader_symbol): New function.
- (elf_hppa_relocate_section): Ignore undefined dynamic loader symbols.
- (elf_hppa_final_link_relocate): Correct relocations for indirect
- references to local data through the DLT. Fix .opd creation for
- local symbols using R_PARISC_LTOFF_FPTR32 and R_PARISC_FPTR64
- relocations. Use e_lsel selector for R_PARISC_DLTIND21L,
- R_PARISC_LTOFF_FPTR21L and R_PARISC_LTOFF_TP21L as per
- "Processor-Specific ELF for PA_RISC, Version 1.43" document.
- Similarly, use e_rsel for DLT and LTOFF 'R' relocations.
- * elf32-hppa.c (final_link_relocate): Revise relocation selectors
- as per "Processor-Specific ELF for PA_RISC, Version 1.43" document.
-
-2002-03-05 Jakub Jelinek <jakub@redhat.com>
-
- * merge.c (_bfd_merge_sections): Don't segfault if there
- is nothing to merge due to GC.
-
-2002-03-05 Alan Modra <amodra@bigpond.net.au>
- * elf32-hppa.c (clobber_millicode_symbols): Remove hack to keep
- symbols that have been forced local.
-
- * elflink.h (elf_bfd_final_link): Call elf_link_output_extsym
- to output forced local syms for non-shared link.
- (elf_link_output_extsym): Tweak condition for calling backend
- adjust_dynamic_symbol so that previous behaviour is kept.
- Whitespace changes throughout file.
-
-2002-03-04 H.J. Lu <hjl@gnu.org>
-
- * elf.c (bfd_section_from_shdr): Handle special sections,
- .init_array, .fini_array and .preinit_array.
- (elf_fake_sections): Likewise.
-
- * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Create the
- DT entry only if the section is in output for .init_array,
- .fini_array and .preinit_array. Complain about .preinit_array
- section in DSO.
- (elf_bfd_final_link): Warn zero size for .init_array,
- .fini_array and .preinit_array sections.
-
- * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Remove
- SHT_INIT_ARRAY, SHT_FINI_ARRAY and SHT_PREINIT_ARRAY.
- (elfNN_ia64_fake_sections): Remove .init_array, .fini_array and
- .preinit_array.
-
-2002-03-04 Alan Modra <amodra@bigpond.net.au>
-
- * configure.in (WIN32LIBADD): Don't eval PICFLAG assignment.
- * configure: Regenerate.
-
-2002-03-02 Tom Rix <trix@redhat.com>
-
- * coff64-rs6000.c (xcoff64_howto_table): Replace howto types with
- symbolic equiv.
- * coff-rs6000.c (xcoff_howto_table): Same.
-
-2002-03-01 David Mosberger <davidm@hpl.hp.com>
-
- * elflink.h (size_dynamic_sections): If section named
- ".preinit_array" exists, create DT_PREINIT_ARRAY and
- DT_PREINIT_ARRAYSZ entries in dynamic table. Analogously for
- ".init_array" and ".fini_array".
- (elf_bfd_final_link): Handle DT_PREINIT_ARRAYSZ, DT_INIT_ARRAYSZ,
- DT_FINI_ARRAYSZ, DT_PREINIT_ARRAY, DT_INIT_ARRAY, and
- DT_FINI_ARRAY.
-
-2002-02-26 Andrew Macleod <amacleod@cygnus.com>
-
- * elflink.h (elf_bfd_final_link): Don't crash on SHN_UNDEF local
- dynsyms.
-
-2002-02-25 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-hppa.h: Update copyright date.
-
- * elf64-ppc.c (ppc64_elf_check_relocs): Warning fix.
- (ppc64_elf_relocate_section): Don't generate power4 style branch
- hints for *_BRTAKEN and *_BRNTAKEN relocs.
-
-2002-02-22 Jakub Jelinek <jakub@redhat.com>
-
- * elf64-sh64.c (sh_elf64_relocate_section): Fix a typo from my
- last patch.
- * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
-
-2002-02-21 Andreas Jaeger <aj@suse.de>
-
- * elf64-x86-64.c: Major rework that introduces all recent changes
- to the x86-64 backend. Get a closer match to elf32-i386.
- (struct elf64_x86_64_dyn_relocs): Rename from
- elf64_x86_64_pcrel_relocs_copied, add additional fields. Change
- all users.
- (struct elf64_x86_64_link_hash_table): Add short cuts to some
- sections.
- (link_hash_newfunc): Rename from elf64_x86_64_link_hash_newfunc,
- remove casts, initialize new hash members.
- (create_got_section): New.
- (elf64_x86_64_create_dynamic_sections): New.
- (elf64_x86_64_copy_indirect_symbol): New.
- (elf64_x86_64_check_relocs): Don't allocate space for dynamic
- relocs, .got or .relgot here but do it in allocate_dynrelocs.
- Reference count possible .plt and .got entries. Don't test input
- section SEC_READONLY here to try to avoid copy relocs, and keep
- dyn_relocs regardless of ELF_LINK_NON_GOT_REF. Don't set
- DF_TEXTREL here. Delay setting of variables until needed. Cache
- pointer to "sreloc" section in elf_section_data. Tweak condition
- under which .got created. Report files with bad relocation
- section names.
- (elf64_x86_64_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
- Reference count possible .plt entries. Don't deallocate .got and
- .relgot space here.
- (elf64_x86_64_adjust_dynamic_symbol): Handle nocopyreloc. Don't
- do copy reloc processing for weakdefs. Remove redundant casts and
- aborts. Delay setting of vars until needed. Move creation of
- dynamic symbols and allocation of .plt and .rela.plt to
- allocate_dynrelocs. Replace BFD_ASSERT with abort.
- (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
- (allocate_dynrelocs): New.
- (readonly_dynrelocs): New.
- (elf64_x86_64_size_dynamic_sections): Call readonly_dynrelocs.
- Allocate space for dyn relocs. Replace BFD_ASSERT with abort.
- Zero out the dynamic allocated content space.
- (elf64_x86_64_discard_copies): Removed.
- (elf64_x86_64_relocate_section): Make use of dynamic section
- short-cuts. Localise vars, and delay setting. Better error
- reporting, replace BFD_ASSERT with abort. Check
- ELF_LINK_HASH_DEF_DYNAMIC to see if a symbol is not defined in the
- regular object file and tread the weak definition as the normal
- one. Don't discard relocs for undefweak or undefined symbols and
- check !DEF_REGULAR as well as DEF_DYNAMIC in test for avoided copy
- relocs.
- (elf64_x86_64_finish_dynamic_symbol): Don't copy relocs for
- symbols that have been forced local. Use same test to decide if
- we can use a relative reloc for got as relocate_section. Expand
- SHN_UNDEF comment. Move expressions out of function calls.
- Replace BFD_ASSERT with abort.
- (bfd_elf64_bfd_final_link): Removed.
- (elf_backend_copy_indirect_symbol): Define.
-
-2002-02-20 Tom Rix <trix@redhat.com>
-
- * coff-rs6000.c (xcoff_howto_table): Add 16 bit R_BA.
- (_bfd_xcoff_reloc_type_lookup): Use it.
- * coff64-rs6000.c (xcoff64_howto_table): Same.
- (xcoff64_reloc_type_lookup): Same.
-
-2002-02-20 Peter Schauer <pes@regent.e-technik.tu-muenchen.de>
-
- * osf-core.c (osf_core_vec): OSF/1 (Digital Unix) core files are
- little endian.
-
-2002-02-19 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * archures.c (bfd_mach_s390_esa): Rename to bfd_mach_s390_31.
- (bfd_mach_s390_esame): Rename to bfd_mach_s390_64.
- * bfd-in2.h: Regenerate.
- * cpu-s390.c (arch_info_struct): Use renamed architecture defines.
- Replace architecture name "s390" with "s390:31-bit" and "s390:esame"
- with "s390:64-bit".
- * elf32-s390.c (elf_howto_table): Add 32 bit pc relative relocations.
- (elf_s390_reloc_type_lookup): Likewise.
- (elf_s390_check_relocs): Likewise.
- (elf_s390_gc_sweep_hook): Likewise.
- (elf_s390_relocate_section): Likewise.
- (elf_s390_object_p): Use renamed architecture define.
- * elf64-s390.c (elf_s390_object_p): Use renamed architecture define.
-
-2002-02-19 Frank Ch. Eigler <fche@redhat.com>
-
- * syms.c (stt[]): Sorted. Added .init/.fini -> "t" mapping.
-
-2002-02-19 Jakub Jelinek <jakub@redhat.com>
-
- * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Enable
- absptr -> pcrel optimization for shared libs.
- Only create minimal .eh_frame_hdr if absptr FDE encoding in shared
- library cannot be converted to pcrel.
- (_bfd_elf_eh_frame_section_offset): Return -2 if making absptr
- relative.
- * elf32-i386.c (elf_i386_relocate_section): If
- _bfd_elf_section_offset returned -2, skip, but make sure the
- relocation is installed.
- * elf32-arm.h (elf32_arm_final_link_relocate): Likewise.
- * elf32-cris.c (cris_elf_relocate_section): Likewise.
- * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
- * elf32-i370.c (i370_elf_relocate_section): Likewise.
- * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
- * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
- * elf32-s390.c (elf_s390_relocate_section): Likewise.
- * elf32-sh.c (sh_elf_relocate_section): Likewise.
- * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
- * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
- * elf64-s390.c (elf_s390_relocate_section): Likewise.
- * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
- * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
- * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
- * elf64-alpha.c (elf64_alpha_relocate_section): Handle
- _bfd_elf_section_offset returning -2 the same way as -1.
- * elfxx-ia64.c (elfNN_ia64_install_dyn_reloc): Likewise.
- * elf32-mips.c (mips_elf_create_dynamic_relocation): Add FIXME
- and BFD_ASSERT.
- * elf64-mips.c (mips_elf64_create_dynamic_relocation): Likewise.
-
-2002-02-18 Tom Rix <trix@redhat.com>
-
- * xcofflink.c (bfd_xcoff_link_gernate_rtinit): Add -brtl support.
- (bfd_xcoff_size_dynamic_sections): Same.
- * bfd-in.h (bfd_xcoff_link_generate_rtinit): Same.
- (bfd_xcoff_size_dynamic_sections): Same.
- * coff-rs6000.c (xcoff_generate_rtinit): Same.
- * coff-rs646000.c (xcoff64_generate_rtinit): Same.
- * libxcoff.h (struct xcoff_backend_data_rec): Same.
- * xcofflink.c (xcoff_build_ldsyms, xcoff_link_add_symbols): Clean.
+2004-03-15 Alan Modra <amodra@bigpond.net.au>
+
+ * bfd-in.h (bfd_getb64, bfd_getl64): Replace bfd_byte* with void*.
+ (bfd_getb32, bfd_getl32, bfd_getb16, bfd_getl16): Likewise.
+ (bfd_getb_signed_64, bfd_getl_signed_64): Likewise.
+ (bfd_getb_signed_32, bfd_getl_signed_32): Likewise.
+ (bfd_getb_signed_16, bfd_getl_signed_16): Likewise.
+ (bfd_putb64, bfd_putl64, bfd_putb32, bfd_putl32): Likewise.
+ (bfd_putb16, bfd_putl16, bfd_get_bits, bfd_put_bits): Likewise.
+ * libbfd.c: Likewise in function definitions.
+ (bfd_put_8): Mask with 0xff rather than casting to char.
+ (bfd_putb16, bfd_putl16, bfd_putb32, bfd_putl32): Likewise.
+ (bfd_putb64, bfd_putl64, bfd_put_bits): Likewise.
+ (H_PUT_64, H_PUT_32, H_PUT_16, H_PUT_8): Remove casts, simplify.
+ (H_PUT_S64, H_PUT_S32, H_PUT_S16, H_PUT_S8): Likewise.
+ (H_GET_64, H_GET_32, H_GET_16, H_GET_8): Likewise.
+ (H_GET_S64, H_GET_S32, H_GET_S16, H_GET_S8): Likewise.
+ * libaout.h (H_PUT_64 H_PUT_32, H_PUT_16): Remove casts, simplify.
+ (H_PUT_S64, H_PUT_S32, H_PUT_S16): Likewise.
+ (H_GET_64, H_GET_32, H_GET_16): Likewise.
+ (H_GET_S64, H_GET_S32, H_GET_S16): Likewise.
+ * archive.c (do_slurp_coff_armap): Update swap prototype.
+ * coff-tic54x.c (tic54x_getl32): Replace bfd_byte* with void*.
+ (tic54x_getl_signed_32): Likewise.
+ (tic54x_putl32): Likewise. Mask with 0xff rather than casting to char.
+ * mach-o.c (bfd_mach_o_read_header): Update get32 prototype.
+ * pdp11.c (bfd_getp32): Make static, replace bfd_byte* with void*.
+ (bfd_getp_signed_32, bfd_putp32): Likewise.
+ * targets.c (struct bfd_target): Use void* in place of bfd_byte* for
+ bfd_getx64, bfd_getx_signed_64, bfd_putx64, bfd_getx32,
+ bfd_getx_signed_32, bfd_putx32, bfd_getx16, bfd_getx_signed_16,
+ bfd_putx16, bfd_h_getx64, bfd_h_getx_signed_64, bfd_h_putx64,
+ bfd_h_getx32, bfd_h_getx_signed_32, bfd_h_putx32, bfd_h_getx16,
+ bfd_h_getx_signed_16, bfd_h_putx16.
+ * aix386-core.c (NO_GET, NO_GETS, NO_PUT): Update prototypes.
+ * hppabsd-core.c: Similarly. Rename NO_SIGNED_GET to NO_GETS.
+ * hpux-core.c: Likewise.
+ * irix-core.c: Likewise.
+ * netbsd-core.c: Likewise.
+ * osf-core.c: Likewise.
+ * ptrace-core.c: Likewise.
+ * sco5-core.c: Likewise.
+ * trad-core.c: Likewise.
* bfd-in2.h: Regenerate.
-2002-02-18 Alan Modra <amodra@bigpond.net.au>
+2004-03-15 Matt Thomas <matt@3am-software.com>
- * elf64-ppc.c (STFD_FR0_0R1, LFD_FR0_0R1, BLR): Define.
- (struct ppc_link_hash_table): Add sfpr.
- (ppc64_elf_link_hash_table_create): Init it.
- (ppc64_elf_create_dynamic_sections): Split creation of .stub and
- .glink out to..
- (create_linkage_sections): ..here. Make .sfpr too.
- (ppc64_elf_check_relocs): Call create_linkage_sections, and set
- dynobj early.
- (MIN_SAVE_FPR, MAX_SAVE_FPR): Define.
- (ppc64_elf_func_desc_adjust): Look for missing ._savef* and
- ._restf* functions, and create as needed.
- (func_desc_adjust): Only force_local for shared libs.
+ * config.bfd: Add x86-64 vector to NetBSD/i386 if 64bit BFD is
+ selected.
-2002-02-18 David O'Brien <obrien@FreeBSD.org>
+2004-03-13 Mark Kettenis <kettenis@gnu.org>
- * configure.in: Bump version number post 2.12 branching.
+ * config.bfd: Add x86_64-*-openbsd*.
+ * configure.in (x86_64-*-openbsd*): Set COREFILE to
+ netbsd-core.lo.
* configure: Regenerate.
-2002-02-17 Hans-Peter Nilsson <hp@bitrange.com>
-
- * mmo.c: Correct and improve comments.
- (mmo_write_chunk): Store trailing byte in bfd buffer; don't
- zero-pad. Use input to fill up non-empty bfd buffer.
- (mmo_flush_chunk): New function.
- (mmo_write_loc_chunk): Add parameter last_vmap, all callers
- changed. Don't emit location specifier if VMA is same as
- *LAST_VMAP after omitting leading zero contents. Call
- mmo_flush_chunk before emitting location specifier.
- (mmo_write_loc_chunk_list): Call mmo_flush_chunk when finished
- with mmo_write_loc_chunk calls.
- (mmo_internal_write_section): Call mmo_flush_chunk after
- mmo_write_chunk.
- (mmo_write_symbols_and_terminator): Move :Main to first position
- in symbol array. Add faked one if it does not exist if there are
- other symbols. Don't add it if there are no symbols at all. Move
- out test for value of :Main from symbol loop. Rename table
- fakemain to maintable and variable mainsym to fakemain.
-
-2002-02-15 Richard Henderson <rth@redhat.com>
+2004-03-09 Steve Ellcey <sje@cup.hp.com>
- * elf64-alpha.c (elf64_alpha_relocate_section) [BRSGP]: A target
- section with no got matches any got. Simplify error generaion.
+ * elfxx-ia64.c (plt_full_entry): Change ld8 to ld8.acq.
-2002-02-15 Alan Modra <amodra@bigpond.net.au>
+2004-03-05 Nathan Sidwell <nathan@codesourcery.com>
- Support arbitrary length fill patterns.
- * linker.c (bfd_new_link_order): Zero all fields with bfd_zalloc.
- (_bfd_default_link_order): Remove bfd_fill_link_order code.
- Call default_data_link_order.
- (default_fill_link_order): Delete.
- (default_data_link_order): New function.
- * elf32-mips.c (_bfd_mips_elf_final_link): Replace occurrences
- of bfd_fill_link_order with bfd_data_link_order.
- * elf64-alpha.c (elf64_alpha_final_link): Likewise.
- * elf64-mips.c (mips_elf64_final_link): Likewise.
+ * elf.c (map_sections_to_segments): Ignore .tbss sections for
+ layout purposes.
- * bfd.c (bfd_scan_vma): Clamp overflows to max bfd_vma value.
- Correct value returned in "end" for "0x<non-hex>".
-
-2002-02-14 Nick Clifton <nickc@cambridge.redhat.com>
-
- * cpu-arm.c (processors): Replace 'arch' field with 'mach'.
- (scan): Test against 'mach' field in info structure.
-
-2002-02-14 Alan Modra <amodra@bigpond.net.au>
-
- * elf.c (elf_fake_sections): Use SHT_NOBITS when SEC_NEVER_LOAD.
-
-2002-02-14 Matt Fredette <fredette@netbsd.org>
-
- * elf32-m68k.c (elf32_m68k_print_private_bfd_data): Recognize
- EF_M68000.
-
-2002-02-13 Nick Clifton <nickc@cambridge.redhat.com>
-
- * elf.c (_bfd_elf_make_section_from_shdr): Do not insist on
- non-zero physical addresses when adjusting the LMAs of new
- sections.
-
-2002-02-12 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * elf-hppa.h (elf_hppa_reloc_final_type): New function stripped
- from _bfd_elf_hppa_gen_reloc_type.
- (_bfd_elf_hppa_gen_reloc_type): Remove duplicate prototype.
- * elf32-hppa.h (elf32_hppa_reloc_final_type): Add protptype.
- * elf32-hppa.c: Include elf32-hppa.h before elf-hppa.h.
- * elf64-hppa.h (elf64_hppa_reloc_final_type): Add protptype.
-
-2002-02-12 Alexandre Oliva <aoliva@redhat.com>
-
- * elf-m10300.c (mn10300_elf_relax_section): Skip section before
- loading its contents if there's nothing to do in it.
-
-2002-02-12 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (ppc64_elf_size_stubs): Correct test for crossing
- 64k boundary.
-
- * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Add dynamic
- DT_PPC64_OPD and DT_PPC64_OPDSZ tags.
- (ppc64_elf_finish_dynamic_sections): Set values for them.
-
-2002-02-11 Michael Snyder <msnyder@redhat.com>
-
- * elf-bfd.h (elfcore_write_lwpstatus): Add prototype.
- * elf.c (elfcore_grok_pstatus): Add prototype.
- (elfcore_grok_lwpstatus): Add prototype.
- (elfcore_write_lwpstatus): New function.
- (elfcore_write_pstatus): Fix typo, eliminate unnecessary memcpy.
-
-2002-02-11 Alexandre Oliva <aoliva@redhat.com>
-
- * elf32-sh.c: Added missing prototypes.
- * elf32-sh64.c: Likewise.
- (sh_elf_align_loads): Mark unused args as such.
- * elf64-sh64.c: Added missing prototypes.
- (struct elf_sh64_link_hash_entry): Fix typo.
- (sh_elf64_relocate_section): Fix info argument passed to
- _bfd_elf_section_offset.
-
-2002-02-11 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: "make dep-am".
- * Makefile.in: Regenerate.
- * aclocal.m4: Regenerate.
- * config.in: Regenerate.
- * configure: Regenerate.
-
-2002-02-10 Daniel Jacobowitz <drow@mvista.com>
-
- * coff-rs6000.c (xcoff_generate_rtinit): Silence uninitialized
- variable warnings.
- * elf32-sh.c (sh_elf_relax_section): Silence signed/unsigned
- comparison warning.
- * trad-core.c (trad_unix_core_file_p): Silence pointer/integer
- cast warnings for the common case.
-
-2002-02-10 Hans-Peter Nilsson <hp@bitrange.com>
-
- * config.bfd (sh-*-linux*, sh-*-elf* | sh-*-rtemself*): Add sh64
- vectors.
- (sh-*-netbsdelf*): New, to trump sh*-*-netbsdelf* and add sh64
- vectors.
-
-2002-02-09 Richard Henderson <rth@redhat.com>
-
- * elf64-alpha.c (elf64_alpha_howto): Add R_ALPHA_BRSGP.
- (elf64_alpha_reloc_map, elf64_alpha_check_relocs): Likewise.
- (elf64_alpha_relocate_section): Likewise.
- * reloc.c (BFD_RELOC_ALPHA_BRSGP): New.
- * bfd-in2.h, libbfd.h: Rebuild.
-
-2002-02-09 Hans-Peter Nilsson <hp@bitrange.com>
-
- * elf64-mmix.c (_bfd_mmix_finalize_linker_allocated_gregs): Check
- that base-plus-offset reloc accounting is consistent.
- (mmix_elf_relax_section): Keep base-plus-offset reloc accounting
- up to date for undefined symbols.
-
-2002-02-08 Eric Christopher <echristo@redhat.com>
-
- From Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
-
- * elf32-mips.c (_bfd_mips_elf_fake_sections): Don't create .rela
- sections for the O32 ABI.
-
-2002-02-08 Chris Demetriou <cgd@broadcom.com>
-
- * elf32-arm.h: Fix formatting of _("...").
- * elf32-d10v.c: Likewise.
- * elf32-m68k.c: Likewise.
- * elf32-mips.c: Likewise.
-
-2002-02-08 Ivan Guzvinec <ivang@opencores.org>
-
- * coff-or32.c: Fix compile time warning messages.
-
-2002-02-08 Alexandre Oliva <aoliva@redhat.com>
-
- Contribute sh64-elf.
- 2002-01-23 Alexandre Oliva <aoliva@redhat.com>
- * reloc.c (R_SH_GOTPLT32, R_SH_GOT_LOW16, R_SH_GOT_MEDLOW16,
- R_SH_GOT_MEDHI16, R_SH_GOT_HI16, R_SH_GOTPLT_LOW16,
- R_SH_GOTPLT_MEDLOW16, R_SH_GOTPLT_MEDHI16, R_SH_GOTPLT_HI16,
- R_SH_PLT_LOW16, R_SH_PLT_MEDLOW16, R_SH_PLT_MEDHI16,
- R_SH_PLT_HI16, R_SH_GOTOFF_LOW16, R_SH_GOTOFF_MEDLOW16,
- R_SH_GOTOFF_MEDHI16, R_SH_GOTOFF_HI16, R_SH_GOTPC_LOW16,
- R_SH_GOTPC_MEDLOW16, R_SH_GOTPC_MEDHI16, R_SH_GOTPC_HI16,
- R_SH_GOT10BY4, R_SH_GOTPLT10BY4, R_SH_GOT10BY8, R_SH_GOTPLT10BY8,
- R_SH_COPY64, R_SH_GLOB_DAT64, R_SH_JMP_SLOT64, R_SH_RELATIVE64):
- New relocs.
- * libbfd.h, bfd-in2.h: Rebuilt.
- * elf32-sh.c (sh_elf_howto_table): Define new relocs.
- (sh_reloc_map): Map them.
- (PLT_ENTRY_SIZE, elf_sh_plt0_entry_be, elf_sh_plt0_entry_le,
- elf_sh_plt_entry_be, elf_sh_plt_entry_le, elf_sh_pic_plt_entry_be,
- elf_sh_pic_plt_entry_le, elf_sh_plt0_entry, elf_sh_plt_entry,
- elf_sh_pic_plt_entry, elf_sh_sizeof_plt, elf_sh_plt_plt0_offset,
- elf_sh_plt0_gotplt_offset, elf_sh_plt_temp_offset,
- elf_sh_plt_symbol_offset, elf_sh_plt_reloc_offset,
- movi_shori_putval) [INCLUDE_SHMEDIA]: New.
- (elf_sh_link_hash_entry) [INCLUDE_SHMEDIA]: Add
- datalabel_got_offset.
- (sh_elf_link_hash_newfunc): Initialize it.
- (sh_elf_relocate_section): Augment the scope of
- seen_stt_datalabel. Introduce GOTPLT support. Extend GOTPC, PLT,
- GOT and GOTOFF handling to new SHmedia relocation types. Support
- GOT_BIAS.
- (sh_elf_check_relocs): Likewise.
- (sh_elf_finish_dynamic_symbol) [TARGET_SHMEDIA]: Set up values in
- PLT entries using movi_shori_putval. Support GOT_BIAS.
- (sh_elf_finish_dynamic_sections): Likewise.
- * elf32-sh64.c (shmedia_prepare_reloc): Do not add addend to
- relocation, it's now done by the caller.
- (GOT_BIAS): New.
- * elf64-sh64.c (GOT_BIAS, PLT_ENTRY_SIZE, elf_sh64_sizeof_plt,
- elf_sh64_plt_plt0_offset, elf_sh64_plt0_gotplt_offset,
- elf_sh64_plt_temp_offset, elf_sh64_plt_symbol_offset,
- elf_sh64_plt_reloc_offset, ELF_DYNAMIC_INTERPRETER,
- elf_sh64_pcrel_relocs_copied, elf_sh64_link_hash_entry,
- elf_sh64_link_hash_table, sh64_elf64_link_hash_traverse,
- sh64_elf64_hash_table): New.
- (sh_elf64_howto_table): Introduce new relocs.
- (sh_elf64_info_to_howto): Accept new PIC relocs.
- (sh_elf64_relocate_section): Augment the scope of
- seen_stt_datalabel. Support new PIC relocs.
- (sh_elf64_check_relocs): Support new PIC relocs.
- (elf_sh64_plt0_entry_be, elf_sh64_plt0_entry_le,
- elf_sh64_plt_entry_be, elf_sh64_plt_entry_le,
- elf_sh64_pic_plt_entry_be, elf_sh64_pic_plt_entry_le,
- elf_sh64_plt0_entry, elf_sh64_plt_entry, elf_sh64_pic_plt_entry,
- sh64_elf64_link_hash_newfunc, sh64_elf64_link_hash_table_create,
- movi_shori_putval, movi_3shori_putval,
- sh64_elf64_create_dynamic_sections,
- sh64_elf64_adjust_dynamic_symbol, sh64_elf64_discard_copies,
- sh64_elf64_size_dynamic_sections,
- sh64_elf64_finish_dynamic_symbol,
- sh64_elf64_finish_dynamic_sections): New.
- (elf_backend_create_dynamic-sections,
- bfd_elf64_bfd_link_hash_table_create,
- elf_backend_adjust_dynamic_symbol,
- elf_backend_size_dynamic_sections,
- elf_backend_finish_dynamic_symbol,
- elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
- elf_backend_plt_readonly, elf_backend_want_plt_sym,
- elf_backend_got_header_size, elf_backend_plt_header_size):
- Define.
- 2001-05-16 Alexandre Oliva <aoliva@redhat.com>
- * elf32-sh.c: Renumbered and renamed some SH5 relocations to
- match official numbers and names; moved unmaching ones to the
- range 0xf2-0xff.
- * elf32-sh64.c, elf64-sh64.c: Likewise.
- 2001-03-12 DJ Delorie <dj@redhat.com>
- * elf32-sh.c (sh_elf_relax_section): Don't relax SHmedia
- sections.
- 2001-03-12 DJ Delorie <dj@redhat.com>
- * elf32-sh64.c (shmedia_prepare_reloc): Validate relocs that must
- be aligned.
- * elf64-sh64.c (sh_elf64_relocate_section): Ditto.
- 2001-01-14 Hans-Peter Nilsson <hpn@cygnus.com>
- * elf32-sh64.c (bfd_elf32_bfd_copy_private_section_data): Define.
- (sh64_elf_fake_sections): Set type to SHT_SH5_CR_SORTED for a
- .cranges section with SEC_SORT_ENTRIES set.
- (sh64_backend_section_from_shdr): Set SEC_SORT_ENTRIES on an
- incoming sorted .cranges section.
- (sh64_bfd_elf_copy_private_section_data): New.
- (sh64_elf_final_write_processing): Only sort .cranges and modify
- start address if called by linker.
- 2001-01-08 Ben Elliston <bje@redhat.com>
- * elf32-sh64.c (sh64_elf_final_write_processing): Activate
- Hans-Peter Nilsson's set bit 0 patch from 2001-01-06.
- * elf64-sh64.c (sh64_elf64_final_write_processing): Ditto.
- 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
- * elf64-sh64.c (sh_elf64_howto_table): No open brace at start of
- line. Add comments before all entries.
- <R_SH_PT_16, R_SH_SHMEDIA_CODE>: Correct and clarify describing
- comment.
- (sh_elf64_reloc): Correct head comment.
- (sh_elf64_relocate_section): Correct spacing.
- <relocating for a local symbol>: Do not honour STO_SH5_ISA32;
- instead call reloc_dangerous callback.
- <case R_SH_SHMEDIA_CODE>: New case.
- (sh_elf64_gc_mark_hook): Correct spacing.
- (sh_elf64_check_relocs): Ditto.
- * elf32-sh64.c (shmedia_prepare_reloc) <case R_SH_SHMEDIA_CODE>:
- New case.
- * elf32-sh.c: Correct #endif comments for #ifndef-wrapped
- functions.
- (sh_elf_howto_table) <R_SH_PT_16, R_SH_SHMEDIA_CODE>: Correct,
- clarify describing comment. Add comments before all entries.
- (sh_elf_relocate_section) <relocating for a local symbol>: Do not
- honour STO_SH5_ISA32; instead call reloc_dangerous callback.
- 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
- Sort .cranges section in final link. Prepare to set bit 0 on
- entry address.
- * elf32-sh64.c (struct sh64_find_section_vma_data): New.
- (sh64_elf_link_output_symbol_hook): Fix typo in prototype.
- (sh64_elf_set_mach_from_flags): Set SEC_DEBUGGING on incoming
- .cranges section.
- (sh64_backend_section_from_shdr): New, to recognize
- SHT_SH5_CR_SORTED on incoming .cranges section.
- (elf_backend_section_from_shdr): Define.
- (sh64_elf_final_write_processing): Sort outgoing .cranges
- section. (New, temporarily disabled:) Set bit 0 on entry address
- according to ISA type.
- (sh64_find_section_for_address): New.
- (crange_qsort_cmpb, crange_qsort_cmpl, crange_bsearch_cmpb,
- crange_bsearch_cmpl): Move here from opcodes/sh64-dis.c.
- (sh64_address_in_cranges): Move here from opcodes/sh64-dis.c. Use
- bfd_malloc, not xmalloc.
- (sh64_get_contents_type): Move here from opcodes/sh64-dis.c. Make
- global.
- * elf32-sh64.c (sh64_elf64_final_write_processing): New, (but
- temporarily disabled) setting bit 0 on entry address.
- (elf_backend_final_write_processing): Define.
- 2001-01-05 Hans-Peter Nilsson <hpn@cygnus.com>
- * elf32-sh.c (sh_elf_howto_table) <R_SH_PT_16>: Adjust fields to
- be a proper relocation for PTA and PTB rather than a marker.
- <R_SH_IMMU5, R_SH_IMMS6, R_SH_IMMU6, R_SH_IMMS10, R_SH_IMMS10BY2,
- R_SH_IMMS10BY4, R_SH_IMMS10BY8, R_SH_IMMS16, R_SH_IMMU16,
- R_SH_IMM_LOW16, R_SH_IMM_LOW16_PCREL, R_SH_IMM_MEDLOW16,
- R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16, R_SH_IMM_MEDHI16_PCREL,
- R_SH_IMM_HI16, R_SH_IMM_HI16_PCREL, R_SH_64, R_SH_64_PCREL>:
- Zero src_mask.
- * elf64-sh64.c: Ditto.
- (sh_elf64_relocate_section) <case R_SH_PT_16>: New case.
- * elf32-sh64.c: Include opcodes/sh64-opc.h
- (shmedia_prepare_reloc): Take a bfd_link_info pointer as first
- argument. Drop const qualifiers from "bfd *" and "bfd_byte *"
- parameters. No unused parameters. Caller changed.
- <case R_SH_PT_16>: New case.
- * Makefile.am (elf32-sh64.lo): Add dependency on sh64-opc.h.
- * Makefile.in: Regenerate.
- 2000-12-30 Hans-Peter Nilsson <hpn@cygnus.com>
- * elf64-sh64.c (sh64_elf64_fake_sections): Set SHF_SH5_ISA32 for
- all code sections.
- (sh_elf64_set_mach_from_flags): Change from EF_SH64 to EF_SH5.
- (sh64_elf_merge_private_data): Ditto.
- * elf32-sh64.c (sh64_elf_fake_sections): Use sh64_elf_section_data
- to access stored section flags.
- (sh64_elf_final_write_processing): Return immediately unless
- called by linker. Use sh64_elf_section_data (cranges) to get size
- of linker-generated cranges entries.
- (sh64_elf_copy_private_data): Add missing "return true".
- (sh64_elf_set_mach_from_flags): Change from EF_SH64 to EF_SH5.
- (sh_elf64_merge_private_data): Ditto.
- 2000-12-19 Hans-Peter Nilsson <hpn@cygnus.com>
- * elf64-sh64.c (sh64_elf64_fake_sections): New, copy of
- elf64-sh64.c:sh64_elf_fake_sections.
- (elf_backend_fake_sections): Define as sh64_elf64_fake_sections.
- 2000-12-18 Hans-Peter Nilsson <hpn@cygnus.com>
- * elf32-sh64.c (sh64_elf_copy_private_data_internal): Delete.
- (sh64_elf_final_write_processing): New.
- (elf_backend_final_write_processing): Define.
- (sh64_elf_fake_sections): Get header flags from tdata field.
- (sh64_elf_copy_private_data): Do not call
- sh64_elf_copy_private_data_internal, just copy e_flags field.
- (sh64_elf_merge_private_data): Do not call
- sh64_elf_copy_private_data_internal.
- 2000-12-12 Hans-Peter Nilsson <hpn@cygnus.com>
- Remove EF_SH64_ABI64, let ELF size make difference.
- Remove SH64-specific BFD section flag.
- * elf32-sh64.c (sh64_elf_fake_sections): Recognize section as
- containing SHmedia through elf_section_data (asect)->tdata
- non-zero, not using a BFD section flag.
- (sh64_elf_set_mach_from_flags): Don't recognize EF_SH64_ABI64.
- (sh64_elf_merge_private_data): Similar.
- (elf_backend_section_flags): Don't define.
- (sh64_elf_backend_section_flags): Delete.
- * elf64-sh64.c (sh_elf64_set_mach_from_flags): Recognize EF_SH64,
- not EF_SH64_ABI64.
- (sh_elf64_merge_private_data): Similar.
- * section.c (Section flags definitions): Don't define
- SEC_SH_ISA_SHMEDIA.
- (bfd-in2.h): Regenerate.
- 2000-12-09 Hans-Peter Nilsson <hpn@cygnus.com>
- Make DataLabel references work with partial linking.
- * elf32-sh64.c: Fix formatting.
- (sh64_elf_link_output_symbol_hook): New.
- (elf_backend_link_output_symbol_hook): Define to
- sh64_elf_link_output_symbol_hook.
- (sh64_elf_add_symbol_hook): Make DataLabel symbol just global
- undefined if partial linking. Adjust sanity check.
- * elf64-sh64.c (sh64_elf64_link_output_symbol_hook): New.
- (elf_backend_link_output_symbol_hook): Define to
- sh64_elf64_link_output_symbol_hook.
- (sh64_elf64_add_symbol_hook): Make DataLabel symbol just global
- undefined if partial linking. Adjust sanity check.
- 2000-12-07 Hans-Peter Nilsson <hpn@cygnus.com>
- Implement semantics for inter-file DataLabel references.
- * elf64-sh64.c (DATALABEL_SUFFIX): Define.
- (sh64_elf64_add_symbol_hook): New.
- (sh_elf64_relocate_section): If passing an indirect symbol with
- st_type STT_DATALABEL on the way to a symbol with st_other
- STO_SH5_ISA32, do not bitor 1 to the relocation.
- (elf_backend_add_symbol_hook): Define to
- sh64_elf64_add_symbol_hook.
- * elf64-sh32.c: Tweak comments.
- (DATALABEL_SUFFIX): Define.
- (sh64_elf_add_symbol_hook): New.
- (elf_backend_add_symbol_hook): Define to sh64_elf_add_symbol_hook.
- * elf32-sh.c (sh_elf_relocate_section): If passing an indirect
- symbol with st_type STT_DATALABEL on the way to a symbol with
- st_other STO_SH5_ISA32, do not bitor 1 to the relocation.
- 2000-12-05 Hans-Peter Nilsson <hpn@cygnus.com>
- Pass through STT_DATALABEL.
- * elf32-sh64.c (sh64_elf_get_symbol_type): New.
- (elf_backend_get_symbol_type): Define.
- * elf64-sh64.c (sh64_elf64_get_symbol_type): New.
- (elf_backend_get_symbol_type): Define.
- 2000-11-30 Hans-Peter Nilsson <hpn@cygnus.com>
- * elf32-sh64.c: Tweak comments.
- (sh64_elf_copy_private_data_internal): Add prototype.
- (bfd_elf32_bfd_set_private_flags): Define.
- (sh64_elf_copy_private_data_internal): Compare machine name, not
- textual BFD target name, to check whether to copy section flag
- SHF_SH5_ISA32.
- (sh64_elf_merge_private_data): Validize bfd_get_arch_size.
- Tweak section-contents-type-mismatch message.
- (shmedia_prepare_reloc): Add ATTRIBUTE_UNUSED markers.
- Validize reloc-types.
- * elf64-sh64.c: New file.
- * targets.c (bfd_elf64_sh64_vec, bfd_elf64_sh64l_vec): Declare.
- * Makefile.am (BFD64_BACKENDS): Add elf64-sh64.lo.
- (BFD64_BACKENDS_CFILES): Add elf64-sh64.c.
- Regenerate dependencies.
- * Makefile.in: Regenerate.
- * config.bfd (sh64-*-elf*): Add bfd_elf64_sh64_vec and
- bfd_elf64_sh64l_vec.
- * configure.in: Handle bfd_elf64_sh64_vec and
- bfd_elf64_sh64l_vec.
- * configure: Regenerate.
- * po/POTFILES.in: Regenerate.
- * po/bfd.pot: Regenerate.
- 2000-11-29 Hans-Peter Nilsson <hpn@cygnus.com>
- * elf32-sh64.c (sh64_elf_set_mach_from_flags): Do not recognize
- anything else but EF_SH64 and EF_SH64_ABI64.
- (sh64_elf_merge_private_data): Emit error for anything else but
- EF_SH64 and EF_SH64_ABI64.
- * config.bfd: Remove bfd_elf32_shblin_vec and bfd_elf32_shlin_vec
- from targ_selvecs.
- * configure.in: Add cofflink.lo to bfd_elf32_sh64_vec and
- bfd_elf32_sh64l_vec as a temporary measure.
- * configure: Regenerate.
- 2000-11-27 Hans-Peter Nilsson <hpn@cygnus.com>
- * cpu-sh.c (arch_info_struct): Include sh5 item
- unconditionalized.
- * config.bfd (sh64-*-elf*): Do not set targ_cflags.
- Add targ_selvecs bfd_elf32_sh_vec, bfd_elf32_shl_vec,
- bfd_elf32_shblin_vec and bfd_elf32_shlin_vec.
- * elf32-sh64.c: Tweak comments.
- (sh64_elf_set_mach_from_flags): Recognize all machine flags that
- are proper subsets of SH64 as bfd_mach_sh5. Add EF_SH64_ABI64.
- (sh64_elf_copy_private_data_internal): Wrap long line.
- (sh64_elf_merge_private_data): Rewrite to allow objects from
- SH64 subsets to be linked together.
- (INCLUDE_SHMEDIA): Define.
- * elf32-sh.c (sh_elf_relocate_section) <local symbol>:
- Parenthesize plus-expression inside or-expression.
- <global symbol>: Ditto.
- (sh_elf_set_mach_from_flags): Remove code refusing
- deleted EF_SH64_32BIT_ABI flag.
- 2000-11-26 Hans-Peter Nilsson <hpn@cygnus.com>
- * elf32-sh.c (sh_elf_howto_table) <R_SH_IMM_LOW16_PCREL,
- R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16_PCREL,
- R_SH_IMM_HI16_PCREL, R_SH_64_PCREL>: Set pcrel_offset to true.
- (sh_elf_relocate_section) <local symbol>: Or 1 in
- calculation of relocation if sym->st_other & STO_SH5_ISA32.
- <global symbol>: Ditto if h->other & STO_SH5_ISA32.
- * elf32-sh64.c (shmedia_prepare_reloc): Add rel->r_addend to
- relocation.
- 2000-11-24 Hans-Peter Nilsson <hpn@cygnus.com>
- * Makefile.am (BFD32_BACKENDS): Add elf32-sh64.lo.
- (BFD32_BACKENDS_CFILES): Add elf32-sh64.c.
- Regenerate dependencies.
- * Makefile.in: Regenerate.
- * archures.c: Add bfd_mach_sh5.
- * config.bfd: Map targ_cpu sh* to bfd_sh_arch.
- Handle sh64-*-elf*. Set targ_cflags to -DINCLUDE_SHMEDIA.
- * configure.in: Handle bfd_elf32_sh64_vec and bfd_elf32_sh64l_vec.
- * configure: Regenerate.
- * reloc.c (BFD_RELOC_SH_SHMEDIA_CODE, BFD_RELOC_SH_IMMU5,
- BFD_RELOC_SH_IMMS6, BFD_RELOC_SH_IMMS6BY32, BFD_RELOC_SH_IMMU6,
- BFD_RELOC_SH_IMMS10, BFD_RELOC_SH_IMMS10BY2,
- BFD_RELOC_SH_IMMS10BY4, BFD_RELOC_SH_IMMS10BY8,
- BFD_RELOC_SH_IMMS16, BFD_RELOC_SH_IMMU16, BFD_RELOC_SH_IMM_LOW16,
- BFD_RELOC_SH_IMM_LOW16_PCREL, BFD_RELOC_SH_IMM_MEDLOW16,
- BFD_RELOC_SH_IMM_MEDLOW16_PCREL, BFD_RELOC_SH_IMM_MEDHI16,
- BFD_RELOC_SH_IMM_MEDHI16_PCREL, BFD_RELOC_SH_IMM_HI16,
- BFD_RELOC_SH_IMM_HI16_PCREL, BFD_RELOC_SH_PT_16): New relocations.
- * cpu-sh.c [INCLUDE_SHMEDIA] (arch_info_struct): Define and link
- in item for SH5.
- * elf32-sh.c [INCLUDE_SHMEDIA] (sh_elf_howto_table): Add howto items
- for SHmedia relocs.
- [INCLUDE_SHMEDIA] (sh_rel): Add mappings for SHmedia relocs.
- [INCLUDE_SHMEDIA] (sh_elf_relocate_section) [default]: Call
- shmedia_prepare_reloc, goto final_link_relocate if it returns
- non-zero, else fail as before.
- (sh_elf_set_mach_from_flags): Provide function only if not defined
- as macro. Do not recognize objects with EF_SH64_32BIT_ABI set.
- (sh_elf_set_private_flags): Provide function only if not defined
- as a macro.
- (sh_elf_copy_private_data): Similar.
- (sh_elf_merge_private_data): Similar.
- * section.c (SEC_SH_ISA_SHMEDIA): New.
- * targets.c (bfd_elf32_sh64_vec, bfd_elf32_sh64l_vec): Declare.
- * elf32-sh64.c: New file.
- * libbfd.h: Regenerate.
- * bfd-in2.h: Regenerate.
- * po/POTFILES.in: Regenerate.
- * po/bfd.pot: Regenerate.
- * bfd-in2.h: Regenerate.
- * libbfd.h: Regenerate.
+2004-02-17 Daniel Jacobowitz <drow@mvista.com>
+ Richard Sandiford <rsandifo@redhat.com>
-2002-02-07 Daniel Jacobowitz <drow@mvista.com>
+ * elfxx-mips.c (mips_elf_calculate_relocation): Use
+ _bfd_elf_symbol_refs_local_p to decide whether to decay
+ a GOT_PAGE/GOT_OFST pair to GOT_DISP/addend.
+ (_bfd_mips_elf_check_relocs): Add a global GOT entry for GOT_PAGE
+ relocs if the symbol wasn't defined by a regular object file.
+ Don't check the symbol's dynindx.
- * bfd-in.h: Update <stdbool.h> check to only see if <stdbool.h> has
- been included, not drag it in.
- * bfd-in2.h: Regenerate.
+2004-02-16 Andrew Cagney <cagney@redhat.com>
-2002-02-06 H.J. Lu (hjl@gnu.org)
+ * bfd-in.h (file_ptr, ufile_ptr): Configure type using
+ @bfd_file_ptr@.
+ * bfd-in2.h: Re-generate.
- * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Update
- the mach and ISA fields if necessary.
+2004-02-14 Andrew Cagney <cagney@redhat.com>
-2002-02-06 Nick Clifton <nickc@cambridge.redhat.com>
+ * configure.host (HDEFINES): When hppa*-*-hpux*, define
+ _LARGEFILE64_SOURCE.
- * coffcode.h (coff_set_arch_mach_hook): Select the highest known
- ARM architecture when an F_ARM_5 flag is detected, since we cannot
- be sure exactly which architecture this represents.
+2004-02-13 Andrew Cagney <cagney@redhat.com>
-2002-02-05 Nick Clifton <nickc@redhat.com>
+ * elf.c (vma_page_aligned_bias): New function.
+ (assign_file_positions_except_relocs)
+ (assign_file_positions_for_segments): Replace broken modulo
+ arithmetic with call to vma_page_aligned_bias.
- * po/tr.po: Updated translation.
+2004-02-11 Andrew Cagney <cagney@redhat.com>
-2002-02-05 Alan Modra <amodra@bigpond.net.au>
+ * bfd-in.h: Update copyright.
+ (bfd_tell): Change return type to file_ptr.
+ * bfd-in2.h: Re-generate.
+ * cache.c: Update copyright.
+ (bfd_cache_lookup_worker): Use real_fseek, do not cast offset
+ parameter.
+ (close_one): Use real_ftell.
+ * bfdio.c: Update copyright.
+ (real_ftell, real_fseek): New functions.
+ (bfd_tell): Use real_fseek and real_ftell, change return type to
+ file_ptr.
+ (bfd_seek): Use real_ftell and real_fseek, change type of
+ file_position to a file_ptr.
+ * libbfd-in.h: Update copyright.
+ (real_ftell, real_fseek): Declare.
+ * libbfd.h: Re-generate.
- From Jimi X <jimix@watson.ibm.com>
- * archures (bfd_mach_ppc64): Define.
- (bfd_powerpc_arch): Rename to bfd_powerpc_archs.
- (bfd_powerpc_arch): Define.
- * bfd-in2.h: Regenerate.
- * cpu-powerpc.c (arch_info_struct): Rename to bfd_powerpc_archs.
- (bfd_powerpc_arch): Move to tail of bfd_powerpc_archs.
- (bfd_powerpc_archs): Add default powerpc64 arch.
-
-2002-02-05 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Check for relocs
- against section syms in readonly sections. Don't do the global
- sym check if we find one.
- * elf64-s390.c (elf_s390_size_dynamic_sections): Likewise.
- * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Likewise.
- * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
- * elf32-s390.c (elf_s390_size_dynamic_sections): Likewise.
- (elf_s390_grok_prstatus): Add missing prototype.
-
-2002-02-04 Hans-Peter Nilsson <hp@bitrange.com>
-
- * elf64-mmix.c (mmix_dump_bpo_gregs): New function.
- (mmix_elf_check_common_relocs) <case R_MMIX_BASE_PLUS_OFFSET>:
- Call bfd_get_section_by_name only once. Initialize
- bpodata->n_bpo_relocs_this_section.
- (_bfd_mmix_prepare_linker_allocated_gregs): Remove comment
- referring to DSOs.
- (bpo_reloc_request_sort_fn): Don't use difference of values as
- return-value.
-
-2002-02-02 David O'Brien <obrien@FreeBSD>
-
- * configure.in: Tweak the FreeBSD 4.x recognition more. Only treat
- version 4.5 and later the same as 5-CURRENT.
+ * configure.in (AC_CHECK_FUNCS): Check for ftello, ftello64,
+ fseeko and fseeko64. Determine bfd_file_ptr.
* configure: Re-generate.
+ * config.in: Re-generate.
-2002-02-02 Jason Thorpe <thorpej@wasabisystems.com>
-
- * config.bfd (hppa*-*-netbsd*): New target.
-
-2002-01-31 Philipp Thomas <pthomas@suse.de>
-
- * coff-arm.c (coff_arm_merge_private_bfd_data): Move ERROR
- to front of message. Unify messages with elf32-arm.h. Use
- commas where neccessary.
- * elf32-arm.h (elf32_arm_merge_private_bfd_data): Use all upcase
- ERROR in messages. Unify messages with coff-arm.c. Correct
- VFP/FPA error message.
- (elf32_arm_print_private_bfd_data): Don't mark APCS-26 and
- APCS-32 for translation.
-
-2002-02-01 Hans-Peter Nilsson <hp@bitrange.com>
-
- Perform on-demand global register allocation from
- R_MMIX_BASE_PLUS_OFFSET relocs.
- * elf64-mmix.c (struct bpo_reloc_section_info, struct
- bpo_reloc_request, struct bpo_greg_section_info): New.
- (mmix_elf_check_common_relocs, mmix_elf_gc_sweep_hook,
- bpo_reloc_request_sort_fn, mmix_elf_relax_section,
- _bfd_mmix_check_all_relocs,
- _bfd_mmix_prepare_linker_allocated_gregs,
- _bfd_mmix_finalize_linker_allocated_gregs): New functions.
- (elf_mmix_howto_table): Correct src_mask for most relocs.
- (mmix_elf_perform_relocation) <case R_MMIX_BASE_PLUS_OFFSET>: New
- case.
- (mmix_final_link_relocate) <case R_MMIX_BASE_PLUS_OFFSET>: New
- case. Fix typo in comment. New label do_mmix_reloc.
- (mmix_elf_check_relocs): Abuse bfd_link_info member base_file to
- store first object file with a base-plus-offset reloc. Call
- mmix_elf_check_common_relocs for the part common with mmo.
- (mmix_elf_final_link): Write out linker-allocated register
- contents section.
- (elf_backend_gc_sweep_hook): Define.
- (bfd_elf64_bfd_relax_section): Define.
-
- * mmo.c: Don't include <ctype.h>
- (mmo_init): Correct init-once logic.
-
-2002-02-01 Tom Rix <trix@redhat.com>
-
- * config.bfd: Conditionally support <aiaff> for pre AIX 4.3.
-
-2002-02-01 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: Run "make dep-am"
- * Makefile.in: Regenerate.
-
-2002-01-31 David O'Brien <obrien@FreeBSD>
-
- * configure.in: Recognize the differences in core files from FreeBSD
- 4.{0,1} and later versions of 4.x. This treats 4.2+ the same as
- 5-CURRENT.
- * configure: Regenerate.
-
-2002-01-31 Ivan Guzvinec <ivang@opencores.org>
-
- * coff-or32.c: New file.
- * cpu-or32.c: New file.
- * elf32-or32.c: New file.
- * archures.c: Add support for or32.
- * targets.c: Add support for or32.
- * bfd-in2.h: Regenerate.
- * coffcode.h (coff_set_arch_mach_hook, coff_set_flags,
- coff_write_object_contents): Add support for or32.
- * config.bfd: Add target.
- * configure.in: Add support for or32.
- * configure: Regenerate.
- * Makefile.am: Add support for or32.
- * Makefile.in: Regenerate.
- * po/SRC-POTFILES.in: Add or32 files.
- * po/bfd.pot: Regenerate.
-
-2002-01-31 Nick Clifton <nickc@cambridge.redhat.com>
- Don Lindsay <lindsayd@cisco.com>
-
- * elf32-mips.c (mips_elf_calculate_relocation): Replace 'return
- false' with a return of a bfd_reloc_ error code.
-
-2002-01-31 Hans-Peter Nilsson <hp@axis.com>
-
- * elf32-cris.c (elf_cris_discard_excess_program_dynamics): Don't
- unexport unreferenced symbols when --export-dynamic. Call
- _bfd_elf_strtab_delref when unexporting.
-
-2002-01-30 Daniel Jacobowitz <drow@mvista.com>
-
- * bfd-in.h: Include <stdbool.h> if it is available.
- * bfd-in2.h: Regenerated.
-
-2002-01-31 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (func_desc_adjust): STV_PROTECTED functions should
- not go via the plt.
-
-2002-01-30 Nick Clifton <nickc@cambridge.redhat.com>
-
- * archures.c: Tidy up formatting of embedded comments.
- * bfd.c: Tidy up formatting of embedded comments.
- * bfd-in.h: Fix formatting of comments.
- * reloc.c: Tidy up formatting of ordinary & embedded comments.
- * section.c: Tidy up formatting of embedded comments.
- * syms.c: Tidy up formatting of embedded comments.
- * targets.c: Tidy up formatting of embedded comments.
-
- * bfd-in2.h: Regenerate.
-
-2002-01-30 Nick Clifton <nickc@cambridge.redhat.com>
-
- * vms-tir.c (cmd_name): New function.
- (tir_cmd_name): New function.
- (etir_sta, etir_sto, etir_opr, etir_stc): Use cmd_name().
- (tir_opr, tir_ctl, tir_cmd): use tir_cmd_name().
- Fix formatting.
-
- * peXXigen.c (pe_print_idata): Rearrange message to aid in
- translation.
- (pe_print_pdata): Rearrange message to aid in translation.
-
- * libbfd.c (warn_deprecated): Rearrange error message to aid in
- translation.
-
- * ihex.c (ihex_write_object_contents): Fix spelling typo.
-
- * ieee.c (ieee_slurp_external_symbols): Remove spurious space.
-
- * elf64-sparc.c (sparc64_elf_add_symbol_hook): Rearrange error
- message to aid in translation.
-
- * elf64-mmix.c (mmix_final_link_relocate): Rearrange error message
- to aid in translation.
-
- * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix typo.
-
-2002-01-30 Philipp Thomas <pthomas@suse.de>
-
- * coff-arm.c, elf32-elf.h: Unify messages.
-
-2002-01-30 Nick Clifton <nickc@redhat.com>
-
- * po/sv.po: Updated translation.
-
-2002-01-30 Philipp Thomas <pthomas@suse.de>
-
- * dwarf2.c (read_abbrev): Use full section name in error message.
- (decode_line_info): Likewise.
-
- * elf.c (_bfd_elf_symbol_from_bfd_symbol): Don't translate debugging
- message.
-
-2002-01-30 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (func_desc_adjust): Only provide missing function
- descriptor symbols for undefined function code syms. Clear
- ELF_LINK_NON_ELF so that they can stay weak.
-
-2002-01-29 Chris Demetriou <cgd@broadcom.com>
- Mitch Lichtenberg <mpl@broadcom.com>
-
- * bfd-in.h (bfd_mips_elf32_create_embedded_relocs): New prototype.
- * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): New function
- to handle 32-bit ELF embedded reloc (ld --embedded-relocs)
- generation.
- * bfd-in2.h: Regenerate.
-
-2002-01-29 Chris Demetriou <cgd@broadcom.com>
-
- * elf32-mips.c: Add additional comments about HI16 relocation
- processing.
- (_bfd_mips_elf_hi16_reloc): Don't subtract address here for
- pc-relative relocations. (Reverts change made on 2001-10-31.)
- (_bfd_mips_elf_lo16_reloc): Subtract address of LO16 part here
- for pc-relative relocations.
- (mips_elf_calculate_relocation): Add a comment about a kludge
- in the R_MIPS_GNU_REL_HI16 handling.
- (_bfd_mips_elf_relocate_section): Implement that kludge;
- adjust pc-relative HI16 relocation for difference in HI16 and
- LO16 addresses, since it can't easily be done in
- mips_elf_calculate_relocation.
-
-2002-01-29 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * elf32-i386 (elf_i386_adjust_dynamic_symbol): Do not replace PLT32
- relocations with PC32 relocations for undefined or weak symbols.
- * elf32-s390 (elf_i386_adjust_dynamic_symbol): Likewise.
- * elf64-s390x (elf_i386_adjust_dynamic_symbol): Likewise.
-
-2002-01-28 Jason Thorpe <thorpej@wasabisystems.com>
-
- * elfcore.h (elf_core_file_p): Improve comment for last change.
-
-2002-01-27 Daniel Jacobowitz <drow@mvista.com>
-
- * configure: Regenerated.
-
-2002-01-27 Jason Thorpe <thorpej@wasabisystems.com>
-
- * elfcore.h (elf_core_file_p): Set the machine architecture
- before processing the program headers.
-
-2002-01-26 Hans-Peter Nilsson <hp@bitrange.com>
-
- * configure.in <64-bit configuration>: If using gcc, check and
- emit error for egcs-1.1.2.
- * configure: Regenerate.
-
-2002-01-26 Egor Duda <deo@logos-m.ru>
-
- * elf.c (elfcore_grok_win32pstatus): Copy only as much information
- as possible to avoid stack corruption.
-
-2002-01-26 Richard Henderson <rth@redhat.com>
-
- * elf64-alpha.c (elf64_alpha_check_relocs): Don't set reltext
- for non-allocated sections.
-
-2002-01-25 Mark Kettenis <kettenis@gnu.org>
-
- * elf.c (elfcore_write_prstatus): Make sure we pass the address of
- prstat.pr_reg even if it is a struct.
-
-2002-01-25 Steve Ellcey <sje@cup.hp.com>
-
- * bfd/elfxx-ia64.c: Reset AIX vector function overrides for HP-UX.
-
-2002-01-25 Philipp Thomas <pthomas@suse.de>
-
- * coffgen.c (coff_print_symbol): Don't mark info message
- for translation.
-
-2002-01-25 Nick Clifton <nickc@redhat.com>
-
- * po/fr.po: Updated translation.
- * po/es.po: Updated translation.
-
-2002-01-25 Philipp Thomas <pthomas@suse.de>
-
- * coff-alpha.c (alpha_relocate_section): Unify warning message
- for GP relative relocations without GP defined.
- * coff-mips.c (mips_relocate_section): Likewise.
-
-2002-01-25 Alan Modra <amodra@bigpond.net.au>
+2004-02-09 Anil Paranjpe <anilp1@KPITCummins.com>
- * elf-eh-frame.c (_bfd_elf_eh_frame_section_offset): Avoid
- unsigned overflow when new_offset < old_offset.
+ * coff-h8300.c: Added comments about relaxation for ldc.w and stc.w.
+ * elf32-h8300.c: Likewise.
-2002-01-24 Philipp Thomas <pthomas@suse.de>
+2004-02-09 Christian Vogel <vogelchr@vogel.cx>
+ Nick Clifton <nickc@redhat.com>
- * bfd.c (_bfd_abort): Fix typo.
+ * elf64-alpha.c (elf64_alpha_calc_got_offsets_for_symbol): Catch
+ GOT entries with no associated GOT subsection.
-2002-01-23 Richard Henderson <rth@redhat.com>
+2004-02-09 Richard Sandiford <rsandifo@redhat.com>
- * elf64-alpha.c (elf64_alpha_adjust_dynamic_symbol): Don't suppress
- plt entries for undefweak symbols.
+ * bfd-elf.h (elf_backend_name_local_section_symbols): New hook.
+ * elf.c (swap_out_syms): Use it to decide whether local section
+ symbols should be named.
+ * elfxx-target.h (elf_backend_name_local_section_symbols): New macro.
+ * elfxx-mips.h (_bfd_mips_elf_name_local_section_symbols): Declare.
+ (elf_backend_name_local_section_symbols): Define.
+ * elfxx-mips.c (_bfd_mips_elf_name_local_section_symbols): New.
-2002-01-23 Steve Ellcey <sje@cup.hp.com>
+2004-01-30 H.J. Lu <hongjiu.lu@intel.com>
- * bfd/targets.c (bfd_elf32_ia64_hpux_big_vec): Add to
- DEFAULT_VECTOR.
- (bfd_elf64_ia64_hpux_big_vec): Ditto.
- (bfd_elf32_h8300_vec): Ditto.
+ * elfxx-ia64.c (elfNN_ia64_relax_brl): New function.
+ (elfNN_ia64_relax_section): Optimize brl to br during the relax
+ finalize pass.
-2002-01-23 Alan Modra <amodra@bigpond.net.au>
+2004-01-30 Alexandre Oliva <aoliva@redhat.com>
- * elf64-ppc.c: Remove stale part of ABI comment.
- (NO_OPD_RELOCS): Define.
- (ppc64_elf_check_relocs): Use it.
- (ppc64_elf_relocate_section): Here too.
- (build_one_stub): Don't point function syms at the stub. Instead,
- hijack plt.offset.
- (ppc64_elf_relocate_section): Check whether REL24 relocs should
- really go to the stub. Make all dynamic relocs in opd against
- locals.
- (ppc64_elf_finish_dynamic_symbol): Allow for non-standard use of
- plt.offset.
+ * elf32-frv.c (elf32_frv_always_size_sections): Initialize pointer
+ to bfd_link_hash_entry passed by reference to
+ _bfd_generic_link_add_one_symbol.
-2002-01-22 Richard Henderson <rth@redhat.com>
+2004-01-25 H.J. Lu <hongjiu.lu@intel.com>
- * elf64-alpha.c (INSN_UNOP): Encode with RB as $sp.
+ * elfxx-ia64.c (elfNN_ia64_relocate_section): Disallow imm
+ relocations against dynamic symbols.
-2002-01-22 Alan Modra <amodra@bigpond.net.au>
+2004-01-23 Daniel Jacobowitz <drow@mvista.com>
- * elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Correct sign of
- TOC_BASE_OFF adjustment.
+ * elf32-arm.h (elf32_arm_check_relocs): Revert part of 2004-01-13
+ change.
- * Makefile.am: Run "make dep-am".
- * Makefile.in: Regenerate.
- * po/SRC-POTFILES.in: Regenerate.
-
-2002-01-22 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * configure.host (hppa*64*-*-hpux*, hppa*64*-*-linux*): Add new
- host defines.
-
-2002-01-21 Hans-Peter Nilsson <hp@axis.com>
-
- * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_32_GOTREL>:
- Check for and emit error if sgot is NULL at this point.
-
-2002-01-21 Jason Thorpe <thorpej@wasabisystems.com>
-
- * config.bfd (ia64*-*-netbsd*): New target.
-
-2002-01-21 Thomas Klausner <wiz@danbala.ifoer.tuwien.ac.at>
-
- * som.c (som_write_space_strings): Comment typo fix.
-
-2002-01-21 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (struct ppc_link_hash_entry): Add is_func and
- is_func_descriptor fields.
- (link_hash_newfunc): Init them.
- (ppc64_elf_check_relocs): Only R_PPC24_REL24 syms starting with a
- dot are candidates for plt entries. When processing .opd relocs,
- set function descriptor strings to point inside function code
- string, and set new ppc_link_hash_entry fields.
- (ppc64_elf_gc_sweep_hook): Don't sweep R_PPC64_REL24 relocs.
- (ppc64_elf_adjust_dynamic_symbol): Remove most code dealing with
- function descriptors. It's now done in..
- (func_desc_adjust): New.
- (ppc64_elf_func_desc_adjust): New.
- (define elf_backend_always_size_sections): Define.
- (ppc64_elf_hide_symbol): New.
- (define elf_backend_hide_symbol): Define.
- (allocate_dynrelocs): Remove code looking up function descriptors
- as that has been done earlier.
- (ppc64_elf_size_dynamic_sections): Use htab shortcut to elf hash
- table.
- (ppc64_elf_finish_dynamic_symbol): Likewise. Remove code looking
- up function descriptor.
- (build_one_stub): Look up the function code sym. Check for
- invalid plt offsets.
- (ppc64_elf_relocate_section): Tweak calls to undefined weak syms.
- Convert R_PPC64_TOC relocs to R_PPC64_RELATIVE in shared libs.
-
- * elf-bfd.h (elf_backend_data <elf_backend_hide_symbol>): Add
- boolean param.
- (_bfd_elf_link_hash_hide_symbol): Likewise.
- * elflink.h (elf_link_add_object_symbols): Adjust call to
- elf_backend_hide_symbol.
- (elf_fix_symbol_flags): Likewise.
- (elf_link_assign_sym_version): Likewise. Use bfd_malloc rather
- than bfd_alloc.
- * elf.c (_bfd_elf_link_hash_hide_symbol): Add "force_local" param.
- Set ELF_LINK_FORCED_LOCAL and call _bfd_elf_strtab_delref.
- * elf32-hppa.c (elf32_hppa_hide_symbol): Likewise.
- (clobber_millicode_symbols): Adjust to suit new hide_symbol.
- * elf32-cris.c (elf_cris_hide_symbol): Add "force_local" param
- and adjust to suit.
- * elf32-mips.c (_bfd_mips_elf_hide_symbol): Likewise, and call
- _bfd_elf_link_hash_hide_symbol rather than duplicating code.
- * elfxx-ia64.c (elfNN_ia64_hash_hide_symbol): Likewise.
-
-2002-01-18 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Test for a
- dynamic function descriptor symbol, not the associated function
- symbol.
-
-2002-01-17 Eric Christopher <echristo@redhat.com>
-
- * elf32-mips.c (mips_elf_calculate_relocation): Fix typo.
-
-2002-01-17 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/bfd.pot: Regenerate.
- * po/fr.po: Regenerate.
-
-2002-01-17 Alan Modra <amodra@bigpond.net.au>
-
- * elf-bfd.h (elf_backend_data <elf_backend_section_from_bfd_section>):
- Remove "Elf_Internal_Shdr *" param.
- (_bfd_mips_elf_section_from_bfd_section): Ditto.
- * elf32-mips.c (_bfd_mips_elf_section_from_bfd_section): Ditto.
- * elf32-m32r.c (_bfd_m32r_elf_section_from_bfd_section): Ditto.
- * elf32-v850.c (v850_elf_section_from_bfd_section): Ditto.
- * elf64-mmix.c (mmix_elf_section_from_bfd_section): Ditto.
- * elfxx-ia64.c (elfNN_hpux_backend_section_from_bfd_section): Ditto.
- * elf.c (_bfd_elf_section_from_bfd_section): Allow backend
- function to override special sections. Remove hdr arg from
- backend call, and don't loop.
-
-2002-01-16 Eric Christopher <echristo@redhat.com>
-
- * elf32-mips.c (mips_elf_calculate_relocation): Set require_jalxp
- on R_MIPS_26 and target is 16bit. Add R_MIPS16_GPREL to list of
- relocations requiring gp0 and gp.
-
-2002-01-16 Richard Earnshaw <rearnsha@arm.com>
-
- * elf32-arm.h (elf32_arm_merge_private_bfd_data): Handle
- EF_ARM_VFP_FLOAT.
- (elf32_arm_print_private_bfd_data): Likewise.
-
-2002-01-16 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/tr.po: Import new version.
-
-2002-01-16 Alan Modra <amodra@bigpond.net.au>
-
- * elf64-ppc.c (ppc64_elf_howto_raw): Remove stale FIXMEs.
- (ppc64_elf_reloc_type_lookup): Use proper CTOR reloc.
- (ORI_R0_R0_0): Correct.
-
-2002-01-16 Alan Modra <amodra@bigpond.net.au>
-
- * elflink.c (_bfd_elf_create_dynamic_sections): Don't set SEC_CODE
- when plt_not_loaded.
- * elf64-ppc.c (ppc64_elf_create_dynamic_sections): No need to
- clear .plt SEC_CODE here. Create .stub and correct .glink flags.
- (PLT_INITIAL_ENTRY_SIZE): Set to 24.
- (ppc64_elf_glink_code): Delete.
- (PPC64_ELF_GLINK_SIZE): Delete.
- (ADDIS_R12_R2, STD_R2_40R1, LD_R11_0R12, LD_R2_0R12, MTCTR_R11,
- BCTR, ADDIS_R12_R12_1, LD_R2_40R1, NOP, LI_R0_0, B_DOT, LIS_R0_0,
- ORI_R0_R0_0): Define.
- (PLT_CALL_STUB_SIZE, GLINK_CALL_STUB_SIZE): Define.
- (struct ppc_link_hash_table): Add sstub and plt_overflow.
- (ppc64_elf_link_hash_table_create): Init them.
- (ppc64_elf_check_relocs <R_PPC64_REL24>): Refcount .plt entry.
- Don't copy to shared lib.
- (ppc64_elf_check_relocs): Call bfd_set_error on errors.
- (ppc64_elf_gc_sweep_hook <R_PPC64_REL24>): Sweep plt refcount.
- (allocate_dynrelocs <plt>): Don't change function sym here. Make
- room for .stub and .glink code.
- (ppc64_elf_size_dynamic_sections): Handle .stub. Make entry for
- DT_PPC64_GLINK.
- (ppc64_elf_final_link): Rename to ppc64_elf_set_toc. Don't call
- bfd_elf64_bfd_final_link.
- (bfd_elf64_bfd_final_link): Don't define.
- (ppc64_elf_size_stubs): New.
- (build_plt_stub): New.
- (build_one_stub): New.
- (ppc64_elf_build_stubs): New.
- (ppc64_elf_relocate_section <toc relocs>): Remove assert.
- (ppc64_elf_relocate_section): Don't copy R_PPC64_REL24 relocs.
- (ppc64_elf_finish_dynamic_symbol): Don't build stubs here. Set
- DT_PPC64_GLINK entry. Tweak DT_PLTGOT, DT_JMPREL, DT_PLTRELSZ in
- case output sections not separate. Adjust DT_RELASZ to not
- include plt relocs. Set reserved got entry. Set got and plt
- entry size.
- (elf_backend_got_header_size): Set to 8.
- * elf64-ppc.h: New file.
-
-2002-01-16 Alan Modra <amodra@bigpond.net.au>
-
- * elf32-arm.h (elf32_arm_size_dynamic_sections): When removing
- sections, use bfd_section_list_remove.
- * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
- * elflink.h (elf_link_add_object_symbols): When removing all
- sections, use bfd_section_list_clear.
-
-2002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/sv.po: New file: Swedish translation.
- * configure.in (ALL_LINGUAS): Add sv.
- * configure: Regenerate.
-
-2002-01-15 Jakub Jelinek <jakub@redhat.com>
-
- * elflink.h (elf_link_input_bfd): Back out 2002-01-07 change.
- * elf.c (merge_sections_remove_hook): New function.
- (_bfd_elf_merge_sections): Pass it as 3rd argument to
- _bfd_merge_sections.
- * libbfd-in.h (_bfd_merge_sections): Add 3rd argument.
- * libbfd.h: Rebuilt.
- * merge.c (_bfd_merge_sections): Add remove_hook argument.
- Call remove_hook if a SEC_EXCLUDE section is encountered.
-
-2002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
-
- * elf32-xstormy16.c (xstormy16_reloc_map): Add new field 'table'.
- (xstormy16_reloc_map): Initialise new field with correct howto
- table.
- (xstormy16_reloc_type_lookup): Use 'table' field to locate correct
- howto entry.
-
-2002-01-10 Michael Snyder <msnyder@redhat.com>
-
- * elf.c (elfcore_write_prstatus): Use long instead of pid_t;
- (elfcore_write_pstatus): Use long instead of pid_t;
- * elf-bfd.h: Change prototypes to use long instead of pid_t;
-
-2002-01-09 Jason Thorpe <thorpej@wasabisystems.com>
-
- * elf.c: Update copyright years.
- (elfcore_grok_netbsd_note): Use NT_NETBSDCORE_PROCINFO
- and NT_NETBSDCORE_FIRSTMACH. Improve a comment.
-
-2002-01-08 Michael Snyder <msnyder@redhat.com>
+2004-01-21 Tom Rix <tcrix@worldnet.att.net>
- Add capability to write corefile note sections, for gdb.
- * elf.c (elfcore_write_note): New function.
- (elfcore_write_prpsinfo): New function.
- (elfcore_write_prstatus): New function.
- (elfcore_write_pstatus): New function.
- (elfcore_write_prfpreg): New function.
- (elfcore_write_prxfpreg): New function.
- * elf-bfd.h: Add prototypes for above functions.
+ * reloc.c: New 5 bit reloc, BFD_RELOC_M68HC12_5B, for m68hc12 movb/movw.
+ * bfd-in2.h, libbfd.h: Rebuilt.
-2002-01-08 Alexandre Oliva <aoliva@redhat.com>
+2004-01-20 Danny Smith <dannysmith@users.sourceforge.net>
- * elf.c (elf_fake_sections): Propagate errors from
- elf_backend_fake_section.
+ * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Don't remove
+ IMAGE_SCN_MEM_WRITE flag from .text section if WP_TEXT
+ flag has been cleared.
-2002-01-07 Jason Thorpe <thorpej@wasabisystems.com>
+2004-01-19 Kazu Hirata <kazu@cs.umass.edu>
- * Makefile.am (BFD32_BACKENDS): Add elf32-sh-nbsd.lo.
- (BFD32_BACKENDS_CFILES): Add elf32-sh-nbsd.c.
- (elf32-sh-nbsd.lo): New rule.
- * Makefile.in: Regenerate.
- * config.bfd (sh*le-*-netbsdelf*): New target.
- (sh*-*-netbsdelf*): New target.
- * configure.in: Include netbsd-core.lo for native sh*-*-netbsd*.
- (bfd_elf32_shnbsd_vec): New vector.
- (bfd_elf32_shlnbsd_vec): New vector.
- * configure: Regenerate.
- * elf32-sh-nbsd.c: New file.
- * targets.c: Update copyright years.
- (_bfd_target_vector): Add bfd_elf32_shlnbsd_vec and
- bfd_elf32_shnbsd_vec.
+ * coff-h8300.c: Add and adjust comments about relaxation.
+ * elf32-h8300.c: Likewise.
-2002-01-07 Aldy Hernandez <aldyh@redhat.com>
+2004-01-16 Kazu Hirata <kazu@cs.umass.edu>
- * coff-rs6000.c (READ20): Use bfd_scan_vma.
+ * coff-h8300.c: Fix comment typos.
+ * elf32-h8300.c: Likewise.
-2002-01-07 Geoffrey Keating <geoffk@redhat.com>
+2004-01-16 Kazu Hirata <kazu@cs.umass.edu>
- * elflink.h (elf_link_input_bfd): Don't ask for the merged offset
- of a symbol in a section that will be deleted.
+ * coff-h8300.c: Add comments about relaxation.
+ * elf32-h8300.c: Likewise.
-2002-01-07 Nick Clifton <nickc@cambridge.redhat.com>
+2004-01-14 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
- * po/es.po: New file: Spanish translation.
- * configure.in (ALL_LINGUAS): Add es.
+ * acinclude.m4: Quote names of macros to be defined by AC_DEFUN
+ throughout.
+ * aclocal.m4: Regenerate.
* configure: Regenerate.
-2002-01-06 Steve Ellcey <sje@cup.hp.com>
-
- * elfxx-ia64.c (is_unwind_section_name): Add target vector as
- argument so we can handle HP-UX specially.
- (elfNN_ia64_hpux_vec): New for use in is_unwind_section_name.
- (elfNN_hpux_backend_section_from_bfd_section): New for support
- of SHN_IA_64_ANSI_COMMON.
- (elfNN_ia64_relax_section): Add support for SHN_IA_64_ANSI_COMMON.
- (is_unwind_section_name): Add special HP-UX support.
- (elfNN_ia64_section_from_shdr): Add support for more sections.
- (elfNN_ia64_fake_sections): Modify is_unwind_section_name call and
- add support for more sections.
- (elfNN_ia64_additional_program_headers): Modify
- is_unwind_section_name call.
- (elfNN_ia64_modify_segment_map): Remove assumption that there is
- only one unwind section in segment.
-
-2002-01-06 Alan Modra <amodra@bigpond.net.au>
-
- * syms.c (_bfd_generic_make_empty_symbol): New function.
- * libbfd-in.h (_bfd_nosymbols_make_empty_symbol): Define as
- _bfd_generic_make_empty_symbol.
- * libbfd.h: Regenerate.
- * bfd-in2.h: Regenerate.
- * hppabsd-core.c (hppabsd_core_make_empty_symbol): Delete function.
- (hppabsd_core_get_symtab_upper_bound): Don't define.
- (hppabsd_core_get_symtab): Likewise.
- (hppabsd_core_print_symbol): Likewise.
- (hppabsd_core_get_symbol_info): Likewise.
- (hppabsd_core_bfd_is_local_label_name): Likewise.
- (hppabsd_core_get_lineno): Likewise.
- (hppabsd_core_find_nearest_line): Likewise.
- (hppabsd_core_bfd_make_debug_symbol): Likewise.
- (hppabsd_core_read_minisymbols): Likewise.
- (hppabsd_core_minisymbol_to_symbol): Likewise.
- (hppabsd_core_vec): Use BFD_JUMP_TABLE_SYMBOLS (_bfd_nosymbols).
- Formatting fixes.
- * hpux-core.c: Similarly.
- * irix-core.c: Similarly.
- * osf-core.c: Similarly.
- * sco5-core.c: Similarly.
- * binary.c (binary_make_empty_symbol): Remove function, define as
- _bfd_generic_make_empty_symbol.
- * ihex.c (ihex_make_empty_symbol): Likewise.
- * mmo.c (mmo_make_empty_symbol): Likewise.
- * ppcboot.c (ppcboot_make_empty_symbol): Likewise.
- * srec.c (srec_make_empty_symbol): Likewise.
- * versados.c (versados_make_empty_symbol): Likewise.
- * vms.c (_bfd_vms_make_empty_symbol): Remove.
- (vms_make_empty_symbol): Define as _bfd_generic_make_empty_symbol.
- * vms-gsd.c (_bfd_vms_slurp_gsd): Call bfd_make_empty_symbol
- rather than _bfd_vms_make_empty_symbol.
- * vms-misc.c (new_symbol): Likewise.
-
-2002-01-05 Alan Modra <amodra@bigpond.net.au>
-
- * section.c (bfd_section_init): Remove unnecessary initialisations.
- (bfd_section_list_clear): New function.
- (bfd_section_list_remove, bfd_section_list_insert): New macros.
- (_bfd_strip_section_from_output): Use them.
- * coffcode.h (coff_set_alignment_hook): Likewise.
- * elf32-mips.c (_bfd_mips_elf_final_link): Likewise.
- * elf64-mips.c (mips_elf64_final_link): Likewise.
- * elf64-mmix.c (mmix_elf_final_link): Likewise.
- * sunos.c (sunos_add_dynamic_symbols): Likewise.
- * xcofflink.c (_bfd_xcoff_bfd_final_link): Likewise.
- * bfd-in2.h: Regenerate.
-
- * netbsd-core.c (netbsd_core_file_p): Use bfd_make_section_anyway
- rather than doing our own section handling. Clean up after errors
- with bfd_release and bfd_section_list_clear. Handle unexpected
- flags.
- * aoutf1.h (sunos4_core_file_p): Likewise.
- * aix386-core.c (aix386_core_file_p): Likewise.
- * cisco-core.c (cisco_core_file_validate): Likewise.
- * ptrace-core.c (ptrace_unix_core_file_p): Likewise.
- * trad-core.c (trad_unix_core_file_p): Likewise.
+2004-01-13 Ian Lance Taylor <ian@wasabisystems.com>
- * hppabsd-core.c (hppabsd_core_core_file_p): Clean up after errors
- with bfd_release and bfd_section_list_clear.
- * hpux-core.c (hpux_core_core_file_p): Likewise.
- * irix-core.c (irix_core_core_file_p): Likewise.
- * lynx-core.c (lynx_core_file_p): Likewise.
- * osf-core.c (osf_core_core_file_p): Likewise.
- * rs6000-core.c (rs6000coff_core_p): Likewise.
- * sco5-core.c (sco5_core_file_p): Likewise.
+ * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Call
+ mips_elf64_rtype_to_howto instead of using howto_table.
- * elf32-mips.c (_bfd_mips_elf_lo16_reloc): Simplify, and perform
- sign extension adjustments without conditionals.
-
-2002-01-04 Jakub Jelinek <jakub@redhat.com>
-
- * elf-eh-frame.c (_bfd_elf_write_section_eh_frame): Don't crash if
- CIE at .eh_frame start is removed due to no FDEs referencing it.
+2004-01-13 Daniel Jacobowitz <drow@mvista.com>
+
+ * elf32-arm.h (elf32_arm_final_link_relocate): Check that we created
+ the .plt section.
+ (elf32_arm_check_relocs): Don't increment the PLT refcount for
+ relocs which would not use the PLT.
+
+2004-01-13 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_check_relocs): Ignore !SEC_ALLOC relocs.
+ (ppc64_elf_gc_sweep_hook): Likewise.
+ (ppc64_elf_size_dynamic_sections): Test for .plt directly.
+
+2004-01-12 Anil Paranjpe <anilp1@KPITCummins.com>
+
+ Adds linker relaxation support for bit manipulation insns like
+ band, bclr, biand, bild, bior, bist, bixor, bld, bnot, bor, bset,
+ bst, btst, bxor.
+ * elf32-h8300.c: Opcode for bit manipulation insn is checked in
+ elf32_h8_relax_section function while relxation for aa:16 and aa:32.
+ * coff-h8300.c: Opcode for bit manipulation insn is checked in
+ h8300_reloc16_extra_cases function while relxation for aa:16 and aa:32.
+
+2004-01-12 Alan Modra <amodra@bigpond.net.au>
+
+ * dwarf2.c: Convert to C90, remove unneeded casts and prototypes.
+
+2004-01-11 Kazu Hirata <kazu@cs.umass.edu>
+
+ * elf32-h8300.c: Fix formatting.
+
+2004-01-11 Kazu Hirata <kazu@cs.umass.edu>
+
+ * elf32-cris.c (cris_elf_gc_sweep_hook): Return early if no
+ dynamic object is present. Declare r_symndx and h in an inner
+ scope.
+ * elf32-vax.c (elf_vax_gc_sweep_hook): Likewise.
+
+2004-01-09 Daniel Jacobowitz <drow@mvista.com>
+
+ * elf32-arm.h (struct elf32_arm_relocs_copied): Remove pc_count.
+ (elf32_arm_copy_indirect_symbol): Don't copy pc_count.
+ (elf32_arm_final_link_relocate): Handle PLT32 and PC24 relocs
+ identically. Do not emit PC24 relocations for shared libraries.
+ (elf32_arm_gc_sweep_hook): Handle PLT32 and PC24 relocs
+ identically. Don't adjust pc_count.
+ (elf32_arm_check_relocs): Handle PLT32 and PC24 relocs identically.
+ Set ELF_LINK_HASH_NEEDS_PLT for both. Don't adjust pc_count; don't
+ adjust count for branch relocations.
+ (allocate_dynrelocs): Correct typo in call to
+ WILL_CALL_FINISH_DYNAMIC_SYMBOL. Never allocate space for
+ PC24 or PLT32 relocs when linking.
+
+2004-01-09 Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
+
+ * coff-arm.c (aoutarm_std_reloc_howto): [ARM_WINCE] Synchronize ARM_26D
+ relocation howto with ARM_26 one for consistency.
+ (coff_arm_relocate_section): Set partial_inplace for ARM_26 relocations
+ that will be converted to ARM_26D ones, since we always want 'done'
+ relocations to be reflected in section's data.
+ (coff_arm_relocate_section): [ARM_WINCE] Quick fix for BL instruction
+ offset.
+ (_bfd_final_link_relocate): Do not modify "inplace" data, if not
+ requested.
+
+2004-01-08 Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
+
+ * coff-arm.c (coff_arm_relocate_section): Do not alter relocs that
+ are not partial_inplace during a relocatable link.
+
+2004-01-08 Kazu Hirata <kazu@cs.umass.edu>
+
+ * elf32-m68k.c (elf_m68k_gc_sweep_hook): Return early
+ if no dynamic object is present. Declare r_symndx and h in an
+ inner scope.
+
+2004-01-07 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elfxx-ia64.c (elfNN_ia64_relax_section): Don't install
+ trampoline if it is known out of range.
+
+2004-01-06 Alexandre Oliva <aoliva@redhat.com>
+
+ 2003-12-17 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (_frv_osec_readonly_p): New.
+ (_frv_emit_got_relocs_plt_entries): Don't emit rofixup for
+ undefweak symbol.
+ (_frv_count_got_plt_entries): Adjust expected count accordingly.
+ (elf32_frv_relocate_section): Likewise. Error out if attempting
+ to emit rofixups or dynamic relocs in read-only segments. Use
+ _bfd_elf_section_offset to adjust r_offsets in rofixups and
+ dynamic relocations.
+ 2003-12-12 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (elf32_frv_relocate_section): Compute dynamic
+ relocations or fixups involving merged sections correctly. Avoid
+ crash when undefined symbol is referenced by R_FRV_32 or
+ R_FRV_FUNCDESC_VALUE.
+ 2003-12-02 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (elf32_frv_relocate_section): Add output_offset of
+ input section holding local symbol to addend of R_FRV_32 or
+ R_FRV_FUNCDESC_VALUE dynamic relocation.
+ 2003-11-27 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (elf32_frv_modify_segment_map): Add link info arg.
+ (elf32_frv_always_size_sections): Don't store pointer to
+ __stacksize symbol in sec_info.
+ (elf32_frv_modify_segment_map): Look it up here.
+ 2003-11-26 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Emit the address
+ of the lazy PLT entry, not only its offset, as the low word of a
+ function descriptor.
+ 2003-11-10 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (elf32_frv_always_size_sections): Define __stacksize
+ if a hash table entry already exists but is not a definition.
+ 2003-11-05 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (frv_elf_link_hash_table_create): Use bfd_zalloc.
+ (_frv_add_rofixup): Don't inline.
+ (_frv_emit_got_relocs_plt_entries): Use NULL as funcdesc address
+ for undefweak symbols.
+ (elf32_frv_relocate_section): Avoid crash while computing
+ relocation when linking with shared library. Only emit rofixups
+ and dynamic relocations for alloc&load sections. Mark binaries
+ with inter-segment relocations for relocation as a unit.
+ (_frv_create_got_section): Rename .rofixup.got to .rofixup.
+ (DEFAULT_STACK_SIZE): New.
+ (_frv_count_got_plt_entries): Fix thinko in deciding whether to
+ emit rofixups or dynamic relocs when linking dynamic non-PIE
+ executables.
+ (elf32_frv_size_dynamic_sections): Generate rofixup on PIEs and
+ shared libs too. Reserve the last entry for the GOT pointer.
+ (elf32_frv_finish_dynamic_sections): Emit it.
+ (elf32_frv_always_size_sections): New.
+ (elf32_frv_modify_segment_map): New.
+ (elf32_frv_check_relocs): Reserve relocs32 space only in ALLOC
+ sections.
+ (frv_elf_merge_private_bfd_data): Clear PIC bit if FDPIC is set.
+ (frv_elf_print_private_bfd_data): Handle FDPIC and LIBPIC.
+ (elf_backend_always_size_sections): New.
+ (elf_backend_modify_segment_map): New.
+ 2003-10-31 Alexandre Oliva <aoliva@redhat.com>
+ * config.bfd: Added frv-*-*linux*.
+ * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Use idx 0 for
+ ABS section, instead of crashing.
+ (elf32_frv_relocate_section): Don't crash before warning about
+ different segments in non-PIC relocation.
+ 2003-10-17 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (elf32_frv_relocate_section): Don't warn on LABEL24
+ relocs to undefweak symbols.
+ (elf32_frv_relocate_section): Ditto for undefined symbols.
+ 2003-10-06 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (elf32_frv_create_dynamic_sections): Make sure
+ gotfixup section was created.
+ 2003-09-30 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (elf32_frv_howto_table): Change GOT12,
+ FUNCDESC_GOT12, GOTOFF12 and FUNCDESC_GOTOFF12 to
+ complain_overflow_signed.
+ * elf32-frv.c (_frv_add_rofixup): Do not error out if contents
+ have not been allocated.
+ (_frv_emit_got_relocs_plt_entries): Return non-void. Assert
+ privfd only if dynamic sections were created.
+ (elf32_frv_relocate_section): Compute gprel_segment, and use it
+ for GPREL relocs. When linking relocatable FDPIC executables,
+ emit warnings for relocations that would be illegal on PIE or
+ shared libraries. Emit rofixup for R_FRV_32 only if input object
+ is not FDPIC.
+ (_frv_create_got_section): Define _gp symbol in the rofixup
+ section.
+ (elf32_frv_finish_dynamic_sections): If rofixups needed but
+ dynamic sections missing, error out requesting -melf32frvfd.
+ 2003-09-19 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Rearrange
+ computation of addends from section and global or local symbol
+ value. Change return type to bfd_boolean, and return a failure if
+ a dynamic FUNCDESC or FUNCDESC_VALUE relocation that requires a
+ nonzero addend is required.
+ (elf32_frv_relocate_section): Likewise. Print error for
+ unsupported nonzero addends.
+ 2003-09-18 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (FRV_SYM_LOCAL): In the absence of dynamic sections,
+ force everything local.
+ (_frv_emit_got_relocs_plt_entries): Cope with NULL sec.
+ * elf32-frv.c (struct frv_elf_link_hash_table): Added sgotfixup.
+ (frv_gotfixup_section): New.
+ (FRV_SYM_LOCAL): Accept undefweak and local common symbols.
+ (struct frv_pic_relocs_info): Split relocs into relocs32, relocsfd
+ and relocsfdv.
+ (_frv_add_rofixup): New.
+ (_frv_emit_got_relocs_plt_entries): Generate fixups for non-PIE
+ fdpic executables. Use FRV_SYM_LOCAL more widely to simplify and
+ improve some ugly conditions.
+ (elf32_frv_relocate_section): Likewise. Reject inter-segment
+ relocations in fdpic.
+ (_frv_create_got_section): Create .rofixup.got section.
+ (struct _frv_dynamic_got_info): Added fixups.
+ (_frv_count_got_plt_entries): Account in-GOT relocations into
+ relocs32, relocsfd and relocsfdv. Account them into relocs or
+ fixups, as appropriate.
+ (elf32_frv_size_dynamic_sections): Size rofixup section. Simplify
+ sizing of gotrel.
+ (elf32_frv_finish_dynamic_sections): Verify that the right number
+ of relocations and fixups was generated.
+ (elf32_frv_check_relocs): Compute relocs32, relocsfd and
+ relocsfdv.
+ * elf32-frv.c (FRV_SYM_LOCAL): New macro, used instead of
+ SYMBOL_CALLS_LOCAL and SYMBOL_REFERENCES_LOCAL.
+ (FRV_FUNCDESC_LOCAL): New macro, used to decide whether a function
+ descriptor of a (formerly-)global symbol is local.
+ (struct frv_pic_relocs_info): Adjust comments.
+ (_frv_emit_got_relocs_plt_entries): Adjust.
+ (elf32_frv_relocate_section): Likewise.
+ (_frv_count_got_plt_entries): Likewise.
+ * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Don't add global
+ symbol's value to addend in the common preamble. Decay dynamic
+ symbols to section+offset if they bind or call locally, for GOT
+ and FUNCDESC_VALUE, respectively.
+ (elf32_frv_relocate_section): Likewise.
+ (elf32_frv_check_relocs): Don't register as dynamic symbols of
+ internal or hidden visibility.
+ 2003-09-17 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (_frv_emit_got_relocs_plt_entries): Get addend as
+ argument, so as to not call _bfd_elf_rel_local_sym to compute it.
+ (elf32_frv_relocate_section): Pass relocation addend in. Use
+ original relocation addend to look up the got relocs/plt entries
+ table. Do not call _bfd_elf_rel_local_sym. Don't error out when
+ processing relocations that reference .scommon symbols.
+ 2003-09-15 Alexandre Oliva <aoliva@redhat.com>
+ Introduce support for dynamic linking.
+ * elf32-frv.c (R_FRV_FUNCDESC_VALUE): Mark it as 64 bits.
+ (elf32_frv_rel_32_howto, elf32_frv_rel_funcdesc_howto,
+ elf32_frv_rel_funcdesc_value_howto): New REL descriptors.
+ (frv_reloc_type_lookup): Return REL howtos for executables and
+ dynamic libraries.
+ (frv_info_to_howto_rel): New.
+ (struct frv_elf_link_hash_table): New.
+ (frv_hash_table, frv_got_section, frv_gotrel_section,
+ frv_plt_section, frv_pltrel_section, frv_relocs_info,
+ frv_got_initial_offset, frv_plt_initial_offset): New macros.
+ (frv_elf_link_hash_table_create): New.
+ (struct frv_pic_relocs_info): New.
+ (frv_pic_relocs_info_hash, frv_pic_relocs_info_eq): New.
+ (frv_pic_relocs_info_find): New.
+ (frv_pic_relocs_info_for_global, frv_pic_relocs_info_for_local):
+ New.
+ (FRV_LZPLT_BLOCK_SIZE, FRV_LZPLT_RESOLVE_LOC): New.
+ (_frv_add_dyn_reloc, _frv_osec_to_segment): New.
+ (_frv_emit_got_relocs_plt_entries): New.
+ (elf32_frv_relocate_section): Add support for dynamic linking.
+ Handle new relocations.
+ (_frv_create_got_section): New.
+ (elf32_frv_create_dynamic_sections): New.
+ (ELF_DYNAMIC_INTERPRETER): New.
+ (struct _frv_dynamic_got_info): New.
+ (_frv_count_got_plt_entries): New.
+ (struct _frv_dynamic_got_plt_info): New.
+ (_frv_compute_got_alloc_data): New.
+ (_frv_get_got_entry, _frv_get_fd_entry): New.
+ (_frv_assign_got_entries, _frv_assign_plt_entries): New.
+ (_frv_resolve_final_relocs_info): New.
+ (elf32_frv_size_dynamic_sections): New.
+ (elf32_frv_finish_dynamic_sections): New.
+ (elf32_frv_adjust_dynamic_symbol): New.
+ (elf32_frv_finish_dynamic_symbol): New.
+ (elf32_frv_check_relocs): Handle new relocs. Explain how the
+ whole thing works.
+ (elf_info_to_howto_rel): Define.
+ (bfd_elf32_bfd_link_hash_table_create): Define.
+ (elf_backend_create_dynamic_sections): Define.
+ (elf_backend_adjust_dynamic_symbol): Define.
+ (elf_backend_size_dynamic_sections): Define.
+ (elf_backend_finish_dynamic_symbol): Define.
+ (elf_backend_finish_dynamic_sections): Define.
+ (elf_backend_want_got_sym): Define.
+ (elf_backend_got_header_size): Define.
+ (elf_backend_want_got_plt): Define.
+ (elf_backend_plt_readonly): Define.
+ (elf_backend_want_plt_sym): Define.
+ (elf_backend_plt_header_size): Define.
+ (elf_backend_may_use_rel_p): Define.
+ (elf_backend_may_use_rela_p): Define.
+ (elf_backend_default_use_rela_p): Define.
+ 2003-08-08 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (R_FRV_FUNCDESC_VALUE, R_FRV_FUNCDESC_GOTOFF12,
+ R_FRV_FUNCDESC_GOTOFFHI, R_FRV_FUNCDESC_GOTOFFLO, R_FRV_GOTOFF12,
+ R_FRV_GOTOFFHI, R_FRV_GOTOFFLO): New.
+ (frv_reloc_map): Map the corresponding BFD relocs to them.
+ (frv_reloc_type_lookup): ... and back to BFD relocs.
+ * reloc.c: New relocs.
+ * bfd-in2.h, libbfd.h: Rebuilt.
+ 2003-08-04 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-frv.c (R_FRV_GOT12, R_FRV_GOTHI, R_FRV_GOTLO,
+ R_FRV_FUNCDESC, R_FRV_FUNCDESC_GOT12, R_FRV_FUNCDESC_GOTHI,
+ R_FRV_FUNCDESC_GOTLO): New.
+ (frv_reloc_map): Map the corresponding BFD relocs to them.
+ (frv_reloc_type_lookup): ... and back to BFD relocs.
+ * reloc.c: New relocs.
+ * bfd-in2.h, libbfd.h: Rebuilt.
-2002-01-04 Jason Thorpe <thorpej@wasabisystems.com>
+2004-01-05 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
- * config.bfd (x86_64-*-netbsd*): New target.
- * configure.in (x86_64-*-netbsd*): Set COREFILE
- to netbsd-core.lo.
- * configure: Regenerated.
+ * elf32-mips.c (ELF_MAXPAGESIZE): Redefine for traditional
+ targets to support pages of up to 64kB.
+ (elf32_bed): Redefine to get a separate backend data structure for
+ traditional targets.
+ * elf64-mips.c (ELF_MAXPAGESIZE): Redefine for traditional
+ targets to support pages of up to 64kB.
+ (elf64_bed): Redefine to get a separate backend data structure for
+ traditional targets.
+ * elfn32-mips.c (ELF_MAXPAGESIZE): Redefine for traditional
+ targets to support pages of up to 64kB.
+ (elf32_bed): Redefine to get a separate backend data structure for
+ traditional targets.
-2002-01-03 Tom Rix <trix@redhat.com>
+2004-01-04 Mark Kettenis <kettenis@gnu.org>
- * xcofflink.c (_bfd_xcoff_bfd_final_link): Update .pad section ordering
- for recent bfd_make_section_anyway change.
+ * elf32-sparc.c (elf32_sparc_grok_psinfo): New function.
-2002-01-03 Nick Clifton <nickc@cambridge.redhat.com>
+2004-01-02 Mark Kettenis <kettenis@gnu.org>
- * elf32-arm.h (elf32_arm_final_link_relocate): Handle
- R_ARM_THM_PC11 reloc.
+ * elf32-i386.c (elf_i386_grok_prstatus): Add support for FreeBSD.
+ (elf_i386_grok_psinfo): Likewise.
-2002-01-02 Nick Clifton <nickc@cambridge.redhat.com>
+2004-01-02 Bernardo Innocenti <bernie@develer.com>
- * configure.in (LINGUAS): Add ja.
- * configure: Regenerate.
- * po/ja.po: Import from translation project's web site.
+ * config.bfd: Add m68k-uClinux target.
-2002-01-02 Nick Clifton <nickc@cambridge.redhat.com>
+2004-01-01 Grant Edwards <grante@visi.com>
- * elf32-arm.h (elf32_arm_merge_private_bfd_data): Reformat error
- messages to ease translation into other languages.
+ * elflink.h (elf_gc_sections): Warn when gc-sections option is ignored.
+ * elf32-h8300.c (elf32_h8_gc_mark_hook): New function.
+ (elf32_h8_gc_sweep_hook): New function.
+ (elf_backend_gc_mark_hook): Define.
+ (elf_backend_gc_sweep_hook): Define.
+ (elf_backend_can_gc_sections): Define.
-For older changes see ChangeLog-0001
+For older changes see ChangeLog-0203
Local Variables:
mode: change-log
diff --git a/contrib/binutils/bfd/ChangeLog-0001 b/contrib/binutils/bfd/ChangeLog-0001
index 3000c03..b5a3475 100644
--- a/contrib/binutils/bfd/ChangeLog-0001
+++ b/contrib/binutils/bfd/ChangeLog-0001
@@ -1514,7 +1514,7 @@
2001-10-08 Aldy Hernandez <aldyh@redhat.com>
- * bfd/config.bfd (targ_cpu): Add arm9e-*-elf.
+ * config.bfd (targ_cpu): Add arm9e-*-elf.
2001-10-06 Stephane Carrez <Stephane.Carrez@worldnet.fr>
@@ -2858,13 +2858,13 @@
2001-08-31 Eric Christopher <echristo@redhat.com>
Jason Eckhardt <jle@redhat.com>
- * bfd/archures.c: Add mipsisa32 and mipsisa64. Remove mips32,
+ * archures.c: Add mipsisa32 and mipsisa64. Remove mips32,
mips32_4k and mips64.
- * bfd/aoutx.h: Remove bfd_mach_mips32, bfd_mach_mips32_4k,
+ * aoutx.h: Remove bfd_mach_mips32, bfd_mach_mips32_4k,
bfd_mach_mips64. Add bfd_mach_mipsisa32, bfd_mach_mipsisa64.
- * bfd/cpu-mips.c: Ditto.
- * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing): Ditto.
- * bfd/bfd-in2.h: Regenerate.
+ * cpu-mips.c: Ditto.
+ * elf32-mips.c (_bfd_mips_elf_final_write_processing): Ditto.
+ * bfd-in2.h: Regenerate.
2001-08-31 Jakub Jelinek <jakub@redhat.com>
@@ -3726,7 +3726,7 @@
2001-07-04 H.J. Lu <hjl@gnu.org>
- * bfd/elf32-mips.c (_bfd_mips_elf_final_write_processing):
+ * elf32-mips.c (_bfd_mips_elf_final_write_processing):
Handle bfd_mach_mips4400, bfd_mach_mips4600 and
bfd_mach_mips5000.
@@ -4529,7 +4529,7 @@
* elf32-openrisc.c (openrisc_elf_howto_table): Do not complain
about overflow in R_OPENRISC_LO_16_IN_INSN and
- R_OPENRISC_HI_16_IN_INSN.Index: bfd/elf32-openrisc.c
+ R_OPENRISC_HI_16_IN_INSN.
2001-04-30 H.J. Lu <hjl@gnu.org>
diff --git a/contrib/binutils/bfd/ChangeLog-0203 b/contrib/binutils/bfd/ChangeLog-0203
new file mode 100644
index 0000000..f99029a
--- /dev/null
+++ b/contrib/binutils/bfd/ChangeLog-0203
@@ -0,0 +1,11405 @@
+2003-12-19 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
+
+ Adfd m32r-linux and PIC support. Add new ABI that uses RELA.
+ * config.bfd (m32r*-*-linux*, m32r*le-*-linux*, m32r*le-*-*): Added.
+ * configure.in (bfd_elf32_m32rlin_vec, bfd_elf32_m32rlelin_vec,
+ bfd_elf32_m32rle_vec): Added
+ * configure: Regenerated.
+ * elf32-m32r.c (m32r_info_to_howto, m32r_elf_adjust_dynamic_symbol,
+ m32r_elf_size_dynamic_sections, m32r_elf_create_dynamic_sections,
+ m32r_elf_finish_dynamic_sections, m32r_elf_finish_dynamic_symbol,
+ allocate_dynrelocs, readonly_dynrelocs, m32r_elf_reloc_type_class,
+ m32r_elf_fake_sections): Added.
+ (m32r_elf_howto_table): Added
+ R_M32R_16_RELA, R_M32R_32_RELA, R_M32R_24_RELA,
+ R_M32R_10_PCREL_RELA, R_M32R_18_PCREL_RELA,
+ R_M32R_26_PCREL_RELA, R_M32R_HI16_ULO_RELA,
+ R_M32R_HI16_SLO_RELA, R_M32R_LO16_RELA,
+ R_M32R_SDA16_RELA, R_M32R_RELA_GNU_VTINHERIT,
+ R_M32R_RELA_GNU_VTENTRY, R_M32R_GOT24,
+ R_M32R_26_PLTREL, R_M32R_COPY, R_M32R_GLOB_DAT,
+ R_M32R_JMP_SLOT, R_M32R_RELATIVE, R_M32R_GOTOFF,
+ R_M32R_GOTPC24, R_M32R_GOT16_HI_ULO,
+ R_M32R_GOT16_HI_SLO, R_M32R_GOT16_LO,
+ R_M32R_GOTPC_HI_ULO, R_M32R_GOTPC_HI_SLO,
+ R_M32R_GOTPC_LO.
+ (m32r_elf_relocate_section, m32r_elf_check_relocs): Changed for
+ New ABI.
+ * reloc.c: Add BFD_RELOC_M32R_GOT24, BFD_RELOC_M32R_26_PLTREL,
+ BFD_RELOC_M32R_COPY, BFD_RELOC_M32R_GLOB_DAT,
+ BFD_RELOC_M32R_JMP_SLOT, BFD_RELOC_M32R_RELATIVE,
+ BFD_RELOC_M32R_GOTOFF, BFD_RELOC_M32R_GOTPC24,
+ BFD_RELOC_M32R_GOT16_HI_ULO, BFD_RELOC_M32R_GOT16_HI_SLO,
+ BFD_RELOC_M32R_GOT16_LO, BFD_RELOC_M32R_GOTPC_HI_ULO,
+ BFD_RELOC_M32R_GOTPC_HI_SLO, BFD_RELOC_M32R_GOTPC_LO.
+ * targets.c (bfd_elf32_m32rlin_vec, bfd_elf32_m32rlelin_vec,
+ bfd_elf32_m32rle_vec): Added.
+ * bfd-in2.h: Regenerated.
+ * libbfd.h: Regenerated.
+
+2003-12-19 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * coffcode.h (styp_to_sec_flags): Don't treat .reloc section
+ as SEC_DEBUGGING.
+
+2003-12-18 Richard Sandiford <rsandifo@redhat.com>
+
+ * elf32-mips.c (elf_mips_howto_table_rel): Replace all uses of
+ mips_elf_generic_reloc with _bfd_mips_elf_generic_reloc. Use
+ _bfd_mips_elf_hi16_reloc for R_MIPS_HI16 and R_MIPS_GNU_REL_HI16,
+ _bfd_mips_elf_lo16_reloc for R_MIPS_LO16 and R_MIPS_GNU_REL_LO16,
+ and _bfd_mips_elf_got16_reloc for R_MIPS_GOT16. Change rightshift
+ to 16 for R_MIPS_HI16 and R_MIPS_GNU_REL_HI16.
+ (mips_elf_generic_reloc, struct mips_hi16, mips_elf_hi16_reloc)
+ (mips_elf_lo16_reloc, mips_elf_got16_reloc): Delete.
+ (_bfd_mips_elf32_gprel16_reloc): Remove special case.
+ (mips_elf_gprel32_reloc, mips32_64bit_reloc): Likewise.
+
+ * elf64-mips.c (mips_elf64_howto_table_rel): Replace all uses of
+ mips_elf_generic_reloc with _bfd_mips_elf_generic_reloc. Use
+ _bfd_mips_elf_hi16_reloc for R_MIPS_HI16, _bfd_mips_elf_lo16_reloc
+ for R_MIPS_LO16 and _bfd_mips_elf_got16_reloc for R_MIPS_GOT16.
+ Change R_MIPS_HI16's rightshift to 16.
+ (mips_elf64_howto_table_rela): Replace all uses of
+ mips_elf_generic_reloc with _bfd_mips_elf_generic_reloc.
+ Use _bfd_mips_elf_generic_reloc for R_MIPS_GOT16 as well.
+ (mips_elf64_hi16_reloc, mips_elf64_got16_reloc): Delete.
+ (mips_elf64_shift6_reloc): Remove special case. Use
+ _bfd_mips_elf_generic_reloc instead of returning bfd_reloc_continue.
+
+ * elfn32-mips.c (prev_reloc_section): Delete.
+ (prev_reloc_address, prev_reloc_addend): Delete.
+ (elf_mips_howto_table_rel, elf_mips_howto_table_rela): As for
+ elf64-mips.c
+ (GET_RELOC_ADDEND, SET_RELOC_ADDEND): Delete.
+ (mips_elf_generic_reloc, struct mips_hi16, mips_elf_hi16_reloc)
+ (mips_elf_lo16_reloc, mips_elf_got16_reloc): Delete.
+ (mips_elf_gprel16_reloc): Delete use of GET_RELOC_ADDEND.
+ (mips_elf_literal_reloc, mips_elf_gprel32_reloc): Likewise.
+ (mips16_jump_reloc, mips16_gprel_reloc): Likewise.
+ (mips_elf_shift6_reloc): Likewise. Delete use of SET_RELOC_ADDEND.
+
+ * elfxx-mips.c (_bfd_mips_elf_gprel16_with_gp): Use
+ _bfd_relocate_contents to install an in-place addend.
+ (mips_hi16): New structure.
+ (mips_hi16_list): Moved from elf32-mips.c.
+ (_bfd_mips_elf_hi16_reloc, _bfd_mips_elf_got16_reloc): New functions.
+ (_bfd_mips_elf_lo16_reloc, _bfd_mips_elf_generic_reloc): New functions.
+ (mips_elf_calculate_relocation): Assume addend is unshifted.
+ (_bfd_mips_elf_relocate_section): Don't apply the howto rightshift
+ on top of the usual high-part shift. Don't shift the addend right
+ before calling mips_elf_calculate_relocation.
+
+ * elfxx-mips.h (_bfd_mips_elf_hi16_reloc): Declare.
+ (_bfd_mips_elf_got16_reloc, _bfd_mips_elf_lo16_reloc): Declare.
+ (_bfd_mips_elf_generic_reloc): Declare.
+
+2003-12-16 Eric Youngdale <eric@mkssoftware.com>
+ Nick Clifton <nickc@redhat.com>
+
+ * peicode.h (pe_ILF_build_a_bfd): Only skip one instance of each
+ prefix character, if they are present.
+
+2003-12-15 Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
+ Nick Clifton <nickc@redhat.com>
+
+ * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Ensure that correct flags
+ are set on known section types.
+
+2003-12-12 Nick Clifton <nickc@redhat.com>
+
+ * po/ro.po: Updated translation.
+
+2003-12-12 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-hppa.c (elf64_hppa_link_output_symbol_hook): Check for
+ NULL dyn_h.
+
+2003-12-11 Nick Clifton <nickc@redhat.com>
+
+ * elf.c (INCLUDE_SECTION_IN_SEGMENT): Skip PT_GNU_STACK segments.
+
+2003-12-08 Richard Sandiford <rsandifo@redhat.com>
+
+ * elfxx-mips.h, elfxx-mips.c, cpu-mips.c: Convert prototypes.
+ Remove casts that were only needed for K&R compatibility.
+
+2003-12-08 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h (struct elf_backend_data): Remove "bfd *" and add
+ "elflink_hash_entry *" param to elf_backend_link_output_symbol_hook.
+ Add "elflink_hash_entry *" param to elf_backend_output_arch_syms.
+ * elflink.h (elf_link_output_sym): Add "elflink_hash_entry *" param,
+ and pass to output_symbol_hook.
+ (elf_bfd_final_link): Adjust elf_link_output_sym calls.
+ (elf_link_output_extsym): Likewise.
+ (elf_link_input_bfd): Likewise.
+ * elf32-sh64.c (sh64_elf_link_output_symbol_hook): Adjust.
+ * elf32-v850.c (v850_elf_link_output_symbol_hook): Likewise.
+ * elf64-mmix.c (mmix_elf_link_output_symbol_hook): Likewise.
+ * elf64-sh64.c (sh64_elf64_link_output_symbol_hook): Likewise.
+ * elfxx-mips.c (_bfd_mips_elf_link_output_symbol_hook): Likewise.
+ * elfxx-mips.h (_bfd_mips_elf_link_output_symbol_hook): Likewise.
+ * elf64-sparc.c (sparc64_elf_output_arch_syms): Likewise.
+ * elf64-hppa.c (elf64_hppa_link_output_symbol_hook): Likewise.
+ Validate dynh->h against h.
+ * elf64-ppc.c (struct ppc_link_hash_entry): Add adjust_done bitfield.
+ (link_hash_newfunc): Init it.
+ (adjust_opd_syms): New function.
+ (ppc64_elf_edit_opd): Set adjust_done when global .opd sym adjusted.
+ Set opd.adjust for all .opd relocs. Call adjust_opd_syms.
+ (ppc64_elf_tls_optimize): Adjust possible .opd sym values here.
+ (ppc64_elf_relocate_section): Also adjust syms not a multiple of 24.
+ (ppc64_elf_output_symbol_hook): New function.
+ (elf_backend_link_output_symbol_hook): Define.
+
+2003-12-07 Richard Sandiford <rsandifo@redhat.com>
+
+ * elf32-mips.c, elfn32-mips.c, elf64-mips.c: Convert prototypes.
+ Remove casts that were only needed for K&R compatibility.
+
+2003-12-05 Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
+
+ * coff-arm.c (aoutarm_std_reloc_howto [ARM_WINCE]): Set
+ partial_inplace for these relocs to FALSE for comptability with
+ the MS linker.
+ Remap ARM_26D relocation from 5 to 0. This fixes "bad fixup" error
+ generated by MS linker, and brings the relocation in line the MS
+ PE documentation.
+
+2003-12-04 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elf32-ppc.c (ppc_elf_relax_section): Don't check relax_finalizing.
+
+2003-12-04 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elfxx-ia64.c (elfNN_ia64_relax_section): Use the
+ need_relax_finalize field in link_info instead of
+ relax_finalizing to check if the relax finalize pass is being
+ done.
+
+2003-12-04 Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
+
+ * coff-arm.c (coff_arm_relocate_section, bfd_arm_process_before_allocation):
+ Change ARM26* to ARM_26* in comments to match definitions.
+ (coff_arm_adjust_symndx): Replace hard-coded constants with
+ appropriate definitions (ARM_26*).
+
+2003-12-04 Alan Modra <amodra@bigpond.net.au>
+
+ * coff-i860.c (coff_i860_reloc_nyi): Return bfd_reloc_not_supported.
+ * elf-m10300.c (elf32_mn10300_finish_hash_table_entry): Warning fixes.
+ (mn10300_elf_relax_section): Likewise.
+ * nlm32-alpha.c (ONES): Define.
+ (nlm32_alpha_howto_table): Use it to avoid warnings.
+
+2003-12-04 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-i386.c (elf_i386_object_p): Delete.
+ (elf_backend_object_p): Don't define.
+ * elf32-s390.c (elf_s390_object_p): No need to alloc tdata here.
+ * elf32-sh.c (sh_elf_object_p): Likewise.
+ * elf32-sparc.c (elf32_sparc_object_p): Likewise.
+ * elf64-alpha.c (elf64_alpha_object_p): Likewise.
+ * elf64-s390.c (elf_s390_object_p): Likewise.
+ * elf64-x86-64.c (elf64_x86_64_elf_object_p): Likewise.
+
+2003-12-03 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
+
+ * archures.c (bfd_mach_m32r2): Add new machine type.
+ * bfd-in2.h: Regenerate.
+ * cpu-m32r.c : Add new machine type.
+ * elf32-m32r.c (m32r_elf_object_p, m32r_elf_final_write_processing,
+ m32r_elf_merge_private_bfd_data): Add support for new machine
+ type.
+
+2003-12-03 Dave Airlie <airlied@linux.ie>
+
+ * config.bfd: Add vax-linux-gnu target.
+ * configure.in: Likewise.
+ * configure: Regenerate.
+
+2003-12-03 Alan Modra <amodra@bigpond.net.au>
+
+ * ecoff.c (ecoff_link_add_archive_symbols): Update for renamed
+ bfd_link_hash_entry field "next" -> "und_next".
+ * linker.c (_bfd_link_hash_newfunc): Likewise.
+ (bfd_link_add_undef): Likewise.
+ (_bfd_generic_link_add_archive_symbols): Likewise.
+ (_bfd_generic_link_add_one_symbol): Likewise.
+ * xcofflink.c (xcoff_link_add_symbols): Likewise.
+
+2003-12-02 Nick Clifton <nickc@redhat.com>
+
+ * configure.in (ALL_LINGUAS): Add ro.
+ * po/ro.po: New Romanian translation.
+
+2003-12-02 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2003-12-01 Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
+
+ * coffcode.h (coff_compute_section_file_positions): Set page_size
+ to 1 instead of 0 in the case file alignment value is zero.
+
+2003-12-01 Kazu Hirata <kazu@cs.umass.edu>
+
+ * coff-rs6000.c: Remove ARGSUSED and VARARGS.
+ * coff64-rs6000.c: Likewise.
+ * coffcode.h: Likewise.
+ * elf32-vax.c: Likewise.
+ * hash.c: Likewise.
+ * hppabsd-core.c: Likewise.
+ * hpux-core.c: Likewise.
+ * ihex.c: Likewise.
+ * netbsd-core.c: Likewise.
+ * osf-core.c: Likewise.
+ * pdp11.c: Likewise.
+ * ptrace-core.c: Likewise.
+ * sco5-core.c: Likewise.
+ * section.c: Likewise.
+ * sunos.c: Likewise.
+ * trad-core.c: Likewise.
+
+2003-12-01 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h (is_elf_hash_table): Take hash tab rather than info arg.
+ * elf.c (_bfd_elf_merge_sections): Adjust to suit.
+ (_bfd_elf_link_just_syms): Likewise.
+ (bfd_elf_get_needed_list): Likewise.
+ (bfd_elf_get_runpath_list): Likewise.
+ (_bfd_elf_link_hash_copy_indirect): Remove unneeded parens.
+ * elf32-hppa.c (elf32_hppa_setup_section_lists): Don't check hash tab
+ creator flavour.
+ (elf32_hppa_set_gp): Look up output sections rather than using htab.
+ * elf32-i960.c: Comment fix. Formatting.
+ * elf32-m32r.c (m32r_elf_add_symbol_hook): Use is_elf_hash_table
+ rather than testing creator flavour.
+ * elf32-sh64.c (sh64_elf_add_symbol_hook): Likewise.
+ * elf64-sh64.c (sh64_elf64_add_symbol_hook): Likewise.
+ * elflink.c (_bfd_elf_link_create_dynamic_sections): Adjust for
+ is_elf_hash_table change. Remove redundant test.
+ (bfd_elf_record_link_assignment): Use is_elf_hash_table rather than
+ testing creator flavour.
+ (elf_link_record_local_dynamic_symbol): Adjust for is_elf_hash_table.
+ (_bfd_elf_fix_symbol_flags): Likewise.
+ (_bfd_elf_adjust_dynamic_symbol): Likewise.
+ * elflink.h (elf_link_add_object_symbols): Likewise. Remove redundant
+ checks. Use is_elf_hash_table rather than testing creator flavour.
+ Use hash_table throughout in place of info->hash.
+ (elf_add_dynamic_entry): Adjust for is_elf_hash_table change.
+ (NAME(bfd_elf,size_dynamic_sections)): Likewise. Remove redundant
+ check.
+ (elf_bfd_final_link): Adjust for is_elf_hash_table change.
+ (elf_link_check_versioned_symbol): Use is_elf_hash_table rather than
+ testing creator flavour.
+ (elf_gc_sections): Add is_elf_hash_table check.
+ (elf_gc_common_finalize_got_offsets): Likewise.
+ (elf_bfd_discard_info): Adjust for is_elf_hash_table change. Remove
+ redundant check.
+ * elfxx-ia64.c (elfNN_ia64_relax_section): Use is_elf_hash_table
+ rather than testing creator flavour.
+
+2003-11-28 Christian Groessler <chris@groessler.org>
+
+ * cpu-z8k.c: Convert to ISO C90.
+ * coff-z8k.c: Likewise.
+
+2003-11-27 Alexandre Oliva <aoliva@redhat.com>
+
+ * elf-bfd.h (elf_backend_data::elf_backend_modify_segment_map):
+ Add link info argument.
+ * elf32-i370.c (elf_backend_modify_segment_map): Likewise.
+ * elf32-ppc.c (ppc_elf_modify_segment_map): Likewise.
+ * elf32-xtensa.c (elf_xtensa_modify_segment_map): Likewise.
+ * elf64-hppa.c (elf64_hppa_modify_segment_map): Likewise.
+ * elfxx-ia64.c (elfNN_ia64_modify_segment_map): Likewise.
+ * elfxx-mips.c (_bfd_mips_elf_modify_segment_map): Likewise.
+ * elfxx-mips.h (_bfd_mips_elf_modify_segment_map): Likewise.
+ * elf.c (assign_file_positions_except_relocs,
+ assign_file_positions_for_segments): Likewise. Adjust calls.
+
+2003-11-27 Mark Kettenis <kettenis@gnu.org>
+
+ * elf.c (elfcore_grok_netbsd_procinfo): Make a pseudosection out
+ of the note.
+
+2003-11-26 Daniel Jacobowitz <drow@mvista.com>
+ Richard Sandiford <rsandifo@redhat.com>
+
+ * elfxx-mips.c (mips_elf_set_global_got_offset): Don't set no_fn_stub.
+ (mips_elf_set_no_stub): New function.
+ (mips_elf_multi_got): Call it.
+ (_bfd_mips_elf_finish_dynamic_symbol): If a relocation is needed for
+ a secondary GOT entry, create an R_MIPS_32 or R_MIPS_64 relocation and
+ use mips_elf_create_dynamic_relocation to deal with any compatibility
+ issues. Store the adjusted addend in the GOT slot.
+
+2003-11-25 Mattias Engdegård <mattias@virtutech.se>
+
+ * stabs.c (_bfd_link_section_stabs): Skip N_EXCL stabs when
+ procesing N_BINCL stabs.
+
+2003-11-25 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc_type_of_stub): Disallow stubs other than
+ ppc_stub_plt_call to symbols defined in shared libs.
+
+2003-11-22 Jakub Jelinek <jakub@redhat.com>
+
+ * elf-bfd.h (ELF_LINK_POINTER_EQUALITY_NEEDED): Define new flag.
+ * elf.c (_bfd_elf_link_hash_copy_indirect): Copy it.
+ * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
+ (elf_i386_check_relocs): Set it.
+ (elf_i386_finish_dynamic_symbol): If it is not set,
+ clear st_value of SHN_UNDEF symbol.
+
+2003-11-20 Jim Blandy <jimb@redhat.com>
+
+ * cpu-powerpc.c (powerpc_compatible): Any ISA in the PowerPC
+ family is a superset of <bfd_arch_rs6000,bfd_mach_rs6k>.
+
+2003-11-20 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * elf32-s390.c (elf_s390_relocate_section): Don't recalculate symbol
+ section for reloc output and subtract the output section's address
+ from the addend when converting a relocation into one against a
+ section symbol.
+ * elf64-s390.c (elf_s390_relocate_section): Likewise.
+
+2003-11-18 James E Wilson <wilson@specifixinc.com>
+
+ * elfxx-ia64.c (get_fptr): For fptr_rel, use dynobj not abfd.
+ (elfNN_ia64_size_dynamic_sections): When stripping sections, check
+ for ia64_info->rel_fptr_sec.
+
+2003-11-18 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (toc_adjusting_stub_needed): Exit early if section
+ size is zero.
+
+2003-11-17 Daniel Jacobowitz <drow@mvista.com>
+
+ * elf.c (_bfd_elf_link_hash_copy_indirect): Copy
+ ELF_LINK_HASH_NEEDS_PLT. Fix formatting.
+ * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Likewise.
+ * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
+ * elf32-ppc.c (ppc_elf_copy_indirect_symbol): Likewise.
+ * elf32-s390.c (elf_s390_copy_indirect_symbol): Likewise.
+ * elf32-sh.c (sh_elf_copy_indirect_symbol): Likewise.
+ * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
+ * elf64-s390.c (elf_s390_copy_indirect_symbol): Likewise.
+ * elf64-x86-64.c (elf64_x86_64_copy_indirect_symbol): Likewise.
+ * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
+ * elf32-xtensa.c (elf_xtensa_copy_indirect_symbol): Remove.
+ (elf_backend_copy_indirect_symbol): Don't define.
+
+2003-11-14 Daniel Jacobowitz <drow@mvista.com>
+
+ * elfxx-mips.c (mips_elf_merge_gots): Weaken assert for local
+ GOT entries.
+
+2003-11-13 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * elf32-s390.c (elf_s390_relocate_section): Only convert R_390_32
+ to R_390_RELATIVE. Convert the other relocations against local
+ symbols to relocations against the start of the section.
+ * elf64-s390.c (elf_s390_relocate_section): Only convert R_390_64
+ to R_390_RELATIVE. Convert the other relocations against local
+ symbols to relocations against the start of the section.
+
+2003-11-11 Nick Clifton <nickc@redhat.com>
+
+ * elf-m10300.c (bfd_mn10300_elf_size_dynamic_sections): Use
+ info->executable not info->shared to decide if a .interp section
+ should be present.
+ * elf32-arm.h (elf32_arm_size_dynamic_sections): Likewise.
+ * elf32-cris.c (elf_cris_size_dynamic_sections): Likewise.
+ * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Likewise.
+ * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
+ * elf32-m68k.c (elf_m68k_size_dynamic_sections): Likewise.
+ * elf32-vax.c (elf_vax_size_dynamic_sections): Likewise.
+ * elf32-xtensa.c (elf_xtensa_size_dynamic_sections): Likewise.
+ * elf64-hppa.c (elf64_hppa_size_dynamic_sections): Likewise.
+ * elfxx-mips.c (_bfd_mips_size_dynamic_sections): Likewise.
+ * elflink.h (size_dynamic_sections): Likewise.
+
+2003-11-10 Jonathan Wilson <jonwil@tpgi.com.au>
+
+ * peXXigen.c (_bfd_XXi_swap_aouthdr_out): Swap out tls pointer.
+ (_bfd_XXi_final_link_postscript): Look for __tks_used symbol. If
+ found initialise the tls data directory entry.
+
+2003-11-07 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c (ppc_elf_install_value): Delete.
+ (shared_stub_entry, stub_entry): Make them arrays of ints.
+ Remove initial branch.
+ (ppc_elf_relax_section): Write one branch around all trampolines
+ instead. Correct bogus R_PPC_PLTREL24 handling. Correct
+ branch range check. Only use shared_stub_entry when shared.
+ Test that branches can reach stubs. Write trampolines out at
+ end so that just one realloc is used. Handle little-endian
+ mode. Move relevant code from ppc_elf_install_value to here.
+ (ppc_elf_relocate_section): Move code handling RELAX32 from
+ ppc_elf_install_value to here.
+
+2003-11-06 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c (ppc_elf_howto_raw); Add entry for R_PPC_RELAX32PC.
+ (ppc_elf_install_value): Handle R_PPC_RELAX32PC. Merge duplicate
+ cases.
+ (shared_stub_entry): Correct opcode.
+ (ppc_elf_relax_section): Generate R_PPC_RELAX32PC relocs.
+ (ppc_elf_relocate_section): Handle them.
+
+2003-11-05 Alan Modra <amodra@bigpond.net.au>
+
+ * elf.c (_bfd_elf_rela_local_sym): Accept asection **, and return
+ updated section in case of merged section.
+ * elf-bfd.h (_bfd_elf_rela_local_sym): Update declaration.
+ * elf-hppa.h (elf_hppa_relocate_section): Adjust call.
+ * elf-m10200.c (mn10200_elf_relocate_section): Likewise.
+ * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
+ * elf32-arm.h (elf32_arm_relocate_section): Likewise.
+ * elf32-avr.c (elf32_avr_relocate_section): Likewise.
+ * elf32-cris.c (cris_elf_relocate_section): Likewise.
+ * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
+ * elf32-frv.c (elf32_frv_relocate_section): Likewise.
+ * elf32-h8300.c (elf32_h8_relocate_section): Likewise.
+ * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
+ * elf32-i370.c (i370_elf_relocate_section): Likewise.
+ * elf32-i860.c (elf32_i860_relocate_section): Likewise.
+ * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
+ * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
+ * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
+ * elf32-msp430.c (elf32_msp430_relocate_section): Likewise.
+ * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
+ * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
+ * elf32-s390.c (elf_s390_relocate_section): Likewise.
+ * elf32-sh.c (sh_elf_relocate_section): Likewise.
+ * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
+ * elf32-v850.c (v850_elf_relocate_section) Likewise.
+ * elf32-vax.c (elf_vax_relocate_section): Likewise.
+ * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
+ * elf32-xtensa.c (elf_xtensa_relocate_section): Likewise.
+ * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
+ * elf64-mmix.c (mmix_elf_relocate_section): Likewise.
+ * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
+ * elf64-s390.c (elf_s390_relocate_section): Likewise.
+ * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
+ * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
+ * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
+ * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
+
+ * elf32-cris.c (cris_elf_relocate_section): Don't recalculate symbol
+ section for reloc output.
+ * elf32-i370.c (i370_elf_relocate_section): Likewise.
+ * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
+ * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
+ * elf32-vax.c (elf_vax_relocate_section): Likewise.
+ * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
+ * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
+
+ * elf32-ppc.c (ppc_elf_relocate_section): Don't recalculate everything
+ for R_PPC_RELAX32 reloc. Don't bother checking ppc_elf_install_value
+ return value.
+ * elf64-ppc.c (ppc64_elf_relocate_section <R_PPC64_TOC>): Sanity check
+ sec->id.
+
+2003-11-05 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-d10v.c (extract_rel_addend, insert_rel_addend): New functions.
+ (elf32_d10v_relocate_section): Use them to handle -r reloc
+ adjustments, and in place of _bfd_elf_rela_local_sym.
+
+ * cpu-iq2000.c (arch_info_struct): Warning fix.
+
+2003-11-05 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-hppa.c (ELIMINATE_COPY_RELOCS): Define.
+ (elf32_hppa_copy_indirect_symbol): Don't copy NON_GOT_REF on
+ weakdefs.
+ (elf32_hppa_check_relocs): Use ELIMINATE_COPY_RELOCS.
+ (elf32_hppa_adjust_dynamic_symbol): Likewise. Copy weakdef
+ NON_GOT_REF.
+ (allocate_dynrelocs): Use ELIMINATE_COPY_RELOCS and
+ SYMBOL_CALLS_LOCAL. Discard relocs for undef weak syms with
+ non-default visibility.
+ (elf32_hppa_relocate_section): Use ELIMINATE_COPY_RELOCS and
+ SYMBOL_CALLS_LOCAL.
+
+2003-11-04 Alan Modra <amodra@bigpond.net.au>
+
+ * aout-target.h, aoutf1.h, bfdio.c, bfdwin.c: Update copyright date.
+ * coff-apollo.c, coff-sparc.c, coff-w65.c, coff-we32k.c: Ditto.
+ * coff-z8k.c, coffgen.c, cpu-frv.c, cpu-h8500.c, cpu-hppa.c: Ditto.
+ * cpu-ia64-opc.c, cpu-m10300.c, cpu-mips.c, cpu-msp430.c: Ditto.
+ * cpu-rs6000.c, cpu-z8k.c, efi-app-ia32.c, elf32-am33lin.c: Ditto.
+ * gen-aout.c, hash.c, hp300hpux.c, init.c, mach-o.c: Ditto.
+ * nlm-target.h, nlm.c, som.h, stabs.c, sysdep.h, xsym.h: Ditto.
+
+ * elf-m10300.c (_bfd_mn10300_elf_create_got_section): Fix
+ "dereferencing type-punned pointer" warnings.
+
+ * aout-adobe.c (aout_adobe_set_section_contents): Constify location.
+ * aoutx.h (NAME(aout,set_section_contents)): Ditto.
+ * bfd-in2.h: Regenerate.
+ * binary.c (binary_set_section_contents): Ditto.
+ * bout.c (b_out_set_section_contents): Ditto.
+ * coff-tic54x.c (tic54x_set_section_contents): Ditto.
+ * coffcode.h (coff_set_section_contents): Ditto.
+ * ecoff.c (_bfd_ecoff_set_section_contents): Ditto.
+ * elf-bfd.h (_bfd_elf_set_section_contents): Ditto.
+ * elf.c (_bfd_elf_set_section_contents): Ditto.
+ * elfxx-mips.c (_bfd_mips_elf_set_section_contents): Ditto.
+ * elfxx-mips.h (_bfd_mips_elf_set_section_contents): Ditto.
+ * i386msdos.c (msdos_set_section_contents): Ditto.
+ * ieee.c (ieee_set_section_contents): Ditto.
+ * ihex.c (ihex_set_section_contents): Ditto.
+ * libaout.h (NAME(aout,set_section_contents)): Ditto.
+ * libbfd-in.h (_bfd_nowrite_set_section_contents): Ditto.
+ (_bfd_generic_set_section_contents): Ditto.
+ * libbfd.h: Regenerate.
+ * libbfd.c (_bfd_generic_set_section_contents): Ditto.
+ * libecoff.h (_bfd_ecoff_set_section_contents): Ditto.
+ * libnlm.h (nlmNAME(set_section_contents)): Ditto.
+ (struct nlm_backend_data <nlm_mangle_relocs>): Ditto.
+ * mmo.c (mmo_set_section_contents): Ditto.
+ * nlm32-alpha.c (nlm_alpha_mangle_relocs): Ditto.
+ * nlm32-i386.c (nlm_i386_mangle_relocs): Ditto.
+ * nlm32-ppc.c (nlm_powerpc_mangle_relocs): Ditto.
+ * nlm32-sparc.c (nlm_sparc_mangle_relocs): Ditto.
+ * nlmcode.h (nlm_set_section_contents): Ditto.
+ * oasys.c (oasys_set_section_contents): Ditto.
+ * pdp11.c (NAME(aout,set_section_contents)): Ditto.
+ * ppcboot.c (ppcboot_set_section_contents): Ditto.
+ * srec.c (srec_set_section_contents): Ditto.
+ * targets.c (BFD_JUMP_TABLE_WRITE <_bfd_set_section_contents>): Ditto.
+ * tekhex.c (tekhex_set_section_contents): Ditto.
+ (move_section_contents): Ditto.
+ * versados.c (versados_set_section_contents): Ditto.
+ * vms-misc.c (_bfd_save_vms_section): Ditto.
+ * vms.c (vms_set_section_contents): Ditto.
+ * vms.h (_bfd_save_vms_section): Ditto.
+
+2003-11-04 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc_size_one_stub): Size relbrlt. Accept info arg
+ rather than htab.
+ (ppc64_elf_size_stubs): Adjust ppc_size_one_stub traversal. Zero
+ relbrlt size.
+ (ppc64_elf_build_stubs): Allocate space for relbrlt.
+
+2003-11-04 Alan Modra <amodra@bigpond.net.au>
+
+ * bfd-in.h (_bfd_elf_tls_setup): Declare.
+ * bfd-in2.h: Regenerate.
+ * elf-bfd.h (struct elf_link_tls_segment): Delete.
+ (struct elf_link_hash_table): Add tls_sec and tls_size.
+ * elf.c (_bfd_elf_link_hash_table_init): Init tls_sec and tls_size.
+ * elflink.c (_bfd_elf_tls_setup): New function.
+ * elflink.h (struct elf_final_link_info): Remove first_tls_sec.
+ (elf_bfd_final_link): Don't set first_tls_sec here. Update code
+ saving tls segment info, round segment size up.
+ (elf_link_output_extsym): Adjust code using tls segment info.
+ (elf_link_input_bfd): Likewise.
+ * elf32-i386.c (dtpoff_base, tpoff): Likewise.
+ * elf32-s390.c (dtpoff_base, tpoff): Likewise.
+ * elf32-sh.c (dtpoff_base, tpoff): Likewise.
+ * elf32-sparc.c (dtpoff_base, tpoff): Likewise.
+ * elf64-s390.c (dtpoff_base, tpoff): Likewise.
+ * elf64-x86-64.c (dtpoff_base, tpoff): Likewise.
+ * elfxx-ia64.c (elfNN_ia64_tprel_base): Likewise.
+ (elfNN_ia64_dtprel_base): Likewise.
+ * elf64-alpha.c (alpha_get_dtprel_base): Likewise.
+ (alpha_get_tprel_base): Likewise.
+ (struct alpha_relax_info): Remove tls_segment.
+ (elf64_alpha_relax_got_load): Adjust invocation of
+ alpha_get_dtprel_base and alpha_get_tprel_base.
+ (elf64_alpha_relax_tls_get_addr): Likewise.
+ (elf64_alpha_relax_section): Likewise.
+ (elf64_alpha_relocate_section): Likewise.
+ (elf64_alpha_relax_find_tls_segment): Delete.
+ * elf32-ppc.c (struct ppc_elf_link_hash_table): Remove tls_sec.
+ (ppc_elf_tls_setup): Call _bfd_elf_tls_setup. Return section.
+ (ppc_elf_relocate_section): Adjust to use elf.tls_sec.
+ * elf32-ppc.h (ppc_elf_tls_setup): Update.
+ * elf64-ppc.c (struct ppc_link_hash_table): Remove tls_sec.
+ (ppc64_elf_tls_setup): Call _bfd_elf_tls_setup. Return section.
+ (ppc64_elf_tls_optimize): Adjust to use elf.tls_sec.
+ (ppc64_elf_relocate_section): Likewise.
+ * elf64-ppc.h (ppc64_elf_tls_setup): Update.
+
+2003-11-03 Daniel Jacobowitz <drow@mvista.com>
+
+ * elf-bfd.h (struct elf_backend_data): Remove plt_header_size.
+ * elf-m10300.c (elf_backend_plt_header_size): Don't define.
+ * elf32-arm.h (elf_backend_plt_header_size): Don't define.
+ * elf32-cris.c (elf_backend_plt_header_size): Don't define.
+ * elf32-i386.c (elf_backend_plt_header_size): Don't define.
+ * elf32-mips.c (elf_backend_plt_header_size): Don't define.
+ * elf32-ppc.c (elf_backend_plt_header_size): Don't define.
+ * elf32-s390.c (elf_backend_plt_header_size): Don't define.
+ * elf32-sh.c (elf_backend_plt_header_size): Don't define.
+ * elf32-sparc.c (elf_backend_plt_header_size): Don't define.
+ * elf64-alpha.c (elf_backend_plt_header_size): Don't define.
+ * elf64-hppa.c (elf_backend_plt_header_size): Don't define.
+ * elf64-mips.c (elf_backend_plt_header_size): Don't define.
+ * elf64-ppc.c (elf_backend_plt_header_size): Don't define.
+ * elf64-s390.c (elf_backend_plt_header_size): Don't define.
+ * elf64-sh64.c (elf_backend_plt_header_size): Don't define.
+ * elf64-sparc.c (elf_backend_plt_header_size): Don't define.
+ * elf64-x86-64.c (elf_backend_plt_header_size): Don't define.
+ * elfn32-mips.c (elf_backend_plt_header_size): Don't define.
+ * elfxx-ia64.c (elf_backend_plt_header_size): Don't define.
+ * elfxx-target.h (elf_backend_plt_header_size): Don't define
+ or include in target initializer.
+
+2003-11-03 Andrew Cagney <cagney@redhat.com>
+
+ * section.c (bfd_set_section_contents): Make the "location" buffer
+ constant.
+ * bfd-in2.h: Re-generate.
+
+2003-10-30 Andrew Cagney <cagney@redhat.com>
+
+ * syms.c: Replace "struct symbol_cache_entry" with "struct
+ bfd_symbol".
+ * vms.h, targets.c, section.c, reloc.c, peicode.h: Ditto.
+ * mipsbsd.c, elf.c, linker.c, elf-bfd.h, ecoff.c: Ditto.
+ * cpu-z8k.c, cpu-ns32k.c, cpu-h8500.c, bfd.c, bfd-in.h: Ditto.
+ * bfd-in2.h: Re-generate.
+
+2003-10-30 Jakub Jelinek <jakub@redhat.com>
+
+ * elfxx-ia64.c: Include objalloc.h, hashtab.h.
+ (struct elfNN_ia64_local_hash_entry): Remove root. Add id and r_sym
+ fields.
+ (struct elfNN_ia64_local_hash_table): Remove.
+ (struct elfNN_ia64_link_hash_table): Change loc_hash_table's type
+ to htab_t. Add loc_hash_memory field.
+ (elfNN_ia64_local_hash_table_init, elfNN_ia64_new_loc_hash_entry):
+ Removed.
+ (elfNN_ia64_local_htab_hash, elfNN_ia64_local_htab_eq): New
+ functions.
+ (elfNN_ia64_hash_table_create): Use hashtab.h hashtable for
+ loc_hash_table. Initialize loc_hash_memory.
+ (elfNN_ia64_hash_table_free): New function.
+ (elfNN_ia64_local_hash_lookup): Remove.
+ (elfNN_ia64_local_dyn_sym_thunk): Change into htab_traverse
+ callback.
+ (elfNN_ia64_dyn_sym_traverse): Use htab_traverse.
+ (get_local_sym_hash): Use hashtab.h hashtable for loc_hash_table.
+ (bfd_elfNN_bfd_link_hash_table_free): Define.
+
+2003-10-30 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.c (_bfd_elf_link_record_dynamic_symbol): Modify versioned
+ symbol string in place.
+
+2003-10-30 Jim Blandy <jimb@redhat.com>
+
+ * cpu-rs6000.c (rs6000_compatible): Check the correct arch_info
+ object's mach field: all PowerPC machines are supersets of the
+ original rs6000, but not later rs6000 machines.
+
+2003-10-30 Alan Modra <amodra@bigpond.net.au>
+
+ * dwarf2.c (struct attribute): Delete "unsnd", "snd" and "addr".
+ Add "val" and "sval" fields.
+ (DW_STRING, DW_UNSND, DW_BLOCK, DW_SND, DW_ADDR): Delete.
+ (read_attribute_value): Expand and adjust DW_* occurrences.
+ (scan_unit_for_functions, parse_comp_unit): Likewise.
+
+2003-10-30 Phil Edwards <phil@codesourcery.com>
+
+ * config.bfd (arm-*-vxworks): Remove separate stanza; merge with
+ other common ELF triples.
+ (i[3-7]86-*-vxworks): Change to ELF format.
+ (mips*-*-windiss): New triple, add to common MIPS/ELF stanza.
+ (sh-*-vxworks): New stanza.
+
+2003-10-30 Lars Knoll <lars@trolltech.com>
+ Michael Matz <matz@suse.de>
+ Jakub Jelinek <jakub@redhat.com>
+ Alan Modra <amodra@bigpond.net.au>
+
+ * merge.c (struct sec_merge_sec_info): Update comment.
+ (struct sec_merge_hash_entry): Remove entsize.
+ (sec_merge_hash_lookup): Only adjust alignment when creating.
+ (sec_merge_emit): Remove register keyword.
+ (cmplengthentry, last4_eq, last_eq): Delete.
+ (strrevcmp, strrevcmp_align, is_suffix): New.
+ (merge_strings): Use them to implement fast suffix merging.
+ * elf-strtab.c (struct elf_strtab_hash_entry): Update comments.
+ Make "len" signed.
+ (_bfd_elf_strtab_add): Lose on >2G strings.
+ (_bfd_elf_strtab_emit): Don't emit strings with len < 0.
+ (cmplengthentry, last4_eq): Delete.
+ (strrevcmp, is_suffix): New.
+ (_bfd_elf_strtab_finalize): Rework to implement fast suffix merging.
+
+2003-10-29 Daniel Jacobowitz <drow@mvista.com>
+
+ * elf32-arm.h (elf32_arm_final_link_relocate): Move check for
+ SEC_ALLOC.
+
+2003-10-29 Philip Blundell <philb@gnu.org>
+
+ * elf32-arm.h (elf32_arm_plt0_entry, elf32_arm_plt_entry): New
+ code sequence.
+ (PLT_HEADER_SIZE): New.
+ (struct elf32_arm_pcrel_relocs_copied): Rename to ...
+ (struct elf32_arm_relocs_copied): ... this. Count both
+ pcrel and non-pcrel relocs. All uses updated.
+ (struct elf32_arm_link_hash_table): Add pointers to dynamic linker
+ sections and symbol/section mapping cache.
+ (create_got_section): New.
+ (elf32_arm_create_dynamic_sections): New.
+ (elf_backend_create_dynamic_sections): Use it.
+ (elf32_arm_final_link_relocate): Support garbage collection of relocs.
+ (elf32_arm_check_relocs): Likewise.
+ (elf32_arm_adjust_dynamic_symbol): Likewise.
+ (elf32_arm_copy_indirect_symbol): New.
+ (elf32_arm_link_hash_table_create): Initialise new fields.
+ (elf32_arm_gc_sweep_hook): Implement.
+ (elf32_arm_discard_copies): Delete.
+ (elf32_arm_finish_dynamic_symbol): Use new PLT code.
+ (elf32_arm_finish_dynamic_sections): Likewise.
+ (elf_backend_can_refcount): Define.
+ (elf_backend_copy_indirect_symbol): Likewise.
+ (elf_backend_plt_header_size): Set to PLT_HEADER_SIZE.
+
+2003-10-29 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (elf_backend_grok_prstatus): Define.
+ (elf_backend_grok_psinfo): Define.
+ (ppc64_elf_grok_prstatus, ppc64_elf_grok_psinfo): New functions.
+
+ * elf.c (_bfd_elfcore_make_pseudosection): Allow multiple
+ sections with the same name.
+ (elfcore_grok_lwpstatus): Likewise.
+ (elfcore_grok_win32pstatus): Likewise.
+ (elfcore_grok_note): Likewise.
+ (elfcore_grok_nto_status): Likewise.
+ (elfcore_grok_nto_gregs): Likewise.
+
+2003-10-27 Daniel Jacobowitz <drow@mvista.com>
+
+ * elf32-arm.h (elf32_arm_merge_private_bfd_data): Never skip dynamic
+ objects.
+
+2003-10-14 Richard Sandiford <rsandifo@redhat.com>
+
+ * elfxx-mips.c (mips_elf_create_got_section): Initialize global_gotno.
+
+2003-10-24 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Look up
+ hash table for real symbols.
+
+2003-10-23 Michael Snyder <msnyder@redhat.com>
+
+ * section.c (asection): Fix typo in comment.
+
+2003-10-23 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (get_tls_mask): Add toc_symndx param, save toc
+ reloc symbol index to it. Don't allow gd syms in shared libs
+ to be optimized.
+ (ppc64_elf_tls_optimize): Adjust get_tls_mask call.
+ (ppc64_elf_size_stubs): Likewise.
+ (ppc64_elf_relocate_section): Check that tls relocs are only used
+ with tls syms, and similarly for non-tls. Correct symbol used
+ when optimizing toc tls code.
+
+2003-10-22 Nick Clifton <nickc@redhat.com>
+
+ * peicode.h (coff_swap_scnhdr_in): Only remove padding when
+ processing an executable.
+
+2003-10-22 Jakub Jelinek <jakub@redhat.com>
+
+ * elflink.c (_bfd_elf_export_symbol): Adjust for globals and locals
+ field changes.
+ (_bfd_elf_link_assign_sym_version): Likewise.
+ * elflink.h (size_dynamic_sections): Likewise.
+
+2003-10-21 Alexandre Oliva <aoliva@redhat.com>,
+ Michael Snyder <msnyder@redhat.com>
+
+ * archures.c (bfd_mach_sh4a, bfd_mach_sh4al_dsp, bfd_mach_sh4_nofpu,
+ bfd_mach_sh4a_nofpu): New machine types.
+ * bfd-in2.h: Rebuilt.
+ * cpu-sh.c (compatible): Remove unused function.
+ (SH4A_NEXT, SH4AL_DSP_NEXT, SH4_NOFPU_NEXT, SH4A_NOFPU_NEXT): New.
+ (arch_info_struct): Add sh4a, sh4al_dsp, sh4-nofpu and sh4a-nofpu.
+ * elf32-sh.c (sh_elf_set_mach_from_flags): Handle them.
+
+2003-10-21 Wouter van Heyst <wouter@vidicode.nl>
+
+ * elf32-arm.h (elf32_arm_merge_private_bfd_data): Correct text
+ describing mismatched formats involving the Maverick FP type.
+
+2003-10-21 Anil Paranjpe <anilp1@KPITCummins.com>
+
+ * binary.c (binary_object_p): Pass machine flag along with
+ architecture.
+
+2003-10-21 Thorsten Brehm <brehm@gmx.net>
+
+ * archures.c (bfd_default_scan): Add support for mcf528x.
+ * ieee.c (ieee_write_processor): Likewise.
+
+2003-10-21 Peter Barada <pbarada@mail.wm.sps.mot.com>
+ Bernardo Innocenti <bernie@develer.com>
+
+ * archures.c: Add MCF528x (MCFv4) support.
+ * bfd/cpu-m68k.c (arch_info_struct): Likewise.
+ * bfd-in2.h: Regenerate.
+
+2003-10-20 Andrew Cagney <cagney@redhat.com>
+
+ * targets.c: Replace "struct sec" with "struct bfd_section"
+ * syms.c, sparclynx.c, section.c, opncls.c: Ditto.
+ * libcoff-in.h, libbfd-in.h, elfxx-target.h: Ditto.
+ * elf.c, coffgen.c, bfd.c, bfd-in.h, aoutf1.h: Ditto.
+ * aout-tic30.c, aout-target.h:
+ * bfd-in2.h, libcoff.h, libbfd.h: Regenerate.
+
+2003-10-18 Hans-Peter Nilsson <hp@bitrange.com>
+
+ Support linker relaxation of new R_MMIX_PUSHJ_STUBBABLE relocs.
+ * elf64-mmix.c (MAX_PUSHJ_STUB_SIZE): New macro.
+ (struct _mmix_elf_section_data): New member pjs.
+ (mmix_set_relaxable_size, mmix_elf_get_section_contents): New
+ functions.
+ (elf_mmix_howto_table): New entry for R_MMIX_PUSHJ_STUBBABLE.
+ (mmix_reloc_map): Ditto.
+ (mmix_elf_relocate_section): Handle R_MMIX_PUSHJ_STUBBABLE.
+ (mmix_final_link_relocate, mmix_elf_check_common_relocs): Ditto.
+ (mmix_elf_perform_relocation): Ditto. Don't mark parameter addr
+ unused.
+ (mmix_elf_check_relocs): Move early return to after
+ mmix_elf_check_common_relocs call.
+ (mmix_elf_symbol_processing): Fix cut-and-pasto in head comment.
+ (_bfd_mmix_before_linker_allocation): Rename from
+ _bfd_mmix_prepare_linker_allocated_gregs. All referers changed.
+ Arrange to set the initial relaxable size of sections.
+ (_bfd_mmix_after_linker_allocation): Rename from
+ _bfd_mmix_finalize_linker_allocated_gregs.
+ (mmix_elf_relax_section): Relax a R_MMIX_PUSHJ_STUBBABLE reloc.
+ (bfd_elf64_get_section_contents): Define.
+ * reloc.c: Add ENUMX for BFD_RELOC_MMIX_PUSHJ_STUBBABLE.
+ * libbfd.h, bfd-in2.h: Regenerate.
+
+ * reloc.c (bfd_generic_relax_section): Default-set
+ section->_cooked_size here.
+ (bfd_generic_get_relocated_section_contents): Don't set it here.
+ Explain why.
+
+2003-10-17 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
+
+ * elf32-hppa.c (elf32_hppa_relocate_section): Skip relocation if
+ output section has been discarded.
+
+2003-10-17 Shrinivas Atre <shrinivasa@KPITCummins.com>
+
+ * coff-h8300.c (funcvec_hash_newfunc): Handle normal mode.
+ (h8300_reloc16_extra_cases): Likewise.
+ (h8300_bfd_link_add_symbols): Likewise.
+
+2003-10-17 Dhananjay Deshpande <dhananjayd@kpitcummins.com>
+
+ * cpu-h8300.c (h8300sxn_info_struct): Correct address size.
+ (h8300sn_info_struct): Likewise.
+ (h8300hn_info_struct): Likewise.
+
+2003-10-16 Pavel Roskin <proski@gnu.org>
+
+ * peXXigen.c (_bfd_XXi_swap_aouthdr_out): Don't calculate image size
+ for sections which lack size info.
+
+2003-10-17 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * configure.host: Add __USE_MINGW_FSEEK to HDEFINES for
+ mingw32.
+
+2003-10-16 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Also warn
+ undefined patterns with '*'.
+
+2003-10-16 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't
+ use the last CIE from a different section.
+ (_bfd_elf_write_section_eh_frame): Don't pad beyond the raw
+ size of the output section.
+
+2003-10-07 Roland McGrath <roland@redhat.com>
+
+ * elf.c (_bfd_elf_make_section_from_phdr): Set alignment_power of
+ new section from p_align header field.
+
+2003-10-16 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elf32-xtensa.c (xtensa_read_table_entries): The external size
+ of entry is 8 bytes.
+
+2003-10-15 Andrew Cagney <cagney@redhat.com>
+
+ * targets.c (BFD_JUMP_TABLE_SYMBOLS): Replace NAME##_get_symtab
+ with NAME##_canonicalize_symtab.
+ * libcoff-in.h (coff_canonicalize_symtab): Update.
+ * xsym.h (bfd_sym_canonicalize_symtab): Update.
+ * elf-bfd.h (_bfd_elf_canonicalize_symtab): Update.
+ * coffgen.c (coff_canonicalize_symtab): Update.
+ * libbfd-in.h (_bfd_nosymbols_canonicalize_symtab): Update.
+ * libnlm.h (nlmNAME(canonicalize_symtab)): Update.
+ * ieee.c (ieee_vec): Update comment.
+ * libecoff.h (_bfd_ecoff_canonicalize_symtab): Update.
+ * mmo.c (mmo_canonicalize_symtab): Update.
+ * nlm-target.h (nlm_canonicalize_symtab): Update.
+ * nlmcode.h (nlm_canonicalize_symtab): Update.
+ * i386msdos.c (msdos_canonicalize_symtab): Update.
+ * hp300hpux.c (MY (canonicalize_symtab)): Update.
+ * oasys.c (oasys_canonicalize_symtab): Update.
+ * som.c (som_canonicalize_symtab): Update.
+ * pef.c (bfd_pef_canonicalize_symtab): Update.
+ * nlmcode.h (nlm_canonicalize_symtab): Update.
+ * xsym.c (bfd_sym_canonicalize_symtab): Update.
+ * vms.c (vms_canonicalize_symtab): Update.
+ * versados.c (versados_canonicalize_symtab): Update.
+ * mach-o.c (bfd_mach_o_canonicalize_symtab): Update.
+ * ieee.c (ieee_canonicalize_symtab): Update.
+ * pdp11.c (NAME(aout,canonicalize_symtab)): Update.
+ * reloc.c: Update comment.
+ * libaout.h (NAME(aout,canonicalize_symtab)): Update.
+ * coff64-rs6000.c (aix5coff64_vec): Update.
+ * coff64-rs6000.c (bfd_xcoff_aix5_backend_data): Update.
+ * coff-rs6000.c (rs6000coff_vec, pmac_xcoff_vec): Update.
+ * aoutx.h (NAME(aout,canonicalize_symtab)): Update.
+ * elfxx-target.h (bfd_elfNN_canonicalize_symtab): Update.
+ * hp300hpux.c (MY_canonicalize_symtab): Update.
+ * ecoff.c (_bfd_ecoff_canonicalize_symtab): Update.
+ * aout-tic30.c (MY_canonicalize_symtab): Update.
+ * aout-target.h (MY_canonicalize_symtab): Update.
+ * ppcboot.c (ppcboot_canonicalize_symtab): Update.
+ * elf.c (_bfd_elf_canonicalize_symtab): Update.
+ * elfcode.h (elf_canonicalize_symtab): Update.
+ * ihex.c (ihex_canonicalize_symtab): Update.
+ * tekhex.c (tekhex_canonicalize_symtab): Update.
+ * binary.c (binary_canonicalize_symtab): Update.
+ * srec.c (srec_canonicalize_symtab): Update.
+
+2003-10-15 Kazu Hirata <kazu@cs.umass.edu>
+
+ * elf32-h8300.c (elf_reloc_map): Fix a comment typo.
+
+2003-10-15 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * elf32-sh.c (sh_elf_relocate_section): Handle R_SH_IMM_*_PCREL
+ relocations.
+ (sh_elf_check_relocs): Likewise.
+
+ * elf32-sh64.c (elf_backend_merge_symbol_attribute): Define.
+ (sh64_elf_merge_symbol_attribute): New.
+ * elf64-sh64.c (elf_backend_merge_symbol_attribute): Define.
+ (sh64_elf64_merge_symbol_attribute): New.
+
+2003-10-14 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * elf-bfd.h (struct elf_backend_data): New function pointer member
+ elf_backend_merge_symbol_attribute.
+ * elflink.h (elf_link_add_object_symbols): Adjust call to
+ elf_backend_merge_symbol_attribute if the backend defined it.
+ * elfxx-target.h (elf_backend_merge_symbol_attribute): New macro.
+ (elfNN_bed): Add that to the initializer.
+
+2003-10-14 Bob Wilson <bob.wilson@acm.org>
+
+ * elf32-xtensa.c (get_is_linkonce_section): Delete.
+ (xtensa_is_property_section, xtensa_is_littable_section): Use
+ XTENSA_INSN_SEC_NAME and XTENSA_LIT_SEC_NAME macros. Do not recognize
+ linkonce sections containing ".xt.insn" and ".xt.lit" substrings.
+ (xtensa_get_property_section_name): Check section name instead of
+ calling get_is_linkonce_section. Remove unused bfd parameter. Use
+ XTENSA_INSN_SEC_NAME and XTENSA_LIT_SEC_NAME macros. Never generate
+ linkonce section names by appending ".xt.insn" or ".xt.lit".
+ (xtensa_read_table_entries): Remove bfd argument in call to
+ xtensa_get_property_section_name. Free section name when done.
+ (elf_xtensa_combine_prop_entries): Free leaking table.
+
+2003-10-13 Richard Sandiford <rsandifo@redht.com>
+
+ * elfxx-mips.c (_bfd_mips_elf_size_dynamic_sections): Don't add
+ DT_MIPS_LIBLIST or DT_MIPS_CONFLICT entries.
+ (_bfd_mips_elf_finish_dynamic_symbol): Don't handle them. Don't
+ handle DT_MIPS_MSYM. Set DT_RELSZ based on the number of relocations
+ that were needed.
+ (_bfd_mips_elf_modify_segment_map): Fix placement of PT_MIPS_OPTIONS.
+ (_bfd_mips_elf_merge_private_bfd_data): Ignore EF_MIPS_UCODE.
+
+2003-10-13 H.J. Lu <hongjiu.lu@intel.com>
+
+ * bfd-in.h (bfd_elf32_ia64_after_parse): New prototype.
+ (bfd_elf64_ia64_after_parse): Likewise.
+ * bfd-in2.h: Regenerated.
+
+ * elfxx-ia64.c (oor_ip): New.
+ (oor_branch_size): Likewise.
+ (bfd_elfNN_ia64_after_parse): Likewise.
+ (elfNN_ia64_relax_section): Use oor_ip if oor_branch_size
+ equals sizeof (oor_ip).
+
+2003-10-12 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * elf64-sh64.c (sh_elf64_relocate_section): Tidy up for the
+ renumbering of some relocation numbers.
+
+2003-10-11 Alan Modra <amodra@bigpond.net.au>
+
+ * coff-sh.c: Move definition of MAP and guard more code with
+ COFF_IMAGE_WITH_PE.
+
+ * section.c (bfd_get_section_size_before_reloc): Ignore reloc_done.
+ * bfd-in2.h: Regenerate.
+
+2003-10-10 H.J. Lu <hongjiu.lu@intel.com>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * doc/Makefile.in: Likewise.
+
+2003-10-09 H.J. Lu <hongjiu.lu@intel.com>
+
+ * cofflink.c: Include "safe-ctype.h".
+ (coff_link_add_symbols): Use ISDIGIT instead of isdigit.
+
+2003-10-08 Dave Brolley <brolley@redhat.com>
+ On behalf of Michael Snyder <msnyder@redhat.com>
+
+ * archures.c: Add FRV fr550 machine.
+ * cpu-frv.c: Ditto.
+ * elf32-frv.c: Ditto.
+ * bfd-in2.h: Regenerate.
+
+2003-10-08 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elfxx-mips.c (STUB_MOVE,STUB_LI16): Fix stub code
+ for non-SGI N64 ABI. Improve code consitency.
+
+2003-10-07 Alexandre Oliva <aoliva@redhat.com>
+
+ * elf32-frv.c (elf32_frv_howto_table): Set R_FRV_LABEL16's
+ rightshift to 2.
+
+2003-10-07 Nathan Sidwell <nathan@codesourcery.com>
+
+ * libbfd-in.h (_bfd_link_section_stabs): Add string offset
+ parameter.
+ * cofflink.c (coff_link_add_symbols): Deal with split stab
+ sections.
+ * elflink.h (elf_link_add_object_symbols): Deal with split stab
+ sections.
+ * stabs.c (_bfd_link_section_stabs): Add string offset parameter.
+ * libbfd.h: Regenerated.
+
+ * coffcode.h (coff_set_alignment_hook): With PE_COFF reloc
+ overflow, set reloc start position to after the count
+ reloc. Subtract one from num relocs. Give error on 0xffff relocs
+ and no overflow.
+ * cofflink.c (_bfd_coff_final_link): Deal with PE_COFF reloc
+ overflow.
+ * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Do overflow if >=
+ 0xffff.
+
+2003-10-06 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elf-eh-frame.c (_bfd_elf_write_section_eh_frame): Pad the
+ last CIE/FDE if needed.
+
+2003-10-06 Nick Clifton <nickc@redhat.com>
+
+ * targets.c (_bfd_target_vector): Include bfd_elf64_sparc_vec if
+ BFD64 is enabled.
+
+2003-10-06 Matt Thomas <matt@3am-software.com>
+
+ * config.bfd: Move the hppa*-*-netbsd* case to the hppa*-*-linux* case.
+
+2003-10-06 Robert Millan <robertmh@gnu.org>
+
+ * configure.in: Match GNU/KNetBSD with new knetbsd*-gnu triplet.
+ * config.bfd: Likewise.
+ * configure: Regenerate.
+
+2003-10-04 Christian Groessler <chris@groessler.org>
+
+ * coff-z8k.c (extra_case): Fix displacement length check for R_JR
+ and R_CALLR.
+
+2003-10-04 Stephane Carrez <stcarrez@nerim.fr>
+
+ * elf32-m68hc1x.c: Update to ISO C90; replace PTR with void*.
+ * elf32-m68hc11.c: Likewise.
+ * elf32-m68hc12.c: Likewise.
+ * elf32-m68hc1x.h: Likewise.
+
+2003-10-04 Stephane Carrez <stcarrez@nerim.fr>
+
+ * elf32-m68hc1x.c (_bfd_m68hc11_elf_merge_private_bfd_data): Fix merge
+ of flags between HC12 and HCS12.
+
+2003-10-04 Bryce McKinlay <bryce@mckinlay.net.nz>
+
+ * merge.c (_bfd_merge_sections): Set SEC_EXCLUDE flag on sections
+ which become empty after merging.
+
+2003-09-30 Jakub Jelinek <jakub@redhat.com>
+
+ * elfxx-ia64.c (ia64_howto_table): Fix size of R_IA64_TPREL64[LM]SB,
+ R_IA64_DTPREL{32,64}[LM]SB and R_IA64_DTPMOD64[LM]SB.
+
+2003-09-30 Chris Demetriou <cgd@broadcom.com>
+
+ * archures.c (bfd_mach_mipsisa64r2): New define.
+ * bfd-in2.h: Regenerate.
+ * aoutx.h (NAME(aout,machine_type)): Handle bfd_mach_mipsisa64r2.
+ * cpu-mips.c (I_mipsisa64r2): New enum value.
+ (arch_info_struct): Add entry for I_mipsisa64r2.
+ * elfxx-mips.c (_bfd_elf_mips_mach)
+ (_bfd_mips_elf_print_private_bfd_data): Handle E_MIPS_ARCH_64R2.
+ (mips_set_isa_flags): Add bfd_mach_mipsisa64r2 case.
+ (mips_mach_extensions): Add entry for bfd_mach_mipsisa64r2.
+
+2003-09-29 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elfxx-ia64.c (elfNN_hpux_backend_symbol_processing): New.
+ Handle SHN_IA_64_ANSI_COMMON.
+ (elf_backend_section_from_bfd_section): Defined.
+
+2003-09-26 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elflink.c (elf_link_read_relocs_from_section): Add an argument
+ of a pointer to section. Check bad symbol index.
+ (_bfd_elf_link_read_relocs): Modify calls to
+ elf_link_read_relocs_from_section.
+
+2003-09-23 DJ Delorie <dj@redhat.com>
+
+ * elf32-sh.c (sh_elf_howto_table): R_SH_SWITCH8,
+ R_SH_GNU_VTINHERIT, R_SH_GNU_VTENTRY,
+ R_SH_LOOP_START,R_SH_LOOP_END moved to "reserved" spaces,
+ R_SH_DIR16, R_SH_DIR8, R_SH_DIR8UL, R_SH_DIR8UW, R_SH_DIR8U,
+ R_SH_DIR8SW, R_SH_DIR8S, R_SH_DIR4UL, R_SH_DIR4UW, R_SH_DIR4U,
+ R_SH_PSHA, R_SH_PSHL added.
+ (sh_reloc_map): Add R_SH_DIR16 and R_SH_DIR8.
+ (sh_elf_relocate_section): Support new relocs.
+
+2003-09-23 Bob Wilson <bob.wilson@acm.org>
+
+ * elf32-xtensa.c (elf_xtensa_relocate_section): Fix typo that clobbered
+ dynamic relocation offsets.
+
+2003-09-23 Alan Modra <amodra@bigpond.net.au>
+
+ * simple.c (bfd_simple_get_relocated_section_contents): Free the
+ hash table using _bfd_generic_link_hash_table_free.
+
+2003-09-23 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h (struct bfd_elf_special_section): Remove "suffix". Change
+ type of prefix_length and suffix_length to int. Rename "attributes"
+ to "attr". Comment.
+ (_bfd_elf_get_sec_type_attr): Update prototype.
+ * elf.c (get_special_section): Rewrite.
+ (_bfd_elf_get_sec_type_attr): Return struct rather than passing in
+ attr and type pointers.
+ (_bfd_elf_new_section_hook): Adjust for above.
+ (special_sections): Merge suffix with prefix. Set
+ prefix_length for all entries. Set suffix_length appropriately.
+ * elf32-m32r.c (m32r_elf_special_sections): Likewise.
+ * elf32-m68hc11.c (elf32_m68hc11_special_sections): Likewise.
+ * elf32-m68hc12.c (elf32_m68hc12_special_sections): Likewise.
+ * elf32-mcore.c (mcore_elf_special_sections): Likewise.
+ * elf32-sh64.c (sh64_elf_special_sections): Likewise.
+ * elf32-v850.c (v850_elf_special_sections): Likewise.
+ * elf32-xtensa.c (elf_xtensa_special_sections): Likewise.
+ * elf64-alpha.c (elf64_alpha_special_sections): Likewise.
+ * elf64-hppa.c (elf64_hppa_special_sections): Likewise.
+ * elf64-ppc.c (ppc64_elf_special_sections): Likewise.
+ * elf64-sh64.c (sh64_elf64_special_sections): Likewise.
+ * elfxx-ia64.c (elfNN_ia64_special_sections): Likewise.
+ * elfxx-mips.c (_bfd_mips_elf_special_sections): Likewise.
+ * elf32-ppc.c (ppc_elf_special_sections): Likewise. Fix .plt flags.
+
+2003-09-21 Daniel Jacobowitz <drow@mvista.com>
+
+ * elf64-alpha.c (elf64_alpha_create_got_section): Initialize
+ ->got if the section already exists.
+
+2003-09-19 Nathan Sidwell <nathan@codesourcery.com>
+
+ * dwarf2.c (decode_line_info): Cope with an initially empty
+ filename table.
+
+2003-09-18 H.J. Lu <hongjiu.lu@intel.com>
+
+ * acinclude.m4: Include ../config/accross.m4.
+ * aclocal.m4: Regenerated.
+
+ * configure.host (HOST_64BIT_TYPE): Remove if it is set to long
+ or long long.
+ (HOST_U_64BIT_TYPE): Remove if it is set to unsigned long long.
+ (host64): Remove if HOST_64BIT_TYPE is set to long.
+
+ * configure.in (HOST_64BIT_TYPE): Set according to the size of
+ long and long long.
+ (HOST_U_64BIT_TYPE): Likewise.
+ (host64): Likewise.
+ * configure: Regenerated.
+
+2003-09-19 Alan Modra <amodra@bigpond.net.au>
+
+ * elf.c (elfcore_write_note): Don't use sizeof(Elf_External_note)
+ since some ABIs round up the size of the struct.
+
+2003-09-18 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elflink.c (_bfd_elf_merge_symbol): Allow type change if
+ the old symbol is undefined and the new symbol is defined.
+
+2003-09-18 Andreas Schwab <schwab@suse.de>
+
+ * simple.c (bfd_simple_get_relocated_section_contents): Use
+ _bfd_generic_link_hash_table_create instead of
+ bfd_link_hash_table_create.
+
+2003-09-10 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elfxx-ia64.c (elfNN_ia64_special_sections): Mark all sections
+ started with ".sbss" or "".sdata" as SHF_IA_64_SHORT.
+
+2003-09-10 John David Anglin <dave.anglin@nrc-cnrc.nrc.ca>
+ Randolph Chung <randolph@tausq.org>
+
+ * elf32-hppa.c (struct elf32_hppa_link_hash_entry,
+ hppa_link_hash_newfunc, hppa_build_one_stub,
+ elf32_hppa_adjust_dynamic_symbol, mark_PIC_calls, allocate_plt_static,
+ allocate_dynrelocs, elf32_hppa_size_dynamic_sections,
+ elf32_hppa_finish_dynamic_symbol): Remove pic_call field and all code
+ for generating import stubs for calls to statically linked PIC
+ functions.
+ (hppa_type_of_stub): Don't generate an import stub for calls to
+ statically linked pic functions. Generate import stubs for calls
+ in a shared object, to functions not in a regular file, and to
+ defined weak functions. Add new argument INFO.
+ (hppa_build_one_stub): Don't undef ADDIL_DP.
+ (elf32_hppa_check_relocs): Don't set SEC_HAS_GOT_REF flag.
+ (elf32_hppa_size_stubs): Pass info to hppa_type_of_stub.
+ (final_link_relocate): Change all DLTIND relocs to DPREL relocs in a
+ non-shared link. Convert instructions that use the the linkage table
+ pointer, or a facsimile thereof, to use the global data pointer when
+ the reloc has been changed.
+
+2003-09-08 Joel Brobecker <brobecker@gnat.com>
+
+ * archures.c: Add new machine names for hppa.
+ * bfd-in2.h: Regenerate.
+ * cpu-hppa.c: Use the new machine names.
+
+2003-09-06 Stephane Carrez <stcarrez@nerim.fr>
+
+ * elf32-m68hc1x.h (struct m68hc11_elf_link_hash_table): Remove
+ all_local_syms member.
+ * elf32-m68hc1x.c (elf32_m68hc11_size_stubs): Use bfd_elf_get_elf_syms
+ to get the local symbols.
+
+2003-09-06 Stephane Carrez <stcarrez@nerim.fr>
+
+ * elf32-m68hc12.c (elf32_m68hc12_special_sections): New for hc11.
+ (elf_backend_special_sections): Define.a
+
+ PR savannah/4950:
+ * elf32-m68hc11.c (elf32_m68hc11_special_sections): The .vectors
+ section is read-only.
+
+2003-09-04 Nick Clifton <nickc@redhat.com>
+
+ * archures.c (bfd_mach_v850e1): Define.
+ * bfd-in2.h: Regenerate.
+ * cpu-v850.h (scan): Accept bfd_mach_v850e1.
+ (arch_info_struct): Include an entry for bfd_mach_v850e1.
+ * elf32-v850.c (v850_elf_object_p): Accept E_V850E1_ARCH flag.
+ (v850_elf_final_write_processing): Accept bfd_mach_v850e1.
+ (v850_elf_print_private_bfd_data): Interpret E_V850E1_ARCH flag.
+ (v850_elf_merge_private_bfd_data): Allow v850e1 binaries to be
+ linked with v850e binaries. Mark the output as v850e.
+
+2003-09-03 Nick Clifton <nickc@redhat.com>
+
+ * cofflink.c (_bfd_coff_link_input_bfd): Do not skip section
+ symbols that are used in relocs.
+
+2003-08-30 Robert Millan <robertmh@gnu.org>
+
+ * configure.in: Match GNU/KFreeBSD with new kfreebsd*-gnu triplet.
+ * config.bfd: Likewise.
+ * configure: Regenerate.
+
+2003-08-31 Christian Groessler <chris@groessler.org>
+
+ * elf32-i860.c (i860_howto_pc26_reloc): Finish relocation here
+ instead of returning bfd_reloc_continue.
+
+2003-08-31 Andreas Jaeger <aj@suse.de>
+
+ * merge.c: Update to ISO C90.
+
+2003-08-27 Ian Lance Taylor <ian@airs.com>
+
+ * configure.in: Check for strtoull.
+ * bfd.c (bfd_scan_vma): Use strtoull when available.
+ * configure, config.in: Regenerate.
+
+ * configure.in: Define and substitute BFD_HOST_LONG_LONG.
+ * bfd-in.h: Define BFD_HOST_LONG_LONG. Test it rather than
+ __GNUC__ when deciding whether to use long long for
+ BFD_HOST_64_BIT.
+ * configure, Makefile.in, doc/Makefile.in, bfd-in2.h: Regenerate.
+
+2003-08-27 Christian Groessler <chris@groessler.org>
+
+ * elf32-i860.c (i860_howto_pc26_reloc, i860_howto_pc16_reloc,
+ i860_howto_splitn_reloc, i860_howto_highadj_reloc): New
+ functions.
+ (elf32_i860_howto_table): Insert the new functions as
+ 'special_function's in the proper reloc type entries.
+
+2003-08-27 Richard Sandiford <rsandifo@redhat.com>
+
+ * elf32-frv.c (elf32_frv_relocate_section): Use
+ _bfd_elf_rela_local_sym.
+
+2003-08-26 Michael Snyder <msnyder@redhat.com>
+
+ * cpu-frv.c: Remove unused enum.
+
+2003-08-25 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * reloc.c: Fix documentation for MIPS ELF relocations.
+ libbfd.h: Regenerate.
+ bfd-in2.h: Regenerate.
+
+2003-08-24 Jason Eckhardt <jle@rice.edu>
+
+ * coff-i860.c (CALC_ADDEND): Define to be a no-op.
+
+2003-08-24 Jason Eckhardt <jle@rice.edu>
+
+ * elf32-i860.c (elf32_i860_relocate_pc16): Subtract 4 and
+ shift by 2 before storing the relocated value.
+
+2003-08-23 Jason Eckhardt <jle@rice.edu>
+
+ * coff-i860.c (coff_i860_reloc_nyi): New function.
+ (howto_table): Add entries for relocations PAIR, HIGHADJ, HIGH,
+ LOWn, SPLITn, and BRADDR.
+ (RTYPE2HOWTO): Check that the r_type is within the howto_table
+ before trying to access the entry.
+ (coff_i860_rtype_to_howto): Likewise.
+ (coff_i860_reloc_type_lookup): New function.
+ (i860_reloc_processing): New function.
+ (coff_bfd_reloc_type_lookup): Define macro.
+ (RELOC_PROCESSING): Define macro.
+ Minor formatting adjustments.
+
+2003-08-23 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h (elf_link_add_object_symbols): Don't crash on NULL owner.
+
+2003-08-22 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elfxx-ia64.c (elfNN_ia64_create_dynamic_sections): Align the
+ .got section at 8 bytes.
+
+2003-08-21 Nick Clifton <nickc@redhat.com>
+
+ * cofflink.c: Update to ISO C90 and tidy up formatting.
+
+2003-08-21 Randolph Chung <tausq@debian.org>
+
+ * elf32-hppa.c (elf32_hppa_object_p): For elf32-hppa-linux, objects
+ can have OSABI=Linux or OSABI=SysV. Check for both.
+ * elf64-hppa.c (elf64_hppa_object_p): Likewise.
+
+2003-08-21 Nick Clifton <nickc@redhat.com>
+
+ * po/sv.po: Updated Swedish translation.
+
+2003-08-20 Richard Sandiford <rsandifo@redhat.com>
+
+ * elf64-mips.c (elf_backend_copy_indirect_symbol): Define.
+
+2003-08-20 Nick Clifton <nickc@redhat.com>
+
+ * elf-bfd.h (RELOC_FOR_GLOBAL_SYMBOL): New macro used to
+ replace some duplicated code in most elfxx-xxxx.c files. This
+ version uses the new fields in bfd_link_info.
+
+ * elf-m10300.c (mn10300_elf_relocate_section): Use new macro.
+ * elf32-arm.h (elf32_arm_relocate_section): Likewise.
+ * elf32-cris.c (cris_elf_relocate_section): Likewise.
+ * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
+ * elf32-i386.c (elf_i386_relocate_section): Likewise.
+ * elf32-ip2k.c (ip2k_elf_relocate_section): Likewise.
+ * elf32-iq2000.c (iq2000_elf_relocate_section): Likewise.
+ * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
+ * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
+ * elf32-s390.c (elf_s390_relocate_section): Likewise.
+ * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
+ * elf32-vax.c (elf_vax_relocate_section): Likewise.
+ * elf32-xtensa.c (elf_xtensa_relocate_section): Likewise.
+ * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
+ * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
+ * elf64-s390.c (elf_s390_relocate_section): Likewise.
+ * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
+ * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
+ * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
+
+ * elf-hppa.h (elf_hppa_unmark_useless_dynamic_symbols,
+ elf_hppa_remark_useless_dynamic_symbols,
+ elf_hppa_relocate_section): Use the new fields in
+ bfd_link_info structure.
+ * elf32-sh.c (sh_elf_relocate_section): Likewise.
+ * elf64-alpha.c (elf64_alpha_check_relocs): Likewise.
+ * elf64-hppa.c (elf64_hppa_check_relocs): Likewise.
+ * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
+ * elfxx-ia64.c (elfNN_ia64_check_relocs): Likewise.
+ * elfxx-mips.c (mips_elf_calculate_relocation): Likewise.
+
+ * elflink.h (elf_link_output_extsym): Fix test for reporting
+ undefined symbols in shared libraries. Remove redundant test
+ of shlib_undefined when reporting references to forced local
+ symbols.
+
+2003-08-18 Andreas Schwab <schwab@suse.de>
+
+ * libpei.h (bfd_pe_executable_p): Also recognize efi-app
+ executables.
+
+2003-08-17 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * simple.c (bfd_simple_get_relocated_section_contents): Move
+ reloc_done hack to before first bfd_section_size call. Change all
+ returns to use new wrapper macro RETURN, restoring sec->reloc_done.
+
+2003-08-16 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c: Don't include elf/ppc.h.
+
+2003-08-14 Richard Sandiford <rsandifo@redhat.com>
+
+ * elfxx-mips.c (_bfd_mips_elf_modify_segment_map): Fix PT_DYNAMIC
+ code to work with 64-bit bfds.
+
+2003-08-14 Alan Modra <amodra@bigpond.net.au>
+
+ * dep-in.sed: Remove libintl.h.
+ * Makefile.am (SRC-POTFILES.in, BLD-POTFILES.in): Unset LC_COLLATE.
+ (POTFILES.in): Remove target.
+ * Makefile.in: Regenerate.
+
+2003-08-12 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_next_input_section): Update comment.
+ (ppc64_elf_relocate_section): For zero sym R_PPC64_TOC relocs,
+ use the function sym from the previous reloc.
+
+2003-08-11 Jakub Jelinek <jakub@redhat.com>
+
+ * elf32-i386.c (elf_i386_relocate_section): Make undefined symbols
+ fatal if -pie.
+ * elf32-s390.c (elf_s390_relocate_section): Likewise.
+ * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
+ * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
+ * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
+ * elf64-s390.c (elf_s390_relocate_section): Likewise.
+ * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
+ * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
+ * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
+ * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
+ (ppc_elf_relocate_section) <case R_PPC_RELAX32>: Issue fatal error
+ on undefined symbols if -pie.
+ * elf32-sh.c (sh_elf_relocate_section): Likewise.
+
+2003-08-11 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_relocate_section): Add special case for crt1.o
+ branch to __libc_start_main.
+
+2003-08-08 Dmitry Diky <diwil@mail.ru>
+
+ * archures.c: Add xW42 and xE42 parts. Sort MPU list according to
+ gcc order.
+ * cpu-msp430.c: Likewise.
+ * elf32-msp430.c: Likewise.
+ * bfd-in2.h: Regenerate.
+
+2003-08-07 Alan Modra <amodra@bigpond.net.au>
+
+ * elfxx-target.h: Remove PTR cast.
+ * targets.c (bfd_target): Make backend_data const void *.
+ * elf-bfd.h: Constify all occurrences of struct elf_backend_data.
+ * elf-m10300.c: Likewise.
+ * elf.c: Likewise.
+ * elf32-hppa.c: Likewise.
+ * elf32-i386.c: Likewise.
+ * elf32-m68hc1x.c: Likewise.
+ * elf32-ppc.c: Likewise.
+ * elf32-s390.c: Likewise.
+ * elf32-sh.c: Likewise.
+ * elf32-sh64.c: Likewise.
+ * elf32-sparc.c: Likewise.
+ * elf32-xtensa.c: Likewise.
+ * elf64-mips.c: Likewise.
+ * elf64-ppc.c: Likewise.
+ * elf64-s390.c: Likewise.
+ * elf64-sh64.c: Likewise.
+ * elf64-sparc.c: Likewise.
+ * elf64-x86-64.c: Likewise.
+ * elfcode.h: Likewise.
+ * elfcore.h: Likewise.
+ * elflink.c: Likewise.
+ * elflink.h: Likewise.
+ * elfxx-ia64.c: Likewise.
+ * elfxx-mips.c: Likewise.
+ * elfxx-mips.h: Likewise.
+ * elf.c (prep_headers): Remove useless check for null backend_data.
+ * bfd-in2.h: Regenerate.
+
+ * elf-bfd.h: Remove PARAMS macro. Replace PTR with void *.
+ (NAME): Use ## rather than CONCAT4 macro.
+ * elfcode.h: Remove one remaining PARAMS macro.
+ * elf-eh-frame.c: Convert to C90, remove unneeded casts and prototypes.
+ * elf-strtab.c: Likewise.
+ * elf-hppa.h: Likewise.
+ * elf32-hppa.h: Likewise.
+ * elf32-hppa.c: Likewise.
+ (elf32_hppa_add_symbol_hook): Delete.
+ (elf_backend_add_symbol_hook): Don't define.
+ * libhppa.h: Convert to C90. Replace INLINE with inline.
+
+2003-08-06 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc_stub_name): Tweak names for better readability.
+ (ppc64_elf_adjust_dynamic_symbol): Allow copy relocs against
+ function descriptors, but warn.
+ (ppc_build_one_stub): Remove a couple of vars. Move code creating
+ stub syms so that we can avoid a stub sym if we already have a
+ plt sym. Do not redefine an existing symbol.
+ (ppc64_elf_build_stubs): When --emit-stub-syms, print a symbol for
+ glink.
+
+2003-08-06 Nick Clifton <nickc@redhat.com>
+
+ * po/fr.po: Updated French translation.
+
+2003-08-06 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.c (_bfd_elf_create_dynamic_sections): Mark .dynbss with
+ SEC_LINKER_CREATED.
+
+2003-08-05 Daniel Jacobowitz <drow@mvista.com>
+
+ * elf32-arm.h (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
+ (elf32_arm_final_link_relocate, elf32_arm_relocate_section): Use it.
+
+2003-08-03 Jeff Muizelaar <muizelaar@rogers.com>
+
+ * coffcode.h (coff_slurp_line_table): Return with a warning
+ message if the line number table could not be read.
+
+2003-08-04 Nick Clifton <nickc@redhat.com>
+
+ * elflink.h (elf_link_add_object_symbols): Prepend "warning: "
+ to messages produced for .gnu.warning.SYMBOL sections.
+
+2003-08-04 Alan Modra <amodra@bigpond.net.au>
+
+ * elfcode.h: Convert to C90, remove unneeded casts and prototypes.
+ * elfcore.h: Likewise.
+ * elflink.c: Likewise.
+ * elflink.h: Likewise.
+ * elf.c (sym_is_global): Remove INLINE.
+ (align_file_position): Replace INLINE with inline.
+ * elfcode.h (elf_swap_dyn_in, elf_swap_dyn_out): Remove INLINE.
+ (elf_file_p): Replace INLINE with inline.
+
+2003-08-02 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * elf32-sh.c (sh_elf_check_relocs): Don't set DF_TEXTREL here.
+
+2003-08-01 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elfxx-ia64.c (get_got): Align the .got section at 8 bytes.
+
+2003-08-01 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elfxx-ia64.c (elfNN_ia64_finish_dynamic_symbol): Use
+ ElfNN_External_Rela instead of Elf64_External_Rela.
+
+2003-08-01 Nick Clifton <nickc@redhat.com>
+
+ * config.bfd: Add code to catch obsolete configurations and warn
+ about them unless --enable-obsolete is used. Use this to mark
+ vax-vms port as obsolete.
+
+2003-07-30 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c (ppc_elf_install_value): Tidy.
+ (ppc_elf_relax_section): Remove dead code. Remove unnecessary casts.
+ Formatting.
+ * elfxx-target.h: Remove PARAMS macro. Formatting.
+
+2003-07-30 Alan Modra <amodra@bigpond.net.au>
+
+ * elf.c (bfd_section_from_r_symndx): Test for SHN_UNDEF.
+ * elf64-ppc.c (get_fdh): New function, split out from
+ ppc64_elf_edit_opd.
+ (ppc64_elf_check_relocs): Use get_fdh.
+ (func_desc_adjust): Likewise. Tidy.
+ (ppc64_elf_edit_opd): Tighten reloc checks. Free local_syms on error
+ exit. Use get_fdh. Account for superfluous dynamic relocs.
+ (ppc64_elf_relocate_section): Warning fix.
+
+2003-07-30 Jason Eckhardt <jle@rice.edu>
+
+ * coff-i860.c: Convert to ISO C90. Remove superflous prototypes.
+
+2003-07-30 Jason Eckhardt <jle@rice.edu>
+
+ * elf32-i860.c: Convert to ISO C90. Remove superflous prototypes.
+
+2003-07-30 Randolph Chung <tausq@debian.org>
+
+ * elf-hppa.h (elf_hppa_relocate_section): Look up dyn_h for undefweak.
+ * elf64-hppa.c (elf64_hppa_finalize_dlt): Check h->root.type.
+
+2003-07-30 Alan Modra <amodra@bigpond.net.au>
+
+ * elf.c: Convert to C90, remove unnecessary prototypes and casts.
+ Replace PTR with void *. Formatting.
+ (_bfd_elf_assign_file_position_for_section): Remove INLINE.
+ (make_mapping): Likewise.
+
+2003-07-29 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (func_desc_adjust): Give linker created function
+ descriptor symbols a size and type.
+ (ppc64_elf_relocate_section): Correct lq insn test.
+
+2003-07-28 Eric Christopher <echristo@redhat.com>
+
+ * elf32-ppc.c (R_PPC_RELAX32): New relocation.
+ (ppc_elf_install_value): New function.
+ (ppc_elf_sort_rela): Remove.
+ (ppc_elf_relax_section): Rewrite. Remove old relaxation
+ and replace with out of range branch stubs.
+ (ppc_elf_relocate_section): Handle R_PPC_RELAX32.
+
+2003-07-29 Alexandre Oliva <aoliva@redhat.com>
+
+ * elf-m10300.c (mn10300_elf_relax_section): Take symbol hash table
+ from input_bfd.
+
+2003-07-28 Alan Modra <amodra@bigpond.net.au>
+
+ * elf.c (special_sections): Set attributes for .got and .plt.
+
+2003-07-27 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Ensure no copy relocs
+ on function descriptors.
+ (ELIMINATE_COPY_RELOCS): Expand comment.
+ (ppc64_elf_special_sections): Move. Don't include non-ppc64 sections.
+ Do include ".toc1".
+
+2003-07-25 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elf.c (_bfd_elf_new_section_hook): Set the default section
+ type to SHT_NULL.
+ (elf_fake_sections): Set the section type based on asect->flags
+ if it is SHT_NULL. Don't abort on processor specific section
+ types.
+
+2003-07-25 H.J. Lu <hongjiu.lu@intel.com>
+
+ * bfd-in2.h: Regenerated.
+
+2003-07-25 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elf-bfd.h (bfd_elf_special_section): New.
+ (elf_backend_data): Add special_sections, a pointer to
+ bfd_elf_special_section.
+ (elf_section_type). New.
+ (elf_section_flags): New.
+ (_bfd_elf_get_sec_type_attr): New.
+
+ * elf.c (_bfd_elf_make_section_from_shdr): Always use the
+ real section type/flags.
+ (special_sections): New.
+ (get_special_section): New.
+ (_bfd_elf_get_sec_type_attr): New.
+ (_bfd_elf_new_section_hook): Check special_section to set
+ elf_section_type and elf_section_flags.
+ (elf_fake_sections): Don't use section name to set ELF section
+ data.
+
+ * elf32-m32r.c (m32r_elf_special_sections): New.
+ (elf_backend_special_sections): Defined.
+
+ * elf32-m68hc11.c (elf32_m68hc11_special_sections): New.
+ (elf_backend_special_sections): Defined.
+
+ * elf32-mcore.c (mcore_elf_special_sections): New.
+ (elf_backend_special_sections): Defined.
+
+ * elf32-ppc.c (ppc_elf_special_sections): New.
+ (elf_backend_special_sections): Defined.
+
+ * elf32-sh64.c (sh64_elf_special_sections): New.
+ (elf_backend_special_sections): Defined.
+
+ * elf32-v850.c (v850_elf_special_sections): New.
+ (elf_backend_special_sections): Defined.
+
+ * elf32-xtensa.c (elf_xtensa_special_sections): New.
+ (elf_backend_special_sections): Defined.
+
+ * elf64-alpha.c (elf64_alpha_special_sections): New.
+ (elf_backend_special_sections): Defined.
+
+ * elf64-hppa.c (elf64_hppa_special_sections): New.
+ (elf_backend_special_sections): Defined.
+
+ * elf64-ppc.c (ppc64_elf_special_sections): New.
+ (elf_backend_special_sections): Defined.
+
+ * elf64-sh64.c (sh64_elf64_special_sections): New.
+ (elf_backend_special_sections): Defined.
+
+ * elfxx-ia64.c (elfNN_ia64_special_sections): New.
+ (elf_backend_special_sections): Defined.
+
+ * elfxx-mips.c (_bfd_mips_elf_special_sections): New.
+
+ * elfxx-mips.h (_bfd_mips_elf_special_sections): New.
+ (elf_backend_special_sections): Defined.
+
+ * elfxx-target.h (elf_backend_special_sections): New. Default
+ to NULL.
+ (elfNN_bed): Initialize special_sections.
+
+ * section.c (bfd_abs_section): Remove const.
+ (bfd_und_section): Likewise.
+ (bfd_com_section): Likewise.
+ (bfd_ind_section): Likewise.
+
+2003-07-24 Nick Clifton <nickc@redhat.com>
+
+ * coff-arm.c (EXTRA_S_FLAGS): Include SEC_CODE so that code
+ sections are assigned the LOAD attribute.
+
+2003-07-25 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * elf32-sh.c: Convert to C90. Replace PTR with void *.
+ * elf32-sh64-com.c: Likewise.
+ * elf32-sh64.c: Likewise.
+ * elf32-sh64.h: Likewise.
+ * elf64-sh64.c: Likewise.
+
+2003-07-24 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * elf32-sh.c (sh_elf_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL.
+ (allocate_dynrelocs): Likewise.
+ (sh_elf_relocate_section): Likewise. Use SYMBOL_REFERENCES_LOCAL.
+ (sh_elf_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL.
+
+2003-07-24 Nick Clifton <nickc@redhat.com>
+
+ * po/fr.po: Updated French translation.
+
+2003-07-23 Bob Wilson <bob.wilson@acm.org>
+
+ * elf32-xtensa.c (xtensa_elf_dynamic_symbol_p): Make inline and move
+ near the beginning of the file. Swap order of arguments. Call
+ _bfd_elf_dynamic_symbol_p with "ignore_protected" set to 0.
+ (elf_xtensa_fix_refcounts): Adjust xtensa_elf_dynamic_symbol_p call.
+ (elf_xtensa_relocate_section): Likewise.
+ (shrink_dynamic_reloc_sections): Likewise.
+
+2003-07-23 Bob Wilson <bob.wilson@acm.org>
+
+ * elf32-xtensa.c (plt_reloc_count): Fix typo in comment.
+ (elf_xtensa_size_dynamic_sections): Use elf_discarded_section.
+ (elf_xtensa_combine_prop_entries): Avoid returning non-zero without
+ first printing an error message.
+ (elf_xtensa_finish_dynamic_sections): Likewise.
+ (elf_xtensa_discard_info_for_section): Adjust size of .got.loc when
+ discarding literal table entries.
+ (elf_xtensa_merge_private_bfd_data): Remove newline from error message.
+ (elf_xtensa_do_asm_simplify): Likewise.
+
+2003-07-23 Stephane Carrez <stcarrez@nerim.fr>
+
+ * elf32-m68hc1x.c (elf32_m68hc11_size_stubs): Avoid crash when
+ we have a local symbol in common section.
+
+2003-07-22 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elflink.c (_bfd_elf_dynamic_symbol_p): Don't return TRUE for
+ weak symbols.
+
+2003-07-22 Nick Clifton <nickc@redhat.com>
+
+ * coffcode.h (coff_slurp_symbol_table): Add C_TCSYM and C_ECOML to
+ expected RS6000 storage classes.
+
+2003-07-21 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elfxx-ia64.c (elfNN_ia64_size_dynamic_sections): Mark
+ output_bfd unused to silence gcc.
+
+2003-07-21 Nick Clifton <nickc@redhat.com>
+
+ * po/sv.po: Updated Swedish translation.
+
+2003-07-21 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h (SYMBOL_REFERENCES_LOCAL, SYMBOL_CALLS_LOCAL): Use..
+ (_bfd_elf_symbol_refs_local_p): ..this. Declare.
+ * elflink.c (_bfd_elf_symbol_refs_local_p): New function.
+ * elf32-i386.c (elf_i386_relocate_section): Remove h NULL test
+ now done in _bfd_elf_symbol_refs_local_p.
+ * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
+ * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
+ * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
+
+2003-07-18 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elflink.c (_bfd_elf_dynamic_symbol_p): Undo the last change.
+
+2003-07-18 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elf-bfd.h (SYMBOL_REFERENCES_LOCAL): Fix a typo.
+ (SYMBOL_CALLS_LOCAL): Likewise.
+
+ * elflink.c (_bfd_elf_dynamic_symbol_p): Return TRUE
+ immediately if symbol isn't defined locally.
+
+2003-07-18 Richard Henderson <rth@redhat.com>
+
+ * elflink.c (_bfd_elf_dynamic_symbol_p): New.
+ * elf-bfd.h (_bfd_elf_dynamic_symbol_p): Declare it.
+ (SYMBOL_REFERENCES_LOCAL, SYMBOL_CALLS_LOCAL): Use it.
+ * elf32-xtensa.c (xtensa_elf_dynamic_symbol_p): Likewise.
+ * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Likewise.
+ * elf64-hppa.c (elf64_hppa_dynamic_symbol_p): Likewise.
+ * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Likewise.
+ Update all callers to provide the relocation being resolved.
+
+2003-07-17 Shaun Jackman <sjackman@pathwayconnect.com>
+
+ * config.bfd (arm-wince-pe): Add -DARM_COFF_BUGFIX to
+ targ_cflags.
+
+2003-07-17 Nick Clifton <nickc@redhat.com>
+
+ * po/es.po: New Spanish translation.
+ * po/sv.po: New Swedish translation.
+ * po/opcodes.pot: Regenerate.
+
+2003-07-16 Richard Henderson <rth@redhat.com>
+
+ * config.bfd, configure.host, configure.in: Remove ia64-aix support.
+ * elfxx-ia64.c, targets.c: Likewise.
+
+2003-07-16 Richard Henderson <rth@redhat.com>
+
+ * elfxx-ia64.c (elfNN_ia64_dynamic_symbol_p): Properly return false
+ for symbols defined locally plus -Bsymbolic. Tidy logic.
+
+2003-07-15 Richard Sandiford <rsandifo@redhat.com>
+
+ * archures.c (bfd_mach_mips7000): New.
+ * bfd-in2.h: Regenerated.
+ * cpu-mips.c (arch_info_struct): Add an entry for mips:7000.
+ * elfxx-mips.c (mips_set_isa_flags): Handle bfd_mach_mips7000.
+ (mips_mach_extensions): Add an entry for it.
+
+2003-07-14 Nick Clifton <nickc@redhat.com>
+
+ * po/tr.po: Update with latest version.
+ * po/SRC-POTFILES.in: Regenerate.
+ * po/bfd.pot: Regenerate.
+ * Makfile.in: Regenerate.
+ * configure: Regenerate.
+
+2003-07-12 Jeff Baker <jbaker@qnx.com>
+
+ * bfd/config.bfd (__QNXTARGET__): Define for Neutrino architectures.
+ * bfd/elf32-arm.h (ELF_MAXPAGESIZE): Set to 4k for Neutrino.
+ * bfd/elf32-sh.c (ELF_MAXPAGESIZE): Set to 4k for Neutrino.
+ * bfd/elf32-ppc.c (ELF_MAXPAGESIZE): Set to 4k for Neutrino.
+
+2003-07-12 Jeff Muizelaar <muizelaar@rogers.com>
+
+ * coffcode.h (coff_set_section_contents): Set the
+ IMAGE_FILE_32BIT_MACHINE flag for PE targets.
+
+2003-07-11 Richard Sandiford <rsandifo@redhat.com>
+
+ * bfd-in.h (bfd_h8300_pad_address): Declare.
+ * bfd-in2.h: Regenerate.
+ * cpu-h8300.c (bfd_h8300_pad_address): New function.
+ * coff-h8300.c (h8300_reloc16_estimate): Use it to canonicalize
+ addresses before checking whether they can be relaxed.
+ (h8300_reloc16_extra_cases): Likewise for the R_MOVL2 sanity check.
+ Don't complain about overflows in general 8-bit relocations.
+ * elf32-h8300.c (elf32_h8_relax_section): Use bfd_h8300_pad_address.
+ Fix handling of R_H8_DIR24A8.
+
+2003-07-11 Richard Sandiford <rsandifo@redhat.com>
+
+ * elf32-h8300.c: Convert function prototypes and definitions
+ to C90 syntax.
+ * coff-h8300.c: Likewise.
+ * cpu-h8300.c: Likewise.
+
+2003-07-11 Alan Modra <amodra@bigpond.net.au>
+
+ * po/SRC-POTFILES.in: Regenerate.
+ * po/bfd.pot: Likewise.
+
+2003-07-10 Bob Wilson <bob.wilson@acm.org>
+
+ * elf32-xtensa.c (elf_xtensa_create_dynamic_sections): Create new
+ .got.loc section. Do not set SEC_ALLOC or SEC_LOAD flags for the
+ .xt.lit.plt section.
+ (elf_xtensa_size_dynamic_sections): Set size of the .got.loc section
+ and allocate memory for it.
+ (elf_xtensa_combine_prop_entries): Copy contents of .xt.lit output
+ section to the .got.loc section.
+ (elf_xtensa_finish_dynamic_sections): Fix up call to
+ elf_xtensa_combine_prop_entries and set DT_XTENSA_GOT_LOC_OFF to
+ the address of .got.loc.
+ (relax_property_section): Shrink .got.loc to match changes in any
+ literal table section.
+ (xtensa_is_property_section): Change to match
+ xtensa_get_property_section_name.
+ (xtensa_is_littable_section): New.
+
+2003-07-10 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elfxx-ia64.c (IA64_HOWTO): Set dst_mask to -1 instead of
+ -1LL.
+
+2003-07-10 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (BFD32_BACKENDS): Add elf32-am33lin.lo.
+ (BFD32_BACKENDS_CFILES): elf32-am33lin.c not elf32-am33lin.lo.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2003-07-10 Alexandre Oliva <aoliva@redhat.com>
+
+ 2001-09-12 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-am33lin.c (ELF_MACHINE_CODE): Redefine to EM_MN10300.
+ (ELF_MACHINE_ALT1): Define to EM_CYGNUS_MN10300.
+ 2001-06-02 Nick Clifton <nickc@cambridge.redhat.com>
+ * elf32-am33lin.c: Rename global functions.
+ 2001-05-09 Alexandre Oliva <aoliva@redhat.com>
+ * config.bfd (am33_2.0, am33_2.0-*-linux*): Added.
+ * configure.in (bfd_elf32_am33lin_vec): Added.
+ * Makefile.am (BFD32_BACKENDS): Added elf32-am33lin.lo.
+ (elf32-am33lin.lo): List dependencies.
+ * aclocal.m4, configure, Makefile.in: Rebuilt.
+ * elf-m10300.c (TARGET_LITTLE_SYM, TARGET_LITTLE_NAME,
+ ELF_ARCH, ELF_MACHINE_CODE, ELF_MAXPAGESIZE): Define only if
+ ELF_ARCH was not defined before.
+ (elf_symbol_leading_char): Define if not defined.
+ * elf32-am33lin.c: Override the definitions above.
+ * targets.c (bfd_elf32_am33lin_vec): New.
+
+2003-07-09 Alexandre Oliva <aoliva@redhat.com>
+
+ 2002-12-12 Alexandre Oliva <aoliva@redhat.com>
+ * elf-m10300.c (elf32_mn10300_link_hash_newfunc): Initialize
+ pcrel_relocs_copied.
+ 2001-12-13 Alexandre Oliva <aoliva@redhat.com>
+ * elf-m10300.c (ELF_DYNAMIC_INTERPRETER): Renamed from
+ ld-linux.so.2 to ld.so.1.
+ 2001-10-10 Alexandre Oliva <aoliva@redhat.com>
+ * elf-m10300.c (elf_mn10300_sizeof_plt0): New macro.
+ (_bfd_mn10300_elf_adjust_dynamic_symbol): Use it.
+ (_bfd_mn10300_elf_finish_dynamic_symbol): Likewise.
+ * elf-m10300.c (_bfd_mn10300_elf_size_dynamic_sections): Allocate
+ .rela.* section contents with bfd_zalloc.
+ 2001-09-25 Alexandre Oliva <aoliva@redhat.com>
+ * elf-m10300.c: Added declarations for functions missing them.
+ Merge some shared-library changes from the i386 back-end. Use
+ R_MN10300_RELATIVE instead of R_MN10300_PCREL32 and
+ R_MN10300_GLOB_DAT instead of R_MN10300_32 where appropriate.
+ (struct elf32_mn10300_link_hash_entry): Remove duplicates of
+ members of elf_link_hash_entry. Adjusted references.
+ (mn10300_elf_final_link_relocate): dynobj was already loaded
+ into a local variable, use it.
+ 2001-09-21 Nick Clifton <nickc@cambridge.redhat.com>
+ * elf-m10300.c: Add missing function prototypes.
+ 2001-08-24 Alexandre Oliva <aoliva@redhat.com>
+ * elf-m10300.c (mn10300_elf_relocate_section): Don't compute
+ relocation for dynamic relocations.
+ 2001-05-16 Alexandre Oliva <aoliva@redhat.com>
+ * reloc.c (BFD_RELOC_MN10300_GOTOFF24): New.
+ * elf-m10300.c: Introduce GOTPC16, GOTOFF24, GOTOFF16 and
+ PLT16, and rename GOTPC to GOTPC32 and GOTOFF to GOTOFF32.
+ (_bfd_mn10300_elf_create_dynamic_sections): Move creation ot PLT...
+ (_bfd_mn10300_elf_create_got_section): ... here, so that its
+ adress is already known at the time we compute relaxations.
+ (mn10300_elf_relax_section): Relax GOTPC32, GOTOFF32, GOT32
+ and PLT32 to narrower relocations.
+ * libbfd.h, bfd-in2.h: Rebuilt.
+ 2001-04-12 Alexandre Oliva <aoliva@redhat.com>
+ * reloc.c (BFD_RELOC_MN10300_GOT32, BFD_RELOC_MN10300_GOT24,
+ BFD_RELOC_MN10300_GOT16, BFD_RELOC_MN10300_COPY,
+ BFD_RELOC_MN10300_GLOB_DAT, BFD_RELOC_MN10300_JMP_SLOT,
+ BFD_RELOC_MN10300_RELATIVE): New relocs.
+ * libbfd.h, bfd-in2.h: Rebuilt.
+ * elf-m10300.c (struct elf_mn10300_pcrel_relocs_copied): New.
+ (struct elf32_mn10300_link_hash_entry): Added DSO-related
+ fields.
+ (elf_mn10300_howto): Defined new relocation types.
+ (mn10300_reloc_map): Map them.
+ (_bfd_mn10300_elf_create_got_section): New fn.
+ (mn10300_elf_check_relocs): Handle PIC relocs.
+ (mn10300_elf_final_link_relocate): Likewise.
+ (mn10300_elf_relocate_section): Handle DSOs.
+ (PLT0_ENTRY_SIZE, PLT_ENTRY_SIZE, PIC_PLT_ENTRY_SIZE): New macros.
+ (elf_mn10300_plt0_entry, elf_mn10300_plt_entry,
+ elf_mn10300_pic_plt_entry): New.
+ (elf_mn10300_sizeof_plt, elf_mn10300_plt_plt0_offset,
+ elf_mn10300_plt0_linker_offset, elf_mn10300_plt0_gotid_offset,
+ elf_mn10300_plt_temp_offset, elf_mn10300_plt_symbol_offset,
+ elf_mn10300_plt_reloc_offset: New macros.
+ (ELF_DYNAMIC_INTERPRETER): Likewise.
+ (_bfd_mn10300_elf_create_dynamic_sections): New function.
+ (_bfd_mn10300_elf_adjust_dynamic_symbol): Likewise.
+ (_bfd_mn10300_elf_discard_copies): Likewise.
+ (_bfd_mn10300_elf_size_dynamic_sections): Likewise.
+ (_bfd_mn10300_elf_finish_dynamic_symbol): Likewise.
+ (_bfd_mn10300_elf_finish_dynamic_sections): Likewise.
+ (elf_backend_can_gc_sections,
+ elf_backend_create_dynamic_sections,
+ elf_backend_adjust_dynamic_sections,
+ elf_backend_size_dynamic_sections,
+ elf_backend_finish_dynamic_symbol,
+ elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
+ elf_backend_plt_readonly, elf_backend_want_plt_sym,
+ elf_backend_got_header_size, elf_backend_plt_header_size): New
+ macros.
+
+2003-07-09 Alexandre Oliva <aoliva@redhat.com>
+
+ 2001-05-06 Alexandre Oliva <aoliva@redhat.com>
+ * elf-m10300.c (compute_function_info): Account for AM33
+ registers in `movm' when computing stack space for `call' when
+ linking for AM33/2.0 link.
+ 2000-04-01 Alexandre Oliva <aoliva@cygnus.com>
+ * archures.c (bfd_mach_am33_2): Renamed from bfd_mach_am332.
+ * bfd-in2.h: Rebuilt.
+ * cpu-m10300.c (bfd_am33_2_arch): Renamed from bfd_am332_arch.
+ * elf-m10300.c: Updated.
+ 2000-03-31 Alexandre Oliva <aoliva@cygnus.com>
+ * archures.c (bfd_mach_am332): Defined.
+ * bfd-in2.h: Rebuilt.
+ * cpu-m10300.c (bfd_am332_arch): Defined.
+ (bfd_am33_arch): Chained with am33-2.
+ * elf-m10300.c (elf_mn10300_mach): Handle am332.
+ (_bfd_mn10300_elf_final_write_processing): Likewise.
+
+2003-07-09 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elfxx-ia64.c (IA64_HOWTO): Set dst_mask to -1LL.
+
+2003-07-10 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (bfd_elf64_mkobject): Define.
+ (struct ppc64_elf_obj_tdata): New.
+ (ppc64_elf_tdata, ppc64_tlsld_got): Define.
+ (ppc64_elf_mkobject): New function.
+ (struct got_entry): Add "owner". Move "tls_type".
+ (struct ppc_link_hash_table): Delete "relgot", "tlsld_got".
+ (ppc64_elf_init_stub_bfd): New function.
+ (create_got_section): Create header .got in dynobj. Create .got
+ and .rela.got in each bfd. Stash pointers in ppc64_elf_obj_tdata.
+ (ppc64_elf_create_dynamic_sections): Don't call create_got_section.
+ Look for dynobj .got, and test it.
+ (ppc64_elf_copy_indirect_symbol): Adjust for changed got.
+ (update_local_sym_info): Likewise.
+ (ppc64_elf_check_relocs): Likewise.
+ (ppc64_elf_gc_sweep_hook): Likewise.
+ (ppc64_elf_tls_optimize): Likewise.
+ (allocate_dynrelocs): Likewise.
+ (ppc64_elf_size_dynamic_sections): Likewise.
+ (ppc64_elf_relocate_section): Likewise.
+ (ppc64_elf_next_toc_section): Update comment.
+ (toc_adjusting_stub_needed): Remove unneeded cast.
+ (ppc64_elf_build_stubs): Check for stub sections in stub bfd by
+ testing section flags.
+ (ppc64_elf_build_stubs): Likewise.
+ (ppc64_elf_size_stubs): Likewise. Remove stub_bfd param.
+ (ppc64_elf_finish_dynamic_sections): Write out got sections.
+ (func_desc_adjust): Copy over dynamic info for undef weaks.
+ * elf64-ppc.h (ppc64_elf_init_stub_bfd): Declare.
+ (ppc64_elf_size_stubs): Update prototype.
+ * elflink.h (elf_link_sort_relocs): Use link_orders to find reldyn
+ input sections rather than scanning dynobj.
+
+2003-07-09 Richard Sandiford <rsandifo@redhat.com>
+
+ * elfxx-mips.c (mips_elf_link_hash_entry): Remove min_dyn_reloc_index.
+ (bfd_mips_elf_swap_msym_in, bfd_mips_elf_swap_msym_out): Delete.
+ (mips_elf_create_msym_section): Delete.
+ (mips_elf_create_dynamic_relocation): Don't set min_dyn_reloc_index.
+ (_bfd_mips_elf_copy_indirect_symbol): Likewise.
+ (_bfd_mips_elf_create_dynamic_sections): Don't create .msym.
+ (_bfd_mips_elf_size_dynamic_sections): Don't calculate its size.
+ (_bfd_mips_elf_size_dynamic_sections): Don't add DT_MIPS_MSYM.
+ (_bfd_mips_elf_finish_dynamic_symbol): Don't add symbols to .msym.
+ (_bfd_mips_elf_finish_dynamic_sections): Likewise.
+
+2003-07-09 Richard Sandiford <rsandifo@redhat.com>
+
+ * elfxx-mips.c (mips_elf_irix6_finish_dynamic_symbol): Make the
+ symbols protected.
+
+2003-07-09 Richard Sandiford <rsandifo@redhat.com>
+
+ * elfxx-mips.c (mips_elf_create_dynamic_relocation): Fix handling
+ of relocations whose offset is -2.
+
+2003-07-09 Richard Sandiford <rsandifo@redhat.com>
+
+ * bfd/elfxx-mips.c (mips_elf_create_dynamic_relocation): Treat
+ forced-local symbols like other locals. Don't create relocations
+ against STN_UNDEF in irix objects.
+
+2003-07-09 Richard Sandiford <rsandifo@redhat.com>
+
+ * bfd/elfxx-mips.c (mips_elf_create_dynamic_relocation): In SGI-
+ compatible objects, add the values of defined external symbols
+ to the addend.
+
+2003-07-09 Richard Sandiford <rsandifo@redhat.com>
+
+ * elfxx-mips.c (_bfd_mips_elf_finish_dynamic_symbol): Always
+ initialize a GOT entry to the symbol's st_value.
+
+2003-07-08 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h (struct elf_obj_tdata): Move linker_section_pointers..
+ * elf32-ppc.c (struct ppc_elf_obj_tdata): ..to here. New.
+ (ppc_elf_tdata): Define.
+ (elf_local_ptr_offsets): Adjust.
+ (ppc_elf_mkobject): New function.
+ (bfd_elf32_mkobject): Define.
+
+ * elfcode.h (elf_object_p): Allocate tdata via _bfd_set_format.
+ * elfcore.h (elf_core_file_p): Likewise.
+ * section.c (bfd_section_init): Remove prototype.
+
+2003-07-08 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h (struct elf_link_hash_entry): Remove linker_section_pointer
+ field.
+ (enum elf_linker_section_enum): Delete.
+ (struct elf_linker_section): Delete.
+ (struct elf_linker_section_pointers): Delete.
+ (struct elf_obj_tdata): Remove #if 0 chunk. Remove linker_section.
+ Make linker_section_pointers a void**.
+ (elf_local_ptr_offsets, elf_linker_section): Don't define.
+ * elf32-ppc.c (enum elf_linker_section_enum): New, cut-down version
+ of old item in elf-bfd.h.
+ (struct elf_linker_section): Likewise.
+ (struct elf_linker_section_pointers): Likewise.
+ (elf_local_ptr_offsets): Define.
+ (struct ppc_elf_link_hash_entry): Add linker_section_pointer.
+ (ppc_elf_link_hash_newfunc): Init it.
+ (struct ppc_elf_link_hash_table): Add sbss.
+ (ppc_elf_link_hash_table_create): zmalloc rather than clearing
+ individual fields.
+ (elf_create_linker_section): Fold into..
+ (ppc_elf_create_linker_section): ..here. Remove hole_size code.
+ Make rela section here if shared.
+ (elf_find_pointer_linker_section): Pass lsect rather than enum.
+ (elf_create_pointer_linker_section): Adjust. zalloc rather than
+ clearing in a loop.
+ (elf_finish_pointer_linker_section): Adjust. Don't make rela
+ section here.
+ (ppc_elf_check_relocs): Adjust.
+ (ppc_elf_add_symbol_hook): Tighten hash creator test. Remove code
+ creating .sbss by hand.
+ * elf.c (_bfd_elf_link_hash_newfunc): Adjust.
+
+2003-07-04 Jakub Jelinek <jakub@redhat.com>
+
+ * elf32-s390.c (elf_howto_table): Change R_390_GOT12 to
+ complain_overflow_bitfield.
+ * elf64-s390.c (elf_howto_table): Change R_390_GOT12 to
+ complain_overflow_bitfield.
+
+2003-07-04 Jakub Jelinek <jakub@redhat.com>
+
+ * elf-bfd.h (SYMBOL_REFERENCES_LOCAL, SYMBOL_CALLS_LOCAL): Return
+ true even if -pie.
+
+2003-07-04 Jakub Jelinek <jakub@redhat.com>
+
+ * elfxx-ia64.c (struct elfNN_ia64_link_hash_table): Add rel_fptr_sec.
+ (elfNN_ia64_dynamic_symbol_p): Change info->shared into
+ !info->executable.
+ (get_fptr): For -pie create .opd as writable section and create
+ .rela.opd as well.
+ (elfNN_ia64_check_relocs): Change info->shared into
+ !info->executable.
+ (allocate_fptr): Likewise.
+ (allocate_dynrel_entries): Account for a relative reloc for -pie
+ @fptr(). Don't account for a relative reloc if -pie want_ltoff_fptr
+ for undefweak symbol. Account for an IPLT reloc in .rela.opd
+ section if -pie.
+ (set_got_entry): Don't create a relative reloc if -pie
+ want_ltoff_fptr for undefweak symbol.
+ (set_fptr_entry): Emit an IPLT reloc in .rela.opd for -pie.
+ (elfNN_ia64_relocate_section): Emit a relative reloc for -pie
+ @fptr().
+
+ * elfxx-ia64.c (elfNN_ia64_relocate_section): Issue undefined_symbol
+ even if -pie.
+ * elf32-i386.c (elf_i386_relocate_section): Likewise.
+ * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
+ * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
+ * elf64-s390.c (elf_s390_relocate_section): Likewise.
+ * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
+ * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
+ * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
+ * elf32-s390.c (elf_s390_relocate_section): Likewise.
+ * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
+
+2003-07-04 Paul Clarke <paulc@senet.com.au>
+
+ * elf32-h8300.c (R_H8_DIR32A16): Fix name field.
+ (elf32_h8_relax_section) <R_H8_DIR16A8>: Adjust position of relocation.
+ <R_H8_DIR32A16>: Fix type of relocation.
+
+2003-07-04 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * elf32-sh.c (sh_elf_create_dynamic_sections): Return if dynamic
+ sections were created already. Remove unnecessary tests of
+ the previous change.
+
+2003-07-04 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * elf32-sh.c (sh_elf_create_dynamic_sections): Don't call
+ bfd_make_section for existing sections.
+
+2003-07-04 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-sparc.c (elf32_sparc_check_relocs): Don't call
+ create_got_section if we already have done so.
+ * elf32-sh.c (sh_elf_create_dynamic_sections): Likewise.
+ (sh_elf_check_relocs): Likewise.
+ (sh_elf_adjust_dynamic_symbol): Delete "dynobj" var. Use
+ htab->root.dynobj instead.
+ (sh_elf_check_relocs): Likewise.
+ (sh_elf_finish_dynamic_sections): Likewise.
+
+ * section.c (bfd_make_section): Return NULL for existing section.
+
+2003-07-04 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c (ppc_elf_create_dynamic_sections): Don't call
+ ppc_elf_create_got if we've already done so.
+
+ * elf-bfd.h (_bfd_elf_create_linker_section) Don't declare.
+ (_bfd_elf_find_pointer_linker_section): Likewise.
+ (bfd_elf32_create_pointer_linker_section): Likewise.
+ (bfd_elf32_finish_pointer_linker_section): Likewise.
+ (bfd_elf64_create_pointer_linker_section): Likewise.
+ (bfd_elf64_finish_pointer_linker_section): Likewise.
+ (_bfd_elf_make_linker_section_rela): Likewise.
+ * elfcode.h (elf_create_pointer_linker_section): Don't define.
+ (elf_finish_pointer_linker_section): Likewise.
+ * elflink.c (_bfd_elf_make_linker_section_rela): Delete.
+ (_bfd_elf_create_linker_section): Move this function..
+ (_bfd_elf_find_pointer_linker_section): ..and this..
+ * elflink.h (elf_create_pointer_linker_section): ..and this..
+ (elf_finish_pointer_linker_section): ..and this..
+ * elf32-ppc.c: ..to here, renaming to the following, and adjusting
+ calls.
+ (elf_create_linker_section): Convert to C90, tidy.
+ (elf_find_pointer_linker_section): Likewise.
+ (elf_create_pointer_linker_section): Likewise.
+ (elf_finish_pointer_linker_section): Likewise.
+ * elf32-i370.c: Delete #if 0 code.
+
+2003-07-02 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_func_desc_adjust): Don't allow _savef* and
+ _restf* to be satisfied by shared libs, and always force them local.
+ (toc_adjusting_stub_needed): Avoid scanning linker created sections.
+ Correct test for "bl".
+ (ppc64_elf_relocate_section <R_PPC64_TLS>): Correct test for
+ primary opcode 31.
+
+2003-07-01 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * elf32-s390.c (s390_elf_ldisp_reloc): New prototype.
+ (s390_tls_reloc): New function.
+ (elf_howto_table): Add long displacement relocations R_390_20,
+ R_390_GOT20, R_390_GOTPLT20 and R_390_TLS_GOTIE20.
+ (elf_s390_reloc_type_lookup): Likewise.
+ (elf_s390_check_relocs): Likewise.
+ (elf_s390_gc_sweep_hook): Likewise.
+ (elf_s390_relocate_section): Likewise.
+ * elf64-s390.c: Same changes as for elf32-s390.c.
+ * reloc.c: Add long displacement relocations BFD_RELOC_390_20,
+ BFD_RELOC_390_GOT20, BFD_RELOC_390_GOTPLT20 and
+ BFD_RELOC_390_TLS_GOTIE20.
+ * bfd-in2.h: Regenerate.
+ * libbfd.h: Likewise.
+
+2003-06-30 Alan Modra <amodra@bigpond.net.au>
+
+ * cpu-ia64-opc.c (ext_imms_scaled): Don't sign extend using shifts.
+ (ins_imms, ins_immsm1u4): Likewise. Warning fix.
+
+2003-06-29 Alan Modra <amodra@bigpond.net.au>
+
+ * archive.c: Convert to C90, remove unnecessary prototypes and casts.
+ Replace PTR with void *. Formatting.
+ * archive64.c: Likewise.
+ * archures.c: Likewise.
+ * bfd-in.h: Likewise.
+ * bfd.c: Likewise.
+ * bfdio.c: Likewise.
+ * bfdwin.c: Likewise.
+ * cache.c: Likewise.
+ * corefile.c: Likewise.
+ * format.c: Likewise.
+ * init.c: Likewise.
+ * libbfd-in.h: Likewise.
+ * libbfd.c: Likewise.
+ * linker.c: Likewise.
+ * opncls.c: Likewise.
+ * reloc.c: Likewise.
+ * section.c: Likewise.
+ * simple.c: Likewise.
+ * syms.c: Likewise.
+ * targets.c: Likewise.
+ * bfd-in2.h: Regenerate.
+ * libbfd.h: Regenerate.
+
+ * ecoff.c (bfd_debug_section): Add missing kept_section initialization.
+ * libbfd-in.h (_bfd_sh_align_load_span): Don't declare if defined.
+ * libbfd.c (COERCE32, EIGHT_GAZILLION): Simplify.
+ (bfd_getb64): Rewrite without parens.
+ (bfd_getl64, bfd_getb_signed_64, bfd_getl_signed_64): Likewise.
+ * cache.c (insert, snip): Remove INLINE.
+ * linker.c (bfd_link_add_undef): Likewise.
+
+2003-06-29 Andreas Jaeger <aj@suse.de>
+
+ * elf64-x86-64.c: Convert to ISO C90 prototypes, remove
+ unnecessary prototypes. Replace PTR with void *.
+ (elf64_x86_64_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL to
+ trim plt entries. Move undefweak non-default visibility test ...
+ (allocate_dynrelocs): ... from here.
+ (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Pass SHARED instead of INFO.
+ Change all callers.
+ (allocate_dynrelocs): Use SYMBOL_CALLS_LOCAL. Use
+ SYMBOL_REFERENCES_LOCAL for dynreloc check.
+ (elf64_x86_64_relocate_section): Use SYMBOL_CALLS_LOCAL for
+ dynreloc and .got relocs.
+ (elf64_x86_64_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL
+ for .got relocs.
+
+2003-06-29 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elfxx-mips.c: Allow lazy binding for R_MIPS_JALR.
+
+2003-06-27 Nick Clifton <nickc@redhat.com>
+
+ * opncls.c (bfd_add_gnu_debuglink_section): Rename to
+ bfd_add_gnu_debuglink_section and only create the section, do not
+ fill in its contents.
+ (bfd_fill_in_gnu_debuglink_section): New function. Fill in the
+ contents of a .gnu-debuglink section.
+ * bfd-in2.h: Regenerate.
+
+2003-06-27 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elfxx-mips.c: Revert .got alignment to 2**4.
+
+2003-06-27 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elf32-mips.c: Fix addend for _gp_disp special symbol.
+
+2003-06-27 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elfxx-mips.c (_bfd_mips_elf_fake_sections): Remove non-default
+ relocation header setup.
+
+2003-06-25 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c (ppc_elf_howto_table): Remove unnecessary cast.
+ (ppc_elf_reloc_type_lookup): Modify comment.
+ (ppc_elf_info_to_howto): Ditto.
+ (ppc_elf_relocate_section): Ditto.
+ (ppc_elf_check_relocs): Call ppc_elf_howto_init.
+
+2003-06-25 Alan Modra <amodra@bigpond.net.au>
+
+ * aout-ns32k.c: Correct spelling of "relocatable".
+ * aoutx.h: Likewise.
+ * bfd-in.h: Likewise.
+ * bfd.c: Likewise.
+ * bout.c: Likewise.
+ * coff-a29k.c: Likewise.
+ * coff-alpha.c: Likewise.
+ * coff-arm.c: Likewise.
+ * coff-i386.c: Likewise.
+ * coff-i860.c: Likewise.
+ * coff-i960.c: Likewise.
+ * coff-m68k.c: Likewise.
+ * coff-m88k.c: Likewise.
+ * coff-mcore.c: Likewise.
+ * coff-mips.c: Likewise.
+ * coff-or32.c: Likewise.
+ * coff-ppc.c: Likewise.
+ * coff-rs6000.c: Likewise.
+ * coff-sh.c: Likewise.
+ * coff-tic80.c: Likewise.
+ * coff64-rs6000.c: Likewise.
+ * cofflink.c: Likewise.
+ * cpu-ns32k.c: Likewise.
+ * ecoff.c: Likewise.
+ * ecofflink.c: Likewise.
+ * elf-bfd.h: Likewise.
+ * elf-eh-frame.c: Likewise.
+ * elf-hppa.h: Likewise.
+ * elf-m10200.c: Likewise.
+ * elf-m10300.c: Likewise.
+ * elf.c: Likewise.
+ * elf32-arm.h: Likewise.
+ * elf32-avr.c: Likewise.
+ * elf32-cris.c: Likewise.
+ * elf32-d10v.c: Likewise.
+ * elf32-dlx.c: Likewise.
+ * elf32-fr30.c: Likewise.
+ * elf32-frv.c: Likewise.
+ * elf32-h8300.c: Likewise.
+ * elf32-hppa.c: Likewise.
+ * elf32-i370.c: Likewise.
+ * elf32-i386.c: Likewise.
+ * elf32-i860.c: Likewise.
+ * elf32-i960.c: Likewise.
+ * elf32-ip2k.c: Likewise.
+ * elf32-iq2000.c: Likewise.
+ * elf32-m32r.c: Likewise.
+ * elf32-m68hc11.c: Likewise.
+ * elf32-m68hc1x.c: Likewise.
+ * elf32-m68k.c: Likewise.
+ * elf32-mcore.c: Likewise.
+ * elf32-mips.c: Likewise.
+ * elf32-msp430.c: Likewise.
+ * elf32-openrisc.c: Likewise.
+ * elf32-ppc.c: Likewise.
+ * elf32-s390.c: Likewise.
+ * elf32-sh.c: Likewise.
+ * elf32-sh64.c: Likewise.
+ * elf32-sparc.c: Likewise.
+ * elf32-v850.c: Likewise.
+ * elf32-vax.c: Likewise.
+ * elf32-xstormy16.c: Likewise.
+ * elf32-xtensa.c: Likewise.
+ * elf64-alpha.c: Likewise.
+ * elf64-hppa.c: Likewise.
+ * elf64-mips.c: Likewise.
+ * elf64-mmix.c: Likewise.
+ * elf64-ppc.c: Likewise.
+ * elf64-s390.c: Likewise.
+ * elf64-sh64.c: Likewise.
+ * elf64-sparc.c: Likewise.
+ * elf64-x86-64.c: Likewise.
+ * elfcode.h: Likewise.
+ * elflink.h: Likewise.
+ * elfn32-mips.c: Likewise.
+ * elfxx-ia64.c: Likewise.
+ * elfxx-mips.c: Likewise.
+ * i386linux.c: Likewise.
+ * ieee.c: Likewise.
+ * libcoff-in.h: Likewise.
+ * linker.c: Likewise.
+ * m68klinux.c: Likewise.
+ * pdp11.c: Likewise.
+ * pe-mips.c: Likewise.
+ * peXXigen.c: Likewise.
+ * reloc.c: Likewise.
+ * reloc16.c: Likewise.
+ * sparclinux.c: Likewise.
+ * sunos.c: Likewise.
+ * syms.c: Likewise.
+ * versados.c: Likewise.
+ * vms.c: Likewise.
+ * xcofflink.c: Likewise.
+ * bfd-in2.h: Regenerate.
+ * libcoff.h: Regenerate.
+ * libbfd.h: Regenerate.
+
+2003-06-24 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c (ppc_elf_check_relocs): Report plt reloc against
+ local sym errors.
+
+ * elf32-i386.c: Convert to C90 function definitions, remove unnecessary
+ prototypes and casts. Replace PTR with void *. Formatting.
+ * elf32-ppc.c: Likewise. Break long strings too.
+ (ppc_elf_relax_section): Use enum elf_ppc_reloc_type for r_type.
+ (ppc_elf_unhandled_reloc): Internationalize error message.
+ * elf32-ppc.h: Remove PARAMS.
+
+2003-06-23 Mark Mitchell <mark@codesourcery.com>
+
+ * elf32-ppc.c (ppc_elf_begin_write_processing): Use bytes to count
+ APUinfo slots.
+ (ppc_elf_final_write_processing): Likewise.
+
+2003-06-23 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elflink.h (elf_link_input_bfd): Check raw size when using
+ kept_section to preserve debug information discarded by
+ linkonce.
+
+2003-06-20 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (struct ppc_link_hash_table): Add top_id.
+ (ppc64_elf_setup_section_lists): Set it.
+ (ppc64_elf_relocate_section): Check sym section id against top_id.
+ (ppc_build_one_stub): Comment on top_id.
+
+2003-06-20 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
+
+ * config.bfd: Add tic4x-*-rtems*.
+
+2003-06-20 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c: Convert to C90 function definitions, remove unnecessary
+ prototypes and casts. Replace PTR with void *. Format copyright.
+ Mention ABI links.
+ (struct ppc_link_hash_table): Rename sgot, srelgot, splt, srelplt,
+ sdynbss, srelbss, sglink, sbrlt and srelbrlt to got, relgot .. relbrlt.
+ (ppc_type_of_stub): Make r_type an enum.
+ (ppc64_elf_size_stubs): Likewise.
+ * elf64-ppc.h: Remove PARAMS macro.
+
+2003-06-19 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_link_hash_table_create): Reinstate init of
+ elf hash tab fields.
+
+ * elf64-ppc.c (ppc64_elf_reloc_type_lookup): Tidy prototype.
+ (ppc64_elf_info_to_howto): Likewise.
+ (ppc64_elf_build_stubs): Add "stats" param, and print statistics.
+ * elf64-ppc.h (ppc64_elf_build_stubs): Adjust prototype.
+
+2003-06-19 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-sparc.c (sparc64_elf_relocate_section): Ignore R_SPARC_DISP32
+ reloc overflow on discarded eh_frame entries.
+
+2003-06-19 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (toc_adjusting_stub_needed): New function.
+ (ppc64_elf_next_input_section): Use it here to set has_gp_reloc.
+ Return error condition.
+ (ppc64_elf_size_stubs): Restrict toc adjusting stubs to sections
+ that have has_gp_reloc set.
+ (struct ppc_link_hash_table): Add stub_count.
+ (ppc_build_one_stub): Increment it.
+ (ppc64_elf_link_hash_table_create): zmalloc rather than clearing
+ individual fields.
+ * elf64-ppc.h (ppc64_elf_next_input_section): Update prototype.
+
+2003-06-18 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h (elf_gc_record_vtentry): Revert last change. Correct
+ size calculation from addend. Round size up.
+
+2003-06-18 Hans-Peter Nilsson <hp@axis.com>
+
+ * elf32-cris.c (cris_elf_relocate_section) <case
+ R_CRIS_32_GOTREL>: When linking a program, don't complain about a
+ symbol from a normal object or an undefined weak symbol.
+
+2003-06-18 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_relocate_section): Accept a symbol on
+ R_PPC64_TOC relocs.
+
+2003-06-17 H.J. Lu <hongjiu.lu@intel.com>
+
+ * section.c (struct sec): Put back kept_section.
+ (STD_SECTION): Put back kept_section initialization.
+ * bfd-in2.h: Regenerate.
+
+ * elflink.h (elf_link_input_bfd): Also check discarded linkonce
+ sections for relocateable output. Use kept_section to preserve
+ debug information discarded by linkonce.
+
+2003-06-17 Roland McGrath <roland@redhat.com>
+
+ * elfxx-ia64.c (elfNN_ia64_relocate_section): Support
+ segment-relative relocation between different segments.
+
+2003-06-17 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_relocate_section): Do unaligned reloc
+ optimizations earlier.
+
+ * elf64-ppc.c (struct ppc_link_hash_table): Reinstate top_index.
+ Restore previous input_list type.
+ (ppc64_elf_link_hash_table_create): Undo last change.
+ (ppc64_elf_setup_section_lists): Reinstate code setting up input lists
+ per output section, but don't bother with bfd_abs_section marker.
+ (ppc64_elf_next_input_section): Adjust for multiple input section
+ lists.
+ (group_sections): Likewise.
+
+2003-06-17 Jakub Jelinek <jakub@redhat.com>
+
+ * elf64-ppc.c (ppc64_elf_relocation_section): Ensure
+ *r_offset == r_addend for RELATIVE relocs against .got.
+
+2003-06-17 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_relocate_section): Optimize unaligned relocs.
+
+2003-06-17 Nick Clifton <nickc@redhat.com>
+
+ * elflink.h (elf_gc_record_vtentry): Allocate an extra element
+ in the vtable_entries_used array to allow for the accessing
+ the largest element.
+
+2003-06-17 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (struct ppc_link_hash_table): Remove top_index. Modify
+ input_list.
+ (ppc64_elf_link_hash_table_create): Init input_list here.
+ (ppc64_elf_setup_section_lists): Remove code setting up input lists
+ per output section. Set toc_off for abs and other standard sections.
+ (ppc64_elf_reinit_toc): Don't set elf_gp on input bfds lacking a toc.
+ (ppc64_elf_next_input_section): Adjust for single input section list.
+ Don't set toc_curr from input bfds that haven't set elf_gp.
+ (group_sections): Adjust for single input section list.
+
+ * elf64-ppc.c (ppc64_elf_relocate_section): Correct pcrel section zero.
+
+2003-06-16 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_relocate_section): When optimizing toctprel
+ tls, check that a TOC16_DS or TOC16_LO_DS reloc isn't pointing to a
+ dtprel entry. Ensure TLS_LD DTPMOD reloc has a zero addend. Write
+ got section for RELATIVE relocs. Fix wrong comment. Change condition
+ under which dynamic relocs update the section contents.
+
+2003-06-13 Robert Millan <zeratul2@wanadoo.es>
+
+ * config.bfd: Add i386-netbsd-gnu target.
+
+2003-06-12 Nick Clifton <nickc@redhat.com>
+
+ * opncls.c (calc_crc32): Rename to
+ bfd_calc_gnu_debuglink_crc32 and export.
+ (GNU_DEBUGLINK): Define and use to replace occurrences of
+ hard-coded ".gnu_debuglink" in the code.
+ (get_debug_link_info): Prevent aborts by replacing call to
+ xmalloc with a call to malloc.
+ (find_separate_debug_file): Prevent aborts by replacing calls
+ to xmalloc and xstrdup with calls to malloc and strdup.
+ (bfd_add_gnu_debuglink): New function. Add a .gnu_debuglink
+ section to a bfd.
+ * bfd-in2.h: Regenerate.
+
+2003-06-12 Federico G. Schwindt <fgsch@lodoss.net>
+
+ * config.bfd (i[3-7]86-*-openbsd[0-2].* | i[3-7]86-*-openbsd3.[0-3]):
+ New target (was i[3-7]86-*-openbsd* before).
+ (i[3-7]86-*-openbsd*): Change to use bfd_elf32_i386_vec.
+ (vax-*-openbsd*): New target.
+
+2003-06-11 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elfxx-mips.c (MIPS_ELF_OPTIONS_SECTION_NAME): Use .MIPS.options
+ for n32, too.
+ (MIPS_ELF_STUB_SECTION_NAME): Use .MIPS.stubs for n32, too.
+ (mips_elf_rel_dyn_section): Use appropriate section alignment.
+ (mips_elf_create_got_section): Likewise.
+ (_bfd_mips_elf_create_dynamic_sections): Likewise.
+
+2003-06-11 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elf32-mips.c (mips_elf_generic_reloc): New Function.
+ (elf_mips_howto_table_rel): Use it.
+ (gprel32_with_gp): Move prototype.
+ (mips_elf_hi16_reloc): Check for ! BSF_LOCAL instead of zero addend.
+ Use mips_elf_generic_reloc.
+ (mips_elf_got16_reloc): Check for ! BSF_LOCAL instead of zero addend.
+ Code cleanup.
+ (_bfd_mips_elf32_gprel16_reloc): Check for ! BSF_LOCAL instead of
+ zero addend.
+ (mips_elf_gprel32_reloc): Likewise. Use the same GP assignment logic
+ as in the other *_gprel*_reloc functions.
+ (gprel32_with_gp): Handle partial_inplace properly.
+ (mips32_64bit_reloc): Use mips_elf_generic_reloc.
+ (mips16_gprel_reloc): Check for ! BSF_LOCAL instead of zero addend.
+ Do addend handling directly instead of calling
+ _bfd_mips_elf_gprel16_with_gp. Handle partial_inplace properly.
+ * elf64-mips.c (mips_elf64_hi16_reloc): Check for ! BSF_LOCAL instead
+ of zero addend. Handle partial_inplace properly.
+ (mips_elf64_got16_reloc): Check for ! BSF_LOCAL instead of zero
+ addend.
+ (mips_elf64_gprel16_reloc): Likewise.
+ (mips_elf64_literal_reloc): Likewise.
+ (mips_elf64_gprel32_reloc): Likewise. Use the same GP assignment
+ logic as in the other *_gprel*_reloc functions. Handle
+ partial_inplace properly.
+ (mips_elf64_shift6_reloc): Check for ! BSF_LOCAL instead of zero
+ addend. Handle partial_inplace properly.
+ (mips16_gprel_reloc): Likewise. Do addend handling directly instead
+ of calling _bfd_mips_elf_gprel16_with_gp.
+ * elfn32-mips.c (mips_elf_got16_reloc): Check for BSF_LOCAL.
+ (mips_elf_gprel32_reloc): Check for ! BSF_LOCAL instead
+ of zero addend.
+ (mips_elf_shift6_reloc): Handle partial_inplace properly.
+ (mips16_gprel_reloc): Likewise. Do addend handling directly instead
+ of calling _bfd_mips_elf_gprel16_with_gp.
+ * elfxx-mips.c (_bfd_mips_elf_gprel16_with_gp): Handle
+ partial_inplace properly. Fix wrong addend handling. Fix overflow
+ check.
+ (_bfd_mips_elf_sign_extend): Renamed from mips_elf_sign_extend and
+ exported.
+ (mips_elf_calculate_relocation): Use _bfd_mips_elf_sign_extend.
+ (_bfd_mips_elf_relocate_section): Likewise.
+ (mips_elf_create_dynamic_relocation): Update sec_info_type access.
+ * elfxx-mips.h (_bfd_mips_relax_section): Fix prototype declaration.
+ (_bfd_mips_elf_sign_extend): New prototype.
+
+2003-06-11 Federico G. Schwindt <fgsch@lodoss.net>
+
+ * config.bfd (sparc-*-openbsd[0-2].* | sparc-*-openbsd3.[0-1]):
+ New target (was sparc-*-openbsd* before).
+ (sparc-*-openbsd*): Change to use bfd_elf32_sparc_vec.
+
+ * configure.in (vax-*-openbsd*): Set COREFILE to netbsd-core.lo.
+ * configure: Regenerate.
+
+2003-06-11 H.J. Lu <hongjiu.lu@intel.com>
+
+ * po/Make-in (DESTDIR): New.
+ (install-data-yes): Support $(DESTDIR).
+ (uninstall): Likewise.
+
+2003-06-11 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (config.status): Depend on version.h.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * po/SRC-POTFILES.in: Regenerate.
+
+2003-06-10 Alan Modra <amodra@bigpond.net.au>
+ Gary Hade <garyhade@us.ibm.com>
+
+ * elf64-ppc.c (ppc64_elf_relocate_section <*_DS>): Special case lq.
+
+2003-06-10 Richard Sandiford <rsandifo@redhat.com>
+
+ * archures.c (bfd_mach_h8300sxn): New architecture.
+ * bfd-in2.h: Regenerate.
+ * cpu-h8300.c (h8300_scan): Check for 'sxn'.
+ (h8300sxn_info_struct): New.
+ (h8300sx_info_struct): Link to it.
+ * elf32-h8300.c (elf32_h8_mach): Add h8300sxn case.
+ (elf32_h8_final_write_processing): Likewise.
+
+2003-06-08 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c: Move TARGET_LITTLE_SYM and other macros used by
+ elfxx-target.h so that we can use elf_backend_got_header_size.
+ (ELF_MACHINE_ALT1, ELF_MACHINE_ALT2): Delete.
+ (GLINK_CALL_STUB_SIZE): Modify. Define new glink call stub and
+ associated macros.
+ (ppc64_elf_howto_raw <GOT_TPREL16_DS, GOT_TPREL16_LO_DS>): Correct
+ dst_mask.
+ (enum ppc_stub_type): Add ppc_stub_long_branch_r2off and
+ ppc_stub_plt_branch_r2off.
+ (struct ppc_stub_hash_entry): Reorganize.
+ (struct ppc_link_hash_table): Add no_multi_toc, multi_toc_needed,
+ toc_curr, toc_off and emit_stub_syms.
+ (ppc64_elf_link_hash_table_create): Init them.
+ (ppc_stub_name): Correct string size.
+ (ppc64_elf_check_relocs): Set has_gp_reloc on GOT and TOC relocs.
+ (ppc64_elf_size_dynamic_sections): Set no_multi_toc if GOT entries
+ used.
+ (ppc_type_of_stub): Tweak root.type test.
+ (build_plt_stub): Remove glink code. Adjust for insn macro changes.
+ (ppc_size_one_stub): Handle ppc_stub_long_branch_r2off and
+ ppc_stub_plt_branch_r2off.
+ (ppc_build_one_stub): Likewise. Fix var shadowing. Correct addis,addi
+ range test. Use toc_off to calculte r2 values. Handle emit_stub_syms.
+ (ppc64_elf_setup_section_lists): Remove htab creator flavour test.
+ Initialize elf_gp and toc_curr.
+ (ppc64_elf_next_toc_section, ppc64_elf_reinit_toc): New functions.
+ (ppc64_elf_next_input_section): Set toc_off.
+ (group_sections): Ensure groups have the same TOC.
+ (ppc64_elf_size_stubs): Check whether we need a TOC adjusting stub.
+ (ppc64_elf_build_stubs): Add emit_stub_syms param, and stash in htab.
+ Build new glink stub.
+ (ppc64_elf_relocate_section): Handle multiple TOCs. Fix comments.
+ (ppc64_elf_finish_dynamic_sections): Adjust DT_PPC64_GLINK.
+ * elf64-ppc.h (ppc64_elf_build_stubs): Update prototype.
+ (ppc64_elf_next_toc_section, ppc64_elf_reinit_toc): Declare.
+ * section.c (struct sec): Rename flag12 to has_gp_reloc.
+ (STD_SECTION): Update.
+ * ecoff.c (bfd_debug_section): Update comment.
+ * bfd-in2.h: Regenerate.
+
+2003-06-05 Daniel Jacobowitz <drow@mvista.com>
+
+ * elfcode.h (elf_slurp_reloc_table_from_section): Don't dereference
+ NULL function pointers.
+
+2003-06-05 Daniel Jacobowitz <drow@mvista.com>
+
+ * simple.c (bfd_simple_get_relocated_section_contents): Call
+ _bfd_generic_link_add_symbols instead of bfd_link_add_symbols.
+
+2003-06-04 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * coff-tic54x.c: Removed the ticoff0_bad_format_hook() and
+ ticoff1_bad_format_hook() functions. Removed the coff0 and coff1
+ swaptables.
+ * coff-tic4x.c: Ditto
+ * coffcode.h: Added extra arguments to CREATE_BIG_COFF_TARGET_VEC
+ and CREATE_LITTLE_COFF_TARGET_VEC. Created the macro
+ CREATE_BIGHDR_COFF_TARGET_VEC. Created the ticoff0_bad_format_hook(),
+ ticoff1_bad_format_hook() functions. Created the coff0 and coff1
+ swap tables.
+ * coff-tic4x.c: Adopted new CREATE_xxx_COFF_TARGET_VEC macros.
+ * coff-a29k.c: Append COFF_SWAP_TABLE argument
+ * coff-apollo.c: Ditto
+ * coff-arm.c: Ditto
+ * coff-h8300.c: Ditto
+ * coff-h8500.c: Ditto
+ * coff-i960.c: Ditto
+ * coff-m68k.c: Ditto
+ * coff-m88k.c: Ditto
+ * coff-mcore.c: Ditto
+ * coff-sh.c: Ditto
+ * coff-sparc.c: Ditto
+ * coff-tic80.c: Ditto
+ * coff-we32k.c: Ditto
+ * coff-z8k.c: Ditto
+ * coff-w65.c: Ditto
+
+2003-06-04 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * coff-tic4x.c (ticoff0_swap_table, ticoff1_swap_table): Fixed
+ initialization bug
+
+2003-06-03 Jakub Jelinek <jakub@redhat.com>
+
+ * elf.c (_bfd_elf_print_private_bfd_data): Handle PT_GNU_STACK.
+ (bfd_section_from_phdr): Likewise.
+ (map_sections_to_segments): Create PT_GNU_STACK segment header.
+ (get_program_header_size): Count with PT_GNU_STACK.
+ * elf-bfd.h (struct elf_obj_tdata): Add stack_flags.
+ * elflink.h (bfd_elfNN_size_dynamic_sections): Set stack_flags.
+
+2003-06-03 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elflink.h (elf_link_input_bfd): Call linker error_handler
+ for discarded definitions.
+
+2003-06-03 Elias Athanasopoulos <elathan@phys.uoa.gr>
+
+ * syms.c (decode_section_type): Return 'n' if section flags are
+ SEC_HAS_CONTENTS && SEC_READONLY.
+
+2003-06-03 Nick Clifton <nickc@redhat.com>
+
+ * elf32-v850.c (v850_elf_howto_t): Rename R_V850_32to
+ R_V850_ABS32. Add entry for R_V850_REL32.
+ (v850_elf_reloc_map): Likewise.
+ (v850_elf_check_relocs): Likewise.
+ (v850_elf_perform_relocation): Likewise.
+ (v850_elf_final_link_relocate): Likewise. Include computation
+ to make R_V850_REl32 pc-relative.
+
+2003-06-03 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * elf32-sh.c (sh_elf_size_dynamic_sections): Create .interp section
+ and DT_DEBUG dynamic tag even for position independent executables.
+ * elf64-sh64.c (sh64_elf64_size_dynamic_sections): Likewize.
+
+2003-06-02 Daniel Jacobowitz <drow@mvista.com>
+
+ * config.bfd: Move obsolete entries out of the range of the
+ targmatch sed script.
+
+2003-06-02 Daniel Jacobowitz <drow@mvista.com>
+
+ * config.bfd (mips*-dec-bsd*, mips*-*-pe*): Mark as obsolete.
+
+2003-05-31 Jakub Jelinek <jakub@redhat.com>
+
+ * elf32-ppc.c (allocate_dynrelocs): Use single slot for first 8192
+ plt entries, not just 8191.
+
+2003-05-30 Daniel Jacobowitz <drow@mvista.com>
+
+ * elfxx-mips.c (_bfd_mips_elf_discard_info): Correct loop index.
+ Reported by Ken Faiczak <kfaiczak@SANDVINE.com>.
+
+2003-05-30 Ulrich Drepper <drepper@redhat.com>
+ Jakub Jelinek <jakub@redhat.com>
+
+ * elflink.h (elf_link_add_object_symbols): Use !info->executable
+ instead of info->shared where appropriate.
+ (bfd_elfNN_size_dynamic_sections, elf_link_output_extsym): Likewise.
+ * elflink.c (_bfd_elf_create_got_section): Likewise.
+ (_bfd_elf_link_create_dynamic_sections): Likewise.
+ (_bfd_elf_link_assign_sym_version): Likewise.
+ * elf32-i386.c (elf_i386_size_dynamic_sections): Create .interp section
+ and DT_DEBUG dynamic tag even for position independent executables.
+ * elf32-ppc.c (ppc_elf_size_dynamic_sections): Likewise.
+ * elf32-s390.c (elf_s390_size_dynamic_sections: Likewise.
+ * elf64-ppc.c (ppc64_elf_size_dynamic_sections: Likewise.
+ * elf64-s390.c (elf_s390_size_dynamic_sections: Likewise.
+ * elf64-x86-64.c (elf64_x86_64_size_dynamic_sections: Likewise.
+ * elfxx-ia64.c (elfNN_ia64_size_dynamic_sections: Likewise.
+ * elf32-sparc.c (elf32_sparc_size_dynamic_sections: Likewise.
+ * elf64-alpha.c (elf64_alpha_size_dynamic_sections: Likewise.
+ * elf64-sparc.c (sparc64_elf_size_dynamic_sections: Likewise.
+
+2003-05-30 Kris Warkentin <kewarken@qnx.com>
+
+ * elf.c (elfcore_grok_nto_status): Only set lwpid for the active or
+ signalled thread.
+ (elfcore_grok_nto_gregs): Only make .reg section for the active thread.
+
+2003-05-29 Nick Clifton <nickc@redhat.com>
+
+ * pef.c: Include "safe-ctype.h" instead of <ctype.h>.
+ Tidy up formatting.
+ * Makefile.am: Add dependency on safe-ctype.h.
+ * Makefile.in: Regenerate.
+
+2003-05-29 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elfxx-mips.c: Don't force symbols local unconditionally.
+
+2003-05-28 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-hppa.c (elf32_hppa_relocate_section): Delete bogus
+ undefined_symbol call.
+
+2003-05-27 Richard Sandiford <rsandifo@redhat.com>
+
+ * elfxx-mips.c (mips_elf_hash_sort_data): Fix formattting.
+ (mips_elf_link_hash_table): Likewise.
+
+2003-05-22 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elf64-mips.c (elf_mips_gnu_rel16_s2): Add internally used
+ R_MIPS_GNU_REL16_S2 support.
+ (bfd_elf64_bfd_reloc_type_lookup): Use it.
+ (mips_elf64_rtype_to_howto): Use it.
+ * elfn32-mips.c (elf_mips_gnu_rel16_s2): Add internally used
+ R_MIPS_GNU_REL16_S2 support.
+ (bfd_elf32_bfd_reloc_type_lookup): Use it.
+ (mips_elf_n32_rtype_to_howto): Use it.
+
+2003-05-21 Stuart F. Downing <sdowning@fame.com>
+
+ * som.h: Define PA_2_0 before including a.out.h
+
+2003-05-07 Eric Christopher <echristo@redhat.com>
+ Alexandre Oliva <aoliva@redhat.com>
+
+ * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Adjust
+ pic tests, change to warning.
+ (_bfd_mips_elf_final_link): Remove EF_MIPS_CPIC flag setting.
+
+2003-05-21 Marcus Comstedt <marcus@mc.pp.se>
+
+ * config.bfd: Check for a target triplet of shl-...-netbsdelf as
+ well as shle-...-netbsdelf. Remove duplicate entry.
+
+2003-05-21 Nick Clifton <nickc@redhat.com>
+
+ * elf32-xstormy16.c (xstormy16_elf_howto_table): Fix dst_mask
+ for X_STORMY16_REL_12 reloc.
+
+ * elf.c (bfd_elf_get_needed_list): Use is_elf_hash_table to check
+ the type of the hash table in the bfd_link_info structure.
+ (bfd_elf_get_runpath_list): Likewise.
+
+2003-05-19 Roland McGrath <roland@redhat.com>
+
+ * elf.c (bfd_elf_bfd_from_remote_memory): New function.
+ * bfd-in.h: Declare it.
+ * bfd-in2.h: Regenerated.
+ * elfcode.h (NAME(_bfd_elf,bfd_from_remote_memory)): New function.
+ * elf-bfd.h (struct elf_backend_data): New function pointer member
+ elf_backend_bfd_from_remote_memory.
+ (_bfd_elf32_bfd_from_remote_memory, _bfd_elf64_bfd_from_remote_memory):
+ Declare them.
+ * elfxx-target.h (elf_backend_bfd_from_remote_memory): New macro.
+ (elfNN_bed): Add that to the initializer.
+
+2003-05-15 Roland McGrath <roland@redhat.com>
+
+ * elf.c (elfcore_grok_note): Grok NT_AUXV note, make ".auxv" section.
+
+2003-05-20 Jakub Jelinek <jakub@redhat.com>
+
+ * elflink.h (elf_link_output_extsym): Only issue error about !=
+ STV_DEFAULT symbols if they are bfd_link_hash_undefined.
+
+2003-05-20 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elflink.c (_bfd_elf_merge_symbol): Check ELF_LINK_DYNAMIC_DEF
+ when removing the old definition for symbols with non-default
+ visibility.
+
+2003-05-18 Jason Eckhardt <jle@rice.edu>
+
+ * elf32-i860.c (elf32_i860_relocate_highadj): Simplify calculation.
+
+2003-05-17 Andreas Schwab <schwab@suse.de>
+
+ * elf32-m68k.c (elf_m68k_check_relocs): Cache reloc section in
+ elf_section_data during processing of pc-relative and absolute
+ relocations.
+ (elf_m68k_relocate_section): Use the cached reloc section instead
+ of computing it again. Fix handling of visibility. Don't modify
+ addend when copying over a relocation into the output.
+
+2003-05-17 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-i386.c (elf_i386_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL
+ to trim plt entries. Move undefweak non-default visibility test..
+ (allocate_dynrelocs): ..from here.
+ * elf32-ppc.c (ppc_elf_adjust_dynamic_symbol): Don't test
+ dynamic_sections_created here. Update comment. Move undefweak
+ non-default visibility test..
+ (allocate_dynrelocs): ..from here. Fix comment.
+ * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Use SYMBOL_CALLS_LOCAL
+ to trim plt entries. Move undefweak non-default visibility test..
+ (allocate_dynrelocs): ..from here. Fix comment.
+ * elflink.h (elf_link_output_extsym): Compare ELF_ST_VISIBILITY with
+ STV_DEFAULT rather than comparing with zero.
+ * elflink.c (_bfd_elf_merge_symbol): Likewise.
+ (_bfd_elf_fix_symbol_flags): Likewise. Format comment.
+
+2003-05-17 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * bfd.c (_bfd_get_gp_value): Prevent illegal access for abfd null
+ pointers.
+ (_bfd_set_gp_value): Likewise.
+
+2003-05-16 Michael Snyder <msnyder@redhat.com>
+ From Bernd Schmidt <bernds@redhat.com>
+ * archures.c (bfd_mach_h8300sx): New.
+ * bfd-in2.h: Regenerate.
+ * cpu-h8300.c (h8300_scan)): Add support for h8300sx.
+ (h8300sx_info_struct): New.
+ (h8300s_info_struct): Link to it.
+ * elf32-h8300.c (elf32_h8_mach): Add support for h8300sx.
+ (elf32_h8_final_write_processing): Likewise.
+ (elf32_h8_relax_section): Likewise.
+
+2003-05-16 Kelley Cook <kelleycook@wideopenwest.com>
+
+ * config.bfd: Accept i[3-7]86 variants.
+ * configure.host: Likewise.
+ * configure.in: Likewise.
+ * configure: Regenerate.
+
+2003-05-15 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elflink.c (_bfd_elf_fix_symbol_flags): Also hide protected
+ symbol.
+
+2003-05-15 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elflink.h (elf_link_check_versioned_symbol): Also allow
+ the base version.
+
+2003-05-15 Alan Modra <amodra@bigpond.net.au>
+ H.J. Lu <hongjiu.lu@intel.com>
+
+ * elf32-i386.c (allocate_dynrelocs): Use SYMBOL_CALLS_LOCAL.
+ (elf_i386_relocate_section): Likewise.
+ * elf32-ppc.c (allocate_dynrelocs): Likewise.
+ (ppc_elf_relocate_section): Likewise.
+ * elf64-ppc.c (allocate_dynrelocs): Likewise.
+ (ppc64_elf_relocate_section): Likewise.
+
+2003-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elf32-mips.c (gprel32_with_gp): Remove useless N64 ABI case.
+
+2003-05-13 Stephane Carrez <stcarrez@nerim.fr>
+
+ * elf32-m68hc1x.c (_bfd_m68hc11_elf_merge_private_bfd_data): Check for
+ processor capability, allow merge of HC12 and HCS12 in some cases.
+ (m68hc11_elf_hash_table_create): Use bfd_malloc instead of bfd_zalloc.
+ * cpu-m68hc12.c (bfd_m68hc12s_arch): New struct.
+ (bfd_m68hc12_arch): Link it.
+ (scan_mach): New function.
+
+2003-05-13 Andrew Haley <aph@redhat.com>
+
+ * elf.c (bfd_elf_hash): Mask lower 32 bits of hash.
+
+2003-05-13 Alan Modra <amodra@bigpond.net.au>
+ H.J. Lu <hongjiu.lu@intel.com>
+
+ * elf-bfd.h (SYMBOL_REFERENCES_LOCAL, SYMBOL_CALLS_LOCAL): Move from
+ elf32-ppc.c. Add ELF_LINK_FORCED_LOCAL check.
+ * elf32-ppc.c: (SYMBOL_REFERENCES_LOCAL, SYMBOL_CALLS_LOCAL): Delete.
+ (allocate_dynrelocs): Use SYMBOL_REFERENCES_LOCAL for dynreloc check.
+ (ppc_elf_relocate_section): Likewise.
+ * elf64-ppc.c (allocate_dynrelocs): Likewise.
+ (ppc64_elf_relocate_section): Likewise. Use for .got relocs too.
+ (ppc64_elf_adjust_dynamic_symbol): Don't assume symbols with .plt
+ relocs need no other types.
+ * elf32-i386.c (allocate_dynrelocs): Use SYMBOL_REFERENCES_LOCAL for
+ dynreloc check.
+ (elf_i386_relocate_section): Likewise. Use for .got relocs too.
+ (elf_i386_finish_dynamic_symbol): Use SYMBOL_REFERENCES_LOCAL for
+ .got relocs.
+
+2003-05-13 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * elf32-sh.c (sh_elf_adjust_dynamic_symbol): For weak symbols,
+ copy ELF_LINK_NON_GOT_REF from weakdef.
+ (allocate_dynrelocs): For undef weak syms with non-default
+ visibility, a) don't allocate plt entries, b) don't allocate
+ .got relocs, c) discard dyn rel space
+ (sh_elf_relocate_section): d) don't generate .got relocs, e)
+ don't generate dynamic relocs.
+ (sh_elf_copy_indirect_symbol): Don't copy ELF_LINK_NON_GOT_REF
+ for weakdefs when symbol already adjusted.
+
+2003-05-12 Nick Clifton <nickc@redhat.com>
+
+ * elf32-xstormy16.c (xstormy16_elf_howto_table): use 'bitfield'
+ overflow detection for R_XSTORMY16_16 reloc.
+
+2003-05-12 Paul Clarke <paulc@senet.com.au>
+
+ * elf32-h8300.c: Fix typo in name of R_H8_DIR8 reloc.
+
+2003-05-11 Jason Eckhardt <jle@rice.edu>
+
+ * elf32-i860.c (elf32_i860_relocate_highadj): Properly
+ adjust upper bits.
+ (elf32_i860_relocate_splitn): Obtain upper 5 bits from the
+ proper place.
+ (elf32_i860_relocate_pc16): Obtain upper 5 bits from the
+ proper place.
+
+2003-05-11 Andreas Schwab <schwab@suse.de>
+
+ * elf32-m68k.c (elf_m68k_relocate_section): Replace ugly
+ complicated tests for unresolvable relocs with a simple direct
+ scheme using "unresolved_reloc" var. Report some detail on
+ bfd_reloc_outofrange and similar errors.
+
+2003-05-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * elf32-s390.c (allocate_dynrelocs, elf_s390_relocate_section):
+ Fix WILL_CALL_FINISH_DYNAMIC_SYMBOL call.
+ (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Pass SHARED instead of INFO.
+ * elf64-s390.c: Likewise.
+
+2003-05-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * elf32-s390.c (ELIMINATE_COPY_RELOCS): Define as one.
+ (elf_s390_adjust_dynamic_symbol): For weak symbols, copy
+ ELF_LINK_NON_GOT_REF from weakdef.
+ (elf_s390_copy_indirect_symbol): Test whether the weakdef sym has
+ already been adjusted before treating it specially.
+ * el64-s390.c: Likwise.
+
+2003-05-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * elf32-s390.c (allocate_dynrelocs): For undef weak syms with
+ non-default visibility, a) don't make them dynamic, b) discard
+ space for dynamic relocs.
+ (elf_s390_relocate_section): Initialize the GOT entries and skip
+ R_390_{8,16,32}/R_390_PC{16,16DBL,32DBL,32} for weak undefined
+ symbols with non-default visibility.
+ * elf64-s390.c: Likewise.
+
+2003-05-09 Alan Modra <amodra@bigpond.net.au>
+
+ * cpu-arm.c (arm_check_note): Warning fix.
+ * elf32-iq2000.c (iq2000_elf_check_relocs): Warning fixes. Arrange
+ to keep relocs if edited.
+ (iq2000_elf_print_private_bfd_data): Return TRUE.
+ * elfxx-ia64.c (elfNN_ia64_relax_section): Use ELFNN_R_SYM, not
+ ELF64_R_SYM.
+ (elfNN_ia64_relax_ldxmov): Warning fix.
+ * xtensa-isa.c (xtensa_add_isa): Warning fix.
+ * xtensa-modules.c (get_num_opcodes): Warning fix.
+
+2003-05-09 Andrey Petrov <petrov@netbsd.org>
+
+ * elf.c (elf_fake_sections): Use correct cast for sh_name.
+
+2003-05-09 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.c (_bfd_elf_link_create_dynamic_sections): Move from
+ elflink.h. Replace LOG_FILE_ALIGN with bed->s->log_file_align.
+ (_bfd_elf_create_dynamic_sections): Use bed->s->log_file_align.
+ (bfd_elf_record_link_assignment): Move from elflink.h.
+ (_bfd_elf_merge_symbol): Likewise.
+ (_bfd_elf_add_default_symbol): Likewise.
+ (_bfd_elf_export_symbol): Likewise.
+ (_bfd_elf_link_find_version_dependencies): Likewise.
+ (_bfd_elf_link_assign_sym_version): Likewise.
+ (_bfd_elf_link_read_relocs): Likewise.
+ (_bfd_elf_link_size_reloc_section): Likewise.
+ (_bfd_elf_fix_symbol_flags): Likewise.
+ (_bfd_elf_adjust_dynamic_symbol): Likewise.
+ (_bfd_elf_link_sec_merge_syms): Likewise.
+ (elf_link_read_relocs_from_section): Likewise. Use bed->s->sizeof_rel
+ and bed->s->sizeof_rela.
+ (_bfd_elf_link_output_relocs): Likewise.
+ * elf-bfd.h (struct elf_size_info): Rename file_align to
+ log_file_align.
+ (struct elf_info_failed): Move from elflink.h.
+ (struct elf_assign_sym_version_info): Likewise.
+ (struct elf_find_verdep_info): Likewise.
+ (_bfd_elf_create_dynamic_sections): Delete duplicate declaration.
+ (_bfd_elf_merge_symbol, _bfd_elf_add_default_symbol,
+ _bfd_elf_export_symbol, _bfd_elf_link_find_version_dependencies,
+ _bfd_elf_link_assign_sym_version,
+ _bfd_elf_link_create_dynamic_sections, _bfd_elf_link_read_relocs,
+ _bfd_elf_link_size_reloc_section, _bfd_elf_link_output_relocs,
+ _bfd_elf_fix_symbol_flags, _bfd_elf_adjust_dynamic_symbol,
+ _bfd_elf_link_sec_merge_syms): Declare.
+ (bfd_elf32_link_create_dynamic_sections): Don't declare.
+ (_bfd_elf32_link_read_relocs): Likewise.
+ (bfd_elf64_link_create_dynamic_sections): Likewise.
+ (_bfd_elf64_link_read_relocs): Likewise.
+ * elflink.h: Move lots o' stuff elsewhere.
+ * bfd-in.h (bfd_elf32_record_link_assignment): Don't declare.
+ (bfd_elf64_record_link_assignment): Likewise.
+ (bfd_elf_record_link_assignment): Declare.
+ * bfd-in2.h: Regenerate.
+ * elfcode.h (elf_link_create_dynamic_sections): Don't declare.
+ (NAME(_bfd_elf,size_info)): Adjust for log_file_align.
+ * elf.c (_bfd_elf_init_reloc_shdr): Adjust for bed->s->log_file_align.
+ (assign_file_positions_for_segments): Likewise.
+ (assign_file_positions_except_relocs): Likewise.
+ (swap_out_syms, elfcore_write_note): Likewise.
+ * elf-m10200.c: Adjust for changed function names.
+ * elf-m10300.c: Likewise.
+ * elf32-arm.h: Likewise.
+ * elf32-h8300.c: Likewise.
+ * elf32-hppa.c: Likewise.
+ * elf32-ip2k.c: Likewise.
+ * elf32-m32r.c: Likewise.
+ * elf32-m68hc11.c: Likewise.
+ * elf32-m68hc1x.c: Likewise.
+ * elf32-m68k.c: Likewise.
+ * elf32-mips.c: Likewise.
+ * elf32-ppc.c: Likewise.
+ * elf32-sh.c: Likewise.
+ * elf32-v850.c: Likewise.
+ * elf32-xtensa.c: Likewise.
+ * elf64-alpha.c: Likewise.
+ * elf64-hppa.c: Likewise.
+ * elf64-mmix.c: Likewise.
+ * elf64-ppc.c: Likewise.
+ * elf64-sh64.c: Likewise.
+ * elfxx-ia64.c: Likewise.
+ * elfxx-mips.c: Likewise.
+ (MIPS_ELF_LOG_FILE_ALIGN): Use log_file_align.
+ * elf64-alpha.c (alpha_elf_size_info): Adjust for log_file_align.
+ * elf64-hppa.c (hppa64_elf_size_info): Likewise.
+ * elf64-mips.c (mips_elf64_size_info): Likewise.
+ * elf64-s390.c (s390_elf64_size_info): Likewise.
+ * elf64-sparc.c (sparc64_elf_size_info): Likewise.
+
+2003-05-08 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elflink.h (elf_add_default_symbol): After skipping the
+ unversioned symbol, go to non-default one.
+
+2003-05-07 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elfxx-ia64.c (_bfd_elf_link_hash_hide_symbol): Also clear the
+ want_plt field.
+ (elfNN_ia64_relocate_section): Don't do dynamic symbol lookup
+ for symbols with non-default visibility.
+
+2003-05-07 H.J. Lu <hongjiu.lu@intel.com>
+
+ * elflink.h (elf_link_check_versioned_symbol): Also handle the
+ case that a DSO references a hidden symbol which may be
+ satisfied by a versioned symbol in another DSO.
+ (elf_link_output_extsym): Check versioned definition for hidden
+ symbol referenced by a DSO.
+
+2003-05-07 Nick Clifton <nickc@redhat.com>
+
+ * elf32-xstormy16.c (xstormy16_elf_howto_table): Reset
+ R_XSTORMY16_16 reloc to ignore overflows.
+
+2003-05-06 Alexandre Oliva <aoliva@redhat.com>
+
+ * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Improve
+ error message for mixing different-endian files. Check for ABI
+ compatibility of input files with the selected emulation.
+
+2003-05-05 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-i386.c (allocate_dynrelocs): For undef weak syms with
+ non-default visibility, a) don't make them dynamic, b) discard
+ space for dynamic relocs.
+ * elf64-x86-64.c (allocate_dynrelocs): Likewise.
+
+ * elf32-ppc.c (allocate_dynrelocs): For undef weak syms with
+ non-default visibility, a) don't allocate plt entries, b) don't
+ allocate .got relocs, c) discard dyn rel space,
+ (ppc_elf_relocate_section): d) don't generate .got relocs, e)
+ don't generate dynamic relocs.
+ * elf64-ppc.c (allocate_dynrelocs): As above.
+ (ppc64_elf_relocate_section): As above.
+
+2003-05-05 Andreas Jaeger <aj@suse.de>
+
+ * elf64-x86-64.c (allocate_dynrelocs): Don't allocate dynamic
+ relocation entries for weak undefined symbols with non-default
+ visibility.
+ (elf64_x86_64_relocate_section): Initialize the GOT entries and
+ skip R_386_32/R_386_PC32 for weak undefined symbols with
+ non-default visibility.
+
+2003-05-04 H.J. Lu <hjl@gnu.org>
+
+ * elf32-i386.c (allocate_dynrelocs): Don't allocate dynamic
+ relocation entries for weak undefined symbols with non-default
+ visibility.
+ (elf_i386_relocate_section): Initialize the GOT entries and
+ skip R_386_32/R_386_PC32 for weak undefined symbols with
+ non-default visibility.
+
+ * elfxx-ia64.c (allocate_fptr): Don't allocate function
+ descriptors for weak undefined symbols with non-default
+ visibility.
+ (allocate_dynrel_entries): Don't allocate relocation entries
+ for symbols resolved to 0.
+ (set_got_entry): Don't install dynamic relocation for weak
+ undefined symbols with non-default visibility.
+ (set_pltoff_entry): Likewise.
+
+ * elflink.h (elf_fix_symbol_flags): Hide weak undefined symbols
+ with non-default visibility.
+ (elf_link_output_extsym): Don't make weak undefined symbols
+ with non-default visibility dynamic.
+
+2003-05-04 H.J. Lu <hjl@gnu.org>
+
+ * elflink.h (elf_merge_symbol): Correctly handle weak definition.
+
+2003-05-04 H.J. Lu <hjl@gnu.org>
+
+ * elflink.h (elf_merge_symbol): Don't record a hidden/internal
+ symbol dynamic. Check indirection when removing the old
+ definition for symbols with non-default visibility.
+ (elf_add_default_symbol): Skip when told by elf_merge_symbol.
+
+2003-05-02 Nick Clifton <nickc@redhat.com>
+
+ * elf32-xstormy16.c (xstormy16_elf_howto_table): Make the
+ R_XSTORMY16_8 and R_XSTORMY16_16 relocs detect and complain about
+ unsigned overflow.
+
+2003-05-02 Andreas Jaeger <aj@suse.de>
+
+ * elf64-x86-64.c (elf_x86_64_copy_indirect_symbol): Don't copy
+ ELF_LINK_NON_GOT_REF for weakdefs when symbol already adjusted.
+ (ELIMINATE_COPY_RELOCS): Define as one. Use throughout.
+ (elf_x86_64_adjust_dynamic_symbol): For weak symbols, copy
+ ELF_LINK_NON_GOT_REF from weakdef.
+
+2003-05-02 Charles Lepple <clepple@ghz.cc>
+ Nick Clifton <nickc@redhat.com>
+
+ * acinclude.m4: Fix name of --enable-install-libbfd switch.
+ * aclocal.m4: Regenerate.
+ * configure: Regenerate.
+ * Makefile.in: Regenerate.
+
+2003-05-01 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c (ppc_elf_copy_indirect_symbol): Test whether the
+ weakdef sym has already been adjusted before treating it specially.
+ * elf32-i386.c (elf_i386_copy_indirect_symbol): Don't copy
+ ELF_LINK_NON_GOT_REF for weakdefs when symbol already adjusted.
+ * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
+ (ppc64_elf_check_relocs): Set ELF_LINK_NON_GOT_REF.
+
+2003-04-28 H.J. Lu <hjl@gnu.org>
+
+ * elfxx-ia64.c (elfNN_ia64_relax_section): Relax ldxmov during
+ the relax finalize pass.
+
+ * section.c (struct sec): Add need_finalize_relax and remove
+ flag11.
+ (STD_SECTION): Update struct sec initializer.
+ * bfd-in2.h: Regenerated.
+
+2003-04-28 H.J. Lu <hjl@gnu.org>
+
+ * elflink.h (elf_merge_symbol): Call elf_backend_copy_indirect_symbol
+ to copy any information related to dynamic linking when we flip
+ the indirection.
+
+2003-04-27 H.J. Lu <hjl@gnu.org>
+
+ * elf-bfd.h (ELF_LINK_DYNAMIC_DEF): New.
+ (ELF_LINK_DYNAMIC_WEAK): New.
+
+ * elflink.h (elf_merge_symbol): Add one argument to indicate if
+ a symbol should be skipped. Ignore definitions in dynamic
+ objects for symbols with non-default visibility.
+ (elf_add_default_symbol): Adjusted.
+ (elf_link_add_object_symbols): Check if a symbol should be
+ skipped. Don't merge the visibility field with the one from
+ a dynamic object.
+ (elf_link_check_versioned_symbol): Use undef_bfd.
+ (elf_link_output_extsym): Warn if a forced local symbol is
+ referenced from dynamic objects. Make non-weak undefined symbol
+ with non-default visibility a fatal error.
+
+2003-04-27 Daniel Jacobowitz <drow@mvista.com>
+
+ * configure.in: Bump version on HEAD to 2.14.90.
+ * configure: Regenerated.
+
+2003-04-26 Stephane Carrez <stcarrez@nerim.fr>
+
+ PR savannah/3331:
+ * elf32-m68hc11.c (m68hc11_elf_relax_section): Clear prev_insn_group
+ when we couldn't relax something.
+
+2003-04-25 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h (elf_merge_symbol): When we find a regular definition
+ for an indirect symbol, flip the indirection so that the old
+ direct symbol now points to the new definition.
+
+2003-04-24 Roland McGrath <roland@redhat.com>
+
+ * elf.c (bfd_section_from_phdr): Map PT_GNU_EH_FRAME to "eh_frame_hdr".
+
+2003-04-24 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c: Formatting and comment fixes.
+ (ELIMINATE_COPY_RELOCS): Move before ppc_elf_copy_indirect_symbol.
+ (ppc_elf_copy_indirect_symbol): Copy flags here for weakdefs.
+
+2003-04-24 Dhananjay Deshpande <dhananjayd@kpitcummins.com>
+
+ * archures.c (bfd_mach_h8300hn, bfd_mach_h8300sn): Added.
+ * bfd-in2.h: Rebuilt.
+ * coff-h8300.c (BADMAG): Add check for H8300HNBADMAG & H8300SNBADMAG.
+ * coffcode.h (coff_set_arch_mach_hook): Add case for H8300HNMAGIC
+ & H8300SNMAGIC.
+ (coff_set_flags): Add case for bfd_mach_h8300hn & bfd_mach_h8300sn.
+ * cpu-h8300.c (h8300_scan): Handle h8300hn, h8300sn.
+ (h8300sn_info_struct, h8300hn_info_struct): New.
+ * elf32-h8300.c (elf32_h8_mach): Handle case for h8300hn & h8300sn
+ (elf32_h8_final_write_processing): Likewise.
+
+2003-04-23 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * elf32-sh.c (tpoff): New.
+ (struct elf_sh_dyn_relocs): Remove tls_tpoff32.
+ (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Pass SHARED instead of INFO.
+ (allocate_dynrelocs): Don't make unnecessary dynamic TLS
+ relocations. Adjust WILL_CALL_FINISH_DYNAMIC_SYMBOL uses.
+ (sh_elf_relocate_section): Likewise. Remove unnecessary tests.
+ (dtpoff_base): Fix wrong indentation.
+ (sh_elf_check_relocs): Don't set DF_STATIC_TLS flag with non-TLS
+ relocations. Don't set tls_tpoff32 flag. Don't make unnecessary
+ R_SH_TLS_TPOFF32 relocations.
+
+2003-04-23 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * archures.c (enum bfd_architecture): Amend comment to refer to SuperH.
+ * cpu-sh.c: Likewise.
+ * elf32-sh.c: Likewise.
+ * reloc.c (bfd_reloc_code_real): Likewise.
+ * elf32-sh64-com.c: Change comment to refer to SuperH.
+ * elf32-sh64.c: Likewise.
+ * elf64-sh64.c: Likewise.
+ * bfd-in2.h (enum bfd_architecture): Regenerate.
+
+2003-04-23 Alan Modra <amodra@bigpond.net.au>
+
+ From Julien LEMOINE <speedblue@debian.org>
+ * elf32-i386.c (elf_i386_info_to_howto): Delete.
+ (elf_info_to_howto): Define as elf_i386_info_to_howto_rel.
+
+2003-04-22 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
+
+ * archures.c: Replace references to Mitsubishi M32R with references
+ to Renesas M32R.
+ * relocs.c: Likewise.
+ * bfd-in2.h: Regenerate.
+
+2003-04-21 Richard Henderson <rth@redhat.com>
+
+ * elf64-alpha.c (alpha_elf_dynamic_symbol_p): Return false for an
+ executable when a symbol is defined both regular and dynamic.
+
+2003-04-21 Stephane Carrez <stcarrez@nerim.fr>
+
+ * Makefile.am (BFD32_BACKENDS): Add elf32-m68hc1x.lo.
+ (elf32-m68hc1x.lo): Update dependencies
+ * configure.in: Add elf32-m68hc1x.lo.
+ * configure: Rebuild.
+ * Makefile.in: Rebuild.
+
+2003-04-21 Stephane Carrez <stcarrez@nerim.fr>
+
+ * elf32-m68hc1x.c: New file (from elf32-m68hc11.c and elf32-m68hc12.c)
+ (m68hc11_elf_hash_table_create): New function.
+ (elf32_m68hc11_link_hash_table_free): New function.
+ (stub_hash_newfunc): New function.
+ (m68hc11_add_stub): New function.
+ (elf32_m68hc11_add_symbol_hook): New function.
+ (elf32_m68hc11_setup_section_lists): New function.
+ (elf32_m68hc11_next_input_section): New function.
+ (elf32_m68hc11_size_stubs): New function.
+ (elf32_m68hc11_build_stubs): New function.
+ (m68hc11_get_relocation_value): New function.
+ (elf32_m68hc11_relocate_section): Call the above to redirect
+ some relocations to the trampoline code.
+ (m68hc11_elf_export_one_stub): New function.
+ (m68hc11_elf_set_symbol): New function.
+ (elf32_m68hc11_build_stubs): Call it via bfd_hash_traverse.
+ (m68hc11_elf_get_bank_parameters): Get parameters only when the info
+ is not yet initialized.
+
+ * elf32-m68hc1x.h: New file (from elf32-m68hc11.c and elf32-m68hc12.c)
+ (elf32_m68hc11_stub_hash_entry): New struct.
+ (m68hc11_page_info): Add trampoline handler address.
+ (m68hc11_elf_link_hash_table): Add stubs generation members.
+ (elf32_m68hc11_add_symbol_hook): Declare.
+ (elf32_m68hc11_setup_section_lists): Declare.
+ (elf32_m68hc11_size_stubs): Declare.
+ (elf32_m68hc11_build_stubs): Declare.
+
+ * elf32-m68hc11.c (m68hc11_elf_ignore_reloc): Move to elf32-m68hc1x.c.
+ (elf32_m68hc11_gc_mark_hook, elf32_m68hc11_gc_sweep_hook): Likewise.
+ (elf32_m68hc11_check_relocs, elf32_m68hc11_relocate_section): Ditto.
+ (_bfd_m68hc11_elf_set_private_flags): Ditto.
+ (_bfd_m68hc11_elf_merge_private_bfd_data): Ditto.
+ (_bfd_m68hc11_elf_print_private_bfd_data): Ditto.
+ (bfd_elf32_bfd_link_hash_table_create): Define.
+ (elf_backend_add_symbol_hook): Define.
+ (m68hc11_elf_bfd_link_hash_table_create): New function.
+ (m68hc11_elf_build_one_stub): New function.
+ (m68hc11_elf_size_one_stub): New function.
+ (m68hc11_elf_bfd_link_hash_table_create): Install the above.
+ (bfd_elf32_bfd_link_hash_table_create): Define.
+
+ * elf32-m68hc12.c (m68hc11_elf_ignore_reloc): Remove.
+ (m68hc12_addr_is_banked): Remove, use m68hc11_addr_is_banked.
+ (m68hc12_phys_addr): Ditto.
+ (m68hc12_phys_page): Ditto.
+ (m68hc12_elf_special_reloc): Move to elf32-m68hc1x.c.
+ (elf32_m68hc11_gc_mark_hook): Likewise.
+ (elf32_m68hc11_gc_sweep_hook): Likewise.
+ (elf32_m68hc11_check_relocs): Likewise.
+ (elf32_m68hc11_relocate_section): Likewise.
+ (_bfd_m68hc12_elf_set_private_flags): Likewise.
+ (_bfd_m68hc12_elf_merge_private_bfd_data): Likewise.
+ (_bfd_m68hc12_elf_print_private_bfd_data): Likewise.
+ (m68hc12_elf_build_one_stub): New function.
+ (m68hc12_elf_size_one_stub): New function.
+ (m68hc12_elf_bfd_link_hash_table_create): New function, use the above.
+ (elf_backend_add_symbol_hook): Define.
+ (elf_m68hc11_howto_table): Use TRUE for pcrel relocs; fix masks.
+
+2003-04-18 Nick Clifton <nickc@redhat.com>
+
+ * format.c (bfd_check_format_matches): Only check associated
+ vector if the matching_vector has been created.
+
+2003-04-15 Alexandre Oliva <aoliva@redhat.com>
+
+ * dwarf2.c (_bfd_dwarf2_find_nearest_line): Fix typo in
+ 2003-04-09's change.
+
+2003-04-15 Brian Ford <ford@vss.fsi.com>
+
+ * peicode.h (coff_swap_scnhdr_in): If a section holds
+ uninitialized data and is from an object file or from an
+ executable image that has not initialized the s_size field, or if
+ the physical size is padded, use the virtual size (stored in
+ s_paddr) instead.
+
+2003-04-15 H.J. Lu <hjl@gnu.org>
+
+ * elflink.h (elf_link_add_object_symbols): Properly report
+ filename for alignment reduction.
+
+2003-04-15 Rohit Kumar Srivastava <rohits@kpitcummins.com>
+
+ * archures.c: Replace occurrances of 'Hitachi' with 'Renesas'.
+ * reloc.c: Likewise.
+ * coff-h8300.c: Likewise.
+ * coff-h8500.c: Likewise.
+ * coff-sh.c: Likewise.
+ * cpu-h8300.c: Likewise.
+ * cpu-sh.c: Likewise.
+ * elf32-h8300.c: Likewise.
+ * elf32-sh.c: Likewise.
+ * elf32-sh64-com.c: Likewise.
+ * elf32-sh64.c: Likewise.
+ * elf64-sh64.c: Likewise.
+ * bfd-in2.h: Regenerate.
+
+2003-04-14 H.J. Lu <hjl@gnu.org>
+
+ * elflink.h (elf_link_add_object_symbols): Maintain maximum
+ alignment for common symbols. Warn reducing alignment for
+ common symbols. Report old filename when symbol size changes.
+
+2003-04-12 Alexandre Oliva <aoliva@redhat.com>
+
+ * elfxx-mips.c (mips_elf_calculate_relocation): Adjust two other
+ occurrences of the same test changed in the previous patch.
+ Optimize.
+
+2003-04-11 Alexandre Oliva <aoliva@redhat.com>
+
+ * elfxx-mips.c (mips_elf_get_global_gotsym_index): New.
+ (mips_elf_calculate_relocation): Decay GOT_PAGE/GOT_OFST to
+ GOT_DISP/addend only if the symbol got a global GOT entry.
+
+2003-04-10 Alexandre Oliva <aoliva@redhat.com>
+
+ * elfxx-mips.c (mips_elf_calculate_relocation): Decay
+ GOT_PAGE/GOT_OFST referencing overridable symbol to
+ GOT_DISP/addend.
+ (_bfd_mips_elf_check_relocs): Handle GOT_PAGE referencing
+ global symbol as GOT_DISP.
+
+2003-04-10 Bob Wilson <bob.wilson@acm.org>
+
+ * elf32-xtensa.c (elf_xtensa_relocate_section): Don't continue to the
+ next relocation on an undefined symbol.
+
+2003-04-09 Richard Henderson <rth@redhat.com>
+
+ * elf64-alpha.c (elf64_alpha_relocate_section) <R_ALPHA_GPREL32>:
+ Ignore relocations against r_symndx == 0.
+
+2003-04-09 H.J. Lu <hjl@gnu.org>
+
+ * elf64-alpha.c (elf64_alpha_relocate_section): Don't return
+ FALSE for undefined symbols.
+ * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
+
+2003-04-09 Alexandre Oliva <aoliva@redhat.com>
+
+ * dwarf2.c (_bfd_dwarf2_find_nearest_line): Try DWARF3-standard
+ and IRIX-specific shift-to-64-bit 4-byte lengths before following
+ addr_size.
+
+2003-04-08 Alexandre Oliva <aoliva@redhat.com>
+
+ * elf32-mips.c (bfd_elf32_bfd_reloc_type_lookup): Detect (ctor)
+ pointer size from ABI, not arch_bits_per_address.
+
+2003-04-07 Kevin Buettner <kevinb@redhat.com>
+
+ * elfn32-mips.c (elf32_mips_grok_prstatus): Adjust core file related
+ constants for n32 ABI.
+
+2003-04-06 Andrew Cagney <cagney@redhat.com>
+
+ * simple.c (bfd_simple_get_relocated_section_contents): Disable
+ free that leads to GDB vs BFD memory corruption.
+
+2003-04-04 Stephane Carrez <stcarrez@nerim.fr>
+
+ * elf32-m68hc11.c (m68hc11_elf_relax_delete_bytes): Also adjust
+ symbols that mark the end of the section.
+ (m68hc11_elf_relax_section): Use R_M68HC11_PCREL_8 relocs when
+ converting to a relative branch so that the offset is computed after
+ the relaxation; also relocate a jsr into a bsr if possible but don't
+ relax them if they are to a far symbol as we need to call the
+ trampoline code.
+ (elf_m68hc11_howto_table): Set pcrel_offset to true.
+
+2003-04-04 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * archures.c: Namespace cleanup. Rename bfd_mach_c3x to
+ bfd_mach_tic3x and bfd_mach_c4x to bfd_mach_tic4x
+ * bfd-in2.h: Regenerate
+ * coff-tic4x.c: Namespace cleanup. Replace s/c4x/tic4x/
+ * cpu-tic4x.c: Ditto
+
+2003-04-03 Nick Clifton <nickc@redhat.com>
+
+ * peXXigen.c (_bfd_XXi_swap_scnhdr_out): Compute ps and ss
+ differently for object files and executables.
+ * peicode.h (coff_swap_scnhdr_in): Only set the s_size field
+ for object files or for executables who have not already
+ initialised the field.
+ * libpei.h (bfd_pe_executable_p): New macro. Return true if
+ the PE format bfd is an executable.
+
+2003-04-03 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c (ppc_elf_check_relocs): Don't use SYMBOL_REFERENCES_LOCAL
+ here as it's too early to reliably determine locality.
+ (ppc_elf_gc_sweep_hook): Likewise.
+ (SYMBOL_REFERENCES_LOCAL): Expand comment.
+
+2003-04-02 Bob Wilson <bob.wilson@acm.org>
+
+ * xtensa-modules.c: Remove comment indicating that this is a
+ generated file.
+
+2003-04-02 Alan Modra <amodra@bigpond.net.au>
+
+ * elfxx-mips.c (_bfd_mips_elf_hide_symbol): Test for NULL dynobj.
+
+2003-04-01 Bob Wilson <bob.wilson@acm.org>
+
+ * Makefile.am (ALL_MACHINES): Add cpu-xtensa.lo.
+ (ALL_MACHINES_CFILES): Add cpu-xtensa.c.
+ (BFD32_BACKENDS): Add elf32-xtensa.lo, xtensa-isa.lo, and
+ xtensa-modules.lo.
+ (BFD32_BACKENDS_CFILES): Add elf32-xtensa.c, xtensa-isa.c, and
+ xtensa-modules.c.
+ (cpu-xtensa.lo): New target.
+ (elf32-xtensa.lo): Likewise.
+ (xtensa-isa.lo): Likewise.
+ (xtensa-modules.lo): Likewise.
+ * Makefile.in: Regenerate.
+ * archures.c (bfd_architecture): Add bfd_{arch,mach}_xtensa.
+ (bfd_archures_list): Add bfd_xtensa_arch.
+ * config.bfd: Handle xtensa-*-*.
+ * configure.in: Handle bfd_elf32_xtensa_{le,be}_vec.
+ * configure: Regenerate.
+ * reloc.c: Add BFD_RELOC_XTENSA_{RTLD,GLOB_DAT,JMP_SLOT,RELATIVE,
+ PLT,OP0,OP1,OP2,ASM_EXPAND,ASM_SIMPLIFY}.
+ * targets.c (bfd_elf32_xtensa_be_vec): Declare.
+ (bfd_elf32_xtensa_le_vec): Likewise.
+ (bfd_target_vector): Add bfd_elf32_xtensa_{be,le}_vec.
+ * cpu-xtensa.c: New file.
+ * elf32-xtensa.c: Likewise.
+ * xtensa-isa.c: Likewise.
+ * xtensa-modules.c: Likewise.
+ * libbfd.h: Regenerate.
+ * bfd-in2.h: Likewise.
+
+2003-04-01 Nick Clifton <nickc@redhat.com>
+
+ * archures.c (bfd_mach_arm_unknown): Define.
+ * bfd-in.h (bfd_arm_merge_machines, bfd_arm+update_notes,
+ bfd_arm_get_mach_from_notes): Prototype.
+ * bfd-in2.h: Regenerate.
+ * coff-arm.c (coff_arm_merge_private_bfd_data): Call
+ bfd_arm_merge_machines.
+ (coff_arm_final_link_postscript): Call bfd_arm_update_notes.
+ * coffcode.h (coff_set_arch_mach_hook): Call
+ bfd_arm_get_mach_from_notes.
+ * coffgen.c (coff_real_object_p): Revert previous delta.
+ * cpu_arm.c (arm_check_note): New function. Examine a note in a
+ .note section.
+ (bfd_arm_merge_machines): New function: Handle the merging of ARM
+ binaries compiled for different architectures..
+ (bfd_arm_update_notes): New function: Update an ARM note section.
+ (bfd_arm_get_mach_from_notes): New function: Extract a bfd machine
+ number from an ARM note section.
+ * elf32-arm.h (elf32_arm_object_p): Use
+ bfd_arm_get_mach_from_notes.
+ (elf32_arm_merge_private_bfd_data): Use bfd_arm_merge_machines.
+ (elf32_arm_final_write_processing): Use bfd_arm_update_notes.
+
+2003-04-01 Ben Elliston <bje@wasabisystems.com>
+
+ * dwarf2.c (read_attribute_value): Correct typo in comment.
+
+2003-04-01 Nick Clifton <nickc@redhat.com>
+
+ * dwarf2.c (concat_filename): Use bfd_malloc() and strdup()
+ instead of concat().
+ (decode_line_info): Only free filename if it is not NULL.
+ (add_line_info): Make a copy of the filename when storing it into
+ the info structure.
+
+2003-03-31 Andreas Schwab <schwab@suse.de>
+ Daniel Jacobowitz <drow@mvista.com>
+
+ * simple.c (bfd_simple_get_relocated_section_contents): Add
+ parameter symbol_table. Optionally use it instead of the symbol
+ table from the bfd. Save and restore output offsets and output
+ sections around bfd_get_relocated_section_contents. Fix a memory
+ leak.
+ (simple_save_output_info, simple_restore_output_info): New
+ functions.
+ * bfd-in2.h: Regenerate.
+ * dwarf2.c (read_abbrevs): Use
+ bfd_simple_get_relocated_section_contents instead of
+ bfd_get_section_contents.
+ (decode_line_info): Likewise.
+ (_bfd_dwarf2_find_nearest_line): Likewise. Don't call
+ find_rela_addend.
+ (find_rela_addend): Remove.
+ * elfxx-ia64.c (elfNN_ia64_reloc): Weaken sanity check for
+ debugging sections.
+ (elfNN_ia64_hash_table_create): Create the hash table with malloc,
+ not bfd_zalloc.
+
+2003-03-31 David Heine <dlheine@suif.stanford.edu>
+
+ * aoutx.h (aout_link_hash_table_create): Use bfd_malloc instead of
+ bfd_alloc.
+ * dwarf2.c (concat_filename): Always allocate space for the
+ returned filename.
+ (decode_line_info): Free the allocated filename returned by
+ concat_filename.
+ * elf-eh-frame.c (bfd_elf_write_section_eh_frame): Fix memory leaks.
+ * elf.c (copy_private_bfd_data): Likewise.
+ (_bfd_elf_slurp_version_tables): Fix bug freeing contents pointer.
+ * elflink.h (elf_link_sort_relocs): Fix memory leak.
+ * format.c (bfd_check_format_matches): Likewise.
+ * linker.c (bfd_generic_final_link): Likewise.
+ * opncls.c (find_separate_debug_info): Likewise.
+ * simple.c (bfd_simple_get_relocated_section_contents): Likewise.
+
+2003-03-28 H.J. Lu <hjl@gnu.org>
+
+ * elflink.h (elf_link_add_object_symbols): Correctly combine
+ visibilities.
+
+2003-03-27 Jakub Jelinek <jakub@redhat.com>
+
+ * elfxx-ia64.c (elfNN_ia64_relax_section): Reset self_dtpmod_offset
+ to -1 before recomputing got offsets.
+
+2003-03-26 Andreas Schwab <schwab@suse.de>
+
+ * elf32-m68k.c (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
+ (elf_m68k_relocate_section): Use it to correctly handle symbols
+ forced to be local.
+ (elf_m68k_finish_dynamic_symbol): Emit RELATIVE reloc for got
+ entries for symbols that are forced to be local.
+
+2003-03-25 Alexandre Oliva <aoliva@redhat.com>
+
+ * elfxx-mips.c (_bfd_mips_relax_section): New function.
+ * elfxx-mips.h (_bfd_mips_relax_section): Declare.
+ * elfn32-mips.c, elf64-mips.c: Use it.
+
+2003-03-25 Stan Cox <scox@redhat.com>
+ Nick Clifton <nickc@redhat.com>
+
+ Contribute support for Intel's iWMMXt chip - an ARM variant:
+
+ * archures.c: Add bfd_mach_arm_iWMMXt.
+ * reloc.c: Add BFD_RELOC_ARM_CP_OFF_IMM_S2.
+ * bfd-in2.h: Regenerate.
+ * libbfd.h: Regenerate.
+ * coff-arm.c (coff_arm_merge_private_bfd_data): Allow iWMMXt
+ object files to be linked with XScale ones.
+ (coff_arm_final_link_postscript): Update note section.
+ * coffcode.h (coff_set_arch_mach_hook): Handle note section.
+ * coffgen.c (coff_real_object_p): Call bfd_coff_set_arch_mach_hook
+ after identifying a coff binary.
+ * cpu-arm.c (processors): Add iWMMXt.
+ (arch_inf): Likewise.
+ * elf32-arm.h (arm_object_p): Handle note section.
+ (elf32_arm_merge_private_bfd_data): Allow iWMMXt object files to
+ be linked with XScale ones.
+ (elf32_arm_section_flags): New function: Set flags on note section.
+ (elf32_arm_final_write_processing): Handle note section.
+
+2003-03-21 DJ Delorie <dj@redhat.com>
+
+ * elf32-xstormy16.c (elf32_xstormy16_relocate_section): Call
+ _bfd_elf_rela_local_sym.
+
+2003-03-20 H.J. Lu <hjl@gnu.org>
+
+ * elfxx-ia64.c (elfNN_ia64_relax_section): Don't try relax for
+ non-ELF outputs.
+
+2003-03-20 Nick Clifton <nickc@redhat.com>
+
+ * peXXigen.c (_bfd_XXi_swap_aouthdr_out): Initialise $idata2 and
+ $idata5 in case bfd_coff_final_link is not called.
+
+2003-03-19 Jakub Jelinek <jakub@redhat.com>
+
+ * elf64-sparc.c (struct sparc64_elf_section_data): Add reloc_count
+ field.
+ (canon_reloc_count): Define.
+ (sparc64_elf_slurp_one_reloc_table, sparc64_elf_slurp_reloc_table,
+ sparc64_elf_canonicalize_dynamic_reloc): Use it instead of
+ reloc_count.
+ (sparc64_elf_canonicalize_reloc): New routine.
+ (bfd_elf64_canonicalize_reloc): Define.
+
+2003-03-18 Jakub Jelinek <jakub@redhat.com>
+
+ * elfxx-ia64.c (elfNN_ia64_relax_section): Handle relaxation
+ againt mergeable sections. Take r_addend into account when caching
+ trampolines.
+
+2003-03-18 Richard Henderson <rth@redhat.com>
+
+ * elfxx-ia64.c (get_dyn_sym_info): Return NULL gracefully for
+ local symbols that have no dyninfo.
+
+2003-03-14 Gene Smith <gene.smith@siemens.com>
+
+ * ieee.c (ieee_write_expression): Handle the case where symbol is
+ NULL.
+ General formatting improvements.
+
+2003-03-13 Nick Clifton <nickc@redhat.com>
+
+ * configure.in (LINGUAS): Add zh_CN.
+ * configure: Regenerate.
+ * po/zh_CN.po: New file.
+
+2003-03-13 Elias Athanasopoulos <elathan@phys.uoa.gr>
+
+ * aout-cris.c (BYTES_IN_WORD): Don't define.
+ aout-encap.c: Likewise.
+ aout-ns32k.c: Likewise.
+ aout-tic30.c: Likewise.
+ hp300bsd.c: Likewise.
+ i386aout.c: Likewise.
+ i386dynix.c: Likewise.
+ i386linux.c: Likewise.
+ i386lynx.c: Likewise.
+ i386mach3.c: Likewise.
+ m68k4knetbsd.c: Likewise.
+ m68klinux.c: Likewise.
+ m68klynx.c: Likewise.
+ m68knetbsd.c: Likewise.
+ m88kmach3.c: Likewise.
+ mipsbsd.c: Likewise.
+ newsos3.c: Likewise.
+ sparclinux.c: Likewise.
+ sparclynx.c: Likewise.
+ sparcnetbsd.c: Likewise.
+ vaxbsd.c: Likewise. Fix comment formatting.
+
+2003-03-12 Alexandre Oliva <aoliva@redhat.com>
+
+ * Reverted 2003-03-02's patch.
+
+ * elfxx-target.h (bfd_elfNN_canonicalize_reloc): Make it
+ overridable.
+ * elf64-mips.c (mips_elf64_canonicalize_reloc,
+ mips_elf64_get_dynamic_reloc_upper_bound,
+ mips_elf64_canonicalize_dynamic_reloc): New, adapted from elf.c.
+ (bfd_elf64_get_canonicalize_reloc,
+ bfd_elf64_get_dynamic_reloc_upper_bound,
+ bfd_elf64_canonicalize_dynamic_reloc): Define.
+ (mips_elf64_slurp_reloc_table): Support dynamic.
+ (mips_elf64_slurp_one_reloc_table): Adjust.
+
+2003-03-12 Nick Clifton <nickc@redhat.com>
+
+ * xsym.c (bfd_sym_fetch_type_information_table_entry): Change
+ 'index' to 'offset' in test for zero value.
+
+2003-03-11 Alexandre Oliva <aoliva@redhat.com>
+
+ * elfxx-mips.c (mips_elf_create_dynamic_relocation): Do not create
+ dynamic relocations pointing to local or section symbols, use the
+ NULL symbol instead. Document the choice to not emit an
+ additional R_MIPS_64 relocation.
+
+2003-03-11 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c (ppc_elf_relocate_section): Subtract tls seg vma from
+ zero index dynamic tls relocs generated for the GOT. Tidy code.
+ Set "relocation" to 1 on DTPMOD32 relocs. Optimize HA adjustment.
+ * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
+
+2003-03-07 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c (ppc_elf_relocate_section): Don't look for a nop after
+ a tls_get_addr call.
+
+ * elf32-ppc.c (ELIMINATE_COPY_RELOCS): Define as one.
+ (ppc_elf_adjust_dynamic_symbol): For weak symbols, copy
+ ELF_LINK_NON_GOT_REF from weakdef.
+ * elf64-ppc.c (ELIMINATE_COPY_RELOCS): Define as one.
+ (ppc64_elf_adjust_dynamic_symbol): For weak symbols, copy
+ ELF_LINK_NON_GOT_REF from weakdef.
+ * elf32-i386.c (ELIMINATE_COPY_RELOCS): Define as one. Use throughout.
+ (elf_i386_adjust_dynamic_symbol): For weak symbols, copy
+ ELF_LINK_NON_GOT_REF from weakdef.
+
+2003-03-06 Jakub Jelinek <jakub@redhat.com>
+ Andrew Haley <aph@redhat.com>
+
+ * elflink.h (elf_bfd_discard_info): Don't process eh frames if
+ output is relocateable.
+
+2003-03-06 Steven Konopa <skonopa@kgo.csc.com>
+
+ * som.c (som_fixup_formats): Correct formats for R_AUX_UNWIND and
+ R_COMMENT.
+
+2003-03-06 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c (ppc_elf_create_linker_section): Don't capitalize
+ error messages.
+ (ELIMINATE_COPY_RELOCS): Define to zero.
+ (ppc_elf_relocate_section): Don't deref htab->tls_sec when calculating
+ TLSLD relocs. Report reloc types on a number of errors. Optimize
+ LOCAL24PC check for non-local syms. Don't capitalize error messages.
+ * elf64-ppc.c (ELIMINATE_COPY_RELOCS): Define to zero.
+ (ppc64_elf_relocate_section): Don't deref htab->tls_sec when
+ calculating TLSLD relocs. Report reloc types on a number of errors.
+ Don't capitalize error messages.
+
+2003-03-03 H.J. Lu <hjl@gnu.org>
+
+ * elfxx-ia64.c (USE_BRL): Removed.
+ (oor_ip): Removed.
+
+2003-03-03 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * elf32-sh.c (sh_elf_howto_tab): Make R_SH_IND12W into an ordinary
+ relocation (no special function), and make it non-partial_inplace.
+ (sh_elf_relax_section): When creating a bsr, use a consistent value
+ no matter if the symbol is extern or not; set addend to -4.
+ Don't swap load / non-load instructions for SH4.
+ (sh_elf_relax_delete_bytes): In R_SH_IND12W case, check the offset
+ rather than if the symbol is external to determine if adjusting the
+ offset makes sense. Adjust the addend too if appropriate.
+ (sh_elf_relocate_section): In R_SH_IND12W, don't fiddle with the
+ relocation.
+
+2003-03-03 Nick Clifton <nickc@redhat.com>
+
+ * po/da.po: Installed latest translation.
+
+2003-03-02 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elf32-mips.c (elf_mips_howto_table_rel): Change definition of
+ R_MIPS_PC16 to rightshift 2.
+ (elf_reloc_map mips_reloc_map): Map to rightshifted BFD reloc.
+ (bfd_elf32_bfd_reloc_type_lookup): Support
+ BFD_RELOC_MIPSEMB_16_PCREL_S2.
+ * elf64-mips.c (mips_elf64_howto_table_rel): Change definition of
+ R_MIPS_PC16 to rightshift 2.
+ (mips_elf64_howto_table_rela): Likewise.
+ (mips_reloc_map): Map to rightshifted BFD reloc.
+ * elfn32-mips.c: The same as in elf64-mips.c.
+ * elfxx-mips.c (mips_elf_got_for_ibfd): Typo in comment.
+ (mips_elf_calculate_relocation): Handle rightshifted addends for
+ R_MIPS_PC16.
+ * reloc.c (BFD_RELOC_MIPSEMB_16_PCREL_S2): New BFD relocation for
+ MIPS Embedded PIC. Remove superfluous empty COMMENT.
+ * libbfd.h: Regenerate.
+ * bfd-in2.h: Regenerate.
+
+2003-02-28 Richard Henderson <rth@redhat.com>
+
+ * elfxx-ia64.c (elfNN_ia64_relax_section): Correct bounds
+ for ltoff22x relaxation.
+
+2003-03-01 Alan Modra <amodra@bigpond.net.au>
+
+ * bfd-in.h (_bfd): Don't define.
+ * bfd.c: Rename occurrences of "struct _bfd" to "struct bfd".
+ * syms.c: Likewise.
+ * bfd-in2.h: Regenerate.
+
+2003-02-27 Richard Henderson <rth@redhat.com>
+
+ * elfxx-ia64.c (struct elfNN_ia64_dyn_sym_info): Add want_gotx;
+ (elfNN_ia64_check_relocs): Set it.
+ (allocate_global_data_got): Check it.
+ (allocate_local_got): Likewise.
+ (allocate_dynrel_entries): Likewise.
+ (elfNN_ia64_relax_ldxmov): New.
+ (elfNN_ia64_relax_section): Handle LTOFF22X, LDXMOV.
+ (elfNN_ia64_choose_gp): Split out from ...
+ (elfNN_ia64_final_link): ... here.
+
+2003-02-27 Andrew Cagney <cagney@redhat.com>
+
+ * bfd.c (struct bfd): Rename "struct _bfd".
+ * bfd-in.h: Update copyright.
+ (struct bfd): Rename "struct _bfd".
+ (_bfd): Define for backward compatibility.
+ * bfd-in2.h: Regenerate.
+
+2003-02-25 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h (elf_bfd_final_link): Apportion reloc counts to rel_hdr
+ and rel_hdr2 when initially counting input relocs rather than after
+ creating output reloc sections.
+ (elf_link_read_relocs_from_section): Don't abort with wrong reloc
+ sizes.
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2003-02-24 Kris Warkentin <kewarken@qnx.com>
+
+ * elf.c (elfcore_read_notes): Add check for QNX style core file.
+ (elfcore_grog_nto_note): New function.
+ (elfcore_grog_nto_gregs): New function.
+ (elfcore_grog_nto_status): New function.
+
+2003-02-24 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.c (_bfd_elf_create_got_section): Check existing .got
+ section flags before concluding that we've already been called.
+ Don't use register keyword.
+ (_bfd_elf_create_dynamic_sections): Don't use register keyword.
+ (_bfd_elf_create_linker_section): Formatting.
+
+2003-02-20 jmc <jmc@prioris.mini.pw.edu.pl>
+
+ * coff-h8300.c: Fix typo: intial -> initial.
+ * coff-ppc.c: Likewise.
+
+2003-02-20 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c: Formatting.
+ (allocate_dynrelocs): LD and GD relocs against the same sym need
+ separate GOT entries.
+ (ppc_elf_relocate_section): Correct GOT handling for multiple GOT
+ entries per symbol.
+
+2003-02-19 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-hppa.c (elf32_hppa_gc_sweep_hook): Simplify dynamic reloc
+ removal. Localize vars. Remove unnecessary dynobj test.
+ * elf32-i386 (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Pass SHARED instead
+ of INFO.
+ (allocate_dynrelocs): Adjust WILL_CALL_FINISH_DYNAMIC_SYMBOL uses,
+ and optimize.
+ (elf_i386_relocate_section): Likewise.
+ (elf_i386_gc_sweep_hook): Simplify dyn reloc removal. Localize vars.
+ * elf32-s390.c (elf_s390_gc_sweep_hook): Likewise.
+ * elf32-sh.c (sh_elf_gc_sweep_hook): Likewise.
+ * elf64-s390.c (elf_s390_gc_sweep_hook): Likewise.
+ * elf64-x86-64.c (elf64_x86_64_gc_sweep_hook): Likewise.
+ * elf32-sparc.c (elf32_sparc_gc_sweep_hook): Likewise. Remove
+ local_dynrel for section too. Don't touch HIPLT22, LOPLT10, PCPLT32
+ or PCPLT10 relocs. Don't subtract twice on PLT32 relocs.
+ Formatting.
+
+ * elf64-ppc.c (ELIMINATE_COPY_RELOCS): Define.
+ (ppc64_elf_check_relocs): Use it. Correct comment. Move SEC_ALLOC
+ test.
+ (ppc64_elf_adjust_dynamic_symbol): Use ELIMINATE_COPY_RELOCS.
+ (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Pass SHARED instead of INFO.
+ (allocate_dynrelocs): Adjust WILL_CALL_FINISH_DYNAMIC_SYMBOL uses,
+ and optimize. Use ELIMINATE_COPY_RELOCS.
+ (ppc64_elf_relocate_section): Likewise.
+
+ * elf32-ppc.c (struct ppc_elf_dyn_relocs): Add pc_count field.
+ (ppc_elf_copy_indirect_symbol): Copy pc_count field.
+ (ELIMINATE_COPY_RELOCS): Define.
+ (ppc_elf_adjust_dynamic_symbol): Convert copy relocs to dynamic.
+ (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Pass SHARED instead of INFO.
+ (MUST_BE_DYN_RELOC): Define.
+ (allocate_dynrelocs): Adjust WILL_CALL_FINISH_DYNAMIC_SYMBOL uses,
+ and optimize. Trim dyn_relocs.
+ (ppc_elf_check_relocs): Don't generate dyn_relocs when we know they'll
+ not be used. Do generate dyn_relocs for copy reloc avoidance. Keep
+ track of pc_rel dyn relocs.
+ (ppc_elf_relocate_section): Remove "will_become_local". Adjust
+ WILL_CALL_FINISH_DYNAMIC_SYMBOL use. Trim dyn relocs as per
+ allocate_dynrelocs. Don't recalculate "sec".
+
+2003-02-18 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c (ppc_elf_relocate_section): Remove unnecessary test.
+ * elf64-ppc.c (ppc64_elf_tls_optimize): Decrement tlsld_got.refcount
+ on invalid LD relocs.
+ (allocate_dynrelocs): Invalid LD relocs don't use tlsld_got entry.
+ (ppc64_elf_relocate_section): Unify new handling of LD relocs and
+ tlsld_got entry. Use IS_PPC64_TLS_RELOC.
+
+ * elf32-ppc.h: New file.
+ * elf32-ppc.c: Include elf32-ppc.h.
+ (NOP, CROR_151515, CROR_313131, TP_OFFSET, DTP_OFFSET): Define.
+ (struct ppc_elf_link_hash_entry): Rename "root" to "elf". Adjust uses.
+ Add "tls_mask" field.
+ (TLS_GD, TLS_LD, TLS_TPREL, TLS_DTPREL, TLS_TLS, TLS_TPRELGD): Define.
+ (struct ppc_elf_link_hash_table): Rename "root" to "elf". Adjust uses.
+ Add got, relgot, plt, relplt, dynbss, relbss, dynsbss, relsbss,
+ sdata, sdata2, tls_sec, tls_get_addr, tlsld_got fields.
+ Make use of htab shortcuts throughout file.
+ (ppc_elf_link_hash_newfunc): Init tls_mask field.
+ (ppc_elf_link_hash_table_create): Init new fields.
+ (ppc_elf_copy_indirect_symbol): Copy tls_mask.
+ (ppc_elf_howto_raw): Add tls relocs.
+ (ppc_elf_reloc_type_lookup): Handle them.
+ (ppc_elf_unhandled_reloc): New function.
+ (ppc_elf_create_got): Stash got section pointer in hash table,
+ return status. Make .rela.got too.
+ (ppc_elf_create_dynamic_sections): Stash section pointers in htab.
+ (ppc_elf_adjust_dynamic_symbol): Only set up copy relocs when
+ NON_GOT_REF set. Don't allocate space in .plt here..
+ (allocate_dynrelocs): ..do so here instead, properly ref-counting and
+ not allocating plt entries unnecessarily. Allocate got entries here.
+ (WILL_CALL_FINISH_DYNAMIC_SYMBOL): Define.
+ (ppc_elf_size_dynamic_sections): Allocate local got entries. Pass
+ "info" during allocate_dynrelocs hash traversal. Use htab section
+ shortcuts rather than searching for named sections. Get rid of
+ "plt" and "strip" booleans.
+ (update_local_sym_info, bad_shared_reloc): New functions.
+ (ppc_elf_check_relocs): Handle TLS relocs. Move .rela.got creation to
+ ppc_elf_create_got. Don't mark got or plt reloc syms dynamic, do so
+ in allocate_dynreloc. Use update_local_sym_info and bad_shared_reloc.
+ Disallow R_PPC_EMB_RELSDA, R_PPC_EMB_NADDR32, R_PPC_EMB_NADDR16,
+ R_PPC_EMB_NADDR16_LO, R_PPC_EMB_NADDR16_HI and R_PPC_EMB_NADDR16_HA
+ in shared libs. R_PPC_PLTREL32 is a plt reloc too. Refcount all
+ relocs that might use a plt entry. Set NON_GOT_REF too.
+ Enumerate all do-nothing relocs.
+ (ppc_elf_gc_sweep_hook): Simplify removal of dynrelocs. Handle
+ tls relocs and all plt relocs.
+ (ppc_elf_tls_setup, ppc_elf_tls_optimize): New functions.
+ (ppc_elf_finish_dynamic_symbol): Don't build got entries here.
+ (ppc_elf_finish_dynamic_sections): Rewrite tag code using htab
+ shortcuts.
+ (ppc_elf_relocate_section): Tidy. Handle TLS relocs. Use
+ bfd_elf_local_sym_name. Simplify unresolved reloc code. Build got
+ entries and got relocs here. Warn on non-zero got reloc addend.
+ Split out branch taken/not taken reloc code into a separate switch
+ and correct offset calculation. Allow BRTAKEN/BRNTAKEN dynamic relocs.
+ Split out HA reloc adjustments to separate switch statement. Don't
+ warn on reloc overflow if we've already warned about undefined.
+ Don't rebuild sym name when reporting errors. Report all possible
+ errors from _bfd_final_link_relocate.
+ (bfd_elf32_bfd_final_link): Don't define.
+
+2003-02-18 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_relocate_section): Don't init "r". Don't
+ rebuild sym name when reporting errors.
+
+2003-02-17 Nick Clifton <nickc@redhat.com>
+
+ * elflink.h (elf_link_output_extsym): Only check
+ allow_shlib_undefined for shared libraries.
+ * elf32-i386.c (elf_i386_relocate_section): Remove bogus check
+ of allow_shlib_undefined.
+ * elf32-cris.c (cris_elf_relocate_section): Likewise.
+ * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
+ * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
+ * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
+ * elf32-s390.c (elf_s390_relocate_section): Likewise.
+ * elf32-sh.c (sh_elf_relocate_section): Likewise.
+ * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
+ * elf32-vax.c (elf_vax_relocate_section): Likewise.
+ * elf64-alpha.c (elf64_alpha_relocate_section): Likewise.
+ * elf64-hppa.c (elf64_hppa_relocate_section): Likewise.
+ * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
+ * elf64-s390.c (elf_s390_relocate_section): Likewise.
+ * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
+ * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
+ * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
+ * elfxx-mips.c (_bfd_mips_elf_relocate_section): Likewise.
+
+2003-02-17 Nick Clifton <nickc@redhat.com>
+
+ * elf.c (SEGMENT_AFTER_SEGMENT): Add third parameter - the
+ address field to use in the comparison.
+ (SEGMENT_OVERLAPS): Check that LMAs overlap as well.
+
+2003-02-14 Bob Wilson <bob.wilson@acm.org>
+
+ * elfcore.h (elf_core_file_p): Compare alternate machine codes for ELF
+ backends when checking if the generic ELF target should be used.
+
+ * syms.c (_bfd_stab_section_find_nearest_line): For line number stabs
+ outside of functions, treat values as absolute addresses.
+
+ * bfd.c: Change embedded documentation to use consistent indentation
+ and to split up long lines. Change informal style of description
+ for functions lacking real documentation.
+ * coffcode.h: Break up long lines in embedded documentation.
+ * format.c: Likewise.
+ * targets.c: Likewise.
+ * libcoff.h: Regenerate.
+ * bfd-in2.h: Regenerate.
+
+2003-02-14 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_link_hash_table_create): Init tls_get_addr.
+ (ppc64_elf_copy_indirect_symbol): Merge tls_mask too.
+ (ppc64_elf_gc_sweep_hook): Simplify removal of dyn_relocs.
+ (allocate_dynrelocs): Don't treat undefined and undefweak specially.
+ (ppc_size_one_stub): Fix warning, and tighten plt entry check.
+ (group_sections): Don't share a stub section if stubs are for a large
+ section. Adjust comment.
+ (ppc64_elf_size_stubs): Roughly double the size left for stubs if
+ !stubs_always_before_branch.
+ (ppc64_elf_relocate_section): Initialize tlsld GOT entry once. Don't
+ treat undefined and undefweak specially when processing dyn relocs.
+
+2003-02-13 Jakub Jelinek <jakub@redhat.com>
+
+ * elflink.h (elf_link_add_object_symbols): Handle .symver x, x@FOO.
+
+2003-02-13 Nick Clifton <nickc@redhat.com>
+
+ * elf32-arm.h (elf32_thumb_to_arm_stub): Include section VMAs
+ in computation of offset to insert into BL instruction.
+
+2003-02-11 Uwe Stieber <uwe@wwws.de>
+
+ * config.bfd: Add support for kaOS as cross build target system.
+
+2003-02-11 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_check_relocs): Match versioned
+ .__tls_get_addr too.
+ (ppc64_elf_tls_setup): Ensure cached tls_get_addr is not indirect.
+
+2003-02-10 Kaz kojima <kkojima@rr.iij4u.or.jp>
+
+ * elf32-sh.c (elf_sh_dyn_relocs): Add tls_tpoff32 field.
+ (elf_sh_link_hash_entry): Remove tls_tpoff32 field.
+ (sh_elf_link_hash_newfunc): Remove the initialization of
+ tls_tpoff32 field.
+ (allocate_dynrelocs): Keep dyn_relocs if it includes the entry
+ for which tls_tpoff32 flag is set.
+ (sh_elf_relocate_section): Covert to LE only if the dyn_relocs
+ of the symbol includes the entry matched with the input_section
+ and having tls_tpoff32 flag on. When linking statically, set
+ symbol index of R_SH_TLS_TPOFF32 relocation to zero if the symbol
+ is defined in this executable.
+ (sh_elf_check_relocs): Set tls_tpoff32 flag appropriately.
+
+2003-02-10 Jakub Jelinek <jakub@redhat.com>
+
+ * elf32-s390.c (elf_s390_size_dynamic_sections): Set relocs to TRUE
+ even if there is just non-empty .rela.plt.
+
+2003-02-10 Nick Clifton <nickc@redhat.com>
+
+ * archures.c (bfd_mach_arm_ep9312): Define.
+ * bfd-in2.h: Regenerate.
+ * cpu-arm.c (processors[]): Add ep9312.
+ (bfd_arm_arch): Add ep9312.
+ * elf32-arm.h (elf32_arm_merge_private_data): Update error
+ messages and add test for Maverick floating point support.
+ (elf32_arm_print_private_bfd_data): Handle
+ EF_ARM_MAVERICK_FLOAT flag.
+ (elf32_arm_object_p): New function.
+ (elf_backend_object_p): Define.
+
+2003-02-10 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c: Rename assorted occurrences of tls_type and similar
+ variables, structure fields or function params to tls_mask or
+ similar to better reflect usage.
+ (struct got_entry): Comment.
+ (struct ppc_link_hash_entry): Expand comment, and renumber TLS_*.
+ (get_tls_mask): Rename from get_tls_type.
+
+2003-02-09 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (TLS_GD_LD): Don't define..
+ (TLS_GD): ..define this instead and update all uses.
+ (TLS_TPRELGD): Define.
+ (ppc64_elf_link_hash_table_create): Tweak initialization of
+ init_refcount and init_offset.
+ (ppc64_elf_check_relocs): Add one extra element to t_symndx array.
+ Mark second slot of GD or LD toc entries.
+ (get_tls_type): Return an int. Distinguish toc GD and LD entries
+ from other tls types.
+ (ppc64_elf_tls_setup): New function, split out from..
+ (ppc64_elf_tls_optimize): ..here. Don't optimize when symbols are
+ defined in a dynamic object. Fix LD optimization. Don't set TLS_TPREL
+ on GD->IE optimization, use TLS_TPRELGD instead. Use get_tls_type
+ return value to properly decide whether toc GD and LD entries can
+ optimize away __tls_get_addr call. Check next reloc after DTPMOD64
+ to determine GD or LD rather than looking at TLS_LD flag. Don't
+ attempt to adjust got entry tls_type here..
+ (allocate_dynrelocs): ..instead, adjust got entry tls_type here, and
+ look for possible merges.
+ (ppc64_elf_size_dynamic_sections): Adjust local got entries for
+ optimization.
+ (ppc64_elf_size_stubs): Tweak __tls_get_addr fudge.
+ (ppc64_elf_relocate_section): Rename some vars to better reflect usage.
+ Make use of return value from get_tls_type to properly detect GD and
+ LD optimizations. Split tlsld/gd hi/ha from lo/ds case. Don't
+ handle tls_get_addr removal when looking at REL24 relocs, do it when
+ looking at the previous reloc. Check reloc after DTPMOD64 to determine
+ GD or LD.
+ * elf64-ppc.h (ppc64_elf_tls_setup): Declare.
+
+2003-02-08 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-hppa.c (group_sections): Don't share a stub section if
+ stubs are for a large section.
+
+ * elf32-hppa.c (elf32_hppa_size_stubs): Double the size left for
+ stubs if !stubs_always_before_branch.
+
+2003-02-07 Nick Clifton <nickc@redhat.com>
+
+ * elf.c (swap_out_syms): Generate an error message if an
+ equivalent output section cannot be found for a symbol.
+
+2003-02-07 Jakub Jelinek <jakub@redhat.com>
+
+ * elf64-alpha.c (elf64_alpha_relax_section): Don't crash if
+ local_got_entries is NULL.
+
+2003-02-06 Andreas Schwab <schwab@suse.de>
+
+ * elf-eh-frame.c (get_DW_EH_PE_signed): Define.
+ (read_value): Add parameter is_signed, use signed extraction if
+ the value is signed.
+ (_bfd_elf_write_section_eh_frame): Pass signed flag of the
+ encoding to read_value.
+
+2003-02-06 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Don't copy got and
+ plt info when called to transfer weak sym info.
+
+2003-02-05 Alan Modra <amodra@bigpond.net.au>
+
+ * reloc.c: Add PPC and PPC64 TLS relocs.
+ * libbfd.h: Regenerate.
+ * bfd-in2.h: Regenerate.
+ * elf64-ppc.c (TP_OFFSET, DTP_OFFSET): Declare.
+ (ppc64_elf_howto_raw): Add TLS howto's. Adjust R_PPC64_NONE to be
+ against a 32 bit field.
+ (ppc64_elf_reloc_type_lookup): Handle TLS relocs.
+ (_ppc64_elf_section_data): Add t_symndx and comments.
+ (ppc64_elf_section_data): Use elf_section_data macro.
+ (ppc64_elf_new_section_hook): American spelling.
+ (struct got_entry, struct plt_entry): New.
+ (MUST_BE_DYN_RELOC): Rename from IS_ABSOLUTE_RELOC.
+ (struct ppc_stub_hash_entry): Add "addend" field.
+ (struct ppc_link_hash_entry): Add "tls_type".
+ (TLS_TLS, TLS_GD_LD, TLS_LD, TLS_TPREL, TLS_DTPREL,
+ TLS_EXPLICIT): Define.
+ (struct ppc_link_hash_table): Add tls_sec, tls_get_addr, tlsld_got.
+ (link_hash_newfunc): Init new fields.
+ (ppc64_elf_link_hash_table_create): Likewise. Set init_refcount and
+ init_offset to NULL.
+ (ppc64_elf_copy_indirect_symbol): Copy got and plt info. Don't call
+ _bfd_elf_link_hash_copy_indirect, rather insert relevant code from
+ there.
+ (update_local_sym_info, update_plt_info): New functions.
+ (ppc64_elf_check_relocs): Use them. Handle TLS relocs. Adjust GOT
+ handling to use got.glist rather than got.refcount. Likewise for PLT.
+ (ppc64_elf_gc_sweep_hook): Handle TLS relocs, new GOT and PLT lists.
+ (func_desc_adjust): Adjust for new PLT list.
+ (ppc64_elf_adjust_dynamic_symbol): Likewise.
+ (get_sym_h, get_tls_type): New functions.
+ (ppc64_elf_edit_opd): Remove unused variable. Use get_sym_h.
+ (ppc64_elf_tls_optimize): New function.
+ (allocate_dynrelocs): Adjust for new PLT and GOT lists. Allocate
+ TLS relocs.
+ (ppc64_elf_size_dynamic_sections): Likewise.
+ (ppc_type_of_stub): Adjust for new PLT list.
+ (ppc_build_one_stub): Likewise.
+ (ppc64_elf_size_stubs): Likewise. Use get_sym_h. Treat __tls_get_addr
+ calls specially.
+ (ppc64_elf_relocate_section): Adjust for new GOT and PLT lists. Handle
+ TLS relocs. Report local syms using bfd_elf_local_sym_name. Don't
+ init GOT entries that have a reloc. Generate GOT relocs here..
+ (ppc64_elf_finish_dynamic_symbol): ..not here. Adjust for PLT list.
+ * elf64-ppc.h (ppc64_elf_tls_optimize): Declare.
+
+2003-02-04 Andreas Schwab <schwab@suse.de>
+
+ * elf32-m68k.c (elf_m68k_hash_entry): Define.
+ (elf_m68k_link_hash_traverse): Remove.
+ (elf_m68k_link_hash_newfunc): Use struct bfd_hash_entry and
+ elf_m68k_hash_entry instead of struct elf_m68k_link_hash_entry to
+ reduce casting.
+ (elf_m68k_check_relocs): Use elf_m68k_hash_entry instead of
+ casting.
+ (elf_m68k_size_dynamic_sections): Use elf_link_hash_traverse
+ instead of elf_m68k_link_hash_traverse.
+ (elf_m68k_discard_copies): Change first parameter to pointer to
+ struct elf_link_hash_entry and use elf_m68k_hash_entry when struct
+ elf_m68k_link_hash_entry is needed.
+
+2003-02-04 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h (struct got_entry, struct plt_entry): Forward declare.
+ (struct elf_link_hash_entry): Add "glist" and "plist" fields to
+ "got" union, and declare as gotplt_union. Use gotplt_uinion for
+ "plt" field.
+ (struct elf_link_hash_table): Make "init_refcount" a gotplt_union.
+ Add "init_offset" field.
+ (struct elf_obj_tdata <local_got>): Add "struct got_entry **" to union.
+ (elf_local_got_ents): Declare.
+ * elf.c (_bfd_elf_link_hash_newfunc): Adjust initialization of "got"
+ and "plt".
+ (_bfd_elf_link_hash_hide_symbol): Use "init_offset".
+ (_bfd_elf_link_hash_table_init): Set "init_offset".
+ * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set init_refcount
+ from init_offset.
+ (elf_adjust_dynamic_symbol): Set plt and got offsets using init_offset.
+
+ * elf.c (bfd_elf_local_sym_name): Split out from..
+ (group_signature): ..here.
+ * elf-bfd.h (bfd_elf_local_sym_name): Declare.
+
+2003-02-04 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h (enum elf_link_info_type): Remove.
+ (struct bfd_elf_section_data): Move sec_info_type, use_rela_p fields
+ to struct sec. Remove linkonce_p field.
+ (elf_linkonce_p): Delete.
+ (elf_discarded_section): Update for sec_info_type change.
+ * section.c (struct sec): Add sec_info_type, use_rela_p, has_tls_reloc,
+ flag11, flag12, flag13, flag14, flag15, flag16, flag20, flag24.
+ (ELF_INFO_TYPE_NONE): Define.
+ (ELF_INFO_TYPE_STABS): Define.
+ (ELF_INFO_TYPE_MERGE): Define.
+ (ELF_INFO_TYPE_EH_FRAME): Define.
+ (ELF_INFO_TYPE_JUST_SYMS): Define.
+ (STD_SECTION): Update struct sec initializer.
+ * ecoff.c (bfd_debug_section): Likewise.
+ * elf.c: Likewise. Update occurrences of sec_info_type and use_rela_p.
+ * elflink.h: Likewise.
+ * elf-eh-frame.c: Likewise.
+ * elf64-alpha.c: Likewise.
+ * elfxx-ia64.c: Likewise.
+ * elfxx-mips.c: Likewise.
+ * bfd-in2.h: Regenerate.
+
+ * elf32-sparc.c (sec_do_relax): Use elf_section_data macro rather than
+ referring to used_by_bfd.
+ * elf64-sparc.c (sec_do_relax): Likewise.
+ * elf64-mmix.c (mmix_elf_section_data): Likewise.
+ * elfxx-mips.c (mips_elf_section_data): Likewise.
+ * ieee.c (ieee_slurp_section_data): Use ieee_per_section macro.
+ (ieee_get_section_contents): Likewise.
+ (ieee_new_section_hook): Formatting.
+ (ieee_canonicalize_reloc): Remove commented out code.
+ * mmo.c (mmo_section_data): Define. Use throughout file.
+ * oasys.c (oasys_get_section_contents): Use oasys_per_section macro.
+
+2003-01-31 Graydon Hoare <graydon@redhat.com>
+
+ * Makefile.am (opncls.lo): Add dependency upon libiberty.h.
+ * Makefile.in: Regenerate.
+ * opncls.c (calc_crc32, get_debug_link_info,
+ seperate_debug_file_exists, find_seperate_debug_file): New
+ internal functions.
+ (bfd_follow_gnu_debuglink): New function. Follow the pointer
+ contained inside a .gnu_debuglink section.
+ * bfd-in2.h: Regenerate.
+
+2003-01-29 Alexandre Oliva <aoliva@redhat.com>
+
+ * elfxx-mips.c (mips_elf_got_entry_hash): Don't dereference
+ entry->abfd when it's NULL.
+
+2003-01-27 Alexandre Oliva <aoliva@redhat.com>
+
+ * elfxx-mips.c (mips_elf_create_dynamic_relocation): Handle
+ _bfd_elf_section_offset returning -2 the same way as -1.
+
+ * elfxx-mips.c (mips_elf_multi_got): New function.
+ (struct mips_got_entry): Make symndx and gotidx signed. Moved
+ addend into union along with address and link hash entry.
+ (struct mips_got_info): Added bfd2got and next.
+ (struct mips_elf_hash_sort_data): Added max_unref_got_dynindx.
+ (mips_elf_got_section, mips_elf_create_got_section): Use
+ SEC_EXCLUDE bit to tell whether we really need the got
+ section. Take boolean arguments to disregard an excluded
+ section, or to create it as excluded. Adjust all callers.
+ Use mips_elf_got_section all over.
+ (mips_elf_local_got_index, mips_elf_got_page,
+ mips_elf_got16_entry): Take input bfd as argument, and pass it
+ on to mips_elf_create_local_got_entry.
+ (mips_elf_global_got_index, mips_elf_create_local_got_entry):
+ Take input bfd as argument, and manage entries in the
+ appropriate GOT.
+ (mips_elf_got_offset_from_index): Take input bfd as argument,
+ and use it to adjust the GP offset of the bfd.
+ (mips_elf_sort_hash_table, mips_elf_sort_hash_table_f): Move
+ unreferenced GOT entries of global symbols to the end.
+ (mips_elf_record_global_got_symbol): Take input bfd as
+ argument. Add entries to the master GOT hash table.
+ (struct mips_elf_bfd2got_hash): New.
+ (struct mips_elf_got_per_bfd_arg): New.
+ (struct mips_elf_set_global_got_offset_arg): New.
+ (mips_elf_hash_bfd_vma, mips_elf_multi_got_entry_hash,
+ mips_elf_multi_got_entry_eq, mips_elf_bfd2got_entry_hash,
+ mips_elf_bfd2got_entry_eq, mips_elf_make_got_per_bfd,
+ mips_elf_merge_gots, mips_elf_set_global_got_offset,
+ mips_elf_resolve_final_got_entry,
+ mips_elf_resolve_final_got_entries, mips_elf_adjust_gp,
+ mips_elf_got_for_ibfd): New functions.
+ (ELF_MIPS_GP_OFFSET): Don't depend on SGI_COMPAT.
+ (MIPS_ELF_GOT_MAX_SIZE): New macro.
+ (STUB_LW): Generate 64-bit stub regardless of SGI_COMPAT.
+ (mips_elf_got_entry_hash): Take new fields into account. Use
+ mips_elf_hash_bfd_vma.
+ (mips_elf_got_entry_eq): Take new fields into account.
+ (mips_elf_create_got_section): Initialize new fields.
+ (mips_elf_calculate_relocation): Pass input_bfd to functions
+ that now take it. Adjust gp for the input_bfd.
+ (mips_elf_allocate_dynamic_relocation,
+ mips_elf_create_dynamic_relocation,
+ _bfd_mips_elf_create_dynamic_sections): Use...
+ (mips_elf_rel_dyn_section): New function. Borrow code from...
+ (_bfd_mips_elf_check_relocs): Pass input_bfd to functions that
+ now take it. Create the got section if needed, even if
+ excluded, before recording a global got symbol. Move some
+ code to...
+ (mips_elf_record_local_got_symbol): New fn.
+ (_bfd_mips_elf_size_dynamic_sections): Disable combreloc.
+ Compute multi-got global entries offsets. Move GOT code to...
+ (_bfd_mips_elf_always_size_sections): Call mips_elf_multi_got
+ if the GOT is too big.
+ (_bfd_mips_elf_finish_dynamic_symbol): Set got entry of
+ undefweak symbol to zero. Generate dynamic relocations for
+ non-primary GOT entries for global symbols.
+ (_bfd_mips_elf_finish_dynamic_sections): Handle multi-got
+ case. Generate dynamic relocations for local got entries.
+ Sort dynamic relocations on N64 too, using...
+ (sort_dynamic_relocs_64): New fns.
+ (_bfd_mips_elf_hide_symbol): Adjust multi-got counters.
+ (_bfd_mips_elf_merge_private_bfd_data): Ignore EF_MIPS_XGOT.
+
+2003-01-27 Alexandre Oliva <aoliva@redhat.com>
+
+ * bfd.c (struct _bfd): Added id field.
+ * opncls.c (_bfd_id_counter): New static variable.
+ (_bfd_new_bfd): Use it.
+ * bfd-in2.h: Rebuilt.
+
+2003-01-25 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-sparc.c (bfd_elf32_new_section_hook): Define.
+
+2003-01-25 Jakub Jelinek <jakub@redhat.com>
+
+ * elf32-sparc.c (_bfd_sparc_elf_howto_table): Add TLS relocs.
+ (elf32_sparc_rev32_howto): New variable.
+ (sparc_reloc_map): Add TLS relocs.
+ (elf32_sparc_reloc_type_lookup, elf32_sparc_info_to_howto):
+ Handle REV32.
+ (sparc_elf_hix22_reloc, sparc_elf_lox10_reloc, elf32_sparc_mkobject):
+ New functions.
+ (struct elf32_sparc_dyn_relocs, struct elf32_sparc_link_hash_entry,
+ struct elf32_sparc_link_hash_table):
+ New structures.
+ (elf32_sparc_tdata, elf32_sparc_local_got_tls_type,
+ elf32_sparc_hash_table): Define.
+ (link_hash_newfunc, elf32_sparc_link_hash_table_create,
+ create_got_section, elf32_sparc_create_dynamic_sections,
+ elf32_sparc_copy_indirect_symbol, elf32_sparc_tls_transition): New
+ functions.
+ (elf32_sparc_check_relocs): Handle TLS relocs. Add dynamic reloc
+ reference counting.
+ (elf32_sparc_gc_sweep_hook): Likewise.
+ (elf32_sparc_adjust_dynamic_symbol): Likewise.
+ (elf32_sparc_size_dynamic_sections): Likewise.
+ (elf32_sparc_relocate_section): Likewise.
+ (allocate_dynrelocs, readonly_dynrelocs, dtpoff_base, tpoff):
+ New functions.
+ (elf32_sparc_object_p): Allocate backend private object data.
+ (bfd_elf32_bfd_link_hash_table_create,
+ elf_backend_copy_indirect_symbol, bfd_elf32_mkobject,
+ elf_backend_can_refcount): Define.
+ (elf_backend_create_dynamic_sections): Define to
+ elf32_sparc_create_dynamic_sections.
+ * reloc.c: Add SPARC TLS relocs.
+ * bfd-in2.h, libbfd.h: Rebuilt.
+ * elf64-sparc.c (sparc64_elf_howto_table): Add TLS relocs.
+ (sparc_reloc_map): Likewise.
+
+2003-01-24 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * bfd-in2.h: Regenerate.
+ * elf32-s390.c (elf_s390_mkobject, elf_s390_tls_transition,
+ s390_tls_reloc, dtpoff_base, tpoff, invalid_tls_insn): New functions.
+ (elf_howto_table): Add TLS relocs.
+ (elf_s390_reloc_type_lookup): Likewise.
+ (elf_s390_link_hash_entry): Add tls_type.
+ (elf_s390_hash_entry, elf_s390_obj_tdata, elf_s390_local_got_tls_type):
+ New macros.
+ (elf_s390_link_hash_table): Add tls_ldm_got.
+ (link_hash_newfunc): Initialize tls_type.
+ (elf_s390_link_hash_table_create): Initialize refcount of tls_ldm_got.
+ (elf_s390_copy_indirect_symbol): Copy tls_type information.
+ (elf_s390_check_relocs): Support TLS relocs.
+ (elf_s390_gc_sweep_hook): Likewise.
+ (allocate_dynrelocs): Likewise.
+ (elf_s390_size_dynamic_sections): Likewise.
+ (elf_s390_relocate_section): Likewise.
+ (elf_s390_finish_dynamic_symbol): Likewise.
+ (bfd_elf32_mkobject): Define for TLS.
+ * elf64-s390.c: Same changes as for elf32-s390.c.
+ * libbfd.h: Regenerate.
+ * reloc.c: Add s390 TLS relocations.
+
+2003-01-24 Charles Lepple <clepple@ghz.cc>
+
+ * aclocal.m4: Fix name of --enable-install-libbfd switch.
+
+2003-01-23 Nick Clifton <nickc@redhat.com>
+
+ * Add sh2e support:
+ 2002-04-02 Elena Zannoni <ezannoni@redhat.com>
+ * archures.c (bfd_mach_sh2e): Added.
+ * bfd-in2.h: Rebuilt.
+ * cpu-sh.c (arch_info_struct): Added SH2e.
+ * elf32-sh.c (sh_elf_set_mach_from_flags): Handle EF_SH2E.
+
+2003-01-23 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h (struct bfd_elf_section_data): Remove tdata. Change
+ dynindx to an int. Rearrange for better packing.
+ * elf.c (_bfd_elf_new_section_hook): Don't alloc if already done.
+ * elf32-mips.c (bfd_elf32_new_section_hook): Define.
+ * elf32-sh64.h: New. Split out from include/elf/sh.h.
+ (struct _sh64_elf_section_data): New struct.
+ (sh64_elf_section_data): Don't dereference sh64_info (was tdata).
+ * elf32-sh64-com.c: Include elf32-sh64.h.
+ * elf32-sh64.c: Likewise.
+ (sh64_elf_new_section_hook): New function.
+ (bfd_elf32_new_section_hook): Define.
+ (sh64_elf_fake_sections): Adjust for sh64_elf_section_data change.
+ (sh64_bfd_elf_copy_private_section_data): Likewise.
+ (sh64_elf_final_write_processing): Likewise.
+ * elf32-sparc.c (struct elf32_sparc_section_data): New.
+ (elf32_sparc_new_section_hook): New function.
+ (SET_SEC_DO_RELAX, SEC_DO_RELAX): Delete.
+ (sec_do_relax): Define.
+ (elf32_sparc_relax_section): Adjust to use sec_do_relax.
+ (elf32_sparc_relocate_section): Likewise.
+ * elf64-mips.c (bfd_elf64_new_section_hook): Define.
+ * elf64-mmix.c (struct _mmix_elf_section_data): New.
+ (mmix_elf_section_data): Define. Use throughout file.
+ (mmix_elf_new_section_hook): New function.
+ (bfd_elf64_new_section_hook): Define.
+ * elf64-ppc.c (struct _ppc64_elf_section_data): New.
+ (ppc64_elf_section_data): Define. Use throughout.
+ (ppc64_elf_new_section_hook): New function.
+ (bfd_elf64_new_section_hook): Define.
+ * elf64-sparc.c (struct sparc64_elf_section_data): New.
+ (sparc64_elf_new_section_hook): New function.
+ (SET_SEC_DO_RELAX, SEC_DO_RELAX): Delete.
+ (sec_do_relax): Define.
+ (sparc64_elf_relax_section): Adjust to use sec_do_relax.
+ (sparc64_elf_relocate_section): Likewise.
+ (bfd_elf64_new_section_hook): Define.
+ * elfn32-mips.c (bfd_elf32_new_section_hook): Define.
+ * elfxx-mips.c (struct _mips_elf_section_data): New.
+ (mips_elf_section_data): Define. Use throughout.
+ (_bfd_mips_elf_new_section_hook): New function.
+ (mips_elf_create_got_section): Don't alloc used_by_bfd.
+ * elfxx-mips.h (_bfd_mips_elf_new_section_hook): Declare.
+ * elfxx-target.h (bfd_elfNN_new_section_hook): Add #ifndef.
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2003-01-21 Richard Henderson <rth@redhat.com>
+
+ * elf64-alpha.c (ALPHA_ELF_LINK_HASH_PLT_LOC): New.
+ (struct alpha_elf_link_hash_entry): Add plt_old_section, plt_old_value.
+ (elf64_alpha_adjust_dynamic_symbol): Set them.
+ (elf64_alpha_size_plt_section_1): Reset them when plt entry removed.
+ (elf64_alpha_relax_tls_get_addr): Handle LDM relocs. Frob the
+ symbol index when relaxing LDM to TPREL.
+ (elf64_alpha_relax_section): Likewise. Allow relaxation of GD
+ relocs, even if the target isn't locally defined.
+ (elf64_alpha_check_relocs): Frob LDM reloc symndx to zero.
+ (elf64_alpha_relocate_section): Likewise. Force TP-relative
+ relocs vs symndx 0 to the tp base.
+
+2003-01-21 Fabio Alemagna <falemagn@aros.org>
+
+ * config.bfd: Handle i[3456]86-*-aros*.
+
+2003-01-21 Andreas Schwab <schwab@suse.de>
+
+ * elf32-ppc.c (struct ppc_elf_dyn_relocs): Define.
+ (struct ppc_elf_link_hash_entry): Define.
+ (ppc_elf_hash_entry): New function.
+ (struct ppc_elf_link_hash_table): Define.
+ (ppc_elf_hash_table): New function.
+ (ppc_elf_link_hash_newfunc): New function.
+ (ppc_elf_link_hash_table_create): New function.
+ (ppc_elf_copy_indirect_symbol): New function.
+ (allocate_dynrelocs): New function.
+ (readonly_dynrelocs): New function.
+ (ppc_elf_size_dynamic_sections): Allocate space for dynamic
+ relocs and determine DT_TEXTREL.
+ (ppc_elf_check_relocs): Don't do that here, just count the
+ dynamic relocs.
+ (ppc_elf_gc_sweep_hook): Discard any dynamic relocs against the
+ removed section.
+ (bfd_elf32_bfd_link_hash_table_create): Define.
+ (elf_backend_copy_indirect_symbol): Define.
+
+2003-01-21 Richard Henderson <rth@redhat.com>
+
+ * elf64-alpha.c (alpha_dynamic_entries_for_reloc): GOTTPREL and
+ TPREL also get a reloc if shared. Remove SREL support.
+ (elf64_alpha_emit_dynrel): New.
+ (elf64_alpha_relocate_section): Use it. Resolve dynamic TPREL
+ and GOTTPREL relocs to local symbols against the tp base.
+ (elf64_alpha_finish_dynamic_symbol): Use elf64_alpha_emit_dynrel.
+
+ * elf64-alpha.c (elf64_alpha_relax_got_load): Decrement got
+ use count before clobbering r_type.
+ (elf64_alpha_relax_tls_get_addr): Don't use pos[1] if insn
+ ordering would mean dataflow inspection is necessary.
+
+2003-01-20 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * coffcode.h (coff_set_flags): Added get/set arch hooks.
+
+2003-01-20 Fabio Alemagna <falemagn@aros.org>
+
+ * elf32-sh.c: Treat elfNN_bed like other macros defined in
+ elfxx-target.h and #undef it before #define'ing it.
+ * elf32-i386.c: Likewise.
+ * elf32-sh64.c: Likewise.
+ * elf64-alpha.c: Likewise.
+ * elf64-sh64.c: Likewise.
+
+2003-01-20 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * bfd-in2.h: Regenerate.
+ * elf32-s390.c (elf_s390_adjust_gotplt): New prototype.
+ (elf_howto_table): Rename R_390_GOTOFF to R_390_GOTOFF32. Add
+ R_390_GOTOFF16, R_390_GOTOFF64, R_390_GOTPLT12, R_390_GOTPLT16,
+ R_390_GOTPLT32, R_390_GOTPLT64, R_390_GOTPLTENT, R_390_PLTOFF16,
+ R_390_PLTOFF32 and R_390_PLTOFF64.
+ (elf_s390_reloc_type_lookup): Likewise.
+ (struct elf_s390_link_hash_entry): Add gotplt_refcount to keep track
+ of GOTPLT references to a function.
+ (link_hash_newfunc): Initialize gotplt_refcount.
+ (elf_s390_check_relocs): Move allocation of local_got_refcounts array
+ and creation of the got section out of the main switch. Add support
+ for the gotoff, gotplt and pltoff relocations.
+ (elf_s390_gc_sweep_hook): Add reference counting for gotoff, gotplt
+ and pltoff.
+ (elf_s390_adjust_gotplt): New function.
+ (elf_s390_adjust_dynamic_symbol): Adjust gotplt refcount for removed
+ plt entries.
+ (allocate_dynrelocs): Add comment.
+ (elf_s390_relocate_section): Change r_type to unsigned. Add support
+ for gotoff, gotplt and pltoff relocations.
+ * elf64-s390.c: Same changes as for elf32-s390.c.
+ * libbfd.h: Regenerate.
+ * reloc.c: Add BFD_RELOC_390_GOTOFF64, BFD_RELOC_390_GOTPLT12,
+ BFD_RELOC_390_GOTPLT16, BFD_RELOC_390_GOTPLT32, BFD_RELOC_390_GOTPLT64,
+ BFD_RELOC_390_GOTPLTENT, BFD_RELOC_390_PLTOFF16, BFD_RELOC_390_PLTOFF32
+ and BFD_RELOC_390_PLTOFF64.
+
+2003-01-18 Jakub Jelinek <jakub@redhat.com>
+
+ * elfxx-ia64.c (elfNN_ia64_relocate_section): Handle
+ R_IA64_TPREL64[LM]SB against non-global symbol properly.
+
+2003-01-16 Jakub Jelinek <jakub@redhat.com>
+
+ * elfxx-ia64.c (struct elfNN_ia64_link_hash_table): Add
+ self_dtpmod_done and self_dtpmod_offset.
+ (allocate_global_data_got): Only use one got entry for all
+ dtpmod relocs against local symbols.
+ (allocate_dynrel_entries): Only need .rela.got entry for
+ dtpmod against global symbol.
+ (elfNN_ia64_size_dynamic_sections): Initialize self_dtpmod_offset.
+ Reserve space in .rela.got for the local dtpmod entry.
+ (set_got_entry): Initialize the common local dtpmod .got entry.
+ (elfNN_ia64_relocate_section): Handle R_IA_64_DTPREL64LSB
+ and R_IA_64_DTPREL64MSB.
+
+2003-01-16 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c: Include elf/ppc64.h rather than elf/ppc.h.
+ (R_PPC_*): Rename all occurrences to R_PPC64_*.
+ (R_PPC64_ADDR30): Rename all occurrences to R_PPC64_REL30.
+ (enum elf_ppc_reloc_type): Ditto to enum elf_ppc64_reloc_type.
+ (ppc64_elf_gc_sweep_hook): Handle R_PPC64_REL30 along with other
+ relative relocs, not with absolute ones.
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * po/SRC-POTFILES.in: Regenerate.
+
+2003-01-15 Andreas Schwab <schwab@suse.de>
+
+ * elf32-ppc.c (ppc_elf_check_relocs): Don't set DF_TEXTREL for a
+ relocation against a non-allocated readonly section.
+
+2003-01-10 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c (ppc_elf_relocate_section): Adjust addend for GOT16_HA.
+ * elf64-ppc.c (ppc64_elf_relocate_section): Likewise. PLTGOT16_HA too.
+
+2002-01-08 Klee Dienes <kdienes@apple.com>
+
+ * Makefile.am (ALL_MACHINES): Use cpu-msp430.lo, not cpu-msp430.c.
+ (BFD32_BACKENDS): Use elf32-msp430.lo, not elf32-msp430.c.
+ * Makefile.in: Regenerate.
+
+2003-01-08 Alexandre Oliva <aoliva@redhat.com>
+
+ * elfn32-mips.c (prev_reloc_section): New.
+ (GET_RELOC_ADDEND): Use it. Parenthesize macro arguments.
+ (SET_RELOC_ADDEND): Parenthesize macro argument.
+
+2003-01-07 John David Anglin <dave.anglin@nrc.gc.ca>
+
+ * elf32-hppa.c (final_link_relocate): For all DP relative relocations,
+ adjust addil instructions if the symbol has no section.
+
+2003-01-07 DJ Delorie <dj@redhat.com>
+
+ * elf32-xstormy16.c (xstormy16_elf_howto_table): Make REL_12 not
+ partial_inplace.
+
+2003-01-07 Andreas Schwab <schwab@suse.de>
+
+ * elf32-m68k.c (elf_m68k_check_relocs): Don't set DF_TEXTREL for
+ PC relative relocations.
+ (elf_m68k_discard_copies): Set it here instead.
+
+2002-01-02 Ben Elliston <bje@redhat.com>
+ Jeff Johnston <jjohnstn@redhat.com>
+
+ * Makefile.am (ALL_MACHINES): Add cpu-iq2000.lo.
+ (ALL_MACHINES_CFILES): Add cpu-iq2000.c.
+ (BFD32_BACKENDS): Add elf32-iq2000.lo.
+ (BFD32_BACKENDS_CFILES): Add elf32-iq2000.c.
+ (cpu-iq2000.lo): New target.
+ * Makefile.in: Regenerate.
+ * config.bfd: Handle iq2000-*-elf.
+ * archures.c (bfd_architecture): Add bfd_{arch,mach}_iq2000.
+ (bfd_archures_list): Add bfd_iq2000_arch.
+ * configure.in: Handle bfd_elf32_iq2000_vec.
+ * configure: Regenerate.
+ * reloc.c: Add BFD_RELOC_IQ2000_OFFSET_16, BFD_RELOC_IQ2000_OFFSET_21,
+ and BFD_RELOC_IQ2000_UHI16.
+ * targets.c (bfd_elf32_iq2000_vec): Declare.
+ (bfd_target_vector): Add bfd_elf32_iq2000_vec.
+ * elf.c (prep_headers): Set e_machine to EM_IQ2000.
+ * cpu-iq2000.c: New file.
+ * elf32-iq2000.c: Likewise.
+ * libbfd.h: Regenerate.
+ * bfd-in2.h: Likewise.
+
+2003-01-02 Richard Sandiford <rsandifo@redhat.com>
+
+ * elfxx-mips.c: Include libiberty.h.
+ (elf_mips_isa, _bfd_mips_elf_mach_extends_p): Remove.
+ (mips_set_isa_flags): New function, split out from...
+ (_bfd_mips_elf_final_write_processing): ...here. Only call
+ mips_set_isa_flags if the EF_MIPS_MACH bits are clear.
+ (mips_mach_extensions): New array.
+ (mips_32bit_flags_p): New function.
+ (_bfd_mips_elf_merge_private_bfd_data): Rework architecture checks.
+ Use mips_32bit_flags_p to check if one binary is 32-bit and the
+ other is 64-bit. When adopting IBFD's architecture, adopt the
+ bfd_mach as well as the flags.
+
+2003-01-02 Nick Kelsey <nickk@ubicom.com>
+
+ * elf32-ip2k.c: Re-work of linker relaxation code for the ip2k to
+ fix internal errors, fix bad code generation, fix incorrect stabs
+ information, and improve ability to eliminate redundant page
+ instructions. Added code to ip2k_final_link_relocate to self-verify
+ the linker relaxation. Fix formatting problems.
+
+2002-12-30 Chris Demetriou <cgd@broadcom.com>
+
+ * aoutx.h (NAME(aout,machine_type)): Add bfd_mach_mipsisa32r2 case.
+ * archures.c (bfd_mach_mipsisa32r2): New define.
+ * bfd-in2.h: Regenerate.
+ * cpu-mips.c (I_mipsisa32r2): New enum value.
+ (arch_info_struct): Add entry for I_mipsisa32r2.
+ * elfxx-mips.c (elf_mips_isa, _bfd_elf_mips_mach)
+ (_bfd_mips_elf_print_private_bfd_data): Handle E_MIPS_ARCH_32R2.
+ (_bfd_mips_elf_final_write_processing): Add
+ bfd_mach_mipsisa32r2 case.
+ (_bfd_mips_elf_merge_private_bfd_data): Handle merging of
+ binaries marked as using MIPS32 Release 2.
+
+2002-12-30 Dmitry Diky <diwil@mail.ru>
+
+ * Makefile.am: Add msp430 target.
+ * configure.in: Likewise.
+ * Makefile.in: Regenerate.
+ * configure: Regenerate.
+ * archures.c: Add msp430 architecture vector.
+ * config.bfd: Likewise.
+ * reloc.c: Add msp430 relocs.
+ * targets.c: Add msp320 target.
+ * cpu-msp430.c: New file: msp430 cpu detection.
+ * elf32-msp430.c: New file: msp430 reloc processing.
+ * bfd-in2.h: Regenerate.
+ * libbfd.h: Regenerate.
+
+2002-12-28 Jakub Jelinek <jakub@redhat.com>
+
+ * elf.c (elf_sort_sections): Don't reorder .tbss.
+ (assign_file_positions_for_segments): Only adjust off/voff
+ for increased alignment in PT_LOAD or PT_NOTE segment,
+ but adjust p_filesz for .tbss too. in PT_LOAD consider
+ .tbss to have zero memory size.
+ (copy_private_bfd_data) [SECTION_SIZE]: Define.
+ [IS_CONTAINED_BY_VMA, IS_CONTAINED_BY_LMA]: Use it.
+ [INCLUDE_SECTION_IN_SEGMENT]: Only put SHF_TLS sections
+ into PT_TLS segment. Never put SHF_TLS sections in
+ segments other than PT_TLS or PT_LOAD.
+
+ * elf64-alpha.c (elf64_alpha_finish_dynamic_sections): Clear .plt
+ sh_entsize.
+
+2002-12-23 DJ Delorie <dj@redhat.com>
+
+ * coff64-rs6000.c (xcoff64_ppc_relocate_section): Fix logic reversal.
+
+2002-12-23 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h (elf_link_output_extsym): Heed strip_discarded.
+
+2002-12-23 Nick Clifton <nickc@redhat.com>
+
+ * archures.c (bfd_arch_get_compatible): Add third parameter
+ 'accept_unknowns'. Only accept unknown format BFDs if
+ accept_unknowns is true, or if the format is "binary".
+ * bfd-in2.h: Regenerate.
+
+2002-12-21 Nick Clifton <nickc@redhat.com>
+
+ * coff-arm.c (coff_arm_relocate_section): Disable WINCE workaround
+ that subtracted 8 from pc relative relocations.
+
+2002-12-20 Kazu Hirata <kazu@cs.umass.edu>
+
+ * coff-h8300.c: Fix comment typos.
+ * coffcode.h: Likewise.
+ * cpu-cris.c: Likewise.
+ * elf32-vax.c: Likewise.
+ * genlink.h: Likewise.
+ * linker.c: Likewise.
+ * som.c: Likewise.
+ * tekhex.c: Likewise.
+ * vms-misc.c: Likewise.
+
+2002-12-20 DJ Delorie <dj@redhat.com>
+
+ * reloc.c: Add BFD_RELOC_XSTORMY16_12.
+ * libbfd.h: Regenerate.
+ * bfd-in2.h: Regenerate.
+ * elf32-xstormy16.c (xstormy16_elf_howto): Add R_XSTORMY16_12.
+ (xstormy16_reloc_map): Add R_XSTORMY16_12.
+
+2002-12-19 Kazu Hirata <kazu@cs.umass.edu>
+
+ * doc/bfdint.texi: Fix typos.
+
+2002-12-20 Paul Eggert <eggert@twinsun.com>
+
+ Port to POSIX 1003.1-2001.
+ * acinclude.m4 (AM_INSTALL_LIBBFD): Do not rely on "test -o".
+ * configure.in (build-warnings): Likewise.
+ (Horrible hacks to build DLLs on Windows): Do not rely on "tail -1".
+ * aclocal.m4: Regenerate.
+ * config.in: Regenerate.
+ * configure: Regenerate.
+
+2002-12-19 Alan Modra <amodra@bigpond.net.au>
+
+ * coff-h8300.c: Include libiberty.h.
+ (h8300_reloc16_extra_cases): Check the hash table creator before
+ referencing h8300 specific fields. Stash the hash table pointer
+ in a local var. Comment typo fixes.
+ (h8300_bfd_link_add_symbols): Likewise.
+
+ * reloc.c (struct reloc_howto_struct): Revise src_mask and
+ dst_mask comments.
+ * bfd-in2.h: Regenerate.
+
+2002-12-18 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c (ppc_elf_relocate_section): Reorganize dynamic reloc
+ code a little. Comment on dynamic relocs against section symbols.
+
+2002-12-17 Roger Sayle <roger@eyesopen.com>
+
+ * configure.host (ia64-*-hpux*): Support 64 bit targets using
+ the HP compiler's "long long".
+
+2002-12-16 Andrew MacLeod <amacleod@redhat.com>
+
+ * elf32-xstormy16.c (xstormy16_elf_howto): Add R_XSTORMY16_LO16
+ and R_XSTORMY16_HI16) howto entries.
+ (xstormy16_reloc_map): Map R_XSTORMY16_{LO,HI}16 to BFD_RELOC_{LO,HI}16.
+ (xstormy16_info_to_howto_rela): Use R_XSTORMY16_GNU_VTINHERIT to
+ determine the start of the second reloc table.
+
+2002-12-16 Nathan Tallent <eraxxon@alumni.rice.edu>
+
+ * ecofflink.c: Fix the reading of the debugging information
+ of Tru64/Alpha binaries that are produced by recent Compaq
+ compilers.
+ (mk_fdrtab): Fix error in creating the FDR (file descriptor)
+ table.
+ (lookup_line): Because of the strange information sometimes
+ generated by Compaq's recent compilers, change how the FDR
+ table is searched so that PDRs (procedure descriptors) are
+ correctly found. Note that this change is really more of a hack;
+ however, I have included extensive documentation as to why
+ this is the best solution short of an extensive rewrite or
+ another hack.
+ (fdrtab_lookup): Add comments to explain the algorithm.
+
+2002-12-12 Alexandre Oliva <aoliva@redhat.com>
+
+ * elf-m10300.c (elf32_mn10300_link_hash_newfunc): Reorder
+ initializers to match struct declaration.
+
+2002-12-12 Alan Modra <amodra@bigpond.net.au>
+
+ * dwarf2.c (comp_unit_contains_address): Comment typo fix.
+ * elf.c (get_program_header_size): Likewise.
+ * elf32-m32r.c (m32r_elf_lo16_reloc): Likewise.
+ (m32r_elf_generic_reloc): Likewise.
+ * elf32-ppc.c (ppc_elf_howto_init): Likewise.
+ * elflink.h (elf_bfd_discard_info): Likewise.
+
+2002-12-12 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-i386.c (elf_i386_finish_dynamic_sections): Add output_offset
+ to DT_JMPREL. Use srelplt input section size for DT_PLTRELSZ and
+ DT_RELSZ adjustment, not output section. Avoid writing tags when
+ unchanged. Don't assume linker script is sane, adjust DT_REL too.
+ * elf32-hppa.c (elf32_hppa_finish_dynamic_sections): Just use raw
+ size of srelplt for DT_PLTRELSZ. Use srelplt input section size for
+ DT_RELASZ adjustment, not output section. Avoid writing tags when
+ unchanged. Adjust DT_RELA.
+ * elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Tweaks for better
+ formatting. Avoid writing tags when unchanged. Adjust DT_RELA.
+
+2002-12-12 Alexandre Oliva <aoliva@redhat.com>
+
+ * elfxx-mips.c (mips_elf_calculate_relocation): Don't divide
+ addend by 4.
+
+2002-12-12 Alexandre Oliva <aoliva@redhat.com>
+
+ * elfxx-mips.c (struct mips_got_entry): New.
+ (struct mips_got_info): Added got_entries field.
+ (mips_elf_got_entry_hash, mips_elf_got_entry_eq): New functions.
+ (mips_elf_local_got_index, mips_elf_got_page,
+ mips_elf_got16_entry): Re-implement in terms of new...
+ (mips_elf_create_local_got_entry): Rewrite to use got_entries.
+ Change return type.
+ (mips_elf_highest): Warning clean-up.
+ (mips_elf_create_got_section): Initialize got_entries.
+ (_bfd_mips_elf_check_relocs): Use got_entries to estimate
+ local got size.
+ (_bfd_mips_elf_size_dynamic_sections): Do not account for
+ GOT_PAGE entries, since we now reuse GOT16 entries.
+
+2002-12-10 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * aoutx.h (set_section_contents): Allow an otherwise unrepresentable
+ read-only section that lies after .text and before .data to be
+ written into the output file and included in a_text.
+ (translate_to_native_sym_flags): If an otherwise unrepresentable
+ section was merged with .text, convert its symbols to N_TEXT
+ symbols.
+ * libaout.h (aout_section_merge_with_text_p): New macro.
+
+2002-12-08 Alan Modra <amodra@bigpond.net.au>
+
+ * bfd-in.h: Comment typo fix. Formatting.
+ * bfd-in2.h: Regenerate.
+ * coff64-rs6000.c (xcoff64_openr_next_archived_file): Warning fix.
+ * elf32-m68hc12.c (m68hc12_elf_set_mach_from_flags): Prototype.
+ * elf64-mmix.c (mmix_dump_bpo_gregs): Warning fix.
+
+2002-12-05 Richard Henderson <rth@redhat.com>
+
+ * elfxx-ia64.c (elfNN_ia64_relax_section): Handle PCREL21BI.
+ Only send PCREL21B though the plt. Fix installed reloc type.
+ (elfNN_ia64_relocate_section): Give error for dynamic reloc
+ against PCREL22 or PCREL64I; clean up error messages for
+ branch relocs.
+
+2002-12-04 Kevin Buettner <kevinb@redhat.com>
+
+ * elf64-mips.c (elf64_mips_grok_prstatus, elf64_mips_grok_psinfo):
+ New functions.
+ (elf_backend_grok_prstatus, elf_backend_grok_psinfo): Define.
+
+2002-12-04 David Mosberger <davidm@hpl.hp.com>
+
+ * cpu-ia64-opc.c: Add operand constant "ar.csd".
+
+2002-12-04 H.J. Lu <hjl@gnu.org>
+
+ * elfxx-ia64.c (get_local_sym_hash): Use section ID instead of
+ BFD address when constructing local name.
+
+2002-12-04 Andreas Schwab <schwab@suse.de>
+
+ * elf32-m68k.c (struct elf_m68k_link_hash_table): Add sym_sec
+ member.
+ (elf_m68k_link_hash_table_create): Initialize it.
+ (elf_m68k_check_relocs): Handle symbols that are forced to be
+ local due to visibility changes.
+ (elf_m68k_adjust_dynamic_symbol): Likewise.
+ (elf_m68k_size_dynamic_sections): Likewise.
+ (elf_m68k_discard_copies): Likewise.
+ (elf_m68k_relocate_section): Likewise.
+
+2002-12-04 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_edit_opd): Correct typo.
+
+2002-12-04 Alan Modra <amodra@bigpond.net.au>
+
+ * srec.c (srec_write_symbols): Restore '$' prefix to address
+ accidentally removed in 2002-04-04 change.
+ (srec_get_symtab): Use 0 instead of `(long) FALSE'.
+
+2002-12-03 Nick Clifton <nickc@redhat.com>
+
+ * elf32-ppc.c (apuinfo_list_init): New function.
+ (apuinfo_list_add): New function: Add a value to the list.
+ (apuinfo_list_length): New function: Return the number of
+ values on the list.
+ (apuinfo_list_element): New function: Return a value on the
+ list.
+ (apuinfo_list_finish): New function: Free the resources used
+ by the list.
+ (ppc_elf_begin_write_processing): New function. Scan the
+ input bfds for apuinfo sections.
+ (ppc_elf_write_section): New function: Delay the creation of
+ the contents of an apuinfo section in an output bfd.
+ (ppc_elf_final_write_processing): New function. Create the
+ contents of an apuinfo section in an output bfd.
+ (elf_backend_begin_write_processing): Define.
+ (elf_backend_final_write_processing): Define.
+ (elf_backend_write_section): Define.
+
+2002-12-03 Richard Henderson <rth@redhat.com>
+
+ * cpu-ia64-opc.c (elf64_ia64_operands): Add ldxmov entry.
+
+2002-12-01 Stephane Carrez <stcarrez@nerim.fr>
+
+ Fix PR savannah/1417:
+ * elf32-m68hc11.c (m68hc11_elf_relax_delete_bytes): Don't adjust
+ branch if it goes to the start of the deleted region.
+
+2002-12-01 Stephane Carrez <stcarrez@nerim.fr>
+
+ * bfd-in2.h (bfd_mach_m6812): Rebuild.
+ * archures.c (bfd_mach_m6812_default, bfd_mach_m6812,
+ bfd_mach_m6812s): Declare.
+
+ * elf32-m68hc12.c (m68hc12_elf_set_mach_from_flags): New function.
+ (_bfd_m68hc12_elf_set_private_flags): Call it.
+ (_bfd_m68hc12_elf_print_private_bfd_data): Report processor version.
+ (_bfd_m68hc12_elf_merge_private_bfd_data): Merge the flags and
+ report microcontroller incompatibilities (HC12 vs HCS12).
+ (elf_backend_object_p): Update.
+
+2002-11-30 Alan Modra <amodra@bigpond.net.au>
+
+ * bfd-in.h (TRUE_FALSE_ALREADY_DEFINED, BFD_TRUE_FALSE): Delete.
+ (enum bfd_boolean, boolean): Delete.
+ (bfd_boolean): Typedef to an int.
+ (FALSE, TRUE): Define.
+ * aix386-core.c, aix5ppc-core.c, aout-adobe.c, aout-arm.c, aout-cris.c,
+ aout-encap.c, aout-ns32k.c, aout-target.h, aout-tic30.c, aoutf1.h,
+ aoutx.h, archive.c, archive64.c, archures.c, bfd-in.h, bfd.c, bfdwin.c,
+ binary.c, bout.c, cache.c, cisco-core.c, coff-a29k.c, coff-alpha.c,
+ coff-apollo.c, coff-arm.c, coff-aux.c, coff-h8300.c, coff-h8500.c,
+ coff-i386.c, coff-i860.c, coff-i960.c, coff-ia64.c, coff-m68k.c,
+ coff-m88k.c, coff-mcore.c, coff-mips.c, coff-or32.c, coff-ppc.c,
+ coff-rs6000.c, coff-sh.c, coff-sparc.c, coff-stgo32.c, coff-tic30.c,
+ coff-tic4x.c, coff-tic54x.c, coff-tic80.c, coff-w65.c, coff-we32k.c,
+ coff-z8k.c, coff64-rs6000.c, coffcode.h, coffgen.c, cofflink.c,
+ corefile.c, cpu-a29k.c, cpu-alpha.c, cpu-arc.c, cpu-arm.c, cpu-avr.c,
+ cpu-cris.c, cpu-d10v.c, cpu-d30v.c, cpu-dlx.c, cpu-fr30.c, cpu-frv.c,
+ cpu-h8300.c, cpu-h8500.c, cpu-hppa.c, cpu-i370.c, cpu-i386.c,
+ cpu-i860.c, cpu-i960.c, cpu-ia64.c, cpu-ip2k.c, cpu-m10200.c,
+ cpu-m10300.c, cpu-m32r.c, cpu-m68hc11.c, cpu-m68hc12.c, cpu-m68k.c,
+ cpu-m88k.c, cpu-mcore.c, cpu-mips.c, cpu-mmix.c, cpu-ns32k.c,
+ cpu-openrisc.c, cpu-or32.c, cpu-pdp11.c, cpu-pj.c, cpu-powerpc.c,
+ cpu-rs6000.c, cpu-s390.c, cpu-sh.c, cpu-sparc.c, cpu-tic30.c,
+ cpu-tic4x.c, cpu-tic54x.c, cpu-tic80.c, cpu-v850.c, cpu-vax.c,
+ cpu-w65.c, cpu-we32k.c, cpu-xstormy16.c, cpu-z8k.c, dwarf1.c,
+ dwarf2.c, ecoff.c, ecofflink.c, efi-app-ia32.c, efi-app-ia64.c,
+ elf-bfd.h, elf-eh-frame.c, elf-hppa.h, elf-m10200.c, elf-m10300.c,
+ elf-strtab.c, elf.c, elf32-arc.c, elf32-arm.h, elf32-avr.c,
+ elf32-cris.c, elf32-d10v.c, elf32-d30v.c, elf32-dlx.c, elf32-fr30.c,
+ elf32-frv.c, elf32-gen.c, elf32-h8300.c, elf32-hppa.c, elf32-hppa.h,
+ elf32-i370.c, elf32-i386.c, elf32-i860.c, elf32-i960.c, elf32-ip2k.c,
+ elf32-m32r.c, elf32-m68hc11.c, elf32-m68hc12.c, elf32-m68k.c,
+ elf32-mcore.c, elf32-mips.c, elf32-openrisc.c, elf32-or32.c,
+ elf32-pj.c, elf32-ppc.c, elf32-s390.c, elf32-sh.c, elf32-sh64-com.c,
+ elf32-sh64.c, elf32-sparc.c, elf32-v850.c, elf32-vax.c,
+ elf32-xstormy16.c, elf64-alpha.c, elf64-gen.c, elf64-hppa.c,
+ elf64-mips.c, elf64-mmix.c, elf64-ppc.c, elf64-ppc.h, elf64-s390.c,
+ elf64-sh64.c, elf64-sparc.c, elf64-x86-64.c, elfarm-nabi.c,
+ elfarm-oabi.c, elfcode.h, elfcore.h, elflink.c, elflink.h,
+ elfn32-mips.c, elfxx-ia64.c, elfxx-mips.c, elfxx-mips.h,
+ elfxx-target.h, format.c, freebsd.h, genlink.h, hash.c, hp300hpux.c,
+ hppabsd-core.c, hpux-core.c, i386aout.c, i386linux.c, i386lynx.c,
+ i386mach3.c, i386msdos.c, i386os9k.c, ieee.c, ihex.c, irix-core.c,
+ libaout.h, libbfd-in.h, libbfd.c, libcoff-in.h, libecoff.h, libieee.h,
+ libnlm.h, liboasys.h, libpei.h, libxcoff.h, linker.c, lynx-core.c,
+ m68klinux.c, m68klynx.c, mach-o.c, mach-o.h, merge.c, mipsbsd.c,
+ mmo.c, netbsd-core.c, netbsd.h, nlm.c, nlm32-alpha.c, nlm32-i386.c,
+ nlm32-ppc.c, nlm32-sparc.c, nlmcode.h, oasys.c, opncls.c, osf-core.c,
+ pc532-mach.c, pdp11.c, pe-arm.c, pe-i386.c, pe-mcore.c, pe-mips.c,
+ pe-sh.c, peXXigen.c, pef.c, pei-arm.c, pei-i386.c, pei-mcore.c,
+ pei-mips.c, pei-sh.c, peicode.h, ppcboot.c, ptrace-core.c, reloc.c,
+ reloc16.c, riscix.c, rs6000-core.c, sco5-core.c, section.c, simple.c,
+ som.c, som.h, sparclinux.c, sparclynx.c, srec.c, stabs.c, sunos.c,
+ syms.c, targets.c, tekhex.c, ticoff.h, trad-core.c, versados.c,
+ vms-gsd.c, vms-hdr.c, vms-misc.c, vms-tir.c, vms.c, vms.h,
+ xcoff-target.h, xcofflink.c, xsym.c, xsym.h: Replace boolean with
+ bfd_boolean, true with TRUE, false with FALSE. Simplify comparisons
+ of bfd_boolean vars with TRUE/FALSE. Formatting.
+ * bfd-in2.h, libbfd.h, libcoff.h: Regenerate
+
+2002-11-28 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h: Replace occurrences of Elf32_Internal_* and
+ Elf64_Internal_* with Elf_Internal_*. Replace Elf_Internal_Rel
+ with Elf_Internal_Rela.
+ * elf-hppa.h, elf-m10200.c, elf-m10300.c, elf32-arc.c, elf32-arm.h,
+ elf32-avr.c, elf32-cris.c, elf32-d10v.c, elf32-d30v.c, elf32-dlx.c,
+ elf32-fr30.c, elf32-frv.c, elf32-gen.c, elf32-h8300.c, elf32-hppa.c,
+ elf32-i370.c, elf32-i386.c, elf32-i860.c, elf32-i960.c, elf32-ip2k.c,
+ elf32-m32r.c, elf32-m68hc11.c, elf32-m68hc12.c, elf32-m68k.c,
+ elf32-mcore.c, elf32-mips.c, elf32-openrisc.c, elf32-or32.c,
+ elf32-ppc.c, elf32-s390.c, elf32-sh.c, elf32-v850.c, elf32-vax.c,
+ elf32-xstormy16.c, elf64-alpha.c, elf64-gen.c, elf64-hppa.c,
+ elf64-mips.c, elf64-mmix.c, elf64-ppc.c, elf64-s390.c, elf64-sh64.c,
+ elf64-sparc.c, elf64-x86-64.c, elfarm-nabi.c, elfarm-oabi.c,
+ elfcode.h, elflink.h, elfn32-mips.c, elfxx-ia64.c, elfxx-mips.c: Ditto.
+ * elf-hppa.h (elf_hppa_internal_shdr): Delete. Use Elf_Internal_Shdr
+ throughout instead.
+ * elf.c (_bfd_elf_no_info_to_howto_rel): Delete.
+ * elfcode.h (elf_swap_reloca_in): Pass source operand as a bfd_byte *.
+ Remove INLINE keyword.
+ (elf_swap_reloc_in): Likewise. Also clear r_addend.
+ (elf_swap_reloc_out, elf_swap_reloca_out): Pass destination operand
+ as a bfd_byte *.
+ (elf_write_relocs): Consolidate REL and RELA code.
+ (elf_slurp_reloc_table_from_section): Simplify REL code.
+ (NAME(_bfd_elf,size_info)): Populate reloc swap entries.
+ * elf-bfd.h (MAX_INT_RELS_PER_EXT_REL): Define.
+ * elflink.h (elf_link_read_relocs_from_section): Consolidate REL and
+ RELA code.
+ (elf_link_adjust_relocs): Likewise. Don't malloc space for temp
+ reloc array, use a fixed size of MAX_INT_RELS_PER_EXT_REL.
+ (elf_link_output_relocs): Likewise.
+ (elf_reloc_link_order): Likewise.
+ (elf_finish_pointer_linker_section): Likewise.
+ (struct elf_link_sort_rela): Remove union.
+ (elf_link_sort_cmp1): Update to suit.
+ (elf_link_sort_cmp2): Here too.
+ (elf_link_sort_relocs): Consolidate REL and RELA code. Fix memory
+ over-allocation for int_rels_per_ext_rel != 1 case.
+ * elf32-arm.h: Update all bfd_elf32_swap_reloc_out calls.
+ * elf32-i386.c: Likewise.
+ * elf32-cris.c: Likewise for bfd_elf32_swap_reloca_out.
+ * elf32-hppa.c, elf32-i370.c, elf32-m68k.c, elf32-ppc.c, elf32-s390.c,
+ elf32-sh.c, elf32-vax.c, elfxx-mips.c: Likewise.
+ * elf64-alpha.c: Likewise for bfd_elf64_swap_reloca_out.
+ * elf64-hppa.c, elf64-mips.c, elf64-ppc.c, elf64-s390.c, elf64-sh64.c,
+ elf64-sparc.c, elf64-x86-64.c: Likewise.
+ * elfxx-ia64.c: Likewise for bfd_elfNN_swap_reloca_out.
+ * elfxx-mips.c (sort_dynamic_relocs): Likewise for
+ bfd_elf32_swap_reloc_in.
+
+ * elf32-arm.h: Update elf32_arm_info_to_howto calls.
+ * elf32-mips.c: Likewise for mips_info_to_howto_rel.
+ (mips_elf64_swap_reloc_in): Zero r_addend.
+ (mips_elf64_be_swap_reloc_in): Likewise.
+ (mips_elf64_slurp_one_reloc_table): Simplify.
+
+ * elf64-alpha.c (alpha_elf_size_info): Populate reloc swap entries.
+ * elf64-hppa.c (hppa64_elf_size_info): Likewise.
+ * elf64-sparc.c (sparc64_elf_size_info): Likewise.
+
+2002-11-28 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * elf32-sh.c (sh_elf_relocate_section): Don't complain about
+ unresolved debugging relocs in dynamic applications.
+ * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
+
+2002-11-26 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-eh-frame.c (ENSURE_NO_RELOCS): Disregard R_*_NONE relocs.
+ (_bfd_elf_discard_section_eh_frame): Don't discard duplicate CIEs
+ on a relocatable link. Comment typos.
+ * elf.c (_bfd_elf_link_hash_newfunc): Assign elements of structure
+ in the order they are declared. Clear elf_hash_value too.
+ (_bfd_elf_link_hash_table_init): Likewise assign in order. Clear
+ eh_info and tls_segment.
+ * elflink.h (elf_link_input_bfd <emit_relocs>): Keep reloc offsets
+ sorted when discarding relocs by turning them into R_*_NONE.
+
+ * libbfd.c (warn_deprecated): Comment spelling.
+ * po/SRC-POTFILES.in: Regenerate.
+
+2002-11-21 Richard Henderson <rth@redhat.com>
+
+ * elflink.h (elf_link_add_object_symbols): Don't overwrite the
+ arch's st_other bits when merging visibilities.
+ (elf_link_output_extsym): Tidy clearing of visibility field.
+
+2002-11-21 Alan Modra <amodra@bigpond.net.au>
+
+ * coff-mcore.c (SWAP_IN_RELOC_OFFSET): Define.
+ (SWAP_OUT_RELOC_OFFSET): Define.
+
+2002-11-20 Alexandre Oliva <aoliva@redhat.com>
+
+ * elf.c (_bfd_elf_link_hash_table_init): Make sure
+ can_refcount is properly extended to the type of
+ init_refcount.
+
+2002-11-19 Alexandre Oliva <aoliva@redhat.com>
+
+ * elfxx-mips.c (MIPS_RELOC_RELA_P): New macro.
+ (_bfd_mips_elf_relocate_section): Use it.
+
+ * elfxx-mips.c (MNAME): New macro.
+ (_bfd_mips_elf_check_relocs): Use it.
+ (_bfd_mips_elf_discard_info): Likewise.
+ (_bfd_mips_elf_final_link): Likewise.
+
+2002-11-19 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_edit_opd): When deleting relocs, adjust
+ rel_hdr.sh_size too.
+
+2002-11-18 Klee Dienes <kdienes@apple.com>
+
+ * Makefile.am (BFD32_LIBS): Add bfdwin.lo, bfdio.lo.
+ (BFD32_LIBS_CFILES): Add bfdwin.c, bfdio.c.
+ (BFD_H_FILES): Add bfdwin.c, bfdio.c.
+ (LIBBFD_H_FILES): Add bfdwin.c, bfdio.c.
+ Add dependencies for bfdwin.c, bfdio.c.
+ * bfd.c: Remove bfd_get_mtime, bfd_get_size.
+ * libbfd.c: Remove real_read, bfd_bread, _bfd_window_internal,
+ bfd_init_window, bfd_free_window, bfd_get_file_window, bfd_bwrite,
+ bfd_tell, bfd_flush, bfd_stat, bfd_seek.
+ * bfdio.c: New file. Contains real_read, bfd_bread, bfd_write,
+ bfd_tell, bfd_flush, bfd_stat, bfd_seek, bfd_ge_mtime,
+ bfd_get_size (moved from libbfd.c and bfd.c).
+ * bfdwin.c New file. Contains _bfd_window_internal,
+ bfd_init_window, bfd_free_window, bfd_get_file_window (moved from
+ libbfd.c and bfd.c).
+ * po/SRC-POTFILES.in: Regenerate.
+ * po/bfd.pot: Regenerate.
+ * libbfd.h: Regenerate.
+ * bfd-in2.h: Regenerate.
+ * aclocal.m4: Regenerate.
+ * Makefile.in: Regenerate.
+ * configure: Regenerate.
+
+2002-11-18 Klee Dienes <kdienes@apple.com>
+
+ * bfd.c (bfd_preserve_save): Don't zero BFD_IN_MEMORY.
+
+2002-11-15 Kazu Hirata <kazu@cs.umass.edu>
+
+ * coff-h8300.c (h8300_reloc16_estimate): Do not optimize away
+ jsr after a short jump.
+ * elf32-h8300.c (elf32_h8_relax_section): Likewise.
+
+2002-11-15 Klee Dienes <kdienes@apple.com>
+
+ * pef.c (bfd_pef_convert_architecture): Move declaration of
+ ARCH_POWERPC and ARCH_M68K to the start of the function.
+
+2002-11-14 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * coff-tic4x.c (tic4x_howto_table): Formatting fixup
+
+2002-11-14 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * elf64-mmix.c (_bfd_mmix_finalize_linker_allocated_gregs):
+ For bpo_gregs_section->contents, allocate _raw_size, not
+ _cooked_size.
+
+2002-11-13 Klee Dienes <kdienes@apple.com>
+
+ * config.bfd: Add entries for powerpc-*-darwin and cousins.
+
+2002-11-13 H.J. Lu <hjl@gnu.org>
+
+ * elfcode.h (elf_object_p): Don't restore abfd->arch_info.
+
+2002-11-13 Klee Dienes <kdienes@apple.com>
+ Alan Modra <amodra@bigpond.net.au>
+
+ * bfd.c (struct bfd_preserve): New.
+ (bfd_preserve_save): New function.
+ (bfd_preserve_restore): Ditto.
+ (bfd_preserve_finish): Ditto.
+ * bfd-in2.h: Regenerate.
+ * mach-o.c: Formatting.
+ (bfd_mach_o_scan_read_symtab_symbol): Make "value" unsigned.
+ (bfd_mach_o_object_p): Use bfd_preserve_save/restore/finish.
+ (bfd_mach_o_core_p): Ditto.
+ (bfd_mach_o_scan): Pass in mdata.
+ * mach-o.h (bfd_mach_o_scan): Update prototype.
+ * pef.c: Formatting.
+ (bfd_pef_object_p): Use bfd_preserve_save/restore/finish.
+ (bfd_pef_xlib_object_p): Ditto.
+ (bfd_pef_scan): Pass in mdata. Move version check to bfd_pef_object_p.
+ * pef.h (bfd_pef_scan): Update prototype.
+ * xsym.c: Formatting, K&R fixes.
+ (bfd_sym_object_p): Use bfd_preserve_save/restore/finish.
+ (bfd_sym_scan): New function split out from bfd_sym_object_p.
+ * xsym.h (bfd_sym_scan): Declare.
+ * elfcode.h (elf_object_p): Use bfd_preserve_save/restore/finish.
+ * elfcore.h (elf_core_file_p): Likewise.
+ * targets.c (_bfd_target_vector): Revert 2002-11-08 change.
+
+2002-11-12 Nick Clifton <nickc@redhat.com>
+
+ * po/da.po: Updated Danish translation.
+
+2002-11-12 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h (elf_link_add_object_symbols): Optimize stabs for
+ relocatable link too.
+ (elf_link_input_bfd): When emitting relocs, adjust offsets for
+ eh_frame and stab sections. Zap deleted relocs.
+ (elf_reloc_symbol_deleted_p): Return true for zero r_symndx.
+ (elf_bfd_discard_info): Run for relocatable link too.
+ * elf64-ppc.c (ppc64_elf_edit_opd): Rename from edit_opd. Make global.
+ Handle ld -r case.
+ (ppc64_elf_size_dynamic_sections): Don't call edit_opd from here.
+ * elf64-ppc.h (ppc64_elf_edit_opd): Declare.
+
+ * elf-bfd.h (struct cie_header): Move from elf_eh-frame.c.
+ (struct cie, struct eh_cie_fde, struct eh_frame_sec_info): Likewise.
+ (struct eh_frame_array_ent, struct eh_frame_hdr_info): Likewise.
+ (enum elf_link_info_type): Remove ELF_INFO_TYPE_EH_FRAME_HDR.
+ (struct eh_frame_hdr_info): Add "hdr_sec", remove "split".
+ (struct elf_link_hash_table): Add eh_info.
+ (struct elf_obj_tdata): Change eh_frame_hdr to an asection *.
+ (_bfd_elf_discard_section_eh_frame): Update prototype.
+ (_bfd_elf_discard_section_eh_frame_hdr): Likewise.
+ (_bfd_elf_write_section_eh_frame): Likewise.
+ (_bfd_elf_write_section_eh_frame_hdr): Likewise.
+ * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Remove "ehdrsec"
+ param. Get "hdr_info" from link hash table.
+ (_bfd_elf_discard_section_eh_frame_hdr): Remove "sec" param. Get
+ header section from link hash table. Save header section to elf_tdata.
+ (_bfd_elf_maybe_strip_eh_frame_hdr): Remove local "sec". Use
+ header section from link hash table. Don't alloc hdr_info. Clear
+ hdr_sec instead of setting "strip".
+ (_bfd_elf_eh_frame_section_offset): Formatting.
+ (_bfd_elf_write_section_eh_frame): Remove "ehdrsec", add "info" param.
+ Get header section from link hash table.
+ (_bfd_elf_write_section_eh_frame_hdr): Remove "sec", add "info" param.
+ Get header section from link hash table.
+ * elf.c (map_sections_to_segments): Use cached eh_frame_hdr.
+ (get_program_header_size): Likewise.
+ (_bfd_elf_section_offset): Formatting.
+ * elflink.h (elf_link_create_dynamic_sections): Stash eh frame header
+ section pointer in link hash table.
+ (elf_bfd_final_link): Adjust _bfd_elf_write_section_eh_frame_hdr
+ and _bfd_elf_write_section_eh_frame calls. Update comment about
+ eh_frame entries.
+ (elf_bfd_discard_info): Adjust _bfd_elf_discard_section_eh_frame and
+ _bfd_elf_discard_section_eh_frame_hdr calls. Remove "ehdr".
+
+ * po/SRC-POTFILES.in: Regenerate.
+
+ * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't zero
+ relocs for discarded FDEs. Remove dead code.
+ (_bfd_elf_write_section_eh_frame_hdr): Remove dead code.
+ * elflink.h (elf_bfd_discard_info): Don't save edited relocs.
+ Tidy conditions under which stabs are edited. Formatting.
+ * elf64-sparc.c (sparc64_elf_relocate_section): Ignore overflows
+ from discarded relocs.
+ * elfxx-ia64.c (elfNN_ia64_install_dyn_reloc): Add reloc output
+ section adjustments after testing magic values.
+
+2002-11-12 Thomas Moestl <tmm@FreeBSD.org>
+
+ * elf64-sparc.c (sparc64_elf_adjust_dynamic_symbol): Correct
+ references to large plt symbols.
+
+2002-11-12 Klee Dienes <kdienes@apple.com>
+
+ * mach-o.c (bfd_mach_o_scan_read_thread): Don't re-use 'i' when
+ looking for an unused section name.
+
+2002-11-11 Kazu Hirata <kazu@cs.umass.edu>
+
+ * coff-h8300.c: Fix formatting.
+ * elf32-h8300.c: Likewise.
+ * reloc16.c: Likewise.
+
+2002-11-09 Jeroen Dobbelaere <jeroen.dobbelaere@acunia.com>
+
+ * elf32-arm.h (elf32_arm_size_dynamic_sections): Don't strip output
+ section when dynamic section unused; _bfd_strip_section_from_output
+ instead.
+
+2002-11-08 Alan Modra <amodra@bigpond.net.au>
+
+ * targets.c (_bfd_target_vector): Disable pef_vec, pef_xlib_vec
+ and sym_vec.
+
+ * dwarf2.c: Revert last change.
+
+2002-11-07 Michal Ludvig <mludvig@suse.cz>
+
+ * dwarf2.c (read_indirect_string, read_abbrevs, decode_line_info,
+ _bfd_dwarf2_find_nearest_line): Use
+ bfd_simple_get_relocated_section_contents() instead of
+ bfd_get_section_contents().
+ * reloc.c (bfd_perform_relocation): Add sanity check.
+ * simple.c (simple_get_relocated_section_contents): If the section
+ does not have any relocs associated with it, just return the
+ unadjusted contents.
+
+2002-11-07 Hans-Peter Nilsson <hp@axis.com>
+
+ * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_16_GOT,
+ case R_CRIS_32_GOT>: Correct test for filling in constant .got
+ contents, enabling for a non-DSO, for symbols defined in the
+ program with --export-dynamic.
+
+2002-11-07 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c: Comment typo fixes.
+ (ppc64_elf_merge_private_bfd_data): Allow BFD_ENDIAN_UNKNOWN input.
+
+2002-11-07 Nick Clifton <nickc@redhat.com>
+
+ * po/da.po: Updated Danish translation.
+
+2002-11-06 Alexandre Oliva <aoliva@redhat.com>
+
+ * elf64-mips.c (mips_elf64_slurp_one_reloc_table): Generate
+ exactly three internal relocs per external reloc. Set reloc_count
+ to the external reloc count.
+
+2002-11-06 Klee Dienes <kdienes@apple.com>
+
+ * coff-stgo32.c (stub_bytes): Mark as const.
+ Fix comment formatting.
+
+2002-11-06 Klee Dienes <kdienes@apple.com>
+
+ * Makefile.am (BFD32_BACKENDS): Add mach-o.lo, pef.lo, and
+ xsym.lo.
+ (BFD32_BACKENDS_CFILES): Add mach-o.c, pef.c, and xsym.c.
+ (SOURCE_HFILES): Add mach-o.h, pef.h, pef-traceback.h, xsym.h
+ * archures.c (enum bfd_architecture): Add bfd_arch_m98k.
+ * bfd.c (struct bfd): Add private data for mach-o, pef, and sym.
+ * targets.c (enum bfd_flavour): Add flavours for mach-o, pef, and
+ sym.
+ (_bfd_target_vector): Add target vectors for mach-o, pef, and sym.
+ * Makefile.in: Regenerate.
+ * doc/Makefile.in: Regenerate.
+ * bfd-in2.h: Regenerate.
+ * xsym.c: New file. Contains support for the Apple/Metrowerks
+ xSYM debugging format.
+ * xsym.h: New file.
+ * pef.c: New file. Contains support for the Apple Code Fragment
+ Manager Preferred Executable Format
+ * pef.h: New file.
+ * pef-traceback.h: New file. Contains support for parsing PowerPC
+ traceback tables as used by PEF executables (and perhaps other
+ systems as well).
+ * mach-o.c: New file. Contains support for the Mach-O object file
+ format.
+ * mach-o.h: New file.
+ * mach-o-target.c: New file. Declares the mach-o targets
+ themselves. Included three times by mach-o.c; each time with a
+ different set of macros set.
+
+2002-11-06 Graeme Peterson <gp@qnx.com>
+
+ * Makefile.am: Remove entries for elf32-qnx.[ch].
+ * Makefile.in: Regenerate.
+ * config.bfd: Change arm-nto to use bfd_elf32_{big|little}arm_vec,
+ ppc-nto to use bfd_elf32_powerpc{le}_vec, sh-nto to use
+ bfd_elf32_sh{l}_vec, and i386-nto to use bfd_elf32_i386_vec.
+ * configure.in: Remove support for bfd_elf32_sh{l}qnx_vec,
+ bfd_elf32_powerpc{le}qnx_vec, bfd_elf32_{big|little}armqnx_vec,
+ and bfd_elf32_i386qnx_vec, and removed elf32-qnx.lo from other targets.
+ bfd_elf32_sh{l}_vec, and i386-nto to use bfd_elf32_i386_vec.
+ * configure: Regenerate.
+ * elf32-qnx.c: Remove.
+ * elf32-qnx.h: Remove.
+ * elf.c: Remove calls to QNX specific set_nonloadable_filepos,
+ is_contained_by_filepos, and copy_private_bfd_data_p.
+ * elf-bfd.h (struct elf_backend_data): Remove set_nonloadable_filepos,
+ is_contained_by_filepos, and copy_private_bfd_data_p.
+ * elf32-i386.c: Remove QNX extended bfd support.
+ * elf32-ppc.c: Remove QNX extended bfd support.
+ * elf32-sh.c: Remove QNX extended bfd support.
+ * elfarm-nabi.c: Remove QNX extended bfd support.
+ * targets.c: Remove qnx vectors.
+ * elfxx-target.h (elf_backend_set_nonloadable_filepos): Remove
+ (elf_backend_is_contained_by_filepos): Remove.
+ (elf_backend_copy_private_bfd_data_p): Remove.
+ * po/SRC-POTFILES.in: Regenerate.
+
+2002-11-06 David O'Brien <obrien@FreeBSD.org>
+ Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-sparc.c (sparc64_elf_relocate_section): Adjust addend of
+ dynamic relocs against section symbols for the output section vma.
+
+2002-11-05 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-arm.h (t2a1_push_insn, t2a2_ldr_insn, t2a3_mov_insn,
+ t2a4_bx_insn, t2a5_pop_insn, t2a6_bx_insn): Remove.
+
+2002-11-05 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+ Alan Modra <amodra@bigpond.net.au>
+
+ * config.bfd (sh-*-linux*): Use bfd_elf*_sh64*lin_vec as sh64
+ vectors in target_selvecs.
+ (shle-*-netbsdelf*): Use bfd_elf*_sh64*nbsd_vec as sh64 vectors
+ in target_selvecs.
+ (sh-*-netbsdelf*): Likewise.
+ * configure.in (assocvecs): New variable. Handle assocvecs like
+ selvecs.
+ * configure: Regenerate.
+ * format.c (bfd_check_format_matches): Store bfd_target pointers
+ in matching_vector instead of target names. Select first target
+ from bfd_associated_vector that matches a list of ambiguous targets.
+ * targets.c (_bfd_associated_vector): New array.
+ (bfd_associated_vector): New variable.
+ (_bfd_target_vector): Add bfd_elf*_sh64*lin_vec.
+ * libbfd-in.h (bfd_associated_vector): Declare.
+ * libbfd.h: Regenerate.
+
+2002-11-05 Elias Athanasopoulos <eathan@otenet.gr>
+
+ * vms-gsd.c (_bfd_vms_write_gsd): Check that symbol->udata.p is
+ non-NULL before dereferencing.
+
+2002-11-04 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * vms.c (vms_object_p): Restore the start address when returning
+ NULL.
+
+2002-11-04 Alan Modra <amodra@bigpond.net.au>
+ Hans-Peter Nilsson <hp@axis.com>
+
+ * elflink.h (struct elf_final_link_info): Add shndxbuf_size.
+ (elf_bfd_final_link): Don't bother zeroing symtab_hdr fields.
+ Set up a larger symshndxbuf, and write it out. Free it on
+ exit rather than freeing symbuf twice. Correct section index
+ on output section symbol loop.
+ (elf_link_output_sym): Accumulate symbol extension section
+ indices, reallocating symshndxbuf rather than writing it out.
+ (elf_link_flush_output_syms): Don't flush symshndxbuf.
+ * elf.c (assign_section_numbers): Init i_shdrp to all zero.
+ Use bfd_zalloc to clear i_shdrp[0] too.
+
+2002-11-03 Stephen Clarke <stephen.clarke@earthling.net>
+
+ * elf32-sh64-com.c (sh64_address_in_cranges): Use
+ _raw_size of cranges section if _cooked_size not yet set.
+
+2002-11-03 Hans-Peter Nilsson <hp@axis.com>
+
+ * elf32-v850.c (v850_elf_relax_delete_bytes): Correct parameters
+ for bfd_elf32_swap_symbol_out.
+
+2002-10-31 David O'Brien <obrien@FreeBSD.org>
+
+ * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't mix
+ signed and unsigned in comparison.
+
+2002-10-30 Daniel Jacobowitz <drow@mvista.com>
+
+ * coffcode.h: Remove extraneous '\'.
+
+2002-10-28 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.am (targets.lo): Depend on Makefile instead of
+ config.status.
+ (archures.lo): Likewise.
+ * Makefile.in: Regenerated.
+
+2002-10-25 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * config.bfd (mips*el-*-netbsd*, mips*-*-netbsd*): Add
+ bfd_elf64_bigmips_vec and bfd_elf64_littlemips_vec to
+ targ_selvecs.
+
+2002-10-25 Jim Wilson <wilson@redhat.com>
+
+ * elf64-sh64.c (sh_elf64_relocate_section): Call
+ _bfd_elf_rela_local_sym. Handle relocs against STT_SECTION symbol
+ of SHF_MERGE section.
+
+2002-10-25 Hans-Peter Nilsson <hp@axis.com>
+
+ * simple.c: Correct placement of ATTRIBUTE_UNUSED.
+
+2002-10-24 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * aoutx.h (NAME(aout,swap_ext_reloc_in)): Cast bytes->r_index to
+ unsigned int. Cast RELOC_BASE10, RELOC_BASE13 and RELOC_BASE22 to
+ unsigned int.
+ (NAME(aout,final_link)): Cast enum used in assignment.
+ (aout_link_write_symbols): Cast enums in comparisons, int values to
+ boolean, enums in assignments to int.
+ (aout_link_input_section_std): Cast rel->r_index to unsigned int.
+ (aout_link_input_section_ext): Likewise. Cast enums used in
+ comparisons with unsigned ints.
+ (aout_link_reloc_link_order): Cast enum to int in assignment.
+ * archive.c (_bfd_generic_read_ar_hdr_mag): Cast result of memchr
+ calls to char *.
+ * bfd-in.h (bfd_set_section_vma): Cast enum true to unsigned int in
+ assignment.
+ * bfd-in2.h (bfd_set_section_vma): Likewise.
+ * bfd.c (bfd_record_phdr): Cast enums in assignments.
+ * binary.c (bfd_alloc): Cast enum to long.
+ * coffgen.c (_bfd_coff_is_local_label_name): Cast return to boolean.
+ * dwarf2.c (read_abbrevs): Add casts to enum types.
+ (read_attribute_value): Likewise.
+ (arange_add): Cast result of bfd_zalloc call.
+ (comp_unit_contains_address): Return true and false.
+ (comp_unit_find_nearest_line): Cast return to boolean.
+ * format.c (bfd_check_format_matches, bfd_set_format): Likewise.
+ * gen-aout.c: define macro '_' if not defined.
+ * libbfd.c (bfd_realloc): Cast malloc and realloc to PTR.
+ (bfd_bwrite): Cast bfd_realloc to bfd_byte *.
+ (bfd_write_bigendian_4byte_int): Cast return to boolean.
+ (bfd_seek): Cast bfd_realloc to bfd_byte *.
+ (bfd_generic_is_local_label_name): Cast return to boolean.
+ * libcoff.h (_bfd_coff_adjust_symndx): Remove extraneous '\'.
+ * linker.c (_bfd_link_hash_newfunc): Cast bfd_hash_allocate result to
+ struct bfd_hash_entry *.
+ (_bfd_generic_link_hash_newfunc): likewise.
+ (_bfd_generic_final_link): Cast enum to unsigned int.
+ * merge.c (sec_merge_emit): Cast return to boolean.
+ (merge_strings): Add casts to const unsigned char *.
+ * reloc.c (bfd_get_reloc_code_name): Cast enums in comparison to int.
+ (bfd_generic_get_relocated_section_content): Cast enum to unsigned int.
+ * section.c (bfd_section_hash_newfunc): Cast bfd_hash_allocate result
+ to struct bfd_hash_entry *.
+ (bfd_set_section_content): Add cast to PTR in comparison.
+ * simple.c (simple_dummy_warning, simple_dummy_undefined_symbol,
+ simple_dummy_reloc_overflow, simple_dummy_reloc_dangerous,
+ simple_dummy_unattached_reloc,
+ bfd_simple_get_relocated_section_contents): Add K&R declarations and
+ function definitions.
+ * srec.c (S3Forced): Initialize to false.
+ (srec_get_symtab): Cast return value from bfd_alloc to asymbol *.
+ * stabs.c (_bfd_link_section_stabs): Cast enum to int in comparisons.
+ (_bfd_discard_section_stabs): Likewise. Also cast return to boolean.
+ * syms.c (bfd_is_undefined_symclass): Cast return to boolean.
+ (_bfd_stab_section_find_nearest_line): Cast enum to bfd_byte in
+ comparisons.
+
+2002-10-23 Jakub Jelinek <jakub@redhat.com>
+
+ * elf64-alpha.c (elf64_alpha_check_relocs): Only put maybe_dynamic
+ relocs into shared lib non-allocated reloc sections.
+
+2002-10-23 Nathan Tallent <eraxxon@alumni.rice.edu>
+
+ * dwarf2.c (add_line_info): Ensure that the line_info_table is
+ sorted even when given an out-of-order line sequence.
+ (lookup_address_in_line_info_table): When an exact VMA match is
+ not found, return line information with the closest VMA.
+
+2002-10-23 Ross Alexander <ross.alexander@uk.neceur.com>
+
+ * elf64-hppa.c: Force DT_FLAGS to always be set. Required by
+ HPUX 11.00 patch PHSS_26559.
+
+2002-10-22 Alexandre Oliva <aoliva@redhat.com>
+
+ * elfxx-mips.c (_bfd_mips_elf_modify_segment_map): Don't move
+ the options section into a separate section unless IRIX 6
+ compatibility is enabled.
+
+2002-10-22 Alexandre Oliva <aoliva@redhat.com>
+
+ * elflink.h (struct elf_link_sort_rela): Turn rel and rela
+ into arrays.
+ (elf_link_sort_cmp1, elf_link_sort_cmp2): Adjust.
+ (elf_link_sort_relocs): Likewise. Take int_rels_per_ext_rel
+ into account.
+ * elfxx-mips.c (mips_elf_create_dynamic_relocation): Compose
+ R_MIPS_REL32 with R_MIPS64 if ABI_64_P.
+
+2002-10-21 Graeme Peterson <gp@qnx.com>
+
+ * targets.c (_bfd_target_vector): Add missing qnx vectors.
+
+2002-10-21 Alan Modra <amodra@bigpond.net.au>
+
+ * targets.c (bfd_target_list): Don't return the default target twice.
+
+2002-10-21 Elias Athanasopoulos <eathan@otenet.gr>
+
+ * archive.c (_bfd_archive_bsd_update_armap_timestamp): Replace
+ perror with bfd_perror.
+
+2002-10-19 H.J. Lu <hjl@gnu.org>
+
+ * elflink.h (elf_link_add_object_symbols): Correctly handle
+ DT_RPATH and DT_RUNPATH.
+
+2002-10-19 Mark Kettenis <kettenis@gnu.org>
+
+ * elf.c (elfcore_grok_note): Fix recognition on NT_PRXFPREG notes.
+
+2002-10-17 Denis Chertykov <denisc@overta.ru>
+
+ * elf32-ip2k.c (ELF_MACHINE_ALT1): Define alternate machine code
+ for ip2k port.
+
+2002-10-17 Alan Modra <amodra@bigpond.net.au>
+
+ * elfxx-target.h (USE_REL): Don't define as 1.
+ * elf32-arm.h (USE_REL): Provide a default define of 0.
+ Use #if rather than #ifdef when testing USE_REL.
+ * elf32-m32r.c: Likewise.
+
+ * elf32-arc.c (USE_REL): Define as 1.
+ * elf32-d10v.c (USE_REL): Likewise.
+ * elf32-m32r.c (USE_REL): Likewise.
+ * elf32-m68hc11.c (USE_REL): Likewise.
+ * elf32-m68hc12.c (USE_REL): Likewise.
+ * elf32-or32.c (USE_REL): Likewise.
+ * elfarm-nabi.c (USE_REL): Likewise.
+
+2002-10-16 Jakub Jelinek <jakub@redhat.com>
+
+ * config.bfd (s390-*-linux*): Add targ64_selvecs.
+ (s390x-*-linux*): Add targ_selvecs.
+
+2002-10-16 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (BFD32_BACKENDS): Remove elfarmqnx-nabi.lo,
+ elf32-i386-fbsd.lo, elf32-i386qnx.lo, elf32-ppcqnx.lo,
+ elf32-sh-lin.lo, elf32-sh64-lin.lo, elf32-sh-nbsd.lo,
+ elf32-sh64-nbsd.lo, elf32-shqnx.lo. Add elf32-qnx.lo.
+ (BFD32_BACKENDS_CFILES): Likewise for corresponding C files.
+ (BFD64_BACKENDS): Remove elf64-sh64-lin.lo, elf64-sh64-nbsd.lo.
+ (BFD64_BACKENDS_CFILES): Likewise for corresponding C files.
+ (SOURCE_HFILES): Add elf32-qnx.h.
+ (BUILD_HFILES): Add bfdver.h.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * configure.in Update bfd vector dependencies.
+ * configure: Regenerate.
+ * elf32-i386-fbsd.c: Delete. Move code to elf32-i386.c.
+ * elf32-i386qnx.c: Likewise.
+ * elf32-ppcqnx.c: Delete. Move code to elf32-ppc.c.
+ * elf32-sh-nbsd.c: Delete. Move code to elf32-sh.c.
+ * elf32-sh-lin.c: Likewise.
+ * elf32-shqnx.c: Likewise.
+ * elf32-sh64-lin.c: Delete. Move code to elf32-sh64.c.
+ * elf32-sh64-nbsd.c: Likewise.
+ * elf64-sh64-lin.c: Delete. Move code to elf64-sh64.c.
+ * elf64-sh64-nbsd.c: Likewise.
+ * elfarmqnx-nabi.c: Delete. Move code to elfarm-nabi.c.
+ * elf32-arm.h (ELF_MAXPAGESIZE): Always define.
+ * elf32-i386.c: Remove ELF_ARCH and ELF32_I386_C_INCLUDED tests.
+ * elf32-ppc.c: Remove ELF32_PPC_C_INCLUDED tests.
+ * elf32-qnx.h (elf_backend_set_nonloadable_filepos): Always define.
+ (elf_backend_is_contained_by_filepos): Likewise.
+ (elf_backend_copy_private_bfd_data_p): Likewise.
+ Globalize and move functions to..
+ * elf32-qnx.c: ..here. New file.
+ * elf32-sh.c: Remove ELF_ARCH and ELF32_SH_C_INCLUDED tests. Don't
+ emit target vectors when INCLUDE_SHMEDIA.
+ * elf32-sh64.c: Remove ELF_ARCH test. Move TARGET_* etc. defines to
+ end of file.
+ * elf64-sh64.c: Remove ELF_ARCH test.
+ * elfarm-nabi.c: Remove ELFARM_NABI_C_INCLUDED test.
+ * po/BLD-POTFILES.in: Regenerate.
+ * po/SRC-POTFILES.in: Regenerate.
+
+2002-10-16 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h (elf_link_add_object_symbols): Error out on dynamic objects
+ loaded with --just-symbols.
+
+ * elf32-i386qnx.c (TARGET_LITTLE_NAME): Define.
+ * elf32-ppcqnx.c (TARGET_LITTLE_NAME, TARGET_BIG_NAME): Define.
+ * elf32-shqnx.c (TARGET_LITTLE_NAME, TARGET_BIG_NAME): Define.
+ * elfarmqnx-nabi.c (TARGET_LITTLE_NAME, TARGET_BIG_NAME): Define.
+
+2002-10-15 Richard Henderson <rth@redhat.com>
+
+ * Makefile.am (BFD64_BACKENDS): Remove elf64-alpha-fbsd.
+ (BFD64_BACKENDS_CFILES): Likewise.
+ * configure.in (bfd_elf64_alpha_freebsd_vec): Use elf64-alpha.
+ * elf64-alpha-fbsd.c: Remove file, move code ...
+ * elf64-alpha.c: ... here.
+ * Makefile.in, configure: Rebuild.
+
+2002-10-14 Richard Henderson <rth@redhat.com>
+
+ * elf64-alpha.c (elf64_alpha_relocate_section) [BRSGP]: Increment
+ VALUE, not ADDEND.
+
+2002-10-14 Stephen Clarke <stephen.clarke@superh.com>
+
+ * elf32-sh.c (elf_sh_link_hash_entry): Replace
+ datalabel_got_offset with union of datalabel_got
+ offset and refcount.
+ (sh_elf_link_hash_newfunc): Initialize datalabel_got.refcount.
+ (allocate_dynrelocs): Delete unnecessary code for
+ STT_DATALABEL type. Create entry in got for
+ datalabel version of symbol if datalabel_got.refcount > 0.
+ (sh_elf_relocate_section): Use datalabel_got union.
+ (sh_elf_gc_sweep_hook): Pull common code to initialize
+ h and eh out of switch statement. Declare seen_stt_datalabel.
+ Initialize it. Decrement datalabel_got.refcount for
+ got relocs when seen_stt_datalabel is true.
+ Decrement local_got_refcounts entry for datalabel got relocs
+ of local symbols.
+ (sh_elf_copy_indirect_symbol): Copy datalabel_got field over.
+ (sh_elf_check_relocs): Declare seen_stt_datalabel.
+ Initialize it. When seen_stt_datalabel is true, increment
+ datalabel_got refcount rather than got.refcount.
+ (sh_elf_finish_dynamic_symbol): Create relocs to
+ initialize got entry for datalabel version of symbol.
+
+2002-10-14 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ (BFD_H_FILES): Remove version.h.
+ * bfd-in.h (BFD_VERSION, BFD_VERSION_DATE, BFD_VERSION_STRING): Move..
+ * version.h: ..to here.
+ * configure.in (bfd_version_date): Remove.
+ (AC_OUTPUT): Make bfdver.h from version.h.
+ * bfd.c: #include "bfdver.h".
+ * vms-hdr.c: Likewise.
+ * Makefile.in: Regenerate.
+ * bfd-in2.h: Regenerate.
+ * configure: Regenerate.
+ * po/SRC-POTFILES.in: Regenerate.
+
+2002-10-14 Alan Modra <amodra@bigpond.net.au>
+
+ * archures.c (bfd_mach_i386_i386, bfd_mach_i386_i8086,
+ bfd_mach_i386_i386_intel_syntax, bfd_mach_x86_64,
+ bfd_mach_x86_64_intel_syntax bfd_mach_ppc, bfd_mach_ppc64,
+ bfd_mach_rs6k, bfd_mach_d10v, bfd_mach_sh, bfd_mach_v850,
+ bfd_mach_arc_5, bfd_mach_arc_6, bfd_mach_arc_7, bfd_mach_arc_8,
+ bfd_mach_m32r, bfd_mach_frv, bfd_mach_frvsimple,
+ bfd_mach_ia64_elf64, bfd_mach_ia64_elf32,
+ bfd_mach_ip2022, bfd_mach_ip2022ext,
+ bfd_mach_s390_31, bfd_mach_s390_64, bfd_mach_xstormy16): Renumber.
+ * bfd-in2.h: Regenerate.
+
+2002-10-14 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * config.bfd (sh*eb-*-linux*, sh*-*-linux*): Add the alternative
+ endian vector to targ_selvecs.
+
+2002-10-13 Alexandre Oliva <aoliva@redhat.com>
+
+ * elfxx-mips.c (mips_elf_calculate_relocation): Take
+ save_addend argument. Don't apply the 32-bit mask to a
+ GPREL32 value if it's to be used in another relocation. Don't
+ use forced-check computation of local_p to decide whether to
+ add gp0 to GPREL16 value. Don't use only the lowest 16 bits
+ of the addend of a non-in-place GPREL16 relocation.
+ (_bfd_mips_elf_relocate_section): Pass use_saved_addend_p to
+ mips_elf_calculate_relocation().
+
+2002-10-12 Stephane Carrez <stcarrez@nerim.fr>
+
+ * elf32-m68hc11.c (m68hc11_elf_relax_section): Don't treat relocs
+ with symbols in other sections if we relaxed something; the sections
+ output offsets must be re-computed before.
+
+2002-10-12 Stephane Carrez <stcarrez@nerim.fr>
+
+ * elf32-m68hc11.c (m68hc11_elf_relax_section): Update symbols
+ handling to use Elf_Internal_Sym.
+ (m68hc11_elf_relax_delete_bytes): Likewise.
+
+2002-10-11 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * elf32-sh.c (sh_elf_optimized_tls_reloc, sh_elf_mkobject,
+ sh_elf_object_p, dtpoff_base): New functions.
+ (sh_elf_howto_table): Add TLS relocs.
+ (sh_reloc_map): Likewise.
+ (sh_elf_info_to_howto): Support TLS relocs.
+ (elf_sh_link_hash_entry): Add tls_type and tls_tpoff32.
+ (sh_elf_hash_entry, sh_elf_tdata, sh_elf_local_got_tls_type):
+ New macros.
+ (sh_elf_obj_tdata): New.
+ (elf_sh_link_hash_table): Add tls_ldm_got.
+ (sh_elf_link_hash_table_create): Clear refcount of tls_ldm_got.
+ (allocate_dynrelocs): Support TLS relocs.
+ (sh_elf_size_dynamic_sections): Likewise.
+ (sh_elf_relocate_section): Support TLS relocs. Don't try to find
+ .rela.got section when found already. Return false after printing
+ error about unresolvable relocation.
+ (sh_elf_gc_sweep_hook): Support TLS relocs.
+ (sh_elf_check_relocs): Likewise.
+ (sh_elf_finish_dynamic_symbol): Likewise.
+ (bfd_elf32_mkobject, elf_backend_object_p): Define for TLS case.
+ * reloc.c: Add SH TLS relocs.
+ * bfd-in2.h, libbfd.h: Regenerate.
+
+2002-10-11 Daniel Jacobowitz <drow@mvista.com>
+
+ * Makefile.in: Regenerated.
+
+2002-10-11 Daniel Jacobowitz <drow@mvista.com>
+
+ * Makefile.am: Run dep-am.
+ (BFD_H_DEP): Add simple.c and linker.c.
+ (BFD32_LIBS): Add simple.lo.
+ (BFD32_LIBS_CFILES): Add simple.c.
+ * Makefile.in: Regenerated.
+ * bfd-in2.h: Regenerated.
+ * simple.c: New file.
+
+2002-10-11 Alan Modra <amodra@bigpond.net.au>
+
+ * coff-arm.c (record_arm_to_thumb_glue): Avoid type-punned pointers.
+ (record_thumb_to_arm_glue): Likewise.
+ * ecoff.c (ecoff_link_add_externals): Likewise.
+ * elf32-arm.h (record_arm_to_thumb_glue): Likewise.
+ (record_thumb_to_arm_glue): Likewise.
+ * elf32-m32r.c (m32r_elf_add_symbol_hook): Likewise.
+ * elf32-sh.c (sh_elf_create_dynamic_sections): Likewise.
+ * elf32-sh64.c (sh64_elf_add_symbol_hook): Likewise.
+ * elf64-alpha.c (elf64_alpha_create_dynamic_sections): Likewise.
+ * elf64-ppc.c (func_desc_adjust): Likewise.
+ * elf64-sh64.c (sh64_elf64_add_symbol_hook): Likewise.
+ (sh64_elf64_create_dynamic_sections): Likewise.
+ * elflink.c (_bfd_elf_create_got_section): Likewise.
+ (_bfd_elf_create_dynamic_sections): Likewise.
+ (_bfd_elf_create_linker_section): Likewise.
+ * elflink.h (elf_add_default_symbol): Likewise.
+ (elf_link_create_dynamic_sections): Likewise.
+ (NAME(bfd_elf,size_dynamic_sections)): Likewise.
+ * elfxx-ia64.c (elfNN_ia64_aix_add_symbol_hook): Likewise.
+ * elfxx-mips.c (mips_elf_create_got_section): Likewise.
+ (_bfd_mips_elf_add_symbol_hook): Likewise.
+ (_bfd_mips_elf_create_dynamic_sections): Likewise.
+ * linker.c (generic_link_add_symbol_list): Likewise.
+ * xcofflink.c (xcoff_link_add_symbols): Likewise.
+
+ * elfxx-ia64.c (oor_brl, oor_ip): Conditionally define.
+
+ * elf64-ppc.c (edit_opd): Only zero opd syms when function is
+ completely removed. Correct local sym adjustment.
+
+2002-10-10 Stephen Clarke <stephen.clarke@superh.com>
+
+ * elf32-sh.c (elf_sh_pic_plt_entry_be, elf_sh_pic_plt_entry_le):
+ Correct mistake in calculation of address of .got.
+ * elf64-sh64.c (elf_sh64_pic_plt_entry_be,
+ elf_sh64_pic_plt_entry_le): Likewise.
+
+2002-10-09 Richard Shann <richard.shann@superh.com>
+ Stephen Clarke <stephen.clarke@superh.com>
+
+ * Makefile.am: Add entries for elf32-sh64-lin.c and
+ elf64-sh64-lin.c. Regenerate.
+ * Makefile.in: Regenerate.
+ * config.bfd: Change sh64eb-*-linux* and sh64-*-linux*
+ to use sh64 vectors rather than sh vectors.
+ * configure.in: Add bfd_elf32_sh64lin_vec, bfd_elf32_sh64blin_vec,
+ bfd_elf64_sh64lin_vec, bfd_elf64_sh64blin_vec.
+ * configure: Regenerate.
+ * elf32-sh64-lin.c: New file.
+ * elf64-sh64-lin.c: New file.
+ * targets.c: Add bfd_elf32_sh64lin_vec, bfd_elf32_sh64blin_vec,
+ bfd_elf64_sh64lin_vec, bfd_elf64_sh64blin_vec.
+
+2002-10-08 H.J. Lu <hjl@gnu.org>
+
+ * elf32-i386.c (elf_i386_relocate_section): Re-arrange the
+ IE->LE transition for R_386_TLS_IE.
+
+2002-10-08 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (edit_opd): Correct test for discarded sections.
+
+2002-10-07 Mark Elbrecht <snowball3@softhome.net>
+
+ * cofflink.c (mark_relocs): Don't mark relocations in excluded
+ sections.
+
+2002-10-07 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h (elf_link_input_bfd): Remove BFD_VERSION_DATE dependent
+ code.
+
+ * elf64-ppc.c (ppc64_elf_build_stubs): Increment .glink indx.
+
+2002-10-06 Alan Modra <amodra@bigpond.net.au>
+
+ * opncls.c: Formatting.
+ (_bfd_new_bfd): Use a smaller section hash table.
+
+2002-10-05 Alexandre Oliva <aoliva@redhat.com>
+
+ * elfxx-mips.c (mips_elf_create_dynamic_relocation): Set the type
+ of the other two relocations packed with a REL32 to NONE.
+
+2002-10-02 Stephen Clarke <stephen.clarke@superh.com>
+
+ * elf32-sh.c (elf_sh_link_hash_entry): Add gotplt_refcount.
+ (sh_elf_link_hash_newfunc): Initialize it.
+ (allocate_dynrelocs): Transfer gotplt refs from plt.refcount
+ to got.refcount for symbols that are forced local or when
+ we have direct got refs.
+ (sh_elf_gc_sweep_hook): Adjust gotplt_refcount. Use it
+ to correctly adjust got.refcount and plt.refcount.
+ (sh_elf_copy_indirect_symbol): Copy gotplt_refcount across.
+ (sh_elf_check_relocs): Increment gotplt_refcount.
+
+2002-10-01 Jakub Jelinek <jakub@redhat.com>
+
+ * elf32-i386.c (elf_i386_relocate_section): Fix
+ movl foo@indntpoff, %eax IE->LE transition.
+
+2002-10-01 Jakub Jelinek <jakub@redhat.com>
+
+ * elf64-x86-64.c (elf64_x86_64_relocate_section): Change TLSGD
+ sequence and its transitions.
+
+2002-10-01 Jakub Jelinek <jakub@redhat.com>
+
+ * elf32-i386.c (elf_i386_relocate_section): Resolve R_386_TLS_LDO_32
+ to st_value + addend in non-code sections.
+ * elf64-x86-64.c (elf64_x86_64_relocate_section): Resolve
+ R_X86_64_DTPOFF32 to st_value + addend in non-code sections.
+
+2002-09-30 Gavin Romig-Koch <gavin@redhat.com>
+ Ken Raeburn <raeburn@cygnus.com>
+ Aldy Hernandez <aldyh@redhat.com>
+ Eric Christopher <echristo@redhat.com>
+ Richard Sandiford <rsandifo@redhat.com>
+
+ * archures.c (bfd_mach_mips4120, bfd_mach_mips5400): New.
+ (bfd_mach_mips5500): New.
+ * cpu-mips.c (I_mips4120, I_mips5400, I_mips5500): New.
+ (arch_info_struct): Add corresponding entries here.
+ * elfxx-mips.c (_bfd_elf_mips_mach): Handle E_MIPS_MACH_4120,
+ E_MIPS_MACH_5400 and E_MIPS_MACH_5500.
+ (_bfd_mips_elf_final_write_processing): Handle bfd_mach_mips4120,
+ bfd_mach_mips5400 and bfd_mach_mips5500.
+ (_bfd_mips_elf_mach_extends_p): New function.
+ (_bfd_mips_elf_merge_private_bfd_data): Use it to help merge
+ the EF_MIPS_MACH flags.
+ * bfd-in2.h: Regenerate.
+
+2002-09-28 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * elf32-vax.c (elf_vax_size_dynamic_section): Don't strip
+ .got sections.
+
+2002-09-28 Alan Modra <amodra@bigpond.net.au>
+
+ * elf.c (map_sections_to_segments): Correct test for start of
+ writable section in the same page as end of read-only section.
+
+2002-09-27 Matt Thomas <matt@3am-software.com>
+
+ * elf32-vax.c (elf_vax_check_relocs): Remove unused
+ local_got_refcounts usage. Remove allocation of got slot.
+ (elf_vax_gc_sweep_hook): Remove unused local_got_refcounts usage.
+ Remove de-allocation of got slot.
+ (elf_vax_size_dynamic_section): Fix some indentation. Add hash
+ traversal for elf_vax_instantiate_got_entries. Allow empty .got
+ sections to be GC'ed.
+ (elf_vax_instantiate_got_entries): New function.
+ (elf_vax_relocate_section): Simplify R_VAX_GOT32 handling. Remove
+ tests that are now handled by elf_vax_instantiate_got_entries.
+ Assert GOT entry falls within .got section size. Remove redundant
+ comparisions. Fix comments.
+
+2002-09-27 Jakub Jelinek <jakub@redhat.com>
+
+ * reloc.c: Add x86-64 TLS relocs.
+ * bfd-in2.h, libbfd.h: Rebuilt.
+ * elf64-x86-64.c (x86_64_elf_howto): Fix size fields for 32-bit
+ relocs. Add TLS relocs.
+ (x86_64_reloc_map): Add TLS relocs.
+ (elf64_x86_64_info_to_howto): Adjust for added TLS relocs.
+ (struct elf64_x86_64_link_hash_entry): Add tls_type field.
+ (GOT_UNKNOWN, GOT_NORMAL, GOT_TLS_GD, GOT_TLS_IE): Define.
+ (elf64_x86_64_hash_entry): Define.
+ (struct elf64_x86_64_obj_tdata): New.
+ (elf64_x86_64_tdata, elf64_x86_64_local_got_tls_type): Define.
+ (struct elf64_x86_64_link_hash_table): Add tls_ld_got.
+ (link_hash_newfunc): Initialize tls_type.
+ (elf64_x86_64_link_hash_table_create): Initialize tls_ld_got.
+ (elf64_x86_64_copy_indirect_symbol): Swap tls_type if necessary.
+ (elf64_x86_64_mkobject): New.
+ (elf64_x86_64_elf_object_p): Allocate struct elf64_x86_64_obj_tdata.
+ (elf64_x86_64_tls_transition): New.
+ (elf64_x86_64_check_relocs): Add r_type variable and use it.
+ Handle TLS relocs.
+ (elf64_x86_64_gc_sweep_hook): Handle TLS relocs.
+ (allocate_dynrelocs): Allocate GOT space for TLS relocs.
+ (elf64_x86_64_size_dynamic_sections): Likewise.
+ (dtpoff_base, tpoff): New.
+ (elf64_x86_64_relocate_section): Handle TLS relocs.
+ (elf64_x86_64_finish_dynamic_symbol): Only handle non-TLS GOT
+ entries.
+ (bfd_elf64_mkobject): Define.
+
+ * elf32-i386.c (elf_i386_check_relocs) [R_386_TLS_LE]: Set
+ DF_STATIC_TLS if shared.
+
+2002-09-26 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elfxx-mips.c (_bfd_mips_elf_fake_sections): Don't emit unneeded
+ empty relocation sections.
+
+2002-09-26 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc_build_one_stub): Don't build glink stubs here.
+ (ppc64_elf_build_stubs): Build them here instead.
+
+2002-09-24 Jakub Jelinek <jakub@redhat.com>
+
+ * elf32-sparc.c (elf32_sparc_relocate_section): Put R_SPARC_RELATIVE
+ addend into r_addend, not *r_offset.
+ (elf32_sparc_finish_dynamic_symbol): Likewise.
+ * elf64-sparc.c (sparc64_elf_finish_dynamic_symbol): Clear xword at
+ R_SPARC_RELATIVE's r_offset.
+
+2002-09-23 Nathan Tallent <eraxxon@alumni.rice.edu>
+
+ * dwarf2.c (decode_line_info): Update to correctly decode
+ the (non-standard DWARF2) out-of-order address sequences
+ generated by the Intel C++ 6.0 compiler for ia64-Linux.
+
+2002-09-23 Mark Elbrecht <snowball3@softhome.net>
+
+ * config.bfd: For DJGPP targets, match with any cpu and any machine.
+
+2002-09-23 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Zero relocs
+ for discarded FDEs. Remove redundant assignment.
+ * elflink.h (elf_bfd_discard_info): Save edited relocs.
+
+2002-09-22 H.J. Lu <hjl@gnu.org>
+
+ * elf64-alpha.c (elf64_alpha_merge_ind_symbols): Don't merge
+ the relocation count between different .reloc sections.
+
+2002-09-21 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c (ppc_elf_relocate_section): Allow ".sbss.*" and
+ ".sdata.*" for R_PPC_SDAREL16, ".sbss2*" and ".sdata2*" for
+ R_PPC_EMB_SDA2REL. Similarly for R_PPC_EMB_SDA21 and
+ R_PPC_EMB_RELSDA.
+
+ * elfcode.h (elf_slurp_reloc_table_from_section): Make "symcount"
+ unsigned. Move "symcount" assignment out of loop.
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * configure: Regenerate.
+ * po/SRC-POTFILES.in: Regnerate.
+
+2002-09-19 Nathan Tallent <eraxxon@alumni.rice.edu>
+
+ * dwarf2.c (_bfd_dwarf2_find_nearest_line): If address length is
+ zero, set it to 8 for (non-standard) 64-bit DWARF2 formats
+ (e.g. IRIX64).
+
+2002-09-19 Jakub Jelinek <jakub@redhat.com>
+
+ * elf32-ppc.c (ppc_elf_finish_dynamic_symbol): Clear .got word
+ even if generating R_PPC_RELATIVE reloc.
+ (ppc_elf_relocate_section): Make sure relocation is performed
+ if skip == -2. Clear memory at r_offset when creating dynamic
+ relocation.
+
+2002-09-19 Jakub Jelinek <jakub@redhat.com>
+
+ * reloc.c (BFD_RELOC_386_TLS_TPOFF, BFD_RELOC_386_TLS_IE,
+ BFD_RELOC_386_TLS_GOTIE): Add.
+ * bfd-in2.h, libbfd.h: Rebuilt.
+ * elf32-i386.c (elf_howto_table): Add R_386_TLS_TPOFF, R_386_TLS_IE
+ and R_386_TLS_GOTIE.
+ (elf_i386_reloc_type_lookup): Handle it.
+ (struct elf_i386_link_hash_entry): Change tls_type type to unsigned
+ char instead of enum, change GOT_* into defines.
+ (GOT_TLS_IE_POS, GOT_TLS_IE_NEG, GOT_TLS_IE_BOTH): Define.
+ (elf_i386_tls_transition): Handle R_386_TLS_IE and R_386_TLS_GOTIE.
+ (elf_i386_check_relocs): Likewise. Avoid crash if local symbol is
+ accessed both as normal and TLS symbol. Move R_386_TLS_LDM and
+ R_386_PLT32 cases so that R_386_TLS_IE can fall through.
+ Handle R_386_TLS_LE_32 and R_386_TLS_LE in shared libs.
+ (elf_i386_gc_sweep_hook): Handle R_386_TLS_IE and R_386_TLS_GOTIE.
+ Handle R_386_TLS_LE_32 and R_386_TLS_LE in shared libs.
+ (allocate_dynrelocs): Allocate 2 .got and 2 .rel.got entries if
+ tls_type is GOT_TLS_IE_BOTH.
+ (elf_i386_size_dynamic_sections): Likewise.
+ (elf_i386_relocate_section): Handle R_386_TLS_IE and R_386_TLS_GOTIE.
+ Handle R_386_TLS_LE_32 and R_386_TLS_LE in shared libs.
+ (elf_i386_finish_dynamic_symbol): Use tls_type & GOT_TLS_IE to catch
+ all 4 GOT_TLS_* TLS types.
+
+2002-09-19 Nick Clifton <nickc@redhat.com>
+
+ * elflink.h (elf_fix_symbol_flags): When examining weak symbols,
+ follow indirect links.
+
+2002-09-19 Nathan Tallent <eraxxon@alumni.rice.edu>
+
+ * ecoffswap.h (ecoff_swap_pdr_in) <isym, iline>: Update to
+ correctly sign-extend 32-bit ECOFF null values (0xffffffff, -1)
+ on 64 bit machines.
+ (ecoff_swap_sym_in) <iss>: Likewise.
+ * ecoff.c (_bfd_ecoff_slurp_symbolic_info): Fix error reading
+ ECOFF information: 'ioptMax' refers to the actual *size*
+ of the optimization symtab, not the number of entries.
+
+2002-09-19 Daniel Jacobowitz <drow@mvista.com>
+
+ * elf32-arm.h (elf32_arm_adjust_dynamic_symbol): Update
+ ELF_LINK_HASH_NEEDS_PLT logic.
+
+2002-09-18 Daniel Jacobowitz <drow@mvista.com>
+
+ * elfcode.h (elf_slurp_reloc_table_from_section): Check
+ correct relocation count.
+
+2002-09-17 Daniel Jacobowitz <drow@mvista.com>
+
+ * bfd-in.h (bfd_get_dynamic_symcount): Define.
+ * bfd.c (struct _bfd): Add dynsymcount.
+ * bfd-in2.h: Regenerated.
+ * elf.c (_bfd_elf_canonicalize_dynamic_symtab): Set
+ abfd->dynsymcount.
+ * elfcode.h (elf_slurp_reloc_table_from_section): Check
+ for overflow.
+
+2002-09-17 Stan Cox <scox@redhat.com>
+
+ * elf64-mips.c (mips_elf64_be_swap_reloca_out): Handle type2 and type3.
+ (mips_elf64_final_gp): Don't make up gp value.
+ * elfn32-mips.c (mips_elf_final_gp): Likewise.
+ * elfxx-mips.c (_bfd_mips_elf_final_link): Always create
+ .MIPS.options/.options section.
+
+2002-09-17 David O'Brien <obrien@FreeBSD.org>
+
+ * elf32-i386-fbsd.c: Always label using the EI_OSABI method.
+ It is benign for FreeBSD < 4.1. Minor reformatting.
+ * elf64-alpha-fbsd.c: Likewise.
+
+2002-09-17 Jakub Jelinek <jakub@redhat.com>
+
+ * elf32-i386.c (elf_i386_relocate_section) [R_386_TLS_TPOFF32]: Negate
+ addend.
+
+2002-09-17 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-alpha.c (alpha_elf_size_info): Make static.
+
+2002-09-17 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * coff-tic4x.c: Add function declarations and ATTRIBUTE_UNUSED.
+ * cpu-tic4x.c: Ditto.
+
+2002-09-17 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elf64-mips.c (define elf_backend_ignore_discarded_relocs): Remove
+ duplicate define.
+
+2002-09-16 Bruno Haible <bruno@clisp.org>
+
+ * elf32-i386.c: Don't defined ELF_ARCH etc. if this file is included
+ by a target variant implementation.
+ * elf64-alpha.c: Likewise.
+ * elf32-i386-fbsd.c: New file.
+ * elf64-alpha-fbsd.c: New file.
+ * targets.c: Support bfd_elf32_i386_freebsd_vec and
+ bfd_elf64_alpha_freebsd_vec.
+ * configure.in: Accept the vectors bfd_elf32_i386_freebsd_vec,
+ bfd_elf64_alpha_freebsd_vec.
+ * Makefile.am (BFD32_BACKENDS): Add elf32-i386-fbsd.lo.
+ (BFD32_BACKENDS_CFILES): Add elf32-i386-fbsd.c.
+ (BFD64_BACKENDS): Add elf64-alpha-fbsd.lo.
+ (BFD64_BACKENDS_CFILES): Add elf64-alpha-fbsd.c.
+ (elf32-i386-fbsd.lo, elf64-alpha-fbsd.lo): Add dependencies.
+ * config.bfd: For FreeBSD targets, set targ_defvec to a FreeBSD
+ specific targets. Define OLD_FREEBSD_ABI_LABEL if appropriate.
+
+2002-09-12 Jakub Jelinek <jakub@redhat.com>
+
+ * elf32-i386.c (dtpoff_base, tpoff): Don't crash if tls_segment is
+ NULL.
+ (elf_i386_relocate_section): Return false after printing error about
+ unresolvable relocation.
+
+2002-09-12 Nick Clifton <nickc@redhat.com>
+
+ * elf32-arm.h (elf32_arm_final_link_relocate): Fix handling of
+ R_ARM_THM_PC11.
+
+2002-09-11 Jeffrey Law <law@redhat.com>
+
+ * elf32-h8300.c (elf32_h8_relax_section): Fix typo.
+
+2002-09-11 Andrew Haley <aph@cambridge.redhat.com>
+
+ * elf.c (_bfd_elf_find_nearest_line): Check functionname_ptr and
+ line_ptr before deciding we've found a symbol.
+
+2002-09-11 Nick Clifton <nickc@redhat.com>
+
+ * po/da.po: New Danish translation file.
+ * configure.in (LINGUAS): Add 'da'.
+ * configure: Regenerate.
+
+2002-09-10 Michael Snyder <msnyder@redhat.com>
+
+ * irix-core.c (do_sections, do_sections64): New functions.
+ (irix_core_core_file_p): Call new functions do_sections,
+ do_sections64, depending on corefile (32-bit or 64-bit).
+
+2002-09-09 Richard Henderson <rth@redhat.com>
+
+ * elfxx-ia64.c (elfNN_ia64_relax_section): Handle PCREL21M
+ and PCREL21F like PCREL21B.
+
+2002-09-04 Kevin Buettner <kevinb@redhat.com>
+
+ * config.bfd (mips*-*-irix6*): Add new ABI vectors. Make n32 default
+ vector.
+
+2002-09-02 Nick Clifton <nickc@redhat.com>
+
+ * elf32-v850.c (v850_elf_final_link_relocate): Use helpful
+ names instead of cryptically overloaded bfd_reloc error
+ codes.
+ (v850_elf_relocate_section): Likewise.
+ (v850_elf_relax_section): Replace caching of external symbols
+ with caching of internal symbols obtained from calling
+ bfd_elf_get_elf_syms().
+ Fixup problems with freeing cached allocated memory blocks.
+
+2002-09-02 Alan Modra <amodra@bigpond.net.au>
+
+ * cpu-pj.c (scan_mach, compatible, arch_info_struct): Remove.
+ (bfd_pj_arch): Use bfd_default_scan.
+ * cpu-v850.c (scan): Remove.
+ (N): Use bfd_default_scan.
+ * cpu-z8k.c (scan_mach): Remove.
+ (arch_info_struct, bfd_z8k_arch): Reorganize so that the default is
+ first. Use bfd_default_scan.
+
+ * ecoff.c (_bfd_ecoff_set_arch_mach_hook): Don't use hard-coded
+ bfd_mach constants.
+ (ecoff_get_magic): Likewise.
+ * elf32-v850.c (v850_elf_object_p): Likewise.
+ (v850_elf_final_write_processing): Likewise.
+ * mipsbsd.c (MY(set_arch_mach)): Likewise.
+ (MY(write_object_contents)): Likewise.
+ * coff64-rs6000.c (xcoff64_write_object_contents): Likewise.
+ * coffcode.h (coff_write_object_contents): Likewise.
+ (coff_set_arch_mach_hook): Add comment describing machine == 0.
+ Remove unnecessary "machine" assignments.
+ (coff_write_relocs): Test for the absolute section sym by testing
+ section and flags.
+
+ * aoutx.h (NAME(aout,machine_type)): Recognize bfd_mach_i386_i386
+ and bfd_mach_i386_i386_intel_syntax.
+ * pdp11.c (NAME(aout,machine_type)): Likewise.
+
+2002-08-30 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * bfd-in.h (align_power): Cast constants to bfd_vma type.
+ * bfd-in2.h (align_power): Likewise.
+
+2002-08-30 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+ * cpu-avr.c (compatible): Don't use hard-coded mach constants.
+ * cpu-powerpc.c (powerpc_compatible): Likewise.
+ * cpu-rs6000.c (rs6000_compatible): Likewise.
+
+2002-08-28 Catherine Moore <clm@redhat.com>
+
+ * elf32-v850.c (v850_elf_reloc_map): Add new relocs.
+ (v850-elf-reloc): Don't resolve pc relative relocs.
+ (v850_elf_ignore_reloc): New routine.
+ (v850_elf_final_link_relocate): Handle new relocs.
+ (v850_elf_relax_delete_bytes ): New routine.
+ (v850_elf_relax_section): New routine.
+ (bfd_elf32_bfd_relax_section): Define.
+ (HOWTO): New entries for new relocs.
+ * reloc.c (BFD_RELOC_V850_LONGCALL): New reloc.
+ (BFD_RELOC_V850_LONGJUMP): New reloc.
+ (BFD_RELOC_V850_ALIGN): New reloc.
+ * archures.c: Remove redundant v850ea architecture.
+ * cpu-v850.c: Remove redundant v850ea support.
+ * libbfd.h: Regenerate.
+ * bfd-in2.h: Regenerated.
+
+2002-08-28 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * config.bfd: Add tic4x-*-*coff* and c4x-*-*coff* target.
+ * configure.in: Add tic4x_coff vector files.
+ * configure: Regenerate.
+ * Makefile.am: Add tic4x target.
+ * Makefile.in: Regenerate.
+
+2002-08-27 Michael Hayes <m.hayes@elec.canterbury.ac.nz>
+
+ * archures.c: Add the BFD arch type tic4x.
+ * bfd-in.h: Add BFD_IN_MEMORY flag.
+ * coff-tic4x.c: New file.
+ * coffswap.h (coff_swap_sym_out): Add preadjuster.
+ * cpu-tic4x.c: New file.
+ * targets.c: Added tic4x- in list of xvecs.
+ * ticoff.h: New file.
+ * bfd-in2.h: Regenerate.
+
+2002-08-27 Adam Nemet <anemet@lnxw.com>
+
+ * elf32-arm.h (elf32_arm_finish_dynamic_sections): Set the last
+ bit of DT_INIT and DT_FINI for Thumb functions.
+
+2002-08-26 Alan Modra <amodra@bigpond.net.au>
+
+ * coffcode.h (coff_set_arch_mach_hook): Handle W65MAGIC.
+
+2002-08-26 Alan Modra <amodra@bigpond.net.au>
+
+ * aoutx.h (NAME(aout,reloc_type_lookup)): Handle BFD_RELOC_8.
+
+2002-08-24 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * elf32-sh.c (sh_elf_copy_indirect_symbol): New.
+ (create_got_section, allocate_dynrelocs, readonly_dynrelocs):
+ Likewise.
+ (struct elf_sh_pcrel_relocs_copied): Removed.
+ (struct elf_sh_dyn_relocs): New.
+ (struct elf_sh_link_hash_entry): Replace pcrel_relocs_copied
+ field with dyn_relocs.
+ (struct elf_sh_link_hash_table): Add short-cuts to get dynamic
+ sections and sym_sec.
+ (sh_elf_link_hash_newfunc): Clear dyn_relocs.
+ (sh_elf_link_hash_table_create): Clear shorts-cuts and sym_sec.
+ (sh_elf_create_dynamic_sections): Use create_got_section instead
+ of _bfd_elf_create_got_section.
+ (sh_elf_check_relocs): Likewise.
+ (sh_elf_create_dynamic_sections): Use short-cuts to the dynamic
+ sections.
+ (sh_elf_adjust_dynamic_symbol, sh_elf_size_dynamic_sections,
+ sh_elf_relocate_section, sh_elf_check_relocs,
+ sh_elf_finish_dynamic_symbol, sh_elf_finish_dynamic_sections):
+ Likewise.
+ (sh_elf_adjust_dynamic_symbol): Handle nocopyreloc. Keep the
+ dynamic relocations and avoiding the copy relocation when we
+ didn't find any dynamic relocations in the section which has
+ contents or is read-only.
+ (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
+ (sh_elf_size_dynamic_sections): Don't reset the size of
+ .rela.got section even if dynamic_sections_created flag is off.
+ Don't use sh_elf_discard_copies. Scan all input bfd and use
+ allocate_dynrelocs. Call readonly_dynrelocs to determine
+ whether we need DT_TEXTREL.
+ (sh_elf_adjust_dynamic_symbol): Use plt.refcount to determine
+ whether the symbol was never referred to.
+ (sh_elf_relocate_section): Use WILL_CALL_FINISH_DYNAMIC_SYMBOL.
+ (sh_elf_gc_sweep_hook): Fill with the real sweep function.
+ (sh_elf_check_relocs): Call create_got_section if the short-cut
+ to .got is null. Increment reference counters only instead of
+ allocating space on dynamic sections here. Don't conditionalize
+ uninitialized got.offset value when marking the symbol as a
+ global offset table entry. Keep relocations for symbols satisfied
+ by a dynamic library to avoid copy relocations for the symbol.
+ Set dynobj field of an elf hash table if needed.
+ (sh_elf_finish_dynamic_sections): Handle null section pointer
+ correctly.
+ (elf_backend_copy_indirect_symbol): Defined.
+ (elf_backend_can_refcount): Defined.
+
+2002-08-23 Nick Clifton <nickc@redhat.com>
+
+ * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Undo
+ previous change. Add comment explaining why.
+
+2002-08-23 Stephen Clarke <stephen.clarke@superh.com>
+
+ * elf32-sh.c (elf_sh_plt0_entry_be, elf_sh_plt0_entry_le): Copy
+ contents of .got.plt[2] to tr0, not address of .got.plt.
+ (sh_elf_finish_dynamic_symbol): Do not apply GOT_BIAS when
+ patching absolute plt entry. For shmedia plt entry, set bottom bit
+ of branch to plt0 as this is a branch to an shmedia instruction.
+ * elf64-sh64.c (elf_sh64_plt0_entry_be, elf_sh64_plt0_entry_le):
+ Copy contents of .got.plt[2] to tr0, not address of .got.plt.
+ (elf_sh64_plt_entry_be, elf_sh64_plt_entry_le): Use ptrel to
+ branch to plt0.
+ (sh64_elf64_finish_dynamic_symbol): Do not apply GOT_BIAS when
+ patching absolute plt entry. For shmedia plt entry, branch to
+ plt0 is now ptrel, so use relative offset. Set bottom bit of
+ branch target as it is a branch to an shmedia instruction.
+
+2002-08-23 Stephen Clarke <stephen.clarke@superh.com>,
+ Richard Shann <richard.shann@superh.com>
+
+ * elf32-sh.c (sh_elf_finish_dynamic_sections): Set LSB of DT_INIT
+ value if .init is an SHmedia function. Similarly for DT_FINI.
+ * elf64-sh64.c (sh64_elf64_finish_dynamic_sections): Likewise.
+
+2002-08-23 Stephen Clarke <stephen.clarke@superh.com>
+
+ * elf32-sh.c (sh_elf_size_dynamic_sections): Zero initialize
+ dynamic section.
+ * elf64-sh64.c (sh64_elf64_size_dynamic_sections): Likewise.
+
+2002-08-22 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Use a simple
+ byte read when reading the return address register column.
+
+2002-08-22 Nick Clifton <nickc@redhat.com>
+
+ * config.bfd: Add powepc64-*-*bsd* target.
+
+2002-08-22 Graeme Peterson <gp@qnx.com>
+
+ * Makefile.am: Add entries for elf32-shqnx.c
+ * Makefile.in: Regenerate.
+ * config.bfd: Add support sh-*-nto* target.
+ * configure.in: Add support for bfd_elf32_sh{l}qnx_vec.
+ * configure: Regenerate.
+ * elf32-qnx.h: Changed typo "elf_i386qnx_*" to "elf_qnx_*" .
+ * elf32-sh.c: Do not include elf32-target.h if
+ ELF32_SH_C_INCLUDED is defined.
+ * elf32-shqnx.c: New file: Support for QNX.
+ * targets.c: Add bfd_elf32_sh{l}qnx_vec.
+
+2002-08-22 Nick Clifton <nickc@redhat.com>
+
+ * po/tr.po: Updated Turkish translation.
+
+ * syms.c (_bfd_generic_read_minisymbols): Set bfd_error if the
+ symbols are not read.
+
+2002-08-22 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-m68hc11.c: Formatting fixes.
+ (elf32_m68hc11_gc_mark_hook): Correct params. Remove unnecessary test.
+ * elf32-m68hc12.c: Formatting fixes.
+ (elf32_m68hc11_gc_mark_hook): Correct params. Remove unnecessary test.
+
+2002-08-22 Alan Modra <amodra@bigpond.net.au>
+
+ * coff-rs6000.c (rs6000coff_vec <object_flags>): Add SEC_CODE and
+ SEC_DATA.
+ (pmac_xcoff_vec): Likewise.
+ * coff64-rs6000.c (rs6000coff64_vec): Likewise.
+ (aix5coff64_vec): Likewise.
+
+2002-08-22 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h (struct elf_backend_data): Add struct elf_backend_data
+ param to elf_backend_copy_indirect_symbol.
+ (_bfd_elf_link_hash_copy_indirect): Likewise.
+ * elflink.h (elf_add_default_symbol, elf_fix_symbol_flags): Adjust
+ calls to copy_indirect_symbol.
+ * elf32-hppa.c (elf32_hppa_copy_indirect_symbol): Likewise.
+ * elf32-i386.c (elf_i386_copy_indirect_symbol): Likewise.
+ * elf32-s390.c (elf_s390_copy_indirect_symbol): Likewise.
+ * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Likewise.
+ * elf64-s390.c (elf_s390_copy_indirect_symbol): Likewise.
+ * elf64-x86-64.c (elf64_x86_64_copy_indirect_symbol): Likewise.
+ * elfxx-ia64.c (elfNN_ia64_hash_copy_indirect): Likewise.
+ * elfxx-mips.c (_bfd_mips_elf_copy_indirect_symbol): Likewise.
+ * elfxx-mips.h (_bfd_mips_elf_copy_indirect_symbol): Likewise.
+ * elf.c (_bfd_elf_link_hash_copy_indirect): Likewise. Properly
+ test refcounts for "used" values.
+
+2002-08-21 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Add PARAMS to
+ argument declaration.
+
+2002-08-19 Elena Zannoni <ezannoni@redhat.com>
+
+ * archures.c (bfd_mach_ppc_e500): Added.
+ * bfd-in2.h: Rebuilt.
+ * cpu-powerpc.c (bfd_powerpc_archs): Added e500.
+
+2002-08-19 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-m68hc12.c (elf_backend_can_gc_sections): False.
+
+2002-08-17 Andrew Cagney <ac131313@redhat.com>
+
+ * elf.c (bfd_elf_get_elf_syms): Change type of `esym' to
+ `bfd_byte'.
+
+2002-08-17 Stan Cox <scox@redhat.com>
+
+ * elfxx-mips.c (_bfd_mips_elf_modify_segment_map): Use the
+ IRIX 6 segment layout for NEWABI.
+
+2002-08-16 Stephen Clarke <stephen.clarke@superh.com>
+
+ * elf32-sh.c (sh_elf_gc_mark_hook): For sh64, skip indirect
+ symbols when looking for section referred to by a relocation.
+ * elf64-sh.c (sh_elf64_gc_mark_hook): Likewise.
+
+2002-08-15 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-i370.c: Move reloc enum to include/elf/i370.h.
+
+2002-08-15 Hans-Peter Nilsson <hp@axis.com>
+
+ * elf32-cris.c (elf_cris_discard_excess_program_dynamics): Add
+ missing check for whether the symbol is referenced by DSO before
+ unexporting it as an unneeded dynamic symbol.
+
+2002-08-14 H.J. Lu <hjl@gnu.org>
+
+ * libbfd.h: Regenerate.
+
+2002-08-14 H.J. Lu <hjl@gnu.org>
+
+ * config.bfd: Always add 64bit vectors to 32bit Linux/mips.
+
+2002-08-14 Stephane Carrez <stcarrez@nerim.fr>
+
+ * elf32-m68hc11.c (m68hc11_relax_group): New to relax group of
+ instructions.
+ (m68hc11_direct_relax): New to define table of relaxable instructions.
+ (find_relaxable_insn): New, find a relaxable insn.
+ (compare_reloc): New to compare two relocs.
+ (m68hc11_elf_relax_section): New, relax text sections.
+ (m68hc11_elf_relax_delete_bytes): New, delete bytes and adjust branchs.
+ (elf32_m68hc11_check_relocs): New function for GC support.
+ (elf32_m68hc11_relocate_section): New function for GC support.
+ (bfd_elf32_bfd_relax_section): Define to support linker relaxation.
+ (elf_backend_check_relocs): Likewise.
+ (elf_backend_relocate_section): Likewise.
+
+2002-08-13 H.J. Lu <hjl@gnu.org>
+
+ * elflink.h (NAME(bfd_elf,size_dynamic_sections): Don't count
+ definitions in shared objects when checking symbol with
+ undefined version.
+
+2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
+
+ * elf32-m68hc11.c (elf32_m68hc11_gc_mark_hook): New for section GC.
+ (elf32_m68hc11_gc_sweep_hook): Likewise.
+ (elf_backend_gc_mark_hook): Define for GC section support.
+ (elf_backend_gc_sweep_hook): Likewise.
+ (elf_backend_can_gc_sections): Likewise.
+
+ * elf32-m68hc12.c: Likewise.
+
+2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
+
+ * elf32-m68hc11.c (_bfd_m68hc11_elf_print_private_bfd_data): New.
+ (_bfd_m68hc11_elf_merge_private_bfd_data): New function.
+ (_bfd_m68hc11_elf_set_private_flags): New function.
+ Use them to set/check/print ELF flags specific to 68HC11.
+
+ * elf32-m68hc12.c (_bfd_m68hc12_elf_print_private_bfd_data): New.
+ (_bfd_m68hc12_elf_merge_private_bfd_data): New function.
+ (_bfd_m68hc12_elf_set_private_flags): New function.
+ Use them to set/check/print ELF flags specific to 68HC12.
+
+2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
+
+ * elf32-m68hc11.c (elf_m68hc11_howto_table): Add the new relocs;
+ fix masks for PC-rel relocs.
+ (m68hc11_elf_ignore_reloc): New function.
+
+ * elf32-m68hc12.c (m68hc12_elf_special_reloc): New to handle specific
+ 68HC12 banked addressing relocs.
+ (m68hc12_phys_addr): New to compute physical address of banked memory.
+ (m68hc12_phys_page): Likewise for page.
+ (m68hc12_addr_is_banked): New to see if address is in banked area.
+ (elf_m68hc12_howto_table): Add new relocs and rename to xx12.
+
+2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
+
+ * reloc.c (BFD_RELOC_M68HC11_RL_JUMP, BFD_RELOC_M68HC11_RL_GROUP,
+ BFD_RELOC_M68HC11_LO16, BFD_RELOC_M68HC11_PAGE,
+ BFD_RELOC_M68HC11_24): New relocs for 68HC11/68HC12.
+ * bfd-in2.h: Regenerate.
+
+2002-08-12 H.J. Lu <hjl@gnu.org>
+
+ * elflink.h (elf_add_default_symbol): Preserve section across
+ elf_merge_symbol.
+
+2002-08-09 Graeme Peterson <gp@qnx.com>
+
+ * Makefile.am: Add entries for elf32-ppcqnx.c, and add
+ elf32-qnx.h dependency to elfarmqnx-nabi.c and elf32-i386qnx.c.
+ * Makefile.in: Regenerate.
+ * config.bfd: Add support for powerpc{le}-*-nto targets.
+ * configure.in: Add support for bfd_elf32_powerpc{le}qnx_vec.
+ * configure: Regenerate.
+ * elf32-i386qnx.c: Moved backend functions into a QNX specific
+ common file "elf32-qnx.h", and now include that file.
+ * elf32-qnx.h: New file: QNX specific common elf backend.
+ * elf32-ppc.c: Do not include elf32-target.h if
+ ELF32_PPC_C_INCLUDED is defined.
+ * elf32-ppcqnx.c: New file: Support for QNX.
+ * elfarmqnx-nabi.c: Include elf32-qnx.h for qnx elf backend.
+ * targets.c: Add bfd_elf32_powerpc{le}qnx_vec.
+
+2002-08-09 Nick Clifton <nickc@redhat.com>
+
+ * po/sv.po: Updated Swedish translation.
+
+2002-08-09 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elfxx-mips.c (mips_elf_global_got_index): Avoid segfault if
+ g->global_gotsym is NULL.
+
+2002-08-08 H.J. Lu <hjl@gnu.org>
+
+ * elflink.h (elf_add_default_symbol): Don't warn if a definition
+ overrides an indirect versioned symbol.
+
+2002-08-08 Jakub Jelinek <jakub@redhat.com>
+
+ * elf32-i386.c (elf_i386_relocate_section): Fill in proper addend
+ for R_386_TLS_TPOFF32 relocs against symndx 0.
+
+2002-08-07 H.J. Lu <hjl@gnu.org>
+
+ * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Check symbol
+ with undefined version if needed.
+ (elf_link_assign_sym_version): Match a default symbol with a
+ version without definition. No need to hide the default
+ definition separately.
+
+2002-08-08 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h (elf_link_output_extsym): Don't output symbols from
+ SEC_EXCLUDE sections.
+
+ * aoutx.h (aout_link_write_symbols): Correct handling of warning syms.
+
+2002-08-07 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (edit_opd): Arrange to drop symbols for discarded .opd
+ entries.
+
+2002-08-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elfxx-mips.c (mips_elf_create_dynamic_relocation): Cast signedness
+ mismatch.
+
+2002-08-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elfxx-mips.c (ABI_64_P): Remove superfluous check.
+
+2002-08-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elf32-mips.c (mips_reloc_map): Fix typo.
+
+2002-08-06 Alan Modra <amodra@bigpond.net.au>
+
+ * xcofflink.c (xcoff_write_global_symbol): Set n_scnum for abs_section.
+
+2002-08-06 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_howto_raw): Zero all src_mask entries.
+
+2002-08-06 Alan Modra <amodra@bigpond.net.au>
+
+ * libxcoff.h: Use PARAMS on function declarations.
+ * coff-rs6000.c (xcoff_generate_rtinit): Simplify size calc.
+ * coff64-rs6000.c (xcoff64_generate_rtinit): Likewise.
+
+ * coff-rs6000.c: (xcoff_rtype2howto): Don't place reloc address in
+ addend.
+ * coff64-rs6000.c: (xcoff64_rtype2howto): Likewise.
+
+2002-08-06 Alan Modra <amodra@bigpond.net.au>
+
+ * coff-rs6000.c: Formatting fixes.
+ (xcoff_calculate_relocation): Use PARAMS in declaration.
+ (xcoff_complain_overflow): Likewise.
+ (xcoff_ppc_relocate_section): Use old-style function pointer call.
+ (bfd_xcoff_backend_data): Remove useless comments.
+ (rs6000coff_vec): Likewise.
+ (bfd_pmac_xcoff_backend_data): Likewise.
+ (pmac_xcoff_vec): Likewise.
+
+ * coff64-rs6000.c: Formatting fixes.
+ (xcoff64_calculate_relocation): Use PARAMS in declaration.
+ (xcoff64_ppc_relocate_section): Use old-style function pointer call.
+ (bfd_xcoff_backend_data): Remove useless comments.
+ (rs6000coff64_vec): Likewise.
+ (bfd_xcoff_aix5_backend_data): Likewise.
+ (aix5coff64_vec): Likewise.
+
+2002-08-06 Alan Modra <amodra@bigpond.net.au>
+
+ * coff-rs6000.c (xcoff_howto_table): Revert some of last change to
+ mask entries. Use complain_overflow_dont for R_REF.
+ (xcoff_reloc_type_ba): Revert last change.
+ (xcoff_reloc_type_br): Likewise.
+ (xcoff_reloc_type_crel): Likewise.
+ (xcoff_ppc_relocate_section): Likewise.
+ * coff64-rs6000.c (xcoff64_reloc_type_br): Likewise.
+ (xcoff64_ppc_relocate_section): Likewise.
+ (xcoff64_howto_table): Revert some of last change to mask entries.
+ Use complain_overflow_dont for R_REF.
+
+ * coff-rs6000.c (xcoff_howto_table): Fix src_mask entries. Make all
+ relocs with bitsize == 16 have size = 1.
+ (xcoff_reloc_type_ba): Correct src_mask and dst_mask adjustment.
+ (xcoff_reloc_type_br): Likewise.
+ (xcoff_reloc_type_crel): Likewise.
+ (xcoff_ppc_relocate_section): Set up src_mask and dst_mask correctly.
+ * coff64-rs6000.c (xcoff64_reloc_type_br): Correct src_mask and
+ dst_mask adjustment.
+ (xcoff64_ppc_relocate_section): Set up src_mask and dst_mask correctly.
+ (xcoff64_howto_table): Fix src_mask entries. Make all relocs with
+ bitsize == 16 have size = 1.
+
+2002-08-01 Denis Chertykov <denisc@overta.ru>
+
+ * elf32-ip2k.c: Processor manufacturer changed to Ubicom.
+ (struct misc): New field isymbuf. All free_* fields removed.
+ (symbol_value): Pass in internal syms. No need to swap syms in.
+ (ip2k_elf_relax_section): Use bfd_elf_get_elf_syms. Properly free
+ possibly cached info.
+ (tidyup_after_error): Removed.
+ (ip2k_elf_relax_section_pass1): Don't use removed fields of struct
+ misc. Use new field.
+ (adjust_all_relocations): Use internal syms. No need to swap syms
+ in and out.
+ (add_page_insn): Don't use removed fields of struct misc.
+
+2002-08-01 Nick Clifton <nickc@redhat.com>
+
+ * elf32-arm.h: Revert previous delta.
+
+2002-08-01 Nick Clifton <nickc@redhat.com>
+
+ * configure.in (AM_INIT_AUTOMAKE): Bump version number.
+ * configure: Regenerate.
+
+2002-07-31 H.J. Lu <hjl@gnu.org>
+
+ * config.bfd: Add x86-64 vector to Linux/i386 if 64bit BFD is
+ selected.
+
+2002-07-31 H.J. Lu <hjl@gnu.org>
+
+ * config.bfd: Add n32 vectors to 32bit Linux/mips if 64bit BFD
+ is selected.
+
+2002-07-31 Jakub Jelinek <jakub@redhat.com>
+
+ * elf32-i386.c (elf_i386_copy_indirect_symbol): Swap tls_type
+ if _bfd_elf_link_hash_copy_indirect will swap got.refcount.
+
+2002-07-31 Ian Dall <ian@sibyl.beware.dropbear.id.au>
+
+ * cpu-ns32k.c (_bfd_ns32k_put_immdeiate, _bfd_ns32k_get_immediate):
+ There is no 8 byte relocation type for this architecture.
+ (do_ns32k_reloc): Use bfd_vma instead of native types.
+ (bfd_ns32k_put_immediate, _bfd_ns32k_relocate_contents) put_data
+ returns void.
+ (_bfd_ns32k_put_displacement): Don't check for overflow. We can
+ rely on generic code to do that.
+ * aout-ns32k.c (howto_table): Add appropriate overflow detection
+ to all table entries.
+ (_bfd_ns32k_relocate_contents): put_data returns void.
+ * ns32k.h: (_bfd_ns32k_put_displacement, _bfd_ns32k_put_immediate)
+ (_bfd_do_ns32k_reloc_contents): Fix prototypes. put data functions
+ return void.
+
+2002-07-31 Ian Dall <ian@sibyl.beware.dropbear.id.au>
+
+ * aoutx.h (aout_link_check_ar_symbols): Whether to include an
+ archive object is target dependant.
+
+2002-07-31 Adam Nemet <anemet@lnxw.com>
+
+ * elf32-arm.h (ARM_PLT_ENTRY_SIZE): Rename PLT_ENTRY_SIZE.
+ (THUMB_PLT_ENTRY_SIZE): New macro.
+ (PLT_ENTRY_SIZE): Return the appropriate *_PLT_ENTRY_SIZE.
+ (elf32_arm_plt0_entry): Rename PLT_ENTRY_SIZE to
+ ARM_PLT_ENTRY_SIZE.
+ (elf32_arm_plt_entry): Likewise.
+ (elf_backend_plt_header_size): Likewise.
+ (elf32_thumb_plt0_entry): New global.
+ (elf32_arm_finish_dynamic_sections): Use it. Put Thumb entries
+ into .plt.thumb.
+ (elf32_thumb_plt_entry): New global.
+ (elf32_arm_finish_dynamic_symbol): Use it. Use .thumb.plt for
+ Thumb entries. Set the bottom bit of the corresponding GOT entry
+ for a Thumb PLT entry.
+ (struct elf32_arm_plt_entry_info): New structure.
+ (struct elf32_arm_link_hash_entry, plt_info): New member of this
+ type.
+ (elf32_arm_link_hash_newfunc): Initialize new member.
+ (elf32_arm_final_link_relocate, R_ARM_THM_PC22 case): Handle
+ relocations against the PLT.
+ (elf32_arm_check_relocs, case R_ARM_PLT32 case): Set
+ first_rel_type if this is the first time we encounter the symbol.
+ (elf32_arm_check_relocs, case R_ARM_THM_PC22 case): New case.
+ Determine if relocation needs a PLT entry. Set first_rel_type if
+ this is the first time we encounter the symbol
+ (elf32_arm_adjust_dynamic_symbol): Create PLT entries for Thumb
+ functions as well.
+ (elf32_arm_size_dynamic_sections): Handle .plt.thumb like .plt.
+ (elf32_arm_create_dynamic_sections): New function. Create the
+ .plt.thumb section.
+ (elf_backend_create_dynamic_sections): Call it.
+
+2002-07-31 Nick Clifton <nickc@redhat.com>
+
+ * bfd.c (bfd_alt_mach_code): Rename parameter 'index' to
+ 'alternative' in order to avoid shadowing global symbol of the
+ same name.
+ * bfd-in2.h: Regenerate.
+ * libbfd.h: Regenerate.
+ * libcoff.h: Regenerate.
+
+2002-07-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * Makefile.am: Add n32 ABI support.
+ * Makefile.in: Regenerate.
+ * config.bfd: Add n32 vectors to mips64*-*-linux* targets. Treat 64
+ bit vectors for mips*-*-linux targets as optional.
+ * configure.in: Add n32 ABI vectors.
+ * configure: Regenerate.
+ * elf32-mips.c (mips_elf32_object_p): Reject n32 ABI files.
+ * elfn32-mips.c: New file, n32 ABI support.
+ * targets.c: Add n32 ABI vectors.
+
+2002-07-30 Graeme Peterson <gp@qnx.com>
+
+ * elfarmqnx-nabi.c: New file: Support for QNX.
+ * config.bfd: Add support for arm-*-nto target.
+ * configure.in: Add support for bfd_elf32_{big|little}armqnx_vec.
+ * configure: Regenerate.
+ * Makefile.am: Add entries for elfarmqnx-nabi.c.
+ * Makefile.in: Regenerate.
+ * elf32-arm.h (ELF_MAXPAGESIZE): Do not define if already defined.
+ Do not define global function if ELFARM_NABI_C_INCLUDED is defined.
+ * elfarm-nabi.c: Do not include elf32-arm.h if
+ ELFARM_NABI_C_INCLUDED is defined.
+ * targets.c: Add bfd_elf32_{big|little}armqnx_vec.
+
+2002-07-30 Nick Clifton <nickc@redhat.com>
+
+ * po/sv.po: Updated Swedish translation.
+
+2002-07-30 Jakub Jelinek <jakub@redhat.com>
+
+ * elf.c (elf_fake_sections): Fix up .tbss sh_size and sh_type.
+
+2002-07-30 Alan Modra <amodra@bigpond.net.au>
+
+ * aoutx.h (some_aout_object_p): Clean up tdata properly on error.
+ * archive.c (bfd_generic_archive_p): Likewise.
+ * coff-rs6000.c (_bfd_xcoff_archive_p): Likewise.
+ (_bfd_xcoff_archive_p): Use bfd_scan_vma in place of strtol.
+ * coff64-rs6000.c (xcoff64_slurp_armap): Likewise.
+ (xcoff64_archive_p): Likewise.
+ (xcoff64_openr_next_archived_file): Likewise.
+ (xcoff64_archive_p): Clean up tdata properly on error.
+ * coffgen.c (coff_real_object_p): Likewise.
+ (coff_object_p): Release filehdr and opthdr.
+ * ecoff.c (_bfd_ecoff_archive_p): Clean up tdata properly on error.
+ * ieee.c (ieee_archive_p): Likewise.
+ * ihex.c (ihex_object_p): Likewise.
+ (ihex_mkobject): Always allocate tdata.
+ * peicode.h (pe_ILF_object_p): Release bfd_alloc'd buffer on error.
+ * srec.c (srec_mkobject): Always allocate tdata.
+ (srec_object_p): Clean up tdata properly on error.
+ (symbolsrec_object_p): Likewise.
+ * versados.c (versados_object_p): Likewise.
+ * vms-misc.c (_bfd_vms_get_record): Use bfd_malloc instead of malloc,
+ and bfd_realloc instead of realloc.
+ (add_new_contents): Use bfd_alloc instead of bfd_malloc for sections.
+ * vms.c (vms_initialize): Always allocate tdata. Use bfd_alloc in
+ place of bfd_malloc, simplifying error freeing. Free hash table too.
+ (vms_object_p): Clean up tdata on error.
+ (vms_mkobject): Don't complain on stderr if vms_initialize fails.
+ (vms_close_and_cleanup): Adjust for bfd_alloc use.
+
+2002-07-30 Alan Modra <amodra@bigpond.net.au>
+
+ * elfxx-ia64.c (elfNN_ia64_final_write_processing): Set e_flags.
+
+2002-07-26 Chris Demetriou <cgd@broadcom.com>
+
+ * elfxx-mips.c (_bfd_mips_elf_merge_private_bfd_data): Merge ASE
+ flags into resulting BFD.
+
+2002-07-26 Alan Modra <amodra@bigpond.net.au>
+
+ From John Reiser <jreiser@BitWagon.com>
+ * elf32-i386.c (elf_i386_link_hash_table_create): Clear
+ tls_ldm_got.refcount.
+
+2002-07-25 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elf64-mips.c: Update TODO comment.
+ (mips_elf64_higher_reloc,mips_elf64_highest_reloc,
+ mips_elf64_gprel16_reloca): Remove prototypes.
+ (mips16_jump_reloc,mips16_gprel_reloc): Add functions.
+ (UNUSED_RELOC): Replace by EMPTY_RELOC.
+ (mips_elf64_howto_table_rel): Use special R_MIPS_HI16 handling. Remove
+ wrong comments. Remove disfunctional support of R_MIPS_HIGHER and
+ R_MIPS_HIGHEST.
+ (mips_elf64_howto_table_rela): Fix handling of R_MIPS_GPREL16 and
+ R_MIPS_GOT16. Remove wrong comments.
+ (elf_mips16_jump_howto,elf_mips16_gprel_howto,
+ elf_mips_gnu_vtinherit_howto,elf_mips_gnu_vtentry_howto): New, code
+ from elf32-mips.c.
+ (mips_elf64_hi16_reloc): Fix formatting.
+ (mips_elf64_higher_reloc,mips_elf64_highest_reloc): Remove.
+ (mips_elf64_got16_reloc): Fix formatting. Remove superfluous code.
+ Better comment. Fall back to R_MIPS_GOT_DISP instead of abort().
+ (mips_elf64_gprel16_reloc): Make static. Add check for
+ partial_inplace.
+ (mips_elf64_gprel16_reloca): Remove.
+ (mips_elf64_literal_reloc): New function.
+ (mips_elf64_gprel32_reloc): Fix formatting.
+ (mips_elf64_shift6_reloc): Fix comment. Make static.
+ (mips16_jump_reloc,mips16_gprel_reloc): New functions, code from
+ elf32-mips.c.
+ (elf_reloc_map,mips_reloc_map): New mapping table, similiar as in
+ elf32-mips.c
+ (bfd_elf64_bfd_reloc_type_lookup): Use the mapping table. Enable GNU
+ specific relocations.
+ (mips_elf64_rtype_to_howto): Enable GNU specific relocations.
+ (mips_elf64_object_p): Invert logic to check for SGI-ish ABI.
+ (ELF_MAXPAGESIZE): Add comment.
+
+2002-07-25 Nick Clifton <nickc@redhat.com>
+
+ * po/sv.po: Updated Swedish translation.
+ * po/es.po: Updated Spanish translation.
+ * po/fr.po: Updated French translation.
+
+2002-07-25 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h (_bfd_elf32_link_record_local_dynamic_symbol): Define
+ as elf_link_record_local_dynamic_symbol.
+ (_bfd_elf64_link_record_local_dynamic_symbol): Likewise.
+ (elf_link_record_local_dynamic_symbol): Declare. Now returns int.
+ * elflink.h (elf_link_record_local_dynamic_symbol): Move to..
+ * elflink.c: .. here. Use bfd_elf_get_elf_syms. Check whether an
+ attempt is made to record a symbol in a discarded section, and
+ return `2' in that case.
+
+2002-07-24 Nick Clifton <nickc@redhat.com>
+
+ * po/sv.po: Updated Swedish translation.
+ * po/es.po: Updated Spanish translation.
+
+2002-07-23 Alan Modra <amodra@bigpond.net.au>
+
+ * po/SRC-POTFILES.in: Regenerate.
+
+ * elf-hppa.h (elf_hppa_relocate_section): If relocatable, return
+ immediately. Remove code handling relocatable linking.
+ * elf32-avr.c (elf32_avr_relocate_section): Likewise.
+ * elf32-cris.c (cris_elf_relocate_section): Likewise.
+ * elf32-fr30.c (elf32_frv_relocate_section): Likewise.
+ * elf32-frv.c (elf32_frv_relocate_section): Likewise.
+ * elf32-h8300.c (elf32_h8_relocate_section): Likewise.
+ * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
+ * elf32-ip2k.c (ip2k_elf_relocate_section): Likewise.
+ * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
+ * elf32-v850.c (v850_elf_relocate_section): Likewise.
+ * elf32-vax.c (elf_vax_relocate_section): Likewise.
+ * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
+ * elf32-avr.c (elf_backend_rela_normal): Define.
+ * elf32-cris.c: Likewise.
+ * elf32-fr30.c: Likewise.
+ * elf32-frv.c: Likewise.
+ * elf32-h8300.c: Likewise.
+ * elf32-hppa.c: Likewise.
+ * elf32-ip2k.c: Likewise.
+ * elf32-sparc.c: Likewise.
+ * elf32-v850.c: Likewise.
+ * elf32-vax.c: Likewise.
+ * elf64-hppa.c: Likewise.
+ * elf64-sparc.c: Likewise.
+ * elf32-fr30.c (elf32_frv_relocate_section): Edit comment.
+ * elf32-frv.c (elf32_frv_relocate_section): Likewise.
+ * elf32-i860.c (elf32_i860_relocate_section): Likewise.
+ * elf32-ip2k.c (ip2k_elf_relocate_section): Likewise.
+ * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
+ * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
+ * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
+ * elf-m10200.c (USE_RELA): Don't define.
+ * elf-m10300.c: Likewise.
+ * elfarm-oabi.c: Likewise.
+ * elf32-i370.c: Likewise.
+ * elf32-ip2k.c: Likewise.
+ * elf32-m68k.c: Likewise.
+ * elf32-mcore.c: Likewise.
+ * elf32-ppc.c: Likewise.
+ * elf32-s390.c: Likewise.
+ * elf32-vax.c: Likewise.
+ * elf64-ppc.c: Likewise.
+ * elf64-s390.c: Likewise.
+ * elf64-x86-64.c: Likewise.
+ * elfxx-ia64.c: Likewise.
+ * elf32-avr.c (USE_REL): Don't undef.
+ * elf32-ip2k.c: Likewise.
+
+2002-07-23 Nick Clifton <nickc@redhat.com>
+
+ * elf-bfd.h (struct elf_backend_data): Add new bitfield
+ 'want_p_paddr_set_to_zero'.
+ * elfxx-target.h: Set default value for want_p_paddr_set_to_zero
+ to false;
+ * elfxx-ia64.c: Set want_p_paddr_set_zero for HPUX target.
+ * elf.c (copy_private_bfd_data): Test want_p_paddr_set_zero.
+
+2002-07-23 Gabor Keresztfalvi <keresztg@mail.com>
+
+ * nlmcode.h (nlm_swap_auxiliary_headers_out): Swapped the order of
+ the MeSsAgEs and CoPyRiGhT tags to make >=NW4.x NLM loaders to
+ show the Copyright string.
+ Minor formatting tidy ups.
+
+2002-07-23 Nick Clifton <nickc@redhat.com>
+
+ * po/fr.po: Updated French translation.
+ * po/sv.po: Updated Swedish translation.
+
+2002-07-23 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h (elf_link_input_bfd): Don't change internal symbols
+ when outputting relocs.
+
+2002-07-20 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * elf64-alpha.c (elf64_alpha_size_dynamic_sections): Only insert
+ DT_PLTGOT into the dynamic section if there is a PLT.
+
+2002-07-19 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elfxx-mips.c (_bfd_mips_elf_discard_info): New function, code from
+ elf32-mips.c.
+ (_bfd_mips_elf_write_section): Likewise.
+ * elfxx-mips.h (_bfd_mips_elf_discard_info): New prototype.
+ (_bfd_mips_elf_write_section): Likewise.
+ * elf32-mips.c (elf32_mips_discard_info): Move to elfxx-mips.c.
+ (elf32_mips_write_section): Likewise.
+ * elf64-mips.c (_bfd_mips_elf_ignore_discarded_relocs): Use it.
+ (_bfd_mips_elf_write_section): Likewise.
+
+2002-07-19 Alan Modra <amodra@bigpond.net.au>
+
+ * elfxx-ia64.c: (elfNN_ia64_modify_segment_map): Properly scan
+ PT_IA_64_UNWIND segments for a given section.
+
+2002-07-17 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.am: Fix a typo.
+ * Makefile.in: Regenerate.
+
+2002-07-15 Denis Chertykov <denisc@overta.ru>
+ Frank Ch. Eigler <fche@redhat.com>
+ Ben Elliston <bje@redhat.com>
+ Alan Lehotsky <alehotsky@cygnus.com>
+ John Healy <jhealy@redhat.com>
+ Graham Stott <grahams@redhat.com>
+ Jeff Johnston <jjohnstn@redhat.com>
+
+ * Makefile.am: Add support for ip2k.
+ * Makefile.in: Regenerate.
+ * doc/Makefile.in: Regenerate.
+ * archures.c: Add support for ip2k.
+ * config.bfd: Add support for ip2k.
+ * configure.in: Add support for ip2k.
+ * configure: Regenerate.
+ * reloc.c: Add support for ip2k.
+ * targets.c: Add support for ip2k.
+ * bfd-in2.h: Regenerate.
+ * libbfd.h: Regenerate.
+ * cpu-ip2k.c: New file.
+ * elf32-ip2k.c: New file.
+
+2002-07-17 Ian Rickards <irickard@arm.com>
+
+ * dwarf2.c (concat_filename): If we can't establish the directory
+ just return the filename.
+
+2002-07-16 Moritz Jodeit <moritz@jodeit.org>
+
+ * peXXigen.c (_bfd_XXi_swap_aouthdr_out): Correct order of memset args.
+
+2002-07-16 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h: Formatting fixes, tidy prototypes.
+ (elf_link_assign_sym_version): Move common code out of loop.
+
+2002-07-16 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h (elf_link_input_bfd): Don't call reloc_emitter when
+ reloc section size is zero. Correct reloc output location.
+
+2002-07-16 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * elf-hppa.h (elf_hppa_reloc_final_type): Use R_PARISC_PCREL16F as
+ the final type for the e_fsel selector when generating PA2.0W code.
+ (elf_hppa_relocate_insn): Provide support for PA2.0W 16-bit format 1
+ relocations.
+
+2002-07-14 H.J. Lu <hjl@gnu.org>
+
+ * elflink.h (elf_link_assign_sym_version): Hide the default
+ definition if there is a hidden versioned definition.
+
+2002-07-12 Hans-Peter Nilsson <hp@axis.com>
+
+ * elf32-cris.c (cris_elf_relocate_section): Drop nonsensical
+ dynamic reference test in assertion when initializing GOT with
+ static contents. Just assert that there are either no dynamic
+ sections, the symbol is defined in the regular objects or that the
+ symbol is undef weak. Tweak comment.
+ (elf_cris_finish_dynamic_symbol): Emit .got reloc for a program
+ only if the symbol isn't defined in the program and isn't undef
+ weak.
+ (elf_cris_adjust_dynamic_symbol): Simplify condition for getting
+ rid of PLT entry: only do it if the symbol isn't defined in a DSO.
+ When doing so, clear ELF_LINK_HASH_NEEDS_PLT. Tweak comments.
+ (elf_cris_discard_excess_program_dynamics): Don't consider
+ ELF_LINK_HASH_REF_DYNAMIC when omitting .got runtime relocs.
+
+2002-07-11 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-i386.c (elf_i386_relocate_section): Don't complain about
+ unresolved debugging relocs in dynamic applications.
+ * elf32-s390.c (elf_s390_relocate_section): Likewise.
+ * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
+ * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
+ * elf64-s390.c (elf_s390_relocate_section): Likewise.
+ * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
+ * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
+
+2002-07-10 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ONES): Define.
+ (ppc64_elf_howto_table): Use ONES here to avoid warnings. Fill in
+ missing src_mask fields. Tweak R_PPC64_NONE, R_PPC64_COPY. Fill
+ in missing dst_mask fields on R_PPC64_PLT32, R_PPC64_PLTREL32.
+
+ * elf64-ppc.c (ppc64_elf_get_symbol_info): Delete.
+ (ppc64_elf_set_private_flags): Delete.
+ (ppc64_elf_section_from_shdr): Delete.
+ (ppc64_elf_merge_private_bfd_data): Remove flag checking/merging code.
+ (ppc64_elf_fake_sections): Delete.
+ (bfd_elf64_bfd_set_private_flags): Don't define.
+ (bfd_elf64_get_symbol_info): Likewise.
+ (elf_backend_section_from_shdr): Likewise.
+ (elf_backend_fake_sections): Likewise.
+
+2002-07-10 Marco Walther <Marco.Walther@sun.com>
+
+ * elf.c: (assign_section_numbers) Set sh_entsize for .stab only
+ when not already set.
+ * elf64-sparc.c: (sparc64_elf_fake_sections): New function.
+ (elf_backend_fake_sections): Define.
+
+2002-07-10 Alan Modra <amodra@bigpond.net.au>
+
+ * merge.c (_bfd_merge_section): Remove redundant output_section check.
+ Formatting.
+ (_bfd_merge_sections): Don't set SEC_EXCLUDE on unused sections.
+
+2002-07-09 Hans-Peter Nilsson <hp@axis.com>
+
+ * elf32-cris.c (cris_elf_relocate_section): Move sanity-check for
+ NULL sym_hashes to just before use.
+ <case R_CRIS_32_GOTREL>: In test for local symbol, accept also
+ symbol with non-default visibility.
+ <case R_CRIS_32_GOTREL, case R_CRIS_32_PLT_GOTREL>: Ditto.
+ <case R_CRIS_8_PCREL, case R_CRIS_16_PCREL, case R_CRIS_32_PCREL>:
+ Ditto.
+ (cris_elf_gc_sweep_hook): Only decrease h->plt.refcount for
+ symbol with non-default visibility.
+ (cris_elf_check_relocs): At tests for local symbol before
+ increasing h->plt.refcount, also check for non-default
+ visibility. Ditto when checking for local symbol to eliminate
+ pc-relative runtime relocs.
+
+2002-07-08 Alan Modra <amodra@bigpond.net.au>
+
+ * elf.c: Formatting.
+ (IS_SOLARIS_PT_INTERP): Add p_paddr and p_memsz checks.
+ (INCLUDE_SECTION_IN_SEGMENT): Remove IS_SOLARIS_PT_INTERP.
+ (copy_private_bfd_data): Set p_vaddr on broken Solaris PT_INTERP
+ segments.
+
+2002-07-07 Mark Mitchell <mark@codesourcery.com>
+ Alan Modra <amodra@bigpond.net.au>
+
+ * cofflink.c (_bfd_coff_final_link): On PE COFF systems, take into
+ account the impact of relocation count overflow when computing
+ section offsets.
+ * coffcode.h (coff_write_relocs): Use obj_pe when deciding whether
+ or not to apply the PE COFF reloc overflow handling. Fix a
+ fencepost error in deciding whether or not to use that technique.
+
+2002-07-07 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h (struct elf_reloc_cookie): Remove locsym_shndx,
+ change type of locsyms.
+ (bfd_elf_get_elf_syms): Declare.
+ * elf.c (bfd_elf_get_elf_syms): New function.
+ (group_signature): Use bfd_elf_get_elf_syms.
+ (bfd_section_from_r_symndx): Likewise.
+ * elfcode.h (elf_slurp_symbol_table): Likewise.
+ * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
+ (elf_link_add_object_symbols): Likewise. Reorganise to increase
+ locality of various data structures. Properly free internal relocs.
+ (elf_bfd_final_link): Properly free internal relocs.
+ (elf_link_check_versioned_symbol): Use bfd_elf_get_elf_syms.
+ (elf_link_input_bfd): Likewise.
+ (elf_gc_mark): Likewise. Properly free internal relocs.
+ (elf_gc_sweep): Properly free internal relocs.
+ (elf_reloc_symbol_deleted_p): No need to swap syms in.
+ (elf_bfd_discard_info): Use bfd_elf_get_elf_syms. Properly free
+ internal relocs.
+ * elf-m10200.c (mn10200_elf_relax_section): Use bfd_elf_get_elf_syms.
+ Properly free possibly cached info.
+ (mn10200_elf_relax_delete_bytes): Remove symbol swapping code.
+ (mn10200_elf_symbol_address_p): Pass in internal syms. Remove
+ symbol swapping code.
+ (mn10200_elf_get_relocated_section_contents): Use bfd_elf_get_elf_syms.
+ Properly free possibly cached info.
+ * elf-m10300.c (mn10300_elf_relax_section): As above for elf-m10200.c.
+ (mn10300_elf_relax_delete_bytes): Likewise.
+ (mn10300_elf_symbol_address_p): Likewise.
+ (mn10300_elf_get_relocated_section_contents): Likewise.
+ * elf32-h8300.c (elf32_h8_relax_section): As above for elf-m10200.c.
+ (elf32_h8_relax_delete_bytes): Likewise.
+ (elf32_h8_symbol_address_p): Likewise.
+ (elf32_h8_get_relocated_section_contents): Likewise.
+ * elf32-m32r.c (m32r_elf_relax_section): As above for elf-m10200.c.
+ (m32r_elf_relax_delete_bytes): Likewise.
+ (m32r_elf_get_relocated_section_contents): Likewise.
+ * elf32-sh.c (sh_elf_reloc_loop): Free section contents using
+ elf_section_data to determine whether cached.
+ (sh_elf_relax_section): As above for elf-m10200.c.
+ (sh_elf_relax_delete_bytes): Likewise.
+ (sh_elf_get_relocated_section_contents): Likewise.
+ * elf32-xstormy16.c (xstormy16_elf_relax_section): As above.
+ * elf64-alpha.c (elf64_alpha_relax_section): As above. Also delay
+ reading of local syms.
+ * elf64-mmix.c (mmix_elf_relax_section): Likewise.
+ * elf64-sh64.c (sh_elf64_get_relocated_section_contents): As above.
+ * elfxx-ia64.c (elfNN_ia64_relax_section): As above.
+ * elfxx-mips.c (_bfd_mips_elf_check_relocs): Properly free internal
+ relocs.
+ * elf32-arm.h (bfd_elf32_arm_process_before_allocation): Properly
+ free internal relocs and section contents. Don't read symbols.
+ * elf32-hppa.c (get_local_syms): Use bfd_elf_get_elf_syms.
+ (elf32_hppa_size_stubs): Don't free local syms.
+ * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Delay
+ reading of local syms. Use bfd_elf_get_elf_syms. Properly free
+ possibly cached info.
+ * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
+ * elf64-hppa.c (elf64_hppa_check_relocs): Use bfd_elf_get_elf_syms.
+ * elf64-ppc.c (struct ppc_link_hash_table): Delete bfd_count and
+ all_local_syms.
+ (get_local_syms): Delete function.
+ (edit_opd): Use bfd_elf_get_elf_syms. Free on error exit. Cache
+ on exit.
+ (ppc64_elf_size_stubs): Use bfd_elf_get_elf_syms. Free/cache on exit.
+
+2002-07-05 Jim Wilson <wilson@redhat.com>
+
+ * syms.c (decode_section_type): New.
+ (bfd_decode_symclass): Call decode_section_type.
+
+2002-07-04 Jakub Jelinek <jakub@redhat.com>
+
+ * merge.c (_bfd_merged_section_offset): Avoid accessing byte before
+ section content start.
+ Reported by Michael Schumacher <mike@hightec-rt.com>.
+
+2002-07-04 Alan Modra <amodra@bigpond.net.au>
+
+ * section.c (_bfd_strip_section_from_output): Remove unnecessary
+ link order code. Don't actually remove the output section here;
+ Just set a flag for the linker to do so.
+ * elflink.c (_bfd_elf_link_renumber_dynsyms): Test for removed
+ sections when setting up output section dynsyms.
+
+2002-07-04 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h (elf_link_add_object_symbols): Revert 1999-09-02 hpux
+ fudge.
+ * elf.c (bfd_section_from_shdr): Work around broken hpux shared
+ libs here instead.
+
+2002-07-02 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * elf64-s390.c (create_got_section): Set .got section alignment to
+ 8 bytes.
+ (elf_s390_check_relocs): Set .rela.dyn section alignment to 8 bytes.
+
+2002-07-02 Alan Modra <amodra@bigpond.net.au>
+
+ * elf.c (_bfd_elf_reloc_type_class): Fix comment grammar.
+
+2002-07-01 Matt Thomas <matt@3am-software.com>
+
+ * elf32-vax.c (elf32_vax_print_private_bfd_data): Change EF_*
+ to EF_VAX_*.
+
+2002-07-01 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elfxx-mips.c (ABI_64_P): Fix comment.
+ (MIPS_ELF_OPTIONS_SECTION_NAME,MIPS_ELF_STUB_SECTION_NAME): Use the
+ new section names for N64 ABI.
+ (mips_elf_output_extsym): No special _gp_disp handling for NewABI.
+ (mips_elf_calculate_relocation): Code formatting.
+ (mips_elf_create_dynamic_relocation): Likewise.
+ (_bfd_mips_elf_fake_sections): IRIX6 needs this hack, too.
+ (_bfd_mips_elf_size_dynamic_sections): Handle GOT_PAGE for any NewABI.
+ (_bfd_mips_elf_relocate_section): No special handling for R_MIPS_64
+ in any NewABI.
+ (_bfd_mips_elf_finish_dynamic_symbol): No special _gp_disp handling
+ for NewABI.
+ (_bfd_mips_elf_modify_segment_map): Handle any N64 ABI.
+ (_bfd_mips_elf_gc_sweep_hook): NewABI GOT relocs should be handled
+ here, too.
+
+2002-07-01 Andreas Schwab <schwab@suse.de>
+
+ * elf64-x86-64.c (elf64_x86_64_relocate_section): Only convert
+ R_X86_64_64 to R_X86_64_RELATIVE.
+
+2002-07-01 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * vaxbsd.c: New BFD backend for VAX BSD and Ultrix.
+ * Makefile.am (BFD32_BACKENDS, BFD32_BACKENDS_CFILES): Add new backend.
+ Run "make dep-am".
+ * config.bfd (vax-*-bsd* | vax-*-ultrix*): Use vaxbsd_vec instead of
+ host_aout_vec.
+ * configure.in (vaxbsd_vec): Add.
+ * targets.c (vaxbsd_vec): Add.
+ * Makefile.in: Rebuild.
+ * configure: Rebuild.
+ * po/SRC-POTFILES.in: Rebuild.
+
+2002-07-01 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h (elf_gc_mark): Pass in the section whose relocs we are
+ examining to gc_mark_hook, rather than the bfd.
+ (elf_gc_sections): Adjust.
+ * elf-bfd.h (struct elf_backend_data <gc_mark_hook>): Likewise.
+ * elf-m10300.c (mn10300_elf_gc_mark_hook): Likewise.
+ * elf32-arm.h (elf32_arm_gc_mark_hook): Likewise.
+ * elf32-avr.c (elf32_avr_gc_mark_hook): Likewise.
+ * elf32-cris.c (cris_elf_gc_mark_hook): Likewise.
+ * elf32-d10v.c (elf32_d10v_gc_mark_hook): Likewise.
+ * elf32-fr30.c (fr30_elf_gc_mark_hook): Likewise.
+ * elf32-hppa.c (elf32_hppa_gc_mark_hook): Likewise.
+ * elf32-i386.c (elf_i386_gc_mark_hook): Likewise.
+ * elf32-m32r.c (m32r_elf_gc_mark_hook): Likewise.
+ * elf32-m68k.c (elf_m68k_gc_mark_hook): Likewise.
+ * elf32-mcore.c (mcore_elf_gc_mark_hook): Likewise.
+ * elf32-openrisc.c (openrisc_elf_gc_mark_hook): Likewise.
+ * elf32-ppc.c (ppc_elf_gc_mark_hook): Likewise.
+ * elf32-s390.c (elf_s390_gc_mark_hook): Likewise.
+ * elf32-sh.c (sh_elf_gc_mark_hook): Likewise.
+ * elf32-sparc.c (elf32_sparc_gc_mark_hook): Likewise.
+ * elf32-v850.c (v850_elf_gc_mark_hook): Likewise.
+ * elf32-vax.c (elf_vax_gc_mark_hook): Likewise.
+ * elf32-xstormy16.c (xstormy16_elf_gc_mark_hook): Likewise.
+ * elf64-mmix.c (mmix_elf_gc_mark_hook): Likewise.
+ * elf64-ppc.c (ppc64_elf_gc_mark_hook): Likewise.
+ * elf64-s390.c (elf_s390_gc_mark_hook): Likewise.
+ * elf64-sh64.c (sh_elf64_gc_mark_hook): Likewise.
+ * elfxx-mips.c (_bfd_mips_elf_gc_mark_hook): Likewise.
+ * elfxx-mips.h (_bfd_mips_elf_gc_mark_hook): Likewise.
+ * elf64-x86-64.c (elf64_x86_64_gc_mark_hook): Likewise.
+ * elf32-frv.c (elf32_frv_gc_mark_hook): Likewise. Also remove
+ redundant local sym tests.
+ * elf64-ppc.c (struct ppc_link_hash_entry): Add is_entry.
+ (link_hash_newfunc): Init is_entry.
+ (ppc64_elf_copy_indirect_symbol): Copy is_entry.
+ (ppc64_elf_link_hash_table_create): Init all_local_syms.
+ (create_linkage_sections): Use bfd_make_section_anyway rather than
+ bfd_make_section.
+ (ppc64_elf_mark_entry_syms): New function.
+ (ppc64_elf_check_relocs): Don't bother testing elf_bad_symtab. Set
+ up opd entry to function section map.
+ (ppc64_elf_gc_mark_hook): Special case opd section relocs, and
+ relocs that reference the opd section.
+ (edit_opd): New function.
+ (ppc64_elf_size_dynamic_sections): Call get_local_syms and edit_opd.
+ (ppc64_elf_setup_section_lists): Don't calculate htab->bfd_count here.
+ (get_local_syms): Do so here. Exit if we already have local syms.
+ Remove bogus comment imported from elf32-hppa.c. Don't attempt to
+ read local syms on non-ELF input.
+ (ppc64_elf_size_stubs): Call _bfd_elf64_link_read_relocs rather
+ than duplicating it's function here. Adjust free of internal
+ relocs to suit.
+ (ppc64_elf_relocate_section): Adjust local syms in opd section.
+ * elf64-ppc.h (ppc64_elf_mark_entry_syms): Declare.
+ * elf32-hppa.c (elf32_hppa_size_stubs): Call
+ _bfd_elf32_link_read_relocs rather than duplicating it's function
+ here. Adjust free of internal relocs to suit.
+
+2002-07-01 Andreas Jaeger <aj@suse.de>
+
+ * elf64-x86-64.c (elf64_x86_64_check_relocs): Certain relocations
+ are not allowed in shared libs code, enforce -fPIC.
+
+2002-06-29 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * mmo.c (mmo_write_loc_chunk): Don't eliminate leading and
+ trailing zero-sequences when there's previous left-over data.
+
+2002-06-27 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * elf64-hppa.c (elf64_hppa_reloc_type_class): New function.
+ (elf64_hppa_finish_dynamic_sections): Check other_rel_sec, dlt_rel_sec
+ and opd_rel_sec in order for starting rela section. Check _raw_size.
+ (elf_backend_reloc_type_class): Define.
+
+2002-06-27 Kevin Buettner <kevinb@redhat.com>
+
+ * dwarf2.c (decode_line_info): Handle older, non-standard, 64-bit
+ DWARF2 formats.
+
+2002-06-27 Alan Modra <amodra@bigpond.net.au>
+
+ * cpu-powerpc.c: Comment on ordering of arch_info.
+ * elf32-ppc.c (ppc_elf_object_p): New function.
+ (elf_backend_object_p): Define.
+ * elf64-ppc.c (ppc64_elf_object_p): New function.
+ (elf_backend_object_p): Define.
+
+2002-06-26 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * configure.in (vax-*-netbsd*): Set COREFILE to netbsd-core.lo.
+ * configure: Regenerate.
+
+2002-06-25 Jason Eckhardt <jle@rice.edu>
+
+ * dwarf2.c (decode_line_info): Check unit->addr_size
+ to read in the proper number of prologue bytes.
+
+2002-06-25 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * config.bfd (powerpc-*-aix5*): Only create a selvecs for
+ aix5coff64_vec if 64-bit bfd support has been enabled.
+ (powerpc64-*-aix5*): Only define if 64-bit bfd support has
+ been enabled.
+
+ * targets.c (_bfd_target_vector[]): Only include
+ aix5coff64_vec if 64-bit bfd support has been enabled.
+
+2002-06-25 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc_add_stub): Replace strcpy/strncpy with memcpy.
+ * elf32-hppa.c (hppa_add_stub): Likewise.
+ * elflink.c (_bfd_elf_link_record_dynamic_symbol): Likewise.
+ * elflink.h (elf_add_default_symbol): Fix comment typo.
+ (elf_add_default_symbol): Replace strcpy and strncpy with memcpy.
+ (elf_link_add_object_symbols): Likewise.
+ (elf_link_assign_sym_version): Likewise.
+ * hash.c (bfd_hash_lookup): Likewise.
+ * linker.c (_bfd_generic_link_add_one_symbol): Likewise.
+ * section.c (bfd_get_unique_section_name): Likewise.
+ * syms.c (_bfd_stab_section_find_nearest_line): Likewise.
+ * elf.c (_bfd_elf_make_section_from_phdr): Likewise.
+ (assign_section_numbers): Likewise.
+ (_bfd_elfcore_make_pseudosection): Likewise.
+ (elfcore_grok_lwpstatus): Likewise.
+ (elfcore_grok_win32pstatus): Likewise.
+ (elfcore_write_note): Constify input params. Use PTR instead of
+ void *. Include terminating NUL in namesz. Correct padding.
+ Support NULL "name" param. Use memcpy instead of strcpy.
+ (elfcore_write_prpsinfo): Constify input params.
+ (elfcore_write_prstatus): Likewise. Use PTR instead of void *.
+ (elfcore_write_lwpstatus): Likewise.
+ (elfcore_write_pstatus): Likewise.
+ (elfcore_write_prfpreg): Likewise.
+ (elfcore_write_prxfpreg): Likewise.
+ * elf-bfd.h (elfcore_write_note): Update declaration.
+ (elfcore_write_prpsinfo): Likewise.
+ (elfcore_write_prstatus): Likewise.
+ (elfcore_write_pstatus): Likewise.
+ (elfcore_write_prfpreg): Likewise.
+ (elfcore_write_prxfpreg): Likewise.
+ (elfcore_write_lwpstatus): Likewise.
+
+2002-06-25 Jason Eckhardt <jle@rice.edu>
+
+ * ecoff.c (ecoff_set_symbol_info): Set BSF_FUNCTION for
+ symbols of type stProc and stStaticProc.
+
+2002-06-25 Nick Clifton <nickc@redhat.com>
+
+ * ecoff.c: VArious formatting fixes.
+
+2002-06-25 Alan Modra <amodra@bigpond.net.au>
+
+ * coff-rs6000.c (xcoff_generate_rtinit): Fix typo.
+
+2002-06-25 Alan Modra <amodra@bigpond.net.au>
+
+ * aout-adobe.c: Don't compare against "true" or "false.
+ * aout-target.h: Likewise.
+ * aoutx.h: Likewise.
+ * archive.c: Likewise.
+ * bout.c: Likewise.
+ * cache.c: Likewise.
+ * coff-a29k.c: Likewise.
+ * coff-alpha.c: Likewise.
+ * coff-i386.c: Likewise.
+ * coff-mips.c: Likewise.
+ * coff-or32.c: Likewise.
+ * coff64-rs6000.c: Likewise.
+ * coffcode.h: Likewise.
+ * coffgen.c: Likewise.
+ * cpu-ns32k.c: Likewise.
+ * ecoff.c: Likewise.
+ * ecofflink.c: Likewise.
+ * elf.c: Likewise.
+ * elf32-arm.h: Likewise.
+ * elf32-cris.c: Likewise.
+ * elf32-d30v.c: Likewise.
+ * elf32-i386.c: Likewise.
+ * elf32-mcore.c: Likewise.
+ * elf32-ppc.c: Likewise.
+ * elf32-sh.c: Likewise.
+ * elf32-sh64.c: Likewise.
+ * elf32-v850.c: Likewise.
+ * elf64-alpha.c: Likewise.
+ * elf64-sh64.c: Likewise.
+ * elfcode.h: Likewise.
+ * elfcore.h: Likewise.
+ * elflink.h: Likewise.
+ * elfxx-mips.c: Likewise.
+ * i386os9k.c: Likewise.
+ * ieee.c: Likewise.
+ * libbfd.c: Likewise.
+ * linker.c: Likewise.
+ * mmo.c: Likewise.
+ * nlm32-alpha.c: Likewise.
+ * nlm32-i386.c: Likewise.
+ * nlm32-ppc.c: Likewise.
+ * nlm32-sparc.c: Likewise.
+ * nlmcode.h: Likewise.
+ * oasys.c: Likewise.
+ * pdp11.c: Likewise.
+ * peicode.h: Likewise.
+ * reloc.c: Likewise.
+ * som.c: Likewise.
+ * srec.c: Likewise.
+ * tekhex.c: Likewise.
+ * vms.c: Likewise.
+ * xcofflink.c: Likewise.
+ * elf64-sparc.c: Edit comment to not use "== false".
+
+ * aoutf1.h: Don't use "? true : false".
+ * ecoff.c: Likewise.
+ * format.c: Likewise.
+ * ieee.c: Likewise.
+ * linker.c: Likewise.
+ * mmo.c: Likewise.
+ * oasys.c: Likewise.
+
+2002-06-23 H.J. Lu <hjl@gnu.org>
+
+ * elflink.h (elf_link_add_archive_symbols): For the default
+ version, check references with only one `@' first.
+
+2002-06-23 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * elf64-hppa.c (elf64_hppa_mark_milli_and_exported_functions): New
+ function.
+ (allocate_global_data_dlt): Don't add millicode symbols to dynamic
+ symbol table.
+ (allocate_global_data_opd, allocate_dynrel_entries): Likewise.
+ (elf64_hppa_size_dynamic_sections): Revise to use
+ elf64_hppa_mark_milli_and_exported_functions.
+ (elf64_hppa_finish_dynamic_symbol): Remove code to keep millicode
+ symbols out of dynamic symbol table.
+
+2002-06-23 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.in: Regenerate.
+ * libbfd.h: Regenerate.
+ * bfd-in2.h: Regenerate.
+ * configure: Regenerate.
+ * po/SRC-POTFILES.in: Regenerate.
+
+ * elflink.h: Comment typo fixes.
+
+2002-06-23 H.J. Lu <hjl@gnu.org>
+
+ * elf-bfd.h (elf_link_loaded_list): New structure.
+ (elf_link_hash_table): Add "loaded".
+ * elf.c (_bfd_elf_link_hash_table_init): Initialize "loaded".
+ * elflink.h (elf_link_check_versioned_symbol): New function.
+ (elf_link_output_extsym): Call elf_link_check_versioned_symbol.
+
+2002-06-19 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * elflink.h (size_dynamic_sections): If the target does not
+ support an ELF style hash table, return true, indicating that
+ nothing needed to be done, rather than false, indicating that the
+ section's size could not be computed.
+
+2002-06-18 Dave Brolley <brolley@redhat.com>
+
+ From Catherine Moore, Michael Meissner, Dave Brolley:
+ * po/SRC-POTFILES.in: Add cpu-frv.c and elf32-frv.c
+ * targets.c: Support bfd_elf32_frv_vec.
+ * reloc.c: Add FRV relocs.
+ * configure.in: Add support for bfd-elf32-frv-vec.
+ * config.bfd (targ_cpu): Add support for frv-*-elf.
+ * archures.c: Add frv arch and machines.
+ * Makefile.am (ALL_MACHINES): Add cpu-frv.lo.
+ (ALL_MACHINES_CFILES): Add cpu-frv.c.
+ (BFD32_BACKENDS): Add elf32-frv.lo.
+ (BFD32_BACKENDS_CFILES): Add elf32-frv.c
+ (cpu-frv.lo): New target.
+ (elf32-frv.lo): New target.
+ * cpu-frv.c: New file.
+ * elf32-frv.c: New file.
+
+2002-06-18 Jakub Jelinek <jakub@redhat.com>
+
+ * elfcode.h (elf_object_p): Sanity check eh_shoff == 0 implies
+ e_shnum == 0.
+ Only read the first section header if e_shoff is non-zero.
+ Don't consider e_shstrndx if there are no sections.
+
+2002-06-17 Tom Rix <trix@redhat.com>
+
+ * elf32-d10v.c (elf_d10v_howto_table): Change R_D10V_10_PCREL_R,
+ R_D10V_10_PCREL_L and R_D10V_18_PCREL to use
+ complain_overflow_bitfield.
+
+2002-06-17 Alan Modra <amodra@bigpond.net.au>
+
+ * opncls.c (bfd_openr): Remove redundant bfd_set_error.
+ (bfd_fdopenr): Likewise.
+ (bfd_openstreamr): Likewise.
+ (bfd_openw): Likewise.
+
+ * targets.c: Sort target vecs.
+ (_bfd_target_vector): Add aix5coff64_vec, bfd_elf32_sh64_vec,
+ bfd_elf32_sh64l_vec, bfd_elf32_sh64lnbsd_vec,
+ bfd_elf32_sh64nbsd_vec, bfd_elf64_sh64_vec, bfd_elf64_sh64l_vec,
+ bfd_elf64_sh64lnbsd_vec, bfd_elf64_sh64nbsd_vec.
+ * configure.in: Sort target vecs. Add m88kmach3_vec.
+ * configure: Regenerate.
+
+2002-06-16 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * elf64-mmix.c (bpo_reloc_request_sort_fn): Use member
+ bpo_reloc_no to break sort order ties, not address of items.
+
+2002-06-16 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * elf-hppa.h (elf_hppa_final_link): Fix formatting in comment.
+ Skip excluded sections in determing __gp value.
+ (elf_hppa_final_link_relocate): Use the symbol's address in
+ R_PARISC_FPTR64 relocations that don't need an opd entry.
+ * elf64-hppa.c (allocate_dynrel_entries): Simplify code.
+ (elf64_hppa_finalize_dynreloc): Likewise.
+ (elf64_hppa_size_dynamic_sections): Move comments and fix typo.
+ (elf64_hppa_finish_dynamic_symbol): Break up assert.
+
+2002-06-14 Sergey Grigoriev <serge@leopold.Physik.Uni-Augsburg.DE>
+
+ * pei-i386.c (COFF_SECTION_ALIGNMENT_ENTRIES): Enable 16 byte
+ alignment for .bss, .data and .text sections so that sse and sse2
+ code will work.
+ * pe-i386.c (COFF_SECTION_ALIGNMENT_ENTRIES): Likewise.
+
+2002-06013 J"orn Rennecke <joern.rennecke@superh.com>
+
+ config.bfd: Add support for sh[1234]l*-*-elf* | sh3el*-*-elf*,
+ sh[1234]*-elf*.
+
+2002-06-12 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * elflink.h (elf_bfd_final_link): Improve error handling for missing
+ dynamic sections.
+
+ * elf64-hppa.c (allocate_global_data_opd): We don't need an opd entry
+ for a symbol that has no output section.
+ (allocate_dynrel_entries): Correct comment.
+ (elf64_hppa_finalize_dynreloc): Likewise. Don't create an opd entry
+ unless we want one.
+ (elf64_hppa_finalize_opd): Prevent segfault if dyn_h is NULL.
+ (elf64_hppa_finalize_dlt): Likewise. Prevent segfault for symbols
+ with no section. Remove unnecessary parentheses.
+
+2002-06-11 Tom Rix <trix@redhat.com>
+
+ * coffcode.h (coff_compute_section_file_positions): Add data
+ section to AIX loader alignment check.
+
+ * coff-rs6000.c (_bfd_xcoff_mkobject): Set default text section
+ alignment to 4 bytes.
+ (_bfd_xcoff_copy_private_bfd_data): Use text and data alignment
+ power accessor macro.
+ (do_shared_object_padding): Remove invalid assertion.
+
+2002-06-10 Richard Sandiford <rsandifo@redhat.com>
+
+ * section.c (_bfd_strip_section_from_output): Set SEC_EXCLUDE
+ for removed output sections.
+
+2002-06-10 Geoffrey Keating <geoffk@redhat.com>
+
+ * merge.c (merge_strings): Use htab_create_alloc with calloc, not
+ htab_alloc.
+ * elf-strtab.c (_bfd_elf_strtab_finalize): Likewise.
+
+2002-06-08 H.J. Lu <hjl@gnu.org>
+
+ * elf.c (copy_private_bfd_data): Don't cast to bfd_size_type to
+ work around a long long bug in gcc 2.96 on mips.
+
+2002-06-08 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * Makefile.am (BFD32_BACKENDS): Add vax1knetbsd.lo.
+ (BFD32_BACKENDS_CFILES): Add vax1knetbsd.c.
+ Regenerate dependency lists.
+ * Makefile.in: Regenerate.
+ * config.bfd (vax-*-netbsdelf*, vax-*-netbsdaout*): Add
+ vax1knetbsd_vec to targ_selvecs.
+ * configure.in: Add vax1knetbsd_vec.
+ * configure: Regenerate.
+ * targets.c (_bfd_target_vector): Add vax1knetbsd_vec.
+ * vax1knetbsd.c: New file.
+ * vaxnetbsd.c: Update copyright years.
+ (TARGET_PAGE_SIZE): Set to 0x1000.
+ (DEFAULT_MID): Set to M_VAX4K_NETBSD.
+
+2002-06-08 Matt Thomas <matt@3am-software.com>
+
+ * libaout.h (enum machine_type): Add M_VAX4K_NETBSD.
+
+2002-06-08 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-sh64.c (sh64_elf64_link_output_symbol_hook): Make static.
+
+2002-06-08 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+ * armnetbsd.c: Replace CONST with const.
+ * corefile.c: Likewise.
+ * elf32-dlx.c: Likewise.
+ * elf64-mips.c: Likewise.
+ * mmo.c: Likewise.
+ * ns32knetbsd.c: Likewise.
+
+ * elf64-sparc.c (sparc64_elf_add_symbol_hook): Check the hash
+ table is elf64-sparc.
+
+2002-06-08 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elfxx-mips.c (_bfd_mips_elf_relocate_section): Simplify code.
+ Fix RELA addends to get not shifted in the result. Don't do special
+ handling of R_MIPS_64 for NewABI.
+
+2002-06-07 Alan Modra <amodra@bigpond.net.au>
+
+ * aoutx.h (NAME(aout,slurp_symbol_table)): Use bfd_zmalloc.
+ (NAME(aout,slurp_reloc_table)): Likewise.
+ * coff-mips.c (mips_relax_section): Use bfd_zalloc.
+ * coff-rs6000.c (xcoff_write_armap_big): Use bfd_zmalloc.
+ (xcoff_write_archive_contents_big): Likewise.
+ (xcoff_generate_rtinit): Likewise.
+ (xcoff_generate_rtinit): Likewise, and check error return.
+ * coff64-rs6000.c (xcoff64_generate_rtinit): Likewise.
+ * coffgen.c (coff_section_symbol): Use bfd_zalloc.
+ (coff_get_normalized_symtab): Likewise.
+ (coff_make_empty_symbol): Likewise.
+ (bfd_coff_set_symbol_class): Likewise.
+ * cofflink.c (coff_link_add_symbols): Likewise.
+ * ecoff.c (_bfd_ecoff_make_empty_symbol): Likewise.
+ * ecofflink.c (ecoff_write_shuffle): Use bfd_zmalloc.
+ (bfd_ecoff_write_accumulated_debug): Likewise.
+ * elf64-alpha.c (get_got_entry): Use bfd_zalloc.
+ * i386linux.c (bfd_i386linux_size_dynamic_sections): Likewise.
+ * i386lynx.c (NAME(lynx,slurp_reloc_table)): Use bfd_zmalloc.
+ * ieee.c (do_with_relocs): Use bfd_zalloc.
+ * m68klinux.c (bfd_m68klinux_size_dynamic_sections): Likewise.
+ * pdp11.c (NAME(aout,slurp_symbol_table)): Use bfd_zmalloc.
+ (NAME(aout,slurp_reloc_table)): Likewise.
+ (NAME(aout,squirt_out_relocs)): Don't memset when zalloc'd.
+ * reloc16.c (bfd_coff_reloc16_relax_section): Use bfd_zmalloc.
+ * som.c (som_build_and_write_symbol_table): Likewise.
+ (som_slurp_string_table): Likewise.
+ (som_slurp_symbol_table): Likewise.
+ (som_bfd_ar_write_symbol_stuff): Likewise.
+ * sparclinux.c (bfd_sparclinux_size_dynamic_sections): Use bfd_zalloc.
+ * sunos.c (bfd_sunos_size_dynamic_sections): Likewise.
+ * tekhex.c (find_chunk): Likewise. Get rid of unused "sname".
+ * vms-gsd.c (_bfd_vms_slurp_gsd): Use bfd_zmalloc.
+ * xcofflink.c (xcoff_link_add_symbols): Use bfd_zalloc/bfd_zmalloc.
+
+2002-06-07 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h (struct bfd_elf_section_data <group_name>): Replace with
+ "group" union.
+ (elf_group_name): Update.
+ (elf_group_id): Define.
+ (bfd_elf_set_group_contents): Declare.
+ * elf.c (elf_fake_sections): Qualify use of elf_group_name.
+ (set_group_contents): Rename to bfd_elf_set_group_contents. Remove
+ ATTRIBUTE_UNUSED from failedptrarg. If elf_group_id is set, use
+ that sym for the signature.
+ (_bfd_elf_compute_section_file_positions): Don't call
+ set_group_contents for "ld -r" case.
+ (swap_out_syms): Use bfd_zalloc.
+ * elflink.h (elf_link_add_archive_symbols): Likewise.
+ (NAME(bfd_elf,size_dynamic_sections)): Likewise.
+ (elf_bfd_final_link): Call bfd_elf_set_group_contents.
+
+2002-06-07 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_relocate_section): Allow unresolved
+ relocs in opd for non-shared too.
+
+2002-06-06 Jeffrey Law <law@redhat.com>
+
+ * elf32-h8300.c (elf32_h8_relax_section): Ignore uninteresting
+ relocations.
+
+2002-06-06 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * merge.c: Include libiberty.h.
+ * elf-strtab.c: Include libiberty.h.
+
+2002-06-06 Elias Athanasopoulos <eathan@otenet.gr>
+
+ * peXXigen.c (pe_print_idata): Remove unused variable.
+
+2002-06-06 David Heine <dlheine@tensilica.com>
+
+ * elf.c (assign_file_positions_for_segments): Remove unallocated
+ sections from the section to segment mapping for PT_LOAD segments.
+ Update comment about empty loadable segments.
+
+2002-06-06 Richard Sandiford <rsandifo@redhat.com>
+
+ * stabs.c (_bfd_link_section_stabs): Check that the symbol offset
+ is within the .stabstr section.
+
+2002-06-06 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h (struct elf_size_info <swap_symbol_in>): Function args
+ are "const PTR", not "const PTR *".
+ (bfd_elf32_swap_symbol_in): Likewise.
+ (bfd_elf64_swap_symbol_in): Likewise.
+ * elfcode.h (elf_swap_symbol_in): Change input args to const PTR.
+ (elf_slurp_symbol_table): Adjust call to elf_swap_symbol_in.
+ * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
+ (elf_link_add_object_symbols): Likewise.
+ (elf_link_record_local_dynamic_symbol): Likewise.
+ (elf_link_input_bfd): Likewise.
+ (elf_gc_mark): Likewise.
+ (elf_reloc_symbol_deleted_p): Likewise.
+ * elf-m10200.c (mn10200_elf_relax_section): Likewise.
+ (mn10200_elf_relax_delete_bytes): Likewise.
+ (mn10200_elf_symbol_address_p): Likewise.
+ (mn10200_elf_get_relocated_section_contents): Likewise.
+ * elf-m10300.c (mn10300_elf_relax_section): Likewise.
+ (mn10300_elf_relax_section): Likewise.
+ (mn10300_elf_relax_delete_bytes): Likewise.
+ (mn10300_elf_symbol_address_p): Likewise.
+ (mn10300_elf_get_relocated_section_contents): Likewise.
+ * elf32-h8300.c (elf32_h8_relax_section): Likewise.
+ (elf32_h8_relax_delete_bytes): Likewise.
+ (elf32_h8_symbol_address_p): Likewise.
+ (elf32_h8_get_relocated_section_contents): Likewise.
+ * elf32-hppa.c (get_local_syms): Likewise.
+ * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
+ * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
+ * elf32-sh.c (sh_elf_relax_section): Likewise.
+ (sh_elf_relax_delete_bytes): Likewise.
+ (sh_elf_get_relocated_section_contents): Likewise.
+ * elf32-xstormy16.c (xstormy16_elf_relax_section): Likewise.
+ * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
+ * elf64-hppa.c (elf64_hppa_check_relocs): Likewise.
+ * elf64-mmix.c (mmix_elf_relax_section): Likewise.
+ * elf64-ppc.c (get_local_syms): Likewise.
+ * elf64-sh64.c (sh_elf64_get_relocated_section_contents): Likewise.
+ * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
+
+2002-06-05 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * config.bfd (sh64l*-*-elf*, shl*-*-elf*): New configurations.
+
+2002-06-05 Alan Modra <amodra@bigpond.net.au>
+
+ * elf.c (group_signature): Swap in the whole symbol, and handle
+ extracting section symbol names.
+ (setup_group): Add comment.
+ (set_group_contents): When called from objcopy or ld, arrange for
+ section contents to be written. Write group member output section
+ indices to allow objcopy to reorganize sections.
+ (_bfd_elf_copy_private_section_data): Copy group info.
+
+ * elf-bfd.h (struct elf_size_info): Add swap_symbol_in field.
+ (bfd_elf32_swap_symbol_in): Update prototype.
+ (bfd_elf64_swap_symbol_in): Likewise.
+ * elfcode.h (elf_swap_symbol_in): Change input args to const PTR *.
+ (elf_slurp_symbol_table): Adjust call to elf_swap_symbol_in.
+ * elflink.h (elf_link_is_defined_archive_symbol): Likewise.
+ (elf_link_add_object_symbols): Likewise.
+ (elf_link_record_local_dynamic_symbol): Likewise.
+ (elf_link_input_bfd): Likewise.
+ (elf_gc_mark): Likewise.
+ (elf_reloc_symbol_deleted_p): Likewise.
+ * elf-m10200.c (mn10200_elf_relax_section): Likewise.
+ (mn10200_elf_relax_delete_bytes): Likewise.
+ (mn10200_elf_symbol_address_p): Likewise.
+ (mn10200_elf_get_relocated_section_contents): Likewise.
+ * elf-m10300.c (mn10300_elf_relax_section): Likewise.
+ (mn10300_elf_relax_section): Likewise.
+ (mn10300_elf_relax_delete_bytes): Likewise.
+ (mn10300_elf_symbol_address_p): Likewise.
+ (mn10300_elf_get_relocated_section_contents): Likewise.
+ * elf32-h8300.c (elf32_h8_relax_section): Likewise.
+ (elf32_h8_relax_delete_bytes): Likewise.
+ (elf32_h8_symbol_address_p): Likewise.
+ (elf32_h8_get_relocated_section_contents): Likewise.
+ * elf32-hppa.c (get_local_syms): Likewise.
+ * elf32-m68k.c (bfd_m68k_elf32_create_embedded_relocs): Likewise.
+ * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): Likewise.
+ * elf32-sh.c (sh_elf_relax_section): Likewise.
+ (sh_elf_relax_delete_bytes): Likewise.
+ (sh_elf_get_relocated_section_contents): Likewise.
+ * elf32-xstormy16.c (xstormy16_elf_relax_section): Likewise.
+ * elf64-alpha.c (elf64_alpha_relax_section): Likewise.
+ * elf64-hppa.c (elf64_hppa_check_relocs): Likewise.
+ * elf64-mmix.c (mmix_elf_relax_section): Likewise.
+ * elf64-ppc.c (get_local_syms): Likewise.
+ * elf64-sh64.c (sh_elf64_get_relocated_section_contents): Likewise.
+ * elfxx-ia64.c (elfNN_ia64_relax_section): Likewise.
+ * elfcode.h (NAME(_bfd_elf,size_info)): Update initialiser.
+ * elf64-alpha.c (alpha_elf_size_info): Likewise.
+ * elf64-hppa.c (hppa64_elf_size_info): Likewise.
+ * elf64-mips.c (mips_elf64_size_info): Likewise.
+ * elf64-s390.c (s390_elf64_size_info): Likewise.
+ * elf64-sparc.c (sparc64_elf_size_info): Likewise.
+
+2002-06-05 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * elf32-mips.c (elf32_mips_ignore_discarded_relocs): Move to...
+ elfxx-mips.c (_bfd_mips_elf_ignore_discarded_relocs): ... here.
+ elf64-mips.c (elf_backend_ignore_discarded_relocs): Use
+ _bfd_mips_elf_ignore_discarded_relocs.
+ elfxx-mips.h (_bfd_mips_elf_ignore_discarded_relocs): Declare.
+
+2002-06-05 H.J. Lu <hjl@gnu.org>
+
+ * elfxx-mips.c (mips_elf_calculate_relocation): Call
+ _bfd_elf_rel_local_sym for STT_SECTION relocations against
+ the SEC_MERGE section.
+
+2002-06-05 Alan Modra <amodra@bigpond.net.au>
+
+ * coff-alpha.c: Update copyright date.
+ * coff-mips.c: Likewise.
+ * xcoff-target.h: Likewise.
+
+ * bfd-in.h: Remove "taken from the source" comment.
+ * libbfd-in.h: Likewise.
+ * libcoff-in.h: Likewise.
+ * bfd-in2.h: Regenerate.
+ * libbfd.h: Regenerate.
+ * libcoff.h: Regenerate.
+
+ * elf.c (bfd_elf_discard_group): Return true.
+ * elf-bfd.h (bfd_elf_discard_group): Declare.
+ * bfd-in.h (bfd_elf_discard_group): Don't declare here.
+ * section.c (bfd_discard_group): Rename to bfd_generic_discard_group.
+ * bfd.c (bfd_discard_group): Define.
+ * targets.c (struct bfd_target): Add _bfd_discard_group.
+ (BFD_JUMP_TABLE_LINK): Here too.
+ * libbfd-in.h (_bfd_nolink_bfd_discard_group): Define.
+ * aout-adobe.c (aout_32_bfd_discard_group): Define.
+ * aout-target.h (MY_bfd_discard_group): Define.
+ * aout-tic30.c (MY_bfd_discard_group): Define.
+ * binary.c (binary_bfd_discard_group): Define.
+ * bout.c (b_out_bfd_discard_group): Define.
+ * coff-alpha.c (_bfd_ecoff_bfd_discard_group): Define.
+ * coffcode.h (coff_bfd_discard_group): Define.
+ * coff-mips.c (_bfd_ecoff_bfd_discard_group): Define.
+ * elfxx-target.h (bfd_elfNN_bfd_discard_group): Define.
+ * i386msdos.c (msdos_bfd_discard_group): Define.
+ * i386os9k.c (os9k_bfd_discard_group): Define.
+ * ieee.c (ieee_bfd_discard_group): Define.
+ * ihex.c (ihex_bfd_discard_group): Define.
+ * mmo.c (mmo_bfd_discard_group): Define.
+ * nlm-target.h (nlm_bfd_discard_group): Define.
+ * oasys.c (oasys_bfd_discard_group): Define.
+ * ppcboot.c (ppcboot_bfd_discard_group): Define.
+ * som.c (som_bfd_discard_group): Define.
+ * srec.c (srec_bfd_discard_group): Define.
+ * tekhex.c (tekhex_bfd_discard_group): Define.
+ * versados.c (versados_bfd_discard_group): Define.
+ * vms.c (vms_bfd_discard_group): Define.
+ * xcoff-target.h (_bfd_xcoff_bfd_discard_group): Define.
+ * coff64-rs6000.c (rs6000coff64_vec): Update initialiser.
+ (aix5coff64_vec): Likewise.
+ * coff-rs6000.c (rs6000coff_vec, pmac_xcoff_vec): Likewise.
+
+2002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * Makefile.am (BFD32_BACKENDS): Add elf32-sh64-com.lo.
+ (BFD32_BACKENDS_CFILES): Add elf32-sh64-com.c.
+ (elf32-sh64-com.lo): New dependency list.
+ * Makefile.in: Regenerate.
+ * configure.in (bfd_elf32_sh64_vec, bfd_elf32_sh64l_vec)
+ (bfd_elf32_sh64nbsd_vec, bfd_elf32_sh64lnbsd_vec): Add
+ elf32-sh64-com.lo.
+ * configure: Regenerate.
+ * elf32-sh64.c (sh64_address_in_cranges)
+ (sh64_get_contents_type, sh64_address_is_shmedia): Move to...
+ (crange_qsort_cmpb, crange_qsort_cmpl, crange_bsearch_cmpb):
+ (crange_bsearch_cmpl): Prepend _bfd_sh64_ to name and move to...
+ * elf32-sh64-com.c: ...here. New file.
+
+2002-06-04 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-openrisc.c (openrisc_elf_gc_mark_hook): Remove
+ ATTRIBUTE_UNUSED on used params.
+ * elf32-vax.c (elf_vax_gc_mark_hook): Remove unnecessary checks
+ before calling bfd_section_from_elf_index on local syms.
+ * elf64-sh64.c (sh_elf64_gc_mark_hook): Likewise.
+
+2002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * Makefile.am (BFD32_BACKENDS): Add elf32-sh64-nbsd.lo.
+ (BFD32_BACKENDS_CFILES): Add elf32-sh64-nbsd.c.
+ (BFD64_BACKENDS): Add elf64-sh64-nbsd.lo.
+ (BFD64_BACKENDS_CFILES): Add elf64-sh64-nbsd.c.
+ (elf32-sh64-nbsd.lo, elf64-sh64-nbsd.lo): New rules.
+ * Makefile.in: Regenerate.
+ * config.bfd (sh5le-*-netbsd*, sh5-*-netbsd*, sh64le-*-netbsd*)
+ (sh64-*-netbsd*): New targets.
+ * configure.in: Add bfd_elf32_sh64nbsd_vec, bfd_elf32_sh64lnbsd_vec,
+ bfd_elf64_sh64nbsd_vec, and bfd_elf64_sh64lnbsd_vec.
+ * configure: Regenerate.
+ * elf32-sh64-nbsd.c: New file.
+ * elf64-sh64-nbsd.c: New file.
+ * targets.c: Add extern decls for bfd_elf32_sh64nbsd_vec,
+ bfd_elf32_sh64lnbsd_vec, bfd_elf64_sh64nbsd_vec, and
+ bfd_elf64_sh64lnbsd_vec.
+
+2002-06-04 Alan Modra <amodra@bigpond.net.au>
+
+ * elf.c (setup_group): Set SEC_LINK_ONCE on GRP_COMDAT groups.
+ (bfd_section_from_shdr): Likewise. Set section name of group
+ sections from signature.
+ (group_signature): Split out from setup_group. Ensure symbol table
+ is available.
+ (bfd_elf_discard_group): New function.
+ (_bfd_elf_make_section_from_shdr): Don't set SEC_LINK_ONCE on
+ .gnu.linkonce* sections if they are members of a group.
+ (set_group_contents): Set GRP_COMDAT flag.
+ * section.c (bfd_discard_group): New function.
+ * bfd-in.h (bfd_elf_discard_group): Declare.
+ * bfd-in2.h: Regenerate.
+ * elf-bfd.h (struct bfd_elf_section_data): Add linkonce_p field.
+ (elf_linkonce_p): Define.
+
+2002-06-04 Alan Modra <amodra@bigpond.net.au>
+
+ * elf.c (bfd_section_from_shdr): Make "name" const.
+ * elf-bfd.h (elf_backend_section_from_shdr): Likewise.
+ * elf32-i370.c (i370_elf_section_from_shdr): Likewise.
+ * elf32-ppc.c (ppc_elf_section_from_shdr): Likewise.
+ * elf32-sh64.c (sh64_backend_section_from_shdr): Likewise.
+ * elf32-v850.c (v850_elf_section_from_shdr): Likewise.
+ * elf64-alpha.c (elf64_alpha_section_from_shdr): Likewise.
+ * elf64-hppa.c (elf64_hppa_section_from_shdr): Likewise.
+ * elf64-ppc.c (ppc64_elf_section_from_shdr): Likewise.
+ * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Likewise.
+ * elfxx-mips.c (_bfd_mips_elf_section_from_shdr): Likewise.
+ * elfxx-mips.h (_bfd_mips_elf_section_from_shdr): Likewise.
+
+2002-06-03 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * elfxx-mips.c (ABI_64_P): Use backend's data to determine the
+ ABI.
+
+2002-06-02 Kazu Hirata <kazu@cs.umass.edu>
+
+ * elf32-arc.c: Fix formatting.
+ * elf32-arm.h: Likewise.
+ * elf32-cris.c: Likewise.
+ * elf32-dlx.c: Likewise.
+ * elf32-hppa.c: Likewise.
+ * elf32-i386.c: Likewise.
+ * elf32-i386qnx.c: Likewise.
+ * elf32-or32.c: Likewise.
+ * elf32-s390.c: Likewise.
+ * elf32-sh64.c: Likewise.
+ * elf32-vax.c: Likewise.
+ * elf32-xstormy16.c: Likewise.
+ * elf64-alpha.c: Likewise.
+ * elf64-mmix.c: Likewise.
+ * elf64-ppc.c: Likewise.
+ * elf64-s390.c: Likewise.
+ * elf64-sh64.c: Likewise.
+ * elf64-x86-64.c: Likewise.
+
+2002-06-02 Richard Henderson <rth@redhat.com>
+
+ * elf64-alpha.c (elf64_alpha_relocate_section): Don't dereference
+ null when there are no got entries for a symbol.
+ (elf64_alpha_relax_find_tls_segment): Rearrange to avoid
+ uninitialized variable warning.
+
+2002-06-01 Richard Henderson <rth@redhat.com>
+
+ * elf64-alpha.c (elf64_alpha_relax_with_lituse): Don't test for
+ undefined symbols here.
+ (elf64_alpha_relax_section): Do it here. Also test for not
+ defined in the current module.
+ (elf64_alpha_relocate_section_r): Split out of ...
+ (elf64_alpha_relocate_section): ... here. Don't dereference
+ NULL when looking up local got entries.
+
+2002-06-01 Richard Henderson <rth@redhat.com>
+
+ * elf64-alpha.c (elf64_alpha_relax_with_lituse): Reject undefined
+ symbols from JSR relaxation.
+ (elf64_alpha_size_plt_section_1): New.
+ (elf64_alpha_calc_dynrel_sizes): Split out .rela.got bits ...
+ (elf64_alpha_size_rela_got_1): ... here.
+ (elf64_alpha_size_dynamic_sections): Split out .rela.got bits ...
+ (elf64_alpha_size_rela_got_section): ... here.
+ (elf64_alpha_size_plt_section): New.
+ (elf64_alpha_relax_section): Call them.
+ (elf64_alpha_size_got_sections): Remove output_bfd arg.
+ (elf64_alpha_finish_dynamic_symbol): Check gotent use_count.
+
+2002-06-01 Richard Henderson <rth@redhat.com>
+
+ * elf64-alpha.c (alpha_get_dtprel_base, alpha_get_tprel_base): New.
+ (elf64_alpha_relocate_section): Use them. Reject LE TLS relocs
+ in shared libraries. Fix DTPRELHI and TPRELHI value.
+ (INSN_ADDQ, INSN_RDUNIQ): New.
+ (struct alpha_relax_info): Add symtab_hdr, tls_segment, first_gotent.
+ (elf64_alpha_relax_with_lituse): Return boolean. Remove irelend
+ argument. Reject dynamic symbols. Use LITUSE symbolic constants.
+ (elf64_alpha_relax_got_load): Rename from relax_without_lituse.
+ Handle GOTDTPREL and GOTTPREL relocations.
+ (elf64_alpha_relax_gprelhilo): New.
+ (elf64_alpha_relax_tls_get_addr): New.
+ (elf64_alpha_relax_find_tls_segment): New.
+ (elf64_alpha_relax_section): Handle TLS relocations.
+ (ALPHA_ELF_LINK_HASH_TLS_IE): New.
+ (elf64_alpha_check_relocs): Set it.
+
+2002-06-01 Richard Henderson <rth@redhat.com>
+
+ * elf64-alpha.c (elf64_alpha_relax_section): Don't store computed gp.
+
+ * elf64-alpha.c (elf64_alpha_check_relocs): Fix typo on maybe_dynamic
+ check; don't suppress dynamic relocs for non-allocated sections.
+
+ * elf64-alpha.c: Remove dead code.
+
+2002-05-31 Alan Modra <amodra@bigpond.net.au>
+
+ * bfd-in2.h: Regenerate.
+ * libbfd.h: Regenerate.
+ * po/SRC-POTFILES.in: Regenerate.
+
+ * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Don't allocate
+ space for bss .plt.
+
+2002-05-31 Graeme Peterson <gp@qnx.com>
+
+ * Makefile.am (BFD32_BACKENDS): Add elf32-i386qnx.lo.
+ (BFD32_BACKENDS_CFILES): Add elf32-i386qnx.c.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * config.bfd: Add i[3456]86-*-nto-qnx* support.
+ * configure.in: Add bfd_elf32_i386qnx_vec support.
+ * configure: Regenerate.
+ * elf-bfd.h (struct elf_backend_data): Add set_nonloadable_filepos,
+ is_contained_by_filepos, and copy_private_bfd_data_p.
+ * elf.c (assign_file_positions_for_segments): Call backend
+ set_nonloadable_filepos. Fix non-K&R call to _bfd_error_handler.
+ (IS_CONTAINED_BY_FILEPOS): Define.
+ (INCLUDE_SECTION_IN_SEGMENT): Also test IS_CONTAINED_BY_FILEPOS.
+ (copy_private_bfd_data): Use IS_CONTAINED_BY_FILEPOS. Typo fix.
+ Fix non-K&R call to _bfd_error_handler.
+ (_bfd_elf_copy_private_section_data): Use backend
+ copy_private_bfd_data_p.
+ * elf32-i386.c: Don't include elfxx-target.h when
+ ELF32_I386_C_INCLUDED is defined.
+ * elf32-i386qnx.c: New QNX elf backend file.
+ * elfxx-target.h: Add elf_backend_set_nonloadable_filepos,
+ elf_backend_is_contained_by_filepos, and
+ elf_backend_do_copy_private_bfd_data.
+ * targets.c: Add bfd_target bfd_elf32_i386qnx_vec.
+
+2002-05-31 Alan Modra <amodra@bigpond.net.au>
+
+ * elfarm-oabi.c (bfd_elf32_arm_add_glue_sections_to_bfd): Define.
+ Move other similar defines to start of file.
+
+2002-05-30 Tom Rix <trix@redhat.com>
+
+ * coff-rs6000.c (xcoff_rtype2howto): Handle 16 bit R_RBA.
+ * coff64-rs6000.c (xcoff64_rtype2howto): Same.
+
+2002-05-30 Richard Henderson <rth@redhat.com>
+
+ * elf64-alpha.c (ALPHA_ELF_LINK_HASH_LU_TLSGD,
+ ALPHA_ELF_LINK_HASH_LU_TLSLDM, ALPHA_ELF_LINK_HASH_LU_FUNC): New.
+ (ALPHA_ELF_GOT_ENTRY_RELOCS_DONE): Remove.
+ (ALPHA_ELF_GOT_ENTRY_RELOCS_XLATED): Remove.
+ (struct alpha_elf_got_entry): Add reloc_type, reloc_done, reloc_xlated.
+ (struct alpha_elf_obj_tdata): Rename total_got_entries and
+ n_local_got_entries to total_got_size and local_got_size.
+ (elf64_alpha_howto, elf64_alpha_reloc_map): Update for TLS relocs.
+ (alpha_got_entry_size): New.
+ (elf64_alpha_relax_with_lituse): Use it.
+ (elf64_alpha_relax_without_lituse): Likewise.
+ (MAX_GOT_SIZE): Rename from MAX_GOT_ENTRIES.
+ (get_got_entry): New.
+ (elf64_alpha_check_relocs): Handle TLS relocs. Reorganize.
+ (elf64_alpha_adjust_dynamic_symbol): Test LU_FUNC as a mask.
+ (elf64_alpha_merge_ind_symbols): Check gotent->reloc_type.
+ (elf64_alpha_can_merge_gots, elf64_alpha_merge_gots): Likewise.
+ (elf64_alpha_calc_got_offsets_for_symbol): Use alpha_got_entry_size.
+ (elf64_alpha_calc_got_offsets): Likewise.
+ (alpha_dynamic_entries_for_reloc): New.
+ (elf64_alpha_calc_dynrel_sizes): Use it.
+ (elf64_alpha_size_dynamic_sections): Likewise.
+ (elf64_alpha_relocate_section): Handle TLS relocations.
+ * reloc.c: Add Alpha TLS relocations.
+ * bfd-in2.h, libbfd.h: Rebuild.
+
+2002-05-29 Ralf Habacker <ralf.habacker@freenet.de>
+
+ * peXXigen.c (pe_print_idata): Remove double printed
+ import table lines; add Bound-To comment.
+
+2002-05-29 Matt Thomas <matt@3am-software.com>
+
+ * Makefile.am (BFD32_BACKENDS): Add elf32-vax.lo.
+ (BFD32_BACKENDS_CFILES): Add elf32-vax.c.
+ (elf32-vax.lo): New rule.
+ * Makefile.in: Regenerate.
+ * configure.in (bfd_elf32_vax_vec)
+ (vaxnetbsd_vec): New vectors.
+ * configure: Regenerate.
+ * config.bfd (vax-*-netbsdelf*)
+ (vax-*-netbsdaout*)
+ (vax-*-netbsd*): New targets.
+ * elf32-vax.c: New file.
+ * reloc.c: Add VAX relocations.
+ * bfd-in2.h: Regenerate.
+ * targets.c (_bfd_target_vector): Add bfd_elf32_vax_vec.
+
+2002-05-29 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * config.bfd (arm-*-netbsd*): Add bfd_elf32_littlearm_vec
+ and bfd_elf32_bigarm_vec to targ_selvecs.
+
+2002-05-29 Ralf Habacker <ralf.habacker@freenet.de>
+
+ * peXXigen.c (pe_print_idata): Fix seg faults on printing import tables
+ with auto-imported symbols.
+
+2002-05-29 Adam Nemet <anemet@lnxw.com>
+
+ * elf32-arm.h (bfd_elf32_arm_get_bfd_for_interworking): Don't add glue
+ sections only record bfd.
+ (bfd_elf32_arm_add_glue_sections_to_bfd): New function.
+ * bfd-in.h (bfd_elf32_arm_add_glue_sections_to_bfd): Declare it.
+ * bfd-in2.h: Regenerate.
+
+2002-05-28 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * syms.c (_bfd_stab_section_find_nearest_line): Move
+ declaration and initialisation of saw_line and saw_func out of
+ for loop.
+
+2002-05-29 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_get_symbol_info): New function.
+ (bfd_elf64_get_symbol_info): Define.
+ * elfxx-target.h (bfd_elfNN_get_symbol_info): Only define if undef.
+
+2002-05-29 Andrey Volkov <avolkov@transas.com>
+
+ * cpu-h8300.c: Make default h8300 machine first in machine list.
+
+2002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
+
+ * config.bfd: Added DLX configuraton.
+ * Makefile.am: Added DLX configuraton.
+ * configure.in: Added DLX configuraton.
+ * archures.c: Add DLX architecture.
+ * reloc.c: Add DLX relocs.
+ * targets.c: Added DLX target vector.
+ * configure: Regenerate.
+ * Makefile.in: Regenreate.
+ * bfd-in2.h: Regenreate.
+ * elf32-dlx.c: New file: Support DLX target.
+ * cpu-dlx.c: New file: Support DLX target.
+
+2002-05-25 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-m68k.c (elf32_m68k_print_private_bfd_data): Formatting.
+
+ * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Revert last change.
+ (ppc64_elf_check_relocs): Don't set up function descriptor symbol
+ strings to point inside function code sym string.
+ (func_desc_adjust): Likewise.
+ (ppc64_elf_hide_symbol): Rewrite code to look up function code sym.
+
+2002-05-24 Michal Ludvig <mludvig@suse.cz>
+
+ * elf64-x86-64.c (elf64_x86_64_grok_prstatus): Added.
+ (elf64_x86_64_grok_psinfo): Added.
+
+2002-05-24 TAMURA Kent <kent@netbsd.org>
+
+ * config.bfd: Add a target for i386-netbsdpe.
+
+2002-05-24 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_copy_indirect_symbol): Don't copy is_func
+ and is_func_descriptor.
+ (func_desc_adjust): Hide function code sym in shared libs unless
+ there is a matching exported function descriptor sym.
+
+2002-05-23 Jakub Jelinek <jakub@redhat.com>
+
+ * elf.c (_bfd_elf_make_section_from_shdr): Set SEC_THREAD_LOCAL
+ for symbols from SHF_TLS section.
+ (_bfd_elf_print_private_bfd_data): Add PT_TLS.
+ (elf_fake_sections): Set SHF_TLS for SEC_THREAD_LOCAL sections.
+ (map_sections_to_segments): Build PT_TLS segment if necessary.
+ (assign_file_positions_for_segments): Likewise.
+ (get_program_header_size): Account for PT_TLS segment.
+ (swap_out_syms): Set type of BSF_THREAD_LOCAL symbols and symbols from
+ SEC_THREAD_LOCAL sections to STT_TLS.
+ * reloc.c: Add 386 and IA-64 TLS relocs.
+ * section.c (SEC_THREAD_LOCAL): Define.
+ (SEC_CONSTRUCTOR_TEXT, SEC_CONSTRUCTOR_DATA, SEC_CONSTRUCTOR_BSS):
+ Remove.
+ * elflink.h (elf_link_add_object_symbols): Support .tcommon.
+ (size_dynamic_sections): If DF_STATIC_TLS, set DF_FLAGS
+ unconditionally.
+ (struct elf_final_link_info): Add first_tls_sec.
+ (elf_bfd_final_link): Set first_tls_sec.
+ Compute elf_hash_table (info)->tls_segment.
+ (elf_link_output_extsym): Handle STT_TLS symbols.
+ (elf_link_input_bfd): Likewise.
+ * syms.c (BSF_THREAD_LOCAL): Define.
+ * bfd-in2.h: Rebuilt.
+ * libbfd.h: Rebuilt.
+ * elf32-i386.c (elf_i386_tls_transition, dtpoff_base, tpoff,
+ elf_i386_mkobject, elf_i386_object_p): New functions.
+ (elf_howto_table): Add TLS relocs.
+ (elf_i386_reloc_type_lookup): Support TLS relocs.
+ (elf_i386_info_to_howto_rel): Likewise.
+ (struct elf_i386_link_hash_entry): Add tls_type.
+ (struct elf_i386_obj_tdata): New.
+ (elf_i386_hash_entry, elf_i386_tdata, elf_i386_local_got_tls_type):
+ New macros.
+ (struct elf_i386_link_hash_table): Add tls_ldm_got.
+ (link_hash_newfunc): Clear tls_type.
+ (elf_i386_check_relocs): Support TLS relocs.
+ (elf_i386_gc_sweep_hook): Likewise.
+ (allocate_dynrelocs): Likewise.
+ (elf_i386_size_dynamic_sections): Likewise.
+ (elf_i386_relocate_section): Likewise.
+ (elf_i386_finish_dynamic_symbol): Likewise.
+ (bfd_elf32_mkobject, elf_backend_object_p): Define.
+ * elfxx-ia64.c (struct elfNN_ia64_dyn_sym_info): Add tprel_offset,
+ dtpmod_offset, dtprel_offset, tprel_done, dtpmod_done, dtprel_done,
+ want_tprel, want_dtpmod, want_dtprel.
+ (elfNN_ia64_tprel_base, elfNN_ia64_dtprel_base): New functions.
+ (ia64_howto_table): Add TLS relocs, rename R_IA64_LTOFF_TP22 to
+ R_IA64_LTOFF_TPREL22.
+ (elf_code_to_howto_index): Add TLS relocs.
+ (elfNN_ia64_check_relocs): Support TLS relocs.
+ (allocate_global_data_got): Account for TLS .got data.
+ (allocate_dynrel_entries): Account for TLS dynamic relocations.
+ (elfNN_ia64_install_value): Supprt TLS relocs.
+ (set_got_entry): Support TLS relocs.
+ (elfNN_ia64_relocate_section): Likewise.
+
+2002-05-23 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * elf32-arm.h (elf32_arm_final_link_relocate): For the Thumb
+ BLX reloc round the relocation up rather than down.
+ * coff-arm.c (coff_arm_relocate_section): Likewise.
+
+2002-05-21 H.J. Lu (hjl@gnu.org)
+
+ * linker.c (_bfd_generic_link_add_one_symbol): Allow multiple
+ definition.
+
+2002-05-22 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_size_stubs): Don't strip .branch_lt.
+ (ppc64_elf_relocate_section): Handle unresolved relocs in opd.
+
+2002-05-22 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_relocate_section): Return false for
+ unresolved relocs.
+ (ppc64_elf_size_dynamic_sections): Check for splt NULL.
+
+2002-05-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * bfd.c (bfd_get_arch_size): Remove bfd_set_error call for
+ non-ELF targets.
+
+2002-05-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elf-bfd.h (elf_backend_emit_relocs): Change prototype to return
+ an error value.
+ * elflink.h (elf_link_output_relocs): Likewise. Improve error message.
+ return with false on error.
+ (elf_link_input_bfd): Check reloc_emitter return value.
+
+2002-05-21 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * config.bfd (armeb-*-netbsdelf*): New target.
+
+2002-05-20 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc_build_one_stub): Point undefined function syms
+ at the plt call stub.
+
+2002-05-19 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * cpu-mips.c (mips_compatible): Don't try to check machine
+ compatibility.
+
+2002-05-18 Tom Rix <trix@redhat.com>
+
+ * coff64-rs6000.c (_bfd_xcoff64_swap_aux_out): Fix C_FILE auxent.
+
+2002-05-17 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_info_to_howto): Formatting.
+ (ppc64_elf_relocate_section): Don't warn about reloc overflow when
+ we've already warned about an undefined symbol. Report more
+ detail on reloc errors.
+
+2002-05-17 Alan Modra <amodra@bigpond.net.au>
+
+ * acinclude.m4 (AM_INSTALL_LIBBFD): New.
+ * configure.in: Invoke AM_INSTALL_LIBBFD.
+ * Makefile.am (install-data-local): Revert 2002-05-13. Move to..
+ (install_libbfd): .. New target.
+ (uninstall_libbfd): Likewise.
+ (install-bfdlibLTLIBRARIES): Likewise.
+ (uninstall-bfdlibLTLIBRARIES): Likewise.
+ (bfdlibdir): New.
+ (bfdincludedir): New.
+ (lib_LTLIBRARIES): Rename to bfdlib_LTLIBRARIES.
+ * aclocal.m4: Regenerate.
+ * configure: Regenerate.
+ * Makefile.in: Regenerate.
+
+2002-05-17 Stuart Balfour <sbalfour@cisco.com>
+
+ * hash.c (bfd_hash_lookup): Remove computation of len from inside
+ hash loop.
+
+2002-05-16 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * config.bfd: Add targets for sh64-linux (little endian and
+ big endian).
+
+2002-05-15 Laurent Pinchart <laurent.pinchart@skynet.be>
+
+ * peXXigen.c (pe_print_idata): Do not assume that the first thunk
+ is located in the same section as the import table. Instead
+ check, and if necessary load the section containing the thunk.
+
+2002-05-15 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * aix5ppc-core.c (xcoff64_core_p): Replace bfd_read with
+ bfd_bread.
+ (xcoff64_core_file_matches_executable_p): Replace bfd_read
+ with bfd_bread.
+
+2002-05-15 Alan Modra <amodra@bigpond.net.au>
+
+ * aix5ppc-core.c: Warning fixes.
+ * aout-adobe.c (aout_32_bfd_link_just_syms): Define.
+ * aout-target.h (MY_bfd_link_just_syms): Define.
+ * aout-tic30.c (MY_bfd_link_just_syms): Define.
+ * bfd.c (bfd_link_just_syms): Define.
+ * binary.c (binary_bfd_link_just_syms): Define.
+ * bout.c (b_out_bfd_link_just_syms): Define.
+ * coff-rs6000.c (rs6000coff_vec, pmac_xcoff_vec): Update initializer.
+ * coff64-rs6000.c (rs6000coff64_vec, aix5coff64_vec): Likewise.
+ * coffcode.h (coff_bfd_link_just_syms): Define.
+ * elf-bfd.h (enum elf_link_info_type): Add ELF_INFO_TYPE_JUST_SYMS.
+ (elf_discarded_section): Check for ELF_INFO_TYPE_JUST_SYMS.
+ (_bfd_elf_link_just_syms): Declare.
+ * elf.c (_bfd_elf_link_just_syms): New function.
+ * elf-eh-frame.c (_bfd_elf_maybe_strip_eh_frame_hdr): Check that
+ sections haven't already been discarded by the linker.
+ * elflink.h (elf_link_add_object_symbols): Likewise for stab
+ sections and SEC_MERGE sections.
+ (elf_bfd_discard_info): Similarly here.
+ * elfxx-target.h (bfd_elfNN_bfd_link_just_syms): Define.
+ * i386msdos.c (msdos_bfd_link_just_syms): Define.
+ * i386os9k.c (os9k_bfd_link_just_syms): Define.
+ * ieee.c (ieee_bfd_link_just_syms): Define.
+ * ihex.c (ihex_bfd_link_just_syms): Define.
+ * libbfd-in.h (_bfd_nolink_bfd_link_just_syms): Define.
+ (_bfd_generic_link_just_syms): Declare.
+ * libecoff.h (_bfd_ecoff_bfd_link_just_syms): Define.
+ * linker.c (_bfd_generic_link_just_syms): New function.
+ * mmo.c (mmo_bfd_link_just_syms): Define.
+ * nlm-target.h (nlm_bfd_link_just_syms): Define.
+ * oasys.c (oasys_bfd_link_just_syms): Define.
+ * ppcboot.c (ppcboot_bfd_link_just_syms): Define.
+ * som.c (som_bfd_link_just_syms): Define.
+ * srec.c (srec_bfd_link_just_syms): Define.
+ * targets.c (struct bfd_target): Add _bfd_link_just_syms.
+ (BFD_JUMP_TABLE_LINK): And here.
+ * tekhex.c (tekhex_bfd_link_just_syms): Define.
+ * versados.c (versados_bfd_link_just_syms): Define.
+ * vms.c (vms_bfd_link_just_syms): Define.
+ * libbfd.h: Regenerate.
+ * bfd-in2.h: Regenerate.
+
+2002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elf32-mips.c: Remove superfluous definitions copied from
+ elfxx-mips.c.
+ (bfd_elf32_bigmips_vec,bfd_elf32_littlemips_vec): Use the
+ SGIish vectors to check the special case.
+ (mips_elf_hi16_reloc): Fix comment.
+ (mips_elf_got16_reloc): Likewise.
+ (_bfd_mips_elf32_gprel16_reloc): Likewise.
+ (elf_reloc_map): Code cleanup.
+ (mips_reloc_map): Add comment.
+ (bfd_elf23_bfd_reloc_type_lookup): Code cleanup.
+ (mips_elf32_rtype_to_howto): Likewise.
+ (mips_elf32_discard_info): Likewise.
+ (elf32_mips_irix_compat): Invert logic: Only SGIish vectors
+ lead to IRIX compatibility now.
+
+2002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * elfxx-mips.c: Call it IRIX, not Irix in comments.
+
+2002-05-13 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * config.bfd (shle-*-netbsdelf*): Add target which includes
+ sh64 support.
+
+2002-05-13 David Edelsohn <edelsohn@gnu.org>
+
+ * configure.in: Revert 2002-04-07. Instead, auto-configure
+ HAVE_ST_C_IMPL.
+ * configure: Regenerate.
+ * config.in: Regenerate.
+ * rs6000-core.c (CNEW_IMPL): Guard use of c_impl with HAVE_ST_C_IMPL
+ or AIX_5_CORE.
+
+2002-05-11 Federico G. Schwindt <fgsch@olimpo.com.br>
+
+ * configure.in (sparc*-*-openbsd*): Support sparc64-openbsd
+ corefiles as well.2
+ * configure: Regenerate.
+
+2002-05-13 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (install-data-local): Install headers to
+ $(exec_prefix)/include.
+ * Makefile.in: Regenerate.
+
+2002-05-11 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
+ Daniel Jacobowitz <drow@mvista.com>
+
+ * coff-sh.c (sh_reloc_map): Map to R_SH_IMM32 for non-PE. Don't
+ map BFD_RELOC_RVA.
+
+2002-05-11 Federico G. Schwindt <fgsch@olimpo.com.br>
+
+ * config.bfd (alpha*-*-openbsd*, sparc64*-*-openbsd*,
+ hppa*-*-openbsd*): New targets.
+ * configure.in (alpha*-*-openbsd*): Set COREFILE.
+ * configure: Regenerate.
+
+2002-05-10 Tom Rix <trix@redhat.com>
+
+ * coff64-rs6000.c (xcoff64_reloc_type_br): New function for
+ xcoff64_ppc_relocate_section.
+ * coff-rs6000.c : Extern common xcoff_reloc_type functions.
+ * libxcoff.h: Common xcoff_reloc_type function declaration.
+
+2002-05-10 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-i386.c (elf_i386_relocate_section): Remove overflow checks
+ added in 2002-05-09 commit.
+
+ * elf32-hppa.c (elf32_hppa_size_stubs): Revert part of 2002-05-04,
+ don't look for stubs on all undefined syms.
+
+2002-05-09 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (RA_REGISTER_MASK, RA_REGISTER_SHIFT): Delete.
+ (ppc64_elf_howto_raw <R_PPC64_RELATIVE>): Not pc_relative or
+ pcrel_offset.
+
+ * elf32-i386.c (elf_howto_table): Comments.
+ (elf_i386_relocate_section): Handle more relocs for relocatable
+ linking and against SEC_MERGE sections.
+
+2002-05-08 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c (ppc_elf_create_got): New function.
+ (ppc_elf_create_dynamic_sections): Call ppc_elf_create_got before
+ _bfd_elf_create_dynamic_sections. Correct .plt flags.
+ (ppc_elf_check_relocs): Use ppc_elf_create_got in place of
+ _bfd_elf_create_got_section.
+
+2002-05-07 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h (struct elf_backend_data): Add rela_normal.
+ * elfxx-target.h (elf_backend_rela_normal): Define.
+ (elfNN_bed): Init rela_normal.
+ * elflink.h (elf_link_input_bfd <emit_relocs>): Handle adjustment
+ for section symbols here if rela_normal. Simplify abs section test.
+ * elf-m10200.c (mn10200_elf_relocate_section): If relocatable,
+ return immediately. Remove code handling relocatable linking.
+ * elf-m10300.c (mn10300_elf_relocate_section): Likewise.
+ * elf32-fr30.c (fr30_elf_relocate_section): Likewise.
+ * elf32-i370.c (i370_elf_relocate_section): Likewise.
+ * elf32-i860.c (elf32_i860_relocate_section): Likewise.
+ * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
+ * elf32-mcore.c (mcore_elf_relocate_section): Likewise.
+ * elf32-openrisc.c (openrisc_elf_relocate_section): Likewise.
+ * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
+ * elf32-s390.c (elf_s390_relocate_section): Likewise.
+ * elf32-xstormy16.c (xstormy16_elf_relocate_section): Likewise.
+ * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
+ * elf64-s390.c (elf_s390_relocate_section): Likewise.
+ * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
+ * elfxx-ia64.c (elfNN_ia64_relocate_section): Likewise.
+ * elf32-arm.h (elf32_arm_relocate_section): Likewise #ifndef USE_REL.
+ * elf32-m32r.c (m32r_elf_relocate_section): Likewise.
+ * elf-m10200.c (elf_backend_rela_normal): Define.
+ * elf-m10300.c (elf_backend_rela_normal): Define.
+ * elf32-fr30.c (elf_backend_rela_normal): Define.
+ * elf32-i370.c (elf_backend_rela_normal): Define.
+ * elf32-i860.c (elf_backend_rela_normal): Define.
+ * elf32-m68k.c (elf_backend_rela_normal): Define.
+ * elf32-mcore.c (elf_backend_rela_normal): Define.
+ * elf32-openrisc.c (elf_backend_rela_normal): Define.
+ * elf32-ppc.c (elf_backend_rela_normal): Define.
+ * elf32-s390.c (elf_backend_rela_normal): Define.
+ * elf32-xstormy16.c (elf_backend_rela_normal): Define.
+ * elf64-ppc.c (elf_backend_rela_normal): Define.
+ * elf64-s390.c (elf_backend_rela_normal): Define.
+ * elf64-x86-64.c (elf_backend_rela_normal): Define.
+ * elfxx-ia64.c (elf_backend_rela_normal): Define.
+ * elf32-arm.h (elf_backend_rela_normal): Define #ifndef USE_REL.
+ * elf32-m32r.c (elf_backend_rela_normal): Likewise.
+
+2002-05-06 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * elf32-arm.h (elf32_arm_final_link_relocate): Convert
+ 'reloc_signed_max' and 'reloc_signed_min' into half-word offsets.
+
+2002-05-06 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h (elf_link_input_bfd <emit_relocs>): Adjust r_offset
+ when not relocatable. Fix reloc_emitter call for K&R.
+
+2002-05-04 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_relocate_section): Reinstate code
+ reloading local sym addend mistakenly removed in 2002-05-01 change.
+
+ * dwarf2.c (struct line_head): Make prologue_length a bfd_vma.
+ (read_abbrevs): Change "offset" param to bfd_vma.
+ (parse_comp_unit): Change "version" and addr_size to unsigned ints.
+ Change "abbrev_offset" to bfd_vma.
+ (read_indirect_string): Use correct conversion chars in error
+ message format string, cast bfd_vma's to unsigned long.
+ (read_abbrevs): Likewise.
+ (read_attribute_value): Likewise.
+ (decode_line_info): Likewise.
+ (scan_unit_for_functions): Likewise.
+ (parse_comp_unit): Likewise.
+
+2002-05-04 Tom Rix <trix@redhat.com>
+
+ * coffswap.h (coff_swap_reloc_in): Remove XCOFF support.
+ (coff_swap_reloc_out): Same.
+ * coff-rs6000.c: (xcoff_swap_reloc_in): Moved from coffswap.h.
+ (xcoff_swap_reloc_out): Same.
+ (xcoff_rtype2howto): Renamed from _bfd_xcoff_rtype2howto. Special
+ case some 16 bit relocs. Add reloc value to output.
+ (xcoff_howto_table): Remove 64 bit R_POS, add 16 bit
+ R_RBR. Improve names.
+ (_bfd_xcoff_reloc_type_lookup): Adjust for removal of 64 bit R_POS.
+ (bfd_xcoff_backend_data): Update with new reloc swap names.
+ (bfd_pmac_xcoff_backend_data) : Same.
+ * coff64-rs6000.c: (xcoff64_swap_reloc_in): Moved from coffswap.h.
+ (xcoff64_swap_reloc_out): Same.
+ (xcoff64_rtype2howto): Special case some 16 bit relocs and 32 bit
+ R_POS. Add reloc value to output.
+ (xcoff64_howto_table): Move 64 bit R_POS to first entry. Add 16
+ bit R_RBR. Improve names, masks.
+ (xcoff64_reloc_type_lookup): Adjust for move of 64 bit R_POS.
+ (bfd_xcoff_backend_data): Update with new reloc swap names.
+ (bfd_xcoff_aix5_backend_data) : Same.
+
+2002-05-04 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-hppa.c (struct elf32_hppa_link_hash_table): Add
+ bfd_count top_index, input_list, all_local_syms.
+ (elf32_hppa_setup_section_lists): New function, split from
+ elf32_hppa_size_stubs.
+ (elf32_hppa_next_input_section): Likewise.
+ (group_sections): Likewise.
+ (get_local_syms): Likewise.
+ (elf32_hppa_size_stubs): Adjust for split out functions. Look for
+ stubs on undefined syms too.
+ (elf32_hppa_set_gp): Use bfd_link_hash* instead of elf_link_hash*.
+ Only access htab elf fields when we have an elf hash table.
+ * elf32-hppa.h (elf32_hppa_setup_section_lists): Declare.
+ (elf32_hppa_next_input_section): Declare.
+
+2002-05-04 Bob Byrnes <byrnes@curl.com>
+
+ * opncls.c (_bfd_new_bfd_contained_in): Check return value of
+ _bfd_new_bfd.
+
+2002-05-03 H.J. Lu (hjl@gnu.org)
+
+ * elfxx-mips.c (mips_elf_link_hash_entry): Add forced_local.
+ (mips_elf_link_hash_newfunc): Initialize forced_local to false.
+ (mips_elf_record_global_got_symbol): Call _bfd_mips_elf_hide_symbol
+ to hide a global symbol.
+ (_bfd_mips_elf_hide_symbol): Return if forced_local is true. Set
+ forced_local to true.
+
+2002-05-02 Richard Henderson <rth@redhat.com>
+
+ * elf64-alpha.c (elf64_alpha_relocate_section): Force relative relocs
+ vs SHN_UNDEF to zero.
+
+2002-05-02 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_howto_raw <R_PPC64_SECTOFF>): Change to a
+ 16 bit reloc.
+ <R_PPC64_SECTOFF_DS>: Likewise.
+ (ppc64_elf_reloc_type_lookup): Map from BFD_RELOC_16_BASEREL to
+ SECTOFF reloc.
+ * elf32-ppc.c (ppc_elf_howto_raw <R_PPC_SECTOFF>): Correct.
+ (ppc_elf_reloc_type_lookup): Map from BFD_RELOC_16_BASEREL to
+ SECTOFF reloc.
+
+ * elf64-ppc.c (ppc64_elf_addr16_ha_reloc): Delete.
+ (ppc64_elf_ha_reloc): New function.
+ (ppc64_elf_brtaken_reloc): New function.
+ (ppc64_elf_sectoff_reloc): New function.
+ (ppc64_elf_sectoff_ha_reloc): New function.
+ (ppc64_elf_toc_reloc): New function.
+ (ppc64_elf_toc_ha_reloc): New function.
+ (ppc64_elf_toc64_reloc): New function.
+ (ppc64_elf_unhandled_reloc): New function.
+ (ppc64_elf_howto_raw): Use the above.
+ <R_PPC64_RELATIVE>: Mark pc_relative, pcrel_offset.
+ <R_PPC64_SECTOFF>: Not pc_relative or pcrel_offset. Fix dst_mask.
+ <R_PPC64_SECTOFF_DS>: Likewise.
+ (IS_ABSOLUTE_RELOC): Update.
+ (struct ppc_link_hash_table): Add have_undefweak.
+ (ppc64_elf_link_hash_table_create): Init.
+ (func_desc_adjust): Set have_undefweak.
+ (ppc64_elf_func_desc_adjust): Call func_desc_adjust earlier. Only
+ add the .sfpr blr when have_undefweak.
+ (ppc64_elf_setup_section_lists): Check hash table flavour.
+ (ppc64_elf_next_input_section): Move output_section->owner test to
+ ppc64elf.em.
+ (ppc64_elf_set_toc): Rename to ppc64_elf_toc, remove info param
+ and relocatable test. Return TOCstart and don't set elf_gp.
+ (ppc64_elf_relocate_section): Correct BRTAKEN/BRNTAKEN branch
+ offset calculation. Add assert on weak sym branch tweaks.
+ * elf64-ppc.h (ppc64_elf_set_toc): Delete.
+ (ppc64_elf_toc): Declare.
+ (ppc64_elf_next_input_section): Update.
+
+2002-05-01 Alan Modra <amodra@bigpond.net.au>
+
+ * syms.c (_bfd_stab_section_find_nearest_line): Don't bomb on NULL
+ file_name.
+
+2002-05-01 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (CROR_151515, CROR_313131): Define.
+ (ppc64_elf_relocate_section): Use them. Don't look for plt calls
+ on R_PPC64_ADDR24 relocs. Require a nop or no link reg on plt
+ call branches. Correct undefined weak destination.
+ (ppc64_elf_func_desc_adjust): Always create at least one blr in
+ .sfpr, and correct case where either only savef* or restf* is
+ needed.
+
+ Long branch stubs, multiple stub sections.
+ * elf64-ppc.h (ppc64_elf_setup_section_lists): Declare.
+ (ppc64_elf_next_input_section): Declare.
+ * elf64-ppc.c: Move linker-only prototypes.
+ (STUB_SUFFIX): Define.
+ (enum ppc_stub_type): New.
+ (struct ppc_stub_hash_entry): New.
+ (struct ppc_branch_hash_entry): New.
+ (struct ppc_link_hash_entry): Add stub_cache, oh.
+ (struct ppc_link_hash_table): Add stub_hash_table etc. Remove
+ sstub. Add sbrlt, srelbrlt, has_14bit_branch, stub_iteration.
+ Rename plt_overflow to stub_error.
+ (ppc_stub_hash_lookup): Define.
+ (ppc_branch_hash_lookup): Define.
+ (stub_hash_newfunc): New function.
+ (branch_hash_newfunc): New function.
+ (link_hash_newfunc): Init new fields.
+ (ppc64_elf_link_hash_table_create): Likewise.
+ (ppc64_elf_link_hash_table_free): New function.
+ (ppc_stub_name): New function.
+ (ppc_get_stub_entry): New function.
+ (ppc_add_stub): New function.
+ (create_linkage_sections): Use bfd_make_section_anyway. Create
+ .branch_lt and .rela.branch_lt sections. Don't create .stub.
+ (ppc64_elf_check_relocs): Set has_14bit_branch on R_PPC64_REL14*,
+ and set up for plt call stubs. Link func and func desc syms.
+ (ppc64_elf_gc_sweep_hook): Handle REL14* as per REL24.
+ (func_desc_adjust): Avoid hash lookup when func desc sym available
+ via shortcut, and set links when processing.
+ (ppc64_elf_hide_symbol): Likewise.
+ (allocate_dynrelocs): Don't allocate stub section here.
+ (ppc64_elf_size_dynamic_sections): Handle sbrlt and srelbrlt.
+ Remove sstub code.
+ (ppc_type_of_stub): New function.
+ (build_one_stub): Delete.
+ (ppc_build_one_stub): New function.
+ (ppc_size_one_stub): New function.
+ (ppc64_elf_setup_section_lists): New function.
+ (ppc64_elf_next_input_section): New function.
+ (group_sections): New function.
+ (get_local_syms): New function.
+ (ppc64_elf_size_stubs): Rewrite.
+ (ppc64_elf_build_stubs): Rewrite.
+ (ppc64_elf_relocate_section): Look up stub entry for REL24
+ relocs. Don't propagate REL14* to dynamic objects. Look for long
+ branch stubs if REL14* or REL24 relocs won't reach.
+ (bfd_elf64_bfd_link_hash_table_free): Define.
+
+2002-04-30 Mark Mitchell <mark@codesourcery.com>
+
+ * config.bfd: Add support for powerpc-*-windiss.
+
+2002-04-30 Tom Rix <trix@redhat.com>
+
+ * xcofflink.c (xcoff_link_add_symbols): Always copy undef C_EXT
+ symbol names into the hash table.
+
+2002-04-28 Tom Rix <trix@redhat.com>
+
+ * coff-rs6000.c (xcoff_calculate_relocation) : Function table for
+ calulating relocations.
+ (xcoff_complain_overflow) : Function table for relocation errors.
+ (xcoff_ppc_relocate_section): Use relocation and complain function
+ tables.
+ (xcoff_complain_overflow_unsigned_func): New complain function.
+ (xcoff_complain_overflow_signed_func): Same.
+ (xcoff_complain_overflow_bitfield_func): Same.
+ (xcoff_complain_overflow_dont_func): Same.
+ (xcoff_reloc_type_crel): New recot function.
+ (xcoff_reloc_type_br): Same.
+ (xcoff_reloc_type_ba): Same.
+ (xcoff_reloc_type_toc): Same.
+ (xcoff_reloc_type_rel): Same.
+ (xcoff_reloc_type_neg): Same.
+ (xcoff_reloc_type_pos): Same.
+ (xcoff_reloc_type_fail): Same.
+ (xcoff_reloc_type_noop): Same.
+ * libxcoff.h : Declare common parts for xcoff64.
+ * coff64-rs6000.c (xcoff64_ppc_relocate_section): Use relocation
+ and complain function tables.
+
+2002-04-28 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-x86-64.c (struct elf64_x86_64_dyn_relocs): Comment typo.
+ * elf32-hppa.c (elf32_hppa_final_link): Formatting.
+
+2002-04-26 Alan Modra <amodra@bigpond.net.au>
+
+ * opncls.c (bfd_make_readable): Call bfd_section_list_clear.
+ * xcofflink.c (xcoff_link_add_dynamic_symbols): Likewise.
+
+ * elflink.h (elf_bfd_final_link): Ensure input bfd class is the
+ same as the output before calling elf_link_input_bfd.
+
+ * coffcode.h (coff_compute_section_file_positions): Set
+ section_tail after shuffling section list.
+
+2002-04-24 Christian Groessler <chris@groessler.org>
+
+ * coff-z8k.c (extra_case): Fix R_IMM32 relocations: The
+ addresses are 23bit with a special layout, not plain 32bit
+ values. Prevent relocation of immediate values.
+
+2002-04-24 Chris G. Demetriou <cgd@broadcom.com>
+
+ * elfxx-mips.c (_bfd_mips_elf_print_private_bfd_data): If MDMX or
+ MIPS-16 ASE flags are set, print something to indicate that.
+
+2002-04-23 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-hppa.c (hppa_type_of_stub): Correct and simplify condition
+ under which a plt call stub is used.
+ (final_link_relocate): Similarly.
+ (allocate_plt_static): Clear h-plabel except when plt entry is
+ exclusively used for a plabel.
+ (allocate_dynrelocs): Use the above to simplify plt sizing.
+ (struct elf32_hppa_link_hash_table): Add has_22bit_branch.
+ (elf32_hppa_link_hash_table_create): Init.
+ (BL22_RP): Define.
+ (hppa_build_one_stub): Use BL22_RP if has_22bit_branch.
+ (elf32_hppa_check_relocs): Set has_22bit_branch.
+
+ * elf32-hppa.c (elf32_hppa_check_relocs): Remove debug message.
+ (final_link_relocate): Likewise.
+
+2002-04-22 Jakub Jelinek <jakub@redhat.com>
+
+ * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Don't build
+ search table if some FDE is DW_EH_PE_aligned encoded either.
+ (_bfd_elf_write_section_eh_frame): Handle terminating FDE specially.
+
+2002-04-22 Richard Smith <richard@ex-parrot.com>
+ Jakub Jelinek <jakub@redhat.com>
+
+ * elf-eh-frame.c (struct eh_cie_fde): Add per_encoding_relative.
+ (_bfd_elf_discard_section_eh_frame): Set it for CIEs with pcrel
+ encoded personality.
+ (_bfd_elf_write_section_eh_frame): Adjust pcrel encoded personality
+ for CIE/FDE removal.
+
+2002-04-20 Tom Rix <trix@redhat.com>
+
+ * coff64-rs6000.c (_bfd_xcoff64_swap_aux_in): Fix C_FILE auxent.
+
+2002-04-20 Alan Modra <amodra@bigpond.net.au>
+
+ * archures.c (bfd_lookup_arch): Move the list order comment..
+ (struct bfd_arch_info): ..to where it belongs.
+ * bfd-in2.h: Regenerate.
+
+ * archures.c (bfd_lookup_arch): Add comment on list order.
+ (bfd_default_set_arch_mach): Use bfd_lookup_arch.
+ * cpu-powerpc.c (bfd_powerpc_archs): Re-order so that the default
+ is always at head of list.
+
+2002-04-18 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * coff-arm.c (coff_thumb_pcrel_12, coff_thumb_pcrel_9,
+ insert_thumb_branch, record_thumb_to_arm_glue): Suppress
+ definition of these functions for ARM_WINCE builds as they are
+ not used.
+ (SWAP_IN_RELOC_OFFSET, SWAP_OUT_RELOC_OFFSET): Do not define
+ for ARM_WINCE builds.
+
+2002-04-18 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * coff-arm.c (bfd_arm_process_before_allocation):
+
+2002-04-17 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * cpu-sh.c (scan_mach): Delete.
+ (arch_info_struct): Replace scan_mach with bfd_default_scan.
+ (bfd_sh_arch): Likewise.
+
+2002-04-16 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * ihex.c (ihex_write_object_contents): Fix check for records
+ crossing 64K boundaries.
+
+2002-04-16 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-m32r.c (m32r_elf_add_symbol_hook): Check the hash table
+ type rather than just assuming entries are ELF.
+ * elf32-sh64.c (sh64_elf_add_symbol_hook): Likewise.
+ * elf64-sh64.c (sh64_elf64_add_symbol_hook): Likewise.
+ * elf64-sparc.c (sparc64_elf_add_symbol_hook): Likewise.
+ * elf64-mmix.c (mmix_elf_add_symbol_hook): Use bfd_link_hash_entry
+ rather than elf_link_hash_entry.
+
+2002-04-15 Richard Henderson <rth@redhat.com>
+
+ * elf32-mips.c (mips_elf32_object_p): Revert 0404 fragment: allow
+ n32 binaries.
+
+2002-04-15 Michael Snyder <msnyder@redhat.com>
+
+ * opncls.c (bfd_close): Write contents if writeable.
+ Minor formatting tidy-ups.
+
+2002-04-15 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-ppc.c (ppc_elf_add_symbol_hook): Check the hash table type.
+
+2002-04-12 Michael Snyder <msnyder@redhat.com>
+
+ * bfd-in.h (bfd_get_section_lma): New access macro.
+ Minor white-space fix-up.
+
+2002-04-12 Alan Modra <amodra@bigpond.net.au>
+
+ * elf.c (prep_headers): Don't zero EI_OSABI, EI_ABIVERSION or
+ header pad.
+
+2002-04-09 DJ Delorie <dj@redhat.com>
+
+ * elfarm-nabi.c (elf32_arm_howto_table): Fix ABS16 masks.
+
+2002-04-09 Casper S. Hornstrup <chorns@users.sourceforge.net>
+
+ * coffcode.h (coff_read_word): New.
+ (coff_compute_checksum): New.
+ (coff_apply_checksum): New.
+ (coff_write_object_contents): Call coff_apply_checksum () to
+ apply checksum to PE image.
+
+2002-04-08 Randolph Chung <tausq@debian.org>
+
+ * elf32-hppa.c (hppa_unwind_entry_compare): Move to elf-hppa.h.
+ (elf32_hppa_final_link): Split out sorting logic to..
+ * elf-hppa.h (elf_hppa_sort_unwind): ..here.
+ (elf_hppa_final_link): Call elf_hppa_sort_unwind.
+
+2002-04-07 Andrew Cagney <ac131313@redhat.com>
+
+ * configure.in: Add missing ``|'' to powerpc-*-aix4.[4-9]*
+ pattern.
+ * configure: Re-generate.
+
+2002-04-07 Andrew Cagney <ac131313@redhat.com>
+
+ * configure.in: Only define AIX_CORE_DUMPX_CORE when AIX version
+ is greater or equal to 4.3.3.
+ * configure: Regenerate.
+ Fix PR gdb/344.
+
+2002-04-05 Hans-Peter Nilsson <hp@axis.com>
+
+ * elf32-cris.c (cris_elf_howto_table) <R_CRIS_16_PCREL,
+ R_CRIS_32_PCREL>: Fix typo in name.
+ (cris_elf_check_relocs): Always create .rela.got here when
+ R_CRIS_16_GOTPLT or R_CRIS_32_GOTPLT is seen.
+ (elf_cris_adjust_gotplt_to_got): Don't create .rela.got here;
+ assume it's created.
+
+2002-04-04 Daniel Jacobowitz <drow@mvista.com>
+
+ * aout-adobe.c (aout_32_bfd_link_hash_table_free): Define.
+ * aout-target.h (MY_bfd_link_hash_table_free): Conditionally
+ define.
+ * aout-tic30.c (MY_bfd_link_hash_table_free): Likewise.
+ * bfd.c (bfd_link_hash_table_free): Define.
+ * binary.c (binary_bfd_link_hash_table_free): Define.
+ * bout.c (b_out_bfd_link_hash_table_free): Define.
+ * coff-rs6000.c (rs6000coff_vec): Include
+ _bfd_generic_link_hash_table_free.
+ (pmac_xcoff_vec): Likewise.
+ * coff64-rs6000.c (rs6000coff64_vec): Likewise.
+ (aix5coff64_vec): Likewise.
+ * coffcode.h (coff_bfd_link_hash_table_free): Conditionally define.
+ * elf-m10300.c (elf32_mn10300_link_hash_table_free): New function.
+ (bfd_elf32_bfd_link_hash_table_free): Define.
+ * elf32-hppa.c (elf32_hppa_link_hash_table_free): New function.
+ (bfd_elf32_bfd_link_hash_table_free): Define.
+ * elfxx-target.h (bfd_elfNN_bfd_link_hash_table_free): Conditionally
+ define.
+ * i386msdos.c (msdos_bfd_link_hash_table_free): Define.
+ * i386os9k.c (os9k_bfd_link_hash_table_free): Define.
+ * ieee.c (ieee_bfd_link_hash_table_free): Define.
+ * ihex.c (ihex_bfd_link_hash_table_free): Define.
+ * libbfd-in.h (_bfd_nolink_bfd_link_hash_table_free): Define.
+ (_bfd_generic_link_hash_table_free): Add prototype.
+ * libcoff-in.h (_bfd_xcoff_bfd_link_hash_table_free): Add prototype.
+ * libecoff.h (_bfd_ecoff_bfd_link_hash_table_free): Define.
+ * linker.c (_bfd_generic_link_hash_table_free): New function.
+ * mmo.c (mmo_bfd_link_hash_table_free): Define.
+ * nlm-target.h (nlm_bfd_link_hash_table_free): Define.
+ * oasys.c (oasys_bfd_link_hash_table_free): Define.
+ * ppcboot.c (ppcboot_bfd_link_hash_table_free): Define.
+ * som.c (som_bfd_link_hash_table_free): Define.
+ * srec.c (srec_bfd_link_hash_table_free): Define.
+ * tekhex.c (tekhex_bfd_link_hash_table_free): Define.
+ * versados.c (versados_bfd_link_hash_table_free): Define.
+ * vms.c (vms_bfd_link_hash_table_free): New function.
+ * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_free): New function.
+
+ * coff-arm.c (coff_arm_link_hash_table_create): Use bfd_malloc
+ instead of bfd_alloc.
+ * coff-h8300.c (h8300_coff_link_hash_table_create): Likewise.
+ * coff-mcore.c (coff_mcore_link_hash_table_create): Likewise.
+ * coff-ppc.c (ppc_coff_link_hash_table_create): Likewise.
+ * cofflink.c (_bfd_coff_link_hash_table_create): Likewise.
+ * ecoff.c (_bfd_ecoff_bfd_link_hash_table_create): Likewise.
+ * elf-m10300.c (elf32_mn10300_link_hash_table_create): Likewise.
+ * elf.c (_bfd_elf_link_hash_table_create): Likewise.
+ * elf32-arm.h (elf32_arm_link_hash_table_create): Likewise.
+ * elf32-cris.c (elf_cris_link_hash_table_create): Likewise.
+ * elf32-hppa.c (elf32_hppa_link_hash_table_create): Likewise.
+ * elf32-i386.c (elf_i386_link_hash_table_create): Likewise.
+ * elf32-m68k.c (elf_m68k_link_hash_table_create): Likewise.
+ * elf32-s390.c (elf_s390_link_hash_table_create): Likewise.
+ * elf32-sh.c (sh_elf_link_hash_table_create): Likewise.
+ * elf64-alpha.c (elf64_alpha_bfd_link_hash_table_create): Likewise.
+ * elf64-ppc.c (ppc64_elf_link_hash_table_create): Likewise.
+ * elf64-s390.c (elf_s390_link_hash_table_create): Likewise.
+ * elf64-sh64.c (sh64_elf64_link_hash_table_create): Likewise.
+ * elf64-sparc.c (sparc64_elf_bfd_link_hash_table_create): Likewise.
+ * elf64-x86-64.c (elf64_x86_64_link_hash_table_create): Likewise.
+ * elfxx-mips.c (_bfd_mips_elf_link_hash_table_create): Likewise.
+ * linker.c (_bfd_generic_link_hash_table_create): Likewise.
+ * m68klinux.c (linux_link_hash_table_create): Likewise.
+ * sparclinux.c (linux_link_hash_table_create): Likewise.
+ * sunos.c (sunos_link_hash_table_create): Likewise.
+ * xcofflink.c (_bfd_xcoff_bfd_link_hash_table_create): Likewise.
+
+ * targets.c: Add _bfd_link_hash_table_free to xvec.
+
+ * bfd-in2.h: Regenerate.
+ * libbfd.h: Regenerate.
+ * libcoff.h: Regenerate.
+
+2002-04-04 Alan Modra <amodra@bigpond.net.au>
+
+ * dep-in.sed: Cope with absolute paths.
+ * Makefile.am (dep.sed): Subst TOPDIR, and not INCDIR.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * coff-arm.c: Fix copyright date.
+ * cpu-h8300.c: Likewise.
+ * cpu-i370.c: Likewise.
+ * cpu-s390.c: Likewise.
+ * cpu-mips.c: Likewise.
+ * po/SRC-POTFILES.in: Regenerate.
+
+2002-04-04 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * Makefile.am: Add elfxx-mips.c to the known backends.
+ (elf32-mips.lo): remove dependency to coff/external.h.
+ * Makefile.in: Regenerate.
+ * configure.in: Add elfxx-mips.lo to all vectors using elf32-mips.lo
+ Remove elf32-mips.lo from 64 bit vectors. Update dependencies
+ accordingly.
+ * configure: Regenerate.
+ * elf-bfd.h: Move all MIPS ELF specific prototypes to elfxx-mips.h.
+ (irix_compat_t): IRIX compatibility level, moved from elf32-mips.c.
+ (elf_backend_mips_irix_compat, elf_backend_mips_rtype_to_howto): New
+ MIPS specific backend functions.
+ * elf32-mips.c: Moved most code to elfxx-mips.c.
+ (mips_elf_hi16_reloc): Rename from _bfd_mips_elf_hi16_reloc and make
+ static.
+ (mips_elf_lo16_reloc): Likewise, was _bfd_mips_elf_lo16_reloc.
+ (mips_elf_got16_reloc): Likewise, was _bfd_mips_elf_got16_reloc.
+ (mips_elf_gprel32_reloc): Likewise, was _bfd_mips_elf_gprel32_reloc.
+ (mips_elf32_rtype_to_howto): Rename from mips_rtype_to_howto. Changed
+ interface to allow selection of the right REL or RELA howto table.
+ (mips_elf32_object_p): Rename from _bfd_mips_elf_object_p and made
+ static. Let it refuse n32 objects.
+ (elf32_mips_grok_prstatus): Rename from _bfd_elf32_mips_grok_prstatus.
+ (elf32_mips_grok_psinfo): Rename from _bfd_elf32_mips_grok_psinfo.
+ (elf32_mips_discard_info): Rename from _bfd_elf32_mips_discard_info.
+ (elf32_mips_ignore_discarded_relocs): Rename from
+ _bfd_elf32_mips_ignore_discarded_relocs.
+ (elf32_mips_write_section): Rename from _bfd_elf32_mips_write_section.
+ (elf32_mips_irix_compat): New function, replaces IRIX_COMPAT.
+ (elf_mips_howto_table_rela): Remove.
+ * elf64-mips.c: Moved most code to elfxx-mips.c.
+ (bfd_elf64_bfd_reloc_type_lookup): Make static.
+ (mips_elf64_rtype_to_howto): New function.
+ (mips_elf64_object_p): Likewise.
+ (elf64_mips_irix_compat): Likewise.
+ * elfxx-mips.c: New file containing common code merged together from
+ elf32-mips.c and elf64-mips.c.
+ * elfxx-mips.h: New file containing MIPS specific prototypes from
+ elf-bfd.h.
+ * elfxx-target.h: Add handling for elf_backend_mips_irix_compat and
+ elf_backend_mips_rtype_to_howto.
+
+2002-04-04 Alan Modra <amodra@bigpond.net.au>
+
+ * srec.c (MAXCHUNK, Chunk): Revise comments.
+ (srec_write_record): Correct buffer size.
+ (srec_write_header): Do without intermediate buffer.
+ (srec_write_section): Validate Chunk.
+ (srec_write_terminator): Pass NULL instead of dummy buffer.
+ (srec_write_symbols): Pass file and symbol names directly to
+ bfd_bwrite so sprintf won't overflow buffer.
+
+2002-04-03 Jakub Jelinek <jakub@redhat.com>
+
+ * elf32-sparc.c (elf32_sparc_relocate_section): Don't emit dynamic
+ PC relative relocs against hidden symbols.
+ * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
+
+2002-04-03 Alan Modra <amodra@bigpond.net.au>
+
+ * elf.c (_bfd_elf_make_section_from_shdr): When setting section
+ LMAs, loop over segments until p_vaddr and p_memsz specify an
+ extent enclosing the section.
+
+2002-04-02 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * ihex.c (ihex_write_object_contents): Do not allow records to
+ cross a 64K boundary - wrap if necessary.
+
+2002-04-01 Nathan Williams <nathanw@wasabisystems.com>
+
+ * elf.c (elfcore_netbsd_get_lwpid): Fix off-by-one error
+ which caused the returned LWP ID to always be 0.
+
+2002-04-01 Richard Henderson <rth@redhat.com>
+
+ * elf32-sparc.c (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
+ (elf32_sparc_relocate_section): Use it to figure out when to
+ initialize .got entries.
+ * elf64-sparc.c: Similarly.
+
+2002-03-28 Alan Modra <amodra@bigpond.net.au>
+
+ * linker.c (link_action): Ignore duplicate warning syms.
+ (_bfd_generic_link_write_global_symbol): Follow warning symbol link.
+ * elflink.h (elf_adjust_dynstr_offsets): Likewise.
+ (elf_adjust_dynamic_symbol): Likewise.
+ (elf_export_symbol): Likewise.
+ (elf_link_find_version_dependencies): Likewise.
+ (elf_link_assign_sym_version): Likewise.
+ (elf_link_sec_merge_syms): Likewise.
+ (elf_link_output_extsym): Likewise.
+ (elf_gc_sweep_symbol): Likewise.
+ (elf_gc_propagate_vtable_entries_used): Likewise.
+ (elf_gc_smash_unused_vtentry_relocs): Likewise.
+ (elf_gc_allocate_got_offsets): Likewise.
+ (elf_collect_hash_codes): Likewise.
+ * elflink.c (elf_link_renumber_hash_table_dynsyms): Likewise.
+ * elf-hppa.h (elf_hppa_unmark_useless_dynamic_symbols): Likewise.
+ (elf_hppa_remark_useless_dynamic_symbols): Likewise.
+ * elf-m10300.c (elf32_mn10300_finish_hash_table_entry): Likewise.
+ * elf32-arm.h (elf32_arm_discard_copies): Likewise.
+ * elf32-cris.c (elf_cris_adjust_gotplt_to_got): Likewise.
+ (elf_cris_discard_excess_dso_dynamics): Likewise.
+ * elf32-hppa.c (clobber_millicode_symbols): Likewise.
+ (mark_PIC_calls): Likewise.
+ (allocate_plt_static): Likewise.
+ (allocate_dynrelocs): Likewise.
+ (readonly_dynrelocs): Likewise.
+ * elf32-i386.c (allocate_dynrelocs): Likewise.
+ (readonly_dynrelocs): Likewise.
+ * elf32-i370.c (i370_elf_adjust_dynindx): Likewise.
+ * elf32-m68k.c (elf_m68k_discard_copies): Likewise.
+ * elf32-mips.c (mips_elf_output_extsym): Likewise.
+ (mips_elf_sort_hash_table_f): Likewise.
+ (mips_elf_check_mips16_stubs): Likewise.
+ * elf32-s390.c (allocate_dynrelocs): Likewise.
+ (readonly_dynrelocs): Likewise.
+ * elf32-sh.c (sh_elf_discard_copies): Likewise.
+ * elf32-xstormy16.c (xstormy16_relax_plt_check): Likewise.
+ (xstormy16_relax_plt_realloc): Likewise.
+ * elf64-alpha.c (elf64_alpha_calc_got_offsets_for_symbol): Likewise.
+ (elf64_alpha_output_extsym): Likewise.
+ * elf64-hppa.c (elf64_hppa_mark_exported_functions): Likewise.
+ * elf64-mips.c (mips_elf64_sort_hash_table_f): Likewise.
+ (mips_elf64_check_mips16_stubs): Likewise.
+ (mips_elf64_output_extsym): Likewise.
+ * elf64-ppc.c (func_desc_adjust): Likewise.
+ (allocate_dynrelocs): Likewise.
+ (readonly_dynrelocs): Likewise.
+ * elf64-s390.c (allocate_dynrelocs): Likewise.
+ (readonly_dynrelocs): Likewise.
+ * elf64-sh64.c (sh64_elf64_discard_copies): Likewise.
+ * elf64-x86-64.c (allocate_dynrelocs): Likewise.
+ (readonly_dynrelocs): Likewise.
+ * elfxx-ia64.c (elfNN_ia64_global_dyn_sym_thunk): Likewise.
+ * aoutx.h (aout_link_write_other_symbol): Likewise.
+ * cofflink.c (_bfd_coff_write_task_globals): Likewise.
+ (_bfd_coff_write_global_sym): Likewise.
+ * i386linux.c (linux_tally_symbols): Likewise.
+ * m68klinux.c (linux_tally_symbols): Likewise.
+ * sparclinux.c (linux_tally_symbols): Likewise.
+ * pdp11.c (aout_link_write_other_symbol): Likewise.
+ * sunos.c (sunos_scan_dynamic_symbol): Likewise.
+ * xcofflink.c (xcoff_build_ldsyms): Likewise.
+ (xcoff_write_global_symbol): Likewise.
+
+ * cofflink.c (_bfd_coff_final_link): Formatting.
+ * cpu-mips.c (mips_compatible): Make static, prototype.
+ * elf32-i386.c (elf_i386_check_relocs): Formatting.
+ * elf32-sh.c (sh_elf_size_dynamic_sections): Likewise.
+ * elf64-alpha.c (elf64_alpha_output_extsym): Likewise.
+ * elf64-mips.c (mips_elf64_sort_hash_table): Likewise.
+ (mips_elf64_final_link): Likewise.
+ * elflink.h (elf_link_find_version_dependencies): Remove duplicate
+ prototype.
+
+2002-03-27 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * coff-arm.c (SWAP_IN_RELOC_OFFSET): Define.
+ (SWAP_OUT_RELOC_OFFSET): Define.
+
+2002-03-27 Gregory Steuck <greg@nest.cx>
+
+ * elf.c (_bfd_elf_get_symtab_upper_bound): Leave space for
+ terminating NULL if empty symbol table.
+ (_bfd_elf_get_dynamic_symtab_upper_bound): Likewise.
+
+2002-03-26 H.J. Lu (hjl@gnu.org)
+
+ * elflink.h (elf_link_input_bfd): Revert the last change since
+ the gcc exception handling isn't fixed yet.
+
+2002-03-26 H.J. Lu (hjl@gnu.org)
+
+ * elflink.h (elf_link_input_bfd): Complain about relocations
+ against local symbols in discarded sections.
+
+2002-03-26 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.h (elf_gc_mark): Don't recurse into non-ELF sections.
+
+2002-03-23 Alan Modra <amodra@bigpond.net.au>
+
+ * elf.c (_bfd_elf_make_section_from_shdr): Don't set lma based on
+ section file offset for !SEC_LOAD sections.
+
+2002-03-21 Richard Earnshaw <rearnsha@arm.com>
+
+ * elf32-arm.h (elf32_arm_final_link_relocate <case R_ARM_GOTOFF>,
+ <case R_ARM_GOT>): Handle relocations to Thumb functions.
+
+2002-03-21 Alan Modra <amodra@bigpond.net.au>
+
+ * coff64-rs6000.c (_bfd_xcoff64_put_symbol_name): Prototype.
+ Whitespace changes.
+ * archive.c: Update copyright date.
+ * bfd-in2.h: Regenerate.
+ * libbfd.h: Regenerate.
+ * Makefile.am: Run "make dep-am"
+ * Makefile.in: Regenerate.
+ * po/SRC-POTFILES.in: Regenerate.
+
+2002-03-20 Daniel Jacobowitz <drow@mvista.com>
+
+ * dwarf2.c (struct funcinfo): Move up.
+ (lookup_address_in_function_table): New argument function_ptr.
+ Set it.
+ (lookup_address_in_line_table): New argument function. If function
+ is non-NULL, use it to handle ``addr'' before the first line note of
+ the function.
+ (comp_unit_find_nearest_line): Update and swap calls to
+ lookup_address_in_function_table and lookup_address_in_line_table.
+ * syms.c (_bfd_stab_section_find_nearest_line): Use the first
+ N_SLINE encountered if we see an N_FUN before any N_SLINE.
+
+2002-03-20 Tom Rix <trix@redhat.com>
+
+ * coff-rs6000.c (_bfd_xcoff_stat_arch_elt): Renamed from
+ _bfd_xcoff_generic_stat_arch_elt. Fix format check.
+ * coff64-rs6000.c : Use _bfd_xcoff_stat_arch_elt.
+
+2002-03-19 Tom Rix <trix@redhat.com>
+
+ * xcofflink.c (_bfd_xcoff_bfd_link_add_symbols): Look through all
+ dynamic objects in archives.
+
+2002-03-19 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * elflink.h (NAME(bfd_elf,record_link_assignment)): Don't set
+ STT_NOTYPE symbols to STT_OBJECT.
+
+2002-03-18 Jan Hubicka <jh@suse.cz>
+
+ * cpu-i386.c (bfd_x86_64_arch): Rename to "i386:x86-64"
+
+2002-03-18 Tom Rix <trix@redhat.com>
+
+ * aix5ppc.core.c : New file for AIX 5 64 bit core support.
+ * bfd-in.h : Add bfd_xcoff_ar_archive_set_magic declaration.
+ * coff-rs6000 (do_pad) : New function for archive padding.
+ (do_copy) : New function for object file copying in archives.
+ (do_shared_object_padding) : New function for padding shared
+ objects to their text section alignment in archives.
+ (bfd_xcoff_ar_achive_set_magic) : Stub.
+ (xcoff_write_armap_big) : Use do_copy and do_pad.
+ (xcoff_write_archive_contents_big) : Use do_shared_object_padding,
+ do_copy and do_pad.
+ * coff64-rs6000.c (xcoff64_write_ojbect_contents) : Use
+ bfd_xcoff_magic_number.
+ (xcoff64_bad_format_hook) : New function for _bfd_bad_format_hook
+ fop.
+ (xcoff_backend_data_r) : Use xcoff64_bad_format_hook.
+ (bfd_xcoff_aix5_backend_data) : New Aix 5 backend data.
+ (aix5coff64_vec) : New Aix 5 target aix5coff64-rs6000.
+ * rs6000-core.c : Update copyright date.
+ * xcofflink.c (bfd_xcoff_size_dynamic_sections): Check for NULL
+ csectpp.
+ * coffcode.h (coff_new_section_hook) : Use new accessor macros.
+ (coff_set_arch_mach_hook) : Add Aix 5 U64_TOCMAGIC magic #.
+ (coff_set_flags) : Use bfd_xcoff_magic_number.
+ * libxcoff.h (bfd_xcoff_is_xcoff64): Add U64_TOCMAGIC.
+ * configure.in : Add powerpc-*-aix5 and rs6000-*-aix5 support.
+ * Makefile.am : Same.
+ * config.bfd : Same.
+ * targets.c : Same.
+ * configure : Regnerate.
+ * Makefile.in : Same.
+ * bfd-in2.h : Same.
+
+2002-03-18 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/fr.po: Updated version.
+
+2002-03-18 Alan Modra <amodra@bigpond.net.au>
+
+ * libbfd.c (bfd_write_bigendian_4byte_int): Return true iff success.
+ * libbfd.h: Regenerate.
+ * archive.c (coff_write_armap): Pass on failures from
+ bfd_write_bigendian_4byte_int.
+
+2002-03-14 H.J. Lu <hjl@gnu.org>
+
+ * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Set the BFD
+ error to bfd_error_nonrepresentable_section for reinit_array
+ section in DSO.
+
+2002-03-14 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * coffcode.h (coff_slurp_symbol_table): When adding BSF_WEAK flag,
+ OR it in rather than replacing previously selected flags.
+
+ * elfxx-target.h (TARGET_BIG_SYM): Set ar_max_namelen to 15.
+ (TARGET_LITTLE_SYM): Set ar_max_namelen to 15.
+
+2002-03-14 Alan Modra <amodra@bigpond.net.au>
+
+ * cpu-mips.c (mips_compatible): New. Don't check bits_per_word.
+ (N): Use the above.
+ * elflink.h (elf_bfd_final_link): Revert last change. Instead,
+ ensure reloc size matches before calling elf_link_input_bfd.
+ Add an assert to check reloc size when counting output relocs.
+
+2002-03-14 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * mmo.c (mmo_get_loc): Return NULL rather than false.
+
+2002-03-13 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/fr.po: Updated version.
+
+2002-03-13 Alan Modra <amodra@bigpond.net.au>
+
+ * archures.c (bfd_default_compatible): Test bits_per_word.
+ * cpu-i386.c (i386_compatible): Remove. Replace occurrences with
+ bfd_default_compatible.
+ * cpu-i370.c (i370_compatible): Likewise.
+ * cpu-sparc.c (sparc_compatible): Likewise.
+ * cpu-h8300.c (compatible): Test in->arch == out->arch.
+
+ * elflink.h: Formatting fixes.
+ (elf_link_output_extsym): Merge undefined and undef weak cases.
+
+ * elflink.h (elf_bfd_final_link): Only call elf_link_input_bfd
+ when word size of input matches output word size.
+
+2002-03-12 Andreas Jaeger <aj@suse.de>
+
+ * cpu-i386.c (i386_compatible): New. Use it instead of
+ bfd_default_compatible.
+
+2002-03-07 H.J. Lu (hjl@gnu.org)
+
+ * coff-sh.c (shcoff_reloc_map): Use bfd_reloc_code_real_type
+ as the type for bfd_reloc_val.
+
+2002-03-05 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * elf-hppa.h (elf_hppa_is_dynamic_loader_symbol): New function.
+ (elf_hppa_relocate_section): Ignore undefined dynamic loader symbols.
+ (elf_hppa_final_link_relocate): Correct relocations for indirect
+ references to local data through the DLT. Fix .opd creation for
+ local symbols using R_PARISC_LTOFF_FPTR32 and R_PARISC_FPTR64
+ relocations. Use e_lsel selector for R_PARISC_DLTIND21L,
+ R_PARISC_LTOFF_FPTR21L and R_PARISC_LTOFF_TP21L as per
+ "Processor-Specific ELF for PA_RISC, Version 1.43" document.
+ Similarly, use e_rsel for DLT and LTOFF 'R' relocations.
+ * elf32-hppa.c (final_link_relocate): Revise relocation selectors
+ as per "Processor-Specific ELF for PA_RISC, Version 1.43" document.
+
+2002-03-05 Jakub Jelinek <jakub@redhat.com>
+
+ * merge.c (_bfd_merge_sections): Don't segfault if there
+ is nothing to merge due to GC.
+
+2002-03-05 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-hppa.c (clobber_millicode_symbols): Remove hack to keep
+ symbols that have been forced local.
+
+ * elflink.h (elf_bfd_final_link): Call elf_link_output_extsym
+ to output forced local syms for non-shared link.
+ (elf_link_output_extsym): Tweak condition for calling backend
+ adjust_dynamic_symbol so that previous behaviour is kept.
+ Whitespace changes throughout file.
+
+2002-03-04 H.J. Lu <hjl@gnu.org>
+
+ * elf.c (bfd_section_from_shdr): Handle special sections,
+ .init_array, .fini_array and .preinit_array.
+ (elf_fake_sections): Likewise.
+
+ * elflink.h (NAME(bfd_elf,size_dynamic_sections)): Create the
+ DT entry only if the section is in output for .init_array,
+ .fini_array and .preinit_array. Complain about .preinit_array
+ section in DSO.
+ (elf_bfd_final_link): Warn zero size for .init_array,
+ .fini_array and .preinit_array sections.
+
+ * elfxx-ia64.c (elfNN_ia64_section_from_shdr): Remove
+ SHT_INIT_ARRAY, SHT_FINI_ARRAY and SHT_PREINIT_ARRAY.
+ (elfNN_ia64_fake_sections): Remove .init_array, .fini_array and
+ .preinit_array.
+
+2002-03-04 Alan Modra <amodra@bigpond.net.au>
+
+ * configure.in (WIN32LIBADD): Don't eval PICFLAG assignment.
+ * configure: Regenerate.
+
+2002-03-02 Tom Rix <trix@redhat.com>
+
+ * coff64-rs6000.c (xcoff64_howto_table): Replace howto types with
+ symbolic equiv.
+ * coff-rs6000.c (xcoff_howto_table): Same.
+
+2002-03-01 David Mosberger <davidm@hpl.hp.com>
+
+ * elflink.h (size_dynamic_sections): If section named
+ ".preinit_array" exists, create DT_PREINIT_ARRAY and
+ DT_PREINIT_ARRAYSZ entries in dynamic table. Analogously for
+ ".init_array" and ".fini_array".
+ (elf_bfd_final_link): Handle DT_PREINIT_ARRAYSZ, DT_INIT_ARRAYSZ,
+ DT_FINI_ARRAYSZ, DT_PREINIT_ARRAY, DT_INIT_ARRAY, and
+ DT_FINI_ARRAY.
+
+2002-02-26 Andrew Macleod <amacleod@cygnus.com>
+
+ * elflink.h (elf_bfd_final_link): Don't crash on SHN_UNDEF local
+ dynsyms.
+
+2002-02-25 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-hppa.h: Update copyright date.
+
+ * elf64-ppc.c (ppc64_elf_check_relocs): Warning fix.
+ (ppc64_elf_relocate_section): Don't generate power4 style branch
+ hints for *_BRTAKEN and *_BRNTAKEN relocs.
+
+2002-02-22 Jakub Jelinek <jakub@redhat.com>
+
+ * elf64-sh64.c (sh_elf64_relocate_section): Fix a typo from my
+ last patch.
+ * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
+
+2002-02-21 Andreas Jaeger <aj@suse.de>
+
+ * elf64-x86-64.c: Major rework that introduces all recent changes
+ to the x86-64 backend. Get a closer match to elf32-i386.
+ (struct elf64_x86_64_dyn_relocs): Rename from
+ elf64_x86_64_pcrel_relocs_copied, add additional fields. Change
+ all users.
+ (struct elf64_x86_64_link_hash_table): Add short cuts to some
+ sections.
+ (link_hash_newfunc): Rename from elf64_x86_64_link_hash_newfunc,
+ remove casts, initialize new hash members.
+ (create_got_section): New.
+ (elf64_x86_64_create_dynamic_sections): New.
+ (elf64_x86_64_copy_indirect_symbol): New.
+ (elf64_x86_64_check_relocs): Don't allocate space for dynamic
+ relocs, .got or .relgot here but do it in allocate_dynrelocs.
+ Reference count possible .plt and .got entries. Don't test input
+ section SEC_READONLY here to try to avoid copy relocs, and keep
+ dyn_relocs regardless of ELF_LINK_NON_GOT_REF. Don't set
+ DF_TEXTREL here. Delay setting of variables until needed. Cache
+ pointer to "sreloc" section in elf_section_data. Tweak condition
+ under which .got created. Report files with bad relocation
+ section names.
+ (elf64_x86_64_gc_sweep_hook): Sweep dyn_relocs and local_dynrel.
+ Reference count possible .plt entries. Don't deallocate .got and
+ .relgot space here.
+ (elf64_x86_64_adjust_dynamic_symbol): Handle nocopyreloc. Don't
+ do copy reloc processing for weakdefs. Remove redundant casts and
+ aborts. Delay setting of vars until needed. Move creation of
+ dynamic symbols and allocation of .plt and .rela.plt to
+ allocate_dynrelocs. Replace BFD_ASSERT with abort.
+ (WILL_CALL_FINISH_DYNAMIC_SYMBOL): New.
+ (allocate_dynrelocs): New.
+ (readonly_dynrelocs): New.
+ (elf64_x86_64_size_dynamic_sections): Call readonly_dynrelocs.
+ Allocate space for dyn relocs. Replace BFD_ASSERT with abort.
+ Zero out the dynamic allocated content space.
+ (elf64_x86_64_discard_copies): Removed.
+ (elf64_x86_64_relocate_section): Make use of dynamic section
+ short-cuts. Localise vars, and delay setting. Better error
+ reporting, replace BFD_ASSERT with abort. Check
+ ELF_LINK_HASH_DEF_DYNAMIC to see if a symbol is not defined in the
+ regular object file and tread the weak definition as the normal
+ one. Don't discard relocs for undefweak or undefined symbols and
+ check !DEF_REGULAR as well as DEF_DYNAMIC in test for avoided copy
+ relocs.
+ (elf64_x86_64_finish_dynamic_symbol): Don't copy relocs for
+ symbols that have been forced local. Use same test to decide if
+ we can use a relative reloc for got as relocate_section. Expand
+ SHN_UNDEF comment. Move expressions out of function calls.
+ Replace BFD_ASSERT with abort.
+ (bfd_elf64_bfd_final_link): Removed.
+ (elf_backend_copy_indirect_symbol): Define.
+
+2002-02-20 Tom Rix <trix@redhat.com>
+
+ * coff-rs6000.c (xcoff_howto_table): Add 16 bit R_BA.
+ (_bfd_xcoff_reloc_type_lookup): Use it.
+ * coff64-rs6000.c (xcoff64_howto_table): Same.
+ (xcoff64_reloc_type_lookup): Same.
+
+2002-02-20 Peter Schauer <pes@regent.e-technik.tu-muenchen.de>
+
+ * osf-core.c (osf_core_vec): OSF/1 (Digital Unix) core files are
+ little endian.
+
+2002-02-19 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * archures.c (bfd_mach_s390_esa): Rename to bfd_mach_s390_31.
+ (bfd_mach_s390_esame): Rename to bfd_mach_s390_64.
+ * bfd-in2.h: Regenerate.
+ * cpu-s390.c (arch_info_struct): Use renamed architecture defines.
+ Replace architecture name "s390" with "s390:31-bit" and "s390:esame"
+ with "s390:64-bit".
+ * elf32-s390.c (elf_howto_table): Add 32 bit pc relative relocations.
+ (elf_s390_reloc_type_lookup): Likewise.
+ (elf_s390_check_relocs): Likewise.
+ (elf_s390_gc_sweep_hook): Likewise.
+ (elf_s390_relocate_section): Likewise.
+ (elf_s390_object_p): Use renamed architecture define.
+ * elf64-s390.c (elf_s390_object_p): Use renamed architecture define.
+
+2002-02-19 Frank Ch. Eigler <fche@redhat.com>
+
+ * syms.c (stt[]): Sorted. Added .init/.fini -> "t" mapping.
+
+2002-02-19 Jakub Jelinek <jakub@redhat.com>
+
+ * elf-eh-frame.c (_bfd_elf_discard_section_eh_frame): Enable
+ absptr -> pcrel optimization for shared libs.
+ Only create minimal .eh_frame_hdr if absptr FDE encoding in shared
+ library cannot be converted to pcrel.
+ (_bfd_elf_eh_frame_section_offset): Return -2 if making absptr
+ relative.
+ * elf32-i386.c (elf_i386_relocate_section): If
+ _bfd_elf_section_offset returned -2, skip, but make sure the
+ relocation is installed.
+ * elf32-arm.h (elf32_arm_final_link_relocate): Likewise.
+ * elf32-cris.c (cris_elf_relocate_section): Likewise.
+ * elf32-hppa.c (elf32_hppa_relocate_section): Likewise.
+ * elf32-i370.c (i370_elf_relocate_section): Likewise.
+ * elf32-m68k.c (elf_m68k_relocate_section): Likewise.
+ * elf32-ppc.c (ppc_elf_relocate_section): Likewise.
+ * elf32-s390.c (elf_s390_relocate_section): Likewise.
+ * elf32-sh.c (sh_elf_relocate_section): Likewise.
+ * elf32-sparc.c (elf32_sparc_relocate_section): Likewise.
+ * elf64-ppc.c (ppc64_elf_relocate_section): Likewise.
+ * elf64-s390.c (elf_s390_relocate_section): Likewise.
+ * elf64-sh64.c (sh_elf64_relocate_section): Likewise.
+ * elf64-sparc.c (sparc64_elf_relocate_section): Likewise.
+ * elf64-x86-64.c (elf64_x86_64_relocate_section): Likewise.
+ * elf64-alpha.c (elf64_alpha_relocate_section): Handle
+ _bfd_elf_section_offset returning -2 the same way as -1.
+ * elfxx-ia64.c (elfNN_ia64_install_dyn_reloc): Likewise.
+ * elf32-mips.c (mips_elf_create_dynamic_relocation): Add FIXME
+ and BFD_ASSERT.
+ * elf64-mips.c (mips_elf64_create_dynamic_relocation): Likewise.
+
+2002-02-18 Tom Rix <trix@redhat.com>
+
+ * xcofflink.c (bfd_xcoff_link_gernate_rtinit): Add -brtl support.
+ (bfd_xcoff_size_dynamic_sections): Same.
+ * bfd-in.h (bfd_xcoff_link_generate_rtinit): Same.
+ (bfd_xcoff_size_dynamic_sections): Same.
+ * coff-rs6000.c (xcoff_generate_rtinit): Same.
+ * coff-rs646000.c (xcoff64_generate_rtinit): Same.
+ * libxcoff.h (struct xcoff_backend_data_rec): Same.
+ * xcofflink.c (xcoff_build_ldsyms, xcoff_link_add_symbols): Clean.
+ * bfd-in2.h: Regenerate.
+
+2002-02-18 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (STFD_FR0_0R1, LFD_FR0_0R1, BLR): Define.
+ (struct ppc_link_hash_table): Add sfpr.
+ (ppc64_elf_link_hash_table_create): Init it.
+ (ppc64_elf_create_dynamic_sections): Split creation of .stub and
+ .glink out to..
+ (create_linkage_sections): ..here. Make .sfpr too.
+ (ppc64_elf_check_relocs): Call create_linkage_sections, and set
+ dynobj early.
+ (MIN_SAVE_FPR, MAX_SAVE_FPR): Define.
+ (ppc64_elf_func_desc_adjust): Look for missing ._savef* and
+ ._restf* functions, and create as needed.
+ (func_desc_adjust): Only force_local for shared libs.
+
+2002-02-18 David O'Brien <obrien@FreeBSD.org>
+
+ * configure.in: Bump version number post 2.12 branching.
+ * configure: Regenerate.
+
+2002-02-17 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * mmo.c: Correct and improve comments.
+ (mmo_write_chunk): Store trailing byte in bfd buffer; don't
+ zero-pad. Use input to fill up non-empty bfd buffer.
+ (mmo_flush_chunk): New function.
+ (mmo_write_loc_chunk): Add parameter last_vmap, all callers
+ changed. Don't emit location specifier if VMA is same as
+ *LAST_VMAP after omitting leading zero contents. Call
+ mmo_flush_chunk before emitting location specifier.
+ (mmo_write_loc_chunk_list): Call mmo_flush_chunk when finished
+ with mmo_write_loc_chunk calls.
+ (mmo_internal_write_section): Call mmo_flush_chunk after
+ mmo_write_chunk.
+ (mmo_write_symbols_and_terminator): Move :Main to first position
+ in symbol array. Add faked one if it does not exist if there are
+ other symbols. Don't add it if there are no symbols at all. Move
+ out test for value of :Main from symbol loop. Rename table
+ fakemain to maintable and variable mainsym to fakemain.
+
+2002-02-15 Richard Henderson <rth@redhat.com>
+
+ * elf64-alpha.c (elf64_alpha_relocate_section) [BRSGP]: A target
+ section with no got matches any got. Simplify error generaion.
+
+2002-02-15 Alan Modra <amodra@bigpond.net.au>
+
+ Support arbitrary length fill patterns.
+ * linker.c (bfd_new_link_order): Zero all fields with bfd_zalloc.
+ (_bfd_default_link_order): Remove bfd_fill_link_order code.
+ Call default_data_link_order.
+ (default_fill_link_order): Delete.
+ (default_data_link_order): New function.
+ * elf32-mips.c (_bfd_mips_elf_final_link): Replace occurrences
+ of bfd_fill_link_order with bfd_data_link_order.
+ * elf64-alpha.c (elf64_alpha_final_link): Likewise.
+ * elf64-mips.c (mips_elf64_final_link): Likewise.
+
+ * bfd.c (bfd_scan_vma): Clamp overflows to max bfd_vma value.
+ Correct value returned in "end" for "0x<non-hex>".
+
+2002-02-14 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * cpu-arm.c (processors): Replace 'arch' field with 'mach'.
+ (scan): Test against 'mach' field in info structure.
+
+2002-02-14 Alan Modra <amodra@bigpond.net.au>
+
+ * elf.c (elf_fake_sections): Use SHT_NOBITS when SEC_NEVER_LOAD.
+
+2002-02-14 Matt Fredette <fredette@netbsd.org>
+
+ * elf32-m68k.c (elf32_m68k_print_private_bfd_data): Recognize
+ EF_M68000.
+
+2002-02-13 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * elf.c (_bfd_elf_make_section_from_shdr): Do not insist on
+ non-zero physical addresses when adjusting the LMAs of new
+ sections.
+
+2002-02-12 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * elf-hppa.h (elf_hppa_reloc_final_type): New function stripped
+ from _bfd_elf_hppa_gen_reloc_type.
+ (_bfd_elf_hppa_gen_reloc_type): Remove duplicate prototype.
+ * elf32-hppa.h (elf32_hppa_reloc_final_type): Add protptype.
+ * elf32-hppa.c: Include elf32-hppa.h before elf-hppa.h.
+ * elf64-hppa.h (elf64_hppa_reloc_final_type): Add protptype.
+
+2002-02-12 Alexandre Oliva <aoliva@redhat.com>
+
+ * elf-m10300.c (mn10300_elf_relax_section): Skip section before
+ loading its contents if there's nothing to do in it.
+
+2002-02-12 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_size_stubs): Correct test for crossing
+ 64k boundary.
+
+ * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Add dynamic
+ DT_PPC64_OPD and DT_PPC64_OPDSZ tags.
+ (ppc64_elf_finish_dynamic_sections): Set values for them.
+
+2002-02-11 Michael Snyder <msnyder@redhat.com>
+
+ * elf-bfd.h (elfcore_write_lwpstatus): Add prototype.
+ * elf.c (elfcore_grok_pstatus): Add prototype.
+ (elfcore_grok_lwpstatus): Add prototype.
+ (elfcore_write_lwpstatus): New function.
+ (elfcore_write_pstatus): Fix typo, eliminate unnecessary memcpy.
+
+2002-02-11 Alexandre Oliva <aoliva@redhat.com>
+
+ * elf32-sh.c: Added missing prototypes.
+ * elf32-sh64.c: Likewise.
+ (sh_elf_align_loads): Mark unused args as such.
+ * elf64-sh64.c: Added missing prototypes.
+ (struct elf_sh64_link_hash_entry): Fix typo.
+ (sh_elf64_relocate_section): Fix info argument passed to
+ _bfd_elf_section_offset.
+
+2002-02-11 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: "make dep-am".
+ * Makefile.in: Regenerate.
+ * aclocal.m4: Regenerate.
+ * config.in: Regenerate.
+ * configure: Regenerate.
+
+2002-02-10 Daniel Jacobowitz <drow@mvista.com>
+
+ * coff-rs6000.c (xcoff_generate_rtinit): Silence uninitialized
+ variable warnings.
+ * elf32-sh.c (sh_elf_relax_section): Silence signed/unsigned
+ comparison warning.
+ * trad-core.c (trad_unix_core_file_p): Silence pointer/integer
+ cast warnings for the common case.
+
+2002-02-10 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * config.bfd (sh-*-linux*, sh-*-elf* | sh-*-rtemself*): Add sh64
+ vectors.
+ (sh-*-netbsdelf*): New, to trump sh*-*-netbsdelf* and add sh64
+ vectors.
+
+2002-02-09 Richard Henderson <rth@redhat.com>
+
+ * elf64-alpha.c (elf64_alpha_howto): Add R_ALPHA_BRSGP.
+ (elf64_alpha_reloc_map, elf64_alpha_check_relocs): Likewise.
+ (elf64_alpha_relocate_section): Likewise.
+ * reloc.c (BFD_RELOC_ALPHA_BRSGP): New.
+ * bfd-in2.h, libbfd.h: Rebuild.
+
+2002-02-09 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * elf64-mmix.c (_bfd_mmix_finalize_linker_allocated_gregs): Check
+ that base-plus-offset reloc accounting is consistent.
+ (mmix_elf_relax_section): Keep base-plus-offset reloc accounting
+ up to date for undefined symbols.
+
+2002-02-08 Eric Christopher <echristo@redhat.com>
+
+ From Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
+
+ * elf32-mips.c (_bfd_mips_elf_fake_sections): Don't create .rela
+ sections for the O32 ABI.
+
+2002-02-08 Chris Demetriou <cgd@broadcom.com>
+
+ * elf32-arm.h: Fix formatting of _("...").
+ * elf32-d10v.c: Likewise.
+ * elf32-m68k.c: Likewise.
+ * elf32-mips.c: Likewise.
+
+2002-02-08 Ivan Guzvinec <ivang@opencores.org>
+
+ * coff-or32.c: Fix compile time warning messages.
+
+2002-02-08 Alexandre Oliva <aoliva@redhat.com>
+
+ Contribute sh64-elf.
+ 2002-01-23 Alexandre Oliva <aoliva@redhat.com>
+ * reloc.c (R_SH_GOTPLT32, R_SH_GOT_LOW16, R_SH_GOT_MEDLOW16,
+ R_SH_GOT_MEDHI16, R_SH_GOT_HI16, R_SH_GOTPLT_LOW16,
+ R_SH_GOTPLT_MEDLOW16, R_SH_GOTPLT_MEDHI16, R_SH_GOTPLT_HI16,
+ R_SH_PLT_LOW16, R_SH_PLT_MEDLOW16, R_SH_PLT_MEDHI16,
+ R_SH_PLT_HI16, R_SH_GOTOFF_LOW16, R_SH_GOTOFF_MEDLOW16,
+ R_SH_GOTOFF_MEDHI16, R_SH_GOTOFF_HI16, R_SH_GOTPC_LOW16,
+ R_SH_GOTPC_MEDLOW16, R_SH_GOTPC_MEDHI16, R_SH_GOTPC_HI16,
+ R_SH_GOT10BY4, R_SH_GOTPLT10BY4, R_SH_GOT10BY8, R_SH_GOTPLT10BY8,
+ R_SH_COPY64, R_SH_GLOB_DAT64, R_SH_JMP_SLOT64, R_SH_RELATIVE64):
+ New relocs.
+ * libbfd.h, bfd-in2.h: Rebuilt.
+ * elf32-sh.c (sh_elf_howto_table): Define new relocs.
+ (sh_reloc_map): Map them.
+ (PLT_ENTRY_SIZE, elf_sh_plt0_entry_be, elf_sh_plt0_entry_le,
+ elf_sh_plt_entry_be, elf_sh_plt_entry_le, elf_sh_pic_plt_entry_be,
+ elf_sh_pic_plt_entry_le, elf_sh_plt0_entry, elf_sh_plt_entry,
+ elf_sh_pic_plt_entry, elf_sh_sizeof_plt, elf_sh_plt_plt0_offset,
+ elf_sh_plt0_gotplt_offset, elf_sh_plt_temp_offset,
+ elf_sh_plt_symbol_offset, elf_sh_plt_reloc_offset,
+ movi_shori_putval) [INCLUDE_SHMEDIA]: New.
+ (elf_sh_link_hash_entry) [INCLUDE_SHMEDIA]: Add
+ datalabel_got_offset.
+ (sh_elf_link_hash_newfunc): Initialize it.
+ (sh_elf_relocate_section): Augment the scope of
+ seen_stt_datalabel. Introduce GOTPLT support. Extend GOTPC, PLT,
+ GOT and GOTOFF handling to new SHmedia relocation types. Support
+ GOT_BIAS.
+ (sh_elf_check_relocs): Likewise.
+ (sh_elf_finish_dynamic_symbol) [TARGET_SHMEDIA]: Set up values in
+ PLT entries using movi_shori_putval. Support GOT_BIAS.
+ (sh_elf_finish_dynamic_sections): Likewise.
+ * elf32-sh64.c (shmedia_prepare_reloc): Do not add addend to
+ relocation, it's now done by the caller.
+ (GOT_BIAS): New.
+ * elf64-sh64.c (GOT_BIAS, PLT_ENTRY_SIZE, elf_sh64_sizeof_plt,
+ elf_sh64_plt_plt0_offset, elf_sh64_plt0_gotplt_offset,
+ elf_sh64_plt_temp_offset, elf_sh64_plt_symbol_offset,
+ elf_sh64_plt_reloc_offset, ELF_DYNAMIC_INTERPRETER,
+ elf_sh64_pcrel_relocs_copied, elf_sh64_link_hash_entry,
+ elf_sh64_link_hash_table, sh64_elf64_link_hash_traverse,
+ sh64_elf64_hash_table): New.
+ (sh_elf64_howto_table): Introduce new relocs.
+ (sh_elf64_info_to_howto): Accept new PIC relocs.
+ (sh_elf64_relocate_section): Augment the scope of
+ seen_stt_datalabel. Support new PIC relocs.
+ (sh_elf64_check_relocs): Support new PIC relocs.
+ (elf_sh64_plt0_entry_be, elf_sh64_plt0_entry_le,
+ elf_sh64_plt_entry_be, elf_sh64_plt_entry_le,
+ elf_sh64_pic_plt_entry_be, elf_sh64_pic_plt_entry_le,
+ elf_sh64_plt0_entry, elf_sh64_plt_entry, elf_sh64_pic_plt_entry,
+ sh64_elf64_link_hash_newfunc, sh64_elf64_link_hash_table_create,
+ movi_shori_putval, movi_3shori_putval,
+ sh64_elf64_create_dynamic_sections,
+ sh64_elf64_adjust_dynamic_symbol, sh64_elf64_discard_copies,
+ sh64_elf64_size_dynamic_sections,
+ sh64_elf64_finish_dynamic_symbol,
+ sh64_elf64_finish_dynamic_sections): New.
+ (elf_backend_create_dynamic-sections,
+ bfd_elf64_bfd_link_hash_table_create,
+ elf_backend_adjust_dynamic_symbol,
+ elf_backend_size_dynamic_sections,
+ elf_backend_finish_dynamic_symbol,
+ elf_backend_finish_dynamic_sections, elf_backend_want_got_plt,
+ elf_backend_plt_readonly, elf_backend_want_plt_sym,
+ elf_backend_got_header_size, elf_backend_plt_header_size):
+ Define.
+ 2001-05-16 Alexandre Oliva <aoliva@redhat.com>
+ * elf32-sh.c: Renumbered and renamed some SH5 relocations to
+ match official numbers and names; moved unmaching ones to the
+ range 0xf2-0xff.
+ * elf32-sh64.c, elf64-sh64.c: Likewise.
+ 2001-03-12 DJ Delorie <dj@redhat.com>
+ * elf32-sh.c (sh_elf_relax_section): Don't relax SHmedia
+ sections.
+ 2001-03-12 DJ Delorie <dj@redhat.com>
+ * elf32-sh64.c (shmedia_prepare_reloc): Validate relocs that must
+ be aligned.
+ * elf64-sh64.c (sh_elf64_relocate_section): Ditto.
+ 2001-01-14 Hans-Peter Nilsson <hpn@cygnus.com>
+ * elf32-sh64.c (bfd_elf32_bfd_copy_private_section_data): Define.
+ (sh64_elf_fake_sections): Set type to SHT_SH5_CR_SORTED for a
+ .cranges section with SEC_SORT_ENTRIES set.
+ (sh64_backend_section_from_shdr): Set SEC_SORT_ENTRIES on an
+ incoming sorted .cranges section.
+ (sh64_bfd_elf_copy_private_section_data): New.
+ (sh64_elf_final_write_processing): Only sort .cranges and modify
+ start address if called by linker.
+ 2001-01-08 Ben Elliston <bje@redhat.com>
+ * elf32-sh64.c (sh64_elf_final_write_processing): Activate
+ Hans-Peter Nilsson's set bit 0 patch from 2001-01-06.
+ * elf64-sh64.c (sh64_elf64_final_write_processing): Ditto.
+ 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
+ * elf64-sh64.c (sh_elf64_howto_table): No open brace at start of
+ line. Add comments before all entries.
+ <R_SH_PT_16, R_SH_SHMEDIA_CODE>: Correct and clarify describing
+ comment.
+ (sh_elf64_reloc): Correct head comment.
+ (sh_elf64_relocate_section): Correct spacing.
+ <relocating for a local symbol>: Do not honour STO_SH5_ISA32;
+ instead call reloc_dangerous callback.
+ <case R_SH_SHMEDIA_CODE>: New case.
+ (sh_elf64_gc_mark_hook): Correct spacing.
+ (sh_elf64_check_relocs): Ditto.
+ * elf32-sh64.c (shmedia_prepare_reloc) <case R_SH_SHMEDIA_CODE>:
+ New case.
+ * elf32-sh.c: Correct #endif comments for #ifndef-wrapped
+ functions.
+ (sh_elf_howto_table) <R_SH_PT_16, R_SH_SHMEDIA_CODE>: Correct,
+ clarify describing comment. Add comments before all entries.
+ (sh_elf_relocate_section) <relocating for a local symbol>: Do not
+ honour STO_SH5_ISA32; instead call reloc_dangerous callback.
+ 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
+ Sort .cranges section in final link. Prepare to set bit 0 on
+ entry address.
+ * elf32-sh64.c (struct sh64_find_section_vma_data): New.
+ (sh64_elf_link_output_symbol_hook): Fix typo in prototype.
+ (sh64_elf_set_mach_from_flags): Set SEC_DEBUGGING on incoming
+ .cranges section.
+ (sh64_backend_section_from_shdr): New, to recognize
+ SHT_SH5_CR_SORTED on incoming .cranges section.
+ (elf_backend_section_from_shdr): Define.
+ (sh64_elf_final_write_processing): Sort outgoing .cranges
+ section. (New, temporarily disabled:) Set bit 0 on entry address
+ according to ISA type.
+ (sh64_find_section_for_address): New.
+ (crange_qsort_cmpb, crange_qsort_cmpl, crange_bsearch_cmpb,
+ crange_bsearch_cmpl): Move here from opcodes/sh64-dis.c.
+ (sh64_address_in_cranges): Move here from opcodes/sh64-dis.c. Use
+ bfd_malloc, not xmalloc.
+ (sh64_get_contents_type): Move here from opcodes/sh64-dis.c. Make
+ global.
+ * elf32-sh64.c (sh64_elf64_final_write_processing): New, (but
+ temporarily disabled) setting bit 0 on entry address.
+ (elf_backend_final_write_processing): Define.
+ 2001-01-05 Hans-Peter Nilsson <hpn@cygnus.com>
+ * elf32-sh.c (sh_elf_howto_table) <R_SH_PT_16>: Adjust fields to
+ be a proper relocation for PTA and PTB rather than a marker.
+ <R_SH_IMMU5, R_SH_IMMS6, R_SH_IMMU6, R_SH_IMMS10, R_SH_IMMS10BY2,
+ R_SH_IMMS10BY4, R_SH_IMMS10BY8, R_SH_IMMS16, R_SH_IMMU16,
+ R_SH_IMM_LOW16, R_SH_IMM_LOW16_PCREL, R_SH_IMM_MEDLOW16,
+ R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16, R_SH_IMM_MEDHI16_PCREL,
+ R_SH_IMM_HI16, R_SH_IMM_HI16_PCREL, R_SH_64, R_SH_64_PCREL>:
+ Zero src_mask.
+ * elf64-sh64.c: Ditto.
+ (sh_elf64_relocate_section) <case R_SH_PT_16>: New case.
+ * elf32-sh64.c: Include opcodes/sh64-opc.h
+ (shmedia_prepare_reloc): Take a bfd_link_info pointer as first
+ argument. Drop const qualifiers from "bfd *" and "bfd_byte *"
+ parameters. No unused parameters. Caller changed.
+ <case R_SH_PT_16>: New case.
+ * Makefile.am (elf32-sh64.lo): Add dependency on sh64-opc.h.
+ * Makefile.in: Regenerate.
+ 2000-12-30 Hans-Peter Nilsson <hpn@cygnus.com>
+ * elf64-sh64.c (sh64_elf64_fake_sections): Set SHF_SH5_ISA32 for
+ all code sections.
+ (sh_elf64_set_mach_from_flags): Change from EF_SH64 to EF_SH5.
+ (sh64_elf_merge_private_data): Ditto.
+ * elf32-sh64.c (sh64_elf_fake_sections): Use sh64_elf_section_data
+ to access stored section flags.
+ (sh64_elf_final_write_processing): Return immediately unless
+ called by linker. Use sh64_elf_section_data (cranges) to get size
+ of linker-generated cranges entries.
+ (sh64_elf_copy_private_data): Add missing "return true".
+ (sh64_elf_set_mach_from_flags): Change from EF_SH64 to EF_SH5.
+ (sh_elf64_merge_private_data): Ditto.
+ 2000-12-19 Hans-Peter Nilsson <hpn@cygnus.com>
+ * elf64-sh64.c (sh64_elf64_fake_sections): New, copy of
+ elf64-sh64.c:sh64_elf_fake_sections.
+ (elf_backend_fake_sections): Define as sh64_elf64_fake_sections.
+ 2000-12-18 Hans-Peter Nilsson <hpn@cygnus.com>
+ * elf32-sh64.c (sh64_elf_copy_private_data_internal): Delete.
+ (sh64_elf_final_write_processing): New.
+ (elf_backend_final_write_processing): Define.
+ (sh64_elf_fake_sections): Get header flags from tdata field.
+ (sh64_elf_copy_private_data): Do not call
+ sh64_elf_copy_private_data_internal, just copy e_flags field.
+ (sh64_elf_merge_private_data): Do not call
+ sh64_elf_copy_private_data_internal.
+ 2000-12-12 Hans-Peter Nilsson <hpn@cygnus.com>
+ Remove EF_SH64_ABI64, let ELF size make difference.
+ Remove SH64-specific BFD section flag.
+ * elf32-sh64.c (sh64_elf_fake_sections): Recognize section as
+ containing SHmedia through elf_section_data (asect)->tdata
+ non-zero, not using a BFD section flag.
+ (sh64_elf_set_mach_from_flags): Don't recognize EF_SH64_ABI64.
+ (sh64_elf_merge_private_data): Similar.
+ (elf_backend_section_flags): Don't define.
+ (sh64_elf_backend_section_flags): Delete.
+ * elf64-sh64.c (sh_elf64_set_mach_from_flags): Recognize EF_SH64,
+ not EF_SH64_ABI64.
+ (sh_elf64_merge_private_data): Similar.
+ * section.c (Section flags definitions): Don't define
+ SEC_SH_ISA_SHMEDIA.
+ (bfd-in2.h): Regenerate.
+ 2000-12-09 Hans-Peter Nilsson <hpn@cygnus.com>
+ Make DataLabel references work with partial linking.
+ * elf32-sh64.c: Fix formatting.
+ (sh64_elf_link_output_symbol_hook): New.
+ (elf_backend_link_output_symbol_hook): Define to
+ sh64_elf_link_output_symbol_hook.
+ (sh64_elf_add_symbol_hook): Make DataLabel symbol just global
+ undefined if partial linking. Adjust sanity check.
+ * elf64-sh64.c (sh64_elf64_link_output_symbol_hook): New.
+ (elf_backend_link_output_symbol_hook): Define to
+ sh64_elf64_link_output_symbol_hook.
+ (sh64_elf64_add_symbol_hook): Make DataLabel symbol just global
+ undefined if partial linking. Adjust sanity check.
+ 2000-12-07 Hans-Peter Nilsson <hpn@cygnus.com>
+ Implement semantics for inter-file DataLabel references.
+ * elf64-sh64.c (DATALABEL_SUFFIX): Define.
+ (sh64_elf64_add_symbol_hook): New.
+ (sh_elf64_relocate_section): If passing an indirect symbol with
+ st_type STT_DATALABEL on the way to a symbol with st_other
+ STO_SH5_ISA32, do not bitor 1 to the relocation.
+ (elf_backend_add_symbol_hook): Define to
+ sh64_elf64_add_symbol_hook.
+ * elf64-sh32.c: Tweak comments.
+ (DATALABEL_SUFFIX): Define.
+ (sh64_elf_add_symbol_hook): New.
+ (elf_backend_add_symbol_hook): Define to sh64_elf_add_symbol_hook.
+ * elf32-sh.c (sh_elf_relocate_section): If passing an indirect
+ symbol with st_type STT_DATALABEL on the way to a symbol with
+ st_other STO_SH5_ISA32, do not bitor 1 to the relocation.
+ 2000-12-05 Hans-Peter Nilsson <hpn@cygnus.com>
+ Pass through STT_DATALABEL.
+ * elf32-sh64.c (sh64_elf_get_symbol_type): New.
+ (elf_backend_get_symbol_type): Define.
+ * elf64-sh64.c (sh64_elf64_get_symbol_type): New.
+ (elf_backend_get_symbol_type): Define.
+ 2000-11-30 Hans-Peter Nilsson <hpn@cygnus.com>
+ * elf32-sh64.c: Tweak comments.
+ (sh64_elf_copy_private_data_internal): Add prototype.
+ (bfd_elf32_bfd_set_private_flags): Define.
+ (sh64_elf_copy_private_data_internal): Compare machine name, not
+ textual BFD target name, to check whether to copy section flag
+ SHF_SH5_ISA32.
+ (sh64_elf_merge_private_data): Validize bfd_get_arch_size.
+ Tweak section-contents-type-mismatch message.
+ (shmedia_prepare_reloc): Add ATTRIBUTE_UNUSED markers.
+ Validize reloc-types.
+ * elf64-sh64.c: New file.
+ * targets.c (bfd_elf64_sh64_vec, bfd_elf64_sh64l_vec): Declare.
+ * Makefile.am (BFD64_BACKENDS): Add elf64-sh64.lo.
+ (BFD64_BACKENDS_CFILES): Add elf64-sh64.c.
+ Regenerate dependencies.
+ * Makefile.in: Regenerate.
+ * config.bfd (sh64-*-elf*): Add bfd_elf64_sh64_vec and
+ bfd_elf64_sh64l_vec.
+ * configure.in: Handle bfd_elf64_sh64_vec and
+ bfd_elf64_sh64l_vec.
+ * configure: Regenerate.
+ * po/POTFILES.in: Regenerate.
+ * po/bfd.pot: Regenerate.
+ 2000-11-29 Hans-Peter Nilsson <hpn@cygnus.com>
+ * elf32-sh64.c (sh64_elf_set_mach_from_flags): Do not recognize
+ anything else but EF_SH64 and EF_SH64_ABI64.
+ (sh64_elf_merge_private_data): Emit error for anything else but
+ EF_SH64 and EF_SH64_ABI64.
+ * config.bfd: Remove bfd_elf32_shblin_vec and bfd_elf32_shlin_vec
+ from targ_selvecs.
+ * configure.in: Add cofflink.lo to bfd_elf32_sh64_vec and
+ bfd_elf32_sh64l_vec as a temporary measure.
+ * configure: Regenerate.
+ 2000-11-27 Hans-Peter Nilsson <hpn@cygnus.com>
+ * cpu-sh.c (arch_info_struct): Include sh5 item
+ unconditionalized.
+ * config.bfd (sh64-*-elf*): Do not set targ_cflags.
+ Add targ_selvecs bfd_elf32_sh_vec, bfd_elf32_shl_vec,
+ bfd_elf32_shblin_vec and bfd_elf32_shlin_vec.
+ * elf32-sh64.c: Tweak comments.
+ (sh64_elf_set_mach_from_flags): Recognize all machine flags that
+ are proper subsets of SH64 as bfd_mach_sh5. Add EF_SH64_ABI64.
+ (sh64_elf_copy_private_data_internal): Wrap long line.
+ (sh64_elf_merge_private_data): Rewrite to allow objects from
+ SH64 subsets to be linked together.
+ (INCLUDE_SHMEDIA): Define.
+ * elf32-sh.c (sh_elf_relocate_section) <local symbol>:
+ Parenthesize plus-expression inside or-expression.
+ <global symbol>: Ditto.
+ (sh_elf_set_mach_from_flags): Remove code refusing
+ deleted EF_SH64_32BIT_ABI flag.
+ 2000-11-26 Hans-Peter Nilsson <hpn@cygnus.com>
+ * elf32-sh.c (sh_elf_howto_table) <R_SH_IMM_LOW16_PCREL,
+ R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16_PCREL,
+ R_SH_IMM_HI16_PCREL, R_SH_64_PCREL>: Set pcrel_offset to true.
+ (sh_elf_relocate_section) <local symbol>: Or 1 in
+ calculation of relocation if sym->st_other & STO_SH5_ISA32.
+ <global symbol>: Ditto if h->other & STO_SH5_ISA32.
+ * elf32-sh64.c (shmedia_prepare_reloc): Add rel->r_addend to
+ relocation.
+ 2000-11-24 Hans-Peter Nilsson <hpn@cygnus.com>
+ * Makefile.am (BFD32_BACKENDS): Add elf32-sh64.lo.
+ (BFD32_BACKENDS_CFILES): Add elf32-sh64.c.
+ Regenerate dependencies.
+ * Makefile.in: Regenerate.
+ * archures.c: Add bfd_mach_sh5.
+ * config.bfd: Map targ_cpu sh* to bfd_sh_arch.
+ Handle sh64-*-elf*. Set targ_cflags to -DINCLUDE_SHMEDIA.
+ * configure.in: Handle bfd_elf32_sh64_vec and bfd_elf32_sh64l_vec.
+ * configure: Regenerate.
+ * reloc.c (BFD_RELOC_SH_SHMEDIA_CODE, BFD_RELOC_SH_IMMU5,
+ BFD_RELOC_SH_IMMS6, BFD_RELOC_SH_IMMS6BY32, BFD_RELOC_SH_IMMU6,
+ BFD_RELOC_SH_IMMS10, BFD_RELOC_SH_IMMS10BY2,
+ BFD_RELOC_SH_IMMS10BY4, BFD_RELOC_SH_IMMS10BY8,
+ BFD_RELOC_SH_IMMS16, BFD_RELOC_SH_IMMU16, BFD_RELOC_SH_IMM_LOW16,
+ BFD_RELOC_SH_IMM_LOW16_PCREL, BFD_RELOC_SH_IMM_MEDLOW16,
+ BFD_RELOC_SH_IMM_MEDLOW16_PCREL, BFD_RELOC_SH_IMM_MEDHI16,
+ BFD_RELOC_SH_IMM_MEDHI16_PCREL, BFD_RELOC_SH_IMM_HI16,
+ BFD_RELOC_SH_IMM_HI16_PCREL, BFD_RELOC_SH_PT_16): New relocations.
+ * cpu-sh.c [INCLUDE_SHMEDIA] (arch_info_struct): Define and link
+ in item for SH5.
+ * elf32-sh.c [INCLUDE_SHMEDIA] (sh_elf_howto_table): Add howto items
+ for SHmedia relocs.
+ [INCLUDE_SHMEDIA] (sh_rel): Add mappings for SHmedia relocs.
+ [INCLUDE_SHMEDIA] (sh_elf_relocate_section) [default]: Call
+ shmedia_prepare_reloc, goto final_link_relocate if it returns
+ non-zero, else fail as before.
+ (sh_elf_set_mach_from_flags): Provide function only if not defined
+ as macro. Do not recognize objects with EF_SH64_32BIT_ABI set.
+ (sh_elf_set_private_flags): Provide function only if not defined
+ as a macro.
+ (sh_elf_copy_private_data): Similar.
+ (sh_elf_merge_private_data): Similar.
+ * section.c (SEC_SH_ISA_SHMEDIA): New.
+ * targets.c (bfd_elf32_sh64_vec, bfd_elf32_sh64l_vec): Declare.
+ * elf32-sh64.c: New file.
+ * libbfd.h: Regenerate.
+ * bfd-in2.h: Regenerate.
+ * po/POTFILES.in: Regenerate.
+ * po/bfd.pot: Regenerate.
+ * bfd-in2.h: Regenerate.
+ * libbfd.h: Regenerate.
+
+2002-02-07 Daniel Jacobowitz <drow@mvista.com>
+
+ * bfd-in.h: Update <stdbool.h> check to only see if <stdbool.h> has
+ been included, not drag it in.
+ * bfd-in2.h: Regenerate.
+
+2002-02-06 H.J. Lu (hjl@gnu.org)
+
+ * elf32-mips.c (_bfd_mips_elf_merge_private_bfd_data): Update
+ the mach and ISA fields if necessary.
+
+2002-02-06 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * coffcode.h (coff_set_arch_mach_hook): Select the highest known
+ ARM architecture when an F_ARM_5 flag is detected, since we cannot
+ be sure exactly which architecture this represents.
+
+2002-02-05 Nick Clifton <nickc@redhat.com>
+
+ * po/tr.po: Updated translation.
+
+2002-02-05 Alan Modra <amodra@bigpond.net.au>
+
+ From Jimi X <jimix@watson.ibm.com>
+ * archures (bfd_mach_ppc64): Define.
+ (bfd_powerpc_arch): Rename to bfd_powerpc_archs.
+ (bfd_powerpc_arch): Define.
+ * bfd-in2.h: Regenerate.
+ * cpu-powerpc.c (arch_info_struct): Rename to bfd_powerpc_archs.
+ (bfd_powerpc_arch): Move to tail of bfd_powerpc_archs.
+ (bfd_powerpc_archs): Add default powerpc64 arch.
+
+2002-02-05 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_size_dynamic_sections): Check for relocs
+ against section syms in readonly sections. Don't do the global
+ sym check if we find one.
+ * elf64-s390.c (elf_s390_size_dynamic_sections): Likewise.
+ * elf32-hppa.c (elf32_hppa_size_dynamic_sections): Likewise.
+ * elf32-i386.c (elf_i386_size_dynamic_sections): Likewise.
+ * elf32-s390.c (elf_s390_size_dynamic_sections): Likewise.
+ (elf_s390_grok_prstatus): Add missing prototype.
+
+2002-02-04 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * elf64-mmix.c (mmix_dump_bpo_gregs): New function.
+ (mmix_elf_check_common_relocs) <case R_MMIX_BASE_PLUS_OFFSET>:
+ Call bfd_get_section_by_name only once. Initialize
+ bpodata->n_bpo_relocs_this_section.
+ (_bfd_mmix_prepare_linker_allocated_gregs): Remove comment
+ referring to DSOs.
+ (bpo_reloc_request_sort_fn): Don't use difference of values as
+ return-value.
+
+2002-02-02 David O'Brien <obrien@FreeBSD>
+
+ * configure.in: Tweak the FreeBSD 4.x recognition more. Only treat
+ version 4.5 and later the same as 5-CURRENT.
+ * configure: Re-generate.
+
+2002-02-02 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * config.bfd (hppa*-*-netbsd*): New target.
+
+2002-01-31 Philipp Thomas <pthomas@suse.de>
+
+ * coff-arm.c (coff_arm_merge_private_bfd_data): Move ERROR
+ to front of message. Unify messages with elf32-arm.h. Use
+ commas where neccessary.
+ * elf32-arm.h (elf32_arm_merge_private_bfd_data): Use all upcase
+ ERROR in messages. Unify messages with coff-arm.c. Correct
+ VFP/FPA error message.
+ (elf32_arm_print_private_bfd_data): Don't mark APCS-26 and
+ APCS-32 for translation.
+
+2002-02-01 Hans-Peter Nilsson <hp@bitrange.com>
+
+ Perform on-demand global register allocation from
+ R_MMIX_BASE_PLUS_OFFSET relocs.
+ * elf64-mmix.c (struct bpo_reloc_section_info, struct
+ bpo_reloc_request, struct bpo_greg_section_info): New.
+ (mmix_elf_check_common_relocs, mmix_elf_gc_sweep_hook,
+ bpo_reloc_request_sort_fn, mmix_elf_relax_section,
+ _bfd_mmix_check_all_relocs,
+ _bfd_mmix_prepare_linker_allocated_gregs,
+ _bfd_mmix_finalize_linker_allocated_gregs): New functions.
+ (elf_mmix_howto_table): Correct src_mask for most relocs.
+ (mmix_elf_perform_relocation) <case R_MMIX_BASE_PLUS_OFFSET>: New
+ case.
+ (mmix_final_link_relocate) <case R_MMIX_BASE_PLUS_OFFSET>: New
+ case. Fix typo in comment. New label do_mmix_reloc.
+ (mmix_elf_check_relocs): Abuse bfd_link_info member base_file to
+ store first object file with a base-plus-offset reloc. Call
+ mmix_elf_check_common_relocs for the part common with mmo.
+ (mmix_elf_final_link): Write out linker-allocated register
+ contents section.
+ (elf_backend_gc_sweep_hook): Define.
+ (bfd_elf64_bfd_relax_section): Define.
+
+ * mmo.c: Don't include <ctype.h>
+ (mmo_init): Correct init-once logic.
+
+2002-02-01 Tom Rix <trix@redhat.com>
+
+ * config.bfd: Conditionally support <aiaff> for pre AIX 4.3.
+
+2002-02-01 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am"
+ * Makefile.in: Regenerate.
+
+2002-01-31 David O'Brien <obrien@FreeBSD>
+
+ * configure.in: Recognize the differences in core files from FreeBSD
+ 4.{0,1} and later versions of 4.x. This treats 4.2+ the same as
+ 5-CURRENT.
+ * configure: Regenerate.
+
+2002-01-31 Ivan Guzvinec <ivang@opencores.org>
+
+ * coff-or32.c: New file.
+ * cpu-or32.c: New file.
+ * elf32-or32.c: New file.
+ * archures.c: Add support for or32.
+ * targets.c: Add support for or32.
+ * bfd-in2.h: Regenerate.
+ * coffcode.h (coff_set_arch_mach_hook, coff_set_flags,
+ coff_write_object_contents): Add support for or32.
+ * config.bfd: Add target.
+ * configure.in: Add support for or32.
+ * configure: Regenerate.
+ * Makefile.am: Add support for or32.
+ * Makefile.in: Regenerate.
+ * po/SRC-POTFILES.in: Add or32 files.
+ * po/bfd.pot: Regenerate.
+
+2002-01-31 Nick Clifton <nickc@cambridge.redhat.com>
+ Don Lindsay <lindsayd@cisco.com>
+
+ * elf32-mips.c (mips_elf_calculate_relocation): Replace 'return
+ false' with a return of a bfd_reloc_ error code.
+
+2002-01-31 Hans-Peter Nilsson <hp@axis.com>
+
+ * elf32-cris.c (elf_cris_discard_excess_program_dynamics): Don't
+ unexport unreferenced symbols when --export-dynamic. Call
+ _bfd_elf_strtab_delref when unexporting.
+
+2002-01-30 Daniel Jacobowitz <drow@mvista.com>
+
+ * bfd-in.h: Include <stdbool.h> if it is available.
+ * bfd-in2.h: Regenerated.
+
+2002-01-31 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (func_desc_adjust): STV_PROTECTED functions should
+ not go via the plt.
+
+2002-01-30 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * archures.c: Tidy up formatting of embedded comments.
+ * bfd.c: Tidy up formatting of embedded comments.
+ * bfd-in.h: Fix formatting of comments.
+ * reloc.c: Tidy up formatting of ordinary & embedded comments.
+ * section.c: Tidy up formatting of embedded comments.
+ * syms.c: Tidy up formatting of embedded comments.
+ * targets.c: Tidy up formatting of embedded comments.
+
+ * bfd-in2.h: Regenerate.
+
+2002-01-30 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * vms-tir.c (cmd_name): New function.
+ (tir_cmd_name): New function.
+ (etir_sta, etir_sto, etir_opr, etir_stc): Use cmd_name().
+ (tir_opr, tir_ctl, tir_cmd): use tir_cmd_name().
+ Fix formatting.
+
+ * peXXigen.c (pe_print_idata): Rearrange message to aid in
+ translation.
+ (pe_print_pdata): Rearrange message to aid in translation.
+
+ * libbfd.c (warn_deprecated): Rearrange error message to aid in
+ translation.
+
+ * ihex.c (ihex_write_object_contents): Fix spelling typo.
+
+ * ieee.c (ieee_slurp_external_symbols): Remove spurious space.
+
+ * elf64-sparc.c (sparc64_elf_add_symbol_hook): Rearrange error
+ message to aid in translation.
+
+ * elf64-mmix.c (mmix_final_link_relocate): Rearrange error message
+ to aid in translation.
+
+ * elf32-arm.h (elf32_arm_merge_private_bfd_data): Fix typo.
+
+2002-01-30 Philipp Thomas <pthomas@suse.de>
+
+ * coff-arm.c, elf32-elf.h: Unify messages.
+
+2002-01-30 Nick Clifton <nickc@redhat.com>
+
+ * po/sv.po: Updated translation.
+
+2002-01-30 Philipp Thomas <pthomas@suse.de>
+
+ * dwarf2.c (read_abbrev): Use full section name in error message.
+ (decode_line_info): Likewise.
+
+ * elf.c (_bfd_elf_symbol_from_bfd_symbol): Don't translate debugging
+ message.
+
+2002-01-30 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (func_desc_adjust): Only provide missing function
+ descriptor symbols for undefined function code syms. Clear
+ ELF_LINK_NON_ELF so that they can stay weak.
+
+2002-01-29 Chris Demetriou <cgd@broadcom.com>
+ Mitch Lichtenberg <mpl@broadcom.com>
+
+ * bfd-in.h (bfd_mips_elf32_create_embedded_relocs): New prototype.
+ * elf32-mips.c (bfd_mips_elf32_create_embedded_relocs): New function
+ to handle 32-bit ELF embedded reloc (ld --embedded-relocs)
+ generation.
+ * bfd-in2.h: Regenerate.
+
+2002-01-29 Chris Demetriou <cgd@broadcom.com>
+
+ * elf32-mips.c: Add additional comments about HI16 relocation
+ processing.
+ (_bfd_mips_elf_hi16_reloc): Don't subtract address here for
+ pc-relative relocations. (Reverts change made on 2001-10-31.)
+ (_bfd_mips_elf_lo16_reloc): Subtract address of LO16 part here
+ for pc-relative relocations.
+ (mips_elf_calculate_relocation): Add a comment about a kludge
+ in the R_MIPS_GNU_REL_HI16 handling.
+ (_bfd_mips_elf_relocate_section): Implement that kludge;
+ adjust pc-relative HI16 relocation for difference in HI16 and
+ LO16 addresses, since it can't easily be done in
+ mips_elf_calculate_relocation.
+
+2002-01-29 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * elf32-i386 (elf_i386_adjust_dynamic_symbol): Do not replace PLT32
+ relocations with PC32 relocations for undefined or weak symbols.
+ * elf32-s390 (elf_i386_adjust_dynamic_symbol): Likewise.
+ * elf64-s390x (elf_i386_adjust_dynamic_symbol): Likewise.
+
+2002-01-28 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * elfcore.h (elf_core_file_p): Improve comment for last change.
+
+2002-01-27 Daniel Jacobowitz <drow@mvista.com>
+
+ * configure: Regenerated.
+
+2002-01-27 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * elfcore.h (elf_core_file_p): Set the machine architecture
+ before processing the program headers.
+
+2002-01-26 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * configure.in <64-bit configuration>: If using gcc, check and
+ emit error for egcs-1.1.2.
+ * configure: Regenerate.
+
+2002-01-26 Egor Duda <deo@logos-m.ru>
+
+ * elf.c (elfcore_grok_win32pstatus): Copy only as much information
+ as possible to avoid stack corruption.
+
+2002-01-26 Richard Henderson <rth@redhat.com>
+
+ * elf64-alpha.c (elf64_alpha_check_relocs): Don't set reltext
+ for non-allocated sections.
+
+2002-01-25 Mark Kettenis <kettenis@gnu.org>
+
+ * elf.c (elfcore_write_prstatus): Make sure we pass the address of
+ prstat.pr_reg even if it is a struct.
+
+2002-01-25 Steve Ellcey <sje@cup.hp.com>
+
+ * elfxx-ia64.c: Reset AIX vector function overrides for HP-UX.
+
+2002-01-25 Philipp Thomas <pthomas@suse.de>
+
+ * coffgen.c (coff_print_symbol): Don't mark info message
+ for translation.
+
+2002-01-25 Nick Clifton <nickc@redhat.com>
+
+ * po/fr.po: Updated translation.
+ * po/es.po: Updated translation.
+
+2002-01-25 Philipp Thomas <pthomas@suse.de>
+
+ * coff-alpha.c (alpha_relocate_section): Unify warning message
+ for GP relative relocations without GP defined.
+ * coff-mips.c (mips_relocate_section): Likewise.
+
+2002-01-25 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-eh-frame.c (_bfd_elf_eh_frame_section_offset): Avoid
+ unsigned overflow when new_offset < old_offset.
+
+2002-01-24 Philipp Thomas <pthomas@suse.de>
+
+ * bfd.c (_bfd_abort): Fix typo.
+
+2002-01-23 Richard Henderson <rth@redhat.com>
+
+ * elf64-alpha.c (elf64_alpha_adjust_dynamic_symbol): Don't suppress
+ plt entries for undefweak symbols.
+
+2002-01-23 Steve Ellcey <sje@cup.hp.com>
+
+ * targets.c (bfd_elf32_ia64_hpux_big_vec): Add to DEFAULT_VECTOR.
+ (bfd_elf64_ia64_hpux_big_vec): Ditto.
+ (bfd_elf32_h8300_vec): Ditto.
+
+2002-01-23 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c: Remove stale part of ABI comment.
+ (NO_OPD_RELOCS): Define.
+ (ppc64_elf_check_relocs): Use it.
+ (ppc64_elf_relocate_section): Here too.
+ (build_one_stub): Don't point function syms at the stub. Instead,
+ hijack plt.offset.
+ (ppc64_elf_relocate_section): Check whether REL24 relocs should
+ really go to the stub. Make all dynamic relocs in opd against
+ locals.
+ (ppc64_elf_finish_dynamic_symbol): Allow for non-standard use of
+ plt.offset.
+
+2002-01-22 Richard Henderson <rth@redhat.com>
+
+ * elf64-alpha.c (INSN_UNOP): Encode with RB as $sp.
+
+2002-01-22 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_finish_dynamic_sections): Correct sign of
+ TOC_BASE_OFF adjustment.
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * po/SRC-POTFILES.in: Regenerate.
+
+2002-01-22 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * configure.host (hppa*64*-*-hpux*, hppa*64*-*-linux*): Add new
+ host defines.
+
+2002-01-21 Hans-Peter Nilsson <hp@axis.com>
+
+ * elf32-cris.c (cris_elf_relocate_section) <case R_CRIS_32_GOTREL>:
+ Check for and emit error if sgot is NULL at this point.
+
+2002-01-21 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * config.bfd (ia64*-*-netbsd*): New target.
+
+2002-01-21 Thomas Klausner <wiz@danbala.ifoer.tuwien.ac.at>
+
+ * som.c (som_write_space_strings): Comment typo fix.
+
+2002-01-21 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (struct ppc_link_hash_entry): Add is_func and
+ is_func_descriptor fields.
+ (link_hash_newfunc): Init them.
+ (ppc64_elf_check_relocs): Only R_PPC24_REL24 syms starting with a
+ dot are candidates for plt entries. When processing .opd relocs,
+ set function descriptor strings to point inside function code
+ string, and set new ppc_link_hash_entry fields.
+ (ppc64_elf_gc_sweep_hook): Don't sweep R_PPC64_REL24 relocs.
+ (ppc64_elf_adjust_dynamic_symbol): Remove most code dealing with
+ function descriptors. It's now done in..
+ (func_desc_adjust): New.
+ (ppc64_elf_func_desc_adjust): New.
+ (define elf_backend_always_size_sections): Define.
+ (ppc64_elf_hide_symbol): New.
+ (define elf_backend_hide_symbol): Define.
+ (allocate_dynrelocs): Remove code looking up function descriptors
+ as that has been done earlier.
+ (ppc64_elf_size_dynamic_sections): Use htab shortcut to elf hash
+ table.
+ (ppc64_elf_finish_dynamic_symbol): Likewise. Remove code looking
+ up function descriptor.
+ (build_one_stub): Look up the function code sym. Check for
+ invalid plt offsets.
+ (ppc64_elf_relocate_section): Tweak calls to undefined weak syms.
+ Convert R_PPC64_TOC relocs to R_PPC64_RELATIVE in shared libs.
+
+ * elf-bfd.h (elf_backend_data <elf_backend_hide_symbol>): Add
+ boolean param.
+ (_bfd_elf_link_hash_hide_symbol): Likewise.
+ * elflink.h (elf_link_add_object_symbols): Adjust call to
+ elf_backend_hide_symbol.
+ (elf_fix_symbol_flags): Likewise.
+ (elf_link_assign_sym_version): Likewise. Use bfd_malloc rather
+ than bfd_alloc.
+ * elf.c (_bfd_elf_link_hash_hide_symbol): Add "force_local" param.
+ Set ELF_LINK_FORCED_LOCAL and call _bfd_elf_strtab_delref.
+ * elf32-hppa.c (elf32_hppa_hide_symbol): Likewise.
+ (clobber_millicode_symbols): Adjust to suit new hide_symbol.
+ * elf32-cris.c (elf_cris_hide_symbol): Add "force_local" param
+ and adjust to suit.
+ * elf32-mips.c (_bfd_mips_elf_hide_symbol): Likewise, and call
+ _bfd_elf_link_hash_hide_symbol rather than duplicating code.
+ * elfxx-ia64.c (elfNN_ia64_hash_hide_symbol): Likewise.
+
+2002-01-18 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_adjust_dynamic_symbol): Test for a
+ dynamic function descriptor symbol, not the associated function
+ symbol.
+
+2002-01-17 Eric Christopher <echristo@redhat.com>
+
+ * elf32-mips.c (mips_elf_calculate_relocation): Fix typo.
+
+2002-01-17 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/bfd.pot: Regenerate.
+ * po/fr.po: Regenerate.
+
+2002-01-17 Alan Modra <amodra@bigpond.net.au>
+
+ * elf-bfd.h (elf_backend_data <elf_backend_section_from_bfd_section>):
+ Remove "Elf_Internal_Shdr *" param.
+ (_bfd_mips_elf_section_from_bfd_section): Ditto.
+ * elf32-mips.c (_bfd_mips_elf_section_from_bfd_section): Ditto.
+ * elf32-m32r.c (_bfd_m32r_elf_section_from_bfd_section): Ditto.
+ * elf32-v850.c (v850_elf_section_from_bfd_section): Ditto.
+ * elf64-mmix.c (mmix_elf_section_from_bfd_section): Ditto.
+ * elfxx-ia64.c (elfNN_hpux_backend_section_from_bfd_section): Ditto.
+ * elf.c (_bfd_elf_section_from_bfd_section): Allow backend
+ function to override special sections. Remove hdr arg from
+ backend call, and don't loop.
+
+2002-01-16 Eric Christopher <echristo@redhat.com>
+
+ * elf32-mips.c (mips_elf_calculate_relocation): Set require_jalxp
+ on R_MIPS_26 and target is 16bit. Add R_MIPS16_GPREL to list of
+ relocations requiring gp0 and gp.
+
+2002-01-16 Richard Earnshaw <rearnsha@arm.com>
+
+ * elf32-arm.h (elf32_arm_merge_private_bfd_data): Handle
+ EF_ARM_VFP_FLOAT.
+ (elf32_arm_print_private_bfd_data): Likewise.
+
+2002-01-16 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/tr.po: Import new version.
+
+2002-01-16 Alan Modra <amodra@bigpond.net.au>
+
+ * elf64-ppc.c (ppc64_elf_howto_raw): Remove stale FIXMEs.
+ (ppc64_elf_reloc_type_lookup): Use proper CTOR reloc.
+ (ORI_R0_R0_0): Correct.
+
+2002-01-16 Alan Modra <amodra@bigpond.net.au>
+
+ * elflink.c (_bfd_elf_create_dynamic_sections): Don't set SEC_CODE
+ when plt_not_loaded.
+ * elf64-ppc.c (ppc64_elf_create_dynamic_sections): No need to
+ clear .plt SEC_CODE here. Create .stub and correct .glink flags.
+ (PLT_INITIAL_ENTRY_SIZE): Set to 24.
+ (ppc64_elf_glink_code): Delete.
+ (PPC64_ELF_GLINK_SIZE): Delete.
+ (ADDIS_R12_R2, STD_R2_40R1, LD_R11_0R12, LD_R2_0R12, MTCTR_R11,
+ BCTR, ADDIS_R12_R12_1, LD_R2_40R1, NOP, LI_R0_0, B_DOT, LIS_R0_0,
+ ORI_R0_R0_0): Define.
+ (PLT_CALL_STUB_SIZE, GLINK_CALL_STUB_SIZE): Define.
+ (struct ppc_link_hash_table): Add sstub and plt_overflow.
+ (ppc64_elf_link_hash_table_create): Init them.
+ (ppc64_elf_check_relocs <R_PPC64_REL24>): Refcount .plt entry.
+ Don't copy to shared lib.
+ (ppc64_elf_check_relocs): Call bfd_set_error on errors.
+ (ppc64_elf_gc_sweep_hook <R_PPC64_REL24>): Sweep plt refcount.
+ (allocate_dynrelocs <plt>): Don't change function sym here. Make
+ room for .stub and .glink code.
+ (ppc64_elf_size_dynamic_sections): Handle .stub. Make entry for
+ DT_PPC64_GLINK.
+ (ppc64_elf_final_link): Rename to ppc64_elf_set_toc. Don't call
+ bfd_elf64_bfd_final_link.
+ (bfd_elf64_bfd_final_link): Don't define.
+ (ppc64_elf_size_stubs): New.
+ (build_plt_stub): New.
+ (build_one_stub): New.
+ (ppc64_elf_build_stubs): New.
+ (ppc64_elf_relocate_section <toc relocs>): Remove assert.
+ (ppc64_elf_relocate_section): Don't copy R_PPC64_REL24 relocs.
+ (ppc64_elf_finish_dynamic_symbol): Don't build stubs here. Set
+ DT_PPC64_GLINK entry. Tweak DT_PLTGOT, DT_JMPREL, DT_PLTRELSZ in
+ case output sections not separate. Adjust DT_RELASZ to not
+ include plt relocs. Set reserved got entry. Set got and plt
+ entry size.
+ (elf_backend_got_header_size): Set to 8.
+ * elf64-ppc.h: New file.
+
+2002-01-16 Alan Modra <amodra@bigpond.net.au>
+
+ * elf32-arm.h (elf32_arm_size_dynamic_sections): When removing
+ sections, use bfd_section_list_remove.
+ * elf32-i370.c (i370_elf_size_dynamic_sections): Likewise.
+ * elflink.h (elf_link_add_object_symbols): When removing all
+ sections, use bfd_section_list_clear.
+
+2002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/sv.po: New file: Swedish translation.
+ * configure.in (ALL_LINGUAS): Add sv.
+ * configure: Regenerate.
+
+2002-01-15 Jakub Jelinek <jakub@redhat.com>
+
+ * elflink.h (elf_link_input_bfd): Back out 2002-01-07 change.
+ * elf.c (merge_sections_remove_hook): New function.
+ (_bfd_elf_merge_sections): Pass it as 3rd argument to
+ _bfd_merge_sections.
+ * libbfd-in.h (_bfd_merge_sections): Add 3rd argument.
+ * libbfd.h: Rebuilt.
+ * merge.c (_bfd_merge_sections): Add remove_hook argument.
+ Call remove_hook if a SEC_EXCLUDE section is encountered.
+
+2002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * elf32-xstormy16.c (xstormy16_reloc_map): Add new field 'table'.
+ (xstormy16_reloc_map): Initialise new field with correct howto
+ table.
+ (xstormy16_reloc_type_lookup): Use 'table' field to locate correct
+ howto entry.
+
+2002-01-10 Michael Snyder <msnyder@redhat.com>
+
+ * elf.c (elfcore_write_prstatus): Use long instead of pid_t;
+ (elfcore_write_pstatus): Use long instead of pid_t;
+ * elf-bfd.h: Change prototypes to use long instead of pid_t;
+
+2002-01-09 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * elf.c: Update copyright years.
+ (elfcore_grok_netbsd_note): Use NT_NETBSDCORE_PROCINFO
+ and NT_NETBSDCORE_FIRSTMACH. Improve a comment.
+
+2002-01-08 Michael Snyder <msnyder@redhat.com>
+
+ Add capability to write corefile note sections, for gdb.
+ * elf.c (elfcore_write_note): New function.
+ (elfcore_write_prpsinfo): New function.
+ (elfcore_write_prstatus): New function.
+ (elfcore_write_pstatus): New function.
+ (elfcore_write_prfpreg): New function.
+ (elfcore_write_prxfpreg): New function.
+ * elf-bfd.h: Add prototypes for above functions.
+
+2002-01-08 Alexandre Oliva <aoliva@redhat.com>
+
+ * elf.c (elf_fake_sections): Propagate errors from
+ elf_backend_fake_section.
+
+2002-01-07 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * Makefile.am (BFD32_BACKENDS): Add elf32-sh-nbsd.lo.
+ (BFD32_BACKENDS_CFILES): Add elf32-sh-nbsd.c.
+ (elf32-sh-nbsd.lo): New rule.
+ * Makefile.in: Regenerate.
+ * config.bfd (sh*le-*-netbsdelf*): New target.
+ (sh*-*-netbsdelf*): New target.
+ * configure.in: Include netbsd-core.lo for native sh*-*-netbsd*.
+ (bfd_elf32_shnbsd_vec): New vector.
+ (bfd_elf32_shlnbsd_vec): New vector.
+ * configure: Regenerate.
+ * elf32-sh-nbsd.c: New file.
+ * targets.c: Update copyright years.
+ (_bfd_target_vector): Add bfd_elf32_shlnbsd_vec and
+ bfd_elf32_shnbsd_vec.
+
+2002-01-07 Aldy Hernandez <aldyh@redhat.com>
+
+ * coff-rs6000.c (READ20): Use bfd_scan_vma.
+
+2002-01-07 Geoffrey Keating <geoffk@redhat.com>
+
+ * elflink.h (elf_link_input_bfd): Don't ask for the merged offset
+ of a symbol in a section that will be deleted.
+
+2002-01-07 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/es.po: New file: Spanish translation.
+ * configure.in (ALL_LINGUAS): Add es.
+ * configure: Regenerate.
+
+2002-01-06 Steve Ellcey <sje@cup.hp.com>
+
+ * elfxx-ia64.c (is_unwind_section_name): Add target vector as
+ argument so we can handle HP-UX specially.
+ (elfNN_ia64_hpux_vec): New for use in is_unwind_section_name.
+ (elfNN_hpux_backend_section_from_bfd_section): New for support
+ of SHN_IA_64_ANSI_COMMON.
+ (elfNN_ia64_relax_section): Add support for SHN_IA_64_ANSI_COMMON.
+ (is_unwind_section_name): Add special HP-UX support.
+ (elfNN_ia64_section_from_shdr): Add support for more sections.
+ (elfNN_ia64_fake_sections): Modify is_unwind_section_name call and
+ add support for more sections.
+ (elfNN_ia64_additional_program_headers): Modify
+ is_unwind_section_name call.
+ (elfNN_ia64_modify_segment_map): Remove assumption that there is
+ only one unwind section in segment.
+
+2002-01-06 Alan Modra <amodra@bigpond.net.au>
+
+ * syms.c (_bfd_generic_make_empty_symbol): New function.
+ * libbfd-in.h (_bfd_nosymbols_make_empty_symbol): Define as
+ _bfd_generic_make_empty_symbol.
+ * libbfd.h: Regenerate.
+ * bfd-in2.h: Regenerate.
+ * hppabsd-core.c (hppabsd_core_make_empty_symbol): Delete function.
+ (hppabsd_core_get_symtab_upper_bound): Don't define.
+ (hppabsd_core_get_symtab): Likewise.
+ (hppabsd_core_print_symbol): Likewise.
+ (hppabsd_core_get_symbol_info): Likewise.
+ (hppabsd_core_bfd_is_local_label_name): Likewise.
+ (hppabsd_core_get_lineno): Likewise.
+ (hppabsd_core_find_nearest_line): Likewise.
+ (hppabsd_core_bfd_make_debug_symbol): Likewise.
+ (hppabsd_core_read_minisymbols): Likewise.
+ (hppabsd_core_minisymbol_to_symbol): Likewise.
+ (hppabsd_core_vec): Use BFD_JUMP_TABLE_SYMBOLS (_bfd_nosymbols).
+ Formatting fixes.
+ * hpux-core.c: Similarly.
+ * irix-core.c: Similarly.
+ * osf-core.c: Similarly.
+ * sco5-core.c: Similarly.
+ * binary.c (binary_make_empty_symbol): Remove function, define as
+ _bfd_generic_make_empty_symbol.
+ * ihex.c (ihex_make_empty_symbol): Likewise.
+ * mmo.c (mmo_make_empty_symbol): Likewise.
+ * ppcboot.c (ppcboot_make_empty_symbol): Likewise.
+ * srec.c (srec_make_empty_symbol): Likewise.
+ * versados.c (versados_make_empty_symbol): Likewise.
+ * vms.c (_bfd_vms_make_empty_symbol): Remove.
+ (vms_make_empty_symbol): Define as _bfd_generic_make_empty_symbol.
+ * vms-gsd.c (_bfd_vms_slurp_gsd): Call bfd_make_empty_symbol
+ rather than _bfd_vms_make_empty_symbol.
+ * vms-misc.c (new_symbol): Likewise.
+
+2002-01-05 Alan Modra <amodra@bigpond.net.au>
+
+ * section.c (bfd_section_init): Remove unnecessary initialisations.
+ (bfd_section_list_clear): New function.
+ (bfd_section_list_remove, bfd_section_list_insert): New macros.
+ (_bfd_strip_section_from_output): Use them.
+ * coffcode.h (coff_set_alignment_hook): Likewise.
+ * elf32-mips.c (_bfd_mips_elf_final_link): Likewise.
+ * elf64-mips.c (mips_elf64_final_link): Likewise.
+ * elf64-mmix.c (mmix_elf_final_link): Likewise.
+ * sunos.c (sunos_add_dynamic_symbols): Likewise.
+ * xcofflink.c (_bfd_xcoff_bfd_final_link): Likewise.
+ * bfd-in2.h: Regenerate.
+
+ * netbsd-core.c (netbsd_core_file_p): Use bfd_make_section_anyway
+ rather than doing our own section handling. Clean up after errors
+ with bfd_release and bfd_section_list_clear. Handle unexpected
+ flags.
+ * aoutf1.h (sunos4_core_file_p): Likewise.
+ * aix386-core.c (aix386_core_file_p): Likewise.
+ * cisco-core.c (cisco_core_file_validate): Likewise.
+ * ptrace-core.c (ptrace_unix_core_file_p): Likewise.
+ * trad-core.c (trad_unix_core_file_p): Likewise.
+
+ * hppabsd-core.c (hppabsd_core_core_file_p): Clean up after errors
+ with bfd_release and bfd_section_list_clear.
+ * hpux-core.c (hpux_core_core_file_p): Likewise.
+ * irix-core.c (irix_core_core_file_p): Likewise.
+ * lynx-core.c (lynx_core_file_p): Likewise.
+ * osf-core.c (osf_core_core_file_p): Likewise.
+ * rs6000-core.c (rs6000coff_core_p): Likewise.
+ * sco5-core.c (sco5_core_file_p): Likewise.
+
+ * elf32-mips.c (_bfd_mips_elf_lo16_reloc): Simplify, and perform
+ sign extension adjustments without conditionals.
+
+2002-01-04 Jakub Jelinek <jakub@redhat.com>
+
+ * elf-eh-frame.c (_bfd_elf_write_section_eh_frame): Don't crash if
+ CIE at .eh_frame start is removed due to no FDEs referencing it.
+
+2002-01-04 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * config.bfd (x86_64-*-netbsd*): New target.
+ * configure.in (x86_64-*-netbsd*): Set COREFILE
+ to netbsd-core.lo.
+ * configure: Regenerated.
+
+2002-01-03 Tom Rix <trix@redhat.com>
+
+ * xcofflink.c (_bfd_xcoff_bfd_final_link): Update .pad section ordering
+ for recent bfd_make_section_anyway change.
+
+2002-01-03 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * elf32-arm.h (elf32_arm_final_link_relocate): Handle
+ R_ARM_THM_PC11 reloc.
+
+2002-01-02 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * configure.in (LINGUAS): Add ja.
+ * configure: Regenerate.
+ * po/ja.po: Import from translation project's web site.
+
+2002-01-02 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * elf32-arm.h (elf32_arm_merge_private_bfd_data): Reformat error
+ messages to ease translation into other languages.
+
+For older changes see ChangeLog-0001
+
+Local Variables:
+mode: change-log
+left-margin: 8
+fill-column: 74
+version-control: never
+End:
diff --git a/contrib/binutils/bfd/Makefile.am b/contrib/binutils/bfd/Makefile.am
index 1213897..de811af 100644
--- a/contrib/binutils/bfd/Makefile.am
+++ b/contrib/binutils/bfd/Makefile.am
@@ -28,20 +28,22 @@ BFD_H = bfd.h
# need two copies of the executable, one to download and one for the
# debugger).
BFD32_LIBS = \
- archive.lo archures.lo bfd.lo cache.lo coffgen.lo corefile.lo \
+ archive.lo archures.lo bfd.lo bfdio.lo bfdwin.lo \
+ cache.lo coffgen.lo corefile.lo \
format.lo init.lo libbfd.lo opncls.lo reloc.lo \
section.lo syms.lo targets.lo hash.lo linker.lo \
srec.lo binary.lo tekhex.lo ihex.lo stabs.lo stab-syms.lo \
- merge.lo dwarf2.lo
+ merge.lo dwarf2.lo simple.lo
BFD64_LIBS = archive64.lo
BFD32_LIBS_CFILES = \
- archive.c archures.c bfd.c cache.c coffgen.c corefile.c \
+ archive.c archures.c bfd.c bfdio.c bfdwin.c \
+ cache.c coffgen.c corefile.c \
format.c init.c libbfd.c opncls.c reloc.c \
section.c syms.c targets.c hash.c linker.c \
srec.c binary.c tekhex.c ihex.c stabs.c stab-syms.c \
- merge.c dwarf2.c
+ merge.c dwarf2.c simple.c
BFD64_LIBS_CFILES = archive64.c
@@ -67,6 +69,8 @@ ALL_MACHINES = \
cpu-i386.lo \
cpu-i860.lo \
cpu-i960.lo \
+ cpu-ip2k.lo \
+ cpu-iq2000.lo \
cpu-m32r.lo \
cpu-m68hc11.lo \
cpu-m68hc12.lo \
@@ -77,6 +81,7 @@ ALL_MACHINES = \
cpu-mcore.lo \
cpu-mips.lo \
cpu-mmix.lo \
+ cpu-msp430.lo \
cpu-or32.lo \
cpu-ns32k.lo \
cpu-openrisc.lo \
@@ -88,6 +93,7 @@ ALL_MACHINES = \
cpu-sh.lo \
cpu-sparc.lo \
cpu-tic30.lo \
+ cpu-tic4x.lo \
cpu-tic54x.lo \
cpu-tic80.lo \
cpu-v850.lo \
@@ -95,6 +101,7 @@ ALL_MACHINES = \
cpu-we32k.lo \
cpu-w65.lo \
cpu-xstormy16.lo \
+ cpu-xtensa.lo \
cpu-z8k.lo
ALL_MACHINES_CFILES = \
@@ -117,6 +124,8 @@ ALL_MACHINES_CFILES = \
cpu-i386.c \
cpu-i860.c \
cpu-i960.c \
+ cpu-ip2k.c \
+ cpu-iq2000.c \
cpu-m32r.c \
cpu-m68hc11.c \
cpu-m68hc12.c \
@@ -127,6 +136,7 @@ ALL_MACHINES_CFILES = \
cpu-mcore.c \
cpu-mips.c \
cpu-mmix.c \
+ cpu-msp430.c \
cpu-or32.c \
cpu-ns32k.c \
cpu-openrisc.c \
@@ -138,6 +148,7 @@ ALL_MACHINES_CFILES = \
cpu-sh.c \
cpu-sparc.c \
cpu-tic30.c \
+ cpu-tic4x.c \
cpu-tic54x.c \
cpu-tic80.c \
cpu-v850.c \
@@ -145,6 +156,7 @@ ALL_MACHINES_CFILES = \
cpu-we32k.c \
cpu-w65.c \
cpu-xstormy16.c \
+ cpu-xtensa.c \
cpu-z8k.c
# The .o files needed by all of the 32 bit vectors that are configured into
@@ -183,6 +195,7 @@ BFD32_BACKENDS = \
coff-stgo32.lo \
coff-svm68k.lo \
coff-tic30.lo \
+ coff-tic4x.lo \
coff-tic54x.lo \
coff-tic80.lo \
coff-u68k.lo \
@@ -195,6 +208,7 @@ BFD32_BACKENDS = \
ecofflink.lo \
efi-app-ia32.lo \
elf.lo \
+ elf32-am33lin.lo \
elf32-arc.lo \
elfarm-oabi.lo \
elfarm-nabi.lo \
@@ -210,13 +224,15 @@ BFD32_BACKENDS = \
elf32-hppa.lo \
elf32-i370.lo \
elf32-i386.lo \
- elf32-i386-fbsd.lo \
elf32-i860.lo \
elf32-i960.lo \
elf32-ia64.lo \
+ elf32-ip2k.lo \
+ elf32-iq2000.lo \
elf32-m32r.lo \
elf32-m68hc11.lo \
elf32-m68hc12.lo \
+ elf32-m68hc1x.lo \
elf32-m68k.lo \
elf32-m88k.lo \
elf-m10200.lo \
@@ -224,21 +240,20 @@ BFD32_BACKENDS = \
elf32-mcore.lo \
elfxx-mips.lo \
elf32-mips.lo \
+ elf32-msp430.lo \
elf32-openrisc.lo \
elf32-or32.lo \
elf32-pj.lo \
elf32-ppc.lo \
elf32-s390.lo \
elf32-sh.lo \
- elf32-sh-lin.lo \
elf32-sh64.lo \
elf32-sh64-com.lo \
- elf32-sh-nbsd.lo \
- elf32-sh64-nbsd.lo \
elf32-sparc.lo \
elf32-v850.lo \
elf32-vax.lo \
elf32-xstormy16.lo \
+ elf32-xtensa.lo \
elf32.lo \
elflink.lo \
elf-strtab.lo \
@@ -264,6 +279,7 @@ BFD32_BACKENDS = \
m68klynx.lo \
m68knetbsd.lo \
m88kmach3.lo \
+ mach-o.lo \
mipsbsd.lo \
newsos3.lo \
nlm.lo \
@@ -275,6 +291,7 @@ BFD32_BACKENDS = \
oasys.lo \
pc532-mach.lo \
pdp11.lo \
+ pef.lo \
pe-arm.lo \
pei-arm.lo \
pe-i386.lo \
@@ -304,7 +321,10 @@ BFD32_BACKENDS = \
vms-hdr.lo \
vms-misc.lo \
vms-tir.lo \
- xcofflink.lo
+ xcofflink.lo \
+ xsym.lo \
+ xtensa-isa.lo \
+ xtensa-modules.lo
BFD32_BACKENDS_CFILES = \
aout-adobe.c \
@@ -340,6 +360,7 @@ BFD32_BACKENDS_CFILES = \
coff-stgo32.c \
coff-svm68k.c \
coff-tic30.c \
+ coff-tic4x.c \
coff-tic54x.c \
coff-tic80.c \
coff-u68k.c \
@@ -352,6 +373,7 @@ BFD32_BACKENDS_CFILES = \
ecofflink.c \
efi-app-ia32.c \
elf.c \
+ elf32-am33lin.c \
elf32-arc.c \
elfarm-oabi.c \
elfarm-nabi.c \
@@ -367,19 +389,22 @@ BFD32_BACKENDS_CFILES = \
elf32-hppa.c \
elf32-i370.c \
elf32-i386.c \
- elf32-i386-fbsd.c \
elf32-i860.c \
elf32-i960.c \
+ elf32-ip2k.c \
+ elf32-iq2000.c \
elf32-m32r.c \
elf32-m68k.c \
elf32-m68hc11.c \
elf32-m68hc12.c \
+ elf32-m68hc1x.c \
elf32-m88k.c \
elf-m10200.c \
elf-m10300.c \
elf32-mcore.c \
elfxx-mips.c \
elf32-mips.c \
+ elf32-msp430.c \
elf32-openrisc.c \
elf32-or32.c \
elf32-pj.c \
@@ -388,13 +413,11 @@ BFD32_BACKENDS_CFILES = \
elf32-sh64-com.c \
elf32-s390.c \
elf32-sh.c \
- elf32-sh-lin.c \
- elf32-sh-nbsd.c \
- elf32-sh64-nbsd.c \
elf32-sparc.c \
elf32-v850.c \
elf32-vax.c \
elf32-xstormy16.c \
+ elf32-xtensa.c \
elf32.c \
elflink.c \
elf-strtab.c \
@@ -420,6 +443,7 @@ BFD32_BACKENDS_CFILES = \
m68klynx.c \
m68knetbsd.c \
m88kmach3.c \
+ mach-o.c \
mipsbsd.c \
newsos3.c \
nlm.c \
@@ -431,6 +455,7 @@ BFD32_BACKENDS_CFILES = \
oasys.c \
pc532-mach.c \
pdp11.c \
+ pef.c \
pe-arm.c \
pei-arm.c \
pe-i386.c \
@@ -459,7 +484,10 @@ BFD32_BACKENDS_CFILES = \
vms-hdr.c \
vms-misc.c \
vms-tir.c \
- xcofflink.c
+ xcofflink.c \
+ xsym.c \
+ xtensa-isa.c \
+ xtensa-modules.c
# The .o files needed by all of the 64 bit vectors that are configured into
# target_vector in targets.c if configured with --enable-targets=all
@@ -473,14 +501,13 @@ BFD64_BACKENDS = \
efi-app-ia64.lo \
elf64-x86-64.lo \
elf64-alpha.lo \
- elf64-alpha-fbsd.lo \
elf64-hppa.lo \
elf64-ia64.lo \
elf64-gen.lo \
+ elfn32-mips.lo \
elf64-mips.lo \
elf64-mmix.lo \
elf64-sh64.lo \
- elf64-sh64-nbsd.lo \
elf64-ppc.lo \
elf64-s390.lo \
elf64-sparc.lo \
@@ -499,15 +526,14 @@ BFD64_BACKENDS_CFILES = \
efi-app-ia64.c \
elf64-x86-64.c \
elf64-alpha.c \
- elf64-alpha-fbsd.c \
elf64-hppa.c \
elf64-gen.c \
+ elfn32-mips.c \
elf64-mips.c \
elf64-mmix.c \
elf64-ppc.c \
elf64-s390.c \
elf64-sh64.c \
- elf64-sh64-nbsd.c \
elf64-sparc.c \
elf64.c \
mmo.c \
@@ -561,16 +587,18 @@ CFILES = $(SOURCE_CFILES) $(BUILD_CFILES)
## This is a list of all .h files which are in the source tree.
SOURCE_HFILES = \
aout-target.h aoutf1.h aoutx.h coffcode.h coffswap.h ecoffswap.h \
- elf-bfd.h elf-hppa.h elf32-arm.h elf32-hppa.h elf64-hppa.h \
- elfcode.h elfcore.h elflink.h freebsd.h genlink.h go32stub.h \
- libaout.h libbfd.h libcoff.h libecoff.h libhppa.h \
- libieee.h libnlm.h liboasys.h libpei.h netbsd.h nlm-target.h \
- nlmcode.h nlmswap.h ns32k.h peicode.h som.h vms.h libxcoff.h \
- xcoff-target.h version.h
+ elf-bfd.h elf-hppa.h elf32-arm.h elf32-hppa.h \
+ elf64-hppa.h elfcode.h elfcore.h \
+ freebsd.h genlink.h go32stub.h \
+ libaout.h libbfd.h libcoff.h libecoff.h libhppa.h libieee.h \
+ libnlm.h liboasys.h libpei.h libxcoff.h mach-o.h \
+ netbsd.h nlm-target.h nlmcode.h nlmswap.h ns32k.h \
+ pef.h pef-traceback.h peicode.h som.h version.h \
+ vms.h xcoff-target.h xsym.h
## ... and all .h files which are in the build tree.
BUILD_HFILES = \
- elf32-target.h elf64-target.h targmatch.h
+ bfdver.h elf32-target.h elf64-target.h targmatch.h
HFILES = $(SOURCE_HFILES) $(BUILD_HFILES)
@@ -578,23 +606,15 @@ SRC_POTFILES = $(SOURCE_CFILES) $(SOURCE_HFILES)
BLD_POTFILES = $(BUILD_CFILES) $(BUILD_HFILES)
po/SRC-POTFILES.in: @MAINT@ Makefile $(SRC_POTFILES)
- for file in $(SRC_POTFILES); do echo $$file; done | sort > tmp.src \
+ for file in $(SRC_POTFILES); do echo $$file; done \
+ | LC_COLLATE= sort > tmp.src \
&& mv tmp.src $(srcdir)/po/SRC-POTFILES.in
po/BLD-POTFILES.in: @MAINT@ Makefile $(BLD_POTFILES)
- for file in $(BLD_POTFILES); do echo $$file; done | sort > tmp.bld \
+ for file in $(BLD_POTFILES); do echo $$file; done \
+ | LC_COLLATE= sort > tmp.bld \
&& mv tmp.bld $(srcdir)/po/BLD-POTFILES.in
-# The following target is retained for upgrade purposes.
-# This target used to exist in older versions of this makefile, and was
-# referenced by <builddir>/po/Makefile (which is created from <srcdir>/po/Make-in)
-# So old versions of <builddir>/po/Makefile will try to regenerate themselves
-# when make is next run, but that dependency cannot be completed without a build
-# of po/POTFILES.in. Hence the presence of this rule. This rule will be deleted
-# once it is no longer needed - probably in the fall of 2001.
-po/POTFILES.in:
-
-
diststuff: info
# Various kinds of .o files to put in libbfd.a:
@@ -653,10 +673,10 @@ targmatch.h: config.bfd targmatch.sed
# When compiling archures.c and targets.c, supply the default target
# info from configure.
-targets.lo: targets.c config.status
+targets.lo: targets.c Makefile
$(LIBTOOL) --mode=compile $(COMPILE) -c $(TDEFAULTS) $(srcdir)/targets.c
-archures.lo: archures.c config.status
+archures.lo: archures.c Makefile
$(LIBTOOL) --mode=compile $(COMPILE) -c $(TDEFAULTS) $(srcdir)/archures.c
elf32-target.h : elfxx-target.h
@@ -788,9 +808,11 @@ stmp-bfd-h: bfd-in3.h
touch stmp-bfd-h
BFD_H_FILES = bfd-in.h init.c opncls.c libbfd.c section.c archures.c \
- reloc.c syms.c bfd.c archive.c corefile.c targets.c format.c version.h
+ reloc.c syms.c bfd.c bfdio.c bfdwin.c \
+ archive.c corefile.c targets.c format.c
BFD64_H_FILES = archive64.c
-LIBBFD_H_FILES = libbfd-in.h init.c libbfd.c cache.c reloc.c archures.c elf.c
+LIBBFD_H_FILES = libbfd-in.h init.c libbfd.c bfdio.c bfdwin.c \
+ cache.c reloc.c archures.c elf.c
LIBCOFF_H_FILES = libcoff-in.h coffcode.h
# Could really use a "copy-if-change"...
@@ -834,8 +856,9 @@ CLEANFILES = bfd.h dep.sed stmp-bfd-h DEP DEPA DEP1 DEP2 libbfd.a stamp-lib \
DISTCLEANFILES = $(BUILD_CFILES) $(BUILD_HFILES)
-# We want to rerun configure if config.bfd or configure.host change.
-config.status: $(srcdir)/configure $(srcdir)/config.bfd $(srcdir)/configure.host
+# We want to rerun configure if config.bfd, configure.host or version.h change.
+config.status: $(srcdir)/configure $(srcdir)/config.bfd \
+ $(srcdir)/configure.host $(srcdir)/version.h
$(SHELL) ./config.status --recheck
# What appears below is generated by a hacked mkdep using gcc -MM.
@@ -845,11 +868,13 @@ config.status: $(srcdir)/configure $(srcdir)/config.bfd $(srcdir)/configure.host
archive.lo: archive.c $(INCDIR)/filenames.h $(INCDIR)/aout/ar.h \
$(INCDIR)/aout/ranlib.h $(INCDIR)/safe-ctype.h
archures.lo: archures.c $(INCDIR)/filenames.h $(INCDIR)/safe-ctype.h
-bfd.lo: bfd.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
+bfd.lo: bfd.c bfdver.h $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
$(INCDIR)/safe-ctype.h $(INCDIR)/bfdlink.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/sym.h libcoff.h libecoff.h $(INCDIR)/coff/ecoff.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h
+bfdio.lo: bfdio.c $(INCDIR)/filenames.h
+bfdwin.lo: bfdwin.c $(INCDIR)/filenames.h
cache.lo: cache.c $(INCDIR)/filenames.h
coffgen.lo: coffgen.c $(INCDIR)/filenames.h $(INCDIR)/coff/internal.h \
libcoff.h $(INCDIR)/bfdlink.h
@@ -857,7 +882,8 @@ corefile.lo: corefile.c $(INCDIR)/filenames.h
format.lo: format.c $(INCDIR)/filenames.h
init.lo: init.c $(INCDIR)/filenames.h
libbfd.lo: libbfd.c $(INCDIR)/filenames.h
-opncls.lo: opncls.c $(INCDIR)/filenames.h $(INCDIR)/objalloc.h
+opncls.lo: opncls.c $(INCDIR)/filenames.h $(INCDIR)/objalloc.h \
+ $(INCDIR)/libiberty.h
reloc.lo: reloc.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h
section.lo: section.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h
syms.lo: syms.c $(INCDIR)/filenames.h $(INCDIR)/safe-ctype.h \
@@ -882,11 +908,12 @@ merge.lo: merge.c $(INCDIR)/filenames.h $(INCDIR)/hashtab.h \
dwarf2.lo: dwarf2.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/dwarf2.h
+simple.lo: simple.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h
archive64.lo: archive64.c $(INCDIR)/filenames.h $(INCDIR)/aout/ar.h
cpu-a29k.lo: cpu-a29k.c $(INCDIR)/filenames.h
cpu-alpha.lo: cpu-alpha.c $(INCDIR)/filenames.h
cpu-arc.lo: cpu-arc.c $(INCDIR)/filenames.h
-cpu-arm.lo: cpu-arm.c $(INCDIR)/filenames.h
+cpu-arm.lo: cpu-arm.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h
cpu-avr.lo: cpu-avr.c $(INCDIR)/filenames.h
cpu-cris.lo: cpu-cris.c $(INCDIR)/filenames.h
cpu-d10v.lo: cpu-d10v.c $(INCDIR)/filenames.h
@@ -903,6 +930,8 @@ cpu-i370.lo: cpu-i370.c $(INCDIR)/filenames.h
cpu-i386.lo: cpu-i386.c $(INCDIR)/filenames.h
cpu-i860.lo: cpu-i860.c $(INCDIR)/filenames.h
cpu-i960.lo: cpu-i960.c $(INCDIR)/filenames.h
+cpu-ip2k.lo: cpu-ip2k.c $(INCDIR)/filenames.h
+cpu-iq2000.lo: cpu-iq2000.c $(INCDIR)/filenames.h
cpu-m32r.lo: cpu-m32r.c $(INCDIR)/filenames.h
cpu-m68hc11.lo: cpu-m68hc11.c $(INCDIR)/filenames.h
cpu-m68hc12.lo: cpu-m68hc12.c $(INCDIR)/filenames.h
@@ -913,6 +942,7 @@ cpu-m10300.lo: cpu-m10300.c $(INCDIR)/filenames.h
cpu-mcore.lo: cpu-mcore.c $(INCDIR)/filenames.h
cpu-mips.lo: cpu-mips.c $(INCDIR)/filenames.h
cpu-mmix.lo: cpu-mmix.c $(INCDIR)/filenames.h
+cpu-msp430.lo: cpu-msp430.c $(INCDIR)/filenames.h
cpu-or32.lo: cpu-or32.c $(INCDIR)/filenames.h
cpu-ns32k.lo: cpu-ns32k.c $(INCDIR)/filenames.h ns32k.h
cpu-openrisc.lo: cpu-openrisc.c $(INCDIR)/filenames.h
@@ -924,6 +954,7 @@ cpu-s390.lo: cpu-s390.c $(INCDIR)/filenames.h
cpu-sh.lo: cpu-sh.c $(INCDIR)/filenames.h
cpu-sparc.lo: cpu-sparc.c $(INCDIR)/filenames.h
cpu-tic30.lo: cpu-tic30.c $(INCDIR)/filenames.h
+cpu-tic4x.lo: cpu-tic4x.c $(INCDIR)/filenames.h
cpu-tic54x.lo: cpu-tic54x.c $(INCDIR)/filenames.h
cpu-tic80.lo: cpu-tic80.c $(INCDIR)/filenames.h
cpu-v850.lo: cpu-v850.c $(INCDIR)/filenames.h $(INCDIR)/safe-ctype.h
@@ -931,6 +962,7 @@ cpu-vax.lo: cpu-vax.c $(INCDIR)/filenames.h
cpu-we32k.lo: cpu-we32k.c $(INCDIR)/filenames.h
cpu-w65.lo: cpu-w65.c $(INCDIR)/filenames.h
cpu-xstormy16.lo: cpu-xstormy16.c $(INCDIR)/filenames.h
+cpu-xtensa.lo: cpu-xtensa.c $(INCDIR)/filenames.h
cpu-z8k.lo: cpu-z8k.c $(INCDIR)/filenames.h
aout-adobe.lo: aout-adobe.c $(INCDIR)/filenames.h $(INCDIR)/aout/adobe.h \
$(INCDIR)/aout/stab_gnu.h $(INCDIR)/aout/stab.def libaout.h \
@@ -993,7 +1025,8 @@ coff-aux.lo: coff-aux.c $(INCDIR)/filenames.h $(INCDIR)/coff/aux-coff.h \
coffswap.h
coff-h8300.lo: coff-h8300.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
genlink.h $(INCDIR)/coff/h8300.h $(INCDIR)/coff/external.h \
- $(INCDIR)/coff/internal.h libcoff.h coffcode.h coffswap.h
+ $(INCDIR)/coff/internal.h libcoff.h $(INCDIR)/libiberty.h \
+ coffcode.h coffswap.h
coff-h8500.lo: coff-h8500.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
$(INCDIR)/coff/h8500.h $(INCDIR)/coff/external.h $(INCDIR)/coff/internal.h \
libcoff.h coffcode.h coffswap.h
@@ -1042,6 +1075,9 @@ coff-svm68k.lo: coff-svm68k.c coff-m68k.c $(INCDIR)/filenames.h \
coff-tic30.lo: coff-tic30.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
$(INCDIR)/coff/tic30.h $(INCDIR)/coff/external.h $(INCDIR)/coff/internal.h \
libcoff.h coffcode.h coffswap.h
+coff-tic4x.lo: coff-tic4x.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
+ $(INCDIR)/coff/tic4x.h $(INCDIR)/coff/ti.h $(INCDIR)/coff/internal.h \
+ libcoff.h coffcode.h coffswap.h
coff-tic54x.lo: coff-tic54x.c $(INCDIR)/filenames.h \
$(INCDIR)/bfdlink.h $(INCDIR)/coff/tic54x.h $(INCDIR)/coff/ti.h \
$(INCDIR)/coff/internal.h libcoff.h coffcode.h coffswap.h
@@ -1061,7 +1097,7 @@ coff-z8k.lo: coff-z8k.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
$(INCDIR)/coff/z8k.h $(INCDIR)/coff/external.h $(INCDIR)/coff/internal.h \
libcoff.h coffcode.h coffswap.h
cofflink.lo: cofflink.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
- $(INCDIR)/coff/internal.h libcoff.h
+ $(INCDIR)/coff/internal.h libcoff.h $(INCDIR)/safe-ctype.h
dwarf1.lo: dwarf1.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/dwarf.h
@@ -1081,6 +1117,10 @@ efi-app-ia32.lo: efi-app-ia32.c $(INCDIR)/filenames.h \
elf.lo: elf.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/libiberty.h
+elf32-am33lin.lo: elf32-am33lin.c elf-m10300.c $(INCDIR)/filenames.h \
+ elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/mn10300.h \
+ $(INCDIR)/elf/reloc-macros.h elf32-target.h
elf32-arc.lo: elf32-arc.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(INCDIR)/elf/arc.h $(INCDIR)/elf/reloc-macros.h \
@@ -1120,7 +1160,7 @@ elf32-fr30.lo: elf32-fr30.c $(INCDIR)/filenames.h elf-bfd.h \
elf32-frv.lo: elf32-frv.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(INCDIR)/elf/frv.h $(INCDIR)/elf/reloc-macros.h \
- elf32-target.h
+ $(INCDIR)/hashtab.h elf32-target.h
elf32-gen.lo: elf32-gen.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h elf32-target.h
@@ -1134,15 +1174,12 @@ elf32-hppa.lo: elf32-hppa.c $(INCDIR)/filenames.h elf-bfd.h \
libhppa.h elf32-hppa.h elf-hppa.h elf32-target.h
elf32-i370.lo: elf32-i370.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
- $(INCDIR)/elf/external.h $(INCDIR)/elf/i370.h elf32-target.h
+ $(INCDIR)/elf/external.h $(INCDIR)/elf/i370.h $(INCDIR)/elf/reloc-macros.h \
+ elf32-target.h
elf32-i386.lo: elf32-i386.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/elf/i386.h $(INCDIR)/elf/reloc-macros.h \
elf32-target.h
-elf32-i386-fbsd.lo: elf32-i386-fbsd.c elf32-i386.c $(INCDIR)/filenames.h \
- $(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
- $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/elf/i386.h \
- $(INCDIR)/elf/reloc-macros.h elf32-target.h
elf32-i860.lo: elf32-i860.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(INCDIR)/elf/i860.h $(INCDIR)/elf/reloc-macros.h \
@@ -1151,6 +1188,14 @@ elf32-i960.lo: elf32-i960.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(INCDIR)/elf/i960.h $(INCDIR)/elf/reloc-macros.h \
elf32-target.h
+elf32-ip2k.lo: elf32-ip2k.c $(INCDIR)/filenames.h elf-bfd.h \
+ $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
+ $(INCDIR)/bfdlink.h $(INCDIR)/elf/ip2k.h $(INCDIR)/elf/reloc-macros.h \
+ elf32-target.h
+elf32-iq2000.lo: elf32-iq2000.c $(INCDIR)/filenames.h \
+ elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/iq2000.h \
+ $(INCDIR)/elf/reloc-macros.h elf32-target.h
elf32-m32r.lo: elf32-m32r.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(INCDIR)/elf/m32r.h $(INCDIR)/elf/reloc-macros.h \
@@ -1160,13 +1205,20 @@ elf32-m68k.lo: elf32-m68k.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
$(INCDIR)/elf/external.h $(INCDIR)/elf/m68k.h $(INCDIR)/elf/reloc-macros.h \
elf32-target.h
elf32-m68hc11.lo: elf32-m68hc11.c $(INCDIR)/filenames.h \
- elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
- $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/m68hc11.h \
- $(INCDIR)/elf/reloc-macros.h elf32-target.h
+ $(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
+ $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h elf32-m68hc1x.h \
+ $(INCDIR)/elf/m68hc11.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/opcode/m68hc11.h elf32-target.h
elf32-m68hc12.lo: elf32-m68hc12.c $(INCDIR)/filenames.h \
- elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
- $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/m68hc11.h \
- $(INCDIR)/elf/reloc-macros.h elf32-target.h
+ $(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
+ $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h elf32-m68hc1x.h \
+ $(INCDIR)/elf/m68hc11.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/opcode/m68hc11.h elf32-target.h
+elf32-m68hc1x.lo: elf32-m68hc1x.c $(INCDIR)/filenames.h \
+ $(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
+ $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h elf32-m68hc1x.h \
+ $(INCDIR)/elf/m68hc11.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/opcode/m68hc11.h
elf32-m88k.lo: elf32-m88k.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h elf32-target.h
@@ -1181,17 +1233,23 @@ elf32-mcore.lo: elf32-mcore.c $(INCDIR)/filenames.h \
$(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
$(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/elf/mcore.h \
$(INCDIR)/elf/reloc-macros.h elf32-target.h
-elfxx-mips.lo: elfxx-mips.c $(INCDIR)/filenames.h elf-bfd.h \
- $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
- $(INCDIR)/bfdlink.h elfxx-mips.h $(INCDIR)/elf/mips.h \
- $(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/sym.h $(INCDIR)/coff/symconst.h \
- $(INCDIR)/coff/ecoff.h $(INCDIR)/coff/mips.h $(INCDIR)/coff/external.h
+elfxx-mips.lo: elfxx-mips.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
+ elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h elfxx-mips.h \
+ $(INCDIR)/elf/mips.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/sym.h \
+ $(INCDIR)/coff/symconst.h $(INCDIR)/coff/ecoff.h $(INCDIR)/coff/mips.h \
+ $(INCDIR)/coff/external.h $(INCDIR)/hashtab.h
elf32-mips.lo: elf32-mips.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
genlink.h elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h elfxx-mips.h $(INCDIR)/elf/mips.h \
$(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/sym.h $(INCDIR)/coff/symconst.h \
$(INCDIR)/coff/internal.h $(INCDIR)/coff/ecoff.h $(INCDIR)/coff/mips.h \
$(INCDIR)/coff/external.h ecoffswap.h elf32-target.h
+elf32-msp430.lo: elf32-msp430.c $(INCDIR)/filenames.h \
+ $(INCDIR)/libiberty.h elf-bfd.h $(INCDIR)/elf/common.h \
+ $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h \
+ $(INCDIR)/elf/msp430.h $(INCDIR)/elf/reloc-macros.h \
+ elf32-target.h
elf32-openrisc.lo: elf32-openrisc.c $(INCDIR)/filenames.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/openrisc.h \
@@ -1208,16 +1266,16 @@ elf32-pj.lo: elf32-pj.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf32-ppc.lo: elf32-ppc.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/elf/ppc.h $(INCDIR)/elf/reloc-macros.h \
- elf32-target.h
+ elf32-ppc.h elf32-target.h
elf32-sh64.lo: elf32-sh64.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(srcdir)/../opcodes/sh64-opc.h \
- elf32-sh.c $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
+ elf32-sh64.h elf32-sh.c $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
elf32-target.h
elf32-sh64-com.lo: elf32-sh64-com.c $(INCDIR)/filenames.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/sh.h \
- $(INCDIR)/elf/reloc-macros.h $(srcdir)/../opcodes/sh64-opc.h
+ $(INCDIR)/elf/reloc-macros.h elf32-sh64.h $(srcdir)/../opcodes/sh64-opc.h
elf32-s390.lo: elf32-s390.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/elf/s390.h $(INCDIR)/elf/reloc-macros.h \
@@ -1226,19 +1284,6 @@ elf32-sh.lo: elf32-sh.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
elf32-target.h
-elf32-sh-lin.lo: elf32-sh-lin.c $(INCDIR)/filenames.h \
- $(INCDIR)/elf/internal.h elf-bfd.h $(INCDIR)/elf/common.h \
- $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h elf32-sh.c \
- $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h elf32-target.h
-elf32-sh-nbsd.lo: elf32-sh-nbsd.c elf32-sh.c $(INCDIR)/filenames.h \
- $(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
- $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/elf/sh.h \
- $(INCDIR)/elf/reloc-macros.h elf32-target.h
-elf32-sh64-nbsd.lo: elf32-sh64-nbsd.c elf32-sh64.c \
- $(INCDIR)/filenames.h elf-bfd.h $(INCDIR)/elf/common.h \
- $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h \
- $(srcdir)/../opcodes/sh64-opc.h elf32-sh.c $(INCDIR)/elf/sh.h \
- $(INCDIR)/elf/reloc-macros.h elf32-target.h
elf32-sparc.lo: elf32-sparc.c $(INCDIR)/filenames.h \
$(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
$(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/elf/sparc.h \
@@ -1257,13 +1302,18 @@ elf32-xstormy16.lo: elf32-xstormy16.c $(INCDIR)/filenames.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/xstormy16.h \
$(INCDIR)/elf/reloc-macros.h $(INCDIR)/libiberty.h \
elf32-target.h
+elf32-xtensa.lo: elf32-xtensa.c $(INCDIR)/filenames.h \
+ $(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
+ $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/elf/xtensa.h \
+ $(INCDIR)/elf/reloc-macros.h $(INCDIR)/xtensa-isa.h \
+ $(INCDIR)/xtensa-config.h elf32-target.h
elf32.lo: elf32.c elfcode.h $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
$(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
$(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h elfcore.h \
- elflink.h
+ $(INCDIR)/safe-ctype.h
elflink.lo: elflink.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
- $(INCDIR)/elf/external.h
+ $(INCDIR)/elf/external.h $(INCDIR)/libiberty.h
elf-strtab.lo: elf-strtab.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(INCDIR)/hashtab.h $(INCDIR)/libiberty.h
@@ -1333,6 +1383,8 @@ m68knetbsd.lo: m68knetbsd.c netbsd.h $(INCDIR)/filenames.h \
m88kmach3.lo: m88kmach3.c $(INCDIR)/filenames.h libaout.h \
$(INCDIR)/bfdlink.h aout-target.h $(INCDIR)/aout/aout64.h \
$(INCDIR)/aout/stab_gnu.h $(INCDIR)/aout/stab.def $(INCDIR)/aout/ar.h
+mach-o.lo: mach-o.c mach-o.h $(INCDIR)/filenames.h \
+ $(INCDIR)/libiberty.h mach-o-target.c
mipsbsd.lo: mipsbsd.c $(INCDIR)/filenames.h libaout.h \
$(INCDIR)/bfdlink.h aout-target.h $(INCDIR)/aout/aout64.h \
$(INCDIR)/aout/stab_gnu.h $(INCDIR)/aout/stab.def $(INCDIR)/aout/ar.h
@@ -1364,6 +1416,8 @@ pc532-mach.lo: pc532-mach.c $(INCDIR)/filenames.h libaout.h \
pdp11.lo: pdp11.c $(INCDIR)/filenames.h libaout.h $(INCDIR)/bfdlink.h \
aout-target.h $(INCDIR)/aout/aout64.h $(INCDIR)/aout/stab_gnu.h \
$(INCDIR)/aout/stab.def $(INCDIR)/aout/ar.h $(INCDIR)/safe-ctype.h
+pef.lo: pef.c $(INCDIR)/safe-ctype.h pef.h pef-traceback.h \
+ $(INCDIR)/filenames.h $(INCDIR)/libiberty.h
pe-arm.lo: pe-arm.c $(INCDIR)/filenames.h coff-arm.c \
$(INCDIR)/coff/arm.h $(INCDIR)/coff/external.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/pe.h libcoff.h $(INCDIR)/bfdlink.h coffcode.h \
@@ -1447,8 +1501,8 @@ vms.lo: vms.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
vms.h
vms-gsd.lo: vms-gsd.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
vms.h
-vms-hdr.lo: vms-hdr.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
- $(INCDIR)/safe-ctype.h vms.h
+vms-hdr.lo: vms-hdr.c bfdver.h $(INCDIR)/filenames.h \
+ $(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h vms.h
vms-misc.lo: vms-misc.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
vms.h
vms-tir.lo: vms-tir.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
@@ -1456,6 +1510,11 @@ vms-tir.lo: vms-tir.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
xcofflink.lo: xcofflink.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
$(INCDIR)/coff/internal.h $(INCDIR)/coff/xcoff.h libcoff.h \
libxcoff.h
+xsym.lo: xsym.c xsym.h $(INCDIR)/filenames.h
+xtensa-isa.lo: xtensa-isa.c $(INCDIR)/xtensa-isa.h \
+ $(INCDIR)/xtensa-isa-internal.h
+xtensa-modules.lo: xtensa-modules.c $(INCDIR)/xtensa-isa.h \
+ $(INCDIR)/xtensa-isa-internal.h
aix5ppc-core.lo: aix5ppc-core.c
aout64.lo: aout64.c aoutx.h $(INCDIR)/filenames.h $(INCDIR)/safe-ctype.h \
$(INCDIR)/bfdlink.h libaout.h $(INCDIR)/aout/aout64.h \
@@ -1487,13 +1546,6 @@ elf64-alpha.lo: elf64-alpha.c $(INCDIR)/filenames.h \
$(INCDIR)/coff/sym.h $(INCDIR)/coff/symconst.h $(INCDIR)/coff/ecoff.h \
$(INCDIR)/coff/alpha.h $(INCDIR)/aout/ar.h libcoff.h \
libecoff.h ecoffswap.h elf64-target.h
-elf64-alpha-fbsd.lo: elf64-alpha-fbsd.c elf64-alpha.c $(INCDIR)/filenames.h \
- elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
- $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/alpha.h \
- $(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/internal.h \
- $(INCDIR)/coff/sym.h $(INCDIR)/coff/symconst.h $(INCDIR)/coff/ecoff.h \
- $(INCDIR)/coff/alpha.h $(INCDIR)/aout/ar.h libcoff.h \
- libecoff.h ecoffswap.h elf64-target.h
elf64-hppa.lo: elf64-hppa.c $(INCDIR)/alloca-conf.h \
$(INCDIR)/filenames.h elf-bfd.h $(INCDIR)/elf/common.h \
$(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h \
@@ -1502,6 +1554,13 @@ elf64-hppa.lo: elf64-hppa.c $(INCDIR)/alloca-conf.h \
elf64-gen.lo: elf64-gen.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h elf64-target.h
+elfn32-mips.lo: elfn32-mips.c $(INCDIR)/filenames.h \
+ $(INCDIR)/bfdlink.h genlink.h elf-bfd.h $(INCDIR)/elf/common.h \
+ $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h elfxx-mips.h \
+ $(INCDIR)/elf/mips.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/sym.h \
+ $(INCDIR)/coff/symconst.h $(INCDIR)/coff/internal.h \
+ $(INCDIR)/coff/ecoff.h $(INCDIR)/coff/mips.h $(INCDIR)/coff/external.h \
+ ecoffswap.h elf32-target.h
elf64-mips.lo: elf64-mips.c $(INCDIR)/filenames.h $(INCDIR)/aout/ar.h \
$(INCDIR)/bfdlink.h genlink.h elf-bfd.h $(INCDIR)/elf/common.h \
$(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h elfxx-mips.h \
@@ -1515,7 +1574,7 @@ elf64-mmix.lo: elf64-mmix.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/opcode/mmix.h elf64-target.h
elf64-ppc.lo: elf64-ppc.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
- $(INCDIR)/elf/external.h $(INCDIR)/elf/ppc.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/elf/ppc64.h $(INCDIR)/elf/reloc-macros.h \
elf64-ppc.h elf64-target.h
elf64-s390.lo: elf64-s390.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
@@ -1525,10 +1584,6 @@ elf64-sh64.lo: elf64-sh64.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
elf64-target.h
-elf64-sh64-nbsd.lo: elf64-sh64-nbsd.c elf64-sh64.c \
- $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h elf-bfd.h \
- $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
- $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h elf64-target.h
elf64-sparc.lo: elf64-sparc.c $(INCDIR)/filenames.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/opcode/sparc.h \
@@ -1537,7 +1592,7 @@ elf64-sparc.lo: elf64-sparc.c $(INCDIR)/filenames.h \
elf64.lo: elf64.c elfcode.h $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
$(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
$(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h elfcore.h \
- elflink.h
+ $(INCDIR)/safe-ctype.h
mmo.lo: mmo.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
$(INCDIR)/elf/mmix.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/opcode/mmix.h
nlm32-alpha.lo: nlm32-alpha.c $(INCDIR)/filenames.h \
@@ -1561,11 +1616,13 @@ cisco-core.lo: cisco-core.c $(INCDIR)/filenames.h
elf32-ia64.lo: elf32-ia64.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(INCDIR)/opcode/ia64.h $(INCDIR)/elf/ia64.h \
- $(INCDIR)/elf/reloc-macros.h elf32-target.h
+ $(INCDIR)/elf/reloc-macros.h $(INCDIR)/objalloc.h $(INCDIR)/hashtab.h \
+ elf32-target.h
elf64-ia64.lo: elf64-ia64.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(INCDIR)/opcode/ia64.h $(INCDIR)/elf/ia64.h \
- $(INCDIR)/elf/reloc-macros.h elf64-target.h
+ $(INCDIR)/elf/reloc-macros.h $(INCDIR)/objalloc.h $(INCDIR)/hashtab.h \
+ elf64-target.h
peigen.lo: peigen.c $(INCDIR)/filenames.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/i386.h $(INCDIR)/coff/external.h $(INCDIR)/coff/pe.h \
libcoff.h $(INCDIR)/bfdlink.h libpei.h
diff --git a/contrib/binutils/bfd/Makefile.in b/contrib/binutils/bfd/Makefile.in
index dd4ff4f..a6685f2 100644
--- a/contrib/binutils/bfd/Makefile.in
+++ b/contrib/binutils/bfd/Makefile.in
@@ -1,6 +1,6 @@
-# Makefile.in generated automatically by automake 1.4 from Makefile.am
+# Makefile.in generated automatically by automake 1.4-p6 from Makefile.am
-# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
+# Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
@@ -68,6 +68,7 @@ AS = @AS@
BFD_HOST_64BIT_LONG = @BFD_HOST_64BIT_LONG@
BFD_HOST_64_BIT = @BFD_HOST_64_BIT@
BFD_HOST_64_BIT_DEFINED = @BFD_HOST_64_BIT_DEFINED@
+BFD_HOST_LONG_LONG = @BFD_HOST_LONG_LONG@
BFD_HOST_U_64_BIT = @BFD_HOST_U_64_BIT@
CATALOGS = @CATALOGS@
CATOBJEXT = @CATOBJEXT@
@@ -115,10 +116,11 @@ WIN32LIBADD = @WIN32LIBADD@
all_backends = @all_backends@
bfd_backends = @bfd_backends@
bfd_default_target_size = @bfd_default_target_size@
+bfd_file_ptr = @bfd_file_ptr@
bfd_libs = @bfd_libs@
bfd_machines = @bfd_machines@
+bfd_ufile_ptr = @bfd_ufile_ptr@
bfd_version = @bfd_version@
-bfd_version_date = @bfd_version_date@
bfd_version_string = @bfd_version_string@
l = @l@
tdefaults = @tdefaults@
@@ -152,21 +154,23 @@ BFD_H = bfd.h
# need two copies of the executable, one to download and one for the
# debugger).
BFD32_LIBS = \
- archive.lo archures.lo bfd.lo cache.lo coffgen.lo corefile.lo \
+ archive.lo archures.lo bfd.lo bfdio.lo bfdwin.lo \
+ cache.lo coffgen.lo corefile.lo \
format.lo init.lo libbfd.lo opncls.lo reloc.lo \
section.lo syms.lo targets.lo hash.lo linker.lo \
srec.lo binary.lo tekhex.lo ihex.lo stabs.lo stab-syms.lo \
- merge.lo dwarf2.lo
+ merge.lo dwarf2.lo simple.lo
BFD64_LIBS = archive64.lo
BFD32_LIBS_CFILES = \
- archive.c archures.c bfd.c cache.c coffgen.c corefile.c \
+ archive.c archures.c bfd.c bfdio.c bfdwin.c \
+ cache.c coffgen.c corefile.c \
format.c init.c libbfd.c opncls.c reloc.c \
section.c syms.c targets.c hash.c linker.c \
srec.c binary.c tekhex.c ihex.c stabs.c stab-syms.c \
- merge.c dwarf2.c
+ merge.c dwarf2.c simple.c
BFD64_LIBS_CFILES = archive64.c
@@ -193,6 +197,8 @@ ALL_MACHINES = \
cpu-i386.lo \
cpu-i860.lo \
cpu-i960.lo \
+ cpu-ip2k.lo \
+ cpu-iq2000.lo \
cpu-m32r.lo \
cpu-m68hc11.lo \
cpu-m68hc12.lo \
@@ -203,6 +209,7 @@ ALL_MACHINES = \
cpu-mcore.lo \
cpu-mips.lo \
cpu-mmix.lo \
+ cpu-msp430.lo \
cpu-or32.lo \
cpu-ns32k.lo \
cpu-openrisc.lo \
@@ -214,6 +221,7 @@ ALL_MACHINES = \
cpu-sh.lo \
cpu-sparc.lo \
cpu-tic30.lo \
+ cpu-tic4x.lo \
cpu-tic54x.lo \
cpu-tic80.lo \
cpu-v850.lo \
@@ -221,6 +229,7 @@ ALL_MACHINES = \
cpu-we32k.lo \
cpu-w65.lo \
cpu-xstormy16.lo \
+ cpu-xtensa.lo \
cpu-z8k.lo
@@ -244,6 +253,8 @@ ALL_MACHINES_CFILES = \
cpu-i386.c \
cpu-i860.c \
cpu-i960.c \
+ cpu-ip2k.c \
+ cpu-iq2000.c \
cpu-m32r.c \
cpu-m68hc11.c \
cpu-m68hc12.c \
@@ -254,6 +265,7 @@ ALL_MACHINES_CFILES = \
cpu-mcore.c \
cpu-mips.c \
cpu-mmix.c \
+ cpu-msp430.c \
cpu-or32.c \
cpu-ns32k.c \
cpu-openrisc.c \
@@ -265,6 +277,7 @@ ALL_MACHINES_CFILES = \
cpu-sh.c \
cpu-sparc.c \
cpu-tic30.c \
+ cpu-tic4x.c \
cpu-tic54x.c \
cpu-tic80.c \
cpu-v850.c \
@@ -272,6 +285,7 @@ ALL_MACHINES_CFILES = \
cpu-we32k.c \
cpu-w65.c \
cpu-xstormy16.c \
+ cpu-xtensa.c \
cpu-z8k.c
@@ -311,6 +325,7 @@ BFD32_BACKENDS = \
coff-stgo32.lo \
coff-svm68k.lo \
coff-tic30.lo \
+ coff-tic4x.lo \
coff-tic54x.lo \
coff-tic80.lo \
coff-u68k.lo \
@@ -323,6 +338,7 @@ BFD32_BACKENDS = \
ecofflink.lo \
efi-app-ia32.lo \
elf.lo \
+ elf32-am33lin.lo \
elf32-arc.lo \
elfarm-oabi.lo \
elfarm-nabi.lo \
@@ -338,13 +354,15 @@ BFD32_BACKENDS = \
elf32-hppa.lo \
elf32-i370.lo \
elf32-i386.lo \
- elf32-i386-fbsd.lo \
elf32-i860.lo \
elf32-i960.lo \
elf32-ia64.lo \
+ elf32-ip2k.lo \
+ elf32-iq2000.lo \
elf32-m32r.lo \
elf32-m68hc11.lo \
elf32-m68hc12.lo \
+ elf32-m68hc1x.lo \
elf32-m68k.lo \
elf32-m88k.lo \
elf-m10200.lo \
@@ -352,21 +370,20 @@ BFD32_BACKENDS = \
elf32-mcore.lo \
elfxx-mips.lo \
elf32-mips.lo \
+ elf32-msp430.lo \
elf32-openrisc.lo \
elf32-or32.lo \
elf32-pj.lo \
elf32-ppc.lo \
elf32-s390.lo \
elf32-sh.lo \
- elf32-sh-lin.lo \
elf32-sh64.lo \
elf32-sh64-com.lo \
- elf32-sh-nbsd.lo \
- elf32-sh64-nbsd.lo \
elf32-sparc.lo \
elf32-v850.lo \
elf32-vax.lo \
elf32-xstormy16.lo \
+ elf32-xtensa.lo \
elf32.lo \
elflink.lo \
elf-strtab.lo \
@@ -392,6 +409,7 @@ BFD32_BACKENDS = \
m68klynx.lo \
m68knetbsd.lo \
m88kmach3.lo \
+ mach-o.lo \
mipsbsd.lo \
newsos3.lo \
nlm.lo \
@@ -403,6 +421,7 @@ BFD32_BACKENDS = \
oasys.lo \
pc532-mach.lo \
pdp11.lo \
+ pef.lo \
pe-arm.lo \
pei-arm.lo \
pe-i386.lo \
@@ -432,7 +451,10 @@ BFD32_BACKENDS = \
vms-hdr.lo \
vms-misc.lo \
vms-tir.lo \
- xcofflink.lo
+ xcofflink.lo \
+ xsym.lo \
+ xtensa-isa.lo \
+ xtensa-modules.lo
BFD32_BACKENDS_CFILES = \
@@ -469,6 +491,7 @@ BFD32_BACKENDS_CFILES = \
coff-stgo32.c \
coff-svm68k.c \
coff-tic30.c \
+ coff-tic4x.c \
coff-tic54x.c \
coff-tic80.c \
coff-u68k.c \
@@ -481,6 +504,7 @@ BFD32_BACKENDS_CFILES = \
ecofflink.c \
efi-app-ia32.c \
elf.c \
+ elf32-am33lin.c \
elf32-arc.c \
elfarm-oabi.c \
elfarm-nabi.c \
@@ -496,19 +520,22 @@ BFD32_BACKENDS_CFILES = \
elf32-hppa.c \
elf32-i370.c \
elf32-i386.c \
- elf32-i386-fbsd.c \
elf32-i860.c \
elf32-i960.c \
+ elf32-ip2k.c \
+ elf32-iq2000.c \
elf32-m32r.c \
elf32-m68k.c \
elf32-m68hc11.c \
elf32-m68hc12.c \
+ elf32-m68hc1x.c \
elf32-m88k.c \
elf-m10200.c \
elf-m10300.c \
elf32-mcore.c \
elfxx-mips.c \
elf32-mips.c \
+ elf32-msp430.c \
elf32-openrisc.c \
elf32-or32.c \
elf32-pj.c \
@@ -517,13 +544,11 @@ BFD32_BACKENDS_CFILES = \
elf32-sh64-com.c \
elf32-s390.c \
elf32-sh.c \
- elf32-sh-lin.c \
- elf32-sh-nbsd.c \
- elf32-sh64-nbsd.c \
elf32-sparc.c \
elf32-v850.c \
elf32-vax.c \
elf32-xstormy16.c \
+ elf32-xtensa.c \
elf32.c \
elflink.c \
elf-strtab.c \
@@ -549,6 +574,7 @@ BFD32_BACKENDS_CFILES = \
m68klynx.c \
m68knetbsd.c \
m88kmach3.c \
+ mach-o.c \
mipsbsd.c \
newsos3.c \
nlm.c \
@@ -560,6 +586,7 @@ BFD32_BACKENDS_CFILES = \
oasys.c \
pc532-mach.c \
pdp11.c \
+ pef.c \
pe-arm.c \
pei-arm.c \
pe-i386.c \
@@ -588,7 +615,10 @@ BFD32_BACKENDS_CFILES = \
vms-hdr.c \
vms-misc.c \
vms-tir.c \
- xcofflink.c
+ xcofflink.c \
+ xsym.c \
+ xtensa-isa.c \
+ xtensa-modules.c
# The .o files needed by all of the 64 bit vectors that are configured into
@@ -603,14 +633,13 @@ BFD64_BACKENDS = \
efi-app-ia64.lo \
elf64-x86-64.lo \
elf64-alpha.lo \
- elf64-alpha-fbsd.lo \
elf64-hppa.lo \
elf64-ia64.lo \
elf64-gen.lo \
+ elfn32-mips.lo \
elf64-mips.lo \
elf64-mmix.lo \
elf64-sh64.lo \
- elf64-sh64-nbsd.lo \
elf64-ppc.lo \
elf64-s390.lo \
elf64-sparc.lo \
@@ -630,15 +659,14 @@ BFD64_BACKENDS_CFILES = \
efi-app-ia64.c \
elf64-x86-64.c \
elf64-alpha.c \
- elf64-alpha-fbsd.c \
elf64-hppa.c \
elf64-gen.c \
+ elfn32-mips.c \
elf64-mips.c \
elf64-mmix.c \
elf64-ppc.c \
elf64-s390.c \
elf64-sh64.c \
- elf64-sh64-nbsd.c \
elf64-sparc.c \
elf64.c \
mmo.c \
@@ -696,16 +724,18 @@ CFILES = $(SOURCE_CFILES) $(BUILD_CFILES)
SOURCE_HFILES = \
aout-target.h aoutf1.h aoutx.h coffcode.h coffswap.h ecoffswap.h \
- elf-bfd.h elf-hppa.h elf32-arm.h elf32-hppa.h elf64-hppa.h \
- elfcode.h elfcore.h elflink.h freebsd.h genlink.h go32stub.h \
- libaout.h libbfd.h libcoff.h libecoff.h libhppa.h \
- libieee.h libnlm.h liboasys.h libpei.h netbsd.h nlm-target.h \
- nlmcode.h nlmswap.h ns32k.h peicode.h som.h vms.h libxcoff.h \
- xcoff-target.h version.h
+ elf-bfd.h elf-hppa.h elf32-arm.h elf32-hppa.h \
+ elf64-hppa.h elfcode.h elfcore.h \
+ freebsd.h genlink.h go32stub.h \
+ libaout.h libbfd.h libcoff.h libecoff.h libhppa.h libieee.h \
+ libnlm.h liboasys.h libpei.h libxcoff.h mach-o.h \
+ netbsd.h nlm-target.h nlmcode.h nlmswap.h ns32k.h \
+ pef.h pef-traceback.h peicode.h som.h version.h \
+ vms.h xcoff-target.h xsym.h
BUILD_HFILES = \
- elf32-target.h elf64-target.h targmatch.h
+ bfdver.h elf32-target.h elf64-target.h targmatch.h
HFILES = $(SOURCE_HFILES) $(BUILD_HFILES)
@@ -736,10 +766,13 @@ BFD_H_DEPS = $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h
LOCAL_H_DEPS = libbfd.h sysdep.h config.h
BFD_H_FILES = bfd-in.h init.c opncls.c libbfd.c section.c archures.c \
- reloc.c syms.c bfd.c archive.c corefile.c targets.c format.c version.h
+ reloc.c syms.c bfd.c bfdio.c bfdwin.c \
+ archive.c corefile.c targets.c format.c
BFD64_H_FILES = archive64.c
-LIBBFD_H_FILES = libbfd-in.h init.c libbfd.c cache.c reloc.c archures.c elf.c
+LIBBFD_H_FILES = libbfd-in.h init.c libbfd.c bfdio.c bfdwin.c \
+ cache.c reloc.c archures.c elf.c
+
LIBCOFF_H_FILES = libcoff-in.h coffcode.h
MOSTLYCLEANFILES = ofiles stamp-ofiles
@@ -752,7 +785,7 @@ DISTCLEANFILES = $(BUILD_CFILES) $(BUILD_HFILES)
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
mkinstalldirs = $(SHELL) $(top_srcdir)/../mkinstalldirs
CONFIG_HEADER = config.h
-CONFIG_CLEAN_FILES = bfd-in3.h
+CONFIG_CLEAN_FILES = bfd-in3.h bfdver.h
LIBRARIES = $(noinst_LIBRARIES)
@@ -764,10 +797,11 @@ libbfd_a_LIBADD =
libbfd_a_OBJECTS =
LTLIBRARIES = $(bfdlib_LTLIBRARIES)
-libbfd_la_OBJECTS = archive.lo archures.lo bfd.lo cache.lo coffgen.lo \
-corefile.lo format.lo init.lo libbfd.lo opncls.lo reloc.lo section.lo \
-syms.lo targets.lo hash.lo linker.lo srec.lo binary.lo tekhex.lo \
-ihex.lo stabs.lo stab-syms.lo merge.lo dwarf2.lo archive64.lo
+libbfd_la_OBJECTS = archive.lo archures.lo bfd.lo bfdio.lo bfdwin.lo \
+cache.lo coffgen.lo corefile.lo format.lo init.lo libbfd.lo opncls.lo \
+reloc.lo section.lo syms.lo targets.lo hash.lo linker.lo srec.lo \
+binary.lo tekhex.lo ihex.lo stabs.lo stab-syms.lo merge.lo dwarf2.lo \
+simple.lo archive64.lo
CFLAGS = @CFLAGS@
COMPILE = $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
@@ -775,7 +809,7 @@ CCLD = $(CC)
LINK = $(LIBTOOL) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(LDFLAGS) -o $@
DIST_COMMON = README ./stamp-h.in COPYING ChangeLog Makefile.am \
Makefile.in TODO acinclude.m4 aclocal.m4 bfd-in2.h config.in configure \
-configure.in
+configure.in version.h
DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
@@ -829,6 +863,8 @@ distclean-hdr:
maintainer-clean-hdr:
bfd-in3.h: $(top_builddir)/config.status bfd-in2.h
cd $(top_builddir) && CONFIG_FILES=$@:bfd-in2.h CONFIG_HEADERS= $(SHELL) ./config.status
+bfdver.h: $(top_builddir)/config.status version.h
+ cd $(top_builddir) && CONFIG_FILES=$@:version.h CONFIG_HEADERS= $(SHELL) ./config.status
mostlyclean-noinstLIBRARIES:
@@ -931,7 +967,7 @@ maintainer-clean-recursive:
dot_seen=no; \
rev=''; list='$(SUBDIRS)'; for subdir in $$list; do \
rev="$$subdir $$rev"; \
- test "$$subdir" = "." && dot_seen=yes; \
+ test "$$subdir" != "." || dot_seen=yes; \
done; \
test "$$dot_seen" = "no" && rev=". $$rev"; \
target=`echo $@ | sed s/-recursive//`; \
@@ -1144,22 +1180,15 @@ mostlyclean distclean maintainer-clean
po/SRC-POTFILES.in: @MAINT@ Makefile $(SRC_POTFILES)
- for file in $(SRC_POTFILES); do echo $$file; done | sort > tmp.src \
+ for file in $(SRC_POTFILES); do echo $$file; done \
+ | LC_COLLATE= sort > tmp.src \
&& mv tmp.src $(srcdir)/po/SRC-POTFILES.in
po/BLD-POTFILES.in: @MAINT@ Makefile $(BLD_POTFILES)
- for file in $(BLD_POTFILES); do echo $$file; done | sort > tmp.bld \
+ for file in $(BLD_POTFILES); do echo $$file; done \
+ | LC_COLLATE= sort > tmp.bld \
&& mv tmp.bld $(srcdir)/po/BLD-POTFILES.in
-# The following target is retained for upgrade purposes.
-# This target used to exist in older versions of this makefile, and was
-# referenced by <builddir>/po/Makefile (which is created from <srcdir>/po/Make-in)
-# So old versions of <builddir>/po/Makefile will try to regenerate themselves
-# when make is next run, but that dependency cannot be completed without a build
-# of po/POTFILES.in. Hence the presence of this rule. This rule will be deleted
-# once it is no longer needed - probably in the fall of 2001.
-po/POTFILES.in:
-
diststuff: info
stamp-ofiles: Makefile
@@ -1199,10 +1228,10 @@ targmatch.h: config.bfd targmatch.sed
# When compiling archures.c and targets.c, supply the default target
# info from configure.
-targets.lo: targets.c config.status
+targets.lo: targets.c Makefile
$(LIBTOOL) --mode=compile $(COMPILE) -c $(TDEFAULTS) $(srcdir)/targets.c
-archures.lo: archures.c config.status
+archures.lo: archures.c Makefile
$(LIBTOOL) --mode=compile $(COMPILE) -c $(TDEFAULTS) $(srcdir)/archures.c
elf32-target.h : elfxx-target.h
@@ -1364,8 +1393,9 @@ stmp-lcoff-h: $(LIBCOFF_H_FILES)
$(SHELL) $(srcdir)/../move-if-change libcoff.h-new $(srcdir)/libcoff.h
touch stmp-lcoff-h
-# We want to rerun configure if config.bfd or configure.host change.
-config.status: $(srcdir)/configure $(srcdir)/config.bfd $(srcdir)/configure.host
+# We want to rerun configure if config.bfd, configure.host or version.h change.
+config.status: $(srcdir)/configure $(srcdir)/config.bfd \
+ $(srcdir)/configure.host $(srcdir)/version.h
$(SHELL) ./config.status --recheck
# What appears below is generated by a hacked mkdep using gcc -MM.
@@ -1375,11 +1405,13 @@ config.status: $(srcdir)/configure $(srcdir)/config.bfd $(srcdir)/configure.host
archive.lo: archive.c $(INCDIR)/filenames.h $(INCDIR)/aout/ar.h \
$(INCDIR)/aout/ranlib.h $(INCDIR)/safe-ctype.h
archures.lo: archures.c $(INCDIR)/filenames.h $(INCDIR)/safe-ctype.h
-bfd.lo: bfd.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
+bfd.lo: bfd.c bfdver.h $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
$(INCDIR)/safe-ctype.h $(INCDIR)/bfdlink.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/sym.h libcoff.h libecoff.h $(INCDIR)/coff/ecoff.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h
+bfdio.lo: bfdio.c $(INCDIR)/filenames.h
+bfdwin.lo: bfdwin.c $(INCDIR)/filenames.h
cache.lo: cache.c $(INCDIR)/filenames.h
coffgen.lo: coffgen.c $(INCDIR)/filenames.h $(INCDIR)/coff/internal.h \
libcoff.h $(INCDIR)/bfdlink.h
@@ -1387,7 +1419,8 @@ corefile.lo: corefile.c $(INCDIR)/filenames.h
format.lo: format.c $(INCDIR)/filenames.h
init.lo: init.c $(INCDIR)/filenames.h
libbfd.lo: libbfd.c $(INCDIR)/filenames.h
-opncls.lo: opncls.c $(INCDIR)/filenames.h $(INCDIR)/objalloc.h
+opncls.lo: opncls.c $(INCDIR)/filenames.h $(INCDIR)/objalloc.h \
+ $(INCDIR)/libiberty.h
reloc.lo: reloc.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h
section.lo: section.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h
syms.lo: syms.c $(INCDIR)/filenames.h $(INCDIR)/safe-ctype.h \
@@ -1412,11 +1445,12 @@ merge.lo: merge.c $(INCDIR)/filenames.h $(INCDIR)/hashtab.h \
dwarf2.lo: dwarf2.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/dwarf2.h
+simple.lo: simple.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h
archive64.lo: archive64.c $(INCDIR)/filenames.h $(INCDIR)/aout/ar.h
cpu-a29k.lo: cpu-a29k.c $(INCDIR)/filenames.h
cpu-alpha.lo: cpu-alpha.c $(INCDIR)/filenames.h
cpu-arc.lo: cpu-arc.c $(INCDIR)/filenames.h
-cpu-arm.lo: cpu-arm.c $(INCDIR)/filenames.h
+cpu-arm.lo: cpu-arm.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h
cpu-avr.lo: cpu-avr.c $(INCDIR)/filenames.h
cpu-cris.lo: cpu-cris.c $(INCDIR)/filenames.h
cpu-d10v.lo: cpu-d10v.c $(INCDIR)/filenames.h
@@ -1433,6 +1467,8 @@ cpu-i370.lo: cpu-i370.c $(INCDIR)/filenames.h
cpu-i386.lo: cpu-i386.c $(INCDIR)/filenames.h
cpu-i860.lo: cpu-i860.c $(INCDIR)/filenames.h
cpu-i960.lo: cpu-i960.c $(INCDIR)/filenames.h
+cpu-ip2k.lo: cpu-ip2k.c $(INCDIR)/filenames.h
+cpu-iq2000.lo: cpu-iq2000.c $(INCDIR)/filenames.h
cpu-m32r.lo: cpu-m32r.c $(INCDIR)/filenames.h
cpu-m68hc11.lo: cpu-m68hc11.c $(INCDIR)/filenames.h
cpu-m68hc12.lo: cpu-m68hc12.c $(INCDIR)/filenames.h
@@ -1443,6 +1479,7 @@ cpu-m10300.lo: cpu-m10300.c $(INCDIR)/filenames.h
cpu-mcore.lo: cpu-mcore.c $(INCDIR)/filenames.h
cpu-mips.lo: cpu-mips.c $(INCDIR)/filenames.h
cpu-mmix.lo: cpu-mmix.c $(INCDIR)/filenames.h
+cpu-msp430.lo: cpu-msp430.c $(INCDIR)/filenames.h
cpu-or32.lo: cpu-or32.c $(INCDIR)/filenames.h
cpu-ns32k.lo: cpu-ns32k.c $(INCDIR)/filenames.h ns32k.h
cpu-openrisc.lo: cpu-openrisc.c $(INCDIR)/filenames.h
@@ -1454,6 +1491,7 @@ cpu-s390.lo: cpu-s390.c $(INCDIR)/filenames.h
cpu-sh.lo: cpu-sh.c $(INCDIR)/filenames.h
cpu-sparc.lo: cpu-sparc.c $(INCDIR)/filenames.h
cpu-tic30.lo: cpu-tic30.c $(INCDIR)/filenames.h
+cpu-tic4x.lo: cpu-tic4x.c $(INCDIR)/filenames.h
cpu-tic54x.lo: cpu-tic54x.c $(INCDIR)/filenames.h
cpu-tic80.lo: cpu-tic80.c $(INCDIR)/filenames.h
cpu-v850.lo: cpu-v850.c $(INCDIR)/filenames.h $(INCDIR)/safe-ctype.h
@@ -1461,6 +1499,7 @@ cpu-vax.lo: cpu-vax.c $(INCDIR)/filenames.h
cpu-we32k.lo: cpu-we32k.c $(INCDIR)/filenames.h
cpu-w65.lo: cpu-w65.c $(INCDIR)/filenames.h
cpu-xstormy16.lo: cpu-xstormy16.c $(INCDIR)/filenames.h
+cpu-xtensa.lo: cpu-xtensa.c $(INCDIR)/filenames.h
cpu-z8k.lo: cpu-z8k.c $(INCDIR)/filenames.h
aout-adobe.lo: aout-adobe.c $(INCDIR)/filenames.h $(INCDIR)/aout/adobe.h \
$(INCDIR)/aout/stab_gnu.h $(INCDIR)/aout/stab.def libaout.h \
@@ -1523,7 +1562,8 @@ coff-aux.lo: coff-aux.c $(INCDIR)/filenames.h $(INCDIR)/coff/aux-coff.h \
coffswap.h
coff-h8300.lo: coff-h8300.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
genlink.h $(INCDIR)/coff/h8300.h $(INCDIR)/coff/external.h \
- $(INCDIR)/coff/internal.h libcoff.h coffcode.h coffswap.h
+ $(INCDIR)/coff/internal.h libcoff.h $(INCDIR)/libiberty.h \
+ coffcode.h coffswap.h
coff-h8500.lo: coff-h8500.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
$(INCDIR)/coff/h8500.h $(INCDIR)/coff/external.h $(INCDIR)/coff/internal.h \
libcoff.h coffcode.h coffswap.h
@@ -1572,6 +1612,9 @@ coff-svm68k.lo: coff-svm68k.c coff-m68k.c $(INCDIR)/filenames.h \
coff-tic30.lo: coff-tic30.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
$(INCDIR)/coff/tic30.h $(INCDIR)/coff/external.h $(INCDIR)/coff/internal.h \
libcoff.h coffcode.h coffswap.h
+coff-tic4x.lo: coff-tic4x.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
+ $(INCDIR)/coff/tic4x.h $(INCDIR)/coff/ti.h $(INCDIR)/coff/internal.h \
+ libcoff.h coffcode.h coffswap.h
coff-tic54x.lo: coff-tic54x.c $(INCDIR)/filenames.h \
$(INCDIR)/bfdlink.h $(INCDIR)/coff/tic54x.h $(INCDIR)/coff/ti.h \
$(INCDIR)/coff/internal.h libcoff.h coffcode.h coffswap.h
@@ -1591,7 +1634,7 @@ coff-z8k.lo: coff-z8k.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
$(INCDIR)/coff/z8k.h $(INCDIR)/coff/external.h $(INCDIR)/coff/internal.h \
libcoff.h coffcode.h coffswap.h
cofflink.lo: cofflink.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
- $(INCDIR)/coff/internal.h libcoff.h
+ $(INCDIR)/coff/internal.h libcoff.h $(INCDIR)/safe-ctype.h
dwarf1.lo: dwarf1.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/dwarf.h
@@ -1611,6 +1654,10 @@ efi-app-ia32.lo: efi-app-ia32.c $(INCDIR)/filenames.h \
elf.lo: elf.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/libiberty.h
+elf32-am33lin.lo: elf32-am33lin.c elf-m10300.c $(INCDIR)/filenames.h \
+ elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/mn10300.h \
+ $(INCDIR)/elf/reloc-macros.h elf32-target.h
elf32-arc.lo: elf32-arc.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(INCDIR)/elf/arc.h $(INCDIR)/elf/reloc-macros.h \
@@ -1650,7 +1697,7 @@ elf32-fr30.lo: elf32-fr30.c $(INCDIR)/filenames.h elf-bfd.h \
elf32-frv.lo: elf32-frv.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(INCDIR)/elf/frv.h $(INCDIR)/elf/reloc-macros.h \
- elf32-target.h
+ $(INCDIR)/elf/dwarf2.h $(INCDIR)/hashtab.h elf32-target.h
elf32-gen.lo: elf32-gen.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h elf32-target.h
@@ -1664,15 +1711,12 @@ elf32-hppa.lo: elf32-hppa.c $(INCDIR)/filenames.h elf-bfd.h \
libhppa.h elf32-hppa.h elf-hppa.h elf32-target.h
elf32-i370.lo: elf32-i370.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
- $(INCDIR)/elf/external.h $(INCDIR)/elf/i370.h elf32-target.h
+ $(INCDIR)/elf/external.h $(INCDIR)/elf/i370.h $(INCDIR)/elf/reloc-macros.h \
+ elf32-target.h
elf32-i386.lo: elf32-i386.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/elf/i386.h $(INCDIR)/elf/reloc-macros.h \
elf32-target.h
-elf32-i386-fbsd.lo: elf32-i386-fbsd.c elf32-i386.c $(INCDIR)/filenames.h \
- $(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
- $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/elf/i386.h \
- $(INCDIR)/elf/reloc-macros.h elf32-target.h
elf32-i860.lo: elf32-i860.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(INCDIR)/elf/i860.h $(INCDIR)/elf/reloc-macros.h \
@@ -1681,6 +1725,14 @@ elf32-i960.lo: elf32-i960.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(INCDIR)/elf/i960.h $(INCDIR)/elf/reloc-macros.h \
elf32-target.h
+elf32-ip2k.lo: elf32-ip2k.c $(INCDIR)/filenames.h elf-bfd.h \
+ $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
+ $(INCDIR)/bfdlink.h $(INCDIR)/elf/ip2k.h $(INCDIR)/elf/reloc-macros.h \
+ elf32-target.h
+elf32-iq2000.lo: elf32-iq2000.c $(INCDIR)/filenames.h \
+ elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/iq2000.h \
+ $(INCDIR)/elf/reloc-macros.h elf32-target.h
elf32-m32r.lo: elf32-m32r.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(INCDIR)/elf/m32r.h $(INCDIR)/elf/reloc-macros.h \
@@ -1690,13 +1742,20 @@ elf32-m68k.lo: elf32-m68k.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
$(INCDIR)/elf/external.h $(INCDIR)/elf/m68k.h $(INCDIR)/elf/reloc-macros.h \
elf32-target.h
elf32-m68hc11.lo: elf32-m68hc11.c $(INCDIR)/filenames.h \
- elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
- $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/m68hc11.h \
- $(INCDIR)/elf/reloc-macros.h elf32-target.h
+ $(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
+ $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h elf32-m68hc1x.h \
+ $(INCDIR)/elf/m68hc11.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/opcode/m68hc11.h elf32-target.h
elf32-m68hc12.lo: elf32-m68hc12.c $(INCDIR)/filenames.h \
- elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
- $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/m68hc11.h \
- $(INCDIR)/elf/reloc-macros.h elf32-target.h
+ $(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
+ $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h elf32-m68hc1x.h \
+ $(INCDIR)/elf/m68hc11.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/opcode/m68hc11.h elf32-target.h
+elf32-m68hc1x.lo: elf32-m68hc1x.c $(INCDIR)/filenames.h \
+ $(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
+ $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h elf32-m68hc1x.h \
+ $(INCDIR)/elf/m68hc11.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/opcode/m68hc11.h
elf32-m88k.lo: elf32-m88k.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h elf32-target.h
@@ -1711,17 +1770,23 @@ elf32-mcore.lo: elf32-mcore.c $(INCDIR)/filenames.h \
$(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
$(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/elf/mcore.h \
$(INCDIR)/elf/reloc-macros.h elf32-target.h
-elfxx-mips.lo: elfxx-mips.c $(INCDIR)/filenames.h elf-bfd.h \
- $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
- $(INCDIR)/bfdlink.h elfxx-mips.h $(INCDIR)/elf/mips.h \
- $(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/sym.h $(INCDIR)/coff/symconst.h \
- $(INCDIR)/coff/ecoff.h $(INCDIR)/coff/mips.h $(INCDIR)/coff/external.h
+elfxx-mips.lo: elfxx-mips.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
+ elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h elfxx-mips.h \
+ $(INCDIR)/elf/mips.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/sym.h \
+ $(INCDIR)/coff/symconst.h $(INCDIR)/coff/ecoff.h $(INCDIR)/coff/mips.h \
+ $(INCDIR)/coff/external.h $(INCDIR)/hashtab.h
elf32-mips.lo: elf32-mips.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
genlink.h elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h elfxx-mips.h $(INCDIR)/elf/mips.h \
$(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/sym.h $(INCDIR)/coff/symconst.h \
$(INCDIR)/coff/internal.h $(INCDIR)/coff/ecoff.h $(INCDIR)/coff/mips.h \
$(INCDIR)/coff/external.h ecoffswap.h elf32-target.h
+elf32-msp430.lo: elf32-msp430.c $(INCDIR)/filenames.h \
+ $(INCDIR)/libiberty.h elf-bfd.h $(INCDIR)/elf/common.h \
+ $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h \
+ $(INCDIR)/elf/msp430.h $(INCDIR)/elf/reloc-macros.h \
+ elf32-target.h
elf32-openrisc.lo: elf32-openrisc.c $(INCDIR)/filenames.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/openrisc.h \
@@ -1738,16 +1803,16 @@ elf32-pj.lo: elf32-pj.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf32-ppc.lo: elf32-ppc.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/elf/ppc.h $(INCDIR)/elf/reloc-macros.h \
- elf32-target.h
+ elf32-ppc.h elf32-target.h
elf32-sh64.lo: elf32-sh64.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(srcdir)/../opcodes/sh64-opc.h \
- elf32-sh.c $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
+ elf32-sh64.h elf32-sh.c $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
elf32-target.h
elf32-sh64-com.lo: elf32-sh64-com.c $(INCDIR)/filenames.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/sh.h \
- $(INCDIR)/elf/reloc-macros.h $(srcdir)/../opcodes/sh64-opc.h
+ $(INCDIR)/elf/reloc-macros.h elf32-sh64.h $(srcdir)/../opcodes/sh64-opc.h
elf32-s390.lo: elf32-s390.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/elf/s390.h $(INCDIR)/elf/reloc-macros.h \
@@ -1756,19 +1821,6 @@ elf32-sh.lo: elf32-sh.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
elf32-target.h
-elf32-sh-lin.lo: elf32-sh-lin.c $(INCDIR)/filenames.h \
- $(INCDIR)/elf/internal.h elf-bfd.h $(INCDIR)/elf/common.h \
- $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h elf32-sh.c \
- $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h elf32-target.h
-elf32-sh-nbsd.lo: elf32-sh-nbsd.c elf32-sh.c $(INCDIR)/filenames.h \
- $(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
- $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/elf/sh.h \
- $(INCDIR)/elf/reloc-macros.h elf32-target.h
-elf32-sh64-nbsd.lo: elf32-sh64-nbsd.c elf32-sh64.c \
- $(INCDIR)/filenames.h elf-bfd.h $(INCDIR)/elf/common.h \
- $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h \
- $(srcdir)/../opcodes/sh64-opc.h elf32-sh.c $(INCDIR)/elf/sh.h \
- $(INCDIR)/elf/reloc-macros.h elf32-target.h
elf32-sparc.lo: elf32-sparc.c $(INCDIR)/filenames.h \
$(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
$(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/elf/sparc.h \
@@ -1787,13 +1839,18 @@ elf32-xstormy16.lo: elf32-xstormy16.c $(INCDIR)/filenames.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/xstormy16.h \
$(INCDIR)/elf/reloc-macros.h $(INCDIR)/libiberty.h \
elf32-target.h
+elf32-xtensa.lo: elf32-xtensa.c $(INCDIR)/filenames.h \
+ $(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
+ $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/elf/xtensa.h \
+ $(INCDIR)/elf/reloc-macros.h $(INCDIR)/xtensa-isa.h \
+ $(INCDIR)/xtensa-config.h elf32-target.h
elf32.lo: elf32.c elfcode.h $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
$(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
$(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h elfcore.h \
- elflink.h
+ $(INCDIR)/safe-ctype.h
elflink.lo: elflink.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
- $(INCDIR)/elf/external.h
+ $(INCDIR)/elf/external.h $(INCDIR)/libiberty.h
elf-strtab.lo: elf-strtab.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(INCDIR)/hashtab.h $(INCDIR)/libiberty.h
@@ -1863,6 +1920,8 @@ m68knetbsd.lo: m68knetbsd.c netbsd.h $(INCDIR)/filenames.h \
m88kmach3.lo: m88kmach3.c $(INCDIR)/filenames.h libaout.h \
$(INCDIR)/bfdlink.h aout-target.h $(INCDIR)/aout/aout64.h \
$(INCDIR)/aout/stab_gnu.h $(INCDIR)/aout/stab.def $(INCDIR)/aout/ar.h
+mach-o.lo: mach-o.c mach-o.h $(INCDIR)/filenames.h \
+ $(INCDIR)/libiberty.h mach-o-target.c
mipsbsd.lo: mipsbsd.c $(INCDIR)/filenames.h libaout.h \
$(INCDIR)/bfdlink.h aout-target.h $(INCDIR)/aout/aout64.h \
$(INCDIR)/aout/stab_gnu.h $(INCDIR)/aout/stab.def $(INCDIR)/aout/ar.h
@@ -1894,6 +1953,8 @@ pc532-mach.lo: pc532-mach.c $(INCDIR)/filenames.h libaout.h \
pdp11.lo: pdp11.c $(INCDIR)/filenames.h libaout.h $(INCDIR)/bfdlink.h \
aout-target.h $(INCDIR)/aout/aout64.h $(INCDIR)/aout/stab_gnu.h \
$(INCDIR)/aout/stab.def $(INCDIR)/aout/ar.h $(INCDIR)/safe-ctype.h
+pef.lo: pef.c $(INCDIR)/safe-ctype.h pef.h pef-traceback.h \
+ $(INCDIR)/filenames.h $(INCDIR)/libiberty.h
pe-arm.lo: pe-arm.c $(INCDIR)/filenames.h coff-arm.c \
$(INCDIR)/coff/arm.h $(INCDIR)/coff/external.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/pe.h libcoff.h $(INCDIR)/bfdlink.h coffcode.h \
@@ -1977,8 +2038,8 @@ vms.lo: vms.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
vms.h
vms-gsd.lo: vms-gsd.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
vms.h
-vms-hdr.lo: vms-hdr.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
- $(INCDIR)/safe-ctype.h vms.h
+vms-hdr.lo: vms-hdr.c bfdver.h $(INCDIR)/filenames.h \
+ $(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h vms.h
vms-misc.lo: vms-misc.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
vms.h
vms-tir.lo: vms-tir.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
@@ -1986,6 +2047,11 @@ vms-tir.lo: vms-tir.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
xcofflink.lo: xcofflink.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
$(INCDIR)/coff/internal.h $(INCDIR)/coff/xcoff.h libcoff.h \
libxcoff.h
+xsym.lo: xsym.c xsym.h $(INCDIR)/filenames.h
+xtensa-isa.lo: xtensa-isa.c $(INCDIR)/xtensa-isa.h \
+ $(INCDIR)/xtensa-isa-internal.h
+xtensa-modules.lo: xtensa-modules.c $(INCDIR)/xtensa-isa.h \
+ $(INCDIR)/xtensa-isa-internal.h
aix5ppc-core.lo: aix5ppc-core.c
aout64.lo: aout64.c aoutx.h $(INCDIR)/filenames.h $(INCDIR)/safe-ctype.h \
$(INCDIR)/bfdlink.h libaout.h $(INCDIR)/aout/aout64.h \
@@ -2017,13 +2083,6 @@ elf64-alpha.lo: elf64-alpha.c $(INCDIR)/filenames.h \
$(INCDIR)/coff/sym.h $(INCDIR)/coff/symconst.h $(INCDIR)/coff/ecoff.h \
$(INCDIR)/coff/alpha.h $(INCDIR)/aout/ar.h libcoff.h \
libecoff.h ecoffswap.h elf64-target.h
-elf64-alpha-fbsd.lo: elf64-alpha-fbsd.c elf64-alpha.c $(INCDIR)/filenames.h \
- elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
- $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/alpha.h \
- $(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/internal.h \
- $(INCDIR)/coff/sym.h $(INCDIR)/coff/symconst.h $(INCDIR)/coff/ecoff.h \
- $(INCDIR)/coff/alpha.h $(INCDIR)/aout/ar.h libcoff.h \
- libecoff.h ecoffswap.h elf64-target.h
elf64-hppa.lo: elf64-hppa.c $(INCDIR)/alloca-conf.h \
$(INCDIR)/filenames.h elf-bfd.h $(INCDIR)/elf/common.h \
$(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h \
@@ -2032,6 +2091,13 @@ elf64-hppa.lo: elf64-hppa.c $(INCDIR)/alloca-conf.h \
elf64-gen.lo: elf64-gen.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h elf64-target.h
+elfn32-mips.lo: elfn32-mips.c $(INCDIR)/filenames.h \
+ $(INCDIR)/bfdlink.h genlink.h elf-bfd.h $(INCDIR)/elf/common.h \
+ $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h elfxx-mips.h \
+ $(INCDIR)/elf/mips.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/sym.h \
+ $(INCDIR)/coff/symconst.h $(INCDIR)/coff/internal.h \
+ $(INCDIR)/coff/ecoff.h $(INCDIR)/coff/mips.h $(INCDIR)/coff/external.h \
+ ecoffswap.h elf32-target.h
elf64-mips.lo: elf64-mips.c $(INCDIR)/filenames.h $(INCDIR)/aout/ar.h \
$(INCDIR)/bfdlink.h genlink.h elf-bfd.h $(INCDIR)/elf/common.h \
$(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h elfxx-mips.h \
@@ -2045,7 +2111,7 @@ elf64-mmix.lo: elf64-mmix.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/opcode/mmix.h elf64-target.h
elf64-ppc.lo: elf64-ppc.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
- $(INCDIR)/elf/external.h $(INCDIR)/elf/ppc.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/elf/ppc64.h $(INCDIR)/elf/reloc-macros.h \
elf64-ppc.h elf64-target.h
elf64-s390.lo: elf64-s390.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
@@ -2055,10 +2121,6 @@ elf64-sh64.lo: elf64-sh64.c $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
elf64-target.h
-elf64-sh64-nbsd.lo: elf64-sh64-nbsd.c elf64-sh64.c \
- $(INCDIR)/filenames.h $(INCDIR)/bfdlink.h elf-bfd.h \
- $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
- $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h elf64-target.h
elf64-sparc.lo: elf64-sparc.c $(INCDIR)/filenames.h \
elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/opcode/sparc.h \
@@ -2067,7 +2129,7 @@ elf64-sparc.lo: elf64-sparc.c $(INCDIR)/filenames.h \
elf64.lo: elf64.c elfcode.h $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
$(INCDIR)/bfdlink.h elf-bfd.h $(INCDIR)/elf/common.h \
$(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h elfcore.h \
- elflink.h
+ $(INCDIR)/safe-ctype.h
mmo.lo: mmo.c $(INCDIR)/filenames.h $(INCDIR)/libiberty.h \
$(INCDIR)/elf/mmix.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/opcode/mmix.h
nlm32-alpha.lo: nlm32-alpha.c $(INCDIR)/filenames.h \
@@ -2091,11 +2153,13 @@ cisco-core.lo: cisco-core.c $(INCDIR)/filenames.h
elf32-ia64.lo: elf32-ia64.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(INCDIR)/opcode/ia64.h $(INCDIR)/elf/ia64.h \
- $(INCDIR)/elf/reloc-macros.h elf32-target.h
+ $(INCDIR)/elf/reloc-macros.h $(INCDIR)/objalloc.h $(INCDIR)/hashtab.h \
+ elf32-target.h
elf64-ia64.lo: elf64-ia64.c $(INCDIR)/filenames.h elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
$(INCDIR)/bfdlink.h $(INCDIR)/opcode/ia64.h $(INCDIR)/elf/ia64.h \
- $(INCDIR)/elf/reloc-macros.h elf64-target.h
+ $(INCDIR)/elf/reloc-macros.h $(INCDIR)/objalloc.h $(INCDIR)/hashtab.h \
+ elf64-target.h
peigen.lo: peigen.c $(INCDIR)/filenames.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/i386.h $(INCDIR)/coff/external.h $(INCDIR)/coff/pe.h \
libcoff.h $(INCDIR)/bfdlink.h libpei.h
diff --git a/contrib/binutils/bfd/acinclude.m4 b/contrib/binutils/bfd/acinclude.m4
index b3c6ccff..63b4bf9 100644
--- a/contrib/binutils/bfd/acinclude.m4
+++ b/contrib/binutils/bfd/acinclude.m4
@@ -1,5 +1,7 @@
+sinclude(../config/accross.m4)
+
dnl See whether we need to use fopen-bin.h rather than fopen-same.h.
-AC_DEFUN(BFD_BINARY_FOPEN,
+AC_DEFUN([BFD_BINARY_FOPEN],
[AC_REQUIRE([AC_CANONICAL_SYSTEM])
case "${host}" in
changequote(,)dnl
@@ -9,7 +11,7 @@ changequote([,])dnl
esac])dnl
dnl Get a default for CC_FOR_BUILD to put into Makefile.
-AC_DEFUN(BFD_CC_FOR_BUILD,
+AC_DEFUN([BFD_CC_FOR_BUILD],
[# Put a plausible default for CC_FOR_BUILD in Makefile.
if test -z "$CC_FOR_BUILD"; then
if test "x$cross_compiling" = "xno"; then
@@ -42,7 +44,7 @@ fi
AC_SUBST(EXEEXT_FOR_BUILD)])dnl
dnl See whether we need a declaration for a function.
-AC_DEFUN(BFD_NEED_DECLARATION,
+AC_DEFUN([BFD_NEED_DECLARATION],
[AC_MSG_CHECKING([whether $1 must be declared])
AC_CACHE_VAL(bfd_cv_decl_needed_$1,
[AC_TRY_COMPILE([
@@ -71,7 +73,7 @@ fi
dnl Check for existence of a type $1 in sys/procfs.h
-AC_DEFUN(BFD_HAVE_SYS_PROCFS_TYPE,
+AC_DEFUN([BFD_HAVE_SYS_PROCFS_TYPE],
[AC_MSG_CHECKING([for $1 in sys/procfs.h])
AC_CACHE_VAL(bfd_cv_have_sys_procfs_type_$1,
[AC_TRY_COMPILE([
@@ -91,7 +93,7 @@ AC_DEFUN(BFD_HAVE_SYS_PROCFS_TYPE,
dnl Check for existence of member $2 in type $1 in sys/procfs.h
-AC_DEFUN(BFD_HAVE_SYS_PROCFS_TYPE_MEMBER,
+AC_DEFUN([BFD_HAVE_SYS_PROCFS_TYPE_MEMBER],
[AC_MSG_CHECKING([for $1.$2 in sys/procfs.h])
AC_CACHE_VAL(bfd_cv_have_sys_procfs_type_member_$1_$2,
[AC_TRY_COMPILE([
@@ -127,9 +129,9 @@ AC_SUBST(INTLLIBS)
AC_DEFUN([AM_INSTALL_LIBBFD],
[AC_MSG_CHECKING([whether to install libbfd])
AC_ARG_ENABLE(install-libbfd,
-[ --install-libbfd controls installation of libbfd and related headers],
+[ --enable-install-libbfd controls installation of libbfd and related headers],
install_libbfd_p=$enableval,
- if test "${host}" = "${target}" -o "$enable_shared" = "yes"; then
+ if test "${host}" = "${target}" || test "$enable_shared" = "yes"; then
install_libbfd_p=yes
else
install_libbfd_p=no
diff --git a/contrib/binutils/bfd/aclocal.m4 b/contrib/binutils/bfd/aclocal.m4
index b6dfcbe..9d27670 100644
--- a/contrib/binutils/bfd/aclocal.m4
+++ b/contrib/binutils/bfd/aclocal.m4
@@ -1,4 +1,4 @@
-dnl aclocal.m4 generated automatically by aclocal 1.4-p5
+dnl aclocal.m4 generated automatically by aclocal 1.4-p6
dnl Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc.
dnl This file is free software; the Free Software Foundation
@@ -10,6 +10,8 @@ dnl but WITHOUT ANY WARRANTY, to the extent permitted by law; without
dnl even the implied warranty of MERCHANTABILITY or FITNESS FOR A
dnl PARTICULAR PURPOSE.
+sinclude(../config/accross.m4)
+
dnl See whether we need to use fopen-bin.h rather than fopen-same.h.
AC_DEFUN(BFD_BINARY_FOPEN,
[AC_REQUIRE([AC_CANONICAL_SYSTEM])
@@ -139,9 +141,9 @@ AC_SUBST(INTLLIBS)
AC_DEFUN([AM_INSTALL_LIBBFD],
[AC_MSG_CHECKING([whether to install libbfd])
AC_ARG_ENABLE(install-libbfd,
-[ --install-libbfd controls installation of libbfd and related headers],
+[ --enable-install-libbfd controls installation of libbfd and related headers],
install_libbfd_p=$enableval,
- if test "${host}" = "${target}" -o "$enable_shared" = "yes"; then
+ if test "${host}" = "${target}" || test "$enable_shared" = "yes"; then
install_libbfd_p=yes
else
install_libbfd_p=no
@@ -173,6 +175,33 @@ else
$1_FALSE=
fi])
+# isc-posix.m4 serial 2 (gettext-0.11.2)
+dnl Copyright (C) 1995-2002 Free Software Foundation, Inc.
+dnl This file is free software, distributed under the terms of the GNU
+dnl General Public License. As a special exception to the GNU General
+dnl Public License, this file may be distributed as part of a program
+dnl that contains a configuration script generated by Autoconf, under
+dnl the same distribution terms as the rest of that program.
+
+# This file is not needed with autoconf-2.53 and newer. Remove it in 2005.
+
+# This test replaces the one in autoconf.
+# Currently this macro should have the same name as the autoconf macro
+# because gettext's gettext.m4 (distributed in the automake package)
+# still uses it. Otherwise, the use in gettext.m4 makes autoheader
+# give these diagnostics:
+# configure.in:556: AC_TRY_COMPILE was called before AC_ISC_POSIX
+# configure.in:556: AC_TRY_RUN was called before AC_ISC_POSIX
+
+undefine([AC_ISC_POSIX])
+
+AC_DEFUN([AC_ISC_POSIX],
+ [
+ dnl This test replaces the obsolescent AC_ISC_POSIX kludge.
+ AC_CHECK_LIB(cposix, strerror, [LIBS="$LIBS -lcposix"])
+ ]
+)
+
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
@@ -183,7 +212,8 @@ dnl Usage:
dnl AM_INIT_AUTOMAKE(package,version, [no-define])
AC_DEFUN([AM_INIT_AUTOMAKE],
-[AC_REQUIRE([AC_PROG_INSTALL])
+[AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
+AC_REQUIRE([AC_PROG_INSTALL])
PACKAGE=[$1]
AC_SUBST(PACKAGE)
VERSION=[$2]
@@ -199,13 +229,42 @@ AC_REQUIRE([AM_SANITY_CHECK])
AC_REQUIRE([AC_ARG_PROGRAM])
dnl FIXME This is truly gross.
missing_dir=`cd $ac_aux_dir && pwd`
-AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
+AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}, $missing_dir)
AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
-AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
+AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}, $missing_dir)
AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
AC_REQUIRE([AC_PROG_MAKE_SET])])
+# Copyright 2002 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+
+# AM_AUTOMAKE_VERSION(VERSION)
+# ----------------------------
+# Automake X.Y traces this macro to ensure aclocal.m4 has been
+# generated from the m4 files accompanying Automake X.Y.
+AC_DEFUN([AM_AUTOMAKE_VERSION],[am__api_version="1.4"])
+
+# AM_SET_CURRENT_AUTOMAKE_VERSION
+# -------------------------------
+# Call AM_AUTOMAKE_VERSION so it can be traced.
+# This function is AC_REQUIREd by AC_INIT_AUTOMAKE.
+AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
+ [AM_AUTOMAKE_VERSION([1.4-p6])])
+
#
# Check to make sure that the build environment is sane.
#
diff --git a/contrib/binutils/bfd/aout-arm.c b/contrib/binutils/bfd/aout-arm.c
index b87e09c..38ecfab 100644
--- a/contrib/binutils/bfd/aout-arm.c
+++ b/contrib/binutils/bfd/aout-arm.c
@@ -1,5 +1,5 @@
/* BFD back-end for raw ARM a.out binaries.
- Copyright 1994, 1995, 1997, 1998, 1999, 2000, 2001
+ Copyright 1994, 1995, 1997, 1998, 1999, 2000, 2001, 2002
Free Software Foundation, Inc.
Contributed by Richard Earnshaw (rwe@pegasus.esprit.ec.org)
@@ -22,7 +22,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "bfd.h"
#include "sysdep.h"
-/* Avoid multiple defininitions from aoutx if supporting standarad a.out
+/* Avoid multiple definitions from aoutx if supporting standard a.out
as well as our own. */
/* Do not "beautify" the CONCAT* macro args. Traditional C will not
remove whitespace added here, and thus will fail to concatenate
@@ -54,7 +54,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "libaout.h"
#include "aout/aout64.h"
-static boolean MY(write_object_contents)
+static bfd_boolean MY(write_object_contents)
PARAMS ((bfd *));
static bfd_reloc_status_type MY(fix_pcrel_26_done)
PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
@@ -80,28 +80,28 @@ reloc_howto_type MY(howto_table)[] =
{
/* Type rs size bsz pcrel bitpos ovrf sf name part_inpl
readmask setmask pcdone. */
- HOWTO (0, 0, 0, 8, false, 0, complain_overflow_bitfield, 0, "8", true,
- 0x000000ff, 0x000000ff, false),
- HOWTO (1, 0, 1, 16, false, 0, complain_overflow_bitfield, 0, "16", true,
- 0x0000ffff, 0x0000ffff, false),
- HOWTO (2, 0, 2, 32, false, 0, complain_overflow_bitfield, 0, "32", true,
- 0xffffffff, 0xffffffff, false),
- HOWTO (3, 2, 2, 26, true, 0, complain_overflow_signed, MY(fix_pcrel_26),
- "ARM26", true, 0x00ffffff, 0x00ffffff, true),
- HOWTO (4, 0, 0, 8, true, 0, complain_overflow_signed, 0, "DISP8", true,
- 0x000000ff, 0x000000ff, true),
- HOWTO (5, 0, 1, 16, true, 0, complain_overflow_signed, 0, "DISP16", true,
- 0x0000ffff, 0x0000ffff, true),
- HOWTO (6, 0, 2, 32, true, 0, complain_overflow_signed, 0, "DISP32", true,
- 0xffffffff, 0xffffffff, true),
- HOWTO (7, 2, 2, 26, false, 0, complain_overflow_signed,
- MY(fix_pcrel_26_done), "ARM26D", true, 0x0, 0x0,
- false),
+ HOWTO (0, 0, 0, 8, FALSE, 0, complain_overflow_bitfield, 0, "8", TRUE,
+ 0x000000ff, 0x000000ff, FALSE),
+ HOWTO (1, 0, 1, 16, FALSE, 0, complain_overflow_bitfield, 0, "16", TRUE,
+ 0x0000ffff, 0x0000ffff, FALSE),
+ HOWTO (2, 0, 2, 32, FALSE, 0, complain_overflow_bitfield, 0, "32", TRUE,
+ 0xffffffff, 0xffffffff, FALSE),
+ HOWTO (3, 2, 2, 26, TRUE, 0, complain_overflow_signed, MY(fix_pcrel_26),
+ "ARM26", TRUE, 0x00ffffff, 0x00ffffff, TRUE),
+ HOWTO (4, 0, 0, 8, TRUE, 0, complain_overflow_signed, 0, "DISP8", TRUE,
+ 0x000000ff, 0x000000ff, TRUE),
+ HOWTO (5, 0, 1, 16, TRUE, 0, complain_overflow_signed, 0, "DISP16", TRUE,
+ 0x0000ffff, 0x0000ffff, TRUE),
+ HOWTO (6, 0, 2, 32, TRUE, 0, complain_overflow_signed, 0, "DISP32", TRUE,
+ 0xffffffff, 0xffffffff, TRUE),
+ HOWTO (7, 2, 2, 26, FALSE, 0, complain_overflow_signed,
+ MY(fix_pcrel_26_done), "ARM26D", TRUE, 0x0, 0x0,
+ FALSE),
EMPTY_HOWTO (-1),
- HOWTO (9, 0, -1, 16, false, 0, complain_overflow_bitfield, 0, "NEG16", true,
- 0x0000ffff, 0x0000ffff, false),
- HOWTO (10, 0, -2, 32, false, 0, complain_overflow_bitfield, 0, "NEG32", true,
- 0xffffffff, 0xffffffff, false)
+ HOWTO (9, 0, -1, 16, FALSE, 0, complain_overflow_bitfield, 0, "NEG16", TRUE,
+ 0x0000ffff, 0x0000ffff, FALSE),
+ HOWTO (10, 0, -2, 32, FALSE, 0, complain_overflow_bitfield, 0, "NEG32", TRUE,
+ 0xffffffff, 0xffffffff, FALSE)
};
#define RELOC_ARM_BITS_NEG_BIG ((unsigned int) 0x08)
diff --git a/contrib/binutils/bfd/aout-encap.c b/contrib/binutils/bfd/aout-encap.c
index 84c46c6..96c7082 100644
--- a/contrib/binutils/bfd/aout-encap.c
+++ b/contrib/binutils/bfd/aout-encap.c
@@ -1,5 +1,5 @@
/* BFD back-end for a.out files encapsulated with COFF headers.
- Copyright 1990, 1991, 1994, 1995, 2000, 2001
+ Copyright 1990, 1991, 1994, 1995, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -24,7 +24,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define TARGET_PAGE_SIZE 4096
#define SEGMENT_SIZE TARGET_PAGE_SIZE
#define TEXT_START_ADDR 0
-#define BYTES_IN_WORD 4
#endif
#include "bfd.h"
@@ -123,7 +122,7 @@ encap_real_callback (abfd)
Section contents have already been written. We write the
file header, symbols, and relocation. */
-boolean
+bfd_boolean
encap_write_object_contents (abfd)
bfd *abfd;
{
@@ -230,7 +229,7 @@ encap_write_object_contents (abfd)
text_size -= N_TXTOFF (outheader);
WRITE_HEADERS(abfd, execp);
- return true;
+ return TRUE;
}
#define MY_write_object_content encap_write_object_contents
diff --git a/contrib/binutils/bfd/aout-target.h b/contrib/binutils/bfd/aout-target.h
index b2acc09..d8cad54 100644
--- a/contrib/binutils/bfd/aout-target.h
+++ b/contrib/binutils/bfd/aout-target.h
@@ -1,6 +1,6 @@
/* Define a target vector and some small routines for a variant of a.out.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -201,21 +201,21 @@ MY(object_p) (abfd)
#ifndef MY_mkobject
-static boolean MY(mkobject) PARAMS ((bfd *));
+static bfd_boolean MY(mkobject) PARAMS ((bfd *));
-static boolean
+static bfd_boolean
MY(mkobject) (abfd)
bfd *abfd;
{
if (! NAME(aout,mkobject) (abfd))
- return false;
+ return FALSE;
#if 0 /* Sizes get set in set_sizes callback, later, after we know
the architecture and machine. */
adata(abfd).page_size = TARGET_PAGE_SIZE;
adata(abfd).segment_size = SEGMENT_SIZE;
adata(abfd).exec_bytes_size = EXEC_BYTES_SIZE;
#endif
- return true;
+ return TRUE;
}
#define MY_mkobject MY(mkobject)
#endif
@@ -228,10 +228,10 @@ MY(mkobject) (abfd)
section contents, and copy_private_bfd_data is not called until
after the section contents have been set. */
-static boolean MY_bfd_copy_private_section_data
+static bfd_boolean MY_bfd_copy_private_section_data
PARAMS ((bfd *, asection *, bfd *, asection *));
-static boolean
+static bfd_boolean
MY_bfd_copy_private_section_data (ibfd, isec, obfd, osec)
bfd *ibfd;
asection *isec ATTRIBUTE_UNUSED;
@@ -241,7 +241,7 @@ MY_bfd_copy_private_section_data (ibfd, isec, obfd, osec)
if (bfd_get_flavour (ibfd) == bfd_target_aout_flavour
&& bfd_get_flavour (obfd) == bfd_target_aout_flavour)
obj_aout_subformat (obfd) = obj_aout_subformat (ibfd);
- return true;
+ return TRUE;
}
#endif
@@ -251,9 +251,9 @@ MY_bfd_copy_private_section_data (ibfd, isec, obfd, osec)
file header, symbols, and relocation. */
#ifndef MY_write_object_contents
-static boolean MY(write_object_contents) PARAMS ((bfd *));
+static bfd_boolean MY(write_object_contents) PARAMS ((bfd *));
-static boolean
+static bfd_boolean
MY(write_object_contents) (abfd)
bfd *abfd;
{
@@ -264,16 +264,16 @@ MY(write_object_contents) (abfd)
WRITE_HEADERS(abfd, execp);
- return true;
+ return TRUE;
}
#define MY_write_object_contents MY(write_object_contents)
#endif
#ifndef MY_set_sizes
-static boolean MY(set_sizes) PARAMS ((bfd *));
+static bfd_boolean MY(set_sizes) PARAMS ((bfd *));
-static boolean
+static bfd_boolean
MY(set_sizes) (abfd)
bfd *abfd;
{
@@ -287,7 +287,7 @@ MY(set_sizes) (abfd)
#endif
adata(abfd).exec_bytes_size = EXEC_BYTES_SIZE;
- return true;
+ return TRUE;
}
#define MY_set_sizes MY(set_sizes)
#endif
@@ -375,9 +375,9 @@ MY_final_link_callback (abfd, ptreloff, pdreloff, psymoff)
/* Final link routine. We need to use a call back to get the correct
offsets in the output file. */
-static boolean MY_bfd_final_link PARAMS ((bfd *, struct bfd_link_info *));
+static bfd_boolean MY_bfd_final_link PARAMS ((bfd *, struct bfd_link_info *));
-static boolean
+static bfd_boolean
MY_bfd_final_link (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -443,7 +443,7 @@ MY_bfd_final_link (abfd, info)
#endif
#ifndef MY_bfd_debug_info_accumulate
#define MY_bfd_debug_info_accumulate \
- (void (*) PARAMS ((bfd*, struct sec *))) bfd_void
+ (void (*) PARAMS ((bfd*, struct bfd_section *))) bfd_void
#endif
#ifndef MY_core_file_failing_command
@@ -470,8 +470,8 @@ MY_bfd_final_link (abfd, info)
#ifndef MY_get_symtab_upper_bound
#define MY_get_symtab_upper_bound NAME(aout,get_symtab_upper_bound)
#endif
-#ifndef MY_get_symtab
-#define MY_get_symtab NAME(aout,get_symtab)
+#ifndef MY_canonicalize_symtab
+#define MY_canonicalize_symtab NAME(aout,canonicalize_symtab)
#endif
#ifndef MY_get_reloc_upper_bound
#define MY_get_reloc_upper_bound NAME(aout,get_reloc_upper_bound)
diff --git a/contrib/binutils/bfd/aoutf1.h b/contrib/binutils/bfd/aoutf1.h
index 80d69d9..352dadf 100644
--- a/contrib/binutils/bfd/aoutf1.h
+++ b/contrib/binutils/bfd/aoutf1.h
@@ -1,6 +1,6 @@
/* A.out "format 1" file handling code for BFD.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000,
- 2001, 2002
+ 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Support.
@@ -75,15 +75,24 @@ The name put into the target vector.
#define sunos_write_object_contents aout_32_sunos4_write_object_contents
#endif
-static boolean sunos_merge_private_bfd_data PARAMS ((bfd *, bfd *));
-static void sunos_set_arch_mach PARAMS ((bfd *, enum machine_type));
-static void choose_reloc_size PARAMS ((bfd *));
-static boolean sunos_write_object_contents PARAMS ((bfd *));
-static const bfd_target *sunos4_core_file_p PARAMS ((bfd *));
-static char *sunos4_core_file_failing_command PARAMS ((bfd *));
-static int sunos4_core_file_failing_signal PARAMS ((bfd *));
-static boolean sunos4_core_file_matches_executable_p PARAMS ((bfd *, bfd *));
-static boolean sunos4_set_sizes PARAMS ((bfd *));
+static bfd_boolean sunos_merge_private_bfd_data
+ PARAMS ((bfd *, bfd *));
+static void sunos_set_arch_mach
+ PARAMS ((bfd *, enum machine_type));
+static void choose_reloc_size
+ PARAMS ((bfd *));
+static bfd_boolean sunos_write_object_contents
+ PARAMS ((bfd *));
+static const bfd_target *sunos4_core_file_p
+ PARAMS ((bfd *));
+static char *sunos4_core_file_failing_command
+ PARAMS ((bfd *));
+static int sunos4_core_file_failing_signal
+ PARAMS ((bfd *));
+static bfd_boolean sunos4_core_file_matches_executable_p
+ PARAMS ((bfd *, bfd *));
+static bfd_boolean sunos4_set_sizes
+ PARAMS ((bfd *));
/* Merge backend data into the output file.
This is necessary on sparclet-aout where we want the resultant machine
@@ -91,13 +100,13 @@ static boolean sunos4_set_sizes PARAMS ((bfd *));
#define MY_bfd_merge_private_bfd_data sunos_merge_private_bfd_data
-static boolean
+static bfd_boolean
sunos_merge_private_bfd_data (ibfd, obfd)
bfd *ibfd, *obfd;
{
if (bfd_get_flavour (ibfd) != bfd_target_aout_flavour
|| bfd_get_flavour (obfd) != bfd_target_aout_flavour)
- return true;
+ return TRUE;
if (bfd_get_arch (obfd) == bfd_arch_sparc)
{
@@ -105,7 +114,7 @@ sunos_merge_private_bfd_data (ibfd, obfd)
bfd_set_arch_mach (obfd, bfd_arch_sparc, bfd_get_mach (ibfd));
}
- return true;
+ return TRUE;
}
/* This is either sunos_32_set_arch_mach or sunos_64_set_arch_mach,
@@ -207,7 +216,7 @@ choose_reloc_size (abfd)
aout_64_sunos4_write_object_contents or
aout_32_sunos4_write_object_contents, depending upon ARCH_SIZE. */
-static boolean
+static bfd_boolean
sunos_write_object_contents (abfd)
bfd *abfd;
{
@@ -264,7 +273,7 @@ sunos_write_object_contents (abfd)
WRITE_HEADERS (abfd, execp);
- return true;
+ return TRUE;
}
/* core files */
@@ -731,7 +740,7 @@ sunos4_core_file_failing_signal (abfd)
return core_hdr (abfd)->hdr->c_signo;
}
-static boolean
+static bfd_boolean
sunos4_core_file_matches_executable_p (core_bfd, exec_bfd)
bfd *core_bfd;
bfd *exec_bfd;
@@ -739,12 +748,12 @@ sunos4_core_file_matches_executable_p (core_bfd, exec_bfd)
if (core_bfd->xvec != exec_bfd->xvec)
{
bfd_set_error (bfd_error_system_call);
- return false;
+ return FALSE;
}
/* Solaris core files do not include an aouthdr. */
if ((core_hdr (core_bfd)->hdr)->c_len == SOLARIS_BCP_CORE_LEN)
- return true;
+ return TRUE;
return (memcmp ((char *) &((core_hdr (core_bfd)->hdr)->c_aouthdr),
(char *) exec_hdr (exec_bfd),
@@ -752,24 +761,24 @@ sunos4_core_file_matches_executable_p (core_bfd, exec_bfd)
}
#define MY_set_sizes sunos4_set_sizes
-static boolean
+static bfd_boolean
sunos4_set_sizes (abfd)
bfd *abfd;
{
switch (bfd_get_arch (abfd))
{
default:
- return false;
+ return FALSE;
case bfd_arch_sparc:
adata (abfd).page_size = 0x2000;
adata (abfd).segment_size = 0x2000;
adata (abfd).exec_bytes_size = EXEC_BYTES_SIZE;
- return true;
+ return TRUE;
case bfd_arch_m68k:
adata (abfd).page_size = 0x2000;
adata (abfd).segment_size = 0x20000;
adata (abfd).exec_bytes_size = EXEC_BYTES_SIZE;
- return true;
+ return TRUE;
}
}
@@ -825,7 +834,7 @@ static const struct aout_backend_data sunos4_aout_backend =
#define MY_bfd_debug_info_start bfd_void
#define MY_bfd_debug_info_end bfd_void
#define MY_bfd_debug_info_accumulate \
- (void (*) PARAMS ((bfd *, struct sec *))) bfd_void
+ (void (*) PARAMS ((bfd *, struct bfd_section *))) bfd_void
#define MY_core_file_p sunos4_core_file_p
#define MY_write_object_contents NAME(aout,sunos4_write_object_contents)
#define MY_backend_data &sunos4_aout_backend
diff --git a/contrib/binutils/bfd/aoutx.h b/contrib/binutils/bfd/aoutx.h
index 70359d6..3282f87 100644
--- a/contrib/binutils/bfd/aoutx.h
+++ b/contrib/binutils/bfd/aoutx.h
@@ -1,24 +1,24 @@
/* BFD semi-generic back-end for a.out binaries.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000,
- 2001, 2002
+ 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Support.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/*
SECTION
@@ -105,9 +105,7 @@ DESCRIPTION
in the @file{config/@var{XXX}.mt} file, and modify @file{configure.in}
to use the
@file{@var{XXX}.mt} file (by setting "<<bfd_target=XXX>>") when your
- configuration is selected.
-
-*/
+ configuration is selected. */
/* Some assumptions:
* Any BFD with D_PAGED set is ZMAGIC, and vice versa.
@@ -131,14 +129,18 @@ DESCRIPTION
#include "aout/stab_gnu.h"
#include "aout/ar.h"
-static boolean aout_get_external_symbols PARAMS ((bfd *));
-static boolean translate_from_native_sym_flags
+static bfd_boolean aout_get_external_symbols
+ PARAMS ((bfd *));
+static bfd_boolean translate_from_native_sym_flags
PARAMS ((bfd *, aout_symbol_type *));
-static boolean translate_to_native_sym_flags
+static bfd_boolean translate_to_native_sym_flags
PARAMS ((bfd *, asymbol *, struct external_nlist *));
-static void adjust_o_magic PARAMS ((bfd *, struct internal_exec *));
-static void adjust_z_magic PARAMS ((bfd *, struct internal_exec *));
-static void adjust_n_magic PARAMS ((bfd *, struct internal_exec *));
+static void adjust_o_magic
+ PARAMS ((bfd *, struct internal_exec *));
+static void adjust_z_magic
+ PARAMS ((bfd *, struct internal_exec *));
+static void adjust_n_magic
+ PARAMS ((bfd *, struct internal_exec *));
reloc_howto_type * NAME(aout,reloc_type_lookup)
PARAMS ((bfd *, bfd_reloc_code_real_type));
@@ -153,9 +155,8 @@ DESCRIPTION
The standard records contain only an
address, a symbol index, and a type field. The extended records
(used on 29ks and sparcs) also have a full integer for an
- addend.
+ addend. */
-*/
#ifndef CTOR_TABLE_RELOC_HOWTO
#define CTOR_TABLE_RELOC_IDX 2
#define CTOR_TABLE_RELOC_HOWTO(BFD) \
@@ -193,58 +194,59 @@ DESCRIPTION
reloc_howto_type howto_table_ext[] =
{
- /* type rs size bsz pcrel bitpos ovrf sf name part_inpl readmask setmask pcdone */
- HOWTO(RELOC_8, 0, 0, 8, false, 0, complain_overflow_bitfield,0,"8", false, 0,0x000000ff, false),
- HOWTO(RELOC_16, 0, 1, 16, false, 0, complain_overflow_bitfield,0,"16", false, 0,0x0000ffff, false),
- HOWTO(RELOC_32, 0, 2, 32, false, 0, complain_overflow_bitfield,0,"32", false, 0,0xffffffff, false),
- HOWTO(RELOC_DISP8, 0, 0, 8, true, 0, complain_overflow_signed,0,"DISP8", false, 0,0x000000ff, false),
- HOWTO(RELOC_DISP16, 0, 1, 16, true, 0, complain_overflow_signed,0,"DISP16", false, 0,0x0000ffff, false),
- HOWTO(RELOC_DISP32, 0, 2, 32, true, 0, complain_overflow_signed,0,"DISP32", false, 0,0xffffffff, false),
- HOWTO(RELOC_WDISP30,2, 2, 30, true, 0, complain_overflow_signed,0,"WDISP30", false, 0,0x3fffffff, false),
- HOWTO(RELOC_WDISP22,2, 2, 22, true, 0, complain_overflow_signed,0,"WDISP22", false, 0,0x003fffff, false),
- HOWTO(RELOC_HI22, 10, 2, 22, false, 0, complain_overflow_bitfield,0,"HI22", false, 0,0x003fffff, false),
- HOWTO(RELOC_22, 0, 2, 22, false, 0, complain_overflow_bitfield,0,"22", false, 0,0x003fffff, false),
- HOWTO(RELOC_13, 0, 2, 13, false, 0, complain_overflow_bitfield,0,"13", false, 0,0x00001fff, false),
- HOWTO(RELOC_LO10, 0, 2, 10, false, 0, complain_overflow_dont,0,"LO10", false, 0,0x000003ff, false),
- HOWTO(RELOC_SFA_BASE,0, 2, 32, false, 0, complain_overflow_bitfield,0,"SFA_BASE", false, 0,0xffffffff, false),
- HOWTO(RELOC_SFA_OFF13,0,2, 32, false, 0, complain_overflow_bitfield,0,"SFA_OFF13",false, 0,0xffffffff, false),
- HOWTO(RELOC_BASE10, 0, 2, 10, false, 0, complain_overflow_dont,0,"BASE10", false, 0,0x000003ff, false),
- HOWTO(RELOC_BASE13, 0, 2, 13, false, 0, complain_overflow_signed,0,"BASE13", false, 0,0x00001fff, false),
- HOWTO(RELOC_BASE22, 10, 2, 22, false, 0, complain_overflow_bitfield,0,"BASE22", false, 0,0x003fffff, false),
- HOWTO(RELOC_PC10, 0, 2, 10, true, 0, complain_overflow_dont,0,"PC10", false, 0,0x000003ff, true),
- HOWTO(RELOC_PC22, 10, 2, 22, true, 0, complain_overflow_signed,0,"PC22", false, 0,0x003fffff, true),
- HOWTO(RELOC_JMP_TBL,2, 2, 30, true, 0, complain_overflow_signed,0,"JMP_TBL", false, 0,0x3fffffff, false),
- HOWTO(RELOC_SEGOFF16,0, 2, 0, false, 0, complain_overflow_bitfield,0,"SEGOFF16", false, 0,0x00000000, false),
- HOWTO(RELOC_GLOB_DAT,0, 2, 0, false, 0, complain_overflow_bitfield,0,"GLOB_DAT", false, 0,0x00000000, false),
- HOWTO(RELOC_JMP_SLOT,0, 2, 0, false, 0, complain_overflow_bitfield,0,"JMP_SLOT", false, 0,0x00000000, false),
- HOWTO(RELOC_RELATIVE,0, 2, 0, false, 0, complain_overflow_bitfield,0,"RELATIVE", false, 0,0x00000000, false),
- HOWTO(0, 0, 0, 0, false, 0, complain_overflow_dont, 0, "R_SPARC_NONE", false,0,0x00000000,true),
- HOWTO(0, 0, 0, 0, false, 0, complain_overflow_dont, 0, "R_SPARC_NONE", false,0,0x00000000,true),
+ /* type rs size bsz pcrel bitpos ovrf sf name part_inpl readmask setmask pcdone. */
+ HOWTO(RELOC_8, 0, 0, 8, FALSE, 0, complain_overflow_bitfield,0,"8", FALSE, 0,0x000000ff, FALSE),
+ HOWTO(RELOC_16, 0, 1, 16, FALSE, 0, complain_overflow_bitfield,0,"16", FALSE, 0,0x0000ffff, FALSE),
+ HOWTO(RELOC_32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,0,"32", FALSE, 0,0xffffffff, FALSE),
+ HOWTO(RELOC_DISP8, 0, 0, 8, TRUE, 0, complain_overflow_signed,0,"DISP8", FALSE, 0,0x000000ff, FALSE),
+ HOWTO(RELOC_DISP16, 0, 1, 16, TRUE, 0, complain_overflow_signed,0,"DISP16", FALSE, 0,0x0000ffff, FALSE),
+ HOWTO(RELOC_DISP32, 0, 2, 32, TRUE, 0, complain_overflow_signed,0,"DISP32", FALSE, 0,0xffffffff, FALSE),
+ HOWTO(RELOC_WDISP30,2, 2, 30, TRUE, 0, complain_overflow_signed,0,"WDISP30", FALSE, 0,0x3fffffff, FALSE),
+ HOWTO(RELOC_WDISP22,2, 2, 22, TRUE, 0, complain_overflow_signed,0,"WDISP22", FALSE, 0,0x003fffff, FALSE),
+ HOWTO(RELOC_HI22, 10, 2, 22, FALSE, 0, complain_overflow_bitfield,0,"HI22", FALSE, 0,0x003fffff, FALSE),
+ HOWTO(RELOC_22, 0, 2, 22, FALSE, 0, complain_overflow_bitfield,0,"22", FALSE, 0,0x003fffff, FALSE),
+ HOWTO(RELOC_13, 0, 2, 13, FALSE, 0, complain_overflow_bitfield,0,"13", FALSE, 0,0x00001fff, FALSE),
+ HOWTO(RELOC_LO10, 0, 2, 10, FALSE, 0, complain_overflow_dont,0,"LO10", FALSE, 0,0x000003ff, FALSE),
+ HOWTO(RELOC_SFA_BASE,0, 2, 32, FALSE, 0, complain_overflow_bitfield,0,"SFA_BASE", FALSE, 0,0xffffffff, FALSE),
+ HOWTO(RELOC_SFA_OFF13,0,2, 32, FALSE, 0, complain_overflow_bitfield,0,"SFA_OFF13",FALSE, 0,0xffffffff, FALSE),
+ HOWTO(RELOC_BASE10, 0, 2, 10, FALSE, 0, complain_overflow_dont,0,"BASE10", FALSE, 0,0x000003ff, FALSE),
+ HOWTO(RELOC_BASE13, 0, 2, 13, FALSE, 0, complain_overflow_signed,0,"BASE13", FALSE, 0,0x00001fff, FALSE),
+ HOWTO(RELOC_BASE22, 10, 2, 22, FALSE, 0, complain_overflow_bitfield,0,"BASE22", FALSE, 0,0x003fffff, FALSE),
+ HOWTO(RELOC_PC10, 0, 2, 10, TRUE, 0, complain_overflow_dont,0,"PC10", FALSE, 0,0x000003ff, TRUE),
+ HOWTO(RELOC_PC22, 10, 2, 22, TRUE, 0, complain_overflow_signed,0,"PC22", FALSE, 0,0x003fffff, TRUE),
+ HOWTO(RELOC_JMP_TBL,2, 2, 30, TRUE, 0, complain_overflow_signed,0,"JMP_TBL", FALSE, 0,0x3fffffff, FALSE),
+ HOWTO(RELOC_SEGOFF16,0, 2, 0, FALSE, 0, complain_overflow_bitfield,0,"SEGOFF16", FALSE, 0,0x00000000, FALSE),
+ HOWTO(RELOC_GLOB_DAT,0, 2, 0, FALSE, 0, complain_overflow_bitfield,0,"GLOB_DAT", FALSE, 0,0x00000000, FALSE),
+ HOWTO(RELOC_JMP_SLOT,0, 2, 0, FALSE, 0, complain_overflow_bitfield,0,"JMP_SLOT", FALSE, 0,0x00000000, FALSE),
+ HOWTO(RELOC_RELATIVE,0, 2, 0, FALSE, 0, complain_overflow_bitfield,0,"RELATIVE", FALSE, 0,0x00000000, FALSE),
+ HOWTO(0, 0, 0, 0, FALSE, 0, complain_overflow_dont, 0, "R_SPARC_NONE", FALSE,0,0x00000000,TRUE),
+ HOWTO(0, 0, 0, 0, FALSE, 0, complain_overflow_dont, 0, "R_SPARC_NONE", FALSE,0,0x00000000,TRUE),
#define RELOC_SPARC_REV32 RELOC_WDISP19
- HOWTO(RELOC_SPARC_REV32, 0, 2, 32, false, 0, complain_overflow_dont,0,"R_SPARC_REV32", false, 0,0xffffffff, false),
+ HOWTO(RELOC_SPARC_REV32, 0, 2, 32, FALSE, 0, complain_overflow_dont,0,"R_SPARC_REV32", FALSE, 0,0xffffffff, FALSE),
};
/* Convert standard reloc records to "arelent" format (incl byte swap). */
-reloc_howto_type howto_table_std[] = {
- /* type rs size bsz pcrel bitpos ovrf sf name part_inpl readmask setmask pcdone */
-HOWTO ( 0, 0, 0, 8, false, 0, complain_overflow_bitfield,0,"8", true, 0x000000ff,0x000000ff, false),
-HOWTO ( 1, 0, 1, 16, false, 0, complain_overflow_bitfield,0,"16", true, 0x0000ffff,0x0000ffff, false),
-HOWTO ( 2, 0, 2, 32, false, 0, complain_overflow_bitfield,0,"32", true, 0xffffffff,0xffffffff, false),
-HOWTO ( 3, 0, 4, 64, false, 0, complain_overflow_bitfield,0,"64", true, 0xdeaddead,0xdeaddead, false),
-HOWTO ( 4, 0, 0, 8, true, 0, complain_overflow_signed, 0,"DISP8", true, 0x000000ff,0x000000ff, false),
-HOWTO ( 5, 0, 1, 16, true, 0, complain_overflow_signed, 0,"DISP16", true, 0x0000ffff,0x0000ffff, false),
-HOWTO ( 6, 0, 2, 32, true, 0, complain_overflow_signed, 0,"DISP32", true, 0xffffffff,0xffffffff, false),
-HOWTO ( 7, 0, 4, 64, true, 0, complain_overflow_signed, 0,"DISP64", true, 0xfeedface,0xfeedface, false),
-HOWTO ( 8, 0, 2, 0, false, 0, complain_overflow_bitfield,0,"GOT_REL", false, 0,0x00000000, false),
-HOWTO ( 9, 0, 1, 16, false, 0, complain_overflow_bitfield,0,"BASE16", false,0xffffffff,0xffffffff, false),
-HOWTO (10, 0, 2, 32, false, 0, complain_overflow_bitfield,0,"BASE32", false,0xffffffff,0xffffffff, false),
+reloc_howto_type howto_table_std[] =
+{
+ /* type rs size bsz pcrel bitpos ovrf sf name part_inpl readmask setmask pcdone. */
+HOWTO ( 0, 0, 0, 8, FALSE, 0, complain_overflow_bitfield,0,"8", TRUE, 0x000000ff,0x000000ff, FALSE),
+HOWTO ( 1, 0, 1, 16, FALSE, 0, complain_overflow_bitfield,0,"16", TRUE, 0x0000ffff,0x0000ffff, FALSE),
+HOWTO ( 2, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,0,"32", TRUE, 0xffffffff,0xffffffff, FALSE),
+HOWTO ( 3, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,0,"64", TRUE, 0xdeaddead,0xdeaddead, FALSE),
+HOWTO ( 4, 0, 0, 8, TRUE, 0, complain_overflow_signed, 0,"DISP8", TRUE, 0x000000ff,0x000000ff, FALSE),
+HOWTO ( 5, 0, 1, 16, TRUE, 0, complain_overflow_signed, 0,"DISP16", TRUE, 0x0000ffff,0x0000ffff, FALSE),
+HOWTO ( 6, 0, 2, 32, TRUE, 0, complain_overflow_signed, 0,"DISP32", TRUE, 0xffffffff,0xffffffff, FALSE),
+HOWTO ( 7, 0, 4, 64, TRUE, 0, complain_overflow_signed, 0,"DISP64", TRUE, 0xfeedface,0xfeedface, FALSE),
+HOWTO ( 8, 0, 2, 0, FALSE, 0, complain_overflow_bitfield,0,"GOT_REL", FALSE, 0,0x00000000, FALSE),
+HOWTO ( 9, 0, 1, 16, FALSE, 0, complain_overflow_bitfield,0,"BASE16", FALSE,0xffffffff,0xffffffff, FALSE),
+HOWTO (10, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,0,"BASE32", FALSE,0xffffffff,0xffffffff, FALSE),
EMPTY_HOWTO (-1),
EMPTY_HOWTO (-1),
EMPTY_HOWTO (-1),
EMPTY_HOWTO (-1),
EMPTY_HOWTO (-1),
- HOWTO (16, 0, 2, 0, false, 0, complain_overflow_bitfield,0,"JMP_TABLE", false, 0,0x00000000, false),
+ HOWTO (16, 0, 2, 0, FALSE, 0, complain_overflow_bitfield,0,"JMP_TABLE", FALSE, 0,0x00000000, FALSE),
EMPTY_HOWTO (-1),
EMPTY_HOWTO (-1),
EMPTY_HOWTO (-1),
@@ -260,7 +262,7 @@ EMPTY_HOWTO (-1),
EMPTY_HOWTO (-1),
EMPTY_HOWTO (-1),
EMPTY_HOWTO (-1),
- HOWTO (32, 0, 2, 0, false, 0, complain_overflow_bitfield,0,"RELATIVE", false, 0,0x00000000, false),
+ HOWTO (32, 0, 2, 0, FALSE, 0, complain_overflow_bitfield,0,"RELATIVE", FALSE, 0,0x00000000, FALSE),
EMPTY_HOWTO (-1),
EMPTY_HOWTO (-1),
EMPTY_HOWTO (-1),
@@ -268,7 +270,7 @@ EMPTY_HOWTO (-1),
EMPTY_HOWTO (-1),
EMPTY_HOWTO (-1),
EMPTY_HOWTO (-1),
- HOWTO (40, 0, 2, 0, false, 0, complain_overflow_bitfield,0,"BASEREL", false, 0,0x00000000, false),
+ HOWTO (40, 0, 2, 0, FALSE, 0, complain_overflow_bitfield,0,"BASEREL", FALSE, 0,0x00000000, FALSE),
};
#define TABLE_SIZE(TABLE) (sizeof (TABLE) / sizeof (TABLE[0]))
@@ -281,6 +283,7 @@ NAME(aout,reloc_type_lookup) (abfd,code)
#define EXT(i, j) case i: return &howto_table_ext[j]
#define STD(i, j) case i: return &howto_table_std[j]
int ext = obj_reloc_entry_size (abfd) == RELOC_EXT_SIZE;
+
if (code == BFD_RELOC_CTOR)
switch (bfd_get_arch_info (abfd)->bits_per_address)
{
@@ -291,6 +294,7 @@ NAME(aout,reloc_type_lookup) (abfd,code)
code = BFD_RELOC_64;
break;
}
+
if (ext)
switch (code)
{
@@ -313,9 +317,10 @@ NAME(aout,reloc_type_lookup) (abfd,code)
default: return (reloc_howto_type *) NULL;
}
else
- /* std relocs */
+ /* std relocs. */
switch (code)
{
+ STD (BFD_RELOC_8, 0);
STD (BFD_RELOC_16, 1);
STD (BFD_RELOC_32, 2);
STD (BFD_RELOC_8_PCREL, 4);
@@ -416,20 +421,20 @@ NAME(aout,swap_exec_header_out) (abfd, execp, raw_bytes)
/* Make all the section for an a.out file. */
-boolean
+bfd_boolean
NAME(aout,make_sections) (abfd)
bfd *abfd;
{
if (obj_textsec (abfd) == (asection *) NULL
&& bfd_make_section (abfd, ".text") == (asection *) NULL)
- return false;
+ return FALSE;
if (obj_datasec (abfd) == (asection *) NULL
&& bfd_make_section (abfd, ".data") == (asection *) NULL)
- return false;
+ return FALSE;
if (obj_bsssec (abfd) == (asection *) NULL
&& bfd_make_section (abfd, ".bss") == (asection *) NULL)
- return false;
- return true;
+ return FALSE;
+ return TRUE;
}
/*
@@ -474,14 +479,15 @@ NAME(aout,some_aout_object_p) (abfd, execp, callback_to_real_object_p)
*abfd->tdata.aout_data = *oldrawptr;
abfd->tdata.aout_data->a.hdr = &rawptr->e;
- *(abfd->tdata.aout_data->a.hdr) = *execp; /* Copy in the internal_exec struct */
+ /* Copy in the internal_exec struct. */
+ *(abfd->tdata.aout_data->a.hdr) = *execp;
execp = abfd->tdata.aout_data->a.hdr;
- /* Set the file flags */
+ /* Set the file flags. */
abfd->flags = BFD_NO_FLAGS;
if (execp->a_drsize || execp->a_trsize)
abfd->flags |= HAS_RELOC;
- /* Setting of EXEC_P has been deferred to the bottom of this function */
+ /* Setting of EXEC_P has been deferred to the bottom of this function. */
if (execp->a_syms)
abfd->flags |= HAS_LINENO | HAS_DEBUG | HAS_SYMS | HAS_LOCALS;
if (N_DYNAMIC (*execp))
@@ -563,18 +569,18 @@ NAME(aout,some_aout_object_p) (abfd, execp, callback_to_real_object_p)
obj_textsec (abfd)->size = N_TXTSIZE (*execp);
obj_textsec (abfd)->raw_size = N_TXTSIZE (*execp);
- /* data and bss are already filled in since they're so standard */
+ /* Data and bss are already filled in since they're so standard. */
- /* The virtual memory addresses of the sections */
+ /* The virtual memory addresses of the sections. */
obj_textsec (abfd)->vma = N_TXTADDR (*execp);
obj_datasec (abfd)->vma = N_DATADDR (*execp);
obj_bsssec (abfd)->vma = N_BSSADDR (*execp);
- /* The file offsets of the sections */
+ /* The file offsets of the sections. */
obj_textsec (abfd)->filepos = N_TXTOFF (*execp);
obj_datasec (abfd)->filepos = N_DATOFF (*execp);
- /* The file offsets of the relocation info */
+ /* The file offsets of the relocation info. */
obj_textsec (abfd)->rel_filepos = N_TRELOFF (*execp);
obj_datasec (abfd)->rel_filepos = N_DRELOFF (*execp);
@@ -669,13 +675,13 @@ FUNCTION
aout_@var{size}_mkobject
SYNOPSIS
- boolean aout_@var{size}_mkobject, (bfd *abfd);
+ bfd_boolean aout_@var{size}_mkobject, (bfd *abfd);
DESCRIPTION
Initialize BFD @var{abfd} for use with a.out files.
*/
-boolean
+bfd_boolean
NAME(aout,mkobject) (abfd)
bfd *abfd;
{
@@ -686,7 +692,7 @@ NAME(aout,mkobject) (abfd)
rawptr = (struct aout_data_struct *) bfd_zalloc (abfd, amt);
if (rawptr == NULL)
- return false;
+ return FALSE;
abfd->tdata.aout_data = rawptr;
exec_hdr (abfd) = &(rawptr->e);
@@ -695,7 +701,7 @@ NAME(aout,mkobject) (abfd)
obj_datasec (abfd) = (asection *) NULL;
obj_bsssec (abfd) = (asection *) NULL;
- return true;
+ return TRUE;
}
/*
@@ -721,12 +727,12 @@ enum machine_type
NAME(aout,machine_type) (arch, machine, unknown)
enum bfd_architecture arch;
unsigned long machine;
- boolean *unknown;
+ bfd_boolean *unknown;
{
enum machine_type arch_flags;
arch_flags = M_UNKNOWN;
- *unknown = true;
+ *unknown = TRUE;
switch (arch)
{
@@ -745,7 +751,7 @@ NAME(aout,machine_type) (arch, machine, unknown)
switch (machine)
{
case 0: arch_flags = M_68010; break;
- case bfd_mach_m68000: arch_flags = M_UNKNOWN; *unknown = false; break;
+ case bfd_mach_m68000: arch_flags = M_UNKNOWN; *unknown = FALSE; break;
case bfd_mach_m68010: arch_flags = M_68010; break;
case bfd_mach_m68020: arch_flags = M_68020; break;
default: arch_flags = M_UNKNOWN; break;
@@ -753,7 +759,9 @@ NAME(aout,machine_type) (arch, machine, unknown)
break;
case bfd_arch_i386:
- if (machine == 0)
+ if (machine == 0
+ || machine == bfd_mach_i386_i386
+ || machine == bfd_mach_i386_i386_intel_syntax)
arch_flags = M_386;
break;
@@ -790,8 +798,10 @@ NAME(aout,machine_type) (arch, machine, unknown)
case bfd_mach_mips12000:
case bfd_mach_mips16:
case bfd_mach_mipsisa32:
+ case bfd_mach_mipsisa32r2:
case bfd_mach_mips5:
case bfd_mach_mipsisa64:
+ case bfd_mach_mipsisa64r2:
case bfd_mach_mips_sb1:
/* FIXME: These should be MIPS3, MIPS4, MIPS16, MIPS32, etc. */
arch_flags = M_MIPS2;
@@ -813,7 +823,7 @@ NAME(aout,machine_type) (arch, machine, unknown)
break;
case bfd_arch_vax:
- *unknown = false;
+ *unknown = FALSE;
break;
case bfd_arch_cris:
@@ -826,7 +836,7 @@ NAME(aout,machine_type) (arch, machine, unknown)
}
if (arch_flags != M_UNKNOWN)
- *unknown = false;
+ *unknown = FALSE;
return arch_flags;
}
@@ -836,7 +846,7 @@ FUNCTION
aout_@var{size}_set_arch_mach
SYNOPSIS
- boolean aout_@var{size}_set_arch_mach,
+ bfd_boolean aout_@var{size}_set_arch_mach,
(bfd *,
enum bfd_architecture arch,
unsigned long machine));
@@ -847,25 +857,25 @@ DESCRIPTION
can support the architecture required.
*/
-boolean
+bfd_boolean
NAME(aout,set_arch_mach) (abfd, arch, machine)
bfd *abfd;
enum bfd_architecture arch;
unsigned long machine;
{
if (! bfd_default_set_arch_mach (abfd, arch, machine))
- return false;
+ return FALSE;
if (arch != bfd_arch_unknown)
{
- boolean unknown;
+ bfd_boolean unknown;
NAME(aout,machine_type) (arch, machine, &unknown);
if (unknown)
- return false;
+ return FALSE;
}
- /* Determine the size of a relocation entry */
+ /* Determine the size of a relocation entry. */
switch (arch)
{
case bfd_arch_sparc:
@@ -903,7 +913,7 @@ adjust_o_magic (abfd, execp)
/* Data. */
if (!obj_datasec (abfd)->user_set_vma)
{
-#if 0 /* ?? Does alignment in the file image really matter? */
+#if 0 /* ?? Does alignment in the file image really matter? */
pad = align_power (vma, obj_datasec (abfd)->alignment_power) - vma;
#endif
obj_textsec (abfd)->_raw_size += pad;
@@ -1110,7 +1120,7 @@ adjust_n_magic (abfd, execp)
N_SET_MAGIC (*execp, NMAGIC);
}
-boolean
+bfd_boolean
NAME(aout,adjust_sizes_and_vmas) (abfd, text_size, text_end)
bfd *abfd;
bfd_size_type *text_size;
@@ -1119,10 +1129,10 @@ NAME(aout,adjust_sizes_and_vmas) (abfd, text_size, text_end)
struct internal_exec *execp = exec_hdr (abfd);
if (! NAME(aout,make_sections) (abfd))
- return false;
+ return FALSE;
if (adata (abfd).magic != undecided_magic)
- return true;
+ return TRUE;
obj_textsec (abfd)->_raw_size =
align_power (obj_textsec (abfd)->_raw_size,
@@ -1199,7 +1209,7 @@ NAME(aout,adjust_sizes_and_vmas) (abfd, text_size, text_end)
obj_bsssec (abfd)->vma, obj_bsssec (abfd)->_raw_size);
#endif
- return true;
+ return TRUE;
}
/*
@@ -1207,7 +1217,7 @@ FUNCTION
aout_@var{size}_new_section_hook
SYNOPSIS
- boolean aout_@var{size}_new_section_hook,
+ bfd_boolean aout_@var{size}_new_section_hook,
(bfd *abfd,
asection *newsect));
@@ -1215,48 +1225,47 @@ DESCRIPTION
Called by the BFD in response to a @code{bfd_make_section}
request.
*/
-boolean
+bfd_boolean
NAME(aout,new_section_hook) (abfd, newsect)
bfd *abfd;
asection *newsect;
{
- /* align to double at least */
+ /* Align to double at least. */
newsect->alignment_power = bfd_get_arch_info (abfd)->section_align_power;
if (bfd_get_format (abfd) == bfd_object)
- {
- if (obj_textsec (abfd) == NULL && !strcmp (newsect->name, ".text"))
- {
- obj_textsec (abfd)= newsect;
- newsect->target_index = N_TEXT;
- return true;
- }
-
- if (obj_datasec (abfd) == NULL && !strcmp (newsect->name, ".data"))
- {
- obj_datasec (abfd) = newsect;
- newsect->target_index = N_DATA;
- return true;
- }
+ {
+ if (obj_textsec (abfd) == NULL && !strcmp (newsect->name, ".text"))
+ {
+ obj_textsec (abfd)= newsect;
+ newsect->target_index = N_TEXT;
+ return TRUE;
+ }
- if (obj_bsssec (abfd) == NULL && !strcmp (newsect->name, ".bss"))
- {
- obj_bsssec (abfd) = newsect;
- newsect->target_index = N_BSS;
- return true;
- }
+ if (obj_datasec (abfd) == NULL && !strcmp (newsect->name, ".data"))
+ {
+ obj_datasec (abfd) = newsect;
+ newsect->target_index = N_DATA;
+ return TRUE;
+ }
- }
+ if (obj_bsssec (abfd) == NULL && !strcmp (newsect->name, ".bss"))
+ {
+ obj_bsssec (abfd) = newsect;
+ newsect->target_index = N_BSS;
+ return TRUE;
+ }
+ }
- /* We allow more than three sections internally */
- return true;
+ /* We allow more than three sections internally. */
+ return TRUE;
}
-boolean
+bfd_boolean
NAME(aout,set_section_contents) (abfd, section, location, offset, count)
bfd *abfd;
sec_ptr section;
- PTR location;
+ const PTR location;
file_ptr offset;
bfd_size_type count;
{
@@ -1266,38 +1275,44 @@ NAME(aout,set_section_contents) (abfd, section, location, offset, count)
if (! abfd->output_has_begun)
{
if (! NAME(aout,adjust_sizes_and_vmas) (abfd, &text_size, &text_end))
- return false;
+ return FALSE;
}
if (section == obj_bsssec (abfd))
{
bfd_set_error (bfd_error_no_contents);
- return false;
+ return FALSE;
}
if (section != obj_textsec (abfd)
&& section != obj_datasec (abfd))
{
- (*_bfd_error_handler)
- (_("%s: can not represent section `%s' in a.out object file format"),
- bfd_get_filename (abfd), bfd_get_section_name (abfd, section));
- bfd_set_error (bfd_error_nonrepresentable_section);
- return false;
+ if (aout_section_merge_with_text_p (abfd, section))
+ section->filepos = obj_textsec (abfd)->filepos +
+ (section->vma - obj_textsec (abfd)->vma);
+ else
+ {
+ (*_bfd_error_handler)
+ (_("%s: can not represent section `%s' in a.out object file format"),
+ bfd_get_filename (abfd), bfd_get_section_name (abfd, section));
+ bfd_set_error (bfd_error_nonrepresentable_section);
+ return FALSE;
+ }
}
if (count != 0)
{
if (bfd_seek (abfd, section->filepos + offset, SEEK_SET) != 0
|| bfd_bwrite (location, count, abfd) != count)
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Read the external symbols from an a.out file. */
-static boolean
+static bfd_boolean
aout_get_external_symbols (abfd)
bfd *abfd;
{
@@ -1312,8 +1327,8 @@ aout_get_external_symbols (abfd)
#ifdef USE_MMAP
if (! bfd_get_file_window (abfd, obj_sym_filepos (abfd),
exec_hdr (abfd)->a_syms,
- &obj_aout_sym_window (abfd), true))
- return false;
+ &obj_aout_sym_window (abfd), TRUE))
+ return FALSE;
syms = (struct external_nlist *) obj_aout_sym_window (abfd).data;
#else
/* We allocate using malloc to make the values easy to free
@@ -1322,14 +1337,14 @@ aout_get_external_symbols (abfd)
syms = ((struct external_nlist *)
bfd_malloc (count * EXTERNAL_NLIST_SIZE));
if (syms == (struct external_nlist *) NULL && count != 0)
- return false;
+ return FALSE;
amt = exec_hdr (abfd)->a_syms;
if (bfd_seek (abfd, obj_sym_filepos (abfd), SEEK_SET) != 0
|| bfd_bread (syms, amt, abfd) != amt)
{
free (syms);
- return false;
+ return FALSE;
}
#endif
@@ -1348,18 +1363,18 @@ aout_get_external_symbols (abfd)
/* Get the size of the strings. */
if (bfd_seek (abfd, obj_str_filepos (abfd), SEEK_SET) != 0
|| bfd_bread ((PTR) string_chars, amt, abfd) != amt)
- return false;
+ return FALSE;
stringsize = GET_WORD (abfd, string_chars);
#ifdef USE_MMAP
if (! bfd_get_file_window (abfd, obj_str_filepos (abfd), stringsize,
- &obj_aout_string_window (abfd), true))
- return false;
+ &obj_aout_string_window (abfd), TRUE))
+ return FALSE;
strings = (char *) obj_aout_string_window (abfd).data;
#else
strings = (char *) bfd_malloc (stringsize + 1);
if (strings == NULL)
- return false;
+ return FALSE;
/* Skip space for the string count in the buffer for convenience
when using indexes. */
@@ -1367,7 +1382,7 @@ aout_get_external_symbols (abfd)
if (bfd_bread (strings + BYTES_IN_WORD, amt, abfd) != amt)
{
free (strings);
- return false;
+ return FALSE;
}
#endif
@@ -1380,7 +1395,7 @@ aout_get_external_symbols (abfd)
obj_aout_external_string_size (abfd) = stringsize;
}
- return true;
+ return TRUE;
}
/* Translate an a.out symbol into a BFD symbol. The desc, other, type
@@ -1388,7 +1403,7 @@ aout_get_external_symbols (abfd)
nlist structure. This function is responsible for setting
symbol->flags and symbol->section, and adjusting symbol->value. */
-static boolean
+static bfd_boolean
translate_from_native_sym_flags (abfd, cache_ptr)
bfd *abfd;
aout_symbol_type *cache_ptr;
@@ -1401,7 +1416,6 @@ translate_from_native_sym_flags (abfd, cache_ptr)
asection *sec;
/* This is a debugging symbol. */
-
cache_ptr->symbol.flags = BSF_DEBUGGING;
/* Work out the symbol section. */
@@ -1426,7 +1440,7 @@ translate_from_native_sym_flags (abfd, cache_ptr)
cache_ptr->symbol.section = sec;
cache_ptr->symbol.value -= sec->vma;
- return true;
+ return TRUE;
}
/* Get the default visibility. This does not apply to all types, so
@@ -1515,18 +1529,18 @@ translate_from_native_sym_flags (abfd, cache_ptr)
amt = strlen (cache_ptr->symbol.name) + 1;
copy = bfd_alloc (abfd, amt);
if (copy == NULL)
- return false;
+ return FALSE;
strcpy (copy, cache_ptr->symbol.name);
section = bfd_make_section (abfd, copy);
if (section == NULL)
- return false;
+ return FALSE;
}
amt = sizeof (arelent_chain);
reloc = (arelent_chain *) bfd_alloc (abfd, amt);
if (reloc == NULL)
- return false;
+ return FALSE;
/* Build a relocation entry for the constructor. */
switch (cache_ptr->type & N_TYPE)
@@ -1639,12 +1653,12 @@ translate_from_native_sym_flags (abfd, cache_ptr)
break;
}
- return true;
+ return TRUE;
}
/* Set the fields of SYM_POINTER according to CACHE_PTR. */
-static boolean
+static bfd_boolean
translate_to_native_sym_flags (abfd, cache_ptr, sym_pointer)
bfd *abfd;
asymbol *cache_ptr;
@@ -1670,7 +1684,7 @@ translate_to_native_sym_flags (abfd, cache_ptr, sym_pointer)
bfd_get_filename (abfd),
cache_ptr->name != NULL ? cache_ptr->name : _("*unknown*"));
bfd_set_error (bfd_error_nonrepresentable_section);
- return false;
+ return FALSE;
}
if (sec->output_section != NULL)
@@ -1695,14 +1709,19 @@ translate_to_native_sym_flags (abfd, cache_ptr, sym_pointer)
sym_pointer->e_type[0] = N_UNDF | N_EXT;
else
{
- (*_bfd_error_handler)
- (_("%s: can not represent section `%s' in a.out object file format"),
- bfd_get_filename (abfd), bfd_get_section_name (abfd, sec));
- bfd_set_error (bfd_error_nonrepresentable_section);
- return false;
+ if (aout_section_merge_with_text_p (abfd, sec))
+ sym_pointer->e_type[0] |= N_TEXT;
+ else
+ {
+ (*_bfd_error_handler)
+ (_("%s: can not represent section `%s' in a.out object file format"),
+ bfd_get_filename (abfd), bfd_get_section_name (abfd, sec));
+ bfd_set_error (bfd_error_nonrepresentable_section);
+ return FALSE;
+ }
}
- /* Turn the symbol from section relative to absolute again */
+ /* Turn the symbol from section relative to absolute again. */
value += sec->vma + off;
if ((cache_ptr->flags & BSF_WARNING) != 0)
@@ -1718,6 +1737,7 @@ translate_to_native_sym_flags (abfd, cache_ptr, sym_pointer)
if ((cache_ptr->flags & BSF_CONSTRUCTOR) != 0)
{
int type = ((aout_symbol_type *) cache_ptr)->type;
+
switch (type)
{
case N_ABS: type = N_SETA; break;
@@ -1746,7 +1766,7 @@ translate_to_native_sym_flags (abfd, cache_ptr, sym_pointer)
PUT_WORD (abfd, value, sym_pointer->e_value);
- return true;
+ return TRUE;
}
/* Native-level interface to symbols. */
@@ -1766,7 +1786,7 @@ NAME(aout,make_empty_symbol) (abfd)
/* Translate a set of internal symbols into external symbols. */
-boolean
+bfd_boolean
NAME(aout,translate_symbol_table) (abfd, in, ext, count, str, strsize, dynamic)
bfd *abfd;
aout_symbol_type *in;
@@ -1774,7 +1794,7 @@ NAME(aout,translate_symbol_table) (abfd, in, ext, count, str, strsize, dynamic)
bfd_size_type count;
char *str;
bfd_size_type strsize;
- boolean dynamic;
+ bfd_boolean dynamic;
{
struct external_nlist *ext_end;
@@ -1796,7 +1816,7 @@ NAME(aout,translate_symbol_table) (abfd, in, ext, count, str, strsize, dynamic)
else if (x < strsize)
in->symbol.name = str + x;
else
- return false;
+ return FALSE;
in->symbol.value = GET_SWORD (abfd, ext->e_value);
in->desc = H_GET_16 (abfd, ext->e_desc);
@@ -1805,20 +1825,20 @@ NAME(aout,translate_symbol_table) (abfd, in, ext, count, str, strsize, dynamic)
in->symbol.udata.p = NULL;
if (! translate_from_native_sym_flags (abfd, in))
- return false;
+ return FALSE;
if (dynamic)
in->symbol.flags |= BSF_DYNAMIC;
}
- return true;
+ return TRUE;
}
/* We read the symbols into a buffer, which is discarded when this
function exits. We read the strings into a buffer large enough to
hold them all plus all the cached symbol entries. */
-boolean
+bfd_boolean
NAME(aout,slurp_symbol_table) (abfd)
bfd *abfd;
{
@@ -1826,20 +1846,20 @@ NAME(aout,slurp_symbol_table) (abfd)
aout_symbol_type *cached;
bfd_size_type cached_size;
- /* If there's no work to be done, don't do any */
+ /* If there's no work to be done, don't do any. */
if (obj_aout_symbols (abfd) != (aout_symbol_type *) NULL)
- return true;
+ return TRUE;
old_external_syms = obj_aout_external_syms (abfd);
if (! aout_get_external_symbols (abfd))
- return false;
+ return FALSE;
cached_size = obj_aout_external_sym_count (abfd);
cached_size *= sizeof (aout_symbol_type);
cached = (aout_symbol_type *) bfd_zmalloc (cached_size);
if (cached == NULL && cached_size != 0)
- return false;
+ return FALSE;
/* Convert from external symbol information to internal. */
if (! (NAME(aout,translate_symbol_table)
@@ -1848,10 +1868,10 @@ NAME(aout,slurp_symbol_table) (abfd)
obj_aout_external_sym_count (abfd),
obj_aout_external_strings (abfd),
obj_aout_external_string_size (abfd),
- false)))
+ FALSE)))
{
free (cached);
- return false;
+ return FALSE;
}
bfd_get_symcount (abfd) = obj_aout_external_sym_count (abfd);
@@ -1873,7 +1893,7 @@ NAME(aout,slurp_symbol_table) (abfd)
obj_aout_external_syms (abfd) = NULL;
}
- return true;
+ return TRUE;
}
/* We use a hash table when writing out symbols so that we only write
@@ -1886,8 +1906,9 @@ NAME(aout,slurp_symbol_table) (abfd)
if BFD_TRADITIONAL_FORMAT is set. */
static bfd_size_type add_to_stringtab
- PARAMS ((bfd *, struct bfd_strtab_hash *, const char *, boolean));
-static boolean emit_stringtab PARAMS ((bfd *, struct bfd_strtab_hash *));
+ PARAMS ((bfd *, struct bfd_strtab_hash *, const char *, bfd_boolean));
+static bfd_boolean emit_stringtab
+ PARAMS ((bfd *, struct bfd_strtab_hash *));
/* Get the index of a string in a strtab, adding it if it is not
already present. */
@@ -1897,9 +1918,9 @@ add_to_stringtab (abfd, tab, str, copy)
bfd *abfd;
struct bfd_strtab_hash *tab;
const char *str;
- boolean copy;
+ bfd_boolean copy;
{
- boolean hash;
+ bfd_boolean hash;
bfd_size_type index;
/* An index of 0 always means the empty string. */
@@ -1908,9 +1929,9 @@ add_to_stringtab (abfd, tab, str, copy)
/* Don't hash if BFD_TRADITIONAL_FORMAT is set, because SunOS dbx
doesn't understand a hashed string table. */
- hash = true;
+ hash = TRUE;
if ((abfd->flags & BFD_TRADITIONAL_FORMAT) != 0)
- hash = false;
+ hash = FALSE;
index = _bfd_stringtab_add (tab, str, hash, copy);
@@ -1927,7 +1948,7 @@ add_to_stringtab (abfd, tab, str, copy)
/* Write out a strtab. ABFD is already at the right location in the
file. */
-static boolean
+static bfd_boolean
emit_stringtab (abfd, tab)
register bfd *abfd;
struct bfd_strtab_hash *tab;
@@ -1938,12 +1959,12 @@ emit_stringtab (abfd, tab)
/* The string table starts with the size. */
PUT_WORD (abfd, _bfd_stringtab_size (tab) + BYTES_IN_WORD, buffer);
if (bfd_bwrite ((PTR) buffer, amt, abfd) != amt)
- return false;
+ return FALSE;
return _bfd_stringtab_emit (abfd, tab);
}
-boolean
+bfd_boolean
NAME(aout,write_syms) (abfd)
bfd *abfd;
{
@@ -1953,7 +1974,7 @@ NAME(aout,write_syms) (abfd)
strtab = _bfd_stringtab_init ();
if (strtab == NULL)
- return false;
+ return FALSE;
for (count = 0; count < bfd_get_symcount (abfd); count++)
{
@@ -1962,7 +1983,7 @@ NAME(aout,write_syms) (abfd)
struct external_nlist nsp;
bfd_size_type amt;
- indx = add_to_stringtab (abfd, strtab, g->name, false);
+ indx = add_to_stringtab (abfd, strtab, g->name, FALSE);
if (indx == (bfd_size_type) -1)
goto error_return;
PUT_WORD (abfd, indx, (bfd_byte *) nsp.e_strx);
@@ -1997,15 +2018,15 @@ NAME(aout,write_syms) (abfd)
_bfd_stringtab_free (strtab);
- return true;
+ return TRUE;
error_return:
_bfd_stringtab_free (strtab);
- return false;
+ return FALSE;
}
long
-NAME(aout,get_symtab) (abfd, location)
+NAME(aout,canonicalize_symtab) (abfd, location)
bfd *abfd;
asymbol **location;
{
@@ -2023,7 +2044,7 @@ NAME(aout,get_symtab) (abfd, location)
return bfd_get_symcount (abfd);
}
-/* Standard reloc stuff */
+/* Standard reloc stuff. */
/* Output standard relocation information to a file in target byte order. */
extern void NAME(aout,swap_std_reloc_out)
@@ -2045,8 +2066,8 @@ NAME(aout,swap_std_reloc_out) (abfd, g, natptr)
PUT_WORD (abfd, g->address, natptr->r_address);
- r_length = g->howto->size ; /* Size as a power of two */
- r_pcrel = (int) g->howto->pc_relative; /* Relative to PC? */
+ r_length = g->howto->size ; /* Size as a power of two. */
+ r_pcrel = (int) g->howto->pc_relative; /* Relative to PC? */
/* XXX This relies on relocs coming from a.out files. */
r_baserel = (g->howto->type & 8) != 0;
r_jmptable = (g->howto->type & 16) != 0;
@@ -2057,43 +2078,41 @@ NAME(aout,swap_std_reloc_out) (abfd, g, natptr)
r_addend = g->addend + (*(g->sym_ptr_ptr))->section->output_section->vma;
#endif
- /* name was clobbered by aout_write_syms to be symbol index */
+ /* Name was clobbered by aout_write_syms to be symbol index. */
/* If this relocation is relative to a symbol then set the
r_index to the symbols index, and the r_extern bit.
Absolute symbols can come in in two ways, either as an offset
from the abs section, or as a symbol which has an abs value.
- check for that here
- */
+ check for that here. */
if (bfd_is_com_section (output_section)
|| bfd_is_abs_section (output_section)
|| bfd_is_und_section (output_section))
{
if (bfd_abs_section_ptr->symbol == sym)
- {
- /* Whoops, looked like an abs symbol, but is really an offset
- from the abs section */
- r_index = N_ABS;
- r_extern = 0;
- }
+ {
+ /* Whoops, looked like an abs symbol, but is
+ really an offset from the abs section. */
+ r_index = N_ABS;
+ r_extern = 0;
+ }
else
- {
- /* Fill in symbol */
- r_extern = 1;
- r_index = (*(g->sym_ptr_ptr))->KEEPIT;
-
- }
+ {
+ /* Fill in symbol. */
+ r_extern = 1;
+ r_index = (*(g->sym_ptr_ptr))->KEEPIT;
+ }
}
else
{
- /* Just an ordinary section */
+ /* Just an ordinary section. */
r_extern = 0;
r_index = output_section->target_index;
}
- /* now the fun stuff */
+ /* Now the fun stuff. */
if (bfd_header_big_endian (abfd))
{
natptr->r_index[0] = r_index >> 16;
@@ -2120,7 +2139,7 @@ NAME(aout,swap_std_reloc_out) (abfd, g, natptr)
}
}
-/* Extended stuff */
+/* Extended stuff. */
/* Output extended relocation information to a file in target byte order. */
extern void NAME(aout,swap_ext_reloc_out)
@@ -2153,7 +2172,6 @@ NAME(aout,swap_ext_reloc_out) (abfd, g, natptr)
Absolute symbols can come in in two ways, either as an offset
from the abs section, or as a symbol which has an abs value.
check for that here. */
-
if (bfd_is_abs_section (bfd_get_section (sym)))
{
r_extern = 0;
@@ -2170,12 +2188,12 @@ NAME(aout,swap_ext_reloc_out) (abfd, g, natptr)
}
else
{
- /* Just an ordinary section */
+ /* Just an ordinary section. */
r_extern = 0;
r_index = output_section->target_index;
}
- /* now the fun stuff */
+ /* Now the fun stuff. */
if (bfd_header_big_endian (abfd))
{
natptr->r_index[0] = r_index >> 16;
@@ -2256,7 +2274,7 @@ NAME(aout,swap_ext_reloc_in) (abfd, bytes, cache_ptr, symbols, symcount)
cache_ptr->address = (GET_SWORD (abfd, bytes->r_address));
- /* now the fun stuff */
+ /* Now the fun stuff. */
if (bfd_header_big_endian (abfd))
{
r_index = (((unsigned int) bytes->r_index[0] << 16)
@@ -2315,7 +2333,7 @@ NAME(aout,swap_std_reloc_in) (abfd, bytes, cache_ptr, symbols, symcount)
cache_ptr->address = H_GET_32 (abfd, bytes->r_address);
- /* now the fun stuff */
+ /* Now the fun stuff. */
if (bfd_header_big_endian (abfd))
{
r_index = (((unsigned int) bytes->r_index[0] << 16)
@@ -2368,7 +2386,7 @@ NAME(aout,swap_std_reloc_in) (abfd, bytes, cache_ptr, symbols, symcount)
/* Read and swap the relocs for a section. */
-boolean
+bfd_boolean
NAME(aout,slurp_reloc_table) (abfd, asect, symbols)
bfd *abfd;
sec_ptr asect;
@@ -2384,10 +2402,10 @@ NAME(aout,slurp_reloc_table) (abfd, asect, symbols)
bfd_size_type amt;
if (asect->relocation)
- return true;
+ return TRUE;
if (asect->flags & SEC_CONSTRUCTOR)
- return true;
+ return TRUE;
if (asect == obj_datasec (abfd))
reloc_size = exec_hdr (abfd)->a_drsize;
@@ -2398,11 +2416,11 @@ NAME(aout,slurp_reloc_table) (abfd, asect, symbols)
else
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
if (bfd_seek (abfd, asect->rel_filepos, SEEK_SET) != 0)
- return false;
+ return FALSE;
each_size = obj_reloc_entry_size (abfd);
@@ -2411,20 +2429,20 @@ NAME(aout,slurp_reloc_table) (abfd, asect, symbols)
amt = count * sizeof (arelent);
reloc_cache = (arelent *) bfd_zmalloc (amt);
if (reloc_cache == NULL && count != 0)
- return false;
+ return FALSE;
relocs = bfd_malloc (reloc_size);
if (relocs == NULL && reloc_size != 0)
{
free (reloc_cache);
- return false;
+ return FALSE;
}
if (bfd_bread (relocs, reloc_size, abfd) != reloc_size)
{
free (relocs);
free (reloc_cache);
- return false;
+ return FALSE;
}
cache_ptr = reloc_cache;
@@ -2450,12 +2468,12 @@ NAME(aout,slurp_reloc_table) (abfd, asect, symbols)
asect->relocation = reloc_cache;
asect->reloc_count = cache_ptr - reloc_cache;
- return true;
+ return TRUE;
}
/* Write out a relocation section into an object file. */
-boolean
+bfd_boolean
NAME(aout,squirt_out_relocs) (abfd, section)
bfd *abfd;
asection *section;
@@ -2468,13 +2486,13 @@ NAME(aout,squirt_out_relocs) (abfd, section)
bfd_size_type natsize;
if (count == 0 || section->orelocation == NULL)
- return true;
+ return TRUE;
each_size = obj_reloc_entry_size (abfd);
natsize = (bfd_size_type) each_size * count;
native = (unsigned char *) bfd_zalloc (abfd, natsize);
if (!native)
- return false;
+ return FALSE;
generic = section->orelocation;
@@ -2498,14 +2516,15 @@ NAME(aout,squirt_out_relocs) (abfd, section)
if (bfd_bwrite ((PTR) native, natsize, abfd) != natsize)
{
bfd_release (abfd, native);
- return false;
+ return FALSE;
}
bfd_release (abfd, native);
- return true;
+ return TRUE;
}
-/* This is stupid. This function should be a boolean predicate */
+/* This is stupid. This function should be a boolean predicate. */
+
long
NAME(aout,canonicalize_reloc) (abfd, section, relptr, symbols)
bfd *abfd;
@@ -2558,10 +2577,9 @@ NAME(aout,get_reloc_upper_bound) (abfd, asect)
bfd_set_error (bfd_error_invalid_operation);
return -1;
}
+
if (asect->flags & SEC_CONSTRUCTOR)
- {
- return (sizeof (arelent *) * (asect->reloc_count+1));
- }
+ return (sizeof (arelent *) * (asect->reloc_count+1));
if (asect == obj_datasec (abfd))
return (sizeof (arelent *)
@@ -2679,7 +2697,7 @@ NAME(aout,print_symbol) (abfd, afile, symbol, how)
long
NAME(aout,read_minisymbols) (abfd, dynamic, minisymsp, sizep)
bfd *abfd;
- boolean dynamic;
+ bfd_boolean dynamic;
PTR *minisymsp;
unsigned int *sizep;
{
@@ -2715,7 +2733,7 @@ NAME(aout,read_minisymbols) (abfd, dynamic, minisymsp, sizep)
asymbol *
NAME(aout,minisymbol_to_symbol) (abfd, dynamic, minisym, sym)
bfd *abfd;
- boolean dynamic;
+ bfd_boolean dynamic;
const PTR minisym;
asymbol *sym;
{
@@ -2733,19 +2751,17 @@ NAME(aout,minisymbol_to_symbol) (abfd, dynamic, minisym, sym)
(bfd_size_type) 1,
obj_aout_external_strings (abfd),
obj_aout_external_string_size (abfd),
- false)))
+ FALSE)))
return NULL;
return sym;
}
-/*
- provided a BFD, a section and an offset into the section, calculate
- and return the name of the source file and the line nearest to the
- wanted location.
-*/
+/* Provided a BFD, a section and an offset into the section, calculate
+ and return the name of the source file and the line nearest to the
+ wanted location. */
-boolean
+bfd_boolean
NAME(aout,find_nearest_line)
(abfd, section, symbols, offset, filename_ptr, functionname_ptr, line_ptr)
bfd *abfd;
@@ -2756,7 +2772,7 @@ NAME(aout,find_nearest_line)
const char **functionname_ptr;
unsigned int *line_ptr;
{
- /* Run down the file looking for the filename, function and linenumber */
+ /* Run down the file looking for the filename, function and linenumber. */
asymbol **p;
const char *directory_name = NULL;
const char *main_file_name = NULL;
@@ -2772,6 +2788,7 @@ NAME(aout,find_nearest_line)
*filename_ptr = abfd->filename;
*functionname_ptr = 0;
*line_ptr = 0;
+
if (symbols != (asymbol **)NULL)
{
for (p = symbols; *p; p++)
@@ -2859,12 +2876,13 @@ NAME(aout,find_nearest_line)
break;
case N_FUN:
{
- /* We'll keep this if it is nearer than the one we have already */
+ /* We'll keep this if it is nearer than the one we have already. */
if (q->symbol.value >= low_func_vma &&
- q->symbol.value <= offset) {
- low_func_vma = q->symbol.value;
- func = (asymbol *)q;
- }
+ q->symbol.value <= offset)
+ {
+ low_func_vma = q->symbol.value;
+ func = (asymbol *)q;
+ }
else if (q->symbol.value > offset)
goto done;
}
@@ -2886,6 +2904,7 @@ NAME(aout,find_nearest_line)
filelen = 0;
else
filelen = strlen (directory_name) + strlen (main_file_name);
+
if (func == NULL)
funclen = 0;
else
@@ -2893,6 +2912,7 @@ NAME(aout,find_nearest_line)
if (adata (abfd).line_buf != NULL)
free (adata (abfd).line_buf);
+
if (filelen + funclen == 0)
adata (abfd).line_buf = buf = NULL;
else
@@ -2900,7 +2920,7 @@ NAME(aout,find_nearest_line)
buf = (char *) bfd_malloc (filelen + funclen + 3);
adata (abfd).line_buf = buf;
if (buf == NULL)
- return false;
+ return FALSE;
}
if (main_file_name != NULL)
@@ -2930,20 +2950,20 @@ NAME(aout,find_nearest_line)
buf[0] = bfd_get_symbol_leading_char (abfd);
strcpy (buf + 1, function);
}
- /* Have to remove : stuff */
+ /* Have to remove : stuff. */
colon = strchr (buf, ':');
if (colon != NULL)
*colon = '\0';
*functionname_ptr = buf;
}
- return true;
+ return TRUE;
}
int
NAME(aout,sizeof_headers) (abfd, execable)
bfd *abfd;
- boolean execable ATTRIBUTE_UNUSED;
+ bfd_boolean execable ATTRIBUTE_UNUSED;
{
return adata (abfd).exec_bytes_size;
}
@@ -2951,7 +2971,7 @@ NAME(aout,sizeof_headers) (abfd, execable)
/* Free all information we have cached for this BFD. We can always
read it again later if we need it. */
-boolean
+bfd_boolean
NAME(aout,bfd_free_cached_info) (abfd)
bfd *abfd;
{
@@ -2959,7 +2979,7 @@ NAME(aout,bfd_free_cached_info) (abfd)
if (bfd_get_format (abfd) != bfd_object
|| abfd->tdata.aout_data == NULL)
- return true;
+ return TRUE;
#define BFCI_FREE(x) if (x != NULL) { free (x); x = NULL; }
BFCI_FREE (obj_aout_symbols (abfd));
@@ -2976,19 +2996,20 @@ NAME(aout,bfd_free_cached_info) (abfd)
BFCI_FREE (o->relocation);
#undef BFCI_FREE
- return true;
+ return TRUE;
}
/* a.out link code. */
-static boolean aout_link_add_object_symbols
+static bfd_boolean aout_link_add_object_symbols
PARAMS ((bfd *, struct bfd_link_info *));
-static boolean aout_link_check_archive_element
- PARAMS ((bfd *, struct bfd_link_info *, boolean *));
-static boolean aout_link_free_symbols PARAMS ((bfd *));
-static boolean aout_link_check_ar_symbols
- PARAMS ((bfd *, struct bfd_link_info *, boolean *pneeded));
-static boolean aout_link_add_symbols
+static bfd_boolean aout_link_check_archive_element
+ PARAMS ((bfd *, struct bfd_link_info *, bfd_boolean *));
+static bfd_boolean aout_link_free_symbols
+ PARAMS ((bfd *));
+static bfd_boolean aout_link_check_ar_symbols
+ PARAMS ((bfd *, struct bfd_link_info *, bfd_boolean *pneeded));
+static bfd_boolean aout_link_add_symbols
PARAMS ((bfd *, struct bfd_link_info *));
/* Routine to create an entry in an a.out link hash table. */
@@ -3016,7 +3037,7 @@ NAME(aout,link_hash_newfunc) (entry, table, string)
if (ret)
{
/* Set local fields. */
- ret->written = false;
+ ret->written = FALSE;
ret->indx = -1;
}
@@ -3025,13 +3046,13 @@ NAME(aout,link_hash_newfunc) (entry, table, string)
/* Initialize an a.out link hash table. */
-boolean
+bfd_boolean
NAME(aout,link_hash_table_init) (table, abfd, newfunc)
struct aout_link_hash_table *table;
bfd *abfd;
- struct bfd_hash_entry *(*newfunc) PARAMS ((struct bfd_hash_entry *,
- struct bfd_hash_table *,
- const char *));
+ struct bfd_hash_entry *(*newfunc)
+ PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *,
+ const char *));
{
return _bfd_link_hash_table_init (&table->root, abfd, newfunc);
}
@@ -3045,9 +3066,10 @@ NAME(aout,link_hash_table_create) (abfd)
struct aout_link_hash_table *ret;
bfd_size_type amt = sizeof (struct aout_link_hash_table);
- ret = (struct aout_link_hash_table *) bfd_alloc (abfd, amt);
+ ret = (struct aout_link_hash_table *) bfd_malloc (amt);
if (ret == NULL)
return (struct bfd_link_hash_table *) NULL;
+
if (! NAME(aout,link_hash_table_init) (ret, abfd,
NAME(aout,link_hash_newfunc)))
{
@@ -3060,7 +3082,7 @@ NAME(aout,link_hash_table_create) (abfd)
/* Given an a.out BFD, add symbols to the global hash table as
appropriate. */
-boolean
+bfd_boolean
NAME(aout,link_add_symbols) (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -3074,27 +3096,27 @@ NAME(aout,link_add_symbols) (abfd, info)
(abfd, info, aout_link_check_archive_element);
default:
bfd_set_error (bfd_error_wrong_format);
- return false;
+ return FALSE;
}
}
/* Add symbols from an a.out object file. */
-static boolean
+static bfd_boolean
aout_link_add_object_symbols (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
{
if (! aout_get_external_symbols (abfd))
- return false;
+ return FALSE;
if (! aout_link_add_symbols (abfd, info))
- return false;
+ return FALSE;
if (! info->keep_memory)
{
if (! aout_link_free_symbols (abfd))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Check a single archive element to see if we need to include it in
@@ -3102,36 +3124,36 @@ aout_link_add_object_symbols (abfd, info)
needed in the link or not. This is called from
_bfd_generic_link_add_archive_symbols. */
-static boolean
+static bfd_boolean
aout_link_check_archive_element (abfd, info, pneeded)
bfd *abfd;
struct bfd_link_info *info;
- boolean *pneeded;
+ bfd_boolean *pneeded;
{
if (! aout_get_external_symbols (abfd))
- return false;
+ return FALSE;
if (! aout_link_check_ar_symbols (abfd, info, pneeded))
- return false;
+ return FALSE;
if (*pneeded)
{
if (! aout_link_add_symbols (abfd, info))
- return false;
+ return FALSE;
}
if (! info->keep_memory || ! *pneeded)
{
if (! aout_link_free_symbols (abfd))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Free up the internal symbols read from an a.out file. */
-static boolean
+static bfd_boolean
aout_link_free_symbols (abfd)
bfd *abfd;
{
@@ -3153,7 +3175,7 @@ aout_link_free_symbols (abfd)
#endif
obj_aout_external_strings (abfd) = (char *) NULL;
}
- return true;
+ return TRUE;
}
/* Look through the internal symbols to see if this object file should
@@ -3163,17 +3185,17 @@ aout_link_free_symbols (abfd)
known symbol but we do not include the object file in the link
(unless there is some other reason to include it). */
-static boolean
+static bfd_boolean
aout_link_check_ar_symbols (abfd, info, pneeded)
bfd *abfd;
struct bfd_link_info *info;
- boolean *pneeded;
+ bfd_boolean *pneeded;
{
register struct external_nlist *p;
struct external_nlist *pend;
char *strings;
- *pneeded = false;
+ *pneeded = FALSE;
/* Look through all the symbols. */
p = obj_aout_external_syms (abfd);
@@ -3203,7 +3225,7 @@ aout_link_check_ar_symbols (abfd, info, pneeded)
}
name = strings + GET_WORD (abfd, p->e_strx);
- h = bfd_link_hash_lookup (info->hash, name, false, false, true);
+ h = bfd_link_hash_lookup (info->hash, name, FALSE, FALSE, TRUE);
/* We are only interested in symbols that are currently
undefined or common. */
@@ -3224,23 +3246,47 @@ aout_link_check_ar_symbols (abfd, info, pneeded)
{
/* This object file defines this symbol. We must link it
in. This is true regardless of whether the current
- definition of the symbol is undefined or common. If the
- current definition is common, we have a case in which we
- have already seen an object file including
+ definition of the symbol is undefined or common.
+
+ If the current definition is common, we have a case in
+ which we have already seen an object file including:
int a;
- and this object file from the archive includes
+ and this object file from the archive includes:
int a = 5;
- In such a case we must include this object file.
+ In such a case, whether to include this object is target
+ dependant for backward compatibility.
FIXME: The SunOS 4.1.3 linker will pull in the archive
element if the symbol is defined in the .data section,
but not if it is defined in the .text section. That
- seems a bit crazy to me, and I haven't implemented it.
- However, it might be correct. */
+ seems a bit crazy to me, and it has not been implemented
+ yet. However, it might be correct. */
+ if (h->type == bfd_link_hash_common)
+ {
+ int skip = 0;
+
+ switch (info->common_skip_ar_aymbols)
+ {
+ case bfd_link_common_skip_text:
+ skip = (type == (N_TEXT | N_EXT));
+ break;
+ case bfd_link_common_skip_data:
+ skip = (type == (N_DATA | N_EXT));
+ break;
+ default:
+ case bfd_link_common_skip_all:
+ skip = 1;
+ break;
+ }
+
+ if (skip)
+ continue;
+ }
+
if (! (*info->callbacks->add_archive_element) (info, abfd, name))
- return false;
- *pneeded = true;
- return true;
+ return FALSE;
+ *pneeded = TRUE;
+ return TRUE;
}
if (type == (N_UNDF | N_EXT))
@@ -3267,9 +3313,9 @@ aout_link_check_ar_symbols (abfd, info, pneeded)
if (! (*info->callbacks->add_archive_element) (info,
abfd,
name))
- return false;
- *pneeded = true;
- return true;
+ return FALSE;
+ *pneeded = TRUE;
+ return TRUE;
}
/* Turn the current link symbol into a common
symbol. It is already on the undefs list. */
@@ -3278,7 +3324,7 @@ aout_link_check_ar_symbols (abfd, info, pneeded)
bfd_hash_allocate (&info->hash->table,
sizeof (struct bfd_link_hash_common_entry)));
if (h->u.c.p == NULL)
- return false;
+ return FALSE;
h->u.c.size = value;
@@ -3315,33 +3361,32 @@ aout_link_check_ar_symbols (abfd, info, pneeded)
if (h->type == bfd_link_hash_undefined)
{
if (! (*info->callbacks->add_archive_element) (info, abfd, name))
- return false;
- *pneeded = true;
- return true;
+ return FALSE;
+ *pneeded = TRUE;
+ return TRUE;
}
}
}
/* We do not need this object file. */
- return true;
+ return TRUE;
}
/* Add all symbols from an object file to the hash table. */
-static boolean
+static bfd_boolean
aout_link_add_symbols (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
{
- boolean (*add_one_symbol) PARAMS ((struct bfd_link_info *, bfd *,
- const char *, flagword, asection *,
- bfd_vma, const char *, boolean,
- boolean,
- struct bfd_link_hash_entry **));
+ bfd_boolean (*add_one_symbol)
+ PARAMS ((struct bfd_link_info *, bfd *, const char *, flagword, asection *,
+ bfd_vma, const char *, bfd_boolean, bfd_boolean,
+ struct bfd_link_hash_entry **));
struct external_nlist *syms;
bfd_size_type sym_count;
char *strings;
- boolean copy;
+ bfd_boolean copy;
struct aout_link_hash_entry **sym_hash;
register struct external_nlist *p;
struct external_nlist *pend;
@@ -3351,15 +3396,15 @@ aout_link_add_symbols (abfd, info)
sym_count = obj_aout_external_sym_count (abfd);
strings = obj_aout_external_strings (abfd);
if (info->keep_memory)
- copy = false;
+ copy = FALSE;
else
- copy = true;
+ copy = TRUE;
if (aout_backend_info (abfd)->add_dynamic_symbols != NULL)
{
if (! ((*aout_backend_info (abfd)->add_dynamic_symbols)
(abfd, info, &syms, &sym_count, &strings)))
- return false;
+ return FALSE;
}
/* We keep a list of the linker hash table entries that correspond
@@ -3369,7 +3414,7 @@ aout_link_add_symbols (abfd, info)
amt = sym_count * sizeof (struct aout_link_hash_entry *);
sym_hash = (struct aout_link_hash_entry **) bfd_alloc (abfd, amt);
if (sym_hash == NULL && sym_count != 0)
- return false;
+ return FALSE;
obj_aout_sym_hashes (abfd) = sym_hash;
add_one_symbol = aout_backend_info (abfd)->add_one_symbol;
@@ -3515,9 +3560,9 @@ aout_link_add_symbols (abfd, info)
}
if (! ((*add_one_symbol)
- (info, abfd, name, flags, section, value, string, copy, false,
+ (info, abfd, name, flags, section, value, string, copy, FALSE,
(struct bfd_link_hash_entry **) sym_hash)))
- return false;
+ return FALSE;
/* Restrict the maximum alignment of a common symbol based on
the architecture, since a.out has no way to represent
@@ -3543,7 +3588,7 @@ aout_link_add_symbols (abfd, info)
++sym_hash;
}
- return true;
+ return TRUE;
}
/* A hash table used for header files with N_BINCL entries. */
@@ -3606,27 +3651,27 @@ struct aout_final_link_info
static struct bfd_hash_entry *aout_link_includes_newfunc
PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-static boolean aout_link_input_bfd
+static bfd_boolean aout_link_input_bfd
PARAMS ((struct aout_final_link_info *, bfd *input_bfd));
-static boolean aout_link_write_symbols
+static bfd_boolean aout_link_write_symbols
PARAMS ((struct aout_final_link_info *, bfd *input_bfd));
-static boolean aout_link_write_other_symbol
+static bfd_boolean aout_link_write_other_symbol
PARAMS ((struct aout_link_hash_entry *, PTR));
-static boolean aout_link_input_section
+static bfd_boolean aout_link_input_section
PARAMS ((struct aout_final_link_info *, bfd *input_bfd,
asection *input_section, file_ptr *reloff_ptr,
bfd_size_type rel_size));
-static boolean aout_link_input_section_std
+static bfd_boolean aout_link_input_section_std
PARAMS ((struct aout_final_link_info *, bfd *input_bfd,
asection *input_section, struct reloc_std_external *,
bfd_size_type rel_size, bfd_byte *contents));
-static boolean aout_link_input_section_ext
+static bfd_boolean aout_link_input_section_ext
PARAMS ((struct aout_final_link_info *, bfd *input_bfd,
asection *input_section, struct reloc_ext_external *,
bfd_size_type rel_size, bfd_byte *contents));
static INLINE asection *aout_reloc_index_to_section
PARAMS ((bfd *, int));
-static boolean aout_link_reloc_link_order
+static bfd_boolean aout_link_reloc_link_order
PARAMS ((struct aout_final_link_info *, asection *,
struct bfd_link_order *));
@@ -3669,14 +3714,14 @@ aout_link_includes_newfunc (entry, table, string)
of bfd_link_order structures which list all the input sections for
the output section. */
-boolean
+bfd_boolean
NAME(aout,final_link) (abfd, info, callback)
bfd *abfd;
struct bfd_link_info *info;
void (*callback) PARAMS ((bfd *, file_ptr *, file_ptr *, file_ptr *));
{
struct aout_final_link_info aout_info;
- boolean includes_hash_initialized = false;
+ bfd_boolean includes_hash_initialized = FALSE;
register bfd *sub;
bfd_size_type trsize, drsize;
bfd_size_type max_contents_size;
@@ -3686,7 +3731,7 @@ NAME(aout,final_link) (abfd, info, callback)
file_ptr text_end;
register struct bfd_link_order *p;
asection *o;
- boolean have_link_order_relocs;
+ bfd_boolean have_link_order_relocs;
if (info->shared)
abfd->flags |= DYNAMIC;
@@ -3702,10 +3747,10 @@ NAME(aout,final_link) (abfd, info, callback)
aout_link_includes_newfunc,
251))
goto error_return;
- includes_hash_initialized = true;
+ includes_hash_initialized = TRUE;
/* Figure out the largest section size. Also, if generating
- relocateable output, count the relocs. */
+ relocatable output, count the relocs. */
trsize = 0;
drsize = 0;
max_contents_size = 0;
@@ -3715,7 +3760,7 @@ NAME(aout,final_link) (abfd, info, callback)
{
bfd_size_type sz;
- if (info->relocateable)
+ if (info->relocatable)
{
if (bfd_get_flavour (sub) == bfd_target_aout_flavour)
{
@@ -3729,7 +3774,7 @@ NAME(aout,final_link) (abfd, info, callback)
work out the number of relocs needed, and then multiply
by the reloc size. */
(*_bfd_error_handler)
- (_("%s: relocateable link from %s to %s not supported"),
+ (_("%s: relocatable link from %s to %s not supported"),
bfd_get_filename (abfd),
sub->xvec->name, abfd->xvec->name);
bfd_set_error (bfd_error_invalid_operation);
@@ -3759,7 +3804,7 @@ NAME(aout,final_link) (abfd, info, callback)
}
}
- if (info->relocateable)
+ if (info->relocatable)
{
if (obj_textsec (abfd) != (asection *) NULL)
trsize += (_bfd_count_link_order_relocs (obj_textsec (abfd)
@@ -3825,7 +3870,7 @@ NAME(aout,final_link) (abfd, info, callback)
struct aout_link_hash_entry *h;
h = aout_link_hash_lookup (aout_hash_table (info), "__DYNAMIC",
- false, false, false);
+ FALSE, FALSE, FALSE);
if (h != NULL)
aout_link_write_other_symbol (h, &aout_info);
}
@@ -3852,7 +3897,7 @@ NAME(aout,final_link) (abfd, info, callback)
We use the output_has_begun field of the input BFDs to see
whether we have already handled it. */
for (sub = info->input_bfds; sub != (bfd *) NULL; sub = sub->link_next)
- sub->output_has_begun = false;
+ sub->output_has_begun = FALSE;
/* Mark all sections which are to be included in the link. This
will normally be every section. We need to do this so that we
@@ -3861,13 +3906,11 @@ NAME(aout,final_link) (abfd, info, callback)
for (o = abfd->sections; o != NULL; o = o->next)
{
for (p = o->link_order_head; p != NULL; p = p->next)
- {
- if (p->type == bfd_indirect_link_order)
- p->u.indirect.section->linker_mark = (unsigned int) true;
- }
+ if (p->type == bfd_indirect_link_order)
+ p->u.indirect.section->linker_mark = TRUE;
}
- have_link_order_relocs = false;
+ have_link_order_relocs = FALSE;
for (o = abfd->sections; o != (asection *) NULL; o = o->next)
{
for (p = o->link_order_head;
@@ -3885,14 +3928,14 @@ NAME(aout,final_link) (abfd, info, callback)
{
if (! aout_link_input_bfd (&aout_info, input_bfd))
goto error_return;
- input_bfd->output_has_begun = true;
+ input_bfd->output_has_begun = TRUE;
}
}
else if (p->type == bfd_section_reloc_link_order
|| p->type == bfd_symbol_reloc_link_order)
{
/* These are handled below. */
- have_link_order_relocs = true;
+ have_link_order_relocs = TRUE;
}
else
{
@@ -3952,7 +3995,7 @@ NAME(aout,final_link) (abfd, info, callback)
if (includes_hash_initialized)
{
bfd_hash_table_free (&aout_info.includes.root);
- includes_hash_initialized = false;
+ includes_hash_initialized = FALSE;
}
/* Finish up any dynamic linking we may be doing. */
@@ -3991,7 +4034,7 @@ NAME(aout,final_link) (abfd, info, callback)
goto error_return;
}
- return true;
+ return TRUE;
error_return:
if (aout_info.contents != NULL)
@@ -4004,12 +4047,12 @@ NAME(aout,final_link) (abfd, info, callback)
free (aout_info.output_syms);
if (includes_hash_initialized)
bfd_hash_table_free (&aout_info.includes.root);
- return false;
+ return FALSE;
}
/* Link an a.out input BFD into the output file. */
-static boolean
+static bfd_boolean
aout_link_input_bfd (finfo, input_bfd)
struct aout_final_link_info *finfo;
bfd *input_bfd;
@@ -4027,16 +4070,16 @@ aout_link_input_bfd (finfo, input_bfd)
}
/* Get the symbols. We probably have them already, unless
- finfo->info->keep_memory is false. */
+ finfo->info->keep_memory is FALSE. */
if (! aout_get_external_symbols (input_bfd))
- return false;
+ return FALSE;
sym_count = obj_aout_external_sym_count (input_bfd);
/* Write out the symbols and get a map of the new indices. The map
is placed into finfo->symbol_map. */
if (! aout_link_write_symbols (finfo, input_bfd))
- return false;
+ return FALSE;
/* Relocate and write out the sections. These functions use the
symbol map created by aout_link_write_symbols. The linker_mark
@@ -4048,7 +4091,7 @@ aout_link_input_bfd (finfo, input_bfd)
obj_textsec (input_bfd),
&finfo->treloff,
exec_hdr (input_bfd)->a_trsize))
- return false;
+ return FALSE;
}
if (obj_datasec (input_bfd)->linker_mark)
{
@@ -4056,7 +4099,7 @@ aout_link_input_bfd (finfo, input_bfd)
obj_datasec (input_bfd),
&finfo->dreloff,
exec_hdr (input_bfd)->a_drsize))
- return false;
+ return FALSE;
}
/* If we are not keeping memory, we don't need the symbols any
@@ -4065,16 +4108,16 @@ aout_link_input_bfd (finfo, input_bfd)
if (! finfo->info->keep_memory)
{
if (! aout_link_free_symbols (input_bfd))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Adjust and write out the symbols for an a.out file. Set the new
symbol indices into a symbol_map. */
-static boolean
+static bfd_boolean
aout_link_write_symbols (finfo, input_bfd)
struct aout_final_link_info *finfo;
bfd *input_bfd;
@@ -4090,8 +4133,8 @@ aout_link_write_symbols (finfo, input_bfd)
struct external_nlist *sym_end;
struct aout_link_hash_entry **sym_hash;
int *symbol_map;
- boolean pass;
- boolean skip_next;
+ bfd_boolean pass;
+ bfd_boolean skip_next;
output_bfd = finfo->output_bfd;
sym_count = obj_aout_external_sym_count (input_bfd);
@@ -4105,16 +4148,16 @@ aout_link_write_symbols (finfo, input_bfd)
if (strip != strip_all
&& (strip != strip_some
|| bfd_hash_lookup (finfo->info->keep_hash, input_bfd->filename,
- false, false) != NULL)
+ FALSE, FALSE) != NULL)
&& discard != discard_all)
{
H_PUT_8 (output_bfd, N_TEXT, outsym->e_type);
H_PUT_8 (output_bfd, 0, outsym->e_other);
H_PUT_16 (output_bfd, 0, outsym->e_desc);
strtab_index = add_to_stringtab (output_bfd, finfo->strtab,
- input_bfd->filename, false);
+ input_bfd->filename, FALSE);
if (strtab_index == (bfd_size_type) -1)
- return false;
+ return FALSE;
PUT_WORD (output_bfd, strtab_index, outsym->e_strx);
PUT_WORD (output_bfd,
(bfd_get_section_vma (output_bfd,
@@ -4125,8 +4168,8 @@ aout_link_write_symbols (finfo, input_bfd)
++outsym;
}
- pass = false;
- skip_next = false;
+ pass = FALSE;
+ skip_next = FALSE;
sym = obj_aout_external_syms (input_bfd);
sym_end = sym + sym_count;
sym_hash = obj_aout_sym_hashes (input_bfd);
@@ -4137,10 +4180,10 @@ aout_link_write_symbols (finfo, input_bfd)
const char *name;
int type;
struct aout_link_hash_entry *h;
- boolean skip;
+ bfd_boolean skip;
asection *symsec;
bfd_vma val = 0;
- boolean copy;
+ bfd_boolean copy;
/* We set *symbol_map to 0 above for all symbols. If it has
already been set to -1 for this symbol, it means that we are
@@ -4164,14 +4207,14 @@ aout_link_write_symbols (finfo, input_bfd)
/* Pass this symbol through. It is the target of an
indirect or warning symbol. */
val = GET_WORD (input_bfd, sym->e_value);
- pass = false;
+ pass = FALSE;
}
else if (skip_next)
{
/* Skip this symbol, which is the target of an indirect
symbol that we have changed to no longer be an indirect
symbol. */
- skip_next = false;
+ skip_next = FALSE;
continue;
}
else
@@ -4213,34 +4256,34 @@ aout_link_write_symbols (finfo, input_bfd)
{
if ((type & N_TYPE) == N_INDR
|| type == N_WARNING)
- skip_next = true;
+ skip_next = TRUE;
*symbol_map = h->indx;
continue;
}
/* See if we are stripping this symbol. */
- skip = false;
+ skip = FALSE;
switch (strip)
{
case strip_none:
break;
case strip_debugger:
if ((type & N_STAB) != 0)
- skip = true;
+ skip = TRUE;
break;
case strip_some:
- if (bfd_hash_lookup (finfo->info->keep_hash, name, false, false)
+ if (bfd_hash_lookup (finfo->info->keep_hash, name, FALSE, FALSE)
== NULL)
- skip = true;
+ skip = TRUE;
break;
case strip_all:
- skip = true;
+ skip = TRUE;
break;
}
if (skip)
{
if (h != (struct aout_link_hash_entry *) NULL)
- h->written = true;
+ h->written = TRUE;
continue;
}
@@ -4269,7 +4312,7 @@ aout_link_write_symbols (finfo, input_bfd)
the indirect symbol was defined, we output it with
the correct definition so the debugger will
understand it. */
- pass = true;
+ pass = TRUE;
val = GET_WORD (input_bfd, sym->e_value);
symsec = NULL;
}
@@ -4285,7 +4328,7 @@ aout_link_write_symbols (finfo, input_bfd)
a case we do not want to output the next symbol,
which is the target of the indirection. */
if ((type & N_TYPE) == N_INDR)
- skip_next = true;
+ skip_next = TRUE;
symsec = NULL;
@@ -4377,7 +4420,7 @@ aout_link_write_symbols (finfo, input_bfd)
it is a local symbol see if we should discard it. */
if (h != (struct aout_link_hash_entry *) NULL)
{
- h->written = true;
+ h->written = TRUE;
h->indx = obj_aout_external_sym_count (output_bfd);
}
else if ((type & N_TYPE) != N_SETT
@@ -4393,15 +4436,15 @@ aout_link_write_symbols (finfo, input_bfd)
case discard_l:
if ((type & N_STAB) == 0
&& bfd_is_local_label_name (input_bfd, name))
- skip = true;
+ skip = TRUE;
break;
case discard_all:
- skip = true;
+ skip = TRUE;
break;
}
if (skip)
{
- pass = false;
+ pass = FALSE;
continue;
}
}
@@ -4457,11 +4500,11 @@ aout_link_write_symbols (finfo, input_bfd)
/* If we have already included a header file with the
same value, then replace this one with an N_EXCL
symbol. */
- copy = (boolean) (! finfo->info->keep_memory);
+ copy = (bfd_boolean) (! finfo->info->keep_memory);
incl_entry = aout_link_includes_lookup (&finfo->includes,
- name, true, copy);
+ name, TRUE, copy);
if (incl_entry == NULL)
- return false;
+ return FALSE;
for (t = incl_entry->totals; t != NULL; t = t->next)
if (t->total == val)
break;
@@ -4473,7 +4516,7 @@ aout_link_write_symbols (finfo, input_bfd)
bfd_hash_allocate (&finfo->includes.root,
sizeof *t));
if (t == NULL)
- return false;
+ return FALSE;
t->total = val;
t->next = incl_entry->totals;
incl_entry->totals = t;
@@ -4518,7 +4561,7 @@ aout_link_write_symbols (finfo, input_bfd)
H_PUT_8 (output_bfd, type, outsym->e_type);
H_PUT_8 (output_bfd, H_GET_8 (input_bfd, sym->e_other), outsym->e_other);
H_PUT_16 (output_bfd, H_GET_16 (input_bfd, sym->e_desc), outsym->e_desc);
- copy = false;
+ copy = FALSE;
if (! finfo->info->keep_memory)
{
/* name points into a string table which we are going to
@@ -4527,12 +4570,12 @@ aout_link_write_symbols (finfo, input_bfd)
if (h != (struct aout_link_hash_entry *) NULL)
name = h->root.root.string;
else
- copy = true;
+ copy = TRUE;
}
strtab_index = add_to_stringtab (output_bfd, finfo->strtab,
name, copy);
if (strtab_index == (bfd_size_type) -1)
- return false;
+ return FALSE;
PUT_WORD (output_bfd, strtab_index, outsym->e_strx);
PUT_WORD (output_bfd, val, outsym->e_value);
*symbol_map = obj_aout_external_sym_count (output_bfd);
@@ -4546,22 +4589,22 @@ aout_link_write_symbols (finfo, input_bfd)
bfd_size_type outsym_size;
if (bfd_seek (output_bfd, finfo->symoff, SEEK_SET) != 0)
- return false;
+ return FALSE;
outsym_size = outsym - finfo->output_syms;
outsym_size *= EXTERNAL_NLIST_SIZE;
if (bfd_bwrite ((PTR) finfo->output_syms, outsym_size, output_bfd)
!= outsym_size)
- return false;
+ return FALSE;
finfo->symoff += outsym_size;
}
- return true;
+ return TRUE;
}
/* Write out a symbol that was not associated with an a.out input
object. */
-static boolean
+static bfd_boolean
aout_link_write_other_symbol (h, data)
struct aout_link_hash_entry *h;
PTR data;
@@ -4578,7 +4621,7 @@ aout_link_write_other_symbol (h, data)
{
h = (struct aout_link_hash_entry *) h->root.u.i.link;
if (h->root.type == bfd_link_hash_new)
- return true;
+ return TRUE;
}
output_bfd = finfo->output_bfd;
@@ -4594,17 +4637,17 @@ aout_link_write_other_symbol (h, data)
}
if (h->written)
- return true;
+ return TRUE;
- h->written = true;
+ h->written = TRUE;
/* An indx of -2 means the symbol must be written. */
if (h->indx != -2
&& (finfo->info->strip == strip_all
|| (finfo->info->strip == strip_some
&& bfd_hash_lookup (finfo->info->keep_hash, h->root.root.string,
- false, false) == NULL)))
- return true;
+ FALSE, FALSE) == NULL)))
+ return TRUE;
switch (h->root.type)
{
@@ -4612,11 +4655,11 @@ aout_link_write_other_symbol (h, data)
case bfd_link_hash_warning:
abort ();
/* Avoid variable not initialized warnings. */
- return true;
+ return TRUE;
case bfd_link_hash_new:
/* This can happen for set symbols when sets are not being
built. */
- return true;
+ return TRUE;
case bfd_link_hash_undefined:
type = N_UNDF | N_EXT;
val = 0;
@@ -4653,14 +4696,14 @@ aout_link_write_other_symbol (h, data)
case bfd_link_hash_indirect:
/* We ignore these symbols, since the indirected symbol is
already in the hash table. */
- return true;
+ return TRUE;
}
H_PUT_8 (output_bfd, type, outsym.e_type);
H_PUT_8 (output_bfd, 0, outsym.e_other);
H_PUT_16 (output_bfd, 0, outsym.e_desc);
indx = add_to_stringtab (output_bfd, finfo->strtab, h->root.root.string,
- false);
+ FALSE);
if (indx == - (bfd_size_type) 1)
{
/* FIXME: No way to handle errors. */
@@ -4681,12 +4724,12 @@ aout_link_write_other_symbol (h, data)
h->indx = obj_aout_external_sym_count (output_bfd);
++obj_aout_external_sym_count (output_bfd);
- return true;
+ return TRUE;
}
/* Link an a.out section into the output file. */
-static boolean
+static bfd_boolean
aout_link_input_section (finfo, input_bfd, input_section, reloff_ptr,
rel_size)
struct aout_final_link_info *finfo;
@@ -4703,7 +4746,7 @@ aout_link_input_section (finfo, input_bfd, input_section, reloff_ptr,
if (! bfd_get_section_contents (input_bfd, input_section,
(PTR) finfo->contents,
(file_ptr) 0, input_size))
- return false;
+ return FALSE;
/* Read in the relocs if we haven't already done it. */
if (aout_section_data (input_section) != NULL
@@ -4716,7 +4759,7 @@ aout_link_input_section (finfo, input_bfd, input_section, reloff_ptr,
{
if (bfd_seek (input_bfd, input_section->rel_filepos, SEEK_SET) != 0
|| bfd_bread (relocs, rel_size, input_bfd) != rel_size)
- return false;
+ return FALSE;
}
}
@@ -4726,14 +4769,14 @@ aout_link_input_section (finfo, input_bfd, input_section, reloff_ptr,
if (! aout_link_input_section_std (finfo, input_bfd, input_section,
(struct reloc_std_external *) relocs,
rel_size, finfo->contents))
- return false;
+ return FALSE;
}
else
{
if (! aout_link_input_section_ext (finfo, input_bfd, input_section,
(struct reloc_ext_external *) relocs,
rel_size, finfo->contents))
- return false;
+ return FALSE;
}
/* Write out the section contents. */
@@ -4742,16 +4785,16 @@ aout_link_input_section (finfo, input_bfd, input_section, reloff_ptr,
(PTR) finfo->contents,
(file_ptr) input_section->output_offset,
input_size))
- return false;
+ return FALSE;
- /* If we are producing relocateable output, the relocs were
+ /* If we are producing relocatable output, the relocs were
modified, and we now write them out. */
- if (finfo->info->relocateable && rel_size > 0)
+ if (finfo->info->relocatable && rel_size > 0)
{
if (bfd_seek (finfo->output_bfd, *reloff_ptr, SEEK_SET) != 0)
- return false;
+ return FALSE;
if (bfd_bwrite (relocs, rel_size, finfo->output_bfd) != rel_size)
- return false;
+ return FALSE;
*reloff_ptr += rel_size;
/* Assert that the relocs have not run into the symbols, and
@@ -4763,7 +4806,7 @@ aout_link_input_section (finfo, input_bfd, input_section, reloff_ptr,
<= obj_datasec (finfo->output_bfd)->rel_filepos)));
}
- return true;
+ return TRUE;
}
/* Get the section corresponding to a reloc index. */
@@ -4793,7 +4836,7 @@ aout_reloc_index_to_section (abfd, indx)
/* Relocate an a.out section using standard a.out relocs. */
-static boolean
+static bfd_boolean
aout_link_input_section_std (finfo, input_bfd, input_section, relocs,
rel_size, contents)
struct aout_final_link_info *finfo;
@@ -4803,13 +4846,12 @@ aout_link_input_section_std (finfo, input_bfd, input_section, relocs,
bfd_size_type rel_size;
bfd_byte *contents;
{
- boolean (*check_dynamic_reloc) PARAMS ((struct bfd_link_info *,
- bfd *, asection *,
- struct aout_link_hash_entry *,
- PTR, bfd_byte *, boolean *,
- bfd_vma *));
+ bfd_boolean (*check_dynamic_reloc)
+ PARAMS ((struct bfd_link_info *, bfd *, asection *,
+ struct aout_link_hash_entry *, PTR, bfd_byte *, bfd_boolean *,
+ bfd_vma *));
bfd *output_bfd;
- boolean relocateable;
+ bfd_boolean relocatable;
struct external_nlist *syms;
char *strings;
struct aout_link_hash_entry **sym_hashes;
@@ -4825,7 +4867,7 @@ aout_link_input_section_std (finfo, input_bfd, input_section, relocs,
BFD_ASSERT (input_bfd->xvec->header_byteorder
== output_bfd->xvec->header_byteorder);
- relocateable = finfo->info->relocateable;
+ relocatable = finfo->info->relocatable;
syms = obj_aout_external_syms (input_bfd);
strings = obj_aout_external_strings (input_bfd);
sym_hashes = obj_aout_sym_hashes (input_bfd);
@@ -4894,9 +4936,9 @@ aout_link_input_section_std (finfo, input_bfd, input_section, relocs,
}
#endif
- if (relocateable)
+ if (relocatable)
{
- /* We are generating a relocateable output file, and must
+ /* We are generating a relocatable output file, and must
modify the reloc accordingly. */
if (r_extern)
{
@@ -4951,10 +4993,10 @@ aout_link_input_section_std (finfo, input_bfd, input_section, relocs,
if (h->indx < 0)
{
h->indx = -2;
- h->written = false;
+ h->written = FALSE;
if (! aout_link_write_other_symbol (h,
(PTR) finfo))
- return false;
+ return FALSE;
}
r_index = h->indx;
}
@@ -4967,7 +5009,7 @@ aout_link_input_section_std (finfo, input_bfd, input_section, relocs,
if (! ((*finfo->info->callbacks->unattached_reloc)
(finfo->info, name, input_bfd, input_section,
r_addr)))
- return false;
+ return FALSE;
r_index = 0;
}
}
@@ -5027,11 +5069,11 @@ aout_link_input_section_std (finfo, input_bfd, input_section, relocs,
}
else
{
- boolean hundef;
+ bfd_boolean hundef;
/* We are generating an executable, and must do a full
relocation. */
- hundef = false;
+ hundef = FALSE;
if (r_extern)
{
@@ -5050,7 +5092,7 @@ aout_link_input_section_std (finfo, input_bfd, input_section, relocs,
relocation = 0;
else
{
- hundef = true;
+ hundef = TRUE;
relocation = 0;
}
}
@@ -5068,12 +5110,12 @@ aout_link_input_section_std (finfo, input_bfd, input_section, relocs,
if (check_dynamic_reloc != NULL)
{
- boolean skip;
+ bfd_boolean skip;
if (! ((*check_dynamic_reloc)
(finfo->info, input_bfd, input_section, h,
(PTR) rel, contents, &skip, &relocation)))
- return false;
+ return FALSE;
if (skip)
continue;
}
@@ -5091,8 +5133,8 @@ aout_link_input_section_std (finfo, input_bfd, input_section, relocs,
name = strings + GET_WORD (input_bfd, syms[r_index].e_strx);
if (! ((*finfo->info->callbacks->undefined_symbol)
(finfo->info, name, input_bfd, input_section,
- r_addr, true)))
- return false;
+ r_addr, TRUE)))
+ return FALSE;
}
r = MY_final_link_relocate (howto,
@@ -5127,19 +5169,19 @@ aout_link_input_section_std (finfo, input_bfd, input_section, relocs,
if (! ((*finfo->info->callbacks->reloc_overflow)
(finfo->info, name, howto->name,
(bfd_vma) 0, input_bfd, input_section, r_addr)))
- return false;
+ return FALSE;
}
break;
}
}
}
- return true;
+ return TRUE;
}
/* Relocate an a.out section using extended a.out relocs. */
-static boolean
+static bfd_boolean
aout_link_input_section_ext (finfo, input_bfd, input_section, relocs,
rel_size, contents)
struct aout_final_link_info *finfo;
@@ -5149,13 +5191,12 @@ aout_link_input_section_ext (finfo, input_bfd, input_section, relocs,
bfd_size_type rel_size;
bfd_byte *contents;
{
- boolean (*check_dynamic_reloc) PARAMS ((struct bfd_link_info *,
- bfd *, asection *,
- struct aout_link_hash_entry *,
- PTR, bfd_byte *, boolean *,
- bfd_vma *));
+ bfd_boolean (*check_dynamic_reloc)
+ PARAMS ((struct bfd_link_info *, bfd *, asection *,
+ struct aout_link_hash_entry *, PTR, bfd_byte *, bfd_boolean *,
+ bfd_vma *));
bfd *output_bfd;
- boolean relocateable;
+ bfd_boolean relocatable;
struct external_nlist *syms;
char *strings;
struct aout_link_hash_entry **sym_hashes;
@@ -5171,7 +5212,7 @@ aout_link_input_section_ext (finfo, input_bfd, input_section, relocs,
BFD_ASSERT (input_bfd->xvec->header_byteorder
== output_bfd->xvec->header_byteorder);
- relocateable = finfo->info->relocateable;
+ relocatable = finfo->info->relocatable;
syms = obj_aout_external_syms (input_bfd);
strings = obj_aout_external_strings (input_bfd);
sym_hashes = obj_aout_sym_hashes (input_bfd);
@@ -5216,9 +5257,9 @@ aout_link_input_section_ext (finfo, input_bfd, input_section, relocs,
BFD_ASSERT (r_type < TABLE_SIZE (howto_table_ext));
- if (relocateable)
+ if (relocatable)
{
- /* We are generating a relocateable output file, and must
+ /* We are generating a relocatable output file, and must
modify the reloc accordingly. */
if (r_extern
|| r_type == (unsigned int) RELOC_BASE10
@@ -5289,10 +5330,10 @@ aout_link_input_section_ext (finfo, input_bfd, input_section, relocs,
if (h->indx < 0)
{
h->indx = -2;
- h->written = false;
+ h->written = FALSE;
if (! aout_link_write_other_symbol (h,
(PTR) finfo))
- return false;
+ return FALSE;
}
r_index = h->indx;
}
@@ -5305,7 +5346,7 @@ aout_link_input_section_ext (finfo, input_bfd, input_section, relocs,
if (! ((*finfo->info->callbacks->unattached_reloc)
(finfo->info, name, input_bfd, input_section,
r_addr)))
- return false;
+ return FALSE;
r_index = 0;
}
}
@@ -5370,12 +5411,12 @@ aout_link_input_section_ext (finfo, input_bfd, input_section, relocs,
}
else
{
- boolean hundef;
+ bfd_boolean hundef;
bfd_reloc_status_type r;
/* We are generating an executable, and must do a full
relocation. */
- hundef = false;
+ hundef = FALSE;
if (r_extern)
{
@@ -5394,7 +5435,7 @@ aout_link_input_section_ext (finfo, input_bfd, input_section, relocs,
relocation = 0;
else
{
- hundef = true;
+ hundef = TRUE;
relocation = 0;
}
}
@@ -5467,12 +5508,12 @@ aout_link_input_section_ext (finfo, input_bfd, input_section, relocs,
if (check_dynamic_reloc != NULL)
{
- boolean skip;
+ bfd_boolean skip;
if (! ((*check_dynamic_reloc)
(finfo->info, input_bfd, input_section, h,
(PTR) rel, contents, &skip, &relocation)))
- return false;
+ return FALSE;
if (skip)
continue;
}
@@ -5494,8 +5535,8 @@ aout_link_input_section_ext (finfo, input_bfd, input_section, relocs,
name = strings + GET_WORD (input_bfd, syms[r_index].e_strx);
if (! ((*finfo->info->callbacks->undefined_symbol)
(finfo->info, name, input_bfd, input_section,
- r_addr, true)))
- return false;
+ r_addr, TRUE)))
+ return FALSE;
}
if (r_type != (unsigned int) RELOC_SPARC_REV32)
@@ -5542,7 +5583,7 @@ aout_link_input_section_ext (finfo, input_bfd, input_section, relocs,
if (! ((*finfo->info->callbacks->reloc_overflow)
(finfo->info, name, howto_table_ext[r_type].name,
r_addend, input_bfd, input_section, r_addr)))
- return false;
+ return FALSE;
}
break;
}
@@ -5550,12 +5591,12 @@ aout_link_input_section_ext (finfo, input_bfd, input_section, relocs,
}
}
- return true;
+ return TRUE;
}
/* Handle a link order which is supposed to generate a reloc. */
-static boolean
+static bfd_boolean
aout_link_reloc_link_order (finfo, o, p)
struct aout_final_link_info *finfo;
asection *o;
@@ -5592,7 +5633,7 @@ aout_link_reloc_link_order (finfo, o, p)
r_extern = 1;
h = ((struct aout_link_hash_entry *)
bfd_wrapped_link_hash_lookup (finfo->output_bfd, finfo->info,
- pr->u.name, false, false, true));
+ pr->u.name, FALSE, FALSE, TRUE));
if (h != (struct aout_link_hash_entry *) NULL
&& h->indx >= 0)
r_index = h->indx;
@@ -5603,9 +5644,9 @@ aout_link_reloc_link_order (finfo, o, p)
here. I don't think that will ever matter for a global
symbol. */
h->indx = -2;
- h->written = false;
+ h->written = FALSE;
if (! aout_link_write_other_symbol (h, (PTR) finfo))
- return false;
+ return FALSE;
r_index = h->indx;
}
else
@@ -5613,7 +5654,7 @@ aout_link_reloc_link_order (finfo, o, p)
if (! ((*finfo->info->callbacks->unattached_reloc)
(finfo->info, pr->u.name, (bfd *) NULL,
(asection *) NULL, (bfd_vma) 0)))
- return false;
+ return FALSE;
r_index = 0;
}
}
@@ -5622,7 +5663,7 @@ aout_link_reloc_link_order (finfo, o, p)
if (howto == 0)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
if (o == obj_textsec (finfo->output_bfd))
@@ -5692,12 +5733,12 @@ aout_link_reloc_link_order (finfo, o, p)
bfd_size_type size;
bfd_reloc_status_type r;
bfd_byte *buf;
- boolean ok;
+ bfd_boolean ok;
size = bfd_get_reloc_size (howto);
buf = (bfd_byte *) bfd_zmalloc (size);
if (buf == (bfd_byte *) NULL)
- return false;
+ return FALSE;
r = MY_relocate_contents (howto, finfo->output_bfd,
(bfd_vma) pr->addend, buf);
switch (r)
@@ -5718,7 +5759,7 @@ aout_link_reloc_link_order (finfo, o, p)
(asection *) NULL, (bfd_vma) 0)))
{
free (buf);
- return false;
+ return FALSE;
}
break;
}
@@ -5726,7 +5767,7 @@ aout_link_reloc_link_order (finfo, o, p)
(file_ptr) p->offset, size);
free (buf);
if (! ok)
- return false;
+ return FALSE;
}
}
else
@@ -5765,7 +5806,7 @@ aout_link_reloc_link_order (finfo, o, p)
amt = obj_reloc_entry_size (finfo->output_bfd);
if (bfd_seek (finfo->output_bfd, *reloff_ptr, SEEK_SET) != 0
|| bfd_bwrite (rel_ptr, amt, finfo->output_bfd) != amt)
- return false;
+ return FALSE;
*reloff_ptr += obj_reloc_entry_size (finfo->output_bfd);
@@ -5776,5 +5817,5 @@ aout_link_reloc_link_order (finfo, o, p)
|| (*reloff_ptr
<= obj_datasec (finfo->output_bfd)->rel_filepos)));
- return true;
+ return TRUE;
}
diff --git a/contrib/binutils/bfd/archive.c b/contrib/binutils/bfd/archive.c
index b051e2a..ba6e684 100644
--- a/contrib/binutils/bfd/archive.c
+++ b/contrib/binutils/bfd/archive.c
@@ -1,6 +1,6 @@
/* BFD back-end for archive files (libraries).
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Support. Mostly Gumby Henkel-Wallace's fault.
@@ -158,27 +158,17 @@ struct ar_cache {
#define ar_maxnamelen(abfd) ((abfd)->xvec->ar_max_namelen)
#define arch_eltdata(bfd) ((struct areltdata *) ((bfd)->arelt_data))
-#define arch_hdr(bfd) ((struct ar_hdr *)arch_eltdata(bfd)->arch_header)
-
-static char *get_extended_arelt_filename PARAMS ((bfd *arch,
- const char *name));
-static boolean do_slurp_bsd_armap PARAMS ((bfd *abfd));
-static boolean do_slurp_coff_armap PARAMS ((bfd *abfd));
-boolean bfd_elf64_archive_slurp_armap PARAMS ((bfd *abfd));
-static const char *normalize PARAMS ((bfd *, const char *file));
-static struct areltdata *bfd_ar_hdr_from_filesystem PARAMS ((bfd *abfd,
- const char *,
- bfd *member));
+#define arch_hdr(bfd) ((struct ar_hdr *) arch_eltdata(bfd)->arch_header)
+
-boolean
-_bfd_generic_mkarchive (abfd)
- bfd *abfd;
+bfd_boolean
+_bfd_generic_mkarchive (bfd *abfd)
{
bfd_size_type amt = sizeof (struct artdata);
- abfd->tdata.aout_ar_data = (struct artdata *) bfd_zalloc (abfd, amt);
+ abfd->tdata.aout_ar_data = bfd_zalloc (abfd, amt);
if (bfd_ardata (abfd) == NULL)
- return false;
+ return FALSE;
bfd_ardata (abfd)->cache = NULL;
bfd_ardata (abfd)->archive_head = NULL;
@@ -186,7 +176,7 @@ _bfd_generic_mkarchive (abfd)
bfd_ardata (abfd)->extended_names = NULL;
bfd_ardata (abfd)->tdata = NULL;
- return true;
+ return TRUE;
}
/*
@@ -194,7 +184,8 @@ FUNCTION
bfd_get_next_mapent
SYNOPSIS
- symindex bfd_get_next_mapent(bfd *abfd, symindex previous, carsym **sym);
+ symindex bfd_get_next_mapent
+ (bfd *abfd, symindex previous, carsym **sym);
DESCRIPTION
Step through archive @var{abfd}'s symbol table (if it
@@ -211,10 +202,7 @@ DESCRIPTION
*/
symindex
-bfd_get_next_mapent (abfd, prev, entry)
- bfd *abfd;
- symindex prev;
- carsym **entry;
+bfd_get_next_mapent (bfd *abfd, symindex prev, carsym **entry)
{
if (!bfd_has_map (abfd))
{
@@ -236,8 +224,7 @@ bfd_get_next_mapent (abfd, prev, entry)
/* To be called by backends only */
bfd *
-_bfd_create_empty_archive_element_shell (obfd)
- bfd *obfd;
+_bfd_create_empty_archive_element_shell (bfd *obfd)
{
return _bfd_new_bfd_contained_in (obfd);
}
@@ -247,27 +234,22 @@ FUNCTION
bfd_set_archive_head
SYNOPSIS
- boolean bfd_set_archive_head(bfd *output, bfd *new_head);
+ bfd_boolean bfd_set_archive_head (bfd *output, bfd *new_head);
DESCRIPTION
Set the head of the chain of
BFDs contained in the archive @var{output} to @var{new_head}.
*/
-boolean
-bfd_set_archive_head (output_archive, new_head)
- bfd *output_archive;
- bfd *new_head;
+bfd_boolean
+bfd_set_archive_head (bfd *output_archive, bfd *new_head)
{
-
output_archive->archive_head = new_head;
- return true;
+ return TRUE;
}
bfd *
-_bfd_look_for_bfd_in_cache (arch_bfd, filepos)
- bfd *arch_bfd;
- file_ptr filepos;
+_bfd_look_for_bfd_in_cache (bfd *arch_bfd, file_ptr filepos)
{
struct ar_cache *current;
@@ -280,20 +262,18 @@ _bfd_look_for_bfd_in_cache (arch_bfd, filepos)
}
/* Kind of stupid to call cons for each one, but we don't do too many */
-boolean
-_bfd_add_bfd_to_archive_cache (arch_bfd, filepos, new_elt)
- bfd *arch_bfd, *new_elt;
- file_ptr filepos;
+bfd_boolean
+_bfd_add_bfd_to_archive_cache (bfd *arch_bfd, file_ptr filepos, bfd *new_elt)
{
bfd_size_type amt = sizeof (struct ar_cache);
- struct ar_cache *new_cache = (struct ar_cache *) bfd_zalloc (arch_bfd, amt);
+ struct ar_cache *new_cache = bfd_zalloc (arch_bfd, amt);
if (new_cache == NULL)
- return false;
+ return FALSE;
new_cache->ptr = filepos;
new_cache->arelt = new_elt;
- new_cache->next = (struct ar_cache *) NULL;
+ new_cache->next = NULL;
if (bfd_ardata (arch_bfd)->cache == NULL)
bfd_ardata (arch_bfd)->cache = new_cache;
else
@@ -305,16 +285,14 @@ _bfd_add_bfd_to_archive_cache (arch_bfd, filepos, new_elt)
current->next = new_cache;
}
- return true;
+ return TRUE;
}
/* The name begins with space. Hence the rest of the name is an index into
the string table. */
static char *
-get_extended_arelt_filename (arch, name)
- bfd *arch;
- const char *name;
+get_extended_arelt_filename (bfd *arch, const char *name)
{
unsigned long index = 0;
@@ -341,20 +319,17 @@ get_extended_arelt_filename (arch, name)
could have been moved arbitrarily.
*/
-PTR
-_bfd_generic_read_ar_hdr (abfd)
- bfd *abfd;
+void *
+_bfd_generic_read_ar_hdr (bfd *abfd)
{
- return _bfd_generic_read_ar_hdr_mag (abfd, (const char *) NULL);
+ return _bfd_generic_read_ar_hdr_mag (abfd, NULL);
}
/* Alpha ECOFF uses an optional different ARFMAG value, so we have a
variant of _bfd_generic_read_ar_hdr which accepts a magic string. */
-PTR
-_bfd_generic_read_ar_hdr_mag (abfd, mag)
- bfd *abfd;
- const char *mag;
+void *
+_bfd_generic_read_ar_hdr_mag (bfd *abfd, const char *mag)
{
struct ar_hdr hdr;
char *hdrp = (char *) &hdr;
@@ -365,8 +340,7 @@ _bfd_generic_read_ar_hdr_mag (abfd, mag)
bfd_size_type allocsize = sizeof (struct areltdata) + sizeof (struct ar_hdr);
char *allocptr = 0;
- if (bfd_bread ((PTR) hdrp, (bfd_size_type) sizeof (struct ar_hdr), abfd)
- != sizeof (struct ar_hdr))
+ if (bfd_bread (hdrp, sizeof (struct ar_hdr), abfd) != sizeof (struct ar_hdr))
{
if (bfd_get_error () != bfd_error_system_call)
bfd_set_error (bfd_error_no_more_archived_files);
@@ -436,12 +410,12 @@ _bfd_generic_read_ar_hdr_mag (abfd, mag)
spaces, so only look for ' ' if we don't find '/'. */
char *e;
- e = (char *) memchr (hdr.ar_name, '\0', ar_maxnamelen (abfd));
+ e = memchr (hdr.ar_name, '\0', ar_maxnamelen (abfd));
if (e == NULL)
{
- e = (char *) memchr (hdr.ar_name, '/', ar_maxnamelen (abfd));
+ e = memchr (hdr.ar_name, '/', ar_maxnamelen (abfd));
if (e == NULL)
- e = (char *) memchr (hdr.ar_name, ' ', ar_maxnamelen (abfd));
+ e = memchr (hdr.ar_name, ' ', ar_maxnamelen (abfd));
}
if (e != NULL)
@@ -466,7 +440,7 @@ _bfd_generic_read_ar_hdr_mag (abfd, mag)
ared = (struct areltdata *) allocptr;
ared->arch_header = allocptr + sizeof (struct areltdata);
- memcpy ((char *) ared->arch_header, (char *) &hdr, sizeof (struct ar_hdr));
+ memcpy (ared->arch_header, &hdr, sizeof (struct ar_hdr));
ared->parsed_size = parsed_size;
if (filename != NULL)
@@ -476,11 +450,11 @@ _bfd_generic_read_ar_hdr_mag (abfd, mag)
ared->filename = allocptr + (sizeof (struct areltdata) +
sizeof (struct ar_hdr));
if (namelen)
- memcpy (ared->filename, hdr.ar_name, (size_t) namelen);
+ memcpy (ared->filename, hdr.ar_name, namelen);
ared->filename[namelen] = '\0';
}
- return (PTR) ared;
+ return ared;
}
/* This is an internal function; it's mainly used when indexing
@@ -488,9 +462,7 @@ _bfd_generic_read_ar_hdr_mag (abfd, mag)
element, since it handles the bookkeeping so nicely for us. */
bfd *
-_bfd_get_elt_at_filepos (archive, filepos)
- bfd *archive;
- file_ptr filepos;
+_bfd_get_elt_at_filepos (bfd *archive, file_ptr filepos)
{
struct areltdata *new_areldata;
bfd *n_nfd;
@@ -502,26 +474,26 @@ _bfd_get_elt_at_filepos (archive, filepos)
if (0 > bfd_seek (archive, filepos, SEEK_SET))
return NULL;
- if ((new_areldata = (struct areltdata *) _bfd_read_ar_hdr (archive)) == NULL)
+ if ((new_areldata = _bfd_read_ar_hdr (archive)) == NULL)
return NULL;
n_nfd = _bfd_create_empty_archive_element_shell (archive);
if (n_nfd == NULL)
{
- bfd_release (archive, (PTR) new_areldata);
+ bfd_release (archive, new_areldata);
return NULL;
}
n_nfd->origin = bfd_tell (archive);
- n_nfd->arelt_data = (PTR) new_areldata;
+ n_nfd->arelt_data = new_areldata;
n_nfd->filename = new_areldata->filename;
if (_bfd_add_bfd_to_archive_cache (archive, filepos, n_nfd))
return n_nfd;
/* Huh? */
- bfd_release (archive, (PTR) n_nfd);
- bfd_release (archive, (PTR) new_areldata);
+ bfd_release (archive, n_nfd);
+ bfd_release (archive, new_areldata);
return NULL;
}
@@ -529,9 +501,7 @@ _bfd_get_elt_at_filepos (archive, filepos)
INDEX. INDEX should have been returned by bfd_get_next_mapent. */
bfd *
-_bfd_generic_get_elt_at_index (abfd, index)
- bfd *abfd;
- symindex index;
+_bfd_generic_get_elt_at_index (bfd *abfd, symindex index)
{
carsym *entry;
@@ -544,7 +514,7 @@ FUNCTION
bfd_openr_next_archived_file
SYNOPSIS
- bfd *bfd_openr_next_archived_file(bfd *archive, bfd *previous);
+ bfd *bfd_openr_next_archived_file (bfd *archive, bfd *previous);
DESCRIPTION
Provided a BFD, @var{archive}, containing an archive and NULL, open
@@ -556,9 +526,7 @@ DESCRIPTION
*/
bfd *
-bfd_openr_next_archived_file (archive, last_file)
- bfd *archive;
- bfd *last_file;
+bfd_openr_next_archived_file (bfd *archive, bfd *last_file)
{
if ((bfd_get_format (archive) != bfd_archive) ||
(archive->direction == write_direction))
@@ -568,15 +536,11 @@ bfd_openr_next_archived_file (archive, last_file)
}
return BFD_SEND (archive,
- openr_next_archived_file,
- (archive,
- last_file));
+ openr_next_archived_file, (archive, last_file));
}
bfd *
-bfd_generic_openr_next_archived_file (archive, last_file)
- bfd *archive;
- bfd *last_file;
+bfd_generic_openr_next_archived_file (bfd *archive, bfd *last_file)
{
file_ptr filestart;
@@ -596,14 +560,13 @@ bfd_generic_openr_next_archived_file (archive, last_file)
}
const bfd_target *
-bfd_generic_archive_p (abfd)
- bfd *abfd;
+bfd_generic_archive_p (bfd *abfd)
{
struct artdata *tdata_hold;
char armag[SARMAG + 1];
bfd_size_type amt;
- if (bfd_bread ((PTR) armag, (bfd_size_type) SARMAG, abfd) != SARMAG)
+ if (bfd_bread (armag, SARMAG, abfd) != SARMAG)
{
if (bfd_get_error () != bfd_error_system_call)
bfd_set_error (bfd_error_wrong_format);
@@ -622,7 +585,7 @@ bfd_generic_archive_p (abfd)
tdata_hold = bfd_ardata (abfd);
amt = sizeof (struct artdata);
- bfd_ardata (abfd) = (struct artdata *) bfd_zalloc (abfd, amt);
+ bfd_ardata (abfd) = bfd_zalloc (abfd, amt);
if (bfd_ardata (abfd) == NULL)
{
bfd_ardata (abfd) = tdata_hold;
@@ -661,13 +624,13 @@ bfd_generic_archive_p (abfd)
normal archive, regardless of the format of the object files.
We do accept an empty archive. */
- first = bfd_openr_next_archived_file (abfd, (bfd *) NULL);
+ first = bfd_openr_next_archived_file (abfd, NULL);
if (first != NULL)
{
- boolean fail;
+ bfd_boolean fail;
- first->target_defaulted = false;
- fail = false;
+ first->target_defaulted = FALSE;
+ fail = FALSE;
if (bfd_check_format (first, bfd_object)
&& first->xvec != abfd->xvec)
{
@@ -676,7 +639,7 @@ bfd_generic_archive_p (abfd)
we have no way to remove it from the archive cache.
It's close to impossible to figure out when we can
release bfd_ardata. FIXME. */
- (void) bfd_close (first);
+ bfd_close (first);
bfd_release (abfd, bfd_ardata (abfd));
#endif
bfd_set_error (bfd_error_wrong_object_format);
@@ -707,11 +670,10 @@ bfd_generic_archive_p (abfd)
/* The size of the string count. */
#define BSD_STRING_COUNT_SIZE 4
-/* Returns false on error, true otherwise */
+/* Returns FALSE on error, TRUE otherwise */
-static boolean
-do_slurp_bsd_armap (abfd)
- bfd *abfd;
+static bfd_boolean
+do_slurp_bsd_armap (bfd *abfd)
{
struct areltdata *mapdata;
unsigned int counter;
@@ -721,23 +683,23 @@ do_slurp_bsd_armap (abfd)
bfd_size_type parsed_size, amt;
carsym *set;
- mapdata = (struct areltdata *) _bfd_read_ar_hdr (abfd);
+ mapdata = _bfd_read_ar_hdr (abfd);
if (mapdata == NULL)
- return false;
+ return FALSE;
parsed_size = mapdata->parsed_size;
- bfd_release (abfd, (PTR) mapdata); /* Don't need it any more. */
+ bfd_release (abfd, mapdata); /* Don't need it any more. */
- raw_armap = (bfd_byte *) bfd_zalloc (abfd, parsed_size);
- if (raw_armap == (bfd_byte *) NULL)
- return false;
+ raw_armap = bfd_zalloc (abfd, parsed_size);
+ if (raw_armap == NULL)
+ return FALSE;
- if (bfd_bread ((PTR) raw_armap, parsed_size, abfd) != parsed_size)
+ if (bfd_bread (raw_armap, parsed_size, abfd) != parsed_size)
{
if (bfd_get_error () != bfd_error_system_call)
bfd_set_error (bfd_error_malformed_archive);
byebye:
- bfd_release (abfd, (PTR) raw_armap);
- return false;
+ bfd_release (abfd, raw_armap);
+ return FALSE;
}
ardata->symdef_count = H_GET_32 (abfd, raw_armap) / BSD_SYMDEF_SIZE;
@@ -755,10 +717,10 @@ do_slurp_bsd_armap (abfd)
stringbase = ((char *) rbase
+ ardata->symdef_count * BSD_SYMDEF_SIZE
+ BSD_STRING_COUNT_SIZE);
- amt = (bfd_size_type) ardata->symdef_count * sizeof (carsym);
- ardata->symdefs = (carsym *) bfd_alloc (abfd, amt);
+ amt = ardata->symdef_count * sizeof (carsym);
+ ardata->symdefs = bfd_alloc (abfd, amt);
if (!ardata->symdefs)
- return false;
+ return FALSE;
for (counter = 0, set = ardata->symdefs;
counter < ardata->symdef_count;
@@ -774,15 +736,14 @@ do_slurp_bsd_armap (abfd)
/* FIXME, we should provide some way to free raw_ardata when
we are done using the strings from it. For now, it seems
to be allocated on an objalloc anyway... */
- bfd_has_map (abfd) = true;
- return true;
+ bfd_has_map (abfd) = TRUE;
+ return TRUE;
}
-/* Returns false on error, true otherwise. */
+/* Returns FALSE on error, TRUE otherwise. */
-static boolean
-do_slurp_coff_armap (abfd)
- bfd *abfd;
+static bfd_boolean
+do_slurp_coff_armap (bfd *abfd)
{
struct areltdata *mapdata;
int *raw_armap, *rawptr;
@@ -792,27 +753,27 @@ do_slurp_coff_armap (abfd)
unsigned int parsed_size;
carsym *carsyms;
bfd_size_type nsymz; /* Number of symbols in armap. */
- bfd_vma (*swap) PARAMS ((const bfd_byte *));
+ bfd_vma (*swap) (const void *);
char int_buf[sizeof (long)];
bfd_size_type carsym_size, ptrsize;
unsigned int i;
- mapdata = (struct areltdata *) _bfd_read_ar_hdr (abfd);
+ mapdata = _bfd_read_ar_hdr (abfd);
if (mapdata == NULL)
- return false;
+ return FALSE;
parsed_size = mapdata->parsed_size;
- bfd_release (abfd, (PTR) mapdata); /* Don't need it any more. */
+ bfd_release (abfd, mapdata); /* Don't need it any more. */
- if (bfd_bread ((PTR) int_buf, (bfd_size_type) 4, abfd) != 4)
+ if (bfd_bread (int_buf, 4, abfd) != 4)
{
if (bfd_get_error () != bfd_error_system_call)
bfd_set_error (bfd_error_malformed_archive);
- return false;
+ return FALSE;
}
/* It seems that all numeric information in a coff archive is always
in big endian format, nomatter the host or target. */
swap = bfd_getb32;
- nsymz = bfd_getb32 ((PTR) int_buf);
+ nsymz = bfd_getb32 (int_buf);
stringsize = parsed_size - (4 * nsymz) - 4;
#if 1
@@ -826,7 +787,7 @@ do_slurp_coff_armap (abfd)
&& bfd_get_flavour (abfd) == bfd_target_coff_flavour)
{
/* This looks dangerous, let's do it the other way around. */
- nsymz = bfd_getl32 ((PTR) int_buf);
+ nsymz = bfd_getl32 (int_buf);
stringsize = parsed_size - (4 * nsymz) - 4;
swap = bfd_getl32;
}
@@ -838,18 +799,18 @@ do_slurp_coff_armap (abfd)
carsym_size = (nsymz * sizeof (carsym));
ptrsize = (4 * nsymz);
- ardata->symdefs = (carsym *) bfd_zalloc (abfd, carsym_size + stringsize + 1);
+ ardata->symdefs = bfd_zalloc (abfd, carsym_size + stringsize + 1);
if (ardata->symdefs == NULL)
- return false;
+ return FALSE;
carsyms = ardata->symdefs;
stringbase = ((char *) ardata->symdefs) + carsym_size;
/* Allocate and read in the raw offsets. */
- raw_armap = (int *) bfd_alloc (abfd, ptrsize);
+ raw_armap = bfd_alloc (abfd, ptrsize);
if (raw_armap == NULL)
goto release_symdefs;
- if (bfd_bread ((PTR) raw_armap, ptrsize, abfd) != ptrsize
- || (bfd_bread ((PTR) stringbase, stringsize, abfd) != stringsize))
+ if (bfd_bread (raw_armap, ptrsize, abfd) != ptrsize
+ || (bfd_bread (stringbase, stringsize, abfd) != stringsize))
{
if (bfd_get_error () != bfd_error_system_call)
bfd_set_error (bfd_error_malformed_archive);
@@ -860,7 +821,7 @@ do_slurp_coff_armap (abfd)
for (i = 0; i < nsymz; i++)
{
rawptr = raw_armap + i;
- carsyms->file_offset = swap ((PTR) rawptr);
+ carsyms->file_offset = swap ((bfd_byte *) rawptr);
carsyms->name = stringbase;
stringbase += strlen (stringbase) + 1;
carsyms++;
@@ -872,15 +833,15 @@ do_slurp_coff_armap (abfd)
/* Pad to an even boundary if you have to. */
ardata->first_file_filepos += (ardata->first_file_filepos) % 2;
- bfd_has_map (abfd) = true;
- bfd_release (abfd, (PTR) raw_armap);
+ bfd_has_map (abfd) = TRUE;
+ bfd_release (abfd, raw_armap);
/* Check for a second archive header (as used by PE). */
{
struct areltdata *tmp;
bfd_seek (abfd, ardata->first_file_filepos, SEEK_SET);
- tmp = (struct areltdata *) _bfd_read_ar_hdr (abfd);
+ tmp = _bfd_read_ar_hdr (abfd);
if (tmp != NULL)
{
if (tmp->arch_header[0] == '/'
@@ -893,32 +854,31 @@ do_slurp_coff_armap (abfd)
}
}
- return true;
+ return TRUE;
release_raw_armap:
- bfd_release (abfd, (PTR) raw_armap);
+ bfd_release (abfd, raw_armap);
release_symdefs:
- bfd_release (abfd, (PTR) (ardata)->symdefs);
- return false;
+ bfd_release (abfd, (ardata)->symdefs);
+ return FALSE;
}
/* This routine can handle either coff-style or bsd-style armaps.
- Returns false on error, true otherwise */
+ Returns FALSE on error, TRUE otherwise */
-boolean
-bfd_slurp_armap (abfd)
- bfd *abfd;
+bfd_boolean
+bfd_slurp_armap (bfd *abfd)
{
char nextname[17];
- int i = bfd_bread ((PTR) nextname, (bfd_size_type) 16, abfd);
+ int i = bfd_bread (nextname, 16, abfd);
if (i == 0)
- return true;
+ return TRUE;
if (i != 16)
- return false;
+ return FALSE;
if (bfd_seek (abfd, (file_ptr) -16, SEEK_CUR) != 0)
- return false;
+ return FALSE;
if (!strncmp (nextname, "__.SYMDEF ", 16)
|| !strncmp (nextname, "__.SYMDEF/ ", 16)) /* old Linux archives */
@@ -929,27 +889,27 @@ bfd_slurp_armap (abfd)
{
/* 64bit ELF (Irix 6) archive. */
#ifdef BFD64
+ extern bfd_boolean bfd_elf64_archive_slurp_armap (bfd *);
return bfd_elf64_archive_slurp_armap (abfd);
#else
bfd_set_error (bfd_error_wrong_format);
- return false;
+ return FALSE;
#endif
}
- bfd_has_map (abfd) = false;
- return true;
+ bfd_has_map (abfd) = FALSE;
+ return TRUE;
}
-/* Returns false on error, true otherwise */
+/* Returns FALSE on error, TRUE otherwise */
/* flavor 2 of a bsd armap, similar to bfd_slurp_bsd_armap except the
header is in a slightly different order and the map name is '/'.
This flavour is used by hp300hpux. */
#define HPUX_SYMDEF_COUNT_SIZE 2
-boolean
-bfd_slurp_bsd_armap_f2 (abfd)
- bfd *abfd;
+bfd_boolean
+bfd_slurp_bsd_armap_f2 (bfd *abfd)
{
struct areltdata *mapdata;
char nextname[17];
@@ -960,16 +920,16 @@ bfd_slurp_bsd_armap_f2 (abfd)
unsigned int stringsize;
bfd_size_type amt;
carsym *set;
- int i = bfd_bread ((PTR) nextname, (bfd_size_type) 16, abfd);
+ int i = bfd_bread (nextname, 16, abfd);
if (i == 0)
- return true;
+ return TRUE;
if (i != 16)
- return false;
+ return FALSE;
/* The archive has at least 16 bytes in it. */
if (bfd_seek (abfd, (file_ptr) -16, SEEK_CUR) != 0)
- return false;
+ return FALSE;
if (!strncmp (nextname, "__.SYMDEF ", 16)
|| !strncmp (nextname, "__.SYMDEF/ ", 16)) /* old Linux archives */
@@ -977,33 +937,33 @@ bfd_slurp_bsd_armap_f2 (abfd)
if (strncmp (nextname, "/ ", 16))
{
- bfd_has_map (abfd) = false;
- return true;
+ bfd_has_map (abfd) = FALSE;
+ return TRUE;
}
- mapdata = (struct areltdata *) _bfd_read_ar_hdr (abfd);
+ mapdata = _bfd_read_ar_hdr (abfd);
if (mapdata == NULL)
- return false;
+ return FALSE;
amt = mapdata->parsed_size;
- raw_armap = (bfd_byte *) bfd_zalloc (abfd, amt);
+ raw_armap = bfd_zalloc (abfd, amt);
if (raw_armap == NULL)
{
byebye:
- bfd_release (abfd, (PTR) mapdata);
- return false;
+ bfd_release (abfd, mapdata);
+ return FALSE;
}
- if (bfd_bread ((PTR) raw_armap, amt, abfd) != amt)
+ if (bfd_bread (raw_armap, amt, abfd) != amt)
{
if (bfd_get_error () != bfd_error_system_call)
bfd_set_error (bfd_error_malformed_archive);
byebyebye:
- bfd_release (abfd, (PTR) raw_armap);
+ bfd_release (abfd, raw_armap);
goto byebye;
}
- ardata->symdef_count = H_GET_16 (abfd, (PTR) raw_armap);
+ ardata->symdef_count = H_GET_16 (abfd, raw_armap);
if (ardata->symdef_count * BSD_SYMDEF_SIZE
> mapdata->parsed_size - HPUX_SYMDEF_COUNT_SIZE)
@@ -1021,10 +981,10 @@ bfd_slurp_bsd_armap_f2 (abfd)
+ HPUX_SYMDEF_COUNT_SIZE
+ BSD_STRING_COUNT_SIZE);
rbase = (bfd_byte *) stringbase + stringsize;
- amt = (bfd_size_type) ardata->symdef_count * BSD_SYMDEF_SIZE;
- ardata->symdefs = (carsym *) bfd_alloc (abfd, amt);
+ amt = ardata->symdef_count * BSD_SYMDEF_SIZE;
+ ardata->symdefs = bfd_alloc (abfd, amt);
if (!ardata->symdefs)
- return false;
+ return FALSE;
for (counter = 0, set = ardata->symdefs;
counter < ardata->symdef_count;
@@ -1040,8 +1000,8 @@ bfd_slurp_bsd_armap_f2 (abfd)
/* FIXME, we should provide some way to free raw_ardata when
we are done using the strings from it. For now, it seems
to be allocated on an objalloc anyway... */
- bfd_has_map (abfd) = true;
- return true;
+ bfd_has_map (abfd) = TRUE;
+ return TRUE;
}
/** Extended name table.
@@ -1054,49 +1014,48 @@ bfd_slurp_bsd_armap_f2 (abfd)
element>. Index is the P.R. of an int (decimal). Data General have
extended the format by using the prefix // for the special element. */
-/* Returns false on error, true otherwise. */
+/* Returns FALSE on error, TRUE otherwise. */
-boolean
-_bfd_slurp_extended_name_table (abfd)
- bfd *abfd;
+bfd_boolean
+_bfd_slurp_extended_name_table (bfd *abfd)
{
char nextname[17];
struct areltdata *namedata;
bfd_size_type amt;
/* FIXME: Formatting sucks here, and in case of failure of BFD_READ,
- we probably don't want to return true. */
+ we probably don't want to return TRUE. */
bfd_seek (abfd, bfd_ardata (abfd)->first_file_filepos, SEEK_SET);
- if (bfd_bread ((PTR) nextname, (bfd_size_type) 16, abfd) == 16)
+ if (bfd_bread (nextname, 16, abfd) == 16)
{
if (bfd_seek (abfd, (file_ptr) -16, SEEK_CUR) != 0)
- return false;
+ return FALSE;
if (strncmp (nextname, "ARFILENAMES/ ", 16) != 0 &&
strncmp (nextname, "// ", 16) != 0)
{
bfd_ardata (abfd)->extended_names = NULL;
- return true;
+ return TRUE;
}
- namedata = (struct areltdata *) _bfd_read_ar_hdr (abfd);
+ namedata = _bfd_read_ar_hdr (abfd);
if (namedata == NULL)
- return false;
+ return FALSE;
amt = namedata->parsed_size;
bfd_ardata (abfd)->extended_names = bfd_zalloc (abfd, amt);
if (bfd_ardata (abfd)->extended_names == NULL)
{
byebye:
- bfd_release (abfd, (PTR) namedata);
- return false;
+ bfd_release (abfd, namedata);
+ return FALSE;
}
- if (bfd_bread ((PTR) bfd_ardata (abfd)->extended_names, amt, abfd) != amt)
+ if (bfd_bread (bfd_ardata (abfd)->extended_names, amt, abfd) != amt)
{
if (bfd_get_error () != bfd_error_system_call)
bfd_set_error (bfd_error_malformed_archive);
- bfd_release (abfd, (PTR) (bfd_ardata (abfd)->extended_names));
+ bfd_release (abfd, (bfd_ardata (abfd)->extended_names));
bfd_ardata (abfd)->extended_names = NULL;
goto byebye;
}
@@ -1129,7 +1088,7 @@ _bfd_slurp_extended_name_table (abfd)
bfd_release (abfd, namedata);
#endif
}
- return true;
+ return TRUE;
}
#ifdef VMS
@@ -1138,9 +1097,7 @@ _bfd_slurp_extended_name_table (abfd)
semicolon. */
static const char *
-normalize (abfd, file)
- bfd *abfd;
- const char *file;
+normalize (bfd *abfd, const char *file)
{
const char *first;
const char *last;
@@ -1161,7 +1118,7 @@ normalize (abfd, file)
first--;
}
- copy = (char *) bfd_alloc (abfd, (bfd_size_type) (last - first + 1));
+ copy = bfd_alloc (abfd, last - first + 1);
if (copy == NULL)
return NULL;
@@ -1173,9 +1130,7 @@ normalize (abfd, file)
#else
static const char *
-normalize (abfd, file)
- bfd *abfd ATTRIBUTE_UNUSED;
- const char *file;
+normalize (bfd *abfd ATTRIBUTE_UNUSED, const char *file)
{
const char *filename = strrchr (file, '/');
@@ -1189,7 +1144,7 @@ normalize (abfd, file)
filename = file + 1;
}
#endif
- if (filename != (char *) NULL)
+ if (filename != NULL)
filename++;
else
filename = file;
@@ -1199,44 +1154,41 @@ normalize (abfd, file)
/* Build a BFD style extended name table. */
-boolean
-_bfd_archive_bsd_construct_extended_name_table (abfd, tabloc, tablen, name)
- bfd *abfd;
- char **tabloc;
- bfd_size_type *tablen;
- const char **name;
+bfd_boolean
+_bfd_archive_bsd_construct_extended_name_table (bfd *abfd,
+ char **tabloc,
+ bfd_size_type *tablen,
+ const char **name)
{
*name = "ARFILENAMES/";
- return _bfd_construct_extended_name_table (abfd, false, tabloc, tablen);
+ return _bfd_construct_extended_name_table (abfd, FALSE, tabloc, tablen);
}
/* Build an SVR4 style extended name table. */
-boolean
-_bfd_archive_coff_construct_extended_name_table (abfd, tabloc, tablen, name)
- bfd *abfd;
- char **tabloc;
- bfd_size_type *tablen;
- const char **name;
+bfd_boolean
+_bfd_archive_coff_construct_extended_name_table (bfd *abfd,
+ char **tabloc,
+ bfd_size_type *tablen,
+ const char **name)
{
*name = "//";
- return _bfd_construct_extended_name_table (abfd, true, tabloc, tablen);
+ return _bfd_construct_extended_name_table (abfd, TRUE, tabloc, tablen);
}
/* Follows archive_head and produces an extended name table if
necessary. Returns (in tabloc) a pointer to an extended name
table, and in tablen the length of the table. If it makes an entry
it clobbers the filename so that the element may be written without
- further massage. Returns true if it ran successfully, false if
+ further massage. Returns TRUE if it ran successfully, FALSE if
something went wrong. A successful return may still involve a
zero-length tablen! */
-boolean
-_bfd_construct_extended_name_table (abfd, trailing_slash, tabloc, tablen)
- bfd *abfd;
- boolean trailing_slash;
- char **tabloc;
- bfd_size_type *tablen;
+bfd_boolean
+_bfd_construct_extended_name_table (bfd *abfd,
+ bfd_boolean trailing_slash,
+ char **tabloc,
+ bfd_size_type *tablen)
{
unsigned int maxname = abfd->xvec->ar_max_namelen;
bfd_size_type total_namelen = 0;
@@ -1253,7 +1205,7 @@ _bfd_construct_extended_name_table (abfd, trailing_slash, tabloc, tablen)
normal = normalize (current, current->filename);
if (normal == NULL)
- return false;
+ return FALSE;
thislen = strlen (normal);
@@ -1289,11 +1241,11 @@ _bfd_construct_extended_name_table (abfd, trailing_slash, tabloc, tablen)
}
if (total_namelen == 0)
- return true;
+ return TRUE;
*tabloc = bfd_zalloc (abfd, total_namelen);
if (*tabloc == NULL)
- return false;
+ return FALSE;
*tablen = total_namelen;
strptr = *tabloc;
@@ -1306,7 +1258,7 @@ _bfd_construct_extended_name_table (abfd, trailing_slash, tabloc, tablen)
normal = normalize (current, current->filename);
if (normal == NULL)
- return false;
+ return FALSE;
thislen = strlen (normal);
if (thislen > maxname)
@@ -1341,7 +1293,7 @@ _bfd_construct_extended_name_table (abfd, trailing_slash, tabloc, tablen)
}
}
- return true;
+ return TRUE;
}
/** A couple of functions for creating ar_hdrs */
@@ -1350,9 +1302,7 @@ _bfd_construct_extended_name_table (abfd, trailing_slash, tabloc, tablen)
/* Function to encode large UID/GID values according to HP. */
static void
-hpux_uid_gid_encode (str, id)
- char str[6];
- long int id;
+hpux_uid_gid_encode (char str[6], long int id)
{
int cnt;
@@ -1378,10 +1328,7 @@ hpux_uid_gid_encode (str, id)
is set, and it's an in-memory bfd, we fake it. */
static struct areltdata *
-bfd_ar_hdr_from_filesystem (abfd, filename, member)
- bfd *abfd;
- const char *filename;
- bfd *member;
+bfd_ar_hdr_from_filesystem (bfd *abfd, const char *filename, bfd *member)
{
struct stat status;
struct areltdata *ared;
@@ -1392,7 +1339,7 @@ bfd_ar_hdr_from_filesystem (abfd, filename, member)
if (member && (member->flags & BFD_IN_MEMORY) != 0)
{
/* Assume we just "made" the member, and fake it. */
- struct bfd_in_memory *bim = (struct bfd_in_memory *) member->iostream;
+ struct bfd_in_memory *bim = member->iostream;
time (&status.st_mtime);
status.st_uid = getuid ();
status.st_gid = getgid ();
@@ -1406,13 +1353,13 @@ bfd_ar_hdr_from_filesystem (abfd, filename, member)
}
amt = sizeof (struct ar_hdr) + sizeof (struct areltdata);
- ared = (struct areltdata *) bfd_zalloc (abfd, amt);
+ ared = bfd_zalloc (abfd, amt);
if (ared == NULL)
return NULL;
hdr = (struct ar_hdr *) (((char *) ared) + sizeof (struct areltdata));
/* ar headers are space padded, not null padded! */
- memset ((PTR) hdr, ' ', sizeof (struct ar_hdr));
+ memset (hdr, ' ', sizeof (struct ar_hdr));
strncpy (hdr->ar_fmag, ARFMAG, 2);
@@ -1458,12 +1405,10 @@ bfd_ar_hdr_from_filesystem (abfd, filename, member)
a strong stomach to write this, and it does, but it takes even a
stronger stomach to try to code around such a thing! */
-struct ar_hdr *bfd_special_undocumented_glue PARAMS ((bfd *, const char *));
+struct ar_hdr *bfd_special_undocumented_glue (bfd *, const char *);
struct ar_hdr *
-bfd_special_undocumented_glue (abfd, filename)
- bfd *abfd;
- const char *filename;
+bfd_special_undocumented_glue (bfd *abfd, const char *filename)
{
struct areltdata *ar_elt = bfd_ar_hdr_from_filesystem (abfd, filename, 0);
if (ar_elt == NULL)
@@ -1474,9 +1419,7 @@ bfd_special_undocumented_glue (abfd, filename)
/* Analogous to stat call. */
int
-bfd_generic_stat_arch_elt (abfd, buf)
- bfd *abfd;
- struct stat *buf;
+bfd_generic_stat_arch_elt (bfd *abfd, struct stat *buf)
{
struct ar_hdr *hdr;
char *aloser;
@@ -1531,10 +1474,7 @@ bfd_generic_stat_arch_elt (abfd, buf)
}
void
-bfd_dont_truncate_arname (abfd, pathname, arhdr)
- bfd *abfd;
- const char *pathname;
- char *arhdr;
+bfd_dont_truncate_arname (bfd *abfd, const char *pathname, char *arhdr)
{
/* FIXME: This interacts unpleasantly with ar's quick-append option.
Fortunately ic960 users will never use that option. Fixing this
@@ -1571,10 +1511,7 @@ bfd_dont_truncate_arname (abfd, pathname, arhdr)
}
void
-bfd_bsd_truncate_arname (abfd, pathname, arhdr)
- bfd *abfd;
- const char *pathname;
- char *arhdr;
+bfd_bsd_truncate_arname (bfd *abfd, const char *pathname, char *arhdr)
{
struct ar_hdr *hdr = (struct ar_hdr *) arhdr;
size_t length;
@@ -1622,10 +1559,7 @@ bfd_bsd_truncate_arname (abfd, pathname, arhdr)
bsd ar. */
void
-bfd_gnu_truncate_arname (abfd, pathname, arhdr)
- bfd *abfd;
- const char *pathname;
- char *arhdr;
+bfd_gnu_truncate_arname (bfd *abfd, const char *pathname, char *arhdr)
{
struct ar_hdr *hdr = (struct ar_hdr *) arhdr;
size_t length;
@@ -1669,16 +1603,16 @@ bfd_gnu_truncate_arname (abfd, pathname, arhdr)
/* The BFD is open for write and has its format set to bfd_archive. */
-boolean
-_bfd_write_archive_contents (arch)
- bfd *arch;
+bfd_boolean
+_bfd_write_archive_contents (bfd *arch)
{
bfd *current;
char *etable = NULL;
bfd_size_type elength = 0;
const char *ename = NULL;
- boolean makemap = bfd_has_map (arch);
- boolean hasobjects = false; /* If no .o's, don't bother to make a map. */
+ bfd_boolean makemap = bfd_has_map (arch);
+ /* If no .o's, don't bother to make a map. */
+ bfd_boolean hasobjects = FALSE;
bfd_size_type wrote;
unsigned int i;
int tries;
@@ -1696,19 +1630,18 @@ _bfd_write_archive_contents (arch)
if (bfd_write_p (current))
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
if (!current->arelt_data)
{
current->arelt_data =
- (PTR) bfd_ar_hdr_from_filesystem (arch, current->filename, current);
+ bfd_ar_hdr_from_filesystem (arch, current->filename, current);
if (!current->arelt_data)
- return false;
+ return FALSE;
/* Put in the file name. */
- BFD_SEND (arch, _bfd_truncate_arname, (arch,
- current->filename,
- (char *) arch_hdr (current)));
+ BFD_SEND (arch, _bfd_truncate_arname,
+ (arch, current->filename, (char *) arch_hdr (current)));
}
if (makemap && ! hasobjects)
@@ -1718,35 +1651,35 @@ _bfd_write_archive_contents (arch)
&& ((bfd_get_file_flags (current) & HAS_SYMS))
#endif
)
- hasobjects = true;
+ hasobjects = TRUE;
}
}
if (!BFD_SEND (arch, _bfd_construct_extended_name_table,
(arch, &etable, &elength, &ename)))
- return false;
+ return FALSE;
if (bfd_seek (arch, (file_ptr) 0, SEEK_SET) != 0)
- return false;
+ return FALSE;
#ifdef GNU960
- wrote = bfd_bwrite (BFD_GNU960_ARMAG (arch), (bfd_size_type) SARMAG, arch);
+ wrote = bfd_bwrite (BFD_GNU960_ARMAG (arch), SARMAG, arch);
#else
- wrote = bfd_bwrite (ARMAG, (bfd_size_type) SARMAG, arch);
+ wrote = bfd_bwrite (ARMAG, SARMAG, arch);
#endif
if (wrote != SARMAG)
- return false;
+ return FALSE;
if (makemap && hasobjects)
{
if (! _bfd_compute_and_write_armap (arch, (unsigned int) elength))
- return false;
+ return FALSE;
}
if (elength != 0)
{
struct ar_hdr hdr;
- memset ((char *) (&hdr), 0, sizeof (struct ar_hdr));
+ memset (&hdr, 0, sizeof (struct ar_hdr));
strcpy (hdr.ar_name, ename);
/* Round size up to even number in archive header. */
sprintf (&(hdr.ar_size[0]), "%-10d",
@@ -1755,14 +1688,14 @@ _bfd_write_archive_contents (arch)
for (i = 0; i < sizeof (struct ar_hdr); i++)
if (((char *) (&hdr))[i] == '\0')
(((char *) (&hdr))[i]) = ' ';
- if ((bfd_bwrite ((PTR) &hdr, (bfd_size_type) sizeof (struct ar_hdr), arch)
+ if ((bfd_bwrite (&hdr, sizeof (struct ar_hdr), arch)
!= sizeof (struct ar_hdr))
|| bfd_bwrite (etable, elength, arch) != elength)
- return false;
+ return FALSE;
if ((elength % 2) == 1)
{
- if (bfd_bwrite ("\012", (bfd_size_type) 1, arch) != 1)
- return false;
+ if (bfd_bwrite ("\012", 1, arch) != 1)
+ return FALSE;
}
}
@@ -1773,31 +1706,31 @@ _bfd_write_archive_contents (arch)
struct ar_hdr *hdr = arch_hdr (current);
/* Write ar header. */
- if (bfd_bwrite ((PTR) hdr, (bfd_size_type) sizeof (*hdr), arch)
+ if (bfd_bwrite (hdr, sizeof (*hdr), arch)
!= sizeof (*hdr))
- return false;
+ return FALSE;
if (bfd_seek (current, (file_ptr) 0, SEEK_SET) != 0)
- return false;
+ return FALSE;
while (remaining)
{
unsigned int amt = DEFAULT_BUFFERSIZE;
if (amt > remaining)
amt = remaining;
errno = 0;
- if (bfd_bread (buffer, (bfd_size_type) amt, current) != amt)
+ if (bfd_bread (buffer, amt, current) != amt)
{
if (bfd_get_error () != bfd_error_system_call)
bfd_set_error (bfd_error_malformed_archive);
- return false;
+ return FALSE;
}
- if (bfd_bwrite (buffer, (bfd_size_type) amt, arch) != amt)
- return false;
+ if (bfd_bwrite (buffer, amt, arch) != amt)
+ return FALSE;
remaining -= amt;
}
if ((arelt_size (current) % 2) == 1)
{
- if (bfd_bwrite ("\012", (bfd_size_type) 1, arch) != 1)
- return false;
+ if (bfd_bwrite ("\012", 1, arch) != 1)
+ return FALSE;
}
}
@@ -1820,15 +1753,13 @@ _bfd_write_archive_contents (arch)
while (++tries < 6);
}
- return true;
+ return TRUE;
}
/* Note that the namidx for the first symbol is 0. */
-boolean
-_bfd_compute_and_write_armap (arch, elength)
- bfd *arch;
- unsigned int elength;
+bfd_boolean
+_bfd_compute_and_write_armap (bfd *arch, unsigned int elength)
{
char *first_name = NULL;
bfd *current;
@@ -1839,7 +1770,7 @@ _bfd_compute_and_write_armap (arch, elength)
int stridx = 0; /* string index */
asymbol **syms = NULL;
long syms_max = 0;
- boolean ret;
+ bfd_boolean ret;
bfd_size_type amt;
/* Dunno if this is the best place for this info... */
@@ -1847,14 +1778,14 @@ _bfd_compute_and_write_armap (arch, elength)
elength += sizeof (struct ar_hdr);
elength += elength % 2;
- amt = (bfd_size_type) orl_max * sizeof (struct orl);
- map = (struct orl *) bfd_malloc (amt);
+ amt = orl_max * sizeof (struct orl);
+ map = bfd_malloc (amt);
if (map == NULL)
goto error_return;
/* We put the symbol names on the arch objalloc, and then discard
them when done. */
- first_name = bfd_alloc (arch, (bfd_size_type) 1);
+ first_name = bfd_alloc (arch, 1);
if (first_name == NULL)
goto error_return;
@@ -1865,7 +1796,7 @@ _bfd_compute_and_write_armap (arch, elength)
/* Map over each element. */
for (current = arch->archive_head;
- current != (bfd *) NULL;
+ current != NULL;
current = current->next, elt_no++)
{
if (bfd_check_format (current, bfd_object)
@@ -1886,7 +1817,7 @@ _bfd_compute_and_write_armap (arch, elength)
if (syms_max > 0)
free (syms);
syms_max = storage;
- syms = (asymbol **) bfd_malloc ((bfd_size_type) syms_max);
+ syms = bfd_malloc (syms_max);
if (syms == NULL)
goto error_return;
}
@@ -1914,9 +1845,9 @@ _bfd_compute_and_write_armap (arch, elength)
if (orl_count == orl_max)
{
orl_max *= 2;
- amt = (bfd_size_type) orl_max * sizeof (struct orl);
- new_map = (struct orl *) bfd_realloc (map, amt);
- if (new_map == (struct orl *) NULL)
+ amt = orl_max * sizeof (struct orl);
+ new_map = bfd_realloc (map, amt);
+ if (new_map == NULL)
goto error_return;
map = new_map;
@@ -1924,7 +1855,7 @@ _bfd_compute_and_write_armap (arch, elength)
namelen = strlen (syms[src_count]->name);
amt = sizeof (char *);
- map[orl_count].name = (char **) bfd_alloc (arch, amt);
+ map[orl_count].name = bfd_alloc (arch, amt);
if (map[orl_count].name == NULL)
goto error_return;
*(map[orl_count].name) = bfd_alloc (arch, namelen + 1);
@@ -1968,16 +1899,15 @@ _bfd_compute_and_write_armap (arch, elength)
if (first_name != NULL)
bfd_release (arch, first_name);
- return false;
+ return FALSE;
}
-boolean
-bsd_write_armap (arch, elength, map, orl_count, stridx)
- bfd *arch;
- unsigned int elength;
- struct orl *map;
- unsigned int orl_count;
- int stridx;
+bfd_boolean
+bsd_write_armap (bfd *arch,
+ unsigned int elength,
+ struct orl *map,
+ unsigned int orl_count,
+ int stridx)
{
int padit = stridx & 1;
unsigned int ranlibsize = orl_count * BSD_SYMDEF_SIZE;
@@ -1996,7 +1926,7 @@ bsd_write_armap (arch, elength, map, orl_count, stridx)
firstreal = mapsize + elength + sizeof (struct ar_hdr) + SARMAG;
stat (arch->filename, &statbuf);
- memset ((char *) (&hdr), 0, sizeof (struct ar_hdr));
+ memset (&hdr, 0, sizeof (struct ar_hdr));
sprintf (hdr.ar_name, RANLIBMAG);
/* Remember the timestamp, to keep it holy. But fudge it a little. */
bfd_ardata (arch)->armap_timestamp = statbuf.st_mtime + ARMAP_TIME_OFFSET;
@@ -2010,12 +1940,12 @@ bsd_write_armap (arch, elength, map, orl_count, stridx)
for (i = 0; i < sizeof (struct ar_hdr); i++)
if (((char *) (&hdr))[i] == '\0')
(((char *) (&hdr))[i]) = ' ';
- if (bfd_bwrite ((PTR) &hdr, (bfd_size_type) sizeof (struct ar_hdr), arch)
+ if (bfd_bwrite (&hdr, sizeof (struct ar_hdr), arch)
!= sizeof (struct ar_hdr))
- return false;
+ return FALSE;
H_PUT_32 (arch, ranlibsize, temp);
- if (bfd_bwrite (temp, (bfd_size_type) sizeof (temp), arch) != sizeof (temp))
- return false;
+ if (bfd_bwrite (temp, sizeof (temp), arch) != sizeof (temp))
+ return FALSE;
for (count = 0; count < orl_count; count++)
{
@@ -2035,43 +1965,42 @@ bsd_write_armap (arch, elength, map, orl_count, stridx)
last_elt = current;
H_PUT_32 (arch, map[count].namidx, buf);
H_PUT_32 (arch, firstreal, buf + BSD_SYMDEF_OFFSET_SIZE);
- if (bfd_bwrite (buf, (bfd_size_type) BSD_SYMDEF_SIZE, arch)
+ if (bfd_bwrite (buf, BSD_SYMDEF_SIZE, arch)
!= BSD_SYMDEF_SIZE)
- return false;
+ return FALSE;
}
/* Now write the strings themselves. */
H_PUT_32 (arch, stringsize, temp);
- if (bfd_bwrite (temp, (bfd_size_type) sizeof (temp), arch) != sizeof (temp))
- return false;
+ if (bfd_bwrite (temp, sizeof (temp), arch) != sizeof (temp))
+ return FALSE;
for (count = 0; count < orl_count; count++)
{
size_t len = strlen (*map[count].name) + 1;
- if (bfd_bwrite (*map[count].name, (bfd_size_type) len, arch) != len)
- return false;
+ if (bfd_bwrite (*map[count].name, len, arch) != len)
+ return FALSE;
}
/* The spec sez this should be a newline. But in order to be
bug-compatible for sun's ar we use a null. */
if (padit)
{
- if (bfd_bwrite ("", (bfd_size_type) 1, arch) != 1)
- return false;
+ if (bfd_bwrite ("", 1, arch) != 1)
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* At the end of archive file handling, update the timestamp in the
file, so the linker will accept it.
- Return true if the timestamp was OK, or an unusual problem happened.
- Return false if we updated the timestamp. */
+ Return TRUE if the timestamp was OK, or an unusual problem happened.
+ Return FALSE if we updated the timestamp. */
-boolean
-_bfd_archive_bsd_update_armap_timestamp (arch)
- bfd *arch;
+bfd_boolean
+_bfd_archive_bsd_update_armap_timestamp (bfd *arch)
{
struct stat archstat;
struct ar_hdr hdr;
@@ -2082,14 +2011,14 @@ _bfd_archive_bsd_update_armap_timestamp (arch)
bfd_flush (arch);
if (bfd_stat (arch, &archstat) == -1)
{
- perror (_("Reading archive file mod timestamp"));
+ bfd_perror (_("Reading archive file mod timestamp"));
/* Can't read mod time for some reason. */
- return true;
+ return TRUE;
}
if (archstat.st_mtime <= bfd_ardata (arch)->armap_timestamp)
/* OK by the linker's rules. */
- return true;
+ return TRUE;
/* Update the timestamp. */
bfd_ardata (arch)->armap_timestamp = archstat.st_mtime + ARMAP_TIME_OFFSET;
@@ -2105,18 +2034,17 @@ _bfd_archive_bsd_update_armap_timestamp (arch)
bfd_ardata (arch)->armap_datepos = (SARMAG
+ offsetof (struct ar_hdr, ar_date[0]));
if (bfd_seek (arch, bfd_ardata (arch)->armap_datepos, SEEK_SET) != 0
- || (bfd_bwrite (hdr.ar_date, (bfd_size_type) sizeof (hdr.ar_date), arch)
+ || (bfd_bwrite (hdr.ar_date, sizeof (hdr.ar_date), arch)
!= sizeof (hdr.ar_date)))
{
- /* FIXME: bfd can't call perror. */
- perror (_("Writing updated armap timestamp"));
+ bfd_perror (_("Writing updated armap timestamp"));
/* Some error while writing. */
- return true;
+ return TRUE;
}
/* We updated the timestamp successfully. */
- return false;
+ return FALSE;
}
/* A coff armap looks like :
@@ -2133,13 +2061,12 @@ _bfd_archive_bsd_update_armap_timestamp (arch)
symbol name n-1
*/
-boolean
-coff_write_armap (arch, elength, map, symbol_count, stridx)
- bfd *arch;
- unsigned int elength;
- struct orl *map;
- unsigned int symbol_count;
- int stridx;
+bfd_boolean
+coff_write_armap (bfd *arch,
+ unsigned int elength,
+ struct orl *map,
+ unsigned int symbol_count,
+ int stridx)
{
/* The size of the ranlib is the number of exported symbols in the
archive * the number of bytes in an int, + an int for the count. */
@@ -2162,7 +2089,7 @@ coff_write_armap (arch, elength, map, symbol_count, stridx)
+ sizeof (struct ar_hdr)
+ SARMAG);
- memset ((char *) (&hdr), 0, sizeof (struct ar_hdr));
+ memset (&hdr, 0, sizeof (struct ar_hdr));
hdr.ar_name[0] = '/';
sprintf (hdr.ar_size, "%-10d", (int) mapsize);
sprintf (hdr.ar_date, "%ld", (long) time (NULL));
@@ -2178,12 +2105,12 @@ coff_write_armap (arch, elength, map, symbol_count, stridx)
/* Write the ar header for this item and the number of symbols. */
- if (bfd_bwrite ((PTR) &hdr, (bfd_size_type) sizeof (struct ar_hdr), arch)
+ if (bfd_bwrite (&hdr, sizeof (struct ar_hdr), arch)
!= sizeof (struct ar_hdr))
- return false;
+ return FALSE;
if (!bfd_write_bigendian_4byte_int (arch, symbol_count))
- return false;
+ return FALSE;
/* Two passes, first write the file offsets for each symbol -
remembering that each offset is on a two byte boundary. */
@@ -2193,7 +2120,7 @@ coff_write_armap (arch, elength, map, symbol_count, stridx)
current = arch->archive_head;
count = 0;
- while (current != (bfd *) NULL && count < symbol_count)
+ while (current != NULL && count < symbol_count)
{
/* For each symbol which is used defined in this object, write
out the object file's address in the archive. */
@@ -2201,12 +2128,11 @@ coff_write_armap (arch, elength, map, symbol_count, stridx)
while (count < symbol_count && map[count].u.abfd == current)
{
if (!bfd_write_bigendian_4byte_int (arch, archive_member_file_ptr))
- return false;
+ return FALSE;
count++;
}
/* Add size of this archive entry. */
- archive_member_file_ptr += (arelt_size (current)
- + sizeof (struct ar_hdr));
+ archive_member_file_ptr += arelt_size (current) + sizeof (struct ar_hdr);
/* Remember aboout the even alignment. */
archive_member_file_ptr += archive_member_file_ptr % 2;
current = current->next;
@@ -2217,17 +2143,17 @@ coff_write_armap (arch, elength, map, symbol_count, stridx)
{
size_t len = strlen (*map[count].name) + 1;
- if (bfd_bwrite (*map[count].name, (bfd_size_type) len, arch) != len)
- return false;
+ if (bfd_bwrite (*map[count].name, len, arch) != len)
+ return FALSE;
}
/* The spec sez this should be a newline. But in order to be
bug-compatible for arc960 we use a null. */
if (padit)
{
- if (bfd_bwrite ("", (bfd_size_type) 1, arch) != 1)
- return false;
+ if (bfd_bwrite ("", 1, arch) != 1)
+ return FALSE;
}
- return true;
+ return TRUE;
}
diff --git a/contrib/binutils/bfd/archive64.c b/contrib/binutils/bfd/archive64.c
index ea94c6a..1b9f5f3 100644
--- a/contrib/binutils/bfd/archive64.c
+++ b/contrib/binutils/bfd/archive64.c
@@ -1,5 +1,5 @@
/* MIPS-specific support for 64-bit ELF
- Copyright 1996, 1997, 1998, 1999, 2000, 2001
+ Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Ian Lance Taylor, Cygnus Support
Linker support added by Mark Mitchell, CodeSourcery, LLC.
@@ -31,15 +31,14 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* Irix 6 defines a 64bit archive map format, so that they can
have archives more than 4 GB in size. */
-boolean bfd_elf64_archive_slurp_armap PARAMS ((bfd *));
-boolean bfd_elf64_archive_write_armap
- PARAMS ((bfd *, unsigned int, struct orl *, unsigned int, int));
+bfd_boolean bfd_elf64_archive_slurp_armap (bfd *);
+bfd_boolean bfd_elf64_archive_write_armap
+ (bfd *, unsigned int, struct orl *, unsigned int, int);
/* Read an Irix 6 armap. */
-boolean
-bfd_elf64_archive_slurp_armap (abfd)
- bfd *abfd;
+bfd_boolean
+bfd_elf64_archive_slurp_armap (bfd *abfd)
{
struct artdata *ardata = bfd_ardata (abfd);
char nextname[17];
@@ -56,14 +55,14 @@ bfd_elf64_archive_slurp_armap (abfd)
/* Get the name of the first element. */
arhdrpos = bfd_tell (abfd);
- i = bfd_bread ((PTR) nextname, (bfd_size_type) 16, abfd);
+ i = bfd_bread (nextname, 16, abfd);
if (i == 0)
- return true;
+ return TRUE;
if (i != 16)
- return false;
+ return FALSE;
if (bfd_seek (abfd, (file_ptr) - 16, SEEK_CUR) != 0)
- return false;
+ return FALSE;
/* Archives with traditional armaps are still permitted. */
if (strncmp (nextname, "/ ", 16) == 0)
@@ -71,21 +70,21 @@ bfd_elf64_archive_slurp_armap (abfd)
if (strncmp (nextname, "/SYM64/ ", 16) != 0)
{
- bfd_has_map (abfd) = false;
- return true;
+ bfd_has_map (abfd) = FALSE;
+ return TRUE;
}
mapdata = (struct areltdata *) _bfd_read_ar_hdr (abfd);
if (mapdata == NULL)
- return false;
+ return FALSE;
parsed_size = mapdata->parsed_size;
- bfd_release (abfd, (PTR) mapdata);
+ bfd_release (abfd, mapdata);
- if (bfd_bread (int_buf, (bfd_size_type) 8, abfd) != 8)
+ if (bfd_bread (int_buf, 8, abfd) != 8)
{
if (bfd_get_error () != bfd_error_system_call)
bfd_set_error (bfd_error_malformed_archive);
- return false;
+ return FALSE;
}
nsymz = bfd_getb64 (int_buf);
@@ -95,13 +94,13 @@ bfd_elf64_archive_slurp_armap (abfd)
ptrsize = 8 * nsymz;
amt = carsym_size + stringsize + 1;
- ardata->symdefs = (carsym *) bfd_zalloc (abfd, amt);
+ ardata->symdefs = bfd_zalloc (abfd, amt);
if (ardata->symdefs == NULL)
- return false;
+ return FALSE;
carsyms = ardata->symdefs;
stringbase = ((char *) ardata->symdefs) + carsym_size;
- raw_armap = (bfd_byte *) bfd_alloc (abfd, ptrsize);
+ raw_armap = bfd_alloc (abfd, ptrsize);
if (raw_armap == NULL)
goto release_symdefs;
@@ -127,29 +126,28 @@ bfd_elf64_archive_slurp_armap (abfd)
/* Pad to an even boundary if you have to. */
ardata->first_file_filepos += (ardata->first_file_filepos) % 2;
- bfd_has_map (abfd) = true;
+ bfd_has_map (abfd) = TRUE;
bfd_release (abfd, raw_armap);
- return true;
+ return TRUE;
release_raw_armap:
bfd_release (abfd, raw_armap);
release_symdefs:
bfd_release (abfd, ardata->symdefs);
- return false;
+ return FALSE;
}
/* Write out an Irix 6 armap. The Irix 6 tools are supposed to be
able to handle ordinary ELF armaps, but at least on Irix 6.2 the
linker crashes. */
-boolean
-bfd_elf64_archive_write_armap (arch, elength, map, symbol_count, stridx)
- bfd *arch;
- unsigned int elength;
- struct orl *map;
- unsigned int symbol_count;
- int stridx;
+bfd_boolean
+bfd_elf64_archive_write_armap (bfd *arch,
+ unsigned int elength,
+ struct orl *map,
+ unsigned int symbol_count,
+ int stridx)
{
unsigned int ranlibsize = (symbol_count * 8) + 8;
unsigned int stringsize = stridx;
@@ -171,7 +169,7 @@ bfd_elf64_archive_write_armap (arch, elength, map, symbol_count, stridx)
+ sizeof (struct ar_hdr)
+ SARMAG);
- memset ((char *) (&hdr), 0, sizeof (struct ar_hdr));
+ memset (&hdr, 0, sizeof (struct ar_hdr));
strcpy (hdr.ar_name, "/SYM64/");
sprintf (hdr.ar_size, "%-10d", (int) mapsize);
sprintf (hdr.ar_date, "%ld", (long) time (NULL));
@@ -187,13 +185,13 @@ bfd_elf64_archive_write_armap (arch, elength, map, symbol_count, stridx)
/* Write the ar header for this item and the number of symbols */
- if (bfd_bwrite ((PTR) &hdr, (bfd_size_type) sizeof (struct ar_hdr), arch)
+ if (bfd_bwrite (&hdr, sizeof (struct ar_hdr), arch)
!= sizeof (struct ar_hdr))
- return false;
+ return FALSE;
bfd_putb64 ((bfd_vma) symbol_count, buf);
- if (bfd_bwrite (buf, (bfd_size_type) 8, arch) != 8)
- return false;
+ if (bfd_bwrite (buf, 8, arch) != 8)
+ return FALSE;
/* Two passes, first write the file offsets for each symbol -
remembering that each offset is on a two byte boundary. */
@@ -203,7 +201,7 @@ bfd_elf64_archive_write_armap (arch, elength, map, symbol_count, stridx)
current = arch->archive_head;
count = 0;
- while (current != (bfd *) NULL && count < symbol_count)
+ while (current != NULL && count < symbol_count)
{
/* For each symbol which is used defined in this object, write out
the object file's address in the archive */
@@ -211,8 +209,8 @@ bfd_elf64_archive_write_armap (arch, elength, map, symbol_count, stridx)
while (map[count].u.abfd == current)
{
bfd_putb64 ((bfd_vma) archive_member_file_ptr, buf);
- if (bfd_bwrite (buf, (bfd_size_type) 8, arch) != 8)
- return false;
+ if (bfd_bwrite (buf, 8, arch) != 8)
+ return FALSE;
count++;
}
/* Add size of this archive entry */
@@ -228,18 +226,18 @@ bfd_elf64_archive_write_armap (arch, elength, map, symbol_count, stridx)
{
size_t len = strlen (*map[count].name) + 1;
- if (bfd_bwrite (*map[count].name, (bfd_size_type) len, arch) != len)
- return false;
+ if (bfd_bwrite (*map[count].name, len, arch) != len)
+ return FALSE;
}
/* The spec says that this should be padded to an 8 byte boundary.
However, the Irix 6.2 tools do not appear to do this. */
while (padding != 0)
{
- if (bfd_bwrite ("", (bfd_size_type) 1, arch) != 1)
- return false;
+ if (bfd_bwrite ("", 1, arch) != 1)
+ return FALSE;
--padding;
}
- return true;
+ return TRUE;
}
diff --git a/contrib/binutils/bfd/archures.c b/contrib/binutils/bfd/archures.c
index 063e4fb..f8aeeef 100644
--- a/contrib/binutils/bfd/archures.c
+++ b/contrib/binutils/bfd/archures.c
@@ -1,24 +1,24 @@
/* BFD library support routines for architectures.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Hacked by John Gilmore and Steve Chamberlain of Cygnus Support.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "bfd.h"
#include "sysdep.h"
@@ -84,6 +84,7 @@ DESCRIPTION
.#define bfd_mach_mcf5206e 10
.#define bfd_mach_mcf5307 11
.#define bfd_mach_mcf5407 12
+.#define bfd_mach_mcf528x 13
. bfd_arch_vax, {* DEC Vax *}
. bfd_arch_i960, {* Intel 960 *}
. {* The order of the following is important.
@@ -129,12 +130,16 @@ DESCRIPTION
.#define bfd_mach_mips4010 4010
.#define bfd_mach_mips4100 4100
.#define bfd_mach_mips4111 4111
+.#define bfd_mach_mips4120 4120
.#define bfd_mach_mips4300 4300
.#define bfd_mach_mips4400 4400
.#define bfd_mach_mips4600 4600
.#define bfd_mach_mips4650 4650
.#define bfd_mach_mips5000 5000
+.#define bfd_mach_mips5400 5400
+.#define bfd_mach_mips5500 5500
.#define bfd_mach_mips6000 6000
+.#define bfd_mach_mips7000 7000
.#define bfd_mach_mips8000 8000
.#define bfd_mach_mips10000 10000
.#define bfd_mach_mips12000 12000
@@ -142,13 +147,15 @@ DESCRIPTION
.#define bfd_mach_mips5 5
.#define bfd_mach_mips_sb1 12310201 {* octal 'SB', 01 *}
.#define bfd_mach_mipsisa32 32
+.#define bfd_mach_mipsisa32r2 33
.#define bfd_mach_mipsisa64 64
+.#define bfd_mach_mipsisa64r2 65
. bfd_arch_i386, {* Intel 386 *}
-.#define bfd_mach_i386_i386 0
-.#define bfd_mach_i386_i8086 1
-.#define bfd_mach_i386_i386_intel_syntax 2
-.#define bfd_mach_x86_64 3
-.#define bfd_mach_x86_64_intel_syntax 4
+.#define bfd_mach_i386_i386 1
+.#define bfd_mach_i386_i8086 2
+.#define bfd_mach_i386_i386_intel_syntax 3
+.#define bfd_mach_x86_64 64
+.#define bfd_mach_x86_64_intel_syntax 65
. bfd_arch_we32k, {* AT&T WE32xxx *}
. bfd_arch_tahoe, {* CCI/Harris Tahoe *}
. bfd_arch_i860, {* Intel 860 *}
@@ -157,15 +164,20 @@ DESCRIPTION
. bfd_arch_alliant, {* Alliant *}
. bfd_arch_convex, {* Convex *}
. bfd_arch_m88k, {* Motorola 88xxx *}
+. bfd_arch_m98k, {* Motorola 98xxx *}
. bfd_arch_pyramid, {* Pyramid Technology *}
-. bfd_arch_h8300, {* Hitachi H8/300 *}
-.#define bfd_mach_h8300 1
-.#define bfd_mach_h8300h 2
-.#define bfd_mach_h8300s 3
+. bfd_arch_h8300, {* Renesas H8/300 (formerly Hitachi H8/300) *}
+.#define bfd_mach_h8300 1
+.#define bfd_mach_h8300h 2
+.#define bfd_mach_h8300s 3
+.#define bfd_mach_h8300hn 4
+.#define bfd_mach_h8300sn 5
+.#define bfd_mach_h8300sx 6
+.#define bfd_mach_h8300sxn 7
. bfd_arch_pdp11, {* DEC PDP-11 *}
. bfd_arch_powerpc, {* PowerPC *}
-.#define bfd_mach_ppc 0
-.#define bfd_mach_ppc64 1
+.#define bfd_mach_ppc 32
+.#define bfd_mach_ppc64 64
.#define bfd_mach_ppc_403 403
.#define bfd_mach_ppc_403gc 4030
.#define bfd_mach_ppc_505 505
@@ -182,38 +194,52 @@ DESCRIPTION
.#define bfd_mach_ppc_rs64ii 642
.#define bfd_mach_ppc_rs64iii 643
.#define bfd_mach_ppc_7400 7400
+.#define bfd_mach_ppc_e500 500
. bfd_arch_rs6000, {* IBM RS/6000 *}
-.#define bfd_mach_rs6k 0
+.#define bfd_mach_rs6k 6000
.#define bfd_mach_rs6k_rs1 6001
.#define bfd_mach_rs6k_rsc 6003
.#define bfd_mach_rs6k_rs2 6002
. bfd_arch_hppa, {* HP PA RISC *}
+.#define bfd_mach_hppa10 10
+.#define bfd_mach_hppa11 11
+.#define bfd_mach_hppa20 20
+.#define bfd_mach_hppa20w 25
. bfd_arch_d10v, {* Mitsubishi D10V *}
-.#define bfd_mach_d10v 0
+.#define bfd_mach_d10v 1
.#define bfd_mach_d10v_ts2 2
.#define bfd_mach_d10v_ts3 3
. bfd_arch_d30v, {* Mitsubishi D30V *}
. bfd_arch_dlx, {* DLX *}
. bfd_arch_m68hc11, {* Motorola 68HC11 *}
. bfd_arch_m68hc12, {* Motorola 68HC12 *}
+.#define bfd_mach_m6812_default 0
+.#define bfd_mach_m6812 1
+.#define bfd_mach_m6812s 2
. bfd_arch_z8k, {* Zilog Z8000 *}
.#define bfd_mach_z8001 1
.#define bfd_mach_z8002 2
-. bfd_arch_h8500, {* Hitachi H8/500 *}
-. bfd_arch_sh, {* Hitachi SH *}
-.#define bfd_mach_sh 0
+. bfd_arch_h8500, {* Renesas H8/500 (formerly Hitachi H8/500) *}
+. bfd_arch_sh, {* Renesas / SuperH SH (formerly Hitachi SH) *}
+.#define bfd_mach_sh 1
.#define bfd_mach_sh2 0x20
.#define bfd_mach_sh_dsp 0x2d
+.#define bfd_mach_sh2e 0x2e
.#define bfd_mach_sh3 0x30
.#define bfd_mach_sh3_dsp 0x3d
.#define bfd_mach_sh3e 0x3e
.#define bfd_mach_sh4 0x40
+.#define bfd_mach_sh4_nofpu 0x41
+.#define bfd_mach_sh4a 0x4a
+.#define bfd_mach_sh4a_nofpu 0x4b
+.#define bfd_mach_sh4al_dsp 0x4d
.#define bfd_mach_sh5 0x50
. bfd_arch_alpha, {* Dec Alpha *}
.#define bfd_mach_alpha_ev4 0x10
.#define bfd_mach_alpha_ev5 0x20
.#define bfd_mach_alpha_ev6 0x30
. bfd_arch_arm, {* Advanced Risc Machines ARM. *}
+.#define bfd_mach_arm_unknown 0
.#define bfd_mach_arm_2 1
.#define bfd_mach_arm_2a 2
.#define bfd_mach_arm_3 3
@@ -224,40 +250,54 @@ DESCRIPTION
.#define bfd_mach_arm_5T 8
.#define bfd_mach_arm_5TE 9
.#define bfd_mach_arm_XScale 10
+.#define bfd_mach_arm_ep9312 11
+.#define bfd_mach_arm_iWMMXt 12
. bfd_arch_ns32k, {* National Semiconductors ns32000 *}
. bfd_arch_w65, {* WDC 65816 *}
. bfd_arch_tic30, {* Texas Instruments TMS320C30 *}
+. bfd_arch_tic4x, {* Texas Instruments TMS320C3X/4X *}
+.#define bfd_mach_tic3x 30
+.#define bfd_mach_tic4x 40
. bfd_arch_tic54x, {* Texas Instruments TMS320C54X *}
. bfd_arch_tic80, {* TI TMS320c80 (MVP) *}
. bfd_arch_v850, {* NEC V850 *}
-.#define bfd_mach_v850 0
+.#define bfd_mach_v850 1
.#define bfd_mach_v850e 'E'
-.#define bfd_mach_v850ea 'A'
+.#define bfd_mach_v850e1 '1'
. bfd_arch_arc, {* ARC Cores *}
-.#define bfd_mach_arc_5 0
-.#define bfd_mach_arc_6 1
-.#define bfd_mach_arc_7 2
-.#define bfd_mach_arc_8 3
-. bfd_arch_m32r, {* Mitsubishi M32R/D *}
-.#define bfd_mach_m32r 0 {* For backwards compatibility. *}
+.#define bfd_mach_arc_5 5
+.#define bfd_mach_arc_6 6
+.#define bfd_mach_arc_7 7
+.#define bfd_mach_arc_8 8
+. bfd_arch_m32r, {* Renesas M32R (formerly Mitsubishi M32R/D) *}
+.#define bfd_mach_m32r 1 {* For backwards compatibility. *}
.#define bfd_mach_m32rx 'x'
+.#define bfd_mach_m32r2 '2'
. bfd_arch_mn10200, {* Matsushita MN10200 *}
. bfd_arch_mn10300, {* Matsushita MN10300 *}
.#define bfd_mach_mn10300 300
.#define bfd_mach_am33 330
+.#define bfd_mach_am33_2 332
. bfd_arch_fr30,
.#define bfd_mach_fr30 0x46523330
. bfd_arch_frv,
-.#define bfd_mach_frv 0
-.#define bfd_mach_frvsimple 1
+.#define bfd_mach_frv 1
+.#define bfd_mach_frvsimple 2
.#define bfd_mach_fr300 300
.#define bfd_mach_fr400 400
.#define bfd_mach_frvtomcat 499 {* fr500 prototype *}
.#define bfd_mach_fr500 500
+.#define bfd_mach_fr550 550
. bfd_arch_mcore,
. bfd_arch_ia64, {* HP/Intel ia64 *}
-.#define bfd_mach_ia64_elf64 0
-.#define bfd_mach_ia64_elf32 1
+.#define bfd_mach_ia64_elf64 64
+.#define bfd_mach_ia64_elf32 32
+. bfd_arch_ip2k, {* Ubicom IP2K microcontrollers. *}
+.#define bfd_mach_ip2022 1
+.#define bfd_mach_ip2022ext 2
+. bfd_arch_iq2000, {* Vitesse IQ2000. *}
+.#define bfd_mach_iq2000 1
+.#define bfd_mach_iq10 2
. bfd_arch_pj,
. bfd_arch_avr, {* Atmel AVR microcontrollers. *}
.#define bfd_mach_avr1 1
@@ -267,12 +307,29 @@ DESCRIPTION
.#define bfd_mach_avr5 5
. bfd_arch_cris, {* Axis CRIS *}
. bfd_arch_s390, {* IBM s390 *}
-.#define bfd_mach_s390_31 0
-.#define bfd_mach_s390_64 1
+.#define bfd_mach_s390_31 31
+.#define bfd_mach_s390_64 64
. bfd_arch_openrisc, {* OpenRISC *}
. bfd_arch_mmix, {* Donald Knuth's educational processor. *}
. bfd_arch_xstormy16,
-.#define bfd_mach_xstormy16 0
+.#define bfd_mach_xstormy16 1
+. bfd_arch_msp430, {* Texas Instruments MSP430 architecture. *}
+.#define bfd_mach_msp11 11
+.#define bfd_mach_msp110 110
+.#define bfd_mach_msp12 12
+.#define bfd_mach_msp13 13
+.#define bfd_mach_msp14 14
+.#define bfd_mach_msp15 15
+.#define bfd_mach_msp16 16
+.#define bfd_mach_msp31 31
+.#define bfd_mach_msp32 32
+.#define bfd_mach_msp33 33
+.#define bfd_mach_msp41 41
+.#define bfd_mach_msp42 42
+.#define bfd_mach_msp43 43
+.#define bfd_mach_msp44 44
+. bfd_arch_xtensa, {* Tensilica's Xtensa cores. *}
+.#define bfd_mach_xtensa 1
. bfd_arch_last
. };
*/
@@ -296,15 +353,14 @@ DESCRIPTION
. const char *arch_name;
. const char *printable_name;
. unsigned int section_align_power;
-. {* True if this is the default machine for the architecture.
+. {* TRUE if this is the default machine for the architecture.
. The default arch should be the first entry for an arch so that
. all the entries for that arch can be accessed via <<next>>. *}
-. boolean the_default;
+. bfd_boolean the_default;
. const struct bfd_arch_info * (*compatible)
-. PARAMS ((const struct bfd_arch_info *a,
-. const struct bfd_arch_info *b));
+. (const struct bfd_arch_info *a, const struct bfd_arch_info *b);
.
-. boolean (*scan) PARAMS ((const struct bfd_arch_info *, const char *));
+. bfd_boolean (*scan) (const struct bfd_arch_info *, const char *);
.
. const struct bfd_arch_info *next;
.}
@@ -331,6 +387,8 @@ extern const bfd_arch_info_type bfd_i386_arch;
extern const bfd_arch_info_type bfd_i860_arch;
extern const bfd_arch_info_type bfd_i960_arch;
extern const bfd_arch_info_type bfd_ia64_arch;
+extern const bfd_arch_info_type bfd_ip2k_arch;
+extern const bfd_arch_info_type bfd_iq2000_arch;
extern const bfd_arch_info_type bfd_m32r_arch;
extern const bfd_arch_info_type bfd_m68hc11_arch;
extern const bfd_arch_info_type bfd_m68hc12_arch;
@@ -341,6 +399,7 @@ extern const bfd_arch_info_type bfd_mips_arch;
extern const bfd_arch_info_type bfd_mmix_arch;
extern const bfd_arch_info_type bfd_mn10200_arch;
extern const bfd_arch_info_type bfd_mn10300_arch;
+extern const bfd_arch_info_type bfd_msp430_arch;
extern const bfd_arch_info_type bfd_ns32k_arch;
extern const bfd_arch_info_type bfd_openrisc_arch;
extern const bfd_arch_info_type bfd_or32_arch;
@@ -353,6 +412,7 @@ extern const bfd_arch_info_type bfd_s390_arch;
extern const bfd_arch_info_type bfd_sh_arch;
extern const bfd_arch_info_type bfd_sparc_arch;
extern const bfd_arch_info_type bfd_tic30_arch;
+extern const bfd_arch_info_type bfd_tic4x_arch;
extern const bfd_arch_info_type bfd_tic54x_arch;
extern const bfd_arch_info_type bfd_tic80_arch;
extern const bfd_arch_info_type bfd_v850_arch;
@@ -360,6 +420,7 @@ extern const bfd_arch_info_type bfd_vax_arch;
extern const bfd_arch_info_type bfd_we32k_arch;
extern const bfd_arch_info_type bfd_w65_arch;
extern const bfd_arch_info_type bfd_xstormy16_arch;
+extern const bfd_arch_info_type bfd_xtensa_arch;
extern const bfd_arch_info_type bfd_z8k_arch;
static const bfd_arch_info_type * const bfd_archures_list[] =
@@ -386,6 +447,8 @@ static const bfd_arch_info_type * const bfd_archures_list[] =
&bfd_i860_arch,
&bfd_i960_arch,
&bfd_ia64_arch,
+ &bfd_ip2k_arch,
+ &bfd_iq2000_arch,
&bfd_m32r_arch,
&bfd_m68hc11_arch,
&bfd_m68hc12_arch,
@@ -396,6 +459,7 @@ static const bfd_arch_info_type * const bfd_archures_list[] =
&bfd_mmix_arch,
&bfd_mn10200_arch,
&bfd_mn10300_arch,
+ &bfd_msp430_arch,
&bfd_ns32k_arch,
&bfd_openrisc_arch,
&bfd_or32_arch,
@@ -406,6 +470,7 @@ static const bfd_arch_info_type * const bfd_archures_list[] =
&bfd_sh_arch,
&bfd_sparc_arch,
&bfd_tic30_arch,
+ &bfd_tic4x_arch,
&bfd_tic54x_arch,
&bfd_tic80_arch,
&bfd_v850_arch,
@@ -413,6 +478,7 @@ static const bfd_arch_info_type * const bfd_archures_list[] =
&bfd_w65_arch,
&bfd_we32k_arch,
&bfd_xstormy16_arch,
+ &bfd_xtensa_arch,
&bfd_z8k_arch,
#endif
0
@@ -423,7 +489,7 @@ FUNCTION
bfd_printable_name
SYNOPSIS
- const char *bfd_printable_name(bfd *abfd);
+ const char *bfd_printable_name (bfd *abfd);
DESCRIPTION
Return a printable string representing the architecture and machine
@@ -432,8 +498,7 @@ DESCRIPTION
*/
const char *
-bfd_printable_name (abfd)
- bfd *abfd;
+bfd_printable_name (bfd *abfd)
{
return abfd->arch_info->printable_name;
}
@@ -443,7 +508,7 @@ FUNCTION
bfd_scan_arch
SYNOPSIS
- const bfd_arch_info_type *bfd_scan_arch(const char *string);
+ const bfd_arch_info_type *bfd_scan_arch (const char *string);
DESCRIPTION
Figure out if BFD supports any cpu which could be described with
@@ -452,8 +517,7 @@ DESCRIPTION
*/
const bfd_arch_info_type *
-bfd_scan_arch (string)
- const char *string;
+bfd_scan_arch (const char *string)
{
const bfd_arch_info_type * const *app, *ap;
@@ -475,7 +539,7 @@ FUNCTION
bfd_arch_list
SYNOPSIS
- const char **bfd_arch_list(void);
+ const char **bfd_arch_list (void);
DESCRIPTION
Return a freshly malloced NULL-terminated vector of the names
@@ -483,7 +547,7 @@ DESCRIPTION
*/
const char **
-bfd_arch_list ()
+bfd_arch_list (void)
{
int vec_length = 0;
const char **name_ptr;
@@ -503,7 +567,7 @@ bfd_arch_list ()
}
amt = (vec_length + 1) * sizeof (char **);
- name_list = (const char **) bfd_malloc (amt);
+ name_list = bfd_malloc (amt);
if (name_list == NULL)
return NULL;
@@ -528,29 +592,38 @@ FUNCTION
bfd_arch_get_compatible
SYNOPSIS
- const bfd_arch_info_type *bfd_arch_get_compatible(
- const bfd *abfd,
- const bfd *bbfd);
+ const bfd_arch_info_type *bfd_arch_get_compatible
+ (const bfd *abfd, const bfd *bbfd, bfd_boolean accept_unknowns);
DESCRIPTION
- Determine whether two BFDs'
- architectures and machine types are compatible. Calculates
- the lowest common denominator between the two architectures
- and machine types implied by the BFDs and returns a pointer to
- an <<arch_info>> structure describing the compatible machine.
+ Determine whether two BFDs' architectures and machine types
+ are compatible. Calculates the lowest common denominator
+ between the two architectures and machine types implied by
+ the BFDs and returns a pointer to an <<arch_info>> structure
+ describing the compatible machine.
*/
const bfd_arch_info_type *
-bfd_arch_get_compatible (abfd, bbfd)
- const bfd *abfd;
- const bfd *bbfd;
+bfd_arch_get_compatible (const bfd *abfd,
+ const bfd *bbfd,
+ bfd_boolean accept_unknowns)
{
- /* If either architecture is unknown, then all we can do is assume
- the user knows what he's doing. */
- if (abfd->arch_info->arch == bfd_arch_unknown)
- return bbfd->arch_info;
- if (bbfd->arch_info->arch == bfd_arch_unknown)
- return abfd->arch_info;
+ const bfd * ubfd = NULL;
+
+ /* Look for an unknown architecture. */
+ if (((ubfd = abfd) && ubfd->arch_info->arch == bfd_arch_unknown)
+ || ((ubfd = bbfd) && ubfd->arch_info->arch == bfd_arch_unknown))
+ {
+ /* We can allow an unknown architecture if accept_unknowns
+ is true, or if the target is the "binary" format, which
+ has an unknown architecture. Since the binary format can
+ only be set by explicit request from the user, it is safe
+ to assume that they know what they are doing. */
+ if (accept_unknowns
+ || strcmp (bfd_get_target (ubfd), "binary") == 0)
+ return ubfd->arch_info;
+ return NULL;
+ }
/* Otherwise architecture-specific code has to decide. */
return abfd->arch_info->compatible (abfd->arch_info, bbfd->arch_info);
@@ -571,7 +644,7 @@ DESCRIPTION
*/
const bfd_arch_info_type bfd_default_arch_struct = {
- 32, 32, 8, bfd_arch_unknown, 0, "unknown", "unknown", 2, true,
+ 32, 32, 8, bfd_arch_unknown, 0, "unknown", "unknown", 2, TRUE,
bfd_default_compatible,
bfd_default_scan,
0,
@@ -582,16 +655,14 @@ FUNCTION
bfd_set_arch_info
SYNOPSIS
- void bfd_set_arch_info(bfd *abfd, const bfd_arch_info_type *arg);
+ void bfd_set_arch_info (bfd *abfd, const bfd_arch_info_type *arg);
DESCRIPTION
Set the architecture info of @var{abfd} to @var{arg}.
*/
void
-bfd_set_arch_info (abfd, arg)
- bfd *abfd;
- const bfd_arch_info_type *arg;
+bfd_set_arch_info (bfd *abfd, const bfd_arch_info_type *arg)
{
abfd->arch_info = arg;
}
@@ -601,9 +672,8 @@ INTERNAL_FUNCTION
bfd_default_set_arch_mach
SYNOPSIS
- boolean bfd_default_set_arch_mach(bfd *abfd,
- enum bfd_architecture arch,
- unsigned long mach);
+ bfd_boolean bfd_default_set_arch_mach
+ (bfd *abfd, enum bfd_architecture arch, unsigned long mach);
DESCRIPTION
Set the architecture and machine type in BFD @var{abfd}
@@ -612,19 +682,18 @@ DESCRIPTION
pointer.
*/
-boolean
-bfd_default_set_arch_mach (abfd, arch, mach)
- bfd *abfd;
- enum bfd_architecture arch;
- unsigned long mach;
+bfd_boolean
+bfd_default_set_arch_mach (bfd *abfd,
+ enum bfd_architecture arch,
+ unsigned long mach)
{
abfd->arch_info = bfd_lookup_arch (arch, mach);
if (abfd->arch_info != NULL)
- return true;
+ return TRUE;
abfd->arch_info = &bfd_default_arch_struct;
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
/*
@@ -632,7 +701,7 @@ FUNCTION
bfd_get_arch
SYNOPSIS
- enum bfd_architecture bfd_get_arch(bfd *abfd);
+ enum bfd_architecture bfd_get_arch (bfd *abfd);
DESCRIPTION
Return the enumerated type which describes the BFD @var{abfd}'s
@@ -640,8 +709,7 @@ DESCRIPTION
*/
enum bfd_architecture
-bfd_get_arch (abfd)
- bfd *abfd;
+bfd_get_arch (bfd *abfd)
{
return abfd->arch_info->arch;
}
@@ -651,7 +719,7 @@ FUNCTION
bfd_get_mach
SYNOPSIS
- unsigned long bfd_get_mach(bfd *abfd);
+ unsigned long bfd_get_mach (bfd *abfd);
DESCRIPTION
Return the long type which describes the BFD @var{abfd}'s
@@ -659,8 +727,7 @@ DESCRIPTION
*/
unsigned long
-bfd_get_mach (abfd)
- bfd *abfd;
+bfd_get_mach (bfd *abfd)
{
return abfd->arch_info->mach;
}
@@ -670,7 +737,7 @@ FUNCTION
bfd_arch_bits_per_byte
SYNOPSIS
- unsigned int bfd_arch_bits_per_byte(bfd *abfd);
+ unsigned int bfd_arch_bits_per_byte (bfd *abfd);
DESCRIPTION
Return the number of bits in one of the BFD @var{abfd}'s
@@ -678,8 +745,7 @@ DESCRIPTION
*/
unsigned int
-bfd_arch_bits_per_byte (abfd)
- bfd *abfd;
+bfd_arch_bits_per_byte (bfd *abfd)
{
return abfd->arch_info->bits_per_byte;
}
@@ -689,7 +755,7 @@ FUNCTION
bfd_arch_bits_per_address
SYNOPSIS
- unsigned int bfd_arch_bits_per_address(bfd *abfd);
+ unsigned int bfd_arch_bits_per_address (bfd *abfd);
DESCRIPTION
Return the number of bits in one of the BFD @var{abfd}'s
@@ -697,8 +763,7 @@ DESCRIPTION
*/
unsigned int
-bfd_arch_bits_per_address (abfd)
- bfd *abfd;
+bfd_arch_bits_per_address (bfd *abfd)
{
return abfd->arch_info->bits_per_address;
}
@@ -709,17 +774,15 @@ INTERNAL_FUNCTION
SYNOPSIS
const bfd_arch_info_type *bfd_default_compatible
- (const bfd_arch_info_type *a,
- const bfd_arch_info_type *b);
+ (const bfd_arch_info_type *a, const bfd_arch_info_type *b);
DESCRIPTION
The default function for testing for compatibility.
*/
const bfd_arch_info_type *
-bfd_default_compatible (a, b)
- const bfd_arch_info_type *a;
- const bfd_arch_info_type *b;
+bfd_default_compatible (const bfd_arch_info_type *a,
+ const bfd_arch_info_type *b)
{
if (a->arch != b->arch)
return NULL;
@@ -741,17 +804,16 @@ INTERNAL_FUNCTION
bfd_default_scan
SYNOPSIS
- boolean bfd_default_scan(const struct bfd_arch_info *info, const char *string);
+ bfd_boolean bfd_default_scan
+ (const struct bfd_arch_info *info, const char *string);
DESCRIPTION
The default function for working out whether this is an
architecture hit and a machine hit.
*/
-boolean
-bfd_default_scan (info, string)
- const bfd_arch_info_type *info;
- const char *string;
+bfd_boolean
+bfd_default_scan (const bfd_arch_info_type *info, const char *string)
{
const char *ptr_src;
const char *ptr_tst;
@@ -763,11 +825,11 @@ bfd_default_scan (info, string)
default architecture? */
if (strcasecmp (string, info->arch_name) == 0
&& info->the_default)
- return true;
+ return TRUE;
/* Exact match of the machine name (PRINTABLE_NAME)? */
if (strcasecmp (string, info->printable_name) == 0)
- return true;
+ return TRUE;
/* Given that printable_name contains no colon, attempt to match:
ARCH_NAME [ ":" ] PRINTABLE_NAME? */
@@ -781,13 +843,13 @@ bfd_default_scan (info, string)
{
if (strcasecmp (string + strlen_arch_name + 1,
info->printable_name) == 0)
- return true;
+ return TRUE;
}
else
{
if (strcasecmp (string + strlen_arch_name,
info->printable_name) == 0)
- return true;
+ return TRUE;
}
}
}
@@ -800,11 +862,11 @@ bfd_default_scan (info, string)
if (strncasecmp (string, info->printable_name, colon_index) == 0
&& strcasecmp (string + colon_index,
info->printable_name + colon_index + 1) == 0)
- return true;
+ return TRUE;
}
/* Given that PRINTABLE_NAME has the form: <arch> ":" <mach>; Do not
- attempt to match just <mach>, it could be ambigious. This test
+ attempt to match just <mach>, it could be ambiguous. This test
is left until later. */
/* NOTE: The below is retained for compatibility only. Please do
@@ -903,6 +965,10 @@ bfd_default_scan (info, string)
arch = bfd_arch_m68k;
number = bfd_mach_mcf5407;
break;
+ case 5282:
+ arch = bfd_arch_m68k;
+ number = bfd_mach_mcf528x;
+ break;
case 32000:
arch = bfd_arch_we32k;
@@ -943,16 +1009,16 @@ bfd_default_scan (info, string)
break;
default:
- return false;
+ return FALSE;
}
if (arch != info->arch)
- return false;
+ return FALSE;
if (number != info->mach)
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
/*
@@ -960,15 +1026,14 @@ FUNCTION
bfd_get_arch_info
SYNOPSIS
- const bfd_arch_info_type * bfd_get_arch_info(bfd *abfd);
+ const bfd_arch_info_type *bfd_get_arch_info (bfd *abfd);
DESCRIPTION
Return the architecture info struct in @var{abfd}.
*/
const bfd_arch_info_type *
-bfd_get_arch_info (abfd)
- bfd *abfd;
+bfd_get_arch_info (bfd *abfd)
{
return abfd->arch_info;
}
@@ -979,21 +1044,17 @@ FUNCTION
SYNOPSIS
const bfd_arch_info_type *bfd_lookup_arch
- (enum bfd_architecture
- arch,
- unsigned long machine);
+ (enum bfd_architecture arch, unsigned long machine);
DESCRIPTION
- Look for the architecure info structure which matches the
+ Look for the architecture info structure which matches the
arguments @var{arch} and @var{machine}. A machine of 0 matches the
machine/architecture structure which marks itself as the
default.
*/
const bfd_arch_info_type *
-bfd_lookup_arch (arch, machine)
- enum bfd_architecture arch;
- unsigned long machine;
+bfd_lookup_arch (enum bfd_architecture arch, unsigned long machine)
{
const bfd_arch_info_type * const *app, *ap;
@@ -1017,7 +1078,7 @@ FUNCTION
SYNOPSIS
const char *bfd_printable_arch_mach
- (enum bfd_architecture arch, unsigned long machine);
+ (enum bfd_architecture arch, unsigned long machine);
DESCRIPTION
Return a printable string representing the architecture and
@@ -1027,9 +1088,7 @@ DESCRIPTION
*/
const char *
-bfd_printable_arch_mach (arch, machine)
- enum bfd_architecture arch;
- unsigned long machine;
+bfd_printable_arch_mach (enum bfd_architecture arch, unsigned long machine)
{
const bfd_arch_info_type *ap = bfd_lookup_arch (arch, machine);
@@ -1043,7 +1102,7 @@ FUNCTION
bfd_octets_per_byte
SYNOPSIS
- unsigned int bfd_octets_per_byte(bfd *abfd);
+ unsigned int bfd_octets_per_byte (bfd *abfd);
DESCRIPTION
Return the number of octets (8-bit quantities) per target byte
@@ -1052,8 +1111,7 @@ DESCRIPTION
*/
unsigned int
-bfd_octets_per_byte (abfd)
- bfd *abfd;
+bfd_octets_per_byte (bfd *abfd)
{
return bfd_arch_mach_octets_per_byte (bfd_get_arch (abfd),
bfd_get_mach (abfd));
@@ -1064,8 +1122,8 @@ FUNCTION
bfd_arch_mach_octets_per_byte
SYNOPSIS
- unsigned int bfd_arch_mach_octets_per_byte(enum bfd_architecture arch,
- unsigned long machine);
+ unsigned int bfd_arch_mach_octets_per_byte
+ (enum bfd_architecture arch, unsigned long machine);
DESCRIPTION
See bfd_octets_per_byte.
@@ -1075,9 +1133,8 @@ DESCRIPTION
*/
unsigned int
-bfd_arch_mach_octets_per_byte (arch, mach)
- enum bfd_architecture arch;
- unsigned long mach;
+bfd_arch_mach_octets_per_byte (enum bfd_architecture arch,
+ unsigned long mach)
{
const bfd_arch_info_type *ap = bfd_lookup_arch (arch, mach);
diff --git a/contrib/binutils/bfd/bfd-in.h b/contrib/binutils/bfd/bfd-in.h
index f0f8cfd..1a5d1ea 100644
--- a/contrib/binutils/bfd/bfd-in.h
+++ b/contrib/binutils/bfd/bfd-in.h
@@ -1,7 +1,8 @@
/* Main header file for the bfd library -- portable access to object files.
- Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
- Free Software Foundation, Inc.
+
+ Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
+ 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
+
Contributed by Cygnus Support.
This file is part of BFD, the Binary File Descriptor library.
@@ -41,10 +42,6 @@ extern "C" {
#endif
#endif
-#define BFD_VERSION @bfd_version@
-#define BFD_VERSION_DATE @bfd_version_date@
-#define BFD_VERSION_STRING @bfd_version_string@
-
/* The word size used by BFD on the host. This may be 64 with a 32
bit target if the host is 64 bit, or if other 64 bit targets have
been selected with --enable-targets, or if --enable-64-bit-bfd. */
@@ -54,9 +51,12 @@ extern "C" {
#define BFD_DEFAULT_TARGET_SIZE @bfd_default_target_size@
#define BFD_HOST_64BIT_LONG @BFD_HOST_64BIT_LONG@
+#define BFD_HOST_LONG_LONG @BFD_HOST_LONG_LONG@
#if @BFD_HOST_64_BIT_DEFINED@
#define BFD_HOST_64_BIT @BFD_HOST_64_BIT@
#define BFD_HOST_U_64_BIT @BFD_HOST_U_64_BIT@
+typedef BFD_HOST_64_BIT bfd_int64_t;
+typedef BFD_HOST_U_64_BIT bfd_uint64_t;
#endif
#if BFD_ARCH_SIZE >= 64
@@ -72,66 +72,31 @@ extern "C" {
#endif
/* Forward declaration. */
-typedef struct _bfd bfd;
-
-/* To squelch erroneous compiler warnings ("illegal pointer
- combination") from the SVR3 compiler, we would like to typedef
- boolean to int (it doesn't like functions which return boolean.
- Making sure they are never implicitly declared to return int
- doesn't seem to help). But this file is not configured based on
- the host. */
-/* General rules: functions which are boolean return true on success
- and false on failure (unless they're a predicate). -- bfd.doc */
-/* I'm sure this is going to break something and someone is going to
- force me to change it. */
-/* typedef enum boolean {false, true} boolean; */
-/* Yup, SVR4 has a "typedef enum boolean" in <sys/types.h> -fnf */
-/* It gets worse if the host also defines a true/false enum... -sts */
-/* And even worse if your compiler has built-in boolean types... -law */
-/* And even worse if your compiler provides a stdbool.h that conflicts
- with these definitions... gcc 2.95 and later do. If so, it must
- be included first. -drow */
-#if defined (__GNUG__) && (__GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 6))
-#define TRUE_FALSE_ALREADY_DEFINED
-#else
-#if defined (__bool_true_false_are_defined)
-/* We have <stdbool.h>. */
-#define TRUE_FALSE_ALREADY_DEFINED
-#endif
-#endif
-#ifdef MPW
-/* Pre-emptive strike - get the file with the enum. */
-#include <Types.h>
-#define TRUE_FALSE_ALREADY_DEFINED
-#endif /* MPW */
-#ifndef TRUE_FALSE_ALREADY_DEFINED
-typedef enum bfd_boolean {false, true} boolean;
-#define BFD_TRUE_FALSE
-#else
-/* Use enum names that will appear nowhere else. */
-typedef enum bfd_boolean {bfd_fffalse, bfd_tttrue} boolean;
+typedef struct bfd bfd;
+
+/* Boolean type used in bfd. Too many systems define their own
+ versions of "boolean" for us to safely typedef a "boolean" of
+ our own. Using an enum for "bfd_boolean" has its own set of
+ problems, with strange looking casts required to avoid warnings
+ on some older compilers. Thus we just use an int.
+
+ General rule: Functions which are bfd_boolean return TRUE on
+ success and FALSE on failure (unless they're a predicate). */
+
+typedef int bfd_boolean;
+#undef FALSE
+#undef TRUE
+#define FALSE 0
+#define TRUE 1
+
+#if 0
+/* Poison. */
+#undef false
+#undef true
+#define false dont_use_false_in_bfd
+#define true dont_use_true_in_bfd
#endif
-/* Support for different sizes of target format ints and addresses.
- If the type `long' is at least 64 bits, BFD_HOST_64BIT_LONG will be
- set to 1 above. Otherwise, if gcc is being used, this code will
- use gcc's "long long" type. Otherwise, BFD_HOST_64_BIT must be
- defined above. */
-
-#ifndef BFD_HOST_64_BIT
-# if BFD_HOST_64BIT_LONG
-# define BFD_HOST_64_BIT long
-# define BFD_HOST_U_64_BIT unsigned long
-# else
-# ifdef __GNUC__
-# if __GNUC__ >= 2
-# define BFD_HOST_64_BIT long long
-# define BFD_HOST_U_64_BIT unsigned long long
-# endif /* __GNUC__ >= 2 */
-# endif /* ! defined (__GNUC__) */
-# endif /* ! BFD_HOST_64BIT_LONG */
-#endif /* ! defined (BFD_HOST_64_BIT) */
-
#ifdef BFD64
#ifndef BFD_HOST_64_BIT
@@ -179,19 +144,22 @@ typedef unsigned long bfd_size_type;
#endif /* not BFD64 */
-/* A pointer to a position in a file. */
-/* FIXME: This should be using off_t from <sys/types.h>.
- For now, try to avoid breaking stuff by not including <sys/types.h> here.
- This will break on systems with 64-bit file offsets (e.g. 4.4BSD).
- Probably the best long-term answer is to avoid using file_ptr AND off_t
- in this header file, and to handle this in the BFD implementation
- rather than in its interface. */
-/* typedef off_t file_ptr; */
-typedef bfd_signed_vma file_ptr;
-typedef bfd_vma ufile_ptr;
+#ifndef BFD_HOST_64_BIT
+/* Fall back on a 32 bit type. The idea is to make these types always
+ available for function return types, but in the case that
+ BFD_HOST_64_BIT is undefined such a function should abort or
+ otherwise signal an error. */
+typedef bfd_signed_vma bfd_int64_t;
+typedef bfd_vma bfd_uint64_t;
+#endif
+
+/* An offset into a file. BFD always uses the largest possible offset
+ based on the build time availability of fseek, fseeko, or fseeko64. */
+typedef @bfd_file_ptr@ file_ptr;
+typedef unsigned @bfd_file_ptr@ ufile_ptr;
-extern void bfd_sprintf_vma PARAMS ((bfd *, char *, bfd_vma));
-extern void bfd_fprintf_vma PARAMS ((bfd *, PTR, bfd_vma));
+extern void bfd_sprintf_vma (bfd *, char *, bfd_vma);
+extern void bfd_fprintf_vma (bfd *, void *, bfd_vma);
#define printf_vma(x) fprintf_vma(stdout,x)
#define bfd_printf_vma(abfd,x) bfd_fprintf_vma (abfd,stdout,x)
@@ -204,7 +172,7 @@ typedef unsigned char bfd_byte;
typedef enum bfd_format
{
bfd_unknown = 0, /* File format is unknown. */
- bfd_object, /* Linker/assember/compiler output. */
+ bfd_object, /* Linker/assembler/compiler output. */
bfd_archive, /* Object archive file. */
bfd_core, /* Core dump. */
bfd_type_end /* Marks the end; don't use it! */
@@ -267,6 +235,9 @@ bfd_format;
/* This flag indicates that the BFD contents are actually cached in
memory. If this is set, iostream points to a bfd_in_memory struct. */
#define BFD_IN_MEMORY 0x800
+
+/* The sections in this BFD specify a memory page. */
+#define HAS_LOAD_PAGE 0x1000
/* Symbols and relocation. */
@@ -319,7 +290,7 @@ typedef struct lineno_cache_entry
unsigned int line_number; /* Linenumber from start of function. */
union
{
- struct symbol_cache_entry *sym; /* Function name. */
+ struct bfd_symbol *sym; /* Function name. */
bfd_vma offset; /* Offset into section. */
} u;
}
@@ -330,7 +301,7 @@ alent;
#define align_power(addr, align) \
(((addr) + ((bfd_vma) 1 << (align)) - 1) & ((bfd_vma) -1 << (align)))
-typedef struct sec *sec_ptr;
+typedef struct bfd_section *sec_ptr;
#define bfd_get_section_name(bfd, ptr) ((ptr)->name + 0)
#define bfd_get_section_vma(bfd, ptr) ((ptr)->vma + 0)
@@ -346,9 +317,9 @@ typedef struct sec *sec_ptr;
#define bfd_is_com_section(ptr) (((ptr)->flags & SEC_IS_COMMON) != 0)
-#define bfd_set_section_vma(bfd, ptr, val) (((ptr)->vma = (ptr)->lma = (val)), ((ptr)->user_set_vma = (unsigned int)true), true)
-#define bfd_set_section_alignment(bfd, ptr, val) (((ptr)->alignment_power = (val)),true)
-#define bfd_set_section_userdata(bfd, ptr, val) (((ptr)->userdata = (val)),true)
+#define bfd_set_section_vma(bfd, ptr, val) (((ptr)->vma = (ptr)->lma = (val)), ((ptr)->user_set_vma = TRUE), TRUE)
+#define bfd_set_section_alignment(bfd, ptr, val) (((ptr)->alignment_power = (val)),TRUE)
+#define bfd_set_section_userdata(bfd, ptr, val) (((ptr)->userdata = (val)),TRUE)
typedef struct stat stat_type;
@@ -374,7 +345,7 @@ typedef struct _symbol_info
/* Get the name of a stabs type code. */
-extern const char *bfd_get_stab_name PARAMS ((int));
+extern const char *bfd_get_stab_name (int);
/* Hash table routines. There is no way to free up a hash table. */
@@ -407,75 +378,74 @@ struct bfd_hash_table
built each of which calls the function in the superclass. Thus
each function should be written to allocate a new block of memory
only if the argument is NULL. */
- struct bfd_hash_entry *(*newfunc) PARAMS ((struct bfd_hash_entry *,
- struct bfd_hash_table *,
- const char *));
+ struct bfd_hash_entry *(*newfunc)
+ (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
/* An objalloc for this hash table. This is a struct objalloc *,
- but we use PTR to avoid requiring the inclusion of objalloc.h. */
- PTR memory;
+ but we use void * to avoid requiring the inclusion of objalloc.h. */
+ void *memory;
};
/* Initialize a hash table. */
-extern boolean bfd_hash_table_init
- PARAMS ((struct bfd_hash_table *,
- struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
- struct bfd_hash_table *,
- const char *)));
+extern bfd_boolean bfd_hash_table_init
+ (struct bfd_hash_table *,
+ struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
+ struct bfd_hash_table *,
+ const char *));
/* Initialize a hash table specifying a size. */
-extern boolean bfd_hash_table_init_n
- PARAMS ((struct bfd_hash_table *,
- struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
- struct bfd_hash_table *,
- const char *),
- unsigned int size));
+extern bfd_boolean bfd_hash_table_init_n
+ (struct bfd_hash_table *,
+ struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
+ struct bfd_hash_table *,
+ const char *),
+ unsigned int size);
/* Free up a hash table. */
-extern void bfd_hash_table_free PARAMS ((struct bfd_hash_table *));
+extern void bfd_hash_table_free
+ (struct bfd_hash_table *);
-/* Look up a string in a hash table. If CREATE is true, a new entry
+/* Look up a string in a hash table. If CREATE is TRUE, a new entry
will be created for this string if one does not already exist. The
- COPY argument must be true if this routine should copy the string
+ COPY argument must be TRUE if this routine should copy the string
into newly allocated memory when adding an entry. */
extern struct bfd_hash_entry *bfd_hash_lookup
- PARAMS ((struct bfd_hash_table *, const char *, boolean create,
- boolean copy));
+ (struct bfd_hash_table *, const char *, bfd_boolean create,
+ bfd_boolean copy);
/* Replace an entry in a hash table. */
extern void bfd_hash_replace
- PARAMS ((struct bfd_hash_table *, struct bfd_hash_entry *old,
- struct bfd_hash_entry *nw));
+ (struct bfd_hash_table *, struct bfd_hash_entry *old,
+ struct bfd_hash_entry *nw);
/* Base method for creating a hash table entry. */
extern struct bfd_hash_entry *bfd_hash_newfunc
- PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *,
- const char *));
+ (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
/* Grab some space for a hash table entry. */
-extern PTR bfd_hash_allocate PARAMS ((struct bfd_hash_table *,
- unsigned int));
+extern void *bfd_hash_allocate
+ (struct bfd_hash_table *, unsigned int);
/* Traverse a hash table in a random order, calling a function on each
- element. If the function returns false, the traversal stops. The
+ element. If the function returns FALSE, the traversal stops. The
INFO argument is passed to the function. */
-extern void bfd_hash_traverse PARAMS ((struct bfd_hash_table *,
- boolean (*) (struct bfd_hash_entry *,
- PTR),
- PTR info));
+extern void bfd_hash_traverse
+ (struct bfd_hash_table *,
+ bfd_boolean (*) (struct bfd_hash_entry *, void *),
+ void *info);
-#define COFF_SWAP_TABLE (PTR) &bfd_coff_std_swap_table
+#define COFF_SWAP_TABLE (void *) &bfd_coff_std_swap_table
/* User program access to BFD facilities. */
/* Direct I/O routines, for programs which know more about the object
file than BFD does. Use higher level routines if possible. */
-extern bfd_size_type bfd_bread PARAMS ((PTR, bfd_size_type, bfd *));
-extern bfd_size_type bfd_bwrite PARAMS ((const PTR, bfd_size_type, bfd *));
-extern int bfd_seek PARAMS ((bfd *, file_ptr, int));
-extern ufile_ptr bfd_tell PARAMS ((bfd *));
-extern int bfd_flush PARAMS ((bfd *));
-extern int bfd_stat PARAMS ((bfd *, struct stat *));
+extern bfd_size_type bfd_bread (void *, bfd_size_type, bfd *);
+extern bfd_size_type bfd_bwrite (const void *, bfd_size_type, bfd *);
+extern int bfd_seek (bfd *, file_ptr, int);
+extern file_ptr bfd_tell (bfd *);
+extern int bfd_flush (bfd *);
+extern int bfd_stat (bfd *, struct stat *);
/* Deprecated old routines. */
#if __GNUC__
@@ -493,8 +463,7 @@ extern int bfd_stat PARAMS ((bfd *, struct stat *));
(warn_deprecated ("bfd_write", (const char *) 0, 0, (const char *) 0),\
bfd_bwrite ((BUF), (ELTSIZE) * (NITEMS), (ABFD)))
#endif
-extern void warn_deprecated
- PARAMS ((const char *, const char *, int, const char *));
+extern void warn_deprecated (const char *, const char *, int, const char *);
/* Cast from const char * to char * so that caller can assign to
a char * without a warning. */
@@ -530,40 +499,41 @@ extern void warn_deprecated
#define bfd_get_symbol_leading_char(abfd) ((abfd)->xvec->symbol_leading_char)
-#define bfd_set_cacheable(abfd,bool) (((abfd)->cacheable = (boolean) (bool)), true)
+#define bfd_set_cacheable(abfd,bool) (((abfd)->cacheable = bool), TRUE)
-extern boolean bfd_cache_close PARAMS ((bfd *abfd));
+extern bfd_boolean bfd_cache_close
+ (bfd *abfd);
/* NB: This declaration should match the autogenerated one in libbfd.h. */
-extern boolean bfd_record_phdr
- PARAMS ((bfd *, unsigned long, boolean, flagword, boolean, bfd_vma,
- boolean, boolean, unsigned int, struct sec **));
+extern bfd_boolean bfd_record_phdr
+ (bfd *, unsigned long, bfd_boolean, flagword, bfd_boolean, bfd_vma,
+ bfd_boolean, bfd_boolean, unsigned int, struct bfd_section **);
/* Byte swapping routines. */
-bfd_vma bfd_getb64 PARAMS ((const unsigned char *));
-bfd_vma bfd_getl64 PARAMS ((const unsigned char *));
-bfd_signed_vma bfd_getb_signed_64 PARAMS ((const unsigned char *));
-bfd_signed_vma bfd_getl_signed_64 PARAMS ((const unsigned char *));
-bfd_vma bfd_getb32 PARAMS ((const unsigned char *));
-bfd_vma bfd_getl32 PARAMS ((const unsigned char *));
-bfd_signed_vma bfd_getb_signed_32 PARAMS ((const unsigned char *));
-bfd_signed_vma bfd_getl_signed_32 PARAMS ((const unsigned char *));
-bfd_vma bfd_getb16 PARAMS ((const unsigned char *));
-bfd_vma bfd_getl16 PARAMS ((const unsigned char *));
-bfd_signed_vma bfd_getb_signed_16 PARAMS ((const unsigned char *));
-bfd_signed_vma bfd_getl_signed_16 PARAMS ((const unsigned char *));
-void bfd_putb64 PARAMS ((bfd_vma, unsigned char *));
-void bfd_putl64 PARAMS ((bfd_vma, unsigned char *));
-void bfd_putb32 PARAMS ((bfd_vma, unsigned char *));
-void bfd_putl32 PARAMS ((bfd_vma, unsigned char *));
-void bfd_putb16 PARAMS ((bfd_vma, unsigned char *));
-void bfd_putl16 PARAMS ((bfd_vma, unsigned char *));
+bfd_uint64_t bfd_getb64 (const void *);
+bfd_uint64_t bfd_getl64 (const void *);
+bfd_int64_t bfd_getb_signed_64 (const void *);
+bfd_int64_t bfd_getl_signed_64 (const void *);
+bfd_vma bfd_getb32 (const void *);
+bfd_vma bfd_getl32 (const void *);
+bfd_signed_vma bfd_getb_signed_32 (const void *);
+bfd_signed_vma bfd_getl_signed_32 (const void *);
+bfd_vma bfd_getb16 (const void *);
+bfd_vma bfd_getl16 (const void *);
+bfd_signed_vma bfd_getb_signed_16 (const void *);
+bfd_signed_vma bfd_getl_signed_16 (const void *);
+void bfd_putb64 (bfd_uint64_t, void *);
+void bfd_putl64 (bfd_uint64_t, void *);
+void bfd_putb32 (bfd_vma, void *);
+void bfd_putl32 (bfd_vma, void *);
+void bfd_putb16 (bfd_vma, void *);
+void bfd_putl16 (bfd_vma, void *);
/* Byte swapping routines which take size and endiannes as arguments. */
-bfd_vma bfd_get_bits PARAMS ((bfd_byte *, int, boolean));
-void bfd_put_bits PARAMS ((bfd_vma, bfd_byte *, int, boolean));
+bfd_uint64_t bfd_get_bits (const void *, int, bfd_boolean);
+void bfd_put_bits (bfd_uint64_t, void *, int, bfd_boolean);
/* Externally visible ECOFF routines. */
@@ -571,59 +541,54 @@ void bfd_put_bits PARAMS ((bfd_vma, bfd_byte *, int, boolean));
struct ecoff_debug_info;
struct ecoff_debug_swap;
struct ecoff_extr;
-struct symbol_cache_entry;
+struct bfd_symbol;
struct bfd_link_info;
struct bfd_link_hash_entry;
struct bfd_elf_version_tree;
#endif
-extern bfd_vma bfd_ecoff_get_gp_value PARAMS ((bfd * abfd));
-extern boolean bfd_ecoff_set_gp_value PARAMS ((bfd *abfd, bfd_vma gp_value));
-extern boolean bfd_ecoff_set_regmasks
- PARAMS ((bfd *abfd, unsigned long gprmask, unsigned long fprmask,
- unsigned long *cprmask));
-extern PTR bfd_ecoff_debug_init
- PARAMS ((bfd *output_bfd, struct ecoff_debug_info *output_debug,
- const struct ecoff_debug_swap *output_swap,
- struct bfd_link_info *));
+extern bfd_vma bfd_ecoff_get_gp_value
+ (bfd * abfd);
+extern bfd_boolean bfd_ecoff_set_gp_value
+ (bfd *abfd, bfd_vma gp_value);
+extern bfd_boolean bfd_ecoff_set_regmasks
+ (bfd *abfd, unsigned long gprmask, unsigned long fprmask,
+ unsigned long *cprmask);
+extern void *bfd_ecoff_debug_init
+ (bfd *output_bfd, struct ecoff_debug_info *output_debug,
+ const struct ecoff_debug_swap *output_swap, struct bfd_link_info *);
extern void bfd_ecoff_debug_free
- PARAMS ((PTR handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
- const struct ecoff_debug_swap *output_swap,
- struct bfd_link_info *));
-extern boolean bfd_ecoff_debug_accumulate
- PARAMS ((PTR handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
- const struct ecoff_debug_swap *output_swap,
- bfd *input_bfd, struct ecoff_debug_info *input_debug,
- const struct ecoff_debug_swap *input_swap,
- struct bfd_link_info *));
-extern boolean bfd_ecoff_debug_accumulate_other
- PARAMS ((PTR handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
- const struct ecoff_debug_swap *output_swap, bfd *input_bfd,
- struct bfd_link_info *));
-extern boolean bfd_ecoff_debug_externals
- PARAMS ((bfd *abfd, struct ecoff_debug_info *debug,
- const struct ecoff_debug_swap *swap,
- boolean relocateable,
- boolean (*get_extr) (struct symbol_cache_entry *,
- struct ecoff_extr *),
- void (*set_index) (struct symbol_cache_entry *,
- bfd_size_type)));
-extern boolean bfd_ecoff_debug_one_external
- PARAMS ((bfd *abfd, struct ecoff_debug_info *debug,
- const struct ecoff_debug_swap *swap,
- const char *name, struct ecoff_extr *esym));
+ (void *handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
+ const struct ecoff_debug_swap *output_swap, struct bfd_link_info *);
+extern bfd_boolean bfd_ecoff_debug_accumulate
+ (void *handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
+ const struct ecoff_debug_swap *output_swap, bfd *input_bfd,
+ struct ecoff_debug_info *input_debug,
+ const struct ecoff_debug_swap *input_swap, struct bfd_link_info *);
+extern bfd_boolean bfd_ecoff_debug_accumulate_other
+ (void *handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
+ const struct ecoff_debug_swap *output_swap, bfd *input_bfd,
+ struct bfd_link_info *);
+extern bfd_boolean bfd_ecoff_debug_externals
+ (bfd *abfd, struct ecoff_debug_info *debug,
+ const struct ecoff_debug_swap *swap, bfd_boolean relocatable,
+ bfd_boolean (*get_extr) (struct bfd_symbol *, struct ecoff_extr *),
+ void (*set_index) (struct bfd_symbol *, bfd_size_type));
+extern bfd_boolean bfd_ecoff_debug_one_external
+ (bfd *abfd, struct ecoff_debug_info *debug,
+ const struct ecoff_debug_swap *swap, const char *name,
+ struct ecoff_extr *esym);
extern bfd_size_type bfd_ecoff_debug_size
- PARAMS ((bfd *abfd, struct ecoff_debug_info *debug,
- const struct ecoff_debug_swap *swap));
-extern boolean bfd_ecoff_write_debug
- PARAMS ((bfd *abfd, struct ecoff_debug_info *debug,
- const struct ecoff_debug_swap *swap, file_ptr where));
-extern boolean bfd_ecoff_write_accumulated_debug
- PARAMS ((PTR handle, bfd *abfd, struct ecoff_debug_info *debug,
- const struct ecoff_debug_swap *swap,
- struct bfd_link_info *info, file_ptr where));
-extern boolean bfd_mips_ecoff_create_embedded_relocs
- PARAMS ((bfd *, struct bfd_link_info *, struct sec *, struct sec *,
- char **));
+ (bfd *abfd, struct ecoff_debug_info *debug,
+ const struct ecoff_debug_swap *swap);
+extern bfd_boolean bfd_ecoff_write_debug
+ (bfd *abfd, struct ecoff_debug_info *debug,
+ const struct ecoff_debug_swap *swap, file_ptr where);
+extern bfd_boolean bfd_ecoff_write_accumulated_debug
+ (void *handle, bfd *abfd, struct ecoff_debug_info *debug,
+ const struct ecoff_debug_swap *swap,
+ struct bfd_link_info *info, file_ptr where);
+extern bfd_boolean bfd_mips_ecoff_create_embedded_relocs
+ (bfd *, struct bfd_link_info *, struct bfd_section *, struct bfd_section *, char **);
/* Externally visible ELF routines. */
@@ -634,36 +599,37 @@ struct bfd_link_needed_list
const char *name;
};
-extern boolean bfd_elf32_record_link_assignment
- PARAMS ((bfd *, struct bfd_link_info *, const char *, boolean));
-extern boolean bfd_elf64_record_link_assignment
- PARAMS ((bfd *, struct bfd_link_info *, const char *, boolean));
+enum dynamic_lib_link_class {
+ DYN_NORMAL = 0,
+ DYN_AS_NEEDED = 1,
+ DYN_DT_NEEDED = 2
+};
+
+extern bfd_boolean bfd_elf_record_link_assignment
+ (bfd *, struct bfd_link_info *, const char *, bfd_boolean);
extern struct bfd_link_needed_list *bfd_elf_get_needed_list
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean bfd_elf_get_bfd_needed_list
- PARAMS ((bfd *, struct bfd_link_needed_list **));
-extern boolean bfd_elf32_size_dynamic_sections
- PARAMS ((bfd *, const char *, const char *, const char *,
- const char * const *, struct bfd_link_info *, struct sec **,
- struct bfd_elf_version_tree *));
-extern boolean bfd_elf64_size_dynamic_sections
- PARAMS ((bfd *, const char *, const char *, const char *,
- const char * const *, struct bfd_link_info *, struct sec **,
- struct bfd_elf_version_tree *));
-extern void bfd_elf_set_dt_needed_name PARAMS ((bfd *, const char *));
-extern void bfd_elf_set_dt_needed_soname PARAMS ((bfd *, const char *));
-extern const char *bfd_elf_get_dt_soname PARAMS ((bfd *));
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean bfd_elf_get_bfd_needed_list
+ (bfd *, struct bfd_link_needed_list **);
+extern bfd_boolean bfd_elf_size_dynamic_sections
+ (bfd *, const char *, const char *, const char *, const char * const *,
+ struct bfd_link_info *, struct bfd_section **, struct bfd_elf_version_tree *);
+extern void bfd_elf_set_dt_needed_name
+ (bfd *, const char *);
+extern const char *bfd_elf_get_dt_soname
+ (bfd *);
+extern void bfd_elf_set_dyn_lib_class
+ (bfd *, int);
extern struct bfd_link_needed_list *bfd_elf_get_runpath_list
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean bfd_elf32_discard_info
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean bfd_elf64_discard_info
- PARAMS ((bfd *, struct bfd_link_info *));
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean bfd_elf_discard_info
+ (bfd *, struct bfd_link_info *);
/* Return an upper bound on the number of bytes required to store a
copy of ABFD's program header table entries. Return -1 if an error
occurs; bfd_get_error will return an appropriate code. */
-extern long bfd_get_elf_phdr_upper_bound PARAMS ((bfd *abfd));
+extern long bfd_get_elf_phdr_upper_bound
+ (bfd *abfd);
/* Copy ABFD's program header table entries to *PHDRS. The entries
will be stored as an array of Elf_Internal_Phdr structures, as
@@ -672,39 +638,58 @@ extern long bfd_get_elf_phdr_upper_bound PARAMS ((bfd *abfd));
Return the number of program header table entries read, or -1 if an
error occurs; bfd_get_error will return an appropriate code. */
-extern int bfd_get_elf_phdrs PARAMS ((bfd *abfd, void *phdrs));
+extern int bfd_get_elf_phdrs
+ (bfd *abfd, void *phdrs);
+
+/* Create a new BFD as if by bfd_openr. Rather than opening a file,
+ reconstruct an ELF file by reading the segments out of remote memory
+ based on the ELF file header at EHDR_VMA and the ELF program headers it
+ points to. If not null, *LOADBASEP is filled in with the difference
+ between the VMAs from which the segments were read, and the VMAs the
+ file headers (and hence BFD's idea of each section's VMA) put them at.
+
+ The function TARGET_READ_MEMORY is called to copy LEN bytes from the
+ remote memory at target address VMA into the local buffer at MYADDR; it
+ should return zero on success or an `errno' code on failure. TEMPL must
+ be a BFD for an ELF target with the word size and byte order found in
+ the remote memory. */
+extern bfd *bfd_elf_bfd_from_remote_memory
+ (bfd *templ, bfd_vma ehdr_vma, bfd_vma *loadbasep,
+ int (*target_read_memory) (bfd_vma vma, char *myaddr, int len));
/* Return the arch_size field of an elf bfd, or -1 if not elf. */
-extern int bfd_get_arch_size PARAMS ((bfd *));
+extern int bfd_get_arch_size
+ (bfd *);
+
+/* Return TRUE if address "naturally" sign extends, or -1 if not elf. */
+extern int bfd_get_sign_extend_vma
+ (bfd *);
-/* Return true if address "naturally" sign extends, or -1 if not elf. */
-extern int bfd_get_sign_extend_vma PARAMS ((bfd *));
+extern struct bfd_section *_bfd_elf_tls_setup
+ (bfd *, struct bfd_link_info *);
-extern boolean bfd_m68k_elf32_create_embedded_relocs
- PARAMS ((bfd *, struct bfd_link_info *, struct sec *, struct sec *,
- char **));
-extern boolean bfd_mips_elf32_create_embedded_relocs
- PARAMS ((bfd *, struct bfd_link_info *, struct sec *, struct sec *,
- char **));
+extern bfd_boolean bfd_m68k_elf32_create_embedded_relocs
+ (bfd *, struct bfd_link_info *, struct bfd_section *, struct bfd_section *, char **);
+extern bfd_boolean bfd_mips_elf32_create_embedded_relocs
+ (bfd *, struct bfd_link_info *, struct bfd_section *, struct bfd_section *, char **);
/* SunOS shared library support routines for the linker. */
extern struct bfd_link_needed_list *bfd_sunos_get_needed_list
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean bfd_sunos_record_link_assignment
- PARAMS ((bfd *, struct bfd_link_info *, const char *));
-extern boolean bfd_sunos_size_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *, struct sec **, struct sec **,
- struct sec **));
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean bfd_sunos_record_link_assignment
+ (bfd *, struct bfd_link_info *, const char *);
+extern bfd_boolean bfd_sunos_size_dynamic_sections
+ (bfd *, struct bfd_link_info *, struct bfd_section **, struct bfd_section **, struct bfd_section **);
/* Linux shared library support routines for the linker. */
-extern boolean bfd_i386linux_size_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean bfd_m68klinux_size_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean bfd_sparclinux_size_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *));
+extern bfd_boolean bfd_i386linux_size_dynamic_sections
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean bfd_m68klinux_size_dynamic_sections
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean bfd_sparclinux_size_dynamic_sections
+ (bfd *, struct bfd_link_info *);
/* mmap hacks */
@@ -714,7 +699,7 @@ typedef struct _bfd_window_internal bfd_window_internal;
typedef struct _bfd_window
{
/* What the user asked for. */
- PTR data;
+ void *data;
bfd_size_type size;
/* The actual window used by BFD. Small user-requested read-only
regions sharing a page may share a single window into the object
@@ -726,34 +711,36 @@ typedef struct _bfd_window
}
bfd_window;
-extern void bfd_init_window PARAMS ((bfd_window *));
-extern void bfd_free_window PARAMS ((bfd_window *));
-extern boolean bfd_get_file_window
- PARAMS ((bfd *, file_ptr, bfd_size_type, bfd_window *, boolean));
+extern void bfd_init_window
+ (bfd_window *);
+extern void bfd_free_window
+ (bfd_window *);
+extern bfd_boolean bfd_get_file_window
+ (bfd *, file_ptr, bfd_size_type, bfd_window *, bfd_boolean);
/* XCOFF support routines for the linker. */
-extern boolean bfd_xcoff_link_record_set
- PARAMS ((bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *,
- bfd_size_type));
-extern boolean bfd_xcoff_import_symbol
- PARAMS ((bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *,
- bfd_vma, const char *, const char *, const char *, unsigned int));
-extern boolean bfd_xcoff_export_symbol
- PARAMS ((bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *));
-extern boolean bfd_xcoff_link_count_reloc
- PARAMS ((bfd *, struct bfd_link_info *, const char *));
-extern boolean bfd_xcoff_record_link_assignment
- PARAMS ((bfd *, struct bfd_link_info *, const char *));
-extern boolean bfd_xcoff_size_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *, const char *, const char *,
- unsigned long, unsigned long, unsigned long, boolean,
- int, boolean, boolean, struct sec **, boolean));
-extern boolean bfd_xcoff_link_generate_rtinit
- PARAMS ((bfd *, const char *, const char *, boolean));
+extern bfd_boolean bfd_xcoff_link_record_set
+ (bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *, bfd_size_type);
+extern bfd_boolean bfd_xcoff_import_symbol
+ (bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *, bfd_vma,
+ const char *, const char *, const char *, unsigned int);
+extern bfd_boolean bfd_xcoff_export_symbol
+ (bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *);
+extern bfd_boolean bfd_xcoff_link_count_reloc
+ (bfd *, struct bfd_link_info *, const char *);
+extern bfd_boolean bfd_xcoff_record_link_assignment
+ (bfd *, struct bfd_link_info *, const char *);
+extern bfd_boolean bfd_xcoff_size_dynamic_sections
+ (bfd *, struct bfd_link_info *, const char *, const char *,
+ unsigned long, unsigned long, unsigned long, bfd_boolean,
+ int, bfd_boolean, bfd_boolean, struct bfd_section **, bfd_boolean);
+extern bfd_boolean bfd_xcoff_link_generate_rtinit
+ (bfd *, const char *, const char *, bfd_boolean);
/* XCOFF support routines for ar. */
-extern boolean bfd_xcoff_ar_archive_set_magic PARAMS ((bfd *, char *));
+extern bfd_boolean bfd_xcoff_ar_archive_set_magic
+ (bfd *, char *);
/* Externally visible COFF routines. */
@@ -762,56 +749,76 @@ struct internal_syment;
union internal_auxent;
#endif
-extern boolean bfd_coff_get_syment
- PARAMS ((bfd *, struct symbol_cache_entry *, struct internal_syment *));
+extern bfd_boolean bfd_coff_get_syment
+ (bfd *, struct bfd_symbol *, struct internal_syment *);
-extern boolean bfd_coff_get_auxent
- PARAMS ((bfd *, struct symbol_cache_entry *, int, union internal_auxent *));
+extern bfd_boolean bfd_coff_get_auxent
+ (bfd *, struct bfd_symbol *, int, union internal_auxent *);
-extern boolean bfd_coff_set_symbol_class
- PARAMS ((bfd *, struct symbol_cache_entry *, unsigned int));
+extern bfd_boolean bfd_coff_set_symbol_class
+ (bfd *, struct bfd_symbol *, unsigned int);
-extern boolean bfd_m68k_coff_create_embedded_relocs
- PARAMS ((bfd *, struct bfd_link_info *, struct sec *, struct sec *,
- char **));
+extern bfd_boolean bfd_m68k_coff_create_embedded_relocs
+ (bfd *, struct bfd_link_info *, struct bfd_section *, struct bfd_section *, char **);
/* ARM Interworking support. Called from linker. */
-extern boolean bfd_arm_allocate_interworking_sections
- PARAMS ((struct bfd_link_info *));
+extern bfd_boolean bfd_arm_allocate_interworking_sections
+ (struct bfd_link_info *);
-extern boolean bfd_arm_process_before_allocation
- PARAMS ((bfd *, struct bfd_link_info *, int));
+extern bfd_boolean bfd_arm_process_before_allocation
+ (bfd *, struct bfd_link_info *, int);
-extern boolean bfd_arm_get_bfd_for_interworking
- PARAMS ((bfd *, struct bfd_link_info *));
+extern bfd_boolean bfd_arm_get_bfd_for_interworking
+ (bfd *, struct bfd_link_info *);
/* PE ARM Interworking support. Called from linker. */
-extern boolean bfd_arm_pe_allocate_interworking_sections
- PARAMS ((struct bfd_link_info *));
+extern bfd_boolean bfd_arm_pe_allocate_interworking_sections
+ (struct bfd_link_info *);
-extern boolean bfd_arm_pe_process_before_allocation
- PARAMS ((bfd *, struct bfd_link_info *, int));
+extern bfd_boolean bfd_arm_pe_process_before_allocation
+ (bfd *, struct bfd_link_info *, int);
-extern boolean bfd_arm_pe_get_bfd_for_interworking
- PARAMS ((bfd *, struct bfd_link_info *));
+extern bfd_boolean bfd_arm_pe_get_bfd_for_interworking
+ (bfd *, struct bfd_link_info *);
/* ELF ARM Interworking support. Called from linker. */
-extern boolean bfd_elf32_arm_allocate_interworking_sections
- PARAMS ((struct bfd_link_info *));
+extern bfd_boolean bfd_elf32_arm_allocate_interworking_sections
+ (struct bfd_link_info *);
-extern boolean bfd_elf32_arm_process_before_allocation
- PARAMS ((bfd *, struct bfd_link_info *, int));
+extern bfd_boolean bfd_elf32_arm_process_before_allocation
+ (bfd *, struct bfd_link_info *, int);
-extern boolean bfd_elf32_arm_get_bfd_for_interworking
- PARAMS ((bfd *, struct bfd_link_info *));
+extern bfd_boolean bfd_elf32_arm_get_bfd_for_interworking
+ (bfd *, struct bfd_link_info *);
-extern boolean bfd_elf32_arm_add_glue_sections_to_bfd
- PARAMS ((bfd *, struct bfd_link_info *));
+extern bfd_boolean bfd_elf32_arm_add_glue_sections_to_bfd
+ (bfd *, struct bfd_link_info *);
+
+/* ARM Note section processing. */
+extern bfd_boolean bfd_arm_merge_machines
+ (bfd *, bfd *);
+
+extern bfd_boolean bfd_arm_update_notes
+ (bfd *, const char *);
+
+extern unsigned int bfd_arm_get_mach_from_notes
+ (bfd *, const char *);
/* TI COFF load page support. */
extern void bfd_ticoff_set_section_load_page
- PARAMS ((struct sec *, int));
+ (struct bfd_section *, int);
extern int bfd_ticoff_get_section_load_page
- PARAMS ((struct sec *));
+ (struct bfd_section *);
+
+/* H8/300 functions. */
+extern bfd_vma bfd_h8300_pad_address
+ (bfd *, bfd_vma);
+
+/* IA64 Itanium code generation. Called from linker. */
+extern void bfd_elf32_ia64_after_parse
+ (int);
+
+extern void bfd_elf64_ia64_after_parse
+ (int);
diff --git a/contrib/binutils/bfd/bfd-in2.h b/contrib/binutils/bfd/bfd-in2.h
index 13aa0f9..2464d27 100644
--- a/contrib/binutils/bfd/bfd-in2.h
+++ b/contrib/binutils/bfd/bfd-in2.h
@@ -1,13 +1,15 @@
/* DO NOT EDIT! -*- buffer-read-only: t -*- This file is automatically
generated from "bfd-in.h", "init.c", "opncls.c", "libbfd.c",
- "section.c", "archures.c", "reloc.c", "syms.c", "bfd.c", "archive.c",
- "corefile.c", "targets.c" and "format.c".
+ "bfdio.c", "bfdwin.c", "section.c", "archures.c", "reloc.c",
+ "syms.c", "bfd.c", "archive.c", "corefile.c", "targets.c", "format.c",
+ "linker.c" and "simple.c".
Run "make headers" in your build bfd/ to regenerate. */
/* Main header file for the bfd library -- portable access to object files.
- Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
- Free Software Foundation, Inc.
+
+ Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
+ 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
+
Contributed by Cygnus Support.
This file is part of BFD, the Binary File Descriptor library.
@@ -47,10 +49,6 @@ extern "C" {
#endif
#endif
-#define BFD_VERSION @bfd_version@
-#define BFD_VERSION_DATE @bfd_version_date@
-#define BFD_VERSION_STRING @bfd_version_string@
-
/* The word size used by BFD on the host. This may be 64 with a 32
bit target if the host is 64 bit, or if other 64 bit targets have
been selected with --enable-targets, or if --enable-64-bit-bfd. */
@@ -60,9 +58,12 @@ extern "C" {
#define BFD_DEFAULT_TARGET_SIZE @bfd_default_target_size@
#define BFD_HOST_64BIT_LONG @BFD_HOST_64BIT_LONG@
+#define BFD_HOST_LONG_LONG @BFD_HOST_LONG_LONG@
#if @BFD_HOST_64_BIT_DEFINED@
#define BFD_HOST_64_BIT @BFD_HOST_64_BIT@
#define BFD_HOST_U_64_BIT @BFD_HOST_U_64_BIT@
+typedef BFD_HOST_64_BIT bfd_int64_t;
+typedef BFD_HOST_U_64_BIT bfd_uint64_t;
#endif
#if BFD_ARCH_SIZE >= 64
@@ -78,66 +79,31 @@ extern "C" {
#endif
/* Forward declaration. */
-typedef struct _bfd bfd;
-
-/* To squelch erroneous compiler warnings ("illegal pointer
- combination") from the SVR3 compiler, we would like to typedef
- boolean to int (it doesn't like functions which return boolean.
- Making sure they are never implicitly declared to return int
- doesn't seem to help). But this file is not configured based on
- the host. */
-/* General rules: functions which are boolean return true on success
- and false on failure (unless they're a predicate). -- bfd.doc */
-/* I'm sure this is going to break something and someone is going to
- force me to change it. */
-/* typedef enum boolean {false, true} boolean; */
-/* Yup, SVR4 has a "typedef enum boolean" in <sys/types.h> -fnf */
-/* It gets worse if the host also defines a true/false enum... -sts */
-/* And even worse if your compiler has built-in boolean types... -law */
-/* And even worse if your compiler provides a stdbool.h that conflicts
- with these definitions... gcc 2.95 and later do. If so, it must
- be included first. -drow */
-#if defined (__GNUG__) && (__GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 6))
-#define TRUE_FALSE_ALREADY_DEFINED
-#else
-#if defined (__bool_true_false_are_defined)
-/* We have <stdbool.h>. */
-#define TRUE_FALSE_ALREADY_DEFINED
-#endif
-#endif
-#ifdef MPW
-/* Pre-emptive strike - get the file with the enum. */
-#include <Types.h>
-#define TRUE_FALSE_ALREADY_DEFINED
-#endif /* MPW */
-#ifndef TRUE_FALSE_ALREADY_DEFINED
-typedef enum bfd_boolean {false, true} boolean;
-#define BFD_TRUE_FALSE
-#else
-/* Use enum names that will appear nowhere else. */
-typedef enum bfd_boolean {bfd_fffalse, bfd_tttrue} boolean;
+typedef struct bfd bfd;
+
+/* Boolean type used in bfd. Too many systems define their own
+ versions of "boolean" for us to safely typedef a "boolean" of
+ our own. Using an enum for "bfd_boolean" has its own set of
+ problems, with strange looking casts required to avoid warnings
+ on some older compilers. Thus we just use an int.
+
+ General rule: Functions which are bfd_boolean return TRUE on
+ success and FALSE on failure (unless they're a predicate). */
+
+typedef int bfd_boolean;
+#undef FALSE
+#undef TRUE
+#define FALSE 0
+#define TRUE 1
+
+#if 0
+/* Poison. */
+#undef false
+#undef true
+#define false dont_use_false_in_bfd
+#define true dont_use_true_in_bfd
#endif
-/* Support for different sizes of target format ints and addresses.
- If the type `long' is at least 64 bits, BFD_HOST_64BIT_LONG will be
- set to 1 above. Otherwise, if gcc is being used, this code will
- use gcc's "long long" type. Otherwise, BFD_HOST_64_BIT must be
- defined above. */
-
-#ifndef BFD_HOST_64_BIT
-# if BFD_HOST_64BIT_LONG
-# define BFD_HOST_64_BIT long
-# define BFD_HOST_U_64_BIT unsigned long
-# else
-# ifdef __GNUC__
-# if __GNUC__ >= 2
-# define BFD_HOST_64_BIT long long
-# define BFD_HOST_U_64_BIT unsigned long long
-# endif /* __GNUC__ >= 2 */
-# endif /* ! defined (__GNUC__) */
-# endif /* ! BFD_HOST_64BIT_LONG */
-#endif /* ! defined (BFD_HOST_64_BIT) */
-
#ifdef BFD64
#ifndef BFD_HOST_64_BIT
@@ -185,19 +151,22 @@ typedef unsigned long bfd_size_type;
#endif /* not BFD64 */
-/* A pointer to a position in a file. */
-/* FIXME: This should be using off_t from <sys/types.h>.
- For now, try to avoid breaking stuff by not including <sys/types.h> here.
- This will break on systems with 64-bit file offsets (e.g. 4.4BSD).
- Probably the best long-term answer is to avoid using file_ptr AND off_t
- in this header file, and to handle this in the BFD implementation
- rather than in its interface. */
-/* typedef off_t file_ptr; */
-typedef bfd_signed_vma file_ptr;
-typedef bfd_vma ufile_ptr;
+#ifndef BFD_HOST_64_BIT
+/* Fall back on a 32 bit type. The idea is to make these types always
+ available for function return types, but in the case that
+ BFD_HOST_64_BIT is undefined such a function should abort or
+ otherwise signal an error. */
+typedef bfd_signed_vma bfd_int64_t;
+typedef bfd_vma bfd_uint64_t;
+#endif
+
+/* An offset into a file. BFD always uses the largest possible offset
+ based on the build time availability of fseek, fseeko, or fseeko64. */
+typedef @bfd_file_ptr@ file_ptr;
+typedef unsigned @bfd_file_ptr@ ufile_ptr;
-extern void bfd_sprintf_vma PARAMS ((bfd *, char *, bfd_vma));
-extern void bfd_fprintf_vma PARAMS ((bfd *, PTR, bfd_vma));
+extern void bfd_sprintf_vma (bfd *, char *, bfd_vma);
+extern void bfd_fprintf_vma (bfd *, void *, bfd_vma);
#define printf_vma(x) fprintf_vma(stdout,x)
#define bfd_printf_vma(abfd,x) bfd_fprintf_vma (abfd,stdout,x)
@@ -210,7 +179,7 @@ typedef unsigned char bfd_byte;
typedef enum bfd_format
{
bfd_unknown = 0, /* File format is unknown. */
- bfd_object, /* Linker/assember/compiler output. */
+ bfd_object, /* Linker/assembler/compiler output. */
bfd_archive, /* Object archive file. */
bfd_core, /* Core dump. */
bfd_type_end /* Marks the end; don't use it! */
@@ -273,6 +242,9 @@ bfd_format;
/* This flag indicates that the BFD contents are actually cached in
memory. If this is set, iostream points to a bfd_in_memory struct. */
#define BFD_IN_MEMORY 0x800
+
+/* The sections in this BFD specify a memory page. */
+#define HAS_LOAD_PAGE 0x1000
/* Symbols and relocation. */
@@ -325,7 +297,7 @@ typedef struct lineno_cache_entry
unsigned int line_number; /* Linenumber from start of function. */
union
{
- struct symbol_cache_entry *sym; /* Function name. */
+ struct bfd_symbol *sym; /* Function name. */
bfd_vma offset; /* Offset into section. */
} u;
}
@@ -336,7 +308,7 @@ alent;
#define align_power(addr, align) \
(((addr) + ((bfd_vma) 1 << (align)) - 1) & ((bfd_vma) -1 << (align)))
-typedef struct sec *sec_ptr;
+typedef struct bfd_section *sec_ptr;
#define bfd_get_section_name(bfd, ptr) ((ptr)->name + 0)
#define bfd_get_section_vma(bfd, ptr) ((ptr)->vma + 0)
@@ -352,9 +324,9 @@ typedef struct sec *sec_ptr;
#define bfd_is_com_section(ptr) (((ptr)->flags & SEC_IS_COMMON) != 0)
-#define bfd_set_section_vma(bfd, ptr, val) (((ptr)->vma = (ptr)->lma = (val)), ((ptr)->user_set_vma = (unsigned int)true), true)
-#define bfd_set_section_alignment(bfd, ptr, val) (((ptr)->alignment_power = (val)),true)
-#define bfd_set_section_userdata(bfd, ptr, val) (((ptr)->userdata = (val)),true)
+#define bfd_set_section_vma(bfd, ptr, val) (((ptr)->vma = (ptr)->lma = (val)), ((ptr)->user_set_vma = TRUE), TRUE)
+#define bfd_set_section_alignment(bfd, ptr, val) (((ptr)->alignment_power = (val)),TRUE)
+#define bfd_set_section_userdata(bfd, ptr, val) (((ptr)->userdata = (val)),TRUE)
typedef struct stat stat_type;
@@ -380,7 +352,7 @@ typedef struct _symbol_info
/* Get the name of a stabs type code. */
-extern const char *bfd_get_stab_name PARAMS ((int));
+extern const char *bfd_get_stab_name (int);
/* Hash table routines. There is no way to free up a hash table. */
@@ -413,75 +385,74 @@ struct bfd_hash_table
built each of which calls the function in the superclass. Thus
each function should be written to allocate a new block of memory
only if the argument is NULL. */
- struct bfd_hash_entry *(*newfunc) PARAMS ((struct bfd_hash_entry *,
- struct bfd_hash_table *,
- const char *));
+ struct bfd_hash_entry *(*newfunc)
+ (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
/* An objalloc for this hash table. This is a struct objalloc *,
- but we use PTR to avoid requiring the inclusion of objalloc.h. */
- PTR memory;
+ but we use void * to avoid requiring the inclusion of objalloc.h. */
+ void *memory;
};
/* Initialize a hash table. */
-extern boolean bfd_hash_table_init
- PARAMS ((struct bfd_hash_table *,
- struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
- struct bfd_hash_table *,
- const char *)));
+extern bfd_boolean bfd_hash_table_init
+ (struct bfd_hash_table *,
+ struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
+ struct bfd_hash_table *,
+ const char *));
/* Initialize a hash table specifying a size. */
-extern boolean bfd_hash_table_init_n
- PARAMS ((struct bfd_hash_table *,
- struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
- struct bfd_hash_table *,
- const char *),
- unsigned int size));
+extern bfd_boolean bfd_hash_table_init_n
+ (struct bfd_hash_table *,
+ struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
+ struct bfd_hash_table *,
+ const char *),
+ unsigned int size);
/* Free up a hash table. */
-extern void bfd_hash_table_free PARAMS ((struct bfd_hash_table *));
+extern void bfd_hash_table_free
+ (struct bfd_hash_table *);
-/* Look up a string in a hash table. If CREATE is true, a new entry
+/* Look up a string in a hash table. If CREATE is TRUE, a new entry
will be created for this string if one does not already exist. The
- COPY argument must be true if this routine should copy the string
+ COPY argument must be TRUE if this routine should copy the string
into newly allocated memory when adding an entry. */
extern struct bfd_hash_entry *bfd_hash_lookup
- PARAMS ((struct bfd_hash_table *, const char *, boolean create,
- boolean copy));
+ (struct bfd_hash_table *, const char *, bfd_boolean create,
+ bfd_boolean copy);
/* Replace an entry in a hash table. */
extern void bfd_hash_replace
- PARAMS ((struct bfd_hash_table *, struct bfd_hash_entry *old,
- struct bfd_hash_entry *nw));
+ (struct bfd_hash_table *, struct bfd_hash_entry *old,
+ struct bfd_hash_entry *nw);
/* Base method for creating a hash table entry. */
extern struct bfd_hash_entry *bfd_hash_newfunc
- PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *,
- const char *));
+ (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
/* Grab some space for a hash table entry. */
-extern PTR bfd_hash_allocate PARAMS ((struct bfd_hash_table *,
- unsigned int));
+extern void *bfd_hash_allocate
+ (struct bfd_hash_table *, unsigned int);
/* Traverse a hash table in a random order, calling a function on each
- element. If the function returns false, the traversal stops. The
+ element. If the function returns FALSE, the traversal stops. The
INFO argument is passed to the function. */
-extern void bfd_hash_traverse PARAMS ((struct bfd_hash_table *,
- boolean (*) (struct bfd_hash_entry *,
- PTR),
- PTR info));
+extern void bfd_hash_traverse
+ (struct bfd_hash_table *,
+ bfd_boolean (*) (struct bfd_hash_entry *, void *),
+ void *info);
-#define COFF_SWAP_TABLE (PTR) &bfd_coff_std_swap_table
+#define COFF_SWAP_TABLE (void *) &bfd_coff_std_swap_table
/* User program access to BFD facilities. */
/* Direct I/O routines, for programs which know more about the object
file than BFD does. Use higher level routines if possible. */
-extern bfd_size_type bfd_bread PARAMS ((PTR, bfd_size_type, bfd *));
-extern bfd_size_type bfd_bwrite PARAMS ((const PTR, bfd_size_type, bfd *));
-extern int bfd_seek PARAMS ((bfd *, file_ptr, int));
-extern ufile_ptr bfd_tell PARAMS ((bfd *));
-extern int bfd_flush PARAMS ((bfd *));
-extern int bfd_stat PARAMS ((bfd *, struct stat *));
+extern bfd_size_type bfd_bread (void *, bfd_size_type, bfd *);
+extern bfd_size_type bfd_bwrite (const void *, bfd_size_type, bfd *);
+extern int bfd_seek (bfd *, file_ptr, int);
+extern file_ptr bfd_tell (bfd *);
+extern int bfd_flush (bfd *);
+extern int bfd_stat (bfd *, struct stat *);
/* Deprecated old routines. */
#if __GNUC__
@@ -499,8 +470,7 @@ extern int bfd_stat PARAMS ((bfd *, struct stat *));
(warn_deprecated ("bfd_write", (const char *) 0, 0, (const char *) 0),\
bfd_bwrite ((BUF), (ELTSIZE) * (NITEMS), (ABFD)))
#endif
-extern void warn_deprecated
- PARAMS ((const char *, const char *, int, const char *));
+extern void warn_deprecated (const char *, const char *, int, const char *);
/* Cast from const char * to char * so that caller can assign to
a char * without a warning. */
@@ -536,40 +506,41 @@ extern void warn_deprecated
#define bfd_get_symbol_leading_char(abfd) ((abfd)->xvec->symbol_leading_char)
-#define bfd_set_cacheable(abfd,bool) (((abfd)->cacheable = (boolean) (bool)), true)
+#define bfd_set_cacheable(abfd,bool) (((abfd)->cacheable = bool), TRUE)
-extern boolean bfd_cache_close PARAMS ((bfd *abfd));
+extern bfd_boolean bfd_cache_close
+ (bfd *abfd);
/* NB: This declaration should match the autogenerated one in libbfd.h. */
-extern boolean bfd_record_phdr
- PARAMS ((bfd *, unsigned long, boolean, flagword, boolean, bfd_vma,
- boolean, boolean, unsigned int, struct sec **));
+extern bfd_boolean bfd_record_phdr
+ (bfd *, unsigned long, bfd_boolean, flagword, bfd_boolean, bfd_vma,
+ bfd_boolean, bfd_boolean, unsigned int, struct bfd_section **);
/* Byte swapping routines. */
-bfd_vma bfd_getb64 PARAMS ((const unsigned char *));
-bfd_vma bfd_getl64 PARAMS ((const unsigned char *));
-bfd_signed_vma bfd_getb_signed_64 PARAMS ((const unsigned char *));
-bfd_signed_vma bfd_getl_signed_64 PARAMS ((const unsigned char *));
-bfd_vma bfd_getb32 PARAMS ((const unsigned char *));
-bfd_vma bfd_getl32 PARAMS ((const unsigned char *));
-bfd_signed_vma bfd_getb_signed_32 PARAMS ((const unsigned char *));
-bfd_signed_vma bfd_getl_signed_32 PARAMS ((const unsigned char *));
-bfd_vma bfd_getb16 PARAMS ((const unsigned char *));
-bfd_vma bfd_getl16 PARAMS ((const unsigned char *));
-bfd_signed_vma bfd_getb_signed_16 PARAMS ((const unsigned char *));
-bfd_signed_vma bfd_getl_signed_16 PARAMS ((const unsigned char *));
-void bfd_putb64 PARAMS ((bfd_vma, unsigned char *));
-void bfd_putl64 PARAMS ((bfd_vma, unsigned char *));
-void bfd_putb32 PARAMS ((bfd_vma, unsigned char *));
-void bfd_putl32 PARAMS ((bfd_vma, unsigned char *));
-void bfd_putb16 PARAMS ((bfd_vma, unsigned char *));
-void bfd_putl16 PARAMS ((bfd_vma, unsigned char *));
+bfd_uint64_t bfd_getb64 (const void *);
+bfd_uint64_t bfd_getl64 (const void *);
+bfd_int64_t bfd_getb_signed_64 (const void *);
+bfd_int64_t bfd_getl_signed_64 (const void *);
+bfd_vma bfd_getb32 (const void *);
+bfd_vma bfd_getl32 (const void *);
+bfd_signed_vma bfd_getb_signed_32 (const void *);
+bfd_signed_vma bfd_getl_signed_32 (const void *);
+bfd_vma bfd_getb16 (const void *);
+bfd_vma bfd_getl16 (const void *);
+bfd_signed_vma bfd_getb_signed_16 (const void *);
+bfd_signed_vma bfd_getl_signed_16 (const void *);
+void bfd_putb64 (bfd_uint64_t, void *);
+void bfd_putl64 (bfd_uint64_t, void *);
+void bfd_putb32 (bfd_vma, void *);
+void bfd_putl32 (bfd_vma, void *);
+void bfd_putb16 (bfd_vma, void *);
+void bfd_putl16 (bfd_vma, void *);
/* Byte swapping routines which take size and endiannes as arguments. */
-bfd_vma bfd_get_bits PARAMS ((bfd_byte *, int, boolean));
-void bfd_put_bits PARAMS ((bfd_vma, bfd_byte *, int, boolean));
+bfd_uint64_t bfd_get_bits (const void *, int, bfd_boolean);
+void bfd_put_bits (bfd_uint64_t, void *, int, bfd_boolean);
/* Externally visible ECOFF routines. */
@@ -577,59 +548,54 @@ void bfd_put_bits PARAMS ((bfd_vma, bfd_byte *, int, boolean));
struct ecoff_debug_info;
struct ecoff_debug_swap;
struct ecoff_extr;
-struct symbol_cache_entry;
+struct bfd_symbol;
struct bfd_link_info;
struct bfd_link_hash_entry;
struct bfd_elf_version_tree;
#endif
-extern bfd_vma bfd_ecoff_get_gp_value PARAMS ((bfd * abfd));
-extern boolean bfd_ecoff_set_gp_value PARAMS ((bfd *abfd, bfd_vma gp_value));
-extern boolean bfd_ecoff_set_regmasks
- PARAMS ((bfd *abfd, unsigned long gprmask, unsigned long fprmask,
- unsigned long *cprmask));
-extern PTR bfd_ecoff_debug_init
- PARAMS ((bfd *output_bfd, struct ecoff_debug_info *output_debug,
- const struct ecoff_debug_swap *output_swap,
- struct bfd_link_info *));
+extern bfd_vma bfd_ecoff_get_gp_value
+ (bfd * abfd);
+extern bfd_boolean bfd_ecoff_set_gp_value
+ (bfd *abfd, bfd_vma gp_value);
+extern bfd_boolean bfd_ecoff_set_regmasks
+ (bfd *abfd, unsigned long gprmask, unsigned long fprmask,
+ unsigned long *cprmask);
+extern void *bfd_ecoff_debug_init
+ (bfd *output_bfd, struct ecoff_debug_info *output_debug,
+ const struct ecoff_debug_swap *output_swap, struct bfd_link_info *);
extern void bfd_ecoff_debug_free
- PARAMS ((PTR handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
- const struct ecoff_debug_swap *output_swap,
- struct bfd_link_info *));
-extern boolean bfd_ecoff_debug_accumulate
- PARAMS ((PTR handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
- const struct ecoff_debug_swap *output_swap,
- bfd *input_bfd, struct ecoff_debug_info *input_debug,
- const struct ecoff_debug_swap *input_swap,
- struct bfd_link_info *));
-extern boolean bfd_ecoff_debug_accumulate_other
- PARAMS ((PTR handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
- const struct ecoff_debug_swap *output_swap, bfd *input_bfd,
- struct bfd_link_info *));
-extern boolean bfd_ecoff_debug_externals
- PARAMS ((bfd *abfd, struct ecoff_debug_info *debug,
- const struct ecoff_debug_swap *swap,
- boolean relocateable,
- boolean (*get_extr) (struct symbol_cache_entry *,
- struct ecoff_extr *),
- void (*set_index) (struct symbol_cache_entry *,
- bfd_size_type)));
-extern boolean bfd_ecoff_debug_one_external
- PARAMS ((bfd *abfd, struct ecoff_debug_info *debug,
- const struct ecoff_debug_swap *swap,
- const char *name, struct ecoff_extr *esym));
+ (void *handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
+ const struct ecoff_debug_swap *output_swap, struct bfd_link_info *);
+extern bfd_boolean bfd_ecoff_debug_accumulate
+ (void *handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
+ const struct ecoff_debug_swap *output_swap, bfd *input_bfd,
+ struct ecoff_debug_info *input_debug,
+ const struct ecoff_debug_swap *input_swap, struct bfd_link_info *);
+extern bfd_boolean bfd_ecoff_debug_accumulate_other
+ (void *handle, bfd *output_bfd, struct ecoff_debug_info *output_debug,
+ const struct ecoff_debug_swap *output_swap, bfd *input_bfd,
+ struct bfd_link_info *);
+extern bfd_boolean bfd_ecoff_debug_externals
+ (bfd *abfd, struct ecoff_debug_info *debug,
+ const struct ecoff_debug_swap *swap, bfd_boolean relocatable,
+ bfd_boolean (*get_extr) (struct bfd_symbol *, struct ecoff_extr *),
+ void (*set_index) (struct bfd_symbol *, bfd_size_type));
+extern bfd_boolean bfd_ecoff_debug_one_external
+ (bfd *abfd, struct ecoff_debug_info *debug,
+ const struct ecoff_debug_swap *swap, const char *name,
+ struct ecoff_extr *esym);
extern bfd_size_type bfd_ecoff_debug_size
- PARAMS ((bfd *abfd, struct ecoff_debug_info *debug,
- const struct ecoff_debug_swap *swap));
-extern boolean bfd_ecoff_write_debug
- PARAMS ((bfd *abfd, struct ecoff_debug_info *debug,
- const struct ecoff_debug_swap *swap, file_ptr where));
-extern boolean bfd_ecoff_write_accumulated_debug
- PARAMS ((PTR handle, bfd *abfd, struct ecoff_debug_info *debug,
- const struct ecoff_debug_swap *swap,
- struct bfd_link_info *info, file_ptr where));
-extern boolean bfd_mips_ecoff_create_embedded_relocs
- PARAMS ((bfd *, struct bfd_link_info *, struct sec *, struct sec *,
- char **));
+ (bfd *abfd, struct ecoff_debug_info *debug,
+ const struct ecoff_debug_swap *swap);
+extern bfd_boolean bfd_ecoff_write_debug
+ (bfd *abfd, struct ecoff_debug_info *debug,
+ const struct ecoff_debug_swap *swap, file_ptr where);
+extern bfd_boolean bfd_ecoff_write_accumulated_debug
+ (void *handle, bfd *abfd, struct ecoff_debug_info *debug,
+ const struct ecoff_debug_swap *swap,
+ struct bfd_link_info *info, file_ptr where);
+extern bfd_boolean bfd_mips_ecoff_create_embedded_relocs
+ (bfd *, struct bfd_link_info *, struct bfd_section *, struct bfd_section *, char **);
/* Externally visible ELF routines. */
@@ -640,36 +606,37 @@ struct bfd_link_needed_list
const char *name;
};
-extern boolean bfd_elf32_record_link_assignment
- PARAMS ((bfd *, struct bfd_link_info *, const char *, boolean));
-extern boolean bfd_elf64_record_link_assignment
- PARAMS ((bfd *, struct bfd_link_info *, const char *, boolean));
+enum dynamic_lib_link_class {
+ DYN_NORMAL = 0,
+ DYN_AS_NEEDED = 1,
+ DYN_DT_NEEDED = 2
+};
+
+extern bfd_boolean bfd_elf_record_link_assignment
+ (bfd *, struct bfd_link_info *, const char *, bfd_boolean);
extern struct bfd_link_needed_list *bfd_elf_get_needed_list
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean bfd_elf_get_bfd_needed_list
- PARAMS ((bfd *, struct bfd_link_needed_list **));
-extern boolean bfd_elf32_size_dynamic_sections
- PARAMS ((bfd *, const char *, const char *, const char *,
- const char * const *, struct bfd_link_info *, struct sec **,
- struct bfd_elf_version_tree *));
-extern boolean bfd_elf64_size_dynamic_sections
- PARAMS ((bfd *, const char *, const char *, const char *,
- const char * const *, struct bfd_link_info *, struct sec **,
- struct bfd_elf_version_tree *));
-extern void bfd_elf_set_dt_needed_name PARAMS ((bfd *, const char *));
-extern void bfd_elf_set_dt_needed_soname PARAMS ((bfd *, const char *));
-extern const char *bfd_elf_get_dt_soname PARAMS ((bfd *));
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean bfd_elf_get_bfd_needed_list
+ (bfd *, struct bfd_link_needed_list **);
+extern bfd_boolean bfd_elf_size_dynamic_sections
+ (bfd *, const char *, const char *, const char *, const char * const *,
+ struct bfd_link_info *, struct bfd_section **, struct bfd_elf_version_tree *);
+extern void bfd_elf_set_dt_needed_name
+ (bfd *, const char *);
+extern const char *bfd_elf_get_dt_soname
+ (bfd *);
+extern void bfd_elf_set_dyn_lib_class
+ (bfd *, int);
extern struct bfd_link_needed_list *bfd_elf_get_runpath_list
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean bfd_elf32_discard_info
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean bfd_elf64_discard_info
- PARAMS ((bfd *, struct bfd_link_info *));
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean bfd_elf_discard_info
+ (bfd *, struct bfd_link_info *);
/* Return an upper bound on the number of bytes required to store a
copy of ABFD's program header table entries. Return -1 if an error
occurs; bfd_get_error will return an appropriate code. */
-extern long bfd_get_elf_phdr_upper_bound PARAMS ((bfd *abfd));
+extern long bfd_get_elf_phdr_upper_bound
+ (bfd *abfd);
/* Copy ABFD's program header table entries to *PHDRS. The entries
will be stored as an array of Elf_Internal_Phdr structures, as
@@ -678,39 +645,58 @@ extern long bfd_get_elf_phdr_upper_bound PARAMS ((bfd *abfd));
Return the number of program header table entries read, or -1 if an
error occurs; bfd_get_error will return an appropriate code. */
-extern int bfd_get_elf_phdrs PARAMS ((bfd *abfd, void *phdrs));
+extern int bfd_get_elf_phdrs
+ (bfd *abfd, void *phdrs);
+
+/* Create a new BFD as if by bfd_openr. Rather than opening a file,
+ reconstruct an ELF file by reading the segments out of remote memory
+ based on the ELF file header at EHDR_VMA and the ELF program headers it
+ points to. If not null, *LOADBASEP is filled in with the difference
+ between the VMAs from which the segments were read, and the VMAs the
+ file headers (and hence BFD's idea of each section's VMA) put them at.
+
+ The function TARGET_READ_MEMORY is called to copy LEN bytes from the
+ remote memory at target address VMA into the local buffer at MYADDR; it
+ should return zero on success or an `errno' code on failure. TEMPL must
+ be a BFD for an ELF target with the word size and byte order found in
+ the remote memory. */
+extern bfd *bfd_elf_bfd_from_remote_memory
+ (bfd *templ, bfd_vma ehdr_vma, bfd_vma *loadbasep,
+ int (*target_read_memory) (bfd_vma vma, char *myaddr, int len));
/* Return the arch_size field of an elf bfd, or -1 if not elf. */
-extern int bfd_get_arch_size PARAMS ((bfd *));
+extern int bfd_get_arch_size
+ (bfd *);
-/* Return true if address "naturally" sign extends, or -1 if not elf. */
-extern int bfd_get_sign_extend_vma PARAMS ((bfd *));
+/* Return TRUE if address "naturally" sign extends, or -1 if not elf. */
+extern int bfd_get_sign_extend_vma
+ (bfd *);
-extern boolean bfd_m68k_elf32_create_embedded_relocs
- PARAMS ((bfd *, struct bfd_link_info *, struct sec *, struct sec *,
- char **));
-extern boolean bfd_mips_elf32_create_embedded_relocs
- PARAMS ((bfd *, struct bfd_link_info *, struct sec *, struct sec *,
- char **));
+extern struct bfd_section *_bfd_elf_tls_setup
+ (bfd *, struct bfd_link_info *);
+
+extern bfd_boolean bfd_m68k_elf32_create_embedded_relocs
+ (bfd *, struct bfd_link_info *, struct bfd_section *, struct bfd_section *, char **);
+extern bfd_boolean bfd_mips_elf32_create_embedded_relocs
+ (bfd *, struct bfd_link_info *, struct bfd_section *, struct bfd_section *, char **);
/* SunOS shared library support routines for the linker. */
extern struct bfd_link_needed_list *bfd_sunos_get_needed_list
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean bfd_sunos_record_link_assignment
- PARAMS ((bfd *, struct bfd_link_info *, const char *));
-extern boolean bfd_sunos_size_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *, struct sec **, struct sec **,
- struct sec **));
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean bfd_sunos_record_link_assignment
+ (bfd *, struct bfd_link_info *, const char *);
+extern bfd_boolean bfd_sunos_size_dynamic_sections
+ (bfd *, struct bfd_link_info *, struct bfd_section **, struct bfd_section **, struct bfd_section **);
/* Linux shared library support routines for the linker. */
-extern boolean bfd_i386linux_size_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean bfd_m68klinux_size_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean bfd_sparclinux_size_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *));
+extern bfd_boolean bfd_i386linux_size_dynamic_sections
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean bfd_m68klinux_size_dynamic_sections
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean bfd_sparclinux_size_dynamic_sections
+ (bfd *, struct bfd_link_info *);
/* mmap hacks */
@@ -720,7 +706,7 @@ typedef struct _bfd_window_internal bfd_window_internal;
typedef struct _bfd_window
{
/* What the user asked for. */
- PTR data;
+ void *data;
bfd_size_type size;
/* The actual window used by BFD. Small user-requested read-only
regions sharing a page may share a single window into the object
@@ -732,34 +718,36 @@ typedef struct _bfd_window
}
bfd_window;
-extern void bfd_init_window PARAMS ((bfd_window *));
-extern void bfd_free_window PARAMS ((bfd_window *));
-extern boolean bfd_get_file_window
- PARAMS ((bfd *, file_ptr, bfd_size_type, bfd_window *, boolean));
+extern void bfd_init_window
+ (bfd_window *);
+extern void bfd_free_window
+ (bfd_window *);
+extern bfd_boolean bfd_get_file_window
+ (bfd *, file_ptr, bfd_size_type, bfd_window *, bfd_boolean);
/* XCOFF support routines for the linker. */
-extern boolean bfd_xcoff_link_record_set
- PARAMS ((bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *,
- bfd_size_type));
-extern boolean bfd_xcoff_import_symbol
- PARAMS ((bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *,
- bfd_vma, const char *, const char *, const char *, unsigned int));
-extern boolean bfd_xcoff_export_symbol
- PARAMS ((bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *));
-extern boolean bfd_xcoff_link_count_reloc
- PARAMS ((bfd *, struct bfd_link_info *, const char *));
-extern boolean bfd_xcoff_record_link_assignment
- PARAMS ((bfd *, struct bfd_link_info *, const char *));
-extern boolean bfd_xcoff_size_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *, const char *, const char *,
- unsigned long, unsigned long, unsigned long, boolean,
- int, boolean, boolean, struct sec **, boolean));
-extern boolean bfd_xcoff_link_generate_rtinit
- PARAMS ((bfd *, const char *, const char *, boolean));
+extern bfd_boolean bfd_xcoff_link_record_set
+ (bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *, bfd_size_type);
+extern bfd_boolean bfd_xcoff_import_symbol
+ (bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *, bfd_vma,
+ const char *, const char *, const char *, unsigned int);
+extern bfd_boolean bfd_xcoff_export_symbol
+ (bfd *, struct bfd_link_info *, struct bfd_link_hash_entry *);
+extern bfd_boolean bfd_xcoff_link_count_reloc
+ (bfd *, struct bfd_link_info *, const char *);
+extern bfd_boolean bfd_xcoff_record_link_assignment
+ (bfd *, struct bfd_link_info *, const char *);
+extern bfd_boolean bfd_xcoff_size_dynamic_sections
+ (bfd *, struct bfd_link_info *, const char *, const char *,
+ unsigned long, unsigned long, unsigned long, bfd_boolean,
+ int, bfd_boolean, bfd_boolean, struct bfd_section **, bfd_boolean);
+extern bfd_boolean bfd_xcoff_link_generate_rtinit
+ (bfd *, const char *, const char *, bfd_boolean);
/* XCOFF support routines for ar. */
-extern boolean bfd_xcoff_ar_archive_set_magic PARAMS ((bfd *, char *));
+extern bfd_boolean bfd_xcoff_ar_archive_set_magic
+ (bfd *, char *);
/* Externally visible COFF routines. */
@@ -768,144 +756,165 @@ struct internal_syment;
union internal_auxent;
#endif
-extern boolean bfd_coff_get_syment
- PARAMS ((bfd *, struct symbol_cache_entry *, struct internal_syment *));
+extern bfd_boolean bfd_coff_get_syment
+ (bfd *, struct bfd_symbol *, struct internal_syment *);
-extern boolean bfd_coff_get_auxent
- PARAMS ((bfd *, struct symbol_cache_entry *, int, union internal_auxent *));
+extern bfd_boolean bfd_coff_get_auxent
+ (bfd *, struct bfd_symbol *, int, union internal_auxent *);
-extern boolean bfd_coff_set_symbol_class
- PARAMS ((bfd *, struct symbol_cache_entry *, unsigned int));
+extern bfd_boolean bfd_coff_set_symbol_class
+ (bfd *, struct bfd_symbol *, unsigned int);
-extern boolean bfd_m68k_coff_create_embedded_relocs
- PARAMS ((bfd *, struct bfd_link_info *, struct sec *, struct sec *,
- char **));
+extern bfd_boolean bfd_m68k_coff_create_embedded_relocs
+ (bfd *, struct bfd_link_info *, struct bfd_section *, struct bfd_section *, char **);
/* ARM Interworking support. Called from linker. */
-extern boolean bfd_arm_allocate_interworking_sections
- PARAMS ((struct bfd_link_info *));
+extern bfd_boolean bfd_arm_allocate_interworking_sections
+ (struct bfd_link_info *);
-extern boolean bfd_arm_process_before_allocation
- PARAMS ((bfd *, struct bfd_link_info *, int));
+extern bfd_boolean bfd_arm_process_before_allocation
+ (bfd *, struct bfd_link_info *, int);
-extern boolean bfd_arm_get_bfd_for_interworking
- PARAMS ((bfd *, struct bfd_link_info *));
+extern bfd_boolean bfd_arm_get_bfd_for_interworking
+ (bfd *, struct bfd_link_info *);
/* PE ARM Interworking support. Called from linker. */
-extern boolean bfd_arm_pe_allocate_interworking_sections
- PARAMS ((struct bfd_link_info *));
+extern bfd_boolean bfd_arm_pe_allocate_interworking_sections
+ (struct bfd_link_info *);
-extern boolean bfd_arm_pe_process_before_allocation
- PARAMS ((bfd *, struct bfd_link_info *, int));
+extern bfd_boolean bfd_arm_pe_process_before_allocation
+ (bfd *, struct bfd_link_info *, int);
-extern boolean bfd_arm_pe_get_bfd_for_interworking
- PARAMS ((bfd *, struct bfd_link_info *));
+extern bfd_boolean bfd_arm_pe_get_bfd_for_interworking
+ (bfd *, struct bfd_link_info *);
/* ELF ARM Interworking support. Called from linker. */
-extern boolean bfd_elf32_arm_allocate_interworking_sections
- PARAMS ((struct bfd_link_info *));
+extern bfd_boolean bfd_elf32_arm_allocate_interworking_sections
+ (struct bfd_link_info *);
+
+extern bfd_boolean bfd_elf32_arm_process_before_allocation
+ (bfd *, struct bfd_link_info *, int);
+
+extern bfd_boolean bfd_elf32_arm_get_bfd_for_interworking
+ (bfd *, struct bfd_link_info *);
-extern boolean bfd_elf32_arm_process_before_allocation
- PARAMS ((bfd *, struct bfd_link_info *, int));
+extern bfd_boolean bfd_elf32_arm_add_glue_sections_to_bfd
+ (bfd *, struct bfd_link_info *);
-extern boolean bfd_elf32_arm_get_bfd_for_interworking
- PARAMS ((bfd *, struct bfd_link_info *));
+/* ARM Note section processing. */
+extern bfd_boolean bfd_arm_merge_machines
+ (bfd *, bfd *);
-extern boolean bfd_elf32_arm_add_glue_sections_to_bfd
- PARAMS ((bfd *, struct bfd_link_info *));
+extern bfd_boolean bfd_arm_update_notes
+ (bfd *, const char *);
+
+extern unsigned int bfd_arm_get_mach_from_notes
+ (bfd *, const char *);
/* TI COFF load page support. */
extern void bfd_ticoff_set_section_load_page
- PARAMS ((struct sec *, int));
+ (struct bfd_section *, int);
extern int bfd_ticoff_get_section_load_page
- PARAMS ((struct sec *));
+ (struct bfd_section *);
+
+/* H8/300 functions. */
+extern bfd_vma bfd_h8300_pad_address
+ (bfd *, bfd_vma);
+
+/* IA64 Itanium code generation. Called from linker. */
+extern void bfd_elf32_ia64_after_parse
+ (int);
+
+extern void bfd_elf64_ia64_after_parse
+ (int);
/* Extracted from init.c. */
-void
-bfd_init PARAMS ((void));
+void bfd_init (void);
/* Extracted from opncls.c. */
-bfd *
-bfd_openr PARAMS ((const char *filename, const char *target));
+bfd *bfd_openr (const char *filename, const char *target);
+
+bfd *bfd_fdopenr (const char *filename, const char *target, int fd);
+
+bfd *bfd_openstreamr (const char *, const char *, void *);
-bfd *
-bfd_fdopenr PARAMS ((const char *filename, const char *target, int fd));
+bfd *bfd_openw (const char *filename, const char *target);
-bfd *
-bfd_openstreamr PARAMS ((const char *, const char *, PTR));
+bfd_boolean bfd_close (bfd *abfd);
-bfd *
-bfd_openw PARAMS ((const char *filename, const char *target));
+bfd_boolean bfd_close_all_done (bfd *);
-boolean
-bfd_close PARAMS ((bfd *abfd));
+bfd *bfd_create (const char *filename, bfd *templ);
-boolean
-bfd_close_all_done PARAMS ((bfd *));
+bfd_boolean bfd_make_writable (bfd *abfd);
-bfd *
-bfd_create PARAMS ((const char *filename, bfd *templ));
+bfd_boolean bfd_make_readable (bfd *abfd);
-boolean
-bfd_make_writable PARAMS ((bfd *abfd));
+unsigned long bfd_calc_gnu_debuglink_crc32
+ (unsigned long crc, const unsigned char *buf, bfd_size_type len);
-boolean
-bfd_make_readable PARAMS ((bfd *abfd));
+char *bfd_follow_gnu_debuglink (bfd *abfd, const char *dir);
+
+struct bfd_section *bfd_create_gnu_debuglink_section
+ (bfd *abfd, const char *filename);
+
+bfd_boolean bfd_fill_in_gnu_debuglink_section
+ (bfd *abfd, struct bfd_section *sect, const char *filename);
/* Extracted from libbfd.c. */
/* Byte swapping macros for user section data. */
#define bfd_put_8(abfd, val, ptr) \
- ((void) (*((unsigned char *) (ptr)) = (unsigned char) (val)))
+ ((void) (*((unsigned char *) (ptr)) = (val) & 0xff))
#define bfd_put_signed_8 \
- bfd_put_8
+ bfd_put_8
#define bfd_get_8(abfd, ptr) \
- (*(unsigned char *) (ptr) & 0xff)
+ (*(unsigned char *) (ptr) & 0xff)
#define bfd_get_signed_8(abfd, ptr) \
- (((*(unsigned char *) (ptr) & 0xff) ^ 0x80) - 0x80)
+ (((*(unsigned char *) (ptr) & 0xff) ^ 0x80) - 0x80)
#define bfd_put_16(abfd, val, ptr) \
- BFD_SEND(abfd, bfd_putx16, ((val),(ptr)))
+ BFD_SEND (abfd, bfd_putx16, ((val),(ptr)))
#define bfd_put_signed_16 \
- bfd_put_16
+ bfd_put_16
#define bfd_get_16(abfd, ptr) \
- BFD_SEND(abfd, bfd_getx16, (ptr))
+ BFD_SEND (abfd, bfd_getx16, (ptr))
#define bfd_get_signed_16(abfd, ptr) \
- BFD_SEND (abfd, bfd_getx_signed_16, (ptr))
+ BFD_SEND (abfd, bfd_getx_signed_16, (ptr))
#define bfd_put_32(abfd, val, ptr) \
- BFD_SEND(abfd, bfd_putx32, ((val),(ptr)))
+ BFD_SEND (abfd, bfd_putx32, ((val),(ptr)))
#define bfd_put_signed_32 \
- bfd_put_32
+ bfd_put_32
#define bfd_get_32(abfd, ptr) \
- BFD_SEND(abfd, bfd_getx32, (ptr))
+ BFD_SEND (abfd, bfd_getx32, (ptr))
#define bfd_get_signed_32(abfd, ptr) \
- BFD_SEND(abfd, bfd_getx_signed_32, (ptr))
+ BFD_SEND (abfd, bfd_getx_signed_32, (ptr))
#define bfd_put_64(abfd, val, ptr) \
- BFD_SEND(abfd, bfd_putx64, ((val), (ptr)))
+ BFD_SEND (abfd, bfd_putx64, ((val), (ptr)))
#define bfd_put_signed_64 \
- bfd_put_64
+ bfd_put_64
#define bfd_get_64(abfd, ptr) \
- BFD_SEND(abfd, bfd_getx64, (ptr))
+ BFD_SEND (abfd, bfd_getx64, (ptr))
#define bfd_get_signed_64(abfd, ptr) \
- BFD_SEND(abfd, bfd_getx_signed_64, (ptr))
+ BFD_SEND (abfd, bfd_getx_signed_64, (ptr))
-#define bfd_get(bits, abfd, ptr) \
- ( (bits) == 8 ? (bfd_vma) bfd_get_8 (abfd, ptr) \
- : (bits) == 16 ? bfd_get_16 (abfd, ptr) \
- : (bits) == 32 ? bfd_get_32 (abfd, ptr) \
- : (bits) == 64 ? bfd_get_64 (abfd, ptr) \
- : (abort (), (bfd_vma) - 1))
+#define bfd_get(bits, abfd, ptr) \
+ ((bits) == 8 ? (bfd_vma) bfd_get_8 (abfd, ptr) \
+ : (bits) == 16 ? bfd_get_16 (abfd, ptr) \
+ : (bits) == 32 ? bfd_get_32 (abfd, ptr) \
+ : (bits) == 64 ? bfd_get_64 (abfd, ptr) \
+ : (abort (), (bfd_vma) - 1))
-#define bfd_put(bits, abfd, val, ptr) \
- ( (bits) == 8 ? bfd_put_8 (abfd, val, ptr) \
- : (bits) == 16 ? bfd_put_16 (abfd, val, ptr) \
- : (bits) == 32 ? bfd_put_32 (abfd, val, ptr) \
- : (bits) == 64 ? bfd_put_64 (abfd, val, ptr) \
- : (abort (), (void) 0))
+#define bfd_put(bits, abfd, val, ptr) \
+ ((bits) == 8 ? bfd_put_8 (abfd, val, ptr) \
+ : (bits) == 16 ? bfd_put_16 (abfd, val, ptr) \
+ : (bits) == 32 ? bfd_put_32 (abfd, val, ptr) \
+ : (bits) == 64 ? bfd_put_64 (abfd, val, ptr) \
+ : (abort (), (void) 0))
/* Byte swapping macros for file header data. */
@@ -946,54 +955,32 @@ bfd_make_readable PARAMS ((bfd *abfd));
#define bfd_h_get_signed_64(abfd, ptr) \
BFD_SEND (abfd, bfd_h_getx_signed_64, (ptr))
-/* Refinements on the above, which should eventually go away. Save
- cluttering the source with (bfd_vma) and (bfd_byte *) casts. */
-
-#define H_PUT_64(abfd, val, where) \
- bfd_h_put_64 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-
-#define H_PUT_32(abfd, val, where) \
- bfd_h_put_32 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-
-#define H_PUT_16(abfd, val, where) \
- bfd_h_put_16 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-
-#define H_PUT_8 bfd_h_put_8
-
-#define H_PUT_S64(abfd, val, where) \
- bfd_h_put_signed_64 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-
-#define H_PUT_S32(abfd, val, where) \
- bfd_h_put_signed_32 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-
-#define H_PUT_S16(abfd, val, where) \
- bfd_h_put_signed_16 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-
-#define H_PUT_S8 bfd_h_put_signed_8
-
-#define H_GET_64(abfd, where) \
- bfd_h_get_64 ((abfd), (bfd_byte *) (where))
-
-#define H_GET_32(abfd, where) \
- bfd_h_get_32 ((abfd), (bfd_byte *) (where))
-
-#define H_GET_16(abfd, where) \
- bfd_h_get_16 ((abfd), (bfd_byte *) (where))
+/* Aliases for the above, which should eventually go away. */
-#define H_GET_8 bfd_h_get_8
+#define H_PUT_64 bfd_h_put_64
+#define H_PUT_32 bfd_h_put_32
+#define H_PUT_16 bfd_h_put_16
+#define H_PUT_8 bfd_h_put_8
+#define H_PUT_S64 bfd_h_put_signed_64
+#define H_PUT_S32 bfd_h_put_signed_32
+#define H_PUT_S16 bfd_h_put_signed_16
+#define H_PUT_S8 bfd_h_put_signed_8
+#define H_GET_64 bfd_h_get_64
+#define H_GET_32 bfd_h_get_32
+#define H_GET_16 bfd_h_get_16
+#define H_GET_8 bfd_h_get_8
+#define H_GET_S64 bfd_h_get_signed_64
+#define H_GET_S32 bfd_h_get_signed_32
+#define H_GET_S16 bfd_h_get_signed_16
+#define H_GET_S8 bfd_h_get_signed_8
-#define H_GET_S64(abfd, where) \
- bfd_h_get_signed_64 ((abfd), (bfd_byte *) (where))
-#define H_GET_S32(abfd, where) \
- bfd_h_get_signed_32 ((abfd), (bfd_byte *) (where))
-
-#define H_GET_S16(abfd, where) \
- bfd_h_get_signed_16 ((abfd), (bfd_byte *) (where))
-
-#define H_GET_S8 bfd_h_get_signed_8
+/* Extracted from bfdio.c. */
+long bfd_get_mtime (bfd *abfd);
+long bfd_get_size (bfd *abfd);
+/* Extracted from bfdwin.c. */
/* Extracted from section.c. */
/* This structure is used for a comdat section, as in PE. A comdat
section is associated with a particular symbol. When the linker
@@ -1012,7 +999,7 @@ struct bfd_comdat_info
long symbol;
};
-typedef struct sec
+typedef struct bfd_section
{
/* The name of the section; the name isn't a copy, the pointer is
the same as that passed to bfd_make_section. */
@@ -1025,7 +1012,7 @@ typedef struct sec
int index;
/* The next section in the list belonging to the BFD, or NULL. */
- struct sec *next;
+ struct bfd_section *next;
/* The field flags contains attributes of the section. Some
flags are read in from the object file, and some are
@@ -1223,10 +1210,39 @@ typedef struct sec
/* A mark flag used by some linker backends for garbage collection. */
unsigned int gc_mark : 1;
- /* Used by the ELF code to mark sections which have been allocated
- to segments. */
+ /* The following flags are used by the ELF linker. */
+
+ /* Mark sections which have been allocated to segments. */
unsigned int segment_mark : 1;
+ /* Type of sec_info information. */
+ unsigned int sec_info_type:3;
+#define ELF_INFO_TYPE_NONE 0
+#define ELF_INFO_TYPE_STABS 1
+#define ELF_INFO_TYPE_MERGE 2
+#define ELF_INFO_TYPE_EH_FRAME 3
+#define ELF_INFO_TYPE_JUST_SYMS 4
+
+ /* Nonzero if this section uses RELA relocations, rather than REL. */
+ unsigned int use_rela_p:1;
+
+ /* Bits used by various backends. */
+ unsigned int has_tls_reloc:1;
+
+ /* Nonzero if this section needs the relax finalize pass. */
+ unsigned int need_finalize_relax:1;
+
+ /* Nonzero if this section has a gp reloc. */
+ unsigned int has_gp_reloc:1;
+
+ /* Unused bits. */
+ unsigned int flag13:1;
+ unsigned int flag14:1;
+ unsigned int flag15:1;
+ unsigned int flag16:4;
+ unsigned int flag20:4;
+ unsigned int flag24:8;
+
/* End of internal packed boolean fields. */
/* The virtual memory address of the section - where it will be
@@ -1262,7 +1278,7 @@ typedef struct sec
bfd_vma output_offset;
/* The output section through which to map on output. */
- struct sec *output_section;
+ struct bfd_section *output_section;
/* The alignment requirement of the section, as an exponent of 2 -
e.g., 3 aligns to 2^3 (or 8). */
@@ -1292,7 +1308,7 @@ typedef struct sec
file_ptr line_filepos;
/* Pointer to data for applications. */
- PTR userdata;
+ void *userdata;
/* If the SEC_IN_MEMORY flag is set, this points to the actual
contents. */
@@ -1310,6 +1326,10 @@ typedef struct sec
/* Optional information about a COMDAT entry; NULL if not COMDAT. */
struct bfd_comdat_info *comdat;
+ /* Points to the kept section if this section is a link-once section,
+ and is discarded. */
+ struct bfd_section *kept_section;
+
/* When a section is being output, this value changes as more
linenumbers are written out. */
file_ptr moving_line_filepos;
@@ -1317,7 +1337,7 @@ typedef struct sec
/* What the section number is in the target world. */
int target_index;
- PTR used_by_bfd;
+ void *used_by_bfd;
/* If this is a constructor section then here is a list of the
relocations created to relocate items within it. */
@@ -1327,8 +1347,8 @@ typedef struct sec
bfd *owner;
/* A symbol which points at this section only. */
- struct symbol_cache_entry *symbol;
- struct symbol_cache_entry **symbol_ptr_ptr;
+ struct bfd_symbol *symbol;
+ struct bfd_symbol **symbol_ptr_ptr;
struct bfd_link_order *link_order_head;
struct bfd_link_order *link_order_tail;
@@ -1345,18 +1365,18 @@ typedef struct sec
#define BFD_IND_SECTION_NAME "*IND*"
/* The absolute section. */
-extern const asection bfd_abs_section;
+extern asection bfd_abs_section;
#define bfd_abs_section_ptr ((asection *) &bfd_abs_section)
#define bfd_is_abs_section(sec) ((sec) == bfd_abs_section_ptr)
/* Pointer to the undefined section. */
-extern const asection bfd_und_section;
+extern asection bfd_und_section;
#define bfd_und_section_ptr ((asection *) &bfd_und_section)
#define bfd_is_und_section(sec) ((sec) == bfd_und_section_ptr)
/* Pointer to the common section. */
-extern const asection bfd_com_section;
+extern asection bfd_com_section;
#define bfd_com_section_ptr ((asection *) &bfd_com_section)
/* Pointer to the indirect section. */
-extern const asection bfd_ind_section;
+extern asection bfd_ind_section;
#define bfd_ind_section_ptr ((asection *) &bfd_ind_section)
#define bfd_is_ind_section(sec) ((sec) == bfd_ind_section_ptr)
@@ -1366,13 +1386,12 @@ extern const asection bfd_ind_section;
|| ((SEC) == bfd_com_section_ptr) \
|| ((SEC) == bfd_ind_section_ptr))
-extern const struct symbol_cache_entry * const bfd_abs_symbol;
-extern const struct symbol_cache_entry * const bfd_com_symbol;
-extern const struct symbol_cache_entry * const bfd_und_symbol;
-extern const struct symbol_cache_entry * const bfd_ind_symbol;
+extern const struct bfd_symbol * const bfd_abs_symbol;
+extern const struct bfd_symbol * const bfd_com_symbol;
+extern const struct bfd_symbol * const bfd_und_symbol;
+extern const struct bfd_symbol * const bfd_ind_symbol;
#define bfd_get_section_size_before_reloc(section) \
- ((section)->reloc_done ? (abort (), (bfd_size_type) 1) \
- : (section)->_raw_size)
+ ((section)->_raw_size)
#define bfd_get_section_size_after_reloc(section) \
((section)->reloc_done ? (section)->_cooked_size \
: (abort (), (bfd_size_type) 1))
@@ -1402,61 +1421,48 @@ extern const struct symbol_cache_entry * const bfd_ind_symbol;
} \
while (0)
-void
-bfd_section_list_clear PARAMS ((bfd *));
+void bfd_section_list_clear (bfd *);
-asection *
-bfd_get_section_by_name PARAMS ((bfd *abfd, const char *name));
+asection *bfd_get_section_by_name (bfd *abfd, const char *name);
-char *
-bfd_get_unique_section_name PARAMS ((bfd *abfd,
- const char *templat,
- int *count));
+char *bfd_get_unique_section_name
+ (bfd *abfd, const char *templat, int *count);
-asection *
-bfd_make_section_old_way PARAMS ((bfd *abfd, const char *name));
+asection *bfd_make_section_old_way (bfd *abfd, const char *name);
-asection *
-bfd_make_section_anyway PARAMS ((bfd *abfd, const char *name));
+asection *bfd_make_section_anyway (bfd *abfd, const char *name);
-asection *
-bfd_make_section PARAMS ((bfd *, const char *name));
+asection *bfd_make_section (bfd *, const char *name);
-boolean
-bfd_set_section_flags PARAMS ((bfd *abfd, asection *sec, flagword flags));
+bfd_boolean bfd_set_section_flags
+ (bfd *abfd, asection *sec, flagword flags);
-void
-bfd_map_over_sections PARAMS ((bfd *abfd,
- void (*func) (bfd *abfd,
- asection *sect,
- PTR obj),
- PTR obj));
+void bfd_map_over_sections
+ (bfd *abfd,
+ void (*func) (bfd *abfd, asection *sect, void *obj),
+ void *obj);
-boolean
-bfd_set_section_size PARAMS ((bfd *abfd, asection *sec, bfd_size_type val));
+bfd_boolean bfd_set_section_size
+ (bfd *abfd, asection *sec, bfd_size_type val);
-boolean
-bfd_set_section_contents PARAMS ((bfd *abfd, asection *section,
- PTR data, file_ptr offset,
- bfd_size_type count));
+bfd_boolean bfd_set_section_contents
+ (bfd *abfd, asection *section, const void *data,
+ file_ptr offset, bfd_size_type count);
-boolean
-bfd_get_section_contents PARAMS ((bfd *abfd, asection *section,
- PTR location, file_ptr offset,
- bfd_size_type count));
+bfd_boolean bfd_get_section_contents
+ (bfd *abfd, asection *section, void *location, file_ptr offset,
+ bfd_size_type count);
-boolean
-bfd_copy_private_section_data PARAMS ((bfd *ibfd, asection *isec,
- bfd *obfd, asection *osec));
+bfd_boolean bfd_copy_private_section_data
+ (bfd *ibfd, asection *isec, bfd *obfd, asection *osec);
#define bfd_copy_private_section_data(ibfd, isection, obfd, osection) \
BFD_SEND (obfd, _bfd_copy_private_section_data, \
(ibfd, isection, obfd, osection))
-void
-_bfd_strip_section_from_output PARAMS ((struct bfd_link_info *info, asection *section));
+void _bfd_strip_section_from_output
+ (struct bfd_link_info *info, asection *section);
-boolean
-bfd_generic_discard_group PARAMS ((bfd *abfd, asection *group));
+bfd_boolean bfd_generic_discard_group (bfd *abfd, asection *group);
/* Extracted from archures.c. */
enum bfd_architecture
@@ -1476,6 +1482,7 @@ enum bfd_architecture
#define bfd_mach_mcf5206e 10
#define bfd_mach_mcf5307 11
#define bfd_mach_mcf5407 12
+#define bfd_mach_mcf528x 13
bfd_arch_vax, /* DEC Vax */
bfd_arch_i960, /* Intel 960 */
/* The order of the following is important.
@@ -1521,12 +1528,16 @@ enum bfd_architecture
#define bfd_mach_mips4010 4010
#define bfd_mach_mips4100 4100
#define bfd_mach_mips4111 4111
+#define bfd_mach_mips4120 4120
#define bfd_mach_mips4300 4300
#define bfd_mach_mips4400 4400
#define bfd_mach_mips4600 4600
#define bfd_mach_mips4650 4650
#define bfd_mach_mips5000 5000
+#define bfd_mach_mips5400 5400
+#define bfd_mach_mips5500 5500
#define bfd_mach_mips6000 6000
+#define bfd_mach_mips7000 7000
#define bfd_mach_mips8000 8000
#define bfd_mach_mips10000 10000
#define bfd_mach_mips12000 12000
@@ -1534,13 +1545,15 @@ enum bfd_architecture
#define bfd_mach_mips5 5
#define bfd_mach_mips_sb1 12310201 /* octal 'SB', 01 */
#define bfd_mach_mipsisa32 32
+#define bfd_mach_mipsisa32r2 33
#define bfd_mach_mipsisa64 64
+#define bfd_mach_mipsisa64r2 65
bfd_arch_i386, /* Intel 386 */
-#define bfd_mach_i386_i386 0
-#define bfd_mach_i386_i8086 1
-#define bfd_mach_i386_i386_intel_syntax 2
-#define bfd_mach_x86_64 3
-#define bfd_mach_x86_64_intel_syntax 4
+#define bfd_mach_i386_i386 1
+#define bfd_mach_i386_i8086 2
+#define bfd_mach_i386_i386_intel_syntax 3
+#define bfd_mach_x86_64 64
+#define bfd_mach_x86_64_intel_syntax 65
bfd_arch_we32k, /* AT&T WE32xxx */
bfd_arch_tahoe, /* CCI/Harris Tahoe */
bfd_arch_i860, /* Intel 860 */
@@ -1549,15 +1562,20 @@ enum bfd_architecture
bfd_arch_alliant, /* Alliant */
bfd_arch_convex, /* Convex */
bfd_arch_m88k, /* Motorola 88xxx */
+ bfd_arch_m98k, /* Motorola 98xxx */
bfd_arch_pyramid, /* Pyramid Technology */
- bfd_arch_h8300, /* Hitachi H8/300 */
-#define bfd_mach_h8300 1
-#define bfd_mach_h8300h 2
-#define bfd_mach_h8300s 3
+ bfd_arch_h8300, /* Renesas H8/300 (formerly Hitachi H8/300) */
+#define bfd_mach_h8300 1
+#define bfd_mach_h8300h 2
+#define bfd_mach_h8300s 3
+#define bfd_mach_h8300hn 4
+#define bfd_mach_h8300sn 5
+#define bfd_mach_h8300sx 6
+#define bfd_mach_h8300sxn 7
bfd_arch_pdp11, /* DEC PDP-11 */
bfd_arch_powerpc, /* PowerPC */
-#define bfd_mach_ppc 0
-#define bfd_mach_ppc64 1
+#define bfd_mach_ppc 32
+#define bfd_mach_ppc64 64
#define bfd_mach_ppc_403 403
#define bfd_mach_ppc_403gc 4030
#define bfd_mach_ppc_505 505
@@ -1574,38 +1592,52 @@ enum bfd_architecture
#define bfd_mach_ppc_rs64ii 642
#define bfd_mach_ppc_rs64iii 643
#define bfd_mach_ppc_7400 7400
+#define bfd_mach_ppc_e500 500
bfd_arch_rs6000, /* IBM RS/6000 */
-#define bfd_mach_rs6k 0
+#define bfd_mach_rs6k 6000
#define bfd_mach_rs6k_rs1 6001
#define bfd_mach_rs6k_rsc 6003
#define bfd_mach_rs6k_rs2 6002
bfd_arch_hppa, /* HP PA RISC */
+#define bfd_mach_hppa10 10
+#define bfd_mach_hppa11 11
+#define bfd_mach_hppa20 20
+#define bfd_mach_hppa20w 25
bfd_arch_d10v, /* Mitsubishi D10V */
-#define bfd_mach_d10v 0
+#define bfd_mach_d10v 1
#define bfd_mach_d10v_ts2 2
#define bfd_mach_d10v_ts3 3
bfd_arch_d30v, /* Mitsubishi D30V */
bfd_arch_dlx, /* DLX */
bfd_arch_m68hc11, /* Motorola 68HC11 */
bfd_arch_m68hc12, /* Motorola 68HC12 */
+#define bfd_mach_m6812_default 0
+#define bfd_mach_m6812 1
+#define bfd_mach_m6812s 2
bfd_arch_z8k, /* Zilog Z8000 */
#define bfd_mach_z8001 1
#define bfd_mach_z8002 2
- bfd_arch_h8500, /* Hitachi H8/500 */
- bfd_arch_sh, /* Hitachi SH */
-#define bfd_mach_sh 0
+ bfd_arch_h8500, /* Renesas H8/500 (formerly Hitachi H8/500) */
+ bfd_arch_sh, /* Renesas / SuperH SH (formerly Hitachi SH) */
+#define bfd_mach_sh 1
#define bfd_mach_sh2 0x20
#define bfd_mach_sh_dsp 0x2d
+#define bfd_mach_sh2e 0x2e
#define bfd_mach_sh3 0x30
#define bfd_mach_sh3_dsp 0x3d
#define bfd_mach_sh3e 0x3e
#define bfd_mach_sh4 0x40
+#define bfd_mach_sh4_nofpu 0x41
+#define bfd_mach_sh4a 0x4a
+#define bfd_mach_sh4a_nofpu 0x4b
+#define bfd_mach_sh4al_dsp 0x4d
#define bfd_mach_sh5 0x50
bfd_arch_alpha, /* Dec Alpha */
#define bfd_mach_alpha_ev4 0x10
#define bfd_mach_alpha_ev5 0x20
#define bfd_mach_alpha_ev6 0x30
bfd_arch_arm, /* Advanced Risc Machines ARM. */
+#define bfd_mach_arm_unknown 0
#define bfd_mach_arm_2 1
#define bfd_mach_arm_2a 2
#define bfd_mach_arm_3 3
@@ -1616,40 +1648,54 @@ enum bfd_architecture
#define bfd_mach_arm_5T 8
#define bfd_mach_arm_5TE 9
#define bfd_mach_arm_XScale 10
+#define bfd_mach_arm_ep9312 11
+#define bfd_mach_arm_iWMMXt 12
bfd_arch_ns32k, /* National Semiconductors ns32000 */
bfd_arch_w65, /* WDC 65816 */
bfd_arch_tic30, /* Texas Instruments TMS320C30 */
+ bfd_arch_tic4x, /* Texas Instruments TMS320C3X/4X */
+#define bfd_mach_tic3x 30
+#define bfd_mach_tic4x 40
bfd_arch_tic54x, /* Texas Instruments TMS320C54X */
bfd_arch_tic80, /* TI TMS320c80 (MVP) */
bfd_arch_v850, /* NEC V850 */
-#define bfd_mach_v850 0
+#define bfd_mach_v850 1
#define bfd_mach_v850e 'E'
-#define bfd_mach_v850ea 'A'
+#define bfd_mach_v850e1 '1'
bfd_arch_arc, /* ARC Cores */
-#define bfd_mach_arc_5 0
-#define bfd_mach_arc_6 1
-#define bfd_mach_arc_7 2
-#define bfd_mach_arc_8 3
- bfd_arch_m32r, /* Mitsubishi M32R/D */
-#define bfd_mach_m32r 0 /* For backwards compatibility. */
+#define bfd_mach_arc_5 5
+#define bfd_mach_arc_6 6
+#define bfd_mach_arc_7 7
+#define bfd_mach_arc_8 8
+ bfd_arch_m32r, /* Renesas M32R (formerly Mitsubishi M32R/D) */
+#define bfd_mach_m32r 1 /* For backwards compatibility. */
#define bfd_mach_m32rx 'x'
+#define bfd_mach_m32r2 '2'
bfd_arch_mn10200, /* Matsushita MN10200 */
bfd_arch_mn10300, /* Matsushita MN10300 */
#define bfd_mach_mn10300 300
#define bfd_mach_am33 330
+#define bfd_mach_am33_2 332
bfd_arch_fr30,
#define bfd_mach_fr30 0x46523330
bfd_arch_frv,
-#define bfd_mach_frv 0
-#define bfd_mach_frvsimple 1
+#define bfd_mach_frv 1
+#define bfd_mach_frvsimple 2
#define bfd_mach_fr300 300
#define bfd_mach_fr400 400
#define bfd_mach_frvtomcat 499 /* fr500 prototype */
#define bfd_mach_fr500 500
+#define bfd_mach_fr550 550
bfd_arch_mcore,
bfd_arch_ia64, /* HP/Intel ia64 */
-#define bfd_mach_ia64_elf64 0
-#define bfd_mach_ia64_elf32 1
+#define bfd_mach_ia64_elf64 64
+#define bfd_mach_ia64_elf32 32
+ bfd_arch_ip2k, /* Ubicom IP2K microcontrollers. */
+#define bfd_mach_ip2022 1
+#define bfd_mach_ip2022ext 2
+ bfd_arch_iq2000, /* Vitesse IQ2000. */
+#define bfd_mach_iq2000 1
+#define bfd_mach_iq10 2
bfd_arch_pj,
bfd_arch_avr, /* Atmel AVR microcontrollers. */
#define bfd_mach_avr1 1
@@ -1659,12 +1705,29 @@ enum bfd_architecture
#define bfd_mach_avr5 5
bfd_arch_cris, /* Axis CRIS */
bfd_arch_s390, /* IBM s390 */
-#define bfd_mach_s390_31 0
-#define bfd_mach_s390_64 1
+#define bfd_mach_s390_31 31
+#define bfd_mach_s390_64 64
bfd_arch_openrisc, /* OpenRISC */
bfd_arch_mmix, /* Donald Knuth's educational processor. */
bfd_arch_xstormy16,
-#define bfd_mach_xstormy16 0
+#define bfd_mach_xstormy16 1
+ bfd_arch_msp430, /* Texas Instruments MSP430 architecture. */
+#define bfd_mach_msp11 11
+#define bfd_mach_msp110 110
+#define bfd_mach_msp12 12
+#define bfd_mach_msp13 13
+#define bfd_mach_msp14 14
+#define bfd_mach_msp15 15
+#define bfd_mach_msp16 16
+#define bfd_mach_msp31 31
+#define bfd_mach_msp32 32
+#define bfd_mach_msp33 33
+#define bfd_mach_msp41 41
+#define bfd_mach_msp42 42
+#define bfd_mach_msp43 43
+#define bfd_mach_msp44 44
+ bfd_arch_xtensa, /* Tensilica's Xtensa cores. */
+#define bfd_mach_xtensa 1
bfd_arch_last
};
@@ -1678,66 +1741,50 @@ typedef struct bfd_arch_info
const char *arch_name;
const char *printable_name;
unsigned int section_align_power;
- /* True if this is the default machine for the architecture.
+ /* TRUE if this is the default machine for the architecture.
The default arch should be the first entry for an arch so that
all the entries for that arch can be accessed via <<next>>. */
- boolean the_default;
+ bfd_boolean the_default;
const struct bfd_arch_info * (*compatible)
- PARAMS ((const struct bfd_arch_info *a,
- const struct bfd_arch_info *b));
+ (const struct bfd_arch_info *a, const struct bfd_arch_info *b);
- boolean (*scan) PARAMS ((const struct bfd_arch_info *, const char *));
+ bfd_boolean (*scan) (const struct bfd_arch_info *, const char *);
const struct bfd_arch_info *next;
}
bfd_arch_info_type;
-const char *
-bfd_printable_name PARAMS ((bfd *abfd));
+const char *bfd_printable_name (bfd *abfd);
-const bfd_arch_info_type *
-bfd_scan_arch PARAMS ((const char *string));
+const bfd_arch_info_type *bfd_scan_arch (const char *string);
-const char **
-bfd_arch_list PARAMS ((void));
+const char **bfd_arch_list (void);
-const bfd_arch_info_type *
-bfd_arch_get_compatible PARAMS ((
- const bfd *abfd,
- const bfd *bbfd));
+const bfd_arch_info_type *bfd_arch_get_compatible
+ (const bfd *abfd, const bfd *bbfd, bfd_boolean accept_unknowns);
-void
-bfd_set_arch_info PARAMS ((bfd *abfd, const bfd_arch_info_type *arg));
+void bfd_set_arch_info (bfd *abfd, const bfd_arch_info_type *arg);
-enum bfd_architecture
-bfd_get_arch PARAMS ((bfd *abfd));
+enum bfd_architecture bfd_get_arch (bfd *abfd);
-unsigned long
-bfd_get_mach PARAMS ((bfd *abfd));
+unsigned long bfd_get_mach (bfd *abfd);
-unsigned int
-bfd_arch_bits_per_byte PARAMS ((bfd *abfd));
+unsigned int bfd_arch_bits_per_byte (bfd *abfd);
-unsigned int
-bfd_arch_bits_per_address PARAMS ((bfd *abfd));
+unsigned int bfd_arch_bits_per_address (bfd *abfd);
-const bfd_arch_info_type *
-bfd_get_arch_info PARAMS ((bfd *abfd));
+const bfd_arch_info_type *bfd_get_arch_info (bfd *abfd);
-const bfd_arch_info_type *
-bfd_lookup_arch PARAMS ((enum bfd_architecture
- arch,
- unsigned long machine));
+const bfd_arch_info_type *bfd_lookup_arch
+ (enum bfd_architecture arch, unsigned long machine);
-const char *
-bfd_printable_arch_mach PARAMS ((enum bfd_architecture arch, unsigned long machine));
+const char *bfd_printable_arch_mach
+ (enum bfd_architecture arch, unsigned long machine);
-unsigned int
-bfd_octets_per_byte PARAMS ((bfd *abfd));
+unsigned int bfd_octets_per_byte (bfd *abfd);
-unsigned int
-bfd_arch_mach_octets_per_byte PARAMS ((enum bfd_architecture arch,
- unsigned long machine));
+unsigned int bfd_arch_mach_octets_per_byte
+ (enum bfd_architecture arch, unsigned long machine);
/* Extracted from reloc.c. */
typedef enum bfd_reloc_status
@@ -1775,7 +1822,7 @@ typedef enum bfd_reloc_status
typedef struct reloc_cache_entry
{
/* A pointer into the canonical table of pointers. */
- struct symbol_cache_entry **sym_ptr_ptr;
+ struct bfd_symbol **sym_ptr_ptr;
/* offset in section. */
bfd_size_type address;
@@ -1834,7 +1881,7 @@ struct reloc_howto_struct
data section of the addend. The relocation function will
subtract from the relocation value the address of the location
being relocated. */
- boolean pc_relative;
+ bfd_boolean pc_relative;
/* The bit position of the reloc value in the destination.
The relocated value is left shifted by this amount. */
@@ -1846,11 +1893,11 @@ struct reloc_howto_struct
/* If this field is non null, then the supplied function is
called rather than the normal function. This allows really
- strange relocation methods to be accomodated (e.g., i960 callj
+ strange relocation methods to be accommodated (e.g., i960 callj
instructions). */
bfd_reloc_status_type (*special_function)
- PARAMS ((bfd *, arelent *, struct symbol_cache_entry *, PTR, asection *,
- bfd *, char **));
+ (bfd *, arelent *, struct bfd_symbol *, void *, asection *,
+ bfd *, char **);
/* The textual name of the relocation type. */
char *name;
@@ -1870,21 +1917,20 @@ struct reloc_howto_struct
USE_REL targets set this field to TRUE. Why this is so is peculiar
to each particular target. For relocs that aren't used in partial
links (e.g. GOT stuff) it doesn't matter what this is set to. */
- boolean partial_inplace;
-
- /* The src_mask selects which parts of the read in data
- are to be used in the relocation sum. E.g., if this was an 8 bit
- byte of data which we read and relocated, this would be
- 0x000000ff. When we have relocs which have an addend, such as
- sun4 extended relocs, the value in the offset part of a
- relocating field is garbage so we never use it. In this case
- the mask would be 0x00000000. */
+ bfd_boolean partial_inplace;
+
+ /* src_mask selects the part of the instruction (or data) to be used
+ in the relocation sum. If the target relocations don't have an
+ addend in the reloc, eg. ELF USE_REL, src_mask will normally equal
+ dst_mask to extract the addend from the section contents. If
+ relocations do have an addend in the reloc, eg. ELF USE_RELA, this
+ field should be zero. Non-zero values for ELF USE_RELA targets are
+ bogus as in those cases the value in the dst_mask part of the
+ section contents should be treated as garbage. */
bfd_vma src_mask;
- /* The dst_mask selects which parts of the instruction are replaced
- into the instruction. In most cases src_mask == dst_mask,
- except in the above special case, where dst_mask would be
- 0x000000ff, and src_mask would be 0x00000000. */
+ /* dst_mask selects which parts of the instruction (or data) are
+ replaced with a relocated value. */
bfd_vma dst_mask;
/* When some formats create PC relative instructions, they leave
@@ -1893,22 +1939,22 @@ struct reloc_howto_struct
be made just by adding in an ordinary offset (e.g., sun3 a.out).
Some formats leave the displacement part of an instruction
empty (e.g., m88k bcs); this flag signals the fact. */
- boolean pcrel_offset;
+ bfd_boolean pcrel_offset;
};
#define HOWTO(C, R, S, B, P, BI, O, SF, NAME, INPLACE, MASKSRC, MASKDST, PC) \
{ (unsigned) C, R, S, B, P, BI, O, SF, NAME, INPLACE, MASKSRC, MASKDST, PC }
#define NEWHOWTO(FUNCTION, NAME, SIZE, REL, IN) \
HOWTO (0, 0, SIZE, 0, REL, 0, complain_overflow_dont, FUNCTION, \
- NAME, false, 0, 0, IN)
+ NAME, FALSE, 0, 0, IN)
#define EMPTY_HOWTO(C) \
- HOWTO ((C), 0, 0, 0, false, 0, complain_overflow_dont, NULL, \
- NULL, false, 0, 0, false)
+ HOWTO ((C), 0, 0, 0, FALSE, 0, complain_overflow_dont, NULL, \
+ NULL, FALSE, 0, 0, FALSE)
#define HOWTO_PREPARE(relocation, symbol) \
{ \
- if (symbol != (asymbol *) NULL) \
+ if (symbol != NULL) \
{ \
if (bfd_is_com_section (symbol->section)) \
{ \
@@ -1921,8 +1967,7 @@ struct reloc_howto_struct
} \
}
-unsigned int
-bfd_get_reloc_size PARAMS ((reloc_howto_type *));
+unsigned int bfd_get_reloc_size (reloc_howto_type *);
typedef struct relent_chain
{
@@ -1931,27 +1976,27 @@ typedef struct relent_chain
}
arelent_chain;
-bfd_reloc_status_type
-bfd_check_overflow PARAMS ((enum complain_overflow how,
+bfd_reloc_status_type bfd_check_overflow
+ (enum complain_overflow how,
unsigned int bitsize,
unsigned int rightshift,
unsigned int addrsize,
- bfd_vma relocation));
+ bfd_vma relocation);
-bfd_reloc_status_type
-bfd_perform_relocation PARAMS ((bfd *abfd,
+bfd_reloc_status_type bfd_perform_relocation
+ (bfd *abfd,
arelent *reloc_entry,
- PTR data,
+ void *data,
asection *input_section,
bfd *output_bfd,
- char **error_message));
+ char **error_message);
-bfd_reloc_status_type
-bfd_install_relocation PARAMS ((bfd *abfd,
+bfd_reloc_status_type bfd_install_relocation
+ (bfd *abfd,
arelent *reloc_entry,
- PTR data, bfd_vma data_start,
+ void *data, bfd_vma data_start,
asection *input_section,
- char **error_message));
+ char **error_message);
enum bfd_reloc_code_real {
_dummy_first_bfd_reloc_code_real,
@@ -2096,6 +2141,32 @@ relocation types already defined. */
/* SPARC little endian relocation */
BFD_RELOC_SPARC_REV32,
+/* SPARC TLS relocations */
+ BFD_RELOC_SPARC_TLS_GD_HI22,
+ BFD_RELOC_SPARC_TLS_GD_LO10,
+ BFD_RELOC_SPARC_TLS_GD_ADD,
+ BFD_RELOC_SPARC_TLS_GD_CALL,
+ BFD_RELOC_SPARC_TLS_LDM_HI22,
+ BFD_RELOC_SPARC_TLS_LDM_LO10,
+ BFD_RELOC_SPARC_TLS_LDM_ADD,
+ BFD_RELOC_SPARC_TLS_LDM_CALL,
+ BFD_RELOC_SPARC_TLS_LDO_HIX22,
+ BFD_RELOC_SPARC_TLS_LDO_LOX10,
+ BFD_RELOC_SPARC_TLS_LDO_ADD,
+ BFD_RELOC_SPARC_TLS_IE_HI22,
+ BFD_RELOC_SPARC_TLS_IE_LO10,
+ BFD_RELOC_SPARC_TLS_IE_LD,
+ BFD_RELOC_SPARC_TLS_IE_LDX,
+ BFD_RELOC_SPARC_TLS_IE_ADD,
+ BFD_RELOC_SPARC_TLS_LE_HIX22,
+ BFD_RELOC_SPARC_TLS_LE_LOX10,
+ BFD_RELOC_SPARC_TLS_DTPMOD32,
+ BFD_RELOC_SPARC_TLS_DTPMOD64,
+ BFD_RELOC_SPARC_TLS_DTPOFF32,
+ BFD_RELOC_SPARC_TLS_DTPOFF64,
+ BFD_RELOC_SPARC_TLS_TPOFF32,
+ BFD_RELOC_SPARC_TLS_TPOFF64,
+
/* Alpha ECOFF and ELF relocations. Some of these treat the symbol or
"addend" in some special way.
For GPDISP_HI16 ("gpdisp") relocations, the symbol is ignored when
@@ -2161,7 +2232,7 @@ GP register. */
BFD_RELOC_ALPHA_GPREL_LO16,
/* Like BFD_RELOC_23_PCREL_S2, except that the source and target must
-share a common GP, and the target address is adjusted for
+share a common GP, and the target address is adjusted for
STO_ALPHA_STD_GPLOAD. */
BFD_RELOC_ALPHA_BRSGP,
@@ -2234,6 +2305,7 @@ to compensate for the borrow when the low bits are added. */
BFD_RELOC_MIPS_RELGOT,
BFD_RELOC_MIPS_JALR,
+
/* Fujitsu Frv Relocations. */
BFD_RELOC_FRV_LABEL16,
BFD_RELOC_FRV_LABEL24,
@@ -2244,6 +2316,48 @@ to compensate for the borrow when the low bits are added. */
BFD_RELOC_FRV_GPREL32,
BFD_RELOC_FRV_GPRELHI,
BFD_RELOC_FRV_GPRELLO,
+ BFD_RELOC_FRV_GOT12,
+ BFD_RELOC_FRV_GOTHI,
+ BFD_RELOC_FRV_GOTLO,
+ BFD_RELOC_FRV_FUNCDESC,
+ BFD_RELOC_FRV_FUNCDESC_GOT12,
+ BFD_RELOC_FRV_FUNCDESC_GOTHI,
+ BFD_RELOC_FRV_FUNCDESC_GOTLO,
+ BFD_RELOC_FRV_FUNCDESC_VALUE,
+ BFD_RELOC_FRV_FUNCDESC_GOTOFF12,
+ BFD_RELOC_FRV_FUNCDESC_GOTOFFHI,
+ BFD_RELOC_FRV_FUNCDESC_GOTOFFLO,
+ BFD_RELOC_FRV_GOTOFF12,
+ BFD_RELOC_FRV_GOTOFFHI,
+ BFD_RELOC_FRV_GOTOFFLO,
+
+
+/* This is a 24bit GOT-relative reloc for the mn10300. */
+ BFD_RELOC_MN10300_GOTOFF24,
+
+/* This is a 32bit GOT-relative reloc for the mn10300, offset by two bytes
+in the instruction. */
+ BFD_RELOC_MN10300_GOT32,
+
+/* This is a 24bit GOT-relative reloc for the mn10300, offset by two bytes
+in the instruction. */
+ BFD_RELOC_MN10300_GOT24,
+
+/* This is a 16bit GOT-relative reloc for the mn10300, offset by two bytes
+in the instruction. */
+ BFD_RELOC_MN10300_GOT16,
+
+/* Copy symbol at runtime. */
+ BFD_RELOC_MN10300_COPY,
+
+/* Create GOT entry. */
+ BFD_RELOC_MN10300_GLOB_DAT,
+
+/* Create PLT entry. */
+ BFD_RELOC_MN10300_JMP_SLOT,
+
+/* Adjust by program base. */
+ BFD_RELOC_MN10300_RELATIVE,
/* i386/elf relocations */
@@ -2277,6 +2391,14 @@ to compensate for the borrow when the low bits are added. */
BFD_RELOC_X86_64_RELATIVE,
BFD_RELOC_X86_64_GOTPCREL,
BFD_RELOC_X86_64_32S,
+ BFD_RELOC_X86_64_DTPMOD64,
+ BFD_RELOC_X86_64_DTPOFF64,
+ BFD_RELOC_X86_64_TPOFF64,
+ BFD_RELOC_X86_64_TLSGD,
+ BFD_RELOC_X86_64_TLSLD,
+ BFD_RELOC_X86_64_DTPOFF32,
+ BFD_RELOC_X86_64_GOTTPOFF,
+ BFD_RELOC_X86_64_TPOFF32,
/* ns32k relocations */
BFD_RELOC_NS32K_IMM_8,
@@ -2359,10 +2481,52 @@ to compensate for the borrow when the low bits are added. */
BFD_RELOC_PPC64_PLTGOT16_DS,
BFD_RELOC_PPC64_PLTGOT16_LO_DS,
+/* PowerPC and PowerPC64 thread-local storage relocations. */
+ BFD_RELOC_PPC_TLS,
+ BFD_RELOC_PPC_DTPMOD,
+ BFD_RELOC_PPC_TPREL16,
+ BFD_RELOC_PPC_TPREL16_LO,
+ BFD_RELOC_PPC_TPREL16_HI,
+ BFD_RELOC_PPC_TPREL16_HA,
+ BFD_RELOC_PPC_TPREL,
+ BFD_RELOC_PPC_DTPREL16,
+ BFD_RELOC_PPC_DTPREL16_LO,
+ BFD_RELOC_PPC_DTPREL16_HI,
+ BFD_RELOC_PPC_DTPREL16_HA,
+ BFD_RELOC_PPC_DTPREL,
+ BFD_RELOC_PPC_GOT_TLSGD16,
+ BFD_RELOC_PPC_GOT_TLSGD16_LO,
+ BFD_RELOC_PPC_GOT_TLSGD16_HI,
+ BFD_RELOC_PPC_GOT_TLSGD16_HA,
+ BFD_RELOC_PPC_GOT_TLSLD16,
+ BFD_RELOC_PPC_GOT_TLSLD16_LO,
+ BFD_RELOC_PPC_GOT_TLSLD16_HI,
+ BFD_RELOC_PPC_GOT_TLSLD16_HA,
+ BFD_RELOC_PPC_GOT_TPREL16,
+ BFD_RELOC_PPC_GOT_TPREL16_LO,
+ BFD_RELOC_PPC_GOT_TPREL16_HI,
+ BFD_RELOC_PPC_GOT_TPREL16_HA,
+ BFD_RELOC_PPC_GOT_DTPREL16,
+ BFD_RELOC_PPC_GOT_DTPREL16_LO,
+ BFD_RELOC_PPC_GOT_DTPREL16_HI,
+ BFD_RELOC_PPC_GOT_DTPREL16_HA,
+ BFD_RELOC_PPC64_TPREL16_DS,
+ BFD_RELOC_PPC64_TPREL16_LO_DS,
+ BFD_RELOC_PPC64_TPREL16_HIGHER,
+ BFD_RELOC_PPC64_TPREL16_HIGHERA,
+ BFD_RELOC_PPC64_TPREL16_HIGHEST,
+ BFD_RELOC_PPC64_TPREL16_HIGHESTA,
+ BFD_RELOC_PPC64_DTPREL16_DS,
+ BFD_RELOC_PPC64_DTPREL16_LO_DS,
+ BFD_RELOC_PPC64_DTPREL16_HIGHER,
+ BFD_RELOC_PPC64_DTPREL16_HIGHERA,
+ BFD_RELOC_PPC64_DTPREL16_HIGHEST,
+ BFD_RELOC_PPC64_DTPREL16_HIGHESTA,
+
/* IBM 370/390 relocations */
BFD_RELOC_I370_D12,
-/* The type of reloc used to build a contructor table - at the moment
+/* The type of reloc used to build a constructor table - at the moment
probably a 32 bit wide absolute relocation, but the target can choose.
It generally does map to one of the other relocation types. */
BFD_RELOC_CTOR,
@@ -2390,6 +2554,7 @@ field in the instruction. */
BFD_RELOC_ARM_SWI,
BFD_RELOC_ARM_MULTI,
BFD_RELOC_ARM_CP_OFF_IMM,
+ BFD_RELOC_ARM_CP_OFF_IMM_S2,
BFD_RELOC_ARM_ADR_IMM,
BFD_RELOC_ARM_LDR_IMM,
BFD_RELOC_ARM_LITERAL,
@@ -2410,7 +2575,7 @@ field in the instruction. */
BFD_RELOC_ARM_GOTOFF,
BFD_RELOC_ARM_GOTPC,
-/* Hitachi SH relocs. Not all of these appear in object files. */
+/* Renesas / SuperH SH relocs. Not all of these appear in object files. */
BFD_RELOC_SH_PCDISP8BY2,
BFD_RELOC_SH_PCDISP12BY2,
BFD_RELOC_SH_IMM4,
@@ -2485,6 +2650,14 @@ field in the instruction. */
BFD_RELOC_SH_IMM_HI16,
BFD_RELOC_SH_IMM_HI16_PCREL,
BFD_RELOC_SH_PT_16,
+ BFD_RELOC_SH_TLS_GD_32,
+ BFD_RELOC_SH_TLS_LD_32,
+ BFD_RELOC_SH_TLS_LDO_32,
+ BFD_RELOC_SH_TLS_IE_32,
+ BFD_RELOC_SH_TLS_LE_32,
+ BFD_RELOC_SH_TLS_DTPMOD32,
+ BFD_RELOC_SH_TLS_DTPOFF32,
+ BFD_RELOC_SH_TLS_TPOFF32,
/* Thumb 23-, 12- and 9-bit pc-relative branches. The lowest bit must
be zero and is not stored in the instruction. */
@@ -2580,7 +2753,7 @@ of the container. */
/* DLX relocs */
BFD_RELOC_DLX_JMP26,
-/* Mitsubishi M32R relocs.
+/* Renesas M32R (formerly Mitsubishi M32R) relocs.
This is a 24 bit absolute address. */
BFD_RELOC_M32R_24,
@@ -2608,6 +2781,22 @@ used when the lower 16 bits are treated as signed. */
add3, load, and store instructions. */
BFD_RELOC_M32R_SDA16,
+/* For PIC. */
+ BFD_RELOC_M32R_GOT24,
+ BFD_RELOC_M32R_26_PLTREL,
+ BFD_RELOC_M32R_COPY,
+ BFD_RELOC_M32R_GLOB_DAT,
+ BFD_RELOC_M32R_JMP_SLOT,
+ BFD_RELOC_M32R_RELATIVE,
+ BFD_RELOC_M32R_GOTOFF,
+ BFD_RELOC_M32R_GOTPC24,
+ BFD_RELOC_M32R_GOT16_HI_ULO,
+ BFD_RELOC_M32R_GOT16_HI_SLO,
+ BFD_RELOC_M32R_GOT16_LO,
+ BFD_RELOC_M32R_GOTPC_HI_ULO,
+ BFD_RELOC_M32R_GOTPC_HI_SLO,
+ BFD_RELOC_M32R_GOTPC_LO,
+
/* This is a 9-bit reloc */
BFD_RELOC_V850_9_PCREL,
@@ -2650,11 +2839,11 @@ data area pointer. */
BFD_RELOC_V850_TDA_4_4_OFFSET,
/* This is a 16 bit offset from the short data area pointer, with the
-bits placed non-contigously in the instruction. */
+bits placed non-contiguously in the instruction. */
BFD_RELOC_V850_SDA_16_16_SPLIT_OFFSET,
/* This is a 16 bit offset from the zero data area pointer, with the
-bits placed non-contigously in the instruction. */
+bits placed non-contiguously in the instruction. */
BFD_RELOC_V850_ZDA_16_16_SPLIT_OFFSET,
/* This is a 6 bit offset from the call table base pointer. */
@@ -2663,6 +2852,14 @@ bits placed non-contigously in the instruction. */
/* This is a 16 bit offset from the call table base pointer. */
BFD_RELOC_V850_CALLT_16_16_OFFSET,
+/* Used for relaxing indirect function calls. */
+ BFD_RELOC_V850_LONGCALL,
+
+/* Used for relaxing indirect jumps. */
+ BFD_RELOC_V850_LONGJUMP,
+
+/* Used to maintain alignment whilst relaxing. */
+ BFD_RELOC_V850_ALIGN,
/* This is a 32bit pcrel reloc for the mn10300, offset by two bytes in the
instruction. */
@@ -2757,6 +2954,7 @@ short offset into 11 bits. */
BFD_RELOC_MMIX_PUSHJ_1,
BFD_RELOC_MMIX_PUSHJ_2,
BFD_RELOC_MMIX_PUSHJ_3,
+ BFD_RELOC_MMIX_PUSHJ_STUBBABLE,
/* These are relocations for the JMP instruction. */
BFD_RELOC_MMIX_JMP,
@@ -2906,6 +3104,95 @@ into 22 bits. */
/* 32 bit rel. offset to GOT entry. */
BFD_RELOC_390_GOTENT,
+/* 64 bit offset to GOT. */
+ BFD_RELOC_390_GOTOFF64,
+
+/* 12-bit offset to symbol-entry within GOT, with PLT handling. */
+ BFD_RELOC_390_GOTPLT12,
+
+/* 16-bit offset to symbol-entry within GOT, with PLT handling. */
+ BFD_RELOC_390_GOTPLT16,
+
+/* 32-bit offset to symbol-entry within GOT, with PLT handling. */
+ BFD_RELOC_390_GOTPLT32,
+
+/* 64-bit offset to symbol-entry within GOT, with PLT handling. */
+ BFD_RELOC_390_GOTPLT64,
+
+/* 32-bit rel. offset to symbol-entry within GOT, with PLT handling. */
+ BFD_RELOC_390_GOTPLTENT,
+
+/* 16-bit rel. offset from the GOT to a PLT entry. */
+ BFD_RELOC_390_PLTOFF16,
+
+/* 32-bit rel. offset from the GOT to a PLT entry. */
+ BFD_RELOC_390_PLTOFF32,
+
+/* 64-bit rel. offset from the GOT to a PLT entry. */
+ BFD_RELOC_390_PLTOFF64,
+
+/* s390 tls relocations. */
+ BFD_RELOC_390_TLS_LOAD,
+ BFD_RELOC_390_TLS_GDCALL,
+ BFD_RELOC_390_TLS_LDCALL,
+ BFD_RELOC_390_TLS_GD32,
+ BFD_RELOC_390_TLS_GD64,
+ BFD_RELOC_390_TLS_GOTIE12,
+ BFD_RELOC_390_TLS_GOTIE32,
+ BFD_RELOC_390_TLS_GOTIE64,
+ BFD_RELOC_390_TLS_LDM32,
+ BFD_RELOC_390_TLS_LDM64,
+ BFD_RELOC_390_TLS_IE32,
+ BFD_RELOC_390_TLS_IE64,
+ BFD_RELOC_390_TLS_IEENT,
+ BFD_RELOC_390_TLS_LE32,
+ BFD_RELOC_390_TLS_LE64,
+ BFD_RELOC_390_TLS_LDO32,
+ BFD_RELOC_390_TLS_LDO64,
+ BFD_RELOC_390_TLS_DTPMOD,
+ BFD_RELOC_390_TLS_DTPOFF,
+ BFD_RELOC_390_TLS_TPOFF,
+
+/* Long displacement extension. */
+ BFD_RELOC_390_20,
+ BFD_RELOC_390_GOT20,
+ BFD_RELOC_390_GOTPLT20,
+ BFD_RELOC_390_TLS_GOTIE20,
+
+/* Scenix IP2K - 9-bit register number / data address */
+ BFD_RELOC_IP2K_FR9,
+
+/* Scenix IP2K - 4-bit register/data bank number */
+ BFD_RELOC_IP2K_BANK,
+
+/* Scenix IP2K - low 13 bits of instruction word address */
+ BFD_RELOC_IP2K_ADDR16CJP,
+
+/* Scenix IP2K - high 3 bits of instruction word address */
+ BFD_RELOC_IP2K_PAGE3,
+
+/* Scenix IP2K - ext/low/high 8 bits of data address */
+ BFD_RELOC_IP2K_LO8DATA,
+ BFD_RELOC_IP2K_HI8DATA,
+ BFD_RELOC_IP2K_EX8DATA,
+
+/* Scenix IP2K - low/high 8 bits of instruction word address */
+ BFD_RELOC_IP2K_LO8INSN,
+ BFD_RELOC_IP2K_HI8INSN,
+
+/* Scenix IP2K - even/odd PC modifier to modify snb pcl.0 */
+ BFD_RELOC_IP2K_PC_SKIP,
+
+/* Scenix IP2K - 16 bit word address in text section. */
+ BFD_RELOC_IP2K_TEXT,
+
+/* Scenix IP2K - 7-bit sp or dp offset */
+ BFD_RELOC_IP2K_FR_OFFSET,
+
+/* Scenix VPE4K coprocessor - data/insn-space addressing */
+ BFD_RELOC_VPE4KMATH_DATA,
+ BFD_RELOC_VPE4KMATH_INSN,
+
/* These two relocations are used by the linker to determine which of
the entries in a C++ virtual function table are actually used. When
the --gc-sections option is given, the linker will zero out the entries
@@ -2913,7 +3200,7 @@ that are not used, so that the code for those functions need not be
included in the output.
VTABLE_INHERIT is a zero-space relocation used to describe to the
-linker the inheritence tree of a C++ virtual function table. The
+linker the inheritance tree of a C++ virtual function table. The
relocation's symbol should be the parent class' vtable, and the
relocation should be located at the child vtable.
@@ -3008,17 +3295,52 @@ this offset in the reloc's section offset. */
BFD_RELOC_IA64_LTOFF_DTPREL22,
/* Motorola 68HC11 reloc.
-This is the 8 bits high part of an absolute address. */
+This is the 8 bit high part of an absolute address. */
BFD_RELOC_M68HC11_HI8,
/* Motorola 68HC11 reloc.
-This is the 8 bits low part of an absolute address. */
+This is the 8 bit low part of an absolute address. */
BFD_RELOC_M68HC11_LO8,
/* Motorola 68HC11 reloc.
-This is the 3 bits of a value. */
+This is the 3 bit of a value. */
BFD_RELOC_M68HC11_3B,
+/* Motorola 68HC11 reloc.
+This reloc marks the beginning of a jump/call instruction.
+It is used for linker relaxation to correctly identify beginning
+of instruction and change some branches to use PC-relative
+addressing mode. */
+ BFD_RELOC_M68HC11_RL_JUMP,
+
+/* Motorola 68HC11 reloc.
+This reloc marks a group of several instructions that gcc generates
+and for which the linker relaxation pass can modify and/or remove
+some of them. */
+ BFD_RELOC_M68HC11_RL_GROUP,
+
+/* Motorola 68HC11 reloc.
+This is the 16-bit lower part of an address. It is used for 'call'
+instruction to specify the symbol address without any special
+transformation (due to memory bank window). */
+ BFD_RELOC_M68HC11_LO16,
+
+/* Motorola 68HC11 reloc.
+This is a 8-bit reloc that specifies the page number of an address.
+It is used by 'call' instruction to specify the page number of
+the symbol. */
+ BFD_RELOC_M68HC11_PAGE,
+
+/* Motorola 68HC11 reloc.
+This is a 24-bit reloc that represents the address with a 16-bit
+value and a 8-bit page number. The symbol address is transformed
+to follow the 16K memory bank of 68HC12 (seen as mapped in the window). */
+ BFD_RELOC_M68HC11_24,
+
+/* Motorola 68HC12 reloc.
+This is the 5 bits of a value. */
+ BFD_RELOC_M68HC12_5B,
+
/* These relocs are only used within the CRIS assembler. They are not
(at present) written to any object files. */
BFD_RELOC_CRIS_BDISP8,
@@ -3101,6 +3423,7 @@ This is the 3 bits of a value. */
/* Sony Xstormy16 Relocations. */
BFD_RELOC_XSTORMY16_REL_12,
+ BFD_RELOC_XSTORMY16_12,
BFD_RELOC_XSTORMY16_24,
BFD_RELOC_XSTORMY16_FPTR16,
@@ -3108,17 +3431,60 @@ This is the 3 bits of a value. */
BFD_RELOC_VAX_GLOB_DAT,
BFD_RELOC_VAX_JMP_SLOT,
BFD_RELOC_VAX_RELATIVE,
+
+/* msp430 specific relocation codes */
+ BFD_RELOC_MSP430_10_PCREL,
+ BFD_RELOC_MSP430_16_PCREL,
+ BFD_RELOC_MSP430_16,
+ BFD_RELOC_MSP430_16_PCREL_BYTE,
+ BFD_RELOC_MSP430_16_BYTE,
+
+/* IQ2000 Relocations. */
+ BFD_RELOC_IQ2000_OFFSET_16,
+ BFD_RELOC_IQ2000_OFFSET_21,
+ BFD_RELOC_IQ2000_UHI16,
+
+/* Special Xtensa relocation used only by PLT entries in ELF shared
+objects to indicate that the runtime linker should set the value
+to one of its own internal functions or data structures. */
+ BFD_RELOC_XTENSA_RTLD,
+
+/* Xtensa relocations for ELF shared objects. */
+ BFD_RELOC_XTENSA_GLOB_DAT,
+ BFD_RELOC_XTENSA_JMP_SLOT,
+ BFD_RELOC_XTENSA_RELATIVE,
+
+/* Xtensa relocation used in ELF object files for symbols that may require
+PLT entries. Otherwise, this is just a generic 32-bit relocation. */
+ BFD_RELOC_XTENSA_PLT,
+
+/* Generic Xtensa relocations. Only the operand number is encoded
+in the relocation. The details are determined by extracting the
+instruction opcode. */
+ BFD_RELOC_XTENSA_OP0,
+ BFD_RELOC_XTENSA_OP1,
+ BFD_RELOC_XTENSA_OP2,
+
+/* Xtensa relocation to mark that the assembler expanded the
+instructions from an original target. The expansion size is
+encoded in the reloc size. */
+ BFD_RELOC_XTENSA_ASM_EXPAND,
+
+/* Xtensa relocation to mark that the linker should simplify
+assembler-expanded instructions. This is commonly used
+internally by the linker after analysis of a
+BFD_RELOC_XTENSA_ASM_EXPAND. */
+ BFD_RELOC_XTENSA_ASM_SIMPLIFY,
BFD_RELOC_UNUSED };
typedef enum bfd_reloc_code_real bfd_reloc_code_real_type;
-reloc_howto_type *
-bfd_reloc_type_lookup PARAMS ((bfd *abfd, bfd_reloc_code_real_type code));
+reloc_howto_type *bfd_reloc_type_lookup
+ (bfd *abfd, bfd_reloc_code_real_type code);
-const char *
-bfd_get_reloc_code_name PARAMS ((bfd_reloc_code_real_type code));
+const char *bfd_get_reloc_code_name (bfd_reloc_code_real_type code);
/* Extracted from syms.c. */
-typedef struct symbol_cache_entry
+typedef struct bfd_symbol
{
/* A pointer to the BFD which owns the symbol. This information
is necessary so that a back end can work out what additional
@@ -3129,7 +3495,7 @@ typedef struct symbol_cache_entry
instead, except that some symbols point to the global sections
bfd_{abs,com,und}_section. This could be fixed by making
these globals be per-bfd (or per-target-flavor). FIXME. */
- struct _bfd *the_bfd; /* Use bfd_asymbol_bfd(sym) to access this field. */
+ struct bfd *the_bfd; /* Use bfd_asymbol_bfd(sym) to access this field. */
/* The text of the symbol. The name is left alone, and not copied; the
application may not alter it. */
@@ -3159,7 +3525,7 @@ typedef struct symbol_cache_entry
<<BSF_LOCAL>>, <<BSF_FORT_COMM>>, <<BSF_UNDEFINED>> or
<<BSF_GLOBAL>>. */
- /* The symbol is a debugging record. The value has an arbitary
+ /* The symbol is a debugging record. The value has an arbitrary
meaning, unless BSF_DEBUGGING_RELOC is also set. */
#define BSF_DEBUGGING 0x08
@@ -3230,12 +3596,12 @@ typedef struct symbol_cache_entry
/* A pointer to the section to which this symbol is
relative. This will always be non NULL, there are special
sections for undefined and absolute symbols. */
- struct sec *section;
+ struct bfd_section *section;
/* Back end special data. */
union
{
- PTR p;
+ void *p;
bfd_vma i;
}
udata;
@@ -3245,53 +3611,48 @@ asymbol;
#define bfd_get_symtab_upper_bound(abfd) \
BFD_SEND (abfd, _bfd_get_symtab_upper_bound, (abfd))
-boolean
-bfd_is_local_label PARAMS ((bfd *abfd, asymbol *sym));
+bfd_boolean bfd_is_local_label (bfd *abfd, asymbol *sym);
-boolean
-bfd_is_local_label_name PARAMS ((bfd *abfd, const char *name));
+bfd_boolean bfd_is_local_label_name (bfd *abfd, const char *name);
#define bfd_is_local_label_name(abfd, name) \
- BFD_SEND (abfd, _bfd_is_local_label_name, (abfd, name))
+ BFD_SEND (abfd, _bfd_is_local_label_name, (abfd, name))
#define bfd_canonicalize_symtab(abfd, location) \
- BFD_SEND (abfd, _bfd_canonicalize_symtab,\
- (abfd, location))
+ BFD_SEND (abfd, _bfd_canonicalize_symtab, (abfd, location))
-boolean
-bfd_set_symtab PARAMS ((bfd *abfd, asymbol **location, unsigned int count));
+bfd_boolean bfd_set_symtab
+ (bfd *abfd, asymbol **location, unsigned int count);
-void
-bfd_print_symbol_vandf PARAMS ((bfd *abfd, PTR file, asymbol *symbol));
+void bfd_print_symbol_vandf (bfd *abfd, void *file, asymbol *symbol);
#define bfd_make_empty_symbol(abfd) \
- BFD_SEND (abfd, _bfd_make_empty_symbol, (abfd))
+ BFD_SEND (abfd, _bfd_make_empty_symbol, (abfd))
-asymbol *
-_bfd_generic_make_empty_symbol PARAMS ((bfd *));
+asymbol *_bfd_generic_make_empty_symbol (bfd *);
#define bfd_make_debug_symbol(abfd,ptr,size) \
- BFD_SEND (abfd, _bfd_make_debug_symbol, (abfd, ptr, size))
+ BFD_SEND (abfd, _bfd_make_debug_symbol, (abfd, ptr, size))
-int
-bfd_decode_symclass PARAMS ((asymbol *symbol));
+int bfd_decode_symclass (asymbol *symbol);
-boolean
-bfd_is_undefined_symclass PARAMS ((int symclass));
+bfd_boolean bfd_is_undefined_symclass (int symclass);
-void
-bfd_symbol_info PARAMS ((asymbol *symbol, symbol_info *ret));
+void bfd_symbol_info (asymbol *symbol, symbol_info *ret);
-boolean
-bfd_copy_private_symbol_data PARAMS ((bfd *ibfd, asymbol *isym, bfd *obfd, asymbol *osym));
+bfd_boolean bfd_copy_private_symbol_data
+ (bfd *ibfd, asymbol *isym, bfd *obfd, asymbol *osym);
#define bfd_copy_private_symbol_data(ibfd, isymbol, obfd, osymbol) \
- BFD_SEND (obfd, _bfd_copy_private_symbol_data, \
- (ibfd, isymbol, obfd, osymbol))
+ BFD_SEND (obfd, _bfd_copy_private_symbol_data, \
+ (ibfd, isymbol, obfd, osymbol))
/* Extracted from bfd.c. */
-struct _bfd
+struct bfd
{
+ /* A unique identifier of the BFD */
+ unsigned int id;
+
/* The filename the application opened the BFD with. */
const char *filename;
@@ -3305,33 +3666,33 @@ struct _bfd
is the result of an fopen on the filename. However, if the
BFD_IN_MEMORY flag is set, then iostream is actually a pointer
to a bfd_in_memory struct. */
- PTR iostream;
+ void *iostream;
/* Is the file descriptor being cached? That is, can it be closed as
needed, and re-opened when accessed later? */
- boolean cacheable;
+ bfd_boolean cacheable;
/* Marks whether there was a default target specified when the
BFD was opened. This is used to select which matching algorithm
to use to choose the back end. */
- boolean target_defaulted;
+ bfd_boolean target_defaulted;
/* The caching routines use these to maintain a
least-recently-used list of BFDs. */
- struct _bfd *lru_prev, *lru_next;
+ struct bfd *lru_prev, *lru_next;
/* When a file is closed by the caching routines, BFD retains
state information on the file here... */
ufile_ptr where;
/* ... and here: (``once'' means at least once). */
- boolean opened_once;
+ bfd_boolean opened_once;
/* Set if we have a locally maintained mtime value, rather than
getting it from the file each time. */
- boolean mtime_set;
+ bfd_boolean mtime_set;
- /* File modified time, if mtime_set is true. */
+ /* File modified time, if mtime_set is TRUE. */
long mtime;
/* Reserved for an unimplemented file locking extension. */
@@ -3360,16 +3721,16 @@ struct _bfd
/* Remember when output has begun, to stop strange things
from happening. */
- boolean output_has_begun;
+ bfd_boolean output_has_begun;
/* A hash table for section names. */
struct bfd_hash_table section_htab;
/* Pointer to linked list of sections. */
- struct sec *sections;
+ struct bfd_section *sections;
/* The place where we add to the section list. */
- struct sec **section_tail;
+ struct bfd_section **section_tail;
/* The number of sections. */
unsigned int section_count;
@@ -3382,7 +3743,7 @@ struct _bfd
unsigned int symcount;
/* Symbol table for output BFD (with symcount entries). */
- struct symbol_cache_entry **outsymbols;
+ struct bfd_symbol **outsymbols;
/* Used for slurped dynamic symbol tables. */
unsigned int dynsymcount;
@@ -3391,14 +3752,14 @@ struct _bfd
const struct bfd_arch_info *arch_info;
/* Stuff only useful for archives. */
- PTR arelt_data;
- struct _bfd *my_archive; /* The containing archive BFD. */
- struct _bfd *next; /* The next BFD in the archive. */
- struct _bfd *archive_head; /* The first BFD in the archive. */
- boolean has_armap;
+ void *arelt_data;
+ struct bfd *my_archive; /* The containing archive BFD. */
+ struct bfd *next; /* The next BFD in the archive. */
+ struct bfd *archive_head; /* The first BFD in the archive. */
+ bfd_boolean has_armap;
/* A chain of BFD structures involved in a link. */
- struct _bfd *link_next;
+ struct bfd *link_next;
/* A field used by _bfd_generic_link_add_archive_symbols. This will
be used only for archive elements. */
@@ -3436,17 +3797,22 @@ struct _bfd
struct cisco_core_struct *cisco_core_data;
struct versados_data_struct *versados_data;
struct netbsd_core_struct *netbsd_core_data;
- PTR any;
+ struct mach_o_data_struct *mach_o_data;
+ struct mach_o_fat_data_struct *mach_o_fat_data;
+ struct bfd_pef_data_struct *pef_data;
+ struct bfd_pef_xlib_data_struct *pef_xlib_data;
+ struct bfd_sym_data_struct *sym_data;
+ void *any;
}
tdata;
/* Used by the application to hold private data. */
- PTR usrdata;
+ void *usrdata;
/* Where all the allocated stuff under this BFD goes. This is a
- struct objalloc *, but we use PTR to avoid requiring the inclusion of
- objalloc.h. */
- PTR memory;
+ struct objalloc *, but we use void * to avoid requiring the inclusion
+ of objalloc.h. */
+ void *memory;
};
typedef enum bfd_error
@@ -3474,114 +3840,84 @@ typedef enum bfd_error
}
bfd_error_type;
-bfd_error_type
-bfd_get_error PARAMS ((void));
-
-void
-bfd_set_error PARAMS ((bfd_error_type error_tag));
-
-const char *
-bfd_errmsg PARAMS ((bfd_error_type error_tag));
+bfd_error_type bfd_get_error (void);
-void
-bfd_perror PARAMS ((const char *message));
+void bfd_set_error (bfd_error_type error_tag);
-typedef void (*bfd_error_handler_type) PARAMS ((const char *, ...));
+const char *bfd_errmsg (bfd_error_type error_tag);
-bfd_error_handler_type
-bfd_set_error_handler PARAMS ((bfd_error_handler_type));
+void bfd_perror (const char *message);
-void
-bfd_set_error_program_name PARAMS ((const char *));
+typedef void (*bfd_error_handler_type) (const char *, ...);
-bfd_error_handler_type
-bfd_get_error_handler PARAMS ((void));
+bfd_error_handler_type bfd_set_error_handler (bfd_error_handler_type);
-const char *
-bfd_archive_filename PARAMS ((bfd *));
+void bfd_set_error_program_name (const char *);
-long
-bfd_get_reloc_upper_bound PARAMS ((bfd *abfd, asection *sect));
+bfd_error_handler_type bfd_get_error_handler (void);
-long
-bfd_canonicalize_reloc PARAMS ((bfd *abfd,
- asection *sec,
- arelent **loc,
- asymbol **syms));
+const char *bfd_archive_filename (bfd *);
-void
-bfd_set_reloc PARAMS ((bfd *abfd, asection *sec, arelent **rel, unsigned int count));
+long bfd_get_reloc_upper_bound (bfd *abfd, asection *sect);
-boolean
-bfd_set_file_flags PARAMS ((bfd *abfd, flagword flags));
+long bfd_canonicalize_reloc
+ (bfd *abfd, asection *sec, arelent **loc, asymbol **syms);
-int
-bfd_get_arch_size PARAMS ((bfd *abfd));
+void bfd_set_reloc
+ (bfd *abfd, asection *sec, arelent **rel, unsigned int count);
-int
-bfd_get_sign_extend_vma PARAMS ((bfd *abfd));
+bfd_boolean bfd_set_file_flags (bfd *abfd, flagword flags);
-boolean
-bfd_set_start_address PARAMS ((bfd *abfd, bfd_vma vma));
+int bfd_get_arch_size (bfd *abfd);
-long
-bfd_get_mtime PARAMS ((bfd *abfd));
+int bfd_get_sign_extend_vma (bfd *abfd);
-long
-bfd_get_size PARAMS ((bfd *abfd));
+bfd_boolean bfd_set_start_address (bfd *abfd, bfd_vma vma);
-unsigned int
-bfd_get_gp_size PARAMS ((bfd *abfd));
+unsigned int bfd_get_gp_size (bfd *abfd);
-void
-bfd_set_gp_size PARAMS ((bfd *abfd, unsigned int i));
+void bfd_set_gp_size (bfd *abfd, unsigned int i);
-bfd_vma
-bfd_scan_vma PARAMS ((const char *string, const char **end, int base));
+bfd_vma bfd_scan_vma (const char *string, const char **end, int base);
-boolean
-bfd_copy_private_bfd_data PARAMS ((bfd *ibfd, bfd *obfd));
+bfd_boolean bfd_copy_private_bfd_data (bfd *ibfd, bfd *obfd);
#define bfd_copy_private_bfd_data(ibfd, obfd) \
BFD_SEND (obfd, _bfd_copy_private_bfd_data, \
(ibfd, obfd))
-boolean
-bfd_merge_private_bfd_data PARAMS ((bfd *ibfd, bfd *obfd));
+bfd_boolean bfd_merge_private_bfd_data (bfd *ibfd, bfd *obfd);
#define bfd_merge_private_bfd_data(ibfd, obfd) \
BFD_SEND (obfd, _bfd_merge_private_bfd_data, \
(ibfd, obfd))
-boolean
-bfd_set_private_flags PARAMS ((bfd *abfd, flagword flags));
+bfd_boolean bfd_set_private_flags (bfd *abfd, flagword flags);
#define bfd_set_private_flags(abfd, flags) \
- BFD_SEND (abfd, _bfd_set_private_flags, \
- (abfd, flags))
+ BFD_SEND (abfd, _bfd_set_private_flags, (abfd, flags))
#define bfd_sizeof_headers(abfd, reloc) \
- BFD_SEND (abfd, _bfd_sizeof_headers, (abfd, reloc))
+ BFD_SEND (abfd, _bfd_sizeof_headers, (abfd, reloc))
#define bfd_find_nearest_line(abfd, sec, syms, off, file, func, line) \
- BFD_SEND (abfd, _bfd_find_nearest_line, (abfd, sec, syms, off, file, func, line))
+ BFD_SEND (abfd, _bfd_find_nearest_line, \
+ (abfd, sec, syms, off, file, func, line))
- /* Do these three do anything useful at all, for any back end? */
#define bfd_debug_info_start(abfd) \
- BFD_SEND (abfd, _bfd_debug_info_start, (abfd))
+ BFD_SEND (abfd, _bfd_debug_info_start, (abfd))
#define bfd_debug_info_end(abfd) \
- BFD_SEND (abfd, _bfd_debug_info_end, (abfd))
+ BFD_SEND (abfd, _bfd_debug_info_end, (abfd))
#define bfd_debug_info_accumulate(abfd, section) \
- BFD_SEND (abfd, _bfd_debug_info_accumulate, (abfd, section))
-
+ BFD_SEND (abfd, _bfd_debug_info_accumulate, (abfd, section))
#define bfd_stat_arch_elt(abfd, stat) \
- BFD_SEND (abfd, _bfd_stat_arch_elt,(abfd, stat))
+ BFD_SEND (abfd, _bfd_stat_arch_elt,(abfd, stat))
#define bfd_update_armap_timestamp(abfd) \
- BFD_SEND (abfd, _bfd_update_armap_timestamp, (abfd))
+ BFD_SEND (abfd, _bfd_update_armap_timestamp, (abfd))
#define bfd_set_arch_mach(abfd, arch, mach)\
- BFD_SEND ( abfd, _bfd_set_arch_mach, (abfd, arch, mach))
+ BFD_SEND ( abfd, _bfd_set_arch_mach, (abfd, arch, mach))
#define bfd_relax_section(abfd, section, link_info, again) \
BFD_SEND (abfd, _bfd_relax_section, (abfd, section, link_info, again))
@@ -3629,36 +3965,48 @@ bfd_set_private_flags PARAMS ((bfd *abfd, flagword flags));
BFD_SEND (abfd, _bfd_canonicalize_dynamic_reloc, (abfd, arels, asyms))
extern bfd_byte *bfd_get_relocated_section_contents
- PARAMS ((bfd *, struct bfd_link_info *,
- struct bfd_link_order *, bfd_byte *,
- boolean, asymbol **));
+ (bfd *, struct bfd_link_info *, struct bfd_link_order *, bfd_byte *,
+ bfd_boolean, asymbol **);
+
+bfd_boolean bfd_alt_mach_code (bfd *abfd, int alternative);
+
+struct bfd_preserve
+{
+ void *marker;
+ void *tdata;
+ flagword flags;
+ const struct bfd_arch_info *arch_info;
+ struct bfd_section *sections;
+ struct bfd_section **section_tail;
+ unsigned int section_count;
+ struct bfd_hash_table section_htab;
+};
+
+bfd_boolean bfd_preserve_save (bfd *, struct bfd_preserve *);
-boolean
-bfd_alt_mach_code PARAMS ((bfd *abfd, int alternative));
+void bfd_preserve_restore (bfd *, struct bfd_preserve *);
+
+void bfd_preserve_finish (bfd *, struct bfd_preserve *);
/* Extracted from archive.c. */
-symindex
-bfd_get_next_mapent PARAMS ((bfd *abfd, symindex previous, carsym **sym));
+symindex bfd_get_next_mapent
+ (bfd *abfd, symindex previous, carsym **sym);
-boolean
-bfd_set_archive_head PARAMS ((bfd *output, bfd *new_head));
+bfd_boolean bfd_set_archive_head (bfd *output, bfd *new_head);
-bfd *
-bfd_openr_next_archived_file PARAMS ((bfd *archive, bfd *previous));
+bfd *bfd_openr_next_archived_file (bfd *archive, bfd *previous);
/* Extracted from corefile.c. */
-const char *
-bfd_core_file_failing_command PARAMS ((bfd *abfd));
+const char *bfd_core_file_failing_command (bfd *abfd);
-int
-bfd_core_file_failing_signal PARAMS ((bfd *abfd));
+int bfd_core_file_failing_signal (bfd *abfd);
-boolean
-core_file_matches_executable_p PARAMS ((bfd *core_bfd, bfd *exec_bfd));
+bfd_boolean core_file_matches_executable_p
+ (bfd *core_bfd, bfd *exec_bfd);
/* Extracted from targets.c. */
#define BFD_SEND(bfd, message, arglist) \
- ((*((bfd)->xvec->message)) arglist)
+ ((*((bfd)->xvec->message)) arglist)
#ifdef DEBUG_BFD_SEND
#undef BFD_SEND
@@ -3668,7 +4016,7 @@ core_file_matches_executable_p PARAMS ((bfd *core_bfd, bfd *exec_bfd));
(bfd_assert (__FILE__,__LINE__), NULL))
#endif
#define BFD_SEND_FMT(bfd, message, arglist) \
- (((bfd)->xvec->message[(int) ((bfd)->format)]) arglist)
+ (((bfd)->xvec->message[(int) ((bfd)->format)]) arglist)
#ifdef DEBUG_BFD_SEND
#undef BFD_SEND_FMT
@@ -3698,7 +4046,11 @@ enum bfd_flavour
bfd_target_msdos_flavour,
bfd_target_ovax_flavour,
bfd_target_evax_flavour,
- bfd_target_mmo_flavour
+ bfd_target_mmo_flavour,
+ bfd_target_mach_o_flavour,
+ bfd_target_pef_flavour,
+ bfd_target_pef_xlib_flavour,
+ bfd_target_sym_flavour
};
enum bfd_endian { BFD_ENDIAN_BIG, BFD_ENDIAN_LITTLE, BFD_ENDIAN_UNKNOWN };
@@ -3742,291 +4094,303 @@ typedef struct bfd_target
/* Entries for byte swapping for data. These are different from the
other entry points, since they don't take a BFD asthe first argument.
Certain other handlers could do the same. */
- bfd_vma (*bfd_getx64) PARAMS ((const bfd_byte *));
- bfd_signed_vma (*bfd_getx_signed_64) PARAMS ((const bfd_byte *));
- void (*bfd_putx64) PARAMS ((bfd_vma, bfd_byte *));
- bfd_vma (*bfd_getx32) PARAMS ((const bfd_byte *));
- bfd_signed_vma (*bfd_getx_signed_32) PARAMS ((const bfd_byte *));
- void (*bfd_putx32) PARAMS ((bfd_vma, bfd_byte *));
- bfd_vma (*bfd_getx16) PARAMS ((const bfd_byte *));
- bfd_signed_vma (*bfd_getx_signed_16) PARAMS ((const bfd_byte *));
- void (*bfd_putx16) PARAMS ((bfd_vma, bfd_byte *));
+ bfd_uint64_t (*bfd_getx64) (const void *);
+ bfd_int64_t (*bfd_getx_signed_64) (const void *);
+ void (*bfd_putx64) (bfd_uint64_t, void *);
+ bfd_vma (*bfd_getx32) (const void *);
+ bfd_signed_vma (*bfd_getx_signed_32) (const void *);
+ void (*bfd_putx32) (bfd_vma, void *);
+ bfd_vma (*bfd_getx16) (const void *);
+ bfd_signed_vma (*bfd_getx_signed_16) (const void *);
+ void (*bfd_putx16) (bfd_vma, void *);
/* Byte swapping for the headers. */
- bfd_vma (*bfd_h_getx64) PARAMS ((const bfd_byte *));
- bfd_signed_vma (*bfd_h_getx_signed_64) PARAMS ((const bfd_byte *));
- void (*bfd_h_putx64) PARAMS ((bfd_vma, bfd_byte *));
- bfd_vma (*bfd_h_getx32) PARAMS ((const bfd_byte *));
- bfd_signed_vma (*bfd_h_getx_signed_32) PARAMS ((const bfd_byte *));
- void (*bfd_h_putx32) PARAMS ((bfd_vma, bfd_byte *));
- bfd_vma (*bfd_h_getx16) PARAMS ((const bfd_byte *));
- bfd_signed_vma (*bfd_h_getx_signed_16) PARAMS ((const bfd_byte *));
- void (*bfd_h_putx16) PARAMS ((bfd_vma, bfd_byte *));
+ bfd_uint64_t (*bfd_h_getx64) (const void *);
+ bfd_int64_t (*bfd_h_getx_signed_64) (const void *);
+ void (*bfd_h_putx64) (bfd_uint64_t, void *);
+ bfd_vma (*bfd_h_getx32) (const void *);
+ bfd_signed_vma (*bfd_h_getx_signed_32) (const void *);
+ void (*bfd_h_putx32) (bfd_vma, void *);
+ bfd_vma (*bfd_h_getx16) (const void *);
+ bfd_signed_vma (*bfd_h_getx_signed_16) (const void *);
+ void (*bfd_h_putx16) (bfd_vma, void *);
/* Format dependent routines: these are vectors of entry points
within the target vector structure, one for each format to check. */
/* Check the format of a file being read. Return a <<bfd_target *>> or zero. */
- const struct bfd_target *(*_bfd_check_format[bfd_type_end]) PARAMS ((bfd *));
+ const struct bfd_target *(*_bfd_check_format[bfd_type_end]) (bfd *);
/* Set the format of a file being written. */
- boolean (*_bfd_set_format[bfd_type_end]) PARAMS ((bfd *));
+ bfd_boolean (*_bfd_set_format[bfd_type_end]) (bfd *);
/* Write cached information into a file being written, at <<bfd_close>>. */
- boolean (*_bfd_write_contents[bfd_type_end]) PARAMS ((bfd *));
+ bfd_boolean (*_bfd_write_contents[bfd_type_end]) (bfd *);
/* Generic entry points. */
#define BFD_JUMP_TABLE_GENERIC(NAME) \
-CONCAT2 (NAME,_close_and_cleanup), \
-CONCAT2 (NAME,_bfd_free_cached_info), \
-CONCAT2 (NAME,_new_section_hook), \
-CONCAT2 (NAME,_get_section_contents), \
-CONCAT2 (NAME,_get_section_contents_in_window)
+ NAME##_close_and_cleanup, \
+ NAME##_bfd_free_cached_info, \
+ NAME##_new_section_hook, \
+ NAME##_get_section_contents, \
+ NAME##_get_section_contents_in_window
/* Called when the BFD is being closed to do any necessary cleanup. */
- boolean (*_close_and_cleanup) PARAMS ((bfd *));
+ bfd_boolean (*_close_and_cleanup) (bfd *);
/* Ask the BFD to free all cached information. */
- boolean (*_bfd_free_cached_info) PARAMS ((bfd *));
+ bfd_boolean (*_bfd_free_cached_info) (bfd *);
/* Called when a new section is created. */
- boolean (*_new_section_hook) PARAMS ((bfd *, sec_ptr));
+ bfd_boolean (*_new_section_hook) (bfd *, sec_ptr);
/* Read the contents of a section. */
- boolean (*_bfd_get_section_contents) PARAMS ((bfd *, sec_ptr, PTR,
- file_ptr, bfd_size_type));
- boolean (*_bfd_get_section_contents_in_window)
- PARAMS ((bfd *, sec_ptr, bfd_window *, file_ptr, bfd_size_type));
+ bfd_boolean (*_bfd_get_section_contents)
+ (bfd *, sec_ptr, void *, file_ptr, bfd_size_type);
+ bfd_boolean (*_bfd_get_section_contents_in_window)
+ (bfd *, sec_ptr, bfd_window *, file_ptr, bfd_size_type);
/* Entry points to copy private data. */
#define BFD_JUMP_TABLE_COPY(NAME) \
-CONCAT2 (NAME,_bfd_copy_private_bfd_data), \
-CONCAT2 (NAME,_bfd_merge_private_bfd_data), \
-CONCAT2 (NAME,_bfd_copy_private_section_data), \
-CONCAT2 (NAME,_bfd_copy_private_symbol_data), \
-CONCAT2 (NAME,_bfd_set_private_flags), \
-CONCAT2 (NAME,_bfd_print_private_bfd_data) \
+ NAME##_bfd_copy_private_bfd_data, \
+ NAME##_bfd_merge_private_bfd_data, \
+ NAME##_bfd_copy_private_section_data, \
+ NAME##_bfd_copy_private_symbol_data, \
+ NAME##_bfd_set_private_flags, \
+ NAME##_bfd_print_private_bfd_data
+
/* Called to copy BFD general private data from one object file
to another. */
- boolean (*_bfd_copy_private_bfd_data) PARAMS ((bfd *, bfd *));
+ bfd_boolean (*_bfd_copy_private_bfd_data) (bfd *, bfd *);
/* Called to merge BFD general private data from one object file
to a common output file when linking. */
- boolean (*_bfd_merge_private_bfd_data) PARAMS ((bfd *, bfd *));
+ bfd_boolean (*_bfd_merge_private_bfd_data) (bfd *, bfd *);
/* Called to copy BFD private section data from one object file
to another. */
- boolean (*_bfd_copy_private_section_data) PARAMS ((bfd *, sec_ptr,
- bfd *, sec_ptr));
+ bfd_boolean (*_bfd_copy_private_section_data)
+ (bfd *, sec_ptr, bfd *, sec_ptr);
/* Called to copy BFD private symbol data from one symbol
to another. */
- boolean (*_bfd_copy_private_symbol_data) PARAMS ((bfd *, asymbol *,
- bfd *, asymbol *));
+ bfd_boolean (*_bfd_copy_private_symbol_data)
+ (bfd *, asymbol *, bfd *, asymbol *);
/* Called to set private backend flags. */
- boolean (*_bfd_set_private_flags) PARAMS ((bfd *, flagword));
+ bfd_boolean (*_bfd_set_private_flags) (bfd *, flagword);
/* Called to print private BFD data. */
- boolean (*_bfd_print_private_bfd_data) PARAMS ((bfd *, PTR));
+ bfd_boolean (*_bfd_print_private_bfd_data) (bfd *, void *);
/* Core file entry points. */
#define BFD_JUMP_TABLE_CORE(NAME) \
-CONCAT2 (NAME,_core_file_failing_command), \
-CONCAT2 (NAME,_core_file_failing_signal), \
-CONCAT2 (NAME,_core_file_matches_executable_p)
- char * (*_core_file_failing_command) PARAMS ((bfd *));
- int (*_core_file_failing_signal) PARAMS ((bfd *));
- boolean (*_core_file_matches_executable_p) PARAMS ((bfd *, bfd *));
+ NAME##_core_file_failing_command, \
+ NAME##_core_file_failing_signal, \
+ NAME##_core_file_matches_executable_p
+
+ char * (*_core_file_failing_command) (bfd *);
+ int (*_core_file_failing_signal) (bfd *);
+ bfd_boolean (*_core_file_matches_executable_p) (bfd *, bfd *);
/* Archive entry points. */
#define BFD_JUMP_TABLE_ARCHIVE(NAME) \
-CONCAT2 (NAME,_slurp_armap), \
-CONCAT2 (NAME,_slurp_extended_name_table), \
-CONCAT2 (NAME,_construct_extended_name_table), \
-CONCAT2 (NAME,_truncate_arname), \
-CONCAT2 (NAME,_write_armap), \
-CONCAT2 (NAME,_read_ar_hdr), \
-CONCAT2 (NAME,_openr_next_archived_file), \
-CONCAT2 (NAME,_get_elt_at_index), \
-CONCAT2 (NAME,_generic_stat_arch_elt), \
-CONCAT2 (NAME,_update_armap_timestamp)
- boolean (*_bfd_slurp_armap) PARAMS ((bfd *));
- boolean (*_bfd_slurp_extended_name_table) PARAMS ((bfd *));
- boolean (*_bfd_construct_extended_name_table)
- PARAMS ((bfd *, char **, bfd_size_type *, const char **));
- void (*_bfd_truncate_arname) PARAMS ((bfd *, const char *, char *));
- boolean (*write_armap)
- PARAMS ((bfd *, unsigned int, struct orl *, unsigned int, int));
- PTR (*_bfd_read_ar_hdr_fn) PARAMS ((bfd *));
- bfd * (*openr_next_archived_file) PARAMS ((bfd *, bfd *));
-#define bfd_get_elt_at_index(b,i) BFD_SEND(b, _bfd_get_elt_at_index, (b,i))
- bfd * (*_bfd_get_elt_at_index) PARAMS ((bfd *, symindex));
- int (*_bfd_stat_arch_elt) PARAMS ((bfd *, struct stat *));
- boolean (*_bfd_update_armap_timestamp) PARAMS ((bfd *));
+ NAME##_slurp_armap, \
+ NAME##_slurp_extended_name_table, \
+ NAME##_construct_extended_name_table, \
+ NAME##_truncate_arname, \
+ NAME##_write_armap, \
+ NAME##_read_ar_hdr, \
+ NAME##_openr_next_archived_file, \
+ NAME##_get_elt_at_index, \
+ NAME##_generic_stat_arch_elt, \
+ NAME##_update_armap_timestamp
+
+ bfd_boolean (*_bfd_slurp_armap) (bfd *);
+ bfd_boolean (*_bfd_slurp_extended_name_table) (bfd *);
+ bfd_boolean (*_bfd_construct_extended_name_table)
+ (bfd *, char **, bfd_size_type *, const char **);
+ void (*_bfd_truncate_arname) (bfd *, const char *, char *);
+ bfd_boolean (*write_armap)
+ (bfd *, unsigned int, struct orl *, unsigned int, int);
+ void * (*_bfd_read_ar_hdr_fn) (bfd *);
+ bfd * (*openr_next_archived_file) (bfd *, bfd *);
+#define bfd_get_elt_at_index(b,i) BFD_SEND (b, _bfd_get_elt_at_index, (b,i))
+ bfd * (*_bfd_get_elt_at_index) (bfd *, symindex);
+ int (*_bfd_stat_arch_elt) (bfd *, struct stat *);
+ bfd_boolean (*_bfd_update_armap_timestamp) (bfd *);
/* Entry points used for symbols. */
#define BFD_JUMP_TABLE_SYMBOLS(NAME) \
-CONCAT2 (NAME,_get_symtab_upper_bound), \
-CONCAT2 (NAME,_get_symtab), \
-CONCAT2 (NAME,_make_empty_symbol), \
-CONCAT2 (NAME,_print_symbol), \
-CONCAT2 (NAME,_get_symbol_info), \
-CONCAT2 (NAME,_bfd_is_local_label_name), \
-CONCAT2 (NAME,_get_lineno), \
-CONCAT2 (NAME,_find_nearest_line), \
-CONCAT2 (NAME,_bfd_make_debug_symbol), \
-CONCAT2 (NAME,_read_minisymbols), \
-CONCAT2 (NAME,_minisymbol_to_symbol)
- long (*_bfd_get_symtab_upper_bound) PARAMS ((bfd *));
- long (*_bfd_canonicalize_symtab) PARAMS ((bfd *,
- struct symbol_cache_entry **));
- struct symbol_cache_entry *
- (*_bfd_make_empty_symbol) PARAMS ((bfd *));
- void (*_bfd_print_symbol) PARAMS ((bfd *, PTR,
- struct symbol_cache_entry *,
- bfd_print_symbol_type));
-#define bfd_print_symbol(b,p,s,e) BFD_SEND(b, _bfd_print_symbol, (b,p,s,e))
- void (*_bfd_get_symbol_info) PARAMS ((bfd *,
- struct symbol_cache_entry *,
- symbol_info *));
-#define bfd_get_symbol_info(b,p,e) BFD_SEND(b, _bfd_get_symbol_info, (b,p,e))
- boolean (*_bfd_is_local_label_name) PARAMS ((bfd *, const char *));
-
- alent * (*_get_lineno) PARAMS ((bfd *, struct symbol_cache_entry *));
- boolean (*_bfd_find_nearest_line)
- PARAMS ((bfd *, struct sec *, struct symbol_cache_entry **, bfd_vma,
- const char **, const char **, unsigned int *));
+ NAME##_get_symtab_upper_bound, \
+ NAME##_canonicalize_symtab, \
+ NAME##_make_empty_symbol, \
+ NAME##_print_symbol, \
+ NAME##_get_symbol_info, \
+ NAME##_bfd_is_local_label_name, \
+ NAME##_get_lineno, \
+ NAME##_find_nearest_line, \
+ NAME##_bfd_make_debug_symbol, \
+ NAME##_read_minisymbols, \
+ NAME##_minisymbol_to_symbol
+
+ long (*_bfd_get_symtab_upper_bound) (bfd *);
+ long (*_bfd_canonicalize_symtab)
+ (bfd *, struct bfd_symbol **);
+ struct bfd_symbol *
+ (*_bfd_make_empty_symbol) (bfd *);
+ void (*_bfd_print_symbol)
+ (bfd *, void *, struct bfd_symbol *, bfd_print_symbol_type);
+#define bfd_print_symbol(b,p,s,e) BFD_SEND (b, _bfd_print_symbol, (b,p,s,e))
+ void (*_bfd_get_symbol_info)
+ (bfd *, struct bfd_symbol *, symbol_info *);
+#define bfd_get_symbol_info(b,p,e) BFD_SEND (b, _bfd_get_symbol_info, (b,p,e))
+ bfd_boolean (*_bfd_is_local_label_name) (bfd *, const char *);
+
+ alent * (*_get_lineno) (bfd *, struct bfd_symbol *);
+ bfd_boolean (*_bfd_find_nearest_line)
+ (bfd *, struct bfd_section *, struct bfd_symbol **, bfd_vma,
+ const char **, const char **, unsigned int *);
/* Back-door to allow format-aware applications to create debug symbols
while using BFD for everything else. Currently used by the assembler
when creating COFF files. */
- asymbol *(*_bfd_make_debug_symbol) PARAMS ((bfd *, void *,
- unsigned long size));
+ asymbol * (*_bfd_make_debug_symbol)
+ (bfd *, void *, unsigned long size);
#define bfd_read_minisymbols(b, d, m, s) \
BFD_SEND (b, _read_minisymbols, (b, d, m, s))
- long (*_read_minisymbols) PARAMS ((bfd *, boolean, PTR *,
- unsigned int *));
+ long (*_read_minisymbols)
+ (bfd *, bfd_boolean, void **, unsigned int *);
#define bfd_minisymbol_to_symbol(b, d, m, f) \
BFD_SEND (b, _minisymbol_to_symbol, (b, d, m, f))
- asymbol *(*_minisymbol_to_symbol) PARAMS ((bfd *, boolean, const PTR,
- asymbol *));
+ asymbol * (*_minisymbol_to_symbol)
+ (bfd *, bfd_boolean, const void *, asymbol *);
/* Routines for relocs. */
#define BFD_JUMP_TABLE_RELOCS(NAME) \
-CONCAT2 (NAME,_get_reloc_upper_bound), \
-CONCAT2 (NAME,_canonicalize_reloc), \
-CONCAT2 (NAME,_bfd_reloc_type_lookup)
- long (*_get_reloc_upper_bound) PARAMS ((bfd *, sec_ptr));
- long (*_bfd_canonicalize_reloc) PARAMS ((bfd *, sec_ptr, arelent **,
- struct symbol_cache_entry **));
+ NAME##_get_reloc_upper_bound, \
+ NAME##_canonicalize_reloc, \
+ NAME##_bfd_reloc_type_lookup
+
+ long (*_get_reloc_upper_bound) (bfd *, sec_ptr);
+ long (*_bfd_canonicalize_reloc)
+ (bfd *, sec_ptr, arelent **, struct bfd_symbol **);
/* See documentation on reloc types. */
reloc_howto_type *
- (*reloc_type_lookup) PARAMS ((bfd *, bfd_reloc_code_real_type));
+ (*reloc_type_lookup) (bfd *, bfd_reloc_code_real_type);
/* Routines used when writing an object file. */
#define BFD_JUMP_TABLE_WRITE(NAME) \
-CONCAT2 (NAME,_set_arch_mach), \
-CONCAT2 (NAME,_set_section_contents)
- boolean (*_bfd_set_arch_mach) PARAMS ((bfd *, enum bfd_architecture,
- unsigned long));
- boolean (*_bfd_set_section_contents) PARAMS ((bfd *, sec_ptr, PTR,
- file_ptr, bfd_size_type));
+ NAME##_set_arch_mach, \
+ NAME##_set_section_contents
+
+ bfd_boolean (*_bfd_set_arch_mach)
+ (bfd *, enum bfd_architecture, unsigned long);
+ bfd_boolean (*_bfd_set_section_contents)
+ (bfd *, sec_ptr, const void *, file_ptr, bfd_size_type);
/* Routines used by the linker. */
#define BFD_JUMP_TABLE_LINK(NAME) \
-CONCAT2 (NAME,_sizeof_headers), \
-CONCAT2 (NAME,_bfd_get_relocated_section_contents), \
-CONCAT2 (NAME,_bfd_relax_section), \
-CONCAT2 (NAME,_bfd_link_hash_table_create), \
-CONCAT2 (NAME,_bfd_link_hash_table_free), \
-CONCAT2 (NAME,_bfd_link_add_symbols), \
-CONCAT2 (NAME,_bfd_link_just_syms), \
-CONCAT2 (NAME,_bfd_final_link), \
-CONCAT2 (NAME,_bfd_link_split_section), \
-CONCAT2 (NAME,_bfd_gc_sections), \
-CONCAT2 (NAME,_bfd_merge_sections), \
-CONCAT2 (NAME,_bfd_discard_group)
- int (*_bfd_sizeof_headers) PARAMS ((bfd *, boolean));
- bfd_byte *(*_bfd_get_relocated_section_contents)
- PARAMS ((bfd *, struct bfd_link_info *, struct bfd_link_order *,
- bfd_byte *, boolean, struct symbol_cache_entry **));
-
- boolean (*_bfd_relax_section)
- PARAMS ((bfd *, struct sec *, struct bfd_link_info *, boolean *));
+ NAME##_sizeof_headers, \
+ NAME##_bfd_get_relocated_section_contents, \
+ NAME##_bfd_relax_section, \
+ NAME##_bfd_link_hash_table_create, \
+ NAME##_bfd_link_hash_table_free, \
+ NAME##_bfd_link_add_symbols, \
+ NAME##_bfd_link_just_syms, \
+ NAME##_bfd_final_link, \
+ NAME##_bfd_link_split_section, \
+ NAME##_bfd_gc_sections, \
+ NAME##_bfd_merge_sections, \
+ NAME##_bfd_discard_group
+
+ int (*_bfd_sizeof_headers) (bfd *, bfd_boolean);
+ bfd_byte * (*_bfd_get_relocated_section_contents)
+ (bfd *, struct bfd_link_info *, struct bfd_link_order *,
+ bfd_byte *, bfd_boolean, struct bfd_symbol **);
+
+ bfd_boolean (*_bfd_relax_section)
+ (bfd *, struct bfd_section *, struct bfd_link_info *, bfd_boolean *);
/* Create a hash table for the linker. Different backends store
different information in this table. */
- struct bfd_link_hash_table *(*_bfd_link_hash_table_create) PARAMS ((bfd *));
+ struct bfd_link_hash_table *
+ (*_bfd_link_hash_table_create) (bfd *);
/* Release the memory associated with the linker hash table. */
- void (*_bfd_link_hash_table_free) PARAMS ((struct bfd_link_hash_table *));
+ void (*_bfd_link_hash_table_free) (struct bfd_link_hash_table *);
/* Add symbols from this object file into the hash table. */
- boolean (*_bfd_link_add_symbols) PARAMS ((bfd *, struct bfd_link_info *));
+ bfd_boolean (*_bfd_link_add_symbols) (bfd *, struct bfd_link_info *);
/* Indicate that we are only retrieving symbol values from this section. */
- void (*_bfd_link_just_syms) PARAMS ((asection *, struct bfd_link_info *));
+ void (*_bfd_link_just_syms) (asection *, struct bfd_link_info *);
/* Do a link based on the link_order structures attached to each
section of the BFD. */
- boolean (*_bfd_final_link) PARAMS ((bfd *, struct bfd_link_info *));
+ bfd_boolean (*_bfd_final_link) (bfd *, struct bfd_link_info *);
/* Should this section be split up into smaller pieces during linking. */
- boolean (*_bfd_link_split_section) PARAMS ((bfd *, struct sec *));
+ bfd_boolean (*_bfd_link_split_section) (bfd *, struct bfd_section *);
/* Remove sections that are not referenced from the output. */
- boolean (*_bfd_gc_sections) PARAMS ((bfd *, struct bfd_link_info *));
+ bfd_boolean (*_bfd_gc_sections) (bfd *, struct bfd_link_info *);
/* Attempt to merge SEC_MERGE sections. */
- boolean (*_bfd_merge_sections) PARAMS ((bfd *, struct bfd_link_info *));
+ bfd_boolean (*_bfd_merge_sections) (bfd *, struct bfd_link_info *);
/* Discard members of a group. */
- boolean (*_bfd_discard_group) PARAMS ((bfd *, struct sec *));
+ bfd_boolean (*_bfd_discard_group) (bfd *, struct bfd_section *);
/* Routines to handle dynamic symbols and relocs. */
#define BFD_JUMP_TABLE_DYNAMIC(NAME) \
-CONCAT2 (NAME,_get_dynamic_symtab_upper_bound), \
-CONCAT2 (NAME,_canonicalize_dynamic_symtab), \
-CONCAT2 (NAME,_get_dynamic_reloc_upper_bound), \
-CONCAT2 (NAME,_canonicalize_dynamic_reloc)
+ NAME##_get_dynamic_symtab_upper_bound, \
+ NAME##_canonicalize_dynamic_symtab, \
+ NAME##_get_dynamic_reloc_upper_bound, \
+ NAME##_canonicalize_dynamic_reloc
+
/* Get the amount of memory required to hold the dynamic symbols. */
- long (*_bfd_get_dynamic_symtab_upper_bound) PARAMS ((bfd *));
+ long (*_bfd_get_dynamic_symtab_upper_bound) (bfd *);
/* Read in the dynamic symbols. */
- long (*_bfd_canonicalize_dynamic_symtab)
- PARAMS ((bfd *, struct symbol_cache_entry **));
+ long (*_bfd_canonicalize_dynamic_symtab)
+ (bfd *, struct bfd_symbol **);
/* Get the amount of memory required to hold the dynamic relocs. */
- long (*_bfd_get_dynamic_reloc_upper_bound) PARAMS ((bfd *));
+ long (*_bfd_get_dynamic_reloc_upper_bound) (bfd *);
/* Read in the dynamic relocs. */
- long (*_bfd_canonicalize_dynamic_reloc)
- PARAMS ((bfd *, arelent **, struct symbol_cache_entry **));
+ long (*_bfd_canonicalize_dynamic_reloc)
+ (bfd *, arelent **, struct bfd_symbol **);
/* Opposite endian version of this target. */
const struct bfd_target * alternative_target;
/* Data for use by back-end routines, which isn't
generic enough to belong in this structure. */
- PTR backend_data;
+ const void *backend_data;
} bfd_target;
-boolean
-bfd_set_default_target PARAMS ((const char *name));
+bfd_boolean bfd_set_default_target (const char *name);
-const bfd_target *
-bfd_find_target PARAMS ((const char *target_name, bfd *abfd));
+const bfd_target *bfd_find_target (const char *target_name, bfd *abfd);
-const char **
-bfd_target_list PARAMS ((void));
+const char ** bfd_target_list (void);
-const bfd_target *
-bfd_search_for_target PARAMS ((int (* search_func) (const bfd_target *, void *), void *));
+const bfd_target *bfd_search_for_target
+ (int (*search_func) (const bfd_target *, void *),
+ void *);
/* Extracted from format.c. */
-boolean
-bfd_check_format PARAMS ((bfd *abfd, bfd_format format));
+bfd_boolean bfd_check_format (bfd *abfd, bfd_format format);
+
+bfd_boolean bfd_check_format_matches
+ (bfd *abfd, bfd_format format, char ***matching);
+
+bfd_boolean bfd_set_format (bfd *abfd, bfd_format format);
+
+const char *bfd_format_string (bfd_format format);
-boolean
-bfd_check_format_matches PARAMS ((bfd *abfd, bfd_format format, char ***matching));
+/* Extracted from linker.c. */
+bfd_boolean bfd_link_split_section (bfd *abfd, asection *sec);
-boolean
-bfd_set_format PARAMS ((bfd *abfd, bfd_format format));
+#define bfd_link_split_section(abfd, sec) \
+ BFD_SEND (abfd, _bfd_link_split_section, (abfd, sec))
-const char *
-bfd_format_string PARAMS ((bfd_format format));
+/* Extracted from simple.c. */
+bfd_byte *bfd_simple_get_relocated_section_contents
+ (bfd *abfd, asection *sec, bfd_byte *outbuf, asymbol **symbol_table);
#ifdef __cplusplus
}
diff --git a/contrib/binutils/bfd/bfd.c b/contrib/binutils/bfd/bfd.c
index 8037b12..59e22aa 100644
--- a/contrib/binutils/bfd/bfd.c
+++ b/contrib/binutils/bfd/bfd.c
@@ -1,24 +1,24 @@
/* Generic BFD library interface and support routines.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Support.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/*
SECTION
@@ -34,8 +34,11 @@ SECTION
CODE_FRAGMENT
.
-.struct _bfd
+.struct bfd
.{
+. {* A unique identifier of the BFD *}
+. unsigned int id;
+.
. {* The filename the application opened the BFD with. *}
. const char *filename;
.
@@ -49,33 +52,33 @@ CODE_FRAGMENT
. is the result of an fopen on the filename. However, if the
. BFD_IN_MEMORY flag is set, then iostream is actually a pointer
. to a bfd_in_memory struct. *}
-. PTR iostream;
+. void *iostream;
.
. {* Is the file descriptor being cached? That is, can it be closed as
. needed, and re-opened when accessed later? *}
-. boolean cacheable;
+. bfd_boolean cacheable;
.
. {* Marks whether there was a default target specified when the
. BFD was opened. This is used to select which matching algorithm
. to use to choose the back end. *}
-. boolean target_defaulted;
+. bfd_boolean target_defaulted;
.
. {* The caching routines use these to maintain a
. least-recently-used list of BFDs. *}
-. struct _bfd *lru_prev, *lru_next;
+. struct bfd *lru_prev, *lru_next;
.
. {* When a file is closed by the caching routines, BFD retains
. state information on the file here... *}
. ufile_ptr where;
.
. {* ... and here: (``once'' means at least once). *}
-. boolean opened_once;
+. bfd_boolean opened_once;
.
. {* Set if we have a locally maintained mtime value, rather than
. getting it from the file each time. *}
-. boolean mtime_set;
+. bfd_boolean mtime_set;
.
-. {* File modified time, if mtime_set is true. *}
+. {* File modified time, if mtime_set is TRUE. *}
. long mtime;
.
. {* Reserved for an unimplemented file locking extension. *}
@@ -104,16 +107,16 @@ CODE_FRAGMENT
.
. {* Remember when output has begun, to stop strange things
. from happening. *}
-. boolean output_has_begun;
+. bfd_boolean output_has_begun;
.
. {* A hash table for section names. *}
. struct bfd_hash_table section_htab;
.
. {* Pointer to linked list of sections. *}
-. struct sec *sections;
+. struct bfd_section *sections;
.
. {* The place where we add to the section list. *}
-. struct sec **section_tail;
+. struct bfd_section **section_tail;
.
. {* The number of sections. *}
. unsigned int section_count;
@@ -126,7 +129,7 @@ CODE_FRAGMENT
. unsigned int symcount;
.
. {* Symbol table for output BFD (with symcount entries). *}
-. struct symbol_cache_entry **outsymbols;
+. struct bfd_symbol **outsymbols;
.
. {* Used for slurped dynamic symbol tables. *}
. unsigned int dynsymcount;
@@ -135,14 +138,14 @@ CODE_FRAGMENT
. const struct bfd_arch_info *arch_info;
.
. {* Stuff only useful for archives. *}
-. PTR arelt_data;
-. struct _bfd *my_archive; {* The containing archive BFD. *}
-. struct _bfd *next; {* The next BFD in the archive. *}
-. struct _bfd *archive_head; {* The first BFD in the archive. *}
-. boolean has_armap;
+. void *arelt_data;
+. struct bfd *my_archive; {* The containing archive BFD. *}
+. struct bfd *next; {* The next BFD in the archive. *}
+. struct bfd *archive_head; {* The first BFD in the archive. *}
+. bfd_boolean has_armap;
.
. {* A chain of BFD structures involved in a link. *}
-. struct _bfd *link_next;
+. struct bfd *link_next;
.
. {* A field used by _bfd_generic_link_add_archive_symbols. This will
. be used only for archive elements. *}
@@ -180,30 +183,30 @@ CODE_FRAGMENT
. struct cisco_core_struct *cisco_core_data;
. struct versados_data_struct *versados_data;
. struct netbsd_core_struct *netbsd_core_data;
-. PTR any;
+. struct mach_o_data_struct *mach_o_data;
+. struct mach_o_fat_data_struct *mach_o_fat_data;
+. struct bfd_pef_data_struct *pef_data;
+. struct bfd_pef_xlib_data_struct *pef_xlib_data;
+. struct bfd_sym_data_struct *sym_data;
+. void *any;
. }
. tdata;
.
. {* Used by the application to hold private data. *}
-. PTR usrdata;
+. void *usrdata;
.
. {* Where all the allocated stuff under this BFD goes. This is a
-. struct objalloc *, but we use PTR to avoid requiring the inclusion of
-. objalloc.h. *}
-. PTR memory;
+. struct objalloc *, but we use void * to avoid requiring the inclusion
+. of objalloc.h. *}
+. void *memory;
.};
.
*/
#include "bfd.h"
+#include "bfdver.h"
#include "sysdep.h"
-
-#ifdef ANSI_PROTOTYPES
#include <stdarg.h>
-#else
-#include <varargs.h>
-#endif
-
#include "libiberty.h"
#include "safe-ctype.h"
#include "bfdlink.h"
@@ -308,7 +311,7 @@ DESCRIPTION
*/
bfd_error_type
-bfd_get_error ()
+bfd_get_error (void)
{
return bfd_error;
}
@@ -325,8 +328,7 @@ DESCRIPTION
*/
void
-bfd_set_error (error_tag)
- bfd_error_type error_tag;
+bfd_set_error (bfd_error_type error_tag)
{
bfd_error = error_tag;
}
@@ -344,8 +346,7 @@ DESCRIPTION
*/
const char *
-bfd_errmsg (error_tag)
- bfd_error_type error_tag;
+bfd_errmsg (bfd_error_type error_tag)
{
#ifndef errno
extern int errno;
@@ -353,11 +354,10 @@ bfd_errmsg (error_tag)
if (error_tag == bfd_error_system_call)
return xstrerror (errno);
- if ((((int) error_tag < (int) bfd_error_no_error) ||
- ((int) error_tag > (int) bfd_error_invalid_error_code)))
- error_tag = bfd_error_invalid_error_code;/* sanity check */
+ if (error_tag > bfd_error_invalid_error_code)
+ error_tag = bfd_error_invalid_error_code; /* sanity check */
- return _(bfd_errmsgs [(int)error_tag]);
+ return _(bfd_errmsgs [error_tag]);
}
/*
@@ -376,12 +376,11 @@ DESCRIPTION
*/
void
-bfd_perror (message)
- const char *message;
+bfd_perror (const char *message)
{
if (bfd_get_error () == bfd_error_system_call)
/* Must be a system error then. */
- perror ((char *)message);
+ perror ((char *) message);
else
{
if (message == NULL || *message == '\0')
@@ -397,13 +396,13 @@ SUBSECTION
Some BFD functions want to print messages describing the
problem. They call a BFD error handler function. This
- function may be overriden by the program.
+ function may be overridden by the program.
The BFD error handler acts like printf.
CODE_FRAGMENT
.
-.typedef void (*bfd_error_handler_type) PARAMS ((const char *, ...));
+.typedef void (*bfd_error_handler_type) (const char *, ...);
.
*/
@@ -413,20 +412,19 @@ static const char *_bfd_error_program_name;
/* This is the default routine to handle BFD error messages. */
-static void _bfd_default_error_handler PARAMS ((const char *s, ...));
-
static void
-_bfd_default_error_handler VPARAMS ((const char *s, ...))
+_bfd_default_error_handler (const char *s, ...)
{
+ va_list p;
+
if (_bfd_error_program_name != NULL)
fprintf (stderr, "%s: ", _bfd_error_program_name);
else
fprintf (stderr, "BFD: ");
- VA_OPEN (p, s);
- VA_FIXEDARG (p, const char *, s);
+ va_start (p, s);
vfprintf (stderr, s, p);
- VA_CLOSE (p);
+ va_end (p);
fprintf (stderr, "\n");
}
@@ -452,8 +450,7 @@ DESCRIPTION
*/
bfd_error_handler_type
-bfd_set_error_handler (pnew)
- bfd_error_handler_type pnew;
+bfd_set_error_handler (bfd_error_handler_type pnew)
{
bfd_error_handler_type pold;
@@ -477,8 +474,7 @@ DESCRIPTION
*/
void
-bfd_set_error_program_name (name)
- const char *name;
+bfd_set_error_program_name (const char *name)
{
_bfd_error_program_name = name;
}
@@ -495,7 +491,7 @@ DESCRIPTION
*/
bfd_error_handler_type
-bfd_get_error_handler ()
+bfd_get_error_handler (void)
{
return _bfd_error_handler;
}
@@ -514,9 +510,11 @@ DESCRIPTION
*/
const char *
-bfd_archive_filename (abfd)
- bfd *abfd;
+bfd_archive_filename (bfd *abfd)
{
+ if (abfd == NULL)
+ return _("<unknown>");
+
if (abfd->my_archive)
{
static size_t curr = 0;
@@ -530,7 +528,7 @@ bfd_archive_filename (abfd)
if (curr)
free (buf);
curr = needed + (needed >> 1);
- buf = bfd_malloc ((bfd_size_type) curr);
+ buf = bfd_malloc (curr);
/* If we can't malloc, fail safe by returning just the file
name. This function is only used when building error
messages. */
@@ -558,7 +556,7 @@ FUNCTION
bfd_get_reloc_upper_bound
SYNOPSIS
- long bfd_get_reloc_upper_bound(bfd *abfd, asection *sect);
+ long bfd_get_reloc_upper_bound (bfd *abfd, asection *sect);
DESCRIPTION
Return the number of bytes required to store the
@@ -568,9 +566,7 @@ DESCRIPTION
*/
long
-bfd_get_reloc_upper_bound (abfd, asect)
- bfd *abfd;
- sec_ptr asect;
+bfd_get_reloc_upper_bound (bfd *abfd, sec_ptr asect)
{
if (abfd->format != bfd_object)
{
@@ -587,10 +583,7 @@ FUNCTION
SYNOPSIS
long bfd_canonicalize_reloc
- (bfd *abfd,
- asection *sec,
- arelent **loc,
- asymbol **syms);
+ (bfd *abfd, asection *sec, arelent **loc, asymbol **syms);
DESCRIPTION
Call the back end associated with the open BFD
@@ -606,11 +599,10 @@ DESCRIPTION
*/
long
-bfd_canonicalize_reloc (abfd, asect, location, symbols)
- bfd *abfd;
- sec_ptr asect;
- arelent **location;
- asymbol **symbols;
+bfd_canonicalize_reloc (bfd *abfd,
+ sec_ptr asect,
+ arelent **location,
+ asymbol **symbols)
{
if (abfd->format != bfd_object)
{
@@ -638,11 +630,10 @@ DESCRIPTION
*/
void
-bfd_set_reloc (ignore_abfd, asect, location, count)
- bfd *ignore_abfd ATTRIBUTE_UNUSED;
- sec_ptr asect;
- arelent **location;
- unsigned int count;
+bfd_set_reloc (bfd *ignore_abfd ATTRIBUTE_UNUSED,
+ sec_ptr asect,
+ arelent **location,
+ unsigned int count)
{
asect->orelocation = location;
asect->reloc_count = count;
@@ -653,7 +644,7 @@ FUNCTION
bfd_set_file_flags
SYNOPSIS
- boolean bfd_set_file_flags(bfd *abfd, flagword flags);
+ bfd_boolean bfd_set_file_flags (bfd *abfd, flagword flags);
DESCRIPTION
Set the flag word in the BFD @var{abfd} to the value @var{flags}.
@@ -668,37 +659,33 @@ DESCRIPTION
*/
-boolean
-bfd_set_file_flags (abfd, flags)
- bfd *abfd;
- flagword flags;
+bfd_boolean
+bfd_set_file_flags (bfd *abfd, flagword flags)
{
if (abfd->format != bfd_object)
{
bfd_set_error (bfd_error_wrong_format);
- return false;
+ return FALSE;
}
if (bfd_read_p (abfd))
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
bfd_get_file_flags (abfd) = flags;
if ((flags & bfd_applicable_file_flags (abfd)) != flags)
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
void
-bfd_assert (file, line)
- const char *file;
- int line;
+bfd_assert (const char *file, int line)
{
(*_bfd_error_handler) (_("BFD %s assertion fail %s:%d"),
BFD_VERSION_STRING, file, line);
@@ -712,10 +699,7 @@ bfd_assert (file, line)
#endif
void
-_bfd_abort (file, line, fn)
- const char *file;
- int line;
- const char *fn;
+_bfd_abort (const char *file, int line, const char *fn)
{
if (fn != NULL)
(*_bfd_error_handler)
@@ -746,11 +730,10 @@ RETURNS
*/
int
-bfd_get_arch_size (abfd)
- bfd *abfd;
+bfd_get_arch_size (bfd *abfd)
{
if (abfd->xvec->flavour == bfd_target_elf_flavour)
- return (get_elf_backend_data (abfd))->s->arch_size;
+ return get_elf_backend_data (abfd)->s->arch_size;
return -1;
}
@@ -777,13 +760,12 @@ RETURNS
*/
int
-bfd_get_sign_extend_vma (abfd)
- bfd *abfd;
+bfd_get_sign_extend_vma (bfd *abfd)
{
char *name;
if (bfd_get_flavour (abfd) == bfd_target_elf_flavour)
- return (get_elf_backend_data (abfd)->sign_extend_vma);
+ return get_elf_backend_data (abfd)->sign_extend_vma;
name = bfd_get_target (abfd);
@@ -804,103 +786,20 @@ FUNCTION
bfd_set_start_address
SYNOPSIS
- boolean bfd_set_start_address(bfd *abfd, bfd_vma vma);
+ bfd_boolean bfd_set_start_address (bfd *abfd, bfd_vma vma);
DESCRIPTION
Make @var{vma} the entry point of output BFD @var{abfd}.
RETURNS
- Returns <<true>> on success, <<false>> otherwise.
+ Returns <<TRUE>> on success, <<FALSE>> otherwise.
*/
-boolean
-bfd_set_start_address (abfd, vma)
- bfd *abfd;
- bfd_vma vma;
+bfd_boolean
+bfd_set_start_address (bfd *abfd, bfd_vma vma)
{
abfd->start_address = vma;
- return true;
-}
-
-/*
-FUNCTION
- bfd_get_mtime
-
-SYNOPSIS
- long bfd_get_mtime(bfd *abfd);
-
-DESCRIPTION
- Return the file modification time (as read from the file system, or
- from the archive header for archive members).
-
-*/
-
-long
-bfd_get_mtime (abfd)
- bfd *abfd;
-{
- FILE *fp;
- struct stat buf;
-
- if (abfd->mtime_set)
- return abfd->mtime;
-
- fp = bfd_cache_lookup (abfd);
- if (0 != fstat (fileno (fp), &buf))
- return 0;
-
- abfd->mtime = buf.st_mtime; /* Save value in case anyone wants it */
- return buf.st_mtime;
-}
-
-/*
-FUNCTION
- bfd_get_size
-
-SYNOPSIS
- long bfd_get_size(bfd *abfd);
-
-DESCRIPTION
- Return the file size (as read from file system) for the file
- associated with BFD @var{abfd}.
-
- The initial motivation for, and use of, this routine is not
- so we can get the exact size of the object the BFD applies to, since
- that might not be generally possible (archive members for example).
- It would be ideal if someone could eventually modify
- it so that such results were guaranteed.
-
- Instead, we want to ask questions like "is this NNN byte sized
- object I'm about to try read from file offset YYY reasonable?"
- As as example of where we might do this, some object formats
- use string tables for which the first <<sizeof (long)>> bytes of the
- table contain the size of the table itself, including the size bytes.
- If an application tries to read what it thinks is one of these
- string tables, without some way to validate the size, and for
- some reason the size is wrong (byte swapping error, wrong location
- for the string table, etc.), the only clue is likely to be a read
- error when it tries to read the table, or a "virtual memory
- exhausted" error when it tries to allocate 15 bazillon bytes
- of space for the 15 bazillon byte table it is about to read.
- This function at least allows us to answer the quesion, "is the
- size reasonable?".
-*/
-
-long
-bfd_get_size (abfd)
- bfd *abfd;
-{
- FILE *fp;
- struct stat buf;
-
- if ((abfd->flags & BFD_IN_MEMORY) != 0)
- return ((struct bfd_in_memory *) abfd->iostream)->size;
-
- fp = bfd_cache_lookup (abfd);
- if (0 != fstat (fileno (fp), & buf))
- return 0;
-
- return buf.st_size;
+ return TRUE;
}
/*
@@ -908,7 +807,7 @@ FUNCTION
bfd_get_gp_size
SYNOPSIS
- unsigned int bfd_get_gp_size(bfd *abfd);
+ unsigned int bfd_get_gp_size (bfd *abfd);
DESCRIPTION
Return the maximum size of objects to be optimized using the GP
@@ -917,8 +816,7 @@ DESCRIPTION
*/
unsigned int
-bfd_get_gp_size (abfd)
- bfd *abfd;
+bfd_get_gp_size (bfd *abfd)
{
if (abfd->format == bfd_object)
{
@@ -935,7 +833,7 @@ FUNCTION
bfd_set_gp_size
SYNOPSIS
- void bfd_set_gp_size(bfd *abfd, unsigned int i);
+ void bfd_set_gp_size (bfd *abfd, unsigned int i);
DESCRIPTION
Set the maximum size of objects to be optimized using the GP
@@ -944,9 +842,7 @@ DESCRIPTION
*/
void
-bfd_set_gp_size (abfd, i)
- bfd *abfd;
- unsigned int i;
+bfd_set_gp_size (bfd *abfd, unsigned int i)
{
/* Don't try to set GP size on an archive or core file! */
if (abfd->format != bfd_object)
@@ -963,9 +859,10 @@ bfd_set_gp_size (abfd, i)
register. */
bfd_vma
-_bfd_get_gp_value (abfd)
- bfd *abfd;
+_bfd_get_gp_value (bfd *abfd)
{
+ if (! abfd)
+ return 0;
if (abfd->format != bfd_object)
return 0;
@@ -980,10 +877,10 @@ _bfd_get_gp_value (abfd)
/* Set the GP value. */
void
-_bfd_set_gp_value (abfd, v)
- bfd *abfd;
- bfd_vma v;
+_bfd_set_gp_value (bfd *abfd, bfd_vma v)
{
+ if (! abfd)
+ BFD_FAIL ();
if (abfd->format != bfd_object)
return;
@@ -998,7 +895,7 @@ FUNCTION
bfd_scan_vma
SYNOPSIS
- bfd_vma bfd_scan_vma(const char *string, const char **end, int base);
+ bfd_vma bfd_scan_vma (const char *string, const char **end, int base);
DESCRIPTION
Convert, like <<strtoul>>, a numerical expression
@@ -1015,10 +912,7 @@ DESCRIPTION
*/
bfd_vma
-bfd_scan_vma (string, end, base)
- const char *string;
- const char **end;
- int base;
+bfd_scan_vma (const char *string, const char **end, int base)
{
bfd_vma value;
bfd_vma cutoff;
@@ -1027,7 +921,12 @@ bfd_scan_vma (string, end, base)
/* Let the host do it if possible. */
if (sizeof (bfd_vma) <= sizeof (unsigned long))
- return (bfd_vma) strtoul (string, (char **) end, base);
+ return strtoul (string, (char **) end, base);
+
+#ifdef HAVE_STRTOULL
+ if (sizeof (bfd_vma) <= sizeof (unsigned long long))
+ return strtoull (string, (char **) end, base);
+#endif
if (base == 0)
{
@@ -1088,11 +987,11 @@ FUNCTION
bfd_copy_private_bfd_data
SYNOPSIS
- boolean bfd_copy_private_bfd_data(bfd *ibfd, bfd *obfd);
+ bfd_boolean bfd_copy_private_bfd_data (bfd *ibfd, bfd *obfd);
DESCRIPTION
Copy private BFD information from the BFD @var{ibfd} to the
- the BFD @var{obfd}. Return <<true>> on success, <<false>> on error.
+ the BFD @var{obfd}. Return <<TRUE>> on success, <<FALSE>> on error.
Possible error returns are:
o <<bfd_error_no_memory>> -
@@ -1109,12 +1008,12 @@ FUNCTION
bfd_merge_private_bfd_data
SYNOPSIS
- boolean bfd_merge_private_bfd_data(bfd *ibfd, bfd *obfd);
+ bfd_boolean bfd_merge_private_bfd_data (bfd *ibfd, bfd *obfd);
DESCRIPTION
Merge private BFD information from the BFD @var{ibfd} to the
- the output file BFD @var{obfd} when linking. Return <<true>>
- on success, <<false>> on error. Possible error returns are:
+ the output file BFD @var{obfd} when linking. Return <<TRUE>>
+ on success, <<FALSE>> on error. Possible error returns are:
o <<bfd_error_no_memory>> -
Not enough memory exists to create private data for @var{obfd}.
@@ -1130,54 +1029,52 @@ FUNCTION
bfd_set_private_flags
SYNOPSIS
- boolean bfd_set_private_flags(bfd *abfd, flagword flags);
+ bfd_boolean bfd_set_private_flags (bfd *abfd, flagword flags);
DESCRIPTION
Set private BFD flag information in the BFD @var{abfd}.
- Return <<true>> on success, <<false>> on error. Possible error
+ Return <<TRUE>> on success, <<FALSE>> on error. Possible error
returns are:
o <<bfd_error_no_memory>> -
Not enough memory exists to create private data for @var{obfd}.
.#define bfd_set_private_flags(abfd, flags) \
-. BFD_SEND (abfd, _bfd_set_private_flags, \
-. (abfd, flags))
+. BFD_SEND (abfd, _bfd_set_private_flags, (abfd, flags))
*/
/*
FUNCTION
- stuff
+ Other functions
DESCRIPTION
- Stuff which should be documented:
+ The following functions exist but have not yet been documented.
.#define bfd_sizeof_headers(abfd, reloc) \
-. BFD_SEND (abfd, _bfd_sizeof_headers, (abfd, reloc))
+. BFD_SEND (abfd, _bfd_sizeof_headers, (abfd, reloc))
.
.#define bfd_find_nearest_line(abfd, sec, syms, off, file, func, line) \
-. BFD_SEND (abfd, _bfd_find_nearest_line, (abfd, sec, syms, off, file, func, line))
+. BFD_SEND (abfd, _bfd_find_nearest_line, \
+. (abfd, sec, syms, off, file, func, line))
.
-. {* Do these three do anything useful at all, for any back end? *}
.#define bfd_debug_info_start(abfd) \
-. BFD_SEND (abfd, _bfd_debug_info_start, (abfd))
+. BFD_SEND (abfd, _bfd_debug_info_start, (abfd))
.
.#define bfd_debug_info_end(abfd) \
-. BFD_SEND (abfd, _bfd_debug_info_end, (abfd))
+. BFD_SEND (abfd, _bfd_debug_info_end, (abfd))
.
.#define bfd_debug_info_accumulate(abfd, section) \
-. BFD_SEND (abfd, _bfd_debug_info_accumulate, (abfd, section))
-.
+. BFD_SEND (abfd, _bfd_debug_info_accumulate, (abfd, section))
.
.#define bfd_stat_arch_elt(abfd, stat) \
-. BFD_SEND (abfd, _bfd_stat_arch_elt,(abfd, stat))
+. BFD_SEND (abfd, _bfd_stat_arch_elt,(abfd, stat))
.
.#define bfd_update_armap_timestamp(abfd) \
-. BFD_SEND (abfd, _bfd_update_armap_timestamp, (abfd))
+. BFD_SEND (abfd, _bfd_update_armap_timestamp, (abfd))
.
.#define bfd_set_arch_mach(abfd, arch, mach)\
-. BFD_SEND ( abfd, _bfd_set_arch_mach, (abfd, arch, mach))
+. BFD_SEND ( abfd, _bfd_set_arch_mach, (abfd, arch, mach))
.
.#define bfd_relax_section(abfd, section, link_info, again) \
. BFD_SEND (abfd, _bfd_relax_section, (abfd, section, link_info, again))
@@ -1225,27 +1122,23 @@ DESCRIPTION
. BFD_SEND (abfd, _bfd_canonicalize_dynamic_reloc, (abfd, arels, asyms))
.
.extern bfd_byte *bfd_get_relocated_section_contents
-. PARAMS ((bfd *, struct bfd_link_info *,
-. struct bfd_link_order *, bfd_byte *,
-. boolean, asymbol **));
+. (bfd *, struct bfd_link_info *, struct bfd_link_order *, bfd_byte *,
+. bfd_boolean, asymbol **);
.
*/
bfd_byte *
-bfd_get_relocated_section_contents (abfd, link_info, link_order, data,
- relocateable, symbols)
- bfd *abfd;
- struct bfd_link_info *link_info;
- struct bfd_link_order *link_order;
- bfd_byte *data;
- boolean relocateable;
- asymbol **symbols;
+bfd_get_relocated_section_contents (bfd *abfd,
+ struct bfd_link_info *link_info,
+ struct bfd_link_order *link_order,
+ bfd_byte *data,
+ bfd_boolean relocatable,
+ asymbol **symbols)
{
bfd *abfd2;
- bfd_byte *(*fn) PARAMS ((bfd *, struct bfd_link_info *,
- struct bfd_link_order *, bfd_byte *, boolean,
- asymbol **));
+ bfd_byte *(*fn) (bfd *, struct bfd_link_info *, struct bfd_link_order *,
+ bfd_byte *, bfd_boolean, asymbol **);
if (link_order->type == bfd_indirect_link_order)
{
@@ -1258,45 +1151,43 @@ bfd_get_relocated_section_contents (abfd, link_info, link_order, data,
fn = abfd2->xvec->_bfd_get_relocated_section_contents;
- return (*fn) (abfd, link_info, link_order, data, relocateable, symbols);
+ return (*fn) (abfd, link_info, link_order, data, relocatable, symbols);
}
/* Record information about an ELF program header. */
-boolean
-bfd_record_phdr (abfd, type, flags_valid, flags, at_valid, at,
- includes_filehdr, includes_phdrs, count, secs)
- bfd *abfd;
- unsigned long type;
- boolean flags_valid;
- flagword flags;
- boolean at_valid;
- bfd_vma at;
- boolean includes_filehdr;
- boolean includes_phdrs;
- unsigned int count;
- asection **secs;
+bfd_boolean
+bfd_record_phdr (bfd *abfd,
+ unsigned long type,
+ bfd_boolean flags_valid,
+ flagword flags,
+ bfd_boolean at_valid,
+ bfd_vma at,
+ bfd_boolean includes_filehdr,
+ bfd_boolean includes_phdrs,
+ unsigned int count,
+ asection **secs)
{
struct elf_segment_map *m, **pm;
bfd_size_type amt;
if (bfd_get_flavour (abfd) != bfd_target_elf_flavour)
- return true;
+ return TRUE;
amt = sizeof (struct elf_segment_map);
amt += ((bfd_size_type) count - 1) * sizeof (asection *);
- m = (struct elf_segment_map *) bfd_alloc (abfd, amt);
+ m = bfd_alloc (abfd, amt);
if (m == NULL)
- return false;
+ return FALSE;
m->next = NULL;
m->p_type = type;
m->p_flags = flags;
m->p_paddr = at;
- m->p_flags_valid = (unsigned int) flags_valid;
- m->p_paddr_valid = (unsigned int) at_valid;
- m->includes_filehdr = (unsigned int) includes_filehdr;
- m->includes_phdrs = (unsigned int) includes_phdrs;
+ m->p_flags_valid = flags_valid;
+ m->p_paddr_valid = at_valid;
+ m->includes_filehdr = includes_filehdr;
+ m->includes_phdrs = includes_phdrs;
m->count = count;
if (count > 0)
memcpy (m->sections, secs, count * sizeof (asection *));
@@ -1305,14 +1196,11 @@ bfd_record_phdr (abfd, type, flags_valid, flags, at_valid, at,
;
*pm = m;
- return true;
+ return TRUE;
}
void
-bfd_sprintf_vma (abfd, buf, value)
- bfd *abfd;
- char *buf;
- bfd_vma value;
+bfd_sprintf_vma (bfd *abfd, char *buf, bfd_vma value)
{
if (bfd_get_flavour (abfd) == bfd_target_elf_flavour)
get_elf_backend_data (abfd)->elf_backend_sprintf_vma (abfd, buf, value);
@@ -1321,10 +1209,7 @@ bfd_sprintf_vma (abfd, buf, value)
}
void
-bfd_fprintf_vma (abfd, stream, value)
- bfd *abfd;
- PTR stream;
- bfd_vma value;
+bfd_fprintf_vma (bfd *abfd, void *stream, bfd_vma value)
{
if (bfd_get_flavour (abfd) == bfd_target_elf_flavour)
get_elf_backend_data (abfd)->elf_backend_fprintf_vma (abfd, stream, value);
@@ -1337,7 +1222,7 @@ FUNCTION
bfd_alt_mach_code
SYNOPSIS
- boolean bfd_alt_mach_code(bfd *abfd, int alternative);
+ bfd_boolean bfd_alt_mach_code (bfd *abfd, int alternative);
DESCRIPTION
@@ -1348,10 +1233,8 @@ DESCRIPTION
machine codes.
*/
-boolean
-bfd_alt_mach_code (abfd, alternative)
- bfd *abfd;
- int alternative;
+bfd_boolean
+bfd_alt_mach_code (bfd *abfd, int alternative)
{
if (bfd_get_flavour (abfd) == bfd_target_elf_flavour)
{
@@ -1366,23 +1249,144 @@ bfd_alt_mach_code (abfd, alternative)
case 1:
code = get_elf_backend_data (abfd)->elf_machine_alt1;
if (code == 0)
- return false;
+ return FALSE;
break;
case 2:
code = get_elf_backend_data (abfd)->elf_machine_alt2;
if (code == 0)
- return false;
+ return FALSE;
break;
default:
- return false;
+ return FALSE;
}
elf_elfheader (abfd)->e_machine = code;
- return true;
+ return TRUE;
}
- return false;
+ return FALSE;
+}
+
+/*
+CODE_FRAGMENT
+
+.struct bfd_preserve
+.{
+. void *marker;
+. void *tdata;
+. flagword flags;
+. const struct bfd_arch_info *arch_info;
+. struct bfd_section *sections;
+. struct bfd_section **section_tail;
+. unsigned int section_count;
+. struct bfd_hash_table section_htab;
+.};
+.
+*/
+
+/*
+FUNCTION
+ bfd_preserve_save
+
+SYNOPSIS
+ bfd_boolean bfd_preserve_save (bfd *, struct bfd_preserve *);
+
+DESCRIPTION
+ When testing an object for compatibility with a particular
+ target back-end, the back-end object_p function needs to set
+ up certain fields in the bfd on successfully recognizing the
+ object. This typically happens in a piecemeal fashion, with
+ failures possible at many points. On failure, the bfd is
+ supposed to be restored to its initial state, which is
+ virtually impossible. However, restoring a subset of the bfd
+ state works in practice. This function stores the subset and
+ reinitializes the bfd.
+
+*/
+
+bfd_boolean
+bfd_preserve_save (bfd *abfd, struct bfd_preserve *preserve)
+{
+ preserve->tdata = abfd->tdata.any;
+ preserve->arch_info = abfd->arch_info;
+ preserve->flags = abfd->flags;
+ preserve->sections = abfd->sections;
+ preserve->section_tail = abfd->section_tail;
+ preserve->section_count = abfd->section_count;
+ preserve->section_htab = abfd->section_htab;
+
+ if (! bfd_hash_table_init (&abfd->section_htab, bfd_section_hash_newfunc))
+ return FALSE;
+
+ abfd->tdata.any = NULL;
+ abfd->arch_info = &bfd_default_arch_struct;
+ abfd->flags &= BFD_IN_MEMORY;
+ abfd->sections = NULL;
+ abfd->section_tail = &abfd->sections;
+ abfd->section_count = 0;
+
+ return TRUE;
+}
+
+/*
+FUNCTION
+ bfd_preserve_restore
+
+SYNOPSIS
+ void bfd_preserve_restore (bfd *, struct bfd_preserve *);
+
+DESCRIPTION
+ This function restores bfd state saved by bfd_preserve_save.
+ If MARKER is non-NULL in struct bfd_preserve then that block
+ and all subsequently bfd_alloc'd memory is freed.
+
+*/
+
+void
+bfd_preserve_restore (bfd *abfd, struct bfd_preserve *preserve)
+{
+ bfd_hash_table_free (&abfd->section_htab);
+
+ abfd->tdata.any = preserve->tdata;
+ abfd->arch_info = preserve->arch_info;
+ abfd->flags = preserve->flags;
+ abfd->section_htab = preserve->section_htab;
+ abfd->sections = preserve->sections;
+ abfd->section_tail = preserve->section_tail;
+ abfd->section_count = preserve->section_count;
+
+ /* bfd_release frees all memory more recently bfd_alloc'd than
+ its arg, as well as its arg. */
+ if (preserve->marker != NULL)
+ {
+ bfd_release (abfd, preserve->marker);
+ preserve->marker = NULL;
+ }
+}
+
+/*
+FUNCTION
+ bfd_preserve_finish
+
+SYNOPSIS
+ void bfd_preserve_finish (bfd *, struct bfd_preserve *);
+
+DESCRIPTION
+ This function should be called when the bfd state saved by
+ bfd_preserve_save is no longer needed. ie. when the back-end
+ object_p function returns with success.
+
+*/
+
+void
+bfd_preserve_finish (bfd *abfd ATTRIBUTE_UNUSED, struct bfd_preserve *preserve)
+{
+ /* It would be nice to be able to free more memory here, eg. old
+ tdata, but that's not possible since these blocks are sitting
+ inside bfd_alloc'd memory. The section hash is on a separate
+ objalloc. */
+ bfd_hash_table_free (&preserve->section_htab);
}
diff --git a/contrib/binutils/bfd/bfdio.c b/contrib/binutils/bfd/bfdio.c
new file mode 100644
index 0000000..a90cb33
--- /dev/null
+++ b/contrib/binutils/bfd/bfdio.c
@@ -0,0 +1,442 @@
+/* Low-level I/O routines for BFDs.
+
+ Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
+ 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
+
+ Written by Cygnus Support.
+
+This file is part of BFD, the Binary File Descriptor library.
+
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+#include "sysdep.h"
+
+#include "bfd.h"
+#include "libbfd.h"
+
+#include <limits.h>
+
+#ifndef S_IXUSR
+#define S_IXUSR 0100 /* Execute by owner. */
+#endif
+#ifndef S_IXGRP
+#define S_IXGRP 0010 /* Execute by group. */
+#endif
+#ifndef S_IXOTH
+#define S_IXOTH 0001 /* Execute by others. */
+#endif
+
+file_ptr
+real_ftell (FILE *file)
+{
+#if defined (HAVE_FTELLO64)
+ return ftello64 (file);
+#elif defined (HAVE_FTELLO)
+ return ftello (file);
+#else
+ return ftell (file);
+#endif
+}
+
+int
+real_fseek (FILE *file, file_ptr offset, int whence)
+{
+#if defined (HAVE_FSEEKO64)
+ return fseeko64 (file, offset, whence);
+#elif defined (HAVE_FSEEKO)
+ return fseeko (file, offset, whence);
+#else
+ return fseek (file, offset, whence);
+#endif
+}
+
+/* Note that archive entries don't have streams; they share their parent's.
+ This allows someone to play with the iostream behind BFD's back.
+
+ Also, note that the origin pointer points to the beginning of a file's
+ contents (0 for non-archive elements). For archive entries this is the
+ first octet in the file, NOT the beginning of the archive header. */
+
+static size_t
+real_read (void *where, size_t a, size_t b, FILE *file)
+{
+ /* FIXME - this looks like an optimization, but it's really to cover
+ up for a feature of some OSs (not solaris - sigh) that
+ ld/pe-dll.c takes advantage of (apparently) when it creates BFDs
+ internally and tries to link against them. BFD seems to be smart
+ enough to realize there are no symbol records in the "file" that
+ doesn't exist but attempts to read them anyway. On Solaris,
+ attempting to read zero bytes from a NULL file results in a core
+ dump, but on other platforms it just returns zero bytes read.
+ This makes it to something reasonable. - DJ */
+ if (a == 0 || b == 0)
+ return 0;
+
+
+#if defined (__VAX) && defined (VMS)
+ /* Apparently fread on Vax VMS does not keep the record length
+ information. */
+ return read (fileno (file), where, a * b);
+#else
+ return fread (where, a, b, file);
+#endif
+}
+
+/* Return value is amount read. */
+
+bfd_size_type
+bfd_bread (void *ptr, bfd_size_type size, bfd *abfd)
+{
+ size_t nread;
+
+ if ((abfd->flags & BFD_IN_MEMORY) != 0)
+ {
+ struct bfd_in_memory *bim;
+ bfd_size_type get;
+
+ bim = abfd->iostream;
+ get = size;
+ if (abfd->where + get > bim->size)
+ {
+ if (bim->size < (bfd_size_type) abfd->where)
+ get = 0;
+ else
+ get = bim->size - abfd->where;
+ bfd_set_error (bfd_error_file_truncated);
+ }
+ memcpy (ptr, bim->buffer + abfd->where, (size_t) get);
+ abfd->where += get;
+ return get;
+ }
+
+ nread = real_read (ptr, 1, (size_t) size, bfd_cache_lookup (abfd));
+ if (nread != (size_t) -1)
+ abfd->where += nread;
+
+ /* Set bfd_error if we did not read as much data as we expected.
+
+ If the read failed due to an error set the bfd_error_system_call,
+ else set bfd_error_file_truncated.
+
+ A BFD backend may wish to override bfd_error_file_truncated to
+ provide something more useful (eg. no_symbols or wrong_format). */
+ if (nread != size)
+ {
+ if (ferror (bfd_cache_lookup (abfd)))
+ bfd_set_error (bfd_error_system_call);
+ else
+ bfd_set_error (bfd_error_file_truncated);
+ }
+
+ return nread;
+}
+
+bfd_size_type
+bfd_bwrite (const void *ptr, bfd_size_type size, bfd *abfd)
+{
+ size_t nwrote;
+
+ if ((abfd->flags & BFD_IN_MEMORY) != 0)
+ {
+ struct bfd_in_memory *bim = abfd->iostream;
+ size = (size_t) size;
+ if (abfd->where + size > bim->size)
+ {
+ bfd_size_type newsize, oldsize;
+
+ oldsize = (bim->size + 127) & ~(bfd_size_type) 127;
+ bim->size = abfd->where + size;
+ /* Round up to cut down on memory fragmentation */
+ newsize = (bim->size + 127) & ~(bfd_size_type) 127;
+ if (newsize > oldsize)
+ {
+ bim->buffer = bfd_realloc (bim->buffer, newsize);
+ if (bim->buffer == 0)
+ {
+ bim->size = 0;
+ return 0;
+ }
+ }
+ }
+ memcpy (bim->buffer + abfd->where, ptr, (size_t) size);
+ abfd->where += size;
+ return size;
+ }
+
+ nwrote = fwrite (ptr, 1, (size_t) size, bfd_cache_lookup (abfd));
+ if (nwrote != (size_t) -1)
+ abfd->where += nwrote;
+ if (nwrote != size)
+ {
+#ifdef ENOSPC
+ errno = ENOSPC;
+#endif
+ bfd_set_error (bfd_error_system_call);
+ }
+ return nwrote;
+}
+
+file_ptr
+bfd_tell (bfd *abfd)
+{
+ file_ptr ptr;
+
+ if ((abfd->flags & BFD_IN_MEMORY) != 0)
+ return abfd->where;
+
+ ptr = real_ftell (bfd_cache_lookup (abfd));
+
+ if (abfd->my_archive)
+ ptr -= abfd->origin;
+ abfd->where = ptr;
+ return ptr;
+}
+
+int
+bfd_flush (bfd *abfd)
+{
+ if ((abfd->flags & BFD_IN_MEMORY) != 0)
+ return 0;
+ return fflush (bfd_cache_lookup(abfd));
+}
+
+/* Returns 0 for success, negative value for failure (in which case
+ bfd_get_error can retrieve the error code). */
+int
+bfd_stat (bfd *abfd, struct stat *statbuf)
+{
+ FILE *f;
+ int result;
+
+ if ((abfd->flags & BFD_IN_MEMORY) != 0)
+ abort ();
+
+ f = bfd_cache_lookup (abfd);
+ if (f == NULL)
+ {
+ bfd_set_error (bfd_error_system_call);
+ return -1;
+ }
+ result = fstat (fileno (f), statbuf);
+ if (result < 0)
+ bfd_set_error (bfd_error_system_call);
+ return result;
+}
+
+/* Returns 0 for success, nonzero for failure (in which case bfd_get_error
+ can retrieve the error code). */
+
+int
+bfd_seek (bfd *abfd, file_ptr position, int direction)
+{
+ int result;
+ FILE *f;
+ file_ptr file_position;
+ /* For the time being, a BFD may not seek to it's end. The problem
+ is that we don't easily have a way to recognize the end of an
+ element in an archive. */
+
+ BFD_ASSERT (direction == SEEK_SET || direction == SEEK_CUR);
+
+ if (direction == SEEK_CUR && position == 0)
+ return 0;
+
+ if ((abfd->flags & BFD_IN_MEMORY) != 0)
+ {
+ struct bfd_in_memory *bim;
+
+ bim = abfd->iostream;
+
+ if (direction == SEEK_SET)
+ abfd->where = position;
+ else
+ abfd->where += position;
+
+ if (abfd->where > bim->size)
+ {
+ if ((abfd->direction == write_direction) ||
+ (abfd->direction == both_direction))
+ {
+ bfd_size_type newsize, oldsize;
+ oldsize = (bim->size + 127) & ~(bfd_size_type) 127;
+ bim->size = abfd->where;
+ /* Round up to cut down on memory fragmentation */
+ newsize = (bim->size + 127) & ~(bfd_size_type) 127;
+ if (newsize > oldsize)
+ {
+ bim->buffer = bfd_realloc (bim->buffer, newsize);
+ if (bim->buffer == 0)
+ {
+ bim->size = 0;
+ return -1;
+ }
+ }
+ }
+ else
+ {
+ abfd->where = bim->size;
+ bfd_set_error (bfd_error_file_truncated);
+ return -1;
+ }
+ }
+ return 0;
+ }
+
+ if (abfd->format != bfd_archive && abfd->my_archive == 0)
+ {
+#if 0
+ /* Explanation for this code: I'm only about 95+% sure that the above
+ conditions are sufficient and that all i/o calls are properly
+ adjusting the `where' field. So this is sort of an `assert'
+ that the `where' field is correct. If we can go a while without
+ tripping the abort, we can probably safely disable this code,
+ so that the real optimizations happen. */
+ file_ptr where_am_i_now;
+ where_am_i_now = real_ftell (bfd_cache_lookup (abfd));
+ if (abfd->my_archive)
+ where_am_i_now -= abfd->origin;
+ if (where_am_i_now != abfd->where)
+ abort ();
+#endif
+ if (direction == SEEK_SET && (bfd_vma) position == abfd->where)
+ return 0;
+ }
+ else
+ {
+ /* We need something smarter to optimize access to archives.
+ Currently, anything inside an archive is read via the file
+ handle for the archive. Which means that a bfd_seek on one
+ component affects the `current position' in the archive, as
+ well as in any other component.
+
+ It might be sufficient to put a spike through the cache
+ abstraction, and look to the archive for the file position,
+ but I think we should try for something cleaner.
+
+ In the meantime, no optimization for archives. */
+ }
+
+ f = bfd_cache_lookup (abfd);
+ file_position = position;
+ if (direction == SEEK_SET && abfd->my_archive != NULL)
+ file_position += abfd->origin;
+
+ result = real_fseek (f, file_position, direction);
+ if (result != 0)
+ {
+ int hold_errno = errno;
+
+ /* Force redetermination of `where' field. */
+ bfd_tell (abfd);
+
+ /* An EINVAL error probably means that the file offset was
+ absurd. */
+ if (hold_errno == EINVAL)
+ bfd_set_error (bfd_error_file_truncated);
+ else
+ {
+ bfd_set_error (bfd_error_system_call);
+ errno = hold_errno;
+ }
+ }
+ else
+ {
+ /* Adjust `where' field. */
+ if (direction == SEEK_SET)
+ abfd->where = position;
+ else
+ abfd->where += position;
+ }
+ return result;
+}
+
+/*
+FUNCTION
+ bfd_get_mtime
+
+SYNOPSIS
+ long bfd_get_mtime (bfd *abfd);
+
+DESCRIPTION
+ Return the file modification time (as read from the file system, or
+ from the archive header for archive members).
+
+*/
+
+long
+bfd_get_mtime (bfd *abfd)
+{
+ FILE *fp;
+ struct stat buf;
+
+ if (abfd->mtime_set)
+ return abfd->mtime;
+
+ fp = bfd_cache_lookup (abfd);
+ if (0 != fstat (fileno (fp), &buf))
+ return 0;
+
+ abfd->mtime = buf.st_mtime; /* Save value in case anyone wants it */
+ return buf.st_mtime;
+}
+
+/*
+FUNCTION
+ bfd_get_size
+
+SYNOPSIS
+ long bfd_get_size (bfd *abfd);
+
+DESCRIPTION
+ Return the file size (as read from file system) for the file
+ associated with BFD @var{abfd}.
+
+ The initial motivation for, and use of, this routine is not
+ so we can get the exact size of the object the BFD applies to, since
+ that might not be generally possible (archive members for example).
+ It would be ideal if someone could eventually modify
+ it so that such results were guaranteed.
+
+ Instead, we want to ask questions like "is this NNN byte sized
+ object I'm about to try read from file offset YYY reasonable?"
+ As as example of where we might do this, some object formats
+ use string tables for which the first <<sizeof (long)>> bytes of the
+ table contain the size of the table itself, including the size bytes.
+ If an application tries to read what it thinks is one of these
+ string tables, without some way to validate the size, and for
+ some reason the size is wrong (byte swapping error, wrong location
+ for the string table, etc.), the only clue is likely to be a read
+ error when it tries to read the table, or a "virtual memory
+ exhausted" error when it tries to allocate 15 bazillon bytes
+ of space for the 15 bazillon byte table it is about to read.
+ This function at least allows us to answer the question, "is the
+ size reasonable?".
+*/
+
+long
+bfd_get_size (bfd *abfd)
+{
+ FILE *fp;
+ struct stat buf;
+
+ if ((abfd->flags & BFD_IN_MEMORY) != 0)
+ return ((struct bfd_in_memory *) abfd->iostream)->size;
+
+ fp = bfd_cache_lookup (abfd);
+ if (0 != fstat (fileno (fp), & buf))
+ return 0;
+
+ return buf.st_size;
+}
diff --git a/contrib/binutils/bfd/bfdwin.c b/contrib/binutils/bfd/bfdwin.c
new file mode 100644
index 0000000..fb7c967
--- /dev/null
+++ b/contrib/binutils/bfd/bfdwin.c
@@ -0,0 +1,251 @@
+/* Support for memory-mapped windows into a BFD.
+ Copyright 1995, 1996, 2001, 2002, 2003 Free Software Foundation, Inc.
+ Written by Cygnus Support.
+
+This file is part of BFD, the Binary File Descriptor library.
+
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+#include "sysdep.h"
+
+#include "bfd.h"
+#include "libbfd.h"
+
+/* Currently, if USE_MMAP is undefined, none if the window stuff is
+ used. Okay, so it's mis-named. At least the command-line option
+ "--without-mmap" is more obvious than "--without-windows" or some
+ such. */
+
+#ifdef USE_MMAP
+
+#undef HAVE_MPROTECT /* code's not tested yet */
+
+#if HAVE_MMAP || HAVE_MPROTECT || HAVE_MADVISE
+#include <sys/mman.h>
+#endif
+
+#ifndef MAP_FILE
+#define MAP_FILE 0
+#endif
+
+static int debug_windows;
+
+/* The idea behind the next and refcount fields is that one mapped
+ region can suffice for multiple read-only windows or multiple
+ non-overlapping read-write windows. It's not implemented yet
+ though. */
+
+/*
+INTERNAL_DEFINITION
+
+.struct _bfd_window_internal {
+. struct _bfd_window_internal *next;
+. void *data;
+. bfd_size_type size;
+. int refcount : 31; {* should be enough... *}
+. unsigned mapped : 1; {* 1 = mmap, 0 = malloc *}
+.};
+*/
+
+void
+bfd_init_window (bfd_window *windowp)
+{
+ windowp->data = 0;
+ windowp->i = 0;
+ windowp->size = 0;
+}
+
+void
+bfd_free_window (bfd_window *windowp)
+{
+ bfd_window_internal *i = windowp->i;
+ windowp->i = 0;
+ windowp->data = 0;
+ if (i == 0)
+ return;
+ i->refcount--;
+ if (debug_windows)
+ fprintf (stderr, "freeing window @%p<%p,%lx,%p>\n",
+ windowp, windowp->data, windowp->size, windowp->i);
+ if (i->refcount != 0)
+ return;
+
+ if (i->mapped)
+ {
+#ifdef HAVE_MMAP
+ munmap (i->data, i->size);
+ goto no_free;
+#else
+ abort ();
+#endif
+ }
+#ifdef HAVE_MPROTECT
+ mprotect (i->data, i->size, PROT_READ | PROT_WRITE);
+#endif
+ free (i->data);
+#ifdef HAVE_MMAP
+ no_free:
+#endif
+ i->data = 0;
+ /* There should be no more references to i at this point. */
+ free (i);
+}
+
+static int ok_to_map = 1;
+
+bfd_boolean
+bfd_get_file_window (bfd *abfd,
+ file_ptr offset,
+ bfd_size_type size,
+ bfd_window *windowp,
+ bfd_boolean writable)
+{
+ static size_t pagesize;
+ bfd_window_internal *i = windowp->i;
+ bfd_size_type size_to_alloc = size;
+
+ if (debug_windows)
+ fprintf (stderr, "bfd_get_file_window (%p, %6ld, %6ld, %p<%p,%lx,%p>, %d)",
+ abfd, (long) offset, (long) size,
+ windowp, windowp->data, (unsigned long) windowp->size,
+ windowp->i, writable);
+
+ /* Make sure we know the page size, so we can be friendly to mmap. */
+ if (pagesize == 0)
+ pagesize = getpagesize ();
+ if (pagesize == 0)
+ abort ();
+
+ if (i == 0)
+ {
+ i = bfd_zmalloc (sizeof (bfd_window_internal));
+ windowp->i = i;
+ if (i == 0)
+ return FALSE;
+ i->data = 0;
+ }
+#ifdef HAVE_MMAP
+ if (ok_to_map
+ && (i->data == 0 || i->mapped == 1)
+ && (abfd->flags & BFD_IN_MEMORY) == 0)
+ {
+ file_ptr file_offset, offset2;
+ size_t real_size;
+ int fd;
+ FILE *f;
+
+ /* Find the real file and the real offset into it. */
+ while (abfd->my_archive != NULL)
+ {
+ offset += abfd->origin;
+ abfd = abfd->my_archive;
+ }
+ f = bfd_cache_lookup (abfd);
+ fd = fileno (f);
+
+ /* Compute offsets and size for mmap and for the user's data. */
+ offset2 = offset % pagesize;
+ if (offset2 < 0)
+ abort ();
+ file_offset = offset - offset2;
+ real_size = offset + size - file_offset;
+ real_size = real_size + pagesize - 1;
+ real_size -= real_size % pagesize;
+
+ /* If we're re-using a memory region, make sure it's big enough. */
+ if (i->data && i->size < size)
+ {
+ munmap (i->data, i->size);
+ i->data = 0;
+ }
+ i->data = mmap (i->data, real_size,
+ writable ? PROT_WRITE | PROT_READ : PROT_READ,
+ (writable
+ ? MAP_FILE | MAP_PRIVATE
+ : MAP_FILE | MAP_SHARED),
+ fd, file_offset);
+ if (i->data == (void *) -1)
+ {
+ /* An error happened. Report it, or try using malloc, or
+ something. */
+ bfd_set_error (bfd_error_system_call);
+ i->data = 0;
+ windowp->data = 0;
+ if (debug_windows)
+ fprintf (stderr, "\t\tmmap failed!\n");
+ return FALSE;
+ }
+ if (debug_windows)
+ fprintf (stderr, "\n\tmapped %ld at %p, offset is %ld\n",
+ (long) real_size, i->data, (long) offset2);
+ i->size = real_size;
+ windowp->data = (bfd_byte *) i->data + offset2;
+ windowp->size = size;
+ i->mapped = 1;
+ return TRUE;
+ }
+ else if (debug_windows)
+ {
+ if (ok_to_map)
+ fprintf (stderr, _("not mapping: data=%lx mapped=%d\n"),
+ (unsigned long) i->data, (int) i->mapped);
+ else
+ fprintf (stderr, _("not mapping: env var not set\n"));
+ }
+#else
+ ok_to_map = 0;
+#endif
+
+#ifdef HAVE_MPROTECT
+ if (!writable)
+ {
+ size_to_alloc += pagesize - 1;
+ size_to_alloc -= size_to_alloc % pagesize;
+ }
+#endif
+ if (debug_windows)
+ fprintf (stderr, "\n\t%s(%6ld)",
+ i->data ? "realloc" : " malloc", (long) size_to_alloc);
+ i->data = bfd_realloc (i->data, size_to_alloc);
+ if (debug_windows)
+ fprintf (stderr, "\t-> %p\n", i->data);
+ i->refcount = 1;
+ if (i->data == NULL)
+ {
+ if (size_to_alloc == 0)
+ return TRUE;
+ return FALSE;
+ }
+ if (bfd_seek (abfd, offset, SEEK_SET) != 0)
+ return FALSE;
+ i->size = bfd_bread (i->data, size, abfd);
+ if (i->size != size)
+ return FALSE;
+ i->mapped = 0;
+#ifdef HAVE_MPROTECT
+ if (!writable)
+ {
+ if (debug_windows)
+ fprintf (stderr, "\tmprotect (%p, %ld, PROT_READ)\n", i->data,
+ (long) i->size);
+ mprotect (i->data, i->size, PROT_READ);
+ }
+#endif
+ windowp->data = i->data;
+ windowp->size = i->size;
+ return TRUE;
+}
+
+#endif /* USE_MMAP */
diff --git a/contrib/binutils/bfd/binary.c b/contrib/binutils/bfd/binary.c
index 7bddabf..65f46af 100644
--- a/contrib/binutils/bfd/binary.c
+++ b/contrib/binutils/bfd/binary.c
@@ -1,23 +1,23 @@
/* BFD back-end for binary objects.
- Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
+ Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support, <ian@cygnus.com>
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* This is a BFD backend which may be used to write binary objects.
It may only be used for output, not input. The intention is that
@@ -41,29 +41,30 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
a start symbol, an end symbol, and an absolute length symbol. */
#define BIN_SYMS 3
-static boolean binary_mkobject PARAMS ((bfd *));
+static bfd_boolean binary_mkobject PARAMS ((bfd *));
static const bfd_target *binary_object_p PARAMS ((bfd *));
-static boolean binary_get_section_contents
+static bfd_boolean binary_get_section_contents
PARAMS ((bfd *, asection *, PTR, file_ptr, bfd_size_type));
static long binary_get_symtab_upper_bound PARAMS ((bfd *));
static char *mangle_name PARAMS ((bfd *, char *));
-static long binary_get_symtab PARAMS ((bfd *, asymbol **));
+static long binary_canonicalize_symtab PARAMS ((bfd *, asymbol **));
static void binary_get_symbol_info PARAMS ((bfd *, asymbol *, symbol_info *));
-static boolean binary_set_section_contents
- PARAMS ((bfd *, asection *, PTR, file_ptr, bfd_size_type));
-static int binary_sizeof_headers PARAMS ((bfd *, boolean));
+static bfd_boolean binary_set_section_contents
+ PARAMS ((bfd *, asection *, const PTR, file_ptr, bfd_size_type));
+static int binary_sizeof_headers PARAMS ((bfd *, bfd_boolean));
-/* Set by external programs - specifies the BFD architecture
- to use when creating binary BFDs. */
-enum bfd_architecture bfd_external_binary_architecture = bfd_arch_unknown;
+/* Set by external programs - specifies the BFD architecture and
+ machine number to be uses when creating binary BFDs. */
+enum bfd_architecture bfd_external_binary_architecture = bfd_arch_unknown;
+unsigned long bfd_external_machine = 0;
/* Create a binary object. Invoked via bfd_set_format. */
-static boolean
+static bfd_boolean
binary_mkobject (abfd)
bfd *abfd ATTRIBUTE_UNUSED;
{
- return true;
+ return TRUE;
}
/* Any file may be considered to be a binary file, provided the target
@@ -107,7 +108,8 @@ binary_object_p (abfd)
{
if ((bfd_get_arch_info (abfd)->arch == bfd_arch_unknown)
&& (bfd_external_binary_architecture != bfd_arch_unknown))
- bfd_set_arch_info (abfd, bfd_lookup_arch (bfd_external_binary_architecture, 0));
+ bfd_set_arch_info (abfd, bfd_lookup_arch
+ (bfd_external_binary_architecture, bfd_external_machine));
}
return abfd->xvec;
@@ -119,7 +121,7 @@ binary_object_p (abfd)
/* Get contents of the only section. */
-static boolean
+static bfd_boolean
binary_get_section_contents (abfd, section, location, offset, count)
bfd *abfd;
asection *section ATTRIBUTE_UNUSED;
@@ -129,8 +131,8 @@ binary_get_section_contents (abfd, section, location, offset, count)
{
if (bfd_seek (abfd, offset, SEEK_SET) != 0
|| bfd_bread (location, count, abfd) != count)
- return false;
- return true;
+ return FALSE;
+ return TRUE;
}
/* Return the amount of memory needed to read the symbol table. */
@@ -174,7 +176,7 @@ mangle_name (abfd, suffix)
/* Return the symbol table. */
static long
-binary_get_symtab (abfd, alocation)
+binary_canonicalize_symtab (abfd, alocation)
bfd *abfd;
asymbol **alocation;
{
@@ -185,7 +187,7 @@ binary_get_symtab (abfd, alocation)
syms = (asymbol *) bfd_alloc (abfd, amt);
if (syms == NULL)
- return (long) false;
+ return 0;
/* Start symbol. */
syms[0].the_bfd = abfd;
@@ -250,27 +252,27 @@ binary_get_symbol_info (ignore_abfd, symbol, ret)
/* Write section contents of a binary file. */
-static boolean
+static bfd_boolean
binary_set_section_contents (abfd, sec, data, offset, size)
bfd *abfd;
asection *sec;
- PTR data;
+ const PTR data;
file_ptr offset;
bfd_size_type size;
{
if (size == 0)
- return true;
+ return TRUE;
if (! abfd->output_has_begun)
{
- boolean found_low;
+ bfd_boolean found_low;
bfd_vma low;
asection *s;
/* The lowest section LMA sets the virtual address of the start
of the file. We use this to set the file position of all the
sections. */
- found_low = false;
+ found_low = FALSE;
low = 0;
for (s = abfd->sections; s != NULL; s = s->next)
if (((s->flags
@@ -280,7 +282,7 @@ binary_set_section_contents (abfd, sec, data, offset, size)
&& (! found_low || s->lma < low))
{
low = s->lma;
- found_low = true;
+ found_low = TRUE;
}
for (s = abfd->sections; s != NULL; s = s->next)
@@ -308,16 +310,16 @@ binary_set_section_contents (abfd, sec, data, offset, size)
(unsigned long) s->filepos);
}
- abfd->output_has_begun = true;
+ abfd->output_has_begun = TRUE;
}
/* We don't want to output anything for a section that is neither
loaded nor allocated. The contents of such a section are not
meaningful in the binary format. */
if ((sec->flags & (SEC_LOAD | SEC_ALLOC)) == 0)
- return true;
+ return TRUE;
if ((sec->flags & SEC_NEVER_LOAD) != 0)
- return true;
+ return TRUE;
return _bfd_generic_set_section_contents (abfd, sec, data, offset, size);
}
@@ -327,7 +329,7 @@ binary_set_section_contents (abfd, sec, data, offset, size)
static int
binary_sizeof_headers (abfd, exec)
bfd *abfd ATTRIBUTE_UNUSED;
- boolean exec ATTRIBUTE_UNUSED;
+ bfd_boolean exec ATTRIBUTE_UNUSED;
{
return 0;
}
diff --git a/contrib/binutils/bfd/bout.c b/contrib/binutils/bfd/bout.c
new file mode 100644
index 0000000..a39a9a3
--- /dev/null
+++ b/contrib/binutils/bfd/bout.c
@@ -0,0 +1,1579 @@
+/* BFD back-end for Intel 960 b.out binaries.
+ Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
+ 2000, 2001, 2002, 2003
+ Free Software Foundation, Inc.
+ Written by Cygnus Support.
+
+This file is part of BFD, the Binary File Descriptor library.
+
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+#include "bfd.h"
+#include "sysdep.h"
+#include "libbfd.h"
+#include "bfdlink.h"
+#include "genlink.h"
+#include "bout.h"
+
+#include "aout/stab_gnu.h"
+#include "libaout.h" /* BFD a.out internal data structures. */
+
+static int aligncode
+ PARAMS ((bfd *abfd, asection *input_section, arelent *r,
+ unsigned int shrink));
+static void perform_slip
+ PARAMS ((bfd *abfd, unsigned int slip, asection *input_section,
+ bfd_vma value));
+static bfd_boolean b_out_squirt_out_relocs
+ PARAMS ((bfd *abfd, asection *section));
+static const bfd_target *b_out_callback
+ PARAMS ((bfd *));
+static bfd_reloc_status_type calljx_callback
+ PARAMS ((bfd *, struct bfd_link_info *, arelent *, PTR src, PTR dst,
+ asection *));
+static bfd_reloc_status_type callj_callback
+ PARAMS ((bfd *, struct bfd_link_info *, arelent *, PTR data,
+ unsigned int srcidx, unsigned int dstidx, asection *, bfd_boolean));
+static bfd_vma get_value
+ PARAMS ((arelent *, struct bfd_link_info *, asection *));
+static int abs32code
+ PARAMS ((bfd *, asection *, arelent *, unsigned int,
+ struct bfd_link_info *));
+static bfd_boolean b_out_bfd_relax_section
+ PARAMS ((bfd *, asection *, struct bfd_link_info *, bfd_boolean *));
+static bfd_byte *b_out_bfd_get_relocated_section_contents
+ PARAMS ((bfd *, struct bfd_link_info *, struct bfd_link_order *, bfd_byte *,
+ bfd_boolean, asymbol **));
+static int b_out_sizeof_headers
+ PARAMS ((bfd *, bfd_boolean));
+static bfd_boolean b_out_set_arch_mach
+ PARAMS ((bfd *, enum bfd_architecture, unsigned long));
+static bfd_boolean b_out_set_section_contents
+ PARAMS ((bfd *, asection *, const PTR, file_ptr, bfd_size_type));
+static long b_out_get_reloc_upper_bound
+ PARAMS ((bfd *, sec_ptr));
+static long b_out_canonicalize_reloc
+ PARAMS ((bfd *, sec_ptr, arelent **, asymbol **));
+static bfd_boolean b_out_slurp_reloc_table
+ PARAMS ((bfd *, sec_ptr, asymbol **));
+static reloc_howto_type *b_out_bfd_reloc_type_lookup
+ PARAMS ((bfd *, bfd_reloc_code_real_type));
+static bfd_boolean b_out_write_object_contents
+ PARAMS ((bfd *));
+static int b_out_symbol_cmp
+ PARAMS ((const void *, const void *));
+static bfd_boolean b_out_mkobject
+ PARAMS ((bfd *));
+static const bfd_target *b_out_object_p
+ PARAMS ((bfd *));
+
+void bout_swap_exec_header_in
+ PARAMS ((bfd *, struct external_exec *, struct internal_exec *));
+void bout_swap_exec_header_out
+ PARAMS ((bfd *, struct internal_exec *, struct external_exec *));
+
+/* Swaps the information in an executable header taken from a raw byte
+ stream memory image, into the internal exec_header structure. */
+
+void
+bout_swap_exec_header_in (abfd, raw_bytes, execp)
+ bfd *abfd;
+ struct external_exec *raw_bytes;
+ struct internal_exec *execp;
+{
+ struct external_exec *bytes = (struct external_exec *)raw_bytes;
+
+ /* Now fill in fields in the execp, from the bytes in the raw data. */
+ execp->a_info = H_GET_32 (abfd, bytes->e_info);
+ execp->a_text = GET_WORD (abfd, bytes->e_text);
+ execp->a_data = GET_WORD (abfd, bytes->e_data);
+ execp->a_bss = GET_WORD (abfd, bytes->e_bss);
+ execp->a_syms = GET_WORD (abfd, bytes->e_syms);
+ execp->a_entry = GET_WORD (abfd, bytes->e_entry);
+ execp->a_trsize = GET_WORD (abfd, bytes->e_trsize);
+ execp->a_drsize = GET_WORD (abfd, bytes->e_drsize);
+ execp->a_tload = GET_WORD (abfd, bytes->e_tload);
+ execp->a_dload = GET_WORD (abfd, bytes->e_dload);
+ execp->a_talign = bytes->e_talign[0];
+ execp->a_dalign = bytes->e_dalign[0];
+ execp->a_balign = bytes->e_balign[0];
+ execp->a_relaxable = bytes->e_relaxable[0];
+}
+
+/* Swaps the information in an internal exec header structure into the
+ supplied buffer ready for writing to disk. */
+
+void
+bout_swap_exec_header_out (abfd, execp, raw_bytes)
+ bfd *abfd;
+ struct internal_exec *execp;
+ struct external_exec *raw_bytes;
+{
+ struct external_exec *bytes = (struct external_exec *)raw_bytes;
+
+ /* Now fill in fields in the raw data, from the fields in the exec struct. */
+ H_PUT_32 (abfd, execp->a_info , bytes->e_info);
+ PUT_WORD (abfd, execp->a_text , bytes->e_text);
+ PUT_WORD (abfd, execp->a_data , bytes->e_data);
+ PUT_WORD (abfd, execp->a_bss , bytes->e_bss);
+ PUT_WORD (abfd, execp->a_syms , bytes->e_syms);
+ PUT_WORD (abfd, execp->a_entry , bytes->e_entry);
+ PUT_WORD (abfd, execp->a_trsize, bytes->e_trsize);
+ PUT_WORD (abfd, execp->a_drsize, bytes->e_drsize);
+ PUT_WORD (abfd, execp->a_tload , bytes->e_tload);
+ PUT_WORD (abfd, execp->a_dload , bytes->e_dload);
+ bytes->e_talign[0] = execp->a_talign;
+ bytes->e_dalign[0] = execp->a_dalign;
+ bytes->e_balign[0] = execp->a_balign;
+ bytes->e_relaxable[0] = execp->a_relaxable;
+}
+
+static const bfd_target *
+b_out_object_p (abfd)
+ bfd *abfd;
+{
+ struct internal_exec anexec;
+ struct external_exec exec_bytes;
+ bfd_size_type amt = EXEC_BYTES_SIZE;
+
+ if (bfd_bread ((PTR) &exec_bytes, amt, abfd) != amt)
+ {
+ if (bfd_get_error () != bfd_error_system_call)
+ bfd_set_error (bfd_error_wrong_format);
+ return 0;
+ }
+
+ anexec.a_info = H_GET_32 (abfd, exec_bytes.e_info);
+
+ if (N_BADMAG (anexec))
+ {
+ bfd_set_error (bfd_error_wrong_format);
+ return 0;
+ }
+
+ bout_swap_exec_header_in (abfd, &exec_bytes, &anexec);
+ return aout_32_some_aout_object_p (abfd, &anexec, b_out_callback);
+}
+
+/* Finish up the opening of a b.out file for reading. Fill in all the
+ fields that are not handled by common code. */
+
+static const bfd_target *
+b_out_callback (abfd)
+ bfd *abfd;
+{
+ struct internal_exec *execp = exec_hdr (abfd);
+ unsigned long bss_start;
+
+ /* Architecture and machine type. */
+ bfd_set_arch_mach(abfd,
+ bfd_arch_i960, /* B.out only used on i960 */
+ bfd_mach_i960_core /* Default */
+ );
+
+ /* The positions of the string table and symbol table. */
+ obj_str_filepos (abfd) = N_STROFF (*execp);
+ obj_sym_filepos (abfd) = N_SYMOFF (*execp);
+
+ /* The alignments of the sections. */
+ obj_textsec (abfd)->alignment_power = execp->a_talign;
+ obj_datasec (abfd)->alignment_power = execp->a_dalign;
+ obj_bsssec (abfd)->alignment_power = execp->a_balign;
+
+ /* The starting addresses of the sections. */
+ obj_textsec (abfd)->vma = execp->a_tload;
+ obj_datasec (abfd)->vma = execp->a_dload;
+
+ obj_textsec (abfd)->lma = obj_textsec (abfd)->vma;
+ obj_datasec (abfd)->lma = obj_datasec (abfd)->vma;
+
+ /* And reload the sizes, since the aout module zaps them. */
+ obj_textsec (abfd)->_raw_size = execp->a_text;
+
+ bss_start = execp->a_dload + execp->a_data; /* BSS = end of data section */
+ obj_bsssec (abfd)->vma = align_power (bss_start, execp->a_balign);
+
+ obj_bsssec (abfd)->lma = obj_bsssec (abfd)->vma;
+
+ /* The file positions of the sections. */
+ obj_textsec (abfd)->filepos = N_TXTOFF(*execp);
+ obj_datasec (abfd)->filepos = N_DATOFF(*execp);
+
+ /* The file positions of the relocation info. */
+ obj_textsec (abfd)->rel_filepos = N_TROFF(*execp);
+ obj_datasec (abfd)->rel_filepos = N_DROFF(*execp);
+
+ adata(abfd).page_size = 1; /* Not applicable. */
+ adata(abfd).segment_size = 1; /* Not applicable. */
+ adata(abfd).exec_bytes_size = EXEC_BYTES_SIZE;
+
+ if (execp->a_relaxable)
+ abfd->flags |= BFD_IS_RELAXABLE;
+ return abfd->xvec;
+}
+
+struct bout_data_struct
+ {
+ struct aoutdata a;
+ struct internal_exec e;
+ };
+
+static bfd_boolean
+b_out_mkobject (abfd)
+ bfd *abfd;
+{
+ struct bout_data_struct *rawptr;
+ bfd_size_type amt = sizeof (struct bout_data_struct);
+
+ rawptr = (struct bout_data_struct *) bfd_zalloc (abfd, amt);
+ if (rawptr == NULL)
+ return FALSE;
+
+ abfd->tdata.bout_data = rawptr;
+ exec_hdr (abfd) = &rawptr->e;
+
+ obj_textsec (abfd) = (asection *) NULL;
+ obj_datasec (abfd) = (asection *) NULL;
+ obj_bsssec (abfd) = (asection *) NULL;
+
+ return TRUE;
+}
+
+static int
+b_out_symbol_cmp (a_ptr, b_ptr)
+ const void * a_ptr;
+ const void * b_ptr;
+{
+ struct aout_symbol ** a = (struct aout_symbol **) a_ptr;
+ struct aout_symbol ** b = (struct aout_symbol **) b_ptr;
+ asection *sec;
+ bfd_vma av, bv;
+
+ /* Primary key is address. */
+ sec = bfd_get_section (&(*a)->symbol);
+ av = sec->output_section->vma + sec->output_offset + (*a)->symbol.value;
+ sec = bfd_get_section (&(*b)->symbol);
+ bv = sec->output_section->vma + sec->output_offset + (*b)->symbol.value;
+
+ if (av < bv)
+ return -1;
+ if (av > bv)
+ return 1;
+
+ /* Secondary key puts CALLNAME syms last and BALNAME syms first, so
+ that they have the best chance of being contiguous. */
+ if (IS_BALNAME ((*a)->other) || IS_CALLNAME ((*b)->other))
+ return -1;
+ if (IS_CALLNAME ((*a)->other) || IS_BALNAME ((*b)->other))
+ return 1;
+
+ return 0;
+}
+
+static bfd_boolean
+b_out_write_object_contents (abfd)
+ bfd *abfd;
+{
+ struct external_exec swapped_hdr;
+ bfd_size_type amt;
+
+ if (! aout_32_make_sections (abfd))
+ return FALSE;
+
+ exec_hdr (abfd)->a_info = BMAGIC;
+
+ exec_hdr (abfd)->a_text = obj_textsec (abfd)->_raw_size;
+ exec_hdr (abfd)->a_data = obj_datasec (abfd)->_raw_size;
+ exec_hdr (abfd)->a_bss = obj_bsssec (abfd)->_raw_size;
+ exec_hdr (abfd)->a_syms = bfd_get_symcount (abfd) * sizeof (struct nlist);
+ exec_hdr (abfd)->a_entry = bfd_get_start_address (abfd);
+ exec_hdr (abfd)->a_trsize = ((obj_textsec (abfd)->reloc_count) *
+ sizeof (struct relocation_info));
+ exec_hdr (abfd)->a_drsize = ((obj_datasec (abfd)->reloc_count) *
+ sizeof (struct relocation_info));
+
+ exec_hdr (abfd)->a_talign = obj_textsec (abfd)->alignment_power;
+ exec_hdr (abfd)->a_dalign = obj_datasec (abfd)->alignment_power;
+ exec_hdr (abfd)->a_balign = obj_bsssec (abfd)->alignment_power;
+
+ exec_hdr (abfd)->a_tload = obj_textsec (abfd)->vma;
+ exec_hdr (abfd)->a_dload = obj_datasec (abfd)->vma;
+
+ bout_swap_exec_header_out (abfd, exec_hdr (abfd), &swapped_hdr);
+
+ amt = EXEC_BYTES_SIZE;
+ if (bfd_seek (abfd, (file_ptr) 0, SEEK_SET) != 0
+ || bfd_bwrite ((PTR) &swapped_hdr, amt, abfd) != amt)
+ return FALSE;
+
+ /* Now write out reloc info, followed by syms and strings */
+ if (bfd_get_symcount (abfd) != 0)
+ {
+ /* Make sure {CALL,BAL}NAME symbols remain adjacent on output
+ by sorting. This is complicated by the fact that stabs are
+ also ordered. Solve this by shifting all stabs to the end
+ in order, then sorting the rest. */
+
+ asymbol **outsyms, **p, **q;
+
+ outsyms = bfd_get_outsymbols (abfd);
+ p = outsyms + bfd_get_symcount (abfd);
+
+ for (q = p--; p >= outsyms; p--)
+ {
+ if ((*p)->flags & BSF_DEBUGGING)
+ {
+ asymbol *t = *--q;
+ *q = *p;
+ *p = t;
+ }
+ }
+
+ if (q > outsyms)
+ qsort (outsyms, (size_t) (q - outsyms), sizeof (asymbol*),
+ b_out_symbol_cmp);
+
+ /* Back to your regularly scheduled program. */
+ if (bfd_seek (abfd, (file_ptr) (N_SYMOFF(*exec_hdr(abfd))), SEEK_SET)
+ != 0)
+ return FALSE;
+
+ if (! aout_32_write_syms (abfd))
+ return FALSE;
+
+ if (bfd_seek (abfd, (file_ptr) (N_TROFF(*exec_hdr(abfd))), SEEK_SET)
+ != 0)
+ return FALSE;
+
+ if (!b_out_squirt_out_relocs (abfd, obj_textsec (abfd)))
+ return FALSE;
+ if (bfd_seek (abfd, (file_ptr) (N_DROFF(*exec_hdr(abfd))), SEEK_SET)
+ != 0)
+ return FALSE;
+
+ if (!b_out_squirt_out_relocs (abfd, obj_datasec (abfd)))
+ return FALSE;
+ }
+ return TRUE;
+}
+
+/* Some reloc hackery. */
+
+#define CALLS 0x66003800 /* Template for 'calls' instruction */
+#define BAL 0x0b000000 /* Template for 'bal' instruction */
+#define BAL_MASK 0x00ffffff
+#define BALX 0x85f00000 /* Template for 'balx' instruction */
+#define BALX_MASK 0x0007ffff
+#define CALL 0x09000000
+#define PCREL13_MASK 0x1fff
+
+#define output_addr(sec) ((sec)->output_offset+(sec)->output_section->vma)
+
+/* Magic to turn callx into calljx. */
+
+static bfd_reloc_status_type
+calljx_callback (abfd, link_info, reloc_entry, src, dst, input_section)
+ bfd *abfd;
+ struct bfd_link_info *link_info;
+ arelent *reloc_entry;
+ PTR src;
+ PTR dst;
+ asection *input_section;
+{
+ int word = bfd_get_32 (abfd, src);
+ asymbol *symbol_in = *(reloc_entry->sym_ptr_ptr);
+ aout_symbol_type *symbol = aout_symbol (symbol_in);
+ bfd_vma value;
+
+ value = get_value (reloc_entry, link_info, input_section);
+
+ if (IS_CALLNAME (symbol->other))
+ {
+ aout_symbol_type *balsym = symbol+1;
+ int inst = bfd_get_32 (abfd, (bfd_byte *) src-4);
+ /* The next symbol should be an N_BALNAME. */
+ BFD_ASSERT (IS_BALNAME (balsym->other));
+ inst &= BALX_MASK;
+ inst |= BALX;
+ bfd_put_32 (abfd, (bfd_vma) inst, (bfd_byte *) dst-4);
+ symbol = balsym;
+ value = (symbol->symbol.value
+ + output_addr (symbol->symbol.section));
+ }
+
+ word += value + reloc_entry->addend;
+
+ bfd_put_32 (abfd, (bfd_vma) word, dst);
+ return bfd_reloc_ok;
+}
+
+/* Magic to turn call into callj. */
+
+static bfd_reloc_status_type
+callj_callback (abfd, link_info, reloc_entry, data, srcidx, dstidx,
+ input_section, shrinking)
+ bfd *abfd;
+ struct bfd_link_info *link_info;
+ arelent *reloc_entry;
+ PTR data;
+ unsigned int srcidx;
+ unsigned int dstidx;
+ asection *input_section;
+ bfd_boolean shrinking;
+{
+ int word = bfd_get_32 (abfd, (bfd_byte *) data + srcidx);
+ asymbol *symbol_in = *(reloc_entry->sym_ptr_ptr);
+ aout_symbol_type *symbol = aout_symbol (symbol_in);
+ bfd_vma value;
+
+ value = get_value (reloc_entry, link_info, input_section);
+
+ if (IS_OTHER(symbol->other))
+ {
+ /* Call to a system procedure - replace code with system
+ procedure number. */
+ word = CALLS | (symbol->other - 1);
+ }
+ else if (IS_CALLNAME(symbol->other))
+ {
+ aout_symbol_type *balsym = symbol+1;
+
+ /* The next symbol should be an N_BALNAME. */
+ BFD_ASSERT(IS_BALNAME(balsym->other));
+
+ /* We are calling a leaf, so replace the call instruction with a
+ bal. */
+ word = BAL | ((word
+ + output_addr (balsym->symbol.section)
+ + balsym->symbol.value + reloc_entry->addend
+ - dstidx
+ - output_addr (input_section))
+ & BAL_MASK);
+ }
+ else if ((symbol->symbol.flags & BSF_SECTION_SYM) != 0)
+ {
+ /* A callj against a symbol in the same section is a fully
+ resolved relative call. We don't need to do anything here.
+ If the symbol is not in the same section, I'm not sure what
+ to do; fortunately, this case will probably never arise. */
+ BFD_ASSERT (! shrinking);
+ BFD_ASSERT (symbol->symbol.section == input_section);
+ }
+ else
+ {
+ word = CALL | (((word & BAL_MASK)
+ + value
+ + reloc_entry->addend
+ - (shrinking ? dstidx : 0)
+ - output_addr (input_section))
+ & BAL_MASK);
+ }
+ bfd_put_32 (abfd, (bfd_vma) word, (bfd_byte *) data + dstidx);
+ return bfd_reloc_ok;
+}
+
+/* type rshift size bitsize pcrel bitpos absolute overflow check*/
+
+#define ABS32CODE 0
+#define ABS32CODE_SHRUNK 1
+#define PCREL24 2
+#define CALLJ 3
+#define ABS32 4
+#define PCREL13 5
+#define ABS32_MAYBE_RELAXABLE 1
+#define ABS32_WAS_RELAXABLE 2
+
+#define ALIGNER 10
+#define ALIGNDONE 11
+static reloc_howto_type howto_reloc_callj =
+HOWTO(CALLJ, 0, 2, 24, TRUE, 0, complain_overflow_signed, 0,"callj", TRUE, 0x00ffffff, 0x00ffffff,FALSE);
+static reloc_howto_type howto_reloc_abs32 =
+HOWTO(ABS32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,0,"abs32", TRUE, 0xffffffff,0xffffffff,FALSE);
+static reloc_howto_type howto_reloc_pcrel24 =
+HOWTO(PCREL24, 0, 2, 24, TRUE, 0, complain_overflow_signed,0,"pcrel24", TRUE, 0x00ffffff,0x00ffffff,FALSE);
+
+static reloc_howto_type howto_reloc_pcrel13 =
+HOWTO(PCREL13, 0, 2, 13, TRUE, 0, complain_overflow_signed,0,"pcrel13", TRUE, 0x00001fff,0x00001fff,FALSE);
+
+static reloc_howto_type howto_reloc_abs32codeshrunk =
+HOWTO(ABS32CODE_SHRUNK, 0, 2, 24, TRUE, 0, complain_overflow_signed, 0,"callx->callj", TRUE, 0x00ffffff, 0x00ffffff,FALSE);
+
+static reloc_howto_type howto_reloc_abs32code =
+HOWTO(ABS32CODE, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,0,"callx", TRUE, 0xffffffff,0xffffffff,FALSE);
+
+static reloc_howto_type howto_align_table[] = {
+ HOWTO (ALIGNER, 0, 0x1, 0, FALSE, 0, complain_overflow_dont, 0, "align16", FALSE, 0, 0, FALSE),
+ HOWTO (ALIGNER, 0, 0x3, 0, FALSE, 0, complain_overflow_dont, 0, "align32", FALSE, 0, 0, FALSE),
+ HOWTO (ALIGNER, 0, 0x7, 0, FALSE, 0, complain_overflow_dont, 0, "align64", FALSE, 0, 0, FALSE),
+ HOWTO (ALIGNER, 0, 0xf, 0, FALSE, 0, complain_overflow_dont, 0, "align128", FALSE, 0, 0, FALSE),
+};
+
+static reloc_howto_type howto_done_align_table[] = {
+ HOWTO (ALIGNDONE, 0x1, 0x1, 0, FALSE, 0, complain_overflow_dont, 0, "donealign16", FALSE, 0, 0, FALSE),
+ HOWTO (ALIGNDONE, 0x3, 0x3, 0, FALSE, 0, complain_overflow_dont, 0, "donealign32", FALSE, 0, 0, FALSE),
+ HOWTO (ALIGNDONE, 0x7, 0x7, 0, FALSE, 0, complain_overflow_dont, 0, "donealign64", FALSE, 0, 0, FALSE),
+ HOWTO (ALIGNDONE, 0xf, 0xf, 0, FALSE, 0, complain_overflow_dont, 0, "donealign128", FALSE, 0, 0, FALSE),
+};
+
+static reloc_howto_type *
+b_out_bfd_reloc_type_lookup (abfd, code)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ bfd_reloc_code_real_type code;
+{
+ switch (code)
+ {
+ default:
+ return 0;
+ case BFD_RELOC_I960_CALLJ:
+ return &howto_reloc_callj;
+ case BFD_RELOC_32:
+ case BFD_RELOC_CTOR:
+ return &howto_reloc_abs32;
+ case BFD_RELOC_24_PCREL:
+ return &howto_reloc_pcrel24;
+ }
+}
+
+/* Allocate enough room for all the reloc entries, plus pointers to them all. */
+
+static bfd_boolean
+b_out_slurp_reloc_table (abfd, asect, symbols)
+ bfd *abfd;
+ sec_ptr asect;
+ asymbol **symbols;
+{
+ register struct relocation_info *rptr;
+ unsigned int counter;
+ arelent *cache_ptr;
+ int extern_mask, pcrel_mask, callj_mask, length_shift;
+ int incode_mask;
+ int size_mask;
+ bfd_vma prev_addr = 0;
+ unsigned int count;
+ bfd_size_type reloc_size, amt;
+ struct relocation_info *relocs;
+ arelent *reloc_cache;
+
+ if (asect->relocation)
+ return TRUE;
+
+ if (!aout_32_slurp_symbol_table (abfd))
+ return FALSE;
+
+ if (asect == obj_datasec (abfd))
+ {
+ reloc_size = exec_hdr(abfd)->a_drsize;
+ goto doit;
+ }
+
+ if (asect == obj_textsec (abfd))
+ {
+ reloc_size = exec_hdr(abfd)->a_trsize;
+ goto doit;
+ }
+
+ if (asect == obj_bsssec (abfd))
+ {
+ reloc_size = 0;
+ goto doit;
+ }
+
+ bfd_set_error (bfd_error_invalid_operation);
+ return FALSE;
+
+ doit:
+ if (bfd_seek (abfd, asect->rel_filepos, SEEK_SET) != 0)
+ return FALSE;
+ count = reloc_size / sizeof (struct relocation_info);
+
+ relocs = (struct relocation_info *) bfd_malloc (reloc_size);
+ if (!relocs && reloc_size != 0)
+ return FALSE;
+
+ amt = ((bfd_size_type) count + 1) * sizeof (arelent);
+ reloc_cache = (arelent *) bfd_malloc (amt);
+ if (!reloc_cache)
+ {
+ if (relocs != NULL)
+ free (relocs);
+ return FALSE;
+ }
+
+ if (bfd_bread ((PTR) relocs, reloc_size, abfd) != reloc_size)
+ {
+ free (reloc_cache);
+ if (relocs != NULL)
+ free (relocs);
+ return FALSE;
+ }
+
+ if (bfd_header_big_endian (abfd))
+ {
+ /* Big-endian bit field allocation order. */
+ pcrel_mask = 0x80;
+ extern_mask = 0x10;
+ incode_mask = 0x08;
+ callj_mask = 0x02;
+ size_mask = 0x20;
+ length_shift = 5;
+ }
+ else
+ {
+ /* Little-endian bit field allocation order. */
+ pcrel_mask = 0x01;
+ extern_mask = 0x08;
+ incode_mask = 0x10;
+ callj_mask = 0x40;
+ size_mask = 0x02;
+ length_shift = 1;
+ }
+
+ for (rptr = relocs, cache_ptr = reloc_cache, counter = 0;
+ counter < count;
+ counter++, rptr++, cache_ptr++)
+ {
+ unsigned char *raw = (unsigned char *)rptr;
+ unsigned int symnum;
+
+ cache_ptr->address = H_GET_32 (abfd, raw + 0);
+ cache_ptr->howto = 0;
+
+ if (bfd_header_big_endian (abfd))
+ symnum = (raw[4] << 16) | (raw[5] << 8) | raw[6];
+ else
+ symnum = (raw[6] << 16) | (raw[5] << 8) | raw[4];
+
+ if (raw[7] & extern_mask)
+ {
+ /* If this is set then the r_index is an index into the symbol table;
+ if the bit is not set then r_index contains a section map.
+ We either fill in the sym entry with a pointer to the symbol,
+ or point to the correct section. */
+ cache_ptr->sym_ptr_ptr = symbols + symnum;
+ cache_ptr->addend = 0;
+ }
+ else
+ {
+ /* In a.out symbols are relative to the beginning of the
+ file rather than sections ?
+ (look in translate_from_native_sym_flags)
+ The reloc entry addend has added to it the offset into the
+ file of the data, so subtract the base to make the reloc
+ section relative. */
+ int s;
+
+ /* Sign-extend symnum from 24 bits to whatever host uses. */
+ s = symnum;
+ if (s & (1 << 23))
+ s |= (~0) << 24;
+
+ cache_ptr->sym_ptr_ptr = (asymbol **)NULL;
+ switch (s)
+ {
+ case N_TEXT:
+ case N_TEXT | N_EXT:
+ cache_ptr->sym_ptr_ptr = obj_textsec (abfd)->symbol_ptr_ptr;
+ cache_ptr->addend = - obj_textsec (abfd)->vma;
+ break;
+ case N_DATA:
+ case N_DATA | N_EXT:
+ cache_ptr->sym_ptr_ptr = obj_datasec (abfd)->symbol_ptr_ptr;
+ cache_ptr->addend = - obj_datasec (abfd)->vma;
+ break;
+ case N_BSS:
+ case N_BSS | N_EXT:
+ cache_ptr->sym_ptr_ptr = obj_bsssec (abfd)->symbol_ptr_ptr;
+ cache_ptr->addend = - obj_bsssec (abfd)->vma;
+ break;
+ case N_ABS:
+ case N_ABS | N_EXT:
+ cache_ptr->sym_ptr_ptr = obj_bsssec (abfd)->symbol_ptr_ptr;
+ cache_ptr->addend = 0;
+ break;
+ case -2: /* .align */
+ if (raw[7] & pcrel_mask)
+ {
+ cache_ptr->howto = &howto_align_table[(raw[7] >> length_shift) & 3];
+ cache_ptr->sym_ptr_ptr = bfd_abs_section_ptr->symbol_ptr_ptr;
+ }
+ else
+ {
+ /* .org? */
+ abort ();
+ }
+ cache_ptr->addend = 0;
+ break;
+ default:
+ BFD_ASSERT(0);
+ break;
+ }
+ }
+
+ /* The i960 only has a few relocation types:
+ abs 32-bit and pcrel 24bit. except for callj's! */
+ if (cache_ptr->howto != 0)
+ ;
+ else if (raw[7] & callj_mask)
+ {
+ cache_ptr->howto = &howto_reloc_callj;
+ }
+ else if ( raw[7] & pcrel_mask)
+ {
+ if (raw[7] & size_mask)
+ cache_ptr->howto = &howto_reloc_pcrel13;
+ else
+ cache_ptr->howto = &howto_reloc_pcrel24;
+ }
+ else
+ {
+ if (raw[7] & incode_mask)
+ cache_ptr->howto = &howto_reloc_abs32code;
+ else
+ cache_ptr->howto = &howto_reloc_abs32;
+ }
+
+ if (cache_ptr->address < prev_addr)
+ {
+ /* Ouch! this reloc is out of order, insert into the right place. */
+ arelent tmp;
+ arelent *cursor = cache_ptr-1;
+ bfd_vma stop = cache_ptr->address;
+
+ tmp = *cache_ptr;
+ while (cursor->address > stop && cursor >= reloc_cache)
+ {
+ cursor[1] = cursor[0];
+ cursor--;
+ }
+
+ cursor[1] = tmp;
+ }
+ else
+ {
+ prev_addr = cache_ptr->address;
+ }
+ }
+
+ if (relocs != NULL)
+ free (relocs);
+ asect->relocation = reloc_cache;
+ asect->reloc_count = count;
+
+ return TRUE;
+}
+
+static bfd_boolean
+b_out_squirt_out_relocs (abfd, section)
+ bfd *abfd;
+ asection *section;
+{
+ arelent **generic;
+ int r_extern = 0;
+ int r_idx;
+ int incode_mask;
+ int len_1;
+ unsigned int count = section->reloc_count;
+ struct relocation_info *native, *natptr;
+ bfd_size_type natsize;
+ int extern_mask, pcrel_mask, len_2, callj_mask;
+
+ if (count == 0)
+ return TRUE;
+
+ generic = section->orelocation;
+ natsize = (bfd_size_type) count * sizeof (struct relocation_info);
+ native = ((struct relocation_info *) bfd_malloc (natsize));
+ if (!native && natsize != 0)
+ return FALSE;
+
+ if (bfd_header_big_endian (abfd))
+ {
+ /* Big-endian bit field allocation order. */
+ pcrel_mask = 0x80;
+ extern_mask = 0x10;
+ len_2 = 0x40;
+ len_1 = 0x20;
+ callj_mask = 0x02;
+ incode_mask = 0x08;
+ }
+ else
+ {
+ /* Little-endian bit field allocation order. */
+ pcrel_mask = 0x01;
+ extern_mask = 0x08;
+ len_2 = 0x04;
+ len_1 = 0x02;
+ callj_mask = 0x40;
+ incode_mask = 0x10;
+ }
+
+ for (natptr = native; count > 0; --count, ++natptr, ++generic)
+ {
+ arelent *g = *generic;
+ unsigned char *raw = (unsigned char *)natptr;
+ asymbol *sym = *(g->sym_ptr_ptr);
+ asection *output_section = sym->section->output_section;
+
+ H_PUT_32 (abfd, g->address, raw);
+ /* Find a type in the output format which matches the input howto -
+ at the moment we assume input format == output format FIXME!! */
+ r_idx = 0;
+ /* FIXME: Need callj stuff here, and to check the howto entries to
+ be sure they are real for this architecture. */
+ if (g->howto== &howto_reloc_callj)
+ raw[7] = callj_mask + pcrel_mask + len_2;
+ else if (g->howto == &howto_reloc_pcrel24)
+ raw[7] = pcrel_mask + len_2;
+ else if (g->howto == &howto_reloc_pcrel13)
+ raw[7] = pcrel_mask + len_1;
+ else if (g->howto == &howto_reloc_abs32code)
+ raw[7] = len_2 + incode_mask;
+ else if (g->howto >= howto_align_table
+ && g->howto <= (howto_align_table
+ + sizeof (howto_align_table) / sizeof (howto_align_table[0])
+ - 1))
+ {
+ /* symnum == -2; extern_mask not set, pcrel_mask set. */
+ r_idx = -2;
+ r_extern = 0;
+ raw[7] = (pcrel_mask
+ | ((g->howto - howto_align_table) << 1));
+ }
+ else
+ raw[7] = len_2;
+
+ if (r_idx != 0)
+ /* Already mucked with r_extern, r_idx. */;
+ else if (bfd_is_com_section (output_section)
+ || bfd_is_abs_section (output_section)
+ || bfd_is_und_section (output_section))
+ {
+ if (bfd_abs_section_ptr->symbol == sym)
+ {
+ /* Whoops, looked like an abs symbol, but is really an offset
+ from the abs section. */
+ r_idx = 0;
+ r_extern = 0;
+ }
+ else
+ {
+ /* Fill in symbol. */
+ r_extern = 1;
+ r_idx = (*g->sym_ptr_ptr)->udata.i;
+ }
+ }
+ else
+ {
+ /* Just an ordinary section. */
+ r_extern = 0;
+ r_idx = output_section->target_index;
+ }
+
+ if (bfd_header_big_endian (abfd))
+ {
+ raw[4] = (unsigned char) (r_idx >> 16);
+ raw[5] = (unsigned char) (r_idx >> 8);
+ raw[6] = (unsigned char) (r_idx );
+ }
+ else
+ {
+ raw[6] = (unsigned char) (r_idx >> 16);
+ raw[5] = (unsigned char) (r_idx>> 8);
+ raw[4] = (unsigned char) (r_idx );
+ }
+
+ if (r_extern)
+ raw[7] |= extern_mask;
+ }
+
+ if (bfd_bwrite ((PTR) native, natsize, abfd) != natsize)
+ {
+ free ((PTR)native);
+ return FALSE;
+ }
+
+ free ((PTR)native);
+
+ return TRUE;
+}
+
+/* This is stupid. This function should be a boolean predicate. */
+
+static long
+b_out_canonicalize_reloc (abfd, section, relptr, symbols)
+ bfd *abfd;
+ sec_ptr section;
+ arelent **relptr;
+ asymbol **symbols;
+{
+ arelent *tblptr;
+ unsigned int count;
+
+ if ((section->flags & SEC_CONSTRUCTOR) != 0)
+ {
+ arelent_chain *chain = section->constructor_chain;
+
+ for (count = 0; count < section->reloc_count; count++)
+ {
+ *relptr++ = &chain->relent;
+ chain = chain->next;
+ }
+ }
+ else
+ {
+ if (section->relocation == NULL
+ && ! b_out_slurp_reloc_table (abfd, section, symbols))
+ return -1;
+
+ tblptr = section->relocation;
+ for (count = 0; count++ < section->reloc_count;)
+ *relptr++ = tblptr++;
+ }
+
+ *relptr = NULL;
+
+ return section->reloc_count;
+}
+
+static long
+b_out_get_reloc_upper_bound (abfd, asect)
+ bfd *abfd;
+ sec_ptr asect;
+{
+ if (bfd_get_format (abfd) != bfd_object)
+ {
+ bfd_set_error (bfd_error_invalid_operation);
+ return -1;
+ }
+
+ if (asect->flags & SEC_CONSTRUCTOR)
+ return sizeof (arelent *) * (asect->reloc_count + 1);
+
+ if (asect == obj_datasec (abfd))
+ return (sizeof (arelent *) *
+ ((exec_hdr(abfd)->a_drsize / sizeof (struct relocation_info))
+ +1));
+
+ if (asect == obj_textsec (abfd))
+ return (sizeof (arelent *) *
+ ((exec_hdr(abfd)->a_trsize / sizeof (struct relocation_info))
+ +1));
+
+ if (asect == obj_bsssec (abfd))
+ return 0;
+
+ bfd_set_error (bfd_error_invalid_operation);
+ return -1;
+}
+
+
+static bfd_boolean
+b_out_set_section_contents (abfd, section, location, offset, count)
+ bfd *abfd;
+ asection *section;
+ const PTR location;
+ file_ptr offset;
+ bfd_size_type count;
+{
+ if (! abfd->output_has_begun)
+ {
+ /* Set by bfd.c handler. */
+ if (! aout_32_make_sections (abfd))
+ return FALSE;
+
+ obj_textsec (abfd)->filepos = sizeof (struct internal_exec);
+ obj_datasec(abfd)->filepos = obj_textsec(abfd)->filepos
+ + obj_textsec (abfd)->_raw_size;
+ }
+
+ /* Regardless, once we know what we're doing, we might as well get going. */
+ if (bfd_seek (abfd, section->filepos + offset, SEEK_SET) != 0)
+ return FALSE;
+
+ if (count == 0)
+ return TRUE;
+
+ return bfd_bwrite ((PTR) location, count, abfd) == count;
+}
+
+static bfd_boolean
+b_out_set_arch_mach (abfd, arch, machine)
+ bfd *abfd;
+ enum bfd_architecture arch;
+ unsigned long machine;
+{
+ bfd_default_set_arch_mach(abfd, arch, machine);
+
+ if (arch == bfd_arch_unknown) /* Unknown machine arch is OK. */
+ return TRUE;
+
+ if (arch == bfd_arch_i960) /* i960 default is OK. */
+ switch (machine)
+ {
+ case bfd_mach_i960_core:
+ case bfd_mach_i960_kb_sb:
+ case bfd_mach_i960_mc:
+ case bfd_mach_i960_xa:
+ case bfd_mach_i960_ca:
+ case bfd_mach_i960_ka_sa:
+ case bfd_mach_i960_jx:
+ case bfd_mach_i960_hx:
+ case 0:
+ return TRUE;
+ default:
+ return FALSE;
+ }
+
+ return FALSE;
+}
+
+static int
+b_out_sizeof_headers (ignore_abfd, ignore)
+ bfd *ignore_abfd ATTRIBUTE_UNUSED;
+ bfd_boolean ignore ATTRIBUTE_UNUSED;
+{
+ return sizeof (struct internal_exec);
+}
+
+
+static bfd_vma
+get_value (reloc, link_info, input_section)
+ arelent *reloc;
+ struct bfd_link_info *link_info;
+ asection *input_section;
+{
+ bfd_vma value;
+ asymbol *symbol = *(reloc->sym_ptr_ptr);
+
+ /* A symbol holds a pointer to a section, and an offset from the
+ base of the section. To relocate, we find where the section will
+ live in the output and add that in. */
+ if (bfd_is_und_section (symbol->section))
+ {
+ struct bfd_link_hash_entry *h;
+
+ /* The symbol is undefined in this BFD. Look it up in the
+ global linker hash table. FIXME: This should be changed when
+ we convert b.out to use a specific final_link function and
+ change the interface to bfd_relax_section to not require the
+ generic symbols. */
+ h = bfd_wrapped_link_hash_lookup (input_section->owner, link_info,
+ bfd_asymbol_name (symbol),
+ FALSE, FALSE, TRUE);
+ if (h != (struct bfd_link_hash_entry *) NULL
+ && (h->type == bfd_link_hash_defined
+ || h->type == bfd_link_hash_defweak))
+ value = h->u.def.value + output_addr (h->u.def.section);
+ else if (h != (struct bfd_link_hash_entry *) NULL
+ && h->type == bfd_link_hash_common)
+ value = h->u.c.size;
+ else
+ {
+ if (! ((*link_info->callbacks->undefined_symbol)
+ (link_info, bfd_asymbol_name (symbol),
+ input_section->owner, input_section, reloc->address,
+ TRUE)))
+ abort ();
+ value = 0;
+ }
+ }
+ else
+ {
+ value = symbol->value + output_addr (symbol->section);
+ }
+
+ /* Add the value contained in the relocation. */
+ value += reloc->addend;
+
+ return value;
+}
+
+static void
+perform_slip (abfd, slip, input_section, value)
+ bfd *abfd;
+ unsigned int slip;
+ asection *input_section;
+ bfd_vma value;
+{
+ asymbol **s;
+
+ s = _bfd_generic_link_get_symbols (abfd);
+ BFD_ASSERT (s != (asymbol **) NULL);
+
+ /* Find all symbols past this point, and make them know
+ what's happened. */
+ while (*s)
+ {
+ asymbol *p = *s;
+
+ if (p->section == input_section)
+ {
+ /* This was pointing into this section, so mangle it. */
+ if (p->value > value)
+ {
+ p->value -=slip;
+
+ if (p->udata.p != NULL)
+ {
+ struct generic_link_hash_entry *h;
+
+ h = (struct generic_link_hash_entry *) p->udata.p;
+ BFD_ASSERT (h->root.type == bfd_link_hash_defined);
+ h->root.u.def.value -= slip;
+ BFD_ASSERT (h->root.u.def.value == p->value);
+ }
+ }
+ }
+ s++;
+ }
+}
+
+/* This routine works out if the thing we want to get to can be
+ reached with a 24bit offset instead of a 32 bit one.
+ If it can, then it changes the amode. */
+
+static int
+abs32code (abfd, input_section, r, shrink, link_info)
+ bfd *abfd;
+ asection *input_section;
+ arelent *r;
+ unsigned int shrink;
+ struct bfd_link_info *link_info;
+{
+ bfd_vma value = get_value (r, link_info, input_section);
+ bfd_vma dot = output_addr (input_section) + r->address;
+ bfd_vma gap;
+
+ /* See if the address we're looking at within 2^23 bytes of where
+ we are, if so then we can use a small branch rather than the
+ jump we were going to. */
+ gap = value - (dot - shrink);
+
+ if (-1 << 23 < (long)gap && (long)gap < 1 << 23)
+ {
+ /* Change the reloc type from 32bitcode possible 24, to 24bit
+ possible 32. */
+ r->howto = &howto_reloc_abs32codeshrunk;
+ /* The place to relc moves back by four bytes. */
+ r->address -=4;
+
+ /* This will be four bytes smaller in the long run. */
+ shrink += 4 ;
+ perform_slip (abfd, 4, input_section, r->address-shrink + 4);
+ }
+
+ return shrink;
+}
+
+static int
+aligncode (abfd, input_section, r, shrink)
+ bfd *abfd;
+ asection *input_section;
+ arelent *r;
+ unsigned int shrink;
+{
+ bfd_vma dot = output_addr (input_section) + r->address;
+ bfd_vma gap;
+ bfd_vma old_end;
+ bfd_vma new_end;
+ unsigned int shrink_delta;
+ int size = r->howto->size;
+
+ /* Reduce the size of the alignment so that it's still aligned but
+ smaller - the current size is already the same size as or bigger
+ than the alignment required. */
+
+ /* Calculate the first byte following the padding before we optimize. */
+ old_end = ((dot + size ) & ~size) + size+1;
+ /* Work out where the new end will be - remember that we're smaller
+ than we used to be. */
+ new_end = ((dot - shrink + size) & ~size);
+
+ /* This is the new end. */
+ gap = old_end - ((dot + size) & ~size);
+
+ shrink_delta = (old_end - new_end) - shrink;
+
+ if (shrink_delta)
+ {
+ /* Change the reloc so that it knows how far to align to. */
+ r->howto = howto_done_align_table + (r->howto - howto_align_table);
+
+ /* Encode the stuff into the addend - for future use we need to
+ know how big the reloc used to be. */
+ r->addend = old_end - dot + r->address;
+
+ /* This will be N bytes smaller in the long run, adjust all the symbols. */
+ perform_slip (abfd, shrink_delta, input_section, r->address - shrink);
+ shrink += shrink_delta;
+ }
+
+ return shrink;
+}
+
+static bfd_boolean
+b_out_bfd_relax_section (abfd, i, link_info, again)
+ bfd *abfd;
+ asection *i;
+ struct bfd_link_info *link_info;
+ bfd_boolean *again;
+{
+ /* Get enough memory to hold the stuff. */
+ bfd *input_bfd = i->owner;
+ asection *input_section = i;
+ unsigned int shrink = 0 ;
+ arelent **reloc_vector = NULL;
+ long reloc_size = bfd_get_reloc_upper_bound (input_bfd,
+ input_section);
+
+ if (reloc_size < 0)
+ return FALSE;
+
+ /* We only run this relaxation once. It might work to run it
+ multiple times, but it hasn't been tested. */
+ *again = FALSE;
+
+ if (reloc_size)
+ {
+ long reloc_count;
+
+ reloc_vector = (arelent **) bfd_malloc ((bfd_size_type) reloc_size);
+ if (reloc_vector == NULL && reloc_size != 0)
+ goto error_return;
+
+ /* Get the relocs and think about them. */
+ reloc_count =
+ bfd_canonicalize_reloc (input_bfd, input_section, reloc_vector,
+ _bfd_generic_link_get_symbols (input_bfd));
+ if (reloc_count < 0)
+ goto error_return;
+ if (reloc_count > 0)
+ {
+ arelent **parent;
+
+ for (parent = reloc_vector; *parent; parent++)
+ {
+ arelent *r = *parent;
+
+ switch (r->howto->type)
+ {
+ case ALIGNER:
+ /* An alignment reloc. */
+ shrink = aligncode (abfd, input_section, r, shrink);
+ break;
+ case ABS32CODE:
+ /* A 32bit reloc in an addressing mode. */
+ shrink = abs32code (input_bfd, input_section, r, shrink,
+ link_info);
+ break;
+ case ABS32CODE_SHRUNK:
+ shrink += 4;
+ break;
+ }
+ }
+ }
+ }
+ input_section->_cooked_size = input_section->_raw_size - shrink;
+
+ if (reloc_vector != NULL)
+ free (reloc_vector);
+ return TRUE;
+ error_return:
+ if (reloc_vector != NULL)
+ free (reloc_vector);
+ return FALSE;
+}
+
+static bfd_byte *
+b_out_bfd_get_relocated_section_contents (output_bfd, link_info, link_order,
+ data, relocatable, symbols)
+ bfd *output_bfd;
+ struct bfd_link_info *link_info;
+ struct bfd_link_order *link_order;
+ bfd_byte *data;
+ bfd_boolean relocatable;
+ asymbol **symbols;
+{
+ /* Get enough memory to hold the stuff. */
+ bfd *input_bfd = link_order->u.indirect.section->owner;
+ asection *input_section = link_order->u.indirect.section;
+ long reloc_size = bfd_get_reloc_upper_bound (input_bfd,
+ input_section);
+ arelent **reloc_vector = NULL;
+ long reloc_count;
+
+ if (reloc_size < 0)
+ goto error_return;
+
+ /* If producing relocatable output, don't bother to relax. */
+ if (relocatable)
+ return bfd_generic_get_relocated_section_contents (output_bfd, link_info,
+ link_order,
+ data, relocatable,
+ symbols);
+
+ reloc_vector = (arelent **) bfd_malloc ((bfd_size_type) reloc_size);
+ if (reloc_vector == NULL && reloc_size != 0)
+ goto error_return;
+
+ input_section->reloc_done = 1;
+
+ /* Read in the section. */
+ BFD_ASSERT (bfd_get_section_contents (input_bfd,
+ input_section,
+ data,
+ (bfd_vma) 0,
+ input_section->_raw_size));
+
+ reloc_count = bfd_canonicalize_reloc (input_bfd,
+ input_section,
+ reloc_vector,
+ symbols);
+ if (reloc_count < 0)
+ goto error_return;
+ if (reloc_count > 0)
+ {
+ arelent **parent = reloc_vector;
+ arelent *reloc ;
+ unsigned int dst_address = 0;
+ unsigned int src_address = 0;
+ unsigned int run;
+ unsigned int idx;
+
+ /* Find how long a run we can do. */
+ while (dst_address < link_order->size)
+ {
+ reloc = *parent;
+ if (reloc)
+ {
+ /* Note that the relaxing didn't tie up the addresses in the
+ relocation, so we use the original address to work out the
+ run of non-relocated data. */
+ BFD_ASSERT (reloc->address >= src_address);
+ run = reloc->address - src_address;
+ parent++;
+ }
+ else
+ {
+ run = link_order->size - dst_address;
+ }
+
+ /* Copy the bytes. */
+ for (idx = 0; idx < run; idx++)
+ data[dst_address++] = data[src_address++];
+
+ /* Now do the relocation. */
+ if (reloc)
+ {
+ switch (reloc->howto->type)
+ {
+ case ABS32CODE:
+ calljx_callback (input_bfd, link_info, reloc,
+ src_address + data, dst_address + data,
+ input_section);
+ src_address += 4;
+ dst_address += 4;
+ break;
+ case ABS32:
+ bfd_put_32 (input_bfd,
+ (bfd_get_32 (input_bfd, data + src_address)
+ + get_value (reloc, link_info, input_section)),
+ data + dst_address);
+ src_address += 4;
+ dst_address += 4;
+ break;
+ case CALLJ:
+ callj_callback (input_bfd, link_info, reloc, data,
+ src_address, dst_address, input_section,
+ FALSE);
+ src_address += 4;
+ dst_address += 4;
+ break;
+ case ALIGNDONE:
+ BFD_ASSERT (reloc->addend >= src_address);
+ BFD_ASSERT ((bfd_vma) reloc->addend
+ <= input_section->_raw_size);
+ src_address = reloc->addend;
+ dst_address = ((dst_address + reloc->howto->size)
+ & ~reloc->howto->size);
+ break;
+ case ABS32CODE_SHRUNK:
+ /* This used to be a callx, but we've found out that a
+ callj will reach, so do the right thing. */
+ callj_callback (input_bfd, link_info, reloc, data,
+ src_address + 4, dst_address, input_section,
+ TRUE);
+ dst_address += 4;
+ src_address += 8;
+ break;
+ case PCREL24:
+ {
+ long int word = bfd_get_32 (input_bfd,
+ data + src_address);
+ bfd_vma value;
+
+ value = get_value (reloc, link_info, input_section);
+ word = ((word & ~BAL_MASK)
+ | (((word & BAL_MASK)
+ + value
+ - output_addr (input_section)
+ + reloc->addend)
+ & BAL_MASK));
+
+ bfd_put_32 (input_bfd, (bfd_vma) word, data + dst_address);
+ dst_address += 4;
+ src_address += 4;
+
+ }
+ break;
+ case PCREL13:
+ {
+ long int word = bfd_get_32 (input_bfd,
+ data + src_address);
+ bfd_vma value;
+
+ value = get_value (reloc, link_info, input_section);
+ word = ((word & ~PCREL13_MASK)
+ | (((word & PCREL13_MASK)
+ + value
+ + reloc->addend
+ - output_addr (input_section))
+ & PCREL13_MASK));
+
+ bfd_put_32 (input_bfd, (bfd_vma) word, data + dst_address);
+ dst_address += 4;
+ src_address += 4;
+ }
+ break;
+
+ default:
+ abort ();
+ }
+ }
+ }
+ }
+ if (reloc_vector != NULL)
+ free (reloc_vector);
+ return data;
+ error_return:
+ if (reloc_vector != NULL)
+ free (reloc_vector);
+ return NULL;
+}
+
+
+/* Build the transfer vectors for Big and Little-Endian B.OUT files. */
+
+#define aout_32_bfd_make_debug_symbol _bfd_nosymbols_bfd_make_debug_symbol
+#define aout_32_close_and_cleanup aout_32_bfd_free_cached_info
+
+#define b_out_bfd_link_hash_table_create _bfd_generic_link_hash_table_create
+#define b_out_bfd_link_hash_table_free _bfd_generic_link_hash_table_free
+#define b_out_bfd_link_add_symbols _bfd_generic_link_add_symbols
+#define b_out_bfd_link_just_syms _bfd_generic_link_just_syms
+#define b_out_bfd_final_link _bfd_generic_final_link
+#define b_out_bfd_link_split_section _bfd_generic_link_split_section
+#define b_out_bfd_gc_sections bfd_generic_gc_sections
+#define b_out_bfd_merge_sections bfd_generic_merge_sections
+#define b_out_bfd_discard_group bfd_generic_discard_group
+
+#define aout_32_get_section_contents_in_window \
+ _bfd_generic_get_section_contents_in_window
+
+extern const bfd_target b_out_vec_little_host;
+
+const bfd_target b_out_vec_big_host =
+{
+ "b.out.big", /* name */
+ bfd_target_aout_flavour,
+ BFD_ENDIAN_LITTLE, /* data byte order is little */
+ BFD_ENDIAN_BIG, /* hdr byte order is big */
+ (HAS_RELOC | EXEC_P | /* object flags */
+ HAS_LINENO | HAS_DEBUG |
+ HAS_SYMS | HAS_LOCALS | WP_TEXT | BFD_IS_RELAXABLE ),
+ (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_RELOC | SEC_CODE | SEC_DATA),
+ '_', /* symbol leading char */
+ ' ', /* ar_pad_char */
+ 16, /* ar_max_namelen */
+
+ bfd_getl64, bfd_getl_signed_64, bfd_putl64,
+ bfd_getl32, bfd_getl_signed_32, bfd_putl32,
+ bfd_getl16, bfd_getl_signed_16, bfd_putl16, /* data */
+ bfd_getb64, bfd_getb_signed_64, bfd_putb64,
+ bfd_getb32, bfd_getb_signed_32, bfd_putb32,
+ bfd_getb16, bfd_getb_signed_16, bfd_putb16, /* hdrs */
+ {_bfd_dummy_target, b_out_object_p, /* bfd_check_format */
+ bfd_generic_archive_p, _bfd_dummy_target},
+ {bfd_false, b_out_mkobject, /* bfd_set_format */
+ _bfd_generic_mkarchive, bfd_false},
+ {bfd_false, b_out_write_object_contents, /* bfd_write_contents */
+ _bfd_write_archive_contents, bfd_false},
+
+ BFD_JUMP_TABLE_GENERIC (aout_32),
+ BFD_JUMP_TABLE_COPY (_bfd_generic),
+ BFD_JUMP_TABLE_CORE (_bfd_nocore),
+ BFD_JUMP_TABLE_ARCHIVE (_bfd_archive_bsd),
+ BFD_JUMP_TABLE_SYMBOLS (aout_32),
+ BFD_JUMP_TABLE_RELOCS (b_out),
+ BFD_JUMP_TABLE_WRITE (b_out),
+ BFD_JUMP_TABLE_LINK (b_out),
+ BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
+
+ & b_out_vec_little_host,
+
+ (PTR) 0,
+};
+
+const bfd_target b_out_vec_little_host =
+{
+ "b.out.little", /* name */
+ bfd_target_aout_flavour,
+ BFD_ENDIAN_LITTLE, /* data byte order is little */
+ BFD_ENDIAN_LITTLE, /* header byte order is little */
+ (HAS_RELOC | EXEC_P | /* object flags */
+ HAS_LINENO | HAS_DEBUG |
+ HAS_SYMS | HAS_LOCALS | WP_TEXT | BFD_IS_RELAXABLE ),
+ (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_RELOC | SEC_CODE | SEC_DATA),
+ '_', /* symbol leading char */
+ ' ', /* ar_pad_char */
+ 16, /* ar_max_namelen */
+ bfd_getl64, bfd_getl_signed_64, bfd_putl64,
+ bfd_getl32, bfd_getl_signed_32, bfd_putl32,
+ bfd_getl16, bfd_getl_signed_16, bfd_putl16, /* data */
+ bfd_getl64, bfd_getl_signed_64, bfd_putl64,
+ bfd_getl32, bfd_getl_signed_32, bfd_putl32,
+ bfd_getl16, bfd_getl_signed_16, bfd_putl16, /* hdrs */
+
+ {_bfd_dummy_target, b_out_object_p, /* bfd_check_format */
+ bfd_generic_archive_p, _bfd_dummy_target},
+ {bfd_false, b_out_mkobject, /* bfd_set_format */
+ _bfd_generic_mkarchive, bfd_false},
+ {bfd_false, b_out_write_object_contents, /* bfd_write_contents */
+ _bfd_write_archive_contents, bfd_false},
+
+ BFD_JUMP_TABLE_GENERIC (aout_32),
+ BFD_JUMP_TABLE_COPY (_bfd_generic),
+ BFD_JUMP_TABLE_CORE (_bfd_nocore),
+ BFD_JUMP_TABLE_ARCHIVE (_bfd_archive_bsd),
+ BFD_JUMP_TABLE_SYMBOLS (aout_32),
+ BFD_JUMP_TABLE_RELOCS (b_out),
+ BFD_JUMP_TABLE_WRITE (b_out),
+ BFD_JUMP_TABLE_LINK (b_out),
+ BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
+
+ & b_out_vec_big_host,
+
+ (PTR) 0
+};
diff --git a/contrib/binutils/bfd/cache.c b/contrib/binutils/bfd/cache.c
index df01a1f..7d056ea 100644
--- a/contrib/binutils/bfd/cache.c
+++ b/contrib/binutils/bfd/cache.c
@@ -1,6 +1,8 @@
/* BFD library -- caching of file descriptors.
- Copyright 1990, 1991, 1992, 1993, 1994, 1996, 2000, 2001, 2002
- Free Software Foundation, Inc.
+
+ Copyright 1990, 1991, 1992, 1993, 1994, 1996, 2000, 2001, 2002,
+ 2003, 2004 Free Software Foundation, Inc.
+
Hacked by Steve Chamberlain of Cygnus Support (steve@cygnus.com).
This file is part of BFD, the Binary File Descriptor library.
@@ -40,10 +42,7 @@ SECTION
#include "sysdep.h"
#include "libbfd.h"
-static void insert PARAMS ((bfd *));
-static void snip PARAMS ((bfd *));
-static boolean close_one PARAMS ((void));
-static boolean bfd_cache_delete PARAMS ((bfd *));
+static bfd_boolean bfd_cache_delete (bfd *);
/*
INTERNAL_FUNCTION
@@ -95,9 +94,8 @@ bfd *bfd_last_cache;
/* Insert a BFD into the cache. */
-static INLINE void
-insert (abfd)
- bfd *abfd;
+static void
+insert (bfd *abfd)
{
if (bfd_last_cache == NULL)
{
@@ -116,9 +114,8 @@ insert (abfd)
/* Remove a BFD from the cache. */
-static INLINE void
-snip (abfd)
- bfd *abfd;
+static void
+snip (bfd *abfd)
{
abfd->lru_prev->lru_next = abfd->lru_next;
abfd->lru_next->lru_prev = abfd->lru_prev;
@@ -133,8 +130,8 @@ snip (abfd)
/* We need to open a new file, and the cache is full. Find the least
recently used cacheable BFD and close it. */
-static boolean
-close_one ()
+static bfd_boolean
+close_one (void)
{
register bfd *kill;
@@ -157,27 +154,26 @@ close_one ()
if (kill == NULL)
{
/* There are no open cacheable BFD's. */
- return true;
+ return TRUE;
}
- kill->where = ftell ((FILE *) kill->iostream);
+ kill->where = real_ftell ((FILE *) kill->iostream);
return bfd_cache_delete (kill);
}
/* Close a BFD and remove it from the cache. */
-static boolean
-bfd_cache_delete (abfd)
- bfd *abfd;
+static bfd_boolean
+bfd_cache_delete (bfd *abfd)
{
- boolean ret;
+ bfd_boolean ret;
if (fclose ((FILE *) abfd->iostream) == 0)
- ret = true;
+ ret = TRUE;
else
{
- ret = false;
+ ret = FALSE;
bfd_set_error (bfd_error_system_call);
}
@@ -194,25 +190,24 @@ INTERNAL_FUNCTION
bfd_cache_init
SYNOPSIS
- boolean bfd_cache_init (bfd *abfd);
+ bfd_boolean bfd_cache_init (bfd *abfd);
DESCRIPTION
Add a newly opened BFD to the cache.
*/
-boolean
-bfd_cache_init (abfd)
- bfd *abfd;
+bfd_boolean
+bfd_cache_init (bfd *abfd)
{
BFD_ASSERT (abfd->iostream != NULL);
if (open_files >= BFD_CACHE_MAX_OPEN)
{
if (! close_one ())
- return false;
+ return FALSE;
}
insert (abfd);
++open_files;
- return true;
+ return TRUE;
}
/*
@@ -220,24 +215,23 @@ INTERNAL_FUNCTION
bfd_cache_close
SYNOPSIS
- boolean bfd_cache_close (bfd *abfd);
+ bfd_boolean bfd_cache_close (bfd *abfd);
DESCRIPTION
Remove the BFD @var{abfd} from the cache. If the attached file is open,
then close it too.
RETURNS
- <<false>> is returned if closing the file fails, <<true>> is
+ <<FALSE>> is returned if closing the file fails, <<TRUE>> is
returned if all is well.
*/
-boolean
-bfd_cache_close (abfd)
- bfd *abfd;
+bfd_boolean
+bfd_cache_close (bfd *abfd)
{
if (abfd->iostream == NULL
|| (abfd->flags & BFD_IN_MEMORY) != 0)
- return true;
+ return TRUE;
return bfd_cache_delete (abfd);
}
@@ -247,7 +241,7 @@ INTERNAL_FUNCTION
bfd_open_file
SYNOPSIS
- FILE* bfd_open_file(bfd *abfd);
+ FILE* bfd_open_file (bfd *abfd);
DESCRIPTION
Call the OS to open a file for @var{abfd}. Return the <<FILE *>>
@@ -258,10 +252,9 @@ DESCRIPTION
*/
FILE *
-bfd_open_file (abfd)
- bfd *abfd;
+bfd_open_file (bfd *abfd)
{
- abfd->cacheable = true; /* Allow it to be closed later. */
+ abfd->cacheable = TRUE; /* Allow it to be closed later. */
if (open_files >= BFD_CACHE_MAX_OPEN)
{
@@ -312,7 +305,7 @@ bfd_open_file (abfd)
unlink (abfd->filename);
#endif
abfd->iostream = (PTR) fopen (abfd->filename, FOPEN_WUB);
- abfd->opened_once = true;
+ abfd->opened_once = TRUE;
}
break;
}
@@ -331,7 +324,7 @@ INTERNAL_FUNCTION
bfd_cache_lookup_worker
SYNOPSIS
- FILE *bfd_cache_lookup_worker(bfd *abfd);
+ FILE *bfd_cache_lookup_worker (bfd *abfd);
DESCRIPTION
Called when the macro <<bfd_cache_lookup>> fails to find a
@@ -342,8 +335,7 @@ DESCRIPTION
*/
FILE *
-bfd_cache_lookup_worker (abfd)
- bfd *abfd;
+bfd_cache_lookup_worker (bfd *abfd)
{
if ((abfd->flags & BFD_IN_MEMORY) != 0)
abort ();
@@ -366,7 +358,7 @@ bfd_cache_lookup_worker (abfd)
return NULL;
if (abfd->where != (unsigned long) abfd->where)
return NULL;
- if (fseek ((FILE *) abfd->iostream, (long) abfd->where, SEEK_SET) != 0)
+ if (real_fseek ((FILE *) abfd->iostream, abfd->where, SEEK_SET) != 0)
return NULL;
}
diff --git a/contrib/binutils/bfd/coff-alpha.c b/contrib/binutils/bfd/coff-alpha.c
index 6d5ac17..e9dd416 100644
--- a/contrib/binutils/bfd/coff-alpha.c
+++ b/contrib/binutils/bfd/coff-alpha.c
@@ -1,5 +1,5 @@
/* BFD back-end for ALPHA Extended-Coff files.
- Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
+ Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Modified from coff-mips.c by Steve Chamberlain <sac@cygnus.com> and
Ian Lance Taylor <ian@cygnus.com>.
@@ -35,36 +35,40 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* Prototypes for static functions. */
-static const bfd_target *alpha_ecoff_object_p PARAMS ((bfd *));
-static boolean alpha_ecoff_bad_format_hook PARAMS ((bfd *abfd, PTR filehdr));
-static PTR alpha_ecoff_mkobject_hook PARAMS ((bfd *, PTR filehdr, PTR aouthdr));
-static void alpha_ecoff_swap_reloc_in PARAMS ((bfd *, PTR,
- struct internal_reloc *));
-static void alpha_ecoff_swap_reloc_out PARAMS ((bfd *,
- const struct internal_reloc *,
- PTR));
-static void alpha_adjust_reloc_in PARAMS ((bfd *,
- const struct internal_reloc *,
- arelent *));
-static void alpha_adjust_reloc_out PARAMS ((bfd *, const arelent *,
- struct internal_reloc *));
+static const bfd_target *alpha_ecoff_object_p
+ PARAMS ((bfd *));
+static bfd_boolean alpha_ecoff_bad_format_hook
+ PARAMS ((bfd *abfd, PTR filehdr));
+static PTR alpha_ecoff_mkobject_hook
+ PARAMS ((bfd *, PTR filehdr, PTR aouthdr));
+static void alpha_ecoff_swap_reloc_in
+ PARAMS ((bfd *, PTR, struct internal_reloc *));
+static void alpha_ecoff_swap_reloc_out
+ PARAMS ((bfd *, const struct internal_reloc *, PTR));
+static void alpha_adjust_reloc_in
+ PARAMS ((bfd *, const struct internal_reloc *, arelent *));
+static void alpha_adjust_reloc_out
+ PARAMS ((bfd *, const arelent *, struct internal_reloc *));
static reloc_howto_type *alpha_bfd_reloc_type_lookup
- PARAMS ((bfd *, bfd_reloc_code_real_type));
+ PARAMS ((bfd *, bfd_reloc_code_real_type));
static bfd_byte *alpha_ecoff_get_relocated_section_contents
PARAMS ((bfd *abfd, struct bfd_link_info *, struct bfd_link_order *,
- bfd_byte *data, boolean relocateable, asymbol **symbols));
+ bfd_byte *data, bfd_boolean relocatable, asymbol **symbols));
static bfd_vma alpha_convert_external_reloc
PARAMS ((bfd *, struct bfd_link_info *, bfd *, struct external_reloc *,
struct ecoff_link_hash_entry *));
-static boolean alpha_relocate_section PARAMS ((bfd *, struct bfd_link_info *,
- bfd *, asection *,
- bfd_byte *, PTR));
-static boolean alpha_adjust_headers
+static bfd_boolean alpha_relocate_section
+ PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *, PTR));
+static bfd_boolean alpha_adjust_headers
PARAMS ((bfd *, struct internal_filehdr *, struct internal_aouthdr *));
-static PTR alpha_ecoff_read_ar_hdr PARAMS ((bfd *));
-static bfd *alpha_ecoff_get_elt_at_filepos PARAMS ((bfd *, file_ptr));
-static bfd *alpha_ecoff_openr_next_archived_file PARAMS ((bfd *, bfd *));
-static bfd *alpha_ecoff_get_elt_at_index PARAMS ((bfd *, symindex));
+static PTR alpha_ecoff_read_ar_hdr
+ PARAMS ((bfd *));
+static bfd *alpha_ecoff_get_elt_at_filepos
+ PARAMS ((bfd *, file_ptr));
+static bfd *alpha_ecoff_openr_next_archived_file
+ PARAMS ((bfd *, bfd *));
+static bfd *alpha_ecoff_get_elt_at_index
+ PARAMS ((bfd *, symindex));
/* ECOFF has COFF sections, but the debugging information is stored in
a completely different format. ECOFF targets use some of the
@@ -122,9 +126,8 @@ static bfd *alpha_ecoff_get_elt_at_index PARAMS ((bfd *, symindex));
/* How to process the various reloc types. */
-static bfd_reloc_status_type
-reloc_nil PARAMS ((bfd *, arelent *, asymbol *, PTR,
- asection *, bfd *, char **));
+static bfd_reloc_status_type reloc_nil
+ PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
static bfd_reloc_status_type
reloc_nil (abfd, reloc, sym, data, sec, output_bfd, error_message)
@@ -152,45 +155,45 @@ static reloc_howto_type alpha_howto_table[] =
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
8, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
reloc_nil, /* special_function */
"IGNORE", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* A 32 bit reference to a symbol. */
HOWTO (ALPHA_R_REFLONG, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"REFLONG", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* A 64 bit reference to a symbol. */
HOWTO (ALPHA_R_REFQUAD, /* type */
0, /* rightshift */
4, /* size (0 = byte, 1 = short, 2 = long) */
64, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"REFQUAD", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
MINUS_ONE, /* src_mask */
MINUS_ONE, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* A 32 bit GP relative offset. This is just like REFLONG except
that when the value is used the value of the gp register will be
@@ -199,15 +202,15 @@ static reloc_howto_type alpha_howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"GPREL32", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Used for an instruction that refers to memory off the GP
register. The offset is 16 bits of the 32 bit instruction. This
@@ -216,15 +219,15 @@ static reloc_howto_type alpha_howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
0, /* special_function */
"LITERAL", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* This reloc only appears immediately following a LITERAL reloc.
It identifies a use of the literal. It seems that the linker can
@@ -239,15 +242,15 @@ static reloc_howto_type alpha_howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
reloc_nil, /* special_function */
"LITUSE", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Load the gp register. This is always used for a ldah instruction
which loads the upper 16 bits of the gp register. The next reloc
@@ -264,15 +267,15 @@ static reloc_howto_type alpha_howto_table[] =
16, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
reloc_nil, /* special_function */
"GPDISP", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* A 21 bit branch. The native assembler generates these for
branches within the text segment, and also fills in the PC
@@ -281,90 +284,90 @@ static reloc_howto_type alpha_howto_table[] =
2, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
21, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
0, /* special_function */
"BRADDR", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0x1fffff, /* src_mask */
0x1fffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* A hint for a jump to a register. */
HOWTO (ALPHA_R_HINT, /* type */
2, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
14, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
0, /* special_function */
"HINT", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0x3fff, /* src_mask */
0x3fff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 16 bit PC relative offset. */
HOWTO (ALPHA_R_SREL16, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
0, /* special_function */
"SREL16", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 32 bit PC relative offset. */
HOWTO (ALPHA_R_SREL32, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
0, /* special_function */
"SREL32", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* A 64 bit PC relative offset. */
HOWTO (ALPHA_R_SREL64, /* type */
0, /* rightshift */
4, /* size (0 = byte, 1 = short, 2 = long) */
64, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
0, /* special_function */
"SREL64", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
MINUS_ONE, /* src_mask */
MINUS_ONE, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Push a value on the reloc evaluation stack. */
HOWTO (ALPHA_R_OP_PUSH, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
0, /* special_function */
"OP_PUSH", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Store the value from the stack at the given address. Store it in
a bitfield of size r_size starting at bit position r_offset. */
@@ -372,15 +375,15 @@ static reloc_howto_type alpha_howto_table[] =
0, /* rightshift */
4, /* size (0 = byte, 1 = short, 2 = long) */
64, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
0, /* special_function */
"OP_STORE", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
MINUS_ONE, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Subtract the reloc address from the value on the top of the
relocation stack. */
@@ -388,15 +391,15 @@ static reloc_howto_type alpha_howto_table[] =
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
0, /* special_function */
"OP_PSUB", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Shift the value on the top of the relocation stack right by the
given value. */
@@ -404,30 +407,30 @@ static reloc_howto_type alpha_howto_table[] =
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
0, /* special_function */
"OP_PRSHIFT", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Adjust the GP value for a new range in the object file. */
HOWTO (ALPHA_R_GPVALUE, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
0, /* special_function */
"GPVALUE", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false) /* pcrel_offset */
+ FALSE) /* pcrel_offset */
};
/* Recognize an Alpha ECOFF file. */
@@ -471,7 +474,7 @@ alpha_ecoff_object_p (abfd)
/* See whether the magic number matches. */
-static boolean
+static bfd_boolean
alpha_ecoff_bad_format_hook (abfd, filehdr)
bfd *abfd ATTRIBUTE_UNUSED;
PTR filehdr;
@@ -479,9 +482,9 @@ alpha_ecoff_bad_format_hook (abfd, filehdr)
struct internal_filehdr *internal_f = (struct internal_filehdr *) filehdr;
if (ALPHA_ECOFF_BADMAG (*internal_f))
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
/* This is a hook called by coff_real_object_p to create any backend
@@ -750,12 +753,12 @@ alpha_adjust_reloc_out (abfd, rel, intern)
static bfd_byte *
alpha_ecoff_get_relocated_section_contents (abfd, link_info, link_order,
- data, relocateable, symbols)
+ data, relocatable, symbols)
bfd *abfd;
struct bfd_link_info *link_info;
struct bfd_link_order *link_order;
bfd_byte *data;
- boolean relocateable;
+ bfd_boolean relocatable;
asymbol **symbols;
{
bfd *input_bfd = link_order->u.indirect.section->owner;
@@ -763,9 +766,9 @@ alpha_ecoff_get_relocated_section_contents (abfd, link_info, link_order,
long reloc_size = bfd_get_reloc_upper_bound (input_bfd, input_section);
arelent **reloc_vector = NULL;
long reloc_count;
- bfd *output_bfd = relocateable ? abfd : (bfd *) NULL;
+ bfd *output_bfd = relocatable ? abfd : (bfd *) NULL;
bfd_vma gp;
- boolean gp_undefined;
+ bfd_boolean gp_undefined;
bfd_vma stack[RELOC_STACKSIZE];
int tos = 0;
@@ -781,7 +784,7 @@ alpha_ecoff_get_relocated_section_contents (abfd, link_info, link_order,
/* The section size is not going to change. */
input_section->_cooked_size = input_section->_raw_size;
- input_section->reloc_done = true;
+ input_section->reloc_done = TRUE;
reloc_count = bfd_canonicalize_reloc (input_bfd, input_section,
reloc_vector, symbols);
@@ -791,11 +794,11 @@ alpha_ecoff_get_relocated_section_contents (abfd, link_info, link_order,
goto successful_return;
/* Get the GP value for the output BFD. */
- gp_undefined = false;
+ gp_undefined = FALSE;
gp = _bfd_get_gp_value (abfd);
if (gp == 0)
{
- if (relocateable)
+ if (relocatable)
{
asection *sec;
bfd_vma lo;
@@ -819,11 +822,11 @@ alpha_ecoff_get_relocated_section_contents (abfd, link_info, link_order,
{
struct bfd_link_hash_entry *h;
- h = bfd_link_hash_lookup (link_info->hash, "_gp", false, false,
- true);
+ h = bfd_link_hash_lookup (link_info->hash, "_gp", FALSE, FALSE,
+ TRUE);
if (h == (struct bfd_link_hash_entry *) NULL
|| h->type != bfd_link_hash_defined)
- gp_undefined = true;
+ gp_undefined = TRUE;
else
{
gp = (h->u.def.value
@@ -855,7 +858,7 @@ alpha_ecoff_get_relocated_section_contents (abfd, link_info, link_order,
case ALPHA_R_SREL16:
case ALPHA_R_SREL32:
case ALPHA_R_SREL64:
- if (relocateable
+ if (relocatable
&& ((*rel->sym_ptr_ptr)->flags & BSF_SECTION_SYM) == 0)
{
rel->address += input_section->output_offset;
@@ -988,7 +991,7 @@ alpha_ecoff_get_relocated_section_contents (abfd, link_info, link_order,
asymbol *symbol;
bfd_vma relocation;
- if (relocateable)
+ if (relocatable)
{
rel->address += input_section->output_offset;
break;
@@ -1021,7 +1024,7 @@ alpha_ecoff_get_relocated_section_contents (abfd, link_info, link_order,
bfd_vma val;
int offset, size;
- if (relocateable)
+ if (relocatable)
{
rel->address += input_section->output_offset;
break;
@@ -1048,7 +1051,7 @@ alpha_ecoff_get_relocated_section_contents (abfd, link_info, link_order,
asymbol *symbol;
bfd_vma relocation;
- if (relocateable)
+ if (relocatable)
{
rel->address += input_section->output_offset;
break;
@@ -1081,7 +1084,7 @@ alpha_ecoff_get_relocated_section_contents (abfd, link_info, link_order,
asymbol *symbol;
bfd_vma relocation;
- if (relocateable)
+ if (relocatable)
{
rel->address += input_section->output_offset;
break;
@@ -1111,14 +1114,14 @@ alpha_ecoff_get_relocated_section_contents (abfd, link_info, link_order,
case ALPHA_R_GPVALUE:
/* I really don't know if this does the right thing. */
gp = rel->addend;
- gp_undefined = false;
+ gp_undefined = FALSE;
break;
default:
abort ();
}
- if (relocateable)
+ if (relocatable)
{
asection *os = input_section->output_section;
@@ -1134,7 +1137,7 @@ alpha_ecoff_get_relocated_section_contents (abfd, link_info, link_order,
case bfd_reloc_undefined:
if (! ((*link_info->callbacks->undefined_symbol)
(link_info, bfd_asymbol_name (*rel->sym_ptr_ptr),
- input_bfd, input_section, rel->address, true)))
+ input_bfd, input_section, rel->address, TRUE)))
goto error_return;
break;
case bfd_reloc_dangerous:
@@ -1245,7 +1248,7 @@ alpha_bfd_reloc_type_lookup (abfd, code)
}
/* A helper routine for alpha_relocate_section which converts an
- external reloc when generating relocateable output. Returns the
+ external reloc when generating relocatable output. Returns the
relocation amount. */
static bfd_vma
@@ -1259,7 +1262,7 @@ alpha_convert_external_reloc (output_bfd, info, input_bfd, ext_rel, h)
unsigned long r_symndx;
bfd_vma relocation;
- BFD_ASSERT (info->relocateable);
+ BFD_ASSERT (info->relocatable);
if (h->root.type == bfd_link_hash_defined
|| h->root.type == bfd_link_hash_defweak)
@@ -1365,7 +1368,7 @@ alpha_convert_external_reloc (output_bfd, info, input_bfd, ext_rel, h)
quite similar to get_relocated_section_contents. Perhaps they
could be combined somehow. */
-static boolean
+static bfd_boolean
alpha_relocate_section (output_bfd, info, input_bfd, input_section,
contents, external_relocs)
bfd *output_bfd;
@@ -1378,7 +1381,7 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
asection **symndx_to_section, *lita_sec;
struct ecoff_link_hash_entry **sym_hashes;
bfd_vma gp;
- boolean gp_undefined;
+ bfd_boolean gp_undefined;
bfd_vma stack[RELOC_STACKSIZE];
int tos = 0;
struct external_reloc *ext_rel;
@@ -1394,7 +1397,7 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
amt = NUM_RELOC_SECTIONS * sizeof (asection *);
symndx_to_section = (asection **) bfd_alloc (input_bfd, amt);
if (!symndx_to_section)
- return false;
+ return FALSE;
symndx_to_section[RELOC_SECTION_NONE] = NULL;
symndx_to_section[RELOC_SECTION_TEXT] =
@@ -1440,7 +1443,7 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
lita_sec = symndx_to_section[RELOC_SECTION_LITA];
gp = _bfd_get_gp_value (output_bfd);
- if (! info->relocateable && lita_sec != NULL)
+ if (! info->relocatable && lita_sec != NULL)
{
struct ecoff_section_tdata *lita_sec_data;
@@ -1485,7 +1488,7 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
_("using multiple gp values"),
(char *) NULL, output_bfd,
(asection *) NULL, (bfd_vma) 0);
- ecoff_data (output_bfd)->issued_multiple_gp_warning = true;
+ ecoff_data (output_bfd)->issued_multiple_gp_warning = TRUE;
}
if (lita_vma < gp - 0x8000)
gp = lita_vma + lita_size - 0x8000;
@@ -1515,9 +1518,9 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
int r_extern;
int r_offset;
int r_size;
- boolean relocatep;
- boolean adjust_addrp;
- boolean gp_usedp;
+ bfd_boolean relocatep;
+ bfd_boolean adjust_addrp;
+ bfd_boolean gp_usedp;
bfd_vma addend;
r_vaddr = H_GET_64 (input_bfd, ext_rel->r_vaddr);
@@ -1532,9 +1535,9 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
r_size = ((ext_rel->r_bits[3] & RELOC_BITS3_SIZE_LITTLE)
>> RELOC_BITS3_SIZE_SH_LITTLE);
- relocatep = false;
- adjust_addrp = true;
- gp_usedp = false;
+ relocatep = FALSE;
+ adjust_addrp = TRUE;
+ gp_usedp = FALSE;
addend = 0;
switch (r_type)
@@ -1549,16 +1552,16 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
not otherwise used for anything. For some reason, the
address of the relocation does not appear to include the
section VMA, unlike the other relocation types. */
- if (info->relocateable)
+ if (info->relocatable)
H_PUT_64 (input_bfd, input_section->output_offset + r_vaddr,
ext_rel->r_vaddr);
- adjust_addrp = false;
+ adjust_addrp = FALSE;
break;
case ALPHA_R_REFLONG:
case ALPHA_R_REFQUAD:
case ALPHA_R_HINT:
- relocatep = true;
+ relocatep = TRUE;
break;
case ALPHA_R_BRADDR:
@@ -1567,7 +1570,7 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
case ALPHA_R_SREL64:
if (r_extern)
addend += - (r_vaddr + 4);
- relocatep = true;
+ relocatep = TRUE;
break;
case ALPHA_R_GPREL32:
@@ -1575,9 +1578,9 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
bit offset from the current GP value. We must adjust it
by the different between the original GP value and the
current GP value. */
- relocatep = true;
+ relocatep = TRUE;
addend = ecoff_data (input_bfd)->gp - gp;
- gp_usedp = true;
+ gp_usedp = TRUE;
break;
case ALPHA_R_LITERAL:
@@ -1608,9 +1611,9 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
|| ((insn >> 26) & 0x3f) == 0x28);
}
- relocatep = true;
+ relocatep = TRUE;
addend = ecoff_data (input_bfd)->gp - gp;
- gp_usedp = true;
+ gp_usedp = TRUE;
break;
case ALPHA_R_LITUSE:
@@ -1674,7 +1677,7 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
bfd_put_32 (input_bfd, (bfd_vma) insn2,
contents + r_vaddr - input_section->vma + r_symndx);
- gp_usedp = true;
+ gp_usedp = TRUE;
}
break;
@@ -1702,7 +1705,7 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
if (h == (struct ecoff_link_hash_entry *) NULL)
abort ();
- if (! info->relocateable)
+ if (! info->relocatable)
{
if (h->root.type == bfd_link_hash_defined
|| h->root.type == bfd_link_hash_defweak)
@@ -1717,8 +1720,8 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
relocated. */
if (! ((*info->callbacks->undefined_symbol)
(info, h->root.root.string, input_bfd,
- input_section, (bfd_vma) 0, true)))
- return false;
+ input_section, (bfd_vma) 0, TRUE)))
+ return FALSE;
addend = 0;
}
}
@@ -1734,7 +1737,7 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
if (! ((*info->callbacks->unattached_reloc)
(info, h->root.root.string, input_bfd,
input_section, (bfd_vma) 0)))
- return false;
+ return FALSE;
}
addend = alpha_convert_external_reloc (output_bfd, info,
@@ -1745,7 +1748,7 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
addend += r_vaddr;
- if (info->relocateable)
+ if (info->relocatable)
{
/* Adjust r_vaddr by the addend. */
H_PUT_64 (input_bfd, addend, ext_rel->r_vaddr);
@@ -1774,14 +1777,14 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
}
}
- adjust_addrp = false;
+ adjust_addrp = FALSE;
break;
case ALPHA_R_OP_STORE:
/* Store a value from the reloc stack into a bitfield. If
- we are generating relocateable output, all we do is
+ we are generating relocatable output, all we do is
adjust the address of the reloc. */
- if (! info->relocateable)
+ if (! info->relocatable)
{
bfd_vma mask;
bfd_vma val;
@@ -1811,7 +1814,7 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
case ALPHA_R_GPVALUE:
/* I really don't know if this does the right thing. */
gp = ecoff_data (input_bfd)->gp + r_symndx;
- gp_undefined = false;
+ gp_undefined = FALSE;
break;
}
@@ -1847,9 +1850,9 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
abort ();
}
- if (info->relocateable)
+ if (info->relocatable)
{
- /* We are generating relocateable output, and must
+ /* We are generating relocatable output, and must
convert the existing reloc. */
if (r_extern)
{
@@ -1861,7 +1864,7 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
if (! ((*info->callbacks->unattached_reloc)
(info, h->root.root.string, input_bfd,
input_section, r_vaddr - input_section->vma)))
- return false;
+ return FALSE;
}
relocation = alpha_convert_external_reloc (output_bfd,
@@ -1918,8 +1921,8 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
if (! ((*info->callbacks->undefined_symbol)
(info, h->root.root.string, input_bfd,
input_section,
- r_vaddr - input_section->vma, true)))
- return false;
+ r_vaddr - input_section->vma, TRUE)))
+ return FALSE;
relocation = 0;
}
}
@@ -1965,14 +1968,14 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
(info, name, alpha_howto_table[r_type].name,
(bfd_vma) 0, input_bfd, input_section,
r_vaddr - input_section->vma)))
- return false;
+ return FALSE;
}
break;
}
}
}
- if (info->relocateable && adjust_addrp)
+ if (info->relocatable && adjust_addrp)
{
/* Change the address of the relocation. */
H_PUT_64 (input_bfd,
@@ -1988,24 +1991,24 @@ alpha_relocate_section (output_bfd, info, input_bfd, input_section,
if (! ((*info->callbacks->reloc_dangerous)
(info, _("GP relative relocation used when GP not defined"),
input_bfd, input_section, r_vaddr - input_section->vma)))
- return false;
+ return FALSE;
/* Only give the error once per link. */
gp = 4;
_bfd_set_gp_value (output_bfd, gp);
- gp_undefined = false;
+ gp_undefined = FALSE;
}
}
if (tos != 0)
abort ();
- return true;
+ return TRUE;
}
/* Do final adjustments to the filehdr and the aouthdr. This routine
sets the dynamic bits in the file header. */
-static boolean
+static bfd_boolean
alpha_adjust_headers (abfd, fhdr, ahdr)
bfd *abfd;
struct internal_filehdr *fhdr;
@@ -2015,7 +2018,7 @@ alpha_adjust_headers (abfd, fhdr, ahdr)
fhdr->f_flags |= F_ALPHA_CALL_SHARED;
else if ((abfd->flags & DYNAMIC) != 0)
fhdr->f_flags |= F_ALPHA_SHARABLE;
- return true;
+ return TRUE;
}
/* Archive handling. In OSF/1 (or Digital Unix) v3.2, Digital
@@ -2185,7 +2188,7 @@ alpha_ecoff_get_elt_at_filepos (archive, filepos)
bim->size = size;
bim->buffer = buf;
- nbfd->mtime_set = true;
+ nbfd->mtime_set = TRUE;
nbfd->mtime = strtol (hdr->ar_date, (char **) NULL, 10);
nbfd->flags |= BFD_IN_MEMORY;
@@ -2262,7 +2265,7 @@ static const struct ecoff_backend_data alpha_ecoff_backend_data =
(unsigned (*) PARAMS ((bfd *,PTR,PTR))) bfd_void, /* reloc_out */
alpha_ecoff_swap_filehdr_out, alpha_ecoff_swap_aouthdr_out,
alpha_ecoff_swap_scnhdr_out,
- FILHSZ, AOUTSZ, SCNHSZ, 0, 0, 0, 0, FILNMLEN, true, false, 4, false, 2,
+ FILHSZ, AOUTSZ, SCNHSZ, 0, 0, 0, 0, FILNMLEN, TRUE, FALSE, 4, FALSE, 2,
alpha_ecoff_swap_filehdr_in, alpha_ecoff_swap_aouthdr_in,
alpha_ecoff_swap_scnhdr_in, NULL,
alpha_ecoff_bad_format_hook, _bfd_ecoff_set_arch_mach_hook,
@@ -2278,10 +2281,10 @@ static const struct ecoff_backend_data alpha_ecoff_backend_data =
/* The page boundary used to align sections in a demand-paged
executable file. E.g., 0x1000. */
0x2000,
- /* True if the .rdata section is part of the text segment, as on the
- Alpha. False if .rdata is part of the data segment, as on the
+ /* TRUE if the .rdata section is part of the text segment, as on the
+ Alpha. FALSE if .rdata is part of the data segment, as on the
MIPS. */
- true,
+ TRUE,
/* Bitsize of constructor entries. */
64,
/* Reloc to use for constructor entries. */
diff --git a/contrib/binutils/bfd/coff-arm.c b/contrib/binutils/bfd/coff-arm.c
index 25256a8..e51d07d 100644
--- a/contrib/binutils/bfd/coff-arm.c
+++ b/contrib/binutils/bfd/coff-arm.c
@@ -1,24 +1,24 @@
/* BFD back-end for ARM COFF files.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Support.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "bfd.h"
#include "sysdep.h"
@@ -80,7 +80,7 @@ typedef unsigned long int insn32;
typedef unsigned short int insn16;
/* Forward declarations for stupid compilers. */
-static boolean coff_arm_relocate_section
+static bfd_boolean coff_arm_relocate_section
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
struct internal_reloc *, struct internal_syment *, asection **));
static bfd_reloc_status_type aoutarm_fix_pcrel_26_done
@@ -99,9 +99,9 @@ static bfd_reloc_status_type coff_thumb_pcrel_12
PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
static bfd_reloc_status_type coff_arm_reloc
PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
-static boolean coff_arm_adjust_symndx
+static bfd_boolean coff_arm_adjust_symndx
PARAMS ((bfd *, struct bfd_link_info *, bfd *,
- asection *, struct internal_reloc *, boolean *));
+ asection *, struct internal_reloc *, bfd_boolean *));
static reloc_howto_type * coff_arm_rtype_to_howto
PARAMS ((bfd *, asection *, struct internal_reloc *,
struct coff_link_hash_entry *, struct internal_syment *,
@@ -125,19 +125,19 @@ static void record_thumb_to_arm_glue
PARAMS ((struct bfd_link_info *, struct coff_link_hash_entry *));
#endif
#endif
-static boolean coff_arm_merge_private_bfd_data
+static bfd_boolean coff_arm_merge_private_bfd_data
PARAMS ((bfd *, bfd *));
-static boolean coff_arm_print_private_bfd_data
+static bfd_boolean coff_arm_print_private_bfd_data
PARAMS ((bfd *, PTR));
-static boolean _bfd_coff_arm_set_private_flags
+static bfd_boolean _bfd_coff_arm_set_private_flags
PARAMS ((bfd *, flagword));
-static boolean coff_arm_copy_private_bfd_data
+static bfd_boolean coff_arm_copy_private_bfd_data
PARAMS ((bfd *, bfd *));
-static boolean coff_arm_is_local_label_name
+static bfd_boolean coff_arm_is_local_label_name
PARAMS ((bfd *, const char *));
-static boolean coff_arm_link_output_has_begun
+static bfd_boolean coff_arm_link_output_has_begun
PARAMS ((bfd *, struct coff_final_link_info *));
-static boolean coff_arm_final_link_postscript
+static bfd_boolean coff_arm_final_link_postscript
PARAMS ((bfd *, struct coff_final_link_info *));
static void arm_emit_base_file_entry
PARAMS ((struct bfd_link_info *, bfd *, asection *, bfd_vma));
@@ -224,7 +224,7 @@ coff_arm_reloc (abfd, reloc_entry, symbol, data, input_section, output_bfd,
#endif
#ifndef PCRELOFFSET
-#define PCRELOFFSET true
+#define PCRELOFFSET TRUE
#endif
/* These most certainly belong somewhere else. Just had to get rid of
@@ -252,11 +252,11 @@ coff_arm_reloc (abfd, reloc_entry, symbol, data, input_section, output_bfd,
#undef ARM_THUMB12
#undef ARM_26D
+#define ARM_26D 0
#define ARM_32 1
#define ARM_RVA32 2
#define ARM_26 3
#define ARM_THUMB12 4
-#define ARM_26D 5
#define ARM_SECTION 14
#define ARM_SECREL 15
#endif
@@ -264,17 +264,29 @@ coff_arm_reloc (abfd, reloc_entry, symbol, data, input_section, output_bfd,
static reloc_howto_type aoutarm_std_reloc_howto[] =
{
#ifdef ARM_WINCE
- EMPTY_HOWTO (-1),
+ HOWTO (ARM_26D,
+ 2,
+ 2,
+ 24,
+ TRUE,
+ 0,
+ complain_overflow_dont,
+ aoutarm_fix_pcrel_26_done,
+ "ARM_26D",
+ FALSE,
+ 0x00ffffff,
+ 0x0,
+ PCRELOFFSET),
HOWTO (ARM_32,
0,
2,
32,
- false,
+ FALSE,
0,
complain_overflow_bitfield,
coff_arm_reloc,
"ARM_32",
- true,
+ FALSE,
0xffffffff,
0xffffffff,
PCRELOFFSET),
@@ -282,12 +294,12 @@ static reloc_howto_type aoutarm_std_reloc_howto[] =
0,
2,
32,
- false,
+ FALSE,
0,
complain_overflow_bitfield,
coff_arm_reloc,
"ARM_RVA32",
- true,
+ FALSE,
0xffffffff,
0xffffffff,
PCRELOFFSET),
@@ -295,12 +307,12 @@ static reloc_howto_type aoutarm_std_reloc_howto[] =
2,
2,
24,
- true,
+ TRUE,
0,
complain_overflow_signed,
aoutarm_fix_pcrel_26 ,
"ARM_26",
- false,
+ FALSE,
0x00ffffff,
0x00ffffff,
PCRELOFFSET),
@@ -308,28 +320,16 @@ static reloc_howto_type aoutarm_std_reloc_howto[] =
1,
1,
11,
- true,
+ TRUE,
0,
complain_overflow_signed,
coff_thumb_pcrel_12 ,
"ARM_THUMB12",
- false,
+ FALSE,
0x000007ff,
0x000007ff,
PCRELOFFSET),
- HOWTO (ARM_26D,
- 2,
- 2,
- 24,
- false,
- 0,
- complain_overflow_dont,
- aoutarm_fix_pcrel_26_done,
- "ARM_26D",
- true,
- 0x00ffffff,
- 0x0,
- false),
+ EMPTY_HOWTO (-1),
EMPTY_HOWTO (-1),
EMPTY_HOWTO (-1),
EMPTY_HOWTO (-1),
@@ -342,12 +342,12 @@ static reloc_howto_type aoutarm_std_reloc_howto[] =
0,
1,
16,
- false,
+ FALSE,
0,
complain_overflow_bitfield,
coff_arm_reloc,
- "ARM_16",
- true,
+ "ARM_SECTION",
+ FALSE,
0x0000ffff,
0x0000ffff,
PCRELOFFSET),
@@ -355,26 +355,26 @@ static reloc_howto_type aoutarm_std_reloc_howto[] =
0,
2,
32,
- false,
+ FALSE,
0,
complain_overflow_bitfield,
coff_arm_reloc,
- "ARM_32",
- true,
+ "ARM_SECREL",
+ FALSE,
0xffffffff,
0xffffffff,
PCRELOFFSET),
#else /* not ARM_WINCE */
- HOWTO (ARM_8, /* type */
+ HOWTO (ARM_8, /* type */
0, /* rightshift */
0, /* size */
8, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- coff_arm_reloc, /* special_function */
+ coff_arm_reloc, /* special_function */
"ARM_8", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0x000000ff, /* src_mask */
0x000000ff, /* dst_mask */
PCRELOFFSET /* pcrel_offset */),
@@ -382,12 +382,12 @@ static reloc_howto_type aoutarm_std_reloc_howto[] =
0,
1,
16,
- false,
+ FALSE,
0,
complain_overflow_bitfield,
coff_arm_reloc,
"ARM_16",
- true,
+ TRUE,
0x0000ffff,
0x0000ffff,
PCRELOFFSET),
@@ -395,12 +395,12 @@ static reloc_howto_type aoutarm_std_reloc_howto[] =
0,
2,
32,
- false,
+ FALSE,
0,
complain_overflow_bitfield,
coff_arm_reloc,
"ARM_32",
- true,
+ TRUE,
0xffffffff,
0xffffffff,
PCRELOFFSET),
@@ -408,12 +408,12 @@ static reloc_howto_type aoutarm_std_reloc_howto[] =
2,
2,
24,
- true,
+ TRUE,
0,
complain_overflow_signed,
aoutarm_fix_pcrel_26 ,
"ARM_26",
- false,
+ FALSE,
0x00ffffff,
0x00ffffff,
PCRELOFFSET),
@@ -421,92 +421,92 @@ static reloc_howto_type aoutarm_std_reloc_howto[] =
0,
0,
8,
- true,
+ TRUE,
0,
complain_overflow_signed,
coff_arm_reloc,
"ARM_DISP8",
- true,
+ TRUE,
0x000000ff,
0x000000ff,
- true),
+ TRUE),
HOWTO (ARM_DISP16,
0,
1,
16,
- true,
+ TRUE,
0,
complain_overflow_signed,
coff_arm_reloc,
"ARM_DISP16",
- true,
+ TRUE,
0x0000ffff,
0x0000ffff,
- true),
+ TRUE),
HOWTO (ARM_DISP32,
0,
2,
32,
- true,
+ TRUE,
0,
complain_overflow_signed,
coff_arm_reloc,
"ARM_DISP32",
- true,
+ TRUE,
0xffffffff,
0xffffffff,
- true),
+ TRUE),
HOWTO (ARM_26D,
2,
2,
24,
- false,
+ FALSE,
0,
complain_overflow_dont,
aoutarm_fix_pcrel_26_done,
"ARM_26D",
- true,
+ TRUE,
0x00ffffff,
0x0,
- false),
+ FALSE),
/* 8 is unused */
EMPTY_HOWTO (-1),
HOWTO (ARM_NEG16,
0,
-1,
16,
- false,
+ FALSE,
0,
complain_overflow_bitfield,
coff_arm_reloc,
"ARM_NEG16",
- true,
+ TRUE,
0x0000ffff,
0x0000ffff,
- false),
+ FALSE),
HOWTO (ARM_NEG32,
0,
-2,
32,
- false,
+ FALSE,
0,
complain_overflow_bitfield,
coff_arm_reloc,
"ARM_NEG32",
- true,
+ TRUE,
0xffffffff,
0xffffffff,
- false),
+ FALSE),
HOWTO (ARM_RVA32,
0,
2,
32,
- false,
+ FALSE,
0,
complain_overflow_bitfield,
coff_arm_reloc,
"ARM_RVA32",
- true,
+ TRUE,
0xffffffff,
0xffffffff,
PCRELOFFSET),
@@ -514,12 +514,12 @@ static reloc_howto_type aoutarm_std_reloc_howto[] =
1,
1,
8,
- true,
+ TRUE,
0,
complain_overflow_signed,
coff_thumb_pcrel_9 ,
"ARM_THUMB9",
- false,
+ FALSE,
0x000000ff,
0x000000ff,
PCRELOFFSET),
@@ -527,12 +527,12 @@ static reloc_howto_type aoutarm_std_reloc_howto[] =
1,
1,
11,
- true,
+ TRUE,
0,
complain_overflow_signed,
coff_thumb_pcrel_12 ,
"ARM_THUMB12",
- false,
+ FALSE,
0x000007ff,
0x000007ff,
PCRELOFFSET),
@@ -540,12 +540,12 @@ static reloc_howto_type aoutarm_std_reloc_howto[] =
1,
2,
22,
- true,
+ TRUE,
0,
complain_overflow_signed,
coff_thumb_pcrel_23 ,
"ARM_THUMB23",
- false,
+ FALSE,
0x07ff07ff,
0x07ff07ff,
PCRELOFFSET)
@@ -555,11 +555,11 @@ static reloc_howto_type aoutarm_std_reloc_howto[] =
#define NUM_RELOCS NUM_ELEM (aoutarm_std_reloc_howto)
#ifdef COFF_WITH_PE
-static boolean in_reloc_p PARAMS ((bfd *, reloc_howto_type *));
-/* Return true if this relocation should
+static bfd_boolean in_reloc_p PARAMS ((bfd *, reloc_howto_type *));
+/* Return TRUE if this relocation should
appear in the output .reloc section. */
-static boolean
+static bfd_boolean
in_reloc_p (abfd, howto)
bfd * abfd ATTRIBUTE_UNUSED;
reloc_howto_type * howto;
@@ -921,13 +921,13 @@ struct coff_arm_link_hash_table
/* The original coff_link_hash_table structure. MUST be first field. */
struct coff_link_hash_table root;
- /* The size in bytes of the section containg the Thumb-to-ARM glue. */
+ /* The size in bytes of the section containing the Thumb-to-ARM glue. */
bfd_size_type thumb_glue_size;
- /* The size in bytes of the section containg the ARM-to-Thumb glue. */
+ /* The size in bytes of the section containing the ARM-to-Thumb glue. */
bfd_size_type arm_glue_size;
- /* An arbitary input BFD chosen to hold the glue sections. */
+ /* An arbitrary input BFD chosen to hold the glue sections. */
bfd * bfd_of_glue_owner;
/* Support interworking with old, non-interworking aware ARM code. */
@@ -991,7 +991,7 @@ arm_emit_base_file_entry (info, output_bfd, input_section, reloc_offset)
instruction.
It takes two thumb instructions to encode the target address. Each has
- 11 bits to invest. The upper 11 bits are stored in one (identifed by
+ 11 bits to invest. The upper 11 bits are stored in one (identified by
H-0.. see below), the lower 11 bits are stored in the other (identified
by H-1).
@@ -1059,7 +1059,7 @@ find_thumb_glue (info, name, input_bfd)
sprintf (tmp_name, THUMB2ARM_GLUE_ENTRY_NAME, name);
myh = coff_link_hash_lookup
- (coff_hash_table (info), tmp_name, false, false, true);
+ (coff_hash_table (info), tmp_name, FALSE, FALSE, TRUE);
if (myh == NULL)
/* xgettext:c-format */
@@ -1089,7 +1089,7 @@ find_arm_glue (info, name, input_bfd)
sprintf (tmp_name, ARM2THUMB_GLUE_ENTRY_NAME, name);
myh = coff_link_hash_lookup
- (coff_hash_table (info), tmp_name, false, false, true);
+ (coff_hash_table (info), tmp_name, FALSE, FALSE, TRUE);
if (myh == NULL)
/* xgettext:c-format */
@@ -1188,7 +1188,7 @@ static const insn32 t2a6_bx_insn = 0xe12fff1e;
ARM/Thumb builds. It is only the code marked THUMBEXTENSION that
is different from the original. */
-static boolean
+static bfd_boolean
coff_arm_relocate_section (output_bfd, info, input_bfd, input_section,
contents, relocs, syms, sections)
bfd *output_bfd;
@@ -1244,16 +1244,17 @@ coff_arm_relocate_section (output_bfd, info, input_bfd, input_section,
howto = coff_rtype_to_howto (input_bfd, input_section, rel, h,
sym, &addend);
if (howto == NULL)
- return false;
+ return FALSE;
/* The relocation_section function will skip pcrel_offset relocs
- when doing a relocateable link. However, we want to convert
- ARM26 to ARM26D relocs if possible. We return a fake howto in
+ when doing a relocatable link. However, we want to convert
+ ARM_26 to ARM_26D relocs if possible. We return a fake howto in
this case without pcrel_offset set, and adjust the addend to
- compensate. */
+ compensate. 'partial_inplace' is also set, since we want 'done'
+ relocations to be reflected in section's data. */
if (rel->r_type == ARM_26
&& h != NULL
- && info->relocateable
+ && info->relocatable
&& (h->root.type == bfd_link_hash_defined
|| h->root.type == bfd_link_hash_defweak)
&& (h->root.u.def.section->output_section
@@ -1264,39 +1265,47 @@ coff_arm_relocate_section (output_bfd, info, input_bfd, input_section,
2,
2,
24,
- true,
+ TRUE,
0,
complain_overflow_signed,
aoutarm_fix_pcrel_26 ,
"ARM_26",
- false,
+ TRUE,
0x00ffffff,
0x00ffffff,
- false);
+ FALSE);
addend -= rel->r_vaddr - input_section->vma;
+#ifdef ARM_WINCE
+ /* FIXME: I don't know why, but the hack is necessary for correct
+ generation of bl's instruction offset. */
+ addend -= 8;
+#endif
howto = &fake_arm26_reloc;
}
#ifdef ARM_WINCE
/* MS ARM-CE makes the reloc relative to the opcode's pc, not
the next opcode's pc, so is off by one. */
- if (howto->pc_relative && !info->relocateable)
+#if 0 /* This appears to have been true for WINCE 2.0, but it is not
+ true for WINCE 3.0. */
+ if (howto->pc_relative && !info->relocatable)
addend -= 8;
#endif
+#endif
- /* If we are doing a relocateable link, then we can just ignore
+ /* If we are doing a relocatable link, then we can just ignore
a PC relative reloc that is pcrel_offset. It will already
- have the correct value. If this is not a relocateable link,
+ have the correct value. If this is not a relocatable link,
then we should ignore the symbol value. */
if (howto->pc_relative && howto->pcrel_offset)
{
- if (info->relocateable)
+ if (info->relocatable)
continue;
/* FIXME - it is not clear which targets need this next test
and which do not. It is known that it is needed for the
VxWorks and EPOC-PE targets, but it is also known that it
- was supressed for other ARM targets. This ought to be
+ was suppressed for other ARM targets. This ought to be
sorted out one day. */
#ifdef ARM_COFF_BUGFIX
/* We must not ignore the symbol value. If the symbol is
@@ -1338,7 +1347,7 @@ coff_arm_relocate_section (output_bfd, info, input_bfd, input_section,
stub generation to the final linker pass. If we fail to
verify that the name is defined, we'll try to build stubs
for an undefined name... */
- if (! info->relocateable
+ if (! info->relocatable
&& ( h->root.type == bfd_link_hash_defined
|| h->root.type == bfd_link_hash_defweak))
{
@@ -1365,7 +1374,7 @@ coff_arm_relocate_section (output_bfd, info, input_bfd, input_section,
myh = find_arm_glue (info, name, input_bfd);
if (myh == NULL)
- return false;
+ return FALSE;
globals = coff_arm_hash_table (info);
@@ -1458,7 +1467,7 @@ coff_arm_relocate_section (output_bfd, info, input_bfd, input_section,
myh = find_thumb_glue (info, name, input_bfd);
if (myh == NULL)
- return false;
+ return FALSE;
globals = coff_arm_hash_table (info);
@@ -1592,12 +1601,12 @@ coff_arm_relocate_section (output_bfd, info, input_bfd, input_section,
+ sec->output_offset);
}
- else if (! info->relocateable)
+ else if (! info->relocatable)
{
if (! ((*info->callbacks->undefined_symbol)
(info, h->root.root.string, input_bfd, input_section,
- rel->r_vaddr - input_section->vma, true)))
- return false;
+ rel->r_vaddr - input_section->vma, TRUE)))
+ return FALSE;
}
}
@@ -1614,7 +1623,7 @@ coff_arm_relocate_section (output_bfd, info, input_bfd, input_section,
rstat = bfd_reloc_ok;
#ifndef ARM_WINCE
/* Only perform this fix during the final link, not a relocatable link. nickc@cygnus.com */
- else if (! info->relocateable
+ else if (! info->relocatable
&& howto->type == ARM_THUMB23)
{
/* This is pretty much a copy of what the default
@@ -1631,18 +1640,18 @@ coff_arm_relocate_section (output_bfd, info, input_bfd, input_section,
rstat = bfd_reloc_outofrange;
else
{
- bfd_vma relocation = val + addend;
- int size = bfd_get_reloc_size (howto);
- boolean overflow = false;
- bfd_byte * location = contents + address;
- bfd_vma x = bfd_get_32 (input_bfd, location);
- bfd_vma src_mask = 0x007FFFFE;
- bfd_signed_vma reloc_signed_max = (1 << (howto->bitsize - 1)) - 1;
- bfd_signed_vma reloc_signed_min = ~reloc_signed_max;
- bfd_vma check;
- bfd_signed_vma signed_check;
- bfd_vma add;
- bfd_signed_vma signed_add;
+ bfd_vma relocation = val + addend;
+ int size = bfd_get_reloc_size (howto);
+ bfd_boolean overflow = FALSE;
+ bfd_byte *location = contents + address;
+ bfd_vma x = bfd_get_32 (input_bfd, location);
+ bfd_vma src_mask = 0x007FFFFE;
+ bfd_signed_vma reloc_signed_max = (1 << (howto->bitsize - 1)) - 1;
+ bfd_signed_vma reloc_signed_min = ~reloc_signed_max;
+ bfd_vma check;
+ bfd_signed_vma signed_check;
+ bfd_vma add;
+ bfd_signed_vma signed_add;
BFD_ASSERT (size == 4);
@@ -1699,7 +1708,7 @@ coff_arm_relocate_section (output_bfd, info, input_bfd, input_section,
/* Assumes two's complement. */
if ( signed_check > reloc_signed_max
|| signed_check < reloc_signed_min)
- overflow = true;
+ overflow = TRUE;
/* Put the relocation into the correct bits.
For a BLX instruction, make sure that the relocation is rounded up
@@ -1731,28 +1740,31 @@ coff_arm_relocate_section (output_bfd, info, input_bfd, input_section,
#endif
else
#endif /* THUMBEXTENSION */
- rstat = _bfd_final_link_relocate (howto, input_bfd, input_section,
- contents,
- rel->r_vaddr - input_section->vma,
- val, addend);
+ if (info->relocatable && ! howto->partial_inplace)
+ rstat = bfd_reloc_ok;
+ else
+ rstat = _bfd_final_link_relocate (howto, input_bfd, input_section,
+ contents,
+ rel->r_vaddr - input_section->vma,
+ val, addend);
#if 1 /* THUMBEXTENSION */
/* FIXME:
Is this the best way to fix up thumb addresses? krk@cygnus.com
Probably not, but it works, and if it works it don't need fixing! nickc@cygnus.com */
/* Only perform this fix during the final link, not a relocatable link. nickc@cygnus.com */
- if (! info->relocateable
+ if (! info->relocatable
&& (rel->r_type == ARM_32 || rel->r_type == ARM_RVA32))
{
/* Determine if we need to set the bottom bit of a relocated address
because the address is the address of a Thumb code symbol. */
- int patchit = false;
+ int patchit = FALSE;
if (h != NULL
&& ( h->class == C_THUMBSTATFUNC
|| h->class == C_THUMBEXTFUNC))
{
- patchit = true;
+ patchit = TRUE;
}
else if (sym != NULL
&& sym->n_scnum > N_UNDEF)
@@ -1761,7 +1773,7 @@ coff_arm_relocate_section (output_bfd, info, input_bfd, input_section,
if ( sym->n_sclass == C_THUMBSTATFUNC
|| sym->n_sclass == C_THUMBEXTFUNC)
- patchit = true;
+ patchit = TRUE;
}
if (patchit)
@@ -1786,7 +1798,7 @@ coff_arm_relocate_section (output_bfd, info, input_bfd, input_section,
bfd_archive_filename (input_bfd),
(unsigned long) rel->r_vaddr,
bfd_get_section_name (input_bfd, input_section));
- return false;
+ return FALSE;
case bfd_reloc_overflow:
{
const char *name;
@@ -1800,23 +1812,23 @@ coff_arm_relocate_section (output_bfd, info, input_bfd, input_section,
{
name = _bfd_coff_internal_syment_name (input_bfd, sym, buf);
if (name == NULL)
- return false;
+ return FALSE;
}
if (! ((*info->callbacks->reloc_overflow)
(info, name, howto->name, (bfd_vma) 0, input_bfd,
input_section, rel->r_vaddr - input_section->vma)))
- return false;
+ return FALSE;
}
}
}
- return true;
+ return TRUE;
}
#ifndef COFF_IMAGE_WITH_PE
-boolean
+bfd_boolean
bfd_arm_allocate_interworking_sections (info)
struct bfd_link_info * info;
{
@@ -1869,7 +1881,7 @@ bfd_arm_allocate_interworking_sections (info)
s->contents = foo;
}
- return true;
+ return TRUE;
}
static void
@@ -1904,7 +1916,7 @@ record_arm_to_thumb_glue (info, h)
sprintf (tmp_name, ARM2THUMB_GLUE_ENTRY_NAME, name);
myh = coff_link_hash_lookup
- (coff_hash_table (info), tmp_name, false, false, true);
+ (coff_hash_table (info), tmp_name, FALSE, FALSE, TRUE);
if (myh != NULL)
{
@@ -1919,7 +1931,7 @@ record_arm_to_thumb_glue (info, h)
bh = NULL;
val = globals->arm_glue_size + 1;
bfd_coff_link_add_one_symbol (info, globals->bfd_of_glue_owner, tmp_name,
- BSF_GLOBAL, s, val, NULL, true, false, &bh);
+ BSF_GLOBAL, s, val, NULL, TRUE, FALSE, &bh);
free (tmp_name);
@@ -1961,7 +1973,7 @@ record_thumb_to_arm_glue (info, h)
sprintf (tmp_name, THUMB2ARM_GLUE_ENTRY_NAME, name);
myh = coff_link_hash_lookup
- (coff_hash_table (info), tmp_name, false, false, true);
+ (coff_hash_table (info), tmp_name, FALSE, FALSE, TRUE);
if (myh != NULL)
{
@@ -1972,7 +1984,7 @@ record_thumb_to_arm_glue (info, h)
bh = NULL;
val = globals->thumb_glue_size + 1;
bfd_coff_link_add_one_symbol (info, globals->bfd_of_glue_owner, tmp_name,
- BSF_GLOBAL, s, val, NULL, true, false, &bh);
+ BSF_GLOBAL, s, val, NULL, TRUE, FALSE, &bh);
/* If we mark it 'thumb', the disassembler will do a better job. */
myh = (struct coff_link_hash_entry *) bh;
@@ -1995,7 +2007,7 @@ record_thumb_to_arm_glue (info, h)
bh = NULL;
val = globals->thumb_glue_size + (globals->support_old_code ? 8 : 4);
bfd_coff_link_add_one_symbol (info, globals->bfd_of_glue_owner, tmp_name,
- BSF_LOCAL, s, val, NULL, true, false, &bh);
+ BSF_LOCAL, s, val, NULL, TRUE, FALSE, &bh);
free (tmp_name);
@@ -2009,7 +2021,7 @@ record_thumb_to_arm_glue (info, h)
This function is called from the linker scripts in ld/emultempl/
{armcoff/pe}.em */
-boolean
+bfd_boolean
bfd_arm_get_bfd_for_interworking (abfd, info)
bfd * abfd;
struct bfd_link_info * info;
@@ -2020,15 +2032,15 @@ bfd_arm_get_bfd_for_interworking (abfd, info)
/* If we are only performing a partial link do not bother
getting a bfd to hold the glue. */
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
globals = coff_arm_hash_table (info);
BFD_ASSERT (globals != NULL);
if (globals->bfd_of_glue_owner != NULL)
- return true;
+ return TRUE;
sec = bfd_get_section_by_name (abfd, ARM2THUMB_GLUE_SECTION_NAME);
@@ -2041,7 +2053,7 @@ bfd_arm_get_bfd_for_interworking (abfd, info)
if (sec == NULL
|| ! bfd_set_section_flags (abfd, sec, flags)
|| ! bfd_set_section_alignment (abfd, sec, 2))
- return false;
+ return FALSE;
}
sec = bfd_get_section_by_name (abfd, THUMB2ARM_GLUE_SECTION_NAME);
@@ -2055,16 +2067,16 @@ bfd_arm_get_bfd_for_interworking (abfd, info)
if (sec == NULL
|| ! bfd_set_section_flags (abfd, sec, flags)
|| ! bfd_set_section_alignment (abfd, sec, 2))
- return false;
+ return FALSE;
}
/* Save the bfd for later use. */
globals->bfd_of_glue_owner = abfd;
- return true;
+ return TRUE;
}
-boolean
+bfd_boolean
bfd_arm_process_before_allocation (abfd, info, support_old_code)
bfd * abfd;
struct bfd_link_info * info;
@@ -2075,8 +2087,8 @@ bfd_arm_process_before_allocation (abfd, info, support_old_code)
/* If we are only performing a partial link do not bother
to construct any glue. */
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
/* Here we have a bfd that is to be included on the link. We have a hook
to do reloc rummaging, before section sizes are nailed down. */
@@ -2094,7 +2106,7 @@ bfd_arm_process_before_allocation (abfd, info, support_old_code)
sec = abfd->sections;
if (sec == NULL)
- return true;
+ return TRUE;
for (; sec != NULL; sec = sec->next)
{
@@ -2178,7 +2190,7 @@ bfd_arm_process_before_allocation (abfd, info, support_old_code)
}
}
- return true;
+ return TRUE;
}
#endif /* ! defined (COFF_IMAGE_WITH_PE) */
@@ -2195,19 +2207,19 @@ bfd_arm_process_before_allocation (abfd, info, support_old_code)
#define coff_bfd_copy_private_bfd_data coff_arm_copy_private_bfd_data
#define coff_bfd_link_hash_table_create coff_arm_link_hash_table_create
-/* When doing a relocateable link, we want to convert ARM26 relocs
- into ARM26D relocs. */
+/* When doing a relocatable link, we want to convert ARM_26 relocs
+ into ARM_26D relocs. */
-static boolean
+static bfd_boolean
coff_arm_adjust_symndx (obfd, info, ibfd, sec, irel, adjustedp)
bfd *obfd ATTRIBUTE_UNUSED;
struct bfd_link_info *info ATTRIBUTE_UNUSED;
bfd *ibfd;
asection *sec;
struct internal_reloc *irel;
- boolean *adjustedp;
+ bfd_boolean *adjustedp;
{
- if (irel->r_type == 3)
+ if (irel->r_type == ARM_26)
{
struct coff_link_hash_entry *h;
@@ -2216,18 +2228,18 @@ coff_arm_adjust_symndx (obfd, info, ibfd, sec, irel, adjustedp)
&& (h->root.type == bfd_link_hash_defined
|| h->root.type == bfd_link_hash_defweak)
&& h->root.u.def.section->output_section == sec->output_section)
- irel->r_type = 7;
+ irel->r_type = ARM_26D;
}
- *adjustedp = false;
- return true;
+ *adjustedp = FALSE;
+ return TRUE;
}
/* Called when merging the private data areas of two BFDs.
This is important as it allows us to detect if we are
attempting to merge binaries compiled for different ARM
- targets, eg different CPUs or differents APCS's. */
+ targets, eg different CPUs or different APCS's. */
-static boolean
+static bfd_boolean
coff_arm_merge_private_bfd_data (ibfd, obfd)
bfd * ibfd;
bfd * obfd;
@@ -2235,16 +2247,21 @@ coff_arm_merge_private_bfd_data (ibfd, obfd)
BFD_ASSERT (ibfd != NULL && obfd != NULL);
if (ibfd == obfd)
- return true;
+ return TRUE;
/* If the two formats are different we cannot merge anything.
This is not an error, since it is permissable to change the
input and output formats. */
if ( ibfd->xvec->flavour != bfd_target_coff_flavour
|| obfd->xvec->flavour != bfd_target_coff_flavour)
- return true;
+ return TRUE;
+
+ /* Determine what should happen if the input ARM architecture
+ does not match the output ARM architecture. */
+ if (! bfd_arm_merge_machines (ibfd, obfd))
+ return FALSE;
- /* Verify that the APCS is the same for the two BFDs */
+ /* Verify that the APCS is the same for the two BFDs. */
if (APCS_SET (ibfd))
{
if (APCS_SET (obfd))
@@ -2260,7 +2277,7 @@ coff_arm_merge_private_bfd_data (ibfd, obfd)
);
bfd_set_error (bfd_error_wrong_format);
- return false;
+ return FALSE;
}
if (APCS_FLOAT_FLAG (obfd) != APCS_FLOAT_FLAG (ibfd))
@@ -2278,7 +2295,7 @@ coff_arm_merge_private_bfd_data (ibfd, obfd)
bfd_get_filename (obfd));
bfd_set_error (bfd_error_wrong_format);
- return false;
+ return FALSE;
}
if (PIC_FLAG (obfd) != PIC_FLAG (ibfd))
@@ -2295,7 +2312,7 @@ coff_arm_merge_private_bfd_data (ibfd, obfd)
bfd_get_filename (obfd));
bfd_set_error (bfd_error_wrong_format);
- return false;
+ return FALSE;
}
}
else
@@ -2334,12 +2351,12 @@ coff_arm_merge_private_bfd_data (ibfd, obfd)
}
}
- return true;
+ return TRUE;
}
/* Display the flags field. */
-static boolean
+static bfd_boolean
coff_arm_print_private_bfd_data (abfd, ptr)
bfd * abfd;
PTR ptr;
@@ -2353,7 +2370,7 @@ coff_arm_print_private_bfd_data (abfd, ptr)
if (APCS_SET (abfd))
{
- /* xgettext: APCS is ARM Prodecure Call Standard, it should not be translated. */
+ /* xgettext: APCS is ARM Procedure Call Standard, it should not be translated. */
fprintf (file, " [APCS-%d]", APCS_26_FLAG (abfd) ? 26 : 32);
if (APCS_FLOAT_FLAG (abfd))
@@ -2376,7 +2393,7 @@ coff_arm_print_private_bfd_data (abfd, ptr)
fputc ('\n', file);
- return true;
+ return TRUE;
}
/* Copies the given flags into the coff_tdata.flags field.
@@ -2386,7 +2403,7 @@ coff_arm_print_private_bfd_data (abfd, ptr)
Note: Although this function is static, it is explicitly
called from both coffcode.h and peicode.h. */
-static boolean
+static bfd_boolean
_bfd_coff_arm_set_private_flags (abfd, flags)
bfd * abfd;
flagword flags;
@@ -2404,7 +2421,7 @@ _bfd_coff_arm_set_private_flags (abfd, flags)
|| (APCS_FLOAT_FLAG (abfd) != (flags & F_APCS_FLOAT))
|| (PIC_FLAG (abfd) != (flags & F_PIC))
))
- return false;
+ return FALSE;
flag |= (flags & (F_APCS_FLOAT | F_PIC));
@@ -2431,13 +2448,13 @@ _bfd_coff_arm_set_private_flags (abfd, flags)
SET_INTERWORK_FLAG (abfd, flag);
- return true;
+ return TRUE;
}
/* Copy the important parts of the target specific data
from one instance of a BFD to another. */
-static boolean
+static bfd_boolean
coff_arm_copy_private_bfd_data (src, dest)
bfd * src;
bfd * dest;
@@ -2445,12 +2462,12 @@ coff_arm_copy_private_bfd_data (src, dest)
BFD_ASSERT (src != NULL && dest != NULL);
if (src == dest)
- return true;
+ return TRUE;
/* If the destination is not in the same format as the source, do not do
the copy. */
if (src->xvec != dest->xvec)
- return true;
+ return TRUE;
/* copy the flags field */
if (APCS_SET (src))
@@ -2459,13 +2476,13 @@ coff_arm_copy_private_bfd_data (src, dest)
{
/* If the src and dest have different APCS flag bits set, fail. */
if (APCS_26_FLAG (dest) != APCS_26_FLAG (src))
- return false;
+ return FALSE;
if (APCS_FLOAT_FLAG (dest) != APCS_FLOAT_FLAG (src))
- return false;
+ return FALSE;
if (PIC_FLAG (dest) != PIC_FLAG (src))
- return false;
+ return FALSE;
}
else
SET_APCS_FLAGS (dest, APCS_26_FLAG (src) | APCS_FLOAT_FLAG (src)
@@ -2498,7 +2515,7 @@ Warning: Clearing the interworking flag of %s because non-interworking code in %
}
}
- return true;
+ return TRUE;
}
/* Note: the definitions here of LOCAL_LABEL_PREFIX and USER_LABEL_PREIFX
@@ -2513,7 +2530,7 @@ Warning: Clearing the interworking flag of %s because non-interworking code in %
non-local.
b) Allow other prefixes than ".", e.g. an empty prefix would cause all
labels of the form Lxxx to be stripped. */
-static boolean
+static bfd_boolean
coff_arm_is_local_label_name (abfd, name)
bfd * abfd ATTRIBUTE_UNUSED;
const char * name;
@@ -2522,7 +2539,7 @@ coff_arm_is_local_label_name (abfd, name)
if (USER_LABEL_PREFIX[0] != 0)
{
if (strncmp (name, USER_LABEL_PREFIX, strlen (USER_LABEL_PREFIX)) == 0)
- return false;
+ return FALSE;
}
#endif
@@ -2535,7 +2552,7 @@ coff_arm_is_local_label_name (abfd, name)
size_t len = strlen (LOCAL_LABEL_PREFIX);
if (strncmp (name, LOCAL_LABEL_PREFIX, len) != 0)
- return false;
+ return FALSE;
/* Perform the checks below for the rest of the name. */
name += len;
@@ -2553,7 +2570,7 @@ coff_arm_is_local_label_name (abfd, name)
krk@cygnus.com */
-static boolean
+static bfd_boolean
coff_arm_link_output_has_begun (sub, info)
bfd * sub;
struct coff_final_link_info * info;
@@ -2562,7 +2579,7 @@ coff_arm_link_output_has_begun (sub, info)
|| sub == coff_arm_hash_table (info->info)->bfd_of_glue_owner);
}
-static boolean
+static bfd_boolean
coff_arm_final_link_postscript (abfd, pfinfo)
bfd * abfd ATTRIBUTE_UNUSED;
struct coff_final_link_info * pfinfo;
@@ -2576,12 +2593,12 @@ coff_arm_final_link_postscript (abfd, pfinfo)
if (globals->bfd_of_glue_owner != NULL)
{
if (! _bfd_coff_link_input_bfd (pfinfo, globals->bfd_of_glue_owner))
- return false;
+ return FALSE;
- globals->bfd_of_glue_owner->output_has_begun = true;
+ globals->bfd_of_glue_owner->output_has_begun = TRUE;
}
- return true;
+ return bfd_arm_update_notes (abfd, ARM_NOTE_SECTION);
}
#include "coffcode.h"
@@ -2605,9 +2622,9 @@ coff_arm_final_link_postscript (abfd, pfinfo)
#ifndef EXTRA_S_FLAGS
#ifdef COFF_WITH_PE
-#define EXTRA_S_FLAGS (SEC_LINK_ONCE | SEC_LINK_DUPLICATES)
+#define EXTRA_S_FLAGS (SEC_CODE | SEC_LINK_ONCE | SEC_LINK_DUPLICATES)
#else
-#define EXTRA_S_FLAGS 0
+#define EXTRA_S_FLAGS SEC_CODE
#endif
#endif
@@ -2615,5 +2632,5 @@ coff_arm_final_link_postscript (abfd, pfinfo)
extern const bfd_target TARGET_BIG_SYM ;
/* Target vectors. */
-CREATE_LITTLE_COFF_TARGET_VEC (TARGET_LITTLE_SYM, TARGET_LITTLE_NAME, D_PAGED, EXTRA_S_FLAGS, TARGET_UNDERSCORE, & TARGET_BIG_SYM)
-CREATE_BIG_COFF_TARGET_VEC (TARGET_BIG_SYM, TARGET_BIG_NAME, D_PAGED, EXTRA_S_FLAGS, TARGET_UNDERSCORE, & TARGET_LITTLE_SYM)
+CREATE_LITTLE_COFF_TARGET_VEC (TARGET_LITTLE_SYM, TARGET_LITTLE_NAME, D_PAGED, EXTRA_S_FLAGS, TARGET_UNDERSCORE, & TARGET_BIG_SYM, COFF_SWAP_TABLE)
+CREATE_BIG_COFF_TARGET_VEC (TARGET_BIG_SYM, TARGET_BIG_NAME, D_PAGED, EXTRA_S_FLAGS, TARGET_UNDERSCORE, & TARGET_LITTLE_SYM, COFF_SWAP_TABLE)
diff --git a/contrib/binutils/bfd/coff-aux.c b/contrib/binutils/bfd/coff-aux.c
index 53822f0..4d7cde5 100644
--- a/contrib/binutils/bfd/coff-aux.c
+++ b/contrib/binutils/bfd/coff-aux.c
@@ -1,5 +1,5 @@
/* BFD back-end for Apple M68K COFF A/UX 3.x files.
- Copyright 1996, 1997, 2000 Free Software Foundation, Inc.
+ Copyright 1996, 1997, 2000, 2002 Free Software Foundation, Inc.
Written by Richard Henderson <rth@tamu.edu>.
This file is part of BFD, the Binary File Descriptor library.
@@ -40,9 +40,9 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "bfd.h"
#include "sysdep.h"
-static boolean coff_m68k_aux_link_add_one_symbol
+static bfd_boolean coff_m68k_aux_link_add_one_symbol
PARAMS ((struct bfd_link_info *, bfd *, const char *, flagword,
- asection *, bfd_vma, const char *, boolean, boolean,
+ asection *, bfd_vma, const char *, bfd_boolean, bfd_boolean,
struct bfd_link_hash_entry **));
#define coff_link_add_one_symbol coff_m68k_aux_link_add_one_symbol
@@ -56,7 +56,7 @@ static boolean coff_m68k_aux_link_add_one_symbol
shared libraries work here, but can work if you are careful with
what you include in the shared object. */
-static boolean
+static bfd_boolean
coff_m68k_aux_link_add_one_symbol (info, abfd, name, flags, section, value,
string, copy, collect, hashp)
struct bfd_link_info *info;
@@ -66,8 +66,8 @@ coff_m68k_aux_link_add_one_symbol (info, abfd, name, flags, section, value,
asection *section;
bfd_vma value;
const char *string;
- boolean copy;
- boolean collect;
+ bfd_boolean copy;
+ bfd_boolean collect;
struct bfd_link_hash_entry **hashp;
{
struct bfd_link_hash_entry *h;
@@ -86,21 +86,21 @@ coff_m68k_aux_link_add_one_symbol (info, abfd, name, flags, section, value,
}
else
{
- h = bfd_link_hash_lookup (info->hash, name, true, copy, false);
+ h = bfd_link_hash_lookup (info->hash, name, TRUE, copy, FALSE);
if (h == NULL)
{
if (hashp != NULL)
*hashp = NULL;
- return false;
+ return FALSE;
}
}
if (info->notice_hash != (struct bfd_hash_table *) NULL
- && (bfd_hash_lookup (info->notice_hash, name, false, false)
+ && (bfd_hash_lookup (info->notice_hash, name, FALSE, FALSE)
!= (struct bfd_hash_entry *) NULL))
{
if (! (*info->callbacks->notice) (info, name, abfd, section, value))
- return false;
+ return FALSE;
}
if (hashp != (struct bfd_link_hash_entry **) NULL)
@@ -121,10 +121,10 @@ coff_m68k_aux_link_add_one_symbol (info, abfd, name, flags, section, value,
{
h->u.def.section = section;
h->u.def.value = value;
- return true;
+ return TRUE;
}
else if (bfd_is_abs_section (section) && !bfd_is_abs_section (msec))
- return true;
+ return TRUE;
}
}
diff --git a/contrib/binutils/bfd/coff-i386.c b/contrib/binutils/bfd/coff-i386.c
index dbeaef1..a24344a 100644
--- a/contrib/binutils/bfd/coff-i386.c
+++ b/contrib/binutils/bfd/coff-i386.c
@@ -1,6 +1,6 @@
/* BFD back-end for Intel 386 COFF files.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Support.
@@ -56,7 +56,7 @@ static reloc_howto_type *coff_i386_reloc_type_lookup
section for a reference to a common symbol is the value itself plus
any desired offset. Ian Taylor, Cygnus Support. */
-/* If we are producing relocateable output, we need to do some
+/* If we are producing relocatable output, we need to do some
adjustments to the object file that are not done by the
bfd_perform_relocation function. This function is called by every
reloc type to make any required adjustments. */
@@ -103,7 +103,7 @@ coff_i386_reloc (abfd, reloc_entry, symbol, data, input_section, output_bfd,
{
/* For some reason bfd_perform_relocation always effectively
ignores the addend for a COFF target when producing
- relocateable output. This seems to be always wrong for 386
+ relocatable output. This seems to be always wrong for 386
COFF, so we handle the addend here instead. */
#ifdef COFF_WITH_PE
if (output_bfd == (bfd *) NULL)
@@ -179,12 +179,12 @@ coff_i386_reloc (abfd, reloc_entry, symbol, data, input_section, output_bfd,
}
#ifdef COFF_WITH_PE
-/* Return true if this relocation should appear in the output .reloc
+/* Return TRUE if this relocation should appear in the output .reloc
section. */
-static boolean in_reloc_p PARAMS ((bfd *, reloc_howto_type *));
+static bfd_boolean in_reloc_p PARAMS ((bfd *, reloc_howto_type *));
-static boolean in_reloc_p (abfd, howto)
+static bfd_boolean in_reloc_p (abfd, howto)
bfd * abfd ATTRIBUTE_UNUSED;
reloc_howto_type *howto;
{
@@ -193,7 +193,7 @@ static boolean in_reloc_p (abfd, howto)
#endif /* COFF_WITH_PE */
#ifndef PCRELOFFSET
-#define PCRELOFFSET false
+#define PCRELOFFSET FALSE
#endif
static reloc_howto_type howto_table[] =
@@ -208,29 +208,29 @@ static reloc_howto_type howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
coff_i386_reloc, /* special_function */
"dir32", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* PE IMAGE_REL_I386_DIR32NB relocation (7). */
HOWTO (R_IMAGEBASE, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
coff_i386_reloc, /* special_function */
"rva32", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
EMPTY_HOWTO (010),
EMPTY_HOWTO (011),
EMPTY_HOWTO (012),
@@ -243,12 +243,12 @@ static reloc_howto_type howto_table[] =
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
8, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
coff_i386_reloc, /* special_function */
"8", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0x000000ff, /* src_mask */
0x000000ff, /* dst_mask */
PCRELOFFSET), /* pcrel_offset */
@@ -257,12 +257,12 @@ static reloc_howto_type howto_table[] =
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
coff_i386_reloc, /* special_function */
"16", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0x0000ffff, /* src_mask */
0x0000ffff, /* dst_mask */
PCRELOFFSET), /* pcrel_offset */
@@ -271,12 +271,12 @@ static reloc_howto_type howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
coff_i386_reloc, /* special_function */
"32", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
PCRELOFFSET), /* pcrel_offset */
@@ -285,12 +285,12 @@ static reloc_howto_type howto_table[] =
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
8, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
coff_i386_reloc, /* special_function */
"DISP8", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0x000000ff, /* src_mask */
0x000000ff, /* dst_mask */
PCRELOFFSET), /* pcrel_offset */
@@ -299,12 +299,12 @@ static reloc_howto_type howto_table[] =
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
coff_i386_reloc, /* special_function */
"DISP16", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0x0000ffff, /* src_mask */
0x0000ffff, /* dst_mask */
PCRELOFFSET), /* pcrel_offset */
@@ -313,12 +313,12 @@ static reloc_howto_type howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
coff_i386_reloc, /* special_function */
"DISP32", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
PCRELOFFSET) /* pcrel_offset */
@@ -386,13 +386,13 @@ static reloc_howto_type howto_table[] =
/* The PE relocate section routine. The only difference between this
and the regular routine is that we don't want to do anything for a
- relocateable link. */
+ relocatable link. */
-static boolean coff_pe_i386_relocate_section
+static bfd_boolean coff_pe_i386_relocate_section
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
struct internal_reloc *, struct internal_syment *, asection **));
-static boolean
+static bfd_boolean
coff_pe_i386_relocate_section (output_bfd, info, input_bfd,
input_section, contents, relocs, syms,
sections)
@@ -405,8 +405,8 @@ coff_pe_i386_relocate_section (output_bfd, info, input_bfd,
struct internal_syment *syms;
asection **sections;
{
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
return _bfd_coff_generic_relocate_section (output_bfd, info, input_bfd,
input_section, contents,
@@ -470,7 +470,7 @@ coff_i386_rtype_to_howto (abfd, sec, rel, h, sym, addendp)
#ifndef COFF_WITH_PE
/* If the output symbol is common (in which case this must be a
- relocateable link), we need to add in the final size of the
+ relocatable link), we need to add in the final size of the
common symbol. */
if (h != NULL && h->root.type == bfd_link_hash_common)
*addendp += h->root.u.c.size;
@@ -539,15 +539,16 @@ coff_i386_reloc_type_lookup (abfd, code)
a leading dot for local labels, so if TARGET_UNDERSCORE is defined
we treat all symbols starting with L as local. */
-static boolean coff_i386_is_local_label_name PARAMS ((bfd *, const char *));
+static bfd_boolean coff_i386_is_local_label_name
+ PARAMS ((bfd *, const char *));
-static boolean
+static bfd_boolean
coff_i386_is_local_label_name (abfd, name)
bfd *abfd;
const char *name;
{
if (name[0] == 'L')
- return true;
+ return TRUE;
return _bfd_coff_is_local_label_name (abfd, name);
}
diff --git a/contrib/binutils/bfd/coff-ia64.c b/contrib/binutils/bfd/coff-ia64.c
index 76d1bf6..2b5b557 100644
--- a/contrib/binutils/bfd/coff-ia64.c
+++ b/contrib/binutils/bfd/coff-ia64.c
@@ -1,5 +1,5 @@
/* BFD back-end for HP/Intel IA-64 COFF files.
- Copyright 1999, 2000, 2001 Free Software Foundation, Inc.
+ Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
Contributed by David Mosberger <davidm@hpl.hp.com>
This file is part of BFD, the Binary File Descriptor library.
@@ -49,17 +49,17 @@ static reloc_howto_type howto_table[] =
(cache_ptr)->howto = howto_table + (dst)->r_type;
#ifdef COFF_WITH_PE
-/* Return true if this relocation should
+/* Return TRUE if this relocation should
appear in the output .reloc section. */
-static boolean in_reloc_p PARAMS ((bfd *, reloc_howto_type *));
+static bfd_boolean in_reloc_p PARAMS ((bfd *, reloc_howto_type *));
-static boolean
+static bfd_boolean
in_reloc_p(abfd, howto)
bfd * abfd ATTRIBUTE_UNUSED;
reloc_howto_type *howto ATTRIBUTE_UNUSED;
{
- return 0; /* We don't do relocs for now... */
+ return FALSE; /* We don't do relocs for now... */
}
#endif
diff --git a/contrib/binutils/bfd/coff-ppc.c b/contrib/binutils/bfd/coff-ppc.c
index 4f8b15e..c1c2c32 100644
--- a/contrib/binutils/bfd/coff-ppc.c
+++ b/contrib/binutils/bfd/coff-ppc.c
@@ -1,6 +1,6 @@
/* BFD back-end for PowerPC Microsoft Portable Executable files.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Original version pieced together by Kim Knuttila (krk@cygnus.com)
@@ -9,30 +9,29 @@
coff files, in particular, those for the rs/6000, alpha, mips, and
intel backends, and the PE work for the arm.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, 59 Temple Place - Suite 330,
-Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/* Current State:
- objdump works
- relocs generated by gas
- ld will link files, but they do not run.
- dlltool will not produce correct output in some .reloc cases, and will
- not produce the right glue code for dll function calls.
-*/
+ not produce the right glue code for dll function calls. */
#include "bfd.h"
#include "sysdep.h"
@@ -54,19 +53,19 @@ Boston, MA 02111-1307, USA. */
/* This file is compiled more than once, but we only compile the
final_link routine once. */
-extern boolean ppc_bfd_coff_final_link
+extern bfd_boolean ppc_bfd_coff_final_link
PARAMS ((bfd *, struct bfd_link_info *));
extern void dump_toc PARAMS ((PTR));
-/* The toc is a set of bfd_vma fields. We use the fact that valid */
-/* addresses are even (i.e. the bit representing "1" is off) to allow */
-/* us to encode a little extra information in the field */
-/* - Unallocated addresses are intialized to 1. */
-/* - Allocated addresses are even numbers. */
-/* The first time we actually write a reference to the toc in the bfd, */
-/* we want to record that fact in a fixup file (if it is asked for), so */
-/* we keep track of whether or not an address has been written by marking */
-/* the low order bit with a "1" upon writing */
+/* The toc is a set of bfd_vma fields. We use the fact that valid
+ addresses are even (i.e. the bit representing "1" is off) to allow
+ us to encode a little extra information in the field
+ - Unallocated addresses are initialized to 1.
+ - Allocated addresses are even numbers.
+ The first time we actually write a reference to the toc in the bfd,
+ we want to record that fact in a fixup file (if it is asked for), so
+ we keep track of whether or not an address has been written by marking
+ the low order bit with a "1" upon writing. */
#define SET_UNALLOCATED(x) ((x) = 1)
#define IS_UNALLOCATED(x) ((x) == 1)
@@ -75,10 +74,10 @@ extern void dump_toc PARAMS ((PTR));
#define MARK_AS_WRITTEN(x) ((x) |= 1)
#define MAKE_ADDR_AGAIN(x) ((x) &= ~1)
-/* Turn on this check if you suspect something amiss in the hash tables */
+/* Turn on this check if you suspect something amiss in the hash tables. */
#ifdef DEBUG_HASH
-/* Need a 7 char string for an eye catcher */
+/* Need a 7 char string for an eye catcher. */
#define EYE "krkjunk"
#define HASH_CHECK_DCL char eye_catcher[8];
@@ -101,17 +100,17 @@ extern void dump_toc PARAMS ((PTR));
#endif
/* In order not to add an int to every hash table item for every coff
- linker, we define our own hash table, derived from the coff one */
+ linker, we define our own hash table, derived from the coff one. */
/* PE linker hash table entries. */
struct ppc_coff_link_hash_entry
{
- struct coff_link_hash_entry root; /* First entry, as required */
+ struct coff_link_hash_entry root; /* First entry, as required. */
/* As we wonder around the relocs, we'll keep the assigned toc_offset
- here */
- bfd_vma toc_offset; /* Our addition, as required */
+ here. */
+ bfd_vma toc_offset; /* Our addition, as required. */
int symbol_is_glue;
unsigned long int glue_insn;
@@ -122,20 +121,20 @@ struct ppc_coff_link_hash_entry
struct ppc_coff_link_hash_table
{
- struct coff_link_hash_table root; /* First entry, as required */
+ struct coff_link_hash_table root; /* First entry, as required. */
};
static struct bfd_hash_entry *ppc_coff_link_hash_newfunc
PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *,
const char *));
-static boolean ppc_coff_link_hash_table_init
+static bfd_boolean ppc_coff_link_hash_table_init
PARAMS ((struct ppc_coff_link_hash_table *, bfd *,
struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
struct bfd_hash_table *,
const char *)));
static struct bfd_link_hash_table *ppc_coff_link_hash_table_create
PARAMS ((bfd *));
-static boolean coff_ppc_relocate_section
+static bfd_boolean coff_ppc_relocate_section
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
struct internal_reloc *, struct internal_syment *, asection **));
static reloc_howto_type *coff_ppc_rtype_to_howto
@@ -172,11 +171,11 @@ ppc_coff_link_hash_newfunc (entry, table, string)
if (ret)
{
/* Initialize the local fields. */
- SET_UNALLOCATED(ret->toc_offset);
+ SET_UNALLOCATED (ret->toc_offset);
ret->symbol_is_glue = 0;
ret->glue_insn = 0;
- HASH_CHECK_INIT(ret);
+ HASH_CHECK_INIT (ret);
}
return (struct bfd_hash_entry *) ret;
@@ -184,7 +183,7 @@ ppc_coff_link_hash_newfunc (entry, table, string)
/* Initialize a PE linker hash table. */
-static boolean
+static bfd_boolean
ppc_coff_link_hash_table_init (table, abfd, newfunc)
struct ppc_coff_link_hash_table *table;
bfd *abfd;
@@ -216,13 +215,13 @@ ppc_coff_link_hash_table_create (abfd)
return &ret->root.root;
}
-/* Now, tailor coffcode.h to use our hash stuff */
+/* Now, tailor coffcode.h to use our hash stuff. */
#define coff_bfd_link_hash_table_create ppc_coff_link_hash_table_create
-/* The nt loader points the toc register to &toc + 32768, in order to */
-/* use the complete range of a 16-bit displacement. We have to adjust */
-/* for this when we fix up loads displaced off the toc reg. */
+/* The nt loader points the toc register to &toc + 32768, in order to
+ use the complete range of a 16-bit displacement. We have to adjust
+ for this when we fix up loads displaced off the toc reg. */
#define TOC_LOAD_ADJUSTMENT (-32768)
#define TOC_SECTION_NAME ".private.toc"
@@ -234,7 +233,7 @@ ppc_coff_link_hash_table_create (abfd)
from smaller values. Start with zero, widen, *then* decrement. */
#define MINUS_ONE (((bfd_vma)0) - 1)
-/* these should definitely go in a header file somewhere... */
+/* These should definitely go in a header file somewhere... */
/* NOP */
#define IMAGE_REL_PPC_ABSOLUTE 0x0000
@@ -284,31 +283,31 @@ ppc_coff_link_hash_table_create (abfd)
/* va of containing section (limited to 16 bits) */
#define IMAGE_REL_PPC_SECREL16 0x000F
-/* stuff to handle immediate data when the number of bits in the */
-/* data is greater than the number of bits in the immediate field */
-/* We need to do (usually) 32 bit arithmetic on 16 bit chunks */
+/* Stuff to handle immediate data when the number of bits in the
+ data is greater than the number of bits in the immediate field
+ We need to do (usually) 32 bit arithmetic on 16 bit chunks. */
#define IMAGE_REL_PPC_REFHI 0x0010
#define IMAGE_REL_PPC_REFLO 0x0011
#define IMAGE_REL_PPC_PAIR 0x0012
-/* This is essentially the same as tocrel16, with TOCDEFN assumed */
+/* This is essentially the same as tocrel16, with TOCDEFN assumed. */
#define IMAGE_REL_PPC_TOCREL16_DEFN 0x0013
-/* Flag bits in IMAGE_RELOCATION.TYPE */
+/* Flag bits in IMAGE_RELOCATION.TYPE. */
-/* subtract reloc value rather than adding it */
+/* Subtract reloc value rather than adding it. */
#define IMAGE_REL_PPC_NEG 0x0100
-/* fix branch prediction bit to predict branch taken */
+/* Fix branch prediction bit to predict branch taken. */
#define IMAGE_REL_PPC_BRTAKEN 0x0200
-/* fix branch prediction bit to predict branch not taken */
+/* Fix branch prediction bit to predict branch not taken. */
#define IMAGE_REL_PPC_BRNTAKEN 0x0400
-/* toc slot defined in file (or, data in toc) */
+/* TOC slot defined in file (or, data in toc). */
#define IMAGE_REL_PPC_TOCDEFN 0x0800
-/* masks to isolate above values in IMAGE_RELOCATION.Type */
+/* Masks to isolate above values in IMAGE_RELOCATION.Type. */
#define IMAGE_REL_PPC_TYPEMASK 0x00FF
#define IMAGE_REL_PPC_FLAGMASK 0x0F00
@@ -317,7 +316,7 @@ ppc_coff_link_hash_table_create (abfd)
#define EXTRACT_JUNK(x) \
((x) & ~(IMAGE_REL_PPC_TYPEMASK | IMAGE_REL_PPC_FLAGMASK))
-/* static helper functions to make relocation work */
+/* Static helper functions to make relocation work. */
/* (Work In Progress) */
static bfd_reloc_status_type ppc_refhi_reloc PARAMS ((bfd *abfd,
@@ -385,45 +384,40 @@ static bfd_reloc_status_type ppc_imglue_reloc PARAMS ((bfd *abfd,
bfd *output_bfd,
char **error));
-static boolean in_reloc_p PARAMS((bfd *abfd, reloc_howto_type *howto));
+static bfd_boolean in_reloc_p PARAMS((bfd *abfd, reloc_howto_type *howto));
/* FIXME: It'll take a while to get through all of these. I only need a few to
get us started, so those I'll make sure work. Those marked FIXME are either
- completely unverified or have a specific unknown marked in the comment */
-
-/*---------------------------------------------------------------------------*/
-/* */
-/* Relocation entries for Windows/NT on PowerPC. */
-/* */
-/* From the document "" we find the following listed as used relocs: */
-/* */
-/* ABSOLUTE : The noop */
-/* ADDR[64|32|16] : fields that hold addresses in data fields or the */
-/* 16 bit displacement field on a load/store. */
-/* ADDR[24|14] : fields that hold addresses in branch and cond */
-/* branches. These represent [26|16] bit addresses. */
-/* The low order 2 bits are preserved. */
-/* REL[24|14] : branches relative to the Instruction Address */
-/* register. These represent [26|16] bit addresses, */
-/* as before. The instruction field will be zero, and */
-/* the address of the SYM will be inserted at link time. */
-/* TOCREL16 : 16 bit displacement field referring to a slot in */
-/* toc. */
-/* TOCREL14 : 16 bit displacement field, similar to REL14 or ADDR14. */
-/* ADDR32NB : 32 bit address relative to the virtual origin. */
-/* (On the alpha, this is always a linker generated thunk)*/
-/* (i.e. 32bit addr relative to the image base) */
-/* SECREL : The value is relative to the start of the section */
-/* containing the symbol. */
-/* SECTION : access to the header containing the item. Supports the */
-/* codeview debugger. */
-/* */
-/* In particular, note that the document does not indicate that the */
-/* relocations listed in the header file are used. */
-/* */
-/* */
-/* */
-/*---------------------------------------------------------------------------*/
+ completely unverified or have a specific unknown marked in the comment. */
+
+/* Relocation entries for Windows/NT on PowerPC.
+
+ From the document "" we find the following listed as used relocs:
+
+ ABSOLUTE : The noop
+ ADDR[64|32|16] : fields that hold addresses in data fields or the
+ 16 bit displacement field on a load/store.
+ ADDR[24|14] : fields that hold addresses in branch and cond
+ branches. These represent [26|16] bit addresses.
+ The low order 2 bits are preserved.
+ REL[24|14] : branches relative to the Instruction Address
+ register. These represent [26|16] bit addresses,
+ as before. The instruction field will be zero, and
+ the address of the SYM will be inserted at link time.
+ TOCREL16 : 16 bit displacement field referring to a slot in
+ toc.
+ TOCREL14 : 16 bit displacement field, similar to REL14 or ADDR14.
+ ADDR32NB : 32 bit address relative to the virtual origin.
+ (On the alpha, this is always a linker generated thunk)
+ (i.e. 32bit addr relative to the image base)
+ SECREL : The value is relative to the start of the section
+ containing the symbol.
+ SECTION : access to the header containing the item. Supports the
+ codeview debugger.
+
+ In particular, note that the document does not indicate that the
+ relocations listed in the header file are used. */
+
static reloc_howto_type ppc_coff_howto_table[] =
{
@@ -433,15 +427,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* dont complain_on_overflow */
0, /* special_function */
"ABSOLUTE", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x00, /* src_mask */
0x00, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* IMAGE_REL_PPC_ADDR64 0x0001 64-bit address */
/* Unused: */
@@ -449,15 +443,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
0, /* rightshift */
3, /* size (0 = byte, 1 = short, 2 = long) */
64, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"ADDR64", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
MINUS_ONE, /* src_mask */
MINUS_ONE, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* IMAGE_REL_PPC_ADDR32 0x0002 32-bit address */
/* Used: */
@@ -465,15 +459,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"ADDR32", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* IMAGE_REL_PPC_ADDR24 0x0003 26-bit address, shifted left 2 (branch absolute) */
/* the LI field is in bit 6 through bit 29 is 24 bits, + 2 for the shift */
@@ -484,15 +478,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
26, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"ADDR24", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0x07fffffc, /* src_mask */
0x07fffffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* IMAGE_REL_PPC_ADDR16 0x0004 16-bit address */
/* Used: */
@@ -500,15 +494,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
0, /* special_function */
"ADDR16", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* IMAGE_REL_PPC_ADDR14 0x0005 */
/* 16-bit address, shifted left 2 (load doubleword) */
@@ -518,15 +512,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
1, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
0, /* special_function */
"ADDR16", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* IMAGE_REL_PPC_REL24 0x0006 */
/* 26-bit PC-relative offset, shifted left 2 (branch relative) */
@@ -535,15 +529,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
26, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
0, /* special_function */
"REL24", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0x3fffffc, /* src_mask */
0x3fffffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* IMAGE_REL_PPC_REL14 0x0007 */
/* 16-bit PC-relative offset, shifted left 2 (br cond relative) */
@@ -554,15 +548,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
1, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
0, /* special_function */
"ADDR16", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* IMAGE_REL_PPC_TOCREL16 0x0008 */
/* 16-bit offset from TOC base */
@@ -571,15 +565,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc_toc16_reloc, /* special_function */
"TOCREL16", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* IMAGE_REL_PPC_TOCREL14 0x0009 */
/* 16-bit offset from TOC base, shifted left 2 (load doubleword) */
@@ -588,15 +582,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
1, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
0, /* special_function */
"TOCREL14", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* IMAGE_REL_PPC_ADDR32NB 0x000A */
/* 32-bit addr w/ image base */
@@ -605,15 +599,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
0, /* special_function */
"ADDR32NB", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* IMAGE_REL_PPC_SECREL 0x000B */
/* va of containing section (as in an image sectionhdr) */
@@ -622,15 +616,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
ppc_secrel_reloc, /* special_function */
"SECREL", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* IMAGE_REL_PPC_SECTION 0x000C */
/* sectionheader number */
@@ -639,15 +633,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
ppc_section_reloc, /* special_function */
"SECTION", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* IMAGE_REL_PPC_IFGLUE 0x000D */
/* substitute TOC restore instruction iff symbol is glue code */
@@ -656,15 +650,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
0, /* special_function */
"IFGLUE", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* IMAGE_REL_PPC_IMGLUE 0x000E */
/* symbol is glue code; virtual address is TOC restore instruction */
@@ -673,15 +667,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc_imglue_reloc, /* special_function */
"IMGLUE", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* IMAGE_REL_PPC_SECREL16 0x000F */
/* va of containing section (limited to 16 bits) */
@@ -690,15 +684,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
0, /* special_function */
"SECREL16", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* IMAGE_REL_PPC_REFHI 0x0010 */
/* Unused: */
@@ -706,15 +700,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
ppc_refhi_reloc, /* special_function */
"REFHI", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* IMAGE_REL_PPC_REFLO 0x0011 */
/* Unused: */
@@ -722,15 +716,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
ppc_refhi_reloc, /* special_function */
"REFLO", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* IMAGE_REL_PPC_PAIR 0x0012 */
/* Unused: */
@@ -738,15 +732,15 @@ static reloc_howto_type ppc_coff_howto_table[] =
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
ppc_pair_reloc, /* special_function */
"PAIR", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* IMAGE_REL_PPC_TOCREL16_DEFN 0x0013 */
/* 16-bit offset from TOC base, without causing a definition */
@@ -755,19 +749,19 @@ static reloc_howto_type ppc_coff_howto_table[] =
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
0, /* special_function */
"TOCREL16, TOCDEFN", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
};
-/* Some really cheezy macros that can be turned on to test stderr :-) */
+/* Some really cheezy macros that can be turned on to test stderr :-) */
#ifdef DEBUG_RELOC
#define UN_IMPL(x) \
@@ -792,16 +786,14 @@ static reloc_howto_type ppc_coff_howto_table[] =
#define n_name _n._n_name
#define n_zeroes _n._n_n._n_zeroes
-#define n_offset _n._n_n._n_offset
-
-*/
+#define n_offset _n._n_n._n_offset */
-#define DUMP_RELOC2(n,r) \
-{ \
- fprintf (stderr,"%s sym %d, r_vaddr %d %s\n", \
- n, r->r_symndx, r->r_vaddr,\
+#define DUMP_RELOC2(n,r) \
+{ \
+ fprintf (stderr,"%s sym %d, r_vaddr %d %s\n", \
+ n, r->r_symndx, r->r_vaddr, \
(((r->r_type) & IMAGE_REL_PPC_TOCDEFN) == 0) \
- ?" ":" TOCDEFN" ); \
+ ?" ":" TOCDEFN" ); \
}
#else
@@ -810,14 +802,13 @@ static reloc_howto_type ppc_coff_howto_table[] =
#define DUMP_RELOC2(n,r)
#endif
-/* toc construction and management routines */
+/* TOC construction and management routines. */
/* This file is compiled twice, and these variables are defined in one
of the compilations. FIXME: This is confusing and weird. Also,
BFD should not use global variables. */
-extern bfd* bfd_of_toc_owner;
+extern bfd * bfd_of_toc_owner;
extern long int global_toc_size;
-
extern long int import_table_size;
extern long int first_thunk_address;
extern long int thunk_size;
@@ -858,7 +849,7 @@ record_toc (toc_section, our_toc_offset, cat, name)
enum ref_category cat;
const char *name;
{
- /* add this entry to our toc addr-offset-name list */
+ /* Add this entry to our toc addr-offset-name list. */
bfd_size_type amt = sizeof (struct list_ele);
struct list_ele *t = (struct list_ele *) bfd_malloc (amt);
@@ -884,13 +875,13 @@ record_toc (toc_section, our_toc_offset, cat, name)
#ifdef COFF_IMAGE_WITH_PE
-static boolean ppc_record_toc_entry
+static bfd_boolean ppc_record_toc_entry
PARAMS ((bfd *, struct bfd_link_info *, asection *, int, enum toc_type));
static void ppc_mark_symbol_as_glue
PARAMS ((bfd *, int, struct internal_reloc *));
-/* record a toc offset against a symbol */
-static boolean
+/* Record a toc offset against a symbol. */
+static bfd_boolean
ppc_record_toc_entry(abfd, info, sec, sym, toc_kind)
bfd *abfd;
struct bfd_link_info *info ATTRIBUTE_UNUSED;
@@ -914,16 +905,19 @@ ppc_record_toc_entry(abfd, info, sec, sym, toc_kind)
if (h == 0)
{
local_syms = obj_coff_local_toc_table(abfd);
+
if (local_syms == 0)
{
unsigned int i;
bfd_size_type amt;
+
/* allocate a table */
amt = (bfd_size_type) obj_raw_syment_count (abfd) * sizeof (int);
local_syms = (int *) bfd_zalloc (abfd, amt);
if (local_syms == 0)
- return false;
+ return FALSE;
obj_coff_local_toc_table (abfd) = local_syms;
+
for (i = 0; i < obj_raw_syment_count (abfd); ++i)
{
SET_UNALLOCATED (local_syms[i]);
@@ -935,12 +929,12 @@ ppc_record_toc_entry(abfd, info, sec, sym, toc_kind)
local_syms[sym] = global_toc_size;
global_toc_size += 4;
- /* The size must fit in a 16bit displacment */
+ /* The size must fit in a 16-bit displacement. */
if (global_toc_size > 65535)
{
(*_bfd_error_handler) (_("TOC overflow"));
bfd_set_error (bfd_error_file_too_big);
- return false;
+ return FALSE;
}
}
}
@@ -948,27 +942,27 @@ ppc_record_toc_entry(abfd, info, sec, sym, toc_kind)
{
name = h->root.root.root.string;
- /* check to see if there's a toc slot allocated. If not, do it
- here. It will be used in relocate_section */
+ /* Check to see if there's a toc slot allocated. If not, do it
+ here. It will be used in relocate_section. */
if (IS_UNALLOCATED(h->toc_offset))
{
h->toc_offset = global_toc_size;
global_toc_size += 4;
- /* The size must fit in a 16bit displacment */
+ /* The size must fit in a 16-bit displacement. */
if (global_toc_size >= 65535)
{
(*_bfd_error_handler) (_("TOC overflow"));
bfd_set_error (bfd_error_file_too_big);
- return false;
+ return FALSE;
}
}
}
- return true;
+ return TRUE;
}
-/* record a toc offset against a symbol */
+/* Record a toc offset against a symbol. */
static void
ppc_mark_symbol_as_glue(abfd, sym, rel)
bfd *abfd;
@@ -989,10 +983,10 @@ ppc_mark_symbol_as_glue(abfd, sym, rel)
#endif /* COFF_IMAGE_WITH_PE */
-/* Return true if this relocation should
+/* Return TRUE if this relocation should
appear in the output .reloc section. */
-static boolean in_reloc_p(abfd, howto)
+static bfd_boolean in_reloc_p(abfd, howto)
bfd * abfd ATTRIBUTE_UNUSED;
reloc_howto_type *howto;
{
@@ -1013,9 +1007,9 @@ static boolean in_reloc_p(abfd, howto)
#if 0
-/* this function is in charge of performing all the ppc PE relocations */
-/* Don't yet know if we want to do this this particular way ... (krk) */
-/* FIXME: (it is not yet enabled) */
+/* This function is in charge of performing all the ppc PE relocations
+ Don't yet know if we want to do this this particular way ... (krk). */
+/* FIXME: (it is not yet enabled). */
static bfd_reloc_status_type
pe_ppc_reloc (abfd, reloc_entry, symbol_in, data, input_section, output_bfd,
@@ -1028,9 +1022,9 @@ pe_ppc_reloc (abfd, reloc_entry, symbol_in, data, input_section, output_bfd,
bfd *output_bfd;
char **error_message;
{
- /* the consth relocation comes in two parts, we have to remember
- the state between calls, in these variables */
- static boolean part1_consth_active = false;
+ /* The consth relocation comes in two parts, we have to remember
+ the state between calls, in these variables. */
+ static bfd_boolean part1_consth_active = FALSE;
static unsigned long part1_consth_value;
unsigned long sym_value;
@@ -1041,7 +1035,7 @@ pe_ppc_reloc (abfd, reloc_entry, symbol_in, data, input_section, output_bfd,
if (output_bfd)
{
- /* Partial linking - do nothing */
+ /* Partial linking - do nothing. */
reloc_entry->address += input_section->output_offset;
return bfd_reloc_ok;
}
@@ -1049,10 +1043,10 @@ pe_ppc_reloc (abfd, reloc_entry, symbol_in, data, input_section, output_bfd,
if (symbol_in != NULL
&& bfd_is_und_section (symbol_in->section))
{
- /* Keep the state machine happy in case we're called again */
+ /* Keep the state machine happy in case we're called again. */
if (r_type == IMAGE_REL_PPC_REFHI)
{
- part1_consth_active = true;
+ part1_consth_active = TRUE;
part1_consth_value = 0;
}
return(bfd_reloc_undefined);
@@ -1060,7 +1054,7 @@ pe_ppc_reloc (abfd, reloc_entry, symbol_in, data, input_section, output_bfd,
if ((part1_consth_active) && (r_type != IMAGE_REL_PPC_PAIR))
{
- part1_consth_active = false;
+ part1_consth_active = FALSE;
*error_message = (char *) _("Missing PAIR");
return(bfd_reloc_dangerous);
}
@@ -1074,7 +1068,7 @@ pe_ppc_reloc (abfd, reloc_entry, symbol_in, data, input_section, output_bfd,
/* The reloc processing routine for the optimized COFF linker. */
-static boolean
+static bfd_boolean
coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
contents, relocs, syms, sections)
bfd *output_bfd;
@@ -1088,19 +1082,19 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
{
struct internal_reloc *rel;
struct internal_reloc *relend;
- boolean hihalf;
+ bfd_boolean hihalf;
bfd_vma hihalf_val;
asection *toc_section = 0;
bfd_vma relocation;
reloc_howto_type *howto = 0;
- /* If we are performing a relocateable link, we don't need to do a
+ /* If we are performing a relocatable link, we don't need to do a
thing. The caller will take care of adjusting the reloc
addresses and symbol indices. */
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
- hihalf = false;
+ hihalf = FALSE;
hihalf_val = 0;
rel = relocs;
@@ -1151,7 +1145,7 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
sec = NULL;
val = 0;
- /* FIXME: PAIR unsupported in the following code */
+ /* FIXME: PAIR unsupported in the following code. */
if (h == NULL)
{
if (symndx == -1)
@@ -1182,14 +1176,14 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
{
if (! ((*info->callbacks->undefined_symbol)
(info, h->root.root.root.string, input_bfd, input_section,
- rel->r_vaddr - input_section->vma, true)))
- return false;
+ rel->r_vaddr - input_section->vma, TRUE)))
+ return FALSE;
}
}
rstat = bfd_reloc_ok;
- /* Each case must do its own relocation, setting rstat appropriately */
+ /* Each case must do its own relocation, setting rstat appropriately. */
switch (r_type)
{
default:
@@ -1197,7 +1191,7 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
(_("%s: unsupported relocation type 0x%02x"),
bfd_archive_filename (input_bfd), r_type);
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
case IMAGE_REL_PPC_TOCREL16:
{
bfd_signed_vma our_toc_offset;
@@ -1217,16 +1211,15 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
}
}
- /*
- * Amazing bit tricks present. As we may have seen earlier, we
- * use the 1 bit to tell us whether or not a toc offset has been
- * allocated. Now that they've all been allocated, we will use
- * the 1 bit to tell us if we've written this particular toc
- * entry out.
- */
- fixit = false;
+ /* Amazing bit tricks present. As we may have seen earlier, we
+ use the 1 bit to tell us whether or not a toc offset has been
+ allocated. Now that they've all been allocated, we will use
+ the 1 bit to tell us if we've written this particular toc
+ entry out. */
+ fixit = FALSE;
if (h == 0)
- { /* it is a file local symbol */
+ {
+ /* It is a file local symbol. */
int *local_toc_table;
const char *name;
@@ -1238,15 +1231,14 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
if (IS_WRITTEN(our_toc_offset))
{
- /* if it has been written out, it is marked with the
+ /* If it has been written out, it is marked with the
1 bit. Fix up our offset, but do not write it out
- again.
- */
+ again. */
MAKE_ADDR_AGAIN(our_toc_offset);
}
else
{
- /* write out the toc entry */
+ /* Write out the toc entry. */
record_toc (toc_section, our_toc_offset, priv,
strdup (name));
@@ -1254,7 +1246,7 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
toc_section->contents + our_toc_offset);
MARK_AS_WRITTEN(local_toc_table[symndx]);
- fixit = true;
+ fixit = TRUE;
}
}
else
@@ -1277,13 +1269,12 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
Import Address Table is mapped immediately following
the toc, some trippy library code trying for speed on
dll linkage, takes advantage of that and considers
- the IAT to be part of the toc, thus saving a load.
- */
+ the IAT to be part of the toc, thus saving a load. */
our_toc_offset = val - (toc_section->output_section->vma
+ toc_section->output_offset);
- /* The size must still fit in a 16bit displacment */
+ /* The size must still fit in a 16-bit displacement. */
if ((bfd_vma) our_toc_offset >= 65535)
{
(*_bfd_error_handler)
@@ -1291,18 +1282,17 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
bfd_archive_filename (input_bfd), name,
(unsigned long) our_toc_offset);
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
record_toc (toc_section, our_toc_offset, pub,
strdup (name));
}
- else if (IS_WRITTEN(our_toc_offset))
+ else if (IS_WRITTEN (our_toc_offset))
{
- /* if it has been written out, it is marked with the
+ /* If it has been written out, it is marked with the
1 bit. Fix up our offset, but do not write it out
- again.
- */
+ again. */
MAKE_ADDR_AGAIN(our_toc_offset);
}
else
@@ -1310,36 +1300,35 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
record_toc(toc_section, our_toc_offset, pub,
strdup (name));
- /* write out the toc entry */
+ /* Write out the toc entry. */
bfd_put_32 (output_bfd, val,
toc_section->contents + our_toc_offset);
MARK_AS_WRITTEN(h->toc_offset);
- /* The tricky part is that this is the address that */
- /* needs a .reloc entry for it */
- fixit = true;
+ /* The tricky part is that this is the address that
+ needs a .reloc entry for it. */
+ fixit = TRUE;
}
}
if (fixit && info->base_file)
{
/* So if this is non pcrelative, and is referenced
- to a section or a common symbol, then it needs a reloc */
+ to a section or a common symbol, then it needs a reloc. */
- /* relocation to a symbol in a section which
+ /* Relocation to a symbol in a section which
isn't absolute - we output the address here
- to a file */
-
+ to a file. */
bfd_vma addr = (toc_section->output_section->vma
+ toc_section->output_offset + our_toc_offset);
- if (coff_data(output_bfd)->pe)
+ if (coff_data (output_bfd)->pe)
addr -= pe_data(output_bfd)->pe_opthdr.ImageBase;
fwrite (&addr, 1,4, (FILE *) info->base_file);
}
- /* FIXME: this test is conservative */
+ /* FIXME: this test is conservative. */
if ((r_flags & IMAGE_REL_PPC_TOCDEFN) != IMAGE_REL_PPC_TOCDEFN
&& (bfd_vma) our_toc_offset > toc_section->_raw_size)
{
@@ -1348,24 +1337,24 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
bfd_archive_filename (input_bfd),
(unsigned long) toc_section->_raw_size);
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
- /* Now we know the relocation for this toc reference */
+ /* Now we know the relocation for this toc reference. */
relocation = our_toc_offset + TOC_LOAD_ADJUSTMENT;
rstat = _bfd_relocate_contents (howto, input_bfd, relocation, loc);
}
break;
case IMAGE_REL_PPC_IFGLUE:
{
- /* To solve this, we need to know whether or not the symbol */
- /* appearing on the call instruction is a glue function or not. */
- /* A glue function must announce itself via a IMGLUE reloc, and */
- /* the reloc contains the required toc restore instruction */
-
+ /* To solve this, we need to know whether or not the symbol
+ appearing on the call instruction is a glue function or not.
+ A glue function must announce itself via a IMGLUE reloc, and
+ the reloc contains the required toc restore instruction. */
bfd_vma x;
const char *my_name;
- DUMP_RELOC2(howto->name, rel);
+
+ DUMP_RELOC2 (howto->name, rel);
if (h != 0)
{
@@ -1379,25 +1368,24 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
}
break;
case IMAGE_REL_PPC_SECREL:
- /* Unimplemented: codeview debugging information */
+ /* Unimplemented: codeview debugging information. */
/* For fast access to the header of the section
containing the item. */
break;
case IMAGE_REL_PPC_SECTION:
- /* Unimplemented: codeview debugging information */
+ /* Unimplemented: codeview debugging information. */
/* Is used to indicate that the value should be relative
to the beginning of the section that contains the
- symbol */
+ symbol. */
break;
case IMAGE_REL_PPC_ABSOLUTE:
{
const char *my_name;
+
if (h == 0)
- my_name = (syms+symndx)->_n._n_name;
+ my_name = (syms+symndx)->_n._n_name;
else
- {
- my_name = h->root.root.root.string;
- }
+ my_name = h->root.root.root.string;
fprintf (stderr,
_("Warning: unsupported reloc %s <file %s, section %s>\n"),
@@ -1413,8 +1401,9 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
case IMAGE_REL_PPC_IMGLUE:
{
/* There is nothing to do now. This reloc was noted in the first
- pass over the relocs, and the glue instruction extracted */
+ pass over the relocs, and the glue instruction extracted. */
const char *my_name;
+
if (h->symbol_is_glue == 1)
break;
my_name = h->root.root.root.string;
@@ -1423,22 +1412,24 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
(_("%s: Out of order IMGLUE reloc for %s"),
bfd_archive_filename (input_bfd), my_name);
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
case IMAGE_REL_PPC_ADDR32NB:
{
const char *name = 0;
- DUMP_RELOC2(howto->name, rel);
+
+ DUMP_RELOC2 (howto->name, rel);
if (strncmp(".idata$2",input_section->name,8) == 0 && first_thunk_address == 0)
{
- /* set magic values */
+ /* Set magic values. */
int idata5offset;
struct coff_link_hash_entry *myh;
+
myh = coff_link_hash_lookup (coff_hash_table (info),
"__idata5_magic__",
- false, false, true);
+ FALSE, FALSE, TRUE);
first_thunk_address = myh->root.u.def.value +
sec->output_section->vma +
sec->output_offset -
@@ -1447,17 +1438,18 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
idata5offset = myh->root.u.def.value;
myh = coff_link_hash_lookup (coff_hash_table (info),
"__idata6_magic__",
- false, false, true);
+ FALSE, FALSE, TRUE);
thunk_size = myh->root.u.def.value - idata5offset;
myh = coff_link_hash_lookup (coff_hash_table (info),
"__idata4_magic__",
- false, false, true);
+ FALSE, FALSE, TRUE);
import_table_size = myh->root.u.def.value;
}
if (h == 0)
- { /* it is a file local symbol */
+ {
+ /* It is a file local symbol. */
sym = syms + symndx;
name = sym->_n._n_name;
}
@@ -1466,11 +1458,11 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
char *target = 0;
name = h->root.root.root.string;
- if (strcmp(".idata$2", name) == 0)
+ if (strcmp (".idata$2", name) == 0)
target = "__idata2_magic__";
- else if (strcmp(".idata$4", name) == 0)
+ else if (strcmp (".idata$4", name) == 0)
target = "__idata4_magic__";
- else if (strcmp(".idata$5", name) == 0)
+ else if (strcmp (".idata$5", name) == 0)
target = "__idata5_magic__";
if (target != 0)
@@ -1479,7 +1471,7 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
myh = coff_link_hash_lookup (coff_hash_table (info),
target,
- false, false, true);
+ FALSE, FALSE, TRUE);
if (myh == 0)
{
/* Missing magic cookies. Something is very wrong. */
@@ -1493,7 +1485,7 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
int idata5offset;
myh = coff_link_hash_lookup (coff_hash_table (info),
"__idata5_magic__",
- false, false, true);
+ FALSE, FALSE, TRUE);
first_thunk_address = myh->root.u.def.value +
sec->output_section->vma +
sec->output_offset -
@@ -1502,22 +1494,22 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
idata5offset = myh->root.u.def.value;
myh = coff_link_hash_lookup (coff_hash_table (info),
"__idata6_magic__",
- false, false, true);
+ FALSE, FALSE, TRUE);
thunk_size = myh->root.u.def.value - idata5offset;
myh = coff_link_hash_lookup (coff_hash_table (info),
"__idata4_magic__",
- false, false, true);
+ FALSE, FALSE, TRUE);
import_table_size = myh->root.u.def.value;
}
}
}
rstat = _bfd_relocate_contents (howto,
- input_bfd,
- val -
- pe_data(output_bfd)->pe_opthdr.ImageBase,
- loc);
+ input_bfd,
+ val -
+ pe_data (output_bfd)->pe_opthdr.ImageBase,
+ loc);
}
break;
@@ -1542,24 +1534,23 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
break;
}
- if ( info->base_file )
+ if (info->base_file)
{
/* So if this is non pcrelative, and is referenced
- to a section or a common symbol, then it needs a reloc */
- if (sym && pe_data(output_bfd)->in_reloc_p(output_bfd, howto))
+ to a section or a common symbol, then it needs a reloc. */
+ if (sym && pe_data(output_bfd)->in_reloc_p (output_bfd, howto))
{
- /* relocation to a symbol in a section which
+ /* Relocation to a symbol in a section which
isn't absolute - we output the address here
- to a file */
+ to a file. */
bfd_vma addr = rel->r_vaddr
- input_section->vma
+ input_section->output_offset
+ input_section->output_section->vma;
- if (coff_data(output_bfd)->pe)
- {
- addr -= pe_data(output_bfd)->pe_opthdr.ImageBase;
- }
+ if (coff_data (output_bfd)->pe)
+ addr -= pe_data (output_bfd)->pe_opthdr.ImageBase;
+
fwrite (&addr, 1,4, (FILE *) info->base_file);
}
}
@@ -1595,15 +1586,12 @@ coff_ppc_relocate_section (output_bfd, info, input_bfd, input_section,
(info, name, howto->name,
(bfd_vma) 0, input_bfd,
input_section, rel->r_vaddr - input_section->vma)))
- {
- return false;
- }
+ return FALSE;
}
}
-
}
- return true;
+ return TRUE;
}
#ifdef COFF_IMAGE_WITH_PE
@@ -1677,7 +1665,7 @@ dump_toc (vfile)
fprintf (file, "\n");
}
-boolean
+bfd_boolean
ppc_allocate_toc_section (info)
struct bfd_link_info *info ATTRIBUTE_UNUSED;
{
@@ -1686,21 +1674,17 @@ ppc_allocate_toc_section (info)
bfd_size_type amt;
static char test_char = '1';
- if ( global_toc_size == 0 ) /* FIXME: does this get me in trouble? */
- return true;
+ if ( global_toc_size == 0 ) /* FIXME: does this get me in trouble? */
+ return TRUE;
if (bfd_of_toc_owner == 0)
- {
- /* No toc owner? Something is very wrong. */
- abort ();
- }
+ /* No toc owner? Something is very wrong. */
+ abort ();
s = bfd_get_section_by_name ( bfd_of_toc_owner , TOC_SECTION_NAME);
if (s == NULL)
- {
- /* No toc section? Something is very wrong. */
- abort ();
- }
+ /* No toc section? Something is very wrong. */
+ abort ();
amt = global_toc_size;
foo = (bfd_byte *) bfd_alloc (bfd_of_toc_owner, amt);
@@ -1709,10 +1693,10 @@ ppc_allocate_toc_section (info)
s->_raw_size = s->_cooked_size = global_toc_size;
s->contents = foo;
- return true;
+ return TRUE;
}
-boolean
+bfd_boolean
ppc_process_before_allocation (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -1720,72 +1704,64 @@ ppc_process_before_allocation (abfd, info)
asection *sec;
struct internal_reloc *i, *rel;
- /* here we have a bfd that is to be included on the link. We have a hook
+ /* Here we have a bfd that is to be included on the link. We have a hook
to do reloc rummaging, before section sizes are nailed down. */
+ _bfd_coff_get_external_symbols (abfd);
- _bfd_coff_get_external_symbols(abfd);
-
- /* rummage around all the relocs and map the toc */
+ /* Rummage around all the relocs and map the toc. */
sec = abfd->sections;
if (sec == 0)
- {
- return true;
- }
+ return TRUE;
for (; sec != 0; sec = sec->next)
- {
- if (sec->reloc_count == 0)
- continue;
+ {
+ if (sec->reloc_count == 0)
+ continue;
- /* load the relocs */
- /* FIXME: there may be a storage leak here */
- i=_bfd_coff_read_internal_relocs(abfd,sec,1,0,0,0);
+ /* load the relocs */
+ /* FIXME: there may be a storage leak here */
+ i=_bfd_coff_read_internal_relocs(abfd,sec,1,0,0,0);
- if (i == 0)
- abort ();
+ if (i == 0)
+ abort ();
- for (rel=i;rel<i+sec->reloc_count;++rel)
- {
- unsigned short r_type = EXTRACT_TYPE (rel->r_type);
- unsigned short r_flags = EXTRACT_FLAGS(rel->r_type);
- boolean ok = true;
+ for (rel = i; rel < i + sec->reloc_count; ++rel)
+ {
+ unsigned short r_type = EXTRACT_TYPE (rel->r_type);
+ unsigned short r_flags = EXTRACT_FLAGS (rel->r_type);
+ bfd_boolean ok = TRUE;
- DUMP_RELOC2(ppc_coff_howto_table[r_type].name, rel);
+ DUMP_RELOC2 (ppc_coff_howto_table[r_type].name, rel);
- switch(r_type)
- {
- case IMAGE_REL_PPC_TOCREL16:
- /* if TOCDEFN is on, ignore as someone else has allocated the
- toc entry */
- if ( (r_flags & IMAGE_REL_PPC_TOCDEFN) != IMAGE_REL_PPC_TOCDEFN )
- ok = ppc_record_toc_entry(abfd, info, sec,
- rel->r_symndx, default_toc);
- if (!ok)
- return false;
- break;
- case IMAGE_REL_PPC_IMGLUE:
- ppc_mark_symbol_as_glue(abfd, rel->r_symndx, rel);
- break;
- default:
- break;
- }
- }
- }
+ switch(r_type)
+ {
+ case IMAGE_REL_PPC_TOCREL16:
+ /* If TOCDEFN is on, ignore as someone else has allocated the
+ toc entry. */
+ if ((r_flags & IMAGE_REL_PPC_TOCDEFN) != IMAGE_REL_PPC_TOCDEFN)
+ ok = ppc_record_toc_entry(abfd, info, sec,
+ rel->r_symndx, default_toc);
+ if (!ok)
+ return FALSE;
+ break;
+ case IMAGE_REL_PPC_IMGLUE:
+ ppc_mark_symbol_as_glue (abfd, rel->r_symndx, rel);
+ break;
+ default:
+ break;
+ }
+ }
+ }
- return true;
+ return TRUE;
}
#endif
static bfd_reloc_status_type
-ppc_refhi_reloc (abfd,
- reloc_entry,
- symbol,
- data,
- input_section,
- output_bfd,
- error_message)
+ppc_refhi_reloc (abfd, reloc_entry, symbol, data,
+ input_section, output_bfd, error_message)
bfd *abfd ATTRIBUTE_UNUSED;
arelent *reloc_entry ATTRIBUTE_UNUSED;
asymbol *symbol ATTRIBUTE_UNUSED;
@@ -1806,13 +1782,8 @@ ppc_refhi_reloc (abfd,
#if 0
static bfd_reloc_status_type
-ppc_reflo_reloc (abfd,
- reloc_entry,
- symbol,
- data,
- input_section,
- output_bfd,
- error_message)
+ppc_reflo_reloc (abfd, reloc_entry, symbol, data,
+ input_section, output_bfd, error_message)
bfd *abfd;
arelent *reloc_entry;
asymbol *symbol;
@@ -1833,13 +1804,8 @@ ppc_reflo_reloc (abfd,
#endif
static bfd_reloc_status_type
-ppc_pair_reloc (abfd,
- reloc_entry,
- symbol,
- data,
- input_section,
- output_bfd,
- error_message)
+ppc_pair_reloc (abfd, reloc_entry, symbol, data,
+ input_section, output_bfd, error_message)
bfd *abfd ATTRIBUTE_UNUSED;
arelent *reloc_entry ATTRIBUTE_UNUSED;
asymbol *symbol ATTRIBUTE_UNUSED;
@@ -1858,13 +1824,8 @@ ppc_pair_reloc (abfd,
}
static bfd_reloc_status_type
-ppc_toc16_reloc (abfd,
- reloc_entry,
- symbol,
- data,
- input_section,
- output_bfd,
- error_message)
+ppc_toc16_reloc (abfd, reloc_entry, symbol, data,
+ input_section, output_bfd, error_message)
bfd *abfd ATTRIBUTE_UNUSED;
arelent *reloc_entry ATTRIBUTE_UNUSED;
asymbol *symbol ATTRIBUTE_UNUSED;
@@ -1873,33 +1834,24 @@ ppc_toc16_reloc (abfd,
bfd *output_bfd;
char **error_message ATTRIBUTE_UNUSED;
{
- UN_IMPL("TOCREL16");
- DUMP_RELOC("TOCREL16",reloc_entry);
+ UN_IMPL ("TOCREL16");
+ DUMP_RELOC ("TOCREL16",reloc_entry);
if (output_bfd == (bfd *) NULL)
- {
- return bfd_reloc_continue;
- }
+ return bfd_reloc_continue;
return bfd_reloc_ok;
}
#if 0
-/* ADDR32NB : 32 bit address relative to the virtual origin. */
-/* (On the alpha, this is always a linker generated thunk)*/
-/* (i.e. 32bit addr relative to the image base) */
-/* */
-/* */
+/* ADDR32NB : 32 bit address relative to the virtual origin.
+ (On the alpha, this is always a linker generated thunk)
+ (i.e. 32bit addr relative to the image base). */
static bfd_reloc_status_type
-ppc_addr32nb_reloc (abfd,
- reloc_entry,
- symbol,
- data,
- input_section,
- output_bfd,
- error_message)
+ppc_addr32nb_reloc (abfd, reloc_entry, symbol, data,
+ input_section, output_bfd, error_message)
bfd *abfd;
arelent *reloc_entry;
asymbol *symbol;
@@ -1917,13 +1869,8 @@ ppc_addr32nb_reloc (abfd,
#endif
static bfd_reloc_status_type
-ppc_secrel_reloc (abfd,
- reloc_entry,
- symbol,
- data,
- input_section,
- output_bfd,
- error_message)
+ppc_secrel_reloc (abfd, reloc_entry, symbol, data,
+ input_section, output_bfd, error_message)
bfd *abfd ATTRIBUTE_UNUSED;
arelent *reloc_entry ATTRIBUTE_UNUSED;
asymbol *symbol ATTRIBUTE_UNUSED;
@@ -1942,13 +1889,8 @@ ppc_secrel_reloc (abfd,
}
static bfd_reloc_status_type
-ppc_section_reloc (abfd,
- reloc_entry,
- symbol,
- data,
- input_section,
- output_bfd,
- error_message)
+ppc_section_reloc (abfd, reloc_entry, symbol, data,
+ input_section, output_bfd, error_message)
bfd *abfd ATTRIBUTE_UNUSED;
arelent *reloc_entry ATTRIBUTE_UNUSED;
asymbol *symbol ATTRIBUTE_UNUSED;
@@ -1967,13 +1909,8 @@ ppc_section_reloc (abfd,
}
static bfd_reloc_status_type
-ppc_imglue_reloc (abfd,
- reloc_entry,
- symbol,
- data,
- input_section,
- output_bfd,
- error_message)
+ppc_imglue_reloc (abfd, reloc_entry, symbol, data,
+ input_section, output_bfd, error_message)
bfd *abfd ATTRIBUTE_UNUSED;
arelent *reloc_entry ATTRIBUTE_UNUSED;
asymbol *symbol ATTRIBUTE_UNUSED;
@@ -1994,19 +1931,16 @@ ppc_imglue_reloc (abfd,
#define MAX_RELOC_INDEX \
(sizeof (ppc_coff_howto_table) / sizeof (ppc_coff_howto_table[0]) - 1)
-/* FIXME: There is a possiblity that when we read in a reloc from a file,
+/* FIXME: There is a possibility that when we read in a reloc from a file,
that there are some bits encoded in the upper portion of the
- type field. Not yet implemented.
-*/
-static void ppc_coff_rtype2howto PARAMS ((arelent *relent,
- struct internal_reloc *internal));
+ type field. Not yet implemented. */
+static void ppc_coff_rtype2howto PARAMS ((arelent *, struct internal_reloc *));
static void
ppc_coff_rtype2howto (relent, internal)
arelent *relent;
struct internal_reloc *internal;
{
-
/* We can encode one of three things in the type field, aside from the
type:
1. IMAGE_REL_PPC_NEG - indicates the value field is a subtraction
@@ -2015,19 +1949,18 @@ ppc_coff_rtype2howto (relent, internal)
the branch is expected to be taken or not.
3. IMAGE_REL_PPC_TOCDEFN - toc slot definition in the file
For now, we just strip this stuff to find the type, and ignore it other
- than that.
- */
+ than that. */
reloc_howto_type *howto;
unsigned short r_type = EXTRACT_TYPE (internal->r_type);
unsigned short r_flags = EXTRACT_FLAGS(internal->r_type);
unsigned short junk = EXTRACT_JUNK (internal->r_type);
- /* the masking process only slices off the bottom byte for r_type. */
+ /* The masking process only slices off the bottom byte for r_type. */
if ( r_type > MAX_RELOC_INDEX )
abort ();
- /* check for absolute crap */
- if ( junk != 0 )
+ /* Check for absolute crap. */
+ if (junk != 0)
abort ();
switch(r_type)
@@ -2040,15 +1973,15 @@ ppc_coff_rtype2howto (relent, internal)
case IMAGE_REL_PPC_ADDR32NB:
case IMAGE_REL_PPC_SECTION:
case IMAGE_REL_PPC_SECREL:
- DUMP_RELOC2(ppc_coff_howto_table[r_type].name, internal);
+ DUMP_RELOC2 (ppc_coff_howto_table[r_type].name, internal);
howto = ppc_coff_howto_table + r_type;
break;
case IMAGE_REL_PPC_IMGLUE:
- DUMP_RELOC2(ppc_coff_howto_table[r_type].name, internal);
+ DUMP_RELOC2 (ppc_coff_howto_table[r_type].name, internal);
howto = ppc_coff_howto_table + r_type;
break;
case IMAGE_REL_PPC_TOCREL16:
- DUMP_RELOC2(ppc_coff_howto_table[r_type].name, internal);
+ DUMP_RELOC2 (ppc_coff_howto_table[r_type].name, internal);
if (r_flags & IMAGE_REL_PPC_TOCDEFN)
howto = ppc_coff_howto_table + IMAGE_REL_PPC_TOCREL16_DEFN;
else
@@ -2064,7 +1997,6 @@ ppc_coff_rtype2howto (relent, internal)
}
relent->howto = howto;
-
}
static reloc_howto_type *
@@ -2086,19 +2018,18 @@ coff_ppc_rtype_to_howto (abfd, sec, rel, h, sym, addendp)
the branch is expected to be taken or not.
3. IMAGE_REL_PPC_TOCDEFN - toc slot definition in the file
For now, we just strip this stuff to find the type, and ignore it other
- than that.
- */
+ than that. */
- unsigned short r_type = EXTRACT_TYPE (rel->r_type);
- unsigned short r_flags = EXTRACT_FLAGS(rel->r_type);
- unsigned short junk = EXTRACT_JUNK (rel->r_type);
+ unsigned short r_type = EXTRACT_TYPE (rel->r_type);
+ unsigned short r_flags = EXTRACT_FLAGS (rel->r_type);
+ unsigned short junk = EXTRACT_JUNK (rel->r_type);
- /* the masking process only slices off the bottom byte for r_type. */
- if ( r_type > MAX_RELOC_INDEX )
+ /* The masking process only slices off the bottom byte for r_type. */
+ if (r_type > MAX_RELOC_INDEX)
abort ();
- /* check for absolute crap */
- if ( junk != 0 )
+ /* Check for absolute crap. */
+ if (junk != 0)
abort ();
switch(r_type)
@@ -2141,7 +2072,7 @@ coff_ppc_rtype_to_howto (abfd, sec, rel, h, sym, addendp)
return howto;
}
-/* a cheesy little macro to make the code a little more readable */
+/* A cheesy little macro to make the code a little more readable. */
#define HOW2MAP(bfd_rtype,ppc_rtype) \
case bfd_rtype: return &ppc_coff_howto_table[ppc_rtype]
@@ -2167,7 +2098,6 @@ ppc_coff_reloc_type_lookup (abfd, code)
default:
return NULL;
}
- /*NOTREACHED*/
}
#undef HOW2MAP
@@ -2229,8 +2159,7 @@ ppc_coff_reloc_type_lookup (abfd, code)
2. It's not clear to me that being the last bfd read necessarily means
that you are the last bfd closed.
3. Doing it on a "swap in" hook depends on when the "swap in" is called,
- and how often, etc. It's not clear to me that there isn't a hole here.
-*/
+ and how often, etc. It's not clear to me that there isn't a hole here. */
static void ppc_coff_swap_sym_in_hook PARAMS ((bfd *, PTR, PTR));
static void
@@ -2239,21 +2168,19 @@ ppc_coff_swap_sym_in_hook (abfd, ext1, in1)
PTR ext1 ATTRIBUTE_UNUSED;
PTR in1;
{
- struct internal_syment *in = (struct internal_syment *)in1;
+ struct internal_syment * in = (struct internal_syment *)in1;
- if (bfd_of_toc_owner != 0) /* we already have a toc, so go home */
+ if (bfd_of_toc_owner != 0) /* We already have a toc, so go home. */
return;
- if (strcmp(in->_n._n_name, ".toc") == 0)
+ if (strcmp (in->_n._n_name, ".toc") == 0)
{
flagword flags;
register asection *s;
- s = bfd_get_section_by_name ( abfd , TOC_SECTION_NAME);
+ s = bfd_get_section_by_name (abfd, TOC_SECTION_NAME);
if (s != NULL)
- {
- return;
- }
+ return;
flags = SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS | SEC_IN_MEMORY ;
@@ -2262,12 +2189,10 @@ ppc_coff_swap_sym_in_hook (abfd, ext1, in1)
if (s == NULL
|| !bfd_set_section_flags (abfd, s, flags)
|| !bfd_set_section_alignment (abfd, s, 2))
- {
- /* FIXME: set appropriate bfd error */
- abort ();
- }
+ /* FIXME: set appropriate bfd error. */
+ abort ();
- /* save the bfd for later allocation */
+ /* Save the bfd for later allocation. */
bfd_of_toc_owner = abfd;
}
@@ -2278,17 +2203,17 @@ ppc_coff_swap_sym_in_hook (abfd, ext1, in1)
#ifndef COFF_IMAGE_WITH_PE
-static boolean ppc_do_last PARAMS ((bfd *));
+static bfd_boolean ppc_do_last PARAMS ((bfd *));
static bfd *ppc_get_last PARAMS ((void));
-static boolean
+static bfd_boolean
ppc_do_last (abfd)
bfd *abfd;
{
if (abfd == bfd_of_toc_owner)
- return true;
+ return TRUE;
else
- return false;
+ return FALSE;
}
static bfd *
@@ -2297,7 +2222,7 @@ ppc_get_last()
return bfd_of_toc_owner;
}
-/* this piece of machinery exists only to guarantee that the bfd that holds
+/* This piece of machinery exists only to guarantee that the bfd that holds
the toc section is written last.
This does depend on bfd_make_section attaching a new section to the
@@ -2306,19 +2231,18 @@ ppc_get_last()
This is otherwise intended to be functionally the same as
cofflink.c:_bfd_coff_final_link(). It is specifically different only
where the POWERPC_LE_PE macro modifies the code. It is left in as a
- precise form of comment. krk@cygnus.com
-*/
+ precise form of comment. krk@cygnus.com */
/* Do the final link step. */
-boolean
+bfd_boolean
ppc_bfd_coff_final_link (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
{
bfd_size_type symesz;
struct coff_final_link_info finfo;
- boolean debug_merge_allocated;
+ bfd_boolean debug_merge_allocated;
asection *o;
struct bfd_link_order *p;
bfd_size_type max_sym_count;
@@ -2351,7 +2275,7 @@ ppc_bfd_coff_final_link (abfd, info)
finfo.contents = NULL;
finfo.external_relocs = NULL;
finfo.internal_relocs = NULL;
- debug_merge_allocated = false;
+ debug_merge_allocated = FALSE;
coff_data (abfd)->link_info = info;
@@ -2361,13 +2285,13 @@ ppc_bfd_coff_final_link (abfd, info)
if (! coff_debug_merge_hash_table_init (&finfo.debug_merge))
goto error_return;
- debug_merge_allocated = true;
+ debug_merge_allocated = TRUE;
/* Compute the file positions for all the sections. */
if (! abfd->output_has_begun)
{
if (! bfd_coff_compute_section_file_positions (abfd))
- return false;
+ return FALSE;
}
/* Count the line numbers and relocation entries required for the
@@ -2382,9 +2306,9 @@ ppc_bfd_coff_final_link (abfd, info)
{
o->reloc_count = 0;
o->lineno_count = 0;
+
for (p = o->link_order_head; p != NULL; p = p->next)
{
-
if (p->type == bfd_indirect_link_order)
{
asection *sec;
@@ -2395,13 +2319,13 @@ ppc_bfd_coff_final_link (abfd, info)
link. This will normally be every section. We need
to do this so that we can identify any sections which
the linker has decided to not include. */
- sec->linker_mark = true;
+ sec->linker_mark = TRUE;
if (info->strip == strip_none
|| info->strip == strip_some)
o->lineno_count += sec->lineno_count;
- if (info->relocateable)
+ if (info->relocatable)
o->reloc_count += sec->reloc_count;
if (sec->_raw_size > max_contents_size)
@@ -2411,7 +2335,7 @@ ppc_bfd_coff_final_link (abfd, info)
if (sec->reloc_count > max_reloc_count)
max_reloc_count = sec->reloc_count;
}
- else if (info->relocateable
+ else if (info->relocatable
&& (p->type == bfd_section_reloc_link_order
|| p->type == bfd_symbol_reloc_link_order))
++o->reloc_count;
@@ -2426,9 +2350,9 @@ ppc_bfd_coff_final_link (abfd, info)
}
}
- /* If doing a relocateable link, allocate space for the pointers we
+ /* If doing a relocatable link, allocate space for the pointers we
need to keep. */
- if (info->relocateable)
+ if (info->relocatable)
{
unsigned int i;
@@ -2437,8 +2361,10 @@ ppc_bfd_coff_final_link (abfd, info)
amt = abfd->section_count + 1;
amt *= sizeof (struct coff_link_section_info);
finfo.section_info = (struct coff_link_section_info *) bfd_malloc (amt);
+
if (finfo.section_info == NULL)
goto error_return;
+
for (i = 0; i <= abfd->section_count; i++)
{
finfo.section_info[i].relocs = NULL;
@@ -2451,6 +2377,7 @@ ppc_bfd_coff_final_link (abfd, info)
line_filepos = rel_filepos;
linesz = bfd_coff_linesz (abfd);
max_output_reloc_count = 0;
+
for (o = abfd->sections; o != NULL; o = o->next)
{
if (o->lineno_count == 0)
@@ -2474,9 +2401,9 @@ ppc_bfd_coff_final_link (abfd, info)
Because of this problem, we also keep the relocs in
memory until the end of the link. This wastes memory,
- but only when doing a relocateable link, which is not the
+ but only when doing a relocatable link, which is not the
common case. */
- BFD_ASSERT (info->relocateable);
+ BFD_ASSERT (info->relocatable);
amt = o->reloc_count;
amt *= sizeof (struct internal_reloc);
finfo.section_info[o->target_index].relocs =
@@ -2509,7 +2436,7 @@ ppc_bfd_coff_final_link (abfd, info)
{
bfd_size_type sz;
- sub->output_has_begun = false;
+ sub->output_has_begun = FALSE;
sz = obj_raw_syment_count (sub);
if (sz > max_sym_count)
max_sym_count = sz;
@@ -2528,7 +2455,7 @@ ppc_bfd_coff_final_link (abfd, info)
finfo.linenos = (bfd_byte *) bfd_malloc (amt);
finfo.contents = (bfd_byte *) bfd_malloc (max_contents_size);
finfo.external_relocs = (bfd_byte *) bfd_malloc (max_reloc_count * relsz);
- if (! info->relocateable)
+ if (! info->relocatable)
{
amt = max_reloc_count * sizeof (struct internal_reloc);
finfo.internal_relocs = (struct internal_reloc *) bfd_malloc (amt);
@@ -2540,7 +2467,7 @@ ppc_bfd_coff_final_link (abfd, info)
|| (finfo.linenos == NULL && max_lineno_count > 0)
|| (finfo.contents == NULL && max_contents_size > 0)
|| (finfo.external_relocs == NULL && max_reloc_count > 0)
- || (! info->relocateable
+ || (! info->relocatable
&& finfo.internal_relocs == NULL
&& max_reloc_count > 0))
goto error_return;
@@ -2575,7 +2502,7 @@ ppc_bfd_coff_final_link (abfd, info)
{
if (! _bfd_coff_link_input_bfd (&finfo, sub))
goto error_return;
- sub->output_has_begun = true;
+ sub->output_has_begun = TRUE;
}
}
else if (p->type == bfd_section_reloc_link_order
@@ -2600,14 +2527,13 @@ ppc_bfd_coff_final_link (abfd, info)
if (! _bfd_coff_link_input_bfd (&finfo, last_one))
goto error_return;
}
- last_one->output_has_begun = true;
+ last_one->output_has_begun = TRUE;
}
#endif
/* Free up the buffers used by _bfd_coff_link_input_bfd. */
-
coff_debug_merge_hash_table_free (&finfo.debug_merge);
- debug_merge_allocated = false;
+ debug_merge_allocated = FALSE;
if (finfo.internal_syms != NULL)
{
@@ -2659,11 +2585,11 @@ ppc_bfd_coff_final_link (abfd, info)
pos = obj_sym_filepos (abfd) + finfo.last_file_index * symesz;
if (bfd_seek (abfd, pos, SEEK_SET) != 0
|| bfd_bwrite (finfo.outsyms, symesz, abfd) != symesz)
- return false;
+ return FALSE;
}
/* Write out the global symbols. */
- finfo.failed = false;
+ finfo.failed = FALSE;
coff_link_hash_traverse (coff_hash_table (info), _bfd_coff_write_global_sym,
(PTR) &finfo);
if (finfo.failed)
@@ -2676,7 +2602,7 @@ ppc_bfd_coff_final_link (abfd, info)
finfo.outsyms = NULL;
}
- if (info->relocateable)
+ if (info->relocatable)
{
/* Now that we have written out all the global symbols, we know
the symbol indices to use for relocs against them, and we can
@@ -2740,7 +2666,7 @@ ppc_bfd_coff_final_link (abfd, info)
if (coff_hash_table (info)->stab_info != NULL)
{
if (! _bfd_write_stab_strings (abfd, &coff_hash_table (info)->stab_info))
- return false;
+ return FALSE;
}
/* Write out the string table. */
@@ -2750,7 +2676,7 @@ ppc_bfd_coff_final_link (abfd, info)
pos = obj_sym_filepos (abfd) + obj_raw_syment_count (abfd) * symesz;
if (bfd_seek (abfd, pos, SEEK_SET) != 0)
- return false;
+ return FALSE;
#if STRING_SIZE_SIZE == 4
H_PUT_32 (abfd,
@@ -2762,10 +2688,10 @@ ppc_bfd_coff_final_link (abfd, info)
if (bfd_bwrite (strbuf, (bfd_size_type) STRING_SIZE_SIZE, abfd)
!= STRING_SIZE_SIZE)
- return false;
+ return FALSE;
if (! _bfd_stringtab_emit (abfd, finfo.strtab))
- return false;
+ return FALSE;
}
_bfd_stringtab_free (finfo.strtab);
@@ -2774,7 +2700,7 @@ ppc_bfd_coff_final_link (abfd, info)
not try to write out the symbols. */
bfd_get_symcount (abfd) = 0;
- return true;
+ return TRUE;
error_return:
if (debug_merge_allocated)
@@ -2812,7 +2738,7 @@ ppc_bfd_coff_final_link (abfd, info)
free (finfo.internal_relocs);
if (external_relocs != NULL)
free (external_relocs);
- return false;
+ return FALSE;
}
#endif
diff --git a/contrib/binutils/bfd/coff-rs6000.c b/contrib/binutils/bfd/coff-rs6000.c
index 5a0b8aa..56e34e2 100644
--- a/contrib/binutils/bfd/coff-rs6000.c
+++ b/contrib/binutils/bfd/coff-rs6000.c
@@ -1,5 +1,5 @@
/* BFD back-end for IBM RS/6000 "XCOFF" files.
- Copyright 1990-1999, 2000, 2001, 2002
+ Copyright 1990-1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
FIXME: Can someone provide a transliteration of this name into ASCII?
Using the following chars caused a compiler warning on HIUX (so I replaced
@@ -36,29 +36,46 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "libcoff.h"
#include "libxcoff.h"
-extern boolean _bfd_xcoff_mkobject PARAMS ((bfd *));
-extern boolean _bfd_xcoff_copy_private_bfd_data PARAMS ((bfd *, bfd *));
-extern boolean _bfd_xcoff_is_local_label_name PARAMS ((bfd *, const char *));
+extern bfd_boolean _bfd_xcoff_mkobject
+ PARAMS ((bfd *));
+extern bfd_boolean _bfd_xcoff_copy_private_bfd_data
+ PARAMS ((bfd *, bfd *));
+extern bfd_boolean _bfd_xcoff_is_local_label_name
+ PARAMS ((bfd *, const char *));
extern reloc_howto_type *_bfd_xcoff_reloc_type_lookup
PARAMS ((bfd *, bfd_reloc_code_real_type));
-extern boolean _bfd_xcoff_slurp_armap PARAMS ((bfd *));
-extern const bfd_target *_bfd_xcoff_archive_p PARAMS ((bfd *));
-extern PTR _bfd_xcoff_read_ar_hdr PARAMS ((bfd *));
-extern bfd *_bfd_xcoff_openr_next_archived_file PARAMS ((bfd *, bfd *));
-extern int _bfd_xcoff_stat_arch_elt PARAMS ((bfd *, struct stat *));
-extern boolean _bfd_xcoff_write_armap
+extern bfd_boolean _bfd_xcoff_slurp_armap
+ PARAMS ((bfd *));
+extern const bfd_target *_bfd_xcoff_archive_p
+ PARAMS ((bfd *));
+extern PTR _bfd_xcoff_read_ar_hdr
+ PARAMS ((bfd *));
+extern bfd *_bfd_xcoff_openr_next_archived_file
+ PARAMS ((bfd *, bfd *));
+extern int _bfd_xcoff_stat_arch_elt
+ PARAMS ((bfd *, struct stat *));
+extern bfd_boolean _bfd_xcoff_write_armap
PARAMS ((bfd *, unsigned int, struct orl *, unsigned int, int));
-extern boolean _bfd_xcoff_write_archive_contents PARAMS ((bfd *));
-extern int _bfd_xcoff_sizeof_headers PARAMS ((bfd *, boolean));
-extern void _bfd_xcoff_swap_sym_in PARAMS ((bfd *, PTR, PTR));
-extern unsigned int _bfd_xcoff_swap_sym_out PARAMS ((bfd *, PTR, PTR));
-extern void _bfd_xcoff_swap_aux_in PARAMS ((bfd *, PTR, int, int, int, int, PTR));
-extern unsigned int _bfd_xcoff_swap_aux_out PARAMS ((bfd *, PTR, int, int, int, int, PTR));
-static void xcoff_swap_reloc_in PARAMS ((bfd *, PTR, PTR));
-static unsigned int xcoff_swap_reloc_out PARAMS ((bfd *, PTR, PTR));
+extern bfd_boolean _bfd_xcoff_write_archive_contents
+ PARAMS ((bfd *));
+extern int _bfd_xcoff_sizeof_headers
+ PARAMS ((bfd *, bfd_boolean));
+extern void _bfd_xcoff_swap_sym_in
+ PARAMS ((bfd *, PTR, PTR));
+extern unsigned int _bfd_xcoff_swap_sym_out
+ PARAMS ((bfd *, PTR, PTR));
+extern void _bfd_xcoff_swap_aux_in
+ PARAMS ((bfd *, PTR, int, int, int, int, PTR));
+extern unsigned int _bfd_xcoff_swap_aux_out
+ PARAMS ((bfd *, PTR, int, int, int, int, PTR));
+static void xcoff_swap_reloc_in
+ PARAMS ((bfd *, PTR, PTR));
+static unsigned int xcoff_swap_reloc_out
+ PARAMS ((bfd *, PTR, PTR));
/* Forward declare xcoff_rtype2howto for coffcode.h macro. */
-void xcoff_rtype2howto PARAMS ((arelent *, struct internal_reloc *));
+void xcoff_rtype2howto
+ PARAMS ((arelent *, struct internal_reloc *));
/* coffcode.h needs these to be defined. */
#define RS6000COFF_C 1
@@ -82,11 +99,14 @@ void xcoff_rtype2howto PARAMS ((arelent *, struct internal_reloc *));
#define coff_bfd_is_local_label_name _bfd_xcoff_is_local_label_name
#define coff_bfd_reloc_type_lookup _bfd_xcoff_reloc_type_lookup
#ifdef AIX_CORE
-extern const bfd_target * rs6000coff_core_p PARAMS ((bfd *abfd));
-extern boolean rs6000coff_core_file_matches_executable_p
+extern const bfd_target * rs6000coff_core_p
+ PARAMS ((bfd *abfd));
+extern bfd_boolean rs6000coff_core_file_matches_executable_p
PARAMS ((bfd *cbfd, bfd *ebfd));
-extern char *rs6000coff_core_file_failing_command PARAMS ((bfd *abfd));
-extern int rs6000coff_core_file_failing_signal PARAMS ((bfd *abfd));
+extern char *rs6000coff_core_file_failing_command
+ PARAMS ((bfd *abfd));
+extern int rs6000coff_core_file_failing_signal
+ PARAMS ((bfd *abfd));
#define CORE_FILE_P rs6000coff_core_p
#define coff_core_file_failing_command \
rs6000coff_core_file_failing_command
@@ -115,13 +135,16 @@ extern int rs6000coff_core_file_failing_signal PARAMS ((bfd *abfd));
/* The main body of code is in coffcode.h. */
-static const char *normalize_filename PARAMS ((bfd *));
-static boolean xcoff_write_armap_old
+static const char *normalize_filename
+ PARAMS ((bfd *));
+static bfd_boolean xcoff_write_armap_old
PARAMS ((bfd *, unsigned int, struct orl *, unsigned int, int));
-static boolean xcoff_write_armap_big
+static bfd_boolean xcoff_write_armap_big
PARAMS ((bfd *, unsigned int, struct orl *, unsigned int, int));
-static boolean xcoff_write_archive_contents_old PARAMS ((bfd *));
-static boolean xcoff_write_archive_contents_big PARAMS ((bfd *));
+static bfd_boolean xcoff_write_archive_contents_old
+ PARAMS ((bfd *));
+static bfd_boolean xcoff_write_archive_contents_big
+ PARAMS ((bfd *));
static void xcoff_swap_ldhdr_in
PARAMS ((bfd *, const PTR, struct internal_ldhdr *));
static void xcoff_swap_ldhdr_out
@@ -134,72 +157,78 @@ static void xcoff_swap_ldrel_in
PARAMS ((bfd *, const PTR, struct internal_ldrel *));
static void xcoff_swap_ldrel_out
PARAMS ((bfd *, const struct internal_ldrel *, PTR));
-static boolean xcoff_ppc_relocate_section
+static bfd_boolean xcoff_ppc_relocate_section
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
struct internal_reloc *, struct internal_syment *, asection **));
-static boolean _bfd_xcoff_put_ldsymbol_name
+static bfd_boolean _bfd_xcoff_put_ldsymbol_name
PARAMS ((bfd *, struct xcoff_loader_info *, struct internal_ldsym *,
const char *));
static asection *xcoff_create_csect_from_smclas
PARAMS ((bfd *, union internal_auxent *, const char *));
-static boolean xcoff_is_lineno_count_overflow PARAMS ((bfd *, bfd_vma));
-static boolean xcoff_is_reloc_count_overflow PARAMS ((bfd *, bfd_vma));
+static bfd_boolean xcoff_is_lineno_count_overflow
+ PARAMS ((bfd *, bfd_vma));
+static bfd_boolean xcoff_is_reloc_count_overflow
+ PARAMS ((bfd *, bfd_vma));
static bfd_vma xcoff_loader_symbol_offset
PARAMS ((bfd *, struct internal_ldhdr *));
static bfd_vma xcoff_loader_reloc_offset
PARAMS ((bfd *, struct internal_ldhdr *));
-static boolean xcoff_generate_rtinit
- PARAMS((bfd *, const char *, const char *, boolean));
-static boolean do_pad PARAMS((bfd *, unsigned int));
-static boolean do_copy PARAMS((bfd *, bfd *));
-static boolean do_shared_object_padding PARAMS ((bfd *, bfd *, ufile_ptr *, int));
+static bfd_boolean xcoff_generate_rtinit
+ PARAMS ((bfd *, const char *, const char *, bfd_boolean));
+static bfd_boolean do_pad
+ PARAMS ((bfd *, unsigned int));
+static bfd_boolean do_copy
+ PARAMS ((bfd *, bfd *));
+static bfd_boolean do_shared_object_padding
+ PARAMS ((bfd *, bfd *, ufile_ptr *, int));
/* Relocation functions */
-static boolean xcoff_reloc_type_br PARAMS ((XCOFF_RELOC_FUNCTION_ARGS));
+static bfd_boolean xcoff_reloc_type_br
+ PARAMS ((XCOFF_RELOC_FUNCTION_ARGS));
-static boolean xcoff_complain_overflow_dont_func
+static bfd_boolean xcoff_complain_overflow_dont_func
PARAMS ((XCOFF_COMPLAIN_FUNCTION_ARGS));
-static boolean xcoff_complain_overflow_bitfield_func
+static bfd_boolean xcoff_complain_overflow_bitfield_func
PARAMS ((XCOFF_COMPLAIN_FUNCTION_ARGS));
-static boolean xcoff_complain_overflow_signed_func
+static bfd_boolean xcoff_complain_overflow_signed_func
PARAMS ((XCOFF_COMPLAIN_FUNCTION_ARGS));
-static boolean xcoff_complain_overflow_unsigned_func
+static bfd_boolean xcoff_complain_overflow_unsigned_func
PARAMS ((XCOFF_COMPLAIN_FUNCTION_ARGS));
-boolean (*xcoff_calculate_relocation[XCOFF_MAX_CALCULATE_RELOCATION])
+bfd_boolean (*xcoff_calculate_relocation[XCOFF_MAX_CALCULATE_RELOCATION])
PARAMS ((XCOFF_RELOC_FUNCTION_ARGS)) =
{
- xcoff_reloc_type_pos, /* R_POS (0x00) */
- xcoff_reloc_type_neg, /* R_NEG (0x01) */
- xcoff_reloc_type_rel, /* R_REL (0x02) */
- xcoff_reloc_type_toc, /* R_TOC (0x03) */
+ xcoff_reloc_type_pos, /* R_POS (0x00) */
+ xcoff_reloc_type_neg, /* R_NEG (0x01) */
+ xcoff_reloc_type_rel, /* R_REL (0x02) */
+ xcoff_reloc_type_toc, /* R_TOC (0x03) */
xcoff_reloc_type_fail, /* R_RTB (0x04) */
- xcoff_reloc_type_toc, /* R_GL (0x05) */
- xcoff_reloc_type_toc, /* R_TCL (0x06) */
- xcoff_reloc_type_fail, /* (0x07) */
- xcoff_reloc_type_ba, /* R_BA (0x08) */
- xcoff_reloc_type_fail, /* (0x09) */
- xcoff_reloc_type_br, /* R_BR (0x0a) */
- xcoff_reloc_type_fail, /* (0x0b) */
- xcoff_reloc_type_pos, /* R_RL (0x0c) */
- xcoff_reloc_type_pos, /* R_RLA (0x0d) */
- xcoff_reloc_type_fail, /* (0x0e) */
+ xcoff_reloc_type_toc, /* R_GL (0x05) */
+ xcoff_reloc_type_toc, /* R_TCL (0x06) */
+ xcoff_reloc_type_fail, /* (0x07) */
+ xcoff_reloc_type_ba, /* R_BA (0x08) */
+ xcoff_reloc_type_fail, /* (0x09) */
+ xcoff_reloc_type_br, /* R_BR (0x0a) */
+ xcoff_reloc_type_fail, /* (0x0b) */
+ xcoff_reloc_type_pos, /* R_RL (0x0c) */
+ xcoff_reloc_type_pos, /* R_RLA (0x0d) */
+ xcoff_reloc_type_fail, /* (0x0e) */
xcoff_reloc_type_noop, /* R_REF (0x0f) */
- xcoff_reloc_type_fail, /* (0x10) */
- xcoff_reloc_type_fail, /* (0x11) */
- xcoff_reloc_type_toc, /* R_TRL (0x12) */
- xcoff_reloc_type_toc, /* R_TRLA (0x13) */
+ xcoff_reloc_type_fail, /* (0x10) */
+ xcoff_reloc_type_fail, /* (0x11) */
+ xcoff_reloc_type_toc, /* R_TRL (0x12) */
+ xcoff_reloc_type_toc, /* R_TRLA (0x13) */
xcoff_reloc_type_fail, /* R_RRTBI (0x14) */
xcoff_reloc_type_fail, /* R_RRTBA (0x15) */
- xcoff_reloc_type_ba, /* R_CAI (0x16) */
+ xcoff_reloc_type_ba, /* R_CAI (0x16) */
xcoff_reloc_type_crel, /* R_CREL (0x17) */
- xcoff_reloc_type_ba, /* R_RBA (0x18) */
- xcoff_reloc_type_ba, /* R_RBAC (0x19) */
- xcoff_reloc_type_br, /* R_RBR (0x1a) */
- xcoff_reloc_type_ba, /* R_RBRC (0x1b) */
+ xcoff_reloc_type_ba, /* R_RBA (0x18) */
+ xcoff_reloc_type_ba, /* R_RBAC (0x19) */
+ xcoff_reloc_type_br, /* R_RBR (0x1a) */
+ xcoff_reloc_type_ba, /* R_RBRC (0x1b) */
};
-boolean (*xcoff_complain_overflow[XCOFF_MAX_COMPLAIN_OVERFLOW])
+bfd_boolean (*xcoff_complain_overflow[XCOFF_MAX_COMPLAIN_OVERFLOW])
PARAMS ((XCOFF_COMPLAIN_FUNCTION_ARGS)) =
{
xcoff_complain_overflow_dont_func,
@@ -211,7 +240,7 @@ boolean (*xcoff_complain_overflow[XCOFF_MAX_COMPLAIN_OVERFLOW])
/* We use our own tdata type. Its first field is the COFF tdata type,
so the COFF routines are compatible. */
-boolean
+bfd_boolean
_bfd_xcoff_mkobject (abfd)
bfd *abfd;
{
@@ -220,7 +249,7 @@ _bfd_xcoff_mkobject (abfd)
abfd->tdata.xcoff_obj_data = (struct xcoff_tdata *) bfd_zalloc (abfd, amt);
if (abfd->tdata.xcoff_obj_data == NULL)
- return false;
+ return FALSE;
coff = coff_data (abfd);
coff->symbols = (coff_symbol_type *) NULL;
coff->conversion_table = (unsigned int *) NULL;
@@ -239,12 +268,12 @@ _bfd_xcoff_mkobject (abfd)
/* text section alignment is different than the default */
bfd_xcoff_text_align_power (abfd) = 2;
- return true;
+ return TRUE;
}
/* Copy XCOFF data from one BFD to another. */
-boolean
+bfd_boolean
_bfd_xcoff_copy_private_bfd_data (ibfd, obfd)
bfd *ibfd;
bfd *obfd;
@@ -253,7 +282,7 @@ _bfd_xcoff_copy_private_bfd_data (ibfd, obfd)
asection *sec;
if (ibfd->xvec != obfd->xvec)
- return true;
+ return TRUE;
ix = xcoff_data (ibfd);
ox = xcoff_data (obfd);
ox->full_aouthdr = ix->full_aouthdr;
@@ -284,7 +313,7 @@ _bfd_xcoff_copy_private_bfd_data (ibfd, obfd)
ox->cputype = ix->cputype;
ox->maxdata = ix->maxdata;
ox->maxstack = ix->maxstack;
- return true;
+ return TRUE;
}
/* I don't think XCOFF really has a notion of local labels based on
@@ -292,17 +321,17 @@ _bfd_xcoff_copy_private_bfd_data (ibfd, obfd)
The AIX native linker does not have a -X option, and it ignores the
-x option. */
-boolean
+bfd_boolean
_bfd_xcoff_is_local_label_name (abfd, name)
bfd *abfd ATTRIBUTE_UNUSED;
const char *name ATTRIBUTE_UNUSED;
{
- return false;
+ return FALSE;
}
void
_bfd_xcoff_swap_sym_in (abfd, ext1, in1)
- bfd *abfd;
+ bfd *abfd;
PTR ext1;
PTR in1;
{
@@ -311,7 +340,7 @@ _bfd_xcoff_swap_sym_in (abfd, ext1, in1)
if (ext->e.e_name[0] != 0)
{
- memcpy(in->_n._n_name, ext->e.e_name, SYMNMLEN);
+ memcpy (in->_n._n_name, ext->e.e_name, SYMNMLEN);
}
else
{
@@ -328,16 +357,16 @@ _bfd_xcoff_swap_sym_in (abfd, ext1, in1)
unsigned int
_bfd_xcoff_swap_sym_out (abfd, inp, extp)
- bfd *abfd;
- PTR inp;
- PTR extp;
+ bfd *abfd;
+ PTR inp;
+ PTR extp;
{
struct internal_syment *in = (struct internal_syment *)inp;
SYMENT *ext =(SYMENT *)extp;
if (in->_n._n_name[0] != 0)
{
- memcpy(ext->e.e_name, in->_n._n_name, SYMNMLEN);
+ memcpy (ext->e.e_name, in->_n._n_name, SYMNMLEN);
}
else
{
@@ -355,13 +384,13 @@ _bfd_xcoff_swap_sym_out (abfd, inp, extp)
void
_bfd_xcoff_swap_aux_in (abfd, ext1, type, class, indx, numaux, in1)
- bfd *abfd;
- PTR ext1;
- int type;
- int class;
- int indx;
- int numaux;
- PTR in1;
+ bfd *abfd;
+ PTR ext1;
+ int type;
+ int class;
+ int indx;
+ int numaux;
+ PTR in1;
{
AUXENT * ext = (AUXENT *)ext1;
union internal_auxent *in = (union internal_auxent *)in1;
@@ -418,7 +447,7 @@ _bfd_xcoff_swap_aux_in (abfd, ext1, type, class, indx, numaux, in1)
in->x_scn.x_nreloc = H_GET_16 (abfd, ext->x_scn.x_nreloc);
in->x_scn.x_nlinno = H_GET_16 (abfd, ext->x_scn.x_nlinno);
/* PE defines some extra fields; we zero them out for
- safety. */
+ safety. */
in->x_scn.x_checksum = 0;
in->x_scn.x_associated = 0;
in->x_scn.x_comdat = 0;
@@ -468,7 +497,8 @@ _bfd_xcoff_swap_aux_in (abfd, ext1, type, class, indx, numaux, in1)
}
-unsigned int _bfd_xcoff_swap_aux_out PARAMS ((bfd *, PTR, int, int, int, int, PTR));
+unsigned int _bfd_xcoff_swap_aux_out
+ PARAMS ((bfd *, PTR, int, int, int, int, PTR));
unsigned int
_bfd_xcoff_swap_aux_out (abfd, inp, type, class, indx, numaux, extp)
@@ -483,7 +513,7 @@ _bfd_xcoff_swap_aux_out (abfd, inp, type, class, indx, numaux, extp)
union internal_auxent *in = (union internal_auxent *)inp;
AUXENT *ext = (AUXENT *)extp;
- memset((PTR)ext, 0, bfd_coff_auxesz (abfd));
+ memset ((PTR)ext, 0, bfd_coff_auxesz (abfd));
switch (class)
{
case C_FILE:
@@ -578,390 +608,390 @@ end:
reloc_howto_type xcoff_howto_table[] =
{
/* Standard 32 bit relocation. */
- HOWTO (R_POS, /* type */
- 0, /* rightshift */
- 2, /* size (0 = byte, 1 = short, 2 = long) */
- 32, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ HOWTO (R_POS, /* type */
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_POS", /* name */
- true, /* partial_inplace */
- 0xffffffff, /* src_mask */
- 0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_POS", /* name */
+ TRUE, /* partial_inplace */
+ 0xffffffff, /* src_mask */
+ 0xffffffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
/* 32 bit relocation, but store negative value. */
- HOWTO (R_NEG, /* type */
- 0, /* rightshift */
- -2, /* size (0 = byte, 1 = short, 2 = long) */
- 32, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ HOWTO (R_NEG, /* type */
+ 0, /* rightshift */
+ -2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_NEG", /* name */
- true, /* partial_inplace */
- 0xffffffff, /* src_mask */
- 0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_NEG", /* name */
+ TRUE, /* partial_inplace */
+ 0xffffffff, /* src_mask */
+ 0xffffffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
/* 32 bit PC relative relocation. */
- HOWTO (R_REL, /* type */
- 0, /* rightshift */
- 2, /* size (0 = byte, 1 = short, 2 = long) */
- 32, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
+ HOWTO (R_REL, /* type */
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ TRUE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
- 0, /* special_function */
- "R_REL", /* name */
- true, /* partial_inplace */
- 0xffffffff, /* src_mask */
- 0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_REL", /* name */
+ TRUE, /* partial_inplace */
+ 0xffffffff, /* src_mask */
+ 0xffffffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
/* 16 bit TOC relative relocation. */
- HOWTO (R_TOC, /* type */
- 0, /* rightshift */
- 1, /* size (0 = byte, 1 = short, 2 = long) */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ HOWTO (R_TOC, /* type */
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_TOC", /* name */
- true, /* partial_inplace */
- 0xffff, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_TOC", /* name */
+ TRUE, /* partial_inplace */
+ 0xffff, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
/* I don't really know what this is. */
- HOWTO (R_RTB, /* type */
- 1, /* rightshift */
- 2, /* size (0 = byte, 1 = short, 2 = long) */
- 32, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ HOWTO (R_RTB, /* type */
+ 1, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_RTB", /* name */
- true, /* partial_inplace */
- 0xffffffff, /* src_mask */
- 0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_RTB", /* name */
+ TRUE, /* partial_inplace */
+ 0xffffffff, /* src_mask */
+ 0xffffffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
/* External TOC relative symbol. */
- HOWTO (R_GL, /* type */
- 0, /* rightshift */
+ HOWTO (R_GL, /* type */
+ 0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_GL", /* name */
- true, /* partial_inplace */
- 0xffff, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
-
- /* Local TOC relative symbol. */
- HOWTO (R_TCL, /* type */
- 0, /* rightshift */
+ 0, /* special_function */
+ "R_GL", /* name */
+ TRUE, /* partial_inplace */
+ 0xffff, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Local TOC relative symbol. */
+ HOWTO (R_TCL, /* type */
+ 0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_TCL", /* name */
- true, /* partial_inplace */
- 0xffff, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_TCL", /* name */
+ TRUE, /* partial_inplace */
+ 0xffff, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
EMPTY_HOWTO (7),
/* Non modifiable absolute branch. */
- HOWTO (R_BA, /* type */
- 0, /* rightshift */
- 2, /* size (0 = byte, 1 = short, 2 = long) */
- 26, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ HOWTO (R_BA, /* type */
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 26, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_BA_26", /* name */
- true, /* partial_inplace */
+ 0, /* special_function */
+ "R_BA_26", /* name */
+ TRUE, /* partial_inplace */
0x03fffffc, /* src_mask */
0x03fffffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
EMPTY_HOWTO (9),
/* Non modifiable relative branch. */
- HOWTO (R_BR, /* type */
- 0, /* rightshift */
- 2, /* size (0 = byte, 1 = short, 2 = long) */
- 26, /* bitsize */
- true, /* pc_relative */
- 0, /* bitpos */
+ HOWTO (R_BR, /* type */
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 26, /* bitsize */
+ TRUE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
- 0, /* special_function */
- "R_BR", /* name */
- true, /* partial_inplace */
- 0x3fffffc, /* src_mask */
- 0x3fffffc, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_BR", /* name */
+ TRUE, /* partial_inplace */
+ 0x03fffffc, /* src_mask */
+ 0x03fffffc, /* dst_mask */
+ FALSE), /* pcrel_offset */
EMPTY_HOWTO (0xb),
/* Indirect load. */
- HOWTO (R_RL, /* type */
- 0, /* rightshift */
+ HOWTO (R_RL, /* type */
+ 0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_RL", /* name */
- true, /* partial_inplace */
- 0xffff, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_RL", /* name */
+ TRUE, /* partial_inplace */
+ 0xffff, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
/* Load address. */
- HOWTO (R_RLA, /* type */
- 0, /* rightshift */
+ HOWTO (R_RLA, /* type */
+ 0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_RLA", /* name */
- true, /* partial_inplace */
- 0xffff, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_RLA", /* name */
+ TRUE, /* partial_inplace */
+ 0xffff, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
EMPTY_HOWTO (0xe),
/* Non-relocating reference. */
- HOWTO (R_REF, /* type */
- 0, /* rightshift */
- 2, /* size (0 = byte, 1 = short, 2 = long) */
- 32, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ HOWTO (R_REF, /* type */
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
- 0, /* special_function */
- "R_REF", /* name */
- false, /* partial_inplace */
- 0, /* src_mask */
- 0, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_REF", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0, /* dst_mask */
+ FALSE), /* pcrel_offset */
EMPTY_HOWTO (0x10),
EMPTY_HOWTO (0x11),
/* TOC relative indirect load. */
- HOWTO (R_TRL, /* type */
- 0, /* rightshift */
+ HOWTO (R_TRL, /* type */
+ 0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_TRL", /* name */
- true, /* partial_inplace */
- 0xffff, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_TRL", /* name */
+ TRUE, /* partial_inplace */
+ 0xffff, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
/* TOC relative load address. */
- HOWTO (R_TRLA, /* type */
- 0, /* rightshift */
+ HOWTO (R_TRLA, /* type */
+ 0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_TRLA", /* name */
- true, /* partial_inplace */
- 0xffff, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_TRLA", /* name */
+ TRUE, /* partial_inplace */
+ 0xffff, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
/* Modifiable relative branch. */
- HOWTO (R_RRTBI, /* type */
- 1, /* rightshift */
- 2, /* size (0 = byte, 1 = short, 2 = long) */
- 32, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ HOWTO (R_RRTBI, /* type */
+ 1, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_RRTBI", /* name */
- true, /* partial_inplace */
- 0xffffffff, /* src_mask */
- 0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_RRTBI", /* name */
+ TRUE, /* partial_inplace */
+ 0xffffffff, /* src_mask */
+ 0xffffffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
/* Modifiable absolute branch. */
- HOWTO (R_RRTBA, /* type */
- 1, /* rightshift */
- 2, /* size (0 = byte, 1 = short, 2 = long) */
- 32, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ HOWTO (R_RRTBA, /* type */
+ 1, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_RRTBA", /* name */
- true, /* partial_inplace */
- 0xffffffff, /* src_mask */
- 0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_RRTBA", /* name */
+ TRUE, /* partial_inplace */
+ 0xffffffff, /* src_mask */
+ 0xffffffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
/* Modifiable call absolute indirect. */
- HOWTO (R_CAI, /* type */
- 0, /* rightshift */
+ HOWTO (R_CAI, /* type */
+ 0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_CAI", /* name */
- true, /* partial_inplace */
- 0xffff, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_CAI", /* name */
+ TRUE, /* partial_inplace */
+ 0xffff, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
/* Modifiable call relative. */
- HOWTO (R_CREL, /* type */
- 0, /* rightshift */
+ HOWTO (R_CREL, /* type */
+ 0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_CREL", /* name */
- true, /* partial_inplace */
- 0xffff, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_CREL", /* name */
+ TRUE, /* partial_inplace */
+ 0xffff, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
/* Modifiable branch absolute. */
- HOWTO (R_RBA, /* type */
- 0, /* rightshift */
- 2, /* size (0 = byte, 1 = short, 2 = long) */
- 26, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ HOWTO (R_RBA, /* type */
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 26, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_RBA", /* name */
- true, /* partial_inplace */
+ 0, /* special_function */
+ "R_RBA", /* name */
+ TRUE, /* partial_inplace */
0x03fffffc, /* src_mask */
0x03fffffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Modifiable branch absolute. */
- HOWTO (R_RBAC, /* type */
- 0, /* rightshift */
- 2, /* size (0 = byte, 1 = short, 2 = long) */
- 32, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ HOWTO (R_RBAC, /* type */
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_RBAC", /* name */
- true, /* partial_inplace */
+ 0, /* special_function */
+ "R_RBAC", /* name */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Modifiable branch relative. */
- HOWTO (R_RBR, /* type */
- 0, /* rightshift */
- 2, /* size (0 = byte, 1 = short, 2 = long) */
- 26, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ HOWTO (R_RBR, /* type */
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 26, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
- 0, /* special_function */
- "R_RBR_26", /* name */
- true, /* partial_inplace */
+ 0, /* special_function */
+ "R_RBR_26", /* name */
+ TRUE, /* partial_inplace */
0x03fffffc, /* src_mask */
0x03fffffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Modifiable branch absolute. */
- HOWTO (R_RBRC, /* type */
- 0, /* rightshift */
+ HOWTO (R_RBRC, /* type */
+ 0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_RBRC", /* name */
- true, /* partial_inplace */
- 0xffff, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_RBRC", /* name */
+ TRUE, /* partial_inplace */
+ 0xffff, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
/* 16 bit Non modifiable absolute branch. */
- HOWTO (R_BA, /* type */
- 0, /* rightshift */
- 1, /* size (0 = byte, 1 = short, 2 = long) */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ HOWTO (R_BA, /* type */
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_BA_16", /* name */
- true, /* partial_inplace */
- 0xfffc, /* src_mask */
- 0xfffc, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_BA_16", /* name */
+ TRUE, /* partial_inplace */
+ 0xfffc, /* src_mask */
+ 0xfffc, /* dst_mask */
+ FALSE), /* pcrel_offset */
/* Modifiable branch relative. */
- HOWTO (R_RBR, /* type */
- 0, /* rightshift */
- 1, /* size (0 = byte, 1 = short, 2 = long) */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ HOWTO (R_RBR, /* type */
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
- 0, /* special_function */
- "R_RBR_16", /* name */
- true, /* partial_inplace */
- 0xffff, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_RBR_16", /* name */
+ TRUE, /* partial_inplace */
+ 0xffff, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
/* Modifiable branch relative. */
- HOWTO (R_RBA, /* type */
- 0, /* rightshift */
- 1, /* size (0 = byte, 1 = short, 2 = long) */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ HOWTO (R_RBA, /* type */
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
- 0, /* special_function */
- "R_RBA_16", /* name */
- true, /* partial_inplace */
- 0xffff, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_RBA_16", /* name */
+ TRUE, /* partial_inplace */
+ 0xffff, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
};
@@ -975,18 +1005,18 @@ xcoff_rtype2howto (relent, internal)
/* Default howto layout works most of the time */
relent->howto = &xcoff_howto_table[internal->r_type];
-
- /* Special case some 16 bit reoloc */
+
+ /* Special case some 16 bit reloc */
if (15 == (internal->r_size & 0x1f))
{
- if (R_BA == internal->r_type)
+ if (R_BA == internal->r_type)
relent->howto = &xcoff_howto_table[0x1c];
- else if (R_RBR == internal->r_type)
+ else if (R_RBR == internal->r_type)
relent->howto = &xcoff_howto_table[0x1d];
- else if (R_RBA == internal->r_type)
+ else if (R_RBA == internal->r_type)
relent->howto = &xcoff_howto_table[0x1e];
}
-
+
/* The r_size field of an XCOFF reloc encodes the bitsize of the
relocation, as well as indicating whether it is signed or not.
Doublecheck that the relocation information gathered from the
@@ -1069,19 +1099,19 @@ _bfd_xcoff_reloc_type_lookup (abfd, code)
/* Set the magic for archive. */
-boolean
+bfd_boolean
bfd_xcoff_ar_archive_set_magic (abfd, magic)
bfd *abfd ATTRIBUTE_UNUSED;
char *magic ATTRIBUTE_UNUSED;
{
/* Not supported yet. */
- return false;
+ return FALSE;
/* bfd_xcoff_archive_set_magic (abfd, magic); */
}
/* Read in the armap of an XCOFF archive. */
-boolean
+bfd_boolean
_bfd_xcoff_slurp_armap (abfd)
bfd *abfd;
{
@@ -1095,8 +1125,8 @@ _bfd_xcoff_slurp_armap (abfd)
if (xcoff_ardata (abfd) == NULL)
{
- bfd_has_map (abfd) = false;
- return true;
+ bfd_has_map (abfd) = FALSE;
+ return TRUE;
}
if (! xcoff_big_format_p (abfd))
@@ -1107,32 +1137,32 @@ _bfd_xcoff_slurp_armap (abfd)
off = strtol (xcoff_ardata (abfd)->symoff, (char **) NULL, 10);
if (off == 0)
{
- bfd_has_map (abfd) = false;
- return true;
+ bfd_has_map (abfd) = FALSE;
+ return TRUE;
}
if (bfd_seek (abfd, off, SEEK_SET) != 0)
- return false;
+ return FALSE;
/* The symbol table starts with a normal archive header. */
if (bfd_bread ((PTR) &hdr, (bfd_size_type) SIZEOF_AR_HDR, abfd)
!= SIZEOF_AR_HDR)
- return false;
+ return FALSE;
/* Skip the name (normally empty). */
namlen = strtol (hdr.namlen, (char **) NULL, 10);
off = ((namlen + 1) & ~ (size_t) 1) + SXCOFFARFMAG;
if (bfd_seek (abfd, off, SEEK_CUR) != 0)
- return false;
+ return FALSE;
sz = strtol (hdr.size, (char **) NULL, 10);
/* Read in the entire symbol table. */
contents = (bfd_byte *) bfd_alloc (abfd, sz);
if (contents == NULL)
- return false;
+ return FALSE;
if (bfd_bread ((PTR) contents, sz, abfd) != sz)
- return false;
+ return FALSE;
/* The symbol table starts with a four byte count. */
c = H_GET_32 (abfd, contents);
@@ -1140,13 +1170,13 @@ _bfd_xcoff_slurp_armap (abfd)
if (c * 4 >= sz)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
bfd_ardata (abfd)->symdefs =
((carsym *) bfd_alloc (abfd, c * sizeof (carsym)));
if (bfd_ardata (abfd)->symdefs == NULL)
- return false;
+ return FALSE;
/* After the count comes a list of four byte file offsets. */
for (i = 0, arsym = bfd_ardata (abfd)->symdefs, p = contents + 4;
@@ -1162,23 +1192,23 @@ _bfd_xcoff_slurp_armap (abfd)
off = strtol (xcoff_ardata_big (abfd)->symoff, (char **) NULL, 10);
if (off == 0)
{
- bfd_has_map (abfd) = false;
- return true;
+ bfd_has_map (abfd) = FALSE;
+ return TRUE;
}
if (bfd_seek (abfd, off, SEEK_SET) != 0)
- return false;
+ return FALSE;
/* The symbol table starts with a normal archive header. */
if (bfd_bread ((PTR) &hdr, (bfd_size_type) SIZEOF_AR_HDR_BIG, abfd)
!= SIZEOF_AR_HDR_BIG)
- return false;
+ return FALSE;
/* Skip the name (normally empty). */
namlen = strtol (hdr.namlen, (char **) NULL, 10);
off = ((namlen + 1) & ~ (size_t) 1) + SXCOFFARFMAG;
if (bfd_seek (abfd, off, SEEK_CUR) != 0)
- return false;
+ return FALSE;
/* XXX This actually has to be a call to strtoll (at least on 32-bit
machines) since the field width is 20 and there numbers with more
@@ -1188,9 +1218,9 @@ _bfd_xcoff_slurp_armap (abfd)
/* Read in the entire symbol table. */
contents = (bfd_byte *) bfd_alloc (abfd, sz);
if (contents == NULL)
- return false;
+ return FALSE;
if (bfd_bread ((PTR) contents, sz, abfd) != sz)
- return false;
+ return FALSE;
/* The symbol table starts with an eight byte count. */
c = H_GET_64 (abfd, contents);
@@ -1198,13 +1228,13 @@ _bfd_xcoff_slurp_armap (abfd)
if (c * 8 >= sz)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
bfd_ardata (abfd)->symdefs =
((carsym *) bfd_alloc (abfd, c * sizeof (carsym)));
if (bfd_ardata (abfd)->symdefs == NULL)
- return false;
+ return FALSE;
/* After the count comes a list of eight byte file offsets. */
for (i = 0, arsym = bfd_ardata (abfd)->symdefs, p = contents + 8;
@@ -1222,15 +1252,15 @@ _bfd_xcoff_slurp_armap (abfd)
if (p >= cend)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
arsym->name = (char *) p;
}
bfd_ardata (abfd)->symdef_count = c;
- bfd_has_map (abfd) = true;
+ bfd_has_map (abfd) = TRUE;
- return true;
+ return TRUE;
}
/* See if this is an XCOFF archive. */
@@ -1545,8 +1575,7 @@ normalize_filename (abfd)
/* Write out an XCOFF armap. */
-/*ARGSUSED*/
-static boolean
+static bfd_boolean
xcoff_write_armap_old (abfd, elength, map, orl_count, stridx)
bfd *abfd;
unsigned int elength ATTRIBUTE_UNUSED;
@@ -1580,11 +1609,11 @@ xcoff_write_armap_old (abfd, elength, map, orl_count, stridx)
!= SIZEOF_AR_HDR
|| (bfd_bwrite (XCOFFARFMAG, (bfd_size_type) SXCOFFARFMAG, abfd)
!= SXCOFFARFMAG))
- return false;
+ return FALSE;
H_PUT_32 (abfd, orl_count, buf);
if (bfd_bwrite (buf, (bfd_size_type) 4, abfd) != 4)
- return false;
+ return FALSE;
sub = abfd->archive_head;
fileoff = SIZEOF_AR_FILE_HDR;
@@ -1597,7 +1626,7 @@ xcoff_write_armap_old (abfd, elength, map, orl_count, stridx)
{
H_PUT_32 (abfd, fileoff, buf);
if (bfd_bwrite (buf, (bfd_size_type) 4, abfd) != 4)
- return false;
+ return FALSE;
++i;
}
namlen = strlen (normalize_filename (sub));
@@ -1618,7 +1647,7 @@ xcoff_write_armap_old (abfd, elength, map, orl_count, stridx)
name = *map[i].name;
namlen = strlen (name);
if (bfd_bwrite (name, (bfd_size_type) (namlen + 1), abfd) != namlen + 1)
- return false;
+ return FALSE;
}
if ((stridx & 1) != 0)
@@ -1627,10 +1656,10 @@ xcoff_write_armap_old (abfd, elength, map, orl_count, stridx)
b = '\0';
if (bfd_bwrite (&b, (bfd_size_type) 1, abfd) != 1)
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
static char buff20[XCOFFARMAGBIG_ELEMENT_SIZE + 1];
@@ -1644,7 +1673,7 @@ static char buff20[XCOFFARMAGBIG_ELEMENT_SIZE + 1];
#define PRINT12(d, v) \
sprintf (buff20, FMT12, (int)(v)), \
- memcpy ((void *) (d), buff20, 12)
+ memcpy ((void *) (d), buff20, 12)
#define PRINT12_OCTAL(d, v) \
sprintf (buff20, FMT12_OCTAL, (unsigned int)(v)), \
@@ -1652,14 +1681,14 @@ static char buff20[XCOFFARMAGBIG_ELEMENT_SIZE + 1];
#define PRINT4(d, v) \
sprintf (buff20, FMT4, (int)(v)), \
- memcpy ((void *) (d), buff20, 4)
+ memcpy ((void *) (d), buff20, 4)
#define READ20(d, v) \
buff20[20] = 0, \
memcpy (buff20, (d), 20), \
(v) = bfd_scan_vma (buff20, (const char **) NULL, 10)
-static boolean
+static bfd_boolean
do_pad (abfd, number)
bfd *abfd;
unsigned int number;
@@ -1668,16 +1697,16 @@ do_pad (abfd, number)
/* Limit pad to <= 4096. */
if (number > 4096)
- return false;
+ return FALSE;
while (number--)
if (bfd_bwrite (&b, (bfd_size_type) 1, abfd) != 1)
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
do_copy (out_bfd, in_bfd)
bfd *out_bfd;
bfd *in_bfd;
@@ -1686,7 +1715,7 @@ do_copy (out_bfd, in_bfd)
bfd_byte buffer[DEFAULT_BUFFERSIZE];
if (bfd_seek (in_bfd, (file_ptr) 0, SEEK_SET) != 0)
- return false;
+ return FALSE;
remaining = arelt_size (in_bfd);
@@ -1694,22 +1723,22 @@ do_copy (out_bfd, in_bfd)
{
if (bfd_bread (buffer, DEFAULT_BUFFERSIZE, in_bfd) != DEFAULT_BUFFERSIZE
|| bfd_bwrite (buffer, DEFAULT_BUFFERSIZE, out_bfd) != DEFAULT_BUFFERSIZE)
- return false;
+ return FALSE;
remaining -= DEFAULT_BUFFERSIZE;
}
if (remaining)
{
- if (bfd_bread (buffer, remaining, in_bfd) != remaining
+ if (bfd_bread (buffer, remaining, in_bfd) != remaining
|| bfd_bwrite (buffer, remaining, out_bfd) != remaining)
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
do_shared_object_padding (out_bfd, in_bfd, offset, ar_header_size)
bfd *out_bfd;
bfd *in_bfd;
@@ -1729,15 +1758,15 @@ do_shared_object_padding (out_bfd, in_bfd, offset, ar_header_size)
pad -= (*offset + ar_header_size) & (pad - 1);
if (! do_pad (out_bfd, pad))
- return false;
+ return FALSE;
*offset += pad;
}
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
xcoff_write_armap_big (abfd, elength, map, orl_count, stridx)
bfd *abfd;
unsigned int elength ATTRIBUTE_UNUSED;
@@ -1751,7 +1780,7 @@ xcoff_write_armap_big (abfd, elength, map, orl_count, stridx)
bfd *current_bfd;
size_t string_length;
ufile_ptr nextoff, prevoff;
-
+
/* First, we look through the symbols and work out which are
from 32-bit objects and which from 64-bit ones. */
sym_32 = sym_64 = str_32 = str_64 = 0;
@@ -1796,50 +1825,50 @@ xcoff_write_armap_big (abfd, elength, map, orl_count, stridx)
BFD_ASSERT (nextoff == bfd_tell (abfd));
- /* Write out the symbol table.
- Layout :
-
+ /* Write out the symbol table.
+ Layout :
+
standard big archive header
- 0x0000 ar_size [0x14]
- 0x0014 ar_nxtmem [0x14]
- 0x0028 ar_prvmem [0x14]
- 0x003C ar_date [0x0C]
- 0x0048 ar_uid [0x0C]
- 0x0054 ar_gid [0x0C]
- 0x0060 ar_mod [0x0C]
- 0x006C ar_namelen[0x04]
- 0x0070 ar_fmag [SXCOFFARFMAG]
-
- Symbol table
- 0x0072 num_syms [0x08], binary
- 0x0078 offsets [0x08 * num_syms], binary
- 0x0086 + 0x08 * num_syms names [??]
- ?? pad to even bytes.
+ 0x0000 ar_size [0x14]
+ 0x0014 ar_nxtmem [0x14]
+ 0x0028 ar_prvmem [0x14]
+ 0x003C ar_date [0x0C]
+ 0x0048 ar_uid [0x0C]
+ 0x0054 ar_gid [0x0C]
+ 0x0060 ar_mod [0x0C]
+ 0x006C ar_namelen[0x04]
+ 0x0070 ar_fmag [SXCOFFARFMAG]
+
+ Symbol table
+ 0x0072 num_syms [0x08], binary
+ 0x0078 offsets [0x08 * num_syms], binary
+ 0x0086 + 0x08 * num_syms names [??]
+ ?? pad to even bytes.
*/
- if (sym_32)
+ if (sym_32)
{
struct xcoff_ar_hdr_big *hdr;
bfd_byte *symbol_table;
bfd_byte *st;
file_ptr fileoff;
- bfd_vma symbol_table_size =
+ bfd_vma symbol_table_size =
SIZEOF_AR_HDR_BIG
+ SXCOFFARFMAG
- + 8
- + 8 * sym_32
+ + 8
+ + 8 * sym_32
+ str_32 + (str_32 & 1);
symbol_table = NULL;
symbol_table = (bfd_byte *) bfd_zmalloc (symbol_table_size);
if (symbol_table == NULL)
- return false;
+ return FALSE;
hdr = (struct xcoff_ar_hdr_big *) symbol_table;
-
+
PRINT20 (hdr->size, 8 + 8 * sym_32 + str_32 + (str_32 & 1));
-
+
if (sym_64)
PRINT20 (hdr->nextoff, nextoff + symbol_table_size);
else
@@ -1858,7 +1887,7 @@ xcoff_write_armap_big (abfd, elength, map, orl_count, stridx)
bfd_h_put_64 (abfd, sym_32, st);
st += 8;
-
+
/* loop over the 32 bit offsets */
current_bfd = abfd->archive_head;
if (current_bfd != NULL)
@@ -1917,27 +1946,27 @@ xcoff_write_armap_big (abfd, elength, map, orl_count, stridx)
prevoff = nextoff;
nextoff = nextoff + symbol_table_size;
}
- else
+ else
PRINT20 (fhdr->symoff, 0);
-
- if (sym_64)
+
+ if (sym_64)
{
struct xcoff_ar_hdr_big *hdr;
bfd_byte *symbol_table;
bfd_byte *st;
file_ptr fileoff;
- bfd_vma symbol_table_size =
+ bfd_vma symbol_table_size =
SIZEOF_AR_HDR_BIG
+ SXCOFFARFMAG
- + 8
- + 8 * sym_64
+ + 8
+ + 8 * sym_64
+ str_64 + (str_64 & 1);
symbol_table = NULL;
symbol_table = (bfd_byte *) bfd_zmalloc (symbol_table_size);
if (symbol_table == NULL)
- return false;
+ return FALSE;
hdr = (struct xcoff_ar_hdr_big *) symbol_table;
@@ -1956,7 +1985,7 @@ xcoff_write_armap_big (abfd, elength, map, orl_count, stridx)
bfd_h_put_64 (abfd, sym_64, st);
st += 8;
-
+
/* loop over the 64 bit offsets */
current_bfd = abfd->archive_head;
if (current_bfd != NULL)
@@ -2014,13 +2043,13 @@ xcoff_write_armap_big (abfd, elength, map, orl_count, stridx)
PRINT20 (fhdr->symoff64, nextoff);
}
- else
+ else
PRINT20 (fhdr->symoff64, 0);
-
- return true;
+
+ return TRUE;
}
-boolean
+bfd_boolean
_bfd_xcoff_write_armap (abfd, elength, map, orl_count, stridx)
bfd *abfd;
unsigned int elength ATTRIBUTE_UNUSED;
@@ -2037,7 +2066,7 @@ _bfd_xcoff_write_armap (abfd, elength, map, orl_count, stridx)
/* Write out an XCOFF archive. We always write an entire archive,
rather than fussing with the freelist and so forth. */
-static boolean
+static bfd_boolean
xcoff_write_archive_contents_old (abfd)
bfd *abfd;
{
@@ -2045,8 +2074,8 @@ xcoff_write_archive_contents_old (abfd)
bfd_size_type count;
bfd_size_type total_namlen;
file_ptr *offsets;
- boolean makemap;
- boolean hasobjects;
+ bfd_boolean makemap;
+ bfd_boolean hasobjects;
ufile_ptr prevoff, nextoff;
bfd *sub;
size_t i;
@@ -2069,13 +2098,13 @@ xcoff_write_archive_contents_old (abfd)
}
offsets = (file_ptr *) bfd_alloc (abfd, count * sizeof (file_ptr));
if (offsets == NULL)
- return false;
+ return FALSE;
if (bfd_seek (abfd, (file_ptr) SIZEOF_AR_FILE_HDR, SEEK_SET) != 0)
- return false;
+ return FALSE;
makemap = bfd_has_map (abfd);
- hasobjects = false;
+ hasobjects = FALSE;
prevoff = 0;
nextoff = SIZEOF_AR_FILE_HDR;
for (sub = abfd->archive_head, i = 0; sub != NULL; sub = sub->next, i++)
@@ -2088,7 +2117,7 @@ xcoff_write_archive_contents_old (abfd)
if (makemap && ! hasobjects)
{
if (bfd_check_format (sub, bfd_object))
- hasobjects = true;
+ hasobjects = TRUE;
}
name = normalize_filename (sub);
@@ -2108,7 +2137,7 @@ xcoff_write_archive_contents_old (abfd)
if (stat (bfd_get_filename (sub), &s) != 0)
{
bfd_set_error (bfd_error_system_call);
- return false;
+ return FALSE;
}
sprintf (ahdrp->size, "%ld", (long) s.st_size);
@@ -2122,7 +2151,7 @@ xcoff_write_archive_contents_old (abfd)
size = sizeof (struct areltdata);
sub->arelt_data = bfd_alloc (sub, size);
if (sub->arelt_data == NULL)
- return false;
+ return FALSE;
}
arch_eltdata (sub)->parsed_size = s.st_size;
@@ -2132,7 +2161,7 @@ xcoff_write_archive_contents_old (abfd)
sprintf (ahdrp->namlen, "%ld", (long) namlen);
/* If the length of the name is odd, we write out the null byte
- after the name as well. */
+ after the name as well. */
namlen = (namlen + 1) &~ (bfd_size_type) 1;
remaining = arelt_size (sub);
@@ -2157,19 +2186,19 @@ xcoff_write_archive_contents_old (abfd)
if ((bfd_bwrite ((PTR) ahdrp, (bfd_size_type) SIZEOF_AR_HDR, abfd)
!= SIZEOF_AR_HDR)
- || (bfd_bwrite ((PTR) name, namlen, abfd) != namlen)
- || (bfd_bwrite ((PTR) XCOFFARFMAG, (bfd_size_type) SXCOFFARFMAG, abfd)
- != SXCOFFARFMAG))
- return false;
+ || bfd_bwrite ((PTR) name, namlen, abfd) != namlen
+ || bfd_bwrite ((PTR) XCOFFARFMAG, (bfd_size_type) SXCOFFARFMAG,
+ abfd) != SXCOFFARFMAG)
+ return FALSE;
if (bfd_seek (sub, (file_ptr) 0, SEEK_SET) != 0)
- return false;
+ return FALSE;
if (! do_copy (abfd, sub))
- return false;
-
+ return FALSE;
+
if (! do_pad (abfd, size & 1))
- return false;
+ return FALSE;
}
sprintf (fhdr.lastmemoff, "%ld", (long) prevoff);
@@ -2213,18 +2242,18 @@ xcoff_write_archive_contents_old (abfd)
!= SIZEOF_AR_HDR)
|| (bfd_bwrite ((PTR) XCOFFARFMAG, (bfd_size_type) SXCOFFARFMAG, abfd)
!= SXCOFFARFMAG))
- return false;
+ return FALSE;
sprintf (decbuf, "%-12ld", (long) count);
if (bfd_bwrite ((PTR) decbuf, (bfd_size_type) XCOFFARMAG_ELEMENT_SIZE, abfd)
!= XCOFFARMAG_ELEMENT_SIZE)
- return false;
+ return FALSE;
for (i = 0; i < (size_t) count; i++)
{
sprintf (decbuf, "%-12ld", (long) offsets[i]);
- if (bfd_bwrite ((PTR) decbuf, (bfd_size_type) XCOFFARMAG_ELEMENT_SIZE,
+ if (bfd_bwrite ((PTR) decbuf, (bfd_size_type) XCOFFARMAG_ELEMENT_SIZE,
abfd) != XCOFFARMAG_ELEMENT_SIZE)
- return false;
+ return FALSE;
}
for (sub = abfd->archive_head; sub != NULL; sub = sub->next)
{
@@ -2234,11 +2263,11 @@ xcoff_write_archive_contents_old (abfd)
name = normalize_filename (sub);
namlen = strlen (name);
if (bfd_bwrite ((PTR) name, namlen + 1, abfd) != namlen + 1)
- return false;
+ return FALSE;
}
if (! do_pad (abfd, size & 1))
- return false;
+ return FALSE;
/* Write out the armap, if appropriate. */
if (! makemap || ! hasobjects)
@@ -2249,7 +2278,7 @@ xcoff_write_archive_contents_old (abfd)
sprintf (fhdr.symoff, "%ld", (long) nextoff);
bfd_ardata (abfd)->tdata = (PTR) &fhdr;
if (! _bfd_compute_and_write_armap (abfd, 0))
- return false;
+ return FALSE;
}
/* Write out the archive file header. */
@@ -2262,12 +2291,12 @@ xcoff_write_archive_contents_old (abfd)
if (bfd_seek (abfd, (file_ptr) 0, SEEK_SET) != 0
|| (bfd_bwrite ((PTR) &fhdr, (bfd_size_type) SIZEOF_AR_FILE_HDR, abfd)
!= SIZEOF_AR_FILE_HDR))
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
xcoff_write_archive_contents_big (abfd)
bfd *abfd;
{
@@ -2275,8 +2304,8 @@ xcoff_write_archive_contents_big (abfd)
bfd_size_type count;
bfd_size_type total_namlen;
file_ptr *offsets;
- boolean makemap;
- boolean hasobjects;
+ bfd_boolean makemap;
+ bfd_boolean hasobjects;
ufile_ptr prevoff, nextoff;
bfd *current_bfd;
size_t i;
@@ -2289,13 +2318,13 @@ xcoff_write_archive_contents_big (abfd)
memcpy (fhdr.magic, XCOFFARMAGBIG, SXCOFFARMAG);
if (bfd_seek (abfd, (file_ptr) SIZEOF_AR_FILE_HDR_BIG, SEEK_SET) != 0)
- return false;
-
+ return FALSE;
+
/* Calculate count and total_namlen. */
makemap = bfd_has_map (abfd);
- hasobjects = false;
- for (current_bfd = abfd->archive_head, count = 0, total_namlen = 0;
- current_bfd != NULL;
+ hasobjects = FALSE;
+ for (current_bfd = abfd->archive_head, count = 0, total_namlen = 0;
+ current_bfd != NULL;
current_bfd = current_bfd->next, count++)
{
total_namlen += strlen (normalize_filename (current_bfd)) + 1;
@@ -2303,7 +2332,7 @@ xcoff_write_archive_contents_big (abfd)
if (makemap
&& ! hasobjects
&& bfd_check_format (current_bfd, bfd_object))
- hasobjects = true;
+ hasobjects = TRUE;
}
offsets = NULL;
@@ -2311,13 +2340,13 @@ xcoff_write_archive_contents_big (abfd)
{
offsets = (file_ptr *) bfd_malloc (count * sizeof (file_ptr));
if (offsets == NULL)
- return false;
+ return FALSE;
}
prevoff = 0;
nextoff = SIZEOF_AR_FILE_HDR_BIG;
- for (current_bfd = abfd->archive_head, i = 0;
- current_bfd != NULL;
+ for (current_bfd = abfd->archive_head, i = 0;
+ current_bfd != NULL;
current_bfd = current_bfd->next, i++)
{
const char *name;
@@ -2339,12 +2368,12 @@ xcoff_write_archive_contents_big (abfd)
ahdrp = &ahdr;
/* XXX This should actually be a call to stat64 (at least on
- 32-bit machines).
+ 32-bit machines).
XXX This call will fail if the original object is not found. */
if (stat (bfd_get_filename (current_bfd), &s) != 0)
{
bfd_set_error (bfd_error_system_call);
- return false;
+ return FALSE;
}
PRINT20 (ahdrp->size, s.st_size);
@@ -2358,7 +2387,7 @@ xcoff_write_archive_contents_big (abfd)
size = sizeof (struct areltdata);
current_bfd->arelt_data = bfd_alloc (current_bfd, size);
if (current_bfd->arelt_data == NULL)
- return false;
+ return FALSE;
}
arch_eltdata (current_bfd)->parsed_size = s.st_size;
@@ -2368,7 +2397,7 @@ xcoff_write_archive_contents_big (abfd)
PRINT4 (ahdrp->namlen, namlen);
/* If the length of the name is odd, we write out the null byte
- after the name as well. */
+ after the name as well. */
namlen = (namlen + 1) &~ (bfd_size_type) 1;
remaining = arelt_size (current_bfd);
@@ -2383,9 +2412,9 @@ xcoff_write_archive_contents_big (abfd)
Their text section needs to be aligned wrt the archive file position.
This requires extra padding before the archive header. */
if (! do_shared_object_padding (abfd, current_bfd, & nextoff,
- SIZEOF_AR_HDR_BIG + namlen
+ SIZEOF_AR_HDR_BIG + namlen
+ SXCOFFARFMAG))
- return false;
+ return FALSE;
offsets[i] = nextoff;
@@ -2397,18 +2426,18 @@ xcoff_write_archive_contents_big (abfd)
if ((bfd_bwrite ((PTR) ahdrp, (bfd_size_type) SIZEOF_AR_HDR_BIG, abfd)
!= SIZEOF_AR_HDR_BIG)
|| bfd_bwrite ((PTR) name, (bfd_size_type) namlen, abfd) != namlen
- || (bfd_bwrite ((PTR) XCOFFARFMAG, (bfd_size_type) SXCOFFARFMAG,
+ || (bfd_bwrite ((PTR) XCOFFARFMAG, (bfd_size_type) SXCOFFARFMAG,
abfd) != SXCOFFARFMAG))
- return false;
+ return FALSE;
if (bfd_seek (current_bfd, (file_ptr) 0, SEEK_SET) != 0)
- return false;
+ return FALSE;
if (! do_copy (abfd, current_bfd))
- return false;
-
+ return FALSE;
+
if (! do_pad (abfd, size & 1))
- return false;
+ return FALSE;
}
if (count)
@@ -2417,25 +2446,25 @@ xcoff_write_archive_contents_big (abfd)
PRINT20 (fhdr.lastmemoff, prevoff);
}
- /* Write out the member table.
- Layout :
+ /* Write out the member table.
+ Layout :
standard big archive header
- 0x0000 ar_size [0x14]
- 0x0014 ar_nxtmem [0x14]
- 0x0028 ar_prvmem [0x14]
- 0x003C ar_date [0x0C]
- 0x0048 ar_uid [0x0C]
- 0x0054 ar_gid [0x0C]
- 0x0060 ar_mod [0x0C]
- 0x006C ar_namelen[0x04]
- 0x0070 ar_fmag [0x02]
-
- Member table
- 0x0072 count [0x14]
- 0x0086 offsets [0x14 * counts]
- 0x0086 + 0x14 * counts names [??]
- ?? pad to even bytes.
+ 0x0000 ar_size [0x14]
+ 0x0014 ar_nxtmem [0x14]
+ 0x0028 ar_prvmem [0x14]
+ 0x003C ar_date [0x0C]
+ 0x0048 ar_uid [0x0C]
+ 0x0054 ar_gid [0x0C]
+ 0x0060 ar_mod [0x0C]
+ 0x006C ar_namelen[0x04]
+ 0x0070 ar_fmag [0x02]
+
+ Member table
+ 0x0072 count [0x14]
+ 0x0086 offsets [0x14 * counts]
+ 0x0086 + 0x14 * counts names [??]
+ ?? pad to even bytes.
*/
BFD_ASSERT (nextoff == bfd_tell (abfd));
@@ -2450,14 +2479,14 @@ xcoff_write_archive_contents_big (abfd)
member_table = NULL;
member_table = (bfd_byte *) bfd_zmalloc (member_table_size);
if (member_table == NULL)
- return false;
+ return FALSE;
hdr = (struct xcoff_ar_hdr_big *) member_table;
PRINT20 (hdr->size, (XCOFFARMAGBIG_ELEMENT_SIZE
+ count * XCOFFARMAGBIG_ELEMENT_SIZE
+ total_namlen + (total_namlen & 1)));
- if (makemap && hasobjects)
+ if (makemap && hasobjects)
PRINT20 (hdr->nextoff, nextoff + member_table_size);
else
PRINT20 (hdr->nextoff, 0);
@@ -2467,7 +2496,7 @@ xcoff_write_archive_contents_big (abfd)
PRINT12 (hdr->gid, 0);
PRINT12 (hdr->mode, 0);
PRINT4 (hdr->namlen, 0);
-
+
mt = member_table + SIZEOF_AR_HDR_BIG;
memcpy (mt, XCOFFARFMAG, SXCOFFARFMAG);
mt += SXCOFFARFMAG;
@@ -2480,25 +2509,25 @@ xcoff_write_archive_contents_big (abfd)
mt += XCOFFARMAGBIG_ELEMENT_SIZE;
}
- if (count)
+ if (count)
{
free (offsets);
offsets = NULL;
}
- for (current_bfd = abfd->archive_head; current_bfd != NULL;
+ for (current_bfd = abfd->archive_head; current_bfd != NULL;
current_bfd = current_bfd->next)
{
const char *name;
size_t namlen;
name = normalize_filename (current_bfd);
- namlen = sprintf(mt, "%s", name);
+ namlen = sprintf (mt, "%s", name);
mt += namlen + 1;
}
-
+
if (bfd_bwrite (member_table, member_table_size, abfd) != member_table_size)
- return false;
+ return FALSE;
free (member_table);
member_table = NULL;
@@ -2510,7 +2539,7 @@ xcoff_write_archive_contents_big (abfd)
/* Write out the armap, if appropriate. */
- if (! makemap || ! hasobjects)
+ if (! makemap || ! hasobjects)
PRINT20 (fhdr.symoff, 0);
else
{
@@ -2518,23 +2547,23 @@ xcoff_write_archive_contents_big (abfd)
/* Save nextoff in fhdr.symoff so the armap routine can use it. */
PRINT20 (fhdr.symoff, nextoff);
-
+
bfd_ardata (abfd)->tdata = (PTR) &fhdr;
if (! _bfd_compute_and_write_armap (abfd, 0))
- return false;
+ return FALSE;
}
/* Write out the archive file header. */
if (bfd_seek (abfd, (file_ptr) 0, SEEK_SET) != 0
- || (bfd_bwrite ((PTR) &fhdr, (bfd_size_type) SIZEOF_AR_FILE_HDR_BIG,
+ || (bfd_bwrite ((PTR) &fhdr, (bfd_size_type) SIZEOF_AR_FILE_HDR_BIG,
abfd) != SIZEOF_AR_FILE_HDR_BIG))
- return false;
-
- return true;
+ return FALSE;
+
+ return TRUE;
}
-boolean
+bfd_boolean
_bfd_xcoff_write_archive_contents (abfd)
bfd *abfd;
{
@@ -2550,7 +2579,7 @@ _bfd_xcoff_write_archive_contents (abfd)
int
_bfd_xcoff_sizeof_headers (abfd, reloc)
bfd *abfd;
- boolean reloc ATTRIBUTE_UNUSED;
+ bfd_boolean reloc ATTRIBUTE_UNUSED;
{
int size;
@@ -2725,8 +2754,8 @@ xcoff_swap_ldrel_out (abfd, src, d)
}
-boolean
-xcoff_reloc_type_noop (input_bfd, input_section, output_bfd, rel, sym, howto,
+bfd_boolean
+xcoff_reloc_type_noop (input_bfd, input_section, output_bfd, rel, sym, howto,
val, addend, relocation, contents)
bfd *input_bfd ATTRIBUTE_UNUSED;
asection *input_section ATTRIBUTE_UNUSED;
@@ -2739,11 +2768,11 @@ xcoff_reloc_type_noop (input_bfd, input_section, output_bfd, rel, sym, howto,
bfd_vma *relocation ATTRIBUTE_UNUSED;
bfd_byte *contents ATTRIBUTE_UNUSED;
{
- return true;
+ return TRUE;
}
-boolean
-xcoff_reloc_type_fail (input_bfd, input_section, output_bfd, rel, sym, howto,
+bfd_boolean
+xcoff_reloc_type_fail (input_bfd, input_section, output_bfd, rel, sym, howto,
val, addend, relocation, contents)
bfd *input_bfd;
asection *input_section ATTRIBUTE_UNUSED;
@@ -2760,11 +2789,11 @@ xcoff_reloc_type_fail (input_bfd, input_section, output_bfd, rel, sym, howto,
(_("%s: unsupported relocation type 0x%02x"),
bfd_get_filename (input_bfd), (unsigned int) rel->r_type);
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
-boolean
-xcoff_reloc_type_pos (input_bfd, input_section, output_bfd, rel, sym, howto,
+bfd_boolean
+xcoff_reloc_type_pos (input_bfd, input_section, output_bfd, rel, sym, howto,
val, addend, relocation, contents)
bfd *input_bfd ATTRIBUTE_UNUSED;
asection *input_section ATTRIBUTE_UNUSED;
@@ -2778,11 +2807,11 @@ xcoff_reloc_type_pos (input_bfd, input_section, output_bfd, rel, sym, howto,
bfd_byte *contents ATTRIBUTE_UNUSED;
{
*relocation = val + addend;
- return true;
+ return TRUE;
}
-boolean
-xcoff_reloc_type_neg (input_bfd, input_section, output_bfd, rel, sym, howto,
+bfd_boolean
+xcoff_reloc_type_neg (input_bfd, input_section, output_bfd, rel, sym, howto,
val, addend, relocation, contents)
bfd *input_bfd ATTRIBUTE_UNUSED;
asection *input_section ATTRIBUTE_UNUSED;
@@ -2796,11 +2825,11 @@ xcoff_reloc_type_neg (input_bfd, input_section, output_bfd, rel, sym, howto,
bfd_byte *contents ATTRIBUTE_UNUSED;
{
*relocation = addend - val;
- return true;
+ return TRUE;
}
-boolean
-xcoff_reloc_type_rel (input_bfd, input_section, output_bfd, rel, sym, howto,
+bfd_boolean
+xcoff_reloc_type_rel (input_bfd, input_section, output_bfd, rel, sym, howto,
val, addend, relocation, contents)
bfd *input_bfd ATTRIBUTE_UNUSED;
asection *input_section;
@@ -2813,7 +2842,7 @@ xcoff_reloc_type_rel (input_bfd, input_section, output_bfd, rel, sym, howto,
bfd_vma *relocation;
bfd_byte *contents ATTRIBUTE_UNUSED;
{
- howto->pc_relative = true;
+ howto->pc_relative = TRUE;
/* A PC relative reloc includes the section address. */
addend += input_section->vma;
@@ -2821,11 +2850,11 @@ xcoff_reloc_type_rel (input_bfd, input_section, output_bfd, rel, sym, howto,
*relocation = val + addend;
*relocation -= (input_section->output_section->vma
+ input_section->output_offset);
- return true;
+ return TRUE;
}
-boolean
-xcoff_reloc_type_toc (input_bfd, input_section, output_bfd, rel, sym, howto,
+bfd_boolean
+xcoff_reloc_type_toc (input_bfd, input_section, output_bfd, rel, sym, howto,
val, addend, relocation, contents)
bfd *input_bfd;
asection *input_section ATTRIBUTE_UNUSED;
@@ -2840,8 +2869,8 @@ xcoff_reloc_type_toc (input_bfd, input_section, output_bfd, rel, sym, howto,
{
struct xcoff_link_hash_entry *h;
- if (0 > rel->r_symndx)
- return false;
+ if (0 > rel->r_symndx)
+ return FALSE;
h = obj_xcoff_sym_hashes (input_bfd)[rel->r_symndx];
@@ -2854,21 +2883,21 @@ xcoff_reloc_type_toc (input_bfd, input_section, output_bfd, rel, sym, howto,
bfd_get_filename (input_bfd), rel->r_vaddr,
h->root.root.string);
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
-
+
BFD_ASSERT ((h->flags & XCOFF_SET_TOC) == 0);
val = (h->toc_section->output_section->vma
+ h->toc_section->output_offset);
}
-
+
*relocation = ((val - xcoff_data (output_bfd)->toc)
- (sym->n_value - xcoff_data (input_bfd)->toc));
- return true;
+ return TRUE;
}
-boolean
-xcoff_reloc_type_ba (input_bfd, input_section, output_bfd, rel, sym, howto,
+bfd_boolean
+xcoff_reloc_type_ba (input_bfd, input_section, output_bfd, rel, sym, howto,
val, addend, relocation, contents)
bfd *input_bfd ATTRIBUTE_UNUSED;
asection *input_section ATTRIBUTE_UNUSED;
@@ -2886,11 +2915,11 @@ xcoff_reloc_type_ba (input_bfd, input_section, output_bfd, rel, sym, howto,
*relocation = val + addend;
- return true;
+ return TRUE;
}
-static boolean
-xcoff_reloc_type_br (input_bfd, input_section, output_bfd, rel, sym, howto,
+static bfd_boolean
+xcoff_reloc_type_br (input_bfd, input_section, output_bfd, rel, sym, howto,
val, addend, relocation, contents)
bfd *input_bfd;
asection *input_section;
@@ -2905,8 +2934,8 @@ xcoff_reloc_type_br (input_bfd, input_section, output_bfd, rel, sym, howto,
{
struct xcoff_link_hash_entry *h;
- if (0 > rel->r_symndx)
- return false;
+ if (0 > rel->r_symndx)
+ return FALSE;
h = obj_xcoff_sym_hashes (input_bfd)[rel->r_symndx];
@@ -2917,60 +2946,60 @@ xcoff_reloc_type_br (input_bfd, input_section, output_bfd, rel, sym, howto,
call is followed by a lwz r2,20(r1), but the call is not
going to global linkage code, we can replace the load with a
cror. */
- if (NULL != h
- && bfd_link_hash_defined == h->root.type
+ if (NULL != h
+ && bfd_link_hash_defined == h->root.type
&& (rel->r_vaddr - input_section->vma + 8
<= input_section->_cooked_size))
{
bfd_byte *pnext;
unsigned long next;
-
+
pnext = contents + (rel->r_vaddr - input_section->vma) + 4;
next = bfd_get_32 (input_bfd, pnext);
-
+
/* The _ptrgl function is magic. It is used by the AIX
compiler to call a function through a pointer. */
if (h->smclas == XMC_GL || strcmp (h->root.root.string, "._ptrgl") == 0)
{
- if (next == 0x4def7b82 /* cror 15,15,15 */
- || next == 0x4ffffb82 /* cror 31,31,31 */
- || next == 0x60000000) /* ori r0,r0,0 */
- bfd_put_32 (input_bfd, 0x80410014, pnext); /* lwz r1,20(r1) */
-
+ if (next == 0x4def7b82 /* cror 15,15,15 */
+ || next == 0x4ffffb82 /* cror 31,31,31 */
+ || next == 0x60000000) /* ori r0,r0,0 */
+ bfd_put_32 (input_bfd, 0x80410014, pnext); /* lwz r1,20(r1) */
+
}
else
- {
- if (next == 0x80410014) /* lwz r1,20(r1) */
- bfd_put_32 (input_bfd, 0x60000000, pnext); /* ori r0,r0,0 */
- }
- }
- else if (NULL != h && bfd_link_hash_undefined == h->root.type)
+ {
+ if (next == 0x80410014) /* lwz r1,20(r1) */
+ bfd_put_32 (input_bfd, 0x60000000, pnext); /* ori r0,r0,0 */
+ }
+ }
+ else if (NULL != h && bfd_link_hash_undefined == h->root.type)
{
/* Normally, this relocation is against a defined symbol. In the
case where this is a partial link and the output section offset
- is greater than 2^25, the linker will return an invalid error
+ is greater than 2^25, the linker will return an invalid error
message that the relocation has been truncated. Yes it has been
- truncated but no it not important. For this case, disable the
+ truncated but no it not important. For this case, disable the
overflow checking. */
-
+
howto->complain_on_overflow = complain_overflow_dont;
}
-
- howto->pc_relative = true;
+
+ howto->pc_relative = TRUE;
howto->src_mask &= ~3;
howto->dst_mask = howto->src_mask;
/* A PC relative reloc includes the section address. */
addend += input_section->vma;
-
+
*relocation = val + addend;
*relocation -= (input_section->output_section->vma
+ input_section->output_offset);
- return true;
+ return TRUE;
}
-boolean
-xcoff_reloc_type_crel (input_bfd, input_section, output_bfd, rel, sym, howto,
+bfd_boolean
+xcoff_reloc_type_crel (input_bfd, input_section, output_bfd, rel, sym, howto,
val, addend, relocation, contents)
bfd *input_bfd ATTRIBUTE_UNUSED;
asection *input_section;
@@ -2983,7 +3012,7 @@ xcoff_reloc_type_crel (input_bfd, input_section, output_bfd, rel, sym, howto,
bfd_vma *relocation;
bfd_byte *contents ATTRIBUTE_UNUSED;
{
- howto->pc_relative = true;
+ howto->pc_relative = TRUE;
howto->src_mask &= ~3;
howto->dst_mask = howto->src_mask;
@@ -2993,29 +3022,29 @@ xcoff_reloc_type_crel (input_bfd, input_section, output_bfd, rel, sym, howto,
*relocation = val + addend;
*relocation -= (input_section->output_section->vma
+ input_section->output_offset);
- return true;
+ return TRUE;
}
-static boolean
-xcoff_complain_overflow_dont_func (input_bfd, val, relocation, howto)
+static bfd_boolean
+xcoff_complain_overflow_dont_func (input_bfd, val, relocation, howto)
bfd *input_bfd ATTRIBUTE_UNUSED;
bfd_vma val ATTRIBUTE_UNUSED;
bfd_vma relocation ATTRIBUTE_UNUSED;
struct reloc_howto_struct *howto ATTRIBUTE_UNUSED;
{
- return false;
+ return FALSE;
}
-static boolean
-xcoff_complain_overflow_bitfield_func (input_bfd, val, relocation, howto)
+static bfd_boolean
+xcoff_complain_overflow_bitfield_func (input_bfd, val, relocation, howto)
bfd *input_bfd;
bfd_vma val;
bfd_vma relocation;
- struct reloc_howto_struct *howto;
+ struct reloc_howto_struct *howto;
{
bfd_vma addrmask, fieldmask, signmask, ss;
bfd_vma a, b, sum;
-
+
/* Get the values to be added together. For signed and unsigned
relocations, we assume that all values should be truncated to
the size of an address. For bitfields, all the bits matter.
@@ -3031,7 +3060,7 @@ xcoff_complain_overflow_bitfield_func (input_bfd, val, relocation, howto)
operand. */
a >>= howto->rightshift;
b >>= howto->bitpos;
-
+
/* Bitfields are sometimes used for signed numbers; for
example, a 13-bit field sometimes represents values in
0..8191 and sometimes represents values in -4096..4095.
@@ -3043,7 +3072,7 @@ xcoff_complain_overflow_bitfield_func (input_bfd, val, relocation, howto)
assumed that it was fully sign extended, and we will keep
that assumption. */
signmask = (fieldmask >> 1) + 1;
-
+
if ((a & ~ fieldmask) != 0)
{
/* Some bits out of the field are set. This might not
@@ -3054,12 +3083,12 @@ xcoff_complain_overflow_bitfield_func (input_bfd, val, relocation, howto)
ones, we are OK, assuming a signed bitfield. */
ss = (signmask << howto->rightshift) - 1;
if ((ss | relocation) != ~ (bfd_vma) 0)
- return true;
+ return TRUE;
a &= fieldmask;
}
-
+
/* We just assume (b & ~ fieldmask) == 0. */
-
+
/* We explicitly permit wrap around if this relocation
covers the high bit of an address. The Linux kernel
relies on it, and it is the only way to write assembler
@@ -3067,8 +3096,8 @@ xcoff_complain_overflow_bitfield_func (input_bfd, val, relocation, howto)
away from the location at which it is linked. */
if (howto->bitsize + howto->rightshift
== bfd_arch_bits_per_address (input_bfd))
- return false;
-
+ return FALSE;
+
sum = a + b;
if (sum < a || (sum & ~ fieldmask) != 0)
{
@@ -3076,14 +3105,14 @@ xcoff_complain_overflow_bitfield_func (input_bfd, val, relocation, howto)
for signed operands again. Here is the overflow test
is as for complain_overflow_signed. */
if (((~ (a ^ b)) & (a ^ sum)) & signmask)
- return true;
+ return TRUE;
}
-
- return false;
+
+ return FALSE;
}
-static boolean
-xcoff_complain_overflow_signed_func (input_bfd, val, relocation, howto)
+static bfd_boolean
+xcoff_complain_overflow_signed_func (input_bfd, val, relocation, howto)
bfd *input_bfd;
bfd_vma val;
bfd_vma relocation;
@@ -3091,7 +3120,7 @@ xcoff_complain_overflow_signed_func (input_bfd, val, relocation, howto)
{
bfd_vma addrmask, fieldmask, signmask, ss;
bfd_vma a, b, sum;
-
+
/* Get the values to be added together. For signed and unsigned
relocations, we assume that all values should be truncated to
the size of an address. For bitfields, all the bits matter.
@@ -3102,15 +3131,15 @@ xcoff_complain_overflow_signed_func (input_bfd, val, relocation, howto)
b = val & howto->src_mask;
a = (a & addrmask) >> howto->rightshift;
-
+
/* If any sign bits are set, all sign bits must be set.
That is, A must be a valid negative address after
shifting. */
signmask = ~ (fieldmask >> 1);
ss = a & signmask;
if (ss != 0 && ss != ((addrmask >> howto->rightshift) & signmask))
- return true;
-
+ return TRUE;
+
/* We only need this next bit of code if the sign bit of B
is below the sign bit of A. This would only happen if
SRC_MASK had fewer bits than BITSIZE. Note that if
@@ -3123,12 +3152,12 @@ xcoff_complain_overflow_signed_func (input_bfd, val, relocation, howto)
/* Set all the bits above the sign bit. */
b -= signmask <<= 1;
}
-
+
b = (b & addrmask) >> howto->bitpos;
-
+
/* Now we can do the addition. */
sum = a + b;
-
+
/* See if the result has the correct sign. Bits above the
sign bit are junk now; ignore them. If the sum is
positive, make sure we did not have all negative inputs;
@@ -3139,21 +3168,21 @@ xcoff_complain_overflow_signed_func (input_bfd, val, relocation, howto)
*/
signmask = (fieldmask >> 1) + 1;
if (((~ (a ^ b)) & (a ^ sum)) & signmask)
- return true;
-
- return false;
+ return TRUE;
+
+ return FALSE;
}
-static boolean
-xcoff_complain_overflow_unsigned_func (input_bfd, val, relocation, howto)
+static bfd_boolean
+xcoff_complain_overflow_unsigned_func (input_bfd, val, relocation, howto)
bfd *input_bfd;
bfd_vma val;
bfd_vma relocation;
- struct reloc_howto_struct *howto;
+ struct reloc_howto_struct *howto;
{
bfd_vma addrmask, fieldmask;
bfd_vma a, b, sum;
-
+
/* Get the values to be added together. For signed and unsigned
relocations, we assume that all values should be truncated to
the size of an address. For bitfields, all the bits matter.
@@ -3178,32 +3207,32 @@ xcoff_complain_overflow_unsigned_func (input_bfd, val, relocation, howto)
b = (b & addrmask) >> howto->bitpos;
sum = (a + b) & addrmask;
if ((a | b | sum) & ~ fieldmask)
- return true;
-
- return false;
+ return TRUE;
+
+ return FALSE;
}
/* This is the relocation function for the RS/6000/POWER/PowerPC.
This is currently the only processor which uses XCOFF; I hope that
- will never change.
+ will never change.
I took the relocation type definitions from two documents:
the PowerPC AIX Version 4 Application Binary Interface, First
Edition (April 1992), and the PowerOpen ABI, Big-Endian
32-Bit Hardware Implementation (June 30, 1994). Differences
- between the documents are noted below.
+ between the documents are noted below.
- Unsupported r_type's
+ Unsupported r_type's
R_RTB:
R_RRTBI:
R_RRTBA:
-
+
These relocs are defined by the PowerPC ABI to be
relative branches which use half of the difference
between the symbol and the program counter. I can't
quite figure out when this is useful. These relocs are
- not defined by the PowerOpen ABI.
+ not defined by the PowerOpen ABI.
Supported r_type's
@@ -3211,7 +3240,7 @@ xcoff_complain_overflow_unsigned_func (input_bfd, val, relocation, howto)
Simple positive relocation.
R_NEG:
- Simple negative relocation.
+ Simple negative relocation.
R_REL:
Simple PC relative relocation.
@@ -3229,16 +3258,16 @@ xcoff_complain_overflow_unsigned_func (input_bfd, val, relocation, howto)
R_GL:
GL linkage relocation. The value of this relocation
- is the address of the entry in the TOC section.
+ is the address of the entry in the TOC section.
R_TCL:
Local object TOC address. I can't figure out the
- difference between this and case R_GL.
+ difference between this and case R_GL.
R_TRL:
TOC relative relocation. A TOC relative load instruction
which may be changed to a load address instruction.
- FIXME: We don't currently implement this optimization.
+ FIXME: We don't currently implement this optimization.
R_TRLA:
TOC relative relocation. This is a TOC relative load
@@ -3248,55 +3277,55 @@ xcoff_complain_overflow_unsigned_func (input_bfd, val, relocation, howto)
R_BA:
Absolute branch. We don't want to mess with the lower
- two bits of the instruction.
+ two bits of the instruction.
R_CAI:
The PowerPC ABI defines this as an absolute call which
may be modified to become a relative call. The PowerOpen
- ABI does not define this relocation type.
-
+ ABI does not define this relocation type.
+
R_RBA:
Absolute branch which may be modified to become a
- relative branch.
+ relative branch.
R_RBAC:
The PowerPC ABI defines this as an absolute branch to a
fixed address which may be modified to an absolute branch
to a symbol. The PowerOpen ABI does not define this
- relocation type.
+ relocation type.
R_RBRC:
The PowerPC ABI defines this as an absolute branch to a
fixed address which may be modified to a relative branch.
- The PowerOpen ABI does not define this relocation type.
+ The PowerOpen ABI does not define this relocation type.
R_BR:
Relative branch. We don't want to mess with the lower
- two bits of the instruction.
+ two bits of the instruction.
R_CREL:
The PowerPC ABI defines this as a relative call which may
be modified to become an absolute call. The PowerOpen
- ABI does not define this relocation type.
+ ABI does not define this relocation type.
R_RBR:
A relative branch which may be modified to become an
absolute branch. FIXME: We don't implement this,
although we should for symbols of storage mapping class
- XMC_XO.
+ XMC_XO.
R_RL:
The PowerPC AIX ABI describes this as a load which may be
changed to a load address. The PowerOpen ABI says this
- is the same as case R_POS.
+ is the same as case R_POS.
R_RLA:
The PowerPC AIX ABI describes this as a load address
which may be changed to a load. The PowerOpen ABI says
- this is the same as R_POS.
+ this is the same as R_POS.
*/
-boolean
+bfd_boolean
xcoff_ppc_relocate_section (output_bfd, info, input_bfd,
input_section, contents, relocs, syms,
sections)
@@ -3328,8 +3357,8 @@ xcoff_ppc_relocate_section (output_bfd, info, input_bfd,
bfd_byte *location;
/* Relocation type R_REF is a special relocation type which is
- merely used to prevent garbage collection from occurring for
- the csect including the symbol which it references. */
+ merely used to prevent garbage collection from occurring for
+ the csect including the symbol which it references. */
if (rel->r_type == R_REF)
continue;
@@ -3338,33 +3367,33 @@ xcoff_ppc_relocate_section (output_bfd, info, input_bfd,
howto.rightshift = 0;
howto.bitsize = (rel->r_size & 0x1f) + 1;
howto.size = howto.bitsize > 16 ? 2 : 1;
- howto.pc_relative = false;
+ howto.pc_relative = FALSE;
howto.bitpos = 0;
howto.complain_on_overflow = (rel->r_size & 0x80
? complain_overflow_signed
: complain_overflow_bitfield);
howto.special_function = NULL;
howto.name = "internal";
- howto.partial_inplace = true;
- howto.src_mask = howto.dst_mask = N_ONES(howto.bitsize);
- howto.pcrel_offset = false;
+ howto.partial_inplace = TRUE;
+ howto.src_mask = howto.dst_mask = N_ONES (howto.bitsize);
+ howto.pcrel_offset = FALSE;
/* symbol */
val = 0;
addend = 0;
h = NULL;
sym = NULL;
- symndx = rel->r_symndx;
+ symndx = rel->r_symndx;
- if (-1 != symndx)
+ if (-1 != symndx)
{
asection *sec;
-
+
h = obj_xcoff_sym_hashes (input_bfd)[symndx];
sym = syms + symndx;
addend = - sym->n_value;
-
- if (NULL == h)
+
+ if (NULL == h)
{
sec = sections[symndx];
/* Hack to make sure we use the right TOC anchor value
@@ -3377,32 +3406,32 @@ xcoff_ppc_relocate_section (output_bfd, info, input_bfd,
+ sec->output_offset
+ sym->n_value
- sec->vma);
- }
- else
+ }
+ else
{
- if (h->root.type == bfd_link_hash_defined
- || h->root.type == bfd_link_hash_defweak)
+ if (h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak)
{
sec = h->root.u.def.section;
val = (h->root.u.def.value
+ sec->output_section->vma
+ sec->output_offset);
- }
- else if (h->root.type == bfd_link_hash_common)
+ }
+ else if (h->root.type == bfd_link_hash_common)
{
sec = h->root.u.c.p->section;
val = (sec->output_section->vma
+ sec->output_offset);
-
- }
- else if ((0 == (h->flags & (XCOFF_DEF_DYNAMIC | XCOFF_IMPORT)))
- && ! info->relocateable)
+
+ }
+ else if ((0 == (h->flags & (XCOFF_DEF_DYNAMIC | XCOFF_IMPORT)))
+ && ! info->relocatable)
{
if (! ((*info->callbacks->undefined_symbol)
(info, h->root.root.string, input_bfd, input_section,
- rel->r_vaddr - input_section->vma, true)))
- return false;
-
+ rel->r_vaddr - input_section->vma, TRUE)))
+ return FALSE;
+
/* Don't try to process the reloc. It can't help, and
it may generate another error. */
continue;
@@ -3410,81 +3439,81 @@ xcoff_ppc_relocate_section (output_bfd, info, input_bfd,
}
}
- if (rel->r_type >= XCOFF_MAX_CALCULATE_RELOCATION
+ if (rel->r_type >= XCOFF_MAX_CALCULATE_RELOCATION
|| !((*xcoff_calculate_relocation[rel->r_type])
- (input_bfd, input_section, output_bfd, rel, sym, &howto, val,
- addend, &relocation, contents)))
- return false;
-
+ (input_bfd, input_section, output_bfd, rel, sym, &howto, val,
+ addend, &relocation, contents)))
+ return FALSE;
+
/* address */
address = rel->r_vaddr - input_section->vma;
location = contents + address;
-
+
if (address > input_section->_raw_size)
- abort();
+ abort ();
/* Get the value we are going to relocate. */
if (1 == howto.size)
value_to_relocate = bfd_get_16 (input_bfd, location);
- else
+ else
value_to_relocate = bfd_get_32 (input_bfd, location);
-
- /* overflow.
-
+
+ /* overflow.
+
FIXME: We may drop bits during the addition
which we don't check for. We must either check at every single
operation, which would be tedious, or we must do the computations
in a type larger than bfd_vma, which would be inefficient. */
-
+
if ((unsigned int) howto.complain_on_overflow
>= XCOFF_MAX_COMPLAIN_OVERFLOW)
- abort();
+ abort ();
if (((*xcoff_complain_overflow[howto.complain_on_overflow])
- (input_bfd, value_to_relocate, relocation, &howto)))
+ (input_bfd, value_to_relocate, relocation, &howto)))
{
const char *name;
char buf[SYMNMLEN + 1];
char reloc_type_name[10];
-
- if (symndx == -1)
+
+ if (symndx == -1)
{
name = "*ABS*";
- }
- else if (h != NULL)
+ }
+ else if (h != NULL)
{
name = h->root.root.string;
- }
- else
+ }
+ else
{
name = _bfd_coff_internal_syment_name (input_bfd, sym, buf);
if (name == NULL)
name = "UNKNOWN";
}
sprintf (reloc_type_name, "0x%02x", rel->r_type);
-
+
if (! ((*info->callbacks->reloc_overflow)
(info, name, reloc_type_name, (bfd_vma) 0, input_bfd,
input_section, rel->r_vaddr - input_section->vma)))
- return false;
+ return FALSE;
}
-
+
/* Add RELOCATION to the right bits of VALUE_TO_RELOCATE. */
value_to_relocate = ((value_to_relocate & ~howto.dst_mask)
| (((value_to_relocate & howto.src_mask)
+ relocation) & howto.dst_mask));
-
+
/* Put the value back in the object file. */
if (1 == howto.size)
bfd_put_16 (input_bfd, value_to_relocate, location);
- else
+ else
bfd_put_32 (input_bfd, value_to_relocate, location);
}
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
_bfd_xcoff_put_ldsymbol_name (abfd, ldinfo, ldsym, name)
bfd *abfd ATTRIBUTE_UNUSED;
struct xcoff_loader_info *ldinfo;
@@ -3513,8 +3542,8 @@ _bfd_xcoff_put_ldsymbol_name (abfd, ldinfo, ldsym, name)
bfd_realloc ((PTR) ldinfo->strings, newalc));
if (newstrings == NULL)
{
- ldinfo->failed = true;
- return false;
+ ldinfo->failed = TRUE;
+ return FALSE;
}
ldinfo->string_alc = newalc;
ldinfo->strings = newstrings;
@@ -3528,10 +3557,10 @@ _bfd_xcoff_put_ldsymbol_name (abfd, ldinfo, ldsym, name)
ldinfo->string_size += len + 3;
}
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
_bfd_xcoff_put_symbol_name (bfd *abfd, struct bfd_strtab_hash *strtab,
struct internal_syment *sym,
const char *name)
@@ -3542,19 +3571,19 @@ _bfd_xcoff_put_symbol_name (bfd *abfd, struct bfd_strtab_hash *strtab,
}
else
{
- boolean hash;
+ bfd_boolean hash;
bfd_size_type indx;
- hash = true;
+ hash = TRUE;
if ((abfd->flags & BFD_TRADITIONAL_FORMAT) != 0)
- hash = false;
- indx = _bfd_stringtab_add (strtab, name, hash, false);
+ hash = FALSE;
+ indx = _bfd_stringtab_add (strtab, name, hash, FALSE);
if (indx == (bfd_size_type) -1)
- return false;
+ return FALSE;
sym->_n._n_n._n_zeroes = 0;
sym->_n._n_n._n_offset = STRING_SIZE_SIZE + indx;
}
- return true;
+ return TRUE;
}
static asection *
@@ -3591,26 +3620,26 @@ xcoff_create_csect_from_smclas (abfd, aux, symbol_name)
return return_value;
}
-static boolean
+static bfd_boolean
xcoff_is_lineno_count_overflow (abfd, value)
bfd *abfd ATTRIBUTE_UNUSED;
bfd_vma value;
{
if (0xffff <= value)
- return true;
+ return TRUE;
- return false;
+ return FALSE;
}
-static boolean
+static bfd_boolean
xcoff_is_reloc_count_overflow (abfd, value)
bfd *abfd ATTRIBUTE_UNUSED;
bfd_vma value;
{
if (0xffff <= value)
- return true;
+ return TRUE;
- return false;
+ return FALSE;
}
static bfd_vma
@@ -3618,7 +3647,7 @@ xcoff_loader_symbol_offset (abfd, ldhdr)
bfd *abfd;
struct internal_ldhdr *ldhdr ATTRIBUTE_UNUSED;
{
- return bfd_xcoff_ldhdrsz(abfd);
+ return bfd_xcoff_ldhdrsz (abfd);
}
static bfd_vma
@@ -3629,12 +3658,12 @@ xcoff_loader_reloc_offset (abfd, ldhdr)
return bfd_xcoff_ldhdrsz (abfd) + ldhdr->l_nsyms * bfd_xcoff_ldsymsz (abfd);
}
-static boolean
+static bfd_boolean
xcoff_generate_rtinit (abfd, init, fini, rtld)
bfd *abfd;
const char *init;
const char *fini;
- boolean rtld;
+ bfd_boolean rtld;
{
bfd_byte filehdr_ext[FILHSZ];
bfd_byte scnhdr_ext[SCNHSZ];
@@ -3651,13 +3680,13 @@ xcoff_generate_rtinit (abfd, init, fini, rtld)
struct internal_syment syment;
union internal_auxent auxent;
struct internal_reloc reloc;
-
+
char *data_name = ".data";
char *rtinit_name = "__rtinit";
char *rtld_name = "__rtld";
-
+
if (! bfd_xcoff_rtinit_size (abfd))
- return false;
+ return FALSE;
initsz = (init == NULL ? 0 : 1 + strlen (init));
finisz = (fini == NULL ? 0 : 1 + strlen (fini));
@@ -3666,7 +3695,7 @@ xcoff_generate_rtinit (abfd, init, fini, rtld)
memset (filehdr_ext, 0, FILHSZ);
memset (&filehdr, 0, sizeof (struct internal_filehdr));
filehdr.f_magic = bfd_xcoff_magic_number (abfd);
- filehdr.f_nscns = 1;
+ filehdr.f_nscns = 1;
filehdr.f_timdat = 0;
filehdr.f_nsyms = 0; /* at least 6, no more than 10 */
filehdr.f_symptr = 0; /* set below */
@@ -3687,34 +3716,34 @@ xcoff_generate_rtinit (abfd, init, fini, rtld)
scnhdr.s_nlnno = 0;
scnhdr.s_flags = STYP_DATA;
- /* .data
- 0x0000 0x00000000 : rtl
- 0x0004 0x00000010 : offset to init, or 0
- 0x0008 0x00000028 : offset to fini, or 0
- 0x000C 0x0000000C : size of descriptor
- 0x0010 0x00000000 : init, needs a reloc
- 0x0014 0x00000040 : offset to init name
- 0x0018 0x00000000 : flags, padded to a word
- 0x001C 0x00000000 : empty init
- 0x0020 0x00000000 :
- 0x0024 0x00000000 :
- 0x0028 0x00000000 : fini, needs a reloc
- 0x002C 0x00000??? : offset to fini name
- 0x0030 0x00000000 : flags, padded to a word
- 0x0034 0x00000000 : empty fini
- 0x0038 0x00000000 :
- 0x003C 0x00000000 :
- 0x0040 init name
+ /* .data
+ 0x0000 0x00000000 : rtl
+ 0x0004 0x00000010 : offset to init, or 0
+ 0x0008 0x00000028 : offset to fini, or 0
+ 0x000C 0x0000000C : size of descriptor
+ 0x0010 0x00000000 : init, needs a reloc
+ 0x0014 0x00000040 : offset to init name
+ 0x0018 0x00000000 : flags, padded to a word
+ 0x001C 0x00000000 : empty init
+ 0x0020 0x00000000 :
+ 0x0024 0x00000000 :
+ 0x0028 0x00000000 : fini, needs a reloc
+ 0x002C 0x00000??? : offset to fini name
+ 0x0030 0x00000000 : flags, padded to a word
+ 0x0034 0x00000000 : empty fini
+ 0x0038 0x00000000 :
+ 0x003C 0x00000000 :
+ 0x0040 init name
0x0040 + initsz fini name */
data_buffer_size = 0x0040 + initsz + finisz;
- data_buffer_size += (data_buffer_size & 7) ? 8 - (data_buffer_size & 7) : 0;
+ data_buffer_size = (data_buffer_size + 7) &~ (bfd_size_type) 7;
data_buffer = NULL;
data_buffer = (bfd_byte *) bfd_zmalloc (data_buffer_size);
if (data_buffer == NULL)
- return false;
+ return FALSE;
- if (initsz)
+ if (initsz)
{
val = 0x10;
bfd_h_put_32 (abfd, val, &data_buffer[0x04]);
@@ -3723,7 +3752,7 @@ xcoff_generate_rtinit (abfd, init, fini, rtld)
memcpy (&data_buffer[val], init, initsz);
}
- if (finisz)
+ if (finisz)
{
val = 0x28;
bfd_h_put_32 (abfd, val, &data_buffer[0x08]);
@@ -3739,7 +3768,7 @@ xcoff_generate_rtinit (abfd, init, fini, rtld)
/* string table */
string_table_size = 0;
- if (initsz > 9)
+ if (initsz > 9)
string_table_size += initsz;
if (finisz > 9)
string_table_size += finisz;
@@ -3748,18 +3777,18 @@ xcoff_generate_rtinit (abfd, init, fini, rtld)
string_table_size += 4;
string_table = (bfd_byte *) bfd_zmalloc (string_table_size);
if (string_table == NULL)
- return false;
+ return FALSE;
val = string_table_size;
bfd_h_put_32 (abfd, val, &string_table[0]);
st_tmp = string_table + 4;
}
-
- /* symbols
+
+ /* symbols
0. .data csect
2. __rtinit
- 4. init function
- 6. fini function
+ 4. init function
+ 6. fini function
8. __rtld */
memset (syment_ext, 0, 10 * SYMESZ);
memset (reloc_ext, 0, 3 * RELSZ);
@@ -3774,10 +3803,10 @@ xcoff_generate_rtinit (abfd, init, fini, rtld)
auxent.x_csect.x_scnlen.l = data_buffer_size;
auxent.x_csect.x_smtyp = 3 << 3 | XTY_SD;
auxent.x_csect.x_smclas = XMC_RW;
- bfd_coff_swap_sym_out (abfd, &syment,
+ bfd_coff_swap_sym_out (abfd, &syment,
&syment_ext[filehdr.f_nsyms * SYMESZ]);
- bfd_coff_swap_aux_out (abfd, &auxent, syment.n_type, syment.n_sclass, 0,
- syment.n_numaux,
+ bfd_coff_swap_aux_out (abfd, &auxent, syment.n_type, syment.n_sclass, 0,
+ syment.n_numaux,
&syment_ext[(filehdr.f_nsyms + 1) * SYMESZ]);
filehdr.f_nsyms += 2;
@@ -3790,20 +3819,20 @@ xcoff_generate_rtinit (abfd, init, fini, rtld)
syment.n_numaux = 1;
auxent.x_csect.x_smtyp = XTY_LD;
auxent.x_csect.x_smclas = XMC_RW;
- bfd_coff_swap_sym_out (abfd, &syment,
+ bfd_coff_swap_sym_out (abfd, &syment,
&syment_ext[filehdr.f_nsyms * SYMESZ]);
- bfd_coff_swap_aux_out (abfd, &auxent, syment.n_type, syment.n_sclass, 0,
- syment.n_numaux,
+ bfd_coff_swap_aux_out (abfd, &auxent, syment.n_type, syment.n_sclass, 0,
+ syment.n_numaux,
&syment_ext[(filehdr.f_nsyms + 1) * SYMESZ]);
filehdr.f_nsyms += 2;
/* init */
- if (initsz)
+ if (initsz)
{
memset (&syment, 0, sizeof (struct internal_syment));
memset (&auxent, 0, sizeof (union internal_auxent));
- if (initsz > 9)
+ if (initsz > 9)
{
syment._n._n_n._n_offset = st_tmp - string_table;
memcpy (st_tmp, init, initsz);
@@ -3814,10 +3843,10 @@ xcoff_generate_rtinit (abfd, init, fini, rtld)
syment.n_sclass = C_EXT;
syment.n_numaux = 1;
- bfd_coff_swap_sym_out (abfd, &syment,
+ bfd_coff_swap_sym_out (abfd, &syment,
&syment_ext[filehdr.f_nsyms * SYMESZ]);
- bfd_coff_swap_aux_out (abfd, &auxent, syment.n_type, syment.n_sclass, 0,
- syment.n_numaux,
+ bfd_coff_swap_aux_out (abfd, &auxent, syment.n_type, syment.n_sclass, 0,
+ syment.n_numaux,
&syment_ext[(filehdr.f_nsyms + 1) * SYMESZ]);
/* reloc */
@@ -3831,14 +3860,14 @@ xcoff_generate_rtinit (abfd, init, fini, rtld)
filehdr.f_nsyms += 2;
scnhdr.s_nreloc += 1;
}
-
+
/* fini */
- if (finisz)
+ if (finisz)
{
memset (&syment, 0, sizeof (struct internal_syment));
memset (&auxent, 0, sizeof (union internal_auxent));
- if (finisz > 9)
+ if (finisz > 9)
{
syment._n._n_n._n_offset = st_tmp - string_table;
memcpy (st_tmp, fini, finisz);
@@ -3849,10 +3878,10 @@ xcoff_generate_rtinit (abfd, init, fini, rtld)
syment.n_sclass = C_EXT;
syment.n_numaux = 1;
- bfd_coff_swap_sym_out (abfd, &syment,
+ bfd_coff_swap_sym_out (abfd, &syment,
&syment_ext[filehdr.f_nsyms * SYMESZ]);
- bfd_coff_swap_aux_out (abfd, &auxent, syment.n_type, syment.n_sclass, 0,
- syment.n_numaux,
+ bfd_coff_swap_aux_out (abfd, &auxent, syment.n_type, syment.n_sclass, 0,
+ syment.n_numaux,
&syment_ext[(filehdr.f_nsyms + 1) * SYMESZ]);
/* reloc */
@@ -3861,7 +3890,7 @@ xcoff_generate_rtinit (abfd, init, fini, rtld)
reloc.r_symndx = filehdr.f_nsyms;
reloc.r_type = R_POS;
reloc.r_size = 31;
- bfd_coff_swap_reloc_out (abfd, &reloc,
+ bfd_coff_swap_reloc_out (abfd, &reloc,
&reloc_ext[scnhdr.s_nreloc * RELSZ]);
filehdr.f_nsyms += 2;
@@ -3875,10 +3904,10 @@ xcoff_generate_rtinit (abfd, init, fini, rtld)
memcpy (syment._n._n_name, rtld_name, strlen (rtld_name));
syment.n_sclass = C_EXT;
syment.n_numaux = 1;
- bfd_coff_swap_sym_out (abfd, &syment,
+ bfd_coff_swap_sym_out (abfd, &syment,
&syment_ext[filehdr.f_nsyms * SYMESZ]);
- bfd_coff_swap_aux_out (abfd, &auxent, syment.n_type, syment.n_sclass, 0,
- syment.n_numaux,
+ bfd_coff_swap_aux_out (abfd, &auxent, syment.n_type, syment.n_sclass, 0,
+ syment.n_numaux,
&syment_ext[(filehdr.f_nsyms + 1) * SYMESZ]);
/* reloc */
@@ -3887,7 +3916,7 @@ xcoff_generate_rtinit (abfd, init, fini, rtld)
reloc.r_symndx = filehdr.f_nsyms;
reloc.r_type = R_POS;
reloc.r_size = 31;
- bfd_coff_swap_reloc_out (abfd, &reloc,
+ bfd_coff_swap_reloc_out (abfd, &reloc,
&reloc_ext[scnhdr.s_nreloc * RELSZ]);
filehdr.f_nsyms += 2;
@@ -3909,24 +3938,24 @@ xcoff_generate_rtinit (abfd, init, fini, rtld)
free (data_buffer);
data_buffer = NULL;
- return true;
+ return TRUE;
}
static reloc_howto_type xcoff_dynamic_reloc =
-HOWTO (0, /* type */
- 0, /* rightshift */
- 2, /* size (0 = byte, 1 = short, 2 = long) */
- 32, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+HOWTO (0, /* type */
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
- 0, /* special_function */
- "R_POS", /* name */
- true, /* partial_inplace */
- 0xffffffff, /* src_mask */
- 0xffffffff, /* dst_mask */
- false); /* pcrel_offset */
+ 0, /* special_function */
+ "R_POS", /* name */
+ TRUE, /* partial_inplace */
+ 0xffffffff, /* src_mask */
+ 0xffffffff, /* dst_mask */
+ FALSE); /* pcrel_offset */
/* glink
@@ -3968,11 +3997,11 @@ static const struct xcoff_backend_data_rec bfd_xcoff_backend_data =
RELSZ,
LINESZ,
FILNMLEN,
- true, /* _bfd_coff_long_filenames */
- false, /* _bfd_coff_long_section_names */
+ TRUE, /* _bfd_coff_long_filenames */
+ FALSE, /* _bfd_coff_long_section_names */
3, /* _bfd_coff_default_section_alignment_power */
- false, /* _bfd_coff_force_symnames_in_strings */
- 2, /* _bfd_coff_debug_string_prefix_length */
+ FALSE, /* _bfd_coff_force_symnames_in_strings */
+ 2, /* _bfd_coff_debug_string_prefix_length */
coff_swap_filehdr_in,
coff_swap_aouthdr_in,
coff_swap_scnhdr_in,
@@ -3988,9 +4017,9 @@ static const struct xcoff_backend_data_rec bfd_xcoff_backend_data =
coff_print_aux,
dummy_reloc16_extra_cases,
dummy_reloc16_estimate,
- NULL, /* bfd_coff_sym_is_global */
+ NULL, /* bfd_coff_sym_is_global */
coff_compute_section_file_positions,
- NULL, /* _bfd_coff_start_final_link */
+ NULL, /* _bfd_coff_start_final_link */
xcoff_ppc_relocate_section,
coff_rtype_to_howto,
NULL, /* _bfd_coff_adjust_symndx */
@@ -3999,7 +4028,7 @@ static const struct xcoff_backend_data_rec bfd_xcoff_backend_data =
coff_final_link_postscript
},
- 0x01DF, /* magic number */
+ 0x01DF, /* magic number */
bfd_arch_rs6000,
bfd_mach_rs6k,
@@ -4015,11 +4044,11 @@ static const struct xcoff_backend_data_rec bfd_xcoff_backend_data =
LDHDRSZ,
LDSYMSZ,
LDRELSZ,
- 12, /* _xcoff_function_descriptor_size */
+ 12, /* _xcoff_function_descriptor_size */
SMALL_AOUTSZ,
- /* Versions. */
- 1, /* _xcoff_ldhdr_version */
+ /* Versions. */
+ 1, /* _xcoff_ldhdr_version */
_bfd_xcoff_put_symbol_name,
_bfd_xcoff_put_ldsymbol_name,
@@ -4034,31 +4063,31 @@ static const struct xcoff_backend_data_rec bfd_xcoff_backend_data =
xcoff_loader_reloc_offset,
/* glink. */
- & xcoff_glink_code[0],
+ &xcoff_glink_code[0],
36, /* _xcoff_glink_size */
/* rtinit */
- 64, /* _xcoff_rtinit_size */
+ 64, /* _xcoff_rtinit_size */
xcoff_generate_rtinit,
-};
+ };
/* The transfer vector that leads the outside world to all of the above. */
const bfd_target rs6000coff_vec =
-{
- "aixcoff-rs6000",
- bfd_target_xcoff_flavour,
- BFD_ENDIAN_BIG, /* data byte order is big */
- BFD_ENDIAN_BIG, /* header byte order is big */
+ {
+ "aixcoff-rs6000",
+ bfd_target_xcoff_flavour,
+ BFD_ENDIAN_BIG, /* data byte order is big */
+ BFD_ENDIAN_BIG, /* header byte order is big */
(HAS_RELOC | EXEC_P | HAS_LINENO | HAS_DEBUG | DYNAMIC
| HAS_SYMS | HAS_LOCALS | WP_TEXT),
- (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_RELOC),
- 0, /* leading char */
- '/', /* ar_pad_char */
+ SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_RELOC | SEC_CODE | SEC_DATA,
+ 0, /* leading char */
+ '/', /* ar_pad_char */
15, /* ar_max_namelen */
- /* data */
+ /* data */
bfd_getb64,
bfd_getb_signed_64,
bfd_putb64,
@@ -4069,7 +4098,7 @@ const bfd_target rs6000coff_vec =
bfd_getb_signed_16,
bfd_putb16,
- /* hdrs */
+ /* hdrs */
bfd_getb64,
bfd_getb_signed_64,
bfd_putb64,
@@ -4080,51 +4109,51 @@ const bfd_target rs6000coff_vec =
bfd_getb_signed_16,
bfd_putb16,
- { /* bfd_check_format */
- _bfd_dummy_target,
- coff_object_p,
- _bfd_xcoff_archive_p,
- CORE_FILE_P
- },
+ { /* bfd_check_format */
+ _bfd_dummy_target,
+ coff_object_p,
+ _bfd_xcoff_archive_p,
+ CORE_FILE_P
+ },
- { /* bfd_set_format */
- bfd_false,
- coff_mkobject,
- _bfd_generic_mkarchive,
- bfd_false
- },
+ { /* bfd_set_format */
+ bfd_false,
+ coff_mkobject,
+ _bfd_generic_mkarchive,
+ bfd_false
+ },
- {/* bfd_write_contents */
- bfd_false,
- coff_write_object_contents,
- _bfd_xcoff_write_archive_contents,
- bfd_false
- },
+ {/* bfd_write_contents */
+ bfd_false,
+ coff_write_object_contents,
+ _bfd_xcoff_write_archive_contents,
+ bfd_false
+ },
- /* Generic */
+ /* Generic */
bfd_true,
bfd_true,
coff_new_section_hook,
_bfd_generic_get_section_contents,
- _bfd_generic_get_section_contents_in_window,
+ _bfd_generic_get_section_contents_in_window,
- /* Copy */
+ /* Copy */
_bfd_xcoff_copy_private_bfd_data,
- ((boolean (*) (bfd *, bfd *)) bfd_true),
- ((boolean (*) (bfd *, asection *, bfd *, asection *)) bfd_true),
- ((boolean (*) (bfd *, asymbol *, bfd *, asymbol *)) bfd_true),
- ((boolean (*) (bfd *, flagword)) bfd_true),
- ((boolean (*) (bfd *, void * )) bfd_true),
+ ((bfd_boolean (*) (bfd *, bfd *)) bfd_true),
+ ((bfd_boolean (*) (bfd *, asection *, bfd *, asection *)) bfd_true),
+ ((bfd_boolean (*) (bfd *, asymbol *, bfd *, asymbol *)) bfd_true),
+ ((bfd_boolean (*) (bfd *, flagword)) bfd_true),
+ ((bfd_boolean (*) (bfd *, void * )) bfd_true),
- /* Core */
+ /* Core */
coff_core_file_failing_command,
coff_core_file_failing_signal,
- coff_core_file_matches_executable_p,
+ coff_core_file_matches_executable_p,
- /* Archive */
+ /* Archive */
_bfd_xcoff_slurp_armap,
bfd_false,
- ((boolean (*) (bfd *, char **, bfd_size_type *, const char **)) bfd_false),
+ ((bfd_boolean (*) (bfd *, char **, bfd_size_type *, const char **)) bfd_false),
bfd_dont_truncate_arname,
_bfd_xcoff_write_armap,
_bfd_xcoff_read_ar_hdr,
@@ -4133,9 +4162,9 @@ const bfd_target rs6000coff_vec =
_bfd_xcoff_stat_arch_elt,
bfd_true,
- /* Symbols */
+ /* Symbols */
coff_get_symtab_upper_bound,
- coff_get_symtab,
+ coff_canonicalize_symtab,
coff_make_empty_symbol,
coff_print_symbol,
coff_get_symbol_info,
@@ -4146,18 +4175,18 @@ const bfd_target rs6000coff_vec =
_bfd_generic_read_minisymbols,
_bfd_generic_minisymbol_to_symbol,
- /* Reloc */
+ /* Reloc */
coff_get_reloc_upper_bound,
coff_canonicalize_reloc,
_bfd_xcoff_reloc_type_lookup,
- /* Write */
+ /* Write */
coff_set_arch_mach,
coff_set_section_contents,
- /* Link */
+ /* Link */
_bfd_xcoff_sizeof_headers,
- bfd_generic_get_relocated_section_contents,
+ bfd_generic_get_relocated_section_contents,
bfd_generic_relax_section,
_bfd_xcoff_bfd_link_hash_table_create,
_bfd_generic_link_hash_table_free,
@@ -4169,17 +4198,17 @@ const bfd_target rs6000coff_vec =
bfd_generic_merge_sections,
bfd_generic_discard_group,
- /* Dynamic */
- _bfd_xcoff_get_dynamic_symtab_upper_bound,
+ /* Dynamic */
+ _bfd_xcoff_get_dynamic_symtab_upper_bound,
_bfd_xcoff_canonicalize_dynamic_symtab,
_bfd_xcoff_get_dynamic_reloc_upper_bound,
_bfd_xcoff_canonicalize_dynamic_reloc,
- /* Opposite endian version, none exists */
- NULL,
+ /* Opposite endian version, none exists */
+ NULL,
- (void *) &bfd_xcoff_backend_data,
-};
+ (void *) &bfd_xcoff_backend_data,
+ };
/* xcoff-powermac target
Old target.
@@ -4190,7 +4219,7 @@ const bfd_target rs6000coff_vec =
(because that's how they were bootstrapped originally),
but they are always PowerPC architecture. */
static const struct xcoff_backend_data_rec bfd_pmac_xcoff_backend_data =
-{
+ {
{ /* COFF backend, defined in libcoff.h. */
_bfd_xcoff_swap_aux_in,
_bfd_xcoff_swap_sym_in,
@@ -4210,11 +4239,11 @@ static const struct xcoff_backend_data_rec bfd_pmac_xcoff_backend_data =
RELSZ,
LINESZ,
FILNMLEN,
- true, /* _bfd_coff_long_filenames */
- false, /* _bfd_coff_long_section_names */
+ TRUE, /* _bfd_coff_long_filenames */
+ FALSE, /* _bfd_coff_long_section_names */
3, /* _bfd_coff_default_section_alignment_power */
- false, /* _bfd_coff_force_symnames_in_strings */
- 2, /* _bfd_coff_debug_string_prefix_length */
+ FALSE, /* _bfd_coff_force_symnames_in_strings */
+ 2, /* _bfd_coff_debug_string_prefix_length */
coff_swap_filehdr_in,
coff_swap_aouthdr_in,
coff_swap_scnhdr_in,
@@ -4230,18 +4259,18 @@ static const struct xcoff_backend_data_rec bfd_pmac_xcoff_backend_data =
coff_print_aux,
dummy_reloc16_extra_cases,
dummy_reloc16_estimate,
- NULL, /* bfd_coff_sym_is_global */
- coff_compute_section_file_positions,
- NULL, /* _bfd_coff_start_final_link */
+ NULL, /* bfd_coff_sym_is_global */
+ coff_compute_section_file_positions,
+ NULL, /* _bfd_coff_start_final_link */
xcoff_ppc_relocate_section,
coff_rtype_to_howto,
NULL, /* _bfd_coff_adjust_symndx */
_bfd_generic_link_add_one_symbol,
coff_link_output_has_begun,
coff_final_link_postscript
- },
+ },
- 0x01DF, /* magic number */
+ 0x01DF, /* magic number */
bfd_arch_powerpc,
bfd_mach_ppc,
@@ -4257,11 +4286,11 @@ static const struct xcoff_backend_data_rec bfd_pmac_xcoff_backend_data =
LDHDRSZ,
LDSYMSZ,
LDRELSZ,
- 12, /* _xcoff_function_descriptor_size */
+ 12, /* _xcoff_function_descriptor_size */
SMALL_AOUTSZ,
/* Versions. */
- 1, /* _xcoff_ldhdr_version */
+ 1, /* _xcoff_ldhdr_version */
_bfd_xcoff_put_symbol_name,
_bfd_xcoff_put_ldsymbol_name,
@@ -4269,38 +4298,38 @@ static const struct xcoff_backend_data_rec bfd_pmac_xcoff_backend_data =
xcoff_create_csect_from_smclas,
/* Lineno and reloc count overflow. */
- xcoff_is_lineno_count_overflow,
- xcoff_is_reloc_count_overflow,
+ xcoff_is_lineno_count_overflow,
+ xcoff_is_reloc_count_overflow,
- xcoff_loader_symbol_offset,
- xcoff_loader_reloc_offset,
+ xcoff_loader_symbol_offset,
+ xcoff_loader_reloc_offset,
/* glink. */
- &xcoff_glink_code[0],
+ &xcoff_glink_code[0],
36, /* _xcoff_glink_size */
- /* rtinit */
- 0, /* _xcoff_rtinit_size */
+ /* rtinit */
+ 0, /* _xcoff_rtinit_size */
xcoff_generate_rtinit,
-};
+ };
-/* The transfer vector that leads the outside world to all of the above. */
+/* The transfer vector that leads the outside world to all of the above. */
const bfd_target pmac_xcoff_vec =
-{
- "xcoff-powermac",
- bfd_target_xcoff_flavour,
- BFD_ENDIAN_BIG, /* data byte order is big */
- BFD_ENDIAN_BIG, /* header byte order is big */
+ {
+ "xcoff-powermac",
+ bfd_target_xcoff_flavour,
+ BFD_ENDIAN_BIG, /* data byte order is big */
+ BFD_ENDIAN_BIG, /* header byte order is big */
(HAS_RELOC | EXEC_P | HAS_LINENO | HAS_DEBUG | DYNAMIC
| HAS_SYMS | HAS_LOCALS | WP_TEXT),
- (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_RELOC),
- 0, /* leading char */
- '/', /* ar_pad_char */
+ SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_RELOC | SEC_CODE | SEC_DATA,
+ 0, /* leading char */
+ '/', /* ar_pad_char */
15, /* ar_max_namelen */
- /* data */
+ /* data */
bfd_getb64,
bfd_getb_signed_64,
bfd_putb64,
@@ -4311,7 +4340,7 @@ const bfd_target pmac_xcoff_vec =
bfd_getb_signed_16,
bfd_putb16,
- /* hdrs */
+ /* hdrs */
bfd_getb64,
bfd_getb_signed_64,
bfd_putb64,
@@ -4322,51 +4351,51 @@ const bfd_target pmac_xcoff_vec =
bfd_getb_signed_16,
bfd_putb16,
- { /* bfd_check_format */
- _bfd_dummy_target,
- coff_object_p,
- _bfd_xcoff_archive_p,
- CORE_FILE_P
- },
+ { /* bfd_check_format */
+ _bfd_dummy_target,
+ coff_object_p,
+ _bfd_xcoff_archive_p,
+ CORE_FILE_P
+ },
- { /* bfd_set_format */
- bfd_false,
- coff_mkobject,
- _bfd_generic_mkarchive,
- bfd_false
- },
+ { /* bfd_set_format */
+ bfd_false,
+ coff_mkobject,
+ _bfd_generic_mkarchive,
+ bfd_false
+ },
- {/* bfd_write_contents */
- bfd_false,
- coff_write_object_contents,
- _bfd_xcoff_write_archive_contents,
- bfd_false
- },
+ {/* bfd_write_contents */
+ bfd_false,
+ coff_write_object_contents,
+ _bfd_xcoff_write_archive_contents,
+ bfd_false
+ },
- /* Generic */
+ /* Generic */
bfd_true,
bfd_true,
coff_new_section_hook,
_bfd_generic_get_section_contents,
- _bfd_generic_get_section_contents_in_window,
+ _bfd_generic_get_section_contents_in_window,
- /* Copy */
+ /* Copy */
_bfd_xcoff_copy_private_bfd_data,
- ((boolean (*) (bfd *, bfd *)) bfd_true),
- ((boolean (*) (bfd *, asection *, bfd *, asection *)) bfd_true),
- ((boolean (*) (bfd *, asymbol *, bfd *, asymbol *)) bfd_true),
- ((boolean (*) (bfd *, flagword)) bfd_true),
- ((boolean (*) (bfd *, void * )) bfd_true),
+ ((bfd_boolean (*) (bfd *, bfd *)) bfd_true),
+ ((bfd_boolean (*) (bfd *, asection *, bfd *, asection *)) bfd_true),
+ ((bfd_boolean (*) (bfd *, asymbol *, bfd *, asymbol *)) bfd_true),
+ ((bfd_boolean (*) (bfd *, flagword)) bfd_true),
+ ((bfd_boolean (*) (bfd *, void * )) bfd_true),
- /* Core */
+ /* Core */
coff_core_file_failing_command,
coff_core_file_failing_signal,
- coff_core_file_matches_executable_p,
+ coff_core_file_matches_executable_p,
- /* Archive */
+ /* Archive */
_bfd_xcoff_slurp_armap,
bfd_false,
- ((boolean (*) (bfd *, char **, bfd_size_type *, const char **)) bfd_false),
+ ((bfd_boolean (*) (bfd *, char **, bfd_size_type *, const char **)) bfd_false),
bfd_dont_truncate_arname,
_bfd_xcoff_write_armap,
_bfd_xcoff_read_ar_hdr,
@@ -4375,9 +4404,9 @@ const bfd_target pmac_xcoff_vec =
_bfd_xcoff_stat_arch_elt,
bfd_true,
- /* Symbols */
+ /* Symbols */
coff_get_symtab_upper_bound,
- coff_get_symtab,
+ coff_canonicalize_symtab,
coff_make_empty_symbol,
coff_print_symbol,
coff_get_symbol_info,
@@ -4388,18 +4417,18 @@ const bfd_target pmac_xcoff_vec =
_bfd_generic_read_minisymbols,
_bfd_generic_minisymbol_to_symbol,
- /* Reloc */
+ /* Reloc */
coff_get_reloc_upper_bound,
coff_canonicalize_reloc,
_bfd_xcoff_reloc_type_lookup,
- /* Write */
+ /* Write */
coff_set_arch_mach,
coff_set_section_contents,
- /* Link */
+ /* Link */
_bfd_xcoff_sizeof_headers,
- bfd_generic_get_relocated_section_contents,
+ bfd_generic_get_relocated_section_contents,
bfd_generic_relax_section,
_bfd_xcoff_bfd_link_hash_table_create,
_bfd_generic_link_hash_table_free,
@@ -4411,14 +4440,14 @@ const bfd_target pmac_xcoff_vec =
bfd_generic_merge_sections,
bfd_generic_discard_group,
- /* Dynamic */
- _bfd_xcoff_get_dynamic_symtab_upper_bound,
+ /* Dynamic */
+ _bfd_xcoff_get_dynamic_symtab_upper_bound,
_bfd_xcoff_canonicalize_dynamic_symtab,
_bfd_xcoff_get_dynamic_reloc_upper_bound,
_bfd_xcoff_canonicalize_dynamic_reloc,
- /* Opposite endian version, none exists */
- NULL,
+ /* Opposite endian version, none exists */
+ NULL,
- (void *) &bfd_pmac_xcoff_backend_data,
-};
+ (void *) &bfd_pmac_xcoff_backend_data,
+ };
diff --git a/contrib/binutils/bfd/coff-sparc.c b/contrib/binutils/bfd/coff-sparc.c
index 35c23df..372b1a7 100644
--- a/contrib/binutils/bfd/coff-sparc.c
+++ b/contrib/binutils/bfd/coff-sparc.c
@@ -1,6 +1,6 @@
/* BFD back-end for Sparc COFF files.
- Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1999, 2000, 2001
- Free Software Foundation, Inc.
+ Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1999, 2000, 2001,
+ 2002, 2003 Free Software Foundation, Inc.
Written by Cygnus Support.
This file is part of BFD, the Binary File Descriptor library.
@@ -103,30 +103,30 @@ bfd_coff_generic_reloc (abfd, reloc_entry, symbol, data, input_section,
static reloc_howto_type coff_sparc_howto_table[] =
{
- HOWTO(R_SPARC_NONE, 0,0, 0,false,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_NONE", false,0,0x00000000,true),
- HOWTO(R_SPARC_8, 0,0, 8,false,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_8", false,0,0x000000ff,true),
- HOWTO(R_SPARC_16, 0,1,16,false,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_16", false,0,0x0000ffff,true),
- HOWTO(R_SPARC_32, 0,2,32,false,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_32", false,0,0xffffffff,true),
- HOWTO(R_SPARC_DISP8, 0,0, 8,true, 0,complain_overflow_signed, bfd_coff_generic_reloc,"R_SPARC_DISP8", false,0,0x000000ff,true),
- HOWTO(R_SPARC_DISP16, 0,1,16,true, 0,complain_overflow_signed, bfd_coff_generic_reloc,"R_SPARC_DISP16", false,0,0x0000ffff,true),
- HOWTO(R_SPARC_DISP32, 0,2,32,true, 0,complain_overflow_signed, bfd_coff_generic_reloc,"R_SPARC_DISP32", false,0,0x00ffffff,true),
- HOWTO(R_SPARC_WDISP30, 2,2,30,true, 0,complain_overflow_signed, bfd_coff_generic_reloc,"R_SPARC_WDISP30", false,0,0x3fffffff,true),
- HOWTO(R_SPARC_WDISP22, 2,2,22,true, 0,complain_overflow_signed, bfd_coff_generic_reloc,"R_SPARC_WDISP22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_HI22, 10,2,22,false,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_HI22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_22, 0,2,22,false,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_13, 0,2,13,false,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_13", false,0,0x00001fff,true),
- HOWTO(R_SPARC_LO10, 0,2,10,false,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_LO10", false,0,0x000003ff,true),
- HOWTO(R_SPARC_GOT10, 0,2,10,false,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_GOT10", false,0,0x000003ff,true),
- HOWTO(R_SPARC_GOT13, 0,2,13,false,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_GOT13", false,0,0x00001fff,true),
- HOWTO(R_SPARC_GOT22, 10,2,22,false,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_GOT22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_PC10, 0,2,10,false,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_PC10", false,0,0x000003ff,true),
- HOWTO(R_SPARC_PC22, 0,2,22,false,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_PC22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_WPLT30, 0,0,00,false,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_WPLT30", false,0,0x00000000,true),
- HOWTO(R_SPARC_COPY, 0,0,00,false,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_COPY", false,0,0x00000000,true),
- HOWTO(R_SPARC_GLOB_DAT,0,0,00,false,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_GLOB_DAT",false,0,0x00000000,true),
- HOWTO(R_SPARC_JMP_SLOT,0,0,00,false,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_JMP_SLOT",false,0,0x00000000,true),
- HOWTO(R_SPARC_RELATIVE,0,0,00,false,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_RELATIVE",false,0,0x00000000,true),
- HOWTO(R_SPARC_UA32, 0,0,00,false,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_UA32", false,0,0x00000000,true),
+ HOWTO(R_SPARC_NONE, 0,0, 0,FALSE,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_NONE", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_8, 0,0, 8,FALSE,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_8", FALSE,0,0x000000ff,TRUE),
+ HOWTO(R_SPARC_16, 0,1,16,FALSE,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_16", FALSE,0,0x0000ffff,TRUE),
+ HOWTO(R_SPARC_32, 0,2,32,FALSE,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_32", FALSE,0,0xffffffff,TRUE),
+ HOWTO(R_SPARC_DISP8, 0,0, 8,TRUE, 0,complain_overflow_signed, bfd_coff_generic_reloc,"R_SPARC_DISP8", FALSE,0,0x000000ff,TRUE),
+ HOWTO(R_SPARC_DISP16, 0,1,16,TRUE, 0,complain_overflow_signed, bfd_coff_generic_reloc,"R_SPARC_DISP16", FALSE,0,0x0000ffff,TRUE),
+ HOWTO(R_SPARC_DISP32, 0,2,32,TRUE, 0,complain_overflow_signed, bfd_coff_generic_reloc,"R_SPARC_DISP32", FALSE,0,0x00ffffff,TRUE),
+ HOWTO(R_SPARC_WDISP30, 2,2,30,TRUE, 0,complain_overflow_signed, bfd_coff_generic_reloc,"R_SPARC_WDISP30", FALSE,0,0x3fffffff,TRUE),
+ HOWTO(R_SPARC_WDISP22, 2,2,22,TRUE, 0,complain_overflow_signed, bfd_coff_generic_reloc,"R_SPARC_WDISP22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_HI22, 10,2,22,FALSE,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_HI22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_22, 0,2,22,FALSE,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_13, 0,2,13,FALSE,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_13", FALSE,0,0x00001fff,TRUE),
+ HOWTO(R_SPARC_LO10, 0,2,10,FALSE,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_LO10", FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_GOT10, 0,2,10,FALSE,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_GOT10", FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_GOT13, 0,2,13,FALSE,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_GOT13", FALSE,0,0x00001fff,TRUE),
+ HOWTO(R_SPARC_GOT22, 10,2,22,FALSE,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_GOT22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_PC10, 0,2,10,FALSE,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_PC10", FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_PC22, 0,2,22,FALSE,0,complain_overflow_bitfield,bfd_coff_generic_reloc,"R_SPARC_PC22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_WPLT30, 0,0,00,FALSE,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_WPLT30", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_COPY, 0,0,00,FALSE,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_COPY", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_GLOB_DAT,0,0,00,FALSE,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_GLOB_DAT",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_JMP_SLOT,0,0,00,FALSE,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_JMP_SLOT",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_RELATIVE,0,0,00,FALSE,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_RELATIVE",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_UA32, 0,0,00,FALSE,0,complain_overflow_dont, bfd_coff_generic_reloc,"R_SPARC_UA32", FALSE,0,0x00000000,TRUE),
};
struct coff_reloc_map {
@@ -216,4 +216,4 @@ rtype2howto (cache_ptr, dst)
#define TARGET_NAME "coff-sparc"
#endif
-CREATE_BIG_COFF_TARGET_VEC (TARGET_SYM, TARGET_NAME, D_PAGED, 0, '_', NULL)
+CREATE_BIG_COFF_TARGET_VEC (TARGET_SYM, TARGET_NAME, D_PAGED, 0, '_', NULL, COFF_SWAP_TABLE)
diff --git a/contrib/binutils/bfd/coff64-rs6000.c b/contrib/binutils/bfd/coff64-rs6000.c
index 9372f6b..ec9c695 100644
--- a/contrib/binutils/bfd/coff64-rs6000.c
+++ b/contrib/binutils/bfd/coff64-rs6000.c
@@ -1,5 +1,5 @@
/* BFD back-end for IBM RS/6000 "XCOFF64" files.
- Copyright 2000, 2001, 2002
+ Copyright 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written Clinton Popetz.
Contributed by Cygnus Support.
@@ -82,39 +82,56 @@
#define coff_SWAP_lineno_in _bfd_xcoff64_swap_lineno_in
#define coff_SWAP_lineno_out _bfd_xcoff64_swap_lineno_out
-static void _bfd_xcoff64_swap_lineno_in PARAMS ((bfd *, PTR, PTR));
-static unsigned int _bfd_xcoff64_swap_lineno_out PARAMS ((bfd *, PTR, PTR));
-static boolean _bfd_xcoff64_put_symbol_name
+static void _bfd_xcoff64_swap_lineno_in
+ PARAMS ((bfd *, PTR, PTR));
+static unsigned int _bfd_xcoff64_swap_lineno_out
+ PARAMS ((bfd *, PTR, PTR));
+static bfd_boolean _bfd_xcoff64_put_symbol_name
PARAMS ((bfd *, struct bfd_strtab_hash *, struct internal_syment *,
const char *));
-static boolean _bfd_xcoff64_put_ldsymbol_name
+static bfd_boolean _bfd_xcoff64_put_ldsymbol_name
PARAMS ((bfd *, struct xcoff_loader_info *, struct internal_ldsym *,
const char *));
-static void _bfd_xcoff64_swap_sym_in PARAMS ((bfd *, PTR, PTR));
-static unsigned int _bfd_xcoff64_swap_sym_out PARAMS ((bfd *, PTR, PTR));
+static void _bfd_xcoff64_swap_sym_in
+ PARAMS ((bfd *, PTR, PTR));
+static unsigned int _bfd_xcoff64_swap_sym_out
+ PARAMS ((bfd *, PTR, PTR));
static void _bfd_xcoff64_swap_aux_in
PARAMS ((bfd *, PTR, int, int, int, int, PTR));
static unsigned int _bfd_xcoff64_swap_aux_out
PARAMS ((bfd *, PTR, int, int, int, int, PTR));
-static void xcoff64_swap_reloc_in PARAMS ((bfd *, PTR, PTR));
-static unsigned int xcoff64_swap_reloc_out PARAMS ((bfd *, PTR, PTR));
-extern boolean _bfd_xcoff_mkobject PARAMS ((bfd *));
-extern boolean _bfd_xcoff_copy_private_bfd_data PARAMS ((bfd *, bfd *));
-extern boolean _bfd_xcoff_is_local_label_name PARAMS ((bfd *, const char *));
+static void xcoff64_swap_reloc_in
+ PARAMS ((bfd *, PTR, PTR));
+static unsigned int xcoff64_swap_reloc_out
+ PARAMS ((bfd *, PTR, PTR));
+extern bfd_boolean _bfd_xcoff_mkobject
+ PARAMS ((bfd *));
+extern bfd_boolean _bfd_xcoff_copy_private_bfd_data
+ PARAMS ((bfd *, bfd *));
+extern bfd_boolean _bfd_xcoff_is_local_label_name
+ PARAMS ((bfd *, const char *));
extern void xcoff64_rtype2howto
PARAMS ((arelent *, struct internal_reloc *));
extern reloc_howto_type * xcoff64_reloc_type_lookup
PARAMS ((bfd *, bfd_reloc_code_real_type));
-extern boolean _bfd_xcoff_slurp_armap PARAMS ((bfd *));
-extern PTR _bfd_xcoff_read_ar_hdr PARAMS ((bfd *));
-extern bfd *_bfd_xcoff_openr_next_archived_file PARAMS ((bfd *, bfd *));
-extern int _bfd_xcoff_stat_arch_elt PARAMS ((bfd *, struct stat *));
-extern boolean _bfd_xcoff_write_armap
+extern bfd_boolean _bfd_xcoff_slurp_armap
+ PARAMS ((bfd *));
+extern PTR _bfd_xcoff_read_ar_hdr
+ PARAMS ((bfd *));
+extern bfd *_bfd_xcoff_openr_next_archived_file
+ PARAMS ((bfd *, bfd *));
+extern int _bfd_xcoff_stat_arch_elt
+ PARAMS ((bfd *, struct stat *));
+extern bfd_boolean _bfd_xcoff_write_armap
PARAMS ((bfd *, unsigned int, struct orl *, unsigned int, int));
-extern boolean _bfd_xcoff_write_archive_contents PARAMS ((bfd *));
-extern int _bfd_xcoff_sizeof_headers PARAMS ((bfd *, boolean));
-extern void _bfd_xcoff_swap_sym_in PARAMS ((bfd *, PTR, PTR));
-extern unsigned int _bfd_xcoff_swap_sym_out PARAMS ((bfd *, PTR, PTR));
+extern bfd_boolean _bfd_xcoff_write_archive_contents
+ PARAMS ((bfd *));
+extern int _bfd_xcoff_sizeof_headers
+ PARAMS ((bfd *, bfd_boolean));
+extern void _bfd_xcoff_swap_sym_in
+ PARAMS ((bfd *, PTR, PTR));
+extern unsigned int _bfd_xcoff_swap_sym_out
+ PARAMS ((bfd *, PTR, PTR));
extern void _bfd_xcoff_swap_aux_in
PARAMS ((bfd *, PTR, int, int, int, int, PTR));
extern unsigned int _bfd_xcoff_swap_aux_out
@@ -131,61 +148,70 @@ static void xcoff64_swap_ldrel_in
PARAMS ((bfd *, const PTR, struct internal_ldrel *));
static void xcoff64_swap_ldrel_out
PARAMS ((bfd *, const struct internal_ldrel *, PTR d));
-static boolean xcoff64_write_object_contents PARAMS ((bfd *));
-static boolean xcoff64_ppc_relocate_section
+static bfd_boolean xcoff64_write_object_contents
+ PARAMS ((bfd *));
+static bfd_boolean xcoff64_ppc_relocate_section
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
struct internal_reloc *, struct internal_syment *,
asection **));
-static boolean xcoff64_slurp_armap PARAMS ((bfd *));
-static const bfd_target *xcoff64_archive_p PARAMS ((bfd *));
-static bfd *xcoff64_openr_next_archived_file PARAMS ((bfd *, bfd *));
-static int xcoff64_sizeof_headers PARAMS ((bfd *, boolean));
+static bfd_boolean xcoff64_slurp_armap
+ PARAMS ((bfd *));
+static const bfd_target *xcoff64_archive_p
+ PARAMS ((bfd *));
+static bfd *xcoff64_openr_next_archived_file
+ PARAMS ((bfd *, bfd *));
+static int xcoff64_sizeof_headers
+ PARAMS ((bfd *, bfd_boolean));
static asection *xcoff64_create_csect_from_smclas
PARAMS ((bfd *, union internal_auxent *, const char *));
-static boolean xcoff64_is_lineno_count_overflow PARAMS ((bfd *, bfd_vma));
-static boolean xcoff64_is_reloc_count_overflow PARAMS ((bfd *, bfd_vma));
+static bfd_boolean xcoff64_is_lineno_count_overflow
+ PARAMS ((bfd *, bfd_vma));
+static bfd_boolean xcoff64_is_reloc_count_overflow
+ PARAMS ((bfd *, bfd_vma));
static bfd_vma xcoff64_loader_symbol_offset
PARAMS ((bfd *, struct internal_ldhdr *));
static bfd_vma xcoff64_loader_reloc_offset
PARAMS ((bfd *, struct internal_ldhdr *));
-static boolean xcoff64_generate_rtinit
- PARAMS ((bfd *, const char *, const char *, boolean));
-static boolean xcoff64_bad_format_hook PARAMS ((bfd *, PTR ));
+static bfd_boolean xcoff64_generate_rtinit
+ PARAMS ((bfd *, const char *, const char *, bfd_boolean));
+static bfd_boolean xcoff64_bad_format_hook
+ PARAMS ((bfd *, PTR ));
/* Relocation functions */
-static boolean xcoff64_reloc_type_br PARAMS ((XCOFF_RELOC_FUNCTION_ARGS));
+static bfd_boolean xcoff64_reloc_type_br
+ PARAMS ((XCOFF_RELOC_FUNCTION_ARGS));
-boolean (*xcoff64_calculate_relocation[XCOFF_MAX_CALCULATE_RELOCATION])
+bfd_boolean (*xcoff64_calculate_relocation[XCOFF_MAX_CALCULATE_RELOCATION])
PARAMS ((XCOFF_RELOC_FUNCTION_ARGS)) =
{
- xcoff_reloc_type_pos, /* R_POS (0x00) */
- xcoff_reloc_type_neg, /* R_NEG (0x01) */
- xcoff_reloc_type_rel, /* R_REL (0x02) */
- xcoff_reloc_type_toc, /* R_TOC (0x03) */
+ xcoff_reloc_type_pos, /* R_POS (0x00) */
+ xcoff_reloc_type_neg, /* R_NEG (0x01) */
+ xcoff_reloc_type_rel, /* R_REL (0x02) */
+ xcoff_reloc_type_toc, /* R_TOC (0x03) */
xcoff_reloc_type_fail, /* R_RTB (0x04) */
- xcoff_reloc_type_toc, /* R_GL (0x05) */
- xcoff_reloc_type_toc, /* R_TCL (0x06) */
- xcoff_reloc_type_fail, /* (0x07) */
- xcoff_reloc_type_ba, /* R_BA (0x08) */
- xcoff_reloc_type_fail, /* (0x09) */
+ xcoff_reloc_type_toc, /* R_GL (0x05) */
+ xcoff_reloc_type_toc, /* R_TCL (0x06) */
+ xcoff_reloc_type_fail, /* (0x07) */
+ xcoff_reloc_type_ba, /* R_BA (0x08) */
+ xcoff_reloc_type_fail, /* (0x09) */
xcoff64_reloc_type_br, /* R_BR (0x0a) */
- xcoff_reloc_type_fail, /* (0x0b) */
- xcoff_reloc_type_pos, /* R_RL (0x0c) */
- xcoff_reloc_type_pos, /* R_RLA (0x0d) */
- xcoff_reloc_type_fail, /* (0x0e) */
+ xcoff_reloc_type_fail, /* (0x0b) */
+ xcoff_reloc_type_pos, /* R_RL (0x0c) */
+ xcoff_reloc_type_pos, /* R_RLA (0x0d) */
+ xcoff_reloc_type_fail, /* (0x0e) */
xcoff_reloc_type_noop, /* R_REF (0x0f) */
- xcoff_reloc_type_fail, /* (0x10) */
- xcoff_reloc_type_fail, /* (0x11) */
- xcoff_reloc_type_toc, /* R_TRL (0x12) */
- xcoff_reloc_type_toc, /* R_TRLA (0x13) */
+ xcoff_reloc_type_fail, /* (0x10) */
+ xcoff_reloc_type_fail, /* (0x11) */
+ xcoff_reloc_type_toc, /* R_TRL (0x12) */
+ xcoff_reloc_type_toc, /* R_TRLA (0x13) */
xcoff_reloc_type_fail, /* R_RRTBI (0x14) */
xcoff_reloc_type_fail, /* R_RRTBA (0x15) */
- xcoff_reloc_type_ba, /* R_CAI (0x16) */
+ xcoff_reloc_type_ba, /* R_CAI (0x16) */
xcoff_reloc_type_crel, /* R_CREL (0x17) */
- xcoff_reloc_type_ba, /* R_RBA (0x18) */
- xcoff_reloc_type_ba, /* R_RBAC (0x19) */
+ xcoff_reloc_type_ba, /* R_RBA (0x18) */
+ xcoff_reloc_type_ba, /* R_RBAC (0x19) */
xcoff64_reloc_type_br, /* R_RBR (0x1a) */
- xcoff_reloc_type_ba, /* R_RBRC (0x1b) */
+ xcoff_reloc_type_ba, /* R_RBRC (0x1b) */
};
/* coffcode.h needs these to be defined. */
@@ -212,11 +238,14 @@ boolean (*xcoff64_calculate_relocation[XCOFF_MAX_CALCULATE_RELOCATION])
#define coff_bfd_is_local_label_name _bfd_xcoff_is_local_label_name
#define coff_bfd_reloc_type_lookup xcoff64_reloc_type_lookup
#ifdef AIX_CORE
-extern const bfd_target * rs6000coff_core_p PARAMS ((bfd *abfd));
-extern boolean rs6000coff_core_file_matches_executable_p
- PARAMS((bfd *cbfd, bfd *ebfd));
-extern char *rs6000coff_core_file_failing_command PARAMS ((bfd *abfd));
-extern int rs6000coff_core_file_failing_signal PARAMS ((bfd *abfd));
+extern const bfd_target * rs6000coff_core_p
+ PARAMS ((bfd *abfd));
+extern bfd_boolean rs6000coff_core_file_matches_executable_p
+ PARAMS ((bfd *cbfd, bfd *ebfd));
+extern char *rs6000coff_core_file_failing_command
+ PARAMS ((bfd *abfd));
+extern int rs6000coff_core_file_failing_signal
+ PARAMS ((bfd *abfd));
#define CORE_FILE_P rs6000coff_core_p
#define coff_core_file_failing_command \
rs6000coff_core_file_failing_command
@@ -496,33 +525,33 @@ _bfd_xcoff64_swap_aux_out (abfd, inp, type, class, indx, numaux, extp)
return bfd_coff_auxesz (abfd);
}
-static boolean
+static bfd_boolean
_bfd_xcoff64_put_symbol_name (abfd, strtab, sym, name)
bfd *abfd;
struct bfd_strtab_hash *strtab;
struct internal_syment *sym;
const char *name;
{
- boolean hash;
+ bfd_boolean hash;
bfd_size_type indx;
- hash = true;
+ hash = TRUE;
if ((abfd->flags & BFD_TRADITIONAL_FORMAT) != 0)
- hash = false;
+ hash = FALSE;
- indx = _bfd_stringtab_add (strtab, name, hash, false);
+ indx = _bfd_stringtab_add (strtab, name, hash, FALSE);
if (indx == (bfd_size_type) -1)
- return false;
+ return FALSE;
sym->_n._n_n._n_zeroes = 0;
sym->_n._n_n._n_offset = STRING_SIZE_SIZE + indx;
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
_bfd_xcoff64_put_ldsymbol_name (abfd, ldinfo, ldsym, name)
bfd *abfd ATTRIBUTE_UNUSED;
struct xcoff_loader_info *ldinfo;
@@ -547,8 +576,8 @@ _bfd_xcoff64_put_ldsymbol_name (abfd, ldinfo, ldsym, name)
bfd_realloc ((PTR) ldinfo->strings, newalc));
if (newstrings == NULL)
{
- ldinfo->failed = true;
- return false;
+ ldinfo->failed = TRUE;
+ return FALSE;
}
ldinfo->string_alc = newalc;
ldinfo->strings = newstrings;
@@ -561,7 +590,7 @@ _bfd_xcoff64_put_ldsymbol_name (abfd, ldinfo, ldsym, name)
ldsym->_l._l_l._l_offset = ldinfo->string_size + 2;
ldinfo->string_size += len + 3;
- return true;
+ return TRUE;
}
/* Routines to swap information in the XCOFF .loader section. If we
@@ -720,20 +749,20 @@ xcoff64_swap_ldrel_out (abfd, src, d)
bfd_put_32 (abfd, src->l_symndx, dst->l_symndx);
}
-static boolean
+static bfd_boolean
xcoff64_write_object_contents (abfd)
- bfd * abfd;
+ bfd *abfd;
{
asection *current;
- boolean hasrelocs = false;
- boolean haslinno = false;
+ bfd_boolean hasrelocs = FALSE;
+ bfd_boolean haslinno = FALSE;
file_ptr scn_base;
file_ptr reloc_base;
file_ptr lineno_base;
file_ptr sym_base;
unsigned long reloc_size = 0;
unsigned long lnno_size = 0;
- boolean long_section_names;
+ bfd_boolean long_section_names;
asection *text_sec = ((void *) 0);
asection *data_sec = ((void *) 0);
asection *bss_sec = ((void *) 0);
@@ -745,7 +774,7 @@ xcoff64_write_object_contents (abfd)
if (! abfd->output_has_begun)
{
if (! bfd_coff_compute_section_file_positions (abfd))
- return false;
+ return FALSE;
}
/* Work out the size of the reloc and linno areas. */
@@ -801,9 +830,9 @@ xcoff64_write_object_contents (abfd)
internal_f.f_nscns = 0;
if (bfd_seek (abfd, scn_base, SEEK_SET) != 0)
- return false;
+ return FALSE;
- long_section_names = false;
+ long_section_names = FALSE;
for (current = abfd->sections; current != NULL; current = current->next)
{
struct internal_scnhdr section;
@@ -836,9 +865,9 @@ xcoff64_write_object_contents (abfd)
section.s_nlnno = current->lineno_count;
if (current->reloc_count != 0)
- hasrelocs = true;
+ hasrelocs = TRUE;
if (current->lineno_count != 0)
- haslinno = true;
+ haslinno = TRUE;
section.s_flags = sec_to_styp_flags (current->name, current->flags);
@@ -858,7 +887,7 @@ xcoff64_write_object_contents (abfd)
amount = bfd_coff_scnhsz (abfd);
if (bfd_coff_swap_scnhdr_out (abfd, &section, &buff) == 0
|| bfd_bwrite ((PTR) (&buff), amount, abfd) != amount)
- return false;
+ return FALSE;
}
internal_f.f_timdat = 0;
@@ -909,14 +938,14 @@ xcoff64_write_object_contents (abfd)
int firstundef;
if (!coff_renumber_symbols (abfd, &firstundef))
- return false;
+ return FALSE;
coff_mangle_symbols (abfd);
if (! coff_write_symbols (abfd))
- return false;
+ return FALSE;
if (! coff_write_linenumbers (abfd))
- return false;
+ return FALSE;
if (! coff_write_relocs (abfd, firstundef))
- return false;
+ return FALSE;
internal_f.f_symptr = sym_base;
internal_f.f_nsyms = bfd_get_symcount (abfd);
@@ -1014,7 +1043,7 @@ xcoff64_write_object_contents (abfd)
internal_a.o_cputype = 4;
break;
case bfd_arch_powerpc:
- if (bfd_get_mach (abfd) == 0)
+ if (bfd_get_mach (abfd) == bfd_mach_ppc)
internal_a.o_cputype = 3;
else
internal_a.o_cputype = 1;
@@ -1028,7 +1057,7 @@ xcoff64_write_object_contents (abfd)
}
if (bfd_seek (abfd, (file_ptr) 0, 0) != 0)
- return false;
+ return FALSE;
{
char * buff;
@@ -1036,7 +1065,7 @@ xcoff64_write_object_contents (abfd)
buff = bfd_malloc (amount);
if (buff == NULL)
- return false;
+ return FALSE;
bfd_coff_swap_filehdr_out (abfd, (PTR) &internal_f, (PTR) buff);
amount = bfd_bwrite ((PTR) buff, amount, abfd);
@@ -1044,7 +1073,7 @@ xcoff64_write_object_contents (abfd)
free (buff);
if (amount != bfd_coff_filhsz (abfd))
- return false;
+ return FALSE;
}
if (abfd->flags & EXEC_P)
@@ -1054,22 +1083,22 @@ xcoff64_write_object_contents (abfd)
buff = bfd_malloc (amount);
if (buff == NULL)
- return false;
+ return FALSE;
- bfd_coff_swap_aouthdr_out (abfd, (PTR) & internal_a, (PTR) buff);
+ bfd_coff_swap_aouthdr_out (abfd, (PTR) &internal_a, (PTR) buff);
amount = bfd_bwrite ((PTR) buff, amount, abfd);
free (buff);
if (amount != bfd_coff_aoutsz (abfd))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
-static boolean
-xcoff64_reloc_type_br (input_bfd, input_section, output_bfd, rel, sym, howto,
+static bfd_boolean
+xcoff64_reloc_type_br (input_bfd, input_section, output_bfd, rel, sym, howto,
val, addend, relocation, contents)
bfd *input_bfd;
asection *input_section;
@@ -1084,8 +1113,8 @@ xcoff64_reloc_type_br (input_bfd, input_section, output_bfd, rel, sym, howto,
{
struct xcoff_link_hash_entry *h;
- if (0 > rel->r_symndx)
- return false;
+ if (0 > rel->r_symndx)
+ return FALSE;
h = obj_xcoff_sym_hashes (input_bfd)[rel->r_symndx];
@@ -1096,60 +1125,60 @@ xcoff64_reloc_type_br (input_bfd, input_section, output_bfd, rel, sym, howto,
call is followed by a ld r2,40(r1), but the call is not
going to global linkage code, we can replace the load with a
cror. */
- if (NULL != h
- && bfd_link_hash_defined == h->root.type
+ if (NULL != h
+ && bfd_link_hash_defined == h->root.type
&& (rel->r_vaddr - input_section->vma + 8
<= input_section->_cooked_size))
{
bfd_byte *pnext;
unsigned long next;
-
+
pnext = contents + (rel->r_vaddr - input_section->vma) + 4;
next = bfd_get_32 (input_bfd, pnext);
-
- /* The _ptrgl function is magic. It is used by the AIX compiler to call
+
+ /* The _ptrgl function is magic. It is used by the AIX compiler to call
a function through a pointer. */
- if (h->smclas == XMC_GL || strcmp (h->root.root.string, "._ptrgl") == 0)
+ if (h->smclas == XMC_GL || strcmp (h->root.root.string, "._ptrgl") == 0)
{
- if (next == 0x4def7b82 /* cror 15,15,15 */
- || next == 0x4ffffb82 /* cror 31,31,31 */
- || next == 0x60000000) /* ori r0,r0,0 */
- bfd_put_32 (input_bfd, 0xe8410028, pnext); /* ld r2,40(r1) */
- }
- else
+ if (next == 0x4def7b82 /* cror 15,15,15 */
+ || next == 0x4ffffb82 /* cror 31,31,31 */
+ || next == 0x60000000) /* ori r0,r0,0 */
+ bfd_put_32 (input_bfd, 0xe8410028, pnext); /* ld r2,40(r1) */
+ }
+ else
{
- if (next == 0xe8410028) /* ld r2,40(r1) */
- bfd_put_32 (input_bfd, 0x60000000, pnext); /* ori r0,r0,0 */
+ if (next == 0xe8410028) /* ld r2,40(r1) */
+ bfd_put_32 (input_bfd, 0x60000000, pnext); /* ori r0,r0,0 */
}
- }
- else if (NULL != h && bfd_link_hash_undefined == h->root.type)
+ }
+ else if (NULL != h && bfd_link_hash_undefined == h->root.type)
{
/* Normally, this relocation is against a defined symbol. In the
case where this is a partial link and the output section offset
- is greater than 2^25, the linker will return an invalid error
+ is greater than 2^25, the linker will return an invalid error
message that the relocation has been truncated. Yes it has been
- truncated but no it not important. For this case, disable the
+ truncated but no it not important. For this case, disable the
overflow checking. */
howto->complain_on_overflow = complain_overflow_dont;
}
-
- howto->pc_relative = true;
+
+ howto->pc_relative = TRUE;
howto->src_mask &= ~3;
howto->dst_mask = howto->src_mask;
-
+
/* A PC relative reloc includes the section address. */
addend += input_section->vma;
-
+
*relocation = val + addend;
*relocation -= (input_section->output_section->vma
+ input_section->output_offset);
- return true;
+ return TRUE;
}
/* This is the relocation function for the PowerPC64.
See xcoff_ppc_relocation_section for more information. */
-boolean
+bfd_boolean
xcoff64_ppc_relocate_section (output_bfd, info, input_bfd,
input_section, contents, relocs, syms,
sections)
@@ -1181,8 +1210,8 @@ xcoff64_ppc_relocate_section (output_bfd, info, input_bfd,
bfd_byte *location;
/* Relocation type R_REF is a special relocation type which is
- merely used to prevent garbage collection from occurring for
- the csect including the symbol which it references. */
+ merely used to prevent garbage collection from occurring for
+ the csect including the symbol which it references. */
if (rel->r_type == R_REF)
continue;
@@ -1191,33 +1220,33 @@ xcoff64_ppc_relocate_section (output_bfd, info, input_bfd,
howto.rightshift = 0;
howto.bitsize = (rel->r_size & 0x3f) + 1;
howto.size = howto.bitsize > 16 ? (howto.bitsize > 32 ? 4 : 2) : 1;
- howto.pc_relative = false;
+ howto.pc_relative = FALSE;
howto.bitpos = 0;
howto.complain_on_overflow = (rel->r_size & 0x80
? complain_overflow_signed
: complain_overflow_bitfield);
howto.special_function = NULL;
howto.name = "internal";
- howto.partial_inplace = true;
- howto.src_mask = howto.dst_mask = N_ONES(howto.bitsize);
- howto.pcrel_offset = false;
+ howto.partial_inplace = TRUE;
+ howto.src_mask = howto.dst_mask = N_ONES (howto.bitsize);
+ howto.pcrel_offset = FALSE;
/* symbol */
val = 0;
addend = 0;
h = NULL;
sym = NULL;
- symndx = rel->r_symndx;
+ symndx = rel->r_symndx;
- if (-1 != symndx)
+ if (-1 != symndx)
{
asection *sec;
-
+
h = obj_xcoff_sym_hashes (input_bfd)[symndx];
sym = syms + symndx;
addend = - sym->n_value;
-
- if (NULL == h)
+
+ if (NULL == h)
{
sec = sections[symndx];
/* Hack to make sure we use the right TOC anchor value
@@ -1230,104 +1259,104 @@ xcoff64_ppc_relocate_section (output_bfd, info, input_bfd,
+ sec->output_offset
+ sym->n_value
- sec->vma);
- }
- else
+ }
+ else
{
- if (h->root.type == bfd_link_hash_defined
- || h->root.type == bfd_link_hash_defweak)
+ if (h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak)
{
sec = h->root.u.def.section;
val = (h->root.u.def.value
+ sec->output_section->vma
+ sec->output_offset);
- }
- else if (h->root.type == bfd_link_hash_common)
+ }
+ else if (h->root.type == bfd_link_hash_common)
{
sec = h->root.u.c.p->section;
val = (sec->output_section->vma
+ sec->output_offset);
- }
- else if ((0 == (h->flags & (XCOFF_DEF_DYNAMIC | XCOFF_IMPORT)))
- && ! info->relocateable)
+ }
+ else if ((0 == (h->flags & (XCOFF_DEF_DYNAMIC | XCOFF_IMPORT)))
+ && ! info->relocatable)
{
if (! ((*info->callbacks->undefined_symbol)
(info, h->root.root.string, input_bfd, input_section,
- rel->r_vaddr - input_section->vma, true)))
- return false;
-
+ rel->r_vaddr - input_section->vma, TRUE)))
+ return FALSE;
+
/* Don't try to process the reloc. It can't help, and
it may generate another error. */
continue;
}
}
}
-
- if (rel->r_type >= XCOFF_MAX_CALCULATE_RELOCATION
- || ((*xcoff64_calculate_relocation[rel->r_type])
- (input_bfd, input_section, output_bfd, rel, sym, &howto, val,
- addend, &relocation, contents)))
- return false;
-
+
+ if (rel->r_type >= XCOFF_MAX_CALCULATE_RELOCATION
+ || !((*xcoff64_calculate_relocation[rel->r_type])
+ (input_bfd, input_section, output_bfd, rel, sym, &howto, val,
+ addend, &relocation, contents)))
+ return FALSE;
+
/* address */
address = rel->r_vaddr - input_section->vma;
location = contents + address;
-
+
if (address > input_section->_raw_size)
- abort();
-
+ abort ();
+
/* Get the value we are going to relocate. */
if (1 == howto.size)
value_to_relocate = bfd_get_16 (input_bfd, location);
else if (2 == howto.size)
value_to_relocate = bfd_get_32 (input_bfd, location);
- else
+ else
value_to_relocate = bfd_get_64 (input_bfd, location);
-
- /* overflow.
-
+
+ /* overflow.
+
FIXME: We may drop bits during the addition
which we don't check for. We must either check at every single
operation, which would be tedious, or we must do the computations
in a type larger than bfd_vma, which would be inefficient. */
-
+
if ((unsigned int) howto.complain_on_overflow
>= XCOFF_MAX_COMPLAIN_OVERFLOW)
- abort();
-
+ abort ();
+
if (((*xcoff_complain_overflow[howto.complain_on_overflow])
- (input_bfd, value_to_relocate, relocation, &howto)))
+ (input_bfd, value_to_relocate, relocation, &howto)))
{
const char *name;
char buf[SYMNMLEN + 1];
char reloc_type_name[10];
-
- if (symndx == -1)
+
+ if (symndx == -1)
{
name = "*ABS*";
- }
- else if (h != NULL)
+ }
+ else if (h != NULL)
{
name = h->root.root.string;
- }
- else
+ }
+ else
{
name = _bfd_coff_internal_syment_name (input_bfd, sym, buf);
if (name == NULL)
name = "UNKNOWN";
}
sprintf (reloc_type_name, "0x%02x", rel->r_type);
-
+
if (! ((*info->callbacks->reloc_overflow)
(info, name, reloc_type_name, (bfd_vma) 0, input_bfd,
input_section, rel->r_vaddr - input_section->vma)))
- return false;
+ return FALSE;
}
/* Add RELOCATION to the right bits of VALUE_TO_RELOCATE. */
value_to_relocate = ((value_to_relocate & ~howto.dst_mask)
| (((value_to_relocate & howto.src_mask)
+ relocation) & howto.dst_mask));
-
+
/* Put the value back in the object file. */
if (1 == howto.size)
bfd_put_16 (input_bfd, value_to_relocate, location);
@@ -1335,9 +1364,9 @@ xcoff64_ppc_relocate_section (output_bfd, info, input_bfd,
bfd_put_32 (input_bfd, value_to_relocate, location);
else
bfd_put_64 (input_bfd, value_to_relocate, location);
-
+
}
- return true;
+ return TRUE;
}
@@ -1354,105 +1383,105 @@ reloc_howto_type xcoff64_howto_table[] =
0, /* rightshift */
4, /* size (0 = byte, 1 = short, 2 = long) */
64, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_POS_64", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
MINUS_ONE, /* src_mask */
MINUS_ONE, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 64 bit relocation, but store negative value. */
HOWTO (R_NEG, /* type */
0, /* rightshift */
-4, /* size (0 = byte, 1 = short, 2 = long) */
64, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_NEG", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
MINUS_ONE, /* src_mask */
MINUS_ONE, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 32 bit PC relative relocation. */
HOWTO (R_REL, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
0, /* special_function */
"R_REL", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 16 bit TOC relative relocation. */
HOWTO (R_TOC, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_TOC", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
- /* I don't really know what this is. */
+ /* I don't really know what this is. */
HOWTO (R_RTB, /* type */
1, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_RTB", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* External TOC relative symbol. */
HOWTO (R_GL, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_GL", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Local TOC relative symbol. */
HOWTO (R_TCL, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_TCL", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
EMPTY_HOWTO (7),
@@ -1461,15 +1490,15 @@ reloc_howto_type xcoff64_howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
26, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_BA_26", /* name */
- true, /* partial_inplace */
- 0x3fffffc, /* src_mask */
- 0x3fffffc, /* dst_mask */
- false), /* pcrel_offset */
+ TRUE, /* partial_inplace */
+ 0x03fffffc, /* src_mask */
+ 0x03fffffc, /* dst_mask */
+ FALSE), /* pcrel_offset */
EMPTY_HOWTO (9),
@@ -1478,15 +1507,15 @@ reloc_howto_type xcoff64_howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
26, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
0, /* special_function */
"R_BR", /* name */
- true, /* partial_inplace */
- 0x3fffffc, /* src_mask */
- 0x3fffffc, /* dst_mask */
- false), /* pcrel_offset */
+ TRUE, /* partial_inplace */
+ 0x03fffffc, /* src_mask */
+ 0x03fffffc, /* dst_mask */
+ FALSE), /* pcrel_offset */
EMPTY_HOWTO (0xb),
@@ -1495,47 +1524,47 @@ reloc_howto_type xcoff64_howto_table[] =
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_RL", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Load address. */
HOWTO (R_RLA, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_RLA", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
EMPTY_HOWTO (0xe),
- /* Non-relocating reference. */
+ /* Non-relocating reference. */
HOWTO (R_REF, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
0, /* special_function */
"R_REF", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
EMPTY_HOWTO (0x10),
EMPTY_HOWTO (0x11),
@@ -1545,209 +1574,209 @@ reloc_howto_type xcoff64_howto_table[] =
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_TRL", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* TOC relative load address. */
HOWTO (R_TRLA, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_TRLA", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Modifiable relative branch. */
HOWTO (R_RRTBI, /* type */
1, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_RRTBI", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Modifiable absolute branch. */
HOWTO (R_RRTBA, /* type */
1, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_RRTBA", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Modifiable call absolute indirect. */
HOWTO (R_CAI, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_CAI", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
- /* Modifiable call relative. */
+ /* Modifiable call relative. */
HOWTO (R_CREL, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_CREL", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Modifiable branch absolute. */
HOWTO (R_RBA, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
26, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_RBA", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0x03fffffc, /* src_mask */
0x03fffffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Modifiable branch absolute. */
HOWTO (R_RBAC, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_RBAC", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Modifiable branch relative. */
HOWTO (R_RBR, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
26, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
0, /* special_function */
"R_RBR_26", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0x03fffffc, /* src_mask */
0x03fffffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Modifiable branch absolute. */
HOWTO (R_RBRC, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_RBRC", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_POS, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_POS_32", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 16 bit Non modifiable absolute branch. */
HOWTO (R_BA, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_BA_16", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xfffc, /* src_mask */
0xfffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Modifiable branch relative. */
- HOWTO (R_RBR, /* type */
- 0, /* rightshift */
- 1, /* size (0 = byte, 1 = short, 2 = long) */
- 16, /* bitsize */
- false, /* pc_relative */
- 0, /* bitpos */
+ HOWTO (R_RBR, /* type */
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
- 0, /* special_function */
- "R_RBR_16", /* name */
- true, /* partial_inplace */
- 0xffff, /* src_mask */
- 0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ 0, /* special_function */
+ "R_RBR_16", /* name */
+ TRUE, /* partial_inplace */
+ 0xffff, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
/* Modifiable branch absolute. */
HOWTO (R_RBA, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_RBA_16", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffff, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
};
@@ -1761,24 +1790,24 @@ xcoff64_rtype2howto (relent, internal)
/* Default howto layout works most of the time */
relent->howto = &xcoff64_howto_table[internal->r_type];
-
- /* Special case some 16 bit reoloc */
+
+ /* Special case some 16 bit reloc */
if (15 == (internal->r_size & 0x3f))
{
- if (R_BA == internal->r_type)
+ if (R_BA == internal->r_type)
relent->howto = &xcoff64_howto_table[0x1d];
- else if (R_RBR == internal->r_type)
+ else if (R_RBR == internal->r_type)
relent->howto = &xcoff64_howto_table[0x1e];
- else if (R_RBA == internal->r_type)
+ else if (R_RBA == internal->r_type)
relent->howto = &xcoff64_howto_table[0x1f];
}
/* Special case 32 bit */
else if (31 == (internal->r_size & 0x3f))
{
- if (R_POS == internal->r_type)
+ if (R_POS == internal->r_type)
relent->howto = &xcoff64_howto_table[0x1c];
}
-
+
/* The r_size field of an XCOFF reloc encodes the bitsize of the
relocation, as well as indicating whether it is signed or not.
Doublecheck that the relocation information gathered from the
@@ -1817,7 +1846,7 @@ xcoff64_reloc_type_lookup (abfd, code)
/* Read in the armap of an XCOFF archive. */
-static boolean
+static bfd_boolean
xcoff64_slurp_armap (abfd)
bfd *abfd;
{
@@ -1835,40 +1864,40 @@ xcoff64_slurp_armap (abfd)
if (xcoff_ardata (abfd) == NULL)
{
- bfd_has_map (abfd) = false;
- return true;
+ bfd_has_map (abfd) = FALSE;
+ return TRUE;
}
off = bfd_scan_vma (xcoff_ardata_big (abfd)->symoff64,
(const char **) NULL, 10);
if (off == 0)
{
- bfd_has_map (abfd) = false;
- return true;
+ bfd_has_map (abfd) = FALSE;
+ return TRUE;
}
if (bfd_seek (abfd, off, SEEK_SET) != 0)
- return false;
+ return FALSE;
/* The symbol table starts with a normal archive header. */
if (bfd_bread ((PTR) &hdr, (bfd_size_type) SIZEOF_AR_HDR_BIG, abfd)
!= SIZEOF_AR_HDR_BIG)
- return false;
+ return FALSE;
/* Skip the name (normally empty). */
namlen = strtol (hdr.namlen, (char **) NULL, 10);
pos = ((namlen + 1) & ~(size_t) 1) + SXCOFFARFMAG;
if (bfd_seek (abfd, pos, SEEK_CUR) != 0)
- return false;
+ return FALSE;
sz = bfd_scan_vma (hdr.size, (const char **) NULL, 10);
/* Read in the entire symbol table. */
contents = (bfd_byte *) bfd_alloc (abfd, sz);
if (contents == NULL)
- return false;
+ return FALSE;
if (bfd_bread ((PTR) contents, sz, abfd) != sz)
- return false;
+ return FALSE;
/* The symbol table starts with an eight byte count. */
c = H_GET_64 (abfd, contents);
@@ -1876,13 +1905,13 @@ xcoff64_slurp_armap (abfd)
if (c * 8 >= sz)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
amt = c;
amt *= sizeof (carsym);
bfd_ardata (abfd)->symdefs = (carsym *) bfd_alloc (abfd, amt);
if (bfd_ardata (abfd)->symdefs == NULL)
- return false;
+ return FALSE;
/* After the count comes a list of eight byte file offsets. */
for (i = 0, arsym = bfd_ardata (abfd)->symdefs, p = contents + 8;
@@ -1899,15 +1928,15 @@ xcoff64_slurp_armap (abfd)
if (p >= cend)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
arsym->name = (char *) p;
}
bfd_ardata (abfd)->symdef_count = c;
- bfd_has_map (abfd) = true;
+ bfd_has_map (abfd) = TRUE;
- return true;
+ return TRUE;
}
@@ -1990,7 +2019,7 @@ xcoff64_openr_next_archived_file (archive, last_file)
bfd *archive;
bfd *last_file;
{
- file_ptr filestart;
+ bfd_vma filestart;
if ((xcoff_ardata (archive) == NULL)
|| ! xcoff_big_format_p (archive))
@@ -2019,17 +2048,16 @@ xcoff64_openr_next_archived_file (archive, last_file)
return NULL;
}
- return _bfd_get_elt_at_filepos (archive, filestart);
+ return _bfd_get_elt_at_filepos (archive, (file_ptr) filestart);
}
/* We can't use the usual coff_sizeof_headers routine, because AIX
always uses an a.out header. */
-/*ARGSUSED*/
static int
xcoff64_sizeof_headers (abfd, reloc)
bfd *abfd;
- boolean reloc ATTRIBUTE_UNUSED;
+ bfd_boolean reloc ATTRIBUTE_UNUSED;
{
int size;
@@ -2085,20 +2113,20 @@ xcoff64_create_csect_from_smclas (abfd, aux, symbol_name)
return return_value;
}
-static boolean
+static bfd_boolean
xcoff64_is_lineno_count_overflow (abfd, value)
bfd *abfd ATTRIBUTE_UNUSED;
bfd_vma value ATTRIBUTE_UNUSED;
{
- return false;
+ return FALSE;
}
-static boolean
+static bfd_boolean
xcoff64_is_reloc_count_overflow (abfd, value)
bfd *abfd ATTRIBUTE_UNUSED;
bfd_vma value ATTRIBUTE_UNUSED;
{
- return false;
+ return FALSE;
}
static bfd_vma
@@ -2117,7 +2145,7 @@ xcoff64_loader_reloc_offset (abfd, ldhdr)
return (ldhdr->l_rldoff);
}
-static boolean
+static bfd_boolean
xcoff64_bad_format_hook (abfd, filehdr)
bfd * abfd;
PTR filehdr;
@@ -2126,20 +2154,20 @@ xcoff64_bad_format_hook (abfd, filehdr)
/* Check flavor first. */
if (bfd_get_flavour (abfd) != bfd_target_xcoff_flavour)
- return false;
+ return FALSE;
if (bfd_xcoff_magic_number (abfd) != internal_f->f_magic)
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
xcoff64_generate_rtinit (abfd, init, fini, rtld)
bfd *abfd;
const char *init;
const char *fini;
- boolean rtld;
+ bfd_boolean rtld;
{
bfd_byte filehdr_ext[FILHSZ];
bfd_byte scnhdr_ext[SCNHSZ * 3];
@@ -2166,7 +2194,7 @@ xcoff64_generate_rtinit (abfd, init, fini, rtld)
char *rtld_name = "__rtld";
if (! bfd_xcoff_rtinit_size (abfd))
- return false;
+ return FALSE;
initsz = (init == NULL ? 0 : 1 + strlen (init));
finisz = (fini == NULL ? 0 : 1 + strlen (fini));
@@ -2225,37 +2253,37 @@ xcoff64_generate_rtinit (abfd, init, fini, rtld)
bss_scnhdr.s_flags = STYP_BSS;
/* .data
- 0x0000 0x00000000 : rtl
- 0x0004 0x00000000 :
- 0x0008 0x00000018 : offset to init, or 0
- 0x000C 0x00000038 : offset to fini, or 0
- 0x0010 0x00000010 : size of descriptor
- 0x0014 0x00000000 : pad
- 0x0018 0x00000000 : init, needs a reloc
- 0x001C 0x00000000 :
- 0x0020 0x00000058 : offset to init name
- 0x0024 0x00000000 : flags, padded to a word
- 0x0028 0x00000000 : empty init
- 0x002C 0x00000000 :
- 0x0030 0x00000000 :
- 0x0034 0x00000000 :
- 0x0038 0x00000000 : fini, needs a reloc
- 0x003C 0x00000000 :
- 0x0040 0x00000??? : offset to fini name
- 0x0044 0x00000000 : flags, padded to a word
- 0x0048 0x00000000 : empty fini
- 0x004C 0x00000000 :
- 0x0050 0x00000000 :
- 0x0054 0x00000000 :
- 0x0058 init name
+ 0x0000 0x00000000 : rtl
+ 0x0004 0x00000000 :
+ 0x0008 0x00000018 : offset to init, or 0
+ 0x000C 0x00000038 : offset to fini, or 0
+ 0x0010 0x00000010 : size of descriptor
+ 0x0014 0x00000000 : pad
+ 0x0018 0x00000000 : init, needs a reloc
+ 0x001C 0x00000000 :
+ 0x0020 0x00000058 : offset to init name
+ 0x0024 0x00000000 : flags, padded to a word
+ 0x0028 0x00000000 : empty init
+ 0x002C 0x00000000 :
+ 0x0030 0x00000000 :
+ 0x0034 0x00000000 :
+ 0x0038 0x00000000 : fini, needs a reloc
+ 0x003C 0x00000000 :
+ 0x0040 0x00000??? : offset to fini name
+ 0x0044 0x00000000 : flags, padded to a word
+ 0x0048 0x00000000 : empty fini
+ 0x004C 0x00000000 :
+ 0x0050 0x00000000 :
+ 0x0054 0x00000000 :
+ 0x0058 init name
0x0058 + initsz fini name */
data_buffer_size = 0x0058 + initsz + finisz;
- data_buffer_size += (data_buffer_size & 7) ? 8 - (data_buffer_size & 7) : 0;
+ data_buffer_size = (data_buffer_size + 7) &~ (bfd_size_type) 7;
data_buffer = NULL;
data_buffer = (bfd_byte *) bfd_zmalloc (data_buffer_size);
if (data_buffer == NULL)
- return false;
+ return FALSE;
if (initsz)
{
@@ -2291,7 +2319,7 @@ xcoff64_generate_rtinit (abfd, init, fini, rtld)
string_table = (bfd_byte *) bfd_zmalloc (string_table_size);
if (string_table == NULL)
- return false;
+ return FALSE;
val = string_table_size;
bfd_put_32 (abfd, val, &string_table[0]);
@@ -2455,7 +2483,7 @@ xcoff64_generate_rtinit (abfd, init, fini, rtld)
free (data_buffer);
data_buffer = NULL;
- return true;
+ return TRUE;
}
/* The typical dynamic reloc. */
@@ -2465,15 +2493,15 @@ HOWTO (0, /* type */
0, /* rightshift */
4, /* size (0 = byte, 1 = short, 2 = long) */
64, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
0, /* special_function */
"R_POS", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
MINUS_ONE, /* src_mask */
MINUS_ONE, /* dst_mask */
- false); /* pcrel_offset */
+ FALSE); /* pcrel_offset */
static unsigned long xcoff64_glink_code[10] =
{
@@ -2490,8 +2518,8 @@ static unsigned long xcoff64_glink_code[10] =
};
static const struct xcoff_backend_data_rec bfd_xcoff_backend_data =
-{
- { /* COFF backend, defined in libcoff.h. */
+ {
+ { /* COFF backend, defined in libcoff.h. */
_bfd_xcoff64_swap_aux_in,
_bfd_xcoff64_swap_sym_in,
_bfd_xcoff64_swap_lineno_in,
@@ -2510,11 +2538,11 @@ static const struct xcoff_backend_data_rec bfd_xcoff_backend_data =
RELSZ,
LINESZ,
FILNMLEN,
- true, /* _bfd_coff_long_filenames */
- false, /* _bfd_coff_long_section_names */
+ TRUE, /* _bfd_coff_long_filenames */
+ FALSE, /* _bfd_coff_long_section_names */
3, /* _bfd_coff_default_section_alignment_power */
- true, /* _bfd_coff_force_symnames_in_strings */
- 4, /* _bfd_coff_debug_string_prefix_length */
+ TRUE, /* _bfd_coff_force_symnames_in_strings */
+ 4, /* _bfd_coff_debug_string_prefix_length */
coff_swap_filehdr_in,
coff_swap_aouthdr_in,
coff_swap_scnhdr_in,
@@ -2530,22 +2558,22 @@ static const struct xcoff_backend_data_rec bfd_xcoff_backend_data =
coff_print_aux,
dummy_reloc16_extra_cases,
dummy_reloc16_estimate,
- NULL, /* bfd_coff_sym_is_global */
- coff_compute_section_file_positions,
- NULL , /* _bfd_coff_start_final_link */
+ NULL, /* bfd_coff_sym_is_global */
+ coff_compute_section_file_positions,
+ NULL, /* _bfd_coff_start_final_link */
xcoff64_ppc_relocate_section,
coff_rtype_to_howto,
NULL, /* _bfd_coff_adjust_symndx */
_bfd_generic_link_add_one_symbol,
coff_link_output_has_begun,
coff_final_link_postscript
- },
+ },
- 0x01EF, /* magic number */
+ 0x01EF, /* magic number */
bfd_arch_powerpc,
bfd_mach_ppc_620,
- /* Function pointers to xcoff specific swap routines. */
+ /* Function pointers to xcoff specific swap routines. */
xcoff64_swap_ldhdr_in,
xcoff64_swap_ldhdr_out,
xcoff64_swap_ldsym_in,
@@ -2553,54 +2581,54 @@ static const struct xcoff_backend_data_rec bfd_xcoff_backend_data =
xcoff64_swap_ldrel_in,
xcoff64_swap_ldrel_out,
- /* Sizes. */
+ /* Sizes. */
LDHDRSZ,
LDSYMSZ,
LDRELSZ,
- 24, /* _xcoff_function_descriptor_size */
- 0, /* _xcoff_small_aout_header_size */
+ 24, /* _xcoff_function_descriptor_size */
+ 0, /* _xcoff_small_aout_header_size */
- /* Versions. */
- 2, /* _xcoff_ldhdr_version */
+ /* Versions. */
+ 2, /* _xcoff_ldhdr_version */
_bfd_xcoff64_put_symbol_name,
_bfd_xcoff64_put_ldsymbol_name,
- &xcoff64_dynamic_reloc,
- xcoff64_create_csect_from_smclas,
+ &xcoff64_dynamic_reloc,
+ xcoff64_create_csect_from_smclas,
- /* Lineno and reloc count overflow. */
- xcoff64_is_lineno_count_overflow,
- xcoff64_is_reloc_count_overflow,
+ /* Lineno and reloc count overflow. */
+ xcoff64_is_lineno_count_overflow,
+ xcoff64_is_reloc_count_overflow,
- xcoff64_loader_symbol_offset,
- xcoff64_loader_reloc_offset,
+ xcoff64_loader_symbol_offset,
+ xcoff64_loader_reloc_offset,
- /* glink. */
- &xcoff64_glink_code[0],
- 40, /* _xcoff_glink_size */
+ /* glink. */
+ &xcoff64_glink_code[0],
+ 40, /* _xcoff_glink_size */
- /* rtinit. */
- 88, /* _xcoff_rtinit_size */
+ /* rtinit. */
+ 88, /* _xcoff_rtinit_size */
xcoff64_generate_rtinit,
-};
+ };
/* The transfer vector that leads the outside world to all of the above. */
const bfd_target rs6000coff64_vec =
-{
- "aixcoff64-rs6000",
- bfd_target_xcoff_flavour,
- BFD_ENDIAN_BIG, /* data byte order is big */
- BFD_ENDIAN_BIG, /* header byte order is big */
+ {
+ "aixcoff64-rs6000",
+ bfd_target_xcoff_flavour,
+ BFD_ENDIAN_BIG, /* data byte order is big */
+ BFD_ENDIAN_BIG, /* header byte order is big */
(HAS_RELOC | EXEC_P | HAS_LINENO | HAS_DEBUG | DYNAMIC
| HAS_SYMS | HAS_LOCALS | WP_TEXT),
- (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_RELOC),
- 0, /* leading char */
- '/', /* ar_pad_char */
+ SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_RELOC | SEC_CODE | SEC_DATA,
+ 0, /* leading char */
+ '/', /* ar_pad_char */
15, /* ar_max_namelen */
- /* data */
+ /* data */
bfd_getb64,
bfd_getb_signed_64,
bfd_putb64,
@@ -2611,7 +2639,7 @@ const bfd_target rs6000coff64_vec =
bfd_getb_signed_16,
bfd_putb16,
- /* hdrs */
+ /* hdrs */
bfd_getb64,
bfd_getb_signed_64,
bfd_putb64,
@@ -2622,51 +2650,51 @@ const bfd_target rs6000coff64_vec =
bfd_getb_signed_16,
bfd_putb16,
- { /* bfd_check_format */
- _bfd_dummy_target,
- coff_object_p,
- xcoff64_archive_p,
- CORE_FILE_P
- },
-
- { /* bfd_set_format */
- bfd_false,
- coff_mkobject,
- _bfd_generic_mkarchive,
- bfd_false
- },
-
- {/* bfd_write_contents */
- bfd_false,
- xcoff64_write_object_contents,
- _bfd_xcoff_write_archive_contents,
- bfd_false
- },
-
- /* Generic */
+ { /* bfd_check_format */
+ _bfd_dummy_target,
+ coff_object_p,
+ xcoff64_archive_p,
+ CORE_FILE_P
+ },
+
+ { /* bfd_set_format */
+ bfd_false,
+ coff_mkobject,
+ _bfd_generic_mkarchive,
+ bfd_false
+ },
+
+ {/* bfd_write_contents */
+ bfd_false,
+ xcoff64_write_object_contents,
+ _bfd_xcoff_write_archive_contents,
+ bfd_false
+ },
+
+ /* Generic */
bfd_true,
bfd_true,
coff_new_section_hook,
_bfd_generic_get_section_contents,
- _bfd_generic_get_section_contents_in_window,
+ _bfd_generic_get_section_contents_in_window,
- /* Copy */
+ /* Copy */
_bfd_xcoff_copy_private_bfd_data,
- ((boolean (*) (bfd *, bfd *)) bfd_true),
- ((boolean (*) (bfd *, asection *, bfd *, asection *)) bfd_true),
- ((boolean (*) (bfd *, asymbol *, bfd *, asymbol *)) bfd_true),
- ((boolean (*) (bfd *, flagword)) bfd_true),
- ((boolean (*) (bfd *, void * )) bfd_true),
+ ((bfd_boolean (*) (bfd *, bfd *)) bfd_true),
+ ((bfd_boolean (*) (bfd *, asection *, bfd *, asection *)) bfd_true),
+ ((bfd_boolean (*) (bfd *, asymbol *, bfd *, asymbol *)) bfd_true),
+ ((bfd_boolean (*) (bfd *, flagword)) bfd_true),
+ ((bfd_boolean (*) (bfd *, void * )) bfd_true),
- /* Core */
+ /* Core */
coff_core_file_failing_command,
coff_core_file_failing_signal,
coff_core_file_matches_executable_p,
- /* Archive */
+ /* Archive */
xcoff64_slurp_armap,
bfd_false,
- ((boolean (*) (bfd *, char **, bfd_size_type *, const char **)) bfd_false),
+ ((bfd_boolean (*) (bfd *, char **, bfd_size_type *, const char **)) bfd_false),
bfd_dont_truncate_arname,
_bfd_xcoff_write_armap,
_bfd_xcoff_read_ar_hdr,
@@ -2675,9 +2703,9 @@ const bfd_target rs6000coff64_vec =
_bfd_xcoff_stat_arch_elt,
bfd_true,
- /* Symbols */
+ /* Symbols */
coff_get_symtab_upper_bound,
- coff_get_symtab,
+ coff_canonicalize_symtab,
coff_make_empty_symbol,
coff_print_symbol,
coff_get_symbol_info,
@@ -2688,18 +2716,18 @@ const bfd_target rs6000coff64_vec =
_bfd_generic_read_minisymbols,
_bfd_generic_minisymbol_to_symbol,
- /* Reloc */
+ /* Reloc */
coff_get_reloc_upper_bound,
coff_canonicalize_reloc,
xcoff64_reloc_type_lookup,
- /* Write */
+ /* Write */
coff_set_arch_mach,
coff_set_section_contents,
- /* Link */
+ /* Link */
xcoff64_sizeof_headers,
- bfd_generic_get_relocated_section_contents,
+ bfd_generic_get_relocated_section_contents,
bfd_generic_relax_section,
_bfd_xcoff_bfd_link_hash_table_create,
_bfd_generic_link_hash_table_free,
@@ -2711,27 +2739,31 @@ const bfd_target rs6000coff64_vec =
bfd_generic_merge_sections,
bfd_generic_discard_group,
- /* Dynamic */
- _bfd_xcoff_get_dynamic_symtab_upper_bound,
+ /* Dynamic */
+ _bfd_xcoff_get_dynamic_symtab_upper_bound,
_bfd_xcoff_canonicalize_dynamic_symtab,
_bfd_xcoff_get_dynamic_reloc_upper_bound,
_bfd_xcoff_canonicalize_dynamic_reloc,
- /* Opposite endian version, none exists */
- NULL,
+ /* Opposite endian version, none exists */
+ NULL,
- (void *) &bfd_xcoff_backend_data,
-};
+ (void *) &bfd_xcoff_backend_data,
+ };
-extern const bfd_target *xcoff64_core_p PARAMS ((bfd *));
-extern boolean xcoff64_core_file_matches_executable_p PARAMS((bfd *, bfd *));
-extern char *xcoff64_core_file_failing_command PARAMS ((bfd *));
-extern int xcoff64_core_file_failing_signal PARAMS ((bfd *));
+extern const bfd_target *xcoff64_core_p
+ PARAMS ((bfd *));
+extern bfd_boolean xcoff64_core_file_matches_executable_p
+ PARAMS ((bfd *, bfd *));
+extern char *xcoff64_core_file_failing_command
+ PARAMS ((bfd *));
+extern int xcoff64_core_file_failing_signal
+ PARAMS ((bfd *));
/* AIX 5 */
static const struct xcoff_backend_data_rec bfd_xcoff_aix5_backend_data =
-{
- { /* COFF backend, defined in libcoff.h. */
+ {
+ { /* COFF backend, defined in libcoff.h. */
_bfd_xcoff64_swap_aux_in,
_bfd_xcoff64_swap_sym_in,
_bfd_xcoff64_swap_lineno_in,
@@ -2750,11 +2782,11 @@ static const struct xcoff_backend_data_rec bfd_xcoff_aix5_backend_data =
RELSZ,
LINESZ,
FILNMLEN,
- true, /* _bfd_coff_long_filenames */
- false, /* _bfd_coff_long_section_names */
+ TRUE, /* _bfd_coff_long_filenames */
+ FALSE, /* _bfd_coff_long_section_names */
3, /* _bfd_coff_default_section_alignment_power */
- true, /* _bfd_coff_force_symnames_in_strings */
- 4, /* _bfd_coff_debug_string_prefix_length */
+ TRUE, /* _bfd_coff_force_symnames_in_strings */
+ 4, /* _bfd_coff_debug_string_prefix_length */
coff_swap_filehdr_in,
coff_swap_aouthdr_in,
coff_swap_scnhdr_in,
@@ -2770,22 +2802,22 @@ static const struct xcoff_backend_data_rec bfd_xcoff_aix5_backend_data =
coff_print_aux,
dummy_reloc16_extra_cases,
dummy_reloc16_estimate,
- NULL, /* bfd_coff_sym_is_global */
- coff_compute_section_file_positions,
- NULL , /* _bfd_coff_start_final_link */
+ NULL, /* bfd_coff_sym_is_global */
+ coff_compute_section_file_positions,
+ NULL, /* _bfd_coff_start_final_link */
xcoff64_ppc_relocate_section,
coff_rtype_to_howto,
NULL, /* _bfd_coff_adjust_symndx */
_bfd_generic_link_add_one_symbol,
coff_link_output_has_begun,
coff_final_link_postscript
- },
+ },
- U64_TOCMAGIC, /* magic number */
+ U64_TOCMAGIC, /* magic number */
bfd_arch_powerpc,
bfd_mach_ppc_620,
- /* Function pointers to xcoff specific swap routines. */
+ /* Function pointers to xcoff specific swap routines. */
xcoff64_swap_ldhdr_in,
xcoff64_swap_ldhdr_out,
xcoff64_swap_ldsym_in,
@@ -2793,53 +2825,53 @@ static const struct xcoff_backend_data_rec bfd_xcoff_aix5_backend_data =
xcoff64_swap_ldrel_in,
xcoff64_swap_ldrel_out,
- /* Sizes. */
+ /* Sizes. */
LDHDRSZ,
LDSYMSZ,
LDRELSZ,
- 24, /* _xcoff_function_descriptor_size */
- 0, /* _xcoff_small_aout_header_size */
- /* Versions. */
- 2, /* _xcoff_ldhdr_version */
+ 24, /* _xcoff_function_descriptor_size */
+ 0, /* _xcoff_small_aout_header_size */
+ /* Versions. */
+ 2, /* _xcoff_ldhdr_version */
_bfd_xcoff64_put_symbol_name,
_bfd_xcoff64_put_ldsymbol_name,
- &xcoff64_dynamic_reloc,
- xcoff64_create_csect_from_smclas,
+ &xcoff64_dynamic_reloc,
+ xcoff64_create_csect_from_smclas,
- /* Lineno and reloc count overflow. */
- xcoff64_is_lineno_count_overflow,
- xcoff64_is_reloc_count_overflow,
+ /* Lineno and reloc count overflow. */
+ xcoff64_is_lineno_count_overflow,
+ xcoff64_is_reloc_count_overflow,
- xcoff64_loader_symbol_offset,
- xcoff64_loader_reloc_offset,
+ xcoff64_loader_symbol_offset,
+ xcoff64_loader_reloc_offset,
- /* glink. */
- &xcoff64_glink_code[0],
- 40, /* _xcoff_glink_size */
+ /* glink. */
+ &xcoff64_glink_code[0],
+ 40, /* _xcoff_glink_size */
- /* rtinit. */
- 88, /* _xcoff_rtinit_size */
+ /* rtinit. */
+ 88, /* _xcoff_rtinit_size */
xcoff64_generate_rtinit,
-};
+ };
/* The transfer vector that leads the outside world to all of the above. */
const bfd_target aix5coff64_vec =
-{
- "aix5coff64-rs6000",
- bfd_target_xcoff_flavour,
- BFD_ENDIAN_BIG, /* data byte order is big */
- BFD_ENDIAN_BIG, /* header byte order is big */
+ {
+ "aix5coff64-rs6000",
+ bfd_target_xcoff_flavour,
+ BFD_ENDIAN_BIG, /* data byte order is big */
+ BFD_ENDIAN_BIG, /* header byte order is big */
(HAS_RELOC | EXEC_P | HAS_LINENO | HAS_DEBUG | DYNAMIC
| HAS_SYMS | HAS_LOCALS | WP_TEXT),
- (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_RELOC),
- 0, /* leading char */
- '/', /* ar_pad_char */
+ SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_RELOC | SEC_CODE | SEC_DATA,
+ 0, /* leading char */
+ '/', /* ar_pad_char */
15, /* ar_max_namelen */
- /* data */
+ /* data */
bfd_getb64,
bfd_getb_signed_64,
bfd_putb64,
@@ -2850,7 +2882,7 @@ const bfd_target aix5coff64_vec =
bfd_getb_signed_16,
bfd_putb16,
- /* hdrs */
+ /* hdrs */
bfd_getb64,
bfd_getb_signed_64,
bfd_putb64,
@@ -2861,51 +2893,51 @@ const bfd_target aix5coff64_vec =
bfd_getb_signed_16,
bfd_putb16,
- { /* bfd_check_format */
- _bfd_dummy_target,
- coff_object_p,
- xcoff64_archive_p,
- xcoff64_core_p
- },
-
- { /* bfd_set_format */
- bfd_false,
- coff_mkobject,
- _bfd_generic_mkarchive,
- bfd_false
- },
-
- {/* bfd_write_contents */
- bfd_false,
- xcoff64_write_object_contents,
- _bfd_xcoff_write_archive_contents,
- bfd_false
- },
-
- /* Generic */
+ { /* bfd_check_format */
+ _bfd_dummy_target,
+ coff_object_p,
+ xcoff64_archive_p,
+ xcoff64_core_p
+ },
+
+ { /* bfd_set_format */
+ bfd_false,
+ coff_mkobject,
+ _bfd_generic_mkarchive,
+ bfd_false
+ },
+
+ {/* bfd_write_contents */
+ bfd_false,
+ xcoff64_write_object_contents,
+ _bfd_xcoff_write_archive_contents,
+ bfd_false
+ },
+
+ /* Generic */
bfd_true,
bfd_true,
coff_new_section_hook,
_bfd_generic_get_section_contents,
- _bfd_generic_get_section_contents_in_window,
+ _bfd_generic_get_section_contents_in_window,
- /* Copy */
+ /* Copy */
_bfd_xcoff_copy_private_bfd_data,
- ((boolean (*) (bfd *, bfd *)) bfd_true),
- ((boolean (*) (bfd *, asection *, bfd *, asection *)) bfd_true),
- ((boolean (*) (bfd *, asymbol *, bfd *, asymbol *)) bfd_true),
- ((boolean (*) (bfd *, flagword)) bfd_true),
- ((boolean (*) (bfd *, void * )) bfd_true),
+ ((bfd_boolean (*) (bfd *, bfd *)) bfd_true),
+ ((bfd_boolean (*) (bfd *, asection *, bfd *, asection *)) bfd_true),
+ ((bfd_boolean (*) (bfd *, asymbol *, bfd *, asymbol *)) bfd_true),
+ ((bfd_boolean (*) (bfd *, flagword)) bfd_true),
+ ((bfd_boolean (*) (bfd *, void * )) bfd_true),
- /* Core */
+ /* Core */
xcoff64_core_file_failing_command,
xcoff64_core_file_failing_signal,
xcoff64_core_file_matches_executable_p,
- /* Archive */
+ /* Archive */
xcoff64_slurp_armap,
bfd_false,
- ((boolean (*) (bfd *, char **, bfd_size_type *, const char **)) bfd_false),
+ ((bfd_boolean (*) (bfd *, char **, bfd_size_type *, const char **)) bfd_false),
bfd_dont_truncate_arname,
_bfd_xcoff_write_armap,
_bfd_xcoff_read_ar_hdr,
@@ -2914,9 +2946,9 @@ const bfd_target aix5coff64_vec =
_bfd_xcoff_stat_arch_elt,
bfd_true,
- /* Symbols */
+ /* Symbols */
coff_get_symtab_upper_bound,
- coff_get_symtab,
+ coff_canonicalize_symtab,
coff_make_empty_symbol,
coff_print_symbol,
coff_get_symbol_info,
@@ -2927,18 +2959,18 @@ const bfd_target aix5coff64_vec =
_bfd_generic_read_minisymbols,
_bfd_generic_minisymbol_to_symbol,
- /* Reloc */
+ /* Reloc */
coff_get_reloc_upper_bound,
coff_canonicalize_reloc,
xcoff64_reloc_type_lookup,
- /* Write */
+ /* Write */
coff_set_arch_mach,
coff_set_section_contents,
- /* Link */
+ /* Link */
xcoff64_sizeof_headers,
- bfd_generic_get_relocated_section_contents,
+ bfd_generic_get_relocated_section_contents,
bfd_generic_relax_section,
_bfd_xcoff_bfd_link_hash_table_create,
_bfd_generic_link_hash_table_free,
@@ -2950,14 +2982,14 @@ const bfd_target aix5coff64_vec =
bfd_generic_merge_sections,
bfd_generic_discard_group,
- /* Dynamic */
- _bfd_xcoff_get_dynamic_symtab_upper_bound,
+ /* Dynamic */
+ _bfd_xcoff_get_dynamic_symtab_upper_bound,
_bfd_xcoff_canonicalize_dynamic_symtab,
_bfd_xcoff_get_dynamic_reloc_upper_bound,
_bfd_xcoff_canonicalize_dynamic_reloc,
- /* Opposite endian version, none exists. */
- NULL,
+ /* Opposite endian version, none exists. */
+ NULL,
- (void *) & bfd_xcoff_aix5_backend_data,
-};
+ (void *) & bfd_xcoff_aix5_backend_data,
+ };
diff --git a/contrib/binutils/bfd/coffcode.h b/contrib/binutils/bfd/coffcode.h
index 1c02dcb..15d9709 100644
--- a/contrib/binutils/bfd/coffcode.h
+++ b/contrib/binutils/bfd/coffcode.h
@@ -1,24 +1,24 @@
/* Support for the generic parts of most COFF variants, for BFD.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Support.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/*
Most of this hacked by Steve Chamberlain,
@@ -225,7 +225,7 @@ SUBSUBSECTION
This routine runs though the provided symbol table and uses
the offsets generated by the previous pass and the pointers
generated when the symbol table was read in to create the
- structured hierachy required by coff. It changes each pointer
+ structured hierarchy required by coff. It changes each pointer
to a symbol into the index into the symbol table of the asymbol.
o <<coff_write_symbols>>
@@ -296,7 +296,7 @@ CODE_FRAGMENT
. struct lineno_cache_entry *lineno;
.
. {* Have the line numbers been relocated yet ? *}
-. boolean done_lineno;
+. bfd_boolean done_lineno;
.} coff_symbol_type;
*/
@@ -309,42 +309,64 @@ CODE_FRAGMENT
#define STRING_SIZE_SIZE (4)
-static long sec_to_styp_flags PARAMS ((const char *, flagword));
-static boolean styp_to_sec_flags
+static long sec_to_styp_flags
+ PARAMS ((const char *, flagword));
+static bfd_boolean styp_to_sec_flags
PARAMS ((bfd *, PTR, const char *, asection *, flagword *));
-static boolean coff_bad_format_hook PARAMS ((bfd *, PTR));
+static bfd_boolean coff_bad_format_hook
+ PARAMS ((bfd *, PTR));
static void coff_set_custom_section_alignment
PARAMS ((bfd *, asection *, const struct coff_section_alignment_entry *,
const unsigned int));
-static boolean coff_new_section_hook PARAMS ((bfd *, asection *));
-static boolean coff_set_arch_mach_hook PARAMS ((bfd *, PTR));
-static boolean coff_write_relocs PARAMS ((bfd *, int));
-static boolean coff_set_flags
+static bfd_boolean coff_new_section_hook
+ PARAMS ((bfd *, asection *));
+static bfd_boolean coff_set_arch_mach_hook
+ PARAMS ((bfd *, PTR));
+static bfd_boolean coff_write_relocs
+ PARAMS ((bfd *, int));
+static bfd_boolean coff_set_flags
PARAMS ((bfd *, unsigned int *, unsigned short *));
-static boolean coff_set_arch_mach
+static bfd_boolean coff_set_arch_mach
PARAMS ((bfd *, enum bfd_architecture, unsigned long)) ATTRIBUTE_UNUSED;
-static boolean coff_compute_section_file_positions PARAMS ((bfd *));
-static boolean coff_write_object_contents PARAMS ((bfd *)) ATTRIBUTE_UNUSED;
-static boolean coff_set_section_contents
- PARAMS ((bfd *, asection *, PTR, file_ptr, bfd_size_type));
-static PTR buy_and_read PARAMS ((bfd *, file_ptr, bfd_size_type));
-static boolean coff_slurp_line_table PARAMS ((bfd *, asection *));
-static boolean coff_slurp_symbol_table PARAMS ((bfd *));
+static bfd_boolean coff_compute_section_file_positions
+ PARAMS ((bfd *));
+static bfd_boolean coff_write_object_contents
+ PARAMS ((bfd *)) ATTRIBUTE_UNUSED;
+static bfd_boolean coff_set_section_contents
+ PARAMS ((bfd *, asection *, const PTR, file_ptr, bfd_size_type));
+static PTR buy_and_read
+ PARAMS ((bfd *, file_ptr, bfd_size_type));
+static bfd_boolean coff_slurp_line_table
+ PARAMS ((bfd *, asection *));
+static bfd_boolean coff_slurp_symbol_table
+ PARAMS ((bfd *));
static enum coff_symbol_classification coff_classify_symbol
PARAMS ((bfd *, struct internal_syment *));
-static boolean coff_slurp_reloc_table PARAMS ((bfd *, asection *, asymbol **));
+static bfd_boolean coff_slurp_reloc_table
+ PARAMS ((bfd *, asection *, asymbol **));
static long coff_canonicalize_reloc
PARAMS ((bfd *, asection *, arelent **, asymbol **));
#ifndef coff_mkobject_hook
-static PTR coff_mkobject_hook PARAMS ((bfd *, PTR, PTR));
+static PTR coff_mkobject_hook
+ PARAMS ((bfd *, PTR, PTR));
#endif
#ifdef COFF_WITH_PE
-static flagword handle_COMDAT PARAMS ((bfd *, flagword, PTR, const char *, asection *));
+static flagword handle_COMDAT
+ PARAMS ((bfd *, flagword, PTR, const char *, asection *));
#endif
#ifdef COFF_IMAGE_WITH_PE
-static boolean coff_read_word PARAMS ((bfd *, unsigned int *));
-static unsigned int coff_compute_checksum PARAMS ((bfd *));
-static boolean coff_apply_checksum PARAMS ((bfd *));
+static bfd_boolean coff_read_word
+ PARAMS ((bfd *, unsigned int *));
+static unsigned int coff_compute_checksum
+ PARAMS ((bfd *));
+static bfd_boolean coff_apply_checksum
+ PARAMS ((bfd *));
+#endif
+#ifdef TICOFF
+static bfd_boolean ticoff0_bad_format_hook
+ PARAMS ((bfd *, PTR ));
+static bfd_boolean ticoff1_bad_format_hook
+ PARAMS ((bfd *, PTR ));
#endif
/* void warning(); */
@@ -542,15 +564,15 @@ sec_to_styp_flags (sec_name, sec_flags)
/* For now, the read/write bits are mapped onto SEC_READONLY, even
though the semantics don't quite match. The bits from the input
- are retained in pei_section_data(abfd, section)->pe_flags */
+ are retained in pei_section_data(abfd, section)->pe_flags. */
- styp_flags |= IMAGE_SCN_MEM_READ; /* always readable. */
+ styp_flags |= IMAGE_SCN_MEM_READ; /* Always readable. */
if ((sec_flags & SEC_READONLY) == 0)
- styp_flags |= IMAGE_SCN_MEM_WRITE; /* Invert READONLY for write */
+ styp_flags |= IMAGE_SCN_MEM_WRITE; /* Invert READONLY for write. */
if (sec_flags & SEC_CODE)
- styp_flags |= IMAGE_SCN_MEM_EXECUTE; /* CODE->EXECUTE */
+ styp_flags |= IMAGE_SCN_MEM_EXECUTE; /* CODE->EXECUTE. */
if (sec_flags & SEC_SHARED)
- styp_flags |= IMAGE_SCN_MEM_SHARED; /* Shared remains meaningful */
+ styp_flags |= IMAGE_SCN_MEM_SHARED; /* Shared remains meaningful. */
return styp_flags;
}
@@ -564,7 +586,7 @@ sec_to_styp_flags (sec_name, sec_flags)
#ifndef COFF_WITH_PE
-static boolean
+static bfd_boolean
styp_to_sec_flags (abfd, hdr, name, section, flags_ptr)
bfd *abfd ATTRIBUTE_UNUSED;
PTR hdr;
@@ -677,12 +699,12 @@ styp_to_sec_flags (abfd, hdr, name, section, flags_ptr)
else
sec_flags |= SEC_ALLOC | SEC_LOAD;
-#ifdef STYP_LIT /* A29k readonly text/data section type */
+#ifdef STYP_LIT /* A29k readonly text/data section type. */
if ((styp_flags & STYP_LIT) == STYP_LIT)
sec_flags = (SEC_LOAD | SEC_ALLOC | SEC_READONLY);
#endif /* STYP_LIT */
-#ifdef STYP_OTHER_LOAD /* Other loaded sections */
+#ifdef STYP_OTHER_LOAD /* Other loaded sections. */
if (styp_flags & STYP_OTHER_LOAD)
sec_flags = (SEC_LOAD | SEC_ALLOC);
#endif /* STYP_SDATA */
@@ -699,10 +721,10 @@ styp_to_sec_flags (abfd, hdr, name, section, flags_ptr)
#endif
if (flags_ptr == NULL)
- return false;
+ return FALSE;
* flags_ptr = sec_flags;
- return true;
+ return TRUE;
}
#else /* COFF_WITH_PE */
@@ -786,7 +808,7 @@ handle_COMDAT (abfd, sec_flags, hdr, name, section)
gas-generated, and look for <something> (whatever
follows the $) as the comdat symbol. */
- /* All 3 branches use this */
+ /* All 3 branches use this. */
symname = _bfd_coff_internal_syment_name (abfd, &isym, buf);
if (symname == NULL)
@@ -914,7 +936,7 @@ handle_COMDAT (abfd, sec_flags, hdr, name, section)
#ifndef TARGET_UNDERSCORE
#define TARGET_UNDERSCORE 0
#endif
- /* Is this the name we're looking for? */
+ /* Is this the name we're looking for ? */
if (strcmp (target_name,
symname + (TARGET_UNDERSCORE ? 1 : 0)) != 0)
{
@@ -973,7 +995,7 @@ handle_COMDAT (abfd, sec_flags, hdr, name, section)
required information. FIXME: Is the COMDAT symbol index used for
any purpose other than objdump? */
-static boolean
+static bfd_boolean
styp_to_sec_flags (abfd, hdr, name, section, flags_ptr)
bfd *abfd;
PTR hdr;
@@ -984,7 +1006,7 @@ styp_to_sec_flags (abfd, hdr, name, section, flags_ptr)
struct internal_scnhdr *internal_s = (struct internal_scnhdr *) hdr;
long styp_flags = internal_s->s_flags;
flagword sec_flags;
- boolean result = true;
+ bfd_boolean result = TRUE;
/* Assume read only unless IMAGE_SCN_MEM_WRITE is specified. */
sec_flags = SEC_READONLY;
@@ -1042,7 +1064,11 @@ styp_to_sec_flags (abfd, hdr, name, section, flags_ptr)
sec_flags &= ~ SEC_READONLY;
break;
case IMAGE_SCN_MEM_DISCARDABLE:
- sec_flags |= SEC_DEBUGGING;
+ /* The MS PE spec sets the DISCARDABLE flag on .reloc sections
+ but we do not want them to be labelled as debug section, since
+ then strip would remove them. */
+ if (strncmp (name, ".reloc", sizeof ".reloc" - 1) != 0)
+ sec_flags |= SEC_DEBUGGING;
break;
case IMAGE_SCN_MEM_SHARED:
sec_flags |= SEC_SHARED;
@@ -1085,7 +1111,7 @@ styp_to_sec_flags (abfd, hdr, name, section, flags_ptr)
(*_bfd_error_handler)
(_("%s (%s): Section flag %s (0x%x) ignored"),
bfd_archive_filename (abfd), name, unhandled, flag);
- result = false;
+ result = FALSE;
}
}
@@ -1173,10 +1199,10 @@ Special entry points for gdb to swap in coff symbol table parts:
. unsigned int _bfd_relsz;
. unsigned int _bfd_linesz;
. unsigned int _bfd_filnmlen;
-. boolean _bfd_coff_long_filenames;
-. boolean _bfd_coff_long_section_names;
+. bfd_boolean _bfd_coff_long_filenames;
+. bfd_boolean _bfd_coff_long_section_names;
. unsigned int _bfd_coff_default_section_alignment_power;
-. boolean _bfd_coff_force_symnames_in_strings;
+. bfd_boolean _bfd_coff_force_symnames_in_strings;
. unsigned int _bfd_coff_debug_string_prefix_length;
.
. void (*_bfd_coff_swap_filehdr_in)
@@ -1191,32 +1217,32 @@ Special entry points for gdb to swap in coff symbol table parts:
. void (*_bfd_coff_swap_reloc_in)
. PARAMS ((bfd *abfd, PTR, PTR));
.
-. boolean (*_bfd_coff_bad_format_hook)
+. bfd_boolean (*_bfd_coff_bad_format_hook)
. PARAMS ((bfd *, PTR));
.
-. boolean (*_bfd_coff_set_arch_mach_hook)
+. bfd_boolean (*_bfd_coff_set_arch_mach_hook)
. PARAMS ((bfd *, PTR));
.
. PTR (*_bfd_coff_mkobject_hook)
. PARAMS ((bfd *, PTR, PTR));
.
-. boolean (*_bfd_styp_to_sec_flags_hook)
+. bfd_boolean (*_bfd_styp_to_sec_flags_hook)
. PARAMS ((bfd *, PTR, const char *, asection *, flagword *));
.
. void (*_bfd_set_alignment_hook)
. PARAMS ((bfd *, asection *, PTR));
.
-. boolean (*_bfd_coff_slurp_symbol_table)
+. bfd_boolean (*_bfd_coff_slurp_symbol_table)
. PARAMS ((bfd *));
.
-. boolean (*_bfd_coff_symname_in_debug)
+. bfd_boolean (*_bfd_coff_symname_in_debug)
. PARAMS ((bfd *, struct internal_syment *));
.
-. boolean (*_bfd_coff_pointerize_aux_hook)
+. bfd_boolean (*_bfd_coff_pointerize_aux_hook)
. PARAMS ((bfd *, combined_entry_type *, combined_entry_type *,
. unsigned int, combined_entry_type *));
.
-. boolean (*_bfd_coff_print_aux)
+. bfd_boolean (*_bfd_coff_print_aux)
. PARAMS ((bfd *, FILE *, combined_entry_type *, combined_entry_type *,
. combined_entry_type *, unsigned int));
.
@@ -1231,13 +1257,13 @@ Special entry points for gdb to swap in coff symbol table parts:
. enum coff_symbol_classification (*_bfd_coff_classify_symbol)
. PARAMS ((bfd *, struct internal_syment *));
.
-. boolean (*_bfd_coff_compute_section_file_positions)
+. bfd_boolean (*_bfd_coff_compute_section_file_positions)
. PARAMS ((bfd *));
.
-. boolean (*_bfd_coff_start_final_link)
+. bfd_boolean (*_bfd_coff_start_final_link)
. PARAMS ((bfd *, struct bfd_link_info *));
.
-. boolean (*_bfd_coff_relocate_section)
+. bfd_boolean (*_bfd_coff_relocate_section)
. PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
. struct internal_reloc *, struct internal_syment *, asection **));
.
@@ -1246,19 +1272,19 @@ Special entry points for gdb to swap in coff symbol table parts:
. struct coff_link_hash_entry *, struct internal_syment *,
. bfd_vma *));
.
-. boolean (*_bfd_coff_adjust_symndx)
+. bfd_boolean (*_bfd_coff_adjust_symndx)
. PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *,
-. struct internal_reloc *, boolean *));
+. struct internal_reloc *, bfd_boolean *));
.
-. boolean (*_bfd_coff_link_add_one_symbol)
+. bfd_boolean (*_bfd_coff_link_add_one_symbol)
. PARAMS ((struct bfd_link_info *, bfd *, const char *, flagword,
-. asection *, bfd_vma, const char *, boolean, boolean,
+. asection *, bfd_vma, const char *, bfd_boolean, bfd_boolean,
. struct bfd_link_hash_entry **));
.
-. boolean (*_bfd_coff_link_output_has_begun)
+. bfd_boolean (*_bfd_coff_link_output_has_begun)
. PARAMS ((bfd *, struct coff_final_link_info *));
.
-. boolean (*_bfd_coff_final_link_postscript)
+. bfd_boolean (*_bfd_coff_final_link_postscript)
. PARAMS ((bfd *, struct coff_final_link_info *));
.
.} bfd_coff_backend_data;
@@ -1328,7 +1354,8 @@ Special entry points for gdb to swap in coff symbol table parts:
.#define bfd_coff_set_arch_mach_hook(abfd, filehdr)\
. ((coff_backend_info (abfd)->_bfd_coff_set_arch_mach_hook) (abfd, filehdr))
.#define bfd_coff_mkobject_hook(abfd, filehdr, aouthdr)\
-. ((coff_backend_info (abfd)->_bfd_coff_mkobject_hook) (abfd, filehdr, aouthdr))
+. ((coff_backend_info (abfd)->_bfd_coff_mkobject_hook)\
+. (abfd, filehdr, aouthdr))
.
.#define bfd_coff_styp_to_sec_flags_hook(abfd, scnhdr, name, section, flags_ptr)\
. ((coff_backend_info (abfd)->_bfd_styp_to_sec_flags_hook)\
@@ -1353,7 +1380,8 @@ Special entry points for gdb to swap in coff symbol table parts:
. ((coff_backend_info (abfd)->_bfd_coff_print_aux)\
. (abfd, file, base, symbol, aux, indaux))
.
-.#define bfd_coff_reloc16_extra_cases(abfd, link_info, link_order, reloc, data, src_ptr, dst_ptr)\
+.#define bfd_coff_reloc16_extra_cases(abfd, link_info, link_order,\
+. reloc, data, src_ptr, dst_ptr)\
. ((coff_backend_info (abfd)->_bfd_coff_reloc16_extra_cases)\
. (abfd, link_info, link_order, reloc, data, src_ptr, dst_ptr))
.
@@ -1381,7 +1409,8 @@ Special entry points for gdb to swap in coff symbol table parts:
.#define bfd_coff_adjust_symndx(obfd, info, ibfd, sec, rel, adjustedp)\
. ((coff_backend_info (abfd)->_bfd_coff_adjust_symndx)\
. (obfd, info, ibfd, sec, rel, adjustedp))
-.#define bfd_coff_link_add_one_symbol(info,abfd,name,flags,section,value,string,cp,coll,hashp)\
+.#define bfd_coff_link_add_one_symbol(info, abfd, name, flags, section,\
+. value, string, cp, coll, hashp)\
. ((coff_backend_info (abfd)->_bfd_coff_link_add_one_symbol)\
. (info, abfd, name, flags, section, value, string, cp, coll, hashp))
.
@@ -1394,7 +1423,7 @@ Special entry points for gdb to swap in coff symbol table parts:
/* See whether the magic number matches. */
-static boolean
+static bfd_boolean
coff_bad_format_hook (abfd, filehdr)
bfd * abfd ATTRIBUTE_UNUSED;
PTR filehdr;
@@ -1402,24 +1431,53 @@ coff_bad_format_hook (abfd, filehdr)
struct internal_filehdr *internal_f = (struct internal_filehdr *) filehdr;
if (BADMAG (*internal_f))
- return false;
+ return FALSE;
- /* if the optional header is NULL or not the correct size then
+ /* If the optional header is NULL or not the correct size then
quit; the only difference I can see between m88k dgux headers (MC88DMAGIC)
and Intel 960 readwrite headers (I960WRMAGIC) is that the
optional header is of a different size.
But the mips keeps extra stuff in it's opthdr, so dont check
- when doing that
- */
+ when doing that. */
#if defined(M88) || defined(I960)
if (internal_f->f_opthdr != 0 && bfd_coff_aoutsz (abfd) != internal_f->f_opthdr)
- return false;
+ return FALSE;
+#endif
+
+ return TRUE;
+}
+
+#ifdef TICOFF
+static bfd_boolean
+ticoff0_bad_format_hook (abfd, filehdr)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ PTR filehdr;
+{
+ struct internal_filehdr *internal_f = (struct internal_filehdr *) filehdr;
+
+ if (COFF0_BADMAG (*internal_f))
+ return FALSE;
+
+ return TRUE;
+}
#endif
- return true;
+#ifdef TICOFF
+static bfd_boolean
+ticoff1_bad_format_hook (abfd, filehdr)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ PTR filehdr;
+{
+ struct internal_filehdr *internal_f = (struct internal_filehdr *) filehdr;
+
+ if (COFF1_BADMAG (*internal_f))
+ return FALSE;
+
+ return TRUE;
}
+#endif
/* Check whether this section uses an alignment other than the
default. */
@@ -1437,6 +1495,7 @@ coff_set_custom_section_alignment (abfd, section, alignment_table, table_size)
for (i = 0; i < table_size; ++i)
{
const char *secname = bfd_get_section_name (abfd, section);
+
if (alignment_table[i].comparison_length == (unsigned int) -1
? strcmp (alignment_table[i].name, secname) == 0
: strncmp (alignment_table[i].name, secname,
@@ -1487,7 +1546,7 @@ static const unsigned int coff_section_alignment_table_size =
/* Initialize a section structure with information peculiar to this
particular implementation of COFF. */
-static boolean
+static bfd_boolean
coff_new_section_hook (abfd, section)
bfd * abfd;
asection * section;
@@ -1514,10 +1573,10 @@ coff_new_section_hook (abfd, section)
amt = sizeof (combined_entry_type) * 10;
native = (combined_entry_type *) bfd_zalloc (abfd, amt);
if (native == NULL)
- return false;
+ return FALSE;
/* We don't need to set up n_name, n_value, or n_scnum in the native
- symbol information, since they'll be overriden by the BFD symbol
+ symbol information, since they'll be overridden by the BFD symbol
anyhow. However, we do need to set the type and storage class,
in case this symbol winds up getting written out. The value 0
for n_numaux is already correct. */
@@ -1531,7 +1590,7 @@ coff_new_section_hook (abfd, section)
coff_section_alignment_table,
coff_section_alignment_table_size);
- return true;
+ return TRUE;
}
#ifdef COFF_ALIGN_IN_SECTION_HEADER
@@ -1550,13 +1609,13 @@ coff_set_alignment_hook (abfd, section, scnhdr)
unsigned int i;
#ifdef I960
- /* Extract ALIGN from 2**ALIGN stored in section header */
+ /* Extract ALIGN from 2**ALIGN stored in section header. */
for (i = 0; i < 32; i++)
if ((1 << i) >= hdr->s_align)
break;
#endif
#ifdef TIC80COFF
- /* TI tools puts the alignment power in bits 8-11 */
+ /* TI tools puts the alignment power in bits 8-11. */
i = (hdr->s_flags >> 8) & 0xF ;
#endif
#ifdef COFF_DECODE_ALIGNMENT
@@ -1572,7 +1631,7 @@ coff_set_alignment_hook (abfd, section, scnhdr)
#else /* ! COFF_ALIGN_IN_SECTION_HEADER */
#ifdef COFF_WITH_PE
-/* a couple of macros to help setting the alignment power field */
+/* A couple of macros to help setting the alignment power field. */
#define ALIGN_SET(field,x,y) \
if (((field) & IMAGE_SCN_ALIGN_64BYTES) == x )\
{\
@@ -1633,21 +1692,27 @@ coff_set_alignment_hook (abfd, section, scnhdr)
section->lma = hdr->s_vaddr;
- /* check for extended relocs */
+ /* Check for extended relocs. */
if (hdr->s_flags & IMAGE_SCN_LNK_NRELOC_OVFL)
{
struct external_reloc dst;
struct internal_reloc n;
file_ptr oldpos = bfd_tell (abfd);
+ bfd_size_type relsz = bfd_coff_relsz (abfd);
+
bfd_seek (abfd, (file_ptr) hdr->s_relptr, 0);
- if (bfd_bread ((PTR) &dst, (bfd_size_type) bfd_coff_relsz (abfd), abfd)
- != bfd_coff_relsz (abfd))
+ if (bfd_bread ((PTR) &dst, relsz, abfd) != relsz)
return;
coff_swap_reloc_in (abfd, &dst, &n);
bfd_seek (abfd, oldpos, 0);
- section->reloc_count = hdr->s_nreloc = n.r_vaddr;
+ section->reloc_count = hdr->s_nreloc = n.r_vaddr - 1;
+ section->rel_filepos += relsz;
}
+ else if (hdr->s_nreloc == 0xffff)
+ (*_bfd_error_handler)
+ ("%s: warning: claims to have 0xffff relocs, without overflow",
+ bfd_get_filename (abfd));
}
#undef ALIGN_SET
#undef ELIFALIGN_SET
@@ -1703,9 +1768,9 @@ coff_set_alignment_hook (abfd, section, scnhdr)
#ifndef coff_mkobject
-static boolean coff_mkobject PARAMS ((bfd *));
+static bfd_boolean coff_mkobject PARAMS ((bfd *));
-static boolean
+static bfd_boolean
coff_mkobject (abfd)
bfd * abfd;
{
@@ -1714,7 +1779,7 @@ coff_mkobject (abfd)
abfd->tdata.coff_obj_data = (struct coff_tdata *) bfd_zalloc (abfd, amt);
if (abfd->tdata.coff_obj_data == 0)
- return false;
+ return FALSE;
coff = coff_data (abfd);
coff->symbols = (coff_symbol_type *) NULL;
coff->conversion_table = (unsigned int *) NULL;
@@ -1724,11 +1789,12 @@ coff_mkobject (abfd)
/* make_abs_section(abfd);*/
- return true;
+ return TRUE;
}
#endif
/* Create the COFF backend specific information. */
+
#ifndef coff_mkobject_hook
static PTR
coff_mkobject_hook (abfd, filehdr, aouthdr)
@@ -1778,7 +1844,7 @@ coff_mkobject_hook (abfd, filehdr, aouthdr)
# else
xcoff->xcoff64 = 0;
# endif
- xcoff->full_aouthdr = true;
+ xcoff->full_aouthdr = TRUE;
xcoff->toc = internal_a->o_toc;
xcoff->sntoc = internal_a->o_sntoc;
xcoff->snentry = internal_a->o_snentry;
@@ -1815,7 +1881,7 @@ coff_mkobject_hook (abfd, filehdr, aouthdr)
would be target independent and would also be much more successful
at linking together COFF files for different architectures. */
-static boolean
+static bfd_boolean
coff_set_arch_mach_hook (abfd, filehdr)
bfd *abfd;
PTR filehdr;
@@ -1824,6 +1890,7 @@ coff_set_arch_mach_hook (abfd, filehdr)
enum bfd_architecture arch;
struct internal_filehdr *internal_f = (struct internal_filehdr *) filehdr;
+ /* Zero selects the default machine for an arch. */
machine = 0;
switch (internal_f->f_magic)
{
@@ -1831,13 +1898,11 @@ coff_set_arch_mach_hook (abfd, filehdr)
case OR32_MAGIC_BIG:
case OR32_MAGIC_LITTLE:
arch = bfd_arch_or32;
- machine = 0;
break;
#endif
#ifdef PPCMAGIC
case PPCMAGIC:
arch = bfd_arch_powerpc;
- machine = 0; /* what does this mean? (krk) */
break;
#endif
#ifdef I386MAGIC
@@ -1846,20 +1911,17 @@ coff_set_arch_mach_hook (abfd, filehdr)
case I386AIXMAGIC: /* Danbury PS/2 AIX C Compiler */
case LYNXCOFFMAGIC: /* shadows the m68k Lynx number below, sigh */
arch = bfd_arch_i386;
- machine = 0;
break;
#endif
#ifdef IA64MAGIC
case IA64MAGIC:
arch = bfd_arch_ia64;
- machine = 0;
break;
#endif
#ifdef A29K_MAGIC_BIG
case A29K_MAGIC_BIG:
case A29K_MAGIC_LITTLE:
arch = bfd_arch_a29k;
- machine = 0;
break;
#endif
#ifdef ARMMAGIC
@@ -1867,21 +1929,25 @@ coff_set_arch_mach_hook (abfd, filehdr)
case ARMPEMAGIC:
case THUMBPEMAGIC:
arch = bfd_arch_arm;
- switch (internal_f->f_flags & F_ARM_ARCHITECTURE_MASK)
+ machine = bfd_arm_get_mach_from_notes (abfd, ARM_NOTE_SECTION);
+ if (machine == bfd_mach_arm_unknown)
{
- case F_ARM_2: machine = bfd_mach_arm_2; break;
- case F_ARM_2a: machine = bfd_mach_arm_2a; break;
- case F_ARM_3: machine = bfd_mach_arm_3; break;
- default:
- case F_ARM_3M: machine = bfd_mach_arm_3M; break;
- case F_ARM_4: machine = bfd_mach_arm_4; break;
- case F_ARM_4T: machine = bfd_mach_arm_4T; break;
- /* The COFF header does not have enough bits available
- to cover all the different ARM architectures. So
- we interpret F_ARM_5, the highest flag value to mean
- "the highest ARM architecture known to BFD" which is
- currently the XScale. */
- case F_ARM_5: machine = bfd_mach_arm_XScale; break;
+ switch (internal_f->f_flags & F_ARM_ARCHITECTURE_MASK)
+ {
+ case F_ARM_2: machine = bfd_mach_arm_2; break;
+ case F_ARM_2a: machine = bfd_mach_arm_2a; break;
+ case F_ARM_3: machine = bfd_mach_arm_3; break;
+ default:
+ case F_ARM_3M: machine = bfd_mach_arm_3M; break;
+ case F_ARM_4: machine = bfd_mach_arm_4; break;
+ case F_ARM_4T: machine = bfd_mach_arm_4T; break;
+ /* The COFF header does not have enough bits available
+ to cover all the different ARM architectures. So
+ we interpret F_ARM_5, the highest flag value to mean
+ "the highest ARM architecture known to BFD" which is
+ currently the XScale. */
+ case F_ARM_5: machine = bfd_mach_arm_XScale; break;
+ }
}
break;
#endif
@@ -1921,7 +1987,7 @@ coff_set_arch_mach_hook (abfd, filehdr)
machine = bfd_mach_z8002;
break;
default:
- return false;
+ return FALSE;
}
break;
#endif
@@ -2000,7 +2066,7 @@ coff_set_arch_mach_hook (abfd, filehdr)
|| bfd_bread (buf, amt, abfd) != amt)
{
free (buf);
- return false;
+ return FALSE;
}
bfd_coff_swap_sym_in (abfd, (PTR) buf, (PTR) &sym);
if (sym.n_sclass == C_FILE)
@@ -2044,7 +2110,6 @@ coff_set_arch_mach_hook (abfd, filehdr)
#ifdef WE32KMAGIC
case WE32KMAGIC:
arch = bfd_arch_we32k;
- machine = 0;
break;
#endif
@@ -2052,7 +2117,7 @@ coff_set_arch_mach_hook (abfd, filehdr)
case H8300MAGIC:
arch = bfd_arch_h8300;
machine = bfd_mach_h8300;
- /* !! FIXME this probably isn't the right place for this */
+ /* !! FIXME this probably isn't the right place for this. */
abfd->flags |= BFD_IS_RELAXABLE;
break;
#endif
@@ -2061,7 +2126,7 @@ coff_set_arch_mach_hook (abfd, filehdr)
case H8300HMAGIC:
arch = bfd_arch_h8300;
machine = bfd_mach_h8300h;
- /* !! FIXME this probably isn't the right place for this */
+ /* !! FIXME this probably isn't the right place for this. */
abfd->flags |= BFD_IS_RELAXABLE;
break;
#endif
@@ -2070,7 +2135,25 @@ coff_set_arch_mach_hook (abfd, filehdr)
case H8300SMAGIC:
arch = bfd_arch_h8300;
machine = bfd_mach_h8300s;
- /* !! FIXME this probably isn't the right place for this */
+ /* !! FIXME this probably isn't the right place for this. */
+ abfd->flags |= BFD_IS_RELAXABLE;
+ break;
+#endif
+
+#ifdef H8300HNMAGIC
+ case H8300HNMAGIC:
+ arch = bfd_arch_h8300;
+ machine = bfd_mach_h8300hn;
+ /* !! FIXME this probably isn't the right place for this. */
+ abfd->flags |= BFD_IS_RELAXABLE;
+ break;
+#endif
+
+#ifdef H8300SNMAGIC
+ case H8300SNMAGIC:
+ arch = bfd_arch_h8300;
+ machine = bfd_mach_h8300sn;
+ /* !! FIXME this probably isn't the right place for this. */
abfd->flags |= BFD_IS_RELAXABLE;
break;
#endif
@@ -2082,21 +2165,18 @@ coff_set_arch_mach_hook (abfd, filehdr)
case SH_ARCH_MAGIC_WINCE:
#endif
arch = bfd_arch_sh;
- machine = 0;
break;
#endif
#ifdef MIPS_ARCH_MAGIC_WINCE
case MIPS_ARCH_MAGIC_WINCE:
arch = bfd_arch_mips;
- machine = 0;
break;
#endif
#ifdef H8500MAGIC
case H8500MAGIC:
arch = bfd_arch_h8500;
- machine = 0;
break;
#endif
@@ -2106,7 +2186,6 @@ coff_set_arch_mach_hook (abfd, filehdr)
case LYNXCOFFMAGIC:
#endif
arch = bfd_arch_sparc;
- machine = 0;
break;
#endif
@@ -2118,16 +2197,17 @@ coff_set_arch_mach_hook (abfd, filehdr)
#ifdef TICOFF0MAGIC
#ifdef TICOFF_TARGET_ARCH
- /* this TI COFF section should be used by all new TI COFF v0 targets */
+ /* This TI COFF section should be used by all new TI COFF v0 targets. */
case TICOFF0MAGIC:
arch = TICOFF_TARGET_ARCH;
+ machine = TICOFF_TARGET_MACHINE_GET (internal_f->f_flags);
break;
#endif
#endif
#ifdef TICOFF1MAGIC
- /* this TI COFF section should be used by all new TI COFF v1/2 targets */
- /* TI COFF1 and COFF2 use the target_id field to specify which arch */
+ /* This TI COFF section should be used by all new TI COFF v1/2 targets. */
+ /* TI COFF1 and COFF2 use the target_id field to specify which arch. */
case TICOFF1MAGIC:
case TICOFF2MAGIC:
switch (internal_f->f_target_id)
@@ -2135,6 +2215,7 @@ coff_set_arch_mach_hook (abfd, filehdr)
#ifdef TI_TARGET_ID
case TI_TARGET_ID:
arch = TICOFF_TARGET_ARCH;
+ machine = TICOFF_TARGET_MACHINE_GET (internal_f->f_flags);
break;
#endif
default:
@@ -2165,21 +2246,21 @@ coff_set_arch_mach_hook (abfd, filehdr)
break;
#endif
- default: /* Unreadable input file type */
+ default: /* Unreadable input file type. */
arch = bfd_arch_obscure;
break;
}
bfd_default_set_arch_mach (abfd, arch, machine);
- return true;
+ return TRUE;
}
#ifdef SYMNAME_IN_DEBUG
-static boolean symname_in_debug_hook
+static bfd_boolean symname_in_debug_hook
PARAMS ((bfd *, struct internal_syment *));
-static boolean
+static bfd_boolean
symname_in_debug_hook (abfd, sym)
bfd * abfd ATTRIBUTE_UNUSED;
struct internal_syment *sym;
@@ -2190,7 +2271,7 @@ symname_in_debug_hook (abfd, sym)
#else
#define symname_in_debug_hook \
- (boolean (*) PARAMS ((bfd *, struct internal_syment *))) bfd_false
+ (bfd_boolean (*) PARAMS ((bfd *, struct internal_syment *))) bfd_false
#endif
@@ -2202,12 +2283,11 @@ symname_in_debug_hook (abfd, sym)
/* Handle the csect auxent of a C_EXT or C_HIDEXT symbol. */
-static boolean coff_pointerize_aux_hook
+static bfd_boolean coff_pointerize_aux_hook
PARAMS ((bfd *, combined_entry_type *, combined_entry_type *,
unsigned int, combined_entry_type *));
-/*ARGSUSED*/
-static boolean
+static bfd_boolean
coff_pointerize_aux_hook (abfd, table_base, symbol, indaux, aux)
bfd *abfd ATTRIBUTE_UNUSED;
combined_entry_type *table_base;
@@ -2227,14 +2307,14 @@ coff_pointerize_aux_hook (abfd, table_base, symbol, indaux, aux)
aux->fix_scnlen = 1;
}
- /* Return true to indicate that the caller should not do any
+ /* Return TRUE to indicate that the caller should not do any
further work on this auxent. */
- return true;
+ return TRUE;
}
- /* Return false to indicate that this auxent should be handled by
+ /* Return FALSE to indicate that this auxent should be handled by
the caller. */
- return false;
+ return FALSE;
}
#else
@@ -2242,12 +2322,11 @@ coff_pointerize_aux_hook (abfd, table_base, symbol, indaux, aux)
/* We don't want to pointerize bal entries. */
-static boolean coff_pointerize_aux_hook
+static bfd_boolean coff_pointerize_aux_hook
PARAMS ((bfd *, combined_entry_type *, combined_entry_type *,
unsigned int, combined_entry_type *));
-/*ARGSUSED*/
-static boolean
+static bfd_boolean
coff_pointerize_aux_hook (abfd, table_base, symbol, indaux, aux)
bfd *abfd ATTRIBUTE_UNUSED;
combined_entry_type *table_base ATTRIBUTE_UNUSED;
@@ -2255,7 +2334,7 @@ coff_pointerize_aux_hook (abfd, table_base, symbol, indaux, aux)
unsigned int indaux;
combined_entry_type *aux ATTRIBUTE_UNUSED;
{
- /* Return true if we don't want to pointerize this aux entry, which
+ /* Return TRUE if we don't want to pointerize this aux entry, which
is the case for the lastfirst aux entry for a C_LEAFPROC symbol. */
return (indaux == 1
&& (symbol->u.syment.n_sclass == C_LEAFPROC
@@ -2270,13 +2349,13 @@ coff_pointerize_aux_hook (abfd, table_base, symbol, indaux, aux)
#endif /* ! I960 */
#endif /* ! RS6000COFF_C */
-/* Print an aux entry. This returns true if it has printed it. */
+/* Print an aux entry. This returns TRUE if it has printed it. */
-static boolean coff_print_aux
+static bfd_boolean coff_print_aux
PARAMS ((bfd *, FILE *, combined_entry_type *, combined_entry_type *,
combined_entry_type *, unsigned int));
-static boolean
+static bfd_boolean
coff_print_aux (abfd, file, table_base, symbol, aux, indaux)
bfd *abfd ATTRIBUTE_UNUSED;
FILE *file ATTRIBUTE_UNUSED;
@@ -2323,12 +2402,12 @@ coff_print_aux (abfd, file, table_base, symbol, aux, indaux)
(unsigned int) aux->u.auxent.x_csect.x_smclas,
aux->u.auxent.x_csect.x_stab,
(unsigned int) aux->u.auxent.x_csect.x_snstab);
- return true;
+ return TRUE;
}
#endif
- /* Return false to indicate that no special action was taken. */
- return false;
+ /* Return FALSE to indicate that no special action was taken. */
+ return FALSE;
}
/*
@@ -2351,7 +2430,7 @@ SUBSUBSECTION
static int compare_arelent_ptr PARAMS ((const PTR, const PTR));
-/* AUX's ld wants relocations to be sorted */
+/* AUX's ld wants relocations to be sorted. */
static int
compare_arelent_ptr (x, y)
const PTR x;
@@ -2367,7 +2446,7 @@ compare_arelent_ptr (x, y)
#endif /* TARG_AUX */
-static boolean
+static bfd_boolean
coff_write_relocs (abfd, first_undef)
bfd * abfd;
int first_undef;
@@ -2384,34 +2463,35 @@ coff_write_relocs (abfd, first_undef)
p = s->orelocation;
#else
{
- /* sort relocations before we write them out */
+ /* Sort relocations before we write them out. */
bfd_size_type amt;
amt = s->reloc_count;
amt *= sizeof (arelent *);
p = (arelent **) bfd_malloc (amt);
if (p == NULL && s->reloc_count > 0)
- return false;
+ return FALSE;
memcpy (p, s->orelocation, (size_t) amt);
qsort (p, s->reloc_count, sizeof (arelent *), compare_arelent_ptr);
}
#endif
if (bfd_seek (abfd, s->rel_filepos, SEEK_SET) != 0)
- return false;
+ return FALSE;
#ifdef COFF_WITH_PE
if (obj_pe (abfd) && s->reloc_count >= 0xffff)
{
- /* encode real count here as first reloc */
+ /* Encode real count here as first reloc. */
struct internal_reloc n;
+
memset ((PTR) & n, 0, sizeof (n));
- /* add one to count *this* reloc (grr) */
+ /* Add one to count *this* reloc (grr). */
n.r_vaddr = s->reloc_count + 1;
coff_swap_reloc_out (abfd, &n, &dst);
if (bfd_bwrite ((PTR) & dst, (bfd_size_type) bfd_coff_relsz (abfd),
abfd) != bfd_coff_relsz (abfd))
- return false;
+ return FALSE;
}
#endif
@@ -2419,6 +2499,7 @@ coff_write_relocs (abfd, first_undef)
{
struct internal_reloc n;
arelent *q = p[i];
+
memset ((PTR) & n, 0, sizeof (n));
/* Now we've renumbered the symbols we know where the
@@ -2436,11 +2517,13 @@ coff_write_relocs (abfd, first_undef)
int j;
const char *sname = q->sym_ptr_ptr[0]->name;
asymbol **outsyms = abfd->outsymbols;
+
for (j = first_undef; outsyms[j]; j++)
{
const char *intable = outsyms[j]->name;
+
if (strcmp (intable, sname) == 0) {
- /* got a hit, so repoint the reloc */
+ /* Got a hit, so repoint the reloc. */
q->sym_ptr_ptr = outsyms + j;
break;
}
@@ -2462,7 +2545,8 @@ coff_write_relocs (abfd, first_undef)
#ifdef SECTION_RELATIVE_ABSOLUTE_SYMBOL_P
if (SECTION_RELATIVE_ABSOLUTE_SYMBOL_P (q,s))
#else
- if (q->sym_ptr_ptr == bfd_abs_section_ptr->symbol_ptr_ptr)
+ if ((*q->sym_ptr_ptr)->section == bfd_abs_section_ptr
+ && ((*q->sym_ptr_ptr)->flags & BSF_SECTION_SYM) != 0)
#endif
/* This is a relocation relative to the absolute symbol. */
n.r_symndx = -1;
@@ -2482,15 +2566,16 @@ coff_write_relocs (abfd, first_undef)
#endif
#ifdef SELECT_RELOC
- /* Work out reloc type from what is required */
+ /* Work out reloc type from what is required. */
SELECT_RELOC (n, q->howto);
#else
n.r_type = q->howto->type;
#endif
coff_swap_reloc_out (abfd, &n, &dst);
+
if (bfd_bwrite ((PTR) & dst, (bfd_size_type) bfd_coff_relsz (abfd),
abfd) != bfd_coff_relsz (abfd))
- return false;
+ return FALSE;
}
#ifdef TARG_AUX
@@ -2499,13 +2584,13 @@ coff_write_relocs (abfd, first_undef)
#endif
}
- return true;
+ return TRUE;
}
/* Set flags and magic number of a coff file from architecture and machine
- type. Result is true if we can represent the arch&type, false if not. */
+ type. Result is TRUE if we can represent the arch&type, FALSE if not. */
-static boolean
+static bfd_boolean
coff_set_flags (abfd, magicp, flagsp)
bfd * abfd;
unsigned int *magicp ATTRIBUTE_UNUSED;
@@ -2525,9 +2610,9 @@ coff_set_flags (abfd, magicp, flagsp)
*flagsp = F_Z8002;
break;
default:
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
#endif
#ifdef I960ROMAGIC
@@ -2567,10 +2652,10 @@ coff_set_flags (abfd, magicp, flagsp)
flags = F_I960HX;
break;
default:
- return false;
+ return FALSE;
}
*flagsp = flags;
- return true;
+ return TRUE;
}
break;
#endif
@@ -2578,17 +2663,17 @@ coff_set_flags (abfd, magicp, flagsp)
#ifdef TIC30MAGIC
case bfd_arch_tic30:
*magicp = TIC30MAGIC;
- return true;
+ return TRUE;
#endif
#ifdef TICOFF_DEFAULT_MAGIC
case TICOFF_TARGET_ARCH:
- /* if there's no indication of which version we want, use the default */
+ /* If there's no indication of which version we want, use the default. */
if (!abfd->xvec )
*magicp = TICOFF_DEFAULT_MAGIC;
else
{
- /* we may want to output in a different COFF version */
+ /* We may want to output in a different COFF version. */
switch (abfd->xvec->name[4])
{
case '0':
@@ -2601,16 +2686,17 @@ coff_set_flags (abfd, magicp, flagsp)
*magicp = TICOFF2MAGIC;
break;
default:
- return false;
+ return FALSE;
}
}
- return true;
+ TICOFF_TARGET_MACHINE_SET (flagsp, bfd_get_mach (abfd));
+ return TRUE;
#endif
#ifdef TIC80_ARCH_MAGIC
case bfd_arch_tic80:
*magicp = TIC80_ARCH_MAGIC;
- return true;
+ return TRUE;
#endif
#ifdef ARMMAGIC
case bfd_arch_arm:
@@ -2648,12 +2734,12 @@ coff_set_flags (abfd, magicp, flagsp)
case bfd_mach_arm_5TE: * flagsp |= F_ARM_5; break;
case bfd_mach_arm_XScale: * flagsp |= F_ARM_5; break;
}
- return true;
+ return TRUE;
#endif
#ifdef PPCMAGIC
case bfd_arch_powerpc:
*magicp = PPCMAGIC;
- return true;
+ return TRUE;
break;
#endif
#ifdef I386MAGIC
@@ -2663,19 +2749,19 @@ coff_set_flags (abfd, magicp, flagsp)
/* Just overwrite the usual value if we're doing Lynx. */
*magicp = LYNXCOFFMAGIC;
#endif
- return true;
+ return TRUE;
break;
#endif
#ifdef I860MAGIC
case bfd_arch_i860:
*magicp = I860MAGIC;
- return true;
+ return TRUE;
break;
#endif
#ifdef IA64MAGIC
case bfd_arch_ia64:
*magicp = IA64MAGIC;
- return true;
+ return TRUE;
break;
#endif
#ifdef MC68MAGIC
@@ -2694,14 +2780,14 @@ coff_set_flags (abfd, magicp, flagsp)
/* Just overwrite the usual value if we're doing Lynx. */
*magicp = LYNXCOFFMAGIC;
#endif
- return true;
+ return TRUE;
break;
#endif
#ifdef MC88MAGIC
case bfd_arch_m88k:
*magicp = MC88OMAGIC;
- return true;
+ return TRUE;
break;
#endif
#ifdef H8300MAGIC
@@ -2710,13 +2796,19 @@ coff_set_flags (abfd, magicp, flagsp)
{
case bfd_mach_h8300:
*magicp = H8300MAGIC;
- return true;
+ return TRUE;
case bfd_mach_h8300h:
*magicp = H8300HMAGIC;
- return true;
+ return TRUE;
case bfd_mach_h8300s:
*magicp = H8300SMAGIC;
- return true;
+ return TRUE;
+ case bfd_mach_h8300hn:
+ *magicp = H8300HNMAGIC;
+ return TRUE;
+ case bfd_mach_h8300sn:
+ *magicp = H8300SNMAGIC;
+ return TRUE;
}
break;
#endif
@@ -2731,14 +2823,14 @@ coff_set_flags (abfd, magicp, flagsp)
else
*magicp = SH_ARCH_MAGIC_LITTLE;
#endif
- return true;
+ return TRUE;
break;
#endif
#ifdef MIPS_ARCH_MAGIC_WINCE
case bfd_arch_mips:
*magicp = MIPS_ARCH_MAGIC_WINCE;
- return true;
+ return TRUE;
break;
#endif
@@ -2749,14 +2841,14 @@ coff_set_flags (abfd, magicp, flagsp)
/* Just overwrite the usual value if we're doing Lynx. */
*magicp = LYNXCOFFMAGIC;
#endif
- return true;
+ return TRUE;
break;
#endif
#ifdef H8500MAGIC
case bfd_arch_h8500:
*magicp = H8500MAGIC;
- return true;
+ return TRUE;
break;
#endif
#ifdef A29K_MAGIC_BIG
@@ -2765,14 +2857,14 @@ coff_set_flags (abfd, magicp, flagsp)
*magicp = A29K_MAGIC_BIG;
else
*magicp = A29K_MAGIC_LITTLE;
- return true;
+ return TRUE;
break;
#endif
#ifdef WE32KMAGIC
case bfd_arch_we32k:
*magicp = WE32KMAGIC;
- return true;
+ return TRUE;
break;
#endif
@@ -2783,20 +2875,20 @@ coff_set_flags (abfd, magicp, flagsp)
#endif
BFD_ASSERT (bfd_get_flavour (abfd) == bfd_target_xcoff_flavour);
*magicp = bfd_xcoff_magic_number (abfd);
- return true;
+ return TRUE;
break;
#endif
#ifdef MCOREMAGIC
case bfd_arch_mcore:
* magicp = MCOREMAGIC;
- return true;
+ return TRUE;
#endif
#ifdef W65MAGIC
case bfd_arch_w65:
*magicp = W65MAGIC;
- return true;
+ return TRUE;
#endif
#ifdef OR32_MAGIC_BIG
@@ -2805,19 +2897,19 @@ coff_set_flags (abfd, magicp, flagsp)
* magicp = OR32_MAGIC_BIG;
else
* magicp = OR32_MAGIC_LITTLE;
- return true;
+ return TRUE;
#endif
default: /* Unknown architecture. */
- /* Fall through to "return false" below, to avoid
+ /* Fall through to "return FALSE" below, to avoid
"statement never reached" errors on the one below. */
break;
}
- return false;
+ return FALSE;
}
-static boolean
+static bfd_boolean
coff_set_arch_mach (abfd, arch, machine)
bfd * abfd;
enum bfd_architecture arch;
@@ -2827,13 +2919,13 @@ coff_set_arch_mach (abfd, arch, machine)
unsigned short dummy2;
if (! bfd_default_set_arch_mach (abfd, arch, machine))
- return false;
+ return FALSE;
if (arch != bfd_arch_unknown
&& ! coff_set_flags (abfd, &dummy1, &dummy2))
- return false; /* We can't represent this type */
+ return FALSE; /* We can't represent this type */
- return true; /* We're easy ... */
+ return TRUE; /* We're easy ... */
}
#ifdef COFF_IMAGE_WITH_PE
@@ -2870,14 +2962,14 @@ sort_by_secaddr (arg1, arg2)
#undef ALIGN_SECTIONS_IN_FILE
#endif
-static boolean
+static bfd_boolean
coff_compute_section_file_positions (abfd)
bfd * abfd;
{
asection *current;
asection *previous = (asection *) NULL;
file_ptr sofar = bfd_coff_filhsz (abfd);
- boolean align_adjust;
+ bfd_boolean align_adjust;
#ifdef ALIGN_SECTIONS_IN_FILE
file_ptr old_sofar;
#endif
@@ -2926,6 +3018,11 @@ coff_compute_section_file_positions (abfd)
if (coff_data (abfd)->link_info)
{
page_size = pe_data (abfd)->pe_opthdr.FileAlignment;
+
+ /* If no file alignment has been set, default to one.
+ This repairs 'ld -r' for arm-wince-pe target. */
+ if (page_size == 0)
+ page_size = 1;
}
else
page_size = PE_DEF_FILE_ALIGNMENT;
@@ -2983,7 +3080,7 @@ coff_compute_section_file_positions (abfd)
amt = sizeof (struct asection *) * (count + 1);
section_list = bfd_malloc (amt);
if (section_list == NULL)
- return false;
+ return FALSE;
i = 0;
for (current = abfd->sections; current != NULL; current = current->next)
@@ -3036,7 +3133,7 @@ coff_compute_section_file_positions (abfd)
}
#endif /* ! COFF_IMAGE_WITH_PE */
- align_adjust = false;
+ align_adjust = FALSE;
for (current = abfd->sections;
current != (asection *) NULL;
current = current->next)
@@ -3049,7 +3146,7 @@ coff_compute_section_file_positions (abfd)
bfd_size_type amt = sizeof (struct coff_section_tdata);
current->used_by_bfd = (PTR) bfd_zalloc (abfd, amt);
if (current->used_by_bfd == NULL)
- return false;
+ return FALSE;
}
if (pei_section_data (abfd, current) == NULL)
{
@@ -3057,7 +3154,7 @@ coff_compute_section_file_positions (abfd)
coff_section_data (abfd, current)->tdata
= (PTR) bfd_zalloc (abfd, amt);
if (coff_section_data (abfd, current)->tdata == NULL)
- return false;
+ return FALSE;
}
if (pei_section_data (abfd, current)->virt_size == 0)
pei_section_data (abfd, current)->virt_size = current->_raw_size;
@@ -3080,21 +3177,21 @@ coff_compute_section_file_positions (abfd)
#ifdef ALIGN_SECTIONS_IN_FILE
if ((abfd->flags & EXEC_P) != 0)
{
- /* make sure this section is aligned on the right boundary - by
- padding the previous section up if necessary */
+ /* Make sure this section is aligned on the right boundary - by
+ padding the previous section up if necessary. */
old_sofar = sofar;
#ifdef RS6000COFF_C
/* AIX loader checks the text section alignment of (vma - filepos)
So even though the filepos may be aligned wrt the o_algntext, for
- AIX executables, this check fails. This shows up when an native
+ AIX executables, this check fails. This shows up when a native
AIX executable is stripped with gnu strip because the default vma
of native is 0x10000150 but default for gnu is 0x10000140. Gnu
- stripped gnu excutable passes this check because the filepos is
+ stripped gnu excutable passes this check because the filepos is
0x0140. This problem also show up with 64 bit shared objects. The
data section must also be aligned. */
- if (!strcmp (current->name, _TEXT)
- || !strcmp (current->name, _DATA))
+ if (!strcmp (current->name, _TEXT)
+ || !strcmp (current->name, _DATA))
{
bfd_vma pad;
bfd_vma align;
@@ -3103,8 +3200,8 @@ coff_compute_section_file_positions (abfd)
align = 1 << current->alignment_power;
pad = abs (current->vma - sofar) % align;
-
- if (pad)
+
+ if (pad)
{
pad = align - pad;
sofar += pad;
@@ -3117,9 +3214,7 @@ coff_compute_section_file_positions (abfd)
}
#endif
if (previous != (asection *) NULL)
- {
- previous->_raw_size += sofar - old_sofar;
- }
+ previous->_raw_size += sofar - old_sofar;
}
#endif
@@ -3141,7 +3236,7 @@ coff_compute_section_file_positions (abfd)
sofar += current->_raw_size;
#ifdef ALIGN_SECTIONS_IN_FILE
- /* make sure that this section is of the right size too */
+ /* Make sure that this section is of the right size too. */
if ((abfd->flags & EXEC_P) == 0)
{
bfd_size_type old_size;
@@ -3166,7 +3261,7 @@ coff_compute_section_file_positions (abfd)
_raw_size, in case the caller only writes out data to the
unaligned _raw_size. */
if (pei_section_data (abfd, current)->virt_size < current->_raw_size)
- align_adjust = true;
+ align_adjust = TRUE;
#endif
#ifdef _LIB
@@ -3192,7 +3287,7 @@ coff_compute_section_file_positions (abfd)
b = 0;
if (bfd_seek (abfd, sofar - 1, SEEK_SET) != 0
|| bfd_bwrite (&b, (bfd_size_type) 1, abfd) != 1)
- return false;
+ return FALSE;
}
/* Make sure the relocations are aligned. We don't need to make
@@ -3201,9 +3296,9 @@ coff_compute_section_file_positions (abfd)
sofar = BFD_ALIGN (sofar, 1 << COFF_DEFAULT_SECTION_ALIGNMENT_POWER);
obj_relocbase (abfd) = sofar;
- abfd->output_has_begun = true;
+ abfd->output_has_begun = TRUE;
- return true;
+ return TRUE;
}
#if 0
@@ -3215,7 +3310,7 @@ coff_compute_section_file_positions (abfd)
/* If .file, .text, .data, .bss symbols are missing, add them. */
/* @@ Should we only be adding missing symbols, or overriding the aux
values for existing section symbols? */
-static boolean
+static bfd_boolean
coff_add_missing_symbols (abfd)
bfd *abfd;
{
@@ -3230,10 +3325,11 @@ coff_add_missing_symbols (abfd)
{
coff_symbol_type *csym = coff_symbol_from (abfd, sympp[i]);
const char *name;
+
if (csym)
{
- /* only do this if there is a coff representation of the input
- symbol */
+ /* Only do this if there is a coff representation of the input
+ symbol. */
if (csym->native && csym->native->u.syment.n_sclass == C_FILE)
{
need_file = 0;
@@ -3259,19 +3355,19 @@ coff_add_missing_symbols (abfd)
need_file = 0;
if (!need_text && !need_data && !need_bss && !need_file)
- return true;
+ return TRUE;
nsyms += need_text + need_data + need_bss + need_file;
amt = nsyms;
amt *= sizeof (asymbol *);
sympp2 = (asymbol **) bfd_alloc (abfd, amt);
if (!sympp2)
- return false;
+ return FALSE;
memcpy (sympp2, sympp, i * sizeof (asymbol *));
+
if (need_file)
- {
- /* @@ Generate fake .file symbol, in sympp2[i], and increment i. */
- abort ();
- }
+ /* @@ Generate fake .file symbol, in sympp2[i], and increment i. */
+ abort ();
+
if (need_text)
sympp2[i++] = coff_section_symbol (abfd, _TEXT);
if (need_data)
@@ -3280,7 +3376,7 @@ coff_add_missing_symbols (abfd)
sympp2[i++] = coff_section_symbol (abfd, _BSS);
BFD_ASSERT (i == nsyms);
bfd_set_symtab (abfd, sympp2, nsyms);
- return true;
+ return TRUE;
}
#endif /* 0 */
@@ -3290,7 +3386,7 @@ coff_add_missing_symbols (abfd)
static unsigned int pelength;
static unsigned int peheader;
-static boolean
+static bfd_boolean
coff_read_word (abfd, value)
bfd *abfd;
unsigned int *value;
@@ -3302,7 +3398,7 @@ coff_read_word (abfd, value)
if (status < 1)
{
*value = 0;
- return false;
+ return FALSE;
}
if (status == 1)
@@ -3312,14 +3408,14 @@ coff_read_word (abfd, value)
pelength += (unsigned int) status;
- return true;
+ return TRUE;
}
static unsigned int
coff_compute_checksum (abfd)
bfd *abfd;
{
- boolean more_data;
+ bfd_boolean more_data;
file_ptr filepos;
unsigned int value;
unsigned int total;
@@ -3343,7 +3439,7 @@ coff_compute_checksum (abfd)
return (0xffff & (total + (total >> 0x10)));
}
-static boolean
+static bfd_boolean
coff_apply_checksum (abfd)
bfd *abfd;
{
@@ -3351,51 +3447,51 @@ coff_apply_checksum (abfd)
unsigned int checksum = 0;
if (bfd_seek (abfd, 0x3c, SEEK_SET) != 0)
- return false;
+ return FALSE;
if (!coff_read_word (abfd, &peheader))
- return false;
+ return FALSE;
if (bfd_seek (abfd, peheader + 0x58, SEEK_SET) != 0)
- return false;
+ return FALSE;
checksum = 0;
bfd_bwrite (&checksum, (bfd_size_type) 4, abfd);
if (bfd_seek (abfd, peheader, SEEK_SET) != 0)
- return false;
+ return FALSE;
computed = coff_compute_checksum (abfd);
checksum = computed + pelength;
if (bfd_seek (abfd, peheader + 0x58, SEEK_SET) != 0)
- return false;
+ return FALSE;
bfd_bwrite (&checksum, (bfd_size_type) 4, abfd);
- return true;
+ return TRUE;
}
#endif /* COFF_IMAGE_WITH_PE */
/* SUPPRESS 558 */
/* SUPPRESS 529 */
-static boolean
+static bfd_boolean
coff_write_object_contents (abfd)
bfd * abfd;
{
asection *current;
- boolean hasrelocs = false;
- boolean haslinno = false;
- boolean hasdebug = false;
+ bfd_boolean hasrelocs = FALSE;
+ bfd_boolean haslinno = FALSE;
+ bfd_boolean hasdebug = FALSE;
file_ptr scn_base;
file_ptr reloc_base;
file_ptr lineno_base;
file_ptr sym_base;
unsigned long reloc_size = 0, reloc_count = 0;
unsigned long lnno_size = 0;
- boolean long_section_names;
+ bfd_boolean long_section_names;
asection *text_sec = NULL;
asection *data_sec = NULL;
asection *bss_sec = NULL;
@@ -3408,25 +3504,25 @@ coff_write_object_contents (abfd)
bfd_set_error (bfd_error_system_call);
/* Make a pass through the symbol table to count line number entries and
- put them into the correct asections */
+ put them into the correct asections. */
lnno_size = coff_count_linenumbers (abfd) * bfd_coff_linesz (abfd);
if (! abfd->output_has_begun)
{
if (! coff_compute_section_file_positions (abfd))
- return false;
+ return FALSE;
}
reloc_base = obj_relocbase (abfd);
- /* Work out the size of the reloc and linno areas */
+ /* Work out the size of the reloc and linno areas. */
for (current = abfd->sections; current != NULL; current =
current->next)
{
#ifdef COFF_WITH_PE
- /* we store the actual reloc count in the first reloc's addr */
+ /* We store the actual reloc count in the first reloc's addr. */
if (obj_pe (abfd) && current->reloc_count >= 0xffff)
reloc_count ++;
#endif
@@ -3438,7 +3534,7 @@ coff_write_object_contents (abfd)
lineno_base = reloc_base + reloc_size;
sym_base = lineno_base + lnno_size;
- /* Indicate in each section->line_filepos its actual file address */
+ /* Indicate in each section->line_filepos its actual file address. */
for (current = abfd->sections; current != NULL; current =
current->next)
{
@@ -3457,7 +3553,7 @@ coff_write_object_contents (abfd)
current->rel_filepos = reloc_base;
reloc_base += current->reloc_count * bfd_coff_relsz (abfd);
#ifdef COFF_WITH_PE
- /* extra reloc to hold real count */
+ /* Extra reloc to hold real count. */
if (obj_pe (abfd) && current->reloc_count >= 0xffff)
reloc_base += bfd_coff_relsz (abfd);
#endif
@@ -3487,21 +3583,21 @@ coff_write_object_contents (abfd)
}
if (bfd_seek (abfd, scn_base, SEEK_SET) != 0)
- return false;
+ return FALSE;
- long_section_names = false;
+ long_section_names = FALSE;
for (current = abfd->sections;
current != NULL;
current = current->next)
{
struct internal_scnhdr section;
- boolean is_reloc_section = false;
+ bfd_boolean is_reloc_section = FALSE;
#ifdef COFF_IMAGE_WITH_PE
if (strcmp (current->name, ".reloc") == 0)
{
- is_reloc_section = true;
- hasrelocs = true;
+ is_reloc_section = TRUE;
+ hasrelocs = TRUE;
pe_data (abfd)->has_reloc_section = 1;
}
#endif
@@ -3522,7 +3618,7 @@ coff_write_object_contents (abfd)
memset (section.s_name, 0, SCNNMLEN);
sprintf (section.s_name, "/%lu", (unsigned long) string_size);
string_size += len + 1;
- long_section_names = true;
+ long_section_names = TRUE;
}
}
#endif
@@ -3553,19 +3649,14 @@ coff_write_object_contents (abfd)
section.s_paddr = 0;
#endif
- /*
- If this section has no size or is unloadable then the scnptr
- will be 0 too
- */
+ /* If this section has no size or is unloadable then the scnptr
+ will be 0 too. */
if (current->_raw_size == 0 ||
(current->flags & (SEC_LOAD | SEC_HAS_CONTENTS)) == 0)
- {
- section.s_scnptr = 0;
- }
+ section.s_scnptr = 0;
else
- {
- section.s_scnptr = current->filepos;
- }
+ section.s_scnptr = current->filepos;
+
section.s_relptr = current->rel_filepos;
section.s_lnnoptr = current->line_filepos;
section.s_nreloc = current->reloc_count;
@@ -3573,13 +3664,13 @@ coff_write_object_contents (abfd)
#ifndef COFF_IMAGE_WITH_PE
/* In PEI, relocs come in the .reloc section. */
if (current->reloc_count != 0)
- hasrelocs = true;
+ hasrelocs = TRUE;
#endif
if (current->lineno_count != 0)
- haslinno = true;
+ haslinno = TRUE;
if ((current->flags & SEC_DEBUGGING) != 0
&& ! is_reloc_section)
- hasdebug = true;
+ hasdebug = TRUE;
#ifdef RS6000COFF_C
#ifndef XCOFF64
@@ -3595,17 +3686,11 @@ coff_write_object_contents (abfd)
section.s_flags = sec_to_styp_flags (current->name, current->flags);
if (!strcmp (current->name, _TEXT))
- {
- text_sec = current;
- }
+ text_sec = current;
else if (!strcmp (current->name, _DATA))
- {
- data_sec = current;
- }
+ data_sec = current;
else if (!strcmp (current->name, _BSS))
- {
- bss_sec = current;
- }
+ bss_sec = current;
#ifdef I960
section.s_align = (current->alignment_power
@@ -3613,7 +3698,7 @@ coff_write_object_contents (abfd)
: 0);
#endif
#ifdef TIC80COFF
- /* TI COFF puts the alignment power in bits 8-11 of the flags */
+ /* TI COFF puts the alignment power in bits 8-11 of the flags. */
section.s_flags |= (current->alignment_power & 0xF) << 8;
#endif
#ifdef COFF_ENCODE_ALIGNMENT
@@ -3636,7 +3721,7 @@ coff_write_object_contents (abfd)
if (coff_swap_scnhdr_out (abfd, &section, &buff) == 0
|| bfd_bwrite ((PTR) &buff, amt, abfd) != amt)
- return false;
+ return FALSE;
}
#ifdef COFF_WITH_PE
@@ -3760,7 +3845,7 @@ coff_write_object_contents (abfd)
amt = bfd_coff_scnhsz (abfd);
if (coff_swap_scnhdr_out (abfd, &scnhdr, &buff) == 0
|| bfd_bwrite ((PTR) &buff, amt, abfd) != amt)
- return false;
+ return FALSE;
}
}
#endif
@@ -3770,14 +3855,11 @@ coff_write_object_contents (abfd)
/* Don't include the internal abs section in the section count */
- /*
- We will NOT put a fucking timestamp in the header here. Every time you
+ /* We will NOT put a fucking timestamp in the header here. Every time you
put it back, I will come in and take it out again. I'm sorry. This
field does not belong here. We fill it with a 0 so it compares the
- same but is not a reasonable time. -- gnu@cygnus.com
- */
+ same but is not a reasonable time. -- gnu@cygnus.com */
internal_f.f_timdat = 0;
-
internal_f.f_flags = 0;
if (abfd->flags & EXEC_P)
@@ -3806,7 +3888,9 @@ coff_write_object_contents (abfd)
internal_f.f_flags |= IMAGE_FILE_DEBUG_STRIPPED;
#endif
-#ifndef COFF_WITH_PE
+#ifdef COFF_WITH_PE
+ internal_f.f_flags |= IMAGE_FILE_32BIT_MACHINE;
+#else
if (bfd_little_endian (abfd))
internal_f.f_flags |= F_AR32WR;
else
@@ -3814,18 +3898,16 @@ coff_write_object_contents (abfd)
#endif
#ifdef TI_TARGET_ID
- /* target id is used in TI COFF v1 and later; COFF0 won't use this field,
- but it doesn't hurt to set it internally */
+ /* Target id is used in TI COFF v1 and later; COFF0 won't use this field,
+ but it doesn't hurt to set it internally. */
internal_f.f_target_id = TI_TARGET_ID;
#endif
#ifdef TIC80_TARGET_ID
internal_f.f_target_id = TIC80_TARGET_ID;
#endif
- /*
- FIXME, should do something about the other byte orders and
- architectures.
- */
+ /* FIXME, should do something about the other byte orders and
+ architectures. */
#ifdef RS6000COFF_C
if ((abfd->flags & DYNAMIC) != 0)
@@ -3836,11 +3918,11 @@ coff_write_object_contents (abfd)
memset (&internal_a, 0, sizeof internal_a);
- /* Set up architecture-dependent stuff */
-
+ /* Set up architecture-dependent stuff. */
{
unsigned int magic = 0;
unsigned short flags = 0;
+
coff_set_flags (abfd, &magic, &flags);
internal_f.f_magic = magic;
internal_f.f_flags |= flags;
@@ -3849,14 +3931,13 @@ coff_write_object_contents (abfd)
#ifdef A29K
#ifdef ULTRA3 /* NYU's machine */
/* FIXME: This is a bogus check. I really want to see if there
- * is a .shbss or a .shdata section, if so then set the magic
- * number to indicate a shared data executable.
- */
+ is a .shbss or a .shdata section, if so then set the magic
+ number to indicate a shared data executable. */
if (internal_f.f_nscns >= 7)
- internal_a.magic = SHMAGIC; /* Shared magic */
+ internal_a.magic = SHMAGIC; /* Shared magic. */
else
#endif /* ULTRA3 */
- internal_a.magic = NMAGIC; /* Assume separate i/d */
+ internal_a.magic = NMAGIC; /* Assume separate i/d. */
#define __A_MAGIC_SET__
#endif /* A29K */
#ifdef TICOFF_AOUT_MAGIC
@@ -3971,7 +4052,7 @@ coff_write_object_contents (abfd)
/* FIXME: Does anybody ever set this to another value? */
internal_a.vstamp = 0;
- /* Now should write relocs, strings, syms */
+ /* Now should write relocs, strings, syms. */
obj_sym_filepos (abfd) = sym_base;
if (bfd_get_symcount (abfd) != 0)
@@ -3979,17 +4060,17 @@ coff_write_object_contents (abfd)
int firstundef;
#if 0
if (!coff_add_missing_symbols (abfd))
- return false;
+ return FALSE;
#endif
if (!coff_renumber_symbols (abfd, &firstundef))
- return false;
+ return FALSE;
coff_mangle_symbols (abfd);
if (! coff_write_symbols (abfd))
- return false;
+ return FALSE;
if (! coff_write_linenumbers (abfd))
- return false;
+ return FALSE;
if (! coff_write_relocs (abfd, firstundef))
- return false;
+ return FALSE;
}
#ifdef COFF_LONG_SECTION_NAMES
else if (long_section_names && ! obj_coff_strings_written (abfd))
@@ -3997,7 +4078,7 @@ coff_write_object_contents (abfd)
/* If we have long section names we have to write out the string
table even if there are no symbols. */
if (! coff_write_symbols (abfd))
- return false;
+ return FALSE;
}
#endif
#ifdef COFF_IMAGE_WITH_PE
@@ -4013,7 +4094,7 @@ coff_write_object_contents (abfd)
(file_ptr) BFD_ALIGN (sym_base, COFF_PAGE_SIZE) - 1,
SEEK_SET) != 0
|| bfd_bwrite (&b, (bfd_size_type) 1, abfd) != 1)
- return false;
+ return FALSE;
}
#endif
#endif
@@ -4116,7 +4197,7 @@ coff_write_object_contents (abfd)
internal_a.o_cputype = 4;
break;
case bfd_arch_powerpc:
- if (bfd_get_mach (abfd) == 0)
+ if (bfd_get_mach (abfd) == bfd_mach_ppc)
internal_a.o_cputype = 3;
else
internal_a.o_cputype = 1;
@@ -4132,7 +4213,7 @@ coff_write_object_contents (abfd)
/* now write them */
if (bfd_seek (abfd, (file_ptr) 0, SEEK_SET) != 0)
- return false;
+ return FALSE;
{
char * buff;
@@ -4140,7 +4221,7 @@ coff_write_object_contents (abfd)
buff = bfd_malloc (amount);
if (buff == NULL)
- return false;
+ return FALSE;
bfd_coff_swap_filehdr_out (abfd, (PTR) &internal_f, (PTR) buff);
amount = bfd_bwrite ((PTR) buff, amount, abfd);
@@ -4148,19 +4229,19 @@ coff_write_object_contents (abfd)
free (buff);
if (amount != bfd_coff_filhsz (abfd))
- return false;
+ return FALSE;
}
if (abfd->flags & EXEC_P)
{
/* Note that peicode.h fills in a PEAOUTHDR, not an AOUTHDR.
- include/coff/pe.h sets AOUTSZ == sizeof (PEAOUTHDR)) */
+ include/coff/pe.h sets AOUTSZ == sizeof (PEAOUTHDR)). */
char * buff;
bfd_size_type amount = bfd_coff_aoutsz (abfd);
buff = bfd_malloc (amount);
if (buff == NULL)
- return false;
+ return FALSE;
coff_swap_aouthdr_out (abfd, (PTR) &internal_a, (PTR) buff);
amount = bfd_bwrite ((PTR) buff, amount, abfd);
@@ -4168,11 +4249,11 @@ coff_write_object_contents (abfd)
free (buff);
if (amount != bfd_coff_aoutsz (abfd))
- return false;
+ return FALSE;
#ifdef COFF_IMAGE_WITH_PE
if (! coff_apply_checksum (abfd))
- return false;
+ return FALSE;
#endif
}
#ifdef RS6000COFF_C
@@ -4188,25 +4269,25 @@ coff_write_object_contents (abfd)
else
size = SMALL_AOUTSZ;
if (bfd_bwrite ((PTR) &buff, (bfd_size_type) size, abfd) != size)
- return false;
+ return FALSE;
}
#endif
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
coff_set_section_contents (abfd, section, location, offset, count)
bfd * abfd;
sec_ptr section;
- PTR location;
+ const PTR location;
file_ptr offset;
bfd_size_type count;
{
- if (! abfd->output_has_begun) /* set by bfd.c handler */
+ if (! abfd->output_has_begun) /* Set by bfd.c handler. */
{
if (! coff_compute_section_file_positions (abfd))
- return false;
+ return FALSE;
}
#if defined(_LIB) && !defined(TARG_AUX)
@@ -4230,7 +4311,7 @@ coff_set_section_contents (abfd, section, location, offset, count)
code has been tested on ISC 4.1 by me, and on SCO by Robert Lipe
<robertl@arnet.com> (Thanks!).
- Gvran Uddeborg <gvran@uddeborg.pp.se> */
+ Gvran Uddeborg <gvran@uddeborg.pp.se>. */
if (strcmp (section->name, _LIB) == 0)
{
@@ -4252,18 +4333,18 @@ coff_set_section_contents (abfd, section, location, offset, count)
/* Don't write out bss sections - one way to do this is to
see if the filepos has not been set. */
if (section->filepos == 0)
- return true;
+ return TRUE;
if (bfd_seek (abfd, section->filepos + offset, SEEK_SET) != 0)
- return false;
+ return FALSE;
if (count == 0)
- return true;
+ return TRUE;
return bfd_bwrite (location, count, abfd) == count;
}
#if 0
-static boolean
+static bfd_boolean
coff_close_and_cleanup (abfd)
bfd *abfd;
{
@@ -4272,19 +4353,19 @@ coff_close_and_cleanup (abfd)
{
case bfd_archive:
if (!_bfd_write_archive_contents (abfd))
- return false;
+ return FALSE;
break;
case bfd_object:
if (!coff_write_object_contents (abfd))
- return false;
+ return FALSE;
break;
default:
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
/* We depend on bfd_close to free all the memory on the objalloc. */
- return true;
+ return TRUE;
}
#endif
@@ -4328,7 +4409,7 @@ SUBSUBSECTION
*/
-static boolean
+static bfd_boolean
coff_slurp_line_table (abfd, asect)
bfd *abfd;
asection *asect;
@@ -4341,10 +4422,17 @@ coff_slurp_line_table (abfd, asect)
amt = (bfd_size_type) bfd_coff_linesz (abfd) * asect->lineno_count;
native_lineno = (LINENO *) buy_and_read (abfd, asect->line_filepos, amt);
+ if (native_lineno == NULL)
+ {
+ (*_bfd_error_handler)
+ (_("%s: warning: line number table read failed"),
+ bfd_archive_filename (abfd));
+ return FALSE;
+ }
amt = ((bfd_size_type) asect->lineno_count + 1) * sizeof (alent);
lineno_cache = (alent *) bfd_alloc (abfd, amt);
if (lineno_cache == NULL)
- return false;
+ return FALSE;
else
{
unsigned int counter = 0;
@@ -4354,16 +4442,17 @@ coff_slurp_line_table (abfd, asect)
while (counter < asect->lineno_count)
{
struct internal_lineno dst;
+
bfd_coff_swap_lineno_in (abfd, src, &dst);
cache_ptr->line_number = dst.l_lnno;
if (cache_ptr->line_number == 0)
{
- boolean warned;
+ bfd_boolean warned;
bfd_signed_vma symndx;
coff_symbol_type *sym;
- warned = false;
+ warned = FALSE;
symndx = dst.l_addr.l_symndx;
if (symndx < 0
|| (bfd_vma) symndx >= obj_raw_syment_count (abfd))
@@ -4372,7 +4461,7 @@ coff_slurp_line_table (abfd, asect)
(_("%s: warning: illegal symbol index %ld in line numbers"),
bfd_archive_filename (abfd), dst.l_addr.l_symndx);
symndx = 0;
- warned = true;
+ warned = TRUE;
}
/* FIXME: We should not be casting between ints and
pointers like this. */
@@ -4404,14 +4493,14 @@ coff_slurp_line_table (abfd, asect)
}
asect->lineno = lineno_cache;
/* FIXME, free native_lineno here, or use alloca or something. */
- return true;
+ return TRUE;
}
/* Slurp in the symbol table, converting it to generic form. Note
that if coff_relocate_section is defined, the linker will read
symbols via coff_link_add_symbols, rather than via this routine. */
-static boolean
+static bfd_boolean
coff_slurp_symbol_table (abfd)
bfd * abfd;
{
@@ -4419,36 +4508,34 @@ coff_slurp_symbol_table (abfd)
coff_symbol_type *cached_area;
unsigned int *table_ptr;
bfd_size_type amt;
-
unsigned int number_of_symbols = 0;
if (obj_symbols (abfd))
- return true;
+ return TRUE;
- /* Read in the symbol table */
+ /* Read in the symbol table. */
if ((native_symbols = coff_get_normalized_symtab (abfd)) == NULL)
- {
- return (false);
- } /* on error */
+ return FALSE;
- /* Allocate enough room for all the symbols in cached form */
+ /* Allocate enough room for all the symbols in cached form. */
amt = obj_raw_syment_count (abfd);
amt *= sizeof (coff_symbol_type);
cached_area = (coff_symbol_type *) bfd_alloc (abfd, amt);
if (cached_area == NULL)
- return false;
+ return FALSE;
amt = obj_raw_syment_count (abfd);
amt *= sizeof (unsigned int);
table_ptr = (unsigned int *) bfd_alloc (abfd, amt);
if (table_ptr == NULL)
- return false;
+ return FALSE;
else
{
coff_symbol_type *dst = cached_area;
unsigned int last_native_index = obj_raw_syment_count (abfd);
unsigned int this_index = 0;
+
while (this_index < last_native_index)
{
combined_entry_type *src = native_symbols + this_index;
@@ -4461,7 +4548,7 @@ coff_slurp_symbol_table (abfd)
dst->symbol.section = coff_section_from_bfd_index (abfd,
src->u.syment.n_scnum);
dst->symbol.flags = 0;
- dst->done_lineno = false;
+ dst->done_lineno = FALSE;
switch (src->u.syment.n_sclass)
{
@@ -4472,8 +4559,7 @@ coff_slurp_symbol_table (abfd)
dst->symbol.flags = BSF_EXPORT | BSF_GLOBAL;
dst->symbol.flags |= BSF_NOT_AT_END | BSF_FUNCTION;
#endif
- /* Fall through to next case */
-
+ /* Fall through to next case. */
#endif
case C_EXT:
@@ -4486,10 +4572,10 @@ coff_slurp_symbol_table (abfd)
case C_HIDEXT:
#endif
#ifdef C_SYSTEM
- case C_SYSTEM: /* System Wide variable */
+ case C_SYSTEM: /* System Wide variable. */
#endif
#ifdef COFF_WITH_PE
- /* In PE, 0x68 (104) denotes a section symbol */
+ /* In PE, 0x68 (104) denotes a section symbol. */
case C_SECTION:
/* In PE, 0x69 (105) denotes a weak external symbol. */
case C_NT_WEAK:
@@ -4563,16 +4649,16 @@ coff_slurp_symbol_table (abfd)
break;
- case C_STAT: /* static */
+ case C_STAT: /* Static. */
#ifdef I960
- case C_LEAFSTAT: /* static leaf procedure */
+ case C_LEAFSTAT: /* Static leaf procedure. */
#endif
#if defined ARM
- case C_THUMBSTAT: /* Thumb static */
- case C_THUMBLABEL: /* Thumb label */
- case C_THUMBSTATFUNC:/* Thumb static function */
+ case C_THUMBSTAT: /* Thumb static. */
+ case C_THUMBLABEL: /* Thumb label. */
+ case C_THUMBSTATFUNC:/* Thumb static function. */
#endif
- case C_LABEL: /* label */
+ case C_LABEL: /* Label. */
if (src->u.syment.n_scnum == N_DEBUG)
dst->symbol.flags = BSF_DEBUGGING;
else
@@ -4595,35 +4681,35 @@ coff_slurp_symbol_table (abfd)
dst->symbol.value = src->u.syment.n_value;
break;
- case C_MOS: /* member of structure */
- case C_EOS: /* end of structure */
-#ifdef NOTDEF /* C_AUTOARG has the same value */
+ case C_MOS: /* Member of structure. */
+ case C_EOS: /* End of structure. */
+#ifdef NOTDEF /* C_AUTOARG has the same value. */
#ifdef C_GLBLREG
- case C_GLBLREG: /* A29k-specific storage class */
+ case C_GLBLREG: /* A29k-specific storage class. */
#endif
#endif
- case C_REGPARM: /* register parameter */
- case C_REG: /* register variable */
- /* C_AUTOARG conflictes with TI COFF C_UEXT */
+ case C_REGPARM: /* Register parameter. */
+ case C_REG: /* register variable. */
+ /* C_AUTOARG conflicts with TI COFF C_UEXT. */
#if !defined (TIC80COFF) && !defined (TICOFF)
#ifdef C_AUTOARG
- case C_AUTOARG: /* 960-specific storage class */
+ case C_AUTOARG: /* 960-specific storage class. */
#endif
#endif
- case C_TPDEF: /* type definition */
+ case C_TPDEF: /* Type definition. */
case C_ARG:
- case C_AUTO: /* automatic variable */
- case C_FIELD: /* bit field */
- case C_ENTAG: /* enumeration tag */
- case C_MOE: /* member of enumeration */
- case C_MOU: /* member of union */
- case C_UNTAG: /* union tag */
+ case C_AUTO: /* Automatic variable. */
+ case C_FIELD: /* Bit field. */
+ case C_ENTAG: /* Enumeration tag. */
+ case C_MOE: /* Member of enumeration. */
+ case C_MOU: /* Member of union. */
+ case C_UNTAG: /* Union tag. */
dst->symbol.flags = BSF_DEBUGGING;
dst->symbol.value = (src->u.syment.n_value);
break;
- case C_FILE: /* file name */
- case C_STRTAG: /* structure tag */
+ case C_FILE: /* File name. */
+ case C_STRTAG: /* Structure tag. */
#ifdef RS6000COFF_C
case C_GSYM:
case C_LSYM:
@@ -4631,7 +4717,9 @@ coff_slurp_symbol_table (abfd)
case C_RSYM:
case C_RPSYM:
case C_STSYM:
+ case C_TCSYM:
case C_BCOMM:
+ case C_ECOML:
case C_ECOMM:
case C_DECL:
case C_ENTRY:
@@ -4643,8 +4731,8 @@ coff_slurp_symbol_table (abfd)
break;
#ifdef RS6000COFF_C
- case C_BINCL: /* beginning of include file */
- case C_EINCL: /* ending of include file */
+ case C_BINCL: /* Beginning of include file. */
+ case C_EINCL: /* Ending of include file. */
/* The value is actually a pointer into the line numbers
of the file. We locate the line number entry, and
set the section to the section which contains it, and
@@ -4685,9 +4773,9 @@ coff_slurp_symbol_table (abfd)
break;
#endif
- case C_BLOCK: /* ".bb" or ".eb" */
- case C_FCN: /* ".bf" or ".ef" (or PE ".lf") */
- case C_EFCN: /* physical end of function */
+ case C_BLOCK: /* ".bb" or ".eb". */
+ case C_FCN: /* ".bf" or ".ef" (or PE ".lf"). */
+ case C_EFCN: /* Physical end of function. */
#if defined COFF_WITH_PE
/* PE sets the symbol to a value relative to the start
of the section. */
@@ -4709,7 +4797,7 @@ coff_slurp_symbol_table (abfd)
#endif
break;
- case C_STATLAB: /* Static load time label */
+ case C_STATLAB: /* Static load time label. */
dst->symbol.value = src->u.syment.n_value;
dst->symbol.flags = BSF_GLOBAL;
break;
@@ -4722,22 +4810,22 @@ coff_slurp_symbol_table (abfd)
&& src->u.syment.n_scnum == 0)
break;
/* Fall through. */
- case C_EXTDEF: /* external definition */
- case C_ULABEL: /* undefined label */
- case C_USTATIC: /* undefined static */
+ case C_EXTDEF: /* External definition. */
+ case C_ULABEL: /* Undefined label. */
+ case C_USTATIC: /* Undefined static. */
#ifndef COFF_WITH_PE
/* C_LINE in regular coff is 0x68. NT has taken over this storage
- class to represent a section symbol */
- case C_LINE: /* line # reformatted as symbol table entry */
+ class to represent a section symbol. */
+ case C_LINE: /* line # reformatted as symbol table entry. */
/* NT uses 0x67 for a weak symbol, not C_ALIAS. */
- case C_ALIAS: /* duplicate tag */
+ case C_ALIAS: /* Duplicate tag. */
#endif
- /* New storage classes for TI COFF */
+ /* New storage classes for TI COFF. */
#if defined(TIC80COFF) || defined(TICOFF)
- case C_UEXT: /* Tentative external definition */
+ case C_UEXT: /* Tentative external definition. */
#endif
- case C_EXTLAB: /* External load time label */
- case C_HIDDEN: /* ext symbol in dmert public lib */
+ case C_EXTLAB: /* External load time label. */
+ case C_HIDDEN: /* Ext symbol in dmert public lib. */
default:
(*_bfd_error_handler)
(_("%s: Unrecognized storage class %d for %s symbol `%s'"),
@@ -4757,17 +4845,18 @@ coff_slurp_symbol_table (abfd)
this_index += (src->u.syment.n_numaux) + 1;
dst++;
number_of_symbols++;
- } /* walk the native symtab */
- } /* bfdize the native symtab */
+ }
+ }
obj_symbols (abfd) = cached_area;
obj_raw_syments (abfd) = native_symbols;
bfd_get_symcount (abfd) = number_of_symbols;
obj_convert (abfd) = table_ptr;
- /* Slurp the line tables for each section too */
+ /* Slurp the line tables for each section too. */
{
asection *p;
+
p = abfd->sections;
while (p)
{
@@ -4775,7 +4864,8 @@ coff_slurp_symbol_table (abfd)
p = p->next;
}
}
- return true;
+
+ return TRUE;
} /* coff_slurp_symbol_table() */
/* Classify a COFF symbol. A couple of targets have globally visible
@@ -4927,7 +5017,7 @@ SUBSUBSECTION
}
#endif
-static boolean
+static bfd_boolean
coff_slurp_reloc_table (abfd, asect, symbols)
bfd * abfd;
sec_ptr asect;
@@ -4940,20 +5030,20 @@ coff_slurp_reloc_table (abfd, asect, symbols)
bfd_size_type amt;
if (asect->relocation)
- return true;
+ return TRUE;
if (asect->reloc_count == 0)
- return true;
+ return TRUE;
if (asect->flags & SEC_CONSTRUCTOR)
- return true;
+ return TRUE;
if (!coff_slurp_symbol_table (abfd))
- return false;
+ return FALSE;
amt = (bfd_size_type) bfd_coff_relsz (abfd) * asect->reloc_count;
native_relocs = (RELOC *) buy_and_read (abfd, asect->rel_filepos, amt);
amt = (bfd_size_type) asect->reloc_count * sizeof (arelent);
reloc_cache = (arelent *) bfd_alloc (abfd, amt);
if (reloc_cache == NULL)
- return false;
+ return FALSE;
for (idx = 0; idx < asect->reloc_count; idx++)
{
@@ -5001,15 +5091,15 @@ coff_slurp_reloc_table (abfd, asect, symbols)
refering to the symbols in the raw data have not been
modified, so we have to have a negative addend to compensate.
- Note that symbols which used to be common must be left alone */
+ Note that symbols which used to be common must be left alone. */
- /* Calculate any reloc addend by looking at the symbol */
+ /* Calculate any reloc addend by looking at the symbol. */
CALC_ADDEND (abfd, ptr, dst, cache_ptr);
cache_ptr->address -= asect->vma;
/* !! cache_ptr->section = (asection *) NULL;*/
- /* Fill in the cache_ptr->howto field from dst.r_type */
+ /* Fill in the cache_ptr->howto field from dst.r_type. */
RTYPE2HOWTO (cache_ptr, &dst);
#endif /* RELOC_PROCESSING */
@@ -5019,12 +5109,12 @@ coff_slurp_reloc_table (abfd, asect, symbols)
(_("%s: illegal relocation type %d at address 0x%lx"),
bfd_archive_filename (abfd), dst.r_type, (long) dst.r_vaddr);
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
}
asect->relocation = reloc_cache;
- return true;
+ return TRUE;
}
#ifndef coff_rtype_to_howto
@@ -5041,7 +5131,6 @@ static reloc_howto_type *coff_rtype_to_howto
struct coff_link_hash_entry *, struct internal_syment *,
bfd_vma *));
-/*ARGSUSED*/
static reloc_howto_type *
coff_rtype_to_howto (abfd, sec, rel, h, sym, addendp)
bfd *abfd ATTRIBUTE_UNUSED;
@@ -5077,16 +5166,16 @@ coff_canonicalize_reloc (abfd, section, relptr, symbols)
if (section->flags & SEC_CONSTRUCTOR)
{
- /* this section has relocs made up by us, they are not in the
- file, so take them out of their chain and place them into
- the data area provided */
+ /* This section has relocs made up by us, they are not in the
+ file, so take them out of their chain and place them into
+ the data area provided. */
arelent_chain *chain = section->constructor_chain;
+
for (count = 0; count < section->reloc_count; count++)
{
*relptr++ = &chain->relent;
chain = chain->next;
}
-
}
else
{
@@ -5201,10 +5290,10 @@ dummy_reloc16_extra_cases (abfd, link_info, link_order, reloc, data, src_ptr,
#ifndef coff_link_output_has_begun
-static boolean coff_link_output_has_begun
+static bfd_boolean coff_link_output_has_begun
PARAMS ((bfd *, struct coff_final_link_info *));
-static boolean
+static bfd_boolean
coff_link_output_has_begun (abfd, info)
bfd * abfd;
struct coff_final_link_info * info ATTRIBUTE_UNUSED;
@@ -5215,15 +5304,15 @@ coff_link_output_has_begun (abfd, info)
#ifndef coff_final_link_postscript
-static boolean coff_final_link_postscript
+static bfd_boolean coff_final_link_postscript
PARAMS ((bfd *, struct coff_final_link_info *));
-static boolean
+static bfd_boolean
coff_final_link_postscript (abfd, pfinfo)
bfd * abfd ATTRIBUTE_UNUSED;
struct coff_final_link_info * pfinfo ATTRIBUTE_UNUSED;
{
- return true;
+ return TRUE;
}
#endif
@@ -5279,20 +5368,20 @@ static const bfd_coff_backend_data bfd_coff_std_swap_table =
coff_SWAP_scnhdr_out,
FILHSZ, AOUTSZ, SCNHSZ, SYMESZ, AUXESZ, RELSZ, LINESZ, FILNMLEN,
#ifdef COFF_LONG_FILENAMES
- true,
+ TRUE,
#else
- false,
+ FALSE,
#endif
#ifdef COFF_LONG_SECTION_NAMES
- true,
+ TRUE,
#else
- false,
+ FALSE,
#endif
COFF_DEFAULT_SECTION_ALIGNMENT_POWER,
#ifdef COFF_FORCE_SYMBOLS_IN_STRINGS
- true,
+ TRUE,
#else
- false,
+ FALSE,
#endif
#ifdef COFF_DEBUG_STRING_WIDE_PREFIX
4,
@@ -5310,6 +5399,92 @@ static const bfd_coff_backend_data bfd_coff_std_swap_table =
coff_link_output_has_begun, coff_final_link_postscript
};
+#ifdef TICOFF
+/* COFF0 differs in file/section header size and relocation entry size. */
+static const bfd_coff_backend_data ticoff0_swap_table =
+{
+ coff_SWAP_aux_in, coff_SWAP_sym_in, coff_SWAP_lineno_in,
+ coff_SWAP_aux_out, coff_SWAP_sym_out,
+ coff_SWAP_lineno_out, coff_SWAP_reloc_out,
+ coff_SWAP_filehdr_out, coff_SWAP_aouthdr_out,
+ coff_SWAP_scnhdr_out,
+ FILHSZ_V0, AOUTSZ, SCNHSZ_V01, SYMESZ, AUXESZ, RELSZ_V0, LINESZ, FILNMLEN,
+#ifdef COFF_LONG_FILENAMES
+ TRUE,
+#else
+ FALSE,
+#endif
+#ifdef COFF_LONG_SECTION_NAMES
+ TRUE,
+#else
+ FALSE,
+#endif
+ COFF_DEFAULT_SECTION_ALIGNMENT_POWER,
+#ifdef COFF_FORCE_SYMBOLS_IN_STRINGS
+ TRUE,
+#else
+ FALSE,
+#endif
+#ifdef COFF_DEBUG_STRING_WIDE_PREFIX
+ 4,
+#else
+ 2,
+#endif
+ coff_SWAP_filehdr_in, coff_SWAP_aouthdr_in, coff_SWAP_scnhdr_in,
+ coff_SWAP_reloc_in, ticoff0_bad_format_hook, coff_set_arch_mach_hook,
+ coff_mkobject_hook, styp_to_sec_flags, coff_set_alignment_hook,
+ coff_slurp_symbol_table, symname_in_debug_hook, coff_pointerize_aux_hook,
+ coff_print_aux, coff_reloc16_extra_cases, coff_reloc16_estimate,
+ coff_classify_symbol, coff_compute_section_file_positions,
+ coff_start_final_link, coff_relocate_section, coff_rtype_to_howto,
+ coff_adjust_symndx, coff_link_add_one_symbol,
+ coff_link_output_has_begun, coff_final_link_postscript
+};
+#endif
+
+#ifdef TICOFF
+/* COFF1 differs in section header size. */
+static const bfd_coff_backend_data ticoff1_swap_table =
+{
+ coff_SWAP_aux_in, coff_SWAP_sym_in, coff_SWAP_lineno_in,
+ coff_SWAP_aux_out, coff_SWAP_sym_out,
+ coff_SWAP_lineno_out, coff_SWAP_reloc_out,
+ coff_SWAP_filehdr_out, coff_SWAP_aouthdr_out,
+ coff_SWAP_scnhdr_out,
+ FILHSZ, AOUTSZ, SCNHSZ_V01, SYMESZ, AUXESZ, RELSZ, LINESZ, FILNMLEN,
+#ifdef COFF_LONG_FILENAMES
+ TRUE,
+#else
+ FALSE,
+#endif
+#ifdef COFF_LONG_SECTION_NAMES
+ TRUE,
+#else
+ FALSE,
+#endif
+ COFF_DEFAULT_SECTION_ALIGNMENT_POWER,
+#ifdef COFF_FORCE_SYMBOLS_IN_STRINGS
+ TRUE,
+#else
+ FALSE,
+#endif
+#ifdef COFF_DEBUG_STRING_WIDE_PREFIX
+ 4,
+#else
+ 2,
+#endif
+ coff_SWAP_filehdr_in, coff_SWAP_aouthdr_in, coff_SWAP_scnhdr_in,
+ coff_SWAP_reloc_in, ticoff1_bad_format_hook, coff_set_arch_mach_hook,
+ coff_mkobject_hook, styp_to_sec_flags, coff_set_alignment_hook,
+ coff_slurp_symbol_table, symname_in_debug_hook, coff_pointerize_aux_hook,
+ coff_print_aux, coff_reloc16_extra_cases, coff_reloc16_estimate,
+ coff_classify_symbol, coff_compute_section_file_positions,
+ coff_start_final_link, coff_relocate_section, coff_rtype_to_howto,
+ coff_adjust_symndx, coff_link_add_one_symbol,
+ coff_link_output_has_begun, coff_final_link_postscript
+};
+#endif
+
#ifndef coff_close_and_cleanup
#define coff_close_and_cleanup _bfd_generic_close_and_cleanup
#endif
@@ -5385,7 +5560,7 @@ static const bfd_coff_backend_data bfd_coff_std_swap_table =
#define coff_bfd_discard_group bfd_generic_discard_group
#endif
-#define CREATE_BIG_COFF_TARGET_VEC(VAR, NAME, EXTRA_O_FLAGS, EXTRA_S_FLAGS, UNDER, ALTERNATIVE) \
+#define CREATE_BIG_COFF_TARGET_VEC(VAR, NAME, EXTRA_O_FLAGS, EXTRA_S_FLAGS, UNDER, ALTERNATIVE, SWAP_TABLE) \
const bfd_target VAR = \
{ \
NAME , \
@@ -5432,10 +5607,60 @@ const bfd_target VAR = \
\
ALTERNATIVE, \
\
- COFF_SWAP_TABLE \
+ SWAP_TABLE \
+};
+
+#define CREATE_BIGHDR_COFF_TARGET_VEC(VAR, NAME, EXTRA_O_FLAGS, EXTRA_S_FLAGS, UNDER, ALTERNATIVE, SWAP_TABLE) \
+const bfd_target VAR = \
+{ \
+ NAME , \
+ bfd_target_coff_flavour, \
+ BFD_ENDIAN_LITTLE, /* data byte order is little */ \
+ BFD_ENDIAN_BIG, /* header byte order is big */ \
+ /* object flags */ \
+ (HAS_RELOC | EXEC_P | HAS_LINENO | HAS_DEBUG | \
+ HAS_SYMS | HAS_LOCALS | WP_TEXT | EXTRA_O_FLAGS), \
+ /* section flags */ \
+ (SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_RELOC | EXTRA_S_FLAGS),\
+ UNDER, /* leading symbol underscore */ \
+ '/', /* ar_pad_char */ \
+ 15, /* ar_max_namelen */ \
+ \
+ /* Data conversion functions. */ \
+ bfd_getb64, bfd_getb_signed_64, bfd_putb64, \
+ bfd_getb32, bfd_getb_signed_32, bfd_putb32, \
+ bfd_getb16, bfd_getb_signed_16, bfd_putb16, \
+ \
+ /* Header conversion functions. */ \
+ bfd_getb64, bfd_getb_signed_64, bfd_putb64, \
+ bfd_getb32, bfd_getb_signed_32, bfd_putb32, \
+ bfd_getb16, bfd_getb_signed_16, bfd_putb16, \
+ \
+ /* bfd_check_format */ \
+ { _bfd_dummy_target, coff_object_p, bfd_generic_archive_p, \
+ _bfd_dummy_target }, \
+ /* bfd_set_format */ \
+ { bfd_false, coff_mkobject, _bfd_generic_mkarchive, bfd_false }, \
+ /* bfd_write_contents */ \
+ { bfd_false, coff_write_object_contents, _bfd_write_archive_contents, \
+ bfd_false }, \
+ \
+ BFD_JUMP_TABLE_GENERIC (coff), \
+ BFD_JUMP_TABLE_COPY (coff), \
+ BFD_JUMP_TABLE_CORE (_bfd_nocore), \
+ BFD_JUMP_TABLE_ARCHIVE (_bfd_archive_coff), \
+ BFD_JUMP_TABLE_SYMBOLS (coff), \
+ BFD_JUMP_TABLE_RELOCS (coff), \
+ BFD_JUMP_TABLE_WRITE (coff), \
+ BFD_JUMP_TABLE_LINK (coff), \
+ BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic), \
+ \
+ ALTERNATIVE, \
+ \
+ SWAP_TABLE \
};
-#define CREATE_LITTLE_COFF_TARGET_VEC(VAR, NAME, EXTRA_O_FLAGS, EXTRA_S_FLAGS, UNDER, ALTERNATIVE) \
+#define CREATE_LITTLE_COFF_TARGET_VEC(VAR, NAME, EXTRA_O_FLAGS, EXTRA_S_FLAGS, UNDER, ALTERNATIVE, SWAP_TABLE) \
const bfd_target VAR = \
{ \
NAME , \
@@ -5480,5 +5705,5 @@ const bfd_target VAR = \
\
ALTERNATIVE, \
\
- COFF_SWAP_TABLE \
+ SWAP_TABLE \
};
diff --git a/contrib/binutils/bfd/coffgen.c b/contrib/binutils/bfd/coffgen.c
index 21589c6..a712b4b 100644
--- a/contrib/binutils/bfd/coffgen.c
+++ b/contrib/binutils/bfd/coffgen.c
@@ -1,6 +1,6 @@
/* Support for the generic parts of COFF, for BFD.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Support.
@@ -46,19 +46,19 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
static void coff_fix_symbol_name
PARAMS ((bfd *, asymbol *, combined_entry_type *, bfd_size_type *,
asection **, bfd_size_type *));
-static boolean coff_write_symbol
+static bfd_boolean coff_write_symbol
PARAMS ((bfd *, asymbol *, combined_entry_type *, bfd_vma *,
bfd_size_type *, asection **, bfd_size_type *));
-static boolean coff_write_alien_symbol
+static bfd_boolean coff_write_alien_symbol
PARAMS ((bfd *, asymbol *, bfd_vma *, bfd_size_type *,
asection **, bfd_size_type *));
-static boolean coff_write_native_symbol
+static bfd_boolean coff_write_native_symbol
PARAMS ((bfd *, coff_symbol_type *, bfd_vma *, bfd_size_type *,
asection **, bfd_size_type *));
static void coff_pointerize_aux
PARAMS ((bfd *, combined_entry_type *, combined_entry_type *,
unsigned int, combined_entry_type *));
-static boolean make_a_section_from_file
+static bfd_boolean make_a_section_from_file
PARAMS ((bfd *, struct internal_scnhdr *, unsigned int));
static const bfd_target *coff_real_object_p
PARAMS ((bfd *, unsigned, struct internal_filehdr *,
@@ -74,7 +74,7 @@ static char *copy_name
/* Take a section header read from a coff file (in HOST byte order),
and make a BFD "section" out of it. This is used by ECOFF. */
-static boolean
+static bfd_boolean
make_a_section_from_file (abfd, hdr, target_index)
bfd *abfd;
struct internal_scnhdr *hdr;
@@ -82,7 +82,7 @@ make_a_section_from_file (abfd, hdr, target_index)
{
asection *return_section;
char *name;
- boolean result = true;
+ bfd_boolean result = TRUE;
flagword flags;
name = NULL;
@@ -103,14 +103,14 @@ make_a_section_from_file (abfd, hdr, target_index)
{
strings = _bfd_coff_read_string_table (abfd);
if (strings == NULL)
- return false;
+ return FALSE;
/* FIXME: For extra safety, we should make sure that
strindex does not run us past the end, but right now we
don't know the length of the string table. */
strings += strindex;
name = bfd_alloc (abfd, (bfd_size_type) strlen (strings) + 1);
if (name == NULL)
- return false;
+ return FALSE;
strcpy (name, strings);
}
}
@@ -120,14 +120,14 @@ make_a_section_from_file (abfd, hdr, target_index)
/* Assorted wastage to null-terminate the name, thanks AT&T! */
name = bfd_alloc (abfd, (bfd_size_type) sizeof (hdr->s_name) + 1);
if (name == NULL)
- return false;
+ return FALSE;
strncpy (name, (char *) &hdr->s_name[0], sizeof (hdr->s_name));
name[sizeof (hdr->s_name)] = 0;
}
return_section = bfd_make_section_anyway (abfd, name);
if (return_section == NULL)
- return false;
+ return FALSE;
return_section->vma = hdr->s_vaddr;
return_section->lma = hdr->s_paddr;
@@ -147,7 +147,7 @@ make_a_section_from_file (abfd, hdr, target_index)
if (! bfd_coff_styp_to_sec_flags_hook (abfd, hdr, name, return_section,
& flags))
- result = false;
+ result = FALSE;
return_section->flags = flags;
@@ -226,7 +226,7 @@ coff_real_object_p (abfd, nscns, internal_f, internal_a)
if (! bfd_coff_set_arch_mach_hook (abfd, (PTR) internal_f))
goto fail;
- /* Now copy data as required; construct all asections etc */
+ /* Now copy data as required; construct all asections etc. */
if (nscns != 0)
{
unsigned int i;
@@ -241,8 +241,6 @@ coff_real_object_p (abfd, nscns, internal_f, internal_a)
}
}
- /* make_abs_section (abfd); */
-
return abfd->xvec;
fail:
@@ -331,7 +329,7 @@ coff_section_from_bfd_index (abfd, index)
bfd *abfd;
int index;
{
- struct sec *answer = abfd->sections;
+ struct bfd_section *answer = abfd->sections;
if (index == N_ABS)
return bfd_abs_section_ptr;
@@ -367,7 +365,7 @@ coff_get_symtab_upper_bound (abfd)
/* Canonicalize a COFF symbol table. */
long
-coff_get_symtab (abfd, alocation)
+coff_canonicalize_symtab (abfd, alocation)
bfd *abfd;
asymbol **alocation;
{
@@ -423,12 +421,12 @@ _bfd_coff_internal_syment_name (abfd, sym, buf)
}
/* Read in and swap the relocs. This returns a buffer holding the
- relocs for section SEC in file ABFD. If CACHE is true and
+ relocs for section SEC in file ABFD. If CACHE is TRUE and
INTERNAL_RELOCS is NULL, the relocs read in will be saved in case
the function is called again. If EXTERNAL_RELOCS is not NULL, it
is a buffer large enough to hold the unswapped relocs. If
INTERNAL_RELOCS is not NULL, it is a buffer large enough to hold
- the swapped relocs. If REQUIRE_INTERNAL is true, then the return
+ the swapped relocs. If REQUIRE_INTERNAL is TRUE, then the return
value must be INTERNAL_RELOCS. The function returns NULL on error. */
struct internal_reloc *
@@ -436,9 +434,9 @@ _bfd_coff_read_internal_relocs (abfd, sec, cache, external_relocs,
require_internal, internal_relocs)
bfd *abfd;
asection *sec;
- boolean cache;
+ bfd_boolean cache;
bfd_byte *external_relocs;
- boolean require_internal;
+ bfd_boolean require_internal;
struct internal_reloc *internal_relocs;
{
bfd_size_type relsz;
@@ -565,7 +563,7 @@ coff_count_linenumbers (abfd)
do
{
asection * sec = q->symbol.section->output_section;
-
+
/* Do not try to update fields in read-only sections. */
if (! bfd_is_const_section (sec))
sec->lineno_count ++;
@@ -656,7 +654,7 @@ fixup_symbol_value (abfd, coff_symbol_ptr, syment)
chain, and that the last one points to the first external symbol. We
do that here too. */
-boolean
+bfd_boolean
coff_renumber_symbols (bfd_ptr, first_undef)
bfd *bfd_ptr;
int *first_undef;
@@ -685,7 +683,7 @@ coff_renumber_symbols (bfd_ptr, first_undef)
amt = sizeof (asymbol *) * ((bfd_size_type) symbol_count + 1);
newsyms = (asymbol **) bfd_alloc (bfd_ptr, amt);
if (!newsyms)
- return false;
+ return FALSE;
bfd_ptr->outsymbols = newsyms;
for (i = 0; i < symbol_count; i++)
if ((symbol_ptr_ptr[i]->flags & BSF_NOT_AT_END) != 0
@@ -748,7 +746,7 @@ coff_renumber_symbols (bfd_ptr, first_undef)
}
obj_conv_table_size (bfd_ptr) = native_index;
- return true;
+ return TRUE;
}
/* Run thorough the symbol table again, and fix it so that all
@@ -943,7 +941,7 @@ coff_fix_symbol_name (abfd, symbol, native, string_size_p,
/* Write a symbol out to a COFF file. */
-static boolean
+static bfd_boolean
coff_write_symbol (abfd, symbol, native, written, string_size_p,
debug_string_section_p, debug_string_size_p)
bfd *abfd;
@@ -988,10 +986,10 @@ coff_write_symbol (abfd, symbol, native, written, string_size_p,
symesz = bfd_coff_symesz (abfd);
buf = bfd_alloc (abfd, symesz);
if (!buf)
- return false;
+ return FALSE;
bfd_coff_swap_sym_out (abfd, &native->u.syment, buf);
if (bfd_bwrite (buf, symesz, abfd) != symesz)
- return false;
+ return FALSE;
bfd_release (abfd, buf);
if (native->u.syment.n_numaux > 0)
@@ -1002,7 +1000,7 @@ coff_write_symbol (abfd, symbol, native, written, string_size_p,
auxesz = bfd_coff_auxesz (abfd);
buf = bfd_alloc (abfd, auxesz);
if (!buf)
- return false;
+ return FALSE;
for (j = 0; j < native->u.syment.n_numaux; j++)
{
bfd_coff_swap_aux_out (abfd,
@@ -1013,7 +1011,7 @@ coff_write_symbol (abfd, symbol, native, written, string_size_p,
native->u.syment.n_numaux,
buf);
if (bfd_bwrite (buf, auxesz, abfd) != auxesz)
- return false;
+ return FALSE;
}
bfd_release (abfd, buf);
}
@@ -1022,14 +1020,14 @@ coff_write_symbol (abfd, symbol, native, written, string_size_p,
set_index (symbol, *written);
*written += numaux + 1;
- return true;
+ return TRUE;
}
/* Write out a symbol to a COFF file that does not come from a COFF
file originally. This symbol may have been created by the linker,
or we may be linking a non COFF file to a COFF file. */
-static boolean
+static bfd_boolean
coff_write_alien_symbol (abfd, symbol, written, string_size_p,
debug_string_section_p, debug_string_size_p)
bfd *abfd;
@@ -1062,7 +1060,7 @@ coff_write_alien_symbol (abfd, symbol, written, string_size_p,
format. So, we just ignore them. We must clobber the symbol
name to keep it from being put in the string table. */
symbol->name = "";
- return true;
+ return TRUE;
}
else
{
@@ -1097,7 +1095,7 @@ coff_write_alien_symbol (abfd, symbol, written, string_size_p,
/* Write a native symbol to a COFF file. */
-static boolean
+static bfd_boolean
coff_write_native_symbol (abfd, symbol, written, string_size_p,
debug_string_section_p, debug_string_size_p)
bfd *abfd;
@@ -1153,7 +1151,7 @@ coff_write_native_symbol (abfd, symbol, written, string_size_p,
#endif
count++;
}
- symbol->done_lineno = true;
+ symbol->done_lineno = TRUE;
if (! bfd_is_const_section (symbol->symbol.section->output_section))
symbol->symbol.section->output_section->moving_line_filepos +=
@@ -1167,7 +1165,7 @@ coff_write_native_symbol (abfd, symbol, written, string_size_p,
/* Write out the COFF symbols. */
-boolean
+bfd_boolean
coff_write_symbols (abfd)
bfd *abfd;
{
@@ -1203,7 +1201,7 @@ coff_write_symbols (abfd)
/* Seek to the right place */
if (bfd_seek (abfd, obj_sym_filepos (abfd), SEEK_SET) != 0)
- return false;
+ return FALSE;
/* Output all the symbols we have */
@@ -1219,14 +1217,14 @@ coff_write_symbols (abfd)
if (!coff_write_alien_symbol (abfd, symbol, &written, &string_size,
&debug_string_section,
&debug_string_size))
- return false;
+ return FALSE;
}
else
{
if (!coff_write_native_symbol (abfd, c_symbol, &written,
&string_size, &debug_string_section,
&debug_string_size))
- return false;
+ return FALSE;
}
}
@@ -1246,7 +1244,7 @@ coff_write_symbols (abfd)
#endif
if (bfd_bwrite ((PTR) buffer, (bfd_size_type) sizeof (buffer), abfd)
!= sizeof (buffer))
- return false;
+ return FALSE;
/* Handle long section names. This code must handle section
names just as they are handled in coff_write_object_contents. */
@@ -1263,7 +1261,7 @@ coff_write_symbols (abfd)
{
if (bfd_bwrite (o->name, (bfd_size_type) (len + 1), abfd)
!= len + 1)
- return false;
+ return FALSE;
}
}
}
@@ -1304,7 +1302,7 @@ coff_write_symbols (abfd)
if (bfd_coff_force_symnames_in_strings (abfd))
{
if (bfd_bwrite (".file", (bfd_size_type) 6, abfd) != 6)
- return false;
+ return FALSE;
}
maxlen = bfd_coff_filnmlen (abfd);
}
@@ -1315,7 +1313,7 @@ coff_write_symbols (abfd)
{
if (bfd_bwrite ((PTR) (q->name), (bfd_size_type) name_length + 1,
abfd) != name_length + 1)
- return false;
+ return FALSE;
}
}
}
@@ -1334,7 +1332,7 @@ coff_write_symbols (abfd)
#endif
if (bfd_bwrite ((PTR) buffer, (bfd_size_type) STRING_SIZE_SIZE, abfd)
!= STRING_SIZE_SIZE)
- return false;
+ return FALSE;
}
/* Make sure the .debug section was created to be the correct size.
@@ -1348,10 +1346,10 @@ coff_write_symbols (abfd)
1 << debug_string_section->alignment_power)
== bfd_section_size (abfd, debug_string_section))));
- return true;
+ return TRUE;
}
-boolean
+bfd_boolean
coff_write_linenumbers (abfd)
bfd *abfd;
{
@@ -1362,14 +1360,14 @@ coff_write_linenumbers (abfd)
linesz = bfd_coff_linesz (abfd);
buff = bfd_alloc (abfd, linesz);
if (!buff)
- return false;
+ return FALSE;
for (s = abfd->sections; s != (asection *) NULL; s = s->next)
{
if (s->lineno_count)
{
asymbol **q = abfd->outsymbols;
if (bfd_seek (abfd, s->line_filepos, SEEK_SET) != 0)
- return false;
+ return FALSE;
/* Find all the linenumbers in this section */
while (*q)
{
@@ -1389,7 +1387,7 @@ coff_write_linenumbers (abfd)
bfd_coff_swap_lineno_out (abfd, &out, buff);
if (bfd_bwrite (buff, (bfd_size_type) linesz, abfd)
!= linesz)
- return false;
+ return FALSE;
l++;
while (l->line_number)
{
@@ -1398,7 +1396,7 @@ coff_write_linenumbers (abfd)
bfd_coff_swap_lineno_out (abfd, &out, buff);
if (bfd_bwrite (buff, (bfd_size_type) linesz, abfd)
!= linesz)
- return false;
+ return FALSE;
l++;
}
}
@@ -1408,7 +1406,7 @@ coff_write_linenumbers (abfd)
}
}
bfd_release (abfd, buff);
- return true;
+ return TRUE;
}
alent *
@@ -1585,7 +1583,7 @@ copy_name (abfd, name, maxlen)
/* Read in the external symbols. */
-boolean
+bfd_boolean
_bfd_coff_get_external_symbols (abfd)
bfd *abfd;
{
@@ -1594,7 +1592,7 @@ _bfd_coff_get_external_symbols (abfd)
PTR syms;
if (obj_coff_external_syms (abfd) != NULL)
- return true;
+ return TRUE;
symesz = bfd_coff_symesz (abfd);
@@ -1602,19 +1600,19 @@ _bfd_coff_get_external_symbols (abfd)
syms = (PTR) bfd_malloc (size);
if (syms == NULL && size != 0)
- return false;
+ return FALSE;
if (bfd_seek (abfd, obj_sym_filepos (abfd), SEEK_SET) != 0
|| bfd_bread (syms, size, abfd) != size)
{
if (syms != NULL)
free (syms);
- return false;
+ return FALSE;
}
obj_coff_external_syms (abfd) = syms;
- return true;
+ return TRUE;
}
/* Read in the external strings. The strings are not loaded until
@@ -1689,7 +1687,7 @@ _bfd_coff_read_string_table (abfd)
/* Free up the external symbols and strings read from a COFF file. */
-boolean
+bfd_boolean
_bfd_coff_free_symbols (abfd)
bfd *abfd;
{
@@ -1705,7 +1703,7 @@ _bfd_coff_free_symbols (abfd)
free (obj_coff_strings (abfd));
obj_coff_strings (abfd) = NULL;
}
- return true;
+ return TRUE;
}
/* Read a symbol table into freshly bfd_allocated memory, swap it, and
@@ -1777,7 +1775,7 @@ coff_get_normalized_symtab (abfd)
}
/* Free the raw symbols, but not the strings (if we have them). */
- obj_coff_keep_strings (abfd) = true;
+ obj_coff_keep_strings (abfd) = TRUE;
if (! _bfd_coff_free_symbols (abfd))
return NULL;
@@ -1909,7 +1907,7 @@ coff_make_empty_symbol (abfd)
new->symbol.section = 0;
new->native = 0;
new->lineno = (alent *) NULL;
- new->done_lineno = false;
+ new->done_lineno = FALSE;
new->symbol.the_bfd = abfd;
return &new->symbol;
}
@@ -1935,7 +1933,7 @@ coff_bfd_make_debug_symbol (abfd, ptr, sz)
new->symbol.section = bfd_abs_section_ptr;
new->symbol.flags = BSF_DEBUGGING;
new->lineno = (alent *) NULL;
- new->done_lineno = false;
+ new->done_lineno = FALSE;
new->symbol.the_bfd = abfd;
return &new->symbol;
}
@@ -1957,7 +1955,7 @@ coff_get_symbol_info (abfd, symbol, ret)
/* Return the COFF syment for a symbol. */
-boolean
+bfd_boolean
bfd_coff_get_syment (abfd, symbol, psyment)
bfd *abfd;
asymbol *symbol;
@@ -1969,7 +1967,7 @@ bfd_coff_get_syment (abfd, symbol, psyment)
if (csym == NULL || csym->native == NULL)
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
*psyment = csym->native->u.syment;
@@ -1980,12 +1978,12 @@ bfd_coff_get_syment (abfd, symbol, psyment)
/* FIXME: We should handle fix_line here. */
- return true;
+ return TRUE;
}
/* Return the COFF auxent for a symbol. */
-boolean
+bfd_boolean
bfd_coff_get_auxent (abfd, symbol, indx, pauxent)
bfd *abfd;
asymbol *symbol;
@@ -2002,7 +2000,7 @@ bfd_coff_get_auxent (abfd, symbol, indx, pauxent)
|| indx >= csym->native->u.syment.n_numaux)
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
ent = csym->native + indx + 1;
@@ -2024,7 +2022,7 @@ bfd_coff_get_auxent (abfd, symbol, indx, pauxent)
((combined_entry_type *) pauxent->x_csect.x_scnlen.p
- obj_raw_syments (abfd));
- return true;
+ return TRUE;
}
/* Print out information about COFF symbol. */
@@ -2191,19 +2189,19 @@ coff_print_symbol (abfd, filep, symbol, how)
function for the is_local_label_name entry point, but some may
override it. */
-boolean
+bfd_boolean
_bfd_coff_is_local_label_name (abfd, name)
bfd *abfd ATTRIBUTE_UNUSED;
const char *name;
{
- return (boolean) (name[0] == '.' && name[1] == 'L');
+ return name[0] == '.' && name[1] == 'L';
}
/* Provided a BFD, a section and an offset (in bytes, not octets) into the
section, calculate and return the name of the source file and the line
nearest to the wanted location. */
-boolean
+bfd_boolean
coff_find_nearest_line (abfd, section, symbols, offset, filename_ptr,
functionname_ptr, line_ptr)
bfd *abfd;
@@ -2214,7 +2212,7 @@ coff_find_nearest_line (abfd, section, symbols, offset, filename_ptr,
const char **functionname_ptr;
unsigned int *line_ptr;
{
- boolean found;
+ bfd_boolean found;
unsigned int i;
unsigned int line_base;
coff_data_type *cof = coff_data (abfd);
@@ -2231,17 +2229,17 @@ coff_find_nearest_line (abfd, section, symbols, offset, filename_ptr,
&found, filename_ptr,
functionname_ptr, line_ptr,
&coff_data(abfd)->line_info))
- return false;
+ return FALSE;
if (found)
- return true;
+ return TRUE;
/* Also try examining DWARF2 debugging information. */
if (_bfd_dwarf2_find_nearest_line (abfd, section, symbols, offset,
filename_ptr, functionname_ptr,
line_ptr, 0,
&coff_data(abfd)->dwarf2_find_line_info))
- return true;
+ return TRUE;
*filename_ptr = 0;
*functionname_ptr = 0;
@@ -2249,15 +2247,15 @@ coff_find_nearest_line (abfd, section, symbols, offset, filename_ptr,
/* Don't try and find line numbers in a non coff file */
if (!bfd_family_coff (abfd))
- return false;
+ return FALSE;
if (cof == NULL)
- return false;
+ return FALSE;
/* Find the first C_FILE symbol. */
p = cof->raw_syments;
if (!p)
- return false;
+ return FALSE;
pend = p + cof->raw_syment_count;
while (p < pend)
@@ -2410,13 +2408,13 @@ coff_find_nearest_line (abfd, section, symbols, offset, filename_ptr,
sec_data->line_base = line_base;
}
- return true;
+ return TRUE;
}
int
coff_sizeof_headers (abfd, reloc)
bfd *abfd;
- boolean reloc;
+ bfd_boolean reloc;
{
size_t size;
@@ -2434,7 +2432,7 @@ coff_sizeof_headers (abfd, reloc)
}
/* Change the class of a coff symbol held by BFD. */
-boolean
+bfd_boolean
bfd_coff_set_symbol_class (abfd, symbol, class)
bfd * abfd;
asymbol * symbol;
@@ -2446,7 +2444,7 @@ bfd_coff_set_symbol_class (abfd, symbol, class)
if (csym == NULL)
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
else if (csym->native == NULL)
{
@@ -2460,7 +2458,7 @@ bfd_coff_set_symbol_class (abfd, symbol, class)
native = (combined_entry_type *) bfd_zalloc (abfd, amt);
if (native == NULL)
- return false;
+ return FALSE;
native->u.syment.n_type = T_NULL;
native->u.syment.n_sclass = class;
@@ -2496,5 +2494,5 @@ bfd_coff_set_symbol_class (abfd, symbol, class)
csym->native->u.syment.n_sclass = class;
}
- return true;
+ return TRUE;
}
diff --git a/contrib/binutils/bfd/cofflink.c b/contrib/binutils/bfd/cofflink.c
index c1302ee..4ad566c 100644
--- a/contrib/binutils/bfd/cofflink.c
+++ b/contrib/binutils/bfd/cofflink.c
@@ -1,23 +1,23 @@
/* COFF specific linker code.
- Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
+ Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* This file contains the COFF backend linker code. */
@@ -27,26 +27,18 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "libbfd.h"
#include "coff/internal.h"
#include "libcoff.h"
+#include "safe-ctype.h"
-static boolean coff_link_add_object_symbols
- PARAMS ((bfd *, struct bfd_link_info *));
-static boolean coff_link_check_archive_element
- PARAMS ((bfd *, struct bfd_link_info *, boolean *));
-static boolean coff_link_check_ar_symbols
- PARAMS ((bfd *, struct bfd_link_info *, boolean *));
-static boolean coff_link_add_symbols PARAMS ((bfd *, struct bfd_link_info *));
-static char *dores_com PARAMS ((char *, bfd *, int));
-static char *get_name PARAMS ((char *, char **));
-static int process_embedded_commands
- PARAMS ((bfd *, struct bfd_link_info *, bfd *));
-static void mark_relocs PARAMS ((struct coff_final_link_info *, bfd *));
-
-/* Return true if SYM is a weak, external symbol. */
+static bfd_boolean coff_link_add_object_symbols (bfd *abfd, struct bfd_link_info *info);
+static bfd_boolean coff_link_check_archive_element (bfd *abfd, struct bfd_link_info *info, bfd_boolean *pneeded);
+static bfd_boolean coff_link_add_symbols (bfd *abfd, struct bfd_link_info *info);
+
+/* Return TRUE if SYM is a weak, external symbol. */
#define IS_WEAK_EXTERNAL(abfd, sym) \
((sym).n_sclass == C_WEAKEXT \
|| (obj_pe (abfd) && (sym).n_sclass == C_NT_WEAK))
-/* Return true if SYM is an external symbol. */
+/* Return TRUE if SYM is an external symbol. */
#define IS_EXTERNAL(abfd, sym) \
((sym).n_sclass == C_EXT || IS_WEAK_EXTERNAL (abfd, sym))
@@ -63,10 +55,9 @@ static void mark_relocs PARAMS ((struct coff_final_link_info *, bfd *));
/* Create an entry in a COFF linker hash table. */
struct bfd_hash_entry *
-_bfd_coff_link_hash_newfunc (entry, table, string)
- struct bfd_hash_entry *entry;
- struct bfd_hash_table *table;
- const char *string;
+_bfd_coff_link_hash_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table,
+ const char *string)
{
struct coff_link_hash_entry *ret = (struct coff_link_hash_entry *) entry;
@@ -98,13 +89,12 @@ _bfd_coff_link_hash_newfunc (entry, table, string)
/* Initialize a COFF linker hash table. */
-boolean
-_bfd_coff_link_hash_table_init (table, abfd, newfunc)
- struct coff_link_hash_table *table;
- bfd *abfd;
- struct bfd_hash_entry *(*newfunc) PARAMS ((struct bfd_hash_entry *,
- struct bfd_hash_table *,
- const char *));
+bfd_boolean
+_bfd_coff_link_hash_table_init (struct coff_link_hash_table *table,
+ bfd *abfd,
+ struct bfd_hash_entry *(*newfunc) (struct bfd_hash_entry *,
+ struct bfd_hash_table *,
+ const char *))
{
table->stab_info = NULL;
return _bfd_link_hash_table_init (&table->root, abfd, newfunc);
@@ -113,15 +103,15 @@ _bfd_coff_link_hash_table_init (table, abfd, newfunc)
/* Create a COFF linker hash table. */
struct bfd_link_hash_table *
-_bfd_coff_link_hash_table_create (abfd)
- bfd *abfd;
+_bfd_coff_link_hash_table_create (bfd *abfd)
{
struct coff_link_hash_table *ret;
bfd_size_type amt = sizeof (struct coff_link_hash_table);
- ret = (struct coff_link_hash_table *) bfd_malloc (amt);
+ ret = bfd_malloc (amt);
if (ret == NULL)
return NULL;
+
if (! _bfd_coff_link_hash_table_init (ret, abfd,
_bfd_coff_link_hash_newfunc))
{
@@ -134,10 +124,9 @@ _bfd_coff_link_hash_table_create (abfd)
/* Create an entry in a COFF debug merge hash table. */
struct bfd_hash_entry *
-_bfd_coff_debug_merge_hash_newfunc (entry, table, string)
- struct bfd_hash_entry *entry;
- struct bfd_hash_table *table;
- const char *string;
+_bfd_coff_debug_merge_hash_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table,
+ const char *string)
{
struct coff_debug_merge_hash_entry *ret =
(struct coff_debug_merge_hash_entry *) entry;
@@ -166,90 +155,52 @@ _bfd_coff_debug_merge_hash_newfunc (entry, table, string)
/* Given a COFF BFD, add symbols to the global hash table as
appropriate. */
-boolean
-_bfd_coff_link_add_symbols (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info;
+bfd_boolean
+_bfd_coff_link_add_symbols (bfd *abfd, struct bfd_link_info *info)
{
switch (bfd_get_format (abfd))
{
case bfd_object:
return coff_link_add_object_symbols (abfd, info);
case bfd_archive:
- return (_bfd_generic_link_add_archive_symbols
- (abfd, info, coff_link_check_archive_element));
+ return _bfd_generic_link_add_archive_symbols
+ (abfd, info, coff_link_check_archive_element);
default:
bfd_set_error (bfd_error_wrong_format);
- return false;
+ return FALSE;
}
}
/* Add symbols from a COFF object file. */
-static boolean
-coff_link_add_object_symbols (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info;
+static bfd_boolean
+coff_link_add_object_symbols (bfd *abfd, struct bfd_link_info *info)
{
if (! _bfd_coff_get_external_symbols (abfd))
- return false;
+ return FALSE;
if (! coff_link_add_symbols (abfd, info))
- return false;
-
- if (! info->keep_memory)
- {
- if (! _bfd_coff_free_symbols (abfd))
- return false;
- }
- return true;
-}
-
-/* Check a single archive element to see if we need to include it in
- the link. *PNEEDED is set according to whether this element is
- needed in the link or not. This is called via
- _bfd_generic_link_add_archive_symbols. */
-
-static boolean
-coff_link_check_archive_element (abfd, info, pneeded)
- bfd *abfd;
- struct bfd_link_info *info;
- boolean *pneeded;
-{
- if (! _bfd_coff_get_external_symbols (abfd))
- return false;
+ return FALSE;
- if (! coff_link_check_ar_symbols (abfd, info, pneeded))
- return false;
-
- if (*pneeded)
- {
- if (! coff_link_add_symbols (abfd, info))
- return false;
- }
-
- if (! info->keep_memory || ! *pneeded)
- {
- if (! _bfd_coff_free_symbols (abfd))
- return false;
- }
+ if (! info->keep_memory
+ && ! _bfd_coff_free_symbols (abfd))
+ return FALSE;
- return true;
+ return TRUE;
}
/* Look through the symbols to see if this object file should be
included in the link. */
-static boolean
-coff_link_check_ar_symbols (abfd, info, pneeded)
- bfd *abfd;
- struct bfd_link_info *info;
- boolean *pneeded;
+static bfd_boolean
+coff_link_check_ar_symbols (bfd *abfd,
+ struct bfd_link_info *info,
+ bfd_boolean *pneeded)
{
bfd_size_type symesz;
bfd_byte *esym;
bfd_byte *esym_end;
- *pneeded = false;
+ *pneeded = FALSE;
symesz = bfd_coff_symesz (abfd);
esym = (bfd_byte *) obj_coff_external_syms (abfd);
@@ -259,7 +210,7 @@ coff_link_check_ar_symbols (abfd, info, pneeded)
struct internal_syment sym;
enum coff_symbol_classification classification;
- bfd_coff_swap_sym_in (abfd, (PTR) esym, (PTR) &sym);
+ bfd_coff_swap_sym_in (abfd, esym, &sym);
classification = bfd_coff_classify_symbol (abfd, &sym);
if (classification == COFF_SYMBOL_GLOBAL
@@ -271,22 +222,17 @@ coff_link_check_ar_symbols (abfd, info, pneeded)
/* This symbol is externally visible, and is defined by this
object file. */
-
name = _bfd_coff_internal_syment_name (abfd, &sym, buf);
if (name == NULL)
- return false;
- h = bfd_link_hash_lookup (info->hash, name, false, false, true);
+ return FALSE;
+ h = bfd_link_hash_lookup (info->hash, name, FALSE, FALSE, TRUE);
+
+ /* Auto import. */
+ if (!h
+ && info->pei386_auto_import
+ && !strncmp (name,"__imp_", 6))
+ h = bfd_link_hash_lookup (info->hash, name + 6, FALSE, FALSE, TRUE);
- /* auto import */
- if (!h && info->pei386_auto_import)
- {
- if (!strncmp (name,"__imp_", 6))
- {
- h =
- bfd_link_hash_lookup (info->hash, name + 6, false, false,
- true);
- }
- }
/* We are only interested in symbols that are currently
undefined. If a symbol is currently known to be common,
COFF linkers do not bring in an object file which defines
@@ -295,9 +241,9 @@ coff_link_check_ar_symbols (abfd, info, pneeded)
&& h->type == bfd_link_hash_undefined)
{
if (! (*info->callbacks->add_archive_element) (info, abfd, name))
- return false;
- *pneeded = true;
- return true;
+ return FALSE;
+ *pneeded = TRUE;
+ return TRUE;
}
}
@@ -305,21 +251,47 @@ coff_link_check_ar_symbols (abfd, info, pneeded)
}
/* We do not need this object file. */
- return true;
+ return TRUE;
+}
+
+/* Check a single archive element to see if we need to include it in
+ the link. *PNEEDED is set according to whether this element is
+ needed in the link or not. This is called via
+ _bfd_generic_link_add_archive_symbols. */
+
+static bfd_boolean
+coff_link_check_archive_element (bfd *abfd,
+ struct bfd_link_info *info,
+ bfd_boolean *pneeded)
+{
+ if (! _bfd_coff_get_external_symbols (abfd))
+ return FALSE;
+
+ if (! coff_link_check_ar_symbols (abfd, info, pneeded))
+ return FALSE;
+
+ if (*pneeded
+ && ! coff_link_add_symbols (abfd, info))
+ return FALSE;
+
+ if ((! info->keep_memory || ! *pneeded)
+ && ! _bfd_coff_free_symbols (abfd))
+ return FALSE;
+
+ return TRUE;
}
/* Add all the symbols from an object file to the hash table. */
-static boolean
-coff_link_add_symbols (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info;
+static bfd_boolean
+coff_link_add_symbols (bfd *abfd,
+ struct bfd_link_info *info)
{
unsigned int n_tmask = coff_data (abfd)->local_n_tmask;
unsigned int n_btshft = coff_data (abfd)->local_n_btshft;
unsigned int n_btmask = coff_data (abfd)->local_n_btmask;
- boolean keep_syms;
- boolean default_copy;
+ bfd_boolean keep_syms;
+ bfd_boolean default_copy;
bfd_size_type symcount;
struct coff_link_hash_entry **sym_hash;
bfd_size_type symesz;
@@ -330,19 +302,19 @@ coff_link_add_symbols (abfd, info)
/* Keep the symbols during this function, in case the linker needs
to read the generic symbols in order to report an error message. */
keep_syms = obj_coff_keep_syms (abfd);
- obj_coff_keep_syms (abfd) = true;
+ obj_coff_keep_syms (abfd) = TRUE;
if (info->keep_memory)
- default_copy = false;
+ default_copy = FALSE;
else
- default_copy = true;
+ default_copy = TRUE;
symcount = obj_raw_syment_count (abfd);
/* We keep a list of the linker hash table entries that correspond
to particular symbols. */
amt = symcount * sizeof (struct coff_link_hash_entry *);
- sym_hash = (struct coff_link_hash_entry **) bfd_zalloc (abfd, amt);
+ sym_hash = bfd_zalloc (abfd, amt);
if (sym_hash == NULL && symcount != 0)
goto error_return;
obj_coff_sym_hashes (abfd) = sym_hash;
@@ -355,9 +327,9 @@ coff_link_add_symbols (abfd, info)
{
struct internal_syment sym;
enum coff_symbol_classification classification;
- boolean copy;
+ bfd_boolean copy;
- bfd_coff_swap_sym_in (abfd, (PTR) esym, (PTR) &sym);
+ bfd_coff_swap_sym_in (abfd, esym, &sym);
classification = bfd_coff_classify_symbol (abfd, &sym);
if (classification != COFF_SYMBOL_LOCAL)
@@ -367,7 +339,7 @@ coff_link_add_symbols (abfd, info)
flagword flags;
asection *section;
bfd_vma value;
- boolean addit;
+ bfd_boolean addit;
/* This symbol is externally visible. */
@@ -380,7 +352,7 @@ coff_link_add_symbols (abfd, info)
copy = default_copy;
if (sym._n._n_n._n_zeroes != 0
|| sym._n._n_n._n_offset == 0)
- copy = true;
+ copy = TRUE;
value = sym.n_value;
@@ -415,7 +387,7 @@ coff_link_add_symbols (abfd, info)
if (IS_WEAK_EXTERNAL (abfd, sym))
flags = BSF_WEAK;
- addit = true;
+ addit = TRUE;
/* In the PE format, section symbols actually refer to the
start of the output section. We handle them specially
@@ -423,7 +395,7 @@ coff_link_add_symbols (abfd, info)
if (obj_pe (abfd) && (flags & BSF_SECTION_SYM) != 0)
{
*sym_hash = coff_link_hash_lookup (coff_hash_table (info),
- name, false, copy, false);
+ name, FALSE, copy, FALSE);
if (*sym_hash != NULL)
{
if (((*sym_hash)->coff_link_hash_flags
@@ -434,7 +406,7 @@ coff_link_add_symbols (abfd, info)
("Warning: symbol `%s' is both section and non-section",
name);
- addit = false;
+ addit = FALSE;
}
}
@@ -469,20 +441,20 @@ coff_link_add_symbols (abfd, info)
{
if (*sym_hash == NULL)
*sym_hash = coff_link_hash_lookup (coff_hash_table (info),
- name, false, copy, false);
+ name, FALSE, copy, FALSE);
if (*sym_hash != NULL
&& (*sym_hash)->root.type == bfd_link_hash_defined
&& (*sym_hash)->root.u.def.section->comdat != NULL
&& strcmp ((*sym_hash)->root.u.def.section->comdat->name,
section->comdat->name) == 0)
- addit = false;
+ addit = FALSE;
}
if (addit)
{
if (! (bfd_coff_link_add_one_symbol
(info, abfd, name, flags, section, value,
- (const char *) NULL, copy, false,
+ (const char *) NULL, copy, FALSE,
(struct bfd_link_hash_entry **) sym_hash)))
goto error_return;
}
@@ -560,9 +532,9 @@ coff_link_add_symbols (abfd, info)
for (i = 0, eaux = esym + symesz, iaux = alloc;
i < sym.n_numaux;
i++, eaux += symesz, iaux++)
- bfd_coff_swap_aux_in (abfd, (PTR) eaux, sym.n_type,
+ bfd_coff_swap_aux_in (abfd, eaux, sym.n_type,
sym.n_sclass, (int) i,
- sym.n_numaux, (PTR) iaux);
+ sym.n_numaux, iaux);
(*sym_hash)->aux = alloc;
}
}
@@ -578,7 +550,6 @@ coff_link_add_symbols (abfd, info)
FIXME: This is not at all the right place to do this.
For example, it won't help objdump. This needs to be
done when we swap in the section header. */
-
BFD_ASSERT ((*sym_hash)->numaux == 1);
if (section->_raw_size == 0)
section->_raw_size = (*sym_hash)->aux[0].x_scn.x_scnlen;
@@ -593,30 +564,35 @@ coff_link_add_symbols (abfd, info)
sym_hash += sym.n_numaux + 1;
}
- /* If this is a non-traditional, non-relocateable link, try to
+ /* If this is a non-traditional, non-relocatable link, try to
optimize the handling of any .stab/.stabstr sections. */
- if (! info->relocateable
+ if (! info->relocatable
&& ! info->traditional_format
&& info->hash->creator->flavour == bfd_get_flavour (abfd)
&& (info->strip != strip_all && info->strip != strip_debugger))
{
- asection *stab, *stabstr;
+ asection *stabstr;
- stab = bfd_get_section_by_name (abfd, ".stab");
- if (stab != NULL)
- {
- stabstr = bfd_get_section_by_name (abfd, ".stabstr");
+ stabstr = bfd_get_section_by_name (abfd, ".stabstr");
- if (stabstr != NULL)
+ if (stabstr != NULL)
+ {
+ bfd_size_type string_offset = 0;
+ asection *stab;
+
+ for (stab = abfd->sections; stab; stab = stab->next)
+ if (strncmp (".stab", stab->name, 5) == 0
+ && (!stab->name[5]
+ || (stab->name[5] == '.' && ISDIGIT (stab->name[6]))))
{
struct coff_link_hash_table *table;
- struct coff_section_tdata *secdata;
-
- secdata = coff_section_data (abfd, stab);
+ struct coff_section_tdata *secdata
+ = coff_section_data (abfd, stab);
+
if (secdata == NULL)
{
amt = sizeof (struct coff_section_tdata);
- stab->used_by_bfd = (PTR) bfd_zalloc (abfd, amt);
+ stab->used_by_bfd = bfd_zalloc (abfd, amt);
if (stab->used_by_bfd == NULL)
goto error_return;
secdata = coff_section_data (abfd, stab);
@@ -626,7 +602,8 @@ coff_link_add_symbols (abfd, info)
if (! _bfd_link_section_stabs (abfd, &table->stab_info,
stab, stabstr,
- &secdata->stab_info))
+ &secdata->stab_info,
+ &string_offset))
goto error_return;
}
}
@@ -634,24 +611,23 @@ coff_link_add_symbols (abfd, info)
obj_coff_keep_syms (abfd) = keep_syms;
- return true;
+ return TRUE;
error_return:
obj_coff_keep_syms (abfd) = keep_syms;
- return false;
+ return FALSE;
}
/* Do the final link step. */
-boolean
-_bfd_coff_final_link (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info;
+bfd_boolean
+_bfd_coff_final_link (bfd *abfd,
+ struct bfd_link_info *info)
{
bfd_size_type symesz;
struct coff_final_link_info finfo;
- boolean debug_merge_allocated;
- boolean long_section_names;
+ bfd_boolean debug_merge_allocated;
+ bfd_boolean long_section_names;
asection *o;
struct bfd_link_order *p;
bfd_size_type max_sym_count;
@@ -684,8 +660,8 @@ _bfd_coff_final_link (abfd, info)
finfo.contents = NULL;
finfo.external_relocs = NULL;
finfo.internal_relocs = NULL;
- finfo.global_to_static = false;
- debug_merge_allocated = false;
+ finfo.global_to_static = FALSE;
+ debug_merge_allocated = FALSE;
coff_data (abfd)->link_info = info;
@@ -695,7 +671,7 @@ _bfd_coff_final_link (abfd, info)
if (! coff_debug_merge_hash_table_init (&finfo.debug_merge))
goto error_return;
- debug_merge_allocated = true;
+ debug_merge_allocated = TRUE;
/* Compute the file positions for all the sections. */
if (! abfd->output_has_begun)
@@ -712,7 +688,7 @@ _bfd_coff_final_link (abfd, info)
max_lineno_count = 0;
max_reloc_count = 0;
- long_section_names = false;
+ long_section_names = FALSE;
for (o = abfd->sections; o != NULL; o = o->next)
{
o->reloc_count = 0;
@@ -729,13 +705,13 @@ _bfd_coff_final_link (abfd, info)
link. This will normally be every section. We need
to do this so that we can identify any sections which
the linker has decided to not include. */
- sec->linker_mark = true;
+ sec->linker_mark = TRUE;
if (info->strip == strip_none
|| info->strip == strip_some)
o->lineno_count += sec->lineno_count;
- if (info->relocateable)
+ if (info->relocatable)
o->reloc_count += sec->reloc_count;
if (sec->_raw_size > max_contents_size)
@@ -745,7 +721,7 @@ _bfd_coff_final_link (abfd, info)
if (sec->reloc_count > max_reloc_count)
max_reloc_count = sec->reloc_count;
}
- else if (info->relocateable
+ else if (info->relocatable
&& (p->type == bfd_section_reloc_link_order
|| p->type == bfd_symbol_reloc_link_order))
++o->reloc_count;
@@ -770,17 +746,17 @@ _bfd_coff_final_link (abfd, info)
table. This must correspond to the code in
coff_write_object_contents which puts the string index
into the s_name field of the section header. That is why
- we pass hash as false. */
- if (_bfd_stringtab_add (finfo.strtab, o->name, false, false)
+ we pass hash as FALSE. */
+ if (_bfd_stringtab_add (finfo.strtab, o->name, FALSE, FALSE)
== (bfd_size_type) -1)
goto error_return;
- long_section_names = true;
+ long_section_names = TRUE;
}
}
- /* If doing a relocateable link, allocate space for the pointers we
+ /* If doing a relocatable link, allocate space for the pointers we
need to keep. */
- if (info->relocateable)
+ if (info->relocatable)
{
unsigned int i;
@@ -788,7 +764,7 @@ _bfd_coff_final_link (abfd, info)
the target_index fields are 1 based. */
amt = abfd->section_count + 1;
amt *= sizeof (struct coff_link_section_info);
- finfo.section_info = (struct coff_link_section_info *) bfd_malloc (amt);
+ finfo.section_info = bfd_malloc (amt);
if (finfo.section_info == NULL)
goto error_return;
for (i = 0; i <= abfd->section_count; i++)
@@ -826,17 +802,15 @@ _bfd_coff_final_link (abfd, info)
Because of this problem, we also keep the relocs in
memory until the end of the link. This wastes memory,
- but only when doing a relocateable link, which is not the
+ but only when doing a relocatable link, which is not the
common case. */
- BFD_ASSERT (info->relocateable);
+ BFD_ASSERT (info->relocatable);
amt = o->reloc_count;
amt *= sizeof (struct internal_reloc);
- finfo.section_info[o->target_index].relocs =
- (struct internal_reloc *) bfd_malloc (amt);
+ finfo.section_info[o->target_index].relocs = bfd_malloc (amt);
amt = o->reloc_count;
amt *= sizeof (struct coff_link_hash_entry *);
- finfo.section_info[o->target_index].rel_hashes =
- (struct coff_link_hash_entry **) bfd_malloc (amt);
+ finfo.section_info[o->target_index].rel_hashes = bfd_malloc (amt);
if (finfo.section_info[o->target_index].relocs == NULL
|| finfo.section_info[o->target_index].rel_hashes == NULL)
goto error_return;
@@ -861,7 +835,7 @@ _bfd_coff_final_link (abfd, info)
{
size_t sz;
- sub->output_has_begun = false;
+ sub->output_has_begun = FALSE;
sz = obj_raw_syment_count (sub);
if (sz > max_sym_count)
max_sym_count = sz;
@@ -869,21 +843,21 @@ _bfd_coff_final_link (abfd, info)
/* Allocate some buffers used while linking. */
amt = max_sym_count * sizeof (struct internal_syment);
- finfo.internal_syms = (struct internal_syment *) bfd_malloc (amt);
+ finfo.internal_syms = bfd_malloc (amt);
amt = max_sym_count * sizeof (asection *);
- finfo.sec_ptrs = (asection **) bfd_malloc (amt);
+ finfo.sec_ptrs = bfd_malloc (amt);
amt = max_sym_count * sizeof (long);
- finfo.sym_indices = (long *) bfd_malloc (amt);
- finfo.outsyms = (bfd_byte *) bfd_malloc ((max_sym_count + 1) * symesz);
+ finfo.sym_indices = bfd_malloc (amt);
+ finfo.outsyms = bfd_malloc ((max_sym_count + 1) * symesz);
amt = max_lineno_count * bfd_coff_linesz (abfd);
- finfo.linenos = (bfd_byte *) bfd_malloc (amt);
- finfo.contents = (bfd_byte *) bfd_malloc (max_contents_size);
+ finfo.linenos = bfd_malloc (amt);
+ finfo.contents = bfd_malloc (max_contents_size);
amt = max_reloc_count * relsz;
- finfo.external_relocs = (bfd_byte *) bfd_malloc (amt);
- if (! info->relocateable)
+ finfo.external_relocs = bfd_malloc (amt);
+ if (! info->relocatable)
{
amt = max_reloc_count * sizeof (struct internal_reloc);
- finfo.internal_relocs = (struct internal_reloc *) bfd_malloc (amt);
+ finfo.internal_relocs = bfd_malloc (amt);
}
if ((finfo.internal_syms == NULL && max_sym_count > 0)
|| (finfo.sec_ptrs == NULL && max_sym_count > 0)
@@ -892,7 +866,7 @@ _bfd_coff_final_link (abfd, info)
|| (finfo.linenos == NULL && max_lineno_count > 0)
|| (finfo.contents == NULL && max_contents_size > 0)
|| (finfo.external_relocs == NULL && max_reloc_count > 0)
- || (! info->relocateable
+ || (! info->relocatable
&& finfo.internal_relocs == NULL
&& max_reloc_count > 0))
goto error_return;
@@ -922,7 +896,7 @@ _bfd_coff_final_link (abfd, info)
{
if (! _bfd_coff_link_input_bfd (&finfo, sub))
goto error_return;
- sub->output_has_begun = true;
+ sub->output_has_begun = TRUE;
}
}
else if (p->type == bfd_section_reloc_link_order
@@ -945,7 +919,7 @@ _bfd_coff_final_link (abfd, info)
/* Free up the buffers used by _bfd_coff_link_input_bfd. */
coff_debug_merge_hash_table_free (&finfo.debug_merge);
- debug_merge_allocated = false;
+ debug_merge_allocated = FALSE;
if (finfo.internal_syms != NULL)
{
@@ -992,13 +966,13 @@ _bfd_coff_final_link (abfd, info)
file_ptr pos;
finfo.last_file.n_value = obj_raw_syment_count (abfd);
- bfd_coff_swap_sym_out (abfd, (PTR) &finfo.last_file,
- (PTR) finfo.outsyms);
+ bfd_coff_swap_sym_out (abfd, &finfo.last_file,
+ finfo.outsyms);
pos = obj_sym_filepos (abfd) + finfo.last_file_index * symesz;
if (bfd_seek (abfd, pos, SEEK_SET) != 0
|| bfd_bwrite (finfo.outsyms, symesz, abfd) != symesz)
- return false;
+ return FALSE;
}
/* If doing task linking (ld --task-link) then make a pass through the
@@ -1006,19 +980,17 @@ _bfd_coff_final_link (abfd, info)
static. */
if (info->task_link)
{
- finfo.failed = false;
+ finfo.failed = FALSE;
coff_link_hash_traverse (coff_hash_table (info),
- _bfd_coff_write_task_globals,
- (PTR) &finfo);
+ _bfd_coff_write_task_globals, &finfo);
if (finfo.failed)
goto error_return;
}
/* Write out the global symbols. */
- finfo.failed = false;
+ finfo.failed = FALSE;
coff_link_hash_traverse (coff_hash_table (info),
- _bfd_coff_write_global_sym,
- (PTR) &finfo);
+ _bfd_coff_write_global_sym, &finfo);
if (finfo.failed)
goto error_return;
@@ -1029,13 +1001,13 @@ _bfd_coff_final_link (abfd, info)
finfo.outsyms = NULL;
}
- if (info->relocateable && max_output_reloc_count > 0)
+ if (info->relocatable && max_output_reloc_count > 0)
{
/* Now that we have written out all the global symbols, we know
the symbol indices to use for relocs against them, and we can
finally write out the relocs. */
amt = max_output_reloc_count * relsz;
- external_relocs = (bfd_byte *) bfd_malloc (amt);
+ external_relocs = bfd_malloc (amt);
if (external_relocs == NULL)
goto error_return;
@@ -1060,13 +1032,30 @@ _bfd_coff_final_link (abfd, info)
BFD_ASSERT ((*rel_hash)->indx >= 0);
irel->r_symndx = (*rel_hash)->indx;
}
- bfd_coff_swap_reloc_out (abfd, (PTR) irel, (PTR) erel);
+ bfd_coff_swap_reloc_out (abfd, irel, erel);
}
- if (bfd_seek (abfd, o->rel_filepos, SEEK_SET) != 0
- || (bfd_bwrite ((PTR) external_relocs,
- (bfd_size_type) relsz * o->reloc_count, abfd)
- != (bfd_size_type) relsz * o->reloc_count))
+ if (bfd_seek (abfd, o->rel_filepos, SEEK_SET) != 0)
+ goto error_return;
+ if (obj_pe (abfd) && o->reloc_count >= 0xffff)
+ {
+ /* In PE COFF, write the count of relocs as the first
+ reloc. The header overflow bit will be set
+ elsewhere. */
+ struct internal_reloc incount;
+ bfd_byte *excount = (bfd_byte *)bfd_malloc (relsz);
+
+ memset (&incount, 0, sizeof (incount));
+ incount.r_vaddr = o->reloc_count + 1;
+ bfd_coff_swap_reloc_out (abfd, (PTR) &incount, (PTR) excount);
+ if (bfd_bwrite (excount, relsz, abfd) != relsz)
+ /* We'll leak, but it's an error anyway. */
+ goto error_return;
+ free (excount);
+ }
+ if (bfd_bwrite (external_relocs,
+ (bfd_size_type) relsz * o->reloc_count, abfd)
+ != (bfd_size_type) relsz * o->reloc_count)
goto error_return;
}
@@ -1094,7 +1083,7 @@ _bfd_coff_final_link (abfd, info)
if (coff_hash_table (info)->stab_info != NULL)
{
if (! _bfd_write_stab_strings (abfd, &coff_hash_table (info)->stab_info))
- return false;
+ return FALSE;
}
/* Write out the string table. */
@@ -1104,7 +1093,7 @@ _bfd_coff_final_link (abfd, info)
pos = obj_sym_filepos (abfd) + obj_raw_syment_count (abfd) * symesz;
if (bfd_seek (abfd, pos, SEEK_SET) != 0)
- return false;
+ return FALSE;
#if STRING_SIZE_SIZE == 4
H_PUT_32 (abfd,
@@ -1116,12 +1105,12 @@ _bfd_coff_final_link (abfd, info)
if (bfd_bwrite (strbuf, (bfd_size_type) STRING_SIZE_SIZE, abfd)
!= STRING_SIZE_SIZE)
- return false;
+ return FALSE;
if (! _bfd_stringtab_emit (abfd, finfo.strtab))
- return false;
+ return FALSE;
- obj_coff_strings_written (abfd) = true;
+ obj_coff_strings_written (abfd) = TRUE;
}
_bfd_stringtab_free (finfo.strtab);
@@ -1130,7 +1119,7 @@ _bfd_coff_final_link (abfd, info)
not try to write out the symbols. */
bfd_get_symcount (abfd) = 0;
- return true;
+ return TRUE;
error_return:
if (debug_merge_allocated)
@@ -1168,20 +1157,18 @@ _bfd_coff_final_link (abfd, info)
free (finfo.internal_relocs);
if (external_relocs != NULL)
free (external_relocs);
- return false;
+ return FALSE;
}
-/* parse out a -heap <reserved>,<commit> line */
+/* Parse out a -heap <reserved>,<commit> line. */
static char *
-dores_com (ptr, output_bfd, heap)
- char *ptr;
- bfd *output_bfd;
- int heap;
+dores_com (char *ptr, bfd *output_bfd, int heap)
{
if (coff_data(output_bfd)->pe)
{
int val = strtoul (ptr, &ptr, 0);
+
if (heap)
pe_data(output_bfd)->pe_opthdr.SizeOfHeapReserve = val;
else
@@ -1199,9 +1186,8 @@ dores_com (ptr, output_bfd, heap)
return ptr;
}
-static char *get_name(ptr, dst)
-char *ptr;
-char **dst;
+static char *
+get_name (char *ptr, char **dst)
{
while (*ptr == ' ')
ptr++;
@@ -1212,85 +1198,89 @@ char **dst;
return ptr+1;
}
-/* Process any magic embedded commands in a section called .drectve */
+/* Process any magic embedded commands in a section called .drectve. */
static int
-process_embedded_commands (output_bfd, info, abfd)
- bfd *output_bfd;
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
- bfd *abfd;
+process_embedded_commands (bfd *output_bfd,
+ struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ bfd *abfd)
{
asection *sec = bfd_get_section_by_name (abfd, ".drectve");
char *s;
char *e;
char *copy;
+
if (!sec)
return 1;
copy = bfd_malloc (sec->_raw_size);
if (!copy)
return 0;
- if (! bfd_get_section_contents(abfd, sec, copy, (bfd_vma) 0, sec->_raw_size))
+
+ if (! bfd_get_section_contents (abfd, sec, copy, (bfd_vma) 0, sec->_raw_size))
{
free (copy);
return 0;
}
e = copy + sec->_raw_size;
+
for (s = copy; s < e ; )
{
- if (s[0]!= '-') {
- s++;
- continue;
- }
+ if (s[0]!= '-')
+ {
+ s++;
+ continue;
+ }
if (strncmp (s,"-attr", 5) == 0)
{
char *name;
char *attribs;
asection *asec;
-
int loop = 1;
int had_write = 0;
int had_read = 0;
int had_exec= 0;
int had_shared= 0;
+
s += 5;
- s = get_name(s, &name);
- s = get_name(s, &attribs);
- while (loop) {
- switch (*attribs++)
- {
- case 'W':
- had_write = 1;
- break;
- case 'R':
- had_read = 1;
- break;
- case 'S':
- had_shared = 1;
- break;
- case 'X':
- had_exec = 1;
- break;
- default:
- loop = 0;
- }
- }
+ s = get_name (s, &name);
+ s = get_name (s, &attribs);
+
+ while (loop)
+ {
+ switch (*attribs++)
+ {
+ case 'W':
+ had_write = 1;
+ break;
+ case 'R':
+ had_read = 1;
+ break;
+ case 'S':
+ had_shared = 1;
+ break;
+ case 'X':
+ had_exec = 1;
+ break;
+ default:
+ loop = 0;
+ }
+ }
asec = bfd_get_section_by_name (abfd, name);
- if (asec) {
- if (had_exec)
- asec->flags |= SEC_CODE;
- if (!had_write)
- asec->flags |= SEC_READONLY;
- }
+ if (asec)
+ {
+ if (had_exec)
+ asec->flags |= SEC_CODE;
+ if (!had_write)
+ asec->flags |= SEC_READONLY;
+ }
}
else if (strncmp (s,"-heap", 5) == 0)
- {
- s = dores_com (s+5, output_bfd, 1);
- }
+ s = dores_com (s+5, output_bfd, 1);
+
else if (strncmp (s,"-stack", 6) == 0)
- {
- s = dores_com (s+6, output_bfd, 0);
- }
+ s = dores_com (s+6, output_bfd, 0);
+
else
s++;
}
@@ -1301,13 +1291,10 @@ process_embedded_commands (output_bfd, info, abfd)
/* Place a marker against all symbols which are used by relocations.
This marker can be picked up by the 'do we skip this symbol ?'
loop in _bfd_coff_link_input_bfd() and used to prevent skipping
- that symbol.
- */
+ that symbol. */
static void
-mark_relocs (finfo, input_bfd)
- struct coff_final_link_info * finfo;
- bfd * input_bfd;
+mark_relocs (struct coff_final_link_info *finfo, bfd *input_bfd)
{
asection * a;
@@ -1328,10 +1315,10 @@ mark_relocs (finfo, input_bfd)
/* Read in the relocs. */
internal_relocs = _bfd_coff_read_internal_relocs
- (input_bfd, a, false,
+ (input_bfd, a, FALSE,
finfo->external_relocs,
- finfo->info->relocateable,
- (finfo->info->relocateable
+ finfo->info->relocatable,
+ (finfo->info->relocatable
? (finfo->section_info[ a->output_section->target_index ].relocs + a->output_section->reloc_count)
: finfo->internal_relocs)
);
@@ -1345,35 +1332,30 @@ mark_relocs (finfo, input_bfd)
/* Place a mark in the sym_indices array (whose entries have
been initialised to 0) for all of the symbols that are used
in the relocation table. This will then be picked up in the
- skip/don't pass */
-
+ skip/don't-skip pass. */
for (; irel < irelend; irel++)
- {
- finfo->sym_indices[ irel->r_symndx ] = -1;
- }
+ finfo->sym_indices[ irel->r_symndx ] = -1;
}
}
/* Link an input file into the linker output file. This function
handles all the sections and relocations of the input file at once. */
-boolean
-_bfd_coff_link_input_bfd (finfo, input_bfd)
- struct coff_final_link_info *finfo;
- bfd *input_bfd;
+bfd_boolean
+_bfd_coff_link_input_bfd (struct coff_final_link_info *finfo, bfd *input_bfd)
{
unsigned int n_tmask = coff_data (input_bfd)->local_n_tmask;
unsigned int n_btshft = coff_data (input_bfd)->local_n_btshft;
#if 0
unsigned int n_btmask = coff_data (input_bfd)->local_n_btmask;
#endif
- boolean (*adjust_symndx) PARAMS ((bfd *, struct bfd_link_info *, bfd *,
- asection *, struct internal_reloc *,
- boolean *));
+ bfd_boolean (*adjust_symndx)
+ (bfd *, struct bfd_link_info *, bfd *, asection *,
+ struct internal_reloc *, bfd_boolean *);
bfd *output_bfd;
const char *strings;
bfd_size_type syment_base;
- boolean copy, hash;
+ bfd_boolean copy, hash;
bfd_size_type isymesz;
bfd_size_type osymesz;
bfd_size_type linesz;
@@ -1397,15 +1379,15 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
linesz = bfd_coff_linesz (input_bfd);
BFD_ASSERT (linesz == bfd_coff_linesz (output_bfd));
- copy = false;
+ copy = FALSE;
if (! finfo->info->keep_memory)
- copy = true;
- hash = true;
+ copy = TRUE;
+ hash = TRUE;
if ((output_bfd->flags & BFD_TRADITIONAL_FORMAT) != 0)
- hash = false;
+ hash = FALSE;
if (! _bfd_coff_get_external_symbols (input_bfd))
- return false;
+ return FALSE;
esym = (bfd_byte *) obj_coff_external_syms (input_bfd);
esym_end = esym + obj_raw_syment_count (input_bfd) * isymesz;
@@ -1415,20 +1397,18 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
output_index = syment_base;
outsym = finfo->outsyms;
- if (coff_data (output_bfd)->pe)
- {
- if (! process_embedded_commands (output_bfd, finfo->info, input_bfd))
- return false;
- }
+ if (coff_data (output_bfd)->pe
+ && ! process_embedded_commands (output_bfd, finfo->info, input_bfd))
+ return FALSE;
- /* If we are going to perform relocations and also strip/discard some symbols
- then we must make sure that we do not strip/discard those symbols that are
- going to be involved in the relocations */
+ /* If we are going to perform relocations and also strip/discard some
+ symbols then we must make sure that we do not strip/discard those
+ symbols that are going to be involved in the relocations. */
if (( finfo->info->strip != strip_none
|| finfo->info->discard != discard_none)
- && finfo->info->relocateable)
+ && finfo->info->relocatable)
{
- /* mark the symbol array as 'not-used' */
+ /* Mark the symbol array as 'not-used'. */
memset (indexp, 0, obj_raw_syment_count (input_bfd) * sizeof * indexp);
mark_relocs (finfo, input_bfd);
@@ -1438,12 +1418,12 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
{
struct internal_syment isym;
enum coff_symbol_classification classification;
- boolean skip;
- boolean global;
- boolean dont_skip_symbol;
+ bfd_boolean skip;
+ bfd_boolean global;
+ bfd_boolean dont_skip_symbol;
int add;
- bfd_coff_swap_sym_in (input_bfd, (PTR) esym, (PTR) isymp);
+ bfd_coff_swap_sym_in (input_bfd, esym, isymp);
/* Make a copy of *isymp so that the relocate_section function
always sees the original values. This is more reliable than
@@ -1473,20 +1453,20 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
relocation. */
if ((finfo->info->strip != strip_none
|| finfo->info->discard != discard_none)
- && finfo->info->relocateable)
+ && finfo->info->relocatable)
dont_skip_symbol = *indexp;
else
- dont_skip_symbol = false;
+ dont_skip_symbol = FALSE;
*indexp = -1;
- skip = false;
- global = false;
+ skip = FALSE;
+ global = FALSE;
add = 1 + isym.n_numaux;
/* If we are stripping all symbols, we want to skip this one. */
if (finfo->info->strip == strip_all && ! dont_skip_symbol)
- skip = true;
+ skip = TRUE;
if (! skip)
{
@@ -1501,22 +1481,22 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
end of the symbol table, so skip them for now.
Locally defined function symbols, however, are an
exception, and are not moved to the end. */
- global = true;
+ global = TRUE;
if (! ISFCN (isym.n_type))
- skip = true;
+ skip = TRUE;
break;
case COFF_SYMBOL_UNDEFINED:
/* Undefined symbols are left for the end. */
- global = true;
- skip = true;
+ global = TRUE;
+ skip = TRUE;
break;
case COFF_SYMBOL_LOCAL:
/* This is a local symbol. Skip it if we are discarding
local symbols. */
if (finfo->info->discard == discard_all && ! dont_skip_symbol)
- skip = true;
+ skip = TRUE;
break;
}
}
@@ -1525,13 +1505,12 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
/* Skip section symbols for sections which are not going to be
emitted. */
if (!skip
+ && dont_skip_symbol == 0
&& isym.n_sclass == C_STAT
&& isym.n_type == T_NULL
- && isym.n_numaux > 0)
- {
- if ((*secpp)->output_section == bfd_abs_section_ptr)
- skip = true;
- }
+ && isym.n_numaux > 0
+ && (*secpp)->output_section == bfd_abs_section_ptr)
+ skip = TRUE;
#endif
/* If we stripping debugging symbols, and this is a debugging
@@ -1552,7 +1531,7 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
|| isym.n_sclass == C_REGPARM
|| isym.n_sclass == C_FIELD
|| isym.n_sclass == C_EOS))))
- skip = true;
+ skip = TRUE;
/* If some symbols are stripped based on the name, work out the
name and decide whether to skip this symbol. */
@@ -1565,16 +1544,16 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
name = _bfd_coff_internal_syment_name (input_bfd, &isym, buf);
if (name == NULL)
- return false;
+ return FALSE;
if (! dont_skip_symbol
&& ((finfo->info->strip == strip_some
- && (bfd_hash_lookup (finfo->info->keep_hash, name, false,
- false) == NULL))
+ && (bfd_hash_lookup (finfo->info->keep_hash, name, FALSE,
+ FALSE) == NULL))
|| (! global
&& finfo->info->discard == discard_l
&& bfd_is_local_label_name (input_bfd, name))))
- skip = true;
+ skip = TRUE;
}
/* If this is an enum, struct, or union tag, see if we have
@@ -1598,7 +1577,7 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
name = _bfd_coff_internal_syment_name (input_bfd, &isym, buf);
if (name == NULL)
- return false;
+ return FALSE;
/* Ignore fake names invented by compiler; treat them all as
the same name. */
@@ -1608,24 +1587,24 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
name = "";
mh = coff_debug_merge_hash_lookup (&finfo->debug_merge, name,
- true, true);
+ TRUE, TRUE);
if (mh == NULL)
- return false;
+ return FALSE;
/* Allocate memory to hold type information. If this turns
out to be a duplicate, we pass this address to
bfd_release. */
amt = sizeof (struct coff_debug_merge_type);
- mt = (struct coff_debug_merge_type *) bfd_alloc (input_bfd, amt);
+ mt = bfd_alloc (input_bfd, amt);
if (mt == NULL)
- return false;
+ return FALSE;
mt->class = isym.n_sclass;
/* Pick up the aux entry, which points to the end of the tag
entries. */
- bfd_coff_swap_aux_in (input_bfd, (PTR) (esym + isymesz),
+ bfd_coff_swap_aux_in (input_bfd, (esym + isymesz),
isym.n_type, isym.n_sclass, 0, isym.n_numaux,
- (PTR) &aux);
+ &aux);
/* Gather the elements. */
epp = &mt->elements;
@@ -1640,23 +1619,22 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
char elebuf[SYMNMLEN + 1];
char *name_copy;
- bfd_coff_swap_sym_in (input_bfd, (PTR) esl, (PTR) islp);
+ bfd_coff_swap_sym_in (input_bfd, esl, islp);
amt = sizeof (struct coff_debug_merge_element);
- *epp = ((struct coff_debug_merge_element *)
- bfd_alloc (input_bfd, amt));
+ *epp = bfd_alloc (input_bfd, amt);
if (*epp == NULL)
- return false;
+ return FALSE;
elename = _bfd_coff_internal_syment_name (input_bfd, islp,
elebuf);
if (elename == NULL)
- return false;
+ return FALSE;
amt = strlen (elename) + 1;
- name_copy = (char *) bfd_alloc (input_bfd, amt);
+ name_copy = bfd_alloc (input_bfd, amt);
if (name_copy == NULL)
- return false;
+ return FALSE;
strcpy (name_copy, elename);
(*epp)->name = name_copy;
@@ -1669,16 +1647,15 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
union internal_auxent eleaux;
long indx;
- bfd_coff_swap_aux_in (input_bfd, (PTR) (esl + isymesz),
+ bfd_coff_swap_aux_in (input_bfd, (esl + isymesz),
islp->n_type, islp->n_sclass, 0,
- islp->n_numaux, (PTR) &eleaux);
+ islp->n_numaux, &eleaux);
indx = eleaux.x_sym.x_tagndx.l;
/* FIXME: If this tagndx entry refers to a symbol
defined later in this file, we just ignore it.
Handling this correctly would be tedious, and may
not be required. */
-
if (indx > 0
&& (indx
< ((esym -
@@ -1701,7 +1678,7 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
type. We always output the type if it has no elements,
for simplicity. */
if (mt->elements == NULL)
- bfd_release (input_bfd, (PTR) mt);
+ bfd_release (input_bfd, mt);
else
{
struct coff_debug_merge_type *mtl;
@@ -1737,10 +1714,10 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
else
{
/* This is a redefinition which can be merged. */
- bfd_release (input_bfd, (PTR) mt);
+ bfd_release (input_bfd, mt);
*indexp = mtl->indx;
add = (eslend - esym) / isymesz;
- skip = true;
+ skip = TRUE;
}
}
}
@@ -1761,13 +1738,12 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
bfd_coff_symname_in_debug. That is only true for
XCOFF, and XCOFF requires different linking code
anyhow. */
- name = _bfd_coff_internal_syment_name (input_bfd, &isym,
- (char *) NULL);
+ name = _bfd_coff_internal_syment_name (input_bfd, &isym, NULL);
if (name == NULL)
- return false;
+ return FALSE;
indx = _bfd_stringtab_add (finfo->strtab, name, hash, copy);
if (indx == (bfd_size_type) -1)
- return false;
+ return FALSE;
isym._n._n_n._n_offset = STRING_SIZE_SIZE + indx;
}
@@ -1835,7 +1811,6 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
it). We try to get this right, below, just before we
write the symbols out, but in the general case we may
have to write the symbol out twice. */
-
if (finfo->last_file_index != -1
&& finfo->last_file.n_value != (bfd_vma) output_index)
{
@@ -1846,11 +1821,11 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
{
/* The last C_FILE symbol is in this input file. */
bfd_coff_swap_sym_out (output_bfd,
- (PTR) &finfo->last_file,
- (PTR) (finfo->outsyms
- + ((finfo->last_file_index
- - syment_base)
- * osymesz)));
+ &finfo->last_file,
+ (finfo->outsyms
+ + ((finfo->last_file_index
+ - syment_base)
+ * osymesz)));
}
else
{
@@ -1860,13 +1835,12 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
symbol. We need to write it out again. We
borrow *outsym temporarily. */
bfd_coff_swap_sym_out (output_bfd,
- (PTR) &finfo->last_file,
- (PTR) outsym);
+ &finfo->last_file, outsym);
pos = obj_sym_filepos (output_bfd);
pos += finfo->last_file_index * osymesz;
if (bfd_seek (output_bfd, pos, SEEK_SET) != 0
|| bfd_bwrite (outsym, osymesz, output_bfd) != osymesz)
- return false;
+ return FALSE;
}
}
@@ -1881,8 +1855,7 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
isym.n_sclass = C_STAT;
/* Output the symbol. */
-
- bfd_coff_swap_sym_out (output_bfd, (PTR) &isym, (PTR) outsym);
+ bfd_coff_swap_sym_out (output_bfd, &isym, outsym);
*indexp = output_index;
@@ -1899,7 +1872,7 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
/* This can happen if there were errors earlier in
the link. */
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
h->indx = output_index;
}
@@ -1922,13 +1895,13 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
/* Fix up the aux entries. This must be done in a separate pass,
because we don't know the correct symbol indices until we have
already decided which symbols we are going to keep. */
-
esym = (bfd_byte *) obj_coff_external_syms (input_bfd);
esym_end = esym + obj_raw_syment_count (input_bfd) * isymesz;
isymp = finfo->internal_syms;
indexp = finfo->sym_indices;
sym_hash = obj_coff_sym_hashes (input_bfd);
outsym = finfo->outsyms;
+
while (esym < esym_end)
{
int add;
@@ -1973,9 +1946,8 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
auxp = h->aux + i;
else
{
- bfd_coff_swap_aux_in (input_bfd, (PTR) esym, isymp->n_type,
- isymp->n_sclass, i, isymp->n_numaux,
- (PTR) &aux);
+ bfd_coff_swap_aux_in (input_bfd, esym, isymp->n_type,
+ isymp->n_sclass, i, isymp->n_numaux, &aux);
auxp = &aux;
}
@@ -1995,13 +1967,13 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
{
strings = _bfd_coff_read_string_table (input_bfd);
if (strings == NULL)
- return false;
+ return FALSE;
}
filename = strings + auxp->x_file.x_n.x_offset;
indx = _bfd_stringtab_add (finfo->strtab, filename,
hash, copy);
if (indx == (bfd_size_type) -1)
- return false;
+ return FALSE;
auxp->x_file.x_n.x_offset = STRING_SIZE_SIZE + indx;
}
}
@@ -2068,18 +2040,19 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
if ((bfd_size_type) finfo->last_bf_index
>= syment_base)
{
- PTR auxout;
+ void *auxout;
/* The last .bf symbol is in this input
file. This will only happen if the
assembler did not set up the .bf
endndx symbols correctly. */
- auxout = (PTR) (finfo->outsyms
- + ((finfo->last_bf_index
- - syment_base)
- * osymesz));
+ auxout = (finfo->outsyms
+ + ((finfo->last_bf_index
+ - syment_base)
+ * osymesz));
+
bfd_coff_swap_aux_out (output_bfd,
- (PTR) &finfo->last_bf,
+ &finfo->last_bf,
isymp->n_type,
isymp->n_sclass,
0, isymp->n_numaux,
@@ -2095,17 +2068,17 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
temporarily. FIXME: This case should
be made faster. */
bfd_coff_swap_aux_out (output_bfd,
- (PTR) &finfo->last_bf,
+ &finfo->last_bf,
isymp->n_type,
isymp->n_sclass,
0, isymp->n_numaux,
- (PTR) outsym);
+ outsym);
pos = obj_sym_filepos (output_bfd);
pos += finfo->last_bf_index * osymesz;
if (bfd_seek (output_bfd, pos, SEEK_SET) != 0
|| (bfd_bwrite (outsym, osymesz, output_bfd)
!= osymesz))
- return false;
+ return FALSE;
}
}
@@ -2126,9 +2099,9 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
if (h == NULL)
{
- bfd_coff_swap_aux_out (output_bfd, (PTR) auxp, isymp->n_type,
+ bfd_coff_swap_aux_out (output_bfd, auxp, isymp->n_type,
isymp->n_sclass, i, isymp->n_numaux,
- (PTR) outsym);
+ outsym);
outsym += osymesz;
}
@@ -2151,7 +2124,7 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
bfd_byte *eline;
bfd_byte *elineend;
bfd_byte *oeline;
- boolean skipping;
+ bfd_boolean skipping;
file_ptr pos;
bfd_size_type amt;
@@ -2171,18 +2144,18 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
if (bfd_seek (input_bfd, o->line_filepos, SEEK_SET) != 0
|| bfd_bread (finfo->linenos, linesz * o->lineno_count,
input_bfd) != linesz * o->lineno_count)
- return false;
+ return FALSE;
offset = o->output_section->vma + o->output_offset - o->vma;
eline = finfo->linenos;
oeline = finfo->linenos;
elineend = eline + linesz * o->lineno_count;
- skipping = false;
+ skipping = FALSE;
for (; eline < elineend; eline += linesz)
{
struct internal_lineno iline;
- bfd_coff_swap_lineno_in (input_bfd, (PTR) eline, (PTR) &iline);
+ bfd_coff_swap_lineno_in (input_bfd, eline, &iline);
if (iline.l_lnno != 0)
iline.l_addr.l_paddr += offset;
@@ -2203,7 +2176,7 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
with symbol #0) will fail. We can't regain
the space in the output file, but at least
they're dense. */
- skipping = true;
+ skipping = TRUE;
}
else
{
@@ -2218,32 +2191,31 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
of the line numbers rather than an absolute
file index. */
bfd_coff_swap_sym_in (output_bfd,
- (PTR) (finfo->outsyms
- + ((indx - syment_base)
- * osymesz)),
- (PTR) &is);
+ (finfo->outsyms
+ + ((indx - syment_base)
+ * osymesz)), &is);
if ((ISFCN (is.n_type)
|| is.n_sclass == C_BLOCK)
&& is.n_numaux >= 1)
{
- PTR auxptr;
+ void *auxptr;
- auxptr = (PTR) (finfo->outsyms
- + ((indx - syment_base + 1)
- * osymesz));
+ auxptr = (finfo->outsyms
+ + ((indx - syment_base + 1)
+ * osymesz));
bfd_coff_swap_aux_in (output_bfd, auxptr,
is.n_type, is.n_sclass,
- 0, is.n_numaux, (PTR) &ia);
+ 0, is.n_numaux, &ia);
ia.x_sym.x_fcnary.x_fcn.x_lnnoptr =
(o->output_section->line_filepos
+ o->output_section->lineno_count * linesz
+ eline - finfo->linenos);
- bfd_coff_swap_aux_out (output_bfd, (PTR) &ia,
+ bfd_coff_swap_aux_out (output_bfd, &ia,
is.n_type, is.n_sclass, 0,
is.n_numaux, auxptr);
}
- skipping = false;
+ skipping = FALSE;
}
iline.l_addr.l_symndx = indx;
@@ -2251,8 +2223,7 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
if (!skipping)
{
- bfd_coff_swap_lineno_out (output_bfd, (PTR) &iline,
- (PTR) oeline);
+ bfd_coff_swap_lineno_out (output_bfd, &iline, oeline);
oeline += linesz;
}
}
@@ -2262,7 +2233,7 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
amt = oeline - finfo->linenos;
if (bfd_seek (output_bfd, pos, SEEK_SET) != 0
|| bfd_bwrite (finfo->linenos, amt, output_bfd) != amt)
- return false;
+ return FALSE;
o->output_section->lineno_count += amt / linesz;
}
@@ -2276,10 +2247,10 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
&& (bfd_size_type) finfo->last_file_index >= syment_base)
{
finfo->last_file.n_value = output_index;
- bfd_coff_swap_sym_out (output_bfd, (PTR) &finfo->last_file,
- (PTR) (finfo->outsyms
- + ((finfo->last_file_index - syment_base)
- * osymesz)));
+ bfd_coff_swap_sym_out (output_bfd, &finfo->last_file,
+ (finfo->outsyms
+ + ((finfo->last_file_index - syment_base)
+ * osymesz)));
}
/* Write the modified symbols to the output file. */
@@ -2292,7 +2263,7 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
amt = outsym - finfo->outsyms;
if (bfd_seek (output_bfd, pos, SEEK_SET) != 0
|| bfd_bwrite (finfo->outsyms, amt, output_bfd) != amt)
- return false;
+ return FALSE;
BFD_ASSERT ((obj_raw_syment_count (output_bfd)
+ (outsym - finfo->outsyms) / osymesz)
@@ -2309,10 +2280,8 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
struct coff_section_tdata *secdata;
if (! o->linker_mark)
- {
- /* This section was omitted from the link. */
- continue;
- }
+ /* This section was omitted from the link. */
+ continue;
if ((o->flags & SEC_HAS_CONTENTS) == 0
|| (o->_raw_size == 0 && (o->flags & SEC_RELOC) == 0))
@@ -2325,7 +2294,7 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
bfd_archive_filename (input_bfd),
bfd_get_section_name (input_bfd, o)));
bfd_set_error (bfd_error_no_contents);
- return false;
+ return FALSE;
}
continue;
@@ -2338,7 +2307,7 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
{
if (! bfd_get_section_contents (input_bfd, o, finfo->contents,
(file_ptr) 0, o->_raw_size))
- return false;
+ return FALSE;
contents = finfo->contents;
}
@@ -2351,14 +2320,14 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
/* Read in the relocs. */
target_index = o->output_section->target_index;
internal_relocs = (_bfd_coff_read_internal_relocs
- (input_bfd, o, false, finfo->external_relocs,
- finfo->info->relocateable,
- (finfo->info->relocateable
+ (input_bfd, o, FALSE, finfo->external_relocs,
+ finfo->info->relocatable,
+ (finfo->info->relocatable
? (finfo->section_info[target_index].relocs
+ o->output_section->reloc_count)
: finfo->internal_relocs)));
if (internal_relocs == NULL)
- return false;
+ return FALSE;
/* Call processor specific code to relocate the section
contents. */
@@ -2368,9 +2337,9 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
internal_relocs,
finfo->internal_syms,
finfo->sec_ptrs))
- return false;
+ return FALSE;
- if (finfo->info->relocateable)
+ if (finfo->info->relocatable)
{
bfd_vma offset;
struct internal_reloc *irelend;
@@ -2384,12 +2353,11 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
for (; irel < irelend; irel++, rel_hash++)
{
struct coff_link_hash_entry *h;
- boolean adjusted;
+ bfd_boolean adjusted;
*rel_hash = NULL;
/* Adjust the reloc address and symbol index. */
-
irel->r_vaddr += offset;
if (irel->r_symndx == -1)
@@ -2400,7 +2368,7 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
if (! (*adjust_symndx) (output_bfd, finfo->info,
input_bfd, o, irel,
&adjusted))
- return false;
+ return FALSE;
if (adjusted)
continue;
}
@@ -2440,18 +2408,17 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
stripping. This should have been handled
by the 'dont_skip_symbol' code in the while
loop at the top of this function. */
-
is = finfo->internal_syms + irel->r_symndx;
name = (_bfd_coff_internal_syment_name
(input_bfd, is, buf));
if (name == NULL)
- return false;
+ return FALSE;
if (! ((*finfo->info->callbacks->unattached_reloc)
(finfo->info, name, input_bfd, o,
irel->r_vaddr)))
- return false;
+ return FALSE;
}
}
}
@@ -2468,32 +2435,28 @@ _bfd_coff_link_input_bfd (finfo, input_bfd)
? o->_cooked_size : o->_raw_size);
if (! bfd_set_section_contents (output_bfd, o->output_section,
contents, loc, amt))
- return false;
+ return FALSE;
}
else
{
if (! (_bfd_write_section_stabs
(output_bfd, &coff_hash_table (finfo->info)->stab_info,
o, &secdata->stab_info, contents)))
- return false;
+ return FALSE;
}
}
- if (! finfo->info->keep_memory)
- {
- if (! _bfd_coff_free_symbols (input_bfd))
- return false;
- }
+ if (! finfo->info->keep_memory
+ && ! _bfd_coff_free_symbols (input_bfd))
+ return FALSE;
- return true;
+ return TRUE;
}
/* Write out a global symbol. Called via coff_link_hash_traverse. */
-boolean
-_bfd_coff_write_global_sym (h, data)
- struct coff_link_hash_entry *h;
- PTR data;
+bfd_boolean
+_bfd_coff_write_global_sym (struct coff_link_hash_entry *h, void *data)
{
struct coff_final_link_info *finfo = (struct coff_final_link_info *) data;
bfd *output_bfd;
@@ -2508,19 +2471,19 @@ _bfd_coff_write_global_sym (h, data)
{
h = (struct coff_link_hash_entry *) h->root.u.i.link;
if (h->root.type == bfd_link_hash_new)
- return true;
+ return TRUE;
}
if (h->indx >= 0)
- return true;
+ return TRUE;
if (h->indx != -2
&& (finfo->info->strip == strip_all
|| (finfo->info->strip == strip_some
&& (bfd_hash_lookup (finfo->info->keep_hash,
- h->root.root.string, false, false)
+ h->root.root.string, FALSE, FALSE)
== NULL))))
- return true;
+ return TRUE;
switch (h->root.type)
{
@@ -2528,7 +2491,7 @@ _bfd_coff_write_global_sym (h, data)
case bfd_link_hash_new:
case bfd_link_hash_warning:
abort ();
- return false;
+ return FALSE;
case bfd_link_hash_undefined:
case bfd_link_hash_undefweak:
@@ -2560,25 +2523,25 @@ _bfd_coff_write_global_sym (h, data)
case bfd_link_hash_indirect:
/* Just ignore these. They can't be handled anyhow. */
- return true;
+ return TRUE;
}
if (strlen (h->root.root.string) <= SYMNMLEN)
strncpy (isym._n._n_name, h->root.root.string, SYMNMLEN);
else
{
- boolean hash;
+ bfd_boolean hash;
bfd_size_type indx;
- hash = true;
+ hash = TRUE;
if ((output_bfd->flags & BFD_TRADITIONAL_FORMAT) != 0)
- hash = false;
+ hash = FALSE;
indx = _bfd_stringtab_add (finfo->strtab, h->root.root.string, hash,
- false);
+ FALSE);
if (indx == (bfd_size_type) -1)
{
- finfo->failed = true;
- return false;
+ finfo->failed = TRUE;
+ return FALSE;
}
isym._n._n_n._n_zeroes = 0;
isym._n._n_n._n_offset = STRING_SIZE_SIZE + indx;
@@ -2597,22 +2560,22 @@ _bfd_coff_write_global_sym (h, data)
if (finfo->global_to_static)
{
if (! IS_EXTERNAL (output_bfd, isym))
- return true;
+ return TRUE;
isym.n_sclass = C_STAT;
}
- /* When a weak symbol is not overriden by a strong one,
+ /* When a weak symbol is not overridden by a strong one,
turn it into an external symbol when not building a
- shared or relocateable object. */
+ shared or relocatable object. */
if (! finfo->info->shared
- && ! finfo->info->relocateable
+ && ! finfo->info->relocatable
&& IS_WEAK_EXTERNAL (finfo->output_bfd, isym))
isym.n_sclass = C_EXT;
isym.n_numaux = h->numaux;
- bfd_coff_swap_sym_out (output_bfd, (PTR) &isym, (PTR) finfo->outsyms);
+ bfd_coff_swap_sym_out (output_bfd, &isym, finfo->outsyms);
symesz = bfd_coff_symesz (output_bfd);
@@ -2621,8 +2584,8 @@ _bfd_coff_write_global_sym (h, data)
if (bfd_seek (output_bfd, pos, SEEK_SET) != 0
|| bfd_bwrite (finfo->outsyms, symesz, output_bfd) != symesz)
{
- finfo->failed = true;
- return false;
+ finfo->failed = TRUE;
+ return FALSE;
}
h->indx = obj_raw_syment_count (output_bfd);
@@ -2659,10 +2622,9 @@ _bfd_coff_write_global_sym (h, data)
/* For PE, an overflow on the final link reportedly does
not matter. FIXME: Why not? */
-
if (sec->reloc_count > 0xffff
&& (! obj_pe (output_bfd)
- || finfo->info->relocateable))
+ || finfo->info->relocatable))
(*_bfd_error_handler)
(_("%s: %s: reloc overflow: 0x%lx > 0xffff"),
bfd_get_filename (output_bfd),
@@ -2671,7 +2633,7 @@ _bfd_coff_write_global_sym (h, data)
if (sec->lineno_count > 0xffff
&& (! obj_pe (output_bfd)
- || finfo->info->relocateable))
+ || finfo->info->relocatable))
(*_bfd_error_handler)
(_("%s: warning: %s: line number overflow: 0x%lx > 0xffff"),
bfd_get_filename (output_bfd),
@@ -2686,32 +2648,30 @@ _bfd_coff_write_global_sym (h, data)
}
}
- bfd_coff_swap_aux_out (output_bfd, (PTR) auxp, isym.n_type,
+ bfd_coff_swap_aux_out (output_bfd, auxp, isym.n_type,
isym.n_sclass, (int) i, isym.n_numaux,
- (PTR) finfo->outsyms);
+ finfo->outsyms);
if (bfd_bwrite (finfo->outsyms, symesz, output_bfd) != symesz)
{
- finfo->failed = true;
- return false;
+ finfo->failed = TRUE;
+ return FALSE;
}
++obj_raw_syment_count (output_bfd);
}
- return true;
+ return TRUE;
}
/* Write out task global symbols, converting them to statics. Called
via coff_link_hash_traverse. Calls bfd_coff_write_global_sym to do
the dirty work, if the symbol we are processing needs conversion. */
-boolean
-_bfd_coff_write_task_globals (h, data)
- struct coff_link_hash_entry *h;
- PTR data;
+bfd_boolean
+_bfd_coff_write_task_globals (struct coff_link_hash_entry *h, void *data)
{
struct coff_final_link_info *finfo = (struct coff_final_link_info *) data;
- boolean rtnval = true;
- boolean save_global_to_static;
+ bfd_boolean rtnval = TRUE;
+ bfd_boolean save_global_to_static;
if (h->root.type == bfd_link_hash_warning)
h = (struct coff_link_hash_entry *) h->root.u.i.link;
@@ -2723,7 +2683,7 @@ _bfd_coff_write_task_globals (h, data)
case bfd_link_hash_defined:
case bfd_link_hash_defweak:
save_global_to_static = finfo->global_to_static;
- finfo->global_to_static = true;
+ finfo->global_to_static = TRUE;
rtnval = _bfd_coff_write_global_sym (h, data);
finfo->global_to_static = save_global_to_static;
break;
@@ -2736,12 +2696,11 @@ _bfd_coff_write_task_globals (h, data)
/* Handle a link order which is supposed to generate a reloc. */
-boolean
-_bfd_coff_reloc_link_order (output_bfd, finfo, output_section, link_order)
- bfd *output_bfd;
- struct coff_final_link_info *finfo;
- asection *output_section;
- struct bfd_link_order *link_order;
+bfd_boolean
+_bfd_coff_reloc_link_order (bfd *output_bfd,
+ struct coff_final_link_info *finfo,
+ asection *output_section,
+ struct bfd_link_order *link_order)
{
reloc_howto_type *howto;
struct internal_reloc *irel;
@@ -2751,7 +2710,7 @@ _bfd_coff_reloc_link_order (output_bfd, finfo, output_section, link_order)
if (howto == NULL)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
if (link_order->u.reloc.p->addend != 0)
@@ -2759,13 +2718,13 @@ _bfd_coff_reloc_link_order (output_bfd, finfo, output_section, link_order)
bfd_size_type size;
bfd_byte *buf;
bfd_reloc_status_type rstat;
- boolean ok;
+ bfd_boolean ok;
file_ptr loc;
size = bfd_get_reloc_size (howto);
- buf = (bfd_byte *) bfd_zmalloc (size);
+ buf = bfd_zmalloc (size);
if (buf == NULL)
- return false;
+ return FALSE;
rstat = _bfd_relocate_contents (howto, output_bfd,
(bfd_vma) link_order->u.reloc.p->addend,\
@@ -2788,21 +2747,20 @@ _bfd_coff_reloc_link_order (output_bfd, finfo, output_section, link_order)
(bfd *) NULL, (asection *) NULL, (bfd_vma) 0)))
{
free (buf);
- return false;
+ return FALSE;
}
break;
}
loc = link_order->offset * bfd_octets_per_byte (output_bfd);
- ok = bfd_set_section_contents (output_bfd, output_section, (PTR) buf,
+ ok = bfd_set_section_contents (output_bfd, output_section, buf,
loc, size);
free (buf);
if (! ok)
- return false;
+ return FALSE;
}
/* Store the reloc information in the right place. It will get
swapped and written out at the end of the final_link routine. */
-
irel = (finfo->section_info[output_section->target_index].relocs
+ output_section->reloc_count);
rel_hash_ptr = (finfo->section_info[output_section->target_index].rel_hashes
@@ -2830,7 +2788,7 @@ _bfd_coff_reloc_link_order (output_bfd, finfo, output_section, link_order)
h = ((struct coff_link_hash_entry *)
bfd_wrapped_link_hash_lookup (output_bfd, finfo->info,
link_order->u.reloc.p->u.name,
- false, false, true));
+ FALSE, FALSE, TRUE));
if (h != NULL)
{
if (h->indx >= 0)
@@ -2849,7 +2807,7 @@ _bfd_coff_reloc_link_order (output_bfd, finfo, output_section, link_order)
if (! ((*finfo->info->callbacks->unattached_reloc)
(finfo->info, link_order->u.reloc.p->u.name, (bfd *) NULL,
(asection *) NULL, (bfd_vma) 0)))
- return false;
+ return FALSE;
irel->r_symndx = 0;
}
}
@@ -2861,27 +2819,23 @@ _bfd_coff_reloc_link_order (output_bfd, finfo, output_section, link_order)
routines anyhow. r_extern is only used for ECOFF. */
/* FIXME: What is the right value for r_offset? Is zero OK? */
-
++output_section->reloc_count;
- return true;
+ return TRUE;
}
/* A basic reloc handling routine which may be used by processors with
simple relocs. */
-boolean
-_bfd_coff_generic_relocate_section (output_bfd, info, input_bfd,
- input_section, contents, relocs, syms,
- sections)
- bfd *output_bfd;
- struct bfd_link_info *info;
- bfd *input_bfd;
- asection *input_section;
- bfd_byte *contents;
- struct internal_reloc *relocs;
- struct internal_syment *syms;
- asection **sections;
+bfd_boolean
+_bfd_coff_generic_relocate_section (bfd *output_bfd,
+ struct bfd_link_info *info,
+ bfd *input_bfd,
+ asection *input_section,
+ bfd_byte *contents,
+ struct internal_reloc *relocs,
+ struct internal_syment *syms,
+ asection **sections)
{
struct internal_reloc *rel;
struct internal_reloc *relend;
@@ -2911,7 +2865,7 @@ _bfd_coff_generic_relocate_section (output_bfd, info, input_bfd,
(*_bfd_error_handler)
("%s: illegal symbol index %ld in relocs",
bfd_archive_filename (input_bfd), symndx);
- return false;
+ return FALSE;
}
else
{
@@ -2923,7 +2877,6 @@ _bfd_coff_generic_relocate_section (output_bfd, info, input_bfd,
size of the symbol is included in the section contents, or it
is not. We assume that the size is not included, and force
the rtype_to_howto function to adjust the addend as needed. */
-
if (sym != NULL && sym->n_scnum != 0)
addend = - sym->n_value;
else
@@ -2932,15 +2885,15 @@ _bfd_coff_generic_relocate_section (output_bfd, info, input_bfd,
howto = bfd_coff_rtype_to_howto (input_bfd, input_section, rel, h,
sym, &addend);
if (howto == NULL)
- return false;
+ return FALSE;
- /* If we are doing a relocateable link, then we can just ignore
+ /* If we are doing a relocatable link, then we can just ignore
a PC relative reloc that is pcrel_offset. It will already
- have the correct value. If this is not a relocateable link,
+ have the correct value. If this is not a relocatable link,
then we should ignore the symbol value. */
if (howto->pc_relative && howto->pcrel_offset)
{
- if (info->relocateable)
+ if (info->relocatable)
continue;
if (sym != NULL && sym->n_scnum != 0)
addend += sym->n_value;
@@ -2983,12 +2936,12 @@ _bfd_coff_generic_relocate_section (output_bfd, info, input_bfd,
else if (h->root.type == bfd_link_hash_undefweak)
val = 0;
- else if (! info->relocateable)
+ else if (! info->relocatable)
{
if (! ((*info->callbacks->undefined_symbol)
(info, h->root.root.string, input_bfd, input_section,
- rel->r_vaddr - input_section->vma, true)))
- return false;
+ rel->r_vaddr - input_section->vma, TRUE)))
+ return FALSE;
}
}
@@ -3013,7 +2966,7 @@ _bfd_coff_generic_relocate_section (output_bfd, info, input_bfd,
!= sizeof (long))
{
bfd_set_error (bfd_error_system_call);
- return false;
+ return FALSE;
}
}
}
@@ -3035,7 +2988,7 @@ _bfd_coff_generic_relocate_section (output_bfd, info, input_bfd,
bfd_archive_filename (input_bfd),
(unsigned long) rel->r_vaddr,
bfd_get_section_name (input_bfd, input_section));
- return false;
+ return FALSE;
case bfd_reloc_overflow:
{
const char *name;
@@ -3049,15 +3002,15 @@ _bfd_coff_generic_relocate_section (output_bfd, info, input_bfd,
{
name = _bfd_coff_internal_syment_name (input_bfd, sym, buf);
if (name == NULL)
- return false;
+ return FALSE;
}
if (! ((*info->callbacks->reloc_overflow)
(info, name, howto->name, (bfd_vma) 0, input_bfd,
input_section, rel->r_vaddr - input_section->vma)))
- return false;
+ return FALSE;
}
}
}
- return true;
+ return TRUE;
}
diff --git a/contrib/binutils/bfd/coffswap.h b/contrib/binutils/bfd/coffswap.h
index cd147c5..5f23ecc 100644
--- a/contrib/binutils/bfd/coffswap.h
+++ b/contrib/binutils/bfd/coffswap.h
@@ -1,24 +1,24 @@
/* Generic COFF swapping routines, for BFD.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1999, 2000,
- 2001
+ 2001, 2002
Free Software Foundation, Inc.
Written by Cygnus Support.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* This file contains routines used to swap COFF data. It is a header
file because the details of swapping depend on the details of the
@@ -381,7 +381,12 @@ coff_swap_sym_out (abfd, inp, extp)
{
struct internal_syment *in = (struct internal_syment *) inp;
SYMENT *ext =(SYMENT *) extp;
- if(in->_n._n_name[0] == 0)
+
+#ifdef COFF_ADJUST_SYM_OUT_PRE
+ COFF_ADJUST_SYM_OUT_PRE (abfd, inp, extp);
+#endif
+
+ if (in->_n._n_name[0] == 0)
{
H_PUT_32 (abfd, 0, ext->e.e.e_zeroes);
H_PUT_32 (abfd, in->_n._n_n._n_offset, ext->e.e.e_offset);
@@ -391,11 +396,13 @@ coff_swap_sym_out (abfd, inp, extp)
#if SYMNMLEN != E_SYMNMLEN
-> Error, we need to cope with truncating or extending SYMNMLEN!;
#else
- memcpy(ext->e.e_name, in->_n._n_name, SYMNMLEN);
+ memcpy (ext->e.e_name, in->_n._n_name, SYMNMLEN);
#endif
}
+
H_PUT_32 (abfd, in->n_value, ext->e_value);
H_PUT_16 (abfd, in->n_scnum, ext->e_scnum);
+
if (sizeof (ext->e_type) == 2)
{
H_PUT_16 (abfd, in->n_type, ext->e_type);
@@ -404,11 +411,14 @@ coff_swap_sym_out (abfd, inp, extp)
{
H_PUT_32 (abfd, in->n_type, ext->e_type);
}
+
H_PUT_8 (abfd, in->n_sclass, ext->e_sclass);
H_PUT_8 (abfd, in->n_numaux, ext->e_numaux);
+
#ifdef COFF_ADJUST_SYM_OUT_POST
COFF_ADJUST_SYM_OUT_POST (abfd, inp, extp);
#endif
+
return SYMESZ;
}
@@ -428,6 +438,7 @@ coff_swap_aux_in (abfd, ext1, type, class, indx, numaux, in1)
#ifdef COFF_ADJUST_AUX_IN_PRE
COFF_ADJUST_AUX_IN_PRE (abfd, ext1, type, class, indx, numaux, in1);
#endif
+
switch (class)
{
case C_FILE:
@@ -448,9 +459,7 @@ coff_swap_aux_in (abfd, ext1, type, class, indx, numaux, in1)
numaux * sizeof (AUXENT));
}
else
- {
- memcpy (in->x_file.x_fname, ext->x_file.x_fname, FILNMLEN);
- }
+ memcpy (in->x_file.x_fname, ext->x_file.x_fname, FILNMLEN);
#endif
}
goto end;
@@ -502,7 +511,7 @@ coff_swap_aux_in (abfd, ext1, type, class, indx, numaux, in1)
H_GET_16 (abfd, ext->x_sym.x_fcnary.x_ary.x_dimen[3]);
}
- if (ISFCN(type))
+ if (ISFCN (type))
{
in->x_sym.x_misc.x_fsize = H_GET_32 (abfd, ext->x_sym.x_misc.x_fsize);
}
@@ -535,7 +544,9 @@ coff_swap_aux_out (abfd, inp, type, class, indx, numaux, extp)
#ifdef COFF_ADJUST_AUX_OUT_PRE
COFF_ADJUST_AUX_OUT_PRE (abfd, inp, type, class, indx, numaux, extp);
#endif
- memset((PTR)ext, 0, AUXESZ);
+
+ memset ((PTR)ext, 0, AUXESZ);
+
switch (class)
{
case C_FILE:
@@ -681,29 +692,29 @@ coff_swap_aouthdr_in (abfd, aouthdr_ext1, aouthdr_int1)
#else
aouthdr_int->o_toc = H_GET_32 (abfd, aouthdr_ext->o_toc);
#endif
- aouthdr_int->o_snentry = H_GET_16 (abfd, aouthdr_ext->o_snentry);
- aouthdr_int->o_sntext = H_GET_16 (abfd, aouthdr_ext->o_sntext);
- aouthdr_int->o_sndata = H_GET_16 (abfd, aouthdr_ext->o_sndata);
- aouthdr_int->o_sntoc = H_GET_16 (abfd, aouthdr_ext->o_sntoc);
+ aouthdr_int->o_snentry = H_GET_16 (abfd, aouthdr_ext->o_snentry);
+ aouthdr_int->o_sntext = H_GET_16 (abfd, aouthdr_ext->o_sntext);
+ aouthdr_int->o_sndata = H_GET_16 (abfd, aouthdr_ext->o_sndata);
+ aouthdr_int->o_sntoc = H_GET_16 (abfd, aouthdr_ext->o_sntoc);
aouthdr_int->o_snloader = H_GET_16 (abfd, aouthdr_ext->o_snloader);
- aouthdr_int->o_snbss = H_GET_16 (abfd, aouthdr_ext->o_snbss);
+ aouthdr_int->o_snbss = H_GET_16 (abfd, aouthdr_ext->o_snbss);
aouthdr_int->o_algntext = H_GET_16 (abfd, aouthdr_ext->o_algntext);
aouthdr_int->o_algndata = H_GET_16 (abfd, aouthdr_ext->o_algndata);
- aouthdr_int->o_modtype = H_GET_16 (abfd, aouthdr_ext->o_modtype);
- aouthdr_int->o_cputype = H_GET_16 (abfd, aouthdr_ext->o_cputype);
+ aouthdr_int->o_modtype = H_GET_16 (abfd, aouthdr_ext->o_modtype);
+ aouthdr_int->o_cputype = H_GET_16 (abfd, aouthdr_ext->o_cputype);
#ifdef XCOFF64
aouthdr_int->o_maxstack = H_GET_64 (abfd, aouthdr_ext->o_maxstack);
- aouthdr_int->o_maxdata = H_GET_64 (abfd, aouthdr_ext->o_maxdata);
+ aouthdr_int->o_maxdata = H_GET_64 (abfd, aouthdr_ext->o_maxdata);
#else
aouthdr_int->o_maxstack = H_GET_32 (abfd, aouthdr_ext->o_maxstack);
- aouthdr_int->o_maxdata = H_GET_32 (abfd, aouthdr_ext->o_maxdata);
+ aouthdr_int->o_maxdata = H_GET_32 (abfd, aouthdr_ext->o_maxdata);
#endif
#endif
#ifdef MIPSECOFF
- aouthdr_int->bss_start = H_GET_32 (abfd, aouthdr_ext->bss_start);
- aouthdr_int->gp_value = H_GET_32 (abfd, aouthdr_ext->gp_value);
- aouthdr_int->gprmask = H_GET_32 (abfd, aouthdr_ext->gprmask);
+ aouthdr_int->bss_start = H_GET_32 (abfd, aouthdr_ext->bss_start);
+ aouthdr_int->gp_value = H_GET_32 (abfd, aouthdr_ext->gp_value);
+ aouthdr_int->gprmask = H_GET_32 (abfd, aouthdr_ext->gprmask);
aouthdr_int->cprmask[0] = H_GET_32 (abfd, aouthdr_ext->cprmask[0]);
aouthdr_int->cprmask[1] = H_GET_32 (abfd, aouthdr_ext->cprmask[1]);
aouthdr_int->cprmask[2] = H_GET_32 (abfd, aouthdr_ext->cprmask[2]);
@@ -712,9 +723,9 @@ coff_swap_aouthdr_in (abfd, aouthdr_ext1, aouthdr_int1)
#ifdef ALPHAECOFF
aouthdr_int->bss_start = H_GET_64 (abfd, aouthdr_ext->bss_start);
- aouthdr_int->gp_value = H_GET_64 (abfd, aouthdr_ext->gp_value);
- aouthdr_int->gprmask = H_GET_32 (abfd, aouthdr_ext->gprmask);
- aouthdr_int->fprmask = H_GET_32 (abfd, aouthdr_ext->fprmask);
+ aouthdr_int->gp_value = H_GET_64 (abfd, aouthdr_ext->gp_value);
+ aouthdr_int->gprmask = H_GET_32 (abfd, aouthdr_ext->gprmask);
+ aouthdr_int->fprmask = H_GET_32 (abfd, aouthdr_ext->fprmask);
#endif
}
@@ -807,7 +818,8 @@ coff_swap_scnhdr_in (abfd, ext, in)
#ifdef COFF_ADJUST_SCNHDR_IN_PRE
COFF_ADJUST_SCNHDR_IN_PRE (abfd, ext, in);
#endif
- memcpy(scnhdr_int->s_name, scnhdr_ext->s_name, sizeof (scnhdr_int->s_name));
+ memcpy (scnhdr_int->s_name, scnhdr_ext->s_name, sizeof (scnhdr_int->s_name));
+
scnhdr_int->s_vaddr = GET_SCNHDR_VADDR (abfd, scnhdr_ext->s_vaddr);
scnhdr_int->s_paddr = GET_SCNHDR_PADDR (abfd, scnhdr_ext->s_paddr);
scnhdr_int->s_size = GET_SCNHDR_SIZE (abfd, scnhdr_ext->s_size);
@@ -866,6 +878,7 @@ coff_swap_scnhdr_out (abfd, in, out)
buf, scnhdr_int->s_nlnno);
PUT_SCNHDR_NLNNO (abfd, 0xffff, scnhdr_ext->s_nlnno);
}
+
if (scnhdr_int->s_nreloc <= MAX_SCNHDR_NRELOC)
PUT_SCNHDR_NRELOC (abfd, scnhdr_int->s_nreloc, scnhdr_ext->s_nreloc);
else
diff --git a/contrib/binutils/bfd/config.bfd b/contrib/binutils/bfd/config.bfd
index 2e9d7fa..1428831 100755
--- a/contrib/binutils/bfd/config.bfd
+++ b/contrib/binutils/bfd/config.bfd
@@ -29,15 +29,30 @@ targ64_selvecs=
targ_cflags=
targ_underscore=no
+# Catch obsolete configurations.
+case $targ in
+ vax-*-vms* \
+ )
+ if test "x$enable_obsolete" != xyes; then
+ echo "*** Configuration $targ is obsolete." >&2
+ echo "*** Specify --enable-obsolete to build it anyway." >&2
+ echo "*** Support will be REMOVED in the next major release of BINUTILS," >&2
+ echo "*** unless a maintainer comes forward." >&2
+ exit 1
+ fi;;
+esac
+
+
targ_cpu=`echo $targ | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
case "${targ_cpu}" in
alpha*) targ_archs=bfd_alpha_arch ;;
arm*) targ_archs=bfd_arm_arch ;;
c30*) targ_archs=bfd_tic30_arch ;;
+c4x*) targ_archs=bfd_tic4x_arch ;;
c54x*) targ_archs=bfd_tic54x_arch ;;
dlx*) targ_archs=bfd_dlx_arch ;;
hppa*) targ_archs=bfd_hppa_arch ;;
-i[3456]86) targ_archs=bfd_i386_arch ;;
+i[3-7]86) targ_archs=bfd_i386_arch ;;
i370) targ_archs=bfd_i370_arch ;;
m6811*|m68hc11*) targ_archs="bfd_m68hc11_arch bfd_m68hc12_arch" ;;
m6812*|m68hc12*) targ_archs="bfd_m68hc12_arch bfd_m68hc11_arch" ;;
@@ -57,7 +72,9 @@ thumb*) targ_archs=bfd_arm_arch ;;
v850*) targ_archs=bfd_v850_arch ;;
x86_64) targ_archs=bfd_i386_arch ;;
xscale*) targ_archs=bfd_arm_arch ;;
+xtensa*) targ_archs=bfd_xtensa_arch ;;
z8k*) targ_archs=bfd_z8k_arch ;;
+am33_2.0) targ_archs=bfd_mn10300_arch ;;
*) targ_archs=bfd_${targ_cpu}_arch ;;
esac
@@ -66,11 +83,29 @@ esac
# Make sure that the left side always has two dashes. Otherwise you
# can get spurious matches. Even for unambiguous cases, do this as a
# convention, else the table becomes a real mess to understand and maintain.
+#
+# Keep obsolete entries above the START comment, to keep them out of
+# targmatch.h.
case "${targ}" in
+ mips*-dec-bsd*)
+ echo "This target is obsolete and has been removed."
+ exit 1
+ ;;
+
+ mips*-*-mach3*)
+ echo "This target is obsolete and has been removed."
+ exit 1
+ ;;
+
+ mips*-*-pe*)
+ echo "This target is obsolete and has been removed."
+ exit 1
+ ;;
+
# START OF targmatch.h
#ifdef BFD64
- alpha*-*-freebsd*)
+ alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu)
targ_defvec=bfd_elf64_alpha_freebsd_vec
targ_selvecs=ecoffalpha_little_vec
# FreeBSD <= 4.0 supports only the old nonstandard way of ABI labelling.
@@ -101,11 +136,7 @@ case "${targ}" in
alpha*-*-*)
targ_defvec=ecoffalpha_little_vec
;;
- ia64*-*-aix*)
- targ_defvec=bfd_elf64_ia64_aix_little_vec
- targ_selvecs="bfd_elf64_ia64_aix_big_vec bfd_efi_app_ia64_vec"
- ;;
- ia64*-*-freebsd* | ia64*-*-netbsd* | ia64*-*-linux-gnu* | ia64*-*-elf*)
+ ia64*-*-freebsd* | ia64*-*-netbsd* | ia64*-*-linux-gnu* | ia64*-*-elf* | ia64*-*-kfreebsd*-gnu)
targ_defvec=bfd_elf64_ia64_little_vec
targ_selvecs="bfd_elf64_ia64_big_vec bfd_efi_app_ia64_vec"
;;
@@ -113,12 +144,15 @@ case "${targ}" in
targ_defvec=bfd_elf32_ia64_hpux_big_vec
targ_selvecs="bfd_elf64_ia64_hpux_big_vec"
;;
- sparc64-*-freebsd* | sparc64-*-netbsd* | sparc64-*-openbsd*)
+ sparc64-*-freebsd* | sparc64-*-netbsd* | sparc64-*-openbsd* | sparc64-*-kfreebsd*-gnu)
targ_defvec=bfd_elf64_sparc_vec
targ_selvecs="bfd_elf32_sparc_vec sunos_big_vec"
;;
#endif /* BFD64 */
+ am33_2.0-*-linux*)
+ targ_defvec=bfd_elf32_am33lin_vec
+ ;;
arc-*-elf*)
targ_defvec=bfd_elf32_littlearc_vec
targ_selvecs=bfd_elf32_bigarc_vec
@@ -136,6 +170,11 @@ case "${targ}" in
targ_defvec=armnetbsd_vec
targ_selvecs="bfd_elf32_littlearm_vec bfd_elf32_bigarm_vec"
targ_underscore=yes
+ targ_cflags=-D__QNXTARGET__
+ ;;
+ arm-*-nto* | nto*arm*)
+ targ_defvec=bfd_elf32_littlearm_vec
+ targ_selvecs=bfd_elf32_bigarm_vec
;;
arm-*-riscix*)
targ_defvec=riscix_vec
@@ -150,7 +189,7 @@ case "${targ}" in
targ_defvec=armpe_little_vec
targ_selvecs="armpe_little_vec armpe_big_vec armpei_little_vec armpei_big_vec"
targ_underscore=no
- targ_cflags=-DARM_WINCE
+ targ_cflags="-DARM_WINCE -DARM_COFF_BUGFIX"
;;
arm-*-pe*)
targ_defvec=armpe_little_vec
@@ -165,12 +204,6 @@ case "${targ}" in
targ_defvec=aout_arm_big_vec
targ_selvecs=aout_arm_little_vec
;;
- arm-*-vxworks*)
- targ_defvec=armcoff_little_vec
- targ_selvecs=armcoff_big_vec
- targ_underscore=yes
- targ_cflags=-DARM_COFF_BUGFIX
- ;;
arm-*-coff)
targ_defvec=armcoff_little_vec
targ_selvecs=armcoff_big_vec
@@ -184,7 +217,12 @@ case "${targ}" in
targ_defvec=bfd_elf32_bigarm_vec
targ_selvecs=bfd_elf32_littlearm_vec
;;
- arm-*-elf | arm-*-freebsd* | arm*-*-linux-gnu* | arm*-*-conix* | arm*-*-uclinux*)
+ arm-*-kaos* | strongarm-*-kaos*)
+ targ_defvec=bfd_elf32_littlearm_vec
+ targ_selvecs=bfd_elf32_bigarm_vec
+ ;;
+ arm-*-elf | arm-*-freebsd* | arm*-*-linux-gnu* | arm*-*-conix* | \
+ arm*-*-uclinux* | arm-*-kfreebsd*-gnu | arm-*-vxworks)
targ_defvec=bfd_elf32_littlearm_vec
targ_selvecs=bfd_elf32_bigarm_vec
;;
@@ -261,6 +299,12 @@ case "${targ}" in
targ_defvec=tic30_coff_vec
;;
+ c4x-*-*coff* | tic4x-*-*coff* | tic4x-*-rtems*)
+ targ_defvec=tic4x_coff1_vec
+ targ_selvecs="tic4x_coff1_beh_vec tic4x_coff2_vec tic4x_coff2_beh_vec tic4x_coff0_vec tic4x_coff0_beh_vec"
+ targ_underscore=yes
+ ;;
+
c54x*-*-*coff* | tic54x-*-*coff*)
targ_defvec=tic54x_coff1_vec
targ_selvecs="tic54x_coff1_beh_vec tic54x_coff2_vec tic54x_coff2_beh_vec tic54x_coff0_vec tic54x_coff0_beh_vec"
@@ -292,8 +336,13 @@ case "${targ}" in
frv-*-elf)
targ_defvec=bfd_elf32_frv_vec
+ targ_selvecs=bfd_elf32_frvfdpic_vec
;;
+ frv-*-*linux*)
+ targ_defvec=bfd_elf32_frvfdpic_vec
+ targ_selvecs=bfd_elf32_frv_vec
+ ;;
h8300*-*-elf)
targ_defvec=bfd_elf32_h8300_vec
@@ -322,11 +371,11 @@ case "${targ}" in
;;
#endif
- hppa*-*-linux-gnu*)
+ hppa*-*-linux-gnu* | hppa*-*-netbsd*)
targ_defvec=bfd_elf32_hppa_linux_vec
targ_selvecs=bfd_elf32_hppa_vec
;;
- hppa*-*-*elf* | hppa*-*-lites* | hppa*-*-netbsd* | hppa*-*-sysv4* | hppa*-*-rtems* | hppa*-*-openbsd*)
+ hppa*-*-*elf* | hppa*-*-lites* | hppa*-*-sysv4* | hppa*-*-rtems* | hppa*-*-openbsd*)
targ_defvec=bfd_elf32_hppa_vec
targ_selvecs=bfd_elf32_hppa_linux_vec
;;
@@ -349,94 +398,113 @@ case "${targ}" in
targ_defvec=bfd_elf32_i370_vec
targ_selvecs="bfd_elf32_i370_vec"
;;
- i[3456]86-*-sco3.2v5*coff)
+ i[3-7]86-*-sco3.2v5*coff)
targ_defvec=i386coff_vec
targ_selvecs=bfd_elf32_i386_vec
;;
- i[3456]86-*-sysv4* | i[3456]86-*-unixware* | i[3456]86-*-solaris2* | \
- i[3456]86-*-elf | i[3456]86-*-sco3.2v5* | \
- i[3456]86-*-dgux* | i[3456]86-*-sysv5*)
+ i[3-7]86-*-sysv4* | i[3-7]86-*-unixware* | i[3-7]86-*-solaris2* | \
+ i[3-7]86-*-elf | i[3-7]86-*-sco3.2v5* | \
+ i[3-7]86-*-dgux* | i[3-7]86-*-sysv5*)
targ_defvec=bfd_elf32_i386_vec
targ_selvecs=i386coff_vec
;;
- i[3456]86-*-nto*)
+ i[3-7]86-*-kaos*)
+ targ_defvec=bfd_elf32_i386_vec
+ targ_selvecs=bfd_elf32_i386_vec
+ ;;
+ i[3-7]86-*-nto*)
targ_defvec=bfd_elf32_i386_vec
targ_selvecs=i386coff_vec
;;
- i[3456]86-*-chorus*)
+ i[3-7]86-*-aros*)
+ targ_defvec=bfd_elf32_i386_vec
+ ;;
+ i[3-7]86-*-chorus*)
targ_defvec=bfd_elf32_i386_vec
;;
*-*-msdosdjgpp* | *-*-go32* | *-go32-rtems* )
targ_defvec=go32coff_vec
targ_selvecs="go32stubbedcoff_vec i386aout_vec"
;;
- i[3456]86-*-sysv* | i[3456]86-*-isc* | i[3456]86-*-sco* | i[3456]86-*-coff | \
- i[3456]86-*-aix*)
+ i[3-7]86-*-sysv* | i[3-7]86-*-isc* | i[3-7]86-*-sco* | i[3-7]86-*-coff | \
+ i[3-7]86-*-aix*)
targ_defvec=i386coff_vec
;;
- i[3456]86*-*-rtemscoff*)
+ i[3-7]86*-*-rtemscoff*)
targ_defvec=i386coff_vec
targ_selvecs="bfd_elf32_i386_vec i386aout_vec"
;;
- i[3456]86-*-rtemself* | i[3456]86-*-rtems*)
+ i[3-7]86-*-rtemself* | i[3-7]86-*-rtems*)
targ_defvec=bfd_elf32_i386_vec
targ_selvecs="i386coff_vec i386aout_vec"
;;
- i[3456]86-sequent-bsd*)
+ i[3-7]86-*-darwin* | i[3-7]86-*-macos10* | i[3-7]86-*-rhapsody*)
+ targ_defvec=mach_o_le_vec
+ targ_selvecs="mach_o_le_vec mach_o_be_vec mach_o_fat_vec pef_vec pef_xlib_vec sym_vec"
+ targ_archs="bfd_i386_arch bfd_powerpc_arch bfd_rs6000_arch"
+ ;;
+ i[3-7]86-sequent-bsd*)
targ_defvec=i386dynix_vec
targ_underscore=yes
;;
- i[3456]86-*-bsd*)
+ i[3-7]86-*-bsd*)
targ_defvec=i386bsd_vec
targ_underscore=yes
;;
- i[3456]86-*-freebsdaout* | i[3456]86-*-freebsd[12].* | \
- i[3456]86-*-freebsd[12])
+ i[3-7]86-*-freebsdaout* | i[3-7]86-*-freebsd[12].* | \
+ i[3-7]86-*-freebsd[12])
targ_defvec=i386freebsd_vec
targ_selvecs=i386bsd_vec
targ_underscore=yes
;;
- i[3456]86-*-freebsd*)
+ i[3-7]86-*-freebsd* | i[3-7]86-*-kfreebsd*-gnu)
targ_defvec=bfd_elf32_i386_freebsd_vec
targ_selvecs=i386coff_vec
# FreeBSD <= 4.0 supports only the old nonstandard way of ABI labelling.
case "${targ}" in
- i[3456]86-*-freebsd3* | i[3456]86-*-freebsd4 | i[3456]86-*-freebsd4.0*)
+ i[3-7]86-*-freebsd3* | i[3-7]86-*-freebsd4 | i[3-7]86-*-freebsd4.0*)
targ_cflags=-DOLD_FREEBSD_ABI_LABEL ;;
esac
;;
- i[3456]86-*-netbsdelf*)
+ i[3-7]86-*-netbsdelf* | i[3-7]86-*-netbsd*-gnu* | i[3-7]86-*-knetbsd*-gnu)
targ_defvec=bfd_elf32_i386_vec
targ_selvecs=i386netbsd_vec
+ targ64_selvecs=bfd_elf64_x86_64_vec
;;
- i[3456]86-*-netbsdpe*)
+ i[3-7]86-*-netbsdpe*)
targ_defvec=i386pe_vec
targ_selvecs="i386pe_vec i386pei_vec bfd_elf32_i386_vec"
;;
- i[3456]86-*-netbsdaout* | i[3456]86-*-netbsd* | i[3456]86-*-openbsd*)
+ i[3-7]86-*-netbsdaout* | i[3-7]86-*-netbsd* | \
+ i[3-7]86-*-openbsd[0-2].* | i[3-7]86-*-openbsd3.[0-3])
targ_defvec=i386netbsd_vec
targ_selvecs="bfd_elf32_i386_vec i386bsd_vec"
targ_underscore=yes
;;
- i[3456]86-*-netware*)
+ i[3-7]86-*-openbsd*)
+ targ_defvec=bfd_elf32_i386_vec
+ targ_selvecs=i386netbsd_vec
+ ;;
+ i[3-7]86-*-netware*)
targ_defvec=bfd_elf32_i386_vec
targ_selvecs="nlm32_i386_vec i386coff_vec i386aout_vec"
;;
- i[3456]86-*-linux*aout*)
+ i[3-7]86-*-linux*aout*)
targ_defvec=i386linux_vec
targ_selvecs=bfd_elf32_i386_vec
targ_underscore=yes
;;
- i[3456]86-*-linux-gnu*)
+ i[3-7]86-*-linux-gnu*)
targ_defvec=bfd_elf32_i386_vec
targ_selvecs="i386linux_vec bfd_efi_app_ia32_vec"
+ targ64_selvecs=bfd_elf64_x86_64_vec
;;
#ifdef BFD64
- x86_64-*-freebsd*)
+ x86_64-*-freebsd* | x86_64-*-kfreebsd*-gnu)
targ_defvec=bfd_elf64_x86_64_vec
targ_selvecs="bfd_elf32_i386_vec i386coff_vec bfd_efi_app_ia32_vec"
;;
- x86_64-*-netbsd*)
+ x86_64-*-netbsd* | x86_64-*-openbsd*)
targ_defvec=bfd_elf64_x86_64_vec
targ_selvecs="bfd_elf32_i386_vec i386netbsd_vec i386coff_vec bfd_efi_app_ia32_vec"
;;
@@ -445,58 +513,58 @@ case "${targ}" in
targ_selvecs="bfd_elf32_i386_vec i386linux_vec bfd_efi_app_ia32_vec"
;;
#endif
- i[3456]86-*-lynxos*)
+ i[3-7]86-*-lynxos*)
targ_defvec=i386lynx_coff_vec
targ_selvecs=i386lynx_aout_vec
;;
- i[3456]86-*-gnu*)
+ i[3-7]86-*-gnu*)
targ_defvec=bfd_elf32_i386_vec
;;
- i[3456]86-*-mach* | i[3456]86-*-osf1mk*)
+ i[3-7]86-*-mach* | i[3-7]86-*-osf1mk*)
targ_defvec=i386mach3_vec
targ_cflags=-DSTAT_FOR_EXEC
targ_underscore=yes
;;
- i[3456]86-*-os9k)
+ i[3-7]86-*-os9k)
targ_defvec=i386os9k_vec
;;
- i[3456]86-*-msdos*)
+ i[3-7]86-*-msdos*)
targ_defvec=i386aout_vec
targ_selvecs=i386msdos_vec
;;
- i[3456]86-*-moss*)
+ i[3-7]86-*-moss*)
targ_defvec=bfd_elf32_i386_vec
targ_selvecs="i386msdos_vec i386aout_vec"
;;
- i[3456]86-*-beospe*)
+ i[3-7]86-*-beospe*)
targ_defvec=i386pe_vec
targ_selvecs="i386pe_vec i386pei_vec"
;;
- i[3456]86-*-beoself* | i[3456]86-*-beos*)
+ i[3-7]86-*-beoself* | i[3-7]86-*-beos*)
targ_defvec=bfd_elf32_i386_vec
targ_selvecs="i386pe_vec i386pei_vec"
;;
- i[3456]86-*-interix*)
+ i[3-7]86-*-interix*)
targ_defvec=i386pei_vec
targ_selvecs="i386pe_vec"
# FIXME: This should eventually be checked at runtime.
targ_cflags=-DSTRICT_PE_FORMAT
;;
- i[3456]86-*-mingw32* | i[3456]86-*-cygwin* | i[3456]86-*-winnt | i[3456]86-*-pe)
+ i[3-7]86-*-mingw32* | i[3-7]86-*-cygwin* | i[3-7]86-*-winnt | i[3-7]86-*-pe)
targ_defvec=i386pe_vec
targ_selvecs="i386pe_vec i386pei_vec bfd_elf32_i386_vec"
;;
- i[3456]86-none-*)
+ i[3-7]86-none-*)
targ_defvec=i386coff_vec
;;
- i[3456]86-*-aout* | i[3456]86*-*-vsta*)
+ i[3-7]86-*-aout* | i[3-7]86*-*-vsta*)
targ_defvec=i386aout_vec
;;
- i[3456]86-*-vxworks*)
- targ_defvec=i386aout_vec
+ i[3-7]86-*-vxworks)
+ targ_defvec=bfd_elf32_i386_vec
targ_underscore=yes
;;
- i[3456]86-*-chaos)
+ i[3-7]86-*-chaos)
targ_defvec=bfd_elf32_i386_vec
targ_selfvecs=i386chaos_vec
;;
@@ -532,6 +600,29 @@ case "${targ}" in
targ_selvecs="icoff_little_vec icoff_big_vec"
;;
+ ip2k-*-elf)
+ targ_defvec=bfd_elf32_ip2k_vec
+ ;;
+
+ iq2000-*-elf)
+ targ_defvec=bfd_elf32_iq2000_vec
+ ;;
+
+ m32r*le-*-linux*)
+ targ_defvec=bfd_elf32_m32rlelin_vec
+ targ_selvecs="bfd_elf32_m32rlin_vec bfd_elf32_m32rlelin_vec"
+ ;;
+
+ m32r*-*-linux*)
+ targ_defvec=bfd_elf32_m32rlin_vec
+ targ_selvecs="bfd_elf32_m32rlin_vec bfd_elf32_m32rlelin_vec"
+ ;;
+
+ m32r*le-*-*)
+ targ_defvec=bfd_elf32_m32rle_vec
+ targ_selvecs="bfd_elf32_m32r_vec bfd_elf32_m32rle_vec"
+ ;;
+
m32r-*-*)
targ_defvec=bfd_elf32_m32r_vec
;;
@@ -571,7 +662,7 @@ case "${targ}" in
targ_defvec=m68kcoff_vec
targ_selvecs="m68kcoff_vec versados_vec ieee_vec aout0_big_vec"
;;
- m68*-*-elf* | m68*-*-sysv4*)
+ m68*-*-elf* | m68*-*-sysv4* | m68*-*-uclinux*)
targ_defvec=bfd_elf32_m68k_vec
targ_selvecs="m68kcoff_vec ieee_vec"
;;
@@ -675,19 +766,11 @@ case "${targ}" in
;;
mips*el-*-netbsd*)
targ_defvec=bfd_elf32_littlemips_vec
- targ_selvecs="bfd_elf32_bigmips_vec ecoff_little_vec ecoff_big_vec"
+ targ_selvecs="bfd_elf32_bigmips_vec bfd_elf64_bigmips_vec bfd_elf64_littlemips_vec ecoff_little_vec ecoff_big_vec"
;;
mips*-*-netbsd*)
targ_defvec=bfd_elf32_bigmips_vec
- targ_selvecs="bfd_elf32_littlemips_vec ecoff_big_vec ecoff_little_vec"
- ;;
- mips*-dec-bsd*)
- targ_defvec=aout_mips_little_vec
- targ_underscore=yes
- ;;
- mips*-dec-mach3*)
- targ_defvec=aout_mips_little_vec
- targ_cflags=-DSTAT_FOR_EXEC
+ targ_selvecs="bfd_elf32_littlemips_vec bfd_elf64_bigmips_vec bfd_elf64_littlemips_vec ecoff_big_vec ecoff_little_vec"
;;
mips*-dec-* | mips*el-*-ecoff*)
targ_defvec=ecoff_little_vec
@@ -699,8 +782,8 @@ case "${targ}" in
;;
#ifdef BFD64
mips*-*-irix6*)
- targ_defvec=bfd_elf32_bigmips_vec
- targ_selvecs="bfd_elf32_littlemips_vec bfd_elf64_bigmips_vec bfd_elf64_littlemips_vec"
+ targ_defvec=bfd_elf32_nbigmips_vec
+ targ_selvecs="bfd_elf32_nlittlemips_vec bfd_elf32_bigmips_vec bfd_elf32_littlemips_vec bfd_elf64_bigmips_vec bfd_elf64_littlemips_vec"
;;
#endif
mips*-*-irix5*)
@@ -715,15 +798,6 @@ case "${targ}" in
targ_defvec=ecoff_biglittle_vec
targ_selvecs="ecoff_little_vec ecoff_big_vec"
;;
- mips*-*-mach3*)
- targ_defvec=aout_mips_little_vec
- targ_cflags=-DSTAT_FOR_EXEC
- ;;
- mips*-*-pe*)
- targ_defvec=mipslpe_vec
- targ_selvecs="mipslpei_vec mipslpei_vec ecoff_little_vec ecoff_big_vec"
- targ_underscore=yes
- ;;
mips*-*-sysv4*)
targ_defvec=bfd_elf32_tradbigmips_vec
targ_selvecs="bfd_elf32_tradlittlemips_vec ecoff_big_vec ecoff_little_vec"
@@ -736,7 +810,7 @@ case "${targ}" in
targ_defvec=bfd_elf32_littlemips_vec
targ_selvecs="bfd_elf32_bigmips_vec bfd_elf64_bigmips_vec bfd_elf64_littlemips_vec"
;;
- mips*-*-elf* | mips*-*-rtems* | mips*-*-vxworks*)
+ mips*-*-elf* | mips*-*-rtems* | mips*-*-vxworks | mips*-*-windiss)
targ_defvec=bfd_elf32_bigmips_vec
targ_selvecs="bfd_elf32_littlemips_vec bfd_elf64_bigmips_vec bfd_elf64_littlemips_vec"
;;
@@ -754,21 +828,23 @@ case "${targ}" in
;;
#ifdef BFD64
mips64*el-*-linux*)
- targ_defvec=bfd_elf32_tradlittlemips_vec
- targ_selvecs="bfd_elf32_tradbigmips_vec bfd_elf64_tradlittlemips_vec bfd_elf64_tradbigmips_vec"
+ targ_defvec=bfd_elf32_ntradlittlemips_vec
+ targ_selvecs="bfd_elf32_ntradbigmips_vec bfd_elf32_tradlittlemips_vec bfd_elf32_tradbigmips_vec bfd_elf64_tradlittlemips_vec bfd_elf64_tradbigmips_vec"
;;
mips64*-*-linux*)
- targ_defvec=bfd_elf32_tradbigmips_vec
- targ_selvecs="bfd_elf32_tradlittlemips_vec bfd_elf64_tradbigmips_vec bfd_elf64_tradlittlemips_vec"
+ targ_defvec=bfd_elf32_ntradbigmips_vec
+ targ_selvecs="bfd_elf32_ntradlittlemips_vec bfd_elf32_tradbigmips_vec bfd_elf32_tradlittlemips_vec bfd_elf64_tradbigmips_vec bfd_elf64_tradlittlemips_vec"
;;
#endif
mips*el-*-linux*)
targ_defvec=bfd_elf32_tradlittlemips_vec
- targ_selvecs="bfd_elf32_tradbigmips_vec bfd_elf64_tradlittlemips_vec bfd_elf64_tradbigmips_vec ecoff_little_vec ecoff_big_vec"
+ targ_selvecs="bfd_elf32_tradbigmips_vec ecoff_little_vec ecoff_big_vec bfd_elf32_ntradlittlemips_vec bfd_elf64_tradlittlemips_vec bfd_elf32_ntradbigmips_vec bfd_elf64_tradbigmips_vec"
+ want64=true
;;
mips*-*-linux*)
targ_defvec=bfd_elf32_tradbigmips_vec
- targ_selvecs="bfd_elf32_tradlittlemips_vec bfd_elf64_tradbigmips_vec bfd_elf64_tradlittlemips_vec ecoff_big_vec ecoff_little_vec"
+ targ_selvecs="bfd_elf32_tradlittlemips_vec ecoff_big_vec ecoff_little_vec bfd_elf32_ntradbigmips_vec bfd_elf64_tradbigmips_vec bfd_elf32_ntradlittlemips_vec bfd_elf64_tradlittlemips_vec"
+ want64=true
;;
#ifdef BFD64
mmix-*-*)
@@ -782,6 +858,11 @@ case "${targ}" in
mn10300-*-*)
targ_defvec=bfd_elf32_mn10300_vec
+ targ_underscore=yes
+ ;;
+
+ msp430-*-*)
+ targ_defvec=bfd_elf32_msp430_vec
;;
ns32k-pc532-mach* | ns32k-pc532-ux*)
@@ -797,12 +878,12 @@ case "${targ}" in
targ_defvec=bfd_elf32_openrisc_vec
;;
- or32-*-coff | or32-*-rtems*)
+ or32-*-coff)
targ_defvec=or32coff_big_vec
targ_underscore=yes
;;
- or32-*-elf)
+ or32-*-elf | or32-*-rtems*)
targ_defvec=bfd_elf32_or32_big_vec
;;
@@ -821,13 +902,27 @@ case "${targ}" in
targ_selvecs="bfd_elf32_pjl_vec bfd_elf32_pj_vec bfd_elf32_i386_vec"
;;
+ powerpc-*-aix5.[01])
+ targ_defvec=rs6000coff_vec
+ targ_selvecs="aix5coff64_vec"
+ want64=true
+ ;;
+#ifdef BFD64
+ powerpc64-*-aix5.[01])
+ targ_defvec=aix5coff64_vec
+ targ_selvecs="rs6000coff_vec"
+ want64=true
+ ;;
+#endif
powerpc-*-aix5*)
+ targ_cflags=-DAIX_WEAK_SUPPORT
targ_defvec=rs6000coff_vec
targ_selvecs="aix5coff64_vec"
want64=true
;;
#ifdef BFD64
powerpc64-*-aix5*)
+ targ_cflags=-DAIX_WEAK_SUPPORT
targ_defvec=aix5coff64_vec
targ_selvecs="rs6000coff_vec"
want64=true
@@ -840,7 +935,6 @@ case "${targ}" in
case "${targ}" in
*-*-aix4.[3456789]* | *-*-aix[56789]*)
want64=true;;
-
*)
targ_cflags=-DSMALL_ARCHIVE;;
esac
@@ -850,7 +944,8 @@ case "${targ}" in
targ_defvec=rs6000coff64_vec
targ_selvecs=rs6000coff_vec
;;
- powerpc64-*-elf* | powerpc-*-elf64* | powerpc64-*-linux*)
+ powerpc64-*-elf* | powerpc-*-elf64* | powerpc64-*-linux* | \
+ powerpc64-*-*bsd*)
targ_defvec=bfd_elf64_powerpc_vec
targ_selvecs="bfd_elf64_powerpcle_vec bfd_elf32_powerpc_vec bfd_elf32_powerpcle_vec rs6000coff_vec rs6000coff64_vec"
;;
@@ -866,6 +961,16 @@ case "${targ}" in
targ_selvecs="rs6000coff_vec bfd_elf32_powerpcle_vec ppcboot_vec"
targ64_selvecs="bfd_elf64_powerpc_vec bfd_elf64_powerpcle_vec"
;;
+ powerpc-*-kaos*)
+ targ_defvec=bfd_elf32_powerpc_vec
+ targ_selvecs="bfd_elf32_powerpcle_vec ppcboot_vec"
+ targ64_selvecs="bfd_elf64_powerpc_vec bfd_elf64_powerpcle_vec"
+ ;;
+ powerpc-*-darwin* | powerpc-*-macos10* | powerpc-*-rhapsody*)
+ targ_defvec=mach_o_be_vec
+ targ_selvecs="mach_o_be_vec mach_o_le_vec mach_o_fat_vec pef_vec pef_xlib_vec sym_vec"
+ targ_archs="bfd_powerpc_arch bfd_rs6000_arch bfd_i386_arch"
+ ;;
powerpc-*-macos* | powerpc-*-mpw*)
targ_defvec=pmac_xcoff_vec
;;
@@ -873,6 +978,14 @@ case "${targ}" in
targ_defvec=bfd_elf32_powerpc_vec
targ_selvecs="nlm32_powerpc_vec rs6000coff_vec"
;;
+ powerpc-*-nto*)
+ targ_defvec=bfd_elf32_powerpc_vec
+ targ_selvecs="rs6000coff_vec bfd_elf32_powerpcle_vec ppcboot_vec"
+ ;;
+ powerpcle-*-nto*)
+ targ_defvec=bfd_elf32_powerpcle_vec
+ targ_selvecs="rs6000coff_vec bfd_elf32_powerpc_vec ppcboot_vec"
+ ;;
powerpcle-*-elf* | powerpcle-*-sysv4* | powerpcle-*-eabi* | \
powerpcle-*-solaris2* | powerpcle-*-linux-gnu* | powerpcle-*-vxworks* |\
powerpcle-*-rtems*)
@@ -880,7 +993,6 @@ case "${targ}" in
targ_selvecs="rs6000coff_vec bfd_elf32_powerpc_vec ppcboot_vec"
targ64_selvecs="bfd_elf64_powerpc_vec bfd_elf64_powerpcle_vec"
;;
-
powerpcle-*-pe | powerpcle-*-winnt* | powerpcle-*-cygwin*)
targ_defvec=bfd_powerpcle_pe_vec
targ_selvecs="bfd_powerpcle_pei_vec bfd_powerpc_pei_vec bfd_powerpcle_pe_vec bfd_powerpc_pe_vec"
@@ -909,12 +1021,12 @@ case "${targ}" in
targ_underscore=yes
;;
sh64eb-*-linux*)
- targ_defvec=bfd_elf32_shblin_vec
- targ_selvecs="bfd_elf32_shblin_vec bfd_elf32_sh64_vec bfd_elf64_sh64_vec bfd_elf32_sh_vec"
+ targ_defvec=bfd_elf32_sh64blin_vec
+ targ_selvecs="bfd_elf32_sh64lin_vec bfd_elf64_sh64blin_vec bfd_elf64_sh64lin_vec bfd_elf32_shblin_vec bfd_elf32_shlin_vec"
;;
sh64-*-linux*)
- targ_defvec=bfd_elf32_shlin_vec
- targ_selvecs="bfd_elf32_shlin_vec bfd_elf32_sh64l_vec bfd_elf64_sh64l_vec bfd_elf32_shl_vec"
+ targ_defvec=bfd_elf32_sh64lin_vec
+ targ_selvecs="bfd_elf32_sh64blin_vec bfd_elf64_sh64lin_vec bfd_elf64_sh64blin_vec bfd_elf32_shlin_vec bfd_elf32_shblin_vec"
;;
#endif /* BFD64 */
@@ -922,7 +1034,7 @@ case "${targ}" in
targ_defvec=bfd_elf32_shblin_vec
targ_selvecs=bfd_elf32_shlin_vec
#ifdef BFD64
- targ_selvecs="${targ_selvecs} bfd_elf32_sh64_vec bfd_elf32_sh64l_vec bfd_elf64_sh64_vec bfd_elf64_sh64l_vec"
+ targ_selvecs="${targ_selvecs} bfd_elf32_sh64lin_vec bfd_elf32_sh64blin_vec bfd_elf64_sh64lin_vec bfd_elf64_sh64blin_vec"
#endif
;;
sh*eb-*-linux*)
@@ -954,30 +1066,25 @@ case "${targ}" in
;;
#endif
- shle-*-netbsdelf*)
+ sh*l*-*-netbsdelf*)
targ_defvec=bfd_elf32_shlnbsd_vec
targ_selvecs="bfd_elf32_shnbsd_vec shcoff_vec shlcoff_vec"
#ifdef BFD64
- targ_selvecs="${targ_selvecs} bfd_elf32_sh64_vec bfd_elf32_sh64l_vec bfd_elf64_sh64_vec bfd_elf64_sh64l_vec"
+ targ_selvecs="${targ_selvecs} bfd_elf32_sh64lnbsd_vec bfd_elf32_sh64nbsd_vec bfd_elf64_sh64lnbsd_vec bfd_elf64_sh64nbsd_vec"
#endif
;;
- sh*le-*-netbsdelf*)
- targ_defvec=bfd_elf32_shlnbsd_vec
- targ_selvecs="bfd_elf32_shnbsd_vec shcoff_vec shlcoff_vec"
- ;;
sh-*-netbsdelf*)
targ_defvec=bfd_elf32_shnbsd_vec
targ_selvecs="bfd_elf32_shlnbsd_vec shcoff_vec shlcoff_vec"
#ifdef BFD64
- targ_selvecs="${targ_selvecs} bfd_elf32_sh64_vec bfd_elf32_sh64l_vec bfd_elf64_sh64_vec bfd_elf64_sh64l_vec"
+ targ_selvecs="${targ_selvecs} bfd_elf32_sh64lnbsd_vec bfd_elf32_sh64nbsd_vec bfd_elf64_sh64lnbsd_vec bfd_elf64_sh64nbsd_vec"
#endif
;;
sh*-*-netbsdelf*)
targ_defvec=bfd_elf32_shnbsd_vec
targ_selvecs="bfd_elf32_shlnbsd_vec shcoff_vec shlcoff_vec"
;;
-
- shl*-*-elf* | sh[1234]l*-*-elf* | sh3el*-*-elf*)
+ shl*-*-elf* | sh[1234]l*-*-elf* | sh3el*-*-elf* | shl*-*-kaos*)
targ_defvec=bfd_elf32_shl_vec
targ_selvecs="bfd_elf32_sh_vec shlcoff_vec shcoff_vec shlcoff_small_vec shcoff_small_vec"
#ifdef BFD64
@@ -985,7 +1092,12 @@ case "${targ}" in
#endif
targ_underscore=yes
;;
- sh-*-elf* | sh[1234]*-elf* | sh-*-rtemself*)
+ sh-*-rtemscoff*)
+ targ_defvec=shcoff_vec
+ targ_selvecs="shcoff_vec shlcoff_vec shcoff_small_vec shlcoff_small_vec"
+ targ_underscore=yes
+ ;;
+ sh-*-elf* | sh[1234]*-elf* | sh-*-rtems* | sh-*-kaos*)
targ_defvec=bfd_elf32_sh_vec
targ_selvecs="bfd_elf32_shl_vec shcoff_vec shlcoff_vec shcoff_small_vec shlcoff_small_vec"
#ifdef BFD64
@@ -993,12 +1105,25 @@ case "${targ}" in
#endif
targ_underscore=yes
;;
+ sh-*-nto*)
+ targ_defvec=bfd_elf32_sh_vec
+ targ_selvecs="bfd_elf32_shl_vec shcoff_vec shlcoff_vec shcoff_small_vec shlcoff_small_vec"
+ targ_underscore=yes
+ ;;
sh-*-pe)
targ_defvec=shlpe_vec
targ_selvecs="shlpe_vec shlpei_vec"
targ_underscore=yes
;;
- sh-*-* | sh-*-rtems*)
+ sh-*-vxworks)
+ targ_defvec=bfd_elf32_sh_vec
+ targ_selvecs="bfd_elf32_shl_vec"
+ # FIXME None of the following are actually used on this target, but
+ # they're necessary for coff-sh.c (which is unconditionally used) to be
+ # compiled correctly.
+ targ_selvecs="$targ_selvecs shcoff_vec shlcoff_vec shcoff_small_vec shlcoff_small_vec"
+ ;;
+ sh-*-*)
targ_defvec=shcoff_vec
targ_selvecs="shcoff_vec shlcoff_vec shcoff_small_vec shlcoff_small_vec"
targ_underscore=yes
@@ -1041,10 +1166,14 @@ case "${targ}" in
targ_selvecs=bfd_elf32_sparc_vec
targ_underscore=yes
;;
- sparc-*-openbsd*)
+ sparc-*-openbsd[0-2].* | sparc-*-openbsd3.[0-1])
targ_defvec=sparcnetbsd_vec
targ_underscore=yes
;;
+ sparc-*-openbsd*)
+ targ_defvec=bfd_elf32_sparc_vec
+ targ_selvecs=sparcnetbsd_vec
+ ;;
sparc-*-elf* | sparc-*-solaris2.[0-6] | sparc-*-solaris2.[0-6].*)
targ_defvec=bfd_elf32_sparc_vec
targ_selvecs=sunos_big_vec
@@ -1105,7 +1234,6 @@ case "${targ}" in
targ_underscore=yes
;;
-
v850-*-*)
targ_defvec=bfd_elf32_v850_vec
;;
@@ -1132,6 +1260,15 @@ case "${targ}" in
targ_underscore=yes
;;
+ vax-*-openbsd*)
+ targ_defvec=vaxnetbsd_vec
+ targ_underscore=yes
+ ;;
+
+ vax-*-linux-gnu*)
+ targ_defvec=bfd_elf32_vax_vec
+ ;;
+
vax*-*-*vms*)
targ_defvec=vms_vax_vec
;;
@@ -1148,6 +1285,11 @@ case "${targ}" in
targ_defvec=bfd_elf32_xstormy16_vec
;;
+ xtensa-*-*)
+ targ_defvec=bfd_elf32_xtensa_le_vec
+ targ_selvecs=bfd_elf32_xtensa_be_vec
+ ;;
+
z8k*-*-*)
targ_defvec=z8kcoff_vec
targ_underscore=yes
@@ -1190,7 +1332,7 @@ esac
# to be used on an arbitrary ELF file for anything other than
# relocation information.
case "${targ_defvec} ${targ_selvecs}" in
- *bfd_elf64*)
+ *bfd_elf64* | *bfd_elf32_n*mips*)
targ_selvecs="${targ_selvecs} bfd_elf64_little_generic_vec bfd_elf64_big_generic_vec bfd_elf32_little_generic_vec bfd_elf32_big_generic_vec"
;;
*bfd_elf32*)
diff --git a/contrib/binutils/bfd/config.in b/contrib/binutils/bfd/config.in
index d13d196..ef9eca4 100644
--- a/contrib/binutils/bfd/config.in
+++ b/contrib/binutils/bfd/config.in
@@ -1,4 +1,4 @@
-/* config.in. Generated automatically from configure.in by autoheader 2.13. */
+/* config.in. Generated automatically from configure.in by autoheader. */
/* Define if using alloca.c. */
#undef C_ALLOCA
@@ -25,9 +25,6 @@
/* Define to `long' if <sys/types.h> doesn't define. */
#undef off_t
-/* Define if you need to in order for stat and other things to work. */
-#undef _POSIX_SOURCE
-
/* Define to `unsigned' if <sys/types.h> doesn't define. */
#undef size_t
@@ -64,6 +61,18 @@
/* Define if you have the fdopen function. */
#undef HAVE_FDOPEN
+/* Define if you have the fseeko function. */
+#undef HAVE_FSEEKO
+
+/* Define if you have the fseeko64 function. */
+#undef HAVE_FSEEKO64
+
+/* Define if you have the ftello function. */
+#undef HAVE_FTELLO
+
+/* Define if you have the ftello64 function. */
+#undef HAVE_FTELLO64
+
/* Define if you have the getcwd function. */
#undef HAVE_GETCWD
@@ -106,6 +115,9 @@
/* Define if you have the strchr function. */
#undef HAVE_STRCHR
+/* Define if you have the strtoull function. */
+#undef HAVE_STRTOULL
+
/* Define if you have the sysconf function. */
#undef HAVE_SYSCONF
@@ -190,6 +202,12 @@
/* Define as 1 if you have gettext and don't want to use GNU gettext. */
#undef HAVE_GETTEXT
+/* The number of bytes in type long long */
+#undef SIZEOF_LONG_LONG
+
+/* The number of bytes in type long */
+#undef SIZEOF_LONG
+
/* Use b modifier when opening binary files? */
#undef USE_BINARY_FOPEN
@@ -262,6 +280,9 @@
/* Name of host specific header file to include in trad-core.c. */
#undef TRAD_HEADER
+/* The number of bytes in type off_t */
+#undef SIZEOF_OFF_T
+
/* Use mmap if it's available? */
#undef USE_MMAP
diff --git a/contrib/binutils/bfd/configure b/contrib/binutils/bfd/configure
index 2eca955..49516021 100755
--- a/contrib/binutils/bfd/configure
+++ b/contrib/binutils/bfd/configure
@@ -37,7 +37,7 @@ ac_help="$ac_help
--enable-maintainer-mode enable make rules and dependencies not useful
(and sometimes confusing) to the casual installer"
ac_help="$ac_help
- --install-libbfd controls installation of libbfd and related headers"
+ --enable-install-libbfd controls installation of libbfd and related headers"
ac_help="$ac_help
--disable-nls do not use Native Language Support"
ac_help="$ac_help
@@ -723,250 +723,51 @@ test "$host_alias" != "$target_alias" &&
NONENONEs,x,x, &&
program_prefix=${target_alias}-
-# Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:730: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_CC="gcc"
- break
- fi
- done
- IFS="$ac_save_ifs"
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-if test -z "$CC"; then
- # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:760: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_prog_rejected=no
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
- ac_prog_rejected=yes
- continue
- fi
- ac_cv_prog_CC="cc"
- break
- fi
- done
- IFS="$ac_save_ifs"
-if test $ac_prog_rejected = yes; then
- # We found a bogon in the path, so make sure we never use it.
- set dummy $ac_cv_prog_CC
- shift
- if test $# -gt 0; then
- # We chose a different compiler from the bogus one.
- # However, it has the same basename, so the bogon will be chosen
- # first if we set CC to just the basename; use the full file name.
- shift
- set dummy "$ac_dir/$ac_word" "$@"
- shift
- ac_cv_prog_CC="$@"
- fi
-fi
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
- if test -z "$CC"; then
- case "`uname -s`" in
- *win32* | *WIN32*)
- # Extract the first word of "cl", so it can be a program name with args.
-set dummy cl; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:811: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+ echo $ac_n "checking for strerror in -lcposix""... $ac_c" 1>&6
+echo "configure:729: checking for strerror in -lcposix" >&5
+ac_lib_var=`echo cposix'_'strerror | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_CC="cl"
- break
- fi
- done
- IFS="$ac_save_ifs"
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
- ;;
- esac
- fi
- test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
-fi
-
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:843: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
-
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-cat > conftest.$ac_ext << EOF
-
-#line 854 "configure"
+ ac_save_LIBS="$LIBS"
+LIBS="-lcposix $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 737 "configure"
#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error. */
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char strerror();
-main(){return(0);}
+int main() {
+strerror()
+; return 0; }
EOF
-if { (eval echo configure:859: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- ac_cv_prog_cc_works=yes
- # If we can't run a trivial program, we are probably using a cross compiler.
- if (./conftest; exit) 2>/dev/null; then
- ac_cv_prog_cc_cross=no
- else
- ac_cv_prog_cc_cross=yes
- fi
+if { (eval echo configure:748: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ rm -rf conftest*
+ eval "ac_cv_lib_$ac_lib_var=yes"
else
echo "configure: failed program was:" >&5
cat conftest.$ac_ext >&5
- ac_cv_prog_cc_works=no
-fi
-rm -fr conftest*
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
-if test $ac_cv_prog_cc_works = no; then
- { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
-fi
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:885: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
-echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
-cross_compiling=$ac_cv_prog_cc_cross
-
-echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:890: checking whether we are using GNU C" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.c <<EOF
-#ifdef __GNUC__
- yes;
-#endif
-EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:899: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
- ac_cv_prog_gcc=yes
-else
- ac_cv_prog_gcc=no
-fi
-fi
-
-echo "$ac_t""$ac_cv_prog_gcc" 1>&6
-
-if test $ac_cv_prog_gcc = yes; then
- GCC=yes
-else
- GCC=
-fi
-
-ac_test_CFLAGS="${CFLAGS+set}"
-ac_save_CFLAGS="$CFLAGS"
-CFLAGS=
-echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:918: checking whether ${CC-cc} accepts -g" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- echo 'void f(){}' > conftest.c
-if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
- ac_cv_prog_cc_g=yes
-else
- ac_cv_prog_cc_g=no
+ rm -rf conftest*
+ eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
+LIBS="$ac_save_LIBS"
fi
-
-echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
-if test "$ac_test_CFLAGS" = set; then
- CFLAGS="$ac_save_CFLAGS"
-elif test $ac_cv_prog_cc_g = yes; then
- if test "$GCC" = yes; then
- CFLAGS="-g -O2"
- else
- CFLAGS="-g"
- fi
-else
- if test "$GCC" = yes; then
- CFLAGS="-O2"
- else
- CFLAGS=
- fi
-fi
-
-echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
-echo "configure:950: checking for POSIXized ISC" >&5
-if test -d /etc/conf/kconfig.d &&
- grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
-then
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
- ISC=yes # If later tests want to check for ISC.
- cat >> confdefs.h <<\EOF
-#define _POSIX_SOURCE 1
-EOF
-
- if test "$GCC" = yes; then
- CC="$CC -posix"
- else
- CC="$CC -Xp"
- fi
+ LIBS="$LIBS -lcposix"
else
echo "$ac_t""no" 1>&6
- ISC=
fi
+
+
+am__api_version="1.4"
# Find a good install program. We prefer a C program (faster),
# so one script is as good as another. But avoid the broken or
# incompatible versions:
@@ -979,7 +780,7 @@ fi
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:983: checking for a BSD compatible install" >&5
+echo "configure:784: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1032,7 +833,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:1036: checking whether build environment is sane" >&5
+echo "configure:837: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -1089,7 +890,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:1093: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:894: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1118,7 +919,7 @@ fi
PACKAGE=bfd
-VERSION=2.13.1
+VERSION=2.15
if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
{ echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
@@ -1134,21 +935,21 @@ EOF
missing_dir=`cd $ac_aux_dir && pwd`
-echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:1139: checking for working aclocal" >&5
+echo $ac_n "checking for working aclocal-${am__api_version}""... $ac_c" 1>&6
+echo "configure:940: checking for working aclocal-${am__api_version}" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
-if (aclocal --version) < /dev/null > /dev/null 2>&1; then
- ACLOCAL=aclocal
+if (aclocal-${am__api_version} --version) < /dev/null > /dev/null 2>&1; then
+ ACLOCAL=aclocal-${am__api_version}
echo "$ac_t""found" 1>&6
else
- ACLOCAL="$missing_dir/missing aclocal"
+ ACLOCAL="$missing_dir/missing aclocal-${am__api_version}"
echo "$ac_t""missing" 1>&6
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:1152: checking for working autoconf" >&5
+echo "configure:953: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1160,21 +961,21 @@ else
echo "$ac_t""missing" 1>&6
fi
-echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:1165: checking for working automake" >&5
+echo $ac_n "checking for working automake-${am__api_version}""... $ac_c" 1>&6
+echo "configure:966: checking for working automake-${am__api_version}" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
-if (automake --version) < /dev/null > /dev/null 2>&1; then
- AUTOMAKE=automake
+if (automake-${am__api_version} --version) < /dev/null > /dev/null 2>&1; then
+ AUTOMAKE=automake-${am__api_version}
echo "$ac_t""found" 1>&6
else
- AUTOMAKE="$missing_dir/missing automake"
+ AUTOMAKE="$missing_dir/missing automake-${am__api_version}"
echo "$ac_t""missing" 1>&6
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:1178: checking for working autoheader" >&5
+echo "configure:979: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1187,7 +988,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:1191: checking for working makeinfo" >&5
+echo "configure:992: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1201,19 +1002,18 @@ fi
# Uncomment the next line to remove the date from the reported bfd version
-# is_release=y
+#is_release=y
bfd_version=`echo "${VERSION}" | sed -e 's/\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\).*/\1.00\2.00\3.00\4.00\5/' -e 's/\([^\.]*\)\..*\(..\)\..*\(..\)\..*\(..\)\..*\(..\)$/\1\2\3\4\5/'`
bfd_version_string="\"${VERSION}\""
-bfd_version_date=`sed -e 's/.*DATE //' < ${srcdir}/version.h`
if test x${is_release} = x; then
+ bfd_version_date=`sed -n -e 's/.*DATE //p' < ${srcdir}/version.h`
bfd_version_string="\"${VERSION} ${bfd_version_date}\""
fi
-
if test $host != $build; then
ac_tool_prefix=${host_alias}-
else
@@ -1223,7 +1023,7 @@ fi
# Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
set dummy ${ac_tool_prefix}ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1227: checking for $ac_word" >&5
+echo "configure:1027: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1255,7 +1055,7 @@ fi
# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1259: checking for $ac_word" >&5
+echo "configure:1059: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1287,7 +1087,7 @@ if test -n "$ac_tool_prefix"; then
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1291: checking for $ac_word" >&5
+echo "configure:1091: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1390,6 +1190,228 @@ else
enable_fast_install=yes
fi
+# Extract the first word of "gcc", so it can be a program name with args.
+set dummy gcc; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:1197: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$CC"; then
+ ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_CC="gcc"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+CC="$ac_cv_prog_CC"
+if test -n "$CC"; then
+ echo "$ac_t""$CC" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+if test -z "$CC"; then
+ # Extract the first word of "cc", so it can be a program name with args.
+set dummy cc; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:1227: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$CC"; then
+ ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_prog_rejected=no
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
+ ac_prog_rejected=yes
+ continue
+ fi
+ ac_cv_prog_CC="cc"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+if test $ac_prog_rejected = yes; then
+ # We found a bogon in the path, so make sure we never use it.
+ set dummy $ac_cv_prog_CC
+ shift
+ if test $# -gt 0; then
+ # We chose a different compiler from the bogus one.
+ # However, it has the same basename, so the bogon will be chosen
+ # first if we set CC to just the basename; use the full file name.
+ shift
+ set dummy "$ac_dir/$ac_word" "$@"
+ shift
+ ac_cv_prog_CC="$@"
+ fi
+fi
+fi
+fi
+CC="$ac_cv_prog_CC"
+if test -n "$CC"; then
+ echo "$ac_t""$CC" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ if test -z "$CC"; then
+ case "`uname -s`" in
+ *win32* | *WIN32*)
+ # Extract the first word of "cl", so it can be a program name with args.
+set dummy cl; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:1278: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$CC"; then
+ ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_CC="cl"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+CC="$ac_cv_prog_CC"
+if test -n "$CC"; then
+ echo "$ac_t""$CC" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+ ;;
+ esac
+ fi
+ test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
+fi
+
+echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
+echo "configure:1310: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+
+ac_ext=c
+# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
+ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
+cross_compiling=$ac_cv_prog_cc_cross
+
+cat > conftest.$ac_ext << EOF
+
+#line 1321 "configure"
+#include "confdefs.h"
+
+main(){return(0);}
+EOF
+if { (eval echo configure:1326: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ ac_cv_prog_cc_works=yes
+ # If we can't run a trivial program, we are probably using a cross compiler.
+ if (./conftest; exit) 2>/dev/null; then
+ ac_cv_prog_cc_cross=no
+ else
+ ac_cv_prog_cc_cross=yes
+ fi
+else
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+ ac_cv_prog_cc_works=no
+fi
+rm -fr conftest*
+ac_ext=c
+# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
+ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
+cross_compiling=$ac_cv_prog_cc_cross
+
+echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
+if test $ac_cv_prog_cc_works = no; then
+ { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
+fi
+echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
+echo "configure:1352: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
+cross_compiling=$ac_cv_prog_cc_cross
+
+echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
+echo "configure:1357: checking whether we are using GNU C" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ cat > conftest.c <<EOF
+#ifdef __GNUC__
+ yes;
+#endif
+EOF
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1366: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+ ac_cv_prog_gcc=yes
+else
+ ac_cv_prog_gcc=no
+fi
+fi
+
+echo "$ac_t""$ac_cv_prog_gcc" 1>&6
+
+if test $ac_cv_prog_gcc = yes; then
+ GCC=yes
+else
+ GCC=
+fi
+
+ac_test_CFLAGS="${CFLAGS+set}"
+ac_save_CFLAGS="$CFLAGS"
+CFLAGS=
+echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
+echo "configure:1385: checking whether ${CC-cc} accepts -g" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ echo 'void f(){}' > conftest.c
+if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
+ ac_cv_prog_cc_g=yes
+else
+ ac_cv_prog_cc_g=no
+fi
+rm -f conftest*
+
+fi
+
+echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
+if test "$ac_test_CFLAGS" = set; then
+ CFLAGS="$ac_save_CFLAGS"
+elif test $ac_cv_prog_cc_g = yes; then
+ if test "$GCC" = yes; then
+ CFLAGS="-g -O2"
+ else
+ CFLAGS="-g"
+ fi
+else
+ if test "$GCC" = yes; then
+ CFLAGS="-O2"
+ else
+ CFLAGS=
+ fi
+fi
+
# Check whether --with-gnu-ld or --without-gnu-ld was given.
if test "${with_gnu_ld+set}" = set; then
withval="$with_gnu_ld"
@@ -1402,7 +1424,7 @@ ac_prog=ld
if test "$GCC" = yes; then
# Check if gcc -print-prog-name=ld gives a path.
echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
-echo "configure:1406: checking for ld used by GCC" >&5
+echo "configure:1428: checking for ld used by GCC" >&5
case $host in
*-*-mingw*)
# gcc leaves a trailing carriage return which upsets mingw
@@ -1432,10 +1454,10 @@ echo "configure:1406: checking for ld used by GCC" >&5
esac
elif test "$with_gnu_ld" = yes; then
echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
-echo "configure:1436: checking for GNU ld" >&5
+echo "configure:1458: checking for GNU ld" >&5
else
echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
-echo "configure:1439: checking for non-GNU ld" >&5
+echo "configure:1461: checking for non-GNU ld" >&5
fi
if eval "test \"`echo '$''{'lt_cv_path_LD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1470,7 +1492,7 @@ else
fi
test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
-echo "configure:1474: checking if the linker ($LD) is GNU ld" >&5
+echo "configure:1496: checking if the linker ($LD) is GNU ld" >&5
if eval "test \"`echo '$''{'lt_cv_prog_gnu_ld'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1487,7 +1509,7 @@ with_gnu_ld=$lt_cv_prog_gnu_ld
echo $ac_n "checking for $LD option to reload object files""... $ac_c" 1>&6
-echo "configure:1491: checking for $LD option to reload object files" >&5
+echo "configure:1513: checking for $LD option to reload object files" >&5
if eval "test \"`echo '$''{'lt_cv_ld_reload_flag'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1499,7 +1521,7 @@ reload_flag=$lt_cv_ld_reload_flag
test -n "$reload_flag" && reload_flag=" $reload_flag"
echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
-echo "configure:1503: checking for BSD-compatible nm" >&5
+echo "configure:1525: checking for BSD-compatible nm" >&5
if eval "test \"`echo '$''{'lt_cv_path_NM'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1537,7 +1559,7 @@ NM="$lt_cv_path_NM"
echo "$ac_t""$NM" 1>&6
echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:1541: checking whether ln -s works" >&5
+echo "configure:1563: checking whether ln -s works" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1558,7 +1580,7 @@ else
fi
echo $ac_n "checking how to recognise dependant libraries""... $ac_c" 1>&6
-echo "configure:1562: checking how to recognise dependant libraries" >&5
+echo "configure:1584: checking how to recognise dependant libraries" >&5
if eval "test \"`echo '$''{'lt_cv_deplibs_check_method'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1668,7 +1690,7 @@ irix5* | irix6*)
# This must be Linux ELF.
linux-gnu*)
case $host_cpu in
- alpha* | hppa* | i*86 | powerpc* | sparc* | ia64* )
+ alpha* | mips* | hppa* | i*86 | powerpc* | sparc* | ia64* )
lt_cv_deplibs_check_method=pass_all ;;
*)
# glibc up to 2.1.1 does not perform some relocations on ARM
@@ -1731,13 +1753,13 @@ file_magic_cmd=$lt_cv_file_magic_cmd
deplibs_check_method=$lt_cv_deplibs_check_method
echo $ac_n "checking for object suffix""... $ac_c" 1>&6
-echo "configure:1735: checking for object suffix" >&5
+echo "configure:1757: checking for object suffix" >&5
if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
rm -f conftest*
echo 'int i = 1;' > conftest.$ac_ext
-if { (eval echo configure:1741: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1763: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
for ac_file in conftest.*; do
case $ac_file in
*.c) ;;
@@ -1757,7 +1779,7 @@ ac_objext=$ac_cv_objext
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:1761: checking for executable suffix" >&5
+echo "configure:1783: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1767,10 +1789,10 @@ else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:1771: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:1793: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
- *.$ac_ext | *.c | *.o | *.obj) ;;
+ *.c | *.o | *.obj) ;;
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
esac
done
@@ -1794,7 +1816,7 @@ case $deplibs_check_method in
file_magic*)
if test "$file_magic_cmd" = '$MAGIC_CMD'; then
echo $ac_n "checking for ${ac_tool_prefix}file""... $ac_c" 1>&6
-echo "configure:1798: checking for ${ac_tool_prefix}file" >&5
+echo "configure:1820: checking for ${ac_tool_prefix}file" >&5
if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1856,7 +1878,7 @@ fi
if test -z "$lt_cv_path_MAGIC_CMD"; then
if test -n "$ac_tool_prefix"; then
echo $ac_n "checking for file""... $ac_c" 1>&6
-echo "configure:1860: checking for file" >&5
+echo "configure:1882: checking for file" >&5
if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1927,7 +1949,7 @@ esac
# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1931: checking for $ac_word" >&5
+echo "configure:1953: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1959,7 +1981,7 @@ if test -n "$ac_tool_prefix"; then
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1963: checking for $ac_word" >&5
+echo "configure:1985: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1994,7 +2016,7 @@ fi
# Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
set dummy ${ac_tool_prefix}strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1998: checking for $ac_word" >&5
+echo "configure:2020: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2026,7 +2048,7 @@ if test -n "$ac_tool_prefix"; then
# Extract the first word of "strip", so it can be a program name with args.
set dummy strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2030: checking for $ac_word" >&5
+echo "configure:2052: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2093,8 +2115,21 @@ test x"$pic_mode" = xno && libtool_flags="$libtool_flags --prefer-non-pic"
case $host in
*-*-irix6*)
# Find out which ABI we are using.
- echo '#line 2097 "configure"' > conftest.$ac_ext
- if { (eval echo configure:2098: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ echo '#line 2119 "configure"' > conftest.$ac_ext
+ if { (eval echo configure:2120: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ if test "$lt_cv_prog_gnu_ld" = yes; then
+ case `/usr/bin/file conftest.$ac_objext` in
+ *32-bit*)
+ LD="${LD-ld} -melf32bsmip"
+ ;;
+ *N32*)
+ LD="${LD-ld} -melf32bmipn32"
+ ;;
+ *64-bit*)
+ LD="${LD-ld} -melf64bmip"
+ ;;
+ esac
+ else
case `/usr/bin/file conftest.$ac_objext` in
*32-bit*)
LD="${LD-ld} -32"
@@ -2106,6 +2141,7 @@ case $host in
LD="${LD-ld} -64"
;;
esac
+ fi
fi
rm -rf conftest*
;;
@@ -2113,7 +2149,7 @@ case $host in
ia64-*-hpux*)
# Find out which ABI we are using.
echo 'int i;' > conftest.$ac_ext
- if { (eval echo configure:2117: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ if { (eval echo configure:2153: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
case "`/usr/bin/file conftest.o`" in
*ELF-32*)
HPUX_IA64_MODE="32"
@@ -2131,7 +2167,7 @@ ia64-*-hpux*)
SAVE_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -belf"
echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
-echo "configure:2135: checking whether the C compiler needs -belf" >&5
+echo "configure:2171: checking whether the C compiler needs -belf" >&5
if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2144,14 +2180,14 @@ ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$a
cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext <<EOF
-#line 2148 "configure"
+#line 2184 "configure"
#include "confdefs.h"
int main() {
; return 0; }
EOF
-if { (eval echo configure:2155: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2191: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
lt_cv_cc_needs_belf=yes
else
@@ -2327,7 +2363,7 @@ if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
fi
fi
WARN_CFLAGS=""
-if test "x${build_warnings}" != x -a "x$GCC" = xyes ; then
+if test "x${build_warnings}" != x && test "x$GCC" = xyes ; then
WARN_CFLAGS="${build_warnings}"
fi
@@ -2341,7 +2377,7 @@ if test -z "$target" ; then
fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:2345: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:2381: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -2364,13 +2400,13 @@ fi
echo $ac_n "checking whether to install libbfd""... $ac_c" 1>&6
-echo "configure:2368: checking whether to install libbfd" >&5
+echo "configure:2404: checking whether to install libbfd" >&5
# Check whether --enable-install-libbfd or --disable-install-libbfd was given.
if test "${enable_install_libbfd+set}" = set; then
enableval="$enable_install_libbfd"
install_libbfd_p=$enableval
else
- if test "${host}" = "${target}" -o "$enable_shared" = "yes"; then
+ if test "${host}" = "${target}" || test "$enable_shared" = "yes"; then
install_libbfd_p=yes
else
install_libbfd_p=no
@@ -2401,7 +2437,7 @@ fi
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:2405: checking for executable suffix" >&5
+echo "configure:2441: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2411,10 +2447,10 @@ else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:2415: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:2451: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
- *.$ac_ext | *.c | *.o | *.obj) ;;
+ *.c | *.o | *.obj) ;;
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
esac
done
@@ -2441,7 +2477,7 @@ bfd_default_target_size=32
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2445: checking for $ac_word" >&5
+echo "configure:2481: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2471,7 +2507,7 @@ if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2475: checking for $ac_word" >&5
+echo "configure:2511: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2522,7 +2558,7 @@ fi
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2526: checking for $ac_word" >&5
+echo "configure:2562: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2554,7 +2590,7 @@ fi
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:2558: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:2594: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -2565,12 +2601,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 2569 "configure"
+#line 2605 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:2574: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2610: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -2596,12 +2632,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:2600: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:2636: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:2605: checking whether we are using GNU C" >&5
+echo "configure:2641: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2610,7 +2646,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2614: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2650: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -2629,7 +2665,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:2633: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:2669: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2661,9 +2697,9 @@ else
fi
-ALL_LINGUAS="fr tr ja es sv da"
+ALL_LINGUAS="fr tr ja es sv da zh_CN ro"
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:2667: checking how to run the C preprocessor" >&5
+echo "configure:2703: checking how to run the C preprocessor" >&5
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
@@ -2678,13 +2714,13 @@ else
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp.
cat > conftest.$ac_ext <<EOF
-#line 2682 "configure"
+#line 2718 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2688: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2724: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -2695,13 +2731,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF
-#line 2699 "configure"
+#line 2735 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2705: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2741: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -2712,13 +2748,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -nologo -E"
cat > conftest.$ac_ext <<EOF
-#line 2716 "configure"
+#line 2752 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2722: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2758: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -2745,7 +2781,7 @@ echo "$ac_t""$CPP" 1>&6
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2749: checking for $ac_word" >&5
+echo "configure:2785: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2773,12 +2809,12 @@ else
fi
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:2777: checking for ANSI C header files" >&5
+echo "configure:2813: checking for ANSI C header files" >&5
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2782 "configure"
+#line 2818 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
@@ -2786,7 +2822,7 @@ else
#include <float.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2790: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2826: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -2803,7 +2839,7 @@ rm -f conftest*
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 2807 "configure"
+#line 2843 "configure"
#include "confdefs.h"
#include <string.h>
EOF
@@ -2821,7 +2857,7 @@ fi
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 2825 "configure"
+#line 2861 "configure"
#include "confdefs.h"
#include <stdlib.h>
EOF
@@ -2842,7 +2878,7 @@ if test "$cross_compiling" = yes; then
:
else
cat > conftest.$ac_ext <<EOF
-#line 2846 "configure"
+#line 2882 "configure"
#include "confdefs.h"
#include <ctype.h>
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -2853,7 +2889,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
exit (0); }
EOF
-if { (eval echo configure:2857: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2893: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
else
@@ -2877,12 +2913,12 @@ EOF
fi
echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:2881: checking for working const" >&5
+echo "configure:2917: checking for working const" >&5
if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2886 "configure"
+#line 2922 "configure"
#include "confdefs.h"
int main() {
@@ -2931,7 +2967,7 @@ ccp = (char const *const *) p;
; return 0; }
EOF
-if { (eval echo configure:2935: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2971: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_const=yes
else
@@ -2952,21 +2988,21 @@ EOF
fi
echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:2956: checking for inline" >&5
+echo "configure:2992: checking for inline" >&5
if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
cat > conftest.$ac_ext <<EOF
-#line 2963 "configure"
+#line 2999 "configure"
#include "confdefs.h"
int main() {
} $ac_kw foo() {
; return 0; }
EOF
-if { (eval echo configure:2970: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3006: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_inline=$ac_kw; break
else
@@ -2992,12 +3028,12 @@ EOF
esac
echo $ac_n "checking for off_t""... $ac_c" 1>&6
-echo "configure:2996: checking for off_t" >&5
+echo "configure:3032: checking for off_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3001 "configure"
+#line 3037 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -3025,12 +3061,12 @@ EOF
fi
echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:3029: checking for size_t" >&5
+echo "configure:3065: checking for size_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3034 "configure"
+#line 3070 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -3060,19 +3096,19 @@ fi
# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
# for constant arguments. Useless!
echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:3064: checking for working alloca.h" >&5
+echo "configure:3100: checking for working alloca.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3069 "configure"
+#line 3105 "configure"
#include "confdefs.h"
#include <alloca.h>
int main() {
char *p = alloca(2 * sizeof(int));
; return 0; }
EOF
-if { (eval echo configure:3076: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3112: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_header_alloca_h=yes
else
@@ -3093,12 +3129,12 @@ EOF
fi
echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:3097: checking for alloca" >&5
+echo "configure:3133: checking for alloca" >&5
if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3102 "configure"
+#line 3138 "configure"
#include "confdefs.h"
#ifdef __GNUC__
@@ -3126,7 +3162,7 @@ int main() {
char *p = (char *) alloca(1);
; return 0; }
EOF
-if { (eval echo configure:3130: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3166: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_func_alloca_works=yes
else
@@ -3158,12 +3194,12 @@ EOF
echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:3162: checking whether alloca needs Cray hooks" >&5
+echo "configure:3198: checking whether alloca needs Cray hooks" >&5
if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3167 "configure"
+#line 3203 "configure"
#include "confdefs.h"
#if defined(CRAY) && ! defined(CRAY2)
webecray
@@ -3188,12 +3224,12 @@ echo "$ac_t""$ac_cv_os_cray" 1>&6
if test $ac_cv_os_cray = yes; then
for ac_func in _getb67 GETB67 getb67; do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3192: checking for $ac_func" >&5
+echo "configure:3228: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3197 "configure"
+#line 3233 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3216,7 +3252,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3220: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3256: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3243,7 +3279,7 @@ done
fi
echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:3247: checking stack direction for C alloca" >&5
+echo "configure:3283: checking stack direction for C alloca" >&5
if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3251,7 +3287,7 @@ else
ac_cv_c_stack_direction=0
else
cat > conftest.$ac_ext <<EOF
-#line 3255 "configure"
+#line 3291 "configure"
#include "confdefs.h"
find_stack_direction ()
{
@@ -3270,7 +3306,7 @@ main ()
exit (find_stack_direction() < 0);
}
EOF
-if { (eval echo configure:3274: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3310: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_stack_direction=1
else
@@ -3291,21 +3327,21 @@ EOF
fi
-for ac_hdr in unistd.h
+for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3299: checking for $ac_hdr" >&5
+echo "configure:3335: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3304 "configure"
+#line 3340 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3309: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3345: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -3334,12 +3370,12 @@ done
for ac_func in getpagesize
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3338: checking for $ac_func" >&5
+echo "configure:3374: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3343 "configure"
+#line 3379 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3362,7 +3398,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3366: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3402: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3387,7 +3423,7 @@ fi
done
echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:3391: checking for working mmap" >&5
+echo "configure:3427: checking for working mmap" >&5
if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3395,7 +3431,7 @@ else
ac_cv_func_mmap_fixed_mapped=no
else
cat > conftest.$ac_ext <<EOF
-#line 3399 "configure"
+#line 3435 "configure"
#include "confdefs.h"
/* Thanks to Mike Haertel and Jim Avera for this test.
@@ -3423,11 +3459,24 @@ else
#include <fcntl.h>
#include <sys/mman.h>
+#if HAVE_SYS_TYPES_H
+# include <sys/types.h>
+#endif
+
+#if HAVE_STDLIB_H
+# include <stdlib.h>
+#endif
+
+#if HAVE_SYS_STAT_H
+# include <sys/stat.h>
+#endif
+
+#if HAVE_UNISTD_H
+# include <unistd.h>
+#endif
+
/* This mess was copied from the GNU getpagesize.h. */
#ifndef HAVE_GETPAGESIZE
-# ifdef HAVE_UNISTD_H
-# include <unistd.h>
-# endif
/* Assume that all systems that can run configure have sys/param.h. */
# ifndef HAVE_SYS_PARAM_H
@@ -3535,7 +3584,7 @@ main()
}
EOF
-if { (eval echo configure:3539: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3588: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_func_mmap_fixed_mapped=yes
else
@@ -3563,17 +3612,17 @@ unistd.h values.h sys/param.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3567: checking for $ac_hdr" >&5
+echo "configure:3616: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3572 "configure"
+#line 3621 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3577: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3626: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -3603,12 +3652,12 @@ done
__argz_count __argz_stringify __argz_next
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3607: checking for $ac_func" >&5
+echo "configure:3656: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3612 "configure"
+#line 3661 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3631,7 +3680,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3635: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3684: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3660,12 +3709,12 @@ done
for ac_func in stpcpy
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3664: checking for $ac_func" >&5
+echo "configure:3713: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3669 "configure"
+#line 3718 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3688,7 +3737,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3692: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3741: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3722,19 +3771,19 @@ EOF
if test $ac_cv_header_locale_h = yes; then
echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
-echo "configure:3726: checking for LC_MESSAGES" >&5
+echo "configure:3775: checking for LC_MESSAGES" >&5
if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3731 "configure"
+#line 3780 "configure"
#include "confdefs.h"
#include <locale.h>
int main() {
return LC_MESSAGES
; return 0; }
EOF
-if { (eval echo configure:3738: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3787: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
am_cv_val_LC_MESSAGES=yes
else
@@ -3755,7 +3804,7 @@ EOF
fi
fi
echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
-echo "configure:3759: checking whether NLS is requested" >&5
+echo "configure:3808: checking whether NLS is requested" >&5
# Check whether --enable-nls or --disable-nls was given.
if test "${enable_nls+set}" = set; then
enableval="$enable_nls"
@@ -3775,7 +3824,7 @@ fi
EOF
echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
-echo "configure:3779: checking whether included gettext is requested" >&5
+echo "configure:3828: checking whether included gettext is requested" >&5
# Check whether --with-included-gettext or --without-included-gettext was given.
if test "${with_included_gettext+set}" = set; then
withval="$with_included_gettext"
@@ -3794,17 +3843,17 @@ fi
ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
-echo "configure:3798: checking for libintl.h" >&5
+echo "configure:3847: checking for libintl.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3803 "configure"
+#line 3852 "configure"
#include "confdefs.h"
#include <libintl.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3808: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3857: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -3821,19 +3870,19 @@ fi
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
-echo "configure:3825: checking for gettext in libc" >&5
+echo "configure:3874: checking for gettext in libc" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3830 "configure"
+#line 3879 "configure"
#include "confdefs.h"
#include <libintl.h>
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:3837: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3886: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libc=yes
else
@@ -3849,7 +3898,7 @@ echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
if test "$gt_cv_func_gettext_libc" != "yes"; then
echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
-echo "configure:3853: checking for bindtextdomain in -lintl" >&5
+echo "configure:3902: checking for bindtextdomain in -lintl" >&5
ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -3857,7 +3906,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lintl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 3861 "configure"
+#line 3910 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -3868,7 +3917,7 @@ int main() {
bindtextdomain()
; return 0; }
EOF
-if { (eval echo configure:3872: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3921: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -3884,19 +3933,19 @@ fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
-echo "configure:3888: checking for gettext in libintl" >&5
+echo "configure:3937: checking for gettext in libintl" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3893 "configure"
+#line 3942 "configure"
#include "confdefs.h"
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:3900: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3949: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libintl=yes
else
@@ -3924,7 +3973,7 @@ EOF
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3928: checking for $ac_word" >&5
+echo "configure:3977: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3958,12 +4007,12 @@ fi
for ac_func in dcgettext
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3962: checking for $ac_func" >&5
+echo "configure:4011: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3967 "configure"
+#line 4016 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3986,7 +4035,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3990: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4039: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -4013,7 +4062,7 @@ done
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4017: checking for $ac_word" >&5
+echo "configure:4066: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4049,7 +4098,7 @@ fi
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4053: checking for $ac_word" >&5
+echo "configure:4102: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4081,7 +4130,7 @@ else
fi
cat > conftest.$ac_ext <<EOF
-#line 4085 "configure"
+#line 4134 "configure"
#include "confdefs.h"
int main() {
@@ -4089,7 +4138,7 @@ extern int _nl_msg_cat_cntr;
return _nl_msg_cat_cntr
; return 0; }
EOF
-if { (eval echo configure:4093: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4142: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
CATOBJEXT=.gmo
DATADIRNAME=share
@@ -4121,7 +4170,7 @@ fi
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4125: checking for $ac_word" >&5
+echo "configure:4174: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4155,7 +4204,7 @@ fi
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4159: checking for $ac_word" >&5
+echo "configure:4208: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4191,7 +4240,7 @@ fi
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4195: checking for $ac_word" >&5
+echo "configure:4244: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4281,7 +4330,7 @@ fi
LINGUAS=
else
echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
-echo "configure:4285: checking for catalogs to be installed" >&5
+echo "configure:4334: checking for catalogs to be installed" >&5
NEW_LINGUAS=
for lang in ${LINGUAS=$ALL_LINGUAS}; do
case "$ALL_LINGUAS" in
@@ -4309,17 +4358,17 @@ echo "configure:4285: checking for catalogs to be installed" >&5
if test "$CATOBJEXT" = ".cat"; then
ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
-echo "configure:4313: checking for linux/version.h" >&5
+echo "configure:4362: checking for linux/version.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4318 "configure"
+#line 4367 "configure"
#include "confdefs.h"
#include <linux/version.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4323: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4372: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -4397,7 +4446,7 @@ fi
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:4401: checking for a BSD compatible install" >&5
+echo "configure:4450: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -4451,21 +4500,141 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
BFD_HOST_64BIT_LONG=0
+BFD_HOST_LONG_LONG=0
BFD_HOST_64_BIT_DEFINED=0
BFD_HOST_64_BIT=
BFD_HOST_U_64_BIT=
-if test "x${HOST_64BIT_TYPE}" = "xlong"; then
+
+echo $ac_n "checking for long long""... $ac_c" 1>&6
+echo "configure:4510: checking for long long" >&5
+if eval "test \"`echo '$''{'bfd_cv_has_long_long'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ cat > conftest.$ac_ext <<EOF
+#line 4515 "configure"
+#include "confdefs.h"
+
+int main() {
+unsigned long long ll = 18446744073709551615ULL;
+; return 0; }
+EOF
+if { (eval echo configure:4522: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ rm -rf conftest*
+ bfd_cv_has_long_long=yes
+else
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+ rm -rf conftest*
+ bfd_cv_has_long_long=no
+fi
+rm -f conftest*
+fi
+
+echo "$ac_t""$bfd_cv_has_long_long" 1>&6
+if test $bfd_cv_has_long_long = yes; then
+ BFD_HOST_LONG_LONG=1
+ echo $ac_n "checking size of long long""... $ac_c" 1>&6
+echo "configure:4538: checking size of long long" >&5
+if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ for ac_size in 4 8 1 2 16 12 ; do # List sizes in rough order of prevalence.
+ cat > conftest.$ac_ext <<EOF
+#line 4544 "configure"
+#include "confdefs.h"
+#include "confdefs.h"
+#include <sys/types.h>
+
+
+int main() {
+switch (0) case 0: case (sizeof (long long) == $ac_size):;
+; return 0; }
+EOF
+if { (eval echo configure:4554: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ rm -rf conftest*
+ ac_cv_sizeof_long_long=$ac_size
+else
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+fi
+rm -f conftest*
+ if test x$ac_cv_sizeof_long_long != x ; then break; fi
+done
+
+fi
+
+if test x$ac_cv_sizeof_long_long = x ; then
+ { echo "configure: error: cannot determine a size for long long" 1>&2; exit 1; }
+fi
+echo "$ac_t""$ac_cv_sizeof_long_long" 1>&6
+cat >> confdefs.h <<EOF
+#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long
+EOF
+
+
+fi
+
+echo $ac_n "checking size of long""... $ac_c" 1>&6
+echo "configure:4579: checking size of long" >&5
+if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ for ac_size in 4 8 1 2 16 12 ; do # List sizes in rough order of prevalence.
+ cat > conftest.$ac_ext <<EOF
+#line 4585 "configure"
+#include "confdefs.h"
+#include "confdefs.h"
+#include <sys/types.h>
+
+
+int main() {
+switch (0) case 0: case (sizeof (long) == $ac_size):;
+; return 0; }
+EOF
+if { (eval echo configure:4595: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ rm -rf conftest*
+ ac_cv_sizeof_long=$ac_size
+else
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+fi
+rm -f conftest*
+ if test x$ac_cv_sizeof_long != x ; then break; fi
+done
+
+fi
+
+if test x$ac_cv_sizeof_long = x ; then
+ { echo "configure: error: cannot determine a size for long" 1>&2; exit 1; }
+fi
+echo "$ac_t""$ac_cv_sizeof_long" 1>&6
+cat >> confdefs.h <<EOF
+#define SIZEOF_LONG $ac_cv_sizeof_long
+EOF
+
+
+if test "x${ac_cv_sizeof_long}" = "x8"; then
+ host64=true
BFD_HOST_64BIT_LONG=1
-elif test "x${HOST_64BIT_TYPE}" != "x"; then
+ test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long"
+ test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long"
+elif test "x${ac_cv_sizeof_long_long}" = "x8"; then
+ test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long long"
+ test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long long"
+fi
+
+if test -n "${HOST_64BIT_TYPE}" -a -n "${HOST_U_64BIT_TYPE}"; then
BFD_HOST_64_BIT_DEFINED=1
- BFD_HOST_64_BIT=${HOST_64BIT_TYPE}
- BFD_HOST_U_64_BIT=${HOST_U_64BIT_TYPE}
+ BFD_HOST_64_BIT="${HOST_64BIT_TYPE}"
+ BFD_HOST_U_64_BIT="${HOST_U_64BIT_TYPE}"
fi
+
+
# Put a plausible default for CC_FOR_BUILD in Makefile.
if test -z "$CC_FOR_BUILD"; then
if test "x$cross_compiling" = "xno"; then
@@ -4480,7 +4649,7 @@ if test "x$cross_compiling" = "xno"; then
EXEEXT_FOR_BUILD='$(EXEEXT)'
else
echo $ac_n "checking for build system executable suffix""... $ac_c" 1>&6
-echo "configure:4484: checking for build system executable suffix" >&5
+echo "configure:4653: checking for build system executable suffix" >&5
if eval "test \"`echo '$''{'bfd_cv_build_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4508,17 +4677,17 @@ for ac_hdr in stddef.h string.h strings.h stdlib.h time.h unistd.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:4512: checking for $ac_hdr" >&5
+echo "configure:4681: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4517 "configure"
+#line 4686 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4522: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4691: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -4548,17 +4717,17 @@ for ac_hdr in fcntl.h sys/file.h sys/time.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:4552: checking for $ac_hdr" >&5
+echo "configure:4721: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4557 "configure"
+#line 4726 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4562: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4731: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -4585,12 +4754,12 @@ fi
done
echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
-echo "configure:4589: checking whether time.h and sys/time.h may both be included" >&5
+echo "configure:4758: checking whether time.h and sys/time.h may both be included" >&5
if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4594 "configure"
+#line 4763 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/time.h>
@@ -4599,7 +4768,7 @@ int main() {
struct tm *tp;
; return 0; }
EOF
-if { (eval echo configure:4603: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4772: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_header_time=yes
else
@@ -4624,12 +4793,12 @@ for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
-echo "configure:4628: checking for $ac_hdr that defines DIR" >&5
+echo "configure:4797: checking for $ac_hdr that defines DIR" >&5
if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4633 "configure"
+#line 4802 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <$ac_hdr>
@@ -4637,7 +4806,7 @@ int main() {
DIR *dirp = 0;
; return 0; }
EOF
-if { (eval echo configure:4641: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4810: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
eval "ac_cv_header_dirent_$ac_safe=yes"
else
@@ -4662,7 +4831,7 @@ done
# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
if test $ac_header_dirent = dirent.h; then
echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
-echo "configure:4666: checking for opendir in -ldir" >&5
+echo "configure:4835: checking for opendir in -ldir" >&5
ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -4670,7 +4839,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-ldir $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4674 "configure"
+#line 4843 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -4681,7 +4850,7 @@ int main() {
opendir()
; return 0; }
EOF
-if { (eval echo configure:4685: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4854: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -4703,7 +4872,7 @@ fi
else
echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
-echo "configure:4707: checking for opendir in -lx" >&5
+echo "configure:4876: checking for opendir in -lx" >&5
ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -4711,7 +4880,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lx $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4715 "configure"
+#line 4884 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -4722,7 +4891,7 @@ int main() {
opendir()
; return 0; }
EOF
-if { (eval echo configure:4726: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4895: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -4747,12 +4916,12 @@ fi
for ac_func in fcntl getpagesize setitimer sysconf fdopen getuid getgid
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:4751: checking for $ac_func" >&5
+echo "configure:4920: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4756 "configure"
+#line 4925 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -4775,7 +4944,62 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:4779: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4948: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ rm -rf conftest*
+ eval "ac_cv_func_$ac_func=yes"
+else
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+ rm -rf conftest*
+ eval "ac_cv_func_$ac_func=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
+ echo "$ac_t""yes" 1>&6
+ ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
+ cat >> confdefs.h <<EOF
+#define $ac_tr_func 1
+EOF
+
+else
+ echo "$ac_t""no" 1>&6
+fi
+done
+
+for ac_func in strtoull
+do
+echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
+echo "configure:4975: checking for $ac_func" >&5
+if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ cat > conftest.$ac_ext <<EOF
+#line 4980 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+ which can conflict with char $ac_func(); below. */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error. */
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char $ac_func();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+ to always fail with ENOSYS. Some functions are actually named
+ something starting with __ and the normal name is an alias. */
+#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
+choke me
+#else
+$ac_func();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:5003: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -4810,12 +5034,12 @@ EOF
esac
echo $ac_n "checking whether strstr must be declared""... $ac_c" 1>&6
-echo "configure:4814: checking whether strstr must be declared" >&5
+echo "configure:5038: checking whether strstr must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_strstr'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4819 "configure"
+#line 5043 "configure"
#include "confdefs.h"
#include <stdio.h>
@@ -4836,7 +5060,7 @@ int main() {
char *(*pfn) = (char *(*)) strstr
; return 0; }
EOF
-if { (eval echo configure:4840: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5064: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_strstr=no
else
@@ -4857,12 +5081,12 @@ EOF
fi
echo $ac_n "checking whether malloc must be declared""... $ac_c" 1>&6
-echo "configure:4861: checking whether malloc must be declared" >&5
+echo "configure:5085: checking whether malloc must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_malloc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4866 "configure"
+#line 5090 "configure"
#include "confdefs.h"
#include <stdio.h>
@@ -4883,7 +5107,7 @@ int main() {
char *(*pfn) = (char *(*)) malloc
; return 0; }
EOF
-if { (eval echo configure:4887: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5111: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_malloc=no
else
@@ -4904,12 +5128,12 @@ EOF
fi
echo $ac_n "checking whether realloc must be declared""... $ac_c" 1>&6
-echo "configure:4908: checking whether realloc must be declared" >&5
+echo "configure:5132: checking whether realloc must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_realloc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4913 "configure"
+#line 5137 "configure"
#include "confdefs.h"
#include <stdio.h>
@@ -4930,7 +5154,7 @@ int main() {
char *(*pfn) = (char *(*)) realloc
; return 0; }
EOF
-if { (eval echo configure:4934: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5158: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_realloc=no
else
@@ -4951,12 +5175,12 @@ EOF
fi
echo $ac_n "checking whether free must be declared""... $ac_c" 1>&6
-echo "configure:4955: checking whether free must be declared" >&5
+echo "configure:5179: checking whether free must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_free'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4960 "configure"
+#line 5184 "configure"
#include "confdefs.h"
#include <stdio.h>
@@ -4977,7 +5201,7 @@ int main() {
char *(*pfn) = (char *(*)) free
; return 0; }
EOF
-if { (eval echo configure:4981: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5205: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_free=no
else
@@ -4998,12 +5222,12 @@ EOF
fi
echo $ac_n "checking whether getenv must be declared""... $ac_c" 1>&6
-echo "configure:5002: checking whether getenv must be declared" >&5
+echo "configure:5226: checking whether getenv must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_getenv'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5007 "configure"
+#line 5231 "configure"
#include "confdefs.h"
#include <stdio.h>
@@ -5024,7 +5248,7 @@ int main() {
char *(*pfn) = (char *(*)) getenv
; return 0; }
EOF
-if { (eval echo configure:5028: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5252: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_getenv=no
else
@@ -5051,7 +5275,7 @@ COREFLAG=
TRAD_HEADER=
if test "${target}" = "${host}"; then
case "${host}" in
- alpha*-*-freebsd*)
+ alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu)
COREFILE=''
;;
alpha*-*-linux-gnu*)
@@ -5062,7 +5286,8 @@ if test "${target}" = "${host}"; then
COREFILE=netbsd-core.lo
;;
alpha*-*-*) COREFILE=osf-core.lo ;;
- arm-*-freebsd*) COREFILE='' ;;
+ arm-*-freebsd* | arm-*-kfreebsd*-gnu)
+ COREFILE='' ;;
arm-*-netbsd*) COREFILE=netbsd-core.lo ;;
arm-*-riscix) COREFILE=trad-core.lo ;;
hppa*-*-hpux*) COREFILE=hpux-core.lo ;;
@@ -5075,62 +5300,54 @@ if test "${target}" = "${host}"; then
TRAD_HEADER='"hosts/i370linux.h"'
;;
- i[3456]86-sequent-bsd*)
+ i[3-7]86-sequent-bsd*)
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/symmetry.h"'
;;
- i[3456]86-sequent-sysv4*) ;;
- i[3456]86-sequent-sysv*)
+ i[3-7]86-sequent-sysv4*) ;;
+ i[3-7]86-sequent-sysv*)
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/symmetry.h"'
;;
- i[3456]86-*-bsdi)
+ i[3-7]86-*-bsdi)
COREFILE=
;;
- i[3456]86-*-bsd* | i[34567]86-*-freebsd[123] | i[34567]86-*-freebsd[123]\.* | i[34567]86-*-freebsd4\.[01234]* | i[34567]86-*-freebsd*aout*)
+ i[3-7]86-*-bsd* | i[3-7]86-*-freebsd[123] | i[3-7]86-*-freebsd[123]\.* | i[3-7]86-*-freebsd4\.[01234]* | i[3-7]86-*-freebsd*aout*)
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/i386bsd.h"'
;;
- i[3456]86-*-freebsd*)
+ i[3-7]86-*-freebsd* | i[3-7]86-*-kfreebsd*-gnu)
COREFILE=''
TRAD_HEADER='"hosts/i386bsd.h"'
;;
- i[3456]86-*-netbsd* | i[3456]86-*-openbsd*)
+ i[3-7]86-*-netbsd* | i[3-7]86-*-knetbsd*-gnu | i[3-7]86-*-openbsd*)
COREFILE=netbsd-core.lo
;;
- i[3456]86-esix-sysv3*)
+ i[3-7]86-esix-sysv3*)
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/esix.h"'
;;
- i[3456]86-*-sco3.2v5*)
+ i[3-7]86-*-sco3.2v5*)
COREFILE=sco5-core.lo
;;
- i[3456]86-*-sco* | i[3456]86-*-isc*)
+ i[3-7]86-*-sco* | i[3-7]86-*-isc*)
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/i386sco.h"'
;;
- i[3456]86-*-mach3*)
+ i[3-7]86-*-mach3*)
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/i386mach3.h"'
;;
- i[3456]86-*-linux-gnu*)
+ i[3-7]86-*-linux-gnu*)
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/i386linux.h"'
;;
- i[3456]86-*-isc*) COREFILE=trad-core.lo ;;
- i[3456]86-*-aix*) COREFILE=aix386-core.lo ;;
+ i[3-7]86-*-isc*) COREFILE=trad-core.lo ;;
+ i[3-7]86-*-aix*) COREFILE=aix386-core.lo ;;
i860-*-mach3* | i860-*-osf1*)
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/i860mach3.h"'
;;
- mips-dec-bsd*)
- COREFILE=trad-core.lo
- TRAD_HEADER='"hosts/mipsbsd.h"'
- ;;
- mips-dec-mach3*)
- COREFILE=trad-core.lo
- TRAD_HEADER='"hosts/mipsmach3.h"'
- ;;
mips-*-netbsd* | mips*-*-openbsd*)
COREFILE=netbsd-core.lo
;;
@@ -5141,10 +5358,6 @@ if test "${target}" = "${host}"; then
mips-sgi-irix4*) COREFILE=irix-core.lo ;;
mips-sgi-irix5*) COREFILE=irix-core.lo ;;
mips-sgi-irix6*) COREFILE=irix-core.lo ;;
- mips-*-mach3*)
- COREFILE=trad-core.lo
- TRAD_HEADER='"hosts/mipsmach3.h"'
- ;;
mips-*-sysv4*) ;;
mips-*-sysv* | mips-*-riscos*)
COREFILE=trad-core.lo
@@ -5211,16 +5424,16 @@ if test "${target}" = "${host}"; then
# Not all versions of AIX with -DAIX_CORE_DUMPX_CORE
# have c_impl as a member of struct core_dumpx
echo $ac_n "checking for c_impl in struct core_dumpx""... $ac_c" 1>&6
-echo "configure:5215: checking for c_impl in struct core_dumpx" >&5
+echo "configure:5428: checking for c_impl in struct core_dumpx" >&5
cat > conftest.$ac_ext <<EOF
-#line 5217 "configure"
+#line 5430 "configure"
#include "confdefs.h"
#include <core.h>
int main() {
struct core_dumpx c; c.c_impl = 0;
; return 0; }
EOF
-if { (eval echo configure:5224: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5437: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
cat >> confdefs.h <<\EOF
#define HAVE_ST_C_IMPL 1
@@ -5240,7 +5453,8 @@ rm -f conftest*
powerpc-*-aix4*) COREFILE=rs6000-core.lo ;;
powerpc-*-aix*) COREFILE=rs6000-core.lo ;;
powerpc-*-beos*) ;;
- powerpc-*-freebsd*) COREFILE='' ;;
+ powerpc-*-freebsd* | powerpc-*-kfreebsd*-gnu)
+ COREFILE='' ;;
powerpc-*-netbsd*) COREFILE=netbsd-core.lo ;;
powerpc-*-*bsd*) COREFILE=netbsd-core.lo ;;
s390*-*-*) COREFILE=trad-core.lo ;;
@@ -5252,7 +5466,9 @@ rm -f conftest*
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/tahoe.h"'
;;
- vax-*-netbsd*) COREFILE=netbsd-core.lo ;;
+ vax-*-netbsd* | vax-*-openbsd*)
+ COREFILE=netbsd-core.lo
+ ;;
vax-*-ultrix2*)
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/vaxult2.h"'
@@ -5261,11 +5477,17 @@ rm -f conftest*
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/vaxult2.h"'
;;
+ vax-*-linux-gnu*)
+ COREFILE=trad-core.lo
+ TRAD_HEADER='"hosts/vaxlinux.h"'
+ ;;
vax-*-*)
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/vaxbsd.h"'
;;
- x86_64-*-netbsd*) COREFILE=netbsd-core.lo ;;
+ x86_64-*-netbsd* | x86_64-*-openbsd*)
+ COREFILE=netbsd-core.lo
+ ;;
esac
case "$COREFILE" in
@@ -5288,17 +5510,17 @@ rm -f conftest*
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:5292: checking for $ac_hdr" >&5
+echo "configure:5514: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5297 "configure"
+#line 5519 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:5302: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:5524: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -5326,12 +5548,12 @@ done
if test "$ac_cv_header_sys_procfs_h" = yes; then
echo $ac_n "checking for prstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5330: checking for prstatus_t in sys/procfs.h" >&5
+echo "configure:5552: checking for prstatus_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prstatus_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5335 "configure"
+#line 5557 "configure"
#include "confdefs.h"
#define _SYSCALL32
@@ -5340,7 +5562,7 @@ int main() {
prstatus_t avar
; return 0; }
EOF
-if { (eval echo configure:5344: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5566: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_prstatus_t=yes
else
@@ -5362,12 +5584,12 @@ EOF
echo "$ac_t""$bfd_cv_have_sys_procfs_type_prstatus_t" 1>&6
echo $ac_n "checking for prstatus32_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5366: checking for prstatus32_t in sys/procfs.h" >&5
+echo "configure:5588: checking for prstatus32_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prstatus32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5371 "configure"
+#line 5593 "configure"
#include "confdefs.h"
#define _SYSCALL32
@@ -5376,7 +5598,7 @@ int main() {
prstatus32_t avar
; return 0; }
EOF
-if { (eval echo configure:5380: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5602: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_prstatus32_t=yes
else
@@ -5398,12 +5620,12 @@ EOF
echo "$ac_t""$bfd_cv_have_sys_procfs_type_prstatus32_t" 1>&6
echo $ac_n "checking for prstatus_t.pr_who in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5402: checking for prstatus_t.pr_who in sys/procfs.h" >&5
+echo "configure:5624: checking for prstatus_t.pr_who in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5407 "configure"
+#line 5629 "configure"
#include "confdefs.h"
#define _SYSCALL32
@@ -5412,7 +5634,7 @@ int main() {
prstatus_t avar; void* aref = (void*) &avar.pr_who
; return 0; }
EOF
-if { (eval echo configure:5416: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5638: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who=yes
else
@@ -5434,12 +5656,12 @@ EOF
echo "$ac_t""$bfd_cv_have_sys_procfs_type_member_prstatus_t_pr_who" 1>&6
echo $ac_n "checking for prstatus32_t.pr_who in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5438: checking for prstatus32_t.pr_who in sys/procfs.h" >&5
+echo "configure:5660: checking for prstatus32_t.pr_who in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5443 "configure"
+#line 5665 "configure"
#include "confdefs.h"
#define _SYSCALL32
@@ -5448,7 +5670,7 @@ int main() {
prstatus32_t avar; void* aref = (void*) &avar.pr_who
; return 0; }
EOF
-if { (eval echo configure:5452: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5674: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who=yes
else
@@ -5470,12 +5692,12 @@ EOF
echo "$ac_t""$bfd_cv_have_sys_procfs_type_member_prstatus32_t_pr_who" 1>&6
echo $ac_n "checking for pstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5474: checking for pstatus_t in sys/procfs.h" >&5
+echo "configure:5696: checking for pstatus_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pstatus_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5479 "configure"
+#line 5701 "configure"
#include "confdefs.h"
#define _SYSCALL32
@@ -5484,7 +5706,7 @@ int main() {
pstatus_t avar
; return 0; }
EOF
-if { (eval echo configure:5488: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5710: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_pstatus_t=yes
else
@@ -5506,12 +5728,12 @@ EOF
echo "$ac_t""$bfd_cv_have_sys_procfs_type_pstatus_t" 1>&6
echo $ac_n "checking for pxstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5510: checking for pxstatus_t in sys/procfs.h" >&5
+echo "configure:5732: checking for pxstatus_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pxstatus_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5515 "configure"
+#line 5737 "configure"
#include "confdefs.h"
#define _SYSCALL32
@@ -5520,7 +5742,7 @@ int main() {
pxstatus_t avar
; return 0; }
EOF
-if { (eval echo configure:5524: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5746: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_pxstatus_t=yes
else
@@ -5542,12 +5764,12 @@ EOF
echo "$ac_t""$bfd_cv_have_sys_procfs_type_pxstatus_t" 1>&6
echo $ac_n "checking for pstatus32_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5546: checking for pstatus32_t in sys/procfs.h" >&5
+echo "configure:5768: checking for pstatus32_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_pstatus32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5551 "configure"
+#line 5773 "configure"
#include "confdefs.h"
#define _SYSCALL32
@@ -5556,7 +5778,7 @@ int main() {
pstatus32_t avar
; return 0; }
EOF
-if { (eval echo configure:5560: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5782: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_pstatus32_t=yes
else
@@ -5578,12 +5800,12 @@ EOF
echo "$ac_t""$bfd_cv_have_sys_procfs_type_pstatus32_t" 1>&6
echo $ac_n "checking for prpsinfo_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5582: checking for prpsinfo_t in sys/procfs.h" >&5
+echo "configure:5804: checking for prpsinfo_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prpsinfo_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5587 "configure"
+#line 5809 "configure"
#include "confdefs.h"
#define _SYSCALL32
@@ -5592,7 +5814,7 @@ int main() {
prpsinfo_t avar
; return 0; }
EOF
-if { (eval echo configure:5596: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5818: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_prpsinfo_t=yes
else
@@ -5614,12 +5836,12 @@ EOF
echo "$ac_t""$bfd_cv_have_sys_procfs_type_prpsinfo_t" 1>&6
echo $ac_n "checking for prpsinfo32_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5618: checking for prpsinfo32_t in sys/procfs.h" >&5
+echo "configure:5840: checking for prpsinfo32_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_prpsinfo32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5623 "configure"
+#line 5845 "configure"
#include "confdefs.h"
#define _SYSCALL32
@@ -5628,7 +5850,7 @@ int main() {
prpsinfo32_t avar
; return 0; }
EOF
-if { (eval echo configure:5632: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5854: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_prpsinfo32_t=yes
else
@@ -5650,12 +5872,12 @@ EOF
echo "$ac_t""$bfd_cv_have_sys_procfs_type_prpsinfo32_t" 1>&6
echo $ac_n "checking for psinfo_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5654: checking for psinfo_t in sys/procfs.h" >&5
+echo "configure:5876: checking for psinfo_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_psinfo_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5659 "configure"
+#line 5881 "configure"
#include "confdefs.h"
#define _SYSCALL32
@@ -5664,7 +5886,7 @@ int main() {
psinfo_t avar
; return 0; }
EOF
-if { (eval echo configure:5668: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5890: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_psinfo_t=yes
else
@@ -5686,12 +5908,12 @@ EOF
echo "$ac_t""$bfd_cv_have_sys_procfs_type_psinfo_t" 1>&6
echo $ac_n "checking for psinfo32_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5690: checking for psinfo32_t in sys/procfs.h" >&5
+echo "configure:5912: checking for psinfo32_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_psinfo32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5695 "configure"
+#line 5917 "configure"
#include "confdefs.h"
#define _SYSCALL32
@@ -5700,7 +5922,7 @@ int main() {
psinfo32_t avar
; return 0; }
EOF
-if { (eval echo configure:5704: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5926: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_psinfo32_t=yes
else
@@ -5722,12 +5944,12 @@ EOF
echo "$ac_t""$bfd_cv_have_sys_procfs_type_psinfo32_t" 1>&6
echo $ac_n "checking for lwpstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5726: checking for lwpstatus_t in sys/procfs.h" >&5
+echo "configure:5948: checking for lwpstatus_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_lwpstatus_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5731 "configure"
+#line 5953 "configure"
#include "confdefs.h"
#define _SYSCALL32
@@ -5736,7 +5958,7 @@ int main() {
lwpstatus_t avar
; return 0; }
EOF
-if { (eval echo configure:5740: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5962: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_lwpstatus_t=yes
else
@@ -5758,12 +5980,12 @@ EOF
echo "$ac_t""$bfd_cv_have_sys_procfs_type_lwpstatus_t" 1>&6
echo $ac_n "checking for lwpxstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5762: checking for lwpxstatus_t in sys/procfs.h" >&5
+echo "configure:5984: checking for lwpxstatus_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_lwpxstatus_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5767 "configure"
+#line 5989 "configure"
#include "confdefs.h"
#define _SYSCALL32
@@ -5772,7 +5994,7 @@ int main() {
lwpxstatus_t avar
; return 0; }
EOF
-if { (eval echo configure:5776: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5998: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_lwpxstatus_t=yes
else
@@ -5794,12 +6016,12 @@ EOF
echo "$ac_t""$bfd_cv_have_sys_procfs_type_lwpxstatus_t" 1>&6
echo $ac_n "checking for lwpstatus_t.pr_context in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5798: checking for lwpstatus_t.pr_context in sys/procfs.h" >&5
+echo "configure:6020: checking for lwpstatus_t.pr_context in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5803 "configure"
+#line 6025 "configure"
#include "confdefs.h"
#define _SYSCALL32
@@ -5808,7 +6030,7 @@ int main() {
lwpstatus_t avar; void* aref = (void*) &avar.pr_context
; return 0; }
EOF
-if { (eval echo configure:5812: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:6034: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context=yes
else
@@ -5830,12 +6052,12 @@ EOF
echo "$ac_t""$bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_context" 1>&6
echo $ac_n "checking for lwpstatus_t.pr_reg in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5834: checking for lwpstatus_t.pr_reg in sys/procfs.h" >&5
+echo "configure:6056: checking for lwpstatus_t.pr_reg in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5839 "configure"
+#line 6061 "configure"
#include "confdefs.h"
#define _SYSCALL32
@@ -5844,7 +6066,7 @@ int main() {
lwpstatus_t avar; void* aref = (void*) &avar.pr_reg
; return 0; }
EOF
-if { (eval echo configure:5848: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:6070: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg=yes
else
@@ -5866,12 +6088,12 @@ EOF
echo "$ac_t""$bfd_cv_have_sys_procfs_type_member_lwpstatus_t_pr_reg" 1>&6
echo $ac_n "checking for win32_pstatus_t in sys/procfs.h""... $ac_c" 1>&6
-echo "configure:5870: checking for win32_pstatus_t in sys/procfs.h" >&5
+echo "configure:6092: checking for win32_pstatus_t in sys/procfs.h" >&5
if eval "test \"`echo '$''{'bfd_cv_have_sys_procfs_type_win32_pstatus_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5875 "configure"
+#line 6097 "configure"
#include "confdefs.h"
#define _SYSCALL32
@@ -5880,7 +6102,7 @@ int main() {
win32_pstatus_t avar
; return 0; }
EOF
-if { (eval echo configure:5884: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:6106: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_have_sys_procfs_type_win32_pstatus_t=yes
else
@@ -5933,7 +6155,7 @@ case "${host}" in
fi
;;
*)
- x=`sed -n -e 's/^[ ]*PICFLAG[ ]*=[ ]*//p' < ../libiberty/Makefile | tail -1`
+ x=`sed -n -e 's/^[ ]*PICFLAG[ ]*=[ ]*//p' < ../libiberty/Makefile | sed -n '$p'`
if test -n "$x"; then
WIN32LIBADD="-L../libiberty/pic -liberty"
fi
@@ -5963,12 +6185,14 @@ fi
all_targets=false
defvec=
selvecs=
+assocvecs=
selarchs=
TDEFINES=
for targ in $target $canon_targets
do
if test "x$targ" = "xall"; then
all_targets=true
+ assocvecs="$assocvecs $targ_defvec $targ_selvecs"
else
. $srcdir/config.bfd
if test "x$targ" = "x$target"; then
@@ -5999,6 +6223,17 @@ done
selvecs="$f"
+# uniq the associated vectors in all the configured targets.
+f=""
+for i in $assocvecs ; do
+ case " $f " in
+ *" $i "*) ;;
+ *) f="$f $i" ;;
+ esac
+done
+assocvecs="$f"
+
+
# uniq the architectures in all the configured targets.
f=""
for i in $selarchs ; do
@@ -6027,8 +6262,6 @@ do
aout0_big_vec) tb="$tb aout0.lo aout32.lo" ;;
aout_arm_big_vec) tb="$tb aout-arm.lo aout32.lo" ;;
aout_arm_little_vec) tb="$tb aout-arm.lo aout32.lo" ;;
- aout_mips_big_vec) tb="$tb mipsbsd.lo aout32.lo" ;;
- aout_mips_little_vec) tb="$tb mipsbsd.lo aout32.lo" ;;
apollocoff_vec) tb="$tb coff-apollo.lo" ;;
arm_epoc_pe_big_vec) tb="$tb epoc-pe-arm.lo peigen.lo cofflink.lo " ;;
arm_epoc_pe_little_vec) tb="$tb epoc-pe-arm.lo peigen.lo cofflink.lo " ;;
@@ -6045,6 +6278,7 @@ do
b_out_vec_little_host) tb="$tb bout.lo aout32.lo" ;;
bfd_efi_app_ia32_vec) tb="$tb efi-app-ia32.lo peigen.lo cofflink.lo" ;;
bfd_efi_app_ia64_vec) tb="$tb efi-app-ia64.lo pepigen.lo cofflink.lo"; target_size=64 ;;
+ bfd_elf32_am33lin_vec) tb="$tb elf32-am33lin.lo elf32.lo $elf" ;;
bfd_elf32_avr_vec) tb="$tb elf32-avr.lo elf32.lo $elf" ;;
bfd_elf32_big_generic_vec) tb="$tb elf32-gen.lo elf32.lo $elf" ;;
bfd_elf32_bigarc_vec) tb="$tb elf32-arc.lo elf32.lo $elf" ;;
@@ -6057,31 +6291,42 @@ do
bfd_elf32_dlx_big_vec) tb="$tb elf32-dlx.lo elf32.lo $elf" ;;
bfd_elf32_fr30_vec) tb="$tb elf32-fr30.lo elf32.lo $elf" ;;
bfd_elf32_frv_vec) tb="$tb elf32-frv.lo elf32.lo $elf" ;;
+ bfd_elf32_frvfdpic_vec) tb="$tb elf32-frv.lo elf32.lo $elf" ;;
bfd_elf32_h8300_vec) tb="$tb elf32-h8300.lo elf32.lo $elf" ;;
bfd_elf32_hppa_linux_vec) tb="$tb elf32-hppa.lo elf32.lo $elf" ;;
bfd_elf32_hppa_vec) tb="$tb elf32-hppa.lo elf32.lo $elf" ;;
bfd_elf32_i370_vec) tb="$tb elf32-i370.lo elf32.lo $elf" ;;
- bfd_elf32_i386_freebsd_vec) tb="$tb elf32-i386-fbsd.lo elf32.lo $elf" ;;
+ bfd_elf32_i386_freebsd_vec) tb="$tb elf32-i386.lo elf32.lo $elf" ;;
bfd_elf32_i386_vec) tb="$tb elf32-i386.lo elf32.lo $elf" ;;
bfd_elf32_i860_little_vec) tb="$tb elf32-i860.lo elf32.lo $elf" ;;
bfd_elf32_i860_vec) tb="$tb elf32-i860.lo elf32.lo $elf" ;;
bfd_elf32_i960_vec) tb="$tb elf32-i960.lo elf32.lo $elf" ;;
bfd_elf32_ia64_big_vec) tb="$tb elf32-ia64.lo elf32.lo $elf" ;;
bfd_elf32_ia64_hpux_big_vec) tb="$tb elf32-ia64.lo elf32.lo $elf";;
+ bfd_elf32_ip2k_vec) tb="$tb elf32-ip2k.lo elf32.lo $elf" ;;
+ bfd_elf32_iq2000_vec) tb="$tb elf32-iq2000.lo elf32.lo $elf" ;;
bfd_elf32_little_generic_vec) tb="$tb elf32-gen.lo elf32.lo $elf" ;;
bfd_elf32_littlearc_vec) tb="$tb elf32-arc.lo elf32.lo $elf" ;;
bfd_elf32_littlearm_oabi_vec) tb="$tb elfarm-oabi.lo elf32.lo $elf" ;;
bfd_elf32_littlearm_vec) tb="$tb elfarm-nabi.lo elf32.lo $elf" ;;
bfd_elf32_littlemips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo" ;;
bfd_elf32_m32r_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;;
- bfd_elf32_m68hc11_vec) tb="$tb elf32-m68hc11.lo elf32.lo $elf" ;;
- bfd_elf32_m68hc12_vec) tb="$tb elf32-m68hc12.lo elf32.lo $elf" ;;
+ bfd_elf32_m32rle_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;;
+ bfd_elf32_m32rlin_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;;
+ bfd_elf32_m32rlelin_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;;
+ bfd_elf32_m68hc11_vec) tb="$tb elf32-m68hc11.lo elf32-m68hc1x.lo elf32.lo $elf" ;;
+ bfd_elf32_m68hc12_vec) tb="$tb elf32-m68hc12.lo elf32-m68hc1x.lo elf32.lo $elf" ;;
bfd_elf32_m68k_vec) tb="$tb elf32-m68k.lo elf32.lo $elf" ;;
bfd_elf32_m88k_vec) tb="$tb elf32-m88k.lo elf32.lo $elf" ;;
bfd_elf32_mcore_big_vec) tb="$tb elf32-mcore.lo elf32.lo $elf" ;;
bfd_elf32_mcore_little_vec) tb="$tb elf32-mcore.lo elf32.lo $elf" ;;
bfd_elf32_mn10200_vec) tb="$tb elf-m10200.lo elf32.lo $elf" ;;
bfd_elf32_mn10300_vec) tb="$tb elf-m10300.lo elf32.lo $elf" ;;
+ bfd_elf32_msp430_vec) tb="$tb elf32-msp430.lo elf32.lo $elf" ;;
+ bfd_elf32_nbigmips_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
+ bfd_elf32_nlittlemips_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
+ bfd_elf32_ntradbigmips_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
+ bfd_elf32_ntradlittlemips_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
bfd_elf32_openrisc_vec) tb="$tb elf32-openrisc.lo elf32.lo $elf" ;;
bfd_elf32_or32_big_vec) tb="$tb elf32-or32.lo elf32.lo $elf" ;;
bfd_elf32_pj_vec) tb="$tb elf32-pj.lo elf32.lo $elf";;
@@ -6094,14 +6339,16 @@ do
# which needs it but does not list it. Should be fixed in right place.
bfd_elf32_sh64_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" target_size=64 ;;
bfd_elf32_sh64l_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" target_size=64 ;;
- bfd_elf32_sh64lnbsd_vec) tb="$tb elf32-sh64-nbsd.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" ;;
- bfd_elf32_sh64nbsd_vec) tb="$tb elf32-sh64-nbsd.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" ;;
+ bfd_elf32_sh64lin_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" target_size=64 ;;
+ bfd_elf32_sh64blin_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" target_size=64 ;;
+ bfd_elf32_sh64lnbsd_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" ;;
+ bfd_elf32_sh64nbsd_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" ;;
bfd_elf32_sh_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo" ;;
- bfd_elf32_shblin_vec) tb="$tb elf32-sh-lin.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
+ bfd_elf32_shblin_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
bfd_elf32_shl_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo" ;;
- bfd_elf32_shlin_vec) tb="$tb elf32-sh-lin.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
- bfd_elf32_shlnbsd_vec) tb="$tb elf32-sh-nbsd.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
- bfd_elf32_shnbsd_vec) tb="$tb elf32-sh-nbsd.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
+ bfd_elf32_shlin_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
+ bfd_elf32_shlnbsd_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
+ bfd_elf32_shnbsd_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
bfd_elf32_sparc_vec) tb="$tb elf32-sparc.lo elf32.lo $elf" ;;
bfd_elf32_tradbigmips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo" ;;
bfd_elf32_tradlittlemips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo" ;;
@@ -6109,14 +6356,14 @@ do
bfd_elf32_v850_vec) tb="$tb elf32-v850.lo elf32.lo $elf" ;;
bfd_elf32_vax_vec) tb="$tb elf32-vax.lo elf32.lo $elf" ;;
bfd_elf32_xstormy16_vec) tb="$tb elf32-xstormy16.lo elf32.lo $elf" ;;
- bfd_elf64_alpha_freebsd_vec) tb="$tb elf64-alpha-fbsd.lo elf64.lo $elf"; target_size=64 ;;
+ bfd_elf32_xtensa_le_vec) tb="$tb xtensa-isa.lo xtensa-modules.lo elf32-xtensa.lo elf32.lo $elf" ;;
+ bfd_elf32_xtensa_be_vec) tb="$tb xtensa-isa.lo xtensa-modules.lo elf32-xtensa.lo elf32.lo $elf" ;;
+ bfd_elf64_alpha_freebsd_vec) tb="$tb elf64-alpha.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_alpha_vec) tb="$tb elf64-alpha.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_big_generic_vec) tb="$tb elf64-gen.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_bigmips_vec) tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
bfd_elf64_hppa_linux_vec) tb="$tb elf64-hppa.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_hppa_vec) tb="$tb elf64-hppa.lo elf64.lo $elf"; target_size=64 ;;
- bfd_elf64_ia64_aix_big_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;;
- bfd_elf64_ia64_aix_little_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_ia64_big_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_ia64_hpux_big_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_ia64_little_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;;
@@ -6128,8 +6375,10 @@ do
bfd_elf64_s390_vec) tb="$tb elf64-s390.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_sh64_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;;
bfd_elf64_sh64l_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;;
- bfd_elf64_sh64lnbsd_vec) tb="$tb elf64-sh64-nbsd.lo elf64.lo $elf" target_size=64 ;;
- bfd_elf64_sh64nbsd_vec) tb="$tb elf64-sh64-nbsd.lo elf64.lo $elf" target_size=64 ;;
+ bfd_elf64_sh64lin_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;;
+ bfd_elf64_sh64blin_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;;
+ bfd_elf64_sh64lnbsd_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;;
+ bfd_elf64_sh64nbsd_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;;
bfd_elf64_sparc_vec) tb="$tb elf64-sparc.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_tradbigmips_vec) tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
bfd_elf64_tradlittlemips_vec) tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
@@ -6181,6 +6430,9 @@ do
m68ksysvcoff_vec) tb="$tb coff-svm68k.lo cofflink.lo" ;;
m88kbcs_vec) tb="$tb coff-m88k.lo" ;;
m88kmach3_vec) tb="$tb m88kmach3.lo aout32.lo" ;;
+ mach_o_be_vec) tb="$tb mach-o.lo" ;;
+ mach_o_le_vec) tb="$tb mach-o.lo" ;;
+ mach_o_fat_vec) tb="$tb mach-o.lo" ;;
mcore_pe_big_vec) tb="$tb pe-mcore.lo peigen.lo cofflink.lo" ;;
mcore_pe_little_vec) tb="$tb pe-mcore.lo peigen.lo cofflink.lo" ;;
mcore_pei_big_vec) tb="$tb pei-mcore.lo peigen.lo cofflink.lo" ;;
@@ -6195,6 +6447,8 @@ do
or32coff_big_vec) tb="$tb coff-or32.lo cofflink.lo" ;;
pc532machaout_vec) tb="$tb pc532-mach.lo aout-ns32k.lo" ;;
pc532netbsd_vec) tb="$tb ns32knetbsd.lo aout-ns32k.lo" ;;
+ pef_vec) tb="$tb pef.lo" ;;
+ pef_xlib_vec) tb="$tb pef.lo" ;;
pdp11_aout_vec) tb="$tb pdp11.lo" ;;
pmac_xcoff_vec) tb="$tb coff-rs6000.lo xcofflink.lo" ;;
ppcboot_vec) tb="$tb ppcboot.lo" ;;
@@ -6215,8 +6469,15 @@ do
sparclynx_coff_vec) tb="$tb cf-sparclynx.lo lynx-core.lo" ;;
sparcnetbsd_vec) tb="$tb sparcnetbsd.lo aout32.lo" ;;
sunos_big_vec) tb="$tb sunos.lo aout32.lo" ;;
+ sym_vec) tb="$tb xsym.lo" ;;
tic30_aout_vec) tb="$tb aout-tic30.lo" ;;
tic30_coff_vec) tb="$tb coff-tic30.lo" ;;
+ tic4x_coff0_vec) tb="$tb coff-tic4x.lo" ;;
+ tic4x_coff0_beh_vec) tb="$tb coff-tic4x.lo" ;;
+ tic4x_coff1_vec) tb="$tb coff-tic4x.lo" ;;
+ tic4x_coff1_beh_vec) tb="$tb coff-tic4x.lo" ;;
+ tic4x_coff2_vec) tb="$tb coff-tic4x.lo" ;;
+ tic4x_coff2_beh_vec) tb="$tb coff-tic4x.lo" ;;
tic54x_coff0_beh_vec) tb="$tb coff-tic54x.lo" ;;
tic54x_coff0_vec) tb="$tb coff-tic54x.lo" ;;
tic54x_coff1_beh_vec) tb="$tb coff-tic54x.lo" ;;
@@ -6286,9 +6547,12 @@ if test x${all_targets} = xtrue ; then
selvecs=
havevecs=
selarchs=
+ test -n "$assocvecs" &&
+ assocvecs=`echo $assocvecs | sed -e 's/^/\&/' -e 's/ \(.\)/,\&\1/g'`
else # all_targets is true
# Only set these if they will be nonempty, for the clever echo.
havevecs=
+ assocvecs=
test -n "$selvecs" &&
havevecs=`echo $selvecs | sed -e 's/^/-DHAVE_/' -e 's/ \(.\)/ -DHAVE_\1/g'`
test -n "$selvecs" &&
@@ -6302,17 +6566,17 @@ case ${host64}-${target64}-${want64} in
wordsize=64
bfd_libs='$(BFD64_LIBS) $(BFD32_LIBS)'
all_backends='$(BFD64_BACKENDS) $(BFD32_BACKENDS)'
- if test -z "$GCC" && test "$BFD_HOST_64BIT_LONG" = "0" && test "$BFD_HOST_64_BIT_DEFINED" = "0"; then
+ if test $BFD_HOST_64_BIT_DEFINED = 0; then
echo "configure: warning: You have requested a 64 bit BFD configuration, but" 1>&2
echo "configure: warning: your compiler may not have a 64 bit integral type" 1>&2
fi
if test -n "$GCC" ; then
bad_64bit_gcc=no;
echo $ac_n "checking for gcc version with buggy 64-bit support""... $ac_c" 1>&6
-echo "configure:6313: checking for gcc version with buggy 64-bit support" >&5
+echo "configure:6577: checking for gcc version with buggy 64-bit support" >&5
# Add more tests for gcc versions with non-working 64-bit support here.
cat > conftest.$ac_ext <<EOF
-#line 6316 "configure"
+#line 6580 "configure"
#include "confdefs.h"
:__GNUC__:__GNUC_MINOR__:__i386__:
EOF
@@ -6346,28 +6610,144 @@ esac
+# Determine the host dependant file_ptr a.k.a. off_t type. In order
+# prefer: off64_t - if ftello64 and fseeko64, off_t - if ftello and
+# fseeko, long. This assumes that sizeof off_t is .ge. sizeof long.
+# Hopefully a reasonable assumption since fseeko et.al. should be
+# upward compatible.
+for ac_func in ftello ftello64 fseeko fseeko64
+do
+echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
+echo "configure:6622: checking for $ac_func" >&5
+if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ cat > conftest.$ac_ext <<EOF
+#line 6627 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+ which can conflict with char $ac_func(); below. */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error. */
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char $ac_func();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+ to always fail with ENOSYS. Some functions are actually named
+ something starting with __ and the normal name is an alias. */
+#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
+choke me
+#else
+$ac_func();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:6650: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ rm -rf conftest*
+ eval "ac_cv_func_$ac_func=yes"
+else
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+ rm -rf conftest*
+ eval "ac_cv_func_$ac_func=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
+ echo "$ac_t""yes" 1>&6
+ ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
+ cat >> confdefs.h <<EOF
+#define $ac_tr_func 1
+EOF
+
+else
+ echo "$ac_t""no" 1>&6
+fi
+done
+
+if test x"$ac_cv_func_ftello" = xyes -a x"$ac_cv_func_fseeko" = xyes; then
+ echo $ac_n "checking size of off_t""... $ac_c" 1>&6
+echo "configure:6676: checking size of off_t" >&5
+if eval "test \"`echo '$''{'ac_cv_sizeof_off_t'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ for ac_size in 4 8 1 2 16 12 ; do # List sizes in rough order of prevalence.
+ cat > conftest.$ac_ext <<EOF
+#line 6682 "configure"
+#include "confdefs.h"
+#include "confdefs.h"
+#include <sys/types.h>
+
+
+int main() {
+switch (0) case 0: case (sizeof (off_t) == $ac_size):;
+; return 0; }
+EOF
+if { (eval echo configure:6692: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ rm -rf conftest*
+ ac_cv_sizeof_off_t=$ac_size
+else
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+fi
+rm -f conftest*
+ if test x$ac_cv_sizeof_off_t != x ; then break; fi
+done
+
+fi
+
+if test x$ac_cv_sizeof_off_t = x ; then
+ { echo "configure: error: cannot determine a size for off_t" 1>&2; exit 1; }
+fi
+echo "$ac_t""$ac_cv_sizeof_off_t" 1>&6
+cat >> confdefs.h <<EOF
+#define SIZEOF_OFF_T $ac_cv_sizeof_off_t
+EOF
+
+
+fi
+echo $ac_n "checking file_ptr type""... $ac_c" 1>&6
+echo "configure:6716: checking file_ptr type" >&5
+bfd_file_ptr="long"
+bfd_ufile_ptr="unsigned long"
+if test x"$ac_cv_func_ftello64" = xyes -a x"$ac_cv_func_fseeko64" = xyes \
+ -o x"${ac_cv_sizeof_off_t}" = x8; then
+ bfd_file_ptr=BFD_HOST_64_BIT
+ bfd_ufile_ptr=BFD_HOST_U_64_BIT
+fi
+echo "$ac_t""$bfd_file_ptr" 1>&6
+
+
+
+
tdefaults=""
test -n "${defvec}" && tdefaults="${tdefaults} -DDEFAULT_VECTOR=${defvec}"
test -n "${selvecs}" && tdefaults="${tdefaults} -DSELECT_VECS='${selvecs}'"
+test -n "${assocvecs}" && tdefaults="${tdefaults} -DASSOCIATED_VECS='${assocvecs}'"
test -n "${selarchs}" && tdefaults="${tdefaults} -DSELECT_ARCHITECTURES='${selarchs}'"
test -n "${havevecs}" && tdefaults="${tdefaults} ${havevecs}"
-for ac_hdr in unistd.h
+for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:6361: checking for $ac_hdr" >&5
+echo "configure:6741: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 6366 "configure"
+#line 6746 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:6371: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:6751: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -6396,12 +6776,12 @@ done
for ac_func in getpagesize
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:6400: checking for $ac_func" >&5
+echo "configure:6780: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 6405 "configure"
+#line 6785 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -6424,7 +6804,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:6428: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6808: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -6449,7 +6829,7 @@ fi
done
echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:6453: checking for working mmap" >&5
+echo "configure:6833: checking for working mmap" >&5
if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -6457,7 +6837,7 @@ else
ac_cv_func_mmap_fixed_mapped=no
else
cat > conftest.$ac_ext <<EOF
-#line 6461 "configure"
+#line 6841 "configure"
#include "confdefs.h"
/* Thanks to Mike Haertel and Jim Avera for this test.
@@ -6485,11 +6865,24 @@ else
#include <fcntl.h>
#include <sys/mman.h>
+#if HAVE_SYS_TYPES_H
+# include <sys/types.h>
+#endif
+
+#if HAVE_STDLIB_H
+# include <stdlib.h>
+#endif
+
+#if HAVE_SYS_STAT_H
+# include <sys/stat.h>
+#endif
+
+#if HAVE_UNISTD_H
+# include <unistd.h>
+#endif
+
/* This mess was copied from the GNU getpagesize.h. */
#ifndef HAVE_GETPAGESIZE
-# ifdef HAVE_UNISTD_H
-# include <unistd.h>
-# endif
/* Assume that all systems that can run configure have sys/param.h. */
# ifndef HAVE_SYS_PARAM_H
@@ -6597,7 +6990,7 @@ main()
}
EOF
-if { (eval echo configure:6601: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:6994: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_func_mmap_fixed_mapped=yes
else
@@ -6622,12 +7015,12 @@ fi
for ac_func in madvise mprotect
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:6626: checking for $ac_func" >&5
+echo "configure:7019: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 6631 "configure"
+#line 7024 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -6650,7 +7043,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:6654: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7047: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -6783,7 +7176,7 @@ done
ac_given_srcdir=$srcdir
ac_given_INSTALL="$INSTALL"
-trap 'rm -fr `echo "Makefile doc/Makefile bfd-in3.h:bfd-in2.h po/Makefile.in:po/Make-in config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
+trap 'rm -fr `echo "Makefile doc/Makefile bfd-in3.h:bfd-in2.h bfdver.h:version.h po/Makefile.in:po/Make-in config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
EOF
cat >> $CONFIG_STATUS <<EOF
@@ -6830,7 +7223,6 @@ s%@build_alias@%$build_alias%g
s%@build_cpu@%$build_cpu%g
s%@build_vendor@%$build_vendor%g
s%@build_os@%$build_os%g
-s%@CC@%$CC%g
s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
s%@INSTALL_DATA@%$INSTALL_DATA%g
@@ -6843,10 +7235,10 @@ s%@AUTOHEADER@%$AUTOHEADER%g
s%@MAKEINFO@%$MAKEINFO%g
s%@SET_MAKE@%$SET_MAKE%g
s%@bfd_version@%$bfd_version%g
-s%@bfd_version_date@%$bfd_version_date%g
s%@bfd_version_string@%$bfd_version_string%g
s%@AR@%$AR%g
s%@RANLIB@%$RANLIB%g
+s%@CC@%$CC%g
s%@LN_S@%$LN_S%g
s%@OBJEXT@%$OBJEXT%g
s%@EXEEXT@%$EXEEXT%g
@@ -6884,6 +7276,7 @@ s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g
s%@l@%$l%g
s%@HDEFINES@%$HDEFINES%g
s%@BFD_HOST_64BIT_LONG@%$BFD_HOST_64BIT_LONG%g
+s%@BFD_HOST_LONG_LONG@%$BFD_HOST_LONG_LONG%g
s%@BFD_HOST_64_BIT_DEFINED@%$BFD_HOST_64_BIT_DEFINED%g
s%@BFD_HOST_64_BIT@%$BFD_HOST_64_BIT%g
s%@BFD_HOST_U_64_BIT@%$BFD_HOST_U_64_BIT%g
@@ -6900,6 +7293,8 @@ s%@all_backends@%$all_backends%g
s%@bfd_backends@%$bfd_backends%g
s%@bfd_machines@%$bfd_machines%g
s%@bfd_default_target_size@%$bfd_default_target_size%g
+s%@bfd_file_ptr@%$bfd_file_ptr%g
+s%@bfd_ufile_ptr@%$bfd_ufile_ptr%g
s%@tdefaults@%$tdefaults%g
CEOF
@@ -6942,7 +7337,7 @@ EOF
cat >> $CONFIG_STATUS <<EOF
-CONFIG_FILES=\${CONFIG_FILES-"Makefile doc/Makefile bfd-in3.h:bfd-in2.h po/Makefile.in:po/Make-in"}
+CONFIG_FILES=\${CONFIG_FILES-"Makefile doc/Makefile bfd-in3.h:bfd-in2.h bfdver.h:version.h po/Makefile.in:po/Make-in"}
EOF
cat >> $CONFIG_STATUS <<\EOF
for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
diff --git a/contrib/binutils/bfd/configure.host b/contrib/binutils/bfd/configure.host
index 207e4c0..024ed62 100644
--- a/contrib/binutils/bfd/configure.host
+++ b/contrib/binutils/bfd/configure.host
@@ -19,51 +19,39 @@ HOST_U_64BIT_TYPE=
case "${host}" in
-alpha*-*-*) host64=true; HOST_64BIT_TYPE=long ;;
-
-hppa*64*-*-hpux*) HDEFINES=-DHOST_HPPAHPUX;
- host64=true; HOST_64BIT_TYPE=long ;;
-hppa*-*-hpux*) HDEFINES=-DHOST_HPPAHPUX ;;
+hppa*-*-hpux*) # HP/UX's ftello64 et.al. declarations are only
+ # visible when _LARGEFILE64_SOURCE is defined.
+ # Without those declarations, real_ftell et.al.
+ # get mis-compiled.
+ HDEFINES="-DHOST_HPPAHPUX -D_LARGEFILE64_SOURCE" ;;
hppa*-*-hiux*) HDEFINES=-DHOST_HPPAHPUX ;;
-hppa*64*-*-linux*) host64=true; HOST_64BIT_TYPE=long ;;
hppa*-*-mpeix*) HDEFINES=-DHOST_HPPAMPEIX ;;
hppa*-*-bsd*) HDEFINES=-DHOST_HPPABSD ;;
hppa*-*-osf*) HDEFINES=-DHOST_HPPAOSF ;;
-ia64-*-linux*) host64=true; HOST_64BIT_TYPE=long ;;
-ia64-*-aix*) host64=true; HOST_64BIT_TYPE=long ;;
+ia64-*-*) host64=true;;
+
+# Workaround for limitations on win9x where file contents are
+# not zero'd out if you seek past the end and then write.
+i[3-7]86-*-mingw32*) HDEFINES=-D__USE_MINGW_FSEEK;;
-i[3456]86-sequent-bsd*) HDEFINES=-Dshared=genshared ;;
-i[3456]86-sequent-sysv4*) ;;
-i[3456]86-sequent-sysv*) HDEFINES=-Dshared=genshared ;;
+i[3-7]86-sequent-bsd*) HDEFINES=-Dshared=genshared ;;
+i[3-7]86-sequent-sysv4*) ;;
+i[3-7]86-sequent-sysv*) HDEFINES=-Dshared=genshared ;;
mips*-*-netbsd*) ;;
mips*-*-openbsd*) ;;
mips*-dec-*) HDEFINES="-G 4" ;;
mips*-sgi-irix3*) HDEFINES="-G 4" ;;
mips*-sgi-irix4*) HDEFINES="-G 4" ;;
-mips*-sgi-irix6*) host64=true
- HOST_64BIT_TYPE="long long";
- HOST_U_64BIT_TYPE="unsigned long long";
- ;;
-mips64*-*-linux*) host64=true
- HOST_64BIT_TYPE="long long";
- HOST_U_64BIT_TYPE="unsigned long long";
- ;;
+mips*-sgi-irix6*) host64=true;;
+mips64*-*-linux*) host64=true;;
mips*-*-sysv4*) ;;
mips*-*-sysv*) HDEFINES="-G 4" ;;
mips*-*-riscos*) HDEFINES="-G 4" ;;
m68*-hp-hpux*) HDEFINES=-DHOST_HP300HPUX ;;
-*-*-aix*) HOST_64BIT_TYPE="long long"
- HOST_U_64BIT_TYPE="unsigned long long"
- ;;
-
-*-*-solaris*) HOST_64BIT_TYPE="long long"
- HOST_U_64BIT_TYPE="unsigned long long"
- ;;
-
*-*-windows*)
HOST_64BIT_TYPE=__int64
HOST_U_64BIT_TYPE="unsigned __int64"
diff --git a/contrib/binutils/bfd/configure.in b/contrib/binutils/bfd/configure.in
index 4db2520..837b753 100644
--- a/contrib/binutils/bfd/configure.in
+++ b/contrib/binutils/bfd/configure.in
@@ -7,26 +7,20 @@ AC_INIT(libbfd.c)
AC_CANONICAL_SYSTEM
AC_ISC_POSIX
-AM_INIT_AUTOMAKE(bfd, 2.13.1)
+AM_INIT_AUTOMAKE(bfd, 2.15)
# Uncomment the next line to remove the date from the reported bfd version
-# is_release=y
+#is_release=y
changequote(,)dnl
bfd_version=`echo "${VERSION}" | sed -e 's/\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\)\.*\([^\.]*\).*/\1.00\2.00\3.00\4.00\5/' -e 's/\([^\.]*\)\..*\(..\)\..*\(..\)\..*\(..\)\..*\(..\)$/\1\2\3\4\5/'`
changequote([,])dnl
bfd_version_string="\"${VERSION}\""
-bfd_version_date=`sed -e 's/.*DATE //' < ${srcdir}/version.h`
if test x${is_release} = x; then
-dnl Sad, but we can't use XSTRING here to pick up the date from version.h
-dnl because traditional C doesn't allow it.
+ bfd_version_date=`sed -n -e 's/.*DATE //p' < ${srcdir}/version.h`
bfd_version_string="\"${VERSION} ${bfd_version_date}\""
fi
-dnl Since we need to edit bfd-in3.h to get the date for bfd_version_string,
-dnl we may as well substitute for bfd_version_date too. That way we don't
-dnl need to #include version.h
AC_SUBST(bfd_version)
-AC_SUBST(bfd_version_date)
AC_SUBST(bfd_version_string)
dnl These must be called before AM_PROG_LIBTOOL, because it may want
@@ -86,7 +80,7 @@ if test x"$silent" != x"yes" && test x"$build_warnings" != x""; then
echo "Setting warning flags = $build_warnings" 6>&1
fi])dnl
WARN_CFLAGS=""
-if test "x${build_warnings}" != x -a "x$GCC" = xyes ; then
+if test "x${build_warnings}" != x && test "x$GCC" = xyes ; then
WARN_CFLAGS="${build_warnings}"
fi
AC_SUBST(WARN_CFLAGS)
@@ -109,7 +103,7 @@ bfd_default_target_size=32
AC_PROG_CC
-ALL_LINGUAS="fr tr ja es sv da"
+ALL_LINGUAS="fr tr ja es sv da zh_CN ro"
CY_GNU_GETTEXT
# Permit host specific settings.
@@ -119,17 +113,41 @@ AC_SUBST(HDEFINES)
AC_PROG_INSTALL
BFD_HOST_64BIT_LONG=0
+BFD_HOST_LONG_LONG=0
BFD_HOST_64_BIT_DEFINED=0
BFD_HOST_64_BIT=
BFD_HOST_U_64_BIT=
-if test "x${HOST_64BIT_TYPE}" = "xlong"; then
+
+AC_MSG_CHECKING([for long long])
+AC_CACHE_VAL(bfd_cv_has_long_long,
+[AC_TRY_COMPILE(,
+[unsigned long long ll = 18446744073709551615ULL;],
+bfd_cv_has_long_long=yes, bfd_cv_has_long_long=no)])
+AC_MSG_RESULT($bfd_cv_has_long_long)
+if test $bfd_cv_has_long_long = yes; then
+ BFD_HOST_LONG_LONG=1
+ AC_COMPILE_CHECK_SIZEOF(long long)
+fi
+
+AC_COMPILE_CHECK_SIZEOF(long)
+if test "x${ac_cv_sizeof_long}" = "x8"; then
+ host64=true
BFD_HOST_64BIT_LONG=1
-elif test "x${HOST_64BIT_TYPE}" != "x"; then
+ test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long"
+ test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long"
+elif test "x${ac_cv_sizeof_long_long}" = "x8"; then
+ test -n "${HOST_64BIT_TYPE}" || HOST_64BIT_TYPE="long long"
+ test -n "${HOST_U_64BIT_TYPE}" || HOST_U_64BIT_TYPE="unsigned long long"
+fi
+
+if test -n "${HOST_64BIT_TYPE}" -a -n "${HOST_U_64BIT_TYPE}"; then
BFD_HOST_64_BIT_DEFINED=1
- BFD_HOST_64_BIT=${HOST_64BIT_TYPE}
- BFD_HOST_U_64_BIT=${HOST_U_64BIT_TYPE}
+ BFD_HOST_64_BIT="${HOST_64BIT_TYPE}"
+ BFD_HOST_U_64_BIT="${HOST_U_64BIT_TYPE}"
fi
+
AC_SUBST(BFD_HOST_64BIT_LONG)
+AC_SUBST(BFD_HOST_LONG_LONG)
AC_SUBST(BFD_HOST_64_BIT_DEFINED)
AC_SUBST(BFD_HOST_64_BIT)
AC_SUBST(BFD_HOST_U_64_BIT)
@@ -141,6 +159,7 @@ AC_CHECK_HEADERS(fcntl.h sys/file.h sys/time.h)
AC_HEADER_TIME
AC_HEADER_DIRENT
AC_CHECK_FUNCS(fcntl getpagesize setitimer sysconf fdopen getuid getgid)
+AC_CHECK_FUNCS(strtoull)
BFD_BINARY_FOPEN
@@ -156,7 +175,7 @@ COREFLAG=
TRAD_HEADER=
if test "${target}" = "${host}"; then
case "${host}" in
- alpha*-*-freebsd*)
+ alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu)
COREFILE=''
;;
alpha*-*-linux-gnu*)
@@ -167,7 +186,8 @@ if test "${target}" = "${host}"; then
COREFILE=netbsd-core.lo
;;
alpha*-*-*) COREFILE=osf-core.lo ;;
- arm-*-freebsd*) COREFILE='' ;;
+ arm-*-freebsd* | arm-*-kfreebsd*-gnu)
+ COREFILE='' ;;
arm-*-netbsd*) COREFILE=netbsd-core.lo ;;
arm-*-riscix) COREFILE=trad-core.lo ;;
hppa*-*-hpux*) COREFILE=hpux-core.lo ;;
@@ -181,85 +201,77 @@ if test "${target}" = "${host}"; then
;;
changequote(,)dnl
- i[3456]86-sequent-bsd*)
+ i[3-7]86-sequent-bsd*)
changequote([,])dnl
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/symmetry.h"'
;;
changequote(,)dnl
- i[3456]86-sequent-sysv4*) ;;
- i[3456]86-sequent-sysv*)
+ i[3-7]86-sequent-sysv4*) ;;
+ i[3-7]86-sequent-sysv*)
changequote([,])dnl
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/symmetry.h"'
;;
changequote(,)dnl
- i[3456]86-*-bsdi)
+ i[3-7]86-*-bsdi)
changequote([,])dnl
COREFILE=
;;
changequote(,)dnl
- i[3456]86-*-bsd* | i[34567]86-*-freebsd[123] | i[34567]86-*-freebsd[123]\.* | i[34567]86-*-freebsd4\.[01234]* | i[34567]86-*-freebsd*aout*)
+ i[3-7]86-*-bsd* | i[3-7]86-*-freebsd[123] | i[3-7]86-*-freebsd[123]\.* | i[3-7]86-*-freebsd4\.[01234]* | i[3-7]86-*-freebsd*aout*)
changequote([,])dnl
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/i386bsd.h"'
;;
changequote(,)dnl
- i[3456]86-*-freebsd*)
+ i[3-7]86-*-freebsd* | i[3-7]86-*-kfreebsd*-gnu)
changequote([,])dnl
COREFILE=''
TRAD_HEADER='"hosts/i386bsd.h"'
;;
changequote(,)dnl
- i[3456]86-*-netbsd* | i[3456]86-*-openbsd*)
+ i[3-7]86-*-netbsd* | i[3-7]86-*-knetbsd*-gnu | i[3-7]86-*-openbsd*)
changequote([,])dnl
COREFILE=netbsd-core.lo
;;
changequote(,)dnl
- i[3456]86-esix-sysv3*)
+ i[3-7]86-esix-sysv3*)
changequote([,])dnl
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/esix.h"'
;;
changequote(,)dnl
- i[3456]86-*-sco3.2v5*)
+ i[3-7]86-*-sco3.2v5*)
changequote([,])dnl
COREFILE=sco5-core.lo
;;
changequote(,)dnl
- i[3456]86-*-sco* | i[3456]86-*-isc*)
+ i[3-7]86-*-sco* | i[3-7]86-*-isc*)
changequote([,])dnl
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/i386sco.h"'
;;
changequote(,)dnl
- i[3456]86-*-mach3*)
+ i[3-7]86-*-mach3*)
changequote([,])dnl
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/i386mach3.h"'
;;
changequote(,)dnl
- i[3456]86-*-linux-gnu*)
+ i[3-7]86-*-linux-gnu*)
changequote([,])dnl
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/i386linux.h"'
;;
changequote(,)dnl
- i[3456]86-*-isc*) COREFILE=trad-core.lo ;;
- i[3456]86-*-aix*) COREFILE=aix386-core.lo ;;
+ i[3-7]86-*-isc*) COREFILE=trad-core.lo ;;
+ i[3-7]86-*-aix*) COREFILE=aix386-core.lo ;;
changequote([,])dnl
i860-*-mach3* | i860-*-osf1*)
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/i860mach3.h"'
;;
- mips-dec-bsd*)
- COREFILE=trad-core.lo
- TRAD_HEADER='"hosts/mipsbsd.h"'
- ;;
- mips-dec-mach3*)
- COREFILE=trad-core.lo
- TRAD_HEADER='"hosts/mipsmach3.h"'
- ;;
mips-*-netbsd* | mips*-*-openbsd*)
COREFILE=netbsd-core.lo
;;
@@ -270,10 +282,6 @@ changequote([,])dnl
mips-sgi-irix4*) COREFILE=irix-core.lo ;;
mips-sgi-irix5*) COREFILE=irix-core.lo ;;
mips-sgi-irix6*) COREFILE=irix-core.lo ;;
- mips-*-mach3*)
- COREFILE=trad-core.lo
- TRAD_HEADER='"hosts/mipsmach3.h"'
- ;;
mips-*-sysv4*) ;;
mips-*-sysv* | mips-*-riscos*)
COREFILE=trad-core.lo
@@ -353,7 +361,8 @@ changequote([,])dnl
powerpc-*-aix4*) COREFILE=rs6000-core.lo ;;
powerpc-*-aix*) COREFILE=rs6000-core.lo ;;
powerpc-*-beos*) ;;
- powerpc-*-freebsd*) COREFILE='' ;;
+ powerpc-*-freebsd* | powerpc-*-kfreebsd*-gnu)
+ COREFILE='' ;;
powerpc-*-netbsd*) COREFILE=netbsd-core.lo ;;
powerpc-*-*bsd*) COREFILE=netbsd-core.lo ;;
s390*-*-*) COREFILE=trad-core.lo ;;
@@ -365,7 +374,9 @@ changequote([,])dnl
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/tahoe.h"'
;;
- vax-*-netbsd*) COREFILE=netbsd-core.lo ;;
+ vax-*-netbsd* | vax-*-openbsd*)
+ COREFILE=netbsd-core.lo
+ ;;
vax-*-ultrix2*)
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/vaxult2.h"'
@@ -374,11 +385,17 @@ changequote([,])dnl
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/vaxult2.h"'
;;
+ vax-*-linux-gnu*)
+ COREFILE=trad-core.lo
+ TRAD_HEADER='"hosts/vaxlinux.h"'
+ ;;
vax-*-*)
COREFILE=trad-core.lo
TRAD_HEADER='"hosts/vaxbsd.h"'
;;
- x86_64-*-netbsd*) COREFILE=netbsd-core.lo ;;
+ x86_64-*-netbsd* | x86_64-*-openbsd*)
+ COREFILE=netbsd-core.lo
+ ;;
esac
case "$COREFILE" in
@@ -446,7 +463,7 @@ case "${host}" in
;;
*)
changequote(,)dnl
- x=`sed -n -e 's/^[ ]*PICFLAG[ ]*=[ ]*//p' < ../libiberty/Makefile | tail -1`
+ x=`sed -n -e 's/^[ ]*PICFLAG[ ]*=[ ]*//p' < ../libiberty/Makefile | sed -n '$p'`
changequote([,])dnl
if test -n "$x"; then
WIN32LIBADD="-L../libiberty/pic -liberty"
@@ -477,12 +494,14 @@ fi
all_targets=false
defvec=
selvecs=
+assocvecs=
selarchs=
TDEFINES=
for targ in $target $canon_targets
do
if test "x$targ" = "xall"; then
all_targets=true
+ assocvecs="$assocvecs $targ_defvec $targ_selvecs"
else
. $srcdir/config.bfd
if test "x$targ" = "x$target"; then
@@ -513,6 +532,17 @@ done
selvecs="$f"
+# uniq the associated vectors in all the configured targets.
+f=""
+for i in $assocvecs ; do
+ case " $f " in
+ *" $i "*) ;;
+ *) f="$f $i" ;;
+ esac
+done
+assocvecs="$f"
+
+
# uniq the architectures in all the configured targets.
f=""
for i in $selarchs ; do
@@ -541,8 +571,6 @@ do
aout0_big_vec) tb="$tb aout0.lo aout32.lo" ;;
aout_arm_big_vec) tb="$tb aout-arm.lo aout32.lo" ;;
aout_arm_little_vec) tb="$tb aout-arm.lo aout32.lo" ;;
- aout_mips_big_vec) tb="$tb mipsbsd.lo aout32.lo" ;;
- aout_mips_little_vec) tb="$tb mipsbsd.lo aout32.lo" ;;
apollocoff_vec) tb="$tb coff-apollo.lo" ;;
arm_epoc_pe_big_vec) tb="$tb epoc-pe-arm.lo peigen.lo cofflink.lo " ;;
arm_epoc_pe_little_vec) tb="$tb epoc-pe-arm.lo peigen.lo cofflink.lo " ;;
@@ -559,6 +587,7 @@ do
b_out_vec_little_host) tb="$tb bout.lo aout32.lo" ;;
bfd_efi_app_ia32_vec) tb="$tb efi-app-ia32.lo peigen.lo cofflink.lo" ;;
bfd_efi_app_ia64_vec) tb="$tb efi-app-ia64.lo pepigen.lo cofflink.lo"; target_size=64 ;;
+ bfd_elf32_am33lin_vec) tb="$tb elf32-am33lin.lo elf32.lo $elf" ;;
bfd_elf32_avr_vec) tb="$tb elf32-avr.lo elf32.lo $elf" ;;
bfd_elf32_big_generic_vec) tb="$tb elf32-gen.lo elf32.lo $elf" ;;
bfd_elf32_bigarc_vec) tb="$tb elf32-arc.lo elf32.lo $elf" ;;
@@ -571,31 +600,42 @@ do
bfd_elf32_dlx_big_vec) tb="$tb elf32-dlx.lo elf32.lo $elf" ;;
bfd_elf32_fr30_vec) tb="$tb elf32-fr30.lo elf32.lo $elf" ;;
bfd_elf32_frv_vec) tb="$tb elf32-frv.lo elf32.lo $elf" ;;
+ bfd_elf32_frvfdpic_vec) tb="$tb elf32-frv.lo elf32.lo $elf" ;;
bfd_elf32_h8300_vec) tb="$tb elf32-h8300.lo elf32.lo $elf" ;;
bfd_elf32_hppa_linux_vec) tb="$tb elf32-hppa.lo elf32.lo $elf" ;;
bfd_elf32_hppa_vec) tb="$tb elf32-hppa.lo elf32.lo $elf" ;;
bfd_elf32_i370_vec) tb="$tb elf32-i370.lo elf32.lo $elf" ;;
- bfd_elf32_i386_freebsd_vec) tb="$tb elf32-i386-fbsd.lo elf32.lo $elf" ;;
+ bfd_elf32_i386_freebsd_vec) tb="$tb elf32-i386.lo elf32.lo $elf" ;;
bfd_elf32_i386_vec) tb="$tb elf32-i386.lo elf32.lo $elf" ;;
bfd_elf32_i860_little_vec) tb="$tb elf32-i860.lo elf32.lo $elf" ;;
bfd_elf32_i860_vec) tb="$tb elf32-i860.lo elf32.lo $elf" ;;
bfd_elf32_i960_vec) tb="$tb elf32-i960.lo elf32.lo $elf" ;;
bfd_elf32_ia64_big_vec) tb="$tb elf32-ia64.lo elf32.lo $elf" ;;
bfd_elf32_ia64_hpux_big_vec) tb="$tb elf32-ia64.lo elf32.lo $elf";;
+ bfd_elf32_ip2k_vec) tb="$tb elf32-ip2k.lo elf32.lo $elf" ;;
+ bfd_elf32_iq2000_vec) tb="$tb elf32-iq2000.lo elf32.lo $elf" ;;
bfd_elf32_little_generic_vec) tb="$tb elf32-gen.lo elf32.lo $elf" ;;
bfd_elf32_littlearc_vec) tb="$tb elf32-arc.lo elf32.lo $elf" ;;
bfd_elf32_littlearm_oabi_vec) tb="$tb elfarm-oabi.lo elf32.lo $elf" ;;
bfd_elf32_littlearm_vec) tb="$tb elfarm-nabi.lo elf32.lo $elf" ;;
bfd_elf32_littlemips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo" ;;
bfd_elf32_m32r_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;;
- bfd_elf32_m68hc11_vec) tb="$tb elf32-m68hc11.lo elf32.lo $elf" ;;
- bfd_elf32_m68hc12_vec) tb="$tb elf32-m68hc12.lo elf32.lo $elf" ;;
+ bfd_elf32_m32rle_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;;
+ bfd_elf32_m32rlin_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;;
+ bfd_elf32_m32rlelin_vec) tb="$tb elf32-m32r.lo elf32.lo $elf" ;;
+ bfd_elf32_m68hc11_vec) tb="$tb elf32-m68hc11.lo elf32-m68hc1x.lo elf32.lo $elf" ;;
+ bfd_elf32_m68hc12_vec) tb="$tb elf32-m68hc12.lo elf32-m68hc1x.lo elf32.lo $elf" ;;
bfd_elf32_m68k_vec) tb="$tb elf32-m68k.lo elf32.lo $elf" ;;
bfd_elf32_m88k_vec) tb="$tb elf32-m88k.lo elf32.lo $elf" ;;
bfd_elf32_mcore_big_vec) tb="$tb elf32-mcore.lo elf32.lo $elf" ;;
bfd_elf32_mcore_little_vec) tb="$tb elf32-mcore.lo elf32.lo $elf" ;;
bfd_elf32_mn10200_vec) tb="$tb elf-m10200.lo elf32.lo $elf" ;;
bfd_elf32_mn10300_vec) tb="$tb elf-m10300.lo elf32.lo $elf" ;;
+ bfd_elf32_msp430_vec) tb="$tb elf32-msp430.lo elf32.lo $elf" ;;
+ bfd_elf32_nbigmips_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
+ bfd_elf32_nlittlemips_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
+ bfd_elf32_ntradbigmips_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
+ bfd_elf32_ntradlittlemips_vec) tb="$tb elfn32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
bfd_elf32_openrisc_vec) tb="$tb elf32-openrisc.lo elf32.lo $elf" ;;
bfd_elf32_or32_big_vec) tb="$tb elf32-or32.lo elf32.lo $elf" ;;
bfd_elf32_pj_vec) tb="$tb elf32-pj.lo elf32.lo $elf";;
@@ -608,14 +648,16 @@ do
# which needs it but does not list it. Should be fixed in right place.
bfd_elf32_sh64_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" target_size=64 ;;
bfd_elf32_sh64l_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" target_size=64 ;;
- bfd_elf32_sh64lnbsd_vec) tb="$tb elf32-sh64-nbsd.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" ;;
- bfd_elf32_sh64nbsd_vec) tb="$tb elf32-sh64-nbsd.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" ;;
+ bfd_elf32_sh64lin_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" target_size=64 ;;
+ bfd_elf32_sh64blin_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" target_size=64 ;;
+ bfd_elf32_sh64lnbsd_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" ;;
+ bfd_elf32_sh64nbsd_vec) tb="$tb elf32-sh64.lo elf32-sh64-com.lo elf32.lo $elf cofflink.lo" ;;
bfd_elf32_sh_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo" ;;
- bfd_elf32_shblin_vec) tb="$tb elf32-sh-lin.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
+ bfd_elf32_shblin_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
bfd_elf32_shl_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo" ;;
- bfd_elf32_shlin_vec) tb="$tb elf32-sh-lin.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
- bfd_elf32_shlnbsd_vec) tb="$tb elf32-sh-nbsd.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
- bfd_elf32_shnbsd_vec) tb="$tb elf32-sh-nbsd.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
+ bfd_elf32_shlin_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
+ bfd_elf32_shlnbsd_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
+ bfd_elf32_shnbsd_vec) tb="$tb elf32-sh.lo elf32.lo $elf coff-sh.lo cofflink.lo" ;;
bfd_elf32_sparc_vec) tb="$tb elf32-sparc.lo elf32.lo $elf" ;;
bfd_elf32_tradbigmips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo" ;;
bfd_elf32_tradlittlemips_vec) tb="$tb elf32-mips.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo" ;;
@@ -623,14 +665,14 @@ do
bfd_elf32_v850_vec) tb="$tb elf32-v850.lo elf32.lo $elf" ;;
bfd_elf32_vax_vec) tb="$tb elf32-vax.lo elf32.lo $elf" ;;
bfd_elf32_xstormy16_vec) tb="$tb elf32-xstormy16.lo elf32.lo $elf" ;;
- bfd_elf64_alpha_freebsd_vec) tb="$tb elf64-alpha-fbsd.lo elf64.lo $elf"; target_size=64 ;;
+ bfd_elf32_xtensa_le_vec) tb="$tb xtensa-isa.lo xtensa-modules.lo elf32-xtensa.lo elf32.lo $elf" ;;
+ bfd_elf32_xtensa_be_vec) tb="$tb xtensa-isa.lo xtensa-modules.lo elf32-xtensa.lo elf32.lo $elf" ;;
+ bfd_elf64_alpha_freebsd_vec) tb="$tb elf64-alpha.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_alpha_vec) tb="$tb elf64-alpha.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_big_generic_vec) tb="$tb elf64-gen.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_bigmips_vec) tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
bfd_elf64_hppa_linux_vec) tb="$tb elf64-hppa.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_hppa_vec) tb="$tb elf64-hppa.lo elf64.lo $elf"; target_size=64 ;;
- bfd_elf64_ia64_aix_big_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;;
- bfd_elf64_ia64_aix_little_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_ia64_big_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_ia64_hpux_big_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_ia64_little_vec) tb="$tb elf64-ia64.lo elf64.lo $elf"; target_size=64 ;;
@@ -642,8 +684,10 @@ do
bfd_elf64_s390_vec) tb="$tb elf64-s390.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_sh64_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;;
bfd_elf64_sh64l_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;;
- bfd_elf64_sh64lnbsd_vec) tb="$tb elf64-sh64-nbsd.lo elf64.lo $elf" target_size=64 ;;
- bfd_elf64_sh64nbsd_vec) tb="$tb elf64-sh64-nbsd.lo elf64.lo $elf" target_size=64 ;;
+ bfd_elf64_sh64lin_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;;
+ bfd_elf64_sh64blin_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;;
+ bfd_elf64_sh64lnbsd_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;;
+ bfd_elf64_sh64nbsd_vec) tb="$tb elf64-sh64.lo elf64.lo $elf" target_size=64 ;;
bfd_elf64_sparc_vec) tb="$tb elf64-sparc.lo elf64.lo $elf"; target_size=64 ;;
bfd_elf64_tradbigmips_vec) tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
bfd_elf64_tradlittlemips_vec) tb="$tb elf64-mips.lo elf64.lo elfxx-mips.lo elf32.lo $elf ecofflink.lo"; target_size=64 ;;
@@ -695,6 +739,9 @@ do
m68ksysvcoff_vec) tb="$tb coff-svm68k.lo cofflink.lo" ;;
m88kbcs_vec) tb="$tb coff-m88k.lo" ;;
m88kmach3_vec) tb="$tb m88kmach3.lo aout32.lo" ;;
+ mach_o_be_vec) tb="$tb mach-o.lo" ;;
+ mach_o_le_vec) tb="$tb mach-o.lo" ;;
+ mach_o_fat_vec) tb="$tb mach-o.lo" ;;
mcore_pe_big_vec) tb="$tb pe-mcore.lo peigen.lo cofflink.lo" ;;
mcore_pe_little_vec) tb="$tb pe-mcore.lo peigen.lo cofflink.lo" ;;
mcore_pei_big_vec) tb="$tb pei-mcore.lo peigen.lo cofflink.lo" ;;
@@ -709,6 +756,8 @@ do
or32coff_big_vec) tb="$tb coff-or32.lo cofflink.lo" ;;
pc532machaout_vec) tb="$tb pc532-mach.lo aout-ns32k.lo" ;;
pc532netbsd_vec) tb="$tb ns32knetbsd.lo aout-ns32k.lo" ;;
+ pef_vec) tb="$tb pef.lo" ;;
+ pef_xlib_vec) tb="$tb pef.lo" ;;
pdp11_aout_vec) tb="$tb pdp11.lo" ;;
pmac_xcoff_vec) tb="$tb coff-rs6000.lo xcofflink.lo" ;;
ppcboot_vec) tb="$tb ppcboot.lo" ;;
@@ -729,8 +778,15 @@ do
sparclynx_coff_vec) tb="$tb cf-sparclynx.lo lynx-core.lo" ;;
sparcnetbsd_vec) tb="$tb sparcnetbsd.lo aout32.lo" ;;
sunos_big_vec) tb="$tb sunos.lo aout32.lo" ;;
+ sym_vec) tb="$tb xsym.lo" ;;
tic30_aout_vec) tb="$tb aout-tic30.lo" ;;
tic30_coff_vec) tb="$tb coff-tic30.lo" ;;
+ tic4x_coff0_vec) tb="$tb coff-tic4x.lo" ;;
+ tic4x_coff0_beh_vec) tb="$tb coff-tic4x.lo" ;;
+ tic4x_coff1_vec) tb="$tb coff-tic4x.lo" ;;
+ tic4x_coff1_beh_vec) tb="$tb coff-tic4x.lo" ;;
+ tic4x_coff2_vec) tb="$tb coff-tic4x.lo" ;;
+ tic4x_coff2_beh_vec) tb="$tb coff-tic4x.lo" ;;
tic54x_coff0_beh_vec) tb="$tb coff-tic54x.lo" ;;
tic54x_coff0_vec) tb="$tb coff-tic54x.lo" ;;
tic54x_coff1_beh_vec) tb="$tb coff-tic54x.lo" ;;
@@ -800,9 +856,12 @@ if test x${all_targets} = xtrue ; then
selvecs=
havevecs=
selarchs=
+ test -n "$assocvecs" &&
+ assocvecs=`echo $assocvecs | sed -e 's/^/\&/' -e 's/ \(.\)/,\&\1/g'`
else # all_targets is true
# Only set these if they will be nonempty, for the clever echo.
havevecs=
+ assocvecs=
test -n "$selvecs" &&
havevecs=`echo $selvecs | sed -e 's/^/-DHAVE_/' -e 's/ \(.\)/ -DHAVE_\1/g'`
test -n "$selvecs" &&
@@ -816,7 +875,7 @@ case ${host64}-${target64}-${want64} in
wordsize=64
bfd_libs='$(BFD64_LIBS) $(BFD32_LIBS)'
all_backends='$(BFD64_BACKENDS) $(BFD32_BACKENDS)'
- if test -z "$GCC" && test "$BFD_HOST_64BIT_LONG" = "0" && test "$BFD_HOST_64_BIT_DEFINED" = "0"; then
+ if test $BFD_HOST_64_BIT_DEFINED = 0; then
AC_MSG_WARN([You have requested a 64 bit BFD configuration, but])
AC_MSG_WARN([your compiler may not have a 64 bit integral type])
fi
@@ -847,9 +906,32 @@ AC_SUBST(bfd_backends)
AC_SUBST(bfd_machines)
AC_SUBST(bfd_default_target_size)
+# Determine the host dependant file_ptr a.k.a. off_t type. In order
+# prefer: off64_t - if ftello64 and fseeko64, off_t - if ftello and
+# fseeko, long. This assumes that sizeof off_t is .ge. sizeof long.
+# Hopefully a reasonable assumption since fseeko et.al. should be
+# upward compatible.
+AC_CHECK_FUNCS(ftello ftello64 fseeko fseeko64)
+if test x"$ac_cv_func_ftello" = xyes -a x"$ac_cv_func_fseeko" = xyes; then
+ AC_COMPILE_CHECK_SIZEOF(off_t)
+fi
+AC_MSG_CHECKING([file_ptr type])
+bfd_file_ptr="long"
+bfd_ufile_ptr="unsigned long"
+if test x"$ac_cv_func_ftello64" = xyes -a x"$ac_cv_func_fseeko64" = xyes \
+ -o x"${ac_cv_sizeof_off_t}" = x8; then
+ bfd_file_ptr=BFD_HOST_64_BIT
+ bfd_ufile_ptr=BFD_HOST_U_64_BIT
+fi
+AC_MSG_RESULT($bfd_file_ptr)
+AC_SUBST(bfd_file_ptr)
+AC_SUBST(bfd_ufile_ptr)
+
+
tdefaults=""
test -n "${defvec}" && tdefaults="${tdefaults} -DDEFAULT_VECTOR=${defvec}"
test -n "${selvecs}" && tdefaults="${tdefaults} -DSELECT_VECS='${selvecs}'"
+test -n "${assocvecs}" && tdefaults="${tdefaults} -DASSOCIATED_VECS='${assocvecs}'"
test -n "${selarchs}" && tdefaults="${tdefaults} -DSELECT_ARCHITECTURES='${selarchs}'"
test -n "${havevecs}" && tdefaults="${tdefaults} ${havevecs}"
AC_SUBST(tdefaults)
@@ -862,6 +944,6 @@ case ${want_mmap}+${ac_cv_func_mmap_fixed_mapped} in
esac
rm -f doc/config.status
-AC_OUTPUT(Makefile doc/Makefile bfd-in3.h:bfd-in2.h po/Makefile.in:po/Make-in,
+AC_OUTPUT(Makefile doc/Makefile bfd-in3.h:bfd-in2.h bfdver.h:version.h po/Makefile.in:po/Make-in,
[sed -e '/SRC-POTFILES =/r po/SRC-POTFILES' -e '/BLD-POTFILES =/r po/BLD-POTFILES' po/Makefile.in > po/Makefile])
diff --git a/contrib/binutils/bfd/corefile.c b/contrib/binutils/bfd/corefile.c
index 2414225..8af4f45 100644
--- a/contrib/binutils/bfd/corefile.c
+++ b/contrib/binutils/bfd/corefile.c
@@ -1,5 +1,5 @@
/* Core file generic interface routines for BFD.
- Copyright 1990, 1991, 1992, 1993, 1994, 2000, 2001, 2002
+ Copyright 1990, 1991, 1992, 1993, 1994, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Support.
@@ -36,7 +36,7 @@ FUNCTION
bfd_core_file_failing_command
SYNOPSIS
- const char *bfd_core_file_failing_command(bfd *abfd);
+ const char *bfd_core_file_failing_command (bfd *abfd);
DESCRIPTION
Return a read-only string explaining which program was running
@@ -45,13 +45,13 @@ DESCRIPTION
*/
const char *
-bfd_core_file_failing_command (abfd)
- bfd *abfd;
+bfd_core_file_failing_command (bfd *abfd)
{
- if (abfd->format != bfd_core) {
- bfd_set_error (bfd_error_invalid_operation);
- return NULL;
- }
+ if (abfd->format != bfd_core)
+ {
+ bfd_set_error (bfd_error_invalid_operation);
+ return NULL;
+ }
return BFD_SEND (abfd, _core_file_failing_command, (abfd));
}
@@ -60,7 +60,7 @@ FUNCTION
bfd_core_file_failing_signal
SYNOPSIS
- int bfd_core_file_failing_signal(bfd *abfd);
+ int bfd_core_file_failing_signal (bfd *abfd);
DESCRIPTION
Returns the signal number which caused the core dump which
@@ -68,13 +68,13 @@ DESCRIPTION
*/
int
-bfd_core_file_failing_signal (abfd)
- bfd *abfd;
+bfd_core_file_failing_signal (bfd *abfd)
{
- if (abfd->format != bfd_core) {
- bfd_set_error (bfd_error_invalid_operation);
- return 0;
- }
+ if (abfd->format != bfd_core)
+ {
+ bfd_set_error (bfd_error_invalid_operation);
+ return 0;
+ }
return BFD_SEND (abfd, _core_file_failing_signal, (abfd));
}
@@ -83,23 +83,24 @@ FUNCTION
core_file_matches_executable_p
SYNOPSIS
- boolean core_file_matches_executable_p
- (bfd *core_bfd, bfd *exec_bfd);
+ bfd_boolean core_file_matches_executable_p
+ (bfd *core_bfd, bfd *exec_bfd);
DESCRIPTION
- Return <<true>> if the core file attached to @var{core_bfd}
+ Return <<TRUE>> if the core file attached to @var{core_bfd}
was generated by a run of the executable file attached to
- @var{exec_bfd}, <<false>> otherwise.
+ @var{exec_bfd}, <<FALSE>> otherwise.
*/
-boolean
-core_file_matches_executable_p (core_bfd, exec_bfd)
- bfd *core_bfd, *exec_bfd;
-{
- if ((core_bfd->format != bfd_core) || (exec_bfd->format != bfd_object)) {
- bfd_set_error (bfd_error_wrong_format);
- return false;
- }
- return BFD_SEND (core_bfd, _core_file_matches_executable_p,
- (core_bfd, exec_bfd));
+bfd_boolean
+core_file_matches_executable_p (bfd *core_bfd, bfd *exec_bfd)
+{
+ if (core_bfd->format != bfd_core || exec_bfd->format != bfd_object)
+ {
+ bfd_set_error (bfd_error_wrong_format);
+ return FALSE;
+ }
+
+ return BFD_SEND (core_bfd, _core_file_matches_executable_p,
+ (core_bfd, exec_bfd));
}
diff --git a/contrib/binutils/bfd/cpu-alpha.c b/contrib/binutils/bfd/cpu-alpha.c
index 93fc69c..c593fc3 100644
--- a/contrib/binutils/bfd/cpu-alpha.c
+++ b/contrib/binutils/bfd/cpu-alpha.c
@@ -1,5 +1,5 @@
/* BFD support for the Alpha architecture.
- Copyright 1992, 1993, 1998, 2000 Free Software Foundation, Inc.
+ Copyright 1992, 1993, 1998, 2000, 2002 Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -39,13 +39,13 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define NN(index) (&arch_info_struct[index])
-/* These exist only so that we can resonably disassemble PALcode. */
+/* These exist only so that we can reasonably disassemble PALcode. */
static const bfd_arch_info_type arch_info_struct[] =
{
- N (64, 64, bfd_mach_alpha_ev4, "alpha:ev4", false, NN(1)),
- N (64, 64, bfd_mach_alpha_ev5, "alpha:ev5", false, NN(2)),
- N (64, 64, bfd_mach_alpha_ev6, "alpha:ev6", false, 0),
+ N (64, 64, bfd_mach_alpha_ev4, "alpha:ev4", FALSE, NN(1)),
+ N (64, 64, bfd_mach_alpha_ev5, "alpha:ev5", FALSE, NN(2)),
+ N (64, 64, bfd_mach_alpha_ev6, "alpha:ev6", FALSE, 0),
};
const bfd_arch_info_type bfd_alpha_arch =
- N (64, 64, 0, "alpha", true, NN(0));
+ N (64, 64, 0, "alpha", TRUE, NN(0));
diff --git a/contrib/binutils/bfd/cpu-arc.c b/contrib/binutils/bfd/cpu-arc.c
index 204eb48..c69df0e 100644
--- a/contrib/binutils/bfd/cpu-arc.c
+++ b/contrib/binutils/bfd/cpu-arc.c
@@ -1,5 +1,5 @@
/* BFD support for the ARC processor
- Copyright 1994, 1995, 1997, 2001 Free Software Foundation, Inc.
+ Copyright 1994, 1995, 1997, 2001, 2002 Free Software Foundation, Inc.
Contributed by Doug Evans (dje@cygnus.com).
This file is part of BFD, the Binary File Descriptor library.
@@ -40,15 +40,15 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
static const bfd_arch_info_type arch_info_struct[] =
{
- ARC ( bfd_mach_arc_5, "arc5", false, &arch_info_struct[1] ),
- ARC ( bfd_mach_arc_5, "base", false, &arch_info_struct[2] ),
- ARC ( bfd_mach_arc_6, "arc6", false, &arch_info_struct[3] ),
- ARC ( bfd_mach_arc_7, "arc7", false, &arch_info_struct[4] ),
- ARC ( bfd_mach_arc_8, "arc8", false, NULL ),
+ ARC ( bfd_mach_arc_5, "arc5", FALSE, &arch_info_struct[1] ),
+ ARC ( bfd_mach_arc_5, "base", FALSE, &arch_info_struct[2] ),
+ ARC ( bfd_mach_arc_6, "arc6", FALSE, &arch_info_struct[3] ),
+ ARC ( bfd_mach_arc_7, "arc7", FALSE, &arch_info_struct[4] ),
+ ARC ( bfd_mach_arc_8, "arc8", FALSE, NULL ),
};
const bfd_arch_info_type bfd_arc_arch =
- ARC ( bfd_mach_arc_6, "arc", true, &arch_info_struct[0] );
+ ARC ( bfd_mach_arc_6, "arc", TRUE, &arch_info_struct[0] );
/* Utility routines. */
diff --git a/contrib/binutils/bfd/cpu-arm.c b/contrib/binutils/bfd/cpu-arm.c
index 9faf648..17889f3 100644
--- a/contrib/binutils/bfd/cpu-arm.c
+++ b/contrib/binutils/bfd/cpu-arm.c
@@ -1,5 +1,5 @@
/* BFD support for the ARM processor
- Copyright 1994, 1997, 1999, 2000, 2002 Free Software Foundation, Inc.
+ Copyright 1994, 1997, 1999, 2000, 2002, 2003 Free Software Foundation, Inc.
Contributed by Richard Earnshaw (rwe@pegasus.esprit.ec.org)
This file is part of BFD, the Binary File Descriptor library.
@@ -21,11 +21,14 @@
#include "bfd.h"
#include "sysdep.h"
#include "libbfd.h"
+#include "libiberty.h"
static const bfd_arch_info_type * compatible
PARAMS ((const bfd_arch_info_type *, const bfd_arch_info_type *));
-static boolean scan
+static bfd_boolean scan
PARAMS ((const struct bfd_arch_info *, const char *));
+static bfd_boolean arm_check_note
+ PARAMS ((bfd *, char *, bfd_size_type, const char *, char **));
/* This routine is provided two arch_infos and works out which ARM
machine which would be compatible with both and returns a pointer
@@ -95,10 +98,12 @@ processors[] =
{ bfd_mach_arm_4, "strongarm"},
{ bfd_mach_arm_4, "strongarm110" },
{ bfd_mach_arm_4, "strongarm1100" },
- { bfd_mach_arm_XScale, "xscale" }
+ { bfd_mach_arm_XScale, "xscale" },
+ { bfd_mach_arm_ep9312, "ep9312" },
+ { bfd_mach_arm_iWMMXt, "iwmmxt" }
};
-static boolean
+static bfd_boolean
scan (info, string)
const struct bfd_arch_info * info;
const char * string;
@@ -107,7 +112,7 @@ scan (info, string)
/* First test for an exact match. */
if (strcasecmp (string, info->printable_name) == 0)
- return true;
+ return TRUE;
/* Next check for a processor name instead of an Architecture name. */
for (i = sizeof (processors) / sizeof (processors[0]); i--;)
@@ -117,13 +122,13 @@ scan (info, string)
}
if (i != -1 && info->mach == processors [i].mach)
- return true;
+ return TRUE;
/* Finally check for the default architecture. */
if (strcasecmp (string, "arm") == 0)
return info->the_default;
- return false;
+ return FALSE;
}
#define N(number, print, default, next) \
@@ -131,17 +136,292 @@ scan (info, string)
static const bfd_arch_info_type arch_info_struct[] =
{
- N (bfd_mach_arm_2, "armv2", false, & arch_info_struct[1]),
- N (bfd_mach_arm_2a, "armv2a", false, & arch_info_struct[2]),
- N (bfd_mach_arm_3, "armv3", false, & arch_info_struct[3]),
- N (bfd_mach_arm_3M, "armv3m", false, & arch_info_struct[4]),
- N (bfd_mach_arm_4, "armv4", false, & arch_info_struct[5]),
- N (bfd_mach_arm_4T, "armv4t", false, & arch_info_struct[6]),
- N (bfd_mach_arm_5, "armv5", false, & arch_info_struct[7]),
- N (bfd_mach_arm_5T, "armv5t", false, & arch_info_struct[8]),
- N (bfd_mach_arm_5TE, "armv5te", false, & arch_info_struct[9]),
- N (bfd_mach_arm_XScale, "xscale", false, NULL)
+ N (bfd_mach_arm_2, "armv2", FALSE, & arch_info_struct[1]),
+ N (bfd_mach_arm_2a, "armv2a", FALSE, & arch_info_struct[2]),
+ N (bfd_mach_arm_3, "armv3", FALSE, & arch_info_struct[3]),
+ N (bfd_mach_arm_3M, "armv3m", FALSE, & arch_info_struct[4]),
+ N (bfd_mach_arm_4, "armv4", FALSE, & arch_info_struct[5]),
+ N (bfd_mach_arm_4T, "armv4t", FALSE, & arch_info_struct[6]),
+ N (bfd_mach_arm_5, "armv5", FALSE, & arch_info_struct[7]),
+ N (bfd_mach_arm_5T, "armv5t", FALSE, & arch_info_struct[8]),
+ N (bfd_mach_arm_5TE, "armv5te", FALSE, & arch_info_struct[9]),
+ N (bfd_mach_arm_XScale, "xscale", FALSE, & arch_info_struct[10]),
+ N (bfd_mach_arm_ep9312, "ep9312", FALSE, & arch_info_struct[11]),
+ N (bfd_mach_arm_iWMMXt,"iwmmxt", FALSE, NULL)
};
const bfd_arch_info_type bfd_arm_arch =
- N (0, "arm", true, & arch_info_struct[0]);
+ N (0, "arm", TRUE, & arch_info_struct[0]);
+
+/* Support functions used by both the COFF and ELF versions of the ARM port. */
+
+/* Handle the merging of the 'machine' settings of input file IBFD
+ and an output file OBFD. These values actually represent the
+ different possible ARM architecture variants.
+ Returns TRUE if they were merged successfully or FALSE otherwise. */
+
+bfd_boolean
+bfd_arm_merge_machines (ibfd, obfd)
+ bfd * ibfd;
+ bfd * obfd;
+{
+ unsigned int in = bfd_get_mach (ibfd);
+ unsigned int out = bfd_get_mach (obfd);
+
+ /* If the output architecture is unknown, we now have a value to set. */
+ if (out == bfd_mach_arm_unknown)
+ bfd_set_arch_mach (obfd, bfd_arch_arm, in);
+
+ /* If the input architecture is unknown,
+ then so must be the output architecture. */
+ else if (in == bfd_mach_arm_unknown)
+ /* FIXME: We ought to have some way to
+ override this on the command line. */
+ bfd_set_arch_mach (obfd, bfd_arch_arm, bfd_mach_arm_unknown);
+
+ /* If they are the same then nothing needs to be done. */
+ else if (out == in)
+ ;
+
+ /* Otherwise the general principle that a earlier architecture can be
+ linked with a later architecture to produce a binary that will execute
+ on the later architecture.
+
+ We fail however if we attempt to link a Cirrus EP9312 binary with an
+ Intel XScale binary, since these architecture have co-processors which
+ will not both be present on the same physical hardware. */
+ else if (in == bfd_mach_arm_ep9312
+ && (out == bfd_mach_arm_XScale || out == bfd_mach_arm_iWMMXt))
+ {
+ _bfd_error_handler (_("\
+ERROR: %s is compiled for the EP9312, whereas %s is compiled for XScale"),
+ bfd_archive_filename (ibfd),
+ bfd_get_filename (obfd));
+ bfd_set_error (bfd_error_wrong_format);
+ return FALSE;
+ }
+ else if (out == bfd_mach_arm_ep9312
+ && (in == bfd_mach_arm_XScale || in == bfd_mach_arm_iWMMXt))
+ {
+ _bfd_error_handler (_("\
+ERROR: %s is compiled for the EP9312, whereas %s is compiled for XScale"),
+ bfd_archive_filename (obfd),
+ bfd_get_filename (ibfd));
+ bfd_set_error (bfd_error_wrong_format);
+ return FALSE;
+ }
+ else if (in > out)
+ bfd_set_arch_mach (obfd, bfd_arch_arm, in);
+ /* else
+ Nothing to do. */
+
+ return TRUE;
+}
+
+typedef struct
+{
+ unsigned char namesz[4]; /* Size of entry's owner string. */
+ unsigned char descsz[4]; /* Size of the note descriptor. */
+ unsigned char type[4]; /* Interpretation of the descriptor. */
+ char name[1]; /* Start of the name+desc data. */
+} arm_Note;
+
+static bfd_boolean
+arm_check_note (abfd, buffer, buffer_size, expected_name, description_return)
+ bfd * abfd;
+ char * buffer;
+ bfd_size_type buffer_size;
+ const char * expected_name;
+ char ** description_return;
+{
+ unsigned long namesz;
+ unsigned long descsz;
+ unsigned long type;
+ char * descr;
+
+ if (buffer_size < offsetof (arm_Note, name))
+ return FALSE;
+
+ /* We have to extract the values this way to allow for a
+ host whose endian-ness is different from the target. */
+ namesz = bfd_get_32 (abfd, buffer);
+ descsz = bfd_get_32 (abfd, buffer + offsetof (arm_Note, descsz));
+ type = bfd_get_32 (abfd, buffer + offsetof (arm_Note, type));
+ descr = buffer + offsetof (arm_Note, name);
+
+ /* Check for buffer overflow. */
+ if (namesz + descsz + offsetof (arm_Note, name) > buffer_size)
+ return FALSE;
+
+ if (expected_name == NULL)
+ {
+ if (namesz != 0)
+ return FALSE;
+ }
+ else
+ {
+ if (namesz != ((strlen (expected_name) + 1 + 3) & ~3))
+ return FALSE;
+
+ if (strcmp (descr, expected_name) != 0)
+ return FALSE;
+
+ descr += (namesz + 3) & ~3;
+ }
+
+ /* FIXME: We should probably check the type as well. */
+
+ if (description_return != NULL)
+ * description_return = descr;
+
+ return TRUE;
+}
+
+#define NOTE_ARCH_STRING "arch: "
+
+bfd_boolean
+bfd_arm_update_notes (abfd, note_section)
+ bfd * abfd;
+ const char * note_section;
+{
+ asection * arm_arch_section;
+ bfd_size_type buffer_size;
+ char * buffer;
+ char * arch_string;
+ char * expected;
+
+ /* Look for a note section. If one is present check the architecture
+ string encoded in it, and set it to the current architecture if it is
+ different. */
+ arm_arch_section = bfd_get_section_by_name (abfd, note_section);
+
+ if (arm_arch_section == NULL)
+ return TRUE;
+
+ buffer_size = arm_arch_section->_raw_size;
+ if (buffer_size == 0)
+ return FALSE;
+
+ buffer = bfd_malloc (buffer_size);
+ if (buffer == NULL)
+ return FALSE;
+
+ if (! bfd_get_section_contents (abfd, arm_arch_section, buffer,
+ (file_ptr) 0, buffer_size))
+ goto FAIL;
+
+ /* Parse the note. */
+ if (! arm_check_note (abfd, buffer, buffer_size, NOTE_ARCH_STRING, & arch_string))
+ goto FAIL;
+
+ /* Check the architecture in the note against the architecture of the bfd. */
+ switch (bfd_get_mach (abfd))
+ {
+ default:
+ case bfd_mach_arm_unknown: expected = "unknown"; break;
+ case bfd_mach_arm_2: expected = "armv2"; break;
+ case bfd_mach_arm_2a: expected = "armv2a"; break;
+ case bfd_mach_arm_3: expected = "armv3"; break;
+ case bfd_mach_arm_3M: expected = "armv3M"; break;
+ case bfd_mach_arm_4: expected = "armv4"; break;
+ case bfd_mach_arm_4T: expected = "armv4t"; break;
+ case bfd_mach_arm_5: expected = "armv5"; break;
+ case bfd_mach_arm_5T: expected = "armv5t"; break;
+ case bfd_mach_arm_5TE: expected = "armv5te"; break;
+ case bfd_mach_arm_XScale: expected = "XScale"; break;
+ case bfd_mach_arm_ep9312: expected = "ep9312"; break;
+ case bfd_mach_arm_iWMMXt: expected = "iWMMXt"; break;
+ }
+
+ if (strcmp (arch_string, expected) != 0)
+ {
+ strcpy (buffer + offsetof (arm_Note, name) + ((strlen (NOTE_ARCH_STRING) + 3) & ~3), expected);
+
+ if (! bfd_set_section_contents (abfd, arm_arch_section, buffer,
+ (file_ptr) 0, buffer_size))
+ {
+ (*_bfd_error_handler)
+ (_("warning: unable to update contents of %s section in %s"),
+ note_section, bfd_get_filename (abfd));
+ goto FAIL;
+ }
+ }
+
+ free (buffer);
+ return TRUE;
+
+ FAIL:
+ free (buffer);
+ return FALSE;
+}
+
+
+static struct
+{
+ const char * string;
+ unsigned int mach;
+}
+architectures[] =
+{
+ { "armv2", bfd_mach_arm_2 },
+ { "armv2a", bfd_mach_arm_2a },
+ { "armv3", bfd_mach_arm_3 },
+ { "armv3M", bfd_mach_arm_3M },
+ { "armv4", bfd_mach_arm_4 },
+ { "armv4t", bfd_mach_arm_4T },
+ { "armv5", bfd_mach_arm_5 },
+ { "armv5t", bfd_mach_arm_5T },
+ { "armv5te", bfd_mach_arm_5TE },
+ { "XScale", bfd_mach_arm_XScale },
+ { "ep9312", bfd_mach_arm_ep9312 },
+ { "iWMMXt", bfd_mach_arm_iWMMXt }
+};
+
+/* Extract the machine number stored in a note section. */
+unsigned int
+bfd_arm_get_mach_from_notes (abfd, note_section)
+ bfd * abfd;
+ const char * note_section;
+{
+ asection * arm_arch_section;
+ bfd_size_type buffer_size;
+ char * buffer;
+ char * arch_string;
+ int i;
+
+ /* Look for a note section. If one is present check the architecture
+ string encoded in it, and set it to the current architecture if it is
+ different. */
+ arm_arch_section = bfd_get_section_by_name (abfd, note_section);
+
+ if (arm_arch_section == NULL)
+ return bfd_mach_arm_unknown;
+
+ buffer_size = arm_arch_section->_raw_size;
+ if (buffer_size == 0)
+ return bfd_mach_arm_unknown;
+
+ buffer = bfd_malloc (buffer_size);
+ if (buffer == NULL)
+ return bfd_mach_arm_unknown;
+
+ if (! bfd_get_section_contents (abfd, arm_arch_section, buffer,
+ (file_ptr) 0, buffer_size))
+ goto FAIL;
+
+ /* Parse the note. */
+ if (! arm_check_note (abfd, buffer, buffer_size, NOTE_ARCH_STRING, & arch_string))
+ goto FAIL;
+
+ /* Interpret the architecture string. */
+ for (i = ARRAY_SIZE (architectures); i--;)
+ if (strcmp (arch_string, architectures[i].string) == 0)
+ {
+ free (buffer);
+ return architectures[i].mach;
+ }
+
+ FAIL:
+ free (buffer);
+ return bfd_mach_arm_unknown;
+}
diff --git a/contrib/binutils/bfd/cpu-i386.c b/contrib/binutils/bfd/cpu-i386.c
index f492827..272c719 100644
--- a/contrib/binutils/bfd/cpu-i386.c
+++ b/contrib/binutils/bfd/cpu-i386.c
@@ -32,7 +32,7 @@ const bfd_arch_info_type bfd_i386_arch_intel_syntax =
"i386:intel",
"i386:intel",
3,
- true,
+ TRUE,
bfd_default_compatible,
bfd_default_scan ,
0,
@@ -47,7 +47,7 @@ const bfd_arch_info_type bfd_x86_64_arch_intel_syntax =
"i386:intel",
"i386:x86-64:intel",
3,
- true,
+ TRUE,
bfd_default_compatible,
bfd_default_scan ,
&bfd_i386_arch_intel_syntax,
@@ -62,7 +62,7 @@ static const bfd_arch_info_type i8086_arch =
"i8086",
"i8086",
3,
- false,
+ FALSE,
bfd_default_compatible,
bfd_default_scan ,
&bfd_x86_64_arch_intel_syntax,
@@ -78,7 +78,7 @@ const bfd_arch_info_type bfd_x86_64_arch =
"i386",
"i386:x86-64",
3,
- true,
+ TRUE,
bfd_default_compatible,
bfd_default_scan ,
&i8086_arch,
@@ -94,7 +94,7 @@ const bfd_arch_info_type bfd_i386_arch =
"i386",
"i386",
3,
- true,
+ TRUE,
bfd_default_compatible,
bfd_default_scan ,
&bfd_x86_64_arch
diff --git a/contrib/binutils/bfd/cpu-ia64-opc.c b/contrib/binutils/bfd/cpu-ia64-opc.c
index a228b1c..740c2ee 100644
--- a/contrib/binutils/bfd/cpu-ia64-opc.c
+++ b/contrib/binutils/bfd/cpu-ia64-opc.c
@@ -1,4 +1,5 @@
-/* Copyright 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+/* Copyright 1998, 1999, 2000, 2001, 2002, 2003
+ Free Software Foundation, Inc.
Contributed by David Mosberger-Tang <davidm@hpl.hp.com>
This file is part of BFD, the Binary File Descriptor library.
@@ -161,8 +162,8 @@ static const char*
ext_imms_scaled (const struct ia64_operand *self, ia64_insn code,
ia64_insn *valuep, int scale)
{
- int i, bits = 0, total = 0, shift;
- BFD_HOST_64_BIT val = 0;
+ int i, bits = 0, total = 0;
+ BFD_HOST_64_BIT val = 0, sign;
for (i = 0; i < NELEMS (self->field) && self->field[i].bits; ++i)
{
@@ -172,8 +173,8 @@ ext_imms_scaled (const struct ia64_operand *self, ia64_insn code,
total += bits;
}
/* sign extend: */
- shift = 8*sizeof (val) - total;
- val = (val << shift) >> shift;
+ sign = (BFD_HOST_64_BIT) 1 << (total - 1);
+ val = (val ^ sign) - sign;
*valuep = (val << scale);
return 0;
@@ -188,10 +189,7 @@ ins_imms (const struct ia64_operand *self, ia64_insn value, ia64_insn *code)
static const char*
ins_immsu4 (const struct ia64_operand *self, ia64_insn value, ia64_insn *code)
{
- if (value == (BFD_HOST_U_64_BIT) 0x100000000)
- value = 0;
- else
- value = (((BFD_HOST_64_BIT)value << 32) >> 32);
+ value = ((value & 0xffffffff) ^ 0x80000000) - 0x80000000;
return ins_imms_scaled (self, value, code, 0);
}
@@ -213,10 +211,7 @@ static const char*
ins_immsm1u4 (const struct ia64_operand *self, ia64_insn value,
ia64_insn *code)
{
- if (value == (BFD_HOST_U_64_BIT) 0x100000000)
- value = 0;
- else
- value = (((BFD_HOST_64_BIT)value << 32) >> 32);
+ value = ((value & 0xffffffff) ^ 0x80000000) - 0x80000000;
--value;
return ins_imms_scaled (self, value, code, 0);
@@ -418,6 +413,7 @@ const struct ia64_operand elf64_ia64_operands[IA64_OPND_COUNT] =
{
/* constants: */
{ CST, ins_const, ext_const, "NIL", {{ 0, 0}}, 0, "<none>" },
+ { CST, ins_const, ext_const, "ar.csd", {{ 0, 0}}, 0, "ar.csd" },
{ CST, ins_const, ext_const, "ar.ccv", {{ 0, 0}}, 0, "ar.ccv" },
{ CST, ins_const, ext_const, "ar.pfs", {{ 0, 0}}, 0, "ar.pfs" },
{ CST, ins_const, ext_const, "1", {{ 0, 0}}, 0, "1" },
@@ -586,4 +582,7 @@ const struct ia64_operand elf64_ia64_operands[IA64_OPND_COUNT] =
"a branch target" },
{ REL, ins_rsvd, ext_rsvd, 0, {{0, 0}}, 0, /* TGT64 */
"a branch target" },
+
+ { ABS, ins_const, ext_const, 0, {{0, 0}}, 0, /* LDXMOV */
+ "ldxmov target" },
};
diff --git a/contrib/binutils/bfd/cpu-ia64.c b/contrib/binutils/bfd/cpu-ia64.c
index 1f36568..2185241 100644
--- a/contrib/binutils/bfd/cpu-ia64.c
+++ b/contrib/binutils/bfd/cpu-ia64.c
@@ -1,5 +1,5 @@
/* BFD support for the ia64 architecture.
- Copyright 1998, 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2002 Free Software Foundation, Inc.
Contributed by David Mosberger-Tang <davidm@hpl.hp.com>
This file is part of BFD, the Binary File Descriptor library.
@@ -32,7 +32,7 @@ const bfd_arch_info_type bfd_ia64_elf32_arch =
"ia64",
"ia64-elf32",
3, /* log2 of section alignment */
- true, /* the one and only */
+ TRUE, /* the one and only */
bfd_default_compatible,
bfd_default_scan ,
0,
@@ -48,7 +48,7 @@ const bfd_arch_info_type bfd_ia64_arch =
"ia64",
"ia64-elf64",
3, /* log2 of section alignment */
- true, /* the one and only */
+ TRUE, /* the one and only */
bfd_default_compatible,
bfd_default_scan ,
&bfd_ia64_elf32_arch,
diff --git a/contrib/binutils/bfd/cpu-powerpc.c b/contrib/binutils/bfd/cpu-powerpc.c
index 5523669..a4e72d5 100644
--- a/contrib/binutils/bfd/cpu-powerpc.c
+++ b/contrib/binutils/bfd/cpu-powerpc.c
@@ -41,7 +41,7 @@ powerpc_compatible (a,b)
case bfd_arch_powerpc:
return bfd_default_compatible (a, b);
case bfd_arch_rs6000:
- if (a->mach == 0)
+ if (b->mach == bfd_mach_rs6k)
return a;
return NULL;
}
@@ -61,7 +61,7 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
"powerpc",
"powerpc:common64",
3,
- true, /* default for 64 bit target */
+ TRUE, /* default for 64 bit target */
powerpc_compatible,
bfd_default_scan,
&bfd_powerpc_archs[1]
@@ -77,7 +77,7 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
"powerpc",
"powerpc:common",
3,
- false,
+ FALSE,
powerpc_compatible,
bfd_default_scan,
&bfd_powerpc_archs[2],
@@ -93,7 +93,7 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
"powerpc",
"powerpc:common",
3,
- true, /* default for 32 bit target */
+ TRUE, /* default for 32 bit target */
powerpc_compatible,
bfd_default_scan,
&bfd_powerpc_archs[1],
@@ -109,7 +109,7 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
"powerpc",
"powerpc:common64",
3,
- false,
+ FALSE,
powerpc_compatible,
bfd_default_scan,
&bfd_powerpc_archs[2]
@@ -124,7 +124,7 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
"powerpc",
"powerpc:603",
3,
- false, /* not the default */
+ FALSE, /* not the default */
powerpc_compatible,
bfd_default_scan,
&bfd_powerpc_archs[3]
@@ -138,7 +138,7 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
"powerpc",
"powerpc:EC603e",
3,
- false, /* not the default */
+ FALSE, /* not the default */
powerpc_compatible,
bfd_default_scan,
&bfd_powerpc_archs[4]
@@ -152,7 +152,7 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
"powerpc",
"powerpc:604",
3,
- false, /* not the default */
+ FALSE, /* not the default */
powerpc_compatible,
bfd_default_scan,
&bfd_powerpc_archs[5]
@@ -166,7 +166,7 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
"powerpc",
"powerpc:403",
3,
- false, /* not the default */
+ FALSE, /* not the default */
powerpc_compatible,
bfd_default_scan,
&bfd_powerpc_archs[6]
@@ -180,7 +180,7 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
"powerpc",
"powerpc:601",
3,
- false, /* not the default */
+ FALSE, /* not the default */
powerpc_compatible,
bfd_default_scan,
&bfd_powerpc_archs[7]
@@ -194,7 +194,7 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
"powerpc",
"powerpc:620",
3,
- false, /* not the default */
+ FALSE, /* not the default */
powerpc_compatible,
bfd_default_scan,
&bfd_powerpc_archs[8]
@@ -208,7 +208,7 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
"powerpc",
"powerpc:630",
3,
- false, /* not the default */
+ FALSE, /* not the default */
powerpc_compatible,
bfd_default_scan,
&bfd_powerpc_archs[9]
@@ -222,7 +222,7 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
"powerpc",
"powerpc:a35",
3,
- false, /* not the default */
+ FALSE, /* not the default */
powerpc_compatible,
bfd_default_scan,
&bfd_powerpc_archs[10]
@@ -236,7 +236,7 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
"powerpc",
"powerpc:rs64ii",
3,
- false, /* not the default */
+ FALSE, /* not the default */
powerpc_compatible,
bfd_default_scan,
&bfd_powerpc_archs[11]
@@ -250,7 +250,7 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
"powerpc",
"powerpc:rs64iii",
3,
- false, /* not the default */
+ FALSE, /* not the default */
powerpc_compatible,
bfd_default_scan,
&bfd_powerpc_archs[12]
@@ -264,12 +264,26 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
"powerpc",
"powerpc:7400",
3,
- false, /* not the default */
+ FALSE, /* not the default */
powerpc_compatible,
bfd_default_scan,
&bfd_powerpc_archs[13]
},
{
+ 32, /* 32 bits in a word */
+ 32, /* 32 bits in an address */
+ 8, /* 8 bits in a byte */
+ bfd_arch_powerpc,
+ bfd_mach_ppc_e500,
+ "powerpc",
+ "powerpc:e500",
+ 3,
+ FALSE,
+ powerpc_compatible,
+ bfd_default_scan,
+ &bfd_powerpc_archs[14]
+ },
+ {
32, /* 32 bits in a word */
32, /* 32 bits in an address */
8, /* 8 bits in a byte */
@@ -278,7 +292,7 @@ const bfd_arch_info_type bfd_powerpc_archs[] =
"powerpc",
"powerpc:MPC8XX",
3,
- false, /* not the default */
+ FALSE, /* not the default */
powerpc_compatible,
bfd_default_scan,
0
diff --git a/contrib/binutils/bfd/cpu-rs6000.c b/contrib/binutils/bfd/cpu-rs6000.c
index 89b9230..d94921f 100644
--- a/contrib/binutils/bfd/cpu-rs6000.c
+++ b/contrib/binutils/bfd/cpu-rs6000.c
@@ -1,5 +1,6 @@
/* BFD back-end for rs6000 support
- Copyright 1990, 1991, 1993, 1995, 2000 Free Software Foundation, Inc.
+ Copyright 1990, 1991, 1993, 1995, 2000, 2002, 2003
+ Free Software Foundation, Inc.
FIXME: Can someone provide a transliteration of this name into ASCII?
Using the following chars caused a compiler warning on HIUX (so I replaced
them with octal escapes), and isn't useful without an understanding of what
@@ -46,7 +47,7 @@ rs6000_compatible (a,b)
case bfd_arch_rs6000:
return bfd_default_compatible (a, b);
case bfd_arch_powerpc:
- if (b->mach == 0)
+ if (a->mach == bfd_mach_rs6k)
return b;
return NULL;
}
@@ -64,7 +65,7 @@ static const bfd_arch_info_type arch_info_struct[] =
"rs6000",
"rs6000:rs1",
3,
- false, /* not the default */
+ FALSE, /* not the default */
rs6000_compatible,
bfd_default_scan,
&arch_info_struct[1]
@@ -78,7 +79,7 @@ static const bfd_arch_info_type arch_info_struct[] =
"rs6000",
"rs6000:rsc",
3,
- false, /* not the default */
+ FALSE, /* not the default */
rs6000_compatible,
bfd_default_scan,
&arch_info_struct[2]
@@ -92,7 +93,7 @@ static const bfd_arch_info_type arch_info_struct[] =
"rs6000",
"rs6000:rs2",
3,
- false, /* not the default */
+ FALSE, /* not the default */
rs6000_compatible,
bfd_default_scan,
0
@@ -109,7 +110,7 @@ const bfd_arch_info_type bfd_rs6000_arch =
"rs6000",
"rs6000:6000",
3,
- true, /* the default */
+ TRUE, /* the default */
rs6000_compatible,
bfd_default_scan,
&arch_info_struct[0]
diff --git a/contrib/binutils/bfd/cpu-s390.c b/contrib/binutils/bfd/cpu-s390.c
index ac0d45e..66fd246 100644
--- a/contrib/binutils/bfd/cpu-s390.c
+++ b/contrib/binutils/bfd/cpu-s390.c
@@ -33,7 +33,7 @@ const bfd_arch_info_type bfd_s390_64_arch =
"s390",
"s390:64-bit",
3, /* section alignment power */
- true, /* the default */
+ TRUE, /* the default */
bfd_default_compatible,
bfd_default_scan,
NULL
@@ -49,7 +49,7 @@ const bfd_arch_info_type bfd_s390_arch =
"s390",
"s390:31-bit",
3, /* section alignment power */
- true, /* the default */
+ TRUE, /* the default */
bfd_default_compatible,
bfd_default_scan,
&bfd_s390_64_arch
diff --git a/contrib/binutils/bfd/cpu-sparc.c b/contrib/binutils/bfd/cpu-sparc.c
index e3b8ecb..3c0eae5 100644
--- a/contrib/binutils/bfd/cpu-sparc.c
+++ b/contrib/binutils/bfd/cpu-sparc.c
@@ -33,7 +33,7 @@ static const bfd_arch_info_type arch_info_struct[] =
"sparc",
"sparc:sparclet",
3,
- false,
+ FALSE,
bfd_default_compatible,
bfd_default_scan,
&arch_info_struct[1],
@@ -47,7 +47,7 @@ static const bfd_arch_info_type arch_info_struct[] =
"sparc",
"sparc:sparclite",
3,
- false,
+ FALSE,
bfd_default_compatible,
bfd_default_scan,
&arch_info_struct[2],
@@ -61,7 +61,7 @@ static const bfd_arch_info_type arch_info_struct[] =
"sparc",
"sparc:v8plus",
3,
- false,
+ FALSE,
bfd_default_compatible,
bfd_default_scan,
&arch_info_struct[3],
@@ -75,7 +75,7 @@ static const bfd_arch_info_type arch_info_struct[] =
"sparc",
"sparc:v8plusa",
3,
- false,
+ FALSE,
bfd_default_compatible,
bfd_default_scan,
&arch_info_struct[4],
@@ -89,7 +89,7 @@ static const bfd_arch_info_type arch_info_struct[] =
"sparc",
"sparc:sparclite_le",
3,
- false,
+ FALSE,
bfd_default_compatible,
bfd_default_scan,
&arch_info_struct[5],
@@ -103,7 +103,7 @@ static const bfd_arch_info_type arch_info_struct[] =
"sparc",
"sparc:v9",
3,
- false,
+ FALSE,
bfd_default_compatible,
bfd_default_scan,
&arch_info_struct[6],
@@ -117,7 +117,7 @@ static const bfd_arch_info_type arch_info_struct[] =
"sparc",
"sparc:v9a",
3,
- false,
+ FALSE,
bfd_default_compatible,
bfd_default_scan,
&arch_info_struct[7],
@@ -131,7 +131,7 @@ static const bfd_arch_info_type arch_info_struct[] =
"sparc",
"sparc:v8plusb",
3,
- false,
+ FALSE,
bfd_default_compatible,
bfd_default_scan,
&arch_info_struct[8],
@@ -145,7 +145,7 @@ static const bfd_arch_info_type arch_info_struct[] =
"sparc",
"sparc:v9b",
3,
- false,
+ FALSE,
bfd_default_compatible,
bfd_default_scan,
0,
@@ -162,7 +162,7 @@ const bfd_arch_info_type bfd_sparc_arch =
"sparc",
"sparc",
3,
- true, /* the default */
+ TRUE, /* the default */
bfd_default_compatible,
bfd_default_scan,
&arch_info_struct[0],
diff --git a/contrib/binutils/bfd/dep-in.sed b/contrib/binutils/bfd/dep-in.sed
index ce8b79b..90a2e6a 100644
--- a/contrib/binutils/bfd/dep-in.sed
+++ b/contrib/binutils/bfd/dep-in.sed
@@ -18,6 +18,7 @@ s! config.h!!g
s! \$(INCDIR)/fopen-[^ ]*\.h!!g
s! \$(INCDIR)/ansidecl\.h!!g
s! \$(INCDIR)/symcat\.h!!g
+s! \.\./intl/libintl\.h!!g
s/\\\n */ /g
diff --git a/contrib/binutils/bfd/doc/ChangeLog b/contrib/binutils/bfd/doc/ChangeLog
index 3d1e30a..fc06933 100644
--- a/contrib/binutils/bfd/doc/ChangeLog
+++ b/contrib/binutils/bfd/doc/ChangeLog
@@ -1,550 +1,14 @@
-2002-09-23 Daniel Jacobowitz <drow@mvista.com>
+2004-04-08 Alan Modra <amodra@bigpond.net.au>
- Merge from mainline:
- 2002-08-28 John David Anglin <dave@hiauly1.hia.nrc.ca>
- * chew.c (paramstuff, outputdots, perform, bang and usage): Remove
- void from function definitions.
-
-2002-08-13 Alan Modra <amodra@bigpond.net.au>
-
- * header.sed: Strip tabs.
-
-2002-06-08 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: Fix quote style in last change.
- * Makefile.in: Regenerate.
-
-2002-06-07 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am (libbfd.h): Don't use "echo -n".
- (libcoff.h, bfd.h): Likewise.
- * Makefile.in: Regenerate.
-
-2002-06-06 Lars Brinkhoff <lars@nocrew.org>
-
- * bfdint.texi: Change registry@sco.com to registry@caldera.com.
-
-2002-06-05 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am (libbfd.h): Add "Extracted from.." comment.
- (libcoff.h, bfd.h): Likewise.
- * Makefile.in: Regenerate.
-
-2002-05-25 Alan Modra <amodra@bigpond.net.au>
-
- * chew.c: Use #include "" instead of <> for local header files.
-
-2002-04-20 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.in: Regenerate.
-
-2002-02-11 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.in: Regenerate.
-
-2002-02-01 Alan Modra <amodra@bigpond.net.au>
-
- * chew.c (WORD): Eliminate.
-
-2002-01-31 Ivan Guzvinec <ivang@opencores.org>
-
- * Makefile.in: Regenerate.
-
-2002-01-31 Alan Modra <amodra@bigpond.net.au>
-
- * chew.c (courierize): Don't modify @command params.
-
-2002-01-30 Nick Clifton <nickc@cambridge.redhat.com>
-
- * proto.str (ENUMDOC): Place two spaces between the end of
- the text and the closing comment marker.
-
-2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
-
- * bfdint.texi (BFD target vector miscellaneous): Add
- bfd_target_mmo_flavour.
- * bfd.texinfo (BFD back ends): Add entry for mmo.
- * Makefile.am (DOCFILES): Add mmo.texi.
- (SRCDOC): Add mmo.c.
- (s-mmo, mmo.texi): New rules.
-
-2001-10-29 Kazu Hirata <kazu@hxi.com>
-
- * bfdsumm.texi: Fix a typo.
-
-2001-10-26 Nick Clifton <nickc@cambridge.redhat.com>
-
- * bfd.texinfo: Change footer to refer to FSF. Change subtitle
- to refer to original creation date.
-
-2002-01-26 Hans-Peter Nilsson <hp@bitrange.com>
-
- * Makefile.am (install): Depend on install-info.
- * Makefile.in: Regenerate.
-
-2001-10-03 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am (BFD_H_DEP): Add ../version.h.
- * Makefile.in: Regenerate.
-
-2001-10-02 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.in: Regenerate.
-
-2001-10-01 Alan Modra <amodra@bigpond.net.au>
-
- * header.sed: New file, adds header to generated files.
- * Makefile.am: Rewrite rules generating libbfd.h, libcoff.h and
- bfd.h, using above. Add missing elf.c dependecy for libbfd.h.
- * Makefile.in: Regenerate.
-
-2001-09-21 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.in: Regenerate.
-
-2001-09-18 Alan Modra <amodra@bigpond.net.au>
-
- * bfdint.texi: Replace reference to bfd_read with bfd_bread.
- Likewise for bfd_write.
-
-2001-07-24 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.in: Regenerate.
-
-2001-06-21 Hans-Peter Nilsson <hp@axis.com>
-
- * bfdint.texi (BFD relocation functions) <different formats>:
- Mention that the GNU linker is aware of input-output format
- restrictions when generating relocatable output. Make new
- paragraph for final-link case.
- (BFD target vector swap): Fix typo.
-
-2001-01-25 Kazu Hirata <kazu@hxi.com>
-
- * chew.c: Do not output trailing whitespaces in type and
- functionname. Update copyright.
-
-2001-01-24 Kazu Hirata <kazu@hxi.com>
-
- * chew.c: Do not output a trailing whitespace.
-
-2000-11-06 Nick Clifton <nickc@redhat.com>
-
- * bfd.texinfo: Add GNU Free Documentation License.
-
-2000-07-09 Alan Modra <alan@linuxcare.com.au>
-
- * Makefile.in: Regenerate.
-
-2000-07-08 Alan Modra <alan@linuxcare.com.au>
-
- * chew.c (outputdots): Don't add a space before `/*'.
- (courierize): Likewise.
-
-Wed May 24 12:03:25 2000 Hans-Peter Nilsson <hp@axis.com>
-
- * bfdint.texi (BFD ELF processor required): Add paragraph about
- target necessities for readelf.
-
-2000-04-30 Ben Elliston <bje@redhat.com>
-
- * bfdint.texi (BFD generated files): Fix another typo.
-
-2000-04-17 Ben Elliston <bje@redhat.com>
-
- * bfdint.texi (BFD_JUMP_TABLE macros): Fix typo.
-
-Fri Apr 7 17:54:38 2000 Andrew Cagney <cagney@b1.cygnus.com>
-
- * Makefile.in: Rebuild with current autoconf/automake.
-
-Thu Feb 4 23:21:36 1999 Ian Lance Taylor <ian@cygnus.com>
-
- * Makefile.in: Rebuild with current autoconf/automake.
-
-Thu Jul 23 09:36:44 1998 Nick Clifton <nickc@cygnus.com>
-
- * bfdint.texi (BFD ELF processor required): Add paragraph
- describing the necessity to create "include/elf/CPU.h".
-
-Thu May 7 14:45:43 1998 Ian Lance Taylor <ian@cygnus.com>
-
- * Makefile.am (chew.o): Add -I options for intl srcdir and
- objdir.
- * Makefile.in: Rebuild.
-
-Mon Apr 27 20:19:24 1998 Ian Lance Taylor <ian@cygnus.com>
-
- * bfdint.texi: New file.
- * Makefile.am (noinst_TEXINFOS): New variable.
- * Makefile.in: Rebuild.
-
-Mon Apr 13 16:48:56 1998 Ian Lance Taylor <ian@cygnus.com>
-
- * Makefile.in: Rebuild.
-
-Mon Apr 6 14:06:55 1998 Ian Lance Taylor <ian@cygnus.com>
-
- * Makefile.am (STAGESTUFF): Remove variable.
- (CLEANFILES): Don't remove $(STAGESTUFF).
- (DISTCLEANFILES, MAINTAINERCLEANFILES): New variables.
- * Makefile.in: Rebuild.
-
-Fri Mar 27 16:25:25 1998 Ian Lance Taylor <ian@cygnus.com>
-
- * chew.c (skip_white_and_starts): Remove unused declaration.
- (skip_white_and_stars): Add casts to avoid warnings.
- (skip_trailing_newlines, paramstuff, courierize): Likewise.
- (bulletize, do_fancy_stuff, iscommand): Likewise.
- (kill_bogus_lines, nextword, main): Likewise.
- (manglecomments): Comment out.
- (outputdots, kill_bogus_lines): Remove unused local variables.
- (perform, compile): Likewise.
- (courierize): Fully parenthesize expression.
- (copy_past_newline): Declare return value.
- (print): Change printf format string.
- (main): Call usage for an unrecognized option.
-
-Fri Feb 13 14:37:14 1998 Ian Lance Taylor <ian@cygnus.com>
-
- * Makefile.am (AUTOMAKE_OPTIONS): Define.
- * Makefile.in: Rebuild.
-
-Mon Jan 26 15:38:36 1998 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
-
- * doc.str (bodytext): Don't output @* at the end.
- * chew.c (kill_bogus_lines): Make sure that a period at the
- beginning is recognized.
- (indent): Don't put indentation at the end.
- (copy_past_newline): Expand tabs.
- * Makefile.am (s-reloc, s-syms): Depend on doc.str.
- * Makefile.in: Rebuild.
-
-Wed Oct 1 14:41:28 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * Makefile.am (libbfd.h): Don't use cpu-h8300.c, cpu-i960.c, or
- elfcode.h as input files; they don't contribute anything.
- * Makefile.in: Rebuild.
-
-Fri Aug 15 04:55:15 1997 Doug Evans <dje@canuck.cygnus.com>
-
- * Makefile.am (libbfd.h, libcoff.h): Invoke $(MKDOC) as ./$(MKDOC).
- * Makefile.in: Rebuild.
-
-Fri Aug 1 12:59:58 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * Makefile.am (CC_FOR_BUILD): Don't set explicitly.
- * Makefile.in: Rebuild.
-
-Thu Jul 31 20:00:12 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * Makefile.am: New file, based on old Makefile.in.
- * Makefile.in: Now built with automake.
-
-Tue Jul 22 14:44:00 1997 Robert Hoehne <robert.hoehne@Mathematik.TU-Chemnitz.DE>
-
- * Makefile.in: Change stamp-* files to s-* files. Use bfdt.texi
- rather than bfd.texi.
- (DOCFILES): Change bfd.texi to bfdt.texi.
- * bfd.texinfo: Include bfdt.texi, not bfd.texi.
-
-Mon Jun 16 15:33:15 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * Makefile.in (CC, CFLAGS): Substitute from configure script.
- From Jeff Makey <jeff@cts.com>.
-
-Tue Apr 15 12:37:41 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * Makefile.in (install-info): Use mkinstalldirs to build
- $(infodir).
-
-Tue Apr 8 12:49:46 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * Makefile.in (install-info): Permit info files to be in srcdir.
- (stamp-*): Add a stamp-X target for each X.texi target.
- (*.texi): Just depend upon stamp-X.
- (clean): Remove stamp-*.
- (distclean): Depend upon mostlyclean. Remove stamp-*. Don't
- remove $(DOCFILES).
-
-Mon Apr 7 15:23:26 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * Makefile.in (distclean): Don't remove *.info files.
-
-Thu Feb 13 20:50:02 1997 Klaus Kaempf (kkaempf@progis.de)
-
- * makefile.vms: New file.
-
-Tue Jun 18 18:32:28 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * chew.c (kill_bogus_lines): Reset sl when not at the start of a
- line. From Uwe Ohse <uwe@tirka.gun.de>.
-
-Tue Jan 30 14:10:46 1996 Ian Lance Taylor <ian@cygnus.com>
-
- From Ronald F. Guilmette <rfg@monkeys.com>:
- * Makefile.in (libbfd.h): Depend upon proto.str.
- (libcoff.h, bfd.h): Likewise.
-
-Fri Nov 3 14:46:48 1995 Fred Fish <fnf@cygnus.com>
-
- * Makefile.in (SRCDOC, SRCPROT, core.texi, bfd.h): Use corefile.c,
- renamed from core.c.
-
-Wed Nov 1 14:28:23 1995 Manfred Hollstein KS/EF4A 60/1F/110 #40283 <manfred@lts.sel.alcatel.de>
-
- * chew.c: Include <ctype.h>.
-
-Fri Oct 6 16:23:34 1995 Ken Raeburn <raeburn@cygnus.com>
-
- Mon Sep 25 22:49:32 1995 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
-
- * Makefile.in (Makefile): Only remake this Makefile.
-
-Wed Oct 4 15:51:05 1995 Ken Raeburn <raeburn@cygnus.com>
-
- * chew.c: Include <stdio.h>.
-
-Tue Sep 12 18:14:50 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * Makefile.in (maintainer-clean): New target.
-
-Thu Aug 31 12:18:43 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * Makefile.in (bfd.h): Add additional #endif at end of bfd.h if
- __cplusplus is defined.
-
-Tue Nov 29 16:13:34 1994 Doug Evans <dje@canuck.cygnus.com>
-
- * chew.c (write_buffer): New argument `f', all callers changed.
- (stdout, stderr, print, drop, idrop): New forth words.
- * proto.str (COMMENT): New command.
- * doc.str (COMMENT): Likewise.
-
-Mon Sep 12 11:44:17 1994 Ian Lance Taylor (ian@sanguine.cygnus.com)
-
- * Makefile.in (DOCFILES): Remove ctor.texi.
- (IPROTOS): Remove ctor.ip.
- (SRCIPROT): Remove $(srcdir)/../ctor.c.
- (ctor.texi): Remove target.
- (libbfd.h): Remove dependency on $(srcdir)/../ctor.c. Remove
- $(MKDOC) run on $(srcdir)/../ctor.c.
- * bfd.texinfo (Constructors): Remove section.
-
-Fri Sep 2 13:33:44 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
-
- * chew.c: Include assert.h. Added prototypes for most functions.
- Changed most uses of int to long. Do bounds checking on the
- stacks. Added comment at the beginning documenting most of the
- intrinsics. Lots of whitespace changes. Re-ordered some
- functions.
- (die, check_range, icheck_range): New functions.
- (strip_trailing_newlines, print_stack_level): New functions.
- (translatecomments): Don't insert tab before "/*".
- (iscommand): Minimum command length is now 4.
- (nextword): Handle some \-sequences.
- (push_addr): Deleted.
- (main): Add new intrinsics strip_trailing_newlines and
- print_stack_level. Complain at end if stack contains more than
- one element, or less.
- (remchar): Make sure the string is not empty before chopping off a
- character.
-
- * doc.str, proto.str: Handle new commands SENUM, ENUM, ENUMX,
- ENUMEQ, ENUMEQX, ENUMDOC.
-
-Wed Jan 12 18:37:12 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * bfd.texinfo: Added Linker Functions node.
- * Makefile.in (DOCFILES): Added linker.texi.
- (SRCDOC): Added linker.c.
- (linker.texi): New target.
-
-Tue Jan 4 10:52:56 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * chew.c: Don't rely on a correct declaration of exit.
- (chew_exit): New function which just calls exit.
- (main): Use it.
-
-Mon Jan 3 11:40:40 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * bfd.texinfo: Added Hash Tables node.
- * Makefile.in (DOCFILES): Added hash.texi.
- (SRCDOC): Added hash.c.
- (hash.texi): New target.
-
-Thu Dec 30 16:57:04 1993 Ken Raeburn (raeburn@cujo.cygnus.com)
-
- * Makefile.in: Delete all references to seclet.c, since it's just
- been deleted. Don't mention hash.c, linker.c, or genlink.h yet,
- since they don't contain documentation yet (hint, hint!).
-
-Fri Nov 5 10:58:53 1993 David J. Mackenzie (djm@thepub.cygnus.com)
-
- * bfd.texinfo: Small cleanups.
-
-Fri Nov 19 03:46:11 1993 Ken Raeburn (raeburn@cambridge.cygnus.com)
-
- * Makefile.in (archures.texi): Depends on $(MKDOC).
-
-Tue Aug 10 14:22:39 1993 Ken Raeburn (raeburn@cambridge.cygnus.com)
-
- * bfd.texinfo (BFD back end): Don't include elfcode.texi, since
- it's empty now and that triggers a makeinfo bug.
-
-Mon Aug 9 16:27:30 1993 Ken Raeburn (raeburn@cambridge.cygnus.com)
-
- * bfd.texinfo (BFD back end): New section on ELF, includes
- elf.texi and elfcode.texi.
- * Makefile.in (DOCFILES): Include elf.texi, elfcode.texi.
- (SRCDOC): Include elfcode.h, elf.c.
- (elf.texi, elfcode.texi): New intermediate targets.
-
-Thu Jun 24 13:48:13 1993 David J. Mackenzie (djm@thepub.cygnus.com)
-
- * Makefile.in (.c.o, chew.o): Put CFLAGS last.
- * bfdsumm.texi: New file, broken out of bfd.texinfo, to share
- with ld.texinfo.
-
-Mon Jun 14 12:07:07 1993 david d `zoo' zuhn (zoo at rtl.cygnus.com)
-
- * Makefile.in (install-info): remove parentdir cruft,
-
-Wed Jun 9 16:00:32 1993 Jim Kingdon (kingdon@cygnus.com)
-
- * Makefile.in (mostlyclean): Remove chew.o.
-
-Tue May 25 14:46:58 1993 Ken Raeburn (raeburn@cambridge.cygnus.com)
-
- * Makefile.in (libbfd.h): Use elfcode.h, not elf32.c.
-
-Mon May 24 15:50:07 1993 Ken Raeburn (raeburn@cygnus.com)
-
- * chew.c (compile): Add a couple of missing casts.
-
-Wed May 12 14:45:14 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * Makefile.in (CC_FOR_BUILD): New variable, define to be $(CC).
- (chew.o, $(MKDOC)): Build using CC_FOR_BUILD rather than CC, since
- it must run on the build machine.
-
-Tue Apr 6 22:38:10 1993 John Gilmore (gnu@cygnus.com)
-
- * Makefile.in (chew): Don't compile from .c to executable in a
- single step; it puts a temporary .o filename into the executable,
- which makes multi-stage comparisons fail. Compile chew.c to
- chew.o, and link that, which makes identical executables every time.
-
-Wed Mar 24 17:26:29 1993 david d `zoo' zuhn (zoo at poseidon.cygnus.com)
-
- * Makefile.in: fix typo (bfd.texinfo not bfd.texino)
-
-Fri Mar 19 01:13:00 1993 Ken Raeburn (raeburn@kr-pc.cygnus.com)
-
- * bfd.texinfo: Since BFD version number has been bumped, do same
- to "version number" on title page, and elsewhere. Should be
- fixed to extract real version number.
-
-Tue Mar 16 12:15:13 1993 Per Bothner (bothner@rtl.cygnus.com)
-
- * Makefile.in: Add *clean rules.
-
-Mon Jan 11 18:43:56 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * Makefile.in (libbfd.h): Removed duplicate init.c and libbfd.c.
- Added seclet.c.
- (bfd.h): Added dependency on bfd.c and seclet.c. Added seclet.c
- to build.
-
-Thu Dec 17 19:35:43 1992 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
-
- * Makefile.in: added dvi target, define and use $(TEXI2DVI)
-
-Thu Dec 3 17:42:48 1992 Ken Raeburn (raeburn@cambridge.cygnus.com)
-
- * Makefile.in (TEXIDIR): New variable.
- (bfd.dvi): Look for bfd.texinfo in $(srcdir). Generate index.
-
- * bfd.texinfo: Minor doc fixes.
-
-Thu Nov 5 03:13:55 1992 John Gilmore (gnu@cygnus.com)
-
- Cleanup: Replace all uses of EXFUN in the BFD sources, with PARAMS.
-
- * chew.c (exfunstuff): Eliminate.
- (paramstuff): Replace exfunstuff with function to generate PARAMS.
- * proto.str: Use paramstuff rather than exfunstuff.
-
-Mon Aug 17 12:40:32 1992 Steve Chamberlain (sac@thepub.cygnus.com)
-
- * chew.c: various patches provided by Howard Chu.
-
-Fri Jun 19 18:59:54 1992 John Gilmore (gnu at cygnus.com)
-
- * Makefile.in (libbfd.h): Add elf.c as a source of prototypes.
-
-Mon May 11 18:55:59 1992 John Gilmore (gnu at cygnus.com)
-
- * chew.c: exit() should be declared by config files, not by
- portable source code. Its type could be int or void function.
-
-Mon May 4 13:45:57 1992 K. Richard Pixley (rich@rtl.cygnus.com)
-
- * Makefile.in: another CFLAGS correction.
-
-Tue Apr 28 10:21:32 1992 K. Richard Pixley (rich@rtl.cygnus.com)
-
- * Makefile.in: Do the CFLAGS thing.
-
-Fri Apr 10 22:34:52 1992 Fred Fish (fnf@cygnus.com)
-
- * Makefile.in (MINUS_G): Add macro and default to -g.
-
-Fri Mar 6 18:53:18 1992 Steve Chamberlain (sac@thepub.cygnus.com)
-
- * chew.c: now has -w switch turn on warnings
-
-Wed Feb 26 18:04:40 1992 K. Richard Pixley (rich@cygnus.com)
-
- * Makefile.in, configure.in: removed traces of namesubdir,
- -subdirs, $(subdir), $(unsubdir), some rcs triggers. Forced
- copyrights to '92, changed some from Cygnus to FSF.
-
-Tue Dec 10 22:11:05 1991 K. Richard Pixley (rich at rtl.cygnus.com)
-
- * Makefile.in: build chew into the current directory. Complete
- the MKDOC macro transition.
-
-Tue Dec 10 08:26:28 1991 Steve Chamberlain (sac at rtl.cygnus.com)
-
- * chew.c: don't core dump when can't open file
- * Makefile.in: get proto.str from the right place when built in
- odd directories
-
-Tue Dec 10 04:07:25 1991 K. Richard Pixley (rich at rtl.cygnus.com)
-
- * Makefile.in: infodir belongs in datadir.
-
-Sat Dec 7 17:01:23 1991 Steve Chamberlain (sac at rtl.cygnus.com)
-
- * chew.c: Much modified
- * proto.str, doc.str: New files for extracting to product
- prototypes and documents respectively.
-
-
-Fri Dec 6 22:57:12 1991 K. Richard Pixley (rich at rtl.cygnus.com)
-
- * Makefile.in: added standards.text support, host/site/target
- inclusion hooks, install using INSTALL_DATA rather than cp,
- don't echo on install.
-
-Thu Dec 5 22:46:17 1991 K. Richard Pixley (rich at rtl.cygnus.com)
-
- * Makefile.in: idestdir and ddestdir go away. Added copyrights
- and shift gpl to v2. Added ChangeLog if it didn't exist. docdir
- and mandir now keyed off datadir by default.
+ Apply from mainline.
+ 2004-03-27 Alan Modra <amodra@bigpond.net.au>
+ * bfdint.texi: Remove all mention of elflink.h.
+For older changes see ChangeLog-9103
Local Variables:
+mode: change-log
+left-margin: 8
+fill-column: 74
version-control: never
End:
diff --git a/contrib/binutils/bfd/doc/ChangeLog-9103 b/contrib/binutils/bfd/doc/ChangeLog-9103
new file mode 100644
index 0000000..3636ed8
--- /dev/null
+++ b/contrib/binutils/bfd/doc/ChangeLog-9103
@@ -0,0 +1,594 @@
+2003-10-15 Andrew Cagney <cagney@redhat.com>
+
+ * bfdint.texi (BFD target vector symbols): Rename _get_symtab to
+ _canonicalize_symtab.
+
+2003-10-08 David Taylor <dtaylor@emc.com>
+
+ * bfd.texinfo: Remove spurious backslash.
+
+2003-07-04 Josh Baratz <baratz@intersystems.com>
+
+ * Makefile.am (MKDOC rule): Add $(CFLAGS) in case it contains
+ CC_FOR_BUILD specific switches.
+ * Makefile.in: Regenerate.
+
+2003-06-29 Alan Modra <amodra@bigpond.net.au>
+
+ * chew.c (paramstuff): Don't emit PARAMS.
+
+2003-02-12 Bob Wilson <bob.wilson@acm.org>
+
+ * bfd.texinfo: Fix quotes for texinfo. Make section title
+ capitalization more consistent. Use @example instead of @lisp.
+ Replace FDL appendix with include of fdl.texi.
+ * fdl.texi: New file.
+
+2002-11-18 Klee Dienes <kdienes@apple.com>
+
+ * Makefile.am (DOCFILES): Add bfdwin.texi, bfdio.texi.
+ (PROTOS): Add bfdio.p, bfdwin.p.
+ (SRCDOC): Add bfdio.c, bfdwin.c.
+ (SRCPROT): Add bfdio.c, bfdwin.c.
+ (SRCIPROT): Add bfdio.c, bfdwin.c.
+ (LIBBFD_H_DEP): Add bfdio.c, bfdwin.c.
+ (BFD_H_DEP): Add bfdio.c, bfdwin.c.
+ Add rules for bfdio.texi, bfdwin.text.
+ * bfd.texinfo: Include bfdio.texi.
+
+2002-10-14 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.in: Regenerate.
+
+2002-10-11 Daniel Jacobowitz <drow@mvista.com>
+
+ * Makefile.in: Regenerated.
+
+2002-08-29 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * chew.c (paramstuff, outputdots, perform, bang and usage): Remove
+ void from function definitions.
+
+2002-08-13 Alan Modra <amodra@bigpond.net.au>
+
+ * header.sed: Strip tabs.
+
+2002-06-08 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Fix quote style in last change.
+ * Makefile.in: Regenerate.
+
+2002-06-07 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (libbfd.h): Don't use "echo -n".
+ (libcoff.h, bfd.h): Likewise.
+ * Makefile.in: Regenerate.
+
+2002-06-06 Lars Brinkhoff <lars@nocrew.org>
+
+ * bfdint.texi: Change registry@sco.com to registry@caldera.com.
+
+2002-06-05 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (libbfd.h): Add "Extracted from.." comment.
+ (libcoff.h, bfd.h): Likewise.
+ * Makefile.in: Regenerate.
+
+2002-05-25 Alan Modra <amodra@bigpond.net.au>
+
+ * chew.c: Use #include "" instead of <> for local header files.
+
+2002-04-20 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.in: Regenerate.
+
+2002-02-11 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.in: Regenerate.
+
+2002-02-01 Alan Modra <amodra@bigpond.net.au>
+
+ * chew.c (WORD): Eliminate.
+
+2002-01-31 Ivan Guzvinec <ivang@opencores.org>
+
+ * Makefile.in: Regenerate.
+
+2002-01-31 Alan Modra <amodra@bigpond.net.au>
+
+ * chew.c (courierize): Don't modify @command params.
+
+2002-01-30 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * proto.str (ENUMDOC): Place two spaces between the end of
+ the text and the closing comment marker.
+
+2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * bfdint.texi (BFD target vector miscellaneous): Add
+ bfd_target_mmo_flavour.
+ * bfd.texinfo (BFD back ends): Add entry for mmo.
+ * Makefile.am (DOCFILES): Add mmo.texi.
+ (SRCDOC): Add mmo.c.
+ (s-mmo, mmo.texi): New rules.
+
+2001-10-29 Kazu Hirata <kazu@hxi.com>
+
+ * bfdsumm.texi: Fix a typo.
+
+2001-10-26 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * bfd.texinfo: Change footer to refer to FSF. Change subtitle
+ to refer to original creation date.
+
+2002-01-26 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * Makefile.am (install): Depend on install-info.
+ * Makefile.in: Regenerate.
+
+2001-10-03 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (BFD_H_DEP): Add ../version.h.
+ * Makefile.in: Regenerate.
+
+2001-10-02 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.in: Regenerate.
+
+2001-10-01 Alan Modra <amodra@bigpond.net.au>
+
+ * header.sed: New file, adds header to generated files.
+ * Makefile.am: Rewrite rules generating libbfd.h, libcoff.h and
+ bfd.h, using above. Add missing elf.c dependecy for libbfd.h.
+ * Makefile.in: Regenerate.
+
+2001-09-21 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.in: Regenerate.
+
+2001-09-18 Alan Modra <amodra@bigpond.net.au>
+
+ * bfdint.texi: Replace reference to bfd_read with bfd_bread.
+ Likewise for bfd_write.
+
+2001-07-24 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.in: Regenerate.
+
+2001-06-21 Hans-Peter Nilsson <hp@axis.com>
+
+ * bfdint.texi (BFD relocation functions) <different formats>:
+ Mention that the GNU linker is aware of input-output format
+ restrictions when generating relocatable output. Make new
+ paragraph for final-link case.
+ (BFD target vector swap): Fix typo.
+
+2001-01-25 Kazu Hirata <kazu@hxi.com>
+
+ * chew.c: Do not output trailing whitespaces in type and
+ functionname. Update copyright.
+
+2001-01-24 Kazu Hirata <kazu@hxi.com>
+
+ * chew.c: Do not output a trailing whitespace.
+
+2000-11-06 Nick Clifton <nickc@redhat.com>
+
+ * bfd.texinfo: Add GNU Free Documentation License.
+
+2000-07-09 Alan Modra <alan@linuxcare.com.au>
+
+ * Makefile.in: Regenerate.
+
+2000-07-08 Alan Modra <alan@linuxcare.com.au>
+
+ * chew.c (outputdots): Don't add a space before `/*'.
+ (courierize): Likewise.
+
+Wed May 24 12:03:25 2000 Hans-Peter Nilsson <hp@axis.com>
+
+ * bfdint.texi (BFD ELF processor required): Add paragraph about
+ target necessities for readelf.
+
+2000-04-30 Ben Elliston <bje@redhat.com>
+
+ * bfdint.texi (BFD generated files): Fix another typo.
+
+2000-04-17 Ben Elliston <bje@redhat.com>
+
+ * bfdint.texi (BFD_JUMP_TABLE macros): Fix typo.
+
+2000-04-07 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * Makefile.in: Rebuild with current autoconf/automake.
+
+1999-02-04 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile.in: Rebuild with current autoconf/automake.
+
+1998-07-23 Nick Clifton <nickc@cygnus.com>
+
+ * bfdint.texi (BFD ELF processor required): Add paragraph
+ describing the necessity to create "include/elf/CPU.h".
+
+1998-05-07 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile.am (chew.o): Add -I options for intl srcdir and
+ objdir.
+ * Makefile.in: Rebuild.
+
+1998-04-27 Ian Lance Taylor <ian@cygnus.com>
+
+ * bfdint.texi: New file.
+ * Makefile.am (noinst_TEXINFOS): New variable.
+ * Makefile.in: Rebuild.
+
+1998-04-13 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile.in: Rebuild.
+
+1998-04-06 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile.am (STAGESTUFF): Remove variable.
+ (CLEANFILES): Don't remove $(STAGESTUFF).
+ (DISTCLEANFILES, MAINTAINERCLEANFILES): New variables.
+ * Makefile.in: Rebuild.
+
+1998-03-27 Ian Lance Taylor <ian@cygnus.com>
+
+ * chew.c (skip_white_and_starts): Remove unused declaration.
+ (skip_white_and_stars): Add casts to avoid warnings.
+ (skip_trailing_newlines, paramstuff, courierize): Likewise.
+ (bulletize, do_fancy_stuff, iscommand): Likewise.
+ (kill_bogus_lines, nextword, main): Likewise.
+ (manglecomments): Comment out.
+ (outputdots, kill_bogus_lines): Remove unused local variables.
+ (perform, compile): Likewise.
+ (courierize): Fully parenthesize expression.
+ (copy_past_newline): Declare return value.
+ (print): Change printf format string.
+ (main): Call usage for an unrecognized option.
+
+1998-02-13 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile.am (AUTOMAKE_OPTIONS): Define.
+ * Makefile.in: Rebuild.
+
+1998-01-26 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
+
+ * doc.str (bodytext): Don't output @* at the end.
+ * chew.c (kill_bogus_lines): Make sure that a period at the
+ beginning is recognized.
+ (indent): Don't put indentation at the end.
+ (copy_past_newline): Expand tabs.
+ * Makefile.am (s-reloc, s-syms): Depend on doc.str.
+ * Makefile.in: Rebuild.
+
+1997-10-01 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile.am (libbfd.h): Don't use cpu-h8300.c, cpu-i960.c, or
+ elfcode.h as input files; they don't contribute anything.
+ * Makefile.in: Rebuild.
+
+1997-08-15 Doug Evans <dje@canuck.cygnus.com>
+
+ * Makefile.am (libbfd.h, libcoff.h): Invoke $(MKDOC) as ./$(MKDOC).
+ * Makefile.in: Rebuild.
+
+1997-08-01 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile.am (CC_FOR_BUILD): Don't set explicitly.
+ * Makefile.in: Rebuild.
+
+1997-07-31 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile.am: New file, based on old Makefile.in.
+ * Makefile.in: Now built with automake.
+
+1997-07-22 Robert Hoehne <robert.hoehne@Mathematik.TU-Chemnitz.DE>
+
+ * Makefile.in: Change stamp-* files to s-* files. Use bfdt.texi
+ rather than bfd.texi.
+ (DOCFILES): Change bfd.texi to bfdt.texi.
+ * bfd.texinfo: Include bfdt.texi, not bfd.texi.
+
+1997-06-16 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile.in (CC, CFLAGS): Substitute from configure script.
+ From Jeff Makey <jeff@cts.com>.
+
+1997-04-15 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile.in (install-info): Use mkinstalldirs to build
+ $(infodir).
+
+1997-04-08 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile.in (install-info): Permit info files to be in srcdir.
+ (stamp-*): Add a stamp-X target for each X.texi target.
+ (*.texi): Just depend upon stamp-X.
+ (clean): Remove stamp-*.
+ (distclean): Depend upon mostlyclean. Remove stamp-*. Don't
+ remove $(DOCFILES).
+
+1997-04-07 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile.in (distclean): Don't remove *.info files.
+
+1997-02-13 Klaus Kaempf (kkaempf@progis.de)
+
+ * makefile.vms: New file.
+
+1996-06-18 Ian Lance Taylor <ian@cygnus.com>
+
+ * chew.c (kill_bogus_lines): Reset sl when not at the start of a
+ line. From Uwe Ohse <uwe@tirka.gun.de>.
+
+1996-01-30 Ian Lance Taylor <ian@cygnus.com>
+
+ From Ronald F. Guilmette <rfg@monkeys.com>:
+ * Makefile.in (libbfd.h): Depend upon proto.str.
+ (libcoff.h, bfd.h): Likewise.
+
+1995-11-03 Fred Fish <fnf@cygnus.com>
+
+ * Makefile.in (SRCDOC, SRCPROT, core.texi, bfd.h): Use corefile.c,
+ renamed from core.c.
+
+1995-11-01 Manfred Hollstein KS/EF4A 60/1F/110 #40283 <manfred@lts.sel.alcatel.de>
+
+ * chew.c: Include <ctype.h>.
+
+1995-10-06 Ken Raeburn <raeburn@cygnus.com>
+
+ Mon Sep 25 22:49:32 1995 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
+
+ * Makefile.in (Makefile): Only remake this Makefile.
+
+1995-10-04 Ken Raeburn <raeburn@cygnus.com>
+
+ * chew.c: Include <stdio.h>.
+
+1995-09-12 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile.in (maintainer-clean): New target.
+
+1995-08-31 Ian Lance Taylor <ian@cygnus.com>
+
+ * Makefile.in (bfd.h): Add additional #endif at end of bfd.h if
+ __cplusplus is defined.
+
+1994-11-29 Doug Evans <dje@canuck.cygnus.com>
+
+ * chew.c (write_buffer): New argument `f', all callers changed.
+ (stdout, stderr, print, drop, idrop): New forth words.
+ * proto.str (COMMENT): New command.
+ * doc.str (COMMENT): Likewise.
+
+1994-09-12 Ian Lance Taylor (ian@sanguine.cygnus.com)
+
+ * Makefile.in (DOCFILES): Remove ctor.texi.
+ (IPROTOS): Remove ctor.ip.
+ (SRCIPROT): Remove $(srcdir)/../ctor.c.
+ (ctor.texi): Remove target.
+ (libbfd.h): Remove dependency on $(srcdir)/../ctor.c. Remove
+ $(MKDOC) run on $(srcdir)/../ctor.c.
+ * bfd.texinfo (Constructors): Remove section.
+
+1994-09-02 Ken Raeburn (raeburn@cujo.cygnus.com)
+
+ * chew.c: Include assert.h. Added prototypes for most functions.
+ Changed most uses of int to long. Do bounds checking on the
+ stacks. Added comment at the beginning documenting most of the
+ intrinsics. Lots of whitespace changes. Re-ordered some
+ functions.
+ (die, check_range, icheck_range): New functions.
+ (strip_trailing_newlines, print_stack_level): New functions.
+ (translatecomments): Don't insert tab before "/*".
+ (iscommand): Minimum command length is now 4.
+ (nextword): Handle some \-sequences.
+ (push_addr): Deleted.
+ (main): Add new intrinsics strip_trailing_newlines and
+ print_stack_level. Complain at end if stack contains more than
+ one element, or less.
+ (remchar): Make sure the string is not empty before chopping off a
+ character.
+
+ * doc.str, proto.str: Handle new commands SENUM, ENUM, ENUMX,
+ ENUMEQ, ENUMEQX, ENUMDOC.
+
+1994-01-12 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * bfd.texinfo: Added Linker Functions node.
+ * Makefile.in (DOCFILES): Added linker.texi.
+ (SRCDOC): Added linker.c.
+ (linker.texi): New target.
+
+1994-01-04 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * chew.c: Don't rely on a correct declaration of exit.
+ (chew_exit): New function which just calls exit.
+ (main): Use it.
+
+1994-01-03 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * bfd.texinfo: Added Hash Tables node.
+ * Makefile.in (DOCFILES): Added hash.texi.
+ (SRCDOC): Added hash.c.
+ (hash.texi): New target.
+
+1993-12-30 Ken Raeburn (raeburn@cujo.cygnus.com)
+
+ * Makefile.in: Delete all references to seclet.c, since it's just
+ been deleted. Don't mention hash.c, linker.c, or genlink.h yet,
+ since they don't contain documentation yet (hint, hint!).
+
+1993-11-05 David J. Mackenzie (djm@thepub.cygnus.com)
+
+ * bfd.texinfo: Small cleanups.
+
+1993-11-19 Ken Raeburn (raeburn@cambridge.cygnus.com)
+
+ * Makefile.in (archures.texi): Depends on $(MKDOC).
+
+1993-08-10 Ken Raeburn (raeburn@cambridge.cygnus.com)
+
+ * bfd.texinfo (BFD back end): Don't include elfcode.texi, since
+ it's empty now and that triggers a makeinfo bug.
+
+1993-08-09 Ken Raeburn (raeburn@cambridge.cygnus.com)
+
+ * bfd.texinfo (BFD back end): New section on ELF, includes
+ elf.texi and elfcode.texi.
+ * Makefile.in (DOCFILES): Include elf.texi, elfcode.texi.
+ (SRCDOC): Include elfcode.h, elf.c.
+ (elf.texi, elfcode.texi): New intermediate targets.
+
+1993-06-24 David J. Mackenzie (djm@thepub.cygnus.com)
+
+ * Makefile.in (.c.o, chew.o): Put CFLAGS last.
+ * bfdsumm.texi: New file, broken out of bfd.texinfo, to share
+ with ld.texinfo.
+
+1993-06-14 david d `zoo' zuhn (zoo at rtl.cygnus.com)
+
+ * Makefile.in (install-info): remove parentdir cruft,
+
+1993-06-09 Jim Kingdon (kingdon@cygnus.com)
+
+ * Makefile.in (mostlyclean): Remove chew.o.
+
+1993-05-25 Ken Raeburn (raeburn@cambridge.cygnus.com)
+
+ * Makefile.in (libbfd.h): Use elfcode.h, not elf32.c.
+
+1993-05-24 Ken Raeburn (raeburn@cygnus.com)
+
+ * chew.c (compile): Add a couple of missing casts.
+
+1993-05-12 Ian Lance Taylor (ian@cygnus.com)
+
+ * Makefile.in (CC_FOR_BUILD): New variable, define to be $(CC).
+ (chew.o, $(MKDOC)): Build using CC_FOR_BUILD rather than CC, since
+ it must run on the build machine.
+
+1993-04-07 John Gilmore (gnu@cygnus.com)
+
+ * Makefile.in (chew): Don't compile from .c to executable in a
+ single step; it puts a temporary .o filename into the executable,
+ which makes multi-stage comparisons fail. Compile chew.c to
+ chew.o, and link that, which makes identical executables every time.
+
+1993-03-24 david d `zoo' zuhn (zoo at poseidon.cygnus.com)
+
+ * Makefile.in: fix typo (bfd.texinfo not bfd.texino)
+
+1993-03-19 Ken Raeburn (raeburn@kr-pc.cygnus.com)
+
+ * bfd.texinfo: Since BFD version number has been bumped, do same
+ to "version number" on title page, and elsewhere. Should be
+ fixed to extract real version number.
+
+1993-03-16 Per Bothner (bothner@rtl.cygnus.com)
+
+ * Makefile.in: Add *clean rules.
+
+1993-01-11 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * Makefile.in (libbfd.h): Removed duplicate init.c and libbfd.c.
+ Added seclet.c.
+ (bfd.h): Added dependency on bfd.c and seclet.c. Added seclet.c
+ to build.
+
+1992-12-17 david d `zoo' zuhn (zoo at cirdan.cygnus.com)
+
+ * Makefile.in: added dvi target, define and use $(TEXI2DVI)
+
+1992-12-03 Ken Raeburn (raeburn@cambridge.cygnus.com)
+
+ * Makefile.in (TEXIDIR): New variable.
+ (bfd.dvi): Look for bfd.texinfo in $(srcdir). Generate index.
+
+ * bfd.texinfo: Minor doc fixes.
+
+1992-11-05 John Gilmore (gnu@cygnus.com)
+
+ Cleanup: Replace all uses of EXFUN in the BFD sources, with PARAMS.
+
+ * chew.c (exfunstuff): Eliminate.
+ (paramstuff): Replace exfunstuff with function to generate PARAMS.
+ * proto.str: Use paramstuff rather than exfunstuff.
+
+1992-08-17 Steve Chamberlain (sac@thepub.cygnus.com)
+
+ * chew.c: various patches provided by Howard Chu.
+
+1992-06-19 John Gilmore (gnu at cygnus.com)
+
+ * Makefile.in (libbfd.h): Add elf.c as a source of prototypes.
+
+1992-05-11 John Gilmore (gnu at cygnus.com)
+
+ * chew.c: exit() should be declared by config files, not by
+ portable source code. Its type could be int or void function.
+
+1992-05-04 K. Richard Pixley (rich@rtl.cygnus.com)
+
+ * Makefile.in: another CFLAGS correction.
+
+1992-04-28 K. Richard Pixley (rich@rtl.cygnus.com)
+
+ * Makefile.in: Do the CFLAGS thing.
+
+1992-04-11 Fred Fish (fnf@cygnus.com)
+
+ * Makefile.in (MINUS_G): Add macro and default to -g.
+
+1992-03-06 Steve Chamberlain (sac@thepub.cygnus.com)
+
+ * chew.c: now has -w switch turn on warnings
+
+1992-02-26 K. Richard Pixley (rich@cygnus.com)
+
+ * Makefile.in, configure.in: removed traces of namesubdir,
+ -subdirs, $(subdir), $(unsubdir), some rcs triggers. Forced
+ copyrights to '92, changed some from Cygnus to FSF.
+
+1991-12-10 K. Richard Pixley (rich at rtl.cygnus.com)
+
+ * Makefile.in: build chew into the current directory. Complete
+ the MKDOC macro transition.
+
+1991-12-10 Steve Chamberlain (sac at rtl.cygnus.com)
+
+ * chew.c: don't core dump when can't open file
+ * Makefile.in: get proto.str from the right place when built in
+ odd directories
+
+1991-12-10 K. Richard Pixley (rich at rtl.cygnus.com)
+
+ * Makefile.in: infodir belongs in datadir.
+
+1991-12-07 Steve Chamberlain (sac at rtl.cygnus.com)
+
+ * chew.c: Much modified
+ * proto.str, doc.str: New files for extracting to product
+ prototypes and documents respectively.
+
+
+1991-12-06 K. Richard Pixley (rich at rtl.cygnus.com)
+
+ * Makefile.in: added standards.text support, host/site/target
+ inclusion hooks, install using INSTALL_DATA rather than cp,
+ don't echo on install.
+
+1991-12-05 K. Richard Pixley (rich at rtl.cygnus.com)
+
+ * Makefile.in: idestdir and ddestdir go away. Added copyrights
+ and shift gpl to v2. Added ChangeLog if it didn't exist. docdir
+ and mandir now keyed off datadir by default.
+
+
+Local Variables:
+version-control: never
+End:
diff --git a/contrib/binutils/bfd/doc/Makefile.am b/contrib/binutils/bfd/doc/Makefile.am
index 0787143..4aaa341 100644
--- a/contrib/binutils/bfd/doc/Makefile.am
+++ b/contrib/binutils/bfd/doc/Makefile.am
@@ -4,13 +4,15 @@ AUTOMAKE_OPTIONS = cygnus
DOCFILES = aoutx.texi archive.texi archures.texi \
bfdt.texi cache.texi coffcode.texi \
- core.texi elf.texi elfcode.texi format.texi libbfd.texi \
+ core.texi elf.texi elfcode.texi format.texi \
+ libbfd.texi bfdwin.texi bfdio.texi \
opncls.texi reloc.texi section.texi \
syms.texi targets.texi init.texi hash.texi linker.texi \
mmo.texi
PROTOS = archive.p archures.p bfd.p \
core.p format.p \
+ bfdio.p bfdwin.p \
libbfd.p opncls.p reloc.p \
section.p syms.p targets.p \
format.p core.p init.p
@@ -22,6 +24,7 @@ IPROTOS = cache.ip libbfd.ip reloc.ip init.ip archures.ip coffcode.ip
# you don't need these three:
SRCDOC = $(srcdir)/../aoutx.h $(srcdir)/../archive.c \
$(srcdir)/../archures.c $(srcdir)/../bfd.c \
+ $(srcdir)/../bfdio.c $(srcdir)/../bfdwin.c \
$(srcdir)/../cache.c $(srcdir)/../coffcode.h \
$(srcdir)/../corefile.c $(srcdir)/../elf.c \
$(srcdir)/../elfcode.h $(srcdir)/../format.c \
@@ -34,11 +37,13 @@ SRCDOC = $(srcdir)/../aoutx.h $(srcdir)/../archive.c \
SRCPROT = $(srcdir)/../archive.c $(srcdir)/../archures.c \
$(srcdir)/../bfd.c $(srcdir)/../coffcode.h $(srcdir)/../corefile.c \
$(srcdir)/../format.c $(srcdir)/../libbfd.c \
+ $(srcdir)/../bfdio.c $(srcdir)/../bfdwin.c \
$(srcdir)/../opncls.c $(srcdir)/../reloc.c \
$(srcdir)/../section.c $(srcdir)/../syms.c \
$(srcdir)/../targets.c $(srcdir)/../init.c
SRCIPROT = $(srcdir)/../cache.c $(srcdir)/../libbfd.c \
+ $(srcdir)/../bfdio.c $(srcdir)/../bfdwin.c \
$(srcdir)/../reloc.c $(srcdir)/../cpu-h8300.c \
$(srcdir)/../cpu-i960.c $(srcdir)/../archures.c \
$(srcdir)/../init.c
@@ -50,7 +55,7 @@ info_TEXINFOS = bfd.texinfo
MKDOC = chew$(EXEEXT_FOR_BUILD)
$(MKDOC): chew.o
- $(CC_FOR_BUILD) -o $(MKDOC) chew.o $(LOADLIBES) $(LDFLAGS)
+ $(CC_FOR_BUILD) -o $(MKDOC) chew.o $(CFLAGS) $(LOADLIBES) $(LDFLAGS)
chew.o: chew.c
$(CC_FOR_BUILD) -c -I.. -I$(srcdir)/.. -I$(srcdir)/../../include -I$(srcdir)/../../intl -I../../intl $(H_CFLAGS) $(CFLAGS) $(srcdir)/chew.c
@@ -143,6 +148,18 @@ s-libbfd: $(MKDOC) $(srcdir)/../libbfd.c $(srcdir)/doc.str
touch s-libbfd
libbfd.texi: s-libbfd
+s-bfdio: $(MKDOC) $(srcdir)/../bfdio.c $(srcdir)/doc.str
+ ./$(MKDOC) -f $(srcdir)/doc.str < $(srcdir)/../bfdio.c >bfdio.tmp
+ $(srcdir)/../../move-if-change bfdio.tmp bfdio.texi
+ touch s-bfdio
+bfdio.texi: s-bfdio
+
+s-bfdwin: $(MKDOC) $(srcdir)/../bfdwin.c $(srcdir)/doc.str
+ ./$(MKDOC) -f $(srcdir)/doc.str < $(srcdir)/../bfdwin.c >bfdwin.tmp
+ $(srcdir)/../../move-if-change bfdwin.tmp bfdwin.texi
+ touch s-bfdwin
+bfdwin.texi: s-bfdwin
+
s-opncls: $(MKDOC) $(srcdir)/../opncls.c $(srcdir)/doc.str
./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../opncls.c >opncls.tmp
$(srcdir)/../../move-if-change opncls.tmp opncls.texi
@@ -195,6 +212,8 @@ LIBBFD_H_DEP = \
$(srcdir)/../libbfd-in.h \
$(srcdir)/../init.c \
$(srcdir)/../libbfd.c \
+ $(srcdir)/../bfdio.c \
+ $(srcdir)/../bfdwin.c \
$(srcdir)/../cache.c \
$(srcdir)/../reloc.c \
$(srcdir)/../archures.c \
@@ -239,6 +258,8 @@ BFD_H_DEP = \
$(srcdir)/../init.c \
$(srcdir)/../opncls.c \
$(srcdir)/../libbfd.c \
+ $(srcdir)/../bfdio.c \
+ $(srcdir)/../bfdwin.c \
$(srcdir)/../section.c \
$(srcdir)/../archures.c \
$(srcdir)/../reloc.c \
@@ -248,6 +269,8 @@ BFD_H_DEP = \
$(srcdir)/../corefile.c \
$(srcdir)/../targets.c \
$(srcdir)/../format.c \
+ $(srcdir)/../linker.c \
+ $(srcdir)/../simple.c \
$(srcdir)/header.sed \
$(srcdir)/proto.str \
$(srcdir)/../version.h \
diff --git a/contrib/binutils/bfd/doc/Makefile.in b/contrib/binutils/bfd/doc/Makefile.in
index f35cc9a..85d6427 100644
--- a/contrib/binutils/bfd/doc/Makefile.in
+++ b/contrib/binutils/bfd/doc/Makefile.in
@@ -1,6 +1,6 @@
-# Makefile.in generated automatically by automake 1.4 from Makefile.am
+# Makefile.in generated automatically by automake 1.4-p6 from Makefile.am
-# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
+# Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
@@ -68,6 +68,7 @@ AS = @AS@
BFD_HOST_64BIT_LONG = @BFD_HOST_64BIT_LONG@
BFD_HOST_64_BIT = @BFD_HOST_64_BIT@
BFD_HOST_64_BIT_DEFINED = @BFD_HOST_64_BIT_DEFINED@
+BFD_HOST_LONG_LONG = @BFD_HOST_LONG_LONG@
BFD_HOST_U_64_BIT = @BFD_HOST_U_64_BIT@
CATALOGS = @CATALOGS@
CATOBJEXT = @CATOBJEXT@
@@ -116,10 +117,11 @@ WIN32LIBADD = @WIN32LIBADD@
all_backends = @all_backends@
bfd_backends = @bfd_backends@
bfd_default_target_size = @bfd_default_target_size@
+bfd_file_ptr = @bfd_file_ptr@
bfd_libs = @bfd_libs@
bfd_machines = @bfd_machines@
+bfd_ufile_ptr = @bfd_ufile_ptr@
bfd_version = @bfd_version@
-bfd_version_date = @bfd_version_date@
bfd_version_string = @bfd_version_string@
bfdincludedir = @bfdincludedir@
bfdlibdir = @bfdlibdir@
@@ -131,7 +133,8 @@ AUTOMAKE_OPTIONS = cygnus
DOCFILES = aoutx.texi archive.texi archures.texi \
bfdt.texi cache.texi coffcode.texi \
- core.texi elf.texi elfcode.texi format.texi libbfd.texi \
+ core.texi elf.texi elfcode.texi format.texi \
+ libbfd.texi bfdwin.texi bfdio.texi \
opncls.texi reloc.texi section.texi \
syms.texi targets.texi init.texi hash.texi linker.texi \
mmo.texi
@@ -139,6 +142,7 @@ DOCFILES = aoutx.texi archive.texi archures.texi \
PROTOS = archive.p archures.p bfd.p \
core.p format.p \
+ bfdio.p bfdwin.p \
libbfd.p opncls.p reloc.p \
section.p syms.p targets.p \
format.p core.p init.p
@@ -151,6 +155,7 @@ IPROTOS = cache.ip libbfd.ip reloc.ip init.ip archures.ip coffcode.ip
# you don't need these three:
SRCDOC = $(srcdir)/../aoutx.h $(srcdir)/../archive.c \
$(srcdir)/../archures.c $(srcdir)/../bfd.c \
+ $(srcdir)/../bfdio.c $(srcdir)/../bfdwin.c \
$(srcdir)/../cache.c $(srcdir)/../coffcode.h \
$(srcdir)/../corefile.c $(srcdir)/../elf.c \
$(srcdir)/../elfcode.h $(srcdir)/../format.c \
@@ -164,12 +169,14 @@ SRCDOC = $(srcdir)/../aoutx.h $(srcdir)/../archive.c \
SRCPROT = $(srcdir)/../archive.c $(srcdir)/../archures.c \
$(srcdir)/../bfd.c $(srcdir)/../coffcode.h $(srcdir)/../corefile.c \
$(srcdir)/../format.c $(srcdir)/../libbfd.c \
+ $(srcdir)/../bfdio.c $(srcdir)/../bfdwin.c \
$(srcdir)/../opncls.c $(srcdir)/../reloc.c \
$(srcdir)/../section.c $(srcdir)/../syms.c \
$(srcdir)/../targets.c $(srcdir)/../init.c
SRCIPROT = $(srcdir)/../cache.c $(srcdir)/../libbfd.c \
+ $(srcdir)/../bfdio.c $(srcdir)/../bfdwin.c \
$(srcdir)/../reloc.c $(srcdir)/../cpu-h8300.c \
$(srcdir)/../cpu-i960.c $(srcdir)/../archures.c \
$(srcdir)/../init.c
@@ -185,6 +192,8 @@ LIBBFD_H_DEP = \
$(srcdir)/../libbfd-in.h \
$(srcdir)/../init.c \
$(srcdir)/../libbfd.c \
+ $(srcdir)/../bfdio.c \
+ $(srcdir)/../bfdwin.c \
$(srcdir)/../cache.c \
$(srcdir)/../reloc.c \
$(srcdir)/../archures.c \
@@ -207,6 +216,8 @@ BFD_H_DEP = \
$(srcdir)/../init.c \
$(srcdir)/../opncls.c \
$(srcdir)/../libbfd.c \
+ $(srcdir)/../bfdio.c \
+ $(srcdir)/../bfdwin.c \
$(srcdir)/../section.c \
$(srcdir)/../archures.c \
$(srcdir)/../reloc.c \
@@ -216,6 +227,8 @@ BFD_H_DEP = \
$(srcdir)/../corefile.c \
$(srcdir)/../targets.c \
$(srcdir)/../format.c \
+ $(srcdir)/../linker.c \
+ $(srcdir)/../simple.c \
$(srcdir)/header.sed \
$(srcdir)/proto.str \
$(srcdir)/../version.h \
@@ -330,7 +343,7 @@ uninstall-info:
else ii=; fi; \
list='$(INFO_DEPS)'; \
for file in $$list; do \
- test -z "$ii" \
+ test -z "$$ii" \
|| install-info --info-dir=$(DESTDIR)$(infodir) --remove $$file; \
done
@$(NORMAL_UNINSTALL)
@@ -459,7 +472,7 @@ mostlyclean distclean maintainer-clean
$(MKDOC): chew.o
- $(CC_FOR_BUILD) -o $(MKDOC) chew.o $(LOADLIBES) $(LDFLAGS)
+ $(CC_FOR_BUILD) -o $(MKDOC) chew.o $(CFLAGS) $(LOADLIBES) $(LDFLAGS)
chew.o: chew.c
$(CC_FOR_BUILD) -c -I.. -I$(srcdir)/.. -I$(srcdir)/../../include -I$(srcdir)/../../intl -I../../intl $(H_CFLAGS) $(CFLAGS) $(srcdir)/chew.c
@@ -552,6 +565,18 @@ s-libbfd: $(MKDOC) $(srcdir)/../libbfd.c $(srcdir)/doc.str
touch s-libbfd
libbfd.texi: s-libbfd
+s-bfdio: $(MKDOC) $(srcdir)/../bfdio.c $(srcdir)/doc.str
+ ./$(MKDOC) -f $(srcdir)/doc.str < $(srcdir)/../bfdio.c >bfdio.tmp
+ $(srcdir)/../../move-if-change bfdio.tmp bfdio.texi
+ touch s-bfdio
+bfdio.texi: s-bfdio
+
+s-bfdwin: $(MKDOC) $(srcdir)/../bfdwin.c $(srcdir)/doc.str
+ ./$(MKDOC) -f $(srcdir)/doc.str < $(srcdir)/../bfdwin.c >bfdwin.tmp
+ $(srcdir)/../../move-if-change bfdwin.tmp bfdwin.texi
+ touch s-bfdwin
+bfdwin.texi: s-bfdwin
+
s-opncls: $(MKDOC) $(srcdir)/../opncls.c $(srcdir)/doc.str
./$(MKDOC) -f $(srcdir)/doc.str <$(srcdir)/../opncls.c >opncls.tmp
$(srcdir)/../../move-if-change opncls.tmp opncls.texi
diff --git a/contrib/binutils/bfd/doc/aoutx.texi b/contrib/binutils/bfd/doc/aoutx.texi
index d99fd05..0c4167b 100644
--- a/contrib/binutils/bfd/doc/aoutx.texi
+++ b/contrib/binutils/bfd/doc/aoutx.texi
@@ -161,7 +161,7 @@ handle any last-minute setup.
@subsubsection @code{aout_@var{size}_mkobject}
@strong{Synopsis}
@example
-boolean aout_@var{size}_mkobject, (bfd *abfd);
+bfd_boolean aout_@var{size}_mkobject, (bfd *abfd);
@end example
@strong{Description}@*
Initialize BFD @var{abfd} for use with a.out files.
@@ -187,7 +187,7 @@ is always understood.
@subsubsection @code{aout_@var{size}_set_arch_mach}
@strong{Synopsis}
@example
-boolean aout_@var{size}_set_arch_mach,
+bfd_boolean aout_@var{size}_set_arch_mach,
(bfd *,
enum bfd_architecture arch,
unsigned long machine));
@@ -201,7 +201,7 @@ can support the architecture required.
@subsubsection @code{aout_@var{size}_new_section_hook}
@strong{Synopsis}
@example
-boolean aout_@var{size}_new_section_hook,
+bfd_boolean aout_@var{size}_new_section_hook,
(bfd *abfd,
asection *newsect));
@end example
diff --git a/contrib/binutils/bfd/doc/archive.texi b/contrib/binutils/bfd/doc/archive.texi
index 7e91a16..e20906a 100644
--- a/contrib/binutils/bfd/doc/archive.texi
+++ b/contrib/binutils/bfd/doc/archive.texi
@@ -54,7 +54,8 @@ Archives are supported in BFD in @code{archive.c}.
@subsubsection @code{bfd_get_next_mapent}
@strong{Synopsis}
@example
-symindex bfd_get_next_mapent(bfd *abfd, symindex previous, carsym **sym);
+symindex bfd_get_next_mapent
+ (bfd *abfd, symindex previous, carsym **sym);
@end example
@strong{Description}@*
Step through archive @var{abfd}'s symbol table (if it
@@ -73,7 +74,7 @@ user-visible element is its name, a null-terminated string.
@subsubsection @code{bfd_set_archive_head}
@strong{Synopsis}
@example
-boolean bfd_set_archive_head(bfd *output, bfd *new_head);
+bfd_boolean bfd_set_archive_head (bfd *output, bfd *new_head);
@end example
@strong{Description}@*
Set the head of the chain of
@@ -83,7 +84,7 @@ BFDs contained in the archive @var{output} to @var{new_head}.
@subsubsection @code{bfd_openr_next_archived_file}
@strong{Synopsis}
@example
-bfd *bfd_openr_next_archived_file(bfd *archive, bfd *previous);
+bfd *bfd_openr_next_archived_file (bfd *archive, bfd *previous);
@end example
@strong{Description}@*
Provided a BFD, @var{archive}, containing an archive and NULL, open
diff --git a/contrib/binutils/bfd/doc/archures.texi b/contrib/binutils/bfd/doc/archures.texi
index 0faf97d..06ee6d3 100644
--- a/contrib/binutils/bfd/doc/archures.texi
+++ b/contrib/binutils/bfd/doc/archures.texi
@@ -50,6 +50,7 @@ enum bfd_architecture
#define bfd_mach_mcf5206e 10
#define bfd_mach_mcf5307 11
#define bfd_mach_mcf5407 12
+#define bfd_mach_mcf528x 13
bfd_arch_vax, /* DEC Vax */
bfd_arch_i960, /* Intel 960 */
/* The order of the following is important.
@@ -95,12 +96,16 @@ enum bfd_architecture
#define bfd_mach_mips4010 4010
#define bfd_mach_mips4100 4100
#define bfd_mach_mips4111 4111
+#define bfd_mach_mips4120 4120
#define bfd_mach_mips4300 4300
#define bfd_mach_mips4400 4400
#define bfd_mach_mips4600 4600
#define bfd_mach_mips4650 4650
#define bfd_mach_mips5000 5000
+#define bfd_mach_mips5400 5400
+#define bfd_mach_mips5500 5500
#define bfd_mach_mips6000 6000
+#define bfd_mach_mips7000 7000
#define bfd_mach_mips8000 8000
#define bfd_mach_mips10000 10000
#define bfd_mach_mips12000 12000
@@ -108,13 +113,15 @@ enum bfd_architecture
#define bfd_mach_mips5 5
#define bfd_mach_mips_sb1 12310201 /* octal 'SB', 01 */
#define bfd_mach_mipsisa32 32
+#define bfd_mach_mipsisa32r2 33
#define bfd_mach_mipsisa64 64
+#define bfd_mach_mipsisa64r2 65
bfd_arch_i386, /* Intel 386 */
-#define bfd_mach_i386_i386 0
-#define bfd_mach_i386_i8086 1
-#define bfd_mach_i386_i386_intel_syntax 2
-#define bfd_mach_x86_64 3
-#define bfd_mach_x86_64_intel_syntax 4
+#define bfd_mach_i386_i386 1
+#define bfd_mach_i386_i8086 2
+#define bfd_mach_i386_i386_intel_syntax 3
+#define bfd_mach_x86_64 64
+#define bfd_mach_x86_64_intel_syntax 65
bfd_arch_we32k, /* AT&T WE32xxx */
bfd_arch_tahoe, /* CCI/Harris Tahoe */
bfd_arch_i860, /* Intel 860 */
@@ -123,15 +130,20 @@ enum bfd_architecture
bfd_arch_alliant, /* Alliant */
bfd_arch_convex, /* Convex */
bfd_arch_m88k, /* Motorola 88xxx */
+ bfd_arch_m98k, /* Motorola 98xxx */
bfd_arch_pyramid, /* Pyramid Technology */
- bfd_arch_h8300, /* Hitachi H8/300 */
-#define bfd_mach_h8300 1
-#define bfd_mach_h8300h 2
-#define bfd_mach_h8300s 3
+ bfd_arch_h8300, /* Renesas H8/300 (formerly Hitachi H8/300) */
+#define bfd_mach_h8300 1
+#define bfd_mach_h8300h 2
+#define bfd_mach_h8300s 3
+#define bfd_mach_h8300hn 4
+#define bfd_mach_h8300sn 5
+#define bfd_mach_h8300sx 6
+#define bfd_mach_h8300sxn 7
bfd_arch_pdp11, /* DEC PDP-11 */
bfd_arch_powerpc, /* PowerPC */
-#define bfd_mach_ppc 0
-#define bfd_mach_ppc64 1
+#define bfd_mach_ppc 32
+#define bfd_mach_ppc64 64
#define bfd_mach_ppc_403 403
#define bfd_mach_ppc_403gc 4030
#define bfd_mach_ppc_505 505
@@ -148,38 +160,52 @@ enum bfd_architecture
#define bfd_mach_ppc_rs64ii 642
#define bfd_mach_ppc_rs64iii 643
#define bfd_mach_ppc_7400 7400
+#define bfd_mach_ppc_e500 500
bfd_arch_rs6000, /* IBM RS/6000 */
-#define bfd_mach_rs6k 0
+#define bfd_mach_rs6k 6000
#define bfd_mach_rs6k_rs1 6001
#define bfd_mach_rs6k_rsc 6003
#define bfd_mach_rs6k_rs2 6002
bfd_arch_hppa, /* HP PA RISC */
+#define bfd_mach_hppa10 10
+#define bfd_mach_hppa11 11
+#define bfd_mach_hppa20 20
+#define bfd_mach_hppa20w 25
bfd_arch_d10v, /* Mitsubishi D10V */
-#define bfd_mach_d10v 0
+#define bfd_mach_d10v 1
#define bfd_mach_d10v_ts2 2
#define bfd_mach_d10v_ts3 3
bfd_arch_d30v, /* Mitsubishi D30V */
bfd_arch_dlx, /* DLX */
bfd_arch_m68hc11, /* Motorola 68HC11 */
bfd_arch_m68hc12, /* Motorola 68HC12 */
+#define bfd_mach_m6812_default 0
+#define bfd_mach_m6812 1
+#define bfd_mach_m6812s 2
bfd_arch_z8k, /* Zilog Z8000 */
#define bfd_mach_z8001 1
#define bfd_mach_z8002 2
- bfd_arch_h8500, /* Hitachi H8/500 */
- bfd_arch_sh, /* Hitachi SH */
-#define bfd_mach_sh 0
+ bfd_arch_h8500, /* Renesas H8/500 (formerly Hitachi H8/500) */
+ bfd_arch_sh, /* Renesas / SuperH SH (formerly Hitachi SH) */
+#define bfd_mach_sh 1
#define bfd_mach_sh2 0x20
#define bfd_mach_sh_dsp 0x2d
+#define bfd_mach_sh2e 0x2e
#define bfd_mach_sh3 0x30
#define bfd_mach_sh3_dsp 0x3d
#define bfd_mach_sh3e 0x3e
#define bfd_mach_sh4 0x40
+#define bfd_mach_sh4_nofpu 0x41
+#define bfd_mach_sh4a 0x4a
+#define bfd_mach_sh4a_nofpu 0x4b
+#define bfd_mach_sh4al_dsp 0x4d
#define bfd_mach_sh5 0x50
bfd_arch_alpha, /* Dec Alpha */
#define bfd_mach_alpha_ev4 0x10
#define bfd_mach_alpha_ev5 0x20
#define bfd_mach_alpha_ev6 0x30
bfd_arch_arm, /* Advanced Risc Machines ARM. */
+#define bfd_mach_arm_unknown 0
#define bfd_mach_arm_2 1
#define bfd_mach_arm_2a 2
#define bfd_mach_arm_3 3
@@ -190,40 +216,54 @@ enum bfd_architecture
#define bfd_mach_arm_5T 8
#define bfd_mach_arm_5TE 9
#define bfd_mach_arm_XScale 10
+#define bfd_mach_arm_ep9312 11
+#define bfd_mach_arm_iWMMXt 12
bfd_arch_ns32k, /* National Semiconductors ns32000 */
bfd_arch_w65, /* WDC 65816 */
bfd_arch_tic30, /* Texas Instruments TMS320C30 */
+ bfd_arch_tic4x, /* Texas Instruments TMS320C3X/4X */
+#define bfd_mach_tic3x 30
+#define bfd_mach_tic4x 40
bfd_arch_tic54x, /* Texas Instruments TMS320C54X */
bfd_arch_tic80, /* TI TMS320c80 (MVP) */
bfd_arch_v850, /* NEC V850 */
-#define bfd_mach_v850 0
+#define bfd_mach_v850 1
#define bfd_mach_v850e 'E'
-#define bfd_mach_v850ea 'A'
+#define bfd_mach_v850e1 '1'
bfd_arch_arc, /* ARC Cores */
-#define bfd_mach_arc_5 0
-#define bfd_mach_arc_6 1
-#define bfd_mach_arc_7 2
-#define bfd_mach_arc_8 3
- bfd_arch_m32r, /* Mitsubishi M32R/D */
-#define bfd_mach_m32r 0 /* For backwards compatibility. */
+#define bfd_mach_arc_5 5
+#define bfd_mach_arc_6 6
+#define bfd_mach_arc_7 7
+#define bfd_mach_arc_8 8
+ bfd_arch_m32r, /* Renesas M32R (formerly Mitsubishi M32R/D) */
+#define bfd_mach_m32r 1 /* For backwards compatibility. */
#define bfd_mach_m32rx 'x'
+#define bfd_mach_m32r2 '2'
bfd_arch_mn10200, /* Matsushita MN10200 */
bfd_arch_mn10300, /* Matsushita MN10300 */
#define bfd_mach_mn10300 300
#define bfd_mach_am33 330
+#define bfd_mach_am33_2 332
bfd_arch_fr30,
#define bfd_mach_fr30 0x46523330
bfd_arch_frv,
-#define bfd_mach_frv 0
-#define bfd_mach_frvsimple 1
+#define bfd_mach_frv 1
+#define bfd_mach_frvsimple 2
#define bfd_mach_fr300 300
#define bfd_mach_fr400 400
#define bfd_mach_frvtomcat 499 /* fr500 prototype */
#define bfd_mach_fr500 500
+#define bfd_mach_fr550 550
bfd_arch_mcore,
bfd_arch_ia64, /* HP/Intel ia64 */
-#define bfd_mach_ia64_elf64 0
-#define bfd_mach_ia64_elf32 1
+#define bfd_mach_ia64_elf64 64
+#define bfd_mach_ia64_elf32 32
+ bfd_arch_ip2k, /* Ubicom IP2K microcontrollers. */
+#define bfd_mach_ip2022 1
+#define bfd_mach_ip2022ext 2
+ bfd_arch_iq2000, /* Vitesse IQ2000. */
+#define bfd_mach_iq2000 1
+#define bfd_mach_iq10 2
bfd_arch_pj,
bfd_arch_avr, /* Atmel AVR microcontrollers. */
#define bfd_mach_avr1 1
@@ -233,12 +273,29 @@ enum bfd_architecture
#define bfd_mach_avr5 5
bfd_arch_cris, /* Axis CRIS */
bfd_arch_s390, /* IBM s390 */
-#define bfd_mach_s390_31 0
-#define bfd_mach_s390_64 1
+#define bfd_mach_s390_31 31
+#define bfd_mach_s390_64 64
bfd_arch_openrisc, /* OpenRISC */
bfd_arch_mmix, /* Donald Knuth's educational processor. */
bfd_arch_xstormy16,
-#define bfd_mach_xstormy16 0
+#define bfd_mach_xstormy16 1
+ bfd_arch_msp430, /* Texas Instruments MSP430 architecture. */
+#define bfd_mach_msp11 11
+#define bfd_mach_msp110 110
+#define bfd_mach_msp12 12
+#define bfd_mach_msp13 13
+#define bfd_mach_msp14 14
+#define bfd_mach_msp15 15
+#define bfd_mach_msp16 16
+#define bfd_mach_msp31 31
+#define bfd_mach_msp32 32
+#define bfd_mach_msp33 33
+#define bfd_mach_msp41 41
+#define bfd_mach_msp42 42
+#define bfd_mach_msp43 43
+#define bfd_mach_msp44 44
+ bfd_arch_xtensa, /* Tensilica's Xtensa cores. */
+#define bfd_mach_xtensa 1
bfd_arch_last
@};
@end example
@@ -261,15 +318,14 @@ typedef struct bfd_arch_info
const char *arch_name;
const char *printable_name;
unsigned int section_align_power;
- /* True if this is the default machine for the architecture.
+ /* TRUE if this is the default machine for the architecture.
The default arch should be the first entry for an arch so that
all the entries for that arch can be accessed via @code{next}. */
- boolean the_default;
+ bfd_boolean the_default;
const struct bfd_arch_info * (*compatible)
- PARAMS ((const struct bfd_arch_info *a,
- const struct bfd_arch_info *b));
+ (const struct bfd_arch_info *a, const struct bfd_arch_info *b);
- boolean (*scan) PARAMS ((const struct bfd_arch_info *, const char *));
+ bfd_boolean (*scan) (const struct bfd_arch_info *, const char *);
const struct bfd_arch_info *next;
@}
@@ -281,7 +337,7 @@ bfd_arch_info_type;
@subsubsection @code{bfd_printable_name}
@strong{Synopsis}
@example
-const char *bfd_printable_name(bfd *abfd);
+const char *bfd_printable_name (bfd *abfd);
@end example
@strong{Description}@*
Return a printable string representing the architecture and machine
@@ -291,7 +347,7 @@ from the pointer to the architecture info structure.
@subsubsection @code{bfd_scan_arch}
@strong{Synopsis}
@example
-const bfd_arch_info_type *bfd_scan_arch(const char *string);
+const bfd_arch_info_type *bfd_scan_arch (const char *string);
@end example
@strong{Description}@*
Figure out if BFD supports any cpu which could be described with
@@ -302,7 +358,7 @@ structure if a machine is found, otherwise NULL.
@subsubsection @code{bfd_arch_list}
@strong{Synopsis}
@example
-const char **bfd_arch_list(void);
+const char **bfd_arch_list (void);
@end example
@strong{Description}@*
Return a freshly malloced NULL-terminated vector of the names
@@ -312,16 +368,15 @@ of all the valid BFD architectures. Do not modify the names.
@subsubsection @code{bfd_arch_get_compatible}
@strong{Synopsis}
@example
-const bfd_arch_info_type *bfd_arch_get_compatible(
- const bfd *abfd,
- const bfd *bbfd);
+const bfd_arch_info_type *bfd_arch_get_compatible
+ (const bfd *abfd, const bfd *bbfd, bfd_boolean accept_unknowns);
@end example
@strong{Description}@*
-Determine whether two BFDs'
-architectures and machine types are compatible. Calculates
-the lowest common denominator between the two architectures
-and machine types implied by the BFDs and returns a pointer to
-an @code{arch_info} structure describing the compatible machine.
+Determine whether two BFDs' architectures and machine types
+are compatible. Calculates the lowest common denominator
+between the two architectures and machine types implied by
+the BFDs and returns a pointer to an @code{arch_info} structure
+describing the compatible machine.
@findex bfd_default_arch_struct
@subsubsection @code{bfd_default_arch_struct}
@@ -339,7 +394,7 @@ extern const bfd_arch_info_type bfd_default_arch_struct;
@subsubsection @code{bfd_set_arch_info}
@strong{Synopsis}
@example
-void bfd_set_arch_info(bfd *abfd, const bfd_arch_info_type *arg);
+void bfd_set_arch_info (bfd *abfd, const bfd_arch_info_type *arg);
@end example
@strong{Description}@*
Set the architecture info of @var{abfd} to @var{arg}.
@@ -348,9 +403,8 @@ Set the architecture info of @var{abfd} to @var{arg}.
@subsubsection @code{bfd_default_set_arch_mach}
@strong{Synopsis}
@example
-boolean bfd_default_set_arch_mach(bfd *abfd,
- enum bfd_architecture arch,
- unsigned long mach);
+bfd_boolean bfd_default_set_arch_mach
+ (bfd *abfd, enum bfd_architecture arch, unsigned long mach);
@end example
@strong{Description}@*
Set the architecture and machine type in BFD @var{abfd}
@@ -362,7 +416,7 @@ pointer.
@subsubsection @code{bfd_get_arch}
@strong{Synopsis}
@example
-enum bfd_architecture bfd_get_arch(bfd *abfd);
+enum bfd_architecture bfd_get_arch (bfd *abfd);
@end example
@strong{Description}@*
Return the enumerated type which describes the BFD @var{abfd}'s
@@ -372,7 +426,7 @@ architecture.
@subsubsection @code{bfd_get_mach}
@strong{Synopsis}
@example
-unsigned long bfd_get_mach(bfd *abfd);
+unsigned long bfd_get_mach (bfd *abfd);
@end example
@strong{Description}@*
Return the long type which describes the BFD @var{abfd}'s
@@ -382,7 +436,7 @@ machine.
@subsubsection @code{bfd_arch_bits_per_byte}
@strong{Synopsis}
@example
-unsigned int bfd_arch_bits_per_byte(bfd *abfd);
+unsigned int bfd_arch_bits_per_byte (bfd *abfd);
@end example
@strong{Description}@*
Return the number of bits in one of the BFD @var{abfd}'s
@@ -392,7 +446,7 @@ architecture's bytes.
@subsubsection @code{bfd_arch_bits_per_address}
@strong{Synopsis}
@example
-unsigned int bfd_arch_bits_per_address(bfd *abfd);
+unsigned int bfd_arch_bits_per_address (bfd *abfd);
@end example
@strong{Description}@*
Return the number of bits in one of the BFD @var{abfd}'s
@@ -403,8 +457,7 @@ architecture's addresses.
@strong{Synopsis}
@example
const bfd_arch_info_type *bfd_default_compatible
- (const bfd_arch_info_type *a,
- const bfd_arch_info_type *b);
+ (const bfd_arch_info_type *a, const bfd_arch_info_type *b);
@end example
@strong{Description}@*
The default function for testing for compatibility.
@@ -413,7 +466,8 @@ The default function for testing for compatibility.
@subsubsection @code{bfd_default_scan}
@strong{Synopsis}
@example
-boolean bfd_default_scan(const struct bfd_arch_info *info, const char *string);
+bfd_boolean bfd_default_scan
+ (const struct bfd_arch_info *info, const char *string);
@end example
@strong{Description}@*
The default function for working out whether this is an
@@ -423,7 +477,7 @@ architecture hit and a machine hit.
@subsubsection @code{bfd_get_arch_info}
@strong{Synopsis}
@example
-const bfd_arch_info_type * bfd_get_arch_info(bfd *abfd);
+const bfd_arch_info_type *bfd_get_arch_info (bfd *abfd);
@end example
@strong{Description}@*
Return the architecture info struct in @var{abfd}.
@@ -433,12 +487,10 @@ Return the architecture info struct in @var{abfd}.
@strong{Synopsis}
@example
const bfd_arch_info_type *bfd_lookup_arch
- (enum bfd_architecture
- arch,
- unsigned long machine);
+ (enum bfd_architecture arch, unsigned long machine);
@end example
@strong{Description}@*
-Look for the architecure info structure which matches the
+Look for the architecture info structure which matches the
arguments @var{arch} and @var{machine}. A machine of 0 matches the
machine/architecture structure which marks itself as the
default.
@@ -460,7 +512,7 @@ This routine is depreciated.
@subsubsection @code{bfd_octets_per_byte}
@strong{Synopsis}
@example
-unsigned int bfd_octets_per_byte(bfd *abfd);
+unsigned int bfd_octets_per_byte (bfd *abfd);
@end example
@strong{Description}@*
Return the number of octets (8-bit quantities) per target byte
@@ -471,8 +523,8 @@ DSP targets have 16, 32, or even 48 bits per byte.
@subsubsection @code{bfd_arch_mach_octets_per_byte}
@strong{Synopsis}
@example
-unsigned int bfd_arch_mach_octets_per_byte(enum bfd_architecture arch,
- unsigned long machine);
+unsigned int bfd_arch_mach_octets_per_byte
+ (enum bfd_architecture arch, unsigned long machine);
@end example
@strong{Description}@*
See bfd_octets_per_byte.
diff --git a/contrib/binutils/bfd/doc/bfd.texinfo b/contrib/binutils/bfd/doc/bfd.texinfo
index 380501e..3ed4194 100644
--- a/contrib/binutils/bfd/doc/bfd.texinfo
+++ b/contrib/binutils/bfd/doc/bfd.texinfo
@@ -1,6 +1,6 @@
\input texinfo.tex
@setfilename bfd.info
-@c Copyright 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1997, 2000
+@c Copyright 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1997, 2000, 2003
@c Free Software Foundation, Inc.
@c
@tex
@@ -30,14 +30,14 @@ END-INFO-DIR-ENTRY
@ifinfo
This file documents the BFD library.
-Copyright (C) 1991, 2000, 2001 Free Software Foundation, Inc.
+Copyright (C) 1991, 2000, 2001, 2003 Free Software Foundation, Inc.
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
- section entitled "GNU Free Documentation License".
+ section entitled ``GNU Free Documentation License''.
@ignore
Permission is granted to process this file through Tex and print the
@@ -64,7 +64,7 @@ notice identical to this one except for the removal of this paragraph
@tex
\def\$#1${{#1}} % Kluge: collect RCS revision info without $...$
-\xdef\manvers{\$Revision: 1.5 $} % For use in headers, footers too
+\xdef\manvers{1.5} % For use in headers, footers too
{\parskip=0pt
\hfill Free Software Foundation\par
\hfill sac\@www.gnu.org\par
@@ -75,14 +75,14 @@ notice identical to this one except for the removal of this paragraph
@end tex
@vskip 0pt plus 1filll
-Copyright @copyright{} 1991, 2001 Free Software Foundation, Inc.
+Copyright @copyright{} 1991, 2001, 2003 Free Software Foundation, Inc.
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
- section entitled "GNU Free Documentation License".
+ section entitled ``GNU Free Documentation License''.
@end titlepage
@end iftex
@@ -170,17 +170,17 @@ For example, this sequence does what you would probably expect:
return the number of sections in an object file attached to a BFD
@code{abfd}.
-@lisp
+@example
@c @cartouche
#include "bfd.h"
-unsigned int number_of_sections(abfd)
+unsigned int number_of_sections (abfd)
bfd *abfd;
@{
- return bfd_count_sections(abfd);
+ return bfd_count_sections (abfd);
@}
@c @end cartouche
-@end lisp
+@end example
The abstraction used within BFD is that an object file has:
@@ -205,8 +205,9 @@ IEEE-695.
@include bfdsumm.texi
@node BFD front end, BFD back ends, Overview, Top
-@chapter BFD front end
+@chapter BFD Front End
@include bfdt.texi
+@include bfdio.texi
@menu
* Memory Usage::
@@ -227,7 +228,7 @@ IEEE-695.
@end menu
@node Memory Usage, Initialization, BFD front end, BFD front end
-@section Memory usage
+@section Memory Usage
BFD keeps all of its internal structures in obstacks. There is one obstack
per open BFD file, into which the current state is stored. When a BFD is
closed, the obstack is deleted, and so everything which has been
@@ -323,370 +324,9 @@ All of BFD lives in one directory.
@include mmo.texi
@node GNU Free Documentation License, Index, BFD back ends, Top
-@chapter GNU Free Documentation License
-@cindex GNU Free Documentation License
-
- GNU Free Documentation License
-
- Version 1.1, March 2000
-
- Copyright (C) 2000 Free Software Foundation, Inc.
- 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-
- Everyone is permitted to copy and distribute verbatim copies
- of this license document, but changing it is not allowed.
-
-
-0. PREAMBLE
-
-The purpose of this License is to make a manual, textbook, or other
-written document "free" in the sense of freedom: to assure everyone
-the effective freedom to copy and redistribute it, with or without
-modifying it, either commercially or noncommercially. Secondarily,
-this License preserves for the author and publisher a way to get
-credit for their work, while not being considered responsible for
-modifications made by others.
-
-This License is a kind of "copyleft", which means that derivative
-works of the document must themselves be free in the same sense. It
-complements the GNU General Public License, which is a copyleft
-license designed for free software.
-
-We have designed this License in order to use it for manuals for free
-software, because free software needs free documentation: a free
-program should come with manuals providing the same freedoms that the
-software does. But this License is not limited to software manuals;
-it can be used for any textual work, regardless of subject matter or
-whether it is published as a printed book. We recommend this License
-principally for works whose purpose is instruction or reference.
-
-
-1. APPLICABILITY AND DEFINITIONS
-
-This License applies to any manual or other work that contains a
-notice placed by the copyright holder saying it can be distributed
-under the terms of this License. The "Document", below, refers to any
-such manual or work. Any member of the public is a licensee, and is
-addressed as "you".
-
-A "Modified Version" of the Document means any work containing the
-Document or a portion of it, either copied verbatim, or with
-modifications and/or translated into another language.
-
-A "Secondary Section" is a named appendix or a front-matter section of
-the Document that deals exclusively with the relationship of the
-publishers or authors of the Document to the Document's overall subject
-(or to related matters) and contains nothing that could fall directly
-within that overall subject. (For example, if the Document is in part a
-textbook of mathematics, a Secondary Section may not explain any
-mathematics.) The relationship could be a matter of historical
-connection with the subject or with related matters, or of legal,
-commercial, philosophical, ethical or political position regarding
-them.
-
-The "Invariant Sections" are certain Secondary Sections whose titles
-are designated, as being those of Invariant Sections, in the notice
-that says that the Document is released under this License.
-
-The "Cover Texts" are certain short passages of text that are listed,
-as Front-Cover Texts or Back-Cover Texts, in the notice that says that
-the Document is released under this License.
-
-A "Transparent" copy of the Document means a machine-readable copy,
-represented in a format whose specification is available to the
-general public, whose contents can be viewed and edited directly and
-straightforwardly with generic text editors or (for images composed of
-pixels) generic paint programs or (for drawings) some widely available
-drawing editor, and that is suitable for input to text formatters or
-for automatic translation to a variety of formats suitable for input
-to text formatters. A copy made in an otherwise Transparent file
-format whose markup has been designed to thwart or discourage
-subsequent modification by readers is not Transparent. A copy that is
-not "Transparent" is called "Opaque".
-
-Examples of suitable formats for Transparent copies include plain
-ASCII without markup, Texinfo input format, LaTeX input format, SGML
-or XML using a publicly available DTD, and standard-conforming simple
-HTML designed for human modification. Opaque formats include
-PostScript, PDF, proprietary formats that can be read and edited only
-by proprietary word processors, SGML or XML for which the DTD and/or
-processing tools are not generally available, and the
-machine-generated HTML produced by some word processors for output
-purposes only.
-
-The "Title Page" means, for a printed book, the title page itself,
-plus such following pages as are needed to hold, legibly, the material
-this License requires to appear in the title page. For works in
-formats which do not have any title page as such, "Title Page" means
-the text near the most prominent appearance of the work's title,
-preceding the beginning of the body of the text.
-
-
-2. VERBATIM COPYING
-
-You may copy and distribute the Document in any medium, either
-commercially or noncommercially, provided that this License, the
-copyright notices, and the license notice saying this License applies
-to the Document are reproduced in all copies, and that you add no other
-conditions whatsoever to those of this License. You may not use
-technical measures to obstruct or control the reading or further
-copying of the copies you make or distribute. However, you may accept
-compensation in exchange for copies. If you distribute a large enough
-number of copies you must also follow the conditions in section 3.
-
-You may also lend copies, under the same conditions stated above, and
-you may publicly display copies.
-
-
-3. COPYING IN QUANTITY
-
-If you publish printed copies of the Document numbering more than 100,
-and the Document's license notice requires Cover Texts, you must enclose
-the copies in covers that carry, clearly and legibly, all these Cover
-Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on
-the back cover. Both covers must also clearly and legibly identify
-you as the publisher of these copies. The front cover must present
-the full title with all words of the title equally prominent and
-visible. You may add other material on the covers in addition.
-Copying with changes limited to the covers, as long as they preserve
-the title of the Document and satisfy these conditions, can be treated
-as verbatim copying in other respects.
-
-If the required texts for either cover are too voluminous to fit
-legibly, you should put the first ones listed (as many as fit
-reasonably) on the actual cover, and continue the rest onto adjacent
-pages.
-
-If you publish or distribute Opaque copies of the Document numbering
-more than 100, you must either include a machine-readable Transparent
-copy along with each Opaque copy, or state in or with each Opaque copy
-a publicly-accessible computer-network location containing a complete
-Transparent copy of the Document, free of added material, which the
-general network-using public has access to download anonymously at no
-charge using public-standard network protocols. If you use the latter
-option, you must take reasonably prudent steps, when you begin
-distribution of Opaque copies in quantity, to ensure that this
-Transparent copy will remain thus accessible at the stated location
-until at least one year after the last time you distribute an Opaque
-copy (directly or through your agents or retailers) of that edition to
-the public.
-
-It is requested, but not required, that you contact the authors of the
-Document well before redistributing any large number of copies, to give
-them a chance to provide you with an updated version of the Document.
-
-
-4. MODIFICATIONS
-
-You may copy and distribute a Modified Version of the Document under
-the conditions of sections 2 and 3 above, provided that you release
-the Modified Version under precisely this License, with the Modified
-Version filling the role of the Document, thus licensing distribution
-and modification of the Modified Version to whoever possesses a copy
-of it. In addition, you must do these things in the Modified Version:
-
-A. Use in the Title Page (and on the covers, if any) a title distinct
- from that of the Document, and from those of previous versions
- (which should, if there were any, be listed in the History section
- of the Document). You may use the same title as a previous version
- if the original publisher of that version gives permission.
-B. List on the Title Page, as authors, one or more persons or entities
- responsible for authorship of the modifications in the Modified
- Version, together with at least five of the principal authors of the
- Document (all of its principal authors, if it has less than five).
-C. State on the Title page the name of the publisher of the
- Modified Version, as the publisher.
-D. Preserve all the copyright notices of the Document.
-E. Add an appropriate copyright notice for your modifications
- adjacent to the other copyright notices.
-F. Include, immediately after the copyright notices, a license notice
- giving the public permission to use the Modified Version under the
- terms of this License, in the form shown in the Addendum below.
-G. Preserve in that license notice the full lists of Invariant Sections
- and required Cover Texts given in the Document's license notice.
-H. Include an unaltered copy of this License.
-I. Preserve the section entitled "History", and its title, and add to
- it an item stating at least the title, year, new authors, and
- publisher of the Modified Version as given on the Title Page. If
- there is no section entitled "History" in the Document, create one
- stating the title, year, authors, and publisher of the Document as
- given on its Title Page, then add an item describing the Modified
- Version as stated in the previous sentence.
-J. Preserve the network location, if any, given in the Document for
- public access to a Transparent copy of the Document, and likewise
- the network locations given in the Document for previous versions
- it was based on. These may be placed in the "History" section.
- You may omit a network location for a work that was published at
- least four years before the Document itself, or if the original
- publisher of the version it refers to gives permission.
-K. In any section entitled "Acknowledgements" or "Dedications",
- preserve the section's title, and preserve in the section all the
- substance and tone of each of the contributor acknowledgements
- and/or dedications given therein.
-L. Preserve all the Invariant Sections of the Document,
- unaltered in their text and in their titles. Section numbers
- or the equivalent are not considered part of the section titles.
-M. Delete any section entitled "Endorsements". Such a section
- may not be included in the Modified Version.
-N. Do not retitle any existing section as "Endorsements"
- or to conflict in title with any Invariant Section.
-
-If the Modified Version includes new front-matter sections or
-appendices that qualify as Secondary Sections and contain no material
-copied from the Document, you may at your option designate some or all
-of these sections as invariant. To do this, add their titles to the
-list of Invariant Sections in the Modified Version's license notice.
-These titles must be distinct from any other section titles.
-
-You may add a section entitled "Endorsements", provided it contains
-nothing but endorsements of your Modified Version by various
-parties--for example, statements of peer review or that the text has
-been approved by an organization as the authoritative definition of a
-standard.
-
-You may add a passage of up to five words as a Front-Cover Text, and a
-passage of up to 25 words as a Back-Cover Text, to the end of the list
-of Cover Texts in the Modified Version. Only one passage of
-Front-Cover Text and one of Back-Cover Text may be added by (or
-through arrangements made by) any one entity. If the Document already
-includes a cover text for the same cover, previously added by you or
-by arrangement made by the same entity you are acting on behalf of,
-you may not add another; but you may replace the old one, on explicit
-permission from the previous publisher that added the old one.
-
-The author(s) and publisher(s) of the Document do not by this License
-give permission to use their names for publicity for or to assert or
-imply endorsement of any Modified Version.
-
-
-5. COMBINING DOCUMENTS
-
-You may combine the Document with other documents released under this
-License, under the terms defined in section 4 above for modified
-versions, provided that you include in the combination all of the
-Invariant Sections of all of the original documents, unmodified, and
-list them all as Invariant Sections of your combined work in its
-license notice.
-
-The combined work need only contain one copy of this License, and
-multiple identical Invariant Sections may be replaced with a single
-copy. If there are multiple Invariant Sections with the same name but
-different contents, make the title of each such section unique by
-adding at the end of it, in parentheses, the name of the original
-author or publisher of that section if known, or else a unique number.
-Make the same adjustment to the section titles in the list of
-Invariant Sections in the license notice of the combined work.
-
-In the combination, you must combine any sections entitled "History"
-in the various original documents, forming one section entitled
-"History"; likewise combine any sections entitled "Acknowledgements",
-and any sections entitled "Dedications". You must delete all sections
-entitled "Endorsements."
-
-
-6. COLLECTIONS OF DOCUMENTS
-
-You may make a collection consisting of the Document and other documents
-released under this License, and replace the individual copies of this
-License in the various documents with a single copy that is included in
-the collection, provided that you follow the rules of this License for
-verbatim copying of each of the documents in all other respects.
-
-You may extract a single document from such a collection, and distribute
-it individually under this License, provided you insert a copy of this
-License into the extracted document, and follow this License in all
-other respects regarding verbatim copying of that document.
-
-
-7. AGGREGATION WITH INDEPENDENT WORKS
-
-A compilation of the Document or its derivatives with other separate
-and independent documents or works, in or on a volume of a storage or
-distribution medium, does not as a whole count as a Modified Version
-of the Document, provided no compilation copyright is claimed for the
-compilation. Such a compilation is called an "aggregate", and this
-License does not apply to the other self-contained works thus compiled
-with the Document, on account of their being thus compiled, if they
-are not themselves derivative works of the Document.
-
-If the Cover Text requirement of section 3 is applicable to these
-copies of the Document, then if the Document is less than one quarter
-of the entire aggregate, the Document's Cover Texts may be placed on
-covers that surround only the Document within the aggregate.
-Otherwise they must appear on covers around the whole aggregate.
-
-
-8. TRANSLATION
-
-Translation is considered a kind of modification, so you may
-distribute translations of the Document under the terms of section 4.
-Replacing Invariant Sections with translations requires special
-permission from their copyright holders, but you may include
-translations of some or all Invariant Sections in addition to the
-original versions of these Invariant Sections. You may include a
-translation of this License provided that you also include the
-original English version of this License. In case of a disagreement
-between the translation and the original English version of this
-License, the original English version will prevail.
-
-
-9. TERMINATION
-
-You may not copy, modify, sublicense, or distribute the Document except
-as expressly provided for under this License. Any other attempt to
-copy, modify, sublicense or distribute the Document is void, and will
-automatically terminate your rights under this License. However,
-parties who have received copies, or rights, from you under this
-License will not have their licenses terminated so long as such
-parties remain in full compliance.
-
-
-10. FUTURE REVISIONS OF THIS LICENSE
-
-The Free Software Foundation may publish new, revised versions
-of the GNU Free Documentation License from time to time. Such new
-versions will be similar in spirit to the present version, but may
-differ in detail to address new problems or concerns. See
-http://www.gnu.org/copyleft/.
-
-Each version of the License is given a distinguishing version number.
-If the Document specifies that a particular numbered version of this
-License "or any later version" applies to it, you have the option of
-following the terms and conditions either of that specified version or
-of any later version that has been published (not as a draft) by the
-Free Software Foundation. If the Document does not specify a version
-number of this License, you may choose any version ever published (not
-as a draft) by the Free Software Foundation.
-
-
-ADDENDUM: How to use this License for your documents
-
-To use this License in a document you have written, include a copy of
-the License in the document and put the following copyright and
-license notices just after the title page:
-
-@smallexample
- Copyright (c) YEAR YOUR NAME.
- Permission is granted to copy, distribute and/or modify this document
- under the terms of the GNU Free Documentation License, Version 1.1
- or any later version published by the Free Software Foundation;
- with the Invariant Sections being LIST THEIR TITLES, with the
- Front-Cover Texts being LIST, and with the Back-Cover Texts being LIST.
- A copy of the license is included in the section entitled "GNU
- Free Documentation License".
-@end smallexample
-
-If you have no Invariant Sections, write "with no Invariant Sections"
-instead of saying which ones are invariant. If you have no
-Front-Cover Texts, write "no Front-Cover Texts" instead of
-"Front-Cover Texts being LIST"; likewise for Back-Cover Texts.
-
-If your document contains nontrivial examples of program code, we
-recommend releasing these examples in parallel under your choice of
-free software license, such as the GNU General Public License,
-to permit their use in free software.
-
-@node Index, , GNU Free Documentation License , Top
+@include fdl.texi
+
+@node Index, , GNU Free Documentation License, Top
@unnumbered Index
@printindex cp
diff --git a/contrib/binutils/bfd/doc/bfdint.texi b/contrib/binutils/bfd/doc/bfdint.texi
index d2996dc..95c0096 100644
--- a/contrib/binutils/bfd/doc/bfdint.texi
+++ b/contrib/binutils/bfd/doc/bfdint.texi
@@ -1,6 +1,6 @@
\input texinfo
@c Copyright 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1998,
-@c 2000, 2001
+@c 2000, 2001, 2002, 2003
@c Free Software Foundation, Inc.
@setfilename bfdint.info
@@ -694,7 +694,7 @@ information in BFD private data. This is called via
@samp{bfd_get_symtab_upper_bound}. The corresponding field in the
target vector is named @samp{_bfd_get_symtab_upper_bound}.
-@item _get_symtab
+@item _canonicalize_symtab
Read in the symbol table. This is called via
@samp{bfd_canonicalize_symtab}. The corresponding field in the target
vector is named @samp{_bfd_canonicalize_symtab}.
@@ -835,7 +835,7 @@ corresponding field in the target vector is named
@item _bfd_get_relocated_section_contents
Read the contents of a section and apply the relocation information.
-This handles both a final link and a relocateable link; in the latter
+This handles both a final link and a relocatable link; in the latter
case, it adjust the relocation information as well. This is called via
@samp{bfd_get_relocated_section_contents}. Most targets implement it by
calling @samp{bfd_generic_get_relocated_section_contents}.
@@ -1073,11 +1073,6 @@ sizes.
Like @file{elfcode.h}, but for functions that are specific to ELF core
files. This is included only by @file{elfcode.h}.
-@item elflink.h
-@cindex @file{elflink.h}
-Like @file{elfcode.h}, but for functions used by the ELF linker. This
-is included only by @file{elfcode.h}.
-
@item elfxx-target.h
@cindex @file{elfxx-target.h}
This file is the source for the generated files @file{elf32-target.h}
@@ -1169,7 +1164,7 @@ allocate space in a different section and use the offset within that
section as the value to store. In the IEEE object file format,
relocations may involve arbitrary expressions.
-When doing a relocateable link, the linker may or may not have to do
+When doing a relocatable link, the linker may or may not have to do
anything with a relocation, depending upon the definition of the
relocation. Simple relocations generally do not require any special
action.
@@ -1240,9 +1235,9 @@ existing target, you need to do the following:
@itemize @bullet
@item
Make sure you clearly understand what the contents of the section should
-look like after assembly, after a relocateable link, and after a final
+look like after assembly, after a relocatable link, and after a final
link. Make sure you clearly understand the operations the linker must
-perform during a relocateable link and during a final link.
+perform during a relocatable link and during a final link.
@item
Write a howto structure for the relocation. The howto structure is
@@ -1257,7 +1252,7 @@ call @samp{bfd_install_relocation}, so your howto structure has to be
able to handle that. You may need to set the @samp{special_function}
field to handle assembly correctly. Be careful to ensure that any code
you write to handle the assembler will also work correctly when doing a
-relocateable link. For example, see @samp{bfd_elf_generic_reloc}.
+relocatable link. For example, see @samp{bfd_elf_generic_reloc}.
@item
Test the assembler. Consider the cases of relocation against an
@@ -1271,14 +1266,14 @@ If your target uses the new linker, which is recommended, add any
required handling to the target specific relocation function. In simple
cases this will just involve a call to @samp{_bfd_final_link_relocate}
or @samp{_bfd_relocate_contents}, depending upon the definition of the
-relocation and whether the link is relocateable or not.
+relocation and whether the link is relocatable or not.
@item
Test the linker. Test the case of a final link. If the relocation can
overflow, use a linker script to force an overflow and make sure the
-error is reported correctly. Test a relocateable link, whether the
-symbol is defined or undefined in the relocateable output. For both the
-final and relocateable link, test the case when the symbol is a common
+error is reported correctly. Test a relocatable link, whether the
+symbol is defined or undefined in the relocatable output. For both the
+final and relocatable link, test the case when the symbol is a common
symbol, when the symbol looked like a common symbol but became a defined
symbol, when the symbol is defined in a different object file, and when
the symbol is defined in the same object file.
@@ -1291,7 +1286,7 @@ thing for the relocation. You may need to set the
doing a link in which the output object file format is S-records.
@item
-Using the linker to generate relocateable output in a different object
+Using the linker to generate relocatable output in a different object
file format is impossible in the general case, so you generally don't
have to worry about that. The GNU linker makes sure to stop that from
happening when an input file in a different format has relocations.
@@ -1350,7 +1345,7 @@ howto structure. Some mechanism would be used to determine which type
of howto structure was being used by a particular format.
The new howto structure would clearly define the relocation behaviour in
-the case of an assembly, a relocateable link, and a final link. At
+the case of an assembly, a relocatable link, and a final link. At
least one special function would be defined as an escape, and it might
make sense to define more.
@@ -1482,8 +1477,7 @@ external data. @file{elfcode.h} is compiled twice, once via
@file{elfcode.h} includes functions to swap the ELF structures in and
out of external form, as well as a few more complex functions.
-Linker support is found in @file{elflink.c} and @file{elflink.h}. The
-latter file is compiled twice, for both 32 and 64 bit support. The
+Linker support is found in @file{elflink.c}. The
linker support is only used if the processor specific file defines
@samp{elf_backend_relocate_section}, which is required to relocate the
section contents. If that macro is not defined, the generic linker code
@@ -1566,7 +1560,7 @@ relocations. @samp{Rela} relocations will require more space in object
files (but not in executables, except when using dynamic linking).
However, this is outweighed by the simplicity of addend handling when
using @samp{Rela} relocations. With @samp{Rel} relocations, the addend
-must be stored in the section contents, which makes relocateable links
+must be stored in the section contents, which makes relocatable links
more complex.
For example, consider C code like @code{i = a[1000];} where @samp{a} is
@@ -1578,7 +1572,7 @@ relocations, that addend must be stored in the instructions themselves.
If you are adding support for a RISC chip which uses two or more
instructions to load an address, then the addend may not fit in a single
instruction, and will have to be somehow split among the instructions.
-This makes linking awkward, particularly when doing a relocateable link
+This makes linking awkward, particularly when doing a relocatable link
in which the addend may have to be updated. It can be done---the MIPS
ELF support does it---but it should be avoided when possible.
@@ -1611,7 +1605,7 @@ called @file{@var{cpu}.h}. This file should define any target specific
information which may be needed outside of the BFD code. In particular
it should use the @samp{START_RELOC_NUMBERS}, @samp{RELOC_NUMBER},
@samp{FAKE_RELOC}, @samp{EMPTY_RELOC} and @samp{END_RELOC_NUMBERS}
-macros to create a table mapping the number used to indentify a
+macros to create a table mapping the number used to identify a
relocation to a name describing that relocation.
While not a BFD component, you probably also want to make the binutils
@@ -1645,7 +1639,7 @@ information, and modify the section contents according to the relocation
information. In simple cases, this is little more than a loop over the
relocations which computes the value of each relocation and calls
@samp{_bfd_final_link_relocate}. The function must check for a
-relocateable link, and in that case normally needs to do nothing other
+relocatable link, and in that case normally needs to do nothing other
than adjust the addend for relocations against a section symbol.
The complex cases generally have to do with dynamic linker support. GOT
@@ -1788,7 +1782,7 @@ The implementation within BFD of a particular object file format. The
set of functions which appear in a particular target vector.
@item BFD
-The BFD library itself. Also, each object file, archive, or exectable
+The BFD library itself. Also, each object file, archive, or executable
opened by the BFD library has the type @samp{bfd *}, and is sometimes
referred to as a bfd.
diff --git a/contrib/binutils/bfd/doc/bfdio.texi b/contrib/binutils/bfd/doc/bfdio.texi
new file mode 100644
index 0000000..b8c79d3
--- /dev/null
+++ b/contrib/binutils/bfd/doc/bfdio.texi
@@ -0,0 +1,41 @@
+@findex bfd_get_mtime
+@subsubsection @code{bfd_get_mtime}
+@strong{Synopsis}
+@example
+long bfd_get_mtime (bfd *abfd);
+@end example
+@strong{Description}@*
+Return the file modification time (as read from the file system, or
+from the archive header for archive members).
+
+@findex bfd_get_size
+@subsubsection @code{bfd_get_size}
+@strong{Synopsis}
+@example
+long bfd_get_size (bfd *abfd);
+@end example
+@strong{Description}@*
+Return the file size (as read from file system) for the file
+associated with BFD @var{abfd}.
+
+The initial motivation for, and use of, this routine is not
+so we can get the exact size of the object the BFD applies to, since
+that might not be generally possible (archive members for example).
+It would be ideal if someone could eventually modify
+it so that such results were guaranteed.
+
+Instead, we want to ask questions like "is this NNN byte sized
+object I'm about to try read from file offset YYY reasonable?"
+As as example of where we might do this, some object formats
+use string tables for which the first @code{sizeof (long)} bytes of the
+table contain the size of the table itself, including the size bytes.
+If an application tries to read what it thinks is one of these
+string tables, without some way to validate the size, and for
+some reason the size is wrong (byte swapping error, wrong location
+for the string table, etc.), the only clue is likely to be a read
+error when it tries to read the table, or a "virtual memory
+exhausted" error when it tries to allocate 15 bazillon bytes
+of space for the 15 bazillon byte table it is about to read.
+This function at least allows us to answer the question, "is the
+size reasonable?".
+
diff --git a/contrib/binutils/bfd/doc/bfdt.texi b/contrib/binutils/bfd/doc/bfdt.texi
index 46bb61a..74cace4 100644
--- a/contrib/binutils/bfd/doc/bfdt.texi
+++ b/contrib/binutils/bfd/doc/bfdt.texi
@@ -10,8 +10,11 @@ to the rest of the data.
@example
-struct _bfd
+struct bfd
@{
+ /* A unique identifier of the BFD */
+ unsigned int id;
+
/* The filename the application opened the BFD with. */
const char *filename;
@@ -25,33 +28,33 @@ struct _bfd
is the result of an fopen on the filename. However, if the
BFD_IN_MEMORY flag is set, then iostream is actually a pointer
to a bfd_in_memory struct. */
- PTR iostream;
+ void *iostream;
/* Is the file descriptor being cached? That is, can it be closed as
needed, and re-opened when accessed later? */
- boolean cacheable;
+ bfd_boolean cacheable;
/* Marks whether there was a default target specified when the
BFD was opened. This is used to select which matching algorithm
to use to choose the back end. */
- boolean target_defaulted;
+ bfd_boolean target_defaulted;
/* The caching routines use these to maintain a
least-recently-used list of BFDs. */
- struct _bfd *lru_prev, *lru_next;
+ struct bfd *lru_prev, *lru_next;
/* When a file is closed by the caching routines, BFD retains
state information on the file here... */
ufile_ptr where;
/* ... and here: (``once'' means at least once). */
- boolean opened_once;
+ bfd_boolean opened_once;
/* Set if we have a locally maintained mtime value, rather than
getting it from the file each time. */
- boolean mtime_set;
+ bfd_boolean mtime_set;
- /* File modified time, if mtime_set is true. */
+ /* File modified time, if mtime_set is TRUE. */
long mtime;
/* Reserved for an unimplemented file locking extension. */
@@ -80,16 +83,16 @@ struct _bfd
/* Remember when output has begun, to stop strange things
from happening. */
- boolean output_has_begun;
+ bfd_boolean output_has_begun;
/* A hash table for section names. */
struct bfd_hash_table section_htab;
/* Pointer to linked list of sections. */
- struct sec *sections;
+ struct bfd_section *sections;
/* The place where we add to the section list. */
- struct sec **section_tail;
+ struct bfd_section **section_tail;
/* The number of sections. */
unsigned int section_count;
@@ -102,7 +105,7 @@ struct _bfd
unsigned int symcount;
/* Symbol table for output BFD (with symcount entries). */
- struct symbol_cache_entry **outsymbols;
+ struct bfd_symbol **outsymbols;
/* Used for slurped dynamic symbol tables. */
unsigned int dynsymcount;
@@ -111,14 +114,14 @@ struct _bfd
const struct bfd_arch_info *arch_info;
/* Stuff only useful for archives. */
- PTR arelt_data;
- struct _bfd *my_archive; /* The containing archive BFD. */
- struct _bfd *next; /* The next BFD in the archive. */
- struct _bfd *archive_head; /* The first BFD in the archive. */
- boolean has_armap;
+ void *arelt_data;
+ struct bfd *my_archive; /* The containing archive BFD. */
+ struct bfd *next; /* The next BFD in the archive. */
+ struct bfd *archive_head; /* The first BFD in the archive. */
+ bfd_boolean has_armap;
/* A chain of BFD structures involved in a link. */
- struct _bfd *link_next;
+ struct bfd *link_next;
/* A field used by _bfd_generic_link_add_archive_symbols. This will
be used only for archive elements. */
@@ -156,17 +159,22 @@ struct _bfd
struct cisco_core_struct *cisco_core_data;
struct versados_data_struct *versados_data;
struct netbsd_core_struct *netbsd_core_data;
- PTR any;
+ struct mach_o_data_struct *mach_o_data;
+ struct mach_o_fat_data_struct *mach_o_fat_data;
+ struct bfd_pef_data_struct *pef_data;
+ struct bfd_pef_xlib_data_struct *pef_xlib_data;
+ struct bfd_sym_data_struct *sym_data;
+ void *any;
@}
tdata;
/* Used by the application to hold private data. */
- PTR usrdata;
+ void *usrdata;
/* Where all the allocated stuff under this BFD goes. This is a
- struct objalloc *, but we use PTR to avoid requiring the inclusion of
- objalloc.h. */
- PTR memory;
+ struct objalloc *, but we use void * to avoid requiring the inclusion
+ of objalloc.h. */
+ void *memory;
@};
@end example
@@ -258,14 +266,14 @@ by @var{message}, a colon, and a space. It is followed by a newline.
@subsection BFD error handler
Some BFD functions want to print messages describing the
problem. They call a BFD error handler function. This
-function may be overriden by the program.
+function may be overridden by the program.
The BFD error handler acts like printf.
@example
-typedef void (*bfd_error_handler_type) PARAMS ((const char *, ...));
+typedef void (*bfd_error_handler_type) (const char *, ...);
@end example
@findex bfd_set_error_handler
@@ -317,7 +325,7 @@ returns the file name.
@subsubsection @code{bfd_get_reloc_upper_bound}
@strong{Synopsis}
@example
-long bfd_get_reloc_upper_bound(bfd *abfd, asection *sect);
+long bfd_get_reloc_upper_bound (bfd *abfd, asection *sect);
@end example
@strong{Description}@*
Return the number of bytes required to store the
@@ -329,10 +337,7 @@ attached to bfd @var{abfd}. If an error occurs, return -1.
@strong{Synopsis}
@example
long bfd_canonicalize_reloc
- (bfd *abfd,
- asection *sec,
- arelent **loc,
- asymbol **syms);
+ (bfd *abfd, asection *sec, arelent **loc, asymbol **syms);
@end example
@strong{Description}@*
Call the back end associated with the open BFD
@@ -362,7 +367,7 @@ The argument @var{abfd} is ignored.
@subsubsection @code{bfd_set_file_flags}
@strong{Synopsis}
@example
-boolean bfd_set_file_flags(bfd *abfd, flagword flags);
+bfd_boolean bfd_set_file_flags (bfd *abfd, flagword flags);
@end example
@strong{Description}@*
Set the flag word in the BFD @var{abfd} to the value @var{flags}.
@@ -418,60 +423,19 @@ not sign extend addresses, and @code{-1} otherwise.
@subsubsection @code{bfd_set_start_address}
@strong{Synopsis}
@example
-boolean bfd_set_start_address(bfd *abfd, bfd_vma vma);
+bfd_boolean bfd_set_start_address (bfd *abfd, bfd_vma vma);
@end example
@strong{Description}@*
Make @var{vma} the entry point of output BFD @var{abfd}.
@strong{Returns}@*
-Returns @code{true} on success, @code{false} otherwise.
-
-@findex bfd_get_mtime
-@subsubsection @code{bfd_get_mtime}
-@strong{Synopsis}
-@example
-long bfd_get_mtime(bfd *abfd);
-@end example
-@strong{Description}@*
-Return the file modification time (as read from the file system, or
-from the archive header for archive members).
-
-@findex bfd_get_size
-@subsubsection @code{bfd_get_size}
-@strong{Synopsis}
-@example
-long bfd_get_size(bfd *abfd);
-@end example
-@strong{Description}@*
-Return the file size (as read from file system) for the file
-associated with BFD @var{abfd}.
-
-The initial motivation for, and use of, this routine is not
-so we can get the exact size of the object the BFD applies to, since
-that might not be generally possible (archive members for example).
-It would be ideal if someone could eventually modify
-it so that such results were guaranteed.
-
-Instead, we want to ask questions like "is this NNN byte sized
-object I'm about to try read from file offset YYY reasonable?"
-As as example of where we might do this, some object formats
-use string tables for which the first @code{sizeof (long)} bytes of the
-table contain the size of the table itself, including the size bytes.
-If an application tries to read what it thinks is one of these
-string tables, without some way to validate the size, and for
-some reason the size is wrong (byte swapping error, wrong location
-for the string table, etc.), the only clue is likely to be a read
-error when it tries to read the table, or a "virtual memory
-exhausted" error when it tries to allocate 15 bazillon bytes
-of space for the 15 bazillon byte table it is about to read.
-This function at least allows us to answer the quesion, "is the
-size reasonable?".
+Returns @code{TRUE} on success, @code{FALSE} otherwise.
@findex bfd_get_gp_size
@subsubsection @code{bfd_get_gp_size}
@strong{Synopsis}
@example
-unsigned int bfd_get_gp_size(bfd *abfd);
+unsigned int bfd_get_gp_size (bfd *abfd);
@end example
@strong{Description}@*
Return the maximum size of objects to be optimized using the GP
@@ -482,7 +446,7 @@ argument to the compiler, assembler or linker.
@subsubsection @code{bfd_set_gp_size}
@strong{Synopsis}
@example
-void bfd_set_gp_size(bfd *abfd, unsigned int i);
+void bfd_set_gp_size (bfd *abfd, unsigned int i);
@end example
@strong{Description}@*
Set the maximum size of objects to be optimized using the GP
@@ -493,7 +457,7 @@ the @code{-G} argument to the compiler, assembler or linker.
@subsubsection @code{bfd_scan_vma}
@strong{Synopsis}
@example
-bfd_vma bfd_scan_vma(const char *string, const char **end, int base);
+bfd_vma bfd_scan_vma (const char *string, const char **end, int base);
@end example
@strong{Description}@*
Convert, like @code{strtoul}, a numerical expression
@@ -512,11 +476,11 @@ returned.
@subsubsection @code{bfd_copy_private_bfd_data}
@strong{Synopsis}
@example
-boolean bfd_copy_private_bfd_data(bfd *ibfd, bfd *obfd);
+bfd_boolean bfd_copy_private_bfd_data (bfd *ibfd, bfd *obfd);
@end example
@strong{Description}@*
Copy private BFD information from the BFD @var{ibfd} to the
-the BFD @var{obfd}. Return @code{true} on success, @code{false} on error.
+the BFD @var{obfd}. Return @code{TRUE} on success, @code{FALSE} on error.
Possible error returns are:
@itemize @bullet
@@ -535,12 +499,12 @@ Not enough memory exists to create private data for @var{obfd}.
@subsubsection @code{bfd_merge_private_bfd_data}
@strong{Synopsis}
@example
-boolean bfd_merge_private_bfd_data(bfd *ibfd, bfd *obfd);
+bfd_boolean bfd_merge_private_bfd_data (bfd *ibfd, bfd *obfd);
@end example
@strong{Description}@*
Merge private BFD information from the BFD @var{ibfd} to the
-the output file BFD @var{obfd} when linking. Return @code{true}
-on success, @code{false} on error. Possible error returns are:
+the output file BFD @var{obfd} when linking. Return @code{TRUE}
+on success, @code{FALSE} on error. Possible error returns are:
@itemize @bullet
@@ -558,11 +522,11 @@ Not enough memory exists to create private data for @var{obfd}.
@subsubsection @code{bfd_set_private_flags}
@strong{Synopsis}
@example
-boolean bfd_set_private_flags(bfd *abfd, flagword flags);
+bfd_boolean bfd_set_private_flags (bfd *abfd, flagword flags);
@end example
@strong{Description}@*
Set private BFD flag information in the BFD @var{abfd}.
-Return @code{true} on success, @code{false} on error. Possible error
+Return @code{TRUE} on success, @code{FALSE} on error. Possible error
returns are:
@itemize @bullet
@@ -573,40 +537,38 @@ Not enough memory exists to create private data for @var{obfd}.
@end itemize
@example
#define bfd_set_private_flags(abfd, flags) \
- BFD_SEND (abfd, _bfd_set_private_flags, \
- (abfd, flags))
+ BFD_SEND (abfd, _bfd_set_private_flags, (abfd, flags))
@end example
-@findex stuff
-@subsubsection @code{stuff}
+@findex Other functions
+@subsubsection @code{Other functions}
@strong{Description}@*
-Stuff which should be documented:
+The following functions exist but have not yet been documented.
@example
#define bfd_sizeof_headers(abfd, reloc) \
- BFD_SEND (abfd, _bfd_sizeof_headers, (abfd, reloc))
+ BFD_SEND (abfd, _bfd_sizeof_headers, (abfd, reloc))
#define bfd_find_nearest_line(abfd, sec, syms, off, file, func, line) \
- BFD_SEND (abfd, _bfd_find_nearest_line, (abfd, sec, syms, off, file, func, line))
+ BFD_SEND (abfd, _bfd_find_nearest_line, \
+ (abfd, sec, syms, off, file, func, line))
- /* Do these three do anything useful at all, for any back end? */
#define bfd_debug_info_start(abfd) \
- BFD_SEND (abfd, _bfd_debug_info_start, (abfd))
+ BFD_SEND (abfd, _bfd_debug_info_start, (abfd))
#define bfd_debug_info_end(abfd) \
- BFD_SEND (abfd, _bfd_debug_info_end, (abfd))
+ BFD_SEND (abfd, _bfd_debug_info_end, (abfd))
#define bfd_debug_info_accumulate(abfd, section) \
- BFD_SEND (abfd, _bfd_debug_info_accumulate, (abfd, section))
-
+ BFD_SEND (abfd, _bfd_debug_info_accumulate, (abfd, section))
#define bfd_stat_arch_elt(abfd, stat) \
- BFD_SEND (abfd, _bfd_stat_arch_elt,(abfd, stat))
+ BFD_SEND (abfd, _bfd_stat_arch_elt,(abfd, stat))
#define bfd_update_armap_timestamp(abfd) \
- BFD_SEND (abfd, _bfd_update_armap_timestamp, (abfd))
+ BFD_SEND (abfd, _bfd_update_armap_timestamp, (abfd))
#define bfd_set_arch_mach(abfd, arch, mach)\
- BFD_SEND ( abfd, _bfd_set_arch_mach, (abfd, arch, mach))
+ BFD_SEND ( abfd, _bfd_set_arch_mach, (abfd, arch, mach))
#define bfd_relax_section(abfd, section, link_info, again) \
BFD_SEND (abfd, _bfd_relax_section, (abfd, section, link_info, again))
@@ -654,9 +616,8 @@ Stuff which should be documented:
BFD_SEND (abfd, _bfd_canonicalize_dynamic_reloc, (abfd, arels, asyms))
extern bfd_byte *bfd_get_relocated_section_contents
- PARAMS ((bfd *, struct bfd_link_info *,
- struct bfd_link_order *, bfd_byte *,
- boolean, asymbol **));
+ (bfd *, struct bfd_link_info *, struct bfd_link_order *, bfd_byte *,
+ bfd_boolean, asymbol **);
@end example
@@ -664,7 +625,7 @@ extern bfd_byte *bfd_get_relocated_section_contents
@subsubsection @code{bfd_alt_mach_code}
@strong{Synopsis}
@example
-boolean bfd_alt_mach_code(bfd *abfd, int alternative);
+bfd_boolean bfd_alt_mach_code (bfd *abfd, int alternative);
@end example
@strong{Description}@*
When more than one machine code number is available for the
@@ -673,3 +634,57 @@ the preferred one (alternative == 0) and any others. Currently,
only ELF supports this feature, with up to two alternate
machine codes.
+
+@example
+struct bfd_preserve
+@{
+ void *marker;
+ void *tdata;
+ flagword flags;
+ const struct bfd_arch_info *arch_info;
+ struct bfd_section *sections;
+ struct bfd_section **section_tail;
+ unsigned int section_count;
+ struct bfd_hash_table section_htab;
+@};
+
+@end example
+@findex bfd_preserve_save
+@subsubsection @code{bfd_preserve_save}
+@strong{Synopsis}
+@example
+bfd_boolean bfd_preserve_save (bfd *, struct bfd_preserve *);
+@end example
+@strong{Description}@*
+When testing an object for compatibility with a particular
+target back-end, the back-end object_p function needs to set
+up certain fields in the bfd on successfully recognizing the
+object. This typically happens in a piecemeal fashion, with
+failures possible at many points. On failure, the bfd is
+supposed to be restored to its initial state, which is
+virtually impossible. However, restoring a subset of the bfd
+state works in practice. This function stores the subset and
+reinitializes the bfd.
+
+@findex bfd_preserve_restore
+@subsubsection @code{bfd_preserve_restore}
+@strong{Synopsis}
+@example
+void bfd_preserve_restore (bfd *, struct bfd_preserve *);
+@end example
+@strong{Description}@*
+This function restores bfd state saved by bfd_preserve_save.
+If MARKER is non-NULL in struct bfd_preserve then that block
+and all subsequently bfd_alloc'd memory is freed.
+
+@findex bfd_preserve_finish
+@subsubsection @code{bfd_preserve_finish}
+@strong{Synopsis}
+@example
+void bfd_preserve_finish (bfd *, struct bfd_preserve *);
+@end example
+@strong{Description}@*
+This function should be called when the bfd state saved by
+bfd_preserve_save is no longer needed. ie. when the back-end
+object_p function returns with success.
+
diff --git a/contrib/binutils/bfd/doc/bfdwin.texi b/contrib/binutils/bfd/doc/bfdwin.texi
new file mode 100644
index 0000000..b1fd7d5
--- /dev/null
+++ b/contrib/binutils/bfd/doc/bfdwin.texi
@@ -0,0 +1,2 @@
+@findex
+@subsubsection @code{}
diff --git a/contrib/binutils/bfd/doc/cache.texi b/contrib/binutils/bfd/doc/cache.texi
index 56d1f18..2bc3696 100644
--- a/contrib/binutils/bfd/doc/cache.texi
+++ b/contrib/binutils/bfd/doc/cache.texi
@@ -48,7 +48,7 @@ otherwise, it has to perform the complicated lookup function.
@subsubsection @code{bfd_cache_init}
@strong{Synopsis}
@example
-boolean bfd_cache_init (bfd *abfd);
+bfd_boolean bfd_cache_init (bfd *abfd);
@end example
@strong{Description}@*
Add a newly opened BFD to the cache.
@@ -57,21 +57,21 @@ Add a newly opened BFD to the cache.
@subsubsection @code{bfd_cache_close}
@strong{Synopsis}
@example
-boolean bfd_cache_close (bfd *abfd);
+bfd_boolean bfd_cache_close (bfd *abfd);
@end example
@strong{Description}@*
Remove the BFD @var{abfd} from the cache. If the attached file is open,
then close it too.
@strong{Returns}@*
-@code{false} is returned if closing the file fails, @code{true} is
+@code{FALSE} is returned if closing the file fails, @code{TRUE} is
returned if all is well.
@findex bfd_open_file
@subsubsection @code{bfd_open_file}
@strong{Synopsis}
@example
-FILE* bfd_open_file(bfd *abfd);
+FILE* bfd_open_file (bfd *abfd);
@end example
@strong{Description}@*
Call the OS to open a file for @var{abfd}. Return the @code{FILE *}
@@ -84,7 +84,7 @@ cache, so it won't have to be removed from it.
@subsubsection @code{bfd_cache_lookup_worker}
@strong{Synopsis}
@example
-FILE *bfd_cache_lookup_worker(bfd *abfd);
+FILE *bfd_cache_lookup_worker (bfd *abfd);
@end example
@strong{Description}@*
Called when the macro @code{bfd_cache_lookup} fails to find a
diff --git a/contrib/binutils/bfd/doc/chew.c b/contrib/binutils/bfd/doc/chew.c
index bdf76e4..7c060da 100644
--- a/contrib/binutils/bfd/doc/chew.c
+++ b/contrib/binutils/bfd/doc/chew.c
@@ -1,6 +1,6 @@
/* chew
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1998, 2000, 2001,
- 2002
+ 2002, 2003
Free Software Foundation, Inc.
Contributed by steve chamberlain @cygnus
@@ -494,8 +494,11 @@ paramstuff ()
string_type out;
init_string (&out);
+#define NO_PARAMS 1
+
/* Make sure that it's not already param'd or proto'd. */
- if (find (tos, "PARAMS") || find (tos, "PROTO") || !find (tos, "("))
+ if (NO_PARAMS
+ || find (tos, "PARAMS") || find (tos, "PROTO") || !find (tos, "("))
{
catstr (&out, tos);
}
diff --git a/contrib/binutils/bfd/doc/coffcode.texi b/contrib/binutils/bfd/doc/coffcode.texi
index 473747e..f9e15a6 100644
--- a/contrib/binutils/bfd/doc/coffcode.texi
+++ b/contrib/binutils/bfd/doc/coffcode.texi
@@ -188,7 +188,7 @@ section. This transformation uses the
This routine runs though the provided symbol table and uses
the offsets generated by the previous pass and the pointers
generated when the symbol table was read in to create the
-structured hierachy required by coff. It changes each pointer
+structured hierarchy required by coff. It changes each pointer
to a symbol into the index into the symbol table of the asymbol.
@itemize @bullet
@@ -259,7 +259,7 @@ typedef struct coff_symbol_struct
struct lineno_cache_entry *lineno;
/* Have the line numbers been relocated yet ? */
- boolean done_lineno;
+ bfd_boolean done_lineno;
@} coff_symbol_type;
@end example
@findex bfd_coff_backend_data
@@ -325,10 +325,10 @@ typedef struct
unsigned int _bfd_relsz;
unsigned int _bfd_linesz;
unsigned int _bfd_filnmlen;
- boolean _bfd_coff_long_filenames;
- boolean _bfd_coff_long_section_names;
+ bfd_boolean _bfd_coff_long_filenames;
+ bfd_boolean _bfd_coff_long_section_names;
unsigned int _bfd_coff_default_section_alignment_power;
- boolean _bfd_coff_force_symnames_in_strings;
+ bfd_boolean _bfd_coff_force_symnames_in_strings;
unsigned int _bfd_coff_debug_string_prefix_length;
void (*_bfd_coff_swap_filehdr_in)
@@ -343,32 +343,32 @@ typedef struct
void (*_bfd_coff_swap_reloc_in)
PARAMS ((bfd *abfd, PTR, PTR));
- boolean (*_bfd_coff_bad_format_hook)
+ bfd_boolean (*_bfd_coff_bad_format_hook)
PARAMS ((bfd *, PTR));
- boolean (*_bfd_coff_set_arch_mach_hook)
+ bfd_boolean (*_bfd_coff_set_arch_mach_hook)
PARAMS ((bfd *, PTR));
PTR (*_bfd_coff_mkobject_hook)
PARAMS ((bfd *, PTR, PTR));
- boolean (*_bfd_styp_to_sec_flags_hook)
+ bfd_boolean (*_bfd_styp_to_sec_flags_hook)
PARAMS ((bfd *, PTR, const char *, asection *, flagword *));
void (*_bfd_set_alignment_hook)
PARAMS ((bfd *, asection *, PTR));
- boolean (*_bfd_coff_slurp_symbol_table)
+ bfd_boolean (*_bfd_coff_slurp_symbol_table)
PARAMS ((bfd *));
- boolean (*_bfd_coff_symname_in_debug)
+ bfd_boolean (*_bfd_coff_symname_in_debug)
PARAMS ((bfd *, struct internal_syment *));
- boolean (*_bfd_coff_pointerize_aux_hook)
+ bfd_boolean (*_bfd_coff_pointerize_aux_hook)
PARAMS ((bfd *, combined_entry_type *, combined_entry_type *,
unsigned int, combined_entry_type *));
- boolean (*_bfd_coff_print_aux)
+ bfd_boolean (*_bfd_coff_print_aux)
PARAMS ((bfd *, FILE *, combined_entry_type *, combined_entry_type *,
combined_entry_type *, unsigned int));
@@ -383,13 +383,13 @@ typedef struct
enum coff_symbol_classification (*_bfd_coff_classify_symbol)
PARAMS ((bfd *, struct internal_syment *));
- boolean (*_bfd_coff_compute_section_file_positions)
+ bfd_boolean (*_bfd_coff_compute_section_file_positions)
PARAMS ((bfd *));
- boolean (*_bfd_coff_start_final_link)
+ bfd_boolean (*_bfd_coff_start_final_link)
PARAMS ((bfd *, struct bfd_link_info *));
- boolean (*_bfd_coff_relocate_section)
+ bfd_boolean (*_bfd_coff_relocate_section)
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
struct internal_reloc *, struct internal_syment *, asection **));
@@ -398,19 +398,19 @@ typedef struct
struct coff_link_hash_entry *, struct internal_syment *,
bfd_vma *));
- boolean (*_bfd_coff_adjust_symndx)
+ bfd_boolean (*_bfd_coff_adjust_symndx)
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *,
- struct internal_reloc *, boolean *));
+ struct internal_reloc *, bfd_boolean *));
- boolean (*_bfd_coff_link_add_one_symbol)
+ bfd_boolean (*_bfd_coff_link_add_one_symbol)
PARAMS ((struct bfd_link_info *, bfd *, const char *, flagword,
- asection *, bfd_vma, const char *, boolean, boolean,
+ asection *, bfd_vma, const char *, bfd_boolean, bfd_boolean,
struct bfd_link_hash_entry **));
- boolean (*_bfd_coff_link_output_has_begun)
+ bfd_boolean (*_bfd_coff_link_output_has_begun)
PARAMS ((bfd *, struct coff_final_link_info *));
- boolean (*_bfd_coff_final_link_postscript)
+ bfd_boolean (*_bfd_coff_final_link_postscript)
PARAMS ((bfd *, struct coff_final_link_info *));
@} bfd_coff_backend_data;
@@ -480,7 +480,8 @@ typedef struct
#define bfd_coff_set_arch_mach_hook(abfd, filehdr)\
((coff_backend_info (abfd)->_bfd_coff_set_arch_mach_hook) (abfd, filehdr))
#define bfd_coff_mkobject_hook(abfd, filehdr, aouthdr)\
- ((coff_backend_info (abfd)->_bfd_coff_mkobject_hook) (abfd, filehdr, aouthdr))
+ ((coff_backend_info (abfd)->_bfd_coff_mkobject_hook)\
+ (abfd, filehdr, aouthdr))
#define bfd_coff_styp_to_sec_flags_hook(abfd, scnhdr, name, section, flags_ptr)\
((coff_backend_info (abfd)->_bfd_styp_to_sec_flags_hook)\
@@ -505,7 +506,8 @@ typedef struct
((coff_backend_info (abfd)->_bfd_coff_print_aux)\
(abfd, file, base, symbol, aux, indaux))
-#define bfd_coff_reloc16_extra_cases(abfd, link_info, link_order, reloc, data, src_ptr, dst_ptr)\
+#define bfd_coff_reloc16_extra_cases(abfd, link_info, link_order,\
+ reloc, data, src_ptr, dst_ptr)\
((coff_backend_info (abfd)->_bfd_coff_reloc16_extra_cases)\
(abfd, link_info, link_order, reloc, data, src_ptr, dst_ptr))
@@ -533,7 +535,8 @@ typedef struct
#define bfd_coff_adjust_symndx(obfd, info, ibfd, sec, rel, adjustedp)\
((coff_backend_info (abfd)->_bfd_coff_adjust_symndx)\
(obfd, info, ibfd, sec, rel, adjustedp))
-#define bfd_coff_link_add_one_symbol(info,abfd,name,flags,section,value,string,cp,coll,hashp)\
+#define bfd_coff_link_add_one_symbol(info, abfd, name, flags, section,\
+ value, string, cp, coll, hashp)\
((coff_backend_info (abfd)->_bfd_coff_link_add_one_symbol)\
(info, abfd, name, flags, section, value, string, cp, coll, hashp))
diff --git a/contrib/binutils/bfd/doc/core.texi b/contrib/binutils/bfd/doc/core.texi
index 08a8c25..e45759c 100644
--- a/contrib/binutils/bfd/doc/core.texi
+++ b/contrib/binutils/bfd/doc/core.texi
@@ -8,7 +8,7 @@ These are functions pertaining to core files.
@subsubsection @code{bfd_core_file_failing_command}
@strong{Synopsis}
@example
-const char *bfd_core_file_failing_command(bfd *abfd);
+const char *bfd_core_file_failing_command (bfd *abfd);
@end example
@strong{Description}@*
Return a read-only string explaining which program was running
@@ -18,7 +18,7 @@ when it failed and produced the core file @var{abfd}.
@subsubsection @code{bfd_core_file_failing_signal}
@strong{Synopsis}
@example
-int bfd_core_file_failing_signal(bfd *abfd);
+int bfd_core_file_failing_signal (bfd *abfd);
@end example
@strong{Description}@*
Returns the signal number which caused the core dump which
@@ -28,11 +28,11 @@ generated the file the BFD @var{abfd} is attached to.
@subsubsection @code{core_file_matches_executable_p}
@strong{Synopsis}
@example
-boolean core_file_matches_executable_p
+bfd_boolean core_file_matches_executable_p
(bfd *core_bfd, bfd *exec_bfd);
@end example
@strong{Description}@*
-Return @code{true} if the core file attached to @var{core_bfd}
+Return @code{TRUE} if the core file attached to @var{core_bfd}
was generated by a run of the executable file attached to
-@var{exec_bfd}, @code{false} otherwise.
+@var{exec_bfd}, @code{FALSE} otherwise.
diff --git a/contrib/binutils/bfd/doc/fdl.texi b/contrib/binutils/bfd/doc/fdl.texi
new file mode 100644
index 0000000..176233c
--- /dev/null
+++ b/contrib/binutils/bfd/doc/fdl.texi
@@ -0,0 +1,366 @@
+@c -*-texinfo-*-
+@appendix GNU Free Documentation License
+@center Version 1.1, March 2000
+
+@display
+Copyright (C) 2000, Free Software Foundation, Inc.
+59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+Everyone is permitted to copy and distribute verbatim copies
+of this license document, but changing it is not allowed.
+@end display
+@sp 1
+@enumerate 0
+@item
+PREAMBLE
+
+The purpose of this License is to make a manual, textbook, or other
+written document ``free'' in the sense of freedom: to assure everyone
+the effective freedom to copy and redistribute it, with or without
+modifying it, either commercially or noncommercially. Secondarily,
+this License preserves for the author and publisher a way to get
+credit for their work, while not being considered responsible for
+modifications made by others.
+
+This License is a kind of ``copyleft'', which means that derivative
+works of the document must themselves be free in the same sense. It
+complements the GNU General Public License, which is a copyleft
+license designed for free software.
+
+We have designed this License in order to use it for manuals for free
+software, because free software needs free documentation: a free
+program should come with manuals providing the same freedoms that the
+software does. But this License is not limited to software manuals;
+it can be used for any textual work, regardless of subject matter or
+whether it is published as a printed book. We recommend this License
+principally for works whose purpose is instruction or reference.
+
+@sp 1
+@item
+APPLICABILITY AND DEFINITIONS
+
+This License applies to any manual or other work that contains a
+notice placed by the copyright holder saying it can be distributed
+under the terms of this License. The ``Document'', below, refers to any
+such manual or work. Any member of the public is a licensee, and is
+addressed as ``you.''
+
+A ``Modified Version'' of the Document means any work containing the
+Document or a portion of it, either copied verbatim, or with
+modifications and/or translated into another language.
+
+A ``Secondary Section'' is a named appendix or a front-matter section of
+the Document that deals exclusively with the relationship of the
+publishers or authors of the Document to the Document's overall subject
+(or to related matters) and contains nothing that could fall directly
+within that overall subject. (For example, if the Document is in part a
+textbook of mathematics, a Secondary Section may not explain any
+mathematics.) The relationship could be a matter of historical
+connection with the subject or with related matters, or of legal,
+commercial, philosophical, ethical or political position regarding
+them.
+
+The ``Invariant Sections'' are certain Secondary Sections whose titles
+are designated, as being those of Invariant Sections, in the notice
+that says that the Document is released under this License.
+
+The ``Cover Texts'' are certain short passages of text that are listed,
+as Front-Cover Texts or Back-Cover Texts, in the notice that says that
+the Document is released under this License.
+
+A ``Transparent'' copy of the Document means a machine-readable copy,
+represented in a format whose specification is available to the
+general public, whose contents can be viewed and edited directly and
+straightforwardly with generic text editors or (for images composed of
+pixels) generic paint programs or (for drawings) some widely available
+drawing editor, and that is suitable for input to text formatters or
+for automatic translation to a variety of formats suitable for input
+to text formatters. A copy made in an otherwise Transparent file
+format whose markup has been designed to thwart or discourage
+subsequent modification by readers is not Transparent. A copy that is
+not ``Transparent'' is called ``Opaque.''
+
+Examples of suitable formats for Transparent copies include plain
+ASCII without markup, Texinfo input format, LaTeX input format, SGML
+or XML using a publicly available DTD, and standard-conforming simple
+HTML designed for human modification. Opaque formats include
+PostScript, PDF, proprietary formats that can be read and edited only
+by proprietary word processors, SGML or XML for which the DTD and/or
+processing tools are not generally available, and the
+machine-generated HTML produced by some word processors for output
+purposes only.
+
+The ``Title Page'' means, for a printed book, the title page itself,
+plus such following pages as are needed to hold, legibly, the material
+this License requires to appear in the title page. For works in
+formats which do not have any title page as such, ``Title Page'' means
+the text near the most prominent appearance of the work's title,
+preceding the beginning of the body of the text.
+@sp 1
+@item
+VERBATIM COPYING
+
+You may copy and distribute the Document in any medium, either
+commercially or noncommercially, provided that this License, the
+copyright notices, and the license notice saying this License applies
+to the Document are reproduced in all copies, and that you add no other
+conditions whatsoever to those of this License. You may not use
+technical measures to obstruct or control the reading or further
+copying of the copies you make or distribute. However, you may accept
+compensation in exchange for copies. If you distribute a large enough
+number of copies you must also follow the conditions in section 3.
+
+You may also lend copies, under the same conditions stated above, and
+you may publicly display copies.
+@sp 1
+@item
+COPYING IN QUANTITY
+
+If you publish printed copies of the Document numbering more than 100,
+and the Document's license notice requires Cover Texts, you must enclose
+the copies in covers that carry, clearly and legibly, all these Cover
+Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on
+the back cover. Both covers must also clearly and legibly identify
+you as the publisher of these copies. The front cover must present
+the full title with all words of the title equally prominent and
+visible. You may add other material on the covers in addition.
+Copying with changes limited to the covers, as long as they preserve
+the title of the Document and satisfy these conditions, can be treated
+as verbatim copying in other respects.
+
+If the required texts for either cover are too voluminous to fit
+legibly, you should put the first ones listed (as many as fit
+reasonably) on the actual cover, and continue the rest onto adjacent
+pages.
+
+If you publish or distribute Opaque copies of the Document numbering
+more than 100, you must either include a machine-readable Transparent
+copy along with each Opaque copy, or state in or with each Opaque copy
+a publicly-accessible computer-network location containing a complete
+Transparent copy of the Document, free of added material, which the
+general network-using public has access to download anonymously at no
+charge using public-standard network protocols. If you use the latter
+option, you must take reasonably prudent steps, when you begin
+distribution of Opaque copies in quantity, to ensure that this
+Transparent copy will remain thus accessible at the stated location
+until at least one year after the last time you distribute an Opaque
+copy (directly or through your agents or retailers) of that edition to
+the public.
+
+It is requested, but not required, that you contact the authors of the
+Document well before redistributing any large number of copies, to give
+them a chance to provide you with an updated version of the Document.
+@sp 1
+@item
+MODIFICATIONS
+
+You may copy and distribute a Modified Version of the Document under
+the conditions of sections 2 and 3 above, provided that you release
+the Modified Version under precisely this License, with the Modified
+Version filling the role of the Document, thus licensing distribution
+and modification of the Modified Version to whoever possesses a copy
+of it. In addition, you must do these things in the Modified Version:
+
+A. Use in the Title Page (and on the covers, if any) a title distinct
+ from that of the Document, and from those of previous versions
+ (which should, if there were any, be listed in the History section
+ of the Document). You may use the same title as a previous version
+ if the original publisher of that version gives permission.@*
+B. List on the Title Page, as authors, one or more persons or entities
+ responsible for authorship of the modifications in the Modified
+ Version, together with at least five of the principal authors of the
+ Document (all of its principal authors, if it has less than five).@*
+C. State on the Title page the name of the publisher of the
+ Modified Version, as the publisher.@*
+D. Preserve all the copyright notices of the Document.@*
+E. Add an appropriate copyright notice for your modifications
+ adjacent to the other copyright notices.@*
+F. Include, immediately after the copyright notices, a license notice
+ giving the public permission to use the Modified Version under the
+ terms of this License, in the form shown in the Addendum below.@*
+G. Preserve in that license notice the full lists of Invariant Sections
+ and required Cover Texts given in the Document's license notice.@*
+H. Include an unaltered copy of this License.@*
+I. Preserve the section entitled ``History'', and its title, and add to
+ it an item stating at least the title, year, new authors, and
+ publisher of the Modified Version as given on the Title Page. If
+ there is no section entitled ``History'' in the Document, create one
+ stating the title, year, authors, and publisher of the Document as
+ given on its Title Page, then add an item describing the Modified
+ Version as stated in the previous sentence.@*
+J. Preserve the network location, if any, given in the Document for
+ public access to a Transparent copy of the Document, and likewise
+ the network locations given in the Document for previous versions
+ it was based on. These may be placed in the ``History'' section.
+ You may omit a network location for a work that was published at
+ least four years before the Document itself, or if the original
+ publisher of the version it refers to gives permission.@*
+K. In any section entitled ``Acknowledgements'' or ``Dedications'',
+ preserve the section's title, and preserve in the section all the
+ substance and tone of each of the contributor acknowledgements
+ and/or dedications given therein.@*
+L. Preserve all the Invariant Sections of the Document,
+ unaltered in their text and in their titles. Section numbers
+ or the equivalent are not considered part of the section titles.@*
+M. Delete any section entitled ``Endorsements.'' Such a section
+ may not be included in the Modified Version.@*
+N. Do not retitle any existing section as ``Endorsements''
+ or to conflict in title with any Invariant Section.@*
+@sp 1
+If the Modified Version includes new front-matter sections or
+appendices that qualify as Secondary Sections and contain no material
+copied from the Document, you may at your option designate some or all
+of these sections as invariant. To do this, add their titles to the
+list of Invariant Sections in the Modified Version's license notice.
+These titles must be distinct from any other section titles.
+
+You may add a section entitled ``Endorsements'', provided it contains
+nothing but endorsements of your Modified Version by various
+parties--for example, statements of peer review or that the text has
+been approved by an organization as the authoritative definition of a
+standard.
+
+You may add a passage of up to five words as a Front-Cover Text, and a
+passage of up to 25 words as a Back-Cover Text, to the end of the list
+of Cover Texts in the Modified Version. Only one passage of
+Front-Cover Text and one of Back-Cover Text may be added by (or
+through arrangements made by) any one entity. If the Document already
+includes a cover text for the same cover, previously added by you or
+by arrangement made by the same entity you are acting on behalf of,
+you may not add another; but you may replace the old one, on explicit
+permission from the previous publisher that added the old one.
+
+The author(s) and publisher(s) of the Document do not by this License
+give permission to use their names for publicity for or to assert or
+imply endorsement of any Modified Version.
+@sp 1
+@item
+COMBINING DOCUMENTS
+
+You may combine the Document with other documents released under this
+License, under the terms defined in section 4 above for modified
+versions, provided that you include in the combination all of the
+Invariant Sections of all of the original documents, unmodified, and
+list them all as Invariant Sections of your combined work in its
+license notice.
+
+The combined work need only contain one copy of this License, and
+multiple identical Invariant Sections may be replaced with a single
+copy. If there are multiple Invariant Sections with the same name but
+different contents, make the title of each such section unique by
+adding at the end of it, in parentheses, the name of the original
+author or publisher of that section if known, or else a unique number.
+Make the same adjustment to the section titles in the list of
+Invariant Sections in the license notice of the combined work.
+
+In the combination, you must combine any sections entitled ``History''
+in the various original documents, forming one section entitled
+``History''; likewise combine any sections entitled ``Acknowledgements'',
+and any sections entitled ``Dedications.'' You must delete all sections
+entitled ``Endorsements.''
+@sp 1
+@item
+COLLECTIONS OF DOCUMENTS
+
+You may make a collection consisting of the Document and other documents
+released under this License, and replace the individual copies of this
+License in the various documents with a single copy that is included in
+the collection, provided that you follow the rules of this License for
+verbatim copying of each of the documents in all other respects.
+
+You may extract a single document from such a collection, and distribute
+it individually under this License, provided you insert a copy of this
+License into the extracted document, and follow this License in all
+other respects regarding verbatim copying of that document.
+@sp 1
+@item
+AGGREGATION WITH INDEPENDENT WORKS
+
+A compilation of the Document or its derivatives with other separate
+and independent documents or works, in or on a volume of a storage or
+distribution medium, does not as a whole count as a Modified Version
+of the Document, provided no compilation copyright is claimed for the
+compilation. Such a compilation is called an ``aggregate'', and this
+License does not apply to the other self-contained works thus compiled
+with the Document, on account of their being thus compiled, if they
+are not themselves derivative works of the Document.
+
+If the Cover Text requirement of section 3 is applicable to these
+copies of the Document, then if the Document is less than one quarter
+of the entire aggregate, the Document's Cover Texts may be placed on
+covers that surround only the Document within the aggregate.
+Otherwise they must appear on covers around the whole aggregate.
+@sp 1
+@item
+TRANSLATION
+
+Translation is considered a kind of modification, so you may
+distribute translations of the Document under the terms of section 4.
+Replacing Invariant Sections with translations requires special
+permission from their copyright holders, but you may include
+translations of some or all Invariant Sections in addition to the
+original versions of these Invariant Sections. You may include a
+translation of this License provided that you also include the
+original English version of this License. In case of a disagreement
+between the translation and the original English version of this
+License, the original English version will prevail.
+@sp 1
+@item
+TERMINATION
+
+You may not copy, modify, sublicense, or distribute the Document except
+as expressly provided for under this License. Any other attempt to
+copy, modify, sublicense or distribute the Document is void, and will
+automatically terminate your rights under this License. However,
+parties who have received copies, or rights, from you under this
+License will not have their licenses terminated so long as such
+parties remain in full compliance.
+@sp 1
+@item
+FUTURE REVISIONS OF THIS LICENSE
+
+The Free Software Foundation may publish new, revised versions
+of the GNU Free Documentation License from time to time. Such new
+versions will be similar in spirit to the present version, but may
+differ in detail to address new problems or concerns. See
+http://www.gnu.org/copyleft/.
+
+Each version of the License is given a distinguishing version number.
+If the Document specifies that a particular numbered version of this
+License ``or any later version'' applies to it, you have the option of
+following the terms and conditions either of that specified version or
+of any later version that has been published (not as a draft) by the
+Free Software Foundation. If the Document does not specify a version
+number of this License, you may choose any version ever published (not
+as a draft) by the Free Software Foundation.
+
+@end enumerate
+
+@unnumberedsec ADDENDUM: How to use this License for your documents
+
+To use this License in a document you have written, include a copy of
+the License in the document and put the following copyright and
+license notices just after the title page:
+
+@smallexample
+@group
+Copyright (C) @var{year} @var{your name}.
+Permission is granted to copy, distribute and/or modify this document
+under the terms of the GNU Free Documentation License, Version 1.1
+or any later version published by the Free Software Foundation;
+with the Invariant Sections being @var{list their titles}, with the
+Front-Cover Texts being @var{list}, and with the Back-Cover Texts being @var{list}.
+A copy of the license is included in the section entitled "GNU
+Free Documentation License."
+@end group
+@end smallexample
+
+If you have no Invariant Sections, write ``with no Invariant Sections''
+instead of saying which ones are invariant. If you have no
+Front-Cover Texts, write ``no Front-Cover Texts'' instead of
+``Front-Cover Texts being @var{list}''; likewise for Back-Cover Texts.
+
+If your document contains nontrivial examples of program code, we
+recommend releasing these examples in parallel under your choice of
+free software license, such as the GNU General Public License,
+to permit their use in free software.
diff --git a/contrib/binutils/bfd/doc/format.texi b/contrib/binutils/bfd/doc/format.texi
index d64bba1..32a1d75 100644
--- a/contrib/binutils/bfd/doc/format.texi
+++ b/contrib/binutils/bfd/doc/format.texi
@@ -27,7 +27,7 @@ The BFD contains the result of an executable core dump.
@subsubsection @code{bfd_check_format}
@strong{Synopsis}
@example
-boolean bfd_check_format(bfd *abfd, bfd_format format);
+bfd_boolean bfd_check_format (bfd *abfd, bfd_format format);
@end example
@strong{Description}@*
Verify if the file attached to the BFD @var{abfd} is compatible
@@ -42,7 +42,7 @@ interrogated to determine a match. If the default target
matches, it is used. If not, exactly one target must recognize
the file, or an error results.
-The function returns @code{true} on success, otherwise @code{false}
+The function returns @code{TRUE} on success, otherwise @code{FALSE}
with one of the following error codes:
@itemize @bullet
@@ -70,10 +70,11 @@ more than one backend recognised the file format.
@subsubsection @code{bfd_check_format_matches}
@strong{Synopsis}
@example
-boolean bfd_check_format_matches(bfd *abfd, bfd_format format, char ***matching);
+bfd_boolean bfd_check_format_matches
+ (bfd *abfd, bfd_format format, char ***matching);
@end example
@strong{Description}@*
-Like @code{bfd_check_format}, except when it returns false with
+Like @code{bfd_check_format}, except when it returns FALSE with
@code{bfd_errno} set to @code{bfd_error_file_ambiguously_recognized}. In that
case, if @var{matching} is not NULL, it will be filled in with
a NULL-terminated list of the names of the formats that matched,
@@ -87,7 +88,7 @@ should free it.
@subsubsection @code{bfd_set_format}
@strong{Synopsis}
@example
-boolean bfd_set_format(bfd *abfd, bfd_format format);
+bfd_boolean bfd_set_format (bfd *abfd, bfd_format format);
@end example
@strong{Description}@*
This function sets the file format of the BFD @var{abfd} to the
@@ -99,7 +100,7 @@ is not open for writing, then an error occurs.
@subsubsection @code{bfd_format_string}
@strong{Synopsis}
@example
-const char *bfd_format_string(bfd_format format);
+const char *bfd_format_string (bfd_format format);
@end example
@strong{Description}@*
Return a pointer to a const string
diff --git a/contrib/binutils/bfd/doc/hash.texi b/contrib/binutils/bfd/doc/hash.texi
index eb87273..3e7372c 100644
--- a/contrib/binutils/bfd/doc/hash.texi
+++ b/contrib/binutils/bfd/doc/hash.texi
@@ -35,7 +35,7 @@ bfd_hash_table} (defined in @code{bfd.h}) and call
@code{bfd_hash_table_init} (if you know approximately how many
entries you will need, the function @code{bfd_hash_table_init_n},
which takes a @var{size} argument, may be used).
-@code{bfd_hash_table_init} returns @code{false} if some sort of
+@code{bfd_hash_table_init} returns @code{FALSE} if some sort of
error occurs.
@findex bfd_hash_newfunc
@@ -61,24 +61,24 @@ been allocated for a hash table. This will not free up the
The function @code{bfd_hash_lookup} is used both to look up a
string in the hash table and to create a new entry.
-If the @var{create} argument is @code{false}, @code{bfd_hash_lookup}
+If the @var{create} argument is @code{FALSE}, @code{bfd_hash_lookup}
will look up a string. If the string is found, it will
returns a pointer to a @code{struct bfd_hash_entry}. If the
string is not found in the table @code{bfd_hash_lookup} will
return @code{NULL}. You should not modify any of the fields in
the returns @code{struct bfd_hash_entry}.
-If the @var{create} argument is @code{true}, the string will be
+If the @var{create} argument is @code{TRUE}, the string will be
entered into the hash table if it is not already there.
Either way a pointer to a @code{struct bfd_hash_entry} will be
returned, either to the existing structure or to a newly
created one. In this case, a @code{NULL} return means that an
error occurred.
-If the @var{create} argument is @code{true}, and a new entry is
+If the @var{create} argument is @code{TRUE}, and a new entry is
created, the @var{copy} argument is used to decide whether to
copy the string onto the hash table objalloc or not. If
-@var{copy} is passed as @code{false}, you must be careful not to
+@var{copy} is passed as @code{FALSE}, you must be careful not to
deallocate or modify the string as long as the hash table
exists.
@@ -95,7 +95,7 @@ hash table entry (a @code{struct bfd_hash_entry *}) and the
generic pointer passed to @code{bfd_hash_traverse}. The function
must return a @code{boolean} value, which indicates whether to
continue traversing the hash table. If the function returns
-@code{false}, @code{bfd_hash_traverse} will stop the traversal and
+@code{FALSE}, @code{bfd_hash_traverse} will stop the traversal and
return immediately.
@node Deriving a New Hash Table Type, , Traversing a Hash Table, Hash Tables
diff --git a/contrib/binutils/bfd/doc/init.texi b/contrib/binutils/bfd/doc/init.texi
index e561a77..0905f6b 100644
--- a/contrib/binutils/bfd/doc/init.texi
+++ b/contrib/binutils/bfd/doc/init.texi
@@ -5,7 +5,7 @@ These are the functions that handle initializing a BFD.
@subsubsection @code{bfd_init}
@strong{Synopsis}
@example
-void bfd_init(void);
+void bfd_init (void);
@end example
@strong{Description}@*
This routine must be called before any other BFD function to
diff --git a/contrib/binutils/bfd/doc/libbfd.texi b/contrib/binutils/bfd/doc/libbfd.texi
index b28650f..5c9ced0 100644
--- a/contrib/binutils/bfd/doc/libbfd.texi
+++ b/contrib/binutils/bfd/doc/libbfd.texi
@@ -10,7 +10,7 @@ completeness.
@subsubsection @code{bfd_write_bigendian_4byte_int}
@strong{Synopsis}
@example
-boolean bfd_write_bigendian_4byte_int (bfd *, unsigned int);
+bfd_boolean bfd_write_bigendian_4byte_int (bfd *, unsigned int);
@end example
@strong{Description}@*
Write a 4 byte integer @var{i} to the output BFD @var{abfd}, in big
@@ -43,54 +43,54 @@ To detect calling these with less than a @code{bfd_vma}, use
/* Byte swapping macros for user section data. */
#define bfd_put_8(abfd, val, ptr) \
- ((void) (*((unsigned char *) (ptr)) = (unsigned char) (val)))
+ ((void) (*((unsigned char *) (ptr)) = (val) & 0xff))
#define bfd_put_signed_8 \
- bfd_put_8
+ bfd_put_8
#define bfd_get_8(abfd, ptr) \
- (*(unsigned char *) (ptr) & 0xff)
+ (*(unsigned char *) (ptr) & 0xff)
#define bfd_get_signed_8(abfd, ptr) \
- (((*(unsigned char *) (ptr) & 0xff) ^ 0x80) - 0x80)
+ (((*(unsigned char *) (ptr) & 0xff) ^ 0x80) - 0x80)
#define bfd_put_16(abfd, val, ptr) \
- BFD_SEND(abfd, bfd_putx16, ((val),(ptr)))
+ BFD_SEND (abfd, bfd_putx16, ((val),(ptr)))
#define bfd_put_signed_16 \
- bfd_put_16
+ bfd_put_16
#define bfd_get_16(abfd, ptr) \
- BFD_SEND(abfd, bfd_getx16, (ptr))
+ BFD_SEND (abfd, bfd_getx16, (ptr))
#define bfd_get_signed_16(abfd, ptr) \
- BFD_SEND (abfd, bfd_getx_signed_16, (ptr))
+ BFD_SEND (abfd, bfd_getx_signed_16, (ptr))
#define bfd_put_32(abfd, val, ptr) \
- BFD_SEND(abfd, bfd_putx32, ((val),(ptr)))
+ BFD_SEND (abfd, bfd_putx32, ((val),(ptr)))
#define bfd_put_signed_32 \
- bfd_put_32
+ bfd_put_32
#define bfd_get_32(abfd, ptr) \
- BFD_SEND(abfd, bfd_getx32, (ptr))
+ BFD_SEND (abfd, bfd_getx32, (ptr))
#define bfd_get_signed_32(abfd, ptr) \
- BFD_SEND(abfd, bfd_getx_signed_32, (ptr))
+ BFD_SEND (abfd, bfd_getx_signed_32, (ptr))
#define bfd_put_64(abfd, val, ptr) \
- BFD_SEND(abfd, bfd_putx64, ((val), (ptr)))
+ BFD_SEND (abfd, bfd_putx64, ((val), (ptr)))
#define bfd_put_signed_64 \
- bfd_put_64
+ bfd_put_64
#define bfd_get_64(abfd, ptr) \
- BFD_SEND(abfd, bfd_getx64, (ptr))
+ BFD_SEND (abfd, bfd_getx64, (ptr))
#define bfd_get_signed_64(abfd, ptr) \
- BFD_SEND(abfd, bfd_getx_signed_64, (ptr))
-
-#define bfd_get(bits, abfd, ptr) \
- ( (bits) == 8 ? (bfd_vma) bfd_get_8 (abfd, ptr) \
- : (bits) == 16 ? bfd_get_16 (abfd, ptr) \
- : (bits) == 32 ? bfd_get_32 (abfd, ptr) \
- : (bits) == 64 ? bfd_get_64 (abfd, ptr) \
- : (abort (), (bfd_vma) - 1))
-
-#define bfd_put(bits, abfd, val, ptr) \
- ( (bits) == 8 ? bfd_put_8 (abfd, val, ptr) \
- : (bits) == 16 ? bfd_put_16 (abfd, val, ptr) \
- : (bits) == 32 ? bfd_put_32 (abfd, val, ptr) \
- : (bits) == 64 ? bfd_put_64 (abfd, val, ptr) \
- : (abort (), (void) 0))
+ BFD_SEND (abfd, bfd_getx_signed_64, (ptr))
+
+#define bfd_get(bits, abfd, ptr) \
+ ((bits) == 8 ? (bfd_vma) bfd_get_8 (abfd, ptr) \
+ : (bits) == 16 ? bfd_get_16 (abfd, ptr) \
+ : (bits) == 32 ? bfd_get_32 (abfd, ptr) \
+ : (bits) == 64 ? bfd_get_64 (abfd, ptr) \
+ : (abort (), (bfd_vma) - 1))
+
+#define bfd_put(bits, abfd, val, ptr) \
+ ((bits) == 8 ? bfd_put_8 (abfd, val, ptr) \
+ : (bits) == 16 ? bfd_put_16 (abfd, val, ptr) \
+ : (bits) == 32 ? bfd_put_32 (abfd, val, ptr) \
+ : (bits) == 64 ? bfd_put_64 (abfd, val, ptr) \
+ : (abort (), (void) 0))
@end example
@@ -142,52 +142,24 @@ order and their data in little endian order.
#define bfd_h_get_signed_64(abfd, ptr) \
BFD_SEND (abfd, bfd_h_getx_signed_64, (ptr))
-/* Refinements on the above, which should eventually go away. Save
- cluttering the source with (bfd_vma) and (bfd_byte *) casts. */
-
-#define H_PUT_64(abfd, val, where) \
- bfd_h_put_64 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-
-#define H_PUT_32(abfd, val, where) \
- bfd_h_put_32 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-
-#define H_PUT_16(abfd, val, where) \
- bfd_h_put_16 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-
-#define H_PUT_8 bfd_h_put_8
-
-#define H_PUT_S64(abfd, val, where) \
- bfd_h_put_signed_64 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-
-#define H_PUT_S32(abfd, val, where) \
- bfd_h_put_signed_32 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-
-#define H_PUT_S16(abfd, val, where) \
- bfd_h_put_signed_16 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-
-#define H_PUT_S8 bfd_h_put_signed_8
-
-#define H_GET_64(abfd, where) \
- bfd_h_get_64 ((abfd), (bfd_byte *) (where))
-
-#define H_GET_32(abfd, where) \
- bfd_h_get_32 ((abfd), (bfd_byte *) (where))
-
-#define H_GET_16(abfd, where) \
- bfd_h_get_16 ((abfd), (bfd_byte *) (where))
-
-#define H_GET_8 bfd_h_get_8
-
-#define H_GET_S64(abfd, where) \
- bfd_h_get_signed_64 ((abfd), (bfd_byte *) (where))
-
-#define H_GET_S32(abfd, where) \
- bfd_h_get_signed_32 ((abfd), (bfd_byte *) (where))
-
-#define H_GET_S16(abfd, where) \
- bfd_h_get_signed_16 ((abfd), (bfd_byte *) (where))
-
-#define H_GET_S8 bfd_h_get_signed_8
+/* Aliases for the above, which should eventually go away. */
+
+#define H_PUT_64 bfd_h_put_64
+#define H_PUT_32 bfd_h_put_32
+#define H_PUT_16 bfd_h_put_16
+#define H_PUT_8 bfd_h_put_8
+#define H_PUT_S64 bfd_h_put_signed_64
+#define H_PUT_S32 bfd_h_put_signed_32
+#define H_PUT_S16 bfd_h_put_signed_16
+#define H_PUT_S8 bfd_h_put_signed_8
+#define H_GET_64 bfd_h_get_64
+#define H_GET_32 bfd_h_get_32
+#define H_GET_16 bfd_h_get_16
+#define H_GET_8 bfd_h_get_8
+#define H_GET_S64 bfd_h_get_signed_64
+#define H_GET_S32 bfd_h_get_signed_32
+#define H_GET_S16 bfd_h_get_signed_16
+#define H_GET_S8 bfd_h_get_signed_8
@end example
diff --git a/contrib/binutils/bfd/doc/linker.texi b/contrib/binutils/bfd/doc/linker.texi
index 5105cc7..f2e2bc1 100644
--- a/contrib/binutils/bfd/doc/linker.texi
+++ b/contrib/binutils/bfd/doc/linker.texi
@@ -55,7 +55,7 @@ however, some additional information will be needed.
For example, with each entry in the hash table the a.out
linker keeps the index the symbol has in the final output file
-(this index number is used so that when doing a relocateable
+(this index number is used so that when doing a relocatable
link the symbol index used in the output file can be quickly
filled in when copying over a reloc). The a.out linker code
defines the required structures and functions for a hash table
@@ -158,7 +158,7 @@ If the @code{_bfd_final_link} routine is also going to need to
read the symbol information, the @code{_bfd_link_add_symbols}
routine should save it somewhere attached to the object file
BFD. However, the information should only be saved if the
-@code{keep_memory} field of the @code{info} argument is true, so
+@code{keep_memory} field of the @code{info} argument is TRUE, so
that the @code{-no-keep-memory} linker switch is effective.
The a.out function which adds symbols from an object file is
@@ -229,7 +229,7 @@ which has several aspects. It must relocate the contents of
the input sections and copy the data into the output sections.
It must build an output symbol table including any local
symbols from the input files and the global symbols from the
-hash table. When producing relocateable output, it must
+hash table. When producing relocatable output, it must
modify the input relocs and write them into the output file.
There may also be object format dependent work to be done.
@@ -266,7 +266,7 @@ various input sections, fill constants, and, eventually, other
types of information. They also describe relocs that must be
created by the BFD backend, but do not correspond to any input
file; this is used to support -Ur, which builds constructors
-while generating a relocateable object file.
+while generating a relocatable object file.
@node Relocating the section contents, Writing the symbol table, Information provided by the linker, Performing the Final Link
@subsubsection Relocating the section contents
@@ -285,7 +285,7 @@ output section in terms of a section belonging to one of the
input files. The @code{_bfd_final_link} function should read the
contents of the section and any associated relocs, apply the
relocs to the section contents, and write out the modified
-section contents. If performing a relocateable link, the
+section contents. If performing a relocatable link, the
relocs themselves must also be modified and written out.
@findex _bfd_relocate_contents
@@ -352,7 +352,7 @@ file at the end of @code{NAME(aout,final_link)}.
@subsubsection @code{bfd_link_split_section}
@strong{Synopsis}
@example
-boolean bfd_link_split_section(bfd *abfd, asection *sec);
+bfd_boolean bfd_link_split_section (bfd *abfd, asection *sec);
@end example
@strong{Description}@*
Return nonzero if @var{sec} should be split during a
diff --git a/contrib/binutils/bfd/doc/mmo.texi b/contrib/binutils/bfd/doc/mmo.texi
new file mode 100644
index 0000000..c308952
--- /dev/null
+++ b/contrib/binutils/bfd/doc/mmo.texi
@@ -0,0 +1,365 @@
+@section mmo backend
+The mmo object format is used exclusively together with Professor
+Donald E.@: Knuth's educational 64-bit processor MMIX. The simulator
+@command{mmix} which is available at
+@url{http://www-cs-faculty.stanford.edu/~knuth/programs/mmix.tar.gz}
+understands this format. That package also includes a combined
+assembler and linker called @command{mmixal}. The mmo format has
+no advantages feature-wise compared to e.g. ELF. It is a simple
+non-relocatable object format with no support for archives or
+debugging information, except for symbol value information and
+line numbers (which is not yet implemented in BFD). See
+@url{http://www-cs-faculty.stanford.edu/~knuth/mmix.html} for more
+information about MMIX. The ELF format is used for intermediate
+object files in the BFD implementation.
+
+@c We want to xref the symbol table node. A feature in "chew"
+@c requires that "commands" do not contain spaces in the
+@c arguments. Hence the hyphen in "Symbol-table".
+@menu
+* File layout::
+* Symbol-table::
+* mmo section mapping::
+@end menu
+
+@node File layout, Symbol-table, mmo, mmo
+@subsection File layout
+The mmo file contents is not partitioned into named sections as
+with e.g.@: ELF. Memory areas is formed by specifying the
+location of the data that follows. Only the memory area
+@samp{0x0000@dots{}00} to @samp{0x01ff@dots{}ff} is executable, so
+it is used for code (and constants) and the area
+@samp{0x2000@dots{}00} to @samp{0x20ff@dots{}ff} is used for
+writable data. @xref{mmo section mapping}.
+
+Contents is entered as 32-bit words, xor:ed over previous
+contents, always zero-initialized. A word that starts with the
+byte @samp{0x98} forms a command called a @samp{lopcode}, where
+the next byte distinguished between the thirteen lopcodes. The
+two remaining bytes, called the @samp{Y} and @samp{Z} fields, or
+the @samp{YZ} field (a 16-bit big-endian number), are used for
+various purposes different for each lopcode. As documented in
+@url{http://www-cs-faculty.stanford.edu/~knuth/mmixal-intro.ps.gz},
+the lopcodes are:
+
+There is provision for specifying ``special data'' of 65536
+different types. We use type 80 (decimal), arbitrarily chosen the
+same as the ELF @code{e_machine} number for MMIX, filling it with
+section information normally found in ELF objects. @xref{mmo
+section mapping}.
+
+@table @code
+@item lop_quote
+0x98000001. The next word is contents, regardless of whether it
+starts with 0x98 or not.
+
+@item lop_loc
+0x9801YYZZ, where @samp{Z} is 1 or 2. This is a location
+directive, setting the location for the next data to the next
+32-bit word (for @math{Z = 1}) or 64-bit word (for @math{Z = 2}),
+plus @math{Y * 2^56}. Normally @samp{Y} is 0 for the text segment
+and 2 for the data segment.
+
+@item lop_skip
+0x9802YYZZ. Increase the current location by @samp{YZ} bytes.
+
+@item lop_fixo
+0x9803YYZZ, where @samp{Z} is 1 or 2. Store the current location
+as 64 bits into the location pointed to by the next 32-bit
+(@math{Z = 1}) or 64-bit (@math{Z = 2}) word, plus @math{Y *
+2^56}.
+
+@item lop_fixr
+0x9804YYZZ. @samp{YZ} is stored into the current location plus
+@math{2 - 4 * YZ}.
+
+@item lop_fixrx
+0x980500ZZ. @samp{Z} is 16 or 24. A value @samp{L} derived from
+the following 32-bit word are used in a manner similar to
+@samp{YZ} in lop_fixr: it is xor:ed into the current location
+minus @math{4 * L}. The first byte of the word is 0 or 1. If it
+is 1, then @math{L = (@var{lowest 24 bits of word}) - 2^Z}, if 0,
+then @math{L = (@var{lowest 24 bits of word})}.
+
+@item lop_file
+0x9806YYZZ. @samp{Y} is the file number, @samp{Z} is count of
+32-bit words. Set the file number to @samp{Y} and the line
+counter to 0. The next @math{Z * 4} bytes contain the file name,
+padded with zeros if the count is not a multiple of four. The
+same @samp{Y} may occur multiple times, but @samp{Z} must be 0 for
+all but the first occurrence.
+
+@item lop_line
+0x9807YYZZ. @samp{YZ} is the line number. Together with
+lop_file, it forms the source location for the next 32-bit word.
+Note that for each non-lopcode 32-bit word, line numbers are
+assumed incremented by one.
+
+@item lop_spec
+0x9808YYZZ. @samp{YZ} is the type number. Data until the next
+lopcode other than lop_quote forms special data of type @samp{YZ}.
+@xref{mmo section mapping}.
+
+Other types than 80, (or type 80 with a content that does not
+parse) is stored in sections named @code{.MMIX.spec_data.@var{n}}
+where @var{n} is the @samp{YZ}-type. The flags for such a
+sections say not to allocate or load the data. The vma is 0.
+Contents of multiple occurrences of special data @var{n} is
+concatenated to the data of the previous lop_spec @var{n}s. The
+location in data or code at which the lop_spec occurred is lost.
+
+@item lop_pre
+0x980901ZZ. The first lopcode in a file. The @samp{Z} field forms the
+length of header information in 32-bit words, where the first word
+tells the time in seconds since @samp{00:00:00 GMT Jan 1 1970}.
+
+@item lop_post
+0x980a00ZZ. @math{Z > 32}. This lopcode follows after all
+content-generating lopcodes in a program. The @samp{Z} field
+denotes the value of @samp{rG} at the beginning of the program.
+The following @math{256 - Z} big-endian 64-bit words are loaded
+into global registers @samp{$G} @dots{} @samp{$255}.
+
+@item lop_stab
+0x980b0000. The next-to-last lopcode in a program. Must follow
+immediately after the lop_post lopcode and its data. After this
+lopcode follows all symbols in a compressed format
+(@pxref{Symbol-table}).
+
+@item lop_end
+0x980cYYZZ. The last lopcode in a program. It must follow the
+lop_stab lopcode and its data. The @samp{YZ} field contains the
+number of 32-bit words of symbol table information after the
+preceding lop_stab lopcode.
+@end table
+
+Note that the lopcode "fixups"; @code{lop_fixr}, @code{lop_fixrx} and
+@code{lop_fixo} are not generated by BFD, but are handled. They are
+generated by @code{mmixal}.
+
+This trivial one-label, one-instruction file:
+
+@example
+ :Main TRAP 1,2,3
+@end example
+
+can be represented this way in mmo:
+
+@example
+ 0x98090101 - lop_pre, one 32-bit word with timestamp.
+ <timestamp>
+ 0x98010002 - lop_loc, text segment, using a 64-bit address.
+ Note that mmixal does not emit this for the file above.
+ 0x00000000 - Address, high 32 bits.
+ 0x00000000 - Address, low 32 bits.
+ 0x98060002 - lop_file, 2 32-bit words for file-name.
+ 0x74657374 - "test"
+ 0x2e730000 - ".s\0\0"
+ 0x98070001 - lop_line, line 1.
+ 0x00010203 - TRAP 1,2,3
+ 0x980a00ff - lop_post, setting $255 to 0.
+ 0x00000000
+ 0x00000000
+ 0x980b0000 - lop_stab for ":Main" = 0, serial 1.
+ 0x203a4040 @xref{Symbol-table}.
+ 0x10404020
+ 0x4d206120
+ 0x69016e00
+ 0x81000000
+ 0x980c0005 - lop_end; symbol table contained five 32-bit words.
+@end example
+@node Symbol-table, mmo section mapping, File layout, mmo
+@subsection Symbol table format
+From mmixal.w (or really, the generated mmixal.tex) in
+@url{http://www-cs-faculty.stanford.edu/~knuth/programs/mmix.tar.gz}):
+``Symbols are stored and retrieved by means of a @samp{ternary
+search trie}, following ideas of Bentley and Sedgewick. (See
+ACM--SIAM Symp.@: on Discrete Algorithms @samp{8} (1997), 360--369;
+R.@:Sedgewick, @samp{Algorithms in C} (Reading, Mass.@:
+Addison--Wesley, 1998), @samp{15.4}.) Each trie node stores a
+character, and there are branches to subtries for the cases where
+a given character is less than, equal to, or greater than the
+character in the trie. There also is a pointer to a symbol table
+entry if a symbol ends at the current node.''
+
+So it's a tree encoded as a stream of bytes. The stream of bytes
+acts on a single virtual global symbol, adding and removing
+characters and signalling complete symbol points. Here, we read
+the stream and create symbols at the completion points.
+
+First, there's a control byte @code{m}. If any of the listed bits
+in @code{m} is nonzero, we execute what stands at the right, in
+the listed order:
+
+@example
+ (MMO3_LEFT)
+ 0x40 - Traverse left trie.
+ (Read a new command byte and recurse.)
+
+ (MMO3_SYMBITS)
+ 0x2f - Read the next byte as a character and store it in the
+ current character position; increment character position.
+ Test the bits of @code{m}:
+
+ (MMO3_WCHAR)
+ 0x80 - The character is 16-bit (so read another byte,
+ merge into current character.
+
+ (MMO3_TYPEBITS)
+ 0xf - We have a complete symbol; parse the type, value
+ and serial number and do what should be done
+ with a symbol. The type and length information
+ is in j = (m & 0xf).
+
+ (MMO3_REGQUAL_BITS)
+ j == 0xf: A register variable. The following
+ byte tells which register.
+ j <= 8: An absolute symbol. Read j bytes as the
+ big-endian number the symbol equals.
+ A j = 2 with two zero bytes denotes an
+ unknown symbol.
+ j > 8: As with j <= 8, but add (0x20 << 56)
+ to the value in the following j - 8
+ bytes.
+
+ Then comes the serial number, as a variant of
+ uleb128, but better named ubeb128:
+ Read bytes and shift the previous value left 7
+ (multiply by 128). Add in the new byte, repeat
+ until a byte has bit 7 set. The serial number
+ is the computed value minus 128.
+
+ (MMO3_MIDDLE)
+ 0x20 - Traverse middle trie. (Read a new command byte
+ and recurse.) Decrement character position.
+
+ (MMO3_RIGHT)
+ 0x10 - Traverse right trie. (Read a new command byte and
+ recurse.)
+@end example
+
+Let's look again at the @code{lop_stab} for the trivial file
+(@pxref{File layout}).
+
+@example
+ 0x980b0000 - lop_stab for ":Main" = 0, serial 1.
+ 0x203a4040
+ 0x10404020
+ 0x4d206120
+ 0x69016e00
+ 0x81000000
+@end example
+
+This forms the trivial trie (note that the path between ``:'' and
+``M'' is redundant):
+
+@example
+ 203a ":"
+ 40 /
+ 40 /
+ 10 \
+ 40 /
+ 40 /
+ 204d "M"
+ 2061 "a"
+ 2069 "i"
+ 016e "n" is the last character in a full symbol, and
+ with a value represented in one byte.
+ 00 The value is 0.
+ 81 The serial number is 1.
+@end example
+
+@node mmo section mapping, , Symbol-table, mmo
+@subsection mmo section mapping
+The implementation in BFD uses special data type 80 (decimal) to
+encapsulate and describe named sections, containing e.g.@: debug
+information. If needed, any datum in the encapsulation will be
+quoted using lop_quote. First comes a 32-bit word holding the
+number of 32-bit words containing the zero-terminated zero-padded
+segment name. After the name there's a 32-bit word holding flags
+describing the section type. Then comes a 64-bit big-endian word
+with the section length (in bytes), then another with the section
+start address. Depending on the type of section, the contents
+might follow, zero-padded to 32-bit boundary. For a loadable
+section (such as data or code), the contents might follow at some
+later point, not necessarily immediately, as a lop_loc with the
+same start address as in the section description, followed by the
+contents. This in effect forms a descriptor that must be emitted
+before the actual contents. Sections described this way must not
+overlap.
+
+For areas that don't have such descriptors, synthetic sections are
+formed by BFD. Consecutive contents in the two memory areas
+@samp{0x0000@dots{}00} to @samp{0x01ff@dots{}ff} and
+@samp{0x2000@dots{}00} to @samp{0x20ff@dots{}ff} are entered in
+sections named @code{.text} and @code{.data} respectively. If an area
+is not otherwise described, but would together with a neighboring
+lower area be less than @samp{0x40000000} bytes long, it is joined
+with the lower area and the gap is zero-filled. For other cases,
+a new section is formed, named @code{.MMIX.sec.@var{n}}. Here,
+@var{n} is a number, a running count through the mmo file,
+starting at 0.
+
+A loadable section specified as:
+
+@example
+ .section secname,"ax"
+ TETRA 1,2,3,4,-1,-2009
+ BYTE 80
+@end example
+
+and linked to address @samp{0x4}, is represented by the sequence:
+
+@example
+ 0x98080050 - lop_spec 80
+ 0x00000002 - two 32-bit words for the section name
+ 0x7365636e - "secn"
+ 0x616d6500 - "ame\0"
+ 0x00000033 - flags CODE, READONLY, LOAD, ALLOC
+ 0x00000000 - high 32 bits of section length
+ 0x0000001c - section length is 28 bytes; 6 * 4 + 1 + alignment to 32 bits
+ 0x00000000 - high 32 bits of section address
+ 0x00000004 - section address is 4
+ 0x98010002 - 64 bits with address of following data
+ 0x00000000 - high 32 bits of address
+ 0x00000004 - low 32 bits: data starts at address 4
+ 0x00000001 - 1
+ 0x00000002 - 2
+ 0x00000003 - 3
+ 0x00000004 - 4
+ 0xffffffff - -1
+ 0xfffff827 - -2009
+ 0x50000000 - 80 as a byte, padded with zeros.
+@end example
+
+Note that the lop_spec wrapping does not include the section
+contents. Compare this to a non-loaded section specified as:
+
+@example
+ .section thirdsec
+ TETRA 200001,100002
+ BYTE 38,40
+@end example
+
+This, when linked to address @samp{0x200000000000001c}, is
+represented by:
+
+@example
+ 0x98080050 - lop_spec 80
+ 0x00000002 - two 32-bit words for the section name
+ 0x7365636e - "thir"
+ 0x616d6500 - "dsec"
+ 0x00000010 - flag READONLY
+ 0x00000000 - high 32 bits of section length
+ 0x0000000c - section length is 12 bytes; 2 * 4 + 2 + alignment to 32 bits
+ 0x20000000 - high 32 bits of address
+ 0x0000001c - low 32 bits of address 0x200000000000001c
+ 0x00030d41 - 200001
+ 0x000186a2 - 100002
+ 0x26280000 - 38, 40 as bytes, padded with zeros
+@end example
+
+For the latter example, the section contents must not be
+loaded in memory, and is therefore specified as part of the
+special data. The address is usually unimportant but might
+provide information for e.g.@: the DWARF 2 debugging format.
diff --git a/contrib/binutils/bfd/doc/opncls.texi b/contrib/binutils/bfd/doc/opncls.texi
index 6c778f9..8cd2ab9 100644
--- a/contrib/binutils/bfd/doc/opncls.texi
+++ b/contrib/binutils/bfd/doc/opncls.texi
@@ -5,7 +5,7 @@
@subsubsection @code{bfd_openr}
@strong{Synopsis}
@example
-bfd *bfd_openr(const char *filename, const char *target);
+bfd *bfd_openr (const char *filename, const char *target);
@end example
@strong{Description}@*
Open the file @var{filename} (using @code{fopen}) with the target
@@ -15,37 +15,38 @@ Calls @code{bfd_find_target}, so @var{target} is interpreted as by
that function.
If @code{NULL} is returned then an error has occured. Possible errors
-are @code{bfd_error_no_memory}, @code{bfd_error_invalid_target} or @code{system_call} error.
+are @code{bfd_error_no_memory}, @code{bfd_error_invalid_target} or
+@code{system_call} error.
@findex bfd_fdopenr
@subsubsection @code{bfd_fdopenr}
@strong{Synopsis}
@example
-bfd *bfd_fdopenr(const char *filename, const char *target, int fd);
+bfd *bfd_fdopenr (const char *filename, const char *target, int fd);
@end example
@strong{Description}@*
-@code{bfd_fdopenr} is to @code{bfd_fopenr} much like @code{fdopen} is to @code{fopen}.
-It opens a BFD on a file already described by the @var{fd}
-supplied.
+@code{bfd_fdopenr} is to @code{bfd_fopenr} much like @code{fdopen} is to
+@code{fopen}. It opens a BFD on a file already described by the
+@var{fd} supplied.
-When the file is later @code{bfd_close}d, the file descriptor will be closed.
+When the file is later @code{bfd_close}d, the file descriptor will
+be closed. If the caller desires that this file descriptor be
+cached by BFD (opened as needed, closed as needed to free
+descriptors for other opens), with the supplied @var{fd} used as
+an initial file descriptor (but subject to closure at any time),
+call bfd_set_cacheable(bfd, 1) on the returned BFD. The default
+is to assume no caching; the file descriptor will remain open
+until @code{bfd_close}, and will not be affected by BFD operations
+on other files.
-If the caller desires that this file descriptor be cached by BFD
-(opened as needed, closed as needed to free descriptors for
-other opens), with the supplied @var{fd} used as an initial
-file descriptor (but subject to closure at any time), call
-bfd_set_cacheable(bfd, 1) on the returned BFD. The default is to
-assume no cacheing; the file descriptor will remain open until
-@code{bfd_close}, and will not be affected by BFD operations on other
-files.
-
-Possible errors are @code{bfd_error_no_memory}, @code{bfd_error_invalid_target} and @code{bfd_error_system_call}.
+Possible errors are @code{bfd_error_no_memory},
+@code{bfd_error_invalid_target} and @code{bfd_error_system_call}.
@findex bfd_openstreamr
@subsubsection @code{bfd_openstreamr}
@strong{Synopsis}
@example
-bfd *bfd_openstreamr(const char *, const char *, PTR);
+bfd *bfd_openstreamr (const char *, const char *, void *);
@end example
@strong{Description}@*
Open a BFD for read access on an existing stdio stream. When
@@ -55,7 +56,7 @@ the BFD is passed to @code{bfd_close}, the stream will be closed.
@subsubsection @code{bfd_openw}
@strong{Synopsis}
@example
-bfd *bfd_openw(const char *filename, const char *target);
+bfd *bfd_openw (const char *filename, const char *target);
@end example
@strong{Description}@*
Create a BFD, associated with file @var{filename}, using the
@@ -68,13 +69,13 @@ Possible errors are @code{bfd_error_system_call}, @code{bfd_error_no_memory},
@subsubsection @code{bfd_close}
@strong{Synopsis}
@example
-boolean bfd_close(bfd *abfd);
+bfd_boolean bfd_close (bfd *abfd);
@end example
@strong{Description}@*
-Close a BFD. If the BFD was open for writing,
-then pending operations are completed and the file written out
-and closed. If the created file is executable, then
-@code{chmod} is called to mark it as such.
+Close a BFD. If the BFD was open for writing, then pending
+operations are completed and the file written out and closed.
+If the created file is executable, then @code{chmod} is called
+to mark it as such.
All memory attached to the BFD is released.
@@ -82,19 +83,19 @@ The file descriptor associated with the BFD is closed (even
if it was passed in to BFD by @code{bfd_fdopenr}).
@strong{Returns}@*
-@code{true} is returned if all is ok, otherwise @code{false}.
+@code{TRUE} is returned if all is ok, otherwise @code{FALSE}.
@findex bfd_close_all_done
@subsubsection @code{bfd_close_all_done}
@strong{Synopsis}
@example
-boolean bfd_close_all_done(bfd *);
+bfd_boolean bfd_close_all_done (bfd *);
@end example
@strong{Description}@*
-Close a BFD. Differs from @code{bfd_close}
-since it does not complete any pending operations. This
-routine would be used if the application had just used BFD for
-swapping and didn't want to use any of the writing code.
+Close a BFD. Differs from @code{bfd_close} since it does not
+complete any pending operations. This routine would be used
+if the application had just used BFD for swapping and didn't
+want to use any of the writing code.
If the created file is executable, then @code{chmod} is called
to mark it as such.
@@ -102,25 +103,24 @@ to mark it as such.
All memory attached to the BFD is released.
@strong{Returns}@*
-@code{true} is returned if all is ok, otherwise @code{false}.
+@code{TRUE} is returned if all is ok, otherwise @code{FALSE}.
@findex bfd_create
@subsubsection @code{bfd_create}
@strong{Synopsis}
@example
-bfd *bfd_create(const char *filename, bfd *templ);
+bfd *bfd_create (const char *filename, bfd *templ);
@end example
@strong{Description}@*
-Create a new BFD in the manner of
-@code{bfd_openw}, but without opening a file. The new BFD
-takes the target from the target used by @var{template}. The
-format is always set to @code{bfd_object}.
+Create a new BFD in the manner of @code{bfd_openw}, but without
+opening a file. The new BFD takes the target from the target
+used by @var{template}. The format is always set to @code{bfd_object}.
@findex bfd_make_writable
@subsubsection @code{bfd_make_writable}
@strong{Synopsis}
@example
-boolean bfd_make_writable(bfd *abfd);
+bfd_boolean bfd_make_writable (bfd *abfd);
@end example
@strong{Description}@*
Takes a BFD as created by @code{bfd_create} and converts it
@@ -129,13 +129,13 @@ by converting the BFD to BFD_IN_MEMORY. It's assumed that
you will call @code{bfd_make_readable} on this bfd later.
@strong{Returns}@*
-@code{true} is returned if all is ok, otherwise @code{false}.
+@code{TRUE} is returned if all is ok, otherwise @code{FALSE}.
@findex bfd_make_readable
@subsubsection @code{bfd_make_readable}
@strong{Synopsis}
@example
-boolean bfd_make_readable(bfd *abfd);
+bfd_boolean bfd_make_readable (bfd *abfd);
@end example
@strong{Description}@*
Takes a BFD as created by @code{bfd_create} and
@@ -145,15 +145,121 @@ contents out to the memory buffer, then reversing the
direction.
@strong{Returns}@*
-@code{true} is returned if all is ok, otherwise @code{false}.
+@code{TRUE} is returned if all is ok, otherwise @code{FALSE}.
@findex bfd_alloc
@subsubsection @code{bfd_alloc}
@strong{Synopsis}
@example
-PTR bfd_alloc (bfd *abfd, size_t wanted);
+void *bfd_alloc (bfd *abfd, size_t wanted);
@end example
@strong{Description}@*
Allocate a block of @var{wanted} bytes of memory attached to
@code{abfd} and return a pointer to it.
+@findex bfd_calc_gnu_debuglink_crc32
+@subsubsection @code{bfd_calc_gnu_debuglink_crc32}
+@strong{Synopsis}
+@example
+unsigned long bfd_calc_gnu_debuglink_crc32
+ (unsigned long crc, const unsigned char *buf, bfd_size_type len);
+@end example
+@strong{Description}@*
+Computes a CRC value as used in the .gnu_debuglink section.
+Advances the previously computed @var{crc} value by computing
+and adding in the crc32 for @var{len} bytes of @var{buf}.
+
+@strong{Returns}@*
+Return the updated CRC32 value.
+
+@findex get_debug_link_info
+@subsubsection @code{get_debug_link_info}
+@strong{Synopsis}
+@example
+char *get_debug_link_info (bfd *abfd, unsigned long *crc32_out);
+@end example
+@strong{Description}@*
+fetch the filename and CRC32 value for any separate debuginfo
+associated with @var{abfd}. Return NULL if no such info found,
+otherwise return filename and update @var{crc32_out}.
+
+@findex separate_debug_file_exists
+@subsubsection @code{separate_debug_file_exists}
+@strong{Synopsis}
+@example
+bfd_boolean separate_debug_file_exists
+ (char *name, unsigned long crc32);
+@end example
+@strong{Description}@*
+Checks to see if @var{name} is a file and if its contents
+match @var{crc32}.
+
+@findex find_separate_debug_file
+@subsubsection @code{find_separate_debug_file}
+@strong{Synopsis}
+@example
+char *find_separate_debug_file (bfd *abfd);
+@end example
+@strong{Description}@*
+Searches @var{abfd} for a reference to separate debugging
+information, scans various locations in the filesystem, including
+the file tree rooted at @var{debug_file_directory}, and returns a
+filename of such debugging information if the file is found and has
+matching CRC32. Returns NULL if no reference to debugging file
+exists, or file cannot be found.
+
+@findex bfd_follow_gnu_debuglink
+@subsubsection @code{bfd_follow_gnu_debuglink}
+@strong{Synopsis}
+@example
+char *bfd_follow_gnu_debuglink (bfd *abfd, const char *dir);
+@end example
+@strong{Description}@*
+Takes a BFD and searches it for a .gnu_debuglink section. If this
+section is found, it examines the section for the name and checksum
+of a '.debug' file containing auxiliary debugging information. It
+then searches the filesystem for this .debug file in some standard
+locations, including the directory tree rooted at @var{dir}, and if
+found returns the full filename.
+
+If @var{dir} is NULL, it will search a default path configured into
+libbfd at build time. [XXX this feature is not currently
+implemented].
+
+@strong{Returns}@*
+@code{NULL} on any errors or failure to locate the .debug file,
+otherwise a pointer to a heap-allocated string containing the
+filename. The caller is responsible for freeing this string.
+
+@findex bfd_create_gnu_debuglink_section
+@subsubsection @code{bfd_create_gnu_debuglink_section}
+@strong{Synopsis}
+@example
+struct bfd_section *bfd_create_gnu_debuglink_section
+ (bfd *abfd, const char *filename);
+@end example
+@strong{Description}@*
+Takes a @var{BFD} and adds a .gnu_debuglink section to it. The section is sized
+to be big enough to contain a link to the specified @var{filename}.
+
+@strong{Returns}@*
+A pointer to the new section is returned if all is ok. Otherwise @code{NULL} is
+returned and bfd_error is set.
+
+@findex bfd_fill_in_gnu_debuglink_section
+@subsubsection @code{bfd_fill_in_gnu_debuglink_section}
+@strong{Synopsis}
+@example
+bfd_boolean bfd_fill_in_gnu_debuglink_section
+ (bfd *abfd, struct bfd_section *sect, const char *filename);
+@end example
+@strong{Description}@*
+Takes a @var{BFD} and containing a .gnu_debuglink section @var{SECT}
+and fills in the contents of the section to contain a link to the
+specified @var{filename}. The filename should be relative to the
+current directory.
+
+@strong{Returns}@*
+@code{TRUE} is returned if all is ok. Otherwise @code{FALSE} is returned
+and bfd_error is set.
+
diff --git a/contrib/binutils/bfd/doc/reloc.texi b/contrib/binutils/bfd/doc/reloc.texi
index 1ebd430..9253a33 100644
--- a/contrib/binutils/bfd/doc/reloc.texi
+++ b/contrib/binutils/bfd/doc/reloc.texi
@@ -60,7 +60,7 @@ typedef enum bfd_reloc_status
typedef struct reloc_cache_entry
@{
/* A pointer into the canonical table of pointers. */
- struct symbol_cache_entry **sym_ptr_ptr;
+ struct bfd_symbol **sym_ptr_ptr;
/* offset in section. */
bfd_size_type address;
@@ -84,15 +84,16 @@ Here is a description of each of the fields within an @code{arelent}:
@code{sym_ptr_ptr}
@end itemize
The symbol table pointer points to a pointer to the symbol
-associated with the relocation request. It is
-the pointer into the table returned by the back end's
-@code{get_symtab} action. @xref{Symbols}. The symbol is referenced
-through a pointer to a pointer so that tools like the linker
-can fix up all the symbols of the same name by modifying only
-one pointer. The relocation routine looks in the symbol and
-uses the base of the section the symbol is attached to and the
-value of the symbol as the initial relocation offset. If the
-symbol pointer is zero, then the section provided is looked up.
+associated with the relocation request. It is the pointer
+into the table returned by the back end's
+@code{canonicalize_symtab} action. @xref{Symbols}. The symbol is
+referenced through a pointer to a pointer so that tools like
+the linker can fix up all the symbols of the same name by
+modifying only one pointer. The relocation routine looks in
+the symbol and uses the base of the section the symbol is
+attached to and the value of the symbol as the initial
+relocation offset. If the symbol pointer is zero, then the
+section provided is looked up.
@itemize @bullet
@@ -254,7 +255,7 @@ information that libbfd needs to know to tie up a back end's data.
@example
-struct symbol_cache_entry; /* Forward declaration. */
+struct bfd_symbol; /* Forward declaration. */
struct reloc_howto_struct
@{
@@ -283,7 +284,7 @@ struct reloc_howto_struct
data section of the addend. The relocation function will
subtract from the relocation value the address of the location
being relocated. */
- boolean pc_relative;
+ bfd_boolean pc_relative;
/* The bit position of the reloc value in the destination.
The relocated value is left shifted by this amount. */
@@ -295,11 +296,11 @@ struct reloc_howto_struct
/* If this field is non null, then the supplied function is
called rather than the normal function. This allows really
- strange relocation methods to be accomodated (e.g., i960 callj
+ strange relocation methods to be accommodated (e.g., i960 callj
instructions). */
bfd_reloc_status_type (*special_function)
- PARAMS ((bfd *, arelent *, struct symbol_cache_entry *, PTR, asection *,
- bfd *, char **));
+ (bfd *, arelent *, struct bfd_symbol *, void *, asection *,
+ bfd *, char **);
/* The textual name of the relocation type. */
char *name;
@@ -319,21 +320,20 @@ struct reloc_howto_struct
USE_REL targets set this field to TRUE. Why this is so is peculiar
to each particular target. For relocs that aren't used in partial
links (e.g. GOT stuff) it doesn't matter what this is set to. */
- boolean partial_inplace;
-
- /* The src_mask selects which parts of the read in data
- are to be used in the relocation sum. E.g., if this was an 8 bit
- byte of data which we read and relocated, this would be
- 0x000000ff. When we have relocs which have an addend, such as
- sun4 extended relocs, the value in the offset part of a
- relocating field is garbage so we never use it. In this case
- the mask would be 0x00000000. */
+ bfd_boolean partial_inplace;
+
+ /* src_mask selects the part of the instruction (or data) to be used
+ in the relocation sum. If the target relocations don't have an
+ addend in the reloc, eg. ELF USE_REL, src_mask will normally equal
+ dst_mask to extract the addend from the section contents. If
+ relocations do have an addend in the reloc, eg. ELF USE_RELA, this
+ field should be zero. Non-zero values for ELF USE_RELA targets are
+ bogus as in those cases the value in the dst_mask part of the
+ section contents should be treated as garbage. */
bfd_vma src_mask;
- /* The dst_mask selects which parts of the instruction are replaced
- into the instruction. In most cases src_mask == dst_mask,
- except in the above special case, where dst_mask would be
- 0x000000ff, and src_mask would be 0x00000000. */
+ /* dst_mask selects which parts of the instruction (or data) are
+ replaced with a relocated value. */
bfd_vma dst_mask;
/* When some formats create PC relative instructions, they leave
@@ -342,7 +342,7 @@ struct reloc_howto_struct
be made just by adding in an ordinary offset (e.g., sun3 a.out).
Some formats leave the displacement part of an instruction
empty (e.g., m88k bcs); this flag signals the fact. */
- boolean pcrel_offset;
+ bfd_boolean pcrel_offset;
@};
@end example
@@ -361,7 +361,7 @@ moment, we are compatible, so do it this way.
@example
#define NEWHOWTO(FUNCTION, NAME, SIZE, REL, IN) \
HOWTO (0, 0, SIZE, 0, REL, 0, complain_overflow_dont, FUNCTION, \
- NAME, false, 0, 0, IN)
+ NAME, FALSE, 0, 0, IN)
@end example
@@ -369,8 +369,8 @@ moment, we are compatible, so do it this way.
This is used to fill in an empty howto entry in an array.
@example
#define EMPTY_HOWTO(C) \
- HOWTO ((C), 0, 0, 0, false, 0, complain_overflow_dont, NULL, \
- NULL, false, 0, 0, false)
+ HOWTO ((C), 0, 0, 0, FALSE, 0, complain_overflow_dont, NULL, \
+ NULL, FALSE, 0, 0, FALSE)
@end example
@@ -379,7 +379,7 @@ Helper routine to turn a symbol into a relocation value.
@example
#define HOWTO_PREPARE(relocation, symbol) \
@{ \
- if (symbol != (asymbol *) NULL) \
+ if (symbol != NULL) \
@{ \
if (bfd_is_com_section (symbol->section)) \
@{ \
@@ -422,8 +422,7 @@ arelent_chain;
@subsubsection @code{bfd_check_overflow}
@strong{Synopsis}
@example
-bfd_reloc_status_type
-bfd_check_overflow
+bfd_reloc_status_type bfd_check_overflow
(enum complain_overflow how,
unsigned int bitsize,
unsigned int rightshift,
@@ -441,11 +440,10 @@ Perform overflow checking on @var{relocation} which has
@subsubsection @code{bfd_perform_relocation}
@strong{Synopsis}
@example
-bfd_reloc_status_type
-bfd_perform_relocation
+bfd_reloc_status_type bfd_perform_relocation
(bfd *abfd,
arelent *reloc_entry,
- PTR data,
+ void *data,
asection *input_section,
bfd *output_bfd,
char **error_message);
@@ -470,11 +468,10 @@ this return @code{bfd_reloc_dangerous}.
@subsubsection @code{bfd_install_relocation}
@strong{Synopsis}
@example
-bfd_reloc_status_type
-bfd_install_relocation
+bfd_reloc_status_type bfd_install_relocation
(bfd *abfd,
arelent *reloc_entry,
- PTR data, bfd_vma data_start,
+ void *data, bfd_vma data_start,
asection *input_section,
char **error_message);
@end example
@@ -647,6 +644,32 @@ SPARC64 relocations
@deffn {} BFD_RELOC_SPARC_REV32
SPARC little endian relocation
@end deffn
+@deffn {} BFD_RELOC_SPARC_TLS_GD_HI22
+@deffnx {} BFD_RELOC_SPARC_TLS_GD_LO10
+@deffnx {} BFD_RELOC_SPARC_TLS_GD_ADD
+@deffnx {} BFD_RELOC_SPARC_TLS_GD_CALL
+@deffnx {} BFD_RELOC_SPARC_TLS_LDM_HI22
+@deffnx {} BFD_RELOC_SPARC_TLS_LDM_LO10
+@deffnx {} BFD_RELOC_SPARC_TLS_LDM_ADD
+@deffnx {} BFD_RELOC_SPARC_TLS_LDM_CALL
+@deffnx {} BFD_RELOC_SPARC_TLS_LDO_HIX22
+@deffnx {} BFD_RELOC_SPARC_TLS_LDO_LOX10
+@deffnx {} BFD_RELOC_SPARC_TLS_LDO_ADD
+@deffnx {} BFD_RELOC_SPARC_TLS_IE_HI22
+@deffnx {} BFD_RELOC_SPARC_TLS_IE_LO10
+@deffnx {} BFD_RELOC_SPARC_TLS_IE_LD
+@deffnx {} BFD_RELOC_SPARC_TLS_IE_LDX
+@deffnx {} BFD_RELOC_SPARC_TLS_IE_ADD
+@deffnx {} BFD_RELOC_SPARC_TLS_LE_HIX22
+@deffnx {} BFD_RELOC_SPARC_TLS_LE_LOX10
+@deffnx {} BFD_RELOC_SPARC_TLS_DTPMOD32
+@deffnx {} BFD_RELOC_SPARC_TLS_DTPMOD64
+@deffnx {} BFD_RELOC_SPARC_TLS_DTPOFF32
+@deffnx {} BFD_RELOC_SPARC_TLS_DTPOFF64
+@deffnx {} BFD_RELOC_SPARC_TLS_TPOFF32
+@deffnx {} BFD_RELOC_SPARC_TLS_TPOFF64
+SPARC TLS relocations
+@end deffn
@deffn {} BFD_RELOC_ALPHA_GPDISP_HI16
Alpha ECOFF and ELF relocations. Some of these treat the symbol or
"addend" in some special way.
@@ -713,7 +736,7 @@ GP register.
@end deffn
@deffn {} BFD_RELOC_ALPHA_BRSGP
Like BFD_RELOC_23_PCREL_S2, except that the source and target must
-share a common GP, and the target address is adjusted for
+share a common GP, and the target address is adjusted for
STO_ALPHA_STD_GPLOAD.
@end deffn
@deffn {} BFD_RELOC_ALPHA_TLSGD
@@ -783,6 +806,8 @@ Relocation against a MIPS literal section.
@deffnx {} BFD_RELOC_MIPS_REL16
@deffnx {} BFD_RELOC_MIPS_RELGOT
@deffnx {} BFD_RELOC_MIPS_JALR
+MIPS ELF relocations.
+@end deffn
@deffn {} BFD_RELOC_FRV_LABEL16
@deffnx {} BFD_RELOC_FRV_LABEL24
@deffnx {} BFD_RELOC_FRV_LO16
@@ -792,9 +817,48 @@ Relocation against a MIPS literal section.
@deffnx {} BFD_RELOC_FRV_GPREL32
@deffnx {} BFD_RELOC_FRV_GPRELHI
@deffnx {} BFD_RELOC_FRV_GPRELLO
+@deffnx {} BFD_RELOC_FRV_GOT12
+@deffnx {} BFD_RELOC_FRV_GOTHI
+@deffnx {} BFD_RELOC_FRV_GOTLO
+@deffnx {} BFD_RELOC_FRV_FUNCDESC
+@deffnx {} BFD_RELOC_FRV_FUNCDESC_GOT12
+@deffnx {} BFD_RELOC_FRV_FUNCDESC_GOTHI
+@deffnx {} BFD_RELOC_FRV_FUNCDESC_GOTLO
+@deffnx {} BFD_RELOC_FRV_FUNCDESC_VALUE
+@deffnx {} BFD_RELOC_FRV_FUNCDESC_GOTOFF12
+@deffnx {} BFD_RELOC_FRV_FUNCDESC_GOTOFFHI
+@deffnx {} BFD_RELOC_FRV_FUNCDESC_GOTOFFLO
+@deffnx {} BFD_RELOC_FRV_GOTOFF12
+@deffnx {} BFD_RELOC_FRV_GOTOFFHI
+@deffnx {} BFD_RELOC_FRV_GOTOFFLO
Fujitsu Frv Relocations.
@end deffn
-MIPS ELF relocations.
+@deffn {} BFD_RELOC_MN10300_GOTOFF24
+This is a 24bit GOT-relative reloc for the mn10300.
+@end deffn
+@deffn {} BFD_RELOC_MN10300_GOT32
+This is a 32bit GOT-relative reloc for the mn10300, offset by two bytes
+in the instruction.
+@end deffn
+@deffn {} BFD_RELOC_MN10300_GOT24
+This is a 24bit GOT-relative reloc for the mn10300, offset by two bytes
+in the instruction.
+@end deffn
+@deffn {} BFD_RELOC_MN10300_GOT16
+This is a 16bit GOT-relative reloc for the mn10300, offset by two bytes
+in the instruction.
+@end deffn
+@deffn {} BFD_RELOC_MN10300_COPY
+Copy symbol at runtime.
+@end deffn
+@deffn {} BFD_RELOC_MN10300_GLOB_DAT
+Create GOT entry.
+@end deffn
+@deffn {} BFD_RELOC_MN10300_JMP_SLOT
+Create PLT entry.
+@end deffn
+@deffn {} BFD_RELOC_MN10300_RELATIVE
+Adjust by program base.
@end deffn
@deffn {} BFD_RELOC_386_GOT32
@deffnx {} BFD_RELOC_386_PLT32
@@ -826,6 +890,14 @@ i386/elf relocations
@deffnx {} BFD_RELOC_X86_64_RELATIVE
@deffnx {} BFD_RELOC_X86_64_GOTPCREL
@deffnx {} BFD_RELOC_X86_64_32S
+@deffnx {} BFD_RELOC_X86_64_DTPMOD64
+@deffnx {} BFD_RELOC_X86_64_DTPOFF64
+@deffnx {} BFD_RELOC_X86_64_TPOFF64
+@deffnx {} BFD_RELOC_X86_64_TLSGD
+@deffnx {} BFD_RELOC_X86_64_TLSLD
+@deffnx {} BFD_RELOC_X86_64_DTPOFF32
+@deffnx {} BFD_RELOC_X86_64_GOTTPOFF
+@deffnx {} BFD_RELOC_X86_64_TPOFF32
x86-64/elf relocations
@end deffn
@deffn {} BFD_RELOC_NS32K_IMM_8
@@ -909,11 +981,53 @@ Picojava relocs. Not all of these appear in object files.
@deffnx {} BFD_RELOC_PPC64_PLTGOT16_LO_DS
Power(rs6000) and PowerPC relocations.
@end deffn
+@deffn {} BFD_RELOC_PPC_TLS
+@deffnx {} BFD_RELOC_PPC_DTPMOD
+@deffnx {} BFD_RELOC_PPC_TPREL16
+@deffnx {} BFD_RELOC_PPC_TPREL16_LO
+@deffnx {} BFD_RELOC_PPC_TPREL16_HI
+@deffnx {} BFD_RELOC_PPC_TPREL16_HA
+@deffnx {} BFD_RELOC_PPC_TPREL
+@deffnx {} BFD_RELOC_PPC_DTPREL16
+@deffnx {} BFD_RELOC_PPC_DTPREL16_LO
+@deffnx {} BFD_RELOC_PPC_DTPREL16_HI
+@deffnx {} BFD_RELOC_PPC_DTPREL16_HA
+@deffnx {} BFD_RELOC_PPC_DTPREL
+@deffnx {} BFD_RELOC_PPC_GOT_TLSGD16
+@deffnx {} BFD_RELOC_PPC_GOT_TLSGD16_LO
+@deffnx {} BFD_RELOC_PPC_GOT_TLSGD16_HI
+@deffnx {} BFD_RELOC_PPC_GOT_TLSGD16_HA
+@deffnx {} BFD_RELOC_PPC_GOT_TLSLD16
+@deffnx {} BFD_RELOC_PPC_GOT_TLSLD16_LO
+@deffnx {} BFD_RELOC_PPC_GOT_TLSLD16_HI
+@deffnx {} BFD_RELOC_PPC_GOT_TLSLD16_HA
+@deffnx {} BFD_RELOC_PPC_GOT_TPREL16
+@deffnx {} BFD_RELOC_PPC_GOT_TPREL16_LO
+@deffnx {} BFD_RELOC_PPC_GOT_TPREL16_HI
+@deffnx {} BFD_RELOC_PPC_GOT_TPREL16_HA
+@deffnx {} BFD_RELOC_PPC_GOT_DTPREL16
+@deffnx {} BFD_RELOC_PPC_GOT_DTPREL16_LO
+@deffnx {} BFD_RELOC_PPC_GOT_DTPREL16_HI
+@deffnx {} BFD_RELOC_PPC_GOT_DTPREL16_HA
+@deffnx {} BFD_RELOC_PPC64_TPREL16_DS
+@deffnx {} BFD_RELOC_PPC64_TPREL16_LO_DS
+@deffnx {} BFD_RELOC_PPC64_TPREL16_HIGHER
+@deffnx {} BFD_RELOC_PPC64_TPREL16_HIGHERA
+@deffnx {} BFD_RELOC_PPC64_TPREL16_HIGHEST
+@deffnx {} BFD_RELOC_PPC64_TPREL16_HIGHESTA
+@deffnx {} BFD_RELOC_PPC64_DTPREL16_DS
+@deffnx {} BFD_RELOC_PPC64_DTPREL16_LO_DS
+@deffnx {} BFD_RELOC_PPC64_DTPREL16_HIGHER
+@deffnx {} BFD_RELOC_PPC64_DTPREL16_HIGHERA
+@deffnx {} BFD_RELOC_PPC64_DTPREL16_HIGHEST
+@deffnx {} BFD_RELOC_PPC64_DTPREL16_HIGHESTA
+PowerPC and PowerPC64 thread-local storage relocations.
+@end deffn
@deffn {} BFD_RELOC_I370_D12
IBM 370/390 relocations
@end deffn
@deffn {} BFD_RELOC_CTOR
-The type of reloc used to build a contructor table - at the moment
+The type of reloc used to build a constructor table - at the moment
probably a 32 bit wide absolute relocation, but the target can choose.
It generally does map to one of the other relocation types.
@end deffn
@@ -938,6 +1052,7 @@ field in the instruction.
@deffnx {} BFD_RELOC_ARM_SWI
@deffnx {} BFD_RELOC_ARM_MULTI
@deffnx {} BFD_RELOC_ARM_CP_OFF_IMM
+@deffnx {} BFD_RELOC_ARM_CP_OFF_IMM_S2
@deffnx {} BFD_RELOC_ARM_ADR_IMM
@deffnx {} BFD_RELOC_ARM_LDR_IMM
@deffnx {} BFD_RELOC_ARM_LITERAL
@@ -1034,7 +1149,15 @@ These relocs are only used within the ARM assembler. They are not
@deffnx {} BFD_RELOC_SH_IMM_HI16
@deffnx {} BFD_RELOC_SH_IMM_HI16_PCREL
@deffnx {} BFD_RELOC_SH_PT_16
-Hitachi SH relocs. Not all of these appear in object files.
+@deffnx {} BFD_RELOC_SH_TLS_GD_32
+@deffnx {} BFD_RELOC_SH_TLS_LD_32
+@deffnx {} BFD_RELOC_SH_TLS_LDO_32
+@deffnx {} BFD_RELOC_SH_TLS_IE_32
+@deffnx {} BFD_RELOC_SH_TLS_LE_32
+@deffnx {} BFD_RELOC_SH_TLS_DTPMOD32
+@deffnx {} BFD_RELOC_SH_TLS_DTPOFF32
+@deffnx {} BFD_RELOC_SH_TLS_TPOFF32
+Renesas / SuperH SH relocs. Not all of these appear in object files.
@end deffn
@deffn {} BFD_RELOC_THUMB_PCREL_BRANCH9
@deffnx {} BFD_RELOC_THUMB_PCREL_BRANCH12
@@ -1131,7 +1254,7 @@ DLX relocs
DLX relocs
@end deffn
@deffn {} BFD_RELOC_M32R_24
-Mitsubishi M32R relocs.
+Renesas M32R (formerly Mitsubishi M32R) relocs.
This is a 24 bit absolute address.
@end deffn
@deffn {} BFD_RELOC_M32R_10_PCREL
@@ -1158,6 +1281,22 @@ This is a 16-bit reloc containing the lower 16 bits of an address.
This is a 16-bit reloc containing the small data area offset for use in
add3, load, and store instructions.
@end deffn
+@deffn {} BFD_RELOC_M32R_GOT24
+@deffnx {} BFD_RELOC_M32R_26_PLTREL
+@deffnx {} BFD_RELOC_M32R_COPY
+@deffnx {} BFD_RELOC_M32R_GLOB_DAT
+@deffnx {} BFD_RELOC_M32R_JMP_SLOT
+@deffnx {} BFD_RELOC_M32R_RELATIVE
+@deffnx {} BFD_RELOC_M32R_GOTOFF
+@deffnx {} BFD_RELOC_M32R_GOTPC24
+@deffnx {} BFD_RELOC_M32R_GOT16_HI_ULO
+@deffnx {} BFD_RELOC_M32R_GOT16_HI_SLO
+@deffnx {} BFD_RELOC_M32R_GOT16_LO
+@deffnx {} BFD_RELOC_M32R_GOTPC_HI_ULO
+@deffnx {} BFD_RELOC_M32R_GOTPC_HI_SLO
+@deffnx {} BFD_RELOC_M32R_GOTPC_LO
+For PIC.
+@end deffn
@deffn {} BFD_RELOC_V850_9_PCREL
This is a 9-bit reloc
@end deffn
@@ -1201,11 +1340,11 @@ This is a 4 bit offset from the tiny data area pointer.
@end deffn
@deffn {} BFD_RELOC_V850_SDA_16_16_SPLIT_OFFSET
This is a 16 bit offset from the short data area pointer, with the
-bits placed non-contigously in the instruction.
+bits placed non-contiguously in the instruction.
@end deffn
@deffn {} BFD_RELOC_V850_ZDA_16_16_SPLIT_OFFSET
This is a 16 bit offset from the zero data area pointer, with the
-bits placed non-contigously in the instruction.
+bits placed non-contiguously in the instruction.
@end deffn
@deffn {} BFD_RELOC_V850_CALLT_6_7_OFFSET
This is a 6 bit offset from the call table base pointer.
@@ -1213,6 +1352,15 @@ This is a 6 bit offset from the call table base pointer.
@deffn {} BFD_RELOC_V850_CALLT_16_16_OFFSET
This is a 16 bit offset from the call table base pointer.
@end deffn
+@deffn {} BFD_RELOC_V850_LONGCALL
+Used for relaxing indirect function calls.
+@end deffn
+@deffn {} BFD_RELOC_V850_LONGJUMP
+Used for relaxing indirect jumps.
+@end deffn
+@deffn {} BFD_RELOC_V850_ALIGN
+Used to maintain alignment whilst relaxing.
+@end deffn
@deffn {} BFD_RELOC_MN10300_32_PCREL
This is a 32bit pcrel reloc for the mn10300, offset by two bytes in the
instruction.
@@ -1305,6 +1453,7 @@ These are relocations for a conditional branch instruction.
@deffnx {} BFD_RELOC_MMIX_PUSHJ_1
@deffnx {} BFD_RELOC_MMIX_PUSHJ_2
@deffnx {} BFD_RELOC_MMIX_PUSHJ_3
+@deffnx {} BFD_RELOC_MMIX_PUSHJ_STUBBABLE
These are relocations for the PUSHJ instruction.
@end deffn
@deffn {} BFD_RELOC_MMIX_JMP
@@ -1455,6 +1604,95 @@ PC relative 32 bit shifted by 1.
@deffn {} BFD_RELOC_390_GOTENT
32 bit rel. offset to GOT entry.
@end deffn
+@deffn {} BFD_RELOC_390_GOTOFF64
+64 bit offset to GOT.
+@end deffn
+@deffn {} BFD_RELOC_390_GOTPLT12
+12-bit offset to symbol-entry within GOT, with PLT handling.
+@end deffn
+@deffn {} BFD_RELOC_390_GOTPLT16
+16-bit offset to symbol-entry within GOT, with PLT handling.
+@end deffn
+@deffn {} BFD_RELOC_390_GOTPLT32
+32-bit offset to symbol-entry within GOT, with PLT handling.
+@end deffn
+@deffn {} BFD_RELOC_390_GOTPLT64
+64-bit offset to symbol-entry within GOT, with PLT handling.
+@end deffn
+@deffn {} BFD_RELOC_390_GOTPLTENT
+32-bit rel. offset to symbol-entry within GOT, with PLT handling.
+@end deffn
+@deffn {} BFD_RELOC_390_PLTOFF16
+16-bit rel. offset from the GOT to a PLT entry.
+@end deffn
+@deffn {} BFD_RELOC_390_PLTOFF32
+32-bit rel. offset from the GOT to a PLT entry.
+@end deffn
+@deffn {} BFD_RELOC_390_PLTOFF64
+64-bit rel. offset from the GOT to a PLT entry.
+@end deffn
+@deffn {} BFD_RELOC_390_TLS_LOAD
+@deffnx {} BFD_RELOC_390_TLS_GDCALL
+@deffnx {} BFD_RELOC_390_TLS_LDCALL
+@deffnx {} BFD_RELOC_390_TLS_GD32
+@deffnx {} BFD_RELOC_390_TLS_GD64
+@deffnx {} BFD_RELOC_390_TLS_GOTIE12
+@deffnx {} BFD_RELOC_390_TLS_GOTIE32
+@deffnx {} BFD_RELOC_390_TLS_GOTIE64
+@deffnx {} BFD_RELOC_390_TLS_LDM32
+@deffnx {} BFD_RELOC_390_TLS_LDM64
+@deffnx {} BFD_RELOC_390_TLS_IE32
+@deffnx {} BFD_RELOC_390_TLS_IE64
+@deffnx {} BFD_RELOC_390_TLS_IEENT
+@deffnx {} BFD_RELOC_390_TLS_LE32
+@deffnx {} BFD_RELOC_390_TLS_LE64
+@deffnx {} BFD_RELOC_390_TLS_LDO32
+@deffnx {} BFD_RELOC_390_TLS_LDO64
+@deffnx {} BFD_RELOC_390_TLS_DTPMOD
+@deffnx {} BFD_RELOC_390_TLS_DTPOFF
+@deffnx {} BFD_RELOC_390_TLS_TPOFF
+s390 tls relocations.
+@end deffn
+@deffn {} BFD_RELOC_390_20
+@deffnx {} BFD_RELOC_390_GOT20
+@deffnx {} BFD_RELOC_390_GOTPLT20
+@deffnx {} BFD_RELOC_390_TLS_GOTIE20
+Long displacement extension.
+@end deffn
+@deffn {} BFD_RELOC_IP2K_FR9
+Scenix IP2K - 9-bit register number / data address
+@end deffn
+@deffn {} BFD_RELOC_IP2K_BANK
+Scenix IP2K - 4-bit register/data bank number
+@end deffn
+@deffn {} BFD_RELOC_IP2K_ADDR16CJP
+Scenix IP2K - low 13 bits of instruction word address
+@end deffn
+@deffn {} BFD_RELOC_IP2K_PAGE3
+Scenix IP2K - high 3 bits of instruction word address
+@end deffn
+@deffn {} BFD_RELOC_IP2K_LO8DATA
+@deffnx {} BFD_RELOC_IP2K_HI8DATA
+@deffnx {} BFD_RELOC_IP2K_EX8DATA
+Scenix IP2K - ext/low/high 8 bits of data address
+@end deffn
+@deffn {} BFD_RELOC_IP2K_LO8INSN
+@deffnx {} BFD_RELOC_IP2K_HI8INSN
+Scenix IP2K - low/high 8 bits of instruction word address
+@end deffn
+@deffn {} BFD_RELOC_IP2K_PC_SKIP
+Scenix IP2K - even/odd PC modifier to modify snb pcl.0
+@end deffn
+@deffn {} BFD_RELOC_IP2K_TEXT
+Scenix IP2K - 16 bit word address in text section.
+@end deffn
+@deffn {} BFD_RELOC_IP2K_FR_OFFSET
+Scenix IP2K - 7-bit sp or dp offset
+@end deffn
+@deffn {} BFD_RELOC_VPE4KMATH_DATA
+@deffnx {} BFD_RELOC_VPE4KMATH_INSN
+Scenix VPE4K coprocessor - data/insn-space addressing
+@end deffn
@deffn {} BFD_RELOC_VTABLE_INHERIT
@deffnx {} BFD_RELOC_VTABLE_ENTRY
These two relocations are used by the linker to determine which of
@@ -1464,7 +1702,7 @@ that are not used, so that the code for those functions need not be
included in the output.
VTABLE_INHERIT is a zero-space relocation used to describe to the
-linker the inheritence tree of a C++ virtual function table. The
+linker the inheritance tree of a C++ virtual function table. The
relocation's symbol should be the parent class' vtable, and the
relocation should be located at the child vtable.
@@ -1558,15 +1796,50 @@ Intel IA64 Relocations.
@end deffn
@deffn {} BFD_RELOC_M68HC11_HI8
Motorola 68HC11 reloc.
-This is the 8 bits high part of an absolute address.
+This is the 8 bit high part of an absolute address.
@end deffn
@deffn {} BFD_RELOC_M68HC11_LO8
Motorola 68HC11 reloc.
-This is the 8 bits low part of an absolute address.
+This is the 8 bit low part of an absolute address.
@end deffn
@deffn {} BFD_RELOC_M68HC11_3B
Motorola 68HC11 reloc.
-This is the 3 bits of a value.
+This is the 3 bit of a value.
+@end deffn
+@deffn {} BFD_RELOC_M68HC11_RL_JUMP
+Motorola 68HC11 reloc.
+This reloc marks the beginning of a jump/call instruction.
+It is used for linker relaxation to correctly identify beginning
+of instruction and change some branches to use PC-relative
+addressing mode.
+@end deffn
+@deffn {} BFD_RELOC_M68HC11_RL_GROUP
+Motorola 68HC11 reloc.
+This reloc marks a group of several instructions that gcc generates
+and for which the linker relaxation pass can modify and/or remove
+some of them.
+@end deffn
+@deffn {} BFD_RELOC_M68HC11_LO16
+Motorola 68HC11 reloc.
+This is the 16-bit lower part of an address. It is used for 'call'
+instruction to specify the symbol address without any special
+transformation (due to memory bank window).
+@end deffn
+@deffn {} BFD_RELOC_M68HC11_PAGE
+Motorola 68HC11 reloc.
+This is a 8-bit reloc that specifies the page number of an address.
+It is used by 'call' instruction to specify the page number of
+the symbol.
+@end deffn
+@deffn {} BFD_RELOC_M68HC11_24
+Motorola 68HC11 reloc.
+This is a 24-bit reloc that represents the address with a 16-bit
+value and a 8-bit page number. The symbol address is transformed
+to follow the 16K memory bank of 68HC12 (seen as mapped in the window).
+@end deffn
+@deffn {} BFD_RELOC_M68HC12_5B
+Motorola 68HC12 reloc.
+This is the 5 bits of a value.
@end deffn
@deffn {} BFD_RELOC_CRIS_BDISP8
@deffnx {} BFD_RELOC_CRIS_UNSIGNED_5
@@ -1649,6 +1922,7 @@ OpenRISC Relocations.
H8 elf Relocations.
@end deffn
@deffn {} BFD_RELOC_XSTORMY16_REL_12
+@deffnx {} BFD_RELOC_XSTORMY16_12
@deffnx {} BFD_RELOC_XSTORMY16_24
@deffnx {} BFD_RELOC_XSTORMY16_FPTR16
Sony Xstormy16 Relocations.
@@ -1658,6 +1932,50 @@ Sony Xstormy16 Relocations.
@deffnx {} BFD_RELOC_VAX_RELATIVE
Relocations used by VAX ELF.
@end deffn
+@deffn {} BFD_RELOC_MSP430_10_PCREL
+@deffnx {} BFD_RELOC_MSP430_16_PCREL
+@deffnx {} BFD_RELOC_MSP430_16
+@deffnx {} BFD_RELOC_MSP430_16_PCREL_BYTE
+@deffnx {} BFD_RELOC_MSP430_16_BYTE
+msp430 specific relocation codes
+@end deffn
+@deffn {} BFD_RELOC_IQ2000_OFFSET_16
+@deffnx {} BFD_RELOC_IQ2000_OFFSET_21
+@deffnx {} BFD_RELOC_IQ2000_UHI16
+IQ2000 Relocations.
+@end deffn
+@deffn {} BFD_RELOC_XTENSA_RTLD
+Special Xtensa relocation used only by PLT entries in ELF shared
+objects to indicate that the runtime linker should set the value
+to one of its own internal functions or data structures.
+@end deffn
+@deffn {} BFD_RELOC_XTENSA_GLOB_DAT
+@deffnx {} BFD_RELOC_XTENSA_JMP_SLOT
+@deffnx {} BFD_RELOC_XTENSA_RELATIVE
+Xtensa relocations for ELF shared objects.
+@end deffn
+@deffn {} BFD_RELOC_XTENSA_PLT
+Xtensa relocation used in ELF object files for symbols that may require
+PLT entries. Otherwise, this is just a generic 32-bit relocation.
+@end deffn
+@deffn {} BFD_RELOC_XTENSA_OP0
+@deffnx {} BFD_RELOC_XTENSA_OP1
+@deffnx {} BFD_RELOC_XTENSA_OP2
+Generic Xtensa relocations. Only the operand number is encoded
+in the relocation. The details are determined by extracting the
+instruction opcode.
+@end deffn
+@deffn {} BFD_RELOC_XTENSA_ASM_EXPAND
+Xtensa relocation to mark that the assembler expanded the
+instructions from an original target. The expansion size is
+encoded in the reloc size.
+@end deffn
+@deffn {} BFD_RELOC_XTENSA_ASM_SIMPLIFY
+Xtensa relocation to mark that the linker should simplify
+assembler-expanded instructions. This is commonly used
+internally by the linker after analysis of a
+BFD_RELOC_XTENSA_ASM_EXPAND.
+@end deffn
@example
@@ -1667,8 +1985,8 @@ typedef enum bfd_reloc_code_real bfd_reloc_code_real_type;
@subsubsection @code{bfd_reloc_type_lookup}
@strong{Synopsis}
@example
-reloc_howto_type *
-bfd_reloc_type_lookup (bfd *abfd, bfd_reloc_code_real_type code);
+reloc_howto_type *bfd_reloc_type_lookup
+ (bfd *abfd, bfd_reloc_code_real_type code);
@end example
@strong{Description}@*
Return a pointer to a howto structure which, when
@@ -1699,21 +2017,22 @@ Useful mainly for printing error messages.
@subsubsection @code{bfd_generic_relax_section}
@strong{Synopsis}
@example
-boolean bfd_generic_relax_section
+bfd_boolean bfd_generic_relax_section
(bfd *abfd,
asection *section,
struct bfd_link_info *,
- boolean *);
+ bfd_boolean *);
@end example
@strong{Description}@*
Provides default handling for relaxing for back ends which
-don't do relaxing -- i.e., does nothing.
+don't do relaxing -- i.e., does nothing except make sure that the
+final size of the section is set.
@findex bfd_generic_gc_sections
@subsubsection @code{bfd_generic_gc_sections}
@strong{Synopsis}
@example
-boolean bfd_generic_gc_sections
+bfd_boolean bfd_generic_gc_sections
(bfd *, struct bfd_link_info *);
@end example
@strong{Description}@*
@@ -1724,7 +2043,7 @@ don't do section gc -- i.e., does nothing.
@subsubsection @code{bfd_generic_merge_sections}
@strong{Synopsis}
@example
-boolean bfd_generic_merge_sections
+bfd_boolean bfd_generic_merge_sections
(bfd *, struct bfd_link_info *);
@end example
@strong{Description}@*
@@ -1735,12 +2054,12 @@ which don't have SEC_MERGE support -- i.e., does nothing.
@subsubsection @code{bfd_generic_get_relocated_section_contents}
@strong{Synopsis}
@example
-bfd_byte *
-bfd_generic_get_relocated_section_contents (bfd *abfd,
+bfd_byte *bfd_generic_get_relocated_section_contents
+ (bfd *abfd,
struct bfd_link_info *link_info,
struct bfd_link_order *link_order,
bfd_byte *data,
- boolean relocateable,
+ bfd_boolean relocatable,
asymbol **symbols);
@end example
@strong{Description}@*
diff --git a/contrib/binutils/bfd/doc/section.texi b/contrib/binutils/bfd/doc/section.texi
index 971fd04..b1501f9 100644
--- a/contrib/binutils/bfd/doc/section.texi
+++ b/contrib/binutils/bfd/doc/section.texi
@@ -124,7 +124,7 @@ struct bfd_comdat_info
long symbol;
@};
-typedef struct sec
+typedef struct bfd_section
@{
/* The name of the section; the name isn't a copy, the pointer is
the same as that passed to bfd_make_section. */
@@ -137,7 +137,7 @@ typedef struct sec
int index;
/* The next section in the list belonging to the BFD, or NULL. */
- struct sec *next;
+ struct bfd_section *next;
/* The field flags contains attributes of the section. Some
flags are read in from the object file, and some are
@@ -335,10 +335,39 @@ typedef struct sec
/* A mark flag used by some linker backends for garbage collection. */
unsigned int gc_mark : 1;
- /* Used by the ELF code to mark sections which have been allocated
- to segments. */
+ /* The following flags are used by the ELF linker. */
+
+ /* Mark sections which have been allocated to segments. */
unsigned int segment_mark : 1;
+ /* Type of sec_info information. */
+ unsigned int sec_info_type:3;
+#define ELF_INFO_TYPE_NONE 0
+#define ELF_INFO_TYPE_STABS 1
+#define ELF_INFO_TYPE_MERGE 2
+#define ELF_INFO_TYPE_EH_FRAME 3
+#define ELF_INFO_TYPE_JUST_SYMS 4
+
+ /* Nonzero if this section uses RELA relocations, rather than REL. */
+ unsigned int use_rela_p:1;
+
+ /* Bits used by various backends. */
+ unsigned int has_tls_reloc:1;
+
+ /* Nonzero if this section needs the relax finalize pass. */
+ unsigned int need_finalize_relax:1;
+
+ /* Nonzero if this section has a gp reloc. */
+ unsigned int has_gp_reloc:1;
+
+ /* Unused bits. */
+ unsigned int flag13:1;
+ unsigned int flag14:1;
+ unsigned int flag15:1;
+ unsigned int flag16:4;
+ unsigned int flag20:4;
+ unsigned int flag24:8;
+
/* End of internal packed boolean fields. */
/* The virtual memory address of the section - where it will be
@@ -374,7 +403,7 @@ typedef struct sec
bfd_vma output_offset;
/* The output section through which to map on output. */
- struct sec *output_section;
+ struct bfd_section *output_section;
/* The alignment requirement of the section, as an exponent of 2 -
e.g., 3 aligns to 2^3 (or 8). */
@@ -404,7 +433,7 @@ typedef struct sec
file_ptr line_filepos;
/* Pointer to data for applications. */
- PTR userdata;
+ void *userdata;
/* If the SEC_IN_MEMORY flag is set, this points to the actual
contents. */
@@ -422,6 +451,10 @@ typedef struct sec
/* Optional information about a COMDAT entry; NULL if not COMDAT. */
struct bfd_comdat_info *comdat;
+ /* Points to the kept section if this section is a link-once section,
+ and is discarded. */
+ struct bfd_section *kept_section;
+
/* When a section is being output, this value changes as more
linenumbers are written out. */
file_ptr moving_line_filepos;
@@ -429,7 +462,7 @@ typedef struct sec
/* What the section number is in the target world. */
int target_index;
- PTR used_by_bfd;
+ void *used_by_bfd;
/* If this is a constructor section then here is a list of the
relocations created to relocate items within it. */
@@ -439,8 +472,8 @@ typedef struct sec
bfd *owner;
/* A symbol which points at this section only. */
- struct symbol_cache_entry *symbol;
- struct symbol_cache_entry **symbol_ptr_ptr;
+ struct bfd_symbol *symbol;
+ struct bfd_symbol **symbol_ptr_ptr;
struct bfd_link_order *link_order_head;
struct bfd_link_order *link_order_tail;
@@ -457,18 +490,18 @@ typedef struct sec
#define BFD_IND_SECTION_NAME "*IND*"
/* The absolute section. */
-extern const asection bfd_abs_section;
+extern asection bfd_abs_section;
#define bfd_abs_section_ptr ((asection *) &bfd_abs_section)
#define bfd_is_abs_section(sec) ((sec) == bfd_abs_section_ptr)
/* Pointer to the undefined section. */
-extern const asection bfd_und_section;
+extern asection bfd_und_section;
#define bfd_und_section_ptr ((asection *) &bfd_und_section)
#define bfd_is_und_section(sec) ((sec) == bfd_und_section_ptr)
/* Pointer to the common section. */
-extern const asection bfd_com_section;
+extern asection bfd_com_section;
#define bfd_com_section_ptr ((asection *) &bfd_com_section)
/* Pointer to the indirect section. */
-extern const asection bfd_ind_section;
+extern asection bfd_ind_section;
#define bfd_ind_section_ptr ((asection *) &bfd_ind_section)
#define bfd_is_ind_section(sec) ((sec) == bfd_ind_section_ptr)
@@ -478,13 +511,12 @@ extern const asection bfd_ind_section;
|| ((SEC) == bfd_com_section_ptr) \
|| ((SEC) == bfd_ind_section_ptr))
-extern const struct symbol_cache_entry * const bfd_abs_symbol;
-extern const struct symbol_cache_entry * const bfd_com_symbol;
-extern const struct symbol_cache_entry * const bfd_und_symbol;
-extern const struct symbol_cache_entry * const bfd_ind_symbol;
+extern const struct bfd_symbol * const bfd_abs_symbol;
+extern const struct bfd_symbol * const bfd_com_symbol;
+extern const struct bfd_symbol * const bfd_und_symbol;
+extern const struct bfd_symbol * const bfd_ind_symbol;
#define bfd_get_section_size_before_reloc(section) \
- ((section)->reloc_done ? (abort (), (bfd_size_type) 1) \
- : (section)->_raw_size)
+ ((section)->_raw_size)
#define bfd_get_section_size_after_reloc(section) \
((section)->reloc_done ? (section)->_cooked_size \
: (abort (), (bfd_size_type) 1))
@@ -534,7 +566,7 @@ hash table entries.
@subsubsection @code{bfd_get_section_by_name}
@strong{Synopsis}
@example
-asection *bfd_get_section_by_name(bfd *abfd, const char *name);
+asection *bfd_get_section_by_name (bfd *abfd, const char *name);
@end example
@strong{Description}@*
Run through @var{abfd} and return the one of the
@@ -550,9 +582,8 @@ or something else) for each section.
@subsubsection @code{bfd_get_unique_section_name}
@strong{Synopsis}
@example
-char *bfd_get_unique_section_name(bfd *abfd,
- const char *templat,
- int *count);
+char *bfd_get_unique_section_name
+ (bfd *abfd, const char *templat, int *count);
@end example
@strong{Description}@*
Invent a section name that is unique in @var{abfd} by tacking
@@ -565,7 +596,7 @@ pointed to by @var{count} will be incremented in this case.
@subsubsection @code{bfd_make_section_old_way}
@strong{Synopsis}
@example
-asection *bfd_make_section_old_way(bfd *abfd, const char *name);
+asection *bfd_make_section_old_way (bfd *abfd, const char *name);
@end example
@strong{Description}@*
Create a new empty section called @var{name}
@@ -592,7 +623,7 @@ If memory allocation fails.
@subsubsection @code{bfd_make_section_anyway}
@strong{Synopsis}
@example
-asection *bfd_make_section_anyway(bfd *abfd, const char *name);
+asection *bfd_make_section_anyway (bfd *abfd, const char *name);
@end example
@strong{Description}@*
Create a new empty section called @var{name} and attach it to the end of
@@ -612,7 +643,7 @@ Return @code{NULL} and set @code{bfd_error} on error; possible errors are:
@subsubsection @code{bfd_make_section}
@strong{Synopsis}
@example
-asection *bfd_make_section(bfd *, const char *name);
+asection *bfd_make_section (bfd *, const char *name);
@end example
@strong{Description}@*
Like @code{bfd_make_section_anyway}, but return @code{NULL} (without calling
@@ -624,12 +655,13 @@ section named @var{name}. If there is an error, return @code{NULL} and set
@subsubsection @code{bfd_set_section_flags}
@strong{Synopsis}
@example
-boolean bfd_set_section_flags(bfd *abfd, asection *sec, flagword flags);
+bfd_boolean bfd_set_section_flags
+ (bfd *abfd, asection *sec, flagword flags);
@end example
@strong{Description}@*
Set the attributes of the section @var{sec} in the BFD
-@var{abfd} to the value @var{flags}. Return @code{true} on success,
-@code{false} on error. Possible error returns are:
+@var{abfd} to the value @var{flags}. Return @code{TRUE} on success,
+@code{FALSE} on error. Possible error returns are:
@itemize @bullet
@@ -644,11 +676,10 @@ have the @code{SEC_HAS_CONTENTS} field set.
@subsubsection @code{bfd_map_over_sections}
@strong{Synopsis}
@example
-void bfd_map_over_sections(bfd *abfd,
- void (*func) (bfd *abfd,
- asection *sect,
- PTR obj),
- PTR obj);
+void bfd_map_over_sections
+ (bfd *abfd,
+ void (*func) (bfd *abfd, asection *sect, void *obj),
+ void *obj);
@end example
@strong{Description}@*
Call the provided function @var{func} for each section
@@ -656,27 +687,28 @@ attached to the BFD @var{abfd}, passing @var{obj} as an
argument. The function will be called as if by
@example
- func(abfd, the_section, obj);
+ func (abfd, the_section, obj);
@end example
-This is the prefered method for iterating over sections; an
+This is the preferred method for iterating over sections; an
alternative would be to use a loop:
@example
section *p;
for (p = abfd->sections; p != NULL; p = p->next)
- func(abfd, p, ...)
+ func (abfd, p, ...)
@end example
@findex bfd_set_section_size
@subsubsection @code{bfd_set_section_size}
@strong{Synopsis}
@example
-boolean bfd_set_section_size(bfd *abfd, asection *sec, bfd_size_type val);
+bfd_boolean bfd_set_section_size
+ (bfd *abfd, asection *sec, bfd_size_type val);
@end example
@strong{Description}@*
Set @var{sec} to the size @var{val}. If the operation is
-ok, then @code{true} is returned, else @code{false}.
+ok, then @code{TRUE} is returned, else @code{FALSE}.
Possible error returns:
@itemize @bullet
@@ -690,9 +722,9 @@ Writing has started to the BFD, so setting the size is invalid.
@subsubsection @code{bfd_set_section_contents}
@strong{Synopsis}
@example
-boolean bfd_set_section_contents (bfd *abfd, asection *section,
- PTR data, file_ptr offset,
- bfd_size_type count);
+bfd_boolean bfd_set_section_contents
+ (bfd *abfd, asection *section, const void *data,
+ file_ptr offset, bfd_size_type count);
@end example
@strong{Description}@*
Sets the contents of the section @var{section} in BFD
@@ -700,7 +732,7 @@ Sets the contents of the section @var{section} in BFD
data is written to the output section starting at offset
@var{offset} for @var{count} octets.
-Normally @code{true} is returned, else @code{false}. Possible error
+Normally @code{TRUE} is returned, else @code{FALSE}. Possible error
returns are:
@itemize @bullet
@@ -718,8 +750,8 @@ This routine is front end to the back end function
@subsubsection @code{bfd_get_section_contents}
@strong{Synopsis}
@example
-boolean bfd_get_section_contents (bfd *abfd, asection *section,
- PTR location, file_ptr offset,
+bfd_boolean bfd_get_section_contents
+ (bfd *abfd, asection *section, void *location, file_ptr offset,
bfd_size_type count);
@end example
@strong{Description}@*
@@ -731,20 +763,20 @@ and is read for @var{count} bytes.
If the contents of a constructor with the @code{SEC_CONSTRUCTOR}
flag set are requested or if the section does not have the
@code{SEC_HAS_CONTENTS} flag set, then the @var{location} is filled
-with zeroes. If no errors occur, @code{true} is returned, else
-@code{false}.
+with zeroes. If no errors occur, @code{TRUE} is returned, else
+@code{FALSE}.
@findex bfd_copy_private_section_data
@subsubsection @code{bfd_copy_private_section_data}
@strong{Synopsis}
@example
-boolean bfd_copy_private_section_data (bfd *ibfd, asection *isec,
- bfd *obfd, asection *osec);
+bfd_boolean bfd_copy_private_section_data
+ (bfd *ibfd, asection *isec, bfd *obfd, asection *osec);
@end example
@strong{Description}@*
Copy private section information from @var{isec} in the BFD
@var{ibfd} to the section @var{osec} in the BFD @var{obfd}.
-Return @code{true} on success, @code{false} on error. Possible error
+Return @code{TRUE} on success, @code{FALSE} on error. Possible error
returns are:
@itemize @bullet
@@ -778,7 +810,7 @@ to remove sections.
@subsubsection @code{bfd_generic_discard_group}
@strong{Synopsis}
@example
-boolean bfd_generic_discard_group (bfd *abfd, asection *group);
+bfd_boolean bfd_generic_discard_group (bfd *abfd, asection *group);
@end example
@strong{Description}@*
Remove all members of @var{group} from the output.
diff --git a/contrib/binutils/bfd/doc/syms.texi b/contrib/binutils/bfd/doc/syms.texi
index cb29e7d..415d156 100644
--- a/contrib/binutils/bfd/doc/syms.texi
+++ b/contrib/binutils/bfd/doc/syms.texi
@@ -47,10 +47,10 @@ excerpt from an application which reads the symbol table:
if (storage_needed < 0)
FAIL
- if (storage_needed == 0) @{
- return ;
- @}
- symbol_table = (asymbol **) xmalloc (storage_needed);
+ if (storage_needed == 0)
+ return;
+
+ symbol_table = xmalloc (storage_needed);
...
number_of_symbols =
bfd_canonicalize_symtab (abfd, symbol_table);
@@ -58,9 +58,8 @@ excerpt from an application which reads the symbol table:
if (number_of_symbols < 0)
FAIL
- for (i = 0; i < number_of_symbols; i++) @{
- process_symbol (symbol_table[i]);
- @}
+ for (i = 0; i < number_of_symbols; i++)
+ process_symbol (symbol_table[i]);
@end example
All storage for the symbols themselves is in an objalloc
@@ -80,25 +79,26 @@ example showing the creation of a symbol table with only one element:
@example
#include "bfd.h"
- main()
+ int main (void)
@{
bfd *abfd;
asymbol *ptrs[2];
asymbol *new;
- abfd = bfd_openw("foo","a.out-sunos-big");
- bfd_set_format(abfd, bfd_object);
- new = bfd_make_empty_symbol(abfd);
+ abfd = bfd_openw ("foo","a.out-sunos-big");
+ bfd_set_format (abfd, bfd_object);
+ new = bfd_make_empty_symbol (abfd);
new->name = "dummy_symbol";
- new->section = bfd_make_section_old_way(abfd, ".text");
+ new->section = bfd_make_section_old_way (abfd, ".text");
new->flags = BSF_GLOBAL;
new->value = 0x12345;
ptrs[0] = new;
- ptrs[1] = (asymbol *)0;
+ ptrs[1] = 0;
- bfd_set_symtab(abfd, ptrs, 1);
- bfd_close(abfd);
+ bfd_set_symtab (abfd, ptrs, 1);
+ bfd_close (abfd);
+ return 0;
@}
./makesym
@@ -106,9 +106,9 @@ example showing the creation of a symbol table with only one element:
00012345 A dummy_symbol
@end example
-Many formats cannot represent arbitary symbol information; for
+Many formats cannot represent arbitrary symbol information; for
instance, the @code{a.out} object format does not allow an
-arbitary number of sections. A symbol pointing to a section
+arbitrary number of sections. A symbol pointing to a section
which is not one of @code{.text}, @code{.data} or @code{.bss} cannot
be described.
@@ -139,7 +139,7 @@ An @code{asymbol} has the form:
@example
-typedef struct symbol_cache_entry
+typedef struct bfd_symbol
@{
/* A pointer to the BFD which owns the symbol. This information
is necessary so that a back end can work out what additional
@@ -150,7 +150,7 @@ typedef struct symbol_cache_entry
instead, except that some symbols point to the global sections
bfd_@{abs,com,und@}_section. This could be fixed by making
these globals be per-bfd (or per-target-flavor). FIXME. */
- struct _bfd *the_bfd; /* Use bfd_asymbol_bfd(sym) to access this field. */
+ struct bfd *the_bfd; /* Use bfd_asymbol_bfd(sym) to access this field. */
/* The text of the symbol. The name is left alone, and not copied; the
application may not alter it. */
@@ -180,7 +180,7 @@ typedef struct symbol_cache_entry
@code{BSF_LOCAL}, @code{BSF_FORT_COMM}, @code{BSF_UNDEFINED} or
@code{BSF_GLOBAL}. */
- /* The symbol is a debugging record. The value has an arbitary
+ /* The symbol is a debugging record. The value has an arbitrary
meaning, unless BSF_DEBUGGING_RELOC is also set. */
#define BSF_DEBUGGING 0x08
@@ -251,12 +251,12 @@ typedef struct symbol_cache_entry
/* A pointer to the section to which this symbol is
relative. This will always be non NULL, there are special
sections for undefined and absolute symbols. */
- struct sec *section;
+ struct bfd_section *section;
/* Back end special data. */
union
@{
- PTR p;
+ void *p;
bfd_vma i;
@}
udata;
@@ -286,26 +286,26 @@ the BFD, then return 0. If an error occurs, return -1.
@subsubsection @code{bfd_is_local_label}
@strong{Synopsis}
@example
-boolean bfd_is_local_label(bfd *abfd, asymbol *sym);
+bfd_boolean bfd_is_local_label (bfd *abfd, asymbol *sym);
@end example
@strong{Description}@*
-Return true if the given symbol @var{sym} in the BFD @var{abfd} is
-a compiler generated local label, else return false.
+Return TRUE if the given symbol @var{sym} in the BFD @var{abfd} is
+a compiler generated local label, else return FALSE.
@findex bfd_is_local_label_name
@subsubsection @code{bfd_is_local_label_name}
@strong{Synopsis}
@example
-boolean bfd_is_local_label_name(bfd *abfd, const char *name);
+bfd_boolean bfd_is_local_label_name (bfd *abfd, const char *name);
@end example
@strong{Description}@*
-Return true if a symbol with the name @var{name} in the BFD
+Return TRUE if a symbol with the name @var{name} in the BFD
@var{abfd} is a compiler generated local label, else return
-false. This just checks whether the name has the form of a
+FALSE. This just checks whether the name has the form of a
local label.
@example
#define bfd_is_local_label_name(abfd, name) \
- BFD_SEND (abfd, _bfd_is_local_label_name, (abfd, name))
+ BFD_SEND (abfd, _bfd_is_local_label_name, (abfd, name))
@end example
@@ -319,8 +319,7 @@ Return the actual number of symbol pointers, not
including the NULL.
@example
#define bfd_canonicalize_symtab(abfd, location) \
- BFD_SEND (abfd, _bfd_canonicalize_symtab,\
- (abfd, location))
+ BFD_SEND (abfd, _bfd_canonicalize_symtab, (abfd, location))
@end example
@@ -328,7 +327,8 @@ including the NULL.
@subsubsection @code{bfd_set_symtab}
@strong{Synopsis}
@example
-boolean bfd_set_symtab (bfd *abfd, asymbol **location, unsigned int count);
+bfd_boolean bfd_set_symtab
+ (bfd *abfd, asymbol **location, unsigned int count);
@end example
@strong{Description}@*
Arrange that when the output BFD @var{abfd} is closed,
@@ -339,7 +339,7 @@ will be written.
@subsubsection @code{bfd_print_symbol_vandf}
@strong{Synopsis}
@example
-void bfd_print_symbol_vandf(bfd *abfd, PTR file, asymbol *symbol);
+void bfd_print_symbol_vandf (bfd *abfd, void *file, asymbol *symbol);
@end example
@strong{Description}@*
Print the value and flags of the @var{symbol} supplied to the
@@ -357,7 +357,7 @@ information surrounding the @code{asymbol}. Building your own
information, and will cause problems later on.
@example
#define bfd_make_empty_symbol(abfd) \
- BFD_SEND (abfd, _bfd_make_empty_symbol, (abfd))
+ BFD_SEND (abfd, _bfd_make_empty_symbol, (abfd))
@end example
@@ -381,7 +381,7 @@ to be used as a debugging symbol. Further details of its use have
yet to be worked out.
@example
#define bfd_make_debug_symbol(abfd,ptr,size) \
- BFD_SEND (abfd, _bfd_make_debug_symbol, (abfd, ptr, size))
+ BFD_SEND (abfd, _bfd_make_debug_symbol, (abfd, ptr, size))
@end example
@@ -393,7 +393,7 @@ class of @var{symbol}, or '?' for an unknown class.
@strong{Synopsis}
@example
-int bfd_decode_symclass(asymbol *symbol);
+int bfd_decode_symclass (asymbol *symbol);
@end example
@findex bfd_is_undefined_symclass
@subsubsection @code{bfd_is_undefined_symclass}
@@ -404,7 +404,7 @@ Returns zero otherwise.
@strong{Synopsis}
@example
-boolean bfd_is_undefined_symclass (int symclass);
+bfd_boolean bfd_is_undefined_symclass (int symclass);
@end example
@findex bfd_symbol_info
@subsubsection @code{bfd_symbol_info}
@@ -415,18 +415,19 @@ calling this function.
@strong{Synopsis}
@example
-void bfd_symbol_info(asymbol *symbol, symbol_info *ret);
+void bfd_symbol_info (asymbol *symbol, symbol_info *ret);
@end example
@findex bfd_copy_private_symbol_data
@subsubsection @code{bfd_copy_private_symbol_data}
@strong{Synopsis}
@example
-boolean bfd_copy_private_symbol_data(bfd *ibfd, asymbol *isym, bfd *obfd, asymbol *osym);
+bfd_boolean bfd_copy_private_symbol_data
+ (bfd *ibfd, asymbol *isym, bfd *obfd, asymbol *osym);
@end example
@strong{Description}@*
Copy private symbol information from @var{isym} in the BFD
@var{ibfd} to the symbol @var{osym} in the BFD @var{obfd}.
-Return @code{true} on success, @code{false} on error. Possible error
+Return @code{TRUE} on success, @code{FALSE} on error. Possible error
returns are:
@itemize @bullet
@@ -437,8 +438,8 @@ Not enough memory exists to create private data for @var{osec}.
@end itemize
@example
#define bfd_copy_private_symbol_data(ibfd, isymbol, obfd, osymbol) \
- BFD_SEND (obfd, _bfd_copy_private_symbol_data, \
- (ibfd, isymbol, obfd, osymbol))
+ BFD_SEND (obfd, _bfd_copy_private_symbol_data, \
+ (ibfd, isymbol, obfd, osymbol))
@end example
diff --git a/contrib/binutils/bfd/doc/targets.texi b/contrib/binutils/bfd/doc/targets.texi
index 5b8d2b8..9b499cf 100644
--- a/contrib/binutils/bfd/doc/targets.texi
+++ b/contrib/binutils/bfd/doc/targets.texi
@@ -2,7 +2,7 @@
@strong{Description}@*
-Each port of BFD to a different machine requries the creation
+Each port of BFD to a different machine requires the creation
of a target back end. All the back end provides to the root
part of BFD is a structure containing pointers to functions
which perform certain low level operations on files. BFD
@@ -50,7 +50,7 @@ format may be determined. This is done by calling
@code{bfd_check_format} on the BFD with a suggested format.
If @code{target_defaulted} has been set, each possible target
type is tried to see if it recognizes the specified format.
-@code{bfd_check_format} returns @code{true} when the caller guesses right.
+@code{bfd_check_format} returns @code{TRUE} when the caller guesses right.
@menu
* bfd_target::
@end menu
@@ -79,7 +79,7 @@ They make the documentation (more) unpleasant to read, so if
someone wants to fix this and not break the above, please do.
@example
#define BFD_SEND(bfd, message, arglist) \
- ((*((bfd)->xvec->message)) arglist)
+ ((*((bfd)->xvec->message)) arglist)
#ifdef DEBUG_BFD_SEND
#undef BFD_SEND
@@ -92,7 +92,7 @@ someone wants to fix this and not break the above, please do.
For operations which index on the BFD format:
@example
#define BFD_SEND_FMT(bfd, message, arglist) \
- (((bfd)->xvec->message[(int) ((bfd)->format)]) arglist)
+ (((bfd)->xvec->message[(int) ((bfd)->format)]) arglist)
#ifdef DEBUG_BFD_SEND
#undef BFD_SEND_FMT
@@ -132,7 +132,11 @@ enum bfd_flavour
bfd_target_msdos_flavour,
bfd_target_ovax_flavour,
bfd_target_evax_flavour,
- bfd_target_mmo_flavour
+ bfd_target_mmo_flavour,
+ bfd_target_mach_o_flavour,
+ bfd_target_pef_flavour,
+ bfd_target_pef_xlib_flavour,
+ bfd_target_sym_flavour
@};
enum bfd_endian @{ BFD_ENDIAN_BIG, BFD_ENDIAN_LITTLE, BFD_ENDIAN_UNKNOWN @};
@@ -176,38 +180,38 @@ typedef struct bfd_target
/* Entries for byte swapping for data. These are different from the
other entry points, since they don't take a BFD asthe first argument.
Certain other handlers could do the same. */
- bfd_vma (*bfd_getx64) PARAMS ((const bfd_byte *));
- bfd_signed_vma (*bfd_getx_signed_64) PARAMS ((const bfd_byte *));
- void (*bfd_putx64) PARAMS ((bfd_vma, bfd_byte *));
- bfd_vma (*bfd_getx32) PARAMS ((const bfd_byte *));
- bfd_signed_vma (*bfd_getx_signed_32) PARAMS ((const bfd_byte *));
- void (*bfd_putx32) PARAMS ((bfd_vma, bfd_byte *));
- bfd_vma (*bfd_getx16) PARAMS ((const bfd_byte *));
- bfd_signed_vma (*bfd_getx_signed_16) PARAMS ((const bfd_byte *));
- void (*bfd_putx16) PARAMS ((bfd_vma, bfd_byte *));
+ bfd_uint64_t (*bfd_getx64) (const void *);
+ bfd_int64_t (*bfd_getx_signed_64) (const void *);
+ void (*bfd_putx64) (bfd_uint64_t, void *);
+ bfd_vma (*bfd_getx32) (const void *);
+ bfd_signed_vma (*bfd_getx_signed_32) (const void *);
+ void (*bfd_putx32) (bfd_vma, void *);
+ bfd_vma (*bfd_getx16) (const void *);
+ bfd_signed_vma (*bfd_getx_signed_16) (const void *);
+ void (*bfd_putx16) (bfd_vma, void *);
/* Byte swapping for the headers. */
- bfd_vma (*bfd_h_getx64) PARAMS ((const bfd_byte *));
- bfd_signed_vma (*bfd_h_getx_signed_64) PARAMS ((const bfd_byte *));
- void (*bfd_h_putx64) PARAMS ((bfd_vma, bfd_byte *));
- bfd_vma (*bfd_h_getx32) PARAMS ((const bfd_byte *));
- bfd_signed_vma (*bfd_h_getx_signed_32) PARAMS ((const bfd_byte *));
- void (*bfd_h_putx32) PARAMS ((bfd_vma, bfd_byte *));
- bfd_vma (*bfd_h_getx16) PARAMS ((const bfd_byte *));
- bfd_signed_vma (*bfd_h_getx_signed_16) PARAMS ((const bfd_byte *));
- void (*bfd_h_putx16) PARAMS ((bfd_vma, bfd_byte *));
+ bfd_uint64_t (*bfd_h_getx64) (const void *);
+ bfd_int64_t (*bfd_h_getx_signed_64) (const void *);
+ void (*bfd_h_putx64) (bfd_uint64_t, void *);
+ bfd_vma (*bfd_h_getx32) (const void *);
+ bfd_signed_vma (*bfd_h_getx_signed_32) (const void *);
+ void (*bfd_h_putx32) (bfd_vma, void *);
+ bfd_vma (*bfd_h_getx16) (const void *);
+ bfd_signed_vma (*bfd_h_getx_signed_16) (const void *);
+ void (*bfd_h_putx16) (bfd_vma, void *);
/* Format dependent routines: these are vectors of entry points
within the target vector structure, one for each format to check. */
/* Check the format of a file being read. Return a @code{bfd_target *} or zero. */
- const struct bfd_target *(*_bfd_check_format[bfd_type_end]) PARAMS ((bfd *));
+ const struct bfd_target *(*_bfd_check_format[bfd_type_end]) (bfd *);
/* Set the format of a file being written. */
- boolean (*_bfd_set_format[bfd_type_end]) PARAMS ((bfd *));
+ bfd_boolean (*_bfd_set_format[bfd_type_end]) (bfd *);
/* Write cached information into a file being written, at @code{bfd_close}. */
- boolean (*_bfd_write_contents[bfd_type_end]) PARAMS ((bfd *));
+ bfd_boolean (*_bfd_write_contents[bfd_type_end]) (bfd *);
@end example
The general target vector. These vectors are initialized using the
@@ -215,227 +219,229 @@ BFD_JUMP_TABLE macros.
@example
/* Generic entry points. */
-@end example
-Do not "beautify" the CONCAT* macro args. Traditional C will not
-remove whitespace added here, and thus will fail to concatenate
-the tokens.
-@example
#define BFD_JUMP_TABLE_GENERIC(NAME) \
-CONCAT2 (NAME,_close_and_cleanup), \
-CONCAT2 (NAME,_bfd_free_cached_info), \
-CONCAT2 (NAME,_new_section_hook), \
-CONCAT2 (NAME,_get_section_contents), \
-CONCAT2 (NAME,_get_section_contents_in_window)
+ NAME##_close_and_cleanup, \
+ NAME##_bfd_free_cached_info, \
+ NAME##_new_section_hook, \
+ NAME##_get_section_contents, \
+ NAME##_get_section_contents_in_window
/* Called when the BFD is being closed to do any necessary cleanup. */
- boolean (*_close_and_cleanup) PARAMS ((bfd *));
+ bfd_boolean (*_close_and_cleanup) (bfd *);
/* Ask the BFD to free all cached information. */
- boolean (*_bfd_free_cached_info) PARAMS ((bfd *));
+ bfd_boolean (*_bfd_free_cached_info) (bfd *);
/* Called when a new section is created. */
- boolean (*_new_section_hook) PARAMS ((bfd *, sec_ptr));
+ bfd_boolean (*_new_section_hook) (bfd *, sec_ptr);
/* Read the contents of a section. */
- boolean (*_bfd_get_section_contents) PARAMS ((bfd *, sec_ptr, PTR,
- file_ptr, bfd_size_type));
- boolean (*_bfd_get_section_contents_in_window)
- PARAMS ((bfd *, sec_ptr, bfd_window *, file_ptr, bfd_size_type));
+ bfd_boolean (*_bfd_get_section_contents)
+ (bfd *, sec_ptr, void *, file_ptr, bfd_size_type);
+ bfd_boolean (*_bfd_get_section_contents_in_window)
+ (bfd *, sec_ptr, bfd_window *, file_ptr, bfd_size_type);
/* Entry points to copy private data. */
#define BFD_JUMP_TABLE_COPY(NAME) \
-CONCAT2 (NAME,_bfd_copy_private_bfd_data), \
-CONCAT2 (NAME,_bfd_merge_private_bfd_data), \
-CONCAT2 (NAME,_bfd_copy_private_section_data), \
-CONCAT2 (NAME,_bfd_copy_private_symbol_data), \
-CONCAT2 (NAME,_bfd_set_private_flags), \
-CONCAT2 (NAME,_bfd_print_private_bfd_data) \
+ NAME##_bfd_copy_private_bfd_data, \
+ NAME##_bfd_merge_private_bfd_data, \
+ NAME##_bfd_copy_private_section_data, \
+ NAME##_bfd_copy_private_symbol_data, \
+ NAME##_bfd_set_private_flags, \
+ NAME##_bfd_print_private_bfd_data
+
/* Called to copy BFD general private data from one object file
to another. */
- boolean (*_bfd_copy_private_bfd_data) PARAMS ((bfd *, bfd *));
+ bfd_boolean (*_bfd_copy_private_bfd_data) (bfd *, bfd *);
/* Called to merge BFD general private data from one object file
to a common output file when linking. */
- boolean (*_bfd_merge_private_bfd_data) PARAMS ((bfd *, bfd *));
+ bfd_boolean (*_bfd_merge_private_bfd_data) (bfd *, bfd *);
/* Called to copy BFD private section data from one object file
to another. */
- boolean (*_bfd_copy_private_section_data) PARAMS ((bfd *, sec_ptr,
- bfd *, sec_ptr));
+ bfd_boolean (*_bfd_copy_private_section_data)
+ (bfd *, sec_ptr, bfd *, sec_ptr);
/* Called to copy BFD private symbol data from one symbol
to another. */
- boolean (*_bfd_copy_private_symbol_data) PARAMS ((bfd *, asymbol *,
- bfd *, asymbol *));
+ bfd_boolean (*_bfd_copy_private_symbol_data)
+ (bfd *, asymbol *, bfd *, asymbol *);
/* Called to set private backend flags. */
- boolean (*_bfd_set_private_flags) PARAMS ((bfd *, flagword));
+ bfd_boolean (*_bfd_set_private_flags) (bfd *, flagword);
/* Called to print private BFD data. */
- boolean (*_bfd_print_private_bfd_data) PARAMS ((bfd *, PTR));
+ bfd_boolean (*_bfd_print_private_bfd_data) (bfd *, void *);
/* Core file entry points. */
#define BFD_JUMP_TABLE_CORE(NAME) \
-CONCAT2 (NAME,_core_file_failing_command), \
-CONCAT2 (NAME,_core_file_failing_signal), \
-CONCAT2 (NAME,_core_file_matches_executable_p)
- char * (*_core_file_failing_command) PARAMS ((bfd *));
- int (*_core_file_failing_signal) PARAMS ((bfd *));
- boolean (*_core_file_matches_executable_p) PARAMS ((bfd *, bfd *));
+ NAME##_core_file_failing_command, \
+ NAME##_core_file_failing_signal, \
+ NAME##_core_file_matches_executable_p
+
+ char * (*_core_file_failing_command) (bfd *);
+ int (*_core_file_failing_signal) (bfd *);
+ bfd_boolean (*_core_file_matches_executable_p) (bfd *, bfd *);
/* Archive entry points. */
#define BFD_JUMP_TABLE_ARCHIVE(NAME) \
-CONCAT2 (NAME,_slurp_armap), \
-CONCAT2 (NAME,_slurp_extended_name_table), \
-CONCAT2 (NAME,_construct_extended_name_table), \
-CONCAT2 (NAME,_truncate_arname), \
-CONCAT2 (NAME,_write_armap), \
-CONCAT2 (NAME,_read_ar_hdr), \
-CONCAT2 (NAME,_openr_next_archived_file), \
-CONCAT2 (NAME,_get_elt_at_index), \
-CONCAT2 (NAME,_generic_stat_arch_elt), \
-CONCAT2 (NAME,_update_armap_timestamp)
- boolean (*_bfd_slurp_armap) PARAMS ((bfd *));
- boolean (*_bfd_slurp_extended_name_table) PARAMS ((bfd *));
- boolean (*_bfd_construct_extended_name_table)
- PARAMS ((bfd *, char **, bfd_size_type *, const char **));
- void (*_bfd_truncate_arname) PARAMS ((bfd *, const char *, char *));
- boolean (*write_armap)
- PARAMS ((bfd *, unsigned int, struct orl *, unsigned int, int));
- PTR (*_bfd_read_ar_hdr_fn) PARAMS ((bfd *));
- bfd * (*openr_next_archived_file) PARAMS ((bfd *, bfd *));
-#define bfd_get_elt_at_index(b,i) BFD_SEND(b, _bfd_get_elt_at_index, (b,i))
- bfd * (*_bfd_get_elt_at_index) PARAMS ((bfd *, symindex));
- int (*_bfd_stat_arch_elt) PARAMS ((bfd *, struct stat *));
- boolean (*_bfd_update_armap_timestamp) PARAMS ((bfd *));
+ NAME##_slurp_armap, \
+ NAME##_slurp_extended_name_table, \
+ NAME##_construct_extended_name_table, \
+ NAME##_truncate_arname, \
+ NAME##_write_armap, \
+ NAME##_read_ar_hdr, \
+ NAME##_openr_next_archived_file, \
+ NAME##_get_elt_at_index, \
+ NAME##_generic_stat_arch_elt, \
+ NAME##_update_armap_timestamp
+
+ bfd_boolean (*_bfd_slurp_armap) (bfd *);
+ bfd_boolean (*_bfd_slurp_extended_name_table) (bfd *);
+ bfd_boolean (*_bfd_construct_extended_name_table)
+ (bfd *, char **, bfd_size_type *, const char **);
+ void (*_bfd_truncate_arname) (bfd *, const char *, char *);
+ bfd_boolean (*write_armap)
+ (bfd *, unsigned int, struct orl *, unsigned int, int);
+ void * (*_bfd_read_ar_hdr_fn) (bfd *);
+ bfd * (*openr_next_archived_file) (bfd *, bfd *);
+#define bfd_get_elt_at_index(b,i) BFD_SEND (b, _bfd_get_elt_at_index, (b,i))
+ bfd * (*_bfd_get_elt_at_index) (bfd *, symindex);
+ int (*_bfd_stat_arch_elt) (bfd *, struct stat *);
+ bfd_boolean (*_bfd_update_armap_timestamp) (bfd *);
/* Entry points used for symbols. */
#define BFD_JUMP_TABLE_SYMBOLS(NAME) \
-CONCAT2 (NAME,_get_symtab_upper_bound), \
-CONCAT2 (NAME,_get_symtab), \
-CONCAT2 (NAME,_make_empty_symbol), \
-CONCAT2 (NAME,_print_symbol), \
-CONCAT2 (NAME,_get_symbol_info), \
-CONCAT2 (NAME,_bfd_is_local_label_name), \
-CONCAT2 (NAME,_get_lineno), \
-CONCAT2 (NAME,_find_nearest_line), \
-CONCAT2 (NAME,_bfd_make_debug_symbol), \
-CONCAT2 (NAME,_read_minisymbols), \
-CONCAT2 (NAME,_minisymbol_to_symbol)
- long (*_bfd_get_symtab_upper_bound) PARAMS ((bfd *));
- long (*_bfd_canonicalize_symtab) PARAMS ((bfd *,
- struct symbol_cache_entry **));
- struct symbol_cache_entry *
- (*_bfd_make_empty_symbol) PARAMS ((bfd *));
- void (*_bfd_print_symbol) PARAMS ((bfd *, PTR,
- struct symbol_cache_entry *,
- bfd_print_symbol_type));
-#define bfd_print_symbol(b,p,s,e) BFD_SEND(b, _bfd_print_symbol, (b,p,s,e))
- void (*_bfd_get_symbol_info) PARAMS ((bfd *,
- struct symbol_cache_entry *,
- symbol_info *));
-#define bfd_get_symbol_info(b,p,e) BFD_SEND(b, _bfd_get_symbol_info, (b,p,e))
- boolean (*_bfd_is_local_label_name) PARAMS ((bfd *, const char *));
-
- alent * (*_get_lineno) PARAMS ((bfd *, struct symbol_cache_entry *));
- boolean (*_bfd_find_nearest_line)
- PARAMS ((bfd *, struct sec *, struct symbol_cache_entry **, bfd_vma,
- const char **, const char **, unsigned int *));
+ NAME##_get_symtab_upper_bound, \
+ NAME##_canonicalize_symtab, \
+ NAME##_make_empty_symbol, \
+ NAME##_print_symbol, \
+ NAME##_get_symbol_info, \
+ NAME##_bfd_is_local_label_name, \
+ NAME##_get_lineno, \
+ NAME##_find_nearest_line, \
+ NAME##_bfd_make_debug_symbol, \
+ NAME##_read_minisymbols, \
+ NAME##_minisymbol_to_symbol
+
+ long (*_bfd_get_symtab_upper_bound) (bfd *);
+ long (*_bfd_canonicalize_symtab)
+ (bfd *, struct bfd_symbol **);
+ struct bfd_symbol *
+ (*_bfd_make_empty_symbol) (bfd *);
+ void (*_bfd_print_symbol)
+ (bfd *, void *, struct bfd_symbol *, bfd_print_symbol_type);
+#define bfd_print_symbol(b,p,s,e) BFD_SEND (b, _bfd_print_symbol, (b,p,s,e))
+ void (*_bfd_get_symbol_info)
+ (bfd *, struct bfd_symbol *, symbol_info *);
+#define bfd_get_symbol_info(b,p,e) BFD_SEND (b, _bfd_get_symbol_info, (b,p,e))
+ bfd_boolean (*_bfd_is_local_label_name) (bfd *, const char *);
+
+ alent * (*_get_lineno) (bfd *, struct bfd_symbol *);
+ bfd_boolean (*_bfd_find_nearest_line)
+ (bfd *, struct bfd_section *, struct bfd_symbol **, bfd_vma,
+ const char **, const char **, unsigned int *);
/* Back-door to allow format-aware applications to create debug symbols
while using BFD for everything else. Currently used by the assembler
when creating COFF files. */
- asymbol *(*_bfd_make_debug_symbol) PARAMS ((bfd *, void *,
- unsigned long size));
+ asymbol * (*_bfd_make_debug_symbol)
+ (bfd *, void *, unsigned long size);
#define bfd_read_minisymbols(b, d, m, s) \
BFD_SEND (b, _read_minisymbols, (b, d, m, s))
- long (*_read_minisymbols) PARAMS ((bfd *, boolean, PTR *,
- unsigned int *));
+ long (*_read_minisymbols)
+ (bfd *, bfd_boolean, void **, unsigned int *);
#define bfd_minisymbol_to_symbol(b, d, m, f) \
BFD_SEND (b, _minisymbol_to_symbol, (b, d, m, f))
- asymbol *(*_minisymbol_to_symbol) PARAMS ((bfd *, boolean, const PTR,
- asymbol *));
+ asymbol * (*_minisymbol_to_symbol)
+ (bfd *, bfd_boolean, const void *, asymbol *);
/* Routines for relocs. */
#define BFD_JUMP_TABLE_RELOCS(NAME) \
-CONCAT2 (NAME,_get_reloc_upper_bound), \
-CONCAT2 (NAME,_canonicalize_reloc), \
-CONCAT2 (NAME,_bfd_reloc_type_lookup)
- long (*_get_reloc_upper_bound) PARAMS ((bfd *, sec_ptr));
- long (*_bfd_canonicalize_reloc) PARAMS ((bfd *, sec_ptr, arelent **,
- struct symbol_cache_entry **));
+ NAME##_get_reloc_upper_bound, \
+ NAME##_canonicalize_reloc, \
+ NAME##_bfd_reloc_type_lookup
+
+ long (*_get_reloc_upper_bound) (bfd *, sec_ptr);
+ long (*_bfd_canonicalize_reloc)
+ (bfd *, sec_ptr, arelent **, struct bfd_symbol **);
/* See documentation on reloc types. */
reloc_howto_type *
- (*reloc_type_lookup) PARAMS ((bfd *, bfd_reloc_code_real_type));
+ (*reloc_type_lookup) (bfd *, bfd_reloc_code_real_type);
/* Routines used when writing an object file. */
#define BFD_JUMP_TABLE_WRITE(NAME) \
-CONCAT2 (NAME,_set_arch_mach), \
-CONCAT2 (NAME,_set_section_contents)
- boolean (*_bfd_set_arch_mach) PARAMS ((bfd *, enum bfd_architecture,
- unsigned long));
- boolean (*_bfd_set_section_contents) PARAMS ((bfd *, sec_ptr, PTR,
- file_ptr, bfd_size_type));
+ NAME##_set_arch_mach, \
+ NAME##_set_section_contents
+
+ bfd_boolean (*_bfd_set_arch_mach)
+ (bfd *, enum bfd_architecture, unsigned long);
+ bfd_boolean (*_bfd_set_section_contents)
+ (bfd *, sec_ptr, const void *, file_ptr, bfd_size_type);
/* Routines used by the linker. */
#define BFD_JUMP_TABLE_LINK(NAME) \
-CONCAT2 (NAME,_sizeof_headers), \
-CONCAT2 (NAME,_bfd_get_relocated_section_contents), \
-CONCAT2 (NAME,_bfd_relax_section), \
-CONCAT2 (NAME,_bfd_link_hash_table_create), \
-CONCAT2 (NAME,_bfd_link_hash_table_free), \
-CONCAT2 (NAME,_bfd_link_add_symbols), \
-CONCAT2 (NAME,_bfd_link_just_syms), \
-CONCAT2 (NAME,_bfd_final_link), \
-CONCAT2 (NAME,_bfd_link_split_section), \
-CONCAT2 (NAME,_bfd_gc_sections), \
-CONCAT2 (NAME,_bfd_merge_sections), \
-CONCAT2 (NAME,_bfd_discard_group)
- int (*_bfd_sizeof_headers) PARAMS ((bfd *, boolean));
- bfd_byte *(*_bfd_get_relocated_section_contents)
- PARAMS ((bfd *, struct bfd_link_info *, struct bfd_link_order *,
- bfd_byte *, boolean, struct symbol_cache_entry **));
-
- boolean (*_bfd_relax_section)
- PARAMS ((bfd *, struct sec *, struct bfd_link_info *, boolean *));
+ NAME##_sizeof_headers, \
+ NAME##_bfd_get_relocated_section_contents, \
+ NAME##_bfd_relax_section, \
+ NAME##_bfd_link_hash_table_create, \
+ NAME##_bfd_link_hash_table_free, \
+ NAME##_bfd_link_add_symbols, \
+ NAME##_bfd_link_just_syms, \
+ NAME##_bfd_final_link, \
+ NAME##_bfd_link_split_section, \
+ NAME##_bfd_gc_sections, \
+ NAME##_bfd_merge_sections, \
+ NAME##_bfd_discard_group
+
+ int (*_bfd_sizeof_headers) (bfd *, bfd_boolean);
+ bfd_byte * (*_bfd_get_relocated_section_contents)
+ (bfd *, struct bfd_link_info *, struct bfd_link_order *,
+ bfd_byte *, bfd_boolean, struct bfd_symbol **);
+
+ bfd_boolean (*_bfd_relax_section)
+ (bfd *, struct bfd_section *, struct bfd_link_info *, bfd_boolean *);
/* Create a hash table for the linker. Different backends store
different information in this table. */
- struct bfd_link_hash_table *(*_bfd_link_hash_table_create) PARAMS ((bfd *));
+ struct bfd_link_hash_table *
+ (*_bfd_link_hash_table_create) (bfd *);
/* Release the memory associated with the linker hash table. */
- void (*_bfd_link_hash_table_free) PARAMS ((struct bfd_link_hash_table *));
+ void (*_bfd_link_hash_table_free) (struct bfd_link_hash_table *);
/* Add symbols from this object file into the hash table. */
- boolean (*_bfd_link_add_symbols) PARAMS ((bfd *, struct bfd_link_info *));
+ bfd_boolean (*_bfd_link_add_symbols) (bfd *, struct bfd_link_info *);
/* Indicate that we are only retrieving symbol values from this section. */
- void (*_bfd_link_just_syms) PARAMS ((asection *, struct bfd_link_info *));
+ void (*_bfd_link_just_syms) (asection *, struct bfd_link_info *);
/* Do a link based on the link_order structures attached to each
section of the BFD. */
- boolean (*_bfd_final_link) PARAMS ((bfd *, struct bfd_link_info *));
+ bfd_boolean (*_bfd_final_link) (bfd *, struct bfd_link_info *);
/* Should this section be split up into smaller pieces during linking. */
- boolean (*_bfd_link_split_section) PARAMS ((bfd *, struct sec *));
+ bfd_boolean (*_bfd_link_split_section) (bfd *, struct bfd_section *);
/* Remove sections that are not referenced from the output. */
- boolean (*_bfd_gc_sections) PARAMS ((bfd *, struct bfd_link_info *));
+ bfd_boolean (*_bfd_gc_sections) (bfd *, struct bfd_link_info *);
/* Attempt to merge SEC_MERGE sections. */
- boolean (*_bfd_merge_sections) PARAMS ((bfd *, struct bfd_link_info *));
+ bfd_boolean (*_bfd_merge_sections) (bfd *, struct bfd_link_info *);
/* Discard members of a group. */
- boolean (*_bfd_discard_group) PARAMS ((bfd *, struct sec *));
+ bfd_boolean (*_bfd_discard_group) (bfd *, struct bfd_section *);
/* Routines to handle dynamic symbols and relocs. */
#define BFD_JUMP_TABLE_DYNAMIC(NAME) \
-CONCAT2 (NAME,_get_dynamic_symtab_upper_bound), \
-CONCAT2 (NAME,_canonicalize_dynamic_symtab), \
-CONCAT2 (NAME,_get_dynamic_reloc_upper_bound), \
-CONCAT2 (NAME,_canonicalize_dynamic_reloc)
+ NAME##_get_dynamic_symtab_upper_bound, \
+ NAME##_canonicalize_dynamic_symtab, \
+ NAME##_get_dynamic_reloc_upper_bound, \
+ NAME##_canonicalize_dynamic_reloc
+
/* Get the amount of memory required to hold the dynamic symbols. */
- long (*_bfd_get_dynamic_symtab_upper_bound) PARAMS ((bfd *));
+ long (*_bfd_get_dynamic_symtab_upper_bound) (bfd *);
/* Read in the dynamic symbols. */
- long (*_bfd_canonicalize_dynamic_symtab)
- PARAMS ((bfd *, struct symbol_cache_entry **));
+ long (*_bfd_canonicalize_dynamic_symtab)
+ (bfd *, struct bfd_symbol **);
/* Get the amount of memory required to hold the dynamic relocs. */
- long (*_bfd_get_dynamic_reloc_upper_bound) PARAMS ((bfd *));
+ long (*_bfd_get_dynamic_reloc_upper_bound) (bfd *);
/* Read in the dynamic relocs. */
- long (*_bfd_canonicalize_dynamic_reloc)
- PARAMS ((bfd *, arelent **, struct symbol_cache_entry **));
+ long (*_bfd_canonicalize_dynamic_reloc)
+ (bfd *, arelent **, struct bfd_symbol **);
@end example
A pointer to an alternative bfd_target in case the current one is not
@@ -449,7 +455,7 @@ to find an alternative output format that is suitable.
/* Data for use by back-end routines, which isn't
generic enough to belong in this structure. */
- PTR backend_data;
+ const void *backend_data;
@} bfd_target;
@@ -459,7 +465,7 @@ to find an alternative output format that is suitable.
@subsubsection @code{bfd_set_default_target}
@strong{Synopsis}
@example
-boolean bfd_set_default_target (const char *name);
+bfd_boolean bfd_set_default_target (const char *name);
@end example
@strong{Description}@*
Set the default target vector to use when recognizing a BFD.
@@ -470,7 +476,7 @@ name or a configuration triplet.
@subsubsection @code{bfd_find_target}
@strong{Synopsis}
@example
-const bfd_target *bfd_find_target(const char *target_name, bfd *abfd);
+const bfd_target *bfd_find_target (const char *target_name, bfd *abfd);
@end example
@strong{Description}@*
Return a pointer to the transfer vector for the object target
@@ -487,7 +493,7 @@ targets to find the one that matches the file being read.
@subsubsection @code{bfd_target_list}
@strong{Synopsis}
@example
-const char **bfd_target_list(void);
+const char ** bfd_target_list (void);
@end example
@strong{Description}@*
Return a freshly malloced NULL-terminated
@@ -498,7 +504,9 @@ modify the names.
@subsubsection @code{bfd_seach_for_target}
@strong{Synopsis}
@example
-const bfd_target * bfd_search_for_target (int (* search_func) (const bfd_target *, void *), void *);
+const bfd_target *bfd_search_for_target
+ (int (*search_func) (const bfd_target *, void *),
+ void *);
@end example
@strong{Description}@*
Return a pointer to the first transfer vector in the list of
diff --git a/contrib/binutils/bfd/dwarf1.c b/contrib/binutils/bfd/dwarf1.c
index 6531986..1047ebf 100644
--- a/contrib/binutils/bfd/dwarf1.c
+++ b/contrib/binutils/bfd/dwarf1.c
@@ -1,5 +1,5 @@
/* DWARF 1 find nearest line (_bfd_dwarf1_find_nearest_line).
- Copyright 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
Written by Gavin Romig-Koch of Cygnus Solutions (gavin@cygnus.com).
@@ -126,15 +126,17 @@ struct linenumber {
/* Find the form of an attr, from the attr field. */
#define FORM_FROM_ATTR(attr) ((attr) & 0xF) /* Implicitly specified */
-static struct dwarf1_unit *alloc_dwarf1_unit PARAMS ((struct dwarf1_debug *));
+static struct dwarf1_unit *alloc_dwarf1_unit
+ PARAMS ((struct dwarf1_debug *));
static struct dwarf1_func *alloc_dwarf1_func
PARAMS ((struct dwarf1_debug *, struct dwarf1_unit *));
-static boolean parse_die PARAMS ((bfd *, struct die_info *, char *, char *));
-static boolean parse_line_table
+static bfd_boolean parse_die
+ PARAMS ((bfd *, struct die_info *, char *, char *));
+static bfd_boolean parse_line_table
PARAMS ((struct dwarf1_debug *, struct dwarf1_unit *));
-static boolean parse_functions_in_unit
+static bfd_boolean parse_functions_in_unit
PARAMS ((struct dwarf1_debug *, struct dwarf1_unit *));
-static boolean dwarf1_unit_find_nearest_line
+static bfd_boolean dwarf1_unit_find_nearest_line
PARAMS ((struct dwarf1_debug *, struct dwarf1_unit *, unsigned long,
const char **, const char **, unsigned int *));
@@ -176,9 +178,9 @@ alloc_dwarf1_func (stash, aUnit)
'abfd' must be the bfd from which the section that 'aDiePtr'
points to was pulled from.
- Return false if the die is invalidly formatted; true otherwise. */
+ Return FALSE if the die is invalidly formatted; TRUE otherwise. */
-static boolean
+static bfd_boolean
parse_die (abfd, aDieInfo, aDiePtr, aDiePtrEnd)
bfd* abfd;
struct die_info* aDieInfo;
@@ -195,12 +197,12 @@ parse_die (abfd, aDieInfo, aDiePtr, aDiePtrEnd)
xptr += 4;
if (aDieInfo->length == 0
|| (this_die + aDieInfo->length) >= aDiePtrEnd)
- return false;
+ return FALSE;
if (aDieInfo->length < 6)
{
/* Just padding bytes. */
aDieInfo->tag = TAG_padding;
- return true;
+ return TRUE;
}
/* Then the tag. */
@@ -259,14 +261,14 @@ parse_die (abfd, aDieInfo, aDiePtr, aDiePtrEnd)
}
}
- return true;
+ return TRUE;
}
/* Parse a dwarf1 line number table for 'aUnit->stmt_list_offset'
- into 'aUnit->linenumber_table'. Return false if an error
- occurs; true otherwise. */
+ into 'aUnit->linenumber_table'. Return FALSE if an error
+ occurs; TRUE otherwise. */
-static boolean
+static bfd_boolean
parse_line_table (stash, aUnit)
struct dwarf1_debug* stash;
struct dwarf1_unit* aUnit;
@@ -281,19 +283,19 @@ parse_line_table (stash, aUnit)
msec = bfd_get_section_by_name (stash->abfd, ".line");
if (! msec)
- return false;
+ return FALSE;
size = bfd_get_section_size_before_reloc (msec);
stash->line_section = (char *) bfd_alloc (stash->abfd, size);
if (! stash->line_section)
- return false;
+ return FALSE;
if (! bfd_get_section_contents (stash->abfd, msec, stash->line_section,
(bfd_vma) 0, size))
{
stash->line_section = 0;
- return false;
+ return FALSE;
}
stash->line_section_end = stash->line_section + size;
@@ -341,15 +343,15 @@ parse_line_table (stash, aUnit)
}
}
- return true;
+ return TRUE;
}
/* Parse each function die in a compilation unit 'aUnit'.
The first child die of 'aUnit' should be in 'aUnit->first_child',
the result is placed in 'aUnit->func_list'.
- Return false if error; true otherwise. */
+ Return FALSE if error; TRUE otherwise. */
-static boolean
+static bfd_boolean
parse_functions_in_unit (stash, aUnit)
struct dwarf1_debug* stash;
struct dwarf1_unit* aUnit;
@@ -365,7 +367,7 @@ parse_functions_in_unit (stash, aUnit)
if (! parse_die (stash->abfd, &eachDieInfo, eachDie,
stash->debug_section_end))
- return false;
+ return FALSE;
if (eachDieInfo.tag == TAG_global_subroutine
|| eachDieInfo.tag == TAG_subroutine
@@ -386,13 +388,13 @@ parse_functions_in_unit (stash, aUnit)
break;
}
- return true;
+ return TRUE;
}
/* Find the nearest line to 'addr' in 'aUnit'.
Return whether we found the line (or a function) without error. */
-static boolean
+static bfd_boolean
dwarf1_unit_find_nearest_line (stash, aUnit, addr,
filename_ptr, functionname_ptr,
linenumber_ptr)
@@ -403,8 +405,8 @@ dwarf1_unit_find_nearest_line (stash, aUnit, addr,
const char **functionname_ptr;
unsigned int *linenumber_ptr;
{
- int line_p = false;
- int func_p = false;
+ int line_p = FALSE;
+ int func_p = FALSE;
if (aUnit->low_pc <= addr && addr < aUnit->high_pc)
{
@@ -416,13 +418,13 @@ dwarf1_unit_find_nearest_line (stash, aUnit, addr,
if (! aUnit->linenumber_table)
{
if (! parse_line_table (stash, aUnit))
- return false;
+ return FALSE;
}
if (! aUnit->func_list)
{
if (! parse_functions_in_unit (stash, aUnit))
- return false;
+ return FALSE;
}
for (i = 0; i < aUnit->line_count; i++)
@@ -432,7 +434,7 @@ dwarf1_unit_find_nearest_line (stash, aUnit, addr,
{
*filename_ptr = aUnit->name;
*linenumber_ptr = aUnit->linenumber_table[i].linenumber;
- line_p = true;
+ line_p = TRUE;
break;
}
}
@@ -445,7 +447,7 @@ dwarf1_unit_find_nearest_line (stash, aUnit, addr,
&& addr < eachFunc->high_pc)
{
*functionname_ptr = eachFunc->name;
- func_p = true;
+ func_p = TRUE;
break;
}
}
@@ -456,9 +458,9 @@ dwarf1_unit_find_nearest_line (stash, aUnit, addr,
}
/* The DWARF 1 version of find_nearest line.
- Return true if the line is found without error. */
+ Return TRUE if the line is found without error. */
-boolean
+bfd_boolean
_bfd_dwarf1_find_nearest_line (abfd, section, symbols, offset,
filename_ptr, functionname_ptr, linenumber_ptr)
bfd *abfd;
@@ -489,7 +491,7 @@ _bfd_dwarf1_find_nearest_line (abfd, section, symbols, offset,
= (struct dwarf1_debug *) bfd_zalloc (abfd, size);
if (! stash)
- return false;
+ return FALSE;
msec = bfd_get_section_by_name (abfd, ".debug");
if (! msec)
@@ -497,20 +499,20 @@ _bfd_dwarf1_find_nearest_line (abfd, section, symbols, offset,
/* No dwarf1 info. Note that at this point the stash
has been allocated, but contains zeros, this lets
future calls to this function fail quicker. */
- return false;
+ return FALSE;
}
size = bfd_get_section_size_before_reloc (msec);
stash->debug_section = (char *) bfd_alloc (abfd, size);
if (! stash->debug_section)
- return false;
+ return FALSE;
if (! bfd_get_section_contents (abfd, msec, stash->debug_section,
(bfd_vma) 0, size))
{
stash->debug_section = 0;
- return false;
+ return FALSE;
}
stash->debug_section_end = stash->debug_section + size;
@@ -522,7 +524,7 @@ _bfd_dwarf1_find_nearest_line (abfd, section, symbols, offset,
or that an error occured while setting up the stash. */
if (! stash->debug_section)
- return false;
+ return FALSE;
/* Look at the previously parsed units to see if any contain
the addr. */
@@ -541,7 +543,7 @@ _bfd_dwarf1_find_nearest_line (abfd, section, symbols, offset,
if (! parse_die (stash->abfd, &aDieInfo, stash->currentDie,
stash->debug_section_end))
- return false;
+ return FALSE;
if (aDieInfo.tag == TAG_compile_unit)
{
@@ -578,7 +580,7 @@ _bfd_dwarf1_find_nearest_line (abfd, section, symbols, offset,
stash->currentDie += aDieInfo.length;
}
- return false;
+ return FALSE;
}
/* EOF */
diff --git a/contrib/binutils/bfd/dwarf2.c b/contrib/binutils/bfd/dwarf2.c
index 0639826..6182ea9 100644
--- a/contrib/binutils/bfd/dwarf2.c
+++ b/contrib/binutils/bfd/dwarf2.c
@@ -1,6 +1,6 @@
/* DWARF 2 support.
- Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
- Free Software Foundation, Inc.
+ Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
+ 2004 Free Software Foundation, Inc.
Adapted from gdb/dwarf2read.c by Gavin Koch of Cygnus Solutions
(gavin@cygnus.com).
@@ -61,21 +61,12 @@ struct attribute
{
char *str;
struct dwarf_block *blk;
- unsigned int unsnd;
- int snd;
- bfd_vma addr;
+ bfd_uint64_t val;
+ bfd_int64_t sval;
}
u;
};
-/* Get at parts of an attribute structure. */
-
-#define DW_STRING(attr) ((attr)->u.str)
-#define DW_UNSND(attr) ((attr)->u.unsnd)
-#define DW_BLOCK(attr) ((attr)->u.blk)
-#define DW_SND(attr) ((attr)->u.snd)
-#define DW_ADDR(attr) ((attr)->u.addr)
-
/* Blocks are a bunch of untyped bytes. */
struct dwarf_block
{
@@ -157,7 +148,7 @@ struct comp_unit
/* The DW_AT_comp_dir attribute. */
char* comp_dir;
- /* True if there is a line number table associated with this comp. unit. */
+ /* TRUE if there is a line number table associated with this comp. unit. */
int stmtlist;
/* The offset into .debug_line of the line number table. */
@@ -209,53 +200,6 @@ struct attr_abbrev
#define ATTR_ALLOC_CHUNK 4
#endif
-static unsigned int read_1_byte PARAMS ((bfd *, char *));
-static int read_1_signed_byte PARAMS ((bfd *, char *));
-static unsigned int read_2_bytes PARAMS ((bfd *, char *));
-static unsigned int read_4_bytes PARAMS ((bfd *, char *));
-static bfd_vma read_8_bytes PARAMS ((bfd *, char *));
-static char *read_n_bytes PARAMS ((bfd *, char *, unsigned int));
-static char *read_string PARAMS ((bfd *, char *, unsigned int *));
-static char *read_indirect_string PARAMS ((struct comp_unit *, char *, unsigned int *));
-static unsigned int read_unsigned_leb128
- PARAMS ((bfd *, char *, unsigned int *));
-static int read_signed_leb128
- PARAMS ((bfd *, char *, unsigned int *));
-static bfd_vma read_address PARAMS ((struct comp_unit *, char *));
-static struct abbrev_info *lookup_abbrev
- PARAMS ((unsigned int, struct abbrev_info **));
-static struct abbrev_info **read_abbrevs
- PARAMS ((bfd *, bfd_vma, struct dwarf2_debug *));
-static char *read_attribute
- PARAMS ((struct attribute *, struct attr_abbrev *,
- struct comp_unit *, char *));
-static char *read_attribute_value
- PARAMS ((struct attribute *, unsigned,
- struct comp_unit *, char *));
-static void add_line_info
- PARAMS ((struct line_info_table *, bfd_vma, char *,
- unsigned int, unsigned int, int));
-static char *concat_filename PARAMS ((struct line_info_table *, unsigned int));
-static void arange_add PARAMS ((struct comp_unit *, bfd_vma, bfd_vma));
-static struct line_info_table *decode_line_info
- PARAMS ((struct comp_unit *, struct dwarf2_debug *));
-static boolean lookup_address_in_line_info_table
- PARAMS ((struct line_info_table *, bfd_vma, struct funcinfo *,
- const char **, unsigned int *));
-static boolean lookup_address_in_function_table
- PARAMS ((struct funcinfo *, bfd_vma, struct funcinfo **, const char **));
-static boolean scan_unit_for_functions PARAMS ((struct comp_unit *));
-static bfd_vma find_rela_addend
- PARAMS ((bfd *, asection *, bfd_size_type, asymbol**));
-static struct comp_unit *parse_comp_unit
- PARAMS ((bfd *, struct dwarf2_debug *, bfd_vma, unsigned int));
-static boolean comp_unit_contains_address
- PARAMS ((struct comp_unit *, bfd_vma));
-static boolean comp_unit_find_nearest_line
- PARAMS ((struct comp_unit *, bfd_vma, const char **, const char **,
- unsigned int *, struct dwarf2_debug *));
-static asection *find_debug_info PARAMS ((bfd *, asection *));
-
/* VERBATIM
The following function up to the END VERBATIM mark are
copied directly from dwarf2read.c. */
@@ -263,74 +207,39 @@ static asection *find_debug_info PARAMS ((bfd *, asection *));
/* Read dwarf information from a buffer. */
static unsigned int
-read_1_byte (abfd, buf)
- bfd *abfd ATTRIBUTE_UNUSED;
- char *buf;
+read_1_byte (bfd *abfd ATTRIBUTE_UNUSED, char *buf)
{
- return bfd_get_8 (abfd, (bfd_byte *) buf);
+ return bfd_get_8 (abfd, buf);
}
static int
-read_1_signed_byte (abfd, buf)
- bfd *abfd ATTRIBUTE_UNUSED;
- char *buf;
+read_1_signed_byte (bfd *abfd ATTRIBUTE_UNUSED, char *buf)
{
- return bfd_get_signed_8 (abfd, (bfd_byte *) buf);
+ return bfd_get_signed_8 (abfd, buf);
}
static unsigned int
-read_2_bytes (abfd, buf)
- bfd *abfd;
- char *buf;
+read_2_bytes (bfd *abfd, char *buf)
{
- return bfd_get_16 (abfd, (bfd_byte *) buf);
+ return bfd_get_16 (abfd, buf);
}
-#if 0 /* This is not used. */
-
-static int
-read_2_signed_bytes (abfd, buf)
- bfd *abfd;
- char *buf;
-{
- return bfd_get_signed_16 (abfd, (bfd_byte *) buf);
-}
-
-#endif
-
static unsigned int
-read_4_bytes (abfd, buf)
- bfd *abfd;
- char *buf;
-{
- return bfd_get_32 (abfd, (bfd_byte *) buf);
-}
-
-#if 0 /* This is not used. */
-
-static int
-read_4_signed_bytes (abfd, buf)
- bfd *abfd;
- char *buf;
+read_4_bytes (bfd *abfd, char *buf)
{
- return bfd_get_signed_32 (abfd, (bfd_byte *) buf);
+ return bfd_get_32 (abfd, buf);
}
-#endif
-
-static bfd_vma
-read_8_bytes (abfd, buf)
- bfd *abfd;
- char *buf;
+static bfd_uint64_t
+read_8_bytes (bfd *abfd, char *buf)
{
- return bfd_get_64 (abfd, (bfd_byte *) buf);
+ return bfd_get_64 (abfd, buf);
}
static char *
-read_n_bytes (abfd, buf, size)
- bfd *abfd ATTRIBUTE_UNUSED;
- char *buf;
- unsigned int size ATTRIBUTE_UNUSED;
+read_n_bytes (bfd *abfd ATTRIBUTE_UNUSED,
+ char *buf,
+ unsigned int size ATTRIBUTE_UNUSED)
{
/* If the size of a host char is 8 bits, we can return a pointer
to the buffer, otherwise we have to copy the data to a buffer
@@ -339,10 +248,9 @@ read_n_bytes (abfd, buf, size)
}
static char *
-read_string (abfd, buf, bytes_read_ptr)
- bfd *abfd ATTRIBUTE_UNUSED;
- char *buf;
- unsigned int *bytes_read_ptr;
+read_string (bfd *abfd ATTRIBUTE_UNUSED,
+ char *buf,
+ unsigned int *bytes_read_ptr)
{
/* Return a pointer to the embedded string. */
if (*buf == '\0')
@@ -356,12 +264,11 @@ read_string (abfd, buf, bytes_read_ptr)
}
static char *
-read_indirect_string (unit, buf, bytes_read_ptr)
- struct comp_unit* unit;
- char *buf;
- unsigned int *bytes_read_ptr;
+read_indirect_string (struct comp_unit* unit,
+ char *buf,
+ unsigned int *bytes_read_ptr)
{
- bfd_vma offset;
+ bfd_uint64_t offset;
struct dwarf2_debug *stash = unit->stash;
if (unit->offset_size == 4)
@@ -385,12 +292,12 @@ read_indirect_string (unit, buf, bytes_read_ptr)
}
stash->dwarf_str_size = msec->_raw_size;
- stash->dwarf_str_buffer = (char*) bfd_alloc (abfd, msec->_raw_size);
+ stash->dwarf_str_buffer = bfd_alloc (abfd, msec->_raw_size);
if (! stash->dwarf_abbrev_buffer)
return NULL;
if (! bfd_get_section_contents (abfd, msec, stash->dwarf_str_buffer,
- (bfd_vma) 0, msec->_raw_size))
+ 0, msec->_raw_size))
return NULL;
}
@@ -409,10 +316,9 @@ read_indirect_string (unit, buf, bytes_read_ptr)
}
static unsigned int
-read_unsigned_leb128 (abfd, buf, bytes_read_ptr)
- bfd *abfd ATTRIBUTE_UNUSED;
- char *buf;
- unsigned int *bytes_read_ptr;
+read_unsigned_leb128 (bfd *abfd ATTRIBUTE_UNUSED,
+ char *buf,
+ unsigned int *bytes_read_ptr)
{
unsigned int result;
unsigned int num_read;
@@ -425,7 +331,7 @@ read_unsigned_leb128 (abfd, buf, bytes_read_ptr)
do
{
- byte = bfd_get_8 (abfd, (bfd_byte *) buf);
+ byte = bfd_get_8 (abfd, buf);
buf ++;
num_read ++;
result |= ((byte & 0x7f) << shift);
@@ -439,10 +345,9 @@ read_unsigned_leb128 (abfd, buf, bytes_read_ptr)
}
static int
-read_signed_leb128 (abfd, buf, bytes_read_ptr)
- bfd *abfd ATTRIBUTE_UNUSED;
- char *buf;
- unsigned int * bytes_read_ptr;
+read_signed_leb128 (bfd *abfd ATTRIBUTE_UNUSED,
+ char *buf,
+ unsigned int * bytes_read_ptr)
{
int result;
int shift;
@@ -455,7 +360,7 @@ read_signed_leb128 (abfd, buf, bytes_read_ptr)
do
{
- byte = bfd_get_8 (abfd, (bfd_byte *) buf);
+ byte = bfd_get_8 (abfd, buf);
buf ++;
num_read ++;
result |= ((byte & 0x7f) << shift);
@@ -473,19 +378,17 @@ read_signed_leb128 (abfd, buf, bytes_read_ptr)
/* END VERBATIM */
-static bfd_vma
-read_address (unit, buf)
- struct comp_unit* unit;
- char *buf;
+static bfd_uint64_t
+read_address (struct comp_unit *unit, char *buf)
{
switch (unit->addr_size)
{
case 8:
- return bfd_get_64 (unit->abfd, (bfd_byte *) buf);
+ return bfd_get_64 (unit->abfd, buf);
case 4:
- return bfd_get_32 (unit->abfd, (bfd_byte *) buf);
+ return bfd_get_32 (unit->abfd, buf);
case 2:
- return bfd_get_16 (unit->abfd, (bfd_byte *) buf);
+ return bfd_get_16 (unit->abfd, buf);
default:
abort ();
}
@@ -494,9 +397,7 @@ read_address (unit, buf)
/* Lookup an abbrev_info structure in the abbrev hash table. */
static struct abbrev_info *
-lookup_abbrev (number,abbrevs)
- unsigned int number;
- struct abbrev_info **abbrevs;
+lookup_abbrev (unsigned int number, struct abbrev_info **abbrevs)
{
unsigned int hash_number;
struct abbrev_info *abbrev;
@@ -521,10 +422,7 @@ lookup_abbrev (number,abbrevs)
in a hash table. */
static struct abbrev_info**
-read_abbrevs (abfd, offset, stash)
- bfd * abfd;
- bfd_vma offset;
- struct dwarf2_debug *stash;
+read_abbrevs (bfd *abfd, bfd_uint64_t offset, struct dwarf2_debug *stash)
{
struct abbrev_info **abbrevs;
char *abbrev_ptr;
@@ -546,13 +444,11 @@ read_abbrevs (abfd, offset, stash)
}
stash->dwarf_abbrev_size = msec->_raw_size;
- stash->dwarf_abbrev_buffer = (char*) bfd_alloc (abfd, msec->_raw_size);
+ stash->dwarf_abbrev_buffer
+ = bfd_simple_get_relocated_section_contents (abfd, msec, NULL,
+ stash->syms);
if (! stash->dwarf_abbrev_buffer)
return 0;
-
- if (! bfd_get_section_contents (abfd, msec, stash->dwarf_abbrev_buffer,
- (bfd_vma) 0, msec->_raw_size))
- return 0;
}
if (offset >= stash->dwarf_abbrev_size)
@@ -564,7 +460,7 @@ read_abbrevs (abfd, offset, stash)
}
amt = sizeof (struct abbrev_info*) * ABBREV_HASH_SIZE;
- abbrevs = (struct abbrev_info**) bfd_zalloc (abfd, amt);
+ abbrevs = bfd_zalloc (abfd, amt);
abbrev_ptr = stash->dwarf_abbrev_buffer + offset;
abbrev_number = read_unsigned_leb128 (abfd, abbrev_ptr, &bytes_read);
@@ -574,7 +470,7 @@ read_abbrevs (abfd, offset, stash)
while (abbrev_number)
{
amt = sizeof (struct abbrev_info);
- cur_abbrev = (struct abbrev_info *) bfd_zalloc (abfd, amt);
+ cur_abbrev = bfd_zalloc (abfd, amt);
/* Read in abbrev header. */
cur_abbrev->number = abbrev_number;
@@ -596,8 +492,7 @@ read_abbrevs (abfd, offset, stash)
{
amt = cur_abbrev->num_attrs + ATTR_ALLOC_CHUNK;
amt *= sizeof (struct attr_abbrev);
- cur_abbrev->attrs = ((struct attr_abbrev *)
- bfd_realloc (cur_abbrev->attrs, amt));
+ cur_abbrev->attrs = bfd_realloc (cur_abbrev->attrs, amt);
if (! cur_abbrev->attrs)
return 0;
}
@@ -638,11 +533,10 @@ read_abbrevs (abfd, offset, stash)
/* Read an attribute value described by an attribute form. */
static char *
-read_attribute_value (attr, form, unit, info_ptr)
- struct attribute *attr;
- unsigned form;
- struct comp_unit *unit;
- char *info_ptr;
+read_attribute_value (struct attribute *attr,
+ unsigned form,
+ struct comp_unit *unit,
+ char *info_ptr)
{
bfd *abfd = unit->abfd;
unsigned int bytes_read;
@@ -654,101 +548,101 @@ read_attribute_value (attr, form, unit, info_ptr)
switch (form)
{
case DW_FORM_addr:
- /* FIXME: DWARF3 draft sais DW_FORM_ref_addr is offset_size. */
+ /* FIXME: DWARF3 draft says DW_FORM_ref_addr is offset_size. */
case DW_FORM_ref_addr:
- DW_ADDR (attr) = read_address (unit, info_ptr);
+ attr->u.val = read_address (unit, info_ptr);
info_ptr += unit->addr_size;
break;
case DW_FORM_block2:
amt = sizeof (struct dwarf_block);
- blk = (struct dwarf_block *) bfd_alloc (abfd, amt);
+ blk = bfd_alloc (abfd, amt);
blk->size = read_2_bytes (abfd, info_ptr);
info_ptr += 2;
blk->data = read_n_bytes (abfd, info_ptr, blk->size);
info_ptr += blk->size;
- DW_BLOCK (attr) = blk;
+ attr->u.blk = blk;
break;
case DW_FORM_block4:
amt = sizeof (struct dwarf_block);
- blk = (struct dwarf_block *) bfd_alloc (abfd, amt);
+ blk = bfd_alloc (abfd, amt);
blk->size = read_4_bytes (abfd, info_ptr);
info_ptr += 4;
blk->data = read_n_bytes (abfd, info_ptr, blk->size);
info_ptr += blk->size;
- DW_BLOCK (attr) = blk;
+ attr->u.blk = blk;
break;
case DW_FORM_data2:
- DW_UNSND (attr) = read_2_bytes (abfd, info_ptr);
+ attr->u.val = read_2_bytes (abfd, info_ptr);
info_ptr += 2;
break;
case DW_FORM_data4:
- DW_UNSND (attr) = read_4_bytes (abfd, info_ptr);
+ attr->u.val = read_4_bytes (abfd, info_ptr);
info_ptr += 4;
break;
case DW_FORM_data8:
- DW_UNSND (attr) = read_8_bytes (abfd, info_ptr);
+ attr->u.val = read_8_bytes (abfd, info_ptr);
info_ptr += 8;
break;
case DW_FORM_string:
- DW_STRING (attr) = read_string (abfd, info_ptr, &bytes_read);
+ attr->u.str = read_string (abfd, info_ptr, &bytes_read);
info_ptr += bytes_read;
break;
case DW_FORM_strp:
- DW_STRING (attr) = read_indirect_string (unit, info_ptr, &bytes_read);
+ attr->u.str = read_indirect_string (unit, info_ptr, &bytes_read);
info_ptr += bytes_read;
break;
case DW_FORM_block:
amt = sizeof (struct dwarf_block);
- blk = (struct dwarf_block *) bfd_alloc (abfd, amt);
+ blk = bfd_alloc (abfd, amt);
blk->size = read_unsigned_leb128 (abfd, info_ptr, &bytes_read);
info_ptr += bytes_read;
blk->data = read_n_bytes (abfd, info_ptr, blk->size);
info_ptr += blk->size;
- DW_BLOCK (attr) = blk;
+ attr->u.blk = blk;
break;
case DW_FORM_block1:
amt = sizeof (struct dwarf_block);
- blk = (struct dwarf_block *) bfd_alloc (abfd, amt);
+ blk = bfd_alloc (abfd, amt);
blk->size = read_1_byte (abfd, info_ptr);
info_ptr += 1;
blk->data = read_n_bytes (abfd, info_ptr, blk->size);
info_ptr += blk->size;
- DW_BLOCK (attr) = blk;
+ attr->u.blk = blk;
break;
case DW_FORM_data1:
- DW_UNSND (attr) = read_1_byte (abfd, info_ptr);
+ attr->u.val = read_1_byte (abfd, info_ptr);
info_ptr += 1;
break;
case DW_FORM_flag:
- DW_UNSND (attr) = read_1_byte (abfd, info_ptr);
+ attr->u.val = read_1_byte (abfd, info_ptr);
info_ptr += 1;
break;
case DW_FORM_sdata:
- DW_SND (attr) = read_signed_leb128 (abfd, info_ptr, &bytes_read);
+ attr->u.sval = read_signed_leb128 (abfd, info_ptr, &bytes_read);
info_ptr += bytes_read;
break;
case DW_FORM_udata:
- DW_UNSND (attr) = read_unsigned_leb128 (abfd, info_ptr, &bytes_read);
+ attr->u.val = read_unsigned_leb128 (abfd, info_ptr, &bytes_read);
info_ptr += bytes_read;
break;
case DW_FORM_ref1:
- DW_UNSND (attr) = read_1_byte (abfd, info_ptr);
+ attr->u.val = read_1_byte (abfd, info_ptr);
info_ptr += 1;
break;
case DW_FORM_ref2:
- DW_UNSND (attr) = read_2_bytes (abfd, info_ptr);
+ attr->u.val = read_2_bytes (abfd, info_ptr);
info_ptr += 2;
break;
case DW_FORM_ref4:
- DW_UNSND (attr) = read_4_bytes (abfd, info_ptr);
+ attr->u.val = read_4_bytes (abfd, info_ptr);
info_ptr += 4;
break;
case DW_FORM_ref8:
- DW_UNSND (attr) = read_8_bytes (abfd, info_ptr);
+ attr->u.val = read_8_bytes (abfd, info_ptr);
info_ptr += 8;
break;
case DW_FORM_ref_udata:
- DW_UNSND (attr) = read_unsigned_leb128 (abfd, info_ptr, &bytes_read);
+ attr->u.val = read_unsigned_leb128 (abfd, info_ptr, &bytes_read);
info_ptr += bytes_read;
break;
case DW_FORM_indirect:
@@ -767,11 +661,10 @@ read_attribute_value (attr, form, unit, info_ptr)
/* Read an attribute described by an abbreviated attribute. */
static char *
-read_attribute (attr, abbrev, unit, info_ptr)
- struct attribute *attr;
- struct attr_abbrev *abbrev;
- struct comp_unit *unit;
- char *info_ptr;
+read_attribute (struct attribute *attr,
+ struct attr_abbrev *abbrev,
+ struct comp_unit *unit,
+ char *info_ptr)
{
attr->name = abbrev->name;
info_ptr = read_attribute_value (attr, abbrev->form, unit, info_ptr);
@@ -821,22 +714,21 @@ struct funcinfo
bfd_vma high;
};
-/* add_line_info: adds a new entry to the line_info list in the
- line_info_table, ensuring that the list is sorted. Note that the
- line_info list is sorted from highest to lowest VMA (with possible
- duplicates); that is, line_info->prev_line always accesses an equal
- or smaller VMA. */
+/* Adds a new entry to the line_info list in the line_info_table, ensuring
+ that the list is sorted. Note that the line_info list is sorted from
+ highest to lowest VMA (with possible duplicates); that is,
+ line_info->prev_line always accesses an equal or smaller VMA. */
+
static void
-add_line_info (table, address, filename, line, column, end_sequence)
- struct line_info_table* table;
- bfd_vma address;
- char* filename;
- unsigned int line;
- unsigned int column;
- int end_sequence;
+add_line_info (struct line_info_table *table,
+ bfd_vma address,
+ char *filename,
+ unsigned int line,
+ unsigned int column,
+ int end_sequence)
{
bfd_size_type amt = sizeof (struct line_info);
- struct line_info* info = (struct line_info*) bfd_alloc (table->abfd, amt);
+ struct line_info* info = bfd_alloc (table->abfd, amt);
/* Find the correct location for 'info'. Normally we will receive
new line_info data 1) in order and 2) with increasing VMAs.
@@ -905,16 +797,26 @@ add_line_info (table, address, filename, line, column, end_sequence)
/* Set member data of 'info'. */
info->address = address;
- info->filename = filename;
info->line = line;
info->column = column;
info->end_sequence = end_sequence;
+
+ if (filename && filename[0])
+ {
+ info->filename = bfd_alloc (table->abfd, strlen (filename) + 1);
+ if (info->filename)
+ strcpy (info->filename, filename);
+ }
+ else
+ info->filename = NULL;
}
+/* Extract a fully qualified filename from a line info table.
+ The returned string has been malloc'ed and it is the caller's
+ responsibility to free it. */
+
static char *
-concat_filename (table, file)
- struct line_info_table* table;
- unsigned int file;
+concat_filename (struct line_info_table *table, unsigned int file)
{
char* filename;
@@ -922,32 +824,36 @@ concat_filename (table, file)
{
(*_bfd_error_handler)
(_("Dwarf Error: mangled line number section (bad file number)."));
- return "<unknown>";
+ return strdup ("<unknown>");
}
filename = table->files[file - 1].name;
- if (IS_ABSOLUTE_PATH(filename))
- return filename;
- else
+
+ if (! IS_ABSOLUTE_PATH (filename))
{
char* dirname = (table->files[file - 1].dir
? table->dirs[table->files[file - 1].dir - 1]
: table->comp_dir);
- /* Not all tools set DW_AT_comp_dir, so dirname may be unknown. The
- best we can do is return the filename part. */
- if (dirname == NULL)
- return filename;
- else
- return (char*) concat (dirname, "/", filename, NULL);
+ /* Not all tools set DW_AT_comp_dir, so dirname may be unknown.
+ The best we can do is return the filename part. */
+ if (dirname != NULL)
+ {
+ unsigned int len = strlen (dirname) + strlen (filename) + 2;
+ char * name;
+
+ name = bfd_malloc (len);
+ if (name)
+ sprintf (name, "%s/%s", dirname, filename);
+ return name;
+ }
}
+
+ return strdup (filename);
}
static void
-arange_add (unit, low_pc, high_pc)
- struct comp_unit *unit;
- bfd_vma low_pc;
- bfd_vma high_pc;
+arange_add (struct comp_unit *unit, bfd_vma low_pc, bfd_vma high_pc)
{
struct arange *arange;
@@ -980,8 +886,7 @@ arange_add (unit, low_pc, high_pc)
}
/* Need to allocate a new arange and insert it into the arange list. */
- arange = (struct arange *)
- bfd_zalloc (unit->abfd, (bfd_size_type) sizeof (*arange));
+ arange = bfd_zalloc (unit->abfd, sizeof (*arange));
arange->low = low_pc;
arange->high = high_pc;
@@ -992,9 +897,7 @@ arange_add (unit, low_pc, high_pc)
/* Decode the line number information for UNIT. */
static struct line_info_table*
-decode_line_info (unit, stash)
- struct comp_unit *unit;
- struct dwarf2_debug *stash;
+decode_line_info (struct comp_unit *unit, struct dwarf2_debug *stash)
{
bfd *abfd = unit->abfd;
struct line_info_table* table;
@@ -1019,21 +922,15 @@ decode_line_info (unit, stash)
}
stash->dwarf_line_size = msec->_raw_size;
- stash->dwarf_line_buffer = (char *) bfd_alloc (abfd, msec->_raw_size);
+ stash->dwarf_line_buffer
+ = bfd_simple_get_relocated_section_contents (abfd, msec, NULL,
+ stash->syms);
if (! stash->dwarf_line_buffer)
return 0;
-
- if (! bfd_get_section_contents (abfd, msec, stash->dwarf_line_buffer,
- (bfd_vma) 0, msec->_raw_size))
- return 0;
-
- /* FIXME: We ought to apply the relocs against this section before
- we process it... */
}
- /* Since we are using un-relocated data, it is possible to get a bad value
- for the line_offset. Validate it here so that we won't get a segfault
- below. */
+ /* It is possible to get a bad value for the line_offset. Validate
+ it here so that we won't get a segfault below. */
if (unit->line_offset >= stash->dwarf_line_size)
{
(*_bfd_error_handler) (_("Dwarf Error: Line offset (%lu) greater than or equal to .debug_line size (%lu)."),
@@ -1043,7 +940,7 @@ decode_line_info (unit, stash)
}
amt = sizeof (struct line_info_table);
- table = (struct line_info_table*) bfd_alloc (abfd, amt);
+ table = bfd_alloc (abfd, amt);
table->abfd = abfd;
table->comp_dir = unit->comp_dir;
@@ -1095,7 +992,7 @@ decode_line_info (unit, stash)
lh.opcode_base = read_1_byte (abfd, line_ptr);
line_ptr += 1;
amt = lh.opcode_base * sizeof (unsigned char);
- lh.standard_opcode_lengths = (unsigned char *) bfd_alloc (abfd, amt);
+ lh.standard_opcode_lengths = bfd_alloc (abfd, amt);
lh.standard_opcode_lengths[0] = 1;
@@ -1114,7 +1011,7 @@ decode_line_info (unit, stash)
{
amt = table->num_dirs + DIR_ALLOC_CHUNK;
amt *= sizeof (char *);
- table->dirs = (char **) bfd_realloc (table->dirs, amt);
+ table->dirs = bfd_realloc (table->dirs, amt);
if (! table->dirs)
return 0;
}
@@ -1133,7 +1030,7 @@ decode_line_info (unit, stash)
{
amt = table->num_files + FILE_ALLOC_CHUNK;
amt *= sizeof (struct fileinfo);
- table->files = (struct fileinfo *) bfd_realloc (table->files, amt);
+ table->files = bfd_realloc (table->files, amt);
if (! table->files)
return 0;
}
@@ -1158,7 +1055,7 @@ decode_line_info (unit, stash)
{
/* State machine registers. */
bfd_vma address = 0;
- char * filename = concat_filename (table, 1);
+ char * filename = table->num_files ? concat_filename (table, 1) : NULL;
unsigned int line = 1;
unsigned int column = 0;
int is_stmt = lh.default_is_stmt;
@@ -1224,8 +1121,7 @@ decode_line_info (unit, stash)
{
amt = table->num_files + FILE_ALLOC_CHUNK;
amt *= sizeof (struct fileinfo);
- table->files =
- (struct fileinfo *) bfd_realloc (table->files, amt);
+ table->files = bfd_realloc (table->files, amt);
if (! table->files)
return 0;
}
@@ -1272,6 +1168,8 @@ decode_line_info (unit, stash)
based, the references are 1 based. */
file = read_unsigned_leb128 (abfd, line_ptr, &bytes_read);
line_ptr += bytes_read;
+ if (filename)
+ free (filename);
filename = concat_filename (table, file);
break;
}
@@ -1296,6 +1194,7 @@ decode_line_info (unit, stash)
default:
{
int i;
+
/* Unknown standard opcode, ignore it. */
for (i = 0; i < lh.standard_opcode_lengths[op_code]; i++)
{
@@ -1305,23 +1204,24 @@ decode_line_info (unit, stash)
}
}
}
+
+ if (filename)
+ free (filename);
}
return table;
}
-/* If ADDR is within TABLE set the output parameters and return true,
- otherwise return false. The output parameters, FILENAME_PTR and
+/* If ADDR is within TABLE set the output parameters and return TRUE,
+ otherwise return FALSE. The output parameters, FILENAME_PTR and
LINENUMBER_PTR, are pointers to the objects to be filled in. */
-static boolean
-lookup_address_in_line_info_table (table, addr, function, filename_ptr,
- linenumber_ptr)
- struct line_info_table* table;
- bfd_vma addr;
- struct funcinfo *function;
- const char **filename_ptr;
- unsigned int *linenumber_ptr;
+static bfd_boolean
+lookup_address_in_line_info_table (struct line_info_table *table,
+ bfd_vma addr,
+ struct funcinfo *function,
+ const char **filename_ptr,
+ unsigned int *linenumber_ptr)
{
/* Note: table->last_line should be a descendingly sorted list. */
struct line_info* next_line = table->last_line;
@@ -1329,7 +1229,7 @@ lookup_address_in_line_info_table (table, addr, function, filename_ptr,
*filename_ptr = NULL;
if (!next_line)
- return false;
+ return FALSE;
each_line = next_line->prev_line;
@@ -1343,10 +1243,10 @@ lookup_address_in_line_info_table (table, addr, function, filename_ptr,
/* If we have an address match, save this info. This allows us
to return as good as results as possible for strange debugging
info. */
- boolean addr_match = false;
+ bfd_boolean addr_match = FALSE;
if (each_line->address <= addr && addr <= next_line->address)
{
- addr_match = true;
+ addr_match = TRUE;
/* If this line appears to span functions, and addr is in the
later function, return the first line of that function instead
@@ -1367,7 +1267,7 @@ lookup_address_in_line_info_table (table, addr, function, filename_ptr,
}
if (addr_match && !each_line->end_sequence)
- return true; /* we have definitely found what we want */
+ return TRUE; /* we have definitely found what we want */
next_line = each_line;
each_line = each_line->prev_line;
@@ -1383,23 +1283,21 @@ lookup_address_in_line_info_table (table, addr, function, filename_ptr,
{
*filename_ptr = next_line->filename;
*linenumber_ptr = next_line->line;
- return true;
+ return TRUE;
}
- return false;
+ return FALSE;
}
/* Function table functions. */
-/* If ADDR is within TABLE, set FUNCTIONNAME_PTR, and return true. */
+/* If ADDR is within TABLE, set FUNCTIONNAME_PTR, and return TRUE. */
-static boolean
-lookup_address_in_function_table (table, addr, function_ptr,
- functionname_ptr)
- struct funcinfo* table;
- bfd_vma addr;
- struct funcinfo** function_ptr;
- const char **functionname_ptr;
+static bfd_boolean
+lookup_address_in_function_table (struct funcinfo *table,
+ bfd_vma addr,
+ struct funcinfo **function_ptr,
+ const char **functionname_ptr)
{
struct funcinfo* each_func;
@@ -1411,11 +1309,11 @@ lookup_address_in_function_table (table, addr, function_ptr,
{
*functionname_ptr = each_func->name;
*function_ptr = each_func;
- return true;
+ return TRUE;
}
}
- return false;
+ return FALSE;
}
/* DWARF2 Compilation unit functions. */
@@ -1423,9 +1321,8 @@ lookup_address_in_function_table (table, addr, function_ptr,
/* Scan over each die in a comp. unit looking for functions to add
to the function table. */
-static boolean
-scan_unit_for_functions (unit)
- struct comp_unit *unit;
+static bfd_boolean
+scan_unit_for_functions (struct comp_unit *unit)
{
bfd *abfd = unit->abfd;
char *info_ptr = unit->first_child_die_ptr;
@@ -1454,13 +1351,13 @@ scan_unit_for_functions (unit)
(*_bfd_error_handler) (_("Dwarf Error: Could not find abbrev number %u."),
abbrev_number);
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
if (abbrev->tag == DW_TAG_subprogram)
{
bfd_size_type amt = sizeof (struct funcinfo);
- func = (struct funcinfo *) bfd_zalloc (abfd, amt);
+ func = bfd_zalloc (abfd, amt);
func->prev_func = unit->function_table;
unit->function_table = func;
}
@@ -1477,23 +1374,23 @@ scan_unit_for_functions (unit)
{
case DW_AT_name:
- name = DW_STRING (&attr);
+ name = attr.u.str;
/* Prefer DW_AT_MIPS_linkage_name over DW_AT_name. */
if (func->name == NULL)
- func->name = DW_STRING (&attr);
+ func->name = attr.u.str;
break;
case DW_AT_MIPS_linkage_name:
- func->name = DW_STRING (&attr);
+ func->name = attr.u.str;
break;
case DW_AT_low_pc:
- func->low = DW_ADDR (&attr);
+ func->low = attr.u.val;
break;
case DW_AT_high_pc:
- func->high = DW_ADDR (&attr);
+ func->high = attr.u.val;
break;
default:
@@ -1505,7 +1402,7 @@ scan_unit_for_functions (unit)
switch (attr.name)
{
case DW_AT_name:
- name = DW_STRING (&attr);
+ name = attr.u.str;
break;
default:
@@ -1518,66 +1415,12 @@ scan_unit_for_functions (unit)
nesting_level++;
}
- return true;
-}
-
-/* Look for a RELA relocation to be applied on OFFSET of section SEC,
- and return the addend if such a relocation is found. Since this is
- only used to find relocations referring to the .debug_abbrev
- section, we make sure the relocation refers to this section, but
- this is not strictly necessary, and it can probably be safely
- removed if needed. However, it is important to note that this
- function only returns the addend, it doesn't serve the purpose of
- applying a generic relocation.
-
- If no suitable relocation is found, or if it is not a real RELA
- relocation, this function returns 0. */
-
-static bfd_vma
-find_rela_addend (abfd, sec, offset, syms)
- bfd* abfd;
- asection* sec;
- bfd_size_type offset;
- asymbol** syms;
-{
- long reloc_size = bfd_get_reloc_upper_bound (abfd, sec);
- arelent **relocs = NULL;
- long reloc_count, relc;
-
- if (reloc_size <= 0)
- return 0;
-
- relocs = (arelent **) bfd_malloc ((bfd_size_type) reloc_size);
- if (relocs == NULL)
- return 0;
-
- reloc_count = bfd_canonicalize_reloc (abfd, sec, relocs, syms);
-
- if (reloc_count <= 0)
- {
- free (relocs);
- return 0;
- }
-
- for (relc = 0; relc < reloc_count; relc++)
- if (relocs[relc]->address == offset
- && (*relocs[relc]->sym_ptr_ptr)->flags & BSF_SECTION_SYM
- && strcmp ((*relocs[relc]->sym_ptr_ptr)->name,
- ".debug_abbrev") == 0)
- {
- bfd_vma addend = (relocs[relc]->howto->partial_inplace
- ? 0 : relocs[relc]->addend);
- free (relocs);
- return addend;
- }
-
- free (relocs);
- return 0;
+ return TRUE;
}
/* Parse a DWARF2 compilation unit starting at INFO_PTR. This
includes the compilation unit header that proceeds the DIE's, but
- does not include the length field that preceeds each compilation
+ does not include the length field that precedes each compilation
unit header. END_PTR points one past the end of this comp unit.
OFFSET_SIZE is the size of DWARF2 offsets (either 4 or 8 bytes).
@@ -1585,15 +1428,14 @@ find_rela_addend (abfd, sec, offset, syms)
to get to the line number information for the compilation unit. */
static struct comp_unit *
-parse_comp_unit (abfd, stash, unit_length, offset_size)
- bfd* abfd;
- struct dwarf2_debug *stash;
- bfd_vma unit_length;
- unsigned int offset_size;
+parse_comp_unit (bfd *abfd,
+ struct dwarf2_debug *stash,
+ bfd_vma unit_length,
+ unsigned int offset_size)
{
struct comp_unit* unit;
unsigned int version;
- bfd_vma abbrev_offset = 0;
+ bfd_uint64_t abbrev_offset = 0;
unsigned int addr_size;
struct abbrev_info** abbrevs;
unsigned int abbrev_number, bytes_read, i;
@@ -1602,7 +1444,6 @@ parse_comp_unit (abfd, stash, unit_length, offset_size)
char *info_ptr = stash->info_ptr;
char *end_ptr = info_ptr + unit_length;
bfd_size_type amt;
- bfd_size_type off;
version = read_2_bytes (abfd, info_ptr);
info_ptr += 2;
@@ -1611,12 +1452,6 @@ parse_comp_unit (abfd, stash, unit_length, offset_size)
abbrev_offset = read_4_bytes (abfd, info_ptr);
else
abbrev_offset = read_8_bytes (abfd, info_ptr);
- /* The abbrev offset is generally a relocation pointing to
- .debug_abbrev+offset. On RELA targets, we have to find the
- relocation and extract the addend to obtain the actual
- abbrev_offset, so do it here. */
- off = info_ptr - stash->sec_info_ptr;
- abbrev_offset += find_rela_addend (abfd, stash->sec, off, stash->syms);
info_ptr += offset_size;
addr_size = read_1_byte (abfd, info_ptr);
info_ptr += 1;
@@ -1669,7 +1504,7 @@ parse_comp_unit (abfd, stash, unit_length, offset_size)
}
amt = sizeof (struct comp_unit);
- unit = (struct comp_unit*) bfd_zalloc (abfd, amt);
+ unit = bfd_zalloc (abfd, amt);
unit->abfd = abfd;
unit->addr_size = addr_size;
unit->offset_size = offset_size;
@@ -1687,29 +1522,29 @@ parse_comp_unit (abfd, stash, unit_length, offset_size)
{
case DW_AT_stmt_list:
unit->stmtlist = 1;
- unit->line_offset = DW_UNSND (&attr);
+ unit->line_offset = attr.u.val;
break;
case DW_AT_name:
- unit->name = DW_STRING (&attr);
+ unit->name = attr.u.str;
break;
case DW_AT_low_pc:
- unit->arange.low = DW_ADDR (&attr);
+ unit->arange.low = attr.u.val;
break;
case DW_AT_high_pc:
- unit->arange.high = DW_ADDR (&attr);
+ unit->arange.high = attr.u.val;
break;
case DW_AT_comp_dir:
{
- char* comp_dir = DW_STRING (&attr);
+ char* comp_dir = attr.u.str;
if (comp_dir)
{
/* Irix 6.2 native cc prepends <machine>.: to the compilation
directory, get rid of it. */
- char *cp = (char*) strchr (comp_dir, ':');
+ char *cp = strchr (comp_dir, ':');
if (cp && cp != comp_dir && cp[-1] == '.' && cp[1] == '/')
comp_dir = cp + 1;
@@ -1727,28 +1562,26 @@ parse_comp_unit (abfd, stash, unit_length, offset_size)
return unit;
}
-/* Return true if UNIT contains the address given by ADDR. */
+/* Return TRUE if UNIT contains the address given by ADDR. */
-static boolean
-comp_unit_contains_address (unit, addr)
- struct comp_unit* unit;
- bfd_vma addr;
+static bfd_boolean
+comp_unit_contains_address (struct comp_unit *unit, bfd_vma addr)
{
struct arange *arange;
if (unit->error)
- return false;
+ return FALSE;
arange = &unit->arange;
do
{
if (addr >= arange->low && addr < arange->high)
- return true;
+ return TRUE;
arange = arange->next;
}
while (arange);
- return false;
+ return FALSE;
}
/* If UNIT contains ADDR, set the output parameters to the values for
@@ -1756,32 +1589,30 @@ comp_unit_contains_address (unit, addr)
FUNCTIONNAME_PTR, and LINENUMBER_PTR, are pointers to the objects
to be filled in.
- Return true of UNIT contains ADDR, and no errors were encountered;
- false otherwise. */
-
-static boolean
-comp_unit_find_nearest_line (unit, addr, filename_ptr, functionname_ptr,
- linenumber_ptr, stash)
- struct comp_unit* unit;
- bfd_vma addr;
- const char **filename_ptr;
- const char **functionname_ptr;
- unsigned int *linenumber_ptr;
- struct dwarf2_debug *stash;
+ Return TRUE if UNIT contains ADDR, and no errors were encountered;
+ FALSE otherwise. */
+
+static bfd_boolean
+comp_unit_find_nearest_line (struct comp_unit *unit,
+ bfd_vma addr,
+ const char **filename_ptr,
+ const char **functionname_ptr,
+ unsigned int *linenumber_ptr,
+ struct dwarf2_debug *stash)
{
- boolean line_p;
- boolean func_p;
+ bfd_boolean line_p;
+ bfd_boolean func_p;
struct funcinfo *function;
if (unit->error)
- return false;
+ return FALSE;
if (! unit->line_table)
{
if (! unit->stmtlist)
{
unit->error = 1;
- return false;
+ return FALSE;
}
unit->line_table = decode_line_info (unit, stash);
@@ -1789,14 +1620,14 @@ comp_unit_find_nearest_line (unit, addr, filename_ptr, functionname_ptr,
if (! unit->line_table)
{
unit->error = 1;
- return false;
+ return FALSE;
}
if (unit->first_child_die_ptr < unit->end_ptr
&& ! scan_unit_for_functions (unit))
{
unit->error = 1;
- return false;
+ return FALSE;
}
}
@@ -1806,7 +1637,7 @@ comp_unit_find_nearest_line (unit, addr, filename_ptr, functionname_ptr,
line_p = lookup_address_in_line_info_table (unit->line_table, addr,
function, filename_ptr,
linenumber_ptr);
- return (boolean) (line_p || func_p);
+ return line_p || func_p;
}
/* Locate a section in a BFD containing debugging info. The search starts
@@ -1822,9 +1653,7 @@ comp_unit_find_nearest_line (unit, addr, filename_ptr, functionname_ptr,
#define GNU_LINKONCE_INFO ".gnu.linkonce.wi."
static asection *
-find_debug_info (abfd, after_sec)
- bfd * abfd;
- asection * after_sec;
+find_debug_info (bfd *abfd, asection *after_sec)
{
asection * msec;
@@ -1847,25 +1676,22 @@ find_debug_info (abfd, after_sec)
return NULL;
}
-/* The DWARF2 version of find_nearest line. Return true if the line
+/* The DWARF2 version of find_nearest line. Return TRUE if the line
is found without error. ADDR_SIZE is the number of bytes in the
initial .debug_info length field and in the abbreviation offset.
You may use zero to indicate that the default value should be
used. */
-boolean
-_bfd_dwarf2_find_nearest_line (abfd, section, symbols, offset,
- filename_ptr, functionname_ptr,
- linenumber_ptr, addr_size, pinfo)
- bfd *abfd;
- asection *section;
- asymbol **symbols;
- bfd_vma offset;
- const char **filename_ptr;
- const char **functionname_ptr;
- unsigned int *linenumber_ptr;
- unsigned int addr_size;
- PTR *pinfo;
+bfd_boolean
+_bfd_dwarf2_find_nearest_line (bfd *abfd,
+ asection *section,
+ asymbol **symbols,
+ bfd_vma offset,
+ const char **filename_ptr,
+ const char **functionname_ptr,
+ unsigned int *linenumber_ptr,
+ unsigned int addr_size,
+ void **pinfo)
{
/* Read each compilation unit from the section .debug_info, and check
to see if it contains the address we are searching for. If yes,
@@ -1875,7 +1701,7 @@ _bfd_dwarf2_find_nearest_line (abfd, section, symbols, offset,
We keep a list of all the previously read compilation units, and
a pointer to the next un-read compilation unit. Check the
previously read units before reading more. */
- struct dwarf2_debug *stash = (struct dwarf2_debug *) *pinfo;
+ struct dwarf2_debug *stash = *pinfo;
/* What address are we looking for? */
bfd_vma addr = offset + section->vma;
@@ -1899,18 +1725,18 @@ _bfd_dwarf2_find_nearest_line (abfd, section, symbols, offset,
asection *msec;
bfd_size_type amt = sizeof (struct dwarf2_debug);
- stash = (struct dwarf2_debug*) bfd_zalloc (abfd, amt);
+ stash = bfd_zalloc (abfd, amt);
if (! stash)
- return false;
+ return FALSE;
- *pinfo = (PTR) stash;
+ *pinfo = stash;
msec = find_debug_info (abfd, NULL);
if (! msec)
/* No dwarf2 info. Note that at this point the stash
has been allocated, but contains zeros, this lets
future calls to this function fail quicker. */
- return false;
+ return FALSE;
/* There can be more than one DWARF2 info section in a BFD these days.
Read them all in and produce one large stash. We do this in two
@@ -1920,9 +1746,9 @@ _bfd_dwarf2_find_nearest_line (abfd, section, symbols, offset,
for (total_size = 0; msec; msec = find_debug_info (abfd, msec))
total_size += msec->_raw_size;
- stash->info_ptr = (char *) bfd_alloc (abfd, total_size);
+ stash->info_ptr = bfd_alloc (abfd, total_size);
if (stash->info_ptr == NULL)
- return false;
+ return FALSE;
stash->info_ptr_end = stash->info_ptr;
@@ -1939,8 +1765,8 @@ _bfd_dwarf2_find_nearest_line (abfd, section, symbols, offset,
start = stash->info_ptr_end - stash->info_ptr;
- if (! bfd_get_section_contents (abfd, msec, stash->info_ptr + start,
- (bfd_vma) 0, size))
+ if ((bfd_simple_get_relocated_section_contents
+ (abfd, msec, stash->info_ptr + start, symbols)) == NULL)
continue;
stash->info_ptr_end = stash->info_ptr + start + size;
@@ -1953,25 +1779,10 @@ _bfd_dwarf2_find_nearest_line (abfd, section, symbols, offset,
stash->syms = symbols;
}
- /* FIXME: There is a problem with the contents of the
- .debug_info section. The 'low' and 'high' addresses of the
- comp_units are computed by relocs against symbols in the
- .text segment. We need these addresses in order to determine
- the nearest line number, and so we have to resolve the
- relocs. There is a similar problem when the .debug_line
- section is processed as well (e.g., there may be relocs
- against the operand of the DW_LNE_set_address operator).
-
- Unfortunately getting hold of the reloc information is hard...
-
- For now, this means that disassembling object files (as
- opposed to fully executables) does not always work as well as
- we would like. */
-
/* A null info_ptr indicates that there is no dwarf2 info
(or that an error occured while setting up the stash). */
if (! stash->info_ptr)
- return false;
+ return FALSE;
/* Check the previously read comp. units first. */
for (each = stash->all_comp_units; each; each = each->next_unit)
@@ -1984,29 +1795,37 @@ _bfd_dwarf2_find_nearest_line (abfd, section, symbols, offset,
while (stash->info_ptr < stash->info_ptr_end)
{
bfd_vma length;
- boolean found;
+ bfd_boolean found;
unsigned int offset_size = addr_size;
- if (addr_size == 4)
+ length = read_4_bytes (abfd, stash->info_ptr);
+ /* A 0xffffff length is the DWARF3 way of indicating we use
+ 64-bit offsets, instead of 32-bit offsets. */
+ if (length == 0xffffffff)
{
- length = read_4_bytes (abfd, stash->info_ptr);
- if (length == 0xffffffff)
- {
- offset_size = 8;
- length = read_8_bytes (abfd, stash->info_ptr + 4);
- stash->info_ptr += 8;
- }
- else if (length == 0)
- {
- /* Handle (non-standard) 64-bit DWARF2 formats. */
- offset_size = 8;
- length = read_4_bytes (abfd, stash->info_ptr + 4);
- stash->info_ptr += 4;
- }
+ offset_size = 8;
+ length = read_8_bytes (abfd, stash->info_ptr + 4);
+ stash->info_ptr += 12;
+ }
+ /* A zero length is the IRIX way of indicating 64-bit offsets,
+ mostly because the 64-bit length will generally fit in 32
+ bits, and the endianness helps. */
+ else if (length == 0)
+ {
+ offset_size = 8;
+ length = read_4_bytes (abfd, stash->info_ptr + 4);
+ stash->info_ptr += 8;
+ }
+ /* In the absence of the hints above, we assume addr_size-sized
+ offsets, for backward-compatibility with pre-DWARF3 64-bit
+ platforms. */
+ else if (addr_size == 8)
+ {
+ length = read_8_bytes (abfd, stash->info_ptr);
+ stash->info_ptr += 8;
}
else
- length = read_8_bytes (abfd, stash->info_ptr);
- stash->info_ptr += addr_size;
+ stash->info_ptr += 4;
if (length > 0)
{
@@ -2034,10 +1853,10 @@ _bfd_dwarf2_find_nearest_line (abfd, section, symbols, offset,
{
if (comp_unit_contains_address (each, addr))
return comp_unit_find_nearest_line (each, addr,
- filename_ptr,
- functionname_ptr,
- linenumber_ptr,
- stash);
+ filename_ptr,
+ functionname_ptr,
+ linenumber_ptr,
+ stash);
}
else
{
@@ -2047,11 +1866,11 @@ _bfd_dwarf2_find_nearest_line (abfd, section, symbols, offset,
linenumber_ptr,
stash);
if (found)
- return true;
+ return TRUE;
}
}
}
}
- return false;
+ return FALSE;
}
diff --git a/contrib/binutils/bfd/ecoff.c b/contrib/binutils/bfd/ecoff.c
index ed10850..cfc5ae1 100644
--- a/contrib/binutils/bfd/ecoff.c
+++ b/contrib/binutils/bfd/ecoff.c
@@ -1,6 +1,6 @@
/* Generic ECOFF (Extended-COFF) routines.
- Copyright 1990, 1991, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
- Free Software Foundation, Inc.
+ Copyright 1990, 1991, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
+ 2002, 2003 Free Software Foundation, Inc.
Original version by Per Bothner.
Full support added by Ian Lance Taylor, ian@cygnus.com.
@@ -46,19 +46,32 @@
/* Prototypes for static functions. */
-static int ecoff_get_magic PARAMS ((bfd *));
-static long ecoff_sec_to_styp_flags PARAMS ((const char *, flagword));
-static boolean ecoff_slurp_symbolic_header PARAMS ((bfd *));
-static boolean ecoff_set_symbol_info PARAMS ((bfd *, SYMR *, asymbol *, int, int));
-static void ecoff_emit_aggregate PARAMS ((bfd *, FDR *, char *, RNDXR *, long, const char *));
-static char *ecoff_type_to_string PARAMS ((bfd *, FDR *, unsigned int));
-static boolean ecoff_slurp_reloc_table PARAMS ((bfd *, asection *, asymbol **));
-static int ecoff_sort_hdrs PARAMS ((const PTR, const PTR));
-static boolean ecoff_compute_section_file_positions PARAMS ((bfd *));
-static bfd_size_type ecoff_compute_reloc_file_positions PARAMS ((bfd *));
-static boolean ecoff_get_extr PARAMS ((asymbol *, EXTR *));
-static void ecoff_set_index PARAMS ((asymbol *, bfd_size_type));
-static unsigned int ecoff_armap_hash PARAMS ((const char *, unsigned int *, unsigned int, unsigned int));
+static int ecoff_get_magic
+ PARAMS ((bfd *));
+static long ecoff_sec_to_styp_flags
+ PARAMS ((const char *, flagword));
+static bfd_boolean ecoff_slurp_symbolic_header
+ PARAMS ((bfd *));
+static bfd_boolean ecoff_set_symbol_info
+ PARAMS ((bfd *, SYMR *, asymbol *, int, int));
+static void ecoff_emit_aggregate
+ PARAMS ((bfd *, FDR *, char *, RNDXR *, long, const char *));
+static char *ecoff_type_to_string
+ PARAMS ((bfd *, FDR *, unsigned int));
+static bfd_boolean ecoff_slurp_reloc_table
+ PARAMS ((bfd *, asection *, asymbol **));
+static int ecoff_sort_hdrs
+ PARAMS ((const PTR, const PTR));
+static bfd_boolean ecoff_compute_section_file_positions
+ PARAMS ((bfd *));
+static bfd_size_type ecoff_compute_reloc_file_positions
+ PARAMS ((bfd *));
+static bfd_boolean ecoff_get_extr
+ PARAMS ((asymbol *, EXTR *));
+static void ecoff_set_index
+ PARAMS ((asymbol *, bfd_size_type));
+static unsigned int ecoff_armap_hash
+ PARAMS ((const char *, unsigned int *, unsigned int, unsigned int));
/* This stuff is somewhat copied from coffcode.h. */
@@ -68,6 +81,12 @@ static asection bfd_debug_section =
"*DEBUG*", 0, 0, NULL, 0, 0, 0,
/* linker_mark, linker_has_input, gc_mark, segment_mark, */
0, 0, 0, 0,
+ /* sec_info_type, use_rela_p, has_tls_reloc, */
+ 0, 0, 0,
+ /* need_finalize_relax, has_gp_reloc, */
+ 0, 0,
+ /* flag13, flag14, flag15, flag16, flag20, flag24, */
+ 0, 0, 0, 0, 0, 0,
/* vma, lma, _cooked_size, _raw_size, */
0, 0, 0, 0,
/* output_offset, output_section, alignment_power, */
@@ -76,21 +95,21 @@ static asection bfd_debug_section =
NULL, NULL, 0, 0, 0,
/* line_filepos, userdata, contents, lineno, lineno_count, */
0, NULL, NULL, NULL, 0,
- /* entsize, comdat, moving_line_filepos, */
- 0, NULL, 0,
+ /* entsize, comdat, kept_section, moving_line_filepos, */
+ 0, NULL, NULL, 0,
/* target_index, used_by_bfd, constructor_chain, owner, */
0, NULL, NULL, NULL,
/* symbol, */
- (struct symbol_cache_entry *) NULL,
+ (struct bfd_symbol *) NULL,
/* symbol_ptr_ptr, */
- (struct symbol_cache_entry **) NULL,
+ (struct bfd_symbol **) NULL,
/* link_order_head, link_order_tail */
NULL, NULL
};
/* Create an ECOFF object. */
-boolean
+bfd_boolean
_bfd_ecoff_mkobject (abfd)
bfd *abfd;
{
@@ -98,9 +117,9 @@ _bfd_ecoff_mkobject (abfd)
abfd->tdata.ecoff_obj_data = (struct ecoff_tdata *) bfd_zalloc (abfd, amt);
if (abfd->tdata.ecoff_obj_data == NULL)
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
/* This is a hook called by coff_real_object_p to create any backend
@@ -151,7 +170,7 @@ _bfd_ecoff_mkobject_hook (abfd, filehdr, aouthdr)
/* Initialize a new section. */
-boolean
+bfd_boolean
_bfd_ecoff_new_section_hook (abfd, section)
bfd *abfd ATTRIBUTE_UNUSED;
asection *section;
@@ -182,7 +201,7 @@ _bfd_ecoff_new_section_hook (abfd, section)
uncertain about .init on some systems and I don't know how shared
libraries work. */
- return true;
+ return TRUE;
}
/* Determine the machine architecture and type. This is called from
@@ -190,7 +209,7 @@ _bfd_ecoff_new_section_hook (abfd, section)
below. This could be an ECOFF backend routine, with one version
for each target, but there aren't all that many ECOFF targets. */
-boolean
+bfd_boolean
_bfd_ecoff_set_arch_mach_hook (abfd, filehdr)
bfd *abfd;
PTR filehdr;
@@ -205,21 +224,21 @@ _bfd_ecoff_set_arch_mach_hook (abfd, filehdr)
case MIPS_MAGIC_LITTLE:
case MIPS_MAGIC_BIG:
arch = bfd_arch_mips;
- mach = 3000;
+ mach = bfd_mach_mips3000;
break;
case MIPS_MAGIC_LITTLE2:
case MIPS_MAGIC_BIG2:
/* MIPS ISA level 2: the r6000. */
arch = bfd_arch_mips;
- mach = 6000;
+ mach = bfd_mach_mips6000;
break;
case MIPS_MAGIC_LITTLE3:
case MIPS_MAGIC_BIG3:
/* MIPS ISA level 3: the r4000. */
arch = bfd_arch_mips;
- mach = 4000;
+ mach = bfd_mach_mips4000;
break;
case ALPHA_MAGIC:
@@ -252,17 +271,17 @@ ecoff_get_magic (abfd)
{
default:
case 0:
- case 3000:
+ case bfd_mach_mips3000:
big = MIPS_MAGIC_BIG;
little = MIPS_MAGIC_LITTLE;
break;
- case 6000:
+ case bfd_mach_mips6000:
big = MIPS_MAGIC_BIG2;
little = MIPS_MAGIC_LITTLE2;
break;
- case 4000:
+ case bfd_mach_mips4000:
big = MIPS_MAGIC_BIG3;
little = MIPS_MAGIC_LITTLE3;
break;
@@ -360,7 +379,7 @@ ecoff_sec_to_styp_flags (name, flags)
/* Get the BFD flags to use for a section. */
-boolean
+bfd_boolean
_bfd_ecoff_styp_to_sec_flags (abfd, hdr, name, section, flags_ptr)
bfd *abfd ATTRIBUTE_UNUSED;
PTR hdr;
@@ -425,12 +444,12 @@ _bfd_ecoff_styp_to_sec_flags (abfd, hdr, name, section, flags_ptr)
sec_flags |= SEC_ALLOC | SEC_LOAD;
* flags_ptr = sec_flags;
- return true;
+ return TRUE;
}
/* Read in the symbolic header for an ECOFF object file. */
-static boolean
+static bfd_boolean
ecoff_slurp_symbolic_header (abfd)
bfd *abfd;
{
@@ -442,13 +461,13 @@ ecoff_slurp_symbolic_header (abfd)
/* See if we've already read it in. */
if (ecoff_data (abfd)->debug_info.symbolic_header.magic ==
backend->debug_swap.sym_magic)
- return true;
+ return TRUE;
/* See whether there is a symbolic header. */
if (ecoff_data (abfd)->sym_filepos == 0)
{
bfd_get_symcount (abfd) = 0;
- return true;
+ return TRUE;
}
/* At this point bfd_get_symcount (abfd) holds the number of symbols
@@ -459,7 +478,7 @@ ecoff_slurp_symbolic_header (abfd)
if (bfd_get_symcount (abfd) != external_hdr_size)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
/* Read the symbolic information header. */
@@ -485,18 +504,18 @@ ecoff_slurp_symbolic_header (abfd)
if (raw != NULL)
free (raw);
- return true;
+ return TRUE;
error_return:
if (raw != NULL)
free (raw);
- return false;
+ return FALSE;
}
/* Read in and swap the important symbolic information for an ECOFF
object file. This is called by gdb via the read_debug_info entry
point in the backend structure. */
-boolean
+bfd_boolean
_bfd_ecoff_slurp_symbolic_info (abfd, ignore, debug)
bfd *abfd;
asection *ignore ATTRIBUTE_UNUSED;
@@ -521,15 +540,15 @@ _bfd_ecoff_slurp_symbolic_info (abfd, ignore, debug)
/* Check whether we've already gotten it, and whether there's any to
get. */
if (ecoff_data (abfd)->raw_syments != (PTR) NULL)
- return true;
+ return TRUE;
if (ecoff_data (abfd)->sym_filepos == 0)
{
bfd_get_symcount (abfd) = 0;
- return true;
+ return TRUE;
}
if (! ecoff_slurp_symbolic_header (abfd))
- return false;
+ return FALSE;
internal_symhdr = &debug->symbolic_header;
@@ -569,11 +588,11 @@ _bfd_ecoff_slurp_symbolic_info (abfd, ignore, debug)
if (raw_size == 0)
{
ecoff_data (abfd)->sym_filepos = 0;
- return true;
+ return TRUE;
}
raw = (PTR) bfd_alloc (abfd, raw_size);
if (raw == NULL)
- return false;
+ return FALSE;
pos = ecoff_data (abfd)->sym_filepos;
pos += backend->debug_swap.external_hdr_size;
@@ -581,7 +600,7 @@ _bfd_ecoff_slurp_symbolic_info (abfd, ignore, debug)
|| bfd_bread (raw, raw_size, abfd) != raw_size)
{
bfd_release (abfd, raw);
- return false;
+ return FALSE;
}
ecoff_data (abfd)->raw_syments = raw;
@@ -620,7 +639,7 @@ _bfd_ecoff_slurp_symbolic_info (abfd, ignore, debug)
amt *= sizeof (struct fdr);
debug->fdr = (struct fdr *) bfd_alloc (abfd, amt);
if (debug->fdr == NULL)
- return false;
+ return FALSE;
external_fdr_size = backend->debug_swap.external_fdr_size;
fdr_ptr = debug->fdr;
fraw_src = (char *) debug->external_fdr;
@@ -628,7 +647,7 @@ _bfd_ecoff_slurp_symbolic_info (abfd, ignore, debug)
for (; fraw_src < fraw_end; fraw_src += external_fdr_size, fdr_ptr++)
(*backend->debug_swap.swap_fdr_in) (abfd, (PTR) fraw_src, fdr_ptr);
- return true;
+ return TRUE;
}
/* ECOFF symbol table routines. The ECOFF symbol table is described
@@ -657,7 +676,7 @@ _bfd_ecoff_make_empty_symbol (abfd)
return (asymbol *) NULL;
new->symbol.section = (asection *) NULL;
new->fdr = (FDR *) NULL;
- new->local = false;
+ new->local = FALSE;
new->native = NULL;
new->symbol.the_bfd = abfd;
return &new->symbol;
@@ -665,7 +684,7 @@ _bfd_ecoff_make_empty_symbol (abfd)
/* Set the BFD flags and section for an ECOFF symbol. */
-static boolean
+static bfd_boolean
ecoff_set_symbol_info (abfd, ecoff_sym, asym, ext, weak)
bfd *abfd;
SYMR *ecoff_sym;
@@ -691,12 +710,12 @@ ecoff_set_symbol_info (abfd, ecoff_sym, asym, ext, weak)
if (ECOFF_IS_STAB (ecoff_sym))
{
asym->flags = BSF_DEBUGGING;
- return true;
+ return TRUE;
}
break;
default:
asym->flags = BSF_DEBUGGING;
- return true;
+ return TRUE;
}
if (weak)
@@ -877,7 +896,7 @@ ecoff_set_symbol_info (abfd, ecoff_sym, asym, ext, weak)
amt = strlen (name) + 1;
copy = (char *) bfd_alloc (abfd, amt);
if (!copy)
- return false;
+ return FALSE;
strcpy (copy, name);
section = bfd_make_section (abfd, copy);
}
@@ -886,7 +905,7 @@ ecoff_set_symbol_info (abfd, ecoff_sym, asym, ext, weak)
amt = sizeof (arelent_chain);
reloc_chain = (arelent_chain *) bfd_alloc (abfd, amt);
if (!reloc_chain)
- return false;
+ return FALSE;
reloc_chain->relent.sym_ptr_ptr =
bfd_get_section (asym)->symbol_ptr_ptr;
reloc_chain->relent.address = section->_raw_size;
@@ -919,12 +938,12 @@ ecoff_set_symbol_info (abfd, ecoff_sym, asym, ext, weak)
break;
}
}
- return true;
+ return TRUE;
}
/* Read an ECOFF symbol table. */
-boolean
+bfd_boolean
_bfd_ecoff_slurp_symbol_table (abfd)
bfd *abfd;
{
@@ -947,20 +966,20 @@ _bfd_ecoff_slurp_symbol_table (abfd)
/* If we've already read in the symbol table, do nothing. */
if (ecoff_data (abfd)->canonical_symbols != NULL)
- return true;
+ return TRUE;
/* Get the symbolic information. */
if (! _bfd_ecoff_slurp_symbolic_info (abfd, (asection *) NULL,
&ecoff_data (abfd)->debug_info))
- return false;
+ return FALSE;
if (bfd_get_symcount (abfd) == 0)
- return true;
+ return TRUE;
internal_size = bfd_get_symcount (abfd);
internal_size *= sizeof (ecoff_symbol_type);
internal = (ecoff_symbol_type *) bfd_alloc (abfd, internal_size);
if (internal == NULL)
- return false;
+ return FALSE;
internal_ptr = internal;
eraw_src = (char *) ecoff_data (abfd)->debug_info.external_ext;
@@ -977,14 +996,14 @@ _bfd_ecoff_slurp_symbol_table (abfd)
if (!ecoff_set_symbol_info (abfd, &internal_esym.asym,
&internal_ptr->symbol, 1,
internal_esym.weakext))
- return false;
+ return FALSE;
/* The alpha uses a negative ifd field for section symbols. */
if (internal_esym.ifd >= 0)
internal_ptr->fdr = (ecoff_data (abfd)->debug_info.fdr
+ internal_esym.ifd);
else
internal_ptr->fdr = NULL;
- internal_ptr->local = false;
+ internal_ptr->local = FALSE;
internal_ptr->native = (PTR) eraw_src;
}
@@ -1012,16 +1031,16 @@ _bfd_ecoff_slurp_symbol_table (abfd)
+ internal_sym.iss);
if (!ecoff_set_symbol_info (abfd, &internal_sym,
&internal_ptr->symbol, 0, 0))
- return false;
+ return FALSE;
internal_ptr->fdr = fdr_ptr;
- internal_ptr->local = true;
+ internal_ptr->local = TRUE;
internal_ptr->native = (PTR) lraw_src;
}
}
ecoff_data (abfd)->canonical_symbols = internal;
- return true;
+ return TRUE;
}
/* Return the amount of space needed for the canonical symbols. */
@@ -1043,7 +1062,7 @@ _bfd_ecoff_get_symtab_upper_bound (abfd)
/* Get the canonical symbols. */
long
-_bfd_ecoff_get_symtab (abfd, alocation)
+_bfd_ecoff_canonicalize_symtab (abfd, alocation)
bfd *abfd;
asymbol **alocation;
{
@@ -1443,7 +1462,7 @@ _bfd_ecoff_get_symbol_info (abfd, symbol, ret)
/* Return whether this is a local label. */
-boolean
+bfd_boolean
_bfd_ecoff_bfd_is_local_label_name (abfd, name)
bfd *abfd ATTRIBUTE_UNUSED;
const char *name;
@@ -1642,7 +1661,7 @@ _bfd_ecoff_print_symbol (abfd, filep, symbol, how)
/* Read in the relocs for a section. */
-static boolean
+static bfd_boolean
ecoff_slurp_reloc_table (abfd, section, symbols)
bfd *abfd;
asection *section;
@@ -1659,10 +1678,10 @@ ecoff_slurp_reloc_table (abfd, section, symbols)
if (section->relocation != (arelent *) NULL
|| section->reloc_count == 0
|| (section->flags & SEC_CONSTRUCTOR) != 0)
- return true;
+ return TRUE;
if (! _bfd_ecoff_slurp_symbol_table (abfd))
- return false;
+ return FALSE;
amt = section->reloc_count;
amt *= sizeof (arelent);
@@ -1673,11 +1692,11 @@ ecoff_slurp_reloc_table (abfd, section, symbols)
external_relocs = (char *) bfd_alloc (abfd, amt);
if (internal_relocs == (arelent *) NULL
|| external_relocs == (char *) NULL)
- return false;
+ return FALSE;
if (bfd_seek (abfd, section->rel_filepos, SEEK_SET) != 0)
- return false;
+ return FALSE;
if (bfd_bread (external_relocs, amt, abfd) != amt)
- return false;
+ return FALSE;
for (i = 0, rptr = internal_relocs; i < section->reloc_count; i++, rptr++)
{
@@ -1747,7 +1766,7 @@ ecoff_slurp_reloc_table (abfd, section, symbols)
section->relocation = internal_relocs;
- return true;
+ return TRUE;
}
/* Get a canonical list of relocs. */
@@ -1795,7 +1814,7 @@ _bfd_ecoff_canonicalize_reloc (abfd, section, relptr, symbols)
and return the name of the source file and the line nearest to the
wanted location. */
-boolean
+bfd_boolean
_bfd_ecoff_find_nearest_line (abfd, section, ignore_symbols, offset,
filename_ptr, functionname_ptr, retline_ptr)
bfd *abfd;
@@ -1814,7 +1833,7 @@ _bfd_ecoff_find_nearest_line (abfd, section, ignore_symbols, offset,
/* Make sure we have the FDR's. */
if (! _bfd_ecoff_slurp_symbolic_info (abfd, (asection *) NULL, debug_info)
|| bfd_get_symcount (abfd) == 0)
- return false;
+ return FALSE;
if (ecoff_data (abfd)->find_line_info == NULL)
{
@@ -1822,7 +1841,7 @@ _bfd_ecoff_find_nearest_line (abfd, section, ignore_symbols, offset,
ecoff_data (abfd)->find_line_info
= (struct ecoff_find_line *) bfd_zalloc (abfd, amt);
if (ecoff_data (abfd)->find_line_info == NULL)
- return false;
+ return FALSE;
}
line_info = ecoff_data (abfd)->find_line_info;
@@ -1844,7 +1863,7 @@ _bfd_ecoff_find_nearest_line (abfd, section, ignore_symbols, offset,
the symbol table, so this function only handles the other debugging
information. */
-boolean
+bfd_boolean
_bfd_ecoff_bfd_copy_private_bfd_data (ibfd, obfd)
bfd *ibfd;
bfd *obfd;
@@ -1854,13 +1873,13 @@ _bfd_ecoff_bfd_copy_private_bfd_data (ibfd, obfd)
register int i;
asymbol **sym_ptr_ptr;
size_t c;
- boolean local;
+ bfd_boolean local;
/* We only want to copy information over if both BFD's use ECOFF
format. */
if (bfd_get_flavour (ibfd) != bfd_target_ecoff_flavour
|| bfd_get_flavour (obfd) != bfd_target_ecoff_flavour)
- return true;
+ return TRUE;
/* Copy the GP value and the register masks. */
ecoff_data (obfd)->gp = ecoff_data (ibfd)->gp;
@@ -1876,15 +1895,15 @@ _bfd_ecoff_bfd_copy_private_bfd_data (ibfd, obfd)
c = bfd_get_symcount (obfd);
sym_ptr_ptr = bfd_get_outsymbols (obfd);
if (c == 0 || sym_ptr_ptr == (asymbol **) NULL)
- return true;
+ return TRUE;
/* See if there are any local symbols. */
- local = false;
+ local = FALSE;
for (; c > 0; c--, sym_ptr_ptr++)
{
if (ecoffsymbol (*sym_ptr_ptr)->local)
{
- local = true;
+ local = TRUE;
break;
}
}
@@ -1947,14 +1966,14 @@ _bfd_ecoff_bfd_copy_private_bfd_data (ibfd, obfd)
}
}
- return true;
+ return TRUE;
}
/* Set the architecture. The supported architecture is stored in the
backend pointer. We always set the architecture anyhow, since many
callers ignore the return value. */
-boolean
+bfd_boolean
_bfd_ecoff_set_arch_mach (abfd, arch, machine)
bfd *abfd;
enum bfd_architecture arch;
@@ -1969,7 +1988,7 @@ _bfd_ecoff_set_arch_mach (abfd, arch, machine)
int
_bfd_ecoff_sizeof_headers (abfd, reloc)
bfd *abfd;
- boolean reloc ATTRIBUTE_UNUSED;
+ bfd_boolean reloc ATTRIBUTE_UNUSED;
{
asection *current;
int c;
@@ -1989,7 +2008,7 @@ _bfd_ecoff_sizeof_headers (abfd, reloc)
/* Get the contents of a section. */
-boolean
+bfd_boolean
_bfd_ecoff_get_section_contents (abfd, section, location, offset, count)
bfd *abfd;
asection *section;
@@ -2033,7 +2052,7 @@ ecoff_sort_hdrs (arg1, arg2)
/* Calculate the file position for each section, and set
reloc_filepos. */
-static boolean
+static bfd_boolean
ecoff_compute_section_file_positions (abfd)
bfd *abfd;
{
@@ -2042,12 +2061,12 @@ ecoff_compute_section_file_positions (abfd)
asection *current;
unsigned int i;
file_ptr old_sofar;
- boolean rdata_in_text;
- boolean first_data, first_nonalloc;
+ bfd_boolean rdata_in_text;
+ bfd_boolean first_data, first_nonalloc;
const bfd_vma round = ecoff_backend (abfd)->round;
bfd_size_type amt;
- sofar = _bfd_ecoff_sizeof_headers (abfd, false);
+ sofar = _bfd_ecoff_sizeof_headers (abfd, FALSE);
file_sofar = sofar;
/* Sort the sections by VMA. */
@@ -2055,7 +2074,7 @@ ecoff_compute_section_file_positions (abfd)
amt *= sizeof (asection *);
sorted_hdrs = (asection **) bfd_malloc (amt);
if (sorted_hdrs == NULL)
- return false;
+ return FALSE;
for (current = abfd->sections, i = 0;
current != NULL;
current = current->next, i++)
@@ -2079,15 +2098,15 @@ ecoff_compute_section_file_positions (abfd)
&& strcmp (current->name, _PDATA) != 0
&& strcmp (current->name, _RCONST) != 0)
{
- rdata_in_text = false;
+ rdata_in_text = FALSE;
break;
}
}
}
ecoff_data (abfd)->rdata_in_text = rdata_in_text;
- first_data = true;
- first_nonalloc = true;
+ first_data = TRUE;
+ first_nonalloc = TRUE;
for (i = 0; i < abfd->section_count; i++)
{
unsigned int alignment_power;
@@ -2120,7 +2139,7 @@ ecoff_compute_section_file_positions (abfd)
{
sofar = (sofar + round - 1) &~ (round - 1);
file_sofar = (file_sofar + round - 1) &~ (round - 1);
- first_data = false;
+ first_data = FALSE;
}
else if (strcmp (current->name, _LIB) == 0)
{
@@ -2138,7 +2157,7 @@ ecoff_compute_section_file_positions (abfd)
/* Skip up to the next page for an unallocated section, such
as the .comment section on the Alpha. This leaves room
for the .bss section. */
- first_nonalloc = false;
+ first_nonalloc = FALSE;
sofar = (sofar + round - 1) &~ (round - 1);
file_sofar = (file_sofar + round - 1) &~ (round - 1);
}
@@ -2177,7 +2196,7 @@ ecoff_compute_section_file_positions (abfd)
ecoff_data (abfd)->reloc_filepos = file_sofar;
- return true;
+ return TRUE;
}
/* Determine the location of the relocs for all the sections in the
@@ -2199,7 +2218,7 @@ ecoff_compute_reloc_file_positions (abfd)
{
if (! ecoff_compute_section_file_positions (abfd))
abort ();
- abfd->output_has_begun = true;
+ abfd->output_has_begun = TRUE;
}
reloc_base = ecoff_data (abfd)->reloc_filepos;
@@ -2239,22 +2258,22 @@ ecoff_compute_reloc_file_positions (abfd)
/* Set the contents of a section. */
-boolean
+bfd_boolean
_bfd_ecoff_set_section_contents (abfd, section, location, offset, count)
bfd *abfd;
asection *section;
- PTR location;
+ const PTR location;
file_ptr offset;
bfd_size_type count;
{
file_ptr pos;
/* This must be done first, because bfd_set_section_contents is
- going to set output_has_begun to true. */
+ going to set output_has_begun to TRUE. */
if (! abfd->output_has_begun)
{
if (! ecoff_compute_section_file_positions (abfd))
- return false;
+ return FALSE;
}
/* Handle the .lib section specially so that Irix 4 shared libraries
@@ -2275,14 +2294,14 @@ _bfd_ecoff_set_section_contents (abfd, section, location, offset, count)
}
if (count == 0)
- return true;
+ return TRUE;
pos = section->filepos + offset;
if (bfd_seek (abfd, pos, SEEK_SET) != 0
|| bfd_bwrite (location, count, abfd) != count)
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
/* Get the GP value for an ECOFF file. This is a hook used by
@@ -2305,7 +2324,7 @@ bfd_ecoff_get_gp_value (abfd)
/* Set the GP value for an ECOFF file. This is a hook used by the
assembler. */
-boolean
+bfd_boolean
bfd_ecoff_set_gp_value (abfd, gp_value)
bfd *abfd;
bfd_vma gp_value;
@@ -2314,18 +2333,18 @@ bfd_ecoff_set_gp_value (abfd, gp_value)
|| bfd_get_format (abfd) != bfd_object)
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
ecoff_data (abfd)->gp = gp_value;
- return true;
+ return TRUE;
}
/* Set the register masks for an ECOFF file. This is a hook used by
the assembler. */
-boolean
+bfd_boolean
bfd_ecoff_set_regmasks (abfd, gprmask, fprmask, cprmask)
bfd *abfd;
unsigned long gprmask;
@@ -2338,7 +2357,7 @@ bfd_ecoff_set_regmasks (abfd, gprmask, fprmask, cprmask)
|| bfd_get_format (abfd) != bfd_object)
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
tdata = ecoff_data (abfd);
@@ -2352,13 +2371,13 @@ bfd_ecoff_set_regmasks (abfd, gprmask, fprmask, cprmask)
tdata->cprmask[i] = cprmask[i];
}
- return true;
+ return TRUE;
}
/* Get ECOFF EXTR information for an external symbol. This function
is passed to bfd_ecoff_debug_externals. */
-static boolean
+static bfd_boolean
ecoff_get_extr (sym, esym)
asymbol *sym;
EXTR *esym;
@@ -2373,7 +2392,7 @@ ecoff_get_extr (sym, esym)
if ((sym->flags & BSF_DEBUGGING) != 0
|| (sym->flags & BSF_LOCAL) != 0
|| (sym->flags & BSF_SECTION_SYM) != 0)
- return false;
+ return FALSE;
esym->jmptbl = 0;
esym->cobol_main = 0;
@@ -2385,13 +2404,13 @@ ecoff_get_extr (sym, esym)
esym->asym.sc = scAbs;
esym->asym.reserved = 0;
esym->asym.index = indexNil;
- return true;
+ return TRUE;
}
ecoff_sym_ptr = ecoffsymbol (sym);
if (ecoff_sym_ptr->local)
- return false;
+ return FALSE;
input_bfd = bfd_asymbol_bfd (sym);
(*(ecoff_backend (input_bfd)->debug_swap.swap_ext_in))
@@ -2417,7 +2436,7 @@ ecoff_get_extr (sym, esym)
esym->ifd = input_debug->ifdmap[esym->ifd];
}
- return true;
+ return TRUE;
}
/* Set the external symbol index. This routine is passed to
@@ -2433,7 +2452,7 @@ ecoff_set_index (sym, indx)
/* Write out an ECOFF file. */
-boolean
+bfd_boolean
_bfd_ecoff_write_object_contents (abfd)
bfd *abfd;
{
@@ -2445,13 +2464,11 @@ _bfd_ecoff_write_object_contents (abfd)
const bfd_size_type external_hdr_size
= backend->debug_swap.external_hdr_size;
const bfd_size_type external_reloc_size = backend->external_reloc_size;
- void (* const adjust_reloc_out) PARAMS ((bfd *,
- const arelent *,
- struct internal_reloc *))
+ void (* const adjust_reloc_out)
+ PARAMS ((bfd *, const arelent *, struct internal_reloc *))
= backend->adjust_reloc_out;
- void (* const swap_reloc_out) PARAMS ((bfd *,
- const struct internal_reloc *,
- PTR))
+ void (* const swap_reloc_out)
+ PARAMS ((bfd *, const struct internal_reloc *, PTR))
= backend->swap_reloc_out;
struct ecoff_debug_info * const debug = &ecoff_data (abfd)->debug_info;
HDRR * const symhdr = &debug->symbolic_header;
@@ -2460,10 +2477,10 @@ _bfd_ecoff_write_object_contents (abfd)
bfd_size_type reloc_size;
bfd_size_type text_size;
bfd_vma text_start;
- boolean set_text_start;
+ bfd_boolean set_text_start;
bfd_size_type data_size;
bfd_vma data_start;
- boolean set_data_start;
+ bfd_boolean set_data_start;
bfd_size_type bss_size;
PTR buff = NULL;
PTR reloc_buff = NULL;
@@ -2485,14 +2502,14 @@ _bfd_ecoff_write_object_contents (abfd)
}
if ((abfd->flags & D_PAGED) != 0)
- text_size = _bfd_ecoff_sizeof_headers (abfd, false);
+ text_size = _bfd_ecoff_sizeof_headers (abfd, FALSE);
else
text_size = 0;
text_start = 0;
- set_text_start = false;
+ set_text_start = FALSE;
data_size = 0;
data_start = 0;
- set_data_start = false;
+ set_data_start = FALSE;
bss_size = 0;
/* Write section headers to the file. */
@@ -2588,7 +2605,7 @@ _bfd_ecoff_write_object_contents (abfd)
if (! set_text_start || text_start > vma)
{
text_start = vma;
- set_text_start = true;
+ set_text_start = TRUE;
}
}
else if ((section.s_flags & STYP_RDATA) != 0
@@ -2604,7 +2621,7 @@ _bfd_ecoff_write_object_contents (abfd)
if (! set_data_start || data_start > vma)
{
data_start = vma;
- set_data_start = true;
+ set_data_start = TRUE;
}
}
else if ((section.s_flags & STYP_BSS) != 0
@@ -2870,13 +2887,13 @@ _bfd_ecoff_write_object_contents (abfd)
bfd_release (abfd, reloc_buff);
if (buff != NULL)
free (buff);
- return true;
+ return TRUE;
error_return:
if (reloc_buff != NULL)
bfd_release (abfd, reloc_buff);
if (buff != NULL)
free (buff);
- return false;
+ return FALSE;
}
/* Archive handling. ECOFF uses what appears to be a unique type of
@@ -2949,7 +2966,7 @@ ecoff_armap_hash (s, rehash, size, hlog)
/* Read in the armap. */
-boolean
+bfd_boolean
_bfd_ecoff_slurp_armap (abfd)
bfd *abfd;
{
@@ -2968,12 +2985,12 @@ _bfd_ecoff_slurp_armap (abfd)
/* Get the name of the first element. */
i = bfd_bread ((PTR) nextname, (bfd_size_type) 16, abfd);
if (i == 0)
- return true;
+ return TRUE;
if (i != 16)
- return false;
+ return FALSE;
if (bfd_seek (abfd, (file_ptr) -16, SEEK_CUR) != 0)
- return false;
+ return FALSE;
/* Irix 4.0.5F apparently can use either an ECOFF armap or a
standard COFF armap. We could move the ECOFF armap stuff into
@@ -2995,8 +3012,8 @@ _bfd_ecoff_slurp_armap (abfd)
|| strncmp (nextname + ARMAP_END_INDEX,
ARMAP_END, sizeof ARMAP_END - 1) != 0)
{
- bfd_has_map (abfd) = false;
- return true;
+ bfd_has_map (abfd) = FALSE;
+ return TRUE;
}
/* Make sure we have the right byte ordering. */
@@ -3006,27 +3023,27 @@ _bfd_ecoff_slurp_armap (abfd)
^ (bfd_big_endian (abfd))))
{
bfd_set_error (bfd_error_wrong_format);
- return false;
+ return FALSE;
}
/* Read in the armap. */
ardata = bfd_ardata (abfd);
mapdata = (struct areltdata *) _bfd_read_ar_hdr (abfd);
if (mapdata == (struct areltdata *) NULL)
- return false;
+ return FALSE;
parsed_size = mapdata->parsed_size;
bfd_release (abfd, (PTR) mapdata);
raw_armap = (char *) bfd_alloc (abfd, parsed_size);
if (raw_armap == (char *) NULL)
- return false;
+ return FALSE;
if (bfd_bread ((PTR) raw_armap, parsed_size, abfd) != parsed_size)
{
if (bfd_get_error () != bfd_error_system_call)
bfd_set_error (bfd_error_malformed_archive);
bfd_release (abfd, (PTR) raw_armap);
- return false;
+ return FALSE;
}
ardata->tdata = (PTR) raw_armap;
@@ -3086,7 +3103,7 @@ _bfd_ecoff_slurp_armap (abfd)
amt *= sizeof (struct symdef);
symdef_ptr = (struct symdef *) bfd_alloc (abfd, amt);
if (!symdef_ptr)
- return false;
+ return FALSE;
ardata->symdefs = (carsym *) symdef_ptr;
@@ -3108,14 +3125,14 @@ _bfd_ecoff_slurp_armap (abfd)
/* Pad to an even boundary. */
ardata->first_file_filepos += ardata->first_file_filepos % 2;
- bfd_has_map (abfd) = true;
+ bfd_has_map (abfd) = TRUE;
- return true;
+ return TRUE;
}
/* Write out an armap. */
-boolean
+bfd_boolean
_bfd_ecoff_write_armap (abfd, elength, map, orl_count, stridx)
bfd *abfd;
unsigned int elength;
@@ -3199,15 +3216,15 @@ _bfd_ecoff_write_armap (abfd, elength, map, orl_count, stridx)
if (bfd_bwrite ((PTR) &hdr, (bfd_size_type) sizeof (struct ar_hdr), abfd)
!= sizeof (struct ar_hdr))
- return false;
+ return FALSE;
H_PUT_32 (abfd, hashsize, temp);
if (bfd_bwrite ((PTR) temp, (bfd_size_type) 4, abfd) != 4)
- return false;
+ return FALSE;
hashtable = (bfd_byte *) bfd_zalloc (abfd, symdefsize);
if (!hashtable)
- return false;
+ return FALSE;
current = abfd->archive_head;
last_elt = current;
@@ -3252,21 +3269,21 @@ _bfd_ecoff_write_armap (abfd, elength, map, orl_count, stridx)
}
if (bfd_bwrite ((PTR) hashtable, symdefsize, abfd) != symdefsize)
- return false;
+ return FALSE;
bfd_release (abfd, hashtable);
/* Now write the strings. */
H_PUT_32 (abfd, stringsize, temp);
if (bfd_bwrite ((PTR) temp, (bfd_size_type) 4, abfd) != 4)
- return false;
+ return FALSE;
for (i = 0; i < orl_count; i++)
{
bfd_size_type len;
len = strlen (*map[i].name) + 1;
if (bfd_bwrite ((PTR) (*map[i].name), len, abfd) != len)
- return false;
+ return FALSE;
}
/* The spec sez this should be a newline. But in order to be
@@ -3274,10 +3291,10 @@ _bfd_ecoff_write_armap (abfd, elength, map, orl_count, stridx)
if (padit)
{
if (bfd_bwrite ("", (bfd_size_type) 1, abfd) != 1)
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* See whether this BFD is an archive. If it is, read in the armap
@@ -3343,7 +3360,7 @@ _bfd_ecoff_archive_p (abfd)
first = bfd_openr_next_archived_file (abfd, (bfd *) NULL);
if (first != NULL)
{
- first->target_defaulted = false;
+ first->target_defaulted = FALSE;
if (bfd_check_format (first, bfd_object)
&& first->xvec != abfd->xvec)
{
@@ -3372,13 +3389,13 @@ static struct bfd_hash_entry *ecoff_link_hash_newfunc
PARAMS ((struct bfd_hash_entry *entry,
struct bfd_hash_table *table,
const char *string));
-static boolean ecoff_link_add_archive_symbols
+static bfd_boolean ecoff_link_add_archive_symbols
PARAMS ((bfd *, struct bfd_link_info *));
-static boolean ecoff_link_check_archive_element
- PARAMS ((bfd *, struct bfd_link_info *, boolean *pneeded));
-static boolean ecoff_link_add_object_symbols
+static bfd_boolean ecoff_link_check_archive_element
+ PARAMS ((bfd *, struct bfd_link_info *, bfd_boolean *pneeded));
+static bfd_boolean ecoff_link_add_object_symbols
PARAMS ((bfd *, struct bfd_link_info *));
-static boolean ecoff_link_add_externals
+static bfd_boolean ecoff_link_add_externals
PARAMS ((bfd *, struct bfd_link_info *, PTR, char *));
/* Routine to create an entry in an ECOFF link hash table. */
@@ -3449,7 +3466,7 @@ _bfd_ecoff_bfd_link_hash_table_create (abfd)
#define ecoff_link_hash_traverse(table, func, info) \
(bfd_link_hash_traverse \
(&(table)->root, \
- (boolean (*) PARAMS ((struct bfd_link_hash_entry *, PTR))) (func), \
+ (bfd_boolean (*) PARAMS ((struct bfd_link_hash_entry *, PTR))) (func), \
(info)))
/* Get the ECOFF link hash table from the info structure. This is
@@ -3460,7 +3477,7 @@ _bfd_ecoff_bfd_link_hash_table_create (abfd)
/* Given an ECOFF BFD, add symbols to the global hash table as
appropriate. */
-boolean
+bfd_boolean
_bfd_ecoff_bfd_link_add_symbols (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -3473,7 +3490,7 @@ _bfd_ecoff_bfd_link_add_symbols (abfd, info)
return ecoff_link_add_archive_symbols (abfd, info);
default:
bfd_set_error (bfd_error_wrong_format);
- return false;
+ return FALSE;
}
}
@@ -3484,7 +3501,7 @@ _bfd_ecoff_bfd_link_add_symbols (abfd, info)
already have a hash table, so there is no reason to construct
another one. */
-static boolean
+static bfd_boolean
ecoff_link_add_archive_symbols (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -3502,9 +3519,9 @@ ecoff_link_add_archive_symbols (abfd, info)
{
/* An empty archive is a special case. */
if (bfd_openr_next_archived_file (abfd, (bfd *) NULL) == NULL)
- return true;
+ return TRUE;
bfd_set_error (bfd_error_no_armap);
- return false;
+ return FALSE;
}
/* If we don't have any raw data for this archive, as can happen on
@@ -3549,9 +3566,9 @@ ecoff_link_add_archive_symbols (abfd, info)
entry if it is the tail, because that would lose any
entries we add to the list later on. */
if (*pundef != info->hash->undefs_tail)
- *pundef = (*pundef)->next;
+ *pundef = (*pundef)->und_next;
else
- pundef = &(*pundef)->next;
+ pundef = &(*pundef)->und_next;
continue;
}
@@ -3561,7 +3578,7 @@ ecoff_link_add_archive_symbols (abfd, info)
other object format. */
if (h->type != bfd_link_hash_undefined)
{
- pundef = &(*pundef)->next;
+ pundef = &(*pundef)->und_next;
continue;
}
@@ -3573,7 +3590,7 @@ ecoff_link_add_archive_symbols (abfd, info)
if (file_offset == 0)
{
/* Nothing in this slot. */
- pundef = &(*pundef)->next;
+ pundef = &(*pundef)->und_next;
continue;
}
@@ -3582,10 +3599,10 @@ ecoff_link_add_archive_symbols (abfd, info)
|| strcmp (name, h->root.string) != 0)
{
unsigned int srch;
- boolean found;
+ bfd_boolean found;
/* That was the wrong symbol. Try rehashing. */
- found = false;
+ found = FALSE;
for (srch = (hash + rehash) & (armap_count - 1);
srch != hash;
srch = (srch + rehash) & (armap_count - 1))
@@ -3597,14 +3614,14 @@ ecoff_link_add_archive_symbols (abfd, info)
if (name[0] == h->root.string[0]
&& strcmp (name, h->root.string) == 0)
{
- found = true;
+ found = TRUE;
break;
}
}
if (! found)
{
- pundef = &(*pundef)->next;
+ pundef = &(*pundef)->und_next;
continue;
}
@@ -3613,33 +3630,33 @@ ecoff_link_add_archive_symbols (abfd, info)
element = (*backend->get_elt_at_filepos) (abfd, (file_ptr) file_offset);
if (element == (bfd *) NULL)
- return false;
+ return FALSE;
if (! bfd_check_format (element, bfd_object))
- return false;
+ return FALSE;
/* Unlike the generic linker, we know that this element provides
a definition for an undefined symbol and we know that we want
to include it. We don't need to check anything. */
if (! (*info->callbacks->add_archive_element) (info, element, name))
- return false;
+ return FALSE;
if (! ecoff_link_add_object_symbols (element, info))
- return false;
+ return FALSE;
- pundef = &(*pundef)->next;
+ pundef = &(*pundef)->und_next;
}
- return true;
+ return TRUE;
}
/* This is called if we used _bfd_generic_link_add_archive_symbols
because we were not dealing with an ECOFF archive. */
-static boolean
+static bfd_boolean
ecoff_link_check_archive_element (abfd, info, pneeded)
bfd *abfd;
struct bfd_link_info *info;
- boolean *pneeded;
+ bfd_boolean *pneeded;
{
const struct ecoff_backend_data * const backend = ecoff_backend (abfd);
void (* const swap_ext_in) PARAMS ((bfd *, PTR, EXTR *))
@@ -3652,7 +3669,7 @@ ecoff_link_check_archive_element (abfd, info, pneeded)
char *ext_ptr;
char *ext_end;
- *pneeded = false;
+ *pneeded = FALSE;
if (! ecoff_slurp_symbolic_header (abfd))
goto error_return;
@@ -3690,7 +3707,7 @@ ecoff_link_check_archive_element (abfd, info, pneeded)
for (; ext_ptr < ext_end; ext_ptr += external_ext_size)
{
EXTR esym;
- boolean def;
+ bfd_boolean def;
const char *name;
struct bfd_link_hash_entry *h;
@@ -3716,10 +3733,10 @@ ecoff_link_check_archive_element (abfd, info, pneeded)
case scInit:
case scFini:
case scRConst:
- def = true;
+ def = TRUE;
break;
default:
- def = false;
+ def = FALSE;
break;
}
@@ -3727,7 +3744,7 @@ ecoff_link_check_archive_element (abfd, info, pneeded)
continue;
name = ssext + esym.asym.iss;
- h = bfd_link_hash_lookup (info->hash, name, false, false, true);
+ h = bfd_link_hash_lookup (info->hash, name, FALSE, FALSE, TRUE);
/* Unlike the generic linker, we do not pull in elements because
of common symbols. */
@@ -3741,7 +3758,7 @@ ecoff_link_check_archive_element (abfd, info, pneeded)
if (! ecoff_link_add_externals (abfd, info, external_ext, ssext))
goto error_return;
- *pneeded = true;
+ *pneeded = TRUE;
goto successful_return;
}
@@ -3750,19 +3767,19 @@ ecoff_link_check_archive_element (abfd, info, pneeded)
free (external_ext);
if (ssext != NULL)
free (ssext);
- return true;
+ return TRUE;
error_return:
if (external_ext != NULL)
free (external_ext);
if (ssext != NULL)
free (ssext);
- return false;
+ return FALSE;
}
/* Add symbols from an ECOFF object file to the global linker hash
table. */
-static boolean
+static bfd_boolean
ecoff_link_add_object_symbols (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -3772,14 +3789,14 @@ ecoff_link_add_object_symbols (abfd, info)
PTR external_ext = NULL;
bfd_size_type esize;
char *ssext = NULL;
- boolean result;
+ bfd_boolean result;
if (! ecoff_slurp_symbolic_header (abfd))
- return false;
+ return FALSE;
/* If there are no symbols, we don't want it. */
if (bfd_get_symcount (abfd) == 0)
- return true;
+ return TRUE;
symhdr = &ecoff_data (abfd)->debug_info.symbolic_header;
@@ -3816,7 +3833,7 @@ ecoff_link_add_object_symbols (abfd, info)
free (ssext);
if (external_ext != NULL)
free (external_ext);
- return false;
+ return FALSE;
}
/* Add the external symbols of an object file to the global linker
@@ -3825,7 +3842,7 @@ ecoff_link_add_object_symbols (abfd, info)
explicitly save any information we may need later on in the link.
We do not want to read the external symbol information again. */
-static boolean
+static bfd_boolean
ecoff_link_add_externals (abfd, info, external_ext, ssext)
bfd *abfd;
struct bfd_link_info *info;
@@ -3848,7 +3865,7 @@ ecoff_link_add_externals (abfd, info, external_ext, ssext)
amt *= sizeof (struct bfd_link_hash_entry *);
sym_hash = (struct bfd_link_hash_entry **) bfd_alloc (abfd, amt);
if (!sym_hash)
- return false;
+ return FALSE;
ecoff_data (abfd)->sym_hashes = (struct ecoff_link_hash_entry **) sym_hash;
ext_ptr = (char *) external_ext;
@@ -3856,7 +3873,7 @@ ecoff_link_add_externals (abfd, info, external_ext, ssext)
for (; ext_ptr < ext_end; ext_ptr += external_ext_size, sym_hash++)
{
EXTR esym;
- boolean skip;
+ bfd_boolean skip;
bfd_vma value;
asection *section;
const char *name;
@@ -3867,7 +3884,7 @@ ecoff_link_add_externals (abfd, info, external_ext, ssext)
(*swap_ext_in) (abfd, (PTR) ext_ptr, &esym);
/* Skip debugging symbols. */
- skip = false;
+ skip = FALSE;
switch (esym.asym.st)
{
case stGlobal:
@@ -3877,7 +3894,7 @@ ecoff_link_add_externals (abfd, info, external_ext, ssext)
case stStaticProc:
break;
default:
- skip = true;
+ skip = TRUE;
break;
}
@@ -3983,8 +4000,8 @@ ecoff_link_add_externals (abfd, info, external_ext, ssext)
if (! (_bfd_generic_link_add_one_symbol
(info, abfd, name,
(flagword) (esym.weakext ? BSF_WEAK : BSF_GLOBAL),
- section, value, (const char *) NULL, true, true, sym_hash)))
- return false;
+ section, value, (const char *) NULL, TRUE, TRUE, sym_hash)))
+ return FALSE;
h = (struct ecoff_link_hash_entry *) *sym_hash;
@@ -4024,20 +4041,20 @@ ecoff_link_add_externals (abfd, info, external_ext, ssext)
}
}
- return true;
+ return TRUE;
}
/* ECOFF final link routines. */
-static boolean ecoff_final_link_debug_accumulate
+static bfd_boolean ecoff_final_link_debug_accumulate
PARAMS ((bfd *output_bfd, bfd *input_bfd, struct bfd_link_info *,
PTR handle));
-static boolean ecoff_link_write_external
+static bfd_boolean ecoff_link_write_external
PARAMS ((struct ecoff_link_hash_entry *, PTR));
-static boolean ecoff_indirect_link_order
+static bfd_boolean ecoff_indirect_link_order
PARAMS ((bfd *, struct bfd_link_info *, asection *,
struct bfd_link_order *));
-static boolean ecoff_reloc_link_order
+static bfd_boolean ecoff_reloc_link_order
PARAMS ((bfd *, struct bfd_link_info *, asection *,
struct bfd_link_order *));
@@ -4054,7 +4071,7 @@ struct extsym_info
processes all the link order information. This may cause it to
close and reopen some input BFDs; I'll see how bad this is. */
-boolean
+bfd_boolean
_bfd_ecoff_bfd_final_link (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -4101,18 +4118,18 @@ _bfd_ecoff_bfd_final_link (abfd, info)
handle = bfd_ecoff_debug_init (abfd, debug, &backend->debug_swap, info);
if (handle == (PTR) NULL)
- return false;
+ return FALSE;
/* Accumulate the debugging symbols from each input BFD. */
for (input_bfd = info->input_bfds;
input_bfd != (bfd *) NULL;
input_bfd = input_bfd->link_next)
{
- boolean ret;
+ bfd_boolean ret;
if (bfd_get_flavour (input_bfd) == bfd_target_ecoff_flavour)
{
- /* Abitrarily set the symbolic header vstamp to the vstamp
+ /* Arbitrarily set the symbolic header vstamp to the vstamp
of the first object file in the link. */
if (symhdr->vstamp == 0)
symhdr->vstamp
@@ -4125,7 +4142,7 @@ _bfd_ecoff_bfd_final_link (abfd, info)
debug, &backend->debug_swap,
input_bfd, info);
if (! ret)
- return false;
+ return FALSE;
/* Combine the register masks. */
ecoff_data (abfd)->gprmask |= ecoff_data (input_bfd)->gprmask;
@@ -4143,7 +4160,7 @@ _bfd_ecoff_bfd_final_link (abfd, info)
ecoff_link_write_external,
(PTR) &einfo);
- if (info->relocateable)
+ if (info->relocatable)
{
/* We need to make a pass over the link_orders to count up the
number of relocations we will need to output, so that we know
@@ -4169,11 +4186,11 @@ _bfd_ecoff_bfd_final_link (abfd, info)
if (! bfd_ecoff_write_accumulated_debug (handle, abfd, debug,
&backend->debug_swap, info,
ecoff_data (abfd)->sym_filepos))
- return false;
+ return FALSE;
bfd_ecoff_debug_free (handle, abfd, debug, &backend->debug_swap, info);
- if (info->relocateable)
+ if (info->relocatable)
{
/* Now reset the reloc_count field of the sections in the output
BFD to 0, so that we can use them to keep track of how many
@@ -4187,13 +4204,13 @@ _bfd_ecoff_bfd_final_link (abfd, info)
{
struct bfd_link_hash_entry *h;
- h = bfd_link_hash_lookup (info->hash, "_gp", false, false, true);
+ h = bfd_link_hash_lookup (info->hash, "_gp", FALSE, FALSE, TRUE);
if (h != (struct bfd_link_hash_entry *) NULL
&& h->type == bfd_link_hash_defined)
ecoff_data (abfd)->gp = (h->u.def.value
+ h->u.def.section->output_section->vma
+ h->u.def.section->output_offset);
- else if (info->relocateable)
+ else if (info->relocatable)
{
bfd_vma lo;
@@ -4230,34 +4247,34 @@ _bfd_ecoff_bfd_final_link (abfd, info)
== bfd_target_ecoff_flavour))
{
if (! ecoff_indirect_link_order (abfd, info, o, p))
- return false;
+ return FALSE;
}
else if (p->type == bfd_section_reloc_link_order
|| p->type == bfd_symbol_reloc_link_order)
{
if (! ecoff_reloc_link_order (abfd, info, o, p))
- return false;
+ return FALSE;
}
else
{
if (! _bfd_default_link_order (abfd, info, o, p))
- return false;
+ return FALSE;
}
}
}
bfd_get_symcount (abfd) = symhdr->iextMax + symhdr->isymMax;
- ecoff_data (abfd)->linker = true;
+ ecoff_data (abfd)->linker = TRUE;
- return true;
+ return TRUE;
}
/* Accumulate the debugging information for an input BFD into the
output BFD. This must read in the symbolic information of the
input BFD. */
-static boolean
+static bfd_boolean
ecoff_final_link_debug_accumulate (output_bfd, input_bfd, info, handle)
bfd *output_bfd;
bfd *input_bfd;
@@ -4268,7 +4285,7 @@ ecoff_final_link_debug_accumulate (output_bfd, input_bfd, info, handle)
const struct ecoff_debug_swap * const swap =
&ecoff_backend (input_bfd)->debug_swap;
HDRR *symhdr = &debug->symbolic_header;
- boolean ret;
+ bfd_boolean ret;
#define READ(ptr, offset, count, size, type) \
if (symhdr->count == 0) \
@@ -4279,13 +4296,13 @@ ecoff_final_link_debug_accumulate (output_bfd, input_bfd, info, handle)
debug->ptr = (type) bfd_malloc (amt); \
if (debug->ptr == NULL) \
{ \
- ret = false; \
+ ret = FALSE; \
goto return_something; \
} \
if (bfd_seek (input_bfd, (file_ptr) symhdr->offset, SEEK_SET) != 0 \
|| bfd_bread (debug->ptr, amt, input_bfd) != amt) \
{ \
- ret = false; \
+ ret = FALSE; \
goto return_something; \
} \
}
@@ -4356,37 +4373,37 @@ ecoff_final_link_debug_accumulate (output_bfd, input_bfd, info, handle)
/* Put out information for an external symbol. These come only from
the hash table. */
-static boolean
+static bfd_boolean
ecoff_link_write_external (h, data)
struct ecoff_link_hash_entry *h;
PTR data;
{
struct extsym_info *einfo = (struct extsym_info *) data;
bfd *output_bfd = einfo->abfd;
- boolean strip;
+ bfd_boolean strip;
if (h->root.type == bfd_link_hash_warning)
{
h = (struct ecoff_link_hash_entry *) h->root.u.i.link;
if (h->root.type == bfd_link_hash_new)
- return true;
+ return TRUE;
}
/* We need to check if this symbol is being stripped. */
if (h->root.type == bfd_link_hash_undefined
|| h->root.type == bfd_link_hash_undefweak)
- strip = false;
+ strip = FALSE;
else if (einfo->info->strip == strip_all
|| (einfo->info->strip == strip_some
&& bfd_hash_lookup (einfo->info->keep_hash,
h->root.root.string,
- false, false) == NULL))
- strip = true;
+ FALSE, FALSE) == NULL))
+ strip = TRUE;
else
- strip = false;
+ strip = FALSE;
if (strip || h->written)
- return true;
+ return TRUE;
if (h->abfd == (bfd *) NULL)
{
@@ -4484,7 +4501,7 @@ ecoff_link_write_external (h, data)
case bfd_link_hash_indirect:
/* We ignore these symbols, since the indirected symbol is
already in the hash table. */
- return true;
+ return TRUE;
}
/* bfd_ecoff_debug_one_external uses iextMax to keep track of the
@@ -4500,7 +4517,7 @@ ecoff_link_write_external (h, data)
/* Relocate and write an ECOFF section into an ECOFF output file. */
-static boolean
+static bfd_boolean
ecoff_indirect_link_order (output_bfd, info, output_section, link_order)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -4521,7 +4538,7 @@ ecoff_indirect_link_order (output_bfd, info, output_section, link_order)
BFD_ASSERT ((output_section->flags & SEC_HAS_CONTENTS) != 0);
if (link_order->size == 0)
- return true;
+ return TRUE;
input_section = link_order->u.indirect.section;
input_bfd = input_section->owner;
@@ -4591,11 +4608,11 @@ ecoff_indirect_link_order (output_bfd, info, output_section, link_order)
cooked_size))
goto error_return;
- /* If we are producing relocateable output, the relocs were
+ /* If we are producing relocatable output, the relocs were
modified, and we write them out now. We use the reloc_count
field of output_section to keep track of the number of relocs we
have output so far. */
- if (info->relocateable)
+ if (info->relocatable)
{
file_ptr pos = (output_section->rel_filepos
+ output_section->reloc_count * external_reloc_size);
@@ -4610,14 +4627,14 @@ ecoff_indirect_link_order (output_bfd, info, output_section, link_order)
free (contents);
if (external_relocs != NULL && section_tdata == NULL)
free (external_relocs);
- return true;
+ return TRUE;
error_return:
if (contents != NULL)
free (contents);
if (external_relocs != NULL && section_tdata == NULL)
free (external_relocs);
- return false;
+ return FALSE;
}
/* Generate a reloc when linking an ECOFF file. This is a reloc
@@ -4625,7 +4642,7 @@ ecoff_indirect_link_order (output_bfd, info, output_section, link_order)
is used to build constructor and destructor tables when linking
with -Ur. */
-static boolean
+static bfd_boolean
ecoff_reloc_link_order (output_bfd, info, output_section, link_order)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -4639,7 +4656,7 @@ ecoff_reloc_link_order (output_bfd, info, output_section, link_order)
struct internal_reloc in;
bfd_size_type external_reloc_size;
bfd_byte *rbuf;
- boolean ok;
+ bfd_boolean ok;
file_ptr pos;
type = link_order->type;
@@ -4654,7 +4671,7 @@ ecoff_reloc_link_order (output_bfd, info, output_section, link_order)
if (rel.howto == 0)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
if (type == bfd_section_reloc_link_order)
@@ -4670,7 +4687,7 @@ ecoff_reloc_link_order (output_bfd, info, output_section, link_order)
actually against the section. */
h = bfd_wrapped_link_hash_lookup (output_bfd, info,
link_order->u.reloc.p->u.name,
- false, false, false);
+ FALSE, FALSE, FALSE);
if (h != NULL
&& (h->type == bfd_link_hash_defined
|| h->type == bfd_link_hash_defweak))
@@ -4704,7 +4721,7 @@ ecoff_reloc_link_order (output_bfd, info, output_section, link_order)
size = bfd_get_reloc_size (rel.howto);
buf = (bfd_byte *) bfd_zmalloc (size);
if (buf == (bfd_byte *) NULL)
- return false;
+ return FALSE;
rstat = _bfd_relocate_contents (rel.howto, output_bfd,
(bfd_vma) addend, buf);
switch (rstat)
@@ -4724,7 +4741,7 @@ ecoff_reloc_link_order (output_bfd, info, output_section, link_order)
(asection *) NULL, (bfd_vma) 0)))
{
free (buf);
- return false;
+ return FALSE;
}
break;
}
@@ -4732,7 +4749,7 @@ ecoff_reloc_link_order (output_bfd, info, output_section, link_order)
(file_ptr) link_order->offset, size);
free (buf);
if (! ok)
- return false;
+ return FALSE;
}
rel.addend = 0;
@@ -4749,7 +4766,7 @@ ecoff_reloc_link_order (output_bfd, info, output_section, link_order)
h = ((struct ecoff_link_hash_entry *)
bfd_wrapped_link_hash_lookup (output_bfd, info,
link_order->u.reloc.p->u.name,
- false, false, true));
+ FALSE, FALSE, TRUE));
if (h != (struct ecoff_link_hash_entry *) NULL
&& h->indx != -1)
in.r_symndx = h->indx;
@@ -4758,7 +4775,7 @@ ecoff_reloc_link_order (output_bfd, info, output_section, link_order)
if (! ((*info->callbacks->unattached_reloc)
(info, link_order->u.reloc.p->u.name, (bfd *) NULL,
(asection *) NULL, (bfd_vma) 0)))
- return false;
+ return FALSE;
in.r_symndx = 0;
}
in.r_extern = 1;
@@ -4810,7 +4827,7 @@ ecoff_reloc_link_order (output_bfd, info, output_section, link_order)
external_reloc_size = ecoff_backend (output_bfd)->external_reloc_size;
rbuf = (bfd_byte *) bfd_malloc (external_reloc_size);
if (rbuf == (bfd_byte *) NULL)
- return false;
+ return FALSE;
(*ecoff_backend (output_bfd)->swap_reloc_out) (output_bfd, &in, (PTR) rbuf);
diff --git a/contrib/binutils/bfd/ecofflink.c b/contrib/binutils/bfd/ecofflink.c
index 5b854af..9e23848 100644
--- a/contrib/binutils/bfd/ecofflink.c
+++ b/contrib/binutils/bfd/ecofflink.c
@@ -1,23 +1,23 @@
/* Routines to link ECOFF debugging information.
- Copyright 1993, 1994, 1995, 1996, 1997, 2000, 2001, 2002
+ Copyright 1993, 1994, 1995, 1996, 1997, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support, <ian@cygnus.com>.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "bfd.h"
#include "sysdep.h"
@@ -32,24 +32,25 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "libcoff.h"
#include "libecoff.h"
-static boolean ecoff_add_bytes PARAMS ((char **buf, char **bufend,
- size_t need));
+static bfd_boolean ecoff_add_bytes
+ PARAMS ((char **buf, char **bufend, size_t need));
static struct bfd_hash_entry *string_hash_newfunc
PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *,
const char *));
-static void ecoff_align_debug PARAMS ((bfd *abfd,
- struct ecoff_debug_info *debug,
- const struct ecoff_debug_swap *swap));
-static boolean ecoff_write_symhdr PARAMS ((bfd *, struct ecoff_debug_info *,
- const struct ecoff_debug_swap *,
- file_ptr where));
-static int cmp_fdrtab_entry PARAMS ((const PTR, const PTR));
-static boolean mk_fdrtab PARAMS ((bfd *,
- struct ecoff_debug_info * const,
- const struct ecoff_debug_swap * const,
- struct ecoff_find_line *));
-static long fdrtab_lookup PARAMS ((struct ecoff_find_line *, bfd_vma));
-static boolean lookup_line
+static void ecoff_align_debug
+ PARAMS ((bfd *abfd, struct ecoff_debug_info *debug,
+ const struct ecoff_debug_swap *swap));
+static bfd_boolean ecoff_write_symhdr
+ PARAMS ((bfd *, struct ecoff_debug_info *, const struct ecoff_debug_swap *,
+ file_ptr where));
+static int cmp_fdrtab_entry
+ PARAMS ((const PTR, const PTR));
+static bfd_boolean mk_fdrtab
+ PARAMS ((bfd *, struct ecoff_debug_info * const,
+ const struct ecoff_debug_swap * const, struct ecoff_find_line *));
+static long fdrtab_lookup
+ PARAMS ((struct ecoff_find_line *, bfd_vma));
+static bfd_boolean lookup_line
PARAMS ((bfd *, struct ecoff_debug_info * const,
const struct ecoff_debug_swap * const, struct ecoff_find_line *));
@@ -253,7 +254,7 @@ _bfd_ecoff_swap_rndx_out (bigend, intern_copy, ext)
/* Add bytes to a buffer. Return success. */
-static boolean
+static bfd_boolean
ecoff_add_bytes (buf, bufend, need)
char **buf;
char **bufend;
@@ -274,10 +275,10 @@ ecoff_add_bytes (buf, bufend, need)
}
newbuf = (char *) bfd_realloc (*buf, (bfd_size_type) have + want);
if (newbuf == NULL)
- return false;
+ return FALSE;
*buf = newbuf;
*bufend = *buf + have + want;
- return true;
+ return TRUE;
}
/* We keep a hash table which maps strings to numbers. We use it to
@@ -347,7 +348,7 @@ struct shuffle
/* The length of the information. */
unsigned long size;
/* Whether this information comes from a file or not. */
- boolean filep;
+ bfd_boolean filep;
union
{
struct
@@ -400,12 +401,11 @@ struct accumulate
/* Add a file entry to a shuffle list. */
-static boolean add_file_shuffle PARAMS ((struct accumulate *,
- struct shuffle **,
- struct shuffle **, bfd *, file_ptr,
- unsigned long));
+static bfd_boolean add_file_shuffle
+ PARAMS ((struct accumulate *, struct shuffle **, struct shuffle **,
+ bfd *, file_ptr, unsigned long));
-static boolean
+static bfd_boolean
add_file_shuffle (ainfo, head, tail, input_bfd, offset, size)
struct accumulate *ainfo;
struct shuffle **head;
@@ -425,7 +425,7 @@ add_file_shuffle (ainfo, head, tail, input_bfd, offset, size)
(*tail)->size += size;
if ((*tail)->size > ainfo->largest_file_shuffle)
ainfo->largest_file_shuffle = (*tail)->size;
- return true;
+ return TRUE;
}
n = (struct shuffle *) objalloc_alloc (ainfo->memory,
@@ -433,11 +433,11 @@ add_file_shuffle (ainfo, head, tail, input_bfd, offset, size)
if (!n)
{
bfd_set_error (bfd_error_no_memory);
- return false;
+ return FALSE;
}
n->next = NULL;
n->size = size;
- n->filep = true;
+ n->filep = TRUE;
n->u.file.input_bfd = input_bfd;
n->u.file.offset = offset;
if (*head == (struct shuffle *) NULL)
@@ -447,17 +447,16 @@ add_file_shuffle (ainfo, head, tail, input_bfd, offset, size)
*tail = n;
if (size > ainfo->largest_file_shuffle)
ainfo->largest_file_shuffle = size;
- return true;
+ return TRUE;
}
/* Add a memory entry to a shuffle list. */
-static boolean add_memory_shuffle PARAMS ((struct accumulate *,
- struct shuffle **head,
- struct shuffle **tail,
- bfd_byte *data, unsigned long size));
+static bfd_boolean add_memory_shuffle
+ PARAMS ((struct accumulate *, struct shuffle **head, struct shuffle **tail,
+ bfd_byte *data, unsigned long size));
-static boolean
+static bfd_boolean
add_memory_shuffle (ainfo, head, tail, data, size)
struct accumulate *ainfo;
struct shuffle **head;
@@ -472,18 +471,18 @@ add_memory_shuffle (ainfo, head, tail, data, size)
if (!n)
{
bfd_set_error (bfd_error_no_memory);
- return false;
+ return FALSE;
}
n->next = NULL;
n->size = size;
- n->filep = false;
+ n->filep = FALSE;
n->u.memory = (PTR) data;
if (*head == (struct shuffle *) NULL)
*head = n;
if (*tail != (struct shuffle *) NULL)
(*tail)->next = n;
*tail = n;
- return true;
+ return TRUE;
}
/* Initialize the FDR hash table. This returns a handle which is then
@@ -527,7 +526,7 @@ bfd_ecoff_debug_init (output_bfd, output_debug, output_swap, info)
ainfo->largest_file_shuffle = 0;
- if (! info->relocateable)
+ if (! info->relocatable)
{
if (! bfd_hash_table_init (&ainfo->str_hash.table, string_hash_newfunc))
return NULL;
@@ -560,7 +559,7 @@ bfd_ecoff_debug_free (handle, output_bfd, output_debug, output_swap, info)
bfd_hash_table_free (&ainfo->fdr_hash.table);
- if (! info->relocateable)
+ if (! info->relocatable)
bfd_hash_table_free (&ainfo->str_hash.table);
objalloc_free (ainfo->memory);
@@ -576,7 +575,7 @@ bfd_ecoff_debug_free (handle, output_bfd, output_debug, output_swap, info)
linker information structure. HANDLE is returned by
bfd_ecoff_debug_init. */
-boolean
+bfd_boolean
bfd_ecoff_debug_accumulate (handle, output_bfd, output_debug, output_swap,
input_bfd, input_debug, input_swap,
info)
@@ -672,10 +671,10 @@ bfd_ecoff_debug_accumulate (handle, output_bfd, output_debug, output_swap,
if (!input_debug->ifdmap || !rfd_out)
{
bfd_set_error (bfd_error_no_memory);
- return false;
+ return FALSE;
}
if (!add_memory_shuffle (ainfo, &ainfo->rfd, &ainfo->rfd_end, rfd_out, sz))
- return false;
+ return FALSE;
copied = 0;
@@ -716,13 +715,13 @@ bfd_ecoff_debug_accumulate (handle, output_bfd, output_debug, output_swap,
lookup = (char *) bfd_malloc ((bfd_size_type) strlen (name) + 20);
if (lookup == NULL)
- return false;
+ return FALSE;
sprintf (lookup, "%s %lx %lx", name, fdr.csym, fdr.caux);
- fh = string_hash_lookup (&ainfo->fdr_hash, lookup, true, true);
+ fh = string_hash_lookup (&ainfo->fdr_hash, lookup, TRUE, TRUE);
free (lookup);
if (fh == (struct string_hash_entry *) NULL)
- return false;
+ return FALSE;
if (fh->val != -1)
{
@@ -773,10 +772,10 @@ bfd_ecoff_debug_accumulate (handle, output_bfd, output_debug, output_swap,
if (!fdr_out)
{
bfd_set_error (bfd_error_no_memory);
- return false;
+ return FALSE;
}
if (!add_memory_shuffle (ainfo, &ainfo->fdr, &ainfo->fdr_end, fdr_out, sz))
- return false;
+ return FALSE;
for (fdr_ptr = fdr_start, i = 0;
fdr_ptr < fdr_end;
fdr_ptr += fdr_add, i++)
@@ -786,7 +785,7 @@ bfd_ecoff_debug_accumulate (handle, output_bfd, output_debug, output_swap,
bfd_byte *sym_out;
bfd_byte *lraw_src;
bfd_byte *lraw_end;
- boolean fgotfilename;
+ bfd_boolean fgotfilename;
if (input_debug->ifdmap[i] < output_symhdr->ifdMax)
{
@@ -822,17 +821,17 @@ bfd_ecoff_debug_accumulate (handle, output_bfd, output_debug, output_swap,
/* Swap in the local symbols, adjust their values, and swap them
out again. */
- fgotfilename = false;
+ fgotfilename = FALSE;
sz = fdr.csym * external_sym_size;
sym_out = (bfd_byte *) objalloc_alloc (ainfo->memory, sz);
if (!sym_out)
{
bfd_set_error (bfd_error_no_memory);
- return false;
+ return FALSE;
}
if (!add_memory_shuffle (ainfo, &ainfo->sym, &ainfo->sym_end, sym_out,
sz))
- return false;
+ return FALSE;
lraw_src = ((bfd_byte *) input_debug->external_sym
+ fdr.isymBase * input_swap->external_sym_size);
lraw_end = lraw_src + fdr.csym * input_swap->external_sym_size;
@@ -880,17 +879,17 @@ bfd_ecoff_debug_accumulate (handle, output_bfd, output_debug, output_swap,
/* If we are doing a final link, we hash all the strings in
the local symbol table together. This reduces the amount
of space required by debugging information. We don't do
- this when performing a relocateable link because it would
+ this when performing a relocatable link because it would
prevent us from easily merging different FDR's. */
- if (! info->relocateable)
+ if (! info->relocatable)
{
- boolean ffilename;
+ bfd_boolean ffilename;
const char *name;
if (! fgotfilename && internal_sym.iss == fdr.rss)
- ffilename = true;
+ ffilename = TRUE;
else
- ffilename = false;
+ ffilename = FALSE;
/* Hash the name into the string table. */
name = input_debug->ss + fdr.issBase + internal_sym.iss;
@@ -900,9 +899,9 @@ bfd_ecoff_debug_accumulate (handle, output_bfd, output_debug, output_swap,
{
struct string_hash_entry *sh;
- sh = string_hash_lookup (&ainfo->str_hash, name, true, true);
+ sh = string_hash_lookup (&ainfo->str_hash, name, TRUE, TRUE);
if (sh == (struct string_hash_entry *) NULL)
- return false;
+ return FALSE;
if (sh->val == -1)
{
sh->val = output_symhdr->issMax;
@@ -920,7 +919,7 @@ bfd_ecoff_debug_accumulate (handle, output_bfd, output_debug, output_swap,
if (ffilename)
{
fdr.rss = internal_sym.iss;
- fgotfilename = true;
+ fgotfilename = TRUE;
}
}
@@ -942,7 +941,7 @@ bfd_ecoff_debug_accumulate (handle, output_bfd, output_debug, output_swap,
file_ptr pos = input_symhdr->cbLineOffset + fdr.cbLineOffset;
if (!add_file_shuffle (ainfo, &ainfo->line, &ainfo->line_end,
input_bfd, pos, (unsigned long) fdr.cbLine))
- return false;
+ return FALSE;
fdr.ilineBase = output_symhdr->ilineMax;
fdr.cbLineOffset = output_symhdr->cbLine;
output_symhdr->ilineMax += fdr.cline;
@@ -955,11 +954,11 @@ bfd_ecoff_debug_accumulate (handle, output_bfd, output_debug, output_swap,
if (!add_file_shuffle (ainfo, &ainfo->aux, &ainfo->aux_end,
input_bfd, pos,
fdr.caux * sizeof (union aux_ext)))
- return false;
+ return FALSE;
fdr.iauxBase = output_symhdr->iauxMax;
output_symhdr->iauxMax += fdr.caux;
}
- if (! info->relocateable)
+ if (! info->relocatable)
{
/* When are are hashing strings, we lie about the number of
@@ -974,7 +973,7 @@ bfd_ecoff_debug_accumulate (handle, output_bfd, output_debug, output_swap,
file_ptr pos = input_symhdr->cbSsOffset + fdr.issBase;
if (!add_file_shuffle (ainfo, &ainfo->ss, &ainfo->ss_end,
input_bfd, pos, (unsigned long) fdr.cbSs))
- return false;
+ return FALSE;
fdr.issBase = output_symhdr->issMax;
output_symhdr->issMax += fdr.cbSs;
}
@@ -994,7 +993,7 @@ bfd_ecoff_debug_accumulate (handle, output_bfd, output_debug, output_swap,
unsigned long size = fdr.cpd * external_pdr_size;
if (!add_file_shuffle (ainfo, &ainfo->pdr, &ainfo->pdr_end,
input_bfd, pos, size))
- return false;
+ return FALSE;
}
BFD_ASSERT (external_opt_size == input_swap->external_opt_size);
if (fdr.copt > 0)
@@ -1004,7 +1003,7 @@ bfd_ecoff_debug_accumulate (handle, output_bfd, output_debug, output_swap,
unsigned long size = fdr.copt * external_opt_size;
if (!add_file_shuffle (ainfo, &ainfo->opt, &ainfo->opt_end,
input_bfd, pos, size))
- return false;
+ return FALSE;
}
}
else
@@ -1027,11 +1026,11 @@ bfd_ecoff_debug_accumulate (handle, output_bfd, output_debug, output_swap,
if (!out)
{
bfd_set_error (bfd_error_no_memory);
- return false;
+ return FALSE;
}
if (!add_memory_shuffle (ainfo, &ainfo->pdr, &ainfo->pdr_end, out,
sz))
- return false;
+ return FALSE;
for (; in < end; in += insz, out += outsz)
{
PDR pdr;
@@ -1068,11 +1067,11 @@ bfd_ecoff_debug_accumulate (handle, output_bfd, output_debug, output_swap,
if (!out)
{
bfd_set_error (bfd_error_no_memory);
- return false;
+ return FALSE;
}
if (!add_memory_shuffle (ainfo, &ainfo->opt, &ainfo->opt_end, out,
sz))
- return false;
+ return FALSE;
for (; in < end; in += insz, out += outsz)
{
OPTR opt;
@@ -1104,16 +1103,15 @@ bfd_ecoff_debug_accumulate (handle, output_bfd, output_debug, output_swap,
++output_symhdr->ifdMax;
}
- return true;
+ return TRUE;
}
/* Add a string to the debugging information we are accumulating.
Return the offset from the fdr string base. */
-static long ecoff_add_string PARAMS ((struct accumulate *,
- struct bfd_link_info *,
- struct ecoff_debug_info *,
- FDR *fdr, const char *string));
+static long ecoff_add_string
+ PARAMS ((struct accumulate *, struct bfd_link_info *,
+ struct ecoff_debug_info *, FDR *fdr, const char *string));
static long
ecoff_add_string (ainfo, info, debug, fdr, string)
@@ -1129,7 +1127,7 @@ ecoff_add_string (ainfo, info, debug, fdr, string)
symhdr = &debug->symbolic_header;
len = strlen (string);
- if (info->relocateable)
+ if (info->relocatable)
{
if (!add_memory_shuffle (ainfo, &ainfo->ss, &ainfo->ss_end, (PTR) string,
len + 1))
@@ -1142,7 +1140,7 @@ ecoff_add_string (ainfo, info, debug, fdr, string)
{
struct string_hash_entry *sh;
- sh = string_hash_lookup (&ainfo->str_hash, string, true, true);
+ sh = string_hash_lookup (&ainfo->str_hash, string, TRUE, TRUE);
if (sh == (struct string_hash_entry *) NULL)
return -1;
if (sh->val == -1)
@@ -1164,7 +1162,7 @@ ecoff_add_string (ainfo, info, debug, fdr, string)
/* Add debugging information from a non-ECOFF file. */
-boolean
+bfd_boolean
bfd_ecoff_debug_accumulate_other (handle, output_bfd, output_debug,
output_swap, input_bfd, info)
PTR handle;
@@ -1203,19 +1201,19 @@ bfd_ecoff_debug_accumulate_other (handle, output_bfd, output_debug,
fdr.rss = ecoff_add_string (ainfo, info, output_debug, &fdr,
bfd_archive_filename (input_bfd));
if (fdr.rss == -1)
- return false;
+ return FALSE;
fdr.isymBase = output_symhdr->isymMax;
/* Get the local symbols from the input BFD. */
symsize = bfd_get_symtab_upper_bound (input_bfd);
if (symsize < 0)
- return false;
+ return FALSE;
symbols = (asymbol **) bfd_alloc (output_bfd, (bfd_size_type) symsize);
if (symbols == (asymbol **) NULL)
- return false;
+ return FALSE;
symcount = bfd_canonicalize_symtab (input_bfd, symbols);
if (symcount < 0)
- return false;
+ return FALSE;
sym_end = symbols + symcount;
/* Handle the local symbols. Any external symbols are handled
@@ -1233,7 +1231,7 @@ bfd_ecoff_debug_accumulate_other (handle, output_bfd, output_debug,
(*sym_ptr)->name);
if (internal_sym.iss == -1)
- return false;
+ return FALSE;
if (bfd_is_com_section ((*sym_ptr)->section)
|| bfd_is_und_section ((*sym_ptr)->section))
internal_sym.value = (*sym_ptr)->value;
@@ -1250,7 +1248,7 @@ bfd_ecoff_debug_accumulate_other (handle, output_bfd, output_debug,
if (!external_sym)
{
bfd_set_error (bfd_error_no_memory);
- return false;
+ return FALSE;
}
(*swap_sym_out) (output_bfd, &internal_sym, external_sym);
add_memory_shuffle (ainfo, &ainfo->sym, &ainfo->sym_end,
@@ -1271,7 +1269,7 @@ bfd_ecoff_debug_accumulate_other (handle, output_bfd, output_debug,
if (!external_fdr)
{
bfd_set_error (bfd_error_no_memory);
- return false;
+ return FALSE;
}
(*output_swap->swap_fdr_out) (output_bfd, &fdr, external_fdr);
add_memory_shuffle (ainfo, &ainfo->fdr, &ainfo->fdr_end,
@@ -1280,7 +1278,7 @@ bfd_ecoff_debug_accumulate_other (handle, output_bfd, output_debug,
++output_symhdr->ifdMax;
- return true;
+ return TRUE;
}
/* Set up ECOFF debugging information for the external symbols.
@@ -1288,14 +1286,14 @@ bfd_ecoff_debug_accumulate_other (handle, output_bfd, output_debug,
probably be changed to use a shuffle structure. The assembler uses
this interface, so that must be changed to do something else. */
-boolean
-bfd_ecoff_debug_externals (abfd, debug, swap, relocateable, get_extr,
+bfd_boolean
+bfd_ecoff_debug_externals (abfd, debug, swap, relocatable, get_extr,
set_index)
bfd *abfd;
struct ecoff_debug_info *debug;
const struct ecoff_debug_swap *swap;
- boolean relocateable;
- boolean (*get_extr) PARAMS ((asymbol *, EXTR *));
+ bfd_boolean relocatable;
+ bfd_boolean (*get_extr) PARAMS ((asymbol *, EXTR *));
void (*set_index) PARAMS ((asymbol *, bfd_size_type));
{
HDRR * const symhdr = &debug->symbolic_header;
@@ -1304,7 +1302,7 @@ bfd_ecoff_debug_externals (abfd, debug, swap, relocateable, get_extr,
sym_ptr_ptr = bfd_get_outsymbols (abfd);
if (sym_ptr_ptr == NULL)
- return true;
+ return TRUE;
for (c = bfd_get_symcount (abfd); c > 0; c--, sym_ptr_ptr++)
{
@@ -1319,7 +1317,7 @@ bfd_ecoff_debug_externals (abfd, debug, swap, relocateable, get_extr,
/* If we're producing an executable, move common symbols into
bss. */
- if (! relocateable)
+ if (! relocatable)
{
if (esym.asym.sc == scCommon)
esym.asym.sc = scBss;
@@ -1349,15 +1347,15 @@ bfd_ecoff_debug_externals (abfd, debug, swap, relocateable, get_extr,
if (! bfd_ecoff_debug_one_external (abfd, debug, swap,
sym_ptr->name, &esym))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Add a single external symbol to the debugging information. */
-boolean
+bfd_boolean
bfd_ecoff_debug_one_external (abfd, debug, swap, name, esym)
bfd *abfd;
struct ecoff_debug_info *debug;
@@ -1379,7 +1377,7 @@ bfd_ecoff_debug_one_external (abfd, debug, swap, name, esym)
if (! ecoff_add_bytes ((char **) &debug->ssext,
(char **) &debug->ssext_end,
symhdr->issExtMax + namelen + 1))
- return false;
+ return FALSE;
}
if ((size_t) ((char *) debug->external_ext_end
- (char *) debug->external_ext)
@@ -1388,7 +1386,7 @@ bfd_ecoff_debug_one_external (abfd, debug, swap, name, esym)
if (! ecoff_add_bytes ((char **) &debug->external_ext,
(char **) &debug->external_ext_end,
(symhdr->iextMax + 1) * (size_t) external_ext_size))
- return false;
+ return FALSE;
}
esym->asym.iss = symhdr->issExtMax;
@@ -1402,7 +1400,7 @@ bfd_ecoff_debug_one_external (abfd, debug, swap, name, esym)
strcpy (debug->ssext + symhdr->issExtMax, name);
symhdr->issExtMax += namelen + 1;
- return true;
+ return TRUE;
}
/* Align the ECOFF debugging information. */
@@ -1503,7 +1501,7 @@ bfd_ecoff_debug_size (abfd, debug, swap)
going to be placed at. This assumes that the counts are set
correctly. */
-static boolean
+static bfd_boolean
ecoff_write_symhdr (abfd, debug, swap, where)
bfd *abfd;
struct ecoff_debug_info *debug;
@@ -1517,7 +1515,7 @@ ecoff_write_symhdr (abfd, debug, swap, where)
/* Go to the right location in the file. */
if (bfd_seek (abfd, where, SEEK_SET) != 0)
- return false;
+ return FALSE;
where += swap->external_hdr_size;
@@ -1557,11 +1555,11 @@ ecoff_write_symhdr (abfd, debug, swap, where)
if (buff != NULL)
free (buff);
- return true;
+ return TRUE;
error_return:
if (buff != NULL)
free (buff);
- return false;
+ return FALSE;
}
/* Write out the ECOFF debugging information. This function assumes
@@ -1570,7 +1568,7 @@ ecoff_write_symhdr (abfd, debug, swap, where)
information to. This function fills in the file offsets in the
symbolic header. */
-boolean
+bfd_boolean
bfd_ecoff_write_debug (abfd, debug, swap, where)
bfd *abfd;
struct ecoff_debug_info *debug;
@@ -1580,14 +1578,14 @@ bfd_ecoff_write_debug (abfd, debug, swap, where)
HDRR * const symhdr = &debug->symbolic_header;
if (! ecoff_write_symhdr (abfd, debug, swap, where))
- return false;
+ return FALSE;
#define WRITE(ptr, count, size, offset) \
BFD_ASSERT (symhdr->offset == 0 \
|| (bfd_vma) bfd_tell (abfd) == symhdr->offset); \
if (bfd_bwrite ((PTR) debug->ptr, (bfd_size_type) size * symhdr->count, abfd)\
!= size * symhdr->count) \
- return false;
+ return FALSE;
WRITE (line, cbLine, sizeof (unsigned char), cbLineOffset);
WRITE (external_dnr, idnMax, swap->external_dnr_size, cbDnOffset);
@@ -1603,16 +1601,16 @@ bfd_ecoff_write_debug (abfd, debug, swap, where)
WRITE (external_ext, iextMax, swap->external_ext_size, cbExtOffset);
#undef WRITE
- return true;
+ return TRUE;
}
/* Write out a shuffle list. */
-static boolean ecoff_write_shuffle PARAMS ((bfd *,
- const struct ecoff_debug_swap *,
- struct shuffle *, PTR space));
+static bfd_boolean ecoff_write_shuffle
+ PARAMS ((bfd *, const struct ecoff_debug_swap *, struct shuffle *,
+ PTR space));
-static boolean
+static bfd_boolean
ecoff_write_shuffle (abfd, swap, shuffle, space)
bfd *abfd;
const struct ecoff_debug_swap *swap;
@@ -1629,7 +1627,7 @@ ecoff_write_shuffle (abfd, swap, shuffle, space)
{
if (bfd_bwrite (l->u.memory, (bfd_size_type) l->size, abfd)
!= l->size)
- return false;
+ return FALSE;
}
else
{
@@ -1637,7 +1635,7 @@ ecoff_write_shuffle (abfd, swap, shuffle, space)
|| bfd_bread (space, (bfd_size_type) l->size,
l->u.file.input_bfd) != l->size
|| bfd_bwrite (space, (bfd_size_type) l->size, abfd) != l->size)
- return false;
+ return FALSE;
}
total += l->size;
}
@@ -1650,23 +1648,23 @@ ecoff_write_shuffle (abfd, swap, shuffle, space)
i = swap->debug_align - (total & (swap->debug_align - 1));
s = (bfd_byte *) bfd_zmalloc ((bfd_size_type) i);
if (s == NULL && i != 0)
- return false;
+ return FALSE;
if (bfd_bwrite ((PTR) s, (bfd_size_type) i, abfd) != i)
{
free (s);
- return false;
+ return FALSE;
}
free (s);
}
- return true;
+ return TRUE;
}
/* Write out debugging information using accumulated linker
information. */
-boolean
+bfd_boolean
bfd_ecoff_write_accumulated_debug (handle, abfd, debug, swap, info, where)
PTR handle;
bfd *abfd;
@@ -1696,7 +1694,7 @@ bfd_ecoff_write_accumulated_debug (handle, abfd, debug, swap, info, where)
/* The string table is written out from the hash table if this is a
final link. */
- if (info->relocateable)
+ if (info->relocatable)
{
BFD_ASSERT (ainfo->ss_hash == (struct string_hash_entry *) NULL);
if (! ecoff_write_shuffle (abfd, swap, ainfo->ss, space))
@@ -1784,12 +1782,12 @@ bfd_ecoff_write_accumulated_debug (handle, abfd, debug, swap, info, where)
if (space != NULL)
free (space);
- return true;
+ return TRUE;
error_return:
if (space != NULL)
free (space);
- return false;
+ return FALSE;
}
/* Handle the find_nearest_line function for both ECOFF and MIPS ELF
@@ -1820,7 +1818,7 @@ cmp_fdrtab_entry (leftp, rightp)
table will be sorted by address so we can look it up via binary
search. */
-static boolean
+static bfd_boolean
mk_fdrtab (abfd, debug_info, debug_swap, line_info)
bfd *abfd;
struct ecoff_debug_info * const debug_info;
@@ -1831,27 +1829,26 @@ mk_fdrtab (abfd, debug_info, debug_swap, line_info)
FDR *fdr_ptr;
FDR *fdr_start;
FDR *fdr_end;
- boolean stabs;
+ bfd_boolean stabs;
long len;
bfd_size_type amt;
fdr_start = debug_info->fdr;
fdr_end = fdr_start + debug_info->symbolic_header.ifdMax;
- /* First, let's see how long the table needs to be: */
+ /* First, let's see how long the table needs to be. */
for (len = 0, fdr_ptr = fdr_start; fdr_ptr < fdr_end; fdr_ptr++)
{
- if (fdr_ptr->cpd == 0) /* skip FDRs that have no PDRs */
+ if (fdr_ptr->cpd == 0) /* Skip FDRs that have no PDRs. */
continue;
++len;
}
- /* Now, create and fill in the table: */
-
+ /* Now, create and fill in the table. */
amt = (bfd_size_type) len * sizeof (struct ecoff_fdrtab_entry);
line_info->fdrtab = (struct ecoff_fdrtab_entry*) bfd_zalloc (abfd, amt);
if (line_info->fdrtab == NULL)
- return false;
+ return FALSE;
line_info->fdrtab_len = len;
tab = line_info->fdrtab;
@@ -1863,39 +1860,53 @@ mk_fdrtab (abfd, debug_info, debug_swap, line_info)
/* Check whether this file has stabs debugging information. In
a file with stabs debugging information, the second local
symbol is named @stabs. */
- stabs = false;
+ stabs = FALSE;
if (fdr_ptr->csym >= 2)
{
char *sym_ptr;
SYMR sym;
sym_ptr = ((char *) debug_info->external_sym
- + (fdr_ptr->isymBase + 1)*debug_swap->external_sym_size);
+ + (fdr_ptr->isymBase + 1) * debug_swap->external_sym_size);
(*debug_swap->swap_sym_in) (abfd, sym_ptr, &sym);
if (strcmp (debug_info->ss + fdr_ptr->issBase + sym.iss,
STABS_SYMBOL) == 0)
- stabs = true;
+ stabs = TRUE;
}
if (!stabs)
{
- bfd_size_type external_pdr_size;
- char *pdr_ptr;
- PDR pdr;
-
- external_pdr_size = debug_swap->external_pdr_size;
-
- pdr_ptr = ((char *) debug_info->external_pdr
- + fdr_ptr->ipdFirst * external_pdr_size);
- (*debug_swap->swap_pdr_in) (abfd, (PTR) pdr_ptr, &pdr);
+ /* eraxxon: There are at least two problems with this computation:
+ 1) PDRs do *not* contain offsets but full vma's; and typically the
+ address of the first PDR is the address of the FDR, which will
+ make (most) of the results of the original computation 0!
+ 2) Once in a wacky while, the Compaq compiler generated PDR
+ addresses do not equal the FDR vma, but they (the PDR address)
+ are still vma's and not offsets. Cf. comments in
+ 'lookup_line'. */
+#if 0
+ bfd_size_type external_pdr_size;
+ char *pdr_ptr;
+ PDR pdr;
+
+ external_pdr_size = debug_swap->external_pdr_size;
+
+ pdr_ptr = ((char *) debug_info->external_pdr
+ + fdr_ptr->ipdFirst * external_pdr_size);
+ (*debug_swap->swap_pdr_in) (abfd, (PTR) pdr_ptr, &pdr);
+ /* The address of the first PDR is the offset of that
+ procedure relative to the beginning of file FDR. */
+ tab->base_addr = fdr_ptr->adr - pdr.adr;
+#else
/* The address of the first PDR is the offset of that
procedure relative to the beginning of file FDR. */
- tab->base_addr = fdr_ptr->adr - pdr.adr;
+ tab->base_addr = fdr_ptr->adr;
+#endif
}
else
{
/* XXX I don't know about stabs, so this is a guess
- (davidm@cs.arizona.edu): */
+ (davidm@cs.arizona.edu). */
tab->base_addr = fdr_ptr->adr;
}
tab->fdr = fdr_ptr;
@@ -1909,7 +1920,7 @@ mk_fdrtab (abfd, debug_info, debug_swap, line_info)
qsort ((PTR) line_info->fdrtab, (size_t) len,
sizeof (struct ecoff_fdrtab_entry), cmp_fdrtab_entry);
- return true;
+ return TRUE;
}
/* Return index of first FDR that covers to OFFSET. */
@@ -1939,14 +1950,22 @@ fdrtab_lookup (line_info, offset)
else
low = mid + 1;
}
+
+ /* eraxxon: at this point 'offset' is either lower than the lowest entry or
+ higher than the highest entry. In the former case high = low = mid = 0;
+ we want to return -1. In the latter case, low = high and mid = low - 1;
+ we want to return the index of the highest entry. Only in former case
+ will the following 'catch-all' test be true. */
++mid;
- /* last entry is catch-all for all higher addresses: */
+ /* Last entry is catch-all for all higher addresses. */
if (offset < tab[mid].base_addr)
return -1;
find_min:
+ /* eraxxon: There may be multiple FDRs in the table with the
+ same base_addr; make sure that we are at the first one. */
while (mid > 0 && tab[mid - 1].base_addr == tab[mid].base_addr)
--mid;
@@ -1956,7 +1975,7 @@ fdrtab_lookup (line_info, offset)
/* Look up a line given an address, storing the information in
LINE_INFO->cache. */
-static boolean
+static bfd_boolean
lookup_line (abfd, debug_info, debug_swap, line_info)
bfd *abfd;
struct ecoff_debug_info * const debug_info;
@@ -1965,30 +1984,101 @@ lookup_line (abfd, debug_info, debug_swap, line_info)
{
struct ecoff_fdrtab_entry *tab;
bfd_vma offset;
- boolean stabs;
+ bfd_boolean stabs;
FDR *fdr_ptr;
int i;
+ /* eraxxon: note that 'offset' is the full vma, not a section offset. */
offset = line_info->cache.start;
/* Build FDR table (sorted by object file's base-address) if we
don't have it already. */
if (line_info->fdrtab == NULL
&& !mk_fdrtab (abfd, debug_info, debug_swap, line_info))
- return false;
+ return FALSE;
tab = line_info->fdrtab;
- /* find first FDR for address OFFSET */
+ /* Find first FDR for address OFFSET. */
i = fdrtab_lookup (line_info, offset);
if (i < 0)
- return false; /* no FDR, no fun... */
+ return FALSE; /* no FDR, no fun... */
+
+ /* eraxxon: 'fdrtab_lookup' doesn't give what we want, at least for Compaq's
+ C++ compiler 6.2. Consider three FDRs with starting addresses of x, y,
+ and z, respectively, such that x < y < z. Assume further that
+ y < 'offset' < z. It is possible at times that the PDR for 'offset' is
+ associated with FDR x and *not* with FDR y. Erg!!
+
+ From a binary dump of my C++ test case 'moo' using Compaq's coffobjanl
+ (output format has been edited for our purposes):
+
+ FDR [2]: (main.C): First instruction: 0x12000207c <x>
+ PDR [5] for File [2]: LoopTest__Xv <0x1200020a0> (a)
+ PDR [7] for File [2]: foo__Xv <0x120002168>
+ FDR [1]: (-1): First instruction: 0x1200020e8 <y>
+ PDR [3] for File [1]: <0x120001ad0> (b)
+ FDR [6]: (-1): First instruction: 0x1200026f0 <z>
+
+ (a) In the case of PDR5, the vma is such that the first few instructions
+ of the procedure can be found. But since the size of this procedure is
+ 160b, the vma will soon cross into the 'address space' of FDR1 and no
+ debugging info will be found. How repugnant!
+
+ (b) It is also possible for a PDR to have a *lower* vma than its associated
+ FDR; see FDR1 and PDR3. Gross!
+
+ Since the FDRs that are causing so much havok (in this case) 1) do not
+ describe actual files (fdr.rss == -1), and 2) contain only compiler
+ generated routines, I thought a simple fix would be to exclude them from
+ the FDR table in 'mk_fdrtab'. But, besides not knowing for certain
+ whether this would be correct, it creates an additional problem. If we
+ happen to ask for source file info on a compiler generated (procedure)
+ symbol -- which is still in the symbol table -- the result can be
+ information from a real procedure! This is because compiler generated
+ procedures with vma's higher than the last FDR in the fdr table will be
+ associated with a PDR from this FDR, specifically the PDR with the
+ highest vma. This wasn't a problem before, because each procedure had a
+ PDR. (Yes, this problem could be eliminated if we kept the size of the
+ last PDR around, but things are already getting ugly).
+
+ Probably, a better solution would be to have a sorted PDR table. Each
+ PDR would have a pointer to its FDR so file information could still be
+ obtained. A FDR table could still be constructed if necessary -- since
+ it only contains pointers, not much extra memory would be used -- but
+ the PDR table would be searched to locate debugging info.
+
+ There is still at least one remaining issue. Sometimes a FDR can have a
+ bogus name, but contain PDRs that should belong to another FDR with a
+ real name. E.g:
+
+ FDR [3]: 0000000120001b50 (/home/.../Array.H~alt~deccxx_5E5A62AD)
+ PDR [a] for File [3]: 0000000120001b50
+ PDR [b] for File [3]: 0000000120001cf0
+ PDR [c] for File [3]: 0000000120001dc8
+ PDR [d] for File [3]: 0000000120001e40
+ PDR [e] for File [3]: 0000000120001eb8
+ PDR [f] for File [3]: 0000000120001f4c
+ FDR [4]: 0000000120001b50 (/home/.../Array.H)
+
+ Here, FDR4 has the correct name, but should (seemingly) contain PDRa-f.
+ The symbol table for PDR4 does contain symbols for PDRa-f, but so does
+ the symbol table for FDR3. However the former is different; perhaps this
+ can be detected easily. (I'm not sure at this point.) This problem only
+ seems to be associated with files with templates. I am assuming the idea
+ is that there is a 'fake' FDR (with PDRs) for each differently typed set
+ of templates that must be generated. Currently, FDR4 is completely
+ excluded from the FDR table in 'mk_fdrtab' because it contains no PDRs.
+
+ Since I don't have time to prepare a real fix for this right now, be
+ prepared for 'A Horrible Hack' to force the inspection of all non-stabs
+ FDRs. It's coming... */
fdr_ptr = tab[i].fdr;
/* Check whether this file has stabs debugging information. In a
file with stabs debugging information, the second local symbol is
named @stabs. */
- stabs = false;
+ stabs = FALSE;
if (fdr_ptr->csym >= 2)
{
char *sym_ptr;
@@ -1999,7 +2089,7 @@ lookup_line (abfd, debug_info, debug_swap, line_info)
(*debug_swap->swap_sym_in) (abfd, sym_ptr, &sym);
if (strcmp (debug_info->ss + fdr_ptr->issBase + sym.iss,
STABS_SYMBOL) == 0)
- stabs = true;
+ stabs = TRUE;
}
if (!stabs)
@@ -2008,7 +2098,7 @@ lookup_line (abfd, debug_info, debug_swap, line_info)
char *pdr_ptr;
char *best_pdr = NULL;
FDR *best_fdr;
- bfd_vma best_dist = ~(bfd_vma) 0;
+ bfd_signed_vma best_dist = -1;
PDR pdr;
unsigned char *line_ptr;
unsigned char *line_end;
@@ -2070,14 +2160,29 @@ lookup_line (abfd, debug_info, debug_swap, line_info)
considerably, which is undesirable. */
external_pdr_size = debug_swap->external_pdr_size;
- /* Make offset relative to object file's start-address: */
+#if 0 /* eraxxon: PDR addresses (pdr.adr) are not relative to FDRs!
+ Leave 'offset' alone. */
+ /* Make offset relative to object file's start-address. */
offset -= tab[i].base_addr;
+#endif
+ /* eraxxon: The Horrible Hack: Because of the problems above, set 'i'
+ to 0 so we look through all FDRs.
+
+ Because FDR's without any symbols are assumed to be non-stabs,
+ searching through all FDRs may cause the following code to try to
+ read stabs FDRs as ECOFF ones. However, I don't think this will
+ harm anything. */
+ i = 0;
+
/* Search FDR list starting at tab[i] for the PDR that best matches
OFFSET. Normally, the FDR list is only one entry long. */
best_fdr = NULL;
do
{
- bfd_vma dist, min_dist = 0;
+ /* eraxxon: 'dist' and 'min_dist' can be negative now
+ because we iterate over every FDR rather than just ones
+ with a base address less than or equal to 'offset'. */
+ bfd_signed_vma dist = -1, min_dist = -1;
char *pdr_hold;
char *pdr_end;
@@ -2100,7 +2205,10 @@ lookup_line (abfd, debug_info, debug_swap, line_info)
if (offset >= (pdr.adr - 0x10 * pdr.prof))
{
dist = offset - (pdr.adr - 0x10 * pdr.prof);
- if (!pdr_hold || dist < min_dist)
+
+ /* eraxxon: 'dist' can be negative now. Note that
+ 'min_dist' can be negative if 'pdr_hold' below is NULL. */
+ if (!pdr_hold || (dist >= 0 && dist < min_dist))
{
min_dist = dist;
pdr_hold = pdr_ptr;
@@ -2108,21 +2216,22 @@ lookup_line (abfd, debug_info, debug_swap, line_info)
}
}
- if (!best_pdr || min_dist < best_dist)
+ if (!best_pdr || (min_dist >= 0 && min_dist < best_dist))
{
- best_dist = min_dist;
+ best_dist = (bfd_vma) min_dist;
best_fdr = fdr_ptr;
best_pdr = pdr_hold;
}
- /* continue looping until base_addr of next entry is different: */
+ /* Continue looping until base_addr of next entry is different. */
}
- while (++i < line_info->fdrtab_len
- && tab[i].base_addr == tab[i - 1].base_addr);
+ /* eraxxon: We want to iterate over all FDRs.
+ See previous comment about 'fdrtab_lookup'. */
+ while (++i < line_info->fdrtab_len);
if (!best_fdr || !best_pdr)
- return false; /* shouldn't happen... */
+ return FALSE; /* Shouldn't happen... */
- /* phew, finally we got something that we can hold onto: */
+ /* Phew, finally we got something that we can hold onto. */
fdr_ptr = best_fdr;
pdr_ptr = best_pdr;
(*debug_swap->swap_pdr_in) (abfd, (PTR) pdr_ptr, &pdr);
@@ -2132,7 +2241,7 @@ lookup_line (abfd, debug_info, debug_swap, line_info)
number entries. */
line_end = debug_info->line + fdr_ptr->cbLineOffset + fdr_ptr->cbLine;
- /* Make offset relative to procedure entry: */
+ /* Make offset relative to procedure entry. */
offset -= pdr.adr - 0x10 * pdr.prof;
lineno = pdr.lnLow;
line_ptr = debug_info->line + fdr_ptr->cbLineOffset + pdr.cbLineOffset;
@@ -2213,8 +2322,8 @@ lookup_line (abfd, debug_info, debug_swap, line_info)
const char *line_file_name;
bfd_vma low_func_vma;
bfd_vma low_line_vma;
- boolean past_line;
- boolean past_fn;
+ bfd_boolean past_line;
+ bfd_boolean past_fn;
char *sym_ptr, *sym_ptr_end;
size_t len, funclen;
char *buffer = NULL;
@@ -2240,8 +2349,8 @@ lookup_line (abfd, debug_info, debug_swap, line_info)
line_file_name = NULL;
low_func_vma = 0;
low_line_vma = 0;
- past_line = false;
- past_fn = false;
+ past_line = FALSE;
+ past_fn = FALSE;
external_sym_size = debug_swap->external_sym_size;
@@ -2291,7 +2400,7 @@ lookup_line (abfd, debug_info, debug_swap, line_info)
case N_FUN:
if (sym.value > offset)
- past_fn = true;
+ past_fn = TRUE;
else if (sym.value >= low_func_vma)
{
low_func_vma = sym.value;
@@ -2304,7 +2413,7 @@ lookup_line (abfd, debug_info, debug_swap, line_info)
else if (sym.st == stLabel && sym.index != indexNil)
{
if (sym.value > offset)
- past_line = true;
+ past_line = TRUE;
else if (sym.value >= low_line_vma)
{
low_line_vma = sym.value;
@@ -2336,7 +2445,7 @@ lookup_line (abfd, debug_info, debug_swap, line_info)
free (line_info->find_buffer);
buffer = (char *) bfd_malloc ((bfd_size_type) len);
if (buffer == NULL)
- return false;
+ return FALSE;
line_info->find_buffer = buffer;
}
@@ -2364,12 +2473,12 @@ lookup_line (abfd, debug_info, debug_swap, line_info)
}
}
- return true;
+ return TRUE;
}
/* Do the work of find_nearest_line. */
-boolean
+bfd_boolean
_bfd_ecoff_locate_line (abfd, section, offset, debug_info, debug_swap,
line_info, filename_ptr, functionname_ptr, retline_ptr)
bfd *abfd;
@@ -2395,7 +2504,7 @@ _bfd_ecoff_locate_line (abfd, section, offset, debug_info, debug_swap,
if (! lookup_line (abfd, debug_info, debug_swap, line_info))
{
line_info->cache.sect = NULL;
- return false;
+ return FALSE;
}
}
@@ -2403,7 +2512,7 @@ _bfd_ecoff_locate_line (abfd, section, offset, debug_info, debug_swap,
*functionname_ptr = line_info->cache.functionname;
*retline_ptr = line_info->cache.line_num;
- return true;
+ return TRUE;
}
/* These routines copy symbolic information into a memory buffer.
@@ -2416,9 +2525,10 @@ _bfd_ecoff_locate_line (abfd, section, offset, debug_info, debug_swap,
/* Collect a shuffle into a memory buffer. */
-static boolean ecoff_collect_shuffle PARAMS ((struct shuffle *, bfd_byte *));
+static bfd_boolean ecoff_collect_shuffle
+ PARAMS ((struct shuffle *, bfd_byte *));
-static boolean
+static bfd_boolean
ecoff_collect_shuffle (l, buff)
struct shuffle *l;
bfd_byte *buff;
@@ -2435,18 +2545,18 @@ ecoff_collect_shuffle (l, buff)
if (bfd_seek (l->u.file.input_bfd, l->u.file.offset, SEEK_SET) != 0
|| (bfd_bread (buff, (bfd_size_type) l->size, l->u.file.input_bfd)
!= l->size))
- return false;
+ return FALSE;
}
total += l->size;
buff += l->size;
}
- return true;
+ return TRUE;
}
/* Copy PDR information into a memory buffer. */
-boolean
+bfd_boolean
_bfd_ecoff_get_accumulated_pdr (handle, buff)
PTR handle;
bfd_byte *buff;
@@ -2458,7 +2568,7 @@ _bfd_ecoff_get_accumulated_pdr (handle, buff)
/* Copy symbol information into a memory buffer. */
-boolean
+bfd_boolean
_bfd_ecoff_get_accumulated_sym (handle, buff)
PTR handle;
bfd_byte *buff;
@@ -2470,7 +2580,7 @@ _bfd_ecoff_get_accumulated_sym (handle, buff)
/* Copy the string table into a memory buffer. */
-boolean
+bfd_boolean
_bfd_ecoff_get_accumulated_ss (handle, buff)
PTR handle;
bfd_byte *buff;
@@ -2497,5 +2607,5 @@ _bfd_ecoff_get_accumulated_ss (handle, buff)
buff += len + 1;
}
- return true;
+ return TRUE;
}
diff --git a/contrib/binutils/bfd/ecoffswap.h b/contrib/binutils/bfd/ecoffswap.h
index 24627d0..7ea0394 100644
--- a/contrib/binutils/bfd/ecoffswap.h
+++ b/contrib/binutils/bfd/ecoffswap.h
@@ -1,23 +1,23 @@
/* Generic ECOFF swapping routines, for BFD.
- Copyright 1992, 1993, 1994, 1995, 1996, 2000, 2001
+ Copyright 1992, 1993, 1994, 1995, 1996, 2000, 2001, 2002
Free Software Foundation, Inc.
Written by Cygnus Support.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* NOTE: This is a header file, but it contains executable routines.
This is done this way because these routines are substantially
@@ -220,7 +220,7 @@ ecoff_swap_fdr_in (abfd, ext_copy, intern)
intern->rfdBase = H_GET_32 (abfd, ext->f_rfdBase);
intern->crfd = H_GET_32 (abfd, ext->f_crfd);
- /* now the fun stuff... */
+ /* Now the fun stuff... */
if (bfd_header_big_endian (abfd))
{
intern->lang = ((ext->f_bits1[0] & FDR_BITS1_LANG_BIG)
@@ -263,7 +263,8 @@ ecoff_swap_fdr_out (abfd, intern_copy, ext_ptr)
struct fdr_ext *ext = (struct fdr_ext *) ext_ptr;
FDR intern[1];
- *intern = *intern_copy; /* Make it reasonable to do in-place. */
+ /* Make it reasonable to do in-place. */
+ *intern = *intern_copy;
ECOFF_PUT_OFF (abfd, intern->adr, ext->f_adr);
H_PUT_32 (abfd, intern->rss, ext->f_rss);
@@ -288,7 +289,7 @@ ecoff_swap_fdr_out (abfd, intern_copy, ext_ptr)
H_PUT_32 (abfd, intern->rfdBase, ext->f_rfdBase);
H_PUT_32 (abfd, intern->crfd, ext->f_crfd);
- /* now the fun stuff... */
+ /* Now the fun stuff... */
if (bfd_header_big_endian (abfd))
{
ext->f_bits1[0] = (((intern->lang << FDR_BITS1_LANG_SH_BIG)
@@ -355,6 +356,11 @@ ecoff_swap_pdr_in (abfd, ext_copy, intern)
intern->cbLineOffset = ECOFF_GET_OFF (abfd, ext->p_cbLineOffset);
#if defined (ECOFF_64) || defined (ECOFF_SIGNED_64)
+ if (intern->isym == (signed long) 0xffffffff)
+ intern->isym = -1;
+ if (intern->iline == (signed long) 0xffffffff)
+ intern->iline = -1;
+
intern->gp_prologue = H_GET_8 (abfd, ext->p_gp_prologue);
if (bfd_header_big_endian (abfd))
{
@@ -396,7 +402,8 @@ ecoff_swap_pdr_out (abfd, intern_copy, ext_ptr)
struct pdr_ext *ext = (struct pdr_ext *) ext_ptr;
PDR intern[1];
- *intern = *intern_copy; /* Make it reasonable to do in-place. */
+ /* Make it reasonable to do in-place. */
+ *intern = *intern_copy;
ECOFF_PUT_OFF (abfd, intern->adr, ext->p_adr);
H_PUT_32 (abfd, intern->isym, ext->p_isym);
@@ -494,7 +501,8 @@ ecoff_swap_pdr_out (abfd, intern_copy, ext_ptr)
struct pdr_ext *ext = (struct pdr_ext *) ext_ptr;
PDR intern[1];
- *intern = *intern_copy; /* Make it reasonable to do in-place. */
+ /* Make it reasonable to do in-place. */
+ *intern = *intern_copy;
ECOFF_PUT_OFF (abfd, intern->adr, ext->p_adr);
H_PUT_32 (abfd, intern->isym, ext->p_isym);
@@ -533,33 +541,41 @@ ecoff_swap_sym_in (abfd, ext_copy, intern)
intern->iss = H_GET_32 (abfd, ext->s_iss);
intern->value = ECOFF_GET_OFF (abfd, ext->s_value);
- /* now the fun stuff... */
- if (bfd_header_big_endian (abfd)) {
- intern->st = (ext->s_bits1[0] & SYM_BITS1_ST_BIG)
- >> SYM_BITS1_ST_SH_BIG;
- intern->sc = ((ext->s_bits1[0] & SYM_BITS1_SC_BIG)
- << SYM_BITS1_SC_SH_LEFT_BIG)
- | ((ext->s_bits2[0] & SYM_BITS2_SC_BIG)
- >> SYM_BITS2_SC_SH_BIG);
- intern->reserved = 0 != (ext->s_bits2[0] & SYM_BITS2_RESERVED_BIG);
- intern->index = ((ext->s_bits2[0] & SYM_BITS2_INDEX_BIG)
- << SYM_BITS2_INDEX_SH_LEFT_BIG)
- | (ext->s_bits3[0] << SYM_BITS3_INDEX_SH_LEFT_BIG)
- | (ext->s_bits4[0] << SYM_BITS4_INDEX_SH_LEFT_BIG);
- } else {
- intern->st = (ext->s_bits1[0] & SYM_BITS1_ST_LITTLE)
- >> SYM_BITS1_ST_SH_LITTLE;
- intern->sc = ((ext->s_bits1[0] & SYM_BITS1_SC_LITTLE)
- >> SYM_BITS1_SC_SH_LITTLE)
- | ((ext->s_bits2[0] & SYM_BITS2_SC_LITTLE)
- << SYM_BITS2_SC_SH_LEFT_LITTLE);
- intern->reserved = 0 != (ext->s_bits2[0] & SYM_BITS2_RESERVED_LITTLE);
- intern->index = ((ext->s_bits2[0] & SYM_BITS2_INDEX_LITTLE)
- >> SYM_BITS2_INDEX_SH_LITTLE)
- | (ext->s_bits3[0] << SYM_BITS3_INDEX_SH_LEFT_LITTLE)
- | ((unsigned int) ext->s_bits4[0]
- << SYM_BITS4_INDEX_SH_LEFT_LITTLE);
- }
+#if defined (ECOFF_64) || defined (ECOFF_SIGNED_64)
+ if (intern->iss == (signed long) 0xffffffff)
+ intern->iss = -1;
+#endif
+
+ /* Now the fun stuff... */
+ if (bfd_header_big_endian (abfd))
+ {
+ intern->st = (ext->s_bits1[0] & SYM_BITS1_ST_BIG)
+ >> SYM_BITS1_ST_SH_BIG;
+ intern->sc = ((ext->s_bits1[0] & SYM_BITS1_SC_BIG)
+ << SYM_BITS1_SC_SH_LEFT_BIG)
+ | ((ext->s_bits2[0] & SYM_BITS2_SC_BIG)
+ >> SYM_BITS2_SC_SH_BIG);
+ intern->reserved = 0 != (ext->s_bits2[0] & SYM_BITS2_RESERVED_BIG);
+ intern->index = ((ext->s_bits2[0] & SYM_BITS2_INDEX_BIG)
+ << SYM_BITS2_INDEX_SH_LEFT_BIG)
+ | (ext->s_bits3[0] << SYM_BITS3_INDEX_SH_LEFT_BIG)
+ | (ext->s_bits4[0] << SYM_BITS4_INDEX_SH_LEFT_BIG);
+ }
+ else
+ {
+ intern->st = (ext->s_bits1[0] & SYM_BITS1_ST_LITTLE)
+ >> SYM_BITS1_ST_SH_LITTLE;
+ intern->sc = ((ext->s_bits1[0] & SYM_BITS1_SC_LITTLE)
+ >> SYM_BITS1_SC_SH_LITTLE)
+ | ((ext->s_bits2[0] & SYM_BITS2_SC_LITTLE)
+ << SYM_BITS2_SC_SH_LEFT_LITTLE);
+ intern->reserved = 0 != (ext->s_bits2[0] & SYM_BITS2_RESERVED_LITTLE);
+ intern->index = ((ext->s_bits2[0] & SYM_BITS2_INDEX_LITTLE)
+ >> SYM_BITS2_INDEX_SH_LITTLE)
+ | (ext->s_bits3[0] << SYM_BITS3_INDEX_SH_LEFT_LITTLE)
+ | ((unsigned int) ext->s_bits4[0]
+ << SYM_BITS4_INDEX_SH_LEFT_LITTLE);
+ }
#ifdef TEST
if (memcmp ((char *)ext, (char *)intern, sizeof (*intern)) != 0)
@@ -578,37 +594,41 @@ ecoff_swap_sym_out (abfd, intern_copy, ext_ptr)
struct sym_ext *ext = (struct sym_ext *) ext_ptr;
SYMR intern[1];
- *intern = *intern_copy; /* Make it reasonable to do in-place. */
+ /* Make it reasonable to do in-place. */
+ *intern = *intern_copy;
H_PUT_32 (abfd, intern->iss, ext->s_iss);
ECOFF_PUT_OFF (abfd, intern->value, ext->s_value);
- /* now the fun stuff... */
- if (bfd_header_big_endian (abfd)) {
- ext->s_bits1[0] = (((intern->st << SYM_BITS1_ST_SH_BIG)
- & SYM_BITS1_ST_BIG)
- | ((intern->sc >> SYM_BITS1_SC_SH_LEFT_BIG)
- & SYM_BITS1_SC_BIG));
- ext->s_bits2[0] = (((intern->sc << SYM_BITS2_SC_SH_BIG)
- & SYM_BITS2_SC_BIG)
- | (intern->reserved ? SYM_BITS2_RESERVED_BIG : 0)
- | ((intern->index >> SYM_BITS2_INDEX_SH_LEFT_BIG)
- & SYM_BITS2_INDEX_BIG));
- ext->s_bits3[0] = (intern->index >> SYM_BITS3_INDEX_SH_LEFT_BIG) & 0xff;
- ext->s_bits4[0] = (intern->index >> SYM_BITS4_INDEX_SH_LEFT_BIG) & 0xff;
- } else {
- ext->s_bits1[0] = (((intern->st << SYM_BITS1_ST_SH_LITTLE)
- & SYM_BITS1_ST_LITTLE)
- | ((intern->sc << SYM_BITS1_SC_SH_LITTLE)
- & SYM_BITS1_SC_LITTLE));
- ext->s_bits2[0] = (((intern->sc >> SYM_BITS2_SC_SH_LEFT_LITTLE)
- & SYM_BITS2_SC_LITTLE)
- | (intern->reserved ? SYM_BITS2_RESERVED_LITTLE : 0)
- | ((intern->index << SYM_BITS2_INDEX_SH_LITTLE)
- & SYM_BITS2_INDEX_LITTLE));
- ext->s_bits3[0] = (intern->index >> SYM_BITS3_INDEX_SH_LEFT_LITTLE) & 0xff;
- ext->s_bits4[0] = (intern->index >> SYM_BITS4_INDEX_SH_LEFT_LITTLE) & 0xff;
- }
+ /* Now the fun stuff... */
+ if (bfd_header_big_endian (abfd))
+ {
+ ext->s_bits1[0] = (((intern->st << SYM_BITS1_ST_SH_BIG)
+ & SYM_BITS1_ST_BIG)
+ | ((intern->sc >> SYM_BITS1_SC_SH_LEFT_BIG)
+ & SYM_BITS1_SC_BIG));
+ ext->s_bits2[0] = (((intern->sc << SYM_BITS2_SC_SH_BIG)
+ & SYM_BITS2_SC_BIG)
+ | (intern->reserved ? SYM_BITS2_RESERVED_BIG : 0)
+ | ((intern->index >> SYM_BITS2_INDEX_SH_LEFT_BIG)
+ & SYM_BITS2_INDEX_BIG));
+ ext->s_bits3[0] = (intern->index >> SYM_BITS3_INDEX_SH_LEFT_BIG) & 0xff;
+ ext->s_bits4[0] = (intern->index >> SYM_BITS4_INDEX_SH_LEFT_BIG) & 0xff;
+ }
+ else
+ {
+ ext->s_bits1[0] = (((intern->st << SYM_BITS1_ST_SH_LITTLE)
+ & SYM_BITS1_ST_LITTLE)
+ | ((intern->sc << SYM_BITS1_SC_SH_LITTLE)
+ & SYM_BITS1_SC_LITTLE));
+ ext->s_bits2[0] = (((intern->sc >> SYM_BITS2_SC_SH_LEFT_LITTLE)
+ & SYM_BITS2_SC_LITTLE)
+ | (intern->reserved ? SYM_BITS2_RESERVED_LITTLE : 0)
+ | ((intern->index << SYM_BITS2_INDEX_SH_LITTLE)
+ & SYM_BITS2_INDEX_LITTLE));
+ ext->s_bits3[0] = (intern->index >> SYM_BITS3_INDEX_SH_LEFT_LITTLE) & 0xff;
+ ext->s_bits4[0] = (intern->index >> SYM_BITS4_INDEX_SH_LEFT_LITTLE) & 0xff;
+ }
#ifdef TEST
if (memcmp ((char *)ext, (char *)intern, sizeof (*intern)) != 0)
@@ -628,23 +648,26 @@ ecoff_swap_ext_in (abfd, ext_copy, intern)
*ext = *(struct ext_ext *) ext_copy;
- /* now the fun stuff... */
- if (bfd_header_big_endian (abfd)) {
- intern->jmptbl = 0 != (ext->es_bits1[0] & EXT_BITS1_JMPTBL_BIG);
- intern->cobol_main = 0 != (ext->es_bits1[0] & EXT_BITS1_COBOL_MAIN_BIG);
- intern->weakext = 0 != (ext->es_bits1[0] & EXT_BITS1_WEAKEXT_BIG);
- } else {
- intern->jmptbl = 0 != (ext->es_bits1[0] & EXT_BITS1_JMPTBL_LITTLE);
- intern->cobol_main = 0 != (ext->es_bits1[0] & EXT_BITS1_COBOL_MAIN_LITTLE);
- intern->weakext = 0 != (ext->es_bits1[0] & EXT_BITS1_WEAKEXT_LITTLE);
- }
+ /* Now the fun stuff... */
+ if (bfd_header_big_endian (abfd))
+ {
+ intern->jmptbl = 0 != (ext->es_bits1[0] & EXT_BITS1_JMPTBL_BIG);
+ intern->cobol_main = 0 != (ext->es_bits1[0] & EXT_BITS1_COBOL_MAIN_BIG);
+ intern->weakext = 0 != (ext->es_bits1[0] & EXT_BITS1_WEAKEXT_BIG);
+ }
+ else
+ {
+ intern->jmptbl = 0 != (ext->es_bits1[0] & EXT_BITS1_JMPTBL_LITTLE);
+ intern->cobol_main = 0 != (ext->es_bits1[0] & EXT_BITS1_COBOL_MAIN_LITTLE);
+ intern->weakext = 0 != (ext->es_bits1[0] & EXT_BITS1_WEAKEXT_LITTLE);
+ }
intern->reserved = 0;
#if defined (ECOFF_32) || defined (ECOFF_SIGNED_32)
- intern->ifd = H_GET_S16 (abfd, ext->es_ifd);
+ intern->ifd = H_GET_S16 (abfd, ext->es_ifd);
#endif
#if defined (ECOFF_64) || defined (ECOFF_SIGNED_64)
- intern->ifd = H_GET_S32 (abfd, ext->es_ifd);
+ intern->ifd = H_GET_S32 (abfd, ext->es_ifd);
#endif
ecoff_swap_sym_in (abfd, &ext->es_asym, &intern->asym);
@@ -666,28 +689,32 @@ ecoff_swap_ext_out (abfd, intern_copy, ext_ptr)
struct ext_ext *ext = (struct ext_ext *) ext_ptr;
EXTR intern[1];
- *intern = *intern_copy; /* Make it reasonable to do in-place. */
+ /* Make it reasonable to do in-place. */
+ *intern = *intern_copy;
- /* now the fun stuff... */
- if (bfd_header_big_endian (abfd)) {
- ext->es_bits1[0] = ((intern->jmptbl ? EXT_BITS1_JMPTBL_BIG : 0)
- | (intern->cobol_main ? EXT_BITS1_COBOL_MAIN_BIG : 0)
- | (intern->weakext ? EXT_BITS1_WEAKEXT_BIG : 0));
- ext->es_bits2[0] = 0;
+ /* Now the fun stuff... */
+ if (bfd_header_big_endian (abfd))
+ {
+ ext->es_bits1[0] = ((intern->jmptbl ? EXT_BITS1_JMPTBL_BIG : 0)
+ | (intern->cobol_main ? EXT_BITS1_COBOL_MAIN_BIG : 0)
+ | (intern->weakext ? EXT_BITS1_WEAKEXT_BIG : 0));
+ ext->es_bits2[0] = 0;
#if defined (ECOFF_64) || defined (ECOFF_SIGNED_64)
- ext->es_bits2[1] = 0;
- ext->es_bits2[2] = 0;
-#endif
- } else {
- ext->es_bits1[0] = ((intern->jmptbl ? EXT_BITS1_JMPTBL_LITTLE : 0)
- | (intern->cobol_main ? EXT_BITS1_COBOL_MAIN_LITTLE : 0)
- | (intern->weakext ? EXT_BITS1_WEAKEXT_LITTLE : 0));
- ext->es_bits2[0] = 0;
+ ext->es_bits2[1] = 0;
+ ext->es_bits2[2] = 0;
+#endif
+ }
+ else
+ {
+ ext->es_bits1[0] = ((intern->jmptbl ? EXT_BITS1_JMPTBL_LITTLE : 0)
+ | (intern->cobol_main ? EXT_BITS1_COBOL_MAIN_LITTLE : 0)
+ | (intern->weakext ? EXT_BITS1_WEAKEXT_LITTLE : 0));
+ ext->es_bits2[0] = 0;
#if defined (ECOFF_64) || defined (ECOFF_SIGNED_64)
- ext->es_bits2[1] = 0;
- ext->es_bits2[2] = 0;
+ ext->es_bits2[1] = 0;
+ ext->es_bits2[2] = 0;
#endif
- }
+ }
#if defined (ECOFF_32) || defined (ECOFF_SIGNED_32)
H_PUT_S16 (abfd, intern->ifd, ext->es_ifd);
@@ -792,7 +819,8 @@ ecoff_swap_opt_out (abfd, intern_copy, ext_ptr)
struct opt_ext *ext = (struct opt_ext *) ext_ptr;
OPTR intern[1];
- *intern = *intern_copy; /* Make it reasonable to do in-place. */
+ /* Make it reasonable to do in-place. */
+ *intern = *intern_copy;
if (bfd_header_big_endian (abfd))
{
@@ -852,7 +880,8 @@ ecoff_swap_dnr_out (abfd, intern_copy, ext_ptr)
struct dnr_ext *ext = (struct dnr_ext *) ext_ptr;
DNR intern[1];
- *intern = *intern_copy; /* Make it reasonable to do in-place. */
+ /* Make it reasonable to do in-place. */
+ *intern = *intern_copy;
H_PUT_32 (abfd, intern->rfd, ext->d_rfd);
H_PUT_32 (abfd, intern->index, ext->d_index);
diff --git a/contrib/binutils/bfd/efi-app-ia32.c b/contrib/binutils/bfd/efi-app-ia32.c
index 8519f99..92a17ef 100644
--- a/contrib/binutils/bfd/efi-app-ia32.c
+++ b/contrib/binutils/bfd/efi-app-ia32.c
@@ -1,5 +1,5 @@
/* BFD back-end for Intel IA-32 EFI application files.
- Copyright 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
Contributed by David Mosberger <davidm@hpl.hp.com>
This file is part of BFD, the Binary File Descriptor library.
@@ -25,7 +25,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define TARGET_NAME "efi-app-ia32"
#define COFF_IMAGE_WITH_PE
#define COFF_WITH_PE
-#define PCRELOFFSET true
+#define PCRELOFFSET TRUE
#define TARGET_UNDERSCORE '_'
#define COFF_LONG_SECTION_NAMES
#define PEI_TARGET_SUBSYSTEM IMAGE_SUBSYSTEM_EFI_APPLICATION
diff --git a/contrib/binutils/bfd/efi-app-ia64.c b/contrib/binutils/bfd/efi-app-ia64.c
index 6104568..c7e9bcf 100644
--- a/contrib/binutils/bfd/efi-app-ia64.c
+++ b/contrib/binutils/bfd/efi-app-ia64.c
@@ -1,5 +1,5 @@
/* BFD back-end for HP/Intel IA-64 EFI application files.
- Copyright 1999, 2000, 2001 Free Software Foundation, Inc.
+ Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
Contributed by David Mosberger <davidm@hpl.hp.com>
This file is part of BFD, the Binary File Descriptor library.
@@ -26,7 +26,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define COFF_IMAGE_WITH_PE
#define COFF_WITH_PE
#define COFF_WITH_pep
-#define PCRELOFFSET true
+#define PCRELOFFSET TRUE
#define TARGET_UNDERSCORE '_'
#define COFF_LONG_SECTION_NAMES
#define PEI_TARGET_SUBSYSTEM IMAGE_SUBSYSTEM_EFI_APPLICATION
diff --git a/contrib/binutils/bfd/elf-bfd.h b/contrib/binutils/bfd/elf-bfd.h
index 9417623..110dd69 100644
--- a/contrib/binutils/bfd/elf-bfd.h
+++ b/contrib/binutils/bfd/elf-bfd.h
@@ -1,23 +1,23 @@
/* BFD back-end data structures for ELF files.
Copyright 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
- 2002 Free Software Foundation, Inc.
+ 2002, 2003, 2004 Free Software Foundation, Inc.
Written by Cygnus Support.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef _LIBELF_H_
#define _LIBELF_H_ 1
@@ -33,20 +33,17 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define NUM_SHDR_ENTRIES(shdr) ((shdr)->sh_size / (shdr)->sh_entsize)
/* If size isn't specified as 64 or 32, NAME macro should fail. */
-/* Do not "beautify" the CONCAT* macro args. Traditional C will not
- remove whitespace added here, and thus will fail to concatenate
- the tokens. */
#ifndef NAME
-#if ARCH_SIZE==64
-#define NAME(x,y) CONCAT4 (x,64,_,y)
+#if ARCH_SIZE == 64
+#define NAME(x, y) x ## 64 ## _ ## y
#endif
-#if ARCH_SIZE==32
-#define NAME(x,y) CONCAT4 (x,32,_,y)
+#if ARCH_SIZE == 32
+#define NAME(x, y) x ## 32 ## _ ## y
#endif
#endif
#ifndef NAME
-#define NAME(x,y) CONCAT4 (x,NOSIZE,_,y)
+#define NAME(x, y) x ## NOSIZE ## _ ## y
#endif
#define ElfNAME(X) NAME(Elf,X)
@@ -67,8 +64,8 @@ typedef struct
union
{
unsigned int hppa_arg_reloc;
- PTR mips_extr;
- PTR any;
+ void *mips_extr;
+ void *any;
}
tc_data;
@@ -80,6 +77,8 @@ typedef struct
} elf_symbol_type;
struct elf_strtab_hash;
+struct got_entry;
+struct plt_entry;
/* ELF linker hash table entries. */
@@ -116,11 +115,6 @@ struct elf_link_hash_entry
one. Otherwise it is NULL. */
struct elf_link_hash_entry *weakdef;
- /* If this symbol is used in the linker created sections, the processor
- specific backend uses this field to map the field into the offset
- from the beginning of the section. */
- struct elf_linker_section_pointers *linker_section_pointer;
-
/* Version information. */
union
{
@@ -139,30 +133,30 @@ struct elf_link_hash_entry
and track a size while the symbol is still undefined. It is indexed
via offset/sizeof(target_void_pointer). */
size_t vtable_entries_size;
- boolean *vtable_entries_used;
+ bfd_boolean *vtable_entries_used;
/* Virtual table derivation info. */
struct elf_link_hash_entry *vtable_parent;
/* If this symbol requires an entry in the global offset table, the
processor specific backend uses this field to track usage and
- final offset. We use a union and two names primarily to document
- the intent of any particular piece of code. The field should be
- used as a count until size_dynamic_sections, at which point the
- contents of the .got is fixed. Afterward, if this field is -1,
- then the symbol does not require a global offset table entry. */
- union
+ final offset. Two schemes are supported: The first assumes that
+ a symbol may only have one GOT entry, and uses REFCOUNT until
+ size_dynamic_sections, at which point the contents of the .got is
+ fixed. Afterward, if OFFSET is -1, then the symbol does not
+ require a global offset table entry. The second scheme allows
+ multiple GOT entries per symbol, managed via a linked list
+ pointed to by GLIST. */
+ union gotplt_union
{
bfd_signed_vma refcount;
bfd_vma offset;
+ struct got_entry *glist;
+ struct plt_entry *plist;
} got;
/* Same, but tracks a procedure linkage table entry. */
- union
- {
- bfd_signed_vma refcount;
- bfd_vma offset;
- } plt;
+ union gotplt_union plt;
/* Symbol size. */
bfd_size_type size;
@@ -202,8 +196,28 @@ struct elf_link_hash_entry
/* Symbol is referenced by a non-GOT/non-PLT relocation. This is
not currently set by all the backends. */
#define ELF_LINK_NON_GOT_REF 010000
+ /* Symbol has a definition in a shared object. */
+#define ELF_LINK_DYNAMIC_DEF 020000
+ /* Symbol is weak in all shared objects. */
+#define ELF_LINK_DYNAMIC_WEAK 040000
+ /* Symbol is referenced with a relocation where C/C++ pointer equality
+ matters. */
+#define ELF_LINK_POINTER_EQUALITY_NEEDED 0100000
};
+/* Will references to this symbol always reference the symbol
+ in this object? STV_PROTECTED is excluded from the visibility test
+ here so that function pointer comparisons work properly. Since
+ function symbols not defined in an app are set to their .plt entry,
+ it's necessary for shared libs to also reference the .plt even
+ though the symbol is really local to the shared lib. */
+#define SYMBOL_REFERENCES_LOCAL(INFO, H) \
+ _bfd_elf_symbol_refs_local_p (H, INFO, 0)
+
+/* Will _calls_ to this symbol always call the version in this object? */
+#define SYMBOL_CALLS_LOCAL(INFO, H) \
+ _bfd_elf_symbol_refs_local_p (H, INFO, 1)
+
/* Records local symbols to be emitted in the dynamic symbol table. */
struct elf_link_local_dynamic_entry
@@ -229,23 +243,73 @@ struct elf_link_loaded_list
bfd *abfd;
};
-enum elf_link_info_type
+/* Structures used by the eh_frame optimization code. */
+struct cie_header
{
- ELF_INFO_TYPE_NONE,
- ELF_INFO_TYPE_STABS,
- ELF_INFO_TYPE_MERGE,
- ELF_INFO_TYPE_EH_FRAME,
- ELF_INFO_TYPE_EH_FRAME_HDR,
- ELF_INFO_TYPE_JUST_SYMS,
- ELF_INFO_TYPE_LAST
+ unsigned int length;
+ unsigned int id;
};
-/* Cached start, size and alignment of PT_TLS segment. */
-struct elf_link_tls_segment
+struct cie
{
- bfd_vma start;
- bfd_size_type size;
- unsigned int align;
+ struct cie_header hdr;
+ unsigned char version;
+ unsigned char augmentation[20];
+ unsigned int code_align;
+ int data_align;
+ unsigned int ra_column;
+ unsigned int augmentation_size;
+ struct elf_link_hash_entry *personality;
+ unsigned char per_encoding;
+ unsigned char lsda_encoding;
+ unsigned char fde_encoding;
+ unsigned char initial_insn_length;
+ unsigned char make_relative;
+ unsigned char make_lsda_relative;
+ unsigned char initial_instructions[50];
+};
+
+struct eh_cie_fde
+{
+ unsigned int offset;
+ unsigned int size;
+ asection *sec;
+ unsigned int new_offset;
+ unsigned char fde_encoding;
+ unsigned char lsda_encoding;
+ unsigned char lsda_offset;
+ unsigned char cie : 1;
+ unsigned char removed : 1;
+ unsigned char make_relative : 1;
+ unsigned char make_lsda_relative : 1;
+ unsigned char per_encoding_relative : 1;
+};
+
+struct eh_frame_sec_info
+{
+ unsigned int count;
+ unsigned int alloced;
+ struct eh_cie_fde entry[1];
+};
+
+struct eh_frame_array_ent
+{
+ bfd_vma initial_loc;
+ bfd_vma fde;
+};
+
+struct eh_frame_hdr_info
+{
+ struct cie last_cie;
+ asection *last_cie_sec;
+ asection *hdr_sec;
+ unsigned int last_cie_offset;
+ unsigned int fde_count, array_count;
+ struct eh_frame_array_ent *array;
+ /* TRUE if .eh_frame_hdr should contain the sorted search table.
+ We build it if we successfully read all .eh_frame input sections
+ and recognize them. */
+ bfd_boolean table;
};
/* ELF linker hash table. */
@@ -256,7 +320,7 @@ struct elf_link_hash_table
/* Whether we have created the special dynamic sections required
when linking against or generating a shared object. */
- boolean dynamic_sections_created;
+ bfd_boolean dynamic_sections_created;
/* The BFD used to hold special sections created by the linker.
This will be the first BFD found which requires these sections to
@@ -265,9 +329,13 @@ struct elf_link_hash_table
/* The value to use when initialising got.refcount/offset and
plt.refcount/offset in an elf_link_hash_entry. Set to zero when
- the values are refcounts. Set to -1 in size_dynamic_sections
- when the values may be offsets. */
- bfd_signed_vma init_refcount;
+ the values are refcounts. Set to init_offset in
+ size_dynamic_sections when the values may be offsets. */
+ union gotplt_union init_refcount;
+
+ /* The value to use for got.refcount/offset and plt.refcount/offset
+ when the values may be offsets. Normally (bfd_vma) -1. */
+ union gotplt_union init_offset;
/* The number of symbols found in the link which must be put into
the .dynsym section. */
@@ -289,10 +357,13 @@ struct elf_link_hash_table
struct elf_link_hash_entry *hgot;
/* A pointer to information used to link stabs in sections. */
- PTR stab_info;
+ void *stab_info;
/* A pointer to information used to merge SEC_MERGE sections. */
- PTR merge_info;
+ void *merge_info;
+
+ /* Used by eh_frame code when editing .eh_frame. */
+ struct eh_frame_hdr_info eh_info;
/* A linked list of local symbols to be added to .dynsym. */
struct elf_link_local_dynamic_entry *dynlocal;
@@ -301,8 +372,9 @@ struct elf_link_hash_table
objects included in the link. */
struct bfd_link_needed_list *runpath;
- /* Cached start, size and alignment of PT_TLS segment. */
- struct elf_link_tls_segment *tls_segment;
+ /* Cached first output tls section and size of PT_TLS segment. */
+ asection *tls_sec;
+ bfd_size_type tls_size;
/* A linked list of BFD's loaded in the link. */
struct elf_link_loaded_list *loaded;
@@ -320,16 +392,16 @@ struct elf_link_hash_table
#define elf_link_hash_traverse(table, func, info) \
(bfd_link_hash_traverse \
(&(table)->root, \
- (boolean (*) PARAMS ((struct bfd_link_hash_entry *, PTR))) (func), \
+ (bfd_boolean (*) (struct bfd_link_hash_entry *, void *)) (func), \
(info)))
/* Get the ELF linker hash table from a link_info structure. */
#define elf_hash_table(p) ((struct elf_link_hash_table *) ((p)->hash))
-/* Returns true if the hash table is a struct elf_link_hash_table. */
-#define is_elf_hash_table(p) \
- ((p)->hash->type == bfd_link_elf_hash_table)
+/* Returns TRUE if the hash table is a struct elf_link_hash_table. */
+#define is_elf_hash_table(htab) \
+ (((struct bfd_link_hash_table *) (htab))->type == bfd_link_elf_hash_table)
/* Used by bfd_section_from_r_symndx to cache a small number of local
symbol to section mappings. */
@@ -353,52 +425,50 @@ struct elf_size_info {
/* The number of internal relocations to allocate per external
relocation entry. */
unsigned char int_rels_per_ext_rel;
+ /* We use some fixed size arrays. This should be large enough to
+ handle all back-ends. */
+#define MAX_INT_RELS_PER_EXT_REL 3
- unsigned char arch_size, file_align;
+ unsigned char arch_size, log_file_align;
unsigned char elfclass, ev_current;
int (*write_out_phdrs)
- PARAMS ((bfd *, const Elf_Internal_Phdr *, unsigned int));
- boolean (*write_shdrs_and_ehdr)
- PARAMS ((bfd *));
+ (bfd *, const Elf_Internal_Phdr *, unsigned int);
+ bfd_boolean
+ (*write_shdrs_and_ehdr) (bfd *);
void (*write_relocs)
- PARAMS ((bfd *, asection *, PTR));
+ (bfd *, asection *, void *);
void (*swap_symbol_in)
- PARAMS ((bfd *, const PTR, const PTR, Elf_Internal_Sym *));
+ (bfd *, const void *, const void *, Elf_Internal_Sym *);
void (*swap_symbol_out)
- PARAMS ((bfd *, const Elf_Internal_Sym *, PTR, PTR));
- boolean (*slurp_reloc_table)
- PARAMS ((bfd *, asection *, asymbol **, boolean));
+ (bfd *, const Elf_Internal_Sym *, void *, void *);
+ bfd_boolean (*slurp_reloc_table)
+ (bfd *, asection *, asymbol **, bfd_boolean);
long (*slurp_symbol_table)
- PARAMS ((bfd *, asymbol **, boolean));
+ (bfd *, asymbol **, bfd_boolean);
void (*swap_dyn_in)
- PARAMS ((bfd *, const PTR, Elf_Internal_Dyn *));
+ (bfd *, const void *, Elf_Internal_Dyn *);
void (*swap_dyn_out)
- PARAMS ((bfd *, const Elf_Internal_Dyn *, PTR));
+ (bfd *, const Elf_Internal_Dyn *, void *);
- /* This function, if defined, is called to swap in a REL
- relocation. If an external relocation corresponds to more than
- one internal relocation, then all relocations are swapped in at
- once. */
+ /* This function is called to swap in a REL relocation. If an
+ external relocation corresponds to more than one internal
+ relocation, then all relocations are swapped in at once. */
void (*swap_reloc_in)
- PARAMS ((bfd *, const bfd_byte *, Elf_Internal_Rel *));
+ (bfd *, const bfd_byte *, Elf_Internal_Rela *);
- /* This function, if defined, is called to swap out a REL
- relocation. */
+ /* This function is called to swap out a REL relocation. */
void (*swap_reloc_out)
- PARAMS ((bfd *, const Elf_Internal_Rel *, bfd_byte *));
+ (bfd *, const Elf_Internal_Rela *, bfd_byte *);
- /* This function, if defined, is called to swap in a RELA
- relocation. If an external relocation corresponds to more than
- one internal relocation, then all relocations are swapped in at
- once. */
+ /* This function is called to swap in a RELA relocation. If an
+ external relocation corresponds to more than one internal
+ relocation, then all relocations are swapped in at once. */
void (*swap_reloca_in)
- PARAMS ((bfd *, const bfd_byte *, Elf_Internal_Rela *));
+ (bfd *, const bfd_byte *, Elf_Internal_Rela *);
- /* This function, if defined, is called to swap out a RELA
- relocation. */
+ /* This function is called to swap out a RELA relocation. */
void (*swap_reloca_out)
- PARAMS ((bfd *, const Elf_Internal_Rela *, bfd_byte *));
-
+ (bfd *, const Elf_Internal_Rela *, bfd_byte *);
};
#define elf_symbol_from(ABFD,S) \
@@ -422,7 +492,8 @@ struct elf_reloc_cookie
size_t locsymcount;
size_t extsymoff;
struct elf_link_hash_entry **sym_hashes;
- boolean bad_symtab;
+ int r_sym_shift;
+ bfd_boolean bad_symtab;
};
/* The level of IRIX compatibility we're striving for. */
@@ -433,6 +504,22 @@ typedef enum {
ict_irix6
} irix_compat_t;
+/* Mapping of ELF section names and types. */
+struct bfd_elf_special_section
+{
+ const char *prefix;
+ int prefix_length;
+ /* 0 means name must match PREFIX exactly.
+ -1 means name must start with PREFIX followed by an arbitrary string.
+ -2 means name must match PREFIX exactly or consist of PREFIX followed
+ by a dot then anything.
+ > 0 means name must start with the first PREFIX_LENGTH chars of
+ PREFIX and finish with the last SUFFIX_LENGTH chars of PREFIX. */
+ int suffix_length;
+ int type;
+ int attr;
+};
+
struct elf_backend_data
{
/* The architecture for this backend. */
@@ -447,20 +534,20 @@ struct elf_backend_data
/* A function to translate an ELF RELA relocation to a BFD arelent
structure. */
void (*elf_info_to_howto)
- PARAMS ((bfd *, arelent *, Elf_Internal_Rela *));
+ (bfd *, arelent *, Elf_Internal_Rela *);
/* A function to translate an ELF REL relocation to a BFD arelent
structure. */
void (*elf_info_to_howto_rel)
- PARAMS ((bfd *, arelent *, Elf_Internal_Rel *));
+ (bfd *, arelent *, Elf_Internal_Rela *);
/* A function to determine whether a symbol is global when
partitioning the symbol table into local and global symbols.
This should be NULL for most targets, in which case the correct
thing will be done. MIPS ELF, at least on the Irix 5, has
special requirements. */
- boolean (*elf_backend_sym_is_global)
- PARAMS ((bfd *, asymbol *));
+ bfd_boolean (*elf_backend_sym_is_global)
+ (bfd *, asymbol *);
/* The remaining functions are hooks which are called only if they
are not NULL. */
@@ -469,61 +556,66 @@ struct elf_backend_data
particular BFD format is relevant for an object file, and to
permit the backend to set any global information it wishes. When
this is called elf_elfheader is set, but anything else should be
- used with caution. If this returns false, the check_format
+ used with caution. If this returns FALSE, the check_format
routine will return a bfd_error_wrong_format error. */
- boolean (*elf_backend_object_p)
- PARAMS ((bfd *));
+ bfd_boolean (*elf_backend_object_p)
+ (bfd *);
/* A function to do additional symbol processing when reading the
ELF symbol table. This is where any processor-specific special
section indices are handled. */
void (*elf_backend_symbol_processing)
- PARAMS ((bfd *, asymbol *));
+ (bfd *, asymbol *);
/* A function to do additional symbol processing after reading the
entire ELF symbol table. */
- boolean (*elf_backend_symbol_table_processing)
- PARAMS ((bfd *, elf_symbol_type *, unsigned int));
+ bfd_boolean (*elf_backend_symbol_table_processing)
+ (bfd *, elf_symbol_type *, unsigned int);
/* A function to set the type of the info field. Processor-specific
types should be handled here. */
int (*elf_backend_get_symbol_type)
- PARAMS (( Elf_Internal_Sym *, int));
+ (Elf_Internal_Sym *, int);
+
+ /* Return true if local section symbols should have a non-null st_name.
+ NULL implies false. */
+ bfd_boolean (*elf_backend_name_local_section_symbols)
+ (bfd *);
/* A function to do additional processing on the ELF section header
just before writing it out. This is used to set the flags and
type fields for some sections, or to actually write out data for
unusual sections. */
- boolean (*elf_backend_section_processing)
- PARAMS ((bfd *, Elf32_Internal_Shdr *));
+ bfd_boolean (*elf_backend_section_processing)
+ (bfd *, Elf_Internal_Shdr *);
/* A function to handle unusual section types when creating BFD
sections from ELF sections. */
- boolean (*elf_backend_section_from_shdr)
- PARAMS ((bfd *, Elf32_Internal_Shdr *, const char *));
+ bfd_boolean (*elf_backend_section_from_shdr)
+ (bfd *, Elf_Internal_Shdr *, const char *);
/* A function to convert machine dependent section header flags to
BFD internal section header flags. */
- boolean (*elf_backend_section_flags)
- PARAMS ((flagword *, Elf32_Internal_Shdr *));
+ bfd_boolean (*elf_backend_section_flags)
+ (flagword *, Elf_Internal_Shdr *);
/* A function to handle unusual program segment types when creating BFD
sections from ELF program segments. */
- boolean (*elf_backend_section_from_phdr)
- PARAMS ((bfd *, Elf32_Internal_Phdr *, int));
+ bfd_boolean (*elf_backend_section_from_phdr)
+ (bfd *, Elf_Internal_Phdr *, int);
/* A function to set up the ELF section header for a BFD section in
preparation for writing it out. This is where the flags and type
fields are set for unusual sections. */
- boolean (*elf_backend_fake_sections)
- PARAMS ((bfd *, Elf32_Internal_Shdr *, asection *));
+ bfd_boolean (*elf_backend_fake_sections)
+ (bfd *, Elf_Internal_Shdr *, asection *);
/* A function to get the ELF section index for a BFD section. If
- this returns true, the section was found. If it is a normal ELF
+ this returns TRUE, the section was found. If it is a normal ELF
section, *RETVAL should be left unchanged. If it is not a normal
ELF section *RETVAL should be set to the SHN_xxxx index. */
- boolean (*elf_backend_section_from_bfd_section)
- PARAMS ((bfd *, asection *, int *retval));
+ bfd_boolean (*elf_backend_section_from_bfd_section)
+ (bfd *, asection *, int *retval);
/* If this field is not NULL, it is called by the add_symbols phase
of a link just before adding a symbol to the global linker hash
@@ -533,16 +625,15 @@ struct elf_backend_data
handling all processor dependent symbol bindings and section
indices, and must set at least *FLAGS and *SEC for each processor
dependent case; failure to do so will cause a link error. */
- boolean (*elf_add_symbol_hook)
- PARAMS ((bfd *abfd, struct bfd_link_info *info,
- const Elf_Internal_Sym *, const char **name,
- flagword *flags, asection **sec, bfd_vma *value));
+ bfd_boolean (*elf_add_symbol_hook)
+ (bfd *abfd, struct bfd_link_info *info, Elf_Internal_Sym *,
+ const char **name, flagword *flags, asection **sec, bfd_vma *value);
/* If this field is not NULL, it is called by the elf_link_output_sym
phase of a link for each symbol which will appear in the object file. */
- boolean (*elf_backend_link_output_symbol_hook)
- PARAMS ((bfd *, struct bfd_link_info *info, const char *,
- Elf_Internal_Sym *, asection *));
+ bfd_boolean (*elf_backend_link_output_symbol_hook)
+ (struct bfd_link_info *info, const char *, Elf_Internal_Sym *,
+ asection *, struct elf_link_hash_entry *);
/* The CREATE_DYNAMIC_SECTIONS function is called by the ELF backend
linker the first time it encounters a dynamic object in the link.
@@ -552,8 +643,8 @@ struct elf_backend_data
created, and this function may modify the section flags if
desired. This function will normally create the .got and .plt
sections, but different backends have different requirements. */
- boolean (*elf_backend_create_dynamic_sections)
- PARAMS ((bfd *abfd, struct bfd_link_info *info));
+ bfd_boolean (*elf_backend_create_dynamic_sections)
+ (bfd *abfd, struct bfd_link_info *info);
/* The CHECK_RELOCS function is called by the add_symbols phase of
the ELF backend linker. It is called once for each section with
@@ -565,9 +656,9 @@ struct elf_backend_data
relocs are always passed as Rela structures; if the section
actually uses Rel structures, the r_addend field will always be
zero. */
- boolean (*check_relocs)
- PARAMS ((bfd *abfd, struct bfd_link_info *info, asection *o,
- const Elf_Internal_Rela *relocs));
+ bfd_boolean (*check_relocs)
+ (bfd *abfd, struct bfd_link_info *info, asection *o,
+ const Elf_Internal_Rela *relocs);
/* The ADJUST_DYNAMIC_SYMBOL function is called by the ELF backend
linker for every symbol which is defined by a dynamic object and
@@ -581,15 +672,15 @@ struct elf_backend_data
the link can deal with. This will normally involve adding an
entry to the .plt or .got or some such section, and setting the
symbol to point to that. */
- boolean (*elf_backend_adjust_dynamic_symbol)
- PARAMS ((struct bfd_link_info *info, struct elf_link_hash_entry *h));
+ bfd_boolean (*elf_backend_adjust_dynamic_symbol)
+ (struct bfd_link_info *info, struct elf_link_hash_entry *h);
/* The ALWAYS_SIZE_SECTIONS function is called by the backend linker
after all the linker input files have been seen but before the
section sizes have been set. This is called after
ADJUST_DYNAMIC_SYMBOL, but before SIZE_DYNAMIC_SECTIONS. */
- boolean (*elf_backend_always_size_sections)
- PARAMS ((bfd *output_bfd, struct bfd_link_info *info));
+ bfd_boolean (*elf_backend_always_size_sections)
+ (bfd *output_bfd, struct bfd_link_info *info);
/* The SIZE_DYNAMIC_SECTIONS function is called by the ELF backend
linker after all the linker input files have been seen but before
@@ -601,8 +692,8 @@ struct elf_backend_data
.dynstr and .hash sections. This function must handle the
.interp section and any sections created by the
CREATE_DYNAMIC_SECTIONS entry point. */
- boolean (*elf_backend_size_dynamic_sections)
- PARAMS ((bfd *output_bfd, struct bfd_link_info *info));
+ bfd_boolean (*elf_backend_size_dynamic_sections)
+ (bfd *output_bfd, struct bfd_link_info *info);
/* The RELOCATE_SECTION function is called by the ELF backend linker
to handle the relocations for a section.
@@ -613,7 +704,7 @@ struct elf_backend_data
This function is responsible for adjust the section contents as
necessary, and (if using Rela relocs and generating a
- relocateable output file) adjusting the reloc addend as
+ relocatable output file) adjusting the reloc addend as
necessary.
This function does not have to worry about setting the reloc
@@ -627,16 +718,15 @@ struct elf_backend_data
The global hash table entry for the global symbols can be found
via elf_sym_hashes (input_bfd).
- When generating relocateable output, this function must handle
+ When generating relocatable output, this function must handle
STB_LOCAL/STT_SECTION symbols specially. The output symbol is
going to be the section symbol corresponding to the output
section, which means that the addend must be adjusted
accordingly. */
- boolean (*elf_backend_relocate_section)
- PARAMS ((bfd *output_bfd, struct bfd_link_info *info,
- bfd *input_bfd, asection *input_section, bfd_byte *contents,
- Elf_Internal_Rela *relocs, Elf_Internal_Sym *local_syms,
- asection **local_sections));
+ bfd_boolean (*elf_backend_relocate_section)
+ (bfd *output_bfd, struct bfd_link_info *info, bfd *input_bfd,
+ asection *input_section, bfd_byte *contents, Elf_Internal_Rela *relocs,
+ Elf_Internal_Sym *local_syms, asection **local_sections);
/* The FINISH_DYNAMIC_SYMBOL function is called by the ELF backend
linker just before it writes a symbol out to the .dynsym section.
@@ -645,71 +735,72 @@ struct elf_backend_data
dynamic sections. Note that FINISH_DYNAMIC_SYMBOL is called on
all .dynsym symbols, while ADJUST_DYNAMIC_SYMBOL is only called
on those symbols which are defined by a dynamic object. */
- boolean (*elf_backend_finish_dynamic_symbol)
- PARAMS ((bfd *output_bfd, struct bfd_link_info *info,
- struct elf_link_hash_entry *h, Elf_Internal_Sym *sym));
+ bfd_boolean (*elf_backend_finish_dynamic_symbol)
+ (bfd *output_bfd, struct bfd_link_info *info,
+ struct elf_link_hash_entry *h, Elf_Internal_Sym *sym);
/* The FINISH_DYNAMIC_SECTIONS function is called by the ELF backend
linker just before it writes all the dynamic sections out to the
output file. The FINISH_DYNAMIC_SYMBOL will have been called on
all dynamic symbols. */
- boolean (*elf_backend_finish_dynamic_sections)
- PARAMS ((bfd *output_bfd, struct bfd_link_info *info));
+ bfd_boolean (*elf_backend_finish_dynamic_sections)
+ (bfd *output_bfd, struct bfd_link_info *info);
/* A function to do any beginning processing needed for the ELF file
before building the ELF headers and computing file positions. */
void (*elf_backend_begin_write_processing)
- PARAMS ((bfd *, struct bfd_link_info *));
+ (bfd *, struct bfd_link_info *);
/* A function to do any final processing needed for the ELF file
- before writing it out. The LINKER argument is true if this BFD
+ before writing it out. The LINKER argument is TRUE if this BFD
was created by the ELF backend linker. */
void (*elf_backend_final_write_processing)
- PARAMS ((bfd *, boolean linker));
+ (bfd *, bfd_boolean linker);
/* This function is called by get_program_header_size. It should
return the number of additional program segments which this BFD
will need. It should return -1 on error. */
int (*elf_backend_additional_program_headers)
- PARAMS ((bfd *));
+ (bfd *);
/* This function is called to modify an existing segment map in a
backend specific fashion. */
- boolean (*elf_backend_modify_segment_map)
- PARAMS ((bfd *));
+ bfd_boolean (*elf_backend_modify_segment_map)
+ (bfd *, struct bfd_link_info *);
/* This function is called during section gc to discover the section a
particular relocation refers to. */
asection * (*gc_mark_hook)
- PARAMS ((asection *sec, struct bfd_link_info *, Elf_Internal_Rela *,
- struct elf_link_hash_entry *h, Elf_Internal_Sym *));
+ (asection *sec, struct bfd_link_info *, Elf_Internal_Rela *,
+ struct elf_link_hash_entry *h, Elf_Internal_Sym *);
/* This function, if defined, is called during the sweep phase of gc
in order that a backend might update any data structures it might
be maintaining. */
- boolean (*gc_sweep_hook)
- PARAMS ((bfd *abfd, struct bfd_link_info *info, asection *o,
- const Elf_Internal_Rela *relocs));
+ bfd_boolean (*gc_sweep_hook)
+ (bfd *abfd, struct bfd_link_info *info, asection *o,
+ const Elf_Internal_Rela *relocs);
/* This function, if defined, is called after the ELF headers have
been created. This allows for things like the OS and ABI versions
to be changed. */
void (*elf_backend_post_process_headers)
- PARAMS ((bfd *, struct bfd_link_info *));
+ (bfd *, struct bfd_link_info *);
/* This function, if defined, prints a symbol to file and returns the
name of the symbol to be printed. It should return NULL to fall
back to default symbol printing. */
const char *(*elf_backend_print_symbol_all)
- PARAMS ((bfd *, PTR, asymbol *));
+ (bfd *, void *, asymbol *);
/* This function, if defined, is called after all local symbols and
- global symbols converted to locals are emited into the symtab
+ global symbols converted to locals are emitted into the symtab
section. It allows the backend to emit special global symbols
not handled in the hash table. */
- boolean (*elf_backend_output_arch_syms)
- PARAMS ((bfd *, struct bfd_link_info *, PTR,
- boolean (*) (PTR, const char *, Elf_Internal_Sym *, asection *)));
+ bfd_boolean (*elf_backend_output_arch_syms)
+ (bfd *, struct bfd_link_info *, void *,
+ bfd_boolean (*) (void *, const char *, Elf_Internal_Sym *, asection *,
+ struct elf_link_hash_entry *));
/* Copy any information related to dynamic linking from a pre-existing
symbol to a newly created symbol. Also called to copy flags and
@@ -717,94 +808,125 @@ struct elf_backend_data
newly created and plt/got refcounts and dynamic indices should not
be copied. */
void (*elf_backend_copy_indirect_symbol)
- PARAMS ((struct elf_backend_data *, struct elf_link_hash_entry *,
- struct elf_link_hash_entry *));
+ (const struct elf_backend_data *, struct elf_link_hash_entry *,
+ struct elf_link_hash_entry *);
/* Modify any information related to dynamic linking such that the
symbol is not exported. */
void (*elf_backend_hide_symbol)
- PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *, boolean));
+ (struct bfd_link_info *, struct elf_link_hash_entry *, bfd_boolean);
+
+ /* Merge the backend specific symbol attribute. */
+ void (*elf_backend_merge_symbol_attribute)
+ (struct elf_link_hash_entry *, const Elf_Internal_Sym *, bfd_boolean,
+ bfd_boolean);
/* Emit relocations. Overrides default routine for emitting relocs,
except during a relocatable link, or if all relocs are being emitted. */
- boolean (*elf_backend_emit_relocs)
- PARAMS ((bfd *, asection *, Elf_Internal_Shdr *, Elf_Internal_Rela *));
+ bfd_boolean (*elf_backend_emit_relocs)
+ (bfd *, asection *, Elf_Internal_Shdr *, Elf_Internal_Rela *);
/* Count relocations. Not called for relocatable links
or if all relocs are being preserved in the output. */
unsigned int (*elf_backend_count_relocs)
- PARAMS ((asection *, Elf_Internal_Rela *));
+ (asection *, Elf_Internal_Rela *);
/* This function, if defined, is called when an NT_PRSTATUS note is found
in a core file. */
- boolean (*elf_backend_grok_prstatus)
- PARAMS ((bfd *, Elf_Internal_Note *));
+ bfd_boolean (*elf_backend_grok_prstatus)
+ (bfd *, Elf_Internal_Note *);
/* This function, if defined, is called when an NT_PSINFO or NT_PRPSINFO
note is found in a core file. */
- boolean (*elf_backend_grok_psinfo)
- PARAMS ((bfd *, Elf_Internal_Note *));
+ bfd_boolean (*elf_backend_grok_psinfo)
+ (bfd *, Elf_Internal_Note *);
/* Functions to print VMAs. Special code to handle 64 bit ELF files. */
void (* elf_backend_sprintf_vma)
- PARAMS ((bfd *, char *, bfd_vma));
+ (bfd *, char *, bfd_vma);
void (* elf_backend_fprintf_vma)
- PARAMS ((bfd *, PTR, bfd_vma));
+ (bfd *, void *, bfd_vma);
/* This function returns class of a reloc type. */
enum elf_reloc_type_class (*elf_backend_reloc_type_class)
- PARAMS ((const Elf_Internal_Rela *));
+ (const Elf_Internal_Rela *);
/* This function, if defined, removes information about discarded functions
from other sections which mention them. */
- boolean (*elf_backend_discard_info)
- PARAMS ((bfd *, struct elf_reloc_cookie *, struct bfd_link_info *));
+ bfd_boolean (*elf_backend_discard_info)
+ (bfd *, struct elf_reloc_cookie *, struct bfd_link_info *);
/* This function, if defined, signals that the function above has removed
the discarded relocations for this section. */
- boolean (*elf_backend_ignore_discarded_relocs)
- PARAMS ((asection *));
+ bfd_boolean (*elf_backend_ignore_discarded_relocs)
+ (asection *);
+
+ /* These functions tell elf-eh-frame whether to attempt to turn
+ absolute or lsda encodings into pc-relative ones. The default
+ definition enables these transformations. */
+ bfd_boolean (*elf_backend_can_make_relative_eh_frame)
+ (bfd *, struct bfd_link_info *, asection *);
+ bfd_boolean (*elf_backend_can_make_lsda_relative_eh_frame)
+ (bfd *, struct bfd_link_info *, asection *);
+
+ /* This function returns an encoding after computing the encoded
+ value (and storing it in ENCODED) for the given OFFSET into OSEC,
+ to be stored in at LOC_OFFSET into the LOC_SEC input section.
+ The default definition chooses a 32-bit PC-relative encoding. */
+ bfd_byte (*elf_backend_encode_eh_address)
+ (bfd *abfd, struct bfd_link_info *info,
+ asection *osec, bfd_vma offset,
+ asection *loc_sec, bfd_vma loc_offset,
+ bfd_vma *encoded);
/* This function, if defined, may write out the given section.
- Returns true if it did so and false if the caller should. */
- boolean (*elf_backend_write_section)
- PARAMS ((bfd *, asection *, bfd_byte *));
+ Returns TRUE if it did so and FALSE if the caller should. */
+ bfd_boolean (*elf_backend_write_section)
+ (bfd *, asection *, bfd_byte *);
/* The level of IRIX compatibility we're striving for.
MIPS ELF specific function. */
irix_compat_t (*elf_backend_mips_irix_compat)
- PARAMS ((bfd *));
+ (bfd *);
reloc_howto_type *(*elf_backend_mips_rtype_to_howto)
- PARAMS ((unsigned int, boolean));
+ (unsigned int, bfd_boolean);
/* The swapping table to use when dealing with ECOFF information.
Used for the MIPS ELF .mdebug section. */
const struct ecoff_debug_swap *elf_backend_ecoff_debug_swap;
+ /* This function implements `bfd_elf_bfd_from_remote_memory';
+ see elf.c, elfcode.h. */
+ bfd *(*elf_backend_bfd_from_remote_memory)
+ (bfd *templ, bfd_vma ehdr_vma, bfd_vma *loadbasep,
+ int (*target_read_memory) (bfd_vma vma, char *myaddr, int len));
+
/* Alternate EM_xxxx machine codes for this backend. */
int elf_machine_alt1;
int elf_machine_alt2;
const struct elf_size_info *s;
+ /* An array of target specific special section map. */
+ const struct bfd_elf_special_section *special_sections;
+
/* offset of the _GLOBAL_OFFSET_TABLE_ symbol from the start of the
.got section */
bfd_vma got_symbol_offset;
- /* The size in bytes of the headers for the GOT and PLT. This includes
- the so-called reserved entries on some systems. */
+ /* The size in bytes of the header for the GOT. This includes the
+ so-called reserved entries on some systems. */
bfd_vma got_header_size;
- bfd_vma plt_header_size;
- /* This is true if the linker should act like collect and gather
- global constructors and destructors by name. This is true for
+ /* This is TRUE if the linker should act like collect and gather
+ global constructors and destructors by name. This is TRUE for
MIPS ELF because the Irix 5 tools can not handle the .init
section. */
unsigned collect : 1;
- /* This is true if the linker should ignore changes to the type of a
- symbol. This is true for MIPS ELF because some Irix 5 objects
+ /* This is TRUE if the linker should ignore changes to the type of a
+ symbol. This is TRUE for MIPS ELF because some Irix 5 objects
record undefined functions as STT_OBJECT although the definitions
are STT_FUNC. */
unsigned type_change_ok : 1;
@@ -831,7 +953,7 @@ struct elf_backend_data
backend relocate_section routine for relocatable linking. */
unsigned rela_normal : 1;
- /* True if addresses "naturally" sign extend. This is used when
+ /* TRUE if addresses "naturally" sign extend. This is used when
swapping in from Elf32 when BFD64. */
unsigned sign_extend_vma : 1;
@@ -872,13 +994,6 @@ struct bfd_elf_section_data
/* The number of relocations currently assigned to REL_HDR2. */
unsigned int rel_count2;
- /* A pointer to a linked list tracking dynamic relocs copied for
- local symbols. */
- PTR local_dynrel;
-
- /* A pointer to the bfd section used for dynamic relocs. */
- asection *sreloc;
-
/* The ELF section number of this section. Only used for an output
file. */
int this_idx;
@@ -891,6 +1006,12 @@ struct bfd_elf_section_data
REL_HDR2 if any. Only used for an output file. */
int rel_idx2;
+ /* Used by the backend linker when generating a shared library to
+ record the dynamic symbol index for a section symbol
+ corresponding to this section. A value of 0 means that there is
+ no dynamic symbol for this section. */
+ int dynindx;
+
/* Used by the backend linker to store the symbol hash table entries
associated with relocs against global symbols. */
struct elf_link_hash_entry **rel_hashes;
@@ -900,101 +1021,85 @@ struct bfd_elf_section_data
pointer may be NULL. It is used by the backend linker. */
Elf_Internal_Rela *relocs;
- /* Used by the backend linker when generating a shared library to
- record the dynamic symbol index for a section symbol
- corresponding to this section. A value of 0 means that there is
- no dynamic symbol for this section. */
- long dynindx;
-
- /* A pointer used for various section optimizations. */
- PTR sec_info;
+ /* A pointer to a linked list tracking dynamic relocs copied for
+ local symbols. */
+ void *local_dynrel;
- /* Type of that information. */
- enum elf_link_info_type sec_info_type;
+ /* A pointer to the bfd section used for dynamic relocs. */
+ asection *sreloc;
union {
/* Group name, if this section is a member of a group. */
const char *name;
/* Group signature sym, if this is the SHT_GROUP section. */
- struct symbol_cache_entry *id;
+ struct bfd_symbol *id;
} group;
/* A linked list of sections in the group. Circular when used by
the linker. */
asection *next_in_group;
- /* A pointer available for the processor specific ELF backend. */
- PTR tdata;
-
- /* Nonzero if this section uses RELA relocations, rather than REL. */
- unsigned int use_rela_p:1;
-
- /* Nonzero when a group is COMDAT. */
- unsigned int linkonce_p:1;
+ /* A pointer used for various section optimizations. */
+ void *sec_info;
};
#define elf_section_data(sec) ((struct bfd_elf_section_data*)sec->used_by_bfd)
+#define elf_section_type(sec) (elf_section_data(sec)->this_hdr.sh_type)
+#define elf_section_flags(sec) (elf_section_data(sec)->this_hdr.sh_flags)
#define elf_group_name(sec) (elf_section_data(sec)->group.name)
#define elf_group_id(sec) (elf_section_data(sec)->group.id)
#define elf_next_in_group(sec) (elf_section_data(sec)->next_in_group)
-#define elf_linkonce_p(sec) (elf_section_data(sec)->linkonce_p)
-/* Return true if section has been discarded. */
-#define elf_discarded_section(sec) \
- (!bfd_is_abs_section(sec) \
- && bfd_is_abs_section((sec)->output_section) \
- && elf_section_data (sec)->sec_info_type != ELF_INFO_TYPE_MERGE \
- && elf_section_data (sec)->sec_info_type != ELF_INFO_TYPE_JUST_SYMS)
+/* Return TRUE if section has been discarded. */
+#define elf_discarded_section(sec) \
+ (!bfd_is_abs_section (sec) \
+ && bfd_is_abs_section ((sec)->output_section) \
+ && sec->sec_info_type != ELF_INFO_TYPE_MERGE \
+ && sec->sec_info_type != ELF_INFO_TYPE_JUST_SYMS)
#define get_elf_backend_data(abfd) \
- ((struct elf_backend_data *) (abfd)->xvec->backend_data)
+ ((const struct elf_backend_data *) (abfd)->xvec->backend_data)
-/* Enumeration to specify the special section. */
-typedef enum elf_linker_section_enum
+/* This struct is used to pass information to routines called via
+ elf_link_hash_traverse which must return failure. */
+
+struct elf_info_failed
{
- LINKER_SECTION_UNKNOWN, /* not used */
- LINKER_SECTION_GOT, /* .got section for global offset pointers */
- LINKER_SECTION_PLT, /* .plt section for generated procedure stubs */
- LINKER_SECTION_SDATA, /* .sdata/.sbss section for PowerPC */
- LINKER_SECTION_SDATA2, /* .sdata2/.sbss2 section for PowerPC */
- LINKER_SECTION_MAX /* # of linker sections */
-} elf_linker_section_enum_t;
+ bfd_boolean failed;
+ struct bfd_link_info *info;
+ struct bfd_elf_version_tree *verdefs;
+};
-/* Sections created by the linker. */
+/* This structure is used to pass information to
+ _bfd_elf_link_assign_sym_version. */
-typedef struct elf_linker_section
+struct elf_assign_sym_version_info
{
- char *name; /* name of the section */
- char *rel_name; /* name of the associated .rel{,a}. section */
- char *bss_name; /* name of a related .bss section */
- char *sym_name; /* name of symbol to reference this section */
- asection *section; /* pointer to the section */
- asection *bss_section; /* pointer to the bss section associated with this */
- asection *rel_section; /* pointer to the relocations needed for this section */
- struct elf_link_hash_entry *sym_hash; /* pointer to the created symbol hash value */
- bfd_vma initial_size; /* initial size before any linker generated allocations */
- bfd_vma sym_offset; /* offset of symbol from beginning of section */
- bfd_vma hole_size; /* size of reserved address hole in allocation */
- bfd_vma hole_offset; /* current offset for the hole */
- bfd_vma max_hole_offset; /* maximum offset for the hole */
- elf_linker_section_enum_t which; /* which section this is */
- boolean hole_written_p; /* whether the hole has been initialized */
- unsigned int alignment; /* alignment for the section */
- flagword flags; /* flags to use to create the section */
-} elf_linker_section_t;
-
-/* Linked list of allocated pointer entries. This hangs off of the symbol lists, and
- provides allows us to return different pointers, based on different addend's. */
-
-typedef struct elf_linker_section_pointers
+ /* Output BFD. */
+ bfd *output_bfd;
+ /* General link information. */
+ struct bfd_link_info *info;
+ /* Version tree. */
+ struct bfd_elf_version_tree *verdefs;
+ /* Whether we had a failure. */
+ bfd_boolean failed;
+};
+
+/* This structure is used to pass information to
+ _bfd_elf_link_find_version_dependencies. */
+
+struct elf_find_verdep_info
{
- struct elf_linker_section_pointers *next; /* next allocated pointer for this symbol */
- bfd_vma offset; /* offset of pointer from beginning of section */
- bfd_vma addend; /* addend used */
- elf_linker_section_enum_t which; /* which linker section this is */
- boolean written_address_p; /* whether address was written yet */
-} elf_linker_section_pointers_t;
+ /* Output BFD. */
+ bfd *output_bfd;
+ /* General link information. */
+ struct bfd_link_info *info;
+ /* The number of dependencies. */
+ unsigned int vers;
+ /* Whether we had a failure. */
+ bfd_boolean failed;
+};
/* Some private data is stashed away for future use using the tdata pointer
in the bfd structure. */
@@ -1025,18 +1130,9 @@ struct elf_obj_tdata
unsigned int symtab_shndx_section;
unsigned int dynversym_section, dynverdef_section, dynverref_section;
file_ptr next_file_pos;
-#if 0
- /* we don't need these inside bfd anymore, and I think
- these weren't used outside bfd. */
- void *prstatus; /* The raw /proc prstatus structure */
- void *prpsinfo; /* The raw /proc prpsinfo structure */
-#endif
bfd_vma gp; /* The gp value */
unsigned int gp_size; /* The gp size */
- Elf_Internal_Shdr **group_sect_ptr;
- int num_group;
-
/* Information grabbed from an elf core file. */
int core_signal;
int core_pid;
@@ -1044,32 +1140,21 @@ struct elf_obj_tdata
char* core_program;
char* core_command;
- /* This is set to true if the object was created by the backend
- linker. */
- boolean linker;
-
/* A mapping from external symbols to entries in the linker hash
table, used when linking. This is indexed by the symbol index
minus the sh_info field of the symbol table header. */
struct elf_link_hash_entry **sym_hashes;
- /* A mapping from local symbols to offsets into the global offset
- table, used when linking. This is indexed by the symbol index.
- Like for the globals, we use a union and two names primarily to
- document the intent of any particular piece of code. The field
- should be used as a count until size_dynamic_sections, at which
- point the contents of the .got is fixed. Afterward, if an entry
- is -1, then the symbol does not require a global offset table entry. */
+ /* Track usage and final offsets of GOT entries for local symbols.
+ This array is indexed by symbol index. Elements are used
+ identically to "got" in struct elf_link_hash_entry. */
union
{
bfd_signed_vma *refcounts;
bfd_vma *offsets;
+ struct got_entry **ents;
} local_got;
- /* A mapping from local symbols to offsets into the various linker
- sections added. This is index by the symbol index. */
- elf_linker_section_pointers_t **linker_section_pointers;
-
/* The linker ELF emulation code needs to let the backend ELF linker
know what filename should be used for a dynamic object if the
dynamic object is found using a search. The emulation code then
@@ -1080,26 +1165,11 @@ struct elf_obj_tdata
one. */
const char *dt_name;
- /* When a reference in a regular object is resolved by a shared
- object is loaded into via the DT_NEEDED entries by the linker
- ELF emulation code, we need to add the shared object to the
- DT_NEEDED list of the resulting binary to indicate the dependency
- as if the -l option is passed to the linker. This field holds the
- name of the loaded shared object. */
- const char *dt_soname;
-
- /* Irix 5 often screws up the symbol table, sorting local symbols
- after global symbols. This flag is set if the symbol table in
- this BFD appears to be screwed up. If it is, we ignore the
- sh_info field in the symbol table header, and always read all the
- symbols. */
- boolean bad_symtab;
-
/* Records the result of `get_program_header_size'. */
bfd_size_type program_header_size;
/* Used by find_nearest_line entry point. */
- PTR line_info;
+ void *line_info;
/* Used by MIPS ELF find_nearest_line entry point. The structure
could be included directly in this one, but there's no point to
@@ -1111,19 +1181,19 @@ struct elf_obj_tdata
struct dwarf1_debug *dwarf1_find_line_info;
/* A place to stash dwarf2 info for this bfd. */
- PTR dwarf2_find_line_info;
+ void *dwarf2_find_line_info;
/* An array of stub sections indexed by symbol number, used by the
MIPS ELF linker. FIXME: We should figure out some way to only
include this field for a MIPS ELF target. */
asection **local_stubs;
- /* Used to determine if the e_flags field has been initialized */
- boolean flags_init;
-
/* Used to determine if PT_GNU_EH_FRAME segment header should be
created. */
- boolean eh_frame_hdr;
+ asection *eh_frame_hdr;
+
+ Elf_Internal_Shdr **group_sect_ptr;
+ int num_group;
/* Number of symbol version definitions we are about to emit. */
unsigned int cverdefs;
@@ -1131,21 +1201,40 @@ struct elf_obj_tdata
/* Number of symbol version references we are about to emit. */
unsigned int cverrefs;
+ /* Segment flags for the PT_GNU_STACK segment. */
+ unsigned int stack_flags;
+
/* Symbol version definitions in external objects. */
Elf_Internal_Verdef *verdef;
/* Symbol version references to external objects. */
Elf_Internal_Verneed *verref;
- /* Linker sections that we are interested in. */
- struct elf_linker_section *linker_section[ (int)LINKER_SECTION_MAX ];
-
/* The Irix 5 support uses two virtual sections, which represent
text/data symbols defined in dynamic objects. */
asymbol *elf_data_symbol;
asymbol *elf_text_symbol;
asection *elf_data_section;
asection *elf_text_section;
+
+ /* Whether a dyanmic object was specified normally on the linker
+ command line, or was specified when --as-needed was in effect,
+ or was found via a DT_NEEDED entry. */
+ enum dynamic_lib_link_class dyn_lib_class;
+
+ /* This is set to TRUE if the object was created by the backend
+ linker. */
+ bfd_boolean linker;
+
+ /* Irix 5 often screws up the symbol table, sorting local symbols
+ after global symbols. This flag is set if the symbol table in
+ this BFD appears to be screwed up. If it is, we ignore the
+ sh_info field in the symbol table header, and always read all the
+ symbols. */
+ bfd_boolean bad_symtab;
+
+ /* Used to determine if the e_flags field has been initialized */
+ bfd_boolean flags_init;
};
#define elf_tdata(bfd) ((bfd) -> tdata.elf_obj_data)
@@ -1170,439 +1259,504 @@ struct elf_obj_tdata
#define elf_sym_hashes(bfd) (elf_tdata(bfd) -> sym_hashes)
#define elf_local_got_refcounts(bfd) (elf_tdata(bfd) -> local_got.refcounts)
#define elf_local_got_offsets(bfd) (elf_tdata(bfd) -> local_got.offsets)
-#define elf_local_ptr_offsets(bfd) (elf_tdata(bfd) -> linker_section_pointers)
+#define elf_local_got_ents(bfd) (elf_tdata(bfd) -> local_got.ents)
#define elf_dt_name(bfd) (elf_tdata(bfd) -> dt_name)
-#define elf_dt_soname(bfd) (elf_tdata(bfd) -> dt_soname)
+#define elf_dyn_lib_class(bfd) (elf_tdata(bfd) -> dyn_lib_class)
#define elf_bad_symtab(bfd) (elf_tdata(bfd) -> bad_symtab)
#define elf_flags_init(bfd) (elf_tdata(bfd) -> flags_init)
-#define elf_linker_section(bfd,n) (elf_tdata(bfd) -> linker_section[(int)n])
extern void _bfd_elf_swap_verdef_in
- PARAMS ((bfd *, const Elf_External_Verdef *, Elf_Internal_Verdef *));
+ (bfd *, const Elf_External_Verdef *, Elf_Internal_Verdef *);
extern void _bfd_elf_swap_verdef_out
- PARAMS ((bfd *, const Elf_Internal_Verdef *, Elf_External_Verdef *));
+ (bfd *, const Elf_Internal_Verdef *, Elf_External_Verdef *);
extern void _bfd_elf_swap_verdaux_in
- PARAMS ((bfd *, const Elf_External_Verdaux *, Elf_Internal_Verdaux *));
+ (bfd *, const Elf_External_Verdaux *, Elf_Internal_Verdaux *);
extern void _bfd_elf_swap_verdaux_out
- PARAMS ((bfd *, const Elf_Internal_Verdaux *, Elf_External_Verdaux *));
+ (bfd *, const Elf_Internal_Verdaux *, Elf_External_Verdaux *);
extern void _bfd_elf_swap_verneed_in
- PARAMS ((bfd *, const Elf_External_Verneed *, Elf_Internal_Verneed *));
+ (bfd *, const Elf_External_Verneed *, Elf_Internal_Verneed *);
extern void _bfd_elf_swap_verneed_out
- PARAMS ((bfd *, const Elf_Internal_Verneed *, Elf_External_Verneed *));
+ (bfd *, const Elf_Internal_Verneed *, Elf_External_Verneed *);
extern void _bfd_elf_swap_vernaux_in
- PARAMS ((bfd *, const Elf_External_Vernaux *, Elf_Internal_Vernaux *));
+ (bfd *, const Elf_External_Vernaux *, Elf_Internal_Vernaux *);
extern void _bfd_elf_swap_vernaux_out
- PARAMS ((bfd *, const Elf_Internal_Vernaux *, Elf_External_Vernaux *));
+ (bfd *, const Elf_Internal_Vernaux *, Elf_External_Vernaux *);
extern void _bfd_elf_swap_versym_in
- PARAMS ((bfd *, const Elf_External_Versym *, Elf_Internal_Versym *));
+ (bfd *, const Elf_External_Versym *, Elf_Internal_Versym *);
extern void _bfd_elf_swap_versym_out
- PARAMS ((bfd *, const Elf_Internal_Versym *, Elf_External_Versym *));
+ (bfd *, const Elf_Internal_Versym *, Elf_External_Versym *);
extern int _bfd_elf_section_from_bfd_section
- PARAMS ((bfd *, asection *));
+ (bfd *, asection *);
extern char *bfd_elf_string_from_elf_section
- PARAMS ((bfd *, unsigned, unsigned));
+ (bfd *, unsigned, unsigned);
extern char *bfd_elf_get_str_section
- PARAMS ((bfd *, unsigned));
+ (bfd *, unsigned);
extern Elf_Internal_Sym *bfd_elf_get_elf_syms
- PARAMS ((bfd *, Elf_Internal_Shdr *, size_t, size_t,
- Elf_Internal_Sym *, PTR, Elf_External_Sym_Shndx *));
-
-extern boolean _bfd_elf_copy_private_bfd_data
- PARAMS ((bfd *, bfd *));
-extern boolean _bfd_elf_print_private_bfd_data
- PARAMS ((bfd *, PTR));
+ (bfd *, Elf_Internal_Shdr *, size_t, size_t, Elf_Internal_Sym *, void *,
+ Elf_External_Sym_Shndx *);
+extern const char *bfd_elf_local_sym_name
+ (bfd *, Elf_Internal_Sym *);
+
+extern bfd_boolean _bfd_elf_copy_private_bfd_data
+ (bfd *, bfd *);
+extern bfd_boolean _bfd_elf_print_private_bfd_data
+ (bfd *, void *);
extern void bfd_elf_print_symbol
- PARAMS ((bfd *, PTR, asymbol *, bfd_print_symbol_type));
+ (bfd *, void *, asymbol *, bfd_print_symbol_type);
#define elf_string_from_elf_strtab(abfd, strindex) \
- bfd_elf_string_from_elf_section(abfd, elf_elfheader(abfd)->e_shstrndx, \
- strindex)
-
-#define bfd_elf32_print_symbol bfd_elf_print_symbol
-#define bfd_elf64_print_symbol bfd_elf_print_symbol
+ bfd_elf_string_from_elf_section (abfd, elf_elfheader(abfd)->e_shstrndx, \
+ strindex)
extern void _bfd_elf_sprintf_vma
- PARAMS ((bfd *, char *, bfd_vma));
+ (bfd *, char *, bfd_vma);
extern void _bfd_elf_fprintf_vma
- PARAMS ((bfd *, PTR, bfd_vma));
+ (bfd *, void *, bfd_vma);
+
+extern bfd_byte _bfd_elf_encode_eh_address
+ (bfd *abfd, struct bfd_link_info *info, asection *osec, bfd_vma offset,
+ asection *loc_sec, bfd_vma loc_offset, bfd_vma *encoded);
+extern bfd_boolean _bfd_elf_can_make_relative
+ (bfd *input_bfd, struct bfd_link_info *info, asection *eh_frame_section);
extern enum elf_reloc_type_class _bfd_elf_reloc_type_class
- PARAMS ((const Elf_Internal_Rela *));
+ (const Elf_Internal_Rela *);
extern bfd_vma _bfd_elf_rela_local_sym
- PARAMS ((bfd *, Elf_Internal_Sym *, asection *, Elf_Internal_Rela *));
+ (bfd *, Elf_Internal_Sym *, asection **, Elf_Internal_Rela *);
extern bfd_vma _bfd_elf_rel_local_sym
- PARAMS ((bfd *, Elf_Internal_Sym *, asection **, bfd_vma));
+ (bfd *, Elf_Internal_Sym *, asection **, bfd_vma);
extern bfd_vma _bfd_elf_section_offset
- PARAMS ((bfd *, struct bfd_link_info *, asection *, bfd_vma));
+ (bfd *, struct bfd_link_info *, asection *, bfd_vma);
extern unsigned long bfd_elf_hash
- PARAMS ((const char *));
+ (const char *);
extern bfd_reloc_status_type bfd_elf_generic_reloc
- PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
-extern boolean bfd_elf_mkobject
- PARAMS ((bfd *));
-extern boolean bfd_elf_mkcorefile
- PARAMS ((bfd *));
+ (bfd *, arelent *, asymbol *, void *, asection *, bfd *, char **);
+extern bfd_boolean bfd_elf_mkobject
+ (bfd *);
+extern bfd_boolean bfd_elf_mkcorefile
+ (bfd *);
extern Elf_Internal_Shdr *bfd_elf_find_section
- PARAMS ((bfd *, char *));
-extern boolean _bfd_elf_make_section_from_shdr
- PARAMS ((bfd *, Elf_Internal_Shdr *, const char *));
-extern boolean _bfd_elf_make_section_from_phdr
- PARAMS ((bfd *, Elf_Internal_Phdr *, int, const char *));
+ (bfd *, char *);
+extern bfd_boolean _bfd_elf_make_section_from_shdr
+ (bfd *, Elf_Internal_Shdr *, const char *);
+extern bfd_boolean _bfd_elf_make_section_from_phdr
+ (bfd *, Elf_Internal_Phdr *, int, const char *);
extern struct bfd_hash_entry *_bfd_elf_link_hash_newfunc
- PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
+ (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
extern struct bfd_link_hash_table *_bfd_elf_link_hash_table_create
- PARAMS ((bfd *));
+ (bfd *);
extern void _bfd_elf_link_hash_copy_indirect
- PARAMS ((struct elf_backend_data *, struct elf_link_hash_entry *,
- struct elf_link_hash_entry *));
+ (const struct elf_backend_data *, struct elf_link_hash_entry *,
+ struct elf_link_hash_entry *);
extern void _bfd_elf_link_hash_hide_symbol
- PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *, boolean));
-extern boolean _bfd_elf_link_hash_table_init
- PARAMS ((struct elf_link_hash_table *, bfd *,
- struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
- struct bfd_hash_table *,
- const char *)));
-extern boolean _bfd_elf_slurp_version_tables
- PARAMS ((bfd *));
-extern boolean _bfd_elf_merge_sections
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean bfd_elf_discard_group
- PARAMS ((bfd *, struct sec *));
+ (struct bfd_link_info *, struct elf_link_hash_entry *, bfd_boolean);
+extern bfd_boolean _bfd_elf_link_hash_table_init
+ (struct elf_link_hash_table *, bfd *,
+ struct bfd_hash_entry *(*)
+ (struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
+extern bfd_boolean _bfd_elf_slurp_version_tables
+ (bfd *);
+extern bfd_boolean _bfd_elf_merge_sections
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean bfd_elf_discard_group
+ (bfd *, struct bfd_section *);
extern void bfd_elf_set_group_contents
- PARAMS ((bfd *, asection *, PTR));
+ (bfd *, asection *, void *);
extern void _bfd_elf_link_just_syms
- PARAMS ((asection *, struct bfd_link_info *));
-extern boolean _bfd_elf_copy_private_symbol_data
- PARAMS ((bfd *, asymbol *, bfd *, asymbol *));
-extern boolean _bfd_elf_copy_private_section_data
- PARAMS ((bfd *, asection *, bfd *, asection *));
-extern boolean _bfd_elf_write_object_contents
- PARAMS ((bfd *));
-extern boolean _bfd_elf_write_corefile_contents
- PARAMS ((bfd *));
-extern boolean _bfd_elf_set_section_contents
- PARAMS ((bfd *, sec_ptr, PTR, file_ptr, bfd_size_type));
+ (asection *, struct bfd_link_info *);
+extern bfd_boolean _bfd_elf_copy_private_symbol_data
+ (bfd *, asymbol *, bfd *, asymbol *);
+extern bfd_boolean _bfd_elf_copy_private_section_data
+ (bfd *, asection *, bfd *, asection *);
+extern bfd_boolean _bfd_elf_write_object_contents
+ (bfd *);
+extern bfd_boolean _bfd_elf_write_corefile_contents
+ (bfd *);
+extern bfd_boolean _bfd_elf_set_section_contents
+ (bfd *, sec_ptr, const void *, file_ptr, bfd_size_type);
extern long _bfd_elf_get_symtab_upper_bound
- PARAMS ((bfd *));
-extern long _bfd_elf_get_symtab
- PARAMS ((bfd *, asymbol **));
+ (bfd *);
+extern long _bfd_elf_canonicalize_symtab
+ (bfd *, asymbol **);
extern long _bfd_elf_get_dynamic_symtab_upper_bound
- PARAMS ((bfd *));
+ (bfd *);
extern long _bfd_elf_canonicalize_dynamic_symtab
- PARAMS ((bfd *, asymbol **));
+ (bfd *, asymbol **);
extern long _bfd_elf_get_reloc_upper_bound
- PARAMS ((bfd *, sec_ptr));
+ (bfd *, sec_ptr);
extern long _bfd_elf_canonicalize_reloc
- PARAMS ((bfd *, sec_ptr, arelent **, asymbol **));
+ (bfd *, sec_ptr, arelent **, asymbol **);
extern long _bfd_elf_get_dynamic_reloc_upper_bound
- PARAMS ((bfd *));
+ (bfd *);
extern long _bfd_elf_canonicalize_dynamic_reloc
- PARAMS ((bfd *, arelent **, asymbol **));
+ (bfd *, arelent **, asymbol **);
extern asymbol *_bfd_elf_make_empty_symbol
- PARAMS ((bfd *));
+ (bfd *);
extern void _bfd_elf_get_symbol_info
- PARAMS ((bfd *, asymbol *, symbol_info *));
-extern boolean _bfd_elf_is_local_label_name
- PARAMS ((bfd *, const char *));
+ (bfd *, asymbol *, symbol_info *);
+extern bfd_boolean _bfd_elf_is_local_label_name
+ (bfd *, const char *);
extern alent *_bfd_elf_get_lineno
- PARAMS ((bfd *, asymbol *));
-extern boolean _bfd_elf_set_arch_mach
- PARAMS ((bfd *, enum bfd_architecture, unsigned long));
-extern boolean _bfd_elf_find_nearest_line
- PARAMS ((bfd *, asection *, asymbol **, bfd_vma, const char **,
- const char **, unsigned int *));
+ (bfd *, asymbol *);
+extern bfd_boolean _bfd_elf_set_arch_mach
+ (bfd *, enum bfd_architecture, unsigned long);
+extern bfd_boolean _bfd_elf_find_nearest_line
+ (bfd *, asection *, asymbol **, bfd_vma, const char **, const char **,
+ unsigned int *);
#define _bfd_elf_read_minisymbols _bfd_generic_read_minisymbols
#define _bfd_elf_minisymbol_to_symbol _bfd_generic_minisymbol_to_symbol
extern int _bfd_elf_sizeof_headers
- PARAMS ((bfd *, boolean));
-extern boolean _bfd_elf_new_section_hook
- PARAMS ((bfd *, asection *));
-extern boolean _bfd_elf_init_reloc_shdr
- PARAMS ((bfd *, Elf_Internal_Shdr *, asection *, boolean));
+ (bfd *, bfd_boolean);
+extern bfd_boolean _bfd_elf_new_section_hook
+ (bfd *, asection *);
+extern bfd_boolean _bfd_elf_init_reloc_shdr
+ (bfd *, Elf_Internal_Shdr *, asection *, bfd_boolean);
+extern const struct bfd_elf_special_section *_bfd_elf_get_sec_type_attr
+ (bfd *, const char *);
/* If the target doesn't have reloc handling written yet: */
extern void _bfd_elf_no_info_to_howto
- PARAMS ((bfd *, arelent *, Elf_Internal_Rela *));
+ (bfd *, arelent *, Elf_Internal_Rela *);
-extern boolean bfd_section_from_shdr
- PARAMS ((bfd *, unsigned int shindex));
-extern boolean bfd_section_from_phdr
- PARAMS ((bfd *, Elf_Internal_Phdr *, int));
+extern bfd_boolean bfd_section_from_shdr
+ (bfd *, unsigned int shindex);
+extern bfd_boolean bfd_section_from_phdr
+ (bfd *, Elf_Internal_Phdr *, int);
extern int _bfd_elf_symbol_from_bfd_symbol
- PARAMS ((bfd *, asymbol **));
+ (bfd *, asymbol **);
extern asection *bfd_section_from_r_symndx
- PARAMS ((bfd *, struct sym_sec_cache *, asection *, unsigned long));
+ (bfd *, struct sym_sec_cache *, asection *, unsigned long);
extern asection *bfd_section_from_elf_index
- PARAMS ((bfd *, unsigned int));
-extern boolean _bfd_elf_create_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *));
+ (bfd *, unsigned int);
extern struct bfd_strtab_hash *_bfd_elf_stringtab_init
- PARAMS ((void));
+ (void);
extern struct elf_strtab_hash * _bfd_elf_strtab_init
- PARAMS ((void));
+ (void);
extern void _bfd_elf_strtab_free
- PARAMS ((struct elf_strtab_hash *));
+ (struct elf_strtab_hash *);
extern bfd_size_type _bfd_elf_strtab_add
- PARAMS ((struct elf_strtab_hash *, const char *, boolean));
+ (struct elf_strtab_hash *, const char *, bfd_boolean);
extern void _bfd_elf_strtab_addref
- PARAMS ((struct elf_strtab_hash *, bfd_size_type));
+ (struct elf_strtab_hash *, bfd_size_type);
extern void _bfd_elf_strtab_delref
- PARAMS ((struct elf_strtab_hash *, bfd_size_type));
+ (struct elf_strtab_hash *, bfd_size_type);
extern void _bfd_elf_strtab_clear_all_refs
- PARAMS ((struct elf_strtab_hash *));
+ (struct elf_strtab_hash *);
extern bfd_size_type _bfd_elf_strtab_size
- PARAMS ((struct elf_strtab_hash *));
+ (struct elf_strtab_hash *);
extern bfd_size_type _bfd_elf_strtab_offset
- PARAMS ((struct elf_strtab_hash *, bfd_size_type));
-extern boolean _bfd_elf_strtab_emit
- PARAMS ((bfd *, struct elf_strtab_hash *));
+ (struct elf_strtab_hash *, bfd_size_type);
+extern bfd_boolean _bfd_elf_strtab_emit
+ (bfd *, struct elf_strtab_hash *);
extern void _bfd_elf_strtab_finalize
- PARAMS ((struct elf_strtab_hash *));
+ (struct elf_strtab_hash *);
-extern boolean _bfd_elf_discard_section_eh_frame
- PARAMS ((bfd *, struct bfd_link_info *, asection *, asection *,
- boolean (*) (bfd_vma, PTR), struct elf_reloc_cookie *));
-extern boolean _bfd_elf_discard_section_eh_frame_hdr
- PARAMS ((bfd *, struct bfd_link_info *, asection *));
+extern bfd_boolean _bfd_elf_discard_section_eh_frame
+ (bfd *, struct bfd_link_info *, asection *,
+ bfd_boolean (*) (bfd_vma, void *), struct elf_reloc_cookie *);
+extern bfd_boolean _bfd_elf_discard_section_eh_frame_hdr
+ (bfd *, struct bfd_link_info *);
extern bfd_vma _bfd_elf_eh_frame_section_offset
- PARAMS ((bfd *, asection *, bfd_vma));
-extern boolean _bfd_elf_write_section_eh_frame
- PARAMS ((bfd *, asection *, asection *, bfd_byte *));
-extern boolean _bfd_elf_write_section_eh_frame_hdr
- PARAMS ((bfd *, asection *));
-extern boolean _bfd_elf_maybe_strip_eh_frame_hdr
- PARAMS ((struct bfd_link_info *));
-
-extern boolean _bfd_elf_link_record_dynamic_symbol
- PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *));
+ (bfd *, asection *, bfd_vma);
+extern bfd_boolean _bfd_elf_write_section_eh_frame
+ (bfd *, struct bfd_link_info *, asection *, bfd_byte *);
+extern bfd_boolean _bfd_elf_write_section_eh_frame_hdr
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean _bfd_elf_maybe_strip_eh_frame_hdr
+ (struct bfd_link_info *);
+
+extern bfd_boolean _bfd_elf_merge_symbol
+ (bfd *, struct bfd_link_info *, const char *, Elf_Internal_Sym *,
+ asection **, bfd_vma *, struct elf_link_hash_entry **, bfd_boolean *,
+ bfd_boolean *, bfd_boolean *, bfd_boolean *);
+
+extern bfd_boolean _bfd_elf_add_default_symbol
+ (bfd *, struct bfd_link_info *, struct elf_link_hash_entry *,
+ const char *, Elf_Internal_Sym *, asection **, bfd_vma *,
+ bfd_boolean *, bfd_boolean);
+
+extern bfd_boolean _bfd_elf_export_symbol
+ (struct elf_link_hash_entry *, void *);
+
+extern bfd_boolean _bfd_elf_link_find_version_dependencies
+ (struct elf_link_hash_entry *, void *);
+
+extern bfd_boolean _bfd_elf_link_assign_sym_version
+ (struct elf_link_hash_entry *, void *);
+
extern long _bfd_elf_link_lookup_local_dynindx
- PARAMS ((struct bfd_link_info *, bfd *, long));
-extern boolean _bfd_elf_compute_section_file_positions
- PARAMS ((bfd *, struct bfd_link_info *));
+ (struct bfd_link_info *, bfd *, long);
+extern bfd_boolean _bfd_elf_compute_section_file_positions
+ (bfd *, struct bfd_link_info *);
extern void _bfd_elf_assign_file_positions_for_relocs
- PARAMS ((bfd *));
+ (bfd *);
extern file_ptr _bfd_elf_assign_file_position_for_section
- PARAMS ((Elf_Internal_Shdr *, file_ptr, boolean));
+ (Elf_Internal_Shdr *, file_ptr, bfd_boolean);
-extern boolean _bfd_elf_validate_reloc
- PARAMS ((bfd *, arelent *));
+extern bfd_boolean _bfd_elf_validate_reloc
+ (bfd *, arelent *);
-extern boolean _bfd_elf_create_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean _bfd_elf_create_got_section
- PARAMS ((bfd *, struct bfd_link_info *));
+extern bfd_boolean _bfd_elf_link_create_dynamic_sections
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean _bfd_elf_create_dynamic_sections
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean _bfd_elf_create_got_section
+ (bfd *, struct bfd_link_info *);
extern unsigned long _bfd_elf_link_renumber_dynsyms
- PARAMS ((bfd *, struct bfd_link_info *));
+ (bfd *, struct bfd_link_info *);
-extern boolean _bfd_elfcore_make_pseudosection
- PARAMS ((bfd *, char *, size_t, ufile_ptr));
+extern bfd_boolean _bfd_elfcore_make_pseudosection
+ (bfd *, char *, size_t, ufile_ptr);
extern char *_bfd_elfcore_strndup
- PARAMS ((bfd *, char *, size_t));
+ (bfd *, char *, size_t);
-extern elf_linker_section_t *_bfd_elf_create_linker_section
- PARAMS ((bfd *, struct bfd_link_info *, enum elf_linker_section_enum,
- elf_linker_section_t *));
+extern Elf_Internal_Rela *_bfd_elf_link_read_relocs
+ (bfd *, asection *, void *, Elf_Internal_Rela *, bfd_boolean);
-extern elf_linker_section_pointers_t *_bfd_elf_find_pointer_linker_section
- PARAMS ((elf_linker_section_pointers_t *, bfd_vma,
- elf_linker_section_enum_t));
+extern bfd_boolean _bfd_elf_link_size_reloc_section
+ (bfd *, Elf_Internal_Shdr *, asection *);
-extern boolean bfd_elf32_create_pointer_linker_section
- PARAMS ((bfd *, struct bfd_link_info *, elf_linker_section_t *,
- struct elf_link_hash_entry *, const Elf32_Internal_Rela *));
+extern bfd_boolean _bfd_elf_link_output_relocs
+ (bfd *, asection *, Elf_Internal_Shdr *, Elf_Internal_Rela *);
-extern bfd_vma bfd_elf32_finish_pointer_linker_section
- PARAMS ((bfd *, bfd *, struct bfd_link_info *, elf_linker_section_t *,
- struct elf_link_hash_entry *, bfd_vma,
- const Elf32_Internal_Rela *, int));
+extern bfd_boolean _bfd_elf_fix_symbol_flags
+ (struct elf_link_hash_entry *, struct elf_info_failed *);
-extern boolean bfd_elf64_create_pointer_linker_section
- PARAMS ((bfd *, struct bfd_link_info *, elf_linker_section_t *,
- struct elf_link_hash_entry *, const Elf64_Internal_Rela *));
+extern bfd_boolean _bfd_elf_adjust_dynamic_symbol
+ (struct elf_link_hash_entry *, void *);
-extern bfd_vma bfd_elf64_finish_pointer_linker_section
- PARAMS ((bfd *, bfd *, struct bfd_link_info *, elf_linker_section_t *,
- struct elf_link_hash_entry *, bfd_vma,
- const Elf64_Internal_Rela *, int));
+extern bfd_boolean _bfd_elf_link_sec_merge_syms
+ (struct elf_link_hash_entry *, void *);
-extern boolean _bfd_elf_make_linker_section_rela
- PARAMS ((bfd *, elf_linker_section_t *, int));
+extern bfd_boolean _bfd_elf_dynamic_symbol_p
+ (struct elf_link_hash_entry *, struct bfd_link_info *, bfd_boolean);
+
+extern bfd_boolean _bfd_elf_symbol_refs_local_p
+ (struct elf_link_hash_entry *, struct bfd_link_info *, bfd_boolean);
extern const bfd_target *bfd_elf32_object_p
- PARAMS ((bfd *));
+ (bfd *);
extern const bfd_target *bfd_elf32_core_file_p
- PARAMS ((bfd *));
+ (bfd *);
extern char *bfd_elf32_core_file_failing_command
- PARAMS ((bfd *));
+ (bfd *);
extern int bfd_elf32_core_file_failing_signal
- PARAMS ((bfd *));
-extern boolean bfd_elf32_core_file_matches_executable_p
- PARAMS ((bfd *, bfd *));
-
-extern boolean bfd_elf32_bfd_link_add_symbols
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean bfd_elf32_bfd_final_link
- PARAMS ((bfd *, struct bfd_link_info *));
+ (bfd *);
+extern bfd_boolean bfd_elf32_core_file_matches_executable_p
+ (bfd *, bfd *);
extern void bfd_elf32_swap_symbol_in
- PARAMS ((bfd *, const PTR, const PTR, Elf_Internal_Sym *));
+ (bfd *, const void *, const void *, Elf_Internal_Sym *);
extern void bfd_elf32_swap_symbol_out
- PARAMS ((bfd *, const Elf_Internal_Sym *, PTR, PTR));
+ (bfd *, const Elf_Internal_Sym *, void *, void *);
extern void bfd_elf32_swap_reloc_in
- PARAMS ((bfd *, const Elf32_External_Rel *, Elf_Internal_Rel *));
+ (bfd *, const bfd_byte *, Elf_Internal_Rela *);
extern void bfd_elf32_swap_reloc_out
- PARAMS ((bfd *, const Elf_Internal_Rel *, Elf32_External_Rel *));
+ (bfd *, const Elf_Internal_Rela *, bfd_byte *);
extern void bfd_elf32_swap_reloca_in
- PARAMS ((bfd *, const Elf32_External_Rela *, Elf_Internal_Rela *));
+ (bfd *, const bfd_byte *, Elf_Internal_Rela *);
extern void bfd_elf32_swap_reloca_out
- PARAMS ((bfd *, const Elf_Internal_Rela *, Elf32_External_Rela *));
+ (bfd *, const Elf_Internal_Rela *, bfd_byte *);
extern void bfd_elf32_swap_phdr_in
- PARAMS ((bfd *, const Elf32_External_Phdr *, Elf_Internal_Phdr *));
+ (bfd *, const Elf32_External_Phdr *, Elf_Internal_Phdr *);
extern void bfd_elf32_swap_phdr_out
- PARAMS ((bfd *, const Elf_Internal_Phdr *, Elf32_External_Phdr *));
+ (bfd *, const Elf_Internal_Phdr *, Elf32_External_Phdr *);
extern void bfd_elf32_swap_dyn_in
- PARAMS ((bfd *, const PTR, Elf_Internal_Dyn *));
+ (bfd *, const void *, Elf_Internal_Dyn *);
extern void bfd_elf32_swap_dyn_out
- PARAMS ((bfd *, const Elf_Internal_Dyn *, PTR));
+ (bfd *, const Elf_Internal_Dyn *, void *);
extern long bfd_elf32_slurp_symbol_table
- PARAMS ((bfd *, asymbol **, boolean));
-extern boolean bfd_elf32_write_shdrs_and_ehdr
- PARAMS ((bfd *));
+ (bfd *, asymbol **, bfd_boolean);
+extern bfd_boolean bfd_elf32_write_shdrs_and_ehdr
+ (bfd *);
extern int bfd_elf32_write_out_phdrs
- PARAMS ((bfd *, const Elf_Internal_Phdr *, unsigned int));
+ (bfd *, const Elf_Internal_Phdr *, unsigned int);
extern void bfd_elf32_write_relocs
- PARAMS ((bfd *, asection *, PTR));
-extern boolean bfd_elf32_slurp_reloc_table
- PARAMS ((bfd *, asection *, asymbol **, boolean));
-extern boolean bfd_elf32_add_dynamic_entry
- PARAMS ((struct bfd_link_info *, bfd_vma, bfd_vma));
-extern boolean bfd_elf32_link_create_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *));
-extern Elf_Internal_Rela *_bfd_elf32_link_read_relocs
- PARAMS ((bfd *, asection *, PTR, Elf_Internal_Rela *, boolean));
+ (bfd *, asection *, void *);
+extern bfd_boolean bfd_elf32_slurp_reloc_table
+ (bfd *, asection *, asymbol **, bfd_boolean);
extern const bfd_target *bfd_elf64_object_p
- PARAMS ((bfd *));
+ (bfd *);
extern const bfd_target *bfd_elf64_core_file_p
- PARAMS ((bfd *));
+ (bfd *);
extern char *bfd_elf64_core_file_failing_command
- PARAMS ((bfd *));
+ (bfd *);
extern int bfd_elf64_core_file_failing_signal
- PARAMS ((bfd *));
-extern boolean bfd_elf64_core_file_matches_executable_p
- PARAMS ((bfd *, bfd *));
-extern boolean bfd_elf64_bfd_link_add_symbols
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean bfd_elf64_bfd_final_link
- PARAMS ((bfd *, struct bfd_link_info *));
+ (bfd *);
+extern bfd_boolean bfd_elf64_core_file_matches_executable_p
+ (bfd *, bfd *);
extern void bfd_elf64_swap_symbol_in
- PARAMS ((bfd *, const PTR, const PTR, Elf_Internal_Sym *));
+ (bfd *, const void *, const void *, Elf_Internal_Sym *);
extern void bfd_elf64_swap_symbol_out
- PARAMS ((bfd *, const Elf_Internal_Sym *, PTR, PTR));
+ (bfd *, const Elf_Internal_Sym *, void *, void *);
extern void bfd_elf64_swap_reloc_in
- PARAMS ((bfd *, const Elf64_External_Rel *, Elf_Internal_Rel *));
+ (bfd *, const bfd_byte *, Elf_Internal_Rela *);
extern void bfd_elf64_swap_reloc_out
- PARAMS ((bfd *, const Elf_Internal_Rel *, Elf64_External_Rel *));
+ (bfd *, const Elf_Internal_Rela *, bfd_byte *);
extern void bfd_elf64_swap_reloca_in
- PARAMS ((bfd *, const Elf64_External_Rela *, Elf_Internal_Rela *));
+ (bfd *, const bfd_byte *, Elf_Internal_Rela *);
extern void bfd_elf64_swap_reloca_out
- PARAMS ((bfd *, const Elf_Internal_Rela *, Elf64_External_Rela *));
+ (bfd *, const Elf_Internal_Rela *, bfd_byte *);
extern void bfd_elf64_swap_phdr_in
- PARAMS ((bfd *, const Elf64_External_Phdr *, Elf_Internal_Phdr *));
+ (bfd *, const Elf64_External_Phdr *, Elf_Internal_Phdr *);
extern void bfd_elf64_swap_phdr_out
- PARAMS ((bfd *, const Elf_Internal_Phdr *, Elf64_External_Phdr *));
+ (bfd *, const Elf_Internal_Phdr *, Elf64_External_Phdr *);
extern void bfd_elf64_swap_dyn_in
- PARAMS ((bfd *, const PTR, Elf_Internal_Dyn *));
+ (bfd *, const void *, Elf_Internal_Dyn *);
extern void bfd_elf64_swap_dyn_out
- PARAMS ((bfd *, const Elf_Internal_Dyn *, PTR));
+ (bfd *, const Elf_Internal_Dyn *, void *);
extern long bfd_elf64_slurp_symbol_table
- PARAMS ((bfd *, asymbol **, boolean));
-extern boolean bfd_elf64_write_shdrs_and_ehdr
- PARAMS ((bfd *));
+ (bfd *, asymbol **, bfd_boolean);
+extern bfd_boolean bfd_elf64_write_shdrs_and_ehdr
+ (bfd *);
extern int bfd_elf64_write_out_phdrs
- PARAMS ((bfd *, const Elf_Internal_Phdr *, unsigned int));
+ (bfd *, const Elf_Internal_Phdr *, unsigned int);
extern void bfd_elf64_write_relocs
- PARAMS ((bfd *, asection *, PTR));
-extern boolean bfd_elf64_slurp_reloc_table
- PARAMS ((bfd *, asection *, asymbol **, boolean));
-extern boolean bfd_elf64_add_dynamic_entry
- PARAMS ((struct bfd_link_info *, bfd_vma, bfd_vma));
-extern boolean bfd_elf64_link_create_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *));
-extern Elf_Internal_Rela *_bfd_elf64_link_read_relocs
- PARAMS ((bfd *, asection *, PTR, Elf_Internal_Rela *, boolean));
-
-#define bfd_elf32_link_record_dynamic_symbol \
- _bfd_elf_link_record_dynamic_symbol
-#define bfd_elf64_link_record_dynamic_symbol \
- _bfd_elf_link_record_dynamic_symbol
-
-extern int elf_link_record_local_dynamic_symbol
- PARAMS ((struct bfd_link_info *, bfd *, long));
-#define _bfd_elf32_link_record_local_dynamic_symbol \
- elf_link_record_local_dynamic_symbol
-#define _bfd_elf64_link_record_local_dynamic_symbol \
- elf_link_record_local_dynamic_symbol
-
-extern boolean _bfd_elf_close_and_cleanup
- PARAMS ((bfd *));
+ (bfd *, asection *, void *);
+extern bfd_boolean bfd_elf64_slurp_reloc_table
+ (bfd *, asection *, asymbol **, bfd_boolean);
+
+extern bfd_boolean bfd_elf_link_add_symbols
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean _bfd_elf_add_dynamic_entry
+ (struct bfd_link_info *, bfd_vma, bfd_vma);
+
+extern bfd_boolean bfd_elf_link_record_dynamic_symbol
+ (struct bfd_link_info *, struct elf_link_hash_entry *);
+
+extern int bfd_elf_link_record_local_dynamic_symbol
+ (struct bfd_link_info *, bfd *, long);
+
+extern bfd_boolean _bfd_elf_close_and_cleanup
+ (bfd *);
extern bfd_reloc_status_type _bfd_elf_rel_vtable_reloc_fn
- PARAMS ((bfd *, arelent *, struct symbol_cache_entry *, PTR,
- asection *, bfd *, char **));
-
-extern boolean _bfd_elf32_gc_sections
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean _bfd_elf32_gc_common_finalize_got_offsets
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean _bfd_elf32_gc_common_final_link
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean _bfd_elf32_gc_record_vtinherit
- PARAMS ((bfd *, asection *, struct elf_link_hash_entry *, bfd_vma));
-extern boolean _bfd_elf32_gc_record_vtentry
- PARAMS ((bfd *, asection *, struct elf_link_hash_entry *, bfd_vma));
-
-extern boolean _bfd_elf64_gc_sections
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean _bfd_elf64_gc_common_finalize_got_offsets
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean _bfd_elf64_gc_common_final_link
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean _bfd_elf64_gc_record_vtinherit
- PARAMS ((bfd *, asection *, struct elf_link_hash_entry *, bfd_vma));
-extern boolean _bfd_elf64_gc_record_vtentry
- PARAMS ((bfd *, asection *, struct elf_link_hash_entry *, bfd_vma));
-
-extern boolean _bfd_elf32_reloc_symbol_deleted_p
- PARAMS ((bfd_vma, PTR));
-extern boolean _bfd_elf64_reloc_symbol_deleted_p
- PARAMS ((bfd_vma, PTR));
+ (bfd *, arelent *, struct bfd_symbol *, void *,
+ asection *, bfd *, char **);
+
+extern bfd_boolean bfd_elf_final_link
+ (bfd *, struct bfd_link_info *);
+
+extern bfd_boolean bfd_elf_gc_sections
+ (bfd *, struct bfd_link_info *);
+
+extern bfd_boolean bfd_elf_gc_record_vtinherit
+ (bfd *, asection *, struct elf_link_hash_entry *, bfd_vma);
+
+extern bfd_boolean bfd_elf_gc_record_vtentry
+ (bfd *, asection *, struct elf_link_hash_entry *, bfd_vma);
+
+extern bfd_boolean bfd_elf_gc_common_finalize_got_offsets
+ (bfd *, struct bfd_link_info *);
+
+extern bfd_boolean bfd_elf_gc_common_final_link
+ (bfd *, struct bfd_link_info *);
+
+extern bfd_boolean bfd_elf_reloc_symbol_deleted_p
+ (bfd_vma, void *);
/* Exported interface for writing elf corefile notes. */
extern char *elfcore_write_note
- PARAMS ((bfd *, char *, int *, const char *, int, const PTR, int));
+ (bfd *, char *, int *, const char *, int, const void *, int);
extern char *elfcore_write_prpsinfo
- PARAMS ((bfd *, char *, int *, const char *, const char *));
+ (bfd *, char *, int *, const char *, const char *);
extern char *elfcore_write_prstatus
- PARAMS ((bfd *, char *, int *, long, int, const PTR));
+ (bfd *, char *, int *, long, int, const void *);
extern char * elfcore_write_pstatus
- PARAMS ((bfd *, char *, int *, long, int, const PTR));
+ (bfd *, char *, int *, long, int, const void *);
extern char *elfcore_write_prfpreg
- PARAMS ((bfd *, char *, int *, const PTR, int));
+ (bfd *, char *, int *, const void *, int);
extern char *elfcore_write_prxfpreg
- PARAMS ((bfd *, char *, int *, const PTR, int));
+ (bfd *, char *, int *, const void *, int);
extern char *elfcore_write_lwpstatus
- PARAMS ((bfd *, char *, int *, long, int, const PTR));
+ (bfd *, char *, int *, long, int, const void *);
+
+extern bfd *_bfd_elf32_bfd_from_remote_memory
+ (bfd *templ, bfd_vma ehdr_vma, bfd_vma *loadbasep,
+ int (*target_read_memory) (bfd_vma, char *, int));
+extern bfd *_bfd_elf64_bfd_from_remote_memory
+ (bfd *templ, bfd_vma ehdr_vma, bfd_vma *loadbasep,
+ int (*target_read_memory) (bfd_vma, char *, int));
/* SH ELF specific routine. */
-extern boolean _sh_elf_set_mach_from_flags
- PARAMS ((bfd *));
+extern bfd_boolean _sh_elf_set_mach_from_flags
+ (bfd *);
+
+/* This is the condition under which finish_dynamic_symbol will be called.
+ If our finish_dynamic_symbol isn't called, we'll need to do something
+ about initializing any .plt and .got entries in relocate_section. */
+#define WILL_CALL_FINISH_DYNAMIC_SYMBOL(DYN, SHARED, H) \
+ ((DYN) \
+ && ((SHARED) \
+ || ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0) \
+ && ((H)->dynindx != -1 \
+ || ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0))
+
+/* This macro is to avoid lots of duplicated code in the body
+ of xxx_relocate_section() in the various elfxx-xxxx.c files. */
+#define RELOC_FOR_GLOBAL_SYMBOL(info, input_bfd, input_section, rel, \
+ r_symndx, symtab_hdr, sym_hashes, \
+ h, sec, relocation, \
+ unresolved_reloc, warned) \
+ do \
+ { \
+ /* It seems this can happen with erroneous or unsupported \
+ input (mixing a.out and elf in an archive, for example.) */ \
+ if (sym_hashes == NULL) \
+ return FALSE; \
+ \
+ h = sym_hashes[r_symndx - symtab_hdr->sh_info]; \
+ \
+ while (h->root.type == bfd_link_hash_indirect \
+ || h->root.type == bfd_link_hash_warning) \
+ h = (struct elf_link_hash_entry *) h->root.u.i.link; \
+ \
+ warned = FALSE; \
+ unresolved_reloc = FALSE; \
+ relocation = 0; \
+ if (h->root.type == bfd_link_hash_defined \
+ || h->root.type == bfd_link_hash_defweak) \
+ { \
+ sec = h->root.u.def.section; \
+ if (sec == NULL \
+ || sec->output_section == NULL) \
+ /* Set a flag that will be cleared later if we find a \
+ relocation value for this symbol. output_section \
+ is typically NULL for symbols satisfied by a shared \
+ library. */ \
+ unresolved_reloc = TRUE; \
+ else \
+ relocation = (h->root.u.def.value \
+ + sec->output_section->vma \
+ + sec->output_offset); \
+ } \
+ else if (h->root.type == bfd_link_hash_undefweak) \
+ ; \
+ else if (info->unresolved_syms_in_objects == RM_IGNORE \
+ && ELF_ST_VISIBILITY (h->other) == STV_DEFAULT) \
+ ; \
+ else \
+ { \
+ bfd_boolean err; \
+ err = (info->unresolved_syms_in_objects == RM_GENERATE_ERROR \
+ || ELF_ST_VISIBILITY (h->other) != STV_DEFAULT); \
+ if (!info->callbacks->undefined_symbol (info, \
+ h->root.root.string, \
+ input_bfd, \
+ input_section, \
+ rel->r_offset, err)) \
+ return FALSE; \
+ warned = TRUE; \
+ } \
+ } \
+ while (0)
#endif /* _LIBELF_H_ */
diff --git a/contrib/binutils/bfd/elf-eh-frame.c b/contrib/binutils/bfd/elf-eh-frame.c
index 62226c5..d3777b4 100644
--- a/contrib/binutils/bfd/elf-eh-frame.c
+++ b/contrib/binutils/bfd/elf-eh-frame.c
@@ -1,22 +1,22 @@
/* .eh_frame section optimization.
- Copyright 2001, 2002 Free Software Foundation, Inc.
+ Copyright 2001, 2002, 2003 Free Software Foundation, Inc.
Written by Jakub Jelinek <jakub@redhat.com>.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "bfd.h"
#include "sysdep.h"
@@ -26,129 +26,44 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define EH_FRAME_HDR_SIZE 8
-struct cie_header
-{
- unsigned int length;
- unsigned int id;
-};
-
-struct cie
-{
- struct cie_header hdr;
- unsigned char version;
- unsigned char augmentation[20];
- unsigned int code_align;
- int data_align;
- unsigned int ra_column;
- unsigned int augmentation_size;
- struct elf_link_hash_entry *personality;
- unsigned char per_encoding;
- unsigned char lsda_encoding;
- unsigned char fde_encoding;
- unsigned char initial_insn_length;
- unsigned char make_relative;
- unsigned char make_lsda_relative;
- unsigned char initial_instructions[50];
-};
-
-struct eh_cie_fde
-{
- unsigned int offset;
- unsigned int size;
- asection *sec;
- unsigned int new_offset;
- unsigned char fde_encoding;
- unsigned char lsda_encoding;
- unsigned char lsda_offset;
- unsigned char cie : 1;
- unsigned char removed : 1;
- unsigned char make_relative : 1;
- unsigned char make_lsda_relative : 1;
- unsigned char per_encoding_relative : 1;
-};
-
-struct eh_frame_sec_info
-{
- unsigned int count;
- unsigned int alloced;
- struct eh_cie_fde entry[1];
-};
-
-struct eh_frame_array_ent
-{
- bfd_vma initial_loc;
- bfd_vma fde;
-};
-
-struct eh_frame_hdr_info
-{
- struct cie last_cie;
- asection *last_cie_sec;
- unsigned int last_cie_offset;
- unsigned int fde_count, array_count;
- struct eh_frame_array_ent *array;
- /* TRUE if .eh_frame_hdr should contain the sorted search table.
- We build it if we successfully read all .eh_frame input sections
- and recognize them. */
- boolean table;
- boolean strip;
-};
-
-static bfd_vma read_unsigned_leb128
- PARAMS ((bfd *, char *, unsigned int *));
-static bfd_signed_vma read_signed_leb128
- PARAMS ((bfd *, char *, unsigned int *));
-static int get_DW_EH_PE_width
- PARAMS ((int, int));
-static bfd_vma read_value
- PARAMS ((bfd *, bfd_byte *, int));
-static void write_value
- PARAMS ((bfd *, bfd_byte *, bfd_vma, int));
-static int cie_compare
- PARAMS ((struct cie *, struct cie *));
-static int vma_compare
- PARAMS ((const PTR a, const PTR b));
-
/* Helper function for reading uleb128 encoded data. */
static bfd_vma
-read_unsigned_leb128 (abfd, buf, bytes_read_ptr)
- bfd *abfd ATTRIBUTE_UNUSED;
- char *buf;
- unsigned int *bytes_read_ptr;
+read_unsigned_leb128 (bfd *abfd ATTRIBUTE_UNUSED,
+ char *buf,
+ unsigned int *bytes_read_ptr)
{
- bfd_vma result;
- unsigned int num_read;
- int shift;
+ bfd_vma result;
+ unsigned int num_read;
+ int shift;
unsigned char byte;
- result = 0;
- shift = 0;
+ result = 0;
+ shift = 0;
num_read = 0;
do
{
byte = bfd_get_8 (abfd, (bfd_byte *) buf);
- buf ++;
- num_read ++;
+ buf++;
+ num_read++;
result |= (((bfd_vma) byte & 0x7f) << shift);
shift += 7;
}
while (byte & 0x80);
- * bytes_read_ptr = num_read;
+ *bytes_read_ptr = num_read;
return result;
}
/* Helper function for reading sleb128 encoded data. */
static bfd_signed_vma
-read_signed_leb128 (abfd, buf, bytes_read_ptr)
- bfd *abfd ATTRIBUTE_UNUSED;
- char *buf;
- unsigned int * bytes_read_ptr;
+read_signed_leb128 (bfd *abfd ATTRIBUTE_UNUSED,
+ char *buf,
+ unsigned int * bytes_read_ptr)
{
- bfd_vma result;
- int shift;
- int num_read;
+ bfd_vma result;
+ int shift;
+ int num_read;
unsigned char byte;
result = 0;
@@ -165,7 +80,7 @@ read_signed_leb128 (abfd, buf, bytes_read_ptr)
while (byte & 0x80);
if (byte & 0x40)
result |= (((bfd_vma) -1) << (shift - 7)) << 7;
- * bytes_read_ptr = num_read;
+ *bytes_read_ptr = num_read;
return result;
}
@@ -188,8 +103,7 @@ while (0)
/* Return 0 if either encoding is variable width, or not yet known to bfd. */
static
-int get_DW_EH_PE_width (encoding, ptr_size)
- int encoding, ptr_size;
+int get_DW_EH_PE_width (int encoding, int ptr_size)
{
/* DW_EH_PE_ values of 0x60 and 0x70 weren't defined at the time .eh_frame
was added to bfd. */
@@ -209,35 +123,47 @@ int get_DW_EH_PE_width (encoding, ptr_size)
return 0;
}
+#define get_DW_EH_PE_signed(encoding) (((encoding) & DW_EH_PE_signed) != 0)
+
/* Read a width sized value from memory. */
static bfd_vma
-read_value (abfd, buf, width)
- bfd *abfd;
- bfd_byte *buf;
- int width;
+read_value (bfd *abfd, bfd_byte *buf, int width, int is_signed)
{
bfd_vma value;
switch (width)
{
- case 2: value = bfd_get_16 (abfd, buf); break;
- case 4: value = bfd_get_32 (abfd, buf); break;
- case 8: value = bfd_get_64 (abfd, buf); break;
- default: BFD_FAIL (); return 0;
+ case 2:
+ if (is_signed)
+ value = bfd_get_signed_16 (abfd, buf);
+ else
+ value = bfd_get_16 (abfd, buf);
+ break;
+ case 4:
+ if (is_signed)
+ value = bfd_get_signed_32 (abfd, buf);
+ else
+ value = bfd_get_32 (abfd, buf);
+ break;
+ case 8:
+ if (is_signed)
+ value = bfd_get_signed_64 (abfd, buf);
+ else
+ value = bfd_get_64 (abfd, buf);
+ break;
+ default:
+ BFD_FAIL ();
+ return 0;
}
return value;
}
-
+
/* Store a width sized value to memory. */
static void
-write_value (abfd, buf, value, width)
- bfd *abfd;
- bfd_byte *buf;
- bfd_vma value;
- int width;
+write_value (bfd *abfd, bfd_byte *buf, bfd_vma value, int width)
{
switch (width)
{
@@ -251,8 +177,7 @@ write_value (abfd, buf, value, width)
/* Return zero if C1 and C2 CIEs can be merged. */
static
-int cie_compare (c1, c2)
- struct cie *c1, *c2;
+int cie_compare (struct cie *c1, struct cie *c2)
{
if (c1->hdr.length == c2->hdr.length
&& c1->version == c2->version
@@ -266,8 +191,7 @@ int cie_compare (c1, c2)
&& c1->per_encoding == c2->per_encoding
&& c1->lsda_encoding == c2->lsda_encoding
&& c1->fde_encoding == c2->fde_encoding
- && (c1->initial_insn_length
- == c2->initial_insn_length)
+ && c1->initial_insn_length == c2->initial_insn_length
&& memcmp (c1->initial_instructions,
c2->initial_instructions,
c1->initial_insn_length) == 0)
@@ -278,35 +202,32 @@ int cie_compare (c1, c2)
/* This function is called for each input file before the .eh_frame
section is relocated. It discards duplicate CIEs and FDEs for discarded
- functions. The function returns true iff any entries have been
+ functions. The function returns TRUE iff any entries have been
deleted. */
-boolean
-_bfd_elf_discard_section_eh_frame (abfd, info, sec, ehdrsec,
- reloc_symbol_deleted_p, cookie)
- bfd *abfd;
- struct bfd_link_info *info;
- asection *sec, *ehdrsec;
- boolean (*reloc_symbol_deleted_p) (bfd_vma, PTR);
- struct elf_reloc_cookie *cookie;
+bfd_boolean
+_bfd_elf_discard_section_eh_frame
+ (bfd *abfd, struct bfd_link_info *info, asection *sec,
+ bfd_boolean (*reloc_symbol_deleted_p) (bfd_vma, void *),
+ struct elf_reloc_cookie *cookie)
{
bfd_byte *ehbuf = NULL, *buf;
bfd_byte *last_cie, *last_fde;
struct cie_header hdr;
struct cie cie;
+ struct elf_link_hash_table *htab;
struct eh_frame_hdr_info *hdr_info;
struct eh_frame_sec_info *sec_info = NULL;
unsigned int leb128_tmp;
unsigned int cie_usage_count, last_cie_ndx, i, offset;
unsigned int make_relative, make_lsda_relative;
- Elf_Internal_Rela *rel;
bfd_size_type new_size;
unsigned int ptr_size;
if (sec->_raw_size == 0)
{
/* This file does not contain .eh_frame information. */
- return false;
+ return FALSE;
}
if ((sec->output_section != NULL
@@ -314,22 +235,19 @@ _bfd_elf_discard_section_eh_frame (abfd, info, sec, ehdrsec,
{
/* At least one of the sections is being discarded from the
link, so we should just ignore them. */
- return false;
+ return FALSE;
}
- BFD_ASSERT (elf_section_data (ehdrsec)->sec_info_type
- == ELF_INFO_TYPE_EH_FRAME_HDR);
- hdr_info = (struct eh_frame_hdr_info *)
- elf_section_data (ehdrsec)->sec_info;
+ htab = elf_hash_table (info);
+ hdr_info = &htab->eh_info;
/* Read the frame unwind information from abfd. */
- ehbuf = (bfd_byte *) bfd_malloc (sec->_raw_size);
+ ehbuf = bfd_malloc (sec->_raw_size);
if (ehbuf == NULL)
goto free_no_table;
- if (! bfd_get_section_contents (abfd, sec, ehbuf, (bfd_vma) 0,
- sec->_raw_size))
+ if (! bfd_get_section_contents (abfd, sec, ehbuf, 0, sec->_raw_size))
goto free_no_table;
if (sec->_raw_size >= 4
@@ -338,7 +256,7 @@ _bfd_elf_discard_section_eh_frame (abfd, info, sec, ehdrsec,
{
/* Empty .eh_frame section. */
free (ehbuf);
- return false;
+ return FALSE;
}
/* If .eh_frame section size doesn't fit into int, we cannot handle
@@ -365,7 +283,8 @@ _bfd_elf_discard_section_eh_frame (abfd, info, sec, ehdrsec,
#define ENSURE_NO_RELOCS(buf) \
if (cookie->rel < cookie->relend \
&& (cookie->rel->r_offset \
- < (bfd_size_type) ((buf) - ehbuf))) \
+ < (bfd_size_type) ((buf) - ehbuf)) \
+ && cookie->rel->r_info != 0) \
goto free_no_table
#define SKIP_RELOCS(buf) \
@@ -448,11 +367,15 @@ _bfd_elf_discard_section_eh_frame (abfd, info, sec, ehdrsec,
/* CIE */
if (last_cie != NULL)
{
- /* Now check if this CIE is identical to last CIE, in which case
- we can remove it, provided we adjust all FDEs.
- Also, it can be removed if we have removed all FDEs using
- that. */
- if (cie_compare (&cie, &hdr_info->last_cie) == 0
+ /* Now check if this CIE is identical to the last CIE,
+ in which case we can remove it provided we adjust
+ all FDEs. Also, it can be removed if we have removed
+ all FDEs using it. */
+ if ((!info->relocatable
+ && hdr_info->last_cie_sec
+ && (sec->output_section
+ == hdr_info->last_cie_sec->output_section)
+ && cie_compare (&cie, &hdr_info->last_cie) == 0)
|| cie_usage_count == 0)
{
new_size -= cie.hdr.length + 4;
@@ -506,6 +429,11 @@ _bfd_elf_discard_section_eh_frame (abfd, info, sec, ehdrsec,
}
read_uleb128 (cie.code_align, buf);
read_sleb128 (cie.data_align, buf);
+ /* Note - in DWARF2 the return address column is an unsigned byte.
+ In DWARF3 it is a ULEB128. We are following DWARF3. For most
+ ports this will not matter as the value will be less than 128.
+ For the others (eg FRV, SH, MMIX, IA64) they need a fixed GCC
+ which conforms to the DWARF3 standard. */
read_uleb128 (cie.ra_column, buf);
ENSURE_NO_RELOCS (buf);
cie.lsda_encoding = DW_EH_PE_omit;
@@ -550,10 +478,9 @@ _bfd_elf_discard_section_eh_frame (abfd, info, sec, ehdrsec,
+ ((buf - ehbuf + per_width - 1)
& ~((bfd_size_type) per_width - 1)));
ENSURE_NO_RELOCS (buf);
- rel = GET_RELOC (buf);
/* Ensure we have a reloc here, against
a global symbol. */
- if (rel != NULL)
+ if (GET_RELOC (buf) != NULL)
{
unsigned long r_symndx;
@@ -591,10 +518,16 @@ _bfd_elf_discard_section_eh_frame (abfd, info, sec, ehdrsec,
/* For shared libraries, try to get rid of as many RELATIVE relocs
as possible. */
if (info->shared
+ && (get_elf_backend_data (abfd)
+ ->elf_backend_can_make_relative_eh_frame
+ (abfd, info, sec))
&& (cie.fde_encoding & 0xf0) == DW_EH_PE_absptr)
cie.make_relative = 1;
if (info->shared
+ && (get_elf_backend_data (abfd)
+ ->elf_backend_can_make_lsda_relative_eh_frame
+ (abfd, info, sec))
&& (cie.lsda_encoding & 0xf0) == DW_EH_PE_absptr)
cie.make_lsda_relative = 1;
@@ -621,17 +554,15 @@ _bfd_elf_discard_section_eh_frame (abfd, info, sec, ehdrsec,
goto free_no_table;
ENSURE_NO_RELOCS (buf);
- rel = GET_RELOC (buf);
- if (rel == NULL)
+ if (GET_RELOC (buf) == NULL)
/* This should not happen. */
goto free_no_table;
if ((*reloc_symbol_deleted_p) (buf - ehbuf, cookie))
{
- /* This is a FDE against discarded section, it should
+ /* This is a FDE against a discarded section. It should
be deleted. */
new_size -= hdr.length + 4;
sec_info->entry[sec_info->count].removed = 1;
- memset (rel, 0, sizeof (*rel));
}
else
{
@@ -640,16 +571,15 @@ _bfd_elf_discard_section_eh_frame (abfd, info, sec, ehdrsec,
&& cie.make_relative == 0)
|| (cie.fde_encoding & 0xf0) == DW_EH_PE_aligned))
{
- /* If shared library uses absolute pointers
+ /* If a shared library uses absolute pointers
which we cannot turn into PC relative,
don't create the binary search table,
since it is affected by runtime relocations. */
- hdr_info->table = false;
+ hdr_info->table = FALSE;
}
cie_usage_count++;
hdr_info->fde_count++;
}
- cookie->rel = rel;
if (cie.lsda_encoding != DW_EH_PE_omit)
{
unsigned int dummy;
@@ -672,7 +602,7 @@ _bfd_elf_discard_section_eh_frame (abfd, info, sec, ehdrsec,
}
elf_section_data (sec)->sec_info = sec_info;
- elf_section_data (sec)->sec_info_type = ELF_INFO_TYPE_EH_FRAME;
+ sec->sec_info_type = ELF_INFO_TYPE_EH_FRAME;
/* Ok, now we can assign new offsets. */
offset = 0;
@@ -730,47 +660,36 @@ free_no_table:
free (ehbuf);
if (sec_info)
free (sec_info);
- hdr_info->table = false;
+ hdr_info->table = FALSE;
hdr_info->last_cie.hdr.length = 0;
- return false;
+ return FALSE;
}
/* This function is called for .eh_frame_hdr section after
_bfd_elf_discard_section_eh_frame has been called on all .eh_frame
input sections. It finalizes the size of .eh_frame_hdr section. */
-boolean
-_bfd_elf_discard_section_eh_frame_hdr (abfd, info, sec)
- bfd *abfd;
- struct bfd_link_info *info;
- asection *sec;
+bfd_boolean
+_bfd_elf_discard_section_eh_frame_hdr (bfd *abfd, struct bfd_link_info *info)
{
+ struct elf_link_hash_table *htab;
struct eh_frame_hdr_info *hdr_info;
- unsigned int ptr_size;
-
- ptr_size = (elf_elfheader (abfd)->e_ident[EI_CLASS]
- == ELFCLASS64) ? 8 : 4;
+ asection *sec;
- if ((elf_section_data (sec)->sec_info_type
- != ELF_INFO_TYPE_EH_FRAME_HDR)
- || ! info->eh_frame_hdr)
- {
- _bfd_strip_section_from_output (info, sec);
- return false;
- }
+ htab = elf_hash_table (info);
+ hdr_info = &htab->eh_info;
+ sec = hdr_info->hdr_sec;
+ if (sec == NULL)
+ return FALSE;
- hdr_info = (struct eh_frame_hdr_info *)
- elf_section_data (sec)->sec_info;
- if (hdr_info->strip)
- return false;
sec->_cooked_size = EH_FRAME_HDR_SIZE;
if (hdr_info->table)
sec->_cooked_size += 4 + hdr_info->fde_count * 8;
/* Request program headers to be recalculated. */
elf_tdata (abfd)->program_header_size = 0;
- elf_tdata (abfd)->eh_frame_hdr = true;
- return true;
+ elf_tdata (abfd)->eh_frame_hdr = sec;
+ return TRUE;
}
/* This function is called from size_dynamic_sections.
@@ -778,25 +697,24 @@ _bfd_elf_discard_section_eh_frame_hdr (abfd, info, sec)
because later on it is too late for calling _bfd_strip_section_from_output,
since dynamic symbol table has been sized. */
-boolean
-_bfd_elf_maybe_strip_eh_frame_hdr (info)
- struct bfd_link_info *info;
+bfd_boolean
+_bfd_elf_maybe_strip_eh_frame_hdr (struct bfd_link_info *info)
{
- asection *sec, *o;
+ asection *o;
bfd *abfd;
+ struct elf_link_hash_table *htab;
struct eh_frame_hdr_info *hdr_info;
- sec = bfd_get_section_by_name (elf_hash_table (info)->dynobj, ".eh_frame_hdr");
- if (sec == NULL || bfd_is_abs_section (sec->output_section))
- return true;
-
- hdr_info
- = bfd_zmalloc (sizeof (struct eh_frame_hdr_info));
- if (hdr_info == NULL)
- return false;
+ htab = elf_hash_table (info);
+ hdr_info = &htab->eh_info;
+ if (hdr_info->hdr_sec == NULL)
+ return TRUE;
- elf_section_data (sec)->sec_info = hdr_info;
- elf_section_data (sec)->sec_info_type = ELF_INFO_TYPE_EH_FRAME_HDR;
+ if (bfd_is_abs_section (hdr_info->hdr_sec->output_section))
+ {
+ hdr_info->hdr_sec = NULL;
+ return TRUE;
+ }
abfd = NULL;
if (info->eh_frame_hdr)
@@ -811,12 +729,13 @@ _bfd_elf_maybe_strip_eh_frame_hdr (info)
if (abfd == NULL)
{
- _bfd_strip_section_from_output (info, sec);
- hdr_info->strip = true;
+ _bfd_strip_section_from_output (info, hdr_info->hdr_sec);
+ hdr_info->hdr_sec = NULL;
+ return TRUE;
}
- else
- hdr_info->table = true;
- return true;
+
+ hdr_info->table = TRUE;
+ return TRUE;
}
/* Adjust an address in the .eh_frame section. Given OFFSET within
@@ -825,18 +744,16 @@ _bfd_elf_maybe_strip_eh_frame_hdr (info)
or to offset with dynamic relocation which is no longer needed. */
bfd_vma
-_bfd_elf_eh_frame_section_offset (output_bfd, sec, offset)
- bfd *output_bfd ATTRIBUTE_UNUSED;
- asection *sec;
- bfd_vma offset;
+_bfd_elf_eh_frame_section_offset (bfd *output_bfd ATTRIBUTE_UNUSED,
+ asection *sec,
+ bfd_vma offset)
{
struct eh_frame_sec_info *sec_info;
unsigned int lo, hi, mid;
- if (elf_section_data (sec)->sec_info_type != ELF_INFO_TYPE_EH_FRAME)
+ if (sec->sec_info_type != ELF_INFO_TYPE_EH_FRAME)
return offset;
- sec_info = (struct eh_frame_sec_info *)
- elf_section_data (sec)->sec_info;
+ sec_info = elf_section_data (sec)->sec_info;
if (offset >= sec->_raw_size)
return offset - (sec->_cooked_size - sec->_raw_size);
@@ -873,9 +790,8 @@ _bfd_elf_eh_frame_section_offset (output_bfd, sec, offset)
for run-time relocation against LSDA field. */
if (sec_info->entry[mid].make_lsda_relative
&& ! sec_info->entry[mid].cie
- && (offset
- == (sec_info->entry[mid].offset + 8
- + sec_info->entry[mid].lsda_offset)))
+ && (offset == (sec_info->entry[mid].offset + 8
+ + sec_info->entry[mid].lsda_offset)))
return (bfd_vma) -2;
return (offset + sec_info->entry[mid].new_offset
@@ -885,13 +801,14 @@ _bfd_elf_eh_frame_section_offset (output_bfd, sec, offset)
/* Write out .eh_frame section. This is called with the relocated
contents. */
-boolean
-_bfd_elf_write_section_eh_frame (abfd, sec, ehdrsec, contents)
- bfd *abfd;
- asection *sec, *ehdrsec;
- bfd_byte *contents;
+bfd_boolean
+_bfd_elf_write_section_eh_frame (bfd *abfd,
+ struct bfd_link_info *info,
+ asection *sec,
+ bfd_byte *contents)
{
struct eh_frame_sec_info *sec_info;
+ struct elf_link_hash_table *htab;
struct eh_frame_hdr_info *hdr_info;
unsigned int i;
bfd_byte *p, *buf;
@@ -902,26 +819,17 @@ _bfd_elf_write_section_eh_frame (abfd, sec, ehdrsec, contents)
ptr_size = (elf_elfheader (sec->owner)->e_ident[EI_CLASS]
== ELFCLASS64) ? 8 : 4;
- if (elf_section_data (sec)->sec_info_type != ELF_INFO_TYPE_EH_FRAME)
- return bfd_set_section_contents (abfd, sec->output_section,
- contents,
- (file_ptr) sec->output_offset,
- sec->_raw_size);
- sec_info = (struct eh_frame_sec_info *)
- elf_section_data (sec)->sec_info;
- hdr_info = NULL;
- if (ehdrsec
- && (elf_section_data (ehdrsec)->sec_info_type
- == ELF_INFO_TYPE_EH_FRAME_HDR))
- {
- hdr_info = (struct eh_frame_hdr_info *)
- elf_section_data (ehdrsec)->sec_info;
- if (hdr_info->table && hdr_info->array == NULL)
- hdr_info->array
- = bfd_malloc (hdr_info->fde_count * sizeof(*hdr_info->array));
- if (hdr_info->array == NULL)
- hdr_info = NULL;
- }
+ if (sec->sec_info_type != ELF_INFO_TYPE_EH_FRAME)
+ return bfd_set_section_contents (abfd, sec->output_section, contents,
+ sec->output_offset, sec->_raw_size);
+ sec_info = elf_section_data (sec)->sec_info;
+ htab = elf_hash_table (info);
+ hdr_info = &htab->eh_info;
+ if (hdr_info->table && hdr_info->array == NULL)
+ hdr_info->array
+ = bfd_malloc (hdr_info->fde_count * sizeof(*hdr_info->array));
+ if (hdr_info->array == NULL)
+ hdr_info = NULL;
p = contents;
for (i = 0; i < sec_info->count; ++i)
@@ -1005,7 +913,9 @@ _bfd_elf_write_section_eh_frame (abfd, sec, ehdrsec, contents)
{
bfd_vma value;
- value = read_value (abfd, buf, per_width);
+ value = read_value (abfd, buf, per_width,
+ get_DW_EH_PE_signed
+ (per_encoding));
value += (sec_info->entry[i].offset
- sec_info->entry[i].new_offset);
write_value (abfd, buf, value, per_width);
@@ -1034,14 +944,16 @@ _bfd_elf_write_section_eh_frame (abfd, sec, ehdrsec, contents)
unsigned int width;
buf = contents + sec_info->entry[i].offset;
- /* Skip length. */
+ /* Skip length. */
buf += 4;
bfd_put_32 (abfd,
sec_info->entry[i].new_offset + 4 - cie_offset, buf);
buf += 4;
width = get_DW_EH_PE_width (sec_info->entry[i].fde_encoding,
ptr_size);
- address = value = read_value (abfd, buf, width);
+ address = value = read_value (abfd, buf, width,
+ get_DW_EH_PE_signed
+ (sec_info->entry[i].fde_encoding));
if (value)
{
switch (sec_info->entry[i].fde_encoding & 0xf0)
@@ -1085,7 +997,9 @@ _bfd_elf_write_section_eh_frame (abfd, sec, ehdrsec, contents)
buf += sec_info->entry[i].lsda_offset;
width = get_DW_EH_PE_width (sec_info->entry[i].lsda_encoding,
ptr_size);
- value = read_value (abfd, buf, width);
+ value = read_value (abfd, buf, width,
+ get_DW_EH_PE_signed
+ (sec_info->entry[i].lsda_encoding));
if (value)
{
if ((sec_info->entry[i].lsda_encoding & 0xf0)
@@ -1121,6 +1035,42 @@ _bfd_elf_write_section_eh_frame (abfd, sec, ehdrsec, contents)
and 3xDW_CFA_nop as pad */
p += 16;
}
+ else
+ {
+ unsigned int alignment = 1 << sec->alignment_power;
+ unsigned int pad = sec->_cooked_size % alignment;
+
+ /* Don't pad beyond the raw size of the output section. It
+ can happen at the last input section. */
+ if (pad
+ && ((sec->output_offset + sec->_cooked_size + pad)
+ <= sec->output_section->_raw_size))
+ {
+ /* Find the last CIE/FDE. */
+ for (i = sec_info->count - 1; i > 0; i--)
+ if (! sec_info->entry[i].removed)
+ break;
+
+ /* The size of the last CIE/FDE must be at least 4. */
+ if (sec_info->entry[i].removed
+ || sec_info->entry[i].size < 4)
+ abort ();
+
+ pad = alignment - pad;
+
+ buf = contents + sec_info->entry[i].new_offset;
+
+ /* Update length. */
+ sec_info->entry[i].size += pad;
+ bfd_put_32 (abfd, sec_info->entry[i].size - 4, buf);
+
+ /* Pad it with DW_CFA_nop */
+ memset (p, 0, pad);
+ p += pad;
+
+ sec->_cooked_size += pad;
+ }
+ }
BFD_ASSERT ((bfd_size_type) (p - contents) == sec->_cooked_size);
@@ -1133,12 +1083,10 @@ _bfd_elf_write_section_eh_frame (abfd, sec, ehdrsec, contents)
VMA of FDE initial location. */
static int
-vma_compare (a, b)
- const PTR a;
- const PTR b;
+vma_compare (const void *a, const void *b)
{
- struct eh_frame_array_ent *p = (struct eh_frame_array_ent *) a;
- struct eh_frame_array_ent *q = (struct eh_frame_array_ent *) b;
+ const struct eh_frame_array_ent *p = a;
+ const struct eh_frame_array_ent *q = b;
if (p->initial_loc > q->initial_loc)
return 1;
if (p->initial_loc < q->initial_loc)
@@ -1166,55 +1114,58 @@ vma_compare (a, b)
fde_count x [encoded] initial_loc, fde
(array of encoded pairs containing
FDE initial_location field and FDE address,
- sorted by increasing initial_loc) */
+ sorted by increasing initial_loc). */
-boolean
-_bfd_elf_write_section_eh_frame_hdr (abfd, sec)
- bfd *abfd;
- asection *sec;
+bfd_boolean
+_bfd_elf_write_section_eh_frame_hdr (bfd *abfd, struct bfd_link_info *info)
{
+ struct elf_link_hash_table *htab;
struct eh_frame_hdr_info *hdr_info;
- unsigned int ptr_size;
+ asection *sec;
bfd_byte *contents;
asection *eh_frame_sec;
bfd_size_type size;
+ bfd_boolean retval;
+ bfd_vma encoded_eh_frame;
- ptr_size = (elf_elfheader (sec->owner)->e_ident[EI_CLASS]
- == ELFCLASS64) ? 8 : 4;
-
- BFD_ASSERT (elf_section_data (sec)->sec_info_type
- == ELF_INFO_TYPE_EH_FRAME_HDR);
- hdr_info = (struct eh_frame_hdr_info *)
- elf_section_data (sec)->sec_info;
- if (hdr_info->strip)
- return true;
+ htab = elf_hash_table (info);
+ hdr_info = &htab->eh_info;
+ sec = hdr_info->hdr_sec;
+ if (sec == NULL)
+ return TRUE;
size = EH_FRAME_HDR_SIZE;
if (hdr_info->array && hdr_info->array_count == hdr_info->fde_count)
size += 4 + hdr_info->fde_count * 8;
contents = bfd_malloc (size);
if (contents == NULL)
- return false;
+ return FALSE;
eh_frame_sec = bfd_get_section_by_name (abfd, ".eh_frame");
if (eh_frame_sec == NULL)
- return false;
+ {
+ free (contents);
+ return FALSE;
+ }
memset (contents, 0, EH_FRAME_HDR_SIZE);
- contents[0] = 1; /* Version */
- contents[1] = DW_EH_PE_pcrel | DW_EH_PE_sdata4; /* .eh_frame offset */
+ contents[0] = 1; /* Version. */
+ contents[1] = get_elf_backend_data (abfd)->elf_backend_encode_eh_address
+ (abfd, info, eh_frame_sec, 0, sec, 4,
+ &encoded_eh_frame); /* .eh_frame offset. */
+
if (hdr_info->array && hdr_info->array_count == hdr_info->fde_count)
{
- contents[2] = DW_EH_PE_udata4; /* FDE count encoding */
- contents[3] = DW_EH_PE_datarel | DW_EH_PE_sdata4; /* search table enc */
+ contents[2] = DW_EH_PE_udata4; /* FDE count encoding. */
+ contents[3] = DW_EH_PE_datarel | DW_EH_PE_sdata4; /* Search table enc. */
}
else
{
contents[2] = DW_EH_PE_omit;
contents[3] = DW_EH_PE_omit;
}
- bfd_put_32 (abfd, eh_frame_sec->vma - sec->output_section->vma - 4,
- contents + 4);
+ bfd_put_32 (abfd, encoded_eh_frame, contents + 4);
+
if (contents[2] != DW_EH_PE_omit)
{
unsigned int i;
@@ -1234,7 +1185,35 @@ _bfd_elf_write_section_eh_frame_hdr (abfd, sec)
}
}
- return bfd_set_section_contents (abfd, sec->output_section,
- contents, (file_ptr) sec->output_offset,
- sec->_cooked_size);
+ retval = bfd_set_section_contents (abfd, sec->output_section,
+ contents, (file_ptr) sec->output_offset,
+ sec->_cooked_size);
+ free (contents);
+ return retval;
+}
+
+/* Decide whether we can use a PC-relative encoding within the given
+ EH frame section. This is the default implementation. */
+
+bfd_boolean
+_bfd_elf_can_make_relative (bfd *input_bfd ATTRIBUTE_UNUSED,
+ struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ asection *eh_frame_section ATTRIBUTE_UNUSED)
+{
+ return TRUE;
+}
+
+/* Select an encoding for the given address. Preference is given to
+ PC-relative addressing modes. */
+
+bfd_byte
+_bfd_elf_encode_eh_address (bfd *abfd ATTRIBUTE_UNUSED,
+ struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ asection *osec, bfd_vma offset,
+ asection *loc_sec, bfd_vma loc_offset,
+ bfd_vma *encoded)
+{
+ *encoded = osec->vma + offset -
+ (loc_sec->output_section->vma + loc_sec->output_offset + loc_offset);
+ return DW_EH_PE_pcrel | DW_EH_PE_sdata4;
}
diff --git a/contrib/binutils/bfd/elf-strtab.c b/contrib/binutils/bfd/elf-strtab.c
index 7a993c2..673b9d7 100644
--- a/contrib/binutils/bfd/elf-strtab.c
+++ b/contrib/binutils/bfd/elf-strtab.c
@@ -1,5 +1,5 @@
/* ELF strtab with GC and suffix merging support.
- Copyright 2001, 2002 Free Software Foundation, Inc.
+ Copyright 2001, 2002, 2003 Free Software Foundation, Inc.
Written by Jakub Jelinek <jakub@redhat.com>.
This file is part of BFD, the Binary File Descriptor library.
@@ -30,15 +30,14 @@
struct elf_strtab_hash_entry
{
struct bfd_hash_entry root;
- /* Length of this entry. */
- unsigned int len;
+ /* Length of this entry. This includes the zero terminator. */
+ int len;
unsigned int refcount;
union {
/* Index within the merged section. */
bfd_size_type index;
- /* Entry this is a suffix of (if len is 0). */
+ /* Entry this is a suffix of (if len < 0). */
struct elf_strtab_hash_entry *suffix;
- struct elf_strtab_hash_entry *next;
} u;
};
@@ -57,53 +56,46 @@ struct elf_strtab_hash
struct elf_strtab_hash_entry **array;
};
-static struct bfd_hash_entry *elf_strtab_hash_newfunc
- PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-static int cmplengthentry PARAMS ((const PTR, const PTR));
-static int last4_eq PARAMS ((const PTR, const PTR));
-
/* Routine to create an entry in a section merge hashtab. */
static struct bfd_hash_entry *
-elf_strtab_hash_newfunc (entry, table, string)
- struct bfd_hash_entry *entry;
- struct bfd_hash_table *table;
- const char *string;
+elf_strtab_hash_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table,
+ const char *string)
{
- struct elf_strtab_hash_entry *ret = (struct elf_strtab_hash_entry *) entry;
-
/* Allocate the structure if it has not already been allocated by a
subclass. */
- if (ret == (struct elf_strtab_hash_entry *) NULL)
- ret = ((struct elf_strtab_hash_entry *)
- bfd_hash_allocate (table, sizeof (struct elf_strtab_hash_entry)));
- if (ret == (struct elf_strtab_hash_entry *) NULL)
+ if (entry == NULL)
+ entry = bfd_hash_allocate (table, sizeof (struct elf_strtab_hash_entry));
+ if (entry == NULL)
return NULL;
/* Call the allocation method of the superclass. */
- ret = ((struct elf_strtab_hash_entry *)
- bfd_hash_newfunc ((struct bfd_hash_entry *) ret, table, string));
+ entry = bfd_hash_newfunc (entry, table, string);
- if (ret)
+ if (entry)
{
/* Initialize the local fields. */
+ struct elf_strtab_hash_entry *ret;
+
+ ret = (struct elf_strtab_hash_entry *) entry;
ret->u.index = -1;
ret->refcount = 0;
ret->len = 0;
}
- return (struct bfd_hash_entry *)ret;
+ return entry;
}
/* Create a new hash table. */
struct elf_strtab_hash *
-_bfd_elf_strtab_init ()
+_bfd_elf_strtab_init (void)
{
struct elf_strtab_hash *table;
bfd_size_type amt = sizeof (struct elf_strtab_hash);
- table = (struct elf_strtab_hash *) bfd_malloc (amt);
+ table = bfd_malloc (amt);
if (table == NULL)
return NULL;
@@ -117,8 +109,7 @@ _bfd_elf_strtab_init ()
table->size = 1;
table->alloced = 64;
amt = sizeof (struct elf_strtab_hasn_entry *);
- table->array = (struct elf_strtab_hash_entry **)
- bfd_malloc (table->alloced * amt);
+ table->array = bfd_malloc (table->alloced * amt);
if (table->array == NULL)
{
free (table);
@@ -133,8 +124,7 @@ _bfd_elf_strtab_init ()
/* Free a strtab. */
void
-_bfd_elf_strtab_free (tab)
- struct elf_strtab_hash *tab;
+_bfd_elf_strtab_free (struct elf_strtab_hash *tab)
{
bfd_hash_table_free (&tab->table);
free (tab->array);
@@ -145,10 +135,9 @@ _bfd_elf_strtab_free (tab)
already present. */
bfd_size_type
-_bfd_elf_strtab_add (tab, str, copy)
- struct elf_strtab_hash *tab;
- const char *str;
- boolean copy;
+_bfd_elf_strtab_add (struct elf_strtab_hash *tab,
+ const char *str,
+ bfd_boolean copy)
{
register struct elf_strtab_hash_entry *entry;
@@ -159,7 +148,7 @@ _bfd_elf_strtab_add (tab, str, copy)
BFD_ASSERT (tab->sec_size == 0);
entry = (struct elf_strtab_hash_entry *)
- bfd_hash_lookup (&tab->table, str, true, copy);
+ bfd_hash_lookup (&tab->table, str, TRUE, copy);
if (entry == NULL)
return (bfd_size_type) -1;
@@ -168,12 +157,13 @@ _bfd_elf_strtab_add (tab, str, copy)
if (entry->len == 0)
{
entry->len = strlen (str) + 1;
+ /* 2G strings lose. */
+ BFD_ASSERT (entry->len > 0);
if (tab->size == tab->alloced)
{
bfd_size_type amt = sizeof (struct elf_strtab_hash_entry *);
tab->alloced *= 2;
- tab->array = (struct elf_strtab_hash_entry **)
- bfd_realloc (tab->array, tab->alloced * amt);
+ tab->array = bfd_realloc (tab->array, tab->alloced * amt);
if (tab->array == NULL)
return (bfd_size_type) -1;
}
@@ -185,9 +175,7 @@ _bfd_elf_strtab_add (tab, str, copy)
}
void
-_bfd_elf_strtab_addref (tab, idx)
- struct elf_strtab_hash *tab;
- bfd_size_type idx;
+_bfd_elf_strtab_addref (struct elf_strtab_hash *tab, bfd_size_type idx)
{
if (idx == 0 || idx == (bfd_size_type) -1)
return;
@@ -197,9 +185,7 @@ _bfd_elf_strtab_addref (tab, idx)
}
void
-_bfd_elf_strtab_delref (tab, idx)
- struct elf_strtab_hash *tab;
- bfd_size_type idx;
+_bfd_elf_strtab_delref (struct elf_strtab_hash *tab, bfd_size_type idx)
{
if (idx == 0 || idx == (bfd_size_type) -1)
return;
@@ -210,8 +196,7 @@ _bfd_elf_strtab_delref (tab, idx)
}
void
-_bfd_elf_strtab_clear_all_refs (tab)
- struct elf_strtab_hash *tab;
+_bfd_elf_strtab_clear_all_refs (struct elf_strtab_hash *tab)
{
bfd_size_type idx;
@@ -220,16 +205,13 @@ _bfd_elf_strtab_clear_all_refs (tab)
}
bfd_size_type
-_bfd_elf_strtab_size (tab)
- struct elf_strtab_hash *tab;
+_bfd_elf_strtab_size (struct elf_strtab_hash *tab)
{
return tab->sec_size ? tab->sec_size : tab->size;
}
bfd_size_type
-_bfd_elf_strtab_offset (tab, idx)
- struct elf_strtab_hash *tab;
- bfd_size_type idx;
+_bfd_elf_strtab_offset (struct elf_strtab_hash *tab, bfd_size_type idx)
{
struct elf_strtab_hash_entry *entry;
@@ -243,88 +225,80 @@ _bfd_elf_strtab_offset (tab, idx)
return tab->array[idx]->u.index;
}
-boolean
-_bfd_elf_strtab_emit (abfd, tab)
- register bfd *abfd;
- struct elf_strtab_hash *tab;
+bfd_boolean
+_bfd_elf_strtab_emit (register bfd *abfd, struct elf_strtab_hash *tab)
{
bfd_size_type off = 1, i;
if (bfd_bwrite ("", 1, abfd) != 1)
- return false;
+ return FALSE;
for (i = 1; i < tab->size; ++i)
{
register const char *str;
- register size_t len;
+ register unsigned int len;
- str = tab->array[i]->root.string;
- len = tab->array[i]->len;
BFD_ASSERT (tab->array[i]->refcount == 0);
- if (len == 0)
+ len = tab->array[i]->len;
+ if ((int) len < 0)
continue;
- if (bfd_bwrite ((PTR) str, (bfd_size_type) len, abfd) != len)
- return false;
+ str = tab->array[i]->root.string;
+ if (bfd_bwrite (str, len, abfd) != len)
+ return FALSE;
off += len;
}
BFD_ASSERT (off == tab->sec_size);
- return true;
+ return TRUE;
}
-/* Compare two elf_strtab_hash_entry structures. This is called via qsort. */
+/* Compare two elf_strtab_hash_entry structures. Called via qsort. */
static int
-cmplengthentry (a, b)
- const PTR a;
- const PTR b;
+strrevcmp (const void *a, const void *b)
{
- struct elf_strtab_hash_entry * A = *(struct elf_strtab_hash_entry **) a;
- struct elf_strtab_hash_entry * B = *(struct elf_strtab_hash_entry **) b;
-
- if (A->len < B->len)
- return 1;
- else if (A->len > B->len)
- return -1;
-
- return memcmp (A->root.string, B->root.string, A->len);
+ struct elf_strtab_hash_entry *A = *(struct elf_strtab_hash_entry **) a;
+ struct elf_strtab_hash_entry *B = *(struct elf_strtab_hash_entry **) b;
+ unsigned int lenA = A->len;
+ unsigned int lenB = B->len;
+ const unsigned char *s = A->root.string + lenA - 1;
+ const unsigned char *t = B->root.string + lenB - 1;
+ int l = lenA < lenB ? lenA : lenB;
+
+ while (l)
+ {
+ if (*s != *t)
+ return (int) *s - (int) *t;
+ s--;
+ t--;
+ l--;
+ }
+ return lenA - lenB;
}
-static int
-last4_eq (a, b)
- const PTR a;
- const PTR b;
+static inline int
+is_suffix (const struct elf_strtab_hash_entry *A,
+ const struct elf_strtab_hash_entry *B)
{
- struct elf_strtab_hash_entry * A = (struct elf_strtab_hash_entry *) a;
- struct elf_strtab_hash_entry * B = (struct elf_strtab_hash_entry *) b;
-
- if (memcmp (A->root.string + A->len - 5, B->root.string + B->len - 5, 4)
- != 0)
- /* This was a hashtable collision. */
- return 0;
-
if (A->len <= B->len)
/* B cannot be a suffix of A unless A is equal to B, which is guaranteed
not to be equal by the hash table. */
return 0;
return memcmp (A->root.string + (A->len - B->len),
- B->root.string, B->len - 5) == 0;
+ B->root.string, B->len - 1) == 0;
}
/* This function assigns final string table offsets for used strings,
merging strings matching suffixes of longer strings if possible. */
void
-_bfd_elf_strtab_finalize (tab)
- struct elf_strtab_hash *tab;
+_bfd_elf_strtab_finalize (struct elf_strtab_hash *tab)
{
- struct elf_strtab_hash_entry **array, **a, **end, *e;
- htab_t last4tab = NULL;
+ struct elf_strtab_hash_entry **array, **a, *e;
bfd_size_type size, amt;
- struct elf_strtab_hash_entry *last[256], **last_ptr[256];
/* GCC 2.91.66 (egcs-1.1.2) on i386 miscompiles this function when i is
a 64-bit bfd_size_type: a 64-bit target or --enable-64-bit-bfd.
@@ -332,105 +306,71 @@ _bfd_elf_strtab_finalize (tab)
cycles. */
size_t i;
- /* Now sort the strings by length, longest first. */
- array = NULL;
+ /* Sort the strings by suffix and length. */
amt = tab->size * sizeof (struct elf_strtab_hash_entry *);
- array = (struct elf_strtab_hash_entry **) bfd_malloc (amt);
+ array = bfd_malloc (amt);
if (array == NULL)
goto alloc_failure;
- memset (last, 0, sizeof (last));
- for (i = 0; i < 256; ++i)
- last_ptr[i] = &last[i];
for (i = 1, a = array; i < tab->size; ++i)
- if (tab->array[i]->refcount)
- *a++ = tab->array[i];
- else
- tab->array[i]->len = 0;
+ {
+ e = tab->array[i];
+ if (e->refcount)
+ {
+ *a++ = e;
+ /* Adjust the length to not include the zero terminator. */
+ e->len -= 1;
+ }
+ else
+ e->len = 0;
+ }
size = a - array;
+ if (size != 0)
+ {
+ qsort (array, size, sizeof (struct elf_strtab_hash_entry *), strrevcmp);
- qsort (array, size, sizeof (struct elf_strtab_hash_entry *), cmplengthentry);
+ /* Loop over the sorted array and merge suffixes. Start from the
+ end because we want eg.
- last4tab = htab_create_alloc (size * 4, NULL, last4_eq, NULL, calloc, free);
- if (last4tab == NULL)
- goto alloc_failure;
+ s1 -> "d"
+ s2 -> "bcd"
+ s3 -> "abcd"
- /* Now insert the strings into hash tables (strings with last 4 characters
- and strings with last character equal), look for longer strings which
- we're suffix of. */
- for (a = array, end = array + size; a < end; a++)
- {
- register hashval_t hash;
- unsigned int c;
- unsigned int j;
- const unsigned char *s;
- PTR *p;
-
- e = *a;
- if (e->len > 4)
- {
- s = e->root.string + e->len - 1;
- hash = 0;
- for (j = 0; j < 4; j++)
- {
- c = *--s;
- hash += c + (c << 17);
- hash ^= hash >> 2;
- }
- p = htab_find_slot_with_hash (last4tab, e, hash, INSERT);
- if (p == NULL)
- goto alloc_failure;
- if (*p)
- {
- struct elf_strtab_hash_entry *ent;
+ to end up as
- ent = (struct elf_strtab_hash_entry *) *p;
- e->u.suffix = ent;
- e->len = 0;
- continue;
- }
- else
- *p = (PTR) e;
- }
- else
- {
- struct elf_strtab_hash_entry *tem;
+ s3 -> "abcd"
+ s2 _____^
+ s1 _______^
- c = e->root.string[e->len - 2] & 0xff;
+ ie. we don't want s1 pointing into the old s2. */
+ e = *--a;
+ e->len += 1;
+ while (--a >= array)
+ {
+ struct elf_strtab_hash_entry *cmp = *a;
- for (tem = last[c]; tem; tem = tem->u.next)
- if (tem->len > e->len
- && memcmp (tem->root.string + (tem->len - e->len),
- e->root.string, e->len - 1) == 0)
- break;
- if (tem)
+ cmp->len += 1;
+ if (is_suffix (e, cmp))
{
- e->u.suffix = tem;
- e->len = 0;
- continue;
+ cmp->u.suffix = e;
+ cmp->len = -cmp->len;
}
+ else
+ e = cmp;
}
-
- c = e->root.string[e->len - 2] & 0xff;
- /* Put longest strings first. */
- *last_ptr[c] = e;
- last_ptr[c] = &e->u.next;
- e->u.next = NULL;
}
alloc_failure:
if (array)
free (array);
- if (last4tab)
- htab_delete (last4tab);
- /* Now assign positions to the strings we want to keep. */
+ /* Assign positions to the strings we want to keep. */
size = 1;
for (i = 1; i < tab->size; ++i)
{
e = tab->array[i];
- if (e->refcount && e->len)
+ if (e->refcount && e->len > 0)
{
e->u.index = size;
size += e->len;
@@ -439,12 +379,11 @@ alloc_failure:
tab->sec_size = size;
- /* And now adjust the rest. */
+ /* Adjust the rest. */
for (i = 1; i < tab->size; ++i)
{
e = tab->array[i];
- if (e->refcount && ! e->len)
- e->u.index = e->u.suffix->u.index
- + (e->u.suffix->len - strlen (e->root.string) - 1);
+ if (e->refcount && e->len < 0)
+ e->u.index = e->u.suffix->u.index + (e->u.suffix->len + e->len);
}
}
diff --git a/contrib/binutils/bfd/elf32-arc.c b/contrib/binutils/bfd/elf32-arc.c
index ff5c5f4..27c1639 100644
--- a/contrib/binutils/bfd/elf32-arc.c
+++ b/contrib/binutils/bfd/elf32-arc.c
@@ -1,5 +1,6 @@
/* ARC-specific support for 32-bit ELF
- Copyright 1994, 1995, 1997, 1999, 2001 Free Software Foundation, Inc.
+ Copyright 1994, 1995, 1997, 1999, 2001, 2002
+ Free Software Foundation, Inc.
Contributed by Doug Evans (dje@cygnus.com).
This file is part of BFD, the Binary File Descriptor library.
@@ -28,18 +29,18 @@
static reloc_howto_type *bfd_elf32_bfd_reloc_type_lookup
PARAMS ((bfd *abfd, bfd_reloc_code_real_type code));
static void arc_info_to_howto_rel
- PARAMS ((bfd *, arelent *, Elf32_Internal_Rel *));
-static boolean arc_elf_object_p
+ PARAMS ((bfd *, arelent *, Elf_Internal_Rela *));
+static bfd_boolean arc_elf_object_p
PARAMS ((bfd *));
static void arc_elf_final_write_processing
- PARAMS ((bfd *, boolean));
+ PARAMS ((bfd *, bfd_boolean));
static bfd_reloc_status_type arc_elf_b22_pcrel
PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
/* Try to minimize the amount of space occupied by relocation tables
on the ROM (not that the ROM won't be swamped by other ELF overhead). */
-#define USE_REL
+#define USE_REL 1
static reloc_howto_type elf_arc_howto_table[] =
{
@@ -48,60 +49,60 @@ static reloc_howto_type elf_arc_howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARC_NONE", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* A standard 32 bit relocation. */
HOWTO (R_ARC_32, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARC_32", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* A 26 bit absolute branch, right shifted by 2. */
HOWTO (R_ARC_B26, /* type */
2, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
26, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARC_B26", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0x00ffffff, /* src_mask */
0x00ffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* A relative 22 bit branch; bits 21-2 are stored in bits 26-7. */
HOWTO (R_ARC_B22_PCREL, /* type */
2, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
22, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
7, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
arc_elf_b22_pcrel, /* special_function */
"R_ARC_B22_PCREL", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0x07ffff80, /* src_mask */
0x07ffff80, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
};
/* Map BFD reloc types to ARC ELF reloc types. */
@@ -141,7 +142,7 @@ static void
arc_info_to_howto_rel (abfd, cache_ptr, dst)
bfd *abfd ATTRIBUTE_UNUSED;
arelent *cache_ptr;
- Elf32_Internal_Rel *dst;
+ Elf_Internal_Rela *dst;
{
unsigned int r_type;
@@ -152,7 +153,7 @@ arc_info_to_howto_rel (abfd, cache_ptr, dst)
/* Set the right machine number for an ARC ELF file. */
-static boolean
+static bfd_boolean
arc_elf_object_p (abfd)
bfd *abfd;
{
@@ -188,7 +189,7 @@ arc_elf_object_p (abfd)
static void
arc_elf_final_write_processing (abfd, linker)
bfd *abfd;
- boolean linker ATTRIBUTE_UNUSED;
+ bfd_boolean linker ATTRIBUTE_UNUSED;
{
unsigned long val;
@@ -225,7 +226,7 @@ arc_elf_b22_pcrel (abfd, reloc_entry, symbol, data, input_section,
{
/* If linking, back up the final symbol address by the address of the
reloc. This cannot be accomplished by setting the pcrel_offset
- field to true, as bfd_install_relocation will detect this and refuse
+ field to TRUE, as bfd_install_relocation will detect this and refuse
to install the offset in the first place, but bfd_perform_relocation
will still insist on removing it. */
if (output_bfd == (bfd *) NULL)
diff --git a/contrib/binutils/bfd/elf32-arm.h b/contrib/binutils/bfd/elf32-arm.h
index bb193ab..8c1acc0 100644
--- a/contrib/binutils/bfd/elf32-arm.h
+++ b/contrib/binutils/bfd/elf32-arm.h
@@ -1,5 +1,6 @@
/* 32-bit ELF support for ARM
- Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004
+ Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -17,16 +18,20 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+#ifndef USE_REL
+#define USE_REL 0
+#endif
+
typedef unsigned long int insn32;
typedef unsigned short int insn16;
-static boolean elf32_arm_set_private_flags
+static bfd_boolean elf32_arm_set_private_flags
PARAMS ((bfd *, flagword));
-static boolean elf32_arm_copy_private_bfd_data
+static bfd_boolean elf32_arm_copy_private_bfd_data
PARAMS ((bfd *, bfd *));
-static boolean elf32_arm_merge_private_bfd_data
+static bfd_boolean elf32_arm_merge_private_bfd_data
PARAMS ((bfd *, bfd *));
-static boolean elf32_arm_print_private_bfd_data
+static bfd_boolean elf32_arm_print_private_bfd_data
PARAMS ((bfd *, PTR));
static int elf32_arm_get_symbol_type
PARAMS (( Elf_Internal_Sym *, int));
@@ -42,10 +47,6 @@ static struct elf_link_hash_entry *find_thumb_glue
PARAMS ((struct bfd_link_info *, const char *, bfd *));
static struct elf_link_hash_entry *find_arm_glue
PARAMS ((struct bfd_link_info *, const char *, bfd *));
-static void record_arm_to_thumb_glue
- PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *));
-static void record_thumb_to_arm_glue
- PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *));
static void elf32_arm_post_process_headers
PARAMS ((bfd *, struct bfd_link_info *));
static int elf32_arm_to_thumb_stub
@@ -54,45 +55,60 @@ static int elf32_arm_to_thumb_stub
static int elf32_thumb_to_arm_stub
PARAMS ((struct bfd_link_info *, const char *, bfd *, bfd *, asection *,
bfd_byte *, asection *, bfd_vma, bfd_signed_vma, bfd_vma));
-static boolean elf32_arm_relocate_section
+static bfd_boolean elf32_arm_relocate_section
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
Elf_Internal_Rela *, Elf_Internal_Sym *, asection **));
static asection * elf32_arm_gc_mark_hook
PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
struct elf_link_hash_entry *, Elf_Internal_Sym *));
-static boolean elf32_arm_gc_sweep_hook
+static bfd_boolean elf32_arm_gc_sweep_hook
PARAMS ((bfd *, struct bfd_link_info *, asection *,
const Elf_Internal_Rela *));
-static boolean elf32_arm_check_relocs
+static bfd_boolean elf32_arm_check_relocs
PARAMS ((bfd *, struct bfd_link_info *, asection *,
const Elf_Internal_Rela *));
-static boolean elf32_arm_find_nearest_line
+static bfd_boolean elf32_arm_find_nearest_line
PARAMS ((bfd *, asection *, asymbol **, bfd_vma, const char **,
const char **, unsigned int *));
-static boolean elf32_arm_adjust_dynamic_symbol
+static bfd_boolean elf32_arm_adjust_dynamic_symbol
PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *));
-static boolean elf32_arm_size_dynamic_sections
+static bfd_boolean elf32_arm_size_dynamic_sections
PARAMS ((bfd *, struct bfd_link_info *));
-static boolean elf32_arm_finish_dynamic_symbol
+static bfd_boolean elf32_arm_finish_dynamic_symbol
PARAMS ((bfd *, struct bfd_link_info *, struct elf_link_hash_entry *,
Elf_Internal_Sym *));
-static boolean elf32_arm_finish_dynamic_sections
+static bfd_boolean elf32_arm_finish_dynamic_sections
PARAMS ((bfd *, struct bfd_link_info *));
static struct bfd_hash_entry * elf32_arm_link_hash_newfunc
PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-#ifdef USE_REL
+#if USE_REL
static void arm_add_to_rel
PARAMS ((bfd *, bfd_byte *, reloc_howto_type *, bfd_signed_vma));
#endif
+static bfd_boolean allocate_dynrelocs
+ PARAMS ((struct elf_link_hash_entry *h, PTR inf));
+static bfd_boolean create_got_section
+ PARAMS ((bfd * dynobj, struct bfd_link_info * info));
+static bfd_boolean elf32_arm_create_dynamic_sections
+ PARAMS ((bfd * dynobj, struct bfd_link_info * info));
+static enum elf_reloc_type_class elf32_arm_reloc_type_class
+ PARAMS ((const Elf_Internal_Rela *));
+static bfd_boolean elf32_arm_object_p
+ PARAMS ((bfd *));
-boolean bfd_elf32_arm_allocate_interworking_sections
+#ifndef ELFARM_NABI_C_INCLUDED
+static void record_arm_to_thumb_glue
+ PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *));
+static void record_thumb_to_arm_glue
+ PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *));
+bfd_boolean bfd_elf32_arm_allocate_interworking_sections
PARAMS ((struct bfd_link_info *));
-boolean bfd_elf32_arm_get_bfd_for_interworking
+bfd_boolean bfd_elf32_arm_get_bfd_for_interworking
PARAMS ((bfd *, struct bfd_link_info *));
-boolean bfd_elf32_arm_process_before_allocation
+bfd_boolean bfd_elf32_arm_process_before_allocation
PARAMS ((bfd *, struct bfd_link_info *, int));
-static enum elf_reloc_type_class elf32_arm_reloc_type_class
- PARAMS ((const Elf_Internal_Rela *));
+#endif
+
#define INTERWORK_FLAG(abfd) (elf_elfheader (abfd)->e_flags & EF_ARM_INTERWORK)
@@ -110,6 +126,12 @@ static enum elf_reloc_type_class elf32_arm_reloc_type_class
section. */
#define ELF_DYNAMIC_INTERPRETER "/usr/lib/ld.so.1"
+#ifdef FOUR_WORD_PLT
+
+/* The size in bytes of the special first entry in the procedure
+ linkage table. */
+#define PLT_HEADER_SIZE 16
+
/* The size in bytes of an entry in the procedure linkage table. */
#define PLT_ENTRY_SIZE 16
@@ -117,23 +139,56 @@ static enum elf_reloc_type_class elf32_arm_reloc_type_class
this. It is set up so that any shared library function that is
called before the relocation has been set up calls the dynamic
linker first. */
-static const bfd_vma elf32_arm_plt0_entry [PLT_ENTRY_SIZE / 4] =
+static const bfd_vma elf32_arm_plt0_entry [PLT_HEADER_SIZE / 4] =
+ {
+ 0xe52de004, /* str lr, [sp, #-4]! */
+ 0xe59fe010, /* ldr lr, [pc, #16] */
+ 0xe08fe00e, /* add lr, pc, lr */
+ 0xe5bef008, /* ldr pc, [lr, #8]! */
+ };
+
+/* Subsequent entries in a procedure linkage table look like
+ this. */
+static const bfd_vma elf32_arm_plt_entry [PLT_ENTRY_SIZE / 4] =
+ {
+ 0xe28fc600, /* add ip, pc, #NN */
+ 0xe28cca00, /* add ip, ip, #NN */
+ 0xe5bcf000, /* ldr pc, [ip, #NN]! */
+ 0x00000000, /* unused */
+ };
+
+#else
+
+/* The size in bytes of the special first entry in the procedure
+ linkage table. */
+#define PLT_HEADER_SIZE 20
+
+/* The size in bytes of an entry in the procedure linkage table. */
+#define PLT_ENTRY_SIZE 12
+
+/* The first entry in a procedure linkage table looks like
+ this. It is set up so that any shared library function that is
+ called before the relocation has been set up calls the dynamic
+ linker first. */
+static const bfd_vma elf32_arm_plt0_entry [PLT_HEADER_SIZE / 4] =
{
- 0xe52de004, /* str lr, [sp, #-4]! */
- 0xe59fe010, /* ldr lr, [pc, #16] */
- 0xe08fe00e, /* add lr, pc, lr */
- 0xe5bef008 /* ldr pc, [lr, #8]! */
+ 0xe52de004, /* str lr, [sp, #-4]! */
+ 0xe59fe004, /* ldr lr, [pc, #4] */
+ 0xe08fe00e, /* add lr, pc, lr */
+ 0xe5bef008, /* ldr pc, [lr, #8]! */
+ 0x00000000, /* &GOT[0] - . */
};
/* Subsequent entries in a procedure linkage table look like
this. */
static const bfd_vma elf32_arm_plt_entry [PLT_ENTRY_SIZE / 4] =
- {
- 0xe59fc004, /* ldr ip, [pc, #4] */
- 0xe08fc00c, /* add ip, pc, ip */
- 0xe59cf000, /* ldr pc, [ip] */
- 0x00000000 /* offset to symbol in got */
- };
+ {
+ 0xe28fc600, /* add ip, pc, #0xNN00000 */
+ 0xe28cca00, /* add ip, ip, #0xNN000 */
+ 0xe5bcf000, /* ldr pc, [ip, #0xNNN]! */
+ };
+
+#endif
/* The ARM linker needs to keep track of the number of relocs that it
decides to copy in check_relocs for each symbol. This is so that
@@ -143,10 +198,10 @@ static const bfd_vma elf32_arm_plt_entry [PLT_ENTRY_SIZE / 4] =
/* This structure keeps track of the number of PC relative relocs we
have copied for a given symbol. */
-struct elf32_arm_pcrel_relocs_copied
+struct elf32_arm_relocs_copied
{
/* Next section. */
- struct elf32_arm_pcrel_relocs_copied * next;
+ struct elf32_arm_relocs_copied * next;
/* A section in dynobj. */
asection * section;
/* Number of relocs copied in this section. */
@@ -159,18 +214,14 @@ struct elf32_arm_link_hash_entry
struct elf_link_hash_entry root;
/* Number of PC relative relocs copied for this symbol. */
- struct elf32_arm_pcrel_relocs_copied * pcrel_relocs_copied;
+ struct elf32_arm_relocs_copied * relocs_copied;
};
-/* Declare this now that the above structures are defined. */
-static boolean elf32_arm_discard_copies
- PARAMS ((struct elf32_arm_link_hash_entry *, PTR));
-
/* Traverse an arm ELF linker hash table. */
#define elf32_arm_link_hash_traverse(table, func, info) \
(elf_link_hash_traverse \
(&(table)->root, \
- (boolean (*) PARAMS ((struct elf_link_hash_entry *, PTR))) (func), \
+ (bfd_boolean (*) PARAMS ((struct elf_link_hash_entry *, PTR))) (func), \
(info)))
/* Get the ARM elf linker hash table from a link_info structure. */
@@ -183,18 +234,30 @@ struct elf32_arm_link_hash_table
/* The main hash table. */
struct elf_link_hash_table root;
- /* The size in bytes of the section containg the Thumb-to-ARM glue. */
+ /* The size in bytes of the section containing the Thumb-to-ARM glue. */
bfd_size_type thumb_glue_size;
- /* The size in bytes of the section containg the ARM-to-Thumb glue. */
+ /* The size in bytes of the section containing the ARM-to-Thumb glue. */
bfd_size_type arm_glue_size;
- /* An arbitary input BFD chosen to hold the glue sections. */
+ /* An arbitrary input BFD chosen to hold the glue sections. */
bfd * bfd_of_glue_owner;
/* A boolean indicating whether knowledge of the ARM's pipeline
length should be applied by the linker. */
int no_pipeline_knowledge;
+
+ /* Short-cuts to get to dynamic linker sections. */
+ asection *sgot;
+ asection *sgotplt;
+ asection *srelgot;
+ asection *splt;
+ asection *srelplt;
+ asection *sdynbss;
+ asection *srelbss;
+
+ /* Small local sym to section mapping cache. */
+ struct sym_sec_cache sym_sec;
};
/* Create an entry in an ARM ELF linker hash table. */
@@ -222,11 +285,120 @@ elf32_arm_link_hash_newfunc (entry, table, string)
_bfd_elf_link_hash_newfunc ((struct bfd_hash_entry *) ret,
table, string));
if (ret != (struct elf32_arm_link_hash_entry *) NULL)
- ret->pcrel_relocs_copied = NULL;
+ ret->relocs_copied = NULL;
return (struct bfd_hash_entry *) ret;
}
+/* Create .got, .gotplt, and .rel.got sections in DYNOBJ, and set up
+ shortcuts to them in our hash table. */
+
+static bfd_boolean
+create_got_section (dynobj, info)
+ bfd *dynobj;
+ struct bfd_link_info *info;
+{
+ struct elf32_arm_link_hash_table *htab;
+
+ if (! _bfd_elf_create_got_section (dynobj, info))
+ return FALSE;
+
+ htab = elf32_arm_hash_table (info);
+ htab->sgot = bfd_get_section_by_name (dynobj, ".got");
+ htab->sgotplt = bfd_get_section_by_name (dynobj, ".got.plt");
+ if (!htab->sgot || !htab->sgotplt)
+ abort ();
+
+ htab->srelgot = bfd_make_section (dynobj, ".rel.got");
+ if (htab->srelgot == NULL
+ || ! bfd_set_section_flags (dynobj, htab->srelgot,
+ (SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS
+ | SEC_IN_MEMORY | SEC_LINKER_CREATED
+ | SEC_READONLY))
+ || ! bfd_set_section_alignment (dynobj, htab->srelgot, 2))
+ return FALSE;
+ return TRUE;
+}
+
+/* Create .plt, .rel.plt, .got, .got.plt, .rel.got, .dynbss, and
+ .rel.bss sections in DYNOBJ, and set up shortcuts to them in our
+ hash table. */
+
+static bfd_boolean
+elf32_arm_create_dynamic_sections (dynobj, info)
+ bfd *dynobj;
+ struct bfd_link_info *info;
+{
+ struct elf32_arm_link_hash_table *htab;
+
+ htab = elf32_arm_hash_table (info);
+ if (!htab->sgot && !create_got_section (dynobj, info))
+ return FALSE;
+
+ if (!_bfd_elf_create_dynamic_sections (dynobj, info))
+ return FALSE;
+
+ htab->splt = bfd_get_section_by_name (dynobj, ".plt");
+ htab->srelplt = bfd_get_section_by_name (dynobj, ".rel.plt");
+ htab->sdynbss = bfd_get_section_by_name (dynobj, ".dynbss");
+ if (!info->shared)
+ htab->srelbss = bfd_get_section_by_name (dynobj, ".rel.bss");
+
+ if (!htab->splt || !htab->srelplt || !htab->sdynbss
+ || (!info->shared && !htab->srelbss))
+ abort ();
+
+ return TRUE;
+}
+
+/* Copy the extra info we tack onto an elf_link_hash_entry. */
+
+static void
+elf32_arm_copy_indirect_symbol (const struct elf_backend_data *bed,
+ struct elf_link_hash_entry *dir,
+ struct elf_link_hash_entry *ind)
+{
+ struct elf32_arm_link_hash_entry *edir, *eind;
+
+ edir = (struct elf32_arm_link_hash_entry *) dir;
+ eind = (struct elf32_arm_link_hash_entry *) ind;
+
+ if (eind->relocs_copied != NULL)
+ {
+ if (edir->relocs_copied != NULL)
+ {
+ struct elf32_arm_relocs_copied **pp;
+ struct elf32_arm_relocs_copied *p;
+
+ if (ind->root.type == bfd_link_hash_indirect)
+ abort ();
+
+ /* Add reloc counts against the weak sym to the strong sym
+ list. Merge any entries against the same section. */
+ for (pp = &eind->relocs_copied; (p = *pp) != NULL; )
+ {
+ struct elf32_arm_relocs_copied *q;
+
+ for (q = edir->relocs_copied; q != NULL; q = q->next)
+ if (q->section == p->section)
+ {
+ q->count += p->count;
+ *pp = p->next;
+ break;
+ }
+ if (q == NULL)
+ pp = &p->next;
+ }
+ *pp = edir->relocs_copied;
+ }
+
+ edir->relocs_copied = eind->relocs_copied;
+ eind->relocs_copied = NULL;
+ }
+
+ _bfd_elf_link_hash_copy_indirect (bed, dir, ind);
+}
+
/* Create an ARM elf linker hash table. */
static struct bfd_link_hash_table *
@@ -247,10 +419,18 @@ elf32_arm_link_hash_table_create (abfd)
return NULL;
}
+ ret->sgot = NULL;
+ ret->sgotplt = NULL;
+ ret->srelgot = NULL;
+ ret->splt = NULL;
+ ret->srelplt = NULL;
+ ret->sdynbss = NULL;
+ ret->srelbss = NULL;
ret->thumb_glue_size = 0;
ret->arm_glue_size = 0;
ret->bfd_of_glue_owner = NULL;
ret->no_pipeline_knowledge = 0;
+ ret->sym_sec.abfd = NULL;
return &ret->root.root;
}
@@ -278,7 +458,7 @@ find_thumb_glue (link_info, name, input_bfd)
sprintf (tmp_name, THUMB2ARM_GLUE_ENTRY_NAME, name);
hash = elf_link_hash_lookup
- (&(hash_table)->root, tmp_name, false, false, true);
+ (&(hash_table)->root, tmp_name, FALSE, FALSE, TRUE);
if (hash == NULL)
/* xgettext:c-format */
@@ -313,7 +493,7 @@ find_arm_glue (link_info, name, input_bfd)
sprintf (tmp_name, ARM2THUMB_GLUE_ENTRY_NAME, name);
myh = elf_link_hash_lookup
- (&(hash_table)->root, tmp_name, false, false, true);
+ (&(hash_table)->root, tmp_name, FALSE, FALSE, TRUE);
if (myh == NULL)
/* xgettext:c-format */
@@ -360,14 +540,8 @@ static const insn16 t2a1_bx_pc_insn = 0x4778;
static const insn16 t2a2_noop_insn = 0x46c0;
static const insn32 t2a3_b_insn = 0xea000000;
-static const insn16 t2a1_push_insn = 0xb540;
-static const insn16 t2a2_ldr_insn = 0x4e03;
-static const insn16 t2a3_mov_insn = 0x46fe;
-static const insn16 t2a4_bx_insn = 0x4730;
-static const insn32 t2a5_pop_insn = 0xe8bd4040;
-static const insn32 t2a6_bx_insn = 0xe12fff1e;
-
-boolean
+#ifndef ELFARM_NABI_C_INCLUDED
+bfd_boolean
bfd_elf32_arm_allocate_interworking_sections (info)
struct bfd_link_info * info;
{
@@ -411,7 +585,7 @@ bfd_elf32_arm_allocate_interworking_sections (info)
s->contents = foo;
}
- return true;
+ return TRUE;
}
static void
@@ -445,7 +619,7 @@ record_arm_to_thumb_glue (link_info, h)
sprintf (tmp_name, ARM2THUMB_GLUE_ENTRY_NAME, name);
myh = elf_link_hash_lookup
- (&(globals)->root, tmp_name, false, false, true);
+ (&(globals)->root, tmp_name, FALSE, FALSE, TRUE);
if (myh != NULL)
{
@@ -461,7 +635,7 @@ record_arm_to_thumb_glue (link_info, h)
val = globals->arm_glue_size + 1;
_bfd_generic_link_add_one_symbol (link_info, globals->bfd_of_glue_owner,
tmp_name, BSF_GLOBAL, s, val,
- NULL, true, false, &bh);
+ NULL, TRUE, FALSE, &bh);
free (tmp_name);
@@ -502,7 +676,7 @@ record_thumb_to_arm_glue (link_info, h)
sprintf (tmp_name, THUMB2ARM_GLUE_ENTRY_NAME, name);
myh = elf_link_hash_lookup
- (&(hash_table)->root, tmp_name, false, false, true);
+ (&(hash_table)->root, tmp_name, FALSE, FALSE, TRUE);
if (myh != NULL)
{
@@ -515,7 +689,7 @@ record_thumb_to_arm_glue (link_info, h)
val = hash_table->thumb_glue_size + 1;
_bfd_generic_link_add_one_symbol (link_info, hash_table->bfd_of_glue_owner,
tmp_name, BSF_GLOBAL, s, val,
- NULL, true, false, &bh);
+ NULL, TRUE, FALSE, &bh);
/* If we mark it 'Thumb', the disassembler will do a better job. */
myh = (struct elf_link_hash_entry *) bh;
@@ -539,7 +713,7 @@ record_thumb_to_arm_glue (link_info, h)
val = hash_table->thumb_glue_size + 4,
_bfd_generic_link_add_one_symbol (link_info, hash_table->bfd_of_glue_owner,
tmp_name, BSF_LOCAL, s, val,
- NULL, true, false, &bh);
+ NULL, TRUE, FALSE, &bh);
free (tmp_name);
@@ -551,7 +725,7 @@ record_thumb_to_arm_glue (link_info, h)
/* Add the glue sections to ABFD. This function is called from the
linker scripts in ld/emultempl/{armelf}.em. */
-boolean
+bfd_boolean
bfd_elf32_arm_add_glue_sections_to_bfd (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -561,8 +735,8 @@ bfd_elf32_arm_add_glue_sections_to_bfd (abfd, info)
/* If we are only performing a partial
link do not bother adding the glue. */
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
sec = bfd_get_section_by_name (abfd, ARM2THUMB_GLUE_SECTION_NAME);
@@ -578,7 +752,7 @@ bfd_elf32_arm_add_glue_sections_to_bfd (abfd, info)
if (sec == NULL
|| !bfd_set_section_flags (abfd, sec, flags)
|| !bfd_set_section_alignment (abfd, sec, 2))
- return false;
+ return FALSE;
/* Set the gc mark to prevent the section from being removed by garbage
collection, despite the fact that no relocs refer to this section. */
@@ -596,19 +770,19 @@ bfd_elf32_arm_add_glue_sections_to_bfd (abfd, info)
if (sec == NULL
|| !bfd_set_section_flags (abfd, sec, flags)
|| !bfd_set_section_alignment (abfd, sec, 2))
- return false;
+ return FALSE;
sec->gc_mark = 1;
}
- return true;
+ return TRUE;
}
/* Select a BFD to be used to hold the sections used by the glue code.
This function is called from the linker scripts in ld/emultempl/
{armelf/pe}.em */
-boolean
+bfd_boolean
bfd_elf32_arm_get_bfd_for_interworking (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -617,23 +791,23 @@ bfd_elf32_arm_get_bfd_for_interworking (abfd, info)
/* If we are only performing a partial link
do not bother getting a bfd to hold the glue. */
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
globals = elf32_arm_hash_table (info);
BFD_ASSERT (globals != NULL);
if (globals->bfd_of_glue_owner != NULL)
- return true;
+ return TRUE;
/* Save the bfd for later use. */
globals->bfd_of_glue_owner = abfd;
- return true;
+ return TRUE;
}
-boolean
+bfd_boolean
bfd_elf32_arm_process_before_allocation (abfd, link_info, no_pipeline_knowledge)
bfd *abfd;
struct bfd_link_info *link_info;
@@ -649,8 +823,8 @@ bfd_elf32_arm_process_before_allocation (abfd, link_info, no_pipeline_knowledge)
/* If we are only performing a partial link do not bother
to construct any glue. */
- if (link_info->relocateable)
- return true;
+ if (link_info->relocatable)
+ return TRUE;
/* Here we have a bfd that is to be included on the link. We have a hook
to do reloc rummaging, before section sizes are nailed down. */
@@ -665,7 +839,7 @@ bfd_elf32_arm_process_before_allocation (abfd, link_info, no_pipeline_knowledge)
sec = abfd->sections;
if (sec == NULL)
- return true;
+ return TRUE;
for (; sec != NULL; sec = sec->next)
{
@@ -676,8 +850,8 @@ bfd_elf32_arm_process_before_allocation (abfd, link_info, no_pipeline_knowledge)
/* Load the relocs. */
internal_relocs
- = _bfd_elf32_link_read_relocs (abfd, sec, (PTR) NULL,
- (Elf_Internal_Rela *) NULL, false);
+ = _bfd_elf_link_read_relocs (abfd, sec, (PTR) NULL,
+ (Elf_Internal_Rela *) NULL, FALSE);
if (internal_relocs == NULL)
goto error_return;
@@ -768,7 +942,7 @@ bfd_elf32_arm_process_before_allocation (abfd, link_info, no_pipeline_knowledge)
internal_relocs = NULL;
}
- return true;
+ return TRUE;
error_return:
if (contents != NULL
@@ -778,8 +952,9 @@ error_return:
&& elf_section_data (sec)->relocs != internal_relocs)
free (internal_relocs);
- return false;
+ return FALSE;
}
+#endif
/* The thumb form of a long branch is a bit finicky, because the offset
encoding is split over two fields, each in it's own instruction. They
@@ -788,7 +963,7 @@ error_return:
instruction.
It takes two thumb instructions to encode the target address. Each has
- 11 bits to invest. The upper 11 bits are stored in one (identifed by
+ 11 bits to invest. The upper 11 bits are stored in one (identified by
H-0.. see below), the lower 11 bits are stored in the other (identified
by H-1).
@@ -862,7 +1037,7 @@ elf32_thumb_to_arm_stub (info, name, input_bfd, output_bfd, input_section,
myh = find_thumb_glue (info, name, input_bfd);
if (myh == NULL)
- return false;
+ return FALSE;
globals = elf32_arm_hash_table (info);
@@ -891,7 +1066,7 @@ elf32_thumb_to_arm_stub (info, name, input_bfd, output_bfd, input_section,
(_(" first occurrence: %s: thumb call to arm"),
bfd_archive_filename (input_bfd));
- return false;
+ return FALSE;
}
--my_offset;
@@ -925,13 +1100,16 @@ elf32_thumb_to_arm_stub (info, name, input_bfd, output_bfd, input_section,
BFD_ASSERT (my_offset <= globals->thumb_glue_size);
- /* Now go back and fix up the original BL insn to point
- to here. */
- ret_offset = (s->output_offset
- + my_offset
- - (input_section->output_offset
- + offset + addend)
- - 8);
+ /* Now go back and fix up the original BL insn to point to here. */
+ ret_offset =
+ /* Address of where the stub is located. */
+ (s->output_section->vma + s->output_offset + my_offset)
+ /* Address of where the BL is located. */
+ - (input_section->output_section->vma + input_section->output_offset + offset)
+ /* Addend in the relocation. */
+ - addend
+ /* Biassing for PC-relative addressing. */
+ - 8;
tmp = bfd_get_32 (input_bfd, hit_data
- input_section->vma);
@@ -940,7 +1118,7 @@ elf32_thumb_to_arm_stub (info, name, input_bfd, output_bfd, input_section,
(bfd_vma) insert_thumb_branch (tmp, ret_offset),
hit_data - input_section->vma);
- return true;
+ return TRUE;
}
/* Arm code calling a Thumb function. */
@@ -968,7 +1146,7 @@ elf32_arm_to_thumb_stub (info, name, input_bfd, output_bfd, input_section,
myh = find_arm_glue (info, name, input_bfd);
if (myh == NULL)
- return false;
+ return FALSE;
globals = elf32_arm_hash_table (info);
@@ -1028,7 +1206,7 @@ elf32_arm_to_thumb_stub (info, name, input_bfd, output_bfd, input_section,
bfd_put_32 (output_bfd, (bfd_vma) tmp, hit_data - input_section->vma);
- return true;
+ return TRUE;
}
/* Perform a relocation as part of a final link. */
@@ -1089,7 +1267,7 @@ elf32_arm_final_link_relocate (howto, input_bfd, output_bfd,
local_got_offsets = elf_local_got_offsets (input_bfd);
r_symndx = ELF32_R_SYM (rel->r_info);
-#ifdef USE_REL
+#if USE_REL
addend = bfd_get_32 (input_bfd, hit_data) & howto->src_mask;
if (addend & ((howto->src_mask + 1) >> 1))
@@ -1115,19 +1293,50 @@ elf32_arm_final_link_relocate (howto, input_bfd, output_bfd,
#ifndef OLD_ARM_ABI
case R_ARM_XPC25:
#endif
+ case R_ARM_PLT32:
+ /* r_symndx will be zero only for relocs against symbols
+ from removed linkonce sections, or sections discarded by
+ a linker script. */
+ if (r_symndx == 0)
+ return bfd_reloc_ok;
+
+ /* Handle relocations which should use the PLT entry. ABS32/REL32
+ will use the symbol's value, which may point to a PLT entry, but we
+ don't need to handle that here. If we created a PLT entry, all
+ branches in this object should go to it. */
+ if ((r_type != R_ARM_ABS32 && r_type != R_ARM_REL32)
+ && h != NULL
+ && splt != NULL
+ && h->plt.offset != (bfd_vma) -1)
+ {
+ /* If we've created a .plt section, and assigned a PLT entry to
+ this function, it should not be known to bind locally. If
+ it were, we would have cleared the PLT entry. */
+ BFD_ASSERT (!SYMBOL_CALLS_LOCAL (info, h));
+
+ value = (splt->output_section->vma
+ + splt->output_offset
+ + h->plt.offset);
+ return _bfd_final_link_relocate (howto, input_bfd, input_section,
+ contents, rel->r_offset, value,
+ (bfd_vma) 0);
+ }
+
/* When generating a shared object, these relocations are copied
into the output file to be resolved at run time. */
if (info->shared
- && r_symndx != 0
- && (r_type != R_ARM_PC24
- || (h != NULL
- && h->dynindx != -1
- && (! info->symbolic
- || (h->elf_link_hash_flags
- & ELF_LINK_HASH_DEF_REGULAR) == 0))))
+ && (input_section->flags & SEC_ALLOC)
+ && (r_type != R_ARM_REL32
+ || !SYMBOL_CALLS_LOCAL (info, h))
+ && (h == NULL
+ || ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak)
+ && r_type != R_ARM_PC24
+ && r_type != R_ARM_PLT32)
{
- Elf_Internal_Rel outrel;
- boolean skip, relocate;
+ Elf_Internal_Rela outrel;
+ bfd_byte *loc;
+ bfd_boolean skip, relocate;
if (sreloc == NULL)
{
@@ -1149,52 +1358,38 @@ elf32_arm_final_link_relocate (howto, input_bfd, output_bfd,
BFD_ASSERT (sreloc != NULL);
}
- skip = false;
- relocate = false;
+ skip = FALSE;
+ relocate = FALSE;
outrel.r_offset =
_bfd_elf_section_offset (output_bfd, info, input_section,
rel->r_offset);
if (outrel.r_offset == (bfd_vma) -1)
- skip = true;
+ skip = TRUE;
else if (outrel.r_offset == (bfd_vma) -2)
- skip = true, relocate = true;
+ skip = TRUE, relocate = TRUE;
outrel.r_offset += (input_section->output_section->vma
+ input_section->output_offset);
if (skip)
memset (&outrel, 0, sizeof outrel);
- else if (r_type == R_ARM_PC24)
- {
- BFD_ASSERT (h != NULL && h->dynindx != -1);
- if ((input_section->flags & SEC_ALLOC) == 0)
- relocate = true;
- outrel.r_info = ELF32_R_INFO (h->dynindx, R_ARM_PC24);
- }
+ else if (h != NULL
+ && h->dynindx != -1
+ && (!info->shared
+ || !info->symbolic
+ || (h->elf_link_hash_flags
+ & ELF_LINK_HASH_DEF_REGULAR) == 0))
+ outrel.r_info = ELF32_R_INFO (h->dynindx, r_type);
else
{
- if (h == NULL
- || ((info->symbolic || h->dynindx == -1)
- && (h->elf_link_hash_flags
- & ELF_LINK_HASH_DEF_REGULAR) != 0))
- {
- relocate = true;
- outrel.r_info = ELF32_R_INFO (0, R_ARM_RELATIVE);
- }
- else
- {
- BFD_ASSERT (h->dynindx != -1);
- if ((input_section->flags & SEC_ALLOC) == 0)
- relocate = true;
- outrel.r_info = ELF32_R_INFO (h->dynindx, R_ARM_ABS32);
- }
+ /* This symbol is local, or marked to become local. */
+ relocate = TRUE;
+ outrel.r_info = ELF32_R_INFO (0, R_ARM_RELATIVE);
}
- bfd_elf32_swap_reloc_out (output_bfd, &outrel,
- (((Elf32_External_Rel *)
- sreloc->contents)
- + sreloc->reloc_count));
- ++sreloc->reloc_count;
+ loc = sreloc->contents;
+ loc += sreloc->reloc_count++ * sizeof (Elf32_External_Rel);
+ bfd_elf32_swap_reloc_out (output_bfd, &outrel, loc);
/* If this reloc is against an external symbol, we do not want to
fiddle with the addend. Otherwise, we need to include the symbol
@@ -1212,6 +1407,7 @@ elf32_arm_final_link_relocate (howto, input_bfd, output_bfd,
case R_ARM_XPC25: /* Arm BLX instruction. */
#endif
case R_ARM_PC24: /* Arm B/BL instruction */
+ case R_ARM_PLT32:
#ifndef OLD_ARM_ABI
if (r_type == R_ARM_XPC25)
{
@@ -1365,7 +1561,7 @@ elf32_arm_final_link_relocate (howto, input_bfd, output_bfd,
case R_ARM_THM_ABS5:
/* Support ldr and str instructions for the thumb. */
-#ifdef USE_REL
+#if USE_REL
/* Need to refetch addend. */
addend = bfd_get_16 (input_bfd, hit_data) & howto->src_mask;
/* ??? Need to determine shift amount from operand size. */
@@ -1388,16 +1584,16 @@ elf32_arm_final_link_relocate (howto, input_bfd, output_bfd,
case R_ARM_THM_PC22:
/* Thumb BL (branch long instruction). */
{
- bfd_vma relocation;
- boolean overflow = false;
- bfd_vma upper_insn = bfd_get_16 (input_bfd, hit_data);
- bfd_vma lower_insn = bfd_get_16 (input_bfd, hit_data + 2);
+ bfd_vma relocation;
+ bfd_boolean overflow = FALSE;
+ bfd_vma upper_insn = bfd_get_16 (input_bfd, hit_data);
+ bfd_vma lower_insn = bfd_get_16 (input_bfd, hit_data + 2);
bfd_signed_vma reloc_signed_max = ((1 << (howto->bitsize - 1)) - 1) >> howto->rightshift;
bfd_signed_vma reloc_signed_min = ~ reloc_signed_max;
- bfd_vma check;
+ bfd_vma check;
bfd_signed_vma signed_check;
-#ifdef USE_REL
+#if USE_REL
/* Need to refetch the addend and squish the two 11 bit pieces
together. */
{
@@ -1471,7 +1667,7 @@ elf32_arm_final_link_relocate (howto, input_bfd, output_bfd,
/* Assumes two's complement. */
if (signed_check > reloc_signed_max || signed_check < reloc_signed_min)
- overflow = true;
+ overflow = TRUE;
#ifndef OLD_ARM_ABI
if (r_type == R_ARM_THM_XPC22
@@ -1497,33 +1693,36 @@ elf32_arm_final_link_relocate (howto, input_bfd, output_bfd,
case R_ARM_THM_PC11:
/* Thumb B (branch) instruction). */
{
- bfd_vma relocation;
+ bfd_signed_vma relocation;
bfd_signed_vma reloc_signed_max = (1 << (howto->bitsize - 1)) - 1;
bfd_signed_vma reloc_signed_min = ~ reloc_signed_max;
- bfd_vma check;
bfd_signed_vma signed_check;
-#ifdef USE_REL
+#if USE_REL
/* Need to refetch addend. */
addend = bfd_get_16 (input_bfd, hit_data) & howto->src_mask;
- /* ??? Need to determine shift amount from operand size. */
- addend >>= howto->rightshift;
+ if (addend & ((howto->src_mask + 1) >> 1))
+ {
+ signed_addend = -1;
+ signed_addend &= ~ howto->src_mask;
+ signed_addend |= addend;
+ }
+ else
+ signed_addend = addend;
+ /* The value in the insn has been right shifted. We need to
+ undo this, so that we can perform the address calculation
+ in terms of bytes. */
+ signed_addend <<= howto->rightshift;
#endif
- relocation = value + addend;
+ relocation = value + signed_addend;
relocation -= (input_section->output_section->vma
+ input_section->output_offset
+ rel->r_offset);
- check = relocation >> howto->rightshift;
-
- /* If this is a signed value, the rightshift just
- dropped leading 1 bits (assuming twos complement). */
- if ((bfd_signed_vma) relocation >= 0)
- signed_check = check;
- else
- signed_check = check | ~((bfd_vma) -1 >> howto->rightshift);
-
+ relocation >>= howto->rightshift;
+ signed_check = relocation;
+ relocation &= howto->dst_mask;
relocation |= (bfd_get_16 (input_bfd, hit_data) & (~ howto->dst_mask));
bfd_put_16 (input_bfd, relocation, hit_data);
@@ -1596,13 +1795,17 @@ elf32_arm_final_link_relocate (howto, input_bfd, output_bfd,
if (h != NULL)
{
bfd_vma off;
+ bfd_boolean dyn;
off = h->got.offset;
BFD_ASSERT (off != (bfd_vma) -1);
+ dyn = globals->root.dynamic_sections_created;
- if (!elf_hash_table (info)->dynamic_sections_created ||
- (info->shared && (info->symbolic || h->dynindx == -1)
- && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR)))
+ if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info->shared, h)
+ || (info->shared
+ && SYMBOL_REFERENCES_LOCAL (info, h))
+ || (ELF_ST_VISIBILITY (h->other)
+ && h->root.type == bfd_link_hash_undefweak))
{
/* This is actually a static link, or it is a -Bsymbolic link
and the symbol is defined locally. We must initialize this
@@ -1652,7 +1855,8 @@ elf32_arm_final_link_relocate (howto, input_bfd, output_bfd,
if (info->shared)
{
asection * srelgot;
- Elf_Internal_Rel outrel;
+ Elf_Internal_Rela outrel;
+ bfd_byte *loc;
srelgot = bfd_get_section_by_name (dynobj, ".rel.got");
BFD_ASSERT (srelgot != NULL);
@@ -1661,11 +1865,9 @@ elf32_arm_final_link_relocate (howto, input_bfd, output_bfd,
+ sgot->output_offset
+ off);
outrel.r_info = ELF32_R_INFO (0, R_ARM_RELATIVE);
- bfd_elf32_swap_reloc_out (output_bfd, &outrel,
- (((Elf32_External_Rel *)
- srelgot->contents)
- + srelgot->reloc_count));
- ++srelgot->reloc_count;
+ loc = srelgot->contents;
+ loc += srelgot->reloc_count++ * sizeof (Elf32_External_Rel);
+ bfd_elf32_swap_reloc_out (output_bfd, &outrel, loc);
}
local_got_offsets[r_symndx] |= 1;
@@ -1678,36 +1880,6 @@ elf32_arm_final_link_relocate (howto, input_bfd, output_bfd,
contents, rel->r_offset, value,
(bfd_vma) 0);
- case R_ARM_PLT32:
- /* Relocation is to the entry for this symbol in the
- procedure linkage table. */
-
- /* Resolve a PLT32 reloc against a local symbol directly,
- without using the procedure linkage table. */
- if (h == NULL)
- return _bfd_final_link_relocate (howto, input_bfd, input_section,
- contents, rel->r_offset, value,
- (bfd_vma) 0);
-
- if (h->plt.offset == (bfd_vma) -1)
- /* We didn't make a PLT entry for this symbol. This
- happens when statically linking PIC code, or when
- using -Bsymbolic. */
- return _bfd_final_link_relocate (howto, input_bfd, input_section,
- contents, rel->r_offset, value,
- (bfd_vma) 0);
-
- BFD_ASSERT(splt != NULL);
- if (splt == NULL)
- return bfd_reloc_notsupported;
-
- value = (splt->output_section->vma
- + splt->output_offset
- + h->plt.offset);
- return _bfd_final_link_relocate (howto, input_bfd, input_section,
- contents, rel->r_offset, value,
- (bfd_vma) 0);
-
case R_ARM_SBREL32:
return bfd_reloc_notsupported;
@@ -1737,7 +1909,7 @@ elf32_arm_final_link_relocate (howto, input_bfd, output_bfd,
}
}
-#ifdef USE_REL
+#if USE_REL
/* Add INCREMENT to the reloc (of type HOWTO) at ADDRESS. */
static void
arm_add_to_rel (abfd, address, howto, increment)
@@ -1811,27 +1983,27 @@ arm_add_to_rel (abfd, address, howto, increment)
#endif /* USE_REL */
/* Relocate an ARM ELF section. */
-static boolean
+static bfd_boolean
elf32_arm_relocate_section (output_bfd, info, input_bfd, input_section,
contents, relocs, local_syms, local_sections)
- bfd * output_bfd;
- struct bfd_link_info * info;
- bfd * input_bfd;
- asection * input_section;
- bfd_byte * contents;
- Elf_Internal_Rela * relocs;
- Elf_Internal_Sym * local_syms;
- asection ** local_sections;
+ bfd *output_bfd;
+ struct bfd_link_info *info;
+ bfd *input_bfd;
+ asection *input_section;
+ bfd_byte *contents;
+ Elf_Internal_Rela *relocs;
+ Elf_Internal_Sym *local_syms;
+ asection **local_sections;
{
- Elf_Internal_Shdr * symtab_hdr;
- struct elf_link_hash_entry ** sym_hashes;
- Elf_Internal_Rela * rel;
- Elf_Internal_Rela * relend;
- const char * name;
-
-#ifndef USE_REL
- if (info->relocateable)
- return true;
+ Elf_Internal_Shdr *symtab_hdr;
+ struct elf_link_hash_entry **sym_hashes;
+ Elf_Internal_Rela *rel;
+ Elf_Internal_Rela *relend;
+ const char *name;
+
+#if !USE_REL
+ if (info->relocatable)
+ return TRUE;
#endif
symtab_hdr = & elf_tdata (input_bfd)->symtab_hdr;
@@ -1858,18 +2030,13 @@ elf32_arm_relocate_section (output_bfd, info, input_bfd, input_section,
|| r_type == R_ARM_GNU_VTINHERIT)
continue;
-#ifdef USE_REL
- elf32_arm_info_to_howto (input_bfd, & bfd_reloc,
- (Elf_Internal_Rel *) rel);
-#else
elf32_arm_info_to_howto (input_bfd, & bfd_reloc, rel);
-#endif
howto = bfd_reloc.howto;
-#ifdef USE_REL
- if (info->relocateable)
+#if USE_REL
+ if (info->relocatable)
{
- /* This is a relocateable link. We don't have to change
+ /* This is a relocatable link. We don't have to change
anything, unless the reloc is against a section symbol,
in which case we have to adjust according to where the
section symbol winds up in the output section. */
@@ -1899,7 +2066,7 @@ elf32_arm_relocate_section (output_bfd, info, input_bfd, input_section,
{
sym = local_syms + r_symndx;
sec = local_sections[r_symndx];
-#ifdef USE_REL
+#if USE_REL
relocation = (sec->output_section->vma
+ sec->output_offset
+ sym->st_value);
@@ -1916,7 +2083,7 @@ elf32_arm_relocate_section (output_bfd, info, input_bfd, input_section,
bfd_archive_filename (input_bfd),
bfd_get_section_name (input_bfd, input_section),
(long) rel->r_offset, howto->name);
- return false;
+ return FALSE;
}
value = bfd_get_32 (input_bfd, contents + rel->r_offset);
@@ -1940,24 +2107,21 @@ elf32_arm_relocate_section (output_bfd, info, input_bfd, input_section,
bfd_put_32 (input_bfd, value, contents + rel->r_offset);
}
#else
- relocation = _bfd_elf_rela_local_sym (output_bfd, sym, sec, rel);
+ relocation = _bfd_elf_rela_local_sym (output_bfd, sym, &sec, rel);
#endif
}
else
{
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
-
- while ( h->root.type == bfd_link_hash_indirect
- || h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
-
- if ( h->root.type == bfd_link_hash_defined
- || h->root.type == bfd_link_hash_defweak)
+ bfd_boolean warned;
+ bfd_boolean unresolved_reloc;
+
+ RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
+ r_symndx, symtab_hdr, sym_hashes,
+ h, sec, relocation,
+ unresolved_reloc, warned);
+
+ if (unresolved_reloc || relocation != 0)
{
- int relocation_needed = 1;
-
- sec = h->root.u.def.section;
-
/* In these cases, we don't need the relocation value.
We check specially because in some obscure cases
sec->output_section will be NULL. */
@@ -1966,11 +2130,14 @@ elf32_arm_relocate_section (output_bfd, info, input_bfd, input_section,
case R_ARM_PC24:
case R_ARM_ABS32:
case R_ARM_THM_PC22:
+ case R_ARM_PLT32:
+
if (info->shared
&& (
- (!info->symbolic && h->dynindx != -1)
+ (!info->symbolic && h->dynindx != -1)
|| (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0
)
+ && ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
&& ((input_section->flags & SEC_ALLOC) != 0
/* DWARF will emit R_ARM_ABS32 relocations in its
sections against symbols defined externally
@@ -1980,63 +2147,34 @@ elf32_arm_relocate_section (output_bfd, info, input_bfd, input_section,
&& (h->elf_link_hash_flags
& ELF_LINK_HASH_DEF_DYNAMIC) != 0))
)
- relocation_needed = 0;
+ relocation = 0;
break;
case R_ARM_GOTPC:
- relocation_needed = 0;
+ relocation = 0;
break;
case R_ARM_GOT32:
- if (elf_hash_table(info)->dynamic_sections_created
- && (!info->shared
+ if ((WILL_CALL_FINISH_DYNAMIC_SYMBOL
+ (elf_hash_table (info)->dynamic_sections_created,
+ info->shared, h))
+ && (!info->shared
|| (!info->symbolic && h->dynindx != -1)
- || (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0
- )
- )
- relocation_needed = 0;
- break;
-
- case R_ARM_PLT32:
- if (h->plt.offset != (bfd_vma)-1)
- relocation_needed = 0;
+ || (h->elf_link_hash_flags
+ & ELF_LINK_HASH_DEF_REGULAR) == 0))
+ relocation = 0;
break;
default:
- if (sec->output_section == NULL)
- {
- (*_bfd_error_handler)
- (_("%s: warning: unresolvable relocation %d against symbol `%s' from %s section"),
- bfd_archive_filename (input_bfd),
- r_type,
- h->root.root.string,
- bfd_get_section_name (input_bfd, input_section));
- relocation_needed = 0;
- }
+ if (unresolved_reloc)
+ _bfd_error_handler
+ (_("%s: warning: unresolvable relocation %d against symbol `%s' from %s section"),
+ bfd_archive_filename (input_bfd),
+ r_type,
+ h->root.root.string,
+ bfd_get_section_name (input_bfd, input_section));
+ break;
}
-
- if (relocation_needed)
- relocation = h->root.u.def.value
- + sec->output_section->vma
- + sec->output_offset;
- else
- relocation = 0;
- }
- else if (h->root.type == bfd_link_hash_undefweak)
- relocation = 0;
- else if (info->shared && !info->symbolic
- && !info->no_undefined
- && ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
- relocation = 0;
- else
- {
- if (!((*info->callbacks->undefined_symbol)
- (info, h->root.root.string, input_bfd,
- input_section, rel->r_offset,
- (!info->shared || info->no_undefined
- || ELF_ST_VISIBILITY (h->other)))))
- return false;
- relocation = 0;
}
}
@@ -2071,14 +2209,14 @@ elf32_arm_relocate_section (output_bfd, info, input_bfd, input_section,
&& (!((*info->callbacks->reloc_overflow)
(info, name, howto->name, (bfd_vma) 0,
input_bfd, input_section, rel->r_offset))))
- return false;
+ return FALSE;
break;
case bfd_reloc_undefined:
if (!((*info->callbacks->undefined_symbol)
(info, name, input_bfd, input_section,
- rel->r_offset, true)))
- return false;
+ rel->r_offset, TRUE)))
+ return FALSE;
break;
case bfd_reloc_outofrange:
@@ -2101,17 +2239,39 @@ elf32_arm_relocate_section (output_bfd, info, input_bfd, input_section,
if (!((*info->callbacks->warning)
(info, msg, name, input_bfd, input_section,
rel->r_offset)))
- return false;
+ return FALSE;
break;
}
}
}
- return true;
+ return TRUE;
+}
+
+/* Set the right machine number. */
+
+static bfd_boolean
+elf32_arm_object_p (abfd)
+ bfd *abfd;
+{
+ unsigned int mach;
+
+ mach = bfd_arm_get_mach_from_notes (abfd, ARM_NOTE_SECTION);
+
+ if (mach != bfd_mach_arm_unknown)
+ bfd_default_set_arch_mach (abfd, bfd_arch_arm, mach);
+
+ else if (elf_elfheader (abfd)->e_flags & EF_ARM_MAVERICK_FLOAT)
+ bfd_default_set_arch_mach (abfd, bfd_arch_arm, bfd_mach_arm_ep9312);
+
+ else
+ bfd_default_set_arch_mach (abfd, bfd_arch_arm, mach);
+
+ return TRUE;
}
/* Function to keep ARM specific flags in the ELF header. */
-static boolean
+static bfd_boolean
elf32_arm_set_private_flags (abfd, flags)
bfd *abfd;
flagword flags;
@@ -2134,15 +2294,15 @@ Warning: Clearing the interworking flag of %s due to outside request"),
else
{
elf_elfheader (abfd)->e_flags = flags;
- elf_flags_init (abfd) = true;
+ elf_flags_init (abfd) = TRUE;
}
- return true;
+ return TRUE;
}
/* Copy backend specific data from one object module to another. */
-static boolean
+static bfd_boolean
elf32_arm_copy_private_bfd_data (ibfd, obfd)
bfd *ibfd;
bfd *obfd;
@@ -2152,7 +2312,7 @@ elf32_arm_copy_private_bfd_data (ibfd, obfd)
if ( bfd_get_flavour (ibfd) != bfd_target_elf_flavour
|| bfd_get_flavour (obfd) != bfd_target_elf_flavour)
- return true;
+ return TRUE;
in_flags = elf_elfheader (ibfd)->e_flags;
out_flags = elf_elfheader (obfd)->e_flags;
@@ -2163,11 +2323,11 @@ elf32_arm_copy_private_bfd_data (ibfd, obfd)
{
/* Cannot mix APCS26 and APCS32 code. */
if ((in_flags & EF_ARM_APCS_26) != (out_flags & EF_ARM_APCS_26))
- return false;
+ return FALSE;
/* Cannot mix float APCS and non-float APCS code. */
if ((in_flags & EF_ARM_APCS_FLOAT) != (out_flags & EF_ARM_APCS_FLOAT))
- return false;
+ return FALSE;
/* If the src and dest have different interworking flags
then turn off the interworking bit. */
@@ -2188,32 +2348,31 @@ Warning: Clearing the interworking flag of %s because non-interworking code in %
}
elf_elfheader (obfd)->e_flags = in_flags;
- elf_flags_init (obfd) = true;
+ elf_flags_init (obfd) = TRUE;
- return true;
+ return TRUE;
}
/* Merge backend specific data from an object file to the output
object file when linking. */
-static boolean
+static bfd_boolean
elf32_arm_merge_private_bfd_data (ibfd, obfd)
bfd * ibfd;
bfd * obfd;
{
flagword out_flags;
flagword in_flags;
- boolean flags_compatible = true;
- boolean null_input_bfd = true;
+ bfd_boolean flags_compatible = TRUE;
asection *sec;
/* Check if we have the same endianess. */
if (! _bfd_generic_verify_endian_match (ibfd, obfd))
- return false;
+ return FALSE;
if ( bfd_get_flavour (ibfd) != bfd_target_elf_flavour
|| bfd_get_flavour (obfd) != bfd_target_elf_flavour)
- return true;
+ return TRUE;
/* The input BFD must have had its flags initialised. */
/* The following seems bogus to me -- The flags are initialized in
@@ -2234,37 +2393,61 @@ elf32_arm_merge_private_bfd_data (ibfd, obfd)
to the default values. */
if (bfd_get_arch_info (ibfd)->the_default
&& elf_elfheader (ibfd)->e_flags == 0)
- return true;
+ return TRUE;
- elf_flags_init (obfd) = true;
+ elf_flags_init (obfd) = TRUE;
elf_elfheader (obfd)->e_flags = in_flags;
if (bfd_get_arch (obfd) == bfd_get_arch (ibfd)
&& bfd_get_arch_info (obfd)->the_default)
return bfd_set_arch_mach (obfd, bfd_get_arch (ibfd), bfd_get_mach (ibfd));
- return true;
+ return TRUE;
}
+ /* Determine what should happen if the input ARM architecture
+ does not match the output ARM architecture. */
+ if (! bfd_arm_merge_machines (ibfd, obfd))
+ return FALSE;
+
/* Identical flags must be compatible. */
if (in_flags == out_flags)
- return true;
-
- /* Check to see if the input BFD actually contains any sections.
- If not, its flags may not have been initialised either, but it cannot
- actually cause any incompatibility. */
- for (sec = ibfd->sections; sec != NULL; sec = sec->next)
+ return TRUE;
+
+ /* Check to see if the input BFD actually contains any sections. If
+ not, its flags may not have been initialised either, but it
+ cannot actually cause any incompatibility. Do not short-circuit
+ dynamic objects; their section list may be emptied by
+ elf_link_add_object_symbols.
+
+ Also check to see if there are no code sections in the input.
+ In this case there is no need to check for code specific flags.
+ XXX - do we need to worry about floating-point format compatability
+ in data sections ? */
+ if (!(ibfd->flags & DYNAMIC))
{
- /* Ignore synthetic glue sections. */
- if (strcmp (sec->name, ".glue_7")
- && strcmp (sec->name, ".glue_7t"))
+ bfd_boolean null_input_bfd = TRUE;
+ bfd_boolean only_data_sections = TRUE;
+
+ for (sec = ibfd->sections; sec != NULL; sec = sec->next)
{
- null_input_bfd = false;
- break;
+ /* Ignore synthetic glue sections. */
+ if (strcmp (sec->name, ".glue_7")
+ && strcmp (sec->name, ".glue_7t"))
+ {
+ if ((bfd_get_section_flags (ibfd, sec)
+ & (SEC_LOAD | SEC_CODE | SEC_HAS_CONTENTS))
+ == (SEC_LOAD | SEC_CODE | SEC_HAS_CONTENTS))
+ only_data_sections = FALSE;
+
+ null_input_bfd = FALSE;
+ break;
+ }
}
+
+ if (null_input_bfd || only_data_sections)
+ return TRUE;
}
- if (null_input_bfd)
- return true;
/* Complain about various flag mismatches. */
if (EF_ARM_EABI_VERSION (in_flags) != EF_ARM_EABI_VERSION (out_flags))
@@ -2275,7 +2458,7 @@ ERROR: %s is compiled for EABI version %d, whereas %s is compiled for version %d
(in_flags & EF_ARM_EABIMASK) >> 24,
bfd_get_filename (obfd),
(out_flags & EF_ARM_EABIMASK) >> 24);
- return false;
+ return FALSE;
}
/* Not sure what needs to be checked for EABI versions >= 1. */
@@ -2289,7 +2472,7 @@ ERROR: %s is compiled for APCS-%d, whereas target %s uses APCS-%d"),
in_flags & EF_ARM_APCS_26 ? 26 : 32,
bfd_get_filename (obfd),
out_flags & EF_ARM_APCS_26 ? 26 : 32);
- flags_compatible = false;
+ flags_compatible = FALSE;
}
if ((in_flags & EF_ARM_APCS_FLOAT) != (out_flags & EF_ARM_APCS_FLOAT))
@@ -2305,23 +2488,39 @@ ERROR: %s passes floats in integer registers, whereas %s passes them in float re
bfd_archive_filename (ibfd),
bfd_get_filename (obfd));
- flags_compatible = false;
+ flags_compatible = FALSE;
}
if ((in_flags & EF_ARM_VFP_FLOAT) != (out_flags & EF_ARM_VFP_FLOAT))
{
if (in_flags & EF_ARM_VFP_FLOAT)
_bfd_error_handler (_("\
-ERROR: %s uses VFP instructions, whereas %s uses FPA instructions"),
+ERROR: %s uses VFP instructions, whereas %s does not"),
+ bfd_archive_filename (ibfd),
+ bfd_get_filename (obfd));
+ else
+ _bfd_error_handler (_("\
+ERROR: %s uses FPA instructions, whereas %s does not"),
+ bfd_archive_filename (ibfd),
+ bfd_get_filename (obfd));
+
+ flags_compatible = FALSE;
+ }
+
+ if ((in_flags & EF_ARM_MAVERICK_FLOAT) != (out_flags & EF_ARM_MAVERICK_FLOAT))
+ {
+ if (in_flags & EF_ARM_MAVERICK_FLOAT)
+ _bfd_error_handler (_("\
+ERROR: %s uses Maverick instructions, whereas %s does not"),
bfd_archive_filename (ibfd),
bfd_get_filename (obfd));
else
_bfd_error_handler (_("\
-ERROR: %s uses FPA instructions, whereas %s uses VFP instructions"),
+ERROR: %s does not use Maverick instructions, whereas %s does"),
bfd_archive_filename (ibfd),
bfd_get_filename (obfd));
- flags_compatible = false;
+ flags_compatible = FALSE;
}
#ifdef EF_ARM_SOFT_FLOAT
@@ -2346,7 +2545,7 @@ ERROR: %s uses hardware FP, whereas %s uses software FP"),
bfd_archive_filename (ibfd),
bfd_get_filename (obfd));
- flags_compatible = false;
+ flags_compatible = FALSE;
}
}
#endif
@@ -2376,7 +2575,7 @@ Warning: %s does not support interworking, whereas %s does"),
/* Display the flags field. */
-static boolean
+static bfd_boolean
elf32_arm_print_private_bfd_data (abfd, ptr)
bfd *abfd;
PTR ptr;
@@ -2399,7 +2598,7 @@ elf32_arm_print_private_bfd_data (abfd, ptr)
switch (EF_ARM_EABI_VERSION (flags))
{
case EF_ARM_EABI_UNKNOWN:
- /* The following flag bits are GNU extenstions and not part of the
+ /* The following flag bits are GNU extensions and not part of the
official ARM ELF extended ABI. Hence they are only decoded if
the EABI version is not set. */
if (flags & EF_ARM_INTERWORK)
@@ -2412,6 +2611,8 @@ elf32_arm_print_private_bfd_data (abfd, ptr)
if (flags & EF_ARM_VFP_FLOAT)
fprintf (file, _(" [VFP float format]"));
+ else if (flags & EF_ARM_MAVERICK_FLOAT)
+ fprintf (file, _(" [Maverick float format]"));
else
fprintf (file, _(" [FPA float format]"));
@@ -2432,7 +2633,8 @@ elf32_arm_print_private_bfd_data (abfd, ptr)
flags &= ~(EF_ARM_INTERWORK | EF_ARM_APCS_26 | EF_ARM_APCS_FLOAT
| EF_ARM_PIC | EF_ARM_NEW_ABI | EF_ARM_OLD_ABI
- | EF_ARM_SOFT_FLOAT | EF_ARM_VFP_FLOAT);
+ | EF_ARM_SOFT_FLOAT | EF_ARM_VFP_FLOAT
+ | EF_ARM_MAVERICK_FLOAT);
break;
case EF_ARM_EABI_VER1:
@@ -2484,7 +2686,7 @@ elf32_arm_print_private_bfd_data (abfd, ptr)
fputc ('\n', file);
- return true;
+ return TRUE;
}
static int
@@ -2552,39 +2754,110 @@ elf32_arm_gc_mark_hook (sec, info, rel, h, sym)
/* Update the got entry reference counts for the section being removed. */
-static boolean
+static bfd_boolean
elf32_arm_gc_sweep_hook (abfd, info, sec, relocs)
bfd *abfd ATTRIBUTE_UNUSED;
struct bfd_link_info *info ATTRIBUTE_UNUSED;
asection *sec ATTRIBUTE_UNUSED;
const Elf_Internal_Rela *relocs ATTRIBUTE_UNUSED;
{
- /* We don't support garbage collection of GOT and PLT relocs yet. */
- return true;
+ Elf_Internal_Shdr *symtab_hdr;
+ struct elf_link_hash_entry **sym_hashes;
+ bfd_signed_vma *local_got_refcounts;
+ const Elf_Internal_Rela *rel, *relend;
+ unsigned long r_symndx;
+ struct elf_link_hash_entry *h;
+
+ elf_section_data (sec)->local_dynrel = NULL;
+
+ symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
+ sym_hashes = elf_sym_hashes (abfd);
+ local_got_refcounts = elf_local_got_refcounts (abfd);
+
+ relend = relocs + sec->reloc_count;
+ for (rel = relocs; rel < relend; rel++)
+ switch (ELF32_R_TYPE (rel->r_info))
+ {
+ case R_ARM_GOT32:
+ r_symndx = ELF32_R_SYM (rel->r_info);
+ if (r_symndx >= symtab_hdr->sh_info)
+ {
+ h = sym_hashes[r_symndx - symtab_hdr->sh_info];
+ if (h->got.refcount > 0)
+ h->got.refcount -= 1;
+ }
+ else if (local_got_refcounts != NULL)
+ {
+ if (local_got_refcounts[r_symndx] > 0)
+ local_got_refcounts[r_symndx] -= 1;
+ }
+ break;
+
+ case R_ARM_ABS32:
+ case R_ARM_REL32:
+ case R_ARM_PC24:
+ case R_ARM_PLT32:
+ r_symndx = ELF32_R_SYM (rel->r_info);
+ if (r_symndx >= symtab_hdr->sh_info)
+ {
+ struct elf32_arm_link_hash_entry *eh;
+ struct elf32_arm_relocs_copied **pp;
+ struct elf32_arm_relocs_copied *p;
+
+ h = sym_hashes[r_symndx - symtab_hdr->sh_info];
+
+ if (h->plt.refcount > 0)
+ h->plt.refcount -= 1;
+
+ if (ELF32_R_TYPE (rel->r_info) == R_ARM_ABS32
+ || ELF32_R_TYPE (rel->r_info) == R_ARM_REL32)
+ {
+ eh = (struct elf32_arm_link_hash_entry *) h;
+
+ for (pp = &eh->relocs_copied; (p = *pp) != NULL;
+ pp = &p->next)
+ if (p->section == sec)
+ {
+ p->count -= 1;
+ if (p->count == 0)
+ *pp = p->next;
+ break;
+ }
+ }
+ }
+ break;
+
+ default:
+ break;
+ }
+
+ return TRUE;
}
/* Look through the relocs for a section during the first phase. */
-static boolean
+static bfd_boolean
elf32_arm_check_relocs (abfd, info, sec, relocs)
- bfd * abfd;
- struct bfd_link_info * info;
- asection * sec;
- const Elf_Internal_Rela * relocs;
+ bfd *abfd;
+ struct bfd_link_info *info;
+ asection *sec;
+ const Elf_Internal_Rela *relocs;
{
- Elf_Internal_Shdr * symtab_hdr;
- struct elf_link_hash_entry ** sym_hashes;
- struct elf_link_hash_entry ** sym_hashes_end;
- const Elf_Internal_Rela * rel;
- const Elf_Internal_Rela * rel_end;
- bfd * dynobj;
- asection * sgot, *srelgot, *sreloc;
- bfd_vma * local_got_offsets;
+ Elf_Internal_Shdr *symtab_hdr;
+ struct elf_link_hash_entry **sym_hashes;
+ struct elf_link_hash_entry **sym_hashes_end;
+ const Elf_Internal_Rela *rel;
+ const Elf_Internal_Rela *rel_end;
+ bfd *dynobj;
+ asection *sreloc;
+ bfd_vma *local_got_offsets;
+ struct elf32_arm_link_hash_table *htab;
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
- sgot = srelgot = sreloc = NULL;
+ htab = elf32_arm_hash_table (info);
+ sreloc = NULL;
dynobj = elf_hash_table (info)->dynobj;
local_got_offsets = elf_local_got_offsets (abfd);
@@ -2609,126 +2882,75 @@ elf32_arm_check_relocs (abfd, info, sec, relocs)
else
h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- /* Some relocs require a global offset table. */
- if (dynobj == NULL)
- {
- switch (ELF32_R_TYPE (rel->r_info))
- {
- case R_ARM_GOT32:
- case R_ARM_GOTOFF:
- case R_ARM_GOTPC:
- elf_hash_table (info)->dynobj = dynobj = abfd;
- if (! _bfd_elf_create_got_section (dynobj, info))
- return false;
- break;
-
- default:
- break;
- }
- }
-
switch (ELF32_R_TYPE (rel->r_info))
{
case R_ARM_GOT32:
/* This symbol requires a global offset table entry. */
- if (sgot == NULL)
- {
- sgot = bfd_get_section_by_name (dynobj, ".got");
- BFD_ASSERT (sgot != NULL);
- }
-
- /* Get the got relocation section if necessary. */
- if (srelgot == NULL
- && (h != NULL || info->shared))
- {
- srelgot = bfd_get_section_by_name (dynobj, ".rel.got");
-
- /* If no got relocation section, make one and initialize. */
- if (srelgot == NULL)
- {
- srelgot = bfd_make_section (dynobj, ".rel.got");
- if (srelgot == NULL
- || ! bfd_set_section_flags (dynobj, srelgot,
- (SEC_ALLOC
- | SEC_LOAD
- | SEC_HAS_CONTENTS
- | SEC_IN_MEMORY
- | SEC_LINKER_CREATED
- | SEC_READONLY))
- || ! bfd_set_section_alignment (dynobj, srelgot, 2))
- return false;
- }
- }
-
if (h != NULL)
{
- if (h->got.offset != (bfd_vma) -1)
- /* We have already allocated space in the .got. */
- break;
-
- h->got.offset = sgot->_raw_size;
-
- /* Make sure this symbol is output as a dynamic symbol. */
- if (h->dynindx == -1)
- if (! bfd_elf32_link_record_dynamic_symbol (info, h))
- return false;
-
- srelgot->_raw_size += sizeof (Elf32_External_Rel);
+ h->got.refcount++;
}
else
{
- /* This is a global offset table entry for a local
- symbol. */
- if (local_got_offsets == NULL)
+ bfd_signed_vma *local_got_refcounts;
+
+ /* This is a global offset table entry for a local symbol. */
+ local_got_refcounts = elf_local_got_refcounts (abfd);
+ if (local_got_refcounts == NULL)
{
bfd_size_type size;
- unsigned int i;
size = symtab_hdr->sh_info;
- size *= sizeof (bfd_vma);
- local_got_offsets = (bfd_vma *) bfd_alloc (abfd, size);
- if (local_got_offsets == NULL)
- return false;
- elf_local_got_offsets (abfd) = local_got_offsets;
- for (i = 0; i < symtab_hdr->sh_info; i++)
- local_got_offsets[i] = (bfd_vma) -1;
+ size *= (sizeof (bfd_signed_vma) + sizeof(char));
+ local_got_refcounts = ((bfd_signed_vma *)
+ bfd_zalloc (abfd, size));
+ if (local_got_refcounts == NULL)
+ return FALSE;
+ elf_local_got_refcounts (abfd) = local_got_refcounts;
}
-
- if (local_got_offsets[r_symndx] != (bfd_vma) -1)
- /* We have already allocated space in the .got. */
- break;
-
- local_got_offsets[r_symndx] = sgot->_raw_size;
-
- if (info->shared)
- /* If we are generating a shared object, we need to
- output a R_ARM_RELATIVE reloc so that the dynamic
- linker can adjust this GOT entry. */
- srelgot->_raw_size += sizeof (Elf32_External_Rel);
+ local_got_refcounts[r_symndx] += 1;
}
-
- sgot->_raw_size += 4;
break;
- case R_ARM_PLT32:
- /* This symbol requires a procedure linkage table entry. We
- actually build the entry in adjust_dynamic_symbol,
- because this might be a case of linking PIC code which is
- never referenced by a dynamic object, in which case we
- don't need to generate a procedure linkage table entry
- after all. */
-
- /* If this is a local symbol, we resolve it directly without
- creating a procedure linkage table entry. */
- if (h == NULL)
- continue;
-
- h->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_PLT;
+ case R_ARM_GOTOFF:
+ case R_ARM_GOTPC:
+ if (htab->sgot == NULL)
+ {
+ if (htab->root.dynobj == NULL)
+ htab->root.dynobj = abfd;
+ if (!create_got_section (htab->root.dynobj, info))
+ return FALSE;
+ }
break;
case R_ARM_ABS32:
case R_ARM_REL32:
case R_ARM_PC24:
+ case R_ARM_PLT32:
+ if (h != NULL)
+ {
+ /* If this reloc is in a read-only section, we might
+ need a copy reloc. We can't check reliably at this
+ stage whether the section is read-only, as input
+ sections have not yet been mapped to output sections.
+ Tentatively set the flag for now, and correct in
+ adjust_dynamic_symbol. */
+ if (!info->shared)
+ h->elf_link_hash_flags |= ELF_LINK_NON_GOT_REF;
+
+ /* We may need a .plt entry if the function this reloc
+ refers to is in a different object. We can't tell for
+ sure yet, because something later might force the
+ symbol local. */
+ if (ELF32_R_TYPE (rel->r_info) == R_ARM_PC24
+ || ELF32_R_TYPE (rel->r_info) == R_ARM_PLT32)
+ h->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_PLT;
+
+ /* If we create a PLT entry, this relocation will reference
+ it, even if it's an ABS32 relocation. */
+ h->plt.refcount += 1;
+ }
+
/* If we are creating a shared library, and this is a reloc
against a global symbol, or a non PC relative reloc
against a local symbol, then we need to copy the reloc
@@ -2740,14 +2962,19 @@ elf32_arm_check_relocs (abfd, info, sec, relocs)
possible that DEF_REGULAR is not set now but will be set
later (it is never cleared). We account for that
possibility below by storing information in the
- pcrel_relocs_copied field of the hash table entry. */
+ relocs_copied field of the hash table entry. */
if (info->shared
- && (ELF32_R_TYPE (rel->r_info) != R_ARM_PC24
- || (h != NULL
- && (! info->symbolic
- || (h->elf_link_hash_flags
- & ELF_LINK_HASH_DEF_REGULAR) == 0))))
+ && (sec->flags & SEC_ALLOC) != 0
+ && ((ELF32_R_TYPE (rel->r_info) != R_ARM_PC24
+ && ELF32_R_TYPE (rel->r_info) != R_ARM_PLT32
+ && ELF32_R_TYPE (rel->r_info) != R_ARM_REL32)
+ || (h != NULL
+ && (! info->symbolic
+ || (h->elf_link_hash_flags
+ & ELF_LINK_HASH_DEF_REGULAR) == 0))))
{
+ struct elf32_arm_relocs_copied *p, **head;
+
/* When creating a shared object, we must copy these
reloc types into the output file. We create a reloc
section in dynobj and make room for this reloc. */
@@ -2760,7 +2987,7 @@ elf32_arm_check_relocs (abfd, info, sec, relocs)
elf_elfheader (abfd)->e_shstrndx,
elf_section_data (sec)->rel_hdr.sh_name));
if (name == NULL)
- return false;
+ return FALSE;
BFD_ASSERT (strncmp (name, ".rel", 4) == 0
&& strcmp (bfd_get_section_name (abfd, sec),
@@ -2779,107 +3006,110 @@ elf32_arm_check_relocs (abfd, info, sec, relocs)
if (sreloc == NULL
|| ! bfd_set_section_flags (dynobj, sreloc, flags)
|| ! bfd_set_section_alignment (dynobj, sreloc, 2))
- return false;
+ return FALSE;
}
- if (sec->flags & SEC_READONLY)
- info->flags |= DF_TEXTREL;
+
+ elf_section_data (sec)->sreloc = sreloc;
}
- sreloc->_raw_size += sizeof (Elf32_External_Rel);
- /* If we are linking with -Bsymbolic, and this is a
- global symbol, we count the number of PC relative
- relocations we have entered for this symbol, so that
- we can discard them again if the symbol is later
- defined by a regular object. Note that this function
- is only called if we are using an elf_i386 linker
- hash table, which means that h is really a pointer to
- an elf_i386_link_hash_entry. */
- if (h != NULL && info->symbolic
- && ELF32_R_TYPE (rel->r_info) == R_ARM_PC24)
+ /* If this is a global symbol, we count the number of
+ relocations we need for this symbol. */
+ if (h != NULL)
{
- struct elf32_arm_link_hash_entry * eh;
- struct elf32_arm_pcrel_relocs_copied * p;
-
- eh = (struct elf32_arm_link_hash_entry *) h;
-
- for (p = eh->pcrel_relocs_copied; p != NULL; p = p->next)
- if (p->section == sreloc)
- break;
-
+ head = &((struct elf32_arm_link_hash_entry *) h)->relocs_copied;
+ }
+ else
+ {
+ /* Track dynamic relocs needed for local syms too.
+ We really need local syms available to do this
+ easily. Oh well. */
+
+ asection *s;
+ s = bfd_section_from_r_symndx (abfd, &htab->sym_sec,
+ sec, r_symndx);
+ if (s == NULL)
+ return FALSE;
+
+ head = ((struct elf32_arm_relocs_copied **)
+ &elf_section_data (s)->local_dynrel);
+ }
+
+ p = *head;
+ if (p == NULL || p->section != sec)
+ {
+ bfd_size_type amt = sizeof *p;
+ p = bfd_alloc (htab->root.dynobj, amt);
if (p == NULL)
- {
- p = ((struct elf32_arm_pcrel_relocs_copied *)
- bfd_alloc (dynobj, (bfd_size_type) sizeof * p));
- if (p == NULL)
- return false;
- p->next = eh->pcrel_relocs_copied;
- eh->pcrel_relocs_copied = p;
- p->section = sreloc;
- p->count = 0;
- }
-
- ++p->count;
+ return FALSE;
+ p->next = *head;
+ *head = p;
+ p->section = sec;
+ p->count = 0;
}
+
+ if (ELF32_R_TYPE (rel->r_info) == R_ARM_ABS32
+ || ELF32_R_TYPE (rel->r_info) == R_ARM_REL32)
+ p->count += 1;
}
break;
/* This relocation describes the C++ object vtable hierarchy.
Reconstruct it for later use during GC. */
case R_ARM_GNU_VTINHERIT:
- if (!_bfd_elf32_gc_record_vtinherit (abfd, sec, h, rel->r_offset))
- return false;
+ if (!bfd_elf_gc_record_vtinherit (abfd, sec, h, rel->r_offset))
+ return FALSE;
break;
/* This relocation describes which C++ vtable entries are actually
used. Record for later use during GC. */
case R_ARM_GNU_VTENTRY:
- if (!_bfd_elf32_gc_record_vtentry (abfd, sec, h, rel->r_offset))
- return false;
+ if (!bfd_elf_gc_record_vtentry (abfd, sec, h, rel->r_offset))
+ return FALSE;
break;
}
}
- return true;
+ return TRUE;
}
/* Find the nearest line to a particular section and offset, for error
reporting. This code is a duplicate of the code in elf.c, except
that it also accepts STT_ARM_TFUNC as a symbol that names a function. */
-static boolean
+static bfd_boolean
elf32_arm_find_nearest_line
(abfd, section, symbols, offset, filename_ptr, functionname_ptr, line_ptr)
- bfd * abfd;
- asection * section;
- asymbol ** symbols;
- bfd_vma offset;
- const char ** filename_ptr;
- const char ** functionname_ptr;
- unsigned int * line_ptr;
+ bfd *abfd;
+ asection *section;
+ asymbol **symbols;
+ bfd_vma offset;
+ const char **filename_ptr;
+ const char **functionname_ptr;
+ unsigned int *line_ptr;
{
- boolean found;
- const char * filename;
- asymbol * func;
- bfd_vma low_func;
- asymbol ** p;
+ bfd_boolean found;
+ const char *filename;
+ asymbol *func;
+ bfd_vma low_func;
+ asymbol **p;
if (_bfd_dwarf2_find_nearest_line (abfd, section, symbols, offset,
filename_ptr, functionname_ptr,
line_ptr, 0,
&elf_tdata (abfd)->dwarf2_find_line_info))
- return true;
+ return TRUE;
if (! _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset,
&found, filename_ptr,
functionname_ptr, line_ptr,
&elf_tdata (abfd)->line_info))
- return false;
+ return FALSE;
if (found)
- return true;
+ return TRUE;
if (symbols == NULL)
- return false;
+ return FALSE;
filename = NULL;
func = NULL;
@@ -2916,13 +3146,13 @@ elf32_arm_find_nearest_line
}
if (func == NULL)
- return false;
+ return FALSE;
*filename_ptr = filename;
*functionname_ptr = bfd_asymbol_name (func);
*line_ptr = 0;
- return true;
+ return TRUE;
}
/* Adjust a symbol defined by a dynamic object and referenced by a
@@ -2931,7 +3161,7 @@ elf32_arm_find_nearest_line
change the definition to something the rest of the link can
understand. */
-static boolean
+static bfd_boolean
elf32_arm_adjust_dynamic_symbol (info, h)
struct bfd_link_info * info;
struct elf_link_hash_entry * h;
@@ -2959,71 +3189,29 @@ elf32_arm_adjust_dynamic_symbol (info, h)
if (h->type == STT_FUNC
|| (h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_PLT) != 0)
{
- /* If we link a program (not a DSO), we'll get rid of unnecessary
- PLT entries; we point to the actual symbols -- even for pic
- relocs, because a program built with -fpic should have the same
- result as one built without -fpic, specifically considering weak
- symbols.
- FIXME: m68k and i386 differ here, for unclear reasons. */
- if (! info->shared
- && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) == 0)
+ if (h->plt.refcount <= 0
+ || SYMBOL_CALLS_LOCAL (info, h)
+ || (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+ && h->root.type == bfd_link_hash_undefweak))
{
/* This case can occur if we saw a PLT32 reloc in an input
- file, but the symbol was not defined by a dynamic object.
- In such a case, we don't actually need to build a
- procedure linkage table, and we can just do a PC32 reloc
- instead. */
- BFD_ASSERT ((h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_PLT) != 0);
+ file, but the symbol was never referred to by a dynamic
+ object, or if all references were garbage collected. In
+ such a case, we don't actually need to build a procedure
+ linkage table, and we can just do a PC24 reloc instead. */
+ h->plt.offset = (bfd_vma) -1;
h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
- return true;
- }
-
- /* Make sure this symbol is output as a dynamic symbol. */
- if (h->dynindx == -1)
- {
- if (! bfd_elf32_link_record_dynamic_symbol (info, h))
- return false;
- }
-
- s = bfd_get_section_by_name (dynobj, ".plt");
- BFD_ASSERT (s != NULL);
-
- /* If this is the first .plt entry, make room for the special
- first entry. */
- if (s->_raw_size == 0)
- s->_raw_size += PLT_ENTRY_SIZE;
-
- /* If this symbol is not defined in a regular file, and we are
- not generating a shared library, then set the symbol to this
- location in the .plt. This is required to make function
- pointers compare as equal between the normal executable and
- the shared library. */
- if (! info->shared
- && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
- {
- h->root.u.def.section = s;
- h->root.u.def.value = s->_raw_size;
}
- h->plt.offset = s->_raw_size;
-
- /* Make room for this entry. */
- s->_raw_size += PLT_ENTRY_SIZE;
-
- /* We also need to make an entry in the .got.plt section, which
- will be placed in the .got section by the linker script. */
- s = bfd_get_section_by_name (dynobj, ".got.plt");
- BFD_ASSERT (s != NULL);
- s->_raw_size += 4;
-
- /* We also need to make an entry in the .rel.plt section. */
-
- s = bfd_get_section_by_name (dynobj, ".rel.plt");
- BFD_ASSERT (s != NULL);
- s->_raw_size += sizeof (Elf32_External_Rel);
-
- return true;
+ return TRUE;
}
+ else
+ /* It's possible that we incorrectly decided a .plt reloc was
+ needed for an R_ARM_PC24 reloc to a non-function sym in
+ check_relocs. We can't decide accurately between function and
+ non-function syms in check-relocs; Objects loaded later in
+ the link may change h->type. So fix it now. */
+ h->plt.offset = (bfd_vma) -1;
/* If this is a weak symbol, and there is a real definition, the
processor independent code will have arranged for us to see the
@@ -3034,7 +3222,7 @@ elf32_arm_adjust_dynamic_symbol (info, h)
|| h->weakdef->root.type == bfd_link_hash_defweak);
h->root.u.def.section = h->weakdef->root.u.def.section;
h->root.u.def.value = h->weakdef->root.u.def.value;
- return true;
+ return TRUE;
}
/* This is a reference to a symbol defined by a dynamic object which
@@ -3045,7 +3233,7 @@ elf32_arm_adjust_dynamic_symbol (info, h)
For such cases we need not do anything here; the relocations will
be handled correctly by relocate_section. */
if (info->shared)
- return true;
+ return TRUE;
/* We must allocate the symbol in our .dynbss section, which will
become part of the .bss section of the executable. There will be
@@ -3085,7 +3273,7 @@ elf32_arm_adjust_dynamic_symbol (info, h)
if (power_of_two > bfd_get_section_alignment (dynobj, s))
{
if (! bfd_set_section_alignment (dynobj, s, power_of_two))
- return false;
+ return FALSE;
}
/* Define the symbol as being at this point in the section. */
@@ -3095,28 +3283,202 @@ elf32_arm_adjust_dynamic_symbol (info, h)
/* Increment the section size to make room for the symbol. */
s->_raw_size += h->size;
- return true;
+ return TRUE;
+}
+
+/* Allocate space in .plt, .got and associated reloc sections for
+ dynamic relocs. */
+
+static bfd_boolean
+allocate_dynrelocs (h, inf)
+ struct elf_link_hash_entry *h;
+ PTR inf;
+{
+ struct bfd_link_info *info;
+ struct elf32_arm_link_hash_table *htab;
+ struct elf32_arm_link_hash_entry *eh;
+ struct elf32_arm_relocs_copied *p;
+
+ if (h->root.type == bfd_link_hash_indirect)
+ return TRUE;
+
+ if (h->root.type == bfd_link_hash_warning)
+ /* When warning symbols are created, they **replace** the "real"
+ entry in the hash table, thus we never get to see the real
+ symbol in a hash traversal. So look at it now. */
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ info = (struct bfd_link_info *) inf;
+ htab = elf32_arm_hash_table (info);
+
+ if (htab->root.dynamic_sections_created
+ && h->plt.refcount > 0)
+ {
+ /* Make sure this symbol is output as a dynamic symbol.
+ Undefined weak syms won't yet be marked as dynamic. */
+ if (h->dynindx == -1
+ && (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
+ }
+
+ if (info->shared
+ || WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, 0, h))
+ {
+ asection *s = htab->splt;
+
+ /* If this is the first .plt entry, make room for the special
+ first entry. */
+ if (s->_raw_size == 0)
+ s->_raw_size += PLT_HEADER_SIZE;
+
+ h->plt.offset = s->_raw_size;
+
+ /* If this symbol is not defined in a regular file, and we are
+ not generating a shared library, then set the symbol to this
+ location in the .plt. This is required to make function
+ pointers compare as equal between the normal executable and
+ the shared library. */
+ if (! info->shared
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
+ {
+ h->root.u.def.section = s;
+ h->root.u.def.value = h->plt.offset;
+ }
+
+ /* Make room for this entry. */
+ s->_raw_size += PLT_ENTRY_SIZE;
+
+ /* We also need to make an entry in the .got.plt section, which
+ will be placed in the .got section by the linker script. */
+ htab->sgotplt->_raw_size += 4;
+
+ /* We also need to make an entry in the .rel.plt section. */
+ htab->srelplt->_raw_size += sizeof (Elf32_External_Rel);
+ }
+ else
+ {
+ h->plt.offset = (bfd_vma) -1;
+ h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
+ }
+ }
+ else
+ {
+ h->plt.offset = (bfd_vma) -1;
+ h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
+ }
+
+ if (h->got.refcount > 0)
+ {
+ asection *s;
+ bfd_boolean dyn;
+
+ /* Make sure this symbol is output as a dynamic symbol.
+ Undefined weak syms won't yet be marked as dynamic. */
+ if (h->dynindx == -1
+ && (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
+ }
+
+ s = htab->sgot;
+ h->got.offset = s->_raw_size;
+ s->_raw_size += 4;
+ dyn = htab->root.dynamic_sections_created;
+ if ((ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak)
+ && (info->shared
+ || WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, 0, h)))
+ htab->srelgot->_raw_size += sizeof (Elf32_External_Rel);
+ }
+ else
+ h->got.offset = (bfd_vma) -1;
+
+ eh = (struct elf32_arm_link_hash_entry *) h;
+ if (eh->relocs_copied == NULL)
+ return TRUE;
+
+ /* In the shared -Bsymbolic case, discard space allocated for
+ dynamic pc-relative relocs against symbols which turn out to be
+ defined in regular objects. For the normal shared case, discard
+ space for pc-relative relocs that have become local due to symbol
+ visibility changes. */
+
+ if (info->shared)
+ {
+ /* Discard relocs on undefined weak syms with non-default
+ visibility. */
+ if (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+ && h->root.type == bfd_link_hash_undefweak)
+ eh->relocs_copied = NULL;
+ }
+ else
+ {
+ /* For the non-shared case, discard space for relocs against
+ symbols which turn out to need copy relocs or are not
+ dynamic. */
+
+ if ((h->elf_link_hash_flags & ELF_LINK_NON_GOT_REF) == 0
+ && (((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
+ || (htab->root.dynamic_sections_created
+ && (h->root.type == bfd_link_hash_undefweak
+ || h->root.type == bfd_link_hash_undefined))))
+ {
+ /* Make sure this symbol is output as a dynamic symbol.
+ Undefined weak syms won't yet be marked as dynamic. */
+ if (h->dynindx == -1
+ && (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
+ }
+
+ /* If that succeeded, we know we'll be keeping all the
+ relocs. */
+ if (h->dynindx != -1)
+ goto keep;
+ }
+
+ eh->relocs_copied = NULL;
+
+ keep: ;
+ }
+
+ /* Finally, allocate space. */
+ for (p = eh->relocs_copied; p != NULL; p = p->next)
+ {
+ asection *sreloc = elf_section_data (p->section)->sreloc;
+ sreloc->_raw_size += p->count * sizeof (Elf32_External_Rel);
+ }
+
+ return TRUE;
}
/* Set the sizes of the dynamic sections. */
-static boolean
+static bfd_boolean
elf32_arm_size_dynamic_sections (output_bfd, info)
bfd * output_bfd ATTRIBUTE_UNUSED;
struct bfd_link_info * info;
{
bfd * dynobj;
asection * s;
- boolean plt;
- boolean relocs;
+ bfd_boolean plt;
+ bfd_boolean relocs;
+ bfd *ibfd;
+ struct elf32_arm_link_hash_table *htab;
+ htab = elf32_arm_hash_table (info);
dynobj = elf_hash_table (info)->dynobj;
BFD_ASSERT (dynobj != NULL);
if (elf_hash_table (info)->dynamic_sections_created)
{
/* Set the contents of the .interp section to the interpreter. */
- if (! info->shared)
+ if (info->executable)
{
s = bfd_get_section_by_name (dynobj, ".interp");
BFD_ASSERT (s != NULL);
@@ -3124,36 +3486,84 @@ elf32_arm_size_dynamic_sections (output_bfd, info)
s->contents = (unsigned char *) ELF_DYNAMIC_INTERPRETER;
}
}
- else
+
+ /* Set up .got offsets for local syms, and space for local dynamic
+ relocs. */
+ for (ibfd = info->input_bfds; ibfd != NULL; ibfd = ibfd->link_next)
{
- /* We may have created entries in the .rel.got section.
- However, if we are not creating the dynamic sections, we will
- not actually use these entries. Reset the size of .rel.got,
- which will cause it to get stripped from the output file
- below. */
- s = bfd_get_section_by_name (dynobj, ".rel.got");
- if (s != NULL)
- s->_raw_size = 0;
+ bfd_signed_vma *local_got;
+ bfd_signed_vma *end_local_got;
+ char *local_tls_type;
+ bfd_size_type locsymcount;
+ Elf_Internal_Shdr *symtab_hdr;
+ asection *srel;
+
+ if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour)
+ continue;
+
+ for (s = ibfd->sections; s != NULL; s = s->next)
+ {
+ struct elf32_arm_relocs_copied *p;
+
+ for (p = *((struct elf32_arm_relocs_copied **)
+ &elf_section_data (s)->local_dynrel);
+ p != NULL;
+ p = p->next)
+ {
+ if (!bfd_is_abs_section (p->section)
+ && bfd_is_abs_section (p->section->output_section))
+ {
+ /* Input section has been discarded, either because
+ it is a copy of a linkonce section or due to
+ linker script /DISCARD/, so we'll be discarding
+ the relocs too. */
+ }
+ else if (p->count != 0)
+ {
+ srel = elf_section_data (p->section)->sreloc;
+ srel->_raw_size += p->count * sizeof (Elf32_External_Rel);
+ if ((p->section->output_section->flags & SEC_READONLY) != 0)
+ info->flags |= DF_TEXTREL;
+ }
+ }
+ }
+
+ local_got = elf_local_got_refcounts (ibfd);
+ if (!local_got)
+ continue;
+
+ symtab_hdr = &elf_tdata (ibfd)->symtab_hdr;
+ locsymcount = symtab_hdr->sh_info;
+ end_local_got = local_got + locsymcount;
+ s = htab->sgot;
+ srel = htab->srelgot;
+ for (; local_got < end_local_got; ++local_got, ++local_tls_type)
+ {
+ if (*local_got > 0)
+ {
+ *local_got = s->_raw_size;
+ s->_raw_size += 4;
+ if (info->shared)
+ srel->_raw_size += sizeof (Elf32_External_Rel);
+ }
+ else
+ *local_got = (bfd_vma) -1;
+ }
}
- /* If this is a -Bsymbolic shared link, then we need to discard all
- PC relative relocs against symbols defined in a regular object.
- We allocated space for them in the check_relocs routine, but we
- will not fill them in in the relocate_section routine. */
- if (info->shared && info->symbolic)
- elf32_arm_link_hash_traverse (elf32_arm_hash_table (info),
- elf32_arm_discard_copies,
- (PTR) NULL);
+ /* Allocate global sym .plt and .got entries, and space for global
+ sym dynamic relocs. */
+ elf_link_hash_traverse (&htab->root, allocate_dynrelocs, (PTR) info);
/* The check_relocs and adjust_dynamic_symbol entry points have
determined the sizes of the various dynamic sections. Allocate
memory for them. */
- plt = false;
- relocs = false;
+ plt = FALSE;
+ relocs = FALSE;
for (s = dynobj->sections; s != NULL; s = s->next)
{
const char * name;
- boolean strip;
+ bfd_boolean strip;
if ((s->flags & SEC_LINKER_CREATED) == 0)
continue;
@@ -3162,7 +3572,7 @@ elf32_arm_size_dynamic_sections (output_bfd, info)
of the dynobj section names depend upon the input files. */
name = bfd_get_section_name (dynobj, s);
- strip = false;
+ strip = FALSE;
if (strcmp (name, ".plt") == 0)
{
@@ -3170,12 +3580,12 @@ elf32_arm_size_dynamic_sections (output_bfd, info)
{
/* Strip this section if we don't need it; see the
comment below. */
- strip = true;
+ strip = TRUE;
}
else
{
/* Remember whether there is a PLT. */
- plt = true;
+ plt = TRUE;
}
}
else if (strncmp (name, ".rel", 4) == 0)
@@ -3191,14 +3601,14 @@ elf32_arm_size_dynamic_sections (output_bfd, info)
adjust_dynamic_symbol is called, and it is that
function which decides whether anything needs to go
into these sections. */
- strip = true;
+ strip = TRUE;
}
else
{
/* Remember whether there are any reloc sections other
than .rel.plt. */
if (strcmp (name, ".rel.plt") != 0)
- relocs = true;
+ relocs = TRUE;
/* We use the reloc_count field as a counter if we need
to copy relocs into the output file. */
@@ -3213,26 +3623,14 @@ elf32_arm_size_dynamic_sections (output_bfd, info)
if (strip)
{
- asection ** spp;
-
- for (spp = &s->output_section->owner->sections;
- *spp != NULL;
- spp = &(*spp)->next)
- {
- if (*spp == s->output_section)
- {
- bfd_section_list_remove (s->output_section->owner, spp);
- --s->output_section->owner->section_count;
- break;
- }
- }
+ _bfd_strip_section_from_output (info, s);
continue;
}
/* Allocate memory for the section contents. */
s->contents = (bfd_byte *) bfd_zalloc (dynobj, s->_raw_size);
if (s->contents == NULL && s->_raw_size != 0)
- return false;
+ return FALSE;
}
if (elf_hash_table (info)->dynamic_sections_created)
@@ -3243,12 +3641,12 @@ elf32_arm_size_dynamic_sections (output_bfd, info)
the .dynamic section. The DT_DEBUG entry is filled in by the
dynamic linker and used by the debugger. */
#define add_dynamic_entry(TAG, VAL) \
- bfd_elf32_add_dynamic_entry (info, (bfd_vma) (TAG), (bfd_vma) (VAL))
+ _bfd_elf_add_dynamic_entry (info, TAG, VAL)
if (!info->shared)
{
if (!add_dynamic_entry (DT_DEBUG, 0))
- return false;
+ return FALSE;
}
if (plt)
@@ -3257,7 +3655,7 @@ elf32_arm_size_dynamic_sections (output_bfd, info)
|| !add_dynamic_entry (DT_PLTRELSZ, 0)
|| !add_dynamic_entry (DT_PLTREL, DT_REL)
|| !add_dynamic_entry (DT_JMPREL, 0))
- return false;
+ return FALSE;
}
if (relocs)
@@ -3265,52 +3663,25 @@ elf32_arm_size_dynamic_sections (output_bfd, info)
if ( !add_dynamic_entry (DT_REL, 0)
|| !add_dynamic_entry (DT_RELSZ, 0)
|| !add_dynamic_entry (DT_RELENT, sizeof (Elf32_External_Rel)))
- return false;
+ return FALSE;
}
if ((info->flags & DF_TEXTREL) != 0)
{
if (!add_dynamic_entry (DT_TEXTREL, 0))
- return false;
+ return FALSE;
info->flags |= DF_TEXTREL;
}
}
#undef add_synamic_entry
- return true;
-}
-
-/* This function is called via elf32_arm_link_hash_traverse if we are
- creating a shared object with -Bsymbolic. It discards the space
- allocated to copy PC relative relocs against symbols which are
- defined in regular objects. We allocated space for them in the
- check_relocs routine, but we won't fill them in in the
- relocate_section routine. */
-
-static boolean
-elf32_arm_discard_copies (h, ignore)
- struct elf32_arm_link_hash_entry * h;
- PTR ignore ATTRIBUTE_UNUSED;
-{
- struct elf32_arm_pcrel_relocs_copied * s;
-
- if (h->root.root.type == bfd_link_hash_warning)
- h = (struct elf32_arm_link_hash_entry *) h->root.root.u.i.link;
-
- /* We only discard relocs for symbols defined in a regular object. */
- if ((h->root.elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
- return true;
-
- for (s = h->pcrel_relocs_copied; s != NULL; s = s->next)
- s->section->_raw_size -= s->count * sizeof (Elf32_External_Rel);
-
- return true;
+ return TRUE;
}
/* Finish up dynamic symbol handling. We set the contents of various
dynamic sections here. */
-static boolean
+static bfd_boolean
elf32_arm_finish_dynamic_symbol (output_bfd, info, h, sym)
bfd * output_bfd;
struct bfd_link_info * info;
@@ -3328,7 +3699,9 @@ elf32_arm_finish_dynamic_symbol (output_bfd, info, h, sym)
asection * srel;
bfd_vma plt_index;
bfd_vma got_offset;
- Elf_Internal_Rel rel;
+ Elf_Internal_Rela rel;
+ bfd_byte *loc;
+ bfd_vma got_displacement;
/* This symbol has an entry in the procedure linkage table. Set
it up. */
@@ -3344,43 +3717,50 @@ elf32_arm_finish_dynamic_symbol (output_bfd, info, h, sym)
corresponds to this symbol. This is the index of this symbol
in all the symbols for which we are making plt entries. The
first entry in the procedure linkage table is reserved. */
- plt_index = h->plt.offset / PLT_ENTRY_SIZE - 1;
+ plt_index = (h->plt.offset - PLT_HEADER_SIZE) / PLT_ENTRY_SIZE;
/* Get the offset into the .got table of the entry that
corresponds to this function. Each .got entry is 4 bytes.
The first three are reserved. */
got_offset = (plt_index + 3) * 4;
+ /* Calculate the displacement between the PLT slot and the
+ entry in the GOT. */
+ got_displacement = (sgot->output_section->vma
+ + sgot->output_offset
+ + got_offset
+ - splt->output_section->vma
+ - splt->output_offset
+ - h->plt.offset
+ - 8);
+
+ BFD_ASSERT ((got_displacement & 0xf0000000) == 0);
+
/* Fill in the entry in the procedure linkage table. */
- bfd_put_32 (output_bfd, elf32_arm_plt_entry[0],
+ bfd_put_32 (output_bfd, elf32_arm_plt_entry[0] | ((got_displacement & 0x0ff00000) >> 20),
splt->contents + h->plt.offset + 0);
- bfd_put_32 (output_bfd, elf32_arm_plt_entry[1],
+ bfd_put_32 (output_bfd, elf32_arm_plt_entry[1] | ((got_displacement & 0x000ff000) >> 12),
splt->contents + h->plt.offset + 4);
- bfd_put_32 (output_bfd, elf32_arm_plt_entry[2],
+ bfd_put_32 (output_bfd, elf32_arm_plt_entry[2] | (got_displacement & 0x00000fff),
splt->contents + h->plt.offset + 8);
- bfd_put_32 (output_bfd,
- (sgot->output_section->vma
- + sgot->output_offset
- + got_offset
- - splt->output_section->vma
- - splt->output_offset
- - h->plt.offset - 12),
- splt->contents + h->plt.offset + 12);
+#ifdef FOUR_WORD_PLT
+ bfd_put_32 (output_bfd, elf32_arm_plt_entry[3],
+ splt->contents + h->plt.offset + 12);
+#endif
/* Fill in the entry in the global offset table. */
bfd_put_32 (output_bfd,
(splt->output_section->vma
+ splt->output_offset),
sgot->contents + got_offset);
-
+
/* Fill in the entry in the .rel.plt section. */
rel.r_offset = (sgot->output_section->vma
+ sgot->output_offset
+ got_offset);
rel.r_info = ELF32_R_INFO (h->dynindx, R_ARM_JUMP_SLOT);
- bfd_elf32_swap_reloc_out (output_bfd, &rel,
- ((Elf32_External_Rel *) srel->contents
- + plt_index));
+ loc = srel->contents + plt_index * sizeof (Elf32_External_Rel);
+ bfd_elf32_swap_reloc_out (output_bfd, &rel, loc);
if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
{
@@ -3401,7 +3781,8 @@ elf32_arm_finish_dynamic_symbol (output_bfd, info, h, sym)
{
asection * sgot;
asection * srel;
- Elf_Internal_Rel rel;
+ Elf_Internal_Rela rel;
+ bfd_byte *loc;
/* This symbol has an entry in the global offset table. Set it
up. */
@@ -3413,30 +3794,33 @@ elf32_arm_finish_dynamic_symbol (output_bfd, info, h, sym)
+ sgot->output_offset
+ (h->got.offset &~ (bfd_vma) 1));
- /* If this is a -Bsymbolic link, and the symbol is defined
- locally, we just want to emit a RELATIVE reloc. The entry in
- the global offset table will already have been initialized in
- the relocate_section function. */
+ /* If this is a static link, or it is a -Bsymbolic link and the
+ symbol is defined locally or was forced to be local because
+ of a version file, we just want to emit a RELATIVE reloc.
+ The entry in the global offset table will already have been
+ initialized in the relocate_section function. */
if (info->shared
- && (info->symbolic || h->dynindx == -1)
- && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR))
- rel.r_info = ELF32_R_INFO (0, R_ARM_RELATIVE);
+ && SYMBOL_REFERENCES_LOCAL (info, h))
+ {
+ BFD_ASSERT((h->got.offset & 1) != 0);
+ rel.r_info = ELF32_R_INFO (0, R_ARM_RELATIVE);
+ }
else
{
+ BFD_ASSERT((h->got.offset & 1) == 0);
bfd_put_32 (output_bfd, (bfd_vma) 0, sgot->contents + h->got.offset);
rel.r_info = ELF32_R_INFO (h->dynindx, R_ARM_GLOB_DAT);
}
- bfd_elf32_swap_reloc_out (output_bfd, &rel,
- ((Elf32_External_Rel *) srel->contents
- + srel->reloc_count));
- ++srel->reloc_count;
+ loc = srel->contents + srel->reloc_count++ * sizeof (Elf32_External_Rel);
+ bfd_elf32_swap_reloc_out (output_bfd, &rel, loc);
}
if ((h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_COPY) != 0)
{
asection * s;
- Elf_Internal_Rel rel;
+ Elf_Internal_Rela rel;
+ bfd_byte *loc;
/* This symbol needs a copy reloc. Set it up. */
BFD_ASSERT (h->dynindx != -1
@@ -3451,10 +3835,8 @@ elf32_arm_finish_dynamic_symbol (output_bfd, info, h, sym)
+ h->root.u.def.section->output_section->vma
+ h->root.u.def.section->output_offset);
rel.r_info = ELF32_R_INFO (h->dynindx, R_ARM_COPY);
- bfd_elf32_swap_reloc_out (output_bfd, &rel,
- ((Elf32_External_Rel *) s->contents
- + s->reloc_count));
- ++s->reloc_count;
+ loc = s->contents + s->reloc_count++ * sizeof (Elf32_External_Rel);
+ bfd_elf32_swap_reloc_out (output_bfd, &rel, loc);
}
/* Mark _DYNAMIC and _GLOBAL_OFFSET_TABLE_ as absolute. */
@@ -3462,12 +3844,12 @@ elf32_arm_finish_dynamic_symbol (output_bfd, info, h, sym)
|| strcmp (h->root.root.string, "_GLOBAL_OFFSET_TABLE_") == 0)
sym->st_shndx = SHN_ABS;
- return true;
+ return TRUE;
}
/* Finish up the dynamic sections. */
-static boolean
+static bfd_boolean
elf32_arm_finish_dynamic_sections (output_bfd, info)
bfd * output_bfd;
struct bfd_link_info * info;
@@ -3548,16 +3930,57 @@ elf32_arm_finish_dynamic_sections (output_bfd, info)
}
bfd_elf32_swap_dyn_out (output_bfd, &dyn, dyncon);
break;
+
+ /* Set the bottom bit of DT_INIT/FINI if the
+ corresponding function is Thumb. */
+ case DT_INIT:
+ name = info->init_function;
+ goto get_sym;
+ case DT_FINI:
+ name = info->fini_function;
+ get_sym:
+ /* If it wasn't set by elf_bfd_final_link
+ then there is nothing to adjust. */
+ if (dyn.d_un.d_val != 0)
+ {
+ struct elf_link_hash_entry * eh;
+
+ eh = elf_link_hash_lookup (elf_hash_table (info), name,
+ FALSE, FALSE, TRUE);
+ if (eh != (struct elf_link_hash_entry *) NULL
+ && ELF_ST_TYPE (eh->type) == STT_ARM_TFUNC)
+ {
+ dyn.d_un.d_val |= 1;
+ bfd_elf32_swap_dyn_out (output_bfd, &dyn, dyncon);
+ }
+ }
+ break;
}
}
/* Fill in the first entry in the procedure linkage table. */
if (splt->_raw_size > 0)
{
+ bfd_vma got_displacement;
+
+ /* Calculate the displacement between the PLT slot and &GOT[0]. */
+ got_displacement = (sgot->output_section->vma
+ + sgot->output_offset
+ - splt->output_section->vma
+ - splt->output_offset
+ - 16);
+
bfd_put_32 (output_bfd, elf32_arm_plt0_entry[0], splt->contents + 0);
bfd_put_32 (output_bfd, elf32_arm_plt0_entry[1], splt->contents + 4);
bfd_put_32 (output_bfd, elf32_arm_plt0_entry[2], splt->contents + 8);
bfd_put_32 (output_bfd, elf32_arm_plt0_entry[3], splt->contents + 12);
+#ifdef FOUR_WORD_PLT
+ /* The displacement value goes in the otherwise-unused last word of
+ the second entry. */
+ bfd_put_32 (output_bfd, got_displacement, splt->contents + 28);
+#else
+ bfd_put_32 (output_bfd, got_displacement, splt->contents + 16);
+#endif
}
/* UnixWare sets the entsize of .plt to 4, although that doesn't
@@ -3580,7 +4003,7 @@ elf32_arm_finish_dynamic_sections (output_bfd, info)
elf_section_data (sgot->output_section)->this_hdr.sh_entsize = 4;
- return true;
+ return TRUE;
}
static void
@@ -3613,10 +4036,37 @@ elf32_arm_reloc_type_class (rela)
}
}
+static bfd_boolean elf32_arm_section_flags PARAMS ((flagword *, Elf_Internal_Shdr *));
+static void elf32_arm_final_write_processing PARAMS ((bfd *, bfd_boolean));
+
+/* Set the right machine number for an Arm ELF file. */
+
+static bfd_boolean
+elf32_arm_section_flags (flags, hdr)
+ flagword *flags;
+ Elf_Internal_Shdr *hdr;
+{
+ if (hdr->sh_type == SHT_NOTE)
+ *flags |= SEC_LINK_ONCE | SEC_LINK_DUPLICATES_SAME_CONTENTS;
+
+ return TRUE;
+}
+
+void
+elf32_arm_final_write_processing (abfd, linker)
+ bfd *abfd;
+ bfd_boolean linker ATTRIBUTE_UNUSED;
+{
+ bfd_arm_update_notes (abfd, ARM_NOTE_SECTION);
+}
#define ELF_ARCH bfd_arch_arm
#define ELF_MACHINE_CODE EM_ARM
+#ifdef __QNXTARGET__
+#define ELF_MAXPAGESIZE 0x1000
+#else
#define ELF_MAXPAGESIZE 0x8000
+#endif
#define bfd_elf32_bfd_copy_private_bfd_data elf32_arm_copy_private_bfd_data
#define bfd_elf32_bfd_merge_private_bfd_data elf32_arm_merge_private_bfd_data
@@ -3632,22 +4082,27 @@ elf32_arm_reloc_type_class (rela)
#define elf_backend_check_relocs elf32_arm_check_relocs
#define elf_backend_relocate_section elf32_arm_relocate_section
#define elf_backend_adjust_dynamic_symbol elf32_arm_adjust_dynamic_symbol
-#define elf_backend_create_dynamic_sections _bfd_elf_create_dynamic_sections
+#define elf_backend_create_dynamic_sections elf32_arm_create_dynamic_sections
#define elf_backend_finish_dynamic_symbol elf32_arm_finish_dynamic_symbol
#define elf_backend_finish_dynamic_sections elf32_arm_finish_dynamic_sections
#define elf_backend_size_dynamic_sections elf32_arm_size_dynamic_sections
#define elf_backend_post_process_headers elf32_arm_post_process_headers
#define elf_backend_reloc_type_class elf32_arm_reloc_type_class
+#define elf_backend_object_p elf32_arm_object_p
+#define elf_backend_section_flags elf32_arm_section_flags
+#define elf_backend_final_write_processing elf32_arm_final_write_processing
+#define elf_backend_copy_indirect_symbol elf32_arm_copy_indirect_symbol
+#define elf_backend_can_refcount 1
#define elf_backend_can_gc_sections 1
#define elf_backend_plt_readonly 1
#define elf_backend_want_got_plt 1
#define elf_backend_want_plt_sym 0
-#ifndef USE_REL
+#if !USE_REL
#define elf_backend_rela_normal 1
#endif
#define elf_backend_got_header_size 12
-#define elf_backend_plt_header_size PLT_ENTRY_SIZE
#include "elf32-target.h"
+
diff --git a/contrib/binutils/bfd/elf32-gen.c b/contrib/binutils/bfd/elf32-gen.c
index 58b5fc6..f2edf69 100644
--- a/contrib/binutils/bfd/elf32-gen.c
+++ b/contrib/binutils/bfd/elf32-gen.c
@@ -1,5 +1,6 @@
/* Generic support for 32-bit ELF
- Copyright 1993, 1995, 1998, 1999, 2001 Free Software Foundation, Inc.
+ Copyright 1993, 1995, 1998, 1999, 2001, 2002, 2004
+ Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -30,28 +31,28 @@ static reloc_howto_type dummy =
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
NULL, /* special_function */
"UNKNOWN", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false); /* pcrel_offset */
+ FALSE); /* pcrel_offset */
static void elf_generic_info_to_howto
- PARAMS ((bfd *, arelent *, Elf32_Internal_Rela *));
+ PARAMS ((bfd *, arelent *, Elf_Internal_Rela *));
static void elf_generic_info_to_howto_rel
- PARAMS ((bfd *, arelent *, Elf32_Internal_Rel *));
-static boolean elf32_generic_link_add_symbols
+ PARAMS ((bfd *, arelent *, Elf_Internal_Rela *));
+static bfd_boolean elf32_generic_link_add_symbols
PARAMS ((bfd *, struct bfd_link_info *));
static void
elf_generic_info_to_howto (abfd, bfd_reloc, elf_reloc)
bfd *abfd ATTRIBUTE_UNUSED;
arelent *bfd_reloc;
- Elf32_Internal_Rela *elf_reloc ATTRIBUTE_UNUSED;
+ Elf_Internal_Rela *elf_reloc ATTRIBUTE_UNUSED;
{
bfd_reloc->howto = &dummy;
}
@@ -60,12 +61,12 @@ static void
elf_generic_info_to_howto_rel (abfd, bfd_reloc, elf_reloc)
bfd *abfd ATTRIBUTE_UNUSED;
arelent *bfd_reloc;
- Elf32_Internal_Rel *elf_reloc ATTRIBUTE_UNUSED;
+ Elf_Internal_Rela *elf_reloc ATTRIBUTE_UNUSED;
{
bfd_reloc->howto = &dummy;
}
-static boolean
+static bfd_boolean
elf32_generic_link_add_symbols (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -84,10 +85,10 @@ elf32_generic_link_add_symbols (abfd, info)
ehdrp->e_machine);
bfd_set_error (bfd_error_wrong_format);
- return false;
+ return FALSE;
}
- return bfd_elf32_bfd_link_add_symbols (abfd, info);
+ return bfd_elf_link_add_symbols (abfd, info);
}
#define TARGET_LITTLE_SYM bfd_elf32_little_generic_vec
diff --git a/contrib/binutils/bfd/elf32-ppc.c b/contrib/binutils/bfd/elf32-ppc.c
index 9abdf61..4eb08ad 100644
--- a/contrib/binutils/bfd/elf32-ppc.c
+++ b/contrib/binutils/bfd/elf32-ppc.c
@@ -1,23 +1,24 @@
/* PowerPC-specific support for 32-bit ELF
- Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
- Free Software Foundation, Inc.
+ Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
+ 2004 Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the
+ Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
/* This file is based on a preliminary PowerPC ELF ABI. The
information may not match the final PowerPC ELF ABI. It includes
@@ -30,100 +31,24 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "libbfd.h"
#include "elf-bfd.h"
#include "elf/ppc.h"
+#include "elf32-ppc.h"
-#define USE_RELA /* we want RELA relocations, not REL */
+/* RELA relocations are used here. */
-static reloc_howto_type *ppc_elf_reloc_type_lookup
- PARAMS ((bfd *abfd, bfd_reloc_code_real_type code));
-static void ppc_elf_info_to_howto
- PARAMS ((bfd *abfd, arelent *cache_ptr, Elf32_Internal_Rela *dst));
-static void ppc_elf_howto_init PARAMS ((void));
-static int ppc_elf_sort_rela PARAMS ((const PTR, const PTR));
-static boolean ppc_elf_relax_section
- PARAMS ((bfd *, asection *, struct bfd_link_info *, boolean *));
static bfd_reloc_status_type ppc_elf_addr16_ha_reloc
- PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
-static boolean ppc_elf_object_p PARAMS ((bfd *));
-static boolean ppc_elf_set_private_flags PARAMS ((bfd *, flagword));
-static boolean ppc_elf_merge_private_bfd_data PARAMS ((bfd *, bfd *));
-
-static int ppc_elf_additional_program_headers PARAMS ((bfd *));
-static boolean ppc_elf_modify_segment_map PARAMS ((bfd *));
-
-static asection *ppc_elf_create_got
- PARAMS ((bfd *, struct bfd_link_info *));
-static boolean ppc_elf_create_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *));
-
-static boolean ppc_elf_section_from_shdr PARAMS ((bfd *,
- Elf32_Internal_Shdr *,
- const char *));
-static boolean ppc_elf_fake_sections
- PARAMS ((bfd *, Elf32_Internal_Shdr *, asection *));
-
-static elf_linker_section_t *ppc_elf_create_linker_section
- PARAMS ((bfd *abfd,
- struct bfd_link_info *info,
- enum elf_linker_section_enum));
-
-static boolean ppc_elf_check_relocs PARAMS ((bfd *,
- struct bfd_link_info *,
- asection *,
- const Elf_Internal_Rela *));
-
-static asection * ppc_elf_gc_mark_hook PARAMS ((asection *sec,
- struct bfd_link_info *info,
- Elf_Internal_Rela *rel,
- struct elf_link_hash_entry *h,
- Elf_Internal_Sym *sym));
-
-static boolean ppc_elf_gc_sweep_hook PARAMS ((bfd *abfd,
- struct bfd_link_info *info,
- asection *sec,
- const Elf_Internal_Rela *relocs));
-
-static boolean ppc_elf_adjust_dynamic_symbol PARAMS ((struct bfd_link_info *,
- struct elf_link_hash_entry *));
-
-static boolean ppc_elf_size_dynamic_sections PARAMS ((bfd *, struct bfd_link_info *));
-
-static boolean ppc_elf_relocate_section PARAMS ((bfd *,
- struct bfd_link_info *info,
- bfd *,
- asection *,
- bfd_byte *,
- Elf_Internal_Rela *relocs,
- Elf_Internal_Sym *local_syms,
- asection **));
-
-static boolean ppc_elf_add_symbol_hook PARAMS ((bfd *,
- struct bfd_link_info *,
- const Elf_Internal_Sym *,
- const char **,
- flagword *,
- asection **,
- bfd_vma *));
-
-static boolean ppc_elf_finish_dynamic_symbol PARAMS ((bfd *,
- struct bfd_link_info *,
- struct elf_link_hash_entry *,
- Elf_Internal_Sym *));
-
-static boolean ppc_elf_finish_dynamic_sections PARAMS ((bfd *, struct bfd_link_info *));
-static enum elf_reloc_type_class ppc_elf_reloc_type_class
- PARAMS ((const Elf_Internal_Rela *));
-static boolean ppc_elf_grok_prstatus
- PARAMS ((bfd *abfd, Elf_Internal_Note *note));
-static boolean ppc_elf_grok_psinfo
- PARAMS ((bfd *abfd, Elf_Internal_Note *note));
-
-#define BRANCH_PREDICT_BIT 0x200000 /* branch prediction bit for branch taken relocs */
-#define RA_REGISTER_MASK 0x001f0000 /* mask to set RA in memory instructions */
-#define RA_REGISTER_SHIFT 16 /* value to shift register by to insert RA */
+ (bfd *, arelent *, asymbol *, void *, asection *, bfd *, char **);
+static bfd_reloc_status_type ppc_elf_unhandled_reloc
+ (bfd *, arelent *, asymbol *, void *, asection *, bfd *, char **);
+
+/* Branch prediction bit for branch taken relocs. */
+#define BRANCH_PREDICT_BIT 0x200000
+/* Mask to set RA in memory instructions. */
+#define RA_REGISTER_MASK 0x001f0000
+/* Value to shift register by to insert RA. */
+#define RA_REGISTER_SHIFT 16
/* The name of the dynamic interpreter. This is put in the .interp
section. */
-
#define ELF_DYNAMIC_INTERPRETER "/usr/lib/ld.so.1"
/* The size in bytes of an entry in the procedure linkage table. */
@@ -135,25 +60,289 @@ static boolean ppc_elf_grok_psinfo
/* The number of single-slot PLT entries (the rest use two slots). */
#define PLT_NUM_SINGLE_ENTRIES 8192
-/* Will references to this symbol always reference the symbol
- in this object? */
-#define SYMBOL_REFERENCES_LOCAL(INFO, H) \
- ((! INFO->shared \
- || INFO->symbolic \
- || H->dynindx == -1 \
- || ELF_ST_VISIBILITY (H->other) == STV_INTERNAL \
- || ELF_ST_VISIBILITY (H->other) == STV_HIDDEN) \
- && (H->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0)
-
-/* Will _calls_ to this symbol always call the version in this object? */
-#define SYMBOL_CALLS_LOCAL(INFO, H) \
- ((! INFO->shared \
- || INFO->symbolic \
- || H->dynindx == -1 \
- || ELF_ST_VISIBILITY (H->other) != STV_DEFAULT) \
- && (H->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0)
+/* Some nop instructions. */
+#define NOP 0x60000000
+#define CROR_151515 0x4def7b82
+#define CROR_313131 0x4ffffb82
+
+/* Offset of tp and dtp pointers from start of TLS block. */
+#define TP_OFFSET 0x7000
+#define DTP_OFFSET 0x8000
+
+
+/* Enumeration to specify the special section. */
+enum elf_linker_section_enum
+{
+ LINKER_SECTION_SDATA,
+ LINKER_SECTION_SDATA2
+};
+
+/* Sections created by the linker. */
+
+typedef struct elf_linker_section
+{
+ /* pointer to the section */
+ asection *section;
+ /* pointer to the relocations needed for this section */
+ asection *rel_section;
+ /* pointer to the created symbol hash value */
+ struct elf_link_hash_entry *sym_hash;
+ /* offset of symbol from beginning of section */
+ bfd_vma sym_offset;
+} elf_linker_section_t;
+
+/* Linked list of allocated pointer entries. This hangs off of the
+ symbol lists, and provides allows us to return different pointers,
+ based on different addend's. */
+
+typedef struct elf_linker_section_pointers
+{
+ /* next allocated pointer for this symbol */
+ struct elf_linker_section_pointers *next;
+ /* offset of pointer from beginning of section */
+ bfd_vma offset;
+ /* addend used */
+ bfd_vma addend;
+ /* which linker section this is */
+ elf_linker_section_t *lsect;
+ /* whether address was written yet */
+ bfd_boolean written_address_p;
+} elf_linker_section_pointers_t;
+
+struct ppc_elf_obj_tdata
+{
+ struct elf_obj_tdata elf;
+
+ /* A mapping from local symbols to offsets into the various linker
+ sections added. This is index by the symbol index. */
+ elf_linker_section_pointers_t **linker_section_pointers;
+};
+
+#define ppc_elf_tdata(bfd) \
+ ((struct ppc_elf_obj_tdata *) (bfd)->tdata.any)
+
+#define elf_local_ptr_offsets(bfd) \
+ (ppc_elf_tdata (bfd)->linker_section_pointers)
+
+/* Override the generic function because we store some extras. */
+
+static bfd_boolean
+ppc_elf_mkobject (bfd *abfd)
+{
+ bfd_size_type amt = sizeof (struct ppc_elf_obj_tdata);
+ abfd->tdata.any = bfd_zalloc (abfd, amt);
+ if (abfd->tdata.any == NULL)
+ return FALSE;
+ return TRUE;
+}
+
+/* The PPC linker needs to keep track of the number of relocs that it
+ decides to copy as dynamic relocs in check_relocs for each symbol.
+ This is so that it can later discard them if they are found to be
+ unnecessary. We store the information in a field extending the
+ regular ELF linker hash table. */
+
+struct ppc_elf_dyn_relocs
+{
+ struct ppc_elf_dyn_relocs *next;
+
+ /* The input section of the reloc. */
+ asection *sec;
+
+ /* Total number of relocs copied for the input section. */
+ bfd_size_type count;
+
+ /* Number of pc-relative relocs copied for the input section. */
+ bfd_size_type pc_count;
+};
+
+/* PPC ELF linker hash entry. */
+
+struct ppc_elf_link_hash_entry
+{
+ struct elf_link_hash_entry elf;
+
+ /* If this symbol is used in the linker created sections, the processor
+ specific backend uses this field to map the field into the offset
+ from the beginning of the section. */
+ elf_linker_section_pointers_t *linker_section_pointer;
+
+ /* Track dynamic relocs copied for this symbol. */
+ struct ppc_elf_dyn_relocs *dyn_relocs;
+
+ /* Contexts in which symbol is used in the GOT (or TOC).
+ TLS_GD .. TLS_TLS bits are or'd into the mask as the
+ corresponding relocs are encountered during check_relocs.
+ tls_optimize clears TLS_GD .. TLS_TPREL when optimizing to
+ indicate the corresponding GOT entry type is not needed. */
+#define TLS_GD 1 /* GD reloc. */
+#define TLS_LD 2 /* LD reloc. */
+#define TLS_TPREL 4 /* TPREL reloc, => IE. */
+#define TLS_DTPREL 8 /* DTPREL reloc, => LD. */
+#define TLS_TLS 16 /* Any TLS reloc. */
+#define TLS_TPRELGD 32 /* TPREL reloc resulting from GD->IE. */
+ char tls_mask;
+};
+
+#define ppc_elf_hash_entry(ent) ((struct ppc_elf_link_hash_entry *) (ent))
+
+/* PPC ELF linker hash table. */
+
+struct ppc_elf_link_hash_table
+{
+ struct elf_link_hash_table elf;
+
+ /* Short-cuts to get to dynamic linker sections. */
+ asection *got;
+ asection *relgot;
+ asection *plt;
+ asection *relplt;
+ asection *dynbss;
+ asection *relbss;
+ asection *dynsbss;
+ asection *relsbss;
+ elf_linker_section_t *sdata;
+ elf_linker_section_t *sdata2;
+ asection *sbss;
+
+ /* Shortcut to .__tls_get_addr. */
+ struct elf_link_hash_entry *tls_get_addr;
+
+ /* TLS local dynamic got entry handling. */
+ union {
+ bfd_signed_vma refcount;
+ bfd_vma offset;
+ } tlsld_got;
+
+ /* Small local sym to section mapping cache. */
+ struct sym_sec_cache sym_sec;
+};
+
+/* Get the PPC ELF linker hash table from a link_info structure. */
+
+#define ppc_elf_hash_table(p) \
+ ((struct ppc_elf_link_hash_table *) (p)->hash)
+
+/* Create an entry in a PPC ELF linker hash table. */
+
+static struct bfd_hash_entry *
+ppc_elf_link_hash_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table,
+ const char *string)
+{
+ /* Allocate the structure if it has not already been allocated by a
+ subclass. */
+ if (entry == NULL)
+ {
+ entry = bfd_hash_allocate (table,
+ sizeof (struct ppc_elf_link_hash_entry));
+ if (entry == NULL)
+ return entry;
+ }
+
+ /* Call the allocation method of the superclass. */
+ entry = _bfd_elf_link_hash_newfunc (entry, table, string);
+ if (entry != NULL)
+ {
+ ppc_elf_hash_entry (entry)->linker_section_pointer = NULL;
+ ppc_elf_hash_entry (entry)->dyn_relocs = NULL;
+ ppc_elf_hash_entry (entry)->tls_mask = 0;
+ }
+
+ return entry;
+}
+
+/* Create a PPC ELF linker hash table. */
+
+static struct bfd_link_hash_table *
+ppc_elf_link_hash_table_create (bfd *abfd)
+{
+ struct ppc_elf_link_hash_table *ret;
+
+ ret = bfd_zmalloc (sizeof (struct ppc_elf_link_hash_table));
+ if (ret == NULL)
+ return NULL;
+
+ if (! _bfd_elf_link_hash_table_init (&ret->elf, abfd,
+ ppc_elf_link_hash_newfunc))
+ {
+ free (ret);
+ return NULL;
+ }
+
+ return &ret->elf.root;
+}
+
+/* If ELIMINATE_COPY_RELOCS is non-zero, the linker will try to avoid
+ copying dynamic variables from a shared lib into an app's dynbss
+ section, and instead use a dynamic relocation to point into the
+ shared lib. */
+#define ELIMINATE_COPY_RELOCS 1
+
+/* Copy the extra info we tack onto an elf_link_hash_entry. */
+
+static void
+ppc_elf_copy_indirect_symbol (const struct elf_backend_data *bed,
+ struct elf_link_hash_entry *dir,
+ struct elf_link_hash_entry *ind)
+{
+ struct ppc_elf_link_hash_entry *edir, *eind;
+
+ edir = (struct ppc_elf_link_hash_entry *) dir;
+ eind = (struct ppc_elf_link_hash_entry *) ind;
+
+ if (eind->dyn_relocs != NULL)
+ {
+ if (edir->dyn_relocs != NULL)
+ {
+ struct ppc_elf_dyn_relocs **pp;
+ struct ppc_elf_dyn_relocs *p;
+
+ if (ind->root.type == bfd_link_hash_indirect)
+ abort ();
+
+ /* Add reloc counts against the weak sym to the strong sym
+ list. Merge any entries against the same section. */
+ for (pp = &eind->dyn_relocs; (p = *pp) != NULL; )
+ {
+ struct ppc_elf_dyn_relocs *q;
+
+ for (q = edir->dyn_relocs; q != NULL; q = q->next)
+ if (q->sec == p->sec)
+ {
+ q->pc_count += p->pc_count;
+ q->count += p->count;
+ *pp = p->next;
+ break;
+ }
+ if (q == NULL)
+ pp = &p->next;
+ }
+ *pp = edir->dyn_relocs;
+ }
+
+ edir->dyn_relocs = eind->dyn_relocs;
+ eind->dyn_relocs = NULL;
+ }
+
+ edir->tls_mask |= eind->tls_mask;
+
+ if (ELIMINATE_COPY_RELOCS
+ && ind->root.type != bfd_link_hash_indirect
+ && (dir->elf_link_hash_flags & ELF_LINK_HASH_DYNAMIC_ADJUSTED) != 0)
+ /* If called to transfer flags for a weakdef during processing
+ of elf_adjust_dynamic_symbol, don't copy ELF_LINK_NON_GOT_REF.
+ We clear it ourselves for ELIMINATE_COPY_RELOCS. */
+ dir->elf_link_hash_flags |=
+ (ind->elf_link_hash_flags & (ELF_LINK_HASH_REF_DYNAMIC
+ | ELF_LINK_HASH_REF_REGULAR
+ | ELF_LINK_HASH_REF_REGULAR_NONWEAK
+ | ELF_LINK_HASH_NEEDS_PLT));
+ else
+ _bfd_elf_link_hash_copy_indirect (bed, dir, ind);
+}
-static reloc_howto_type *ppc_elf_howto_table[(int) R_PPC_max];
+static reloc_howto_type *ppc_elf_howto_table[R_PPC_max];
static reloc_howto_type ppc_elf_howto_raw[] = {
/* This reloc does nothing. */
@@ -161,30 +350,30 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_NONE", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* A standard 32 bit relocation. */
HOWTO (R_PPC_ADDR32, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_ADDR32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* An absolute 26 bit branch; the lower two bits must be zero.
FIXME: we don't check that, we just clear them. */
@@ -192,60 +381,60 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
26, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_ADDR24", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0x3fffffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* A standard 16 bit relocation. */
HOWTO (R_PPC_ADDR16, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_ADDR16", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* A 16 bit relocation without overflow. */
HOWTO (R_PPC_ADDR16_LO, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_ADDR16_LO", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* The high order 16 bits of an address. */
HOWTO (R_PPC_ADDR16_HI, /* type */
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_ADDR16_HI", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* The high order 16 bits of an address, plus 1 if the contents of
the low 16 bits, treated as a signed number, is negative. */
@@ -253,15 +442,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc_elf_addr16_ha_reloc, /* special_function */
"R_PPC_ADDR16_HA", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* An absolute 16 bit branch; the lower two bits must be zero.
FIXME: we don't check that, we just clear them. */
@@ -269,15 +458,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_ADDR14", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* An absolute 16 bit branch, for which bit 10 should be set to
indicate that the branch is expected to be taken. The lower two
@@ -286,15 +475,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_ADDR14_BRTAKEN",/* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* An absolute 16 bit branch, for which bit 10 should be set to
indicate that the branch is not expected to be taken. The lower
@@ -303,45 +492,45 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_ADDR14_BRNTAKEN",/* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* A relative 26 bit branch; the lower two bits must be zero. */
HOWTO (R_PPC_REL24, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
26, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_REL24", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0x3fffffc, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* A relative 16 bit branch; the lower two bits must be zero. */
HOWTO (R_PPC_REL14, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_REL14", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffc, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* A relative 16 bit branch. Bit 10 should be set to indicate that
the branch is expected to be taken. The lower two bits must be
@@ -350,15 +539,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_REL14_BRTAKEN", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffc, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* A relative 16 bit branch. Bit 10 should be set to indicate that
the branch is not expected to be taken. The lower two bits must
@@ -367,15 +556,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_REL14_BRNTAKEN",/* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffc, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* Like R_PPC_ADDR16, but referring to the GOT table entry for the
symbol. */
@@ -383,15 +572,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_GOT16", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC_ADDR16_LO, but referring to the GOT table entry for
the symbol. */
@@ -399,15 +588,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_GOT16_LO", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC_ADDR16_HI, but referring to the GOT table entry for
the symbol. */
@@ -415,15 +604,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_GOT16_HI", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC_ADDR16_HA, but referring to the GOT table entry for
the symbol. */
@@ -431,15 +620,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
ppc_elf_addr16_ha_reloc, /* special_function */
"R_PPC_GOT16_HA", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC_REL24, but referring to the procedure linkage table
entry for the symbol. */
@@ -447,15 +636,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
26, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_PLTREL24", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0x3fffffc, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* This is used only by the dynamic linker. The symbol should exist
both in the object being run and in some shared library. The
@@ -466,15 +655,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_COPY", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC_ADDR32, but used when setting global offset table
entries. */
@@ -482,30 +671,30 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_GLOB_DAT", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Marks a procedure linkage table entry for a symbol. */
HOWTO (R_PPC_JMP_SLOT, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_JMP_SLOT", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Used only by the dynamic linker. When the object is run, this
longword is set to the load address of the object, plus the
@@ -514,15 +703,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_RELATIVE", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC_REL24, but uses the value of the symbol within the
object rather than the final value. Normally used for
@@ -531,60 +720,60 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
26, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_LOCAL24PC", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0x3fffffc, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* Like R_PPC_ADDR32, but may be unaligned. */
HOWTO (R_PPC_UADDR32, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_UADDR32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC_ADDR16, but may be unaligned. */
HOWTO (R_PPC_UADDR16, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_UADDR16", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 32-bit PC relative */
HOWTO (R_PPC_REL32, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_REL32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffffffff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* 32-bit relocation to the symbol's procedure linkage table.
FIXME: not supported. */
@@ -592,15 +781,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_PLT32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 32-bit PC relative relocation to the symbol's procedure linkage table.
FIXME: not supported. */
@@ -608,15 +797,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_PLTREL32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* Like R_PPC_ADDR16_LO, but referring to the PLT table entry for
the symbol. */
@@ -624,15 +813,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_PLT16_LO", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC_ADDR16_HI, but referring to the PLT table entry for
the symbol. */
@@ -640,15 +829,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_PLT16_HI", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC_ADDR16_HA, but referring to the PLT table entry for
the symbol. */
@@ -656,15 +845,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
ppc_elf_addr16_ha_reloc, /* special_function */
"R_PPC_PLT16_HA", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* A sign-extended 16 bit value relative to _SDA_BASE_, for use with
small data items. */
@@ -672,138 +861,568 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_SDAREL16", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 16-bit section relative relocation. */
HOWTO (R_PPC_SECTOFF, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_SECTOFF", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 16-bit lower half section relative relocation. */
HOWTO (R_PPC_SECTOFF_LO, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_SECTOFF_LO", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 16-bit upper half section relative relocation. */
HOWTO (R_PPC_SECTOFF_HI, /* type */
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_SECTOFF_HI", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 16-bit upper half adjusted section relative relocation. */
HOWTO (R_PPC_SECTOFF_HA, /* type */
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
ppc_elf_addr16_ha_reloc, /* special_function */
"R_PPC_SECTOFF_HA", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Marker reloc for TLS. */
+ HOWTO (R_PPC_TLS,
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_PPC_TLS", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Computes the load module index of the load module that contains the
+ definition of its TLS sym. */
+ HOWTO (R_PPC_DTPMOD32,
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_DTPMOD32", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffffffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Computes a dtv-relative displacement, the difference between the value
+ of sym+add and the base address of the thread-local storage block that
+ contains the definition of sym, minus 0x8000. */
+ HOWTO (R_PPC_DTPREL32,
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_DTPREL32", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffffffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* A 16 bit dtprel reloc. */
+ HOWTO (R_PPC_DTPREL16,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_DTPREL16", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like DTPREL16, but no overflow. */
+ HOWTO (R_PPC_DTPREL16_LO,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_DTPREL16_LO", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like DTPREL16_LO, but next higher group of 16 bits. */
+ HOWTO (R_PPC_DTPREL16_HI,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_DTPREL16_HI", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like DTPREL16_HI, but adjust for low 16 bits. */
+ HOWTO (R_PPC_DTPREL16_HA,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_DTPREL16_HA", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Computes a tp-relative displacement, the difference between the value of
+ sym+add and the value of the thread pointer (r13). */
+ HOWTO (R_PPC_TPREL32,
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_TPREL32", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffffffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* A 16 bit tprel reloc. */
+ HOWTO (R_PPC_TPREL16,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_TPREL16", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like TPREL16, but no overflow. */
+ HOWTO (R_PPC_TPREL16_LO,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_TPREL16_LO", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like TPREL16_LO, but next higher group of 16 bits. */
+ HOWTO (R_PPC_TPREL16_HI,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_TPREL16_HI", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like TPREL16_HI, but adjust for low 16 bits. */
+ HOWTO (R_PPC_TPREL16_HA,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_TPREL16_HA", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Allocates two contiguous entries in the GOT to hold a tls_index structure,
+ with values (sym+add)@dtpmod and (sym+add)@dtprel, and computes the offset
+ to the first entry. */
+ HOWTO (R_PPC_GOT_TLSGD16,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_GOT_TLSGD16", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TLSGD16, but no overflow. */
+ HOWTO (R_PPC_GOT_TLSGD16_LO,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_GOT_TLSGD16_LO", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TLSGD16_LO, but next higher group of 16 bits. */
+ HOWTO (R_PPC_GOT_TLSGD16_HI,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_GOT_TLSGD16_HI", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TLSGD16_HI, but adjust for low 16 bits. */
+ HOWTO (R_PPC_GOT_TLSGD16_HA,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_GOT_TLSGD16_HA", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Allocates two contiguous entries in the GOT to hold a tls_index structure,
+ with values (sym+add)@dtpmod and zero, and computes the offset to the
+ first entry. */
+ HOWTO (R_PPC_GOT_TLSLD16,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_GOT_TLSLD16", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TLSLD16, but no overflow. */
+ HOWTO (R_PPC_GOT_TLSLD16_LO,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_GOT_TLSLD16_LO", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TLSLD16_LO, but next higher group of 16 bits. */
+ HOWTO (R_PPC_GOT_TLSLD16_HI,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_GOT_TLSLD16_HI", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TLSLD16_HI, but adjust for low 16 bits. */
+ HOWTO (R_PPC_GOT_TLSLD16_HA,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_GOT_TLSLD16_HA", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Allocates an entry in the GOT with value (sym+add)@dtprel, and computes
+ the offset to the entry. */
+ HOWTO (R_PPC_GOT_DTPREL16,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_GOT_DTPREL16", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_DTPREL16, but no overflow. */
+ HOWTO (R_PPC_GOT_DTPREL16_LO,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_GOT_DTPREL16_LO", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_DTPREL16_LO, but next higher group of 16 bits. */
+ HOWTO (R_PPC_GOT_DTPREL16_HI,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_GOT_DTPREL16_HI", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_DTPREL16_HI, but adjust for low 16 bits. */
+ HOWTO (R_PPC_GOT_DTPREL16_HA,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_GOT_DTPREL16_HA", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Allocates an entry in the GOT with value (sym+add)@tprel, and computes the
+ offset to the entry. */
+ HOWTO (R_PPC_GOT_TPREL16,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_GOT_TPREL16", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TPREL16, but no overflow. */
+ HOWTO (R_PPC_GOT_TPREL16_LO,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_GOT_TPREL16_LO", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TPREL16_LO, but next higher group of 16 bits. */
+ HOWTO (R_PPC_GOT_TPREL16_HI,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_GOT_TPREL16_HI", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TPREL16_HI, but adjust for low 16 bits. */
+ HOWTO (R_PPC_GOT_TPREL16_HA,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc_elf_unhandled_reloc, /* special_function */
+ "R_PPC_GOT_TPREL16_HA", /* name */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* The remaining relocs are from the Embedded ELF ABI, and are not
in the SVR4 ELF ABI. */
- /* 32 bit value resulting from the addend minus the symbol */
+ /* 32 bit value resulting from the addend minus the symbol. */
HOWTO (R_PPC_EMB_NADDR32, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_EMB_NADDR32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
- /* 16 bit value resulting from the addend minus the symbol */
+ /* 16 bit value resulting from the addend minus the symbol. */
HOWTO (R_PPC_EMB_NADDR16, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_EMB_NADDR16", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
- /* 16 bit value resulting from the addend minus the symbol */
+ /* 16 bit value resulting from the addend minus the symbol. */
HOWTO (R_PPC_EMB_NADDR16_LO, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_EMB_ADDR16_LO", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
- /* The high order 16 bits of the addend minus the symbol */
+ /* The high order 16 bits of the addend minus the symbol. */
HOWTO (R_PPC_EMB_NADDR16_HI, /* type */
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_EMB_NADDR16_HI", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* The high order 16 bits of the result of the addend minus the address,
plus 1 if the contents of the low 16 bits, treated as a signed number,
@@ -812,49 +1431,49 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc_elf_addr16_ha_reloc, /* special_function */
"R_PPC_EMB_NADDR16_HA", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 16 bit value resulting from allocating a 4 byte word to hold an
address in the .sdata section, and returning the offset from
- _SDA_BASE_ for that relocation */
+ _SDA_BASE_ for that relocation. */
HOWTO (R_PPC_EMB_SDAI16, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_EMB_SDAI16", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 16 bit value resulting from allocating a 4 byte word to hold an
address in the .sdata2 section, and returning the offset from
- _SDA2_BASE_ for that relocation */
+ _SDA2_BASE_ for that relocation. */
HOWTO (R_PPC_EMB_SDA2I16, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_EMB_SDA2I16", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* A sign-extended 16 bit value relative to _SDA2_BASE_, for use with
small data items. */
@@ -862,15 +1481,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_EMB_SDA2REL", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Relocate against either _SDA_BASE_ or _SDA2_BASE_, filling in the 16 bit
signed offset from the appropriate base, and filling in the register
@@ -879,15 +1498,15 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_EMB_SDA21", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Relocation not handled: R_PPC_EMB_MRKREF */
/* Relocation not handled: R_PPC_EMB_RELSEC16 */
@@ -903,440 +1522,594 @@ static reloc_howto_type ppc_elf_howto_raw[] = {
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_EMB_RELSDA", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
+
+ /* Phony relocs to handle branch stubs. */
+ HOWTO (R_PPC_RELAX32, /* type */
+ 0, /* rightshift */
+ 0, /* size */
+ 0, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_PPC_RELAX32", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0, /* dst_mask */
+ FALSE), /* pcrel_offset */
- /* GNU extension to record C++ vtable hierarchy */
+ HOWTO (R_PPC_RELAX32PC, /* type */
+ 0, /* rightshift */
+ 0, /* size */
+ 0, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_PPC_RELAX32PC", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* GNU extension to record C++ vtable hierarchy. */
HOWTO (R_PPC_GNU_VTINHERIT, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
NULL, /* special_function */
"R_PPC_GNU_VTINHERIT", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
- /* GNU extension to record C++ vtable member usage */
+ /* GNU extension to record C++ vtable member usage. */
HOWTO (R_PPC_GNU_VTENTRY, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
NULL, /* special_function */
"R_PPC_GNU_VTENTRY", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
- /* Phony reloc to handle AIX style TOC entries */
+ /* Phony reloc to handle AIX style TOC entries. */
HOWTO (R_PPC_TOC16, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC_TOC16", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
};
/* Initialize the ppc_elf_howto_table, so that linear accesses can be done. */
static void
-ppc_elf_howto_init ()
+ppc_elf_howto_init (void)
{
unsigned int i, type;
- for (i = 0; i < sizeof (ppc_elf_howto_raw) / sizeof (ppc_elf_howto_raw[0]); i++)
+ for (i = 0;
+ i < sizeof (ppc_elf_howto_raw) / sizeof (ppc_elf_howto_raw[0]);
+ i++)
{
type = ppc_elf_howto_raw[i].type;
- BFD_ASSERT (type < sizeof (ppc_elf_howto_table) / sizeof (ppc_elf_howto_table[0]));
+ if (type >= (sizeof (ppc_elf_howto_table)
+ / sizeof (ppc_elf_howto_table[0])))
+ abort ();
ppc_elf_howto_table[type] = &ppc_elf_howto_raw[i];
}
}
-/* This function handles relaxing for the PPC with option --mpc860c0[=<n>].
-
- The MPC860, revision C0 or earlier contains a bug in the die.
- If all of the following conditions are true, the next instruction
- to be executed *may* be treated as a no-op.
- 1/ A forward branch is executed.
- 2/ The branch is predicted as not taken.
- 3/ The branch is taken.
- 4/ The branch is located in the last 5 words of a page.
- (The EOP limit is 5 by default but may be specified as any value from 1-10.)
-
- Our software solution is to detect these problematic branches in a
- linker pass and modify them as follows:
- 1/ Unconditional branches - Since these are always predicted taken,
- there is no problem and no action is required.
- 2/ Conditional backward branches - No problem, no action required.
- 3/ Conditional forward branches - Ensure that the "inverse prediction
- bit" is set (ensure it is predicted taken).
- 4/ Conditional register branches - Ensure that the "y bit" is set
- (ensure it is predicted taken).
-*/
-
-/* Sort sections by address. */
+#define ARRAY_SIZE(a) (sizeof (a) / sizeof ((a)[0]))
-static int
-ppc_elf_sort_rela (arg1, arg2)
- const PTR arg1;
- const PTR arg2;
-{
- const Elf_Internal_Rela **rela1 = (const Elf_Internal_Rela**) arg1;
- const Elf_Internal_Rela **rela2 = (const Elf_Internal_Rela**) arg2;
-
- /* Sort by offset. */
- return ((*rela1)->r_offset - (*rela2)->r_offset);
-}
-
-static boolean
-ppc_elf_relax_section (abfd, isec, link_info, again)
- bfd *abfd;
- asection *isec;
- struct bfd_link_info *link_info;
- boolean *again;
+static const int shared_stub_entry[] =
+ {
+ 0x7c0802a6, /* mflr 0 */
+ 0x429f0005, /* bcl 20, 31, .Lxxx */
+ 0x7d6802a6, /* mflr 11 */
+ 0x3d6b0000, /* addis 11, 11, (xxx-.Lxxx)@ha */
+ 0x396b0018, /* addi 11, 11, (xxx-.Lxxx)@l */
+ 0x7c0803a6, /* mtlr 0 */
+ 0x7d6903a6, /* mtctr 11 */
+ 0x4e800420, /* bctr */
+ };
+
+static const int stub_entry[] =
+ {
+ 0x3d600000, /* lis 11,xxx@ha */
+ 0x396b0000, /* addi 11,11,xxx@l */
+ 0x7d6903a6, /* mtctr 11 */
+ 0x4e800420, /* bctr */
+ };
+
+
+static bfd_boolean
+ppc_elf_relax_section (bfd *abfd,
+ asection *isec,
+ struct bfd_link_info *link_info,
+ bfd_boolean *again)
{
-#define PAGESIZE 0x1000
+ struct one_fixup
+ {
+ struct one_fixup *next;
+ asection *tsec;
+ bfd_vma toff;
+ bfd_vma trampoff;
+ };
+ Elf_Internal_Shdr *symtab_hdr;
bfd_byte *contents = NULL;
- bfd_byte *free_contents = NULL;
+ Elf_Internal_Sym *isymbuf = NULL;
Elf_Internal_Rela *internal_relocs = NULL;
- Elf_Internal_Rela *free_relocs = NULL;
- Elf_Internal_Rela **rela_comb = NULL;
- int comb_curr, comb_count;
+ Elf_Internal_Rela *irel, *irelend;
+ struct one_fixup *fixups = NULL;
+ bfd_boolean changed;
+ struct ppc_elf_link_hash_table *ppc_info;
+ bfd_size_type trampoff;
+
+ *again = FALSE;
- /* We never have to do this more than once per input section. */
- *again = false;
+ /* Nothing to do if there are no relocations. */
+ if ((isec->flags & SEC_RELOC) == 0 || isec->reloc_count == 0)
+ return TRUE;
/* If needed, initialize this section's cooked size. */
if (isec->_cooked_size == 0)
- isec->_cooked_size = isec->_raw_size;
+ isec->_cooked_size = isec->_raw_size;
- /* We're only interested in text sections which overlap the
- troublesome area at the end of a page. */
- if (link_info->mpc860c0 && (isec->flags & SEC_CODE) && isec->_cooked_size)
+ trampoff = (isec->_cooked_size + 3) & (bfd_vma) -4;
+ /* Space for a branch around any trampolines. */
+ trampoff += 4;
+
+ symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
+
+ /* Get a copy of the native relocations. */
+ internal_relocs = _bfd_elf_link_read_relocs (abfd, isec, NULL, NULL,
+ link_info->keep_memory);
+ if (internal_relocs == NULL)
+ goto error_return;
+
+ ppc_info = ppc_elf_hash_table (link_info);
+ irelend = internal_relocs + isec->reloc_count;
+
+ /* Get the section contents. */
+ /* Get cached copy if it exists. */
+ if (elf_section_data (isec)->this_hdr.contents != NULL)
+ contents = elf_section_data (isec)->this_hdr.contents;
+ else
{
- bfd_vma dot, end_page, end_section;
- boolean section_modified;
+ /* Go get them off disk. */
+ contents = bfd_malloc (isec->_raw_size);
+ if (contents == NULL)
+ goto error_return;
- /* Get the section contents. */
- /* Get cached copy if it exists. */
- if (elf_section_data (isec)->this_hdr.contents != NULL)
- contents = elf_section_data (isec)->this_hdr.contents;
+ if (!bfd_get_section_contents (abfd, isec, contents, 0, isec->_raw_size))
+ goto error_return;
+ }
+
+ for (irel = internal_relocs; irel < irelend; irel++)
+ {
+ unsigned long r_type = ELF32_R_TYPE (irel->r_info);
+ bfd_vma symaddr, reladdr, toff, roff;
+ asection *tsec;
+ struct one_fixup *f;
+ size_t insn_offset = 0;
+ bfd_vma max_branch_offset, val;
+ bfd_byte *hit_addr;
+ unsigned long t0;
+
+ switch (r_type)
+ {
+ case R_PPC_REL24:
+ case R_PPC_LOCAL24PC:
+ case R_PPC_PLTREL24:
+ max_branch_offset = 1 << 25;
+ break;
+
+ case R_PPC_REL14:
+ case R_PPC_REL14_BRTAKEN:
+ case R_PPC_REL14_BRNTAKEN:
+ max_branch_offset = 1 << 15;
+ break;
+
+ default:
+ continue;
+ }
+
+ /* Get the value of the symbol referred to by the reloc. */
+ if (ELF32_R_SYM (irel->r_info) < symtab_hdr->sh_info)
+ {
+ /* A local symbol. */
+ Elf_Internal_Sym *isym;
+
+ /* Read this BFD's local symbols. */
+ if (isymbuf == NULL)
+ {
+ isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+ if (isymbuf == NULL)
+ isymbuf = bfd_elf_get_elf_syms (abfd, symtab_hdr,
+ symtab_hdr->sh_info, 0,
+ NULL, NULL, NULL);
+ if (isymbuf == 0)
+ goto error_return;
+ }
+ isym = isymbuf + ELF32_R_SYM (irel->r_info);
+ if (isym->st_shndx == SHN_UNDEF)
+ continue; /* We can't do anything with undefined symbols. */
+ else if (isym->st_shndx == SHN_ABS)
+ tsec = bfd_abs_section_ptr;
+ else if (isym->st_shndx == SHN_COMMON)
+ tsec = bfd_com_section_ptr;
+ else
+ tsec = bfd_section_from_elf_index (abfd, isym->st_shndx);
+
+ toff = isym->st_value;
+ }
else
{
- /* Go get them off disk. */
- contents = (bfd_byte *) bfd_malloc (isec->_raw_size);
- if (contents == NULL)
- goto error_return;
- free_contents = contents;
-
- if (! bfd_get_section_contents (abfd, isec, contents,
- (file_ptr) 0, isec->_raw_size))
- goto error_return;
- }
-
- comb_curr = 0;
- comb_count = 0;
- if (isec->reloc_count)
- {
- unsigned n;
- bfd_size_type amt;
-
- /* Get a copy of the native relocations. */
- internal_relocs = _bfd_elf32_link_read_relocs (
- abfd, isec, (PTR) NULL, (Elf_Internal_Rela *) NULL,
- link_info->keep_memory);
- if (internal_relocs == NULL)
- goto error_return;
- if (! link_info->keep_memory)
- free_relocs = internal_relocs;
-
- /* Setup a faster access method for the reloc info we need. */
- amt = isec->reloc_count;
- amt *= sizeof (Elf_Internal_Rela*);
- rela_comb = (Elf_Internal_Rela**) bfd_malloc (amt);
- if (rela_comb == NULL)
- goto error_return;
- for (n = 0; n < isec->reloc_count; ++n)
- {
- long r_type;
-
- r_type = ELF32_R_TYPE (internal_relocs[n].r_info);
- if (r_type < 0 || r_type >= (int) R_PPC_max)
- goto error_return;
-
- /* Prologue constants are sometimes present in the ".text"
- sections and they can be identified by their associated relocation.
- We don't want to process those words and some others which
- can also be identified by their relocations. However, not all
- conditional branches will have a relocation so we will
- only ignore words that 1) have a reloc, and 2) the reloc
- is not applicable to a conditional branch.
- The array rela_comb is built here for use in the EOP scan loop. */
- switch (r_type)
- {
- case R_PPC_ADDR14_BRNTAKEN: /* absolute, predicted not taken */
- case R_PPC_REL14: /* relative cond. br. */
- case R_PPC_REL14_BRNTAKEN: /* rel. cond. br., predicted not taken */
- /* We should check the instruction. */
- break;
- default:
- /* The word is not a conditional branch - ignore it. */
- rela_comb[comb_count++] = &internal_relocs[n];
- break;
- }
- }
- if (comb_count > 1)
- qsort (rela_comb, (size_t) comb_count, sizeof (int), ppc_elf_sort_rela);
- }
-
- /* Enumerate each EOP region that overlaps this section. */
- end_section = isec->vma + isec->_cooked_size;
- dot = end_page = (isec->vma | (PAGESIZE - 1)) + 1;
- dot -= link_info->mpc860c0;
- section_modified = false;
- if (dot < isec->vma) /* Increment the start position if this section */
- dot = isec->vma; /* begins in the middle of its first EOP region. */
- for (;
- dot < end_section;
- dot += PAGESIZE, end_page += PAGESIZE)
- {
-
- /* Check each word in this EOP region. */
- for (; dot < end_page; dot += 4)
- {
- bfd_vma isec_offset;
- unsigned long insn;
- boolean skip, modified;
-
- /* Don't process this word if there is a relocation for it and
- the relocation indicates the word is not a conditional branch. */
- skip = false;
- isec_offset = dot - isec->vma;
- for (; comb_curr<comb_count; ++comb_curr)
- {
- bfd_vma r_offset;
-
- r_offset = rela_comb[comb_curr]->r_offset;
- if (r_offset >= isec_offset)
- {
- if (r_offset == isec_offset) skip = true;
- break;
- }
- }
- if (skip) continue;
-
- /* Check the current word for a problematic conditional branch. */
-#define BO0(insn) ((insn) & 0x02000000)
-#define BO2(insn) ((insn) & 0x00800000)
-#define BO4(insn) ((insn) & 0x00200000)
- insn = (unsigned long) bfd_get_32 (abfd, contents + isec_offset);
- modified = false;
- if ((insn & 0xFc000000) == 0x40000000)
- {
- /* Instruction is BCx */
- if ((!BO0(insn) || !BO2(insn)) && !BO4(insn))
- {
- bfd_vma target;
- /* This branch is predicted as "normal".
- If this is a forward branch, it is problematic. */
-
- target = insn & 0x0000Fffc; /*extract*/
- target = (target ^ 0x8000) - 0x8000; /*sign extend*/
- if ((insn & 0x00000002) == 0)
- target += dot; /*convert to abs*/
- if (target > dot)
- {
- insn |= 0x00200000; /* set the prediction bit */
- modified = true;
- }
- }
- }
- else if ((insn & 0xFc00Fffe) == 0x4c000420)
- {
- /* Instruction is BCCTRx */
- if ((!BO0(insn) || !BO2(insn)) && !BO4(insn))
- {
- /* This branch is predicted as not-taken.
- If this is a forward branch, it is problematic.
- Since we can't tell statically if it will branch forward,
- always set the prediction bit. */
- insn |= 0x00200000; /* set the prediction bit */
- modified = true;
- }
- }
- else if ((insn & 0xFc00Fffe) == 0x4c000020)
- {
- /* Instruction is BCLRx */
- if ((!BO0(insn) || !BO2(insn)) && !BO4(insn))
- {
- /* This branch is predicted as not-taken.
- If this is a forward branch, it is problematic.
- Since we can't tell statically if it will branch forward,
- always set the prediction bit. */
- insn |= 0x00200000; /* set the prediction bit */
- modified = true;
- }
- }
-#undef BO0
-#undef BO2
-#undef BO4
- if (modified)
- {
- bfd_put_32 (abfd, (bfd_vma) insn, contents + isec_offset);
- section_modified = true;
- }
- }
- }
- if (section_modified)
+ /* Global symbol handling. */
+ unsigned long indx;
+ struct elf_link_hash_entry *h;
+
+ indx = ELF32_R_SYM (irel->r_info) - symtab_hdr->sh_info;
+ h = elf_sym_hashes (abfd)[indx];
+
+ while (h->root.type == bfd_link_hash_indirect
+ || h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ if (r_type == R_PPC_PLTREL24
+ && ppc_info->plt != NULL
+ && h->plt.offset != (bfd_vma) -1)
+ {
+ tsec = ppc_info->plt;
+ toff = h->plt.offset;
+ }
+ else if (h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak)
+ {
+ tsec = h->root.u.def.section;
+ toff = h->root.u.def.value;
+ }
+ else
+ continue;
+ }
+
+ /* If the branch and target are in the same section, you have
+ no hope of adding stubs. We'll error out later should the
+ branch overflow. */
+ if (tsec == isec)
+ continue;
+
+ toff += irel->r_addend;
+ if (tsec->sec_info_type == ELF_INFO_TYPE_MERGE)
+ toff = _bfd_merged_section_offset (abfd, &tsec,
+ elf_section_data (tsec)->sec_info,
+ toff, 0);
+
+ symaddr = tsec->output_section->vma + tsec->output_offset + toff;
+
+ roff = irel->r_offset;
+ reladdr = isec->output_section->vma + isec->output_offset + roff;
+
+ /* If the branch is in range, no need to do anything. */
+ if (symaddr - reladdr + max_branch_offset < 2 * max_branch_offset)
+ continue;
+
+ /* Look for an existing fixup to this address. */
+ for (f = fixups; f ; f = f->next)
+ if (f->tsec == tsec && f->toff == toff)
+ break;
+
+ if (f == NULL)
{
- elf_section_data (isec)->this_hdr.contents = contents;
- free_contents = NULL;
+ size_t size;
+ unsigned long stub_rtype;
+
+ val = trampoff - roff;
+ if (val >= max_branch_offset)
+ /* Oh dear, we can't reach a trampoline. Don't try to add
+ one. We'll report an error later. */
+ continue;
+
+ if (link_info->shared)
+ {
+ size = 4 * ARRAY_SIZE (shared_stub_entry);
+ insn_offset = 12;
+ stub_rtype = R_PPC_RELAX32PC;
+ }
+ else
+ {
+ size = 4 * ARRAY_SIZE (stub_entry);
+ insn_offset = 0;
+ stub_rtype = R_PPC_RELAX32;
+ }
+
+ /* Hijack the old relocation. Since we need two
+ relocations for this use a "composite" reloc. */
+ irel->r_info = ELF32_R_INFO (ELF32_R_SYM (irel->r_info),
+ stub_rtype);
+ irel->r_offset = trampoff + insn_offset;
+
+ /* Record the fixup so we don't do it again this section. */
+ f = bfd_malloc (sizeof (*f));
+ f->next = fixups;
+ f->tsec = tsec;
+ f->toff = toff;
+ f->trampoff = trampoff;
+ fixups = f;
+
+ trampoff += size;
+ }
+ else
+ {
+ val = f->trampoff - roff;
+ if (val >= max_branch_offset)
+ continue;
+
+ /* Nop out the reloc, since we're finalizing things here. */
+ irel->r_info = ELF32_R_INFO (0, R_PPC_NONE);
+ }
+
+ /* Fix up the existing branch to hit the trampoline. */
+ hit_addr = contents + roff;
+ switch (r_type)
+ {
+ case R_PPC_REL24:
+ case R_PPC_LOCAL24PC:
+ case R_PPC_PLTREL24:
+ t0 = bfd_get_32 (abfd, hit_addr);
+ t0 &= ~0x3fffffc;
+ t0 |= val & 0x3fffffc;
+ bfd_put_32 (abfd, t0, hit_addr);
+ break;
+
+ case R_PPC_REL14:
+ case R_PPC_REL14_BRTAKEN:
+ case R_PPC_REL14_BRNTAKEN:
+ t0 = bfd_get_32 (abfd, hit_addr);
+ t0 &= ~0xfffc;
+ t0 |= val & 0xfffc;
+ bfd_put_32 (abfd, t0, hit_addr);
+ break;
}
}
- if (rela_comb != NULL)
+ /* Write out the trampolines. */
+ changed = fixups != NULL;
+ if (fixups != NULL)
{
- free (rela_comb);
- rela_comb = NULL;
+ const int *stub;
+ bfd_byte *dest;
+ bfd_vma val;
+ int i, size;
+
+ do
+ {
+ struct one_fixup *f = fixups;
+ fixups = fixups->next;
+ free (f);
+ }
+ while (fixups);
+
+ contents = bfd_realloc (contents, trampoff);
+ if (contents == NULL)
+ goto error_return;
+
+ isec->_cooked_size = (isec->_cooked_size + 3) & (bfd_vma) -4;
+ /* Branch around the trampolines. */
+ val = trampoff - isec->_cooked_size + 0x48000000;
+ dest = contents + isec->_cooked_size;
+ isec->_cooked_size = trampoff;
+ bfd_put_32 (abfd, val, dest);
+ dest += 4;
+
+ if (link_info->shared)
+ {
+ stub = shared_stub_entry;
+ size = ARRAY_SIZE (shared_stub_entry);
+ }
+ else
+ {
+ stub = stub_entry;
+ size = ARRAY_SIZE (stub_entry);
+ }
+
+ i = 0;
+ while (dest < contents + trampoff)
+ {
+ bfd_put_32 (abfd, stub[i], dest);
+ i++;
+ if (i == size)
+ i = 0;
+ dest += 4;
+ }
+ BFD_ASSERT (i == 0);
}
- if (free_relocs != NULL)
+ if (isymbuf != NULL
+ && symtab_hdr->contents != (unsigned char *) isymbuf)
{
- free (free_relocs);
- free_relocs = NULL;
+ if (! link_info->keep_memory)
+ free (isymbuf);
+ else
+ {
+ /* Cache the symbols for elf_link_input_bfd. */
+ symtab_hdr->contents = (unsigned char *) isymbuf;
+ }
}
- if (free_contents != NULL)
+ if (contents != NULL
+ && elf_section_data (isec)->this_hdr.contents != contents)
{
- if (! link_info->keep_memory)
- free (free_contents);
+ if (!changed && !link_info->keep_memory)
+ free (contents);
else
{
/* Cache the section contents for elf_link_input_bfd. */
elf_section_data (isec)->this_hdr.contents = contents;
}
- free_contents = NULL;
}
- return true;
+ if (elf_section_data (isec)->relocs != internal_relocs)
+ {
+ if (!changed)
+ free (internal_relocs);
+ else
+ elf_section_data (isec)->relocs = internal_relocs;
+ }
-error_return:
- if (rela_comb != NULL)
- free (rela_comb);
- if (free_relocs != NULL)
- free (free_relocs);
- if (free_contents != NULL)
- free (free_contents);
- return false;
+ *again = changed;
+ return TRUE;
+
+ error_return:
+ if (isymbuf != NULL && (unsigned char *) isymbuf != symtab_hdr->contents)
+ free (isymbuf);
+ if (contents != NULL
+ && elf_section_data (isec)->this_hdr.contents != contents)
+ free (contents);
+ if (internal_relocs != NULL
+ && elf_section_data (isec)->relocs != internal_relocs)
+ free (internal_relocs);
+ return FALSE;
}
static reloc_howto_type *
-ppc_elf_reloc_type_lookup (abfd, code)
- bfd *abfd ATTRIBUTE_UNUSED;
- bfd_reloc_code_real_type code;
+ppc_elf_reloc_type_lookup (bfd *abfd ATTRIBUTE_UNUSED,
+ bfd_reloc_code_real_type code)
{
- enum elf_ppc_reloc_type ppc_reloc = R_PPC_NONE;
+ enum elf_ppc_reloc_type r;
+ /* Initialize howto table if not already done. */
if (!ppc_elf_howto_table[R_PPC_ADDR32])
- /* Initialize howto table if needed. */
ppc_elf_howto_init ();
- switch ((int) code)
+ switch (code)
{
default:
- return (reloc_howto_type *) NULL;
-
- case BFD_RELOC_NONE: ppc_reloc = R_PPC_NONE; break;
- case BFD_RELOC_32: ppc_reloc = R_PPC_ADDR32; break;
- case BFD_RELOC_PPC_BA26: ppc_reloc = R_PPC_ADDR24; break;
- case BFD_RELOC_16: ppc_reloc = R_PPC_ADDR16; break;
- case BFD_RELOC_LO16: ppc_reloc = R_PPC_ADDR16_LO; break;
- case BFD_RELOC_HI16: ppc_reloc = R_PPC_ADDR16_HI; break;
- case BFD_RELOC_HI16_S: ppc_reloc = R_PPC_ADDR16_HA; break;
- case BFD_RELOC_PPC_BA16: ppc_reloc = R_PPC_ADDR14; break;
- case BFD_RELOC_PPC_BA16_BRTAKEN: ppc_reloc = R_PPC_ADDR14_BRTAKEN; break;
- case BFD_RELOC_PPC_BA16_BRNTAKEN: ppc_reloc = R_PPC_ADDR14_BRNTAKEN; break;
- case BFD_RELOC_PPC_B26: ppc_reloc = R_PPC_REL24; break;
- case BFD_RELOC_PPC_B16: ppc_reloc = R_PPC_REL14; break;
- case BFD_RELOC_PPC_B16_BRTAKEN: ppc_reloc = R_PPC_REL14_BRTAKEN; break;
- case BFD_RELOC_PPC_B16_BRNTAKEN: ppc_reloc = R_PPC_REL14_BRNTAKEN; break;
- case BFD_RELOC_16_GOTOFF: ppc_reloc = R_PPC_GOT16; break;
- case BFD_RELOC_LO16_GOTOFF: ppc_reloc = R_PPC_GOT16_LO; break;
- case BFD_RELOC_HI16_GOTOFF: ppc_reloc = R_PPC_GOT16_HI; break;
- case BFD_RELOC_HI16_S_GOTOFF: ppc_reloc = R_PPC_GOT16_HA; break;
- case BFD_RELOC_24_PLT_PCREL: ppc_reloc = R_PPC_PLTREL24; break;
- case BFD_RELOC_PPC_COPY: ppc_reloc = R_PPC_COPY; break;
- case BFD_RELOC_PPC_GLOB_DAT: ppc_reloc = R_PPC_GLOB_DAT; break;
- case BFD_RELOC_PPC_LOCAL24PC: ppc_reloc = R_PPC_LOCAL24PC; break;
- case BFD_RELOC_32_PCREL: ppc_reloc = R_PPC_REL32; break;
- case BFD_RELOC_32_PLTOFF: ppc_reloc = R_PPC_PLT32; break;
- case BFD_RELOC_32_PLT_PCREL: ppc_reloc = R_PPC_PLTREL32; break;
- case BFD_RELOC_LO16_PLTOFF: ppc_reloc = R_PPC_PLT16_LO; break;
- case BFD_RELOC_HI16_PLTOFF: ppc_reloc = R_PPC_PLT16_HI; break;
- case BFD_RELOC_HI16_S_PLTOFF: ppc_reloc = R_PPC_PLT16_HA; break;
- case BFD_RELOC_GPREL16: ppc_reloc = R_PPC_SDAREL16; break;
- case BFD_RELOC_16_BASEREL: ppc_reloc = R_PPC_SECTOFF; break;
- case BFD_RELOC_LO16_BASEREL: ppc_reloc = R_PPC_SECTOFF_LO; break;
- case BFD_RELOC_HI16_BASEREL: ppc_reloc = R_PPC_SECTOFF_HI; break;
- case BFD_RELOC_HI16_S_BASEREL: ppc_reloc = R_PPC_SECTOFF_HA; break;
- case BFD_RELOC_CTOR: ppc_reloc = R_PPC_ADDR32; break;
- case BFD_RELOC_PPC_TOC16: ppc_reloc = R_PPC_TOC16; break;
- case BFD_RELOC_PPC_EMB_NADDR32: ppc_reloc = R_PPC_EMB_NADDR32; break;
- case BFD_RELOC_PPC_EMB_NADDR16: ppc_reloc = R_PPC_EMB_NADDR16; break;
- case BFD_RELOC_PPC_EMB_NADDR16_LO: ppc_reloc = R_PPC_EMB_NADDR16_LO; break;
- case BFD_RELOC_PPC_EMB_NADDR16_HI: ppc_reloc = R_PPC_EMB_NADDR16_HI; break;
- case BFD_RELOC_PPC_EMB_NADDR16_HA: ppc_reloc = R_PPC_EMB_NADDR16_HA; break;
- case BFD_RELOC_PPC_EMB_SDAI16: ppc_reloc = R_PPC_EMB_SDAI16; break;
- case BFD_RELOC_PPC_EMB_SDA2I16: ppc_reloc = R_PPC_EMB_SDA2I16; break;
- case BFD_RELOC_PPC_EMB_SDA2REL: ppc_reloc = R_PPC_EMB_SDA2REL; break;
- case BFD_RELOC_PPC_EMB_SDA21: ppc_reloc = R_PPC_EMB_SDA21; break;
- case BFD_RELOC_PPC_EMB_MRKREF: ppc_reloc = R_PPC_EMB_MRKREF; break;
- case BFD_RELOC_PPC_EMB_RELSEC16: ppc_reloc = R_PPC_EMB_RELSEC16; break;
- case BFD_RELOC_PPC_EMB_RELST_LO: ppc_reloc = R_PPC_EMB_RELST_LO; break;
- case BFD_RELOC_PPC_EMB_RELST_HI: ppc_reloc = R_PPC_EMB_RELST_HI; break;
- case BFD_RELOC_PPC_EMB_RELST_HA: ppc_reloc = R_PPC_EMB_RELST_HA; break;
- case BFD_RELOC_PPC_EMB_BIT_FLD: ppc_reloc = R_PPC_EMB_BIT_FLD; break;
- case BFD_RELOC_PPC_EMB_RELSDA: ppc_reloc = R_PPC_EMB_RELSDA; break;
- case BFD_RELOC_VTABLE_INHERIT: ppc_reloc = R_PPC_GNU_VTINHERIT; break;
- case BFD_RELOC_VTABLE_ENTRY: ppc_reloc = R_PPC_GNU_VTENTRY; break;
- }
-
- return ppc_elf_howto_table[(int) ppc_reloc];
+ return NULL;
+
+ case BFD_RELOC_NONE: r = R_PPC_NONE; break;
+ case BFD_RELOC_32: r = R_PPC_ADDR32; break;
+ case BFD_RELOC_PPC_BA26: r = R_PPC_ADDR24; break;
+ case BFD_RELOC_16: r = R_PPC_ADDR16; break;
+ case BFD_RELOC_LO16: r = R_PPC_ADDR16_LO; break;
+ case BFD_RELOC_HI16: r = R_PPC_ADDR16_HI; break;
+ case BFD_RELOC_HI16_S: r = R_PPC_ADDR16_HA; break;
+ case BFD_RELOC_PPC_BA16: r = R_PPC_ADDR14; break;
+ case BFD_RELOC_PPC_BA16_BRTAKEN: r = R_PPC_ADDR14_BRTAKEN; break;
+ case BFD_RELOC_PPC_BA16_BRNTAKEN: r = R_PPC_ADDR14_BRNTAKEN; break;
+ case BFD_RELOC_PPC_B26: r = R_PPC_REL24; break;
+ case BFD_RELOC_PPC_B16: r = R_PPC_REL14; break;
+ case BFD_RELOC_PPC_B16_BRTAKEN: r = R_PPC_REL14_BRTAKEN; break;
+ case BFD_RELOC_PPC_B16_BRNTAKEN: r = R_PPC_REL14_BRNTAKEN; break;
+ case BFD_RELOC_16_GOTOFF: r = R_PPC_GOT16; break;
+ case BFD_RELOC_LO16_GOTOFF: r = R_PPC_GOT16_LO; break;
+ case BFD_RELOC_HI16_GOTOFF: r = R_PPC_GOT16_HI; break;
+ case BFD_RELOC_HI16_S_GOTOFF: r = R_PPC_GOT16_HA; break;
+ case BFD_RELOC_24_PLT_PCREL: r = R_PPC_PLTREL24; break;
+ case BFD_RELOC_PPC_COPY: r = R_PPC_COPY; break;
+ case BFD_RELOC_PPC_GLOB_DAT: r = R_PPC_GLOB_DAT; break;
+ case BFD_RELOC_PPC_LOCAL24PC: r = R_PPC_LOCAL24PC; break;
+ case BFD_RELOC_32_PCREL: r = R_PPC_REL32; break;
+ case BFD_RELOC_32_PLTOFF: r = R_PPC_PLT32; break;
+ case BFD_RELOC_32_PLT_PCREL: r = R_PPC_PLTREL32; break;
+ case BFD_RELOC_LO16_PLTOFF: r = R_PPC_PLT16_LO; break;
+ case BFD_RELOC_HI16_PLTOFF: r = R_PPC_PLT16_HI; break;
+ case BFD_RELOC_HI16_S_PLTOFF: r = R_PPC_PLT16_HA; break;
+ case BFD_RELOC_GPREL16: r = R_PPC_SDAREL16; break;
+ case BFD_RELOC_16_BASEREL: r = R_PPC_SECTOFF; break;
+ case BFD_RELOC_LO16_BASEREL: r = R_PPC_SECTOFF_LO; break;
+ case BFD_RELOC_HI16_BASEREL: r = R_PPC_SECTOFF_HI; break;
+ case BFD_RELOC_HI16_S_BASEREL: r = R_PPC_SECTOFF_HA; break;
+ case BFD_RELOC_CTOR: r = R_PPC_ADDR32; break;
+ case BFD_RELOC_PPC_TOC16: r = R_PPC_TOC16; break;
+ case BFD_RELOC_PPC_TLS: r = R_PPC_TLS; break;
+ case BFD_RELOC_PPC_DTPMOD: r = R_PPC_DTPMOD32; break;
+ case BFD_RELOC_PPC_TPREL16: r = R_PPC_TPREL16; break;
+ case BFD_RELOC_PPC_TPREL16_LO: r = R_PPC_TPREL16_LO; break;
+ case BFD_RELOC_PPC_TPREL16_HI: r = R_PPC_TPREL16_HI; break;
+ case BFD_RELOC_PPC_TPREL16_HA: r = R_PPC_TPREL16_HA; break;
+ case BFD_RELOC_PPC_TPREL: r = R_PPC_TPREL32; break;
+ case BFD_RELOC_PPC_DTPREL16: r = R_PPC_DTPREL16; break;
+ case BFD_RELOC_PPC_DTPREL16_LO: r = R_PPC_DTPREL16_LO; break;
+ case BFD_RELOC_PPC_DTPREL16_HI: r = R_PPC_DTPREL16_HI; break;
+ case BFD_RELOC_PPC_DTPREL16_HA: r = R_PPC_DTPREL16_HA; break;
+ case BFD_RELOC_PPC_DTPREL: r = R_PPC_DTPREL32; break;
+ case BFD_RELOC_PPC_GOT_TLSGD16: r = R_PPC_GOT_TLSGD16; break;
+ case BFD_RELOC_PPC_GOT_TLSGD16_LO: r = R_PPC_GOT_TLSGD16_LO; break;
+ case BFD_RELOC_PPC_GOT_TLSGD16_HI: r = R_PPC_GOT_TLSGD16_HI; break;
+ case BFD_RELOC_PPC_GOT_TLSGD16_HA: r = R_PPC_GOT_TLSGD16_HA; break;
+ case BFD_RELOC_PPC_GOT_TLSLD16: r = R_PPC_GOT_TLSLD16; break;
+ case BFD_RELOC_PPC_GOT_TLSLD16_LO: r = R_PPC_GOT_TLSLD16_LO; break;
+ case BFD_RELOC_PPC_GOT_TLSLD16_HI: r = R_PPC_GOT_TLSLD16_HI; break;
+ case BFD_RELOC_PPC_GOT_TLSLD16_HA: r = R_PPC_GOT_TLSLD16_HA; break;
+ case BFD_RELOC_PPC_GOT_TPREL16: r = R_PPC_GOT_TPREL16; break;
+ case BFD_RELOC_PPC_GOT_TPREL16_LO: r = R_PPC_GOT_TPREL16_LO; break;
+ case BFD_RELOC_PPC_GOT_TPREL16_HI: r = R_PPC_GOT_TPREL16_HI; break;
+ case BFD_RELOC_PPC_GOT_TPREL16_HA: r = R_PPC_GOT_TPREL16_HA; break;
+ case BFD_RELOC_PPC_GOT_DTPREL16: r = R_PPC_GOT_DTPREL16; break;
+ case BFD_RELOC_PPC_GOT_DTPREL16_LO: r = R_PPC_GOT_DTPREL16_LO; break;
+ case BFD_RELOC_PPC_GOT_DTPREL16_HI: r = R_PPC_GOT_DTPREL16_HI; break;
+ case BFD_RELOC_PPC_GOT_DTPREL16_HA: r = R_PPC_GOT_DTPREL16_HA; break;
+ case BFD_RELOC_PPC_EMB_NADDR32: r = R_PPC_EMB_NADDR32; break;
+ case BFD_RELOC_PPC_EMB_NADDR16: r = R_PPC_EMB_NADDR16; break;
+ case BFD_RELOC_PPC_EMB_NADDR16_LO: r = R_PPC_EMB_NADDR16_LO; break;
+ case BFD_RELOC_PPC_EMB_NADDR16_HI: r = R_PPC_EMB_NADDR16_HI; break;
+ case BFD_RELOC_PPC_EMB_NADDR16_HA: r = R_PPC_EMB_NADDR16_HA; break;
+ case BFD_RELOC_PPC_EMB_SDAI16: r = R_PPC_EMB_SDAI16; break;
+ case BFD_RELOC_PPC_EMB_SDA2I16: r = R_PPC_EMB_SDA2I16; break;
+ case BFD_RELOC_PPC_EMB_SDA2REL: r = R_PPC_EMB_SDA2REL; break;
+ case BFD_RELOC_PPC_EMB_SDA21: r = R_PPC_EMB_SDA21; break;
+ case BFD_RELOC_PPC_EMB_MRKREF: r = R_PPC_EMB_MRKREF; break;
+ case BFD_RELOC_PPC_EMB_RELSEC16: r = R_PPC_EMB_RELSEC16; break;
+ case BFD_RELOC_PPC_EMB_RELST_LO: r = R_PPC_EMB_RELST_LO; break;
+ case BFD_RELOC_PPC_EMB_RELST_HI: r = R_PPC_EMB_RELST_HI; break;
+ case BFD_RELOC_PPC_EMB_RELST_HA: r = R_PPC_EMB_RELST_HA; break;
+ case BFD_RELOC_PPC_EMB_BIT_FLD: r = R_PPC_EMB_BIT_FLD; break;
+ case BFD_RELOC_PPC_EMB_RELSDA: r = R_PPC_EMB_RELSDA; break;
+ case BFD_RELOC_VTABLE_INHERIT: r = R_PPC_GNU_VTINHERIT; break;
+ case BFD_RELOC_VTABLE_ENTRY: r = R_PPC_GNU_VTENTRY; break;
+ }
+
+ return ppc_elf_howto_table[r];
};
/* Set the howto pointer for a PowerPC ELF reloc. */
static void
-ppc_elf_info_to_howto (abfd, cache_ptr, dst)
- bfd *abfd ATTRIBUTE_UNUSED;
- arelent *cache_ptr;
- Elf32_Internal_Rela *dst;
+ppc_elf_info_to_howto (bfd *abfd ATTRIBUTE_UNUSED,
+ arelent *cache_ptr,
+ Elf_Internal_Rela *dst)
{
+ /* Initialize howto table if not already done. */
if (!ppc_elf_howto_table[R_PPC_ADDR32])
- /* Initialize howto table if needed. */
ppc_elf_howto_init ();
BFD_ASSERT (ELF32_R_TYPE (dst->r_info) < (unsigned int) R_PPC_max);
@@ -1346,15 +2119,13 @@ ppc_elf_info_to_howto (abfd, cache_ptr, dst)
/* Handle the R_PPC_ADDR16_HA reloc. */
static bfd_reloc_status_type
-ppc_elf_addr16_ha_reloc (abfd, reloc_entry, symbol, data, input_section,
- output_bfd, error_message)
- bfd *abfd ATTRIBUTE_UNUSED;
- arelent *reloc_entry;
- asymbol *symbol;
- PTR data ATTRIBUTE_UNUSED;
- asection *input_section;
- bfd *output_bfd;
- char **error_message ATTRIBUTE_UNUSED;
+ppc_elf_addr16_ha_reloc (bfd *abfd ATTRIBUTE_UNUSED,
+ arelent *reloc_entry,
+ asymbol *symbol,
+ void *data ATTRIBUTE_UNUSED,
+ asection *input_section,
+ bfd *output_bfd,
+ char **error_message ATTRIBUTE_UNUSED)
{
bfd_vma relocation;
@@ -1381,12 +2152,37 @@ ppc_elf_addr16_ha_reloc (abfd, reloc_entry, symbol, data, input_section,
return bfd_reloc_continue;
}
+static bfd_reloc_status_type
+ppc_elf_unhandled_reloc (bfd *abfd,
+ arelent *reloc_entry,
+ asymbol *symbol,
+ void *data,
+ asection *input_section,
+ bfd *output_bfd,
+ char **error_message)
+{
+ /* If this is a relocatable link (output_bfd test tells us), just
+ call the generic function. Any adjustment will be done at final
+ link time. */
+ if (output_bfd != NULL)
+ return bfd_elf_generic_reloc (abfd, reloc_entry, symbol, data,
+ input_section, output_bfd, error_message);
+
+ if (error_message != NULL)
+ {
+ static char buf[60];
+ sprintf (buf, _("generic linker can't handle %s"),
+ reloc_entry->howto->name);
+ *error_message = buf;
+ }
+ return bfd_reloc_dangerous;
+}
+
/* Fix bad default arch selected for a 32 bit input bfd when the
default is 64 bit. */
-static boolean
-ppc_elf_object_p (abfd)
- bfd *abfd;
+static bfd_boolean
+ppc_elf_object_p (bfd *abfd)
{
if (abfd->arch_info->the_default && abfd->arch_info->bits_per_word == 64)
{
@@ -1399,73 +2195,75 @@ ppc_elf_object_p (abfd)
BFD_ASSERT (abfd->arch_info->bits_per_word == 32);
}
}
- return true;
+ return TRUE;
}
/* Function to set whether a module needs the -mrelocatable bit set. */
-static boolean
-ppc_elf_set_private_flags (abfd, flags)
- bfd *abfd;
- flagword flags;
+static bfd_boolean
+ppc_elf_set_private_flags (bfd *abfd, flagword flags)
{
BFD_ASSERT (!elf_flags_init (abfd)
|| elf_elfheader (abfd)->e_flags == flags);
elf_elfheader (abfd)->e_flags = flags;
- elf_flags_init (abfd) = true;
- return true;
+ elf_flags_init (abfd) = TRUE;
+ return TRUE;
}
/* Merge backend specific data from an object file to the output
- object file when linking */
-static boolean
-ppc_elf_merge_private_bfd_data (ibfd, obfd)
- bfd *ibfd;
- bfd *obfd;
+ object file when linking. */
+
+static bfd_boolean
+ppc_elf_merge_private_bfd_data (bfd *ibfd, bfd *obfd)
{
flagword old_flags;
flagword new_flags;
- boolean error;
+ bfd_boolean error;
- /* Check if we have the same endianess */
+ /* Check if we have the same endianess. */
if (! _bfd_generic_verify_endian_match (ibfd, obfd))
- return false;
+ return FALSE;
if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour
|| bfd_get_flavour (obfd) != bfd_target_elf_flavour)
- return true;
+ return TRUE;
new_flags = elf_elfheader (ibfd)->e_flags;
old_flags = elf_elfheader (obfd)->e_flags;
- if (!elf_flags_init (obfd)) /* First call, no flags set */
+ if (!elf_flags_init (obfd))
{
- elf_flags_init (obfd) = true;
+ /* First call, no flags set. */
+ elf_flags_init (obfd) = TRUE;
elf_elfheader (obfd)->e_flags = new_flags;
}
- else if (new_flags == old_flags) /* Compatible flags are ok */
+ /* Compatible flags are ok. */
+ else if (new_flags == old_flags)
;
- else /* Incompatible flags */
+ /* Incompatible flags. */
+ else
{
- /* Warn about -mrelocatable mismatch. Allow -mrelocatable-lib to be linked
- with either. */
- error = false;
+ /* Warn about -mrelocatable mismatch. Allow -mrelocatable-lib
+ to be linked with either. */
+ error = FALSE;
if ((new_flags & EF_PPC_RELOCATABLE) != 0
&& (old_flags & (EF_PPC_RELOCATABLE | EF_PPC_RELOCATABLE_LIB)) == 0)
{
- error = true;
+ error = TRUE;
(*_bfd_error_handler)
- (_("%s: compiled with -mrelocatable and linked with modules compiled normally"),
+ (_("%s: compiled with -mrelocatable and linked with "
+ "modules compiled normally"),
bfd_archive_filename (ibfd));
}
else if ((new_flags & (EF_PPC_RELOCATABLE | EF_PPC_RELOCATABLE_LIB)) == 0
&& (old_flags & EF_PPC_RELOCATABLE) != 0)
{
- error = true;
+ error = TRUE;
(*_bfd_error_handler)
- (_("%s: compiled normally and linked with modules compiled with -mrelocatable"),
+ (_("%s: compiled normally and linked with "
+ "modules compiled with -mrelocatable"),
bfd_archive_filename (ibfd));
}
@@ -1474,51 +2272,50 @@ ppc_elf_merge_private_bfd_data (ibfd, obfd)
elf_elfheader (obfd)->e_flags &= ~EF_PPC_RELOCATABLE_LIB;
/* The output is -mrelocatable iff it can't be -mrelocatable-lib,
- but each input file is either -mrelocatable or -mrelocatable-lib. */
+ but each input file is either -mrelocatable or -mrelocatable-lib. */
if (! (elf_elfheader (obfd)->e_flags & EF_PPC_RELOCATABLE_LIB)
&& (new_flags & (EF_PPC_RELOCATABLE_LIB | EF_PPC_RELOCATABLE))
&& (old_flags & (EF_PPC_RELOCATABLE_LIB | EF_PPC_RELOCATABLE)))
elf_elfheader (obfd)->e_flags |= EF_PPC_RELOCATABLE;
- /* Do not warn about eabi vs. V.4 mismatch, just or in the bit if any module uses it */
+ /* Do not warn about eabi vs. V.4 mismatch, just or in the bit if
+ any module uses it. */
elf_elfheader (obfd)->e_flags |= (new_flags & EF_PPC_EMB);
- new_flags &= ~ (EF_PPC_RELOCATABLE | EF_PPC_RELOCATABLE_LIB | EF_PPC_EMB);
- old_flags &= ~ (EF_PPC_RELOCATABLE | EF_PPC_RELOCATABLE_LIB | EF_PPC_EMB);
+ new_flags &= ~(EF_PPC_RELOCATABLE | EF_PPC_RELOCATABLE_LIB | EF_PPC_EMB);
+ old_flags &= ~(EF_PPC_RELOCATABLE | EF_PPC_RELOCATABLE_LIB | EF_PPC_EMB);
- /* Warn about any other mismatches */
+ /* Warn about any other mismatches. */
if (new_flags != old_flags)
{
- error = true;
+ error = TRUE;
(*_bfd_error_handler)
- (_("%s: uses different e_flags (0x%lx) fields than previous modules (0x%lx)"),
+ (_("%s: uses different e_flags (0x%lx) fields "
+ "than previous modules (0x%lx)"),
bfd_archive_filename (ibfd), (long) new_flags, (long) old_flags);
}
if (error)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
/* Handle a PowerPC specific section when reading an object file. This
is called when elfcode.h finds a section with an unknown type. */
-static boolean
-ppc_elf_section_from_shdr (abfd, hdr, name)
- bfd *abfd;
- Elf32_Internal_Shdr *hdr;
- const char *name;
+static bfd_boolean
+ppc_elf_section_from_shdr (bfd *abfd, Elf_Internal_Shdr *hdr, const char *name)
{
asection *newsect;
flagword flags;
if (! _bfd_elf_make_section_from_shdr (abfd, hdr, name))
- return false;
+ return FALSE;
newsect = hdr->bfd_section;
flags = bfd_get_section_flags (abfd, newsect);
@@ -1529,16 +2326,15 @@ ppc_elf_section_from_shdr (abfd, hdr, name)
flags |= SEC_SORT_ENTRIES;
bfd_set_section_flags (abfd, newsect, flags);
- return true;
+ return TRUE;
}
/* Set up any other section flags and such that may be necessary. */
-static boolean
-ppc_elf_fake_sections (abfd, shdr, asect)
- bfd *abfd ATTRIBUTE_UNUSED;
- Elf32_Internal_Shdr *shdr;
- asection *asect;
+static bfd_boolean
+ppc_elf_fake_sections (bfd *abfd ATTRIBUTE_UNUSED,
+ Elf_Internal_Shdr *shdr,
+ asection *asect)
{
if ((asect->flags & SEC_EXCLUDE) != 0)
shdr->sh_flags |= SHF_EXCLUDE;
@@ -1546,75 +2342,363 @@ ppc_elf_fake_sections (abfd, shdr, asect)
if ((asect->flags & SEC_SORT_ENTRIES) != 0)
shdr->sh_type = SHT_ORDERED;
- return true;
+ return TRUE;
+}
+
+/* Find a linker generated pointer with a given addend and type. */
+
+static elf_linker_section_pointers_t *
+elf_find_pointer_linker_section
+ (elf_linker_section_pointers_t *linker_pointers,
+ bfd_vma addend,
+ elf_linker_section_t *lsect)
+{
+ for ( ; linker_pointers != NULL; linker_pointers = linker_pointers->next)
+ if (lsect == linker_pointers->lsect && addend == linker_pointers->addend)
+ return linker_pointers;
+
+ return NULL;
+}
+
+/* Allocate a pointer to live in a linker created section. */
+
+static bfd_boolean
+elf_create_pointer_linker_section (bfd *abfd,
+ struct bfd_link_info *info,
+ elf_linker_section_t *lsect,
+ struct elf_link_hash_entry *h,
+ const Elf_Internal_Rela *rel)
+{
+ elf_linker_section_pointers_t **ptr_linker_section_ptr = NULL;
+ elf_linker_section_pointers_t *linker_section_ptr;
+ unsigned long r_symndx = ELF32_R_SYM (rel->r_info);
+ bfd_size_type amt;
+
+ BFD_ASSERT (lsect != NULL);
+
+ /* Is this a global symbol? */
+ if (h != NULL)
+ {
+ struct ppc_elf_link_hash_entry *eh;
+
+ /* Has this symbol already been allocated? If so, our work is done. */
+ eh = (struct ppc_elf_link_hash_entry *) h;
+ if (elf_find_pointer_linker_section (eh->linker_section_pointer,
+ rel->r_addend,
+ lsect))
+ return TRUE;
+
+ ptr_linker_section_ptr = &eh->linker_section_pointer;
+ /* Make sure this symbol is output as a dynamic symbol. */
+ if (h->dynindx == -1)
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
+ }
+
+ if (lsect->rel_section)
+ lsect->rel_section->_raw_size += sizeof (Elf32_External_Rela);
+ }
+ else
+ {
+ /* Allocation of a pointer to a local symbol. */
+ elf_linker_section_pointers_t **ptr = elf_local_ptr_offsets (abfd);
+
+ /* Allocate a table to hold the local symbols if first time. */
+ if (!ptr)
+ {
+ unsigned int num_symbols = elf_tdata (abfd)->symtab_hdr.sh_info;
+
+ amt = num_symbols;
+ amt *= sizeof (elf_linker_section_pointers_t *);
+ ptr = bfd_zalloc (abfd, amt);
+
+ if (!ptr)
+ return FALSE;
+
+ elf_local_ptr_offsets (abfd) = ptr;
+ }
+
+ /* Has this symbol already been allocated? If so, our work is done. */
+ if (elf_find_pointer_linker_section (ptr[r_symndx],
+ rel->r_addend,
+ lsect))
+ return TRUE;
+
+ ptr_linker_section_ptr = &ptr[r_symndx];
+
+ if (info->shared)
+ {
+ /* If we are generating a shared object, we need to
+ output a R_<xxx>_RELATIVE reloc so that the
+ dynamic linker can adjust this GOT entry. */
+ BFD_ASSERT (lsect->rel_section != NULL);
+ lsect->rel_section->_raw_size += sizeof (Elf32_External_Rela);
+ }
+ }
+
+ /* Allocate space for a pointer in the linker section, and allocate
+ a new pointer record from internal memory. */
+ BFD_ASSERT (ptr_linker_section_ptr != NULL);
+ amt = sizeof (elf_linker_section_pointers_t);
+ linker_section_ptr = bfd_alloc (abfd, amt);
+
+ if (!linker_section_ptr)
+ return FALSE;
+
+ linker_section_ptr->next = *ptr_linker_section_ptr;
+ linker_section_ptr->addend = rel->r_addend;
+ linker_section_ptr->lsect = lsect;
+ linker_section_ptr->written_address_p = FALSE;
+ *ptr_linker_section_ptr = linker_section_ptr;
+
+ linker_section_ptr->offset = lsect->section->_raw_size;
+ lsect->section->_raw_size += 4;
+
+#ifdef DEBUG
+ fprintf (stderr,
+ "Create pointer in linker section %s, offset = %ld, section size = %ld\n",
+ lsect->name, (long) linker_section_ptr->offset,
+ (long) lsect->section->_raw_size);
+#endif
+
+ return TRUE;
+}
+
+#define bfd_put_ptr(BFD, VAL, ADDR) bfd_put_32 (BFD, VAL, ADDR)
+
+/* Fill in the address for a pointer generated in a linker section. */
+
+static bfd_vma
+elf_finish_pointer_linker_section (bfd *output_bfd,
+ bfd *input_bfd,
+ struct bfd_link_info *info,
+ elf_linker_section_t *lsect,
+ struct elf_link_hash_entry *h,
+ bfd_vma relocation,
+ const Elf_Internal_Rela *rel,
+ int relative_reloc)
+{
+ elf_linker_section_pointers_t *linker_section_ptr;
+
+ BFD_ASSERT (lsect != NULL);
+
+ if (h != NULL)
+ {
+ /* Handle global symbol. */
+ struct ppc_elf_link_hash_entry *eh;
+
+ eh = (struct ppc_elf_link_hash_entry *) h;
+ linker_section_ptr
+ = elf_find_pointer_linker_section (eh->linker_section_pointer,
+ rel->r_addend,
+ lsect);
+
+ BFD_ASSERT (linker_section_ptr != NULL);
+
+ if (! elf_hash_table (info)->dynamic_sections_created
+ || (info->shared
+ && info->symbolic
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR)))
+ {
+ /* This is actually a static link, or it is a
+ -Bsymbolic link and the symbol is defined
+ locally. We must initialize this entry in the
+ global section.
+
+ When doing a dynamic link, we create a .rela.<xxx>
+ relocation entry to initialize the value. This
+ is done in the finish_dynamic_symbol routine. */
+ if (!linker_section_ptr->written_address_p)
+ {
+ linker_section_ptr->written_address_p = TRUE;
+ bfd_put_ptr (output_bfd,
+ relocation + linker_section_ptr->addend,
+ (lsect->section->contents
+ + linker_section_ptr->offset));
+ }
+ }
+ }
+ else
+ {
+ /* Handle local symbol. */
+ unsigned long r_symndx = ELF32_R_SYM (rel->r_info);
+ BFD_ASSERT (elf_local_ptr_offsets (input_bfd) != NULL);
+ BFD_ASSERT (elf_local_ptr_offsets (input_bfd)[r_symndx] != NULL);
+ linker_section_ptr = (elf_find_pointer_linker_section
+ (elf_local_ptr_offsets (input_bfd)[r_symndx],
+ rel->r_addend,
+ lsect));
+
+ BFD_ASSERT (linker_section_ptr != NULL);
+
+ /* Write out pointer if it hasn't been rewritten out before. */
+ if (!linker_section_ptr->written_address_p)
+ {
+ linker_section_ptr->written_address_p = TRUE;
+ bfd_put_ptr (output_bfd, relocation + linker_section_ptr->addend,
+ lsect->section->contents + linker_section_ptr->offset);
+
+ if (info->shared)
+ {
+ /* We need to generate a relative reloc for the dynamic
+ linker. */
+
+ asection *srel = lsect->rel_section;
+ Elf_Internal_Rela outrel[MAX_INT_RELS_PER_EXT_REL];
+ bfd_byte *erel;
+ const struct elf_backend_data *bed;
+ unsigned int i;
+
+ BFD_ASSERT (srel != NULL);
+
+ bed = get_elf_backend_data (output_bfd);
+ for (i = 0; i < bed->s->int_rels_per_ext_rel; i++)
+ {
+ outrel[i].r_offset = (lsect->section->output_section->vma
+ + lsect->section->output_offset
+ + linker_section_ptr->offset);
+ outrel[i].r_info = 0;
+ outrel[i].r_addend = 0;
+ }
+ outrel[0].r_info = ELF32_R_INFO (0, relative_reloc);
+ erel = lsect->section->contents;
+ erel += (elf_section_data (lsect->section)->rel_count++
+ * sizeof (Elf32_External_Rela));
+ bfd_elf32_swap_reloca_out (output_bfd, outrel, erel);
+ }
+ }
+ }
+
+ relocation = (lsect->section->output_offset
+ + linker_section_ptr->offset
+ - lsect->sym_offset);
+
+#ifdef DEBUG
+ fprintf (stderr,
+ "Finish pointer in linker section %s, offset = %ld (0x%lx)\n",
+ lsect->name, (long) relocation, (long) relocation);
+#endif
+
+ /* Subtract out the addend, because it will get added back in by the normal
+ processing. */
+ return relocation - linker_section_ptr->addend;
}
/* Create a special linker section */
static elf_linker_section_t *
-ppc_elf_create_linker_section (abfd, info, which)
- bfd *abfd;
- struct bfd_link_info *info;
- enum elf_linker_section_enum which;
+ppc_elf_create_linker_section (bfd *abfd,
+ struct bfd_link_info *info,
+ enum elf_linker_section_enum which)
{
- bfd *dynobj = elf_hash_table (info)->dynobj;
elf_linker_section_t *lsect;
+ struct ppc_elf_link_hash_table *htab = ppc_elf_hash_table (info);
+ asection *s;
+ bfd_size_type amt;
+ flagword flags;
+ const char *name;
+ const char *rel_name;
+ const char *sym_name;
+ bfd_vma sym_offset;
+
+ /* Both of these sections are (technically) created by the user
+ putting data in them, so they shouldn't be marked
+ SEC_LINKER_CREATED.
+
+ The linker creates them so it has somewhere to attach their
+ respective symbols. In fact, if they were empty it would
+ be OK to leave the symbol set to 0 (or any random number), because
+ the appropriate register should never be used. */
+ flags = SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS | SEC_IN_MEMORY;
+ sym_offset = 32768;
+
+ switch (which)
+ {
+ default:
+ abort ();
+ return NULL;
+
+ case LINKER_SECTION_SDATA: /* .sdata/.sbss section */
+ name = ".sdata";
+ rel_name = ".rela.sdata";
+ sym_name = "_SDA_BASE_";
+ break;
+
+ case LINKER_SECTION_SDATA2: /* .sdata2/.sbss2 section */
+ name = ".sdata2";
+ rel_name = ".rela.sdata2";
+ sym_name = "_SDA2_BASE_";
+ flags |= SEC_READONLY;
+ break;
+ }
- /* Record the first bfd section that needs the special section */
- if (!dynobj)
- dynobj = elf_hash_table (info)->dynobj = abfd;
+ /* Record the first bfd that needs the special sections. */
+ if (!htab->elf.dynobj)
+ htab->elf.dynobj = abfd;
- /* If this is the first time, create the section */
- lsect = elf_linker_section (dynobj, which);
- if (!lsect)
+ amt = sizeof (elf_linker_section_t);
+ lsect = bfd_zalloc (htab->elf.dynobj, amt);
+
+ lsect->sym_offset = sym_offset;
+
+ /* See if the sections already exist. */
+ s = bfd_get_section_by_name (htab->elf.dynobj, name);
+ if (s == NULL || (s->flags & flags) != flags)
{
- elf_linker_section_t defaults;
- static elf_linker_section_t zero_section;
+ s = bfd_make_section_anyway (htab->elf.dynobj, name);
+ if (s == NULL
+ || !bfd_set_section_flags (htab->elf.dynobj, s, flags))
+ return NULL;
+ }
+ lsect->section = s;
- defaults = zero_section;
- defaults.which = which;
- defaults.hole_written_p = false;
- defaults.alignment = 2;
+ if (bfd_get_section_alignment (htab->elf.dynobj, s) < 2
+ && !bfd_set_section_alignment (htab->elf.dynobj, s, 2))
+ return NULL;
- /* Both of these sections are (technically) created by the user
- putting data in them, so they shouldn't be marked
- SEC_LINKER_CREATED.
+ s->_raw_size = align_power (s->_raw_size, 2);
- The linker creates them so it has somewhere to attach their
- respective symbols. In fact, if they were empty it would
- be OK to leave the symbol set to 0 (or any random number), because
- the appropriate register should never be used. */
- defaults.flags = (SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS
- | SEC_IN_MEMORY);
+#ifdef DEBUG
+ fprintf (stderr, "Creating section %s, current size = %ld\n",
+ name, (long) s->_raw_size);
+#endif
- switch (which)
- {
- default:
- (*_bfd_error_handler) (_("%s: Unknown special linker type %d"),
- bfd_get_filename (abfd),
- (int) which);
+ if (sym_name)
+ {
+ struct elf_link_hash_entry *h;
+ struct bfd_link_hash_entry *bh;
- bfd_set_error (bfd_error_bad_value);
- return (elf_linker_section_t *) 0;
-
- case LINKER_SECTION_SDATA: /* .sdata/.sbss section */
- defaults.name = ".sdata";
- defaults.rel_name = ".rela.sdata";
- defaults.bss_name = ".sbss";
- defaults.sym_name = "_SDA_BASE_";
- defaults.sym_offset = 32768;
- break;
+#ifdef DEBUG
+ fprintf (stderr, "Adding %s to section %s\n", sym_name, name);
+#endif
+ bh = bfd_link_hash_lookup (info->hash, sym_name,
+ FALSE, FALSE, FALSE);
- case LINKER_SECTION_SDATA2: /* .sdata2/.sbss2 section */
- defaults.name = ".sdata2";
- defaults.rel_name = ".rela.sdata2";
- defaults.bss_name = ".sbss2";
- defaults.sym_name = "_SDA2_BASE_";
- defaults.sym_offset = 32768;
- defaults.flags |= SEC_READONLY;
- break;
- }
+ if ((bh == NULL || bh->type == bfd_link_hash_undefined)
+ && !(_bfd_generic_link_add_one_symbol
+ (info, abfd, sym_name, BSF_GLOBAL, s, sym_offset, NULL,
+ FALSE, get_elf_backend_data (abfd)->collect, &bh)))
+ return NULL;
+ h = (struct elf_link_hash_entry *) bh;
- lsect = _bfd_elf_create_linker_section (abfd, info, which, &defaults);
+ h->type = STT_OBJECT;
+ lsect->sym_hash = h;
+
+ if (info->shared
+ && ! bfd_elf_link_record_dynamic_symbol (info, h))
+ return NULL;
+ }
+
+ if (info->shared)
+ {
+ s = bfd_make_section_anyway (htab->elf.dynobj, rel_name);
+ lsect->rel_section = s;
+ flags = (SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS | SEC_IN_MEMORY
+ | SEC_LINKER_CREATED | SEC_READONLY);
+ if (s == NULL
+ || ! bfd_set_section_flags (htab->elf.dynobj, s, flags)
+ || ! bfd_set_section_alignment (htab->elf.dynobj, s, 2))
+ return NULL;
}
return lsect;
@@ -1624,8 +2708,7 @@ ppc_elf_create_linker_section (abfd, info, which)
need to bump up the number of section headers. */
static int
-ppc_elf_additional_program_headers (abfd)
- bfd *abfd;
+ppc_elf_additional_program_headers (bfd *abfd)
{
asection *s;
int ret;
@@ -1649,73 +2732,88 @@ ppc_elf_additional_program_headers (abfd)
/* Modify the segment map if needed. */
-static boolean
-ppc_elf_modify_segment_map (abfd)
- bfd *abfd ATTRIBUTE_UNUSED;
+static bfd_boolean
+ppc_elf_modify_segment_map (bfd *abfd ATTRIBUTE_UNUSED,
+ struct bfd_link_info *info ATTRIBUTE_UNUSED)
{
- return true;
+ return TRUE;
}
/* The powerpc .got has a blrl instruction in it. Mark it executable. */
-static asection *
-ppc_elf_create_got (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info;
+static bfd_boolean
+ppc_elf_create_got (bfd *abfd, struct bfd_link_info *info)
{
- register asection *s;
+ struct ppc_elf_link_hash_table *htab;
+ asection *s;
flagword flags;
if (!_bfd_elf_create_got_section (abfd, info))
- return NULL;
+ return FALSE;
- s = bfd_get_section_by_name (abfd, ".got");
+ htab = ppc_elf_hash_table (info);
+ htab->got = s = bfd_get_section_by_name (abfd, ".got");
if (s == NULL)
abort ();
flags = (SEC_ALLOC | SEC_LOAD | SEC_CODE | SEC_HAS_CONTENTS | SEC_IN_MEMORY
| SEC_LINKER_CREATED);
if (!bfd_set_section_flags (abfd, s, flags))
- return NULL;
- return s;
+ return FALSE;
+
+ htab->relgot = bfd_make_section (abfd, ".rela.got");
+ if (!htab->relgot
+ || ! bfd_set_section_flags (abfd, htab->relgot,
+ (SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS
+ | SEC_IN_MEMORY | SEC_LINKER_CREATED
+ | SEC_READONLY))
+ || ! bfd_set_section_alignment (abfd, htab->relgot, 2))
+ return FALSE;
+
+ return TRUE;
}
/* We have to create .dynsbss and .rela.sbss here so that they get mapped
to output sections (just like _bfd_elf_create_dynamic_sections has
to create .dynbss and .rela.bss). */
-static boolean
-ppc_elf_create_dynamic_sections (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info;
+static bfd_boolean
+ppc_elf_create_dynamic_sections (bfd *abfd, struct bfd_link_info *info)
{
- register asection *s;
+ struct ppc_elf_link_hash_table *htab;
+ asection *s;
flagword flags;
- if (!ppc_elf_create_got (abfd, info))
- return false;
+ htab = ppc_elf_hash_table (info);
+
+ if (htab->got == NULL
+ && !ppc_elf_create_got (abfd, info))
+ return FALSE;
if (!_bfd_elf_create_dynamic_sections (abfd, info))
- return false;
+ return FALSE;
flags = (SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS | SEC_IN_MEMORY
| SEC_LINKER_CREATED);
- s = bfd_make_section (abfd, ".dynsbss");
+ htab->dynbss = bfd_get_section_by_name (abfd, ".dynbss");
+ htab->dynsbss = s = bfd_make_section (abfd, ".dynsbss");
if (s == NULL
|| ! bfd_set_section_flags (abfd, s, SEC_ALLOC))
- return false;
+ return FALSE;
if (! info->shared)
{
- s = bfd_make_section (abfd, ".rela.sbss");
+ htab->relbss = bfd_get_section_by_name (abfd, ".rela.bss");
+ htab->relsbss = s = bfd_make_section (abfd, ".rela.sbss");
if (s == NULL
|| ! bfd_set_section_flags (abfd, s, flags | SEC_READONLY)
|| ! bfd_set_section_alignment (abfd, s, 2))
- return false;
+ return FALSE;
}
- s = bfd_get_section_by_name (abfd, ".plt");
+ htab->relplt = bfd_get_section_by_name (abfd, ".rela.plt");
+ htab->plt = s = bfd_get_section_by_name (abfd, ".plt");
if (s == NULL)
abort ();
@@ -1729,22 +2827,22 @@ ppc_elf_create_dynamic_sections (abfd, info)
change the definition to something the rest of the link can
understand. */
-static boolean
-ppc_elf_adjust_dynamic_symbol (info, h)
- struct bfd_link_info *info;
- struct elf_link_hash_entry *h;
+static bfd_boolean
+ppc_elf_adjust_dynamic_symbol (struct bfd_link_info *info,
+ struct elf_link_hash_entry *h)
{
- bfd *dynobj = elf_hash_table (info)->dynobj;
+ struct ppc_elf_link_hash_table *htab;
asection *s;
unsigned int power_of_two;
- bfd_vma plt_offset;
#ifdef DEBUG
- fprintf (stderr, "ppc_elf_adjust_dynamic_symbol called for %s\n", h->root.root.string);
+ fprintf (stderr, "ppc_elf_adjust_dynamic_symbol called for %s\n",
+ h->root.root.string);
#endif
/* Make sure we know what is going on here. */
- BFD_ASSERT (dynobj != NULL
+ htab = ppc_elf_hash_table (info);
+ BFD_ASSERT (htab->elf.dynobj != NULL
&& ((h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_PLT)
|| h->weakdef != NULL
|| ((h->elf_link_hash_flags
@@ -1754,86 +2852,31 @@ ppc_elf_adjust_dynamic_symbol (info, h)
&& (h->elf_link_hash_flags
& ELF_LINK_HASH_DEF_REGULAR) == 0)));
- /* If this is a function, put it in the procedure linkage table. We
- will fill in the contents of the procedure linkage table later,
- when we know the address of the .got section. */
+ /* Deal with function syms. */
if (h->type == STT_FUNC
|| (h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_PLT) != 0)
{
- if (! elf_hash_table (info)->dynamic_sections_created
- || SYMBOL_CALLS_LOCAL (info, h)
- || (info->shared && h->plt.refcount <= 0))
+ /* Clear procedure linkage table information for any symbol that
+ won't need a .plt entry. */
+ if (h->plt.refcount <= 0
+ || SYMBOL_CALLS_LOCAL (info, h)
+ || (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+ && h->root.type == bfd_link_hash_undefweak))
{
/* A PLT entry is not required/allowed when:
1. We are not using ld.so; because then the PLT entry
- can't be set up, so we can't use one.
+ can't be set up, so we can't use one. In this case,
+ ppc_elf_adjust_dynamic_symbol won't even be called.
- 2. We know for certain that a call to this symbol
- will go to this object.
+ 2. GC has rendered the entry unused.
- 3. GC has rendered the entry unused.
- Note, however, that in an executable all references to the
- symbol go to the PLT, so we can't turn it off in that case.
- ??? The correct thing to do here is to reference count
- all uses of the symbol, not just those to the GOT or PLT. */
+ 3. We know for certain that a call to this symbol
+ will go to this object, or will remain undefined. */
h->plt.offset = (bfd_vma) -1;
h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
- return true;
- }
-
- /* Make sure this symbol is output as a dynamic symbol. */
- if (h->dynindx == -1)
- {
- if (! bfd_elf32_link_record_dynamic_symbol (info, h))
- return false;
- }
- BFD_ASSERT (h->dynindx != -1);
-
- s = bfd_get_section_by_name (dynobj, ".plt");
- BFD_ASSERT (s != NULL);
-
- /* If this is the first .plt entry, make room for the special
- first entry. */
- if (s->_raw_size == 0)
- s->_raw_size += PLT_INITIAL_ENTRY_SIZE;
-
- /* The PowerPC PLT is actually composed of two parts, the first part
- is 2 words (for a load and a jump), and then there is a remaining
- word available at the end. */
- plt_offset = (PLT_INITIAL_ENTRY_SIZE
- + (PLT_SLOT_SIZE
- * ((s->_raw_size - PLT_INITIAL_ENTRY_SIZE)
- / PLT_ENTRY_SIZE)));
-
- /* If this symbol is not defined in a regular file, and we are
- not generating a shared library, then set the symbol to this
- location in the .plt. This is required to make function
- pointers compare as equal between the normal executable and
- the shared library. */
- if (! info->shared
- && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
- {
- h->root.u.def.section = s;
- h->root.u.def.value = plt_offset;
}
-
- h->plt.offset = plt_offset;
-
- /* Make room for this entry. After the 8192nd entry, room
- for two entries is allocated. */
- if ((s->_raw_size - PLT_INITIAL_ENTRY_SIZE) / PLT_ENTRY_SIZE
- >= PLT_NUM_SINGLE_ENTRIES)
- s->_raw_size += 2 * PLT_ENTRY_SIZE;
- else
- s->_raw_size += PLT_ENTRY_SIZE;
-
- /* We also need to make an entry in the .rela.plt section. */
- s = bfd_get_section_by_name (dynobj, ".rela.plt");
- BFD_ASSERT (s != NULL);
- s->_raw_size += sizeof (Elf32_External_Rela);
-
- return true;
+ return TRUE;
}
else
h->plt.offset = (bfd_vma) -1;
@@ -1847,7 +2890,11 @@ ppc_elf_adjust_dynamic_symbol (info, h)
|| h->weakdef->root.type == bfd_link_hash_defweak);
h->root.u.def.section = h->weakdef->root.u.def.section;
h->root.u.def.value = h->weakdef->root.u.def.value;
- return true;
+ if (ELIMINATE_COPY_RELOCS)
+ h->elf_link_hash_flags
+ = ((h->elf_link_hash_flags & ~ELF_LINK_NON_GOT_REF)
+ | (h->weakdef->elf_link_hash_flags & ELF_LINK_NON_GOT_REF));
+ return TRUE;
}
/* This is a reference to a symbol defined by a dynamic object which
@@ -1858,7 +2905,31 @@ ppc_elf_adjust_dynamic_symbol (info, h)
For such cases we need not do anything here; the relocations will
be handled correctly by relocate_section. */
if (info->shared)
- return true;
+ return TRUE;
+
+ /* If there are no references to this symbol that do not use the
+ GOT, we don't need to generate a copy reloc. */
+ if ((h->elf_link_hash_flags & ELF_LINK_NON_GOT_REF) == 0)
+ return TRUE;
+
+ if (ELIMINATE_COPY_RELOCS)
+ {
+ struct ppc_elf_dyn_relocs *p;
+ for (p = ppc_elf_hash_entry (h)->dyn_relocs; p != NULL; p = p->next)
+ {
+ s = p->sec->output_section;
+ if (s != NULL && (s->flags & SEC_READONLY) != 0)
+ break;
+ }
+
+ /* If we didn't find any dynamic relocs in read-only sections, then
+ we'll be keeping the dynamic relocs and avoiding the copy reloc. */
+ if (p == NULL)
+ {
+ h->elf_link_hash_flags &= ~ELF_LINK_NON_GOT_REF;
+ return TRUE;
+ }
+ }
/* We must allocate the symbol in our .dynbss section, which will
become part of the .bss section of the executable. There will be
@@ -1874,10 +2945,10 @@ ppc_elf_adjust_dynamic_symbol (info, h)
allocate it in .sbss. FIXME: It would be better to do this if and
only if there were actually SDAREL relocs for that symbol. */
- if (h->size <= elf_gp_size (dynobj))
- s = bfd_get_section_by_name (dynobj, ".dynsbss");
+ if (h->size <= elf_gp_size (htab->elf.dynobj))
+ s = htab->dynsbss;
else
- s = bfd_get_section_by_name (dynobj, ".dynbss");
+ s = htab->dynbss;
BFD_ASSERT (s != NULL);
/* We must generate a R_PPC_COPY reloc to tell the dynamic linker to
@@ -1888,10 +2959,10 @@ ppc_elf_adjust_dynamic_symbol (info, h)
{
asection *srel;
- if (h->size <= elf_gp_size (dynobj))
- srel = bfd_get_section_by_name (dynobj, ".rela.sbss");
+ if (h->size <= elf_gp_size (htab->elf.dynobj))
+ srel = htab->relsbss;
else
- srel = bfd_get_section_by_name (dynobj, ".rela.bss");
+ srel = htab->relbss;
BFD_ASSERT (srel != NULL);
srel->_raw_size += sizeof (Elf32_External_Rela);
h->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_COPY;
@@ -1906,10 +2977,10 @@ ppc_elf_adjust_dynamic_symbol (info, h)
/* Apply the required alignment. */
s->_raw_size = BFD_ALIGN (s->_raw_size,
(bfd_size_type) (1 << power_of_two));
- if (power_of_two > bfd_get_section_alignment (dynobj, s))
+ if (power_of_two > bfd_get_section_alignment (htab->elf.dynobj, s))
{
- if (! bfd_set_section_alignment (dynobj, s, power_of_two))
- return false;
+ if (! bfd_set_section_alignment (htab->elf.dynobj, s, power_of_two))
+ return FALSE;
}
/* Define the symbol as being at this point in the section. */
@@ -1919,93 +2990,426 @@ ppc_elf_adjust_dynamic_symbol (info, h)
/* Increment the section size to make room for the symbol. */
s->_raw_size += h->size;
- return true;
+ return TRUE;
}
+/* Of those relocs that might be copied as dynamic relocs, this macro
+ selects those that must be copied when linking a shared library,
+ even when the symbol is local. */
+
+#define MUST_BE_DYN_RELOC(RTYPE) \
+ ((RTYPE) != R_PPC_REL24 \
+ && (RTYPE) != R_PPC_REL14 \
+ && (RTYPE) != R_PPC_REL14_BRTAKEN \
+ && (RTYPE) != R_PPC_REL14_BRNTAKEN \
+ && (RTYPE) != R_PPC_REL32)
+
+/* Allocate space in associated reloc sections for dynamic relocs. */
+
+static bfd_boolean
+allocate_dynrelocs (struct elf_link_hash_entry *h, void *inf)
+{
+ struct bfd_link_info *info = inf;
+ struct ppc_elf_link_hash_entry *eh;
+ struct ppc_elf_link_hash_table *htab;
+ struct ppc_elf_dyn_relocs *p;
+
+ if (h->root.type == bfd_link_hash_indirect)
+ return TRUE;
+
+ if (h->root.type == bfd_link_hash_warning)
+ /* When warning symbols are created, they **replace** the "real"
+ entry in the hash table, thus we never get to see the real
+ symbol in a hash traversal. So look at it now. */
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ htab = ppc_elf_hash_table (info);
+ if (htab->elf.dynamic_sections_created
+ && h->plt.refcount > 0)
+ {
+ /* Make sure this symbol is output as a dynamic symbol. */
+ if (h->dynindx == -1
+ && (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
+ }
+
+ if (info->shared
+ || WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, 0, h))
+ {
+ asection *s = htab->plt;
+
+ /* If this is the first .plt entry, make room for the special
+ first entry. */
+ if (s->_raw_size == 0)
+ s->_raw_size += PLT_INITIAL_ENTRY_SIZE;
+
+ /* The PowerPC PLT is actually composed of two parts, the
+ first part is 2 words (for a load and a jump), and then
+ there is a remaining word available at the end. */
+ h->plt.offset = (PLT_INITIAL_ENTRY_SIZE
+ + (PLT_SLOT_SIZE
+ * ((s->_raw_size - PLT_INITIAL_ENTRY_SIZE)
+ / PLT_ENTRY_SIZE)));
+
+ /* If this symbol is not defined in a regular file, and we
+ are not generating a shared library, then set the symbol
+ to this location in the .plt. This is required to make
+ function pointers compare as equal between the normal
+ executable and the shared library. */
+ if (! info->shared
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
+ {
+ h->root.u.def.section = s;
+ h->root.u.def.value = h->plt.offset;
+ }
+
+ /* Make room for this entry. After the 8192nd entry, room
+ for two entries is allocated. */
+ s->_raw_size += PLT_ENTRY_SIZE;
+ if ((s->_raw_size - PLT_INITIAL_ENTRY_SIZE) / PLT_ENTRY_SIZE
+ > PLT_NUM_SINGLE_ENTRIES)
+ s->_raw_size += PLT_ENTRY_SIZE;
+
+ /* We also need to make an entry in the .rela.plt section. */
+ htab->relplt->_raw_size += sizeof (Elf32_External_Rela);
+ }
+ else
+ {
+ h->plt.offset = (bfd_vma) -1;
+ h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
+ }
+ }
+ else
+ {
+ h->plt.offset = (bfd_vma) -1;
+ h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
+ }
+
+ eh = (struct ppc_elf_link_hash_entry *) h;
+ if (eh->elf.got.refcount > 0)
+ {
+ /* Make sure this symbol is output as a dynamic symbol. */
+ if (eh->elf.dynindx == -1
+ && (eh->elf.elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
+ {
+ if (!bfd_elf_link_record_dynamic_symbol (info, &eh->elf))
+ return FALSE;
+ }
+
+ if (eh->tls_mask == (TLS_TLS | TLS_LD)
+ && !(eh->elf.elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC))
+ /* If just an LD reloc, we'll just use htab->tlsld_got.offset. */
+ eh->elf.got.offset = (bfd_vma) -1;
+ else
+ {
+ bfd_boolean dyn;
+ eh->elf.got.offset = htab->got->_raw_size;
+ if ((eh->tls_mask & TLS_TLS) != 0)
+ {
+ if ((eh->tls_mask & TLS_LD) != 0)
+ htab->got->_raw_size += 8;
+ if ((eh->tls_mask & TLS_GD) != 0)
+ htab->got->_raw_size += 8;
+ if ((eh->tls_mask & (TLS_TPREL | TLS_TPRELGD)) != 0)
+ htab->got->_raw_size += 4;
+ if ((eh->tls_mask & TLS_DTPREL) != 0)
+ htab->got->_raw_size += 4;
+ }
+ else
+ htab->got->_raw_size += 4;
+ dyn = htab->elf.dynamic_sections_created;
+ if ((info->shared
+ || WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, 0, &eh->elf))
+ && (ELF_ST_VISIBILITY (eh->elf.other) == STV_DEFAULT
+ || eh->elf.root.type != bfd_link_hash_undefweak))
+ {
+ /* All the entries we allocated need relocs. */
+ htab->relgot->_raw_size
+ += ((htab->got->_raw_size - eh->elf.got.offset) / 4
+ * sizeof (Elf32_External_Rela));
+ /* Except LD only needs one. */
+ if ((eh->tls_mask & TLS_LD) != 0)
+ htab->relgot->_raw_size -= sizeof (Elf32_External_Rela);
+ }
+ }
+ }
+ else
+ eh->elf.got.offset = (bfd_vma) -1;
+
+ if (eh->dyn_relocs == NULL)
+ return TRUE;
+
+ /* In the shared -Bsymbolic case, discard space allocated for
+ dynamic pc-relative relocs against symbols which turn out to be
+ defined in regular objects. For the normal shared case, discard
+ space for relocs that have become local due to symbol visibility
+ changes. */
+
+ if (info->shared)
+ {
+ /* Relocs that use pc_count are those that appear on a call insn,
+ or certain REL relocs (see MUST_BE_DYN_RELOC) that can be
+ generated via assembly. We want calls to protected symbols to
+ resolve directly to the function rather than going via the plt.
+ If people want function pointer comparisons to work as expected
+ then they should avoid writing weird assembly. */
+ if (SYMBOL_CALLS_LOCAL (info, h))
+ {
+ struct ppc_elf_dyn_relocs **pp;
+
+ for (pp = &eh->dyn_relocs; (p = *pp) != NULL; )
+ {
+ p->count -= p->pc_count;
+ p->pc_count = 0;
+ if (p->count == 0)
+ *pp = p->next;
+ else
+ pp = &p->next;
+ }
+ }
+
+ /* Also discard relocs on undefined weak syms with non-default
+ visibility. */
+ if (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+ && h->root.type == bfd_link_hash_undefweak)
+ eh->dyn_relocs = NULL;
+
+ /* Make sure undefined weak symbols are output as a dynamic symbol
+ in PIEs. */
+ if (info->pie
+ && eh->dyn_relocs != NULL
+ && h->dynindx == -1
+ && h->root.type == bfd_link_hash_undefweak
+ && (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
+ }
+ }
+ else if (ELIMINATE_COPY_RELOCS)
+ {
+ /* For the non-shared case, discard space for relocs against
+ symbols which turn out to need copy relocs or are not
+ dynamic. */
+
+ if ((h->elf_link_hash_flags & ELF_LINK_NON_GOT_REF) == 0
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
+ {
+ /* Make sure this symbol is output as a dynamic symbol.
+ Undefined weak syms won't yet be marked as dynamic. */
+ if (h->dynindx == -1
+ && (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
+ }
+
+ /* If that succeeded, we know we'll be keeping all the
+ relocs. */
+ if (h->dynindx != -1)
+ goto keep;
+ }
+
+ eh->dyn_relocs = NULL;
+
+ keep: ;
+ }
+
+ /* Finally, allocate space. */
+ for (p = eh->dyn_relocs; p != NULL; p = p->next)
+ {
+ asection *sreloc = elf_section_data (p->sec)->sreloc;
+ sreloc->_raw_size += p->count * sizeof (Elf32_External_Rela);
+ }
+
+ return TRUE;
+}
+
+/* Find any dynamic relocs that apply to read-only sections. */
+
+static bfd_boolean
+readonly_dynrelocs (struct elf_link_hash_entry *h, void *info)
+{
+ struct ppc_elf_dyn_relocs *p;
+
+ if (h->root.type == bfd_link_hash_indirect)
+ return TRUE;
+
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ for (p = ppc_elf_hash_entry (h)->dyn_relocs; p != NULL; p = p->next)
+ {
+ asection *s = p->sec->output_section;
+
+ if (s != NULL
+ && ((s->flags & (SEC_READONLY | SEC_ALLOC))
+ == (SEC_READONLY | SEC_ALLOC)))
+ {
+ ((struct bfd_link_info *) info)->flags |= DF_TEXTREL;
+
+ /* Not an error, just cut short the traversal. */
+ return FALSE;
+ }
+ }
+ return TRUE;
+}
+
/* Set the sizes of the dynamic sections. */
-static boolean
-ppc_elf_size_dynamic_sections (output_bfd, info)
- bfd *output_bfd ATTRIBUTE_UNUSED;
- struct bfd_link_info *info;
+static bfd_boolean
+ppc_elf_size_dynamic_sections (bfd *output_bfd ATTRIBUTE_UNUSED,
+ struct bfd_link_info *info)
{
- bfd *dynobj;
+ struct ppc_elf_link_hash_table *htab;
asection *s;
- boolean plt;
- boolean relocs;
+ bfd_boolean relocs;
+ bfd *ibfd;
#ifdef DEBUG
fprintf (stderr, "ppc_elf_size_dynamic_sections called\n");
#endif
- dynobj = elf_hash_table (info)->dynobj;
- BFD_ASSERT (dynobj != NULL);
+ htab = ppc_elf_hash_table (info);
+ BFD_ASSERT (htab->elf.dynobj != NULL);
if (elf_hash_table (info)->dynamic_sections_created)
{
/* Set the contents of the .interp section to the interpreter. */
- if (! info->shared)
+ if (info->executable)
{
- s = bfd_get_section_by_name (dynobj, ".interp");
+ s = bfd_get_section_by_name (htab->elf.dynobj, ".interp");
BFD_ASSERT (s != NULL);
s->_raw_size = sizeof ELF_DYNAMIC_INTERPRETER;
s->contents = (unsigned char *) ELF_DYNAMIC_INTERPRETER;
}
}
+
+ if (htab->tlsld_got.refcount > 0)
+ {
+ htab->tlsld_got.offset = htab->got->_raw_size;
+ htab->got->_raw_size += 8;
+ if (info->shared)
+ htab->relgot->_raw_size += sizeof (Elf32_External_Rela);
+ }
else
+ htab->tlsld_got.offset = (bfd_vma) -1;
+
+ /* Set up .got offsets for local syms, and space for local dynamic
+ relocs. */
+ for (ibfd = info->input_bfds; ibfd != NULL; ibfd = ibfd->link_next)
{
- /* We may have created entries in the .rela.got, .rela.sdata, and
- .rela.sdata2 sections. However, if we are not creating the
- dynamic sections, we will not actually use these entries. Reset
- the size of .rela.got, et al, which will cause it to get
- stripped from the output file below. */
- static char *rela_sections[] = { ".rela.got", ".rela.sdata",
- ".rela.sdata2", ".rela.sbss",
- (char *) 0 };
- char **p;
+ bfd_signed_vma *local_got;
+ bfd_signed_vma *end_local_got;
+ char *lgot_masks;
+ bfd_size_type locsymcount;
+ Elf_Internal_Shdr *symtab_hdr;
+ asection *srel;
+
+ if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour)
+ continue;
- for (p = rela_sections; *p != (char *) 0; p++)
+ for (s = ibfd->sections; s != NULL; s = s->next)
{
- s = bfd_get_section_by_name (dynobj, *p);
- if (s != NULL)
- s->_raw_size = 0;
+ struct ppc_elf_dyn_relocs *p;
+
+ for (p = ((struct ppc_elf_dyn_relocs *)
+ elf_section_data (s)->local_dynrel);
+ p != NULL;
+ p = p->next)
+ {
+ if (!bfd_is_abs_section (p->sec)
+ && bfd_is_abs_section (p->sec->output_section))
+ {
+ /* Input section has been discarded, either because
+ it is a copy of a linkonce section or due to
+ linker script /DISCARD/, so we'll be discarding
+ the relocs too. */
+ }
+ else if (p->count != 0)
+ {
+ elf_section_data (p->sec)->sreloc->_raw_size
+ += p->count * sizeof (Elf32_External_Rela);
+ if ((p->sec->output_section->flags
+ & (SEC_READONLY | SEC_ALLOC))
+ == (SEC_READONLY | SEC_ALLOC))
+ info->flags |= DF_TEXTREL;
+ }
+ }
}
+
+ local_got = elf_local_got_refcounts (ibfd);
+ if (!local_got)
+ continue;
+
+ symtab_hdr = &elf_tdata (ibfd)->symtab_hdr;
+ locsymcount = symtab_hdr->sh_info;
+ end_local_got = local_got + locsymcount;
+ lgot_masks = (char *) end_local_got;
+ s = htab->got;
+ srel = htab->relgot;
+ for (; local_got < end_local_got; ++local_got, ++lgot_masks)
+ if (*local_got > 0)
+ {
+ if (*lgot_masks == (TLS_TLS | TLS_LD))
+ {
+ /* If just an LD reloc, we'll just use
+ htab->tlsld_got.offset. */
+ if (htab->tlsld_got.offset == (bfd_vma) -1)
+ {
+ htab->tlsld_got.offset = s->_raw_size;
+ s->_raw_size += 8;
+ if (info->shared)
+ srel->_raw_size += sizeof (Elf32_External_Rela);
+ }
+ *local_got = (bfd_vma) -1;
+ }
+ else
+ {
+ *local_got = s->_raw_size;
+ if ((*lgot_masks & TLS_TLS) != 0)
+ {
+ if ((*lgot_masks & TLS_GD) != 0)
+ s->_raw_size += 8;
+ if ((*lgot_masks & (TLS_TPREL | TLS_TPRELGD)) != 0)
+ s->_raw_size += 4;
+ if ((*lgot_masks & TLS_DTPREL) != 0)
+ s->_raw_size += 4;
+ }
+ else
+ s->_raw_size += 4;
+ if (info->shared)
+ srel->_raw_size += ((s->_raw_size - *local_got) / 4
+ * sizeof (Elf32_External_Rela));
+ }
+ }
+ else
+ *local_got = (bfd_vma) -1;
}
- /* The check_relocs and adjust_dynamic_symbol entry points have
- determined the sizes of the various dynamic sections. Allocate
- memory for them. */
- plt = false;
- relocs = false;
- for (s = dynobj->sections; s != NULL; s = s->next)
- {
- const char *name;
- boolean strip;
+ /* Allocate space for global sym dynamic relocs. */
+ elf_link_hash_traverse (elf_hash_table (info), allocate_dynrelocs, info);
+ /* We've now determined the sizes of the various dynamic sections.
+ Allocate memory for them. */
+ relocs = FALSE;
+ for (s = htab->elf.dynobj->sections; s != NULL; s = s->next)
+ {
if ((s->flags & SEC_LINKER_CREATED) == 0)
continue;
- /* It's OK to base decisions on the section name, because none
- of the dynobj section names depend upon the input files. */
- name = bfd_get_section_name (dynobj, s);
-
- strip = false;
-
- if (strcmp (name, ".plt") == 0)
+ if (s == htab->plt
+ || s == htab->got
+ || (htab->sdata != NULL && s == htab->sdata->section)
+ || (htab->sdata2 != NULL && s == htab->sdata2->section))
{
- if (s->_raw_size == 0)
- {
- /* Strip this section if we don't need it; see the
- comment below. */
- strip = true;
- }
- else
- {
- /* Remember whether there is a PLT. */
- plt = true;
- }
+ /* Strip this section if we don't need it; see the
+ comment below. */
}
- else if (strncmp (name, ".rela", 5) == 0)
+ else if (strncmp (bfd_get_section_name (dynobj, s), ".rela", 5) == 0)
{
if (s->_raw_size == 0)
{
@@ -2018,39 +3422,36 @@ ppc_elf_size_dynamic_sections (output_bfd, info)
adjust_dynamic_symbol is called, and it is that
function which decides whether anything needs to go
into these sections. */
- strip = true;
}
else
{
/* Remember whether there are any relocation sections. */
- relocs = true;
+ relocs = TRUE;
/* We use the reloc_count field as a counter if we need
to copy relocs into the output file. */
s->reloc_count = 0;
}
}
- else if (strcmp (name, ".got") != 0
- && strcmp (name, ".sdata") != 0
- && strcmp (name, ".sdata2") != 0)
+ else
{
/* It's not one of our sections, so don't allocate space. */
continue;
}
- if (strip)
+ if (s->_raw_size == 0)
{
_bfd_strip_section_from_output (info, s);
continue;
}
/* Allocate memory for the section contents. */
- s->contents = (bfd_byte *) bfd_zalloc (dynobj, s->_raw_size);
- if (s->contents == NULL && s->_raw_size != 0)
- return false;
+ s->contents = bfd_zalloc (htab->elf.dynobj, s->_raw_size);
+ if (s->contents == NULL)
+ return FALSE;
}
- if (elf_hash_table (info)->dynamic_sections_created)
+ if (htab->elf.dynamic_sections_created)
{
/* Add some entries to the .dynamic section. We fill in the
values later, in ppc_elf_finish_dynamic_sections, but we
@@ -2058,21 +3459,21 @@ ppc_elf_size_dynamic_sections (output_bfd, info)
the .dynamic section. The DT_DEBUG entry is filled in by the
dynamic linker and used by the debugger. */
#define add_dynamic_entry(TAG, VAL) \
- bfd_elf32_add_dynamic_entry (info, (bfd_vma) (TAG), (bfd_vma) (VAL))
+ _bfd_elf_add_dynamic_entry (info, TAG, VAL)
- if (!info->shared)
+ if (info->executable)
{
if (!add_dynamic_entry (DT_DEBUG, 0))
- return false;
+ return FALSE;
}
- if (plt)
+ if (htab->plt != NULL && htab->plt->_raw_size != 0)
{
if (!add_dynamic_entry (DT_PLTGOT, 0)
|| !add_dynamic_entry (DT_PLTRELSZ, 0)
|| !add_dynamic_entry (DT_PLTREL, DT_RELA)
|| !add_dynamic_entry (DT_JMPREL, 0))
- return false;
+ return FALSE;
}
if (relocs)
@@ -2080,46 +3481,81 @@ ppc_elf_size_dynamic_sections (output_bfd, info)
if (!add_dynamic_entry (DT_RELA, 0)
|| !add_dynamic_entry (DT_RELASZ, 0)
|| !add_dynamic_entry (DT_RELAENT, sizeof (Elf32_External_Rela)))
- return false;
+ return FALSE;
}
+ /* If any dynamic relocs apply to a read-only section, then we
+ need a DT_TEXTREL entry. */
+ if ((info->flags & DF_TEXTREL) == 0)
+ elf_link_hash_traverse (elf_hash_table (info), readonly_dynrelocs,
+ info);
+
if ((info->flags & DF_TEXTREL) != 0)
{
if (!add_dynamic_entry (DT_TEXTREL, 0))
- return false;
- info->flags |= DF_TEXTREL;
+ return FALSE;
}
}
#undef add_dynamic_entry
- return true;
+ return TRUE;
}
+static bfd_boolean
+update_local_sym_info (bfd *abfd,
+ Elf_Internal_Shdr *symtab_hdr,
+ unsigned long r_symndx,
+ int tls_type)
+{
+ bfd_signed_vma *local_got_refcounts = elf_local_got_refcounts (abfd);
+ char *local_got_tls_masks;
+
+ if (local_got_refcounts == NULL)
+ {
+ bfd_size_type size = symtab_hdr->sh_info;
+
+ size *= sizeof (*local_got_refcounts) + sizeof (*local_got_tls_masks);
+ local_got_refcounts = bfd_zalloc (abfd, size);
+ if (local_got_refcounts == NULL)
+ return FALSE;
+ elf_local_got_refcounts (abfd) = local_got_refcounts;
+ }
+
+ local_got_refcounts[r_symndx] += 1;
+ local_got_tls_masks = (char *) (local_got_refcounts + symtab_hdr->sh_info);
+ local_got_tls_masks[r_symndx] |= tls_type;
+ return TRUE;
+}
+
+static void
+bad_shared_reloc (bfd *abfd, enum elf_ppc_reloc_type r_type)
+{
+ (*_bfd_error_handler)
+ (_("%s: relocation %s cannot be used when making a shared object"),
+ bfd_archive_filename (abfd),
+ ppc_elf_howto_table[r_type]->name);
+ bfd_set_error (bfd_error_bad_value);
+}
+
/* Look through the relocs for a section during the first phase, and
allocate space in the global offset table or procedure linkage
table. */
-static boolean
-ppc_elf_check_relocs (abfd, info, sec, relocs)
- bfd *abfd;
- struct bfd_link_info *info;
- asection *sec;
- const Elf_Internal_Rela *relocs;
+static bfd_boolean
+ppc_elf_check_relocs (bfd *abfd,
+ struct bfd_link_info *info,
+ asection *sec,
+ const Elf_Internal_Rela *relocs)
{
- bfd *dynobj;
+ struct ppc_elf_link_hash_table *htab;
Elf_Internal_Shdr *symtab_hdr;
- struct elf_link_hash_entry **sym_hashes, **sym_hashes_end;
+ struct elf_link_hash_entry **sym_hashes;
const Elf_Internal_Rela *rel;
const Elf_Internal_Rela *rel_end;
- bfd_signed_vma *local_got_refcounts;
- elf_linker_section_t *sdata;
- elf_linker_section_t *sdata2;
asection *sreloc;
- asection *sgot = NULL;
- asection *srelgot = NULL;
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
#ifdef DEBUG
fprintf (stderr, "ppc_elf_check_relocs called for section %s in %s\n",
@@ -2127,39 +3563,40 @@ ppc_elf_check_relocs (abfd, info, sec, relocs)
bfd_archive_filename (abfd));
#endif
+ /* Initialize howto table if not already done. */
+ if (!ppc_elf_howto_table[R_PPC_ADDR32])
+ ppc_elf_howto_init ();
+
/* Create the linker generated sections all the time so that the
special symbols are created. */
-
- if ((sdata = elf_linker_section (abfd, LINKER_SECTION_SDATA)) == NULL)
+ htab = ppc_elf_hash_table (info);
+ if (htab->sdata == NULL)
{
- sdata = ppc_elf_create_linker_section (abfd, info, LINKER_SECTION_SDATA);
- if (!sdata)
- return false;
+ htab->sdata = ppc_elf_create_linker_section (abfd, info,
+ LINKER_SECTION_SDATA);
+ if (htab->sdata == NULL)
+ return FALSE;
}
- if ((sdata2 = elf_linker_section (abfd, LINKER_SECTION_SDATA2)) == NULL)
+ if (htab->sdata2 == NULL)
{
- sdata2 = ppc_elf_create_linker_section (abfd, info, LINKER_SECTION_SDATA2);
- if (!sdata2)
- return false;
+ htab->sdata2 = ppc_elf_create_linker_section (abfd, info,
+ LINKER_SECTION_SDATA2);
+ if (htab->sdata2 == NULL)
+ return FALSE;
}
- dynobj = elf_hash_table (info)->dynobj;
symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
- local_got_refcounts = elf_local_got_refcounts (abfd);
-
sym_hashes = elf_sym_hashes (abfd);
- sym_hashes_end = sym_hashes + symtab_hdr->sh_size/sizeof (Elf32_External_Sym);
- if (!elf_bad_symtab (abfd))
- sym_hashes_end -= symtab_hdr->sh_info;
-
sreloc = NULL;
rel_end = relocs + sec->reloc_count;
for (rel = relocs; rel < rel_end; rel++)
{
unsigned long r_symndx;
+ enum elf_ppc_reloc_type r_type;
struct elf_link_hash_entry *h;
+ int tls_type = 0;
r_symndx = ELF32_R_SYM (rel->r_info);
if (r_symndx < symtab_hdr->sh_info)
@@ -2172,182 +3609,118 @@ ppc_elf_check_relocs (abfd, info, sec, relocs)
startup code. */
if (h && strcmp (h->root.root.string, "_GLOBAL_OFFSET_TABLE_") == 0)
{
- if (sgot == NULL)
+ if (htab->got == NULL)
{
- if (dynobj == NULL)
- elf_hash_table (info)->dynobj = dynobj = abfd;
- sgot = ppc_elf_create_got (dynobj, info);
- if (sgot == NULL)
- return false;
+ if (htab->elf.dynobj == NULL)
+ htab->elf.dynobj = abfd;
+ if (!ppc_elf_create_got (htab->elf.dynobj, info))
+ return FALSE;
}
}
- switch (ELF32_R_TYPE (rel->r_info))
+ r_type = ELF32_R_TYPE (rel->r_info);
+ switch (r_type)
{
- /* GOT16 relocations */
+ case R_PPC_GOT_TLSLD16:
+ case R_PPC_GOT_TLSLD16_LO:
+ case R_PPC_GOT_TLSLD16_HI:
+ case R_PPC_GOT_TLSLD16_HA:
+ htab->tlsld_got.refcount += 1;
+ tls_type = TLS_TLS | TLS_LD;
+ goto dogottls;
+
+ case R_PPC_GOT_TLSGD16:
+ case R_PPC_GOT_TLSGD16_LO:
+ case R_PPC_GOT_TLSGD16_HI:
+ case R_PPC_GOT_TLSGD16_HA:
+ tls_type = TLS_TLS | TLS_GD;
+ goto dogottls;
+
+ case R_PPC_GOT_TPREL16:
+ case R_PPC_GOT_TPREL16_LO:
+ case R_PPC_GOT_TPREL16_HI:
+ case R_PPC_GOT_TPREL16_HA:
+ if (info->shared)
+ info->flags |= DF_STATIC_TLS;
+ tls_type = TLS_TLS | TLS_TPREL;
+ goto dogottls;
+
+ case R_PPC_GOT_DTPREL16:
+ case R_PPC_GOT_DTPREL16_LO:
+ case R_PPC_GOT_DTPREL16_HI:
+ case R_PPC_GOT_DTPREL16_HA:
+ tls_type = TLS_TLS | TLS_DTPREL;
+ dogottls:
+ sec->has_tls_reloc = 1;
+ /* Fall thru */
+
+ /* GOT16 relocations */
case R_PPC_GOT16:
case R_PPC_GOT16_LO:
case R_PPC_GOT16_HI:
case R_PPC_GOT16_HA:
/* This symbol requires a global offset table entry. */
-
- if (sgot == NULL)
- {
- if (dynobj == NULL)
- elf_hash_table (info)->dynobj = dynobj = abfd;
- sgot = ppc_elf_create_got (dynobj, info);
- if (sgot == NULL)
- return false;
- }
-
- if (srelgot == NULL
- && (h != NULL || info->shared))
+ if (htab->got == NULL)
{
- srelgot = bfd_get_section_by_name (dynobj, ".rela.got");
- if (srelgot == NULL)
- {
- srelgot = bfd_make_section (dynobj, ".rela.got");
- if (srelgot == NULL
- || ! bfd_set_section_flags (dynobj, srelgot,
- (SEC_ALLOC
- | SEC_LOAD
- | SEC_HAS_CONTENTS
- | SEC_IN_MEMORY
- | SEC_LINKER_CREATED
- | SEC_READONLY))
- || ! bfd_set_section_alignment (dynobj, srelgot, 2))
- return false;
- }
+ if (htab->elf.dynobj == NULL)
+ htab->elf.dynobj = abfd;
+ if (!ppc_elf_create_got (htab->elf.dynobj, info))
+ return FALSE;
}
-
if (h != NULL)
{
- if (h->got.refcount == 0)
- {
- /* Make sure this symbol is output as a dynamic symbol. */
- if (h->dynindx == -1)
- if (!bfd_elf32_link_record_dynamic_symbol (info, h))
- return false;
-
- /* Allocate space in the .got. */
- sgot->_raw_size += 4;
- /* Allocate relocation space. */
- srelgot->_raw_size += sizeof (Elf32_External_Rela);
- }
- h->got.refcount++;
+ h->got.refcount += 1;
+ ppc_elf_hash_entry (h)->tls_mask |= tls_type;
}
else
- {
- /* This is a global offset table entry for a local symbol. */
- if (local_got_refcounts == NULL)
- {
- bfd_size_type size;
-
- size = symtab_hdr->sh_info;
- size *= sizeof (bfd_signed_vma);
- local_got_refcounts
- = (bfd_signed_vma *) bfd_zalloc (abfd, size);
- if (local_got_refcounts == NULL)
- return false;
- elf_local_got_refcounts (abfd) = local_got_refcounts;
- }
- if (local_got_refcounts[r_symndx] == 0)
- {
- sgot->_raw_size += 4;
-
- /* If we are generating a shared object, we need to
- output a R_PPC_RELATIVE reloc so that the
- dynamic linker can adjust this GOT entry. */
- if (info->shared)
- srelgot->_raw_size += sizeof (Elf32_External_Rela);
- }
- local_got_refcounts[r_symndx]++;
- }
+ /* This is a global offset table entry for a local symbol. */
+ if (!update_local_sym_info (abfd, symtab_hdr, r_symndx, tls_type))
+ return FALSE;
break;
- /* Indirect .sdata relocation */
+ /* Indirect .sdata relocation. */
case R_PPC_EMB_SDAI16:
if (info->shared)
{
- ((*_bfd_error_handler)
- (_("%s: relocation %s cannot be used when making a shared object"),
- bfd_archive_filename (abfd), "R_PPC_EMB_SDAI16"));
- return false;
- }
-
- if (srelgot == NULL && (h != NULL || info->shared))
- {
- srelgot = bfd_get_section_by_name (dynobj, ".rela.got");
- if (srelgot == NULL)
- {
- srelgot = bfd_make_section (dynobj, ".rela.got");
- if (srelgot == NULL
- || ! bfd_set_section_flags (dynobj, srelgot,
- (SEC_ALLOC
- | SEC_LOAD
- | SEC_HAS_CONTENTS
- | SEC_IN_MEMORY
- | SEC_LINKER_CREATED
- | SEC_READONLY))
- || ! bfd_set_section_alignment (dynobj, srelgot, 2))
- return false;
- }
+ bad_shared_reloc (abfd, r_type);
+ return FALSE;
}
-
- if (!bfd_elf32_create_pointer_linker_section (abfd, info, sdata, h, rel))
- return false;
-
+ if (!elf_create_pointer_linker_section (abfd, info,
+ htab->sdata, h, rel))
+ return FALSE;
break;
- /* Indirect .sdata2 relocation */
+ /* Indirect .sdata2 relocation. */
case R_PPC_EMB_SDA2I16:
if (info->shared)
{
- ((*_bfd_error_handler)
- (_("%s: relocation %s cannot be used when making a shared object"),
- bfd_archive_filename (abfd), "R_PPC_EMB_SDA2I16"));
- return false;
- }
-
- if (srelgot == NULL && (h != NULL || info->shared))
- {
- srelgot = bfd_get_section_by_name (dynobj, ".rela.got");
- if (srelgot == NULL)
- {
- srelgot = bfd_make_section (dynobj, ".rela.got");
- if (srelgot == NULL
- || ! bfd_set_section_flags (dynobj, srelgot,
- (SEC_ALLOC
- | SEC_LOAD
- | SEC_HAS_CONTENTS
- | SEC_IN_MEMORY
- | SEC_LINKER_CREATED
- | SEC_READONLY))
- || ! bfd_set_section_alignment (dynobj, srelgot, 2))
- return false;
- }
+ bad_shared_reloc (abfd, r_type);
+ return FALSE;
}
-
- if (!bfd_elf32_create_pointer_linker_section (abfd, info, sdata2, h, rel))
- return false;
-
+ if (!elf_create_pointer_linker_section (abfd, info,
+ htab->sdata2, h, rel))
+ return FALSE;
break;
case R_PPC_SDAREL16:
case R_PPC_EMB_SDA2REL:
case R_PPC_EMB_SDA21:
+ case R_PPC_EMB_RELSDA:
+ case R_PPC_EMB_NADDR32:
+ case R_PPC_EMB_NADDR16:
+ case R_PPC_EMB_NADDR16_LO:
+ case R_PPC_EMB_NADDR16_HI:
+ case R_PPC_EMB_NADDR16_HA:
if (info->shared)
{
- ((*_bfd_error_handler)
- (_("%s: relocation %s cannot be used when making a shared object"),
- bfd_archive_filename (abfd),
- ppc_elf_howto_table[(int) ELF32_R_TYPE (rel->r_info)]->name));
- return false;
+ bad_shared_reloc (abfd, r_type);
+ return FALSE;
}
break;
case R_PPC_PLT32:
case R_PPC_PLTREL24:
+ case R_PPC_PLTREL32:
case R_PPC_PLT16_LO:
case R_PPC_PLT16_HI:
case R_PPC_PLT16_HA:
@@ -2355,25 +3728,25 @@ ppc_elf_check_relocs (abfd, info, sec, relocs)
fprintf (stderr, "Reloc requires a PLT entry\n");
#endif
/* This symbol requires a procedure linkage table entry. We
- actually build the entry in adjust_dynamic_symbol,
- because this might be a case of linking PIC code without
- linking in any dynamic objects, in which case we don't
- need to generate a procedure linkage table after all. */
+ actually build the entry in finish_dynamic_symbol,
+ because this might be a case of linking PIC code without
+ linking in any dynamic objects, in which case we don't
+ need to generate a procedure linkage table after all. */
if (h == NULL)
{
/* It does not make sense to have a procedure linkage
- table entry for a local symbol. */
+ table entry for a local symbol. */
+ (*_bfd_error_handler) (_("%s(%s+0x%lx): %s reloc against "
+ "local symbol"),
+ bfd_archive_filename (abfd),
+ sec->name,
+ (long) rel->r_offset,
+ ppc_elf_howto_table[r_type]->name);
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
- /* Make sure this symbol is output as a dynamic symbol. */
- if (h->dynindx == -1)
- {
- if (! bfd_elf32_link_record_dynamic_symbol (info, h))
- return false;
- }
h->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_PLT;
h->plt.refcount++;
break;
@@ -2385,26 +3758,73 @@ ppc_elf_check_relocs (abfd, info, sec, relocs)
case R_PPC_SECTOFF_LO:
case R_PPC_SECTOFF_HI:
case R_PPC_SECTOFF_HA:
+ case R_PPC_DTPREL16:
+ case R_PPC_DTPREL16_LO:
+ case R_PPC_DTPREL16_HI:
+ case R_PPC_DTPREL16_HA:
+ case R_PPC_TOC16:
+ break;
+
+ /* This are just markers. */
+ case R_PPC_TLS:
+ case R_PPC_EMB_MRKREF:
+ case R_PPC_NONE:
+ case R_PPC_max:
+ break;
+
+ /* These should only appear in dynamic objects. */
+ case R_PPC_COPY:
+ case R_PPC_GLOB_DAT:
+ case R_PPC_JMP_SLOT:
+ case R_PPC_RELATIVE:
break;
- /* This refers only to functions defined in the shared library */
+ /* These aren't handled yet. We'll report an error later. */
+ case R_PPC_ADDR30:
+ case R_PPC_EMB_RELSEC16:
+ case R_PPC_EMB_RELST_LO:
+ case R_PPC_EMB_RELST_HI:
+ case R_PPC_EMB_RELST_HA:
+ case R_PPC_EMB_BIT_FLD:
+ break;
+
+ /* This refers only to functions defined in the shared library. */
case R_PPC_LOCAL24PC:
break;
/* This relocation describes the C++ object vtable hierarchy.
Reconstruct it for later use during GC. */
case R_PPC_GNU_VTINHERIT:
- if (!_bfd_elf32_gc_record_vtinherit (abfd, sec, h, rel->r_offset))
- return false;
+ if (!bfd_elf_gc_record_vtinherit (abfd, sec, h, rel->r_offset))
+ return FALSE;
break;
/* This relocation describes which C++ vtable entries are actually
used. Record for later use during GC. */
case R_PPC_GNU_VTENTRY:
- if (!_bfd_elf32_gc_record_vtentry (abfd, sec, h, rel->r_addend))
- return false;
+ if (!bfd_elf_gc_record_vtentry (abfd, sec, h, rel->r_addend))
+ return FALSE;
break;
+ /* We shouldn't really be seeing these. */
+ case R_PPC_TPREL32:
+ if (info->shared)
+ info->flags |= DF_STATIC_TLS;
+ goto dodyn;
+
+ /* Nor these. */
+ case R_PPC_DTPMOD32:
+ case R_PPC_DTPREL32:
+ goto dodyn;
+
+ case R_PPC_TPREL16:
+ case R_PPC_TPREL16_LO:
+ case R_PPC_TPREL16_HI:
+ case R_PPC_TPREL16_HA:
+ if (info->shared)
+ info->flags |= DF_STATIC_TLS;
+ goto dodyn;
+
/* When creating a shared object, we must copy these
relocs into the output file. We create a reloc
section in dynobj and make room for the reloc. */
@@ -2414,17 +3834,77 @@ ppc_elf_check_relocs (abfd, info, sec, relocs)
case R_PPC_REL14_BRNTAKEN:
case R_PPC_REL32:
if (h == NULL
- || strcmp (h->root.root.string, "_GLOBAL_OFFSET_TABLE_") == 0
- || SYMBOL_REFERENCES_LOCAL (info, h))
+ || strcmp (h->root.root.string, "_GLOBAL_OFFSET_TABLE_") == 0)
break;
/* fall through */
- default:
- if (info->shared)
+ case R_PPC_ADDR32:
+ case R_PPC_ADDR24:
+ case R_PPC_ADDR16:
+ case R_PPC_ADDR16_LO:
+ case R_PPC_ADDR16_HI:
+ case R_PPC_ADDR16_HA:
+ case R_PPC_ADDR14:
+ case R_PPC_ADDR14_BRTAKEN:
+ case R_PPC_ADDR14_BRNTAKEN:
+ case R_PPC_UADDR32:
+ case R_PPC_UADDR16:
+ if (h != NULL && !info->shared)
+ {
+ /* We may need a plt entry if the symbol turns out to be
+ a function defined in a dynamic object. */
+ h->plt.refcount++;
+
+ /* We may need a copy reloc too. */
+ h->elf_link_hash_flags |= ELF_LINK_NON_GOT_REF;
+ }
+
+ dodyn:
+ /* If we are creating a shared library, and this is a reloc
+ against a global symbol, or a non PC relative reloc
+ against a local symbol, then we need to copy the reloc
+ into the shared library. However, if we are linking with
+ -Bsymbolic, we do not need to copy a reloc against a
+ global symbol which is defined in an object we are
+ including in the link (i.e., DEF_REGULAR is set). At
+ this point we have not seen all the input files, so it is
+ possible that DEF_REGULAR is not set now but will be set
+ later (it is never cleared). In case of a weak definition,
+ DEF_REGULAR may be cleared later by a strong definition in
+ a shared library. We account for that possibility below by
+ storing information in the dyn_relocs field of the hash
+ table entry. A similar situation occurs when creating
+ shared libraries and symbol visibility changes render the
+ symbol local.
+
+ If on the other hand, we are creating an executable, we
+ may need to keep relocations for symbols satisfied by a
+ dynamic library if we manage to avoid copy relocs for the
+ symbol. */
+ if ((info->shared
+ && (MUST_BE_DYN_RELOC (r_type)
+ || (h != NULL
+ && (! info->symbolic
+ || h->root.type == bfd_link_hash_defweak
+ || (h->elf_link_hash_flags
+ & ELF_LINK_HASH_DEF_REGULAR) == 0))))
+ || (ELIMINATE_COPY_RELOCS
+ && !info->shared
+ && (sec->flags & SEC_ALLOC) != 0
+ && h != NULL
+ && (h->root.type == bfd_link_hash_defweak
+ || (h->elf_link_hash_flags
+ & ELF_LINK_HASH_DEF_REGULAR) == 0)))
{
+ struct ppc_elf_dyn_relocs *p;
+ struct ppc_elf_dyn_relocs **head;
+
#ifdef DEBUG
- fprintf (stderr, "ppc_elf_check_relocs need to create relocation for %s\n",
- (h && h->root.root.string) ? h->root.root.string : "<unknown>");
+ fprintf (stderr,
+ "ppc_elf_check_relocs needs to "
+ "create relocation for %s\n",
+ (h && h->root.root.string
+ ? h->root.root.string : "<unknown>"));
#endif
if (sreloc == NULL)
{
@@ -2435,58 +3915,88 @@ ppc_elf_check_relocs (abfd, info, sec, relocs)
elf_elfheader (abfd)->e_shstrndx,
elf_section_data (sec)->rel_hdr.sh_name));
if (name == NULL)
- return false;
+ return FALSE;
BFD_ASSERT (strncmp (name, ".rela", 5) == 0
&& strcmp (bfd_get_section_name (abfd, sec),
name + 5) == 0);
- sreloc = bfd_get_section_by_name (dynobj, name);
+ sreloc = bfd_get_section_by_name (htab->elf.dynobj, name);
if (sreloc == NULL)
{
flagword flags;
- sreloc = bfd_make_section (dynobj, name);
+ sreloc = bfd_make_section (htab->elf.dynobj, name);
flags = (SEC_HAS_CONTENTS | SEC_READONLY
| SEC_IN_MEMORY | SEC_LINKER_CREATED);
if ((sec->flags & SEC_ALLOC) != 0)
flags |= SEC_ALLOC | SEC_LOAD;
if (sreloc == NULL
- || ! bfd_set_section_flags (dynobj, sreloc, flags)
- || ! bfd_set_section_alignment (dynobj, sreloc, 2))
- return false;
+ || ! bfd_set_section_flags (htab->elf.dynobj,
+ sreloc, flags)
+ || ! bfd_set_section_alignment (htab->elf.dynobj,
+ sreloc, 2))
+ return FALSE;
}
- if (sec->flags & SEC_READONLY)
- info->flags |= DF_TEXTREL;
+ elf_section_data (sec)->sreloc = sreloc;
}
- sreloc->_raw_size += sizeof (Elf32_External_Rela);
+ /* If this is a global symbol, we count the number of
+ relocations we need for this symbol. */
+ if (h != NULL)
+ {
+ head = &ppc_elf_hash_entry (h)->dyn_relocs;
+ }
+ else
+ {
+ /* Track dynamic relocs needed for local syms too.
+ We really need local syms available to do this
+ easily. Oh well. */
+
+ asection *s;
+ s = bfd_section_from_r_symndx (abfd, &htab->sym_sec,
+ sec, r_symndx);
+ if (s == NULL)
+ return FALSE;
+
+ head = ((struct ppc_elf_dyn_relocs **)
+ &elf_section_data (s)->local_dynrel);
+ }
- /* FIXME: We should here do what the m68k and i386
- backends do: if the reloc is pc-relative, record it
- in case it turns out that the reloc is unnecessary
- because the symbol is forced local by versioning or
- we are linking with -Bdynamic. Fortunately this
- case is not frequent. */
+ p = *head;
+ if (p == NULL || p->sec != sec)
+ {
+ p = bfd_alloc (htab->elf.dynobj, sizeof *p);
+ if (p == NULL)
+ return FALSE;
+ p->next = *head;
+ *head = p;
+ p->sec = sec;
+ p->count = 0;
+ p->pc_count = 0;
+ }
+
+ p->count += 1;
+ if (!MUST_BE_DYN_RELOC (r_type))
+ p->pc_count += 1;
}
break;
}
}
- return true;
+ return TRUE;
}
/* Return the section that should be marked against GC for a given
relocation. */
static asection *
-ppc_elf_gc_mark_hook (sec, info, rel, h, sym)
- asection *sec;
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
- Elf_Internal_Rela *rel;
- struct elf_link_hash_entry *h;
- Elf_Internal_Sym *sym;
+ppc_elf_gc_mark_hook (asection *sec,
+ struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ Elf_Internal_Rela *rel,
+ struct elf_link_hash_entry *h,
+ Elf_Internal_Sym *sym)
{
if (h != NULL)
{
@@ -2517,153 +4027,401 @@ ppc_elf_gc_mark_hook (sec, info, rel, h, sym)
return NULL;
}
-/* Update the got entry reference counts for the section being removed. */
+/* Update the got, plt and dynamic reloc reference counts for the
+ section being removed. */
-static boolean
-ppc_elf_gc_sweep_hook (abfd, info, sec, relocs)
- bfd *abfd;
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
- asection *sec;
- const Elf_Internal_Rela *relocs;
+static bfd_boolean
+ppc_elf_gc_sweep_hook (bfd *abfd,
+ struct bfd_link_info *info,
+ asection *sec,
+ const Elf_Internal_Rela *relocs)
{
+ struct ppc_elf_link_hash_table *htab;
Elf_Internal_Shdr *symtab_hdr;
struct elf_link_hash_entry **sym_hashes;
bfd_signed_vma *local_got_refcounts;
const Elf_Internal_Rela *rel, *relend;
- unsigned long r_symndx;
- struct elf_link_hash_entry *h;
+ elf_section_data (sec)->local_dynrel = NULL;
+
+ htab = ppc_elf_hash_table (info);
symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
sym_hashes = elf_sym_hashes (abfd);
local_got_refcounts = elf_local_got_refcounts (abfd);
relend = relocs + sec->reloc_count;
for (rel = relocs; rel < relend; rel++)
- switch (ELF32_R_TYPE (rel->r_info))
- {
- case R_PPC_GOT16:
- case R_PPC_GOT16_LO:
- case R_PPC_GOT16_HI:
- case R_PPC_GOT16_HA:
- r_symndx = ELF32_R_SYM (rel->r_info);
- if (r_symndx >= symtab_hdr->sh_info)
- {
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- if (h->got.refcount > 0)
- h->got.refcount--;
- }
- else if (local_got_refcounts != NULL)
- {
- if (local_got_refcounts[r_symndx] > 0)
- local_got_refcounts[r_symndx]--;
- }
- break;
-
- case R_PPC_PLT32:
- case R_PPC_PLTREL24:
- case R_PPC_PLT16_LO:
- case R_PPC_PLT16_HI:
- case R_PPC_PLT16_HA:
- r_symndx = ELF32_R_SYM (rel->r_info);
- if (r_symndx >= symtab_hdr->sh_info)
+ {
+ unsigned long r_symndx;
+ enum elf_ppc_reloc_type r_type;
+ struct elf_link_hash_entry *h = NULL;
+
+ r_symndx = ELF32_R_SYM (rel->r_info);
+ if (r_symndx >= symtab_hdr->sh_info)
+ {
+ struct ppc_elf_dyn_relocs **pp, *p;
+ struct ppc_elf_link_hash_entry *eh;
+
+ h = sym_hashes[r_symndx - symtab_hdr->sh_info];
+ eh = (struct ppc_elf_link_hash_entry *) h;
+
+ for (pp = &eh->dyn_relocs; (p = *pp) != NULL; pp = &p->next)
+ if (p->sec == sec)
+ {
+ /* Everything must go for SEC. */
+ *pp = p->next;
+ break;
+ }
+ }
+
+ r_type = ELF32_R_TYPE (rel->r_info);
+ switch (r_type)
+ {
+ case R_PPC_GOT_TLSLD16:
+ case R_PPC_GOT_TLSLD16_LO:
+ case R_PPC_GOT_TLSLD16_HI:
+ case R_PPC_GOT_TLSLD16_HA:
+ htab->tlsld_got.refcount -= 1;
+ /* Fall thru */
+
+ case R_PPC_GOT_TLSGD16:
+ case R_PPC_GOT_TLSGD16_LO:
+ case R_PPC_GOT_TLSGD16_HI:
+ case R_PPC_GOT_TLSGD16_HA:
+ case R_PPC_GOT_TPREL16:
+ case R_PPC_GOT_TPREL16_LO:
+ case R_PPC_GOT_TPREL16_HI:
+ case R_PPC_GOT_TPREL16_HA:
+ case R_PPC_GOT_DTPREL16:
+ case R_PPC_GOT_DTPREL16_LO:
+ case R_PPC_GOT_DTPREL16_HI:
+ case R_PPC_GOT_DTPREL16_HA:
+ case R_PPC_GOT16:
+ case R_PPC_GOT16_LO:
+ case R_PPC_GOT16_HI:
+ case R_PPC_GOT16_HA:
+ if (h != NULL)
+ {
+ if (h->got.refcount > 0)
+ h->got.refcount--;
+ }
+ else if (local_got_refcounts != NULL)
+ {
+ if (local_got_refcounts[r_symndx] > 0)
+ local_got_refcounts[r_symndx]--;
+ }
+ break;
+
+ case R_PPC_REL24:
+ case R_PPC_REL14:
+ case R_PPC_REL14_BRTAKEN:
+ case R_PPC_REL14_BRNTAKEN:
+ case R_PPC_REL32:
+ if (h == NULL
+ || strcmp (h->root.root.string, "_GLOBAL_OFFSET_TABLE_") == 0)
+ break;
+ /* Fall thru */
+
+ case R_PPC_ADDR32:
+ case R_PPC_ADDR24:
+ case R_PPC_ADDR16:
+ case R_PPC_ADDR16_LO:
+ case R_PPC_ADDR16_HI:
+ case R_PPC_ADDR16_HA:
+ case R_PPC_ADDR14:
+ case R_PPC_ADDR14_BRTAKEN:
+ case R_PPC_ADDR14_BRNTAKEN:
+ case R_PPC_UADDR32:
+ case R_PPC_UADDR16:
+ case R_PPC_PLT32:
+ case R_PPC_PLTREL24:
+ case R_PPC_PLT16_LO:
+ case R_PPC_PLT16_HI:
+ case R_PPC_PLT16_HA:
+ if (h != NULL)
+ {
+ if (h->plt.refcount > 0)
+ h->plt.refcount--;
+ }
+ break;
+
+ default:
+ break;
+ }
+ }
+ return TRUE;
+}
+
+/* Set htab->tls_get_addr and call the generic ELF tls_setup function. */
+
+asection *
+ppc_elf_tls_setup (bfd *obfd, struct bfd_link_info *info)
+{
+ struct ppc_elf_link_hash_table *htab;
+
+ htab = ppc_elf_hash_table (info);
+ htab->tls_get_addr = elf_link_hash_lookup (&htab->elf, "__tls_get_addr",
+ FALSE, FALSE, TRUE);
+
+ return _bfd_elf_tls_setup (obfd, info);
+}
+
+/* Run through all the TLS relocs looking for optimization
+ opportunities. */
+
+bfd_boolean
+ppc_elf_tls_optimize (bfd *obfd ATTRIBUTE_UNUSED,
+ struct bfd_link_info *info)
+{
+ bfd *ibfd;
+ asection *sec;
+ struct ppc_elf_link_hash_table *htab;
+
+ if (info->relocatable || info->shared)
+ return TRUE;
+
+ htab = ppc_elf_hash_table (info);
+ for (ibfd = info->input_bfds; ibfd != NULL; ibfd = ibfd->link_next)
+ {
+ Elf_Internal_Sym *locsyms = NULL;
+ Elf_Internal_Shdr *symtab_hdr = &elf_tdata (ibfd)->symtab_hdr;
+
+ for (sec = ibfd->sections; sec != NULL; sec = sec->next)
+ if (sec->has_tls_reloc && !bfd_is_abs_section (sec->output_section))
{
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- if (h->plt.refcount > 0)
- h->plt.refcount--;
- }
- break;
+ Elf_Internal_Rela *relstart, *rel, *relend;
+ int expecting_tls_get_addr;
+
+ /* Read the relocations. */
+ relstart = _bfd_elf_link_read_relocs (ibfd, sec, NULL, NULL,
+ info->keep_memory);
+ if (relstart == NULL)
+ return FALSE;
+
+ expecting_tls_get_addr = 0;
+ relend = relstart + sec->reloc_count;
+ for (rel = relstart; rel < relend; rel++)
+ {
+ enum elf_ppc_reloc_type r_type;
+ unsigned long r_symndx;
+ struct elf_link_hash_entry *h = NULL;
+ char *tls_mask;
+ char tls_set, tls_clear;
+ bfd_boolean is_local;
+
+ r_symndx = ELF32_R_SYM (rel->r_info);
+ if (r_symndx >= symtab_hdr->sh_info)
+ {
+ struct elf_link_hash_entry **sym_hashes;
+
+ sym_hashes = elf_sym_hashes (ibfd);
+ h = sym_hashes[r_symndx - symtab_hdr->sh_info];
+ while (h->root.type == bfd_link_hash_indirect
+ || h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+ }
+
+ is_local = FALSE;
+ if (h == NULL
+ || !(h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC))
+ is_local = TRUE;
+
+ r_type = ELF32_R_TYPE (rel->r_info);
+ switch (r_type)
+ {
+ case R_PPC_GOT_TLSLD16:
+ case R_PPC_GOT_TLSLD16_LO:
+ case R_PPC_GOT_TLSLD16_HI:
+ case R_PPC_GOT_TLSLD16_HA:
+ /* These relocs should never be against a symbol
+ defined in a shared lib. Leave them alone if
+ that turns out to be the case. */
+ expecting_tls_get_addr = 0;
+ htab->tlsld_got.refcount -= 1;
+ if (!is_local)
+ continue;
+
+ /* LD -> LE */
+ tls_set = 0;
+ tls_clear = TLS_LD;
+ expecting_tls_get_addr = 1;
+ break;
+
+ case R_PPC_GOT_TLSGD16:
+ case R_PPC_GOT_TLSGD16_LO:
+ case R_PPC_GOT_TLSGD16_HI:
+ case R_PPC_GOT_TLSGD16_HA:
+ if (is_local)
+ /* GD -> LE */
+ tls_set = 0;
+ else
+ /* GD -> IE */
+ tls_set = TLS_TLS | TLS_TPRELGD;
+ tls_clear = TLS_GD;
+ expecting_tls_get_addr = 1;
+ break;
+
+ case R_PPC_GOT_TPREL16:
+ case R_PPC_GOT_TPREL16_LO:
+ case R_PPC_GOT_TPREL16_HI:
+ case R_PPC_GOT_TPREL16_HA:
+ expecting_tls_get_addr = 0;
+ if (is_local)
+ {
+ /* IE -> LE */
+ tls_set = 0;
+ tls_clear = TLS_TPREL;
+ break;
+ }
+ else
+ continue;
+
+ case R_PPC_REL14:
+ case R_PPC_REL14_BRTAKEN:
+ case R_PPC_REL14_BRNTAKEN:
+ case R_PPC_REL24:
+ if (expecting_tls_get_addr
+ && h != NULL
+ && h == htab->tls_get_addr)
+ {
+ if (h->plt.refcount > 0)
+ h->plt.refcount -= 1;
+ }
+ expecting_tls_get_addr = 0;
+ continue;
+
+ default:
+ expecting_tls_get_addr = 0;
+ continue;
+ }
+
+ if (h != NULL)
+ {
+ if (tls_set == 0)
+ {
+ /* We managed to get rid of a got entry. */
+ if (h->got.refcount > 0)
+ h->got.refcount -= 1;
+ }
+ tls_mask = &ppc_elf_hash_entry (h)->tls_mask;
+ }
+ else
+ {
+ Elf_Internal_Sym *sym;
+ bfd_signed_vma *lgot_refs;
+ char *lgot_masks;
+
+ if (locsyms == NULL)
+ {
+ locsyms = (Elf_Internal_Sym *) symtab_hdr->contents;
+ if (locsyms == NULL)
+ locsyms = bfd_elf_get_elf_syms (ibfd, symtab_hdr,
+ symtab_hdr->sh_info,
+ 0, NULL, NULL, NULL);
+ if (locsyms == NULL)
+ {
+ if (elf_section_data (sec)->relocs != relstart)
+ free (relstart);
+ return FALSE;
+ }
+ }
+ sym = locsyms + r_symndx;
+ lgot_refs = elf_local_got_refcounts (ibfd);
+ if (lgot_refs == NULL)
+ abort ();
+ if (tls_set == 0)
+ {
+ /* We managed to get rid of a got entry. */
+ if (lgot_refs[r_symndx] > 0)
+ lgot_refs[r_symndx] -= 1;
+ }
+ lgot_masks = (char *) (lgot_refs + symtab_hdr->sh_info);
+ tls_mask = &lgot_masks[r_symndx];
+ }
+
+ *tls_mask |= tls_set;
+ *tls_mask &= ~tls_clear;
+ }
- default:
- break;
- }
+ if (elf_section_data (sec)->relocs != relstart)
+ free (relstart);
+ }
- return true;
+ if (locsyms != NULL
+ && (symtab_hdr->contents != (unsigned char *) locsyms))
+ {
+ if (!info->keep_memory)
+ free (locsyms);
+ else
+ symtab_hdr->contents = (unsigned char *) locsyms;
+ }
+ }
+ return TRUE;
}
/* Hook called by the linker routine which adds symbols from an object
file. We use it to put .comm items in .sbss, and not .bss. */
-static boolean
-ppc_elf_add_symbol_hook (abfd, info, sym, namep, flagsp, secp, valp)
- bfd *abfd;
- struct bfd_link_info *info;
- const Elf_Internal_Sym *sym;
- const char **namep ATTRIBUTE_UNUSED;
- flagword *flagsp ATTRIBUTE_UNUSED;
- asection **secp;
- bfd_vma *valp;
+static bfd_boolean
+ppc_elf_add_symbol_hook (bfd *abfd,
+ struct bfd_link_info *info,
+ Elf_Internal_Sym *sym,
+ const char **namep ATTRIBUTE_UNUSED,
+ flagword *flagsp ATTRIBUTE_UNUSED,
+ asection **secp,
+ bfd_vma *valp)
{
if (sym->st_shndx == SHN_COMMON
- && !info->relocateable
+ && !info->relocatable
&& sym->st_size <= elf_gp_size (abfd)
- && info->hash->creator->flavour == bfd_target_elf_flavour)
+ && (info->hash->creator == abfd->xvec
+ || info->hash->creator == abfd->xvec->alternative_target))
{
/* Common symbols less than or equal to -G nn bytes are automatically
- put into .sdata. */
- elf_linker_section_t *sdata
- = ppc_elf_create_linker_section (abfd, info, LINKER_SECTION_SDATA);
-
- if (!sdata->bss_section)
- {
- bfd_size_type amt;
-
- /* We don't go through bfd_make_section, because we don't
- want to attach this common section to DYNOBJ. The linker
- will move the symbols to the appropriate output section
- when it defines common symbols. */
- amt = sizeof (asection);
- sdata->bss_section = (asection *) bfd_zalloc (abfd, amt);
- if (sdata->bss_section == NULL)
- return false;
- sdata->bss_section->name = sdata->bss_name;
- sdata->bss_section->flags = SEC_IS_COMMON;
- sdata->bss_section->output_section = sdata->bss_section;
- amt = sizeof (asymbol);
- sdata->bss_section->symbol = (asymbol *) bfd_zalloc (abfd, amt);
- amt = sizeof (asymbol *);
- sdata->bss_section->symbol_ptr_ptr =
- (asymbol **) bfd_zalloc (abfd, amt);
- if (sdata->bss_section->symbol == NULL
- || sdata->bss_section->symbol_ptr_ptr == NULL)
- return false;
- sdata->bss_section->symbol->name = sdata->bss_name;
- sdata->bss_section->symbol->flags = BSF_SECTION_SYM;
- sdata->bss_section->symbol->section = sdata->bss_section;
- *sdata->bss_section->symbol_ptr_ptr = sdata->bss_section->symbol;
- }
-
- *secp = sdata->bss_section;
+ put into .sbss. */
+ struct ppc_elf_link_hash_table *htab;
+
+ htab = ppc_elf_hash_table (info);
+ if (htab->sbss == NULL)
+ {
+ flagword flags = SEC_IS_COMMON;
+
+ htab->sbss = bfd_make_section_anyway (abfd, ".sbss");
+ if (htab->sbss == NULL
+ || ! bfd_set_section_flags (abfd, htab->sbss, flags))
+ return FALSE;
+ }
+
+ *secp = htab->sbss;
*valp = sym->st_size;
}
- return true;
+ return TRUE;
}
/* Finish up dynamic symbol handling. We set the contents of various
dynamic sections here. */
-static boolean
-ppc_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
- bfd *output_bfd;
- struct bfd_link_info *info;
- struct elf_link_hash_entry *h;
- Elf_Internal_Sym *sym;
+static bfd_boolean
+ppc_elf_finish_dynamic_symbol (bfd *output_bfd,
+ struct bfd_link_info *info,
+ struct elf_link_hash_entry *h,
+ Elf_Internal_Sym *sym)
{
- bfd *dynobj;
+ struct ppc_elf_link_hash_table *htab;
#ifdef DEBUG
fprintf (stderr, "ppc_elf_finish_dynamic_symbol called for %s",
h->root.root.string);
#endif
- dynobj = elf_hash_table (info)->dynobj;
- BFD_ASSERT (dynobj != NULL);
+ htab = ppc_elf_hash_table (info);
+ BFD_ASSERT (htab->elf.dynobj != NULL);
if (h->plt.offset != (bfd_vma) -1)
{
- asection *splt;
- asection *srela;
Elf_Internal_Rela rela;
+ bfd_byte *loc;
bfd_vma reloc_index;
#ifdef DEBUG
@@ -2671,20 +4429,17 @@ ppc_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
#endif
/* This symbol has an entry in the procedure linkage table. Set
- it up. */
+ it up. */
BFD_ASSERT (h->dynindx != -1);
-
- splt = bfd_get_section_by_name (dynobj, ".plt");
- srela = bfd_get_section_by_name (dynobj, ".rela.plt");
- BFD_ASSERT (splt != NULL && srela != NULL);
+ BFD_ASSERT (htab->plt != NULL && htab->relplt != NULL);
/* We don't need to fill in the .plt. The ppc dynamic linker
will fill it in. */
/* Fill in the entry in the .rela.plt section. */
- rela.r_offset = (splt->output_section->vma
- + splt->output_offset
+ rela.r_offset = (htab->plt->output_section->vma
+ + htab->plt->output_offset
+ h->plt.offset);
rela.r_info = ELF32_R_INFO (h->dynindx, R_PPC_JMP_SLOT);
rela.r_addend = 0;
@@ -2692,9 +4447,9 @@ ppc_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
reloc_index = (h->plt.offset - PLT_INITIAL_ENTRY_SIZE) / PLT_SLOT_SIZE;
if (reloc_index > PLT_NUM_SINGLE_ENTRIES)
reloc_index -= (reloc_index - PLT_NUM_SINGLE_ENTRIES) / 2;
- bfd_elf32_swap_reloca_out (output_bfd, &rela,
- ((Elf32_External_Rela *) srela->contents
- + reloc_index));
+ loc = (htab->relplt->contents
+ + reloc_index * sizeof (Elf32_External_Rela));
+ bfd_elf32_swap_reloca_out (output_bfd, &rela, loc);
if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
{
@@ -2711,53 +4466,11 @@ ppc_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
}
}
- if (h->got.offset != (bfd_vma) -1)
- {
- asection *sgot;
- asection *srela;
- Elf_Internal_Rela rela;
-
- /* This symbol has an entry in the global offset table. Set it
- up. */
-
- sgot = bfd_get_section_by_name (dynobj, ".got");
- srela = bfd_get_section_by_name (dynobj, ".rela.got");
- BFD_ASSERT (sgot != NULL && srela != NULL);
-
- rela.r_offset = (sgot->output_section->vma
- + sgot->output_offset
- + (h->got.offset &~ (bfd_vma) 1));
-
- /* If this is a -Bsymbolic link, and the symbol is defined
- locally, we just want to emit a RELATIVE reloc. The entry in
- the global offset table will already have been initialized in
- the relocate_section function. */
- if (info->shared
- && SYMBOL_REFERENCES_LOCAL (info, h))
- {
- rela.r_info = ELF32_R_INFO (0, R_PPC_RELATIVE);
- rela.r_addend = (h->root.u.def.value
- + h->root.u.def.section->output_section->vma
- + h->root.u.def.section->output_offset);
- }
- else
- {
- BFD_ASSERT ((h->got.offset & 1) == 0);
- rela.r_info = ELF32_R_INFO (h->dynindx, R_PPC_GLOB_DAT);
- rela.r_addend = 0;
- }
-
- bfd_put_32 (output_bfd, (bfd_vma) 0, sgot->contents + h->got.offset);
- bfd_elf32_swap_reloca_out (output_bfd, &rela,
- ((Elf32_External_Rela *) srela->contents
- + srela->reloc_count));
- ++srela->reloc_count;
- }
-
if ((h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_COPY) != 0)
{
asection *s;
Elf_Internal_Rela rela;
+ bfd_byte *loc;
/* This symbols needs a copy reloc. Set it up. */
@@ -2767,12 +4480,10 @@ ppc_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
BFD_ASSERT (h->dynindx != -1);
- if (h->size <= elf_gp_size (dynobj))
- s = bfd_get_section_by_name (h->root.u.def.section->owner,
- ".rela.sbss");
+ if (h->size <= elf_gp_size (htab->elf.dynobj))
+ s = htab->relsbss;
else
- s = bfd_get_section_by_name (h->root.u.def.section->owner,
- ".rela.bss");
+ s = htab->relbss;
BFD_ASSERT (s != NULL);
rela.r_offset = (h->root.u.def.value
@@ -2780,10 +4491,8 @@ ppc_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
+ h->root.u.def.section->output_offset);
rela.r_info = ELF32_R_INFO (h->dynindx, R_PPC_COPY);
rela.r_addend = 0;
- bfd_elf32_swap_reloca_out (output_bfd, &rela,
- ((Elf32_External_Rela *) s->contents
- + s->reloc_count));
- ++s->reloc_count;
+ loc = s->contents + s->reloc_count++ * sizeof (Elf32_External_Rela);
+ bfd_elf32_swap_reloca_out (output_bfd, &rela, loc);
}
#ifdef DEBUG
@@ -2796,94 +4505,82 @@ ppc_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
|| strcmp (h->root.root.string, "_PROCEDURE_LINKAGE_TABLE_") == 0)
sym->st_shndx = SHN_ABS;
- return true;
+ return TRUE;
}
/* Finish up the dynamic sections. */
-static boolean
-ppc_elf_finish_dynamic_sections (output_bfd, info)
- bfd *output_bfd;
- struct bfd_link_info *info;
+static bfd_boolean
+ppc_elf_finish_dynamic_sections (bfd *output_bfd,
+ struct bfd_link_info *info)
{
asection *sdyn;
- bfd *dynobj = elf_hash_table (info)->dynobj;
- asection *sgot = bfd_get_section_by_name (dynobj, ".got");
+ struct ppc_elf_link_hash_table *htab;
#ifdef DEBUG
fprintf (stderr, "ppc_elf_finish_dynamic_sections called\n");
#endif
- sdyn = bfd_get_section_by_name (dynobj, ".dynamic");
+ htab = ppc_elf_hash_table (info);
+ sdyn = bfd_get_section_by_name (htab->elf.dynobj, ".dynamic");
- if (elf_hash_table (info)->dynamic_sections_created)
+ if (htab->elf.dynamic_sections_created)
{
- asection *splt;
Elf32_External_Dyn *dyncon, *dynconend;
- splt = bfd_get_section_by_name (dynobj, ".plt");
- BFD_ASSERT (splt != NULL && sdyn != NULL);
+ BFD_ASSERT (htab->plt != NULL && sdyn != NULL);
dyncon = (Elf32_External_Dyn *) sdyn->contents;
dynconend = (Elf32_External_Dyn *) (sdyn->contents + sdyn->_raw_size);
for (; dyncon < dynconend; dyncon++)
{
Elf_Internal_Dyn dyn;
- const char *name;
- boolean size;
+ asection *s;
- bfd_elf32_swap_dyn_in (dynobj, dyncon, &dyn);
+ bfd_elf32_swap_dyn_in (htab->elf.dynobj, dyncon, &dyn);
switch (dyn.d_tag)
{
- case DT_PLTGOT: name = ".plt"; size = false; break;
- case DT_PLTRELSZ: name = ".rela.plt"; size = true; break;
- case DT_JMPREL: name = ".rela.plt"; size = false; break;
- default: name = NULL; size = false; break;
- }
+ case DT_PLTGOT:
+ s = htab->plt;
+ dyn.d_un.d_ptr = s->output_section->vma + s->output_offset;
+ break;
- if (name != NULL)
- {
- asection *s;
+ case DT_PLTRELSZ:
+ dyn.d_un.d_val = htab->relplt->_raw_size;
+ break;
- s = bfd_get_section_by_name (output_bfd, name);
- if (s == NULL)
- dyn.d_un.d_val = 0;
- else
- {
- if (! size)
- dyn.d_un.d_ptr = s->vma;
- else
- {
- if (s->_cooked_size != 0)
- dyn.d_un.d_val = s->_cooked_size;
- else
- dyn.d_un.d_val = s->_raw_size;
- }
- }
- bfd_elf32_swap_dyn_out (output_bfd, &dyn, dyncon);
+ case DT_JMPREL:
+ s = htab->relplt;
+ dyn.d_un.d_ptr = s->output_section->vma + s->output_offset;
+ break;
+
+ default:
+ continue;
}
+
+ bfd_elf32_swap_dyn_out (output_bfd, &dyn, dyncon);
}
}
/* Add a blrl instruction at _GLOBAL_OFFSET_TABLE_-4 so that a function can
easily find the address of the _GLOBAL_OFFSET_TABLE_. */
- if (sgot)
+ if (htab->got)
{
- unsigned char *contents = sgot->contents;
- bfd_put_32 (output_bfd, (bfd_vma) 0x4e800021 /* blrl */, contents);
+ unsigned char *contents = htab->got->contents;
+ bfd_put_32 (output_bfd, 0x4e800021 /* blrl */, contents);
if (sdyn == NULL)
- bfd_put_32 (output_bfd, (bfd_vma) 0, contents+4);
+ bfd_put_32 (output_bfd, 0, contents + 4);
else
bfd_put_32 (output_bfd,
sdyn->output_section->vma + sdyn->output_offset,
- contents+4);
+ contents + 4);
- elf_section_data (sgot->output_section)->this_hdr.sh_entsize = 4;
+ elf_section_data (htab->got->output_section)->this_hdr.sh_entsize = 4;
}
- return true;
+ return TRUE;
}
/* The RELOCATE_SECTION function is called by the ELF backend linker
@@ -2895,7 +4592,7 @@ ppc_elf_finish_dynamic_sections (output_bfd, info)
This function is responsible for adjust the section contents as
necessary, and (if using Rela relocs and generating a
- relocateable output file) adjusting the reloc addend as
+ relocatable output file) adjusting the reloc addend as
necessary.
This function does not have to worry about setting the reloc
@@ -2909,289 +4606,711 @@ ppc_elf_finish_dynamic_sections (output_bfd, info)
The global hash table entry for the global symbols can be found
via elf_sym_hashes (input_bfd).
- When generating relocateable output, this function must handle
+ When generating relocatable output, this function must handle
STB_LOCAL/STT_SECTION symbols specially. The output symbol is
going to be the section symbol corresponding to the output
section, which means that the addend must be adjusted
accordingly. */
-static boolean
-ppc_elf_relocate_section (output_bfd, info, input_bfd, input_section,
- contents, relocs, local_syms, local_sections)
- bfd *output_bfd;
- struct bfd_link_info *info;
- bfd *input_bfd;
- asection *input_section;
- bfd_byte *contents;
- Elf_Internal_Rela *relocs;
- Elf_Internal_Sym *local_syms;
- asection **local_sections;
+static bfd_boolean
+ppc_elf_relocate_section (bfd *output_bfd,
+ struct bfd_link_info *info,
+ bfd *input_bfd,
+ asection *input_section,
+ bfd_byte *contents,
+ Elf_Internal_Rela *relocs,
+ Elf_Internal_Sym *local_syms,
+ asection **local_sections)
{
- Elf_Internal_Shdr *symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
- struct elf_link_hash_entry **sym_hashes = elf_sym_hashes (input_bfd);
- bfd *dynobj = elf_hash_table (info)->dynobj;
- elf_linker_section_t *sdata = (dynobj) ? elf_linker_section (dynobj, LINKER_SECTION_SDATA) : NULL;
- elf_linker_section_t *sdata2 = (dynobj) ? elf_linker_section (dynobj, LINKER_SECTION_SDATA2) : NULL;
- Elf_Internal_Rela *rel = relocs;
- Elf_Internal_Rela *relend = relocs + input_section->reloc_count;
- asection *sreloc = NULL;
- asection *splt;
- asection *sgot;
+ Elf_Internal_Shdr *symtab_hdr;
+ struct elf_link_hash_entry **sym_hashes;
+ struct ppc_elf_link_hash_table *htab;
+ Elf_Internal_Rela *rel;
+ Elf_Internal_Rela *relend;
+ Elf_Internal_Rela outrel;
+ bfd_byte *loc;
+ asection *sreloc = NULL;
bfd_vma *local_got_offsets;
- boolean ret = true;
- long insn;
+ bfd_boolean ret = TRUE;
#ifdef DEBUG
- fprintf (stderr, "ppc_elf_relocate_section called for %s section %s, %ld relocations%s\n",
+ fprintf (stderr, "ppc_elf_relocate_section called for %s section %s, "
+ "%ld relocations%s\n",
bfd_archive_filename (input_bfd),
bfd_section_name(input_bfd, input_section),
(long) input_section->reloc_count,
- (info->relocateable) ? " (relocatable)" : "");
+ (info->relocatable) ? " (relocatable)" : "");
#endif
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
+ /* Initialize howto table if not already done. */
if (!ppc_elf_howto_table[R_PPC_ADDR32])
- /* Initialize howto table if needed. */
ppc_elf_howto_init ();
+ htab = ppc_elf_hash_table (info);
local_got_offsets = elf_local_got_offsets (input_bfd);
-
- splt = sgot = NULL;
- if (dynobj != NULL)
- {
- splt = bfd_get_section_by_name (dynobj, ".plt");
- sgot = bfd_get_section_by_name (dynobj, ".got");
- }
-
+ symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
+ sym_hashes = elf_sym_hashes (input_bfd);
+ rel = relocs;
+ relend = relocs + input_section->reloc_count;
for (; rel < relend; rel++)
{
- enum elf_ppc_reloc_type r_type = (enum elf_ppc_reloc_type)ELF32_R_TYPE (rel->r_info);
- bfd_vma offset = rel->r_offset;
- bfd_vma addend = rel->r_addend;
- bfd_reloc_status_type r = bfd_reloc_other;
- Elf_Internal_Sym *sym = (Elf_Internal_Sym *) 0;
- asection *sec = (asection *) 0;
- struct elf_link_hash_entry *h = (struct elf_link_hash_entry *) 0;
- const char *sym_name = (const char *) 0;
+ enum elf_ppc_reloc_type r_type;
+ bfd_vma addend;
+ bfd_reloc_status_type r;
+ Elf_Internal_Sym *sym;
+ asection *sec;
+ struct elf_link_hash_entry *h;
+ const char *sym_name;
reloc_howto_type *howto;
unsigned long r_symndx;
bfd_vma relocation;
- int will_become_local;
-
- /* Unknown relocation handling */
- if ((unsigned) r_type >= (unsigned) R_PPC_max
- || !ppc_elf_howto_table[(int) r_type])
- {
- (*_bfd_error_handler) (_("%s: unknown relocation type %d"),
- bfd_archive_filename (input_bfd),
- (int) r_type);
-
- bfd_set_error (bfd_error_bad_value);
- ret = false;
- continue;
- }
-
- howto = ppc_elf_howto_table[(int) r_type];
+ bfd_vma branch_bit, insn, from;
+ bfd_boolean unresolved_reloc;
+ bfd_boolean warned;
+ unsigned int tls_type, tls_mask, tls_gd;
+
+ r_type = ELF32_R_TYPE (rel->r_info);
+ sym = NULL;
+ sec = NULL;
+ h = NULL;
+ unresolved_reloc = FALSE;
+ warned = FALSE;
r_symndx = ELF32_R_SYM (rel->r_info);
if (r_symndx < symtab_hdr->sh_info)
{
sym = local_syms + r_symndx;
sec = local_sections[r_symndx];
- sym_name = "<local symbol>";
+ sym_name = bfd_elf_local_sym_name (input_bfd, sym);
- relocation = _bfd_elf_rela_local_sym (output_bfd, sym, sec, rel);
- addend = rel->r_addend;
- /* Relocs to local symbols are always resolved. */
- will_become_local = 1;
+ relocation = _bfd_elf_rela_local_sym (output_bfd, sym, &sec, rel);
}
else
{
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- while (h->root.type == bfd_link_hash_indirect
- || h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
+ RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
+ r_symndx, symtab_hdr, sym_hashes,
+ h, sec, relocation,
+ unresolved_reloc, warned);
+
sym_name = h->root.root.string;
+ }
- /* Can this relocation be resolved immediately? */
- will_become_local = SYMBOL_REFERENCES_LOCAL (info, h);
+ /* TLS optimizations. Replace instruction sequences and relocs
+ based on information we collected in tls_optimize. We edit
+ RELOCS so that --emit-relocs will output something sensible
+ for the final instruction stream. */
+ tls_mask = 0;
+ tls_gd = 0;
+ if (IS_PPC_TLS_RELOC (r_type))
+ {
+ if (h != NULL)
+ tls_mask = ((struct ppc_elf_link_hash_entry *) h)->tls_mask;
+ else if (local_got_offsets != NULL)
+ {
+ char *lgot_masks;
+ lgot_masks = (char *) (local_got_offsets + symtab_hdr->sh_info);
+ tls_mask = lgot_masks[r_symndx];
+ }
+ }
- if (h->root.type == bfd_link_hash_defined
- || h->root.type == bfd_link_hash_defweak)
+ /* Ensure reloc mapping code below stays sane. */
+ if ((R_PPC_GOT_TLSLD16 & 3) != (R_PPC_GOT_TLSGD16 & 3)
+ || (R_PPC_GOT_TLSLD16_LO & 3) != (R_PPC_GOT_TLSGD16_LO & 3)
+ || (R_PPC_GOT_TLSLD16_HI & 3) != (R_PPC_GOT_TLSGD16_HI & 3)
+ || (R_PPC_GOT_TLSLD16_HA & 3) != (R_PPC_GOT_TLSGD16_HA & 3)
+ || (R_PPC_GOT_TLSLD16 & 3) != (R_PPC_GOT_TPREL16 & 3)
+ || (R_PPC_GOT_TLSLD16_LO & 3) != (R_PPC_GOT_TPREL16_LO & 3)
+ || (R_PPC_GOT_TLSLD16_HI & 3) != (R_PPC_GOT_TPREL16_HI & 3)
+ || (R_PPC_GOT_TLSLD16_HA & 3) != (R_PPC_GOT_TPREL16_HA & 3))
+ abort ();
+ switch (r_type)
+ {
+ default:
+ break;
+
+ case R_PPC_GOT_TPREL16:
+ case R_PPC_GOT_TPREL16_LO:
+ if (tls_mask != 0
+ && (tls_mask & TLS_TPREL) == 0)
{
- sec = h->root.u.def.section;
- if (((r_type == R_PPC_PLT32
- || r_type == R_PPC_PLTREL24)
- && splt != NULL
- && h->plt.offset != (bfd_vma) -1)
- || (r_type == R_PPC_LOCAL24PC
- && sec->output_section == NULL)
- || ((r_type == R_PPC_GOT16
- || r_type == R_PPC_GOT16_LO
- || r_type == R_PPC_GOT16_HI
- || r_type == R_PPC_GOT16_HA)
- && elf_hash_table (info)->dynamic_sections_created
- && (! info->shared || ! will_become_local))
- || (info->shared
- && ! will_become_local
- && ((input_section->flags & SEC_ALLOC) != 0
- /* Testing SEC_DEBUGGING here may be wrong.
- It's here to avoid a crash when
- generating a shared library with DWARF
- debugging information. */
- || ((input_section->flags & SEC_DEBUGGING) != 0
- && (h->elf_link_hash_flags
- & ELF_LINK_HASH_DEF_DYNAMIC) != 0))
- && (r_type == R_PPC_ADDR32
- || r_type == R_PPC_ADDR24
- || r_type == R_PPC_ADDR16
- || r_type == R_PPC_ADDR16_LO
- || r_type == R_PPC_ADDR16_HI
- || r_type == R_PPC_ADDR16_HA
- || r_type == R_PPC_ADDR14
- || r_type == R_PPC_ADDR14_BRTAKEN
- || r_type == R_PPC_ADDR14_BRNTAKEN
- || r_type == R_PPC_COPY
- || r_type == R_PPC_GLOB_DAT
- || r_type == R_PPC_JMP_SLOT
- || r_type == R_PPC_UADDR32
- || r_type == R_PPC_UADDR16
- || r_type == R_PPC_SDAREL16
- || r_type == R_PPC_EMB_NADDR32
- || r_type == R_PPC_EMB_NADDR16
- || r_type == R_PPC_EMB_NADDR16_LO
- || r_type == R_PPC_EMB_NADDR16_HI
- || r_type == R_PPC_EMB_NADDR16_HA
- || r_type == R_PPC_EMB_SDAI16
- || r_type == R_PPC_EMB_SDA2I16
- || r_type == R_PPC_EMB_SDA2REL
- || r_type == R_PPC_EMB_SDA21
- || r_type == R_PPC_EMB_MRKREF
- || r_type == R_PPC_EMB_BIT_FLD
- || r_type == R_PPC_EMB_RELSDA
- || ((r_type == R_PPC_REL24
- || r_type == R_PPC_REL32
- || r_type == R_PPC_REL14
- || r_type == R_PPC_REL14_BRTAKEN
- || r_type == R_PPC_REL14_BRNTAKEN
- || r_type == R_PPC_RELATIVE)
- && strcmp (h->root.root.string,
- "_GLOBAL_OFFSET_TABLE_") != 0))))
- {
- /* In these cases, we don't need the relocation
- value. We check specially because in some
- obscure cases sec->output_section will be NULL. */
- relocation = 0;
- }
- else if (sec->output_section == NULL)
+ bfd_vma insn;
+ insn = bfd_get_32 (output_bfd, contents + rel->r_offset - 2);
+ insn &= 31 << 21;
+ insn |= 0x3c020000; /* addis 0,2,0 */
+ bfd_put_32 (output_bfd, insn, contents + rel->r_offset - 2);
+ r_type = R_PPC_TPREL16_HA;
+ rel->r_info = ELF32_R_INFO (r_symndx, r_type);
+ }
+ break;
+
+ case R_PPC_TLS:
+ if (tls_mask != 0
+ && (tls_mask & TLS_TPREL) == 0)
+ {
+ bfd_vma insn, rtra;
+ insn = bfd_get_32 (output_bfd, contents + rel->r_offset);
+ if ((insn & ((31 << 26) | (31 << 11)))
+ == ((31 << 26) | (2 << 11)))
+ rtra = insn & ((1 << 26) - (1 << 16));
+ else if ((insn & ((31 << 26) | (31 << 16)))
+ == ((31 << 26) | (2 << 16)))
+ rtra = (insn & (31 << 21)) | ((insn & (31 << 11)) << 5);
+ else
+ abort ();
+ if ((insn & ((1 << 11) - (1 << 1))) == 266 << 1)
+ /* add -> addi. */
+ insn = 14 << 26;
+ else if ((insn & (31 << 1)) == 23 << 1
+ && ((insn & (31 << 6)) < 14 << 6
+ || ((insn & (31 << 6)) >= 16 << 6
+ && (insn & (31 << 6)) < 24 << 6)))
+ /* load and store indexed -> dform. */
+ insn = (32 | ((insn >> 6) & 31)) << 26;
+ else if ((insn & (31 << 1)) == 21 << 1
+ && (insn & (0x1a << 6)) == 0)
+ /* ldx, ldux, stdx, stdux -> ld, ldu, std, stdu. */
+ insn = (((58 | ((insn >> 6) & 4)) << 26)
+ | ((insn >> 6) & 1));
+ else if ((insn & (31 << 1)) == 21 << 1
+ && (insn & ((1 << 11) - (1 << 1))) == 341 << 1)
+ /* lwax -> lwa. */
+ insn = (58 << 26) | 2;
+ else
+ abort ();
+ insn |= rtra;
+ bfd_put_32 (output_bfd, insn, contents + rel->r_offset);
+ r_type = R_PPC_TPREL16_LO;
+ rel->r_info = ELF32_R_INFO (r_symndx, r_type);
+ /* Was PPC_TLS which sits on insn boundary, now
+ PPC_TPREL16_LO which is at insn+2. */
+ rel->r_offset += 2;
+ }
+ break;
+
+ case R_PPC_GOT_TLSGD16_HI:
+ case R_PPC_GOT_TLSGD16_HA:
+ tls_gd = TLS_TPRELGD;
+ if (tls_mask != 0 && (tls_mask & TLS_GD) == 0)
+ goto tls_gdld_hi;
+ break;
+
+ case R_PPC_GOT_TLSLD16_HI:
+ case R_PPC_GOT_TLSLD16_HA:
+ if (tls_mask != 0 && (tls_mask & TLS_LD) == 0)
+ {
+ tls_gdld_hi:
+ if ((tls_mask & tls_gd) != 0)
+ r_type = (((r_type - (R_PPC_GOT_TLSGD16 & 3)) & 3)
+ + R_PPC_GOT_TPREL16);
+ else
{
- (*_bfd_error_handler)
- (_("%s: warning: unresolvable relocation against symbol `%s' from %s section"),
- bfd_archive_filename (input_bfd), h->root.root.string,
- bfd_get_section_name (input_bfd, input_section));
- relocation = 0;
+ bfd_put_32 (output_bfd, NOP, contents + rel->r_offset);
+ rel->r_offset -= 2;
+ r_type = R_PPC_NONE;
}
- else
- relocation = (h->root.u.def.value
- + sec->output_section->vma
- + sec->output_offset);
+ rel->r_info = ELF32_R_INFO (r_symndx, r_type);
}
- else if (h->root.type == bfd_link_hash_undefweak)
- relocation = 0;
- else if (info->shared
- && (!info->symbolic || info->allow_shlib_undefined)
- && !info->no_undefined
- && ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
- relocation = 0;
- else
+ break;
+
+ case R_PPC_GOT_TLSGD16:
+ case R_PPC_GOT_TLSGD16_LO:
+ tls_gd = TLS_TPRELGD;
+ if (tls_mask != 0 && (tls_mask & TLS_GD) == 0)
+ goto tls_get_addr_check;
+ break;
+
+ case R_PPC_GOT_TLSLD16:
+ case R_PPC_GOT_TLSLD16_LO:
+ if (tls_mask != 0 && (tls_mask & TLS_LD) == 0)
{
- if (! (*info->callbacks->undefined_symbol) (info,
- h->root.root.string,
- input_bfd,
- input_section,
- rel->r_offset,
- (!info->shared
- || info->no_undefined
- || ELF_ST_VISIBILITY (h->other))))
- return false;
- relocation = 0;
+ tls_get_addr_check:
+ if (rel + 1 < relend)
+ {
+ enum elf_ppc_reloc_type r_type2;
+ unsigned long r_symndx2;
+ struct elf_link_hash_entry *h2;
+ bfd_vma insn1, insn2;
+ bfd_vma offset;
+
+ /* The next instruction should be a call to
+ __tls_get_addr. Peek at the reloc to be sure. */
+ r_type2 = ELF32_R_TYPE (rel[1].r_info);
+ r_symndx2 = ELF32_R_SYM (rel[1].r_info);
+ if (r_symndx2 < symtab_hdr->sh_info
+ || (r_type2 != R_PPC_REL14
+ && r_type2 != R_PPC_REL14_BRTAKEN
+ && r_type2 != R_PPC_REL14_BRNTAKEN
+ && r_type2 != R_PPC_REL24
+ && r_type2 != R_PPC_PLTREL24))
+ break;
+
+ h2 = sym_hashes[r_symndx2 - symtab_hdr->sh_info];
+ while (h2->root.type == bfd_link_hash_indirect
+ || h2->root.type == bfd_link_hash_warning)
+ h2 = (struct elf_link_hash_entry *) h2->root.u.i.link;
+ if (h2 == NULL || h2 != htab->tls_get_addr)
+ break;
+
+ /* OK, it checks out. Replace the call. */
+ offset = rel[1].r_offset;
+ insn1 = bfd_get_32 (output_bfd,
+ contents + rel->r_offset - 2);
+ if ((tls_mask & tls_gd) != 0)
+ {
+ /* IE */
+ insn1 &= (1 << 26) - 1;
+ insn1 |= 32 << 26; /* lwz */
+ insn2 = 0x7c631214; /* add 3,3,2 */
+ rel[1].r_info = ELF32_R_INFO (r_symndx2, R_PPC_NONE);
+ r_type = (((r_type - (R_PPC_GOT_TLSGD16 & 3)) & 3)
+ + R_PPC_GOT_TPREL16);
+ rel->r_info = ELF32_R_INFO (r_symndx, r_type);
+ }
+ else
+ {
+ /* LE */
+ insn1 = 0x3c620000; /* addis 3,2,0 */
+ insn2 = 0x38630000; /* addi 3,3,0 */
+ if (tls_gd == 0)
+ {
+ /* Was an LD reloc. */
+ r_symndx = 0;
+ rel->r_addend = htab->elf.tls_sec->vma + DTP_OFFSET;
+ rel[1].r_addend = htab->elf.tls_sec->vma + DTP_OFFSET;
+ }
+ r_type = R_PPC_TPREL16_HA;
+ rel->r_info = ELF32_R_INFO (r_symndx, r_type);
+ rel[1].r_info = ELF32_R_INFO (r_symndx,
+ R_PPC_TPREL16_LO);
+ rel[1].r_offset += 2;
+ }
+ bfd_put_32 (output_bfd, insn1, contents + rel->r_offset - 2);
+ bfd_put_32 (output_bfd, insn2, contents + offset);
+ if (tls_gd == 0)
+ {
+ /* We changed the symbol on an LD reloc. Start over
+ in order to get h, sym, sec etc. right. */
+ rel--;
+ continue;
+ }
+ }
}
+ break;
}
- switch ((int) r_type)
+ /* Handle other relocations that tweak non-addend part of insn. */
+ branch_bit = 0;
+ switch (r_type)
{
default:
- (*_bfd_error_handler) (_("%s: unknown relocation type %d for symbol %s"),
- bfd_archive_filename (input_bfd),
- (int) r_type, sym_name);
+ break;
+
+ /* Branch taken prediction relocations. */
+ case R_PPC_ADDR14_BRTAKEN:
+ case R_PPC_REL14_BRTAKEN:
+ branch_bit = BRANCH_PREDICT_BIT;
+ /* Fall thru */
+
+ /* Branch not taken prediction relocations. */
+ case R_PPC_ADDR14_BRNTAKEN:
+ case R_PPC_REL14_BRNTAKEN:
+ insn = bfd_get_32 (output_bfd, contents + rel->r_offset);
+ insn &= ~BRANCH_PREDICT_BIT;
+ insn |= branch_bit;
+
+ from = (rel->r_offset
+ + input_section->output_offset
+ + input_section->output_section->vma);
+
+ /* Invert 'y' bit if not the default. */
+ if ((bfd_signed_vma) (relocation + rel->r_addend - from) < 0)
+ insn ^= BRANCH_PREDICT_BIT;
+
+ bfd_put_32 (output_bfd, insn, contents + rel->r_offset);
+ break;
+ }
+
+ addend = rel->r_addend;
+ tls_type = 0;
+ howto = NULL;
+ if (r_type < R_PPC_max)
+ howto = ppc_elf_howto_table[r_type];
+ switch (r_type)
+ {
+ default:
+ (*_bfd_error_handler)
+ (_("%s: unknown relocation type %d for symbol %s"),
+ bfd_archive_filename (input_bfd), (int) r_type, sym_name);
bfd_set_error (bfd_error_bad_value);
- ret = false;
+ ret = FALSE;
continue;
- case (int) R_PPC_NONE:
+ case R_PPC_NONE:
+ case R_PPC_TLS:
+ case R_PPC_EMB_MRKREF:
+ case R_PPC_GNU_VTINHERIT:
+ case R_PPC_GNU_VTENTRY:
continue;
+ /* GOT16 relocations. Like an ADDR16 using the symbol's
+ address in the GOT as relocation value instead of the
+ symbol's value itself. Also, create a GOT entry for the
+ symbol and put the symbol value there. */
+ case R_PPC_GOT_TLSGD16:
+ case R_PPC_GOT_TLSGD16_LO:
+ case R_PPC_GOT_TLSGD16_HI:
+ case R_PPC_GOT_TLSGD16_HA:
+ tls_type = TLS_TLS | TLS_GD;
+ goto dogot;
+
+ case R_PPC_GOT_TLSLD16:
+ case R_PPC_GOT_TLSLD16_LO:
+ case R_PPC_GOT_TLSLD16_HI:
+ case R_PPC_GOT_TLSLD16_HA:
+ tls_type = TLS_TLS | TLS_LD;
+ goto dogot;
+
+ case R_PPC_GOT_TPREL16:
+ case R_PPC_GOT_TPREL16_LO:
+ case R_PPC_GOT_TPREL16_HI:
+ case R_PPC_GOT_TPREL16_HA:
+ tls_type = TLS_TLS | TLS_TPREL;
+ goto dogot;
+
+ case R_PPC_GOT_DTPREL16:
+ case R_PPC_GOT_DTPREL16_LO:
+ case R_PPC_GOT_DTPREL16_HI:
+ case R_PPC_GOT_DTPREL16_HA:
+ tls_type = TLS_TLS | TLS_DTPREL;
+ goto dogot;
+
+ case R_PPC_GOT16:
+ case R_PPC_GOT16_LO:
+ case R_PPC_GOT16_HI:
+ case R_PPC_GOT16_HA:
+ dogot:
+ {
+ /* Relocation is to the entry for this symbol in the global
+ offset table. */
+ bfd_vma off;
+ bfd_vma *offp;
+ unsigned long indx;
+
+ if (htab->got == NULL)
+ abort ();
+
+ indx = 0;
+ if (tls_type == (TLS_TLS | TLS_LD)
+ && (h == NULL
+ || !(h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC)))
+ offp = &htab->tlsld_got.offset;
+ else if (h != NULL)
+ {
+ bfd_boolean dyn;
+ dyn = htab->elf.dynamic_sections_created;
+ if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info->shared, h)
+ || (info->shared
+ && SYMBOL_REFERENCES_LOCAL (info, h)))
+ /* This is actually a static link, or it is a
+ -Bsymbolic link and the symbol is defined
+ locally, or the symbol was forced to be local
+ because of a version file. */
+ ;
+ else
+ {
+ indx = h->dynindx;
+ unresolved_reloc = FALSE;
+ }
+ offp = &h->got.offset;
+ }
+ else
+ {
+ if (local_got_offsets == NULL)
+ abort ();
+ offp = &local_got_offsets[r_symndx];
+ }
+
+ /* The offset must always be a multiple of 4. We use the
+ least significant bit to record whether we have already
+ processed this entry. */
+ off = *offp;
+ if ((off & 1) != 0)
+ off &= ~1;
+ else
+ {
+ unsigned int tls_m = (tls_mask
+ & (TLS_LD | TLS_GD | TLS_DTPREL
+ | TLS_TPREL | TLS_TPRELGD));
+
+ if (offp == &htab->tlsld_got.offset)
+ tls_m = TLS_LD;
+ else if (h == NULL
+ || !(h->elf_link_hash_flags
+ & ELF_LINK_HASH_DEF_DYNAMIC))
+ tls_m &= ~TLS_LD;
+
+ /* We might have multiple got entries for this sym.
+ Initialize them all. */
+ do
+ {
+ int tls_ty = 0;
+
+ if ((tls_m & TLS_LD) != 0)
+ {
+ tls_ty = TLS_TLS | TLS_LD;
+ tls_m &= ~TLS_LD;
+ }
+ else if ((tls_m & TLS_GD) != 0)
+ {
+ tls_ty = TLS_TLS | TLS_GD;
+ tls_m &= ~TLS_GD;
+ }
+ else if ((tls_m & TLS_DTPREL) != 0)
+ {
+ tls_ty = TLS_TLS | TLS_DTPREL;
+ tls_m &= ~TLS_DTPREL;
+ }
+ else if ((tls_m & (TLS_TPREL | TLS_TPRELGD)) != 0)
+ {
+ tls_ty = TLS_TLS | TLS_TPREL;
+ tls_m = 0;
+ }
+
+ /* Generate relocs for the dynamic linker. */
+ if ((info->shared || indx != 0)
+ && (h == NULL
+ || ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak))
+ {
+ outrel.r_offset = (htab->got->output_section->vma
+ + htab->got->output_offset
+ + off);
+ outrel.r_addend = 0;
+ if (tls_ty & (TLS_LD | TLS_GD))
+ {
+ outrel.r_info = ELF32_R_INFO (indx, R_PPC_DTPMOD32);
+ if (tls_ty == (TLS_TLS | TLS_GD))
+ {
+ loc = htab->relgot->contents;
+ loc += (htab->relgot->reloc_count++
+ * sizeof (Elf32_External_Rela));
+ bfd_elf32_swap_reloca_out (output_bfd,
+ &outrel, loc);
+ outrel.r_offset += 4;
+ outrel.r_info
+ = ELF32_R_INFO (indx, R_PPC_DTPREL32);
+ }
+ }
+ else if (tls_ty == (TLS_TLS | TLS_DTPREL))
+ outrel.r_info = ELF32_R_INFO (indx, R_PPC_DTPREL32);
+ else if (tls_ty == (TLS_TLS | TLS_TPREL))
+ outrel.r_info = ELF32_R_INFO (indx, R_PPC_TPREL32);
+ else if (indx == 0)
+ outrel.r_info = ELF32_R_INFO (indx, R_PPC_RELATIVE);
+ else
+ outrel.r_info = ELF32_R_INFO (indx, R_PPC_GLOB_DAT);
+ if (indx == 0)
+ {
+ outrel.r_addend += relocation;
+ if (tls_ty & (TLS_GD | TLS_DTPREL | TLS_TPREL))
+ outrel.r_addend -= htab->elf.tls_sec->vma;
+ }
+ loc = htab->relgot->contents;
+ loc += (htab->relgot->reloc_count++
+ * sizeof (Elf32_External_Rela));
+ bfd_elf32_swap_reloca_out (output_bfd, &outrel, loc);
+ }
+
+ /* Init the .got section contents if we're not
+ emitting a reloc. */
+ else
+ {
+ bfd_vma value = relocation;
+
+ if (tls_ty == (TLS_TLS | TLS_LD))
+ value = 1;
+ else if (tls_ty != 0)
+ {
+ value -= htab->elf.tls_sec->vma + DTP_OFFSET;
+ if (tls_ty == (TLS_TLS | TLS_TPREL))
+ value += DTP_OFFSET - TP_OFFSET;
+
+ if (tls_ty == (TLS_TLS | TLS_GD))
+ {
+ bfd_put_32 (output_bfd, value,
+ htab->got->contents + off + 4);
+ value = 1;
+ }
+ }
+ bfd_put_32 (output_bfd, value,
+ htab->got->contents + off);
+ }
+
+ off += 4;
+ if (tls_ty & (TLS_LD | TLS_GD))
+ off += 4;
+ }
+ while (tls_m != 0);
+
+ off = *offp;
+ *offp = off | 1;
+ }
+
+ if (off >= (bfd_vma) -2)
+ abort ();
+
+ if ((tls_type & TLS_TLS) != 0)
+ {
+ if (tls_type != (TLS_TLS | TLS_LD))
+ {
+ if ((tls_mask & TLS_LD) != 0
+ && !(h == NULL
+ || !(h->elf_link_hash_flags
+ & ELF_LINK_HASH_DEF_DYNAMIC)))
+ off += 8;
+ if (tls_type != (TLS_TLS | TLS_GD))
+ {
+ if ((tls_mask & TLS_GD) != 0)
+ off += 8;
+ if (tls_type != (TLS_TLS | TLS_DTPREL))
+ {
+ if ((tls_mask & TLS_DTPREL) != 0)
+ off += 4;
+ }
+ }
+ }
+ }
+
+ relocation = htab->got->output_offset + off - 4;
+
+ /* Addends on got relocations don't make much sense.
+ x+off@got is actually x@got+off, and since the got is
+ generated by a hash table traversal, the value in the
+ got at entry m+n bears little relation to the entry m. */
+ if (addend != 0)
+ (*_bfd_error_handler)
+ (_("%s(%s+0x%lx): non-zero addend on %s reloc against `%s'"),
+ bfd_archive_filename (input_bfd),
+ bfd_get_section_name (input_bfd, input_section),
+ (long) rel->r_offset,
+ howto->name,
+ sym_name);
+ }
+ break;
+
/* Relocations that need no special processing. */
- case (int) R_PPC_LOCAL24PC:
+ case R_PPC_LOCAL24PC:
/* It makes no sense to point a local relocation
at a symbol not in this object. */
- if (h != NULL
- && (h->root.type == bfd_link_hash_defined
- || h->root.type == bfd_link_hash_defweak)
- && sec->output_section == NULL)
+ if (unresolved_reloc)
{
if (! (*info->callbacks->undefined_symbol) (info,
h->root.root.string,
input_bfd,
input_section,
rel->r_offset,
- true))
- return false;
+ TRUE))
+ return FALSE;
continue;
}
break;
- /* Relocations that may need to be propagated if this is a shared
- object. */
- case (int) R_PPC_REL24:
- case (int) R_PPC_REL32:
- case (int) R_PPC_REL14:
+ case R_PPC_DTPREL16:
+ case R_PPC_DTPREL16_LO:
+ case R_PPC_DTPREL16_HI:
+ case R_PPC_DTPREL16_HA:
+ addend -= htab->elf.tls_sec->vma + DTP_OFFSET;
+ break;
+
+ /* Relocations that may need to be propagated if this is a shared
+ object. */
+ case R_PPC_TPREL16:
+ case R_PPC_TPREL16_LO:
+ case R_PPC_TPREL16_HI:
+ case R_PPC_TPREL16_HA:
+ addend -= htab->elf.tls_sec->vma + TP_OFFSET;
+ /* The TPREL16 relocs shouldn't really be used in shared
+ libs as they will result in DT_TEXTREL being set, but
+ support them anyway. */
+ goto dodyn;
+
+ case R_PPC_TPREL32:
+ addend -= htab->elf.tls_sec->vma + TP_OFFSET;
+ goto dodyn;
+
+ case R_PPC_DTPREL32:
+ addend -= htab->elf.tls_sec->vma + DTP_OFFSET;
+ goto dodyn;
+
+ case R_PPC_DTPMOD32:
+ relocation = 1;
+ addend = 0;
+ goto dodyn;
+
+ case R_PPC_REL24:
+ case R_PPC_REL32:
+ case R_PPC_REL14:
+ case R_PPC_REL14_BRTAKEN:
+ case R_PPC_REL14_BRNTAKEN:
/* If these relocations are not to a named symbol, they can be
handled right here, no need to bother the dynamic linker. */
- if (h == NULL
- || strcmp (h->root.root.string, "_GLOBAL_OFFSET_TABLE_") == 0
- || SYMBOL_REFERENCES_LOCAL (info, h))
+ if (SYMBOL_REFERENCES_LOCAL (info, h)
+ || strcmp (h->root.root.string, "_GLOBAL_OFFSET_TABLE_") == 0)
break;
- /* fall through */
-
- /* Relocations that always need to be propagated if this is a shared
- object. */
- case (int) R_PPC_ADDR32:
- case (int) R_PPC_ADDR24:
- case (int) R_PPC_ADDR16:
- case (int) R_PPC_ADDR16_LO:
- case (int) R_PPC_ADDR16_HI:
- case (int) R_PPC_ADDR16_HA:
- case (int) R_PPC_ADDR14:
- case (int) R_PPC_UADDR32:
- case (int) R_PPC_UADDR16:
- if (info->shared && r_symndx != 0)
+ /* fall through */
+
+ /* Relocations that always need to be propagated if this is a shared
+ object. */
+ case R_PPC_ADDR32:
+ case R_PPC_ADDR24:
+ case R_PPC_ADDR16:
+ case R_PPC_ADDR16_LO:
+ case R_PPC_ADDR16_HI:
+ case R_PPC_ADDR16_HA:
+ case R_PPC_ADDR14:
+ case R_PPC_ADDR14_BRTAKEN:
+ case R_PPC_ADDR14_BRNTAKEN:
+ case R_PPC_UADDR32:
+ case R_PPC_UADDR16:
+ /* r_symndx will be zero only for relocs against symbols
+ from removed linkonce sections, or sections discarded by
+ a linker script. */
+ dodyn:
+ if (r_symndx == 0)
+ break;
+ /* Fall thru. */
+
+ if ((info->shared
+ && (h == NULL
+ || ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak)
+ && (MUST_BE_DYN_RELOC (r_type)
+ || !SYMBOL_CALLS_LOCAL (info, h)))
+ || (ELIMINATE_COPY_RELOCS
+ && !info->shared
+ && (input_section->flags & SEC_ALLOC) != 0
+ && h != NULL
+ && h->dynindx != -1
+ && (h->elf_link_hash_flags & ELF_LINK_NON_GOT_REF) == 0
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0))
{
- Elf_Internal_Rela outrel;
int skip;
#ifdef DEBUG
- fprintf (stderr, "ppc_elf_relocate_section need to create relocation for %s\n",
- (h && h->root.root.string) ? h->root.root.string : "<unknown>");
+ fprintf (stderr, "ppc_elf_relocate_section needs to "
+ "create relocation for %s\n",
+ (h && h->root.root.string
+ ? h->root.root.string : "<unknown>"));
#endif
/* When generating a shared object, these relocations
- are copied into the output file to be resolved at run
- time. */
-
+ are copied into the output file to be resolved at run
+ time. */
if (sreloc == NULL)
{
const char *name;
@@ -3201,14 +5320,14 @@ ppc_elf_relocate_section (output_bfd, info, input_bfd, input_section,
elf_elfheader (input_bfd)->e_shstrndx,
elf_section_data (input_section)->rel_hdr.sh_name));
if (name == NULL)
- return false;
+ return FALSE;
BFD_ASSERT (strncmp (name, ".rela", 5) == 0
&& strcmp (bfd_get_section_name (input_bfd,
input_section),
name + 5) == 0);
- sreloc = bfd_get_section_by_name (dynobj, name);
+ sreloc = bfd_get_section_by_name (htab->elf.dynobj, name);
BFD_ASSERT (sreloc != NULL);
}
@@ -3225,67 +5344,56 @@ ppc_elf_relocate_section (output_bfd, info, input_bfd, input_section,
if (skip)
memset (&outrel, 0, sizeof outrel);
- /* h->dynindx may be -1 if this symbol was marked to
- become local. */
- else if (! will_become_local)
+ else if (!SYMBOL_REFERENCES_LOCAL (info, h))
{
+ unresolved_reloc = FALSE;
outrel.r_info = ELF32_R_INFO (h->dynindx, r_type);
outrel.r_addend = rel->r_addend;
}
else
{
+ outrel.r_addend = relocation + rel->r_addend;
+
if (r_type == R_PPC_ADDR32)
- {
- outrel.r_info = ELF32_R_INFO (0, R_PPC_RELATIVE);
- outrel.r_addend = relocation + rel->r_addend;
- }
+ outrel.r_info = ELF32_R_INFO (0, R_PPC_RELATIVE);
else
{
long indx;
- if (h == NULL)
- sec = local_sections[r_symndx];
- else
- {
- BFD_ASSERT (h->root.type == bfd_link_hash_defined
- || (h->root.type
- == bfd_link_hash_defweak));
- sec = h->root.u.def.section;
- }
- if (sec != NULL && bfd_is_abs_section (sec))
+ if (bfd_is_abs_section (sec))
indx = 0;
else if (sec == NULL || sec->owner == NULL)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
else
{
asection *osec;
+ /* We are turning this relocation into one
+ against a section symbol. It would be
+ proper to subtract the symbol's value,
+ osec->vma, from the emitted reloc addend,
+ but ld.so expects buggy relocs. */
osec = sec->output_section;
indx = elf_section_data (osec)->dynindx;
BFD_ASSERT (indx > 0);
#ifdef DEBUG
if (indx <= 0)
- {
- printf ("indx=%d section=%s flags=%08x name=%s\n",
- indx, osec->name, osec->flags,
- h->root.root.string);
- }
+ printf ("indx=%d section=%s flags=%08x name=%s\n",
+ indx, osec->name, osec->flags,
+ h->root.root.string);
#endif
}
outrel.r_info = ELF32_R_INFO (indx, r_type);
- outrel.r_addend = relocation + rel->r_addend;
}
}
- bfd_elf32_swap_reloca_out (output_bfd, &outrel,
- (((Elf32_External_Rela *)
- sreloc->contents)
- + sreloc->reloc_count));
- ++sreloc->reloc_count;
+ loc = sreloc->contents;
+ loc += sreloc->reloc_count++ * sizeof (Elf32_External_Rela);
+ bfd_elf32_swap_reloca_out (output_bfd, &outrel, loc);
if (skip == -1)
continue;
@@ -3301,252 +5409,175 @@ ppc_elf_relocate_section (output_bfd, info, input_bfd, input_section,
break;
}
}
-
- /* Arithmetic adjust relocations that aren't going into a
- shared object. */
- if (r_type == R_PPC_ADDR16_HA
- /* It's just possible that this symbol is a weak symbol
- that's not actually defined anywhere. In that case,
- 'sec' would be NULL, and we should leave the symbol
- alone (it will be set to zero elsewhere in the link). */
- && sec != NULL)
- {
- addend += ((relocation + addend) & 0x8000) << 1;
- }
break;
- /* branch taken prediction relocations */
- case (int) R_PPC_ADDR14_BRTAKEN:
- case (int) R_PPC_REL14_BRTAKEN:
- insn = bfd_get_32 (output_bfd, contents + offset);
- if ((relocation - offset) & 0x8000)
- insn &= ~BRANCH_PREDICT_BIT;
- else
- insn |= BRANCH_PREDICT_BIT;
- bfd_put_32 (output_bfd, (bfd_vma) insn, contents + offset);
- break;
-
- /* branch not taken predicition relocations */
- case (int) R_PPC_ADDR14_BRNTAKEN:
- case (int) R_PPC_REL14_BRNTAKEN:
- insn = bfd_get_32 (output_bfd, contents + offset);
- if ((relocation - offset) & 0x8000)
- insn |= BRANCH_PREDICT_BIT;
- else
- insn &= ~BRANCH_PREDICT_BIT;
- bfd_put_32 (output_bfd, (bfd_vma) insn, contents + offset);
- break;
-
- /* GOT16 relocations */
- case (int) R_PPC_GOT16:
- case (int) R_PPC_GOT16_LO:
- case (int) R_PPC_GOT16_HI:
- case (int) R_PPC_GOT16_HA:
- /* Relocation is to the entry for this symbol in the global
- offset table. */
- BFD_ASSERT (sgot != NULL);
-
- if (h != NULL)
- {
- bfd_vma off;
-
- off = h->got.offset;
- BFD_ASSERT (off != (bfd_vma) -1);
-
- if (! elf_hash_table (info)->dynamic_sections_created
- || (info->shared
- && SYMBOL_REFERENCES_LOCAL (info, h)))
- {
- /* This is actually a static link, or it is a
- -Bsymbolic link and the symbol is defined
- locally. We must initialize this entry in the
- global offset table. Since the offset must
- always be a multiple of 4, we use the least
- significant bit to record whether we have
- initialized it already.
-
- When doing a dynamic link, we create a .rela.got
- relocation entry to initialize the value. This
- is done in the finish_dynamic_symbol routine. */
- if ((off & 1) != 0)
- off &= ~1;
- else
- {
- bfd_put_32 (output_bfd, relocation,
- sgot->contents + off);
- h->got.offset |= 1;
- }
- }
-
- relocation = sgot->output_offset + off - 4;
- }
- else
- {
- bfd_vma off;
+ case R_PPC_RELAX32PC:
+ relocation -= (input_section->output_section->vma
+ + input_section->output_offset
+ + rel->r_offset - 4);
+ /* Fall thru */
+ case R_PPC_RELAX32:
+ {
+ unsigned long t0;
+ unsigned long t1;
- BFD_ASSERT (local_got_offsets != NULL
- && local_got_offsets[r_symndx] != (bfd_vma) -1);
+ t0 = bfd_get_32 (output_bfd, contents + rel->r_offset);
+ t1 = bfd_get_32 (output_bfd, contents + rel->r_offset + 4);
- off = local_got_offsets[r_symndx];
+ /* We're clearing the bits for R_PPC_ADDR16_HA
+ and R_PPC_ADDR16_LO here. */
+ t0 &= ~0xffff;
+ t1 &= ~0xffff;
- /* The offset must always be a multiple of 4. We use
- the least significant bit to record whether we have
- already processed this entry. */
- if ((off & 1) != 0)
- off &= ~1;
- else
- {
+ /* t0 is HA, t1 is LO */
+ relocation += addend;
+ t0 |= ((relocation + 0x8000) >> 16) & 0xffff;
+ t1 |= relocation & 0xffff;
- if (info->shared)
- {
- asection *srelgot;
- Elf_Internal_Rela outrel;
-
- /* We need to generate a R_PPC_RELATIVE reloc
- for the dynamic linker. */
- srelgot = bfd_get_section_by_name (dynobj, ".rela.got");
- BFD_ASSERT (srelgot != NULL);
-
- outrel.r_offset = (sgot->output_section->vma
- + sgot->output_offset
- + off);
- outrel.r_info = ELF32_R_INFO (0, R_PPC_RELATIVE);
- outrel.r_addend = relocation;
- bfd_elf32_swap_reloca_out (output_bfd, &outrel,
- (((Elf32_External_Rela *)
- srelgot->contents)
- + srelgot->reloc_count));
- ++srelgot->reloc_count;
- relocation = 0;
- }
-
- bfd_put_32 (output_bfd, relocation, sgot->contents + off);
- local_got_offsets[r_symndx] |= 1;
- }
-
- relocation = sgot->output_offset + off - 4;
- }
- break;
+ bfd_put_32 (output_bfd, t0, contents + rel->r_offset);
+ bfd_put_32 (output_bfd, t1, contents + rel->r_offset + 4);
+ }
+ continue;
- /* Indirect .sdata relocation */
- case (int) R_PPC_EMB_SDAI16:
- BFD_ASSERT (sdata != NULL);
- relocation = bfd_elf32_finish_pointer_linker_section (output_bfd, input_bfd, info,
- sdata, h, relocation, rel,
- R_PPC_RELATIVE);
+ /* Indirect .sdata relocation. */
+ case R_PPC_EMB_SDAI16:
+ BFD_ASSERT (htab->sdata != NULL);
+ relocation
+ = elf_finish_pointer_linker_section (output_bfd, input_bfd, info,
+ htab->sdata, h, relocation,
+ rel, R_PPC_RELATIVE);
break;
- /* Indirect .sdata2 relocation */
- case (int) R_PPC_EMB_SDA2I16:
- BFD_ASSERT (sdata2 != NULL);
- relocation = bfd_elf32_finish_pointer_linker_section (output_bfd, input_bfd, info,
- sdata2, h, relocation, rel,
- R_PPC_RELATIVE);
+ /* Indirect .sdata2 relocation. */
+ case R_PPC_EMB_SDA2I16:
+ BFD_ASSERT (htab->sdata2 != NULL);
+ relocation
+ = elf_finish_pointer_linker_section (output_bfd, input_bfd, info,
+ htab->sdata2, h, relocation,
+ rel, R_PPC_RELATIVE);
break;
- /* Handle the TOC16 reloc. We want to use the offset within the .got
- section, not the actual VMA. This is appropriate when generating
- an embedded ELF object, for which the .got section acts like the
- AIX .toc section. */
- case (int) R_PPC_TOC16: /* phony GOT16 relocations */
- BFD_ASSERT (sec != (asection *) 0);
+ /* Handle the TOC16 reloc. We want to use the offset within the .got
+ section, not the actual VMA. This is appropriate when generating
+ an embedded ELF object, for which the .got section acts like the
+ AIX .toc section. */
+ case R_PPC_TOC16: /* phony GOT16 relocations */
+ BFD_ASSERT (sec != NULL);
BFD_ASSERT (bfd_is_und_section (sec)
|| strcmp (bfd_get_section_name (abfd, sec), ".got") == 0
|| strcmp (bfd_get_section_name (abfd, sec), ".cgot") == 0)
- addend -= sec->output_section->vma + sec->output_offset + 0x8000;
+ addend -= sec->output_section->vma + sec->output_offset + 0x8000;
break;
- case (int) R_PPC_PLTREL24:
+ case R_PPC_PLTREL24:
/* Relocation is to the entry for this symbol in the
- procedure linkage table. */
+ procedure linkage table. */
BFD_ASSERT (h != NULL);
if (h->plt.offset == (bfd_vma) -1
- || splt == NULL)
+ || htab->plt == NULL)
{
/* We didn't make a PLT entry for this symbol. This
- happens when statically linking PIC code, or when
- using -Bsymbolic. */
+ happens when statically linking PIC code, or when
+ using -Bsymbolic. */
break;
}
- relocation = (splt->output_section->vma
- + splt->output_offset
+ unresolved_reloc = FALSE;
+ relocation = (htab->plt->output_section->vma
+ + htab->plt->output_offset
+ h->plt.offset);
break;
- /* relocate against _SDA_BASE_ */
- case (int) R_PPC_SDAREL16:
+ /* Relocate against _SDA_BASE_. */
+ case R_PPC_SDAREL16:
{
const char *name;
+ const struct elf_link_hash_entry *sh;
- BFD_ASSERT (sec != (asection *) 0);
+ BFD_ASSERT (sec != NULL);
name = bfd_get_section_name (abfd, sec->output_section);
- if (strcmp (name, ".sdata") != 0
- && strcmp (name, ".sbss") != 0)
+ if (! ((strncmp (name, ".sdata", 6) == 0
+ && (name[6] == 0 || name[6] == '.'))
+ || (strncmp (name, ".sbss", 5) == 0
+ && (name[5] == 0 || name[5] == '.'))))
{
- (*_bfd_error_handler) (_("%s: The target (%s) of a %s relocation is in the wrong output section (%s)"),
- bfd_archive_filename (input_bfd),
- sym_name,
- ppc_elf_howto_table[(int) r_type]->name,
- name);
+ (*_bfd_error_handler)
+ (_("%s: the target (%s) of a %s relocation is "
+ "in the wrong output section (%s)"),
+ bfd_archive_filename (input_bfd),
+ sym_name,
+ howto->name,
+ name);
}
- addend -= (sdata->sym_hash->root.u.def.value
- + sdata->sym_hash->root.u.def.section->output_section->vma
- + sdata->sym_hash->root.u.def.section->output_offset);
+ sh = htab->sdata->sym_hash;
+ addend -= (sh->root.u.def.value
+ + sh->root.u.def.section->output_section->vma
+ + sh->root.u.def.section->output_offset);
}
break;
- /* relocate against _SDA2_BASE_ */
- case (int) R_PPC_EMB_SDA2REL:
+ /* Relocate against _SDA2_BASE_. */
+ case R_PPC_EMB_SDA2REL:
{
const char *name;
+ const struct elf_link_hash_entry *sh;
- BFD_ASSERT (sec != (asection *) 0);
+ BFD_ASSERT (sec != NULL);
name = bfd_get_section_name (abfd, sec->output_section);
- if (strcmp (name, ".sdata2") != 0 && strcmp (name, ".sbss2") != 0)
+ if (! (strncmp (name, ".sdata2", 7) == 0
+ || strncmp (name, ".sbss2", 6) == 0))
{
- (*_bfd_error_handler) (_("%s: The target (%s) of a %s relocation is in the wrong output section (%s)"),
- bfd_archive_filename (input_bfd),
- sym_name,
- ppc_elf_howto_table[(int) r_type]->name,
- name);
+ (*_bfd_error_handler)
+ (_("%s: the target (%s) of a %s relocation is "
+ "in the wrong output section (%s)"),
+ bfd_archive_filename (input_bfd),
+ sym_name,
+ howto->name,
+ name);
bfd_set_error (bfd_error_bad_value);
- ret = false;
+ ret = FALSE;
continue;
}
- addend -= (sdata2->sym_hash->root.u.def.value
- + sdata2->sym_hash->root.u.def.section->output_section->vma
- + sdata2->sym_hash->root.u.def.section->output_offset);
+ sh = htab->sdata2->sym_hash;
+ addend -= (sh->root.u.def.value
+ + sh->root.u.def.section->output_section->vma
+ + sh->root.u.def.section->output_offset);
}
break;
- /* relocate against either _SDA_BASE_, _SDA2_BASE_, or 0 */
- case (int) R_PPC_EMB_SDA21:
- case (int) R_PPC_EMB_RELSDA:
+ /* Relocate against either _SDA_BASE_, _SDA2_BASE_, or 0. */
+ case R_PPC_EMB_SDA21:
+ case R_PPC_EMB_RELSDA:
{
const char *name;
+ const struct elf_link_hash_entry *sh;
int reg;
- BFD_ASSERT (sec != (asection *) 0);
+ BFD_ASSERT (sec != NULL);
name = bfd_get_section_name (abfd, sec->output_section);
- if (strcmp (name, ".sdata") == 0 || strcmp (name, ".sbss") == 0)
+ if (((strncmp (name, ".sdata", 6) == 0
+ && (name[6] == 0 || name[6] == '.'))
+ || (strncmp (name, ".sbss", 5) == 0
+ && (name[5] == 0 || name[5] == '.'))))
{
reg = 13;
- addend -= (sdata->sym_hash->root.u.def.value
- + sdata->sym_hash->root.u.def.section->output_section->vma
- + sdata->sym_hash->root.u.def.section->output_offset);
+ sh = htab->sdata->sym_hash;
+ addend -= (sh->root.u.def.value
+ + sh->root.u.def.section->output_section->vma
+ + sh->root.u.def.section->output_offset);
}
- else if (strcmp (name, ".sdata2") == 0
- || strcmp (name, ".sbss2") == 0)
+ else if (strncmp (name, ".sdata2", 7) == 0
+ || strncmp (name, ".sbss2", 6) == 0)
{
reg = 2;
- addend -= (sdata2->sym_hash->root.u.def.value
- + sdata2->sym_hash->root.u.def.section->output_section->vma
- + sdata2->sym_hash->root.u.def.section->output_offset);
+ sh = htab->sdata2->sym_hash;
+ addend -= (sh->root.u.def.value
+ + sh->root.u.def.section->output_section->vma
+ + sh->root.u.def.section->output_offset);
}
else if (strcmp (name, ".PPC.EMB.sdata0") == 0
@@ -3557,114 +5588,144 @@ ppc_elf_relocate_section (output_bfd, info, input_bfd, input_section,
else
{
- (*_bfd_error_handler) (_("%s: The target (%s) of a %s relocation is in the wrong output section (%s)"),
- bfd_archive_filename (input_bfd),
- sym_name,
- ppc_elf_howto_table[(int) r_type]->name,
- name);
+ (*_bfd_error_handler)
+ (_("%s: the target (%s) of a %s relocation is "
+ "in the wrong output section (%s)"),
+ bfd_archive_filename (input_bfd),
+ sym_name,
+ howto->name,
+ name);
bfd_set_error (bfd_error_bad_value);
- ret = false;
+ ret = FALSE;
continue;
}
if (r_type == R_PPC_EMB_SDA21)
{ /* fill in register field */
- insn = bfd_get_32 (output_bfd, contents + offset);
+ insn = bfd_get_32 (output_bfd, contents + rel->r_offset);
insn = (insn & ~RA_REGISTER_MASK) | (reg << RA_REGISTER_SHIFT);
- bfd_put_32 (output_bfd, (bfd_vma) insn, contents + offset);
+ bfd_put_32 (output_bfd, insn, contents + rel->r_offset);
}
}
break;
- /* Relocate against the beginning of the section */
- case (int) R_PPC_SECTOFF:
- case (int) R_PPC_SECTOFF_LO:
- case (int) R_PPC_SECTOFF_HI:
- BFD_ASSERT (sec != (asection *) 0);
- addend -= sec->output_section->vma;
- break;
-
- case (int) R_PPC_SECTOFF_HA:
- BFD_ASSERT (sec != (asection *) 0);
+ /* Relocate against the beginning of the section. */
+ case R_PPC_SECTOFF:
+ case R_PPC_SECTOFF_LO:
+ case R_PPC_SECTOFF_HI:
+ case R_PPC_SECTOFF_HA:
+ BFD_ASSERT (sec != NULL);
addend -= sec->output_section->vma;
- addend += ((relocation + addend) & 0x8000) << 1;
- break;
-
- /* Negative relocations */
- case (int) R_PPC_EMB_NADDR32:
- case (int) R_PPC_EMB_NADDR16:
- case (int) R_PPC_EMB_NADDR16_LO:
- case (int) R_PPC_EMB_NADDR16_HI:
- addend -= 2 * relocation;
break;
- case (int) R_PPC_EMB_NADDR16_HA:
+ /* Negative relocations. */
+ case R_PPC_EMB_NADDR32:
+ case R_PPC_EMB_NADDR16:
+ case R_PPC_EMB_NADDR16_LO:
+ case R_PPC_EMB_NADDR16_HI:
+ case R_PPC_EMB_NADDR16_HA:
addend -= 2 * relocation;
- addend += ((relocation + addend) & 0x8000) << 1;
break;
- /* NOP relocation that prevents garbage collecting linkers from omitting a
- reference. */
- case (int) R_PPC_EMB_MRKREF:
- continue;
-
- case (int) R_PPC_COPY:
- case (int) R_PPC_GLOB_DAT:
- case (int) R_PPC_JMP_SLOT:
- case (int) R_PPC_RELATIVE:
- case (int) R_PPC_PLT32:
- case (int) R_PPC_PLTREL32:
- case (int) R_PPC_PLT16_LO:
- case (int) R_PPC_PLT16_HI:
- case (int) R_PPC_PLT16_HA:
- case (int) R_PPC_EMB_RELSEC16:
- case (int) R_PPC_EMB_RELST_LO:
- case (int) R_PPC_EMB_RELST_HI:
- case (int) R_PPC_EMB_RELST_HA:
- case (int) R_PPC_EMB_BIT_FLD:
- (*_bfd_error_handler) (_("%s: Relocation %s is not yet supported for symbol %s."),
- bfd_archive_filename (input_bfd),
- ppc_elf_howto_table[(int) r_type]->name,
- sym_name);
+ case R_PPC_COPY:
+ case R_PPC_GLOB_DAT:
+ case R_PPC_JMP_SLOT:
+ case R_PPC_RELATIVE:
+ case R_PPC_PLT32:
+ case R_PPC_PLTREL32:
+ case R_PPC_PLT16_LO:
+ case R_PPC_PLT16_HI:
+ case R_PPC_PLT16_HA:
+ case R_PPC_ADDR30:
+ case R_PPC_EMB_RELSEC16:
+ case R_PPC_EMB_RELST_LO:
+ case R_PPC_EMB_RELST_HI:
+ case R_PPC_EMB_RELST_HA:
+ case R_PPC_EMB_BIT_FLD:
+ (*_bfd_error_handler)
+ (_("%s: relocation %s is not yet supported for symbol %s."),
+ bfd_archive_filename (input_bfd),
+ howto->name,
+ sym_name);
bfd_set_error (bfd_error_invalid_operation);
- ret = false;
+ ret = FALSE;
continue;
+ }
- case (int) R_PPC_GNU_VTINHERIT:
- case (int) R_PPC_GNU_VTENTRY:
- /* These are no-ops in the end. */
- continue;
+ /* Do any further special processing. */
+ switch (r_type)
+ {
+ default:
+ break;
+
+ case R_PPC_ADDR16_HA:
+ case R_PPC_GOT16_HA:
+ case R_PPC_PLT16_HA:
+ case R_PPC_SECTOFF_HA:
+ case R_PPC_TPREL16_HA:
+ case R_PPC_DTPREL16_HA:
+ case R_PPC_GOT_TLSGD16_HA:
+ case R_PPC_GOT_TLSLD16_HA:
+ case R_PPC_GOT_TPREL16_HA:
+ case R_PPC_GOT_DTPREL16_HA:
+ case R_PPC_EMB_NADDR16_HA:
+ case R_PPC_EMB_RELST_HA:
+ /* It's just possible that this symbol is a weak symbol
+ that's not actually defined anywhere. In that case,
+ 'sec' would be NULL, and we should leave the symbol
+ alone (it will be set to zero elsewhere in the link). */
+ if (sec != NULL)
+ /* Add 0x10000 if sign bit in 0:15 is set.
+ Bits 0:15 are not used. */
+ addend += 0x8000;
+ break;
}
#ifdef DEBUG
- fprintf (stderr, "\ttype = %s (%d), name = %s, symbol index = %ld, offset = %ld, addend = %ld\n",
+ fprintf (stderr, "\ttype = %s (%d), name = %s, symbol index = %ld, "
+ "offset = %ld, addend = %ld\n",
howto->name,
(int) r_type,
sym_name,
r_symndx,
- (long) offset,
+ (long) rel->r_offset,
(long) addend);
#endif
+ if (unresolved_reloc
+ && !((input_section->flags & SEC_DEBUGGING) != 0
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0))
+ {
+ (*_bfd_error_handler)
+ (_("%s(%s+0x%lx): unresolvable %s relocation against symbol `%s'"),
+ bfd_archive_filename (input_bfd),
+ bfd_get_section_name (input_bfd, input_section),
+ (long) rel->r_offset,
+ howto->name,
+ sym_name);
+ ret = FALSE;
+ }
+
r = _bfd_final_link_relocate (howto,
input_bfd,
input_section,
contents,
- offset,
+ rel->r_offset,
relocation,
addend);
- if (r == bfd_reloc_ok)
- ;
- else if (r == bfd_reloc_overflow)
+ if (r != bfd_reloc_ok)
{
- const char *name;
-
- if (h != NULL)
+ if (sym_name == NULL)
+ sym_name = "(null)";
+ if (r == bfd_reloc_overflow)
{
- if (h->root.type == bfd_link_hash_undefweak
+ if (warned)
+ continue;
+ if (h != NULL
+ && h->root.type == bfd_link_hash_undefweak
&& howto->pc_relative)
{
/* Assume this is a call protected by other code that
@@ -3676,30 +5737,25 @@ ppc_elf_relocate_section (output_bfd, info, input_bfd, input_section,
continue;
}
- name = h->root.root.string;
+ if (! (*info->callbacks->reloc_overflow) (info,
+ sym_name,
+ howto->name,
+ rel->r_addend,
+ input_bfd,
+ input_section,
+ rel->r_offset))
+ return FALSE;
}
else
{
- name = bfd_elf_string_from_elf_section (input_bfd,
- symtab_hdr->sh_link,
- sym->st_name);
- if (name == NULL)
- continue;
- if (*name == '\0')
- name = bfd_section_name (input_bfd, sec);
+ (*_bfd_error_handler)
+ (_("%s(%s+0x%lx): %s reloc against `%s': error %d"),
+ bfd_archive_filename (input_bfd),
+ bfd_get_section_name (input_bfd, input_section),
+ (long) rel->r_offset, howto->name, sym_name, (int) r);
+ ret = FALSE;
}
-
- if (! (*info->callbacks->reloc_overflow) (info,
- name,
- howto->name,
- (bfd_vma) 0,
- input_bfd,
- input_section,
- offset))
- return false;
}
- else
- ret = false;
}
#ifdef DEBUG
@@ -3710,10 +5766,9 @@ ppc_elf_relocate_section (output_bfd, info, input_bfd, input_section,
}
static enum elf_reloc_type_class
-ppc_elf_reloc_type_class (rela)
- const Elf_Internal_Rela *rela;
+ppc_elf_reloc_type_class (const Elf_Internal_Rela *rela)
{
- switch ((int) ELF32_R_TYPE (rela->r_info))
+ switch (ELF32_R_TYPE (rela->r_info))
{
case R_PPC_RELATIVE:
return reloc_class_relative;
@@ -3728,32 +5783,31 @@ ppc_elf_reloc_type_class (rela)
}
}
-/* Support for core dump NOTE sections */
-static boolean
-ppc_elf_grok_prstatus (abfd, note)
- bfd *abfd;
- Elf_Internal_Note *note;
+/* Support for core dump NOTE sections. */
+
+static bfd_boolean
+ppc_elf_grok_prstatus (bfd *abfd, Elf_Internal_Note *note)
{
int offset;
unsigned int raw_size;
switch (note->descsz)
{
- default:
- return false;
+ default:
+ return FALSE;
- case 268: /* Linux/PPC */
- /* pr_cursig */
- elf_tdata (abfd)->core_signal = bfd_get_16 (abfd, note->descdata + 12);
+ case 268: /* Linux/PPC. */
+ /* pr_cursig */
+ elf_tdata (abfd)->core_signal = bfd_get_16 (abfd, note->descdata + 12);
- /* pr_pid */
- elf_tdata (abfd)->core_pid = bfd_get_32 (abfd, note->descdata + 24);
+ /* pr_pid */
+ elf_tdata (abfd)->core_pid = bfd_get_32 (abfd, note->descdata + 24);
- /* pr_reg */
- offset = 72;
- raw_size = 192;
+ /* pr_reg */
+ offset = 72;
+ raw_size = 192;
- break;
+ break;
}
/* Make a ".reg/999" section. */
@@ -3761,21 +5815,19 @@ ppc_elf_grok_prstatus (abfd, note)
raw_size, note->descpos + offset);
}
-static boolean
-ppc_elf_grok_psinfo (abfd, note)
- bfd *abfd;
- Elf_Internal_Note *note;
+static bfd_boolean
+ppc_elf_grok_psinfo (bfd *abfd, Elf_Internal_Note *note)
{
switch (note->descsz)
{
- default:
- return false;
+ default:
+ return FALSE;
- case 128: /* Linux/PPC elf_prpsinfo */
- elf_tdata (abfd)->core_program
- = _bfd_elfcore_strndup (abfd, note->descdata + 32, 16);
- elf_tdata (abfd)->core_command
- = _bfd_elfcore_strndup (abfd, note->descdata + 48, 80);
+ case 128: /* Linux/PPC elf_prpsinfo. */
+ elf_tdata (abfd)->core_program
+ = _bfd_elfcore_strndup (abfd, note->descdata + 32, 16);
+ elf_tdata (abfd)->core_command
+ = _bfd_elfcore_strndup (abfd, note->descdata + 48, 80);
}
/* Note that for some reason, a spurious space is tacked
@@ -3790,16 +5842,322 @@ ppc_elf_grok_psinfo (abfd, note)
command[n - 1] = '\0';
}
- return true;
+ return TRUE;
}
+/* Very simple linked list structure for recording apuinfo values. */
+typedef struct apuinfo_list
+{
+ struct apuinfo_list *next;
+ unsigned long value;
+}
+apuinfo_list;
+
+static apuinfo_list *head;
+
+
+static void
+apuinfo_list_init (void)
+{
+ head = NULL;
+}
+
+static void
+apuinfo_list_add (unsigned long value)
+{
+ apuinfo_list *entry = head;
+
+ while (entry != NULL)
+ {
+ if (entry->value == value)
+ return;
+ entry = entry->next;
+ }
+
+ entry = bfd_malloc (sizeof (* entry));
+ if (entry == NULL)
+ return;
+
+ entry->value = value;
+ entry->next = head;
+ head = entry;
+}
+
+static unsigned
+apuinfo_list_length (void)
+{
+ apuinfo_list *entry;
+ unsigned long count;
+
+ for (entry = head, count = 0;
+ entry;
+ entry = entry->next)
+ ++ count;
+
+ return count;
+}
+
+static inline unsigned long
+apuinfo_list_element (unsigned long number)
+{
+ apuinfo_list * entry;
+
+ for (entry = head;
+ entry && number --;
+ entry = entry->next)
+ ;
+
+ return entry ? entry->value : 0;
+}
+
+static void
+apuinfo_list_finish (void)
+{
+ apuinfo_list *entry;
+
+ for (entry = head; entry;)
+ {
+ apuinfo_list *next = entry->next;
+ free (entry);
+ entry = next;
+ }
+
+ head = NULL;
+}
+
+#define APUINFO_SECTION_NAME ".PPC.EMB.apuinfo"
+#define APUINFO_LABEL "APUinfo"
+
+/* Scan the input BFDs and create a linked list of
+ the APUinfo values that will need to be emitted. */
+
+static void
+ppc_elf_begin_write_processing (bfd *abfd, struct bfd_link_info *link_info)
+{
+ bfd *ibfd;
+ asection *asec;
+ char *buffer;
+ unsigned num_input_sections;
+ bfd_size_type output_section_size;
+ unsigned i;
+ unsigned num_entries;
+ unsigned long offset;
+ unsigned long length;
+ const char *error_message = NULL;
+
+ if (link_info == NULL)
+ return;
+
+ /* Scan the input bfds, looking for apuinfo sections. */
+ num_input_sections = 0;
+ output_section_size = 0;
+
+ for (ibfd = link_info->input_bfds; ibfd; ibfd = ibfd->link_next)
+ {
+ asec = bfd_get_section_by_name (ibfd, APUINFO_SECTION_NAME);
+ if (asec)
+ {
+ ++ num_input_sections;
+ output_section_size += asec->_raw_size;
+ }
+ }
+
+ /* We need at least one input sections
+ in order to make merging worthwhile. */
+ if (num_input_sections < 1)
+ return;
+
+ /* Just make sure that the output section exists as well. */
+ asec = bfd_get_section_by_name (abfd, APUINFO_SECTION_NAME);
+ if (asec == NULL)
+ return;
+
+ /* Allocate a buffer for the contents of the input sections. */
+ buffer = bfd_malloc (output_section_size);
+ if (buffer == NULL)
+ return;
+
+ offset = 0;
+ apuinfo_list_init ();
+
+ /* Read in the input sections contents. */
+ for (ibfd = link_info->input_bfds; ibfd; ibfd = ibfd->link_next)
+ {
+ unsigned long datum;
+ char *ptr;
+
+ asec = bfd_get_section_by_name (ibfd, APUINFO_SECTION_NAME);
+ if (asec == NULL)
+ continue;
+
+ length = asec->_raw_size;
+ if (length < 24)
+ {
+ error_message = _("corrupt or empty %s section in %s");
+ goto fail;
+ }
+
+ if (bfd_seek (ibfd, asec->filepos, SEEK_SET) != 0
+ || (bfd_bread (buffer + offset, length, ibfd) != length))
+ {
+ error_message = _("unable to read in %s section from %s");
+ goto fail;
+ }
+
+ /* Process the contents of the section. */
+ ptr = buffer + offset;
+ error_message = _("corrupt %s section in %s");
+
+ /* Verify the contents of the header. Note - we have to
+ extract the values this way in order to allow for a
+ host whose endian-ness is different from the target. */
+ datum = bfd_get_32 (ibfd, ptr);
+ if (datum != sizeof APUINFO_LABEL)
+ goto fail;
+
+ datum = bfd_get_32 (ibfd, ptr + 8);
+ if (datum != 0x2)
+ goto fail;
+
+ if (strcmp (ptr + 12, APUINFO_LABEL) != 0)
+ goto fail;
+
+ /* Get the number of bytes used for apuinfo entries. */
+ datum = bfd_get_32 (ibfd, ptr + 4);
+ if (datum + 20 != length)
+ goto fail;
+
+ /* Make sure that we do not run off the end of the section. */
+ if (offset + length > output_section_size)
+ goto fail;
+
+ /* Scan the apuinfo section, building a list of apuinfo numbers. */
+ for (i = 0; i < datum; i += 4)
+ apuinfo_list_add (bfd_get_32 (ibfd, ptr + 20 + i));
+
+ /* Update the offset. */
+ offset += length;
+ }
+
+ error_message = NULL;
+
+ /* Compute the size of the output section. */
+ num_entries = apuinfo_list_length ();
+ output_section_size = 20 + num_entries * 4;
+
+ asec = bfd_get_section_by_name (abfd, APUINFO_SECTION_NAME);
+
+ if (! bfd_set_section_size (abfd, asec, output_section_size))
+ ibfd = abfd,
+ error_message = _("warning: unable to set size of %s section in %s");
+
+ fail:
+ free (buffer);
+
+ if (error_message)
+ (*_bfd_error_handler) (error_message, APUINFO_SECTION_NAME,
+ bfd_archive_filename (ibfd));
+}
+
+
+/* Prevent the output section from accumulating the input sections'
+ contents. We have already stored this in our linked list structure. */
+
+static bfd_boolean
+ppc_elf_write_section (bfd *abfd ATTRIBUTE_UNUSED,
+ asection *asec,
+ bfd_byte *contents ATTRIBUTE_UNUSED)
+{
+ return (apuinfo_list_length ()
+ && strcmp (asec->name, APUINFO_SECTION_NAME) == 0);
+}
+
+
+/* Finally we can generate the output section. */
+
+static void
+ppc_elf_final_write_processing (bfd *abfd, bfd_boolean linker ATTRIBUTE_UNUSED)
+{
+ bfd_byte *buffer;
+ asection *asec;
+ unsigned i;
+ unsigned num_entries;
+ bfd_size_type length;
+
+ asec = bfd_get_section_by_name (abfd, APUINFO_SECTION_NAME);
+ if (asec == NULL)
+ return;
+
+ if (apuinfo_list_length () == 0)
+ return;
+
+ length = asec->_raw_size;
+ if (length < 20)
+ return;
+
+ buffer = bfd_malloc (length);
+ if (buffer == NULL)
+ {
+ (*_bfd_error_handler)
+ (_("failed to allocate space for new APUinfo section."));
+ return;
+ }
+
+ /* Create the apuinfo header. */
+ num_entries = apuinfo_list_length ();
+ bfd_put_32 (abfd, sizeof APUINFO_LABEL, buffer);
+ bfd_put_32 (abfd, num_entries * 4, buffer + 4);
+ bfd_put_32 (abfd, 0x2, buffer + 8);
+ strcpy (buffer + 12, APUINFO_LABEL);
+
+ length = 20;
+ for (i = 0; i < num_entries; i++)
+ {
+ bfd_put_32 (abfd, apuinfo_list_element (i), buffer + length);
+ length += 4;
+ }
+
+ if (length != asec->_raw_size)
+ (*_bfd_error_handler) (_("failed to compute new APUinfo section."));
+
+ if (! bfd_set_section_contents (abfd, asec, buffer, (file_ptr) 0, length))
+ (*_bfd_error_handler) (_("failed to install new APUinfo section."));
+
+ free (buffer);
+
+ apuinfo_list_finish ();
+}
+
+/* Add extra PPC sections -- Note, for now, make .sbss2 and
+ .PPC.EMB.sbss0 a normal section, and not a bss section so
+ that the linker doesn't crater when trying to make more than
+ 2 sections. */
+
+static struct bfd_elf_special_section const ppc_elf_special_sections[]=
+{
+ { ".tags", 5, 0, SHT_ORDERED, SHF_ALLOC },
+ { ".sdata", 6, -2, SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
+ { ".sbss", 5, -2, SHT_NOBITS, SHF_ALLOC + SHF_WRITE },
+ { ".sdata2", 7, -2, SHT_PROGBITS, SHF_ALLOC },
+ { ".sbss2", 6, -2, SHT_PROGBITS, SHF_ALLOC },
+ { ".PPC.EMB.apuinfo", 16, 0, SHT_NOTE, 0 },
+ { ".PPC.EMB.sdata0", 15, 0, SHT_PROGBITS, SHF_ALLOC },
+ { ".PPC.EMB.sbss0", 14, 0, SHT_PROGBITS, SHF_ALLOC },
+ { ".plt", 4, 0, SHT_NOBITS, SHF_ALLOC + SHF_EXECINSTR },
+ { NULL, 0, 0, 0, 0 }
+};
+
#define TARGET_LITTLE_SYM bfd_elf32_powerpcle_vec
#define TARGET_LITTLE_NAME "elf32-powerpcle"
#define TARGET_BIG_SYM bfd_elf32_powerpc_vec
#define TARGET_BIG_NAME "elf32-powerpc"
#define ELF_ARCH bfd_arch_powerpc
#define ELF_MACHINE_CODE EM_PPC
+#ifdef __QNXTARGET__
+#define ELF_MAXPAGESIZE 0x1000
+#else
#define ELF_MAXPAGESIZE 0x10000
+#endif
#define elf_info_to_howto ppc_elf_info_to_howto
#ifdef EM_CYGNUS_POWERPC
@@ -3815,14 +6173,14 @@ ppc_elf_grok_psinfo (abfd, note)
#define elf_backend_can_gc_sections 1
#define elf_backend_can_refcount 1
#define elf_backend_got_header_size 12
-#define elf_backend_plt_header_size PLT_INITIAL_ENTRY_SIZE
#define elf_backend_rela_normal 1
+#define bfd_elf32_mkobject ppc_elf_mkobject
#define bfd_elf32_bfd_merge_private_bfd_data ppc_elf_merge_private_bfd_data
-#define bfd_elf32_bfd_relax_section ppc_elf_relax_section
+#define bfd_elf32_bfd_relax_section ppc_elf_relax_section
#define bfd_elf32_bfd_reloc_type_lookup ppc_elf_reloc_type_lookup
#define bfd_elf32_bfd_set_private_flags ppc_elf_set_private_flags
-#define bfd_elf32_bfd_final_link _bfd_elf32_gc_common_final_link
+#define bfd_elf32_bfd_link_hash_table_create ppc_elf_link_hash_table_create
#define elf_backend_object_p ppc_elf_object_p
#define elf_backend_gc_mark_hook ppc_elf_gc_mark_hook
@@ -3831,6 +6189,7 @@ ppc_elf_grok_psinfo (abfd, note)
#define elf_backend_relocate_section ppc_elf_relocate_section
#define elf_backend_create_dynamic_sections ppc_elf_create_dynamic_sections
#define elf_backend_check_relocs ppc_elf_check_relocs
+#define elf_backend_copy_indirect_symbol ppc_elf_copy_indirect_symbol
#define elf_backend_adjust_dynamic_symbol ppc_elf_adjust_dynamic_symbol
#define elf_backend_add_symbol_hook ppc_elf_add_symbol_hook
#define elf_backend_size_dynamic_sections ppc_elf_size_dynamic_sections
@@ -3842,5 +6201,9 @@ ppc_elf_grok_psinfo (abfd, note)
#define elf_backend_grok_prstatus ppc_elf_grok_prstatus
#define elf_backend_grok_psinfo ppc_elf_grok_psinfo
#define elf_backend_reloc_type_class ppc_elf_reloc_type_class
+#define elf_backend_begin_write_processing ppc_elf_begin_write_processing
+#define elf_backend_final_write_processing ppc_elf_final_write_processing
+#define elf_backend_write_section ppc_elf_write_section
+#define elf_backend_special_sections ppc_elf_special_sections
#include "elf32-target.h"
diff --git a/contrib/binutils/bfd/elf32-s390.c b/contrib/binutils/bfd/elf32-s390.c
index b7e2189..074c108 100644
--- a/contrib/binutils/bfd/elf32-s390.c
+++ b/contrib/binutils/bfd/elf32-s390.c
@@ -1,5 +1,5 @@
/* IBM S/390-specific support for 32-bit ELF
- Copyright 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
Contributed by Carl B. Pedersen and Martin Schwidefsky.
This file is part of BFD, the Binary File Descriptor library.
@@ -29,50 +29,67 @@ static reloc_howto_type *elf_s390_reloc_type_lookup
PARAMS ((bfd *, bfd_reloc_code_real_type));
static void elf_s390_info_to_howto
PARAMS ((bfd *, arelent *, Elf_Internal_Rela *));
-static boolean elf_s390_is_local_label_name
+static bfd_boolean elf_s390_is_local_label_name
PARAMS ((bfd *, const char *));
static struct bfd_hash_entry *link_hash_newfunc
PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
static struct bfd_link_hash_table *elf_s390_link_hash_table_create
PARAMS ((bfd *));
-static boolean create_got_section
+static bfd_boolean create_got_section
PARAMS((bfd *, struct bfd_link_info *));
-static boolean elf_s390_create_dynamic_sections
+static bfd_boolean elf_s390_create_dynamic_sections
PARAMS((bfd *, struct bfd_link_info *));
static void elf_s390_copy_indirect_symbol
- PARAMS ((struct elf_backend_data *, struct elf_link_hash_entry *,
+ PARAMS ((const struct elf_backend_data *, struct elf_link_hash_entry *,
struct elf_link_hash_entry *));
-static boolean elf_s390_check_relocs
+static bfd_boolean elf_s390_check_relocs
PARAMS ((bfd *, struct bfd_link_info *, asection *,
const Elf_Internal_Rela *));
static asection *elf_s390_gc_mark_hook
PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
struct elf_link_hash_entry *, Elf_Internal_Sym *));
-static boolean elf_s390_gc_sweep_hook
+static bfd_boolean elf_s390_gc_sweep_hook
PARAMS ((bfd *, struct bfd_link_info *, asection *,
const Elf_Internal_Rela *));
-static boolean elf_s390_adjust_dynamic_symbol
+struct elf_s390_link_hash_entry;
+static void elf_s390_adjust_gotplt
+ PARAMS ((struct elf_s390_link_hash_entry *));
+static bfd_boolean elf_s390_adjust_dynamic_symbol
PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *));
-static boolean allocate_dynrelocs
+static bfd_boolean allocate_dynrelocs
PARAMS ((struct elf_link_hash_entry *, PTR));
-static boolean readonly_dynrelocs
+static bfd_boolean readonly_dynrelocs
PARAMS ((struct elf_link_hash_entry *, PTR));
-static boolean elf_s390_size_dynamic_sections
+static bfd_boolean elf_s390_size_dynamic_sections
PARAMS ((bfd *, struct bfd_link_info *));
-static boolean elf_s390_relocate_section
+static bfd_boolean elf_s390_relocate_section
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
Elf_Internal_Rela *, Elf_Internal_Sym *, asection **));
-static boolean elf_s390_finish_dynamic_symbol
+static bfd_boolean elf_s390_finish_dynamic_symbol
PARAMS ((bfd *, struct bfd_link_info *, struct elf_link_hash_entry *,
Elf_Internal_Sym *));
static enum elf_reloc_type_class elf_s390_reloc_type_class
PARAMS ((const Elf_Internal_Rela *));
-static boolean elf_s390_finish_dynamic_sections
+static bfd_boolean elf_s390_finish_dynamic_sections
PARAMS ((bfd *, struct bfd_link_info *));
-static boolean elf_s390_object_p PARAMS ((bfd *));
-static boolean elf_s390_grok_prstatus PARAMS ((bfd *, Elf_Internal_Note *));
-
-#define USE_RELA 1 /* We want RELA relocations, not REL. */
+static bfd_boolean elf_s390_mkobject
+ PARAMS ((bfd *));
+static bfd_boolean elf_s390_object_p
+ PARAMS ((bfd *));
+static bfd_boolean elf_s390_grok_prstatus
+ PARAMS ((bfd *, Elf_Internal_Note *));
+static int elf_s390_tls_transition
+ PARAMS ((struct bfd_link_info *, int, int));
+static bfd_reloc_status_type s390_tls_reloc
+ PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
+static bfd_vma dtpoff_base
+ PARAMS ((struct bfd_link_info *));
+static bfd_vma tpoff
+ PARAMS ((struct bfd_link_info *, bfd_vma));
+static void invalid_tls_insn
+ PARAMS ((bfd *, asection *, Elf_Internal_Rela *));
+static bfd_reloc_status_type s390_elf_ldisp_reloc
+ PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
#include "elf/s390.h"
@@ -84,45 +101,130 @@ static reloc_howto_type elf_howto_table[] =
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_390_NONE", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO(R_390_8, 0, 0, 8, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_8", false, 0,0x000000ff, false),
- HOWTO(R_390_12, 0, 1, 12, false, 0, complain_overflow_dont, bfd_elf_generic_reloc, "R_390_12", false, 0,0x00000fff, false),
- HOWTO(R_390_16, 0, 1, 16, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_16", false, 0,0x0000ffff, false),
- HOWTO(R_390_32, 0, 2, 32, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_32", false, 0,0xffffffff, false),
- HOWTO(R_390_PC32, 0, 2, 32, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_PC32", false, 0,0xffffffff, true),
- HOWTO(R_390_GOT12, 0, 1, 12, false, 0, complain_overflow_dont, bfd_elf_generic_reloc, "R_390_GOT12", false, 0,0x00000fff, false),
- HOWTO(R_390_GOT32, 0, 2, 32, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_GOT32", false, 0,0xffffffff, false),
- HOWTO(R_390_PLT32, 0, 2, 32, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_PLT32", false, 0,0xffffffff, true),
- HOWTO(R_390_COPY, 0, 2, 32, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_COPY", false, 0,0xffffffff, false),
- HOWTO(R_390_GLOB_DAT, 0, 2, 32, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_GLOB_DAT",false, 0,0xffffffff, false),
- HOWTO(R_390_JMP_SLOT, 0, 2, 32, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_JMP_SLOT",false, 0,0xffffffff, false),
- HOWTO(R_390_RELATIVE, 0, 2, 32, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_RELATIVE",false, 0,0xffffffff, false),
- HOWTO(R_390_GOTOFF, 0, 2, 32, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_GOTOFF", false, 0,0xffffffff, false),
- HOWTO(R_390_GOTPC, 0, 2, 32, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_GOTPC", false, 0,0xffffffff, true),
- HOWTO(R_390_GOT16, 0, 1, 16, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_GOT16", false, 0,0x0000ffff, false),
- HOWTO(R_390_PC16, 0, 1, 16, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_PC16", false, 0,0x0000ffff, true),
- HOWTO(R_390_PC16DBL, 1, 1, 16, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_PC16DBL", false, 0,0x0000ffff, true),
- HOWTO(R_390_PLT16DBL, 1, 1, 16, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_PLT16DBL", false, 0,0x0000ffff, true),
- HOWTO(R_390_PC32DBL, 1, 2, 32, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_PC32DBL", false, 0,0xffffffff, true),
- HOWTO(R_390_PLT32DBL, 1, 2, 32, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_PLT32DBL", false, 0,0xffffffff, true),
- HOWTO(R_390_GOTPCDBL, 1, 2, 32, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_GOTPCDBL", false, 0,0xffffffff, true),
- HOWTO(R_390_GOTENT, 1, 2, 32, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_GOTENT", false, 0,0xffffffff, true),
+ FALSE), /* pcrel_offset */
+
+ HOWTO(R_390_8, 0, 0, 8, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_8", FALSE, 0,0x000000ff, FALSE),
+ HOWTO(R_390_12, 0, 1, 12, FALSE, 0, complain_overflow_dont,
+ bfd_elf_generic_reloc, "R_390_12", FALSE, 0,0x00000fff, FALSE),
+ HOWTO(R_390_16, 0, 1, 16, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_16", FALSE, 0,0x0000ffff, FALSE),
+ HOWTO(R_390_32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_32", FALSE, 0,0xffffffff, FALSE),
+ HOWTO(R_390_PC32, 0, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PC32", FALSE, 0,0xffffffff, TRUE),
+ HOWTO(R_390_GOT12, 0, 1, 12, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOT12", FALSE, 0,0x00000fff, FALSE),
+ HOWTO(R_390_GOT32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOT32", FALSE, 0,0xffffffff, FALSE),
+ HOWTO(R_390_PLT32, 0, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PLT32", FALSE, 0,0xffffffff, TRUE),
+ HOWTO(R_390_COPY, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_COPY", FALSE, 0,0xffffffff, FALSE),
+ HOWTO(R_390_GLOB_DAT, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GLOB_DAT", FALSE, 0,0xffffffff, FALSE),
+ HOWTO(R_390_JMP_SLOT, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_JMP_SLOT", FALSE, 0,0xffffffff, FALSE),
+ HOWTO(R_390_RELATIVE, 0, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_RELATIVE", FALSE, 0,0xffffffff, FALSE),
+ HOWTO(R_390_GOTOFF32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTOFF32", FALSE, 0,0xffffffff, FALSE),
+ HOWTO(R_390_GOTPC, 0, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTPC", FALSE, 0,0xffffffff, TRUE),
+ HOWTO(R_390_GOT16, 0, 1, 16, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOT16", FALSE, 0,0x0000ffff, FALSE),
+ HOWTO(R_390_PC16, 0, 1, 16, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PC16", FALSE, 0,0x0000ffff, TRUE),
+ HOWTO(R_390_PC16DBL, 1, 1, 16, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PC16DBL", FALSE, 0,0x0000ffff, TRUE),
+ HOWTO(R_390_PLT16DBL, 1, 1, 16, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PLT16DBL", FALSE, 0,0x0000ffff, TRUE),
+ HOWTO(R_390_PC32DBL, 1, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PC32DBL", FALSE, 0,0xffffffff, TRUE),
+ HOWTO(R_390_PLT32DBL, 1, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PLT32DBL", FALSE, 0,0xffffffff, TRUE),
+ HOWTO(R_390_GOTPCDBL, 1, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTPCDBL", FALSE, 0,0xffffffff, TRUE),
+ EMPTY_HOWTO (R_390_64), /* Empty entry for R_390_64. */
+ EMPTY_HOWTO (R_390_PC64), /* Empty entry for R_390_PC64. */
+ EMPTY_HOWTO (R_390_GOT64), /* Empty entry for R_390_GOT64. */
+ EMPTY_HOWTO (R_390_PLT64), /* Empty entry for R_390_PLT64. */
+ HOWTO(R_390_GOTENT, 1, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTENT", FALSE, 0,0xffffffff, TRUE),
+ HOWTO(R_390_GOTOFF16, 0, 1, 16, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTOFF16", FALSE, 0,0x0000ffff, FALSE),
+ EMPTY_HOWTO (R_390_GOTOFF64), /* Empty entry for R_390_GOTOFF64. */
+ HOWTO(R_390_GOTPLT12, 0, 1, 12, FALSE, 0, complain_overflow_dont,
+ bfd_elf_generic_reloc, "R_390_GOTPLT12", FALSE, 0,0x00000fff, FALSE),
+ HOWTO(R_390_GOTPLT16, 0, 1, 16, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTPLT16", FALSE, 0,0x0000ffff, FALSE),
+ HOWTO(R_390_GOTPLT32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTPLT32", FALSE, 0,0xffffffff, FALSE),
+ EMPTY_HOWTO (R_390_GOTPLT64), /* Empty entry for R_390_GOTPLT64. */
+ HOWTO(R_390_GOTPLTENT, 1, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTPLTENT",FALSE, 0,0xffffffff, TRUE),
+ HOWTO(R_390_PLTOFF16, 0, 1, 16, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PLTOFF16", FALSE, 0,0x0000ffff, FALSE),
+ HOWTO(R_390_PLTOFF32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PLTOFF32", FALSE, 0,0xffffffff, FALSE),
+ EMPTY_HOWTO (R_390_PLTOFF64), /* Empty entry for R_390_PLTOFF64. */
+ HOWTO(R_390_TLS_LOAD, 0, 0, 0, FALSE, 0, complain_overflow_dont,
+ s390_tls_reloc, "R_390_TLS_LOAD", FALSE, 0, 0, FALSE),
+ HOWTO(R_390_TLS_GDCALL, 0, 0, 0, FALSE, 0, complain_overflow_dont,
+ s390_tls_reloc, "R_390_TLS_GDCALL", FALSE, 0, 0, FALSE),
+ HOWTO(R_390_TLS_LDCALL, 0, 0, 0, FALSE, 0, complain_overflow_dont,
+ s390_tls_reloc, "R_390_TLS_LDCALL", FALSE, 0, 0, FALSE),
+ HOWTO(R_390_TLS_GD32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_GD32", FALSE, 0, 0xffffffff, FALSE),
+ EMPTY_HOWTO (R_390_TLS_GD64), /* Empty entry for R_390_TLS_GD64. */
+ HOWTO(R_390_TLS_GOTIE12, 0, 1, 12, FALSE, 0, complain_overflow_dont,
+ bfd_elf_generic_reloc, "R_390_TLS_GOTIE12", FALSE, 0, 0x00000fff, FALSE),
+ HOWTO(R_390_TLS_GOTIE32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_GOTIE32", FALSE, 0, 0xffffffff, FALSE),
+ EMPTY_HOWTO (R_390_TLS_GOTIE64), /* Empty entry for R_390_TLS_GOTIE64. */
+ HOWTO(R_390_TLS_LDM32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_LDM32", FALSE, 0, 0xffffffff, FALSE),
+ EMPTY_HOWTO (R_390_TLS_LDM64), /* Empty entry for R_390_TLS_LDM64. */
+ HOWTO(R_390_TLS_IE32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_IE32", FALSE, 0, 0xffffffff, FALSE),
+ EMPTY_HOWTO (R_390_TLS_IE64), /* Empty entry for R_390_TLS_IE64. */
+ HOWTO(R_390_TLS_IEENT, 1, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_IEENT", FALSE, 0, 0xffffffff, TRUE),
+ HOWTO(R_390_TLS_LE32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_LE32", FALSE, 0, 0xffffffff, FALSE),
+ EMPTY_HOWTO (R_390_TLS_LE64), /* Empty entry for R_390_TLS_LE64. */
+ HOWTO(R_390_TLS_LDO32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_LDO32", FALSE, 0, 0xffffffff, FALSE),
+ EMPTY_HOWTO (R_390_TLS_LDO64), /* Empty entry for R_390_TLS_LDO64. */
+ HOWTO(R_390_TLS_DTPMOD, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_DTPMOD", FALSE, 0, 0xffffffff, FALSE),
+ HOWTO(R_390_TLS_DTPOFF, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_DTPOFF", FALSE, 0, 0xffffffff, FALSE),
+ HOWTO(R_390_TLS_TPOFF, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_TPOFF", FALSE, 0, 0xffffffff, FALSE),
+ HOWTO(R_390_20, 0, 2, 20, FALSE, 8, complain_overflow_dont,
+ s390_elf_ldisp_reloc, "R_390_20", FALSE, 0,0x0fffff00, FALSE),
+ HOWTO(R_390_GOT20, 0, 2, 20, FALSE, 8, complain_overflow_dont,
+ s390_elf_ldisp_reloc, "R_390_GOT20", FALSE, 0,0x0fffff00, FALSE),
+ HOWTO(R_390_GOTPLT20, 0, 2, 20, FALSE, 8, complain_overflow_dont,
+ s390_elf_ldisp_reloc, "R_390_GOTPLT20", FALSE, 0,0x0fffff00, FALSE),
+ HOWTO(R_390_TLS_GOTIE20, 0, 2, 20, FALSE, 8, complain_overflow_dont,
+ s390_elf_ldisp_reloc, "R_390_TLS_GOTIE20", FALSE, 0,0x0fffff00, FALSE),
};
/* GNU extension to record C++ vtable hierarchy. */
static reloc_howto_type elf32_s390_vtinherit_howto =
- HOWTO (R_390_GNU_VTINHERIT, 0,2,0,false,0,complain_overflow_dont, NULL, "R_390_GNU_VTINHERIT", false,0, 0, false);
+ HOWTO (R_390_GNU_VTINHERIT, 0,2,0,FALSE,0,complain_overflow_dont, NULL, "R_390_GNU_VTINHERIT", FALSE,0, 0, FALSE);
static reloc_howto_type elf32_s390_vtentry_howto =
- HOWTO (R_390_GNU_VTENTRY, 0,2,0,false,0,complain_overflow_dont, _bfd_elf_rel_vtable_reloc_fn,"R_390_GNU_VTENTRY", false,0,0, false);
+ HOWTO (R_390_GNU_VTENTRY, 0,2,0,FALSE,0,complain_overflow_dont, _bfd_elf_rel_vtable_reloc_fn,"R_390_GNU_VTENTRY", FALSE,0,0, FALSE);
static reloc_howto_type *
elf_s390_reloc_type_lookup (abfd, code)
@@ -160,7 +262,7 @@ elf_s390_reloc_type_lookup (abfd, code)
case BFD_RELOC_390_RELATIVE:
return &elf_howto_table[(int) R_390_RELATIVE];
case BFD_RELOC_32_GOTOFF:
- return &elf_howto_table[(int) R_390_GOTOFF];
+ return &elf_howto_table[(int) R_390_GOTOFF32];
case BFD_RELOC_390_GOTPC:
return &elf_howto_table[(int) R_390_GOTPC];
case BFD_RELOC_390_GOT16:
@@ -179,6 +281,56 @@ elf_s390_reloc_type_lookup (abfd, code)
return &elf_howto_table[(int) R_390_GOTPCDBL];
case BFD_RELOC_390_GOTENT:
return &elf_howto_table[(int) R_390_GOTENT];
+ case BFD_RELOC_16_GOTOFF:
+ return &elf_howto_table[(int) R_390_GOTOFF16];
+ case BFD_RELOC_390_GOTPLT12:
+ return &elf_howto_table[(int) R_390_GOTPLT12];
+ case BFD_RELOC_390_GOTPLT16:
+ return &elf_howto_table[(int) R_390_GOTPLT16];
+ case BFD_RELOC_390_GOTPLT32:
+ return &elf_howto_table[(int) R_390_GOTPLT32];
+ case BFD_RELOC_390_GOTPLTENT:
+ return &elf_howto_table[(int) R_390_GOTPLTENT];
+ case BFD_RELOC_390_PLTOFF16:
+ return &elf_howto_table[(int) R_390_PLTOFF16];
+ case BFD_RELOC_390_PLTOFF32:
+ return &elf_howto_table[(int) R_390_PLTOFF32];
+ case BFD_RELOC_390_TLS_LOAD:
+ return &elf_howto_table[(int) R_390_TLS_LOAD];
+ case BFD_RELOC_390_TLS_GDCALL:
+ return &elf_howto_table[(int) R_390_TLS_GDCALL];
+ case BFD_RELOC_390_TLS_LDCALL:
+ return &elf_howto_table[(int) R_390_TLS_LDCALL];
+ case BFD_RELOC_390_TLS_GD32:
+ return &elf_howto_table[(int) R_390_TLS_GD32];
+ case BFD_RELOC_390_TLS_GOTIE12:
+ return &elf_howto_table[(int) R_390_TLS_GOTIE12];
+ case BFD_RELOC_390_TLS_GOTIE32:
+ return &elf_howto_table[(int) R_390_TLS_GOTIE32];
+ case BFD_RELOC_390_TLS_LDM32:
+ return &elf_howto_table[(int) R_390_TLS_LDM32];
+ case BFD_RELOC_390_TLS_IE32:
+ return &elf_howto_table[(int) R_390_TLS_IE32];
+ case BFD_RELOC_390_TLS_IEENT:
+ return &elf_howto_table[(int) R_390_TLS_IEENT];
+ case BFD_RELOC_390_TLS_LE32:
+ return &elf_howto_table[(int) R_390_TLS_LE32];
+ case BFD_RELOC_390_TLS_LDO32:
+ return &elf_howto_table[(int) R_390_TLS_LDO32];
+ case BFD_RELOC_390_TLS_DTPMOD:
+ return &elf_howto_table[(int) R_390_TLS_DTPMOD];
+ case BFD_RELOC_390_TLS_DTPOFF:
+ return &elf_howto_table[(int) R_390_TLS_DTPOFF];
+ case BFD_RELOC_390_TLS_TPOFF:
+ return &elf_howto_table[(int) R_390_TLS_TPOFF];
+ case BFD_RELOC_390_20:
+ return &elf_howto_table[(int) R_390_20];
+ case BFD_RELOC_390_GOT20:
+ return &elf_howto_table[(int) R_390_GOT20];
+ case BFD_RELOC_390_GOTPLT20:
+ return &elf_howto_table[(int) R_390_GOTPLT20];
+ case BFD_RELOC_390_TLS_GOTIE20:
+ return &elf_howto_table[(int) R_390_TLS_GOTIE20];
case BFD_RELOC_VTABLE_INHERIT:
return &elf32_s390_vtinherit_howto;
case BFD_RELOC_VTABLE_ENTRY:
@@ -214,13 +366,83 @@ elf_s390_info_to_howto (abfd, cache_ptr, dst)
}
}
-static boolean
+/* A relocation function which doesn't do anything. */
+static bfd_reloc_status_type
+s390_tls_reloc (abfd, reloc_entry, symbol, data, input_section,
+ output_bfd, error_message)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ arelent *reloc_entry;
+ asymbol *symbol ATTRIBUTE_UNUSED;
+ PTR data ATTRIBUTE_UNUSED;
+ asection *input_section;
+ bfd *output_bfd;
+ char **error_message ATTRIBUTE_UNUSED;
+{
+ if (output_bfd)
+ reloc_entry->address += input_section->output_offset;
+ return bfd_reloc_ok;
+}
+
+/* Handle the large displacement relocs. */
+static bfd_reloc_status_type
+s390_elf_ldisp_reloc (abfd, reloc_entry, symbol, data, input_section,
+ output_bfd, error_message)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ arelent *reloc_entry;
+ asymbol *symbol;
+ PTR data ATTRIBUTE_UNUSED;
+ asection *input_section;
+ bfd *output_bfd;
+ char **error_message ATTRIBUTE_UNUSED;
+{
+ reloc_howto_type *howto = reloc_entry->howto;
+ bfd_vma relocation;
+ bfd_vma insn;
+
+ if (output_bfd != (bfd *) NULL
+ && (symbol->flags & BSF_SECTION_SYM) == 0
+ && (! howto->partial_inplace
+ || reloc_entry->addend == 0))
+ {
+ reloc_entry->address += input_section->output_offset;
+ return bfd_reloc_ok;
+ }
+
+ if (output_bfd != NULL)
+ return bfd_reloc_continue;
+
+ if (reloc_entry->address > input_section->_cooked_size)
+ return bfd_reloc_outofrange;
+
+ relocation = (symbol->value
+ + symbol->section->output_section->vma
+ + symbol->section->output_offset);
+ relocation += reloc_entry->addend;
+ if (howto->pc_relative)
+ {
+ relocation -= (input_section->output_section->vma
+ + input_section->output_offset);
+ relocation -= reloc_entry->address;
+ }
+
+ insn = bfd_get_32 (abfd, (bfd_byte *) data + reloc_entry->address);
+ insn |= (relocation & 0xfff) << 16 | (relocation & 0xff000) >> 4;
+ bfd_put_32 (abfd, insn, (bfd_byte *) data + reloc_entry->address);
+
+ if ((bfd_signed_vma) relocation < - 0x80000
+ || (bfd_signed_vma) relocation > 0x7ffff)
+ return bfd_reloc_overflow;
+ else
+ return bfd_reloc_ok;
+}
+
+static bfd_boolean
elf_s390_is_local_label_name (abfd, name)
bfd *abfd;
const char *name;
{
if (name[0] == '.' && (name[1] == 'X' || name[1] == 'L'))
- return true;
+ return TRUE;
return _bfd_elf_is_local_label_name (abfd, name);
}
@@ -232,6 +454,12 @@ elf_s390_is_local_label_name (abfd, name)
#define ELF_DYNAMIC_INTERPRETER "/usr/lib/ld.so.1"
+/* If ELIMINATE_COPY_RELOCS is non-zero, the linker will try to avoid
+ copying dynamic variables from a shared lib into an app's dynbss
+ section, and instead use a dynamic relocation to point into the
+ shared lib. */
+#define ELIMINATE_COPY_RELOCS 1
+
/* The size in bytes of the first entry in the procedure linkage table. */
#define PLT_FIRST_ENTRY_SIZE 32
/* The size in bytes of an entry in the procedure linkage table. */
@@ -256,7 +484,7 @@ elf_s390_is_local_label_name (abfd, name)
Word 1 is a pointer to a structure describing the object
Word 2 is used to point to the loader entry address.
- The code for position independand PLT entries looks like this:
+ The code for position independent PLT entries looks like this:
r12 holds addr of the current GOT at entry to the PLT
@@ -413,8 +641,54 @@ struct elf_s390_link_hash_entry
/* Track dynamic relocs copied for this symbol. */
struct elf_s390_dyn_relocs *dyn_relocs;
+
+ /* Number of GOTPLT references for a function. */
+ bfd_signed_vma gotplt_refcount;
+
+#define GOT_UNKNOWN 0
+#define GOT_NORMAL 1
+#define GOT_TLS_GD 2
+#define GOT_TLS_IE 3
+#define GOT_TLS_IE_NLT 4
+ unsigned char tls_type;
};
+#define elf_s390_hash_entry(ent) \
+ ((struct elf_s390_link_hash_entry *)(ent))
+
+struct elf_s390_obj_tdata
+{
+ struct elf_obj_tdata root;
+
+ /* tls_type for each local got entry. */
+ char *local_got_tls_type;
+};
+
+#define elf_s390_tdata(abfd) \
+ ((struct elf_s390_obj_tdata *) (abfd)->tdata.any)
+
+#define elf_s390_local_got_tls_type(abfd) \
+ (elf_s390_tdata (abfd)->local_got_tls_type)
+
+static bfd_boolean
+elf_s390_mkobject (abfd)
+ bfd *abfd;
+{
+ bfd_size_type amt = sizeof (struct elf_s390_obj_tdata);
+ abfd->tdata.any = bfd_zalloc (abfd, amt);
+ if (abfd->tdata.any == NULL)
+ return FALSE;
+ return TRUE;
+}
+
+static bfd_boolean
+elf_s390_object_p (abfd)
+ bfd *abfd;
+{
+ /* Set the right machine number for an s390 elf32 file. */
+ return bfd_default_set_arch_mach (abfd, bfd_arch_s390, bfd_mach_s390_31);
+}
+
/* s390 ELF linker hash table. */
struct elf_s390_link_hash_table
@@ -430,6 +704,11 @@ struct elf_s390_link_hash_table
asection *sdynbss;
asection *srelbss;
+ union {
+ bfd_signed_vma refcount;
+ bfd_vma offset;
+ } tls_ldm_got;
+
/* Small local sym to section mapping cache. */
struct sym_sec_cache sym_sec;
};
@@ -465,6 +744,8 @@ link_hash_newfunc (entry, table, string)
eh = (struct elf_s390_link_hash_entry *) entry;
eh->dyn_relocs = NULL;
+ eh->gotplt_refcount = 0;
+ eh->tls_type = GOT_UNKNOWN;
}
return entry;
@@ -496,6 +777,7 @@ elf_s390_link_hash_table_create (abfd)
ret->srelplt = NULL;
ret->sdynbss = NULL;
ret->srelbss = NULL;
+ ret->tls_ldm_got.refcount = 0;
ret->sym_sec.abfd = NULL;
return &ret->elf.root;
@@ -504,7 +786,7 @@ elf_s390_link_hash_table_create (abfd)
/* Create .got, .gotplt, and .rela.got sections in DYNOBJ, and set up
shortcuts to them in our hash table. */
-static boolean
+static bfd_boolean
create_got_section (dynobj, info)
bfd *dynobj;
struct bfd_link_info *info;
@@ -512,7 +794,7 @@ create_got_section (dynobj, info)
struct elf_s390_link_hash_table *htab;
if (! _bfd_elf_create_got_section (dynobj, info))
- return false;
+ return FALSE;
htab = elf_s390_hash_table (info);
htab->sgot = bfd_get_section_by_name (dynobj, ".got");
@@ -527,15 +809,15 @@ create_got_section (dynobj, info)
| SEC_IN_MEMORY | SEC_LINKER_CREATED
| SEC_READONLY))
|| ! bfd_set_section_alignment (dynobj, htab->srelgot, 2))
- return false;
- return true;
+ return FALSE;
+ return TRUE;
}
/* Create .plt, .rela.plt, .got, .got.plt, .rela.got, .dynbss, and
.rela.bss sections in DYNOBJ, and set up shortcuts to them in our
hash table. */
-static boolean
+static bfd_boolean
elf_s390_create_dynamic_sections (dynobj, info)
bfd *dynobj;
struct bfd_link_info *info;
@@ -544,10 +826,10 @@ elf_s390_create_dynamic_sections (dynobj, info)
htab = elf_s390_hash_table (info);
if (!htab->sgot && !create_got_section (dynobj, info))
- return false;
+ return FALSE;
if (!_bfd_elf_create_dynamic_sections (dynobj, info))
- return false;
+ return FALSE;
htab->splt = bfd_get_section_by_name (dynobj, ".plt");
htab->srelplt = bfd_get_section_by_name (dynobj, ".rela.plt");
@@ -559,14 +841,14 @@ elf_s390_create_dynamic_sections (dynobj, info)
|| (!info->shared && !htab->srelbss))
abort ();
- return true;
+ return TRUE;
}
/* Copy the extra info we tack onto an elf_link_hash_entry. */
static void
elf_s390_copy_indirect_symbol (bed, dir, ind)
- struct elf_backend_data *bed;
+ const struct elf_backend_data *bed;
struct elf_link_hash_entry *dir, *ind;
{
struct elf_s390_link_hash_entry *edir, *eind;
@@ -608,14 +890,60 @@ elf_s390_copy_indirect_symbol (bed, dir, ind)
eind->dyn_relocs = NULL;
}
- _bfd_elf_link_hash_copy_indirect (bed, dir, ind);
+ if (ind->root.type == bfd_link_hash_indirect
+ && dir->got.refcount <= 0)
+ {
+ edir->tls_type = eind->tls_type;
+ eind->tls_type = GOT_UNKNOWN;
+ }
+
+ if (ELIMINATE_COPY_RELOCS
+ && ind->root.type != bfd_link_hash_indirect
+ && (dir->elf_link_hash_flags & ELF_LINK_HASH_DYNAMIC_ADJUSTED) != 0)
+ /* If called to transfer flags for a weakdef during processing
+ of elf_adjust_dynamic_symbol, don't copy ELF_LINK_NON_GOT_REF.
+ We clear it ourselves for ELIMINATE_COPY_RELOCS. */
+ dir->elf_link_hash_flags |=
+ (ind->elf_link_hash_flags & (ELF_LINK_HASH_REF_DYNAMIC
+ | ELF_LINK_HASH_REF_REGULAR
+ | ELF_LINK_HASH_REF_REGULAR_NONWEAK
+ | ELF_LINK_HASH_NEEDS_PLT));
+ else
+ _bfd_elf_link_hash_copy_indirect (bed, dir, ind);
+}
+
+static int
+elf_s390_tls_transition (info, r_type, is_local)
+ struct bfd_link_info *info;
+ int r_type;
+ int is_local;
+{
+ if (info->shared)
+ return r_type;
+
+ switch (r_type)
+ {
+ case R_390_TLS_GD32:
+ case R_390_TLS_IE32:
+ if (is_local)
+ return R_390_TLS_LE32;
+ return R_390_TLS_IE32;
+ case R_390_TLS_GOTIE32:
+ if (is_local)
+ return R_390_TLS_LE32;
+ return R_390_TLS_GOTIE32;
+ case R_390_TLS_LDM32:
+ return R_390_TLS_LE32;
+ }
+
+ return r_type;
}
/* Look through the relocs for a section during the first phase, and
allocate space in the global offset table or procedure linkage
table. */
-static boolean
+static bfd_boolean
elf_s390_check_relocs (abfd, info, sec, relocs)
bfd *abfd;
struct bfd_link_info *info;
@@ -628,19 +956,23 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
const Elf_Internal_Rela *rel;
const Elf_Internal_Rela *rel_end;
asection *sreloc;
+ bfd_signed_vma *local_got_refcounts;
+ int tls_type, old_tls_type;
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
htab = elf_s390_hash_table (info);
symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
sym_hashes = elf_sym_hashes (abfd);
+ local_got_refcounts = elf_local_got_refcounts (abfd);
sreloc = NULL;
rel_end = relocs + sec->reloc_count;
for (rel = relocs; rel < rel_end; rel++)
{
+ unsigned int r_type;
unsigned long r_symndx;
struct elf_link_hash_entry *h;
@@ -651,7 +983,7 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
(*_bfd_error_handler) (_("%s: bad symbol index: %d"),
bfd_archive_filename (abfd),
r_symndx);
- return false;
+ return FALSE;
}
if (r_symndx < symtab_hdr->sh_info)
@@ -659,40 +991,48 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
else
h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- switch (ELF32_R_TYPE (rel->r_info))
+ /* Create got section and local_got_refcounts array if they
+ are needed. */
+ r_type = elf_s390_tls_transition (info,
+ ELF32_R_TYPE (rel->r_info),
+ h == NULL);
+ switch (r_type)
{
case R_390_GOT12:
- case R_390_GOT16:
+ case R_390_GOT16:
+ case R_390_GOT20:
case R_390_GOT32:
case R_390_GOTENT:
- /* This symbol requires a global offset table entry. */
- if (h != NULL)
- {
- h->got.refcount += 1;
- }
- else
+ case R_390_GOTPLT12:
+ case R_390_GOTPLT16:
+ case R_390_GOTPLT20:
+ case R_390_GOTPLT32:
+ case R_390_GOTPLTENT:
+ case R_390_TLS_GD32:
+ case R_390_TLS_GOTIE12:
+ case R_390_TLS_GOTIE20:
+ case R_390_TLS_GOTIE32:
+ case R_390_TLS_IEENT:
+ case R_390_TLS_IE32:
+ case R_390_TLS_LDM32:
+ if (h == NULL
+ && local_got_refcounts == NULL)
{
- bfd_signed_vma *local_got_refcounts;
+ bfd_size_type size;
- /* This is a global offset table entry for a local symbol. */
- local_got_refcounts = elf_local_got_refcounts (abfd);
+ size = symtab_hdr->sh_info;
+ size *= (sizeof (bfd_signed_vma) + sizeof(char));
+ local_got_refcounts = ((bfd_signed_vma *)
+ bfd_zalloc (abfd, size));
if (local_got_refcounts == NULL)
- {
- bfd_size_type size;
-
- size = symtab_hdr->sh_info;
- size *= sizeof (bfd_signed_vma);
- local_got_refcounts = ((bfd_signed_vma *)
- bfd_zalloc (abfd, size));
- if (local_got_refcounts == NULL)
- return false;
- elf_local_got_refcounts (abfd) = local_got_refcounts;
- }
- local_got_refcounts[r_symndx] += 1;
+ return FALSE;
+ elf_local_got_refcounts (abfd) = local_got_refcounts;
+ elf_s390_local_got_tls_type (abfd)
+ = (char *) (local_got_refcounts + symtab_hdr->sh_info);
}
- /* Fall through */
-
- case R_390_GOTOFF:
+ /* Fall through. */
+ case R_390_GOTOFF16:
+ case R_390_GOTOFF32:
case R_390_GOTPC:
case R_390_GOTPCDBL:
if (htab->sgot == NULL)
@@ -700,34 +1040,155 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
if (htab->elf.dynobj == NULL)
htab->elf.dynobj = abfd;
if (!create_got_section (htab->elf.dynobj, info))
- return false;
+ return FALSE;
}
+ }
+
+ switch (r_type)
+ {
+ case R_390_GOTOFF16:
+ case R_390_GOTOFF32:
+ case R_390_GOTPC:
+ case R_390_GOTPCDBL:
+ /* Got is created, nothing to be done. */
break;
- case R_390_PLT16DBL:
- case R_390_PLT32DBL:
+ case R_390_PLT16DBL:
+ case R_390_PLT32DBL:
case R_390_PLT32:
+ case R_390_PLTOFF16:
+ case R_390_PLTOFF32:
/* This symbol requires a procedure linkage table entry. We
- actually build the entry in adjust_dynamic_symbol,
- because this might be a case of linking PIC code which is
- never referenced by a dynamic object, in which case we
- don't need to generate a procedure linkage table entry
- after all. */
+ actually build the entry in adjust_dynamic_symbol,
+ because this might be a case of linking PIC code which is
+ never referenced by a dynamic object, in which case we
+ don't need to generate a procedure linkage table entry
+ after all. */
/* If this is a local symbol, we resolve it directly without
- creating a procedure linkage table entry. */
- if (h == NULL)
- continue;
+ creating a procedure linkage table entry. */
+ if (h != NULL)
+ {
+ h->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_PLT;
+ h->plt.refcount += 1;
+ }
+ break;
- h->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_PLT;
- h->plt.refcount += 1;
+ case R_390_GOTPLT12:
+ case R_390_GOTPLT16:
+ case R_390_GOTPLT20:
+ case R_390_GOTPLT32:
+ case R_390_GOTPLTENT:
+ /* This symbol requires either a procedure linkage table entry
+ or an entry in the local got. We actually build the entry
+ in adjust_dynamic_symbol because whether this is really a
+ global reference can change and with it the fact if we have
+ to create a plt entry or a local got entry. To be able to
+ make a once global symbol a local one we have to keep track
+ of the number of gotplt references that exist for this
+ symbol. */
+ if (h != NULL)
+ {
+ ((struct elf_s390_link_hash_entry *) h)->gotplt_refcount++;
+ h->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_PLT;
+ h->plt.refcount += 1;
+ }
+ else
+ local_got_refcounts[r_symndx] += 1;
+ break;
+
+ case R_390_TLS_LDM32:
+ htab->tls_ldm_got.refcount += 1;
break;
- case R_390_8:
- case R_390_16:
+ case R_390_TLS_IE32:
+ case R_390_TLS_GOTIE12:
+ case R_390_TLS_GOTIE20:
+ case R_390_TLS_GOTIE32:
+ case R_390_TLS_IEENT:
+ if (info->shared)
+ info->flags |= DF_STATIC_TLS;
+ /* Fall through. */
+
+ case R_390_GOT12:
+ case R_390_GOT16:
+ case R_390_GOT20:
+ case R_390_GOT32:
+ case R_390_GOTENT:
+ case R_390_TLS_GD32:
+ /* This symbol requires a global offset table entry. */
+ switch (r_type)
+ {
+ default:
+ case R_390_GOT12:
+ case R_390_GOT16:
+ case R_390_GOT20:
+ case R_390_GOT32:
+ case R_390_GOTENT:
+ tls_type = GOT_NORMAL;
+ break;
+ case R_390_TLS_GD32:
+ tls_type = GOT_TLS_GD;
+ break;
+ case R_390_TLS_IE32:
+ case R_390_TLS_GOTIE32:
+ tls_type = GOT_TLS_IE;
+ break;
+ case R_390_TLS_GOTIE12:
+ case R_390_TLS_GOTIE20:
+ case R_390_TLS_IEENT:
+ tls_type = GOT_TLS_IE_NLT;
+ break;
+ }
+
+ if (h != NULL)
+ {
+ h->got.refcount += 1;
+ old_tls_type = elf_s390_hash_entry(h)->tls_type;
+ }
+ else
+ {
+ local_got_refcounts[r_symndx] += 1;
+ old_tls_type = elf_s390_local_got_tls_type (abfd) [r_symndx];
+ }
+ /* If a TLS symbol is accessed using IE at least once,
+ there is no point to use dynamic model for it. */
+ if (old_tls_type != tls_type && old_tls_type != GOT_UNKNOWN)
+ {
+ if (old_tls_type == GOT_NORMAL || tls_type == GOT_NORMAL)
+ {
+ (*_bfd_error_handler)
+ (_("%s: `%s' accessed both as normal and thread local symbol"),
+ bfd_archive_filename (abfd), h->root.root.string);
+ return FALSE;
+ }
+ if (old_tls_type > tls_type)
+ tls_type = old_tls_type;
+ }
+
+ if (old_tls_type != tls_type)
+ {
+ if (h != NULL)
+ elf_s390_hash_entry (h)->tls_type = tls_type;
+ else
+ elf_s390_local_got_tls_type (abfd) [r_symndx] = tls_type;
+ }
+
+ if (r_type != R_390_TLS_IE32)
+ break;
+ /* Fall through. */
+
+ case R_390_TLS_LE32:
+ if (!info->shared)
+ break;
+ info->flags |= DF_STATIC_TLS;
+ /* Fall through. */
+
+ case R_390_8:
+ case R_390_16:
case R_390_32:
- case R_390_PC16:
- case R_390_PC16DBL:
+ case R_390_PC16:
+ case R_390_PC16DBL:
case R_390_PC32DBL:
case R_390_PC32:
if (h != NULL && !info->shared)
@@ -777,7 +1238,8 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
|| h->root.type == bfd_link_hash_defweak
|| (h->elf_link_hash_flags
& ELF_LINK_HASH_DEF_REGULAR) == 0))))
- || (!info->shared
+ || (ELIMINATE_COPY_RELOCS
+ && !info->shared
&& (sec->flags & SEC_ALLOC) != 0
&& h != NULL
&& (h->root.type == bfd_link_hash_defweak
@@ -800,7 +1262,7 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
elf_elfheader (abfd)->e_shstrndx,
elf_section_data (sec)->rel_hdr.sh_name));
if (name == NULL)
- return false;
+ return FALSE;
if (strncmp (name, ".rela", 5) != 0
|| strcmp (bfd_get_section_name (abfd, sec),
@@ -828,7 +1290,7 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
if (sreloc == NULL
|| ! bfd_set_section_flags (dynobj, sreloc, flags)
|| ! bfd_set_section_alignment (dynobj, sreloc, 2))
- return false;
+ return FALSE;
}
elf_section_data (sec)->sreloc = sreloc;
}
@@ -844,12 +1306,12 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
/* Track dynamic relocs needed for local syms too.
We really need local syms available to do this
easily. Oh well. */
-
asection *s;
+
s = bfd_section_from_r_symndx (abfd, &htab->sym_sec,
sec, r_symndx);
if (s == NULL)
- return false;
+ return FALSE;
head = ((struct elf_s390_dyn_relocs **)
&elf_section_data (s)->local_dynrel);
@@ -859,10 +1321,11 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
if (p == NULL || p->sec != sec)
{
bfd_size_type amt = sizeof *p;
+
p = ((struct elf_s390_dyn_relocs *)
bfd_alloc (htab->elf.dynobj, amt));
if (p == NULL)
- return false;
+ return FALSE;
p->next = *head;
*head = p;
p->sec = sec;
@@ -881,24 +1344,24 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
/* This relocation describes the C++ object vtable hierarchy.
Reconstruct it for later use during GC. */
- case R_390_GNU_VTINHERIT:
- if (!_bfd_elf32_gc_record_vtinherit (abfd, sec, h, rel->r_offset))
- return false;
- break;
+ case R_390_GNU_VTINHERIT:
+ if (!bfd_elf_gc_record_vtinherit (abfd, sec, h, rel->r_offset))
+ return FALSE;
+ break;
/* This relocation describes which C++ vtable entries are actually
used. Record for later use during GC. */
- case R_390_GNU_VTENTRY:
- if (!_bfd_elf32_gc_record_vtentry (abfd, sec, h, rel->r_addend))
- return false;
- break;
+ case R_390_GNU_VTENTRY:
+ if (!bfd_elf_gc_record_vtentry (abfd, sec, h, rel->r_addend))
+ return FALSE;
+ break;
default:
break;
}
}
- return true;
+ return TRUE;
}
/* Return the section that should be marked against GC for a given
@@ -943,7 +1406,7 @@ elf_s390_gc_mark_hook (sec, info, rel, h, sym)
/* Update the got entry reference counts for the section being removed. */
-static boolean
+static bfd_boolean
elf_s390_gc_sweep_hook (abfd, info, sec, relocs)
bfd *abfd;
struct bfd_link_info *info;
@@ -954,8 +1417,6 @@ elf_s390_gc_sweep_hook (abfd, info, sec, relocs)
struct elf_link_hash_entry **sym_hashes;
bfd_signed_vma *local_got_refcounts;
const Elf_Internal_Rela *rel, *relend;
- unsigned long r_symndx;
- struct elf_link_hash_entry *h;
elf_section_data (sec)->local_dynrel = NULL;
@@ -965,84 +1426,140 @@ elf_s390_gc_sweep_hook (abfd, info, sec, relocs)
relend = relocs + sec->reloc_count;
for (rel = relocs; rel < relend; rel++)
- switch (ELF32_R_TYPE (rel->r_info))
- {
- case R_390_GOT12:
- case R_390_GOT16:
- case R_390_GOT32:
- case R_390_GOTOFF:
- case R_390_GOTPC:
- case R_390_GOTPCDBL:
- case R_390_GOTENT:
- r_symndx = ELF32_R_SYM (rel->r_info);
- if (r_symndx >= symtab_hdr->sh_info)
- {
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- if (h->got.refcount > 0)
- h->got.refcount -= 1;
- }
- else if (local_got_refcounts != NULL)
- {
- if (local_got_refcounts[r_symndx] > 0)
- local_got_refcounts[r_symndx] -= 1;
- }
- break;
+ {
+ unsigned long r_symndx;
+ unsigned int r_type;
+ struct elf_link_hash_entry *h = NULL;
+
+ r_symndx = ELF32_R_SYM (rel->r_info);
+ if (r_symndx >= symtab_hdr->sh_info)
+ {
+ struct elf_s390_link_hash_entry *eh;
+ struct elf_s390_dyn_relocs **pp;
+ struct elf_s390_dyn_relocs *p;
- case R_390_8:
- case R_390_12:
- case R_390_16:
- case R_390_32:
- case R_390_PC16:
- case R_390_PC16DBL:
- case R_390_PC32DBL:
- case R_390_PC32:
- r_symndx = ELF32_R_SYM (rel->r_info);
- if (r_symndx >= symtab_hdr->sh_info)
- {
- struct elf_s390_link_hash_entry *eh;
- struct elf_s390_dyn_relocs **pp;
- struct elf_s390_dyn_relocs *p;
-
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
-
- if (!info->shared && h->plt.refcount > 0)
- h->plt.refcount -= 1;
-
- eh = (struct elf_s390_link_hash_entry *) h;
-
- for (pp = &eh->dyn_relocs; (p = *pp) != NULL; pp = &p->next)
- if (p->sec == sec)
+ h = sym_hashes[r_symndx - symtab_hdr->sh_info];
+ eh = (struct elf_s390_link_hash_entry *) h;
+
+ for (pp = &eh->dyn_relocs; (p = *pp) != NULL; pp = &p->next)
+ if (p->sec == sec)
+ {
+ /* Everything must go for SEC. */
+ *pp = p->next;
+ break;
+ }
+ }
+
+ r_type = ELF32_R_TYPE (rel->r_info);
+ r_type = elf_s390_tls_transition (info, r_type, h != NULL);
+ switch (r_type)
+ {
+ case R_390_TLS_LDM32:
+ if (elf_s390_hash_table (info)->tls_ldm_got.refcount > 0)
+ elf_s390_hash_table (info)->tls_ldm_got.refcount -= 1;
+ break;
+
+ case R_390_TLS_GD32:
+ case R_390_TLS_IE32:
+ case R_390_TLS_GOTIE12:
+ case R_390_TLS_GOTIE20:
+ case R_390_TLS_GOTIE32:
+ case R_390_TLS_IEENT:
+ case R_390_GOT12:
+ case R_390_GOT16:
+ case R_390_GOT20:
+ case R_390_GOT32:
+ case R_390_GOTOFF16:
+ case R_390_GOTOFF32:
+ case R_390_GOTPC:
+ case R_390_GOTPCDBL:
+ case R_390_GOTENT:
+ if (h != NULL)
+ {
+ if (h->got.refcount > 0)
+ h->got.refcount -= 1;
+ }
+ else if (local_got_refcounts != NULL)
+ {
+ if (local_got_refcounts[r_symndx] > 0)
+ local_got_refcounts[r_symndx] -= 1;
+ }
+ break;
+
+ case R_390_8:
+ case R_390_12:
+ case R_390_16:
+ case R_390_20:
+ case R_390_32:
+ case R_390_PC16:
+ case R_390_PC16DBL:
+ case R_390_PC32DBL:
+ case R_390_PC32:
+ if (info->shared)
+ break;
+ /* Fall through. */
+
+ case R_390_PLT16DBL:
+ case R_390_PLT32DBL:
+ case R_390_PLT32:
+ case R_390_PLTOFF16:
+ case R_390_PLTOFF32:
+ if (h != NULL)
+ {
+ if (h->plt.refcount > 0)
+ h->plt.refcount -= 1;
+ }
+ break;
+
+ case R_390_GOTPLT12:
+ case R_390_GOTPLT16:
+ case R_390_GOTPLT20:
+ case R_390_GOTPLT32:
+ case R_390_GOTPLTENT:
+ if (h != NULL)
+ {
+ if (h->plt.refcount > 0)
{
- if (ELF32_R_TYPE (rel->r_info) == R_390_PC16
- || ELF32_R_TYPE (rel->r_info) == R_390_PC16DBL
- || ELF32_R_TYPE (rel->r_info) == R_390_PC32DBL
- || ELF32_R_TYPE (rel->r_info) == R_390_PC32)
- p->pc_count -= 1;
- p->count -= 1;
- if (p->count == 0)
- *pp = p->next;
- break;
+ ((struct elf_s390_link_hash_entry *) h)->gotplt_refcount--;
+ h->plt.refcount -= 1;
}
- }
- break;
+ }
+ else if (local_got_refcounts != NULL)
+ {
+ if (local_got_refcounts[r_symndx] > 0)
+ local_got_refcounts[r_symndx] -= 1;
+ }
+ break;
- case R_390_PLT16DBL:
- case R_390_PLT32DBL:
- case R_390_PLT32:
- r_symndx = ELF32_R_SYM (rel->r_info);
- if (r_symndx >= symtab_hdr->sh_info)
- {
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- if (h->plt.refcount > 0)
- h->plt.refcount -= 1;
- }
- break;
+ default:
+ break;
+ }
+ }
- default:
- break;
- }
+ return TRUE;
+}
+
+/* Make sure we emit a GOT entry if the symbol was supposed to have a PLT
+ entry but we found we will not create any. Called when we find we will
+ not have any PLT for this symbol, by for example
+ elf_s390_adjust_dynamic_symbol when we're doing a proper dynamic link,
+ or elf_s390_size_dynamic_sections if no dynamic sections will be
+ created (we're only linking static objects). */
+
+static void
+elf_s390_adjust_gotplt (h)
+ struct elf_s390_link_hash_entry *h;
+{
+ if (h->elf.root.type == bfd_link_hash_warning)
+ h = (struct elf_s390_link_hash_entry *) h->elf.root.u.i.link;
- return true;
+ if (h->gotplt_refcount <= 0)
+ return;
+
+ /* We simply add the number of gotplt references to the number
+ * of got references for this symbol. */
+ h->elf.got.refcount += h->gotplt_refcount;
+ h->gotplt_refcount = -1;
}
/* Adjust a symbol defined by a dynamic object and referenced by a
@@ -1051,14 +1568,12 @@ elf_s390_gc_sweep_hook (abfd, info, sec, relocs)
change the definition to something the rest of the link can
understand. */
-static boolean
+static bfd_boolean
elf_s390_adjust_dynamic_symbol (info, h)
struct bfd_link_info *info;
struct elf_link_hash_entry *h;
{
struct elf_s390_link_hash_table *htab;
- struct elf_s390_link_hash_entry * eh;
- struct elf_s390_dyn_relocs *p;
asection *s;
unsigned int power_of_two;
@@ -1076,15 +1591,16 @@ elf_s390_adjust_dynamic_symbol (info, h)
&& h->root.type != bfd_link_hash_undefined))
{
/* This case can occur if we saw a PLT32 reloc in an input
- file, but the symbol was never referred to by a dynamic
- object, or if all references were garbage collected. In
+ file, but the symbol was never referred to by a dynamic
+ object, or if all references were garbage collected. In
such a case, we don't actually need to build a procedure
linkage table, and we can just do a PC32 reloc instead. */
h->plt.offset = (bfd_vma) -1;
h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
+ elf_s390_adjust_gotplt((struct elf_s390_link_hash_entry *) h);
}
- return true;
+ return TRUE;
}
else
/* It's possible that we incorrectly decided a .plt reloc was
@@ -1103,7 +1619,11 @@ elf_s390_adjust_dynamic_symbol (info, h)
|| h->weakdef->root.type == bfd_link_hash_defweak);
h->root.u.def.section = h->weakdef->root.u.def.section;
h->root.u.def.value = h->weakdef->root.u.def.value;
- return true;
+ if (ELIMINATE_COPY_RELOCS || info->nocopyreloc)
+ h->elf_link_hash_flags
+ = ((h->elf_link_hash_flags & ~ELF_LINK_NON_GOT_REF)
+ | (h->weakdef->elf_link_hash_flags & ELF_LINK_NON_GOT_REF));
+ return TRUE;
}
/* This is a reference to a symbol defined by a dynamic object which
@@ -1114,34 +1634,40 @@ elf_s390_adjust_dynamic_symbol (info, h)
For such cases we need not do anything here; the relocations will
be handled correctly by relocate_section. */
if (info->shared)
- return true;
+ return TRUE;
/* If there are no references to this symbol that do not use the
GOT, we don't need to generate a copy reloc. */
if ((h->elf_link_hash_flags & ELF_LINK_NON_GOT_REF) == 0)
- return true;
+ return TRUE;
/* If -z nocopyreloc was given, we won't generate them either. */
if (info->nocopyreloc)
{
h->elf_link_hash_flags &= ~ELF_LINK_NON_GOT_REF;
- return true;
+ return TRUE;
}
- eh = (struct elf_s390_link_hash_entry *) h;
- for (p = eh->dyn_relocs; p != NULL; p = p->next)
+ if (ELIMINATE_COPY_RELOCS)
{
- s = p->sec->output_section;
- if (s != NULL && (s->flags & SEC_READONLY) != 0)
- break;
- }
+ struct elf_s390_link_hash_entry * eh;
+ struct elf_s390_dyn_relocs *p;
- /* If we didn't find any dynamic relocs in read-only sections, then
- we'll be keeping the dynamic relocs and avoiding the copy reloc. */
- if (p == NULL)
- {
- h->elf_link_hash_flags &= ~ELF_LINK_NON_GOT_REF;
- return true;
+ eh = (struct elf_s390_link_hash_entry *) h;
+ for (p = eh->dyn_relocs; p != NULL; p = p->next)
+ {
+ s = p->sec->output_section;
+ if (s != NULL && (s->flags & SEC_READONLY) != 0)
+ break;
+ }
+
+ /* If we didn't find any dynamic relocs in read-only sections, then
+ we'll be keeping the dynamic relocs and avoiding the copy reloc. */
+ if (p == NULL)
+ {
+ h->elf_link_hash_flags &= ~ELF_LINK_NON_GOT_REF;
+ return TRUE;
+ }
}
/* We must allocate the symbol in our .dynbss section, which will
@@ -1177,7 +1703,7 @@ elf_s390_adjust_dynamic_symbol (info, h)
if (power_of_two > bfd_get_section_alignment (htab->elf.dynobj, s))
{
if (! bfd_set_section_alignment (htab->elf.dynobj, s, power_of_two))
- return false;
+ return FALSE;
}
/* Define the symbol as being at this point in the section. */
@@ -1187,24 +1713,13 @@ elf_s390_adjust_dynamic_symbol (info, h)
/* Increment the section size to make room for the symbol. */
s->_raw_size += h->size;
- return true;
+ return TRUE;
}
-/* This is the condition under which elf_s390_finish_dynamic_symbol
- will be called from elflink.h. If elflink.h doesn't call our
- finish_dynamic_symbol routine, we'll need to do something about
- initializing any .plt and .got entries in elf_s390_relocate_section. */
-#define WILL_CALL_FINISH_DYNAMIC_SYMBOL(DYN, INFO, H) \
- ((DYN) \
- && ((INFO)->shared \
- || ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0) \
- && ((H)->dynindx != -1 \
- || ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0))
-
/* Allocate space in .plt, .got and associated reloc sections for
dynamic relocs. */
-static boolean
+static bfd_boolean
allocate_dynrelocs (h, inf)
struct elf_link_hash_entry *h;
PTR inf;
@@ -1215,27 +1730,33 @@ allocate_dynrelocs (h, inf)
struct elf_s390_dyn_relocs *p;
if (h->root.type == bfd_link_hash_indirect)
- return true;
+ return TRUE;
if (h->root.type == bfd_link_hash_warning)
+ /* When warning symbols are created, they **replace** the "real"
+ entry in the hash table, thus we never get to see the real
+ symbol in a hash traversal. So look at it now. */
h = (struct elf_link_hash_entry *) h->root.u.i.link;
info = (struct bfd_link_info *) inf;
htab = elf_s390_hash_table (info);
if (htab->elf.dynamic_sections_created
- && h->plt.refcount > 0)
+ && h->plt.refcount > 0
+ && (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak))
{
/* Make sure this symbol is output as a dynamic symbol.
Undefined weak syms won't yet be marked as dynamic. */
if (h->dynindx == -1
&& (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
{
- if (! bfd_elf32_link_record_dynamic_symbol (info, h))
- return false;
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
}
- if (WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, info, h))
+ if (info->shared
+ || WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, 0, h))
{
asection *s = htab->splt;
@@ -1272,33 +1793,69 @@ allocate_dynrelocs (h, inf)
{
h->plt.offset = (bfd_vma) -1;
h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
+ elf_s390_adjust_gotplt((struct elf_s390_link_hash_entry *) h);
}
}
else
{
h->plt.offset = (bfd_vma) -1;
h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
+ elf_s390_adjust_gotplt((struct elf_s390_link_hash_entry *) h);
}
- if (h->got.refcount > 0)
+ /* If R_390_TLS_{IE32,GOTIE32,GOTIE12,IEENT} symbol is now local to
+ the binary, we can optimize a bit. IE32 and GOTIE32 get converted
+ to R_390_TLS_LE32 requiring no TLS entry. For GOTIE12 and IEENT
+ we can save the dynamic TLS relocation. */
+ if (h->got.refcount > 0
+ && !info->shared
+ && h->dynindx == -1
+ && elf_s390_hash_entry(h)->tls_type >= GOT_TLS_IE)
{
+ if (elf_s390_hash_entry(h)->tls_type == GOT_TLS_IE_NLT)
+ /* For the GOTIE access without a literal pool entry the offset has
+ to be stored somewhere. The immediate value in the instruction
+ is not bit enough so the value is stored in the got. */
+ {
+ h->got.offset = htab->sgot->_raw_size;
+ htab->sgot->_raw_size += GOT_ENTRY_SIZE;
+ }
+ else
+ h->got.offset = (bfd_vma) -1;
+ }
+ else if (h->got.refcount > 0)
+ {
asection *s;
- boolean dyn;
+ bfd_boolean dyn;
+ int tls_type = elf_s390_hash_entry(h)->tls_type;
/* Make sure this symbol is output as a dynamic symbol.
Undefined weak syms won't yet be marked as dynamic. */
if (h->dynindx == -1
&& (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
{
- if (! bfd_elf32_link_record_dynamic_symbol (info, h))
- return false;
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
}
s = htab->sgot;
h->got.offset = s->_raw_size;
s->_raw_size += GOT_ENTRY_SIZE;
+ /* R_390_TLS_GD32 needs 2 consecutive GOT slots. */
+ if (tls_type == GOT_TLS_GD)
+ s->_raw_size += GOT_ENTRY_SIZE;
dyn = htab->elf.dynamic_sections_created;
- if (WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info, h))
+ /* R_390_TLS_IE32 needs one dynamic relocation,
+ R_390_TLS_GD32 needs one if local symbol and two if global. */
+ if ((tls_type == GOT_TLS_GD && h->dynindx == -1)
+ || tls_type >= GOT_TLS_IE)
+ htab->srelgot->_raw_size += sizeof (Elf32_External_Rela);
+ else if (tls_type == GOT_TLS_GD)
+ htab->srelgot->_raw_size += 2 * sizeof (Elf32_External_Rela);
+ else if ((ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak)
+ && (info->shared
+ || WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, 0, h)))
htab->srelgot->_raw_size += sizeof (Elf32_External_Rela);
}
else
@@ -1306,7 +1863,7 @@ allocate_dynrelocs (h, inf)
eh = (struct elf_s390_link_hash_entry *) h;
if (eh->dyn_relocs == NULL)
- return true;
+ return TRUE;
/* In the shared -Bsymbolic case, discard space allocated for
dynamic pc-relative relocs against symbols which turn out to be
@@ -1316,9 +1873,7 @@ allocate_dynrelocs (h, inf)
if (info->shared)
{
- if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0
- && ((h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0
- || info->symbolic))
+ if (SYMBOL_REFERENCES_LOCAL (info, h))
{
struct elf_s390_dyn_relocs **pp;
@@ -1332,8 +1887,14 @@ allocate_dynrelocs (h, inf)
pp = &p->next;
}
}
+
+ /* Also discard relocs on undefined weak syms with non-default
+ visibility. */
+ if (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+ && h->root.type == bfd_link_hash_undefweak)
+ eh->dyn_relocs = NULL;
}
- else
+ else if (ELIMINATE_COPY_RELOCS)
{
/* For the non-shared case, discard space for relocs against
symbols which turn out to need copy relocs or are not
@@ -1351,8 +1912,8 @@ allocate_dynrelocs (h, inf)
if (h->dynindx == -1
&& (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
{
- if (! bfd_elf32_link_record_dynamic_symbol (info, h))
- return false;
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
}
/* If that succeeded, we know we'll be keeping all the
@@ -1370,15 +1931,16 @@ allocate_dynrelocs (h, inf)
for (p = eh->dyn_relocs; p != NULL; p = p->next)
{
asection *sreloc = elf_section_data (p->sec)->sreloc;
+
sreloc->_raw_size += p->count * sizeof (Elf32_External_Rela);
}
- return true;
+ return TRUE;
}
/* Find any dynamic relocs that apply to read-only sections. */
-static boolean
+static bfd_boolean
readonly_dynrelocs (h, inf)
struct elf_link_hash_entry *h;
PTR inf;
@@ -1401,15 +1963,15 @@ readonly_dynrelocs (h, inf)
info->flags |= DF_TEXTREL;
/* Not an error, just cut short the traversal. */
- return false;
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
/* Set the sizes of the dynamic sections. */
-static boolean
+static bfd_boolean
elf_s390_size_dynamic_sections (output_bfd, info)
bfd *output_bfd ATTRIBUTE_UNUSED;
struct bfd_link_info *info;
@@ -1417,7 +1979,7 @@ elf_s390_size_dynamic_sections (output_bfd, info)
struct elf_s390_link_hash_table *htab;
bfd *dynobj;
asection *s;
- boolean relocs;
+ bfd_boolean relocs;
bfd *ibfd;
htab = elf_s390_hash_table (info);
@@ -1428,7 +1990,7 @@ elf_s390_size_dynamic_sections (output_bfd, info)
if (htab->elf.dynamic_sections_created)
{
/* Set the contents of the .interp section to the interpreter. */
- if (! info->shared)
+ if (info->executable)
{
s = bfd_get_section_by_name (dynobj, ".interp");
if (s == NULL)
@@ -1444,6 +2006,7 @@ elf_s390_size_dynamic_sections (output_bfd, info)
{
bfd_signed_vma *local_got;
bfd_signed_vma *end_local_got;
+ char *local_tls_type;
bfd_size_type locsymcount;
Elf_Internal_Shdr *symtab_hdr;
asection *srela;
@@ -1485,14 +2048,17 @@ elf_s390_size_dynamic_sections (output_bfd, info)
symtab_hdr = &elf_tdata (ibfd)->symtab_hdr;
locsymcount = symtab_hdr->sh_info;
end_local_got = local_got + locsymcount;
+ local_tls_type = elf_s390_local_got_tls_type (ibfd);
s = htab->sgot;
srela = htab->srelgot;
- for (; local_got < end_local_got; ++local_got)
+ for (; local_got < end_local_got; ++local_got, ++local_tls_type)
{
if (*local_got > 0)
{
*local_got = s->_raw_size;
s->_raw_size += GOT_ENTRY_SIZE;
+ if (*local_tls_type == GOT_TLS_GD)
+ s->_raw_size += GOT_ENTRY_SIZE;
if (info->shared)
srela->_raw_size += sizeof (Elf32_External_Rela);
}
@@ -1501,13 +2067,24 @@ elf_s390_size_dynamic_sections (output_bfd, info)
}
}
+ if (htab->tls_ldm_got.refcount > 0)
+ {
+ /* Allocate 2 got entries and 1 dynamic reloc for R_390_TLS_LDM32
+ relocs. */
+ htab->tls_ldm_got.offset = htab->sgot->_raw_size;
+ htab->sgot->_raw_size += 2 * GOT_ENTRY_SIZE;
+ htab->srelgot->_raw_size += sizeof (Elf32_External_Rela);
+ }
+ else
+ htab->tls_ldm_got.offset = -1;
+
/* Allocate global sym .plt and .got entries, and space for global
sym dynamic relocs. */
elf_link_hash_traverse (&htab->elf, allocate_dynrelocs, (PTR) info);
/* We now have determined the sizes of the various dynamic sections.
Allocate memory for them. */
- relocs = false;
+ relocs = FALSE;
for (s = dynobj->sections; s != NULL; s = s->next)
{
if ((s->flags & SEC_LINKER_CREATED) == 0)
@@ -1522,8 +2099,8 @@ elf_s390_size_dynamic_sections (output_bfd, info)
}
else if (strncmp (bfd_get_section_name (dynobj, s), ".rela", 5) == 0)
{
- if (s->_raw_size != 0 && s != htab->srelplt)
- relocs = true;
+ if (s->_raw_size != 0)
+ relocs = TRUE;
/* We use the reloc_count field as a counter if we need
to copy relocs into the output file. */
@@ -1558,7 +2135,7 @@ elf_s390_size_dynamic_sections (output_bfd, info)
of garbage. */
s->contents = (bfd_byte *) bfd_zalloc (dynobj, s->_raw_size);
if (s->contents == NULL)
- return false;
+ return FALSE;
}
if (htab->elf.dynamic_sections_created)
@@ -1569,12 +2146,12 @@ elf_s390_size_dynamic_sections (output_bfd, info)
the .dynamic section. The DT_DEBUG entry is filled in by the
dynamic linker and used by the debugger. */
#define add_dynamic_entry(TAG, VAL) \
- bfd_elf32_add_dynamic_entry (info, (bfd_vma) (TAG), (bfd_vma) (VAL))
+ _bfd_elf_add_dynamic_entry (info, TAG, VAL)
- if (! info->shared)
+ if (info->executable)
{
if (!add_dynamic_entry (DT_DEBUG, 0))
- return false;
+ return FALSE;
}
if (htab->splt->_raw_size != 0)
@@ -1583,15 +2160,15 @@ elf_s390_size_dynamic_sections (output_bfd, info)
|| !add_dynamic_entry (DT_PLTRELSZ, 0)
|| !add_dynamic_entry (DT_PLTREL, DT_RELA)
|| !add_dynamic_entry (DT_JMPREL, 0))
- return false;
+ return FALSE;
}
if (relocs)
- {
- if (!add_dynamic_entry (DT_RELA, 0)
- || !add_dynamic_entry (DT_RELASZ, 0)
- || !add_dynamic_entry (DT_RELAENT, sizeof (Elf32_External_Rela)))
- return false;
+ {
+ if (!add_dynamic_entry (DT_RELA, 0)
+ || !add_dynamic_entry (DT_RELASZ, 0)
+ || !add_dynamic_entry (DT_RELAENT, sizeof (Elf32_External_Rela)))
+ return FALSE;
/* If any dynamic relocs apply to a read-only section,
then we need a DT_TEXTREL entry. */
@@ -1602,18 +2179,68 @@ elf_s390_size_dynamic_sections (output_bfd, info)
if ((info->flags & DF_TEXTREL) != 0)
{
if (!add_dynamic_entry (DT_TEXTREL, 0))
- return false;
+ return FALSE;
}
}
}
#undef add_dynamic_entry
- return true;
+ return TRUE;
+}
+
+/* Return the base VMA address which should be subtracted from real addresses
+ when resolving @dtpoff relocation.
+ This is PT_TLS segment p_vaddr. */
+
+static bfd_vma
+dtpoff_base (info)
+ struct bfd_link_info *info;
+{
+ /* If tls_sec is NULL, we should have signalled an error already. */
+ if (elf_hash_table (info)->tls_sec == NULL)
+ return 0;
+ return elf_hash_table (info)->tls_sec->vma;
+}
+
+/* Return the relocation value for @tpoff relocation
+ if STT_TLS virtual address is ADDRESS. */
+
+static bfd_vma
+tpoff (info, address)
+ struct bfd_link_info *info;
+ bfd_vma address;
+{
+ struct elf_link_hash_table *htab = elf_hash_table (info);
+
+ /* If tls_sec is NULL, we should have signalled an error already. */
+ if (htab->tls_sec == NULL)
+ return 0;
+ return htab->tls_size + htab->tls_sec->vma - address;
+}
+
+/* Complain if TLS instruction relocation is against an invalid
+ instruction. */
+
+static void
+invalid_tls_insn (input_bfd, input_section, rel)
+ bfd *input_bfd;
+ asection *input_section;
+ Elf_Internal_Rela *rel;
+{
+ reloc_howto_type *howto;
+
+ howto = elf_howto_table + ELF32_R_TYPE (rel->r_info);
+ (*_bfd_error_handler)
+ (_("%s(%s+0x%lx): invalid instruction for TLS relocation %s"),
+ bfd_archive_filename (input_bfd),
+ bfd_get_section_name (input_bfd, input_section),
+ (long) rel->r_offset,
+ howto->name);
}
/* Relocate a 390 ELF section. */
-static boolean
+static bfd_boolean
elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
contents, relocs, local_syms, local_sections)
bfd *output_bfd;
@@ -1632,8 +2259,8 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
Elf_Internal_Rela *rel;
Elf_Internal_Rela *relend;
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
htab = elf_s390_hash_table (info);
symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
@@ -1644,7 +2271,7 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
relend = relocs + input_section->reloc_count;
for (; rel < relend; rel++)
{
- int r_type;
+ unsigned int r_type;
reloc_howto_type *howto;
unsigned long r_symndx;
struct elf_link_hash_entry *h;
@@ -1652,250 +2279,279 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
asection *sec;
bfd_vma off;
bfd_vma relocation;
- boolean unresolved_reloc;
+ bfd_boolean unresolved_reloc;
bfd_reloc_status_type r;
+ int tls_type;
r_type = ELF32_R_TYPE (rel->r_info);
if (r_type == (int) R_390_GNU_VTINHERIT
- || r_type == (int) R_390_GNU_VTENTRY)
- continue;
- if (r_type < 0 || r_type >= (int) R_390_max)
+ || r_type == (int) R_390_GNU_VTENTRY)
+ continue;
+ if (r_type >= (int) R_390_max)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
howto = elf_howto_table + r_type;
r_symndx = ELF32_R_SYM (rel->r_info);
+
+ /* This is a final link. */
h = NULL;
sym = NULL;
sec = NULL;
- unresolved_reloc = false;
+ unresolved_reloc = FALSE;
if (r_symndx < symtab_hdr->sh_info)
{
sym = local_syms + r_symndx;
sec = local_sections[r_symndx];
- relocation = _bfd_elf_rela_local_sym (output_bfd, sym, sec, rel);
+ relocation = _bfd_elf_rela_local_sym (output_bfd, sym, &sec, rel);
}
else
{
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- while (h->root.type == bfd_link_hash_indirect
- || h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
+ bfd_boolean warned ATTRIBUTE_UNUSED;
- if (h->root.type == bfd_link_hash_defined
- || h->root.type == bfd_link_hash_defweak)
- {
- sec = h->root.u.def.section;
- if (sec->output_section == NULL)
- {
- /* Set a flag that will be cleared later if we find a
- relocation value for this symbol. output_section
- is typically NULL for symbols satisfied by a shared
- library. */
- unresolved_reloc = true;
- relocation = 0;
- }
- else
- relocation = (h->root.u.def.value
- + sec->output_section->vma
- + sec->output_offset);
- }
- else if (h->root.type == bfd_link_hash_undefweak)
- relocation = 0;
- else if (info->shared
- && (!info->symbolic || info->allow_shlib_undefined)
- && !info->no_undefined
- && ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
- relocation = 0;
- else
- {
- if (! ((*info->callbacks->undefined_symbol)
- (info, h->root.root.string, input_bfd,
- input_section, rel->r_offset,
- (!info->shared || info->no_undefined
- || ELF_ST_VISIBILITY (h->other)))))
- return false;
- relocation = 0;
- }
+ RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
+ r_symndx, symtab_hdr, sym_hashes,
+ h, sec, relocation,
+ unresolved_reloc, warned);
}
switch (r_type)
{
- case R_390_GOT12:
- case R_390_GOT16:
- case R_390_GOT32:
+ case R_390_GOTPLT12:
+ case R_390_GOTPLT16:
+ case R_390_GOTPLT20:
+ case R_390_GOTPLT32:
+ case R_390_GOTPLTENT:
+ /* There are three cases for a GOTPLT relocation. 1) The
+ relocation is against the jump slot entry of a plt that
+ will get emitted to the output file. 2) The relocation
+ is against the jump slot of a plt entry that has been
+ removed. elf_s390_adjust_gotplt has created a GOT entry
+ as replacement. 3) The relocation is against a local symbol.
+ Cases 2) and 3) are the same as the GOT relocation code
+ so we just have to test for case 1 and fall through for
+ the other two. */
+ if (h != NULL && h->plt.offset != (bfd_vma) -1)
+ {
+ bfd_vma plt_index;
+
+ /* Calc. index no.
+ Current offset - size first entry / entry size. */
+ plt_index = (h->plt.offset - PLT_FIRST_ENTRY_SIZE) /
+ PLT_ENTRY_SIZE;
+
+ /* Offset in GOT is PLT index plus GOT headers(3) times 4,
+ addr & GOT addr. */
+ relocation = (plt_index + 3) * GOT_ENTRY_SIZE;
+ unresolved_reloc = FALSE;
+
+ if (r_type == R_390_GOTPLTENT)
+ relocation += htab->sgot->output_section->vma;
+ break;
+ }
+ /* Fall through. */
+
+ case R_390_GOT12:
+ case R_390_GOT16:
+ case R_390_GOT20:
+ case R_390_GOT32:
case R_390_GOTENT:
- /* Relocation is to the entry for this symbol in the global
- offset table. */
+ /* Relocation is to the entry for this symbol in the global
+ offset table. */
if (htab->sgot == NULL)
abort ();
- if (h != NULL)
- {
- boolean dyn;
+ if (h != NULL)
+ {
+ bfd_boolean dyn;
- off = h->got.offset;
+ off = h->got.offset;
dyn = htab->elf.dynamic_sections_created;
- if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info, h)
- || (info->shared
- && (info->symbolic
+ if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info->shared, h)
+ || (info->shared
+ && (info->symbolic
|| h->dynindx == -1
|| (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL))
- && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR)))
- {
- /* This is actually a static link, or it is a
- -Bsymbolic link and the symbol is defined
- locally, or the symbol was forced to be local
- because of a version file. We must initialize
- this entry in the global offset table. Since the
- offset must always be a multiple of 2, we use the
- least significant bit to record whether we have
- initialized it already.
-
- When doing a dynamic link, we create a .rel.got
- relocation entry to initialize the value. This
- is done in the finish_dynamic_symbol routine. */
- if ((off & 1) != 0)
- off &= ~1;
- else
- {
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR))
+ || (ELF_ST_VISIBILITY (h->other)
+ && h->root.type == bfd_link_hash_undefweak))
+ {
+ /* This is actually a static link, or it is a
+ -Bsymbolic link and the symbol is defined
+ locally, or the symbol was forced to be local
+ because of a version file. We must initialize
+ this entry in the global offset table. Since the
+ offset must always be a multiple of 2, we use the
+ least significant bit to record whether we have
+ initialized it already.
+
+ When doing a dynamic link, we create a .rel.got
+ relocation entry to initialize the value. This
+ is done in the finish_dynamic_symbol routine. */
+ if ((off & 1) != 0)
+ off &= ~1;
+ else
+ {
bfd_put_32 (output_bfd, relocation,
htab->sgot->contents + off);
- h->got.offset |= 1;
- }
- }
+ h->got.offset |= 1;
+ }
+ }
else
- unresolved_reloc = false;
- }
- else
- {
+ unresolved_reloc = FALSE;
+ }
+ else
+ {
if (local_got_offsets == NULL)
abort ();
- off = local_got_offsets[r_symndx];
+ off = local_got_offsets[r_symndx];
- /* The offset must always be a multiple of 4. We use
- the least significant bit to record whether we have
- already generated the necessary reloc. */
- if ((off & 1) != 0)
- off &= ~1;
- else
- {
- bfd_put_32 (output_bfd, relocation,
+ /* The offset must always be a multiple of 4. We use
+ the least significant bit to record whether we have
+ already generated the necessary reloc. */
+ if ((off & 1) != 0)
+ off &= ~1;
+ else
+ {
+ bfd_put_32 (output_bfd, relocation,
htab->sgot->contents + off);
- if (info->shared)
- {
- asection *srelgot;
- Elf_Internal_Rela outrel;
- Elf32_External_Rela *loc;
+ if (info->shared)
+ {
+ asection *srelgot;
+ Elf_Internal_Rela outrel;
+ bfd_byte *loc;
- srelgot = htab->srelgot;
+ srelgot = htab->srelgot;
if (srelgot == NULL)
abort ();
- outrel.r_offset = (htab->sgot->output_section->vma
- + htab->sgot->output_offset
- + off);
- outrel.r_info = ELF32_R_INFO (0, R_390_RELATIVE);
+ outrel.r_offset = (htab->sgot->output_section->vma
+ + htab->sgot->output_offset
+ + off);
+ outrel.r_info = ELF32_R_INFO (0, R_390_RELATIVE);
outrel.r_addend = relocation;
- loc = (Elf32_External_Rela *) srelgot->contents;
- loc += srelgot->reloc_count++;
- bfd_elf32_swap_reloca_out (output_bfd, &outrel, loc);
- }
+ loc = srelgot->contents;
+ loc += srelgot->reloc_count++ * sizeof (Elf32_External_Rela);
+ bfd_elf32_swap_reloca_out (output_bfd, &outrel, loc);
+ }
- local_got_offsets[r_symndx] |= 1;
- }
- }
+ local_got_offsets[r_symndx] |= 1;
+ }
+ }
if (off >= (bfd_vma) -2)
abort ();
relocation = htab->sgot->output_offset + off;
- /*
- * For @GOTENT the relocation is against the offset between
- * the instruction and the symbols entry in the GOT and not
- * between the start of the GOT and the symbols entry. We
- * add the vma of the GOT to get the correct value.
- */
- if (r_type == R_390_GOTENT)
+ /* For @GOTENT the relocation is against the offset between
+ the instruction and the symbols entry in the GOT and not
+ between the start of the GOT and the symbols entry. We
+ add the vma of the GOT to get the correct value. */
+ if ( r_type == R_390_GOTENT
+ || r_type == R_390_GOTPLTENT)
relocation += htab->sgot->output_section->vma;
- break;
-
- case R_390_GOTOFF:
- /* Relocation is relative to the start of the global offset
- table. */
+ break;
- /* Note that sgot->output_offset is not involved in this
- calculation. We always want the start of .got. If we
- defined _GLOBAL_OFFSET_TABLE in a different way, as is
- permitted by the ABI, we might have to change this
- calculation. */
- relocation -= htab->sgot->output_section->vma;
- break;
+ case R_390_GOTOFF16:
+ case R_390_GOTOFF32:
+ /* Relocation is relative to the start of the global offset
+ table. */
+
+ /* Note that sgot->output_offset is not involved in this
+ calculation. We always want the start of .got. If we
+ defined _GLOBAL_OFFSET_TABLE in a different way, as is
+ permitted by the ABI, we might have to change this
+ calculation. */
+ relocation -= htab->sgot->output_section->vma;
+ break;
- case R_390_GOTPC:
+ case R_390_GOTPC:
case R_390_GOTPCDBL:
- /* Use global offset table as symbol value. */
- relocation = htab->sgot->output_section->vma;
- unresolved_reloc = false;
- break;
-
- case R_390_PLT16DBL:
- case R_390_PLT32DBL:
- case R_390_PLT32:
- /* Relocation is to the entry for this symbol in the
- procedure linkage table. */
-
- /* Resolve a PLT32 reloc against a local symbol directly,
- without using the procedure linkage table. */
- if (h == NULL)
- break;
-
- if (h->plt.offset == (bfd_vma) -1
+ /* Use global offset table as symbol value. */
+ relocation = htab->sgot->output_section->vma;
+ unresolved_reloc = FALSE;
+ break;
+
+ case R_390_PLT16DBL:
+ case R_390_PLT32DBL:
+ case R_390_PLT32:
+ /* Relocation is to the entry for this symbol in the
+ procedure linkage table. */
+
+ /* Resolve a PLT32 reloc against a local symbol directly,
+ without using the procedure linkage table. */
+ if (h == NULL)
+ break;
+
+ if (h->plt.offset == (bfd_vma) -1
|| htab->splt == NULL)
- {
- /* We didn't make a PLT entry for this symbol. This
- happens when statically linking PIC code, or when
- using -Bsymbolic. */
- break;
- }
-
- relocation = (htab->splt->output_section->vma
- + htab->splt->output_offset
- + h->plt.offset);
- unresolved_reloc = false;
- break;
-
- case R_390_8:
- case R_390_16:
- case R_390_32:
- case R_390_PC16:
- case R_390_PC16DBL:
- case R_390_PC32DBL:
- case R_390_PC32:
+ {
+ /* We didn't make a PLT entry for this symbol. This
+ happens when statically linking PIC code, or when
+ using -Bsymbolic. */
+ break;
+ }
+
+ relocation = (htab->splt->output_section->vma
+ + htab->splt->output_offset
+ + h->plt.offset);
+ unresolved_reloc = FALSE;
+ break;
+
+ case R_390_PLTOFF16:
+ case R_390_PLTOFF32:
+ /* Relocation is to the entry for this symbol in the
+ procedure linkage table relative to the start of the GOT. */
+
+ /* For local symbols or if we didn't make a PLT entry for
+ this symbol resolve the symbol directly. */
+ if ( h == NULL
+ || h->plt.offset == (bfd_vma) -1
+ || htab->splt == NULL)
+ {
+ relocation -= htab->sgot->output_section->vma;
+ break;
+ }
+
+ relocation = (htab->splt->output_section->vma
+ + htab->splt->output_offset
+ + h->plt.offset
+ - htab->sgot->output_section->vma);
+ unresolved_reloc = FALSE;
+ break;
+
+ case R_390_8:
+ case R_390_16:
+ case R_390_32:
+ case R_390_PC16:
+ case R_390_PC16DBL:
+ case R_390_PC32DBL:
+ case R_390_PC32:
/* r_symndx will be zero only for relocs against symbols
from removed linkonce sections, or sections discarded by
a linker script. */
- if (r_symndx == 0
- || (input_section->flags & SEC_ALLOC) == 0)
+ if (r_symndx == 0
+ || (input_section->flags & SEC_ALLOC) == 0)
break;
- if ((info->shared
+ if ((info->shared
+ && (h == NULL
+ || ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak)
&& ((r_type != R_390_PC16
&& r_type != R_390_PC16DBL
&& r_type != R_390_PC32DBL
&& r_type != R_390_PC32)
|| (h != NULL
- && h->dynindx != -1
- && (! info->symbolic
- || (h->elf_link_hash_flags
- & ELF_LINK_HASH_DEF_REGULAR) == 0))))
- || (!info->shared
+ && !SYMBOL_REFERENCES_LOCAL (info, h))))
+ || (ELIMINATE_COPY_RELOCS
+ && !info->shared
&& h != NULL
&& h->dynindx != -1
&& (h->elf_link_hash_flags & ELF_LINK_NON_GOT_REF) == 0
@@ -1905,32 +2561,32 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
& ELF_LINK_HASH_DEF_REGULAR) == 0)
|| h->root.type == bfd_link_hash_undefweak
|| h->root.type == bfd_link_hash_undefined)))
- {
- Elf_Internal_Rela outrel;
- boolean skip, relocate;
+ {
+ Elf_Internal_Rela outrel;
+ bfd_boolean skip, relocate;
asection *sreloc;
- Elf32_External_Rela *loc;
+ bfd_byte *loc;
/* When generating a shared object, these relocations
are copied into the output file to be resolved at run
time. */
- skip = false;
- relocate = false;
+ skip = FALSE;
+ relocate = FALSE;
outrel.r_offset =
_bfd_elf_section_offset (output_bfd, info, input_section,
rel->r_offset);
if (outrel.r_offset == (bfd_vma) -1)
- skip = true;
+ skip = TRUE;
else if (outrel.r_offset == (bfd_vma) -2)
- skip = true, relocate = true;
- outrel.r_offset += (input_section->output_section->vma
- + input_section->output_offset);
+ skip = TRUE, relocate = TRUE;
+ outrel.r_offset += (input_section->output_section->vma
+ + input_section->output_offset);
- if (skip)
+ if (skip)
memset (&outrel, 0, sizeof outrel);
- else if (h != NULL
+ else if (h != NULL
&& h->dynindx != -1
&& (r_type == R_390_PC16
|| r_type == R_390_PC16DBL
@@ -1940,35 +2596,392 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
|| !info->symbolic
|| (h->elf_link_hash_flags
& ELF_LINK_HASH_DEF_REGULAR) == 0))
- {
- outrel.r_info = ELF32_R_INFO (h->dynindx, r_type);
+ {
+ outrel.r_info = ELF32_R_INFO (h->dynindx, r_type);
outrel.r_addend = rel->r_addend;
- }
- else
- {
+ }
+ else
+ {
/* This symbol is local, or marked to become local. */
- relocate = true;
- outrel.r_info = ELF32_R_INFO (0, R_390_RELATIVE);
outrel.r_addend = relocation + rel->r_addend;
- }
+ if (r_type == R_390_32)
+ {
+ relocate = TRUE;
+ outrel.r_info = ELF32_R_INFO (0, R_390_RELATIVE);
+ }
+ else
+ {
+ long sindx;
+
+ if (bfd_is_abs_section (sec))
+ sindx = 0;
+ else if (sec == NULL || sec->owner == NULL)
+ {
+ bfd_set_error(bfd_error_bad_value);
+ return FALSE;
+ }
+ else
+ {
+ asection *osec;
+
+ osec = sec->output_section;
+ sindx = elf_section_data (osec)->dynindx;
+ BFD_ASSERT (sindx > 0);
+
+ /* We are turning this relocation into one
+ against a section symbol, so subtract out
+ the output section's address but not the
+ offset of the input section in the output
+ section. */
+
+ outrel.r_addend -= osec->vma;
+ }
+ outrel.r_info = ELF32_R_INFO (sindx, r_type);
+ }
+ }
sreloc = elf_section_data (input_section)->sreloc;
if (sreloc == NULL)
abort ();
- loc = (Elf32_External_Rela *) sreloc->contents;
- loc += sreloc->reloc_count++;
+ loc = sreloc->contents;
+ loc += sreloc->reloc_count++ * sizeof (Elf32_External_Rela);
bfd_elf32_swap_reloca_out (output_bfd, &outrel, loc);
- /* If this reloc is against an external symbol, we do
- not want to fiddle with the addend. Otherwise, we
- need to include the symbol value so that it becomes
- an addend for the dynamic reloc. */
- if (! relocate)
- continue;
- }
+ /* If this reloc is against an external symbol, we do
+ not want to fiddle with the addend. Otherwise, we
+ need to include the symbol value so that it becomes
+ an addend for the dynamic reloc. */
+ if (! relocate)
+ continue;
+ }
break;
+ /* Relocations for tls literal pool entries. */
+ case R_390_TLS_IE32:
+ if (info->shared)
+ {
+ Elf_Internal_Rela outrel;
+ asection *sreloc;
+ bfd_byte *loc;
+
+ outrel.r_offset = rel->r_offset
+ + input_section->output_section->vma
+ + input_section->output_offset;
+ outrel.r_info = ELF32_R_INFO (0, R_390_RELATIVE);
+ sreloc = elf_section_data (input_section)->sreloc;
+ if (sreloc == NULL)
+ abort ();
+ loc = sreloc->contents;
+ loc += sreloc->reloc_count++ * sizeof (Elf32_External_Rela);
+ bfd_elf32_swap_reloc_out (output_bfd, &outrel, loc);
+ }
+ /* Fall through. */
+
+ case R_390_TLS_GD32:
+ case R_390_TLS_GOTIE32:
+ r_type = elf_s390_tls_transition (info, r_type, h == NULL);
+ tls_type = GOT_UNKNOWN;
+ if (h == NULL && local_got_offsets)
+ tls_type = elf_s390_local_got_tls_type (input_bfd) [r_symndx];
+ else if (h != NULL)
+ {
+ tls_type = elf_s390_hash_entry(h)->tls_type;
+ if (!info->shared && h->dynindx == -1 && tls_type >= GOT_TLS_IE)
+ r_type = R_390_TLS_LE32;
+ }
+ if (r_type == R_390_TLS_GD32 && tls_type >= GOT_TLS_IE)
+ r_type = R_390_TLS_IE32;
+
+ if (r_type == R_390_TLS_LE32)
+ {
+ /* This relocation gets optimized away by the local exec
+ access optimization. */
+ BFD_ASSERT (! unresolved_reloc);
+ bfd_put_32 (output_bfd, -tpoff (info, relocation),
+ contents + rel->r_offset);
+ continue;
+ }
+
+ if (htab->sgot == NULL)
+ abort ();
+
+ if (h != NULL)
+ off = h->got.offset;
+ else
+ {
+ if (local_got_offsets == NULL)
+ abort ();
+
+ off = local_got_offsets[r_symndx];
+ }
+
+ emit_tls_relocs:
+
+ if ((off & 1) != 0)
+ off &= ~1;
+ else
+ {
+ Elf_Internal_Rela outrel;
+ bfd_byte *loc;
+ int dr_type, indx;
+
+ if (htab->srelgot == NULL)
+ abort ();
+
+ outrel.r_offset = (htab->sgot->output_section->vma
+ + htab->sgot->output_offset + off);
+
+ indx = h && h->dynindx != -1 ? h->dynindx : 0;
+ if (r_type == R_390_TLS_GD32)
+ dr_type = R_390_TLS_DTPMOD;
+ else
+ dr_type = R_390_TLS_TPOFF;
+ if (dr_type == R_390_TLS_TPOFF && indx == 0)
+ outrel.r_addend = relocation - dtpoff_base (info);
+ else
+ outrel.r_addend = 0;
+ outrel.r_info = ELF32_R_INFO (indx, dr_type);
+ loc = htab->srelgot->contents;
+ loc += htab->srelgot->reloc_count++
+ * sizeof (Elf32_External_Rela);
+ bfd_elf32_swap_reloca_out (output_bfd, &outrel, loc);
+
+ if (r_type == R_390_TLS_GD32)
+ {
+ if (indx == 0)
+ {
+ BFD_ASSERT (! unresolved_reloc);
+ bfd_put_32 (output_bfd,
+ relocation - dtpoff_base (info),
+ htab->sgot->contents + off + GOT_ENTRY_SIZE);
+ }
+ else
+ {
+ outrel.r_info = ELF32_R_INFO (indx, R_390_TLS_DTPOFF);
+ outrel.r_offset += GOT_ENTRY_SIZE;
+ outrel.r_addend = 0;
+ htab->srelgot->reloc_count++;
+ loc += sizeof (Elf32_External_Rela);
+ bfd_elf32_swap_reloca_out (output_bfd, &outrel, loc);
+ }
+ }
+
+ if (h != NULL)
+ h->got.offset |= 1;
+ else
+ local_got_offsets[r_symndx] |= 1;
+ }
+
+ if (off >= (bfd_vma) -2)
+ abort ();
+ if (r_type == ELF32_R_TYPE (rel->r_info))
+ {
+ relocation = htab->sgot->output_offset + off;
+ if (r_type == R_390_TLS_IE32 || r_type == R_390_TLS_IEENT)
+ relocation += htab->sgot->output_section->vma;
+ unresolved_reloc = FALSE;
+ }
+ else
+ {
+ bfd_put_32 (output_bfd, htab->sgot->output_offset + off,
+ contents + rel->r_offset);
+ continue;
+ }
+ break;
+
+ case R_390_TLS_GOTIE12:
+ case R_390_TLS_GOTIE20:
+ case R_390_TLS_IEENT:
+ if (h == NULL)
+ {
+ if (local_got_offsets == NULL)
+ abort();
+ off = local_got_offsets[r_symndx];
+ if (info->shared)
+ goto emit_tls_relocs;
+ }
+ else
+ {
+ off = h->got.offset;
+ tls_type = elf_s390_hash_entry(h)->tls_type;
+ if (info->shared || h->dynindx != -1 || tls_type < GOT_TLS_IE)
+ goto emit_tls_relocs;
+ }
+
+ if (htab->sgot == NULL)
+ abort ();
+
+ BFD_ASSERT (! unresolved_reloc);
+ bfd_put_32 (output_bfd, -tpoff (info, relocation),
+ htab->sgot->contents + off);
+ relocation = htab->sgot->output_offset + off;
+ if (r_type == R_390_TLS_IEENT)
+ relocation += htab->sgot->output_section->vma;
+ unresolved_reloc = FALSE;
+ break;
+
+ case R_390_TLS_LDM32:
+ if (! info->shared)
+ /* The literal pool entry this relocation refers to gets ignored
+ by the optimized code of the local exec model. Do nothing
+ and the value will turn out zero. */
+ continue;
+
+ if (htab->sgot == NULL)
+ abort ();
+
+ off = htab->tls_ldm_got.offset;
+ if (off & 1)
+ off &= ~1;
+ else
+ {
+ Elf_Internal_Rela outrel;
+ bfd_byte *loc;
+
+ if (htab->srelgot == NULL)
+ abort ();
+
+ outrel.r_offset = (htab->sgot->output_section->vma
+ + htab->sgot->output_offset + off);
+
+ bfd_put_32 (output_bfd, 0,
+ htab->sgot->contents + off + GOT_ENTRY_SIZE);
+ outrel.r_info = ELF32_R_INFO (0, R_390_TLS_DTPMOD);
+ outrel.r_addend = 0;
+ loc = htab->srelgot->contents;
+ loc += htab->srelgot->reloc_count++
+ * sizeof (Elf32_External_Rela);
+ bfd_elf32_swap_reloca_out (output_bfd, &outrel, loc);
+ htab->tls_ldm_got.offset |= 1;
+ }
+ relocation = htab->sgot->output_offset + off;
+ unresolved_reloc = FALSE;
+ break;
+
+ case R_390_TLS_LE32:
+ if (info->shared)
+ {
+ /* Linking a shared library with non-fpic code requires
+ a R_390_TLS_TPOFF relocation. */
+ Elf_Internal_Rela outrel;
+ asection *sreloc;
+ bfd_byte *loc;
+ int indx;
+
+ outrel.r_offset = rel->r_offset
+ + input_section->output_section->vma
+ + input_section->output_offset;
+ if (h != NULL && h->dynindx != -1)
+ indx = h->dynindx;
+ else
+ indx = 0;
+ outrel.r_info = ELF32_R_INFO (indx, R_390_TLS_TPOFF);
+ if (indx == 0)
+ outrel.r_addend = relocation - dtpoff_base (info);
+ else
+ outrel.r_addend = 0;
+ sreloc = elf_section_data (input_section)->sreloc;
+ if (sreloc == NULL)
+ abort ();
+ loc = sreloc->contents;
+ loc += sreloc->reloc_count++ * sizeof (Elf32_External_Rela);
+ bfd_elf32_swap_reloca_out (output_bfd, &outrel, loc);
+ }
+ else
+ {
+ BFD_ASSERT (! unresolved_reloc);
+ bfd_put_32 (output_bfd, -tpoff (info, relocation),
+ contents + rel->r_offset);
+ }
+ continue;
+
+ case R_390_TLS_LDO32:
+ if (info->shared || (input_section->flags & SEC_CODE) == 0)
+ relocation -= dtpoff_base (info);
+ else
+ /* When converting LDO to LE, we must negate. */
+ relocation = -tpoff (info, relocation);
+ break;
+
+ /* Relocations for tls instructions. */
+ case R_390_TLS_LOAD:
+ case R_390_TLS_GDCALL:
+ case R_390_TLS_LDCALL:
+ tls_type = GOT_UNKNOWN;
+ if (h == NULL && local_got_offsets)
+ tls_type = elf_s390_local_got_tls_type (input_bfd) [r_symndx];
+ else if (h != NULL)
+ tls_type = elf_s390_hash_entry(h)->tls_type;
+
+ if (tls_type == GOT_TLS_GD)
+ continue;
+
+ if (r_type == R_390_TLS_LOAD)
+ {
+ if (!info->shared && (h == NULL || h->dynindx == -1))
+ {
+ /* IE->LE transition. Four valid cases:
+ l %rx,0(0,%ry) -> lr %rx,%ry + bcr 0,0
+ l %rx,0(%ry,0) -> lr %rx,%ry + bcr 0,0
+ l %rx,0(%ry,%r12) -> lr %rx,%ry + bcr 0,0
+ l %rx,0(%r12,%ry) -> lr %rx,%ry + bcr 0,0 */
+ unsigned int insn, ry;
+
+ insn = bfd_get_32 (input_bfd, contents + rel->r_offset);
+ ry = 0;
+ if ((insn & 0xff00f000) == 0x58000000)
+ /* l %rx,0(%ry,0) -> lr %rx,%ry + bcr 0,0 */
+ ry = (insn & 0x000f0000);
+ else if ((insn & 0xff0f0000) == 0x58000000)
+ /* l %rx,0(0,%ry) -> lr %rx,%ry + bcr 0,0 */
+ ry = (insn & 0x0000f000) << 4;
+ else if ((insn & 0xff00f000) == 0x5800c000)
+ /* l %rx,0(%ry,%r12) -> lr %rx,%ry + bcr 0,0 */
+ ry = (insn & 0x000f0000);
+ else if ((insn & 0xff0f0000) == 0x580c0000)
+ /* l %rx,0(%r12,%ry) -> lr %rx,%ry + bcr 0,0 */
+ ry = (insn & 0x0000f000) << 4;
+ else
+ invalid_tls_insn (input_bfd, input_section, rel);
+ insn = 0x18000700 | (insn & 0x00f00000) | ry;
+ bfd_put_32 (output_bfd, insn, contents + rel->r_offset);
+ }
+ }
+ else if (r_type == R_390_TLS_GDCALL)
+ {
+ unsigned int insn;
+
+ insn = bfd_get_32 (input_bfd, contents + rel->r_offset);
+ if ((insn & 0xff000fff) != 0x4d000000)
+ invalid_tls_insn (input_bfd, input_section, rel);
+ if (!info->shared && (h == NULL || h->dynindx == -1))
+ /* GD->LE transition.
+ bas %r14,0(%rx,%r13) -> bc 0,0 */
+ insn = 0x47000000;
+ else
+ /* GD->IE transition.
+ bas %r14,0(%rx,%r13) -> l %r2,0(%r2,%r12) */
+ insn = 0x5822c000;
+ bfd_put_32 (output_bfd, insn, contents + rel->r_offset);
+ }
+ else if (r_type == R_390_TLS_LDCALL)
+ {
+ if (!info->shared)
+ {
+ unsigned int insn;
+
+ insn = bfd_get_32 (input_bfd, contents + rel->r_offset);
+ if ((insn & 0xff000fff) != 0x4d000000)
+ invalid_tls_insn (input_bfd, input_section, rel);
+ /* LD->LE transition.
+ bas %r14,0(%rx,%r13) -> bc 0,0 */
+ insn = 0x47000000;
+ bfd_put_32 (output_bfd, insn, contents + rel->r_offset);
+ }
+ }
+ continue;
+
default:
break;
}
@@ -1986,9 +2999,21 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
(long) rel->r_offset,
h->root.root.string);
- r = _bfd_final_link_relocate (howto, input_bfd, input_section,
- contents, rel->r_offset,
- relocation, rel->r_addend);
+ if (r_type == R_390_20
+ || r_type == R_390_GOT20
+ || r_type == R_390_GOTPLT20
+ || r_type == R_390_TLS_GOTIE20)
+ {
+ relocation += rel->r_addend;
+ relocation = (relocation&0xfff) << 8 | (relocation&0xff000) >> 12;
+ r = _bfd_final_link_relocate (howto, input_bfd, input_section,
+ contents, rel->r_offset,
+ relocation, 0);
+ }
+ else
+ r = _bfd_final_link_relocate (howto, input_bfd, input_section,
+ contents, rel->r_offset,
+ relocation, rel->r_addend);
if (r != bfd_reloc_ok)
{
@@ -2002,7 +3027,7 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
symtab_hdr->sh_link,
sym->st_name);
if (name == NULL)
- return false;
+ return FALSE;
if (*name == '\0')
name = bfd_section_name (input_bfd, sec);
}
@@ -2013,7 +3038,7 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
if (! ((*info->callbacks->reloc_overflow)
(info, name, howto->name, (bfd_vma) 0,
input_bfd, input_section, rel->r_offset)))
- return false;
+ return FALSE;
}
else
{
@@ -2022,18 +3047,18 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
bfd_archive_filename (input_bfd),
bfd_get_section_name (input_bfd, input_section),
(long) rel->r_offset, name, (int) r);
- return false;
+ return FALSE;
}
}
}
- return true;
+ return TRUE;
}
/* Finish up dynamic symbol handling. We set the contents of various
dynamic sections here. */
-static boolean
+static bfd_boolean
elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -2049,12 +3074,11 @@ elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
bfd_vma plt_index;
bfd_vma got_offset;
Elf_Internal_Rela rela;
- Elf32_External_Rela *loc;
+ bfd_byte *loc;
bfd_vma relative_offset;
/* This symbol has an entry in the procedure linkage table. Set
- it up. */
-
+ it up. */
if (h->dynindx == -1
|| htab->splt == NULL
|| htab->sgotplt == NULL
@@ -2062,26 +3086,26 @@ elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
abort ();
/* Calc. index no.
- Current offset - size first entry / entry size. */
+ Current offset - size first entry / entry size. */
plt_index = (h->plt.offset - PLT_FIRST_ENTRY_SIZE) / PLT_ENTRY_SIZE;
/* Offset in GOT is PLT index plus GOT headers(3) times 4,
- addr & GOT addr. */
+ addr & GOT addr. */
got_offset = (plt_index + 3) * GOT_ENTRY_SIZE;
/* S390 uses halfwords for relative branch calc! */
relative_offset = - ((PLT_FIRST_ENTRY_SIZE +
- (PLT_ENTRY_SIZE * plt_index) + 18) / 2);
+ (PLT_ENTRY_SIZE * plt_index) + 18) / 2);
/* If offset is > 32768, branch to a previous branch
- 390 can only handle +-64 K jumps. */
+ 390 can only handle +-64 K jumps. */
if ( -32768 > (int) relative_offset )
- relative_offset =
- -(unsigned) (((65536 / PLT_ENTRY_SIZE - 1) * PLT_ENTRY_SIZE) / 2);
+ relative_offset
+ = -(unsigned) (((65536 / PLT_ENTRY_SIZE - 1) * PLT_ENTRY_SIZE) / 2);
/* Fill in the entry in the procedure linkage table. */
if (!info->shared)
{
- bfd_put_32 (output_bfd, (bfd_vma) PLT_ENTRY_WORD0,
+ bfd_put_32 (output_bfd, (bfd_vma) PLT_ENTRY_WORD0,
htab->splt->contents + h->plt.offset);
bfd_put_32 (output_bfd, (bfd_vma) PLT_ENTRY_WORD1,
htab->splt->contents + h->plt.offset + 4);
@@ -2152,10 +3176,10 @@ elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
}
/* Insert offset into reloc. table here. */
bfd_put_32 (output_bfd, plt_index * sizeof (Elf32_External_Rela),
- htab->splt->contents + h->plt.offset + 28);
+ htab->splt->contents + h->plt.offset + 28);
/* Fill in the entry in the global offset table.
- Points to instruction after GOT offset. */
+ Points to instruction after GOT offset. */
bfd_put_32 (output_bfd,
(htab->splt->output_section->vma
+ htab->splt->output_offset
@@ -2169,7 +3193,7 @@ elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
+ got_offset);
rela.r_info = ELF32_R_INFO (h->dynindx, R_390_JMP_SLOT);
rela.r_addend = 0;
- loc = (Elf32_External_Rela *) htab->srelplt->contents + plt_index;
+ loc = htab->srelplt->contents + plt_index * sizeof (Elf32_External_Rela);
bfd_elf32_swap_reloca_out (output_bfd, &rela, loc);
if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
@@ -2183,13 +3207,16 @@ elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
}
}
- if (h->got.offset != (bfd_vma) -1)
+ if (h->got.offset != (bfd_vma) -1
+ && elf_s390_hash_entry(h)->tls_type != GOT_TLS_GD
+ && elf_s390_hash_entry(h)->tls_type != GOT_TLS_IE
+ && elf_s390_hash_entry(h)->tls_type != GOT_TLS_IE_NLT)
{
Elf_Internal_Rela rela;
- Elf32_External_Rela *loc;
+ bfd_byte *loc;
/* This symbol has an entry in the global offset table. Set it
- up. */
+ up. */
if (htab->sgot == NULL || htab->srelgot == NULL)
abort ();
@@ -2212,26 +3239,26 @@ elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
BFD_ASSERT((h->got.offset & 1) != 0);
rela.r_info = ELF32_R_INFO (0, R_390_RELATIVE);
rela.r_addend = (h->root.u.def.value
- + h->root.u.def.section->output_section->vma
- + h->root.u.def.section->output_offset);
- }
+ + h->root.u.def.section->output_section->vma
+ + h->root.u.def.section->output_offset);
+ }
else
{
BFD_ASSERT((h->got.offset & 1) == 0);
bfd_put_32 (output_bfd, (bfd_vma) 0, htab->sgot->contents + h->got.offset);
rela.r_info = ELF32_R_INFO (h->dynindx, R_390_GLOB_DAT);
- rela.r_addend = 0;
- }
+ rela.r_addend = 0;
+ }
- loc = (Elf32_External_Rela *) htab->srelgot->contents;
- loc += htab->srelgot->reloc_count++;
+ loc = htab->srelgot->contents;
+ loc += htab->srelgot->reloc_count++ * sizeof (Elf32_External_Rela);
bfd_elf32_swap_reloca_out (output_bfd, &rela, loc);
}
if ((h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_COPY) != 0)
{
Elf_Internal_Rela rela;
- Elf32_External_Rela *loc;
+ bfd_byte *loc;
/* This symbols needs a copy reloc. Set it up. */
@@ -2246,8 +3273,8 @@ elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
+ h->root.u.def.section->output_offset);
rela.r_info = ELF32_R_INFO (h->dynindx, R_390_COPY);
rela.r_addend = 0;
- loc = (Elf32_External_Rela *) htab->srelbss->contents;
- loc += htab->srelbss->reloc_count++;
+ loc = htab->srelbss->contents;
+ loc += htab->srelbss->reloc_count++ * sizeof (Elf32_External_Rela);
bfd_elf32_swap_reloca_out (output_bfd, &rela, loc);
}
@@ -2257,7 +3284,7 @@ elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
|| strcmp (h->root.root.string, "_PROCEDURE_LINKAGE_TABLE_") == 0)
sym->st_shndx = SHN_ABS;
- return true;
+ return TRUE;
}
/* Used to decide how to sort relocs in an optimal manner for the
@@ -2282,7 +3309,7 @@ elf_s390_reloc_type_class (rela)
/* Finish up the dynamic sections. */
-static boolean
+static bfd_boolean
elf_s390_finish_dynamic_sections (output_bfd, info)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -2339,39 +3366,39 @@ elf_s390_finish_dynamic_sections (output_bfd, info)
/* Fill in the special first entry in the procedure linkage table. */
if (htab->splt && htab->splt->_raw_size > 0)
{
- memset (htab->splt->contents, 0, PLT_FIRST_ENTRY_SIZE);
- if (info->shared)
+ memset (htab->splt->contents, 0, PLT_FIRST_ENTRY_SIZE);
+ if (info->shared)
{
bfd_put_32 (output_bfd, (bfd_vma) PLT_PIC_FIRST_ENTRY_WORD0,
- htab->splt->contents );
+ htab->splt->contents );
bfd_put_32 (output_bfd, (bfd_vma) PLT_PIC_FIRST_ENTRY_WORD1,
- htab->splt->contents +4 );
+ htab->splt->contents +4 );
bfd_put_32 (output_bfd, (bfd_vma) PLT_PIC_FIRST_ENTRY_WORD2,
- htab->splt->contents +8 );
+ htab->splt->contents +8 );
bfd_put_32 (output_bfd, (bfd_vma) PLT_PIC_FIRST_ENTRY_WORD3,
- htab->splt->contents +12 );
+ htab->splt->contents +12 );
bfd_put_32 (output_bfd, (bfd_vma) PLT_PIC_FIRST_ENTRY_WORD4,
- htab->splt->contents +16 );
- }
- else
- {
- bfd_put_32 (output_bfd, (bfd_vma)PLT_FIRST_ENTRY_WORD0,
- htab->splt->contents );
- bfd_put_32 (output_bfd, (bfd_vma) PLT_FIRST_ENTRY_WORD1,
- htab->splt->contents +4 );
- bfd_put_32 (output_bfd, (bfd_vma) PLT_FIRST_ENTRY_WORD2,
- htab->splt->contents +8 );
- bfd_put_32 (output_bfd, (bfd_vma) PLT_FIRST_ENTRY_WORD3,
- htab->splt->contents +12 );
- bfd_put_32 (output_bfd, (bfd_vma) PLT_FIRST_ENTRY_WORD4,
- htab->splt->contents +16 );
- bfd_put_32 (output_bfd, (bfd_vma) PLT_FIRST_ENTRY_WORD5,
- htab->splt->contents +20 );
- bfd_put_32 (output_bfd,
- htab->sgotplt->output_section->vma
+ htab->splt->contents +16 );
+ }
+ else
+ {
+ bfd_put_32 (output_bfd, (bfd_vma)PLT_FIRST_ENTRY_WORD0,
+ htab->splt->contents );
+ bfd_put_32 (output_bfd, (bfd_vma) PLT_FIRST_ENTRY_WORD1,
+ htab->splt->contents +4 );
+ bfd_put_32 (output_bfd, (bfd_vma) PLT_FIRST_ENTRY_WORD2,
+ htab->splt->contents +8 );
+ bfd_put_32 (output_bfd, (bfd_vma) PLT_FIRST_ENTRY_WORD3,
+ htab->splt->contents +12 );
+ bfd_put_32 (output_bfd, (bfd_vma) PLT_FIRST_ENTRY_WORD4,
+ htab->splt->contents +16 );
+ bfd_put_32 (output_bfd, (bfd_vma) PLT_FIRST_ENTRY_WORD5,
+ htab->splt->contents +20 );
+ bfd_put_32 (output_bfd,
+ htab->sgotplt->output_section->vma
+ htab->sgotplt->output_offset,
- htab->splt->contents + 24);
- }
+ htab->splt->contents + 24);
+ }
elf_section_data (htab->splt->output_section)
->this_hdr.sh_entsize = 4;
}
@@ -2396,17 +3423,10 @@ elf_s390_finish_dynamic_sections (output_bfd, info)
elf_section_data (htab->sgotplt->output_section)
->this_hdr.sh_entsize = 4;
}
- return true;
-}
-
-static boolean
-elf_s390_object_p (abfd)
- bfd *abfd;
-{
- return bfd_default_set_arch_mach (abfd, bfd_arch_s390, bfd_mach_s390_31);
+ return TRUE;
}
-static boolean
+static bfd_boolean
elf_s390_grok_prstatus (abfd, note)
bfd * abfd;
Elf_Internal_Note * note;
@@ -2417,7 +3437,7 @@ elf_s390_grok_prstatus (abfd, note)
switch (note->descsz)
{
default:
- return false;
+ return FALSE;
case 224: /* S/390 Linux. */
/* pr_cursig */
@@ -2450,29 +3470,29 @@ elf_s390_grok_prstatus (abfd, note)
#define elf_backend_plt_readonly 1
#define elf_backend_want_plt_sym 0
#define elf_backend_got_header_size 12
-#define elf_backend_plt_header_size PLT_ENTRY_SIZE
#define elf_backend_rela_normal 1
-#define elf_info_to_howto elf_s390_info_to_howto
+#define elf_info_to_howto elf_s390_info_to_howto
#define bfd_elf32_bfd_is_local_label_name elf_s390_is_local_label_name
#define bfd_elf32_bfd_link_hash_table_create elf_s390_link_hash_table_create
#define bfd_elf32_bfd_reloc_type_lookup elf_s390_reloc_type_lookup
#define elf_backend_adjust_dynamic_symbol elf_s390_adjust_dynamic_symbol
-#define elf_backend_check_relocs elf_s390_check_relocs
+#define elf_backend_check_relocs elf_s390_check_relocs
#define elf_backend_copy_indirect_symbol elf_s390_copy_indirect_symbol
#define elf_backend_create_dynamic_sections elf_s390_create_dynamic_sections
#define elf_backend_finish_dynamic_sections elf_s390_finish_dynamic_sections
#define elf_backend_finish_dynamic_symbol elf_s390_finish_dynamic_symbol
-#define elf_backend_gc_mark_hook elf_s390_gc_mark_hook
-#define elf_backend_gc_sweep_hook elf_s390_gc_sweep_hook
+#define elf_backend_gc_mark_hook elf_s390_gc_mark_hook
+#define elf_backend_gc_sweep_hook elf_s390_gc_sweep_hook
#define elf_backend_reloc_type_class elf_s390_reloc_type_class
-#define elf_backend_relocate_section elf_s390_relocate_section
+#define elf_backend_relocate_section elf_s390_relocate_section
#define elf_backend_size_dynamic_sections elf_s390_size_dynamic_sections
#define elf_backend_reloc_type_class elf_s390_reloc_type_class
#define elf_backend_grok_prstatus elf_s390_grok_prstatus
-#define elf_backend_object_p elf_s390_object_p
+#define bfd_elf32_mkobject elf_s390_mkobject
+#define elf_backend_object_p elf_s390_object_p
#include "elf32-target.h"
diff --git a/contrib/binutils/bfd/elf32-sparc.c b/contrib/binutils/bfd/elf32-sparc.c
index b6cf7eb..0f94f5f 100644
--- a/contrib/binutils/bfd/elf32-sparc.c
+++ b/contrib/binutils/bfd/elf32-sparc.c
@@ -1,22 +1,22 @@
/* SPARC-specific support for 32-bit ELF
- Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
- Free Software Foundation, Inc.
+ Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+ 2003, 2004 Free Software Foundation, Inc.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "bfd.h"
#include "sysdep.h"
@@ -30,34 +30,61 @@ static reloc_howto_type *elf32_sparc_reloc_type_lookup
PARAMS ((bfd *, bfd_reloc_code_real_type));
static void elf32_sparc_info_to_howto
PARAMS ((bfd *, arelent *, Elf_Internal_Rela *));
-static boolean elf32_sparc_check_relocs
+static bfd_boolean elf32_sparc_check_relocs
PARAMS ((bfd *, struct bfd_link_info *, asection *,
const Elf_Internal_Rela *));
-static boolean elf32_sparc_adjust_dynamic_symbol
+static bfd_boolean elf32_sparc_adjust_dynamic_symbol
PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *));
-static boolean elf32_sparc_size_dynamic_sections
+static bfd_boolean allocate_dynrelocs
+ PARAMS ((struct elf_link_hash_entry *, PTR));
+static bfd_boolean readonly_dynrelocs
+ PARAMS ((struct elf_link_hash_entry *, PTR));
+static bfd_boolean elf32_sparc_size_dynamic_sections
PARAMS ((bfd *, struct bfd_link_info *));
-static boolean elf32_sparc_relax_section
- PARAMS ((bfd *, asection *, struct bfd_link_info *, boolean *));
-static boolean elf32_sparc_relocate_section
+static bfd_boolean elf32_sparc_new_section_hook
+ PARAMS ((bfd *, asection *));
+static bfd_boolean elf32_sparc_relax_section
+ PARAMS ((bfd *, asection *, struct bfd_link_info *, bfd_boolean *));
+static bfd_vma dtpoff_base
+ PARAMS ((struct bfd_link_info *));
+static bfd_vma tpoff
+ PARAMS ((struct bfd_link_info *, bfd_vma));
+static bfd_boolean elf32_sparc_relocate_section
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
Elf_Internal_Rela *, Elf_Internal_Sym *, asection **));
-static boolean elf32_sparc_finish_dynamic_symbol
+static bfd_boolean elf32_sparc_finish_dynamic_symbol
PARAMS ((bfd *, struct bfd_link_info *, struct elf_link_hash_entry *,
Elf_Internal_Sym *));
-static boolean elf32_sparc_finish_dynamic_sections
+static bfd_boolean elf32_sparc_finish_dynamic_sections
PARAMS ((bfd *, struct bfd_link_info *));
-static boolean elf32_sparc_merge_private_bfd_data PARAMS ((bfd *, bfd *));
-static boolean elf32_sparc_object_p
+static bfd_boolean elf32_sparc_merge_private_bfd_data
+ PARAMS ((bfd *, bfd *));
+static struct bfd_hash_entry *link_hash_newfunc
+ PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
+static struct bfd_link_hash_table *elf32_sparc_link_hash_table_create
+ PARAMS ((bfd *));
+static bfd_boolean create_got_section
+ PARAMS ((bfd *, struct bfd_link_info *));
+static bfd_boolean elf32_sparc_create_dynamic_sections
+ PARAMS ((bfd *, struct bfd_link_info *));
+static void elf32_sparc_copy_indirect_symbol
+ PARAMS ((const struct elf_backend_data *, struct elf_link_hash_entry *,
+ struct elf_link_hash_entry *));
+static int elf32_sparc_tls_transition
+ PARAMS ((struct bfd_link_info *, bfd *, int, int));
+
+static bfd_boolean elf32_sparc_mkobject
+ PARAMS ((bfd *));
+static bfd_boolean elf32_sparc_object_p
PARAMS ((bfd *));
static void elf32_sparc_final_write_processing
- PARAMS ((bfd *, boolean));
+ PARAMS ((bfd *, bfd_boolean));
static enum elf_reloc_type_class elf32_sparc_reloc_type_class
PARAMS ((const Elf_Internal_Rela *));
static asection * elf32_sparc_gc_mark_hook
PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
struct elf_link_hash_entry *, Elf_Internal_Sym *));
-static boolean elf32_sparc_gc_sweep_hook
+static bfd_boolean elf32_sparc_gc_sweep_hook
PARAMS ((bfd *, struct bfd_link_info *, asection *,
const Elf_Internal_Rela *));
@@ -67,75 +94,104 @@ static bfd_reloc_status_type sparc_elf_notsupported_reloc
PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
static bfd_reloc_status_type sparc_elf_wdisp16_reloc
PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
+static bfd_reloc_status_type sparc_elf_hix22_reloc
+ PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
+static bfd_reloc_status_type sparc_elf_lox10_reloc
+ PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
reloc_howto_type _bfd_sparc_elf_howto_table[] =
{
- HOWTO(R_SPARC_NONE, 0,0, 0,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", false,0,0x00000000,true),
- HOWTO(R_SPARC_8, 0,0, 8,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_8", false,0,0x000000ff,true),
- HOWTO(R_SPARC_16, 0,1,16,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_16", false,0,0x0000ffff,true),
- HOWTO(R_SPARC_32, 0,2,32,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_32", false,0,0xffffffff,true),
- HOWTO(R_SPARC_DISP8, 0,0, 8,true, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_DISP8", false,0,0x000000ff,true),
- HOWTO(R_SPARC_DISP16, 0,1,16,true, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_DISP16", false,0,0x0000ffff,true),
- HOWTO(R_SPARC_DISP32, 0,2,32,true, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_DISP32", false,0,0xffffffff,true),
- HOWTO(R_SPARC_WDISP30, 2,2,30,true, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_WDISP30", false,0,0x3fffffff,true),
- HOWTO(R_SPARC_WDISP22, 2,2,22,true, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_WDISP22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_HI22, 10,2,22,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_HI22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_22, 0,2,22,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_13, 0,2,13,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_13", false,0,0x00001fff,true),
- HOWTO(R_SPARC_LO10, 0,2,10,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_LO10", false,0,0x000003ff,true),
- HOWTO(R_SPARC_GOT10, 0,2,10,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_GOT10", false,0,0x000003ff,true),
- HOWTO(R_SPARC_GOT13, 0,2,13,false,0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_GOT13", false,0,0x00001fff,true),
- HOWTO(R_SPARC_GOT22, 10,2,22,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_GOT22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_PC10, 0,2,10,true, 0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_PC10", false,0,0x000003ff,true),
- HOWTO(R_SPARC_PC22, 10,2,22,true, 0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_PC22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_WPLT30, 2,2,30,true, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_WPLT30", false,0,0x3fffffff,true),
- HOWTO(R_SPARC_COPY, 0,0,00,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_COPY", false,0,0x00000000,true),
- HOWTO(R_SPARC_GLOB_DAT, 0,0,00,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_GLOB_DAT",false,0,0x00000000,true),
- HOWTO(R_SPARC_JMP_SLOT, 0,0,00,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_JMP_SLOT",false,0,0x00000000,true),
- HOWTO(R_SPARC_RELATIVE, 0,0,00,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_RELATIVE",false,0,0x00000000,true),
- HOWTO(R_SPARC_UA32, 0,2,32,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_UA32", false,0,0xffffffff,true),
- HOWTO(R_SPARC_PLT32, 0,0,00,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_PLT32", false,0,0xffffffff,true),
- HOWTO(R_SPARC_HIPLT22, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_HIPLT22", false,0,0x00000000,true),
- HOWTO(R_SPARC_LOPLT10, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_LOPLT10", false,0,0x00000000,true),
- HOWTO(R_SPARC_PCPLT32, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_PCPLT32", false,0,0x00000000,true),
- HOWTO(R_SPARC_PCPLT22, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_PCPLT22", false,0,0x00000000,true),
- HOWTO(R_SPARC_PCPLT10, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_PCPLT10", false,0,0x00000000,true),
- HOWTO(R_SPARC_10, 0,2,10,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_10", false,0,0x000003ff,true),
- HOWTO(R_SPARC_11, 0,2,11,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_11", false,0,0x000007ff,true),
+ HOWTO(R_SPARC_NONE, 0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_8, 0,0, 8,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_8", FALSE,0,0x000000ff,TRUE),
+ HOWTO(R_SPARC_16, 0,1,16,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_16", FALSE,0,0x0000ffff,TRUE),
+ HOWTO(R_SPARC_32, 0,2,32,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_32", FALSE,0,0xffffffff,TRUE),
+ HOWTO(R_SPARC_DISP8, 0,0, 8,TRUE, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_DISP8", FALSE,0,0x000000ff,TRUE),
+ HOWTO(R_SPARC_DISP16, 0,1,16,TRUE, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_DISP16", FALSE,0,0x0000ffff,TRUE),
+ HOWTO(R_SPARC_DISP32, 0,2,32,TRUE, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_DISP32", FALSE,0,0xffffffff,TRUE),
+ HOWTO(R_SPARC_WDISP30, 2,2,30,TRUE, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_WDISP30", FALSE,0,0x3fffffff,TRUE),
+ HOWTO(R_SPARC_WDISP22, 2,2,22,TRUE, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_WDISP22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_HI22, 10,2,22,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_HI22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_22, 0,2,22,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_13, 0,2,13,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_13", FALSE,0,0x00001fff,TRUE),
+ HOWTO(R_SPARC_LO10, 0,2,10,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_LO10", FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_GOT10, 0,2,10,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_GOT10", FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_GOT13, 0,2,13,FALSE,0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_GOT13", FALSE,0,0x00001fff,TRUE),
+ HOWTO(R_SPARC_GOT22, 10,2,22,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_GOT22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_PC10, 0,2,10,TRUE, 0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_PC10", FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_PC22, 10,2,22,TRUE, 0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_PC22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_WPLT30, 2,2,30,TRUE, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_WPLT30", FALSE,0,0x3fffffff,TRUE),
+ HOWTO(R_SPARC_COPY, 0,0,00,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_COPY", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_GLOB_DAT, 0,0,00,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_GLOB_DAT",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_JMP_SLOT, 0,0,00,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_JMP_SLOT",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_RELATIVE, 0,0,00,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_RELATIVE",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_UA32, 0,2,32,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_UA32", FALSE,0,0xffffffff,TRUE),
+ HOWTO(R_SPARC_PLT32, 0,0,00,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_PLT32", FALSE,0,0xffffffff,TRUE),
+ HOWTO(R_SPARC_HIPLT22, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_HIPLT22", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_LOPLT10, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_LOPLT10", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_PCPLT32, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_PCPLT32", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_PCPLT22, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_PCPLT22", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_PCPLT10, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_PCPLT10", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_10, 0,2,10,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_10", FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_11, 0,2,11,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_11", FALSE,0,0x000007ff,TRUE),
/* These are for sparc64 in a 64 bit environment.
Values need to be here because the table is indexed by reloc number. */
- HOWTO(R_SPARC_64, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_64", false,0,0x00000000,true),
- HOWTO(R_SPARC_OLO10, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_OLO10", false,0,0x00000000,true),
- HOWTO(R_SPARC_HH22, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_HH22", false,0,0x00000000,true),
- HOWTO(R_SPARC_HM10, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_HM10", false,0,0x00000000,true),
- HOWTO(R_SPARC_LM22, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_LM22", false,0,0x00000000,true),
- HOWTO(R_SPARC_PC_HH22, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_PC_HH22", false,0,0x00000000,true),
- HOWTO(R_SPARC_PC_HM10, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_PC_HM10", false,0,0x00000000,true),
- HOWTO(R_SPARC_PC_LM22, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_PC_LM22", false,0,0x00000000,true),
+ HOWTO(R_SPARC_64, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_64", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_OLO10, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_OLO10", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_HH22, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_HH22", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_HM10, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_HM10", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_LM22, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_LM22", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_PC_HH22, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_PC_HH22", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_PC_HM10, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_PC_HM10", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_PC_LM22, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_PC_LM22", FALSE,0,0x00000000,TRUE),
/* End sparc64 in 64 bit environment values.
The following are for sparc64 in a 32 bit environment. */
- HOWTO(R_SPARC_WDISP16, 2,2,16,true, 0,complain_overflow_signed, sparc_elf_wdisp16_reloc,"R_SPARC_WDISP16", false,0,0x00000000,true),
- HOWTO(R_SPARC_WDISP19, 2,2,19,true, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_WDISP19", false,0,0x0007ffff,true),
- HOWTO(R_SPARC_UNUSED_42, 0,0, 0,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_UNUSED_42",false,0,0x00000000,true),
- HOWTO(R_SPARC_7, 0,2, 7,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_7", false,0,0x0000007f,true),
- HOWTO(R_SPARC_5, 0,2, 5,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_5", false,0,0x0000001f,true),
- HOWTO(R_SPARC_6, 0,2, 6,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_6", false,0,0x0000003f,true),
- HOWTO(R_SPARC_NONE, 0,0, 0,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", false,0,0x00000000,true),
- HOWTO(R_SPARC_NONE, 0,0, 0,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", false,0,0x00000000,true),
- HOWTO(R_SPARC_NONE, 0,0, 0,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", false,0,0x00000000,true),
- HOWTO(R_SPARC_NONE, 0,0, 0,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", false,0,0x00000000,true),
- HOWTO(R_SPARC_NONE, 0,0, 0,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", false,0,0x00000000,true),
- HOWTO(R_SPARC_NONE, 0,0, 0,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", false,0,0x00000000,true),
- HOWTO(R_SPARC_NONE, 0,0, 0,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", false,0,0x00000000,true),
- HOWTO(R_SPARC_NONE, 0,0, 0,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", false,0,0x00000000,true),
- HOWTO(R_SPARC_UA64, 0,0, 0,false,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_UA64", false,0,0x00000000,true),
- HOWTO(R_SPARC_UA16, 0,1,16,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_UA16", false,0,0x0000ffff,true),
- HOWTO(R_SPARC_REV32, 0,2,32,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_REV32", false,0,0xffffffff,true),
+ HOWTO(R_SPARC_WDISP16, 2,2,16,TRUE, 0,complain_overflow_signed, sparc_elf_wdisp16_reloc,"R_SPARC_WDISP16", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_WDISP19, 2,2,19,TRUE, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_WDISP19", FALSE,0,0x0007ffff,TRUE),
+ HOWTO(R_SPARC_UNUSED_42, 0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_UNUSED_42",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_7, 0,2, 7,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_7", FALSE,0,0x0000007f,TRUE),
+ HOWTO(R_SPARC_5, 0,2, 5,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_5", FALSE,0,0x0000001f,TRUE),
+ HOWTO(R_SPARC_6, 0,2, 6,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_6", FALSE,0,0x0000003f,TRUE),
+ HOWTO(R_SPARC_NONE, 0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_NONE, 0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_NONE, 0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_NONE, 0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_NONE, 0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_NONE, 0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_NONE, 0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_NONE, 0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_UA64, 0,0, 0,FALSE,0,complain_overflow_dont, sparc_elf_notsupported_reloc, "R_SPARC_UA64", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_UA16, 0,1,16,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_UA16", FALSE,0,0x0000ffff,TRUE),
+ HOWTO(R_SPARC_TLS_GD_HI22,10,2,22,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_GD_HI22",FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_TLS_GD_LO10,0,2,10,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_GD_LO10",FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_TLS_GD_ADD,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_GD_ADD",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_GD_CALL,2,2,30,TRUE,0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_TLS_GD_CALL",FALSE,0,0x3fffffff,TRUE),
+ HOWTO(R_SPARC_TLS_LDM_HI22,10,2,22,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_LDM_HI22",FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_TLS_LDM_LO10,0,2,10,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_LDM_LO10",FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_TLS_LDM_ADD,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_LDM_ADD",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_LDM_CALL,2,2,30,TRUE,0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_TLS_LDM_CALL",FALSE,0,0x3fffffff,TRUE),
+ HOWTO(R_SPARC_TLS_LDO_HIX22,0,2,0,FALSE,0,complain_overflow_bitfield,sparc_elf_hix22_reloc,"R_SPARC_TLS_LDO_HIX22",FALSE,0,0x003fffff, FALSE),
+ HOWTO(R_SPARC_TLS_LDO_LOX10,0,2,0,FALSE,0,complain_overflow_dont, sparc_elf_lox10_reloc, "R_SPARC_TLS_LDO_LOX10",FALSE,0,0x000003ff, FALSE),
+ HOWTO(R_SPARC_TLS_LDO_ADD,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_LDO_ADD",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_IE_HI22,10,2,22,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_IE_HI22",FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_TLS_IE_LO10,0,2,10,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_IE_LO10",FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_TLS_IE_LD,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_IE_LD",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_IE_LDX,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_IE_LDX",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_IE_ADD,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_IE_ADD",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_LE_HIX22,0,2,0,FALSE,0,complain_overflow_bitfield,sparc_elf_hix22_reloc, "R_SPARC_TLS_LE_HIX22",FALSE,0,0x003fffff, FALSE),
+ HOWTO(R_SPARC_TLS_LE_LOX10,0,2,0,FALSE,0,complain_overflow_dont, sparc_elf_lox10_reloc, "R_SPARC_TLS_LE_LOX10",FALSE,0,0x000003ff, FALSE),
+ HOWTO(R_SPARC_TLS_DTPMOD32,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_DTPMOD32",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_DTPMOD64,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_DTPMOD64",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_DTPOFF32,0,2,32,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc,"R_SPARC_TLS_DTPOFF32",FALSE,0,0xffffffff,TRUE),
+ HOWTO(R_SPARC_TLS_DTPOFF64,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_DTPOFF64",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_TPOFF32,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_TPOFF32",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_TPOFF64,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_TPOFF64",FALSE,0,0x00000000,TRUE)
};
static reloc_howto_type elf32_sparc_vtinherit_howto =
- HOWTO (R_SPARC_GNU_VTINHERIT, 0,2,0,false,0,complain_overflow_dont, NULL, "R_SPARC_GNU_VTINHERIT", false,0, 0, false);
+ HOWTO (R_SPARC_GNU_VTINHERIT, 0,2,0,FALSE,0,complain_overflow_dont, NULL, "R_SPARC_GNU_VTINHERIT", FALSE,0, 0, FALSE);
static reloc_howto_type elf32_sparc_vtentry_howto =
- HOWTO (R_SPARC_GNU_VTENTRY, 0,2,0,false,0,complain_overflow_dont, _bfd_elf_rel_vtable_reloc_fn,"R_SPARC_GNU_VTENTRY", false,0,0, false);
+ HOWTO (R_SPARC_GNU_VTENTRY, 0,2,0,FALSE,0,complain_overflow_dont, _bfd_elf_rel_vtable_reloc_fn,"R_SPARC_GNU_VTENTRY", FALSE,0,0, FALSE);
+static reloc_howto_type elf32_sparc_rev32_howto =
+ HOWTO(R_SPARC_REV32, 0,2,32,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_REV32", FALSE,0,0xffffffff,TRUE);
struct elf_reloc_map {
bfd_reloc_code_real_type bfd_reloc_val;
@@ -187,9 +243,33 @@ static const struct elf_reloc_map sparc_reloc_map[] =
{ BFD_RELOC_SPARC_7, R_SPARC_7 },
{ BFD_RELOC_SPARC_5, R_SPARC_5 },
{ BFD_RELOC_SPARC_6, R_SPARC_6 },
- { BFD_RELOC_SPARC_REV32, R_SPARC_REV32 },
+ { BFD_RELOC_SPARC_TLS_GD_HI22, R_SPARC_TLS_GD_HI22 },
+ { BFD_RELOC_SPARC_TLS_GD_LO10, R_SPARC_TLS_GD_LO10 },
+ { BFD_RELOC_SPARC_TLS_GD_ADD, R_SPARC_TLS_GD_ADD },
+ { BFD_RELOC_SPARC_TLS_GD_CALL, R_SPARC_TLS_GD_CALL },
+ { BFD_RELOC_SPARC_TLS_LDM_HI22, R_SPARC_TLS_LDM_HI22 },
+ { BFD_RELOC_SPARC_TLS_LDM_LO10, R_SPARC_TLS_LDM_LO10 },
+ { BFD_RELOC_SPARC_TLS_LDM_ADD, R_SPARC_TLS_LDM_ADD },
+ { BFD_RELOC_SPARC_TLS_LDM_CALL, R_SPARC_TLS_LDM_CALL },
+ { BFD_RELOC_SPARC_TLS_LDO_HIX22, R_SPARC_TLS_LDO_HIX22 },
+ { BFD_RELOC_SPARC_TLS_LDO_LOX10, R_SPARC_TLS_LDO_LOX10 },
+ { BFD_RELOC_SPARC_TLS_LDO_ADD, R_SPARC_TLS_LDO_ADD },
+ { BFD_RELOC_SPARC_TLS_IE_HI22, R_SPARC_TLS_IE_HI22 },
+ { BFD_RELOC_SPARC_TLS_IE_LO10, R_SPARC_TLS_IE_LO10 },
+ { BFD_RELOC_SPARC_TLS_IE_LD, R_SPARC_TLS_IE_LD },
+ { BFD_RELOC_SPARC_TLS_IE_LDX, R_SPARC_TLS_IE_LDX },
+ { BFD_RELOC_SPARC_TLS_IE_ADD, R_SPARC_TLS_IE_ADD },
+ { BFD_RELOC_SPARC_TLS_LE_HIX22, R_SPARC_TLS_LE_HIX22 },
+ { BFD_RELOC_SPARC_TLS_LE_LOX10, R_SPARC_TLS_LE_LOX10 },
+ { BFD_RELOC_SPARC_TLS_DTPMOD32, R_SPARC_TLS_DTPMOD32 },
+ { BFD_RELOC_SPARC_TLS_DTPMOD64, R_SPARC_TLS_DTPMOD64 },
+ { BFD_RELOC_SPARC_TLS_DTPOFF32, R_SPARC_TLS_DTPOFF32 },
+ { BFD_RELOC_SPARC_TLS_DTPOFF64, R_SPARC_TLS_DTPOFF64 },
+ { BFD_RELOC_SPARC_TLS_TPOFF32, R_SPARC_TLS_TPOFF32 },
+ { BFD_RELOC_SPARC_TLS_TPOFF64, R_SPARC_TLS_TPOFF64 },
{ BFD_RELOC_VTABLE_INHERIT, R_SPARC_GNU_VTINHERIT },
{ BFD_RELOC_VTABLE_ENTRY, R_SPARC_GNU_VTENTRY },
+ { BFD_RELOC_SPARC_REV32, R_SPARC_REV32 }
};
static reloc_howto_type *
@@ -207,12 +287,18 @@ elf32_sparc_reloc_type_lookup (abfd, code)
case BFD_RELOC_VTABLE_ENTRY:
return &elf32_sparc_vtentry_howto;
+ case BFD_RELOC_SPARC_REV32:
+ return &elf32_sparc_rev32_howto;
+
default:
- for (i = 0; i < sizeof (sparc_reloc_map) / sizeof (struct elf_reloc_map); i++)
- {
- if (sparc_reloc_map[i].bfd_reloc_val == code)
- return &_bfd_sparc_elf_howto_table[(int) sparc_reloc_map[i].elf_reloc_val];
- }
+ for (i = 0;
+ i < sizeof (sparc_reloc_map) / sizeof (struct elf_reloc_map);
+ i++)
+ {
+ if (sparc_reloc_map[i].bfd_reloc_val == code)
+ return (_bfd_sparc_elf_howto_table
+ + (int) sparc_reloc_map[i].elf_reloc_val);
+ }
}
bfd_set_error (bfd_error_bad_value);
return NULL;
@@ -237,6 +323,10 @@ elf32_sparc_info_to_howto (abfd, cache_ptr, dst)
cache_ptr->howto = &elf32_sparc_vtentry_howto;
break;
+ case R_SPARC_REV32:
+ cache_ptr->howto = &elf32_sparc_rev32_howto;
+ break;
+
default:
BFD_ASSERT (ELF32_R_TYPE(dst->r_info) < (unsigned int) R_SPARC_max_std);
cache_ptr->howto = &_bfd_sparc_elf_howto_table[ELF32_R_TYPE(dst->r_info)];
@@ -319,6 +409,127 @@ sparc_elf_wdisp16_reloc (abfd,
else
return bfd_reloc_ok;
}
+
+/* Handle the HIX22 reloc. */
+
+static bfd_reloc_status_type
+sparc_elf_hix22_reloc (abfd,
+ reloc_entry,
+ symbol,
+ data,
+ input_section,
+ output_bfd,
+ error_message)
+ bfd *abfd;
+ arelent *reloc_entry;
+ asymbol *symbol;
+ PTR data;
+ asection *input_section;
+ bfd *output_bfd;
+ char **error_message ATTRIBUTE_UNUSED;
+{
+ bfd_vma relocation;
+ bfd_vma insn;
+
+ if (output_bfd != (bfd *) NULL
+ && (symbol->flags & BSF_SECTION_SYM) == 0)
+ {
+ reloc_entry->address += input_section->output_offset;
+ return bfd_reloc_ok;
+ }
+
+ if (output_bfd != NULL)
+ return bfd_reloc_continue;
+
+ if (reloc_entry->address > input_section->_cooked_size)
+ return bfd_reloc_outofrange;
+
+ relocation = (symbol->value
+ + symbol->section->output_section->vma
+ + symbol->section->output_offset);
+ relocation += reloc_entry->addend;
+ insn = bfd_get_32 (abfd, (bfd_byte *) data + reloc_entry->address);
+
+ insn = (insn &~ (bfd_vma) 0x3fffff) | (((~relocation) >> 10) & 0x3fffff);
+ bfd_put_32 (abfd, insn, (bfd_byte *) data + reloc_entry->address);
+
+ return bfd_reloc_ok;
+}
+
+/* Handle the LOX10 reloc. */
+
+static bfd_reloc_status_type
+sparc_elf_lox10_reloc (abfd,
+ reloc_entry,
+ symbol,
+ data,
+ input_section,
+ output_bfd,
+ error_message)
+ bfd *abfd;
+ arelent *reloc_entry;
+ asymbol *symbol;
+ PTR data;
+ asection *input_section;
+ bfd *output_bfd;
+ char **error_message ATTRIBUTE_UNUSED;
+{
+ bfd_vma relocation;
+ bfd_vma insn;
+
+ if (output_bfd != (bfd *) NULL
+ && (symbol->flags & BSF_SECTION_SYM) == 0)
+ {
+ reloc_entry->address += input_section->output_offset;
+ return bfd_reloc_ok;
+ }
+
+ if (output_bfd != NULL)
+ return bfd_reloc_continue;
+
+ if (reloc_entry->address > input_section->_cooked_size)
+ return bfd_reloc_outofrange;
+
+ relocation = (symbol->value
+ + symbol->section->output_section->vma
+ + symbol->section->output_offset);
+ relocation += reloc_entry->addend;
+ insn = bfd_get_32 (abfd, (bfd_byte *) data + reloc_entry->address);
+
+ insn = (insn &~ (bfd_vma) 0x1fff) | 0x1c00 | (relocation & 0x3ff);
+ bfd_put_32 (abfd, insn, (bfd_byte *) data + reloc_entry->address);
+
+ return bfd_reloc_ok;
+}
+
+/* Support for core dump NOTE sections. */
+
+static bfd_boolean
+elf32_sparc_grok_psinfo (bfd *abfd, Elf_Internal_Note *note)
+{
+ switch (note->descsz)
+ {
+ default:
+ return FALSE;
+
+ case 260: /* Solaris prpsinfo_t. */
+ elf_tdata (abfd)->core_program
+ = _bfd_elfcore_strndup (abfd, note->descdata + 84, 16);
+ elf_tdata (abfd)->core_command
+ = _bfd_elfcore_strndup (abfd, note->descdata + 100, 80);
+ break;
+
+ case 336: /* Solaris psinfo_t. */
+ elf_tdata (abfd)->core_program
+ = _bfd_elfcore_strndup (abfd, note->descdata + 88, 16);
+ elf_tdata (abfd)->core_command
+ = _bfd_elfcore_strndup (abfd, note->descdata + 104, 80);
+ break;
+ }
+
+ return TRUE;
+}
+
/* Functions for the SPARC ELF linker. */
@@ -347,185 +558,553 @@ sparc_elf_wdisp16_reloc (abfd,
/* nop. */
#define PLT_ENTRY_WORD2 SPARC_NOP
+/* The SPARC linker needs to keep track of the number of relocs that it
+ decides to copy as dynamic relocs in check_relocs for each symbol.
+ This is so that it can later discard them if they are found to be
+ unnecessary. We store the information in a field extending the
+ regular ELF linker hash table. */
+
+struct elf32_sparc_dyn_relocs
+{
+ struct elf32_sparc_dyn_relocs *next;
+
+ /* The input section of the reloc. */
+ asection *sec;
+
+ /* Total number of relocs copied for the input section. */
+ bfd_size_type count;
+
+ /* Number of pc-relative relocs copied for the input section. */
+ bfd_size_type pc_count;
+};
+
+/* SPARC ELF linker hash entry. */
+
+struct elf32_sparc_link_hash_entry
+{
+ struct elf_link_hash_entry elf;
+
+ /* Track dynamic relocs copied for this symbol. */
+ struct elf32_sparc_dyn_relocs *dyn_relocs;
+
+#define GOT_UNKNOWN 0
+#define GOT_NORMAL 1
+#define GOT_TLS_GD 2
+#define GOT_TLS_IE 3
+ unsigned char tls_type;
+};
+
+#define elf32_sparc_hash_entry(ent) ((struct elf32_sparc_link_hash_entry *)(ent))
+
+struct elf32_sparc_obj_tdata
+{
+ struct elf_obj_tdata root;
+
+ /* tls_type for each local got entry. */
+ char *local_got_tls_type;
+
+ /* TRUE if TLS GD relocs has been seen for this object. */
+ bfd_boolean has_tlsgd;
+};
+
+#define elf32_sparc_tdata(abfd) \
+ ((struct elf32_sparc_obj_tdata *) (abfd)->tdata.any)
+
+#define elf32_sparc_local_got_tls_type(abfd) \
+ (elf32_sparc_tdata (abfd)->local_got_tls_type)
+
+static bfd_boolean
+elf32_sparc_mkobject (abfd)
+ bfd *abfd;
+{
+ bfd_size_type amt = sizeof (struct elf32_sparc_obj_tdata);
+ abfd->tdata.any = bfd_zalloc (abfd, amt);
+ if (abfd->tdata.any == NULL)
+ return FALSE;
+ return TRUE;
+}
+
+/* SPARC ELF linker hash table. */
+
+struct elf32_sparc_link_hash_table
+{
+ struct elf_link_hash_table elf;
+
+ /* Short-cuts to get to dynamic linker sections. */
+ asection *sgot;
+ asection *srelgot;
+ asection *splt;
+ asection *srelplt;
+ asection *sdynbss;
+ asection *srelbss;
+
+ union {
+ bfd_signed_vma refcount;
+ bfd_vma offset;
+ } tls_ldm_got;
+
+ /* Small local sym to section mapping cache. */
+ struct sym_sec_cache sym_sec;
+};
+
+/* Get the SPARC ELF linker hash table from a link_info structure. */
+
+#define elf32_sparc_hash_table(p) \
+ ((struct elf32_sparc_link_hash_table *) ((p)->hash))
+
+/* Create an entry in an i386 ELF linker hash table. */
+
+static struct bfd_hash_entry *
+link_hash_newfunc (entry, table, string)
+ struct bfd_hash_entry *entry;
+ struct bfd_hash_table *table;
+ const char *string;
+{
+ /* Allocate the structure if it has not already been allocated by a
+ subclass. */
+ if (entry == NULL)
+ {
+ entry = bfd_hash_allocate (table,
+ sizeof (struct elf32_sparc_link_hash_entry));
+ if (entry == NULL)
+ return entry;
+ }
+
+ /* Call the allocation method of the superclass. */
+ entry = _bfd_elf_link_hash_newfunc (entry, table, string);
+ if (entry != NULL)
+ {
+ struct elf32_sparc_link_hash_entry *eh;
+
+ eh = (struct elf32_sparc_link_hash_entry *) entry;
+ eh->dyn_relocs = NULL;
+ eh->tls_type = GOT_UNKNOWN;
+ }
+
+ return entry;
+}
+
+/* Create a SPARC ELF linker hash table. */
+
+static struct bfd_link_hash_table *
+elf32_sparc_link_hash_table_create (abfd)
+ bfd *abfd;
+{
+ struct elf32_sparc_link_hash_table *ret;
+ bfd_size_type amt = sizeof (struct elf32_sparc_link_hash_table);
+
+ ret = (struct elf32_sparc_link_hash_table *) bfd_malloc (amt);
+ if (ret == NULL)
+ return NULL;
+
+ if (! _bfd_elf_link_hash_table_init (&ret->elf, abfd, link_hash_newfunc))
+ {
+ free (ret);
+ return NULL;
+ }
+
+ ret->sgot = NULL;
+ ret->srelgot = NULL;
+ ret->splt = NULL;
+ ret->srelplt = NULL;
+ ret->sdynbss = NULL;
+ ret->srelbss = NULL;
+ ret->tls_ldm_got.refcount = 0;
+ ret->sym_sec.abfd = NULL;
+
+ return &ret->elf.root;
+}
+
+/* Create .got and .rela.got sections in DYNOBJ, and set up
+ shortcuts to them in our hash table. */
+
+static bfd_boolean
+create_got_section (dynobj, info)
+ bfd *dynobj;
+ struct bfd_link_info *info;
+{
+ struct elf32_sparc_link_hash_table *htab;
+
+ if (! _bfd_elf_create_got_section (dynobj, info))
+ return FALSE;
+
+ htab = elf32_sparc_hash_table (info);
+ htab->sgot = bfd_get_section_by_name (dynobj, ".got");
+ if (!htab->sgot)
+ abort ();
+
+ htab->srelgot = bfd_make_section (dynobj, ".rela.got");
+ if (htab->srelgot == NULL
+ || ! bfd_set_section_flags (dynobj, htab->srelgot,
+ (SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS
+ | SEC_IN_MEMORY | SEC_LINKER_CREATED
+ | SEC_READONLY))
+ || ! bfd_set_section_alignment (dynobj, htab->srelgot, 2))
+ return FALSE;
+ return TRUE;
+}
+
+/* Create .plt, .rela.plt, .got, .rela.got, .dynbss, and
+ .rela.bss sections in DYNOBJ, and set up shortcuts to them in our
+ hash table. */
+
+static bfd_boolean
+elf32_sparc_create_dynamic_sections (dynobj, info)
+ bfd *dynobj;
+ struct bfd_link_info *info;
+{
+ struct elf32_sparc_link_hash_table *htab;
+
+ htab = elf32_sparc_hash_table (info);
+ if (!htab->sgot && !create_got_section (dynobj, info))
+ return FALSE;
+
+ if (!_bfd_elf_create_dynamic_sections (dynobj, info))
+ return FALSE;
+
+ htab->splt = bfd_get_section_by_name (dynobj, ".plt");
+ htab->srelplt = bfd_get_section_by_name (dynobj, ".rela.plt");
+ htab->sdynbss = bfd_get_section_by_name (dynobj, ".dynbss");
+ if (!info->shared)
+ htab->srelbss = bfd_get_section_by_name (dynobj, ".rela.bss");
+
+ if (!htab->splt || !htab->srelplt || !htab->sdynbss
+ || (!info->shared && !htab->srelbss))
+ abort ();
+
+ return TRUE;
+}
+
+/* Copy the extra info we tack onto an elf_link_hash_entry. */
+
+static void
+elf32_sparc_copy_indirect_symbol (bed, dir, ind)
+ const struct elf_backend_data *bed;
+ struct elf_link_hash_entry *dir, *ind;
+{
+ struct elf32_sparc_link_hash_entry *edir, *eind;
+
+ edir = (struct elf32_sparc_link_hash_entry *) dir;
+ eind = (struct elf32_sparc_link_hash_entry *) ind;
+
+ if (eind->dyn_relocs != NULL)
+ {
+ if (edir->dyn_relocs != NULL)
+ {
+ struct elf32_sparc_dyn_relocs **pp;
+ struct elf32_sparc_dyn_relocs *p;
+
+ if (ind->root.type == bfd_link_hash_indirect)
+ abort ();
+
+ /* Add reloc counts against the weak sym to the strong sym
+ list. Merge any entries against the same section. */
+ for (pp = &eind->dyn_relocs; (p = *pp) != NULL; )
+ {
+ struct elf32_sparc_dyn_relocs *q;
+
+ for (q = edir->dyn_relocs; q != NULL; q = q->next)
+ if (q->sec == p->sec)
+ {
+ q->pc_count += p->pc_count;
+ q->count += p->count;
+ *pp = p->next;
+ break;
+ }
+ if (q == NULL)
+ pp = &p->next;
+ }
+ *pp = edir->dyn_relocs;
+ }
+
+ edir->dyn_relocs = eind->dyn_relocs;
+ eind->dyn_relocs = NULL;
+ }
+
+ if (ind->root.type == bfd_link_hash_indirect
+ && dir->got.refcount <= 0)
+ {
+ edir->tls_type = eind->tls_type;
+ eind->tls_type = GOT_UNKNOWN;
+ }
+ _bfd_elf_link_hash_copy_indirect (bed, dir, ind);
+}
+
+static int
+elf32_sparc_tls_transition (info, abfd, r_type, is_local)
+ struct bfd_link_info *info;
+ bfd *abfd;
+ int r_type;
+ int is_local;
+{
+ if (r_type == R_SPARC_TLS_GD_HI22
+ && ! elf32_sparc_tdata (abfd)->has_tlsgd)
+ r_type = R_SPARC_REV32;
+
+ if (info->shared)
+ return r_type;
+
+ switch (r_type)
+ {
+ case R_SPARC_TLS_GD_HI22:
+ if (is_local)
+ return R_SPARC_TLS_LE_HIX22;
+ return R_SPARC_TLS_IE_HI22;
+ case R_SPARC_TLS_GD_LO10:
+ if (is_local)
+ return R_SPARC_TLS_LE_LOX10;
+ return R_SPARC_TLS_IE_LO10;
+ case R_SPARC_TLS_IE_HI22:
+ if (is_local)
+ return R_SPARC_TLS_LE_HIX22;
+ return r_type;
+ case R_SPARC_TLS_IE_LO10:
+ if (is_local)
+ return R_SPARC_TLS_LE_LOX10;
+ return r_type;
+ case R_SPARC_TLS_LDM_HI22:
+ return R_SPARC_TLS_LE_HIX22;
+ case R_SPARC_TLS_LDM_LO10:
+ return R_SPARC_TLS_LE_LOX10;
+ }
+
+ return r_type;
+}
+
/* Look through the relocs for a section during the first phase, and
allocate space in the global offset table or procedure linkage
table. */
-static boolean
+static bfd_boolean
elf32_sparc_check_relocs (abfd, info, sec, relocs)
bfd *abfd;
struct bfd_link_info *info;
asection *sec;
const Elf_Internal_Rela *relocs;
{
- bfd *dynobj;
+ struct elf32_sparc_link_hash_table *htab;
Elf_Internal_Shdr *symtab_hdr;
struct elf_link_hash_entry **sym_hashes;
bfd_vma *local_got_offsets;
const Elf_Internal_Rela *rel;
const Elf_Internal_Rela *rel_end;
- asection *sgot;
- asection *srelgot;
asection *sreloc;
+ bfd_boolean checked_tlsgd = FALSE;
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
- dynobj = elf_hash_table (info)->dynobj;
+ htab = elf32_sparc_hash_table (info);
symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
sym_hashes = elf_sym_hashes (abfd);
local_got_offsets = elf_local_got_offsets (abfd);
- sgot = NULL;
- srelgot = NULL;
sreloc = NULL;
rel_end = relocs + sec->reloc_count;
for (rel = relocs; rel < rel_end; rel++)
{
+ unsigned int r_type;
unsigned long r_symndx;
struct elf_link_hash_entry *h;
r_symndx = ELF32_R_SYM (rel->r_info);
+ r_type = ELF32_R_TYPE (rel->r_info);
+
+ if (r_symndx >= NUM_SHDR_ENTRIES (symtab_hdr))
+ {
+ (*_bfd_error_handler) (_("%s: bad symbol index: %d"),
+ bfd_archive_filename (abfd),
+ r_symndx);
+ return FALSE;
+ }
+
if (r_symndx < symtab_hdr->sh_info)
h = NULL;
else
h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- switch (ELF32_R_TYPE (rel->r_info))
+ /* Compatibility with old R_SPARC_REV32 reloc conflicting
+ with R_SPARC_TLS_GD_HI22. */
+ if (! checked_tlsgd)
+ switch (r_type)
+ {
+ case R_SPARC_TLS_GD_HI22:
+ {
+ const Elf_Internal_Rela *relt;
+
+ for (relt = rel + 1; relt < rel_end; relt++)
+ if (ELF32_R_TYPE (relt->r_info) == R_SPARC_TLS_GD_LO10
+ || ELF32_R_TYPE (relt->r_info) == R_SPARC_TLS_GD_ADD
+ || ELF32_R_TYPE (relt->r_info) == R_SPARC_TLS_GD_CALL)
+ break;
+ checked_tlsgd = TRUE;
+ elf32_sparc_tdata (abfd)->has_tlsgd = relt < rel_end;
+ }
+ break;
+ case R_SPARC_TLS_GD_LO10:
+ case R_SPARC_TLS_GD_ADD:
+ case R_SPARC_TLS_GD_CALL:
+ checked_tlsgd = TRUE;
+ elf32_sparc_tdata (abfd)->has_tlsgd = TRUE;
+ break;
+ }
+
+ r_type = elf32_sparc_tls_transition (info, abfd, r_type, h == NULL);
+ switch (r_type)
{
+ case R_SPARC_TLS_LDM_HI22:
+ case R_SPARC_TLS_LDM_LO10:
+ htab->tls_ldm_got.refcount += 1;
+ break;
+
+ case R_SPARC_TLS_LE_HIX22:
+ case R_SPARC_TLS_LE_LOX10:
+ if (info->shared)
+ goto r_sparc_plt32;
+ break;
+
+ case R_SPARC_TLS_IE_HI22:
+ case R_SPARC_TLS_IE_LO10:
+ if (info->shared)
+ info->flags |= DF_STATIC_TLS;
+ /* Fall through */
+
case R_SPARC_GOT10:
case R_SPARC_GOT13:
case R_SPARC_GOT22:
+ case R_SPARC_TLS_GD_HI22:
+ case R_SPARC_TLS_GD_LO10:
/* This symbol requires a global offset table entry. */
+ {
+ int tls_type, old_tls_type;
- if (dynobj == NULL)
- {
- /* Create the .got section. */
- elf_hash_table (info)->dynobj = dynobj = abfd;
- if (! _bfd_elf_create_got_section (dynobj, info))
- return false;
- }
+ switch (r_type)
+ {
+ default:
+ case R_SPARC_GOT10:
+ case R_SPARC_GOT13:
+ case R_SPARC_GOT22:
+ tls_type = GOT_NORMAL;
+ break;
+ case R_SPARC_TLS_GD_HI22:
+ case R_SPARC_TLS_GD_LO10:
+ tls_type = GOT_TLS_GD;
+ break;
+ case R_SPARC_TLS_IE_HI22:
+ case R_SPARC_TLS_IE_LO10:
+ tls_type = GOT_TLS_IE;
+ break;
+ }
- if (sgot == NULL)
- {
- sgot = bfd_get_section_by_name (dynobj, ".got");
- BFD_ASSERT (sgot != NULL);
- }
+ if (h != NULL)
+ {
+ h->got.refcount += 1;
+ old_tls_type = elf32_sparc_hash_entry(h)->tls_type;
+ }
+ else
+ {
+ bfd_signed_vma *local_got_refcounts;
- if (srelgot == NULL
- && (h != NULL || info->shared))
- {
- srelgot = bfd_get_section_by_name (dynobj, ".rela.got");
- if (srelgot == NULL)
- {
- srelgot = bfd_make_section (dynobj, ".rela.got");
- if (srelgot == NULL
- || ! bfd_set_section_flags (dynobj, srelgot,
- (SEC_ALLOC
- | SEC_LOAD
- | SEC_HAS_CONTENTS
- | SEC_IN_MEMORY
- | SEC_LINKER_CREATED
- | SEC_READONLY))
- || ! bfd_set_section_alignment (dynobj, srelgot, 2))
- return false;
- }
- }
+ /* This is a global offset table entry for a local symbol. */
+ local_got_refcounts = elf_local_got_refcounts (abfd);
+ if (local_got_refcounts == NULL)
+ {
+ bfd_size_type size;
+
+ size = symtab_hdr->sh_info;
+ size *= (sizeof (bfd_signed_vma) + sizeof(char));
+ local_got_refcounts = ((bfd_signed_vma *)
+ bfd_zalloc (abfd, size));
+ if (local_got_refcounts == NULL)
+ return FALSE;
+ elf_local_got_refcounts (abfd) = local_got_refcounts;
+ elf32_sparc_local_got_tls_type (abfd)
+ = (char *) (local_got_refcounts + symtab_hdr->sh_info);
+ }
+ local_got_refcounts[r_symndx] += 1;
+ old_tls_type = elf32_sparc_local_got_tls_type (abfd) [r_symndx];
+ }
- if (h != NULL)
- {
- if (h->got.offset != (bfd_vma) -1)
- {
- /* We have already allocated space in the .got. */
- break;
- }
- h->got.offset = sgot->_raw_size;
+ /* If a TLS symbol is accessed using IE at least once,
+ there is no point to use dynamic model for it. */
+ if (old_tls_type != tls_type && old_tls_type != GOT_UNKNOWN
+ && (old_tls_type != GOT_TLS_GD
+ || tls_type != GOT_TLS_IE))
+ {
+ if (old_tls_type == GOT_TLS_IE && tls_type == GOT_TLS_GD)
+ tls_type = old_tls_type;
+ else
+ {
+ (*_bfd_error_handler)
+ (_("%s: `%s' accessed both as normal and thread local symbol"),
+ bfd_archive_filename (abfd),
+ h ? h->root.root.string : "<local>");
+ return FALSE;
+ }
+ }
- /* Make sure this symbol is output as a dynamic symbol. */
- if (h->dynindx == -1)
- {
- if (! bfd_elf32_link_record_dynamic_symbol (info, h))
- return false;
- }
+ if (old_tls_type != tls_type)
+ {
+ if (h != NULL)
+ elf32_sparc_hash_entry (h)->tls_type = tls_type;
+ else
+ elf32_sparc_local_got_tls_type (abfd) [r_symndx] = tls_type;
+ }
+ }
- srelgot->_raw_size += sizeof (Elf32_External_Rela);
- }
- else
+ if (htab->sgot == NULL)
{
- /* This is a global offset table entry for a local
- symbol. */
- if (local_got_offsets == NULL)
- {
- bfd_size_type size;
- register unsigned int i;
-
- size = symtab_hdr->sh_info;
- size *= sizeof (bfd_vma);
- local_got_offsets = (bfd_vma *) bfd_alloc (abfd, size);
- if (local_got_offsets == NULL)
- return false;
- elf_local_got_offsets (abfd) = local_got_offsets;
- for (i = 0; i < symtab_hdr->sh_info; i++)
- local_got_offsets[i] = (bfd_vma) -1;
- }
- if (local_got_offsets[r_symndx] != (bfd_vma) -1)
- {
- /* We have already allocated space in the .got. */
- break;
- }
- local_got_offsets[r_symndx] = sgot->_raw_size;
-
- if (info->shared)
- {
- /* If we are generating a shared object, we need to
- output a R_SPARC_RELATIVE reloc so that the
- dynamic linker can adjust this GOT entry. */
- srelgot->_raw_size += sizeof (Elf32_External_Rela);
- }
+ if (htab->elf.dynobj == NULL)
+ htab->elf.dynobj = abfd;
+ if (!create_got_section (htab->elf.dynobj, info))
+ return FALSE;
}
-
- sgot->_raw_size += 4;
-
- /* If the .got section is more than 0x1000 bytes, we add
- 0x1000 to the value of _GLOBAL_OFFSET_TABLE_, so that 13
- bit relocations have a greater chance of working. */
- if (sgot->_raw_size >= 0x1000
- && elf_hash_table (info)->hgot->root.u.def.value == 0)
- elf_hash_table (info)->hgot->root.u.def.value = 0x1000;
-
break;
+ case R_SPARC_TLS_GD_CALL:
+ case R_SPARC_TLS_LDM_CALL:
+ if (info->shared)
+ {
+ /* These are basically R_SPARC_TLS_WPLT30 relocs against
+ __tls_get_addr. */
+ struct bfd_link_hash_entry *bh = NULL;
+ if (! _bfd_generic_link_add_one_symbol (info, abfd,
+ "__tls_get_addr", 0,
+ bfd_und_section_ptr, 0,
+ NULL, FALSE, FALSE,
+ &bh))
+ return FALSE;
+ h = (struct elf_link_hash_entry *) bh;
+ }
+ else
+ break;
+ /* Fall through */
+
case R_SPARC_PLT32:
case R_SPARC_WPLT30:
/* This symbol requires a procedure linkage table entry. We
- actually build the entry in adjust_dynamic_symbol,
- because this might be a case of linking PIC code without
- linking in any dynamic objects, in which case we don't
- need to generate a procedure linkage table after all. */
+ actually build the entry in adjust_dynamic_symbol,
+ because this might be a case of linking PIC code without
+ linking in any dynamic objects, in which case we don't
+ need to generate a procedure linkage table after all. */
if (h == NULL)
{
/* The Solaris native assembler will generate a WPLT30
- reloc for a local symbol if you assemble a call from
- one section to another when using -K pic. We treat
- it as WDISP30. */
- if (ELF32_R_TYPE (rel->r_info) != R_SPARC_WPLT30)
+ reloc for a local symbol if you assemble a call from
+ one section to another when using -K pic. We treat
+ it as WDISP30. */
+ if (ELF32_R_TYPE (rel->r_info) == R_SPARC_PLT32)
goto r_sparc_plt32;
break;
}
- /* Make sure this symbol is output as a dynamic symbol. */
- if (h->dynindx == -1)
- {
- if (! bfd_elf32_link_record_dynamic_symbol (info, h))
- return false;
- }
-
h->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_PLT;
- if (ELF32_R_TYPE (rel->r_info) != R_SPARC_WPLT30)
+ if (ELF32_R_TYPE (rel->r_info) == R_SPARC_PLT32)
goto r_sparc_plt32;
+ h->plt.refcount += 1;
break;
case R_SPARC_PC10:
@@ -537,6 +1116,7 @@ elf32_sparc_check_relocs (abfd, info, sec, relocs)
&& strcmp (h->root.root.string, "_GLOBAL_OFFSET_TABLE_") == 0)
break;
/* Fall through. */
+
case R_SPARC_DISP8:
case R_SPARC_DISP16:
case R_SPARC_DISP32:
@@ -544,23 +1124,6 @@ elf32_sparc_check_relocs (abfd, info, sec, relocs)
case R_SPARC_WDISP22:
case R_SPARC_WDISP19:
case R_SPARC_WDISP16:
- if (h != NULL)
- h->elf_link_hash_flags |= ELF_LINK_NON_GOT_REF;
-
- /* If we are linking with -Bsymbolic, we do not need to copy
- a PC relative reloc against a global symbol which is
- defined in an object we are including in the link (i.e.,
- DEF_REGULAR is set). FIXME: At this point we have not
- seen all the input files, so it is possible that
- DEF_REGULAR is not set now but will be set later (it is
- never cleared). This needs to be handled as in
- elf32-i386.c. */
- if (h == NULL
- || (info->symbolic
- && (h->elf_link_hash_flags
- & ELF_LINK_HASH_DEF_REGULAR) != 0))
- break;
- /* Fall through. */
case R_SPARC_8:
case R_SPARC_16:
case R_SPARC_32:
@@ -574,26 +1137,75 @@ elf32_sparc_check_relocs (abfd, info, sec, relocs)
h->elf_link_hash_flags |= ELF_LINK_NON_GOT_REF;
r_sparc_plt32:
- if (info->shared && (sec->flags & SEC_ALLOC))
+ if (h != NULL && !info->shared)
{
+ /* We may need a .plt entry if the function this reloc
+ refers to is in a shared lib. */
+ h->plt.refcount += 1;
+ }
+
+ /* If we are creating a shared library, and this is a reloc
+ against a global symbol, or a non PC relative reloc
+ against a local symbol, then we need to copy the reloc
+ into the shared library. However, if we are linking with
+ -Bsymbolic, we do not need to copy a reloc against a
+ global symbol which is defined in an object we are
+ including in the link (i.e., DEF_REGULAR is set). At
+ this point we have not seen all the input files, so it is
+ possible that DEF_REGULAR is not set now but will be set
+ later (it is never cleared). In case of a weak definition,
+ DEF_REGULAR may be cleared later by a strong definition in
+ a shared library. We account for that possibility below by
+ storing information in the relocs_copied field of the hash
+ table entry. A similar situation occurs when creating
+ shared libraries and symbol visibility changes render the
+ symbol local.
+
+ If on the other hand, we are creating an executable, we
+ may need to keep relocations for symbols satisfied by a
+ dynamic library if we manage to avoid copy relocs for the
+ symbol. */
+ if ((info->shared
+ && (sec->flags & SEC_ALLOC) != 0
+ && (! _bfd_sparc_elf_howto_table[r_type].pc_relative
+ || (h != NULL
+ && (! info->symbolic
+ || h->root.type == bfd_link_hash_defweak
+ || (h->elf_link_hash_flags
+ & ELF_LINK_HASH_DEF_REGULAR) == 0))))
+ || (!info->shared
+ && (sec->flags & SEC_ALLOC) != 0
+ && h != NULL
+ && (h->root.type == bfd_link_hash_defweak
+ || (h->elf_link_hash_flags
+ & ELF_LINK_HASH_DEF_REGULAR) == 0)))
+ {
+ struct elf32_sparc_dyn_relocs *p;
+ struct elf32_sparc_dyn_relocs **head;
+
/* When creating a shared object, we must copy these
- relocs into the output file. We create a reloc
- section in dynobj and make room for the reloc. */
+ relocs into the output file. We create a reloc
+ section in dynobj and make room for the reloc. */
if (sreloc == NULL)
{
const char *name;
+ bfd *dynobj;
name = (bfd_elf_string_from_elf_section
(abfd,
elf_elfheader (abfd)->e_shstrndx,
elf_section_data (sec)->rel_hdr.sh_name));
if (name == NULL)
- return false;
+ return FALSE;
BFD_ASSERT (strncmp (name, ".rela", 5) == 0
&& strcmp (bfd_get_section_name (abfd, sec),
name + 5) == 0);
+ if (htab->elf.dynobj == NULL)
+ htab->elf.dynobj = abfd;
+ dynobj = htab->elf.dynobj;
+
sreloc = bfd_get_section_by_name (dynobj, name);
if (sreloc == NULL)
{
@@ -607,33 +1219,69 @@ elf32_sparc_check_relocs (abfd, info, sec, relocs)
if (sreloc == NULL
|| ! bfd_set_section_flags (dynobj, sreloc, flags)
|| ! bfd_set_section_alignment (dynobj, sreloc, 2))
- return false;
+ return FALSE;
}
- if (sec->flags & SEC_READONLY)
- info->flags |= DF_TEXTREL;
+ elf_section_data (sec)->sreloc = sreloc;
+ }
+
+ /* If this is a global symbol, we count the number of
+ relocations we need for this symbol. */
+ if (h != NULL)
+ head = &((struct elf32_sparc_link_hash_entry *) h)->dyn_relocs;
+ else
+ {
+ /* Track dynamic relocs needed for local syms too.
+ We really need local syms available to do this
+ easily. Oh well. */
+
+ asection *s;
+ s = bfd_section_from_r_symndx (abfd, &htab->sym_sec,
+ sec, r_symndx);
+ if (s == NULL)
+ return FALSE;
+
+ head = ((struct elf32_sparc_dyn_relocs **)
+ &elf_section_data (s)->local_dynrel);
+ }
+
+ p = *head;
+ if (p == NULL || p->sec != sec)
+ {
+ bfd_size_type amt = sizeof *p;
+ p = ((struct elf32_sparc_dyn_relocs *)
+ bfd_alloc (htab->elf.dynobj, amt));
+ if (p == NULL)
+ return FALSE;
+ p->next = *head;
+ *head = p;
+ p->sec = sec;
+ p->count = 0;
+ p->pc_count = 0;
}
- sreloc->_raw_size += sizeof (Elf32_External_Rela);
+ p->count += 1;
+ if (_bfd_sparc_elf_howto_table[r_type].pc_relative)
+ p->pc_count += 1;
}
break;
- case R_SPARC_GNU_VTINHERIT:
- if (!_bfd_elf32_gc_record_vtinherit (abfd, sec, h, rel->r_offset))
- return false;
- break;
+ case R_SPARC_GNU_VTINHERIT:
+ if (!bfd_elf_gc_record_vtinherit (abfd, sec, h, rel->r_offset))
+ return FALSE;
+ break;
- case R_SPARC_GNU_VTENTRY:
- if (!_bfd_elf32_gc_record_vtentry (abfd, sec, h, rel->r_addend))
- return false;
- break;
+ case R_SPARC_GNU_VTENTRY:
+ if (!bfd_elf_gc_record_vtentry (abfd, sec, h, rel->r_addend))
+ return FALSE;
+ break;
default:
break;
}
}
- return true;
+ return TRUE;
}
static asection *
@@ -650,21 +1298,21 @@ elf32_sparc_gc_mark_hook (sec, info, rel, h, sym)
{
case R_SPARC_GNU_VTINHERIT:
case R_SPARC_GNU_VTENTRY:
- break;
+ break;
default:
- switch (h->root.type)
- {
- case bfd_link_hash_defined:
- case bfd_link_hash_defweak:
- return h->root.u.def.section;
+ switch (h->root.type)
+ {
+ case bfd_link_hash_defined:
+ case bfd_link_hash_defweak:
+ return h->root.u.def.section;
- case bfd_link_hash_common:
- return h->root.u.c.p->section;
+ case bfd_link_hash_common:
+ return h->root.u.c.p->section;
default:
break;
- }
+ }
}
}
else
@@ -674,20 +1322,19 @@ elf32_sparc_gc_mark_hook (sec, info, rel, h, sym)
}
/* Update the got entry reference counts for the section being removed. */
-static boolean
+static bfd_boolean
elf32_sparc_gc_sweep_hook (abfd, info, sec, relocs)
bfd *abfd;
struct bfd_link_info *info ATTRIBUTE_UNUSED;
asection *sec;
const Elf_Internal_Rela *relocs;
{
-
Elf_Internal_Shdr *symtab_hdr;
struct elf_link_hash_entry **sym_hashes;
bfd_signed_vma *local_got_refcounts;
const Elf_Internal_Rela *rel, *relend;
- unsigned long r_symndx;
- struct elf_link_hash_entry *h;
+
+ elf_section_data (sec)->local_dynrel = NULL;
symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
sym_hashes = elf_sym_hashes (abfd);
@@ -695,44 +1342,100 @@ elf32_sparc_gc_sweep_hook (abfd, info, sec, relocs)
relend = relocs + sec->reloc_count;
for (rel = relocs; rel < relend; rel++)
- switch (ELF32_R_TYPE (rel->r_info))
- {
- case R_SPARC_GOT10:
- case R_SPARC_GOT13:
- case R_SPARC_GOT22:
- r_symndx = ELF32_R_SYM (rel->r_info);
- if (r_symndx >= symtab_hdr->sh_info)
- {
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- if (h->got.refcount > 0)
- h->got.refcount--;
- }
- else
- {
- if (local_got_refcounts[r_symndx] > 0)
- local_got_refcounts[r_symndx]--;
- }
- break;
-
- case R_SPARC_PLT32:
- case R_SPARC_HIPLT22:
- case R_SPARC_LOPLT10:
- case R_SPARC_PCPLT32:
- case R_SPARC_PCPLT10:
- r_symndx = ELF32_R_SYM (rel->r_info);
- if (r_symndx >= symtab_hdr->sh_info)
- {
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- if (h->plt.refcount > 0)
- h->plt.refcount--;
- }
- break;
+ {
+ unsigned long r_symndx;
+ unsigned int r_type;
+ struct elf_link_hash_entry *h = NULL;
- default:
- break;
- }
+ r_symndx = ELF32_R_SYM (rel->r_info);
+ if (r_symndx >= symtab_hdr->sh_info)
+ {
+ struct elf32_sparc_link_hash_entry *eh;
+ struct elf32_sparc_dyn_relocs **pp;
+ struct elf32_sparc_dyn_relocs *p;
+
+ h = sym_hashes[r_symndx - symtab_hdr->sh_info];
+ eh = (struct elf32_sparc_link_hash_entry *) h;
+ for (pp = &eh->dyn_relocs; (p = *pp) != NULL; pp = &p->next)
+ if (p->sec == sec)
+ {
+ /* Everything must go for SEC. */
+ *pp = p->next;
+ break;
+ }
+ }
+
+ r_type = ELF32_R_TYPE (rel->r_info);
+ r_type = elf32_sparc_tls_transition (info, abfd, r_type, h != NULL);
+ switch (r_type)
+ {
+ case R_SPARC_TLS_LDM_HI22:
+ case R_SPARC_TLS_LDM_LO10:
+ if (elf32_sparc_hash_table (info)->tls_ldm_got.refcount > 0)
+ elf32_sparc_hash_table (info)->tls_ldm_got.refcount -= 1;
+ break;
+
+ case R_SPARC_TLS_GD_HI22:
+ case R_SPARC_TLS_GD_LO10:
+ case R_SPARC_TLS_IE_HI22:
+ case R_SPARC_TLS_IE_LO10:
+ case R_SPARC_GOT10:
+ case R_SPARC_GOT13:
+ case R_SPARC_GOT22:
+ if (h != NULL)
+ {
+ if (h->got.refcount > 0)
+ h->got.refcount--;
+ }
+ else
+ {
+ if (local_got_refcounts[r_symndx] > 0)
+ local_got_refcounts[r_symndx]--;
+ }
+ break;
+
+ case R_SPARC_PC10:
+ case R_SPARC_PC22:
+ if (h != NULL
+ && strcmp (h->root.root.string, "_GLOBAL_OFFSET_TABLE_") == 0)
+ break;
+ /* Fall through. */
+
+ case R_SPARC_DISP8:
+ case R_SPARC_DISP16:
+ case R_SPARC_DISP32:
+ case R_SPARC_WDISP30:
+ case R_SPARC_WDISP22:
+ case R_SPARC_WDISP19:
+ case R_SPARC_WDISP16:
+ case R_SPARC_8:
+ case R_SPARC_16:
+ case R_SPARC_32:
+ case R_SPARC_HI22:
+ case R_SPARC_22:
+ case R_SPARC_13:
+ case R_SPARC_LO10:
+ case R_SPARC_UA16:
+ case R_SPARC_UA32:
+ case R_SPARC_PLT32:
+ if (info->shared)
+ break;
+ /* Fall through. */
+
+ case R_SPARC_WPLT30:
+ if (h != NULL)
+ {
+ if (h->plt.refcount > 0)
+ h->plt.refcount--;
+ }
+ break;
+
+ default:
+ break;
+ }
+ }
- return true;
+ return TRUE;
}
/* Adjust a symbol defined by a dynamic object and referenced by a
@@ -741,19 +1444,21 @@ elf32_sparc_gc_sweep_hook (abfd, info, sec, relocs)
change the definition to something the rest of the link can
understand. */
-static boolean
+static bfd_boolean
elf32_sparc_adjust_dynamic_symbol (info, h)
struct bfd_link_info *info;
struct elf_link_hash_entry *h;
{
- bfd *dynobj;
+ struct elf32_sparc_link_hash_table *htab;
+ struct elf32_sparc_link_hash_entry * eh;
+ struct elf32_sparc_dyn_relocs *p;
asection *s;
unsigned int power_of_two;
- dynobj = elf_hash_table (info)->dynobj;
+ htab = elf32_sparc_hash_table (info);
/* Make sure we know what is going on here. */
- BFD_ASSERT (dynobj != NULL
+ BFD_ASSERT (htab->elf.dynobj != NULL
&& ((h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_PLT)
|| h->weakdef != NULL
|| ((h->elf_link_hash_flags
@@ -777,64 +1482,26 @@ elf32_sparc_adjust_dynamic_symbol (info, h)
|| h->root.type == bfd_link_hash_defweak)
&& (h->root.u.def.section->flags & SEC_CODE) != 0))
{
- if (! elf_hash_table (info)->dynamic_sections_created
- || ((!info->shared || info->symbolic || h->dynindx == -1)
- && (h->elf_link_hash_flags
- & ELF_LINK_HASH_DEF_REGULAR) != 0))
+ if (h->plt.refcount <= 0
+ || (! info->shared
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) == 0
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) == 0
+ && h->root.type != bfd_link_hash_undefweak
+ && h->root.type != bfd_link_hash_undefined))
{
/* This case can occur if we saw a WPLT30 reloc in an input
- file, but none of the input files were dynamic objects.
- Or, when linking the main application or a -Bsymbolic
- shared library against PIC code. Or when a global symbol
- has been made private, e.g. via versioning.
-
- In these cases we know what value the symbol will resolve
- to, so we don't actually need to build a procedure linkage
- table, and we can just do a WDISP30 reloc instead. */
-
+ file, but the symbol was never referred to by a dynamic
+ object, or if all references were garbage collected. In
+ such a case, we don't actually need to build a procedure
+ linkage table, and we can just do a WDISP30 reloc instead. */
+ h->plt.offset = (bfd_vma) -1;
h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
- return true;
}
- s = bfd_get_section_by_name (dynobj, ".plt");
- BFD_ASSERT (s != NULL);
-
- /* The first four entries in .plt are reserved. */
- if (s->_raw_size == 0)
- s->_raw_size = 4 * PLT_ENTRY_SIZE;
-
- /* The procedure linkage table has a maximum size. */
- if (s->_raw_size >= 0x400000)
- {
- bfd_set_error (bfd_error_bad_value);
- return false;
- }
-
- /* If this symbol is not defined in a regular file, and we are
- not generating a shared library, then set the symbol to this
- location in the .plt. This is required to make function
- pointers compare as equal between the normal executable and
- the shared library. */
- if (! info->shared
- && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
- {
- h->root.u.def.section = s;
- h->root.u.def.value = s->_raw_size;
- }
-
- h->plt.offset = s->_raw_size;
-
- /* Make room for this entry. */
- s->_raw_size += PLT_ENTRY_SIZE;
-
- /* We also need to make an entry in the .rela.plt section. */
-
- s = bfd_get_section_by_name (dynobj, ".rela.plt");
- BFD_ASSERT (s != NULL);
- s->_raw_size += sizeof (Elf32_External_Rela);
-
- return true;
+ return TRUE;
}
+ else
+ h->plt.offset = (bfd_vma) -1;
/* If this is a weak symbol, and there is a real definition, the
processor independent code will have arranged for us to see the
@@ -845,7 +1512,7 @@ elf32_sparc_adjust_dynamic_symbol (info, h)
|| h->weakdef->root.type == bfd_link_hash_defweak);
h->root.u.def.section = h->weakdef->root.u.def.section;
h->root.u.def.value = h->weakdef->root.u.def.value;
- return true;
+ return TRUE;
}
/* This is a reference to a symbol defined by a dynamic object which
@@ -856,12 +1523,28 @@ elf32_sparc_adjust_dynamic_symbol (info, h)
For such cases we need not do anything here; the relocations will
be handled correctly by relocate_section. */
if (info->shared)
- return true;
+ return TRUE;
/* If there are no references to this symbol that do not use the
GOT, we don't need to generate a copy reloc. */
if ((h->elf_link_hash_flags & ELF_LINK_NON_GOT_REF) == 0)
- return true;
+ return TRUE;
+
+ eh = (struct elf32_sparc_link_hash_entry *) h;
+ for (p = eh->dyn_relocs; p != NULL; p = p->next)
+ {
+ s = p->sec->output_section;
+ if (s != NULL && (s->flags & SEC_READONLY) != 0)
+ break;
+ }
+
+ /* If we didn't find any dynamic relocs in read-only sections, then
+ we'll be keeping the dynamic relocs and avoiding the copy reloc. */
+ if (p == NULL)
+ {
+ h->elf_link_hash_flags &= ~ELF_LINK_NON_GOT_REF;
+ return TRUE;
+ }
/* We must allocate the symbol in our .dynbss section, which will
become part of the .bss section of the executable. There will be
@@ -873,20 +1556,13 @@ elf32_sparc_adjust_dynamic_symbol (info, h)
both the dynamic object and the regular object will refer to the
same memory location for the variable. */
- s = bfd_get_section_by_name (dynobj, ".dynbss");
- BFD_ASSERT (s != NULL);
-
/* We must generate a R_SPARC_COPY reloc to tell the dynamic linker
to copy the initial value out of the dynamic object and into the
runtime process image. We need to remember the offset into the
.rel.bss section we are going to use. */
if ((h->root.u.def.section->flags & SEC_ALLOC) != 0)
{
- asection *srel;
-
- srel = bfd_get_section_by_name (dynobj, ".rela.bss");
- BFD_ASSERT (srel != NULL);
- srel->_raw_size += sizeof (Elf32_External_Rela);
+ htab->srelbss->_raw_size += sizeof (Elf32_External_Rela);
h->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_COPY;
}
@@ -897,12 +1573,13 @@ elf32_sparc_adjust_dynamic_symbol (info, h)
power_of_two = 3;
/* Apply the required alignment. */
+ s = htab->sdynbss;
s->_raw_size = BFD_ALIGN (s->_raw_size,
(bfd_size_type) (1 << power_of_two));
if (power_of_two > bfd_get_section_alignment (dynobj, s))
{
if (! bfd_set_section_alignment (dynobj, s, power_of_two))
- return false;
+ return FALSE;
}
/* Define the symbol as being at this point in the section. */
@@ -912,60 +1589,372 @@ elf32_sparc_adjust_dynamic_symbol (info, h)
/* Increment the section size to make room for the symbol. */
s->_raw_size += h->size;
- return true;
+ return TRUE;
+}
+
+/* Allocate space in .plt, .got and associated reloc sections for
+ dynamic relocs. */
+
+static bfd_boolean
+allocate_dynrelocs (h, inf)
+ struct elf_link_hash_entry *h;
+ PTR inf;
+{
+ struct bfd_link_info *info;
+ struct elf32_sparc_link_hash_table *htab;
+ struct elf32_sparc_link_hash_entry *eh;
+ struct elf32_sparc_dyn_relocs *p;
+
+ if (h->root.type == bfd_link_hash_indirect)
+ return TRUE;
+
+ if (h->root.type == bfd_link_hash_warning)
+ /* When warning symbols are created, they **replace** the "real"
+ entry in the hash table, thus we never get to see the real
+ symbol in a hash traversal. So look at it now. */
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ info = (struct bfd_link_info *) inf;
+ htab = elf32_sparc_hash_table (info);
+
+ if (htab->elf.dynamic_sections_created
+ && h->plt.refcount > 0)
+ {
+ /* Make sure this symbol is output as a dynamic symbol.
+ Undefined weak syms won't yet be marked as dynamic. */
+ if (h->dynindx == -1
+ && (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
+ }
+
+ if (WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, info->shared, h))
+ {
+ asection *s = htab->splt;
+
+ /* The first four entries in .plt are reserved. */
+ if (s->_raw_size == 0)
+ s->_raw_size = 4 * PLT_ENTRY_SIZE;
+
+ /* The procedure linkage table has a maximum size. */
+ if (s->_raw_size >= 0x400000)
+ {
+ bfd_set_error (bfd_error_bad_value);
+ return FALSE;
+ }
+
+ h->plt.offset = s->_raw_size;
+
+ /* If this symbol is not defined in a regular file, and we are
+ not generating a shared library, then set the symbol to this
+ location in the .plt. This is required to make function
+ pointers compare as equal between the normal executable and
+ the shared library. */
+ if (! info->shared
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
+ {
+ h->root.u.def.section = s;
+ h->root.u.def.value = h->plt.offset;
+ }
+
+ /* Make room for this entry. */
+ s->_raw_size += PLT_ENTRY_SIZE;
+
+ /* We also need to make an entry in the .rela.plt section. */
+ htab->srelplt->_raw_size += sizeof (Elf32_External_Rela);
+ }
+ else
+ {
+ h->plt.offset = (bfd_vma) -1;
+ h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
+ }
+ }
+ else
+ {
+ h->plt.offset = (bfd_vma) -1;
+ h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
+ }
+
+ /* If R_SPARC_TLS_IE_{HI22,LO10} symbol is now local to the binary,
+ make it a R_SPARC_TLS_LE_{HI22,LO10} requiring no TLS entry. */
+ if (h->got.refcount > 0
+ && !info->shared
+ && h->dynindx == -1
+ && elf32_sparc_hash_entry(h)->tls_type == GOT_TLS_IE)
+ h->got.offset = (bfd_vma) -1;
+ else if (h->got.refcount > 0)
+ {
+ asection *s;
+ bfd_boolean dyn;
+ int tls_type = elf32_sparc_hash_entry(h)->tls_type;
+
+ /* Make sure this symbol is output as a dynamic symbol.
+ Undefined weak syms won't yet be marked as dynamic. */
+ if (h->dynindx == -1
+ && (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
+ }
+
+ s = htab->sgot;
+ h->got.offset = s->_raw_size;
+ s->_raw_size += 4;
+ /* R_SPARC_TLS_GD_HI{22,LO10} needs 2 consecutive GOT slots. */
+ if (tls_type == GOT_TLS_GD)
+ s->_raw_size += 4;
+ dyn = htab->elf.dynamic_sections_created;
+ /* R_SPARC_TLS_IE_{HI22,LO10} needs one dynamic relocation,
+ R_SPARC_TLS_GD_{HI22,LO10} needs one if local symbol and two if
+ global. */
+ if ((tls_type == GOT_TLS_GD && h->dynindx == -1)
+ || tls_type == GOT_TLS_IE)
+ htab->srelgot->_raw_size += sizeof (Elf32_External_Rela);
+ else if (tls_type == GOT_TLS_GD)
+ htab->srelgot->_raw_size += 2 * sizeof (Elf32_External_Rela);
+ else if (WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info->shared, h))
+ htab->srelgot->_raw_size += sizeof (Elf32_External_Rela);
+ }
+ else
+ h->got.offset = (bfd_vma) -1;
+
+ eh = (struct elf32_sparc_link_hash_entry *) h;
+ if (eh->dyn_relocs == NULL)
+ return TRUE;
+
+ /* In the shared -Bsymbolic case, discard space allocated for
+ dynamic pc-relative relocs against symbols which turn out to be
+ defined in regular objects. For the normal shared case, discard
+ space for pc-relative relocs that have become local due to symbol
+ visibility changes. */
+
+ if (info->shared)
+ {
+ if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0
+ && ((h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0
+ || info->symbolic))
+ {
+ struct elf32_sparc_dyn_relocs **pp;
+
+ for (pp = &eh->dyn_relocs; (p = *pp) != NULL; )
+ {
+ p->count -= p->pc_count;
+ p->pc_count = 0;
+ if (p->count == 0)
+ *pp = p->next;
+ else
+ pp = &p->next;
+ }
+ }
+ }
+ else
+ {
+ /* For the non-shared case, discard space for relocs against
+ symbols which turn out to need copy relocs or are not
+ dynamic. */
+
+ if ((h->elf_link_hash_flags & ELF_LINK_NON_GOT_REF) == 0
+ && (((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
+ || (htab->elf.dynamic_sections_created
+ && (h->root.type == bfd_link_hash_undefweak
+ || h->root.type == bfd_link_hash_undefined))))
+ {
+ /* Make sure this symbol is output as a dynamic symbol.
+ Undefined weak syms won't yet be marked as dynamic. */
+ if (h->dynindx == -1
+ && (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
+ }
+
+ /* If that succeeded, we know we'll be keeping all the
+ relocs. */
+ if (h->dynindx != -1)
+ goto keep;
+ }
+
+ eh->dyn_relocs = NULL;
+
+ keep: ;
+ }
+
+ /* Finally, allocate space. */
+ for (p = eh->dyn_relocs; p != NULL; p = p->next)
+ {
+ asection *sreloc = elf_section_data (p->sec)->sreloc;
+ sreloc->_raw_size += p->count * sizeof (Elf32_External_Rela);
+ }
+
+ return TRUE;
+}
+
+/* Find any dynamic relocs that apply to read-only sections. */
+
+static bfd_boolean
+readonly_dynrelocs (h, inf)
+ struct elf_link_hash_entry *h;
+ PTR inf;
+{
+ struct elf32_sparc_link_hash_entry *eh;
+ struct elf32_sparc_dyn_relocs *p;
+
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ eh = (struct elf32_sparc_link_hash_entry *) h;
+ for (p = eh->dyn_relocs; p != NULL; p = p->next)
+ {
+ asection *s = p->sec->output_section;
+
+ if (s != NULL && (s->flags & SEC_READONLY) != 0)
+ {
+ struct bfd_link_info *info = (struct bfd_link_info *) inf;
+
+ info->flags |= DF_TEXTREL;
+
+ /* Not an error, just cut short the traversal. */
+ return FALSE;
+ }
+ }
+ return TRUE;
}
/* Set the sizes of the dynamic sections. */
-static boolean
+static bfd_boolean
elf32_sparc_size_dynamic_sections (output_bfd, info)
bfd *output_bfd ATTRIBUTE_UNUSED;
struct bfd_link_info *info;
{
+ struct elf32_sparc_link_hash_table *htab;
bfd *dynobj;
asection *s;
- boolean relplt;
+ bfd *ibfd;
- dynobj = elf_hash_table (info)->dynobj;
+ htab = elf32_sparc_hash_table (info);
+ dynobj = htab->elf.dynobj;
BFD_ASSERT (dynobj != NULL);
if (elf_hash_table (info)->dynamic_sections_created)
{
/* Set the contents of the .interp section to the interpreter. */
- if (! info->shared)
+ if (info->executable)
{
s = bfd_get_section_by_name (dynobj, ".interp");
BFD_ASSERT (s != NULL);
s->_raw_size = sizeof ELF_DYNAMIC_INTERPRETER;
s->contents = (unsigned char *) ELF_DYNAMIC_INTERPRETER;
}
+ }
- /* Make space for the trailing nop in .plt. */
- s = bfd_get_section_by_name (dynobj, ".plt");
- BFD_ASSERT (s != NULL);
- if (s->_raw_size > 0)
- s->_raw_size += 4;
+ /* Set up .got offsets for local syms, and space for local dynamic
+ relocs. */
+ for (ibfd = info->input_bfds; ibfd != NULL; ibfd = ibfd->link_next)
+ {
+ bfd_signed_vma *local_got;
+ bfd_signed_vma *end_local_got;
+ char *local_tls_type;
+ bfd_size_type locsymcount;
+ Elf_Internal_Shdr *symtab_hdr;
+ asection *srel;
+
+ if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour)
+ continue;
+
+ for (s = ibfd->sections; s != NULL; s = s->next)
+ {
+ struct elf32_sparc_dyn_relocs *p;
+
+ for (p = *((struct elf32_sparc_dyn_relocs **)
+ &elf_section_data (s)->local_dynrel);
+ p != NULL;
+ p = p->next)
+ {
+ if (!bfd_is_abs_section (p->sec)
+ && bfd_is_abs_section (p->sec->output_section))
+ {
+ /* Input section has been discarded, either because
+ it is a copy of a linkonce section or due to
+ linker script /DISCARD/, so we'll be discarding
+ the relocs too. */
+ }
+ else if (p->count != 0)
+ {
+ srel = elf_section_data (p->sec)->sreloc;
+ srel->_raw_size += p->count * sizeof (Elf32_External_Rela);
+ if ((p->sec->output_section->flags & SEC_READONLY) != 0)
+ info->flags |= DF_TEXTREL;
+ }
+ }
+ }
+
+ local_got = elf_local_got_refcounts (ibfd);
+ if (!local_got)
+ continue;
+
+ symtab_hdr = &elf_tdata (ibfd)->symtab_hdr;
+ locsymcount = symtab_hdr->sh_info;
+ end_local_got = local_got + locsymcount;
+ local_tls_type = elf32_sparc_local_got_tls_type (ibfd);
+ s = htab->sgot;
+ srel = htab->srelgot;
+ for (; local_got < end_local_got; ++local_got, ++local_tls_type)
+ {
+ if (*local_got > 0)
+ {
+ *local_got = s->_raw_size;
+ s->_raw_size += 4;
+ if (*local_tls_type == GOT_TLS_GD)
+ s->_raw_size += 4;
+ if (info->shared
+ || *local_tls_type == GOT_TLS_GD
+ || *local_tls_type == GOT_TLS_IE)
+ srel->_raw_size += sizeof (Elf32_External_Rela);
+ }
+ else
+ *local_got = (bfd_vma) -1;
+ }
+ }
+
+ if (htab->tls_ldm_got.refcount > 0)
+ {
+ /* Allocate 2 got entries and 1 dynamic reloc for
+ R_SPARC_TLS_LDM_{HI22,LO10} relocs. */
+ htab->tls_ldm_got.offset = htab->sgot->_raw_size;
+ htab->sgot->_raw_size += 8;
+ htab->srelgot->_raw_size += sizeof (Elf32_External_Rela);
}
else
+ htab->tls_ldm_got.offset = -1;
+
+ /* Allocate global sym .plt and .got entries, and space for global
+ sym dynamic relocs. */
+ elf_link_hash_traverse (&htab->elf, allocate_dynrelocs, (PTR) info);
+
+ if (elf_hash_table (info)->dynamic_sections_created)
{
- /* We may have created entries in the .rela.got section.
- However, if we are not creating the dynamic sections, we will
- not actually use these entries. Reset the size of .rela.got,
- which will cause it to get stripped from the output file
- below. */
- s = bfd_get_section_by_name (dynobj, ".rela.got");
- if (s != NULL)
- s->_raw_size = 0;
+ /* Make space for the trailing nop in .plt. */
+ if (htab->splt->_raw_size > 0)
+ htab->splt->_raw_size += 4;
+
+ /* If the .got section is more than 0x1000 bytes, we add
+ 0x1000 to the value of _GLOBAL_OFFSET_TABLE_, so that 13
+ bit relocations have a greater chance of working. */
+ if (htab->sgot->_raw_size >= 0x1000
+ && elf_hash_table (info)->hgot->root.u.def.value == 0)
+ elf_hash_table (info)->hgot->root.u.def.value = 0x1000;
}
/* The check_relocs and adjust_dynamic_symbol entry points have
determined the sizes of the various dynamic sections. Allocate
memory for them. */
- relplt = false;
for (s = dynobj->sections; s != NULL; s = s->next)
{
const char *name;
- boolean strip;
+ bfd_boolean strip = FALSE;
if ((s->flags & SEC_LINKER_CREATED) == 0)
continue;
@@ -974,8 +1963,6 @@ elf32_sparc_size_dynamic_sections (output_bfd, info)
of the dynobj section names depend upon the input files. */
name = bfd_get_section_name (dynobj, s);
- strip = false;
-
if (strncmp (name, ".rela", 5) == 0)
{
if (s->_raw_size == 0)
@@ -989,20 +1976,16 @@ elf32_sparc_size_dynamic_sections (output_bfd, info)
adjust_dynamic_symbol is called, and it is that
function which decides whether anything needs to go
into these sections. */
- strip = true;
+ strip = TRUE;
}
else
{
- if (strcmp (name, ".rela.plt") == 0)
- relplt = true;
-
/* We use the reloc_count field as a counter if we need
to copy relocs into the output file. */
s->reloc_count = 0;
}
}
- else if (strcmp (name, ".plt") != 0
- && strcmp (name, ".got") != 0)
+ else if (s != htab->splt && s != htab->sgot)
{
/* It's not one of our sections, so don't allocate space. */
continue;
@@ -1022,7 +2005,7 @@ elf32_sparc_size_dynamic_sections (output_bfd, info)
contents to zero. */
s->contents = (bfd_byte *) bfd_zalloc (dynobj, s->_raw_size);
if (s->contents == NULL && s->_raw_size != 0)
- return false;
+ return FALSE;
}
if (elf_hash_table (info)->dynamic_sections_created)
@@ -1033,68 +2016,115 @@ elf32_sparc_size_dynamic_sections (output_bfd, info)
the .dynamic section. The DT_DEBUG entry is filled in by the
dynamic linker and used by the debugger. */
#define add_dynamic_entry(TAG, VAL) \
- bfd_elf32_add_dynamic_entry (info, (bfd_vma) (TAG), (bfd_vma) (VAL))
+ _bfd_elf_add_dynamic_entry (info, TAG, VAL)
- if (!info->shared)
+ if (info->executable)
{
if (!add_dynamic_entry (DT_DEBUG, 0))
- return false;
+ return FALSE;
}
- if (relplt)
+ if (htab->srelplt->_raw_size != 0)
{
if (!add_dynamic_entry (DT_PLTGOT, 0)
|| !add_dynamic_entry (DT_PLTRELSZ, 0)
|| !add_dynamic_entry (DT_PLTREL, DT_RELA)
|| !add_dynamic_entry (DT_JMPREL, 0))
- return false;
+ return FALSE;
}
if (!add_dynamic_entry (DT_RELA, 0)
|| !add_dynamic_entry (DT_RELASZ, 0)
|| !add_dynamic_entry (DT_RELAENT, sizeof (Elf32_External_Rela)))
- return false;
+ return FALSE;
+
+ /* If any dynamic relocs apply to a read-only section,
+ then we need a DT_TEXTREL entry. */
+ if ((info->flags & DF_TEXTREL) == 0)
+ elf_link_hash_traverse (&htab->elf, readonly_dynrelocs,
+ (PTR) info);
if (info->flags & DF_TEXTREL)
{
if (!add_dynamic_entry (DT_TEXTREL, 0))
- return false;
+ return FALSE;
}
}
#undef add_dynamic_entry
- return true;
+ return TRUE;
}
-#define SET_SEC_DO_RELAX(section) do { elf_section_data(section)->tdata = (void *)1; } while (0)
-#define SEC_DO_RELAX(section) (elf_section_data(section)->tdata == (void *)1)
+struct elf32_sparc_section_data
+{
+ struct bfd_elf_section_data elf;
+ unsigned int do_relax;
+};
+
+#define sec_do_relax(sec) \
+ ((struct elf32_sparc_section_data *) elf_section_data (sec))->do_relax
-static boolean
+static bfd_boolean
+elf32_sparc_new_section_hook (abfd, sec)
+ bfd *abfd;
+ asection *sec;
+{
+ struct elf32_sparc_section_data *sdata;
+ bfd_size_type amt = sizeof (*sdata);
+
+ sdata = (struct elf32_sparc_section_data *) bfd_zalloc (abfd, amt);
+ if (sdata == NULL)
+ return FALSE;
+ sec->used_by_bfd = (PTR) sdata;
+
+ return _bfd_elf_new_section_hook (abfd, sec);
+}
+
+static bfd_boolean
elf32_sparc_relax_section (abfd, section, link_info, again)
bfd *abfd ATTRIBUTE_UNUSED;
asection *section ATTRIBUTE_UNUSED;
struct bfd_link_info *link_info ATTRIBUTE_UNUSED;
- boolean *again;
+ bfd_boolean *again;
+{
+ *again = FALSE;
+ sec_do_relax (section) = 1;
+ return TRUE;
+}
+
+/* Return the base VMA address which should be subtracted from real addresses
+ when resolving @dtpoff relocation.
+ This is PT_TLS segment p_vaddr. */
+
+static bfd_vma
+dtpoff_base (info)
+ struct bfd_link_info *info;
{
- *again = false;
- SET_SEC_DO_RELAX (section);
- return true;
+ /* If tls_sec is NULL, we should have signalled an error already. */
+ if (elf_hash_table (info)->tls_sec == NULL)
+ return 0;
+ return elf_hash_table (info)->tls_sec->vma;
}
-/* This is the condition under which finish_dynamic_symbol will be called
- from elflink.h. If elflink.h doesn't call our finish_dynamic_symbol
- routine, we'll need to do something about initializing any .plt and .got
- entries in relocate_section. */
-#define WILL_CALL_FINISH_DYNAMIC_SYMBOL(DYN, INFO, H) \
- ((DYN) \
- && ((INFO)->shared \
- || ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0) \
- && ((H)->dynindx != -1 \
- || ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0))
+/* Return the relocation value for @tpoff relocation
+ if STT_TLS virtual address is ADDRESS. */
+
+static bfd_vma
+tpoff (info, address)
+ struct bfd_link_info *info;
+ bfd_vma address;
+{
+ struct elf_link_hash_table *htab = elf_hash_table (info);
+
+ /* If tls_sec is NULL, we should have signalled an error already. */
+ if (htab->tls_sec == NULL)
+ return 0;
+ return address - htab->tls_size - htab->tls_sec->vma;
+}
/* Relocate a SPARC ELF section. */
-static boolean
+static bfd_boolean
elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
contents, relocs, local_syms, local_sections)
bfd *output_bfd;
@@ -1106,18 +2136,19 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
Elf_Internal_Sym *local_syms;
asection **local_sections;
{
- bfd *dynobj;
+ struct elf32_sparc_link_hash_table *htab;
Elf_Internal_Shdr *symtab_hdr;
struct elf_link_hash_entry **sym_hashes;
bfd_vma *local_got_offsets;
bfd_vma got_base;
- asection *sgot;
- asection *splt;
asection *sreloc;
Elf_Internal_Rela *rel;
Elf_Internal_Rela *relend;
- dynobj = elf_hash_table (info)->dynobj;
+ if (info->relocatable)
+ return TRUE;
+
+ htab = elf32_sparc_hash_table (info);
symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
sym_hashes = elf_sym_hashes (input_bfd);
local_got_offsets = elf_local_got_offsets (input_bfd);
@@ -1127,15 +2158,13 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
else
got_base = elf_hash_table (info)->hgot->root.u.def.value;
- sgot = NULL;
- splt = NULL;
- sreloc = NULL;
+ sreloc = elf_section_data (input_section)->sreloc;
rel = relocs;
relend = relocs + input_section->reloc_count;
for (; rel < relend; rel++)
{
- int r_type;
+ int r_type, tls_type;
reloc_howto_type *howto;
unsigned long r_symndx;
struct elf_link_hash_entry *h;
@@ -1143,93 +2172,42 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
asection *sec;
bfd_vma relocation, off;
bfd_reloc_status_type r;
- boolean is_plt = false;
- boolean unresolved_reloc;
+ bfd_boolean is_plt = FALSE;
+ bfd_boolean unresolved_reloc;
r_type = ELF32_R_TYPE (rel->r_info);
if (r_type == R_SPARC_GNU_VTINHERIT
- || r_type == R_SPARC_GNU_VTENTRY)
- continue;
+ || r_type == R_SPARC_GNU_VTENTRY)
+ continue;
if (r_type < 0 || r_type >= (int) R_SPARC_max_std)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
howto = _bfd_sparc_elf_howto_table + r_type;
- r_symndx = ELF32_R_SYM (rel->r_info);
-
- if (info->relocateable)
- {
- /* This is a relocateable link. We don't have to change
- anything, unless the reloc is against a section symbol,
- in which case we have to adjust according to where the
- section symbol winds up in the output section. */
- if (r_symndx < symtab_hdr->sh_info)
- {
- sym = local_syms + r_symndx;
- if (ELF_ST_TYPE (sym->st_info) == STT_SECTION)
- {
- sec = local_sections[r_symndx];
- rel->r_addend += sec->output_offset + sym->st_value;
- }
- }
-
- continue;
- }
-
/* This is a final link. */
+ r_symndx = ELF32_R_SYM (rel->r_info);
h = NULL;
sym = NULL;
sec = NULL;
- unresolved_reloc = false;
+ unresolved_reloc = FALSE;
if (r_symndx < symtab_hdr->sh_info)
{
sym = local_syms + r_symndx;
sec = local_sections[r_symndx];
- relocation = _bfd_elf_rela_local_sym (output_bfd, sym, sec, rel);
+ relocation = _bfd_elf_rela_local_sym (output_bfd, sym, &sec, rel);
}
else
{
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- while (h->root.type == bfd_link_hash_indirect
- || h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
+ bfd_boolean warned ATTRIBUTE_UNUSED;
- relocation = 0;
- if (h->root.type == bfd_link_hash_defined
- || h->root.type == bfd_link_hash_defweak)
- {
- sec = h->root.u.def.section;
- if (sec->output_section == NULL)
- /* Set a flag that will be cleared later if we find a
- relocation value for this symbol. output_section
- is typically NULL for symbols satisfied by a shared
- library. */
- unresolved_reloc = true;
- else
- relocation = (h->root.u.def.value
- + sec->output_section->vma
- + sec->output_offset);
- }
- else if (h->root.type == bfd_link_hash_undefweak)
- ;
- else if (info->shared
- && (!info->symbolic || info->allow_shlib_undefined)
- && !info->no_undefined
- && ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
- ;
- else
- {
- if (! ((*info->callbacks->undefined_symbol)
- (info, h->root.root.string, input_bfd,
- input_section, rel->r_offset,
- (!info->shared || info->no_undefined
- || ELF_ST_VISIBILITY (h->other)))))
- return false;
- }
+ RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
+ r_symndx, symtab_hdr, sym_hashes,
+ h, sec, relocation,
+ unresolved_reloc, warned);
}
switch (r_type)
@@ -1238,22 +2216,19 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
case R_SPARC_GOT13:
case R_SPARC_GOT22:
/* Relocation is to the entry for this symbol in the global
- offset table. */
- if (sgot == NULL)
- {
- sgot = bfd_get_section_by_name (dynobj, ".got");
- BFD_ASSERT (sgot != NULL);
- }
+ offset table. */
+ if (htab->sgot == NULL)
+ abort ();
if (h != NULL)
{
- boolean dyn;
+ bfd_boolean dyn;
off = h->got.offset;
BFD_ASSERT (off != (bfd_vma) -1);
dyn = elf_hash_table (info)->dynamic_sections_created;
- if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info, h)
+ if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info->shared, h)
|| (info->shared
&& (info->symbolic
|| h->dynindx == -1
@@ -1261,13 +2236,13 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
&& (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR)))
{
/* This is actually a static link, or it is a
- -Bsymbolic link and the symbol is defined
- locally, or the symbol was forced to be local
- because of a version file. We must initialize
- this entry in the global offset table. Since the
- offset must always be a multiple of 4, we use the
- least significant bit to record whether we have
- initialized it already.
+ -Bsymbolic link and the symbol is defined
+ locally, or the symbol was forced to be local
+ because of a version file. We must initialize
+ this entry in the global offset table. Since the
+ offset must always be a multiple of 4, we use the
+ least significant bit to record whether we have
+ initialized it already.
When doing a dynamic link, we create a .rela.got
relocation entry to initialize the value. This
@@ -1277,12 +2252,12 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
else
{
bfd_put_32 (output_bfd, relocation,
- sgot->contents + off);
+ htab->sgot->contents + off);
h->got.offset |= 1;
}
}
else
- unresolved_reloc = false;
+ unresolved_reloc = FALSE;
}
else
{
@@ -1301,32 +2276,32 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
if (info->shared)
{
- asection *srelgot;
+ asection *s;
Elf_Internal_Rela outrel;
+ bfd_byte *loc;
/* We need to generate a R_SPARC_RELATIVE reloc
for the dynamic linker. */
- srelgot = bfd_get_section_by_name (dynobj, ".rela.got");
- BFD_ASSERT (srelgot != NULL);
+ s = htab->srelgot;
+ BFD_ASSERT (s != NULL);
- outrel.r_offset = (sgot->output_section->vma
- + sgot->output_offset
+ outrel.r_offset = (htab->sgot->output_section->vma
+ + htab->sgot->output_offset
+ off);
outrel.r_info = ELF32_R_INFO (0, R_SPARC_RELATIVE);
outrel.r_addend = relocation;
relocation = 0;
- bfd_elf32_swap_reloca_out (output_bfd, &outrel,
- (((Elf32_External_Rela *)
- srelgot->contents)
- + srelgot->reloc_count));
- ++srelgot->reloc_count;
+ loc = s->contents;
+ loc += s->reloc_count++ * sizeof (Elf32_External_Rela);
+ bfd_elf32_swap_reloca_out (output_bfd, &outrel, loc);
}
- bfd_put_32 (output_bfd, relocation, sgot->contents + off);
+ bfd_put_32 (output_bfd, relocation,
+ htab->sgot->contents + off);
local_got_offsets[r_symndx] |= 1;
}
}
- relocation = sgot->output_offset + off - got_base;
+ relocation = htab->sgot->output_offset + off - got_base;
break;
case R_SPARC_PLT32:
@@ -1337,8 +2312,9 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
}
/* Fall through. */
case R_SPARC_WPLT30:
+ r_sparc_wplt30:
/* Relocation is to the entry for this symbol in the
- procedure linkage table. */
+ procedure linkage table. */
/* The Solaris native assembler will generate a WPLT30 reloc
for a local symbol if you assemble a call from one
@@ -1347,28 +2323,22 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
if (h == NULL)
break;
- if (h->plt.offset == (bfd_vma) -1)
+ if (h->plt.offset == (bfd_vma) -1 || htab->splt == NULL)
{
/* We didn't make a PLT entry for this symbol. This
- happens when statically linking PIC code, or when
- using -Bsymbolic. */
+ happens when statically linking PIC code, or when
+ using -Bsymbolic. */
break;
}
- if (splt == NULL)
- {
- splt = bfd_get_section_by_name (dynobj, ".plt");
- BFD_ASSERT (splt != NULL);
- }
-
- relocation = (splt->output_section->vma
- + splt->output_offset
+ relocation = (htab->splt->output_section->vma
+ + htab->splt->output_offset
+ h->plt.offset);
- unresolved_reloc = false;
+ unresolved_reloc = FALSE;
if (r_type == R_SPARC_PLT32)
{
r_type = R_SPARC_32;
- is_plt = true;
+ is_plt = TRUE;
goto r_sparc_plt32;
}
break;
@@ -1386,12 +2356,6 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
case R_SPARC_WDISP22:
case R_SPARC_WDISP19:
case R_SPARC_WDISP16:
- if (h == NULL
- || (info->symbolic
- && (h->elf_link_hash_flags
- & ELF_LINK_HASH_DEF_REGULAR) != 0))
- break;
- /* Fall through. */
case R_SPARC_8:
case R_SPARC_16:
case R_SPARC_32:
@@ -1402,46 +2366,50 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
case R_SPARC_UA16:
case R_SPARC_UA32:
r_sparc_plt32:
- if (info->shared
- && r_symndx != 0
- && (input_section->flags & SEC_ALLOC))
+ /* r_symndx will be zero only for relocs against symbols
+ from removed linkonce sections, or sections discarded by
+ a linker script. */
+ if (r_symndx == 0
+ || (input_section->flags & SEC_ALLOC) == 0)
+ break;
+
+ if ((info->shared
+ && (! howto->pc_relative
+ || (h != NULL
+ && h->dynindx != -1
+ && (! info->symbolic
+ || (h->elf_link_hash_flags
+ & ELF_LINK_HASH_DEF_REGULAR) == 0))))
+ || (!info->shared
+ && h != NULL
+ && h->dynindx != -1
+ && (h->elf_link_hash_flags & ELF_LINK_NON_GOT_REF) == 0
+ && (((h->elf_link_hash_flags
+ & ELF_LINK_HASH_DEF_DYNAMIC) != 0
+ && (h->elf_link_hash_flags
+ & ELF_LINK_HASH_DEF_REGULAR) == 0)
+ || h->root.type == bfd_link_hash_undefweak
+ || h->root.type == bfd_link_hash_undefined)))
{
Elf_Internal_Rela outrel;
- boolean skip, relocate = false;
+ bfd_byte *loc;
+ bfd_boolean skip, relocate = FALSE;
/* When generating a shared object, these relocations
- are copied into the output file to be resolved at run
- time. */
+ are copied into the output file to be resolved at run
+ time. */
- if (sreloc == NULL)
- {
- const char *name;
-
- name = (bfd_elf_string_from_elf_section
- (input_bfd,
- elf_elfheader (input_bfd)->e_shstrndx,
- elf_section_data (input_section)->rel_hdr.sh_name));
- if (name == NULL)
- return false;
+ BFD_ASSERT (sreloc != NULL);
- BFD_ASSERT (strncmp (name, ".rela", 5) == 0
- && strcmp (bfd_get_section_name (input_bfd,
- input_section),
- name + 5) == 0);
-
- sreloc = bfd_get_section_by_name (dynobj, name);
- BFD_ASSERT (sreloc != NULL);
- }
-
- skip = false;
+ skip = FALSE;
outrel.r_offset =
_bfd_elf_section_offset (output_bfd, info, input_section,
rel->r_offset);
if (outrel.r_offset == (bfd_vma) -1)
- skip = true;
+ skip = TRUE;
else if (outrel.r_offset == (bfd_vma) -2)
- skip = true, relocate = true;
+ skip = TRUE, relocate = TRUE;
outrel.r_offset += (input_section->output_section->vma
+ input_section->output_offset);
@@ -1474,14 +2442,14 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
FIXME: Add code tracking needed dynamic relocs as
e.g. i386 has. */
if (h->dynindx == -1)
- skip = true, relocate = true;
+ skip = TRUE, relocate = TRUE;
break;
}
if (skip)
memset (&outrel, 0, sizeof outrel);
/* h->dynindx may be -1 if the symbol was marked to
- become local. */
+ become local. */
else if (h != NULL && ! is_plt
&& ((! info->symbolic && h->dynindx != -1)
|| (h->elf_link_hash_flags
@@ -1503,22 +2471,14 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
long indx;
if (is_plt)
- sec = splt;
- else if (h == NULL)
- sec = local_sections[r_symndx];
- else
- {
- BFD_ASSERT (h->root.type == bfd_link_hash_defined
- || (h->root.type
- == bfd_link_hash_defweak));
- sec = h->root.u.def.section;
- }
- if (sec != NULL && bfd_is_abs_section (sec))
+ sec = htab->splt;
+
+ if (bfd_is_abs_section (sec))
indx = 0;
else if (sec == NULL || sec->owner == NULL)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
else
{
@@ -1536,7 +2496,7 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
(_("%s: probably compiled without -fPIC?"),
bfd_archive_filename (input_bfd));
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
}
@@ -1545,19 +2505,341 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
}
}
- bfd_elf32_swap_reloca_out (output_bfd, &outrel,
- (((Elf32_External_Rela *)
- sreloc->contents)
- + sreloc->reloc_count));
- ++sreloc->reloc_count;
+ loc = sreloc->contents;
+ loc += sreloc->reloc_count++ * sizeof (Elf32_External_Rela);
+ bfd_elf32_swap_reloca_out (output_bfd, &outrel, loc);
/* This reloc will be computed at runtime, so there's no
- need to do anything now. */
+ need to do anything now. */
if (! relocate)
continue;
}
break;
+ case R_SPARC_TLS_GD_HI22:
+ if (! elf32_sparc_tdata (input_bfd)->has_tlsgd)
+ {
+ /* R_SPARC_REV32 used the same reloc number as
+ R_SPARC_TLS_GD_HI22. */
+ r_type = R_SPARC_REV32;
+ break;
+ }
+ /* Fall through */
+
+ case R_SPARC_TLS_GD_LO10:
+ case R_SPARC_TLS_IE_HI22:
+ case R_SPARC_TLS_IE_LO10:
+ r_type = elf32_sparc_tls_transition (info, input_bfd, r_type,
+ h == NULL);
+ tls_type = GOT_UNKNOWN;
+ if (h == NULL && local_got_offsets)
+ tls_type = elf32_sparc_local_got_tls_type (input_bfd) [r_symndx];
+ else if (h != NULL)
+ {
+ tls_type = elf32_sparc_hash_entry(h)->tls_type;
+ if (!info->shared && h->dynindx == -1 && tls_type == GOT_TLS_IE)
+ switch (ELF32_R_TYPE (rel->r_info))
+ {
+ case R_SPARC_TLS_GD_HI22:
+ case R_SPARC_TLS_IE_HI22:
+ r_type = R_SPARC_TLS_LE_HIX22;
+ break;
+ default:
+ r_type = R_SPARC_TLS_LE_LOX10;
+ break;
+ }
+ }
+ if (tls_type == GOT_TLS_IE)
+ switch (r_type)
+ {
+ case R_SPARC_TLS_GD_HI22:
+ r_type = R_SPARC_TLS_IE_HI22;
+ break;
+ case R_SPARC_TLS_GD_LO10:
+ r_type = R_SPARC_TLS_IE_LO10;
+ break;
+ }
+
+ if (r_type == R_SPARC_TLS_LE_HIX22)
+ {
+ relocation = tpoff (info, relocation);
+ break;
+ }
+ if (r_type == R_SPARC_TLS_LE_LOX10)
+ {
+ /* Change add into xor. */
+ relocation = tpoff (info, relocation);
+ bfd_put_32 (output_bfd, (bfd_get_32 (input_bfd,
+ contents + rel->r_offset)
+ | 0x80182000), contents + rel->r_offset);
+ break;
+ }
+
+ if (h != NULL)
+ {
+ off = h->got.offset;
+ h->got.offset |= 1;
+ }
+ else
+ {
+ BFD_ASSERT (local_got_offsets != NULL);
+ off = local_got_offsets[r_symndx];
+ local_got_offsets[r_symndx] |= 1;
+ }
+
+ r_sparc_tlsldm:
+ if (htab->sgot == NULL)
+ abort ();
+
+ if ((off & 1) != 0)
+ off &= ~1;
+ else
+ {
+ Elf_Internal_Rela outrel;
+ Elf32_External_Rela *loc;
+ int dr_type, indx;
+
+ if (htab->srelgot == NULL)
+ abort ();
+
+ bfd_put_32 (output_bfd, 0, htab->sgot->contents + off);
+ outrel.r_offset = (htab->sgot->output_section->vma
+ + htab->sgot->output_offset + off);
+ indx = h && h->dynindx != -1 ? h->dynindx : 0;
+ if (r_type == R_SPARC_TLS_IE_HI22
+ || r_type == R_SPARC_TLS_IE_LO10)
+ dr_type = R_SPARC_TLS_TPOFF32;
+ else
+ dr_type = R_SPARC_TLS_DTPMOD32;
+ if (dr_type == R_SPARC_TLS_TPOFF32 && indx == 0)
+ outrel.r_addend = relocation - dtpoff_base (info);
+ else
+ outrel.r_addend = 0;
+ outrel.r_info = ELF32_R_INFO (indx, dr_type);
+ loc = (Elf32_External_Rela *) htab->srelgot->contents;
+ loc += htab->srelgot->reloc_count++;
+ bfd_elf32_swap_reloca_out (output_bfd, &outrel,
+ (bfd_byte *) loc);
+
+ if (r_type == R_SPARC_TLS_GD_HI22
+ || r_type == R_SPARC_TLS_GD_LO10)
+ {
+ if (indx == 0)
+ {
+ BFD_ASSERT (! unresolved_reloc);
+ bfd_put_32 (output_bfd,
+ relocation - dtpoff_base (info),
+ htab->sgot->contents + off + 4);
+ }
+ else
+ {
+ bfd_put_32 (output_bfd, 0,
+ htab->sgot->contents + off + 4);
+ outrel.r_info = ELF32_R_INFO (indx,
+ R_SPARC_TLS_DTPOFF32);
+ outrel.r_offset += 4;
+ htab->srelgot->reloc_count++;
+ loc++;
+ bfd_elf32_swap_reloca_out (output_bfd, &outrel,
+ (bfd_byte *) loc);
+ }
+ }
+ else if (dr_type == R_SPARC_TLS_DTPMOD32)
+ {
+ bfd_put_32 (output_bfd, 0,
+ htab->sgot->contents + off + 4);
+ }
+ }
+
+ if (off >= (bfd_vma) -2)
+ abort ();
+
+ relocation = htab->sgot->output_offset + off - got_base;
+ unresolved_reloc = FALSE;
+ howto = _bfd_sparc_elf_howto_table + r_type;
+ break;
+
+ case R_SPARC_TLS_LDM_HI22:
+ case R_SPARC_TLS_LDM_LO10:
+ if (! info->shared)
+ {
+ bfd_put_32 (output_bfd, SPARC_NOP, contents + rel->r_offset);
+ continue;
+ }
+ off = htab->tls_ldm_got.offset;
+ htab->tls_ldm_got.offset |= 1;
+ goto r_sparc_tlsldm;
+
+ case R_SPARC_TLS_LDO_HIX22:
+ case R_SPARC_TLS_LDO_LOX10:
+ if (info->shared)
+ relocation -= dtpoff_base (info);
+ else
+ relocation = tpoff (info, relocation);
+ break;
+
+ case R_SPARC_TLS_LE_HIX22:
+ case R_SPARC_TLS_LE_LOX10:
+ if (info->shared)
+ {
+ Elf_Internal_Rela outrel;
+ bfd_boolean skip, relocate = FALSE;
+
+ BFD_ASSERT (sreloc != NULL);
+ skip = FALSE;
+ outrel.r_offset =
+ _bfd_elf_section_offset (output_bfd, info, input_section,
+ rel->r_offset);
+ if (outrel.r_offset == (bfd_vma) -1)
+ skip = TRUE;
+ else if (outrel.r_offset == (bfd_vma) -2)
+ skip = TRUE, relocate = TRUE;
+ outrel.r_offset += (input_section->output_section->vma
+ + input_section->output_offset);
+ if (skip)
+ memset (&outrel, 0, sizeof outrel);
+ else
+ {
+ outrel.r_info = ELF32_R_INFO (0, r_type);
+ outrel.r_addend = relocation - dtpoff_base (info)
+ + rel->r_addend;
+ }
+
+ bfd_elf32_swap_reloca_out (output_bfd, &outrel,
+ (bfd_byte *) (((Elf32_External_Rela *)
+ sreloc->contents)
+ + sreloc->reloc_count));
+ ++sreloc->reloc_count;
+ continue;
+ }
+ relocation = tpoff (info, relocation);
+ break;
+
+ case R_SPARC_TLS_LDM_CALL:
+ if (! info->shared)
+ {
+ /* mov %g0, %o0 */
+ bfd_put_32 (output_bfd, 0x90100000, contents + rel->r_offset);
+ continue;
+ }
+ /* Fall through */
+
+ case R_SPARC_TLS_GD_CALL:
+ tls_type = GOT_UNKNOWN;
+ if (h == NULL && local_got_offsets)
+ tls_type = elf32_sparc_local_got_tls_type (input_bfd) [r_symndx];
+ else if (h != NULL)
+ tls_type = elf32_sparc_hash_entry(h)->tls_type;
+ if (! info->shared
+ || (r_type == R_SPARC_TLS_GD_CALL && tls_type == GOT_TLS_IE))
+ {
+ bfd_vma insn;
+
+ if (!info->shared && (h == NULL || h->dynindx == -1))
+ {
+ /* GD -> LE */
+ bfd_put_32 (output_bfd, SPARC_NOP, contents + rel->r_offset);
+ continue;
+ }
+
+ /* GD -> IE */
+ if (rel + 1 < relend
+ && ELF32_R_TYPE (rel[1].r_info) == R_SPARC_TLS_GD_ADD
+ && rel[1].r_offset == rel->r_offset + 4
+ && ELF32_R_SYM (rel[1].r_info) == r_symndx
+ && (((insn = bfd_get_32 (input_bfd,
+ contents + rel[1].r_offset))
+ >> 25) & 0x1f) == 8)
+ {
+ /* We have
+ call __tls_get_addr, %tgd_call(foo)
+ add %reg1, %reg2, %o0, %tgd_add(foo)
+ and change it into IE:
+ ld [%reg1 + %reg2], %o0, %tie_ld(foo)
+ add %g7, %o0, %o0, %tie_add(foo).
+ add is 0x80000000 | (rd << 25) | (rs1 << 14) | rs2,
+ ld is 0xc0000000 | (rd << 25) | (rs1 << 14) | rs2. */
+ bfd_put_32 (output_bfd, insn | 0xc0000000,
+ contents + rel->r_offset);
+ bfd_put_32 (output_bfd, 0x9001c008,
+ contents + rel->r_offset + 4);
+ rel++;
+ continue;
+ }
+
+ bfd_put_32 (output_bfd, 0x9001c008, contents + rel->r_offset);
+ continue;
+ }
+
+ h = (struct elf_link_hash_entry *)
+ bfd_link_hash_lookup (info->hash, "__tls_get_addr", FALSE,
+ FALSE, TRUE);
+ BFD_ASSERT (h != NULL);
+ r_type = R_SPARC_WPLT30;
+ howto = _bfd_sparc_elf_howto_table + r_type;
+ goto r_sparc_wplt30;
+
+ case R_SPARC_TLS_GD_ADD:
+ tls_type = GOT_UNKNOWN;
+ if (h == NULL && local_got_offsets)
+ tls_type = elf32_sparc_local_got_tls_type (input_bfd) [r_symndx];
+ else if (h != NULL)
+ tls_type = elf32_sparc_hash_entry(h)->tls_type;
+ if (! info->shared || tls_type == GOT_TLS_IE)
+ {
+ /* add %reg1, %reg2, %reg3, %tgd_add(foo)
+ changed into IE:
+ ld [%reg1 + %reg2], %reg3, %tie_ld(foo)
+ or LE:
+ add %g7, %reg2, %reg3. */
+ bfd_vma insn = bfd_get_32 (input_bfd, contents + rel->r_offset);
+ if ((h != NULL && h->dynindx != -1) || info->shared)
+ relocation = insn | 0xc0000000;
+ else
+ relocation = (insn & ~0x7c000) | 0x1c000;
+ bfd_put_32 (output_bfd, relocation, contents + rel->r_offset);
+ }
+ continue;
+
+ case R_SPARC_TLS_LDM_ADD:
+ if (! info->shared)
+ bfd_put_32 (output_bfd, SPARC_NOP, contents + rel->r_offset);
+ continue;
+
+ case R_SPARC_TLS_LDO_ADD:
+ if (! info->shared)
+ {
+ /* Change rs1 into %g7. */
+ bfd_vma insn = bfd_get_32 (input_bfd, contents + rel->r_offset);
+ insn = (insn & ~0x7c000) | 0x1c000;
+ bfd_put_32 (output_bfd, insn, contents + rel->r_offset);
+ }
+ continue;
+
+ case R_SPARC_TLS_IE_LD:
+ case R_SPARC_TLS_IE_LDX:
+ if (! info->shared && (h == NULL || h->dynindx == -1))
+ {
+ bfd_vma insn = bfd_get_32 (input_bfd, contents + rel->r_offset);
+ int rs2 = insn & 0x1f;
+ int rd = (insn >> 25) & 0x1f;
+
+ if (rs2 == rd)
+ relocation = SPARC_NOP;
+ else
+ relocation = 0x80100000 | (insn & 0x3e00001f);
+ bfd_put_32 (output_bfd, relocation, contents + rel->r_offset);
+ }
+ continue;
+
+ case R_SPARC_TLS_IE_ADD:
+ /* Totally useless relocation. */
+ continue;
+
+ case R_SPARC_TLS_DTPOFF32:
+ relocation -= dtpoff_base (info);
+ break;
+
default:
break;
}
@@ -1607,8 +2889,35 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
bfd_putl32 (/*input_bfd,*/ x, contents + rel->r_offset);
r = bfd_reloc_ok;
}
+ else if (r_type == R_SPARC_TLS_LDO_HIX22
+ || r_type == R_SPARC_TLS_LE_HIX22)
+ {
+ bfd_vma x;
+
+ relocation += rel->r_addend;
+ relocation = relocation ^ 0xffffffff;
+
+ x = bfd_get_32 (input_bfd, contents + rel->r_offset);
+ x = (x & ~(bfd_vma) 0x3fffff) | ((relocation >> 10) & 0x3fffff);
+ bfd_put_32 (input_bfd, x, contents + rel->r_offset);
+ r = bfd_reloc_ok;
+ }
+ else if (r_type == R_SPARC_TLS_LDO_LOX10
+ || r_type == R_SPARC_TLS_LE_LOX10)
+ {
+ bfd_vma x;
+
+ relocation += rel->r_addend;
+ relocation = (relocation & 0x3ff) | 0x1c00;
+
+ x = bfd_get_32 (input_bfd, contents + rel->r_offset);
+ x = (x & ~(bfd_vma) 0x1fff) | relocation;
+ bfd_put_32 (input_bfd, x, contents + rel->r_offset);
+
+ r = bfd_reloc_ok;
+ }
else if ((r_type == R_SPARC_WDISP30 || r_type == R_SPARC_WPLT30)
- && SEC_DO_RELAX (input_section)
+ && sec_do_relax (input_section)
&& rel->r_offset + 4 < input_section->_raw_size)
{
#define G0 0
@@ -1721,27 +3030,27 @@ elf32_sparc_relocate_section (output_bfd, info, input_bfd, input_section,
symtab_hdr->sh_link,
sym->st_name);
if (name == NULL)
- return false;
+ return FALSE;
if (*name == '\0')
name = bfd_section_name (input_bfd, sec);
}
if (! ((*info->callbacks->reloc_overflow)
(info, name, howto->name, (bfd_vma) 0,
input_bfd, input_section, rel->r_offset)))
- return false;
+ return FALSE;
}
break;
}
}
}
- return true;
+ return TRUE;
}
/* Finish up dynamic symbol handling. We set the contents of various
dynamic sections here. */
-static boolean
+static bfd_boolean
elf32_sparc_finish_dynamic_symbol (output_bfd, info, h, sym)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -1749,22 +3058,25 @@ elf32_sparc_finish_dynamic_symbol (output_bfd, info, h, sym)
Elf_Internal_Sym *sym;
{
bfd *dynobj;
+ struct elf32_sparc_link_hash_table *htab;
- dynobj = elf_hash_table (info)->dynobj;
+ htab = elf32_sparc_hash_table (info);
+ dynobj = htab->elf.dynobj;
if (h->plt.offset != (bfd_vma) -1)
{
asection *splt;
asection *srela;
Elf_Internal_Rela rela;
+ bfd_byte *loc;
/* This symbol has an entry in the procedure linkage table. Set
- it up. */
+ it up. */
BFD_ASSERT (h->dynindx != -1);
- splt = bfd_get_section_by_name (dynobj, ".plt");
- srela = bfd_get_section_by_name (dynobj, ".rela.plt");
+ splt = htab->splt;
+ srela = htab->srelplt;
BFD_ASSERT (splt != NULL && srela != NULL);
/* Fill in the entry in the procedure linkage table. */
@@ -1784,9 +3096,9 @@ elf32_sparc_finish_dynamic_symbol (output_bfd, info, h, sym)
+ h->plt.offset);
rela.r_info = ELF32_R_INFO (h->dynindx, R_SPARC_JMP_SLOT);
rela.r_addend = 0;
- bfd_elf32_swap_reloca_out (output_bfd, &rela,
- ((Elf32_External_Rela *) srela->contents
- + h->plt.offset / PLT_ENTRY_SIZE - 4));
+ loc = srela->contents;
+ loc += (h->plt.offset / PLT_ENTRY_SIZE - 4) * sizeof (Elf32_External_Rela);
+ bfd_elf32_swap_reloca_out (output_bfd, &rela, loc);
if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
{
@@ -1803,17 +3115,20 @@ elf32_sparc_finish_dynamic_symbol (output_bfd, info, h, sym)
}
}
- if (h->got.offset != (bfd_vma) -1)
+ if (h->got.offset != (bfd_vma) -1
+ && elf32_sparc_hash_entry(h)->tls_type != GOT_TLS_GD
+ && elf32_sparc_hash_entry(h)->tls_type != GOT_TLS_IE)
{
asection *sgot;
asection *srela;
Elf_Internal_Rela rela;
+ bfd_byte *loc;
/* This symbol has an entry in the global offset table. Set it
- up. */
+ up. */
- sgot = bfd_get_section_by_name (dynobj, ".got");
- srela = bfd_get_section_by_name (dynobj, ".rela.got");
+ sgot = htab->sgot;
+ srela = htab->srelgot;
BFD_ASSERT (sgot != NULL && srela != NULL);
rela.r_offset = (sgot->output_section->vma
@@ -1843,16 +3158,16 @@ elf32_sparc_finish_dynamic_symbol (output_bfd, info, h, sym)
bfd_put_32 (output_bfd, (bfd_vma) 0,
sgot->contents + (h->got.offset &~ (bfd_vma) 1));
- bfd_elf32_swap_reloca_out (output_bfd, &rela,
- ((Elf32_External_Rela *) srela->contents
- + srela->reloc_count));
- ++srela->reloc_count;
+ loc = srela->contents;
+ loc += srela->reloc_count++ * sizeof (Elf32_External_Rela);
+ bfd_elf32_swap_reloca_out (output_bfd, &rela, loc);
}
if ((h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_COPY) != 0)
{
asection *s;
Elf_Internal_Rela rela;
+ bfd_byte *loc;
/* This symbols needs a copy reloc. Set it up. */
@@ -1867,10 +3182,8 @@ elf32_sparc_finish_dynamic_symbol (output_bfd, info, h, sym)
+ h->root.u.def.section->output_offset);
rela.r_info = ELF32_R_INFO (h->dynindx, R_SPARC_COPY);
rela.r_addend = 0;
- bfd_elf32_swap_reloca_out (output_bfd, &rela,
- ((Elf32_External_Rela *) s->contents
- + s->reloc_count));
- ++s->reloc_count;
+ loc = s->contents + s->reloc_count++ * sizeof (Elf32_External_Rela);
+ bfd_elf32_swap_reloca_out (output_bfd, &rela, loc);
}
/* Mark some specially defined symbols as absolute. */
@@ -1879,21 +3192,22 @@ elf32_sparc_finish_dynamic_symbol (output_bfd, info, h, sym)
|| strcmp (h->root.root.string, "_PROCEDURE_LINKAGE_TABLE_") == 0)
sym->st_shndx = SHN_ABS;
- return true;
+ return TRUE;
}
/* Finish up the dynamic sections. */
-static boolean
+static bfd_boolean
elf32_sparc_finish_dynamic_sections (output_bfd, info)
bfd *output_bfd;
struct bfd_link_info *info;
{
bfd *dynobj;
asection *sdyn;
- asection *sgot;
+ struct elf32_sparc_link_hash_table *htab;
- dynobj = elf_hash_table (info)->dynobj;
+ htab = elf32_sparc_hash_table (info);
+ dynobj = htab->elf.dynobj;
sdyn = bfd_get_section_by_name (dynobj, ".dynamic");
@@ -1911,16 +3225,16 @@ elf32_sparc_finish_dynamic_sections (output_bfd, info)
{
Elf_Internal_Dyn dyn;
const char *name;
- boolean size;
+ bfd_boolean size;
bfd_elf32_swap_dyn_in (dynobj, dyncon, &dyn);
switch (dyn.d_tag)
{
- case DT_PLTGOT: name = ".plt"; size = false; break;
- case DT_PLTRELSZ: name = ".rela.plt"; size = true; break;
- case DT_JMPREL: name = ".rela.plt"; size = false; break;
- default: name = NULL; size = false; break;
+ case DT_PLTGOT: name = ".plt"; size = FALSE; break;
+ case DT_PLTRELSZ: name = ".rela.plt"; size = TRUE; break;
+ case DT_JMPREL: name = ".rela.plt"; size = FALSE; break;
+ default: name = NULL; size = FALSE; break;
}
if (name != NULL)
@@ -1955,27 +3269,25 @@ elf32_sparc_finish_dynamic_sections (output_bfd, info)
splt->contents + splt->_raw_size - 4);
}
- elf_section_data (splt->output_section)->this_hdr.sh_entsize =
- PLT_ENTRY_SIZE;
+ elf_section_data (splt->output_section)->this_hdr.sh_entsize = 0;
}
/* Set the first entry in the global offset table to the address of
the dynamic section. */
- sgot = bfd_get_section_by_name (dynobj, ".got");
- BFD_ASSERT (sgot != NULL);
- if (sgot->_raw_size > 0)
+ if (htab->sgot && htab->sgot->_raw_size > 0)
{
if (sdyn == NULL)
- bfd_put_32 (output_bfd, (bfd_vma) 0, sgot->contents);
+ bfd_put_32 (output_bfd, (bfd_vma) 0, htab->sgot->contents);
else
bfd_put_32 (output_bfd,
sdyn->output_section->vma + sdyn->output_offset,
- sgot->contents);
+ htab->sgot->contents);
}
- elf_section_data (sgot->output_section)->this_hdr.sh_entsize = 4;
+ if (htab->sgot)
+ elf_section_data (htab->sgot->output_section)->this_hdr.sh_entsize = 4;
- return true;
+ return TRUE;
}
/* Functions for dealing with the e_flags field.
@@ -1988,24 +3300,24 @@ elf32_sparc_finish_dynamic_sections (output_bfd, info)
/* Merge backend specific data from an object file to the output
object file when linking. */
-static boolean
+static bfd_boolean
elf32_sparc_merge_private_bfd_data (ibfd, obfd)
bfd *ibfd;
bfd *obfd;
{
- boolean error;
+ bfd_boolean error;
/* FIXME: This should not be static. */
static unsigned long previous_ibfd_e_flags = (unsigned long) -1;
if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour
|| bfd_get_flavour (obfd) != bfd_target_elf_flavour)
- return true;
+ return TRUE;
- error = false;
+ error = FALSE;
if (bfd_get_mach (ibfd) >= bfd_mach_sparc_v9)
{
- error = true;
+ error = TRUE;
(*_bfd_error_handler)
(_("%s: compiled for a 64 bit system and target is 32 bit"),
bfd_archive_filename (ibfd));
@@ -2023,22 +3335,22 @@ elf32_sparc_merge_private_bfd_data (ibfd, obfd)
(*_bfd_error_handler)
(_("%s: linking little endian files with big endian files"),
bfd_archive_filename (ibfd));
- error = true;
+ error = TRUE;
}
previous_ibfd_e_flags = elf_elfheader (ibfd)->e_flags & EF_SPARC_LEDATA;
if (error)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Set the right machine number. */
-static boolean
+static bfd_boolean
elf32_sparc_object_p (abfd)
bfd *abfd;
{
@@ -2054,7 +3366,7 @@ elf32_sparc_object_p (abfd)
return bfd_default_set_arch_mach (abfd, bfd_arch_sparc,
bfd_mach_sparc_v8plus);
else
- return false;
+ return FALSE;
}
else if (elf_elfheader (abfd)->e_flags & EF_SPARC_LEDATA)
return bfd_default_set_arch_mach (abfd, bfd_arch_sparc,
@@ -2069,7 +3381,7 @@ elf32_sparc_object_p (abfd)
static void
elf32_sparc_final_write_processing (abfd, linker)
bfd *abfd;
- boolean linker ATTRIBUTE_UNUSED;
+ bfd_boolean linker ATTRIBUTE_UNUSED;
{
switch (bfd_get_mach (abfd))
{
@@ -2126,10 +3438,15 @@ elf32_sparc_reloc_type_class (rela)
#define ELF_MAXPAGESIZE 0x10000
#define bfd_elf32_bfd_reloc_type_lookup elf32_sparc_reloc_type_lookup
+#define bfd_elf32_bfd_link_hash_table_create \
+ elf32_sparc_link_hash_table_create
#define bfd_elf32_bfd_relax_section elf32_sparc_relax_section
+#define bfd_elf32_new_section_hook elf32_sparc_new_section_hook
#define elf_info_to_howto elf32_sparc_info_to_howto
+#define elf_backend_copy_indirect_symbol \
+ elf32_sparc_copy_indirect_symbol
#define elf_backend_create_dynamic_sections \
- _bfd_elf_create_dynamic_sections
+ elf32_sparc_create_dynamic_sections
#define elf_backend_check_relocs elf32_sparc_check_relocs
#define elf_backend_adjust_dynamic_symbol \
elf32_sparc_adjust_dynamic_symbol
@@ -2142,18 +3459,21 @@ elf32_sparc_reloc_type_class (rela)
elf32_sparc_finish_dynamic_sections
#define bfd_elf32_bfd_merge_private_bfd_data \
elf32_sparc_merge_private_bfd_data
+#define bfd_elf32_mkobject elf32_sparc_mkobject
#define elf_backend_object_p elf32_sparc_object_p
#define elf_backend_final_write_processing \
elf32_sparc_final_write_processing
-#define elf_backend_gc_mark_hook elf32_sparc_gc_mark_hook
+#define elf_backend_gc_mark_hook elf32_sparc_gc_mark_hook
#define elf_backend_gc_sweep_hook elf32_sparc_gc_sweep_hook
+#define elf_backend_grok_psinfo elf32_sparc_grok_psinfo
#define elf_backend_reloc_type_class elf32_sparc_reloc_type_class
#define elf_backend_can_gc_sections 1
+#define elf_backend_can_refcount 1
#define elf_backend_want_got_plt 0
#define elf_backend_plt_readonly 0
#define elf_backend_want_plt_sym 1
#define elf_backend_got_header_size 4
-#define elf_backend_plt_header_size (4*PLT_ENTRY_SIZE)
+#define elf_backend_rela_normal 1
#include "elf32-target.h"
diff --git a/contrib/binutils/bfd/elf64-gen.c b/contrib/binutils/bfd/elf64-gen.c
index a58f6ac..be1dc3e 100644
--- a/contrib/binutils/bfd/elf64-gen.c
+++ b/contrib/binutils/bfd/elf64-gen.c
@@ -1,5 +1,6 @@
/* Generic support for 64-bit ELF
- Copyright 1993, 1995, 1998, 1999, 2001 Free Software Foundation, Inc.
+ Copyright 1993, 1995, 1998, 1999, 2001, 2002, 2004
+ Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -30,28 +31,28 @@ static reloc_howto_type dummy =
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
NULL, /* special_function */
"UNKNOWN", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false); /* pcrel_offset */
+ FALSE); /* pcrel_offset */
static void elf_generic_info_to_howto
- PARAMS ((bfd *, arelent *, Elf64_Internal_Rela *));
+ PARAMS ((bfd *, arelent *, Elf_Internal_Rela *));
static void elf_generic_info_to_howto_rel
- PARAMS ((bfd *, arelent *, Elf64_Internal_Rel *));
-static boolean elf64_generic_link_add_symbols
+ PARAMS ((bfd *, arelent *, Elf_Internal_Rela *));
+static bfd_boolean elf64_generic_link_add_symbols
PARAMS ((bfd *, struct bfd_link_info *));
static void
elf_generic_info_to_howto (abfd, bfd_reloc, elf_reloc)
bfd *abfd ATTRIBUTE_UNUSED;
arelent *bfd_reloc;
- Elf64_Internal_Rela *elf_reloc ATTRIBUTE_UNUSED;
+ Elf_Internal_Rela *elf_reloc ATTRIBUTE_UNUSED;
{
bfd_reloc->howto = &dummy;
}
@@ -60,12 +61,12 @@ static void
elf_generic_info_to_howto_rel (abfd, bfd_reloc, elf_reloc)
bfd *abfd ATTRIBUTE_UNUSED;
arelent *bfd_reloc;
- Elf64_Internal_Rel *elf_reloc ATTRIBUTE_UNUSED;
+ Elf_Internal_Rela *elf_reloc ATTRIBUTE_UNUSED;
{
bfd_reloc->howto = &dummy;
}
-static boolean
+static bfd_boolean
elf64_generic_link_add_symbols (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -84,10 +85,10 @@ elf64_generic_link_add_symbols (abfd, info)
ehdrp->e_machine);
bfd_set_error (bfd_error_wrong_format);
- return false;
+ return FALSE;
}
- return bfd_elf64_bfd_link_add_symbols (abfd, info);
+ return bfd_elf_link_add_symbols (abfd, info);
}
#define TARGET_LITTLE_SYM bfd_elf64_little_generic_vec
diff --git a/contrib/binutils/bfd/elf64-ppc.c b/contrib/binutils/bfd/elf64-ppc.c
index c512636..a0d81d0 100644
--- a/contrib/binutils/bfd/elf64-ppc.c
+++ b/contrib/binutils/bfd/elf64-ppc.c
@@ -1,66 +1,102 @@
/* PowerPC64-specific support for 64-bit ELF.
- Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 1999, 2000, 2001, 2002, 2003, 2004
+ Free Software Foundation, Inc.
Written by Linus Nordberg, Swox AB <info@swox.com>,
based on elf32-ppc.c by Ian Lance Taylor.
+ Largely rewritten by Alan Modra <amodra@bigpond.net.au>
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License along
+ with this program; if not, write to the Free Software Foundation, Inc.,
+ 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-/* This file is based on the 64-bit PowerPC ELF ABI. It is also based
- on the file elf32-ppc.c. */
+/* The 64-bit PowerPC ELF ABI may be found at
+ http://www.linuxbase.org/spec/ELF/ppc64/PPC-elf64abi.txt, and
+ http://www.linuxbase.org/spec/ELF/ppc64/spec/book1.html */
#include "bfd.h"
#include "sysdep.h"
#include "bfdlink.h"
#include "libbfd.h"
#include "elf-bfd.h"
-#include "elf/ppc.h"
+#include "elf/ppc64.h"
#include "elf64-ppc.h"
-#define USE_RELA /* we want RELA relocations, not REL. */
-
-
-static void ppc_howto_init
- PARAMS ((void));
-static reloc_howto_type *ppc64_elf_reloc_type_lookup
- PARAMS ((bfd *abfd, bfd_reloc_code_real_type code));
-static void ppc64_elf_info_to_howto
- PARAMS ((bfd *abfd, arelent *cache_ptr, Elf64_Internal_Rela *dst));
static bfd_reloc_status_type ppc64_elf_ha_reloc
- PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
+ (bfd *, arelent *, asymbol *, void *, asection *, bfd *, char **);
static bfd_reloc_status_type ppc64_elf_brtaken_reloc
- PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
+ (bfd *, arelent *, asymbol *, void *, asection *, bfd *, char **);
static bfd_reloc_status_type ppc64_elf_sectoff_reloc
- PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
+ (bfd *, arelent *, asymbol *, void *, asection *, bfd *, char **);
static bfd_reloc_status_type ppc64_elf_sectoff_ha_reloc
- PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
+ (bfd *, arelent *, asymbol *, void *, asection *, bfd *, char **);
static bfd_reloc_status_type ppc64_elf_toc_reloc
- PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
+ (bfd *, arelent *, asymbol *, void *, asection *, bfd *, char **);
static bfd_reloc_status_type ppc64_elf_toc_ha_reloc
- PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
+ (bfd *, arelent *, asymbol *, void *, asection *, bfd *, char **);
static bfd_reloc_status_type ppc64_elf_toc64_reloc
- PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
+ (bfd *, arelent *, asymbol *, void *, asection *, bfd *, char **);
static bfd_reloc_status_type ppc64_elf_unhandled_reloc
- PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
-static boolean ppc64_elf_object_p
- PARAMS ((bfd *));
-static boolean ppc64_elf_merge_private_bfd_data
- PARAMS ((bfd *, bfd *));
+ (bfd *, arelent *, asymbol *, void *, asection *, bfd *, char **);
+#define TARGET_LITTLE_SYM bfd_elf64_powerpcle_vec
+#define TARGET_LITTLE_NAME "elf64-powerpcle"
+#define TARGET_BIG_SYM bfd_elf64_powerpc_vec
+#define TARGET_BIG_NAME "elf64-powerpc"
+#define ELF_ARCH bfd_arch_powerpc
+#define ELF_MACHINE_CODE EM_PPC64
+#define ELF_MAXPAGESIZE 0x10000
+#define elf_info_to_howto ppc64_elf_info_to_howto
+
+#define elf_backend_want_got_sym 0
+#define elf_backend_want_plt_sym 0
+#define elf_backend_plt_alignment 3
+#define elf_backend_plt_not_loaded 1
+#define elf_backend_got_symbol_offset 0
+#define elf_backend_got_header_size 8
+#define elf_backend_can_gc_sections 1
+#define elf_backend_can_refcount 1
+#define elf_backend_rela_normal 1
+
+#define bfd_elf64_mkobject ppc64_elf_mkobject
+#define bfd_elf64_bfd_reloc_type_lookup ppc64_elf_reloc_type_lookup
+#define bfd_elf64_bfd_merge_private_bfd_data ppc64_elf_merge_private_bfd_data
+#define bfd_elf64_new_section_hook ppc64_elf_new_section_hook
+#define bfd_elf64_bfd_link_hash_table_create ppc64_elf_link_hash_table_create
+#define bfd_elf64_bfd_link_hash_table_free ppc64_elf_link_hash_table_free
+
+#define elf_backend_object_p ppc64_elf_object_p
+#define elf_backend_grok_prstatus ppc64_elf_grok_prstatus
+#define elf_backend_grok_psinfo ppc64_elf_grok_psinfo
+#define elf_backend_create_dynamic_sections ppc64_elf_create_dynamic_sections
+#define elf_backend_copy_indirect_symbol ppc64_elf_copy_indirect_symbol
+#define elf_backend_add_symbol_hook ppc64_elf_add_symbol_hook
+#define elf_backend_check_relocs ppc64_elf_check_relocs
+#define elf_backend_gc_mark_hook ppc64_elf_gc_mark_hook
+#define elf_backend_gc_sweep_hook ppc64_elf_gc_sweep_hook
+#define elf_backend_adjust_dynamic_symbol ppc64_elf_adjust_dynamic_symbol
+#define elf_backend_hide_symbol ppc64_elf_hide_symbol
+#define elf_backend_always_size_sections ppc64_elf_func_desc_adjust
+#define elf_backend_size_dynamic_sections ppc64_elf_size_dynamic_sections
+#define elf_backend_relocate_section ppc64_elf_relocate_section
+#define elf_backend_finish_dynamic_symbol ppc64_elf_finish_dynamic_symbol
+#define elf_backend_reloc_type_class ppc64_elf_reloc_type_class
+#define elf_backend_finish_dynamic_sections ppc64_elf_finish_dynamic_sections
+#define elf_backend_link_output_symbol_hook ppc64_elf_output_symbol_hook
+#define elf_backend_special_sections ppc64_elf_special_sections
+
/* The name of the dynamic interpreter. This is put in the .interp
section. */
#define ELF_DYNAMIC_INTERPRETER "/usr/lib/ld.so.1"
@@ -72,9 +108,16 @@ static boolean ppc64_elf_merge_private_bfd_data
#define PLT_INITIAL_ENTRY_SIZE PLT_ENTRY_SIZE
/* TOC base pointers offset from start of TOC. */
-#define TOC_BASE_OFF (0x8000)
+#define TOC_BASE_OFF 0x8000
+
+/* Offset of tp and dtp pointers from start of TLS block. */
+#define TP_OFFSET 0x7000
+#define DTP_OFFSET 0x8000
-/* .plt call stub instructions. */
+/* .plt call stub instructions. The normal stub is like this, but
+ sometimes the .plt entry crosses a 64k boundary and we need to
+ insert an addis to adjust r12. */
+#define PLT_CALL_STUB_SIZE (7*4)
#define ADDIS_R12_R2 0x3d820000 /* addis %r12,%r2,xxx@ha */
#define STD_R2_40R1 0xf8410028 /* std %r2,40(%r1) */
#define LD_R11_0R12 0xe96c0000 /* ld %r11,xxx+0@l(%r12) */
@@ -83,19 +126,31 @@ static boolean ppc64_elf_merge_private_bfd_data
/* ld %r11,xxx+16@l(%r12) */
#define BCTR 0x4e800420 /* bctr */
-/* The normal stub is this size. */
-#define PLT_CALL_STUB_SIZE (7*4)
-
-/* But sometimes the .plt entry crosses a 64k boundary, and we need
- to adjust the high word with this insn. */
-#define ADDIS_R12_R12_1 0x3d8c0001 /* addis %r12,%r12,1 */
-
-/* The .glink fixup call stub is the same as the .plt call stub, but
- the first instruction restores r2, and the std is omitted. */
-#define LD_R2_40R1 0xe8410028 /* ld %r2,40(%r1) */
-/* Always allow this much space. */
-#define GLINK_CALL_STUB_SIZE (8*4)
+#define ADDIS_R2_R2 0x3c420000 /* addis %r2,%r2,off@ha */
+#define ADDI_R2_R2 0x38420000 /* addi %r2,%r2,off@l */
+
+#define LD_R2_40R1 0xe8410028 /* ld %r2,40(%r1) */
+
+/* glink call stub instructions. We enter with the index in R0, and the
+ address of glink entry in CTR. From that, we can calculate PLT0. */
+#define GLINK_CALL_STUB_SIZE (16*4)
+#define MFCTR_R12 0x7d8902a6 /* mfctr %r12 */
+#define SLDI_R11_R0_3 0x780b1f24 /* sldi %r11,%r0,3 */
+#define ADDIC_R2_R0_32K 0x34408000 /* addic. %r2,%r0,-32768 */
+#define SUB_R12_R12_R11 0x7d8b6050 /* sub %r12,%r12,%r11 */
+#define SRADI_R2_R2_63 0x7c42fe76 /* sradi %r2,%r2,63 */
+#define SLDI_R11_R0_2 0x780b1764 /* sldi %r11,%r0,2 */
+#define AND_R2_R2_R11 0x7c425838 /* and %r2,%r2,%r11 */
+ /* sub %r12,%r12,%r11 */
+#define ADD_R12_R12_R2 0x7d8c1214 /* add %r12,%r12,%r2 */
+#define ADDIS_R12_R12 0x3d8c0000 /* addis %r12,%r12,xxx@ha */
+ /* ld %r11,xxx@l(%r12) */
+#define ADDI_R12_R12 0x398c0000 /* addi %r12,%r12,xxx@l */
+ /* ld %r2,8(%r12) */
+ /* mtctr %r11 */
+ /* ld %r11,16(%r12) */
+ /* bctr */
/* Pad with this. */
#define NOP 0x60000000
@@ -127,40 +182,40 @@ static boolean ppc64_elf_merge_private_bfd_data
#endif
#define ONES(n) (((bfd_vma) 1 << ((n) - 1) << 1) - 1)
-
+
/* Relocation HOWTO's. */
-static reloc_howto_type *ppc64_elf_howto_table[(int) R_PPC_max];
+static reloc_howto_type *ppc64_elf_howto_table[(int) R_PPC64_max];
static reloc_howto_type ppc64_elf_howto_raw[] = {
/* This reloc does nothing. */
HOWTO (R_PPC64_NONE, /* type */
0, /* rightshift */
- 0, /* size (0 = byte, 1 = short, 2 = long) */
- 8, /* bitsize */
- false, /* pc_relative */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_NONE", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* A standard 32 bit relocation. */
HOWTO (R_PPC64_ADDR32, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_ADDR32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* An absolute 26 bit branch; the lower two bits must be zero.
FIXME: we don't check that, we just clear them. */
@@ -168,60 +223,60 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
26, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_ADDR24", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0x03fffffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* A standard 16 bit relocation. */
HOWTO (R_PPC64_ADDR16, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_ADDR16", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* A 16 bit relocation without overflow. */
HOWTO (R_PPC64_ADDR16_LO, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_ADDR16_LO", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Bits 16-31 of an address. */
HOWTO (R_PPC64_ADDR16_HI, /* type */
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_ADDR16_HI", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Bits 16-31 of an address, plus 1 if the contents of the low 16
bits, treated as a signed number, is negative. */
@@ -229,15 +284,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_ha_reloc, /* special_function */
"R_PPC64_ADDR16_HA", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* An absolute 16 bit branch; the lower two bits must be zero.
FIXME: we don't check that, we just clear them. */
@@ -245,15 +300,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_ADDR14", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0x0000fffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* An absolute 16 bit branch, for which bit 10 should be set to
indicate that the branch is expected to be taken. The lower two
@@ -262,15 +317,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
ppc64_elf_brtaken_reloc, /* special_function */
"R_PPC64_ADDR14_BRTAKEN",/* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0x0000fffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* An absolute 16 bit branch, for which bit 10 should be set to
indicate that the branch is not expected to be taken. The lower
@@ -279,45 +334,45 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
ppc64_elf_brtaken_reloc, /* special_function */
"R_PPC64_ADDR14_BRNTAKEN",/* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0x0000fffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* A relative 26 bit branch; the lower two bits must be zero. */
HOWTO (R_PPC64_REL24, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
26, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_REL24", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0x03fffffc, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* A relative 16 bit branch; the lower two bits must be zero. */
HOWTO (R_PPC64_REL14, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_REL14", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0x0000fffc, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* A relative 16 bit branch. Bit 10 should be set to indicate that
the branch is expected to be taken. The lower two bits must be
@@ -326,15 +381,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
ppc64_elf_brtaken_reloc, /* special_function */
"R_PPC64_REL14_BRTAKEN", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0x0000fffc, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* A relative 16 bit branch. Bit 10 should be set to indicate that
the branch is not expected to be taken. The lower two bits must
@@ -343,15 +398,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
ppc64_elf_brtaken_reloc, /* special_function */
"R_PPC64_REL14_BRNTAKEN",/* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0x0000fffc, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* Like R_PPC64_ADDR16, but referring to the GOT table entry for the
symbol. */
@@ -359,15 +414,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_GOT16", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_ADDR16_LO, but referring to the GOT table entry for
the symbol. */
@@ -375,15 +430,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_GOT16_LO", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_ADDR16_HI, but referring to the GOT table entry for
the symbol. */
@@ -391,15 +446,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont,/* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_GOT16_HI", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_ADDR16_HA, but referring to the GOT table entry for
the symbol. */
@@ -407,15 +462,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont,/* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_GOT16_HA", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* This is used only by the dynamic linker. The symbol should exist
both in the object being run and in some shared library. The
@@ -426,15 +481,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
0, /* this one is variable size */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_COPY", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_ADDR64, but used when setting global offset table
entries. */
@@ -442,15 +497,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
4, /* size (0=byte, 1=short, 2=long, 4=64 bits) */
64, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_GLOB_DAT", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
ONES (64), /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Created by the link editor. Marks a procedure linkage table
entry for a symbol. */
@@ -458,15 +513,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_JMP_SLOT", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Used only by the dynamic linker. When the object is run, this
doubleword64 is set to the load address of the object, plus the
@@ -475,76 +530,76 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
4, /* size (0=byte, 1=short, 2=long, 4=64 bits) */
64, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_RELATIVE", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
ONES (64), /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_ADDR32, but may be unaligned. */
HOWTO (R_PPC64_UADDR32, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_UADDR32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_ADDR16, but may be unaligned. */
HOWTO (R_PPC64_UADDR16, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_UADDR16", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 32-bit PC relative. */
HOWTO (R_PPC64_REL32, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
/* FIXME: Verify. Was complain_overflow_bitfield. */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_REL32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffffffff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* 32-bit relocation to the symbol's procedure linkage table. */
HOWTO (R_PPC64_PLT32, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_PLT32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 32-bit PC relative relocation to the symbol's procedure linkage table.
FIXME: R_PPC64_PLTREL32 not supported. */
@@ -552,15 +607,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_PLTREL32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffffffff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* Like R_PPC64_ADDR16_LO, but referring to the PLT table entry for
the symbol. */
@@ -568,15 +623,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_PLT16_LO", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_ADDR16_HI, but referring to the PLT table entry for
the symbol. */
@@ -584,15 +639,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_PLT16_HI", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_ADDR16_HA, but referring to the PLT table entry for
the symbol. */
@@ -600,91 +655,90 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_PLT16_HA", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 16-bit section relative relocation. */
HOWTO (R_PPC64_SECTOFF, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
ppc64_elf_sectoff_reloc, /* special_function */
"R_PPC64_SECTOFF", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_SECTOFF, but no overflow warning. */
HOWTO (R_PPC64_SECTOFF_LO, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_sectoff_reloc, /* special_function */
"R_PPC64_SECTOFF_LO", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 16-bit upper half section relative relocation. */
HOWTO (R_PPC64_SECTOFF_HI, /* type */
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_sectoff_reloc, /* special_function */
"R_PPC64_SECTOFF_HI", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 16-bit upper half adjusted section relative relocation. */
HOWTO (R_PPC64_SECTOFF_HA, /* type */
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_sectoff_ha_reloc, /* special_function */
"R_PPC64_SECTOFF_HA", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
- /* Like R_PPC64_REL24 without touching the two least significant
- bits. Should have been named R_PPC64_REL30! */
- HOWTO (R_PPC64_ADDR30, /* type */
+ /* Like R_PPC64_REL24 without touching the two least significant bits. */
+ HOWTO (R_PPC64_REL30, /* type */
2, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
30, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
- "R_PPC64_ADDR30", /* name */
- false, /* partial_inplace */
+ "R_PPC64_REL30", /* name */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffffffc, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* Relocs in the 64-bit PowerPC ELF ABI, not in the 32-bit ABI. */
@@ -693,30 +747,30 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
4, /* size (0=byte, 1=short, 2=long, 4=64 bits) */
64, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_ADDR64", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
ONES (64), /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* The bits 32-47 of an address. */
HOWTO (R_PPC64_ADDR16_HIGHER, /* type */
32, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_ADDR16_HIGHER", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* The bits 32-47 of an address, plus 1 if the contents of the low
16 bits, treated as a signed number, is negative. */
@@ -724,30 +778,30 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
32, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_ha_reloc, /* special_function */
"R_PPC64_ADDR16_HIGHERA", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* The bits 48-63 of an address. */
HOWTO (R_PPC64_ADDR16_HIGHEST,/* type */
48, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_ADDR16_HIGHEST", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* The bits 48-63 of an address, plus 1 if the contents of the low
16 bits, treated as a signed number, is negative. */
@@ -755,60 +809,60 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
48, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_ha_reloc, /* special_function */
"R_PPC64_ADDR16_HIGHESTA", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like ADDR64, but may be unaligned. */
HOWTO (R_PPC64_UADDR64, /* type */
0, /* rightshift */
4, /* size (0=byte, 1=short, 2=long, 4=64 bits) */
64, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_UADDR64", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
ONES (64), /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 64-bit relative relocation. */
HOWTO (R_PPC64_REL64, /* type */
0, /* rightshift */
4, /* size (0=byte, 1=short, 2=long, 4=64 bits) */
64, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_REL64", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
ONES (64), /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* 64-bit relocation to the symbol's procedure linkage table. */
HOWTO (R_PPC64_PLT64, /* type */
0, /* rightshift */
4, /* size (0=byte, 1=short, 2=long, 4=64 bits) */
64, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_PLT64", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
ONES (64), /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 64-bit PC relative relocation to the symbol's procedure linkage
table. */
@@ -817,15 +871,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
4, /* size (0=byte, 1=short, 2=long, 4=64 bits) */
64, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_PLTREL64", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
ONES (64), /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* 16 bit TOC-relative relocation. */
@@ -834,15 +888,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
ppc64_elf_toc_reloc, /* special_function */
"R_PPC64_TOC16", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 16 bit TOC-relative relocation without overflow. */
@@ -851,15 +905,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_toc_reloc, /* special_function */
"R_PPC64_TOC16_LO", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 16 bit TOC-relative relocation, high 16 bits. */
@@ -868,15 +922,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_toc_reloc, /* special_function */
"R_PPC64_TOC16_HI", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 16 bit TOC-relative relocation, high 16 bits, plus 1 if the
contents of the low 16 bits, treated as a signed number, is
@@ -887,15 +941,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_toc_ha_reloc, /* special_function */
"R_PPC64_TOC16_HA", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 64-bit relocation; insert value of TOC base (.TOC.). */
@@ -904,15 +958,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
4, /* size (0=byte, 1=short, 2=long, 4=64 bits) */
64, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
ppc64_elf_toc64_reloc, /* special_function */
"R_PPC64_TOC", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
ONES (64), /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_GOT16, but also informs the link editor that the
value to relocate may (!) refer to a PLT entry which the link
@@ -927,15 +981,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_PLTGOT16", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_PLTGOT16, but without overflow. */
/* FIXME: R_PPC64_PLTGOT16_LO not implemented. */
@@ -943,15 +997,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_PLTGOT16_LO", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_PLT_GOT16, but using bits 16-31 of the address. */
/* FIXME: R_PPC64_PLTGOT16_HI not implemented. */
@@ -959,15 +1013,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_PLTGOT16_HI", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_PLT_GOT16, but using bits 16-31 of the address, plus
1 if the contents of the low 16 bits, treated as a signed number,
@@ -977,150 +1031,150 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
16, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont,/* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_PLTGOT16_HA", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_ADDR16, but for instructions with a DS field. */
HOWTO (R_PPC64_ADDR16_DS, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_ADDR16_DS", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_ADDR16_LO, but for instructions with a DS field. */
HOWTO (R_PPC64_ADDR16_LO_DS, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_PPC64_ADDR16_LO_DS",/* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_GOT16, but for instructions with a DS field. */
HOWTO (R_PPC64_GOT16_DS, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_GOT16_DS", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_GOT16_LO, but for instructions with a DS field. */
HOWTO (R_PPC64_GOT16_LO_DS, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_GOT16_LO_DS", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_PLT16_LO, but for instructions with a DS field. */
HOWTO (R_PPC64_PLT16_LO_DS, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_PLT16_LO_DS", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_SECTOFF, but for instructions with a DS field. */
HOWTO (R_PPC64_SECTOFF_DS, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
ppc64_elf_sectoff_reloc, /* special_function */
"R_PPC64_SECTOFF_DS", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_SECTOFF_LO, but for instructions with a DS field. */
HOWTO (R_PPC64_SECTOFF_LO_DS, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_sectoff_reloc, /* special_function */
"R_PPC64_SECTOFF_LO_DS",/* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_TOC16, but for instructions with a DS field. */
HOWTO (R_PPC64_TOC16_DS, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
ppc64_elf_toc_reloc, /* special_function */
"R_PPC64_TOC16_DS", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_TOC16_LO, but for instructions with a DS field. */
HOWTO (R_PPC64_TOC16_LO_DS, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_toc_reloc, /* special_function */
"R_PPC64_TOC16_LO_DS", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_PLTGOT16, but for instructions with a DS field. */
/* FIXME: R_PPC64_PLTGOT16_DS not implemented. */
@@ -1128,15 +1182,15 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_PLTGOT16_DS", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Like R_PPC64_PLTGOT16_LO, but for instructions with a DS field. */
/* FIXME: R_PPC64_PLTGOT16_LO not implemented. */
@@ -1144,45 +1198,655 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
ppc64_elf_unhandled_reloc, /* special_function */
"R_PPC64_PLTGOT16_LO_DS",/* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfffc, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Marker reloc for TLS. */
+ HOWTO (R_PPC64_TLS,
+ 0, /* rightshift */
+ 2, /* size (0 = byte, 1 = short, 2 = long) */
+ 32, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ bfd_elf_generic_reloc, /* special_function */
+ "R_PPC64_TLS", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Computes the load module index of the load module that contains the
+ definition of its TLS sym. */
+ HOWTO (R_PPC64_DTPMOD64,
+ 0, /* rightshift */
+ 4, /* size (0 = byte, 1 = short, 2 = long) */
+ 64, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_DTPMOD64", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ ONES (64), /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Computes a dtv-relative displacement, the difference between the value
+ of sym+add and the base address of the thread-local storage block that
+ contains the definition of sym, minus 0x8000. */
+ HOWTO (R_PPC64_DTPREL64,
+ 0, /* rightshift */
+ 4, /* size (0 = byte, 1 = short, 2 = long) */
+ 64, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_DTPREL64", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ ONES (64), /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* A 16 bit dtprel reloc. */
+ HOWTO (R_PPC64_DTPREL16,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_DTPREL16", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like DTPREL16, but no overflow. */
+ HOWTO (R_PPC64_DTPREL16_LO,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_DTPREL16_LO", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like DTPREL16_LO, but next higher group of 16 bits. */
+ HOWTO (R_PPC64_DTPREL16_HI,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_DTPREL16_HI", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like DTPREL16_HI, but adjust for low 16 bits. */
+ HOWTO (R_PPC64_DTPREL16_HA,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_DTPREL16_HA", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like DTPREL16_HI, but next higher group of 16 bits. */
+ HOWTO (R_PPC64_DTPREL16_HIGHER,
+ 32, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_DTPREL16_HIGHER", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like DTPREL16_HIGHER, but adjust for low 16 bits. */
+ HOWTO (R_PPC64_DTPREL16_HIGHERA,
+ 32, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_DTPREL16_HIGHERA", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like DTPREL16_HIGHER, but next higher group of 16 bits. */
+ HOWTO (R_PPC64_DTPREL16_HIGHEST,
+ 48, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_DTPREL16_HIGHEST", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like DTPREL16_HIGHEST, but adjust for low 16 bits. */
+ HOWTO (R_PPC64_DTPREL16_HIGHESTA,
+ 48, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_DTPREL16_HIGHESTA", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like DTPREL16, but for insns with a DS field. */
+ HOWTO (R_PPC64_DTPREL16_DS,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_DTPREL16_DS", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfffc, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like DTPREL16_DS, but no overflow. */
+ HOWTO (R_PPC64_DTPREL16_LO_DS,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_DTPREL16_LO_DS", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfffc, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Computes a tp-relative displacement, the difference between the value of
+ sym+add and the value of the thread pointer (r13). */
+ HOWTO (R_PPC64_TPREL64,
+ 0, /* rightshift */
+ 4, /* size (0 = byte, 1 = short, 2 = long) */
+ 64, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_TPREL64", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ ONES (64), /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* A 16 bit tprel reloc. */
+ HOWTO (R_PPC64_TPREL16,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_TPREL16", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like TPREL16, but no overflow. */
+ HOWTO (R_PPC64_TPREL16_LO,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_TPREL16_LO", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like TPREL16_LO, but next higher group of 16 bits. */
+ HOWTO (R_PPC64_TPREL16_HI,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_TPREL16_HI", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like TPREL16_HI, but adjust for low 16 bits. */
+ HOWTO (R_PPC64_TPREL16_HA,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_TPREL16_HA", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like TPREL16_HI, but next higher group of 16 bits. */
+ HOWTO (R_PPC64_TPREL16_HIGHER,
+ 32, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_TPREL16_HIGHER", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like TPREL16_HIGHER, but adjust for low 16 bits. */
+ HOWTO (R_PPC64_TPREL16_HIGHERA,
+ 32, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_TPREL16_HIGHERA", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like TPREL16_HIGHER, but next higher group of 16 bits. */
+ HOWTO (R_PPC64_TPREL16_HIGHEST,
+ 48, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_TPREL16_HIGHEST", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like TPREL16_HIGHEST, but adjust for low 16 bits. */
+ HOWTO (R_PPC64_TPREL16_HIGHESTA,
+ 48, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_TPREL16_HIGHESTA", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like TPREL16, but for insns with a DS field. */
+ HOWTO (R_PPC64_TPREL16_DS,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_TPREL16_DS", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfffc, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like TPREL16_DS, but no overflow. */
+ HOWTO (R_PPC64_TPREL16_LO_DS,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_TPREL16_LO_DS", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfffc, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Allocates two contiguous entries in the GOT to hold a tls_index structure,
+ with values (sym+add)@dtpmod and (sym+add)@dtprel, and computes the offset
+ to the first entry relative to the TOC base (r2). */
+ HOWTO (R_PPC64_GOT_TLSGD16,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_GOT_TLSGD16", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TLSGD16, but no overflow. */
+ HOWTO (R_PPC64_GOT_TLSGD16_LO,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_GOT_TLSGD16_LO", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TLSGD16_LO, but next higher group of 16 bits. */
+ HOWTO (R_PPC64_GOT_TLSGD16_HI,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_GOT_TLSGD16_HI", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TLSGD16_HI, but adjust for low 16 bits. */
+ HOWTO (R_PPC64_GOT_TLSGD16_HA,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_GOT_TLSGD16_HA", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Allocates two contiguous entries in the GOT to hold a tls_index structure,
+ with values (sym+add)@dtpmod and zero, and computes the offset to the
+ first entry relative to the TOC base (r2). */
+ HOWTO (R_PPC64_GOT_TLSLD16,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_GOT_TLSLD16", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TLSLD16, but no overflow. */
+ HOWTO (R_PPC64_GOT_TLSLD16_LO,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_GOT_TLSLD16_LO", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TLSLD16_LO, but next higher group of 16 bits. */
+ HOWTO (R_PPC64_GOT_TLSLD16_HI,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_GOT_TLSLD16_HI", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TLSLD16_HI, but adjust for low 16 bits. */
+ HOWTO (R_PPC64_GOT_TLSLD16_HA,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_GOT_TLSLD16_HA", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Allocates an entry in the GOT with value (sym+add)@dtprel, and computes
+ the offset to the entry relative to the TOC base (r2). */
+ HOWTO (R_PPC64_GOT_DTPREL16_DS,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_GOT_DTPREL16_DS", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfffc, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_DTPREL16_DS, but no overflow. */
+ HOWTO (R_PPC64_GOT_DTPREL16_LO_DS,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_GOT_DTPREL16_LO_DS", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfffc, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_DTPREL16_LO_DS, but next higher group of 16 bits. */
+ HOWTO (R_PPC64_GOT_DTPREL16_HI,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_GOT_DTPREL16_HI", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_DTPREL16_HI, but adjust for low 16 bits. */
+ HOWTO (R_PPC64_GOT_DTPREL16_HA,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_GOT_DTPREL16_HA", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Allocates an entry in the GOT with value (sym+add)@tprel, and computes the
+ offset to the entry relative to the TOC base (r2). */
+ HOWTO (R_PPC64_GOT_TPREL16_DS,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_signed, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_GOT_TPREL16_DS", /* name */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0xfffc, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TPREL16_DS, but no overflow. */
+ HOWTO (R_PPC64_GOT_TPREL16_LO_DS,
+ 0, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_GOT_TPREL16_LO_DS", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xfffc, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TPREL16_LO_DS, but next higher group of 16 bits. */
+ HOWTO (R_PPC64_GOT_TPREL16_HI,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_GOT_TPREL16_HI", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
+
+ /* Like GOT_TPREL16_HI, but adjust for low 16 bits. */
+ HOWTO (R_PPC64_GOT_TPREL16_HA,
+ 16, /* rightshift */
+ 1, /* size (0 = byte, 1 = short, 2 = long) */
+ 16, /* bitsize */
+ FALSE, /* pc_relative */
+ 0, /* bitpos */
+ complain_overflow_dont, /* complain_on_overflow */
+ ppc64_elf_unhandled_reloc, /* special_function */
+ "R_PPC64_GOT_TPREL16_HA", /* name */
+ FALSE, /* partial_inplace */
+ 0, /* src_mask */
+ 0xffff, /* dst_mask */
+ FALSE), /* pcrel_offset */
/* GNU extension to record C++ vtable hierarchy. */
HOWTO (R_PPC64_GNU_VTINHERIT, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
NULL, /* special_function */
"R_PPC64_GNU_VTINHERIT", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* GNU extension to record C++ vtable member usage. */
HOWTO (R_PPC64_GNU_VTENTRY, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
NULL, /* special_function */
"R_PPC64_GNU_VTENTRY", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
};
@@ -1190,7 +1854,7 @@ static reloc_howto_type ppc64_elf_howto_raw[] = {
be done. */
static void
-ppc_howto_init ()
+ppc_howto_init (void)
{
unsigned int i, type;
@@ -1206,155 +1870,232 @@ ppc_howto_init ()
}
static reloc_howto_type *
-ppc64_elf_reloc_type_lookup (abfd, code)
- bfd *abfd ATTRIBUTE_UNUSED;
- bfd_reloc_code_real_type code;
+ppc64_elf_reloc_type_lookup (bfd *abfd ATTRIBUTE_UNUSED,
+ bfd_reloc_code_real_type code)
{
- enum elf_ppc_reloc_type ppc_reloc = R_PPC_NONE;
+ enum elf_ppc64_reloc_type r = R_PPC64_NONE;
if (!ppc64_elf_howto_table[R_PPC64_ADDR32])
/* Initialize howto table if needed. */
ppc_howto_init ();
- switch ((int) code)
+ switch (code)
{
default:
- return (reloc_howto_type *) NULL;
+ return NULL;
- case BFD_RELOC_NONE: ppc_reloc = R_PPC64_NONE;
+ case BFD_RELOC_NONE: r = R_PPC64_NONE;
+ break;
+ case BFD_RELOC_32: r = R_PPC64_ADDR32;
+ break;
+ case BFD_RELOC_PPC_BA26: r = R_PPC64_ADDR24;
+ break;
+ case BFD_RELOC_16: r = R_PPC64_ADDR16;
+ break;
+ case BFD_RELOC_LO16: r = R_PPC64_ADDR16_LO;
+ break;
+ case BFD_RELOC_HI16: r = R_PPC64_ADDR16_HI;
+ break;
+ case BFD_RELOC_HI16_S: r = R_PPC64_ADDR16_HA;
+ break;
+ case BFD_RELOC_PPC_BA16: r = R_PPC64_ADDR14;
+ break;
+ case BFD_RELOC_PPC_BA16_BRTAKEN: r = R_PPC64_ADDR14_BRTAKEN;
+ break;
+ case BFD_RELOC_PPC_BA16_BRNTAKEN: r = R_PPC64_ADDR14_BRNTAKEN;
+ break;
+ case BFD_RELOC_PPC_B26: r = R_PPC64_REL24;
+ break;
+ case BFD_RELOC_PPC_B16: r = R_PPC64_REL14;
+ break;
+ case BFD_RELOC_PPC_B16_BRTAKEN: r = R_PPC64_REL14_BRTAKEN;
+ break;
+ case BFD_RELOC_PPC_B16_BRNTAKEN: r = R_PPC64_REL14_BRNTAKEN;
+ break;
+ case BFD_RELOC_16_GOTOFF: r = R_PPC64_GOT16;
+ break;
+ case BFD_RELOC_LO16_GOTOFF: r = R_PPC64_GOT16_LO;
+ break;
+ case BFD_RELOC_HI16_GOTOFF: r = R_PPC64_GOT16_HI;
+ break;
+ case BFD_RELOC_HI16_S_GOTOFF: r = R_PPC64_GOT16_HA;
+ break;
+ case BFD_RELOC_PPC_COPY: r = R_PPC64_COPY;
+ break;
+ case BFD_RELOC_PPC_GLOB_DAT: r = R_PPC64_GLOB_DAT;
+ break;
+ case BFD_RELOC_32_PCREL: r = R_PPC64_REL32;
+ break;
+ case BFD_RELOC_32_PLTOFF: r = R_PPC64_PLT32;
+ break;
+ case BFD_RELOC_32_PLT_PCREL: r = R_PPC64_PLTREL32;
+ break;
+ case BFD_RELOC_LO16_PLTOFF: r = R_PPC64_PLT16_LO;
+ break;
+ case BFD_RELOC_HI16_PLTOFF: r = R_PPC64_PLT16_HI;
+ break;
+ case BFD_RELOC_HI16_S_PLTOFF: r = R_PPC64_PLT16_HA;
+ break;
+ case BFD_RELOC_16_BASEREL: r = R_PPC64_SECTOFF;
+ break;
+ case BFD_RELOC_LO16_BASEREL: r = R_PPC64_SECTOFF_LO;
+ break;
+ case BFD_RELOC_HI16_BASEREL: r = R_PPC64_SECTOFF_HI;
+ break;
+ case BFD_RELOC_HI16_S_BASEREL: r = R_PPC64_SECTOFF_HA;
break;
- case BFD_RELOC_32: ppc_reloc = R_PPC64_ADDR32;
+ case BFD_RELOC_CTOR: r = R_PPC64_ADDR64;
break;
- case BFD_RELOC_PPC_BA26: ppc_reloc = R_PPC64_ADDR24;
+ case BFD_RELOC_64: r = R_PPC64_ADDR64;
break;
- case BFD_RELOC_16: ppc_reloc = R_PPC64_ADDR16;
+ case BFD_RELOC_PPC64_HIGHER: r = R_PPC64_ADDR16_HIGHER;
break;
- case BFD_RELOC_LO16: ppc_reloc = R_PPC64_ADDR16_LO;
+ case BFD_RELOC_PPC64_HIGHER_S: r = R_PPC64_ADDR16_HIGHERA;
break;
- case BFD_RELOC_HI16: ppc_reloc = R_PPC64_ADDR16_HI;
+ case BFD_RELOC_PPC64_HIGHEST: r = R_PPC64_ADDR16_HIGHEST;
break;
- case BFD_RELOC_HI16_S: ppc_reloc = R_PPC64_ADDR16_HA;
+ case BFD_RELOC_PPC64_HIGHEST_S: r = R_PPC64_ADDR16_HIGHESTA;
break;
- case BFD_RELOC_PPC_BA16: ppc_reloc = R_PPC64_ADDR14;
+ case BFD_RELOC_64_PCREL: r = R_PPC64_REL64;
break;
- case BFD_RELOC_PPC_BA16_BRTAKEN: ppc_reloc = R_PPC64_ADDR14_BRTAKEN;
+ case BFD_RELOC_64_PLTOFF: r = R_PPC64_PLT64;
break;
- case BFD_RELOC_PPC_BA16_BRNTAKEN: ppc_reloc = R_PPC64_ADDR14_BRNTAKEN;
+ case BFD_RELOC_64_PLT_PCREL: r = R_PPC64_PLTREL64;
break;
- case BFD_RELOC_PPC_B26: ppc_reloc = R_PPC64_REL24;
+ case BFD_RELOC_PPC_TOC16: r = R_PPC64_TOC16;
break;
- case BFD_RELOC_PPC_B16: ppc_reloc = R_PPC64_REL14;
+ case BFD_RELOC_PPC64_TOC16_LO: r = R_PPC64_TOC16_LO;
break;
- case BFD_RELOC_PPC_B16_BRTAKEN: ppc_reloc = R_PPC64_REL14_BRTAKEN;
+ case BFD_RELOC_PPC64_TOC16_HI: r = R_PPC64_TOC16_HI;
break;
- case BFD_RELOC_PPC_B16_BRNTAKEN: ppc_reloc = R_PPC64_REL14_BRNTAKEN;
+ case BFD_RELOC_PPC64_TOC16_HA: r = R_PPC64_TOC16_HA;
break;
- case BFD_RELOC_16_GOTOFF: ppc_reloc = R_PPC64_GOT16;
+ case BFD_RELOC_PPC64_TOC: r = R_PPC64_TOC;
break;
- case BFD_RELOC_LO16_GOTOFF: ppc_reloc = R_PPC64_GOT16_LO;
+ case BFD_RELOC_PPC64_PLTGOT16: r = R_PPC64_PLTGOT16;
break;
- case BFD_RELOC_HI16_GOTOFF: ppc_reloc = R_PPC64_GOT16_HI;
+ case BFD_RELOC_PPC64_PLTGOT16_LO: r = R_PPC64_PLTGOT16_LO;
break;
- case BFD_RELOC_HI16_S_GOTOFF: ppc_reloc = R_PPC64_GOT16_HA;
+ case BFD_RELOC_PPC64_PLTGOT16_HI: r = R_PPC64_PLTGOT16_HI;
break;
- case BFD_RELOC_PPC_COPY: ppc_reloc = R_PPC64_COPY;
+ case BFD_RELOC_PPC64_PLTGOT16_HA: r = R_PPC64_PLTGOT16_HA;
break;
- case BFD_RELOC_PPC_GLOB_DAT: ppc_reloc = R_PPC64_GLOB_DAT;
+ case BFD_RELOC_PPC64_ADDR16_DS: r = R_PPC64_ADDR16_DS;
break;
- case BFD_RELOC_32_PCREL: ppc_reloc = R_PPC64_REL32;
+ case BFD_RELOC_PPC64_ADDR16_LO_DS: r = R_PPC64_ADDR16_LO_DS;
break;
- case BFD_RELOC_32_PLTOFF: ppc_reloc = R_PPC64_PLT32;
+ case BFD_RELOC_PPC64_GOT16_DS: r = R_PPC64_GOT16_DS;
break;
- case BFD_RELOC_32_PLT_PCREL: ppc_reloc = R_PPC64_PLTREL32;
+ case BFD_RELOC_PPC64_GOT16_LO_DS: r = R_PPC64_GOT16_LO_DS;
break;
- case BFD_RELOC_LO16_PLTOFF: ppc_reloc = R_PPC64_PLT16_LO;
+ case BFD_RELOC_PPC64_PLT16_LO_DS: r = R_PPC64_PLT16_LO_DS;
break;
- case BFD_RELOC_HI16_PLTOFF: ppc_reloc = R_PPC64_PLT16_HI;
+ case BFD_RELOC_PPC64_SECTOFF_DS: r = R_PPC64_SECTOFF_DS;
break;
- case BFD_RELOC_HI16_S_PLTOFF: ppc_reloc = R_PPC64_PLT16_HA;
+ case BFD_RELOC_PPC64_SECTOFF_LO_DS: r = R_PPC64_SECTOFF_LO_DS;
break;
- case BFD_RELOC_16_BASEREL: ppc_reloc = R_PPC64_SECTOFF;
+ case BFD_RELOC_PPC64_TOC16_DS: r = R_PPC64_TOC16_DS;
break;
- case BFD_RELOC_LO16_BASEREL: ppc_reloc = R_PPC64_SECTOFF_LO;
+ case BFD_RELOC_PPC64_TOC16_LO_DS: r = R_PPC64_TOC16_LO_DS;
break;
- case BFD_RELOC_HI16_BASEREL: ppc_reloc = R_PPC64_SECTOFF_HI;
+ case BFD_RELOC_PPC64_PLTGOT16_DS: r = R_PPC64_PLTGOT16_DS;
break;
- case BFD_RELOC_HI16_S_BASEREL: ppc_reloc = R_PPC64_SECTOFF_HA;
+ case BFD_RELOC_PPC64_PLTGOT16_LO_DS: r = R_PPC64_PLTGOT16_LO_DS;
break;
- case BFD_RELOC_CTOR: ppc_reloc = R_PPC64_ADDR64;
+ case BFD_RELOC_PPC_TLS: r = R_PPC64_TLS;
break;
- case BFD_RELOC_64: ppc_reloc = R_PPC64_ADDR64;
+ case BFD_RELOC_PPC_DTPMOD: r = R_PPC64_DTPMOD64;
break;
- case BFD_RELOC_PPC64_HIGHER: ppc_reloc = R_PPC64_ADDR16_HIGHER;
+ case BFD_RELOC_PPC_TPREL16: r = R_PPC64_TPREL16;
break;
- case BFD_RELOC_PPC64_HIGHER_S: ppc_reloc = R_PPC64_ADDR16_HIGHERA;
+ case BFD_RELOC_PPC_TPREL16_LO: r = R_PPC64_TPREL16_LO;
break;
- case BFD_RELOC_PPC64_HIGHEST: ppc_reloc = R_PPC64_ADDR16_HIGHEST;
+ case BFD_RELOC_PPC_TPREL16_HI: r = R_PPC64_TPREL16_HI;
break;
- case BFD_RELOC_PPC64_HIGHEST_S: ppc_reloc = R_PPC64_ADDR16_HIGHESTA;
+ case BFD_RELOC_PPC_TPREL16_HA: r = R_PPC64_TPREL16_HA;
break;
- case BFD_RELOC_64_PCREL: ppc_reloc = R_PPC64_REL64;
+ case BFD_RELOC_PPC_TPREL: r = R_PPC64_TPREL64;
break;
- case BFD_RELOC_64_PLTOFF: ppc_reloc = R_PPC64_PLT64;
+ case BFD_RELOC_PPC_DTPREL16: r = R_PPC64_DTPREL16;
break;
- case BFD_RELOC_64_PLT_PCREL: ppc_reloc = R_PPC64_PLTREL64;
+ case BFD_RELOC_PPC_DTPREL16_LO: r = R_PPC64_DTPREL16_LO;
break;
- case BFD_RELOC_PPC_TOC16: ppc_reloc = R_PPC64_TOC16;
+ case BFD_RELOC_PPC_DTPREL16_HI: r = R_PPC64_DTPREL16_HI;
break;
- case BFD_RELOC_PPC64_TOC16_LO: ppc_reloc = R_PPC64_TOC16_LO;
+ case BFD_RELOC_PPC_DTPREL16_HA: r = R_PPC64_DTPREL16_HA;
break;
- case BFD_RELOC_PPC64_TOC16_HI: ppc_reloc = R_PPC64_TOC16_HI;
+ case BFD_RELOC_PPC_DTPREL: r = R_PPC64_DTPREL64;
break;
- case BFD_RELOC_PPC64_TOC16_HA: ppc_reloc = R_PPC64_TOC16_HA;
+ case BFD_RELOC_PPC_GOT_TLSGD16: r = R_PPC64_GOT_TLSGD16;
break;
- case BFD_RELOC_PPC64_TOC: ppc_reloc = R_PPC64_TOC;
+ case BFD_RELOC_PPC_GOT_TLSGD16_LO: r = R_PPC64_GOT_TLSGD16_LO;
break;
- case BFD_RELOC_PPC64_PLTGOT16: ppc_reloc = R_PPC64_PLTGOT16;
+ case BFD_RELOC_PPC_GOT_TLSGD16_HI: r = R_PPC64_GOT_TLSGD16_HI;
break;
- case BFD_RELOC_PPC64_PLTGOT16_LO: ppc_reloc = R_PPC64_PLTGOT16_LO;
+ case BFD_RELOC_PPC_GOT_TLSGD16_HA: r = R_PPC64_GOT_TLSGD16_HA;
break;
- case BFD_RELOC_PPC64_PLTGOT16_HI: ppc_reloc = R_PPC64_PLTGOT16_HI;
+ case BFD_RELOC_PPC_GOT_TLSLD16: r = R_PPC64_GOT_TLSLD16;
break;
- case BFD_RELOC_PPC64_PLTGOT16_HA: ppc_reloc = R_PPC64_PLTGOT16_HA;
+ case BFD_RELOC_PPC_GOT_TLSLD16_LO: r = R_PPC64_GOT_TLSLD16_LO;
break;
- case BFD_RELOC_PPC64_ADDR16_DS: ppc_reloc = R_PPC64_ADDR16_DS;
+ case BFD_RELOC_PPC_GOT_TLSLD16_HI: r = R_PPC64_GOT_TLSLD16_HI;
break;
- case BFD_RELOC_PPC64_ADDR16_LO_DS: ppc_reloc = R_PPC64_ADDR16_LO_DS;
+ case BFD_RELOC_PPC_GOT_TLSLD16_HA: r = R_PPC64_GOT_TLSLD16_HA;
break;
- case BFD_RELOC_PPC64_GOT16_DS: ppc_reloc = R_PPC64_GOT16_DS;
+ case BFD_RELOC_PPC_GOT_TPREL16: r = R_PPC64_GOT_TPREL16_DS;
break;
- case BFD_RELOC_PPC64_GOT16_LO_DS: ppc_reloc = R_PPC64_GOT16_LO_DS;
+ case BFD_RELOC_PPC_GOT_TPREL16_LO: r = R_PPC64_GOT_TPREL16_LO_DS;
break;
- case BFD_RELOC_PPC64_PLT16_LO_DS: ppc_reloc = R_PPC64_PLT16_LO_DS;
+ case BFD_RELOC_PPC_GOT_TPREL16_HI: r = R_PPC64_GOT_TPREL16_HI;
break;
- case BFD_RELOC_PPC64_SECTOFF_DS: ppc_reloc = R_PPC64_SECTOFF_DS;
+ case BFD_RELOC_PPC_GOT_TPREL16_HA: r = R_PPC64_GOT_TPREL16_HA;
break;
- case BFD_RELOC_PPC64_SECTOFF_LO_DS: ppc_reloc = R_PPC64_SECTOFF_LO_DS;
+ case BFD_RELOC_PPC_GOT_DTPREL16: r = R_PPC64_GOT_DTPREL16_DS;
break;
- case BFD_RELOC_PPC64_TOC16_DS: ppc_reloc = R_PPC64_TOC16_DS;
+ case BFD_RELOC_PPC_GOT_DTPREL16_LO: r = R_PPC64_GOT_DTPREL16_LO_DS;
break;
- case BFD_RELOC_PPC64_TOC16_LO_DS: ppc_reloc = R_PPC64_TOC16_LO_DS;
+ case BFD_RELOC_PPC_GOT_DTPREL16_HI: r = R_PPC64_GOT_DTPREL16_HI;
break;
- case BFD_RELOC_PPC64_PLTGOT16_DS: ppc_reloc = R_PPC64_PLTGOT16_DS;
+ case BFD_RELOC_PPC_GOT_DTPREL16_HA: r = R_PPC64_GOT_DTPREL16_HA;
break;
- case BFD_RELOC_PPC64_PLTGOT16_LO_DS: ppc_reloc = R_PPC64_PLTGOT16_LO_DS;
+ case BFD_RELOC_PPC64_TPREL16_DS: r = R_PPC64_TPREL16_DS;
break;
- case BFD_RELOC_VTABLE_INHERIT: ppc_reloc = R_PPC64_GNU_VTINHERIT;
+ case BFD_RELOC_PPC64_TPREL16_LO_DS: r = R_PPC64_TPREL16_LO_DS;
break;
- case BFD_RELOC_VTABLE_ENTRY: ppc_reloc = R_PPC64_GNU_VTENTRY;
+ case BFD_RELOC_PPC64_TPREL16_HIGHER: r = R_PPC64_TPREL16_HIGHER;
+ break;
+ case BFD_RELOC_PPC64_TPREL16_HIGHERA: r = R_PPC64_TPREL16_HIGHERA;
+ break;
+ case BFD_RELOC_PPC64_TPREL16_HIGHEST: r = R_PPC64_TPREL16_HIGHEST;
+ break;
+ case BFD_RELOC_PPC64_TPREL16_HIGHESTA: r = R_PPC64_TPREL16_HIGHESTA;
+ break;
+ case BFD_RELOC_PPC64_DTPREL16_DS: r = R_PPC64_DTPREL16_DS;
+ break;
+ case BFD_RELOC_PPC64_DTPREL16_LO_DS: r = R_PPC64_DTPREL16_LO_DS;
+ break;
+ case BFD_RELOC_PPC64_DTPREL16_HIGHER: r = R_PPC64_DTPREL16_HIGHER;
+ break;
+ case BFD_RELOC_PPC64_DTPREL16_HIGHERA: r = R_PPC64_DTPREL16_HIGHERA;
+ break;
+ case BFD_RELOC_PPC64_DTPREL16_HIGHEST: r = R_PPC64_DTPREL16_HIGHEST;
+ break;
+ case BFD_RELOC_PPC64_DTPREL16_HIGHESTA: r = R_PPC64_DTPREL16_HIGHESTA;
+ break;
+ case BFD_RELOC_VTABLE_INHERIT: r = R_PPC64_GNU_VTINHERIT;
+ break;
+ case BFD_RELOC_VTABLE_ENTRY: r = R_PPC64_GNU_VTENTRY;
break;
}
- return ppc64_elf_howto_table[(int) ppc_reloc];
+ return ppc64_elf_howto_table[r];
};
/* Set the howto pointer for a PowerPC ELF reloc. */
static void
-ppc64_elf_info_to_howto (abfd, cache_ptr, dst)
- bfd *abfd ATTRIBUTE_UNUSED;
- arelent *cache_ptr;
- Elf64_Internal_Rela *dst;
+ppc64_elf_info_to_howto (bfd *abfd ATTRIBUTE_UNUSED, arelent *cache_ptr,
+ Elf_Internal_Rela *dst)
{
unsigned int type;
@@ -1368,18 +2109,12 @@ ppc64_elf_info_to_howto (abfd, cache_ptr, dst)
cache_ptr->howto = ppc64_elf_howto_table[type];
}
-/* Handle the R_PPC_ADDR16_HA and similar relocs. */
+/* Handle the R_PPC64_ADDR16_HA and similar relocs. */
static bfd_reloc_status_type
-ppc64_elf_ha_reloc (abfd, reloc_entry, symbol, data,
- input_section, output_bfd, error_message)
- bfd *abfd;
- arelent *reloc_entry;
- asymbol *symbol;
- PTR data;
- asection *input_section;
- bfd *output_bfd;
- char **error_message;
+ppc64_elf_ha_reloc (bfd *abfd, arelent *reloc_entry, asymbol *symbol,
+ void *data, asection *input_section,
+ bfd *output_bfd, char **error_message)
{
/* If this is a relocatable link (output_bfd test tells us), just
call the generic function. Any adjustment will be done at final
@@ -1396,21 +2131,15 @@ ppc64_elf_ha_reloc (abfd, reloc_entry, symbol, data,
}
static bfd_reloc_status_type
-ppc64_elf_brtaken_reloc (abfd, reloc_entry, symbol, data,
- input_section, output_bfd, error_message)
- bfd *abfd;
- arelent *reloc_entry;
- asymbol *symbol;
- PTR data;
- asection *input_section;
- bfd *output_bfd;
- char **error_message;
+ppc64_elf_brtaken_reloc (bfd *abfd, arelent *reloc_entry, asymbol *symbol,
+ void *data, asection *input_section,
+ bfd *output_bfd, char **error_message)
{
long insn;
- enum elf_ppc_reloc_type r_type;
+ enum elf_ppc64_reloc_type r_type;
bfd_size_type octets;
/* Disabled until we sort out how ld should choose 'y' vs 'at'. */
- boolean is_power4 = false;
+ bfd_boolean is_power4 = FALSE;
/* If this is a relocatable link (output_bfd test tells us), just
call the generic function. Any adjustment will be done at final
@@ -1422,7 +2151,7 @@ ppc64_elf_brtaken_reloc (abfd, reloc_entry, symbol, data,
octets = reloc_entry->address * bfd_octets_per_byte (abfd);
insn = bfd_get_32 (abfd, (bfd_byte *) data + octets);
insn &= ~(0x01 << 21);
- r_type = (enum elf_ppc_reloc_type) reloc_entry->howto->type;
+ r_type = reloc_entry->howto->type;
if (r_type == R_PPC64_ADDR14_BRTAKEN
|| r_type == R_PPC64_REL14_BRTAKEN)
insn |= 0x01 << 21; /* 'y' or 't' bit, lowest bit of BO field. */
@@ -1458,20 +2187,14 @@ ppc64_elf_brtaken_reloc (abfd, reloc_entry, symbol, data,
if ((bfd_signed_vma) (target - from) < 0)
insn ^= 0x01 << 21;
}
- bfd_put_32 (abfd, (bfd_vma) insn, (bfd_byte *) data + octets);
+ bfd_put_32 (abfd, insn, (bfd_byte *) data + octets);
return bfd_reloc_continue;
}
static bfd_reloc_status_type
-ppc64_elf_sectoff_reloc (abfd, reloc_entry, symbol, data,
- input_section, output_bfd, error_message)
- bfd *abfd;
- arelent *reloc_entry;
- asymbol *symbol;
- PTR data;
- asection *input_section;
- bfd *output_bfd;
- char **error_message;
+ppc64_elf_sectoff_reloc (bfd *abfd, arelent *reloc_entry, asymbol *symbol,
+ void *data, asection *input_section,
+ bfd *output_bfd, char **error_message)
{
/* If this is a relocatable link (output_bfd test tells us), just
call the generic function. Any adjustment will be done at final
@@ -1486,15 +2209,9 @@ ppc64_elf_sectoff_reloc (abfd, reloc_entry, symbol, data,
}
static bfd_reloc_status_type
-ppc64_elf_sectoff_ha_reloc (abfd, reloc_entry, symbol, data,
- input_section, output_bfd, error_message)
- bfd *abfd;
- arelent *reloc_entry;
- asymbol *symbol;
- PTR data;
- asection *input_section;
- bfd *output_bfd;
- char **error_message;
+ppc64_elf_sectoff_ha_reloc (bfd *abfd, arelent *reloc_entry, asymbol *symbol,
+ void *data, asection *input_section,
+ bfd *output_bfd, char **error_message)
{
/* If this is a relocatable link (output_bfd test tells us), just
call the generic function. Any adjustment will be done at final
@@ -1512,15 +2229,9 @@ ppc64_elf_sectoff_ha_reloc (abfd, reloc_entry, symbol, data,
}
static bfd_reloc_status_type
-ppc64_elf_toc_reloc (abfd, reloc_entry, symbol, data,
- input_section, output_bfd, error_message)
- bfd *abfd;
- arelent *reloc_entry;
- asymbol *symbol;
- PTR data;
- asection *input_section;
- bfd *output_bfd;
- char **error_message;
+ppc64_elf_toc_reloc (bfd *abfd, arelent *reloc_entry, asymbol *symbol,
+ void *data, asection *input_section,
+ bfd *output_bfd, char **error_message)
{
bfd_vma TOCstart;
@@ -1541,15 +2252,9 @@ ppc64_elf_toc_reloc (abfd, reloc_entry, symbol, data,
}
static bfd_reloc_status_type
-ppc64_elf_toc_ha_reloc (abfd, reloc_entry, symbol, data,
- input_section, output_bfd, error_message)
- bfd *abfd;
- arelent *reloc_entry;
- asymbol *symbol;
- PTR data;
- asection *input_section;
- bfd *output_bfd;
- char **error_message;
+ppc64_elf_toc_ha_reloc (bfd *abfd, arelent *reloc_entry, asymbol *symbol,
+ void *data, asection *input_section,
+ bfd *output_bfd, char **error_message)
{
bfd_vma TOCstart;
@@ -1573,15 +2278,9 @@ ppc64_elf_toc_ha_reloc (abfd, reloc_entry, symbol, data,
}
static bfd_reloc_status_type
-ppc64_elf_toc64_reloc (abfd, reloc_entry, symbol, data,
- input_section, output_bfd, error_message)
- bfd *abfd;
- arelent *reloc_entry;
- asymbol *symbol;
- PTR data;
- asection *input_section;
- bfd *output_bfd;
- char **error_message;
+ppc64_elf_toc64_reloc (bfd *abfd, arelent *reloc_entry, asymbol *symbol,
+ void *data, asection *input_section,
+ bfd *output_bfd, char **error_message)
{
bfd_vma TOCstart;
bfd_size_type octets;
@@ -1603,15 +2302,9 @@ ppc64_elf_toc64_reloc (abfd, reloc_entry, symbol, data,
}
static bfd_reloc_status_type
-ppc64_elf_unhandled_reloc (abfd, reloc_entry, symbol, data,
- input_section, output_bfd, error_message)
- bfd *abfd;
- arelent *reloc_entry;
- asymbol *symbol;
- PTR data;
- asection *input_section;
- bfd *output_bfd;
- char **error_message;
+ppc64_elf_unhandled_reloc (bfd *abfd, arelent *reloc_entry, asymbol *symbol,
+ void *data, asection *input_section,
+ bfd *output_bfd, char **error_message)
{
/* If this is a relocatable link (output_bfd test tells us), just
call the generic function. Any adjustment will be done at final
@@ -1630,12 +2323,45 @@ ppc64_elf_unhandled_reloc (abfd, reloc_entry, symbol, data,
return bfd_reloc_dangerous;
}
+struct ppc64_elf_obj_tdata
+{
+ struct elf_obj_tdata elf;
+
+ /* Shortcuts to dynamic linker sections. */
+ asection *got;
+ asection *relgot;
+
+ /* TLS local dynamic got entry handling. Suppose for multiple GOT
+ sections means we potentially need one of these for each input bfd. */
+ union {
+ bfd_signed_vma refcount;
+ bfd_vma offset;
+ } tlsld_got;
+};
+
+#define ppc64_elf_tdata(bfd) \
+ ((struct ppc64_elf_obj_tdata *) (bfd)->tdata.any)
+
+#define ppc64_tlsld_got(bfd) \
+ (&ppc64_elf_tdata (bfd)->tlsld_got)
+
+/* Override the generic function because we store some extras. */
+
+static bfd_boolean
+ppc64_elf_mkobject (bfd *abfd)
+{
+ bfd_size_type amt = sizeof (struct ppc64_elf_obj_tdata);
+ abfd->tdata.any = bfd_zalloc (abfd, amt);
+ if (abfd->tdata.any == NULL)
+ return FALSE;
+ return TRUE;
+}
+
/* Fix bad default arch selected for a 64 bit input bfd when the
default is 32 bit. */
-static boolean
-ppc64_elf_object_p (abfd)
- bfd *abfd;
+static bfd_boolean
+ppc64_elf_object_p (bfd *abfd)
{
if (abfd->arch_info->the_default && abfd->arch_info->bits_per_word == 32)
{
@@ -1648,16 +2374,53 @@ ppc64_elf_object_p (abfd)
BFD_ASSERT (abfd->arch_info->bits_per_word == 64);
}
}
- return true;
+ return TRUE;
+}
+
+/* Support for core dump NOTE sections. */
+
+static bfd_boolean
+ppc64_elf_grok_prstatus (bfd *abfd, Elf_Internal_Note *note)
+{
+ size_t offset, raw_size;
+
+ if (note->descsz != 504)
+ return FALSE;
+
+ /* pr_cursig */
+ elf_tdata (abfd)->core_signal = bfd_get_16 (abfd, note->descdata + 12);
+
+ /* pr_pid */
+ elf_tdata (abfd)->core_pid = bfd_get_32 (abfd, note->descdata + 32);
+
+ /* pr_reg */
+ offset = 112;
+ raw_size = 384;
+
+ /* Make a ".reg/999" section. */
+ return _bfd_elfcore_make_pseudosection (abfd, ".reg",
+ raw_size, note->descpos + offset);
+}
+
+static bfd_boolean
+ppc64_elf_grok_psinfo (bfd *abfd, Elf_Internal_Note *note)
+{
+ if (note->descsz != 136)
+ return FALSE;
+
+ elf_tdata (abfd)->core_program
+ = _bfd_elfcore_strndup (abfd, note->descdata + 40, 16);
+ elf_tdata (abfd)->core_command
+ = _bfd_elfcore_strndup (abfd, note->descdata + 56, 80);
+
+ return TRUE;
}
/* Merge backend specific data from an object file to the output
object file when linking. */
-static boolean
-ppc64_elf_merge_private_bfd_data (ibfd, obfd)
- bfd *ibfd;
- bfd *obfd;
+static bfd_boolean
+ppc64_elf_merge_private_bfd_data (bfd *ibfd, bfd *obfd)
{
/* Check if we have the same endianess. */
if (ibfd->xvec->byteorder != obfd->xvec->byteorder
@@ -1667,17 +2430,67 @@ ppc64_elf_merge_private_bfd_data (ibfd, obfd)
const char *msg;
if (bfd_big_endian (ibfd))
- msg = _("%s: compiled for a big endian system and target is little endian");
+ msg = _("%s: compiled for a big endian system "
+ "and target is little endian");
else
- msg = _("%s: compiled for a little endian system and target is big endian");
+ msg = _("%s: compiled for a little endian system "
+ "and target is big endian");
(*_bfd_error_handler) (msg, bfd_archive_filename (ibfd));
bfd_set_error (bfd_error_wrong_format);
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
+}
+
+/* Add extra PPC sections. */
+
+static struct bfd_elf_special_section const ppc64_elf_special_sections[]=
+{
+ { ".sdata", 6, -2, SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
+ { ".sbss", 5, -2, SHT_NOBITS, SHF_ALLOC + SHF_WRITE },
+ { ".plt", 4, 0, SHT_NOBITS, 0 },
+ { ".toc", 4, 0, SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
+ { ".toc1", 5, 0, SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
+ { ".tocbss", 7, 0, SHT_NOBITS, SHF_ALLOC + SHF_WRITE },
+ { NULL, 0, 0, 0, 0 }
+};
+
+struct _ppc64_elf_section_data
+{
+ struct bfd_elf_section_data elf;
+
+ /* An array with one entry for each opd function descriptor. */
+ union
+ {
+ /* Points to the function code section for local opd entries. */
+ asection **func_sec;
+ /* After editing .opd, adjust references to opd local syms. */
+ long *adjust;
+ } opd;
+
+ /* An array for toc sections, indexed by offset/8.
+ Specifies the relocation symbol index used at a given toc offset. */
+ unsigned *t_symndx;
+};
+
+#define ppc64_elf_section_data(sec) \
+ ((struct _ppc64_elf_section_data *) elf_section_data (sec))
+
+static bfd_boolean
+ppc64_elf_new_section_hook (bfd *abfd, asection *sec)
+{
+ struct _ppc64_elf_section_data *sdata;
+ bfd_size_type amt = sizeof (*sdata);
+
+ sdata = bfd_zalloc (abfd, amt);
+ if (sdata == NULL)
+ return FALSE;
+ sec->used_by_bfd = sdata;
+
+ return _bfd_elf_new_section_hook (abfd, sec);
}
/* The following functions are specific to the ELF linker, while
@@ -1720,7 +2533,7 @@ ppc64_elf_merge_private_bfd_data (ibfd, obfd)
.
. .foo_stub:
. addis 12,2,Lfoo@toc@ha # in practice, the call stub
- . addi 12,12,Lfoo@toc@l # is slightly optimised, but
+ . addi 12,12,Lfoo@toc@l # is slightly optimized, but
. std 2,40(1) # this is the general idea
. ld 11,0(12)
. ld 2,8(12)
@@ -1768,13 +2581,74 @@ struct ppc_dyn_relocs
bfd_size_type pc_count;
};
+/* Track GOT entries needed for a given symbol. We might need more
+ than one got entry per symbol. */
+struct got_entry
+{
+ struct got_entry *next;
+
+ /* The symbol addend that we'll be placing in the GOT. */
+ bfd_vma addend;
+
+ /* Unlike other ELF targets, we use separate GOT entries for the same
+ symbol referenced from different input files. This is to support
+ automatic multiple TOC/GOT sections, where the TOC base can vary
+ from one input file to another.
+
+ Point to the BFD owning this GOT entry. */
+ bfd *owner;
+
+ /* Zero for non-tls entries, or TLS_TLS and one of TLS_GD, TLS_LD,
+ TLS_TPREL or TLS_DTPREL for tls entries. */
+ char tls_type;
+
+ /* Reference count until size_dynamic_sections, GOT offset thereafter. */
+ union
+ {
+ bfd_signed_vma refcount;
+ bfd_vma offset;
+ } got;
+};
+
+/* The same for PLT. */
+struct plt_entry
+{
+ struct plt_entry *next;
+
+ bfd_vma addend;
+
+ union
+ {
+ bfd_signed_vma refcount;
+ bfd_vma offset;
+ } plt;
+};
+
/* Of those relocs that might be copied as dynamic relocs, this macro
- selects between relative and absolute types. */
+ selects those that must be copied when linking a shared library,
+ even when the symbol is local. */
-#define IS_ABSOLUTE_RELOC(RTYPE) \
+#define MUST_BE_DYN_RELOC(RTYPE) \
((RTYPE) != R_PPC64_REL32 \
&& (RTYPE) != R_PPC64_REL64 \
- && (RTYPE) != R_PPC64_ADDR30)
+ && (RTYPE) != R_PPC64_REL30)
+
+/* If ELIMINATE_COPY_RELOCS is non-zero, the linker will try to avoid
+ copying dynamic variables from a shared lib into an app's dynbss
+ section, and instead use a dynamic relocation to point into the
+ shared lib. With code that gcc generates, it's vital that this be
+ enabled; In the PowerPC64 ABI, the address of a function is actually
+ the address of a function descriptor, which resides in the .opd
+ section. gcc uses the descriptor directly rather than going via the
+ GOT as some other ABI's do, which means that initialized function
+ pointers must reference the descriptor. Thus, a function pointer
+ initialized to the address of a function in a shared library will
+ either require a copy reloc, or a dynamic reloc. Using a copy reloc
+ redefines the function descriptor symbol to point to the copy. This
+ presents a problem as a plt entry for that function is also
+ initialized from the function descriptor symbol and the copy reloc
+ may not be initialized first. */
+#define ELIMINATE_COPY_RELOCS 1
/* Section name for stubs is the associated section name plus this
string. */
@@ -1803,12 +2677,31 @@ struct ppc_dyn_relocs
. mtctr %r11
. ld %r11,xxx+16@toc@l(%r12)
. bctr
+
+ ppc_stub_long_branch and ppc_stub_plt_branch may also have additional
+ code to adjust the value and save r2 to support multiple toc sections.
+ A ppc_stub_long_branch with an r2 offset looks like:
+ . std %r2,40(%r1)
+ . addis %r2,%r2,off@ha
+ . addi %r2,%r2,off@l
+ . b dest
+
+ A ppc_stub_plt_branch with an r2 offset looks like:
+ . std %r2,40(%r1)
+ . addis %r12,%r2,xxx@toc@ha
+ . ld %r11,xxx@toc@l(%r12)
+ . addis %r2,%r2,off@ha
+ . addi %r2,%r2,off@l
+ . mtctr %r11
+ . bctr
*/
enum ppc_stub_type {
ppc_stub_none,
ppc_stub_long_branch,
+ ppc_stub_long_branch_r2off,
ppc_stub_plt_branch,
+ ppc_stub_plt_branch_r2off,
ppc_stub_plt_call
};
@@ -1817,6 +2710,8 @@ struct ppc_stub_hash_entry {
/* Base hash table entry structure. */
struct bfd_hash_entry root;
+ enum ppc_stub_type stub_type;
+
/* The stub section. */
asection *stub_sec;
@@ -1828,11 +2723,12 @@ struct ppc_stub_hash_entry {
bfd_vma target_value;
asection *target_section;
- enum ppc_stub_type stub_type;
-
/* The symbol table entry, if any, that this was derived from. */
struct ppc_link_hash_entry *h;
+ /* And the reloc addend that this was derived from. */
+ bfd_vma addend;
+
/* Where this stub is being called from, or, in the case of combined
stub sections, the first input section in the group. */
asection *id_sec;
@@ -1868,6 +2764,26 @@ struct ppc_link_hash_entry
unsigned int is_func:1;
unsigned int is_func_descriptor:1;
unsigned int is_entry:1;
+
+ /* Whether global opd sym has been adjusted or not. */
+ unsigned int adjust_done:1;
+
+ /* Contexts in which symbol is used in the GOT (or TOC).
+ TLS_GD .. TLS_EXPLICIT bits are or'd into the mask as the
+ corresponding relocs are encountered during check_relocs.
+ tls_optimize clears TLS_GD .. TLS_TPREL when optimizing to
+ indicate the corresponding GOT entry type is not needed.
+ tls_optimize may also set TLS_TPRELGD when a GD reloc turns into
+ a TPREL one. We use a separate flag rather than setting TPREL
+ just for convenience in distinguishing the two cases. */
+#define TLS_GD 1 /* GD reloc. */
+#define TLS_LD 2 /* LD reloc. */
+#define TLS_TPREL 4 /* TPREL reloc, => IE. */
+#define TLS_DTPREL 8 /* DTPREL reloc, => LD. */
+#define TLS_TLS 16 /* Any TLS reloc. */
+#define TLS_EXPLICIT 32 /* Marks TOC section TLS relocs. */
+#define TLS_TPRELGD 64 /* TPREL reloc resulting from GD->IE. */
+ char tls_mask;
};
/* ppc64 ELF linker hash table. */
@@ -1886,8 +2802,8 @@ struct ppc_link_hash_table
bfd *stub_bfd;
/* Linker call-backs. */
- asection * (*add_stub_section) PARAMS ((const char *, asection *));
- void (*layout_sections_again) PARAMS ((void));
+ asection * (*add_stub_section) (const char *, asection *);
+ void (*layout_sections_again) (void);
/* Array to keep track of which stub sections have been created, and
information on stub grouping. */
@@ -1896,23 +2812,45 @@ struct ppc_link_hash_table
asection *link_sec;
/* The stub section. */
asection *stub_sec;
+ /* Along with elf_gp, specifies the TOC pointer used in this group. */
+ bfd_vma toc_off;
} *stub_group;
- /* Assorted information used by ppc64_elf_size_stubs. */
+ /* Support for multiple toc sections. */
+ unsigned int no_multi_toc;
+ unsigned int multi_toc_needed;
+
+ /* Temp used when calculating TOC pointers. */
+ bfd_vma toc_curr;
+
+ /* Highest input section id. */
+ int top_id;
+
+ /* Highest output section index. */
int top_index;
+
+ /* List of input sections for each output section. */
asection **input_list;
/* Short-cuts to get to dynamic linker sections. */
- asection *sgot;
- asection *srelgot;
- asection *splt;
- asection *srelplt;
- asection *sdynbss;
- asection *srelbss;
- asection *sglink;
+ asection *got;
+ asection *plt;
+ asection *relplt;
+ asection *dynbss;
+ asection *relbss;
+ asection *glink;
asection *sfpr;
- asection *sbrlt;
- asection *srelbrlt;
+ asection *brlt;
+ asection *relbrlt;
+
+ /* Shortcut to .__tls_get_addr. */
+ struct elf_link_hash_entry *tls_get_addr;
+
+ /* Statistics. */
+ unsigned long stub_count[ppc_stub_plt_call];
+
+ /* Set if we should emit symbols for stubs. */
+ unsigned int emit_stub_syms;
/* Set on error. */
unsigned int stub_error;
@@ -1931,81 +2869,6 @@ struct ppc_link_hash_table
struct sym_sec_cache sym_sec;
};
-static struct bfd_hash_entry *stub_hash_newfunc
- PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-static struct bfd_hash_entry *branch_hash_newfunc
- PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-static struct bfd_hash_entry *link_hash_newfunc
- PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-static struct bfd_link_hash_table *ppc64_elf_link_hash_table_create
- PARAMS ((bfd *));
-static void ppc64_elf_link_hash_table_free
- PARAMS ((struct bfd_link_hash_table *));
-static char *ppc_stub_name
- PARAMS ((const asection *, const asection *,
- const struct ppc_link_hash_entry *, const Elf_Internal_Rela *));
-static struct ppc_stub_hash_entry *ppc_get_stub_entry
- PARAMS ((const asection *, const asection *, struct elf_link_hash_entry *,
- const Elf_Internal_Rela *, struct ppc_link_hash_table *));
-static struct ppc_stub_hash_entry *ppc_add_stub
- PARAMS ((const char *, asection *, struct ppc_link_hash_table *));
-static boolean create_linkage_sections
- PARAMS ((bfd *, struct bfd_link_info *));
-static boolean create_got_section
- PARAMS ((bfd *, struct bfd_link_info *));
-static boolean ppc64_elf_create_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *));
-static void ppc64_elf_copy_indirect_symbol
- PARAMS ((struct elf_backend_data *, struct elf_link_hash_entry *,
- struct elf_link_hash_entry *));
-static boolean ppc64_elf_check_relocs
- PARAMS ((bfd *, struct bfd_link_info *, asection *,
- const Elf_Internal_Rela *));
-static asection * ppc64_elf_gc_mark_hook
- PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
- struct elf_link_hash_entry *, Elf_Internal_Sym *));
-static boolean ppc64_elf_gc_sweep_hook
- PARAMS ((bfd *, struct bfd_link_info *, asection *,
- const Elf_Internal_Rela *));
-static boolean func_desc_adjust
- PARAMS ((struct elf_link_hash_entry *, PTR));
-static boolean ppc64_elf_func_desc_adjust
- PARAMS ((bfd *, struct bfd_link_info *));
-static boolean ppc64_elf_adjust_dynamic_symbol
- PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *));
-static void ppc64_elf_hide_symbol
- PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *, boolean));
-static boolean edit_opd
- PARAMS ((bfd *, struct bfd_link_info *));
-static boolean allocate_dynrelocs
- PARAMS ((struct elf_link_hash_entry *, PTR));
-static boolean readonly_dynrelocs
- PARAMS ((struct elf_link_hash_entry *, PTR));
-static enum elf_reloc_type_class ppc64_elf_reloc_type_class
- PARAMS ((const Elf_Internal_Rela *));
-static boolean ppc64_elf_size_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *));
-static INLINE enum ppc_stub_type ppc_type_of_stub
- PARAMS ((asection *, const Elf_Internal_Rela *,
- struct ppc_link_hash_entry **, bfd_vma));
-static bfd_byte *build_plt_stub
- PARAMS ((bfd *, bfd_byte *, int, int));
-static boolean ppc_build_one_stub
- PARAMS ((struct bfd_hash_entry *, PTR));
-static boolean ppc_size_one_stub
- PARAMS ((struct bfd_hash_entry *, PTR));
-static void group_sections
- PARAMS ((struct ppc_link_hash_table *, bfd_size_type, boolean));
-static boolean ppc64_elf_relocate_section
- PARAMS ((bfd *, struct bfd_link_info *info, bfd *, asection *, bfd_byte *,
- Elf_Internal_Rela *relocs, Elf_Internal_Sym *local_syms,
- asection **));
-static boolean ppc64_elf_finish_dynamic_symbol
- PARAMS ((bfd *, struct bfd_link_info *, struct elf_link_hash_entry *,
- Elf_Internal_Sym *));
-static boolean ppc64_elf_finish_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *));
-
/* Get the ppc64 ELF linker hash table from a link_info structure. */
#define ppc_hash_table(p) \
@@ -2022,10 +2885,9 @@ static boolean ppc64_elf_finish_dynamic_sections
/* Create an entry in the stub hash table. */
static struct bfd_hash_entry *
-stub_hash_newfunc (entry, table, string)
- struct bfd_hash_entry *entry;
- struct bfd_hash_table *table;
- const char *string;
+stub_hash_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table,
+ const char *string)
{
/* Allocate the structure if it has not already been allocated by a
subclass. */
@@ -2044,11 +2906,11 @@ stub_hash_newfunc (entry, table, string)
/* Initialize the local fields. */
eh = (struct ppc_stub_hash_entry *) entry;
+ eh->stub_type = ppc_stub_none;
eh->stub_sec = NULL;
eh->stub_offset = 0;
eh->target_value = 0;
eh->target_section = NULL;
- eh->stub_type = ppc_stub_none;
eh->h = NULL;
eh->id_sec = NULL;
}
@@ -2059,10 +2921,9 @@ stub_hash_newfunc (entry, table, string)
/* Create an entry in the branch hash table. */
static struct bfd_hash_entry *
-branch_hash_newfunc (entry, table, string)
- struct bfd_hash_entry *entry;
- struct bfd_hash_table *table;
- const char *string;
+branch_hash_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table,
+ const char *string)
{
/* Allocate the structure if it has not already been allocated by a
subclass. */
@@ -2091,10 +2952,9 @@ branch_hash_newfunc (entry, table, string)
/* Create an entry in a ppc64 ELF linker hash table. */
static struct bfd_hash_entry *
-link_hash_newfunc (entry, table, string)
- struct bfd_hash_entry *entry;
- struct bfd_hash_table *table;
- const char *string;
+link_hash_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table,
+ const char *string)
{
/* Allocate the structure if it has not already been allocated by a
subclass. */
@@ -2117,6 +2977,8 @@ link_hash_newfunc (entry, table, string)
eh->is_func = 0;
eh->is_func_descriptor = 0;
eh->is_entry = 0;
+ eh->adjust_done = 0;
+ eh->tls_mask = 0;
}
return entry;
@@ -2125,13 +2987,12 @@ link_hash_newfunc (entry, table, string)
/* Create a ppc64 ELF linker hash table. */
static struct bfd_link_hash_table *
-ppc64_elf_link_hash_table_create (abfd)
- bfd *abfd;
+ppc64_elf_link_hash_table_create (bfd *abfd)
{
struct ppc_link_hash_table *htab;
bfd_size_type amt = sizeof (struct ppc_link_hash_table);
- htab = (struct ppc_link_hash_table *) bfd_malloc (amt);
+ htab = bfd_zmalloc (amt);
if (htab == NULL)
return NULL;
@@ -2149,25 +3010,14 @@ ppc64_elf_link_hash_table_create (abfd)
if (!bfd_hash_table_init (&htab->branch_hash_table, branch_hash_newfunc))
return NULL;
- htab->stub_bfd = NULL;
- htab->add_stub_section = NULL;
- htab->layout_sections_again = NULL;
- htab->stub_group = NULL;
- htab->sgot = NULL;
- htab->srelgot = NULL;
- htab->splt = NULL;
- htab->srelplt = NULL;
- htab->sdynbss = NULL;
- htab->srelbss = NULL;
- htab->sglink = NULL;
- htab->sfpr = NULL;
- htab->sbrlt = NULL;
- htab->srelbrlt = NULL;
- htab->stub_error = 0;
- htab->has_14bit_branch = 0;
- htab->have_undefweak = 0;
- htab->stub_iteration = 0;
- htab->sym_sec.abfd = NULL;
+ /* Initializing two fields of the union is just cosmetic. We really
+ only care about glist, but when compiled on a 32-bit host the
+ bfd_vma fields are larger. Setting the bfd_vma to zero makes
+ debugger inspection of these fields look nicer. */
+ htab->elf.init_refcount.refcount = 0;
+ htab->elf.init_refcount.glist = NULL;
+ htab->elf.init_offset.offset = 0;
+ htab->elf.init_offset.glist = NULL;
return &htab->elf.root;
}
@@ -2175,8 +3025,7 @@ ppc64_elf_link_hash_table_create (abfd)
/* Free the derived linker hash table. */
static void
-ppc64_elf_link_hash_table_free (hash)
- struct bfd_link_hash_table *hash;
+ppc64_elf_link_hash_table_free (struct bfd_link_hash_table *hash)
{
struct ppc_link_hash_table *ret = (struct ppc_link_hash_table *) hash;
@@ -2185,14 +3034,30 @@ ppc64_elf_link_hash_table_free (hash)
_bfd_generic_link_hash_table_free (hash);
}
+/* Satisfy the ELF linker by filling in some fields in our fake bfd. */
+
+void
+ppc64_elf_init_stub_bfd (bfd *abfd, struct bfd_link_info *info)
+{
+ struct ppc_link_hash_table *htab;
+
+ elf_elfheader (abfd)->e_ident[EI_CLASS] = ELFCLASS64;
+
+/* Always hook our dynamic sections into the first bfd, which is the
+ linker created stub bfd. This ensures that the GOT header is at
+ the start of the output TOC section. */
+ htab = ppc_hash_table (info);
+ htab->stub_bfd = abfd;
+ htab->elf.dynobj = abfd;
+}
+
/* Build a name for an entry in the stub hash table. */
static char *
-ppc_stub_name (input_section, sym_sec, h, rel)
- const asection *input_section;
- const asection *sym_sec;
- const struct ppc_link_hash_entry *h;
- const Elf_Internal_Rela *rel;
+ppc_stub_name (const asection *input_section,
+ const asection *sym_sec,
+ const struct ppc_link_hash_entry *h,
+ const Elf_Internal_Rela *rel)
{
char *stub_name;
bfd_size_type len;
@@ -2208,7 +3073,7 @@ ppc_stub_name (input_section, sym_sec, h, rel)
stub_name = bfd_malloc (len);
if (stub_name != NULL)
{
- sprintf (stub_name, "%08x_%s+%x",
+ sprintf (stub_name, "%08x.%s+%x",
input_section->id & 0xffffffff,
h->elf.root.root.string,
(int) rel->r_addend & 0xffffffff);
@@ -2216,11 +3081,11 @@ ppc_stub_name (input_section, sym_sec, h, rel)
}
else
{
- len = 8 + 1 + 8 + 1 + 8 + 1 + 16 + 1;
+ len = 8 + 1 + 8 + 1 + 8 + 1 + 8 + 1;
stub_name = bfd_malloc (len);
if (stub_name != NULL)
{
- sprintf (stub_name, "%08x_%x:%x+%x",
+ sprintf (stub_name, "%08x.%x:%x+%x",
input_section->id & 0xffffffff,
sym_sec->id & 0xffffffff,
(int) ELF64_R_SYM (rel->r_info) & 0xffffffff,
@@ -2234,12 +3099,11 @@ ppc_stub_name (input_section, sym_sec, h, rel)
creating the stub name takes a bit of time. */
static struct ppc_stub_hash_entry *
-ppc_get_stub_entry (input_section, sym_sec, hash, rel, htab)
- const asection *input_section;
- const asection *sym_sec;
- struct elf_link_hash_entry *hash;
- const Elf_Internal_Rela *rel;
- struct ppc_link_hash_table *htab;
+ppc_get_stub_entry (const asection *input_section,
+ const asection *sym_sec,
+ struct elf_link_hash_entry *hash,
+ const Elf_Internal_Rela *rel,
+ struct ppc_link_hash_table *htab)
{
struct ppc_stub_hash_entry *stub_entry;
struct ppc_link_hash_entry *h = (struct ppc_link_hash_entry *) hash;
@@ -2267,7 +3131,7 @@ ppc_get_stub_entry (input_section, sym_sec, hash, rel, htab)
return NULL;
stub_entry = ppc_stub_hash_lookup (&htab->stub_hash_table,
- stub_name, false, false);
+ stub_name, FALSE, FALSE);
if (h != NULL)
h->stub_cache = stub_entry;
@@ -2281,10 +3145,9 @@ ppc_get_stub_entry (input_section, sym_sec, hash, rel, htab)
stub entry are initialised. */
static struct ppc_stub_hash_entry *
-ppc_add_stub (stub_name, section, htab)
- const char *stub_name;
- asection *section;
- struct ppc_link_hash_table *htab;
+ppc_add_stub (const char *stub_name,
+ asection *section,
+ struct ppc_link_hash_table *htab)
{
asection *link_sec;
asection *stub_sec;
@@ -2319,7 +3182,7 @@ ppc_add_stub (stub_name, section, htab)
/* Enter this entry into the linker stub hash table. */
stub_entry = ppc_stub_hash_lookup (&htab->stub_hash_table, stub_name,
- true, false);
+ TRUE, FALSE);
if (stub_entry == NULL)
{
(*_bfd_error_handler) (_("%s: cannot create stub entry %s"),
@@ -2336,10 +3199,8 @@ ppc_add_stub (stub_name, section, htab)
/* Create sections for linker generated code. */
-static boolean
-create_linkage_sections (dynobj, info)
- bfd *dynobj;
- struct bfd_link_info *info;
+static bfd_boolean
+create_linkage_sections (bfd *dynobj, struct bfd_link_info *info)
{
struct ppc_link_hash_table *htab;
flagword flags;
@@ -2353,107 +3214,118 @@ create_linkage_sections (dynobj, info)
if (htab->sfpr == NULL
|| ! bfd_set_section_flags (dynobj, htab->sfpr, flags)
|| ! bfd_set_section_alignment (dynobj, htab->sfpr, 2))
- return false;
+ return FALSE;
/* Create .glink for lazy dynamic linking support. */
- htab->sglink = bfd_make_section_anyway (dynobj, ".glink");
- if (htab->sglink == NULL
- || ! bfd_set_section_flags (dynobj, htab->sglink, flags)
- || ! bfd_set_section_alignment (dynobj, htab->sglink, 2))
- return false;
+ htab->glink = bfd_make_section_anyway (dynobj, ".glink");
+ if (htab->glink == NULL
+ || ! bfd_set_section_flags (dynobj, htab->glink, flags)
+ || ! bfd_set_section_alignment (dynobj, htab->glink, 2))
+ return FALSE;
/* Create .branch_lt for plt_branch stubs. */
flags = (SEC_ALLOC | SEC_LOAD
| SEC_HAS_CONTENTS | SEC_IN_MEMORY | SEC_LINKER_CREATED);
- htab->sbrlt = bfd_make_section_anyway (dynobj, ".branch_lt");
- if (htab->sbrlt == NULL
- || ! bfd_set_section_flags (dynobj, htab->sbrlt, flags)
- || ! bfd_set_section_alignment (dynobj, htab->sbrlt, 3))
- return false;
+ htab->brlt = bfd_make_section_anyway (dynobj, ".branch_lt");
+ if (htab->brlt == NULL
+ || ! bfd_set_section_flags (dynobj, htab->brlt, flags)
+ || ! bfd_set_section_alignment (dynobj, htab->brlt, 3))
+ return FALSE;
if (info->shared)
{
flags = (SEC_ALLOC | SEC_LOAD | SEC_READONLY
| SEC_HAS_CONTENTS | SEC_IN_MEMORY | SEC_LINKER_CREATED);
- htab->srelbrlt = bfd_make_section_anyway (dynobj, ".rela.branch_lt");
- if (!htab->srelbrlt
- || ! bfd_set_section_flags (dynobj, htab->srelbrlt, flags)
- || ! bfd_set_section_alignment (dynobj, htab->srelbrlt, 3))
- return false;
+ htab->relbrlt = bfd_make_section_anyway (dynobj, ".rela.branch_lt");
+ if (!htab->relbrlt
+ || ! bfd_set_section_flags (dynobj, htab->relbrlt, flags)
+ || ! bfd_set_section_alignment (dynobj, htab->relbrlt, 3))
+ return FALSE;
}
- return true;
+ return TRUE;
}
-/* Create .got and .rela.got sections in DYNOBJ, and set up
- shortcuts to them in our hash table. */
+/* Create .got and .rela.got sections in ABFD, and .got in dynobj if
+ not already done. */
-static boolean
-create_got_section (dynobj, info)
- bfd *dynobj;
- struct bfd_link_info *info;
+static bfd_boolean
+create_got_section (bfd *abfd, struct bfd_link_info *info)
{
- struct ppc_link_hash_table *htab;
+ asection *got, *relgot;
+ flagword flags;
+ struct ppc_link_hash_table *htab = ppc_hash_table (info);
- if (! _bfd_elf_create_got_section (dynobj, info))
- return false;
+ if (!htab->got)
+ {
+ if (! _bfd_elf_create_got_section (htab->elf.dynobj, info))
+ return FALSE;
- htab = ppc_hash_table (info);
- htab->sgot = bfd_get_section_by_name (dynobj, ".got");
- if (!htab->sgot)
- abort ();
+ htab->got = bfd_get_section_by_name (htab->elf.dynobj, ".got");
+ if (!htab->got)
+ abort ();
+ }
+
+ flags = (SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS | SEC_IN_MEMORY
+ | SEC_LINKER_CREATED);
+
+ got = bfd_make_section (abfd, ".got");
+ if (!got
+ || !bfd_set_section_flags (abfd, got, flags)
+ || !bfd_set_section_alignment (abfd, got, 3))
+ return FALSE;
+
+ relgot = bfd_make_section (abfd, ".rela.got");
+ if (!relgot
+ || ! bfd_set_section_flags (abfd, relgot, flags | SEC_READONLY)
+ || ! bfd_set_section_alignment (abfd, relgot, 3))
+ return FALSE;
- htab->srelgot = bfd_make_section (dynobj, ".rela.got");
- if (!htab->srelgot
- || ! bfd_set_section_flags (dynobj, htab->srelgot,
- (SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS
- | SEC_IN_MEMORY | SEC_LINKER_CREATED
- | SEC_READONLY))
- || ! bfd_set_section_alignment (dynobj, htab->srelgot, 3))
- return false;
- return true;
+ ppc64_elf_tdata (abfd)->got = got;
+ ppc64_elf_tdata (abfd)->relgot = relgot;
+ return TRUE;
}
/* Create the dynamic sections, and set up shortcuts. */
-static boolean
-ppc64_elf_create_dynamic_sections (dynobj, info)
- bfd *dynobj;
- struct bfd_link_info *info;
+static bfd_boolean
+ppc64_elf_create_dynamic_sections (bfd *dynobj, struct bfd_link_info *info)
{
struct ppc_link_hash_table *htab;
- htab = ppc_hash_table (info);
- if (!htab->sgot && !create_got_section (dynobj, info))
- return false;
-
if (!_bfd_elf_create_dynamic_sections (dynobj, info))
- return false;
+ return FALSE;
- htab->splt = bfd_get_section_by_name (dynobj, ".plt");
- htab->srelplt = bfd_get_section_by_name (dynobj, ".rela.plt");
- htab->sdynbss = bfd_get_section_by_name (dynobj, ".dynbss");
+ htab = ppc_hash_table (info);
+ if (!htab->got)
+ htab->got = bfd_get_section_by_name (dynobj, ".got");
+ htab->plt = bfd_get_section_by_name (dynobj, ".plt");
+ htab->relplt = bfd_get_section_by_name (dynobj, ".rela.plt");
+ htab->dynbss = bfd_get_section_by_name (dynobj, ".dynbss");
if (!info->shared)
- htab->srelbss = bfd_get_section_by_name (dynobj, ".rela.bss");
+ htab->relbss = bfd_get_section_by_name (dynobj, ".rela.bss");
- if (!htab->splt || !htab->srelplt || !htab->sdynbss
- || (!info->shared && !htab->srelbss))
+ if (!htab->got || !htab->plt || !htab->relplt || !htab->dynbss
+ || (!info->shared && !htab->relbss))
abort ();
- return true;
+ return TRUE;
}
/* Copy the extra info we tack onto an elf_link_hash_entry. */
static void
-ppc64_elf_copy_indirect_symbol (bed, dir, ind)
- struct elf_backend_data *bed;
- struct elf_link_hash_entry *dir, *ind;
+ppc64_elf_copy_indirect_symbol
+ (const struct elf_backend_data *bed ATTRIBUTE_UNUSED,
+ struct elf_link_hash_entry *dir,
+ struct elf_link_hash_entry *ind)
{
struct ppc_link_hash_entry *edir, *eind;
+ flagword mask;
edir = (struct ppc_link_hash_entry *) dir;
eind = (struct ppc_link_hash_entry *) ind;
+ /* Copy over any dynamic relocs we may have on the indirect sym. */
if (eind->dyn_relocs != NULL)
{
if (edir->dyn_relocs != NULL)
@@ -2461,7 +3333,7 @@ ppc64_elf_copy_indirect_symbol (bed, dir, ind)
struct ppc_dyn_relocs **pp;
struct ppc_dyn_relocs *p;
- if (ind->root.type == bfd_link_hash_indirect)
+ if (eind->elf.root.type == bfd_link_hash_indirect)
abort ();
/* Add reloc counts against the weak sym to the strong sym
@@ -2491,16 +3363,102 @@ ppc64_elf_copy_indirect_symbol (bed, dir, ind)
edir->is_func |= eind->is_func;
edir->is_func_descriptor |= eind->is_func_descriptor;
edir->is_entry |= eind->is_entry;
+ edir->tls_mask |= eind->tls_mask;
+
+ mask = (ELF_LINK_HASH_REF_DYNAMIC | ELF_LINK_HASH_REF_REGULAR
+ | ELF_LINK_HASH_REF_REGULAR_NONWEAK | ELF_LINK_NON_GOT_REF
+ | ELF_LINK_HASH_NEEDS_PLT);
+ /* If called to transfer flags for a weakdef during processing
+ of elf_adjust_dynamic_symbol, don't copy ELF_LINK_NON_GOT_REF.
+ We clear it ourselves for ELIMINATE_COPY_RELOCS. */
+ if (ELIMINATE_COPY_RELOCS
+ && eind->elf.root.type != bfd_link_hash_indirect
+ && (edir->elf.elf_link_hash_flags & ELF_LINK_HASH_DYNAMIC_ADJUSTED) != 0)
+ mask &= ~ELF_LINK_NON_GOT_REF;
+
+ edir->elf.elf_link_hash_flags |= eind->elf.elf_link_hash_flags & mask;
+
+ /* If we were called to copy over info for a weak sym, that's all. */
+ if (eind->elf.root.type != bfd_link_hash_indirect)
+ return;
+
+ /* Copy over got entries that we may have already seen to the
+ symbol which just became indirect. */
+ if (eind->elf.got.glist != NULL)
+ {
+ if (edir->elf.got.glist != NULL)
+ {
+ struct got_entry **entp;
+ struct got_entry *ent;
+
+ for (entp = &eind->elf.got.glist; (ent = *entp) != NULL; )
+ {
+ struct got_entry *dent;
+
+ for (dent = edir->elf.got.glist; dent != NULL; dent = dent->next)
+ if (dent->addend == ent->addend
+ && dent->owner == ent->owner
+ && dent->tls_type == ent->tls_type)
+ {
+ dent->got.refcount += ent->got.refcount;
+ *entp = ent->next;
+ break;
+ }
+ if (dent == NULL)
+ entp = &ent->next;
+ }
+ *entp = edir->elf.got.glist;
+ }
+
+ edir->elf.got.glist = eind->elf.got.glist;
+ eind->elf.got.glist = NULL;
+ }
+
+ /* And plt entries. */
+ if (eind->elf.plt.plist != NULL)
+ {
+ if (edir->elf.plt.plist != NULL)
+ {
+ struct plt_entry **entp;
+ struct plt_entry *ent;
+
+ for (entp = &eind->elf.plt.plist; (ent = *entp) != NULL; )
+ {
+ struct plt_entry *dent;
+
+ for (dent = edir->elf.plt.plist; dent != NULL; dent = dent->next)
+ if (dent->addend == ent->addend)
+ {
+ dent->plt.refcount += ent->plt.refcount;
+ *entp = ent->next;
+ break;
+ }
+ if (dent == NULL)
+ entp = &ent->next;
+ }
+ *entp = edir->elf.plt.plist;
+ }
+
+ edir->elf.plt.plist = eind->elf.plt.plist;
+ eind->elf.plt.plist = NULL;
+ }
- _bfd_elf_link_hash_copy_indirect (bed, dir, ind);
+ if (edir->elf.dynindx == -1)
+ {
+ edir->elf.dynindx = eind->elf.dynindx;
+ edir->elf.dynstr_index = eind->elf.dynstr_index;
+ eind->elf.dynindx = -1;
+ eind->elf.dynstr_index = 0;
+ }
+ else
+ BFD_ASSERT (eind->elf.dynindx == -1);
}
/* Set a flag, used by ppc64_elf_gc_mark_hook, on the entry symbol and
symbols undefined on the command-line. */
-boolean
-ppc64_elf_mark_entry_syms (info)
- struct bfd_link_info *info;
+bfd_boolean
+ppc64_elf_mark_entry_syms (struct bfd_link_info *info)
{
struct ppc_link_hash_table *htab;
struct bfd_sym_chain *sym;
@@ -2510,23 +3468,134 @@ ppc64_elf_mark_entry_syms (info)
{
struct elf_link_hash_entry *h;
- h = elf_link_hash_lookup (&htab->elf, sym->name, false, false, false);
+ h = elf_link_hash_lookup (&htab->elf, sym->name, FALSE, FALSE, FALSE);
if (h != NULL)
((struct ppc_link_hash_entry *) h)->is_entry = 1;
}
- return true;
+ return TRUE;
+}
+
+/* Hack symbols defined in .opd sections to be function type. */
+
+static bfd_boolean
+ppc64_elf_add_symbol_hook (bfd *ibfd ATTRIBUTE_UNUSED,
+ struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ Elf_Internal_Sym *isym,
+ const char **name ATTRIBUTE_UNUSED,
+ flagword *flags ATTRIBUTE_UNUSED,
+ asection **sec,
+ bfd_vma *value ATTRIBUTE_UNUSED)
+{
+ if (strcmp (bfd_get_section_name (ibfd, *sec), ".opd") == 0)
+ isym->st_info = ELF_ST_INFO (ELF_ST_BIND (isym->st_info), STT_FUNC);
+ return TRUE;
+}
+
+static bfd_boolean
+update_local_sym_info (bfd *abfd, Elf_Internal_Shdr *symtab_hdr,
+ unsigned long r_symndx, bfd_vma r_addend, int tls_type)
+{
+ struct got_entry **local_got_ents = elf_local_got_ents (abfd);
+ char *local_got_tls_masks;
+
+ if (local_got_ents == NULL)
+ {
+ bfd_size_type size = symtab_hdr->sh_info;
+
+ size *= sizeof (*local_got_ents) + sizeof (*local_got_tls_masks);
+ local_got_ents = bfd_zalloc (abfd, size);
+ if (local_got_ents == NULL)
+ return FALSE;
+ elf_local_got_ents (abfd) = local_got_ents;
+ }
+
+ if ((tls_type & TLS_EXPLICIT) == 0)
+ {
+ struct got_entry *ent;
+
+ for (ent = local_got_ents[r_symndx]; ent != NULL; ent = ent->next)
+ if (ent->addend == r_addend
+ && ent->owner == abfd
+ && ent->tls_type == tls_type)
+ break;
+ if (ent == NULL)
+ {
+ bfd_size_type amt = sizeof (*ent);
+ ent = bfd_alloc (abfd, amt);
+ if (ent == NULL)
+ return FALSE;
+ ent->next = local_got_ents[r_symndx];
+ ent->addend = r_addend;
+ ent->owner = abfd;
+ ent->tls_type = tls_type;
+ ent->got.refcount = 0;
+ local_got_ents[r_symndx] = ent;
+ }
+ ent->got.refcount += 1;
+ }
+
+ local_got_tls_masks = (char *) (local_got_ents + symtab_hdr->sh_info);
+ local_got_tls_masks[r_symndx] |= tls_type;
+ return TRUE;
+}
+
+static bfd_boolean
+update_plt_info (bfd *abfd, struct ppc_link_hash_entry *eh, bfd_vma addend)
+{
+ struct plt_entry *ent;
+
+ for (ent = eh->elf.plt.plist; ent != NULL; ent = ent->next)
+ if (ent->addend == addend)
+ break;
+ if (ent == NULL)
+ {
+ bfd_size_type amt = sizeof (*ent);
+ ent = bfd_alloc (abfd, amt);
+ if (ent == NULL)
+ return FALSE;
+ ent->next = eh->elf.plt.plist;
+ ent->addend = addend;
+ ent->plt.refcount = 0;
+ eh->elf.plt.plist = ent;
+ }
+ ent->plt.refcount += 1;
+ eh->elf.elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_PLT;
+ eh->is_func = 1;
+ return TRUE;
+}
+
+/* Find the function descriptor hash entry from the given function code
+ hash entry FH. Link the entries via their OH fields. */
+static struct ppc_link_hash_entry *
+get_fdh (struct ppc_link_hash_entry *fh, struct ppc_link_hash_table *htab)
+{
+ struct ppc_link_hash_entry *fdh = (struct ppc_link_hash_entry *) fh->oh;
+
+ if (fdh == NULL)
+ {
+ const char *fd_name = fh->elf.root.root.string + 1;
+
+ fdh = (struct ppc_link_hash_entry *)
+ elf_link_hash_lookup (&htab->elf, fd_name, FALSE, FALSE, FALSE);
+ if (fdh != NULL)
+ {
+ fdh->is_func_descriptor = 1;
+ fdh->oh = &fh->elf;
+ fh->is_func = 1;
+ fh->oh = &fdh->elf;
+ }
+ }
+
+ return fdh;
}
/* Look through the relocs for a section during the first phase, and
calculate needed space in the global offset table, procedure
linkage table, and dynamic reloc sections. */
-static boolean
-ppc64_elf_check_relocs (abfd, info, sec, relocs)
- bfd *abfd;
- struct bfd_link_info *info;
- asection *sec;
- const Elf_Internal_Rela *relocs;
+static bfd_boolean
+ppc64_elf_check_relocs (bfd *abfd, struct bfd_link_info *info,
+ asection *sec, const Elf_Internal_Rela *relocs)
{
struct ppc_link_hash_table *htab;
Elf_Internal_Shdr *symtab_hdr;
@@ -2536,8 +3605,17 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
asection *sreloc;
asection **opd_sym_map;
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
+
+ /* Don't do anything special with non-loaded, non-alloced sections.
+ In particular, any relocs in such sections should not affect GOT
+ and PLT reference counting (ie. we don't allow them to create GOT
+ or PLT entries), there's no possibility or desire to optimize TLS
+ relocs, and there's not much point in propagating relocs to shared
+ libs that the dynamic linker won't relocate. */
+ if ((sec->flags & SEC_ALLOC) == 0)
+ return TRUE;
htab = ppc_hash_table (info);
symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
@@ -2567,24 +3645,23 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
bfd_size_type amt;
amt = sec->_raw_size * sizeof (union opd_info) / 24;
- opd_sym_map = (asection **) bfd_zalloc (abfd, amt);
+ opd_sym_map = bfd_zalloc (abfd, amt);
if (opd_sym_map == NULL)
- return false;
- elf_section_data (sec)->tdata = opd_sym_map;
+ return FALSE;
+ ppc64_elf_section_data (sec)->opd.func_sec = opd_sym_map;
}
- if (htab->elf.dynobj == NULL)
- htab->elf.dynobj = abfd;
if (htab->sfpr == NULL
&& !create_linkage_sections (htab->elf.dynobj, info))
- return false;
+ return FALSE;
rel_end = relocs + sec->reloc_count;
for (rel = relocs; rel < rel_end; rel++)
{
unsigned long r_symndx;
struct elf_link_hash_entry *h;
- enum elf_ppc_reloc_type r_type;
+ enum elf_ppc64_reloc_type r_type;
+ int tls_type = 0;
r_symndx = ELF64_R_SYM (rel->r_info);
if (r_symndx < symtab_hdr->sh_info)
@@ -2592,46 +3669,86 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
else
h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- r_type = (enum elf_ppc_reloc_type) ELF64_R_TYPE (rel->r_info);
+ r_type = ELF64_R_TYPE (rel->r_info);
switch (r_type)
{
- /* GOT16 relocations */
+ case R_PPC64_GOT_TLSLD16:
+ case R_PPC64_GOT_TLSLD16_LO:
+ case R_PPC64_GOT_TLSLD16_HI:
+ case R_PPC64_GOT_TLSLD16_HA:
+ ppc64_tlsld_got (abfd)->refcount += 1;
+ tls_type = TLS_TLS | TLS_LD;
+ goto dogottls;
+
+ case R_PPC64_GOT_TLSGD16:
+ case R_PPC64_GOT_TLSGD16_LO:
+ case R_PPC64_GOT_TLSGD16_HI:
+ case R_PPC64_GOT_TLSGD16_HA:
+ tls_type = TLS_TLS | TLS_GD;
+ goto dogottls;
+
+ case R_PPC64_GOT_TPREL16_DS:
+ case R_PPC64_GOT_TPREL16_LO_DS:
+ case R_PPC64_GOT_TPREL16_HI:
+ case R_PPC64_GOT_TPREL16_HA:
+ if (info->shared)
+ info->flags |= DF_STATIC_TLS;
+ tls_type = TLS_TLS | TLS_TPREL;
+ goto dogottls;
+
+ case R_PPC64_GOT_DTPREL16_DS:
+ case R_PPC64_GOT_DTPREL16_LO_DS:
+ case R_PPC64_GOT_DTPREL16_HI:
+ case R_PPC64_GOT_DTPREL16_HA:
+ tls_type = TLS_TLS | TLS_DTPREL;
+ dogottls:
+ sec->has_tls_reloc = 1;
+ /* Fall thru */
+
case R_PPC64_GOT16:
case R_PPC64_GOT16_DS:
case R_PPC64_GOT16_HA:
case R_PPC64_GOT16_HI:
case R_PPC64_GOT16_LO:
case R_PPC64_GOT16_LO_DS:
-
/* This symbol requires a global offset table entry. */
- if (htab->sgot == NULL
- && !create_got_section (htab->elf.dynobj, info))
- return false;
+ sec->has_gp_reloc = 1;
+ if (ppc64_elf_tdata (abfd)->got == NULL
+ && !create_got_section (abfd, info))
+ return FALSE;
if (h != NULL)
{
- h->got.refcount += 1;
- }
- else
- {
- bfd_signed_vma *local_got_refcounts;
+ struct ppc_link_hash_entry *eh;
+ struct got_entry *ent;
- /* This is a global offset table entry for a local symbol. */
- local_got_refcounts = elf_local_got_refcounts (abfd);
- if (local_got_refcounts == NULL)
+ eh = (struct ppc_link_hash_entry *) h;
+ for (ent = eh->elf.got.glist; ent != NULL; ent = ent->next)
+ if (ent->addend == rel->r_addend
+ && ent->owner == abfd
+ && ent->tls_type == tls_type)
+ break;
+ if (ent == NULL)
{
- bfd_size_type size;
-
- size = symtab_hdr->sh_info;
- size *= sizeof (bfd_signed_vma);
- local_got_refcounts = ((bfd_signed_vma *)
- bfd_zalloc (abfd, size));
- if (local_got_refcounts == NULL)
- return false;
- elf_local_got_refcounts (abfd) = local_got_refcounts;
+ bfd_size_type amt = sizeof (*ent);
+ ent = bfd_alloc (abfd, amt);
+ if (ent == NULL)
+ return FALSE;
+ ent->next = eh->elf.got.glist;
+ ent->addend = rel->r_addend;
+ ent->owner = abfd;
+ ent->tls_type = tls_type;
+ ent->got.refcount = 0;
+ eh->elf.got.glist = ent;
}
- local_got_refcounts[r_symndx] += 1;
+ ent->got.refcount += 1;
+ eh->tls_mask |= tls_type;
}
+ else
+ /* This is a global offset table entry for a local symbol. */
+ if (!update_local_sym_info (abfd, symtab_hdr, r_symndx,
+ rel->r_addend, tls_type))
+ return FALSE;
break;
case R_PPC64_PLT16_HA:
@@ -2649,12 +3766,12 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
/* It does not make sense to have a procedure linkage
table entry for a local symbol. */
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
-
- h->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_PLT;
- h->plt.refcount += 1;
- ((struct ppc_link_hash_entry *) h)->is_func = 1;
+ else
+ if (!update_plt_info (abfd, (struct ppc_link_hash_entry *) h,
+ rel->r_addend))
+ return FALSE;
break;
/* The following relocations don't need to propagate the
@@ -2666,26 +3783,40 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
case R_PPC64_SECTOFF_HA:
case R_PPC64_SECTOFF_DS:
case R_PPC64_SECTOFF_LO_DS:
+ case R_PPC64_DTPREL16:
+ case R_PPC64_DTPREL16_LO:
+ case R_PPC64_DTPREL16_HI:
+ case R_PPC64_DTPREL16_HA:
+ case R_PPC64_DTPREL16_DS:
+ case R_PPC64_DTPREL16_LO_DS:
+ case R_PPC64_DTPREL16_HIGHER:
+ case R_PPC64_DTPREL16_HIGHERA:
+ case R_PPC64_DTPREL16_HIGHEST:
+ case R_PPC64_DTPREL16_HIGHESTA:
+ break;
+
+ /* Nor do these. */
case R_PPC64_TOC16:
case R_PPC64_TOC16_LO:
case R_PPC64_TOC16_HI:
case R_PPC64_TOC16_HA:
case R_PPC64_TOC16_DS:
case R_PPC64_TOC16_LO_DS:
+ sec->has_gp_reloc = 1;
break;
/* This relocation describes the C++ object vtable hierarchy.
Reconstruct it for later use during GC. */
case R_PPC64_GNU_VTINHERIT:
- if (!_bfd_elf64_gc_record_vtinherit (abfd, sec, h, rel->r_offset))
- return false;
+ if (!bfd_elf_gc_record_vtinherit (abfd, sec, h, rel->r_offset))
+ return FALSE;
break;
/* This relocation describes which C++ vtable entries are actually
used. Record for later use during GC. */
case R_PPC64_GNU_VTENTRY:
- if (!_bfd_elf64_gc_record_vtentry (abfd, sec, h, rel->r_addend))
- return false;
+ if (!bfd_elf_gc_record_vtentry (abfd, sec, h, rel->r_addend))
+ return FALSE;
break;
case R_PPC64_REL14:
@@ -2701,9 +3832,92 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
{
/* We may need a .plt entry if the function this reloc
refers to is in a shared lib. */
- h->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_PLT;
- h->plt.refcount += 1;
- ((struct ppc_link_hash_entry *) h)->is_func = 1;
+ if (!update_plt_info (abfd, (struct ppc_link_hash_entry *) h,
+ rel->r_addend))
+ return FALSE;
+ if (h == htab->tls_get_addr)
+ sec->has_tls_reloc = 1;
+ else if ((strncmp (h->root.root.string, ".__tls_get_addr", 15)
+ == 0)
+ && (h->root.root.string[15] == 0
+ || h->root.root.string[15] == '@'))
+ {
+ htab->tls_get_addr = h;
+ sec->has_tls_reloc = 1;
+ }
+ }
+ break;
+
+ case R_PPC64_TPREL64:
+ tls_type = TLS_EXPLICIT | TLS_TLS | TLS_TPREL;
+ if (info->shared)
+ info->flags |= DF_STATIC_TLS;
+ goto dotlstoc;
+
+ case R_PPC64_DTPMOD64:
+ if (rel + 1 < rel_end
+ && rel[1].r_info == ELF64_R_INFO (r_symndx, R_PPC64_DTPREL64)
+ && rel[1].r_offset == rel->r_offset + 8)
+ tls_type = TLS_EXPLICIT | TLS_TLS | TLS_GD;
+ else
+ tls_type = TLS_EXPLICIT | TLS_TLS | TLS_LD;
+ goto dotlstoc;
+
+ case R_PPC64_DTPREL64:
+ tls_type = TLS_EXPLICIT | TLS_TLS | TLS_DTPREL;
+ if (rel != relocs
+ && rel[-1].r_info == ELF64_R_INFO (r_symndx, R_PPC64_DTPMOD64)
+ && rel[-1].r_offset == rel->r_offset - 8)
+ /* This is the second reloc of a dtpmod, dtprel pair.
+ Don't mark with TLS_DTPREL. */
+ goto dodyn;
+
+ dotlstoc:
+ sec->has_tls_reloc = 1;
+ if (h != NULL)
+ {
+ struct ppc_link_hash_entry *eh;
+ eh = (struct ppc_link_hash_entry *) h;
+ eh->tls_mask |= tls_type;
+ }
+ else
+ if (!update_local_sym_info (abfd, symtab_hdr, r_symndx,
+ rel->r_addend, tls_type))
+ return FALSE;
+
+ if (ppc64_elf_section_data (sec)->t_symndx == NULL)
+ {
+ /* One extra to simplify get_tls_mask. */
+ bfd_size_type amt = sec->_raw_size * sizeof (unsigned) / 8 + 1;
+ ppc64_elf_section_data (sec)->t_symndx = bfd_zalloc (abfd, amt);
+ if (ppc64_elf_section_data (sec)->t_symndx == NULL)
+ return FALSE;
+ }
+ BFD_ASSERT (rel->r_offset % 8 == 0);
+ ppc64_elf_section_data (sec)->t_symndx[rel->r_offset / 8] = r_symndx;
+
+ /* Mark the second slot of a GD or LD entry.
+ -1 to indicate GD and -2 to indicate LD. */
+ if (tls_type == (TLS_EXPLICIT | TLS_TLS | TLS_GD))
+ ppc64_elf_section_data (sec)->t_symndx[rel->r_offset / 8 + 1] = -1;
+ else if (tls_type == (TLS_EXPLICIT | TLS_TLS | TLS_LD))
+ ppc64_elf_section_data (sec)->t_symndx[rel->r_offset / 8 + 1] = -2;
+ goto dodyn;
+
+ case R_PPC64_TPREL16:
+ case R_PPC64_TPREL16_LO:
+ case R_PPC64_TPREL16_HI:
+ case R_PPC64_TPREL16_HA:
+ case R_PPC64_TPREL16_DS:
+ case R_PPC64_TPREL16_LO_DS:
+ case R_PPC64_TPREL16_HIGHER:
+ case R_PPC64_TPREL16_HIGHERA:
+ case R_PPC64_TPREL16_HIGHEST:
+ case R_PPC64_TPREL16_HIGHESTA:
+ if (info->shared)
+ {
+ info->flags |= DF_STATIC_TLS;
+ goto dodyn;
}
break;
@@ -2712,38 +3926,27 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
&& h != NULL
&& h->root.root.string[0] == '.'
&& h->root.root.string[1] != 0)
- {
- struct elf_link_hash_entry *fdh;
+ get_fdh ((struct ppc_link_hash_entry *) h, htab);
- fdh = elf_link_hash_lookup (&htab->elf, h->root.root.string + 1,
- false, false, false);
- if (fdh != NULL)
- {
- ((struct ppc_link_hash_entry *) fdh)->is_func_descriptor = 1;
- ((struct ppc_link_hash_entry *) fdh)->oh = h;
- ((struct ppc_link_hash_entry *) h)->is_func = 1;
- ((struct ppc_link_hash_entry *) h)->oh = fdh;
- }
- }
if (opd_sym_map != NULL
&& h == NULL
&& rel + 1 < rel_end
- && ((enum elf_ppc_reloc_type) ELF64_R_TYPE ((rel + 1)->r_info)
- == R_PPC64_TOC))
+ && ELF64_R_TYPE ((rel + 1)->r_info) == R_PPC64_TOC)
{
asection *s;
s = bfd_section_from_r_symndx (abfd, &htab->sym_sec, sec,
r_symndx);
if (s == NULL)
- return false;
+ return FALSE;
else if (s != sec)
opd_sym_map[rel->r_offset / 24] = s;
}
/* Fall through. */
- case R_PPC64_REL64:
+ case R_PPC64_REL30:
case R_PPC64_REL32:
+ case R_PPC64_REL64:
case R_PPC64_ADDR14:
case R_PPC64_ADDR14_BRNTAKEN:
case R_PPC64_ADDR14_BRTAKEN:
@@ -2758,12 +3961,15 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
case R_PPC64_ADDR16_LO:
case R_PPC64_ADDR16_LO_DS:
case R_PPC64_ADDR24:
- case R_PPC64_ADDR30:
case R_PPC64_ADDR32:
case R_PPC64_UADDR16:
case R_PPC64_UADDR32:
case R_PPC64_UADDR64:
case R_PPC64_TOC:
+ if (h != NULL && !info->shared)
+ /* We may need a copy reloc. */
+ h->elf_link_hash_flags |= ELF_LINK_NON_GOT_REF;
+
/* Don't propagate .opd relocs. */
if (NO_OPD_RELOCS && opd_sym_map != NULL)
break;
@@ -2780,7 +3986,7 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
later (it is never cleared). In case of a weak definition,
DEF_REGULAR may be cleared later by a strong definition in
a shared library. We account for that possibility below by
- storing information in the relocs_copied field of the hash
+ storing information in the dyn_relocs field of the hash
table entry. A similar situation occurs when creating
shared libraries and symbol visibility changes render the
symbol local.
@@ -2789,16 +3995,16 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
may need to keep relocations for symbols satisfied by a
dynamic library if we manage to avoid copy relocs for the
symbol. */
+ dodyn:
if ((info->shared
- && (sec->flags & SEC_ALLOC) != 0
- && (IS_ABSOLUTE_RELOC (r_type)
+ && (MUST_BE_DYN_RELOC (r_type)
|| (h != NULL
&& (! info->symbolic
|| h->root.type == bfd_link_hash_defweak
|| (h->elf_link_hash_flags
& ELF_LINK_HASH_DEF_REGULAR) == 0))))
- || (!info->shared
- && (sec->flags & SEC_ALLOC) != 0
+ || (ELIMINATE_COPY_RELOCS
+ && !info->shared
&& h != NULL
&& (h->root.type == bfd_link_hash_defweak
|| (h->elf_link_hash_flags
@@ -2820,7 +4026,7 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
elf_elfheader (abfd)->e_shstrndx,
elf_section_data (sec)->rel_hdr.sh_name));
if (name == NULL)
- return false;
+ return FALSE;
if (strncmp (name, ".rela", 5) != 0
|| strcmp (bfd_get_section_name (abfd, sec),
@@ -2846,7 +4052,7 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
if (sreloc == NULL
|| ! bfd_set_section_flags (dynobj, sreloc, flags)
|| ! bfd_set_section_alignment (dynobj, sreloc, 3))
- return false;
+ return FALSE;
}
elf_section_data (sec)->sreloc = sreloc;
}
@@ -2867,7 +4073,7 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
s = bfd_section_from_r_symndx (abfd, &htab->sym_sec,
sec, r_symndx);
if (s == NULL)
- return false;
+ return FALSE;
head = ((struct ppc_dyn_relocs **)
&elf_section_data (s)->local_dynrel);
@@ -2876,11 +4082,9 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
p = *head;
if (p == NULL || p->sec != sec)
{
- p = ((struct ppc_dyn_relocs *)
- bfd_alloc (htab->elf.dynobj,
- (bfd_size_type) sizeof *p));
+ p = bfd_alloc (htab->elf.dynobj, sizeof *p);
if (p == NULL)
- return false;
+ return FALSE;
p->next = *head;
*head = p;
p->sec = sec;
@@ -2889,7 +4093,7 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
}
p->count += 1;
- if (!IS_ABSOLUTE_RELOC (r_type))
+ if (!MUST_BE_DYN_RELOC (r_type))
p->pc_count += 1;
}
break;
@@ -2899,28 +4103,27 @@ ppc64_elf_check_relocs (abfd, info, sec, relocs)
}
}
- return true;
+ return TRUE;
}
/* Return the section that should be marked against GC for a given
relocation. */
static asection *
-ppc64_elf_gc_mark_hook (sec, info, rel, h, sym)
- asection *sec;
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
- Elf_Internal_Rela *rel;
- struct elf_link_hash_entry *h;
- Elf_Internal_Sym *sym;
+ppc64_elf_gc_mark_hook (asection *sec,
+ struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ Elf_Internal_Rela *rel,
+ struct elf_link_hash_entry *h,
+ Elf_Internal_Sym *sym)
{
asection *rsec = NULL;
if (h != NULL)
{
- enum elf_ppc_reloc_type r_type;
+ enum elf_ppc64_reloc_type r_type;
struct ppc_link_hash_entry *fdh;
- r_type = (enum elf_ppc_reloc_type) ELF64_R_TYPE (rel->r_info);
+ r_type = ELF64_R_TYPE (rel->r_info);
switch (r_type)
{
case R_PPC64_GNU_VTINHERIT:
@@ -2942,10 +4145,10 @@ ppc64_elf_gc_mark_hook (sec, info, rel, h, sym)
/* Function entry syms return NULL if they are in .opd
and are not ._start (or others undefined on the ld
command line). Thus we avoid marking all function
- sections, as all functions are referenced in .opd. */
+ sections, as all functions are referenced in .opd. */
else if ((fdh->oh != NULL
&& ((struct ppc_link_hash_entry *) fdh->oh)->is_entry)
- || elf_section_data (sec)->tdata == NULL)
+ || ppc64_elf_section_data (sec)->opd.func_sec == NULL)
rsec = h->root.u.def.section;
break;
@@ -2963,10 +4166,10 @@ ppc64_elf_gc_mark_hook (sec, info, rel, h, sym)
asection **opd_sym_section;
rsec = bfd_section_from_elf_index (sec->owner, sym->st_shndx);
- opd_sym_section = (asection **) elf_section_data (rsec)->tdata;
+ opd_sym_section = ppc64_elf_section_data (rsec)->opd.func_sec;
if (opd_sym_section != NULL)
rsec = opd_sym_section[sym->st_value / 24];
- else if (elf_section_data (sec)->tdata != NULL)
+ else if (ppc64_elf_section_data (sec)->opd.func_sec != NULL)
rsec = NULL;
}
@@ -2976,52 +4179,110 @@ ppc64_elf_gc_mark_hook (sec, info, rel, h, sym)
/* Update the .got, .plt. and dynamic reloc reference counts for the
section being removed. */
-static boolean
-ppc64_elf_gc_sweep_hook (abfd, info, sec, relocs)
- bfd *abfd;
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
- asection *sec;
- const Elf_Internal_Rela *relocs;
+static bfd_boolean
+ppc64_elf_gc_sweep_hook (bfd *abfd, struct bfd_link_info *info,
+ asection *sec, const Elf_Internal_Rela *relocs)
{
+ struct ppc_link_hash_table *htab;
Elf_Internal_Shdr *symtab_hdr;
struct elf_link_hash_entry **sym_hashes;
- bfd_signed_vma *local_got_refcounts;
+ struct got_entry **local_got_ents;
const Elf_Internal_Rela *rel, *relend;
+ if ((sec->flags & SEC_ALLOC) == 0)
+ return TRUE;
+
elf_section_data (sec)->local_dynrel = NULL;
+ htab = ppc_hash_table (info);
symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
sym_hashes = elf_sym_hashes (abfd);
- local_got_refcounts = elf_local_got_refcounts (abfd);
+ local_got_ents = elf_local_got_ents (abfd);
relend = relocs + sec->reloc_count;
for (rel = relocs; rel < relend; rel++)
{
unsigned long r_symndx;
- enum elf_ppc_reloc_type r_type;
- struct elf_link_hash_entry *h;
+ enum elf_ppc64_reloc_type r_type;
+ struct elf_link_hash_entry *h = NULL;
+ char tls_type = 0;
r_symndx = ELF64_R_SYM (rel->r_info);
- r_type = (enum elf_ppc_reloc_type) ELF64_R_TYPE (rel->r_info);
+ r_type = ELF64_R_TYPE (rel->r_info);
+ if (r_symndx >= symtab_hdr->sh_info)
+ {
+ struct ppc_link_hash_entry *eh;
+ struct ppc_dyn_relocs **pp;
+ struct ppc_dyn_relocs *p;
+
+ h = sym_hashes[r_symndx - symtab_hdr->sh_info];
+ eh = (struct ppc_link_hash_entry *) h;
+
+ for (pp = &eh->dyn_relocs; (p = *pp) != NULL; pp = &p->next)
+ if (p->sec == sec)
+ {
+ /* Everything must go for SEC. */
+ *pp = p->next;
+ break;
+ }
+ }
+
switch (r_type)
{
+ case R_PPC64_GOT_TLSLD16:
+ case R_PPC64_GOT_TLSLD16_LO:
+ case R_PPC64_GOT_TLSLD16_HI:
+ case R_PPC64_GOT_TLSLD16_HA:
+ ppc64_tlsld_got (abfd)->refcount -= 1;
+ tls_type = TLS_TLS | TLS_LD;
+ goto dogot;
+
+ case R_PPC64_GOT_TLSGD16:
+ case R_PPC64_GOT_TLSGD16_LO:
+ case R_PPC64_GOT_TLSGD16_HI:
+ case R_PPC64_GOT_TLSGD16_HA:
+ tls_type = TLS_TLS | TLS_GD;
+ goto dogot;
+
+ case R_PPC64_GOT_TPREL16_DS:
+ case R_PPC64_GOT_TPREL16_LO_DS:
+ case R_PPC64_GOT_TPREL16_HI:
+ case R_PPC64_GOT_TPREL16_HA:
+ tls_type = TLS_TLS | TLS_TPREL;
+ goto dogot;
+
+ case R_PPC64_GOT_DTPREL16_DS:
+ case R_PPC64_GOT_DTPREL16_LO_DS:
+ case R_PPC64_GOT_DTPREL16_HI:
+ case R_PPC64_GOT_DTPREL16_HA:
+ tls_type = TLS_TLS | TLS_DTPREL;
+ goto dogot;
+
case R_PPC64_GOT16:
case R_PPC64_GOT16_DS:
case R_PPC64_GOT16_HA:
case R_PPC64_GOT16_HI:
case R_PPC64_GOT16_LO:
case R_PPC64_GOT16_LO_DS:
- if (r_symndx >= symtab_hdr->sh_info)
- {
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- if (h->got.refcount > 0)
- h->got.refcount--;
- }
- else
- {
- if (local_got_refcounts[r_symndx] > 0)
- local_got_refcounts[r_symndx]--;
- }
+ dogot:
+ {
+ struct got_entry *ent;
+
+ if (h != NULL)
+ ent = h->got.glist;
+ else
+ ent = local_got_ents[r_symndx];
+
+ for (; ent != NULL; ent = ent->next)
+ if (ent->addend == rel->r_addend
+ && ent->owner == abfd
+ && ent->tls_type == tls_type)
+ break;
+ if (ent == NULL)
+ abort ();
+ if (ent->got.refcount > 0)
+ ent->got.refcount -= 1;
+ }
break;
case R_PPC64_PLT16_HA:
@@ -3029,87 +4290,21 @@ ppc64_elf_gc_sweep_hook (abfd, info, sec, relocs)
case R_PPC64_PLT16_LO:
case R_PPC64_PLT32:
case R_PPC64_PLT64:
- if (r_symndx >= symtab_hdr->sh_info)
- {
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- if (h->plt.refcount > 0)
- h->plt.refcount--;
- }
- break;
-
case R_PPC64_REL14:
case R_PPC64_REL14_BRNTAKEN:
case R_PPC64_REL14_BRTAKEN:
case R_PPC64_REL24:
- if (r_symndx >= symtab_hdr->sh_info)
- {
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- if (h->plt.refcount > 0)
- h->plt.refcount--;
- }
- break;
-
- case R_PPC64_REL32:
- case R_PPC64_REL64:
- if (r_symndx >= symtab_hdr->sh_info)
- {
- struct ppc_link_hash_entry *eh;
- struct ppc_dyn_relocs **pp;
- struct ppc_dyn_relocs *p;
-
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- eh = (struct ppc_link_hash_entry *) h;
-
- for (pp = &eh->dyn_relocs; (p = *pp) != NULL; pp = &p->next)
- if (p->sec == sec)
- {
- p->pc_count -= 1;
- p->count -= 1;
- if (p->count == 0)
- *pp = p->next;
- break;
- }
- }
- break;
-
- case R_PPC64_ADDR14:
- case R_PPC64_ADDR14_BRNTAKEN:
- case R_PPC64_ADDR14_BRTAKEN:
- case R_PPC64_ADDR16:
- case R_PPC64_ADDR16_DS:
- case R_PPC64_ADDR16_HA:
- case R_PPC64_ADDR16_HI:
- case R_PPC64_ADDR16_HIGHER:
- case R_PPC64_ADDR16_HIGHERA:
- case R_PPC64_ADDR16_HIGHEST:
- case R_PPC64_ADDR16_HIGHESTA:
- case R_PPC64_ADDR16_LO:
- case R_PPC64_ADDR16_LO_DS:
- case R_PPC64_ADDR24:
- case R_PPC64_ADDR30:
- case R_PPC64_ADDR32:
- case R_PPC64_ADDR64:
- case R_PPC64_UADDR16:
- case R_PPC64_UADDR32:
- case R_PPC64_UADDR64:
- case R_PPC64_TOC:
- if (r_symndx >= symtab_hdr->sh_info)
+ if (h != NULL)
{
- struct ppc_link_hash_entry *eh;
- struct ppc_dyn_relocs **pp;
- struct ppc_dyn_relocs *p;
-
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- eh = (struct ppc_link_hash_entry *) h;
+ struct plt_entry *ent;
- for (pp = &eh->dyn_relocs; (p = *pp) != NULL; pp = &p->next)
- if (p->sec == sec)
- {
- p->count -= 1;
- if (p->count == 0)
- *pp = p->next;
- break;
- }
+ for (ent = h->plt.plist; ent != NULL; ent = ent->next)
+ if (ent->addend == rel->r_addend)
+ break;
+ if (ent == NULL)
+ abort ();
+ if (ent->plt.refcount > 0)
+ ent->plt.refcount -= 1;
}
break;
@@ -3117,124 +4312,131 @@ ppc64_elf_gc_sweep_hook (abfd, info, sec, relocs)
break;
}
}
- return true;
+ return TRUE;
}
/* Called via elf_link_hash_traverse to transfer dynamic linking
information on function code symbol entries to their corresponding
function descriptor symbol entries. */
-static boolean
-func_desc_adjust (h, inf)
- struct elf_link_hash_entry *h;
- PTR inf;
+static bfd_boolean
+func_desc_adjust (struct elf_link_hash_entry *h, void *inf)
{
struct bfd_link_info *info;
struct ppc_link_hash_table *htab;
+ struct plt_entry *ent;
+ struct ppc_link_hash_entry *fh;
+ struct ppc_link_hash_entry *fdh;
+ bfd_boolean force_local;
- if (h->root.type == bfd_link_hash_indirect)
- return true;
+ fh = (struct ppc_link_hash_entry *) h;
+ if (fh->elf.root.type == bfd_link_hash_indirect)
+ return TRUE;
- if (h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
+ if (fh->elf.root.type == bfd_link_hash_warning)
+ fh = (struct ppc_link_hash_entry *) fh->elf.root.u.i.link;
- info = (struct bfd_link_info *) inf;
+ info = inf;
htab = ppc_hash_table (info);
/* If this is a function code symbol, transfer dynamic linking
information to the function descriptor symbol. */
- if (!((struct ppc_link_hash_entry *) h)->is_func)
- return true;
+ if (!fh->is_func)
+ return TRUE;
- if (h->root.type == bfd_link_hash_undefweak
- && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_REGULAR))
- htab->have_undefweak = true;
+ if (fh->elf.root.type == bfd_link_hash_undefweak
+ && (fh->elf.elf_link_hash_flags & ELF_LINK_HASH_REF_REGULAR))
+ htab->have_undefweak = TRUE;
- if (h->plt.refcount > 0
- && h->root.root.string[0] == '.'
- && h->root.root.string[1] != '\0')
+ for (ent = fh->elf.plt.plist; ent != NULL; ent = ent->next)
+ if (ent->plt.refcount > 0)
+ break;
+ if (ent == NULL
+ || fh->elf.root.root.string[0] != '.'
+ || fh->elf.root.root.string[1] == '\0')
+ return TRUE;
+
+ /* Find the corresponding function descriptor symbol. Create it
+ as undefined if necessary. */
+
+ fdh = get_fdh (fh, htab);
+ if (fdh != NULL)
+ while (fdh->elf.root.type == bfd_link_hash_indirect
+ || fdh->elf.root.type == bfd_link_hash_warning)
+ fdh = (struct ppc_link_hash_entry *) fdh->elf.root.u.i.link;
+
+ if (fdh == NULL
+ && info->shared
+ && (fh->elf.root.type == bfd_link_hash_undefined
+ || fh->elf.root.type == bfd_link_hash_undefweak))
{
- struct elf_link_hash_entry *fdh = ((struct ppc_link_hash_entry *) h)->oh;
- boolean force_local;
-
- /* Find the corresponding function descriptor symbol. Create it
- as undefined if necessary. */
-
- if (fdh == NULL)
- fdh = elf_link_hash_lookup (&htab->elf, h->root.root.string + 1,
- false, false, true);
-
- if (fdh == NULL
- && info->shared
- && (h->root.type == bfd_link_hash_undefined
- || h->root.type == bfd_link_hash_undefweak))
+ bfd *abfd;
+ asymbol *newsym;
+ struct bfd_link_hash_entry *bh;
+
+ abfd = fh->elf.root.u.undef.abfd;
+ newsym = bfd_make_empty_symbol (abfd);
+ newsym->name = fh->elf.root.root.string + 1;
+ newsym->section = bfd_und_section_ptr;
+ newsym->value = 0;
+ newsym->flags = BSF_OBJECT;
+ if (fh->elf.root.type == bfd_link_hash_undefweak)
+ newsym->flags |= BSF_WEAK;
+
+ bh = &fdh->elf.root;
+ if ( !(_bfd_generic_link_add_one_symbol
+ (info, abfd, newsym->name, newsym->flags,
+ newsym->section, newsym->value, NULL, FALSE, FALSE, &bh)))
{
- bfd *abfd;
- asymbol *newsym;
- struct bfd_link_hash_entry *bh;
-
- abfd = h->root.u.undef.abfd;
- newsym = bfd_make_empty_symbol (abfd);
- newsym->name = h->root.root.string + 1;
- newsym->section = bfd_und_section_ptr;
- newsym->value = 0;
- newsym->flags = BSF_OBJECT;
- if (h->root.type == bfd_link_hash_undefweak)
- newsym->flags |= BSF_WEAK;
-
- bh = &fdh->root;
- if ( !(_bfd_generic_link_add_one_symbol
- (info, abfd, newsym->name, newsym->flags,
- newsym->section, newsym->value, NULL, false, false, &bh)))
- {
- return false;
- }
- fdh = (struct elf_link_hash_entry *) bh;
- fdh->elf_link_hash_flags &= ~ELF_LINK_NON_ELF;
+ return FALSE;
}
+ fdh = (struct ppc_link_hash_entry *) bh;
+ fdh->elf.elf_link_hash_flags &= ~ELF_LINK_NON_ELF;
+ fdh->elf.size = 24;
+ fdh->elf.type = STT_OBJECT;
+ }
- if (fdh != NULL
- && (fdh->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0
- && (info->shared
- || (fdh->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0
- || (fdh->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) != 0))
+ if (fdh != NULL
+ && (fdh->elf.elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0
+ && (info->shared
+ || (fdh->elf.elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0
+ || (fdh->elf.elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) != 0
+ || (fdh->elf.root.type == bfd_link_hash_undefweak
+ && ELF_ST_VISIBILITY (fdh->elf.other) == STV_DEFAULT)))
+ {
+ if (fdh->elf.dynindx == -1)
+ if (! bfd_elf_link_record_dynamic_symbol (info, &fdh->elf))
+ return FALSE;
+ fdh->elf.elf_link_hash_flags
+ |= (fh->elf.elf_link_hash_flags & (ELF_LINK_HASH_REF_REGULAR
+ | ELF_LINK_HASH_REF_DYNAMIC
+ | ELF_LINK_HASH_REF_REGULAR_NONWEAK
+ | ELF_LINK_NON_GOT_REF));
+ if (ELF_ST_VISIBILITY (fh->elf.other) == STV_DEFAULT)
{
- if (fdh->dynindx == -1)
- if (! bfd_elf64_link_record_dynamic_symbol (info, fdh))
- return false;
- fdh->elf_link_hash_flags |= (h->elf_link_hash_flags
- & (ELF_LINK_HASH_REF_REGULAR
- | ELF_LINK_HASH_REF_DYNAMIC
- | ELF_LINK_HASH_REF_REGULAR_NONWEAK
- | ELF_LINK_NON_GOT_REF));
- if (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
- {
- fdh->plt.refcount = h->plt.refcount;
- fdh->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_PLT;
- }
- ((struct ppc_link_hash_entry *) fdh)->is_func_descriptor = 1;
- ((struct ppc_link_hash_entry *) fdh)->oh = h;
- ((struct ppc_link_hash_entry *) h)->oh = fdh;
+ fdh->elf.plt.plist = fh->elf.plt.plist;
+ fdh->elf.elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_PLT;
}
-
- /* Now that the info is on the function descriptor, clear the
- function code sym info. Any function code syms for which we
- don't have a definition in a regular file, we force local.
- This prevents a shared library from exporting syms that have
- been imported from another library. Function code syms that
- are really in the library we must leave global to prevent the
- linker dragging in a definition from a static library. */
- force_local = (info->shared
- && ((h->elf_link_hash_flags
- & ELF_LINK_HASH_DEF_REGULAR) == 0
- || fdh == NULL
- || (fdh->elf_link_hash_flags
- & ELF_LINK_HASH_DEF_REGULAR) == 0
- || (fdh->elf_link_hash_flags
- & ELF_LINK_FORCED_LOCAL) != 0));
- _bfd_elf_link_hash_hide_symbol (info, h, force_local);
+ fdh->is_func_descriptor = 1;
+ fdh->oh = &fh->elf;
+ fh->oh = &fdh->elf;
}
- return true;
+ /* Now that the info is on the function descriptor, clear the
+ function code sym info. Any function code syms for which we
+ don't have a definition in a regular file, we force local.
+ This prevents a shared library from exporting syms that have
+ been imported from another library. Function code syms that
+ are really in the library we must leave global to prevent the
+ linker dragging in a definition from a static library. */
+ force_local
+ = (info->shared
+ && ((fh->elf.elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0
+ || fdh == NULL
+ || (fdh->elf.elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0
+ || (fdh->elf.elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0));
+ _bfd_elf_link_hash_hide_symbol (info, &fh->elf, force_local);
+
+ return TRUE;
}
#define MIN_SAVE_FPR 14
@@ -3244,10 +4446,9 @@ func_desc_adjust (h, inf)
this hook to a) provide some gcc support functions, and b) transfer
dynamic linking information gathered so far on function code symbol
entries, to their corresponding function descriptor symbol entries. */
-static boolean
-ppc64_elf_func_desc_adjust (obfd, info)
- bfd *obfd ATTRIBUTE_UNUSED;
- struct bfd_link_info *info;
+static bfd_boolean
+ppc64_elf_func_desc_adjust (bfd *obfd ATTRIBUTE_UNUSED,
+ struct bfd_link_info *info)
{
struct ppc_link_hash_table *htab;
unsigned int lowest_savef = MAX_SAVE_FPR + 2;
@@ -3261,7 +4462,7 @@ ppc64_elf_func_desc_adjust (obfd, info)
if (htab->sfpr == NULL)
/* We don't have any relocs. */
- return true;
+ return TRUE;
/* First provide any missing ._savef* and ._restf* functions. */
memcpy (sym, "._savef14", 10);
@@ -3269,9 +4470,9 @@ ppc64_elf_func_desc_adjust (obfd, info)
{
sym[7] = i / 10 + '0';
sym[8] = i % 10 + '0';
- h = elf_link_hash_lookup (&htab->elf, sym, false, false, true);
+ h = elf_link_hash_lookup (&htab->elf, sym, FALSE, FALSE, TRUE);
if (h != NULL
- && h->root.type == bfd_link_hash_undefined)
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
{
if (lowest_savef > i)
lowest_savef = i;
@@ -3280,7 +4481,7 @@ ppc64_elf_func_desc_adjust (obfd, info)
h->root.u.def.value = (i - lowest_savef) * 4;
h->type = STT_FUNC;
h->elf_link_hash_flags |= ELF_LINK_HASH_DEF_REGULAR;
- _bfd_elf_link_hash_hide_symbol (info, h, info->shared);
+ _bfd_elf_link_hash_hide_symbol (info, h, TRUE);
}
}
@@ -3289,9 +4490,9 @@ ppc64_elf_func_desc_adjust (obfd, info)
{
sym[7] = i / 10 + '0';
sym[8] = i % 10 + '0';
- h = elf_link_hash_lookup (&htab->elf, sym, false, false, true);
+ h = elf_link_hash_lookup (&htab->elf, sym, FALSE, FALSE, TRUE);
if (h != NULL
- && h->root.type == bfd_link_hash_undefined)
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
{
if (lowest_restf > i)
lowest_restf = i;
@@ -3301,11 +4502,11 @@ ppc64_elf_func_desc_adjust (obfd, info)
+ (i - lowest_restf) * 4);
h->type = STT_FUNC;
h->elf_link_hash_flags |= ELF_LINK_HASH_DEF_REGULAR;
- _bfd_elf_link_hash_hide_symbol (info, h, info->shared);
+ _bfd_elf_link_hash_hide_symbol (info, h, TRUE);
}
}
- elf_link_hash_traverse (&htab->elf, func_desc_adjust, (PTR) info);
+ elf_link_hash_traverse (&htab->elf, func_desc_adjust, info);
htab->sfpr->_raw_size = ((MAX_SAVE_FPR + 2 - lowest_savef) * 4
+ (MAX_SAVE_FPR + 2 - lowest_restf) * 4);
@@ -3315,15 +4516,15 @@ ppc64_elf_func_desc_adjust (obfd, info)
if (!htab->have_undefweak)
{
_bfd_strip_section_from_output (info, htab->sfpr);
- return true;
+ return TRUE;
}
htab->sfpr->_raw_size = 4;
}
- p = (bfd_byte *) bfd_alloc (htab->elf.dynobj, htab->sfpr->_raw_size);
+ p = bfd_alloc (htab->elf.dynobj, htab->sfpr->_raw_size);
if (p == NULL)
- return false;
+ return FALSE;
htab->sfpr->contents = p;
for (i = lowest_savef; i <= MAX_SAVE_FPR; i++)
@@ -3352,7 +4553,7 @@ ppc64_elf_func_desc_adjust (obfd, info)
bfd_put_32 (htab->elf.dynobj, BLR, p);
}
- return true;
+ return TRUE;
}
/* Adjust a symbol defined by a dynamic object and referenced by a
@@ -3361,14 +4562,11 @@ ppc64_elf_func_desc_adjust (obfd, info)
change the definition to something the rest of the link can
understand. */
-static boolean
-ppc64_elf_adjust_dynamic_symbol (info, h)
- struct bfd_link_info *info;
- struct elf_link_hash_entry *h;
+static bfd_boolean
+ppc64_elf_adjust_dynamic_symbol (struct bfd_link_info *info,
+ struct elf_link_hash_entry *h)
{
struct ppc_link_hash_table *htab;
- struct ppc_link_hash_entry * eh;
- struct ppc_dyn_relocs *p;
asection *s;
unsigned int power_of_two;
@@ -3380,20 +4578,22 @@ ppc64_elf_adjust_dynamic_symbol (info, h)
{
/* Clear procedure linkage table information for any symbol that
won't need a .plt entry. */
+ struct plt_entry *ent;
+ for (ent = h->plt.plist; ent != NULL; ent = ent->next)
+ if (ent->plt.refcount > 0)
+ break;
if (!((struct ppc_link_hash_entry *) h)->is_func_descriptor
- || h->plt.refcount <= 0
- || (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0
- || (! info->shared
- && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) == 0
- && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) == 0))
+ || ent == NULL
+ || SYMBOL_CALLS_LOCAL (info, h)
+ || (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+ && h->root.type == bfd_link_hash_undefweak))
{
- h->plt.offset = (bfd_vma) -1;
+ h->plt.plist = NULL;
h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
}
- return true;
}
else
- h->plt.offset = (bfd_vma) -1;
+ h->plt.plist = NULL;
/* If this is a weak symbol, and there is a real definition, the
processor independent code will have arranged for us to see the
@@ -3404,40 +4604,63 @@ ppc64_elf_adjust_dynamic_symbol (info, h)
|| h->weakdef->root.type == bfd_link_hash_defweak);
h->root.u.def.section = h->weakdef->root.u.def.section;
h->root.u.def.value = h->weakdef->root.u.def.value;
- return true;
+ if (ELIMINATE_COPY_RELOCS)
+ h->elf_link_hash_flags
+ = ((h->elf_link_hash_flags & ~ELF_LINK_NON_GOT_REF)
+ | (h->weakdef->elf_link_hash_flags & ELF_LINK_NON_GOT_REF));
+ return TRUE;
}
- /* This is a reference to a symbol defined by a dynamic object which
- is not a function. */
-
/* If we are creating a shared library, we must presume that the
only references to the symbol are via the global offset table.
For such cases we need not do anything here; the relocations will
be handled correctly by relocate_section. */
if (info->shared)
- return true;
+ return TRUE;
/* If there are no references to this symbol that do not use the
GOT, we don't need to generate a copy reloc. */
if ((h->elf_link_hash_flags & ELF_LINK_NON_GOT_REF) == 0)
- return true;
+ return TRUE;
- eh = (struct ppc_link_hash_entry *) h;
- for (p = eh->dyn_relocs; p != NULL; p = p->next)
+ if (ELIMINATE_COPY_RELOCS)
{
- s = p->sec->output_section;
- if (s != NULL && (s->flags & SEC_READONLY) != 0)
- break;
+ struct ppc_link_hash_entry * eh;
+ struct ppc_dyn_relocs *p;
+
+ eh = (struct ppc_link_hash_entry *) h;
+ for (p = eh->dyn_relocs; p != NULL; p = p->next)
+ {
+ s = p->sec->output_section;
+ if (s != NULL && (s->flags & SEC_READONLY) != 0)
+ break;
+ }
+
+ /* If we didn't find any dynamic relocs in read-only sections, then
+ we'll be keeping the dynamic relocs and avoiding the copy reloc. */
+ if (p == NULL)
+ {
+ h->elf_link_hash_flags &= ~ELF_LINK_NON_GOT_REF;
+ return TRUE;
+ }
}
- /* If we didn't find any dynamic relocs in read-only sections, then
- we'll be keeping the dynamic relocs and avoiding the copy reloc. */
- if (p == NULL)
+ if (h->plt.plist != NULL)
{
- h->elf_link_hash_flags &= ~ELF_LINK_NON_GOT_REF;
- return true;
+ /* We should never get here, but unfortunately there are versions
+ of gcc out there that improperly (for this ABI) put initialized
+ function pointers, vtable refs and suchlike in read-only
+ sections. Allow them to proceed, but warn that this might
+ break at runtime. */
+ (*_bfd_error_handler)
+ (_("copy reloc against `%s' requires lazy plt linking; "
+ "avoid setting LD_BIND_NOW=1 or upgrade gcc"),
+ h->root.root.string);
}
+ /* This is a reference to a symbol defined by a dynamic object which
+ is not a function. */
+
/* We must allocate the symbol in our .dynbss section, which will
become part of the .bss section of the executable. There will be
an entry for this symbol in the .dynsym section. The dynamic
@@ -3448,13 +4671,13 @@ ppc64_elf_adjust_dynamic_symbol (info, h)
both the dynamic object and the regular object will refer to the
same memory location for the variable. */
- /* We must generate a R_PPC_COPY reloc to tell the dynamic linker to
- copy the initial value out of the dynamic object and into the
+ /* We must generate a R_PPC64_COPY reloc to tell the dynamic linker
+ to copy the initial value out of the dynamic object and into the
runtime process image. We need to remember the offset into the
.rela.bss section we are going to use. */
if ((h->root.u.def.section->flags & SEC_ALLOC) != 0)
{
- htab->srelbss->_raw_size += sizeof (Elf64_External_Rela);
+ htab->relbss->_raw_size += sizeof (Elf64_External_Rela);
h->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_COPY;
}
@@ -3465,12 +4688,12 @@ ppc64_elf_adjust_dynamic_symbol (info, h)
power_of_two = 4;
/* Apply the required alignment. */
- s = htab->sdynbss;
+ s = htab->dynbss;
s->_raw_size = BFD_ALIGN (s->_raw_size, (bfd_size_type) (1 << power_of_two));
if (power_of_two > bfd_get_section_alignment (htab->elf.dynobj, s))
{
if (! bfd_set_section_alignment (htab->elf.dynobj, s, power_of_two))
- return false;
+ return FALSE;
}
/* Define the symbol as being at this point in the section. */
@@ -3480,16 +4703,15 @@ ppc64_elf_adjust_dynamic_symbol (info, h)
/* Increment the section size to make room for the symbol. */
s->_raw_size += h->size;
- return true;
+ return TRUE;
}
/* If given a function descriptor symbol, hide both the function code
sym and the descriptor. */
static void
-ppc64_elf_hide_symbol (info, h, force_local)
- struct bfd_link_info *info;
- struct elf_link_hash_entry *h;
- boolean force_local;
+ppc64_elf_hide_symbol (struct bfd_link_info *info,
+ struct elf_link_hash_entry *h,
+ bfd_boolean force_local)
{
_bfd_elf_link_hash_hide_symbol (info, h, force_local);
@@ -3516,7 +4738,7 @@ ppc64_elf_hide_symbol (info, h, force_local)
save = *p;
*(char *) p = '.';
htab = ppc_hash_table (info);
- fh = elf_link_hash_lookup (&htab->elf, p, false, false, false);
+ fh = elf_link_hash_lookup (&htab->elf, p, FALSE, FALSE, FALSE);
*(char *) p = save;
/* Unfortunately, if it so happens that the string we were
@@ -3529,7 +4751,7 @@ ppc64_elf_hide_symbol (info, h, force_local)
while (q >= h->root.root.string && *q == *p)
--q, --p;
if (q < h->root.root.string && *p == '.')
- fh = elf_link_hash_lookup (&htab->elf, p, false, false, false);
+ fh = elf_link_hash_lookup (&htab->elf, p, FALSE, FALSE, FALSE);
}
if (fh != NULL)
{
@@ -3542,17 +4764,197 @@ ppc64_elf_hide_symbol (info, h, force_local)
}
}
-static boolean
-edit_opd (obfd, info)
- bfd *obfd;
- struct bfd_link_info *info;
+static bfd_boolean
+get_sym_h (struct elf_link_hash_entry **hp, Elf_Internal_Sym **symp,
+ asection **symsecp, char **tls_maskp, Elf_Internal_Sym **locsymsp,
+ unsigned long r_symndx, bfd *ibfd)
+{
+ Elf_Internal_Shdr *symtab_hdr = &elf_tdata (ibfd)->symtab_hdr;
+
+ if (r_symndx >= symtab_hdr->sh_info)
+ {
+ struct elf_link_hash_entry **sym_hashes = elf_sym_hashes (ibfd);
+ struct elf_link_hash_entry *h;
+
+ h = sym_hashes[r_symndx - symtab_hdr->sh_info];
+ while (h->root.type == bfd_link_hash_indirect
+ || h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ if (hp != NULL)
+ *hp = h;
+
+ if (symp != NULL)
+ *symp = NULL;
+
+ if (symsecp != NULL)
+ {
+ asection *symsec = NULL;
+ if (h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak)
+ symsec = h->root.u.def.section;
+ *symsecp = symsec;
+ }
+
+ if (tls_maskp != NULL)
+ {
+ struct ppc_link_hash_entry *eh;
+
+ eh = (struct ppc_link_hash_entry *) h;
+ *tls_maskp = &eh->tls_mask;
+ }
+ }
+ else
+ {
+ Elf_Internal_Sym *sym;
+ Elf_Internal_Sym *locsyms = *locsymsp;
+
+ if (locsyms == NULL)
+ {
+ locsyms = (Elf_Internal_Sym *) symtab_hdr->contents;
+ if (locsyms == NULL)
+ locsyms = bfd_elf_get_elf_syms (ibfd, symtab_hdr,
+ symtab_hdr->sh_info,
+ 0, NULL, NULL, NULL);
+ if (locsyms == NULL)
+ return FALSE;
+ *locsymsp = locsyms;
+ }
+ sym = locsyms + r_symndx;
+
+ if (hp != NULL)
+ *hp = NULL;
+
+ if (symp != NULL)
+ *symp = sym;
+
+ if (symsecp != NULL)
+ {
+ asection *symsec = NULL;
+ if ((sym->st_shndx != SHN_UNDEF
+ && sym->st_shndx < SHN_LORESERVE)
+ || sym->st_shndx > SHN_HIRESERVE)
+ symsec = bfd_section_from_elf_index (ibfd, sym->st_shndx);
+ *symsecp = symsec;
+ }
+
+ if (tls_maskp != NULL)
+ {
+ struct got_entry **lgot_ents;
+ char *tls_mask;
+
+ tls_mask = NULL;
+ lgot_ents = elf_local_got_ents (ibfd);
+ if (lgot_ents != NULL)
+ {
+ char *lgot_masks = (char *) (lgot_ents + symtab_hdr->sh_info);
+ tls_mask = &lgot_masks[r_symndx];
+ }
+ *tls_maskp = tls_mask;
+ }
+ }
+ return TRUE;
+}
+
+/* Returns TLS_MASKP for the given REL symbol. Function return is 0 on
+ error, 2 on a toc GD type suitable for optimization, 3 on a toc LD
+ type suitable for optimization, and 1 otherwise. */
+
+static int
+get_tls_mask (char **tls_maskp, unsigned long *toc_symndx,
+ Elf_Internal_Sym **locsymsp,
+ const Elf_Internal_Rela *rel, bfd *ibfd)
+{
+ unsigned long r_symndx;
+ int next_r;
+ struct elf_link_hash_entry *h;
+ Elf_Internal_Sym *sym;
+ asection *sec;
+ bfd_vma off;
+
+ r_symndx = ELF64_R_SYM (rel->r_info);
+ if (!get_sym_h (&h, &sym, &sec, tls_maskp, locsymsp, r_symndx, ibfd))
+ return 0;
+
+ if ((*tls_maskp != NULL && **tls_maskp != 0)
+ || sec == NULL
+ || ppc64_elf_section_data (sec)->t_symndx == NULL)
+ return 1;
+
+ /* Look inside a TOC section too. */
+ if (h != NULL)
+ {
+ BFD_ASSERT (h->root.type == bfd_link_hash_defined);
+ off = h->root.u.def.value;
+ }
+ else
+ off = sym->st_value;
+ off += rel->r_addend;
+ BFD_ASSERT (off % 8 == 0);
+ r_symndx = ppc64_elf_section_data (sec)->t_symndx[off / 8];
+ next_r = ppc64_elf_section_data (sec)->t_symndx[off / 8 + 1];
+ if (!get_sym_h (&h, &sym, &sec, tls_maskp, locsymsp, r_symndx, ibfd))
+ return 0;
+ if (toc_symndx != NULL)
+ *toc_symndx = r_symndx;
+ if ((h == NULL
+ || ((h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak)
+ && !(h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC)))
+ && (next_r == -1 || next_r == -2))
+ return 1 - next_r;
+ return 1;
+}
+
+/* Adjust all global syms defined in opd sections. In gcc generated
+ code these will already have been done, but I suppose we have to
+ cater for all sorts of hand written assembly. */
+
+static bfd_boolean
+adjust_opd_syms (struct elf_link_hash_entry *h, void *inf ATTRIBUTE_UNUSED)
+{
+ struct ppc_link_hash_entry *eh;
+ asection *sym_sec;
+ long *opd_adjust;
+
+ if (h->root.type == bfd_link_hash_indirect)
+ return TRUE;
+
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ if (h->root.type != bfd_link_hash_defined
+ && h->root.type != bfd_link_hash_defweak)
+ return TRUE;
+
+ eh = (struct ppc_link_hash_entry *) h;
+ if (eh->adjust_done)
+ return TRUE;
+
+ sym_sec = eh->elf.root.u.def.section;
+ if (sym_sec != NULL
+ && elf_section_data (sym_sec) != NULL
+ && (opd_adjust = ppc64_elf_section_data (sym_sec)->opd.adjust) != NULL)
+ {
+ eh->elf.root.u.def.value += opd_adjust[eh->elf.root.u.def.value / 24];
+ eh->adjust_done = 1;
+ }
+ return TRUE;
+}
+
+/* Remove unused Official Procedure Descriptor entries. Currently we
+ only remove those associated with functions in discarded link-once
+ sections, or weakly defined functions that have been overridden. It
+ would be possible to remove many more entries for statically linked
+ applications. */
+
+bfd_boolean
+ppc64_elf_edit_opd (bfd *obfd, struct bfd_link_info *info)
{
bfd *ibfd;
- unsigned int bfd_indx;
+ bfd_boolean some_edited = FALSE;
- for (bfd_indx = 0, ibfd = info->input_bfds;
- ibfd != NULL;
- ibfd = ibfd->link_next, bfd_indx++)
+ for (ibfd = info->input_bfds; ibfd != NULL; ibfd = ibfd->link_next)
{
asection *sec;
Elf_Internal_Rela *relstart, *rel, *relend;
@@ -3560,16 +4962,24 @@ edit_opd (obfd, info)
Elf_Internal_Sym *local_syms;
struct elf_link_hash_entry **sym_hashes;
bfd_vma offset;
+ bfd_size_type amt;
long *adjust;
- boolean need_edit;
+ bfd_boolean need_edit;
sec = bfd_get_section_by_name (ibfd, ".opd");
if (sec == NULL)
continue;
- adjust = (long *) elf_section_data (sec)->tdata;
- BFD_ASSERT (adjust != NULL);
- memset (adjust, 0, (size_t) sec->_raw_size * sizeof (long) / 24);
+ amt = sec->_raw_size * sizeof (long) / 24;
+ adjust = ppc64_elf_section_data (sec)->opd.adjust;
+ if (adjust == NULL)
+ {
+ /* Must be a ld -r link. ie. check_relocs hasn't been
+ called. */
+ adjust = bfd_zalloc (obfd, amt);
+ ppc64_elf_section_data (sec)->opd.adjust = adjust;
+ }
+ memset (adjust, 0, amt);
if (sec->output_section == bfd_abs_section_ptr)
continue;
@@ -3583,20 +4993,19 @@ edit_opd (obfd, info)
sym_hashes = elf_sym_hashes (ibfd);
/* Read the relocations. */
- relstart = _bfd_elf64_link_read_relocs (obfd, sec, (PTR) NULL,
- (Elf_Internal_Rela *) NULL,
- info->keep_memory);
+ relstart = _bfd_elf_link_read_relocs (ibfd, sec, NULL, NULL,
+ info->keep_memory);
if (relstart == NULL)
- return false;
+ return FALSE;
/* First run through the relocs to check they are sane, and to
determine whether we need to edit this opd section. */
- need_edit = false;
+ need_edit = FALSE;
offset = 0;
relend = relstart + sec->reloc_count;
- for (rel = relstart; rel < relend; rel++)
+ for (rel = relstart; rel < relend; )
{
- enum elf_ppc_reloc_type r_type;
+ enum elf_ppc64_reloc_type r_type;
unsigned long r_symndx;
asection *sym_sec;
struct elf_link_hash_entry *h;
@@ -3605,79 +5014,50 @@ edit_opd (obfd, info)
/* .opd contains a regular array of 24 byte entries. We're
only interested in the reloc pointing to a function entry
point. */
- r_type = (enum elf_ppc_reloc_type) ELF64_R_TYPE (rel->r_info);
- if (r_type == R_PPC64_TOC)
- continue;
-
- if (r_type != R_PPC64_ADDR64)
- {
- (*_bfd_error_handler)
- (_("%s: unexpected reloc type %u in .opd section"),
- bfd_archive_filename (ibfd), r_type);
- need_edit = false;
- break;
- }
-
- if (rel + 1 >= relend)
- continue;
- r_type = (enum elf_ppc_reloc_type) ELF64_R_TYPE ((rel + 1)->r_info);
- if (r_type != R_PPC64_TOC)
- continue;
-
- if (rel->r_offset != offset)
+ if (rel->r_offset != offset
+ || rel + 1 >= relend
+ || (rel + 1)->r_offset != offset + 8)
{
/* If someone messes with .opd alignment then after a
"ld -r" we might have padding in the middle of .opd.
Also, there's nothing to prevent someone putting
something silly in .opd with the assembler. No .opd
- optimization for them! */
+ optimization for them! */
(*_bfd_error_handler)
(_("%s: .opd is not a regular array of opd entries"),
bfd_archive_filename (ibfd));
- need_edit = false;
+ need_edit = FALSE;
break;
}
- r_symndx = ELF64_R_SYM (rel->r_info);
- sym_sec = NULL;
- h = NULL;
- sym = NULL;
- if (r_symndx >= symtab_hdr->sh_info)
+ if ((r_type = ELF64_R_TYPE (rel->r_info)) != R_PPC64_ADDR64
+ || (r_type = ELF64_R_TYPE ((rel + 1)->r_info)) != R_PPC64_TOC)
{
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- while (h->root.type == bfd_link_hash_indirect
- || h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
- if (h->root.type == bfd_link_hash_defined
- || h->root.type == bfd_link_hash_defweak)
- sym_sec = h->root.u.def.section;
- }
- else
- {
- if (local_syms == NULL)
- {
- local_syms = (Elf_Internal_Sym *) symtab_hdr->contents;
- if (local_syms == NULL)
- local_syms = bfd_elf_get_elf_syms (ibfd, symtab_hdr,
- symtab_hdr->sh_info, 0,
- NULL, NULL, NULL);
- if (local_syms == NULL)
- goto error_free_rel;
- }
- sym = local_syms + r_symndx;
- if ((sym->st_shndx != SHN_UNDEF
- && sym->st_shndx < SHN_LORESERVE)
- || sym->st_shndx > SHN_HIRESERVE)
- sym_sec = bfd_section_from_elf_index (ibfd, sym->st_shndx);
+ (*_bfd_error_handler)
+ (_("%s: unexpected reloc type %u in .opd section"),
+ bfd_archive_filename (ibfd), r_type);
+ need_edit = FALSE;
+ break;
}
+ r_symndx = ELF64_R_SYM (rel->r_info);
+ if (!get_sym_h (&h, &sym, &sym_sec, NULL, &local_syms,
+ r_symndx, ibfd))
+ goto error_ret;
+
if (sym_sec == NULL || sym_sec->owner == NULL)
{
+ const char *sym_name;
+ if (h != NULL)
+ sym_name = h->root.root.string;
+ else
+ sym_name = bfd_elf_local_sym_name (ibfd, sym);
+
(*_bfd_error_handler)
(_("%s: undefined sym `%s' in .opd section"),
bfd_archive_filename (ibfd),
- h != NULL ? h->root.root.string : "<local symbol>");
- need_edit = false;
+ sym_name);
+ need_edit = FALSE;
break;
}
@@ -3690,16 +5070,21 @@ edit_opd (obfd, info)
which we test for via the output_section. */
if (sym_sec->owner != ibfd
|| sym_sec->output_section == bfd_abs_section_ptr)
- need_edit = true;
+ need_edit = TRUE;
offset += 24;
+ rel += 2;
+ /* Allow for the possibility of a reloc on the third word. */
+ if (rel < relend
+ && rel->r_offset == offset - 8)
+ rel += 1;
}
if (need_edit)
{
Elf_Internal_Rela *write_rel;
bfd_byte *rptr, *wptr;
- boolean skip;
+ bfd_boolean skip;
/* This seems a waste of time as input .opd sections are all
zeros as generated by gcc, but I suppose there's no reason
@@ -3709,16 +5094,16 @@ edit_opd (obfd, info)
{
bfd_byte *loc = bfd_alloc (ibfd, sec->_raw_size);
if (loc == NULL
- || !bfd_get_section_contents (ibfd, sec, loc, (bfd_vma) 0,
+ || !bfd_get_section_contents (ibfd, sec, loc, 0,
sec->_raw_size))
{
+ error_ret:
if (local_syms != NULL
&& symtab_hdr->contents != (unsigned char *) local_syms)
free (local_syms);
- error_free_rel:
if (elf_section_data (sec)->relocs != relstart)
free (relstart);
- return false;
+ return FALSE;
}
sec->contents = loc;
sec->flags |= (SEC_IN_MEMORY | SEC_HAS_CONTENTS);
@@ -3729,40 +5114,26 @@ edit_opd (obfd, info)
wptr = sec->contents;
rptr = sec->contents;
write_rel = relstart;
- skip = false;
+ skip = FALSE;
offset = 0;
for (rel = relstart; rel < relend; rel++)
{
+ unsigned long r_symndx;
+ asection *sym_sec;
+ struct elf_link_hash_entry *h;
+ Elf_Internal_Sym *sym;
+
+ r_symndx = ELF64_R_SYM (rel->r_info);
+ if (!get_sym_h (&h, &sym, &sym_sec, NULL, &local_syms,
+ r_symndx, ibfd))
+ goto error_ret;
+
if (rel->r_offset == offset)
{
- unsigned long r_symndx;
- asection *sym_sec;
- struct elf_link_hash_entry *h;
- Elf_Internal_Sym *sym;
-
- r_symndx = ELF64_R_SYM (rel->r_info);
- sym_sec = NULL;
- h = NULL;
- sym = NULL;
- if (r_symndx >= symtab_hdr->sh_info)
- {
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- while (h->root.type == bfd_link_hash_indirect
- || h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
- if (h->root.type == bfd_link_hash_defined
- || h->root.type == bfd_link_hash_defweak)
- sym_sec = h->root.u.def.section;
- }
- else
- {
- sym = local_syms + r_symndx;
- if ((sym->st_shndx != SHN_UNDEF
- && sym->st_shndx < SHN_LORESERVE)
- || sym->st_shndx > SHN_HIRESERVE)
- sym_sec = bfd_section_from_elf_index (ibfd,
- sym->st_shndx);
- }
+ struct ppc_link_hash_entry *fdh = NULL;
+ if (h != NULL)
+ fdh = get_fdh ((struct ppc_link_hash_entry *) h,
+ ppc_hash_table (info));
skip = (sym_sec->owner != ibfd
|| sym_sec->output_section == bfd_abs_section_ptr);
@@ -3772,14 +5143,8 @@ edit_opd (obfd, info)
{
/* Arrange for the function descriptor sym
to be dropped. */
- struct elf_link_hash_entry *fdh;
- struct ppc_link_hash_entry *fh;
-
- fh = (struct ppc_link_hash_entry *) h;
- BFD_ASSERT (fh->is_func);
- fdh = fh->oh;
- fdh->root.u.def.value = 0;
- fdh->root.u.def.section = sym_sec;
+ fdh->elf.root.u.def.value = 0;
+ fdh->elf.root.u.def.section = sym_sec;
}
}
else
@@ -3788,29 +5153,25 @@ edit_opd (obfd, info)
if (h != NULL)
{
- /* Redefine the function descriptor symbol
- to this location in the opd section.
- We've checked above that opd relocs are
- ordered. */
- struct elf_link_hash_entry *fdh;
- struct ppc_link_hash_entry *fh;
-
- fh = (struct ppc_link_hash_entry *) h;
- BFD_ASSERT (fh->is_func);
- fdh = fh->oh;
- fdh->root.u.def.value = wptr - sec->contents;
- }
- else
- {
- /* Local syms are a bit tricky. We could
- tweak them as they can be cached, but
- we'd need to look through the local syms
- for the function descriptor sym which we
- don't have at the moment. So keep an
- array of adjustments. */
- adjust[rel->r_offset / 24] = wptr - rptr;
+ /* Redefine the function descriptor symbol to
+ this location in the opd section. It is
+ necessary to update the value here rather
+ than using an array of adjustments as we do
+ for local symbols, because various places
+ in the generic ELF code use the value
+ stored in u.def.value. */
+ fdh->elf.root.u.def.value = wptr - sec->contents;
+ fdh->adjust_done = 1;
}
+ /* Local syms are a bit tricky. We could
+ tweak them as they can be cached, but
+ we'd need to look through the local syms
+ for the function descriptor sym which we
+ don't have at the moment. So keep an
+ array of adjustments. */
+ adjust[rel->r_offset / 24] = wptr - rptr;
+
if (wptr != rptr)
memcpy (wptr, rptr, 24);
wptr += 24;
@@ -3819,11 +5180,41 @@ edit_opd (obfd, info)
offset += 24;
}
- /* We need to adjust any reloc offsets to point to the
- new opd entries. While we're at it, we may as well
- remove redundant relocs. */
- if (!skip)
+ if (skip)
{
+ BFD_ASSERT (MUST_BE_DYN_RELOC (ELF64_R_TYPE (rel->r_info)));
+ if (info->shared)
+ {
+ /* We won't be needing dynamic relocs here. */
+ struct ppc_dyn_relocs **pp;
+ struct ppc_dyn_relocs *p;
+
+ if (h != NULL)
+ pp = &((struct ppc_link_hash_entry *) h)->dyn_relocs;
+ else if (sym_sec != NULL)
+ pp = ((struct ppc_dyn_relocs **)
+ &elf_section_data (sym_sec)->local_dynrel);
+ else
+ pp = ((struct ppc_dyn_relocs **)
+ &elf_section_data (sec)->local_dynrel);
+ while ((p = *pp) != NULL)
+ {
+ if (p->sec == sec)
+ {
+ p->count -= 1;
+ if (p->count == 0)
+ *pp = p->next;
+ break;
+ }
+ pp = &p->next;
+ }
+ }
+ }
+ else
+ {
+ /* We need to adjust any reloc offsets to point to the
+ new opd entries. While we're at it, we may as well
+ remove redundant relocs. */
rel->r_offset += wptr - rptr;
if (write_rel != rel)
memcpy (write_rel, rel, sizeof (*rel));
@@ -3833,6 +5224,12 @@ edit_opd (obfd, info)
sec->_cooked_size = wptr - sec->contents;
sec->reloc_count = write_rel - relstart;
+ /* Fudge the size too, as this is used later in
+ elf_bfd_final_link if we are emitting relocs. */
+ elf_section_data (sec)->rel_hdr.sh_size
+ = sec->reloc_count * elf_section_data (sec)->rel_hdr.sh_entsize;
+ BFD_ASSERT (elf_section_data (sec)->rel_hdr2 == NULL);
+ some_edited = TRUE;
}
else if (elf_section_data (sec)->relocs != relstart)
free (relstart);
@@ -3847,36 +5244,351 @@ edit_opd (obfd, info)
}
}
- return true;
+ if (some_edited)
+ elf_link_hash_traverse (elf_hash_table (info), adjust_opd_syms, NULL);
+
+ return TRUE;
+}
+
+/* Set htab->tls_get_addr and call the generic ELF tls_setup function. */
+
+asection *
+ppc64_elf_tls_setup (bfd *obfd, struct bfd_link_info *info)
+{
+ struct ppc_link_hash_table *htab;
+
+ htab = ppc_hash_table (info);
+ if (htab->tls_get_addr != NULL)
+ {
+ struct elf_link_hash_entry *h = htab->tls_get_addr;
+
+ while (h->root.type == bfd_link_hash_indirect
+ || h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ htab->tls_get_addr = h;
+ }
+
+ return _bfd_elf_tls_setup (obfd, info);
+}
+
+/* Run through all the TLS relocs looking for optimization
+ opportunities. The linker has been hacked (see ppc64elf.em) to do
+ a preliminary section layout so that we know the TLS segment
+ offsets. We can't optimize earlier because some optimizations need
+ to know the tp offset, and we need to optimize before allocating
+ dynamic relocations. */
+
+bfd_boolean
+ppc64_elf_tls_optimize (bfd *obfd ATTRIBUTE_UNUSED, struct bfd_link_info *info)
+{
+ bfd *ibfd;
+ asection *sec;
+ struct ppc_link_hash_table *htab;
+
+ if (info->relocatable || info->shared)
+ return TRUE;
+
+ htab = ppc_hash_table (info);
+ for (ibfd = info->input_bfds; ibfd != NULL; ibfd = ibfd->link_next)
+ {
+ Elf_Internal_Sym *locsyms = NULL;
+
+ for (sec = ibfd->sections; sec != NULL; sec = sec->next)
+ if (sec->has_tls_reloc && !bfd_is_abs_section (sec->output_section))
+ {
+ Elf_Internal_Rela *relstart, *rel, *relend;
+ int expecting_tls_get_addr;
+
+ /* Read the relocations. */
+ relstart = _bfd_elf_link_read_relocs (ibfd, sec, NULL, NULL,
+ info->keep_memory);
+ if (relstart == NULL)
+ return FALSE;
+
+ expecting_tls_get_addr = 0;
+ relend = relstart + sec->reloc_count;
+ for (rel = relstart; rel < relend; rel++)
+ {
+ enum elf_ppc64_reloc_type r_type;
+ unsigned long r_symndx;
+ struct elf_link_hash_entry *h;
+ Elf_Internal_Sym *sym;
+ asection *sym_sec;
+ char *tls_mask;
+ char tls_set, tls_clear, tls_type = 0;
+ bfd_vma value;
+ bfd_boolean ok_tprel, is_local;
+
+ r_symndx = ELF64_R_SYM (rel->r_info);
+ if (!get_sym_h (&h, &sym, &sym_sec, &tls_mask, &locsyms,
+ r_symndx, ibfd))
+ {
+ err_free_rel:
+ if (elf_section_data (sec)->relocs != relstart)
+ free (relstart);
+ if (locsyms != NULL
+ && (elf_tdata (ibfd)->symtab_hdr.contents
+ != (unsigned char *) locsyms))
+ free (locsyms);
+ return FALSE;
+ }
+
+ if (h != NULL)
+ {
+ if (h->root.type != bfd_link_hash_defined
+ && h->root.type != bfd_link_hash_defweak)
+ continue;
+ value = h->root.u.def.value;
+ }
+ else
+ {
+ value = sym->st_value;
+
+ if (elf_section_data (sym_sec) != NULL)
+ {
+ long *adjust;
+ adjust = ppc64_elf_section_data (sym_sec)->opd.adjust;
+ if (adjust != NULL)
+ value += adjust[value / 24];
+ }
+ }
+
+ ok_tprel = FALSE;
+ is_local = FALSE;
+ if (h == NULL
+ || !(h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC))
+ {
+ is_local = TRUE;
+ value += sym_sec->output_offset;
+ value += sym_sec->output_section->vma;
+ value -= htab->elf.tls_sec->vma;
+ ok_tprel = (value + TP_OFFSET + ((bfd_vma) 1 << 31)
+ < (bfd_vma) 1 << 32);
+ }
+
+ r_type = ELF64_R_TYPE (rel->r_info);
+ switch (r_type)
+ {
+ case R_PPC64_GOT_TLSLD16:
+ case R_PPC64_GOT_TLSLD16_LO:
+ case R_PPC64_GOT_TLSLD16_HI:
+ case R_PPC64_GOT_TLSLD16_HA:
+ /* These relocs should never be against a symbol
+ defined in a shared lib. Leave them alone if
+ that turns out to be the case. */
+ ppc64_tlsld_got (ibfd)->refcount -= 1;
+ if (!is_local)
+ continue;
+
+ /* LD -> LE */
+ tls_set = 0;
+ tls_clear = TLS_LD;
+ tls_type = TLS_TLS | TLS_LD;
+ expecting_tls_get_addr = 1;
+ break;
+
+ case R_PPC64_GOT_TLSGD16:
+ case R_PPC64_GOT_TLSGD16_LO:
+ case R_PPC64_GOT_TLSGD16_HI:
+ case R_PPC64_GOT_TLSGD16_HA:
+ if (ok_tprel)
+ /* GD -> LE */
+ tls_set = 0;
+ else
+ /* GD -> IE */
+ tls_set = TLS_TLS | TLS_TPRELGD;
+ tls_clear = TLS_GD;
+ tls_type = TLS_TLS | TLS_GD;
+ expecting_tls_get_addr = 1;
+ break;
+
+ case R_PPC64_GOT_TPREL16_DS:
+ case R_PPC64_GOT_TPREL16_LO_DS:
+ case R_PPC64_GOT_TPREL16_HI:
+ case R_PPC64_GOT_TPREL16_HA:
+ expecting_tls_get_addr = 0;
+ if (ok_tprel)
+ {
+ /* IE -> LE */
+ tls_set = 0;
+ tls_clear = TLS_TPREL;
+ tls_type = TLS_TLS | TLS_TPREL;
+ break;
+ }
+ else
+ continue;
+
+ case R_PPC64_REL14:
+ case R_PPC64_REL14_BRTAKEN:
+ case R_PPC64_REL14_BRNTAKEN:
+ case R_PPC64_REL24:
+ if (h != NULL
+ && h == htab->tls_get_addr)
+ {
+ if (!expecting_tls_get_addr
+ && rel != relstart
+ && ((ELF64_R_TYPE (rel[-1].r_info)
+ == R_PPC64_TOC16)
+ || (ELF64_R_TYPE (rel[-1].r_info)
+ == R_PPC64_TOC16_LO)))
+ {
+ /* Check for toc tls entries. */
+ char *toc_tls;
+ int retval;
+
+ retval = get_tls_mask (&toc_tls, NULL, &locsyms,
+ rel - 1, ibfd);
+ if (retval == 0)
+ goto err_free_rel;
+ if (toc_tls != NULL)
+ expecting_tls_get_addr = retval > 1;
+ }
+
+ if (expecting_tls_get_addr)
+ {
+ struct plt_entry *ent;
+ for (ent = h->plt.plist; ent; ent = ent->next)
+ if (ent->addend == 0)
+ {
+ if (ent->plt.refcount > 0)
+ ent->plt.refcount -= 1;
+ break;
+ }
+ }
+ }
+ expecting_tls_get_addr = 0;
+ continue;
+
+ case R_PPC64_TPREL64:
+ expecting_tls_get_addr = 0;
+ if (ok_tprel)
+ {
+ /* IE -> LE */
+ tls_set = TLS_EXPLICIT;
+ tls_clear = TLS_TPREL;
+ break;
+ }
+ else
+ continue;
+
+ case R_PPC64_DTPMOD64:
+ expecting_tls_get_addr = 0;
+ if (rel + 1 < relend
+ && (rel[1].r_info
+ == ELF64_R_INFO (r_symndx, R_PPC64_DTPREL64))
+ && rel[1].r_offset == rel->r_offset + 8)
+ {
+ if (ok_tprel)
+ /* GD -> LE */
+ tls_set = TLS_EXPLICIT | TLS_GD;
+ else
+ /* GD -> IE */
+ tls_set = TLS_EXPLICIT | TLS_GD | TLS_TPRELGD;
+ tls_clear = TLS_GD;
+ }
+ else
+ {
+ if (!is_local)
+ continue;
+
+ /* LD -> LE */
+ tls_set = TLS_EXPLICIT;
+ tls_clear = TLS_LD;
+ }
+ break;
+
+ default:
+ expecting_tls_get_addr = 0;
+ continue;
+ }
+
+ if ((tls_set & TLS_EXPLICIT) == 0)
+ {
+ struct got_entry *ent;
+
+ /* Adjust got entry for this reloc. */
+ if (h != NULL)
+ ent = h->got.glist;
+ else
+ ent = elf_local_got_ents (ibfd)[r_symndx];
+
+ for (; ent != NULL; ent = ent->next)
+ if (ent->addend == rel->r_addend
+ && ent->owner == ibfd
+ && ent->tls_type == tls_type)
+ break;
+ if (ent == NULL)
+ abort ();
+
+ if (tls_set == 0)
+ {
+ /* We managed to get rid of a got entry. */
+ if (ent->got.refcount > 0)
+ ent->got.refcount -= 1;
+ }
+ }
+ else if (h != NULL)
+ {
+ struct ppc_link_hash_entry * eh;
+ struct ppc_dyn_relocs **pp;
+ struct ppc_dyn_relocs *p;
+
+ /* Adjust dynamic relocs. */
+ eh = (struct ppc_link_hash_entry *) h;
+ for (pp = &eh->dyn_relocs;
+ (p = *pp) != NULL;
+ pp = &p->next)
+ if (p->sec == sec)
+ {
+ /* If we got rid of a DTPMOD/DTPREL reloc
+ pair then we'll lose one or two dyn
+ relocs. */
+ if (tls_set == (TLS_EXPLICIT | TLS_GD))
+ p->count -= 1;
+ p->count -= 1;
+ if (p->count == 0)
+ *pp = p->next;
+ break;
+ }
+ }
+
+ *tls_mask |= tls_set;
+ *tls_mask &= ~tls_clear;
+ }
+
+ if (elf_section_data (sec)->relocs != relstart)
+ free (relstart);
+ }
+
+ if (locsyms != NULL
+ && (elf_tdata (ibfd)->symtab_hdr.contents
+ != (unsigned char *) locsyms))
+ {
+ if (!info->keep_memory)
+ free (locsyms);
+ else
+ elf_tdata (ibfd)->symtab_hdr.contents = (unsigned char *) locsyms;
+ }
+ }
+ return TRUE;
}
-
-/* This is the condition under which ppc64_elf_finish_dynamic_symbol
- will be called from elflink.h. If elflink.h doesn't call our
- finish_dynamic_symbol routine, we'll need to do something about
- initializing any .plt and .got entries in ppc64_elf_relocate_section. */
-#define WILL_CALL_FINISH_DYNAMIC_SYMBOL(DYN, INFO, H) \
- ((DYN) \
- && ((INFO)->shared \
- || ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0) \
- && ((H)->dynindx != -1 \
- || ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0))
/* Allocate space in .plt, .got and associated reloc sections for
dynamic relocs. */
-static boolean
-allocate_dynrelocs (h, inf)
- struct elf_link_hash_entry *h;
- PTR inf;
+static bfd_boolean
+allocate_dynrelocs (struct elf_link_hash_entry *h, void *inf)
{
struct bfd_link_info *info;
struct ppc_link_hash_table *htab;
asection *s;
struct ppc_link_hash_entry *eh;
struct ppc_dyn_relocs *p;
+ struct got_entry *gent;
if (h->root.type == bfd_link_hash_indirect)
- return true;
+ return TRUE;
if (h->root.type == bfd_link_hash_warning)
h = (struct elf_link_hash_entry *) h->root.u.i.link;
@@ -3885,75 +5597,122 @@ allocate_dynrelocs (h, inf)
htab = ppc_hash_table (info);
if (htab->elf.dynamic_sections_created
- && h->plt.refcount > 0
- && h->dynindx != -1)
+ && h->dynindx != -1
+ && WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, info->shared, h))
{
- BFD_ASSERT (((struct ppc_link_hash_entry *) h)->is_func_descriptor);
-
- if (WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, info, h))
- {
- /* If this is the first .plt entry, make room for the special
- first entry. */
- s = htab->splt;
- if (s->_raw_size == 0)
- s->_raw_size += PLT_INITIAL_ENTRY_SIZE;
-
- h->plt.offset = s->_raw_size;
-
- /* Make room for this entry. */
- s->_raw_size += PLT_ENTRY_SIZE;
-
- /* Make room for the .glink code. */
- s = htab->sglink;
- if (s->_raw_size == 0)
- s->_raw_size += GLINK_CALL_STUB_SIZE;
- /* We need bigger stubs past index 32767. */
- if (s->_raw_size >= GLINK_CALL_STUB_SIZE + 32768*2*4)
- s->_raw_size += 4;
- s->_raw_size += 2*4;
-
- /* We also need to make an entry in the .rela.plt section. */
- s = htab->srelplt;
- s->_raw_size += sizeof (Elf64_External_Rela);
- }
- else
+ struct plt_entry *pent;
+ bfd_boolean doneone = FALSE;
+ for (pent = h->plt.plist; pent != NULL; pent = pent->next)
+ if (pent->plt.refcount > 0)
+ {
+ BFD_ASSERT (((struct ppc_link_hash_entry *) h)->is_func_descriptor);
+
+ /* If this is the first .plt entry, make room for the special
+ first entry. */
+ s = htab->plt;
+ if (s->_raw_size == 0)
+ s->_raw_size += PLT_INITIAL_ENTRY_SIZE;
+
+ pent->plt.offset = s->_raw_size;
+
+ /* Make room for this entry. */
+ s->_raw_size += PLT_ENTRY_SIZE;
+
+ /* Make room for the .glink code. */
+ s = htab->glink;
+ if (s->_raw_size == 0)
+ s->_raw_size += GLINK_CALL_STUB_SIZE;
+ /* We need bigger stubs past index 32767. */
+ if (s->_raw_size >= GLINK_CALL_STUB_SIZE + 32768*2*4)
+ s->_raw_size += 4;
+ s->_raw_size += 2*4;
+
+ /* We also need to make an entry in the .rela.plt section. */
+ s = htab->relplt;
+ s->_raw_size += sizeof (Elf64_External_Rela);
+ doneone = TRUE;
+ }
+ else
+ pent->plt.offset = (bfd_vma) -1;
+ if (!doneone)
{
- h->plt.offset = (bfd_vma) -1;
+ h->plt.plist = NULL;
h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
}
}
else
{
- h->plt.offset = (bfd_vma) -1;
+ h->plt.plist = NULL;
h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
}
- if (h->got.refcount > 0)
- {
- boolean dyn;
-
- /* Make sure this symbol is output as a dynamic symbol.
- Undefined weak syms won't yet be marked as dynamic. */
- if (h->dynindx == -1
- && (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
+ eh = (struct ppc_link_hash_entry *) h;
+ /* Run through the TLS GD got entries first if we're changing them
+ to TPREL. */
+ if ((eh->tls_mask & TLS_TPRELGD) != 0)
+ for (gent = h->got.glist; gent != NULL; gent = gent->next)
+ if (gent->got.refcount > 0
+ && (gent->tls_type & TLS_GD) != 0)
{
- if (! bfd_elf64_link_record_dynamic_symbol (info, h))
- return false;
+ /* This was a GD entry that has been converted to TPREL. If
+ there happens to be a TPREL entry we can use that one. */
+ struct got_entry *ent;
+ for (ent = h->got.glist; ent != NULL; ent = ent->next)
+ if (ent->got.refcount > 0
+ && (ent->tls_type & TLS_TPREL) != 0
+ && ent->addend == gent->addend
+ && ent->owner == gent->owner)
+ {
+ gent->got.refcount = 0;
+ break;
+ }
+
+ /* If not, then we'll be using our own TPREL entry. */
+ if (gent->got.refcount != 0)
+ gent->tls_type = TLS_TLS | TLS_TPREL;
}
- s = htab->sgot;
- h->got.offset = s->_raw_size;
- s->_raw_size += 8;
- dyn = htab->elf.dynamic_sections_created;
- if (WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info, h))
- htab->srelgot->_raw_size += sizeof (Elf64_External_Rela);
- }
- else
- h->got.offset = (bfd_vma) -1;
+ for (gent = h->got.glist; gent != NULL; gent = gent->next)
+ if (gent->got.refcount > 0)
+ {
+ bfd_boolean dyn;
+
+ /* Make sure this symbol is output as a dynamic symbol.
+ Undefined weak syms won't yet be marked as dynamic,
+ nor will all TLS symbols. */
+ if (h->dynindx == -1
+ && (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
+ }
+
+ if ((gent->tls_type & TLS_LD) != 0
+ && !(h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC))
+ {
+ gent->got.offset = ppc64_tlsld_got (gent->owner)->offset;
+ continue;
+ }
+
+ s = ppc64_elf_tdata (gent->owner)->got;
+ gent->got.offset = s->_raw_size;
+ s->_raw_size
+ += (gent->tls_type & eh->tls_mask & (TLS_GD | TLS_LD)) ? 16 : 8;
+ dyn = htab->elf.dynamic_sections_created;
+ if ((info->shared
+ || WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, 0, h))
+ && (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak))
+ ppc64_elf_tdata (gent->owner)->relgot->_raw_size
+ += (gent->tls_type & eh->tls_mask & TLS_GD
+ ? 2 * sizeof (Elf64_External_Rela)
+ : sizeof (Elf64_External_Rela));
+ }
+ else
+ gent->got.offset = (bfd_vma) -1;
- eh = (struct ppc_link_hash_entry *) h;
if (eh->dyn_relocs == NULL)
- return true;
+ return TRUE;
/* In the shared -Bsymbolic case, discard space allocated for
dynamic pc-relative relocs against symbols which turn out to be
@@ -3963,9 +5722,13 @@ allocate_dynrelocs (h, inf)
if (info->shared)
{
- if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0
- && ((h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0
- || info->symbolic))
+ /* Relocs that use pc_count are those that appear on a call insn,
+ or certain REL relocs (see MUST_BE_DYN_RELOC) that can be
+ generated via assembly. We want calls to protected symbols to
+ resolve directly to the function rather than going via the plt.
+ If people want function pointer comparisons to work as expected
+ then they should avoid writing weird assembly. */
+ if (SYMBOL_CALLS_LOCAL (info, h))
{
struct ppc_dyn_relocs **pp;
@@ -3979,27 +5742,30 @@ allocate_dynrelocs (h, inf)
pp = &p->next;
}
}
+
+ /* Also discard relocs on undefined weak syms with non-default
+ visibility. */
+ if (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+ && h->root.type == bfd_link_hash_undefweak)
+ eh->dyn_relocs = NULL;
}
- else
+ else if (ELIMINATE_COPY_RELOCS)
{
/* For the non-shared case, discard space for relocs against
symbols which turn out to need copy relocs or are not
dynamic. */
if ((h->elf_link_hash_flags & ELF_LINK_NON_GOT_REF) == 0
- && (((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0
- && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
- || (htab->elf.dynamic_sections_created
- && (h->root.type == bfd_link_hash_undefweak
- || h->root.type == bfd_link_hash_undefined))))
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
{
/* Make sure this symbol is output as a dynamic symbol.
Undefined weak syms won't yet be marked as dynamic. */
if (h->dynindx == -1
&& (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
{
- if (! bfd_elf64_link_record_dynamic_symbol (info, h))
- return false;
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
}
/* If that succeeded, we know we'll be keeping all the
@@ -4020,15 +5786,13 @@ allocate_dynrelocs (h, inf)
sreloc->_raw_size += p->count * sizeof (Elf64_External_Rela);
}
- return true;
+ return TRUE;
}
/* Find any dynamic relocs that apply to read-only sections. */
-static boolean
-readonly_dynrelocs (h, inf)
- struct elf_link_hash_entry *h;
- PTR inf;
+static bfd_boolean
+readonly_dynrelocs (struct elf_link_hash_entry *h, void *inf)
{
struct ppc_link_hash_entry *eh;
struct ppc_dyn_relocs *p;
@@ -4043,28 +5807,27 @@ readonly_dynrelocs (h, inf)
if (s != NULL && (s->flags & SEC_READONLY) != 0)
{
- struct bfd_link_info *info = (struct bfd_link_info *) inf;
+ struct bfd_link_info *info = inf;
info->flags |= DF_TEXTREL;
/* Not an error, just cut short the traversal. */
- return false;
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
/* Set the sizes of the dynamic sections. */
-static boolean
-ppc64_elf_size_dynamic_sections (output_bfd, info)
- bfd *output_bfd ATTRIBUTE_UNUSED;
- struct bfd_link_info *info;
+static bfd_boolean
+ppc64_elf_size_dynamic_sections (bfd *output_bfd ATTRIBUTE_UNUSED,
+ struct bfd_link_info *info)
{
struct ppc_link_hash_table *htab;
bfd *dynobj;
asection *s;
- boolean relocs;
+ bfd_boolean relocs;
bfd *ibfd;
htab = ppc_hash_table (info);
@@ -4075,7 +5838,7 @@ ppc64_elf_size_dynamic_sections (output_bfd, info)
if (htab->elf.dynamic_sections_created)
{
/* Set the contents of the .interp section to the interpreter. */
- if (! info->shared)
+ if (info->executable)
{
s = bfd_get_section_by_name (dynobj, ".interp");
if (s == NULL)
@@ -4089,8 +5852,9 @@ ppc64_elf_size_dynamic_sections (output_bfd, info)
relocs. */
for (ibfd = info->input_bfds; ibfd != NULL; ibfd = ibfd->link_next)
{
- bfd_signed_vma *local_got;
- bfd_signed_vma *end_local_got;
+ struct got_entry **lgot_ents;
+ struct got_entry **end_lgot_ents;
+ char *lgot_masks;
bfd_size_type locsymcount;
Elf_Internal_Shdr *symtab_hdr;
asection *srel;
@@ -4098,6 +5862,20 @@ ppc64_elf_size_dynamic_sections (output_bfd, info)
if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour)
continue;
+ if (ppc64_tlsld_got (ibfd)->refcount > 0)
+ {
+ s = ppc64_elf_tdata (ibfd)->got;
+ ppc64_tlsld_got (ibfd)->offset = s->_raw_size;
+ s->_raw_size += 16;
+ if (info->shared)
+ {
+ srel = ppc64_elf_tdata (ibfd)->relgot;
+ srel->_raw_size += sizeof (Elf64_External_Rela);
+ }
+ }
+ else
+ ppc64_tlsld_got (ibfd)->offset = (bfd_vma) -1;
+
for (s = ibfd->sections; s != NULL; s = s->next)
{
struct ppc_dyn_relocs *p;
@@ -4125,50 +5903,78 @@ ppc64_elf_size_dynamic_sections (output_bfd, info)
}
}
- local_got = elf_local_got_refcounts (ibfd);
- if (!local_got)
+ lgot_ents = elf_local_got_ents (ibfd);
+ if (!lgot_ents)
continue;
symtab_hdr = &elf_tdata (ibfd)->symtab_hdr;
locsymcount = symtab_hdr->sh_info;
- end_local_got = local_got + locsymcount;
- s = htab->sgot;
- srel = htab->srelgot;
- for (; local_got < end_local_got; ++local_got)
+ end_lgot_ents = lgot_ents + locsymcount;
+ lgot_masks = (char *) end_lgot_ents;
+ s = ppc64_elf_tdata (ibfd)->got;
+ srel = ppc64_elf_tdata (ibfd)->relgot;
+ for (; lgot_ents < end_lgot_ents; ++lgot_ents, ++lgot_masks)
{
- if (*local_got > 0)
- {
- *local_got = s->_raw_size;
- s->_raw_size += 8;
- if (info->shared)
- srel->_raw_size += sizeof (Elf64_External_Rela);
- }
- else
- *local_got = (bfd_vma) -1;
+ struct got_entry *ent;
+
+ for (ent = *lgot_ents; ent != NULL; ent = ent->next)
+ if (ent->got.refcount > 0)
+ {
+ if ((ent->tls_type & *lgot_masks & TLS_LD) != 0)
+ {
+ if (ppc64_tlsld_got (ibfd)->offset == (bfd_vma) -1)
+ {
+ ppc64_tlsld_got (ibfd)->offset = s->_raw_size;
+ s->_raw_size += 16;
+ if (info->shared)
+ srel->_raw_size += sizeof (Elf64_External_Rela);
+ }
+ ent->got.offset = ppc64_tlsld_got (ibfd)->offset;
+ }
+ else
+ {
+ ent->got.offset = s->_raw_size;
+ if ((ent->tls_type & *lgot_masks & TLS_GD) != 0)
+ {
+ s->_raw_size += 16;
+ if (info->shared)
+ srel->_raw_size += 2 * sizeof (Elf64_External_Rela);
+ }
+ else
+ {
+ s->_raw_size += 8;
+ if (info->shared)
+ srel->_raw_size += sizeof (Elf64_External_Rela);
+ }
+ }
+ }
+ else
+ ent->got.offset = (bfd_vma) -1;
}
}
- if (!edit_opd (output_bfd, info))
- return false;
-
/* Allocate global sym .plt and .got entries, and space for global
sym dynamic relocs. */
- elf_link_hash_traverse (&htab->elf, allocate_dynrelocs, (PTR) info);
+ elf_link_hash_traverse (&htab->elf, allocate_dynrelocs, info);
/* We now have determined the sizes of the various dynamic sections.
Allocate memory for them. */
- relocs = false;
+ relocs = FALSE;
for (s = dynobj->sections; s != NULL; s = s->next)
{
if ((s->flags & SEC_LINKER_CREATED) == 0)
continue;
- if (s == htab->sbrlt || s == htab->srelbrlt)
+ /* Reset _cooked_size since prelim layout will set it wrongly,
+ and a non-zero _cooked_size sticks. */
+ s->_cooked_size = 0;
+
+ if (s == htab->brlt || s == htab->relbrlt)
/* These haven't been allocated yet; don't strip. */
continue;
- else if (s == htab->splt
- || s == htab->sgot
- || s == htab->sglink)
+ else if (s == htab->got
+ || s == htab->plt
+ || s == htab->glink)
{
/* Strip this section if we don't need it; see the
comment below. */
@@ -4189,8 +5995,8 @@ ppc64_elf_size_dynamic_sections (output_bfd, info)
}
else
{
- if (s != htab->srelplt)
- relocs = true;
+ if (s != htab->relplt)
+ relocs = TRUE;
/* We use the reloc_count field as a counter if we need
to copy relocs into the output file. */
@@ -4210,17 +6016,51 @@ ppc64_elf_size_dynamic_sections (output_bfd, info)
}
/* .plt is in the bss section. We don't initialise it. */
- if ((s->flags & SEC_LOAD) == 0)
+ if (s == htab->plt)
continue;
/* Allocate memory for the section contents. We use bfd_zalloc
here in case unused entries are not reclaimed before the
section's contents are written out. This should not happen,
- but this way if it does, we get a R_PPC64_NONE reloc instead
- of garbage. */
- s->contents = (bfd_byte *) bfd_zalloc (dynobj, s->_raw_size);
+ but this way if it does we get a R_PPC64_NONE reloc in .rela
+ sections instead of garbage.
+ We also rely on the section contents being zero when writing
+ the GOT. */
+ s->contents = bfd_zalloc (dynobj, s->_raw_size);
if (s->contents == NULL)
- return false;
+ return FALSE;
+ }
+
+ for (ibfd = info->input_bfds; ibfd != NULL; ibfd = ibfd->link_next)
+ {
+ s = ppc64_elf_tdata (ibfd)->got;
+ if (s != NULL && s != htab->got)
+ {
+ s->_cooked_size = 0;
+ if (s->_raw_size == 0)
+ _bfd_strip_section_from_output (info, s);
+ else
+ {
+ s->contents = bfd_zalloc (ibfd, s->_raw_size);
+ if (s->contents == NULL)
+ return FALSE;
+ }
+ }
+ s = ppc64_elf_tdata (ibfd)->relgot;
+ if (s != NULL)
+ {
+ s->_cooked_size = 0;
+ if (s->_raw_size == 0)
+ _bfd_strip_section_from_output (info, s);
+ else
+ {
+ s->contents = bfd_zalloc (ibfd, s->_raw_size);
+ if (s->contents == NULL)
+ return FALSE;
+ relocs = TRUE;
+ s->reloc_count = 0;
+ }
+ }
}
if (htab->elf.dynamic_sections_created)
@@ -4231,29 +6071,29 @@ ppc64_elf_size_dynamic_sections (output_bfd, info)
the .dynamic section. The DT_DEBUG entry is filled in by the
dynamic linker and used by the debugger. */
#define add_dynamic_entry(TAG, VAL) \
- bfd_elf64_add_dynamic_entry (info, (bfd_vma) (TAG), (bfd_vma) (VAL))
+ _bfd_elf_add_dynamic_entry (info, TAG, VAL)
- if (!info->shared)
+ if (info->executable)
{
if (!add_dynamic_entry (DT_DEBUG, 0))
- return false;
+ return FALSE;
}
- if (htab->splt != NULL && htab->splt->_raw_size != 0)
+ if (htab->plt != NULL && htab->plt->_raw_size != 0)
{
if (!add_dynamic_entry (DT_PLTGOT, 0)
|| !add_dynamic_entry (DT_PLTRELSZ, 0)
|| !add_dynamic_entry (DT_PLTREL, DT_RELA)
|| !add_dynamic_entry (DT_JMPREL, 0)
|| !add_dynamic_entry (DT_PPC64_GLINK, 0))
- return false;
+ return FALSE;
}
if (NO_OPD_RELOCS)
{
if (!add_dynamic_entry (DT_PPC64_OPD, 0)
|| !add_dynamic_entry (DT_PPC64_OPDSZ, 0))
- return false;
+ return FALSE;
}
if (relocs)
@@ -4261,53 +6101,57 @@ ppc64_elf_size_dynamic_sections (output_bfd, info)
if (!add_dynamic_entry (DT_RELA, 0)
|| !add_dynamic_entry (DT_RELASZ, 0)
|| !add_dynamic_entry (DT_RELAENT, sizeof (Elf64_External_Rela)))
- return false;
+ return FALSE;
/* If any dynamic relocs apply to a read-only section,
then we need a DT_TEXTREL entry. */
if ((info->flags & DF_TEXTREL) == 0)
- elf_link_hash_traverse (&htab->elf, readonly_dynrelocs,
- (PTR) info);
+ elf_link_hash_traverse (&htab->elf, readonly_dynrelocs, info);
if ((info->flags & DF_TEXTREL) != 0)
{
if (!add_dynamic_entry (DT_TEXTREL, 0))
- return false;
+ return FALSE;
}
}
}
#undef add_dynamic_entry
- return true;
+ return TRUE;
}
/* Determine the type of stub needed, if any, for a call. */
-static INLINE enum ppc_stub_type
-ppc_type_of_stub (input_sec, rel, hash, destination)
- asection *input_sec;
- const Elf_Internal_Rela *rel;
- struct ppc_link_hash_entry **hash;
- bfd_vma destination;
+static inline enum ppc_stub_type
+ppc_type_of_stub (asection *input_sec,
+ const Elf_Internal_Rela *rel,
+ struct ppc_link_hash_entry **hash,
+ bfd_vma destination)
{
struct ppc_link_hash_entry *h = *hash;
bfd_vma location;
bfd_vma branch_offset;
bfd_vma max_branch_offset;
- unsigned int r_type;
+ enum elf_ppc64_reloc_type r_type;
if (h != NULL)
{
if (h->oh != NULL
- && h->oh->plt.offset != (bfd_vma) -1
&& h->oh->dynindx != -1)
{
- *hash = (struct ppc_link_hash_entry *) h->oh;
- return ppc_stub_plt_call;
+ struct plt_entry *ent;
+ for (ent = h->oh->plt.plist; ent != NULL; ent = ent->next)
+ if (ent->addend == rel->r_addend
+ && ent->plt.offset != (bfd_vma) -1)
+ {
+ *hash = (struct ppc_link_hash_entry *) h->oh;
+ return ppc_stub_plt_call;
+ }
}
- if (h->elf.root.type == bfd_link_hash_undefweak
- || h->elf.root.type == bfd_link_hash_undefined)
+ if (!(h->elf.root.type == bfd_link_hash_defined
+ || h->elf.root.type == bfd_link_hash_defweak)
+ || h->elf.root.u.def.section->output_section == NULL)
return ppc_stub_none;
}
@@ -4321,7 +6165,7 @@ ppc_type_of_stub (input_sec, rel, hash, destination)
/* Determine if a long branch stub is needed. */
max_branch_offset = 1 << 25;
- if (r_type != (unsigned int) R_PPC64_REL24)
+ if (r_type != R_PPC64_REL24)
max_branch_offset = 1 << 15;
if (branch_offset + max_branch_offset >= 2 * max_branch_offset)
@@ -4334,29 +6178,22 @@ ppc_type_of_stub (input_sec, rel, hash, destination)
/* Build a .plt call stub. */
-static bfd_byte *
-build_plt_stub (obfd, p, offset, glink)
- bfd *obfd;
- bfd_byte *p;
- int offset;
- int glink;
+static inline bfd_byte *
+build_plt_stub (bfd *obfd, bfd_byte *p, int offset)
{
#define PPC_LO(v) ((v) & 0xffff)
#define PPC_HI(v) (((v) >> 16) & 0xffff)
#define PPC_HA(v) PPC_HI ((v) + 0x8000)
- if (glink)
- bfd_put_32 (obfd, LD_R2_40R1, p), p += 4;
bfd_put_32 (obfd, ADDIS_R12_R2 | PPC_HA (offset), p), p += 4;
- if (!glink)
- bfd_put_32 (obfd, STD_R2_40R1, p), p += 4;
+ bfd_put_32 (obfd, STD_R2_40R1, p), p += 4;
bfd_put_32 (obfd, LD_R11_0R12 | PPC_LO (offset), p), p += 4;
if (PPC_HA (offset + 8) != PPC_HA (offset))
- bfd_put_32 (obfd, ADDIS_R12_R12_1, p), p += 4;
+ bfd_put_32 (obfd, ADDIS_R12_R12 | 1, p), p += 4;
offset += 8;
bfd_put_32 (obfd, LD_R2_0R12 | PPC_LO (offset), p), p += 4;
if (PPC_HA (offset + 8) != PPC_HA (offset))
- bfd_put_32 (obfd, ADDIS_R12_R12_1, p), p += 4;
+ bfd_put_32 (obfd, ADDIS_R12_R12 | 1, p), p += 4;
offset += 8;
bfd_put_32 (obfd, MTCTR_R11, p), p += 4;
bfd_put_32 (obfd, LD_R11_0R12 | PPC_LO (offset), p), p += 4;
@@ -4364,39 +6201,35 @@ build_plt_stub (obfd, p, offset, glink)
return p;
}
-static boolean
-ppc_build_one_stub (gen_entry, in_arg)
- struct bfd_hash_entry *gen_entry;
- PTR in_arg;
+static bfd_boolean
+ppc_build_one_stub (struct bfd_hash_entry *gen_entry, void *in_arg)
{
struct ppc_stub_hash_entry *stub_entry;
struct ppc_branch_hash_entry *br_entry;
struct bfd_link_info *info;
struct ppc_link_hash_table *htab;
- asection *stub_sec;
- bfd *stub_bfd;
bfd_byte *loc;
bfd_byte *p;
unsigned int indx;
+ struct plt_entry *ent;
bfd_vma off;
int size;
/* Massage our args to the form they really have. */
stub_entry = (struct ppc_stub_hash_entry *) gen_entry;
- info = (struct bfd_link_info *) in_arg;
+ info = in_arg;
htab = ppc_hash_table (info);
- stub_sec = stub_entry->stub_sec;
/* Make a note of the offset within the stubs for this entry. */
- stub_entry->stub_offset = stub_sec->_cooked_size;
- loc = stub_sec->contents + stub_entry->stub_offset;
-
- stub_bfd = stub_sec->owner;
+ stub_entry->stub_offset = stub_entry->stub_sec->_cooked_size;
+ loc = stub_entry->stub_sec->contents + stub_entry->stub_offset;
+ htab->stub_count[stub_entry->stub_type - 1] += 1;
switch (stub_entry->stub_type)
{
case ppc_stub_long_branch:
+ case ppc_stub_long_branch_r2off:
/* Branches are relative. This is where we are going to. */
off = (stub_entry->target_value
+ stub_entry->target_section->output_offset
@@ -4404,73 +6237,113 @@ ppc_build_one_stub (gen_entry, in_arg)
/* And this is where we are coming from. */
off -= (stub_entry->stub_offset
- + stub_sec->output_offset
- + stub_sec->output_section->vma);
+ + stub_entry->stub_sec->output_offset
+ + stub_entry->stub_sec->output_section->vma);
- BFD_ASSERT (off + (1 << 25) < (bfd_vma) (1 << 26));
+ if (stub_entry->stub_type != ppc_stub_long_branch_r2off)
+ size = 4;
+ else
+ {
+ bfd_vma r2off;
+
+ r2off = (htab->stub_group[stub_entry->target_section->id].toc_off
+ - htab->stub_group[stub_entry->id_sec->id].toc_off);
+ bfd_put_32 (htab->stub_bfd, STD_R2_40R1, loc);
+ loc += 4;
+ bfd_put_32 (htab->stub_bfd, ADDIS_R2_R2 | PPC_HA (r2off), loc);
+ loc += 4;
+ bfd_put_32 (htab->stub_bfd, ADDI_R2_R2 | PPC_LO (r2off), loc);
+ loc += 4;
+ off -= 12;
+ size = 16;
+ }
+ bfd_put_32 (htab->stub_bfd, B_DOT | (off & 0x3fffffc), loc);
- bfd_put_32 (stub_bfd, (bfd_vma) B_DOT | (off & 0x3fffffc), loc);
- size = 4;
+ BFD_ASSERT (off + (1 << 25) < (bfd_vma) (1 << 26));
break;
case ppc_stub_plt_branch:
+ case ppc_stub_plt_branch_r2off:
br_entry = ppc_branch_hash_lookup (&htab->branch_hash_table,
stub_entry->root.string + 9,
- false, false);
+ FALSE, FALSE);
if (br_entry == NULL)
{
(*_bfd_error_handler) (_("can't find branch stub `%s'"),
stub_entry->root.string + 9);
- htab->stub_error = true;
- return false;
+ htab->stub_error = TRUE;
+ return FALSE;
}
off = (stub_entry->target_value
+ stub_entry->target_section->output_offset
+ stub_entry->target_section->output_section->vma);
- bfd_put_64 (htab->sbrlt->owner, off,
- htab->sbrlt->contents + br_entry->offset);
+ bfd_put_64 (htab->brlt->owner, off,
+ htab->brlt->contents + br_entry->offset);
if (info->shared)
{
/* Create a reloc for the branch lookup table entry. */
Elf_Internal_Rela rela;
- Elf64_External_Rela *r;
+ bfd_byte *rl;
rela.r_offset = (br_entry->offset
- + htab->sbrlt->output_offset
- + htab->sbrlt->output_section->vma);
+ + htab->brlt->output_offset
+ + htab->brlt->output_section->vma);
rela.r_info = ELF64_R_INFO (0, R_PPC64_RELATIVE);
rela.r_addend = off;
- r = (Elf64_External_Rela *) htab->srelbrlt->contents;
- r += htab->srelbrlt->reloc_count++;
- bfd_elf64_swap_reloca_out (htab->srelbrlt->owner, &rela, r);
+ rl = htab->relbrlt->contents;
+ rl += htab->relbrlt->reloc_count++ * sizeof (Elf64_External_Rela);
+ bfd_elf64_swap_reloca_out (htab->relbrlt->owner, &rela, rl);
}
off = (br_entry->offset
- + htab->sbrlt->output_offset
- + htab->sbrlt->output_section->vma
- - elf_gp (htab->sbrlt->output_section->owner)
- - TOC_BASE_OFF);
+ + htab->brlt->output_offset
+ + htab->brlt->output_section->vma
+ - elf_gp (htab->brlt->output_section->owner)
+ - htab->stub_group[stub_entry->id_sec->id].toc_off);
- if (off + 0x80000000 > 0xffffffff || (off & 7) != 0)
+ if (off + 0x80008000 > 0xffffffff || (off & 7) != 0)
{
(*_bfd_error_handler)
(_("linkage table error against `%s'"),
stub_entry->root.string);
bfd_set_error (bfd_error_bad_value);
- htab->stub_error = true;
- return false;
+ htab->stub_error = TRUE;
+ return FALSE;
}
indx = off;
- bfd_put_32 (stub_bfd, (bfd_vma) ADDIS_R12_R2 | PPC_HA (indx), loc);
- bfd_put_32 (stub_bfd, (bfd_vma) LD_R11_0R12 | PPC_LO (indx), loc + 4);
- bfd_put_32 (stub_bfd, (bfd_vma) MTCTR_R11, loc + 8);
- bfd_put_32 (stub_bfd, (bfd_vma) BCTR, loc + 12);
- size = 16;
+ if (stub_entry->stub_type != ppc_stub_plt_branch_r2off)
+ {
+ bfd_put_32 (htab->stub_bfd, ADDIS_R12_R2 | PPC_HA (indx), loc);
+ loc += 4;
+ bfd_put_32 (htab->stub_bfd, LD_R11_0R12 | PPC_LO (indx), loc);
+ size = 16;
+ }
+ else
+ {
+ bfd_vma r2off;
+
+ r2off = (htab->stub_group[stub_entry->target_section->id].toc_off
+ - htab->stub_group[stub_entry->id_sec->id].toc_off);
+ bfd_put_32 (htab->stub_bfd, STD_R2_40R1, loc);
+ loc += 4;
+ bfd_put_32 (htab->stub_bfd, ADDIS_R12_R2 | PPC_HA (indx), loc);
+ loc += 4;
+ bfd_put_32 (htab->stub_bfd, LD_R11_0R12 | PPC_LO (indx), loc);
+ loc += 4;
+ bfd_put_32 (htab->stub_bfd, ADDIS_R2_R2 | PPC_HA (r2off), loc);
+ loc += 4;
+ bfd_put_32 (htab->stub_bfd, ADDI_R2_R2 | PPC_LO (r2off), loc);
+ size = 28;
+ }
+ loc += 4;
+ bfd_put_32 (htab->stub_bfd, MTCTR_R11, loc);
+ loc += 4;
+ bfd_put_32 (htab->stub_bfd, BCTR, loc);
break;
case ppc_stub_plt_call:
@@ -4482,82 +6355,122 @@ ppc_build_one_stub (gen_entry, in_arg)
{
/* Point the symbol at the stub. There may be multiple stubs,
we don't really care; The main thing is to make this sym
- defined somewhere. */
+ defined somewhere. Maybe defining the symbol in the stub
+ section is a silly idea. If we didn't do this, htab->top_id
+ could disappear. */
stub_entry->h->oh->root.type = bfd_link_hash_defined;
stub_entry->h->oh->root.u.def.section = stub_entry->stub_sec;
stub_entry->h->oh->root.u.def.value = stub_entry->stub_offset;
}
/* Now build the stub. */
- off = stub_entry->h->elf.plt.offset;
+ off = (bfd_vma) -1;
+ for (ent = stub_entry->h->elf.plt.plist; ent != NULL; ent = ent->next)
+ if (ent->addend == stub_entry->addend)
+ {
+ off = ent->plt.offset;
+ break;
+ }
if (off >= (bfd_vma) -2)
abort ();
off &= ~ (bfd_vma) 1;
- off += (htab->splt->output_offset
- + htab->splt->output_section->vma
- - elf_gp (htab->splt->output_section->owner)
- - TOC_BASE_OFF);
+ off += (htab->plt->output_offset
+ + htab->plt->output_section->vma
+ - elf_gp (htab->plt->output_section->owner)
+ - htab->stub_group[stub_entry->id_sec->id].toc_off);
- if (off + 0x80000000 > 0xffffffff || (off & 7) != 0)
+ if (off + 0x80008000 > 0xffffffff || (off & 7) != 0)
{
(*_bfd_error_handler)
(_("linkage table error against `%s'"),
stub_entry->h->elf.root.root.string);
bfd_set_error (bfd_error_bad_value);
- htab->stub_error = true;
- return false;
+ htab->stub_error = TRUE;
+ return FALSE;
}
- p = build_plt_stub (stub_bfd, loc, (int) off, 0);
+ p = build_plt_stub (htab->stub_bfd, loc, off);
size = p - loc;
break;
default:
BFD_FAIL ();
- return false;
+ return FALSE;
+ }
+
+ stub_entry->stub_sec->_cooked_size += size;
+
+ if (htab->emit_stub_syms
+ && !(stub_entry->stub_type == ppc_stub_plt_call
+ && stub_entry->h->oh->root.type == bfd_link_hash_defined
+ && stub_entry->h->oh->root.u.def.section == stub_entry->stub_sec
+ && stub_entry->h->oh->root.u.def.value == stub_entry->stub_offset))
+ {
+ struct elf_link_hash_entry *h;
+ h = elf_link_hash_lookup (&htab->elf, stub_entry->root.string,
+ TRUE, FALSE, FALSE);
+ if (h == NULL)
+ return FALSE;
+ if (h->root.type == bfd_link_hash_new)
+ {
+ h->root.type = bfd_link_hash_defined;
+ h->root.u.def.section = stub_entry->stub_sec;
+ h->root.u.def.value = stub_entry->stub_offset;
+ h->elf_link_hash_flags = (ELF_LINK_HASH_REF_REGULAR
+ | ELF_LINK_HASH_DEF_REGULAR
+ | ELF_LINK_HASH_REF_REGULAR_NONWEAK
+ | ELF_LINK_FORCED_LOCAL);
+ }
}
- stub_sec->_cooked_size += size;
- return true;
+ return TRUE;
}
/* As above, but don't actually build the stub. Just bump offset so
we know stub section sizes, and select plt_branch stubs where
long_branch stubs won't do. */
-static boolean
-ppc_size_one_stub (gen_entry, in_arg)
- struct bfd_hash_entry *gen_entry;
- PTR in_arg;
+static bfd_boolean
+ppc_size_one_stub (struct bfd_hash_entry *gen_entry, void *in_arg)
{
struct ppc_stub_hash_entry *stub_entry;
+ struct bfd_link_info *info;
struct ppc_link_hash_table *htab;
bfd_vma off;
int size;
/* Massage our args to the form they really have. */
stub_entry = (struct ppc_stub_hash_entry *) gen_entry;
- htab = (struct ppc_link_hash_table *) in_arg;
+ info = in_arg;
+
+ htab = ppc_hash_table (info);
if (stub_entry->stub_type == ppc_stub_plt_call)
{
- off = stub_entry->h->elf.plt.offset & ~(bfd_vma) 1;
- off += (htab->splt->output_offset
- + htab->splt->output_section->vma
- - elf_gp (htab->splt->output_section->owner)
- - TOC_BASE_OFF);
-
- size = 28;
- if (PPC_HA ((int) off + 16) != PPC_HA ((int) off))
+ struct plt_entry *ent;
+ off = (bfd_vma) -1;
+ for (ent = stub_entry->h->elf.plt.plist; ent != NULL; ent = ent->next)
+ if (ent->addend == stub_entry->addend)
+ {
+ off = ent->plt.offset & ~(bfd_vma) 1;
+ break;
+ }
+ if (off >= (bfd_vma) -2)
+ abort ();
+ off += (htab->plt->output_offset
+ + htab->plt->output_section->vma
+ - elf_gp (htab->plt->output_section->owner)
+ - htab->stub_group[stub_entry->id_sec->id].toc_off);
+
+ size = PLT_CALL_STUB_SIZE;
+ if (PPC_HA (off + 16) != PPC_HA (off))
size += 4;
}
else
{
- /* ppc_stub_long_branch or ppc_stub_plt_branch. */
- stub_entry->stub_type = ppc_stub_long_branch;
- size = 4;
-
+ /* ppc_stub_long_branch or ppc_stub_plt_branch, or their r2off
+ variants. */
off = (stub_entry->target_value
+ stub_entry->target_section->output_offset
+ stub_entry->target_section->output_section->vma);
@@ -4565,34 +6478,53 @@ ppc_size_one_stub (gen_entry, in_arg)
+ stub_entry->stub_sec->output_offset
+ stub_entry->stub_sec->output_section->vma);
+ /* Reset the stub type from the plt variant in case we now
+ can reach with a shorter stub. */
+ if (stub_entry->stub_type >= ppc_stub_plt_branch)
+ stub_entry->stub_type += ppc_stub_long_branch - ppc_stub_plt_branch;
+
+ size = 4;
+ if (stub_entry->stub_type == ppc_stub_long_branch_r2off)
+ {
+ off -= 12;
+ size = 16;
+ }
+
+ /* If the branch offset if too big, use a ppc_stub_plt_branch. */
if (off + (1 << 25) >= (bfd_vma) (1 << 26))
{
struct ppc_branch_hash_entry *br_entry;
br_entry = ppc_branch_hash_lookup (&htab->branch_hash_table,
stub_entry->root.string + 9,
- true, false);
+ TRUE, FALSE);
if (br_entry == NULL)
{
(*_bfd_error_handler) (_("can't build branch stub `%s'"),
stub_entry->root.string + 9);
- htab->stub_error = true;
- return false;
+ htab->stub_error = TRUE;
+ return FALSE;
}
if (br_entry->iter != htab->stub_iteration)
{
br_entry->iter = htab->stub_iteration;
- br_entry->offset = htab->sbrlt->_raw_size;
- htab->sbrlt->_raw_size += 8;
+ br_entry->offset = htab->brlt->_raw_size;
+ htab->brlt->_raw_size += 8;
+
+ if (info->shared)
+ htab->relbrlt->_raw_size += sizeof (Elf64_External_Rela);
}
- stub_entry->stub_type = ppc_stub_plt_branch;
+
+ stub_entry->stub_type += ppc_stub_plt_branch - ppc_stub_long_branch;
size = 16;
+ if (stub_entry->stub_type != ppc_stub_plt_branch)
+ size = 28;
}
}
stub_entry->stub_sec->_raw_size += size;
- return true;
+ return TRUE;
}
/* Set up various things so that we can make a list of input sections
@@ -4600,23 +6532,20 @@ ppc_size_one_stub (gen_entry, in_arg)
0 when no stubs will be needed, and 1 on success. */
int
-ppc64_elf_setup_section_lists (output_bfd, info)
- bfd *output_bfd;
- struct bfd_link_info *info;
+ppc64_elf_setup_section_lists (bfd *output_bfd, struct bfd_link_info *info)
{
bfd *input_bfd;
- int top_id, top_index;
+ int top_id, top_index, id;
asection *section;
- asection **input_list, **list;
+ asection **input_list;
bfd_size_type amt;
struct ppc_link_hash_table *htab = ppc_hash_table (info);
- if (htab->elf.root.creator->flavour != bfd_target_elf_flavour
- || htab->sbrlt == NULL)
+ if (htab->brlt == NULL)
return 0;
/* Find the top input section id. */
- for (input_bfd = info->input_bfds, top_id = 0;
+ for (input_bfd = info->input_bfds, top_id = 3;
input_bfd != NULL;
input_bfd = input_bfd->link_next)
{
@@ -4629,11 +6558,18 @@ ppc64_elf_setup_section_lists (output_bfd, info)
}
}
+ htab->top_id = top_id;
amt = sizeof (struct map_stub) * (top_id + 1);
- htab->stub_group = (struct map_stub *) bfd_zmalloc (amt);
+ htab->stub_group = bfd_zmalloc (amt);
if (htab->stub_group == NULL)
return -1;
+ /* Set toc_off for com, und, abs and ind sections. */
+ for (id = 0; id < 3; id++)
+ htab->stub_group[id].toc_off = TOC_BASE_OFF;
+
+ elf_gp (output_bfd) = htab->toc_curr = ppc64_elf_toc (output_bfd);
+
/* We can't use output_bfd->section_count here to find the top output
section index as some sections may have been removed, and
_bfd_strip_section_from_output doesn't renumber the indices. */
@@ -4647,27 +6583,114 @@ ppc64_elf_setup_section_lists (output_bfd, info)
htab->top_index = top_index;
amt = sizeof (asection *) * (top_index + 1);
- input_list = (asection **) bfd_malloc (amt);
+ input_list = bfd_zmalloc (amt);
htab->input_list = input_list;
if (input_list == NULL)
return -1;
- /* For sections we aren't interested in, mark their entries with a
- value we can check later. */
- list = input_list + top_index;
- do
- *list = bfd_abs_section_ptr;
- while (list-- != input_list);
+ return 1;
+}
- for (section = output_bfd->sections;
- section != NULL;
- section = section->next)
+/* The linker repeatedly calls this function for each TOC input section
+ and linker generated GOT section. Group input bfds such that the toc
+ within a group is less than 64k in size. Will break with cute linker
+ scripts that play games with dot in the output toc section. */
+
+void
+ppc64_elf_next_toc_section (struct bfd_link_info *info, asection *isec)
+{
+ struct ppc_link_hash_table *htab = ppc_hash_table (info);
+
+ if (!htab->no_multi_toc)
{
- if ((section->flags & SEC_CODE) != 0)
- input_list[section->index] = NULL;
+ bfd_vma addr = isec->output_offset + isec->output_section->vma;
+ bfd_vma off = addr - htab->toc_curr;
+ if (off + isec->_raw_size > 0x10000)
+ {
+ htab->toc_curr = addr;
+ htab->multi_toc_needed = 1;
+ }
+ elf_gp (isec->owner) = (htab->toc_curr
+ - elf_gp (isec->output_section->owner)
+ + TOC_BASE_OFF);
}
+}
- return 1;
+/* Called after the last call to the above function. */
+
+void
+ppc64_elf_reinit_toc (bfd *output_bfd ATTRIBUTE_UNUSED,
+ struct bfd_link_info *info)
+{
+ struct ppc_link_hash_table *htab = ppc_hash_table (info);
+
+ /* toc_curr tracks the TOC offset used for code sections below in
+ ppc64_elf_next_input_section. Start off at 0x8000. */
+ htab->toc_curr = TOC_BASE_OFF;
+}
+
+/* No toc references were found in ISEC. If the code in ISEC makes no
+ calls, then there's no need to use toc adjusting stubs when branching
+ into ISEC. Actually, indirect calls from ISEC are OK as they will
+ load r2. */
+
+static int
+toc_adjusting_stub_needed (struct bfd_link_info *info, asection *isec)
+{
+ bfd_byte *contents;
+ bfd_size_type i;
+ int ret;
+ int branch_ok;
+
+ /* We know none of our code bearing sections will need toc stubs. */
+ if ((isec->flags & SEC_LINKER_CREATED) != 0)
+ return 0;
+
+ if (isec->_raw_size == 0)
+ return 0;
+
+ /* Hack for linux kernel. .fixup contains branches, but only back to
+ the function that hit an exception. */
+ branch_ok = strcmp (isec->name, ".fixup") == 0;
+
+ contents = elf_section_data (isec)->this_hdr.contents;
+ if (contents == NULL)
+ {
+ contents = bfd_malloc (isec->_raw_size);
+ if (contents == NULL)
+ return -1;
+ if (! bfd_get_section_contents (isec->owner, isec, contents,
+ 0, isec->_raw_size))
+ {
+ free (contents);
+ return -1;
+ }
+ if (info->keep_memory)
+ elf_section_data (isec)->this_hdr.contents = contents;
+ }
+
+ /* Code scan, because we don't necessarily have relocs on calls to
+ static functions. */
+ ret = 0;
+ for (i = 0; i < isec->_raw_size; i += 4)
+ {
+ unsigned long insn = bfd_get_32 (isec->owner, contents + i);
+ /* Is this a branch? */
+ if ((insn & (0x3f << 26)) == (18 << 26)
+ /* If branch and link, it's a function call. */
+ && ((insn & 1) != 0
+ /* Sibling calls use a plain branch. I don't know a way
+ of deciding whether a branch is really a sibling call. */
+ || !branch_ok))
+ {
+ ret = 1;
+ break;
+ }
+ }
+
+ if (elf_section_data (isec)->this_hdr.contents != contents)
+ free (contents);
+ return ret;
}
/* The linker repeatedly calls this function for each input section,
@@ -4675,26 +6698,43 @@ ppc64_elf_setup_section_lists (output_bfd, info)
Build lists of input sections to determine groupings between which
we may insert linker stubs. */
-void
-ppc64_elf_next_input_section (info, isec)
- struct bfd_link_info *info;
- asection *isec;
+bfd_boolean
+ppc64_elf_next_input_section (struct bfd_link_info *info, asection *isec)
{
struct ppc_link_hash_table *htab = ppc_hash_table (info);
+ int ret;
- if (isec->output_section->index <= htab->top_index)
+ if ((isec->output_section->flags & SEC_CODE) != 0
+ && isec->output_section->index <= htab->top_index)
{
asection **list = htab->input_list + isec->output_section->index;
- if (*list != bfd_abs_section_ptr)
- {
- /* Steal the link_sec pointer for our list. */
+ /* Steal the link_sec pointer for our list. */
#define PREV_SEC(sec) (htab->stub_group[(sec)->id].link_sec)
- /* This happens to make the list in reverse order,
- which is what we want. */
- PREV_SEC (isec) = *list;
- *list = isec;
- }
+ /* This happens to make the list in reverse order,
+ which is what we want. */
+ PREV_SEC (isec) = *list;
+ *list = isec;
}
+
+ /* If a code section has a function that uses the TOC then we need
+ to use the right TOC (obviously). Also, make sure that .opd gets
+ the correct TOC value for R_PPC64_TOC relocs that don't have or
+ can't find their function symbol (shouldn't ever happen now). */
+ if (isec->has_gp_reloc || (isec->flags & SEC_CODE) == 0)
+ {
+ if (elf_gp (isec->owner) != 0)
+ htab->toc_curr = elf_gp (isec->owner);
+ }
+ else if ((ret = toc_adjusting_stub_needed (info, isec)) < 0)
+ return FALSE;
+ else
+ isec->has_gp_reloc = ret;
+
+ /* Functions that don't use the TOC can belong in any TOC group.
+ Use the last TOC base. This happens to make _init and _fini
+ pasting work. */
+ htab->stub_group[isec->id].toc_off = htab->toc_curr;
+ return TRUE;
}
/* See whether we can group stub sections together. Grouping stub
@@ -4705,31 +6745,34 @@ ppc64_elf_next_input_section (info, isec)
the middle of a function is not a good idea. */
static void
-group_sections (htab, stub_group_size, stubs_always_before_branch)
- struct ppc_link_hash_table *htab;
- bfd_size_type stub_group_size;
- boolean stubs_always_before_branch;
+group_sections (struct ppc_link_hash_table *htab,
+ bfd_size_type stub_group_size,
+ bfd_boolean stubs_always_before_branch)
{
asection **list = htab->input_list + htab->top_index;
do
{
asection *tail = *list;
- if (tail == bfd_abs_section_ptr)
- continue;
while (tail != NULL)
{
asection *curr;
asection *prev;
bfd_size_type total;
+ bfd_boolean big_sec;
+ bfd_vma curr_toc;
curr = tail;
if (tail->_cooked_size)
total = tail->_cooked_size;
else
total = tail->_raw_size;
+ big_sec = total >= stub_group_size;
+ curr_toc = htab->stub_group[tail->id].toc_off;
+
while ((prev = PREV_SEC (curr)) != NULL
&& ((total += curr->output_offset - prev->output_offset)
- < stub_group_size))
+ < stub_group_size)
+ && htab->stub_group[prev->id].toc_off == curr_toc)
curr = prev;
/* OK, the size from the start of CURR to the end is less
@@ -4741,7 +6784,7 @@ group_sections (htab, stub_group_size, stubs_always_before_branch)
section size. That's a little tricky, and this way will
only break if stubs added make the total size more than
2^25, ie. for the default stub_group_size, if stubs total
- more than 2834432 bytes, or over 100000 plt call stubs. */
+ more than 2097152 bytes, or nearly 75000 plt call stubs. */
do
{
prev = PREV_SEC (tail);
@@ -4751,13 +6794,17 @@ group_sections (htab, stub_group_size, stubs_always_before_branch)
while (tail != curr && (tail = prev) != NULL);
/* But wait, there's more! Input sections up to stub_group_size
- bytes before the stub section can be handled by it too. */
- if (!stubs_always_before_branch)
+ bytes before the stub section can be handled by it too.
+ Don't do this if we have a really large section after the
+ stubs, as adding more stubs increases the chance that
+ branches may not reach into the stub section. */
+ if (!stubs_always_before_branch && !big_sec)
{
total = 0;
while (prev != NULL
&& ((total += tail->output_offset - prev->output_offset)
- < stub_group_size))
+ < stub_group_size)
+ && htab->stub_group[prev->id].toc_off == curr_toc)
{
tail = prev;
prev = PREV_SEC (tail);
@@ -4778,22 +6825,18 @@ group_sections (htab, stub_group_size, stubs_always_before_branch)
PC-relative calls to a target that is unreachable with a "bl"
instruction. */
-boolean
-ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
- add_stub_section, layout_sections_again)
- bfd *output_bfd;
- bfd *stub_bfd;
- struct bfd_link_info *info;
- bfd_signed_vma group_size;
- asection * (*add_stub_section) PARAMS ((const char *, asection *));
- void (*layout_sections_again) PARAMS ((void));
+bfd_boolean
+ppc64_elf_size_stubs (bfd *output_bfd,
+ struct bfd_link_info *info,
+ bfd_signed_vma group_size,
+ asection *(*add_stub_section) (const char *, asection *),
+ void (*layout_sections_again) (void))
{
bfd_size_type stub_group_size;
- boolean stubs_always_before_branch;
+ bfd_boolean stubs_always_before_branch;
struct ppc_link_hash_table *htab = ppc_hash_table (info);
/* Stash our params away. */
- htab->stub_bfd = stub_bfd;
htab->add_stub_section = add_stub_section;
htab->layout_sections_again = layout_sections_again;
stubs_always_before_branch = group_size < 0;
@@ -4804,9 +6847,18 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
if (stub_group_size == 1)
{
/* Default values. */
- stub_group_size = 30720000;
- if (htab->has_14bit_branch)
- stub_group_size = 30000;
+ if (stubs_always_before_branch)
+ {
+ stub_group_size = 0x1e00000;
+ if (htab->has_14bit_branch)
+ stub_group_size = 0x7800;
+ }
+ else
+ {
+ stub_group_size = 0x1c00000;
+ if (htab->has_14bit_branch)
+ stub_group_size = 0x7000;
+ }
}
group_sections (htab, stub_group_size, stubs_always_before_branch);
@@ -4816,10 +6868,10 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
bfd *input_bfd;
unsigned int bfd_indx;
asection *stub_sec;
- boolean stub_changed;
+ bfd_boolean stub_changed;
htab->stub_iteration += 1;
- stub_changed = false;
+ stub_changed = FALSE;
for (input_bfd = info->input_bfds, bfd_indx = 0;
input_bfd != NULL;
@@ -4855,9 +6907,8 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
/* Get the relocs. */
internal_relocs
- = _bfd_elf64_link_read_relocs (input_bfd, section, NULL,
- (Elf_Internal_Rela *) NULL,
- info->keep_memory);
+ = _bfd_elf_link_read_relocs (input_bfd, section, NULL, NULL,
+ info->keep_memory);
if (internal_relocs == NULL)
goto error_ret_free_local;
@@ -4866,61 +6917,47 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
irelaend = irela + section->reloc_count;
for (; irela < irelaend; irela++)
{
- unsigned int r_type, r_indx;
+ enum elf_ppc64_reloc_type r_type;
+ unsigned int r_indx;
enum ppc_stub_type stub_type;
struct ppc_stub_hash_entry *stub_entry;
asection *sym_sec;
bfd_vma sym_value;
bfd_vma destination;
struct ppc_link_hash_entry *hash;
+ struct elf_link_hash_entry *h;
+ Elf_Internal_Sym *sym;
char *stub_name;
const asection *id_sec;
r_type = ELF64_R_TYPE (irela->r_info);
r_indx = ELF64_R_SYM (irela->r_info);
- if (r_type >= (unsigned int) R_PPC_max)
+ if (r_type >= R_PPC64_max)
{
bfd_set_error (bfd_error_bad_value);
goto error_ret_free_internal;
}
/* Only look for stubs on branch instructions. */
- if (r_type != (unsigned int) R_PPC64_REL24
- && r_type != (unsigned int) R_PPC64_REL14
- && r_type != (unsigned int) R_PPC64_REL14_BRTAKEN
- && r_type != (unsigned int) R_PPC64_REL14_BRNTAKEN)
+ if (r_type != R_PPC64_REL24
+ && r_type != R_PPC64_REL14
+ && r_type != R_PPC64_REL14_BRTAKEN
+ && r_type != R_PPC64_REL14_BRNTAKEN)
continue;
/* Now determine the call target, its name, value,
section. */
- sym_sec = NULL;
- sym_value = 0;
destination = 0;
- hash = NULL;
- if (r_indx < symtab_hdr->sh_info)
+ if (!get_sym_h (&h, &sym, &sym_sec, NULL, &local_syms,
+ r_indx, input_bfd))
+ goto error_ret_free_internal;
+ hash = (struct ppc_link_hash_entry *) h;
+
+ if (hash == NULL)
{
/* It's a local symbol. */
- Elf_Internal_Sym *sym;
- Elf_Internal_Shdr *hdr;
-
- if (local_syms == NULL)
- {
- local_syms
- = (Elf_Internal_Sym *) symtab_hdr->contents;
- if (local_syms == NULL)
- local_syms
- = bfd_elf_get_elf_syms (input_bfd, symtab_hdr,
- symtab_hdr->sh_info, 0,
- NULL, NULL, NULL);
- if (local_syms == NULL)
- goto error_ret_free_internal;
- }
- sym = local_syms + r_indx;
- hdr = elf_elfsections (input_bfd)[sym->st_shndx];
- sym_sec = hdr->bfd_section;
- if (ELF_ST_TYPE (sym->st_info) != STT_SECTION)
- sym_value = sym->st_value;
+ sym_value = sym->st_value;
destination = (sym_value + irela->r_addend
+ sym_sec->output_offset
+ sym_sec->output_section->vma);
@@ -4928,21 +6965,10 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
else
{
/* It's an external symbol. */
- int e_indx;
-
- e_indx = r_indx - symtab_hdr->sh_info;
- hash = ((struct ppc_link_hash_entry *)
- elf_sym_hashes (input_bfd)[e_indx]);
-
- while (hash->elf.root.type == bfd_link_hash_indirect
- || hash->elf.root.type == bfd_link_hash_warning)
- hash = ((struct ppc_link_hash_entry *)
- hash->elf.root.u.i.link);
-
+ sym_value = 0;
if (hash->elf.root.type == bfd_link_hash_defined
|| hash->elf.root.type == bfd_link_hash_defweak)
{
- sym_sec = hash->elf.root.u.def.section;
sym_value = hash->elf.root.u.def.value;
if (sym_sec->output_section != NULL)
destination = (sym_value + irela->r_addend
@@ -4963,9 +6989,44 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
/* Determine what (if any) linker stub is needed. */
stub_type = ppc_type_of_stub (section, irela, &hash,
destination);
+
+ if (stub_type != ppc_stub_plt_call)
+ {
+ /* Check whether we need a TOC adjusting stub.
+ Since the linker pastes together pieces from
+ different object files when creating the
+ _init and _fini functions, it may be that a
+ call to what looks like a local sym is in
+ fact a call needing a TOC adjustment. */
+ if (sym_sec != NULL
+ && sym_sec->output_section != NULL
+ && (htab->stub_group[sym_sec->id].toc_off
+ != htab->stub_group[section->id].toc_off)
+ && sym_sec->has_gp_reloc
+ && section->has_gp_reloc)
+ stub_type = ppc_stub_long_branch_r2off;
+ }
+
if (stub_type == ppc_stub_none)
continue;
+ /* __tls_get_addr calls might be eliminated. */
+ if (stub_type != ppc_stub_plt_call
+ && hash != NULL
+ && &hash->elf == htab->tls_get_addr
+ && section->has_tls_reloc
+ && irela != internal_relocs)
+ {
+ /* Get tls info. */
+ char *tls_mask;
+
+ if (!get_tls_mask (&tls_mask, NULL, &local_syms,
+ irela - 1, input_bfd))
+ goto error_ret_free_internal;
+ if (*tls_mask != 0)
+ continue;
+ }
+
/* Support for grouping stub sections. */
id_sec = htab->stub_group[section->id].link_sec;
@@ -4975,7 +7036,7 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
goto error_ret_free_internal;
stub_entry = ppc_stub_hash_lookup (&htab->stub_hash_table,
- stub_name, false, false);
+ stub_name, FALSE, FALSE);
if (stub_entry != NULL)
{
/* The proper stub has already been created. */
@@ -4995,14 +7056,15 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
&& (symtab_hdr->contents
!= (unsigned char *) local_syms))
free (local_syms);
- return false;
+ return FALSE;
}
+ stub_entry->stub_type = stub_type;
stub_entry->target_value = sym_value;
stub_entry->target_section = sym_sec;
- stub_entry->stub_type = stub_type;
stub_entry->h = hash;
- stub_changed = true;
+ stub_entry->addend = irela->r_addend;
+ stub_changed = TRUE;
}
/* We're done with the internal relocs, free them. */
@@ -5028,14 +7090,20 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
for (stub_sec = htab->stub_bfd->sections;
stub_sec != NULL;
stub_sec = stub_sec->next)
+ if ((stub_sec->flags & SEC_LINKER_CREATED) == 0)
+ {
+ stub_sec->_raw_size = 0;
+ stub_sec->_cooked_size = 0;
+ }
+ htab->brlt->_raw_size = 0;
+ htab->brlt->_cooked_size = 0;
+ if (info->shared)
{
- stub_sec->_raw_size = 0;
- stub_sec->_cooked_size = 0;
+ htab->relbrlt->_raw_size = 0;
+ htab->relbrlt->_cooked_size = 0;
}
- htab->sbrlt->_raw_size = 0;
- htab->sbrlt->_cooked_size = 0;
- bfd_hash_traverse (&htab->stub_hash_table, ppc_size_one_stub, htab);
+ bfd_hash_traverse (&htab->stub_hash_table, ppc_size_one_stub, info);
/* Ask the linker to do its stuff. */
(*htab->layout_sections_again) ();
@@ -5046,15 +7114,14 @@ ppc64_elf_size_stubs (output_bfd, stub_bfd, info, group_size,
the dynamic symbol table is corrupted since the section symbol
for the stripped section isn't written. */
- return true;
+ return TRUE;
}
/* Called after we have determined section placement. If sections
move, we'll be called again. Provide a value for TOCstart. */
bfd_vma
-ppc64_elf_toc (obfd)
- bfd *obfd;
+ppc64_elf_toc (bfd *obfd)
{
asection *s;
bfd_vma TOCstart;
@@ -5110,79 +7177,141 @@ ppc64_elf_toc (obfd)
The stubs are kept in a hash table attached to the main linker
hash table. This function is called via gldelf64ppc_finish. */
-boolean
-ppc64_elf_build_stubs (info)
- struct bfd_link_info *info;
+bfd_boolean
+ppc64_elf_build_stubs (bfd_boolean emit_stub_syms,
+ struct bfd_link_info *info,
+ char **stats)
{
struct ppc_link_hash_table *htab = ppc_hash_table (info);
asection *stub_sec;
- bfd_vma plt_r2;
bfd_byte *p;
+ int stub_sec_count = 0;
+ htab->emit_stub_syms = emit_stub_syms;
for (stub_sec = htab->stub_bfd->sections;
stub_sec != NULL;
stub_sec = stub_sec->next)
- {
- bfd_size_type size;
+ if ((stub_sec->flags & SEC_LINKER_CREATED) == 0)
+ {
+ bfd_size_type size;
- /* Allocate memory to hold the linker stubs. */
- size = stub_sec->_raw_size;
- if (size != 0)
- {
- stub_sec->contents = (bfd_byte *) bfd_zalloc (htab->stub_bfd, size);
- if (stub_sec->contents == NULL)
- return false;
- }
- stub_sec->_cooked_size = 0;
- }
+ /* Allocate memory to hold the linker stubs. */
+ size = stub_sec->_raw_size;
+ if (size != 0)
+ {
+ stub_sec->contents = bfd_zalloc (htab->stub_bfd, size);
+ if (stub_sec->contents == NULL)
+ return FALSE;
+ }
+ stub_sec->_cooked_size = 0;
+ }
- if (htab->splt != NULL)
+ if (htab->plt != NULL)
{
unsigned int indx;
+ bfd_vma plt0;
/* Build the .glink plt call stub. */
- plt_r2 = (htab->splt->output_offset
- + htab->splt->output_section->vma
- - elf_gp (htab->splt->output_section->owner)
- - TOC_BASE_OFF);
- p = htab->sglink->contents;
- p = build_plt_stub (htab->sglink->owner, p, (int) plt_r2, 1);
- while (p < htab->sglink->contents + GLINK_CALL_STUB_SIZE)
+ plt0 = (htab->plt->output_section->vma
+ + htab->plt->output_offset
+ - (htab->glink->output_section->vma
+ + htab->glink->output_offset
+ + GLINK_CALL_STUB_SIZE));
+ if (plt0 + 0x80008000 > 0xffffffff)
{
- bfd_put_32 (htab->sglink->owner, NOP, p);
- p += 4;
+ (*_bfd_error_handler) (_(".glink and .plt too far apart"));
+ bfd_set_error (bfd_error_bad_value);
+ return FALSE;
}
+ if (htab->emit_stub_syms)
+ {
+ struct elf_link_hash_entry *h;
+ h = elf_link_hash_lookup (&htab->elf, "__glink", TRUE, FALSE, FALSE);
+ if (h == NULL)
+ return FALSE;
+ if (h->root.type == bfd_link_hash_new)
+ {
+ h->root.type = bfd_link_hash_defined;
+ h->root.u.def.section = htab->glink;
+ h->root.u.def.value = 0;
+ h->elf_link_hash_flags = (ELF_LINK_HASH_REF_REGULAR
+ | ELF_LINK_HASH_DEF_REGULAR
+ | ELF_LINK_HASH_REF_REGULAR_NONWEAK
+ | ELF_LINK_FORCED_LOCAL);
+ }
+ }
+ p = htab->glink->contents;
+ bfd_put_32 (htab->glink->owner, MFCTR_R12, p);
+ p += 4;
+ bfd_put_32 (htab->glink->owner, SLDI_R11_R0_3, p);
+ p += 4;
+ bfd_put_32 (htab->glink->owner, ADDIC_R2_R0_32K, p);
+ p += 4;
+ bfd_put_32 (htab->glink->owner, SUB_R12_R12_R11, p);
+ p += 4;
+ bfd_put_32 (htab->glink->owner, SRADI_R2_R2_63, p);
+ p += 4;
+ bfd_put_32 (htab->glink->owner, SLDI_R11_R0_2, p);
+ p += 4;
+ bfd_put_32 (htab->glink->owner, AND_R2_R2_R11, p);
+ p += 4;
+ bfd_put_32 (htab->glink->owner, SUB_R12_R12_R11, p);
+ p += 4;
+ bfd_put_32 (htab->glink->owner, ADD_R12_R12_R2, p);
+ p += 4;
+ bfd_put_32 (htab->glink->owner, ADDIS_R12_R12 | PPC_HA (plt0), p);
+ p += 4;
+ bfd_put_32 (htab->glink->owner, LD_R11_0R12 | PPC_LO (plt0), p);
+ p += 4;
+ bfd_put_32 (htab->glink->owner, ADDI_R12_R12 | PPC_LO (plt0), p);
+ p += 4;
+ bfd_put_32 (htab->glink->owner, LD_R2_0R12 | 8, p);
+ p += 4;
+ bfd_put_32 (htab->glink->owner, MTCTR_R11, p);
+ p += 4;
+ bfd_put_32 (htab->glink->owner, LD_R11_0R12 | 16, p);
+ p += 4;
+ bfd_put_32 (htab->glink->owner, BCTR, p);
+ p += 4;
+
/* Build the .glink lazy link call stubs. */
indx = 0;
- while (p < htab->sglink->contents + htab->sglink->_raw_size)
+ while (p < htab->glink->contents + htab->glink->_raw_size)
{
if (indx < 0x8000)
{
- bfd_put_32 (htab->sglink->owner, LI_R0_0 | indx, p);
+ bfd_put_32 (htab->glink->owner, LI_R0_0 | indx, p);
p += 4;
}
else
{
- bfd_put_32 (htab->sglink->owner, LIS_R0_0 | PPC_HI (indx), p);
+ bfd_put_32 (htab->glink->owner, LIS_R0_0 | PPC_HI (indx), p);
p += 4;
- bfd_put_32 (htab->sglink->owner, ORI_R0_R0_0 | PPC_LO (indx), p);
+ bfd_put_32 (htab->glink->owner, ORI_R0_R0_0 | PPC_LO (indx), p);
p += 4;
}
- bfd_put_32 (htab->sglink->owner,
- B_DOT | ((htab->sglink->contents - p) & 0x3fffffc), p);
+ bfd_put_32 (htab->glink->owner,
+ B_DOT | ((htab->glink->contents - p) & 0x3fffffc), p);
indx++;
p += 4;
}
- htab->sglink->_cooked_size = p - htab->sglink->contents;
+ htab->glink->_cooked_size = p - htab->glink->contents;
}
- if (htab->sbrlt->_raw_size != 0)
+ if (htab->brlt->_raw_size != 0)
+ {
+ htab->brlt->contents = bfd_zalloc (htab->brlt->owner,
+ htab->brlt->_raw_size);
+ if (htab->brlt->contents == NULL)
+ return FALSE;
+ }
+ if (info->shared && htab->relbrlt->_raw_size != 0)
{
- htab->sbrlt->contents = (bfd_byte *) bfd_zalloc (htab->sbrlt->owner,
- htab->sbrlt->_raw_size);
- if (htab->sbrlt->contents == NULL)
- return false;
+ htab->relbrlt->contents = bfd_zalloc (htab->relbrlt->owner,
+ htab->relbrlt->_raw_size);
+ if (htab->relbrlt->contents == NULL)
+ return FALSE;
}
/* Build the stubs as directed by the stub hash table. */
@@ -5191,19 +7320,43 @@ ppc64_elf_build_stubs (info)
for (stub_sec = htab->stub_bfd->sections;
stub_sec != NULL;
stub_sec = stub_sec->next)
- {
- if (stub_sec->_raw_size != stub_sec->_cooked_size)
- break;
- }
+ if ((stub_sec->flags & SEC_LINKER_CREATED) == 0)
+ {
+ stub_sec_count += 1;
+ if (stub_sec->_raw_size != stub_sec->_cooked_size)
+ break;
+ }
if (stub_sec != NULL
- || htab->sglink->_raw_size != htab->sglink->_cooked_size)
+ || htab->glink->_raw_size != htab->glink->_cooked_size)
{
- htab->stub_error = true;
+ htab->stub_error = TRUE;
(*_bfd_error_handler) (_("stubs don't match calculated size"));
}
- return !htab->stub_error;
+ if (htab->stub_error)
+ return FALSE;
+
+ if (stats != NULL)
+ {
+ *stats = bfd_malloc (500);
+ if (*stats == NULL)
+ return FALSE;
+
+ sprintf (*stats, _("linker stubs in %u groups\n"
+ " branch %lu\n"
+ " toc adjust %lu\n"
+ " long branch %lu\n"
+ " long toc adj %lu\n"
+ " plt call %lu"),
+ stub_sec_count,
+ htab->stub_count[ppc_stub_long_branch - 1],
+ htab->stub_count[ppc_stub_long_branch_r2off - 1],
+ htab->stub_count[ppc_stub_plt_branch - 1],
+ htab->stub_count[ppc_stub_plt_branch_r2off - 1],
+ htab->stub_count[ppc_stub_plt_call - 1]);
+ }
+ return TRUE;
}
/* The RELOCATE_SECTION function is called by the ELF backend linker
@@ -5215,7 +7368,7 @@ ppc64_elf_build_stubs (info)
This function is responsible for adjust the section contents as
necessary, and (if using Rela relocs and generating a
- relocateable output file) adjusting the reloc addend as
+ relocatable output file) adjusting the reloc addend as
necessary.
This function does not have to worry about setting the reloc
@@ -5229,56 +7382,55 @@ ppc64_elf_build_stubs (info)
The global hash table entry for the global symbols can be found
via elf_sym_hashes (input_bfd).
- When generating relocateable output, this function must handle
+ When generating relocatable output, this function must handle
STB_LOCAL/STT_SECTION symbols specially. The output symbol is
going to be the section symbol corresponding to the output
section, which means that the addend must be adjusted
accordingly. */
-static boolean
-ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
- contents, relocs, local_syms, local_sections)
- bfd *output_bfd;
- struct bfd_link_info *info;
- bfd *input_bfd;
- asection *input_section;
- bfd_byte *contents;
- Elf_Internal_Rela *relocs;
- Elf_Internal_Sym *local_syms;
- asection **local_sections;
+static bfd_boolean
+ppc64_elf_relocate_section (bfd *output_bfd,
+ struct bfd_link_info *info,
+ bfd *input_bfd,
+ asection *input_section,
+ bfd_byte *contents,
+ Elf_Internal_Rela *relocs,
+ Elf_Internal_Sym *local_syms,
+ asection **local_sections)
{
struct ppc_link_hash_table *htab;
Elf_Internal_Shdr *symtab_hdr;
struct elf_link_hash_entry **sym_hashes;
Elf_Internal_Rela *rel;
Elf_Internal_Rela *relend;
- bfd_vma *local_got_offsets;
+ Elf_Internal_Rela outrel;
+ bfd_byte *loc;
+ struct got_entry **local_got_ents;
bfd_vma TOCstart;
- boolean ret = true;
- boolean is_opd;
+ bfd_boolean ret = TRUE;
+ bfd_boolean is_opd;
/* Disabled until we sort out how ld should choose 'y' vs 'at'. */
- boolean is_power4 = false;
+ bfd_boolean is_power4 = FALSE;
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
/* Initialize howto table if needed. */
if (!ppc64_elf_howto_table[R_PPC64_ADDR32])
ppc_howto_init ();
htab = ppc_hash_table (info);
- local_got_offsets = elf_local_got_offsets (input_bfd);
+ local_got_ents = elf_local_got_ents (input_bfd);
TOCstart = elf_gp (output_bfd);
symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
sym_hashes = elf_sym_hashes (input_bfd);
- is_opd = elf_section_data (input_section)->tdata != NULL;
+ is_opd = ppc64_elf_section_data (input_section)->opd.adjust != NULL;
rel = relocs;
relend = relocs + input_section->reloc_count;
for (; rel < relend; rel++)
{
- enum elf_ppc_reloc_type r_type;
- bfd_vma offset;
+ enum elf_ppc64_reloc_type r_type;
bfd_vma addend;
bfd_reloc_status_type r;
Elf_Internal_Sym *sym;
@@ -5286,96 +7438,420 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
struct elf_link_hash_entry *h;
struct elf_link_hash_entry *fdh;
const char *sym_name;
- unsigned long r_symndx;
+ unsigned long r_symndx, toc_symndx;
+ char tls_mask, tls_gd, tls_type;
+ char sym_type;
bfd_vma relocation;
- boolean unresolved_reloc;
- boolean warned;
- long insn;
+ bfd_boolean unresolved_reloc;
+ bfd_boolean warned;
+ unsigned long insn, mask;
struct ppc_stub_hash_entry *stub_entry;
bfd_vma max_br_offset;
bfd_vma from;
- r_type = (enum elf_ppc_reloc_type) ELF64_R_TYPE (rel->r_info);
+ r_type = ELF64_R_TYPE (rel->r_info);
r_symndx = ELF64_R_SYM (rel->r_info);
- offset = rel->r_offset;
- addend = rel->r_addend;
- r = bfd_reloc_other;
- sym = (Elf_Internal_Sym *) 0;
- sec = (asection *) 0;
- h = (struct elf_link_hash_entry *) 0;
- sym_name = (const char *) 0;
- unresolved_reloc = false;
- warned = false;
-
- if (r_type == R_PPC64_TOC)
- {
- /* Relocation value is TOC base. Symbol is ignored. */
- relocation = TOCstart + TOC_BASE_OFF;
- }
- else if (r_symndx < symtab_hdr->sh_info)
+
+ /* For old style R_PPC64_TOC relocs with a zero symbol, use the
+ symbol of the previous ADDR64 reloc. The symbol gives us the
+ proper TOC base to use. */
+ if (rel->r_info == ELF64_R_INFO (0, R_PPC64_TOC)
+ && rel != relocs
+ && ELF64_R_TYPE (rel[-1].r_info) == R_PPC64_ADDR64
+ && is_opd)
+ r_symndx = ELF64_R_SYM (rel[-1].r_info);
+
+ sym = NULL;
+ sec = NULL;
+ h = NULL;
+ sym_name = NULL;
+ unresolved_reloc = FALSE;
+ warned = FALSE;
+
+ if (r_symndx < symtab_hdr->sh_info)
{
/* It's a local symbol. */
sym = local_syms + r_symndx;
sec = local_sections[r_symndx];
- sym_name = "<local symbol>";
-
- relocation = _bfd_elf_rela_local_sym (output_bfd, sym, sec, rel);
- /* rel may have changed, update our copy of addend. */
- addend = rel->r_addend;
-
+ sym_name = bfd_elf_local_sym_name (input_bfd, sym);
+ sym_type = ELF64_ST_TYPE (sym->st_info);
+ relocation = _bfd_elf_rela_local_sym (output_bfd, sym, &sec, rel);
if (elf_section_data (sec) != NULL)
{
long *opd_sym_adjust;
- opd_sym_adjust = (long *) elf_section_data (sec)->tdata;
- if (opd_sym_adjust != NULL && sym->st_value % 24 == 0)
+ opd_sym_adjust = ppc64_elf_section_data (sec)->opd.adjust;
+ if (opd_sym_adjust != NULL)
relocation += opd_sym_adjust[sym->st_value / 24];
}
}
else
{
- /* It's a global symbol. */
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- while (h->root.type == bfd_link_hash_indirect
- || h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
+ RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
+ r_symndx, symtab_hdr, sym_hashes,
+ h, sec, relocation,
+ unresolved_reloc, warned);
sym_name = h->root.root.string;
- relocation = 0;
- if (h->root.type == bfd_link_hash_defined
+ sym_type = h->type;
+ }
+
+ /* TLS optimizations. Replace instruction sequences and relocs
+ based on information we collected in tls_optimize. We edit
+ RELOCS so that --emit-relocs will output something sensible
+ for the final instruction stream. */
+ tls_mask = 0;
+ tls_gd = 0;
+ toc_symndx = 0;
+ if (IS_PPC64_TLS_RELOC (r_type))
+ {
+ if (h != NULL)
+ tls_mask = ((struct ppc_link_hash_entry *) h)->tls_mask;
+ else if (local_got_ents != NULL)
+ {
+ char *lgot_masks;
+ lgot_masks = (char *) (local_got_ents + symtab_hdr->sh_info);
+ tls_mask = lgot_masks[r_symndx];
+ }
+ if (tls_mask == 0 && r_type == R_PPC64_TLS)
+ {
+ /* Check for toc tls entries. */
+ char *toc_tls;
+
+ if (!get_tls_mask (&toc_tls, &toc_symndx, &local_syms,
+ rel, input_bfd))
+ return FALSE;
+
+ if (toc_tls)
+ tls_mask = *toc_tls;
+ }
+ }
+
+ /* Check that tls relocs are used with tls syms, and non-tls
+ relocs are used with non-tls syms. */
+ if (r_symndx != 0
+ && r_type != R_PPC64_NONE
+ && (h == NULL
+ || h->root.type == bfd_link_hash_defined
|| h->root.type == bfd_link_hash_defweak)
+ && IS_PPC64_TLS_RELOC (r_type) != (sym_type == STT_TLS))
+ {
+ if (r_type == R_PPC64_TLS && tls_mask != 0)
+ /* R_PPC64_TLS is OK against a symbol in the TOC. */
+ ;
+ else
+ (*_bfd_error_handler)
+ (sym_type == STT_TLS
+ ? _("%s(%s+0x%lx): %s used with TLS symbol %s")
+ : _("%s(%s+0x%lx): %s used with non-TLS symbol %s"),
+ bfd_archive_filename (input_bfd),
+ input_section->name,
+ (long) rel->r_offset,
+ ppc64_elf_howto_table[r_type]->name,
+ sym_name);
+ }
+
+ /* Ensure reloc mapping code below stays sane. */
+ if (R_PPC64_TOC16_LO_DS != R_PPC64_TOC16_DS + 1
+ || R_PPC64_TOC16_LO != R_PPC64_TOC16 + 1
+ || (R_PPC64_GOT_TLSLD16 & 3) != (R_PPC64_GOT_TLSGD16 & 3)
+ || (R_PPC64_GOT_TLSLD16_LO & 3) != (R_PPC64_GOT_TLSGD16_LO & 3)
+ || (R_PPC64_GOT_TLSLD16_HI & 3) != (R_PPC64_GOT_TLSGD16_HI & 3)
+ || (R_PPC64_GOT_TLSLD16_HA & 3) != (R_PPC64_GOT_TLSGD16_HA & 3)
+ || (R_PPC64_GOT_TLSLD16 & 3) != (R_PPC64_GOT_TPREL16_DS & 3)
+ || (R_PPC64_GOT_TLSLD16_LO & 3) != (R_PPC64_GOT_TPREL16_LO_DS & 3)
+ || (R_PPC64_GOT_TLSLD16_HI & 3) != (R_PPC64_GOT_TPREL16_HI & 3)
+ || (R_PPC64_GOT_TLSLD16_HA & 3) != (R_PPC64_GOT_TPREL16_HA & 3))
+ abort ();
+
+ switch (r_type)
+ {
+ default:
+ break;
+
+ case R_PPC64_TOC16:
+ case R_PPC64_TOC16_LO:
+ case R_PPC64_TOC16_DS:
+ case R_PPC64_TOC16_LO_DS:
+ {
+ /* Check for toc tls entries. */
+ char *toc_tls;
+ int retval;
+
+ retval = get_tls_mask (&toc_tls, &toc_symndx, &local_syms,
+ rel, input_bfd);
+ if (retval == 0)
+ return FALSE;
+
+ if (toc_tls)
+ {
+ tls_mask = *toc_tls;
+ if (r_type == R_PPC64_TOC16_DS
+ || r_type == R_PPC64_TOC16_LO_DS)
+ {
+ if (tls_mask != 0
+ && (tls_mask & (TLS_DTPREL | TLS_TPREL)) == 0)
+ goto toctprel;
+ }
+ else
+ {
+ /* If we found a GD reloc pair, then we might be
+ doing a GD->IE transition. */
+ if (retval == 2)
+ {
+ tls_gd = TLS_TPRELGD;
+ if (tls_mask != 0 && (tls_mask & TLS_GD) == 0)
+ goto tls_get_addr_check;
+ }
+ else if (retval == 3)
+ {
+ if (tls_mask != 0 && (tls_mask & TLS_LD) == 0)
+ goto tls_get_addr_check;
+ }
+ }
+ }
+ }
+ break;
+
+ case R_PPC64_GOT_TPREL16_DS:
+ case R_PPC64_GOT_TPREL16_LO_DS:
+ if (tls_mask != 0
+ && (tls_mask & TLS_TPREL) == 0)
{
- sec = h->root.u.def.section;
- if (sec->output_section == NULL)
- /* Set a flag that will be cleared later if we find a
- relocation value for this symbol. output_section
- is typically NULL for symbols satisfied by a shared
- library. */
- unresolved_reloc = true;
+ toctprel:
+ insn = bfd_get_32 (output_bfd, contents + rel->r_offset - 2);
+ insn &= 31 << 21;
+ insn |= 0x3c0d0000; /* addis 0,13,0 */
+ bfd_put_32 (output_bfd, insn, contents + rel->r_offset - 2);
+ r_type = R_PPC64_TPREL16_HA;
+ if (toc_symndx != 0)
+ {
+ rel->r_info = ELF64_R_INFO (toc_symndx, r_type);
+ /* We changed the symbol. Start over in order to
+ get h, sym, sec etc. right. */
+ rel--;
+ continue;
+ }
else
- relocation = (h->root.u.def.value
- + sec->output_section->vma
- + sec->output_offset);
+ rel->r_info = ELF64_R_INFO (r_symndx, r_type);
+ }
+ break;
+
+ case R_PPC64_TLS:
+ if (tls_mask != 0
+ && (tls_mask & TLS_TPREL) == 0)
+ {
+ bfd_vma rtra;
+ insn = bfd_get_32 (output_bfd, contents + rel->r_offset);
+ if ((insn & ((0x3f << 26) | (31 << 11)))
+ == ((31 << 26) | (13 << 11)))
+ rtra = insn & ((1 << 26) - (1 << 16));
+ else if ((insn & ((0x3f << 26) | (31 << 16)))
+ == ((31 << 26) | (13 << 16)))
+ rtra = (insn & (31 << 21)) | ((insn & (31 << 11)) << 5);
+ else
+ abort ();
+ if ((insn & ((1 << 11) - (1 << 1))) == 266 << 1)
+ /* add -> addi. */
+ insn = 14 << 26;
+ else if ((insn & (31 << 1)) == 23 << 1
+ && ((insn & (31 << 6)) < 14 << 6
+ || ((insn & (31 << 6)) >= 16 << 6
+ && (insn & (31 << 6)) < 24 << 6)))
+ /* load and store indexed -> dform. */
+ insn = (32 | ((insn >> 6) & 31)) << 26;
+ else if ((insn & (31 << 1)) == 21 << 1
+ && (insn & (0x1a << 6)) == 0)
+ /* ldx, ldux, stdx, stdux -> ld, ldu, std, stdu. */
+ insn = (((58 | ((insn >> 6) & 4)) << 26)
+ | ((insn >> 6) & 1));
+ else if ((insn & (31 << 1)) == 21 << 1
+ && (insn & ((1 << 11) - (1 << 1))) == 341 << 1)
+ /* lwax -> lwa. */
+ insn = (58 << 26) | 2;
+ else
+ abort ();
+ insn |= rtra;
+ bfd_put_32 (output_bfd, insn, contents + rel->r_offset);
+ /* Was PPC64_TLS which sits on insn boundary, now
+ PPC64_TPREL16_LO which is at insn+2. */
+ rel->r_offset += 2;
+ r_type = R_PPC64_TPREL16_LO;
+ if (toc_symndx != 0)
+ {
+ rel->r_info = ELF64_R_INFO (toc_symndx, r_type);
+ /* We changed the symbol. Start over in order to
+ get h, sym, sec etc. right. */
+ rel--;
+ continue;
+ }
+ else
+ rel->r_info = ELF64_R_INFO (r_symndx, r_type);
+ }
+ break;
+
+ case R_PPC64_GOT_TLSGD16_HI:
+ case R_PPC64_GOT_TLSGD16_HA:
+ tls_gd = TLS_TPRELGD;
+ if (tls_mask != 0 && (tls_mask & TLS_GD) == 0)
+ goto tls_gdld_hi;
+ break;
+
+ case R_PPC64_GOT_TLSLD16_HI:
+ case R_PPC64_GOT_TLSLD16_HA:
+ if (tls_mask != 0 && (tls_mask & TLS_LD) == 0)
+ {
+ tls_gdld_hi:
+ if ((tls_mask & tls_gd) != 0)
+ r_type = (((r_type - (R_PPC64_GOT_TLSGD16 & 3)) & 3)
+ + R_PPC64_GOT_TPREL16_DS);
+ else
+ {
+ bfd_put_32 (output_bfd, NOP, contents + rel->r_offset);
+ rel->r_offset -= 2;
+ r_type = R_PPC64_NONE;
+ }
+ rel->r_info = ELF64_R_INFO (r_symndx, r_type);
+ }
+ break;
+
+ case R_PPC64_GOT_TLSGD16:
+ case R_PPC64_GOT_TLSGD16_LO:
+ tls_gd = TLS_TPRELGD;
+ if (tls_mask != 0 && (tls_mask & TLS_GD) == 0)
+ goto tls_get_addr_check;
+ break;
+
+ case R_PPC64_GOT_TLSLD16:
+ case R_PPC64_GOT_TLSLD16_LO:
+ if (tls_mask != 0 && (tls_mask & TLS_LD) == 0)
+ {
+ tls_get_addr_check:
+ if (rel + 1 < relend)
+ {
+ enum elf_ppc64_reloc_type r_type2;
+ unsigned long r_symndx2;
+ struct elf_link_hash_entry *h2;
+ bfd_vma insn1, insn2, insn3;
+ bfd_vma offset;
+
+ /* The next instruction should be a call to
+ __tls_get_addr. Peek at the reloc to be sure. */
+ r_type2 = ELF64_R_TYPE (rel[1].r_info);
+ r_symndx2 = ELF64_R_SYM (rel[1].r_info);
+ if (r_symndx2 < symtab_hdr->sh_info
+ || (r_type2 != R_PPC64_REL14
+ && r_type2 != R_PPC64_REL14_BRTAKEN
+ && r_type2 != R_PPC64_REL14_BRNTAKEN
+ && r_type2 != R_PPC64_REL24))
+ break;
+
+ h2 = sym_hashes[r_symndx2 - symtab_hdr->sh_info];
+ while (h2->root.type == bfd_link_hash_indirect
+ || h2->root.type == bfd_link_hash_warning)
+ h2 = (struct elf_link_hash_entry *) h2->root.u.i.link;
+ if (h2 == NULL || h2 != htab->tls_get_addr)
+ break;
+
+ /* OK, it checks out. Replace the call. */
+ offset = rel[1].r_offset;
+ insn1 = bfd_get_32 (output_bfd,
+ contents + rel->r_offset - 2);
+ insn3 = bfd_get_32 (output_bfd,
+ contents + offset + 4);
+ if ((tls_mask & tls_gd) != 0)
+ {
+ /* IE */
+ insn1 &= (1 << 26) - (1 << 2);
+ insn1 |= 58 << 26; /* ld */
+ insn2 = 0x7c636a14; /* add 3,3,13 */
+ rel[1].r_info = ELF64_R_INFO (r_symndx2, R_PPC64_NONE);
+ if ((tls_mask & TLS_EXPLICIT) == 0)
+ r_type = (((r_type - (R_PPC64_GOT_TLSGD16 & 3)) & 3)
+ + R_PPC64_GOT_TPREL16_DS);
+ else
+ r_type += R_PPC64_TOC16_DS - R_PPC64_TOC16;
+ rel->r_info = ELF64_R_INFO (r_symndx, r_type);
+ }
+ else
+ {
+ /* LE */
+ insn1 = 0x3c6d0000; /* addis 3,13,0 */
+ insn2 = 0x38630000; /* addi 3,3,0 */
+ if (tls_gd == 0)
+ {
+ /* Was an LD reloc. */
+ r_symndx = 0;
+ rel->r_addend = htab->elf.tls_sec->vma + DTP_OFFSET;
+ rel[1].r_addend = htab->elf.tls_sec->vma + DTP_OFFSET;
+ }
+ else if (toc_symndx != 0)
+ r_symndx = toc_symndx;
+ r_type = R_PPC64_TPREL16_HA;
+ rel->r_info = ELF64_R_INFO (r_symndx, r_type);
+ rel[1].r_info = ELF64_R_INFO (r_symndx,
+ R_PPC64_TPREL16_LO);
+ rel[1].r_offset += 2;
+ }
+ if (insn3 == NOP
+ || insn3 == CROR_151515 || insn3 == CROR_313131)
+ {
+ insn3 = insn2;
+ insn2 = NOP;
+ rel[1].r_offset += 4;
+ }
+ bfd_put_32 (output_bfd, insn1, contents + rel->r_offset - 2);
+ bfd_put_32 (output_bfd, insn2, contents + offset);
+ bfd_put_32 (output_bfd, insn3, contents + offset + 4);
+ if (tls_gd == 0 || toc_symndx != 0)
+ {
+ /* We changed the symbol. Start over in order
+ to get h, sym, sec etc. right. */
+ rel--;
+ continue;
+ }
+ }
+ }
+ break;
+
+ case R_PPC64_DTPMOD64:
+ if (rel + 1 < relend
+ && rel[1].r_info == ELF64_R_INFO (r_symndx, R_PPC64_DTPREL64)
+ && rel[1].r_offset == rel->r_offset + 8)
+ {
+ if ((tls_mask & TLS_GD) == 0)
+ {
+ rel[1].r_info = ELF64_R_INFO (r_symndx, R_PPC64_NONE);
+ if ((tls_mask & TLS_TPRELGD) != 0)
+ r_type = R_PPC64_TPREL64;
+ else
+ {
+ bfd_put_64 (output_bfd, 1, contents + rel->r_offset);
+ r_type = R_PPC64_NONE;
+ }
+ rel->r_info = ELF64_R_INFO (r_symndx, r_type);
+ }
}
- else if (h->root.type == bfd_link_hash_undefweak)
- ;
- else if (info->shared
- && (!info->symbolic || info->allow_shlib_undefined)
- && !info->no_undefined
- && ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
- ;
else
{
- if (! ((*info->callbacks->undefined_symbol)
- (info, h->root.root.string, input_bfd, input_section,
- offset, (!info->shared
- || info->no_undefined
- || ELF_ST_VISIBILITY (h->other)))))
- return false;
- warned = true;
+ if ((tls_mask & TLS_LD) == 0)
+ {
+ bfd_put_64 (output_bfd, 1, contents + rel->r_offset);
+ r_type = R_PPC64_NONE;
+ rel->r_info = ELF64_R_INFO (r_symndx, r_type);
+ }
}
+ break;
+
+ case R_PPC64_TPREL64:
+ if ((tls_mask & TLS_TPREL) == 0)
+ {
+ r_type = R_PPC64_NONE;
+ rel->r_info = ELF64_R_INFO (r_symndx, r_type);
+ }
+ break;
}
- /* First handle relocations that tweak non-addend part of insn. */
+ /* Handle other relocations that tweak non-addend part of insn. */
insn = 0;
switch (r_type)
{
@@ -5391,7 +7867,8 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
/* Branch not taken prediction relocations. */
case R_PPC64_ADDR14_BRNTAKEN:
case R_PPC64_REL14_BRNTAKEN:
- insn |= bfd_get_32 (output_bfd, contents + offset) & ~(0x01 << 21);
+ insn |= bfd_get_32 (output_bfd,
+ contents + rel->r_offset) & ~(0x01 << 21);
if (is_power4)
{
/* Set 'a' bit. This is 0b00010 in BO field for branch
@@ -5406,51 +7883,97 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
}
else
{
- from = (offset
+ from = (rel->r_offset
+ input_section->output_offset
+ input_section->output_section->vma);
/* Invert 'y' bit if not the default. */
- if ((bfd_signed_vma) (relocation + addend - from) < 0)
+ if ((bfd_signed_vma) (relocation + rel->r_addend - from) < 0)
insn ^= 0x01 << 21;
}
- bfd_put_32 (output_bfd, (bfd_vma) insn, contents + offset);
+ bfd_put_32 (output_bfd, insn, contents + rel->r_offset);
break;
case R_PPC64_REL24:
- /* A REL24 branching to a linkage function is followed by a
- nop. We replace the nop with a ld in order to restore
- the TOC base pointer. Only calls to shared objects need
- to alter the TOC base. These are recognized by their
- need for a PLT entry. */
- if (h != NULL
- && (fdh = ((struct ppc_link_hash_entry *) h)->oh) != NULL
- && fdh->plt.offset != (bfd_vma) -1
+ /* Calls to functions with a different TOC, such as calls to
+ shared objects, need to alter the TOC pointer. This is
+ done using a linkage stub. A REL24 branching to these
+ linkage stubs needs to be followed by a nop, as the nop
+ will be replaced with an instruction to restore the TOC
+ base pointer. */
+ if (((h != NULL
+ && (fdh = ((struct ppc_link_hash_entry *) h)->oh) != NULL
+ && fdh->plt.plist != NULL)
+ || ((fdh = h, sec) != NULL
+ && sec->output_section != NULL
+ && (htab->stub_group[sec->id].toc_off
+ != htab->stub_group[input_section->id].toc_off)))
&& (stub_entry = ppc_get_stub_entry (input_section, sec, fdh,
- rel, htab)) != NULL)
+ rel, htab)) != NULL
+ && (stub_entry->stub_type == ppc_stub_plt_call
+ || stub_entry->stub_type == ppc_stub_plt_branch_r2off
+ || stub_entry->stub_type == ppc_stub_long_branch_r2off))
{
- boolean can_plt_call = 0;
+ bfd_boolean can_plt_call = 0;
- if (offset + 8 <= input_section->_cooked_size)
+ if (rel->r_offset + 8 <= input_section->_cooked_size)
{
- insn = bfd_get_32 (input_bfd, contents + offset + 4);
+ insn = bfd_get_32 (input_bfd, contents + rel->r_offset + 4);
if (insn == NOP
|| insn == CROR_151515 || insn == CROR_313131)
{
- bfd_put_32 (input_bfd, (bfd_vma) LD_R2_40R1,
- contents + offset + 4);
+ bfd_put_32 (input_bfd, LD_R2_40R1,
+ contents + rel->r_offset + 4);
can_plt_call = 1;
}
}
if (!can_plt_call)
{
- /* If this is a plain branch rather than a branch
- and link, don't require a nop. */
- insn = bfd_get_32 (input_bfd, contents + offset);
- if ((insn & 1) == 0)
- can_plt_call = 1;
+ if (stub_entry->stub_type == ppc_stub_plt_call)
+ {
+ /* If this is a plain branch rather than a branch
+ and link, don't require a nop. */
+ insn = bfd_get_32 (input_bfd, contents + rel->r_offset);
+ if ((insn & 1) == 0)
+ can_plt_call = 1;
+ }
+ else if (h != NULL
+ && strcmp (h->root.root.string,
+ ".__libc_start_main") == 0)
+ {
+ /* Allow crt1 branch to go via a toc adjusting stub. */
+ can_plt_call = 1;
+ }
+ else
+ {
+ if (strcmp (input_section->output_section->name,
+ ".init") == 0
+ || strcmp (input_section->output_section->name,
+ ".fini") == 0)
+ (*_bfd_error_handler)
+ (_("%s(%s+0x%lx): automatic multiple TOCs "
+ "not supported using your crt files; "
+ "recompile with -mminimal-toc or upgrade gcc"),
+ bfd_archive_filename (input_bfd),
+ input_section->name,
+ (long) rel->r_offset);
+ else
+ (*_bfd_error_handler)
+ (_("%s(%s+0x%lx): sibling call optimization to `%s' "
+ "does not allow automatic multiple TOCs; "
+ "recompile with -mminimal-toc or "
+ "-fno-optimize-sibling-calls, "
+ "or make `%s' extern"),
+ bfd_archive_filename (input_bfd),
+ input_section->name,
+ (long) rel->r_offset,
+ sym_name,
+ sym_name);
+ bfd_set_error (bfd_error_bad_value);
+ ret = FALSE;
+ }
}
if (can_plt_call)
@@ -5458,15 +7981,15 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
relocation = (stub_entry->stub_offset
+ stub_entry->stub_sec->output_offset
+ stub_entry->stub_sec->output_section->vma);
- addend = 0;
- unresolved_reloc = false;
+ if (stub_entry->stub_type == ppc_stub_plt_call)
+ unresolved_reloc = FALSE;
}
}
if (h != NULL
&& h->root.type == bfd_link_hash_undefweak
&& relocation == 0
- && addend == 0)
+ && rel->r_addend == 0)
{
/* Tweak calls to undefined weak functions to point at a
blr. We can thus call a weak function without first
@@ -5476,7 +7999,7 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
relocation = (htab->sfpr->_raw_size - 4
+ htab->sfpr->output_offset
+ htab->sfpr->output_section->vma);
- from = (offset
+ from = (rel->r_offset
+ input_section->output_offset
+ input_section->output_section->vma);
@@ -5490,6 +8013,8 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
}
/* Set `addend'. */
+ tls_type = 0;
+ addend = rel->r_addend;
switch (r_type)
{
default:
@@ -5498,116 +8023,211 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
bfd_archive_filename (input_bfd), (int) r_type, sym_name);
bfd_set_error (bfd_error_bad_value);
- ret = false;
+ ret = FALSE;
continue;
case R_PPC64_NONE:
- case R_PPC_GNU_VTINHERIT:
- case R_PPC_GNU_VTENTRY:
+ case R_PPC64_TLS:
+ case R_PPC64_GNU_VTINHERIT:
+ case R_PPC64_GNU_VTENTRY:
continue;
/* GOT16 relocations. Like an ADDR16 using the symbol's
address in the GOT as relocation value instead of the
- symbols value itself. Also, create a GOT entry for the
+ symbol's value itself. Also, create a GOT entry for the
symbol and put the symbol value there. */
+ case R_PPC64_GOT_TLSGD16:
+ case R_PPC64_GOT_TLSGD16_LO:
+ case R_PPC64_GOT_TLSGD16_HI:
+ case R_PPC64_GOT_TLSGD16_HA:
+ tls_type = TLS_TLS | TLS_GD;
+ goto dogot;
+
+ case R_PPC64_GOT_TLSLD16:
+ case R_PPC64_GOT_TLSLD16_LO:
+ case R_PPC64_GOT_TLSLD16_HI:
+ case R_PPC64_GOT_TLSLD16_HA:
+ tls_type = TLS_TLS | TLS_LD;
+ goto dogot;
+
+ case R_PPC64_GOT_TPREL16_DS:
+ case R_PPC64_GOT_TPREL16_LO_DS:
+ case R_PPC64_GOT_TPREL16_HI:
+ case R_PPC64_GOT_TPREL16_HA:
+ tls_type = TLS_TLS | TLS_TPREL;
+ goto dogot;
+
+ case R_PPC64_GOT_DTPREL16_DS:
+ case R_PPC64_GOT_DTPREL16_LO_DS:
+ case R_PPC64_GOT_DTPREL16_HI:
+ case R_PPC64_GOT_DTPREL16_HA:
+ tls_type = TLS_TLS | TLS_DTPREL;
+ goto dogot;
+
case R_PPC64_GOT16:
case R_PPC64_GOT16_LO:
case R_PPC64_GOT16_HI:
case R_PPC64_GOT16_HA:
case R_PPC64_GOT16_DS:
case R_PPC64_GOT16_LO_DS:
+ dogot:
{
/* Relocation is to the entry for this symbol in the global
offset table. */
+ asection *got;
+ bfd_vma *offp;
bfd_vma off;
+ unsigned long indx = 0;
- if (htab->sgot == NULL)
- abort ();
-
- if (h != NULL)
+ if (tls_type == (TLS_TLS | TLS_LD)
+ && (h == NULL
+ || !(h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC)))
+ offp = &ppc64_tlsld_got (input_bfd)->offset;
+ else
{
- boolean dyn;
-
- off = h->got.offset;
- dyn = htab->elf.dynamic_sections_created;
- if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info, h)
- || (info->shared
- && (info->symbolic
- || h->dynindx == -1
- || (h->elf_link_hash_flags
- & ELF_LINK_FORCED_LOCAL))
- && (h->elf_link_hash_flags
- & ELF_LINK_HASH_DEF_REGULAR)))
+ struct got_entry *ent;
+
+ if (h != NULL)
{
- /* This is actually a static link, or it is a
- -Bsymbolic link and the symbol is defined
- locally, or the symbol was forced to be local
- because of a version file. We must initialize
- this entry in the global offset table. Since the
- offset must always be a multiple of 8, we use the
- least significant bit to record whether we have
- initialized it already.
-
- When doing a dynamic link, we create a .rel.got
- relocation entry to initialize the value. This
- is done in the finish_dynamic_symbol routine. */
- if ((off & 1) != 0)
- off &= ~1;
+ bfd_boolean dyn = htab->elf.dynamic_sections_created;
+ if (!WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info->shared, h)
+ || (info->shared
+ && SYMBOL_REFERENCES_LOCAL (info, h)))
+ /* This is actually a static link, or it is a
+ -Bsymbolic link and the symbol is defined
+ locally, or the symbol was forced to be local
+ because of a version file. */
+ ;
else
{
- bfd_put_64 (output_bfd, relocation,
- htab->sgot->contents + off);
- h->got.offset |= 1;
+ indx = h->dynindx;
+ unresolved_reloc = FALSE;
}
+ ent = h->got.glist;
}
else
- unresolved_reloc = false;
+ {
+ if (local_got_ents == NULL)
+ abort ();
+ ent = local_got_ents[r_symndx];
+ }
+
+ for (; ent != NULL; ent = ent->next)
+ if (ent->addend == rel->r_addend
+ && ent->owner == input_bfd
+ && ent->tls_type == tls_type)
+ break;
+ if (ent == NULL)
+ abort ();
+ offp = &ent->got.offset;
}
+
+ got = ppc64_elf_tdata (input_bfd)->got;
+ if (got == NULL)
+ abort ();
+
+ /* The offset must always be a multiple of 8. We use the
+ least significant bit to record whether we have already
+ processed this entry. */
+ off = *offp;
+ if ((off & 1) != 0)
+ off &= ~1;
else
{
- if (local_got_offsets == NULL)
- abort ();
+ /* Generate relocs for the dynamic linker, except in
+ the case of TLSLD where we'll use one entry per
+ module. */
+ asection *relgot = ppc64_elf_tdata (input_bfd)->relgot;
+
+ *offp = off | 1;
+ if ((info->shared || indx != 0)
+ && (h == NULL
+ || ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak))
+ {
+ outrel.r_offset = (got->output_section->vma
+ + got->output_offset
+ + off);
+ outrel.r_addend = rel->r_addend;
+ if (tls_type & (TLS_LD | TLS_GD))
+ {
+ outrel.r_addend = 0;
+ outrel.r_info = ELF64_R_INFO (indx, R_PPC64_DTPMOD64);
+ if (tls_type == (TLS_TLS | TLS_GD))
+ {
+ loc = relgot->contents;
+ loc += (relgot->reloc_count++
+ * sizeof (Elf64_External_Rela));
+ bfd_elf64_swap_reloca_out (output_bfd,
+ &outrel, loc);
+ outrel.r_offset += 8;
+ outrel.r_addend = rel->r_addend;
+ outrel.r_info
+ = ELF64_R_INFO (indx, R_PPC64_DTPREL64);
+ }
+ }
+ else if (tls_type == (TLS_TLS | TLS_DTPREL))
+ outrel.r_info = ELF64_R_INFO (indx, R_PPC64_DTPREL64);
+ else if (tls_type == (TLS_TLS | TLS_TPREL))
+ outrel.r_info = ELF64_R_INFO (indx, R_PPC64_TPREL64);
+ else if (indx == 0)
+ {
+ outrel.r_info = ELF64_R_INFO (indx, R_PPC64_RELATIVE);
- off = local_got_offsets[r_symndx];
+ /* Write the .got section contents for the sake
+ of prelink. */
+ loc = got->contents + off;
+ bfd_put_64 (output_bfd, outrel.r_addend + relocation,
+ loc);
+ }
+ else
+ outrel.r_info = ELF64_R_INFO (indx, R_PPC64_GLOB_DAT);
- /* The offset must always be a multiple of 8. We use
- the least significant bit to record whether we have
- already processed this entry. */
- if ((off & 1) != 0)
- off &= ~1;
+ if (indx == 0 && tls_type != (TLS_TLS | TLS_LD))
+ {
+ outrel.r_addend += relocation;
+ if (tls_type & (TLS_GD | TLS_DTPREL | TLS_TPREL))
+ outrel.r_addend -= htab->elf.tls_sec->vma;
+ }
+ loc = relgot->contents;
+ loc += (relgot->reloc_count++
+ * sizeof (Elf64_External_Rela));
+ bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
+ }
+
+ /* Init the .got section contents here if we're not
+ emitting a reloc. */
else
{
- bfd_put_64 (output_bfd, relocation,
- htab->sgot->contents + off);
-
- if (info->shared)
+ relocation += rel->r_addend;
+ if (tls_type == (TLS_TLS | TLS_LD))
+ relocation = 1;
+ else if (tls_type != 0)
{
- Elf_Internal_Rela outrel;
- Elf64_External_Rela *loc;
-
- /* We need to generate a R_PPC64_RELATIVE reloc
- for the dynamic linker. */
- outrel.r_offset = (htab->sgot->output_section->vma
- + htab->sgot->output_offset
- + off);
- outrel.r_info = ELF64_R_INFO (0, R_PPC64_RELATIVE);
- outrel.r_addend = relocation;
- loc = (Elf64_External_Rela *) htab->srelgot->contents;
- loc += htab->srelgot->reloc_count++;
- bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
+ relocation -= htab->elf.tls_sec->vma + DTP_OFFSET;
+ if (tls_type == (TLS_TLS | TLS_TPREL))
+ relocation += DTP_OFFSET - TP_OFFSET;
+
+ if (tls_type == (TLS_TLS | TLS_GD))
+ {
+ bfd_put_64 (output_bfd, relocation,
+ got->contents + off + 8);
+ relocation = 1;
+ }
}
- local_got_offsets[r_symndx] |= 1;
+ bfd_put_64 (output_bfd, relocation,
+ got->contents + off);
}
}
if (off >= (bfd_vma) -2)
abort ();
- relocation = htab->sgot->output_offset + off;
+ relocation = got->output_offset + off;
/* TOC base (r2) is TOC start plus 0x8000. */
- addend -= TOC_BASE_OFF;
+ addend = -TOC_BASE_OFF;
}
break;
@@ -5624,21 +8244,38 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
if (h == NULL)
break;
- if (h->plt.offset == (bfd_vma) -1
- || htab->splt == NULL)
+ /* It's possible that we didn't make a PLT entry for this
+ symbol. This happens when statically linking PIC code,
+ or when using -Bsymbolic. Go find a match if there is a
+ PLT entry. */
+ if (htab->plt != NULL)
{
- /* We didn't make a PLT entry for this symbol. This
- happens when statically linking PIC code, or when
- using -Bsymbolic. */
- break;
+ struct plt_entry *ent;
+ for (ent = h->plt.plist; ent != NULL; ent = ent->next)
+ if (ent->addend == rel->r_addend
+ && ent->plt.offset != (bfd_vma) -1)
+ {
+ relocation = (htab->plt->output_section->vma
+ + htab->plt->output_offset
+ + ent->plt.offset);
+ unresolved_reloc = FALSE;
+ }
}
-
- relocation = (htab->splt->output_section->vma
- + htab->splt->output_offset
- + h->plt.offset);
- unresolved_reloc = false;
break;
+ case R_PPC64_TOC:
+ /* Relocation value is TOC base. */
+ relocation = TOCstart;
+ if (r_symndx == 0)
+ relocation += htab->stub_group[input_section->id].toc_off;
+ else if (unresolved_reloc)
+ ;
+ else if (sec != NULL && sec->id <= htab->top_id)
+ relocation += htab->stub_group[sec->id].toc_off;
+ else
+ unresolved_reloc = TRUE;
+ goto dodyn2;
+
/* TOC16 relocs. We want the offset relative to the TOC base,
which is the address of the start of the TOC plus 0x8000.
The TOC consists of sections .got, .toc, .tocbss, and .plt,
@@ -5649,7 +8286,7 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
case R_PPC64_TOC16_DS:
case R_PPC64_TOC16_LO_DS:
case R_PPC64_TOC16_HA:
- addend -= TOCstart + TOC_BASE_OFF;
+ addend -= TOCstart + htab->stub_group[input_section->id].toc_off;
break;
/* Relocate against the beginning of the section. */
@@ -5659,7 +8296,7 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
case R_PPC64_SECTOFF_DS:
case R_PPC64_SECTOFF_LO_DS:
case R_PPC64_SECTOFF_HA:
- if (sec != (asection *) 0)
+ if (sec != NULL)
addend -= sec->output_section->vma;
break;
@@ -5669,8 +8306,53 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
case R_PPC64_REL24:
break;
+ case R_PPC64_TPREL16:
+ case R_PPC64_TPREL16_LO:
+ case R_PPC64_TPREL16_HI:
+ case R_PPC64_TPREL16_HA:
+ case R_PPC64_TPREL16_DS:
+ case R_PPC64_TPREL16_LO_DS:
+ case R_PPC64_TPREL16_HIGHER:
+ case R_PPC64_TPREL16_HIGHERA:
+ case R_PPC64_TPREL16_HIGHEST:
+ case R_PPC64_TPREL16_HIGHESTA:
+ addend -= htab->elf.tls_sec->vma + TP_OFFSET;
+ if (info->shared)
+ /* The TPREL16 relocs shouldn't really be used in shared
+ libs as they will result in DT_TEXTREL being set, but
+ support them anyway. */
+ goto dodyn;
+ break;
+
+ case R_PPC64_DTPREL16:
+ case R_PPC64_DTPREL16_LO:
+ case R_PPC64_DTPREL16_HI:
+ case R_PPC64_DTPREL16_HA:
+ case R_PPC64_DTPREL16_DS:
+ case R_PPC64_DTPREL16_LO_DS:
+ case R_PPC64_DTPREL16_HIGHER:
+ case R_PPC64_DTPREL16_HIGHERA:
+ case R_PPC64_DTPREL16_HIGHEST:
+ case R_PPC64_DTPREL16_HIGHESTA:
+ addend -= htab->elf.tls_sec->vma + DTP_OFFSET;
+ break;
+
+ case R_PPC64_DTPMOD64:
+ relocation = 1;
+ addend = 0;
+ goto dodyn;
+
+ case R_PPC64_TPREL64:
+ addend -= htab->elf.tls_sec->vma + TP_OFFSET;
+ goto dodyn;
+
+ case R_PPC64_DTPREL64:
+ addend -= htab->elf.tls_sec->vma + DTP_OFFSET;
+ /* Fall thru */
+
/* Relocations that may need to be propagated if this is a
dynamic object. */
+ case R_PPC64_REL30:
case R_PPC64_REL32:
case R_PPC64_REL64:
case R_PPC64_ADDR14:
@@ -5687,7 +8369,6 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
case R_PPC64_ADDR16_LO:
case R_PPC64_ADDR16_LO_DS:
case R_PPC64_ADDR24:
- case R_PPC64_ADDR30:
case R_PPC64_ADDR32:
case R_PPC64_ADDR64:
case R_PPC64_UADDR16:
@@ -5696,11 +8377,12 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
/* r_symndx will be zero only for relocs against symbols
from removed linkonce sections, or sections discarded by
a linker script. */
+ dodyn:
if (r_symndx == 0)
break;
/* Fall thru. */
- case R_PPC64_TOC:
+ dodyn2:
if ((input_section->flags & SEC_ALLOC) == 0)
break;
@@ -5708,56 +8390,59 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
break;
if ((info->shared
- && (IS_ABSOLUTE_RELOC (r_type)
- || (h != NULL
- && h->dynindx != -1
- && (! info->symbolic
- || (h->elf_link_hash_flags
- & ELF_LINK_HASH_DEF_REGULAR) == 0))))
- || (!info->shared
+ && (h == NULL
+ || ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak)
+ && (MUST_BE_DYN_RELOC (r_type)
+ || !SYMBOL_CALLS_LOCAL (info, h)))
+ || (ELIMINATE_COPY_RELOCS
+ && !info->shared
&& h != NULL
&& h->dynindx != -1
&& (h->elf_link_hash_flags & ELF_LINK_NON_GOT_REF) == 0
- && (((h->elf_link_hash_flags
- & ELF_LINK_HASH_DEF_DYNAMIC) != 0
- && (h->elf_link_hash_flags
- & ELF_LINK_HASH_DEF_REGULAR) == 0)
- || h->root.type == bfd_link_hash_undefweak
- || h->root.type == bfd_link_hash_undefined)))
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0))
{
Elf_Internal_Rela outrel;
- boolean skip, relocate;
+ bfd_boolean skip, relocate;
asection *sreloc;
- Elf64_External_Rela *loc;
+ bfd_byte *loc;
+ bfd_vma out_off;
/* When generating a dynamic object, these relocations
are copied into the output file to be resolved at run
time. */
- skip = false;
- relocate = false;
-
- outrel.r_offset =
- _bfd_elf_section_offset (output_bfd, info, input_section,
- rel->r_offset);
- if (outrel.r_offset == (bfd_vma) -1)
- skip = true;
- else if (outrel.r_offset == (bfd_vma) -2)
- skip = true, relocate = true;
- outrel.r_offset += (input_section->output_section->vma
- + input_section->output_offset);
- outrel.r_addend = addend;
+ skip = FALSE;
+ relocate = FALSE;
+
+ out_off = _bfd_elf_section_offset (output_bfd, info,
+ input_section, rel->r_offset);
+ if (out_off == (bfd_vma) -1)
+ skip = TRUE;
+ else if (out_off == (bfd_vma) -2)
+ skip = TRUE, relocate = TRUE;
+ out_off += (input_section->output_section->vma
+ + input_section->output_offset);
+ outrel.r_offset = out_off;
+ outrel.r_addend = rel->r_addend;
+
+ /* Optimize unaligned reloc use. */
+ if ((r_type == R_PPC64_ADDR64 && (out_off & 7) != 0)
+ || (r_type == R_PPC64_UADDR64 && (out_off & 7) == 0))
+ r_type ^= R_PPC64_ADDR64 ^ R_PPC64_UADDR64;
+ else if ((r_type == R_PPC64_ADDR32 && (out_off & 3) != 0)
+ || (r_type == R_PPC64_UADDR32 && (out_off & 3) == 0))
+ r_type ^= R_PPC64_ADDR32 ^ R_PPC64_UADDR32;
+ else if ((r_type == R_PPC64_ADDR16 && (out_off & 1) != 0)
+ || (r_type == R_PPC64_UADDR16 && (out_off & 1) == 0))
+ r_type ^= R_PPC64_ADDR16 ^ R_PPC64_UADDR16;
if (skip)
memset (&outrel, 0, sizeof outrel);
- else if (h != NULL
- && h->dynindx != -1
+ else if (!SYMBOL_REFERENCES_LOCAL (info, h)
&& !is_opd
- && (!IS_ABSOLUTE_RELOC (r_type)
- || !info->shared
- || !info->symbolic
- || (h->elf_link_hash_flags
- & ELF_LINK_HASH_DEF_REGULAR) == 0))
+ && r_type != R_PPC64_TOC)
outrel.r_info = ELF64_R_INFO (h->dynindx, r_type);
else
{
@@ -5765,7 +8450,6 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
or this is an opd section reloc which must point
at a local function. */
outrel.r_addend += relocation;
- relocate = true;
if (r_type == R_PPC64_ADDR64 || r_type == R_PPC64_TOC)
{
if (is_opd && h != NULL)
@@ -5780,9 +8464,15 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
bug in binutils handling of weak syms.)
In these cases we won't use the opd
entry in this lib. */
- unresolved_reloc = false;
+ unresolved_reloc = FALSE;
}
outrel.r_info = ELF64_R_INFO (0, R_PPC64_RELATIVE);
+
+ /* We need to relocate .opd contents for ld.so.
+ Prelink also wants simple and consistent rules
+ for relocs. This make all RELATIVE relocs have
+ *r_offset equal to r_addend. */
+ relocate = TRUE;
}
else
{
@@ -5793,7 +8483,7 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
else if (sec == NULL || sec->owner == NULL)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
else
{
@@ -5818,15 +8508,35 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
if (sreloc == NULL)
abort ();
- loc = (Elf64_External_Rela *) sreloc->contents;
- loc += sreloc->reloc_count++;
+ loc = sreloc->contents;
+ loc += sreloc->reloc_count++ * sizeof (Elf64_External_Rela);
bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
/* If this reloc is against an external symbol, it will
be computed at runtime, so there's no need to do
- anything now. */
+ anything now. However, for the sake of prelink ensure
+ that the section contents are a known value. */
if (! relocate)
- continue;
+ {
+ unresolved_reloc = FALSE;
+ /* The value chosen here is quite arbitrary as ld.so
+ ignores section contents except for the special
+ case of .opd where the contents might be accessed
+ before relocation. Choose zero, as that won't
+ cause reloc overflow. */
+ relocation = 0;
+ addend = 0;
+ /* Use *r_offset == r_addend for R_PPC64_ADDR64 relocs
+ to improve backward compatibility with older
+ versions of ld. */
+ if (r_type == R_PPC64_ADDR64)
+ addend = outrel.r_addend;
+ /* Adjust pc_relative relocs to have zero in *r_offset. */
+ else if (ppc64_elf_howto_table[r_type]->pc_relative)
+ addend = (input_section->output_section->vma
+ + input_section->output_offset
+ + rel->r_offset);
+ }
}
break;
@@ -5836,7 +8546,7 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
case R_PPC64_RELATIVE:
/* We shouldn't ever see these dynamic relocs in relocatable
files. */
- /* Fall thru */
+ /* Fall through. */
case R_PPC64_PLTGOT16:
case R_PPC64_PLTGOT16_DS:
@@ -5849,12 +8559,12 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
/* These ones haven't been implemented yet. */
(*_bfd_error_handler)
- (_("%s: Relocation %s is not supported for symbol %s."),
+ (_("%s: relocation %s is not supported for symbol %s."),
bfd_archive_filename (input_bfd),
- ppc64_elf_howto_table[(int) r_type]->name, sym_name);
+ ppc64_elf_howto_table[r_type]->name, sym_name);
bfd_set_error (bfd_error_invalid_operation);
- ret = false;
+ ret = FALSE;
continue;
}
@@ -5867,16 +8577,33 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
case R_PPC64_ADDR16_HA:
case R_PPC64_ADDR16_HIGHERA:
case R_PPC64_ADDR16_HIGHESTA:
+ case R_PPC64_GOT16_HA:
+ case R_PPC64_PLTGOT16_HA:
case R_PPC64_PLT16_HA:
case R_PPC64_TOC16_HA:
case R_PPC64_SECTOFF_HA:
+ case R_PPC64_TPREL16_HA:
+ case R_PPC64_DTPREL16_HA:
+ case R_PPC64_GOT_TLSGD16_HA:
+ case R_PPC64_GOT_TLSLD16_HA:
+ case R_PPC64_GOT_TPREL16_HA:
+ case R_PPC64_GOT_DTPREL16_HA:
+ case R_PPC64_TPREL16_HIGHER:
+ case R_PPC64_TPREL16_HIGHERA:
+ case R_PPC64_TPREL16_HIGHEST:
+ case R_PPC64_TPREL16_HIGHESTA:
+ case R_PPC64_DTPREL16_HIGHER:
+ case R_PPC64_DTPREL16_HIGHERA:
+ case R_PPC64_DTPREL16_HIGHEST:
+ case R_PPC64_DTPREL16_HIGHESTA:
/* It's just possible that this symbol is a weak symbol
that's not actually defined anywhere. In that case,
'sec' would be NULL, and we should leave the symbol
alone (it will be set to zero elsewhere in the link). */
if (sec != NULL)
- /* Add 0x10000 if sign bit in 0:15 is set. */
- addend += ((relocation + addend) & 0x8000) << 1;
+ /* Add 0x10000 if sign bit in 0:15 is set.
+ Bits 0:15 are not used. */
+ addend += 0x8000;
break;
case R_PPC64_ADDR16_DS:
@@ -5890,14 +8617,33 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
case R_PPC64_TOC16_LO_DS:
case R_PPC64_PLTGOT16_DS:
case R_PPC64_PLTGOT16_LO_DS:
- if (((relocation + addend) & 3) != 0)
+ case R_PPC64_GOT_TPREL16_DS:
+ case R_PPC64_GOT_TPREL16_LO_DS:
+ case R_PPC64_GOT_DTPREL16_DS:
+ case R_PPC64_GOT_DTPREL16_LO_DS:
+ case R_PPC64_TPREL16_DS:
+ case R_PPC64_TPREL16_LO_DS:
+ case R_PPC64_DTPREL16_DS:
+ case R_PPC64_DTPREL16_LO_DS:
+ insn = bfd_get_32 (input_bfd, contents + (rel->r_offset & ~3));
+ mask = 3;
+ /* If this reloc is against an lq insn, then the value must be
+ a multiple of 16. This is somewhat of a hack, but the
+ "correct" way to do this by defining _DQ forms of all the
+ _DS relocs bloats all reloc switches in this file. It
+ doesn't seem to make much sense to use any of these relocs
+ in data, so testing the insn should be safe. */
+ if ((insn & (0x3f << 26)) == (56u << 26))
+ mask = 15;
+ if (((relocation + addend) & mask) != 0)
{
(*_bfd_error_handler)
- (_("%s: error: relocation %s not a multiple of 4"),
+ (_("%s: error: relocation %s not a multiple of %d"),
bfd_archive_filename (input_bfd),
- ppc64_elf_howto_table[(int) r_type]->name);
+ ppc64_elf_howto_table[r_type]->name,
+ mask + 1);
bfd_set_error (bfd_error_bad_value);
- ret = false;
+ ret = FALSE;
continue;
}
break;
@@ -5912,12 +8658,18 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
max_br_offset = 1 << 25;
branch_check:
- /* If the branch is out of reach, then redirect the
- call to the local stub for this function. */
- from = (offset
+ /* If the branch is out of reach or the TOC register needs
+ adjusting, then redirect the call to the local stub for
+ this function. */
+ from = (rel->r_offset
+ input_section->output_offset
+ input_section->output_section->vma);
- if (relocation + addend - from + max_br_offset >= 2 * max_br_offset
+ if ((relocation + addend - from + max_br_offset >= 2 * max_br_offset
+ || (sec != NULL
+ && sec->output_section != NULL
+ && sec->id <= htab->top_id
+ && (htab->stub_group[sec->id].toc_off
+ != htab->stub_group[input_section->id].toc_off)))
&& (stub_entry = ppc_get_stub_entry (input_section, sec, h,
rel, htab)) != NULL)
{
@@ -5939,30 +8691,34 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
&& (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0))
{
(*_bfd_error_handler)
- (_("%s(%s+0x%lx): unresolvable relocation against symbol `%s'"),
+ (_("%s(%s+0x%lx): unresolvable %s relocation against symbol `%s'"),
bfd_archive_filename (input_bfd),
bfd_get_section_name (input_bfd, input_section),
(long) rel->r_offset,
+ ppc64_elf_howto_table[(int) r_type]->name,
h->root.root.string);
- ret = false;
+ ret = FALSE;
}
r = _bfd_final_link_relocate (ppc64_elf_howto_table[(int) r_type],
input_bfd,
input_section,
contents,
- offset,
+ rel->r_offset,
relocation,
addend);
if (r != bfd_reloc_ok)
{
- const char *name;
-
- if (h != NULL)
+ if (sym_name == NULL)
+ sym_name = "(null)";
+ if (r == bfd_reloc_overflow)
{
- if (h->root.type == bfd_link_hash_undefweak
- && ppc64_elf_howto_table[(int) r_type]->pc_relative)
+ if (warned)
+ continue;
+ if (h != NULL
+ && h->root.type == bfd_link_hash_undefweak
+ && ppc64_elf_howto_table[r_type]->pc_relative)
{
/* Assume this is a call protected by other code that
detects the symbol is undefined. If this is the case,
@@ -5973,36 +8729,22 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
continue;
}
- name = h->root.root.string;
- }
- else
- {
- name = bfd_elf_string_from_elf_section (input_bfd,
- symtab_hdr->sh_link,
- sym->st_name);
- if (name == NULL)
- continue;
- if (*name == '\0')
- name = bfd_section_name (input_bfd, sec);
- }
-
- if (r == bfd_reloc_overflow)
- {
- if (warned)
- continue;
if (!((*info->callbacks->reloc_overflow)
- (info, name, ppc64_elf_howto_table[(int) r_type]->name,
- rel->r_addend, input_bfd, input_section, offset)))
- return false;
+ (info, sym_name, ppc64_elf_howto_table[r_type]->name,
+ rel->r_addend, input_bfd, input_section, rel->r_offset)))
+ return FALSE;
}
else
{
(*_bfd_error_handler)
- (_("%s(%s+0x%lx): reloc against `%s': error %d"),
+ (_("%s(%s+0x%lx): %s reloc against `%s': error %d"),
bfd_archive_filename (input_bfd),
bfd_get_section_name (input_bfd, input_section),
- (long) rel->r_offset, name, (int) r);
- ret = false;
+ (long) rel->r_offset,
+ ppc64_elf_howto_table[r_type]->name,
+ sym_name,
+ (int) r);
+ ret = FALSE;
}
}
}
@@ -6010,15 +8752,40 @@ ppc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
return ret;
}
+/* Adjust the value of any local symbols in opd sections. */
+
+static bfd_boolean
+ppc64_elf_output_symbol_hook (struct bfd_link_info *info,
+ const char *name ATTRIBUTE_UNUSED,
+ Elf_Internal_Sym *elfsym,
+ asection *input_sec,
+ struct elf_link_hash_entry *h)
+{
+ long *adjust;
+ bfd_vma value;
+
+ if (h != NULL
+ || input_sec == NULL
+ || ppc64_elf_section_data (input_sec) == NULL
+ || (adjust = ppc64_elf_section_data (input_sec)->opd.adjust) == NULL)
+ return TRUE;
+
+ value = elfsym->st_value - input_sec->output_offset;
+ if (!info->relocatable)
+ value -= input_sec->output_section->vma;
+
+ elfsym->st_value += adjust[value / 24];
+ return TRUE;
+}
+
/* Finish up dynamic symbol handling. We set the contents of various
dynamic sections here. */
-static boolean
-ppc64_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
- bfd *output_bfd;
- struct bfd_link_info *info;
- struct elf_link_hash_entry *h;
- Elf_Internal_Sym *sym;
+static bfd_boolean
+ppc64_elf_finish_dynamic_symbol (bfd *output_bfd,
+ struct bfd_link_info *info,
+ struct elf_link_hash_entry *h,
+ Elf_Internal_Sym *sym)
{
struct ppc_link_hash_table *htab;
bfd *dynobj;
@@ -6026,91 +8793,49 @@ ppc64_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
htab = ppc_hash_table (info);
dynobj = htab->elf.dynobj;
- if (h->plt.offset != (bfd_vma) -1
- && ((struct ppc_link_hash_entry *) h)->is_func_descriptor)
- {
- Elf_Internal_Rela rela;
- Elf64_External_Rela *loc;
-
- /* This symbol has an entry in the procedure linkage table. Set
- it up. */
-
- if (htab->splt == NULL
- || htab->srelplt == NULL
- || htab->sglink == NULL)
- abort ();
-
- /* Create a JMP_SLOT reloc to inform the dynamic linker to
- fill in the PLT entry. */
-
- rela.r_offset = (htab->splt->output_section->vma
- + htab->splt->output_offset
- + h->plt.offset);
- rela.r_info = ELF64_R_INFO (h->dynindx, R_PPC64_JMP_SLOT);
- rela.r_addend = 0;
-
- loc = (Elf64_External_Rela *) htab->srelplt->contents;
- loc += (h->plt.offset - PLT_INITIAL_ENTRY_SIZE) / PLT_ENTRY_SIZE;
- bfd_elf64_swap_reloca_out (output_bfd, &rela, loc);
- }
-
- if (h->got.offset != (bfd_vma) -1)
+ if (((struct ppc_link_hash_entry *) h)->is_func_descriptor)
{
+ struct plt_entry *ent;
Elf_Internal_Rela rela;
- Elf64_External_Rela *loc;
+ bfd_byte *loc;
- /* This symbol has an entry in the global offset table. Set it
- up. */
-
- if (htab->sgot == NULL || htab->srelgot == NULL)
- abort ();
+ for (ent = h->plt.plist; ent != NULL; ent = ent->next)
+ if (ent->plt.offset != (bfd_vma) -1)
+ {
+ /* This symbol has an entry in the procedure linkage
+ table. Set it up. */
- rela.r_offset = (htab->sgot->output_section->vma
- + htab->sgot->output_offset
- + (h->got.offset &~ (bfd_vma) 1));
-
- /* If this is a static link, or it is a -Bsymbolic link and the
- symbol is defined locally or was forced to be local because
- of a version file, we just want to emit a RELATIVE reloc.
- The entry in the global offset table will already have been
- initialized in the relocate_section function. */
- if (info->shared
- && (info->symbolic
- || h->dynindx == -1
- || (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL))
- && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR))
- {
- BFD_ASSERT((h->got.offset & 1) != 0);
- rela.r_info = ELF64_R_INFO (0, R_PPC64_RELATIVE);
- rela.r_addend = (h->root.u.def.value
- + h->root.u.def.section->output_section->vma
- + h->root.u.def.section->output_offset);
- }
- else
- {
- BFD_ASSERT ((h->got.offset & 1) == 0);
- bfd_put_64 (output_bfd, (bfd_vma) 0,
- htab->sgot->contents + h->got.offset);
- rela.r_info = ELF64_R_INFO (h->dynindx, R_PPC64_GLOB_DAT);
- rela.r_addend = 0;
- }
+ if (htab->plt == NULL
+ || htab->relplt == NULL
+ || htab->glink == NULL)
+ abort ();
- loc = (Elf64_External_Rela *) htab->srelgot->contents;
- loc += htab->srelgot->reloc_count++;
- bfd_elf64_swap_reloca_out (output_bfd, &rela, loc);
+ /* Create a JMP_SLOT reloc to inform the dynamic linker to
+ fill in the PLT entry. */
+ rela.r_offset = (htab->plt->output_section->vma
+ + htab->plt->output_offset
+ + ent->plt.offset);
+ rela.r_info = ELF64_R_INFO (h->dynindx, R_PPC64_JMP_SLOT);
+ rela.r_addend = ent->addend;
+
+ loc = htab->relplt->contents;
+ loc += ((ent->plt.offset - PLT_INITIAL_ENTRY_SIZE) / PLT_ENTRY_SIZE
+ * sizeof (Elf64_External_Rela));
+ bfd_elf64_swap_reloca_out (output_bfd, &rela, loc);
+ }
}
if ((h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_COPY) != 0)
{
Elf_Internal_Rela rela;
- Elf64_External_Rela *loc;
+ bfd_byte *loc;
/* This symbol needs a copy reloc. Set it up. */
if (h->dynindx == -1
|| (h->root.type != bfd_link_hash_defined
&& h->root.type != bfd_link_hash_defweak)
- || htab->srelbss == NULL)
+ || htab->relbss == NULL)
abort ();
rela.r_offset = (h->root.u.def.value
@@ -6118,8 +8843,8 @@ ppc64_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
+ h->root.u.def.section->output_offset);
rela.r_info = ELF64_R_INFO (h->dynindx, R_PPC64_COPY);
rela.r_addend = 0;
- loc = (Elf64_External_Rela *) htab->srelbss->contents;
- loc += htab->srelbss->reloc_count++;
+ loc = htab->relbss->contents;
+ loc += htab->relbss->reloc_count++ * sizeof (Elf64_External_Rela);
bfd_elf64_swap_reloca_out (output_bfd, &rela, loc);
}
@@ -6127,19 +8852,18 @@ ppc64_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
if (strcmp (h->root.root.string, "_DYNAMIC") == 0)
sym->st_shndx = SHN_ABS;
- return true;
+ return TRUE;
}
/* Used to decide how to sort relocs in an optimal manner for the
dynamic linker, before writing them out. */
static enum elf_reloc_type_class
-ppc64_elf_reloc_type_class (rela)
- const Elf_Internal_Rela *rela;
+ppc64_elf_reloc_type_class (const Elf_Internal_Rela *rela)
{
- enum elf_ppc_reloc_type r_type;
+ enum elf_ppc64_reloc_type r_type;
- r_type = (enum elf_ppc_reloc_type) ELF64_R_TYPE (rela->r_info);
+ r_type = ELF64_R_TYPE (rela->r_info);
switch (r_type)
{
case R_PPC64_RELATIVE:
@@ -6155,10 +8879,9 @@ ppc64_elf_reloc_type_class (rela)
/* Finish up the dynamic sections. */
-static boolean
-ppc64_elf_finish_dynamic_sections (output_bfd, info)
- bfd *output_bfd;
- struct bfd_link_info *info;
+static bfd_boolean
+ppc64_elf_finish_dynamic_sections (bfd *output_bfd,
+ struct bfd_link_info *info)
{
struct ppc_link_hash_table *htab;
bfd *dynobj;
@@ -6172,7 +8895,7 @@ ppc64_elf_finish_dynamic_sections (output_bfd, info)
{
Elf64_External_Dyn *dyncon, *dynconend;
- if (sdyn == NULL || htab->sgot == NULL)
+ if (sdyn == NULL || htab->got == NULL)
abort ();
dyncon = (Elf64_External_Dyn *) sdyn->contents;
@@ -6190,41 +8913,62 @@ ppc64_elf_finish_dynamic_sections (output_bfd, info)
continue;
case DT_PPC64_GLINK:
- dyn.d_un.d_ptr = (htab->sglink->output_section->vma
- + htab->sglink->output_offset);
+ s = htab->glink;
+ dyn.d_un.d_ptr = s->output_section->vma + s->output_offset;
+ /* We stupidly defined DT_PPC64_GLINK to be the start
+ of glink rather than the first entry point, which is
+ what ld.so needs, and now have a bigger stub to
+ support automatic multiple TOCs. */
+ dyn.d_un.d_ptr += GLINK_CALL_STUB_SIZE - 32;
break;
case DT_PPC64_OPD:
s = bfd_get_section_by_name (output_bfd, ".opd");
- if (s != NULL)
- dyn.d_un.d_ptr = s->vma;
+ if (s == NULL)
+ continue;
+ dyn.d_un.d_ptr = s->vma;
break;
case DT_PPC64_OPDSZ:
s = bfd_get_section_by_name (output_bfd, ".opd");
- if (s != NULL)
- dyn.d_un.d_val = s->_raw_size;
+ if (s == NULL)
+ continue;
+ dyn.d_un.d_val = s->_raw_size;
break;
case DT_PLTGOT:
- dyn.d_un.d_ptr = (htab->splt->output_section->vma
- + htab->splt->output_offset);
+ s = htab->plt;
+ dyn.d_un.d_ptr = s->output_section->vma + s->output_offset;
break;
case DT_JMPREL:
- dyn.d_un.d_ptr = (htab->srelplt->output_section->vma
- + htab->srelplt->output_offset);
+ s = htab->relplt;
+ dyn.d_un.d_ptr = s->output_section->vma + s->output_offset;
break;
case DT_PLTRELSZ:
- dyn.d_un.d_val = htab->srelplt->_raw_size;
+ dyn.d_un.d_val = htab->relplt->_raw_size;
break;
case DT_RELASZ:
/* Don't count procedure linkage table relocs in the
overall reloc count. */
- if (htab->srelplt != NULL)
- dyn.d_un.d_val -= htab->srelplt->_raw_size;
+ s = htab->relplt;
+ if (s == NULL)
+ continue;
+ dyn.d_un.d_val -= s->_raw_size;
+ break;
+
+ case DT_RELA:
+ /* We may not be using the standard ELF linker script.
+ If .rela.plt is the first .rela section, we adjust
+ DT_RELA to not include it. */
+ s = htab->relplt;
+ if (s == NULL)
+ continue;
+ if (dyn.d_un.d_ptr != s->output_section->vma + s->output_offset)
+ continue;
+ dyn.d_un.d_ptr += s->_raw_size;
break;
}
@@ -6232,74 +8976,49 @@ ppc64_elf_finish_dynamic_sections (output_bfd, info)
}
}
- if (htab->sgot != NULL && htab->sgot->_raw_size != 0)
+ if (htab->got != NULL && htab->got->_raw_size != 0)
{
/* Fill in the first entry in the global offset table.
We use it to hold the link-time TOCbase. */
bfd_put_64 (output_bfd,
elf_gp (output_bfd) + TOC_BASE_OFF,
- htab->sgot->contents);
+ htab->got->contents);
/* Set .got entry size. */
- elf_section_data (htab->sgot->output_section)->this_hdr.sh_entsize = 8;
+ elf_section_data (htab->got->output_section)->this_hdr.sh_entsize = 8;
}
- if (htab->splt != NULL && htab->splt->_raw_size != 0)
+ if (htab->plt != NULL && htab->plt->_raw_size != 0)
{
/* Set .plt entry size. */
- elf_section_data (htab->splt->output_section)->this_hdr.sh_entsize
+ elf_section_data (htab->plt->output_section)->this_hdr.sh_entsize
= PLT_ENTRY_SIZE;
}
- return true;
-}
-
-#define TARGET_LITTLE_SYM bfd_elf64_powerpcle_vec
-#define TARGET_LITTLE_NAME "elf64-powerpcle"
-#define TARGET_BIG_SYM bfd_elf64_powerpc_vec
-#define TARGET_BIG_NAME "elf64-powerpc"
-#define ELF_ARCH bfd_arch_powerpc
-#define ELF_MACHINE_CODE EM_PPC64
-#define ELF_MAXPAGESIZE 0x10000
-#define elf_info_to_howto ppc64_elf_info_to_howto
-
-#ifdef EM_CYGNUS_POWERPC
-#define ELF_MACHINE_ALT1 EM_CYGNUS_POWERPC
-#endif
-
-#ifdef EM_PPC_OLD
-#define ELF_MACHINE_ALT2 EM_PPC_OLD
-#endif
-
-#define elf_backend_want_got_sym 0
-#define elf_backend_want_plt_sym 0
-#define elf_backend_plt_alignment 3
-#define elf_backend_plt_not_loaded 1
-#define elf_backend_got_symbol_offset 0
-#define elf_backend_got_header_size 8
-#define elf_backend_plt_header_size PLT_INITIAL_ENTRY_SIZE
-#define elf_backend_can_gc_sections 1
-#define elf_backend_can_refcount 1
-#define elf_backend_rela_normal 1
-
-#define bfd_elf64_bfd_reloc_type_lookup ppc64_elf_reloc_type_lookup
-#define bfd_elf64_bfd_merge_private_bfd_data ppc64_elf_merge_private_bfd_data
-#define bfd_elf64_bfd_link_hash_table_create ppc64_elf_link_hash_table_create
-#define bfd_elf64_bfd_link_hash_table_free ppc64_elf_link_hash_table_free
+ /* We need to handle writing out multiple GOT sections ourselves,
+ since we didn't add them to DYNOBJ. */
+ while ((dynobj = dynobj->link_next) != NULL)
+ {
+ asection *s;
+ s = ppc64_elf_tdata (dynobj)->got;
+ if (s != NULL
+ && s->_raw_size != 0
+ && s->output_section != bfd_abs_section_ptr
+ && !bfd_set_section_contents (output_bfd, s->output_section,
+ s->contents, s->output_offset,
+ s->_raw_size))
+ return FALSE;
+ s = ppc64_elf_tdata (dynobj)->relgot;
+ if (s != NULL
+ && s->_raw_size != 0
+ && s->output_section != bfd_abs_section_ptr
+ && !bfd_set_section_contents (output_bfd, s->output_section,
+ s->contents, s->output_offset,
+ s->_raw_size))
+ return FALSE;
+ }
-#define elf_backend_object_p ppc64_elf_object_p
-#define elf_backend_create_dynamic_sections ppc64_elf_create_dynamic_sections
-#define elf_backend_copy_indirect_symbol ppc64_elf_copy_indirect_symbol
-#define elf_backend_check_relocs ppc64_elf_check_relocs
-#define elf_backend_gc_mark_hook ppc64_elf_gc_mark_hook
-#define elf_backend_gc_sweep_hook ppc64_elf_gc_sweep_hook
-#define elf_backend_adjust_dynamic_symbol ppc64_elf_adjust_dynamic_symbol
-#define elf_backend_hide_symbol ppc64_elf_hide_symbol
-#define elf_backend_always_size_sections ppc64_elf_func_desc_adjust
-#define elf_backend_size_dynamic_sections ppc64_elf_size_dynamic_sections
-#define elf_backend_relocate_section ppc64_elf_relocate_section
-#define elf_backend_finish_dynamic_symbol ppc64_elf_finish_dynamic_symbol
-#define elf_backend_reloc_type_class ppc64_elf_reloc_type_class
-#define elf_backend_finish_dynamic_sections ppc64_elf_finish_dynamic_sections
+ return TRUE;
+}
#include "elf64-target.h"
diff --git a/contrib/binutils/bfd/elf64-ppc.h b/contrib/binutils/bfd/elf64-ppc.h
index cabc388..998e7e1 100644
--- a/contrib/binutils/bfd/elf64-ppc.h
+++ b/contrib/binutils/bfd/elf64-ppc.h
@@ -1,5 +1,5 @@
/* PowerPC64-specific support for 64-bit ELF.
- Copyright 2002 Free Software Foundation, Inc.
+ Copyright 2002, 2003 Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -17,16 +17,28 @@ You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-boolean ppc64_elf_mark_entry_syms
- PARAMS ((struct bfd_link_info *));
+void ppc64_elf_init_stub_bfd
+ (bfd *, struct bfd_link_info *);
+bfd_boolean ppc64_elf_mark_entry_syms
+ (struct bfd_link_info *);
+bfd_boolean ppc64_elf_edit_opd
+ (bfd *, struct bfd_link_info *);
+asection *ppc64_elf_tls_setup
+ (bfd *, struct bfd_link_info *);
+bfd_boolean ppc64_elf_tls_optimize
+ (bfd *, struct bfd_link_info *);
bfd_vma ppc64_elf_toc
- PARAMS ((bfd *));
+ (bfd *);
int ppc64_elf_setup_section_lists
- PARAMS ((bfd *, struct bfd_link_info *));
-void ppc64_elf_next_input_section
- PARAMS ((struct bfd_link_info *, asection *));
-boolean ppc64_elf_size_stubs
- PARAMS ((bfd *, bfd *, struct bfd_link_info *, bfd_signed_vma,
- asection *(*) (const char *, asection *), void (*) (void)));
-boolean ppc64_elf_build_stubs
- PARAMS ((struct bfd_link_info *));
+ (bfd *, struct bfd_link_info *);
+void ppc64_elf_next_toc_section
+ (struct bfd_link_info *, asection *);
+void ppc64_elf_reinit_toc
+ (bfd *, struct bfd_link_info *);
+bfd_boolean ppc64_elf_next_input_section
+ (struct bfd_link_info *, asection *);
+bfd_boolean ppc64_elf_size_stubs
+ (bfd *, struct bfd_link_info *, bfd_signed_vma,
+ asection *(*) (const char *, asection *), void (*) (void));
+bfd_boolean ppc64_elf_build_stubs
+ (bfd_boolean, struct bfd_link_info *, char **);
diff --git a/contrib/binutils/bfd/elf64-s390.c b/contrib/binutils/bfd/elf64-s390.c
index 5ad1ca7..63a261a 100644
--- a/contrib/binutils/bfd/elf64-s390.c
+++ b/contrib/binutils/bfd/elf64-s390.c
@@ -1,5 +1,5 @@
/* IBM S/390-specific support for 64-bit ELF
- Copyright 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
Contributed Martin Schwidefsky (schwidefsky@de.ibm.com).
This file is part of BFD, the Binary File Descriptor library.
@@ -29,49 +29,65 @@ static reloc_howto_type *elf_s390_reloc_type_lookup
PARAMS ((bfd *, bfd_reloc_code_real_type));
static void elf_s390_info_to_howto
PARAMS ((bfd *, arelent *, Elf_Internal_Rela *));
-static boolean elf_s390_is_local_label_name
+static bfd_boolean elf_s390_is_local_label_name
PARAMS ((bfd *, const char *));
static struct bfd_hash_entry *link_hash_newfunc
PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
static struct bfd_link_hash_table *elf_s390_link_hash_table_create
PARAMS ((bfd *));
-static boolean create_got_section
+static bfd_boolean create_got_section
PARAMS((bfd *, struct bfd_link_info *));
-static boolean elf_s390_create_dynamic_sections
+static bfd_boolean elf_s390_create_dynamic_sections
PARAMS((bfd *, struct bfd_link_info *));
static void elf_s390_copy_indirect_symbol
- PARAMS ((struct elf_backend_data *, struct elf_link_hash_entry *,
+ PARAMS ((const struct elf_backend_data *, struct elf_link_hash_entry *,
struct elf_link_hash_entry *));
-static boolean elf_s390_check_relocs
+static bfd_boolean elf_s390_check_relocs
PARAMS ((bfd *, struct bfd_link_info *, asection *,
const Elf_Internal_Rela *));
static asection *elf_s390_gc_mark_hook
PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
struct elf_link_hash_entry *, Elf_Internal_Sym *));
-static boolean elf_s390_gc_sweep_hook
+static bfd_boolean elf_s390_gc_sweep_hook
PARAMS ((bfd *, struct bfd_link_info *, asection *,
const Elf_Internal_Rela *));
-static boolean elf_s390_adjust_dynamic_symbol
+struct elf_s390_link_hash_entry;
+static void elf_s390_adjust_gotplt
+ PARAMS ((struct elf_s390_link_hash_entry *));
+static bfd_boolean elf_s390_adjust_dynamic_symbol
PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *));
-static boolean allocate_dynrelocs
+static bfd_boolean allocate_dynrelocs
PARAMS ((struct elf_link_hash_entry *, PTR));
-static boolean readonly_dynrelocs
+static bfd_boolean readonly_dynrelocs
PARAMS ((struct elf_link_hash_entry *, PTR));
-static boolean elf_s390_size_dynamic_sections
+static bfd_boolean elf_s390_size_dynamic_sections
PARAMS ((bfd *, struct bfd_link_info *));
-static boolean elf_s390_relocate_section
+static bfd_boolean elf_s390_relocate_section
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
Elf_Internal_Rela *, Elf_Internal_Sym *, asection **));
-static boolean elf_s390_finish_dynamic_symbol
+static bfd_boolean elf_s390_finish_dynamic_symbol
PARAMS ((bfd *, struct bfd_link_info *, struct elf_link_hash_entry *,
Elf_Internal_Sym *));
static enum elf_reloc_type_class elf_s390_reloc_type_class
PARAMS ((const Elf_Internal_Rela *));
-static boolean elf_s390_finish_dynamic_sections
+static bfd_boolean elf_s390_finish_dynamic_sections
PARAMS ((bfd *, struct bfd_link_info *));
-static boolean elf_s390_object_p PARAMS ((bfd *));
-
-#define USE_RELA 1 /* We want RELA relocations, not REL. */
+static bfd_boolean elf_s390_mkobject
+ PARAMS ((bfd *));
+static bfd_boolean elf_s390_object_p
+ PARAMS ((bfd *));
+static int elf_s390_tls_transition
+ PARAMS ((struct bfd_link_info *, int, int));
+static bfd_reloc_status_type s390_tls_reloc
+ PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
+static bfd_vma dtpoff_base
+ PARAMS ((struct bfd_link_info *));
+static bfd_vma tpoff
+ PARAMS ((struct bfd_link_info *, bfd_vma));
+static void invalid_tls_insn
+ PARAMS ((bfd *, asection *, Elf_Internal_Rela *));
+static bfd_reloc_status_type s390_elf_ldisp_reloc
+ PARAMS ((bfd *, arelent *, asymbol *, PTR, asection *, bfd *, char **));
#include "elf/s390.h"
@@ -86,49 +102,137 @@ static reloc_howto_type elf_howto_table[] =
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_390_NONE", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
-
- HOWTO(R_390_8, 0, 0, 8, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_8", false, 0,0x000000ff, false),
- HOWTO(R_390_12, 0, 1, 12, false, 0, complain_overflow_dont, bfd_elf_generic_reloc, "R_390_12", false, 0,0x00000fff, false),
- HOWTO(R_390_16, 0, 1, 16, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_16", false, 0,0x0000ffff, false),
- HOWTO(R_390_32, 0, 2, 32, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_32", false, 0,0xffffffff, false),
- HOWTO(R_390_PC32, 0, 2, 32, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_PC32", false, 0,0xffffffff, true),
- HOWTO(R_390_GOT12, 0, 1, 12, false, 0, complain_overflow_dont, bfd_elf_generic_reloc, "R_390_GOT12", false, 0,0x00000fff, false),
- HOWTO(R_390_GOT32, 0, 2, 32, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_GOT32", false, 0,0xffffffff, false),
- HOWTO(R_390_PLT32, 0, 2, 32, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_PLT32", false, 0,0xffffffff, true),
- HOWTO(R_390_COPY, 0, 4, 64, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_COPY", false, 0,MINUS_ONE, false),
- HOWTO(R_390_GLOB_DAT, 0, 4, 64, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_GLOB_DAT",false, 0,MINUS_ONE, false),
- HOWTO(R_390_JMP_SLOT, 0, 4, 64, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_JMP_SLOT",false, 0,MINUS_ONE, false),
- HOWTO(R_390_RELATIVE, 0, 4, 64, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_RELATIVE",false, 0,MINUS_ONE, false),
- HOWTO(R_390_GOTOFF, 0, 4, 64, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_GOTOFF", false, 0,MINUS_ONE, false),
- HOWTO(R_390_GOTPC, 0, 4, 64, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_GOTPC", false, 0,MINUS_ONE, true),
- HOWTO(R_390_GOT16, 0, 1, 16, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_GOT16", false, 0,0x0000ffff, false),
- HOWTO(R_390_PC16, 0, 1, 16, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_PC16", false, 0,0x0000ffff, true),
- HOWTO(R_390_PC16DBL, 1, 1, 16, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_PC16DBL", false, 0,0x0000ffff, true),
- HOWTO(R_390_PLT16DBL, 1, 1, 16, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_PLT16DBL", false, 0,0x0000ffff, true),
- HOWTO(R_390_PC32DBL, 1, 2, 32, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_PC32DBL", false, 0,0xffffffff, true),
- HOWTO(R_390_PLT32DBL, 1, 2, 32, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_PLT32DBL", false, 0,0xffffffff, true),
- HOWTO(R_390_GOTPCDBL, 1, 2, 32, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_GOTPCDBL", false, 0,MINUS_ONE, true),
- HOWTO(R_390_64, 0, 4, 64, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_64", false, 0,MINUS_ONE, false),
- HOWTO(R_390_PC64, 0, 4, 64, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_PC64", false, 0,MINUS_ONE, true),
- HOWTO(R_390_GOT64, 0, 4, 64, false, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_GOT64", false, 0,MINUS_ONE, false),
- HOWTO(R_390_PLT64, 0, 4, 64, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_PLT64", false, 0,MINUS_ONE, true),
- HOWTO(R_390_GOTENT, 1, 2, 32, true, 0, complain_overflow_bitfield, bfd_elf_generic_reloc, "R_390_GOTENT", false, 0,MINUS_ONE, true),
+ FALSE), /* pcrel_offset */
+
+ HOWTO(R_390_8, 0, 0, 8, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_8", FALSE, 0,0x000000ff, FALSE),
+ HOWTO(R_390_12, 0, 1, 12, FALSE, 0, complain_overflow_dont,
+ bfd_elf_generic_reloc, "R_390_12", FALSE, 0,0x00000fff, FALSE),
+ HOWTO(R_390_16, 0, 1, 16, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_16", FALSE, 0,0x0000ffff, FALSE),
+ HOWTO(R_390_32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_32", FALSE, 0,0xffffffff, FALSE),
+ HOWTO(R_390_PC32, 0, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PC32", FALSE, 0,0xffffffff, TRUE),
+ HOWTO(R_390_GOT12, 0, 1, 12, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOT12", FALSE, 0,0x00000fff, FALSE),
+ HOWTO(R_390_GOT32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOT32", FALSE, 0,0xffffffff, FALSE),
+ HOWTO(R_390_PLT32, 0, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PLT32", FALSE, 0,0xffffffff, TRUE),
+ HOWTO(R_390_COPY, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_COPY", FALSE, 0,MINUS_ONE, FALSE),
+ HOWTO(R_390_GLOB_DAT, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GLOB_DAT", FALSE, 0,MINUS_ONE, FALSE),
+ HOWTO(R_390_JMP_SLOT, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_JMP_SLOT", FALSE, 0,MINUS_ONE, FALSE),
+ HOWTO(R_390_RELATIVE, 0, 4, 64, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_RELATIVE", FALSE, 0,MINUS_ONE, FALSE),
+ HOWTO(R_390_GOTOFF32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTOFF32", FALSE, 0,MINUS_ONE, FALSE),
+ HOWTO(R_390_GOTPC, 0, 4, 64, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTPC", FALSE, 0,MINUS_ONE, TRUE),
+ HOWTO(R_390_GOT16, 0, 1, 16, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOT16", FALSE, 0,0x0000ffff, FALSE),
+ HOWTO(R_390_PC16, 0, 1, 16, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PC16", FALSE, 0,0x0000ffff, TRUE),
+ HOWTO(R_390_PC16DBL, 1, 1, 16, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PC16DBL", FALSE, 0,0x0000ffff, TRUE),
+ HOWTO(R_390_PLT16DBL, 1, 1, 16, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PLT16DBL", FALSE, 0,0x0000ffff, TRUE),
+ HOWTO(R_390_PC32DBL, 1, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PC32DBL", FALSE, 0,0xffffffff, TRUE),
+ HOWTO(R_390_PLT32DBL, 1, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PLT32DBL", FALSE, 0,0xffffffff, TRUE),
+ HOWTO(R_390_GOTPCDBL, 1, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTPCDBL", FALSE, 0,MINUS_ONE, TRUE),
+ HOWTO(R_390_64, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_64", FALSE, 0,MINUS_ONE, FALSE),
+ HOWTO(R_390_PC64, 0, 4, 64, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PC64", FALSE, 0,MINUS_ONE, TRUE),
+ HOWTO(R_390_GOT64, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOT64", FALSE, 0,MINUS_ONE, FALSE),
+ HOWTO(R_390_PLT64, 0, 4, 64, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PLT64", FALSE, 0,MINUS_ONE, TRUE),
+ HOWTO(R_390_GOTENT, 1, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTENT", FALSE, 0,MINUS_ONE, TRUE),
+ HOWTO(R_390_GOTOFF16, 0, 1, 16, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTOFF16", FALSE, 0,0x0000ffff, FALSE),
+ HOWTO(R_390_GOTOFF64, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTOFF64", FALSE, 0,MINUS_ONE, FALSE),
+ HOWTO(R_390_GOTPLT12, 0, 1, 12, FALSE, 0, complain_overflow_dont,
+ bfd_elf_generic_reloc, "R_390_GOTPLT12", FALSE, 0,0x00000fff, FALSE),
+ HOWTO(R_390_GOTPLT16, 0, 1, 16, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTPLT16", FALSE, 0,0x0000ffff, FALSE),
+ HOWTO(R_390_GOTPLT32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTPLT32", FALSE, 0,0xffffffff, FALSE),
+ HOWTO(R_390_GOTPLT64, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTPLT64", FALSE, 0,MINUS_ONE, FALSE),
+ HOWTO(R_390_GOTPLTENT, 1, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_GOTPLTENT",FALSE, 0,MINUS_ONE, TRUE),
+ HOWTO(R_390_PLTOFF16, 0, 1, 16, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PLTOFF16", FALSE, 0,0x0000ffff, FALSE),
+ HOWTO(R_390_PLTOFF32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PLTOFF32", FALSE, 0,0xffffffff, FALSE),
+ HOWTO(R_390_PLTOFF64, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_PLTOFF64", FALSE, 0,MINUS_ONE, FALSE),
+ HOWTO(R_390_TLS_LOAD, 0, 0, 0, FALSE, 0, complain_overflow_dont,
+ s390_tls_reloc, "R_390_TLS_LOAD", FALSE, 0, 0, FALSE),
+ HOWTO(R_390_TLS_GDCALL, 0, 0, 0, FALSE, 0, complain_overflow_dont,
+ s390_tls_reloc, "R_390_TLS_GDCALL", FALSE, 0, 0, FALSE),
+ HOWTO(R_390_TLS_LDCALL, 0, 0, 0, FALSE, 0, complain_overflow_dont,
+ s390_tls_reloc, "R_390_TLS_LDCALL", FALSE, 0, 0, FALSE),
+ EMPTY_HOWTO (R_390_TLS_GD32), /* Empty entry for R_390_TLS_GD32. */
+ HOWTO(R_390_TLS_GD64, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_GD64", FALSE, 0, MINUS_ONE, FALSE),
+ HOWTO(R_390_TLS_GOTIE12, 0, 1, 12, FALSE, 0, complain_overflow_dont,
+ bfd_elf_generic_reloc, "R_390_TLS_GOTIE12", FALSE, 0, 0x00000fff, FALSE),
+ EMPTY_HOWTO (R_390_TLS_GOTIE32), /* Empty entry for R_390_TLS_GOTIE32. */
+ HOWTO(R_390_TLS_GOTIE64, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_GOTIE64", FALSE, 0, MINUS_ONE, FALSE),
+ EMPTY_HOWTO (R_390_TLS_LDM32), /* Empty entry for R_390_TLS_LDM32. */
+ HOWTO(R_390_TLS_LDM64, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_LDM64", FALSE, 0, MINUS_ONE, FALSE),
+ EMPTY_HOWTO (R_390_TLS_IE32), /* Empty entry for R_390_TLS_IE32. */
+ HOWTO(R_390_TLS_IE64, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_IE64", FALSE, 0, MINUS_ONE, FALSE),
+ HOWTO(R_390_TLS_IEENT, 1, 2, 32, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_IEENT", FALSE, 0, MINUS_ONE, TRUE),
+ EMPTY_HOWTO (R_390_TLS_LE32), /* Empty entry for R_390_TLS_LE32. */
+ HOWTO(R_390_TLS_LE64, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_LE64", FALSE, 0, MINUS_ONE, FALSE),
+ EMPTY_HOWTO (R_390_TLS_LDO32), /* Empty entry for R_390_TLS_LDO32. */
+ HOWTO(R_390_TLS_LDO64, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_LDO64", FALSE, 0, MINUS_ONE, FALSE),
+ HOWTO(R_390_TLS_DTPMOD, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_DTPMOD", FALSE, 0, MINUS_ONE, FALSE),
+ HOWTO(R_390_TLS_DTPOFF, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_DTPOFF", FALSE, 0, MINUS_ONE, FALSE),
+ HOWTO(R_390_TLS_TPOFF, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_390_TLS_TPOFF", FALSE, 0, MINUS_ONE, FALSE),
+ HOWTO(R_390_20, 0, 2, 20, FALSE, 8, complain_overflow_dont,
+ s390_elf_ldisp_reloc, "R_390_20", FALSE, 0,0x0fffff00, FALSE),
+ HOWTO(R_390_GOT20, 0, 2, 20, FALSE, 8, complain_overflow_dont,
+ s390_elf_ldisp_reloc, "R_390_GOT20", FALSE, 0,0x0fffff00, FALSE),
+ HOWTO(R_390_GOTPLT20, 0, 2, 20, FALSE, 8, complain_overflow_dont,
+ s390_elf_ldisp_reloc, "R_390_GOTPLT20", FALSE, 0,0x0fffff00, FALSE),
+ HOWTO(R_390_TLS_GOTIE20, 0, 2, 20, FALSE, 8, complain_overflow_dont,
+ s390_elf_ldisp_reloc, "R_390_TLS_GOTIE20", FALSE, 0,0x0fffff00, FALSE),
};
/* GNU extension to record C++ vtable hierarchy. */
static reloc_howto_type elf64_s390_vtinherit_howto =
- HOWTO (R_390_GNU_VTINHERIT, 0,4,0,false,0,complain_overflow_dont, NULL, "R_390_GNU_VTINHERIT", false,0, 0, false);
+ HOWTO (R_390_GNU_VTINHERIT, 0,4,0,FALSE,0,complain_overflow_dont, NULL, "R_390_GNU_VTINHERIT", FALSE,0, 0, FALSE);
static reloc_howto_type elf64_s390_vtentry_howto =
- HOWTO (R_390_GNU_VTENTRY, 0,4,0,false,0,complain_overflow_dont, _bfd_elf_rel_vtable_reloc_fn,"R_390_GNU_VTENTRY", false,0,0, false);
+ HOWTO (R_390_GNU_VTENTRY, 0,4,0,FALSE,0,complain_overflow_dont, _bfd_elf_rel_vtable_reloc_fn,"R_390_GNU_VTENTRY", FALSE,0,0, FALSE);
static reloc_howto_type *
elf_s390_reloc_type_lookup (abfd, code)
@@ -166,7 +270,7 @@ elf_s390_reloc_type_lookup (abfd, code)
case BFD_RELOC_390_RELATIVE:
return &elf_howto_table[(int) R_390_RELATIVE];
case BFD_RELOC_32_GOTOFF:
- return &elf_howto_table[(int) R_390_GOTOFF];
+ return &elf_howto_table[(int) R_390_GOTOFF32];
case BFD_RELOC_390_GOTPC:
return &elf_howto_table[(int) R_390_GOTPC];
case BFD_RELOC_390_GOT16:
@@ -177,10 +281,6 @@ elf_s390_reloc_type_lookup (abfd, code)
return &elf_howto_table[(int) R_390_PC16DBL];
case BFD_RELOC_390_PLT16DBL:
return &elf_howto_table[(int) R_390_PLT16DBL];
- case BFD_RELOC_VTABLE_INHERIT:
- return &elf64_s390_vtinherit_howto;
- case BFD_RELOC_VTABLE_ENTRY:
- return &elf64_s390_vtentry_howto;
case BFD_RELOC_390_PC32DBL:
return &elf_howto_table[(int) R_390_PC32DBL];
case BFD_RELOC_390_PLT32DBL:
@@ -197,6 +297,66 @@ elf_s390_reloc_type_lookup (abfd, code)
return &elf_howto_table[(int) R_390_PLT64];
case BFD_RELOC_390_GOTENT:
return &elf_howto_table[(int) R_390_GOTENT];
+ case BFD_RELOC_16_GOTOFF:
+ return &elf_howto_table[(int) R_390_GOTOFF16];
+ case BFD_RELOC_390_GOTOFF64:
+ return &elf_howto_table[(int) R_390_GOTOFF64];
+ case BFD_RELOC_390_GOTPLT12:
+ return &elf_howto_table[(int) R_390_GOTPLT12];
+ case BFD_RELOC_390_GOTPLT16:
+ return &elf_howto_table[(int) R_390_GOTPLT16];
+ case BFD_RELOC_390_GOTPLT32:
+ return &elf_howto_table[(int) R_390_GOTPLT32];
+ case BFD_RELOC_390_GOTPLT64:
+ return &elf_howto_table[(int) R_390_GOTPLT64];
+ case BFD_RELOC_390_GOTPLTENT:
+ return &elf_howto_table[(int) R_390_GOTPLTENT];
+ case BFD_RELOC_390_PLTOFF16:
+ return &elf_howto_table[(int) R_390_PLTOFF16];
+ case BFD_RELOC_390_PLTOFF32:
+ return &elf_howto_table[(int) R_390_PLTOFF32];
+ case BFD_RELOC_390_PLTOFF64:
+ return &elf_howto_table[(int) R_390_PLTOFF64];
+ case BFD_RELOC_390_TLS_LOAD:
+ return &elf_howto_table[(int) R_390_TLS_LOAD];
+ case BFD_RELOC_390_TLS_GDCALL:
+ return &elf_howto_table[(int) R_390_TLS_GDCALL];
+ case BFD_RELOC_390_TLS_LDCALL:
+ return &elf_howto_table[(int) R_390_TLS_LDCALL];
+ case BFD_RELOC_390_TLS_GD64:
+ return &elf_howto_table[(int) R_390_TLS_GD64];
+ case BFD_RELOC_390_TLS_GOTIE12:
+ return &elf_howto_table[(int) R_390_TLS_GOTIE12];
+ case BFD_RELOC_390_TLS_GOTIE64:
+ return &elf_howto_table[(int) R_390_TLS_GOTIE64];
+ case BFD_RELOC_390_TLS_LDM64:
+ return &elf_howto_table[(int) R_390_TLS_LDM64];
+ case BFD_RELOC_390_TLS_IE64:
+ return &elf_howto_table[(int) R_390_TLS_IE64];
+ case BFD_RELOC_390_TLS_IEENT:
+ return &elf_howto_table[(int) R_390_TLS_IEENT];
+ case BFD_RELOC_390_TLS_LE64:
+ return &elf_howto_table[(int) R_390_TLS_LE64];
+ case BFD_RELOC_390_TLS_LDO64:
+ return &elf_howto_table[(int) R_390_TLS_LDO64];
+ case BFD_RELOC_390_TLS_DTPMOD:
+ return &elf_howto_table[(int) R_390_TLS_DTPMOD];
+ case BFD_RELOC_390_TLS_DTPOFF:
+ return &elf_howto_table[(int) R_390_TLS_DTPOFF];
+ case BFD_RELOC_390_TLS_TPOFF:
+ return &elf_howto_table[(int) R_390_TLS_TPOFF];
+ case BFD_RELOC_390_20:
+ return &elf_howto_table[(int) R_390_20];
+ case BFD_RELOC_390_GOT20:
+ return &elf_howto_table[(int) R_390_GOT20];
+ case BFD_RELOC_390_GOTPLT20:
+ return &elf_howto_table[(int) R_390_GOTPLT20];
+ case BFD_RELOC_390_TLS_GOTIE20:
+ return &elf_howto_table[(int) R_390_TLS_GOTIE20];
+ case BFD_RELOC_VTABLE_INHERIT:
+ return &elf64_s390_vtinherit_howto;
+ case BFD_RELOC_VTABLE_ENTRY:
+ return &elf64_s390_vtentry_howto;
default:
break;
}
@@ -228,13 +388,82 @@ elf_s390_info_to_howto (abfd, cache_ptr, dst)
}
}
-static boolean
+/* A relocation function which doesn't do anything. */
+static bfd_reloc_status_type
+s390_tls_reloc (abfd, reloc_entry, symbol, data, input_section,
+ output_bfd, error_message)
+ bfd *abfd ATTRIBUTE_UNUSED;
+ arelent *reloc_entry;
+ asymbol *symbol ATTRIBUTE_UNUSED;
+ PTR data ATTRIBUTE_UNUSED;
+ asection *input_section;
+ bfd *output_bfd;
+ char **error_message ATTRIBUTE_UNUSED;
+{
+ if (output_bfd)
+ reloc_entry->address += input_section->output_offset;
+ return bfd_reloc_ok;
+}
+
+/* Handle the large displacement relocs. */
+static bfd_reloc_status_type
+s390_elf_ldisp_reloc (abfd, reloc_entry, symbol, data, input_section,
+ output_bfd, error_message)
+ bfd *abfd;
+ arelent *reloc_entry;
+ asymbol *symbol;
+ PTR data;
+ asection *input_section;
+ bfd *output_bfd;
+ char **error_message ATTRIBUTE_UNUSED;
+{
+ reloc_howto_type *howto = reloc_entry->howto;
+ bfd_vma relocation;
+ bfd_vma insn;
+
+ if (output_bfd != (bfd *) NULL
+ && (symbol->flags & BSF_SECTION_SYM) == 0
+ && (! howto->partial_inplace
+ || reloc_entry->addend == 0))
+ {
+ reloc_entry->address += input_section->output_offset;
+ return bfd_reloc_ok;
+ }
+ if (output_bfd != NULL)
+ return bfd_reloc_continue;
+
+ if (reloc_entry->address > input_section->_cooked_size)
+ return bfd_reloc_outofrange;
+
+ relocation = (symbol->value
+ + symbol->section->output_section->vma
+ + symbol->section->output_offset);
+ relocation += reloc_entry->addend;
+ if (howto->pc_relative)
+ {
+ relocation -= (input_section->output_section->vma
+ + input_section->output_offset);
+ relocation -= reloc_entry->address;
+ }
+
+ insn = bfd_get_32 (abfd, (bfd_byte *) data + reloc_entry->address);
+ insn |= (relocation & 0xfff) << 16 | (relocation & 0xff000) >> 4;
+ bfd_put_32 (abfd, insn, (bfd_byte *) data + reloc_entry->address);
+
+ if ((bfd_signed_vma) relocation < - 0x80000
+ || (bfd_signed_vma) relocation > 0x7ffff)
+ return bfd_reloc_overflow;
+ else
+ return bfd_reloc_ok;
+}
+
+static bfd_boolean
elf_s390_is_local_label_name (abfd, name)
bfd *abfd;
const char *name;
{
if (name[0] == '.' && (name[1] == 'X' || name[1] == 'L'))
- return true;
+ return TRUE;
return _bfd_elf_is_local_label_name (abfd, name);
}
@@ -246,6 +475,12 @@ elf_s390_is_local_label_name (abfd, name)
#define ELF_DYNAMIC_INTERPRETER "/usr/lib/ld.so.1"
+/* If ELIMINATE_COPY_RELOCS is non-zero, the linker will try to avoid
+ copying dynamic variables from a shared lib into an app's dynbss
+ section, and instead use a dynamic relocation to point into the
+ shared lib. */
+#define ELIMINATE_COPY_RELOCS 1
+
/* The size in bytes of the first entry in the procedure linkage table. */
#define PLT_FIRST_ENTRY_SIZE 32
/* The size in bytes of an entry in the procedure linkage table. */
@@ -359,8 +594,54 @@ struct elf_s390_link_hash_entry
/* Track dynamic relocs copied for this symbol. */
struct elf_s390_dyn_relocs *dyn_relocs;
+
+ /* Number of GOTPLT references for a function. */
+ bfd_signed_vma gotplt_refcount;
+
+#define GOT_UNKNOWN 0
+#define GOT_NORMAL 1
+#define GOT_TLS_GD 2
+#define GOT_TLS_IE 3
+#define GOT_TLS_IE_NLT 3
+ unsigned char tls_type;
};
+#define elf_s390_hash_entry(ent) \
+ ((struct elf_s390_link_hash_entry *)(ent))
+
+struct elf_s390_obj_tdata
+{
+ struct elf_obj_tdata root;
+
+ /* tls_type for each local got entry. */
+ char *local_got_tls_type;
+};
+
+#define elf_s390_tdata(abfd) \
+ ((struct elf_s390_obj_tdata *) (abfd)->tdata.any)
+
+#define elf_s390_local_got_tls_type(abfd) \
+ (elf_s390_tdata (abfd)->local_got_tls_type)
+
+static bfd_boolean
+elf_s390_mkobject (abfd)
+ bfd *abfd;
+{
+ bfd_size_type amt = sizeof (struct elf_s390_obj_tdata);
+ abfd->tdata.any = bfd_zalloc (abfd, amt);
+ if (abfd->tdata.any == NULL)
+ return FALSE;
+ return TRUE;
+}
+
+static bfd_boolean
+elf_s390_object_p (abfd)
+ bfd *abfd;
+{
+ /* Set the right machine number for an s390 elf32 file. */
+ return bfd_default_set_arch_mach (abfd, bfd_arch_s390, bfd_mach_s390_64);
+}
+
/* s390 ELF linker hash table. */
struct elf_s390_link_hash_table
@@ -376,6 +657,11 @@ struct elf_s390_link_hash_table
asection *sdynbss;
asection *srelbss;
+ union {
+ bfd_signed_vma refcount;
+ bfd_vma offset;
+ } tls_ldm_got;
+
/* Small local sym to section mapping cache. */
struct sym_sec_cache sym_sec;
};
@@ -411,6 +697,8 @@ link_hash_newfunc (entry, table, string)
eh = (struct elf_s390_link_hash_entry *) entry;
eh->dyn_relocs = NULL;
+ eh->gotplt_refcount = 0;
+ eh->tls_type = GOT_UNKNOWN;
}
return entry;
@@ -442,6 +730,7 @@ elf_s390_link_hash_table_create (abfd)
ret->srelplt = NULL;
ret->sdynbss = NULL;
ret->srelbss = NULL;
+ ret->tls_ldm_got.refcount = 0;
ret->sym_sec.abfd = NULL;
return &ret->elf.root;
@@ -450,7 +739,7 @@ elf_s390_link_hash_table_create (abfd)
/* Create .got, .gotplt, and .rela.got sections in DYNOBJ, and set up
shortcuts to them in our hash table. */
-static boolean
+static bfd_boolean
create_got_section (dynobj, info)
bfd *dynobj;
struct bfd_link_info *info;
@@ -458,7 +747,7 @@ create_got_section (dynobj, info)
struct elf_s390_link_hash_table *htab;
if (! _bfd_elf_create_got_section (dynobj, info))
- return false;
+ return FALSE;
htab = elf_s390_hash_table (info);
htab->sgot = bfd_get_section_by_name (dynobj, ".got");
@@ -473,15 +762,15 @@ create_got_section (dynobj, info)
| SEC_IN_MEMORY | SEC_LINKER_CREATED
| SEC_READONLY))
|| ! bfd_set_section_alignment (dynobj, htab->srelgot, 3))
- return false;
- return true;
+ return FALSE;
+ return TRUE;
}
/* Create .plt, .rela.plt, .got, .got.plt, .rela.got, .dynbss, and
.rela.bss sections in DYNOBJ, and set up shortcuts to them in our
hash table. */
-static boolean
+static bfd_boolean
elf_s390_create_dynamic_sections (dynobj, info)
bfd *dynobj;
struct bfd_link_info *info;
@@ -490,10 +779,10 @@ elf_s390_create_dynamic_sections (dynobj, info)
htab = elf_s390_hash_table (info);
if (!htab->sgot && !create_got_section (dynobj, info))
- return false;
+ return FALSE;
if (!_bfd_elf_create_dynamic_sections (dynobj, info))
- return false;
+ return FALSE;
htab->splt = bfd_get_section_by_name (dynobj, ".plt");
htab->srelplt = bfd_get_section_by_name (dynobj, ".rela.plt");
@@ -505,14 +794,14 @@ elf_s390_create_dynamic_sections (dynobj, info)
|| (!info->shared && !htab->srelbss))
abort ();
- return true;
+ return TRUE;
}
/* Copy the extra info we tack onto an elf_link_hash_entry. */
static void
elf_s390_copy_indirect_symbol (bed, dir, ind)
- struct elf_backend_data *bed;
+ const struct elf_backend_data *bed;
struct elf_link_hash_entry *dir, *ind;
{
struct elf_s390_link_hash_entry *edir, *eind;
@@ -554,14 +843,60 @@ elf_s390_copy_indirect_symbol (bed, dir, ind)
eind->dyn_relocs = NULL;
}
- _bfd_elf_link_hash_copy_indirect (bed, dir, ind);
+ if (ind->root.type == bfd_link_hash_indirect
+ && dir->got.refcount <= 0)
+ {
+ edir->tls_type = eind->tls_type;
+ eind->tls_type = GOT_UNKNOWN;
+ }
+
+ if (ELIMINATE_COPY_RELOCS
+ && ind->root.type != bfd_link_hash_indirect
+ && (dir->elf_link_hash_flags & ELF_LINK_HASH_DYNAMIC_ADJUSTED) != 0)
+ /* If called to transfer flags for a weakdef during processing
+ of elf_adjust_dynamic_symbol, don't copy ELF_LINK_NON_GOT_REF.
+ We clear it ourselves for ELIMINATE_COPY_RELOCS. */
+ dir->elf_link_hash_flags |=
+ (ind->elf_link_hash_flags & (ELF_LINK_HASH_REF_DYNAMIC
+ | ELF_LINK_HASH_REF_REGULAR
+ | ELF_LINK_HASH_REF_REGULAR_NONWEAK
+ | ELF_LINK_HASH_NEEDS_PLT));
+ else
+ _bfd_elf_link_hash_copy_indirect (bed, dir, ind);
+}
+
+static int
+elf_s390_tls_transition (info, r_type, is_local)
+ struct bfd_link_info *info;
+ int r_type;
+ int is_local;
+{
+ if (info->shared)
+ return r_type;
+
+ switch (r_type)
+ {
+ case R_390_TLS_GD64:
+ case R_390_TLS_IE64:
+ if (is_local)
+ return R_390_TLS_LE64;
+ return R_390_TLS_IE64;
+ case R_390_TLS_GOTIE64:
+ if (is_local)
+ return R_390_TLS_LE64;
+ return R_390_TLS_GOTIE64;
+ case R_390_TLS_LDM64:
+ return R_390_TLS_LE64;
+ }
+
+ return r_type;
}
/* Look through the relocs for a section during the first phase, and
allocate space in the global offset table or procedure linkage
table. */
-static boolean
+static bfd_boolean
elf_s390_check_relocs (abfd, info, sec, relocs)
bfd *abfd;
struct bfd_link_info *info;
@@ -574,19 +909,23 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
const Elf_Internal_Rela *rel;
const Elf_Internal_Rela *rel_end;
asection *sreloc;
+ bfd_signed_vma *local_got_refcounts;
+ int tls_type, old_tls_type;
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
htab = elf_s390_hash_table (info);
symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
sym_hashes = elf_sym_hashes (abfd);
+ local_got_refcounts = elf_local_got_refcounts (abfd);
sreloc = NULL;
rel_end = relocs + sec->reloc_count;
for (rel = relocs; rel < rel_end; rel++)
{
+ unsigned int r_type;
unsigned long r_symndx;
struct elf_link_hash_entry *h;
@@ -597,7 +936,7 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
(*_bfd_error_handler) (_("%s: bad symbol index: %d"),
bfd_archive_filename (abfd),
r_symndx);
- return false;
+ return FALSE;
}
if (r_symndx < symtab_hdr->sh_info)
@@ -605,41 +944,51 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
else
h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- switch (ELF64_R_TYPE (rel->r_info))
+ /* Create got section and local_got_refcounts array if they
+ are needed. */
+ r_type = elf_s390_tls_transition (info,
+ ELF64_R_TYPE (rel->r_info),
+ h == NULL);
+ switch (r_type)
{
case R_390_GOT12:
- case R_390_GOT16:
+ case R_390_GOT16:
+ case R_390_GOT20:
case R_390_GOT32:
case R_390_GOT64:
case R_390_GOTENT:
- /* This symbol requires a global offset table entry. */
- if (h != NULL)
- {
- h->got.refcount += 1;
- }
- else
+ case R_390_GOTPLT12:
+ case R_390_GOTPLT16:
+ case R_390_GOTPLT20:
+ case R_390_GOTPLT32:
+ case R_390_GOTPLT64:
+ case R_390_GOTPLTENT:
+ case R_390_TLS_GD64:
+ case R_390_TLS_GOTIE12:
+ case R_390_TLS_GOTIE20:
+ case R_390_TLS_GOTIE64:
+ case R_390_TLS_IEENT:
+ case R_390_TLS_IE64:
+ case R_390_TLS_LDM64:
+ if (h == NULL
+ && local_got_refcounts == NULL)
{
- bfd_signed_vma *local_got_refcounts;
+ bfd_size_type size;
- /* This is a global offset table entry for a local symbol. */
- local_got_refcounts = elf_local_got_refcounts (abfd);
+ size = symtab_hdr->sh_info;
+ size *= (sizeof (bfd_signed_vma) + sizeof(char));
+ local_got_refcounts = ((bfd_signed_vma *)
+ bfd_zalloc (abfd, size));
if (local_got_refcounts == NULL)
- {
- bfd_size_type size;
-
- size = symtab_hdr->sh_info;
- size *= sizeof (bfd_signed_vma);
- local_got_refcounts = ((bfd_signed_vma *)
- bfd_zalloc (abfd, size));
- if (local_got_refcounts == NULL)
- return false;
- elf_local_got_refcounts (abfd) = local_got_refcounts;
- }
- local_got_refcounts[r_symndx] += 1;
+ return FALSE;
+ elf_local_got_refcounts (abfd) = local_got_refcounts;
+ elf_s390_local_got_tls_type (abfd)
+ = (char *) (local_got_refcounts + symtab_hdr->sh_info);
}
- /* Fall through */
-
- case R_390_GOTOFF:
+ /* Fall through. */
+ case R_390_GOTOFF16:
+ case R_390_GOTOFF32:
+ case R_390_GOTOFF64:
case R_390_GOTPC:
case R_390_GOTPCDBL:
if (htab->sgot == NULL)
@@ -647,36 +996,161 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
if (htab->elf.dynobj == NULL)
htab->elf.dynobj = abfd;
if (!create_got_section (htab->elf.dynobj, info))
- return false;
+ return FALSE;
}
+ }
+
+ switch (r_type)
+ {
+ case R_390_GOTOFF16:
+ case R_390_GOTOFF32:
+ case R_390_GOTOFF64:
+ case R_390_GOTPC:
+ case R_390_GOTPCDBL:
+ /* Got is created, nothing to be done. */
break;
- case R_390_PLT16DBL:
+ case R_390_PLT16DBL:
case R_390_PLT32:
case R_390_PLT32DBL:
case R_390_PLT64:
+ case R_390_PLTOFF16:
+ case R_390_PLTOFF32:
+ case R_390_PLTOFF64:
/* This symbol requires a procedure linkage table entry. We
- actually build the entry in adjust_dynamic_symbol,
- because this might be a case of linking PIC code which is
- never referenced by a dynamic object, in which case we
- don't need to generate a procedure linkage table entry
- after all. */
+ actually build the entry in adjust_dynamic_symbol,
+ because this might be a case of linking PIC code which is
+ never referenced by a dynamic object, in which case we
+ don't need to generate a procedure linkage table entry
+ after all. */
/* If this is a local symbol, we resolve it directly without
- creating a procedure linkage table entry. */
- if (h == NULL)
- continue;
+ creating a procedure linkage table entry. */
+ if (h != NULL)
+ {
+ h->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_PLT;
+ h->plt.refcount += 1;
+ }
+ break;
- h->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_PLT;
- h->plt.refcount += 1;
+ case R_390_GOTPLT12:
+ case R_390_GOTPLT16:
+ case R_390_GOTPLT20:
+ case R_390_GOTPLT32:
+ case R_390_GOTPLT64:
+ case R_390_GOTPLTENT:
+ /* This symbol requires either a procedure linkage table entry
+ or an entry in the local got. We actually build the entry
+ in adjust_dynamic_symbol because whether this is really a
+ global reference can change and with it the fact if we have
+ to create a plt entry or a local got entry. To be able to
+ make a once global symbol a local one we have to keep track
+ of the number of gotplt references that exist for this
+ symbol. */
+ if (h != NULL)
+ {
+ ((struct elf_s390_link_hash_entry *) h)->gotplt_refcount++;
+ h->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_PLT;
+ h->plt.refcount += 1;
+ }
+ else
+ local_got_refcounts[r_symndx] += 1;
+ break;
+
+ case R_390_TLS_LDM64:
+ htab->tls_ldm_got.refcount += 1;
break;
- case R_390_8:
- case R_390_16:
+ case R_390_TLS_IE64:
+ case R_390_TLS_GOTIE12:
+ case R_390_TLS_GOTIE20:
+ case R_390_TLS_GOTIE64:
+ case R_390_TLS_IEENT:
+ if (info->shared)
+ info->flags |= DF_STATIC_TLS;
+ /* Fall through */
+
+ case R_390_GOT12:
+ case R_390_GOT16:
+ case R_390_GOT20:
+ case R_390_GOT32:
+ case R_390_GOT64:
+ case R_390_GOTENT:
+ case R_390_TLS_GD64:
+ /* This symbol requires a global offset table entry. */
+ switch (r_type)
+ {
+ default:
+ case R_390_GOT12:
+ case R_390_GOT16:
+ case R_390_GOT20:
+ case R_390_GOT32:
+ case R_390_GOTENT:
+ tls_type = GOT_NORMAL;
+ break;
+ case R_390_TLS_GD64:
+ tls_type = GOT_TLS_GD;
+ break;
+ case R_390_TLS_IE64:
+ case R_390_TLS_GOTIE64:
+ tls_type = GOT_TLS_IE;
+ break;
+ case R_390_TLS_GOTIE12:
+ case R_390_TLS_GOTIE20:
+ case R_390_TLS_IEENT:
+ tls_type = GOT_TLS_IE_NLT;
+ break;
+ }
+
+ if (h != NULL)
+ {
+ h->got.refcount += 1;
+ old_tls_type = elf_s390_hash_entry(h)->tls_type;
+ }
+ else
+ {
+ local_got_refcounts[r_symndx] += 1;
+ old_tls_type = elf_s390_local_got_tls_type (abfd) [r_symndx];
+ }
+ /* If a TLS symbol is accessed using IE at least once,
+ there is no point to use dynamic model for it. */
+ if (old_tls_type != tls_type && old_tls_type != GOT_UNKNOWN)
+ {
+ if (old_tls_type == GOT_NORMAL || tls_type == GOT_NORMAL)
+ {
+ (*_bfd_error_handler)
+ (_("%s: `%s' accessed both as normal and thread local symbol"),
+ bfd_archive_filename (abfd), h->root.root.string);
+ return FALSE;
+ }
+ if (old_tls_type > tls_type)
+ tls_type = old_tls_type;
+ }
+
+ if (old_tls_type != tls_type)
+ {
+ if (h != NULL)
+ elf_s390_hash_entry (h)->tls_type = tls_type;
+ else
+ elf_s390_local_got_tls_type (abfd) [r_symndx] = tls_type;
+ }
+
+ if (r_type != R_390_TLS_IE64)
+ break;
+ /* Fall through */
+
+ case R_390_TLS_LE64:
+ if (!info->shared)
+ break;
+ info->flags |= DF_STATIC_TLS;
+ /* Fall through */
+
+ case R_390_8:
+ case R_390_16:
case R_390_32:
case R_390_64:
- case R_390_PC16:
- case R_390_PC16DBL:
+ case R_390_PC16:
+ case R_390_PC16DBL:
case R_390_PC32:
case R_390_PC32DBL:
case R_390_PC64:
@@ -728,7 +1202,8 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
|| h->root.type == bfd_link_hash_defweak
|| (h->elf_link_hash_flags
& ELF_LINK_HASH_DEF_REGULAR) == 0))))
- || (!info->shared
+ || (ELIMINATE_COPY_RELOCS
+ && !info->shared
&& (sec->flags & SEC_ALLOC) != 0
&& h != NULL
&& (h->root.type == bfd_link_hash_defweak
@@ -751,7 +1226,7 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
elf_elfheader (abfd)->e_shstrndx,
elf_section_data (sec)->rel_hdr.sh_name));
if (name == NULL)
- return false;
+ return FALSE;
if (strncmp (name, ".rela", 5) != 0
|| strcmp (bfd_get_section_name (abfd, sec),
@@ -779,7 +1254,7 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
if (sreloc == NULL
|| ! bfd_set_section_flags (dynobj, sreloc, flags)
|| ! bfd_set_section_alignment (dynobj, sreloc, 3))
- return false;
+ return FALSE;
}
elf_section_data (sec)->sreloc = sreloc;
}
@@ -800,7 +1275,7 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
s = bfd_section_from_r_symndx (abfd, &htab->sym_sec,
sec, r_symndx);
if (s == NULL)
- return false;
+ return FALSE;
head = ((struct elf_s390_dyn_relocs **)
&elf_section_data (s)->local_dynrel);
@@ -813,7 +1288,7 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
p = ((struct elf_s390_dyn_relocs *)
bfd_alloc (htab->elf.dynobj, amt));
if (p == NULL)
- return false;
+ return FALSE;
p->next = *head;
*head = p;
p->sec = sec;
@@ -833,24 +1308,24 @@ elf_s390_check_relocs (abfd, info, sec, relocs)
/* This relocation describes the C++ object vtable hierarchy.
Reconstruct it for later use during GC. */
- case R_390_GNU_VTINHERIT:
- if (!_bfd_elf64_gc_record_vtinherit (abfd, sec, h, rel->r_offset))
- return false;
- break;
+ case R_390_GNU_VTINHERIT:
+ if (!bfd_elf_gc_record_vtinherit (abfd, sec, h, rel->r_offset))
+ return FALSE;
+ break;
/* This relocation describes which C++ vtable entries are actually
used. Record for later use during GC. */
- case R_390_GNU_VTENTRY:
- if (!_bfd_elf64_gc_record_vtentry (abfd, sec, h, rel->r_addend))
- return false;
- break;
+ case R_390_GNU_VTENTRY:
+ if (!bfd_elf_gc_record_vtentry (abfd, sec, h, rel->r_addend))
+ return FALSE;
+ break;
default:
break;
}
}
- return true;
+ return TRUE;
}
/* Return the section that should be marked against GC for a given
@@ -895,7 +1370,7 @@ elf_s390_gc_mark_hook (sec, info, rel, h, sym)
/* Update the got entry reference counts for the section being removed. */
-static boolean
+static bfd_boolean
elf_s390_gc_sweep_hook (abfd, info, sec, relocs)
bfd *abfd;
struct bfd_link_info *info;
@@ -906,8 +1381,6 @@ elf_s390_gc_sweep_hook (abfd, info, sec, relocs)
struct elf_link_hash_entry **sym_hashes;
bfd_signed_vma *local_got_refcounts;
const Elf_Internal_Rela *rel, *relend;
- unsigned long r_symndx;
- struct elf_link_hash_entry *h;
elf_section_data (sec)->local_dynrel = NULL;
@@ -917,87 +1390,147 @@ elf_s390_gc_sweep_hook (abfd, info, sec, relocs)
relend = relocs + sec->reloc_count;
for (rel = relocs; rel < relend; rel++)
- switch (ELF64_R_TYPE (rel->r_info))
- {
- case R_390_GOT12:
- case R_390_GOT16:
- case R_390_GOT32:
- case R_390_GOT64:
- case R_390_GOTOFF:
- case R_390_GOTPC:
- case R_390_GOTPCDBL:
- case R_390_GOTENT:
- r_symndx = ELF64_R_SYM (rel->r_info);
- if (r_symndx >= symtab_hdr->sh_info)
- {
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- if (h->got.refcount > 0)
- h->got.refcount -= 1;
- }
- else if (local_got_refcounts != NULL)
- {
- if (local_got_refcounts[r_symndx] > 0)
- local_got_refcounts[r_symndx] -= 1;
- }
- break;
-
- case R_390_8:
- case R_390_12:
- case R_390_16:
- case R_390_32:
- case R_390_64:
- case R_390_PC16:
- case R_390_PC16DBL:
- case R_390_PC32:
- case R_390_PC32DBL:
- case R_390_PC64:
- r_symndx = ELF64_R_SYM (rel->r_info);
- if (r_symndx >= symtab_hdr->sh_info)
- {
- struct elf_s390_link_hash_entry *eh;
- struct elf_s390_dyn_relocs **pp;
- struct elf_s390_dyn_relocs *p;
-
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
-
- if (!info->shared && h->plt.refcount > 0)
- h->plt.refcount -= 1;
-
- eh = (struct elf_s390_link_hash_entry *) h;
-
- for (pp = &eh->dyn_relocs; (p = *pp) != NULL; pp = &p->next)
- if (p->sec == sec)
+ {
+ unsigned long r_symndx;
+ unsigned int r_type;
+ struct elf_link_hash_entry *h = NULL;
+
+ r_symndx = ELF64_R_SYM (rel->r_info);
+ if (r_symndx >= symtab_hdr->sh_info)
+ {
+ struct elf_s390_link_hash_entry *eh;
+ struct elf_s390_dyn_relocs **pp;
+ struct elf_s390_dyn_relocs *p;
+
+ h = sym_hashes[r_symndx - symtab_hdr->sh_info];
+ eh = (struct elf_s390_link_hash_entry *) h;
+
+ for (pp = &eh->dyn_relocs; (p = *pp) != NULL; pp = &p->next)
+ if (p->sec == sec)
+ {
+ /* Everything must go for SEC. */
+ *pp = p->next;
+ break;
+ }
+ }
+
+ r_type = ELF64_R_TYPE (rel->r_info);
+ r_type = elf_s390_tls_transition (info, r_type, h != NULL);
+ switch (r_type)
+ {
+ case R_390_TLS_LDM64:
+ if (elf_s390_hash_table (info)->tls_ldm_got.refcount > 0)
+ elf_s390_hash_table (info)->tls_ldm_got.refcount -= 1;
+ break;
+
+ case R_390_TLS_GD64:
+ case R_390_TLS_IE64:
+ case R_390_TLS_GOTIE12:
+ case R_390_TLS_GOTIE20:
+ case R_390_TLS_GOTIE64:
+ case R_390_TLS_IEENT:
+ case R_390_GOT12:
+ case R_390_GOT16:
+ case R_390_GOT20:
+ case R_390_GOT32:
+ case R_390_GOT64:
+ case R_390_GOTOFF16:
+ case R_390_GOTOFF32:
+ case R_390_GOTOFF64:
+ case R_390_GOTPC:
+ case R_390_GOTPCDBL:
+ case R_390_GOTENT:
+ if (h != NULL)
+ {
+ if (h->got.refcount > 0)
+ h->got.refcount -= 1;
+ }
+ else if (local_got_refcounts != NULL)
+ {
+ if (local_got_refcounts[r_symndx] > 0)
+ local_got_refcounts[r_symndx] -= 1;
+ }
+ break;
+
+ case R_390_8:
+ case R_390_12:
+ case R_390_16:
+ case R_390_20:
+ case R_390_32:
+ case R_390_64:
+ case R_390_PC16:
+ case R_390_PC16DBL:
+ case R_390_PC32:
+ case R_390_PC32DBL:
+ case R_390_PC64:
+ if (info->shared)
+ break;
+ /* Fall through */
+
+ case R_390_PLT16DBL:
+ case R_390_PLT32:
+ case R_390_PLT32DBL:
+ case R_390_PLT64:
+ case R_390_PLTOFF16:
+ case R_390_PLTOFF32:
+ case R_390_PLTOFF64:
+ if (h != NULL)
+ {
+ if (h->plt.refcount > 0)
+ h->plt.refcount -= 1;
+ }
+ break;
+
+ case R_390_GOTPLT12:
+ case R_390_GOTPLT16:
+ case R_390_GOTPLT20:
+ case R_390_GOTPLT32:
+ case R_390_GOTPLT64:
+ case R_390_GOTPLTENT:
+ if (h != NULL)
+ {
+ if (h->plt.refcount > 0)
{
- if (ELF64_R_TYPE (rel->r_info) == R_390_PC16
- || ELF64_R_TYPE (rel->r_info) == R_390_PC16DBL
- || ELF64_R_TYPE (rel->r_info) == R_390_PC32)
- p->pc_count -= 1;
- p->count -= 1;
- if (p->count == 0)
- *pp = p->next;
- break;
+ ((struct elf_s390_link_hash_entry *) h)->gotplt_refcount--;
+ h->plt.refcount -= 1;
}
- }
- break;
-
- case R_390_PLT16DBL:
- case R_390_PLT32:
- case R_390_PLT32DBL:
- case R_390_PLT64:
- r_symndx = ELF64_R_SYM (rel->r_info);
- if (r_symndx >= symtab_hdr->sh_info)
- {
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- if (h->plt.refcount > 0)
- h->plt.refcount -= 1;
- }
- break;
-
- default:
- break;
- }
-
- return true;
+ }
+ else if (local_got_refcounts != NULL)
+ {
+ if (local_got_refcounts[r_symndx] > 0)
+ local_got_refcounts[r_symndx] -= 1;
+ }
+ break;
+
+ default:
+ break;
+ }
+ }
+
+ return TRUE;
+}
+
+/* Make sure we emit a GOT entry if the symbol was supposed to have a PLT
+ entry but we found we will not create any. Called when we find we will
+ not have any PLT for this symbol, by for example
+ elf_s390_adjust_dynamic_symbol when we're doing a proper dynamic link,
+ or elf_s390_size_dynamic_sections if no dynamic sections will be
+ created (we're only linking static objects). */
+
+static void
+elf_s390_adjust_gotplt (h)
+ struct elf_s390_link_hash_entry *h;
+{
+ if (h->elf.root.type == bfd_link_hash_warning)
+ h = (struct elf_s390_link_hash_entry *) h->elf.root.u.i.link;
+
+ if (h->gotplt_refcount <= 0)
+ return;
+
+ /* We simply add the number of gotplt references to the number
+ * of got references for this symbol. */
+ h->elf.got.refcount += h->gotplt_refcount;
+ h->gotplt_refcount = -1;
}
/* Adjust a symbol defined by a dynamic object and referenced by a
@@ -1006,14 +1539,12 @@ elf_s390_gc_sweep_hook (abfd, info, sec, relocs)
change the definition to something the rest of the link can
understand. */
-static boolean
+static bfd_boolean
elf_s390_adjust_dynamic_symbol (info, h)
struct bfd_link_info *info;
struct elf_link_hash_entry *h;
{
struct elf_s390_link_hash_table *htab;
- struct elf_s390_link_hash_entry * eh;
- struct elf_s390_dyn_relocs *p;
asection *s;
unsigned int power_of_two;
@@ -1031,15 +1562,16 @@ elf_s390_adjust_dynamic_symbol (info, h)
&& h->root.type != bfd_link_hash_undefined))
{
/* This case can occur if we saw a PLT32 reloc in an input
- file, but the symbol was never referred to by a dynamic
- object, or if all references were garbage collected. In
+ file, but the symbol was never referred to by a dynamic
+ object, or if all references were garbage collected. In
such a case, we don't actually need to build a procedure
linkage table, and we can just do a PC32 reloc instead. */
h->plt.offset = (bfd_vma) -1;
h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
+ elf_s390_adjust_gotplt((struct elf_s390_link_hash_entry *) h);
}
- return true;
+ return TRUE;
}
else
/* It's possible that we incorrectly decided a .plt reloc was
@@ -1058,7 +1590,11 @@ elf_s390_adjust_dynamic_symbol (info, h)
|| h->weakdef->root.type == bfd_link_hash_defweak);
h->root.u.def.section = h->weakdef->root.u.def.section;
h->root.u.def.value = h->weakdef->root.u.def.value;
- return true;
+ if (ELIMINATE_COPY_RELOCS || info->nocopyreloc)
+ h->elf_link_hash_flags
+ = ((h->elf_link_hash_flags & ~ELF_LINK_NON_GOT_REF)
+ | (h->weakdef->elf_link_hash_flags & ELF_LINK_NON_GOT_REF));
+ return TRUE;
}
/* This is a reference to a symbol defined by a dynamic object which
@@ -1069,34 +1605,40 @@ elf_s390_adjust_dynamic_symbol (info, h)
For such cases we need not do anything here; the relocations will
be handled correctly by relocate_section. */
if (info->shared)
- return true;
+ return TRUE;
/* If there are no references to this symbol that do not use the
GOT, we don't need to generate a copy reloc. */
if ((h->elf_link_hash_flags & ELF_LINK_NON_GOT_REF) == 0)
- return true;
+ return TRUE;
/* If -z nocopyreloc was given, we won't generate them either. */
if (info->nocopyreloc)
{
h->elf_link_hash_flags &= ~ELF_LINK_NON_GOT_REF;
- return true;
+ return TRUE;
}
- eh = (struct elf_s390_link_hash_entry *) h;
- for (p = eh->dyn_relocs; p != NULL; p = p->next)
+ if (ELIMINATE_COPY_RELOCS)
{
- s = p->sec->output_section;
- if (s != NULL && (s->flags & SEC_READONLY) != 0)
- break;
- }
+ struct elf_s390_link_hash_entry * eh;
+ struct elf_s390_dyn_relocs *p;
- /* If we didn't find any dynamic relocs in read-only sections, then
- we'll be keeping the dynamic relocs and avoiding the copy reloc. */
- if (p == NULL)
- {
- h->elf_link_hash_flags &= ~ELF_LINK_NON_GOT_REF;
- return true;
+ eh = (struct elf_s390_link_hash_entry *) h;
+ for (p = eh->dyn_relocs; p != NULL; p = p->next)
+ {
+ s = p->sec->output_section;
+ if (s != NULL && (s->flags & SEC_READONLY) != 0)
+ break;
+ }
+
+ /* If we didn't find any dynamic relocs in read-only sections, then
+ we'll be keeping the dynamic relocs and avoiding the copy reloc. */
+ if (p == NULL)
+ {
+ h->elf_link_hash_flags &= ~ELF_LINK_NON_GOT_REF;
+ return TRUE;
+ }
}
/* We must allocate the symbol in our .dynbss section, which will
@@ -1132,7 +1674,7 @@ elf_s390_adjust_dynamic_symbol (info, h)
if (power_of_two > bfd_get_section_alignment (htab->elf.dynobj, s))
{
if (! bfd_set_section_alignment (htab->elf.dynobj, s, power_of_two))
- return false;
+ return FALSE;
}
/* Define the symbol as being at this point in the section. */
@@ -1142,24 +1684,13 @@ elf_s390_adjust_dynamic_symbol (info, h)
/* Increment the section size to make room for the symbol. */
s->_raw_size += h->size;
- return true;
+ return TRUE;
}
-/* This is the condition under which elf_s390_finish_dynamic_symbol
- will be called from elflink.h. If elflink.h doesn't call our
- finish_dynamic_symbol routine, we'll need to do something about
- initializing any .plt and .got entries in elf_s390_relocate_section. */
-#define WILL_CALL_FINISH_DYNAMIC_SYMBOL(DYN, INFO, H) \
- ((DYN) \
- && ((INFO)->shared \
- || ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0) \
- && ((H)->dynindx != -1 \
- || ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0))
-
/* Allocate space in .plt, .got and associated reloc sections for
dynamic relocs. */
-static boolean
+static bfd_boolean
allocate_dynrelocs (h, inf)
struct elf_link_hash_entry *h;
PTR inf;
@@ -1170,27 +1701,33 @@ allocate_dynrelocs (h, inf)
struct elf_s390_dyn_relocs *p;
if (h->root.type == bfd_link_hash_indirect)
- return true;
+ return TRUE;
if (h->root.type == bfd_link_hash_warning)
+ /* When warning symbols are created, they **replace** the "real"
+ entry in the hash table, thus we never get to see the real
+ symbol in a hash traversal. So look at it now. */
h = (struct elf_link_hash_entry *) h->root.u.i.link;
info = (struct bfd_link_info *) inf;
htab = elf_s390_hash_table (info);
if (htab->elf.dynamic_sections_created
- && h->plt.refcount > 0)
+ && h->plt.refcount > 0
+ && (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak))
{
/* Make sure this symbol is output as a dynamic symbol.
Undefined weak syms won't yet be marked as dynamic. */
if (h->dynindx == -1
&& (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
{
- if (! bfd_elf64_link_record_dynamic_symbol (info, h))
- return false;
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
}
- if (WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, info, h))
+ if (info->shared
+ || WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, 0, h))
{
asection *s = htab->splt;
@@ -1227,33 +1764,69 @@ allocate_dynrelocs (h, inf)
{
h->plt.offset = (bfd_vma) -1;
h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
+ elf_s390_adjust_gotplt((struct elf_s390_link_hash_entry *) h);
}
}
else
{
h->plt.offset = (bfd_vma) -1;
h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
+ elf_s390_adjust_gotplt((struct elf_s390_link_hash_entry *) h);
}
- if (h->got.refcount > 0)
+ /* If R_390_TLS_{IE64,GOTIE64,GOTIE12,IEENT} symbol is now local to
+ the binary, we can optimize a bit. IE64 and GOTIE64 get converted
+ to R_390_TLS_LE64 requiring no TLS entry. For GOTIE12 and IEENT
+ we can save the dynamic TLS relocation. */
+ if (h->got.refcount > 0
+ && !info->shared
+ && h->dynindx == -1
+ && elf_s390_hash_entry(h)->tls_type >= GOT_TLS_IE)
+ {
+ if (elf_s390_hash_entry(h)->tls_type == GOT_TLS_IE_NLT)
+ /* For the GOTIE access without a literal pool entry the offset has
+ to be stored somewhere. The immediate value in the instruction
+ is not bit enough so the value is stored in the got. */
+ {
+ h->got.offset = htab->sgot->_raw_size;
+ htab->sgot->_raw_size += GOT_ENTRY_SIZE;
+ }
+ else
+ h->got.offset = (bfd_vma) -1;
+ }
+ else if (h->got.refcount > 0)
{
asection *s;
- boolean dyn;
+ bfd_boolean dyn;
+ int tls_type = elf_s390_hash_entry(h)->tls_type;
/* Make sure this symbol is output as a dynamic symbol.
Undefined weak syms won't yet be marked as dynamic. */
if (h->dynindx == -1
&& (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
{
- if (! bfd_elf64_link_record_dynamic_symbol (info, h))
- return false;
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
}
s = htab->sgot;
h->got.offset = s->_raw_size;
s->_raw_size += GOT_ENTRY_SIZE;
+ /* R_390_TLS_GD64 needs 2 consecutive GOT slots. */
+ if (tls_type == GOT_TLS_GD)
+ s->_raw_size += GOT_ENTRY_SIZE;
dyn = htab->elf.dynamic_sections_created;
- if (WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info, h))
+ /* R_390_TLS_IE64 needs one dynamic relocation,
+ R_390_TLS_GD64 needs one if local symbol and two if global. */
+ if ((tls_type == GOT_TLS_GD && h->dynindx == -1)
+ || tls_type >= GOT_TLS_IE)
+ htab->srelgot->_raw_size += sizeof (Elf64_External_Rela);
+ else if (tls_type == GOT_TLS_GD)
+ htab->srelgot->_raw_size += 2 * sizeof (Elf64_External_Rela);
+ else if ((ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak)
+ && (info->shared
+ || WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, 0, h)))
htab->srelgot->_raw_size += sizeof (Elf64_External_Rela);
}
else
@@ -1261,7 +1834,7 @@ allocate_dynrelocs (h, inf)
eh = (struct elf_s390_link_hash_entry *) h;
if (eh->dyn_relocs == NULL)
- return true;
+ return TRUE;
/* In the shared -Bsymbolic case, discard space allocated for
dynamic pc-relative relocs against symbols which turn out to be
@@ -1271,9 +1844,7 @@ allocate_dynrelocs (h, inf)
if (info->shared)
{
- if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0
- && ((h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0
- || info->symbolic))
+ if (SYMBOL_REFERENCES_LOCAL (info, h))
{
struct elf_s390_dyn_relocs **pp;
@@ -1287,8 +1858,14 @@ allocate_dynrelocs (h, inf)
pp = &p->next;
}
}
+
+ /* Also discard relocs on undefined weak syms with non-default
+ visibility. */
+ if (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+ && h->root.type == bfd_link_hash_undefweak)
+ eh->dyn_relocs = NULL;
}
- else
+ else if (ELIMINATE_COPY_RELOCS)
{
/* For the non-shared case, discard space for relocs against
symbols which turn out to need copy relocs or are not
@@ -1306,8 +1883,8 @@ allocate_dynrelocs (h, inf)
if (h->dynindx == -1
&& (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
{
- if (! bfd_elf64_link_record_dynamic_symbol (info, h))
- return false;
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
}
/* If that succeeded, we know we'll be keeping all the
@@ -1328,12 +1905,12 @@ allocate_dynrelocs (h, inf)
sreloc->_raw_size += p->count * sizeof (Elf64_External_Rela);
}
- return true;
+ return TRUE;
}
/* Find any dynamic relocs that apply to read-only sections. */
-static boolean
+static bfd_boolean
readonly_dynrelocs (h, inf)
struct elf_link_hash_entry *h;
PTR inf;
@@ -1356,15 +1933,15 @@ readonly_dynrelocs (h, inf)
info->flags |= DF_TEXTREL;
/* Not an error, just cut short the traversal. */
- return false;
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
/* Set the sizes of the dynamic sections. */
-static boolean
+static bfd_boolean
elf_s390_size_dynamic_sections (output_bfd, info)
bfd *output_bfd ATTRIBUTE_UNUSED;
struct bfd_link_info *info;
@@ -1372,7 +1949,7 @@ elf_s390_size_dynamic_sections (output_bfd, info)
struct elf_s390_link_hash_table *htab;
bfd *dynobj;
asection *s;
- boolean relocs;
+ bfd_boolean relocs;
bfd *ibfd;
htab = elf_s390_hash_table (info);
@@ -1383,7 +1960,7 @@ elf_s390_size_dynamic_sections (output_bfd, info)
if (htab->elf.dynamic_sections_created)
{
/* Set the contents of the .interp section to the interpreter. */
- if (! info->shared)
+ if (info->executable)
{
s = bfd_get_section_by_name (dynobj, ".interp");
if (s == NULL)
@@ -1399,6 +1976,7 @@ elf_s390_size_dynamic_sections (output_bfd, info)
{
bfd_signed_vma *local_got;
bfd_signed_vma *end_local_got;
+ char *local_tls_type;
bfd_size_type locsymcount;
Elf_Internal_Shdr *symtab_hdr;
asection *srela;
@@ -1440,14 +2018,17 @@ elf_s390_size_dynamic_sections (output_bfd, info)
symtab_hdr = &elf_tdata (ibfd)->symtab_hdr;
locsymcount = symtab_hdr->sh_info;
end_local_got = local_got + locsymcount;
+ local_tls_type = elf_s390_local_got_tls_type (ibfd);
s = htab->sgot;
srela = htab->srelgot;
- for (; local_got < end_local_got; ++local_got)
+ for (; local_got < end_local_got; ++local_got, ++local_tls_type)
{
if (*local_got > 0)
{
*local_got = s->_raw_size;
s->_raw_size += GOT_ENTRY_SIZE;
+ if (*local_tls_type == GOT_TLS_GD)
+ s->_raw_size += GOT_ENTRY_SIZE;
if (info->shared)
srela->_raw_size += sizeof (Elf64_External_Rela);
}
@@ -1456,13 +2037,24 @@ elf_s390_size_dynamic_sections (output_bfd, info)
}
}
+ if (htab->tls_ldm_got.refcount > 0)
+ {
+ /* Allocate 2 got entries and 1 dynamic reloc for R_390_TLS_LDM64
+ relocs. */
+ htab->tls_ldm_got.offset = htab->sgot->_raw_size;
+ htab->sgot->_raw_size += 2 * GOT_ENTRY_SIZE;
+ htab->srelgot->_raw_size += sizeof (Elf64_External_Rela);
+ }
+ else
+ htab->tls_ldm_got.offset = -1;
+
/* Allocate global sym .plt and .got entries, and space for global
sym dynamic relocs. */
elf_link_hash_traverse (&htab->elf, allocate_dynrelocs, (PTR) info);
/* We now have determined the sizes of the various dynamic sections.
Allocate memory for them. */
- relocs = false;
+ relocs = FALSE;
for (s = dynobj->sections; s != NULL; s = s->next)
{
if ((s->flags & SEC_LINKER_CREATED) == 0)
@@ -1478,7 +2070,7 @@ elf_s390_size_dynamic_sections (output_bfd, info)
else if (strncmp (bfd_get_section_name (dynobj, s), ".rela", 5) == 0)
{
if (s->_raw_size != 0 && s != htab->srelplt)
- relocs = true;
+ relocs = TRUE;
/* We use the reloc_count field as a counter if we need
to copy relocs into the output file. */
@@ -1513,7 +2105,7 @@ elf_s390_size_dynamic_sections (output_bfd, info)
of garbage. */
s->contents = (bfd_byte *) bfd_zalloc (dynobj, s->_raw_size);
if (s->contents == NULL)
- return false;
+ return FALSE;
}
if (htab->elf.dynamic_sections_created)
@@ -1524,12 +2116,12 @@ elf_s390_size_dynamic_sections (output_bfd, info)
the .dynamic section. The DT_DEBUG entry is filled in by the
dynamic linker and used by the debugger. */
#define add_dynamic_entry(TAG, VAL) \
- bfd_elf64_add_dynamic_entry (info, (bfd_vma) (TAG), (bfd_vma) (VAL))
+ _bfd_elf_add_dynamic_entry (info, TAG, VAL)
- if (! info->shared)
+ if (info->executable)
{
if (!add_dynamic_entry (DT_DEBUG, 0))
- return false;
+ return FALSE;
}
if (htab->splt->_raw_size != 0)
@@ -1538,15 +2130,15 @@ elf_s390_size_dynamic_sections (output_bfd, info)
|| !add_dynamic_entry (DT_PLTRELSZ, 0)
|| !add_dynamic_entry (DT_PLTREL, DT_RELA)
|| !add_dynamic_entry (DT_JMPREL, 0))
- return false;
+ return FALSE;
}
if (relocs)
- {
- if (!add_dynamic_entry (DT_RELA, 0)
- || !add_dynamic_entry (DT_RELASZ, 0)
- || !add_dynamic_entry (DT_RELAENT, sizeof (Elf64_External_Rela)))
- return false;
+ {
+ if (!add_dynamic_entry (DT_RELA, 0)
+ || !add_dynamic_entry (DT_RELASZ, 0)
+ || !add_dynamic_entry (DT_RELAENT, sizeof (Elf64_External_Rela)))
+ return FALSE;
/* If any dynamic relocs apply to a read-only section,
then we need a DT_TEXTREL entry. */
@@ -1557,18 +2149,68 @@ elf_s390_size_dynamic_sections (output_bfd, info)
if ((info->flags & DF_TEXTREL) != 0)
{
if (!add_dynamic_entry (DT_TEXTREL, 0))
- return false;
+ return FALSE;
}
}
}
#undef add_dynamic_entry
- return true;
+ return TRUE;
+}
+
+/* Return the base VMA address which should be subtracted from real addresses
+ when resolving @dtpoff relocation.
+ This is PT_TLS segment p_vaddr. */
+
+static bfd_vma
+dtpoff_base (info)
+ struct bfd_link_info *info;
+{
+ /* If tls_sec is NULL, we should have signalled an error already. */
+ if (elf_hash_table (info)->tls_sec == NULL)
+ return 0;
+ return elf_hash_table (info)->tls_sec->vma;
+}
+
+/* Return the relocation value for @tpoff relocation
+ if STT_TLS virtual address is ADDRESS. */
+
+static bfd_vma
+tpoff (info, address)
+ struct bfd_link_info *info;
+ bfd_vma address;
+{
+ struct elf_link_hash_table *htab = elf_hash_table (info);
+
+ /* If tls_sec is NULL, we should have signalled an error already. */
+ if (htab->tls_sec == NULL)
+ return 0;
+ return htab->tls_size + htab->tls_sec->vma - address;
+}
+
+/* Complain if TLS instruction relocation is against an invalid
+ instruction. */
+
+static void
+invalid_tls_insn (input_bfd, input_section, rel)
+ bfd *input_bfd;
+ asection *input_section;
+ Elf_Internal_Rela *rel;
+{
+ reloc_howto_type *howto;
+
+ howto = elf_howto_table + ELF64_R_TYPE (rel->r_info);
+ (*_bfd_error_handler)
+ (_("%s(%s+0x%lx): invalid instruction for TLS relocation %s"),
+ bfd_archive_filename (input_bfd),
+ bfd_get_section_name (input_bfd, input_section),
+ (long) rel->r_offset,
+ howto->name);
}
/* Relocate a 390 ELF section. */
-static boolean
+static bfd_boolean
elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
contents, relocs, local_syms, local_sections)
bfd *output_bfd;
@@ -1587,8 +2229,8 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
Elf_Internal_Rela *rel;
Elf_Internal_Rela *relend;
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
htab = elf_s390_hash_table (info);
symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
@@ -1599,7 +2241,7 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
relend = relocs + input_section->reloc_count;
for (; rel < relend; rel++)
{
- int r_type;
+ unsigned int r_type;
reloc_howto_type *howto;
unsigned long r_symndx;
struct elf_link_hash_entry *h;
@@ -1607,256 +2249,287 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
asection *sec;
bfd_vma off;
bfd_vma relocation;
- boolean unresolved_reloc;
+ bfd_boolean unresolved_reloc;
bfd_reloc_status_type r;
+ int tls_type;
r_type = ELF64_R_TYPE (rel->r_info);
if (r_type == (int) R_390_GNU_VTINHERIT
- || r_type == (int) R_390_GNU_VTENTRY)
- continue;
- if (r_type < 0 || r_type >= (int) R_390_max)
+ || r_type == (int) R_390_GNU_VTENTRY)
+ continue;
+ if (r_type >= (int) R_390_max)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
howto = elf_howto_table + r_type;
r_symndx = ELF64_R_SYM (rel->r_info);
+
+ /* This is a final link. */
h = NULL;
sym = NULL;
sec = NULL;
- unresolved_reloc = false;
+ unresolved_reloc = FALSE;
if (r_symndx < symtab_hdr->sh_info)
{
sym = local_syms + r_symndx;
sec = local_sections[r_symndx];
- relocation = _bfd_elf_rela_local_sym (output_bfd, sym, sec, rel);
+ relocation = _bfd_elf_rela_local_sym (output_bfd, sym, &sec, rel);
}
else
{
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- while (h->root.type == bfd_link_hash_indirect
- || h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
+ bfd_boolean warned ATTRIBUTE_UNUSED;
- if (h->root.type == bfd_link_hash_defined
- || h->root.type == bfd_link_hash_defweak)
- {
- sec = h->root.u.def.section;
- if (sec->output_section == NULL)
- {
- /* Set a flag that will be cleared later if we find a
- relocation value for this symbol. output_section
- is typically NULL for symbols satisfied by a shared
- library. */
- unresolved_reloc = true;
- relocation = 0;
- }
- else
- relocation = (h->root.u.def.value
- + sec->output_section->vma
- + sec->output_offset);
- }
- else if (h->root.type == bfd_link_hash_undefweak)
- relocation = 0;
- else if (info->shared
- && (!info->symbolic || info->allow_shlib_undefined)
- && !info->no_undefined
- && ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
- relocation = 0;
- else
- {
- if (! ((*info->callbacks->undefined_symbol)
- (info, h->root.root.string, input_bfd,
- input_section, rel->r_offset,
- (!info->shared || info->no_undefined
- || ELF_ST_VISIBILITY (h->other)))))
- return false;
- relocation = 0;
- }
+ RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
+ r_symndx, symtab_hdr, sym_hashes,
+ h, sec, relocation,
+ unresolved_reloc, warned);
}
switch (r_type)
{
- case R_390_GOT12:
- case R_390_GOT16:
- case R_390_GOT32:
- case R_390_GOT64:
- case R_390_GOTENT:
- /* Relocation is to the entry for this symbol in the global
- offset table. */
+ case R_390_GOTPLT12:
+ case R_390_GOTPLT16:
+ case R_390_GOTPLT20:
+ case R_390_GOTPLT32:
+ case R_390_GOTPLT64:
+ case R_390_GOTPLTENT:
+ /* There are three cases for a GOTPLT relocation. 1) The
+ relocation is against the jump slot entry of a plt that
+ will get emitted to the output file. 2) The relocation
+ is against the jump slot of a plt entry that has been
+ removed. elf_s390_adjust_gotplt has created a GOT entry
+ as replacement. 3) The relocation is against a local symbol.
+ Cases 2) and 3) are the same as the GOT relocation code
+ so we just have to test for case 1 and fall through for
+ the other two. */
+ if (h != NULL && h->plt.offset != (bfd_vma) -1)
+ {
+ bfd_vma plt_index;
+
+ /* Calc. index no.
+ Current offset - size first entry / entry size. */
+ plt_index = (h->plt.offset - PLT_FIRST_ENTRY_SIZE) /
+ PLT_ENTRY_SIZE;
+
+ /* Offset in GOT is PLT index plus GOT headers(3) times 4,
+ addr & GOT addr. */
+ relocation = (plt_index + 3) * GOT_ENTRY_SIZE;
+ unresolved_reloc = FALSE;
+
+ if (r_type == R_390_GOTPLTENT)
+ relocation += htab->sgot->output_section->vma;
+ break;
+ }
+ /* Fall through. */
+
+ case R_390_GOT12:
+ case R_390_GOT16:
+ case R_390_GOT20:
+ case R_390_GOT32:
+ case R_390_GOT64:
+ case R_390_GOTENT:
+ /* Relocation is to the entry for this symbol in the global
+ offset table. */
if (htab->sgot == NULL)
abort ();
- if (h != NULL)
- {
- boolean dyn;
+ if (h != NULL)
+ {
+ bfd_boolean dyn;
- off = h->got.offset;
+ off = h->got.offset;
dyn = htab->elf.dynamic_sections_created;
- if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info, h)
- || (info->shared
- && (info->symbolic
+ if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info->shared, h)
+ || (info->shared
+ && (info->symbolic
|| h->dynindx == -1
|| (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL))
- && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR)))
- {
- /* This is actually a static link, or it is a
- -Bsymbolic link and the symbol is defined
- locally, or the symbol was forced to be local
- because of a version file. We must initialize
- this entry in the global offset table. Since the
- offset must always be a multiple of 2, we use the
- least significant bit to record whether we have
- initialized it already.
-
- When doing a dynamic link, we create a .rel.got
- relocation entry to initialize the value. This
- is done in the finish_dynamic_symbol routine. */
- if ((off & 1) != 0)
- off &= ~1;
- else
- {
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR))
+ || (ELF_ST_VISIBILITY (h->other)
+ && h->root.type == bfd_link_hash_undefweak))
+ {
+ /* This is actually a static link, or it is a
+ -Bsymbolic link and the symbol is defined
+ locally, or the symbol was forced to be local
+ because of a version file. We must initialize
+ this entry in the global offset table. Since the
+ offset must always be a multiple of 2, we use the
+ least significant bit to record whether we have
+ initialized it already.
+
+ When doing a dynamic link, we create a .rel.got
+ relocation entry to initialize the value. This
+ is done in the finish_dynamic_symbol routine. */
+ if ((off & 1) != 0)
+ off &= ~1;
+ else
+ {
bfd_put_64 (output_bfd, relocation,
htab->sgot->contents + off);
- h->got.offset |= 1;
- }
- }
+ h->got.offset |= 1;
+ }
+ }
else
- unresolved_reloc = false;
- }
- else
- {
+ unresolved_reloc = FALSE;
+ }
+ else
+ {
if (local_got_offsets == NULL)
abort ();
- off = local_got_offsets[r_symndx];
+ off = local_got_offsets[r_symndx];
- /* The offset must always be a multiple of 8. We use
- the least significant bit to record whether we have
- already generated the necessary reloc. */
- if ((off & 1) != 0)
- off &= ~1;
- else
- {
- bfd_put_64 (output_bfd, relocation,
+ /* The offset must always be a multiple of 8. We use
+ the least significant bit to record whether we have
+ already generated the necessary reloc. */
+ if ((off & 1) != 0)
+ off &= ~1;
+ else
+ {
+ bfd_put_64 (output_bfd, relocation,
htab->sgot->contents + off);
- if (info->shared)
- {
- asection *srelgot;
- Elf_Internal_Rela outrel;
- Elf64_External_Rela *loc;
+ if (info->shared)
+ {
+ asection *s;
+ Elf_Internal_Rela outrel;
+ bfd_byte *loc;
- srelgot = htab->srelgot;
- if (srelgot == NULL)
+ s = htab->srelgot;
+ if (s == NULL)
abort ();
- outrel.r_offset = (htab->sgot->output_section->vma
- + htab->sgot->output_offset
- + off);
- outrel.r_info = ELF64_R_INFO (0, R_390_RELATIVE);
+ outrel.r_offset = (htab->sgot->output_section->vma
+ + htab->sgot->output_offset
+ + off);
+ outrel.r_info = ELF64_R_INFO (0, R_390_RELATIVE);
outrel.r_addend = relocation;
- loc = (Elf64_External_Rela *) srelgot->contents;
- loc += srelgot->reloc_count++;
- bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
- }
+ loc = s->contents;
+ loc += s->reloc_count++ * sizeof (Elf64_External_Rela);
+ bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
+ }
- local_got_offsets[r_symndx] |= 1;
- }
- }
+ local_got_offsets[r_symndx] |= 1;
+ }
+ }
if (off >= (bfd_vma) -2)
abort ();
relocation = htab->sgot->output_offset + off;
- /*
- * For @GOTENT the relocation is against the offset between
- * the instruction and the symbols entry in the GOT and not
- * between the start of the GOT and the symbols entry. We
- * add the vma of the GOT to get the correct value.
- */
- if (r_type == R_390_GOTENT)
+ /* For @GOTENT the relocation is against the offset between
+ the instruction and the symbols entry in the GOT and not
+ between the start of the GOT and the symbols entry. We
+ add the vma of the GOT to get the correct value. */
+ if ( r_type == R_390_GOTENT
+ || r_type == R_390_GOTPLTENT)
relocation += htab->sgot->output_section->vma;
- break;
+ break;
+
+ case R_390_GOTOFF16:
+ case R_390_GOTOFF32:
+ case R_390_GOTOFF64:
+ /* Relocation is relative to the start of the global offset
+ table. */
+
+ /* Note that sgot->output_offset is not involved in this
+ calculation. We always want the start of .got. If we
+ defined _GLOBAL_OFFSET_TABLE in a different way, as is
+ permitted by the ABI, we might have to change this
+ calculation. */
+ relocation -= htab->sgot->output_section->vma;
+ break;
+
+ case R_390_GOTPC:
+ case R_390_GOTPCDBL:
+ /* Use global offset table as symbol value. */
+ relocation = htab->sgot->output_section->vma;
+ unresolved_reloc = FALSE;
+ break;
- case R_390_GOTOFF:
- /* Relocation is relative to the start of the global offset
- table. */
+ case R_390_PLT16DBL:
+ case R_390_PLT32:
+ case R_390_PLT32DBL:
+ case R_390_PLT64:
+ /* Relocation is to the entry for this symbol in the
+ procedure linkage table. */
- /* Note that sgot->output_offset is not involved in this
- calculation. We always want the start of .got. If we
- defined _GLOBAL_OFFSET_TABLE in a different way, as is
- permitted by the ABI, we might have to change this
- calculation. */
- relocation -= htab->sgot->output_section->vma;
+ /* Resolve a PLT32 reloc against a local symbol directly,
+ without using the procedure linkage table. */
+ if (h == NULL)
+ break;
- break;
+ if (h->plt.offset == (bfd_vma) -1
+ || htab->splt == NULL)
+ {
+ /* We didn't make a PLT entry for this symbol. This
+ happens when statically linking PIC code, or when
+ using -Bsymbolic. */
+ break;
+ }
- case R_390_GOTPC:
- case R_390_GOTPCDBL:
- /* Use global offset table as symbol value. */
- relocation = htab->sgot->output_section->vma;
- unresolved_reloc = false;
- break;
-
- case R_390_PLT16DBL:
- case R_390_PLT32:
- case R_390_PLT32DBL:
- case R_390_PLT64:
- /* Relocation is to the entry for this symbol in the
- procedure linkage table. */
-
- /* Resolve a PLT32 reloc against a local symbol directly,
- without using the procedure linkage table. */
- if (h == NULL)
- break;
-
- if (h->plt.offset == (bfd_vma) -1
+ relocation = (htab->splt->output_section->vma
+ + htab->splt->output_offset
+ + h->plt.offset);
+ unresolved_reloc = FALSE;
+ break;
+
+ case R_390_PLTOFF16:
+ case R_390_PLTOFF32:
+ case R_390_PLTOFF64:
+ /* Relocation is to the entry for this symbol in the
+ procedure linkage table relative to the start of the GOT. */
+
+ /* For local symbols or if we didn't make a PLT entry for
+ this symbol resolve the symbol directly. */
+ if ( h == NULL
+ || h->plt.offset == (bfd_vma) -1
|| htab->splt == NULL)
- {
- /* We didn't make a PLT entry for this symbol. This
- happens when statically linking PIC code, or when
- using -Bsymbolic. */
- break;
- }
-
- relocation = (htab->splt->output_section->vma
- + htab->splt->output_offset
- + h->plt.offset);
- unresolved_reloc = false;
- break;
-
- case R_390_8:
- case R_390_16:
- case R_390_32:
- case R_390_64:
- case R_390_PC16:
- case R_390_PC16DBL:
- case R_390_PC32:
+ {
+ relocation -= htab->sgot->output_section->vma;
+ break;
+ }
+
+ relocation = (htab->splt->output_section->vma
+ + htab->splt->output_offset
+ + h->plt.offset
+ - htab->sgot->output_section->vma);
+ unresolved_reloc = FALSE;
+ break;
+
+ case R_390_8:
+ case R_390_16:
+ case R_390_32:
+ case R_390_64:
+ case R_390_PC16:
+ case R_390_PC16DBL:
+ case R_390_PC32:
case R_390_PC32DBL:
- case R_390_PC64:
+ case R_390_PC64:
/* r_symndx will be zero only for relocs against symbols
from removed linkonce sections, or sections discarded by
a linker script. */
- if (r_symndx == 0
- || (input_section->flags & SEC_ALLOC) == 0)
+ if (r_symndx == 0
+ || (input_section->flags & SEC_ALLOC) == 0)
break;
- if ((info->shared
+ if ((info->shared
+ && (h == NULL
+ || ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak)
&& ((r_type != R_390_PC16
&& r_type != R_390_PC16DBL
&& r_type != R_390_PC32
&& r_type != R_390_PC32DBL
&& r_type != R_390_PC64)
|| (h != NULL
- && h->dynindx != -1
- && (! info->symbolic
- || (h->elf_link_hash_flags
- & ELF_LINK_HASH_DEF_REGULAR) == 0))))
- || (!info->shared
+ && !SYMBOL_REFERENCES_LOCAL (info, h))))
+ || (ELIMINATE_COPY_RELOCS
+ && !info->shared
&& h != NULL
&& h->dynindx != -1
&& (h->elf_link_hash_flags & ELF_LINK_NON_GOT_REF) == 0
@@ -1866,33 +2539,32 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
& ELF_LINK_HASH_DEF_REGULAR) == 0)
|| h->root.type == bfd_link_hash_undefweak
|| h->root.type == bfd_link_hash_undefined)))
- {
- Elf_Internal_Rela outrel;
- boolean skip, relocate;
+ {
+ Elf_Internal_Rela outrel;
+ bfd_boolean skip, relocate;
asection *sreloc;
- Elf64_External_Rela *loc;
+ bfd_byte *loc;
- /* When generating a shared object, these relocations
- are copied into the output file to be resolved at run
- time. */
-
- skip = false;
- relocate = false;
+ /* When generating a shared object, these relocations
+ are copied into the output file to be resolved at run
+ time. */
+ skip = FALSE;
+ relocate = FALSE;
outrel.r_offset =
_bfd_elf_section_offset (output_bfd, info, input_section,
rel->r_offset);
if (outrel.r_offset == (bfd_vma) -1)
- skip = true;
+ skip = TRUE;
else if (outrel.r_offset == (bfd_vma) -2)
- skip = true, relocate = true;
+ skip = TRUE, relocate = TRUE;
- outrel.r_offset += (input_section->output_section->vma
- + input_section->output_offset);
+ outrel.r_offset += (input_section->output_section->vma
+ + input_section->output_offset);
- if (skip)
+ if (skip)
memset (&outrel, 0, sizeof outrel);
- else if (h != NULL
+ else if (h != NULL
&& h->dynindx != -1
&& (r_type == R_390_PC16
|| r_type == R_390_PC16DBL
@@ -1903,39 +2575,412 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
|| !info->symbolic
|| (h->elf_link_hash_flags
& ELF_LINK_HASH_DEF_REGULAR) == 0))
- {
- outrel.r_info = ELF64_R_INFO (h->dynindx, r_type);
+ {
+ outrel.r_info = ELF64_R_INFO (h->dynindx, r_type);
outrel.r_addend = rel->r_addend;
- }
- else
- {
+ }
+ else
+ {
/* This symbol is local, or marked to become local. */
- relocate = true;
- outrel.r_info = ELF64_R_INFO (0, R_390_RELATIVE);
outrel.r_addend = relocation + rel->r_addend;
+ if (r_type == R_390_64)
+ {
+ relocate = TRUE;
+ outrel.r_info = ELF64_R_INFO (0, R_390_RELATIVE);
+ }
+ else
+ {
+ long sindx;
+
+ if (bfd_is_abs_section (sec))
+ sindx = 0;
+ else if (sec == NULL || sec->owner == NULL)
+ {
+ bfd_set_error(bfd_error_bad_value);
+ return FALSE;
+ }
+ else
+ {
+ asection *osec;
+
+ osec = sec->output_section;
+ sindx = elf_section_data (osec)->dynindx;
+ BFD_ASSERT (sindx > 0);
+
+ /* We are turning this relocation into one
+ against a section symbol, so subtract out
+ the output section's address but not the
+ offset of the input section in the output
+ section. */
+
+ outrel.r_addend -= osec->vma;
+ }
+ outrel.r_info = ELF64_R_INFO (sindx, r_type);
+ }
+ }
+
+ sreloc = elf_section_data (input_section)->sreloc;
+ if (sreloc == NULL)
+ abort ();
+
+ loc = sreloc->contents;
+ loc += sreloc->reloc_count++ * sizeof (Elf64_External_Rela);
+ bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
+
+ /* If this reloc is against an external symbol, we do
+ not want to fiddle with the addend. Otherwise, we
+ need to include the symbol value so that it becomes
+ an addend for the dynamic reloc. */
+ if (! relocate)
+ continue;
+ }
+
+ break;
+
+ /* Relocations for tls literal pool entries. */
+ case R_390_TLS_IE64:
+ if (info->shared)
+ {
+ Elf_Internal_Rela outrel;
+ asection *sreloc;
+ bfd_byte *loc;
+
+ outrel.r_offset = rel->r_offset
+ + input_section->output_section->vma
+ + input_section->output_offset;
+ outrel.r_info = ELF64_R_INFO (0, R_390_RELATIVE);
+ sreloc = elf_section_data (input_section)->sreloc;
+ if (sreloc == NULL)
+ abort ();
+ loc = sreloc->contents;
+ loc += sreloc->reloc_count++ * sizeof (Elf64_External_Rela);
+ bfd_elf64_swap_reloc_out (output_bfd, &outrel, loc);
+ }
+ /* Fall through. */
+
+ case R_390_TLS_GD64:
+ case R_390_TLS_GOTIE64:
+ r_type = elf_s390_tls_transition (info, r_type, h == NULL);
+ tls_type = GOT_UNKNOWN;
+ if (h == NULL && local_got_offsets)
+ tls_type = elf_s390_local_got_tls_type (input_bfd) [r_symndx];
+ else if (h != NULL)
+ {
+ tls_type = elf_s390_hash_entry(h)->tls_type;
+ if (!info->shared && h->dynindx == -1 && tls_type >= GOT_TLS_IE)
+ r_type = R_390_TLS_LE64;
+ }
+ if (r_type == R_390_TLS_GD64 && tls_type >= GOT_TLS_IE)
+ r_type = R_390_TLS_IE64;
+
+ if (r_type == R_390_TLS_LE64)
+ {
+ /* This relocation gets optimized away by the local exec
+ access optimization. */
+ BFD_ASSERT (! unresolved_reloc);
+ bfd_put_64 (output_bfd, -tpoff (info, relocation),
+ contents + rel->r_offset);
+ continue;
+ }
+
+ if (htab->sgot == NULL)
+ abort ();
+
+ if (h != NULL)
+ off = h->got.offset;
+ else
+ {
+ if (local_got_offsets == NULL)
+ abort ();
+
+ off = local_got_offsets[r_symndx];
+ }
+
+ emit_tls_relocs:
+
+ if ((off & 1) != 0)
+ off &= ~1;
+ else
+ {
+ Elf_Internal_Rela outrel;
+ bfd_byte *loc;
+ int dr_type, indx;
+
+ if (htab->srelgot == NULL)
+ abort ();
+
+ outrel.r_offset = (htab->sgot->output_section->vma
+ + htab->sgot->output_offset + off);
+
+ indx = h && h->dynindx != -1 ? h->dynindx : 0;
+ if (r_type == R_390_TLS_GD64)
+ dr_type = R_390_TLS_DTPMOD;
+ else
+ dr_type = R_390_TLS_TPOFF;
+ if (dr_type == R_390_TLS_TPOFF && indx == 0)
+ outrel.r_addend = relocation - dtpoff_base (info);
+ else
+ outrel.r_addend = 0;
+ outrel.r_info = ELF64_R_INFO (indx, dr_type);
+ loc = htab->srelgot->contents;
+ loc += htab->srelgot->reloc_count++
+ * sizeof (Elf64_External_Rela);
+ bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
+
+ if (r_type == R_390_TLS_GD64)
+ {
+ if (indx == 0)
+ {
+ BFD_ASSERT (! unresolved_reloc);
+ bfd_put_64 (output_bfd,
+ relocation - dtpoff_base (info),
+ htab->sgot->contents + off + GOT_ENTRY_SIZE);
+ }
+ else
+ {
+ outrel.r_info = ELF64_R_INFO (indx, R_390_TLS_DTPOFF);
+ outrel.r_offset += GOT_ENTRY_SIZE;
+ outrel.r_addend = 0;
+ htab->srelgot->reloc_count++;
+ loc += sizeof (Elf64_External_Rela);
+ bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
+ }
}
+ if (h != NULL)
+ h->got.offset |= 1;
+ else
+ local_got_offsets[r_symndx] |= 1;
+ }
+
+ if (off >= (bfd_vma) -2)
+ abort ();
+ if (r_type == ELF64_R_TYPE (rel->r_info))
+ {
+ relocation = htab->sgot->output_offset + off;
+ if (r_type == R_390_TLS_IE64 || r_type == R_390_TLS_IEENT)
+ relocation += htab->sgot->output_section->vma;
+ unresolved_reloc = FALSE;
+ }
+ else
+ {
+ bfd_put_64 (output_bfd, htab->sgot->output_offset + off,
+ contents + rel->r_offset);
+ continue;
+ }
+ break;
+
+ case R_390_TLS_GOTIE12:
+ case R_390_TLS_GOTIE20:
+ case R_390_TLS_IEENT:
+ if (h == NULL)
+ {
+ if (local_got_offsets == NULL)
+ abort();
+ off = local_got_offsets[r_symndx];
+ if (info->shared)
+ goto emit_tls_relocs;
+ }
+ else
+ {
+ off = h->got.offset;
+ tls_type = elf_s390_hash_entry(h)->tls_type;
+ if (info->shared || h->dynindx != -1 || tls_type < GOT_TLS_IE)
+ goto emit_tls_relocs;
+ }
+
+ if (htab->sgot == NULL)
+ abort ();
+
+ BFD_ASSERT (! unresolved_reloc);
+ bfd_put_64 (output_bfd, -tpoff (info, relocation),
+ htab->sgot->contents + off);
+ relocation = htab->sgot->output_offset + off;
+ if (r_type == R_390_TLS_IEENT)
+ relocation += htab->sgot->output_section->vma;
+ unresolved_reloc = FALSE;
+ break;
+
+ case R_390_TLS_LDM64:
+ if (! info->shared)
+ /* The literal pool entry this relocation refers to gets ignored
+ by the optimized code of the local exec model. Do nothing
+ and the value will turn out zero. */
+ continue;
+
+ if (htab->sgot == NULL)
+ abort ();
+
+ off = htab->tls_ldm_got.offset;
+ if (off & 1)
+ off &= ~1;
+ else
+ {
+ Elf_Internal_Rela outrel;
+ bfd_byte *loc;
+
+ if (htab->srelgot == NULL)
+ abort ();
+
+ outrel.r_offset = (htab->sgot->output_section->vma
+ + htab->sgot->output_offset + off);
+
+ bfd_put_64 (output_bfd, 0,
+ htab->sgot->contents + off + GOT_ENTRY_SIZE);
+ outrel.r_info = ELF64_R_INFO (0, R_390_TLS_DTPMOD);
+ outrel.r_addend = 0;
+ loc = htab->srelgot->contents;
+ loc += htab->srelgot->reloc_count++
+ * sizeof (Elf64_External_Rela);
+ bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
+ htab->tls_ldm_got.offset |= 1;
+ }
+ relocation = htab->sgot->output_offset + off;
+ unresolved_reloc = FALSE;
+ break;
+
+ case R_390_TLS_LE64:
+ if (info->shared)
+ {
+ /* Linking a shared library with non-fpic code requires
+ a R_390_TLS_TPOFF relocation. */
+ Elf_Internal_Rela outrel;
+ asection *sreloc;
+ bfd_byte *loc;
+ int indx;
+
+ outrel.r_offset = rel->r_offset
+ + input_section->output_section->vma
+ + input_section->output_offset;
+ if (h != NULL && h->dynindx != -1)
+ indx = h->dynindx;
+ else
+ indx = 0;
+ outrel.r_info = ELF64_R_INFO (indx, R_390_TLS_TPOFF);
+ if (indx == 0)
+ outrel.r_addend = relocation - dtpoff_base (info);
+ else
+ outrel.r_addend = 0;
sreloc = elf_section_data (input_section)->sreloc;
if (sreloc == NULL)
abort ();
+ loc = sreloc->contents;
+ loc += sreloc->reloc_count++ * sizeof (Elf64_External_Rela);
+ bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
+ }
+ else
+ {
+ BFD_ASSERT (! unresolved_reloc);
+ bfd_put_64 (output_bfd, -tpoff (info, relocation),
+ contents + rel->r_offset);
+ }
+ continue;
- loc = (Elf64_External_Rela *) sreloc->contents;
- loc += sreloc->reloc_count++;
- bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
+ case R_390_TLS_LDO64:
+ if (info->shared || (input_section->flags & SEC_CODE) == 0)
+ relocation -= dtpoff_base (info);
+ else
+ /* When converting LDO to LE, we must negate. */
+ relocation = -tpoff (info, relocation);
+ break;
- /* If this reloc is against an external symbol, we do
- not want to fiddle with the addend. Otherwise, we
- need to include the symbol value so that it becomes
- an addend for the dynamic reloc. */
- if (! relocate)
- continue;
- }
+ /* Relocations for tls instructions. */
+ case R_390_TLS_LOAD:
+ case R_390_TLS_GDCALL:
+ case R_390_TLS_LDCALL:
+ tls_type = GOT_UNKNOWN;
+ if (h == NULL && local_got_offsets)
+ tls_type = elf_s390_local_got_tls_type (input_bfd) [r_symndx];
+ else if (h != NULL)
+ tls_type = elf_s390_hash_entry(h)->tls_type;
+
+ if (tls_type == GOT_TLS_GD)
+ continue;
+
+ if (r_type == R_390_TLS_LOAD)
+ {
+ if (!info->shared && (h == NULL || h->dynindx == -1))
+ {
+ /* IE->LE transition. Four valid cases:
+ lg %rx,(0,%ry) -> sllg %rx,%ry,0
+ lg %rx,(%ry,0) -> sllg %rx,%ry,0
+ lg %rx,(%ry,%r12) -> sllg %rx,%ry,0
+ lg %rx,(%r12,%ry) -> sllg %rx,%ry,0 */
+ unsigned int insn0, insn1, ry;
+
+ insn0 = bfd_get_32 (input_bfd, contents + rel->r_offset);
+ insn1 = bfd_get_16 (input_bfd, contents + rel->r_offset + 4);
+ if (insn1 != 0x0004)
+ invalid_tls_insn (input_bfd, input_section, rel);
+ ry = 0;
+ if ((insn0 & 0xff00f000) == 0xe3000000)
+ /* lg %rx,0(%ry,0) -> sllg %rx,%ry,0 */
+ ry = (insn0 & 0x000f0000);
+ else if ((insn0 & 0xff0f0000) == 0xe3000000)
+ /* lg %rx,0(0,%ry) -> sllg %rx,%ry,0 */
+ ry = (insn0 & 0x0000f000) << 4;
+ else if ((insn0 & 0xff00f000) == 0xe300c000)
+ /* lg %rx,0(%ry,%r12) -> sllg %rx,%ry,0 */
+ ry = (insn0 & 0x000f0000);
+ else if ((insn0 & 0xff0f0000) == 0xe30c0000)
+ /* lg %rx,0(%r12,%ry) -> sllg %rx,%ry,0 */
+ ry = (insn0 & 0x0000f000) << 4;
+ else
+ invalid_tls_insn (input_bfd, input_section, rel);
+ insn0 = 0xeb000000 | (insn0 & 0x00f00000) | ry;
+ insn1 = 0x000d;
+ bfd_put_32 (output_bfd, insn0, contents + rel->r_offset);
+ bfd_put_16 (output_bfd, insn1, contents + rel->r_offset + 4);
+ }
+ }
+ else if (r_type == R_390_TLS_GDCALL)
+ {
+ unsigned int insn0, insn1;
- break;
+ insn0 = bfd_get_32 (input_bfd, contents + rel->r_offset);
+ insn1 = bfd_get_16 (input_bfd, contents + rel->r_offset + 4);
+ if ((insn0 & 0xffff0000) != 0xc0e50000)
+ invalid_tls_insn (input_bfd, input_section, rel);
+ if (!info->shared && (h == NULL || h->dynindx == -1))
+ {
+ /* GD->LE transition.
+ brasl %r14,__tls_get_addr@plt -> brcl 0,. */
+ insn0 = 0xc0040000;
+ insn1 = 0x0000;
+ }
+ else
+ {
+ /* GD->IE transition.
+ brasl %r14,__tls_get_addr@plt -> lg %r2,0(%r2,%r12) */
+ insn0 = 0xe322c000;
+ insn1 = 0x0004;
+ }
+ bfd_put_32 (output_bfd, insn0, contents + rel->r_offset);
+ bfd_put_16 (output_bfd, insn1, contents + rel->r_offset + 4);
+ }
+ else if (r_type == R_390_TLS_LDCALL)
+ {
+ if (!info->shared)
+ {
+ unsigned int insn0, insn1;
+
+ insn0 = bfd_get_32 (input_bfd, contents + rel->r_offset);
+ insn1 = bfd_get_16 (input_bfd, contents + rel->r_offset + 4);
+ if ((insn0 & 0xffff0000) != 0xc0e50000)
+ invalid_tls_insn (input_bfd, input_section, rel);
+ /* LD->LE transition.
+ brasl %r14,__tls_get_addr@plt -> brcl 0,. */
+ insn0 = 0xc0040000;
+ insn1 = 0x0000;
+ bfd_put_32 (output_bfd, insn0, contents + rel->r_offset);
+ bfd_put_16 (output_bfd, insn1, contents + rel->r_offset + 4);
+ }
+ }
+ continue;
- default:
- break;
- }
+ default:
+ break;
+ }
/* Dynamic relocs are not propagated for SEC_DEBUGGING sections
because such sections are not SEC_ALLOC and thus ld.so will
@@ -1950,7 +2995,19 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
(long) rel->r_offset,
h->root.root.string);
- r = _bfd_final_link_relocate (howto, input_bfd, input_section,
+ if (r_type == R_390_20
+ || r_type == R_390_GOT20
+ || r_type == R_390_GOTPLT20
+ || r_type == R_390_TLS_GOTIE20)
+ {
+ relocation += rel->r_addend;
+ relocation = (relocation&0xfff) << 8 | (relocation&0xff000) >> 12;
+ r = _bfd_final_link_relocate (howto, input_bfd, input_section,
+ contents, rel->r_offset,
+ relocation, 0);
+ }
+ else
+ r = _bfd_final_link_relocate (howto, input_bfd, input_section,
contents, rel->r_offset,
relocation, rel->r_addend);
@@ -1966,7 +3023,7 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
symtab_hdr->sh_link,
sym->st_name);
if (name == NULL)
- return false;
+ return FALSE;
if (*name == '\0')
name = bfd_section_name (input_bfd, sec);
}
@@ -1977,7 +3034,7 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
if (! ((*info->callbacks->reloc_overflow)
(info, name, howto->name, (bfd_vma) 0,
input_bfd, input_section, rel->r_offset)))
- return false;
+ return FALSE;
}
else
{
@@ -1986,18 +3043,18 @@ elf_s390_relocate_section (output_bfd, info, input_bfd, input_section,
bfd_archive_filename (input_bfd),
bfd_get_section_name (input_bfd, input_section),
(long) rel->r_offset, name, (int) r);
- return false;
+ return FALSE;
}
}
}
- return true;
+ return TRUE;
}
/* Finish up dynamic symbol handling. We set the contents of various
dynamic sections here. */
-static boolean
+static bfd_boolean
elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -2013,10 +3070,10 @@ elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
bfd_vma plt_index;
bfd_vma got_offset;
Elf_Internal_Rela rela;
- Elf64_External_Rela *loc;
+ bfd_byte *loc;
/* This symbol has an entry in the procedure linkage table. Set
- it up. */
+ it up. */
if (h->dynindx == -1
|| htab->splt == NULL
@@ -2025,11 +3082,11 @@ elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
abort ();
/* Calc. index no.
- Current offset - size first entry / entry size. */
+ Current offset - size first entry / entry size. */
plt_index = (h->plt.offset - PLT_FIRST_ENTRY_SIZE) / PLT_ENTRY_SIZE;
/* Offset in GOT is PLT index plus GOT headers(3) times 8,
- addr & GOT addr. */
+ addr & GOT addr. */
got_offset = (plt_index + 3) * GOT_ENTRY_SIZE;
/* Fill in the blueprint of a PLT. */
@@ -2064,7 +3121,7 @@ elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
htab->splt->contents + h->plt.offset + 28);
/* Fill in the entry in the global offset table.
- Points to instruction after GOT offset. */
+ Points to instruction after GOT offset. */
bfd_put_64 (output_bfd,
(htab->splt->output_section->vma
+ htab->splt->output_offset
@@ -2078,7 +3135,7 @@ elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
+ got_offset);
rela.r_info = ELF64_R_INFO (h->dynindx, R_390_JMP_SLOT);
rela.r_addend = 0;
- loc = (Elf64_External_Rela *) htab->srelplt->contents + plt_index;
+ loc = htab->srelplt->contents + plt_index * sizeof (Elf64_External_Rela);
bfd_elf64_swap_reloca_out (output_bfd, &rela, loc);
if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
@@ -2092,14 +3149,16 @@ elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
}
}
- if (h->got.offset != (bfd_vma) -1)
+ if (h->got.offset != (bfd_vma) -1
+ && elf_s390_hash_entry(h)->tls_type != GOT_TLS_GD
+ && elf_s390_hash_entry(h)->tls_type != GOT_TLS_IE
+ && elf_s390_hash_entry(h)->tls_type != GOT_TLS_IE_NLT)
{
Elf_Internal_Rela rela;
- Elf64_External_Rela *loc;
+ bfd_byte *loc;
/* This symbol has an entry in the global offset table. Set it
- up. */
-
+ up. */
if (htab->sgot == NULL || htab->srelgot == NULL)
abort ();
@@ -2117,30 +3176,30 @@ elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
|| h->dynindx == -1
|| (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL))
&& (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR))
- {
+ {
BFD_ASSERT((h->got.offset & 1) != 0);
- rela.r_info = ELF64_R_INFO (0, R_390_RELATIVE);
- rela.r_addend = (h->root.u.def.value
- + h->root.u.def.section->output_section->vma
- + h->root.u.def.section->output_offset);
- }
+ rela.r_info = ELF64_R_INFO (0, R_390_RELATIVE);
+ rela.r_addend = (h->root.u.def.value
+ + h->root.u.def.section->output_section->vma
+ + h->root.u.def.section->output_offset);
+ }
else
{
BFD_ASSERT((h->got.offset & 1) == 0);
bfd_put_64 (output_bfd, (bfd_vma) 0, htab->sgot->contents + h->got.offset);
rela.r_info = ELF64_R_INFO (h->dynindx, R_390_GLOB_DAT);
- rela.r_addend = 0;
- }
+ rela.r_addend = 0;
+ }
- loc = (Elf64_External_Rela *) htab->srelgot->contents;
- loc += htab->srelgot->reloc_count++;
+ loc = htab->srelgot->contents;
+ loc += htab->srelgot->reloc_count++ * sizeof (Elf64_External_Rela);
bfd_elf64_swap_reloca_out (output_bfd, &rela, loc);
}
if ((h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_COPY) != 0)
{
Elf_Internal_Rela rela;
- Elf64_External_Rela *loc;
+ bfd_byte *loc;
/* This symbols needs a copy reloc. Set it up. */
@@ -2155,8 +3214,8 @@ elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
+ h->root.u.def.section->output_offset);
rela.r_info = ELF64_R_INFO (h->dynindx, R_390_COPY);
rela.r_addend = 0;
- loc = (Elf64_External_Rela *) htab->srelbss->contents;
- loc += htab->srelbss->reloc_count++;
+ loc = htab->srelbss->contents;
+ loc += htab->srelbss->reloc_count++ * sizeof (Elf64_External_Rela);
bfd_elf64_swap_reloca_out (output_bfd, &rela, loc);
}
@@ -2166,7 +3225,7 @@ elf_s390_finish_dynamic_symbol (output_bfd, info, h, sym)
|| strcmp (h->root.root.string, "_PROCEDURE_LINKAGE_TABLE_") == 0)
sym->st_shndx = SHN_ABS;
- return true;
+ return TRUE;
}
/* Used to decide how to sort relocs in an optimal manner for the
@@ -2191,7 +3250,7 @@ elf_s390_reloc_type_class (rela)
/* Finish up the dynamic sections. */
-static boolean
+static bfd_boolean
elf_s390_finish_dynamic_sections (output_bfd, info)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -2307,21 +3366,12 @@ elf_s390_finish_dynamic_sections (output_bfd, info)
elf_section_data (htab->sgot->output_section)
->this_hdr.sh_entsize = 8;
}
- return true;
-}
-
-static boolean
-elf_s390_object_p (abfd)
- bfd *abfd;
-{
- return bfd_default_set_arch_mach (abfd, bfd_arch_s390, bfd_mach_s390_64);
+ return TRUE;
}
-/*
- * Why was the hash table entry size definition changed from
- * ARCH_SIZE/8 to 4? This breaks the 64 bit dynamic linker and
- * this is the only reason for the s390_elf64_size_info structure.
- */
+/* Why was the hash table entry size definition changed from
+ ARCH_SIZE/8 to 4? This breaks the 64 bit dynamic linker and
+ this is the only reason for the s390_elf64_size_info structure. */
const struct elf_size_info s390_elf64_size_info =
{
@@ -2333,10 +3383,10 @@ const struct elf_size_info s390_elf64_size_info =
sizeof (Elf64_External_Sym),
sizeof (Elf64_External_Dyn),
sizeof (Elf_External_Note),
- 8, /* hash-table entry size */
- 1, /* internal relocations per external relocations */
- 64, /* arch_size */
- 8, /* file_align */
+ 8, /* hash-table entry size. */
+ 1, /* internal relocations per external relocations. */
+ 64, /* arch_size. */
+ 3, /* log_file_align. */
ELFCLASS64, EV_CURRENT,
bfd_elf64_write_out_phdrs,
bfd_elf64_write_shdrs_and_ehdr,
@@ -2347,10 +3397,10 @@ const struct elf_size_info s390_elf64_size_info =
bfd_elf64_slurp_symbol_table,
bfd_elf64_swap_dyn_in,
bfd_elf64_swap_dyn_out,
- NULL,
- NULL,
- NULL,
- NULL
+ bfd_elf64_swap_reloc_in,
+ bfd_elf64_swap_reloc_out,
+ bfd_elf64_swap_reloca_in,
+ bfd_elf64_swap_reloca_out
};
#define TARGET_BIG_SYM bfd_elf64_s390_vec
@@ -2368,7 +3418,6 @@ const struct elf_size_info s390_elf64_size_info =
#define elf_backend_plt_readonly 1
#define elf_backend_want_plt_sym 0
#define elf_backend_got_header_size 24
-#define elf_backend_plt_header_size PLT_ENTRY_SIZE
#define elf_backend_rela_normal 1
#define elf_info_to_howto elf_s390_info_to_howto
@@ -2390,6 +3439,7 @@ const struct elf_size_info s390_elf64_size_info =
#define elf_backend_size_dynamic_sections elf_s390_size_dynamic_sections
#define elf_backend_reloc_type_class elf_s390_reloc_type_class
-#define elf_backend_object_p elf_s390_object_p
+#define bfd_elf64_mkobject elf_s390_mkobject
+#define elf_backend_object_p elf_s390_object_p
#include "elf64-target.h"
diff --git a/contrib/binutils/bfd/elf64-sparc.c b/contrib/binutils/bfd/elf64-sparc.c
index a3c100d..4568a22 100644
--- a/contrib/binutils/bfd/elf64-sparc.c
+++ b/contrib/binutils/bfd/elf64-sparc.c
@@ -1,22 +1,22 @@
/* SPARC-specific support for 64-bit ELF
- Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
- Free Software Foundation, Inc.
+ Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+ 2003, 2004 Free Software Foundation, Inc.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "bfd.h"
#include "sysdep.h"
@@ -51,49 +51,54 @@ static bfd_vma sparc64_elf_plt_entry_offset
static bfd_vma sparc64_elf_plt_ptr_offset
PARAMS ((bfd_vma, bfd_vma));
-static boolean sparc64_elf_check_relocs
+static bfd_boolean sparc64_elf_check_relocs
PARAMS ((bfd *, struct bfd_link_info *, asection *sec,
const Elf_Internal_Rela *));
-static boolean sparc64_elf_adjust_dynamic_symbol
+static bfd_boolean sparc64_elf_adjust_dynamic_symbol
PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *));
-static boolean sparc64_elf_size_dynamic_sections
+static bfd_boolean sparc64_elf_size_dynamic_sections
PARAMS ((bfd *, struct bfd_link_info *));
static int sparc64_elf_get_symbol_type
PARAMS (( Elf_Internal_Sym *, int));
-static boolean sparc64_elf_add_symbol_hook
- PARAMS ((bfd *, struct bfd_link_info *, const Elf_Internal_Sym *,
+static bfd_boolean sparc64_elf_add_symbol_hook
+ PARAMS ((bfd *, struct bfd_link_info *, Elf_Internal_Sym *,
const char **, flagword *, asection **, bfd_vma *));
-static boolean sparc64_elf_output_arch_syms
+static bfd_boolean sparc64_elf_output_arch_syms
PARAMS ((bfd *, struct bfd_link_info *, PTR,
- boolean (*) (PTR, const char *, Elf_Internal_Sym *, asection *)));
+ bfd_boolean (*) (PTR, const char *, Elf_Internal_Sym *,
+ asection *, struct elf_link_hash_entry *)));
static void sparc64_elf_symbol_processing
PARAMS ((bfd *, asymbol *));
-static boolean sparc64_elf_merge_private_bfd_data
+static bfd_boolean sparc64_elf_merge_private_bfd_data
PARAMS ((bfd *, bfd *));
-static boolean sparc64_elf_fake_sections
- PARAMS ((bfd *, Elf32_Internal_Shdr *, asection *));
+static bfd_boolean sparc64_elf_fake_sections
+ PARAMS ((bfd *, Elf_Internal_Shdr *, asection *));
static const char *sparc64_elf_print_symbol_all
PARAMS ((bfd *, PTR, asymbol *));
-static boolean sparc64_elf_relax_section
- PARAMS ((bfd *, asection *, struct bfd_link_info *, boolean *));
-static boolean sparc64_elf_relocate_section
+static bfd_boolean sparc64_elf_new_section_hook
+ PARAMS ((bfd *, asection *));
+static bfd_boolean sparc64_elf_relax_section
+ PARAMS ((bfd *, asection *, struct bfd_link_info *, bfd_boolean *));
+static bfd_boolean sparc64_elf_relocate_section
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
Elf_Internal_Rela *, Elf_Internal_Sym *, asection **));
-static boolean sparc64_elf_finish_dynamic_symbol
+static bfd_boolean sparc64_elf_finish_dynamic_symbol
PARAMS ((bfd *, struct bfd_link_info *, struct elf_link_hash_entry *,
Elf_Internal_Sym *));
-static boolean sparc64_elf_finish_dynamic_sections
+static bfd_boolean sparc64_elf_finish_dynamic_sections
PARAMS ((bfd *, struct bfd_link_info *));
-static boolean sparc64_elf_object_p PARAMS ((bfd *));
+static bfd_boolean sparc64_elf_object_p PARAMS ((bfd *));
static long sparc64_elf_get_reloc_upper_bound PARAMS ((bfd *, asection *));
static long sparc64_elf_get_dynamic_reloc_upper_bound PARAMS ((bfd *));
-static boolean sparc64_elf_slurp_one_reloc_table
- PARAMS ((bfd *, asection *, Elf_Internal_Shdr *, asymbol **, boolean));
-static boolean sparc64_elf_slurp_reloc_table
- PARAMS ((bfd *, asection *, asymbol **, boolean));
+static bfd_boolean sparc64_elf_slurp_one_reloc_table
+ PARAMS ((bfd *, asection *, Elf_Internal_Shdr *, asymbol **, bfd_boolean));
+static bfd_boolean sparc64_elf_slurp_reloc_table
+ PARAMS ((bfd *, asection *, asymbol **, bfd_boolean));
+static long sparc64_elf_canonicalize_reloc
+ PARAMS ((bfd *, asection *, arelent **, asymbol **));
static long sparc64_elf_canonicalize_dynamic_reloc
PARAMS ((bfd *, arelent **, asymbol **));
static void sparc64_elf_write_relocs PARAMS ((bfd *, asection *, PTR));
@@ -113,65 +118,89 @@ static bfd_reloc_status_type sparc_elf_lox10_reloc
static reloc_howto_type sparc64_elf_howto_table[] =
{
- HOWTO(R_SPARC_NONE, 0,0, 0,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", false,0,0x00000000,true),
- HOWTO(R_SPARC_8, 0,0, 8,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_8", false,0,0x000000ff,true),
- HOWTO(R_SPARC_16, 0,1,16,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_16", false,0,0x0000ffff,true),
- HOWTO(R_SPARC_32, 0,2,32,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_32", false,0,0xffffffff,true),
- HOWTO(R_SPARC_DISP8, 0,0, 8,true, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_DISP8", false,0,0x000000ff,true),
- HOWTO(R_SPARC_DISP16, 0,1,16,true, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_DISP16", false,0,0x0000ffff,true),
- HOWTO(R_SPARC_DISP32, 0,2,32,true, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_DISP32", false,0,0xffffffff,true),
- HOWTO(R_SPARC_WDISP30, 2,2,30,true, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_WDISP30", false,0,0x3fffffff,true),
- HOWTO(R_SPARC_WDISP22, 2,2,22,true, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_WDISP22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_HI22, 10,2,22,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_HI22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_22, 0,2,22,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_13, 0,2,13,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_13", false,0,0x00001fff,true),
- HOWTO(R_SPARC_LO10, 0,2,10,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_LO10", false,0,0x000003ff,true),
- HOWTO(R_SPARC_GOT10, 0,2,10,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_GOT10", false,0,0x000003ff,true),
- HOWTO(R_SPARC_GOT13, 0,2,13,false,0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_GOT13", false,0,0x00001fff,true),
- HOWTO(R_SPARC_GOT22, 10,2,22,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_GOT22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_PC10, 0,2,10,true, 0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_PC10", false,0,0x000003ff,true),
- HOWTO(R_SPARC_PC22, 10,2,22,true, 0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_PC22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_WPLT30, 2,2,30,true, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_WPLT30", false,0,0x3fffffff,true),
- HOWTO(R_SPARC_COPY, 0,0,00,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_COPY", false,0,0x00000000,true),
- HOWTO(R_SPARC_GLOB_DAT, 0,0,00,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_GLOB_DAT",false,0,0x00000000,true),
- HOWTO(R_SPARC_JMP_SLOT, 0,0,00,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_JMP_SLOT",false,0,0x00000000,true),
- HOWTO(R_SPARC_RELATIVE, 0,0,00,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_RELATIVE",false,0,0x00000000,true),
- HOWTO(R_SPARC_UA32, 0,2,32,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_UA32", false,0,0xffffffff,true),
+ HOWTO(R_SPARC_NONE, 0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_NONE", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_8, 0,0, 8,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_8", FALSE,0,0x000000ff,TRUE),
+ HOWTO(R_SPARC_16, 0,1,16,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_16", FALSE,0,0x0000ffff,TRUE),
+ HOWTO(R_SPARC_32, 0,2,32,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_32", FALSE,0,0xffffffff,TRUE),
+ HOWTO(R_SPARC_DISP8, 0,0, 8,TRUE, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_DISP8", FALSE,0,0x000000ff,TRUE),
+ HOWTO(R_SPARC_DISP16, 0,1,16,TRUE, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_DISP16", FALSE,0,0x0000ffff,TRUE),
+ HOWTO(R_SPARC_DISP32, 0,2,32,TRUE, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_DISP32", FALSE,0,0xffffffff,TRUE),
+ HOWTO(R_SPARC_WDISP30, 2,2,30,TRUE, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_WDISP30", FALSE,0,0x3fffffff,TRUE),
+ HOWTO(R_SPARC_WDISP22, 2,2,22,TRUE, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_WDISP22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_HI22, 10,2,22,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_HI22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_22, 0,2,22,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_13, 0,2,13,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_13", FALSE,0,0x00001fff,TRUE),
+ HOWTO(R_SPARC_LO10, 0,2,10,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_LO10", FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_GOT10, 0,2,10,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_GOT10", FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_GOT13, 0,2,13,FALSE,0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_GOT13", FALSE,0,0x00001fff,TRUE),
+ HOWTO(R_SPARC_GOT22, 10,2,22,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_GOT22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_PC10, 0,2,10,TRUE, 0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_PC10", FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_PC22, 10,2,22,TRUE, 0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_PC22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_WPLT30, 2,2,30,TRUE, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_WPLT30", FALSE,0,0x3fffffff,TRUE),
+ HOWTO(R_SPARC_COPY, 0,0,00,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_COPY", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_GLOB_DAT, 0,0,00,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_GLOB_DAT",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_JMP_SLOT, 0,0,00,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_JMP_SLOT",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_RELATIVE, 0,0,00,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_RELATIVE",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_UA32, 0,2,32,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_UA32", FALSE,0,0xffffffff,TRUE),
#ifndef SPARC64_OLD_RELOCS
- HOWTO(R_SPARC_PLT32, 0,2,32,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_PLT32", false,0,0xffffffff,true),
+ HOWTO(R_SPARC_PLT32, 0,2,32,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_PLT32", FALSE,0,0xffffffff,TRUE),
/* These aren't implemented yet. */
- HOWTO(R_SPARC_HIPLT22, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsup_reloc, "R_SPARC_HIPLT22", false,0,0x00000000,true),
- HOWTO(R_SPARC_LOPLT10, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsup_reloc, "R_SPARC_LOPLT10", false,0,0x00000000,true),
- HOWTO(R_SPARC_PCPLT32, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsup_reloc, "R_SPARC_PCPLT32", false,0,0x00000000,true),
- HOWTO(R_SPARC_PCPLT22, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsup_reloc, "R_SPARC_PCPLT22", false,0,0x00000000,true),
- HOWTO(R_SPARC_PCPLT10, 0,0,00,false,0,complain_overflow_dont, sparc_elf_notsup_reloc, "R_SPARC_PCPLT10", false,0,0x00000000,true),
+ HOWTO(R_SPARC_HIPLT22, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsup_reloc, "R_SPARC_HIPLT22", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_LOPLT10, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsup_reloc, "R_SPARC_LOPLT10", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_PCPLT32, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsup_reloc, "R_SPARC_PCPLT32", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_PCPLT22, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsup_reloc, "R_SPARC_PCPLT22", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_PCPLT10, 0,0,00,FALSE,0,complain_overflow_dont, sparc_elf_notsup_reloc, "R_SPARC_PCPLT10", FALSE,0,0x00000000,TRUE),
#endif
- HOWTO(R_SPARC_10, 0,2,10,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_10", false,0,0x000003ff,true),
- HOWTO(R_SPARC_11, 0,2,11,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_11", false,0,0x000007ff,true),
- HOWTO(R_SPARC_64, 0,4,64,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_64", false,0,MINUS_ONE, true),
- HOWTO(R_SPARC_OLO10, 0,2,13,false,0,complain_overflow_signed, sparc_elf_notsup_reloc, "R_SPARC_OLO10", false,0,0x00001fff,true),
- HOWTO(R_SPARC_HH22, 42,2,22,false,0,complain_overflow_unsigned,bfd_elf_generic_reloc, "R_SPARC_HH22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_HM10, 32,2,10,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_HM10", false,0,0x000003ff,true),
- HOWTO(R_SPARC_LM22, 10,2,22,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_LM22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_PC_HH22, 42,2,22,true, 0,complain_overflow_unsigned,bfd_elf_generic_reloc, "R_SPARC_PC_HH22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_PC_HM10, 32,2,10,true, 0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_PC_HM10", false,0,0x000003ff,true),
- HOWTO(R_SPARC_PC_LM22, 10,2,22,true, 0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_PC_LM22", false,0,0x003fffff,true),
- HOWTO(R_SPARC_WDISP16, 2,2,16,true, 0,complain_overflow_signed, sparc_elf_wdisp16_reloc,"R_SPARC_WDISP16", false,0,0x00000000,true),
- HOWTO(R_SPARC_WDISP19, 2,2,19,true, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_WDISP19", false,0,0x0007ffff,true),
- HOWTO(R_SPARC_UNUSED_42, 0,0, 0,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_UNUSED_42",false,0,0x00000000,true),
- HOWTO(R_SPARC_7, 0,2, 7,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_7", false,0,0x0000007f,true),
- HOWTO(R_SPARC_5, 0,2, 5,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_5", false,0,0x0000001f,true),
- HOWTO(R_SPARC_6, 0,2, 6,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_6", false,0,0x0000003f,true),
- HOWTO(R_SPARC_DISP64, 0,4,64,true, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_DISP64", false,0,MINUS_ONE, true),
- HOWTO(R_SPARC_PLT64, 0,4,64,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_PLT64", false,0,MINUS_ONE, true),
- HOWTO(R_SPARC_HIX22, 0,4, 0,false,0,complain_overflow_bitfield,sparc_elf_hix22_reloc, "R_SPARC_HIX22", false,0,MINUS_ONE, false),
- HOWTO(R_SPARC_LOX10, 0,4, 0,false,0,complain_overflow_dont, sparc_elf_lox10_reloc, "R_SPARC_LOX10", false,0,MINUS_ONE, false),
- HOWTO(R_SPARC_H44, 22,2,22,false,0,complain_overflow_unsigned,bfd_elf_generic_reloc, "R_SPARC_H44", false,0,0x003fffff,false),
- HOWTO(R_SPARC_M44, 12,2,10,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_M44", false,0,0x000003ff,false),
- HOWTO(R_SPARC_L44, 0,2,13,false,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_L44", false,0,0x00000fff,false),
- HOWTO(R_SPARC_REGISTER, 0,4, 0,false,0,complain_overflow_bitfield,sparc_elf_notsup_reloc, "R_SPARC_REGISTER",false,0,MINUS_ONE, false),
- HOWTO(R_SPARC_UA64, 0,4,64,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_UA64", false,0,MINUS_ONE, true),
- HOWTO(R_SPARC_UA16, 0,1,16,false,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_UA16", false,0,0x0000ffff,true)
+ HOWTO(R_SPARC_10, 0,2,10,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_10", FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_11, 0,2,11,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_11", FALSE,0,0x000007ff,TRUE),
+ HOWTO(R_SPARC_64, 0,4,64,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_64", FALSE,0,MINUS_ONE, TRUE),
+ HOWTO(R_SPARC_OLO10, 0,2,13,FALSE,0,complain_overflow_signed, sparc_elf_notsup_reloc, "R_SPARC_OLO10", FALSE,0,0x00001fff,TRUE),
+ HOWTO(R_SPARC_HH22, 42,2,22,FALSE,0,complain_overflow_unsigned,bfd_elf_generic_reloc, "R_SPARC_HH22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_HM10, 32,2,10,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_HM10", FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_LM22, 10,2,22,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_LM22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_PC_HH22, 42,2,22,TRUE, 0,complain_overflow_unsigned,bfd_elf_generic_reloc, "R_SPARC_PC_HH22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_PC_HM10, 32,2,10,TRUE, 0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_PC_HM10", FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_PC_LM22, 10,2,22,TRUE, 0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_PC_LM22", FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_WDISP16, 2,2,16,TRUE, 0,complain_overflow_signed, sparc_elf_wdisp16_reloc,"R_SPARC_WDISP16", FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_WDISP19, 2,2,19,TRUE, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_WDISP19", FALSE,0,0x0007ffff,TRUE),
+ HOWTO(R_SPARC_UNUSED_42, 0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_UNUSED_42",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_7, 0,2, 7,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_7", FALSE,0,0x0000007f,TRUE),
+ HOWTO(R_SPARC_5, 0,2, 5,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_5", FALSE,0,0x0000001f,TRUE),
+ HOWTO(R_SPARC_6, 0,2, 6,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_6", FALSE,0,0x0000003f,TRUE),
+ HOWTO(R_SPARC_DISP64, 0,4,64,TRUE, 0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_DISP64", FALSE,0,MINUS_ONE, TRUE),
+ HOWTO(R_SPARC_PLT64, 0,4,64,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_PLT64", FALSE,0,MINUS_ONE, TRUE),
+ HOWTO(R_SPARC_HIX22, 0,4, 0,FALSE,0,complain_overflow_bitfield,sparc_elf_hix22_reloc, "R_SPARC_HIX22", FALSE,0,MINUS_ONE, FALSE),
+ HOWTO(R_SPARC_LOX10, 0,4, 0,FALSE,0,complain_overflow_dont, sparc_elf_lox10_reloc, "R_SPARC_LOX10", FALSE,0,MINUS_ONE, FALSE),
+ HOWTO(R_SPARC_H44, 22,2,22,FALSE,0,complain_overflow_unsigned,bfd_elf_generic_reloc, "R_SPARC_H44", FALSE,0,0x003fffff,FALSE),
+ HOWTO(R_SPARC_M44, 12,2,10,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_M44", FALSE,0,0x000003ff,FALSE),
+ HOWTO(R_SPARC_L44, 0,2,13,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_L44", FALSE,0,0x00000fff,FALSE),
+ HOWTO(R_SPARC_REGISTER, 0,4, 0,FALSE,0,complain_overflow_bitfield,sparc_elf_notsup_reloc, "R_SPARC_REGISTER",FALSE,0,MINUS_ONE, FALSE),
+ HOWTO(R_SPARC_UA64, 0,4,64,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_UA64", FALSE,0,MINUS_ONE, TRUE),
+ HOWTO(R_SPARC_UA16, 0,1,16,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc, "R_SPARC_UA16", FALSE,0,0x0000ffff,TRUE),
+ HOWTO(R_SPARC_TLS_GD_HI22,10,2,22,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_GD_HI22",FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_TLS_GD_LO10,0,2,10,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_GD_LO10",FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_TLS_GD_ADD,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_GD_ADD",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_GD_CALL,2,2,30,TRUE,0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_TLS_GD_CALL",FALSE,0,0x3fffffff,TRUE),
+ HOWTO(R_SPARC_TLS_LDM_HI22,10,2,22,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_LDM_HI22",FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_TLS_LDM_LO10,0,2,10,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_LDM_LO10",FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_TLS_LDM_ADD,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_LDM_ADD",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_LDM_CALL,2,2,30,TRUE,0,complain_overflow_signed, bfd_elf_generic_reloc, "R_SPARC_TLS_LDM_CALL",FALSE,0,0x3fffffff,TRUE),
+ HOWTO(R_SPARC_TLS_LDO_HIX22,0,2,0,FALSE,0,complain_overflow_bitfield,sparc_elf_hix22_reloc,"R_SPARC_TLS_LDO_HIX22",FALSE,0,0x003fffff, FALSE),
+ HOWTO(R_SPARC_TLS_LDO_LOX10,0,2,0,FALSE,0,complain_overflow_dont, sparc_elf_lox10_reloc, "R_SPARC_TLS_LDO_LOX10",FALSE,0,0x000003ff, FALSE),
+ HOWTO(R_SPARC_TLS_LDO_ADD,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_LDO_ADD",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_IE_HI22,10,2,22,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_IE_HI22",FALSE,0,0x003fffff,TRUE),
+ HOWTO(R_SPARC_TLS_IE_LO10,0,2,10,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_IE_LO10",FALSE,0,0x000003ff,TRUE),
+ HOWTO(R_SPARC_TLS_IE_LD,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_IE_LD",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_IE_LDX,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_IE_LDX",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_IE_ADD,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_IE_ADD",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_LE_HIX22,0,2,0,FALSE,0,complain_overflow_bitfield,sparc_elf_hix22_reloc, "R_SPARC_TLS_LE_HIX22",FALSE,0,0x003fffff, FALSE),
+ HOWTO(R_SPARC_TLS_LE_LOX10,0,2,0,FALSE,0,complain_overflow_dont, sparc_elf_lox10_reloc, "R_SPARC_TLS_LE_LOX10",FALSE,0,0x000003ff, FALSE),
+ HOWTO(R_SPARC_TLS_DTPMOD32,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_DTPMOD32",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_DTPMOD64,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_DTPMOD64",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_DTPOFF32,0,2,32,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc,"R_SPARC_TLS_DTPOFF32",FALSE,0,0xffffffff,TRUE),
+ HOWTO(R_SPARC_TLS_DTPOFF64,0,4,64,FALSE,0,complain_overflow_bitfield,bfd_elf_generic_reloc,"R_SPARC_TLS_DTPOFF64",FALSE,0,MINUS_ONE,TRUE),
+ HOWTO(R_SPARC_TLS_TPOFF32,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_TPOFF32",FALSE,0,0x00000000,TRUE),
+ HOWTO(R_SPARC_TLS_TPOFF64,0,0, 0,FALSE,0,complain_overflow_dont, bfd_elf_generic_reloc, "R_SPARC_TLS_TPOFF64",FALSE,0,0x00000000,TRUE)
};
struct elf_reloc_map {
@@ -225,6 +254,30 @@ static const struct elf_reloc_map sparc_reloc_map[] =
{ BFD_RELOC_SPARC_5, R_SPARC_5 },
{ BFD_RELOC_SPARC_6, R_SPARC_6 },
{ BFD_RELOC_SPARC_DISP64, R_SPARC_DISP64 },
+ { BFD_RELOC_SPARC_TLS_GD_HI22, R_SPARC_TLS_GD_HI22 },
+ { BFD_RELOC_SPARC_TLS_GD_LO10, R_SPARC_TLS_GD_LO10 },
+ { BFD_RELOC_SPARC_TLS_GD_ADD, R_SPARC_TLS_GD_ADD },
+ { BFD_RELOC_SPARC_TLS_GD_CALL, R_SPARC_TLS_GD_CALL },
+ { BFD_RELOC_SPARC_TLS_LDM_HI22, R_SPARC_TLS_LDM_HI22 },
+ { BFD_RELOC_SPARC_TLS_LDM_LO10, R_SPARC_TLS_LDM_LO10 },
+ { BFD_RELOC_SPARC_TLS_LDM_ADD, R_SPARC_TLS_LDM_ADD },
+ { BFD_RELOC_SPARC_TLS_LDM_CALL, R_SPARC_TLS_LDM_CALL },
+ { BFD_RELOC_SPARC_TLS_LDO_HIX22, R_SPARC_TLS_LDO_HIX22 },
+ { BFD_RELOC_SPARC_TLS_LDO_LOX10, R_SPARC_TLS_LDO_LOX10 },
+ { BFD_RELOC_SPARC_TLS_LDO_ADD, R_SPARC_TLS_LDO_ADD },
+ { BFD_RELOC_SPARC_TLS_IE_HI22, R_SPARC_TLS_IE_HI22 },
+ { BFD_RELOC_SPARC_TLS_IE_LO10, R_SPARC_TLS_IE_LO10 },
+ { BFD_RELOC_SPARC_TLS_IE_LD, R_SPARC_TLS_IE_LD },
+ { BFD_RELOC_SPARC_TLS_IE_LDX, R_SPARC_TLS_IE_LDX },
+ { BFD_RELOC_SPARC_TLS_IE_ADD, R_SPARC_TLS_IE_ADD },
+ { BFD_RELOC_SPARC_TLS_LE_HIX22, R_SPARC_TLS_LE_HIX22 },
+ { BFD_RELOC_SPARC_TLS_LE_LOX10, R_SPARC_TLS_LE_LOX10 },
+ { BFD_RELOC_SPARC_TLS_DTPMOD32, R_SPARC_TLS_DTPMOD32 },
+ { BFD_RELOC_SPARC_TLS_DTPMOD64, R_SPARC_TLS_DTPMOD64 },
+ { BFD_RELOC_SPARC_TLS_DTPOFF32, R_SPARC_TLS_DTPOFF32 },
+ { BFD_RELOC_SPARC_TLS_DTPOFF64, R_SPARC_TLS_DTPOFF64 },
+ { BFD_RELOC_SPARC_TLS_TPOFF32, R_SPARC_TLS_TPOFF32 },
+ { BFD_RELOC_SPARC_TLS_TPOFF64, R_SPARC_TLS_TPOFF64 },
#ifndef SPARC64_OLD_RELOCS
{ BFD_RELOC_SPARC_PLT32, R_SPARC_PLT32 },
#endif
@@ -255,12 +308,23 @@ static void
sparc64_elf_info_to_howto (abfd, cache_ptr, dst)
bfd *abfd ATTRIBUTE_UNUSED;
arelent *cache_ptr;
- Elf64_Internal_Rela *dst;
+ Elf_Internal_Rela *dst;
{
BFD_ASSERT (ELF64_R_TYPE_ID (dst->r_info) < (unsigned int) R_SPARC_max_std);
cache_ptr->howto = &sparc64_elf_howto_table[ELF64_R_TYPE_ID (dst->r_info)];
}
+struct sparc64_elf_section_data
+{
+ struct bfd_elf_section_data elf;
+ unsigned int do_relax, reloc_count;
+};
+
+#define sec_do_relax(sec) \
+ ((struct sparc64_elf_section_data *) elf_section_data (sec))->do_relax
+#define canon_reloc_count(sec) \
+ ((struct sparc64_elf_section_data *) elf_section_data (sec))->reloc_count
+
/* Due to the way how we handle R_SPARC_OLO10, each entry in a SHT_RELA
section can represent up to two relocs, we must tell the user to allocate
more space. */
@@ -285,13 +349,13 @@ sparc64_elf_get_dynamic_reloc_upper_bound (abfd)
has secondary addend in ELF64_R_TYPE_DATA. We handle it as two relocations
for the same location, R_SPARC_LO10 and R_SPARC_13. */
-static boolean
+static bfd_boolean
sparc64_elf_slurp_one_reloc_table (abfd, asect, rel_hdr, symbols, dynamic)
bfd *abfd;
asection *asect;
Elf_Internal_Shdr *rel_hdr;
asymbol **symbols;
- boolean dynamic;
+ bfd_boolean dynamic;
{
PTR allocated = NULL;
bfd_byte *native_relocs;
@@ -311,7 +375,7 @@ sparc64_elf_slurp_one_reloc_table (abfd, asect, rel_hdr, symbols, dynamic)
native_relocs = (bfd_byte *) allocated;
- relents = asect->relocation + asect->reloc_count;
+ relents = asect->relocation + canon_reloc_count (asect);
entsize = rel_hdr->sh_entsize;
BFD_ASSERT (entsize == sizeof (Elf64_External_Rela));
@@ -323,7 +387,7 @@ sparc64_elf_slurp_one_reloc_table (abfd, asect, rel_hdr, symbols, dynamic)
{
Elf_Internal_Rela rela;
- bfd_elf64_swap_reloca_in (abfd, (Elf64_External_Rela *) native_relocs, &rela);
+ bfd_elf64_swap_reloca_in (abfd, native_relocs, &rela);
/* The address of an ELF reloc is section relative for an object
file, and absolute for an executable file or shared library.
@@ -366,27 +430,27 @@ sparc64_elf_slurp_one_reloc_table (abfd, asect, rel_hdr, symbols, dynamic)
relent->howto = &sparc64_elf_howto_table[ELF64_R_TYPE_ID (rela.r_info)];
}
- asect->reloc_count += relent - relents;
+ canon_reloc_count (asect) += relent - relents;
if (allocated != NULL)
free (allocated);
- return true;
+ return TRUE;
error_return:
if (allocated != NULL)
free (allocated);
- return false;
+ return FALSE;
}
/* Read in and swap the external relocs. */
-static boolean
+static bfd_boolean
sparc64_elf_slurp_reloc_table (abfd, asect, symbols, dynamic)
bfd *abfd;
asection *asect;
asymbol **symbols;
- boolean dynamic;
+ bfd_boolean dynamic;
{
struct bfd_elf_section_data * const d = elf_section_data (asect);
Elf_Internal_Shdr *rel_hdr;
@@ -394,13 +458,13 @@ sparc64_elf_slurp_reloc_table (abfd, asect, symbols, dynamic)
bfd_size_type amt;
if (asect->relocation != NULL)
- return true;
+ return TRUE;
if (! dynamic)
{
if ((asect->flags & SEC_RELOC) == 0
|| asect->reloc_count == 0)
- return true;
+ return TRUE;
rel_hdr = &d->rel_hdr;
rel_hdr2 = d->rel_hdr2;
@@ -415,7 +479,7 @@ sparc64_elf_slurp_reloc_table (abfd, asect, symbols, dynamic)
dynamic symbol table, and in that case bfd_section_from_shdr
in elf.c does not update the RELOC_COUNT. */
if (asect->_raw_size == 0)
- return true;
+ return TRUE;
rel_hdr = &d->this_hdr;
asect->reloc_count = NUM_SHDR_ENTRIES (rel_hdr);
@@ -426,23 +490,50 @@ sparc64_elf_slurp_reloc_table (abfd, asect, symbols, dynamic)
amt *= 2 * sizeof (arelent);
asect->relocation = (arelent *) bfd_alloc (abfd, amt);
if (asect->relocation == NULL)
- return false;
+ return FALSE;
- /* The sparc64_elf_slurp_one_reloc_table routine increments reloc_count. */
- asect->reloc_count = 0;
+ /* The sparc64_elf_slurp_one_reloc_table routine increments
+ canon_reloc_count. */
+ canon_reloc_count (asect) = 0;
if (!sparc64_elf_slurp_one_reloc_table (abfd, asect, rel_hdr, symbols,
dynamic))
- return false;
+ return FALSE;
if (rel_hdr2
&& !sparc64_elf_slurp_one_reloc_table (abfd, asect, rel_hdr2, symbols,
dynamic))
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
+/* Canonicalize the relocs. */
+
+static long
+sparc64_elf_canonicalize_reloc (abfd, section, relptr, symbols)
+ bfd *abfd;
+ sec_ptr section;
+ arelent **relptr;
+ asymbol **symbols;
+{
+ arelent *tblptr;
+ unsigned int i;
+ const struct elf_backend_data *bed = get_elf_backend_data (abfd);
+
+ if (! bed->s->slurp_reloc_table (abfd, section, symbols, FALSE))
+ return -1;
+
+ tblptr = section->relocation;
+ for (i = 0; i < canon_reloc_count (section); i++)
+ *relptr++ = tblptr++;
+
+ *relptr = NULL;
+
+ return canon_reloc_count (section);
+}
+
+
/* Canonicalize the dynamic relocation entries. Note that we return
the dynamic relocations as a single block, although they are
actually associated with particular sections; the interface, which
@@ -476,9 +567,9 @@ sparc64_elf_canonicalize_dynamic_reloc (abfd, storage, syms)
arelent *p;
long count, i;
- if (! sparc64_elf_slurp_reloc_table (abfd, s, syms, true))
+ if (! sparc64_elf_slurp_reloc_table (abfd, s, syms, TRUE))
return -1;
- count = s->reloc_count;
+ count = canon_reloc_count (s);
p = s->relocation;
for (i = 0; i < count; i++)
*storage++ = p++;
@@ -499,7 +590,7 @@ sparc64_elf_write_relocs (abfd, sec, data)
asection *sec;
PTR data;
{
- boolean *failedp = (boolean *) data;
+ bfd_boolean *failedp = (bfd_boolean *) data;
Elf_Internal_Shdr *rela_hdr;
Elf64_External_Rela *outbound_relocas, *src_rela;
unsigned int idx, count;
@@ -550,7 +641,7 @@ sparc64_elf_write_relocs (abfd, sec, data)
rela_hdr->contents = (PTR) bfd_alloc (abfd, rela_hdr->sh_size);
if (rela_hdr->contents == NULL)
{
- *failedp = true;
+ *failedp = TRUE;
return;
}
@@ -590,7 +681,7 @@ sparc64_elf_write_relocs (abfd, sec, data)
n = _bfd_elf_symbol_from_bfd_symbol (abfd, &sym);
if (n < 0)
{
- *failedp = true;
+ *failedp = TRUE;
return;
}
last_sym_idx = n;
@@ -600,7 +691,7 @@ sparc64_elf_write_relocs (abfd, sec, data)
&& (*ptr->sym_ptr_ptr)->the_bfd->xvec != abfd->xvec
&& ! _bfd_elf_validate_reloc (abfd, ptr))
{
- *failedp = true;
+ *failedp = TRUE;
return;
}
@@ -626,7 +717,7 @@ sparc64_elf_write_relocs (abfd, sec, data)
dst_rela.r_info = ELF64_R_INFO (n, ptr->howto->type);
dst_rela.r_addend = ptr->addend;
- bfd_elf64_swap_reloca_out (abfd, &dst_rela, src_rela);
+ bfd_elf64_swap_reloca_out (abfd, &dst_rela, (bfd_byte *) src_rela);
++src_rela;
}
}
@@ -714,7 +805,7 @@ init_insn_reloc (abfd,
return bfd_reloc_ok;
}
- /* This works because partial_inplace is false. */
+ /* This works because partial_inplace is FALSE. */
if (output_bfd != NULL)
return bfd_reloc_continue;
@@ -994,7 +1085,7 @@ sparc64_elf_plt_ptr_offset (index, max)
allocate space in the global offset table or procedure linkage
table. */
-static boolean
+static bfd_boolean
sparc64_elf_check_relocs (abfd, info, sec, relocs)
bfd *abfd;
struct bfd_link_info *info;
@@ -1011,8 +1102,8 @@ sparc64_elf_check_relocs (abfd, info, sec, relocs)
asection *srelgot;
asection *sreloc;
- if (info->relocateable || !(sec->flags & SEC_ALLOC))
- return true;
+ if (info->relocatable || !(sec->flags & SEC_ALLOC))
+ return TRUE;
dynobj = elf_hash_table (info)->dynobj;
symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
@@ -1047,7 +1138,7 @@ sparc64_elf_check_relocs (abfd, info, sec, relocs)
/* Create the .got section. */
elf_hash_table (info)->dynobj = dynobj = abfd;
if (! _bfd_elf_create_got_section (dynobj, info))
- return false;
+ return FALSE;
}
if (sgot == NULL)
@@ -1071,7 +1162,7 @@ sparc64_elf_check_relocs (abfd, info, sec, relocs)
| SEC_LINKER_CREATED
| SEC_READONLY))
|| ! bfd_set_section_alignment (dynobj, srelgot, 3))
- return false;
+ return FALSE;
}
}
@@ -1087,8 +1178,8 @@ sparc64_elf_check_relocs (abfd, info, sec, relocs)
/* Make sure this symbol is output as a dynamic symbol. */
if (h->dynindx == -1)
{
- if (! bfd_elf64_link_record_dynamic_symbol (info, h))
- return false;
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
}
srelgot->_raw_size += sizeof (Elf64_External_Rela);
@@ -1106,7 +1197,7 @@ sparc64_elf_check_relocs (abfd, info, sec, relocs)
size *= sizeof (bfd_vma);
local_got_offsets = (bfd_vma *) bfd_alloc (abfd, size);
if (local_got_offsets == NULL)
- return false;
+ return FALSE;
elf_local_got_offsets (abfd) = local_got_offsets;
for (i = 0; i < symtab_hdr->sh_info; i++)
local_got_offsets[i] = (bfd_vma) -1;
@@ -1164,14 +1255,14 @@ sparc64_elf_check_relocs (abfd, info, sec, relocs)
/* It does not make sense to have a procedure linkage
table entry for a local symbol. */
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
/* Make sure this symbol is output as a dynamic symbol. */
if (h->dynindx == -1)
{
- if (! bfd_elf64_link_record_dynamic_symbol (info, h))
- return false;
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
}
h->elf_link_hash_flags |= ELF_LINK_HASH_NEEDS_PLT;
@@ -1243,7 +1334,7 @@ sparc64_elf_check_relocs (abfd, info, sec, relocs)
elf_elfheader (abfd)->e_shstrndx,
elf_section_data (sec)->rel_hdr.sh_name));
if (name == NULL)
- return false;
+ return FALSE;
BFD_ASSERT (strncmp (name, ".rela", 5) == 0
&& strcmp (bfd_get_section_name (abfd, sec),
@@ -1262,7 +1353,7 @@ sparc64_elf_check_relocs (abfd, info, sec, relocs)
if (sreloc == NULL
|| ! bfd_set_section_flags (dynobj, sreloc, flags)
|| ! bfd_set_section_alignment (dynobj, sreloc, 3))
- return false;
+ return FALSE;
}
if (sec->flags & SEC_READONLY)
info->flags |= DF_TEXTREL;
@@ -1280,21 +1371,21 @@ sparc64_elf_check_relocs (abfd, info, sec, relocs)
(*_bfd_error_handler) (_("%s: check_relocs: unhandled reloc type %d"),
bfd_archive_filename (abfd),
ELF64_R_TYPE_ID (rel->r_info));
- return false;
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
/* Hook called by the linker routine which adds symbols from an object
file. We use it for STT_REGISTER symbols. */
-static boolean
+static bfd_boolean
sparc64_elf_add_symbol_hook (abfd, info, sym, namep, flagsp, secp, valp)
bfd *abfd;
struct bfd_link_info *info;
- const Elf_Internal_Sym *sym;
+ Elf_Internal_Sym *sym;
const char **namep;
flagword *flagsp ATTRIBUTE_UNUSED;
asection **secp ATTRIBUTE_UNUSED;
@@ -1316,7 +1407,7 @@ sparc64_elf_add_symbol_hook (abfd, info, sym, namep, flagsp, secp, valp)
(*_bfd_error_handler)
(_("%s: Only registers %%g[2367] can be declared using STT_REGISTER"),
bfd_archive_filename (abfd));
- return false;
+ return FALSE;
}
if (info->hash->creator != abfd->xvec
@@ -1326,7 +1417,7 @@ sparc64_elf_add_symbol_hook (abfd, info, sym, namep, flagsp, secp, valp)
If STT_REGISTER comes from a dynamic object, don't put it into
the output bfd. The dynamic linker will recheck it. */
*namep = NULL;
- return true;
+ return TRUE;
}
p = sparc64_elf_hash_table(info)->app_regs + reg;
@@ -1338,7 +1429,7 @@ sparc64_elf_add_symbol_hook (abfd, info, sym, namep, flagsp, secp, valp)
(int) sym->st_value,
**namep ? *namep : "#scratch", bfd_archive_filename (abfd),
*p->name ? p->name : "#scratch", bfd_archive_filename (p->abfd));
- return false;
+ return FALSE;
}
if (p->name == NULL)
@@ -1348,7 +1439,7 @@ sparc64_elf_add_symbol_hook (abfd, info, sym, namep, flagsp, secp, valp)
struct elf_link_hash_entry *h;
h = (struct elf_link_hash_entry *)
- bfd_link_hash_lookup (info->hash, *namep, false, false, false);
+ bfd_link_hash_lookup (info->hash, *namep, FALSE, FALSE, FALSE);
if (h != NULL)
{
@@ -1360,13 +1451,13 @@ sparc64_elf_add_symbol_hook (abfd, info, sym, namep, flagsp, secp, valp)
(_("Symbol `%s' has differing types: REGISTER in %s, previously %s in %s"),
*namep, bfd_archive_filename (abfd),
stt_types[type], bfd_archive_filename (p->abfd));
- return false;
+ return FALSE;
}
p->name = bfd_hash_allocate (&info->hash->table,
strlen (*namep) + 1);
if (!p->name)
- return false;
+ return FALSE;
strcpy (p->name, *namep);
}
@@ -1386,7 +1477,7 @@ sparc64_elf_add_symbol_hook (abfd, info, sym, namep, flagsp, secp, valp)
}
}
*namep = NULL;
- return true;
+ return TRUE;
}
else if (*namep && **namep
&& info->hash->creator == abfd->xvec)
@@ -1406,22 +1497,23 @@ sparc64_elf_add_symbol_hook (abfd, info, sym, namep, flagsp, secp, valp)
(_("Symbol `%s' has differing types: %s in %s, previously REGISTER in %s"),
*namep, stt_types[type], bfd_archive_filename (abfd),
bfd_archive_filename (p->abfd));
- return false;
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
-/* This function takes care of emiting STT_REGISTER symbols
+/* This function takes care of emitting STT_REGISTER symbols
which we cannot easily keep in the symbol hash table. */
-static boolean
+static bfd_boolean
sparc64_elf_output_arch_syms (output_bfd, info, finfo, func)
bfd *output_bfd ATTRIBUTE_UNUSED;
struct bfd_link_info *info;
PTR finfo;
- boolean (*func) PARAMS ((PTR, const char *,
- Elf_Internal_Sym *, asection *));
+ bfd_boolean (*func)
+ PARAMS ((PTR, const char *, Elf_Internal_Sym *, asection *,
+ struct elf_link_hash_entry *));
{
int reg;
struct sparc64_elf_app_reg *app_regs =
@@ -1449,7 +1541,7 @@ sparc64_elf_output_arch_syms (output_bfd, info, finfo, func)
}
if (info->strip == strip_all)
- return true;
+ return TRUE;
for (reg = 0; reg < 4; reg++)
if (app_regs [reg].name != NULL)
@@ -1457,7 +1549,7 @@ sparc64_elf_output_arch_syms (output_bfd, info, finfo, func)
if (info->strip == strip_some
&& bfd_hash_lookup (info->keep_hash,
app_regs [reg].name,
- false, false) == NULL)
+ FALSE, FALSE) == NULL)
continue;
sym.st_value = reg < 2 ? reg + 2 : reg + 4;
@@ -1467,11 +1559,12 @@ sparc64_elf_output_arch_syms (output_bfd, info, finfo, func)
sym.st_shndx = app_regs [reg].shndx;
if (! (*func) (finfo, app_regs [reg].name, &sym,
sym.st_shndx == SHN_ABS
- ? bfd_abs_section_ptr : bfd_und_section_ptr))
- return false;
+ ? bfd_abs_section_ptr : bfd_und_section_ptr,
+ NULL))
+ return FALSE;
}
- return true;
+ return TRUE;
}
static int
@@ -1509,7 +1602,7 @@ sparc64_elf_symbol_processing (abfd, asym)
change the definition to something the rest of the link can
understand. */
-static boolean
+static bfd_boolean
sparc64_elf_adjust_dynamic_symbol (info, h)
struct bfd_link_info *info;
struct elf_link_hash_entry *h;
@@ -1553,7 +1646,7 @@ sparc64_elf_adjust_dynamic_symbol (info, h)
procedure linkage table, and we can just do a WDISP30
reloc instead. */
BFD_ASSERT ((h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_PLT) != 0);
- return true;
+ return TRUE;
}
s = bfd_get_section_by_name (dynobj, ".plt");
@@ -1593,10 +1686,10 @@ sparc64_elf_adjust_dynamic_symbol (info, h)
if (s->_raw_size >= (bfd_vma)1 << 32)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* If this is a weak symbol, and there is a real definition, the
@@ -1608,7 +1701,7 @@ sparc64_elf_adjust_dynamic_symbol (info, h)
|| h->weakdef->root.type == bfd_link_hash_defweak);
h->root.u.def.section = h->weakdef->root.u.def.section;
h->root.u.def.value = h->weakdef->root.u.def.value;
- return true;
+ return TRUE;
}
/* This is a reference to a symbol defined by a dynamic object which
@@ -1619,7 +1712,7 @@ sparc64_elf_adjust_dynamic_symbol (info, h)
For such cases we need not do anything here; the relocations will
be handled correctly by relocate_section. */
if (info->shared)
- return true;
+ return TRUE;
/* We must allocate the symbol in our .dynbss section, which will
become part of the .bss section of the executable. There will be
@@ -1661,7 +1754,7 @@ sparc64_elf_adjust_dynamic_symbol (info, h)
if (power_of_two > bfd_get_section_alignment (dynobj, s))
{
if (! bfd_set_section_alignment (dynobj, s, power_of_two))
- return false;
+ return FALSE;
}
/* Define the symbol as being at this point in the section. */
@@ -1671,19 +1764,19 @@ sparc64_elf_adjust_dynamic_symbol (info, h)
/* Increment the section size to make room for the symbol. */
s->_raw_size += h->size;
- return true;
+ return TRUE;
}
/* Set the sizes of the dynamic sections. */
-static boolean
+static bfd_boolean
sparc64_elf_size_dynamic_sections (output_bfd, info)
bfd *output_bfd;
struct bfd_link_info *info;
{
bfd *dynobj;
asection *s;
- boolean relplt;
+ bfd_boolean relplt;
dynobj = elf_hash_table (info)->dynobj;
BFD_ASSERT (dynobj != NULL);
@@ -1691,7 +1784,7 @@ sparc64_elf_size_dynamic_sections (output_bfd, info)
if (elf_hash_table (info)->dynamic_sections_created)
{
/* Set the contents of the .interp section to the interpreter. */
- if (! info->shared)
+ if (info->executable)
{
s = bfd_get_section_by_name (dynobj, ".interp");
BFD_ASSERT (s != NULL);
@@ -1714,11 +1807,11 @@ sparc64_elf_size_dynamic_sections (output_bfd, info)
/* The check_relocs and adjust_dynamic_symbol entry points have
determined the sizes of the various dynamic sections. Allocate
memory for them. */
- relplt = false;
+ relplt = FALSE;
for (s = dynobj->sections; s != NULL; s = s->next)
{
const char *name;
- boolean strip;
+ bfd_boolean strip;
if ((s->flags & SEC_LINKER_CREATED) == 0)
continue;
@@ -1727,7 +1820,7 @@ sparc64_elf_size_dynamic_sections (output_bfd, info)
of the dynobj section names depend upon the input files. */
name = bfd_get_section_name (dynobj, s);
- strip = false;
+ strip = FALSE;
if (strncmp (name, ".rela", 5) == 0)
{
@@ -1742,12 +1835,12 @@ sparc64_elf_size_dynamic_sections (output_bfd, info)
adjust_dynamic_symbol is called, and it is that
function which decides whether anything needs to go
into these sections. */
- strip = true;
+ strip = TRUE;
}
else
{
if (strcmp (name, ".rela.plt") == 0)
- relplt = true;
+ relplt = TRUE;
/* We use the reloc_count field as a counter if we need
to copy relocs into the output file. */
@@ -1772,7 +1865,7 @@ sparc64_elf_size_dynamic_sections (output_bfd, info)
at the beginning, and we don't want garbage. */
s->contents = (bfd_byte *) bfd_zalloc (dynobj, s->_raw_size);
if (s->contents == NULL && s->_raw_size != 0)
- return false;
+ return FALSE;
}
if (elf_hash_table (info)->dynamic_sections_created)
@@ -1783,17 +1876,17 @@ sparc64_elf_size_dynamic_sections (output_bfd, info)
the .dynamic section. The DT_DEBUG entry is filled in by the
dynamic linker and used by the debugger. */
#define add_dynamic_entry(TAG, VAL) \
- bfd_elf64_add_dynamic_entry (info, (bfd_vma) (TAG), (bfd_vma) (VAL))
+ _bfd_elf_add_dynamic_entry (info, TAG, VAL)
int reg;
struct sparc64_elf_app_reg * app_regs;
struct elf_strtab_hash *dynstr;
struct elf_link_hash_table *eht = elf_hash_table (info);
- if (!info->shared)
+ if (info->executable)
{
if (!add_dynamic_entry (DT_DEBUG, 0))
- return false;
+ return FALSE;
}
if (relplt)
@@ -1802,18 +1895,18 @@ sparc64_elf_size_dynamic_sections (output_bfd, info)
|| !add_dynamic_entry (DT_PLTRELSZ, 0)
|| !add_dynamic_entry (DT_PLTREL, DT_RELA)
|| !add_dynamic_entry (DT_JMPREL, 0))
- return false;
+ return FALSE;
}
if (!add_dynamic_entry (DT_RELA, 0)
|| !add_dynamic_entry (DT_RELASZ, 0)
|| !add_dynamic_entry (DT_RELAENT, sizeof (Elf64_External_Rela)))
- return false;
+ return FALSE;
if (info->flags & DF_TEXTREL)
{
if (!add_dynamic_entry (DT_TEXTREL, 0))
- return false;
+ return FALSE;
}
/* Add dynamic STT_REGISTER symbols and corresponding DT_SPARC_REGISTER
@@ -1827,12 +1920,12 @@ sparc64_elf_size_dynamic_sections (output_bfd, info)
struct elf_link_local_dynamic_entry *entry, *e;
if (!add_dynamic_entry (DT_SPARC_REGISTER, 0))
- return false;
+ return FALSE;
entry = (struct elf_link_local_dynamic_entry *)
bfd_hash_allocate (&info->hash->table, sizeof (*entry));
if (entry == NULL)
- return false;
+ return FALSE;
/* We cheat here a little bit: the symbol will not be local, so we
put it at the end of the dynlocal linked list. We will fix it
@@ -1841,7 +1934,7 @@ sparc64_elf_size_dynamic_sections (output_bfd, info)
entry->isym.st_size = 0;
if (*app_regs [reg].name != '\0')
entry->isym.st_name
- = _bfd_elf_strtab_add (dynstr, app_regs[reg].name, false);
+ = _bfd_elf_strtab_add (dynstr, app_regs[reg].name, FALSE);
else
entry->isym.st_name = 0;
entry->isym.st_other = 0;
@@ -1865,38 +1958,40 @@ sparc64_elf_size_dynamic_sections (output_bfd, info)
}
#undef add_dynamic_entry
- return true;
+ return TRUE;
}
-#define SET_SEC_DO_RELAX(section) do { elf_section_data(section)->tdata = (void *)1; } while (0)
-#define SEC_DO_RELAX(section) (elf_section_data(section)->tdata == (void *)1)
+static bfd_boolean
+sparc64_elf_new_section_hook (abfd, sec)
+ bfd *abfd;
+ asection *sec;
+{
+ struct sparc64_elf_section_data *sdata;
+ bfd_size_type amt = sizeof (*sdata);
+
+ sdata = (struct sparc64_elf_section_data *) bfd_zalloc (abfd, amt);
+ if (sdata == NULL)
+ return FALSE;
+ sec->used_by_bfd = (PTR) sdata;
-static boolean
+ return _bfd_elf_new_section_hook (abfd, sec);
+}
+
+static bfd_boolean
sparc64_elf_relax_section (abfd, section, link_info, again)
bfd *abfd ATTRIBUTE_UNUSED;
asection *section ATTRIBUTE_UNUSED;
struct bfd_link_info *link_info ATTRIBUTE_UNUSED;
- boolean *again;
+ bfd_boolean *again;
{
- *again = false;
- SET_SEC_DO_RELAX (section);
- return true;
+ *again = FALSE;
+ sec_do_relax (section) = 1;
+ return TRUE;
}
-/* This is the condition under which finish_dynamic_symbol will be called
- from elflink.h. If elflink.h doesn't call our finish_dynamic_symbol
- routine, we'll need to do something about initializing any .plt and
- .got entries in relocate_section. */
-#define WILL_CALL_FINISH_DYNAMIC_SYMBOL(DYN, INFO, H) \
- ((DYN) \
- && ((INFO)->shared \
- || ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0) \
- && ((H)->dynindx != -1 \
- || ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0))
-
/* Relocate a SPARC64 ELF section. */
-static boolean
+static bfd_boolean
sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
contents, relocs, local_syms, local_sections)
bfd *output_bfd;
@@ -1919,6 +2014,9 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
Elf_Internal_Rela *rel;
Elf_Internal_Rela *relend;
+ if (info->relocatable)
+ return TRUE;
+
dynobj = elf_hash_table (info)->dynobj;
symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
sym_hashes = elf_sym_hashes (input_bfd);
@@ -1930,6 +2028,8 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
got_base = elf_hash_table (info)->hgot->root.u.def.value;
sgot = splt = sreloc = NULL;
+ if (dynobj != NULL)
+ splt = bfd_get_section_by_name (dynobj, ".plt");
rel = relocs;
relend = relocs + NUM_SHDR_ENTRIES (& elf_section_data (input_section)->rel_hdr);
@@ -1943,92 +2043,42 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
asection *sec;
bfd_vma relocation, off;
bfd_reloc_status_type r;
- boolean is_plt = false;
- boolean unresolved_reloc;
+ bfd_boolean is_plt = FALSE;
+ bfd_boolean unresolved_reloc;
r_type = ELF64_R_TYPE_ID (rel->r_info);
if (r_type < 0 || r_type >= (int) R_SPARC_max_std)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
howto = sparc64_elf_howto_table + r_type;
- r_symndx = ELF64_R_SYM (rel->r_info);
-
- if (info->relocateable)
- {
- /* This is a relocateable link. We don't have to change
- anything, unless the reloc is against a section symbol,
- in which case we have to adjust according to where the
- section symbol winds up in the output section. */
- if (r_symndx < symtab_hdr->sh_info)
- {
- sym = local_syms + r_symndx;
- if (ELF_ST_TYPE (sym->st_info) == STT_SECTION)
- {
- sec = local_sections[r_symndx];
- rel->r_addend += sec->output_offset + sym->st_value;
- }
- }
-
- continue;
- }
-
/* This is a final link. */
+ r_symndx = ELF64_R_SYM (rel->r_info);
h = NULL;
sym = NULL;
sec = NULL;
- unresolved_reloc = false;
+ unresolved_reloc = FALSE;
if (r_symndx < symtab_hdr->sh_info)
{
sym = local_syms + r_symndx;
sec = local_sections[r_symndx];
- relocation = _bfd_elf_rela_local_sym (output_bfd, sym, sec, rel);
+ relocation = _bfd_elf_rela_local_sym (output_bfd, sym, &sec, rel);
}
else
{
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- while (h->root.type == bfd_link_hash_indirect
- || h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
+ bfd_boolean warned;
- relocation = 0;
- if (h->root.type == bfd_link_hash_defined
- || h->root.type == bfd_link_hash_defweak)
- {
- sec = h->root.u.def.section;
- if (sec->output_section == NULL)
- /* Set a flag that will be cleared later if we find a
- relocation value for this symbol. output_section
- is typically NULL for symbols satisfied by a shared
- library. */
- unresolved_reloc = true;
- else
- relocation = (h->root.u.def.value
- + sec->output_section->vma
- + sec->output_offset);
- }
- else if (h->root.type == bfd_link_hash_undefweak)
- ;
- else if (info->shared
- && (!info->symbolic || info->allow_shlib_undefined)
- && !info->no_undefined
- && ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
- ;
- else
+ RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
+ r_symndx, symtab_hdr, sym_hashes,
+ h, sec, relocation,
+ unresolved_reloc, warned);
+ if (warned)
{
- if (! ((*info->callbacks->undefined_symbol)
- (info, h->root.root.string, input_bfd,
- input_section, rel->r_offset,
- (!info->shared || info->no_undefined
- || ELF_ST_VISIBILITY (h->other)))))
- return false;
-
/* To avoid generating warning messages about truncated
relocations, set the relocation's address to be the same as
the start of this section. */
-
if (input_section->output_section != NULL)
relocation = input_section->output_section->vma;
else
@@ -2090,7 +2140,8 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
case R_SPARC_UA16:
{
Elf_Internal_Rela outrel;
- boolean skip, relocate;
+ bfd_byte *loc;
+ bfd_boolean skip, relocate;
if (sreloc == NULL)
{
@@ -2101,7 +2152,7 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
elf_section_data (input_section)->rel_hdr.sh_name));
if (name == NULL)
- return false;
+ return FALSE;
BFD_ASSERT (strncmp (name, ".rela", 5) == 0
&& strcmp (bfd_get_section_name(input_bfd,
@@ -2112,16 +2163,16 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
BFD_ASSERT (sreloc != NULL);
}
- skip = false;
- relocate = false;
+ skip = FALSE;
+ relocate = FALSE;
outrel.r_offset =
_bfd_elf_section_offset (output_bfd, info, input_section,
rel->r_offset);
if (outrel.r_offset == (bfd_vma) -1)
- skip = true;
+ skip = TRUE;
else if (outrel.r_offset == (bfd_vma) -2)
- skip = true, relocate = true;
+ skip = TRUE, relocate = TRUE;
outrel.r_offset += (input_section->output_section->vma
+ input_section->output_offset);
@@ -2158,7 +2209,7 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
FIXME: Add code tracking needed dynamic relocs as
e.g. i386 has. */
if (h->dynindx == -1)
- skip = true, relocate = true;
+ skip = TRUE, relocate = TRUE;
break;
}
@@ -2190,21 +2241,13 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
if (is_plt)
sec = splt;
- else if (h == NULL)
- sec = local_sections[r_symndx];
- else
- {
- BFD_ASSERT (h->root.type == bfd_link_hash_defined
- || (h->root.type
- == bfd_link_hash_defweak));
- sec = h->root.u.def.section;
- }
- if (sec != NULL && bfd_is_abs_section (sec))
+
+ if (bfd_is_abs_section (sec))
indx = 0;
else if (sec == NULL || sec->owner == NULL)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
else
{
@@ -2229,7 +2272,7 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
(_("%s: probably compiled without -fPIC?"),
bfd_archive_filename (input_bfd));
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
}
@@ -2241,11 +2284,9 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
}
}
- bfd_elf64_swap_reloca_out (output_bfd, &outrel,
- (((Elf64_External_Rela *)
- sreloc->contents)
- + sreloc->reloc_count));
- ++sreloc->reloc_count;
+ loc = sreloc->contents;
+ loc += sreloc->reloc_count++ * sizeof (Elf64_External_Rela);
+ bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
/* This reloc will be computed at runtime, so there's no
need to do anything now. */
@@ -2271,13 +2312,13 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
if (h != NULL)
{
- boolean dyn;
+ bfd_boolean dyn;
off = h->got.offset;
BFD_ASSERT (off != (bfd_vma) -1);
dyn = elf_hash_table (info)->dynamic_sections_created;
- if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info, h)
+ if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info->shared, h)
|| (info->shared
&& (info->symbolic
|| h->dynindx == -1
@@ -2306,7 +2347,7 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
}
}
else
- unresolved_reloc = false;
+ unresolved_reloc = FALSE;
}
else
{
@@ -2325,8 +2366,9 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
if (info->shared)
{
- asection *srelgot;
+ asection *s;
Elf_Internal_Rela outrel;
+ bfd_byte *loc;
/* The Solaris 2.7 64-bit linker adds the contents
of the location to the value of the reloc.
@@ -2338,19 +2380,17 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
/* We need to generate a R_SPARC_RELATIVE reloc
for the dynamic linker. */
- srelgot = bfd_get_section_by_name(dynobj, ".rela.got");
- BFD_ASSERT (srelgot != NULL);
+ s = bfd_get_section_by_name(dynobj, ".rela.got");
+ BFD_ASSERT (s != NULL);
outrel.r_offset = (sgot->output_section->vma
+ sgot->output_offset
+ off);
outrel.r_info = ELF64_R_INFO (0, R_SPARC_RELATIVE);
outrel.r_addend = relocation;
- bfd_elf64_swap_reloca_out (output_bfd, &outrel,
- (((Elf64_External_Rela *)
- srelgot->contents)
- + srelgot->reloc_count));
- ++srelgot->reloc_count;
+ loc = s->contents;
+ loc += s->reloc_count++ * sizeof (Elf64_External_Rela);
+ bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
}
else
bfd_put_64 (output_bfd, relocation, sgot->contents + off);
@@ -2371,7 +2411,7 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
procedure linkage table. */
BFD_ASSERT (h != NULL);
- if (h->plt.offset == (bfd_vma) -1)
+ if (h->plt.offset == (bfd_vma) -1 || splt == NULL)
{
/* We didn't make a PLT entry for this symbol. This
happens when statically linking PIC code, or when
@@ -2379,22 +2419,16 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
goto do_default;
}
- if (splt == NULL)
- {
- splt = bfd_get_section_by_name (dynobj, ".plt");
- BFD_ASSERT (splt != NULL);
- }
-
relocation = (splt->output_section->vma
+ splt->output_offset
+ sparc64_elf_plt_entry_offset (h->plt.offset));
- unresolved_reloc = false;
+ unresolved_reloc = FALSE;
if (r_type == R_SPARC_WPLT30)
goto do_wplt30;
if (r_type == R_SPARC_PLT32 || r_type == R_SPARC_PLT64)
{
r_type = r_type == R_SPARC_PLT32 ? R_SPARC_32 : R_SPARC_64;
- is_plt = true;
+ is_plt = TRUE;
goto do_dynreloc;
}
goto do_default;
@@ -2475,7 +2509,7 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
case R_SPARC_WDISP30:
do_wplt30:
- if (SEC_DO_RELAX (input_section)
+ if (sec_do_relax (input_section)
&& rel->r_offset + 4 < input_section->_raw_size)
{
#define G0 0
@@ -2562,7 +2596,7 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
}
}
}
- /* FALLTHROUGH */
+ /* Fall through. */
default:
do_default:
@@ -2601,11 +2635,10 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
/* The Solaris native linker silently disregards
overflows. We don't, but this breaks stabs debugging
info, whose relocations are only 32-bits wide. Ignore
- overflows in this case. */
- if (r_type == R_SPARC_32
- && (input_section->flags & SEC_DEBUGGING) != 0
- && strcmp (bfd_section_name (input_bfd, input_section),
- ".stab") == 0)
+ overflows for discarded entries. */
+ if ((r_type == R_SPARC_32 || r_type == R_SPARC_DISP32)
+ && _bfd_elf_section_offset (output_bfd, info, input_section,
+ rel->r_offset) == (bfd_vma) -1)
break;
if (h != NULL)
@@ -2630,26 +2663,26 @@ sparc64_elf_relocate_section (output_bfd, info, input_bfd, input_section,
symtab_hdr->sh_link,
sym->st_name));
if (name == NULL)
- return false;
+ return FALSE;
if (*name == '\0')
name = bfd_section_name (input_bfd, sec);
}
if (! ((*info->callbacks->reloc_overflow)
(info, name, howto->name, (bfd_vma) 0,
input_bfd, input_section, rel->r_offset)))
- return false;
+ return FALSE;
}
break;
}
}
- return true;
+ return TRUE;
}
/* Finish up dynamic symbol handling. We set the contents of various
dynamic sections here. */
-static boolean
+static bfd_boolean
sparc64_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -2665,6 +2698,7 @@ sparc64_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
asection *splt;
asection *srela;
Elf_Internal_Rela rela;
+ bfd_byte *loc;
/* This symbol has an entry in the PLT. Set it up. */
@@ -2696,9 +2730,9 @@ sparc64_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
Sun forgot to read their own ABI and copied elf32-sparc behaviour,
thus .plt[4] has corresponding .rela.plt[0] and so on. */
- bfd_elf64_swap_reloca_out (output_bfd, &rela,
- ((Elf64_External_Rela *) srela->contents
- + (h->plt.offset - 4)));
+ loc = srela->contents;
+ loc += (h->plt.offset - 4) * sizeof (Elf64_External_Rela);
+ bfd_elf64_swap_reloca_out (output_bfd, &rela, loc);
if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
{
@@ -2720,6 +2754,7 @@ sparc64_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
asection *sgot;
asection *srela;
Elf_Internal_Rela rela;
+ bfd_byte *loc;
/* This symbol has an entry in the GOT. Set it up. */
@@ -2748,24 +2783,24 @@ sparc64_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
}
else
{
- bfd_put_64 (output_bfd, (bfd_vma) 0, sgot->contents + h->got.offset);
rela.r_info = ELF64_R_INFO (h->dynindx, R_SPARC_GLOB_DAT);
rela.r_addend = 0;
}
- bfd_elf64_swap_reloca_out (output_bfd, &rela,
- ((Elf64_External_Rela *) srela->contents
- + srela->reloc_count));
- ++srela->reloc_count;
+ bfd_put_64 (output_bfd, (bfd_vma) 0,
+ sgot->contents + (h->got.offset &~ (bfd_vma) 1));
+ loc = srela->contents;
+ loc += srela->reloc_count++ * sizeof (Elf64_External_Rela);
+ bfd_elf64_swap_reloca_out (output_bfd, &rela, loc);
}
if ((h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_COPY) != 0)
{
asection *s;
Elf_Internal_Rela rela;
+ bfd_byte *loc;
/* This symbols needs a copy reloc. Set it up. */
-
BFD_ASSERT (h->dynindx != -1);
s = bfd_get_section_by_name (h->root.u.def.section->owner,
@@ -2777,10 +2812,8 @@ sparc64_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
+ h->root.u.def.section->output_offset);
rela.r_info = ELF64_R_INFO (h->dynindx, R_SPARC_COPY);
rela.r_addend = 0;
- bfd_elf64_swap_reloca_out (output_bfd, &rela,
- ((Elf64_External_Rela *) s->contents
- + s->reloc_count));
- ++s->reloc_count;
+ loc = s->contents + s->reloc_count++ * sizeof (Elf64_External_Rela);
+ bfd_elf64_swap_reloca_out (output_bfd, &rela, loc);
}
/* Mark some specially defined symbols as absolute. */
@@ -2789,12 +2822,12 @@ sparc64_elf_finish_dynamic_symbol (output_bfd, info, h, sym)
|| strcmp (h->root.root.string, "_PROCEDURE_LINKAGE_TABLE_") == 0)
sym->st_shndx = SHN_ABS;
- return true;
+ return TRUE;
}
/* Finish up the dynamic sections. */
-static boolean
+static bfd_boolean
sparc64_elf_finish_dynamic_sections (output_bfd, info)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -2822,27 +2855,27 @@ sparc64_elf_finish_dynamic_sections (output_bfd, info)
{
Elf_Internal_Dyn dyn;
const char *name;
- boolean size;
+ bfd_boolean size;
bfd_elf64_swap_dyn_in (dynobj, dyncon, &dyn);
switch (dyn.d_tag)
{
- case DT_PLTGOT: name = ".plt"; size = false; break;
- case DT_PLTRELSZ: name = ".rela.plt"; size = true; break;
- case DT_JMPREL: name = ".rela.plt"; size = false; break;
+ case DT_PLTGOT: name = ".plt"; size = FALSE; break;
+ case DT_PLTRELSZ: name = ".rela.plt"; size = TRUE; break;
+ case DT_JMPREL: name = ".rela.plt"; size = FALSE; break;
case DT_SPARC_REGISTER:
if (stt_regidx == -1)
{
stt_regidx =
_bfd_elf_link_lookup_local_dynindx (info, output_bfd, -1);
if (stt_regidx == -1)
- return false;
+ return FALSE;
}
dyn.d_un.d_val = stt_regidx++;
bfd_elf64_swap_dyn_out (output_bfd, &dyn, dyncon);
/* fallthrough */
- default: name = NULL; size = false; break;
+ default: name = NULL; size = FALSE; break;
}
if (name != NULL)
@@ -2870,10 +2903,8 @@ sparc64_elf_finish_dynamic_sections (output_bfd, info)
/* Initialize the contents of the .plt section. */
if (splt->_raw_size > 0)
- {
- sparc64_elf_build_plt (output_bfd, splt->contents,
- (int) (splt->_raw_size / PLT_ENTRY_SIZE));
- }
+ sparc64_elf_build_plt (output_bfd, splt->contents,
+ (int) (splt->_raw_size / PLT_ENTRY_SIZE));
elf_section_data (splt->output_section)->this_hdr.sh_entsize =
PLT_ENTRY_SIZE;
@@ -2895,7 +2926,7 @@ sparc64_elf_finish_dynamic_sections (output_bfd, info)
elf_section_data (sgot->output_section)->this_hdr.sh_entsize = 8;
- return true;
+ return TRUE;
}
static enum elf_reloc_type_class
@@ -2920,25 +2951,25 @@ sparc64_elf_reloc_type_class (rela)
/* Merge backend specific data from an object file to the output
object file when linking. */
-static boolean
+static bfd_boolean
sparc64_elf_merge_private_bfd_data (ibfd, obfd)
bfd *ibfd;
bfd *obfd;
{
- boolean error;
+ bfd_boolean error;
flagword new_flags, old_flags;
int new_mm, old_mm;
if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour
|| bfd_get_flavour (obfd) != bfd_target_elf_flavour)
- return true;
+ return TRUE;
new_flags = elf_elfheader (ibfd)->e_flags;
old_flags = elf_elfheader (obfd)->e_flags;
if (!elf_flags_init (obfd)) /* First call, no flags set */
{
- elf_flags_init (obfd) = true;
+ elf_flags_init (obfd) = TRUE;
elf_elfheader (obfd)->e_flags = new_flags;
}
@@ -2947,7 +2978,7 @@ sparc64_elf_merge_private_bfd_data (ibfd, obfd)
else /* Incompatible flags */
{
- error = false;
+ error = FALSE;
#define EF_SPARC_ISA_EXTENSIONS \
(EF_SPARC_SUN_US1 | EF_SPARC_SUN_US3 | EF_SPARC_HAL_R1)
@@ -2969,7 +3000,7 @@ sparc64_elf_merge_private_bfd_data (ibfd, obfd)
if ((old_flags & (EF_SPARC_SUN_US1 | EF_SPARC_SUN_US3))
&& (old_flags & EF_SPARC_HAL_R1))
{
- error = true;
+ error = TRUE;
(*_bfd_error_handler)
(_("%s: linking UltraSPARC specific with HAL specific code"),
bfd_archive_filename (ibfd));
@@ -2988,7 +3019,7 @@ sparc64_elf_merge_private_bfd_data (ibfd, obfd)
/* Warn about any other mismatches */
if (new_flags != old_flags)
{
- error = true;
+ error = TRUE;
(*_bfd_error_handler)
(_("%s: uses different e_flags (0x%lx) fields than previous modules (0x%lx)"),
bfd_archive_filename (ibfd), (long) new_flags, (long) old_flags);
@@ -2999,18 +3030,18 @@ sparc64_elf_merge_private_bfd_data (ibfd, obfd)
if (error)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
/* MARCO: Set the correct entry size for the .stab section. */
-static boolean
+static bfd_boolean
sparc64_elf_fake_sections (abfd, hdr, sec)
bfd *abfd ATTRIBUTE_UNUSED;
- Elf32_Internal_Shdr *hdr ATTRIBUTE_UNUSED;
+ Elf_Internal_Shdr *hdr ATTRIBUTE_UNUSED;
asection *sec;
{
const char *name;
@@ -3022,8 +3053,8 @@ sparc64_elf_fake_sections (abfd, hdr, sec)
/* Even in the 64bit case the stab entries are only 12 bytes long. */
elf_section_data (sec)->this_hdr.sh_entsize = 12;
}
-
- return true;
+
+ return TRUE;
}
/* Print a STT_REGISTER symbol to file FILE. */
@@ -3056,7 +3087,7 @@ sparc64_elf_print_symbol_all (abfd, filep, symbol)
/* Set the right machine number for a SPARC64 ELF file. */
-static boolean
+static bfd_boolean
sparc64_elf_object_p (abfd)
bfd *abfd;
{
@@ -3084,14 +3115,14 @@ const struct elf_size_info sparc64_elf_size_info =
sizeof (Elf64_External_Sym),
sizeof (Elf64_External_Dyn),
sizeof (Elf_External_Note),
- 4, /* hash-table entry size */
- /* internal relocations per external relocations.
+ 4, /* hash-table entry size. */
+ /* Internal relocations per external relocations.
For link purposes we use just 1 internal per
1 external, for assembly and slurp symbol table
we use 2. */
1,
- 64, /* arch_size */
- 8, /* file_align */
+ 64, /* arch_size. */
+ 3, /* log_file_align. */
ELFCLASS64,
EV_CURRENT,
bfd_elf64_write_out_phdrs,
@@ -3103,10 +3134,10 @@ const struct elf_size_info sparc64_elf_size_info =
bfd_elf64_slurp_symbol_table,
bfd_elf64_swap_dyn_in,
bfd_elf64_swap_dyn_out,
- NULL,
- NULL,
- NULL,
- NULL
+ bfd_elf64_swap_reloc_in,
+ bfd_elf64_swap_reloc_out,
+ bfd_elf64_swap_reloca_in,
+ bfd_elf64_swap_reloca_out
};
#define TARGET_BIG_SYM bfd_elf64_sparc_vec
@@ -3129,12 +3160,16 @@ const struct elf_size_info sparc64_elf_size_info =
sparc64_elf_get_reloc_upper_bound
#define bfd_elf64_get_dynamic_reloc_upper_bound \
sparc64_elf_get_dynamic_reloc_upper_bound
+#define bfd_elf64_canonicalize_reloc \
+ sparc64_elf_canonicalize_reloc
#define bfd_elf64_canonicalize_dynamic_reloc \
sparc64_elf_canonicalize_dynamic_reloc
#define bfd_elf64_bfd_reloc_type_lookup \
sparc64_elf_reloc_type_lookup
#define bfd_elf64_bfd_relax_section \
sparc64_elf_relax_section
+#define bfd_elf64_new_section_hook \
+ sparc64_elf_new_section_hook
#define elf_backend_create_dynamic_sections \
_bfd_elf_create_dynamic_sections
@@ -3175,11 +3210,11 @@ const struct elf_size_info sparc64_elf_size_info =
#define elf_backend_want_got_plt 0
#define elf_backend_plt_readonly 0
#define elf_backend_want_plt_sym 1
+#define elf_backend_rela_normal 1
/* Section 5.2.4 of the ABI specifies a 256-byte boundary for the table. */
#define elf_backend_plt_alignment 8
#define elf_backend_got_header_size 8
-#define elf_backend_plt_header_size PLT_HEADER_SIZE
#include "elf64-target.h"
diff --git a/contrib/binutils/bfd/elf64-x86-64.c b/contrib/binutils/bfd/elf64-x86-64.c
index a7303d0..a1d6250 100644
--- a/contrib/binutils/bfd/elf64-x86-64.c
+++ b/contrib/binutils/bfd/elf64-x86-64.c
@@ -1,22 +1,22 @@
/* X86-64 specific support for 64-bit ELF
- Copyright 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
Contributed by Jan Hubicka <jh@suse.cz>.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "bfd.h"
#include "sysdep.h"
@@ -26,9 +26,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "elf/x86-64.h"
-/* We use only the RELA entries. */
-#define USE_RELA 1
-
/* In case we're on a 32-bit machine, construct a 64-bit "-1" value. */
#define MINUS_ONE (~ (bfd_vma) 0)
@@ -37,59 +34,83 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
special_function, name, partial_inplace, src_mask, dst_pack, pcrel_offset. */
static reloc_howto_type x86_64_elf_howto_table[] =
{
- HOWTO(R_X86_64_NONE, 0, 0, 0, false, 0, complain_overflow_dont,
- bfd_elf_generic_reloc, "R_X86_64_NONE", false, 0x00000000, 0x00000000,
- false),
- HOWTO(R_X86_64_64, 0, 4, 64, false, 0, complain_overflow_bitfield,
- bfd_elf_generic_reloc, "R_X86_64_64", false, MINUS_ONE, MINUS_ONE,
- false),
- HOWTO(R_X86_64_PC32, 0, 4, 32, true, 0, complain_overflow_signed,
- bfd_elf_generic_reloc, "R_X86_64_PC32", false, 0xffffffff, 0xffffffff,
- true),
- HOWTO(R_X86_64_GOT32, 0, 4, 32, false, 0, complain_overflow_signed,
- bfd_elf_generic_reloc, "R_X86_64_GOT32", false, 0xffffffff, 0xffffffff,
- false),
- HOWTO(R_X86_64_PLT32, 0, 4, 32, true, 0, complain_overflow_signed,
- bfd_elf_generic_reloc, "R_X86_64_PLT32", false, 0xffffffff, 0xffffffff,
- true),
- HOWTO(R_X86_64_COPY, 0, 4, 32, false, 0, complain_overflow_bitfield,
- bfd_elf_generic_reloc, "R_X86_64_COPY", false, 0xffffffff, 0xffffffff,
- false),
- HOWTO(R_X86_64_GLOB_DAT, 0, 4, 64, false, 0, complain_overflow_bitfield,
- bfd_elf_generic_reloc, "R_X86_64_GLOB_DAT", false, MINUS_ONE,
- MINUS_ONE, false),
- HOWTO(R_X86_64_JUMP_SLOT, 0, 4, 64, false, 0, complain_overflow_bitfield,
- bfd_elf_generic_reloc, "R_X86_64_JUMP_SLOT", false, MINUS_ONE,
- MINUS_ONE, false),
- HOWTO(R_X86_64_RELATIVE, 0, 4, 64, false, 0, complain_overflow_bitfield,
- bfd_elf_generic_reloc, "R_X86_64_RELATIVE", false, MINUS_ONE,
- MINUS_ONE, false),
- HOWTO(R_X86_64_GOTPCREL, 0, 4, 32, true,0 , complain_overflow_signed,
- bfd_elf_generic_reloc, "R_X86_64_GOTPCREL", false, 0xffffffff,
- 0xffffffff, true),
- HOWTO(R_X86_64_32, 0, 4, 32, false, 0, complain_overflow_unsigned,
- bfd_elf_generic_reloc, "R_X86_64_32", false, 0xffffffff, 0xffffffff,
- false),
- HOWTO(R_X86_64_32S, 0, 4, 32, false, 0, complain_overflow_signed,
- bfd_elf_generic_reloc, "R_X86_64_32S", false, 0xffffffff, 0xffffffff,
- false),
- HOWTO(R_X86_64_16, 0, 1, 16, false, 0, complain_overflow_bitfield,
- bfd_elf_generic_reloc, "R_X86_64_16", false, 0xffff, 0xffff, false),
- HOWTO(R_X86_64_PC16,0, 1, 16, true, 0, complain_overflow_bitfield,
- bfd_elf_generic_reloc, "R_X86_64_PC16", false, 0xffff, 0xffff, true),
- HOWTO(R_X86_64_8, 0, 0, 8, false, 0, complain_overflow_signed,
- bfd_elf_generic_reloc, "R_X86_64_8", false, 0xff, 0xff, false),
- HOWTO(R_X86_64_PC8, 0, 0, 8, true, 0, complain_overflow_signed,
- bfd_elf_generic_reloc, "R_X86_64_PC8", false, 0xff, 0xff, true),
+ HOWTO(R_X86_64_NONE, 0, 0, 0, FALSE, 0, complain_overflow_dont,
+ bfd_elf_generic_reloc, "R_X86_64_NONE", FALSE, 0x00000000, 0x00000000,
+ FALSE),
+ HOWTO(R_X86_64_64, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_X86_64_64", FALSE, MINUS_ONE, MINUS_ONE,
+ FALSE),
+ HOWTO(R_X86_64_PC32, 0, 2, 32, TRUE, 0, complain_overflow_signed,
+ bfd_elf_generic_reloc, "R_X86_64_PC32", FALSE, 0xffffffff, 0xffffffff,
+ TRUE),
+ HOWTO(R_X86_64_GOT32, 0, 2, 32, FALSE, 0, complain_overflow_signed,
+ bfd_elf_generic_reloc, "R_X86_64_GOT32", FALSE, 0xffffffff, 0xffffffff,
+ FALSE),
+ HOWTO(R_X86_64_PLT32, 0, 2, 32, TRUE, 0, complain_overflow_signed,
+ bfd_elf_generic_reloc, "R_X86_64_PLT32", FALSE, 0xffffffff, 0xffffffff,
+ TRUE),
+ HOWTO(R_X86_64_COPY, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_X86_64_COPY", FALSE, 0xffffffff, 0xffffffff,
+ FALSE),
+ HOWTO(R_X86_64_GLOB_DAT, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_X86_64_GLOB_DAT", FALSE, MINUS_ONE,
+ MINUS_ONE, FALSE),
+ HOWTO(R_X86_64_JUMP_SLOT, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_X86_64_JUMP_SLOT", FALSE, MINUS_ONE,
+ MINUS_ONE, FALSE),
+ HOWTO(R_X86_64_RELATIVE, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_X86_64_RELATIVE", FALSE, MINUS_ONE,
+ MINUS_ONE, FALSE),
+ HOWTO(R_X86_64_GOTPCREL, 0, 2, 32, TRUE, 0, complain_overflow_signed,
+ bfd_elf_generic_reloc, "R_X86_64_GOTPCREL", FALSE, 0xffffffff,
+ 0xffffffff, TRUE),
+ HOWTO(R_X86_64_32, 0, 2, 32, FALSE, 0, complain_overflow_unsigned,
+ bfd_elf_generic_reloc, "R_X86_64_32", FALSE, 0xffffffff, 0xffffffff,
+ FALSE),
+ HOWTO(R_X86_64_32S, 0, 2, 32, FALSE, 0, complain_overflow_signed,
+ bfd_elf_generic_reloc, "R_X86_64_32S", FALSE, 0xffffffff, 0xffffffff,
+ FALSE),
+ HOWTO(R_X86_64_16, 0, 1, 16, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_X86_64_16", FALSE, 0xffff, 0xffff, FALSE),
+ HOWTO(R_X86_64_PC16,0, 1, 16, TRUE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_X86_64_PC16", FALSE, 0xffff, 0xffff, TRUE),
+ HOWTO(R_X86_64_8, 0, 0, 8, FALSE, 0, complain_overflow_signed,
+ bfd_elf_generic_reloc, "R_X86_64_8", FALSE, 0xff, 0xff, FALSE),
+ HOWTO(R_X86_64_PC8, 0, 0, 8, TRUE, 0, complain_overflow_signed,
+ bfd_elf_generic_reloc, "R_X86_64_PC8", FALSE, 0xff, 0xff, TRUE),
+ HOWTO(R_X86_64_DTPMOD64, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_X86_64_DTPMOD64", FALSE, MINUS_ONE,
+ MINUS_ONE, FALSE),
+ HOWTO(R_X86_64_DTPOFF64, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_X86_64_DTPOFF64", FALSE, MINUS_ONE,
+ MINUS_ONE, FALSE),
+ HOWTO(R_X86_64_TPOFF64, 0, 4, 64, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_X86_64_TPOFF64", FALSE, MINUS_ONE,
+ MINUS_ONE, FALSE),
+ HOWTO(R_X86_64_TLSGD, 0, 2, 32, TRUE, 0, complain_overflow_signed,
+ bfd_elf_generic_reloc, "R_X86_64_TLSGD", FALSE, 0xffffffff,
+ 0xffffffff, TRUE),
+ HOWTO(R_X86_64_TLSLD, 0, 2, 32, TRUE, 0, complain_overflow_signed,
+ bfd_elf_generic_reloc, "R_X86_64_TLSLD", FALSE, 0xffffffff,
+ 0xffffffff, TRUE),
+ HOWTO(R_X86_64_DTPOFF32, 0, 2, 32, FALSE, 0, complain_overflow_bitfield,
+ bfd_elf_generic_reloc, "R_X86_64_DTPOFF32", FALSE, 0xffffffff,
+ 0xffffffff, FALSE),
+ HOWTO(R_X86_64_GOTTPOFF, 0, 2, 32, TRUE, 0, complain_overflow_signed,
+ bfd_elf_generic_reloc, "R_X86_64_GOTTPOFF", FALSE, 0xffffffff,
+ 0xffffffff, TRUE),
+ HOWTO(R_X86_64_TPOFF32, 0, 2, 32, FALSE, 0, complain_overflow_signed,
+ bfd_elf_generic_reloc, "R_X86_64_TPOFF32", FALSE, 0xffffffff,
+ 0xffffffff, FALSE),
/* GNU extension to record C++ vtable hierarchy. */
- HOWTO (R_X86_64_GNU_VTINHERIT, 0, 4, 0, false, 0, complain_overflow_dont,
- NULL, "R_X86_64_GNU_VTINHERIT", false, 0, 0, false),
+ HOWTO (R_X86_64_GNU_VTINHERIT, 0, 4, 0, FALSE, 0, complain_overflow_dont,
+ NULL, "R_X86_64_GNU_VTINHERIT", FALSE, 0, 0, FALSE),
/* GNU extension to record C++ vtable member usage. */
- HOWTO (R_X86_64_GNU_VTENTRY, 0, 4, 0, false, 0, complain_overflow_dont,
- _bfd_elf_rel_vtable_reloc_fn, "R_X86_64_GNU_VTENTRY", false, 0, 0,
- false)
+ HOWTO (R_X86_64_GNU_VTENTRY, 0, 4, 0, FALSE, 0, complain_overflow_dont,
+ _bfd_elf_rel_vtable_reloc_fn, "R_X86_64_GNU_VTENTRY", FALSE, 0, 0,
+ FALSE)
};
/* Map BFD relocs to the x86_64 elf relocs. */
@@ -117,68 +138,26 @@ static const struct elf_reloc_map x86_64_reloc_map[] =
{ BFD_RELOC_16_PCREL, R_X86_64_PC16, },
{ BFD_RELOC_8, R_X86_64_8, },
{ BFD_RELOC_8_PCREL, R_X86_64_PC8, },
+ { BFD_RELOC_X86_64_DTPMOD64, R_X86_64_DTPMOD64, },
+ { BFD_RELOC_X86_64_DTPOFF64, R_X86_64_DTPOFF64, },
+ { BFD_RELOC_X86_64_TPOFF64, R_X86_64_TPOFF64, },
+ { BFD_RELOC_X86_64_TLSGD, R_X86_64_TLSGD, },
+ { BFD_RELOC_X86_64_TLSLD, R_X86_64_TLSLD, },
+ { BFD_RELOC_X86_64_DTPOFF32, R_X86_64_DTPOFF32, },
+ { BFD_RELOC_X86_64_GOTTPOFF, R_X86_64_GOTTPOFF, },
+ { BFD_RELOC_X86_64_TPOFF32, R_X86_64_TPOFF32, },
{ BFD_RELOC_VTABLE_INHERIT, R_X86_64_GNU_VTINHERIT, },
{ BFD_RELOC_VTABLE_ENTRY, R_X86_64_GNU_VTENTRY, },
};
-static reloc_howto_type *elf64_x86_64_reloc_type_lookup
- PARAMS ((bfd *, bfd_reloc_code_real_type));
-static void elf64_x86_64_info_to_howto
- PARAMS ((bfd *, arelent *, Elf64_Internal_Rela *));
-static boolean elf64_x86_64_grok_prstatus
- PARAMS ((bfd *, Elf_Internal_Note *));
-static boolean elf64_x86_64_grok_psinfo
- PARAMS ((bfd *, Elf_Internal_Note *));
-static struct bfd_link_hash_table *elf64_x86_64_link_hash_table_create
- PARAMS ((bfd *));
-static boolean elf64_x86_64_elf_object_p PARAMS ((bfd *abfd));
-static boolean create_got_section
- PARAMS((bfd *, struct bfd_link_info *));
-static boolean elf64_x86_64_create_dynamic_sections
- PARAMS((bfd *, struct bfd_link_info *));
-static void elf64_x86_64_copy_indirect_symbol
- PARAMS ((struct elf_backend_data *, struct elf_link_hash_entry *,
- struct elf_link_hash_entry *));
-static boolean elf64_x86_64_check_relocs
- PARAMS ((bfd *, struct bfd_link_info *, asection *sec,
- const Elf_Internal_Rela *));
-static asection *elf64_x86_64_gc_mark_hook
- PARAMS ((asection *, struct bfd_link_info *, Elf_Internal_Rela *,
- struct elf_link_hash_entry *, Elf_Internal_Sym *));
-
-static boolean elf64_x86_64_gc_sweep_hook
- PARAMS ((bfd *, struct bfd_link_info *, asection *,
- const Elf_Internal_Rela *));
-
-static struct bfd_hash_entry *link_hash_newfunc
- PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-static boolean elf64_x86_64_adjust_dynamic_symbol
- PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *));
-
-static boolean allocate_dynrelocs
- PARAMS ((struct elf_link_hash_entry *, PTR));
-static boolean readonly_dynrelocs
- PARAMS ((struct elf_link_hash_entry *, PTR));
-static boolean elf64_x86_64_size_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *));
-static boolean elf64_x86_64_relocate_section
- PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
- Elf_Internal_Rela *, Elf_Internal_Sym *, asection **));
-static boolean elf64_x86_64_finish_dynamic_symbol
- PARAMS ((bfd *, struct bfd_link_info *, struct elf_link_hash_entry *,
- Elf_Internal_Sym *sym));
-static boolean elf64_x86_64_finish_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *));
-static enum elf_reloc_type_class elf64_x86_64_reloc_type_class
- PARAMS ((const Elf_Internal_Rela *));
/* Given a BFD reloc type, return a HOWTO structure. */
static reloc_howto_type *
-elf64_x86_64_reloc_type_lookup (abfd, code)
- bfd *abfd ATTRIBUTE_UNUSED;
- bfd_reloc_code_real_type code;
+elf64_x86_64_reloc_type_lookup (bfd *abfd ATTRIBUTE_UNUSED,
+ bfd_reloc_code_real_type code)
{
unsigned int i;
+
for (i = 0; i < sizeof (x86_64_reloc_map) / sizeof (struct elf_reloc_map);
i++)
{
@@ -191,33 +170,29 @@ elf64_x86_64_reloc_type_lookup (abfd, code)
/* Given an x86_64 ELF reloc type, fill in an arelent structure. */
static void
-elf64_x86_64_info_to_howto (abfd, cache_ptr, dst)
- bfd *abfd ATTRIBUTE_UNUSED;
- arelent *cache_ptr;
- Elf64_Internal_Rela *dst;
+elf64_x86_64_info_to_howto (bfd *abfd ATTRIBUTE_UNUSED, arelent *cache_ptr,
+ Elf_Internal_Rela *dst)
{
unsigned r_type, i;
r_type = ELF64_R_TYPE (dst->r_info);
if (r_type < (unsigned int) R_X86_64_GNU_VTINHERIT)
{
- BFD_ASSERT (r_type <= (unsigned int) R_X86_64_PC8);
+ BFD_ASSERT (r_type <= (unsigned int) R_X86_64_TPOFF32);
i = r_type;
}
else
{
BFD_ASSERT (r_type < (unsigned int) R_X86_64_max);
- i = r_type - ((unsigned int) R_X86_64_GNU_VTINHERIT - R_X86_64_PC8 - 1);
+ i = r_type - ((unsigned int) R_X86_64_GNU_VTINHERIT - R_X86_64_TPOFF32 - 1);
}
cache_ptr->howto = &x86_64_elf_howto_table[i];
BFD_ASSERT (r_type == cache_ptr->howto->type);
}
/* Support for core dump NOTE sections. */
-static boolean
-elf64_x86_64_grok_prstatus (abfd, note)
- bfd *abfd;
- Elf_Internal_Note *note;
+static bfd_boolean
+elf64_x86_64_grok_prstatus (bfd *abfd, Elf_Internal_Note *note)
{
int offset;
size_t raw_size;
@@ -225,7 +200,7 @@ elf64_x86_64_grok_prstatus (abfd, note)
switch (note->descsz)
{
default:
- return false;
+ return FALSE;
case 336: /* sizeof(istruct elf_prstatus) on Linux/x86_64 */
/* pr_cursig */
@@ -248,15 +223,13 @@ elf64_x86_64_grok_prstatus (abfd, note)
raw_size, note->descpos + offset);
}
-static boolean
-elf64_x86_64_grok_psinfo (abfd, note)
- bfd *abfd;
- Elf_Internal_Note *note;
+static bfd_boolean
+elf64_x86_64_grok_psinfo (bfd *abfd, Elf_Internal_Note *note)
{
switch (note->descsz)
{
default:
- return false;
+ return FALSE;
case 136: /* sizeof(struct elf_prpsinfo) on Linux/x86_64 */
elf_tdata (abfd)->core_program
@@ -277,7 +250,7 @@ elf64_x86_64_grok_psinfo (abfd, note)
command[n - 1] = '\0';
}
- return true;
+ return TRUE;
}
/* Functions for the x86-64 ELF linker. */
@@ -287,6 +260,12 @@ elf64_x86_64_grok_psinfo (abfd, note)
#define ELF_DYNAMIC_INTERPRETER "/lib/ld64.so.1"
+/* If ELIMINATE_COPY_RELOCS is non-zero, the linker will try to avoid
+ copying dynamic variables from a shared lib into an app's dynbss
+ section, and instead use a dynamic relocation to point into the
+ shared lib. */
+#define ELIMINATE_COPY_RELOCS 1
+
/* The size in bytes of an entry in the global offset table. */
#define GOT_ENTRY_SIZE 8
@@ -346,8 +325,32 @@ struct elf64_x86_64_link_hash_entry
/* Track dynamic relocs copied for this symbol. */
struct elf64_x86_64_dyn_relocs *dyn_relocs;
+
+#define GOT_UNKNOWN 0
+#define GOT_NORMAL 1
+#define GOT_TLS_GD 2
+#define GOT_TLS_IE 3
+ unsigned char tls_type;
+};
+
+#define elf64_x86_64_hash_entry(ent) \
+ ((struct elf64_x86_64_link_hash_entry *)(ent))
+
+struct elf64_x86_64_obj_tdata
+{
+ struct elf_obj_tdata root;
+
+ /* tls_type for each local got entry. */
+ char *local_got_tls_type;
};
+#define elf64_x86_64_tdata(abfd) \
+ ((struct elf64_x86_64_obj_tdata *) (abfd)->tdata.any)
+
+#define elf64_x86_64_local_got_tls_type(abfd) \
+ (elf64_x86_64_tdata (abfd)->local_got_tls_type)
+
+
/* x86-64 ELF linker hash table. */
struct elf64_x86_64_link_hash_table
@@ -363,6 +366,11 @@ struct elf64_x86_64_link_hash_table
asection *sdynbss;
asection *srelbss;
+ union {
+ bfd_signed_vma refcount;
+ bfd_vma offset;
+ } tls_ld_got;
+
/* Small local sym to section mapping cache. */
struct sym_sec_cache sym_sec;
};
@@ -375,10 +383,8 @@ struct elf64_x86_64_link_hash_table
/* Create an entry in an x86-64 ELF linker hash table. */
static struct bfd_hash_entry *
-link_hash_newfunc (entry, table, string)
- struct bfd_hash_entry *entry;
- struct bfd_hash_table *table;
- const char *string;
+link_hash_newfunc (struct bfd_hash_entry *entry, struct bfd_hash_table *table,
+ const char *string)
{
/* Allocate the structure if it has not already been allocated by a
subclass. */
@@ -398,6 +404,7 @@ link_hash_newfunc (entry, table, string)
eh = (struct elf64_x86_64_link_hash_entry *) entry;
eh->dyn_relocs = NULL;
+ eh->tls_type = GOT_UNKNOWN;
}
return entry;
@@ -406,8 +413,7 @@ link_hash_newfunc (entry, table, string)
/* Create an X86-64 ELF linker hash table. */
static struct bfd_link_hash_table *
-elf64_x86_64_link_hash_table_create (abfd)
- bfd *abfd;
+elf64_x86_64_link_hash_table_create (bfd *abfd)
{
struct elf64_x86_64_link_hash_table *ret;
bfd_size_type amt = sizeof (struct elf64_x86_64_link_hash_table);
@@ -430,6 +436,7 @@ elf64_x86_64_link_hash_table_create (abfd)
ret->sdynbss = NULL;
ret->srelbss = NULL;
ret->sym_sec.abfd = NULL;
+ ret->tls_ld_got.refcount = 0;
return &ret->elf.root;
}
@@ -437,15 +444,13 @@ elf64_x86_64_link_hash_table_create (abfd)
/* Create .got, .gotplt, and .rela.got sections in DYNOBJ, and set up
shortcuts to them in our hash table. */
-static boolean
-create_got_section (dynobj, info)
- bfd *dynobj;
- struct bfd_link_info *info;
+static bfd_boolean
+create_got_section (bfd *dynobj, struct bfd_link_info *info)
{
struct elf64_x86_64_link_hash_table *htab;
if (! _bfd_elf_create_got_section (dynobj, info))
- return false;
+ return FALSE;
htab = elf64_x86_64_hash_table (info);
htab->sgot = bfd_get_section_by_name (dynobj, ".got");
@@ -460,27 +465,25 @@ create_got_section (dynobj, info)
| SEC_IN_MEMORY | SEC_LINKER_CREATED
| SEC_READONLY))
|| ! bfd_set_section_alignment (dynobj, htab->srelgot, 3))
- return false;
- return true;
+ return FALSE;
+ return TRUE;
}
/* Create .plt, .rela.plt, .got, .got.plt, .rela.got, .dynbss, and
.rela.bss sections in DYNOBJ, and set up shortcuts to them in our
hash table. */
-static boolean
-elf64_x86_64_create_dynamic_sections (dynobj, info)
- bfd *dynobj;
- struct bfd_link_info *info;
+static bfd_boolean
+elf64_x86_64_create_dynamic_sections (bfd *dynobj, struct bfd_link_info *info)
{
struct elf64_x86_64_link_hash_table *htab;
htab = elf64_x86_64_hash_table (info);
if (!htab->sgot && !create_got_section (dynobj, info))
- return false;
+ return FALSE;
if (!_bfd_elf_create_dynamic_sections (dynobj, info))
- return false;
+ return FALSE;
htab->splt = bfd_get_section_by_name (dynobj, ".plt");
htab->srelplt = bfd_get_section_by_name (dynobj, ".rela.plt");
@@ -492,15 +495,15 @@ elf64_x86_64_create_dynamic_sections (dynobj, info)
|| (!info->shared && !htab->srelbss))
abort ();
- return true;
+ return TRUE;
}
/* Copy the extra info we tack onto an elf_link_hash_entry. */
static void
-elf64_x86_64_copy_indirect_symbol (bed, dir, ind)
- struct elf_backend_data *bed;
- struct elf_link_hash_entry *dir, *ind;
+elf64_x86_64_copy_indirect_symbol (const struct elf_backend_data *bed,
+ struct elf_link_hash_entry *dir,
+ struct elf_link_hash_entry *ind)
{
struct elf64_x86_64_link_hash_entry *edir, *eind;
@@ -541,28 +544,73 @@ elf64_x86_64_copy_indirect_symbol (bed, dir, ind)
eind->dyn_relocs = NULL;
}
- _bfd_elf_link_hash_copy_indirect (bed, dir, ind);
+ if (ind->root.type == bfd_link_hash_indirect
+ && dir->got.refcount <= 0)
+ {
+ edir->tls_type = eind->tls_type;
+ eind->tls_type = GOT_UNKNOWN;
+ }
+
+ if (ELIMINATE_COPY_RELOCS
+ && ind->root.type != bfd_link_hash_indirect
+ && (dir->elf_link_hash_flags & ELF_LINK_HASH_DYNAMIC_ADJUSTED) != 0)
+ /* If called to transfer flags for a weakdef during processing
+ of elf_adjust_dynamic_symbol, don't copy ELF_LINK_NON_GOT_REF.
+ We clear it ourselves for ELIMINATE_COPY_RELOCS. */
+ dir->elf_link_hash_flags |=
+ (ind->elf_link_hash_flags & (ELF_LINK_HASH_REF_DYNAMIC
+ | ELF_LINK_HASH_REF_REGULAR
+ | ELF_LINK_HASH_REF_REGULAR_NONWEAK
+ | ELF_LINK_HASH_NEEDS_PLT));
+ else
+ _bfd_elf_link_hash_copy_indirect (bed, dir, ind);
+}
+
+static bfd_boolean
+elf64_x86_64_mkobject (bfd *abfd)
+{
+ bfd_size_type amt = sizeof (struct elf64_x86_64_obj_tdata);
+ abfd->tdata.any = bfd_zalloc (abfd, amt);
+ if (abfd->tdata.any == NULL)
+ return FALSE;
+ return TRUE;
}
-static boolean
-elf64_x86_64_elf_object_p (abfd)
- bfd *abfd;
+static bfd_boolean
+elf64_x86_64_elf_object_p (bfd *abfd)
{
/* Set the right machine number for an x86-64 elf64 file. */
bfd_default_set_arch_mach (abfd, bfd_arch_i386, bfd_mach_x86_64);
- return true;
+ return TRUE;
+}
+
+static int
+elf64_x86_64_tls_transition (struct bfd_link_info *info, int r_type, int is_local)
+{
+ if (info->shared)
+ return r_type;
+
+ switch (r_type)
+ {
+ case R_X86_64_TLSGD:
+ case R_X86_64_GOTTPOFF:
+ if (is_local)
+ return R_X86_64_TPOFF32;
+ return R_X86_64_GOTTPOFF;
+ case R_X86_64_TLSLD:
+ return R_X86_64_TPOFF32;
+ }
+
+ return r_type;
}
/* Look through the relocs for a section during the first phase, and
calculate needed space in the global offset table, procedure
linkage table, and dynamic reloc sections. */
-static boolean
-elf64_x86_64_check_relocs (abfd, info, sec, relocs)
- bfd *abfd;
- struct bfd_link_info *info;
- asection *sec;
- const Elf_Internal_Rela *relocs;
+static bfd_boolean
+elf64_x86_64_check_relocs (bfd *abfd, struct bfd_link_info *info, asection *sec,
+ const Elf_Internal_Rela *relocs)
{
struct elf64_x86_64_link_hash_table *htab;
Elf_Internal_Shdr *symtab_hdr;
@@ -571,8 +619,8 @@ elf64_x86_64_check_relocs (abfd, info, sec, relocs)
const Elf_Internal_Rela *rel_end;
asection *sreloc;
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
htab = elf64_x86_64_hash_table (info);
symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
@@ -583,17 +631,19 @@ elf64_x86_64_check_relocs (abfd, info, sec, relocs)
rel_end = relocs + sec->reloc_count;
for (rel = relocs; rel < rel_end; rel++)
{
+ unsigned int r_type;
unsigned long r_symndx;
struct elf_link_hash_entry *h;
r_symndx = ELF64_R_SYM (rel->r_info);
+ r_type = ELF64_R_TYPE (rel->r_info);
if (r_symndx >= NUM_SHDR_ENTRIES (symtab_hdr))
{
(*_bfd_error_handler) (_("%s: bad symbol index: %d"),
bfd_archive_filename (abfd),
r_symndx);
- return false;
+ return FALSE;
}
if (r_symndx < symtab_hdr->sh_info)
@@ -601,44 +651,109 @@ elf64_x86_64_check_relocs (abfd, info, sec, relocs)
else
h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- switch (ELF64_R_TYPE (rel->r_info))
+ r_type = elf64_x86_64_tls_transition (info, r_type, h == NULL);
+ switch (r_type)
{
- case R_X86_64_GOT32:
- case R_X86_64_GOTPCREL:
- /* This symbol requires a global offset table entry. */
- if (h != NULL)
+ case R_X86_64_TLSLD:
+ htab->tls_ld_got.refcount += 1;
+ goto create_got;
+
+ case R_X86_64_TPOFF32:
+ if (info->shared)
{
- h->got.refcount += 1;
+ (*_bfd_error_handler)
+ (_("%s: relocation %s can not be used when making a shared object; recompile with -fPIC"),
+ bfd_archive_filename (abfd),
+ x86_64_elf_howto_table[r_type].name);
+ bfd_set_error (bfd_error_bad_value);
+ return FALSE;
}
- else
- {
- bfd_signed_vma *local_got_refcounts;
+ break;
- /* This is a global offset table entry for a local symbol. */
- local_got_refcounts = elf_local_got_refcounts (abfd);
- if (local_got_refcounts == NULL)
- {
- bfd_size_type size;
-
- size = symtab_hdr->sh_info;
- size *= sizeof (bfd_signed_vma);
- local_got_refcounts = ((bfd_signed_vma *)
- bfd_zalloc (abfd, size));
- if (local_got_refcounts == NULL)
- return false;
- elf_local_got_refcounts (abfd) = local_got_refcounts;
- }
- local_got_refcounts[r_symndx] += 1;
- }
+ case R_X86_64_GOTTPOFF:
+ if (info->shared)
+ info->flags |= DF_STATIC_TLS;
+ /* Fall through */
+
+ case R_X86_64_GOT32:
+ case R_X86_64_GOTPCREL:
+ case R_X86_64_TLSGD:
+ /* This symbol requires a global offset table entry. */
+ {
+ int tls_type, old_tls_type;
+
+ switch (r_type)
+ {
+ default: tls_type = GOT_NORMAL; break;
+ case R_X86_64_TLSGD: tls_type = GOT_TLS_GD; break;
+ case R_X86_64_GOTTPOFF: tls_type = GOT_TLS_IE; break;
+ }
+
+ if (h != NULL)
+ {
+ h->got.refcount += 1;
+ old_tls_type = elf64_x86_64_hash_entry (h)->tls_type;
+ }
+ else
+ {
+ bfd_signed_vma *local_got_refcounts;
+
+ /* This is a global offset table entry for a local symbol. */
+ local_got_refcounts = elf_local_got_refcounts (abfd);
+ if (local_got_refcounts == NULL)
+ {
+ bfd_size_type size;
+
+ size = symtab_hdr->sh_info;
+ size *= sizeof (bfd_signed_vma) + sizeof (char);
+ local_got_refcounts = ((bfd_signed_vma *)
+ bfd_zalloc (abfd, size));
+ if (local_got_refcounts == NULL)
+ return FALSE;
+ elf_local_got_refcounts (abfd) = local_got_refcounts;
+ elf64_x86_64_local_got_tls_type (abfd)
+ = (char *) (local_got_refcounts + symtab_hdr->sh_info);
+ }
+ local_got_refcounts[r_symndx] += 1;
+ old_tls_type
+ = elf64_x86_64_local_got_tls_type (abfd) [r_symndx];
+ }
+
+ /* If a TLS symbol is accessed using IE at least once,
+ there is no point to use dynamic model for it. */
+ if (old_tls_type != tls_type && old_tls_type != GOT_UNKNOWN
+ && (old_tls_type != GOT_TLS_GD || tls_type != GOT_TLS_IE))
+ {
+ if (old_tls_type == GOT_TLS_IE && tls_type == GOT_TLS_GD)
+ tls_type = old_tls_type;
+ else
+ {
+ (*_bfd_error_handler)
+ (_("%s: %s' accessed both as normal and thread local symbol"),
+ bfd_archive_filename (abfd),
+ h ? h->root.root.string : "<local>");
+ return FALSE;
+ }
+ }
+
+ if (old_tls_type != tls_type)
+ {
+ if (h != NULL)
+ elf64_x86_64_hash_entry (h)->tls_type = tls_type;
+ else
+ elf64_x86_64_local_got_tls_type (abfd) [r_symndx] = tls_type;
+ }
+ }
/* Fall through */
//case R_X86_64_GOTPCREL:
+ create_got:
if (htab->sgot == NULL)
{
if (htab->elf.dynobj == NULL)
htab->elf.dynobj = abfd;
if (!create_got_section (htab->elf.dynobj, info))
- return false;
+ return FALSE;
}
break;
@@ -674,9 +789,9 @@ elf64_x86_64_check_relocs (abfd, info, sec, relocs)
(*_bfd_error_handler)
(_("%s: relocation %s can not be used when making a shared object; recompile with -fPIC"),
bfd_archive_filename (abfd),
- x86_64_elf_howto_table[ELF64_R_TYPE (rel->r_info)].name);
+ x86_64_elf_howto_table[r_type].name);
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
/* Fall through. */
@@ -722,15 +837,16 @@ elf64_x86_64_check_relocs (abfd, info, sec, relocs)
symbol. */
if ((info->shared
&& (sec->flags & SEC_ALLOC) != 0
- && (((ELF64_R_TYPE (rel->r_info) != R_X86_64_PC8)
- && (ELF64_R_TYPE (rel->r_info) != R_X86_64_PC16)
- && (ELF64_R_TYPE (rel->r_info) != R_X86_64_PC32))
+ && (((r_type != R_X86_64_PC8)
+ && (r_type != R_X86_64_PC16)
+ && (r_type != R_X86_64_PC32))
|| (h != NULL
&& (! info->symbolic
|| h->root.type == bfd_link_hash_defweak
|| (h->elf_link_hash_flags
& ELF_LINK_HASH_DEF_REGULAR) == 0))))
- || (!info->shared
+ || (ELIMINATE_COPY_RELOCS
+ && !info->shared
&& (sec->flags & SEC_ALLOC) != 0
&& h != NULL
&& (h->root.type == bfd_link_hash_defweak
@@ -753,7 +869,7 @@ elf64_x86_64_check_relocs (abfd, info, sec, relocs)
elf_elfheader (abfd)->e_shstrndx,
elf_section_data (sec)->rel_hdr.sh_name));
if (name == NULL)
- return false;
+ return FALSE;
if (strncmp (name, ".rela", 5) != 0
|| strcmp (bfd_get_section_name (abfd, sec),
@@ -782,7 +898,7 @@ elf64_x86_64_check_relocs (abfd, info, sec, relocs)
if (sreloc == NULL
|| ! bfd_set_section_flags (dynobj, sreloc, flags)
|| ! bfd_set_section_alignment (dynobj, sreloc, 3))
- return false;
+ return FALSE;
}
elf_section_data (sec)->sreloc = sreloc;
}
@@ -803,7 +919,7 @@ elf64_x86_64_check_relocs (abfd, info, sec, relocs)
s = bfd_section_from_r_symndx (abfd, &htab->sym_sec,
sec, r_symndx);
if (s == NULL)
- return false;
+ return FALSE;
head = ((struct elf64_x86_64_dyn_relocs **)
&elf_section_data (s)->local_dynrel);
@@ -816,7 +932,7 @@ elf64_x86_64_check_relocs (abfd, info, sec, relocs)
p = ((struct elf64_x86_64_dyn_relocs *)
bfd_alloc (htab->elf.dynobj, amt));
if (p == NULL)
- return false;
+ return FALSE;
p->next = *head;
*head = p;
p->sec = sec;
@@ -825,9 +941,9 @@ elf64_x86_64_check_relocs (abfd, info, sec, relocs)
}
p->count += 1;
- if (ELF64_R_TYPE (rel->r_info) == R_X86_64_PC8
- || ELF64_R_TYPE (rel->r_info) == R_X86_64_PC16
- || ELF64_R_TYPE (rel->r_info) == R_X86_64_PC32)
+ if (r_type == R_X86_64_PC8
+ || r_type == R_X86_64_PC16
+ || r_type == R_X86_64_PC32)
p->pc_count += 1;
}
break;
@@ -835,15 +951,15 @@ elf64_x86_64_check_relocs (abfd, info, sec, relocs)
/* This relocation describes the C++ object vtable hierarchy.
Reconstruct it for later use during GC. */
case R_X86_64_GNU_VTINHERIT:
- if (!_bfd_elf64_gc_record_vtinherit (abfd, sec, h, rel->r_offset))
- return false;
+ if (!bfd_elf_gc_record_vtinherit (abfd, sec, h, rel->r_offset))
+ return FALSE;
break;
/* This relocation describes which C++ vtable entries are actually
used. Record for later use during GC. */
case R_X86_64_GNU_VTENTRY:
- if (!_bfd_elf64_gc_record_vtentry (abfd, sec, h, rel->r_addend))
- return false;
+ if (!bfd_elf_gc_record_vtentry (abfd, sec, h, rel->r_addend))
+ return FALSE;
break;
default:
@@ -851,19 +967,18 @@ elf64_x86_64_check_relocs (abfd, info, sec, relocs)
}
}
- return true;
+ return TRUE;
}
/* Return the section that should be marked against GC for a given
relocation. */
static asection *
-elf64_x86_64_gc_mark_hook (sec, info, rel, h, sym)
- asection *sec;
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
- Elf_Internal_Rela *rel;
- struct elf_link_hash_entry *h;
- Elf_Internal_Sym *sym;
+elf64_x86_64_gc_mark_hook (asection *sec,
+ struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ Elf_Internal_Rela *rel,
+ struct elf_link_hash_entry *h,
+ Elf_Internal_Sym *sym)
{
if (h != NULL)
{
@@ -896,19 +1011,14 @@ elf64_x86_64_gc_mark_hook (sec, info, rel, h, sym)
/* Update the got entry reference counts for the section being removed. */
-static boolean
-elf64_x86_64_gc_sweep_hook (abfd, info, sec, relocs)
- bfd *abfd;
- struct bfd_link_info *info;
- asection *sec;
- const Elf_Internal_Rela *relocs;
+static bfd_boolean
+elf64_x86_64_gc_sweep_hook (bfd *abfd, struct bfd_link_info *info,
+ asection *sec, const Elf_Internal_Rela *relocs)
{
Elf_Internal_Shdr *symtab_hdr;
struct elf_link_hash_entry **sym_hashes;
bfd_signed_vma *local_got_refcounts;
const Elf_Internal_Rela *rel, *relend;
- unsigned long r_symndx;
- struct elf_link_hash_entry *h;
elf_section_data (sec)->local_dynrel = NULL;
@@ -918,77 +1028,81 @@ elf64_x86_64_gc_sweep_hook (abfd, info, sec, relocs)
relend = relocs + sec->reloc_count;
for (rel = relocs; rel < relend; rel++)
- switch (ELF64_R_TYPE (rel->r_info))
- {
- case R_X86_64_GOT32:
- case R_X86_64_GOTPCREL:
- r_symndx = ELF64_R_SYM (rel->r_info);
- if (r_symndx >= symtab_hdr->sh_info)
- {
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- if (h->got.refcount > 0)
- h->got.refcount -= 1;
- }
- else if (local_got_refcounts != NULL)
- {
- if (local_got_refcounts[r_symndx] > 0)
- local_got_refcounts[r_symndx] -= 1;
- }
- break;
+ {
+ unsigned long r_symndx;
+ unsigned int r_type;
+ struct elf_link_hash_entry *h = NULL;
- case R_X86_64_8:
- case R_X86_64_16:
- case R_X86_64_32:
- case R_X86_64_64:
- case R_X86_64_32S:
- case R_X86_64_PC8:
- case R_X86_64_PC16:
- case R_X86_64_PC32:
- r_symndx = ELF64_R_SYM (rel->r_info);
- if (r_symndx >= symtab_hdr->sh_info)
- {
- struct elf64_x86_64_link_hash_entry *eh;
- struct elf64_x86_64_dyn_relocs **pp;
- struct elf64_x86_64_dyn_relocs *p;
+ r_symndx = ELF64_R_SYM (rel->r_info);
+ if (r_symndx >= symtab_hdr->sh_info)
+ {
+ struct elf64_x86_64_link_hash_entry *eh;
+ struct elf64_x86_64_dyn_relocs **pp;
+ struct elf64_x86_64_dyn_relocs *p;
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
+ h = sym_hashes[r_symndx - symtab_hdr->sh_info];
+ eh = (struct elf64_x86_64_link_hash_entry *) h;
- if (!info->shared && h->plt.refcount > 0)
- h->plt.refcount -= 1;
+ for (pp = &eh->dyn_relocs; (p = *pp) != NULL; pp = &p->next)
+ if (p->sec == sec)
+ {
+ /* Everything must go for SEC. */
+ *pp = p->next;
+ break;
+ }
+ }
- eh = (struct elf64_x86_64_link_hash_entry *) h;
+ r_type = ELF64_R_TYPE (rel->r_info);
+ r_type = elf64_x86_64_tls_transition (info, r_type, h != NULL);
+ switch (r_type)
+ {
+ case R_X86_64_TLSLD:
+ if (elf64_x86_64_hash_table (info)->tls_ld_got.refcount > 0)
+ elf64_x86_64_hash_table (info)->tls_ld_got.refcount -= 1;
+ break;
- for (pp = &eh->dyn_relocs; (p = *pp) != NULL; pp = &p->next)
- if (p->sec == sec)
- {
- if (ELF64_R_TYPE (rel->r_info) == R_X86_64_PC8
- || ELF64_R_TYPE (rel->r_info) == R_X86_64_PC16
- || ELF64_R_TYPE (rel->r_info) == R_X86_64_PC32)
- p->pc_count -= 1;
- p->count -= 1;
- if (p->count == 0)
- *pp = p->next;
- break;
- }
- }
- break;
+ case R_X86_64_TLSGD:
+ case R_X86_64_GOTTPOFF:
+ case R_X86_64_GOT32:
+ case R_X86_64_GOTPCREL:
+ if (h != NULL)
+ {
+ if (h->got.refcount > 0)
+ h->got.refcount -= 1;
+ }
+ else if (local_got_refcounts != NULL)
+ {
+ if (local_got_refcounts[r_symndx] > 0)
+ local_got_refcounts[r_symndx] -= 1;
+ }
+ break;
+ case R_X86_64_8:
+ case R_X86_64_16:
+ case R_X86_64_32:
+ case R_X86_64_64:
+ case R_X86_64_32S:
+ case R_X86_64_PC8:
+ case R_X86_64_PC16:
+ case R_X86_64_PC32:
+ if (info->shared)
+ break;
+ /* Fall thru */
- case R_X86_64_PLT32:
- r_symndx = ELF64_R_SYM (rel->r_info);
- if (r_symndx >= symtab_hdr->sh_info)
- {
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- if (h->plt.refcount > 0)
- h->plt.refcount -= 1;
- }
- break;
+ case R_X86_64_PLT32:
+ if (h != NULL)
+ {
+ if (h->plt.refcount > 0)
+ h->plt.refcount -= 1;
+ }
+ break;
- default:
- break;
- }
+ default:
+ break;
+ }
+ }
- return true;
+ return TRUE;
}
/* Adjust a symbol defined by a dynamic object and referenced by a
@@ -997,14 +1111,11 @@ elf64_x86_64_gc_sweep_hook (abfd, info, sec, relocs)
change the definition to something the rest of the link can
understand. */
-static boolean
-elf64_x86_64_adjust_dynamic_symbol (info, h)
- struct bfd_link_info *info;
- struct elf_link_hash_entry *h;
+static bfd_boolean
+elf64_x86_64_adjust_dynamic_symbol (struct bfd_link_info *info,
+ struct elf_link_hash_entry *h)
{
struct elf64_x86_64_link_hash_table *htab;
- struct elf64_x86_64_link_hash_entry * eh;
- struct elf64_x86_64_dyn_relocs *p;
asection *s;
unsigned int power_of_two;
@@ -1015,11 +1126,9 @@ elf64_x86_64_adjust_dynamic_symbol (info, h)
|| (h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_PLT) != 0)
{
if (h->plt.refcount <= 0
- || (! info->shared
- && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) == 0
- && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) == 0
- && h->root.type != bfd_link_hash_undefweak
- && h->root.type != bfd_link_hash_undefined))
+ || SYMBOL_CALLS_LOCAL (info, h)
+ || (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+ && h->root.type == bfd_link_hash_undefweak))
{
/* This case can occur if we saw a PLT32 reloc in an input
file, but the symbol was never referred to by a dynamic
@@ -1030,7 +1139,7 @@ elf64_x86_64_adjust_dynamic_symbol (info, h)
h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
}
- return true;
+ return TRUE;
}
else
/* It's possible that we incorrectly decided a .plt reloc was
@@ -1049,7 +1158,11 @@ elf64_x86_64_adjust_dynamic_symbol (info, h)
|| h->weakdef->root.type == bfd_link_hash_defweak);
h->root.u.def.section = h->weakdef->root.u.def.section;
h->root.u.def.value = h->weakdef->root.u.def.value;
- return true;
+ if (ELIMINATE_COPY_RELOCS || info->nocopyreloc)
+ h->elf_link_hash_flags
+ = ((h->elf_link_hash_flags & ~ELF_LINK_NON_GOT_REF)
+ | (h->weakdef->elf_link_hash_flags & ELF_LINK_NON_GOT_REF));
+ return TRUE;
}
/* This is a reference to a symbol defined by a dynamic object which
@@ -1060,34 +1173,40 @@ elf64_x86_64_adjust_dynamic_symbol (info, h)
For such cases we need not do anything here; the relocations will
be handled correctly by relocate_section. */
if (info->shared)
- return true;
+ return TRUE;
/* If there are no references to this symbol that do not use the
GOT, we don't need to generate a copy reloc. */
if ((h->elf_link_hash_flags & ELF_LINK_NON_GOT_REF) == 0)
- return true;
+ return TRUE;
/* If -z nocopyreloc was given, we won't generate them either. */
if (info->nocopyreloc)
{
h->elf_link_hash_flags &= ~ELF_LINK_NON_GOT_REF;
- return true;
+ return TRUE;
}
- eh = (struct elf64_x86_64_link_hash_entry *) h;
- for (p = eh->dyn_relocs; p != NULL; p = p->next)
+ if (ELIMINATE_COPY_RELOCS)
{
- s = p->sec->output_section;
- if (s != NULL && (s->flags & SEC_READONLY) != 0)
- break;
- }
+ struct elf64_x86_64_link_hash_entry * eh;
+ struct elf64_x86_64_dyn_relocs *p;
- /* If we didn't find any dynamic relocs in read-only sections, then
- we'll be keeping the dynamic relocs and avoiding the copy reloc. */
- if (p == NULL)
- {
- h->elf_link_hash_flags &= ~ELF_LINK_NON_GOT_REF;
- return true;
+ eh = (struct elf64_x86_64_link_hash_entry *) h;
+ for (p = eh->dyn_relocs; p != NULL; p = p->next)
+ {
+ s = p->sec->output_section;
+ if (s != NULL && (s->flags & SEC_READONLY) != 0)
+ break;
+ }
+
+ /* If we didn't find any dynamic relocs in read-only sections, then
+ we'll be keeping the dynamic relocs and avoiding the copy reloc. */
+ if (p == NULL)
+ {
+ h->elf_link_hash_flags &= ~ELF_LINK_NON_GOT_REF;
+ return TRUE;
+ }
}
/* We must allocate the symbol in our .dynbss section, which will
@@ -1126,7 +1245,7 @@ elf64_x86_64_adjust_dynamic_symbol (info, h)
if (power_of_two > bfd_get_section_alignment (htab->elf.dynobj, s))
{
if (! bfd_set_section_alignment (htab->elf.dynobj, s, power_of_two))
- return false;
+ return FALSE;
}
/* Define the symbol as being at this point in the section. */
@@ -1136,27 +1255,14 @@ elf64_x86_64_adjust_dynamic_symbol (info, h)
/* Increment the section size to make room for the symbol. */
s->_raw_size += h->size;
- return true;
+ return TRUE;
}
-/* This is the condition under which elf64_x86_64_finish_dynamic_symbol
- will be called from elflink.h. If elflink.h doesn't call our
- finish_dynamic_symbol routine, we'll need to do something about
- initializing any .plt and .got entries in elf64_x86_64_relocate_section. */
-#define WILL_CALL_FINISH_DYNAMIC_SYMBOL(DYN, INFO, H) \
- ((DYN) \
- && ((INFO)->shared \
- || ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0) \
- && ((H)->dynindx != -1 \
- || ((H)->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0))
-
/* Allocate space in .plt, .got and associated reloc sections for
dynamic relocs. */
-static boolean
-allocate_dynrelocs (h, inf)
- struct elf_link_hash_entry *h;
- PTR inf;
+static bfd_boolean
+allocate_dynrelocs (struct elf_link_hash_entry *h, void * inf)
{
struct bfd_link_info *info;
struct elf64_x86_64_link_hash_table *htab;
@@ -1164,7 +1270,7 @@ allocate_dynrelocs (h, inf)
struct elf64_x86_64_dyn_relocs *p;
if (h->root.type == bfd_link_hash_indirect)
- return true;
+ return TRUE;
if (h->root.type == bfd_link_hash_warning)
h = (struct elf_link_hash_entry *) h->root.u.i.link;
@@ -1180,11 +1286,12 @@ allocate_dynrelocs (h, inf)
if (h->dynindx == -1
&& (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
{
- if (! bfd_elf64_link_record_dynamic_symbol (info, h))
- return false;
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
}
- if (WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, info, h))
+ if (info->shared
+ || WILL_CALL_FINISH_DYNAMIC_SYMBOL (1, 0, h))
{
asection *s = htab->splt;
@@ -1229,25 +1336,47 @@ allocate_dynrelocs (h, inf)
h->elf_link_hash_flags &= ~ELF_LINK_HASH_NEEDS_PLT;
}
- if (h->got.refcount > 0)
+ /* If R_X86_64_GOTTPOFF symbol is now local to the binary,
+ make it a R_X86_64_TPOFF32 requiring no GOT entry. */
+ if (h->got.refcount > 0
+ && !info->shared
+ && h->dynindx == -1
+ && elf64_x86_64_hash_entry (h)->tls_type == GOT_TLS_IE)
+ h->got.offset = (bfd_vma) -1;
+ else if (h->got.refcount > 0)
{
asection *s;
- boolean dyn;
+ bfd_boolean dyn;
+ int tls_type = elf64_x86_64_hash_entry (h)->tls_type;
/* Make sure this symbol is output as a dynamic symbol.
Undefined weak syms won't yet be marked as dynamic. */
if (h->dynindx == -1
&& (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
{
- if (! bfd_elf64_link_record_dynamic_symbol (info, h))
- return false;
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
}
s = htab->sgot;
h->got.offset = s->_raw_size;
s->_raw_size += GOT_ENTRY_SIZE;
+ /* R_X86_64_TLSGD needs 2 consecutive GOT slots. */
+ if (tls_type == GOT_TLS_GD)
+ s->_raw_size += GOT_ENTRY_SIZE;
dyn = htab->elf.dynamic_sections_created;
- if (WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info, h))
+ /* R_X86_64_TLSGD needs one dynamic relocation if local symbol
+ and two if global.
+ R_X86_64_GOTTPOFF needs one dynamic relocation. */
+ if ((tls_type == GOT_TLS_GD && h->dynindx == -1)
+ || tls_type == GOT_TLS_IE)
+ htab->srelgot->_raw_size += sizeof (Elf64_External_Rela);
+ else if (tls_type == GOT_TLS_GD)
+ htab->srelgot->_raw_size += 2 * sizeof (Elf64_External_Rela);
+ else if ((ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak)
+ && (info->shared
+ || WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, 0, h)))
htab->srelgot->_raw_size += sizeof (Elf64_External_Rela);
}
else
@@ -1255,7 +1384,7 @@ allocate_dynrelocs (h, inf)
eh = (struct elf64_x86_64_link_hash_entry *) h;
if (eh->dyn_relocs == NULL)
- return true;
+ return TRUE;
/* In the shared -Bsymbolic case, discard space allocated for
dynamic pc-relative relocs against symbols which turn out to be
@@ -1265,9 +1394,13 @@ allocate_dynrelocs (h, inf)
if (info->shared)
{
- if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0
- && ((h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0
- || info->symbolic))
+ /* Relocs that use pc_count are those that appear on a call
+ insn, or certain REL relocs that can generated via assembly.
+ We want calls to protected symbols to resolve directly to the
+ function rather than going via the plt. If people want
+ function pointer comparisons to work as expected then they
+ should avoid writing weird assembly. */
+ if (SYMBOL_CALLS_LOCAL (info, h))
{
struct elf64_x86_64_dyn_relocs **pp;
@@ -1281,8 +1414,14 @@ allocate_dynrelocs (h, inf)
pp = &p->next;
}
}
+
+ /* Also discard relocs on undefined weak syms with non-default
+ visibility. */
+ if (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+ && h->root.type == bfd_link_hash_undefweak)
+ eh->dyn_relocs = NULL;
}
- else
+ else if (ELIMINATE_COPY_RELOCS)
{
/* For the non-shared case, discard space for relocs against
symbols which turn out to need copy relocs or are not
@@ -1300,8 +1439,8 @@ allocate_dynrelocs (h, inf)
if (h->dynindx == -1
&& (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
{
- if (! bfd_elf64_link_record_dynamic_symbol (info, h))
- return false;
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
}
/* If that succeeded, we know we'll be keeping all the
@@ -1322,15 +1461,13 @@ allocate_dynrelocs (h, inf)
sreloc->_raw_size += p->count * sizeof (Elf64_External_Rela);
}
- return true;
+ return TRUE;
}
/* Find any dynamic relocs that apply to read-only sections. */
-static boolean
-readonly_dynrelocs (h, inf)
- struct elf_link_hash_entry *h;
- PTR inf;
+static bfd_boolean
+readonly_dynrelocs (struct elf_link_hash_entry *h, void * inf)
{
struct elf64_x86_64_link_hash_entry *eh;
struct elf64_x86_64_dyn_relocs *p;
@@ -1350,23 +1487,22 @@ readonly_dynrelocs (h, inf)
info->flags |= DF_TEXTREL;
/* Not an error, just cut short the traversal. */
- return false;
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
/* Set the sizes of the dynamic sections. */
-static boolean
-elf64_x86_64_size_dynamic_sections (output_bfd, info)
- bfd *output_bfd ATTRIBUTE_UNUSED;
- struct bfd_link_info *info;
+static bfd_boolean
+elf64_x86_64_size_dynamic_sections (bfd *output_bfd ATTRIBUTE_UNUSED,
+ struct bfd_link_info *info)
{
struct elf64_x86_64_link_hash_table *htab;
bfd *dynobj;
asection *s;
- boolean relocs;
+ bfd_boolean relocs;
bfd *ibfd;
htab = elf64_x86_64_hash_table (info);
@@ -1377,7 +1513,7 @@ elf64_x86_64_size_dynamic_sections (output_bfd, info)
if (htab->elf.dynamic_sections_created)
{
/* Set the contents of the .interp section to the interpreter. */
- if (! info->shared)
+ if (info->executable)
{
s = bfd_get_section_by_name (dynobj, ".interp");
if (s == NULL)
@@ -1393,6 +1529,7 @@ elf64_x86_64_size_dynamic_sections (output_bfd, info)
{
bfd_signed_vma *local_got;
bfd_signed_vma *end_local_got;
+ char *local_tls_type;
bfd_size_type locsymcount;
Elf_Internal_Shdr *symtab_hdr;
asection *srel;
@@ -1435,15 +1572,20 @@ elf64_x86_64_size_dynamic_sections (output_bfd, info)
symtab_hdr = &elf_tdata (ibfd)->symtab_hdr;
locsymcount = symtab_hdr->sh_info;
end_local_got = local_got + locsymcount;
+ local_tls_type = elf64_x86_64_local_got_tls_type (ibfd);
s = htab->sgot;
srel = htab->srelgot;
- for (; local_got < end_local_got; ++local_got)
+ for (; local_got < end_local_got; ++local_got, ++local_tls_type)
{
if (*local_got > 0)
{
*local_got = s->_raw_size;
s->_raw_size += GOT_ENTRY_SIZE;
- if (info->shared)
+ if (*local_tls_type == GOT_TLS_GD)
+ s->_raw_size += GOT_ENTRY_SIZE;
+ if (info->shared
+ || *local_tls_type == GOT_TLS_GD
+ || *local_tls_type == GOT_TLS_IE)
srel->_raw_size += sizeof (Elf64_External_Rela);
}
else
@@ -1451,13 +1593,24 @@ elf64_x86_64_size_dynamic_sections (output_bfd, info)
}
}
+ if (htab->tls_ld_got.refcount > 0)
+ {
+ /* Allocate 2 got entries and 1 dynamic reloc for R_X86_64_TLSLD
+ relocs. */
+ htab->tls_ld_got.offset = htab->sgot->_raw_size;
+ htab->sgot->_raw_size += 2 * GOT_ENTRY_SIZE;
+ htab->srelgot->_raw_size += sizeof (Elf64_External_Rela);
+ }
+ else
+ htab->tls_ld_got.offset = -1;
+
/* Allocate global sym .plt and .got entries, and space for global
sym dynamic relocs. */
elf_link_hash_traverse (&htab->elf, allocate_dynrelocs, (PTR) info);
/* We now have determined the sizes of the various dynamic sections.
Allocate memory for them. */
- relocs = false;
+ relocs = FALSE;
for (s = dynobj->sections; s != NULL; s = s->next)
{
if ((s->flags & SEC_LINKER_CREATED) == 0)
@@ -1473,7 +1626,7 @@ elf64_x86_64_size_dynamic_sections (output_bfd, info)
else if (strncmp (bfd_get_section_name (dynobj, s), ".rela", 5) == 0)
{
if (s->_raw_size != 0 && s != htab->srelplt)
- relocs = true;
+ relocs = TRUE;
/* We use the reloc_count field as a counter if we need
to copy relocs into the output file. */
@@ -1508,7 +1661,7 @@ elf64_x86_64_size_dynamic_sections (output_bfd, info)
of garbage. */
s->contents = (bfd_byte *) bfd_zalloc (dynobj, s->_raw_size);
if (s->contents == NULL)
- return false;
+ return FALSE;
}
if (htab->elf.dynamic_sections_created)
@@ -1519,12 +1672,12 @@ elf64_x86_64_size_dynamic_sections (output_bfd, info)
the .dynamic section. The DT_DEBUG entry is filled in by the
dynamic linker and used by the debugger. */
#define add_dynamic_entry(TAG, VAL) \
- bfd_elf64_add_dynamic_entry (info, (bfd_vma) (TAG), (bfd_vma) (VAL))
+ _bfd_elf_add_dynamic_entry (info, TAG, VAL)
- if (! info->shared)
+ if (info->executable)
{
if (!add_dynamic_entry (DT_DEBUG, 0))
- return false;
+ return FALSE;
}
if (htab->splt->_raw_size != 0)
@@ -1533,7 +1686,7 @@ elf64_x86_64_size_dynamic_sections (output_bfd, info)
|| !add_dynamic_entry (DT_PLTRELSZ, 0)
|| !add_dynamic_entry (DT_PLTREL, DT_RELA)
|| !add_dynamic_entry (DT_JMPREL, 0))
- return false;
+ return FALSE;
}
if (relocs)
@@ -1541,7 +1694,7 @@ elf64_x86_64_size_dynamic_sections (output_bfd, info)
if (!add_dynamic_entry (DT_RELA, 0)
|| !add_dynamic_entry (DT_RELASZ, 0)
|| !add_dynamic_entry (DT_RELAENT, sizeof (Elf64_External_Rela)))
- return false;
+ return FALSE;
/* If any dynamic relocs apply to a read-only section,
then we need a DT_TEXTREL entry. */
@@ -1552,28 +1705,50 @@ elf64_x86_64_size_dynamic_sections (output_bfd, info)
if ((info->flags & DF_TEXTREL) != 0)
{
if (!add_dynamic_entry (DT_TEXTREL, 0))
- return false;
+ return FALSE;
}
}
}
#undef add_dynamic_entry
- return true;
+ return TRUE;
+}
+
+/* Return the base VMA address which should be subtracted from real addresses
+ when resolving @dtpoff relocation.
+ This is PT_TLS segment p_vaddr. */
+
+static bfd_vma
+dtpoff_base (struct bfd_link_info *info)
+{
+ /* If tls_sec is NULL, we should have signalled an error already. */
+ if (elf_hash_table (info)->tls_sec == NULL)
+ return 0;
+ return elf_hash_table (info)->tls_sec->vma;
+}
+
+/* Return the relocation value for @tpoff relocation
+ if STT_TLS virtual address is ADDRESS. */
+
+static bfd_vma
+tpoff (struct bfd_link_info *info, bfd_vma address)
+{
+ struct elf_link_hash_table *htab = elf_hash_table (info);
+
+ /* If tls_segment is NULL, we should have signalled an error already. */
+ if (htab->tls_sec == NULL)
+ return 0;
+ return address - htab->tls_size - htab->tls_sec->vma;
}
/* Relocate an x86_64 ELF section. */
-static boolean
-elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
- contents, relocs, local_syms, local_sections)
- bfd *output_bfd;
- struct bfd_link_info *info;
- bfd *input_bfd;
- asection *input_section;
- bfd_byte *contents;
- Elf_Internal_Rela *relocs;
- Elf_Internal_Sym *local_syms;
- asection **local_sections;
+static bfd_boolean
+elf64_x86_64_relocate_section (bfd *output_bfd, struct bfd_link_info *info,
+ bfd *input_bfd, asection *input_section,
+ bfd_byte *contents, Elf_Internal_Rela *relocs,
+ Elf_Internal_Sym *local_syms,
+ asection **local_sections)
{
struct elf64_x86_64_link_hash_table *htab;
Elf_Internal_Shdr *symtab_hdr;
@@ -1582,8 +1757,8 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
Elf_Internal_Rela *rel;
Elf_Internal_Rela *relend;
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
htab = elf64_x86_64_hash_table (info);
symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
@@ -1594,7 +1769,7 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
relend = relocs + input_section->reloc_count;
for (; rel < relend; rel++)
{
- int r_type;
+ unsigned int r_type;
reloc_howto_type *howto;
unsigned long r_symndx;
struct elf_link_hash_entry *h;
@@ -1602,18 +1777,19 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
asection *sec;
bfd_vma off;
bfd_vma relocation;
- boolean unresolved_reloc;
+ bfd_boolean unresolved_reloc;
bfd_reloc_status_type r;
+ int tls_type;
r_type = ELF64_R_TYPE (rel->r_info);
if (r_type == (int) R_X86_64_GNU_VTINHERIT
|| r_type == (int) R_X86_64_GNU_VTENTRY)
continue;
- if (r_type < 0 || r_type >= R_X86_64_max)
+ if (r_type >= R_X86_64_max)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
howto = x86_64_elf_howto_table + r_type;
@@ -1621,56 +1797,22 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
h = NULL;
sym = NULL;
sec = NULL;
- unresolved_reloc = false;
+ unresolved_reloc = FALSE;
if (r_symndx < symtab_hdr->sh_info)
{
sym = local_syms + r_symndx;
sec = local_sections[r_symndx];
- relocation = _bfd_elf_rela_local_sym (output_bfd, sym, sec, rel);
+ relocation = _bfd_elf_rela_local_sym (output_bfd, sym, &sec, rel);
}
else
{
- h = sym_hashes[r_symndx - symtab_hdr->sh_info];
- while (h->root.type == bfd_link_hash_indirect
- || h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
+ bfd_boolean warned;
- if (h->root.type == bfd_link_hash_defined
- || h->root.type == bfd_link_hash_defweak)
- {
- sec = h->root.u.def.section;
- if (sec->output_section == NULL)
- {
- /* Set a flag that will be cleared later if we find a
- relocation value for this symbol. output_section
- is typically NULL for symbols satisfied by a shared
- library. */
- unresolved_reloc = true;
- relocation = 0;
- }
- else
- relocation = (h->root.u.def.value
- + sec->output_section->vma
- + sec->output_offset);
- }
- else if (h->root.type == bfd_link_hash_undefweak)
- relocation = 0;
- else if (info->shared
- && (!info->symbolic || info->allow_shlib_undefined)
- && !info->no_undefined
- && ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
- relocation = 0;
- else
- {
- if (! ((*info->callbacks->undefined_symbol)
- (info, h->root.root.string, input_bfd,
- input_section, rel->r_offset,
- (!info->shared || info->no_undefined
- || ELF_ST_VISIBILITY (h->other)))))
- return false;
- relocation = 0;
- }
+ RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
+ r_symndx, symtab_hdr, sym_hashes,
+ h, sec, relocation,
+ unresolved_reloc, warned);
}
/* When generating a shared object, the relocations handled here are
copied into the output file to be resolved at run time. */
@@ -1686,17 +1828,16 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
if (h != NULL)
{
- boolean dyn;
+ bfd_boolean dyn;
off = h->got.offset;
dyn = htab->elf.dynamic_sections_created;
- if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info, h)
+ if (! WILL_CALL_FINISH_DYNAMIC_SYMBOL (dyn, info->shared, h)
|| (info->shared
- && (info->symbolic
- || h->dynindx == -1
- || (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL))
- && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR)))
+ && SYMBOL_REFERENCES_LOCAL (info, h))
+ || (ELF_ST_VISIBILITY (h->other)
+ && h->root.type == bfd_link_hash_undefweak))
{
/* This is actually a static link, or it is a -Bsymbolic
link and the symbol is defined locally, or the symbol
@@ -1719,7 +1860,7 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
}
}
else
- unresolved_reloc = false;
+ unresolved_reloc = FALSE;
}
else
{
@@ -1740,14 +1881,14 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
if (info->shared)
{
- asection *srelgot;
+ asection *s;
Elf_Internal_Rela outrel;
- Elf64_External_Rela *loc;
+ bfd_byte *loc;
/* We need to generate a R_X86_64_RELATIVE reloc
for the dynamic linker. */
- srelgot = htab->srelgot;
- if (srelgot == NULL)
+ s = htab->srelgot;
+ if (s == NULL)
abort ();
outrel.r_offset = (htab->sgot->output_section->vma
@@ -1755,8 +1896,8 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
+ off);
outrel.r_info = ELF64_R_INFO (0, R_X86_64_RELATIVE);
outrel.r_addend = relocation;
- loc = (Elf64_External_Rela *) srelgot->contents;
- loc += srelgot->reloc_count++;
+ loc = s->contents;
+ loc += s->reloc_count++ * sizeof (Elf64_External_Rela);
bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
}
@@ -1794,7 +1935,7 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
relocation = (htab->splt->output_section->vma
+ htab->splt->output_offset
+ h->plt.offset);
- unresolved_reloc = false;
+ unresolved_reloc = FALSE;
break;
case R_X86_64_PC8:
@@ -1815,15 +1956,15 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
break;
if ((info->shared
+ && (h == NULL
+ || ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak)
&& ((r_type != R_X86_64_PC8
&& r_type != R_X86_64_PC16
&& r_type != R_X86_64_PC32)
- || (h != NULL
- && h->dynindx != -1
- && (! info->symbolic
- || (h->elf_link_hash_flags
- & ELF_LINK_HASH_DEF_REGULAR) == 0))))
- || (!info->shared
+ || !SYMBOL_CALLS_LOCAL (info, h)))
+ || (ELIMINATE_COPY_RELOCS
+ && !info->shared
&& h != NULL
&& h->dynindx != -1
&& (h->elf_link_hash_flags & ELF_LINK_NON_GOT_REF) == 0
@@ -1835,24 +1976,23 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
|| h->root.type == bfd_link_hash_undefined)))
{
Elf_Internal_Rela outrel;
- boolean skip, relocate;
+ bfd_byte *loc;
+ bfd_boolean skip, relocate;
asection *sreloc;
- Elf64_External_Rela *loc;
/* When generating a shared object, these relocations
are copied into the output file to be resolved at run
time. */
-
- skip = false;
- relocate = false;
+ skip = FALSE;
+ relocate = FALSE;
outrel.r_offset =
_bfd_elf_section_offset (output_bfd, info, input_section,
rel->r_offset);
if (outrel.r_offset == (bfd_vma) -1)
- skip = true;
+ skip = TRUE;
else if (outrel.r_offset == (bfd_vma) -2)
- skip = true, relocate = true;
+ skip = TRUE, relocate = TRUE;
outrel.r_offset += (input_section->output_section->vma
+ input_section->output_offset);
@@ -1880,7 +2020,7 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
/* This symbol is local, or marked to become local. */
if (r_type == R_X86_64_64)
{
- relocate = true;
+ relocate = TRUE;
outrel.r_info = ELF64_R_INFO (0, R_X86_64_RELATIVE);
outrel.r_addend = relocation + rel->r_addend;
}
@@ -1888,21 +2028,12 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
{
long sindx;
- if (h == NULL)
- sec = local_sections[r_symndx];
- else
- {
- BFD_ASSERT (h->root.type == bfd_link_hash_defined
- || (h->root.type
- == bfd_link_hash_defweak));
- sec = h->root.u.def.section;
- }
- if (sec != NULL && bfd_is_abs_section (sec))
+ if (bfd_is_abs_section (sec))
sindx = 0;
else if (sec == NULL || sec->owner == NULL)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
else
{
@@ -1922,8 +2053,8 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
if (sreloc == NULL)
abort ();
- loc = (Elf64_External_Rela *) sreloc->contents;
- loc += sreloc->reloc_count++;
+ loc = sreloc->contents;
+ loc += sreloc->reloc_count++ * sizeof (Elf64_External_Rela);
bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
/* If this reloc is against an external symbol, we do
@@ -1936,6 +2067,314 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
break;
+ case R_X86_64_TLSGD:
+ case R_X86_64_GOTTPOFF:
+ r_type = elf64_x86_64_tls_transition (info, r_type, h == NULL);
+ tls_type = GOT_UNKNOWN;
+ if (h == NULL && local_got_offsets)
+ tls_type = elf64_x86_64_local_got_tls_type (input_bfd) [r_symndx];
+ else if (h != NULL)
+ {
+ tls_type = elf64_x86_64_hash_entry (h)->tls_type;
+ if (!info->shared && h->dynindx == -1 && tls_type == GOT_TLS_IE)
+ r_type = R_X86_64_TPOFF32;
+ }
+ if (r_type == R_X86_64_TLSGD)
+ {
+ if (tls_type == GOT_TLS_IE)
+ r_type = R_X86_64_GOTTPOFF;
+ }
+
+ if (r_type == R_X86_64_TPOFF32)
+ {
+ BFD_ASSERT (! unresolved_reloc);
+ if (ELF64_R_TYPE (rel->r_info) == R_X86_64_TLSGD)
+ {
+ unsigned int i;
+ static unsigned char tlsgd[8]
+ = { 0x66, 0x48, 0x8d, 0x3d, 0x66, 0x66, 0x48, 0xe8 };
+
+ /* GD->LE transition.
+ .byte 0x66; leaq foo@tlsgd(%rip), %rdi
+ .word 0x6666; rex64; call __tls_get_addr@plt
+ Change it into:
+ movq %fs:0, %rax
+ leaq foo@tpoff(%rax), %rax */
+ BFD_ASSERT (rel->r_offset >= 4);
+ for (i = 0; i < 4; i++)
+ BFD_ASSERT (bfd_get_8 (input_bfd,
+ contents + rel->r_offset - 4 + i)
+ == tlsgd[i]);
+ BFD_ASSERT (rel->r_offset + 12 <= input_section->_raw_size);
+ for (i = 0; i < 4; i++)
+ BFD_ASSERT (bfd_get_8 (input_bfd,
+ contents + rel->r_offset + 4 + i)
+ == tlsgd[i+4]);
+ BFD_ASSERT (rel + 1 < relend);
+ BFD_ASSERT (ELF64_R_TYPE (rel[1].r_info) == R_X86_64_PLT32);
+ memcpy (contents + rel->r_offset - 4,
+ "\x64\x48\x8b\x04\x25\0\0\0\0\x48\x8d\x80\0\0\0",
+ 16);
+ bfd_put_32 (output_bfd, tpoff (info, relocation),
+ contents + rel->r_offset + 8);
+ /* Skip R_X86_64_PLT32. */
+ rel++;
+ continue;
+ }
+ else
+ {
+ unsigned int val, type, reg;
+
+ /* IE->LE transition:
+ Originally it can be one of:
+ movq foo@gottpoff(%rip), %reg
+ addq foo@gottpoff(%rip), %reg
+ We change it into:
+ movq $foo, %reg
+ leaq foo(%reg), %reg
+ addq $foo, %reg. */
+ BFD_ASSERT (rel->r_offset >= 3);
+ val = bfd_get_8 (input_bfd, contents + rel->r_offset - 3);
+ BFD_ASSERT (val == 0x48 || val == 0x4c);
+ type = bfd_get_8 (input_bfd, contents + rel->r_offset - 2);
+ BFD_ASSERT (type == 0x8b || type == 0x03);
+ reg = bfd_get_8 (input_bfd, contents + rel->r_offset - 1);
+ BFD_ASSERT ((reg & 0xc7) == 5);
+ reg >>= 3;
+ BFD_ASSERT (rel->r_offset + 4 <= input_section->_raw_size);
+ if (type == 0x8b)
+ {
+ /* movq */
+ if (val == 0x4c)
+ bfd_put_8 (output_bfd, 0x49,
+ contents + rel->r_offset - 3);
+ bfd_put_8 (output_bfd, 0xc7,
+ contents + rel->r_offset - 2);
+ bfd_put_8 (output_bfd, 0xc0 | reg,
+ contents + rel->r_offset - 1);
+ }
+ else if (reg == 4)
+ {
+ /* addq -> addq - addressing with %rsp/%r12 is
+ special */
+ if (val == 0x4c)
+ bfd_put_8 (output_bfd, 0x49,
+ contents + rel->r_offset - 3);
+ bfd_put_8 (output_bfd, 0x81,
+ contents + rel->r_offset - 2);
+ bfd_put_8 (output_bfd, 0xc0 | reg,
+ contents + rel->r_offset - 1);
+ }
+ else
+ {
+ /* addq -> leaq */
+ if (val == 0x4c)
+ bfd_put_8 (output_bfd, 0x4d,
+ contents + rel->r_offset - 3);
+ bfd_put_8 (output_bfd, 0x8d,
+ contents + rel->r_offset - 2);
+ bfd_put_8 (output_bfd, 0x80 | reg | (reg << 3),
+ contents + rel->r_offset - 1);
+ }
+ bfd_put_32 (output_bfd, tpoff (info, relocation),
+ contents + rel->r_offset);
+ continue;
+ }
+ }
+
+ if (htab->sgot == NULL)
+ abort ();
+
+ if (h != NULL)
+ off = h->got.offset;
+ else
+ {
+ if (local_got_offsets == NULL)
+ abort ();
+
+ off = local_got_offsets[r_symndx];
+ }
+
+ if ((off & 1) != 0)
+ off &= ~1;
+ else
+ {
+ Elf_Internal_Rela outrel;
+ bfd_byte *loc;
+ int dr_type, indx;
+
+ if (htab->srelgot == NULL)
+ abort ();
+
+ outrel.r_offset = (htab->sgot->output_section->vma
+ + htab->sgot->output_offset + off);
+
+ indx = h && h->dynindx != -1 ? h->dynindx : 0;
+ if (r_type == R_X86_64_TLSGD)
+ dr_type = R_X86_64_DTPMOD64;
+ else
+ dr_type = R_X86_64_TPOFF64;
+
+ bfd_put_64 (output_bfd, 0, htab->sgot->contents + off);
+ outrel.r_addend = 0;
+ if (dr_type == R_X86_64_TPOFF64 && indx == 0)
+ outrel.r_addend = relocation - dtpoff_base (info);
+ outrel.r_info = ELF64_R_INFO (indx, dr_type);
+
+ loc = htab->srelgot->contents;
+ loc += htab->srelgot->reloc_count++ * sizeof (Elf64_External_Rela);
+ bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
+
+ if (r_type == R_X86_64_TLSGD)
+ {
+ if (indx == 0)
+ {
+ BFD_ASSERT (! unresolved_reloc);
+ bfd_put_64 (output_bfd,
+ relocation - dtpoff_base (info),
+ htab->sgot->contents + off + GOT_ENTRY_SIZE);
+ }
+ else
+ {
+ bfd_put_64 (output_bfd, 0,
+ htab->sgot->contents + off + GOT_ENTRY_SIZE);
+ outrel.r_info = ELF64_R_INFO (indx,
+ R_X86_64_DTPOFF64);
+ outrel.r_offset += GOT_ENTRY_SIZE;
+ htab->srelgot->reloc_count++;
+ loc += sizeof (Elf64_External_Rela);
+ bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
+ }
+ }
+
+ if (h != NULL)
+ h->got.offset |= 1;
+ else
+ local_got_offsets[r_symndx] |= 1;
+ }
+
+ if (off >= (bfd_vma) -2)
+ abort ();
+ if (r_type == ELF64_R_TYPE (rel->r_info))
+ {
+ relocation = htab->sgot->output_section->vma
+ + htab->sgot->output_offset + off;
+ unresolved_reloc = FALSE;
+ }
+ else
+ {
+ unsigned int i;
+ static unsigned char tlsgd[8]
+ = { 0x66, 0x48, 0x8d, 0x3d, 0x66, 0x66, 0x48, 0xe8 };
+
+ /* GD->IE transition.
+ .byte 0x66; leaq foo@tlsgd(%rip), %rdi
+ .word 0x6666; rex64; call __tls_get_addr@plt
+ Change it into:
+ movq %fs:0, %rax
+ addq foo@gottpoff(%rip), %rax */
+ BFD_ASSERT (rel->r_offset >= 4);
+ for (i = 0; i < 4; i++)
+ BFD_ASSERT (bfd_get_8 (input_bfd,
+ contents + rel->r_offset - 4 + i)
+ == tlsgd[i]);
+ BFD_ASSERT (rel->r_offset + 12 <= input_section->_raw_size);
+ for (i = 0; i < 4; i++)
+ BFD_ASSERT (bfd_get_8 (input_bfd,
+ contents + rel->r_offset + 4 + i)
+ == tlsgd[i+4]);
+ BFD_ASSERT (rel + 1 < relend);
+ BFD_ASSERT (ELF64_R_TYPE (rel[1].r_info) == R_X86_64_PLT32);
+ memcpy (contents + rel->r_offset - 4,
+ "\x64\x48\x8b\x04\x25\0\0\0\0\x48\x03\x05\0\0\0",
+ 16);
+
+ relocation = (htab->sgot->output_section->vma
+ + htab->sgot->output_offset + off
+ - rel->r_offset
+ - input_section->output_section->vma
+ - input_section->output_offset
+ - 12);
+ bfd_put_32 (output_bfd, relocation,
+ contents + rel->r_offset + 8);
+ /* Skip R_X86_64_PLT32. */
+ rel++;
+ continue;
+ }
+ break;
+
+ case R_X86_64_TLSLD:
+ if (! info->shared)
+ {
+ /* LD->LE transition:
+ Ensure it is:
+ leaq foo@tlsld(%rip), %rdi; call __tls_get_addr@plt.
+ We change it into:
+ .word 0x6666; .byte 0x66; movl %fs:0, %rax. */
+ BFD_ASSERT (rel->r_offset >= 3);
+ BFD_ASSERT (bfd_get_8 (input_bfd, contents + rel->r_offset - 3)
+ == 0x48);
+ BFD_ASSERT (bfd_get_8 (input_bfd, contents + rel->r_offset - 2)
+ == 0x8d);
+ BFD_ASSERT (bfd_get_8 (input_bfd, contents + rel->r_offset - 1)
+ == 0x3d);
+ BFD_ASSERT (rel->r_offset + 9 <= input_section->_raw_size);
+ BFD_ASSERT (bfd_get_8 (input_bfd, contents + rel->r_offset + 4)
+ == 0xe8);
+ BFD_ASSERT (rel + 1 < relend);
+ BFD_ASSERT (ELF64_R_TYPE (rel[1].r_info) == R_X86_64_PLT32);
+ memcpy (contents + rel->r_offset - 3,
+ "\x66\x66\x66\x64\x48\x8b\x04\x25\0\0\0", 12);
+ /* Skip R_X86_64_PLT32. */
+ rel++;
+ continue;
+ }
+
+ if (htab->sgot == NULL)
+ abort ();
+
+ off = htab->tls_ld_got.offset;
+ if (off & 1)
+ off &= ~1;
+ else
+ {
+ Elf_Internal_Rela outrel;
+ bfd_byte *loc;
+
+ if (htab->srelgot == NULL)
+ abort ();
+
+ outrel.r_offset = (htab->sgot->output_section->vma
+ + htab->sgot->output_offset + off);
+
+ bfd_put_64 (output_bfd, 0,
+ htab->sgot->contents + off);
+ bfd_put_64 (output_bfd, 0,
+ htab->sgot->contents + off + GOT_ENTRY_SIZE);
+ outrel.r_info = ELF64_R_INFO (0, R_X86_64_DTPMOD64);
+ outrel.r_addend = 0;
+ loc = htab->srelgot->contents;
+ loc += htab->srelgot->reloc_count++ * sizeof (Elf64_External_Rela);
+ bfd_elf64_swap_reloca_out (output_bfd, &outrel, loc);
+ htab->tls_ld_got.offset |= 1;
+ }
+ relocation = htab->sgot->output_section->vma
+ + htab->sgot->output_offset + off;
+ unresolved_reloc = FALSE;
+ break;
+
+ case R_X86_64_DTPOFF32:
+ if (info->shared || (input_section->flags & SEC_CODE) == 0)
+ relocation -= dtpoff_base (info);
+ else
+ relocation = tpoff (info, relocation);
+ break;
+
+ case R_X86_64_TPOFF32:
+ BFD_ASSERT (! info->shared);
+ relocation = tpoff (info, relocation);
+ break;
+
default:
break;
}
@@ -1969,7 +2408,7 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
symtab_hdr->sh_link,
sym->st_name);
if (name == NULL)
- return false;
+ return FALSE;
if (*name == '\0')
name = bfd_section_name (input_bfd, sec);
}
@@ -1980,7 +2419,7 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
if (! ((*info->callbacks->reloc_overflow)
(info, name, howto->name, (bfd_vma) 0,
input_bfd, input_section, rel->r_offset)))
- return false;
+ return FALSE;
}
else
{
@@ -1989,23 +2428,22 @@ elf64_x86_64_relocate_section (output_bfd, info, input_bfd, input_section,
bfd_archive_filename (input_bfd),
bfd_get_section_name (input_bfd, input_section),
(long) rel->r_offset, name, (int) r);
- return false;
+ return FALSE;
}
}
}
- return true;
+ return TRUE;
}
/* Finish up dynamic symbol handling. We set the contents of various
dynamic sections here. */
-static boolean
-elf64_x86_64_finish_dynamic_symbol (output_bfd, info, h, sym)
- bfd *output_bfd;
- struct bfd_link_info *info;
- struct elf_link_hash_entry *h;
- Elf_Internal_Sym *sym;
+static bfd_boolean
+elf64_x86_64_finish_dynamic_symbol (bfd *output_bfd,
+ struct bfd_link_info *info,
+ struct elf_link_hash_entry *h,
+ Elf_Internal_Sym *sym)
{
struct elf64_x86_64_link_hash_table *htab;
@@ -2016,11 +2454,10 @@ elf64_x86_64_finish_dynamic_symbol (output_bfd, info, h, sym)
bfd_vma plt_index;
bfd_vma got_offset;
Elf_Internal_Rela rela;
- Elf64_External_Rela *loc;
+ bfd_byte *loc;
/* This symbol has an entry in the procedure linkage table. Set
it up. */
-
if (h->dynindx == -1
|| htab->splt == NULL
|| htab->sgotplt == NULL
@@ -2076,7 +2513,7 @@ elf64_x86_64_finish_dynamic_symbol (output_bfd, info, h, sym)
+ got_offset);
rela.r_info = ELF64_R_INFO (h->dynindx, R_X86_64_JUMP_SLOT);
rela.r_addend = 0;
- loc = (Elf64_External_Rela *) htab->srelplt->contents + plt_index;
+ loc = htab->srelplt->contents + plt_index * sizeof (Elf64_External_Rela);
bfd_elf64_swap_reloca_out (output_bfd, &rela, loc);
if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
@@ -2090,14 +2527,15 @@ elf64_x86_64_finish_dynamic_symbol (output_bfd, info, h, sym)
}
}
- if (h->got.offset != (bfd_vma) -1)
+ if (h->got.offset != (bfd_vma) -1
+ && elf64_x86_64_hash_entry (h)->tls_type != GOT_TLS_GD
+ && elf64_x86_64_hash_entry (h)->tls_type != GOT_TLS_IE)
{
Elf_Internal_Rela rela;
- Elf64_External_Rela *loc;
+ bfd_byte *loc;
/* This symbol has an entry in the global offset table. Set it
- up. */
-
+ up. */
if (htab->sgot == NULL || htab->srelgot == NULL)
abort ();
@@ -2111,10 +2549,7 @@ elf64_x86_64_finish_dynamic_symbol (output_bfd, info, h, sym)
The entry in the global offset table will already have been
initialized in the relocate_section function. */
if (info->shared
- && (info->symbolic
- || h->dynindx == -1
- || (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL))
- && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR))
+ && SYMBOL_REFERENCES_LOCAL (info, h))
{
BFD_ASSERT((h->got.offset & 1) != 0);
rela.r_info = ELF64_R_INFO (0, R_X86_64_RELATIVE);
@@ -2131,15 +2566,15 @@ elf64_x86_64_finish_dynamic_symbol (output_bfd, info, h, sym)
rela.r_addend = 0;
}
- loc = (Elf64_External_Rela *) htab->srelgot->contents;
- loc += htab->srelgot->reloc_count++;
+ loc = htab->srelgot->contents;
+ loc += htab->srelgot->reloc_count++ * sizeof (Elf64_External_Rela);
bfd_elf64_swap_reloca_out (output_bfd, &rela, loc);
}
if ((h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_COPY) != 0)
{
Elf_Internal_Rela rela;
- Elf64_External_Rela *loc;
+ bfd_byte *loc;
/* This symbol needs a copy reloc. Set it up. */
@@ -2154,8 +2589,8 @@ elf64_x86_64_finish_dynamic_symbol (output_bfd, info, h, sym)
+ h->root.u.def.section->output_offset);
rela.r_info = ELF64_R_INFO (h->dynindx, R_X86_64_COPY);
rela.r_addend = 0;
- loc = (Elf64_External_Rela *) htab->srelbss->contents;
- loc += htab->srelbss->reloc_count++;
+ loc = htab->srelbss->contents;
+ loc += htab->srelbss->reloc_count++ * sizeof (Elf64_External_Rela);
bfd_elf64_swap_reloca_out (output_bfd, &rela, loc);
}
@@ -2164,15 +2599,14 @@ elf64_x86_64_finish_dynamic_symbol (output_bfd, info, h, sym)
|| strcmp (h->root.root.string, "_GLOBAL_OFFSET_TABLE_") == 0)
sym->st_shndx = SHN_ABS;
- return true;
+ return TRUE;
}
/* Used to decide how to sort relocs in an optimal manner for the
dynamic linker, before writing them out. */
static enum elf_reloc_type_class
-elf64_x86_64_reloc_type_class (rela)
- const Elf_Internal_Rela *rela;
+elf64_x86_64_reloc_type_class (const Elf_Internal_Rela *rela)
{
switch ((int) ELF64_R_TYPE (rela->r_info))
{
@@ -2189,10 +2623,8 @@ elf64_x86_64_reloc_type_class (rela)
/* Finish up the dynamic sections. */
-static boolean
-elf64_x86_64_finish_dynamic_sections (output_bfd, info)
- bfd *output_bfd;
- struct bfd_link_info *info;
+static bfd_boolean
+elf64_x86_64_finish_dynamic_sections (bfd *output_bfd, struct bfd_link_info *info)
{
struct elf64_x86_64_link_hash_table *htab;
bfd *dynobj;
@@ -2315,7 +2747,7 @@ elf64_x86_64_finish_dynamic_sections (output_bfd, info)
GOT_ENTRY_SIZE;
}
- return true;
+ return TRUE;
}
@@ -2331,7 +2763,6 @@ elf64_x86_64_finish_dynamic_sections (output_bfd, info)
#define elf_backend_plt_readonly 1
#define elf_backend_want_plt_sym 0
#define elf_backend_got_header_size (GOT_ENTRY_SIZE*3)
-#define elf_backend_plt_header_size PLT_ENTRY_SIZE
#define elf_backend_rela_normal 1
#define elf_info_to_howto elf64_x86_64_info_to_howto
@@ -2354,5 +2785,6 @@ elf64_x86_64_finish_dynamic_sections (output_bfd, info)
#define elf_backend_relocate_section elf64_x86_64_relocate_section
#define elf_backend_size_dynamic_sections elf64_x86_64_size_dynamic_sections
#define elf_backend_object_p elf64_x86_64_elf_object_p
+#define bfd_elf64_mkobject elf64_x86_64_mkobject
#include "elf64-target.h"
diff --git a/contrib/binutils/bfd/elfarm-nabi.c b/contrib/binutils/bfd/elfarm-nabi.c
index 2d791de..5ecbe8e 100644
--- a/contrib/binutils/bfd/elfarm-nabi.c
+++ b/contrib/binutils/bfd/elfarm-nabi.c
@@ -1,5 +1,5 @@
/* 32-bit ELF support for ARM new abi option.
- Copyright 1999, 2000, 2001 Free Software Foundation, Inc.
+ Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -27,7 +27,7 @@
#define NUM_ELEM(a) (sizeof (a) / (sizeof (a)[0]))
#endif
-#define USE_REL
+#define USE_REL 1
#define TARGET_LITTLE_SYM bfd_elf32_littlearm_vec
#define TARGET_LITTLE_NAME "elf32-littlearm"
@@ -42,9 +42,9 @@
static reloc_howto_type * elf32_arm_reloc_type_lookup
PARAMS ((bfd * abfd, bfd_reloc_code_real_type code));
-static boolean elf32_arm_nabi_grok_prstatus
+static bfd_boolean elf32_arm_nabi_grok_prstatus
PARAMS ((bfd *abfd, Elf_Internal_Note *note));
-static boolean elf32_arm_nabi_grok_psinfo
+static bfd_boolean elf32_arm_nabi_grok_psinfo
PARAMS ((bfd *abfd, Elf_Internal_Note *note));
/* Note: code such as elf32_arm_reloc_type_lookup expect to use e.g.
@@ -58,247 +58,247 @@ static reloc_howto_type elf32_arm_howto_table[] =
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_NONE", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_PC24, /* type */
2, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
24, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_PC24", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x00ffffff, /* src_mask */
0x00ffffff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* 32 bit absolute */
HOWTO (R_ARM_ABS32, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_ABS32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* standard 32bit pc-relative reloc */
HOWTO (R_ARM_REL32, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_REL32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* 8 bit absolute */
HOWTO (R_ARM_PC13, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
8, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_PC13", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x000000ff, /* src_mask */
0x000000ff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 16 bit absolute */
HOWTO (R_ARM_ABS16, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_ABS16", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x0000ffff, /* src_mask */
0x0000ffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 12 bit absolute */
HOWTO (R_ARM_ABS12, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
12, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_ABS12", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x000008ff, /* src_mask */
0x000008ff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_THM_ABS5, /* type */
6, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
5, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_THM_ABS5", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x000007e0, /* src_mask */
0x000007e0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 8 bit absolute */
HOWTO (R_ARM_ABS8, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
8, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_ABS8", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x000000ff, /* src_mask */
0x000000ff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_SBREL32, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_SBREL32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_THM_PC22, /* type */
1, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
23, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_THM_PC22", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x07ff07ff, /* src_mask */
0x07ff07ff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
HOWTO (R_ARM_THM_PC8, /* type */
1, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
8, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_THM_PC8", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x000000ff, /* src_mask */
0x000000ff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
HOWTO (R_ARM_AMP_VCALL9, /* type */
1, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
8, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_AMP_VCALL9", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x000000ff, /* src_mask */
0x000000ff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
HOWTO (R_ARM_SWI24, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_SWI24", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x00000000, /* src_mask */
0x00000000, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_THM_SWI8, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_SWI8", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x00000000, /* src_mask */
0x00000000, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* BLX instruction for the ARM. */
HOWTO (R_ARM_XPC25, /* type */
2, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
25, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_XPC25", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x00ffffff, /* src_mask */
0x00ffffff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* BLX instruction for the Thumb. */
HOWTO (R_ARM_THM_XPC22, /* type */
2, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
22, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_THM_XPC22", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x07ff07ff, /* src_mask */
0x07ff07ff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* These next three relocs are not defined, but we need to fill the space. */
@@ -306,43 +306,43 @@ static reloc_howto_type elf32_arm_howto_table[] =
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_unknown_17", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_NONE, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_unknown_18", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_NONE, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_unknown_19", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Relocs used in ARM Linux */
@@ -350,113 +350,113 @@ static reloc_howto_type elf32_arm_howto_table[] =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_COPY", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_GLOB_DAT, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_GLOB_DAT", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_JUMP_SLOT, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_JUMP_SLOT", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_RELATIVE, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_RELATIVE", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_GOTOFF, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_GOTOFF", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_GOTPC, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_GOTPC", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
HOWTO (R_ARM_GOT32, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_GOT32", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_PLT32, /* type */
2, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
26, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_PLT32", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0x00ffffff, /* src_mask */
0x00ffffff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* End of relocs used in ARM Linux */
@@ -464,57 +464,57 @@ static reloc_howto_type elf32_arm_howto_table[] =
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_RREL32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_RABS32, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_RABS32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_RPC24, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_RPC24", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_RBASE, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_RBASE", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
};
@@ -524,15 +524,15 @@ static reloc_howto_type elf32_arm_vtinherit_howto =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
NULL, /* special_function */
"R_ARM_GNU_VTINHERIT", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false); /* pcrel_offset */
+ FALSE); /* pcrel_offset */
/* GNU extension to record C++ vtable member usage */
static reloc_howto_type elf32_arm_vtentry_howto =
@@ -540,15 +540,15 @@ static reloc_howto_type elf32_arm_vtentry_howto =
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
_bfd_elf_rel_vtable_reloc_fn, /* special_function */
"R_ARM_GNU_VTENTRY", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false); /* pcrel_offset */
+ FALSE); /* pcrel_offset */
/* 12 bit pc relative */
static reloc_howto_type elf32_arm_thm_pc11_howto =
@@ -556,15 +556,15 @@ static reloc_howto_type elf32_arm_thm_pc11_howto =
1, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
11, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_THM_PC11", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x000007ff, /* src_mask */
0x000007ff, /* dst_mask */
- true); /* pcrel_offset */
+ TRUE); /* pcrel_offset */
/* 12 bit pc relative */
static reloc_howto_type elf32_arm_thm_pc9_howto =
@@ -572,24 +572,24 @@ static reloc_howto_type elf32_arm_thm_pc9_howto =
1, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
8, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_THM_PC9", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x000000ff, /* src_mask */
0x000000ff, /* dst_mask */
- true); /* pcrel_offset */
+ TRUE); /* pcrel_offset */
static void elf32_arm_info_to_howto
- PARAMS ((bfd *, arelent *, Elf32_Internal_Rel *));
+ PARAMS ((bfd *, arelent *, Elf_Internal_Rela *));
static void
elf32_arm_info_to_howto (abfd, bfd_reloc, elf_reloc)
bfd * abfd ATTRIBUTE_UNUSED;
arelent * bfd_reloc;
- Elf32_Internal_Rel * elf_reloc;
+ Elf_Internal_Rela * elf_reloc;
{
unsigned int r_type;
@@ -682,7 +682,7 @@ elf32_arm_reloc_type_lookup (abfd, code)
}
/* Support for core dump NOTE sections */
-static boolean
+static bfd_boolean
elf32_arm_nabi_grok_prstatus (abfd, note)
bfd *abfd;
Elf_Internal_Note *note;
@@ -693,7 +693,7 @@ elf32_arm_nabi_grok_prstatus (abfd, note)
switch (note->descsz)
{
default:
- return false;
+ return FALSE;
case 148: /* Linux/ARM 32-bit*/
/* pr_cursig */
@@ -714,7 +714,7 @@ elf32_arm_nabi_grok_prstatus (abfd, note)
raw_size, note->descpos + offset);
}
-static boolean
+static bfd_boolean
elf32_arm_nabi_grok_psinfo (abfd, note)
bfd *abfd;
Elf_Internal_Note *note;
@@ -722,7 +722,7 @@ elf32_arm_nabi_grok_psinfo (abfd, note)
switch (note->descsz)
{
default:
- return false;
+ return FALSE;
case 124: /* Linux/ARM elf_prpsinfo */
elf_tdata (abfd)->core_program
@@ -743,7 +743,7 @@ elf32_arm_nabi_grok_psinfo (abfd, note)
command[n - 1] = '\0';
}
- return true;
+ return TRUE;
}
#define elf_backend_grok_prstatus elf32_arm_nabi_grok_prstatus
diff --git a/contrib/binutils/bfd/elfarm-oabi.c b/contrib/binutils/bfd/elfarm-oabi.c
index c8e3fe6..08ba41e 100644
--- a/contrib/binutils/bfd/elfarm-oabi.c
+++ b/contrib/binutils/bfd/elfarm-oabi.c
@@ -37,8 +37,6 @@
#define NUM_ELEM(a) (sizeof (a) / sizeof (a)[0])
#endif
-#define USE_RELA
-
#define TARGET_LITTLE_SYM bfd_elf32_littlearm_oabi_vec
#define TARGET_LITTLE_NAME "elf32-littlearm-oabi"
#define TARGET_BIG_SYM bfd_elf32_bigarm_oabi_vec
@@ -51,7 +49,7 @@
#define ARM_ELF_OS_ABI_VERSION 0
static reloc_howto_type * find_howto PARAMS ((unsigned int));
-static void elf32_arm_info_to_howto PARAMS ((bfd *, arelent *, Elf32_Internal_Rela *));
+static void elf32_arm_info_to_howto PARAMS ((bfd *, arelent *, Elf_Internal_Rela *));
static reloc_howto_type * elf32_arm_reloc_type_lookup PARAMS ((bfd *, bfd_reloc_code_real_type));
static reloc_howto_type elf32_arm_howto_table[] =
@@ -61,220 +59,220 @@ static reloc_howto_type elf32_arm_howto_table[] =
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_NONE", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_PC24, /* type */
2, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
24, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_PC24", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x00ffffff, /* src_mask */
0x00ffffff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* 32 bit absolute. */
HOWTO (R_ARM_ABS32, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_ABS32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* Standard 32bit pc-relative reloc. */
HOWTO (R_ARM_REL32, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
32, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_REL32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0xffffffff, /* src_mask */
0xffffffff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* 8 bit absolute. */
HOWTO (R_ARM_ABS8, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
8, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_ABS8", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x000000ff, /* src_mask */
0x000000ff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 16 bit absolute. */
HOWTO (R_ARM_ABS16, /* type */
0, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
16, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_ABS16", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* 12 bit absolute. */
HOWTO (R_ARM_ABS12, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
12, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_ABS12", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x000008ff, /* src_mask */
0x000008ff, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_THM_ABS5, /* type */
6, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
5, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_THM_ABS5", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x000007e0, /* src_mask */
0x000007e0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_THM_PC22, /* type */
1, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
23, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_THM_PC22", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x07ff07ff, /* src_mask */
0x07ff07ff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
HOWTO (R_ARM_SBREL32, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_SBREL32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_AMP_VCALL9, /* type */
1, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
8, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_AMP_VCALL9", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x000000ff, /* src_mask */
0x000000ff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* 12 bit pc relative. */
HOWTO (R_ARM_THM_PC11, /* type */
1, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
11, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_THM_PC11", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x000007ff, /* src_mask */
0x000007ff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* 12 bit pc relative. */
HOWTO (R_ARM_THM_PC9, /* type */
1, /* rightshift */
1, /* size (0 = byte, 1 = short, 2 = long) */
8, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_signed, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_THM_PC9", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0x000000ff, /* src_mask */
0x000000ff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* GNU extension to record C++ vtable hierarchy. */
HOWTO (R_ARM_GNU_VTINHERIT, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
NULL, /* special_function */
"R_ARM_GNU_VTINHERIT", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* GNU extension to record C++ vtable member usage. */
HOWTO (R_ARM_GNU_VTENTRY, /* type */
0, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
_bfd_elf_rel_vtable_reloc_fn, /* special_function */
"R_ARM_GNU_VTENTRY", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
/* XXX - gap in index numbering here. */
@@ -282,15 +280,15 @@ static reloc_howto_type elf32_arm_howto_table[] =
2, /* rightshift */
2, /* size (0 = byte, 1 = short, 2 = long) */
26, /* bitsize */
- true, /* pc_relative */
+ TRUE, /* pc_relative */
0, /* bitpos */
complain_overflow_bitfield,/* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_PLT32", /* name */
- true, /* partial_inplace */
+ TRUE, /* partial_inplace */
0x00ffffff, /* src_mask */
0x00ffffff, /* dst_mask */
- true), /* pcrel_offset */
+ TRUE), /* pcrel_offset */
/* XXX - gap in index numbering here. */
@@ -298,57 +296,57 @@ static reloc_howto_type elf32_arm_howto_table[] =
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_RREL32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_RABS32, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_RABS32", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_RPC24, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_RPC24", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false), /* pcrel_offset */
+ FALSE), /* pcrel_offset */
HOWTO (R_ARM_RBASE, /* type */
0, /* rightshift */
0, /* size (0 = byte, 1 = short, 2 = long) */
0, /* bitsize */
- false, /* pc_relative */
+ FALSE, /* pc_relative */
0, /* bitpos */
complain_overflow_dont, /* complain_on_overflow */
bfd_elf_generic_reloc, /* special_function */
"R_ARM_RBASE", /* name */
- false, /* partial_inplace */
+ FALSE, /* partial_inplace */
0, /* src_mask */
0, /* dst_mask */
- false) /* pcrel_offset */
+ FALSE) /* pcrel_offset */
};
/* Locate a reloc in the howto table. This function must be used
@@ -371,7 +369,7 @@ static void
elf32_arm_info_to_howto (abfd, bfd_reloc, elf_reloc)
bfd *abfd ATTRIBUTE_UNUSED;
arelent *bfd_reloc;
- Elf32_Internal_Rela *elf_reloc;
+ Elf_Internal_Rela *elf_reloc;
{
unsigned int r_type;
diff --git a/contrib/binutils/bfd/elfcode.h b/contrib/binutils/bfd/elfcode.h
index 4f54cd3..bc69d48 100644
--- a/contrib/binutils/bfd/elfcode.h
+++ b/contrib/binutils/bfd/elfcode.h
@@ -1,6 +1,6 @@
/* ELF executable support for BFD.
Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
- 2001, 2002 Free Software Foundation, Inc.
+ 2001, 2002, 2003 Free Software Foundation, Inc.
Written by Fred Fish @ Cygnus Support, from information published
in "UNIX System V Release 4, Programmers Guide: ANSI C and
@@ -102,7 +102,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define elf_get_reloc_upper_bound NAME(bfd_elf,get_reloc_upper_bound)
#define elf_canonicalize_reloc NAME(bfd_elf,canonicalize_reloc)
#define elf_slurp_symbol_table NAME(bfd_elf,slurp_symbol_table)
-#define elf_get_symtab NAME(bfd_elf,get_symtab)
+#define elf_canonicalize_symtab NAME(bfd_elf,canonicalize_symtab)
#define elf_canonicalize_dynamic_symtab \
NAME(bfd_elf,canonicalize_dynamic_symtab)
#define elf_make_empty_symbol NAME(bfd_elf,make_empty_symbol)
@@ -115,28 +115,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define elf_no_info_to_howto NAME(bfd_elf,no_info_to_howto)
#define elf_no_info_to_howto_rel NAME(bfd_elf,no_info_to_howto_rel)
#define elf_find_section NAME(bfd_elf,find_section)
-#define elf_bfd_link_add_symbols NAME(bfd_elf,bfd_link_add_symbols)
-#define elf_add_dynamic_entry NAME(bfd_elf,add_dynamic_entry)
#define elf_write_shdrs_and_ehdr NAME(bfd_elf,write_shdrs_and_ehdr)
#define elf_write_out_phdrs NAME(bfd_elf,write_out_phdrs)
#define elf_write_relocs NAME(bfd_elf,write_relocs)
#define elf_slurp_reloc_table NAME(bfd_elf,slurp_reloc_table)
-#define elf_link_create_dynamic_sections \
- NAME(bfd_elf,link_create_dynamic_sections)
-#define elf_bfd_discard_info NAME(bfd_elf,discard_info)
-#define elf_reloc_symbol_deleted_p NAME(_bfd_elf,reloc_symbol_deleted_p)
-#define elf_link_record_dynamic_symbol _bfd_elf_link_record_dynamic_symbol
-#define elf_bfd_final_link NAME(bfd_elf,bfd_final_link)
-#define elf_create_pointer_linker_section NAME(bfd_elf,create_pointer_linker_section)
-#define elf_finish_pointer_linker_section NAME(bfd_elf,finish_pointer_linker_section)
-#define elf_gc_sections NAME(_bfd_elf,gc_sections)
-#define elf_gc_common_finalize_got_offsets \
- NAME(_bfd_elf,gc_common_finalize_got_offsets)
-#define elf_gc_common_final_link NAME(_bfd_elf,gc_common_final_link)
-#define elf_gc_record_vtinherit NAME(_bfd_elf,gc_record_vtinherit)
-#define elf_gc_record_vtentry NAME(_bfd_elf,gc_record_vtentry)
-#define elf_link_record_local_dynamic_symbol \
- NAME(_bfd_elf,link_record_local_dynamic_symbol)
#if ARCH_SIZE == 64
#define ELF_R_INFO(X,Y) ELF64_R_INFO(X,Y)
@@ -155,31 +137,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define LOG_FILE_ALIGN 2
#endif
-/* Static functions */
-
-static void elf_swap_ehdr_in
- PARAMS ((bfd *, const Elf_External_Ehdr *, Elf_Internal_Ehdr *));
-static void elf_swap_ehdr_out
- PARAMS ((bfd *, const Elf_Internal_Ehdr *, Elf_External_Ehdr *));
-static void elf_swap_shdr_in
- PARAMS ((bfd *, const Elf_External_Shdr *, Elf_Internal_Shdr *));
-static void elf_swap_shdr_out
- PARAMS ((bfd *, const Elf_Internal_Shdr *, Elf_External_Shdr *));
-
-#define elf_stringtab_init _bfd_elf_stringtab_init
-
-#define section_from_elf_index bfd_section_from_elf_index
-
-static boolean elf_slurp_reloc_table_from_section
- PARAMS ((bfd *, asection *, Elf_Internal_Shdr *, bfd_size_type,
- arelent *, asymbol **, boolean));
-
-static boolean elf_file_p PARAMS ((Elf_External_Ehdr *));
-
#ifdef DEBUG
-static void elf_debug_section PARAMS ((int, Elf_Internal_Shdr *));
-static void elf_debug_file PARAMS ((Elf_Internal_Ehdr *));
-static char *elf_symbol_flags PARAMS ((flagword));
+static void elf_debug_section (int, Elf_Internal_Shdr *);
+static void elf_debug_file (Elf_Internal_Ehdr *);
+static char *elf_symbol_flags (flagword);
#endif
/* Structure swapping routines */
@@ -203,14 +164,13 @@ static char *elf_symbol_flags PARAMS ((flagword));
format. */
void
-elf_swap_symbol_in (abfd, psrc, pshn, dst)
- bfd *abfd;
- const PTR psrc;
- const PTR pshn;
- Elf_Internal_Sym *dst;
+elf_swap_symbol_in (bfd *abfd,
+ const void *psrc,
+ const void *pshn,
+ Elf_Internal_Sym *dst)
{
- const Elf_External_Sym *src = (const Elf_External_Sym *) psrc;
- const Elf_External_Sym_Shndx *shndx = (const Elf_External_Sym_Shndx *) pshn;
+ const Elf_External_Sym *src = psrc;
+ const Elf_External_Sym_Shndx *shndx = pshn;
int signed_vma = get_elf_backend_data (abfd)->sign_extend_vma;
dst->st_name = H_GET_32 (abfd, src->st_name);
@@ -234,14 +194,13 @@ elf_swap_symbol_in (abfd, psrc, pshn, dst)
format. */
void
-elf_swap_symbol_out (abfd, src, cdst, shndx)
- bfd *abfd;
- const Elf_Internal_Sym *src;
- PTR cdst;
- PTR shndx;
+elf_swap_symbol_out (bfd *abfd,
+ const Elf_Internal_Sym *src,
+ void *cdst,
+ void *shndx)
{
unsigned int tmp;
- Elf_External_Sym *dst = (Elf_External_Sym *) cdst;
+ Elf_External_Sym *dst = cdst;
H_PUT_32 (abfd, src->st_name, dst->st_name);
H_PUT_WORD (abfd, src->st_value, dst->st_value);
H_PUT_WORD (abfd, src->st_size, dst->st_size);
@@ -262,10 +221,9 @@ elf_swap_symbol_out (abfd, src, cdst, shndx)
internal format. */
static void
-elf_swap_ehdr_in (abfd, src, dst)
- bfd *abfd;
- const Elf_External_Ehdr *src;
- Elf_Internal_Ehdr *dst;
+elf_swap_ehdr_in (bfd *abfd,
+ const Elf_External_Ehdr *src,
+ Elf_Internal_Ehdr *dst)
{
int signed_vma = get_elf_backend_data (abfd)->sign_extend_vma;
memcpy (dst->e_ident, src->e_ident, EI_NIDENT);
@@ -291,10 +249,9 @@ elf_swap_ehdr_in (abfd, src, dst)
external format. */
static void
-elf_swap_ehdr_out (abfd, src, dst)
- bfd *abfd;
- const Elf_Internal_Ehdr *src;
- Elf_External_Ehdr *dst;
+elf_swap_ehdr_out (bfd *abfd,
+ const Elf_Internal_Ehdr *src,
+ Elf_External_Ehdr *dst)
{
unsigned int tmp;
int signed_vma = get_elf_backend_data (abfd)->sign_extend_vma;
@@ -328,10 +285,9 @@ elf_swap_ehdr_out (abfd, src, dst)
ELF section header table entry in internal format. */
static void
-elf_swap_shdr_in (abfd, src, dst)
- bfd *abfd;
- const Elf_External_Shdr *src;
- Elf_Internal_Shdr *dst;
+elf_swap_shdr_in (bfd *abfd,
+ const Elf_External_Shdr *src,
+ Elf_Internal_Shdr *dst)
{
int signed_vma = get_elf_backend_data (abfd)->sign_extend_vma;
@@ -356,10 +312,9 @@ elf_swap_shdr_in (abfd, src, dst)
ELF section header table entry in external format. */
static void
-elf_swap_shdr_out (abfd, src, dst)
- bfd *abfd;
- const Elf_Internal_Shdr *src;
- Elf_External_Shdr *dst;
+elf_swap_shdr_out (bfd *abfd,
+ const Elf_Internal_Shdr *src,
+ Elf_External_Shdr *dst)
{
/* note that all elements of dst are *arrays of unsigned char* already... */
H_PUT_32 (abfd, src->sh_name, dst->sh_name);
@@ -378,10 +333,9 @@ elf_swap_shdr_out (abfd, src, dst)
ELF program header table entry in internal format. */
void
-elf_swap_phdr_in (abfd, src, dst)
- bfd *abfd;
- const Elf_External_Phdr *src;
- Elf_Internal_Phdr *dst;
+elf_swap_phdr_in (bfd *abfd,
+ const Elf_External_Phdr *src,
+ Elf_Internal_Phdr *dst)
{
int signed_vma = get_elf_backend_data (abfd)->sign_extend_vma;
@@ -404,10 +358,9 @@ elf_swap_phdr_in (abfd, src, dst)
}
void
-elf_swap_phdr_out (abfd, src, dst)
- bfd *abfd;
- const Elf_Internal_Phdr *src;
- Elf_External_Phdr *dst;
+elf_swap_phdr_out (bfd *abfd,
+ const Elf_Internal_Phdr *src,
+ Elf_External_Phdr *dst)
{
/* note that all elements of dst are *arrays of unsigned char* already... */
H_PUT_32 (abfd, src->p_type, dst->p_type);
@@ -421,68 +374,67 @@ elf_swap_phdr_out (abfd, src, dst)
}
/* Translate an ELF reloc from external format to internal format. */
-INLINE void
-elf_swap_reloc_in (abfd, src, dst)
- bfd *abfd;
- const Elf_External_Rel *src;
- Elf_Internal_Rel *dst;
+void
+elf_swap_reloc_in (bfd *abfd,
+ const bfd_byte *s,
+ Elf_Internal_Rela *dst)
{
+ const Elf_External_Rel *src = (const Elf_External_Rel *) s;
dst->r_offset = H_GET_WORD (abfd, src->r_offset);
dst->r_info = H_GET_WORD (abfd, src->r_info);
+ dst->r_addend = 0;
}
-INLINE void
-elf_swap_reloca_in (abfd, src, dst)
- bfd *abfd;
- const Elf_External_Rela *src;
- Elf_Internal_Rela *dst;
+void
+elf_swap_reloca_in (bfd *abfd,
+ const bfd_byte *s,
+ Elf_Internal_Rela *dst)
{
+ const Elf_External_Rela *src = (const Elf_External_Rela *) s;
dst->r_offset = H_GET_WORD (abfd, src->r_offset);
dst->r_info = H_GET_WORD (abfd, src->r_info);
dst->r_addend = H_GET_SIGNED_WORD (abfd, src->r_addend);
}
/* Translate an ELF reloc from internal format to external format. */
-INLINE void
-elf_swap_reloc_out (abfd, src, dst)
- bfd *abfd;
- const Elf_Internal_Rel *src;
- Elf_External_Rel *dst;
+void
+elf_swap_reloc_out (bfd *abfd,
+ const Elf_Internal_Rela *src,
+ bfd_byte *d)
{
+ Elf_External_Rel *dst = (Elf_External_Rel *) d;
H_PUT_WORD (abfd, src->r_offset, dst->r_offset);
H_PUT_WORD (abfd, src->r_info, dst->r_info);
}
-INLINE void
-elf_swap_reloca_out (abfd, src, dst)
- bfd *abfd;
- const Elf_Internal_Rela *src;
- Elf_External_Rela *dst;
+void
+elf_swap_reloca_out (bfd *abfd,
+ const Elf_Internal_Rela *src,
+ bfd_byte *d)
{
+ Elf_External_Rela *dst = (Elf_External_Rela *) d;
H_PUT_WORD (abfd, src->r_offset, dst->r_offset);
H_PUT_WORD (abfd, src->r_info, dst->r_info);
H_PUT_SIGNED_WORD (abfd, src->r_addend, dst->r_addend);
}
-INLINE void
-elf_swap_dyn_in (abfd, p, dst)
- bfd *abfd;
- const PTR p;
- Elf_Internal_Dyn *dst;
+void
+elf_swap_dyn_in (bfd *abfd,
+ const void *p,
+ Elf_Internal_Dyn *dst)
{
- const Elf_External_Dyn *src = (const Elf_External_Dyn *) p;
+ const Elf_External_Dyn *src = p;
dst->d_tag = H_GET_WORD (abfd, src->d_tag);
dst->d_un.d_val = H_GET_WORD (abfd, src->d_un.d_val);
}
-INLINE void
-elf_swap_dyn_out (abfd, src, p)
- bfd *abfd;
- const Elf_Internal_Dyn *src;
- PTR p;
+void
+elf_swap_dyn_out (bfd *abfd,
+ const Elf_Internal_Dyn *src,
+ void *p)
{
- Elf_External_Dyn *dst = (Elf_External_Dyn *) p;
+ Elf_External_Dyn *dst = p;
H_PUT_WORD (abfd, src->d_tag, dst->d_tag);
H_PUT_WORD (abfd, src->d_un.d_val, dst->d_un.d_val);
@@ -495,9 +447,8 @@ elf_swap_dyn_out (abfd, src, p)
First we validate the file by reading in the ELF header and checking
the magic number. */
-static INLINE boolean
-elf_file_p (x_ehdrp)
- Elf_External_Ehdr *x_ehdrp;
+static inline bfd_boolean
+elf_file_p (Elf_External_Ehdr *x_ehdrp)
{
return ((x_ehdrp->e_ident[EI_MAG0] == ELFMAG0)
&& (x_ehdrp->e_ident[EI_MAG1] == ELFMAG1)
@@ -505,16 +456,6 @@ elf_file_p (x_ehdrp)
&& (x_ehdrp->e_ident[EI_MAG3] == ELFMAG3));
}
-struct bfd_preserve
-{
- const struct bfd_arch_info *arch_info;
- struct elf_obj_tdata *tdata;
- struct bfd_hash_table section_htab;
- struct sec *sections;
- struct sec **section_tail;
- unsigned int section_count;
-};
-
/* Check to see if the file associated with ABFD matches the target vector
that ABFD points to.
@@ -524,8 +465,7 @@ struct bfd_preserve
file does not match the target vector. */
const bfd_target *
-elf_object_p (abfd)
- bfd *abfd;
+elf_object_p (bfd *abfd)
{
Elf_External_Ehdr x_ehdr; /* Elf file header, external form */
Elf_Internal_Ehdr *i_ehdrp; /* Elf file header, internal form */
@@ -534,18 +474,16 @@ elf_object_p (abfd)
Elf_Internal_Shdr *i_shdrp; /* Section header table, internal form */
unsigned int shindex;
char *shstrtab; /* Internal copy of section header stringtab */
- struct elf_backend_data *ebd;
+ const struct elf_backend_data *ebd;
struct bfd_preserve preserve;
- struct elf_obj_tdata *new_tdata = NULL;
asection *s;
bfd_size_type amt;
- preserve.arch_info = abfd->arch_info;
+ preserve.marker = NULL;
/* Read in the ELF header in external format. */
- if (bfd_bread ((PTR) & x_ehdr, (bfd_size_type) sizeof (x_ehdr), abfd)
- != sizeof (x_ehdr))
+ if (bfd_bread (&x_ehdr, sizeof (x_ehdr), abfd) != sizeof (x_ehdr))
{
if (bfd_get_error () != bfd_error_system_call)
goto got_wrong_format_error;
@@ -580,27 +518,15 @@ elf_object_p (abfd)
goto got_wrong_format_error;
}
+ if (!bfd_preserve_save (abfd, &preserve))
+ goto got_no_match;
+
/* Allocate an instance of the elf_obj_tdata structure and hook it up to
the tdata pointer in the bfd. */
- amt = sizeof (struct elf_obj_tdata);
- new_tdata = (struct elf_obj_tdata *) bfd_zalloc (abfd, amt);
- if (new_tdata == NULL)
- goto got_no_match;
- preserve.tdata = elf_tdata (abfd);
- elf_tdata (abfd) = new_tdata;
-
- /* Clear section information, since there might be a recognized bfd that
- we now check if we can replace, and we don't want to append to it. */
- preserve.sections = abfd->sections;
- preserve.section_tail = abfd->section_tail;
- preserve.section_count = abfd->section_count;
- preserve.section_htab = abfd->section_htab;
- abfd->sections = NULL;
- abfd->section_tail = &abfd->sections;
- abfd->section_count = 0;
- if (!bfd_hash_table_init (&abfd->section_htab, bfd_section_hash_newfunc))
+ if (! (*abfd->xvec->_bfd_set_format[bfd_object]) (abfd))
goto got_no_match;
+ preserve.marker = elf_tdata (abfd);
/* Now that we know the byte order, swap in the rest of the header */
i_ehdrp = elf_elfheader (abfd);
@@ -633,8 +559,10 @@ elf_object_p (abfd)
/* Check that the ELF e_machine field matches what this particular
BFD format expects. */
if (ebd->elf_machine_code != i_ehdrp->e_machine
- && (ebd->elf_machine_alt1 == 0 || i_ehdrp->e_machine != ebd->elf_machine_alt1)
- && (ebd->elf_machine_alt2 == 0 || i_ehdrp->e_machine != ebd->elf_machine_alt2))
+ && (ebd->elf_machine_alt1 == 0
+ || i_ehdrp->e_machine != ebd->elf_machine_alt1)
+ && (ebd->elf_machine_alt2 == 0
+ || i_ehdrp->e_machine != ebd->elf_machine_alt2))
{
const bfd_target * const *target_ptr;
@@ -645,11 +573,11 @@ elf_object_p (abfd)
for which we do not have a specific backend. */
for (target_ptr = bfd_target_vector; *target_ptr != NULL; target_ptr++)
{
- struct elf_backend_data *back;
+ const struct elf_backend_data *back;
if ((*target_ptr)->flavour != bfd_target_elf_flavour)
continue;
- back = (struct elf_backend_data *) (*target_ptr)->backend_data;
+ back = (const struct elf_backend_data *) (*target_ptr)->backend_data;
if (back->elf_machine_code == i_ehdrp->e_machine
|| (back->elf_machine_alt1 != 0
&& back->elf_machine_alt1 == i_ehdrp->e_machine)
@@ -689,8 +617,7 @@ elf_object_p (abfd)
/* Read the first section header at index 0, and convert to internal
form. */
- if (bfd_bread ((PTR) & x_shdr, (bfd_size_type) sizeof x_shdr, abfd)
- != sizeof (x_shdr))
+ if (bfd_bread (&x_shdr, sizeof x_shdr, abfd) != sizeof (x_shdr))
goto got_no_match;
elf_swap_shdr_in (abfd, &x_shdr, &i_shdr);
@@ -712,7 +639,7 @@ elf_object_p (abfd)
unsigned int num_sec;
amt = sizeof (*i_shdrp) * i_ehdrp->e_shnum;
- i_shdrp = (Elf_Internal_Shdr *) bfd_alloc (abfd, amt);
+ i_shdrp = bfd_alloc (abfd, amt);
if (!i_shdrp)
goto got_no_match;
num_sec = i_ehdrp->e_shnum;
@@ -720,7 +647,7 @@ elf_object_p (abfd)
num_sec += SHN_HIRESERVE + 1 - SHN_LORESERVE;
elf_numsections (abfd) = num_sec;
amt = sizeof (i_shdrp) * num_sec;
- elf_elfsections (abfd) = (Elf_Internal_Shdr **) bfd_alloc (abfd, amt);
+ elf_elfsections (abfd) = bfd_alloc (abfd, amt);
if (!elf_elfsections (abfd))
goto got_no_match;
@@ -741,8 +668,7 @@ elf_object_p (abfd)
to internal form. */
for (shindex = 1; shindex < i_ehdrp->e_shnum; shindex++)
{
- if (bfd_bread ((PTR) & x_shdr, (bfd_size_type) sizeof x_shdr, abfd)
- != sizeof (x_shdr))
+ if (bfd_bread (&x_shdr, sizeof x_shdr, abfd) != sizeof (x_shdr))
goto got_no_match;
elf_swap_shdr_in (abfd, &x_shdr, i_shdrp + shindex);
@@ -773,7 +699,7 @@ elf_object_p (abfd)
unsigned int i;
amt = i_ehdrp->e_phnum * sizeof (Elf_Internal_Phdr);
- elf_tdata (abfd)->phdr = (Elf_Internal_Phdr *) bfd_alloc (abfd, amt);
+ elf_tdata (abfd)->phdr = bfd_alloc (abfd, amt);
if (elf_tdata (abfd)->phdr == NULL)
goto got_no_match;
if (bfd_seek (abfd, (file_ptr) i_ehdrp->e_phoff, SEEK_SET) != 0)
@@ -783,8 +709,7 @@ elf_object_p (abfd)
{
Elf_External_Phdr x_phdr;
- if (bfd_bread ((PTR) &x_phdr, (bfd_size_type) sizeof x_phdr, abfd)
- != sizeof x_phdr)
+ if (bfd_bread (&x_phdr, sizeof x_phdr, abfd) != sizeof x_phdr)
goto got_no_match;
elf_swap_phdr_in (abfd, &x_phdr, i_phdr);
}
@@ -844,11 +769,8 @@ elf_object_p (abfd)
}
}
- /* It would be nice to be able to free more memory here, eg. old
- elf_elfsections, old tdata, but that's not possible since these
- blocks are sitting inside obj_alloc'd memory. */
- bfd_hash_table_free (&preserve.section_htab);
- return (abfd->xvec);
+ bfd_preserve_finish (abfd, &preserve);
+ return abfd->xvec;
got_wrong_format_error:
/* There is way too much undoing of half-known state here. The caller,
@@ -863,18 +785,8 @@ elf_object_p (abfd)
bfd_set_error (bfd_error_wrong_format);
got_no_match:
- abfd->arch_info = preserve.arch_info;
- if (new_tdata != NULL)
- {
- /* bfd_release frees all memory more recently bfd_alloc'd than
- its arg, as well as its arg. */
- bfd_release (abfd, new_tdata);
- elf_tdata (abfd) = preserve.tdata;
- abfd->section_htab = preserve.section_htab;
- abfd->sections = preserve.sections;
- abfd->section_tail = preserve.section_tail;
- abfd->section_count = preserve.section_count;
- }
+ if (preserve.marker != NULL)
+ bfd_preserve_restore (abfd, &preserve);
return NULL;
}
@@ -883,19 +795,17 @@ elf_object_p (abfd)
/* Write out the relocs. */
void
-elf_write_relocs (abfd, sec, data)
- bfd *abfd;
- asection *sec;
- PTR data;
+elf_write_relocs (bfd *abfd, asection *sec, void *data)
{
- boolean *failedp = (boolean *) data;
+ bfd_boolean *failedp = data;
Elf_Internal_Shdr *rela_hdr;
- Elf_External_Rela *outbound_relocas;
- Elf_External_Rel *outbound_relocs;
+ bfd_vma addr_offset;
+ void (*swap_out) (bfd *, const Elf_Internal_Rela *, bfd_byte *);
+ size_t extsize;
+ bfd_byte *dst_rela;
unsigned int idx;
- int use_rela_p;
- asymbol *last_sym = 0;
- int last_sym_idx = 0;
+ asymbol *last_sym;
+ int last_sym_idx;
/* If we have already failed, don't do anything. */
if (*failedp)
@@ -914,148 +824,94 @@ elf_write_relocs (abfd, sec, data)
rela_hdr = &elf_section_data (sec)->rel_hdr;
rela_hdr->sh_size = rela_hdr->sh_entsize * sec->reloc_count;
- rela_hdr->contents = (PTR) bfd_alloc (abfd, rela_hdr->sh_size);
+ rela_hdr->contents = bfd_alloc (abfd, rela_hdr->sh_size);
if (rela_hdr->contents == NULL)
{
- *failedp = true;
+ *failedp = TRUE;
return;
}
/* Figure out whether the relocations are RELA or REL relocations. */
if (rela_hdr->sh_type == SHT_RELA)
- use_rela_p = true;
+ {
+ swap_out = elf_swap_reloca_out;
+ extsize = sizeof (Elf_External_Rela);
+ }
else if (rela_hdr->sh_type == SHT_REL)
- use_rela_p = false;
+ {
+ swap_out = elf_swap_reloc_out;
+ extsize = sizeof (Elf_External_Rel);
+ }
else
/* Every relocation section should be either an SHT_RELA or an
SHT_REL section. */
abort ();
+ /* The address of an ELF reloc is section relative for an object
+ file, and absolute for an executable file or shared library.
+ The address of a BFD reloc is always section relative. */
+ addr_offset = 0;
+ if ((abfd->flags & (EXEC_P | DYNAMIC)) != 0)
+ addr_offset = sec->vma;
+
/* orelocation has the data, reloc_count has the count... */
- if (use_rela_p)
- {
- outbound_relocas = (Elf_External_Rela *) rela_hdr->contents;
+ last_sym = 0;
+ last_sym_idx = 0;
+ dst_rela = rela_hdr->contents;
- for (idx = 0; idx < sec->reloc_count; idx++)
+ for (idx = 0; idx < sec->reloc_count; idx++, dst_rela += extsize)
+ {
+ Elf_Internal_Rela src_rela;
+ arelent *ptr;
+ asymbol *sym;
+ int n;
+
+ ptr = sec->orelocation[idx];
+ sym = *ptr->sym_ptr_ptr;
+ if (sym == last_sym)
+ n = last_sym_idx;
+ else if (bfd_is_abs_section (sym->section) && sym->value == 0)
+ n = STN_UNDEF;
+ else
{
- Elf_Internal_Rela dst_rela;
- Elf_External_Rela *src_rela;
- arelent *ptr;
- asymbol *sym;
- int n;
-
- ptr = sec->orelocation[idx];
- src_rela = outbound_relocas + idx;
-
- /* The address of an ELF reloc is section relative for an object
- file, and absolute for an executable file or shared library.
- The address of a BFD reloc is always section relative. */
- if ((abfd->flags & (EXEC_P | DYNAMIC)) == 0)
- dst_rela.r_offset = ptr->address;
- else
- dst_rela.r_offset = ptr->address + sec->vma;
-
- sym = *ptr->sym_ptr_ptr;
- if (sym == last_sym)
- n = last_sym_idx;
- else if (bfd_is_abs_section (sym->section) && sym->value == 0)
- n = STN_UNDEF;
- else
- {
- last_sym = sym;
- n = _bfd_elf_symbol_from_bfd_symbol (abfd, &sym);
- if (n < 0)
- {
- *failedp = true;
- return;
- }
- last_sym_idx = n;
- }
-
- if ((*ptr->sym_ptr_ptr)->the_bfd != NULL
- && (*ptr->sym_ptr_ptr)->the_bfd->xvec != abfd->xvec
- && ! _bfd_elf_validate_reloc (abfd, ptr))
+ last_sym = sym;
+ n = _bfd_elf_symbol_from_bfd_symbol (abfd, &sym);
+ if (n < 0)
{
- *failedp = true;
+ *failedp = TRUE;
return;
}
-
- dst_rela.r_info = ELF_R_INFO (n, ptr->howto->type);
-
- dst_rela.r_addend = ptr->addend;
- elf_swap_reloca_out (abfd, &dst_rela, src_rela);
+ last_sym_idx = n;
}
- }
- else
- /* REL relocations */
- {
- outbound_relocs = (Elf_External_Rel *) rela_hdr->contents;
- for (idx = 0; idx < sec->reloc_count; idx++)
+ if ((*ptr->sym_ptr_ptr)->the_bfd != NULL
+ && (*ptr->sym_ptr_ptr)->the_bfd->xvec != abfd->xvec
+ && ! _bfd_elf_validate_reloc (abfd, ptr))
{
- Elf_Internal_Rel dst_rel;
- Elf_External_Rel *src_rel;
- arelent *ptr;
- int n;
- asymbol *sym;
-
- ptr = sec->orelocation[idx];
- sym = *ptr->sym_ptr_ptr;
- src_rel = outbound_relocs + idx;
-
- /* The address of an ELF reloc is section relative for an object
- file, and absolute for an executable file or shared library.
- The address of a BFD reloc is always section relative. */
- if ((abfd->flags & (EXEC_P | DYNAMIC)) == 0)
- dst_rel.r_offset = ptr->address;
- else
- dst_rel.r_offset = ptr->address + sec->vma;
-
- if (sym == last_sym)
- n = last_sym_idx;
- else if (bfd_is_abs_section (sym->section) && sym->value == 0)
- n = STN_UNDEF;
- else
- {
- last_sym = sym;
- n = _bfd_elf_symbol_from_bfd_symbol (abfd, &sym);
- if (n < 0)
- {
- *failedp = true;
- return;
- }
- last_sym_idx = n;
- }
-
- if ((*ptr->sym_ptr_ptr)->the_bfd != NULL
- && (*ptr->sym_ptr_ptr)->the_bfd->xvec != abfd->xvec
- && ! _bfd_elf_validate_reloc (abfd, ptr))
- {
- *failedp = true;
- return;
- }
-
- dst_rel.r_info = ELF_R_INFO (n, ptr->howto->type);
-
- elf_swap_reloc_out (abfd, &dst_rel, src_rel);
+ *failedp = TRUE;
+ return;
}
+
+ src_rela.r_offset = ptr->address + addr_offset;
+ src_rela.r_info = ELF_R_INFO (n, ptr->howto->type);
+ src_rela.r_addend = ptr->addend;
+ (*swap_out) (abfd, &src_rela, dst_rela);
}
}
/* Write out the program headers. */
int
-elf_write_out_phdrs (abfd, phdr, count)
- bfd *abfd;
- const Elf_Internal_Phdr *phdr;
- unsigned int count;
+elf_write_out_phdrs (bfd *abfd,
+ const Elf_Internal_Phdr *phdr,
+ unsigned int count)
{
while (count--)
{
Elf_External_Phdr extphdr;
elf_swap_phdr_out (abfd, phdr, &extphdr);
- if (bfd_bwrite (&extphdr, (bfd_size_type) sizeof (Elf_External_Phdr),
- abfd) != sizeof (Elf_External_Phdr))
+ if (bfd_bwrite (&extphdr, sizeof (Elf_External_Phdr), abfd)
+ != sizeof (Elf_External_Phdr))
return -1;
phdr++;
}
@@ -1064,9 +920,8 @@ elf_write_out_phdrs (abfd, phdr, count)
/* Write out the section headers and the ELF file header. */
-boolean
-elf_write_shdrs_and_ehdr (abfd)
- bfd *abfd;
+bfd_boolean
+elf_write_shdrs_and_ehdr (bfd *abfd)
{
Elf_External_Ehdr x_ehdr; /* Elf file header, external form */
Elf_Internal_Ehdr *i_ehdrp; /* Elf file header, internal form */
@@ -1086,8 +941,8 @@ elf_write_shdrs_and_ehdr (abfd)
elf_swap_ehdr_out (abfd, i_ehdrp, &x_ehdr);
amt = sizeof (x_ehdr);
if (bfd_seek (abfd, (file_ptr) 0, SEEK_SET) != 0
- || bfd_bwrite ((PTR) & x_ehdr, amt, abfd) != amt)
- return false;
+ || bfd_bwrite (&x_ehdr, amt, abfd) != amt)
+ return FALSE;
/* Some fields in the first section header handle overflow of ehdr
fields. */
@@ -1099,9 +954,9 @@ elf_write_shdrs_and_ehdr (abfd)
/* at this point we've concocted all the ELF sections... */
amt = i_ehdrp->e_shnum;
amt *= sizeof (*x_shdrp);
- x_shdrp = (Elf_External_Shdr *) bfd_alloc (abfd, amt);
+ x_shdrp = bfd_alloc (abfd, amt);
if (!x_shdrp)
- return false;
+ return FALSE;
for (count = 0; count < i_ehdrp->e_shnum; i_shdrp++, count++)
{
@@ -1109,24 +964,21 @@ elf_write_shdrs_and_ehdr (abfd)
elf_debug_section (count, *i_shdrp);
#endif
elf_swap_shdr_out (abfd, *i_shdrp, x_shdrp + count);
-
+
if (count == SHN_LORESERVE - 1)
i_shdrp += SHN_HIRESERVE + 1 - SHN_LORESERVE;
}
if (bfd_seek (abfd, (file_ptr) i_ehdrp->e_shoff, SEEK_SET) != 0
- || bfd_bwrite ((PTR) x_shdrp, amt, abfd) != amt)
- return false;
+ || bfd_bwrite (x_shdrp, amt, abfd) != amt)
+ return FALSE;
/* need to dump the string table too... */
- return true;
+ return TRUE;
}
long
-elf_slurp_symbol_table (abfd, symptrs, dynamic)
- bfd *abfd;
- asymbol **symptrs; /* Buffer for generated bfd symbols */
- boolean dynamic;
+elf_slurp_symbol_table (bfd *abfd, asymbol **symptrs, bfd_boolean dynamic)
{
Elf_Internal_Shdr *hdr;
Elf_Internal_Shdr *verhdr;
@@ -1138,7 +990,7 @@ elf_slurp_symbol_table (abfd, symptrs, dynamic)
Elf_Internal_Sym *isymbuf = NULL;
Elf_External_Versym *xver;
Elf_External_Versym *xverbuf = NULL;
- struct elf_backend_data *ebd;
+ const struct elf_backend_data *ebd;
bfd_size_type amt;
/* Read each raw ELF symbol, converting from external ELF form to
@@ -1186,7 +1038,7 @@ elf_slurp_symbol_table (abfd, symptrs, dynamic)
amt = symcount;
amt *= sizeof (elf_symbol_type);
- symbase = (elf_symbol_type *) bfd_zalloc (abfd, amt);
+ symbase = bfd_zalloc (abfd, amt);
if (symbase == (elf_symbol_type *) NULL)
goto error_return;
@@ -1210,12 +1062,11 @@ elf_slurp_symbol_table (abfd, symptrs, dynamic)
if (bfd_seek (abfd, verhdr->sh_offset, SEEK_SET) != 0)
goto error_return;
- xverbuf = (Elf_External_Versym *) bfd_malloc (verhdr->sh_size);
+ xverbuf = bfd_malloc (verhdr->sh_size);
if (xverbuf == NULL && verhdr->sh_size != 0)
goto error_return;
- if (bfd_bread ((PTR) xverbuf, verhdr->sh_size, abfd)
- != verhdr->sh_size)
+ if (bfd_bread (xverbuf, verhdr->sh_size, abfd) != verhdr->sh_size)
goto error_return;
}
@@ -1242,8 +1093,8 @@ elf_slurp_symbol_table (abfd, symptrs, dynamic)
else if (isym->st_shndx < SHN_LORESERVE
|| isym->st_shndx > SHN_HIRESERVE)
{
- sym->symbol.section = section_from_elf_index (abfd,
- isym->st_shndx);
+ sym->symbol.section = bfd_section_from_elf_index (abfd,
+ isym->st_shndx);
if (sym->symbol.section == NULL)
{
/* This symbol is in a section for which we did not
@@ -1268,7 +1119,7 @@ elf_slurp_symbol_table (abfd, symptrs, dynamic)
else
sym->symbol.section = bfd_abs_section_ptr;
- /* If this is a relocateable file, then the symbol value is
+ /* If this is a relocatable file, then the symbol value is
already section relative. */
if ((abfd->flags & (EXEC_P | DYNAMIC)) != 0)
sym->symbol.value -= sym->symbol.section->vma;
@@ -1360,26 +1211,24 @@ error_return:
/* Read relocations for ASECT from REL_HDR. There are RELOC_COUNT of
them. */
-static boolean
-elf_slurp_reloc_table_from_section (abfd, asect, rel_hdr, reloc_count,
- relents, symbols, dynamic)
- bfd *abfd;
- asection *asect;
- Elf_Internal_Shdr *rel_hdr;
- bfd_size_type reloc_count;
- arelent *relents;
- asymbol **symbols;
- boolean dynamic;
+static bfd_boolean
+elf_slurp_reloc_table_from_section (bfd *abfd,
+ asection *asect,
+ Elf_Internal_Shdr *rel_hdr,
+ bfd_size_type reloc_count,
+ arelent *relents,
+ asymbol **symbols,
+ bfd_boolean dynamic)
{
- struct elf_backend_data * const ebd = get_elf_backend_data (abfd);
- PTR allocated = NULL;
+ const struct elf_backend_data * const ebd = get_elf_backend_data (abfd);
+ void *allocated = NULL;
bfd_byte *native_relocs;
arelent *relent;
unsigned int i;
int entsize;
unsigned int symcount;
- allocated = (PTR) bfd_malloc (rel_hdr->sh_size);
+ allocated = bfd_malloc (rel_hdr->sh_size);
if (allocated == NULL)
goto error_return;
@@ -1388,7 +1237,7 @@ elf_slurp_reloc_table_from_section (abfd, asect, rel_hdr, reloc_count,
!= rel_hdr->sh_size))
goto error_return;
- native_relocs = (bfd_byte *) allocated;
+ native_relocs = allocated;
entsize = rel_hdr->sh_entsize;
BFD_ASSERT (entsize == sizeof (Elf_External_Rel)
@@ -1404,17 +1253,11 @@ elf_slurp_reloc_table_from_section (abfd, asect, rel_hdr, reloc_count,
i++, relent++, native_relocs += entsize)
{
Elf_Internal_Rela rela;
- Elf_Internal_Rel rel;
if (entsize == sizeof (Elf_External_Rela))
- elf_swap_reloca_in (abfd, (Elf_External_Rela *) native_relocs, &rela);
+ elf_swap_reloca_in (abfd, native_relocs, &rela);
else
- {
- elf_swap_reloc_in (abfd, (Elf_External_Rel *) native_relocs, &rel);
- rela.r_offset = rel.r_offset;
- rela.r_info = rel.r_info;
- rela.r_addend = 0;
- }
+ elf_swap_reloc_in (abfd, native_relocs, &rela);
/* The address of an ELF reloc is section relative for an object
file, and absolute for an executable file or shared library.
@@ -1450,31 +1293,32 @@ elf_slurp_reloc_table_from_section (abfd, asect, rel_hdr, reloc_count,
relent->addend = rela.r_addend;
- if (entsize == sizeof (Elf_External_Rela))
+ if ((entsize == sizeof (Elf_External_Rela)
+ && ebd->elf_info_to_howto != NULL)
+ || ebd->elf_info_to_howto_rel == NULL)
(*ebd->elf_info_to_howto) (abfd, relent, &rela);
else
- (*ebd->elf_info_to_howto_rel) (abfd, relent, &rel);
+ (*ebd->elf_info_to_howto_rel) (abfd, relent, &rela);
}
if (allocated != NULL)
free (allocated);
- return true;
+ return TRUE;
error_return:
if (allocated != NULL)
free (allocated);
- return false;
+ return FALSE;
}
/* Read in and swap the external relocs. */
-boolean
-elf_slurp_reloc_table (abfd, asect, symbols, dynamic)
- bfd *abfd;
- asection *asect;
- asymbol **symbols;
- boolean dynamic;
+bfd_boolean
+elf_slurp_reloc_table (bfd *abfd,
+ asection *asect,
+ asymbol **symbols,
+ bfd_boolean dynamic)
{
struct bfd_elf_section_data * const d = elf_section_data (asect);
Elf_Internal_Shdr *rel_hdr;
@@ -1485,13 +1329,13 @@ elf_slurp_reloc_table (abfd, asect, symbols, dynamic)
bfd_size_type amt;
if (asect->relocation != NULL)
- return true;
+ return TRUE;
if (! dynamic)
{
if ((asect->flags & SEC_RELOC) == 0
|| asect->reloc_count == 0)
- return true;
+ return TRUE;
rel_hdr = &d->rel_hdr;
reloc_count = NUM_SHDR_ENTRIES (rel_hdr);
@@ -1510,7 +1354,7 @@ elf_slurp_reloc_table (abfd, asect, symbols, dynamic)
dynamic symbol table, and in that case bfd_section_from_shdr
in elf.c does not update the RELOC_COUNT. */
if (asect->_raw_size == 0)
- return true;
+ return TRUE;
rel_hdr = &d->this_hdr;
reloc_count = NUM_SHDR_ENTRIES (rel_hdr);
@@ -1519,32 +1363,30 @@ elf_slurp_reloc_table (abfd, asect, symbols, dynamic)
}
amt = (reloc_count + reloc_count2) * sizeof (arelent);
- relents = (arelent *) bfd_alloc (abfd, amt);
+ relents = bfd_alloc (abfd, amt);
if (relents == NULL)
- return false;
+ return FALSE;
if (!elf_slurp_reloc_table_from_section (abfd, asect,
rel_hdr, reloc_count,
relents,
symbols, dynamic))
- return false;
+ return FALSE;
if (rel_hdr2
&& !elf_slurp_reloc_table_from_section (abfd, asect,
rel_hdr2, reloc_count2,
relents + reloc_count,
symbols, dynamic))
- return false;
+ return FALSE;
asect->relocation = relents;
- return true;
+ return TRUE;
}
#ifdef DEBUG
static void
-elf_debug_section (num, hdr)
- int num;
- Elf_Internal_Shdr *hdr;
+elf_debug_section (int num, Elf_Internal_Shdr *hdr)
{
fprintf (stderr, "\nSection#%d '%s' 0x%.8lx\n", num,
hdr->bfd_section != NULL ? hdr->bfd_section->name : "",
@@ -1570,8 +1412,7 @@ elf_debug_section (num, hdr)
}
static void
-elf_debug_file (ehdrp)
- Elf_Internal_Ehdr *ehdrp;
+elf_debug_file (Elf_Internal_Ehdr *ehdrp)
{
fprintf (stderr, "e_entry = 0x%.8lx\n", (long) ehdrp->e_entry);
fprintf (stderr, "e_phoff = %ld\n", (long) ehdrp->e_phoff);
@@ -1583,8 +1424,7 @@ elf_debug_file (ehdrp)
}
static char *
-elf_symbol_flags (flags)
- flagword flags;
+elf_symbol_flags (flagword flags)
{
static char buffer[1024];
@@ -1655,8 +1495,230 @@ elf_symbol_flags (flags)
}
#endif
+/* Create a new BFD as if by bfd_openr. Rather than opening a file,
+ reconstruct an ELF file by reading the segments out of remote memory
+ based on the ELF file header at EHDR_VMA and the ELF program headers it
+ points to. If not null, *LOADBASEP is filled in with the difference
+ between the VMAs from which the segments were read, and the VMAs the
+ file headers (and hence BFD's idea of each section's VMA) put them at.
+
+ The function TARGET_READ_MEMORY is called to copy LEN bytes from the
+ remote memory at target address VMA into the local buffer at MYADDR; it
+ should return zero on success or an `errno' code on failure. TEMPL must
+ be a BFD for a target with the word size and byte order found in the
+ remote memory. */
+
+bfd *
+NAME(_bfd_elf,bfd_from_remote_memory)
+ (bfd *templ,
+ bfd_vma ehdr_vma,
+ bfd_vma *loadbasep,
+ int (*target_read_memory) (bfd_vma, char *, int))
+{
+ Elf_External_Ehdr x_ehdr; /* Elf file header, external form */
+ Elf_Internal_Ehdr i_ehdr; /* Elf file header, internal form */
+ Elf_External_Phdr *x_phdrs;
+ Elf_Internal_Phdr *i_phdrs, *last_phdr;
+ bfd *nbfd;
+ struct bfd_in_memory *bim;
+ int contents_size;
+ char *contents;
+ int err;
+ unsigned int i;
+ bfd_vma loadbase;
+
+ /* Read in the ELF header in external format. */
+ err = target_read_memory (ehdr_vma, (char *) &x_ehdr, sizeof x_ehdr);
+ if (err)
+ {
+ bfd_set_error (bfd_error_system_call);
+ errno = err;
+ return NULL;
+ }
+
+ /* Now check to see if we have a valid ELF file, and one that BFD can
+ make use of. The magic number must match, the address size ('class')
+ and byte-swapping must match our XVEC entry. */
+
+ if (! elf_file_p (&x_ehdr)
+ || x_ehdr.e_ident[EI_VERSION] != EV_CURRENT
+ || x_ehdr.e_ident[EI_CLASS] != ELFCLASS)
+ {
+ bfd_set_error (bfd_error_wrong_format);
+ return NULL;
+ }
+
+ /* Check that file's byte order matches xvec's */
+ switch (x_ehdr.e_ident[EI_DATA])
+ {
+ case ELFDATA2MSB: /* Big-endian */
+ if (! bfd_header_big_endian (templ))
+ {
+ bfd_set_error (bfd_error_wrong_format);
+ return NULL;
+ }
+ break;
+ case ELFDATA2LSB: /* Little-endian */
+ if (! bfd_header_little_endian (templ))
+ {
+ bfd_set_error (bfd_error_wrong_format);
+ return NULL;
+ }
+ break;
+ case ELFDATANONE: /* No data encoding specified */
+ default: /* Unknown data encoding specified */
+ bfd_set_error (bfd_error_wrong_format);
+ return NULL;
+ }
+
+ elf_swap_ehdr_in (templ, &x_ehdr, &i_ehdr);
+
+ /* The file header tells where to find the program headers.
+ These are what we use to actually choose what to read. */
+
+ if (i_ehdr.e_phentsize != sizeof (Elf_External_Phdr) || i_ehdr.e_phnum == 0)
+ {
+ bfd_set_error (bfd_error_wrong_format);
+ return NULL;
+ }
+
+ x_phdrs = bfd_malloc (i_ehdr.e_phnum * (sizeof *x_phdrs + sizeof *i_phdrs));
+ if (x_phdrs == NULL)
+ {
+ bfd_set_error (bfd_error_no_memory);
+ return NULL;
+ }
+ err = target_read_memory (ehdr_vma + i_ehdr.e_phoff, (char *) x_phdrs,
+ i_ehdr.e_phnum * sizeof x_phdrs[0]);
+ if (err)
+ {
+ free (x_phdrs);
+ bfd_set_error (bfd_error_system_call);
+ errno = err;
+ return NULL;
+ }
+ i_phdrs = (Elf_Internal_Phdr *) &x_phdrs[i_ehdr.e_phnum];
+
+ contents_size = 0;
+ last_phdr = NULL;
+ loadbase = ehdr_vma;
+ for (i = 0; i < i_ehdr.e_phnum; ++i)
+ {
+ elf_swap_phdr_in (templ, &x_phdrs[i], &i_phdrs[i]);
+ if (i_phdrs[i].p_type == PT_LOAD)
+ {
+ bfd_vma segment_end;
+ segment_end = (i_phdrs[i].p_offset + i_phdrs[i].p_filesz
+ + i_phdrs[i].p_align - 1) & -i_phdrs[i].p_align;
+ if (segment_end > (bfd_vma) contents_size)
+ contents_size = segment_end;
+
+ if ((i_phdrs[i].p_offset & -i_phdrs[i].p_align) == 0)
+ loadbase = ehdr_vma - (i_phdrs[i].p_vaddr & -i_phdrs[i].p_align);
+
+ last_phdr = &i_phdrs[i];
+ }
+ }
+ if (last_phdr == NULL)
+ {
+ /* There were no PT_LOAD segments, so we don't have anything to read. */
+ free (x_phdrs);
+ bfd_set_error (bfd_error_wrong_format);
+ return NULL;
+ }
+
+ /* Trim the last segment so we don't bother with zeros in the last page
+ that are off the end of the file. However, if the extra bit in that
+ page includes the section headers, keep them. */
+ if ((bfd_vma) contents_size > last_phdr->p_offset + last_phdr->p_filesz
+ && (bfd_vma) contents_size >= (i_ehdr.e_shoff
+ + i_ehdr.e_shnum * i_ehdr.e_shentsize))
+ {
+ contents_size = last_phdr->p_offset + last_phdr->p_filesz;
+ if ((bfd_vma) contents_size < (i_ehdr.e_shoff
+ + i_ehdr.e_shnum * i_ehdr.e_shentsize))
+ contents_size = i_ehdr.e_shoff + i_ehdr.e_shnum * i_ehdr.e_shentsize;
+ }
+ else
+ contents_size = last_phdr->p_offset + last_phdr->p_filesz;
+
+ /* Now we know the size of the whole image we want read in. */
+ contents = bfd_zmalloc (contents_size);
+ if (contents == NULL)
+ {
+ free (x_phdrs);
+ bfd_set_error (bfd_error_no_memory);
+ return NULL;
+ }
+
+ for (i = 0; i < i_ehdr.e_phnum; ++i)
+ if (i_phdrs[i].p_type == PT_LOAD)
+ {
+ bfd_vma start = i_phdrs[i].p_offset & -i_phdrs[i].p_align;
+ bfd_vma end = (i_phdrs[i].p_offset + i_phdrs[i].p_filesz
+ + i_phdrs[i].p_align - 1) & -i_phdrs[i].p_align;
+ if (end > (bfd_vma) contents_size)
+ end = contents_size;
+ err = target_read_memory ((loadbase + i_phdrs[i].p_vaddr)
+ & -i_phdrs[i].p_align,
+ contents + start, end - start);
+ if (err)
+ {
+ free (x_phdrs);
+ free (contents);
+ bfd_set_error (bfd_error_system_call);
+ errno = err;
+ return NULL;
+ }
+ }
+ free (x_phdrs);
+
+ /* If the segments visible in memory didn't include the section headers,
+ then clear them from the file header. */
+ if ((bfd_vma) contents_size < (i_ehdr.e_shoff
+ + i_ehdr.e_shnum * i_ehdr.e_shentsize))
+ {
+ memset (&x_ehdr.e_shoff, 0, sizeof x_ehdr.e_shoff);
+ memset (&x_ehdr.e_shnum, 0, sizeof x_ehdr.e_shnum);
+ memset (&x_ehdr.e_shstrndx, 0, sizeof x_ehdr.e_shstrndx);
+ }
+
+ /* This will normally have been in the first PT_LOAD segment. But it
+ conceivably could be missing, and we might have just changed it. */
+ memcpy (contents, &x_ehdr, sizeof x_ehdr);
+
+ /* Now we have a memory image of the ELF file contents. Make a BFD. */
+ bim = bfd_malloc (sizeof (struct bfd_in_memory));
+ if (bim == NULL)
+ {
+ free (contents);
+ bfd_set_error (bfd_error_no_memory);
+ return NULL;
+ }
+ nbfd = _bfd_new_bfd ();
+ if (nbfd == NULL)
+ {
+ free (bim);
+ free (contents);
+ bfd_set_error (bfd_error_no_memory);
+ return NULL;
+ }
+ nbfd->filename = "<in-memory>";
+ nbfd->xvec = templ->xvec;
+ bim->size = contents_size;
+ bim->buffer = contents;
+ nbfd->iostream = bim;
+ nbfd->flags = BFD_IN_MEMORY;
+ nbfd->direction = read_direction;
+ nbfd->mtime = time (NULL);
+ nbfd->mtime_set = TRUE;
+
+ if (loadbasep)
+ *loadbasep = loadbase;
+ return nbfd;
+}
+
#include "elfcore.h"
-#include "elflink.h"
/* Size-dependent data and functions. */
const struct elf_size_info NAME(_bfd_elf,size_info) = {
@@ -1670,7 +1732,7 @@ const struct elf_size_info NAME(_bfd_elf,size_info) = {
sizeof (Elf_External_Note),
4,
1,
- ARCH_SIZE, FILE_ALIGN,
+ ARCH_SIZE, LOG_FILE_ALIGN,
ELFCLASS, EV_CURRENT,
elf_write_out_phdrs,
elf_write_shdrs_and_ehdr,
@@ -1681,8 +1743,8 @@ const struct elf_size_info NAME(_bfd_elf,size_info) = {
elf_slurp_symbol_table,
elf_swap_dyn_in,
elf_swap_dyn_out,
- NULL,
- NULL,
- NULL,
- NULL
+ elf_swap_reloc_in,
+ elf_swap_reloc_out,
+ elf_swap_reloca_in,
+ elf_swap_reloca_out
};
diff --git a/contrib/binutils/bfd/elfcore.h b/contrib/binutils/bfd/elfcore.h
index 7db5f72..81c4cff 100644
--- a/contrib/binutils/bfd/elfcore.h
+++ b/contrib/binutils/bfd/elfcore.h
@@ -1,41 +1,37 @@
/* ELF core file support for BFD.
- Copyright 1995, 1996, 1997, 1998, 2000, 2001, 2002
+ Copyright 1995, 1996, 1997, 1998, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
char*
-elf_core_file_failing_command (abfd)
- bfd *abfd;
+elf_core_file_failing_command (bfd *abfd)
{
return elf_tdata (abfd)->core_command;
}
int
-elf_core_file_failing_signal (abfd)
- bfd *abfd;
+elf_core_file_failing_signal (bfd *abfd)
{
return elf_tdata (abfd)->core_signal;
}
-boolean
-elf_core_file_matches_executable_p (core_bfd, exec_bfd)
- bfd *core_bfd;
- bfd *exec_bfd;
+bfd_boolean
+elf_core_file_matches_executable_p (bfd *core_bfd, bfd *exec_bfd)
{
char* corename;
@@ -44,22 +40,22 @@ elf_core_file_matches_executable_p (core_bfd, exec_bfd)
if (core_bfd->xvec != exec_bfd->xvec)
{
bfd_set_error (bfd_error_system_call);
- return false;
+ return FALSE;
}
/* See if the name in the corefile matches the executable name. */
-
corename = elf_tdata (core_bfd)->core_program;
if (corename != NULL)
{
const char* execname = strrchr (exec_bfd->filename, '/');
+
execname = execname ? execname + 1 : exec_bfd->filename;
- if (strcmp(execname, corename) != 0)
- return false;
+ if (strcmp (execname, corename) != 0)
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Core files are simply standard ELF formatted files that partition
@@ -71,39 +67,35 @@ elf_core_file_matches_executable_p (core_bfd, exec_bfd)
register set) and the floating point register set are stored in a
segment of type PT_NOTE. We handcraft a couple of extra bfd sections
that allow standard bfd access to the general registers (.reg) and the
- floating point registers (.reg2).
-
- */
+ floating point registers (.reg2). */
const bfd_target *
-elf_core_file_p (abfd)
- bfd *abfd;
+elf_core_file_p (bfd *abfd)
{
- Elf_External_Ehdr x_ehdr; /* Elf file header, external form */
- Elf_Internal_Ehdr *i_ehdrp; /* Elf file header, internal form */
- Elf_Internal_Phdr *i_phdrp; /* Elf program header, internal form */
+ Elf_External_Ehdr x_ehdr; /* Elf file header, external form. */
+ Elf_Internal_Ehdr *i_ehdrp; /* Elf file header, internal form. */
+ Elf_Internal_Phdr *i_phdrp; /* Elf program header, internal form. */
unsigned int phindex;
- struct elf_backend_data *ebd;
+ const struct elf_backend_data *ebd;
struct bfd_preserve preserve;
- struct elf_obj_tdata *new_tdata = NULL;
bfd_size_type amt;
- preserve.arch_info = abfd->arch_info;
+ preserve.marker = NULL;
/* Read in the ELF header in external format. */
- if (bfd_bread ((PTR) &x_ehdr, (bfd_size_type) sizeof (x_ehdr), abfd)
- != sizeof (x_ehdr))
+ if (bfd_bread (&x_ehdr, sizeof (x_ehdr), abfd) != sizeof (x_ehdr))
{
if (bfd_get_error () != bfd_error_system_call)
- bfd_set_error (bfd_error_wrong_format);
- return NULL;
+ goto wrong;
+ else
+ goto fail;
}
/* Check the magic number. */
if (! elf_file_p (&x_ehdr))
goto wrong;
- /* FIXME: Check EI_VERSION here ! */
+ /* FIXME: Check EI_VERSION here ! */
/* Check the address size ("class"). */
if (x_ehdr.e_ident[EI_CLASS] != ELFCLASS)
@@ -112,11 +104,11 @@ elf_core_file_p (abfd)
/* Check the byteorder. */
switch (x_ehdr.e_ident[EI_DATA])
{
- case ELFDATA2MSB: /* Big-endian */
+ case ELFDATA2MSB: /* Big-endian. */
if (! bfd_big_endian (abfd))
goto wrong;
break;
- case ELFDATA2LSB: /* Little-endian */
+ case ELFDATA2LSB: /* Little-endian. */
if (! bfd_little_endian (abfd))
goto wrong;
break;
@@ -124,25 +116,13 @@ elf_core_file_p (abfd)
goto wrong;
}
+ if (!bfd_preserve_save (abfd, &preserve))
+ goto fail;
+
/* Give abfd an elf_obj_tdata. */
- amt = sizeof (struct elf_obj_tdata);
- new_tdata = (struct elf_obj_tdata *) bfd_zalloc (abfd, amt);
- if (new_tdata == NULL)
- return NULL;
- preserve.tdata = elf_tdata (abfd);
- elf_tdata (abfd) = new_tdata;
-
- /* Clear section information, since there might be a recognized bfd that
- we now check if we can replace, and we don't want to append to it. */
- preserve.sections = abfd->sections;
- preserve.section_tail = abfd->section_tail;
- preserve.section_count = abfd->section_count;
- preserve.section_htab = abfd->section_htab;
- abfd->sections = NULL;
- abfd->section_tail = &abfd->sections;
- abfd->section_count = 0;
- if (!bfd_hash_table_init (&abfd->section_htab, bfd_section_hash_newfunc))
+ if (! (*abfd->xvec->_bfd_set_format[bfd_core]) (abfd))
goto fail;
+ preserve.marker = elf_tdata (abfd);
/* Swap in the rest of the header, now that we have the byte order. */
i_ehdrp = elf_elfheader (abfd);
@@ -173,12 +153,16 @@ elf_core_file_p (abfd)
for (target_ptr = bfd_target_vector; *target_ptr != NULL; target_ptr++)
{
- struct elf_backend_data *back;
+ const struct elf_backend_data *back;
if ((*target_ptr)->flavour != bfd_target_elf_flavour)
continue;
- back = (struct elf_backend_data *) (*target_ptr)->backend_data;
- if (back->elf_machine_code == i_ehdrp->e_machine)
+ back = (const struct elf_backend_data *) (*target_ptr)->backend_data;
+ if (back->elf_machine_code == i_ehdrp->e_machine
+ || (back->elf_machine_alt1 != 0
+ && i_ehdrp->e_machine == back->elf_machine_alt1)
+ || (back->elf_machine_alt2 != 0
+ && i_ehdrp->e_machine == back->elf_machine_alt2))
{
/* target_ptr is an ELF backend which matches this
object file, so reject the generic ELF target. */
@@ -203,7 +187,7 @@ elf_core_file_p (abfd)
/* Allocate space for the program headers. */
amt = sizeof (*i_phdrp) * i_ehdrp->e_phnum;
- i_phdrp = (Elf_Internal_Phdr *) bfd_alloc (abfd, amt);
+ i_phdrp = bfd_alloc (abfd, amt);
if (!i_phdrp)
goto fail;
@@ -213,8 +197,8 @@ elf_core_file_p (abfd)
for (phindex = 0; phindex < i_ehdrp->e_phnum; ++phindex)
{
Elf_External_Phdr x_phdr;
- if (bfd_bread ((PTR) &x_phdr, (bfd_size_type) sizeof (x_phdr), abfd)
- != sizeof (x_phdr))
+
+ if (bfd_bread (&x_phdr, sizeof (x_phdr), abfd) != sizeof (x_phdr))
goto fail;
elf_swap_phdr_in (abfd, &x_phdr, i_phdrp + phindex);
@@ -232,23 +216,19 @@ elf_core_file_p (abfd)
/* Process each program header. */
for (phindex = 0; phindex < i_ehdrp->e_phnum; ++phindex)
- {
- if (! bfd_section_from_phdr (abfd, i_phdrp + phindex, (int) phindex))
- goto fail;
- }
+ if (! bfd_section_from_phdr (abfd, i_phdrp + phindex, (int) phindex))
+ goto fail;
/* Save the entry point from the ELF header. */
bfd_get_start_address (abfd) = i_ehdrp->e_entry;
/* Let the backend double check the format and override global
information. */
- if (ebd->elf_backend_object_p)
- {
- if (! (*ebd->elf_backend_object_p) (abfd))
- goto wrong;
- }
+ if (ebd->elf_backend_object_p
+ && (! (*ebd->elf_backend_object_p) (abfd)))
+ goto wrong;
- bfd_hash_table_free (&preserve.section_htab);
+ bfd_preserve_finish (abfd, &preserve);
return abfd->xvec;
wrong:
@@ -264,17 +244,7 @@ wrong:
bfd_set_error (bfd_error_wrong_format);
fail:
- abfd->arch_info = preserve.arch_info;
- if (new_tdata != NULL)
- {
- /* bfd_release frees all memory more recently bfd_alloc'd than
- its arg, as well as its arg. */
- bfd_release (abfd, new_tdata);
- elf_tdata (abfd) = preserve.tdata;
- abfd->section_htab = preserve.section_htab;
- abfd->sections = preserve.sections;
- abfd->section_tail = preserve.section_tail;
- abfd->section_count = preserve.section_count;
- }
+ if (preserve.marker != NULL)
+ bfd_preserve_restore (abfd, &preserve);
return NULL;
}
diff --git a/contrib/binutils/bfd/elflink.c b/contrib/binutils/bfd/elflink.c
index d6da588..6628db3 100644
--- a/contrib/binutils/bfd/elflink.c
+++ b/contrib/binutils/bfd/elflink.c
@@ -1,5 +1,5 @@
/* ELF linking support for BFD.
- Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
+ Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -24,22 +24,23 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "libbfd.h"
#define ARCH_SIZE 0
#include "elf-bfd.h"
+#include "safe-ctype.h"
+#include "libiberty.h"
-boolean
-_bfd_elf_create_got_section (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info;
+bfd_boolean
+_bfd_elf_create_got_section (bfd *abfd, struct bfd_link_info *info)
{
flagword flags;
- register asection *s;
+ asection *s;
struct elf_link_hash_entry *h;
struct bfd_link_hash_entry *bh;
- struct elf_backend_data *bed = get_elf_backend_data (abfd);
+ const struct elf_backend_data *bed = get_elf_backend_data (abfd);
int ptralign;
/* This function may be called more than once. */
- if (bfd_get_section_by_name (abfd, ".got") != NULL)
- return true;
+ s = bfd_get_section_by_name (abfd, ".got");
+ if (s != NULL && (s->flags & SEC_LINKER_CREATED) != 0)
+ return TRUE;
switch (bed->s->arch_size)
{
@@ -53,7 +54,7 @@ _bfd_elf_create_got_section (abfd, info)
default:
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
flags = (SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS | SEC_IN_MEMORY
@@ -63,7 +64,7 @@ _bfd_elf_create_got_section (abfd, info)
if (s == NULL
|| !bfd_set_section_flags (abfd, s, flags)
|| !bfd_set_section_alignment (abfd, s, ptralign))
- return false;
+ return FALSE;
if (bed->want_got_plt)
{
@@ -71,7 +72,7 @@ _bfd_elf_create_got_section (abfd, info)
if (s == NULL
|| !bfd_set_section_flags (abfd, s, flags)
|| !bfd_set_section_alignment (abfd, s, ptralign))
- return false;
+ return FALSE;
}
if (bed->want_got_sym)
@@ -83,16 +84,15 @@ _bfd_elf_create_got_section (abfd, info)
bh = NULL;
if (!(_bfd_generic_link_add_one_symbol
(info, abfd, "_GLOBAL_OFFSET_TABLE_", BSF_GLOBAL, s,
- bed->got_symbol_offset, (const char *) NULL, false,
- bed->collect, &bh)))
- return false;
+ bed->got_symbol_offset, NULL, FALSE, bed->collect, &bh)))
+ return FALSE;
h = (struct elf_link_hash_entry *) bh;
h->elf_link_hash_flags |= ELF_LINK_HASH_DEF_REGULAR;
h->type = STT_OBJECT;
- if (info->shared
- && ! _bfd_elf_link_record_dynamic_symbol (info, h))
- return false;
+ if (! info->executable
+ && ! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
elf_hash_table (info)->hgot = h;
}
@@ -100,36 +100,157 @@ _bfd_elf_create_got_section (abfd, info)
/* The first bit of the global offset table is the header. */
s->_raw_size += bed->got_header_size + bed->got_symbol_offset;
- return true;
+ return TRUE;
}
-/* Create dynamic sections when linking against a dynamic object. */
+/* Create some sections which will be filled in with dynamic linking
+ information. ABFD is an input file which requires dynamic sections
+ to be created. The dynamic sections take up virtual memory space
+ when the final executable is run, so we need to create them before
+ addresses are assigned to the output sections. We work out the
+ actual contents and size of these sections later. */
-boolean
-_bfd_elf_create_dynamic_sections (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info;
+bfd_boolean
+_bfd_elf_link_create_dynamic_sections (bfd *abfd, struct bfd_link_info *info)
{
- flagword flags, pltflags;
+ flagword flags;
register asection *s;
- struct elf_backend_data *bed = get_elf_backend_data (abfd);
- int ptralign;
+ struct elf_link_hash_entry *h;
+ struct bfd_link_hash_entry *bh;
+ const struct elf_backend_data *bed;
- switch (bed->s->arch_size)
+ if (! is_elf_hash_table (info->hash))
+ return FALSE;
+
+ if (elf_hash_table (info)->dynamic_sections_created)
+ return TRUE;
+
+ /* Make sure that all dynamic sections use the same input BFD. */
+ if (elf_hash_table (info)->dynobj == NULL)
+ elf_hash_table (info)->dynobj = abfd;
+ else
+ abfd = elf_hash_table (info)->dynobj;
+
+ /* Note that we set the SEC_IN_MEMORY flag for all of these
+ sections. */
+ flags = (SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS
+ | SEC_IN_MEMORY | SEC_LINKER_CREATED);
+
+ /* A dynamically linked executable has a .interp section, but a
+ shared library does not. */
+ if (info->executable)
{
- case 32:
- ptralign = 2;
- break;
+ s = bfd_make_section (abfd, ".interp");
+ if (s == NULL
+ || ! bfd_set_section_flags (abfd, s, flags | SEC_READONLY))
+ return FALSE;
+ }
- case 64:
- ptralign = 3;
- break;
+ if (! info->traditional_format)
+ {
+ s = bfd_make_section (abfd, ".eh_frame_hdr");
+ if (s == NULL
+ || ! bfd_set_section_flags (abfd, s, flags | SEC_READONLY)
+ || ! bfd_set_section_alignment (abfd, s, 2))
+ return FALSE;
+ elf_hash_table (info)->eh_info.hdr_sec = s;
+ }
- default:
- bfd_set_error (bfd_error_bad_value);
- return false;
+ bed = get_elf_backend_data (abfd);
+
+ /* Create sections to hold version informations. These are removed
+ if they are not needed. */
+ s = bfd_make_section (abfd, ".gnu.version_d");
+ if (s == NULL
+ || ! bfd_set_section_flags (abfd, s, flags | SEC_READONLY)
+ || ! bfd_set_section_alignment (abfd, s, bed->s->log_file_align))
+ return FALSE;
+
+ s = bfd_make_section (abfd, ".gnu.version");
+ if (s == NULL
+ || ! bfd_set_section_flags (abfd, s, flags | SEC_READONLY)
+ || ! bfd_set_section_alignment (abfd, s, 1))
+ return FALSE;
+
+ s = bfd_make_section (abfd, ".gnu.version_r");
+ if (s == NULL
+ || ! bfd_set_section_flags (abfd, s, flags | SEC_READONLY)
+ || ! bfd_set_section_alignment (abfd, s, bed->s->log_file_align))
+ return FALSE;
+
+ s = bfd_make_section (abfd, ".dynsym");
+ if (s == NULL
+ || ! bfd_set_section_flags (abfd, s, flags | SEC_READONLY)
+ || ! bfd_set_section_alignment (abfd, s, bed->s->log_file_align))
+ return FALSE;
+
+ s = bfd_make_section (abfd, ".dynstr");
+ if (s == NULL
+ || ! bfd_set_section_flags (abfd, s, flags | SEC_READONLY))
+ return FALSE;
+
+ /* Create a strtab to hold the dynamic symbol names. */
+ if (elf_hash_table (info)->dynstr == NULL)
+ {
+ elf_hash_table (info)->dynstr = _bfd_elf_strtab_init ();
+ if (elf_hash_table (info)->dynstr == NULL)
+ return FALSE;
}
+ s = bfd_make_section (abfd, ".dynamic");
+ if (s == NULL
+ || ! bfd_set_section_flags (abfd, s, flags)
+ || ! bfd_set_section_alignment (abfd, s, bed->s->log_file_align))
+ return FALSE;
+
+ /* The special symbol _DYNAMIC is always set to the start of the
+ .dynamic section. This call occurs before we have processed the
+ symbols for any dynamic object, so we don't have to worry about
+ overriding a dynamic definition. We could set _DYNAMIC in a
+ linker script, but we only want to define it if we are, in fact,
+ creating a .dynamic section. We don't want to define it if there
+ is no .dynamic section, since on some ELF platforms the start up
+ code examines it to decide how to initialize the process. */
+ bh = NULL;
+ if (! (_bfd_generic_link_add_one_symbol
+ (info, abfd, "_DYNAMIC", BSF_GLOBAL, s, 0, NULL, FALSE,
+ get_elf_backend_data (abfd)->collect, &bh)))
+ return FALSE;
+ h = (struct elf_link_hash_entry *) bh;
+ h->elf_link_hash_flags |= ELF_LINK_HASH_DEF_REGULAR;
+ h->type = STT_OBJECT;
+
+ if (! info->executable
+ && ! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
+
+ s = bfd_make_section (abfd, ".hash");
+ if (s == NULL
+ || ! bfd_set_section_flags (abfd, s, flags | SEC_READONLY)
+ || ! bfd_set_section_alignment (abfd, s, bed->s->log_file_align))
+ return FALSE;
+ elf_section_data (s)->this_hdr.sh_entsize = bed->s->sizeof_hash_entry;
+
+ /* Let the backend create the rest of the sections. This lets the
+ backend set the right flags. The backend will normally create
+ the .got and .plt sections. */
+ if (! (*bed->elf_backend_create_dynamic_sections) (abfd, info))
+ return FALSE;
+
+ elf_hash_table (info)->dynamic_sections_created = TRUE;
+
+ return TRUE;
+}
+
+/* Create dynamic sections when linking against a dynamic object. */
+
+bfd_boolean
+_bfd_elf_create_dynamic_sections (bfd *abfd, struct bfd_link_info *info)
+{
+ flagword flags, pltflags;
+ asection *s;
+ const struct elf_backend_data *bed = get_elf_backend_data (abfd);
+
/* We need to create .plt, .rel[a].plt, .got, .got.plt, .dynbss, and
.rel[a].bss sections. */
@@ -147,7 +268,7 @@ _bfd_elf_create_dynamic_sections (abfd, info)
if (s == NULL
|| ! bfd_set_section_flags (abfd, s, pltflags)
|| ! bfd_set_section_alignment (abfd, s, bed->plt_alignment))
- return false;
+ return FALSE;
if (bed->want_plt_sym)
{
@@ -157,28 +278,27 @@ _bfd_elf_create_dynamic_sections (abfd, info)
struct bfd_link_hash_entry *bh = NULL;
if (! (_bfd_generic_link_add_one_symbol
- (info, abfd, "_PROCEDURE_LINKAGE_TABLE_", BSF_GLOBAL, s,
- (bfd_vma) 0, (const char *) NULL, false,
- get_elf_backend_data (abfd)->collect, &bh)))
- return false;
+ (info, abfd, "_PROCEDURE_LINKAGE_TABLE_", BSF_GLOBAL, s, 0, NULL,
+ FALSE, get_elf_backend_data (abfd)->collect, &bh)))
+ return FALSE;
h = (struct elf_link_hash_entry *) bh;
h->elf_link_hash_flags |= ELF_LINK_HASH_DEF_REGULAR;
h->type = STT_OBJECT;
- if (info->shared
- && ! _bfd_elf_link_record_dynamic_symbol (info, h))
- return false;
+ if (! info->executable
+ && ! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
}
s = bfd_make_section (abfd,
bed->default_use_rela_p ? ".rela.plt" : ".rel.plt");
if (s == NULL
|| ! bfd_set_section_flags (abfd, s, flags | SEC_READONLY)
- || ! bfd_set_section_alignment (abfd, s, ptralign))
- return false;
+ || ! bfd_set_section_alignment (abfd, s, bed->s->log_file_align))
+ return FALSE;
if (! _bfd_elf_create_got_section (abfd, info))
- return false;
+ return FALSE;
if (bed->want_dynbss)
{
@@ -190,8 +310,8 @@ _bfd_elf_create_dynamic_sections (abfd, info)
section into the .bss section of the final image. */
s = bfd_make_section (abfd, ".dynbss");
if (s == NULL
- || ! bfd_set_section_flags (abfd, s, SEC_ALLOC))
- return false;
+ || ! bfd_set_section_flags (abfd, s, SEC_ALLOC | SEC_LINKER_CREATED))
+ return FALSE;
/* The .rel[a].bss section holds copy relocs. This section is not
normally needed. We need to create it here, though, so that the
@@ -211,12 +331,12 @@ _bfd_elf_create_dynamic_sections (abfd, info)
? ".rela.bss" : ".rel.bss"));
if (s == NULL
|| ! bfd_set_section_flags (abfd, s, flags | SEC_READONLY)
- || ! bfd_set_section_alignment (abfd, s, ptralign))
- return false;
+ || ! bfd_set_section_alignment (abfd, s, bed->s->log_file_align))
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
/* Record a new dynamic symbol. We record the dynamic symbols as we
@@ -227,17 +347,15 @@ _bfd_elf_create_dynamic_sections (abfd, info)
symbol should be in the dynamic symbol table, but only if there is
one. */
-boolean
-_bfd_elf_link_record_dynamic_symbol (info, h)
- struct bfd_link_info *info;
- struct elf_link_hash_entry *h;
+bfd_boolean
+bfd_elf_link_record_dynamic_symbol (struct bfd_link_info *info,
+ struct elf_link_hash_entry *h)
{
if (h->dynindx == -1)
{
struct elf_strtab_hash *dynstr;
- char *p, *alc;
+ char *p;
const char *name;
- boolean copy;
bfd_size_type indx;
/* XXX: The ABI draft says the linker must turn hidden and
@@ -252,7 +370,7 @@ _bfd_elf_link_record_dynamic_symbol (info, h)
&& h->root.type != bfd_link_hash_undefweak)
{
h->elf_link_hash_flags |= ELF_LINK_FORCED_LOCAL;
- return true;
+ return TRUE;
}
default:
@@ -268,42 +386,102 @@ _bfd_elf_link_record_dynamic_symbol (info, h)
/* Create a strtab to hold the dynamic symbol names. */
elf_hash_table (info)->dynstr = dynstr = _bfd_elf_strtab_init ();
if (dynstr == NULL)
- return false;
+ return FALSE;
}
/* We don't put any version information in the dynamic string
- table. */
+ table. */
name = h->root.root.string;
p = strchr (name, ELF_VER_CHR);
- if (p == NULL)
- {
- alc = NULL;
- copy = false;
- }
- else
- {
- size_t len = p - name + 1;
+ if (p != NULL)
+ /* We know that the p points into writable memory. In fact,
+ there are only a few symbols that have read-only names, being
+ those like _GLOBAL_OFFSET_TABLE_ that are created specially
+ by the backends. Most symbols will have names pointing into
+ an ELF string table read from a file, or to objalloc memory. */
+ *p = 0;
- alc = bfd_malloc ((bfd_size_type) len);
- if (alc == NULL)
- return false;
- memcpy (alc, name, len - 1);
- alc[len - 1] = '\0';
- name = alc;
- copy = true;
- }
-
- indx = _bfd_elf_strtab_add (dynstr, name, copy);
+ indx = _bfd_elf_strtab_add (dynstr, name, p != NULL);
- if (alc != NULL)
- free (alc);
+ if (p != NULL)
+ *p = ELF_VER_CHR;
if (indx == (bfd_size_type) -1)
- return false;
+ return FALSE;
h->dynstr_index = indx;
}
- return true;
+ return TRUE;
+}
+
+/* Record an assignment to a symbol made by a linker script. We need
+ this in case some dynamic object refers to this symbol. */
+
+bfd_boolean
+bfd_elf_record_link_assignment (bfd *output_bfd ATTRIBUTE_UNUSED,
+ struct bfd_link_info *info,
+ const char *name,
+ bfd_boolean provide)
+{
+ struct elf_link_hash_entry *h;
+
+ if (!is_elf_hash_table (info->hash))
+ return TRUE;
+
+ h = elf_link_hash_lookup (elf_hash_table (info), name, TRUE, TRUE, FALSE);
+ if (h == NULL)
+ return FALSE;
+
+ /* Since we're defining the symbol, don't let it seem to have not
+ been defined. record_dynamic_symbol and size_dynamic_sections
+ may depend on this. */
+ if (h->root.type == bfd_link_hash_undefweak
+ || h->root.type == bfd_link_hash_undefined)
+ h->root.type = bfd_link_hash_new;
+
+ if (h->root.type == bfd_link_hash_new)
+ h->elf_link_hash_flags &= ~ELF_LINK_NON_ELF;
+
+ /* If this symbol is being provided by the linker script, and it is
+ currently defined by a dynamic object, but not by a regular
+ object, then mark it as undefined so that the generic linker will
+ force the correct value. */
+ if (provide
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
+ h->root.type = bfd_link_hash_undefined;
+
+ /* If this symbol is not being provided by the linker script, and it is
+ currently defined by a dynamic object, but not by a regular object,
+ then clear out any version information because the symbol will not be
+ associated with the dynamic object any more. */
+ if (!provide
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
+ h->verinfo.verdef = NULL;
+
+ h->elf_link_hash_flags |= ELF_LINK_HASH_DEF_REGULAR;
+
+ if (((h->elf_link_hash_flags & (ELF_LINK_HASH_DEF_DYNAMIC
+ | ELF_LINK_HASH_REF_DYNAMIC)) != 0
+ || info->shared)
+ && h->dynindx == -1)
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
+
+ /* If this is a weak defined symbol, and we know a corresponding
+ real symbol from the same dynamic object, make sure the real
+ symbol is also made into a dynamic symbol. */
+ if (h->weakdef != NULL
+ && h->weakdef->dynindx == -1)
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, h->weakdef))
+ return FALSE;
+ }
+ }
+
+ return TRUE;
}
/* Record a new local dynamic symbol. Returns 0 on failure, 1 on
@@ -311,10 +489,9 @@ _bfd_elf_link_record_dynamic_symbol (info, h)
in a discarded section, eg. a discarded link-once section symbol. */
int
-elf_link_record_local_dynamic_symbol (info, input_bfd, input_indx)
- struct bfd_link_info *info;
- bfd *input_bfd;
- long input_indx;
+bfd_elf_link_record_local_dynamic_symbol (struct bfd_link_info *info,
+ bfd *input_bfd,
+ long input_indx)
{
bfd_size_type amt;
struct elf_link_local_dynamic_entry *entry;
@@ -325,7 +502,7 @@ elf_link_record_local_dynamic_symbol (info, input_bfd, input_indx)
Elf_External_Sym_Shndx eshndx;
char esym[sizeof (Elf64_External_Sym)];
- if (! is_elf_hash_table (info))
+ if (! is_elf_hash_table (info->hash))
return 0;
/* See if the entry exists already. */
@@ -334,14 +511,13 @@ elf_link_record_local_dynamic_symbol (info, input_bfd, input_indx)
return 1;
amt = sizeof (*entry);
- entry = (struct elf_link_local_dynamic_entry *) bfd_alloc (input_bfd, amt);
+ entry = bfd_alloc (input_bfd, amt);
if (entry == NULL)
return 0;
/* Go find the symbol, so that we can find it's name. */
if (!bfd_elf_get_elf_syms (input_bfd, &elf_tdata (input_bfd)->symtab_hdr,
- (size_t) 1, (size_t) input_indx,
- &entry->isym, esym, &eshndx))
+ 1, input_indx, &entry->isym, esym, &eshndx))
{
bfd_release (input_bfd, entry);
return 0;
@@ -376,7 +552,7 @@ elf_link_record_local_dynamic_symbol (info, input_bfd, input_indx)
return 0;
}
- dynstr_index = _bfd_elf_strtab_add (dynstr, name, false);
+ dynstr_index = _bfd_elf_strtab_add (dynstr, name, FALSE);
if (dynstr_index == (unsigned long) -1)
return 0;
entry->isym.st_name = dynstr_index;
@@ -401,10 +577,9 @@ elf_link_record_local_dynamic_symbol (info, input_bfd, input_indx)
/* Return the dynindex of a local dynamic symbol. */
long
-_bfd_elf_link_lookup_local_dynindx (info, input_bfd, input_indx)
- struct bfd_link_info *info;
- bfd *input_bfd;
- long input_indx;
+_bfd_elf_link_lookup_local_dynindx (struct bfd_link_info *info,
+ bfd *input_bfd,
+ long input_indx)
{
struct elf_link_local_dynamic_entry *e;
@@ -418,15 +593,11 @@ _bfd_elf_link_lookup_local_dynindx (info, input_bfd, input_indx)
them are removed because they are marked as local. This is called
via elf_link_hash_traverse. */
-static boolean elf_link_renumber_hash_table_dynsyms
- PARAMS ((struct elf_link_hash_entry *, PTR));
-
-static boolean
-elf_link_renumber_hash_table_dynsyms (h, data)
- struct elf_link_hash_entry *h;
- PTR data;
+static bfd_boolean
+elf_link_renumber_hash_table_dynsyms (struct elf_link_hash_entry *h,
+ void *data)
{
- size_t *count = (size_t *) data;
+ size_t *count = data;
if (h->root.type == bfd_link_hash_warning)
h = (struct elf_link_hash_entry *) h->root.u.i.link;
@@ -434,7 +605,7 @@ elf_link_renumber_hash_table_dynsyms (h, data)
if (h->dynindx != -1)
h->dynindx = ++(*count);
- return true;
+ return TRUE;
}
/* Assign dynsym indices. In a shared library we generate a section
@@ -443,9 +614,7 @@ elf_link_renumber_hash_table_dynsyms (h, data)
the global symbols. */
unsigned long
-_bfd_elf_link_renumber_dynsyms (output_bfd, info)
- bfd *output_bfd;
- struct bfd_link_info *info;
+_bfd_elf_link_renumber_dynsyms (bfd *output_bfd, struct bfd_link_info *info)
{
unsigned long dynsymcount = 0;
@@ -476,175 +645,8264 @@ _bfd_elf_link_renumber_dynsyms (output_bfd, info)
return elf_hash_table (info)->dynsymcount = dynsymcount;
}
+
+/* This function is called when we want to define a new symbol. It
+ handles the various cases which arise when we find a definition in
+ a dynamic object, or when there is already a definition in a
+ dynamic object. The new symbol is described by NAME, SYM, PSEC,
+ and PVALUE. We set SYM_HASH to the hash table entry. We set
+ OVERRIDE if the old symbol is overriding a new definition. We set
+ TYPE_CHANGE_OK if it is OK for the type to change. We set
+ SIZE_CHANGE_OK if it is OK for the size to change. By OK to
+ change, we mean that we shouldn't warn if the type or size does
+ change. */
+
+bfd_boolean
+_bfd_elf_merge_symbol (bfd *abfd,
+ struct bfd_link_info *info,
+ const char *name,
+ Elf_Internal_Sym *sym,
+ asection **psec,
+ bfd_vma *pvalue,
+ struct elf_link_hash_entry **sym_hash,
+ bfd_boolean *skip,
+ bfd_boolean *override,
+ bfd_boolean *type_change_ok,
+ bfd_boolean *size_change_ok)
+{
+ asection *sec;
+ struct elf_link_hash_entry *h;
+ struct elf_link_hash_entry *flip;
+ int bind;
+ bfd *oldbfd;
+ bfd_boolean newdyn, olddyn, olddef, newdef, newdyncommon, olddyncommon;
+ bfd_boolean newweak, oldweak;
+
+ *skip = FALSE;
+ *override = FALSE;
+
+ sec = *psec;
+ bind = ELF_ST_BIND (sym->st_info);
+
+ if (! bfd_is_und_section (sec))
+ h = elf_link_hash_lookup (elf_hash_table (info), name, TRUE, FALSE, FALSE);
+ else
+ h = ((struct elf_link_hash_entry *)
+ bfd_wrapped_link_hash_lookup (abfd, info, name, TRUE, FALSE, FALSE));
+ if (h == NULL)
+ return FALSE;
+ *sym_hash = h;
+
+ /* This code is for coping with dynamic objects, and is only useful
+ if we are doing an ELF link. */
+ if (info->hash->creator != abfd->xvec)
+ return TRUE;
+
+ /* For merging, we only care about real symbols. */
+
+ while (h->root.type == bfd_link_hash_indirect
+ || h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ /* If we just created the symbol, mark it as being an ELF symbol.
+ Other than that, there is nothing to do--there is no merge issue
+ with a newly defined symbol--so we just return. */
+
+ if (h->root.type == bfd_link_hash_new)
+ {
+ h->elf_link_hash_flags &=~ ELF_LINK_NON_ELF;
+ return TRUE;
+ }
+
+ /* OLDBFD is a BFD associated with the existing symbol. */
+
+ switch (h->root.type)
+ {
+ default:
+ oldbfd = NULL;
+ break;
+
+ case bfd_link_hash_undefined:
+ case bfd_link_hash_undefweak:
+ oldbfd = h->root.u.undef.abfd;
+ break;
+
+ case bfd_link_hash_defined:
+ case bfd_link_hash_defweak:
+ oldbfd = h->root.u.def.section->owner;
+ break;
+
+ case bfd_link_hash_common:
+ oldbfd = h->root.u.c.p->section->owner;
+ break;
+ }
+
+ /* In cases involving weak versioned symbols, we may wind up trying
+ to merge a symbol with itself. Catch that here, to avoid the
+ confusion that results if we try to override a symbol with
+ itself. The additional tests catch cases like
+ _GLOBAL_OFFSET_TABLE_, which are regular symbols defined in a
+ dynamic object, which we do want to handle here. */
+ if (abfd == oldbfd
+ && ((abfd->flags & DYNAMIC) == 0
+ || (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0))
+ return TRUE;
+
+ /* NEWDYN and OLDDYN indicate whether the new or old symbol,
+ respectively, is from a dynamic object. */
+
+ if ((abfd->flags & DYNAMIC) != 0)
+ newdyn = TRUE;
+ else
+ newdyn = FALSE;
+
+ if (oldbfd != NULL)
+ olddyn = (oldbfd->flags & DYNAMIC) != 0;
+ else
+ {
+ asection *hsec;
+
+ /* This code handles the special SHN_MIPS_{TEXT,DATA} section
+ indices used by MIPS ELF. */
+ switch (h->root.type)
+ {
+ default:
+ hsec = NULL;
+ break;
+
+ case bfd_link_hash_defined:
+ case bfd_link_hash_defweak:
+ hsec = h->root.u.def.section;
+ break;
+
+ case bfd_link_hash_common:
+ hsec = h->root.u.c.p->section;
+ break;
+ }
+
+ if (hsec == NULL)
+ olddyn = FALSE;
+ else
+ olddyn = (hsec->symbol->flags & BSF_DYNAMIC) != 0;
+ }
+
+ /* NEWDEF and OLDDEF indicate whether the new or old symbol,
+ respectively, appear to be a definition rather than reference. */
+
+ if (bfd_is_und_section (sec) || bfd_is_com_section (sec))
+ newdef = FALSE;
+ else
+ newdef = TRUE;
+
+ if (h->root.type == bfd_link_hash_undefined
+ || h->root.type == bfd_link_hash_undefweak
+ || h->root.type == bfd_link_hash_common)
+ olddef = FALSE;
+ else
+ olddef = TRUE;
+
+ /* We need to remember if a symbol has a definition in a dynamic
+ object or is weak in all dynamic objects. Internal and hidden
+ visibility will make it unavailable to dynamic objects. */
+ if (newdyn && (h->elf_link_hash_flags & ELF_LINK_DYNAMIC_DEF) == 0)
+ {
+ if (!bfd_is_und_section (sec))
+ h->elf_link_hash_flags |= ELF_LINK_DYNAMIC_DEF;
+ else
+ {
+ /* Check if this symbol is weak in all dynamic objects. If it
+ is the first time we see it in a dynamic object, we mark
+ if it is weak. Otherwise, we clear it. */
+ if ((h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) == 0)
+ {
+ if (bind == STB_WEAK)
+ h->elf_link_hash_flags |= ELF_LINK_DYNAMIC_WEAK;
+ }
+ else if (bind != STB_WEAK)
+ h->elf_link_hash_flags &= ~ELF_LINK_DYNAMIC_WEAK;
+ }
+ }
+
+ /* If the old symbol has non-default visibility, we ignore the new
+ definition from a dynamic object. */
+ if (newdyn
+ && ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+ && !bfd_is_und_section (sec))
+ {
+ *skip = TRUE;
+ /* Make sure this symbol is dynamic. */
+ h->elf_link_hash_flags |= ELF_LINK_HASH_REF_DYNAMIC;
+ /* A protected symbol has external availability. Make sure it is
+ recorded as dynamic.
+
+ FIXME: Should we check type and size for protected symbol? */
+ if (ELF_ST_VISIBILITY (h->other) == STV_PROTECTED)
+ return bfd_elf_link_record_dynamic_symbol (info, h);
+ else
+ return TRUE;
+ }
+ else if (!newdyn
+ && ELF_ST_VISIBILITY (sym->st_other) != STV_DEFAULT
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0)
+ {
+ /* If the new symbol with non-default visibility comes from a
+ relocatable file and the old definition comes from a dynamic
+ object, we remove the old definition. */
+ if ((*sym_hash)->root.type == bfd_link_hash_indirect)
+ h = *sym_hash;
+
+ if ((h->root.und_next || info->hash->undefs_tail == &h->root)
+ && bfd_is_und_section (sec))
+ {
+ /* If the new symbol is undefined and the old symbol was
+ also undefined before, we need to make sure
+ _bfd_generic_link_add_one_symbol doesn't mess
+ up the linker hash table undefs list. Since the old
+ definition came from a dynamic object, it is still on the
+ undefs list. */
+ h->root.type = bfd_link_hash_undefined;
+ /* FIXME: What if the new symbol is weak undefined? */
+ h->root.u.undef.abfd = abfd;
+ }
+ else
+ {
+ h->root.type = bfd_link_hash_new;
+ h->root.u.undef.abfd = NULL;
+ }
+
+ if (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC)
+ {
+ h->elf_link_hash_flags &= ~ELF_LINK_HASH_DEF_DYNAMIC;
+ h->elf_link_hash_flags |= (ELF_LINK_HASH_REF_DYNAMIC
+ | ELF_LINK_DYNAMIC_DEF);
+ }
+ /* FIXME: Should we check type and size for protected symbol? */
+ h->size = 0;
+ h->type = 0;
+ return TRUE;
+ }
+
+ /* Differentiate strong and weak symbols. */
+ newweak = bind == STB_WEAK;
+ oldweak = (h->root.type == bfd_link_hash_defweak
+ || h->root.type == bfd_link_hash_undefweak);
+
+ /* If a new weak symbol definition comes from a regular file and the
+ old symbol comes from a dynamic library, we treat the new one as
+ strong. Similarly, an old weak symbol definition from a regular
+ file is treated as strong when the new symbol comes from a dynamic
+ library. Further, an old weak symbol from a dynamic library is
+ treated as strong if the new symbol is from a dynamic library.
+ This reflects the way glibc's ld.so works.
+
+ Do this before setting *type_change_ok or *size_change_ok so that
+ we warn properly when dynamic library symbols are overridden. */
+
+ if (newdef && !newdyn && olddyn)
+ newweak = FALSE;
+ if (olddef && newdyn)
+ oldweak = FALSE;
+
+ /* It's OK to change the type if either the existing symbol or the
+ new symbol is weak. A type change is also OK if the old symbol
+ is undefined and the new symbol is defined. */
+
+ if (oldweak
+ || newweak
+ || (newdef
+ && h->root.type == bfd_link_hash_undefined))
+ *type_change_ok = TRUE;
+
+ /* It's OK to change the size if either the existing symbol or the
+ new symbol is weak, or if the old symbol is undefined. */
+
+ if (*type_change_ok
+ || h->root.type == bfd_link_hash_undefined)
+ *size_change_ok = TRUE;
+
+ /* NEWDYNCOMMON and OLDDYNCOMMON indicate whether the new or old
+ symbol, respectively, appears to be a common symbol in a dynamic
+ object. If a symbol appears in an uninitialized section, and is
+ not weak, and is not a function, then it may be a common symbol
+ which was resolved when the dynamic object was created. We want
+ to treat such symbols specially, because they raise special
+ considerations when setting the symbol size: if the symbol
+ appears as a common symbol in a regular object, and the size in
+ the regular object is larger, we must make sure that we use the
+ larger size. This problematic case can always be avoided in C,
+ but it must be handled correctly when using Fortran shared
+ libraries.
+
+ Note that if NEWDYNCOMMON is set, NEWDEF will be set, and
+ likewise for OLDDYNCOMMON and OLDDEF.
+
+ Note that this test is just a heuristic, and that it is quite
+ possible to have an uninitialized symbol in a shared object which
+ is really a definition, rather than a common symbol. This could
+ lead to some minor confusion when the symbol really is a common
+ symbol in some regular object. However, I think it will be
+ harmless. */
+
+ if (newdyn
+ && newdef
+ && !newweak
+ && (sec->flags & SEC_ALLOC) != 0
+ && (sec->flags & SEC_LOAD) == 0
+ && sym->st_size > 0
+ && ELF_ST_TYPE (sym->st_info) != STT_FUNC)
+ newdyncommon = TRUE;
+ else
+ newdyncommon = FALSE;
+
+ if (olddyn
+ && olddef
+ && h->root.type == bfd_link_hash_defined
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0
+ && (h->root.u.def.section->flags & SEC_ALLOC) != 0
+ && (h->root.u.def.section->flags & SEC_LOAD) == 0
+ && h->size > 0
+ && h->type != STT_FUNC)
+ olddyncommon = TRUE;
+ else
+ olddyncommon = FALSE;
+
+ /* If both the old and the new symbols look like common symbols in a
+ dynamic object, set the size of the symbol to the larger of the
+ two. */
+
+ if (olddyncommon
+ && newdyncommon
+ && sym->st_size != h->size)
+ {
+ /* Since we think we have two common symbols, issue a multiple
+ common warning if desired. Note that we only warn if the
+ size is different. If the size is the same, we simply let
+ the old symbol override the new one as normally happens with
+ symbols defined in dynamic objects. */
+
+ if (! ((*info->callbacks->multiple_common)
+ (info, h->root.root.string, oldbfd, bfd_link_hash_common,
+ h->size, abfd, bfd_link_hash_common, sym->st_size)))
+ return FALSE;
+
+ if (sym->st_size > h->size)
+ h->size = sym->st_size;
+
+ *size_change_ok = TRUE;
+ }
+
+ /* If we are looking at a dynamic object, and we have found a
+ definition, we need to see if the symbol was already defined by
+ some other object. If so, we want to use the existing
+ definition, and we do not want to report a multiple symbol
+ definition error; we do this by clobbering *PSEC to be
+ bfd_und_section_ptr.
+
+ We treat a common symbol as a definition if the symbol in the
+ shared library is a function, since common symbols always
+ represent variables; this can cause confusion in principle, but
+ any such confusion would seem to indicate an erroneous program or
+ shared library. We also permit a common symbol in a regular
+ object to override a weak symbol in a shared object. */
+
+ if (newdyn
+ && newdef
+ && (olddef
+ || (h->root.type == bfd_link_hash_common
+ && (newweak
+ || ELF_ST_TYPE (sym->st_info) == STT_FUNC))))
+ {
+ *override = TRUE;
+ newdef = FALSE;
+ newdyncommon = FALSE;
+
+ *psec = sec = bfd_und_section_ptr;
+ *size_change_ok = TRUE;
+
+ /* If we get here when the old symbol is a common symbol, then
+ we are explicitly letting it override a weak symbol or
+ function in a dynamic object, and we don't want to warn about
+ a type change. If the old symbol is a defined symbol, a type
+ change warning may still be appropriate. */
+
+ if (h->root.type == bfd_link_hash_common)
+ *type_change_ok = TRUE;
+ }
+
+ /* Handle the special case of an old common symbol merging with a
+ new symbol which looks like a common symbol in a shared object.
+ We change *PSEC and *PVALUE to make the new symbol look like a
+ common symbol, and let _bfd_generic_link_add_one_symbol will do
+ the right thing. */
+
+ if (newdyncommon
+ && h->root.type == bfd_link_hash_common)
+ {
+ *override = TRUE;
+ newdef = FALSE;
+ newdyncommon = FALSE;
+ *pvalue = sym->st_size;
+ *psec = sec = bfd_com_section_ptr;
+ *size_change_ok = TRUE;
+ }
+
+ /* If the old symbol is from a dynamic object, and the new symbol is
+ a definition which is not from a dynamic object, then the new
+ symbol overrides the old symbol. Symbols from regular files
+ always take precedence over symbols from dynamic objects, even if
+ they are defined after the dynamic object in the link.
+
+ As above, we again permit a common symbol in a regular object to
+ override a definition in a shared object if the shared object
+ symbol is a function or is weak. */
+
+ flip = NULL;
+ if (! newdyn
+ && (newdef
+ || (bfd_is_com_section (sec)
+ && (oldweak
+ || h->type == STT_FUNC)))
+ && olddyn
+ && olddef
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0)
+ {
+ /* Change the hash table entry to undefined, and let
+ _bfd_generic_link_add_one_symbol do the right thing with the
+ new definition. */
+
+ h->root.type = bfd_link_hash_undefined;
+ h->root.u.undef.abfd = h->root.u.def.section->owner;
+ *size_change_ok = TRUE;
+
+ olddef = FALSE;
+ olddyncommon = FALSE;
+
+ /* We again permit a type change when a common symbol may be
+ overriding a function. */
+
+ if (bfd_is_com_section (sec))
+ *type_change_ok = TRUE;
+
+ if ((*sym_hash)->root.type == bfd_link_hash_indirect)
+ flip = *sym_hash;
+ else
+ /* This union may have been set to be non-NULL when this symbol
+ was seen in a dynamic object. We must force the union to be
+ NULL, so that it is correct for a regular symbol. */
+ h->verinfo.vertree = NULL;
+ }
+
+ /* Handle the special case of a new common symbol merging with an
+ old symbol that looks like it might be a common symbol defined in
+ a shared object. Note that we have already handled the case in
+ which a new common symbol should simply override the definition
+ in the shared library. */
+
+ if (! newdyn
+ && bfd_is_com_section (sec)
+ && olddyncommon)
+ {
+ /* It would be best if we could set the hash table entry to a
+ common symbol, but we don't know what to use for the section
+ or the alignment. */
+ if (! ((*info->callbacks->multiple_common)
+ (info, h->root.root.string, oldbfd, bfd_link_hash_common,
+ h->size, abfd, bfd_link_hash_common, sym->st_size)))
+ return FALSE;
+
+ /* If the presumed common symbol in the dynamic object is
+ larger, pretend that the new symbol has its size. */
+
+ if (h->size > *pvalue)
+ *pvalue = h->size;
+
+ /* FIXME: We no longer know the alignment required by the symbol
+ in the dynamic object, so we just wind up using the one from
+ the regular object. */
+
+ olddef = FALSE;
+ olddyncommon = FALSE;
+
+ h->root.type = bfd_link_hash_undefined;
+ h->root.u.undef.abfd = h->root.u.def.section->owner;
+
+ *size_change_ok = TRUE;
+ *type_change_ok = TRUE;
+
+ if ((*sym_hash)->root.type == bfd_link_hash_indirect)
+ flip = *sym_hash;
+ else
+ h->verinfo.vertree = NULL;
+ }
+
+ if (flip != NULL)
+ {
+ /* Handle the case where we had a versioned symbol in a dynamic
+ library and now find a definition in a normal object. In this
+ case, we make the versioned symbol point to the normal one. */
+ const struct elf_backend_data *bed = get_elf_backend_data (abfd);
+ flip->root.type = h->root.type;
+ h->root.type = bfd_link_hash_indirect;
+ h->root.u.i.link = (struct bfd_link_hash_entry *) flip;
+ (*bed->elf_backend_copy_indirect_symbol) (bed, flip, h);
+ flip->root.u.undef.abfd = h->root.u.undef.abfd;
+ if (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC)
+ {
+ h->elf_link_hash_flags &= ~ELF_LINK_HASH_DEF_DYNAMIC;
+ flip->elf_link_hash_flags |= ELF_LINK_HASH_REF_DYNAMIC;
+ }
+ }
+
+ return TRUE;
+}
+
+/* This function is called to create an indirect symbol from the
+ default for the symbol with the default version if needed. The
+ symbol is described by H, NAME, SYM, PSEC, VALUE, and OVERRIDE. We
+ set DYNSYM if the new indirect symbol is dynamic. */
+
+bfd_boolean
+_bfd_elf_add_default_symbol (bfd *abfd,
+ struct bfd_link_info *info,
+ struct elf_link_hash_entry *h,
+ const char *name,
+ Elf_Internal_Sym *sym,
+ asection **psec,
+ bfd_vma *value,
+ bfd_boolean *dynsym,
+ bfd_boolean override)
+{
+ bfd_boolean type_change_ok;
+ bfd_boolean size_change_ok;
+ bfd_boolean skip;
+ char *shortname;
+ struct elf_link_hash_entry *hi;
+ struct bfd_link_hash_entry *bh;
+ const struct elf_backend_data *bed;
+ bfd_boolean collect;
+ bfd_boolean dynamic;
+ char *p;
+ size_t len, shortlen;
+ asection *sec;
+
+ /* If this symbol has a version, and it is the default version, we
+ create an indirect symbol from the default name to the fully
+ decorated name. This will cause external references which do not
+ specify a version to be bound to this version of the symbol. */
+ p = strchr (name, ELF_VER_CHR);
+ if (p == NULL || p[1] != ELF_VER_CHR)
+ return TRUE;
+
+ if (override)
+ {
+ /* We are overridden by an old definition. We need to check if we
+ need to create the indirect symbol from the default name. */
+ hi = elf_link_hash_lookup (elf_hash_table (info), name, TRUE,
+ FALSE, FALSE);
+ BFD_ASSERT (hi != NULL);
+ if (hi == h)
+ return TRUE;
+ while (hi->root.type == bfd_link_hash_indirect
+ || hi->root.type == bfd_link_hash_warning)
+ {
+ hi = (struct elf_link_hash_entry *) hi->root.u.i.link;
+ if (hi == h)
+ return TRUE;
+ }
+ }
+
+ bed = get_elf_backend_data (abfd);
+ collect = bed->collect;
+ dynamic = (abfd->flags & DYNAMIC) != 0;
+
+ shortlen = p - name;
+ shortname = bfd_hash_allocate (&info->hash->table, shortlen + 1);
+ if (shortname == NULL)
+ return FALSE;
+ memcpy (shortname, name, shortlen);
+ shortname[shortlen] = '\0';
+
+ /* We are going to create a new symbol. Merge it with any existing
+ symbol with this name. For the purposes of the merge, act as
+ though we were defining the symbol we just defined, although we
+ actually going to define an indirect symbol. */
+ type_change_ok = FALSE;
+ size_change_ok = FALSE;
+ sec = *psec;
+ if (!_bfd_elf_merge_symbol (abfd, info, shortname, sym, &sec, value,
+ &hi, &skip, &override, &type_change_ok,
+ &size_change_ok))
+ return FALSE;
+
+ if (skip)
+ goto nondefault;
+
+ if (! override)
+ {
+ bh = &hi->root;
+ if (! (_bfd_generic_link_add_one_symbol
+ (info, abfd, shortname, BSF_INDIRECT, bfd_ind_section_ptr,
+ 0, name, FALSE, collect, &bh)))
+ return FALSE;
+ hi = (struct elf_link_hash_entry *) bh;
+ }
+ else
+ {
+ /* In this case the symbol named SHORTNAME is overriding the
+ indirect symbol we want to add. We were planning on making
+ SHORTNAME an indirect symbol referring to NAME. SHORTNAME
+ is the name without a version. NAME is the fully versioned
+ name, and it is the default version.
+
+ Overriding means that we already saw a definition for the
+ symbol SHORTNAME in a regular object, and it is overriding
+ the symbol defined in the dynamic object.
+
+ When this happens, we actually want to change NAME, the
+ symbol we just added, to refer to SHORTNAME. This will cause
+ references to NAME in the shared object to become references
+ to SHORTNAME in the regular object. This is what we expect
+ when we override a function in a shared object: that the
+ references in the shared object will be mapped to the
+ definition in the regular object. */
+
+ while (hi->root.type == bfd_link_hash_indirect
+ || hi->root.type == bfd_link_hash_warning)
+ hi = (struct elf_link_hash_entry *) hi->root.u.i.link;
+
+ h->root.type = bfd_link_hash_indirect;
+ h->root.u.i.link = (struct bfd_link_hash_entry *) hi;
+ if (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC)
+ {
+ h->elf_link_hash_flags &=~ ELF_LINK_HASH_DEF_DYNAMIC;
+ hi->elf_link_hash_flags |= ELF_LINK_HASH_REF_DYNAMIC;
+ if (hi->elf_link_hash_flags
+ & (ELF_LINK_HASH_REF_REGULAR
+ | ELF_LINK_HASH_DEF_REGULAR))
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, hi))
+ return FALSE;
+ }
+ }
+
+ /* Now set HI to H, so that the following code will set the
+ other fields correctly. */
+ hi = h;
+ }
+
+ /* If there is a duplicate definition somewhere, then HI may not
+ point to an indirect symbol. We will have reported an error to
+ the user in that case. */
+
+ if (hi->root.type == bfd_link_hash_indirect)
+ {
+ struct elf_link_hash_entry *ht;
+
+ ht = (struct elf_link_hash_entry *) hi->root.u.i.link;
+ (*bed->elf_backend_copy_indirect_symbol) (bed, ht, hi);
+
+ /* See if the new flags lead us to realize that the symbol must
+ be dynamic. */
+ if (! *dynsym)
+ {
+ if (! dynamic)
+ {
+ if (info->shared
+ || ((hi->elf_link_hash_flags
+ & ELF_LINK_HASH_REF_DYNAMIC) != 0))
+ *dynsym = TRUE;
+ }
+ else
+ {
+ if ((hi->elf_link_hash_flags
+ & ELF_LINK_HASH_REF_REGULAR) != 0)
+ *dynsym = TRUE;
+ }
+ }
+ }
+
+ /* We also need to define an indirection from the nondefault version
+ of the symbol. */
+
+nondefault:
+ len = strlen (name);
+ shortname = bfd_hash_allocate (&info->hash->table, len);
+ if (shortname == NULL)
+ return FALSE;
+ memcpy (shortname, name, shortlen);
+ memcpy (shortname + shortlen, p + 1, len - shortlen);
+
+ /* Once again, merge with any existing symbol. */
+ type_change_ok = FALSE;
+ size_change_ok = FALSE;
+ sec = *psec;
+ if (!_bfd_elf_merge_symbol (abfd, info, shortname, sym, &sec, value,
+ &hi, &skip, &override, &type_change_ok,
+ &size_change_ok))
+ return FALSE;
+
+ if (skip)
+ return TRUE;
+
+ if (override)
+ {
+ /* Here SHORTNAME is a versioned name, so we don't expect to see
+ the type of override we do in the case above unless it is
+ overridden by a versioned definition. */
+ if (hi->root.type != bfd_link_hash_defined
+ && hi->root.type != bfd_link_hash_defweak)
+ (*_bfd_error_handler)
+ (_("%s: warning: unexpected redefinition of indirect versioned symbol `%s'"),
+ bfd_archive_filename (abfd), shortname);
+ }
+ else
+ {
+ bh = &hi->root;
+ if (! (_bfd_generic_link_add_one_symbol
+ (info, abfd, shortname, BSF_INDIRECT,
+ bfd_ind_section_ptr, 0, name, FALSE, collect, &bh)))
+ return FALSE;
+ hi = (struct elf_link_hash_entry *) bh;
+
+ /* If there is a duplicate definition somewhere, then HI may not
+ point to an indirect symbol. We will have reported an error
+ to the user in that case. */
+
+ if (hi->root.type == bfd_link_hash_indirect)
+ {
+ (*bed->elf_backend_copy_indirect_symbol) (bed, h, hi);
+
+ /* See if the new flags lead us to realize that the symbol
+ must be dynamic. */
+ if (! *dynsym)
+ {
+ if (! dynamic)
+ {
+ if (info->shared
+ || ((hi->elf_link_hash_flags
+ & ELF_LINK_HASH_REF_DYNAMIC) != 0))
+ *dynsym = TRUE;
+ }
+ else
+ {
+ if ((hi->elf_link_hash_flags
+ & ELF_LINK_HASH_REF_REGULAR) != 0)
+ *dynsym = TRUE;
+ }
+ }
+ }
+ }
+
+ return TRUE;
+}
+
+/* This routine is used to export all defined symbols into the dynamic
+ symbol table. It is called via elf_link_hash_traverse. */
+
+bfd_boolean
+_bfd_elf_export_symbol (struct elf_link_hash_entry *h, void *data)
+{
+ struct elf_info_failed *eif = data;
+
+ /* Ignore indirect symbols. These are added by the versioning code. */
+ if (h->root.type == bfd_link_hash_indirect)
+ return TRUE;
+
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ if (h->dynindx == -1
+ && (h->elf_link_hash_flags
+ & (ELF_LINK_HASH_DEF_REGULAR | ELF_LINK_HASH_REF_REGULAR)) != 0)
+ {
+ struct bfd_elf_version_tree *t;
+ struct bfd_elf_version_expr *d;
+
+ for (t = eif->verdefs; t != NULL; t = t->next)
+ {
+ if (t->globals.list != NULL)
+ {
+ d = (*t->match) (&t->globals, NULL, h->root.root.string);
+ if (d != NULL)
+ goto doit;
+ }
+
+ if (t->locals.list != NULL)
+ {
+ d = (*t->match) (&t->locals, NULL, h->root.root.string);
+ if (d != NULL)
+ return TRUE;
+ }
+ }
+
+ if (!eif->verdefs)
+ {
+ doit:
+ if (! bfd_elf_link_record_dynamic_symbol (eif->info, h))
+ {
+ eif->failed = TRUE;
+ return FALSE;
+ }
+ }
+ }
+
+ return TRUE;
+}
+
+/* Look through the symbols which are defined in other shared
+ libraries and referenced here. Update the list of version
+ dependencies. This will be put into the .gnu.version_r section.
+ This function is called via elf_link_hash_traverse. */
+
+bfd_boolean
+_bfd_elf_link_find_version_dependencies (struct elf_link_hash_entry *h,
+ void *data)
+{
+ struct elf_find_verdep_info *rinfo = data;
+ Elf_Internal_Verneed *t;
+ Elf_Internal_Vernaux *a;
+ bfd_size_type amt;
+
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ /* We only care about symbols defined in shared objects with version
+ information. */
+ if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) == 0
+ || (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0
+ || h->dynindx == -1
+ || h->verinfo.verdef == NULL)
+ return TRUE;
+
+ /* See if we already know about this version. */
+ for (t = elf_tdata (rinfo->output_bfd)->verref; t != NULL; t = t->vn_nextref)
+ {
+ if (t->vn_bfd != h->verinfo.verdef->vd_bfd)
+ continue;
+
+ for (a = t->vn_auxptr; a != NULL; a = a->vna_nextptr)
+ if (a->vna_nodename == h->verinfo.verdef->vd_nodename)
+ return TRUE;
+
+ break;
+ }
+
+ /* This is a new version. Add it to tree we are building. */
+
+ if (t == NULL)
+ {
+ amt = sizeof *t;
+ t = bfd_zalloc (rinfo->output_bfd, amt);
+ if (t == NULL)
+ {
+ rinfo->failed = TRUE;
+ return FALSE;
+ }
+
+ t->vn_bfd = h->verinfo.verdef->vd_bfd;
+ t->vn_nextref = elf_tdata (rinfo->output_bfd)->verref;
+ elf_tdata (rinfo->output_bfd)->verref = t;
+ }
+
+ amt = sizeof *a;
+ a = bfd_zalloc (rinfo->output_bfd, amt);
+
+ /* Note that we are copying a string pointer here, and testing it
+ above. If bfd_elf_string_from_elf_section is ever changed to
+ discard the string data when low in memory, this will have to be
+ fixed. */
+ a->vna_nodename = h->verinfo.verdef->vd_nodename;
+
+ a->vna_flags = h->verinfo.verdef->vd_flags;
+ a->vna_nextptr = t->vn_auxptr;
+
+ h->verinfo.verdef->vd_exp_refno = rinfo->vers;
+ ++rinfo->vers;
+
+ a->vna_other = h->verinfo.verdef->vd_exp_refno + 1;
+
+ t->vn_auxptr = a;
+
+ return TRUE;
+}
+
+/* Figure out appropriate versions for all the symbols. We may not
+ have the version number script until we have read all of the input
+ files, so until that point we don't know which symbols should be
+ local. This function is called via elf_link_hash_traverse. */
+
+bfd_boolean
+_bfd_elf_link_assign_sym_version (struct elf_link_hash_entry *h, void *data)
+{
+ struct elf_assign_sym_version_info *sinfo;
+ struct bfd_link_info *info;
+ const struct elf_backend_data *bed;
+ struct elf_info_failed eif;
+ char *p;
+ bfd_size_type amt;
+
+ sinfo = data;
+ info = sinfo->info;
+
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ /* Fix the symbol flags. */
+ eif.failed = FALSE;
+ eif.info = info;
+ if (! _bfd_elf_fix_symbol_flags (h, &eif))
+ {
+ if (eif.failed)
+ sinfo->failed = TRUE;
+ return FALSE;
+ }
+
+ /* We only need version numbers for symbols defined in regular
+ objects. */
+ if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
+ return TRUE;
+
+ bed = get_elf_backend_data (sinfo->output_bfd);
+ p = strchr (h->root.root.string, ELF_VER_CHR);
+ if (p != NULL && h->verinfo.vertree == NULL)
+ {
+ struct bfd_elf_version_tree *t;
+ bfd_boolean hidden;
+
+ hidden = TRUE;
+
+ /* There are two consecutive ELF_VER_CHR characters if this is
+ not a hidden symbol. */
+ ++p;
+ if (*p == ELF_VER_CHR)
+ {
+ hidden = FALSE;
+ ++p;
+ }
+
+ /* If there is no version string, we can just return out. */
+ if (*p == '\0')
+ {
+ if (hidden)
+ h->elf_link_hash_flags |= ELF_LINK_HIDDEN;
+ return TRUE;
+ }
+
+ /* Look for the version. If we find it, it is no longer weak. */
+ for (t = sinfo->verdefs; t != NULL; t = t->next)
+ {
+ if (strcmp (t->name, p) == 0)
+ {
+ size_t len;
+ char *alc;
+ struct bfd_elf_version_expr *d;
+
+ len = p - h->root.root.string;
+ alc = bfd_malloc (len);
+ if (alc == NULL)
+ return FALSE;
+ memcpy (alc, h->root.root.string, len - 1);
+ alc[len - 1] = '\0';
+ if (alc[len - 2] == ELF_VER_CHR)
+ alc[len - 2] = '\0';
+
+ h->verinfo.vertree = t;
+ t->used = TRUE;
+ d = NULL;
+
+ if (t->globals.list != NULL)
+ d = (*t->match) (&t->globals, NULL, alc);
+
+ /* See if there is anything to force this symbol to
+ local scope. */
+ if (d == NULL && t->locals.list != NULL)
+ {
+ d = (*t->match) (&t->locals, NULL, alc);
+ if (d != NULL
+ && h->dynindx != -1
+ && info->shared
+ && ! info->export_dynamic)
+ (*bed->elf_backend_hide_symbol) (info, h, TRUE);
+ }
+
+ free (alc);
+ break;
+ }
+ }
+
+ /* If we are building an application, we need to create a
+ version node for this version. */
+ if (t == NULL && info->executable)
+ {
+ struct bfd_elf_version_tree **pp;
+ int version_index;
+
+ /* If we aren't going to export this symbol, we don't need
+ to worry about it. */
+ if (h->dynindx == -1)
+ return TRUE;
+
+ amt = sizeof *t;
+ t = bfd_zalloc (sinfo->output_bfd, amt);
+ if (t == NULL)
+ {
+ sinfo->failed = TRUE;
+ return FALSE;
+ }
+
+ t->name = p;
+ t->name_indx = (unsigned int) -1;
+ t->used = TRUE;
+
+ version_index = 1;
+ /* Don't count anonymous version tag. */
+ if (sinfo->verdefs != NULL && sinfo->verdefs->vernum == 0)
+ version_index = 0;
+ for (pp = &sinfo->verdefs; *pp != NULL; pp = &(*pp)->next)
+ ++version_index;
+ t->vernum = version_index;
+
+ *pp = t;
+
+ h->verinfo.vertree = t;
+ }
+ else if (t == NULL)
+ {
+ /* We could not find the version for a symbol when
+ generating a shared archive. Return an error. */
+ (*_bfd_error_handler)
+ (_("%s: undefined versioned symbol name %s"),
+ bfd_get_filename (sinfo->output_bfd), h->root.root.string);
+ bfd_set_error (bfd_error_bad_value);
+ sinfo->failed = TRUE;
+ return FALSE;
+ }
+
+ if (hidden)
+ h->elf_link_hash_flags |= ELF_LINK_HIDDEN;
+ }
+
+ /* If we don't have a version for this symbol, see if we can find
+ something. */
+ if (h->verinfo.vertree == NULL && sinfo->verdefs != NULL)
+ {
+ struct bfd_elf_version_tree *t;
+ struct bfd_elf_version_tree *local_ver;
+ struct bfd_elf_version_expr *d;
+
+ /* See if can find what version this symbol is in. If the
+ symbol is supposed to be local, then don't actually register
+ it. */
+ local_ver = NULL;
+ for (t = sinfo->verdefs; t != NULL; t = t->next)
+ {
+ if (t->globals.list != NULL)
+ {
+ bfd_boolean matched;
+
+ matched = FALSE;
+ d = NULL;
+ while ((d = (*t->match) (&t->globals, d,
+ h->root.root.string)) != NULL)
+ if (d->symver)
+ matched = TRUE;
+ else
+ {
+ /* There is a version without definition. Make
+ the symbol the default definition for this
+ version. */
+ h->verinfo.vertree = t;
+ local_ver = NULL;
+ d->script = 1;
+ break;
+ }
+ if (d != NULL)
+ break;
+ else if (matched)
+ /* There is no undefined version for this symbol. Hide the
+ default one. */
+ (*bed->elf_backend_hide_symbol) (info, h, TRUE);
+ }
+
+ if (t->locals.list != NULL)
+ {
+ d = NULL;
+ while ((d = (*t->match) (&t->locals, d,
+ h->root.root.string)) != NULL)
+ {
+ local_ver = t;
+ /* If the match is "*", keep looking for a more
+ explicit, perhaps even global, match.
+ XXX: Shouldn't this be !d->wildcard instead? */
+ if (d->pattern[0] != '*' || d->pattern[1] != '\0')
+ break;
+ }
+
+ if (d != NULL)
+ break;
+ }
+ }
+
+ if (local_ver != NULL)
+ {
+ h->verinfo.vertree = local_ver;
+ if (h->dynindx != -1
+ && info->shared
+ && ! info->export_dynamic)
+ {
+ (*bed->elf_backend_hide_symbol) (info, h, TRUE);
+ }
+ }
+ }
+
+ return TRUE;
+}
+
+/* Read and swap the relocs from the section indicated by SHDR. This
+ may be either a REL or a RELA section. The relocations are
+ translated into RELA relocations and stored in INTERNAL_RELOCS,
+ which should have already been allocated to contain enough space.
+ The EXTERNAL_RELOCS are a buffer where the external form of the
+ relocations should be stored.
+
+ Returns FALSE if something goes wrong. */
+
+static bfd_boolean
+elf_link_read_relocs_from_section (bfd *abfd,
+ asection *sec,
+ Elf_Internal_Shdr *shdr,
+ void *external_relocs,
+ Elf_Internal_Rela *internal_relocs)
+{
+ const struct elf_backend_data *bed;
+ void (*swap_in) (bfd *, const bfd_byte *, Elf_Internal_Rela *);
+ const bfd_byte *erela;
+ const bfd_byte *erelaend;
+ Elf_Internal_Rela *irela;
+ Elf_Internal_Shdr *symtab_hdr;
+ size_t nsyms;
+
+ /* Position ourselves at the start of the section. */
+ if (bfd_seek (abfd, shdr->sh_offset, SEEK_SET) != 0)
+ return FALSE;
+
+ /* Read the relocations. */
+ if (bfd_bread (external_relocs, shdr->sh_size, abfd) != shdr->sh_size)
+ return FALSE;
+
+ symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
+ nsyms = symtab_hdr->sh_size / symtab_hdr->sh_entsize;
+
+ bed = get_elf_backend_data (abfd);
+
+ /* Convert the external relocations to the internal format. */
+ if (shdr->sh_entsize == bed->s->sizeof_rel)
+ swap_in = bed->s->swap_reloc_in;
+ else if (shdr->sh_entsize == bed->s->sizeof_rela)
+ swap_in = bed->s->swap_reloca_in;
+ else
+ {
+ bfd_set_error (bfd_error_wrong_format);
+ return FALSE;
+ }
+
+ erela = external_relocs;
+ erelaend = erela + shdr->sh_size;
+ irela = internal_relocs;
+ while (erela < erelaend)
+ {
+ bfd_vma r_symndx;
+
+ (*swap_in) (abfd, erela, irela);
+ r_symndx = ELF32_R_SYM (irela->r_info);
+ if (bed->s->arch_size == 64)
+ r_symndx >>= 24;
+ if ((size_t) r_symndx >= nsyms)
+ {
+ (*_bfd_error_handler)
+ (_("%s: bad reloc symbol index (0x%lx >= 0x%lx) for offset 0x%lx in section `%s'"),
+ bfd_archive_filename (abfd), (unsigned long) r_symndx,
+ (unsigned long) nsyms, irela->r_offset, sec->name);
+ bfd_set_error (bfd_error_bad_value);
+ return FALSE;
+ }
+ irela += bed->s->int_rels_per_ext_rel;
+ erela += shdr->sh_entsize;
+ }
+
+ return TRUE;
+}
+
+/* Read and swap the relocs for a section O. They may have been
+ cached. If the EXTERNAL_RELOCS and INTERNAL_RELOCS arguments are
+ not NULL, they are used as buffers to read into. They are known to
+ be large enough. If the INTERNAL_RELOCS relocs argument is NULL,
+ the return value is allocated using either malloc or bfd_alloc,
+ according to the KEEP_MEMORY argument. If O has two relocation
+ sections (both REL and RELA relocations), then the REL_HDR
+ relocations will appear first in INTERNAL_RELOCS, followed by the
+ REL_HDR2 relocations. */
+
+Elf_Internal_Rela *
+_bfd_elf_link_read_relocs (bfd *abfd,
+ asection *o,
+ void *external_relocs,
+ Elf_Internal_Rela *internal_relocs,
+ bfd_boolean keep_memory)
+{
+ Elf_Internal_Shdr *rel_hdr;
+ void *alloc1 = NULL;
+ Elf_Internal_Rela *alloc2 = NULL;
+ const struct elf_backend_data *bed = get_elf_backend_data (abfd);
+
+ if (elf_section_data (o)->relocs != NULL)
+ return elf_section_data (o)->relocs;
+
+ if (o->reloc_count == 0)
+ return NULL;
+
+ rel_hdr = &elf_section_data (o)->rel_hdr;
+
+ if (internal_relocs == NULL)
+ {
+ bfd_size_type size;
+
+ size = o->reloc_count;
+ size *= bed->s->int_rels_per_ext_rel * sizeof (Elf_Internal_Rela);
+ if (keep_memory)
+ internal_relocs = bfd_alloc (abfd, size);
+ else
+ internal_relocs = alloc2 = bfd_malloc (size);
+ if (internal_relocs == NULL)
+ goto error_return;
+ }
+
+ if (external_relocs == NULL)
+ {
+ bfd_size_type size = rel_hdr->sh_size;
+
+ if (elf_section_data (o)->rel_hdr2)
+ size += elf_section_data (o)->rel_hdr2->sh_size;
+ alloc1 = bfd_malloc (size);
+ if (alloc1 == NULL)
+ goto error_return;
+ external_relocs = alloc1;
+ }
+
+ if (!elf_link_read_relocs_from_section (abfd, o, rel_hdr,
+ external_relocs,
+ internal_relocs))
+ goto error_return;
+ if (elf_section_data (o)->rel_hdr2
+ && (!elf_link_read_relocs_from_section
+ (abfd, o,
+ elf_section_data (o)->rel_hdr2,
+ ((bfd_byte *) external_relocs) + rel_hdr->sh_size,
+ internal_relocs + (NUM_SHDR_ENTRIES (rel_hdr)
+ * bed->s->int_rels_per_ext_rel))))
+ goto error_return;
+
+ /* Cache the results for next time, if we can. */
+ if (keep_memory)
+ elf_section_data (o)->relocs = internal_relocs;
+
+ if (alloc1 != NULL)
+ free (alloc1);
+
+ /* Don't free alloc2, since if it was allocated we are passing it
+ back (under the name of internal_relocs). */
+
+ return internal_relocs;
+
+ error_return:
+ if (alloc1 != NULL)
+ free (alloc1);
+ if (alloc2 != NULL)
+ free (alloc2);
+ return NULL;
+}
+
+/* Compute the size of, and allocate space for, REL_HDR which is the
+ section header for a section containing relocations for O. */
+
+bfd_boolean
+_bfd_elf_link_size_reloc_section (bfd *abfd,
+ Elf_Internal_Shdr *rel_hdr,
+ asection *o)
+{
+ bfd_size_type reloc_count;
+ bfd_size_type num_rel_hashes;
+
+ /* Figure out how many relocations there will be. */
+ if (rel_hdr == &elf_section_data (o)->rel_hdr)
+ reloc_count = elf_section_data (o)->rel_count;
+ else
+ reloc_count = elf_section_data (o)->rel_count2;
+
+ num_rel_hashes = o->reloc_count;
+ if (num_rel_hashes < reloc_count)
+ num_rel_hashes = reloc_count;
+
+ /* That allows us to calculate the size of the section. */
+ rel_hdr->sh_size = rel_hdr->sh_entsize * reloc_count;
+
+ /* The contents field must last into write_object_contents, so we
+ allocate it with bfd_alloc rather than malloc. Also since we
+ cannot be sure that the contents will actually be filled in,
+ we zero the allocated space. */
+ rel_hdr->contents = bfd_zalloc (abfd, rel_hdr->sh_size);
+ if (rel_hdr->contents == NULL && rel_hdr->sh_size != 0)
+ return FALSE;
+
+ /* We only allocate one set of hash entries, so we only do it the
+ first time we are called. */
+ if (elf_section_data (o)->rel_hashes == NULL
+ && num_rel_hashes)
+ {
+ struct elf_link_hash_entry **p;
+
+ p = bfd_zmalloc (num_rel_hashes * sizeof (struct elf_link_hash_entry *));
+ if (p == NULL)
+ return FALSE;
+
+ elf_section_data (o)->rel_hashes = p;
+ }
+
+ return TRUE;
+}
+
+/* Copy the relocations indicated by the INTERNAL_RELOCS (which
+ originated from the section given by INPUT_REL_HDR) to the
+ OUTPUT_BFD. */
+
+bfd_boolean
+_bfd_elf_link_output_relocs (bfd *output_bfd,
+ asection *input_section,
+ Elf_Internal_Shdr *input_rel_hdr,
+ Elf_Internal_Rela *internal_relocs)
+{
+ Elf_Internal_Rela *irela;
+ Elf_Internal_Rela *irelaend;
+ bfd_byte *erel;
+ Elf_Internal_Shdr *output_rel_hdr;
+ asection *output_section;
+ unsigned int *rel_countp = NULL;
+ const struct elf_backend_data *bed;
+ void (*swap_out) (bfd *, const Elf_Internal_Rela *, bfd_byte *);
+
+ output_section = input_section->output_section;
+ output_rel_hdr = NULL;
+
+ if (elf_section_data (output_section)->rel_hdr.sh_entsize
+ == input_rel_hdr->sh_entsize)
+ {
+ output_rel_hdr = &elf_section_data (output_section)->rel_hdr;
+ rel_countp = &elf_section_data (output_section)->rel_count;
+ }
+ else if (elf_section_data (output_section)->rel_hdr2
+ && (elf_section_data (output_section)->rel_hdr2->sh_entsize
+ == input_rel_hdr->sh_entsize))
+ {
+ output_rel_hdr = elf_section_data (output_section)->rel_hdr2;
+ rel_countp = &elf_section_data (output_section)->rel_count2;
+ }
+ else
+ {
+ (*_bfd_error_handler)
+ (_("%s: relocation size mismatch in %s section %s"),
+ bfd_get_filename (output_bfd),
+ bfd_archive_filename (input_section->owner),
+ input_section->name);
+ bfd_set_error (bfd_error_wrong_object_format);
+ return FALSE;
+ }
+
+ bed = get_elf_backend_data (output_bfd);
+ if (input_rel_hdr->sh_entsize == bed->s->sizeof_rel)
+ swap_out = bed->s->swap_reloc_out;
+ else if (input_rel_hdr->sh_entsize == bed->s->sizeof_rela)
+ swap_out = bed->s->swap_reloca_out;
+ else
+ abort ();
+
+ erel = output_rel_hdr->contents;
+ erel += *rel_countp * input_rel_hdr->sh_entsize;
+ irela = internal_relocs;
+ irelaend = irela + (NUM_SHDR_ENTRIES (input_rel_hdr)
+ * bed->s->int_rels_per_ext_rel);
+ while (irela < irelaend)
+ {
+ (*swap_out) (output_bfd, irela, erel);
+ irela += bed->s->int_rels_per_ext_rel;
+ erel += input_rel_hdr->sh_entsize;
+ }
+
+ /* Bump the counter, so that we know where to add the next set of
+ relocations. */
+ *rel_countp += NUM_SHDR_ENTRIES (input_rel_hdr);
+
+ return TRUE;
+}
-/* Create a special linker section, or return a pointer to a linker
- section already created */
+/* Fix up the flags for a symbol. This handles various cases which
+ can only be fixed after all the input files are seen. This is
+ currently called by both adjust_dynamic_symbol and
+ assign_sym_version, which is unnecessary but perhaps more robust in
+ the face of future changes. */
-elf_linker_section_t *
-_bfd_elf_create_linker_section (abfd, info, which, defaults)
- bfd *abfd;
- struct bfd_link_info *info;
- enum elf_linker_section_enum which;
- elf_linker_section_t *defaults;
+bfd_boolean
+_bfd_elf_fix_symbol_flags (struct elf_link_hash_entry *h,
+ struct elf_info_failed *eif)
{
- bfd *dynobj = elf_hash_table (info)->dynobj;
- elf_linker_section_t *lsect;
+ /* If this symbol was mentioned in a non-ELF file, try to set
+ DEF_REGULAR and REF_REGULAR correctly. This is the only way to
+ permit a non-ELF file to correctly refer to a symbol defined in
+ an ELF dynamic object. */
+ if ((h->elf_link_hash_flags & ELF_LINK_NON_ELF) != 0)
+ {
+ while (h->root.type == bfd_link_hash_indirect)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ if (h->root.type != bfd_link_hash_defined
+ && h->root.type != bfd_link_hash_defweak)
+ h->elf_link_hash_flags |= (ELF_LINK_HASH_REF_REGULAR
+ | ELF_LINK_HASH_REF_REGULAR_NONWEAK);
+ else
+ {
+ if (h->root.u.def.section->owner != NULL
+ && (bfd_get_flavour (h->root.u.def.section->owner)
+ == bfd_target_elf_flavour))
+ h->elf_link_hash_flags |= (ELF_LINK_HASH_REF_REGULAR
+ | ELF_LINK_HASH_REF_REGULAR_NONWEAK);
+ else
+ h->elf_link_hash_flags |= ELF_LINK_HASH_DEF_REGULAR;
+ }
+
+ if (h->dynindx == -1
+ && ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0
+ || (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) != 0))
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (eif->info, h))
+ {
+ eif->failed = TRUE;
+ return FALSE;
+ }
+ }
+ }
+ else
+ {
+ /* Unfortunately, ELF_LINK_NON_ELF is only correct if the symbol
+ was first seen in a non-ELF file. Fortunately, if the symbol
+ was first seen in an ELF file, we're probably OK unless the
+ symbol was defined in a non-ELF file. Catch that case here.
+ FIXME: We're still in trouble if the symbol was first seen in
+ a dynamic object, and then later in a non-ELF regular object. */
+ if ((h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak)
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0
+ && (h->root.u.def.section->owner != NULL
+ ? (bfd_get_flavour (h->root.u.def.section->owner)
+ != bfd_target_elf_flavour)
+ : (bfd_is_abs_section (h->root.u.def.section)
+ && (h->elf_link_hash_flags
+ & ELF_LINK_HASH_DEF_DYNAMIC) == 0)))
+ h->elf_link_hash_flags |= ELF_LINK_HASH_DEF_REGULAR;
+ }
+
+ /* If this is a final link, and the symbol was defined as a common
+ symbol in a regular object file, and there was no definition in
+ any dynamic object, then the linker will have allocated space for
+ the symbol in a common section but the ELF_LINK_HASH_DEF_REGULAR
+ flag will not have been set. */
+ if (h->root.type == bfd_link_hash_defined
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_REGULAR) != 0
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) == 0
+ && (h->root.u.def.section->owner->flags & DYNAMIC) == 0)
+ h->elf_link_hash_flags |= ELF_LINK_HASH_DEF_REGULAR;
+
+ /* If -Bsymbolic was used (which means to bind references to global
+ symbols to the definition within the shared object), and this
+ symbol was defined in a regular object, then it actually doesn't
+ need a PLT entry. Likewise, if the symbol has non-default
+ visibility. If the symbol has hidden or internal visibility, we
+ will force it local. */
+ if ((h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_PLT) != 0
+ && eif->info->shared
+ && is_elf_hash_table (eif->info->hash)
+ && (eif->info->symbolic
+ || ELF_ST_VISIBILITY (h->other) != STV_DEFAULT)
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0)
+ {
+ const struct elf_backend_data *bed;
+ bfd_boolean force_local;
+
+ bed = get_elf_backend_data (elf_hash_table (eif->info)->dynobj);
- /* Record the first bfd section that needs the special section */
- if (!dynobj)
- dynobj = elf_hash_table (info)->dynobj = abfd;
+ force_local = (ELF_ST_VISIBILITY (h->other) == STV_INTERNAL
+ || ELF_ST_VISIBILITY (h->other) == STV_HIDDEN);
+ (*bed->elf_backend_hide_symbol) (eif->info, h, force_local);
+ }
- /* If this is the first time, create the section */
- lsect = elf_linker_section (dynobj, which);
- if (!lsect)
+ /* If a weak undefined symbol has non-default visibility, we also
+ hide it from the dynamic linker. */
+ if (ELF_ST_VISIBILITY (h->other) != STV_DEFAULT
+ && h->root.type == bfd_link_hash_undefweak)
+ {
+ const struct elf_backend_data *bed;
+ bed = get_elf_backend_data (elf_hash_table (eif->info)->dynobj);
+ (*bed->elf_backend_hide_symbol) (eif->info, h, TRUE);
+ }
+
+ /* If this is a weak defined symbol in a dynamic object, and we know
+ the real definition in the dynamic object, copy interesting flags
+ over to the real definition. */
+ if (h->weakdef != NULL)
+ {
+ struct elf_link_hash_entry *weakdef;
+
+ weakdef = h->weakdef;
+ if (h->root.type == bfd_link_hash_indirect)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ BFD_ASSERT (h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak);
+ BFD_ASSERT (weakdef->root.type == bfd_link_hash_defined
+ || weakdef->root.type == bfd_link_hash_defweak);
+ BFD_ASSERT (weakdef->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC);
+
+ /* If the real definition is defined by a regular object file,
+ don't do anything special. See the longer description in
+ _bfd_elf_adjust_dynamic_symbol, below. */
+ if ((weakdef->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0)
+ h->weakdef = NULL;
+ else
+ {
+ const struct elf_backend_data *bed;
+
+ bed = get_elf_backend_data (elf_hash_table (eif->info)->dynobj);
+ (*bed->elf_backend_copy_indirect_symbol) (bed, weakdef, h);
+ }
+ }
+
+ return TRUE;
+}
+
+/* Make the backend pick a good value for a dynamic symbol. This is
+ called via elf_link_hash_traverse, and also calls itself
+ recursively. */
+
+bfd_boolean
+_bfd_elf_adjust_dynamic_symbol (struct elf_link_hash_entry *h, void *data)
+{
+ struct elf_info_failed *eif = data;
+ bfd *dynobj;
+ const struct elf_backend_data *bed;
+
+ if (! is_elf_hash_table (eif->info->hash))
+ return FALSE;
+
+ if (h->root.type == bfd_link_hash_warning)
+ {
+ h->plt = elf_hash_table (eif->info)->init_offset;
+ h->got = elf_hash_table (eif->info)->init_offset;
+
+ /* When warning symbols are created, they **replace** the "real"
+ entry in the hash table, thus we never get to see the real
+ symbol in a hash traversal. So look at it now. */
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+ }
+
+ /* Ignore indirect symbols. These are added by the versioning code. */
+ if (h->root.type == bfd_link_hash_indirect)
+ return TRUE;
+
+ /* Fix the symbol flags. */
+ if (! _bfd_elf_fix_symbol_flags (h, eif))
+ return FALSE;
+
+ /* If this symbol does not require a PLT entry, and it is not
+ defined by a dynamic object, or is not referenced by a regular
+ object, ignore it. We do have to handle a weak defined symbol,
+ even if no regular object refers to it, if we decided to add it
+ to the dynamic symbol table. FIXME: Do we normally need to worry
+ about symbols which are defined by one dynamic object and
+ referenced by another one? */
+ if ((h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_PLT) == 0
+ && ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) != 0
+ || (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) == 0
+ || ((h->elf_link_hash_flags & ELF_LINK_HASH_REF_REGULAR) == 0
+ && (h->weakdef == NULL || h->weakdef->dynindx == -1))))
+ {
+ h->plt = elf_hash_table (eif->info)->init_offset;
+ return TRUE;
+ }
+
+ /* If we've already adjusted this symbol, don't do it again. This
+ can happen via a recursive call. */
+ if ((h->elf_link_hash_flags & ELF_LINK_HASH_DYNAMIC_ADJUSTED) != 0)
+ return TRUE;
+
+ /* Don't look at this symbol again. Note that we must set this
+ after checking the above conditions, because we may look at a
+ symbol once, decide not to do anything, and then get called
+ recursively later after REF_REGULAR is set below. */
+ h->elf_link_hash_flags |= ELF_LINK_HASH_DYNAMIC_ADJUSTED;
+
+ /* If this is a weak definition, and we know a real definition, and
+ the real symbol is not itself defined by a regular object file,
+ then get a good value for the real definition. We handle the
+ real symbol first, for the convenience of the backend routine.
+
+ Note that there is a confusing case here. If the real definition
+ is defined by a regular object file, we don't get the real symbol
+ from the dynamic object, but we do get the weak symbol. If the
+ processor backend uses a COPY reloc, then if some routine in the
+ dynamic object changes the real symbol, we will not see that
+ change in the corresponding weak symbol. This is the way other
+ ELF linkers work as well, and seems to be a result of the shared
+ library model.
+
+ I will clarify this issue. Most SVR4 shared libraries define the
+ variable _timezone and define timezone as a weak synonym. The
+ tzset call changes _timezone. If you write
+ extern int timezone;
+ int _timezone = 5;
+ int main () { tzset (); printf ("%d %d\n", timezone, _timezone); }
+ you might expect that, since timezone is a synonym for _timezone,
+ the same number will print both times. However, if the processor
+ backend uses a COPY reloc, then actually timezone will be copied
+ into your process image, and, since you define _timezone
+ yourself, _timezone will not. Thus timezone and _timezone will
+ wind up at different memory locations. The tzset call will set
+ _timezone, leaving timezone unchanged. */
+
+ if (h->weakdef != NULL)
+ {
+ /* If we get to this point, we know there is an implicit
+ reference by a regular object file via the weak symbol H.
+ FIXME: Is this really true? What if the traversal finds
+ H->WEAKDEF before it finds H? */
+ h->weakdef->elf_link_hash_flags |= ELF_LINK_HASH_REF_REGULAR;
+
+ if (! _bfd_elf_adjust_dynamic_symbol (h->weakdef, eif))
+ return FALSE;
+ }
+
+ /* If a symbol has no type and no size and does not require a PLT
+ entry, then we are probably about to do the wrong thing here: we
+ are probably going to create a COPY reloc for an empty object.
+ This case can arise when a shared object is built with assembly
+ code, and the assembly code fails to set the symbol type. */
+ if (h->size == 0
+ && h->type == STT_NOTYPE
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_NEEDS_PLT) == 0)
+ (*_bfd_error_handler)
+ (_("warning: type and size of dynamic symbol `%s' are not defined"),
+ h->root.root.string);
+
+ dynobj = elf_hash_table (eif->info)->dynobj;
+ bed = get_elf_backend_data (dynobj);
+ if (! (*bed->elf_backend_adjust_dynamic_symbol) (eif->info, h))
+ {
+ eif->failed = TRUE;
+ return FALSE;
+ }
+
+ return TRUE;
+}
+
+/* Adjust all external symbols pointing into SEC_MERGE sections
+ to reflect the object merging within the sections. */
+
+bfd_boolean
+_bfd_elf_link_sec_merge_syms (struct elf_link_hash_entry *h, void *data)
+{
+ asection *sec;
+
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ if ((h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak)
+ && ((sec = h->root.u.def.section)->flags & SEC_MERGE)
+ && sec->sec_info_type == ELF_INFO_TYPE_MERGE)
+ {
+ bfd *output_bfd = data;
+
+ h->root.u.def.value =
+ _bfd_merged_section_offset (output_bfd,
+ &h->root.u.def.section,
+ elf_section_data (sec)->sec_info,
+ h->root.u.def.value, 0);
+ }
+
+ return TRUE;
+}
+
+/* Returns false if the symbol referred to by H should be considered
+ to resolve local to the current module, and true if it should be
+ considered to bind dynamically. */
+
+bfd_boolean
+_bfd_elf_dynamic_symbol_p (struct elf_link_hash_entry *h,
+ struct bfd_link_info *info,
+ bfd_boolean ignore_protected)
+{
+ bfd_boolean binding_stays_local_p;
+
+ if (h == NULL)
+ return FALSE;
+
+ while (h->root.type == bfd_link_hash_indirect
+ || h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ /* If it was forced local, then clearly it's not dynamic. */
+ if (h->dynindx == -1)
+ return FALSE;
+ if (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL)
+ return FALSE;
+
+ /* Identify the cases where name binding rules say that a
+ visible symbol resolves locally. */
+ binding_stays_local_p = info->executable || info->symbolic;
+
+ switch (ELF_ST_VISIBILITY (h->other))
+ {
+ case STV_INTERNAL:
+ case STV_HIDDEN:
+ return FALSE;
+
+ case STV_PROTECTED:
+ /* Proper resolution for function pointer equality may require
+ that these symbols perhaps be resolved dynamically, even though
+ we should be resolving them to the current module. */
+ if (!ignore_protected)
+ binding_stays_local_p = TRUE;
+ break;
+
+ default:
+ break;
+ }
+
+ /* If it isn't defined locally, then clearly it's dynamic. */
+ if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
+ return TRUE;
+
+ /* Otherwise, the symbol is dynamic if binding rules don't tell
+ us that it remains local. */
+ return !binding_stays_local_p;
+}
+
+/* Return true if the symbol referred to by H should be considered
+ to resolve local to the current module, and false otherwise. Differs
+ from (the inverse of) _bfd_elf_dynamic_symbol_p in the treatment of
+ undefined symbols and weak symbols. */
+
+bfd_boolean
+_bfd_elf_symbol_refs_local_p (struct elf_link_hash_entry *h,
+ struct bfd_link_info *info,
+ bfd_boolean local_protected)
+{
+ /* If it's a local sym, of course we resolve locally. */
+ if (h == NULL)
+ return TRUE;
+
+ /* If we don't have a definition in a regular file, then we can't
+ resolve locally. The sym is either undefined or dynamic. */
+ if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
+ return FALSE;
+
+ /* Forced local symbols resolve locally. */
+ if ((h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0)
+ return TRUE;
+
+ /* As do non-dynamic symbols. */
+ if (h->dynindx == -1)
+ return TRUE;
+
+ /* At this point, we know the symbol is defined and dynamic. In an
+ executable it must resolve locally, likewise when building symbolic
+ shared libraries. */
+ if (info->executable || info->symbolic)
+ return TRUE;
+
+ /* Now deal with defined dynamic symbols in shared libraries. Ones
+ with default visibility might not resolve locally. */
+ if (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
+ return FALSE;
+
+ /* However, STV_HIDDEN or STV_INTERNAL ones must be local. */
+ if (ELF_ST_VISIBILITY (h->other) != STV_PROTECTED)
+ return TRUE;
+
+ /* Function pointer equality tests may require that STV_PROTECTED
+ symbols be treated as dynamic symbols, even when we know that the
+ dynamic linker will resolve them locally. */
+ return local_protected;
+}
+
+/* Caches some TLS segment info, and ensures that the TLS segment vma is
+ aligned. Returns the first TLS output section. */
+
+struct bfd_section *
+_bfd_elf_tls_setup (bfd *obfd, struct bfd_link_info *info)
+{
+ struct bfd_section *sec, *tls;
+ unsigned int align = 0;
+
+ for (sec = obfd->sections; sec != NULL; sec = sec->next)
+ if ((sec->flags & SEC_THREAD_LOCAL) != 0)
+ break;
+ tls = sec;
+
+ for (; sec != NULL && (sec->flags & SEC_THREAD_LOCAL) != 0; sec = sec->next)
+ if (sec->alignment_power > align)
+ align = sec->alignment_power;
+
+ elf_hash_table (info)->tls_sec = tls;
+
+ /* Ensure the alignment of the first section is the largest alignment,
+ so that the tls segment starts aligned. */
+ if (tls != NULL)
+ tls->alignment_power = align;
+
+ return tls;
+}
+
+/* Return TRUE iff this is a non-common, definition of a non-function symbol. */
+static bfd_boolean
+is_global_data_symbol_definition (bfd *abfd ATTRIBUTE_UNUSED,
+ Elf_Internal_Sym *sym)
+{
+ /* Local symbols do not count, but target specific ones might. */
+ if (ELF_ST_BIND (sym->st_info) != STB_GLOBAL
+ && ELF_ST_BIND (sym->st_info) < STB_LOOS)
+ return FALSE;
+
+ /* Function symbols do not count. */
+ if (ELF_ST_TYPE (sym->st_info) == STT_FUNC)
+ return FALSE;
+
+ /* If the section is undefined, then so is the symbol. */
+ if (sym->st_shndx == SHN_UNDEF)
+ return FALSE;
+
+ /* If the symbol is defined in the common section, then
+ it is a common definition and so does not count. */
+ if (sym->st_shndx == SHN_COMMON)
+ return FALSE;
+
+ /* If the symbol is in a target specific section then we
+ must rely upon the backend to tell us what it is. */
+ if (sym->st_shndx >= SHN_LORESERVE && sym->st_shndx < SHN_ABS)
+ /* FIXME - this function is not coded yet:
+
+ return _bfd_is_global_symbol_definition (abfd, sym);
+
+ Instead for now assume that the definition is not global,
+ Even if this is wrong, at least the linker will behave
+ in the same way that it used to do. */
+ return FALSE;
+
+ return TRUE;
+}
+
+/* Search the symbol table of the archive element of the archive ABFD
+ whose archive map contains a mention of SYMDEF, and determine if
+ the symbol is defined in this element. */
+static bfd_boolean
+elf_link_is_defined_archive_symbol (bfd * abfd, carsym * symdef)
+{
+ Elf_Internal_Shdr * hdr;
+ bfd_size_type symcount;
+ bfd_size_type extsymcount;
+ bfd_size_type extsymoff;
+ Elf_Internal_Sym *isymbuf;
+ Elf_Internal_Sym *isym;
+ Elf_Internal_Sym *isymend;
+ bfd_boolean result;
+
+ abfd = _bfd_get_elt_at_filepos (abfd, symdef->file_offset);
+ if (abfd == NULL)
+ return FALSE;
+
+ if (! bfd_check_format (abfd, bfd_object))
+ return FALSE;
+
+ /* If we have already included the element containing this symbol in the
+ link then we do not need to include it again. Just claim that any symbol
+ it contains is not a definition, so that our caller will not decide to
+ (re)include this element. */
+ if (abfd->archive_pass)
+ return FALSE;
+
+ /* Select the appropriate symbol table. */
+ if ((abfd->flags & DYNAMIC) == 0 || elf_dynsymtab (abfd) == 0)
+ hdr = &elf_tdata (abfd)->symtab_hdr;
+ else
+ hdr = &elf_tdata (abfd)->dynsymtab_hdr;
+
+ symcount = hdr->sh_size / get_elf_backend_data (abfd)->s->sizeof_sym;
+
+ /* The sh_info field of the symtab header tells us where the
+ external symbols start. We don't care about the local symbols. */
+ if (elf_bad_symtab (abfd))
+ {
+ extsymcount = symcount;
+ extsymoff = 0;
+ }
+ else
+ {
+ extsymcount = symcount - hdr->sh_info;
+ extsymoff = hdr->sh_info;
+ }
+
+ if (extsymcount == 0)
+ return FALSE;
+
+ /* Read in the symbol table. */
+ isymbuf = bfd_elf_get_elf_syms (abfd, hdr, extsymcount, extsymoff,
+ NULL, NULL, NULL);
+ if (isymbuf == NULL)
+ return FALSE;
+
+ /* Scan the symbol table looking for SYMDEF. */
+ result = FALSE;
+ for (isym = isymbuf, isymend = isymbuf + extsymcount; isym < isymend; isym++)
+ {
+ const char *name;
+
+ name = bfd_elf_string_from_elf_section (abfd, hdr->sh_link,
+ isym->st_name);
+ if (name == NULL)
+ break;
+
+ if (strcmp (name, symdef->name) == 0)
+ {
+ result = is_global_data_symbol_definition (abfd, isym);
+ break;
+ }
+ }
+
+ free (isymbuf);
+
+ return result;
+}
+
+/* Add an entry to the .dynamic table. */
+
+bfd_boolean
+_bfd_elf_add_dynamic_entry (struct bfd_link_info *info,
+ bfd_vma tag,
+ bfd_vma val)
+{
+ struct elf_link_hash_table *hash_table;
+ const struct elf_backend_data *bed;
+ asection *s;
+ bfd_size_type newsize;
+ bfd_byte *newcontents;
+ Elf_Internal_Dyn dyn;
+
+ hash_table = elf_hash_table (info);
+ if (! is_elf_hash_table (hash_table))
+ return FALSE;
+
+ bed = get_elf_backend_data (hash_table->dynobj);
+ s = bfd_get_section_by_name (hash_table->dynobj, ".dynamic");
+ BFD_ASSERT (s != NULL);
+
+ newsize = s->_raw_size + bed->s->sizeof_dyn;
+ newcontents = bfd_realloc (s->contents, newsize);
+ if (newcontents == NULL)
+ return FALSE;
+
+ dyn.d_tag = tag;
+ dyn.d_un.d_val = val;
+ bed->s->swap_dyn_out (hash_table->dynobj, &dyn, newcontents + s->_raw_size);
+
+ s->_raw_size = newsize;
+ s->contents = newcontents;
+
+ return TRUE;
+}
+
+/* Add a DT_NEEDED entry for this dynamic object if DO_IT is true,
+ otherwise just check whether one already exists. Returns -1 on error,
+ 1 if a DT_NEEDED tag already exists, and 0 on success. */
+
+static int
+elf_add_dt_needed_tag (struct bfd_link_info *info,
+ const char *soname,
+ bfd_boolean do_it)
+{
+ struct elf_link_hash_table *hash_table;
+ bfd_size_type oldsize;
+ bfd_size_type strindex;
+
+ hash_table = elf_hash_table (info);
+ oldsize = _bfd_elf_strtab_size (hash_table->dynstr);
+ strindex = _bfd_elf_strtab_add (hash_table->dynstr, soname, FALSE);
+ if (strindex == (bfd_size_type) -1)
+ return -1;
+
+ if (oldsize == _bfd_elf_strtab_size (hash_table->dynstr))
+ {
+ asection *sdyn;
+ const struct elf_backend_data *bed;
+ bfd_byte *extdyn;
+
+ bed = get_elf_backend_data (hash_table->dynobj);
+ sdyn = bfd_get_section_by_name (hash_table->dynobj, ".dynamic");
+ BFD_ASSERT (sdyn != NULL);
+
+ for (extdyn = sdyn->contents;
+ extdyn < sdyn->contents + sdyn->_raw_size;
+ extdyn += bed->s->sizeof_dyn)
+ {
+ Elf_Internal_Dyn dyn;
+
+ bed->s->swap_dyn_in (hash_table->dynobj, extdyn, &dyn);
+ if (dyn.d_tag == DT_NEEDED
+ && dyn.d_un.d_val == strindex)
+ {
+ _bfd_elf_strtab_delref (hash_table->dynstr, strindex);
+ return 1;
+ }
+ }
+ }
+
+ if (do_it)
+ {
+ if (!_bfd_elf_add_dynamic_entry (info, DT_NEEDED, strindex))
+ return -1;
+ }
+ else
+ /* We were just checking for existence of the tag. */
+ _bfd_elf_strtab_delref (hash_table->dynstr, strindex);
+
+ return 0;
+}
+
+/* Sort symbol by value and section. */
+static int
+elf_sort_symbol (const void *arg1, const void *arg2)
+{
+ const struct elf_link_hash_entry *h1;
+ const struct elf_link_hash_entry *h2;
+ bfd_signed_vma vdiff;
+
+ h1 = *(const struct elf_link_hash_entry **) arg1;
+ h2 = *(const struct elf_link_hash_entry **) arg2;
+ vdiff = h1->root.u.def.value - h2->root.u.def.value;
+ if (vdiff != 0)
+ return vdiff > 0 ? 1 : -1;
+ else
+ {
+ long sdiff = h1->root.u.def.section - h2->root.u.def.section;
+ if (sdiff != 0)
+ return sdiff > 0 ? 1 : -1;
+ }
+ return 0;
+}
+
+/* This function is used to adjust offsets into .dynstr for
+ dynamic symbols. This is called via elf_link_hash_traverse. */
+
+static bfd_boolean
+elf_adjust_dynstr_offsets (struct elf_link_hash_entry *h, void *data)
+{
+ struct elf_strtab_hash *dynstr = data;
+
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ if (h->dynindx != -1)
+ h->dynstr_index = _bfd_elf_strtab_offset (dynstr, h->dynstr_index);
+ return TRUE;
+}
+
+/* Assign string offsets in .dynstr, update all structures referencing
+ them. */
+
+static bfd_boolean
+elf_finalize_dynstr (bfd *output_bfd, struct bfd_link_info *info)
+{
+ struct elf_link_hash_table *hash_table = elf_hash_table (info);
+ struct elf_link_local_dynamic_entry *entry;
+ struct elf_strtab_hash *dynstr = hash_table->dynstr;
+ bfd *dynobj = hash_table->dynobj;
+ asection *sdyn;
+ bfd_size_type size;
+ const struct elf_backend_data *bed;
+ bfd_byte *extdyn;
+
+ _bfd_elf_strtab_finalize (dynstr);
+ size = _bfd_elf_strtab_size (dynstr);
+
+ bed = get_elf_backend_data (dynobj);
+ sdyn = bfd_get_section_by_name (dynobj, ".dynamic");
+ BFD_ASSERT (sdyn != NULL);
+
+ /* Update all .dynamic entries referencing .dynstr strings. */
+ for (extdyn = sdyn->contents;
+ extdyn < sdyn->contents + sdyn->_raw_size;
+ extdyn += bed->s->sizeof_dyn)
+ {
+ Elf_Internal_Dyn dyn;
+
+ bed->s->swap_dyn_in (dynobj, extdyn, &dyn);
+ switch (dyn.d_tag)
+ {
+ case DT_STRSZ:
+ dyn.d_un.d_val = size;
+ break;
+ case DT_NEEDED:
+ case DT_SONAME:
+ case DT_RPATH:
+ case DT_RUNPATH:
+ case DT_FILTER:
+ case DT_AUXILIARY:
+ dyn.d_un.d_val = _bfd_elf_strtab_offset (dynstr, dyn.d_un.d_val);
+ break;
+ default:
+ continue;
+ }
+ bed->s->swap_dyn_out (dynobj, &dyn, extdyn);
+ }
+
+ /* Now update local dynamic symbols. */
+ for (entry = hash_table->dynlocal; entry ; entry = entry->next)
+ entry->isym.st_name = _bfd_elf_strtab_offset (dynstr,
+ entry->isym.st_name);
+
+ /* And the rest of dynamic symbols. */
+ elf_link_hash_traverse (hash_table, elf_adjust_dynstr_offsets, dynstr);
+
+ /* Adjust version definitions. */
+ if (elf_tdata (output_bfd)->cverdefs)
{
asection *s;
- bfd_size_type amt = sizeof (elf_linker_section_t);
+ bfd_byte *p;
+ bfd_size_type i;
+ Elf_Internal_Verdef def;
+ Elf_Internal_Verdaux defaux;
- lsect = (elf_linker_section_t *) bfd_alloc (dynobj, amt);
+ s = bfd_get_section_by_name (dynobj, ".gnu.version_d");
+ p = s->contents;
+ do
+ {
+ _bfd_elf_swap_verdef_in (output_bfd, (Elf_External_Verdef *) p,
+ &def);
+ p += sizeof (Elf_External_Verdef);
+ for (i = 0; i < def.vd_cnt; ++i)
+ {
+ _bfd_elf_swap_verdaux_in (output_bfd,
+ (Elf_External_Verdaux *) p, &defaux);
+ defaux.vda_name = _bfd_elf_strtab_offset (dynstr,
+ defaux.vda_name);
+ _bfd_elf_swap_verdaux_out (output_bfd,
+ &defaux, (Elf_External_Verdaux *) p);
+ p += sizeof (Elf_External_Verdaux);
+ }
+ }
+ while (def.vd_next);
+ }
- *lsect = *defaults;
- elf_linker_section (dynobj, which) = lsect;
- lsect->which = which;
- lsect->hole_written_p = false;
+ /* Adjust version references. */
+ if (elf_tdata (output_bfd)->verref)
+ {
+ asection *s;
+ bfd_byte *p;
+ bfd_size_type i;
+ Elf_Internal_Verneed need;
+ Elf_Internal_Vernaux needaux;
- /* See if the sections already exist */
- lsect->section = s = bfd_get_section_by_name (dynobj, lsect->name);
- if (!s || (s->flags & defaults->flags) != defaults->flags)
+ s = bfd_get_section_by_name (dynobj, ".gnu.version_r");
+ p = s->contents;
+ do
{
- lsect->section = s = bfd_make_section_anyway (dynobj, lsect->name);
+ _bfd_elf_swap_verneed_in (output_bfd, (Elf_External_Verneed *) p,
+ &need);
+ need.vn_file = _bfd_elf_strtab_offset (dynstr, need.vn_file);
+ _bfd_elf_swap_verneed_out (output_bfd, &need,
+ (Elf_External_Verneed *) p);
+ p += sizeof (Elf_External_Verneed);
+ for (i = 0; i < need.vn_cnt; ++i)
+ {
+ _bfd_elf_swap_vernaux_in (output_bfd,
+ (Elf_External_Vernaux *) p, &needaux);
+ needaux.vna_name = _bfd_elf_strtab_offset (dynstr,
+ needaux.vna_name);
+ _bfd_elf_swap_vernaux_out (output_bfd,
+ &needaux,
+ (Elf_External_Vernaux *) p);
+ p += sizeof (Elf_External_Vernaux);
+ }
+ }
+ while (need.vn_next);
+ }
- if (s == NULL)
- return (elf_linker_section_t *)0;
+ return TRUE;
+}
+
+/* Add symbols from an ELF object file to the linker hash table. */
- bfd_set_section_flags (dynobj, s, defaults->flags);
- bfd_set_section_alignment (dynobj, s, lsect->alignment);
+static bfd_boolean
+elf_link_add_object_symbols (bfd *abfd, struct bfd_link_info *info)
+{
+ bfd_boolean (*add_symbol_hook)
+ (bfd *, struct bfd_link_info *, Elf_Internal_Sym *,
+ const char **, flagword *, asection **, bfd_vma *);
+ bfd_boolean (*check_relocs)
+ (bfd *, struct bfd_link_info *, asection *, const Elf_Internal_Rela *);
+ bfd_boolean collect;
+ Elf_Internal_Shdr *hdr;
+ bfd_size_type symcount;
+ bfd_size_type extsymcount;
+ bfd_size_type extsymoff;
+ struct elf_link_hash_entry **sym_hash;
+ bfd_boolean dynamic;
+ Elf_External_Versym *extversym = NULL;
+ Elf_External_Versym *ever;
+ struct elf_link_hash_entry *weaks;
+ struct elf_link_hash_entry **nondeflt_vers = NULL;
+ bfd_size_type nondeflt_vers_cnt = 0;
+ Elf_Internal_Sym *isymbuf = NULL;
+ Elf_Internal_Sym *isym;
+ Elf_Internal_Sym *isymend;
+ const struct elf_backend_data *bed;
+ bfd_boolean add_needed;
+ struct elf_link_hash_table * hash_table;
+ bfd_size_type amt;
+
+ hash_table = elf_hash_table (info);
+
+ bed = get_elf_backend_data (abfd);
+ add_symbol_hook = bed->elf_add_symbol_hook;
+ collect = bed->collect;
+
+ if ((abfd->flags & DYNAMIC) == 0)
+ dynamic = FALSE;
+ else
+ {
+ dynamic = TRUE;
+
+ /* You can't use -r against a dynamic object. Also, there's no
+ hope of using a dynamic object which does not exactly match
+ the format of the output file. */
+ if (info->relocatable
+ || !is_elf_hash_table (hash_table)
+ || hash_table->root.creator != abfd->xvec)
+ {
+ bfd_set_error (bfd_error_invalid_operation);
+ goto error_return;
}
- else if (bfd_get_section_alignment (dynobj, s) < lsect->alignment)
- bfd_set_section_alignment (dynobj, s, lsect->alignment);
+ }
- s->_raw_size = align_power (s->_raw_size, lsect->alignment);
+ /* As a GNU extension, any input sections which are named
+ .gnu.warning.SYMBOL are treated as warning symbols for the given
+ symbol. This differs from .gnu.warning sections, which generate
+ warnings when they are included in an output file. */
+ if (info->executable)
+ {
+ asection *s;
- /* Is there a hole we have to provide? If so check whether the segment is
- too big already */
- if (lsect->hole_size)
+ for (s = abfd->sections; s != NULL; s = s->next)
{
- lsect->hole_offset = s->_raw_size;
- s->_raw_size += lsect->hole_size;
- if (lsect->hole_offset > lsect->max_hole_offset)
+ const char *name;
+
+ name = bfd_get_section_name (abfd, s);
+ if (strncmp (name, ".gnu.warning.", sizeof ".gnu.warning." - 1) == 0)
{
- (*_bfd_error_handler) (_("%s: Section %s is too large to add hole of %ld bytes"),
- bfd_get_filename (abfd),
- lsect->name,
- (long) lsect->hole_size);
+ char *msg;
+ bfd_size_type sz;
+ bfd_size_type prefix_len;
+ const char * gnu_warning_prefix = _("warning: ");
- bfd_set_error (bfd_error_bad_value);
- return (elf_linker_section_t *)0;
+ name += sizeof ".gnu.warning." - 1;
+
+ /* If this is a shared object, then look up the symbol
+ in the hash table. If it is there, and it is already
+ been defined, then we will not be using the entry
+ from this shared object, so we don't need to warn.
+ FIXME: If we see the definition in a regular object
+ later on, we will warn, but we shouldn't. The only
+ fix is to keep track of what warnings we are supposed
+ to emit, and then handle them all at the end of the
+ link. */
+ if (dynamic)
+ {
+ struct elf_link_hash_entry *h;
+
+ h = elf_link_hash_lookup (hash_table, name,
+ FALSE, FALSE, TRUE);
+
+ /* FIXME: What about bfd_link_hash_common? */
+ if (h != NULL
+ && (h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak))
+ {
+ /* We don't want to issue this warning. Clobber
+ the section size so that the warning does not
+ get copied into the output file. */
+ s->_raw_size = 0;
+ continue;
+ }
+ }
+
+ sz = bfd_section_size (abfd, s);
+ prefix_len = strlen (gnu_warning_prefix);
+ msg = bfd_alloc (abfd, prefix_len + sz + 1);
+ if (msg == NULL)
+ goto error_return;
+
+ strcpy (msg, gnu_warning_prefix);
+ if (! bfd_get_section_contents (abfd, s, msg + prefix_len, 0, sz))
+ goto error_return;
+
+ msg[prefix_len + sz] = '\0';
+
+ if (! (_bfd_generic_link_add_one_symbol
+ (info, abfd, name, BSF_WARNING, s, 0, msg,
+ FALSE, collect, NULL)))
+ goto error_return;
+
+ if (! info->relocatable)
+ {
+ /* Clobber the section size so that the warning does
+ not get copied into the output file. */
+ s->_raw_size = 0;
+ }
}
}
+ }
-#ifdef DEBUG
- fprintf (stderr, "Creating section %s, current size = %ld\n",
- lsect->name, (long)s->_raw_size);
-#endif
+ add_needed = TRUE;
+ if (! dynamic)
+ {
+ /* If we are creating a shared library, create all the dynamic
+ sections immediately. We need to attach them to something,
+ so we attach them to this BFD, provided it is the right
+ format. FIXME: If there are no input BFD's of the same
+ format as the output, we can't make a shared library. */
+ if (info->shared
+ && is_elf_hash_table (hash_table)
+ && hash_table->root.creator == abfd->xvec
+ && ! hash_table->dynamic_sections_created)
+ {
+ if (! _bfd_elf_link_create_dynamic_sections (abfd, info))
+ goto error_return;
+ }
+ }
+ else if (!is_elf_hash_table (hash_table))
+ goto error_return;
+ else
+ {
+ asection *s;
+ const char *soname = NULL;
+ struct bfd_link_needed_list *rpath = NULL, *runpath = NULL;
+ int ret;
+
+ /* ld --just-symbols and dynamic objects don't mix very well.
+ Test for --just-symbols by looking at info set up by
+ _bfd_elf_link_just_syms. */
+ if ((s = abfd->sections) != NULL
+ && s->sec_info_type == ELF_INFO_TYPE_JUST_SYMS)
+ goto error_return;
+
+ /* If this dynamic lib was specified on the command line with
+ --as-needed in effect, then we don't want to add a DT_NEEDED
+ tag unless the lib is actually used. Similary for libs brought
+ in by another lib's DT_NEEDED. */
+ add_needed = elf_dyn_lib_class (abfd) == DYN_NORMAL;
+
+ s = bfd_get_section_by_name (abfd, ".dynamic");
+ if (s != NULL)
+ {
+ bfd_byte *dynbuf;
+ bfd_byte *extdyn;
+ int elfsec;
+ unsigned long shlink;
+
+ dynbuf = bfd_malloc (s->_raw_size);
+ if (dynbuf == NULL)
+ goto error_return;
+
+ if (! bfd_get_section_contents (abfd, s, dynbuf, 0, s->_raw_size))
+ goto error_free_dyn;
+
+ elfsec = _bfd_elf_section_from_bfd_section (abfd, s);
+ if (elfsec == -1)
+ goto error_free_dyn;
+ shlink = elf_elfsections (abfd)[elfsec]->sh_link;
+
+ for (extdyn = dynbuf;
+ extdyn < dynbuf + s->_raw_size;
+ extdyn += bed->s->sizeof_dyn)
+ {
+ Elf_Internal_Dyn dyn;
+
+ bed->s->swap_dyn_in (abfd, extdyn, &dyn);
+ if (dyn.d_tag == DT_SONAME)
+ {
+ unsigned int tagv = dyn.d_un.d_val;
+ soname = bfd_elf_string_from_elf_section (abfd, shlink, tagv);
+ if (soname == NULL)
+ goto error_free_dyn;
+ }
+ if (dyn.d_tag == DT_NEEDED)
+ {
+ struct bfd_link_needed_list *n, **pn;
+ char *fnm, *anm;
+ unsigned int tagv = dyn.d_un.d_val;
+
+ amt = sizeof (struct bfd_link_needed_list);
+ n = bfd_alloc (abfd, amt);
+ fnm = bfd_elf_string_from_elf_section (abfd, shlink, tagv);
+ if (n == NULL || fnm == NULL)
+ goto error_free_dyn;
+ amt = strlen (fnm) + 1;
+ anm = bfd_alloc (abfd, amt);
+ if (anm == NULL)
+ goto error_free_dyn;
+ memcpy (anm, fnm, amt);
+ n->name = anm;
+ n->by = abfd;
+ n->next = NULL;
+ for (pn = & hash_table->needed;
+ *pn != NULL;
+ pn = &(*pn)->next)
+ ;
+ *pn = n;
+ }
+ if (dyn.d_tag == DT_RUNPATH)
+ {
+ struct bfd_link_needed_list *n, **pn;
+ char *fnm, *anm;
+ unsigned int tagv = dyn.d_un.d_val;
+
+ amt = sizeof (struct bfd_link_needed_list);
+ n = bfd_alloc (abfd, amt);
+ fnm = bfd_elf_string_from_elf_section (abfd, shlink, tagv);
+ if (n == NULL || fnm == NULL)
+ goto error_free_dyn;
+ amt = strlen (fnm) + 1;
+ anm = bfd_alloc (abfd, amt);
+ if (anm == NULL)
+ goto error_free_dyn;
+ memcpy (anm, fnm, amt);
+ n->name = anm;
+ n->by = abfd;
+ n->next = NULL;
+ for (pn = & runpath;
+ *pn != NULL;
+ pn = &(*pn)->next)
+ ;
+ *pn = n;
+ }
+ /* Ignore DT_RPATH if we have seen DT_RUNPATH. */
+ if (!runpath && dyn.d_tag == DT_RPATH)
+ {
+ struct bfd_link_needed_list *n, **pn;
+ char *fnm, *anm;
+ unsigned int tagv = dyn.d_un.d_val;
+
+ amt = sizeof (struct bfd_link_needed_list);
+ n = bfd_alloc (abfd, amt);
+ fnm = bfd_elf_string_from_elf_section (abfd, shlink, tagv);
+ if (n == NULL || fnm == NULL)
+ goto error_free_dyn;
+ amt = strlen (fnm) + 1;
+ anm = bfd_alloc (abfd, amt);
+ if (anm == NULL)
+ {
+ error_free_dyn:
+ free (dynbuf);
+ goto error_return;
+ }
+ memcpy (anm, fnm, amt);
+ n->name = anm;
+ n->by = abfd;
+ n->next = NULL;
+ for (pn = & rpath;
+ *pn != NULL;
+ pn = &(*pn)->next)
+ ;
+ *pn = n;
+ }
+ }
+
+ free (dynbuf);
+ }
+
+ /* DT_RUNPATH overrides DT_RPATH. Do _NOT_ bfd_release, as that
+ frees all more recently bfd_alloc'd blocks as well. */
+ if (runpath)
+ rpath = runpath;
+
+ if (rpath)
+ {
+ struct bfd_link_needed_list **pn;
+ for (pn = & hash_table->runpath;
+ *pn != NULL;
+ pn = &(*pn)->next)
+ ;
+ *pn = rpath;
+ }
+
+ /* We do not want to include any of the sections in a dynamic
+ object in the output file. We hack by simply clobbering the
+ list of sections in the BFD. This could be handled more
+ cleanly by, say, a new section flag; the existing
+ SEC_NEVER_LOAD flag is not the one we want, because that one
+ still implies that the section takes up space in the output
+ file. */
+ bfd_section_list_clear (abfd);
+
+ /* If this is the first dynamic object found in the link, create
+ the special sections required for dynamic linking. */
+ if (! _bfd_elf_link_create_dynamic_sections (abfd, info))
+ goto error_return;
+
+ /* Find the name to use in a DT_NEEDED entry that refers to this
+ object. If the object has a DT_SONAME entry, we use it.
+ Otherwise, if the generic linker stuck something in
+ elf_dt_name, we use that. Otherwise, we just use the file
+ name. */
+ if (soname == NULL || *soname == '\0')
+ {
+ soname = elf_dt_name (abfd);
+ if (soname == NULL || *soname == '\0')
+ soname = bfd_get_filename (abfd);
+ }
+
+ /* Save the SONAME because sometimes the linker emulation code
+ will need to know it. */
+ elf_dt_name (abfd) = soname;
+
+ ret = elf_add_dt_needed_tag (info, soname, add_needed);
+ if (ret < 0)
+ goto error_return;
+
+ /* If we have already included this dynamic object in the
+ link, just ignore it. There is no reason to include a
+ particular dynamic object more than once. */
+ if (ret > 0)
+ return TRUE;
+ }
+
+ /* If this is a dynamic object, we always link against the .dynsym
+ symbol table, not the .symtab symbol table. The dynamic linker
+ will only see the .dynsym symbol table, so there is no reason to
+ look at .symtab for a dynamic object. */
+
+ if (! dynamic || elf_dynsymtab (abfd) == 0)
+ hdr = &elf_tdata (abfd)->symtab_hdr;
+ else
+ hdr = &elf_tdata (abfd)->dynsymtab_hdr;
+
+ symcount = hdr->sh_size / bed->s->sizeof_sym;
+
+ /* The sh_info field of the symtab header tells us where the
+ external symbols start. We don't care about the local symbols at
+ this point. */
+ if (elf_bad_symtab (abfd))
+ {
+ extsymcount = symcount;
+ extsymoff = 0;
+ }
+ else
+ {
+ extsymcount = symcount - hdr->sh_info;
+ extsymoff = hdr->sh_info;
+ }
+
+ sym_hash = NULL;
+ if (extsymcount != 0)
+ {
+ isymbuf = bfd_elf_get_elf_syms (abfd, hdr, extsymcount, extsymoff,
+ NULL, NULL, NULL);
+ if (isymbuf == NULL)
+ goto error_return;
+
+ /* We store a pointer to the hash table entry for each external
+ symbol. */
+ amt = extsymcount * sizeof (struct elf_link_hash_entry *);
+ sym_hash = bfd_alloc (abfd, amt);
+ if (sym_hash == NULL)
+ goto error_free_sym;
+ elf_sym_hashes (abfd) = sym_hash;
+ }
+
+ if (dynamic)
+ {
+ /* Read in any version definitions. */
+ if (! _bfd_elf_slurp_version_tables (abfd))
+ goto error_free_sym;
+
+ /* Read in the symbol versions, but don't bother to convert them
+ to internal format. */
+ if (elf_dynversym (abfd) != 0)
+ {
+ Elf_Internal_Shdr *versymhdr;
+
+ versymhdr = &elf_tdata (abfd)->dynversym_hdr;
+ extversym = bfd_malloc (versymhdr->sh_size);
+ if (extversym == NULL)
+ goto error_free_sym;
+ amt = versymhdr->sh_size;
+ if (bfd_seek (abfd, versymhdr->sh_offset, SEEK_SET) != 0
+ || bfd_bread (extversym, amt, abfd) != amt)
+ goto error_free_vers;
+ }
+ }
+
+ weaks = NULL;
+
+ ever = extversym != NULL ? extversym + extsymoff : NULL;
+ for (isym = isymbuf, isymend = isymbuf + extsymcount;
+ isym < isymend;
+ isym++, sym_hash++, ever = (ever != NULL ? ever + 1 : NULL))
+ {
+ int bind;
+ bfd_vma value;
+ asection *sec;
+ flagword flags;
+ const char *name;
+ struct elf_link_hash_entry *h;
+ bfd_boolean definition;
+ bfd_boolean size_change_ok;
+ bfd_boolean type_change_ok;
+ bfd_boolean new_weakdef;
+ bfd_boolean override;
+ unsigned int old_alignment;
+ bfd *old_bfd;
+
+ override = FALSE;
+
+ flags = BSF_NO_FLAGS;
+ sec = NULL;
+ value = isym->st_value;
+ *sym_hash = NULL;
+
+ bind = ELF_ST_BIND (isym->st_info);
+ if (bind == STB_LOCAL)
+ {
+ /* This should be impossible, since ELF requires that all
+ global symbols follow all local symbols, and that sh_info
+ point to the first global symbol. Unfortunately, Irix 5
+ screws this up. */
+ continue;
+ }
+ else if (bind == STB_GLOBAL)
+ {
+ if (isym->st_shndx != SHN_UNDEF
+ && isym->st_shndx != SHN_COMMON)
+ flags = BSF_GLOBAL;
+ }
+ else if (bind == STB_WEAK)
+ flags = BSF_WEAK;
+ else
+ {
+ /* Leave it up to the processor backend. */
+ }
+
+ if (isym->st_shndx == SHN_UNDEF)
+ sec = bfd_und_section_ptr;
+ else if (isym->st_shndx < SHN_LORESERVE || isym->st_shndx > SHN_HIRESERVE)
+ {
+ sec = bfd_section_from_elf_index (abfd, isym->st_shndx);
+ if (sec == NULL)
+ sec = bfd_abs_section_ptr;
+ else if ((abfd->flags & (EXEC_P | DYNAMIC)) != 0)
+ value -= sec->vma;
+ }
+ else if (isym->st_shndx == SHN_ABS)
+ sec = bfd_abs_section_ptr;
+ else if (isym->st_shndx == SHN_COMMON)
+ {
+ sec = bfd_com_section_ptr;
+ /* What ELF calls the size we call the value. What ELF
+ calls the value we call the alignment. */
+ value = isym->st_size;
+ }
+ else
+ {
+ /* Leave it up to the processor backend. */
+ }
+
+ name = bfd_elf_string_from_elf_section (abfd, hdr->sh_link,
+ isym->st_name);
+ if (name == NULL)
+ goto error_free_vers;
+
+ if (isym->st_shndx == SHN_COMMON
+ && ELF_ST_TYPE (isym->st_info) == STT_TLS)
+ {
+ asection *tcomm = bfd_get_section_by_name (abfd, ".tcommon");
+
+ if (tcomm == NULL)
+ {
+ tcomm = bfd_make_section (abfd, ".tcommon");
+ if (tcomm == NULL
+ || !bfd_set_section_flags (abfd, tcomm, (SEC_ALLOC
+ | SEC_IS_COMMON
+ | SEC_LINKER_CREATED
+ | SEC_THREAD_LOCAL)))
+ goto error_free_vers;
+ }
+ sec = tcomm;
+ }
+ else if (add_symbol_hook)
+ {
+ if (! (*add_symbol_hook) (abfd, info, isym, &name, &flags, &sec,
+ &value))
+ goto error_free_vers;
+
+ /* The hook function sets the name to NULL if this symbol
+ should be skipped for some reason. */
+ if (name == NULL)
+ continue;
+ }
- if (lsect->sym_name)
+ /* Sanity check that all possibilities were handled. */
+ if (sec == NULL)
+ {
+ bfd_set_error (bfd_error_bad_value);
+ goto error_free_vers;
+ }
+
+ if (bfd_is_und_section (sec)
+ || bfd_is_com_section (sec))
+ definition = FALSE;
+ else
+ definition = TRUE;
+
+ size_change_ok = FALSE;
+ type_change_ok = get_elf_backend_data (abfd)->type_change_ok;
+ old_alignment = 0;
+ old_bfd = NULL;
+
+ if (is_elf_hash_table (hash_table))
+ {
+ Elf_Internal_Versym iver;
+ unsigned int vernum = 0;
+ bfd_boolean skip;
+
+ if (ever != NULL)
+ {
+ _bfd_elf_swap_versym_in (abfd, ever, &iver);
+ vernum = iver.vs_vers & VERSYM_VERSION;
+
+ /* If this is a hidden symbol, or if it is not version
+ 1, we append the version name to the symbol name.
+ However, we do not modify a non-hidden absolute
+ symbol, because it might be the version symbol
+ itself. FIXME: What if it isn't? */
+ if ((iver.vs_vers & VERSYM_HIDDEN) != 0
+ || (vernum > 1 && ! bfd_is_abs_section (sec)))
+ {
+ const char *verstr;
+ size_t namelen, verlen, newlen;
+ char *newname, *p;
+
+ if (isym->st_shndx != SHN_UNDEF)
+ {
+ if (vernum > elf_tdata (abfd)->dynverdef_hdr.sh_info)
+ {
+ (*_bfd_error_handler)
+ (_("%s: %s: invalid version %u (max %d)"),
+ bfd_archive_filename (abfd), name, vernum,
+ elf_tdata (abfd)->dynverdef_hdr.sh_info);
+ bfd_set_error (bfd_error_bad_value);
+ goto error_free_vers;
+ }
+ else if (vernum > 1)
+ verstr =
+ elf_tdata (abfd)->verdef[vernum - 1].vd_nodename;
+ else
+ verstr = "";
+ }
+ else
+ {
+ /* We cannot simply test for the number of
+ entries in the VERNEED section since the
+ numbers for the needed versions do not start
+ at 0. */
+ Elf_Internal_Verneed *t;
+
+ verstr = NULL;
+ for (t = elf_tdata (abfd)->verref;
+ t != NULL;
+ t = t->vn_nextref)
+ {
+ Elf_Internal_Vernaux *a;
+
+ for (a = t->vn_auxptr; a != NULL; a = a->vna_nextptr)
+ {
+ if (a->vna_other == vernum)
+ {
+ verstr = a->vna_nodename;
+ break;
+ }
+ }
+ if (a != NULL)
+ break;
+ }
+ if (verstr == NULL)
+ {
+ (*_bfd_error_handler)
+ (_("%s: %s: invalid needed version %d"),
+ bfd_archive_filename (abfd), name, vernum);
+ bfd_set_error (bfd_error_bad_value);
+ goto error_free_vers;
+ }
+ }
+
+ namelen = strlen (name);
+ verlen = strlen (verstr);
+ newlen = namelen + verlen + 2;
+ if ((iver.vs_vers & VERSYM_HIDDEN) == 0
+ && isym->st_shndx != SHN_UNDEF)
+ ++newlen;
+
+ newname = bfd_alloc (abfd, newlen);
+ if (newname == NULL)
+ goto error_free_vers;
+ memcpy (newname, name, namelen);
+ p = newname + namelen;
+ *p++ = ELF_VER_CHR;
+ /* If this is a defined non-hidden version symbol,
+ we add another @ to the name. This indicates the
+ default version of the symbol. */
+ if ((iver.vs_vers & VERSYM_HIDDEN) == 0
+ && isym->st_shndx != SHN_UNDEF)
+ *p++ = ELF_VER_CHR;
+ memcpy (p, verstr, verlen + 1);
+
+ name = newname;
+ }
+ }
+
+ if (!_bfd_elf_merge_symbol (abfd, info, name, isym, &sec, &value,
+ sym_hash, &skip, &override,
+ &type_change_ok, &size_change_ok))
+ goto error_free_vers;
+
+ if (skip)
+ continue;
+
+ if (override)
+ definition = FALSE;
+
+ h = *sym_hash;
+ while (h->root.type == bfd_link_hash_indirect
+ || h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ /* Remember the old alignment if this is a common symbol, so
+ that we don't reduce the alignment later on. We can't
+ check later, because _bfd_generic_link_add_one_symbol
+ will set a default for the alignment which we want to
+ override. We also remember the old bfd where the existing
+ definition comes from. */
+ switch (h->root.type)
+ {
+ default:
+ break;
+
+ case bfd_link_hash_defined:
+ case bfd_link_hash_defweak:
+ old_bfd = h->root.u.def.section->owner;
+ break;
+
+ case bfd_link_hash_common:
+ old_bfd = h->root.u.c.p->section->owner;
+ old_alignment = h->root.u.c.p->alignment_power;
+ break;
+ }
+
+ if (elf_tdata (abfd)->verdef != NULL
+ && ! override
+ && vernum > 1
+ && definition)
+ h->verinfo.verdef = &elf_tdata (abfd)->verdef[vernum - 1];
+ }
+
+ if (! (_bfd_generic_link_add_one_symbol
+ (info, abfd, name, flags, sec, value, NULL, FALSE, collect,
+ (struct bfd_link_hash_entry **) sym_hash)))
+ goto error_free_vers;
+
+ h = *sym_hash;
+ while (h->root.type == bfd_link_hash_indirect
+ || h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+ *sym_hash = h;
+
+ new_weakdef = FALSE;
+ if (dynamic
+ && definition
+ && (flags & BSF_WEAK) != 0
+ && ELF_ST_TYPE (isym->st_info) != STT_FUNC
+ && is_elf_hash_table (hash_table)
+ && h->weakdef == NULL)
+ {
+ /* Keep a list of all weak defined non function symbols from
+ a dynamic object, using the weakdef field. Later in this
+ function we will set the weakdef field to the correct
+ value. We only put non-function symbols from dynamic
+ objects on this list, because that happens to be the only
+ time we need to know the normal symbol corresponding to a
+ weak symbol, and the information is time consuming to
+ figure out. If the weakdef field is not already NULL,
+ then this symbol was already defined by some previous
+ dynamic object, and we will be using that previous
+ definition anyhow. */
+
+ h->weakdef = weaks;
+ weaks = h;
+ new_weakdef = TRUE;
+ }
+
+ /* Set the alignment of a common symbol. */
+ if (isym->st_shndx == SHN_COMMON
+ && h->root.type == bfd_link_hash_common)
+ {
+ unsigned int align;
+
+ align = bfd_log2 (isym->st_value);
+ if (align > old_alignment
+ /* Permit an alignment power of zero if an alignment of one
+ is specified and no other alignments have been specified. */
+ || (isym->st_value == 1 && old_alignment == 0))
+ h->root.u.c.p->alignment_power = align;
+ else
+ h->root.u.c.p->alignment_power = old_alignment;
+ }
+
+ if (is_elf_hash_table (hash_table))
+ {
+ int old_flags;
+ bfd_boolean dynsym;
+ int new_flag;
+
+ /* Check the alignment when a common symbol is involved. This
+ can change when a common symbol is overridden by a normal
+ definition or a common symbol is ignored due to the old
+ normal definition. We need to make sure the maximum
+ alignment is maintained. */
+ if ((old_alignment || isym->st_shndx == SHN_COMMON)
+ && h->root.type != bfd_link_hash_common)
+ {
+ unsigned int common_align;
+ unsigned int normal_align;
+ unsigned int symbol_align;
+ bfd *normal_bfd;
+ bfd *common_bfd;
+
+ symbol_align = ffs (h->root.u.def.value) - 1;
+ if (h->root.u.def.section->owner != NULL
+ && (h->root.u.def.section->owner->flags & DYNAMIC) == 0)
+ {
+ normal_align = h->root.u.def.section->alignment_power;
+ if (normal_align > symbol_align)
+ normal_align = symbol_align;
+ }
+ else
+ normal_align = symbol_align;
+
+ if (old_alignment)
+ {
+ common_align = old_alignment;
+ common_bfd = old_bfd;
+ normal_bfd = abfd;
+ }
+ else
+ {
+ common_align = bfd_log2 (isym->st_value);
+ common_bfd = abfd;
+ normal_bfd = old_bfd;
+ }
+
+ if (normal_align < common_align)
+ (*_bfd_error_handler)
+ (_("Warning: alignment %u of symbol `%s' in %s is smaller than %u in %s"),
+ 1 << normal_align,
+ name,
+ bfd_archive_filename (normal_bfd),
+ 1 << common_align,
+ bfd_archive_filename (common_bfd));
+ }
+
+ /* Remember the symbol size and type. */
+ if (isym->st_size != 0
+ && (definition || h->size == 0))
+ {
+ if (h->size != 0 && h->size != isym->st_size && ! size_change_ok)
+ (*_bfd_error_handler)
+ (_("Warning: size of symbol `%s' changed from %lu in %s to %lu in %s"),
+ name, (unsigned long) h->size,
+ bfd_archive_filename (old_bfd),
+ (unsigned long) isym->st_size,
+ bfd_archive_filename (abfd));
+
+ h->size = isym->st_size;
+ }
+
+ /* If this is a common symbol, then we always want H->SIZE
+ to be the size of the common symbol. The code just above
+ won't fix the size if a common symbol becomes larger. We
+ don't warn about a size change here, because that is
+ covered by --warn-common. */
+ if (h->root.type == bfd_link_hash_common)
+ h->size = h->root.u.c.size;
+
+ if (ELF_ST_TYPE (isym->st_info) != STT_NOTYPE
+ && (definition || h->type == STT_NOTYPE))
+ {
+ if (h->type != STT_NOTYPE
+ && h->type != ELF_ST_TYPE (isym->st_info)
+ && ! type_change_ok)
+ (*_bfd_error_handler)
+ (_("Warning: type of symbol `%s' changed from %d to %d in %s"),
+ name, h->type, ELF_ST_TYPE (isym->st_info),
+ bfd_archive_filename (abfd));
+
+ h->type = ELF_ST_TYPE (isym->st_info);
+ }
+
+ /* If st_other has a processor-specific meaning, specific
+ code might be needed here. We never merge the visibility
+ attribute with the one from a dynamic object. */
+ if (bed->elf_backend_merge_symbol_attribute)
+ (*bed->elf_backend_merge_symbol_attribute) (h, isym, definition,
+ dynamic);
+
+ if (isym->st_other != 0 && !dynamic)
+ {
+ unsigned char hvis, symvis, other, nvis;
+
+ /* Take the balance of OTHER from the definition. */
+ other = (definition ? isym->st_other : h->other);
+ other &= ~ ELF_ST_VISIBILITY (-1);
+
+ /* Combine visibilities, using the most constraining one. */
+ hvis = ELF_ST_VISIBILITY (h->other);
+ symvis = ELF_ST_VISIBILITY (isym->st_other);
+ if (! hvis)
+ nvis = symvis;
+ else if (! symvis)
+ nvis = hvis;
+ else
+ nvis = hvis < symvis ? hvis : symvis;
+
+ h->other = other | nvis;
+ }
+
+ /* Set a flag in the hash table entry indicating the type of
+ reference or definition we just found. Keep a count of
+ the number of dynamic symbols we find. A dynamic symbol
+ is one which is referenced or defined by both a regular
+ object and a shared object. */
+ old_flags = h->elf_link_hash_flags;
+ dynsym = FALSE;
+ if (! dynamic)
+ {
+ if (! definition)
+ {
+ new_flag = ELF_LINK_HASH_REF_REGULAR;
+ if (bind != STB_WEAK)
+ new_flag |= ELF_LINK_HASH_REF_REGULAR_NONWEAK;
+ }
+ else
+ new_flag = ELF_LINK_HASH_DEF_REGULAR;
+ if (! info->executable
+ || (old_flags & (ELF_LINK_HASH_DEF_DYNAMIC
+ | ELF_LINK_HASH_REF_DYNAMIC)) != 0)
+ dynsym = TRUE;
+ }
+ else
+ {
+ if (! definition)
+ new_flag = ELF_LINK_HASH_REF_DYNAMIC;
+ else
+ new_flag = ELF_LINK_HASH_DEF_DYNAMIC;
+ if ((old_flags & (ELF_LINK_HASH_DEF_REGULAR
+ | ELF_LINK_HASH_REF_REGULAR)) != 0
+ || (h->weakdef != NULL
+ && ! new_weakdef
+ && h->weakdef->dynindx != -1))
+ dynsym = TRUE;
+ }
+
+ h->elf_link_hash_flags |= new_flag;
+
+ /* Check to see if we need to add an indirect symbol for
+ the default name. */
+ if (definition || h->root.type == bfd_link_hash_common)
+ if (!_bfd_elf_add_default_symbol (abfd, info, h, name, isym,
+ &sec, &value, &dynsym,
+ override))
+ goto error_free_vers;
+
+ if (definition && !dynamic)
+ {
+ char *p = strchr (name, ELF_VER_CHR);
+ if (p != NULL && p[1] != ELF_VER_CHR)
+ {
+ /* Queue non-default versions so that .symver x, x@FOO
+ aliases can be checked. */
+ if (! nondeflt_vers)
+ {
+ amt = (isymend - isym + 1)
+ * sizeof (struct elf_link_hash_entry *);
+ nondeflt_vers = bfd_malloc (amt);
+ }
+ nondeflt_vers [nondeflt_vers_cnt++] = h;
+ }
+ }
+
+ if (dynsym && h->dynindx == -1)
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ goto error_free_vers;
+ if (h->weakdef != NULL
+ && ! new_weakdef
+ && h->weakdef->dynindx == -1)
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, h->weakdef))
+ goto error_free_vers;
+ }
+ }
+ else if (dynsym && h->dynindx != -1)
+ /* If the symbol already has a dynamic index, but
+ visibility says it should not be visible, turn it into
+ a local symbol. */
+ switch (ELF_ST_VISIBILITY (h->other))
+ {
+ case STV_INTERNAL:
+ case STV_HIDDEN:
+ (*bed->elf_backend_hide_symbol) (info, h, TRUE);
+ dynsym = FALSE;
+ break;
+ }
+
+ if (!add_needed
+ && definition
+ && dynsym
+ && (h->elf_link_hash_flags
+ & ELF_LINK_HASH_REF_REGULAR) != 0)
+ {
+ int ret;
+ const char *soname = elf_dt_name (abfd);
+
+ /* A symbol from a library loaded via DT_NEEDED of some
+ other library is referenced by a regular object.
+ Add a DT_NEEDED entry for it. */
+ add_needed = TRUE;
+ ret = elf_add_dt_needed_tag (info, soname, add_needed);
+ if (ret < 0)
+ goto error_free_vers;
+
+ BFD_ASSERT (ret == 0);
+ }
+ }
+ }
+
+ /* Now that all the symbols from this input file are created, handle
+ .symver foo, foo@BAR such that any relocs against foo become foo@BAR. */
+ if (nondeflt_vers != NULL)
+ {
+ bfd_size_type cnt, symidx;
+
+ for (cnt = 0; cnt < nondeflt_vers_cnt; ++cnt)
+ {
+ struct elf_link_hash_entry *h = nondeflt_vers[cnt], *hi;
+ char *shortname, *p;
+
+ p = strchr (h->root.root.string, ELF_VER_CHR);
+ if (p == NULL
+ || (h->root.type != bfd_link_hash_defined
+ && h->root.type != bfd_link_hash_defweak))
+ continue;
+
+ amt = p - h->root.root.string;
+ shortname = bfd_malloc (amt + 1);
+ memcpy (shortname, h->root.root.string, amt);
+ shortname[amt] = '\0';
+
+ hi = (struct elf_link_hash_entry *)
+ bfd_link_hash_lookup (&hash_table->root, shortname,
+ FALSE, FALSE, FALSE);
+ if (hi != NULL
+ && hi->root.type == h->root.type
+ && hi->root.u.def.value == h->root.u.def.value
+ && hi->root.u.def.section == h->root.u.def.section)
+ {
+ (*bed->elf_backend_hide_symbol) (info, hi, TRUE);
+ hi->root.type = bfd_link_hash_indirect;
+ hi->root.u.i.link = (struct bfd_link_hash_entry *) h;
+ (*bed->elf_backend_copy_indirect_symbol) (bed, h, hi);
+ sym_hash = elf_sym_hashes (abfd);
+ if (sym_hash)
+ for (symidx = 0; symidx < extsymcount; ++symidx)
+ if (sym_hash[symidx] == hi)
+ {
+ sym_hash[symidx] = h;
+ break;
+ }
+ }
+ free (shortname);
+ }
+ free (nondeflt_vers);
+ nondeflt_vers = NULL;
+ }
+
+ if (extversym != NULL)
+ {
+ free (extversym);
+ extversym = NULL;
+ }
+
+ if (isymbuf != NULL)
+ free (isymbuf);
+ isymbuf = NULL;
+
+ /* Now set the weakdefs field correctly for all the weak defined
+ symbols we found. The only way to do this is to search all the
+ symbols. Since we only need the information for non functions in
+ dynamic objects, that's the only time we actually put anything on
+ the list WEAKS. We need this information so that if a regular
+ object refers to a symbol defined weakly in a dynamic object, the
+ real symbol in the dynamic object is also put in the dynamic
+ symbols; we also must arrange for both symbols to point to the
+ same memory location. We could handle the general case of symbol
+ aliasing, but a general symbol alias can only be generated in
+ assembler code, handling it correctly would be very time
+ consuming, and other ELF linkers don't handle general aliasing
+ either. */
+ if (weaks != NULL)
+ {
+ struct elf_link_hash_entry **hpp;
+ struct elf_link_hash_entry **hppend;
+ struct elf_link_hash_entry **sorted_sym_hash;
+ struct elf_link_hash_entry *h;
+ size_t sym_count;
+
+ /* Since we have to search the whole symbol list for each weak
+ defined symbol, search time for N weak defined symbols will be
+ O(N^2). Binary search will cut it down to O(NlogN). */
+ amt = extsymcount * sizeof (struct elf_link_hash_entry *);
+ sorted_sym_hash = bfd_malloc (amt);
+ if (sorted_sym_hash == NULL)
+ goto error_return;
+ sym_hash = sorted_sym_hash;
+ hpp = elf_sym_hashes (abfd);
+ hppend = hpp + extsymcount;
+ sym_count = 0;
+ for (; hpp < hppend; hpp++)
+ {
+ h = *hpp;
+ if (h != NULL
+ && h->root.type == bfd_link_hash_defined
+ && h->type != STT_FUNC)
+ {
+ *sym_hash = h;
+ sym_hash++;
+ sym_count++;
+ }
+ }
+
+ qsort (sorted_sym_hash, sym_count,
+ sizeof (struct elf_link_hash_entry *),
+ elf_sort_symbol);
+
+ while (weaks != NULL)
+ {
+ struct elf_link_hash_entry *hlook;
+ asection *slook;
+ bfd_vma vlook;
+ long ilook;
+ size_t i, j, idx;
+
+ hlook = weaks;
+ weaks = hlook->weakdef;
+ hlook->weakdef = NULL;
+
+ BFD_ASSERT (hlook->root.type == bfd_link_hash_defined
+ || hlook->root.type == bfd_link_hash_defweak
+ || hlook->root.type == bfd_link_hash_common
+ || hlook->root.type == bfd_link_hash_indirect);
+ slook = hlook->root.u.def.section;
+ vlook = hlook->root.u.def.value;
+
+ ilook = -1;
+ i = 0;
+ j = sym_count;
+ while (i < j)
+ {
+ bfd_signed_vma vdiff;
+ idx = (i + j) / 2;
+ h = sorted_sym_hash [idx];
+ vdiff = vlook - h->root.u.def.value;
+ if (vdiff < 0)
+ j = idx;
+ else if (vdiff > 0)
+ i = idx + 1;
+ else
+ {
+ long sdiff = slook - h->root.u.def.section;
+ if (sdiff < 0)
+ j = idx;
+ else if (sdiff > 0)
+ i = idx + 1;
+ else
+ {
+ ilook = idx;
+ break;
+ }
+ }
+ }
+
+ /* We didn't find a value/section match. */
+ if (ilook == -1)
+ continue;
+
+ for (i = ilook; i < sym_count; i++)
+ {
+ h = sorted_sym_hash [i];
+
+ /* Stop if value or section doesn't match. */
+ if (h->root.u.def.value != vlook
+ || h->root.u.def.section != slook)
+ break;
+ else if (h != hlook)
+ {
+ hlook->weakdef = h;
+
+ /* If the weak definition is in the list of dynamic
+ symbols, make sure the real definition is put
+ there as well. */
+ if (hlook->dynindx != -1 && h->dynindx == -1)
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ goto error_return;
+ }
+
+ /* If the real definition is in the list of dynamic
+ symbols, make sure the weak definition is put
+ there as well. If we don't do this, then the
+ dynamic loader might not merge the entries for the
+ real definition and the weak definition. */
+ if (h->dynindx != -1 && hlook->dynindx == -1)
+ {
+ if (! bfd_elf_link_record_dynamic_symbol (info, hlook))
+ goto error_return;
+ }
+ break;
+ }
+ }
+ }
+
+ free (sorted_sym_hash);
+ }
+
+ /* If this object is the same format as the output object, and it is
+ not a shared library, then let the backend look through the
+ relocs.
+
+ This is required to build global offset table entries and to
+ arrange for dynamic relocs. It is not required for the
+ particular common case of linking non PIC code, even when linking
+ against shared libraries, but unfortunately there is no way of
+ knowing whether an object file has been compiled PIC or not.
+ Looking through the relocs is not particularly time consuming.
+ The problem is that we must either (1) keep the relocs in memory,
+ which causes the linker to require additional runtime memory or
+ (2) read the relocs twice from the input file, which wastes time.
+ This would be a good case for using mmap.
+
+ I have no idea how to handle linking PIC code into a file of a
+ different format. It probably can't be done. */
+ check_relocs = get_elf_backend_data (abfd)->check_relocs;
+ if (! dynamic
+ && is_elf_hash_table (hash_table)
+ && hash_table->root.creator == abfd->xvec
+ && check_relocs != NULL)
+ {
+ asection *o;
+
+ for (o = abfd->sections; o != NULL; o = o->next)
+ {
+ Elf_Internal_Rela *internal_relocs;
+ bfd_boolean ok;
+
+ if ((o->flags & SEC_RELOC) == 0
+ || o->reloc_count == 0
+ || ((info->strip == strip_all || info->strip == strip_debugger)
+ && (o->flags & SEC_DEBUGGING) != 0)
+ || bfd_is_abs_section (o->output_section))
+ continue;
+
+ internal_relocs = _bfd_elf_link_read_relocs (abfd, o, NULL, NULL,
+ info->keep_memory);
+ if (internal_relocs == NULL)
+ goto error_return;
+
+ ok = (*check_relocs) (abfd, info, o, internal_relocs);
+
+ if (elf_section_data (o)->relocs != internal_relocs)
+ free (internal_relocs);
+
+ if (! ok)
+ goto error_return;
+ }
+ }
+
+ /* If this is a non-traditional link, try to optimize the handling
+ of the .stab/.stabstr sections. */
+ if (! dynamic
+ && ! info->traditional_format
+ && is_elf_hash_table (hash_table)
+ && (info->strip != strip_all && info->strip != strip_debugger))
+ {
+ asection *stabstr;
+
+ stabstr = bfd_get_section_by_name (abfd, ".stabstr");
+ if (stabstr != NULL)
+ {
+ bfd_size_type string_offset = 0;
+ asection *stab;
+
+ for (stab = abfd->sections; stab; stab = stab->next)
+ if (strncmp (".stab", stab->name, 5) == 0
+ && (!stab->name[5] ||
+ (stab->name[5] == '.' && ISDIGIT (stab->name[6])))
+ && (stab->flags & SEC_MERGE) == 0
+ && !bfd_is_abs_section (stab->output_section))
+ {
+ struct bfd_elf_section_data *secdata;
+
+ secdata = elf_section_data (stab);
+ if (! _bfd_link_section_stabs (abfd,
+ & hash_table->stab_info,
+ stab, stabstr,
+ &secdata->sec_info,
+ &string_offset))
+ goto error_return;
+ if (secdata->sec_info)
+ stab->sec_info_type = ELF_INFO_TYPE_STABS;
+ }
+ }
+ }
+
+ if (! info->relocatable
+ && ! dynamic
+ && is_elf_hash_table (hash_table))
+ {
+ asection *s;
+
+ for (s = abfd->sections; s != NULL; s = s->next)
+ if ((s->flags & SEC_MERGE) != 0
+ && !bfd_is_abs_section (s->output_section))
+ {
+ struct bfd_elf_section_data *secdata;
+
+ secdata = elf_section_data (s);
+ if (! _bfd_merge_section (abfd,
+ & hash_table->merge_info,
+ s, &secdata->sec_info))
+ goto error_return;
+ else if (secdata->sec_info)
+ s->sec_info_type = ELF_INFO_TYPE_MERGE;
+ }
+ }
+
+ if (is_elf_hash_table (hash_table))
+ {
+ /* Add this bfd to the loaded list. */
+ struct elf_link_loaded_list *n;
+
+ n = bfd_alloc (abfd, sizeof (struct elf_link_loaded_list));
+ if (n == NULL)
+ goto error_return;
+ n->abfd = abfd;
+ n->next = hash_table->loaded;
+ hash_table->loaded = n;
+ }
+
+ return TRUE;
+
+ error_free_vers:
+ if (nondeflt_vers != NULL)
+ free (nondeflt_vers);
+ if (extversym != NULL)
+ free (extversym);
+ error_free_sym:
+ if (isymbuf != NULL)
+ free (isymbuf);
+ error_return:
+ return FALSE;
+}
+
+/* Add symbols from an ELF archive file to the linker hash table. We
+ don't use _bfd_generic_link_add_archive_symbols because of a
+ problem which arises on UnixWare. The UnixWare libc.so is an
+ archive which includes an entry libc.so.1 which defines a bunch of
+ symbols. The libc.so archive also includes a number of other
+ object files, which also define symbols, some of which are the same
+ as those defined in libc.so.1. Correct linking requires that we
+ consider each object file in turn, and include it if it defines any
+ symbols we need. _bfd_generic_link_add_archive_symbols does not do
+ this; it looks through the list of undefined symbols, and includes
+ any object file which defines them. When this algorithm is used on
+ UnixWare, it winds up pulling in libc.so.1 early and defining a
+ bunch of symbols. This means that some of the other objects in the
+ archive are not included in the link, which is incorrect since they
+ precede libc.so.1 in the archive.
+
+ Fortunately, ELF archive handling is simpler than that done by
+ _bfd_generic_link_add_archive_symbols, which has to allow for a.out
+ oddities. In ELF, if we find a symbol in the archive map, and the
+ symbol is currently undefined, we know that we must pull in that
+ object file.
+
+ Unfortunately, we do have to make multiple passes over the symbol
+ table until nothing further is resolved. */
+
+static bfd_boolean
+elf_link_add_archive_symbols (bfd *abfd, struct bfd_link_info *info)
+{
+ symindex c;
+ bfd_boolean *defined = NULL;
+ bfd_boolean *included = NULL;
+ carsym *symdefs;
+ bfd_boolean loop;
+ bfd_size_type amt;
+
+ if (! bfd_has_map (abfd))
+ {
+ /* An empty archive is a special case. */
+ if (bfd_openr_next_archived_file (abfd, NULL) == NULL)
+ return TRUE;
+ bfd_set_error (bfd_error_no_armap);
+ return FALSE;
+ }
+
+ /* Keep track of all symbols we know to be already defined, and all
+ files we know to be already included. This is to speed up the
+ second and subsequent passes. */
+ c = bfd_ardata (abfd)->symdef_count;
+ if (c == 0)
+ return TRUE;
+ amt = c;
+ amt *= sizeof (bfd_boolean);
+ defined = bfd_zmalloc (amt);
+ included = bfd_zmalloc (amt);
+ if (defined == NULL || included == NULL)
+ goto error_return;
+
+ symdefs = bfd_ardata (abfd)->symdefs;
+
+ do
+ {
+ file_ptr last;
+ symindex i;
+ carsym *symdef;
+ carsym *symdefend;
+
+ loop = FALSE;
+ last = -1;
+
+ symdef = symdefs;
+ symdefend = symdef + c;
+ for (i = 0; symdef < symdefend; symdef++, i++)
{
struct elf_link_hash_entry *h;
- struct bfd_link_hash_entry *bh;
+ bfd *element;
+ struct bfd_link_hash_entry *undefs_tail;
+ symindex mark;
-#ifdef DEBUG
- fprintf (stderr, "Adding %s to section %s\n",
- lsect->sym_name,
- lsect->name);
-#endif
- bh = bfd_link_hash_lookup (info->hash, lsect->sym_name,
- false, false, false);
+ if (defined[i] || included[i])
+ continue;
+ if (symdef->file_offset == last)
+ {
+ included[i] = TRUE;
+ continue;
+ }
+
+ h = elf_link_hash_lookup (elf_hash_table (info), symdef->name,
+ FALSE, FALSE, FALSE);
+
+ if (h == NULL)
+ {
+ char *p, *copy;
+ size_t len, first;
+
+ /* If this is a default version (the name contains @@),
+ look up the symbol again with only one `@' as well
+ as without the version. The effect is that references
+ to the symbol with and without the version will be
+ matched by the default symbol in the archive. */
+
+ p = strchr (symdef->name, ELF_VER_CHR);
+ if (p == NULL || p[1] != ELF_VER_CHR)
+ continue;
+
+ /* First check with only one `@'. */
+ len = strlen (symdef->name);
+ copy = bfd_alloc (abfd, len);
+ if (copy == NULL)
+ goto error_return;
+ first = p - symdef->name + 1;
+ memcpy (copy, symdef->name, first);
+ memcpy (copy + first, symdef->name + first + 1, len - first);
+
+ h = elf_link_hash_lookup (elf_hash_table (info), copy,
+ FALSE, FALSE, FALSE);
+
+ if (h == NULL)
+ {
+ /* We also need to check references to the symbol
+ without the version. */
+
+ copy[first - 1] = '\0';
+ h = elf_link_hash_lookup (elf_hash_table (info),
+ copy, FALSE, FALSE, FALSE);
+ }
+
+ bfd_release (abfd, copy);
+ }
+
+ if (h == NULL)
+ continue;
+
+ if (h->root.type == bfd_link_hash_common)
+ {
+ /* We currently have a common symbol. The archive map contains
+ a reference to this symbol, so we may want to include it. We
+ only want to include it however, if this archive element
+ contains a definition of the symbol, not just another common
+ declaration of it.
+
+ Unfortunately some archivers (including GNU ar) will put
+ declarations of common symbols into their archive maps, as
+ well as real definitions, so we cannot just go by the archive
+ map alone. Instead we must read in the element's symbol
+ table and check that to see what kind of symbol definition
+ this is. */
+ if (! elf_link_is_defined_archive_symbol (abfd, symdef))
+ continue;
+ }
+ else if (h->root.type != bfd_link_hash_undefined)
+ {
+ if (h->root.type != bfd_link_hash_undefweak)
+ defined[i] = TRUE;
+ continue;
+ }
+
+ /* We need to include this archive member. */
+ element = _bfd_get_elt_at_filepos (abfd, symdef->file_offset);
+ if (element == NULL)
+ goto error_return;
+
+ if (! bfd_check_format (element, bfd_object))
+ goto error_return;
+
+ /* Doublecheck that we have not included this object
+ already--it should be impossible, but there may be
+ something wrong with the archive. */
+ if (element->archive_pass != 0)
+ {
+ bfd_set_error (bfd_error_bad_value);
+ goto error_return;
+ }
+ element->archive_pass = 1;
+
+ undefs_tail = info->hash->undefs_tail;
- if ((bh == NULL || bh->type == bfd_link_hash_undefined)
- && !(_bfd_generic_link_add_one_symbol
- (info, abfd, lsect->sym_name, BSF_GLOBAL, s,
- (lsect->hole_size
- ? s->_raw_size - lsect->hole_size + lsect->sym_offset
- : lsect->sym_offset),
- (const char *) NULL, false,
- get_elf_backend_data (abfd)->collect, &bh)))
- return (elf_linker_section_t *) 0;
- h = (struct elf_link_hash_entry *) bh;
+ if (! (*info->callbacks->add_archive_element) (info, element,
+ symdef->name))
+ goto error_return;
+ if (! bfd_link_add_symbols (element, info))
+ goto error_return;
- if ((defaults->which != LINKER_SECTION_SDATA)
- && (defaults->which != LINKER_SECTION_SDATA2))
- h->elf_link_hash_flags |= ELF_LINK_HASH_DEF_DYNAMIC;
+ /* If there are any new undefined symbols, we need to make
+ another pass through the archive in order to see whether
+ they can be defined. FIXME: This isn't perfect, because
+ common symbols wind up on undefs_tail and because an
+ undefined symbol which is defined later on in this pass
+ does not require another pass. This isn't a bug, but it
+ does make the code less efficient than it could be. */
+ if (undefs_tail != info->hash->undefs_tail)
+ loop = TRUE;
- h->type = STT_OBJECT;
- lsect->sym_hash = h;
+ /* Look backward to mark all symbols from this object file
+ which we have already seen in this pass. */
+ mark = i;
+ do
+ {
+ included[mark] = TRUE;
+ if (mark == 0)
+ break;
+ --mark;
+ }
+ while (symdefs[mark].file_offset == symdef->file_offset);
- if (info->shared
- && ! _bfd_elf_link_record_dynamic_symbol (info, h))
- return (elf_linker_section_t *) 0;
+ /* We mark subsequent symbols from this object file as we go
+ on through the loop. */
+ last = symdef->file_offset;
}
}
+ while (loop);
-#if 0
- /* This does not make sense. The sections which may exist in the
- object file have nothing to do with the sections we want to
- create. */
+ free (defined);
+ free (included);
+
+ return TRUE;
+
+ error_return:
+ if (defined != NULL)
+ free (defined);
+ if (included != NULL)
+ free (included);
+ return FALSE;
+}
+
+/* Given an ELF BFD, add symbols to the global hash table as
+ appropriate. */
+
+bfd_boolean
+bfd_elf_link_add_symbols (bfd *abfd, struct bfd_link_info *info)
+{
+ switch (bfd_get_format (abfd))
+ {
+ case bfd_object:
+ return elf_link_add_object_symbols (abfd, info);
+ case bfd_archive:
+ return elf_link_add_archive_symbols (abfd, info);
+ default:
+ bfd_set_error (bfd_error_wrong_format);
+ return FALSE;
+ }
+}
+
+/* This function will be called though elf_link_hash_traverse to store
+ all hash value of the exported symbols in an array. */
+
+static bfd_boolean
+elf_collect_hash_codes (struct elf_link_hash_entry *h, void *data)
+{
+ unsigned long **valuep = data;
+ const char *name;
+ char *p;
+ unsigned long ha;
+ char *alc = NULL;
+
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ /* Ignore indirect symbols. These are added by the versioning code. */
+ if (h->dynindx == -1)
+ return TRUE;
+
+ name = h->root.root.string;
+ p = strchr (name, ELF_VER_CHR);
+ if (p != NULL)
+ {
+ alc = bfd_malloc (p - name + 1);
+ memcpy (alc, name, p - name);
+ alc[p - name] = '\0';
+ name = alc;
+ }
+
+ /* Compute the hash value. */
+ ha = bfd_elf_hash (name);
+
+ /* Store the found hash value in the array given as the argument. */
+ *(*valuep)++ = ha;
- /* Find the related sections if they have been created */
- if (lsect->bss_name && !lsect->bss_section)
- lsect->bss_section = bfd_get_section_by_name (dynobj, lsect->bss_name);
+ /* And store it in the struct so that we can put it in the hash table
+ later. */
+ h->elf_hash_value = ha;
+
+ if (alc != NULL)
+ free (alc);
+
+ return TRUE;
+}
+
+/* Array used to determine the number of hash table buckets to use
+ based on the number of symbols there are. If there are fewer than
+ 3 symbols we use 1 bucket, fewer than 17 symbols we use 3 buckets,
+ fewer than 37 we use 17 buckets, and so forth. We never use more
+ than 32771 buckets. */
+
+static const size_t elf_buckets[] =
+{
+ 1, 3, 17, 37, 67, 97, 131, 197, 263, 521, 1031, 2053, 4099, 8209,
+ 16411, 32771, 0
+};
+
+/* Compute bucket count for hashing table. We do not use a static set
+ of possible tables sizes anymore. Instead we determine for all
+ possible reasonable sizes of the table the outcome (i.e., the
+ number of collisions etc) and choose the best solution. The
+ weighting functions are not too simple to allow the table to grow
+ without bounds. Instead one of the weighting factors is the size.
+ Therefore the result is always a good payoff between few collisions
+ (= short chain lengths) and table size. */
+static size_t
+compute_bucket_count (struct bfd_link_info *info)
+{
+ size_t dynsymcount = elf_hash_table (info)->dynsymcount;
+ size_t best_size = 0;
+ unsigned long int *hashcodes;
+ unsigned long int *hashcodesp;
+ unsigned long int i;
+ bfd_size_type amt;
+
+ /* Compute the hash values for all exported symbols. At the same
+ time store the values in an array so that we could use them for
+ optimizations. */
+ amt = dynsymcount;
+ amt *= sizeof (unsigned long int);
+ hashcodes = bfd_malloc (amt);
+ if (hashcodes == NULL)
+ return 0;
+ hashcodesp = hashcodes;
+
+ /* Put all hash values in HASHCODES. */
+ elf_link_hash_traverse (elf_hash_table (info),
+ elf_collect_hash_codes, &hashcodesp);
+
+ /* We have a problem here. The following code to optimize the table
+ size requires an integer type with more the 32 bits. If
+ BFD_HOST_U_64_BIT is set we know about such a type. */
+#ifdef BFD_HOST_U_64_BIT
+ if (info->optimize)
+ {
+ unsigned long int nsyms = hashcodesp - hashcodes;
+ size_t minsize;
+ size_t maxsize;
+ BFD_HOST_U_64_BIT best_chlen = ~((BFD_HOST_U_64_BIT) 0);
+ unsigned long int *counts ;
+ bfd *dynobj = elf_hash_table (info)->dynobj;
+ const struct elf_backend_data *bed = get_elf_backend_data (dynobj);
+
+ /* Possible optimization parameters: if we have NSYMS symbols we say
+ that the hashing table must at least have NSYMS/4 and at most
+ 2*NSYMS buckets. */
+ minsize = nsyms / 4;
+ if (minsize == 0)
+ minsize = 1;
+ best_size = maxsize = nsyms * 2;
+
+ /* Create array where we count the collisions in. We must use bfd_malloc
+ since the size could be large. */
+ amt = maxsize;
+ amt *= sizeof (unsigned long int);
+ counts = bfd_malloc (amt);
+ if (counts == NULL)
+ {
+ free (hashcodes);
+ return 0;
+ }
+
+ /* Compute the "optimal" size for the hash table. The criteria is a
+ minimal chain length. The minor criteria is (of course) the size
+ of the table. */
+ for (i = minsize; i < maxsize; ++i)
+ {
+ /* Walk through the array of hashcodes and count the collisions. */
+ BFD_HOST_U_64_BIT max;
+ unsigned long int j;
+ unsigned long int fact;
+
+ memset (counts, '\0', i * sizeof (unsigned long int));
+
+ /* Determine how often each hash bucket is used. */
+ for (j = 0; j < nsyms; ++j)
+ ++counts[hashcodes[j] % i];
+
+ /* For the weight function we need some information about the
+ pagesize on the target. This is information need not be 100%
+ accurate. Since this information is not available (so far) we
+ define it here to a reasonable default value. If it is crucial
+ to have a better value some day simply define this value. */
+# ifndef BFD_TARGET_PAGESIZE
+# define BFD_TARGET_PAGESIZE (4096)
+# endif
+
+ /* We in any case need 2 + NSYMS entries for the size values and
+ the chains. */
+ max = (2 + nsyms) * (bed->s->arch_size / 8);
+
+# if 1
+ /* Variant 1: optimize for short chains. We add the squares
+ of all the chain lengths (which favors many small chain
+ over a few long chains). */
+ for (j = 0; j < i; ++j)
+ max += counts[j] * counts[j];
+
+ /* This adds penalties for the overall size of the table. */
+ fact = i / (BFD_TARGET_PAGESIZE / (bed->s->arch_size / 8)) + 1;
+ max *= fact * fact;
+# else
+ /* Variant 2: Optimize a lot more for small table. Here we
+ also add squares of the size but we also add penalties for
+ empty slots (the +1 term). */
+ for (j = 0; j < i; ++j)
+ max += (1 + counts[j]) * (1 + counts[j]);
+
+ /* The overall size of the table is considered, but not as
+ strong as in variant 1, where it is squared. */
+ fact = i / (BFD_TARGET_PAGESIZE / (bed->s->arch_size / 8)) + 1;
+ max *= fact;
+# endif
+
+ /* Compare with current best results. */
+ if (max < best_chlen)
+ {
+ best_chlen = max;
+ best_size = i;
+ }
+ }
+
+ free (counts);
+ }
+ else
+#endif /* defined (BFD_HOST_U_64_BIT) */
+ {
+ /* This is the fallback solution if no 64bit type is available or if we
+ are not supposed to spend much time on optimizations. We select the
+ bucket count using a fixed set of numbers. */
+ for (i = 0; elf_buckets[i] != 0; i++)
+ {
+ best_size = elf_buckets[i];
+ if (dynsymcount < elf_buckets[i + 1])
+ break;
+ }
+ }
+
+ /* Free the arrays we needed. */
+ free (hashcodes);
+
+ return best_size;
+}
- if (lsect->rel_name && !lsect->rel_section)
- lsect->rel_section = bfd_get_section_by_name (dynobj, lsect->rel_name);
+/* Set up the sizes and contents of the ELF dynamic sections. This is
+ called by the ELF linker emulation before_allocation routine. We
+ must set the sizes of the sections before the linker sets the
+ addresses of the various sections. */
+
+bfd_boolean
+bfd_elf_size_dynamic_sections (bfd *output_bfd,
+ const char *soname,
+ const char *rpath,
+ const char *filter_shlib,
+ const char * const *auxiliary_filters,
+ struct bfd_link_info *info,
+ asection **sinterpptr,
+ struct bfd_elf_version_tree *verdefs)
+{
+ bfd_size_type soname_indx;
+ bfd *dynobj;
+ const struct elf_backend_data *bed;
+ struct elf_assign_sym_version_info asvinfo;
+
+ *sinterpptr = NULL;
+
+ soname_indx = (bfd_size_type) -1;
+
+ if (!is_elf_hash_table (info->hash))
+ return TRUE;
+
+ if (info->execstack)
+ elf_tdata (output_bfd)->stack_flags = PF_R | PF_W | PF_X;
+ else if (info->noexecstack)
+ elf_tdata (output_bfd)->stack_flags = PF_R | PF_W;
+ else
+ {
+ bfd *inputobj;
+ asection *notesec = NULL;
+ int exec = 0;
+
+ for (inputobj = info->input_bfds;
+ inputobj;
+ inputobj = inputobj->link_next)
+ {
+ asection *s;
+
+ if (inputobj->flags & DYNAMIC)
+ continue;
+ s = bfd_get_section_by_name (inputobj, ".note.GNU-stack");
+ if (s)
+ {
+ if (s->flags & SEC_CODE)
+ exec = PF_X;
+ notesec = s;
+ }
+ else
+ exec = PF_X;
+ }
+ if (notesec)
+ {
+ elf_tdata (output_bfd)->stack_flags = PF_R | PF_W | exec;
+ if (exec && info->relocatable
+ && notesec->output_section != bfd_abs_section_ptr)
+ notesec->output_section->flags |= SEC_CODE;
+ }
+ }
+
+ /* Any syms created from now on start with -1 in
+ got.refcount/offset and plt.refcount/offset. */
+ elf_hash_table (info)->init_refcount = elf_hash_table (info)->init_offset;
+
+ /* The backend may have to create some sections regardless of whether
+ we're dynamic or not. */
+ bed = get_elf_backend_data (output_bfd);
+ if (bed->elf_backend_always_size_sections
+ && ! (*bed->elf_backend_always_size_sections) (output_bfd, info))
+ return FALSE;
+
+ dynobj = elf_hash_table (info)->dynobj;
+
+ /* If there were no dynamic objects in the link, there is nothing to
+ do here. */
+ if (dynobj == NULL)
+ return TRUE;
+
+ if (! _bfd_elf_maybe_strip_eh_frame_hdr (info))
+ return FALSE;
+
+ if (elf_hash_table (info)->dynamic_sections_created)
+ {
+ struct elf_info_failed eif;
+ struct elf_link_hash_entry *h;
+ asection *dynstr;
+ struct bfd_elf_version_tree *t;
+ struct bfd_elf_version_expr *d;
+ bfd_boolean all_defined;
+
+ *sinterpptr = bfd_get_section_by_name (dynobj, ".interp");
+ BFD_ASSERT (*sinterpptr != NULL || !info->executable);
+
+ if (soname != NULL)
+ {
+ soname_indx = _bfd_elf_strtab_add (elf_hash_table (info)->dynstr,
+ soname, TRUE);
+ if (soname_indx == (bfd_size_type) -1
+ || !_bfd_elf_add_dynamic_entry (info, DT_SONAME, soname_indx))
+ return FALSE;
+ }
+
+ if (info->symbolic)
+ {
+ if (!_bfd_elf_add_dynamic_entry (info, DT_SYMBOLIC, 0))
+ return FALSE;
+ info->flags |= DF_SYMBOLIC;
+ }
+
+ if (rpath != NULL)
+ {
+ bfd_size_type indx;
+
+ indx = _bfd_elf_strtab_add (elf_hash_table (info)->dynstr, rpath,
+ TRUE);
+ if (indx == (bfd_size_type) -1
+ || !_bfd_elf_add_dynamic_entry (info, DT_RPATH, indx))
+ return FALSE;
+
+ if (info->new_dtags)
+ {
+ _bfd_elf_strtab_addref (elf_hash_table (info)->dynstr, indx);
+ if (!_bfd_elf_add_dynamic_entry (info, DT_RUNPATH, indx))
+ return FALSE;
+ }
+ }
+
+ if (filter_shlib != NULL)
+ {
+ bfd_size_type indx;
+
+ indx = _bfd_elf_strtab_add (elf_hash_table (info)->dynstr,
+ filter_shlib, TRUE);
+ if (indx == (bfd_size_type) -1
+ || !_bfd_elf_add_dynamic_entry (info, DT_FILTER, indx))
+ return FALSE;
+ }
+
+ if (auxiliary_filters != NULL)
+ {
+ const char * const *p;
+
+ for (p = auxiliary_filters; *p != NULL; p++)
+ {
+ bfd_size_type indx;
+
+ indx = _bfd_elf_strtab_add (elf_hash_table (info)->dynstr,
+ *p, TRUE);
+ if (indx == (bfd_size_type) -1
+ || !_bfd_elf_add_dynamic_entry (info, DT_AUXILIARY, indx))
+ return FALSE;
+ }
+ }
+
+ eif.info = info;
+ eif.verdefs = verdefs;
+ eif.failed = FALSE;
+
+ /* If we are supposed to export all symbols into the dynamic symbol
+ table (this is not the normal case), then do so. */
+ if (info->export_dynamic)
+ {
+ elf_link_hash_traverse (elf_hash_table (info),
+ _bfd_elf_export_symbol,
+ &eif);
+ if (eif.failed)
+ return FALSE;
+ }
+
+ /* Make all global versions with definition. */
+ for (t = verdefs; t != NULL; t = t->next)
+ for (d = t->globals.list; d != NULL; d = d->next)
+ if (!d->symver && d->symbol)
+ {
+ const char *verstr, *name;
+ size_t namelen, verlen, newlen;
+ char *newname, *p;
+ struct elf_link_hash_entry *newh;
+
+ name = d->symbol;
+ namelen = strlen (name);
+ verstr = t->name;
+ verlen = strlen (verstr);
+ newlen = namelen + verlen + 3;
+
+ newname = bfd_malloc (newlen);
+ if (newname == NULL)
+ return FALSE;
+ memcpy (newname, name, namelen);
+
+ /* Check the hidden versioned definition. */
+ p = newname + namelen;
+ *p++ = ELF_VER_CHR;
+ memcpy (p, verstr, verlen + 1);
+ newh = elf_link_hash_lookup (elf_hash_table (info),
+ newname, FALSE, FALSE,
+ FALSE);
+ if (newh == NULL
+ || (newh->root.type != bfd_link_hash_defined
+ && newh->root.type != bfd_link_hash_defweak))
+ {
+ /* Check the default versioned definition. */
+ *p++ = ELF_VER_CHR;
+ memcpy (p, verstr, verlen + 1);
+ newh = elf_link_hash_lookup (elf_hash_table (info),
+ newname, FALSE, FALSE,
+ FALSE);
+ }
+ free (newname);
+
+ /* Mark this version if there is a definition and it is
+ not defined in a shared object. */
+ if (newh != NULL
+ && ((newh->elf_link_hash_flags
+ & ELF_LINK_HASH_DEF_DYNAMIC) == 0)
+ && (newh->root.type == bfd_link_hash_defined
+ || newh->root.type == bfd_link_hash_defweak))
+ d->symver = 1;
+ }
+
+ /* Attach all the symbols to their version information. */
+ asvinfo.output_bfd = output_bfd;
+ asvinfo.info = info;
+ asvinfo.verdefs = verdefs;
+ asvinfo.failed = FALSE;
+
+ elf_link_hash_traverse (elf_hash_table (info),
+ _bfd_elf_link_assign_sym_version,
+ &asvinfo);
+ if (asvinfo.failed)
+ return FALSE;
+
+ if (!info->allow_undefined_version)
+ {
+ /* Check if all global versions have a definition. */
+ all_defined = TRUE;
+ for (t = verdefs; t != NULL; t = t->next)
+ for (d = t->globals.list; d != NULL; d = d->next)
+ if (!d->symver && !d->script)
+ {
+ (*_bfd_error_handler)
+ (_("%s: undefined version: %s"),
+ d->pattern, t->name);
+ all_defined = FALSE;
+ }
+
+ if (!all_defined)
+ {
+ bfd_set_error (bfd_error_bad_value);
+ return FALSE;
+ }
+ }
+
+ /* Find all symbols which were defined in a dynamic object and make
+ the backend pick a reasonable value for them. */
+ elf_link_hash_traverse (elf_hash_table (info),
+ _bfd_elf_adjust_dynamic_symbol,
+ &eif);
+ if (eif.failed)
+ return FALSE;
+
+ /* Add some entries to the .dynamic section. We fill in some of the
+ values later, in elf_bfd_final_link, but we must add the entries
+ now so that we know the final size of the .dynamic section. */
+
+ /* If there are initialization and/or finalization functions to
+ call then add the corresponding DT_INIT/DT_FINI entries. */
+ h = (info->init_function
+ ? elf_link_hash_lookup (elf_hash_table (info),
+ info->init_function, FALSE,
+ FALSE, FALSE)
+ : NULL);
+ if (h != NULL
+ && (h->elf_link_hash_flags & (ELF_LINK_HASH_REF_REGULAR
+ | ELF_LINK_HASH_DEF_REGULAR)) != 0)
+ {
+ if (!_bfd_elf_add_dynamic_entry (info, DT_INIT, 0))
+ return FALSE;
+ }
+ h = (info->fini_function
+ ? elf_link_hash_lookup (elf_hash_table (info),
+ info->fini_function, FALSE,
+ FALSE, FALSE)
+ : NULL);
+ if (h != NULL
+ && (h->elf_link_hash_flags & (ELF_LINK_HASH_REF_REGULAR
+ | ELF_LINK_HASH_DEF_REGULAR)) != 0)
+ {
+ if (!_bfd_elf_add_dynamic_entry (info, DT_FINI, 0))
+ return FALSE;
+ }
+
+ if (bfd_get_section_by_name (output_bfd, ".preinit_array") != NULL)
+ {
+ /* DT_PREINIT_ARRAY is not allowed in shared library. */
+ if (! info->executable)
+ {
+ bfd *sub;
+ asection *o;
+
+ for (sub = info->input_bfds; sub != NULL;
+ sub = sub->link_next)
+ for (o = sub->sections; o != NULL; o = o->next)
+ if (elf_section_data (o)->this_hdr.sh_type
+ == SHT_PREINIT_ARRAY)
+ {
+ (*_bfd_error_handler)
+ (_("%s: .preinit_array section is not allowed in DSO"),
+ bfd_archive_filename (sub));
+ break;
+ }
+
+ bfd_set_error (bfd_error_nonrepresentable_section);
+ return FALSE;
+ }
+
+ if (!_bfd_elf_add_dynamic_entry (info, DT_PREINIT_ARRAY, 0)
+ || !_bfd_elf_add_dynamic_entry (info, DT_PREINIT_ARRAYSZ, 0))
+ return FALSE;
+ }
+ if (bfd_get_section_by_name (output_bfd, ".init_array") != NULL)
+ {
+ if (!_bfd_elf_add_dynamic_entry (info, DT_INIT_ARRAY, 0)
+ || !_bfd_elf_add_dynamic_entry (info, DT_INIT_ARRAYSZ, 0))
+ return FALSE;
+ }
+ if (bfd_get_section_by_name (output_bfd, ".fini_array") != NULL)
+ {
+ if (!_bfd_elf_add_dynamic_entry (info, DT_FINI_ARRAY, 0)
+ || !_bfd_elf_add_dynamic_entry (info, DT_FINI_ARRAYSZ, 0))
+ return FALSE;
+ }
+
+ dynstr = bfd_get_section_by_name (dynobj, ".dynstr");
+ /* If .dynstr is excluded from the link, we don't want any of
+ these tags. Strictly, we should be checking each section
+ individually; This quick check covers for the case where
+ someone does a /DISCARD/ : { *(*) }. */
+ if (dynstr != NULL && dynstr->output_section != bfd_abs_section_ptr)
+ {
+ bfd_size_type strsize;
+
+ strsize = _bfd_elf_strtab_size (elf_hash_table (info)->dynstr);
+ if (!_bfd_elf_add_dynamic_entry (info, DT_HASH, 0)
+ || !_bfd_elf_add_dynamic_entry (info, DT_STRTAB, 0)
+ || !_bfd_elf_add_dynamic_entry (info, DT_SYMTAB, 0)
+ || !_bfd_elf_add_dynamic_entry (info, DT_STRSZ, strsize)
+ || !_bfd_elf_add_dynamic_entry (info, DT_SYMENT,
+ bed->s->sizeof_sym))
+ return FALSE;
+ }
+ }
+
+ /* The backend must work out the sizes of all the other dynamic
+ sections. */
+ if (bed->elf_backend_size_dynamic_sections
+ && ! (*bed->elf_backend_size_dynamic_sections) (output_bfd, info))
+ return FALSE;
+
+ if (elf_hash_table (info)->dynamic_sections_created)
+ {
+ bfd_size_type dynsymcount;
+ asection *s;
+ size_t bucketcount = 0;
+ size_t hash_entry_size;
+ unsigned int dtagcount;
+
+ /* Set up the version definition section. */
+ s = bfd_get_section_by_name (dynobj, ".gnu.version_d");
+ BFD_ASSERT (s != NULL);
+
+ /* We may have created additional version definitions if we are
+ just linking a regular application. */
+ verdefs = asvinfo.verdefs;
+
+ /* Skip anonymous version tag. */
+ if (verdefs != NULL && verdefs->vernum == 0)
+ verdefs = verdefs->next;
+
+ if (verdefs == NULL)
+ _bfd_strip_section_from_output (info, s);
+ else
+ {
+ unsigned int cdefs;
+ bfd_size_type size;
+ struct bfd_elf_version_tree *t;
+ bfd_byte *p;
+ Elf_Internal_Verdef def;
+ Elf_Internal_Verdaux defaux;
+
+ cdefs = 0;
+ size = 0;
+
+ /* Make space for the base version. */
+ size += sizeof (Elf_External_Verdef);
+ size += sizeof (Elf_External_Verdaux);
+ ++cdefs;
+
+ for (t = verdefs; t != NULL; t = t->next)
+ {
+ struct bfd_elf_version_deps *n;
+
+ size += sizeof (Elf_External_Verdef);
+ size += sizeof (Elf_External_Verdaux);
+ ++cdefs;
+
+ for (n = t->deps; n != NULL; n = n->next)
+ size += sizeof (Elf_External_Verdaux);
+ }
+
+ s->_raw_size = size;
+ s->contents = bfd_alloc (output_bfd, s->_raw_size);
+ if (s->contents == NULL && s->_raw_size != 0)
+ return FALSE;
+
+ /* Fill in the version definition section. */
+
+ p = s->contents;
+
+ def.vd_version = VER_DEF_CURRENT;
+ def.vd_flags = VER_FLG_BASE;
+ def.vd_ndx = 1;
+ def.vd_cnt = 1;
+ def.vd_aux = sizeof (Elf_External_Verdef);
+ def.vd_next = (sizeof (Elf_External_Verdef)
+ + sizeof (Elf_External_Verdaux));
+
+ if (soname_indx != (bfd_size_type) -1)
+ {
+ _bfd_elf_strtab_addref (elf_hash_table (info)->dynstr,
+ soname_indx);
+ def.vd_hash = bfd_elf_hash (soname);
+ defaux.vda_name = soname_indx;
+ }
+ else
+ {
+ const char *name;
+ bfd_size_type indx;
+
+ name = basename (output_bfd->filename);
+ def.vd_hash = bfd_elf_hash (name);
+ indx = _bfd_elf_strtab_add (elf_hash_table (info)->dynstr,
+ name, FALSE);
+ if (indx == (bfd_size_type) -1)
+ return FALSE;
+ defaux.vda_name = indx;
+ }
+ defaux.vda_next = 0;
+
+ _bfd_elf_swap_verdef_out (output_bfd, &def,
+ (Elf_External_Verdef *) p);
+ p += sizeof (Elf_External_Verdef);
+ _bfd_elf_swap_verdaux_out (output_bfd, &defaux,
+ (Elf_External_Verdaux *) p);
+ p += sizeof (Elf_External_Verdaux);
+
+ for (t = verdefs; t != NULL; t = t->next)
+ {
+ unsigned int cdeps;
+ struct bfd_elf_version_deps *n;
+ struct elf_link_hash_entry *h;
+ struct bfd_link_hash_entry *bh;
+
+ cdeps = 0;
+ for (n = t->deps; n != NULL; n = n->next)
+ ++cdeps;
+
+ /* Add a symbol representing this version. */
+ bh = NULL;
+ if (! (_bfd_generic_link_add_one_symbol
+ (info, dynobj, t->name, BSF_GLOBAL, bfd_abs_section_ptr,
+ 0, NULL, FALSE,
+ get_elf_backend_data (dynobj)->collect, &bh)))
+ return FALSE;
+ h = (struct elf_link_hash_entry *) bh;
+ h->elf_link_hash_flags &= ~ ELF_LINK_NON_ELF;
+ h->elf_link_hash_flags |= ELF_LINK_HASH_DEF_REGULAR;
+ h->type = STT_OBJECT;
+ h->verinfo.vertree = t;
+
+ if (! bfd_elf_link_record_dynamic_symbol (info, h))
+ return FALSE;
+
+ def.vd_version = VER_DEF_CURRENT;
+ def.vd_flags = 0;
+ if (t->globals.list == NULL
+ && t->locals.list == NULL
+ && ! t->used)
+ def.vd_flags |= VER_FLG_WEAK;
+ def.vd_ndx = t->vernum + 1;
+ def.vd_cnt = cdeps + 1;
+ def.vd_hash = bfd_elf_hash (t->name);
+ def.vd_aux = sizeof (Elf_External_Verdef);
+ def.vd_next = 0;
+ if (t->next != NULL)
+ def.vd_next = (sizeof (Elf_External_Verdef)
+ + (cdeps + 1) * sizeof (Elf_External_Verdaux));
+
+ _bfd_elf_swap_verdef_out (output_bfd, &def,
+ (Elf_External_Verdef *) p);
+ p += sizeof (Elf_External_Verdef);
+
+ defaux.vda_name = h->dynstr_index;
+ _bfd_elf_strtab_addref (elf_hash_table (info)->dynstr,
+ h->dynstr_index);
+ defaux.vda_next = 0;
+ if (t->deps != NULL)
+ defaux.vda_next = sizeof (Elf_External_Verdaux);
+ t->name_indx = defaux.vda_name;
+
+ _bfd_elf_swap_verdaux_out (output_bfd, &defaux,
+ (Elf_External_Verdaux *) p);
+ p += sizeof (Elf_External_Verdaux);
+
+ for (n = t->deps; n != NULL; n = n->next)
+ {
+ if (n->version_needed == NULL)
+ {
+ /* This can happen if there was an error in the
+ version script. */
+ defaux.vda_name = 0;
+ }
+ else
+ {
+ defaux.vda_name = n->version_needed->name_indx;
+ _bfd_elf_strtab_addref (elf_hash_table (info)->dynstr,
+ defaux.vda_name);
+ }
+ if (n->next == NULL)
+ defaux.vda_next = 0;
+ else
+ defaux.vda_next = sizeof (Elf_External_Verdaux);
+
+ _bfd_elf_swap_verdaux_out (output_bfd, &defaux,
+ (Elf_External_Verdaux *) p);
+ p += sizeof (Elf_External_Verdaux);
+ }
+ }
+
+ if (!_bfd_elf_add_dynamic_entry (info, DT_VERDEF, 0)
+ || !_bfd_elf_add_dynamic_entry (info, DT_VERDEFNUM, cdefs))
+ return FALSE;
+
+ elf_tdata (output_bfd)->cverdefs = cdefs;
+ }
+
+ if ((info->new_dtags && info->flags) || (info->flags & DF_STATIC_TLS))
+ {
+ if (!_bfd_elf_add_dynamic_entry (info, DT_FLAGS, info->flags))
+ return FALSE;
+ }
+ else if (info->flags & DF_BIND_NOW)
+ {
+ if (!_bfd_elf_add_dynamic_entry (info, DT_BIND_NOW, 0))
+ return FALSE;
+ }
+
+ if (info->flags_1)
+ {
+ if (info->executable)
+ info->flags_1 &= ~ (DF_1_INITFIRST
+ | DF_1_NODELETE
+ | DF_1_NOOPEN);
+ if (!_bfd_elf_add_dynamic_entry (info, DT_FLAGS_1, info->flags_1))
+ return FALSE;
+ }
+
+ /* Work out the size of the version reference section. */
+
+ s = bfd_get_section_by_name (dynobj, ".gnu.version_r");
+ BFD_ASSERT (s != NULL);
+ {
+ struct elf_find_verdep_info sinfo;
+
+ sinfo.output_bfd = output_bfd;
+ sinfo.info = info;
+ sinfo.vers = elf_tdata (output_bfd)->cverdefs;
+ if (sinfo.vers == 0)
+ sinfo.vers = 1;
+ sinfo.failed = FALSE;
+
+ elf_link_hash_traverse (elf_hash_table (info),
+ _bfd_elf_link_find_version_dependencies,
+ &sinfo);
+
+ if (elf_tdata (output_bfd)->verref == NULL)
+ _bfd_strip_section_from_output (info, s);
+ else
+ {
+ Elf_Internal_Verneed *t;
+ unsigned int size;
+ unsigned int crefs;
+ bfd_byte *p;
+
+ /* Build the version definition section. */
+ size = 0;
+ crefs = 0;
+ for (t = elf_tdata (output_bfd)->verref;
+ t != NULL;
+ t = t->vn_nextref)
+ {
+ Elf_Internal_Vernaux *a;
+
+ size += sizeof (Elf_External_Verneed);
+ ++crefs;
+ for (a = t->vn_auxptr; a != NULL; a = a->vna_nextptr)
+ size += sizeof (Elf_External_Vernaux);
+ }
+
+ s->_raw_size = size;
+ s->contents = bfd_alloc (output_bfd, s->_raw_size);
+ if (s->contents == NULL)
+ return FALSE;
+
+ p = s->contents;
+ for (t = elf_tdata (output_bfd)->verref;
+ t != NULL;
+ t = t->vn_nextref)
+ {
+ unsigned int caux;
+ Elf_Internal_Vernaux *a;
+ bfd_size_type indx;
+
+ caux = 0;
+ for (a = t->vn_auxptr; a != NULL; a = a->vna_nextptr)
+ ++caux;
+
+ t->vn_version = VER_NEED_CURRENT;
+ t->vn_cnt = caux;
+ indx = _bfd_elf_strtab_add (elf_hash_table (info)->dynstr,
+ elf_dt_name (t->vn_bfd) != NULL
+ ? elf_dt_name (t->vn_bfd)
+ : basename (t->vn_bfd->filename),
+ FALSE);
+ if (indx == (bfd_size_type) -1)
+ return FALSE;
+ t->vn_file = indx;
+ t->vn_aux = sizeof (Elf_External_Verneed);
+ if (t->vn_nextref == NULL)
+ t->vn_next = 0;
+ else
+ t->vn_next = (sizeof (Elf_External_Verneed)
+ + caux * sizeof (Elf_External_Vernaux));
+
+ _bfd_elf_swap_verneed_out (output_bfd, t,
+ (Elf_External_Verneed *) p);
+ p += sizeof (Elf_External_Verneed);
+
+ for (a = t->vn_auxptr; a != NULL; a = a->vna_nextptr)
+ {
+ a->vna_hash = bfd_elf_hash (a->vna_nodename);
+ indx = _bfd_elf_strtab_add (elf_hash_table (info)->dynstr,
+ a->vna_nodename, FALSE);
+ if (indx == (bfd_size_type) -1)
+ return FALSE;
+ a->vna_name = indx;
+ if (a->vna_nextptr == NULL)
+ a->vna_next = 0;
+ else
+ a->vna_next = sizeof (Elf_External_Vernaux);
+
+ _bfd_elf_swap_vernaux_out (output_bfd, a,
+ (Elf_External_Vernaux *) p);
+ p += sizeof (Elf_External_Vernaux);
+ }
+ }
+
+ if (!_bfd_elf_add_dynamic_entry (info, DT_VERNEED, 0)
+ || !_bfd_elf_add_dynamic_entry (info, DT_VERNEEDNUM, crefs))
+ return FALSE;
+
+ elf_tdata (output_bfd)->cverrefs = crefs;
+ }
+ }
+
+ /* Assign dynsym indicies. In a shared library we generate a
+ section symbol for each output section, which come first.
+ Next come all of the back-end allocated local dynamic syms,
+ followed by the rest of the global symbols. */
+
+ dynsymcount = _bfd_elf_link_renumber_dynsyms (output_bfd, info);
+
+ /* Work out the size of the symbol version section. */
+ s = bfd_get_section_by_name (dynobj, ".gnu.version");
+ BFD_ASSERT (s != NULL);
+ if (dynsymcount == 0
+ || (verdefs == NULL && elf_tdata (output_bfd)->verref == NULL))
+ {
+ _bfd_strip_section_from_output (info, s);
+ /* The DYNSYMCOUNT might have changed if we were going to
+ output a dynamic symbol table entry for S. */
+ dynsymcount = _bfd_elf_link_renumber_dynsyms (output_bfd, info);
+ }
+ else
+ {
+ s->_raw_size = dynsymcount * sizeof (Elf_External_Versym);
+ s->contents = bfd_zalloc (output_bfd, s->_raw_size);
+ if (s->contents == NULL)
+ return FALSE;
+
+ if (!_bfd_elf_add_dynamic_entry (info, DT_VERSYM, 0))
+ return FALSE;
+ }
+
+ /* Set the size of the .dynsym and .hash sections. We counted
+ the number of dynamic symbols in elf_link_add_object_symbols.
+ We will build the contents of .dynsym and .hash when we build
+ the final symbol table, because until then we do not know the
+ correct value to give the symbols. We built the .dynstr
+ section as we went along in elf_link_add_object_symbols. */
+ s = bfd_get_section_by_name (dynobj, ".dynsym");
+ BFD_ASSERT (s != NULL);
+ s->_raw_size = dynsymcount * bed->s->sizeof_sym;
+ s->contents = bfd_alloc (output_bfd, s->_raw_size);
+ if (s->contents == NULL && s->_raw_size != 0)
+ return FALSE;
+
+ if (dynsymcount != 0)
+ {
+ Elf_Internal_Sym isym;
+
+ /* The first entry in .dynsym is a dummy symbol. */
+ isym.st_value = 0;
+ isym.st_size = 0;
+ isym.st_name = 0;
+ isym.st_info = 0;
+ isym.st_other = 0;
+ isym.st_shndx = 0;
+ bed->s->swap_symbol_out (output_bfd, &isym, s->contents, 0);
+ }
+
+ /* Compute the size of the hashing table. As a side effect this
+ computes the hash values for all the names we export. */
+ bucketcount = compute_bucket_count (info);
+
+ s = bfd_get_section_by_name (dynobj, ".hash");
+ BFD_ASSERT (s != NULL);
+ hash_entry_size = elf_section_data (s)->this_hdr.sh_entsize;
+ s->_raw_size = ((2 + bucketcount + dynsymcount) * hash_entry_size);
+ s->contents = bfd_zalloc (output_bfd, s->_raw_size);
+ if (s->contents == NULL)
+ return FALSE;
+
+ bfd_put (8 * hash_entry_size, output_bfd, bucketcount, s->contents);
+ bfd_put (8 * hash_entry_size, output_bfd, dynsymcount,
+ s->contents + hash_entry_size);
+
+ elf_hash_table (info)->bucketcount = bucketcount;
+
+ s = bfd_get_section_by_name (dynobj, ".dynstr");
+ BFD_ASSERT (s != NULL);
+
+ elf_finalize_dynstr (output_bfd, info);
+
+ s->_raw_size = _bfd_elf_strtab_size (elf_hash_table (info)->dynstr);
+
+ for (dtagcount = 0; dtagcount <= info->spare_dynamic_tags; ++dtagcount)
+ if (!_bfd_elf_add_dynamic_entry (info, DT_NULL, 0))
+ return FALSE;
+ }
+
+ return TRUE;
+}
+
+/* Final phase of ELF linker. */
+
+/* A structure we use to avoid passing large numbers of arguments. */
+
+struct elf_final_link_info
+{
+ /* General link information. */
+ struct bfd_link_info *info;
+ /* Output BFD. */
+ bfd *output_bfd;
+ /* Symbol string table. */
+ struct bfd_strtab_hash *symstrtab;
+ /* .dynsym section. */
+ asection *dynsym_sec;
+ /* .hash section. */
+ asection *hash_sec;
+ /* symbol version section (.gnu.version). */
+ asection *symver_sec;
+ /* Buffer large enough to hold contents of any section. */
+ bfd_byte *contents;
+ /* Buffer large enough to hold external relocs of any section. */
+ void *external_relocs;
+ /* Buffer large enough to hold internal relocs of any section. */
+ Elf_Internal_Rela *internal_relocs;
+ /* Buffer large enough to hold external local symbols of any input
+ BFD. */
+ bfd_byte *external_syms;
+ /* And a buffer for symbol section indices. */
+ Elf_External_Sym_Shndx *locsym_shndx;
+ /* Buffer large enough to hold internal local symbols of any input
+ BFD. */
+ Elf_Internal_Sym *internal_syms;
+ /* Array large enough to hold a symbol index for each local symbol
+ of any input BFD. */
+ long *indices;
+ /* Array large enough to hold a section pointer for each local
+ symbol of any input BFD. */
+ asection **sections;
+ /* Buffer to hold swapped out symbols. */
+ bfd_byte *symbuf;
+ /* And one for symbol section indices. */
+ Elf_External_Sym_Shndx *symshndxbuf;
+ /* Number of swapped out symbols in buffer. */
+ size_t symbuf_count;
+ /* Number of symbols which fit in symbuf. */
+ size_t symbuf_size;
+ /* And same for symshndxbuf. */
+ size_t shndxbuf_size;
+};
+
+/* This struct is used to pass information to elf_link_output_extsym. */
+
+struct elf_outext_info
+{
+ bfd_boolean failed;
+ bfd_boolean localsyms;
+ struct elf_final_link_info *finfo;
+};
+
+/* When performing a relocatable link, the input relocations are
+ preserved. But, if they reference global symbols, the indices
+ referenced must be updated. Update all the relocations in
+ REL_HDR (there are COUNT of them), using the data in REL_HASH. */
+
+static void
+elf_link_adjust_relocs (bfd *abfd,
+ Elf_Internal_Shdr *rel_hdr,
+ unsigned int count,
+ struct elf_link_hash_entry **rel_hash)
+{
+ unsigned int i;
+ const struct elf_backend_data *bed = get_elf_backend_data (abfd);
+ bfd_byte *erela;
+ void (*swap_in) (bfd *, const bfd_byte *, Elf_Internal_Rela *);
+ void (*swap_out) (bfd *, const Elf_Internal_Rela *, bfd_byte *);
+ bfd_vma r_type_mask;
+ int r_sym_shift;
+
+ if (rel_hdr->sh_entsize == bed->s->sizeof_rel)
+ {
+ swap_in = bed->s->swap_reloc_in;
+ swap_out = bed->s->swap_reloc_out;
+ }
+ else if (rel_hdr->sh_entsize == bed->s->sizeof_rela)
+ {
+ swap_in = bed->s->swap_reloca_in;
+ swap_out = bed->s->swap_reloca_out;
+ }
+ else
+ abort ();
+
+ if (bed->s->int_rels_per_ext_rel > MAX_INT_RELS_PER_EXT_REL)
+ abort ();
+
+ if (bed->s->arch_size == 32)
+ {
+ r_type_mask = 0xff;
+ r_sym_shift = 8;
+ }
+ else
+ {
+ r_type_mask = 0xffffffff;
+ r_sym_shift = 32;
+ }
+
+ erela = rel_hdr->contents;
+ for (i = 0; i < count; i++, rel_hash++, erela += rel_hdr->sh_entsize)
+ {
+ Elf_Internal_Rela irela[MAX_INT_RELS_PER_EXT_REL];
+ unsigned int j;
+
+ if (*rel_hash == NULL)
+ continue;
+
+ BFD_ASSERT ((*rel_hash)->indx >= 0);
+
+ (*swap_in) (abfd, erela, irela);
+ for (j = 0; j < bed->s->int_rels_per_ext_rel; j++)
+ irela[j].r_info = ((bfd_vma) (*rel_hash)->indx << r_sym_shift
+ | (irela[j].r_info & r_type_mask));
+ (*swap_out) (abfd, irela, erela);
+ }
+}
+
+struct elf_link_sort_rela
+{
+ union {
+ bfd_vma offset;
+ bfd_vma sym_mask;
+ } u;
+ enum elf_reloc_type_class type;
+ /* We use this as an array of size int_rels_per_ext_rel. */
+ Elf_Internal_Rela rela[1];
+};
+
+static int
+elf_link_sort_cmp1 (const void *A, const void *B)
+{
+ const struct elf_link_sort_rela *a = A;
+ const struct elf_link_sort_rela *b = B;
+ int relativea, relativeb;
+
+ relativea = a->type == reloc_class_relative;
+ relativeb = b->type == reloc_class_relative;
+
+ if (relativea < relativeb)
+ return 1;
+ if (relativea > relativeb)
+ return -1;
+ if ((a->rela->r_info & a->u.sym_mask) < (b->rela->r_info & b->u.sym_mask))
+ return -1;
+ if ((a->rela->r_info & a->u.sym_mask) > (b->rela->r_info & b->u.sym_mask))
+ return 1;
+ if (a->rela->r_offset < b->rela->r_offset)
+ return -1;
+ if (a->rela->r_offset > b->rela->r_offset)
+ return 1;
+ return 0;
+}
+
+static int
+elf_link_sort_cmp2 (const void *A, const void *B)
+{
+ const struct elf_link_sort_rela *a = A;
+ const struct elf_link_sort_rela *b = B;
+ int copya, copyb;
+
+ if (a->u.offset < b->u.offset)
+ return -1;
+ if (a->u.offset > b->u.offset)
+ return 1;
+ copya = (a->type == reloc_class_copy) * 2 + (a->type == reloc_class_plt);
+ copyb = (b->type == reloc_class_copy) * 2 + (b->type == reloc_class_plt);
+ if (copya < copyb)
+ return -1;
+ if (copya > copyb)
+ return 1;
+ if (a->rela->r_offset < b->rela->r_offset)
+ return -1;
+ if (a->rela->r_offset > b->rela->r_offset)
+ return 1;
+ return 0;
+}
+
+static size_t
+elf_link_sort_relocs (bfd *abfd, struct bfd_link_info *info, asection **psec)
+{
+ asection *reldyn;
+ bfd_size_type count, size;
+ size_t i, ret, sort_elt, ext_size;
+ bfd_byte *sort, *s_non_relative, *p;
+ struct elf_link_sort_rela *sq;
+ const struct elf_backend_data *bed = get_elf_backend_data (abfd);
+ int i2e = bed->s->int_rels_per_ext_rel;
+ void (*swap_in) (bfd *, const bfd_byte *, Elf_Internal_Rela *);
+ void (*swap_out) (bfd *, const Elf_Internal_Rela *, bfd_byte *);
+ struct bfd_link_order *lo;
+ bfd_vma r_sym_mask;
+
+ reldyn = bfd_get_section_by_name (abfd, ".rela.dyn");
+ if (reldyn == NULL || reldyn->_raw_size == 0)
+ {
+ reldyn = bfd_get_section_by_name (abfd, ".rel.dyn");
+ if (reldyn == NULL || reldyn->_raw_size == 0)
+ return 0;
+ ext_size = bed->s->sizeof_rel;
+ swap_in = bed->s->swap_reloc_in;
+ swap_out = bed->s->swap_reloc_out;
+ }
+ else
+ {
+ ext_size = bed->s->sizeof_rela;
+ swap_in = bed->s->swap_reloca_in;
+ swap_out = bed->s->swap_reloca_out;
+ }
+ count = reldyn->_raw_size / ext_size;
+
+ size = 0;
+ for (lo = reldyn->link_order_head; lo != NULL; lo = lo->next)
+ if (lo->type == bfd_indirect_link_order)
+ {
+ asection *o = lo->u.indirect.section;
+ size += o->_raw_size;
+ }
+
+ if (size != reldyn->_raw_size)
+ return 0;
+
+ sort_elt = (sizeof (struct elf_link_sort_rela)
+ + (i2e - 1) * sizeof (Elf_Internal_Rela));
+ sort = bfd_zmalloc (sort_elt * count);
+ if (sort == NULL)
+ {
+ (*info->callbacks->warning)
+ (info, _("Not enough memory to sort relocations"), 0, abfd, 0, 0);
+ return 0;
+ }
+
+ if (bed->s->arch_size == 32)
+ r_sym_mask = ~(bfd_vma) 0xff;
+ else
+ r_sym_mask = ~(bfd_vma) 0xffffffff;
+
+ for (lo = reldyn->link_order_head; lo != NULL; lo = lo->next)
+ if (lo->type == bfd_indirect_link_order)
+ {
+ bfd_byte *erel, *erelend;
+ asection *o = lo->u.indirect.section;
+
+ erel = o->contents;
+ erelend = o->contents + o->_raw_size;
+ p = sort + o->output_offset / ext_size * sort_elt;
+ while (erel < erelend)
+ {
+ struct elf_link_sort_rela *s = (struct elf_link_sort_rela *) p;
+ (*swap_in) (abfd, erel, s->rela);
+ s->type = (*bed->elf_backend_reloc_type_class) (s->rela);
+ s->u.sym_mask = r_sym_mask;
+ p += sort_elt;
+ erel += ext_size;
+ }
+ }
+
+ qsort (sort, count, sort_elt, elf_link_sort_cmp1);
+
+ for (i = 0, p = sort; i < count; i++, p += sort_elt)
+ {
+ struct elf_link_sort_rela *s = (struct elf_link_sort_rela *) p;
+ if (s->type != reloc_class_relative)
+ break;
+ }
+ ret = i;
+ s_non_relative = p;
+
+ sq = (struct elf_link_sort_rela *) s_non_relative;
+ for (; i < count; i++, p += sort_elt)
+ {
+ struct elf_link_sort_rela *sp = (struct elf_link_sort_rela *) p;
+ if (((sp->rela->r_info ^ sq->rela->r_info) & r_sym_mask) != 0)
+ sq = sp;
+ sp->u.offset = sq->rela->r_offset;
+ }
+
+ qsort (s_non_relative, count - ret, sort_elt, elf_link_sort_cmp2);
+
+ for (lo = reldyn->link_order_head; lo != NULL; lo = lo->next)
+ if (lo->type == bfd_indirect_link_order)
+ {
+ bfd_byte *erel, *erelend;
+ asection *o = lo->u.indirect.section;
+
+ erel = o->contents;
+ erelend = o->contents + o->_raw_size;
+ p = sort + o->output_offset / ext_size * sort_elt;
+ while (erel < erelend)
+ {
+ struct elf_link_sort_rela *s = (struct elf_link_sort_rela *) p;
+ (*swap_out) (abfd, s->rela, erel);
+ p += sort_elt;
+ erel += ext_size;
+ }
+ }
+
+ free (sort);
+ *psec = reldyn;
+ return ret;
+}
+
+/* Flush the output symbols to the file. */
+
+static bfd_boolean
+elf_link_flush_output_syms (struct elf_final_link_info *finfo,
+ const struct elf_backend_data *bed)
+{
+ if (finfo->symbuf_count > 0)
+ {
+ Elf_Internal_Shdr *hdr;
+ file_ptr pos;
+ bfd_size_type amt;
+
+ hdr = &elf_tdata (finfo->output_bfd)->symtab_hdr;
+ pos = hdr->sh_offset + hdr->sh_size;
+ amt = finfo->symbuf_count * bed->s->sizeof_sym;
+ if (bfd_seek (finfo->output_bfd, pos, SEEK_SET) != 0
+ || bfd_bwrite (finfo->symbuf, amt, finfo->output_bfd) != amt)
+ return FALSE;
+
+ hdr->sh_size += amt;
+ finfo->symbuf_count = 0;
+ }
+
+ return TRUE;
+}
+
+/* Add a symbol to the output symbol table. */
+
+static bfd_boolean
+elf_link_output_sym (struct elf_final_link_info *finfo,
+ const char *name,
+ Elf_Internal_Sym *elfsym,
+ asection *input_sec,
+ struct elf_link_hash_entry *h)
+{
+ bfd_byte *dest;
+ Elf_External_Sym_Shndx *destshndx;
+ bfd_boolean (*output_symbol_hook)
+ (struct bfd_link_info *, const char *, Elf_Internal_Sym *, asection *,
+ struct elf_link_hash_entry *);
+ const struct elf_backend_data *bed;
+
+ bed = get_elf_backend_data (finfo->output_bfd);
+ output_symbol_hook = bed->elf_backend_link_output_symbol_hook;
+ if (output_symbol_hook != NULL)
+ {
+ if (! (*output_symbol_hook) (finfo->info, name, elfsym, input_sec, h))
+ return FALSE;
+ }
+
+ if (name == NULL || *name == '\0')
+ elfsym->st_name = 0;
+ else if (input_sec->flags & SEC_EXCLUDE)
+ elfsym->st_name = 0;
+ else
+ {
+ elfsym->st_name = (unsigned long) _bfd_stringtab_add (finfo->symstrtab,
+ name, TRUE, FALSE);
+ if (elfsym->st_name == (unsigned long) -1)
+ return FALSE;
+ }
+
+ if (finfo->symbuf_count >= finfo->symbuf_size)
+ {
+ if (! elf_link_flush_output_syms (finfo, bed))
+ return FALSE;
+ }
+
+ dest = finfo->symbuf + finfo->symbuf_count * bed->s->sizeof_sym;
+ destshndx = finfo->symshndxbuf;
+ if (destshndx != NULL)
+ {
+ if (bfd_get_symcount (finfo->output_bfd) >= finfo->shndxbuf_size)
+ {
+ bfd_size_type amt;
+
+ amt = finfo->shndxbuf_size * sizeof (Elf_External_Sym_Shndx);
+ finfo->symshndxbuf = destshndx = bfd_realloc (destshndx, amt * 2);
+ if (destshndx == NULL)
+ return FALSE;
+ memset ((char *) destshndx + amt, 0, amt);
+ finfo->shndxbuf_size *= 2;
+ }
+ destshndx += bfd_get_symcount (finfo->output_bfd);
+ }
+
+ bed->s->swap_symbol_out (finfo->output_bfd, elfsym, dest, destshndx);
+ finfo->symbuf_count += 1;
+ bfd_get_symcount (finfo->output_bfd) += 1;
+
+ return TRUE;
+}
+
+/* For DSOs loaded in via a DT_NEEDED entry, emulate ld.so in
+ allowing an unsatisfied unversioned symbol in the DSO to match a
+ versioned symbol that would normally require an explicit version.
+ We also handle the case that a DSO references a hidden symbol
+ which may be satisfied by a versioned symbol in another DSO. */
+
+static bfd_boolean
+elf_link_check_versioned_symbol (struct bfd_link_info *info,
+ const struct elf_backend_data *bed,
+ struct elf_link_hash_entry *h)
+{
+ bfd *abfd;
+ struct elf_link_loaded_list *loaded;
+
+ if (!is_elf_hash_table (info->hash))
+ return FALSE;
+
+ switch (h->root.type)
+ {
+ default:
+ abfd = NULL;
+ break;
+
+ case bfd_link_hash_undefined:
+ case bfd_link_hash_undefweak:
+ abfd = h->root.u.undef.abfd;
+ if ((abfd->flags & DYNAMIC) == 0
+ || elf_dyn_lib_class (abfd) != DYN_DT_NEEDED)
+ return FALSE;
+ break;
+
+ case bfd_link_hash_defined:
+ case bfd_link_hash_defweak:
+ abfd = h->root.u.def.section->owner;
+ break;
+
+ case bfd_link_hash_common:
+ abfd = h->root.u.c.p->section->owner;
+ break;
+ }
+ BFD_ASSERT (abfd != NULL);
+
+ for (loaded = elf_hash_table (info)->loaded;
+ loaded != NULL;
+ loaded = loaded->next)
+ {
+ bfd *input;
+ Elf_Internal_Shdr *hdr;
+ bfd_size_type symcount;
+ bfd_size_type extsymcount;
+ bfd_size_type extsymoff;
+ Elf_Internal_Shdr *versymhdr;
+ Elf_Internal_Sym *isym;
+ Elf_Internal_Sym *isymend;
+ Elf_Internal_Sym *isymbuf;
+ Elf_External_Versym *ever;
+ Elf_External_Versym *extversym;
+
+ input = loaded->abfd;
+
+ /* We check each DSO for a possible hidden versioned definition. */
+ if (input == abfd
+ || (input->flags & DYNAMIC) == 0
+ || elf_dynversym (input) == 0)
+ continue;
+
+ hdr = &elf_tdata (input)->dynsymtab_hdr;
+
+ symcount = hdr->sh_size / bed->s->sizeof_sym;
+ if (elf_bad_symtab (input))
+ {
+ extsymcount = symcount;
+ extsymoff = 0;
+ }
+ else
+ {
+ extsymcount = symcount - hdr->sh_info;
+ extsymoff = hdr->sh_info;
+ }
+
+ if (extsymcount == 0)
+ continue;
+
+ isymbuf = bfd_elf_get_elf_syms (input, hdr, extsymcount, extsymoff,
+ NULL, NULL, NULL);
+ if (isymbuf == NULL)
+ return FALSE;
+
+ /* Read in any version definitions. */
+ versymhdr = &elf_tdata (input)->dynversym_hdr;
+ extversym = bfd_malloc (versymhdr->sh_size);
+ if (extversym == NULL)
+ goto error_ret;
+
+ if (bfd_seek (input, versymhdr->sh_offset, SEEK_SET) != 0
+ || (bfd_bread (extversym, versymhdr->sh_size, input)
+ != versymhdr->sh_size))
+ {
+ free (extversym);
+ error_ret:
+ free (isymbuf);
+ return FALSE;
+ }
+
+ ever = extversym + extsymoff;
+ isymend = isymbuf + extsymcount;
+ for (isym = isymbuf; isym < isymend; isym++, ever++)
+ {
+ const char *name;
+ Elf_Internal_Versym iver;
+ unsigned short version_index;
+
+ if (ELF_ST_BIND (isym->st_info) == STB_LOCAL
+ || isym->st_shndx == SHN_UNDEF)
+ continue;
+
+ name = bfd_elf_string_from_elf_section (input,
+ hdr->sh_link,
+ isym->st_name);
+ if (strcmp (name, h->root.root.string) != 0)
+ continue;
+
+ _bfd_elf_swap_versym_in (input, ever, &iver);
+
+ if ((iver.vs_vers & VERSYM_HIDDEN) == 0)
+ {
+ /* If we have a non-hidden versioned sym, then it should
+ have provided a definition for the undefined sym. */
+ abort ();
+ }
+
+ version_index = iver.vs_vers & VERSYM_VERSION;
+ if (version_index == 1 || version_index == 2)
+ {
+ /* This is the base or first version. We can use it. */
+ free (extversym);
+ free (isymbuf);
+ return TRUE;
+ }
+ }
+
+ free (extversym);
+ free (isymbuf);
+ }
+
+ return FALSE;
+}
+
+/* Add an external symbol to the symbol table. This is called from
+ the hash table traversal routine. When generating a shared object,
+ we go through the symbol table twice. The first time we output
+ anything that might have been forced to local scope in a version
+ script. The second time we output the symbols that are still
+ global symbols. */
+
+static bfd_boolean
+elf_link_output_extsym (struct elf_link_hash_entry *h, void *data)
+{
+ struct elf_outext_info *eoinfo = data;
+ struct elf_final_link_info *finfo = eoinfo->finfo;
+ bfd_boolean strip;
+ Elf_Internal_Sym sym;
+ asection *input_sec;
+ const struct elf_backend_data *bed;
+
+ if (h->root.type == bfd_link_hash_warning)
+ {
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+ if (h->root.type == bfd_link_hash_new)
+ return TRUE;
+ }
+
+ /* Decide whether to output this symbol in this pass. */
+ if (eoinfo->localsyms)
+ {
+ if ((h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
+ return TRUE;
+ }
+ else
+ {
+ if ((h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0)
+ return TRUE;
+ }
+
+ bed = get_elf_backend_data (finfo->output_bfd);
+
+ /* If we have an undefined symbol reference here then it must have
+ come from a shared library that is being linked in. (Undefined
+ references in regular files have already been handled). If we
+ are reporting errors for this situation then do so now. */
+ if (h->root.type == bfd_link_hash_undefined
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) != 0
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_REGULAR) == 0
+ && ! elf_link_check_versioned_symbol (finfo->info, bed, h)
+ && finfo->info->unresolved_syms_in_shared_libs != RM_IGNORE)
+ {
+ if (! ((*finfo->info->callbacks->undefined_symbol)
+ (finfo->info, h->root.root.string, h->root.u.undef.abfd,
+ NULL, 0, finfo->info->unresolved_syms_in_shared_libs == RM_GENERATE_ERROR)))
+ {
+ eoinfo->failed = TRUE;
+ return FALSE;
+ }
+ }
+
+ /* We should also warn if a forced local symbol is referenced from
+ shared libraries. */
+ if (! finfo->info->relocatable
+ && (! finfo->info->shared)
+ && (h->elf_link_hash_flags
+ & (ELF_LINK_FORCED_LOCAL | ELF_LINK_HASH_REF_DYNAMIC | ELF_LINK_DYNAMIC_DEF | ELF_LINK_DYNAMIC_WEAK))
+ == (ELF_LINK_FORCED_LOCAL | ELF_LINK_HASH_REF_DYNAMIC)
+ && ! elf_link_check_versioned_symbol (finfo->info, bed, h))
+ {
+ (*_bfd_error_handler)
+ (_("%s: %s symbol `%s' in %s is referenced by DSO"),
+ bfd_get_filename (finfo->output_bfd),
+ ELF_ST_VISIBILITY (h->other) == STV_INTERNAL
+ ? "internal"
+ : ELF_ST_VISIBILITY (h->other) == STV_HIDDEN
+ ? "hidden" : "local",
+ h->root.root.string,
+ bfd_archive_filename (h->root.u.def.section->owner));
+ eoinfo->failed = TRUE;
+ return FALSE;
+ }
+
+ /* We don't want to output symbols that have never been mentioned by
+ a regular file, or that we have been told to strip. However, if
+ h->indx is set to -2, the symbol is used by a reloc and we must
+ output it. */
+ if (h->indx == -2)
+ strip = FALSE;
+ else if (((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_DYNAMIC) != 0
+ || (h->elf_link_hash_flags & ELF_LINK_HASH_REF_DYNAMIC) != 0)
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_REGULAR) == 0)
+ strip = TRUE;
+ else if (finfo->info->strip == strip_all)
+ strip = TRUE;
+ else if (finfo->info->strip == strip_some
+ && bfd_hash_lookup (finfo->info->keep_hash,
+ h->root.root.string, FALSE, FALSE) == NULL)
+ strip = TRUE;
+ else if (finfo->info->strip_discarded
+ && (h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak)
+ && elf_discarded_section (h->root.u.def.section))
+ strip = TRUE;
+ else
+ strip = FALSE;
+
+ /* If we're stripping it, and it's not a dynamic symbol, there's
+ nothing else to do unless it is a forced local symbol. */
+ if (strip
+ && h->dynindx == -1
+ && (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
+ return TRUE;
+
+ sym.st_value = 0;
+ sym.st_size = h->size;
+ sym.st_other = h->other;
+ if ((h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0)
+ sym.st_info = ELF_ST_INFO (STB_LOCAL, h->type);
+ else if (h->root.type == bfd_link_hash_undefweak
+ || h->root.type == bfd_link_hash_defweak)
+ sym.st_info = ELF_ST_INFO (STB_WEAK, h->type);
+ else
+ sym.st_info = ELF_ST_INFO (STB_GLOBAL, h->type);
+
+ switch (h->root.type)
+ {
+ default:
+ case bfd_link_hash_new:
+ case bfd_link_hash_warning:
+ abort ();
+ return FALSE;
+
+ case bfd_link_hash_undefined:
+ case bfd_link_hash_undefweak:
+ input_sec = bfd_und_section_ptr;
+ sym.st_shndx = SHN_UNDEF;
+ break;
+
+ case bfd_link_hash_defined:
+ case bfd_link_hash_defweak:
+ {
+ input_sec = h->root.u.def.section;
+ if (input_sec->output_section != NULL)
+ {
+ sym.st_shndx =
+ _bfd_elf_section_from_bfd_section (finfo->output_bfd,
+ input_sec->output_section);
+ if (sym.st_shndx == SHN_BAD)
+ {
+ (*_bfd_error_handler)
+ (_("%s: could not find output section %s for input section %s"),
+ bfd_get_filename (finfo->output_bfd),
+ input_sec->output_section->name,
+ input_sec->name);
+ eoinfo->failed = TRUE;
+ return FALSE;
+ }
+
+ /* ELF symbols in relocatable files are section relative,
+ but in nonrelocatable files they are virtual
+ addresses. */
+ sym.st_value = h->root.u.def.value + input_sec->output_offset;
+ if (! finfo->info->relocatable)
+ {
+ sym.st_value += input_sec->output_section->vma;
+ if (h->type == STT_TLS)
+ {
+ /* STT_TLS symbols are relative to PT_TLS segment
+ base. */
+ BFD_ASSERT (elf_hash_table (finfo->info)->tls_sec != NULL);
+ sym.st_value -= elf_hash_table (finfo->info)->tls_sec->vma;
+ }
+ }
+ }
+ else
+ {
+ BFD_ASSERT (input_sec->owner == NULL
+ || (input_sec->owner->flags & DYNAMIC) != 0);
+ sym.st_shndx = SHN_UNDEF;
+ input_sec = bfd_und_section_ptr;
+ }
+ }
+ break;
+
+ case bfd_link_hash_common:
+ input_sec = h->root.u.c.p->section;
+ sym.st_shndx = SHN_COMMON;
+ sym.st_value = 1 << h->root.u.c.p->alignment_power;
+ break;
+
+ case bfd_link_hash_indirect:
+ /* These symbols are created by symbol versioning. They point
+ to the decorated version of the name. For example, if the
+ symbol foo@@GNU_1.2 is the default, which should be used when
+ foo is used with no version, then we add an indirect symbol
+ foo which points to foo@@GNU_1.2. We ignore these symbols,
+ since the indirected symbol is already in the hash table. */
+ return TRUE;
+ }
+
+ /* Give the processor backend a chance to tweak the symbol value,
+ and also to finish up anything that needs to be done for this
+ symbol. FIXME: Not calling elf_backend_finish_dynamic_symbol for
+ forced local syms when non-shared is due to a historical quirk. */
+ if ((h->dynindx != -1
+ || (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) != 0)
+ && ((finfo->info->shared
+ && (ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak))
+ || (h->elf_link_hash_flags & ELF_LINK_FORCED_LOCAL) == 0)
+ && elf_hash_table (finfo->info)->dynamic_sections_created)
+ {
+ if (! ((*bed->elf_backend_finish_dynamic_symbol)
+ (finfo->output_bfd, finfo->info, h, &sym)))
+ {
+ eoinfo->failed = TRUE;
+ return FALSE;
+ }
+ }
+
+ /* If we are marking the symbol as undefined, and there are no
+ non-weak references to this symbol from a regular object, then
+ mark the symbol as weak undefined; if there are non-weak
+ references, mark the symbol as strong. We can't do this earlier,
+ because it might not be marked as undefined until the
+ finish_dynamic_symbol routine gets through with it. */
+ if (sym.st_shndx == SHN_UNDEF
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_REF_REGULAR) != 0
+ && (ELF_ST_BIND (sym.st_info) == STB_GLOBAL
+ || ELF_ST_BIND (sym.st_info) == STB_WEAK))
+ {
+ int bindtype;
+
+ if ((h->elf_link_hash_flags & ELF_LINK_HASH_REF_REGULAR_NONWEAK) != 0)
+ bindtype = STB_GLOBAL;
+ else
+ bindtype = STB_WEAK;
+ sym.st_info = ELF_ST_INFO (bindtype, ELF_ST_TYPE (sym.st_info));
+ }
+
+ /* If a non-weak symbol with non-default visibility is not defined
+ locally, it is a fatal error. */
+ if (! finfo->info->relocatable
+ && ELF_ST_VISIBILITY (sym.st_other) != STV_DEFAULT
+ && ELF_ST_BIND (sym.st_info) != STB_WEAK
+ && h->root.type == bfd_link_hash_undefined
+ && (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
+ {
+ (*_bfd_error_handler)
+ (_("%s: %s symbol `%s' isn't defined"),
+ bfd_get_filename (finfo->output_bfd),
+ ELF_ST_VISIBILITY (sym.st_other) == STV_PROTECTED
+ ? "protected"
+ : ELF_ST_VISIBILITY (sym.st_other) == STV_INTERNAL
+ ? "internal" : "hidden",
+ h->root.root.string);
+ eoinfo->failed = TRUE;
+ return FALSE;
+ }
+
+ /* If this symbol should be put in the .dynsym section, then put it
+ there now. We already know the symbol index. We also fill in
+ the entry in the .hash section. */
+ if (h->dynindx != -1
+ && elf_hash_table (finfo->info)->dynamic_sections_created)
+ {
+ size_t bucketcount;
+ size_t bucket;
+ size_t hash_entry_size;
+ bfd_byte *bucketpos;
+ bfd_vma chain;
+ bfd_byte *esym;
+
+ sym.st_name = h->dynstr_index;
+ esym = finfo->dynsym_sec->contents + h->dynindx * bed->s->sizeof_sym;
+ bed->s->swap_symbol_out (finfo->output_bfd, &sym, esym, 0);
+
+ bucketcount = elf_hash_table (finfo->info)->bucketcount;
+ bucket = h->elf_hash_value % bucketcount;
+ hash_entry_size
+ = elf_section_data (finfo->hash_sec)->this_hdr.sh_entsize;
+ bucketpos = ((bfd_byte *) finfo->hash_sec->contents
+ + (bucket + 2) * hash_entry_size);
+ chain = bfd_get (8 * hash_entry_size, finfo->output_bfd, bucketpos);
+ bfd_put (8 * hash_entry_size, finfo->output_bfd, h->dynindx, bucketpos);
+ bfd_put (8 * hash_entry_size, finfo->output_bfd, chain,
+ ((bfd_byte *) finfo->hash_sec->contents
+ + (bucketcount + 2 + h->dynindx) * hash_entry_size));
+
+ if (finfo->symver_sec != NULL && finfo->symver_sec->contents != NULL)
+ {
+ Elf_Internal_Versym iversym;
+ Elf_External_Versym *eversym;
+
+ if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
+ {
+ if (h->verinfo.verdef == NULL)
+ iversym.vs_vers = 0;
+ else
+ iversym.vs_vers = h->verinfo.verdef->vd_exp_refno + 1;
+ }
+ else
+ {
+ if (h->verinfo.vertree == NULL)
+ iversym.vs_vers = 1;
+ else
+ iversym.vs_vers = h->verinfo.vertree->vernum + 1;
+ }
+
+ if ((h->elf_link_hash_flags & ELF_LINK_HIDDEN) != 0)
+ iversym.vs_vers |= VERSYM_HIDDEN;
+
+ eversym = (Elf_External_Versym *) finfo->symver_sec->contents;
+ eversym += h->dynindx;
+ _bfd_elf_swap_versym_out (finfo->output_bfd, &iversym, eversym);
+ }
+ }
+
+ /* If we're stripping it, then it was just a dynamic symbol, and
+ there's nothing else to do. */
+ if (strip || (input_sec->flags & SEC_EXCLUDE) != 0)
+ return TRUE;
+
+ h->indx = bfd_get_symcount (finfo->output_bfd);
+
+ if (! elf_link_output_sym (finfo, h->root.root.string, &sym, input_sec, h))
+ {
+ eoinfo->failed = TRUE;
+ return FALSE;
+ }
+
+ return TRUE;
+}
+
+static bfd_boolean
+elf_section_ignore_discarded_relocs (asection *sec)
+{
+ const struct elf_backend_data *bed;
+
+ switch (sec->sec_info_type)
+ {
+ case ELF_INFO_TYPE_STABS:
+ case ELF_INFO_TYPE_EH_FRAME:
+ return TRUE;
+ default:
+ break;
+ }
+
+ bed = get_elf_backend_data (sec->owner);
+ if (bed->elf_backend_ignore_discarded_relocs != NULL
+ && (*bed->elf_backend_ignore_discarded_relocs) (sec))
+ return TRUE;
+
+ return FALSE;
+}
+
+/* Link an input file into the linker output file. This function
+ handles all the sections and relocations of the input file at once.
+ This is so that we only have to read the local symbols once, and
+ don't have to keep them in memory. */
+
+static bfd_boolean
+elf_link_input_bfd (struct elf_final_link_info *finfo, bfd *input_bfd)
+{
+ bfd_boolean (*relocate_section)
+ (bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
+ Elf_Internal_Rela *, Elf_Internal_Sym *, asection **);
+ bfd *output_bfd;
+ Elf_Internal_Shdr *symtab_hdr;
+ size_t locsymcount;
+ size_t extsymoff;
+ Elf_Internal_Sym *isymbuf;
+ Elf_Internal_Sym *isym;
+ Elf_Internal_Sym *isymend;
+ long *pindex;
+ asection **ppsection;
+ asection *o;
+ const struct elf_backend_data *bed;
+ bfd_boolean emit_relocs;
+ struct elf_link_hash_entry **sym_hashes;
+
+ output_bfd = finfo->output_bfd;
+ bed = get_elf_backend_data (output_bfd);
+ relocate_section = bed->elf_backend_relocate_section;
+
+ /* If this is a dynamic object, we don't want to do anything here:
+ we don't want the local symbols, and we don't want the section
+ contents. */
+ if ((input_bfd->flags & DYNAMIC) != 0)
+ return TRUE;
+
+ emit_relocs = (finfo->info->relocatable
+ || finfo->info->emitrelocations
+ || bed->elf_backend_emit_relocs);
+
+ symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
+ if (elf_bad_symtab (input_bfd))
+ {
+ locsymcount = symtab_hdr->sh_size / bed->s->sizeof_sym;
+ extsymoff = 0;
+ }
+ else
+ {
+ locsymcount = symtab_hdr->sh_info;
+ extsymoff = symtab_hdr->sh_info;
+ }
+
+ /* Read the local symbols. */
+ isymbuf = (Elf_Internal_Sym *) symtab_hdr->contents;
+ if (isymbuf == NULL && locsymcount != 0)
+ {
+ isymbuf = bfd_elf_get_elf_syms (input_bfd, symtab_hdr, locsymcount, 0,
+ finfo->internal_syms,
+ finfo->external_syms,
+ finfo->locsym_shndx);
+ if (isymbuf == NULL)
+ return FALSE;
+ }
+
+ /* Find local symbol sections and adjust values of symbols in
+ SEC_MERGE sections. Write out those local symbols we know are
+ going into the output file. */
+ isymend = isymbuf + locsymcount;
+ for (isym = isymbuf, pindex = finfo->indices, ppsection = finfo->sections;
+ isym < isymend;
+ isym++, pindex++, ppsection++)
+ {
+ asection *isec;
+ const char *name;
+ Elf_Internal_Sym osym;
+
+ *pindex = -1;
+
+ if (elf_bad_symtab (input_bfd))
+ {
+ if (ELF_ST_BIND (isym->st_info) != STB_LOCAL)
+ {
+ *ppsection = NULL;
+ continue;
+ }
+ }
+
+ if (isym->st_shndx == SHN_UNDEF)
+ isec = bfd_und_section_ptr;
+ else if (isym->st_shndx < SHN_LORESERVE
+ || isym->st_shndx > SHN_HIRESERVE)
+ {
+ isec = bfd_section_from_elf_index (input_bfd, isym->st_shndx);
+ if (isec
+ && isec->sec_info_type == ELF_INFO_TYPE_MERGE
+ && ELF_ST_TYPE (isym->st_info) != STT_SECTION)
+ isym->st_value =
+ _bfd_merged_section_offset (output_bfd, &isec,
+ elf_section_data (isec)->sec_info,
+ isym->st_value, 0);
+ }
+ else if (isym->st_shndx == SHN_ABS)
+ isec = bfd_abs_section_ptr;
+ else if (isym->st_shndx == SHN_COMMON)
+ isec = bfd_com_section_ptr;
+ else
+ {
+ /* Who knows? */
+ isec = NULL;
+ }
+
+ *ppsection = isec;
+
+ /* Don't output the first, undefined, symbol. */
+ if (ppsection == finfo->sections)
+ continue;
+
+ if (ELF_ST_TYPE (isym->st_info) == STT_SECTION)
+ {
+ /* We never output section symbols. Instead, we use the
+ section symbol of the corresponding section in the output
+ file. */
+ continue;
+ }
+
+ /* If we are stripping all symbols, we don't want to output this
+ one. */
+ if (finfo->info->strip == strip_all)
+ continue;
+
+ /* If we are discarding all local symbols, we don't want to
+ output this one. If we are generating a relocatable output
+ file, then some of the local symbols may be required by
+ relocs; we output them below as we discover that they are
+ needed. */
+ if (finfo->info->discard == discard_all)
+ continue;
+
+ /* If this symbol is defined in a section which we are
+ discarding, we don't need to keep it, but note that
+ linker_mark is only reliable for sections that have contents.
+ For the benefit of the MIPS ELF linker, we check SEC_EXCLUDE
+ as well as linker_mark. */
+ if ((isym->st_shndx < SHN_LORESERVE || isym->st_shndx > SHN_HIRESERVE)
+ && isec != NULL
+ && ((! isec->linker_mark && (isec->flags & SEC_HAS_CONTENTS) != 0)
+ || (! finfo->info->relocatable
+ && (isec->flags & SEC_EXCLUDE) != 0)))
+ continue;
+
+ /* Get the name of the symbol. */
+ name = bfd_elf_string_from_elf_section (input_bfd, symtab_hdr->sh_link,
+ isym->st_name);
+ if (name == NULL)
+ return FALSE;
+
+ /* See if we are discarding symbols with this name. */
+ if ((finfo->info->strip == strip_some
+ && (bfd_hash_lookup (finfo->info->keep_hash, name, FALSE, FALSE)
+ == NULL))
+ || (((finfo->info->discard == discard_sec_merge
+ && (isec->flags & SEC_MERGE) && ! finfo->info->relocatable)
+ || finfo->info->discard == discard_l)
+ && bfd_is_local_label_name (input_bfd, name)))
+ continue;
+
+ /* If we get here, we are going to output this symbol. */
+
+ osym = *isym;
+
+ /* Adjust the section index for the output file. */
+ osym.st_shndx = _bfd_elf_section_from_bfd_section (output_bfd,
+ isec->output_section);
+ if (osym.st_shndx == SHN_BAD)
+ return FALSE;
+
+ *pindex = bfd_get_symcount (output_bfd);
+
+ /* ELF symbols in relocatable files are section relative, but
+ in executable files they are virtual addresses. Note that
+ this code assumes that all ELF sections have an associated
+ BFD section with a reasonable value for output_offset; below
+ we assume that they also have a reasonable value for
+ output_section. Any special sections must be set up to meet
+ these requirements. */
+ osym.st_value += isec->output_offset;
+ if (! finfo->info->relocatable)
+ {
+ osym.st_value += isec->output_section->vma;
+ if (ELF_ST_TYPE (osym.st_info) == STT_TLS)
+ {
+ /* STT_TLS symbols are relative to PT_TLS segment base. */
+ BFD_ASSERT (elf_hash_table (finfo->info)->tls_sec != NULL);
+ osym.st_value -= elf_hash_table (finfo->info)->tls_sec->vma;
+ }
+ }
+
+ if (! elf_link_output_sym (finfo, name, &osym, isec, NULL))
+ return FALSE;
+ }
+
+ /* Relocate the contents of each section. */
+ sym_hashes = elf_sym_hashes (input_bfd);
+ for (o = input_bfd->sections; o != NULL; o = o->next)
+ {
+ bfd_byte *contents;
+
+ if (! o->linker_mark)
+ {
+ /* This section was omitted from the link. */
+ continue;
+ }
+
+ if ((o->flags & SEC_HAS_CONTENTS) == 0
+ || (o->_raw_size == 0 && (o->flags & SEC_RELOC) == 0))
+ continue;
+
+ if ((o->flags & SEC_LINKER_CREATED) != 0)
+ {
+ /* Section was created by _bfd_elf_link_create_dynamic_sections
+ or somesuch. */
+ continue;
+ }
+
+ /* Get the contents of the section. They have been cached by a
+ relaxation routine. Note that o is a section in an input
+ file, so the contents field will not have been set by any of
+ the routines which work on output files. */
+ if (elf_section_data (o)->this_hdr.contents != NULL)
+ contents = elf_section_data (o)->this_hdr.contents;
+ else
+ {
+ contents = finfo->contents;
+ if (! bfd_get_section_contents (input_bfd, o, contents, 0,
+ o->_raw_size))
+ return FALSE;
+ }
+
+ if ((o->flags & SEC_RELOC) != 0)
+ {
+ Elf_Internal_Rela *internal_relocs;
+ bfd_vma r_type_mask;
+ int r_sym_shift;
+
+ /* Get the swapped relocs. */
+ internal_relocs
+ = _bfd_elf_link_read_relocs (input_bfd, o, finfo->external_relocs,
+ finfo->internal_relocs, FALSE);
+ if (internal_relocs == NULL
+ && o->reloc_count > 0)
+ return FALSE;
+
+ if (bed->s->arch_size == 32)
+ {
+ r_type_mask = 0xff;
+ r_sym_shift = 8;
+ }
+ else
+ {
+ r_type_mask = 0xffffffff;
+ r_sym_shift = 32;
+ }
+
+ /* Run through the relocs looking for any against symbols
+ from discarded sections and section symbols from
+ removed link-once sections. Complain about relocs
+ against discarded sections. Zero relocs against removed
+ link-once sections. Preserve debug information as much
+ as we can. */
+ if (!elf_section_ignore_discarded_relocs (o))
+ {
+ Elf_Internal_Rela *rel, *relend;
+
+ rel = internal_relocs;
+ relend = rel + o->reloc_count * bed->s->int_rels_per_ext_rel;
+ for ( ; rel < relend; rel++)
+ {
+ unsigned long r_symndx = rel->r_info >> r_sym_shift;
+ asection *sec;
+
+ if (r_symndx >= locsymcount
+ || (elf_bad_symtab (input_bfd)
+ && finfo->sections[r_symndx] == NULL))
+ {
+ struct elf_link_hash_entry *h;
+
+ h = sym_hashes[r_symndx - extsymoff];
+ while (h->root.type == bfd_link_hash_indirect
+ || h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ /* Complain if the definition comes from a
+ discarded section. */
+ sec = h->root.u.def.section;
+ if ((h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak)
+ && elf_discarded_section (sec))
+ {
+ if ((o->flags & SEC_DEBUGGING) != 0)
+ {
+ BFD_ASSERT (r_symndx != 0);
+ /* Try to preserve debug information. */
+ if ((o->flags & SEC_DEBUGGING) != 0
+ && sec->kept_section != NULL
+ && sec->_raw_size == sec->kept_section->_raw_size)
+ h->root.u.def.section
+ = sec->kept_section;
+ else
+ memset (rel, 0, sizeof (*rel));
+ }
+ else
+ finfo->info->callbacks->error_handler
+ (LD_DEFINITION_IN_DISCARDED_SECTION,
+ _("%T: discarded in section `%s' from %s\n"),
+ h->root.root.string,
+ h->root.root.string,
+ h->root.u.def.section->name,
+ bfd_archive_filename (h->root.u.def.section->owner));
+ }
+ }
+ else
+ {
+ sec = finfo->sections[r_symndx];
+
+ if (sec != NULL && elf_discarded_section (sec))
+ {
+ if ((o->flags & SEC_DEBUGGING) != 0
+ || (sec->flags & SEC_LINK_ONCE) != 0)
+ {
+ BFD_ASSERT (r_symndx != 0);
+ /* Try to preserve debug information. */
+ if ((o->flags & SEC_DEBUGGING) != 0
+ && sec->kept_section != NULL
+ && sec->_raw_size == sec->kept_section->_raw_size)
+ finfo->sections[r_symndx]
+ = sec->kept_section;
+ else
+ {
+ rel->r_info &= r_type_mask;
+ rel->r_addend = 0;
+ }
+ }
+ else
+ {
+ static int count;
+ int ok;
+ char *buf;
+
+ ok = asprintf (&buf, "local symbol %d",
+ count++);
+ if (ok <= 0)
+ buf = (char *) "local symbol";
+ finfo->info->callbacks->error_handler
+ (LD_DEFINITION_IN_DISCARDED_SECTION,
+ _("%T: discarded in section `%s' from %s\n"),
+ buf, buf, sec->name,
+ bfd_archive_filename (input_bfd));
+ if (ok != -1)
+ free (buf);
+ }
+ }
+ }
+ }
+ }
+
+ /* Relocate the section by invoking a back end routine.
+
+ The back end routine is responsible for adjusting the
+ section contents as necessary, and (if using Rela relocs
+ and generating a relocatable output file) adjusting the
+ reloc addend as necessary.
+
+ The back end routine does not have to worry about setting
+ the reloc address or the reloc symbol index.
+
+ The back end routine is given a pointer to the swapped in
+ internal symbols, and can access the hash table entries
+ for the external symbols via elf_sym_hashes (input_bfd).
+
+ When generating relocatable output, the back end routine
+ must handle STB_LOCAL/STT_SECTION symbols specially. The
+ output symbol is going to be a section symbol
+ corresponding to the output section, which will require
+ the addend to be adjusted. */
+
+ if (! (*relocate_section) (output_bfd, finfo->info,
+ input_bfd, o, contents,
+ internal_relocs,
+ isymbuf,
+ finfo->sections))
+ return FALSE;
+
+ if (emit_relocs)
+ {
+ Elf_Internal_Rela *irela;
+ Elf_Internal_Rela *irelaend;
+ bfd_vma last_offset;
+ struct elf_link_hash_entry **rel_hash;
+ Elf_Internal_Shdr *input_rel_hdr, *input_rel_hdr2;
+ unsigned int next_erel;
+ bfd_boolean (*reloc_emitter)
+ (bfd *, asection *, Elf_Internal_Shdr *, Elf_Internal_Rela *);
+ bfd_boolean rela_normal;
+
+ input_rel_hdr = &elf_section_data (o)->rel_hdr;
+ rela_normal = (bed->rela_normal
+ && (input_rel_hdr->sh_entsize
+ == bed->s->sizeof_rela));
+
+ /* Adjust the reloc addresses and symbol indices. */
+
+ irela = internal_relocs;
+ irelaend = irela + o->reloc_count * bed->s->int_rels_per_ext_rel;
+ rel_hash = (elf_section_data (o->output_section)->rel_hashes
+ + elf_section_data (o->output_section)->rel_count
+ + elf_section_data (o->output_section)->rel_count2);
+ last_offset = o->output_offset;
+ if (!finfo->info->relocatable)
+ last_offset += o->output_section->vma;
+ for (next_erel = 0; irela < irelaend; irela++, next_erel++)
+ {
+ unsigned long r_symndx;
+ asection *sec;
+ Elf_Internal_Sym sym;
+
+ if (next_erel == bed->s->int_rels_per_ext_rel)
+ {
+ rel_hash++;
+ next_erel = 0;
+ }
+
+ irela->r_offset = _bfd_elf_section_offset (output_bfd,
+ finfo->info, o,
+ irela->r_offset);
+ if (irela->r_offset >= (bfd_vma) -2)
+ {
+ /* This is a reloc for a deleted entry or somesuch.
+ Turn it into an R_*_NONE reloc, at the same
+ offset as the last reloc. elf_eh_frame.c and
+ elf_bfd_discard_info rely on reloc offsets
+ being ordered. */
+ irela->r_offset = last_offset;
+ irela->r_info = 0;
+ irela->r_addend = 0;
+ continue;
+ }
+
+ irela->r_offset += o->output_offset;
+
+ /* Relocs in an executable have to be virtual addresses. */
+ if (!finfo->info->relocatable)
+ irela->r_offset += o->output_section->vma;
+
+ last_offset = irela->r_offset;
+
+ r_symndx = irela->r_info >> r_sym_shift;
+ if (r_symndx == STN_UNDEF)
+ continue;
+
+ if (r_symndx >= locsymcount
+ || (elf_bad_symtab (input_bfd)
+ && finfo->sections[r_symndx] == NULL))
+ {
+ struct elf_link_hash_entry *rh;
+ unsigned long indx;
+
+ /* This is a reloc against a global symbol. We
+ have not yet output all the local symbols, so
+ we do not know the symbol index of any global
+ symbol. We set the rel_hash entry for this
+ reloc to point to the global hash table entry
+ for this symbol. The symbol index is then
+ set at the end of elf_bfd_final_link. */
+ indx = r_symndx - extsymoff;
+ rh = elf_sym_hashes (input_bfd)[indx];
+ while (rh->root.type == bfd_link_hash_indirect
+ || rh->root.type == bfd_link_hash_warning)
+ rh = (struct elf_link_hash_entry *) rh->root.u.i.link;
+
+ /* Setting the index to -2 tells
+ elf_link_output_extsym that this symbol is
+ used by a reloc. */
+ BFD_ASSERT (rh->indx < 0);
+ rh->indx = -2;
+
+ *rel_hash = rh;
+
+ continue;
+ }
+
+ /* This is a reloc against a local symbol. */
+
+ *rel_hash = NULL;
+ sym = isymbuf[r_symndx];
+ sec = finfo->sections[r_symndx];
+ if (ELF_ST_TYPE (sym.st_info) == STT_SECTION)
+ {
+ /* I suppose the backend ought to fill in the
+ section of any STT_SECTION symbol against a
+ processor specific section. If we have
+ discarded a section, the output_section will
+ be the absolute section. */
+ if (bfd_is_abs_section (sec)
+ || (sec != NULL
+ && bfd_is_abs_section (sec->output_section)))
+ r_symndx = 0;
+ else if (sec == NULL || sec->owner == NULL)
+ {
+ bfd_set_error (bfd_error_bad_value);
+ return FALSE;
+ }
+ else
+ {
+ r_symndx = sec->output_section->target_index;
+ BFD_ASSERT (r_symndx != 0);
+ }
+
+ /* Adjust the addend according to where the
+ section winds up in the output section. */
+ if (rela_normal)
+ irela->r_addend += sec->output_offset;
+ }
+ else
+ {
+ if (finfo->indices[r_symndx] == -1)
+ {
+ unsigned long shlink;
+ const char *name;
+ asection *osec;
+
+ if (finfo->info->strip == strip_all)
+ {
+ /* You can't do ld -r -s. */
+ bfd_set_error (bfd_error_invalid_operation);
+ return FALSE;
+ }
+
+ /* This symbol was skipped earlier, but
+ since it is needed by a reloc, we
+ must output it now. */
+ shlink = symtab_hdr->sh_link;
+ name = (bfd_elf_string_from_elf_section
+ (input_bfd, shlink, sym.st_name));
+ if (name == NULL)
+ return FALSE;
+
+ osec = sec->output_section;
+ sym.st_shndx =
+ _bfd_elf_section_from_bfd_section (output_bfd,
+ osec);
+ if (sym.st_shndx == SHN_BAD)
+ return FALSE;
+
+ sym.st_value += sec->output_offset;
+ if (! finfo->info->relocatable)
+ {
+ sym.st_value += osec->vma;
+ if (ELF_ST_TYPE (sym.st_info) == STT_TLS)
+ {
+ /* STT_TLS symbols are relative to PT_TLS
+ segment base. */
+ BFD_ASSERT (elf_hash_table (finfo->info)
+ ->tls_sec != NULL);
+ sym.st_value -= (elf_hash_table (finfo->info)
+ ->tls_sec->vma);
+ }
+ }
+
+ finfo->indices[r_symndx]
+ = bfd_get_symcount (output_bfd);
+
+ if (! elf_link_output_sym (finfo, name, &sym, sec,
+ NULL))
+ return FALSE;
+ }
+
+ r_symndx = finfo->indices[r_symndx];
+ }
+
+ irela->r_info = ((bfd_vma) r_symndx << r_sym_shift
+ | (irela->r_info & r_type_mask));
+ }
+
+ /* Swap out the relocs. */
+ if (bed->elf_backend_emit_relocs
+ && !(finfo->info->relocatable
+ || finfo->info->emitrelocations))
+ reloc_emitter = bed->elf_backend_emit_relocs;
+ else
+ reloc_emitter = _bfd_elf_link_output_relocs;
+
+ if (input_rel_hdr->sh_size != 0
+ && ! (*reloc_emitter) (output_bfd, o, input_rel_hdr,
+ internal_relocs))
+ return FALSE;
+
+ input_rel_hdr2 = elf_section_data (o)->rel_hdr2;
+ if (input_rel_hdr2 && input_rel_hdr2->sh_size != 0)
+ {
+ internal_relocs += (NUM_SHDR_ENTRIES (input_rel_hdr)
+ * bed->s->int_rels_per_ext_rel);
+ if (! (*reloc_emitter) (output_bfd, o, input_rel_hdr2,
+ internal_relocs))
+ return FALSE;
+ }
+ }
+ }
+
+ /* Write out the modified section contents. */
+ if (bed->elf_backend_write_section
+ && (*bed->elf_backend_write_section) (output_bfd, o, contents))
+ {
+ /* Section written out. */
+ }
+ else switch (o->sec_info_type)
+ {
+ case ELF_INFO_TYPE_STABS:
+ if (! (_bfd_write_section_stabs
+ (output_bfd,
+ &elf_hash_table (finfo->info)->stab_info,
+ o, &elf_section_data (o)->sec_info, contents)))
+ return FALSE;
+ break;
+ case ELF_INFO_TYPE_MERGE:
+ if (! _bfd_write_merged_section (output_bfd, o,
+ elf_section_data (o)->sec_info))
+ return FALSE;
+ break;
+ case ELF_INFO_TYPE_EH_FRAME:
+ {
+ if (! _bfd_elf_write_section_eh_frame (output_bfd, finfo->info,
+ o, contents))
+ return FALSE;
+ }
+ break;
+ default:
+ {
+ bfd_size_type sec_size;
+
+ sec_size = (o->_cooked_size != 0 ? o->_cooked_size : o->_raw_size);
+ if (! (o->flags & SEC_EXCLUDE)
+ && ! bfd_set_section_contents (output_bfd, o->output_section,
+ contents,
+ (file_ptr) o->output_offset,
+ sec_size))
+ return FALSE;
+ }
+ break;
+ }
+ }
+
+ return TRUE;
+}
+
+/* Generate a reloc when linking an ELF file. This is a reloc
+ requested by the linker, and does come from any input file. This
+ is used to build constructor and destructor tables when linking
+ with -Ur. */
+
+static bfd_boolean
+elf_reloc_link_order (bfd *output_bfd,
+ struct bfd_link_info *info,
+ asection *output_section,
+ struct bfd_link_order *link_order)
+{
+ reloc_howto_type *howto;
+ long indx;
+ bfd_vma offset;
+ bfd_vma addend;
+ struct elf_link_hash_entry **rel_hash_ptr;
+ Elf_Internal_Shdr *rel_hdr;
+ const struct elf_backend_data *bed = get_elf_backend_data (output_bfd);
+ Elf_Internal_Rela irel[MAX_INT_RELS_PER_EXT_REL];
+ bfd_byte *erel;
+ unsigned int i;
+
+ howto = bfd_reloc_type_lookup (output_bfd, link_order->u.reloc.p->reloc);
+ if (howto == NULL)
+ {
+ bfd_set_error (bfd_error_bad_value);
+ return FALSE;
+ }
+
+ addend = link_order->u.reloc.p->addend;
+
+ /* Figure out the symbol index. */
+ rel_hash_ptr = (elf_section_data (output_section)->rel_hashes
+ + elf_section_data (output_section)->rel_count
+ + elf_section_data (output_section)->rel_count2);
+ if (link_order->type == bfd_section_reloc_link_order)
+ {
+ indx = link_order->u.reloc.p->u.section->target_index;
+ BFD_ASSERT (indx != 0);
+ *rel_hash_ptr = NULL;
+ }
+ else
+ {
+ struct elf_link_hash_entry *h;
+
+ /* Treat a reloc against a defined symbol as though it were
+ actually against the section. */
+ h = ((struct elf_link_hash_entry *)
+ bfd_wrapped_link_hash_lookup (output_bfd, info,
+ link_order->u.reloc.p->u.name,
+ FALSE, FALSE, TRUE));
+ if (h != NULL
+ && (h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak))
+ {
+ asection *section;
+
+ section = h->root.u.def.section;
+ indx = section->output_section->target_index;
+ *rel_hash_ptr = NULL;
+ /* It seems that we ought to add the symbol value to the
+ addend here, but in practice it has already been added
+ because it was passed to constructor_callback. */
+ addend += section->output_section->vma + section->output_offset;
+ }
+ else if (h != NULL)
+ {
+ /* Setting the index to -2 tells elf_link_output_extsym that
+ this symbol is used by a reloc. */
+ h->indx = -2;
+ *rel_hash_ptr = h;
+ indx = 0;
+ }
+ else
+ {
+ if (! ((*info->callbacks->unattached_reloc)
+ (info, link_order->u.reloc.p->u.name, NULL, NULL, 0)))
+ return FALSE;
+ indx = 0;
+ }
+ }
+
+ /* If this is an inplace reloc, we must write the addend into the
+ object file. */
+ if (howto->partial_inplace && addend != 0)
+ {
+ bfd_size_type size;
+ bfd_reloc_status_type rstat;
+ bfd_byte *buf;
+ bfd_boolean ok;
+ const char *sym_name;
+
+ size = bfd_get_reloc_size (howto);
+ buf = bfd_zmalloc (size);
+ if (buf == NULL)
+ return FALSE;
+ rstat = _bfd_relocate_contents (howto, output_bfd, addend, buf);
+ switch (rstat)
+ {
+ case bfd_reloc_ok:
+ break;
+
+ default:
+ case bfd_reloc_outofrange:
+ abort ();
+
+ case bfd_reloc_overflow:
+ if (link_order->type == bfd_section_reloc_link_order)
+ sym_name = bfd_section_name (output_bfd,
+ link_order->u.reloc.p->u.section);
+ else
+ sym_name = link_order->u.reloc.p->u.name;
+ if (! ((*info->callbacks->reloc_overflow)
+ (info, sym_name, howto->name, addend, NULL, NULL, 0)))
+ {
+ free (buf);
+ return FALSE;
+ }
+ break;
+ }
+ ok = bfd_set_section_contents (output_bfd, output_section, buf,
+ link_order->offset, size);
+ free (buf);
+ if (! ok)
+ return FALSE;
+ }
+
+ /* The address of a reloc is relative to the section in a
+ relocatable file, and is a virtual address in an executable
+ file. */
+ offset = link_order->offset;
+ if (! info->relocatable)
+ offset += output_section->vma;
+
+ for (i = 0; i < bed->s->int_rels_per_ext_rel; i++)
+ {
+ irel[i].r_offset = offset;
+ irel[i].r_info = 0;
+ irel[i].r_addend = 0;
+ }
+ if (bed->s->arch_size == 32)
+ irel[0].r_info = ELF32_R_INFO (indx, howto->type);
+ else
+ irel[0].r_info = ELF64_R_INFO (indx, howto->type);
+
+ rel_hdr = &elf_section_data (output_section)->rel_hdr;
+ erel = rel_hdr->contents;
+ if (rel_hdr->sh_type == SHT_REL)
+ {
+ erel += (elf_section_data (output_section)->rel_count
+ * bed->s->sizeof_rel);
+ (*bed->s->swap_reloc_out) (output_bfd, irel, erel);
+ }
+ else
+ {
+ irel[0].r_addend = addend;
+ erel += (elf_section_data (output_section)->rel_count
+ * bed->s->sizeof_rela);
+ (*bed->s->swap_reloca_out) (output_bfd, irel, erel);
+ }
+
+ ++elf_section_data (output_section)->rel_count;
+
+ return TRUE;
+}
+
+/* Do the final step of an ELF link. */
+
+bfd_boolean
+bfd_elf_final_link (bfd *abfd, struct bfd_link_info *info)
+{
+ bfd_boolean dynamic;
+ bfd_boolean emit_relocs;
+ bfd *dynobj;
+ struct elf_final_link_info finfo;
+ register asection *o;
+ register struct bfd_link_order *p;
+ register bfd *sub;
+ bfd_size_type max_contents_size;
+ bfd_size_type max_external_reloc_size;
+ bfd_size_type max_internal_reloc_count;
+ bfd_size_type max_sym_count;
+ bfd_size_type max_sym_shndx_count;
+ file_ptr off;
+ Elf_Internal_Sym elfsym;
+ unsigned int i;
+ Elf_Internal_Shdr *symtab_hdr;
+ Elf_Internal_Shdr *symtab_shndx_hdr;
+ Elf_Internal_Shdr *symstrtab_hdr;
+ const struct elf_backend_data *bed = get_elf_backend_data (abfd);
+ struct elf_outext_info eoinfo;
+ bfd_boolean merged;
+ size_t relativecount = 0;
+ asection *reldyn = 0;
+ bfd_size_type amt;
+
+ if (! is_elf_hash_table (info->hash))
+ return FALSE;
+
+ if (info->shared)
+ abfd->flags |= DYNAMIC;
+
+ dynamic = elf_hash_table (info)->dynamic_sections_created;
+ dynobj = elf_hash_table (info)->dynobj;
+
+ emit_relocs = (info->relocatable
+ || info->emitrelocations
+ || bed->elf_backend_emit_relocs);
+
+ finfo.info = info;
+ finfo.output_bfd = abfd;
+ finfo.symstrtab = _bfd_elf_stringtab_init ();
+ if (finfo.symstrtab == NULL)
+ return FALSE;
+
+ if (! dynamic)
+ {
+ finfo.dynsym_sec = NULL;
+ finfo.hash_sec = NULL;
+ finfo.symver_sec = NULL;
+ }
+ else
+ {
+ finfo.dynsym_sec = bfd_get_section_by_name (dynobj, ".dynsym");
+ finfo.hash_sec = bfd_get_section_by_name (dynobj, ".hash");
+ BFD_ASSERT (finfo.dynsym_sec != NULL && finfo.hash_sec != NULL);
+ finfo.symver_sec = bfd_get_section_by_name (dynobj, ".gnu.version");
+ /* Note that it is OK if symver_sec is NULL. */
+ }
+
+ finfo.contents = NULL;
+ finfo.external_relocs = NULL;
+ finfo.internal_relocs = NULL;
+ finfo.external_syms = NULL;
+ finfo.locsym_shndx = NULL;
+ finfo.internal_syms = NULL;
+ finfo.indices = NULL;
+ finfo.sections = NULL;
+ finfo.symbuf = NULL;
+ finfo.symshndxbuf = NULL;
+ finfo.symbuf_count = 0;
+ finfo.shndxbuf_size = 0;
+
+ /* Count up the number of relocations we will output for each output
+ section, so that we know the sizes of the reloc sections. We
+ also figure out some maximum sizes. */
+ max_contents_size = 0;
+ max_external_reloc_size = 0;
+ max_internal_reloc_count = 0;
+ max_sym_count = 0;
+ max_sym_shndx_count = 0;
+ merged = FALSE;
+ for (o = abfd->sections; o != NULL; o = o->next)
+ {
+ struct bfd_elf_section_data *esdo = elf_section_data (o);
+ o->reloc_count = 0;
+
+ for (p = o->link_order_head; p != NULL; p = p->next)
+ {
+ unsigned int reloc_count = 0;
+ struct bfd_elf_section_data *esdi = NULL;
+ unsigned int *rel_count1;
+
+ if (p->type == bfd_section_reloc_link_order
+ || p->type == bfd_symbol_reloc_link_order)
+ reloc_count = 1;
+ else if (p->type == bfd_indirect_link_order)
+ {
+ asection *sec;
+
+ sec = p->u.indirect.section;
+ esdi = elf_section_data (sec);
+
+ /* Mark all sections which are to be included in the
+ link. This will normally be every section. We need
+ to do this so that we can identify any sections which
+ the linker has decided to not include. */
+ sec->linker_mark = TRUE;
+
+ if (sec->flags & SEC_MERGE)
+ merged = TRUE;
+
+ if (info->relocatable || info->emitrelocations)
+ reloc_count = sec->reloc_count;
+ else if (bed->elf_backend_count_relocs)
+ {
+ Elf_Internal_Rela * relocs;
+
+ relocs = _bfd_elf_link_read_relocs (abfd, sec, NULL, NULL,
+ info->keep_memory);
+
+ reloc_count = (*bed->elf_backend_count_relocs) (sec, relocs);
+
+ if (elf_section_data (o)->relocs != relocs)
+ free (relocs);
+ }
+
+ if (sec->_raw_size > max_contents_size)
+ max_contents_size = sec->_raw_size;
+ if (sec->_cooked_size > max_contents_size)
+ max_contents_size = sec->_cooked_size;
+
+ /* We are interested in just local symbols, not all
+ symbols. */
+ if (bfd_get_flavour (sec->owner) == bfd_target_elf_flavour
+ && (sec->owner->flags & DYNAMIC) == 0)
+ {
+ size_t sym_count;
+
+ if (elf_bad_symtab (sec->owner))
+ sym_count = (elf_tdata (sec->owner)->symtab_hdr.sh_size
+ / bed->s->sizeof_sym);
+ else
+ sym_count = elf_tdata (sec->owner)->symtab_hdr.sh_info;
+
+ if (sym_count > max_sym_count)
+ max_sym_count = sym_count;
+
+ if (sym_count > max_sym_shndx_count
+ && elf_symtab_shndx (sec->owner) != 0)
+ max_sym_shndx_count = sym_count;
+
+ if ((sec->flags & SEC_RELOC) != 0)
+ {
+ size_t ext_size;
+
+ ext_size = elf_section_data (sec)->rel_hdr.sh_size;
+ if (ext_size > max_external_reloc_size)
+ max_external_reloc_size = ext_size;
+ if (sec->reloc_count > max_internal_reloc_count)
+ max_internal_reloc_count = sec->reloc_count;
+ }
+ }
+ }
+
+ if (reloc_count == 0)
+ continue;
+
+ o->reloc_count += reloc_count;
+
+ /* MIPS may have a mix of REL and RELA relocs on sections.
+ To support this curious ABI we keep reloc counts in
+ elf_section_data too. We must be careful to add the
+ relocations from the input section to the right output
+ count. FIXME: Get rid of one count. We have
+ o->reloc_count == esdo->rel_count + esdo->rel_count2. */
+ rel_count1 = &esdo->rel_count;
+ if (esdi != NULL)
+ {
+ bfd_boolean same_size;
+ bfd_size_type entsize1;
+
+ entsize1 = esdi->rel_hdr.sh_entsize;
+ BFD_ASSERT (entsize1 == bed->s->sizeof_rel
+ || entsize1 == bed->s->sizeof_rela);
+ same_size = !o->use_rela_p == (entsize1 == bed->s->sizeof_rel);
+
+ if (!same_size)
+ rel_count1 = &esdo->rel_count2;
+
+ if (esdi->rel_hdr2 != NULL)
+ {
+ bfd_size_type entsize2 = esdi->rel_hdr2->sh_entsize;
+ unsigned int alt_count;
+ unsigned int *rel_count2;
+
+ BFD_ASSERT (entsize2 != entsize1
+ && (entsize2 == bed->s->sizeof_rel
+ || entsize2 == bed->s->sizeof_rela));
+
+ rel_count2 = &esdo->rel_count2;
+ if (!same_size)
+ rel_count2 = &esdo->rel_count;
+
+ /* The following is probably too simplistic if the
+ backend counts output relocs unusually. */
+ BFD_ASSERT (bed->elf_backend_count_relocs == NULL);
+ alt_count = NUM_SHDR_ENTRIES (esdi->rel_hdr2);
+ *rel_count2 += alt_count;
+ reloc_count -= alt_count;
+ }
+ }
+ *rel_count1 += reloc_count;
+ }
+
+ if (o->reloc_count > 0)
+ o->flags |= SEC_RELOC;
+ else
+ {
+ /* Explicitly clear the SEC_RELOC flag. The linker tends to
+ set it (this is probably a bug) and if it is set
+ assign_section_numbers will create a reloc section. */
+ o->flags &=~ SEC_RELOC;
+ }
+
+ /* If the SEC_ALLOC flag is not set, force the section VMA to
+ zero. This is done in elf_fake_sections as well, but forcing
+ the VMA to 0 here will ensure that relocs against these
+ sections are handled correctly. */
+ if ((o->flags & SEC_ALLOC) == 0
+ && ! o->user_set_vma)
+ o->vma = 0;
+ }
+
+ if (! info->relocatable && merged)
+ elf_link_hash_traverse (elf_hash_table (info),
+ _bfd_elf_link_sec_merge_syms, abfd);
+
+ /* Figure out the file positions for everything but the symbol table
+ and the relocs. We set symcount to force assign_section_numbers
+ to create a symbol table. */
+ bfd_get_symcount (abfd) = info->strip == strip_all ? 0 : 1;
+ BFD_ASSERT (! abfd->output_has_begun);
+ if (! _bfd_elf_compute_section_file_positions (abfd, info))
+ goto error_return;
+
+ /* That created the reloc sections. Set their sizes, and assign
+ them file positions, and allocate some buffers. */
+ for (o = abfd->sections; o != NULL; o = o->next)
+ {
+ if ((o->flags & SEC_RELOC) != 0)
+ {
+ if (!(_bfd_elf_link_size_reloc_section
+ (abfd, &elf_section_data (o)->rel_hdr, o)))
+ goto error_return;
+
+ if (elf_section_data (o)->rel_hdr2
+ && !(_bfd_elf_link_size_reloc_section
+ (abfd, elf_section_data (o)->rel_hdr2, o)))
+ goto error_return;
+ }
+
+ /* Now, reset REL_COUNT and REL_COUNT2 so that we can use them
+ to count upwards while actually outputting the relocations. */
+ elf_section_data (o)->rel_count = 0;
+ elf_section_data (o)->rel_count2 = 0;
+ }
+
+ _bfd_elf_assign_file_positions_for_relocs (abfd);
+
+ /* We have now assigned file positions for all the sections except
+ .symtab and .strtab. We start the .symtab section at the current
+ file position, and write directly to it. We build the .strtab
+ section in memory. */
+ bfd_get_symcount (abfd) = 0;
+ symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
+ /* sh_name is set in prep_headers. */
+ symtab_hdr->sh_type = SHT_SYMTAB;
+ /* sh_flags, sh_addr and sh_size all start off zero. */
+ symtab_hdr->sh_entsize = bed->s->sizeof_sym;
+ /* sh_link is set in assign_section_numbers. */
+ /* sh_info is set below. */
+ /* sh_offset is set just below. */
+ symtab_hdr->sh_addralign = 1 << bed->s->log_file_align;
+
+ off = elf_tdata (abfd)->next_file_pos;
+ off = _bfd_elf_assign_file_position_for_section (symtab_hdr, off, TRUE);
+
+ /* Note that at this point elf_tdata (abfd)->next_file_pos is
+ incorrect. We do not yet know the size of the .symtab section.
+ We correct next_file_pos below, after we do know the size. */
+
+ /* Allocate a buffer to hold swapped out symbols. This is to avoid
+ continuously seeking to the right position in the file. */
+ if (! info->keep_memory || max_sym_count < 20)
+ finfo.symbuf_size = 20;
+ else
+ finfo.symbuf_size = max_sym_count;
+ amt = finfo.symbuf_size;
+ amt *= bed->s->sizeof_sym;
+ finfo.symbuf = bfd_malloc (amt);
+ if (finfo.symbuf == NULL)
+ goto error_return;
+ if (elf_numsections (abfd) > SHN_LORESERVE)
+ {
+ /* Wild guess at number of output symbols. realloc'd as needed. */
+ amt = 2 * max_sym_count + elf_numsections (abfd) + 1000;
+ finfo.shndxbuf_size = amt;
+ amt *= sizeof (Elf_External_Sym_Shndx);
+ finfo.symshndxbuf = bfd_zmalloc (amt);
+ if (finfo.symshndxbuf == NULL)
+ goto error_return;
+ }
+
+ /* Start writing out the symbol table. The first symbol is always a
+ dummy symbol. */
+ if (info->strip != strip_all
+ || emit_relocs)
+ {
+ elfsym.st_value = 0;
+ elfsym.st_size = 0;
+ elfsym.st_info = 0;
+ elfsym.st_other = 0;
+ elfsym.st_shndx = SHN_UNDEF;
+ if (! elf_link_output_sym (&finfo, NULL, &elfsym, bfd_und_section_ptr,
+ NULL))
+ goto error_return;
+ }
+
+#if 0
+ /* Some standard ELF linkers do this, but we don't because it causes
+ bootstrap comparison failures. */
+ /* Output a file symbol for the output file as the second symbol.
+ We output this even if we are discarding local symbols, although
+ I'm not sure if this is correct. */
+ elfsym.st_value = 0;
+ elfsym.st_size = 0;
+ elfsym.st_info = ELF_ST_INFO (STB_LOCAL, STT_FILE);
+ elfsym.st_other = 0;
+ elfsym.st_shndx = SHN_ABS;
+ if (! elf_link_output_sym (&finfo, bfd_get_filename (abfd),
+ &elfsym, bfd_abs_section_ptr, NULL))
+ goto error_return;
#endif
- return lsect;
+ /* Output a symbol for each section. We output these even if we are
+ discarding local symbols, since they are used for relocs. These
+ symbols have no names. We store the index of each one in the
+ index field of the section, so that we can find it again when
+ outputting relocs. */
+ if (info->strip != strip_all
+ || emit_relocs)
+ {
+ elfsym.st_size = 0;
+ elfsym.st_info = ELF_ST_INFO (STB_LOCAL, STT_SECTION);
+ elfsym.st_other = 0;
+ for (i = 1; i < elf_numsections (abfd); i++)
+ {
+ o = bfd_section_from_elf_index (abfd, i);
+ if (o != NULL)
+ o->target_index = bfd_get_symcount (abfd);
+ elfsym.st_shndx = i;
+ if (info->relocatable || o == NULL)
+ elfsym.st_value = 0;
+ else
+ elfsym.st_value = o->vma;
+ if (! elf_link_output_sym (&finfo, NULL, &elfsym, o, NULL))
+ goto error_return;
+ if (i == SHN_LORESERVE - 1)
+ i += SHN_HIRESERVE + 1 - SHN_LORESERVE;
+ }
+ }
+
+ /* Allocate some memory to hold information read in from the input
+ files. */
+ if (max_contents_size != 0)
+ {
+ finfo.contents = bfd_malloc (max_contents_size);
+ if (finfo.contents == NULL)
+ goto error_return;
+ }
+
+ if (max_external_reloc_size != 0)
+ {
+ finfo.external_relocs = bfd_malloc (max_external_reloc_size);
+ if (finfo.external_relocs == NULL)
+ goto error_return;
+ }
+
+ if (max_internal_reloc_count != 0)
+ {
+ amt = max_internal_reloc_count * bed->s->int_rels_per_ext_rel;
+ amt *= sizeof (Elf_Internal_Rela);
+ finfo.internal_relocs = bfd_malloc (amt);
+ if (finfo.internal_relocs == NULL)
+ goto error_return;
+ }
+
+ if (max_sym_count != 0)
+ {
+ amt = max_sym_count * bed->s->sizeof_sym;
+ finfo.external_syms = bfd_malloc (amt);
+ if (finfo.external_syms == NULL)
+ goto error_return;
+
+ amt = max_sym_count * sizeof (Elf_Internal_Sym);
+ finfo.internal_syms = bfd_malloc (amt);
+ if (finfo.internal_syms == NULL)
+ goto error_return;
+
+ amt = max_sym_count * sizeof (long);
+ finfo.indices = bfd_malloc (amt);
+ if (finfo.indices == NULL)
+ goto error_return;
+
+ amt = max_sym_count * sizeof (asection *);
+ finfo.sections = bfd_malloc (amt);
+ if (finfo.sections == NULL)
+ goto error_return;
+ }
+
+ if (max_sym_shndx_count != 0)
+ {
+ amt = max_sym_shndx_count * sizeof (Elf_External_Sym_Shndx);
+ finfo.locsym_shndx = bfd_malloc (amt);
+ if (finfo.locsym_shndx == NULL)
+ goto error_return;
+ }
+
+ if (elf_hash_table (info)->tls_sec)
+ {
+ bfd_vma base, end = 0;
+ asection *sec;
+
+ for (sec = elf_hash_table (info)->tls_sec;
+ sec && (sec->flags & SEC_THREAD_LOCAL);
+ sec = sec->next)
+ {
+ bfd_vma size = sec->_raw_size;
+
+ if (size == 0 && (sec->flags & SEC_HAS_CONTENTS) == 0)
+ {
+ struct bfd_link_order *o;
+
+ for (o = sec->link_order_head; o != NULL; o = o->next)
+ if (size < o->offset + o->size)
+ size = o->offset + o->size;
+ }
+ end = sec->vma + size;
+ }
+ base = elf_hash_table (info)->tls_sec->vma;
+ end = align_power (end, elf_hash_table (info)->tls_sec->alignment_power);
+ elf_hash_table (info)->tls_size = end - base;
+ }
+
+ /* Since ELF permits relocations to be against local symbols, we
+ must have the local symbols available when we do the relocations.
+ Since we would rather only read the local symbols once, and we
+ would rather not keep them in memory, we handle all the
+ relocations for a single input file at the same time.
+
+ Unfortunately, there is no way to know the total number of local
+ symbols until we have seen all of them, and the local symbol
+ indices precede the global symbol indices. This means that when
+ we are generating relocatable output, and we see a reloc against
+ a global symbol, we can not know the symbol index until we have
+ finished examining all the local symbols to see which ones we are
+ going to output. To deal with this, we keep the relocations in
+ memory, and don't output them until the end of the link. This is
+ an unfortunate waste of memory, but I don't see a good way around
+ it. Fortunately, it only happens when performing a relocatable
+ link, which is not the common case. FIXME: If keep_memory is set
+ we could write the relocs out and then read them again; I don't
+ know how bad the memory loss will be. */
+
+ for (sub = info->input_bfds; sub != NULL; sub = sub->link_next)
+ sub->output_has_begun = FALSE;
+ for (o = abfd->sections; o != NULL; o = o->next)
+ {
+ for (p = o->link_order_head; p != NULL; p = p->next)
+ {
+ if (p->type == bfd_indirect_link_order
+ && (bfd_get_flavour ((sub = p->u.indirect.section->owner))
+ == bfd_target_elf_flavour)
+ && elf_elfheader (sub)->e_ident[EI_CLASS] == bed->s->elfclass)
+ {
+ if (! sub->output_has_begun)
+ {
+ if (! elf_link_input_bfd (&finfo, sub))
+ goto error_return;
+ sub->output_has_begun = TRUE;
+ }
+ }
+ else if (p->type == bfd_section_reloc_link_order
+ || p->type == bfd_symbol_reloc_link_order)
+ {
+ if (! elf_reloc_link_order (abfd, info, o, p))
+ goto error_return;
+ }
+ else
+ {
+ if (! _bfd_default_link_order (abfd, info, o, p))
+ goto error_return;
+ }
+ }
+ }
+
+ /* Output any global symbols that got converted to local in a
+ version script or due to symbol visibility. We do this in a
+ separate step since ELF requires all local symbols to appear
+ prior to any global symbols. FIXME: We should only do this if
+ some global symbols were, in fact, converted to become local.
+ FIXME: Will this work correctly with the Irix 5 linker? */
+ eoinfo.failed = FALSE;
+ eoinfo.finfo = &finfo;
+ eoinfo.localsyms = TRUE;
+ elf_link_hash_traverse (elf_hash_table (info), elf_link_output_extsym,
+ &eoinfo);
+ if (eoinfo.failed)
+ return FALSE;
+
+ /* That wrote out all the local symbols. Finish up the symbol table
+ with the global symbols. Even if we want to strip everything we
+ can, we still need to deal with those global symbols that got
+ converted to local in a version script. */
+
+ /* The sh_info field records the index of the first non local symbol. */
+ symtab_hdr->sh_info = bfd_get_symcount (abfd);
+
+ if (dynamic
+ && finfo.dynsym_sec->output_section != bfd_abs_section_ptr)
+ {
+ Elf_Internal_Sym sym;
+ bfd_byte *dynsym = finfo.dynsym_sec->contents;
+ long last_local = 0;
+
+ /* Write out the section symbols for the output sections. */
+ if (info->shared)
+ {
+ asection *s;
+
+ sym.st_size = 0;
+ sym.st_name = 0;
+ sym.st_info = ELF_ST_INFO (STB_LOCAL, STT_SECTION);
+ sym.st_other = 0;
+
+ for (s = abfd->sections; s != NULL; s = s->next)
+ {
+ int indx;
+ bfd_byte *dest;
+ long dynindx;
+
+ indx = elf_section_data (s)->this_idx;
+ dynindx = elf_section_data (s)->dynindx;
+ BFD_ASSERT (indx > 0);
+ sym.st_shndx = indx;
+ sym.st_value = s->vma;
+ dest = dynsym + dynindx * bed->s->sizeof_sym;
+ bed->s->swap_symbol_out (abfd, &sym, dest, 0);
+ }
+
+ last_local = bfd_count_sections (abfd);
+ }
+
+ /* Write out the local dynsyms. */
+ if (elf_hash_table (info)->dynlocal)
+ {
+ struct elf_link_local_dynamic_entry *e;
+ for (e = elf_hash_table (info)->dynlocal; e ; e = e->next)
+ {
+ asection *s;
+ bfd_byte *dest;
+
+ sym.st_size = e->isym.st_size;
+ sym.st_other = e->isym.st_other;
+
+ /* Copy the internal symbol as is.
+ Note that we saved a word of storage and overwrote
+ the original st_name with the dynstr_index. */
+ sym = e->isym;
+
+ if (e->isym.st_shndx != SHN_UNDEF
+ && (e->isym.st_shndx < SHN_LORESERVE
+ || e->isym.st_shndx > SHN_HIRESERVE))
+ {
+ s = bfd_section_from_elf_index (e->input_bfd,
+ e->isym.st_shndx);
+
+ sym.st_shndx =
+ elf_section_data (s->output_section)->this_idx;
+ sym.st_value = (s->output_section->vma
+ + s->output_offset
+ + e->isym.st_value);
+ }
+
+ if (last_local < e->dynindx)
+ last_local = e->dynindx;
+
+ dest = dynsym + e->dynindx * bed->s->sizeof_sym;
+ bed->s->swap_symbol_out (abfd, &sym, dest, 0);
+ }
+ }
+
+ elf_section_data (finfo.dynsym_sec->output_section)->this_hdr.sh_info =
+ last_local + 1;
+ }
+
+ /* We get the global symbols from the hash table. */
+ eoinfo.failed = FALSE;
+ eoinfo.localsyms = FALSE;
+ eoinfo.finfo = &finfo;
+ elf_link_hash_traverse (elf_hash_table (info), elf_link_output_extsym,
+ &eoinfo);
+ if (eoinfo.failed)
+ return FALSE;
+
+ /* If backend needs to output some symbols not present in the hash
+ table, do it now. */
+ if (bed->elf_backend_output_arch_syms)
+ {
+ typedef bfd_boolean (*out_sym_func)
+ (void *, const char *, Elf_Internal_Sym *, asection *,
+ struct elf_link_hash_entry *);
+
+ if (! ((*bed->elf_backend_output_arch_syms)
+ (abfd, info, &finfo, (out_sym_func) elf_link_output_sym)))
+ return FALSE;
+ }
+
+ /* Flush all symbols to the file. */
+ if (! elf_link_flush_output_syms (&finfo, bed))
+ return FALSE;
+
+ /* Now we know the size of the symtab section. */
+ off += symtab_hdr->sh_size;
+
+ symtab_shndx_hdr = &elf_tdata (abfd)->symtab_shndx_hdr;
+ if (symtab_shndx_hdr->sh_name != 0)
+ {
+ symtab_shndx_hdr->sh_type = SHT_SYMTAB_SHNDX;
+ symtab_shndx_hdr->sh_entsize = sizeof (Elf_External_Sym_Shndx);
+ symtab_shndx_hdr->sh_addralign = sizeof (Elf_External_Sym_Shndx);
+ amt = bfd_get_symcount (abfd) * sizeof (Elf_External_Sym_Shndx);
+ symtab_shndx_hdr->sh_size = amt;
+
+ off = _bfd_elf_assign_file_position_for_section (symtab_shndx_hdr,
+ off, TRUE);
+
+ if (bfd_seek (abfd, symtab_shndx_hdr->sh_offset, SEEK_SET) != 0
+ || (bfd_bwrite (finfo.symshndxbuf, amt, abfd) != amt))
+ return FALSE;
+ }
+
+
+ /* Finish up and write out the symbol string table (.strtab)
+ section. */
+ symstrtab_hdr = &elf_tdata (abfd)->strtab_hdr;
+ /* sh_name was set in prep_headers. */
+ symstrtab_hdr->sh_type = SHT_STRTAB;
+ symstrtab_hdr->sh_flags = 0;
+ symstrtab_hdr->sh_addr = 0;
+ symstrtab_hdr->sh_size = _bfd_stringtab_size (finfo.symstrtab);
+ symstrtab_hdr->sh_entsize = 0;
+ symstrtab_hdr->sh_link = 0;
+ symstrtab_hdr->sh_info = 0;
+ /* sh_offset is set just below. */
+ symstrtab_hdr->sh_addralign = 1;
+
+ off = _bfd_elf_assign_file_position_for_section (symstrtab_hdr, off, TRUE);
+ elf_tdata (abfd)->next_file_pos = off;
+
+ if (bfd_get_symcount (abfd) > 0)
+ {
+ if (bfd_seek (abfd, symstrtab_hdr->sh_offset, SEEK_SET) != 0
+ || ! _bfd_stringtab_emit (abfd, finfo.symstrtab))
+ return FALSE;
+ }
+
+ /* Adjust the relocs to have the correct symbol indices. */
+ for (o = abfd->sections; o != NULL; o = o->next)
+ {
+ if ((o->flags & SEC_RELOC) == 0)
+ continue;
+
+ elf_link_adjust_relocs (abfd, &elf_section_data (o)->rel_hdr,
+ elf_section_data (o)->rel_count,
+ elf_section_data (o)->rel_hashes);
+ if (elf_section_data (o)->rel_hdr2 != NULL)
+ elf_link_adjust_relocs (abfd, elf_section_data (o)->rel_hdr2,
+ elf_section_data (o)->rel_count2,
+ (elf_section_data (o)->rel_hashes
+ + elf_section_data (o)->rel_count));
+
+ /* Set the reloc_count field to 0 to prevent write_relocs from
+ trying to swap the relocs out itself. */
+ o->reloc_count = 0;
+ }
+
+ if (dynamic && info->combreloc && dynobj != NULL)
+ relativecount = elf_link_sort_relocs (abfd, info, &reldyn);
+
+ /* If we are linking against a dynamic object, or generating a
+ shared library, finish up the dynamic linking information. */
+ if (dynamic)
+ {
+ bfd_byte *dyncon, *dynconend;
+
+ /* Fix up .dynamic entries. */
+ o = bfd_get_section_by_name (dynobj, ".dynamic");
+ BFD_ASSERT (o != NULL);
+
+ dyncon = o->contents;
+ dynconend = o->contents + o->_raw_size;
+ for (; dyncon < dynconend; dyncon += bed->s->sizeof_dyn)
+ {
+ Elf_Internal_Dyn dyn;
+ const char *name;
+ unsigned int type;
+
+ bed->s->swap_dyn_in (dynobj, dyncon, &dyn);
+
+ switch (dyn.d_tag)
+ {
+ default:
+ continue;
+ case DT_NULL:
+ if (relativecount > 0 && dyncon + bed->s->sizeof_dyn < dynconend)
+ {
+ switch (elf_section_data (reldyn)->this_hdr.sh_type)
+ {
+ case SHT_REL: dyn.d_tag = DT_RELCOUNT; break;
+ case SHT_RELA: dyn.d_tag = DT_RELACOUNT; break;
+ default: continue;
+ }
+ dyn.d_un.d_val = relativecount;
+ relativecount = 0;
+ break;
+ }
+ continue;
+
+ case DT_INIT:
+ name = info->init_function;
+ goto get_sym;
+ case DT_FINI:
+ name = info->fini_function;
+ get_sym:
+ {
+ struct elf_link_hash_entry *h;
+
+ h = elf_link_hash_lookup (elf_hash_table (info), name,
+ FALSE, FALSE, TRUE);
+ if (h != NULL
+ && (h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak))
+ {
+ dyn.d_un.d_val = h->root.u.def.value;
+ o = h->root.u.def.section;
+ if (o->output_section != NULL)
+ dyn.d_un.d_val += (o->output_section->vma
+ + o->output_offset);
+ else
+ {
+ /* The symbol is imported from another shared
+ library and does not apply to this one. */
+ dyn.d_un.d_val = 0;
+ }
+ break;
+ }
+ }
+ continue;
+
+ case DT_PREINIT_ARRAYSZ:
+ name = ".preinit_array";
+ goto get_size;
+ case DT_INIT_ARRAYSZ:
+ name = ".init_array";
+ goto get_size;
+ case DT_FINI_ARRAYSZ:
+ name = ".fini_array";
+ get_size:
+ o = bfd_get_section_by_name (abfd, name);
+ if (o == NULL)
+ {
+ (*_bfd_error_handler)
+ (_("%s: could not find output section %s"),
+ bfd_get_filename (abfd), name);
+ goto error_return;
+ }
+ if (o->_raw_size == 0)
+ (*_bfd_error_handler)
+ (_("warning: %s section has zero size"), name);
+ dyn.d_un.d_val = o->_raw_size;
+ break;
+
+ case DT_PREINIT_ARRAY:
+ name = ".preinit_array";
+ goto get_vma;
+ case DT_INIT_ARRAY:
+ name = ".init_array";
+ goto get_vma;
+ case DT_FINI_ARRAY:
+ name = ".fini_array";
+ goto get_vma;
+
+ case DT_HASH:
+ name = ".hash";
+ goto get_vma;
+ case DT_STRTAB:
+ name = ".dynstr";
+ goto get_vma;
+ case DT_SYMTAB:
+ name = ".dynsym";
+ goto get_vma;
+ case DT_VERDEF:
+ name = ".gnu.version_d";
+ goto get_vma;
+ case DT_VERNEED:
+ name = ".gnu.version_r";
+ goto get_vma;
+ case DT_VERSYM:
+ name = ".gnu.version";
+ get_vma:
+ o = bfd_get_section_by_name (abfd, name);
+ if (o == NULL)
+ {
+ (*_bfd_error_handler)
+ (_("%s: could not find output section %s"),
+ bfd_get_filename (abfd), name);
+ goto error_return;
+ }
+ dyn.d_un.d_ptr = o->vma;
+ break;
+
+ case DT_REL:
+ case DT_RELA:
+ case DT_RELSZ:
+ case DT_RELASZ:
+ if (dyn.d_tag == DT_REL || dyn.d_tag == DT_RELSZ)
+ type = SHT_REL;
+ else
+ type = SHT_RELA;
+ dyn.d_un.d_val = 0;
+ for (i = 1; i < elf_numsections (abfd); i++)
+ {
+ Elf_Internal_Shdr *hdr;
+
+ hdr = elf_elfsections (abfd)[i];
+ if (hdr->sh_type == type
+ && (hdr->sh_flags & SHF_ALLOC) != 0)
+ {
+ if (dyn.d_tag == DT_RELSZ || dyn.d_tag == DT_RELASZ)
+ dyn.d_un.d_val += hdr->sh_size;
+ else
+ {
+ if (dyn.d_un.d_val == 0
+ || hdr->sh_addr < dyn.d_un.d_val)
+ dyn.d_un.d_val = hdr->sh_addr;
+ }
+ }
+ }
+ break;
+ }
+ bed->s->swap_dyn_out (dynobj, &dyn, dyncon);
+ }
+ }
+
+ /* If we have created any dynamic sections, then output them. */
+ if (dynobj != NULL)
+ {
+ if (! (*bed->elf_backend_finish_dynamic_sections) (abfd, info))
+ goto error_return;
+
+ for (o = dynobj->sections; o != NULL; o = o->next)
+ {
+ if ((o->flags & SEC_HAS_CONTENTS) == 0
+ || o->_raw_size == 0
+ || o->output_section == bfd_abs_section_ptr)
+ continue;
+ if ((o->flags & SEC_LINKER_CREATED) == 0)
+ {
+ /* At this point, we are only interested in sections
+ created by _bfd_elf_link_create_dynamic_sections. */
+ continue;
+ }
+ if ((elf_section_data (o->output_section)->this_hdr.sh_type
+ != SHT_STRTAB)
+ || strcmp (bfd_get_section_name (abfd, o), ".dynstr") != 0)
+ {
+ if (! bfd_set_section_contents (abfd, o->output_section,
+ o->contents,
+ (file_ptr) o->output_offset,
+ o->_raw_size))
+ goto error_return;
+ }
+ else
+ {
+ /* The contents of the .dynstr section are actually in a
+ stringtab. */
+ off = elf_section_data (o->output_section)->this_hdr.sh_offset;
+ if (bfd_seek (abfd, off, SEEK_SET) != 0
+ || ! _bfd_elf_strtab_emit (abfd,
+ elf_hash_table (info)->dynstr))
+ goto error_return;
+ }
+ }
+ }
+
+ if (info->relocatable)
+ {
+ bfd_boolean failed = FALSE;
+
+ bfd_map_over_sections (abfd, bfd_elf_set_group_contents, &failed);
+ if (failed)
+ goto error_return;
+ }
+
+ /* If we have optimized stabs strings, output them. */
+ if (elf_hash_table (info)->stab_info != NULL)
+ {
+ if (! _bfd_write_stab_strings (abfd, &elf_hash_table (info)->stab_info))
+ goto error_return;
+ }
+
+ if (info->eh_frame_hdr)
+ {
+ if (! _bfd_elf_write_section_eh_frame_hdr (abfd, info))
+ goto error_return;
+ }
+
+ if (finfo.symstrtab != NULL)
+ _bfd_stringtab_free (finfo.symstrtab);
+ if (finfo.contents != NULL)
+ free (finfo.contents);
+ if (finfo.external_relocs != NULL)
+ free (finfo.external_relocs);
+ if (finfo.internal_relocs != NULL)
+ free (finfo.internal_relocs);
+ if (finfo.external_syms != NULL)
+ free (finfo.external_syms);
+ if (finfo.locsym_shndx != NULL)
+ free (finfo.locsym_shndx);
+ if (finfo.internal_syms != NULL)
+ free (finfo.internal_syms);
+ if (finfo.indices != NULL)
+ free (finfo.indices);
+ if (finfo.sections != NULL)
+ free (finfo.sections);
+ if (finfo.symbuf != NULL)
+ free (finfo.symbuf);
+ if (finfo.symshndxbuf != NULL)
+ free (finfo.symshndxbuf);
+ for (o = abfd->sections; o != NULL; o = o->next)
+ {
+ if ((o->flags & SEC_RELOC) != 0
+ && elf_section_data (o)->rel_hashes != NULL)
+ free (elf_section_data (o)->rel_hashes);
+ }
+
+ elf_tdata (abfd)->linker = TRUE;
+
+ return TRUE;
+
+ error_return:
+ if (finfo.symstrtab != NULL)
+ _bfd_stringtab_free (finfo.symstrtab);
+ if (finfo.contents != NULL)
+ free (finfo.contents);
+ if (finfo.external_relocs != NULL)
+ free (finfo.external_relocs);
+ if (finfo.internal_relocs != NULL)
+ free (finfo.internal_relocs);
+ if (finfo.external_syms != NULL)
+ free (finfo.external_syms);
+ if (finfo.locsym_shndx != NULL)
+ free (finfo.locsym_shndx);
+ if (finfo.internal_syms != NULL)
+ free (finfo.internal_syms);
+ if (finfo.indices != NULL)
+ free (finfo.indices);
+ if (finfo.sections != NULL)
+ free (finfo.sections);
+ if (finfo.symbuf != NULL)
+ free (finfo.symbuf);
+ if (finfo.symshndxbuf != NULL)
+ free (finfo.symshndxbuf);
+ for (o = abfd->sections; o != NULL; o = o->next)
+ {
+ if ((o->flags & SEC_RELOC) != 0
+ && elf_section_data (o)->rel_hashes != NULL)
+ free (elf_section_data (o)->rel_hashes);
+ }
+
+ return FALSE;
}
-/* Find a linker generated pointer with a given addend and type. */
+/* Garbage collect unused sections. */
-elf_linker_section_pointers_t *
-_bfd_elf_find_pointer_linker_section (linker_pointers, addend, which)
- elf_linker_section_pointers_t *linker_pointers;
- bfd_vma addend;
- elf_linker_section_enum_t which;
+/* The mark phase of garbage collection. For a given section, mark
+ it and any sections in this section's group, and all the sections
+ which define symbols to which it refers. */
+
+typedef asection * (*gc_mark_hook_fn)
+ (asection *, struct bfd_link_info *, Elf_Internal_Rela *,
+ struct elf_link_hash_entry *, Elf_Internal_Sym *);
+
+static bfd_boolean
+elf_gc_mark (struct bfd_link_info *info,
+ asection *sec,
+ gc_mark_hook_fn gc_mark_hook)
{
- for ( ; linker_pointers != NULL; linker_pointers = linker_pointers->next)
+ bfd_boolean ret;
+ asection *group_sec;
+
+ sec->gc_mark = 1;
+
+ /* Mark all the sections in the group. */
+ group_sec = elf_section_data (sec)->next_in_group;
+ if (group_sec && !group_sec->gc_mark)
+ if (!elf_gc_mark (info, group_sec, gc_mark_hook))
+ return FALSE;
+
+ /* Look through the section relocs. */
+ ret = TRUE;
+ if ((sec->flags & SEC_RELOC) != 0 && sec->reloc_count > 0)
{
- if (which == linker_pointers->which && addend == linker_pointers->addend)
- return linker_pointers;
+ Elf_Internal_Rela *relstart, *rel, *relend;
+ Elf_Internal_Shdr *symtab_hdr;
+ struct elf_link_hash_entry **sym_hashes;
+ size_t nlocsyms;
+ size_t extsymoff;
+ bfd *input_bfd = sec->owner;
+ const struct elf_backend_data *bed = get_elf_backend_data (input_bfd);
+ Elf_Internal_Sym *isym = NULL;
+ int r_sym_shift;
+
+ symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
+ sym_hashes = elf_sym_hashes (input_bfd);
+
+ /* Read the local symbols. */
+ if (elf_bad_symtab (input_bfd))
+ {
+ nlocsyms = symtab_hdr->sh_size / bed->s->sizeof_sym;
+ extsymoff = 0;
+ }
+ else
+ extsymoff = nlocsyms = symtab_hdr->sh_info;
+
+ isym = (Elf_Internal_Sym *) symtab_hdr->contents;
+ if (isym == NULL && nlocsyms != 0)
+ {
+ isym = bfd_elf_get_elf_syms (input_bfd, symtab_hdr, nlocsyms, 0,
+ NULL, NULL, NULL);
+ if (isym == NULL)
+ return FALSE;
+ }
+
+ /* Read the relocations. */
+ relstart = _bfd_elf_link_read_relocs (input_bfd, sec, NULL, NULL,
+ info->keep_memory);
+ if (relstart == NULL)
+ {
+ ret = FALSE;
+ goto out1;
+ }
+ relend = relstart + sec->reloc_count * bed->s->int_rels_per_ext_rel;
+
+ if (bed->s->arch_size == 32)
+ r_sym_shift = 8;
+ else
+ r_sym_shift = 32;
+
+ for (rel = relstart; rel < relend; rel++)
+ {
+ unsigned long r_symndx;
+ asection *rsec;
+ struct elf_link_hash_entry *h;
+
+ r_symndx = rel->r_info >> r_sym_shift;
+ if (r_symndx == 0)
+ continue;
+
+ if (r_symndx >= nlocsyms
+ || ELF_ST_BIND (isym[r_symndx].st_info) != STB_LOCAL)
+ {
+ h = sym_hashes[r_symndx - extsymoff];
+ rsec = (*gc_mark_hook) (sec, info, rel, h, NULL);
+ }
+ else
+ {
+ rsec = (*gc_mark_hook) (sec, info, rel, NULL, &isym[r_symndx]);
+ }
+
+ if (rsec && !rsec->gc_mark)
+ {
+ if (bfd_get_flavour (rsec->owner) != bfd_target_elf_flavour)
+ rsec->gc_mark = 1;
+ else if (!elf_gc_mark (info, rsec, gc_mark_hook))
+ {
+ ret = FALSE;
+ goto out2;
+ }
+ }
+ }
+
+ out2:
+ if (elf_section_data (sec)->relocs != relstart)
+ free (relstart);
+ out1:
+ if (isym != NULL && symtab_hdr->contents != (unsigned char *) isym)
+ {
+ if (! info->keep_memory)
+ free (isym);
+ else
+ symtab_hdr->contents = (unsigned char *) isym;
+ }
}
- return (elf_linker_section_pointers_t *)0;
+ return ret;
+}
+
+/* Sweep symbols in swept sections. Called via elf_link_hash_traverse. */
+
+static bfd_boolean
+elf_gc_sweep_symbol (struct elf_link_hash_entry *h, void *idxptr)
+{
+ int *idx = idxptr;
+
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ if (h->dynindx != -1
+ && ((h->root.type != bfd_link_hash_defined
+ && h->root.type != bfd_link_hash_defweak)
+ || h->root.u.def.section->gc_mark))
+ h->dynindx = (*idx)++;
+
+ return TRUE;
+}
+
+/* The sweep phase of garbage collection. Remove all garbage sections. */
+
+typedef bfd_boolean (*gc_sweep_hook_fn)
+ (bfd *, struct bfd_link_info *, asection *, const Elf_Internal_Rela *);
+
+static bfd_boolean
+elf_gc_sweep (struct bfd_link_info *info, gc_sweep_hook_fn gc_sweep_hook)
+{
+ bfd *sub;
+
+ for (sub = info->input_bfds; sub != NULL; sub = sub->link_next)
+ {
+ asection *o;
+
+ if (bfd_get_flavour (sub) != bfd_target_elf_flavour)
+ continue;
+
+ for (o = sub->sections; o != NULL; o = o->next)
+ {
+ /* Keep special sections. Keep .debug sections. */
+ if ((o->flags & SEC_LINKER_CREATED)
+ || (o->flags & SEC_DEBUGGING))
+ o->gc_mark = 1;
+
+ if (o->gc_mark)
+ continue;
+
+ /* Skip sweeping sections already excluded. */
+ if (o->flags & SEC_EXCLUDE)
+ continue;
+
+ /* Since this is early in the link process, it is simple
+ to remove a section from the output. */
+ o->flags |= SEC_EXCLUDE;
+
+ /* But we also have to update some of the relocation
+ info we collected before. */
+ if (gc_sweep_hook
+ && (o->flags & SEC_RELOC) && o->reloc_count > 0)
+ {
+ Elf_Internal_Rela *internal_relocs;
+ bfd_boolean r;
+
+ internal_relocs
+ = _bfd_elf_link_read_relocs (o->owner, o, NULL, NULL,
+ info->keep_memory);
+ if (internal_relocs == NULL)
+ return FALSE;
+
+ r = (*gc_sweep_hook) (o->owner, info, o, internal_relocs);
+
+ if (elf_section_data (o)->relocs != internal_relocs)
+ free (internal_relocs);
+
+ if (!r)
+ return FALSE;
+ }
+ }
+ }
+
+ /* Remove the symbols that were in the swept sections from the dynamic
+ symbol table. GCFIXME: Anyone know how to get them out of the
+ static symbol table as well? */
+ {
+ int i = 0;
+
+ elf_link_hash_traverse (elf_hash_table (info), elf_gc_sweep_symbol, &i);
+
+ elf_hash_table (info)->dynsymcount = i;
+ }
+
+ return TRUE;
+}
+
+/* Propagate collected vtable information. This is called through
+ elf_link_hash_traverse. */
+
+static bfd_boolean
+elf_gc_propagate_vtable_entries_used (struct elf_link_hash_entry *h, void *okp)
+{
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ /* Those that are not vtables. */
+ if (h->vtable_parent == NULL)
+ return TRUE;
+
+ /* Those vtables that do not have parents, we cannot merge. */
+ if (h->vtable_parent == (struct elf_link_hash_entry *) -1)
+ return TRUE;
+
+ /* If we've already been done, exit. */
+ if (h->vtable_entries_used && h->vtable_entries_used[-1])
+ return TRUE;
+
+ /* Make sure the parent's table is up to date. */
+ elf_gc_propagate_vtable_entries_used (h->vtable_parent, okp);
+
+ if (h->vtable_entries_used == NULL)
+ {
+ /* None of this table's entries were referenced. Re-use the
+ parent's table. */
+ h->vtable_entries_used = h->vtable_parent->vtable_entries_used;
+ h->vtable_entries_size = h->vtable_parent->vtable_entries_size;
+ }
+ else
+ {
+ size_t n;
+ bfd_boolean *cu, *pu;
+
+ /* Or the parent's entries into ours. */
+ cu = h->vtable_entries_used;
+ cu[-1] = TRUE;
+ pu = h->vtable_parent->vtable_entries_used;
+ if (pu != NULL)
+ {
+ const struct elf_backend_data *bed;
+ unsigned int log_file_align;
+
+ bed = get_elf_backend_data (h->root.u.def.section->owner);
+ log_file_align = bed->s->log_file_align;
+ n = h->vtable_parent->vtable_entries_size >> log_file_align;
+ while (n--)
+ {
+ if (*pu)
+ *cu = TRUE;
+ pu++;
+ cu++;
+ }
+ }
+ }
+
+ return TRUE;
+}
+
+static bfd_boolean
+elf_gc_smash_unused_vtentry_relocs (struct elf_link_hash_entry *h, void *okp)
+{
+ asection *sec;
+ bfd_vma hstart, hend;
+ Elf_Internal_Rela *relstart, *relend, *rel;
+ const struct elf_backend_data *bed;
+ unsigned int log_file_align;
+
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ /* Take care of both those symbols that do not describe vtables as
+ well as those that are not loaded. */
+ if (h->vtable_parent == NULL)
+ return TRUE;
+
+ BFD_ASSERT (h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak);
+
+ sec = h->root.u.def.section;
+ hstart = h->root.u.def.value;
+ hend = hstart + h->size;
+
+ relstart = _bfd_elf_link_read_relocs (sec->owner, sec, NULL, NULL, TRUE);
+ if (!relstart)
+ return *(bfd_boolean *) okp = FALSE;
+ bed = get_elf_backend_data (sec->owner);
+ log_file_align = bed->s->log_file_align;
+
+ relend = relstart + sec->reloc_count * bed->s->int_rels_per_ext_rel;
+
+ for (rel = relstart; rel < relend; ++rel)
+ if (rel->r_offset >= hstart && rel->r_offset < hend)
+ {
+ /* If the entry is in use, do nothing. */
+ if (h->vtable_entries_used
+ && (rel->r_offset - hstart) < h->vtable_entries_size)
+ {
+ bfd_vma entry = (rel->r_offset - hstart) >> log_file_align;
+ if (h->vtable_entries_used[entry])
+ continue;
+ }
+ /* Otherwise, kill it. */
+ rel->r_offset = rel->r_info = rel->r_addend = 0;
+ }
+
+ return TRUE;
+}
+
+/* Do mark and sweep of unused sections. */
+
+bfd_boolean
+bfd_elf_gc_sections (bfd *abfd, struct bfd_link_info *info)
+{
+ bfd_boolean ok = TRUE;
+ bfd *sub;
+ asection * (*gc_mark_hook)
+ (asection *, struct bfd_link_info *, Elf_Internal_Rela *,
+ struct elf_link_hash_entry *h, Elf_Internal_Sym *);
+
+ if (!get_elf_backend_data (abfd)->can_gc_sections
+ || info->relocatable
+ || info->emitrelocations
+ || !is_elf_hash_table (info->hash)
+ || elf_hash_table (info)->dynamic_sections_created)
+ {
+ (*_bfd_error_handler)(_("Warning: gc-sections option ignored"));
+ return TRUE;
+ }
+
+ /* Apply transitive closure to the vtable entry usage info. */
+ elf_link_hash_traverse (elf_hash_table (info),
+ elf_gc_propagate_vtable_entries_used,
+ &ok);
+ if (!ok)
+ return FALSE;
+
+ /* Kill the vtable relocations that were not used. */
+ elf_link_hash_traverse (elf_hash_table (info),
+ elf_gc_smash_unused_vtentry_relocs,
+ &ok);
+ if (!ok)
+ return FALSE;
+
+ /* Grovel through relocs to find out who stays ... */
+
+ gc_mark_hook = get_elf_backend_data (abfd)->gc_mark_hook;
+ for (sub = info->input_bfds; sub != NULL; sub = sub->link_next)
+ {
+ asection *o;
+
+ if (bfd_get_flavour (sub) != bfd_target_elf_flavour)
+ continue;
+
+ for (o = sub->sections; o != NULL; o = o->next)
+ {
+ if (o->flags & SEC_KEEP)
+ if (!elf_gc_mark (info, o, gc_mark_hook))
+ return FALSE;
+ }
+ }
+
+ /* ... and mark SEC_EXCLUDE for those that go. */
+ if (!elf_gc_sweep (info, get_elf_backend_data (abfd)->gc_sweep_hook))
+ return FALSE;
+
+ return TRUE;
}
-/* Make the .rela section corresponding to the generated linker section. */
-
-boolean
-_bfd_elf_make_linker_section_rela (dynobj, lsect, alignment)
- bfd *dynobj;
- elf_linker_section_t *lsect;
- int alignment;
-{
- if (lsect->rel_section)
- return true;
-
- lsect->rel_section = bfd_get_section_by_name (dynobj, lsect->rel_name);
- if (lsect->rel_section == NULL)
- {
- lsect->rel_section = bfd_make_section (dynobj, lsect->rel_name);
- if (lsect->rel_section == NULL
- || ! bfd_set_section_flags (dynobj,
- lsect->rel_section,
- (SEC_ALLOC
- | SEC_LOAD
- | SEC_HAS_CONTENTS
- | SEC_IN_MEMORY
- | SEC_LINKER_CREATED
- | SEC_READONLY))
- || ! bfd_set_section_alignment (dynobj, lsect->rel_section, alignment))
- return false;
- }
-
- return true;
+/* Called from check_relocs to record the existence of a VTINHERIT reloc. */
+
+bfd_boolean
+bfd_elf_gc_record_vtinherit (bfd *abfd,
+ asection *sec,
+ struct elf_link_hash_entry *h,
+ bfd_vma offset)
+{
+ struct elf_link_hash_entry **sym_hashes, **sym_hashes_end;
+ struct elf_link_hash_entry **search, *child;
+ bfd_size_type extsymcount;
+ const struct elf_backend_data *bed = get_elf_backend_data (abfd);
+
+ /* The sh_info field of the symtab header tells us where the
+ external symbols start. We don't care about the local symbols at
+ this point. */
+ extsymcount = elf_tdata (abfd)->symtab_hdr.sh_size / bed->s->sizeof_sym;
+ if (!elf_bad_symtab (abfd))
+ extsymcount -= elf_tdata (abfd)->symtab_hdr.sh_info;
+
+ sym_hashes = elf_sym_hashes (abfd);
+ sym_hashes_end = sym_hashes + extsymcount;
+
+ /* Hunt down the child symbol, which is in this section at the same
+ offset as the relocation. */
+ for (search = sym_hashes; search != sym_hashes_end; ++search)
+ {
+ if ((child = *search) != NULL
+ && (child->root.type == bfd_link_hash_defined
+ || child->root.type == bfd_link_hash_defweak)
+ && child->root.u.def.section == sec
+ && child->root.u.def.value == offset)
+ goto win;
+ }
+
+ (*_bfd_error_handler) ("%s: %s+%lu: No symbol found for INHERIT",
+ bfd_archive_filename (abfd), sec->name,
+ (unsigned long) offset);
+ bfd_set_error (bfd_error_invalid_operation);
+ return FALSE;
+
+ win:
+ if (!h)
+ {
+ /* This *should* only be the absolute section. It could potentially
+ be that someone has defined a non-global vtable though, which
+ would be bad. It isn't worth paging in the local symbols to be
+ sure though; that case should simply be handled by the assembler. */
+
+ child->vtable_parent = (struct elf_link_hash_entry *) -1;
+ }
+ else
+ child->vtable_parent = h;
+
+ return TRUE;
+}
+
+/* Called from check_relocs to record the existence of a VTENTRY reloc. */
+
+bfd_boolean
+bfd_elf_gc_record_vtentry (bfd *abfd ATTRIBUTE_UNUSED,
+ asection *sec ATTRIBUTE_UNUSED,
+ struct elf_link_hash_entry *h,
+ bfd_vma addend)
+{
+ const struct elf_backend_data *bed = get_elf_backend_data (abfd);
+ unsigned int log_file_align = bed->s->log_file_align;
+
+ if (addend >= h->vtable_entries_size)
+ {
+ size_t size, bytes, file_align;
+ bfd_boolean *ptr = h->vtable_entries_used;
+
+ /* While the symbol is undefined, we have to be prepared to handle
+ a zero size. */
+ file_align = 1 << log_file_align;
+ if (h->root.type == bfd_link_hash_undefined)
+ size = addend + file_align;
+ else
+ {
+ size = h->size;
+ if (addend >= size)
+ {
+ /* Oops! We've got a reference past the defined end of
+ the table. This is probably a bug -- shall we warn? */
+ size = addend + file_align;
+ }
+ }
+ size = (size + file_align - 1) & -file_align;
+
+ /* Allocate one extra entry for use as a "done" flag for the
+ consolidation pass. */
+ bytes = ((size >> log_file_align) + 1) * sizeof (bfd_boolean);
+
+ if (ptr)
+ {
+ ptr = bfd_realloc (ptr - 1, bytes);
+
+ if (ptr != NULL)
+ {
+ size_t oldbytes;
+
+ oldbytes = (((h->vtable_entries_size >> log_file_align) + 1)
+ * sizeof (bfd_boolean));
+ memset (((char *) ptr) + oldbytes, 0, bytes - oldbytes);
+ }
+ }
+ else
+ ptr = bfd_zmalloc (bytes);
+
+ if (ptr == NULL)
+ return FALSE;
+
+ /* And arrange for that done flag to be at index -1. */
+ h->vtable_entries_used = ptr + 1;
+ h->vtable_entries_size = size;
+ }
+
+ h->vtable_entries_used[addend >> log_file_align] = TRUE;
+
+ return TRUE;
+}
+
+struct alloc_got_off_arg {
+ bfd_vma gotoff;
+ unsigned int got_elt_size;
+};
+
+/* We need a special top-level link routine to convert got reference counts
+ to real got offsets. */
+
+static bfd_boolean
+elf_gc_allocate_got_offsets (struct elf_link_hash_entry *h, void *arg)
+{
+ struct alloc_got_off_arg *gofarg = arg;
+
+ if (h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ if (h->got.refcount > 0)
+ {
+ h->got.offset = gofarg->gotoff;
+ gofarg->gotoff += gofarg->got_elt_size;
+ }
+ else
+ h->got.offset = (bfd_vma) -1;
+
+ return TRUE;
+}
+
+/* And an accompanying bit to work out final got entry offsets once
+ we're done. Should be called from final_link. */
+
+bfd_boolean
+bfd_elf_gc_common_finalize_got_offsets (bfd *abfd,
+ struct bfd_link_info *info)
+{
+ bfd *i;
+ const struct elf_backend_data *bed = get_elf_backend_data (abfd);
+ bfd_vma gotoff;
+ unsigned int got_elt_size = bed->s->arch_size / 8;
+ struct alloc_got_off_arg gofarg;
+
+ if (! is_elf_hash_table (info->hash))
+ return FALSE;
+
+ /* The GOT offset is relative to the .got section, but the GOT header is
+ put into the .got.plt section, if the backend uses it. */
+ if (bed->want_got_plt)
+ gotoff = 0;
+ else
+ gotoff = bed->got_header_size;
+
+ /* Do the local .got entries first. */
+ for (i = info->input_bfds; i; i = i->link_next)
+ {
+ bfd_signed_vma *local_got;
+ bfd_size_type j, locsymcount;
+ Elf_Internal_Shdr *symtab_hdr;
+
+ if (bfd_get_flavour (i) != bfd_target_elf_flavour)
+ continue;
+
+ local_got = elf_local_got_refcounts (i);
+ if (!local_got)
+ continue;
+
+ symtab_hdr = &elf_tdata (i)->symtab_hdr;
+ if (elf_bad_symtab (i))
+ locsymcount = symtab_hdr->sh_size / bed->s->sizeof_sym;
+ else
+ locsymcount = symtab_hdr->sh_info;
+
+ for (j = 0; j < locsymcount; ++j)
+ {
+ if (local_got[j] > 0)
+ {
+ local_got[j] = gotoff;
+ gotoff += got_elt_size;
+ }
+ else
+ local_got[j] = (bfd_vma) -1;
+ }
+ }
+
+ /* Then the global .got entries. .plt refcounts are handled by
+ adjust_dynamic_symbol */
+ gofarg.gotoff = gotoff;
+ gofarg.got_elt_size = got_elt_size;
+ elf_link_hash_traverse (elf_hash_table (info),
+ elf_gc_allocate_got_offsets,
+ &gofarg);
+ return TRUE;
+}
+
+/* Many folk need no more in the way of final link than this, once
+ got entry reference counting is enabled. */
+
+bfd_boolean
+bfd_elf_gc_common_final_link (bfd *abfd, struct bfd_link_info *info)
+{
+ if (!bfd_elf_gc_common_finalize_got_offsets (abfd, info))
+ return FALSE;
+
+ /* Invoke the regular ELF backend linker to do all the work. */
+ return bfd_elf_final_link (abfd, info);
+}
+
+bfd_boolean
+bfd_elf_reloc_symbol_deleted_p (bfd_vma offset, void *cookie)
+{
+ struct elf_reloc_cookie *rcookie = cookie;
+
+ if (rcookie->bad_symtab)
+ rcookie->rel = rcookie->rels;
+
+ for (; rcookie->rel < rcookie->relend; rcookie->rel++)
+ {
+ unsigned long r_symndx;
+
+ if (! rcookie->bad_symtab)
+ if (rcookie->rel->r_offset > offset)
+ return FALSE;
+ if (rcookie->rel->r_offset != offset)
+ continue;
+
+ r_symndx = rcookie->rel->r_info >> rcookie->r_sym_shift;
+ if (r_symndx == SHN_UNDEF)
+ return TRUE;
+
+ if (r_symndx >= rcookie->locsymcount
+ || ELF_ST_BIND (rcookie->locsyms[r_symndx].st_info) != STB_LOCAL)
+ {
+ struct elf_link_hash_entry *h;
+
+ h = rcookie->sym_hashes[r_symndx - rcookie->extsymoff];
+
+ while (h->root.type == bfd_link_hash_indirect
+ || h->root.type == bfd_link_hash_warning)
+ h = (struct elf_link_hash_entry *) h->root.u.i.link;
+
+ if ((h->root.type == bfd_link_hash_defined
+ || h->root.type == bfd_link_hash_defweak)
+ && elf_discarded_section (h->root.u.def.section))
+ return TRUE;
+ else
+ return FALSE;
+ }
+ else
+ {
+ /* It's not a relocation against a global symbol,
+ but it could be a relocation against a local
+ symbol for a discarded section. */
+ asection *isec;
+ Elf_Internal_Sym *isym;
+
+ /* Need to: get the symbol; get the section. */
+ isym = &rcookie->locsyms[r_symndx];
+ if (isym->st_shndx < SHN_LORESERVE || isym->st_shndx > SHN_HIRESERVE)
+ {
+ isec = bfd_section_from_elf_index (rcookie->abfd, isym->st_shndx);
+ if (isec != NULL && elf_discarded_section (isec))
+ return TRUE;
+ }
+ }
+ return FALSE;
+ }
+ return FALSE;
+}
+
+/* Discard unneeded references to discarded sections.
+ Returns TRUE if any section's size was changed. */
+/* This function assumes that the relocations are in sorted order,
+ which is true for all known assemblers. */
+
+bfd_boolean
+bfd_elf_discard_info (bfd *output_bfd, struct bfd_link_info *info)
+{
+ struct elf_reloc_cookie cookie;
+ asection *stab, *eh;
+ Elf_Internal_Shdr *symtab_hdr;
+ const struct elf_backend_data *bed;
+ bfd *abfd;
+ unsigned int count;
+ bfd_boolean ret = FALSE;
+
+ if (info->traditional_format
+ || !is_elf_hash_table (info->hash))
+ return FALSE;
+
+ for (abfd = info->input_bfds; abfd != NULL; abfd = abfd->link_next)
+ {
+ if (bfd_get_flavour (abfd) != bfd_target_elf_flavour)
+ continue;
+
+ bed = get_elf_backend_data (abfd);
+
+ if ((abfd->flags & DYNAMIC) != 0)
+ continue;
+
+ eh = bfd_get_section_by_name (abfd, ".eh_frame");
+ if (info->relocatable
+ || (eh != NULL
+ && (eh->_raw_size == 0
+ || bfd_is_abs_section (eh->output_section))))
+ eh = NULL;
+
+ stab = bfd_get_section_by_name (abfd, ".stab");
+ if (stab != NULL
+ && (stab->_raw_size == 0
+ || bfd_is_abs_section (stab->output_section)
+ || stab->sec_info_type != ELF_INFO_TYPE_STABS))
+ stab = NULL;
+
+ if (stab == NULL
+ && eh == NULL
+ && bed->elf_backend_discard_info == NULL)
+ continue;
+
+ symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
+ cookie.abfd = abfd;
+ cookie.sym_hashes = elf_sym_hashes (abfd);
+ cookie.bad_symtab = elf_bad_symtab (abfd);
+ if (cookie.bad_symtab)
+ {
+ cookie.locsymcount = symtab_hdr->sh_size / bed->s->sizeof_sym;
+ cookie.extsymoff = 0;
+ }
+ else
+ {
+ cookie.locsymcount = symtab_hdr->sh_info;
+ cookie.extsymoff = symtab_hdr->sh_info;
+ }
+
+ if (bed->s->arch_size == 32)
+ cookie.r_sym_shift = 8;
+ else
+ cookie.r_sym_shift = 32;
+
+ cookie.locsyms = (Elf_Internal_Sym *) symtab_hdr->contents;
+ if (cookie.locsyms == NULL && cookie.locsymcount != 0)
+ {
+ cookie.locsyms = bfd_elf_get_elf_syms (abfd, symtab_hdr,
+ cookie.locsymcount, 0,
+ NULL, NULL, NULL);
+ if (cookie.locsyms == NULL)
+ return FALSE;
+ }
+
+ if (stab != NULL)
+ {
+ cookie.rels = NULL;
+ count = stab->reloc_count;
+ if (count != 0)
+ cookie.rels = _bfd_elf_link_read_relocs (abfd, stab, NULL, NULL,
+ info->keep_memory);
+ if (cookie.rels != NULL)
+ {
+ cookie.rel = cookie.rels;
+ cookie.relend = cookie.rels;
+ cookie.relend += count * bed->s->int_rels_per_ext_rel;
+ if (_bfd_discard_section_stabs (abfd, stab,
+ elf_section_data (stab)->sec_info,
+ bfd_elf_reloc_symbol_deleted_p,
+ &cookie))
+ ret = TRUE;
+ if (elf_section_data (stab)->relocs != cookie.rels)
+ free (cookie.rels);
+ }
+ }
+
+ if (eh != NULL)
+ {
+ cookie.rels = NULL;
+ count = eh->reloc_count;
+ if (count != 0)
+ cookie.rels = _bfd_elf_link_read_relocs (abfd, eh, NULL, NULL,
+ info->keep_memory);
+ cookie.rel = cookie.rels;
+ cookie.relend = cookie.rels;
+ if (cookie.rels != NULL)
+ cookie.relend += count * bed->s->int_rels_per_ext_rel;
+
+ if (_bfd_elf_discard_section_eh_frame (abfd, info, eh,
+ bfd_elf_reloc_symbol_deleted_p,
+ &cookie))
+ ret = TRUE;
+
+ if (cookie.rels != NULL
+ && elf_section_data (eh)->relocs != cookie.rels)
+ free (cookie.rels);
+ }
+
+ if (bed->elf_backend_discard_info != NULL
+ && (*bed->elf_backend_discard_info) (abfd, &cookie, info))
+ ret = TRUE;
+
+ if (cookie.locsyms != NULL
+ && symtab_hdr->contents != (unsigned char *) cookie.locsyms)
+ {
+ if (! info->keep_memory)
+ free (cookie.locsyms);
+ else
+ symtab_hdr->contents = (unsigned char *) cookie.locsyms;
+ }
+ }
+
+ if (info->eh_frame_hdr
+ && !info->relocatable
+ && _bfd_elf_discard_section_eh_frame_hdr (output_bfd, info))
+ ret = TRUE;
+
+ return ret;
}
diff --git a/contrib/binutils/bfd/elfxx-ia64.c b/contrib/binutils/bfd/elfxx-ia64.c
index 06a279e..b19aac2 100644
--- a/contrib/binutils/bfd/elfxx-ia64.c
+++ b/contrib/binutils/bfd/elfxx-ia64.c
@@ -1,22 +1,23 @@
/* IA-64 support for 64-bit ELF
- Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004
+ Free Software Foundation, Inc.
Contributed by David Mosberger-Tang <davidm@hpl.hp.com>
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "bfd.h"
#include "sysdep.h"
@@ -24,38 +25,36 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "elf-bfd.h"
#include "opcode/ia64.h"
#include "elf/ia64.h"
+#include "objalloc.h"
+#include "hashtab.h"
-/*
- * THE RULES for all the stuff the linker creates --
- *
- * GOT Entries created in response to LTOFF or LTOFF_FPTR
- * relocations. Dynamic relocs created for dynamic
- * symbols in an application; REL relocs for locals
- * in a shared library.
- *
- * FPTR The canonical function descriptor. Created for local
- * symbols in applications. Descriptors for dynamic symbols
- * and local symbols in shared libraries are created by
- * ld.so. Thus there are no dynamic relocs against these
- * objects. The FPTR relocs for such _are_ passed through
- * to the dynamic relocation tables.
- *
- * FULL_PLT Created for a PCREL21B relocation against a dynamic symbol.
- * Requires the creation of a PLTOFF entry. This does not
- * require any dynamic relocations.
- *
- * PLTOFF Created by PLTOFF relocations. For local symbols, this
- * is an alternate function descriptor, and in shared libraries
- * requires two REL relocations. Note that this cannot be
- * transformed into an FPTR relocation, since it must be in
- * range of the GP. For dynamic symbols, this is a function
- * descriptor for a MIN_PLT entry, and requires one IPLT reloc.
- *
- * MIN_PLT Created by PLTOFF entries against dynamic symbols. This
- * does not reqire dynamic relocations.
- */
-
-#define USE_RELA /* we want RELA relocs, not REL */
+/* THE RULES for all the stuff the linker creates --
+
+ GOT Entries created in response to LTOFF or LTOFF_FPTR
+ relocations. Dynamic relocs created for dynamic
+ symbols in an application; REL relocs for locals
+ in a shared library.
+
+ FPTR The canonical function descriptor. Created for local
+ symbols in applications. Descriptors for dynamic symbols
+ and local symbols in shared libraries are created by
+ ld.so. Thus there are no dynamic relocs against these
+ objects. The FPTR relocs for such _are_ passed through
+ to the dynamic relocation tables.
+
+ FULL_PLT Created for a PCREL21B relocation against a dynamic symbol.
+ Requires the creation of a PLTOFF entry. This does not
+ require any dynamic relocations.
+
+ PLTOFF Created by PLTOFF relocations. For local symbols, this
+ is an alternate function descriptor, and in shared libraries
+ requires two REL relocations. Note that this cannot be
+ transformed into an FPTR relocation, since it must be in
+ range of the GP. For dynamic symbols, this is a function
+ descriptor for a MIN_PLT entry, and requires one IPLT reloc.
+
+ MIN_PLT Created by PLTOFF entries against dynamic symbols. This
+ does not require dynamic relocations. */
#define NELEMS(a) ((int) (sizeof (a) / sizeof ((a)[0])))
@@ -83,7 +82,7 @@ struct elfNN_ia64_dyn_sym_info
bfd_vma dtpmod_offset;
bfd_vma dtprel_offset;
- /* The symbol table entry, if any, that this was derrived from. */
+ /* The symbol table entry, if any, that this was derived from. */
struct elf_link_hash_entry *h;
/* Used to count non-got, non-plt relocations for delayed sizing
@@ -94,9 +93,12 @@ struct elfNN_ia64_dyn_sym_info
asection *srel;
int type;
int count;
+
+ /* Is this reloc against readonly section? */
+ bfd_boolean reltext;
} *reloc_entries;
- /* True when the section contents have been updated. */
+ /* TRUE when the section contents have been updated. */
unsigned got_done : 1;
unsigned fptr_done : 1;
unsigned pltoff_done : 1;
@@ -104,8 +106,9 @@ struct elfNN_ia64_dyn_sym_info
unsigned dtpmod_done : 1;
unsigned dtprel_done : 1;
- /* True for the different kinds of linker data we want created. */
+ /* TRUE for the different kinds of linker data we want created. */
unsigned want_got : 1;
+ unsigned want_gotx : 1;
unsigned want_fptr : 1;
unsigned want_ltoff_fptr : 1;
unsigned want_plt : 1;
@@ -118,20 +121,15 @@ struct elfNN_ia64_dyn_sym_info
struct elfNN_ia64_local_hash_entry
{
- struct bfd_hash_entry root;
+ int id;
+ unsigned int r_sym;
struct elfNN_ia64_dyn_sym_info *info;
- /* True if this hash entry's addends was translated for
+ /* TRUE if this hash entry's addends was translated for
SHF_MERGE optimization. */
unsigned sec_merge_done : 1;
};
-struct elfNN_ia64_local_hash_table
-{
- struct bfd_hash_table root;
- /* No additional fields for now. */
-};
-
struct elfNN_ia64_link_hash_entry
{
struct elf_link_hash_entry root;
@@ -140,20 +138,30 @@ struct elfNN_ia64_link_hash_entry
struct elfNN_ia64_link_hash_table
{
- /* The main hash table */
+ /* The main hash table. */
struct elf_link_hash_table root;
asection *got_sec; /* the linkage table section (or NULL) */
asection *rel_got_sec; /* dynamic relocation section for same */
asection *fptr_sec; /* function descriptor table (or NULL) */
+ asection *rel_fptr_sec; /* dynamic relocation section for same */
asection *plt_sec; /* the primary plt section (or NULL) */
asection *pltoff_sec; /* private descriptors for plt (or NULL) */
asection *rel_pltoff_sec; /* dynamic relocation section for same */
bfd_size_type minplt_entries; /* number of minplt entries */
unsigned reltext : 1; /* are there relocs against readonly sections? */
+ unsigned self_dtpmod_done : 1;/* has self DTPMOD entry been finished? */
+ bfd_vma self_dtpmod_offset; /* .got offset to self DTPMOD entry */
- struct elfNN_ia64_local_hash_table loc_hash_table;
+ htab_t loc_hash_table;
+ void *loc_hash_memory;
+};
+
+struct elfNN_ia64_allocate_data
+{
+ struct bfd_link_info *info;
+ bfd_size_type ofs;
};
#define elfNN_ia64_hash_table(p) \
@@ -167,76 +175,66 @@ static reloc_howto_type * lookup_howto
static reloc_howto_type *elfNN_ia64_reloc_type_lookup
PARAMS ((bfd *abfd, bfd_reloc_code_real_type bfd_code));
static void elfNN_ia64_info_to_howto
- PARAMS ((bfd *abfd, arelent *bfd_reloc, ElfNN_Internal_Rela *elf_reloc));
-static boolean elfNN_ia64_relax_section
+ PARAMS ((bfd *abfd, arelent *bfd_reloc, Elf_Internal_Rela *elf_reloc));
+static bfd_boolean elfNN_ia64_relax_section
PARAMS((bfd *abfd, asection *sec, struct bfd_link_info *link_info,
- boolean *again));
-static boolean is_unwind_section_name
+ bfd_boolean *again));
+static void elfNN_ia64_relax_ldxmov
+ PARAMS((bfd *abfd, bfd_byte *contents, bfd_vma off));
+static bfd_boolean is_unwind_section_name
PARAMS ((bfd *abfd, const char *));
-static boolean elfNN_ia64_section_from_shdr
- PARAMS ((bfd *, ElfNN_Internal_Shdr *, const char *));
-static boolean elfNN_ia64_section_flags
- PARAMS ((flagword *, ElfNN_Internal_Shdr *));
-static boolean elfNN_ia64_fake_sections
- PARAMS ((bfd *abfd, ElfNN_Internal_Shdr *hdr, asection *sec));
+static bfd_boolean elfNN_ia64_section_from_shdr
+ PARAMS ((bfd *, Elf_Internal_Shdr *, const char *));
+static bfd_boolean elfNN_ia64_section_flags
+ PARAMS ((flagword *, Elf_Internal_Shdr *));
+static bfd_boolean elfNN_ia64_fake_sections
+ PARAMS ((bfd *abfd, Elf_Internal_Shdr *hdr, asection *sec));
static void elfNN_ia64_final_write_processing
- PARAMS ((bfd *abfd, boolean linker));
-static boolean elfNN_ia64_add_symbol_hook
- PARAMS ((bfd *abfd, struct bfd_link_info *info, const Elf_Internal_Sym *sym,
- const char **namep, flagword *flagsp, asection **secp,
- bfd_vma *valp));
-static boolean elfNN_ia64_aix_vec
- PARAMS ((const bfd_target *vec));
-static boolean elfNN_ia64_aix_add_symbol_hook
- PARAMS ((bfd *abfd, struct bfd_link_info *info, const Elf_Internal_Sym *sym,
+ PARAMS ((bfd *abfd, bfd_boolean linker));
+static bfd_boolean elfNN_ia64_add_symbol_hook
+ PARAMS ((bfd *abfd, struct bfd_link_info *info, Elf_Internal_Sym *sym,
const char **namep, flagword *flagsp, asection **secp,
bfd_vma *valp));
-static boolean elfNN_ia64_aix_link_add_symbols
- PARAMS ((bfd *abfd, struct bfd_link_info *info));
static int elfNN_ia64_additional_program_headers
PARAMS ((bfd *abfd));
-static boolean elfNN_ia64_modify_segment_map
- PARAMS ((bfd *));
-static boolean elfNN_ia64_is_local_label_name
+static bfd_boolean elfNN_ia64_modify_segment_map
+ PARAMS ((bfd *, struct bfd_link_info *));
+static bfd_boolean elfNN_ia64_is_local_label_name
PARAMS ((bfd *abfd, const char *name));
-static boolean elfNN_ia64_dynamic_symbol_p
- PARAMS ((struct elf_link_hash_entry *h, struct bfd_link_info *info));
-static boolean elfNN_ia64_local_hash_table_init
- PARAMS ((struct elfNN_ia64_local_hash_table *ht, bfd *abfd,
- new_hash_entry_func new));
-static struct bfd_hash_entry *elfNN_ia64_new_loc_hash_entry
- PARAMS ((struct bfd_hash_entry *entry, struct bfd_hash_table *table,
- const char *string));
+static bfd_boolean elfNN_ia64_dynamic_symbol_p
+ PARAMS ((struct elf_link_hash_entry *h, struct bfd_link_info *info, int));
static struct bfd_hash_entry *elfNN_ia64_new_elf_hash_entry
PARAMS ((struct bfd_hash_entry *entry, struct bfd_hash_table *table,
const char *string));
static void elfNN_ia64_hash_copy_indirect
- PARAMS ((struct elf_backend_data *, struct elf_link_hash_entry *,
+ PARAMS ((const struct elf_backend_data *, struct elf_link_hash_entry *,
struct elf_link_hash_entry *));
static void elfNN_ia64_hash_hide_symbol
- PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *, boolean));
+ PARAMS ((struct bfd_link_info *, struct elf_link_hash_entry *, bfd_boolean));
+static hashval_t elfNN_ia64_local_htab_hash PARAMS ((const void *));
+static int elfNN_ia64_local_htab_eq PARAMS ((const void *ptr1,
+ const void *ptr2));
static struct bfd_link_hash_table *elfNN_ia64_hash_table_create
PARAMS ((bfd *abfd));
-static struct elfNN_ia64_local_hash_entry *elfNN_ia64_local_hash_lookup
- PARAMS ((struct elfNN_ia64_local_hash_table *table, const char *string,
- boolean create, boolean copy));
-static boolean elfNN_ia64_global_dyn_sym_thunk
- PARAMS ((struct bfd_hash_entry *, PTR));
-static boolean elfNN_ia64_local_dyn_sym_thunk
+static void elfNN_ia64_hash_table_free
+ PARAMS ((struct bfd_link_hash_table *hash));
+static bfd_boolean elfNN_ia64_global_dyn_sym_thunk
PARAMS ((struct bfd_hash_entry *, PTR));
+static int elfNN_ia64_local_dyn_sym_thunk
+ PARAMS ((void **, PTR));
static void elfNN_ia64_dyn_sym_traverse
PARAMS ((struct elfNN_ia64_link_hash_table *ia64_info,
- boolean (*func) (struct elfNN_ia64_dyn_sym_info *, PTR),
+ bfd_boolean (*func) (struct elfNN_ia64_dyn_sym_info *, PTR),
PTR info));
-static boolean elfNN_ia64_create_dynamic_sections
+static bfd_boolean elfNN_ia64_create_dynamic_sections
PARAMS ((bfd *abfd, struct bfd_link_info *info));
static struct elfNN_ia64_local_hash_entry * get_local_sym_hash
PARAMS ((struct elfNN_ia64_link_hash_table *ia64_info,
- bfd *abfd, const Elf_Internal_Rela *rel, boolean create));
+ bfd *abfd, const Elf_Internal_Rela *rel, bfd_boolean create));
static struct elfNN_ia64_dyn_sym_info * get_dyn_sym_info
PARAMS ((struct elfNN_ia64_link_hash_table *ia64_info,
struct elf_link_hash_entry *h,
- bfd *abfd, const Elf_Internal_Rela *rel, boolean create));
+ bfd *abfd, const Elf_Internal_Rela *rel, bfd_boolean create));
static asection *get_got
PARAMS ((bfd *abfd, struct bfd_link_info *info,
struct elfNN_ia64_link_hash_table *ia64_info));
@@ -248,34 +246,31 @@ static asection *get_pltoff
struct elfNN_ia64_link_hash_table *ia64_info));
static asection *get_reloc_section
PARAMS ((bfd *abfd, struct elfNN_ia64_link_hash_table *ia64_info,
- asection *sec, boolean create));
-static boolean count_dyn_reloc
- PARAMS ((bfd *abfd, struct elfNN_ia64_dyn_sym_info *dyn_i,
- asection *srel, int type));
-static boolean elfNN_ia64_check_relocs
+ asection *sec, bfd_boolean create));
+static bfd_boolean elfNN_ia64_check_relocs
PARAMS ((bfd *abfd, struct bfd_link_info *info, asection *sec,
const Elf_Internal_Rela *relocs));
-static boolean elfNN_ia64_adjust_dynamic_symbol
+static bfd_boolean elfNN_ia64_adjust_dynamic_symbol
PARAMS ((struct bfd_link_info *info, struct elf_link_hash_entry *h));
static long global_sym_index
PARAMS ((struct elf_link_hash_entry *h));
-static boolean allocate_fptr
+static bfd_boolean allocate_fptr
PARAMS ((struct elfNN_ia64_dyn_sym_info *dyn_i, PTR data));
-static boolean allocate_global_data_got
+static bfd_boolean allocate_global_data_got
PARAMS ((struct elfNN_ia64_dyn_sym_info *dyn_i, PTR data));
-static boolean allocate_global_fptr_got
+static bfd_boolean allocate_global_fptr_got
PARAMS ((struct elfNN_ia64_dyn_sym_info *dyn_i, PTR data));
-static boolean allocate_local_got
+static bfd_boolean allocate_local_got
PARAMS ((struct elfNN_ia64_dyn_sym_info *dyn_i, PTR data));
-static boolean allocate_pltoff_entries
+static bfd_boolean allocate_pltoff_entries
PARAMS ((struct elfNN_ia64_dyn_sym_info *dyn_i, PTR data));
-static boolean allocate_plt_entries
+static bfd_boolean allocate_plt_entries
PARAMS ((struct elfNN_ia64_dyn_sym_info *dyn_i, PTR data));
-static boolean allocate_plt2_entries
+static bfd_boolean allocate_plt2_entries
PARAMS ((struct elfNN_ia64_dyn_sym_info *dyn_i, PTR data));
-static boolean allocate_dynrel_entries
+static bfd_boolean allocate_dynrel_entries
PARAMS ((struct elfNN_ia64_dyn_sym_info *dyn_i, PTR data));
-static boolean elfNN_ia64_size_dynamic_sections
+static bfd_boolean elfNN_ia64_size_dynamic_sections
PARAMS ((bfd *output_bfd, struct bfd_link_info *info));
static bfd_reloc_status_type elfNN_ia64_install_value
PARAMS ((bfd *abfd, bfd_byte *hit_addr, bfd_vma val, unsigned int r_type));
@@ -294,41 +289,43 @@ static bfd_vma set_fptr_entry
static bfd_vma set_pltoff_entry
PARAMS ((bfd *abfd, struct bfd_link_info *info,
struct elfNN_ia64_dyn_sym_info *dyn_i,
- bfd_vma value, boolean));
+ bfd_vma value, bfd_boolean));
static bfd_vma elfNN_ia64_tprel_base
PARAMS ((struct bfd_link_info *info));
static bfd_vma elfNN_ia64_dtprel_base
PARAMS ((struct bfd_link_info *info));
static int elfNN_ia64_unwind_entry_compare
PARAMS ((const PTR, const PTR));
-static boolean elfNN_ia64_final_link
+static bfd_boolean elfNN_ia64_choose_gp
PARAMS ((bfd *abfd, struct bfd_link_info *info));
-static boolean elfNN_ia64_relocate_section
+static bfd_boolean elfNN_ia64_final_link
+ PARAMS ((bfd *abfd, struct bfd_link_info *info));
+static bfd_boolean elfNN_ia64_relocate_section
PARAMS ((bfd *output_bfd, struct bfd_link_info *info, bfd *input_bfd,
asection *input_section, bfd_byte *contents,
Elf_Internal_Rela *relocs, Elf_Internal_Sym *local_syms,
asection **local_sections));
-static boolean elfNN_ia64_finish_dynamic_symbol
+static bfd_boolean elfNN_ia64_finish_dynamic_symbol
PARAMS ((bfd *output_bfd, struct bfd_link_info *info,
struct elf_link_hash_entry *h, Elf_Internal_Sym *sym));
-static boolean elfNN_ia64_finish_dynamic_sections
+static bfd_boolean elfNN_ia64_finish_dynamic_sections
PARAMS ((bfd *abfd, struct bfd_link_info *info));
-static boolean elfNN_ia64_set_private_flags
+static bfd_boolean elfNN_ia64_set_private_flags
PARAMS ((bfd *abfd, flagword flags));
-static boolean elfNN_ia64_merge_private_bfd_data
+static bfd_boolean elfNN_ia64_merge_private_bfd_data
PARAMS ((bfd *ibfd, bfd *obfd));
-static boolean elfNN_ia64_print_private_bfd_data
+static bfd_boolean elfNN_ia64_print_private_bfd_data
PARAMS ((bfd *abfd, PTR ptr));
static enum elf_reloc_type_class elfNN_ia64_reloc_type_class
PARAMS ((const Elf_Internal_Rela *));
-static boolean elfNN_ia64_hpux_vec
+static bfd_boolean elfNN_ia64_hpux_vec
PARAMS ((const bfd_target *vec));
static void elfNN_hpux_post_process_headers
PARAMS ((bfd *abfd, struct bfd_link_info *info));
-boolean elfNN_hpux_backend_section_from_bfd_section
+bfd_boolean elfNN_hpux_backend_section_from_bfd_section
PARAMS ((bfd *abfd, asection *sec, int *retval));
-/* ia64-specific relocation */
+/* ia64-specific relocation. */
/* Perform a relocation. Not much to do here as all the hard work is
done in elfNN_ia64_final_link_relocate. */
@@ -348,121 +345,125 @@ elfNN_ia64_reloc (abfd, reloc, sym, data, input_section,
reloc->address += input_section->output_offset;
return bfd_reloc_ok;
}
+
+ if (input_section->flags & SEC_DEBUGGING)
+ return bfd_reloc_continue;
+
*error_message = "Unsupported call to elfNN_ia64_reloc";
return bfd_reloc_notsupported;
}
#define IA64_HOWTO(TYPE, NAME, SIZE, PCREL, IN) \
HOWTO (TYPE, 0, SIZE, 0, PCREL, 0, complain_overflow_signed, \
- elfNN_ia64_reloc, NAME, false, 0, 0, IN)
+ elfNN_ia64_reloc, NAME, FALSE, 0, -1, IN)
/* This table has to be sorted according to increasing number of the
TYPE field. */
static reloc_howto_type ia64_howto_table[] =
{
- IA64_HOWTO (R_IA64_NONE, "NONE", 0, false, true),
-
- IA64_HOWTO (R_IA64_IMM14, "IMM14", 0, false, true),
- IA64_HOWTO (R_IA64_IMM22, "IMM22", 0, false, true),
- IA64_HOWTO (R_IA64_IMM64, "IMM64", 0, false, true),
- IA64_HOWTO (R_IA64_DIR32MSB, "DIR32MSB", 2, false, true),
- IA64_HOWTO (R_IA64_DIR32LSB, "DIR32LSB", 2, false, true),
- IA64_HOWTO (R_IA64_DIR64MSB, "DIR64MSB", 4, false, true),
- IA64_HOWTO (R_IA64_DIR64LSB, "DIR64LSB", 4, false, true),
-
- IA64_HOWTO (R_IA64_GPREL22, "GPREL22", 0, false, true),
- IA64_HOWTO (R_IA64_GPREL64I, "GPREL64I", 0, false, true),
- IA64_HOWTO (R_IA64_GPREL32MSB, "GPREL32MSB", 2, false, true),
- IA64_HOWTO (R_IA64_GPREL32LSB, "GPREL32LSB", 2, false, true),
- IA64_HOWTO (R_IA64_GPREL64MSB, "GPREL64MSB", 4, false, true),
- IA64_HOWTO (R_IA64_GPREL64LSB, "GPREL64LSB", 4, false, true),
-
- IA64_HOWTO (R_IA64_LTOFF22, "LTOFF22", 0, false, true),
- IA64_HOWTO (R_IA64_LTOFF64I, "LTOFF64I", 0, false, true),
-
- IA64_HOWTO (R_IA64_PLTOFF22, "PLTOFF22", 0, false, true),
- IA64_HOWTO (R_IA64_PLTOFF64I, "PLTOFF64I", 0, false, true),
- IA64_HOWTO (R_IA64_PLTOFF64MSB, "PLTOFF64MSB", 4, false, true),
- IA64_HOWTO (R_IA64_PLTOFF64LSB, "PLTOFF64LSB", 4, false, true),
-
- IA64_HOWTO (R_IA64_FPTR64I, "FPTR64I", 0, false, true),
- IA64_HOWTO (R_IA64_FPTR32MSB, "FPTR32MSB", 2, false, true),
- IA64_HOWTO (R_IA64_FPTR32LSB, "FPTR32LSB", 2, false, true),
- IA64_HOWTO (R_IA64_FPTR64MSB, "FPTR64MSB", 4, false, true),
- IA64_HOWTO (R_IA64_FPTR64LSB, "FPTR64LSB", 4, false, true),
-
- IA64_HOWTO (R_IA64_PCREL60B, "PCREL60B", 0, true, true),
- IA64_HOWTO (R_IA64_PCREL21B, "PCREL21B", 0, true, true),
- IA64_HOWTO (R_IA64_PCREL21M, "PCREL21M", 0, true, true),
- IA64_HOWTO (R_IA64_PCREL21F, "PCREL21F", 0, true, true),
- IA64_HOWTO (R_IA64_PCREL32MSB, "PCREL32MSB", 2, true, true),
- IA64_HOWTO (R_IA64_PCREL32LSB, "PCREL32LSB", 2, true, true),
- IA64_HOWTO (R_IA64_PCREL64MSB, "PCREL64MSB", 4, true, true),
- IA64_HOWTO (R_IA64_PCREL64LSB, "PCREL64LSB", 4, true, true),
-
- IA64_HOWTO (R_IA64_LTOFF_FPTR22, "LTOFF_FPTR22", 0, false, true),
- IA64_HOWTO (R_IA64_LTOFF_FPTR64I, "LTOFF_FPTR64I", 0, false, true),
- IA64_HOWTO (R_IA64_LTOFF_FPTR32MSB, "LTOFF_FPTR32MSB", 2, false, true),
- IA64_HOWTO (R_IA64_LTOFF_FPTR32LSB, "LTOFF_FPTR32LSB", 2, false, true),
- IA64_HOWTO (R_IA64_LTOFF_FPTR64MSB, "LTOFF_FPTR64MSB", 4, false, true),
- IA64_HOWTO (R_IA64_LTOFF_FPTR64LSB, "LTOFF_FPTR64LSB", 4, false, true),
-
- IA64_HOWTO (R_IA64_SEGREL32MSB, "SEGREL32MSB", 2, false, true),
- IA64_HOWTO (R_IA64_SEGREL32LSB, "SEGREL32LSB", 2, false, true),
- IA64_HOWTO (R_IA64_SEGREL64MSB, "SEGREL64MSB", 4, false, true),
- IA64_HOWTO (R_IA64_SEGREL64LSB, "SEGREL64LSB", 4, false, true),
-
- IA64_HOWTO (R_IA64_SECREL32MSB, "SECREL32MSB", 2, false, true),
- IA64_HOWTO (R_IA64_SECREL32LSB, "SECREL32LSB", 2, false, true),
- IA64_HOWTO (R_IA64_SECREL64MSB, "SECREL64MSB", 4, false, true),
- IA64_HOWTO (R_IA64_SECREL64LSB, "SECREL64LSB", 4, false, true),
-
- IA64_HOWTO (R_IA64_REL32MSB, "REL32MSB", 2, false, true),
- IA64_HOWTO (R_IA64_REL32LSB, "REL32LSB", 2, false, true),
- IA64_HOWTO (R_IA64_REL64MSB, "REL64MSB", 4, false, true),
- IA64_HOWTO (R_IA64_REL64LSB, "REL64LSB", 4, false, true),
-
- IA64_HOWTO (R_IA64_LTV32MSB, "LTV32MSB", 2, false, true),
- IA64_HOWTO (R_IA64_LTV32LSB, "LTV32LSB", 2, false, true),
- IA64_HOWTO (R_IA64_LTV64MSB, "LTV64MSB", 4, false, true),
- IA64_HOWTO (R_IA64_LTV64LSB, "LTV64LSB", 4, false, true),
-
- IA64_HOWTO (R_IA64_PCREL21BI, "PCREL21BI", 0, true, true),
- IA64_HOWTO (R_IA64_PCREL22, "PCREL22", 0, true, true),
- IA64_HOWTO (R_IA64_PCREL64I, "PCREL64I", 0, true, true),
-
- IA64_HOWTO (R_IA64_IPLTMSB, "IPLTMSB", 4, false, true),
- IA64_HOWTO (R_IA64_IPLTLSB, "IPLTLSB", 4, false, true),
- IA64_HOWTO (R_IA64_COPY, "COPY", 4, false, true),
- IA64_HOWTO (R_IA64_LTOFF22X, "LTOFF22X", 0, false, true),
- IA64_HOWTO (R_IA64_LDXMOV, "LDXMOV", 0, false, true),
-
- IA64_HOWTO (R_IA64_TPREL14, "TPREL14", 0, false, false),
- IA64_HOWTO (R_IA64_TPREL22, "TPREL22", 0, false, false),
- IA64_HOWTO (R_IA64_TPREL64I, "TPREL64I", 0, false, false),
- IA64_HOWTO (R_IA64_TPREL64MSB, "TPREL64MSB", 8, false, false),
- IA64_HOWTO (R_IA64_TPREL64LSB, "TPREL64LSB", 8, false, false),
- IA64_HOWTO (R_IA64_LTOFF_TPREL22, "LTOFF_TPREL22", 0, false, false),
-
- IA64_HOWTO (R_IA64_DTPMOD64MSB, "TPREL64MSB", 8, false, false),
- IA64_HOWTO (R_IA64_DTPMOD64LSB, "TPREL64LSB", 8, false, false),
- IA64_HOWTO (R_IA64_LTOFF_DTPMOD22, "LTOFF_DTPMOD22", 0, false, false),
-
- IA64_HOWTO (R_IA64_DTPREL14, "DTPREL14", 0, false, false),
- IA64_HOWTO (R_IA64_DTPREL22, "DTPREL22", 0, false, false),
- IA64_HOWTO (R_IA64_DTPREL64I, "DTPREL64I", 0, false, false),
- IA64_HOWTO (R_IA64_DTPREL32MSB, "DTPREL32MSB", 4, false, false),
- IA64_HOWTO (R_IA64_DTPREL32LSB, "DTPREL32LSB", 4, false, false),
- IA64_HOWTO (R_IA64_DTPREL64MSB, "DTPREL64MSB", 8, false, false),
- IA64_HOWTO (R_IA64_DTPREL64LSB, "DTPREL64LSB", 8, false, false),
- IA64_HOWTO (R_IA64_LTOFF_DTPREL22, "LTOFF_DTPREL22", 0, false, false),
+ IA64_HOWTO (R_IA64_NONE, "NONE", 0, FALSE, TRUE),
+
+ IA64_HOWTO (R_IA64_IMM14, "IMM14", 0, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_IMM22, "IMM22", 0, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_IMM64, "IMM64", 0, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_DIR32MSB, "DIR32MSB", 2, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_DIR32LSB, "DIR32LSB", 2, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_DIR64MSB, "DIR64MSB", 4, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_DIR64LSB, "DIR64LSB", 4, FALSE, TRUE),
+
+ IA64_HOWTO (R_IA64_GPREL22, "GPREL22", 0, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_GPREL64I, "GPREL64I", 0, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_GPREL32MSB, "GPREL32MSB", 2, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_GPREL32LSB, "GPREL32LSB", 2, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_GPREL64MSB, "GPREL64MSB", 4, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_GPREL64LSB, "GPREL64LSB", 4, FALSE, TRUE),
+
+ IA64_HOWTO (R_IA64_LTOFF22, "LTOFF22", 0, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_LTOFF64I, "LTOFF64I", 0, FALSE, TRUE),
+
+ IA64_HOWTO (R_IA64_PLTOFF22, "PLTOFF22", 0, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_PLTOFF64I, "PLTOFF64I", 0, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_PLTOFF64MSB, "PLTOFF64MSB", 4, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_PLTOFF64LSB, "PLTOFF64LSB", 4, FALSE, TRUE),
+
+ IA64_HOWTO (R_IA64_FPTR64I, "FPTR64I", 0, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_FPTR32MSB, "FPTR32MSB", 2, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_FPTR32LSB, "FPTR32LSB", 2, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_FPTR64MSB, "FPTR64MSB", 4, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_FPTR64LSB, "FPTR64LSB", 4, FALSE, TRUE),
+
+ IA64_HOWTO (R_IA64_PCREL60B, "PCREL60B", 0, TRUE, TRUE),
+ IA64_HOWTO (R_IA64_PCREL21B, "PCREL21B", 0, TRUE, TRUE),
+ IA64_HOWTO (R_IA64_PCREL21M, "PCREL21M", 0, TRUE, TRUE),
+ IA64_HOWTO (R_IA64_PCREL21F, "PCREL21F", 0, TRUE, TRUE),
+ IA64_HOWTO (R_IA64_PCREL32MSB, "PCREL32MSB", 2, TRUE, TRUE),
+ IA64_HOWTO (R_IA64_PCREL32LSB, "PCREL32LSB", 2, TRUE, TRUE),
+ IA64_HOWTO (R_IA64_PCREL64MSB, "PCREL64MSB", 4, TRUE, TRUE),
+ IA64_HOWTO (R_IA64_PCREL64LSB, "PCREL64LSB", 4, TRUE, TRUE),
+
+ IA64_HOWTO (R_IA64_LTOFF_FPTR22, "LTOFF_FPTR22", 0, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_LTOFF_FPTR64I, "LTOFF_FPTR64I", 0, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_LTOFF_FPTR32MSB, "LTOFF_FPTR32MSB", 2, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_LTOFF_FPTR32LSB, "LTOFF_FPTR32LSB", 2, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_LTOFF_FPTR64MSB, "LTOFF_FPTR64MSB", 4, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_LTOFF_FPTR64LSB, "LTOFF_FPTR64LSB", 4, FALSE, TRUE),
+
+ IA64_HOWTO (R_IA64_SEGREL32MSB, "SEGREL32MSB", 2, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_SEGREL32LSB, "SEGREL32LSB", 2, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_SEGREL64MSB, "SEGREL64MSB", 4, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_SEGREL64LSB, "SEGREL64LSB", 4, FALSE, TRUE),
+
+ IA64_HOWTO (R_IA64_SECREL32MSB, "SECREL32MSB", 2, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_SECREL32LSB, "SECREL32LSB", 2, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_SECREL64MSB, "SECREL64MSB", 4, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_SECREL64LSB, "SECREL64LSB", 4, FALSE, TRUE),
+
+ IA64_HOWTO (R_IA64_REL32MSB, "REL32MSB", 2, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_REL32LSB, "REL32LSB", 2, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_REL64MSB, "REL64MSB", 4, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_REL64LSB, "REL64LSB", 4, FALSE, TRUE),
+
+ IA64_HOWTO (R_IA64_LTV32MSB, "LTV32MSB", 2, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_LTV32LSB, "LTV32LSB", 2, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_LTV64MSB, "LTV64MSB", 4, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_LTV64LSB, "LTV64LSB", 4, FALSE, TRUE),
+
+ IA64_HOWTO (R_IA64_PCREL21BI, "PCREL21BI", 0, TRUE, TRUE),
+ IA64_HOWTO (R_IA64_PCREL22, "PCREL22", 0, TRUE, TRUE),
+ IA64_HOWTO (R_IA64_PCREL64I, "PCREL64I", 0, TRUE, TRUE),
+
+ IA64_HOWTO (R_IA64_IPLTMSB, "IPLTMSB", 4, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_IPLTLSB, "IPLTLSB", 4, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_COPY, "COPY", 4, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_LTOFF22X, "LTOFF22X", 0, FALSE, TRUE),
+ IA64_HOWTO (R_IA64_LDXMOV, "LDXMOV", 0, FALSE, TRUE),
+
+ IA64_HOWTO (R_IA64_TPREL14, "TPREL14", 0, FALSE, FALSE),
+ IA64_HOWTO (R_IA64_TPREL22, "TPREL22", 0, FALSE, FALSE),
+ IA64_HOWTO (R_IA64_TPREL64I, "TPREL64I", 0, FALSE, FALSE),
+ IA64_HOWTO (R_IA64_TPREL64MSB, "TPREL64MSB", 4, FALSE, FALSE),
+ IA64_HOWTO (R_IA64_TPREL64LSB, "TPREL64LSB", 4, FALSE, FALSE),
+ IA64_HOWTO (R_IA64_LTOFF_TPREL22, "LTOFF_TPREL22", 0, FALSE, FALSE),
+
+ IA64_HOWTO (R_IA64_DTPMOD64MSB, "TPREL64MSB", 4, FALSE, FALSE),
+ IA64_HOWTO (R_IA64_DTPMOD64LSB, "TPREL64LSB", 4, FALSE, FALSE),
+ IA64_HOWTO (R_IA64_LTOFF_DTPMOD22, "LTOFF_DTPMOD22", 0, FALSE, FALSE),
+
+ IA64_HOWTO (R_IA64_DTPREL14, "DTPREL14", 0, FALSE, FALSE),
+ IA64_HOWTO (R_IA64_DTPREL22, "DTPREL22", 0, FALSE, FALSE),
+ IA64_HOWTO (R_IA64_DTPREL64I, "DTPREL64I", 0, FALSE, FALSE),
+ IA64_HOWTO (R_IA64_DTPREL32MSB, "DTPREL32MSB", 2, FALSE, FALSE),
+ IA64_HOWTO (R_IA64_DTPREL32LSB, "DTPREL32LSB", 2, FALSE, FALSE),
+ IA64_HOWTO (R_IA64_DTPREL64MSB, "DTPREL64MSB", 4, FALSE, FALSE),
+ IA64_HOWTO (R_IA64_DTPREL64LSB, "DTPREL64LSB", 4, FALSE, FALSE),
+ IA64_HOWTO (R_IA64_LTOFF_DTPREL22, "LTOFF_DTPREL22", 0, FALSE, FALSE),
};
static unsigned char elf_code_to_howto_index[R_IA64_MAX_RELOC_CODE + 1];
/* Given a BFD reloc type, return the matching HOWTO structure. */
-static reloc_howto_type*
+static reloc_howto_type *
lookup_howto (rtype)
unsigned int rtype;
{
@@ -601,7 +602,7 @@ static void
elfNN_ia64_info_to_howto (abfd, bfd_reloc, elf_reloc)
bfd *abfd ATTRIBUTE_UNUSED;
arelent *bfd_reloc;
- ElfNN_Internal_Rela *elf_reloc;
+ Elf_Internal_Rela *elf_reloc;
{
bfd_reloc->howto
= lookup_howto ((unsigned int) ELFNN_R_TYPE (elf_reloc->r_info));
@@ -635,7 +636,7 @@ static const bfd_byte plt_min_entry[PLT_MIN_ENTRY_SIZE] =
static const bfd_byte plt_full_entry[PLT_FULL_ENTRY_SIZE] =
{
0x0b, 0x78, 0x00, 0x02, 0x00, 0x24, /* [MMI] addl r15=0,r1;; */
- 0x00, 0x41, 0x3c, 0x30, 0x28, 0xc0, /* ld8 r16=[r15],8 */
+ 0x00, 0x41, 0x3c, 0x70, 0x29, 0xc0, /* ld8.acq r16=[r15],8*/
0x01, 0x08, 0x00, 0x84, /* mov r14=r1;; */
0x11, 0x08, 0x00, 0x1e, 0x18, 0x10, /* [MIB] ld8 r1=[r15] */
0x60, 0x80, 0x04, 0x80, 0x03, 0x00, /* mov b6=r16 */
@@ -643,22 +644,14 @@ static const bfd_byte plt_full_entry[PLT_FULL_ENTRY_SIZE] =
};
#define ELF_DYNAMIC_INTERPRETER "/usr/lib/ld.so.1"
-#define AIX_DYNAMIC_INTERPRETER "/usr/lib/ia64l64/libc.so.1"
-#define DYNAMIC_INTERPRETER(abfd) \
- (elfNN_ia64_aix_vec (abfd->xvec) ? AIX_DYNAMIC_INTERPRETER : ELF_DYNAMIC_INTERPRETER)
-/* Select out of range branch fixup type. Note that Itanium does
- not support brl, and so it gets emulated by the kernel. */
-#undef USE_BRL
-
-#ifdef USE_BRL
static const bfd_byte oor_brl[16] =
{
0x05, 0x00, 0x00, 0x00, 0x01, 0x00, /* [MLX] nop.m 0 */
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, /* brl.sptk.few tgt;; */
0x00, 0x00, 0x00, 0xc0
};
-#else
+
static const bfd_byte oor_ip[48] =
{
0x04, 0x00, 0x00, 0x00, 0x01, 0x00, /* [MLX] nop.m 0 */
@@ -671,19 +664,54 @@ static const bfd_byte oor_ip[48] =
0x60, 0x80, 0x04, 0x80, 0x03, 0x00, /* mov b6=r16 */
0x60, 0x00, 0x80, 0x00 /* br b6;; */
};
-#endif
-
-/* These functions do relaxation for IA-64 ELF.
- This is primarily to support branches to targets out of range;
- relaxation of R_IA64_LTOFF22X and R_IA64_LDXMOV not yet supported. */
+static size_t oor_branch_size = sizeof (oor_brl);
+
+void
+bfd_elfNN_ia64_after_parse (int itanium)
+{
+ oor_branch_size = itanium ? sizeof (oor_ip) : sizeof (oor_brl);
+}
-static boolean
+static void
+elfNN_ia64_relax_brl (bfd *abfd, bfd_byte *contents, bfd_vma off)
+{
+ int template;
+ bfd_byte *hit_addr;
+ bfd_vma t0, t1, i0, i1, i2;
+
+ hit_addr = (bfd_byte *) (contents + off);
+ hit_addr -= (long) hit_addr & 0x3;
+ t0 = bfd_get_64 (abfd, hit_addr);
+ t1 = bfd_get_64 (abfd, hit_addr + 8);
+
+ /* Keep the instruction in slot 0. */
+ i0 = (t0 >> 5) & 0x1ffffffffffLL;
+ /* Use nop.b for slot 1. */
+ i1 = 0x4000000000LL;
+ /* For slot 2, turn brl into br by masking out bit 40. */
+ i2 = (t1 >> 23) & 0x0ffffffffffLL;
+
+ /* Turn a MLX bundle into a MBB bundle with the same stop-bit
+ variety. */
+ template = 0x12;
+ if ((t0 & 0x1fLL) == 5)
+ template += 1;
+ t0 = (i1 << 46) | (i0 << 5) | template;
+ t1 = (i2 << 23) | (i1 >> 18);
+
+ bfd_put_64 (abfd, t0, hit_addr);
+ bfd_put_64 (abfd, t1, hit_addr + 8);
+}
+
+/* These functions do relaxation for IA-64 ELF. */
+
+static bfd_boolean
elfNN_ia64_relax_section (abfd, sec, link_info, again)
bfd *abfd;
asection *sec;
struct bfd_link_info *link_info;
- boolean *again;
+ bfd_boolean *again;
{
struct one_fixup
{
@@ -700,17 +728,26 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
Elf_Internal_Sym *isymbuf = NULL;
struct elfNN_ia64_link_hash_table *ia64_info;
struct one_fixup *fixups = NULL;
- boolean changed_contents = false;
- boolean changed_relocs = false;
+ bfd_boolean changed_contents = FALSE;
+ bfd_boolean changed_relocs = FALSE;
+ bfd_boolean changed_got = FALSE;
+ bfd_vma gp = 0;
/* Assume we're not going to change any sizes, and we'll only need
one pass. */
- *again = false;
+ *again = FALSE;
- /* Nothing to do if there are no relocations. */
+ /* Don't even try to relax for non-ELF outputs. */
+ if (!is_elf_hash_table (link_info->hash))
+ return FALSE;
+
+ /* Nothing to do if there are no relocations or there is no need for
+ the relax finalize pass. */
if ((sec->flags & SEC_RELOC) == 0
- || sec->reloc_count == 0)
- return true;
+ || sec->reloc_count == 0
+ || (!link_info->need_relax_finalize
+ && sec->need_finalize_relax == 0))
+ return TRUE;
/* If this is the first time we have been called for this section,
initialize the cooked size. */
@@ -720,27 +757,15 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
/* Load the relocations for this section. */
- internal_relocs = (_bfd_elfNN_link_read_relocs
+ internal_relocs = (_bfd_elf_link_read_relocs
(abfd, sec, (PTR) NULL, (Elf_Internal_Rela *) NULL,
link_info->keep_memory));
if (internal_relocs == NULL)
- return false;
+ return FALSE;
ia64_info = elfNN_ia64_hash_table (link_info);
irelend = internal_relocs + sec->reloc_count;
- for (irel = internal_relocs; irel < irelend; irel++)
- if (ELFNN_R_TYPE (irel->r_info) == (int) R_IA64_PCREL21B)
- break;
-
- /* No branch-type relocations. */
- if (irel == irelend)
- {
- if (elf_section_data (sec)->relocs != internal_relocs)
- free (internal_relocs);
- return true;
- }
-
/* Get the section contents. */
if (elf_section_data (sec)->this_hdr.contents != NULL)
contents = elf_section_data (sec)->this_hdr.contents;
@@ -755,15 +780,57 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
goto error_return;
}
- for (; irel < irelend; irel++)
+ for (irel = internal_relocs; irel < irelend; irel++)
{
+ unsigned long r_type = ELFNN_R_TYPE (irel->r_info);
bfd_vma symaddr, reladdr, trampoff, toff, roff;
asection *tsec;
struct one_fixup *f;
bfd_size_type amt;
+ bfd_boolean is_branch;
+ struct elfNN_ia64_dyn_sym_info *dyn_i;
- if (ELFNN_R_TYPE (irel->r_info) != (int) R_IA64_PCREL21B)
- continue;
+ switch (r_type)
+ {
+ case R_IA64_PCREL21B:
+ case R_IA64_PCREL21BI:
+ case R_IA64_PCREL21M:
+ case R_IA64_PCREL21F:
+ /* In the finalize pass, all br relaxations are done. We can
+ skip it. */
+ if (!link_info->need_relax_finalize)
+ continue;
+ is_branch = TRUE;
+ break;
+
+ case R_IA64_PCREL60B:
+ /* We can't optimize brl to br before the finalize pass since
+ br relaxations will increase the code size. Defer it to
+ the finalize pass. */
+ if (link_info->need_relax_finalize)
+ {
+ sec->need_finalize_relax = 1;
+ continue;
+ }
+ is_branch = TRUE;
+ break;
+
+ case R_IA64_LTOFF22X:
+ case R_IA64_LDXMOV:
+ /* We can't relax ldx/mov before the finalize pass since
+ br relaxations will increase the code size. Defer it to
+ the finalize pass. */
+ if (link_info->need_relax_finalize)
+ {
+ sec->need_finalize_relax = 1;
+ continue;
+ }
+ is_branch = FALSE;
+ break;
+
+ default:
+ continue;
+ }
/* Get the value of the symbol referred to by the reloc. */
if (ELFNN_R_SYM (irel->r_info) < symtab_hdr->sh_info)
@@ -783,9 +850,9 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
goto error_return;
}
- isym = isymbuf + ELF64_R_SYM (irel->r_info);
+ isym = isymbuf + ELFNN_R_SYM (irel->r_info);
if (isym->st_shndx == SHN_UNDEF)
- continue; /* We can't do anthing with undefined symbols. */
+ continue; /* We can't do anything with undefined symbols. */
else if (isym->st_shndx == SHN_ABS)
tsec = bfd_abs_section_ptr;
else if (isym->st_shndx == SHN_COMMON)
@@ -796,12 +863,12 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
tsec = bfd_section_from_elf_index (abfd, isym->st_shndx);
toff = isym->st_value;
+ dyn_i = get_dyn_sym_info (ia64_info, NULL, abfd, irel, FALSE);
}
else
{
unsigned long indx;
struct elf_link_hash_entry *h;
- struct elfNN_ia64_dyn_sym_info *dyn_i;
indx = ELFNN_R_SYM (irel->r_info) - symtab_hdr->sh_info;
h = elf_sym_hashes (abfd)[indx];
@@ -811,18 +878,29 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
|| h->root.type == bfd_link_hash_warning)
h = (struct elf_link_hash_entry *) h->root.u.i.link;
- dyn_i = get_dyn_sym_info (ia64_info, h, abfd, irel, false);
+ dyn_i = get_dyn_sym_info (ia64_info, h, abfd, irel, FALSE);
/* For branches to dynamic symbols, we're interested instead
in a branch to the PLT entry. */
- if (dyn_i && dyn_i->want_plt2)
+ if (is_branch && dyn_i && dyn_i->want_plt2)
{
+ /* Internal branches shouldn't be sent to the PLT.
+ Leave this for now and we'll give an error later. */
+ if (r_type != R_IA64_PCREL21B)
+ continue;
+
tsec = ia64_info->plt_sec;
toff = dyn_i->plt2_offset;
+ BFD_ASSERT (irel->r_addend == 0);
}
+
+ /* Can't do anything else with dynamic symbols. */
+ else if (elfNN_ia64_dynamic_symbol_p (h, link_info, r_type))
+ continue;
+
else
{
- /* We can't do anthing with undefined symbols. */
+ /* We can't do anything with undefined symbols. */
if (h->root.type == bfd_link_hash_undefined
|| h->root.type == bfd_link_hash_undefweak)
continue;
@@ -832,109 +910,193 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
}
}
- symaddr = (tsec->output_section->vma
- + tsec->output_offset
- + toff
- + irel->r_addend);
+ if (tsec->sec_info_type == ELF_INFO_TYPE_MERGE)
+ toff = _bfd_merged_section_offset (abfd, &tsec,
+ elf_section_data (tsec)->sec_info,
+ toff + irel->r_addend,
+ (bfd_vma) 0);
+ else
+ toff += irel->r_addend;
+
+ symaddr = tsec->output_section->vma + tsec->output_offset + toff;
roff = irel->r_offset;
- reladdr = (sec->output_section->vma
- + sec->output_offset
- + roff) & (bfd_vma) -4;
- /* If the branch is in range, no need to do anything. */
- if ((bfd_signed_vma) (symaddr - reladdr) >= -0x1000000
- && (bfd_signed_vma) (symaddr - reladdr) <= 0x0FFFFF0)
- continue;
+ if (is_branch)
+ {
+ bfd_signed_vma offset;
- /* If the branch and target are in the same section, you've
- got one honking big section and we can't help you. You'll
- get an error message later. */
- if (tsec == sec)
- continue;
+ reladdr = (sec->output_section->vma
+ + sec->output_offset
+ + roff) & (bfd_vma) -4;
- /* Look for an existing fixup to this address. */
- for (f = fixups; f ; f = f->next)
- if (f->tsec == tsec && f->toff == toff)
- break;
+ /* If the branch is in range, no need to do anything. */
+ if ((bfd_signed_vma) (symaddr - reladdr) >= -0x1000000
+ && (bfd_signed_vma) (symaddr - reladdr) <= 0x0FFFFF0)
+ {
+ /* If the 60-bit branch is in 21-bit range, optimize it. */
+ if (r_type == R_IA64_PCREL60B)
+ {
+ elfNN_ia64_relax_brl (abfd, contents, roff);
- if (f == NULL)
- {
- /* Two alternatives: If it's a branch to a PLT entry, we can
- make a copy of the FULL_PLT entry. Otherwise, we'll have
- to use a `brl' insn to get where we're going. */
+ irel->r_info
+ = ELF64_R_INFO (ELF64_R_SYM (irel->r_info),
+ R_IA64_PCREL21B);
- size_t size;
+ /* If the original relocation offset points to slot
+ 1, change it to slot 2. */
+ if ((irel->r_offset & 3) == 1)
+ irel->r_offset += 1;
+ }
- if (tsec == ia64_info->plt_sec)
- size = sizeof (plt_full_entry);
- else
- {
-#ifdef USE_BRL
- size = sizeof (oor_brl);
-#else
- size = sizeof (oor_ip);
-#endif
+ continue;
}
+ else if (r_type == R_IA64_PCREL60B)
+ continue;
- /* Resize the current section to make room for the new branch. */
- trampoff = (sec->_cooked_size + 15) & (bfd_vma) -16;
- amt = trampoff + size;
- contents = (bfd_byte *) bfd_realloc (contents, amt);
- if (contents == NULL)
- goto error_return;
- sec->_cooked_size = amt;
+ /* If the branch and target are in the same section, you've
+ got one honking big section and we can't help you. You'll
+ get an error message later. */
+ if (tsec == sec)
+ continue;
+
+ /* Look for an existing fixup to this address. */
+ for (f = fixups; f ; f = f->next)
+ if (f->tsec == tsec && f->toff == toff)
+ break;
- if (tsec == ia64_info->plt_sec)
+ if (f == NULL)
{
- memcpy (contents + trampoff, plt_full_entry, size);
+ /* Two alternatives: If it's a branch to a PLT entry, we can
+ make a copy of the FULL_PLT entry. Otherwise, we'll have
+ to use a `brl' insn to get where we're going. */
- /* Hijack the old relocation for use as the PLTOFF reloc. */
- irel->r_info = ELFNN_R_INFO (ELFNN_R_SYM (irel->r_info),
- R_IA64_PLTOFF22);
- irel->r_offset = trampoff;
+ size_t size;
+
+ if (tsec == ia64_info->plt_sec)
+ size = sizeof (plt_full_entry);
+ else
+ size = oor_branch_size;
+
+ /* Resize the current section to make room for the new branch. */
+ trampoff = (sec->_cooked_size + 15) & (bfd_vma) -16;
+
+ /* If trampoline is out of range, there is nothing we
+ can do. */
+ offset = trampoff - (roff & (bfd_vma) -4);
+ if (offset < -0x1000000 || offset > 0x0FFFFF0)
+ continue;
+
+ amt = trampoff + size;
+ contents = (bfd_byte *) bfd_realloc (contents, amt);
+ if (contents == NULL)
+ goto error_return;
+ sec->_cooked_size = amt;
+
+ if (tsec == ia64_info->plt_sec)
+ {
+ memcpy (contents + trampoff, plt_full_entry, size);
+
+ /* Hijack the old relocation for use as the PLTOFF reloc. */
+ irel->r_info = ELFNN_R_INFO (ELFNN_R_SYM (irel->r_info),
+ R_IA64_PLTOFF22);
+ irel->r_offset = trampoff;
+ }
+ else
+ {
+ if (size == sizeof (oor_ip))
+ {
+ memcpy (contents + trampoff, oor_ip, size);
+ irel->r_info = ELFNN_R_INFO (ELFNN_R_SYM (irel->r_info),
+ R_IA64_PCREL64I);
+ irel->r_addend -= 16;
+ irel->r_offset = trampoff + 2;
+ }
+ else
+ {
+ memcpy (contents + trampoff, oor_brl, size);
+ irel->r_info = ELFNN_R_INFO (ELFNN_R_SYM (irel->r_info),
+ R_IA64_PCREL60B);
+ irel->r_offset = trampoff + 2;
+ }
+
+ }
+
+ /* Record the fixup so we don't do it again this section. */
+ f = (struct one_fixup *)
+ bfd_malloc ((bfd_size_type) sizeof (*f));
+ f->next = fixups;
+ f->tsec = tsec;
+ f->toff = toff;
+ f->trampoff = trampoff;
+ fixups = f;
}
else
{
-#ifdef USE_BRL
- memcpy (contents + trampoff, oor_brl, size);
- irel->r_info = ELFNN_R_INFO (ELFNN_R_SYM (irel->r_info),
- R_IA64_PCREL60B);
- irel->r_offset = trampoff + 2;
-#else
- memcpy (contents + trampoff, oor_ip, size);
- irel->r_info = ELFNN_R_INFO (ELFNN_R_SYM (irel->r_info),
- R_IA64_PCREL64I);
- irel->r_addend -= 16;
- irel->r_offset = trampoff + 2;
-#endif
+ /* If trampoline is out of range, there is nothing we
+ can do. */
+ offset = f->trampoff - (roff & (bfd_vma) -4);
+ if (offset < -0x1000000 || offset > 0x0FFFFF0)
+ continue;
+
+ /* Nop out the reloc, since we're finalizing things here. */
+ irel->r_info = ELFNN_R_INFO (0, R_IA64_NONE);
}
- /* Record the fixup so we don't do it again this section. */
- f = (struct one_fixup *) bfd_malloc ((bfd_size_type) sizeof (*f));
- f->next = fixups;
- f->tsec = tsec;
- f->toff = toff;
- f->trampoff = trampoff;
- fixups = f;
+ /* Fix up the existing branch to hit the trampoline. */
+ if (elfNN_ia64_install_value (abfd, contents + roff, offset,
+ r_type) != bfd_reloc_ok)
+ goto error_return;
+
+ changed_contents = TRUE;
+ changed_relocs = TRUE;
}
else
{
- /* Nop out the reloc, since we're finalizing things here. */
- irel->r_info = ELFNN_R_INFO (0, R_IA64_NONE);
- }
+ /* Fetch the gp. */
+ if (gp == 0)
+ {
+ bfd *obfd = sec->output_section->owner;
+ gp = _bfd_get_gp_value (obfd);
+ if (gp == 0)
+ {
+ if (!elfNN_ia64_choose_gp (obfd, link_info))
+ goto error_return;
+ gp = _bfd_get_gp_value (obfd);
+ }
+ }
- /* Fix up the existing branch to hit the trampoline. Hope like
- hell this doesn't overflow too. */
- if (elfNN_ia64_install_value (abfd, contents + roff,
- f->trampoff - (roff & (bfd_vma) -4),
- R_IA64_PCREL21B) != bfd_reloc_ok)
- goto error_return;
+ /* If the data is out of range, do nothing. */
+ if ((bfd_signed_vma) (symaddr - gp) >= 0x200000
+ ||(bfd_signed_vma) (symaddr - gp) < -0x200000)
+ continue;
- changed_contents = true;
- changed_relocs = true;
+ if (r_type == R_IA64_LTOFF22X)
+ {
+ irel->r_info = ELFNN_R_INFO (ELFNN_R_SYM (irel->r_info),
+ R_IA64_GPREL22);
+ changed_relocs = TRUE;
+ if (dyn_i->want_gotx)
+ {
+ dyn_i->want_gotx = 0;
+ changed_got |= !dyn_i->want_got;
+ }
+ }
+ else
+ {
+ elfNN_ia64_relax_ldxmov (abfd, contents, roff);
+ irel->r_info = ELFNN_R_INFO (0, R_IA64_NONE);
+ changed_contents = TRUE;
+ changed_relocs = TRUE;
+ }
+ }
}
+ /* ??? If we created fixups, this may push the code segment large
+ enough that the data segment moves, which will change the GP.
+ Reset the GP so that we re-calculate next round. We need to
+ do this at the _beginning_ of the next round; now will not do. */
+
/* Clean up and go home. */
while (fixups)
{
@@ -975,8 +1137,27 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
elf_section_data (sec)->relocs = internal_relocs;
}
+ if (changed_got)
+ {
+ struct elfNN_ia64_allocate_data data;
+ data.info = link_info;
+ data.ofs = 0;
+ ia64_info->self_dtpmod_offset = (bfd_vma) -1;
+
+ elfNN_ia64_dyn_sym_traverse (ia64_info, allocate_global_data_got, &data);
+ elfNN_ia64_dyn_sym_traverse (ia64_info, allocate_global_fptr_got, &data);
+ elfNN_ia64_dyn_sym_traverse (ia64_info, allocate_local_got, &data);
+ ia64_info->got_sec->_raw_size = data.ofs;
+ ia64_info->got_sec->_cooked_size = data.ofs;
+
+ /* ??? Resize .rela.got too. */
+ }
+
+ if (!link_info->need_relax_finalize)
+ sec->need_finalize_relax = 0;
+
*again = changed_contents || changed_relocs;
- return true;
+ return TRUE;
error_return:
if (isymbuf != NULL && (unsigned char *) isymbuf != symtab_hdr->contents)
@@ -987,12 +1168,45 @@ elfNN_ia64_relax_section (abfd, sec, link_info, again)
if (internal_relocs != NULL
&& elf_section_data (sec)->relocs != internal_relocs)
free (internal_relocs);
- return false;
+ return FALSE;
+}
+
+static void
+elfNN_ia64_relax_ldxmov (abfd, contents, off)
+ bfd *abfd;
+ bfd_byte *contents;
+ bfd_vma off;
+{
+ int shift, r1, r3;
+ bfd_vma dword, insn;
+
+ switch ((int)off & 0x3)
+ {
+ case 0: shift = 5; break;
+ case 1: shift = 14; off += 3; break;
+ case 2: shift = 23; off += 6; break;
+ default:
+ abort ();
+ }
+
+ dword = bfd_get_64 (abfd, contents + off);
+ insn = (dword >> shift) & 0x1ffffffffffLL;
+
+ r1 = (insn >> 6) & 127;
+ r3 = (insn >> 20) & 127;
+ if (r1 == r3)
+ insn = 0x8000000; /* nop */
+ else
+ insn = (insn & 0x7f01fff) | 0x10800000000LL; /* (qp) mov r1 = r3 */
+
+ dword &= ~(0x1ffffffffffLL << shift);
+ dword |= (insn << shift);
+ bfd_put_64 (abfd, dword, contents + off);
}
-/* Return true if NAME is an unwind table section name. */
+/* Return TRUE if NAME is an unwind table section name. */
-static inline boolean
+static inline bfd_boolean
is_unwind_section_name (abfd, name)
bfd *abfd;
const char *name;
@@ -1001,7 +1215,7 @@ is_unwind_section_name (abfd, name)
if (elfNN_ia64_hpux_vec (abfd->xvec)
&& !strcmp (name, ELF_STRING_ia64_unwind_hdr))
- return false;
+ return FALSE;
len1 = sizeof (ELF_STRING_ia64_unwind) - 1;
len2 = sizeof (ELF_STRING_ia64_unwind_info) - 1;
@@ -1014,10 +1228,10 @@ is_unwind_section_name (abfd, name)
/* Handle an IA-64 specific section when reading an object file. This
is called when elfcode.h finds a section with an unknown type. */
-static boolean
+static bfd_boolean
elfNN_ia64_section_from_shdr (abfd, hdr, name)
bfd *abfd;
- ElfNN_Internal_Shdr *hdr;
+ Elf_Internal_Shdr *hdr;
const char *name;
{
asection *newsect;
@@ -1035,18 +1249,18 @@ elfNN_ia64_section_from_shdr (abfd, hdr, name)
case SHT_IA_64_EXT:
if (strcmp (name, ELF_STRING_ia64_archext) != 0)
- return false;
+ return FALSE;
break;
default:
- return false;
+ return FALSE;
}
if (! _bfd_elf_make_section_from_shdr (abfd, hdr, name))
- return false;
+ return FALSE;
newsect = hdr->bfd_section;
- return true;
+ return TRUE;
}
/* Convert IA-64 specific section flags to bfd internal section flags. */
@@ -1054,24 +1268,24 @@ elfNN_ia64_section_from_shdr (abfd, hdr, name)
/* ??? There is no bfd internal flag equivalent to the SHF_IA_64_NORECOV
flag. */
-static boolean
+static bfd_boolean
elfNN_ia64_section_flags (flags, hdr)
flagword *flags;
- ElfNN_Internal_Shdr *hdr;
+ Elf_Internal_Shdr *hdr;
{
if (hdr->sh_flags & SHF_IA_64_SHORT)
*flags |= SEC_SMALL_DATA;
- return true;
+ return TRUE;
}
/* Set the correct type for an IA-64 ELF section. We do this by the
section name, which is a hack, but ought to work. */
-static boolean
+static bfd_boolean
elfNN_ia64_fake_sections (abfd, hdr, sec)
bfd *abfd ATTRIBUTE_UNUSED;
- ElfNN_Internal_Shdr *hdr;
+ Elf_Internal_Shdr *hdr;
asection *sec;
{
register const char *name;
@@ -1090,30 +1304,28 @@ elfNN_ia64_fake_sections (abfd, hdr, sec)
else if (strcmp (name, ".HP.opt_annot") == 0)
hdr->sh_type = SHT_IA_64_HP_OPT_ANOT;
else if (strcmp (name, ".reloc") == 0)
- /*
- * This is an ugly, but unfortunately necessary hack that is
- * needed when producing EFI binaries on IA-64. It tells
- * elf.c:elf_fake_sections() not to consider ".reloc" as a section
- * containing ELF relocation info. We need this hack in order to
- * be able to generate ELF binaries that can be translated into
- * EFI applications (which are essentially COFF objects). Those
- * files contain a COFF ".reloc" section inside an ELFNN object,
- * which would normally cause BFD to segfault because it would
- * attempt to interpret this section as containing relocation
- * entries for section "oc". With this hack enabled, ".reloc"
- * will be treated as a normal data section, which will avoid the
- * segfault. However, you won't be able to create an ELFNN binary
- * with a section named "oc" that needs relocations, but that's
- * the kind of ugly side-effects you get when detecting section
- * types based on their names... In practice, this limitation is
- * unlikely to bite.
- */
+ /* This is an ugly, but unfortunately necessary hack that is
+ needed when producing EFI binaries on IA-64. It tells
+ elf.c:elf_fake_sections() not to consider ".reloc" as a section
+ containing ELF relocation info. We need this hack in order to
+ be able to generate ELF binaries that can be translated into
+ EFI applications (which are essentially COFF objects). Those
+ files contain a COFF ".reloc" section inside an ELFNN object,
+ which would normally cause BFD to segfault because it would
+ attempt to interpret this section as containing relocation
+ entries for section "oc". With this hack enabled, ".reloc"
+ will be treated as a normal data section, which will avoid the
+ segfault. However, you won't be able to create an ELFNN binary
+ with a section named "oc" that needs relocations, but that's
+ the kind of ugly side-effects you get when detecting section
+ types based on their names... In practice, this limitation is
+ unlikely to bite. */
hdr->sh_type = SHT_PROGBITS;
if (sec->flags & SEC_SMALL_DATA)
hdr->sh_flags |= SHF_IA_64_SHORT;
- return true;
+ return TRUE;
}
/* The final processing done just before writing out an IA-64 ELF
@@ -1122,7 +1334,7 @@ elfNN_ia64_fake_sections (abfd, hdr, sec)
static void
elfNN_ia64_final_write_processing (abfd, linker)
bfd *abfd;
- boolean linker ATTRIBUTE_UNUSED;
+ bfd_boolean linker ATTRIBUTE_UNUSED;
{
Elf_Internal_Shdr *hdr;
const char *sname;
@@ -1196,23 +1408,36 @@ elfNN_ia64_final_write_processing (abfd, linker)
break;
}
}
+
+ if (! elf_flags_init (abfd))
+ {
+ unsigned long flags = 0;
+
+ if (abfd->xvec->byteorder == BFD_ENDIAN_BIG)
+ flags |= EF_IA_64_BE;
+ if (bfd_get_mach (abfd) == bfd_mach_ia64_elf64)
+ flags |= EF_IA_64_ABI64;
+
+ elf_elfheader(abfd)->e_flags = flags;
+ elf_flags_init (abfd) = TRUE;
+ }
}
/* Hook called by the linker routine which adds symbols from an object
file. We use it to put .comm items in .sbss, and not .bss. */
-static boolean
+static bfd_boolean
elfNN_ia64_add_symbol_hook (abfd, info, sym, namep, flagsp, secp, valp)
bfd *abfd;
struct bfd_link_info *info;
- const Elf_Internal_Sym *sym;
+ Elf_Internal_Sym *sym;
const char **namep ATTRIBUTE_UNUSED;
flagword *flagsp ATTRIBUTE_UNUSED;
asection **secp;
bfd_vma *valp;
{
if (sym->st_shndx == SHN_COMMON
- && !info->relocateable
+ && !info->relocatable
&& sym->st_size <= elf_gp_size (abfd))
{
/* Common symbols less than or equal to -G nn bytes are
@@ -1227,122 +1452,14 @@ elfNN_ia64_add_symbol_hook (abfd, info, sym, namep, flagsp, secp, valp)
|| !bfd_set_section_flags (abfd, scomm, (SEC_ALLOC
| SEC_IS_COMMON
| SEC_LINKER_CREATED)))
- return false;
+ return FALSE;
}
*secp = scomm;
*valp = sym->st_size;
}
- return true;
-}
-
-static boolean
-elfNN_ia64_aix_vec (const bfd_target *vec)
-{
- extern const bfd_target bfd_elfNN_ia64_aix_little_vec;
- extern const bfd_target bfd_elfNN_ia64_aix_big_vec;
-
- return (/**/vec == & bfd_elfNN_ia64_aix_little_vec
- || vec == & bfd_elfNN_ia64_aix_big_vec);
-}
-
-/* Hook called by the linker routine which adds symbols from an object
- file. We use it to handle OS-specific symbols. */
-
-static boolean
-elfNN_ia64_aix_add_symbol_hook (abfd, info, sym, namep, flagsp, secp, valp)
- bfd *abfd;
- struct bfd_link_info *info;
- const Elf_Internal_Sym *sym;
- const char **namep;
- flagword *flagsp;
- asection **secp;
- bfd_vma *valp;
-{
- if (strcmp (*namep, "__GLOB_DATA_PTR") == 0)
- {
- /* Define __GLOB_DATA_PTR when it is encountered. This is expected to
- be a linker-defined symbol by the Aix C runtime startup code. IBM sez
- no one else should use it b/c it is undocumented. */
- struct elf_link_hash_entry *h;
-
- h = elf_link_hash_lookup (elf_hash_table (info), *namep,
- false, false, false);
- if (h == NULL)
- {
- struct elf_backend_data *bed;
- struct elfNN_ia64_link_hash_table *ia64_info;
- struct bfd_link_hash_entry *bh = NULL;
-
- bed = get_elf_backend_data (abfd);
- ia64_info = elfNN_ia64_hash_table (info);
-
- if (!(_bfd_generic_link_add_one_symbol
- (info, abfd, *namep, BSF_GLOBAL,
- bfd_get_section_by_name (abfd, ".bss"),
- bed->got_symbol_offset, (const char *) NULL, false,
- bed->collect, &bh)))
- return false;
-
- h = (struct elf_link_hash_entry *) bh;
- h->elf_link_hash_flags |= ELF_LINK_HASH_DEF_REGULAR;
- h->type = STT_OBJECT;
-
- if (! _bfd_elf_link_record_dynamic_symbol (info, h))
- return false;
- }
-
- return true;
- }
- else if (sym->st_shndx == SHN_LOOS)
- {
- unsigned int i;
-
- /* SHN_AIX_SYSCALL: Treat this as any other symbol. The special symbol
- is only relevant when compiling code for extended system calls.
- Replace the "special" section with .text, if possible.
- Note that these symbols are always assumed to be in .text. */
- for (i = 1; i < elf_numsections (abfd); i++)
- {
- asection * sec = bfd_section_from_elf_index (abfd, i);
-
- if (sec && strcmp (sec->name, ".text") == 0)
- {
- *secp = sec;
- break;
- }
- }
-
- if (*secp == NULL)
- *secp = bfd_abs_section_ptr;
-
- *valp = sym->st_size;
-
- return true;
- }
- else
- {
- return elfNN_ia64_add_symbol_hook (abfd, info, sym,
- namep, flagsp, secp, valp);
- }
-}
-
-boolean
-elfNN_ia64_aix_link_add_symbols (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info;
-{
- /* Make sure dynamic sections are always created. */
- if (! elf_hash_table (info)->dynamic_sections_created
- && abfd->xvec == info->hash->creator)
- {
- if (! bfd_elfNN_link_create_dynamic_sections (abfd, info))
- return false;
- }
-
- /* Now do the standard call. */
- return bfd_elfNN_bfd_link_add_symbols (abfd, info);
+ return TRUE;
}
/* Return the number of additional phdrs we will need. */
@@ -1367,9 +1484,10 @@ elfNN_ia64_additional_program_headers (abfd)
return ret;
}
-static boolean
-elfNN_ia64_modify_segment_map (abfd)
+static bfd_boolean
+elfNN_ia64_modify_segment_map (abfd, info)
bfd *abfd;
+ struct bfd_link_info *info ATTRIBUTE_UNUSED;
{
struct elf_segment_map *m, **pm;
Elf_Internal_Shdr *hdr;
@@ -1388,7 +1506,7 @@ elfNN_ia64_modify_segment_map (abfd)
m = ((struct elf_segment_map *)
bfd_zalloc (abfd, (bfd_size_type) sizeof *m));
if (m == NULL)
- return false;
+ return FALSE;
m->p_type = PT_IA_64_ARCHEXT;
m->count = 1;
@@ -1436,7 +1554,7 @@ elfNN_ia64_modify_segment_map (abfd)
m = ((struct elf_segment_map *)
bfd_zalloc (abfd, (bfd_size_type) sizeof *m));
if (m == NULL)
- return false;
+ return FALSE;
m->p_type = PT_IA_64_UNWIND;
m->count = 1;
@@ -1480,13 +1598,13 @@ elfNN_ia64_modify_segment_map (abfd)
found:;
}
- return true;
+ return TRUE;
}
/* According to the Tahoe assembler spec, all labels starting with a
'.' are local. */
-static boolean
+static bfd_boolean
elfNN_ia64_is_local_label_name (abfd, name)
bfd *abfd ATTRIBUTE_UNUSED;
const char *name;
@@ -1496,78 +1614,19 @@ elfNN_ia64_is_local_label_name (abfd, name)
/* Should we do dynamic things to this symbol? */
-static boolean
-elfNN_ia64_dynamic_symbol_p (h, info)
+static bfd_boolean
+elfNN_ia64_dynamic_symbol_p (h, info, r_type)
struct elf_link_hash_entry *h;
struct bfd_link_info *info;
+ int r_type;
{
- if (h == NULL)
- return false;
-
- while (h->root.type == bfd_link_hash_indirect
- || h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
-
- if (h->dynindx == -1)
- return false;
- switch (ELF_ST_VISIBILITY (h->other))
- {
- case STV_INTERNAL:
- case STV_HIDDEN:
- return false;
- }
+ bfd_boolean ignore_protected
+ = ((r_type & 0xf8) == 0x40 /* FPTR relocs */
+ || (r_type & 0xf8) == 0x50); /* LTOFF_FPTR relocs */
- if (h->root.type == bfd_link_hash_undefweak
- || h->root.type == bfd_link_hash_defweak)
- return true;
-
- if ((info->shared && (!info->symbolic || info->allow_shlib_undefined))
- || ((h->elf_link_hash_flags
- & (ELF_LINK_HASH_DEF_DYNAMIC | ELF_LINK_HASH_REF_REGULAR))
- == (ELF_LINK_HASH_DEF_DYNAMIC | ELF_LINK_HASH_REF_REGULAR)))
- return true;
-
- return false;
+ return _bfd_elf_dynamic_symbol_p (h, info, ignore_protected);
}
-static boolean
-elfNN_ia64_local_hash_table_init (ht, abfd, new)
- struct elfNN_ia64_local_hash_table *ht;
- bfd *abfd ATTRIBUTE_UNUSED;
- new_hash_entry_func new;
-{
- memset (ht, 0, sizeof (*ht));
- return bfd_hash_table_init (&ht->root, new);
-}
-
-static struct bfd_hash_entry*
-elfNN_ia64_new_loc_hash_entry (entry, table, string)
- struct bfd_hash_entry *entry;
- struct bfd_hash_table *table;
- const char *string;
-{
- struct elfNN_ia64_local_hash_entry *ret;
- ret = (struct elfNN_ia64_local_hash_entry *) entry;
-
- /* Allocate the structure if it has not already been allocated by a
- subclass. */
- if (!ret)
- ret = bfd_hash_allocate (table, sizeof (*ret));
-
- if (!ret)
- return 0;
-
- /* Initialize our local data. All zeros, and definitely easier
- than setting a handful of bit fields. */
- memset (ret, 0, sizeof (*ret));
-
- /* Call the allocation method of the superclass. */
- ret = ((struct elfNN_ia64_local_hash_entry *)
- bfd_hash_newfunc ((struct bfd_hash_entry *) ret, table, string));
-
- return (struct bfd_hash_entry *) ret;
-}
-
static struct bfd_hash_entry*
elfNN_ia64_new_elf_hash_entry (entry, table, string)
struct bfd_hash_entry *entry;
@@ -1599,7 +1658,7 @@ elfNN_ia64_new_elf_hash_entry (entry, table, string)
static void
elfNN_ia64_hash_copy_indirect (bed, xdir, xind)
- struct elf_backend_data *bed ATTRIBUTE_UNUSED;
+ const struct elf_backend_data *bed ATTRIBUTE_UNUSED;
struct elf_link_hash_entry *xdir, *xind;
{
struct elfNN_ia64_link_hash_entry *dir, *ind;
@@ -1614,7 +1673,8 @@ elfNN_ia64_hash_copy_indirect (bed, xdir, xind)
(ind->root.elf_link_hash_flags
& (ELF_LINK_HASH_REF_DYNAMIC
| ELF_LINK_HASH_REF_REGULAR
- | ELF_LINK_HASH_REF_REGULAR_NONWEAK));
+ | ELF_LINK_HASH_REF_REGULAR_NONWEAK
+ | ELF_LINK_HASH_NEEDS_PLT));
if (ind->root.root.type != bfd_link_hash_indirect)
return;
@@ -1651,7 +1711,7 @@ static void
elfNN_ia64_hash_hide_symbol (info, xh, force_local)
struct bfd_link_info *info;
struct elf_link_hash_entry *xh;
- boolean force_local;
+ bfd_boolean force_local;
{
struct elfNN_ia64_link_hash_entry *h;
struct elfNN_ia64_dyn_sym_info *dyn_i;
@@ -1661,7 +1721,37 @@ elfNN_ia64_hash_hide_symbol (info, xh, force_local)
_bfd_elf_link_hash_hide_symbol (info, &h->root, force_local);
for (dyn_i = h->info; dyn_i; dyn_i = dyn_i->next)
- dyn_i->want_plt2 = 0;
+ {
+ dyn_i->want_plt2 = 0;
+ dyn_i->want_plt = 0;
+ }
+}
+
+/* Compute a hash of a local hash entry. */
+
+static hashval_t
+elfNN_ia64_local_htab_hash (ptr)
+ const void *ptr;
+{
+ struct elfNN_ia64_local_hash_entry *entry
+ = (struct elfNN_ia64_local_hash_entry *) ptr;
+
+ return (((entry->id & 0xff) << 24) | ((entry->id & 0xff00) << 8))
+ ^ entry->r_sym ^ (entry->id >> 16);
+}
+
+/* Compare local hash entries. */
+
+static int
+elfNN_ia64_local_htab_eq (ptr1, ptr2)
+ const void *ptr1, *ptr2;
+{
+ struct elfNN_ia64_local_hash_entry *entry1
+ = (struct elfNN_ia64_local_hash_entry *) ptr1;
+ struct elfNN_ia64_local_hash_entry *entry2
+ = (struct elfNN_ia64_local_hash_entry *) ptr2;
+
+ return entry1->id == entry2->id && entry1->r_sym == entry2->r_sym;
}
/* Create the derived linker hash table. The IA-64 ELF port uses this
@@ -1674,43 +1764,53 @@ elfNN_ia64_hash_table_create (abfd)
{
struct elfNN_ia64_link_hash_table *ret;
- ret = bfd_zalloc (abfd, (bfd_size_type) sizeof (*ret));
+ ret = bfd_zmalloc ((bfd_size_type) sizeof (*ret));
if (!ret)
return 0;
+
if (!_bfd_elf_link_hash_table_init (&ret->root, abfd,
elfNN_ia64_new_elf_hash_entry))
{
- bfd_release (abfd, ret);
+ free (ret);
+ return 0;
+ }
+
+ ret->loc_hash_table = htab_try_create (1024, elfNN_ia64_local_htab_hash,
+ elfNN_ia64_local_htab_eq, NULL);
+ ret->loc_hash_memory = objalloc_create ();
+ if (!ret->loc_hash_table || !ret->loc_hash_memory)
+ {
+ free (ret);
return 0;
}
- if (!elfNN_ia64_local_hash_table_init (&ret->loc_hash_table, abfd,
- elfNN_ia64_new_loc_hash_entry))
- return 0;
return &ret->root.root;
}
-/* Look up an entry in a Alpha ELF linker hash table. */
+/* Destroy IA-64 linker hash table. */
-static INLINE struct elfNN_ia64_local_hash_entry *
-elfNN_ia64_local_hash_lookup(table, string, create, copy)
- struct elfNN_ia64_local_hash_table *table;
- const char *string;
- boolean create, copy;
+static void
+elfNN_ia64_hash_table_free (hash)
+ struct bfd_link_hash_table *hash;
{
- return ((struct elfNN_ia64_local_hash_entry *)
- bfd_hash_lookup (&table->root, string, create, copy));
+ struct elfNN_ia64_link_hash_table *ia64_info
+ = (struct elfNN_ia64_link_hash_table *) hash;
+ if (ia64_info->loc_hash_table)
+ htab_delete (ia64_info->loc_hash_table);
+ if (ia64_info->loc_hash_memory)
+ objalloc_free ((struct objalloc *) ia64_info->loc_hash_memory);
+ _bfd_generic_link_hash_table_free (hash);
}
/* Traverse both local and global hash tables. */
struct elfNN_ia64_dyn_sym_traverse_data
{
- boolean (*func) PARAMS ((struct elfNN_ia64_dyn_sym_info *, PTR));
+ bfd_boolean (*func) PARAMS ((struct elfNN_ia64_dyn_sym_info *, PTR));
PTR data;
};
-static boolean
+static bfd_boolean
elfNN_ia64_global_dyn_sym_thunk (xentry, xdata)
struct bfd_hash_entry *xentry;
PTR xdata;
@@ -1726,31 +1826,31 @@ elfNN_ia64_global_dyn_sym_thunk (xentry, xdata)
for (dyn_i = entry->info; dyn_i; dyn_i = dyn_i->next)
if (! (*data->func) (dyn_i, data->data))
- return false;
- return true;
+ return FALSE;
+ return TRUE;
}
-static boolean
-elfNN_ia64_local_dyn_sym_thunk (xentry, xdata)
- struct bfd_hash_entry *xentry;
+static bfd_boolean
+elfNN_ia64_local_dyn_sym_thunk (slot, xdata)
+ void **slot;
PTR xdata;
{
struct elfNN_ia64_local_hash_entry *entry
- = (struct elfNN_ia64_local_hash_entry *) xentry;
+ = (struct elfNN_ia64_local_hash_entry *) *slot;
struct elfNN_ia64_dyn_sym_traverse_data *data
= (struct elfNN_ia64_dyn_sym_traverse_data *) xdata;
struct elfNN_ia64_dyn_sym_info *dyn_i;
for (dyn_i = entry->info; dyn_i; dyn_i = dyn_i->next)
if (! (*data->func) (dyn_i, data->data))
- return false;
- return true;
+ return 0;
+ return 1;
}
static void
elfNN_ia64_dyn_sym_traverse (ia64_info, func, data)
struct elfNN_ia64_link_hash_table *ia64_info;
- boolean (*func) PARAMS ((struct elfNN_ia64_dyn_sym_info *, PTR));
+ bfd_boolean (*func) PARAMS ((struct elfNN_ia64_dyn_sym_info *, PTR));
PTR data;
{
struct elfNN_ia64_dyn_sym_traverse_data xdata;
@@ -1760,11 +1860,11 @@ elfNN_ia64_dyn_sym_traverse (ia64_info, func, data)
elf_link_hash_traverse (&ia64_info->root,
elfNN_ia64_global_dyn_sym_thunk, &xdata);
- bfd_hash_traverse (&ia64_info->loc_hash_table.root,
- elfNN_ia64_local_dyn_sym_thunk, &xdata);
+ htab_traverse (ia64_info->loc_hash_table,
+ elfNN_ia64_local_dyn_sym_thunk, &xdata);
}
-static boolean
+static bfd_boolean
elfNN_ia64_create_dynamic_sections (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -1773,7 +1873,7 @@ elfNN_ia64_create_dynamic_sections (abfd, info)
asection *s;
if (! _bfd_elf_create_dynamic_sections (abfd, info))
- return false;
+ return FALSE;
ia64_info = elfNN_ia64_hash_table (info);
@@ -1783,10 +1883,12 @@ elfNN_ia64_create_dynamic_sections (abfd, info)
{
flagword flags = bfd_get_section_flags (abfd, ia64_info->got_sec);
bfd_set_section_flags (abfd, ia64_info->got_sec, SEC_SMALL_DATA | flags);
+ /* The .got section is always aligned at 8 bytes. */
+ bfd_set_section_alignment (abfd, ia64_info->got_sec, 3);
}
if (!get_pltoff (abfd, info, ia64_info))
- return false;
+ return FALSE;
s = bfd_make_section(abfd, ".rela.IA_64.pltoff");
if (s == NULL
@@ -1796,7 +1898,7 @@ elfNN_ia64_create_dynamic_sections (abfd, info)
| SEC_LINKER_CREATED
| SEC_READONLY))
|| !bfd_set_section_alignment (abfd, s, 3))
- return false;
+ return FALSE;
ia64_info->rel_pltoff_sec = s;
s = bfd_make_section(abfd, ".rela.got");
@@ -1807,10 +1909,10 @@ elfNN_ia64_create_dynamic_sections (abfd, info)
| SEC_LINKER_CREATED
| SEC_READONLY))
|| !bfd_set_section_alignment (abfd, s, 3))
- return false;
+ return FALSE;
ia64_info->rel_got_sec = s;
- return true;
+ return TRUE;
}
/* Find and/or create a hash entry for local symbol. */
@@ -1819,28 +1921,35 @@ get_local_sym_hash (ia64_info, abfd, rel, create)
struct elfNN_ia64_link_hash_table *ia64_info;
bfd *abfd;
const Elf_Internal_Rela *rel;
- boolean create;
+ bfd_boolean create;
{
- char *addr_name;
- size_t len;
- struct elfNN_ia64_local_hash_entry *ret;
-
- /* Construct a string for use in the elfNN_ia64_local_hash_table.
- name describes what was once anonymous memory. */
-
- len = sizeof (void*)*2 + 1 + sizeof (bfd_vma)*4 + 1 + 1;
- len += 10; /* %p slop */
+ struct elfNN_ia64_local_hash_entry e, *ret;
+ asection *sec = abfd->sections;
+ hashval_t h = (((sec->id & 0xff) << 24) | ((sec->id & 0xff00) << 8))
+ ^ ELFNN_R_SYM (rel->r_info) ^ (sec->id >> 16);
+ void **slot;
+
+ e.id = sec->id;
+ e.r_sym = ELFNN_R_SYM (rel->r_info);
+ slot = htab_find_slot_with_hash (ia64_info->loc_hash_table, &e, h,
+ create ? INSERT : NO_INSERT);
+
+ if (!slot)
+ return NULL;
- addr_name = bfd_malloc (len);
- if (addr_name == NULL)
- return 0;
- sprintf (addr_name, "%p:%lx",
- (void *) abfd, (unsigned long) ELFNN_R_SYM (rel->r_info));
+ if (*slot)
+ return (struct elfNN_ia64_local_hash_entry *) *slot;
- /* Collect the canonical entry data for this address. */
- ret = elfNN_ia64_local_hash_lookup (&ia64_info->loc_hash_table,
- addr_name, create, create);
- free (addr_name);
+ ret = (struct elfNN_ia64_local_hash_entry *)
+ objalloc_alloc ((struct objalloc *) ia64_info->loc_hash_memory,
+ sizeof (struct elfNN_ia64_local_hash_entry));
+ if (ret)
+ {
+ memset (ret, 0, sizeof (*ret));
+ ret->id = sec->id;
+ ret->r_sym = ELFNN_R_SYM (rel->r_info);
+ *slot = ret;
+ }
return ret;
}
@@ -1853,7 +1962,7 @@ get_dyn_sym_info (ia64_info, h, abfd, rel, create)
struct elf_link_hash_entry *h;
bfd *abfd;
const Elf_Internal_Rela *rel;
- boolean create;
+ bfd_boolean create;
{
struct elfNN_ia64_dyn_sym_info **pp;
struct elfNN_ia64_dyn_sym_info *dyn_i;
@@ -1866,7 +1975,11 @@ get_dyn_sym_info (ia64_info, h, abfd, rel, create)
struct elfNN_ia64_local_hash_entry *loc_h;
loc_h = get_local_sym_hash (ia64_info, abfd, rel, create);
- BFD_ASSERT (loc_h);
+ if (!loc_h)
+ {
+ BFD_ASSERT (!create);
+ return NULL;
+ }
pp = &loc_h->info;
}
@@ -1909,6 +2022,10 @@ get_got (abfd, info, ia64_info)
BFD_ASSERT (got);
ia64_info->got_sec = got;
+ /* The .got section is always aligned at 8 bytes. */
+ if (!bfd_set_section_alignment (abfd, got, 3))
+ return 0;
+
flags = bfd_get_section_flags (abfd, got);
bfd_set_section_flags (abfd, got, SEC_SMALL_DATA | flags);
}
@@ -1917,14 +2034,14 @@ get_got (abfd, info, ia64_info)
}
/* Create function descriptor section (.opd). This section is called .opd
- because it contains "official prodecure descriptors". The "official"
+ because it contains "official procedure descriptors". The "official"
refers to the fact that these descriptors are used when taking the address
of a procedure, thus ensuring a unique address for each procedure. */
static asection *
get_fptr (abfd, info, ia64_info)
bfd *abfd;
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
+ struct bfd_link_info *info;
struct elfNN_ia64_link_hash_table *ia64_info;
{
asection *fptr;
@@ -1944,7 +2061,7 @@ get_fptr (abfd, info, ia64_info)
| SEC_LOAD
| SEC_HAS_CONTENTS
| SEC_IN_MEMORY
- | SEC_READONLY
+ | (info->pie ? 0 : SEC_READONLY)
| SEC_LINKER_CREATED))
|| !bfd_set_section_alignment (abfd, fptr, 4))
{
@@ -1953,6 +2070,26 @@ get_fptr (abfd, info, ia64_info)
}
ia64_info->fptr_sec = fptr;
+
+ if (info->pie)
+ {
+ asection *fptr_rel;
+ fptr_rel = bfd_make_section(dynobj, ".rela.opd");
+ if (fptr_rel == NULL
+ || !bfd_set_section_flags (dynobj, fptr_rel,
+ (SEC_ALLOC | SEC_LOAD
+ | SEC_HAS_CONTENTS
+ | SEC_IN_MEMORY
+ | SEC_LINKER_CREATED
+ | SEC_READONLY))
+ || !bfd_set_section_alignment (abfd, fptr_rel, 3))
+ {
+ BFD_ASSERT (0);
+ return NULL;
+ }
+
+ ia64_info->rel_fptr_sec = fptr_rel;
+ }
}
return fptr;
@@ -2000,7 +2137,7 @@ get_reloc_section (abfd, ia64_info, sec, create)
bfd *abfd;
struct elfNN_ia64_link_hash_table *ia64_info;
asection *sec;
- boolean create;
+ bfd_boolean create;
{
const char *srel_name;
asection *srel;
@@ -2039,18 +2176,12 @@ get_reloc_section (abfd, ia64_info, sec, create)
return NULL;
}
- if (sec->flags & SEC_READONLY)
- ia64_info->reltext = 1;
-
return srel;
}
-static boolean
-count_dyn_reloc (abfd, dyn_i, srel, type)
- bfd *abfd;
- struct elfNN_ia64_dyn_sym_info *dyn_i;
- asection *srel;
- int type;
+static bfd_boolean
+count_dyn_reloc (bfd *abfd, struct elfNN_ia64_dyn_sym_info *dyn_i,
+ asection *srel, int type, bfd_boolean reltext)
{
struct elfNN_ia64_dyn_reloc_entry *rent;
@@ -2063,7 +2194,7 @@ count_dyn_reloc (abfd, dyn_i, srel, type)
rent = ((struct elfNN_ia64_dyn_reloc_entry *)
bfd_alloc (abfd, (bfd_size_type) sizeof (*rent)));
if (!rent)
- return false;
+ return FALSE;
rent->next = dyn_i->reloc_entries;
rent->srel = srel;
@@ -2071,12 +2202,13 @@ count_dyn_reloc (abfd, dyn_i, srel, type)
rent->count = 0;
dyn_i->reloc_entries = rent;
}
+ rent->reltext = reltext;
rent->count++;
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
elfNN_ia64_check_relocs (abfd, info, sec, relocs)
bfd *abfd;
struct bfd_link_info *info;
@@ -2089,8 +2221,8 @@ elfNN_ia64_check_relocs (abfd, info, sec, relocs)
const Elf_Internal_Rela *rel;
asection *got, *fptr, *srel;
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
symtab_hdr = &elf_tdata (abfd)->symtab_hdr;
ia64_info = elfNN_ia64_hash_table (info);
@@ -2102,22 +2234,23 @@ elfNN_ia64_check_relocs (abfd, info, sec, relocs)
{
enum {
NEED_GOT = 1,
- NEED_FPTR = 2,
- NEED_PLTOFF = 4,
- NEED_MIN_PLT = 8,
- NEED_FULL_PLT = 16,
- NEED_DYNREL = 32,
- NEED_LTOFF_FPTR = 64,
- NEED_TPREL = 128,
- NEED_DTPMOD = 256,
- NEED_DTPREL = 512
+ NEED_GOTX = 2,
+ NEED_FPTR = 4,
+ NEED_PLTOFF = 8,
+ NEED_MIN_PLT = 16,
+ NEED_FULL_PLT = 32,
+ NEED_DYNREL = 64,
+ NEED_LTOFF_FPTR = 128,
+ NEED_TPREL = 256,
+ NEED_DTPMOD = 512,
+ NEED_DTPREL = 1024
};
struct elf_link_hash_entry *h = NULL;
unsigned long r_symndx = ELFNN_R_SYM (rel->r_info);
struct elfNN_ia64_dyn_sym_info *dyn_i;
int need_entry;
- boolean maybe_dynamic;
+ bfd_boolean maybe_dynamic;
int dynrel_type = R_IA64_NONE;
if (r_symndx >= symtab_hdr->sh_info)
@@ -2137,13 +2270,12 @@ elfNN_ia64_check_relocs (abfd, info, sec, relocs)
locally or externally defined, as not all of the input files
have yet been processed. Do something with what we know, as
this may help reduce memory usage and processing time later. */
- maybe_dynamic = false;
- if (h && ((info->shared
- && (!info->symbolic || info->allow_shlib_undefined))
+ maybe_dynamic = FALSE;
+ if (h && ((!info->executable
+ && (!info->symbolic || info->unresolved_syms_in_shared_libs == RM_IGNORE))
|| ! (h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR)
- || h->root.type == bfd_link_hash_defweak
- || elfNN_ia64_aix_vec (abfd->xvec)))
- maybe_dynamic = true;
+ || h->root.type == bfd_link_hash_defweak))
+ maybe_dynamic = TRUE;
need_entry = 0;
switch (ELFNN_R_TYPE (rel->r_info))
@@ -2199,7 +2331,7 @@ elfNN_ia64_check_relocs (abfd, info, sec, relocs)
case R_IA64_FPTR32LSB:
case R_IA64_FPTR64MSB:
case R_IA64_FPTR64LSB:
- if (info->shared || h || elfNN_ia64_aix_vec (abfd->xvec))
+ if (info->shared || h)
need_entry = NEED_FPTR | NEED_DYNREL;
else
need_entry = NEED_FPTR;
@@ -2207,11 +2339,14 @@ elfNN_ia64_check_relocs (abfd, info, sec, relocs)
break;
case R_IA64_LTOFF22:
- case R_IA64_LTOFF22X:
case R_IA64_LTOFF64I:
need_entry = NEED_GOT;
break;
+ case R_IA64_LTOFF22X:
+ need_entry = NEED_GOTX;
+ break;
+
case R_IA64_PLTOFF22:
case R_IA64_PLTOFF64I:
case R_IA64_PLTOFF64MSB:
@@ -2248,10 +2383,7 @@ elfNN_ia64_check_relocs (abfd, info, sec, relocs)
case R_IA64_DIR64MSB:
case R_IA64_DIR64LSB:
/* Shared objects will always need at least a REL relocation. */
- if (info->shared || maybe_dynamic
- || (elfNN_ia64_aix_vec (abfd->xvec)
- && (!h || strcmp (h->root.root.string,
- "__GLOB_DATA_PTR") != 0)))
+ if (info->shared || maybe_dynamic)
need_entry = NEED_DYNREL;
dynrel_type = R_IA64_DIR64LSB;
break;
@@ -2287,22 +2419,25 @@ elfNN_ia64_check_relocs (abfd, info, sec, relocs)
abfd, 0, (bfd_vma) 0);
}
- dyn_i = get_dyn_sym_info (ia64_info, h, abfd, rel, true);
+ dyn_i = get_dyn_sym_info (ia64_info, h, abfd, rel, TRUE);
/* Record whether or not this is a local symbol. */
dyn_i->h = h;
/* Create what's needed. */
- if (need_entry & (NEED_GOT | NEED_TPREL | NEED_DTPMOD | NEED_DTPREL))
+ if (need_entry & (NEED_GOT | NEED_GOTX | NEED_TPREL
+ | NEED_DTPMOD | NEED_DTPREL))
{
if (!got)
{
got = get_got (abfd, info, ia64_info);
if (!got)
- return false;
+ return FALSE;
}
if (need_entry & NEED_GOT)
dyn_i->want_got = 1;
+ if (need_entry & NEED_GOTX)
+ dyn_i->want_gotx = 1;
if (need_entry & NEED_TPREL)
dyn_i->want_tprel = 1;
if (need_entry & NEED_DTPMOD)
@@ -2316,19 +2451,17 @@ elfNN_ia64_check_relocs (abfd, info, sec, relocs)
{
fptr = get_fptr (abfd, info, ia64_info);
if (!fptr)
- return false;
+ return FALSE;
}
/* FPTRs for shared libraries are allocated by the dynamic
linker. Make sure this local symbol will appear in the
dynamic symbol table. */
- if (!h && (info->shared
- /* AIX also needs one */
- || elfNN_ia64_aix_vec (abfd->xvec)))
+ if (!h && info->shared)
{
- if (! (_bfd_elfNN_link_record_local_dynamic_symbol
+ if (! (bfd_elf_link_record_local_dynamic_symbol
(info, abfd, (long) r_symndx)))
- return false;
+ return FALSE;
}
dyn_i->want_fptr = 1;
@@ -2350,40 +2483,32 @@ elfNN_ia64_check_relocs (abfd, info, sec, relocs)
{
if (!srel)
{
- srel = get_reloc_section (abfd, ia64_info, sec, true);
+ srel = get_reloc_section (abfd, ia64_info, sec, TRUE);
if (!srel)
- return false;
+ return FALSE;
}
- if (!count_dyn_reloc (abfd, dyn_i, srel, dynrel_type))
- return false;
+ if (!count_dyn_reloc (abfd, dyn_i, srel, dynrel_type,
+ (sec->flags & SEC_READONLY) != 0))
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
-struct elfNN_ia64_allocate_data
-{
- struct bfd_link_info *info;
- bfd_size_type ofs;
-};
-
/* For cleanliness, and potentially faster dynamic loading, allocate
external GOT entries first. */
-static boolean
+static bfd_boolean
allocate_global_data_got (dyn_i, data)
struct elfNN_ia64_dyn_sym_info *dyn_i;
PTR data;
{
struct elfNN_ia64_allocate_data *x = (struct elfNN_ia64_allocate_data *)data;
- if (dyn_i->want_got
+ if ((dyn_i->want_got || dyn_i->want_gotx)
&& ! dyn_i->want_fptr
- && (elfNN_ia64_dynamic_symbol_p (dyn_i->h, x->info)
- || (elfNN_ia64_aix_vec (x->info->hash->creator)
- && (!dyn_i->h || strcmp (dyn_i->h->root.root.string,
- "__GLOB_DATA_PTR") != 0))))
+ && elfNN_ia64_dynamic_symbol_p (dyn_i->h, x->info, 0))
{
dyn_i->got_offset = x->ofs;
x->ofs += 8;
@@ -2395,20 +2520,35 @@ allocate_global_data_got (dyn_i, data)
}
if (dyn_i->want_dtpmod)
{
- dyn_i->dtpmod_offset = x->ofs;
- x->ofs += 8;
+ if (elfNN_ia64_dynamic_symbol_p (dyn_i->h, x->info, 0))
+ {
+ dyn_i->dtpmod_offset = x->ofs;
+ x->ofs += 8;
+ }
+ else
+ {
+ struct elfNN_ia64_link_hash_table *ia64_info;
+
+ ia64_info = elfNN_ia64_hash_table (x->info);
+ if (ia64_info->self_dtpmod_offset == (bfd_vma) -1)
+ {
+ ia64_info->self_dtpmod_offset = x->ofs;
+ x->ofs += 8;
+ }
+ dyn_i->dtpmod_offset = ia64_info->self_dtpmod_offset;
+ }
}
if (dyn_i->want_dtprel)
{
dyn_i->dtprel_offset = x->ofs;
x->ofs += 8;
}
- return true;
+ return TRUE;
}
/* Next, allocate all the GOT entries used by LTOFF_FPTR relocs. */
-static boolean
+static bfd_boolean
allocate_global_fptr_got (dyn_i, data)
struct elfNN_ia64_dyn_sym_info *dyn_i;
PTR data;
@@ -2417,32 +2557,30 @@ allocate_global_fptr_got (dyn_i, data)
if (dyn_i->want_got
&& dyn_i->want_fptr
- && (elfNN_ia64_dynamic_symbol_p (dyn_i->h, x->info)
- || elfNN_ia64_aix_vec (x->info->hash->creator)))
+ && elfNN_ia64_dynamic_symbol_p (dyn_i->h, x->info, R_IA64_FPTR64LSB))
{
dyn_i->got_offset = x->ofs;
x->ofs += 8;
}
- return true;
+ return TRUE;
}
/* Lastly, allocate all the GOT entries for local data. */
-static boolean
+static bfd_boolean
allocate_local_got (dyn_i, data)
struct elfNN_ia64_dyn_sym_info *dyn_i;
PTR data;
{
struct elfNN_ia64_allocate_data *x = (struct elfNN_ia64_allocate_data *)data;
- if (dyn_i->want_got
- && ! (elfNN_ia64_dynamic_symbol_p (dyn_i->h, x->info)
- || elfNN_ia64_aix_vec (x->info->hash->creator)))
+ if ((dyn_i->want_got || dyn_i->want_gotx)
+ && !elfNN_ia64_dynamic_symbol_p (dyn_i->h, x->info, 0))
{
dyn_i->got_offset = x->ofs;
x->ofs += 8;
}
- return true;
+ return TRUE;
}
/* Search for the index of a global symbol in it's defining object file. */
@@ -2467,7 +2605,7 @@ global_sym_index (h)
/* Allocate function descriptors. We can do these for every function
in a main executable that is not exported. */
-static boolean
+static bfd_boolean
allocate_fptr (dyn_i, data)
struct elfNN_ia64_dyn_sym_info *dyn_i;
PTR data;
@@ -2483,22 +2621,20 @@ allocate_fptr (dyn_i, data)
|| h->root.type == bfd_link_hash_warning)
h = (struct elf_link_hash_entry *) h->root.u.i.link;
- if (x->info->shared
- /* AIX needs an FPTR in this case. */
- || (elfNN_ia64_aix_vec (x->info->hash->creator)
- && (!h
- || h->root.type == bfd_link_hash_defined
- || h->root.type == bfd_link_hash_defweak)))
+ if (!x->info->executable
+ && (!h
+ || ELF_ST_VISIBILITY (h->other) == STV_DEFAULT
+ || h->root.type != bfd_link_hash_undefweak))
{
if (h && h->dynindx == -1)
{
BFD_ASSERT ((h->root.type == bfd_link_hash_defined)
|| (h->root.type == bfd_link_hash_defweak));
- if (!_bfd_elfNN_link_record_local_dynamic_symbol
+ if (!bfd_elf_link_record_local_dynamic_symbol
(x->info, h->root.u.def.section->owner,
global_sym_index (h)))
- return false;
+ return FALSE;
}
dyn_i->want_fptr = 0;
@@ -2511,12 +2647,12 @@ allocate_fptr (dyn_i, data)
else
dyn_i->want_fptr = 0;
}
- return true;
+ return TRUE;
}
/* Allocate all the minimal PLT entries. */
-static boolean
+static bfd_boolean
allocate_plt_entries (dyn_i, data)
struct elfNN_ia64_dyn_sym_info *dyn_i;
PTR data;
@@ -2533,7 +2669,7 @@ allocate_plt_entries (dyn_i, data)
h = (struct elf_link_hash_entry *) h->root.u.i.link;
/* ??? Versioned symbols seem to lose ELF_LINK_HASH_NEEDS_PLT. */
- if (elfNN_ia64_dynamic_symbol_p (h, x->info))
+ if (elfNN_ia64_dynamic_symbol_p (h, x->info, 0))
{
bfd_size_type offset = x->ofs;
if (offset == 0)
@@ -2549,12 +2685,12 @@ allocate_plt_entries (dyn_i, data)
dyn_i->want_plt2 = 0;
}
}
- return true;
+ return TRUE;
}
/* Allocate all the full PLT entries. */
-static boolean
+static bfd_boolean
allocate_plt2_entries (dyn_i, data)
struct elfNN_ia64_dyn_sym_info *dyn_i;
PTR data;
@@ -2574,7 +2710,7 @@ allocate_plt2_entries (dyn_i, data)
h = (struct elf_link_hash_entry *) h->root.u.i.link;
dyn_i->h->plt.offset = ofs;
}
- return true;
+ return TRUE;
}
/* Allocate all the PLTOFF entries requested by relocations and
@@ -2582,7 +2718,7 @@ allocate_plt2_entries (dyn_i, data)
because the latter are not necessarily addressable by the GP.
??? Relaxation might be able to determine that they are. */
-static boolean
+static bfd_boolean
allocate_pltoff_entries (dyn_i, data)
struct elfNN_ia64_dyn_sym_info *dyn_i;
PTR data;
@@ -2594,13 +2730,13 @@ allocate_pltoff_entries (dyn_i, data)
dyn_i->pltoff_offset = x->ofs;
x->ofs += 16;
}
- return true;
+ return TRUE;
}
/* Allocate dynamic relocations for those symbols that turned out
to be dynamic. */
-static boolean
+static bfd_boolean
allocate_dynrel_entries (dyn_i, data)
struct elfNN_ia64_dyn_sym_info *dyn_i;
PTR data;
@@ -2608,15 +2744,17 @@ allocate_dynrel_entries (dyn_i, data)
struct elfNN_ia64_allocate_data *x = (struct elfNN_ia64_allocate_data *)data;
struct elfNN_ia64_link_hash_table *ia64_info;
struct elfNN_ia64_dyn_reloc_entry *rent;
- boolean dynamic_symbol, shared;
+ bfd_boolean dynamic_symbol, shared, resolved_zero;
ia64_info = elfNN_ia64_hash_table (x->info);
- dynamic_symbol = elfNN_ia64_dynamic_symbol_p (dyn_i->h, x->info)
- || (elfNN_ia64_aix_vec (x->info->hash->creator)
- /* Don't allocate an entry for __GLOB_DATA_PTR */
- && (!dyn_i->h || strcmp (dyn_i->h->root.root.string,
- "__GLOB_DATA_PTR") != 0));
+
+ /* Note that this can't be used in relation to FPTR relocs below. */
+ dynamic_symbol = elfNN_ia64_dynamic_symbol_p (dyn_i->h, x->info, 0);
+
shared = x->info->shared;
+ resolved_zero = (dyn_i->h
+ && ELF_ST_VISIBILITY (dyn_i->h->other)
+ && dyn_i->h->root.type == bfd_link_hash_undefweak);
/* Take care of the normal data relocations. */
@@ -2627,10 +2765,11 @@ allocate_dynrel_entries (dyn_i, data)
switch (rent->type)
{
case R_IA64_FPTR64LSB:
- /* Allocate one iff !want_fptr, which by this point will
- be true only if we're actually allocating one statically
- in the main executable. */
- if (dyn_i->want_fptr)
+ /* Allocate one iff !want_fptr and not PIE, which by this point
+ will be true only if we're actually allocating one statically
+ in the main executable. Position independent executables
+ need a relative reloc. */
+ if (dyn_i->want_fptr && !x->info->pie)
continue;
break;
case R_IA64_PCREL64LSB:
@@ -2656,22 +2795,39 @@ allocate_dynrel_entries (dyn_i, data)
default:
abort ();
}
+ if (rent->reltext)
+ ia64_info->reltext = 1;
rent->srel->_raw_size += sizeof (ElfNN_External_Rela) * count;
}
/* Take care of the GOT and PLT relocations. */
- if (((dynamic_symbol || shared) && dyn_i->want_got)
- || (dyn_i->want_ltoff_fptr && dyn_i->h && dyn_i->h->dynindx != -1))
- ia64_info->rel_got_sec->_raw_size += sizeof (ElfNN_External_Rela);
+ if ((!resolved_zero
+ && (dynamic_symbol || shared)
+ && (dyn_i->want_got || dyn_i->want_gotx))
+ || (dyn_i->want_ltoff_fptr
+ && dyn_i->h
+ && dyn_i->h->dynindx != -1))
+ {
+ if (!dyn_i->want_ltoff_fptr
+ || !x->info->pie
+ || dyn_i->h == NULL
+ || dyn_i->h->root.type != bfd_link_hash_undefweak)
+ ia64_info->rel_got_sec->_raw_size += sizeof (ElfNN_External_Rela);
+ }
if ((dynamic_symbol || shared) && dyn_i->want_tprel)
ia64_info->rel_got_sec->_raw_size += sizeof (ElfNN_External_Rela);
- if ((dynamic_symbol || shared) && dyn_i->want_dtpmod)
+ if (dynamic_symbol && dyn_i->want_dtpmod)
ia64_info->rel_got_sec->_raw_size += sizeof (ElfNN_External_Rela);
if (dynamic_symbol && dyn_i->want_dtprel)
ia64_info->rel_got_sec->_raw_size += sizeof (ElfNN_External_Rela);
+ if (ia64_info->rel_fptr_sec && dyn_i->want_fptr)
+ {
+ if (dyn_i->h == NULL || dyn_i->h->root.type != bfd_link_hash_undefweak)
+ ia64_info->rel_fptr_sec->_raw_size += sizeof (ElfNN_External_Rela);
+ }
- if (dyn_i->want_pltoff)
+ if (!resolved_zero && dyn_i->want_pltoff)
{
bfd_size_type t = 0;
@@ -2686,10 +2842,10 @@ allocate_dynrel_entries (dyn_i, data)
ia64_info->rel_pltoff_sec->_raw_size += t;
}
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
elfNN_ia64_adjust_dynamic_symbol (info, h)
struct bfd_link_info *info ATTRIBUTE_UNUSED;
struct elf_link_hash_entry *h;
@@ -2706,7 +2862,7 @@ elfNN_ia64_adjust_dynamic_symbol (info, h)
|| h->weakdef->root.type == bfd_link_hash_defweak);
h->root.u.def.section = h->weakdef->root.u.def.section;
h->root.u.def.value = h->weakdef->root.u.def.value;
- return true;
+ return TRUE;
}
/* If this is a reference to a symbol defined by a dynamic object which
@@ -2716,33 +2872,34 @@ elfNN_ia64_adjust_dynamic_symbol (info, h)
But IA-64 code is canonically PIC, so as a rule we can avoid this sort
of hackery. */
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
elfNN_ia64_size_dynamic_sections (output_bfd, info)
- bfd *output_bfd;
+ bfd *output_bfd ATTRIBUTE_UNUSED;
struct bfd_link_info *info;
{
struct elfNN_ia64_allocate_data data;
struct elfNN_ia64_link_hash_table *ia64_info;
asection *sec;
bfd *dynobj;
- boolean relplt = false;
+ bfd_boolean relplt = FALSE;
dynobj = elf_hash_table(info)->dynobj;
ia64_info = elfNN_ia64_hash_table (info);
+ ia64_info->self_dtpmod_offset = (bfd_vma) -1;
BFD_ASSERT(dynobj != NULL);
data.info = info;
/* Set the contents of the .interp section to the interpreter. */
if (ia64_info->root.dynamic_sections_created
- && !info->shared)
+ && info->executable)
{
sec = bfd_get_section_by_name (dynobj, ".interp");
BFD_ASSERT (sec != NULL);
- sec->contents = (bfd_byte *) DYNAMIC_INTERPRETER (output_bfd);
- sec->_raw_size = strlen (DYNAMIC_INTERPRETER (output_bfd)) + 1;
+ sec->contents = (bfd_byte *) ELF_DYNAMIC_INTERPRETER;
+ sec->_raw_size = strlen (ELF_DYNAMIC_INTERPRETER) + 1;
}
/* Allocate the GOT entries. */
@@ -2767,7 +2924,7 @@ elfNN_ia64_size_dynamic_sections (output_bfd, info)
/* Now that we've seen all of the input files, we can decide which
symbols need plt entries. Allocate the minimal PLT entries first.
- We do this even though dynamic_sections_created may be false, because
+ We do this even though dynamic_sections_created may be FALSE, because
this has the side-effect of clearing want_plt and want_plt2. */
data.ofs = 0;
@@ -2784,8 +2941,12 @@ elfNN_ia64_size_dynamic_sections (output_bfd, info)
data.ofs = (data.ofs + 31) & (bfd_vma) -32;
elfNN_ia64_dyn_sym_traverse (ia64_info, allocate_plt2_entries, &data);
- if (data.ofs != 0)
+ if (data.ofs != 0 || ia64_info->root.dynamic_sections_created)
{
+ /* FIXME: we always reserve the memory for dynamic linker even if
+ there are no PLT entries since dynamic linker may assume the
+ reserved memory always exists. */
+
BFD_ASSERT (ia64_info->root.dynamic_sections_created);
ia64_info->plt_sec->_raw_size = data.ofs;
@@ -2810,6 +2971,8 @@ elfNN_ia64_size_dynamic_sections (output_bfd, info)
/* Allocate space for the dynamic relocations that turned out to be
required. */
+ if (info->shared && ia64_info->self_dtpmod_offset != (bfd_vma) -1)
+ ia64_info->rel_got_sec->_raw_size += sizeof (ElfNN_External_Rela);
elfNN_ia64_dyn_sym_traverse (ia64_info, allocate_dynrel_entries, &data);
}
@@ -2817,7 +2980,7 @@ elfNN_ia64_size_dynamic_sections (output_bfd, info)
Allocate memory for them. */
for (sec = dynobj->sections; sec != NULL; sec = sec->next)
{
- boolean strip;
+ bfd_boolean strip;
if (!(sec->flags & SEC_LINKER_CREATED))
continue;
@@ -2833,7 +2996,7 @@ elfNN_ia64_size_dynamic_sections (output_bfd, info)
strip = (sec->_raw_size == 0);
if (sec == ia64_info->got_sec)
- strip = false;
+ strip = FALSE;
else if (sec == ia64_info->rel_got_sec)
{
if (strip)
@@ -2848,6 +3011,15 @@ elfNN_ia64_size_dynamic_sections (output_bfd, info)
if (strip)
ia64_info->fptr_sec = NULL;
}
+ else if (sec == ia64_info->rel_fptr_sec)
+ {
+ if (strip)
+ ia64_info->rel_fptr_sec = NULL;
+ else
+ /* We use the reloc_count field as a counter if we need to
+ copy relocs into the output file. */
+ sec->reloc_count = 0;
+ }
else if (sec == ia64_info->plt_sec)
{
if (strip)
@@ -2864,7 +3036,7 @@ elfNN_ia64_size_dynamic_sections (output_bfd, info)
ia64_info->rel_pltoff_sec = NULL;
else
{
- relplt = true;
+ relplt = TRUE;
/* We use the reloc_count field as a counter if we need to
copy relocs into the output file. */
sec->reloc_count = 0;
@@ -2879,7 +3051,7 @@ elfNN_ia64_size_dynamic_sections (output_bfd, info)
name = bfd_get_section_name (dynobj, sec);
if (strcmp (name, ".got.plt") == 0)
- strip = false;
+ strip = FALSE;
else if (strncmp (name, ".rel", 4) == 0)
{
if (!strip)
@@ -2900,7 +3072,7 @@ elfNN_ia64_size_dynamic_sections (output_bfd, info)
/* Allocate memory for the section contents. */
sec->contents = (bfd_byte *) bfd_zalloc (dynobj, sec->_raw_size);
if (sec->contents == NULL && sec->_raw_size != 0)
- return false;
+ return FALSE;
}
}
@@ -2910,46 +3082,46 @@ elfNN_ia64_size_dynamic_sections (output_bfd, info)
later (in finish_dynamic_sections) but we must add the entries now
so that we get the correct size for the .dynamic section. */
- if (!info->shared)
+ if (info->executable)
{
/* The DT_DEBUG entry is filled in by the dynamic linker and used
by the debugger. */
#define add_dynamic_entry(TAG, VAL) \
- bfd_elfNN_add_dynamic_entry (info, (bfd_vma) (TAG), (bfd_vma) (VAL))
+ _bfd_elf_add_dynamic_entry (info, TAG, VAL)
if (!add_dynamic_entry (DT_DEBUG, 0))
- return false;
+ return FALSE;
}
if (!add_dynamic_entry (DT_IA_64_PLT_RESERVE, 0))
- return false;
+ return FALSE;
if (!add_dynamic_entry (DT_PLTGOT, 0))
- return false;
+ return FALSE;
if (relplt)
{
if (!add_dynamic_entry (DT_PLTRELSZ, 0)
|| !add_dynamic_entry (DT_PLTREL, DT_RELA)
|| !add_dynamic_entry (DT_JMPREL, 0))
- return false;
+ return FALSE;
}
if (!add_dynamic_entry (DT_RELA, 0)
|| !add_dynamic_entry (DT_RELASZ, 0)
|| !add_dynamic_entry (DT_RELAENT, sizeof (ElfNN_External_Rela)))
- return false;
+ return FALSE;
if (ia64_info->reltext)
{
if (!add_dynamic_entry (DT_TEXTREL, 0))
- return false;
+ return FALSE;
info->flags |= DF_TEXTREL;
}
}
/* ??? Perhaps force __gp local. */
- return true;
+ return TRUE;
}
static bfd_reloc_status_type
@@ -3190,14 +3362,13 @@ elfNN_ia64_install_dyn_reloc (abfd, info, sec, srel, offset, type,
bfd_vma addend;
{
Elf_Internal_Rela outrel;
-
- offset += sec->output_section->vma + sec->output_offset;
+ bfd_byte *loc;
BFD_ASSERT (dynindx != -1);
outrel.r_info = ELFNN_R_INFO (dynindx, type);
outrel.r_addend = addend;
outrel.r_offset = _bfd_elf_section_offset (abfd, info, sec, offset);
- if ((outrel.r_offset | 1) == (bfd_vma) -1)
+ if (outrel.r_offset >= (bfd_vma) -2)
{
/* Run for the hills. We shouldn't be outputting a relocation
for this. So do what everyone else does and output a no-op. */
@@ -3205,10 +3376,12 @@ elfNN_ia64_install_dyn_reloc (abfd, info, sec, srel, offset, type,
outrel.r_addend = 0;
outrel.r_offset = 0;
}
+ else
+ outrel.r_offset += sec->output_section->vma + sec->output_offset;
- bfd_elfNN_swap_reloca_out (abfd, &outrel,
- ((ElfNN_External_Rela *) srel->contents
- + srel->reloc_count++));
+ loc = srel->contents;
+ loc += srel->reloc_count++ * sizeof (ElfNN_External_Rela);
+ bfd_elfNN_swap_reloca_out (abfd, &outrel, loc);
BFD_ASSERT (sizeof (ElfNN_External_Rela) * srel->reloc_count
<= srel->_cooked_size);
}
@@ -3228,7 +3401,7 @@ set_got_entry (abfd, info, dyn_i, dynindx, addend, value, dyn_r_type)
{
struct elfNN_ia64_link_hash_table *ia64_info;
asection *got_sec;
- boolean done;
+ bfd_boolean done;
bfd_vma got_offset;
ia64_info = elfNN_ia64_hash_table (info);
@@ -3238,22 +3411,31 @@ set_got_entry (abfd, info, dyn_i, dynindx, addend, value, dyn_r_type)
{
case R_IA64_TPREL64LSB:
done = dyn_i->tprel_done;
- dyn_i->tprel_done = true;
+ dyn_i->tprel_done = TRUE;
got_offset = dyn_i->tprel_offset;
break;
case R_IA64_DTPMOD64LSB:
- done = dyn_i->dtpmod_done;
- dyn_i->dtpmod_done = true;
+ if (dyn_i->dtpmod_offset != ia64_info->self_dtpmod_offset)
+ {
+ done = dyn_i->dtpmod_done;
+ dyn_i->dtpmod_done = TRUE;
+ }
+ else
+ {
+ done = ia64_info->self_dtpmod_done;
+ ia64_info->self_dtpmod_done = TRUE;
+ dynindx = 0;
+ }
got_offset = dyn_i->dtpmod_offset;
break;
case R_IA64_DTPREL64LSB:
done = dyn_i->dtprel_done;
- dyn_i->dtprel_done = true;
+ dyn_i->dtprel_done = TRUE;
got_offset = dyn_i->dtprel_offset;
break;
default:
done = dyn_i->got_done;
- dyn_i->got_done = true;
+ dyn_i->got_done = TRUE;
got_offset = dyn_i->got_offset;
break;
}
@@ -3266,10 +3448,17 @@ set_got_entry (abfd, info, dyn_i, dynindx, addend, value, dyn_r_type)
bfd_put_64 (abfd, value, got_sec->contents + got_offset);
/* Install a dynamic relocation if needed. */
- if ((info->shared && dyn_r_type != R_IA64_DTPREL64LSB)
- || elfNN_ia64_dynamic_symbol_p (dyn_i->h, info)
- || elfNN_ia64_aix_vec (abfd->xvec)
- || (dynindx != -1 && dyn_r_type == R_IA64_FPTR64LSB))
+ if (((info->shared
+ && (!dyn_i->h
+ || ELF_ST_VISIBILITY (dyn_i->h->other) == STV_DEFAULT
+ || dyn_i->h->root.type != bfd_link_hash_undefweak)
+ && dyn_r_type != R_IA64_DTPREL64LSB)
+ || elfNN_ia64_dynamic_symbol_p (dyn_i->h, info, dyn_r_type)
+ || (dynindx != -1 && dyn_r_type == R_IA64_FPTR64LSB))
+ && (!dyn_i->want_ltoff_fptr
+ || !info->pie
+ || !dyn_i->h
+ || dyn_i->h->root.type != bfd_link_hash_undefweak))
{
if (dynindx == -1
&& dyn_r_type != R_IA64_TPREL64LSB
@@ -3304,7 +3493,7 @@ set_got_entry (abfd, info, dyn_i, dynindx, addend, value, dyn_r_type)
dyn_r_type = R_IA64_DTPREL64MSB;
break;
default:
- BFD_ASSERT (false);
+ BFD_ASSERT (FALSE);
break;
}
}
@@ -3348,6 +3537,24 @@ set_fptr_entry (abfd, info, dyn_i, value)
bfd_put_64 (abfd, value, fptr_sec->contents + dyn_i->fptr_offset);
bfd_put_64 (abfd, _bfd_get_gp_value (abfd),
fptr_sec->contents + dyn_i->fptr_offset + 8);
+ if (ia64_info->rel_fptr_sec)
+ {
+ Elf_Internal_Rela outrel;
+ bfd_byte *loc;
+
+ if (bfd_little_endian (abfd))
+ outrel.r_info = ELFNN_R_INFO (0, R_IA64_IPLTLSB);
+ else
+ outrel.r_info = ELFNN_R_INFO (0, R_IA64_IPLTMSB);
+ outrel.r_addend = value;
+ outrel.r_offset = (fptr_sec->output_section->vma
+ + fptr_sec->output_offset
+ + dyn_i->fptr_offset);
+ loc = ia64_info->rel_fptr_sec->contents;
+ loc += ia64_info->rel_fptr_sec->reloc_count++
+ * sizeof (ElfNN_External_Rela);
+ bfd_elfNN_swap_reloca_out (abfd, &outrel, loc);
+ }
}
/* Return the descriptor's address. */
@@ -3367,7 +3574,7 @@ set_pltoff_entry (abfd, info, dyn_i, value, is_plt)
struct bfd_link_info *info;
struct elfNN_ia64_dyn_sym_info *dyn_i;
bfd_vma value;
- boolean is_plt;
+ bfd_boolean is_plt;
{
struct elfNN_ia64_link_hash_table *ia64_info;
asection *pltoff_sec;
@@ -3387,7 +3594,11 @@ set_pltoff_entry (abfd, info, dyn_i, value, is_plt)
bfd_put_64 (abfd, gp, pltoff_sec->contents + dyn_i->pltoff_offset + 8);
/* Install dynamic relocations if needed. */
- if (!is_plt && info->shared)
+ if (!is_plt
+ && info->shared
+ && (!dyn_i->h
+ || ELF_ST_VISIBILITY (dyn_i->h->other) == STV_DEFAULT
+ || dyn_i->h->root.type != bfd_link_hash_undefweak))
{
unsigned int dyn_r_type;
@@ -3426,12 +3637,10 @@ static bfd_vma
elfNN_ia64_tprel_base (info)
struct bfd_link_info *info;
{
- struct elf_link_tls_segment *tls_segment
- = elf_hash_table (info)->tls_segment;
+ asection *tls_sec = elf_hash_table (info)->tls_sec;
- BFD_ASSERT (tls_segment != NULL);
- return (tls_segment->start
- - align_power ((bfd_vma) 16, tls_segment->align));
+ BFD_ASSERT (tls_sec != NULL);
+ return tls_sec->vma - align_power ((bfd_vma) 16, tls_sec->alignment_power);
}
/* Return the base VMA address which should be subtracted from real addresses
@@ -3442,8 +3651,8 @@ static bfd_vma
elfNN_ia64_dtprel_base (info)
struct bfd_link_info *info;
{
- BFD_ASSERT (elf_hash_table (info)->tls_segment != NULL);
- return elf_hash_table (info)->tls_segment->start;
+ BFD_ASSERT (elf_hash_table (info)->tls_sec != NULL);
+ return elf_hash_table (info)->tls_sec->vma;
}
/* Called through qsort to sort the .IA_64.unwind section during a
@@ -3465,125 +3674,148 @@ elfNN_ia64_unwind_entry_compare (a, b)
return (av < bv ? -1 : av > bv ? 1 : 0);
}
-static boolean
-elfNN_ia64_final_link (abfd, info)
+/* Make sure we've got ourselves a nice fat __gp value. */
+static bfd_boolean
+elfNN_ia64_choose_gp (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
{
+ bfd_vma min_vma = (bfd_vma) -1, max_vma = 0;
+ bfd_vma min_short_vma = min_vma, max_short_vma = 0;
+ struct elf_link_hash_entry *gp;
+ bfd_vma gp_val;
+ asection *os;
struct elfNN_ia64_link_hash_table *ia64_info;
- asection *unwind_output_sec;
ia64_info = elfNN_ia64_hash_table (info);
- /* Make sure we've got ourselves a nice fat __gp value. */
- if (!info->relocateable)
+ /* Find the min and max vma of all sections marked short. Also collect
+ min and max vma of any type, for use in selecting a nice gp. */
+ for (os = abfd->sections; os ; os = os->next)
{
- bfd_vma min_vma = (bfd_vma) -1, max_vma = 0;
- bfd_vma min_short_vma = min_vma, max_short_vma = 0;
- struct elf_link_hash_entry *gp;
- bfd_vma gp_val;
- asection *os;
+ bfd_vma lo, hi;
+
+ if ((os->flags & SEC_ALLOC) == 0)
+ continue;
+
+ lo = os->vma;
+ hi = os->vma + os->_raw_size;
+ if (hi < lo)
+ hi = (bfd_vma) -1;
- /* Find the min and max vma of all sections marked short. Also
- collect min and max vma of any type, for use in selecting a
- nice gp. */
- for (os = abfd->sections; os ; os = os->next)
+ if (min_vma > lo)
+ min_vma = lo;
+ if (max_vma < hi)
+ max_vma = hi;
+ if (os->flags & SEC_SMALL_DATA)
{
- bfd_vma lo, hi;
+ if (min_short_vma > lo)
+ min_short_vma = lo;
+ if (max_short_vma < hi)
+ max_short_vma = hi;
+ }
+ }
- if ((os->flags & SEC_ALLOC) == 0)
- continue;
+ /* See if the user wants to force a value. */
+ gp = elf_link_hash_lookup (elf_hash_table (info), "__gp", FALSE,
+ FALSE, FALSE);
- lo = os->vma;
- hi = os->vma + os->_raw_size;
- if (hi < lo)
- hi = (bfd_vma) -1;
+ if (gp
+ && (gp->root.type == bfd_link_hash_defined
+ || gp->root.type == bfd_link_hash_defweak))
+ {
+ asection *gp_sec = gp->root.u.def.section;
+ gp_val = (gp->root.u.def.value
+ + gp_sec->output_section->vma
+ + gp_sec->output_offset);
+ }
+ else
+ {
+ /* Pick a sensible value. */
- if (min_vma > lo)
- min_vma = lo;
- if (max_vma < hi)
- max_vma = hi;
- if (os->flags & SEC_SMALL_DATA)
- {
- if (min_short_vma > lo)
- min_short_vma = lo;
- if (max_short_vma < hi)
- max_short_vma = hi;
- }
+ asection *got_sec = ia64_info->got_sec;
+
+ /* Start with just the address of the .got. */
+ if (got_sec)
+ gp_val = got_sec->output_section->vma;
+ else if (max_short_vma != 0)
+ gp_val = min_short_vma;
+ else
+ gp_val = min_vma;
+
+ /* If it is possible to address the entire image, but we
+ don't with the choice above, adjust. */
+ if (max_vma - min_vma < 0x400000
+ && max_vma - gp_val <= 0x200000
+ && gp_val - min_vma > 0x200000)
+ gp_val = min_vma + 0x200000;
+ else if (max_short_vma != 0)
+ {
+ /* If we don't cover all the short data, adjust. */
+ if (max_short_vma - gp_val >= 0x200000)
+ gp_val = min_short_vma + 0x200000;
+
+ /* If we're addressing stuff past the end, adjust back. */
+ if (gp_val > max_vma)
+ gp_val = max_vma - 0x200000 + 8;
}
+ }
- /* See if the user wants to force a value. */
- gp = elf_link_hash_lookup (elf_hash_table (info), "__gp", false,
- false, false);
+ /* Validate whether all SHF_IA_64_SHORT sections are within
+ range of the chosen GP. */
- if (gp
- && (gp->root.type == bfd_link_hash_defined
- || gp->root.type == bfd_link_hash_defweak))
+ if (max_short_vma != 0)
+ {
+ if (max_short_vma - min_short_vma >= 0x400000)
{
- asection *gp_sec = gp->root.u.def.section;
- gp_val = (gp->root.u.def.value
- + gp_sec->output_section->vma
- + gp_sec->output_offset);
+ (*_bfd_error_handler)
+ (_("%s: short data segment overflowed (0x%lx >= 0x400000)"),
+ bfd_get_filename (abfd),
+ (unsigned long) (max_short_vma - min_short_vma));
+ return FALSE;
}
- else
+ else if ((gp_val > min_short_vma
+ && gp_val - min_short_vma > 0x200000)
+ || (gp_val < max_short_vma
+ && max_short_vma - gp_val >= 0x200000))
{
- /* Pick a sensible value. */
+ (*_bfd_error_handler)
+ (_("%s: __gp does not cover short data segment"),
+ bfd_get_filename (abfd));
+ return FALSE;
+ }
+ }
- asection *got_sec = ia64_info->got_sec;
+ _bfd_set_gp_value (abfd, gp_val);
- /* Start with just the address of the .got. */
- if (got_sec)
- gp_val = got_sec->output_section->vma;
- else if (max_short_vma != 0)
- gp_val = min_short_vma;
- else
- gp_val = min_vma;
-
- /* If it is possible to address the entire image, but we
- don't with the choice above, adjust. */
- if (max_vma - min_vma < 0x400000
- && max_vma - gp_val <= 0x200000
- && gp_val - min_vma > 0x200000)
- gp_val = min_vma + 0x200000;
- else if (max_short_vma != 0)
- {
- /* If we don't cover all the short data, adjust. */
- if (max_short_vma - gp_val >= 0x200000)
- gp_val = min_short_vma + 0x200000;
+ return TRUE;
+}
- /* If we're addressing stuff past the end, adjust back. */
- if (gp_val > max_vma)
- gp_val = max_vma - 0x200000 + 8;
- }
- }
+static bfd_boolean
+elfNN_ia64_final_link (abfd, info)
+ bfd *abfd;
+ struct bfd_link_info *info;
+{
+ struct elfNN_ia64_link_hash_table *ia64_info;
+ asection *unwind_output_sec;
- /* Validate whether all SHF_IA_64_SHORT sections are within
- range of the chosen GP. */
+ ia64_info = elfNN_ia64_hash_table (info);
- if (max_short_vma != 0)
+ /* Make sure we've got ourselves a nice fat __gp value. */
+ if (!info->relocatable)
+ {
+ bfd_vma gp_val = _bfd_get_gp_value (abfd);
+ struct elf_link_hash_entry *gp;
+
+ if (gp_val == 0)
{
- if (max_short_vma - min_short_vma >= 0x400000)
- {
- (*_bfd_error_handler)
- (_("%s: short data segment overflowed (0x%lx >= 0x400000)"),
- bfd_get_filename (abfd),
- (unsigned long) (max_short_vma - min_short_vma));
- return false;
- }
- else if ((gp_val > min_short_vma
- && gp_val - min_short_vma > 0x200000)
- || (gp_val < max_short_vma
- && max_short_vma - gp_val >= 0x200000))
- {
- (*_bfd_error_handler)
- (_("%s: __gp does not cover short data segment"),
- bfd_get_filename (abfd));
- return false;
- }
+ if (! elfNN_ia64_choose_gp (abfd, info))
+ return FALSE;
+ gp_val = _bfd_get_gp_value (abfd);
}
- _bfd_set_gp_value (abfd, gp_val);
-
+ gp = elf_link_hash_lookup (elf_hash_table (info), "__gp", FALSE,
+ FALSE, FALSE);
if (gp)
{
gp->root.type = bfd_link_hash_defined;
@@ -3596,7 +3828,7 @@ elfNN_ia64_final_link (abfd, info)
of the .IA_64.unwind section. Force this section to be relocated
into memory rather than written immediately to the output file. */
unwind_output_sec = NULL;
- if (!info->relocateable)
+ if (!info->relocatable)
{
asection *s = bfd_get_section_by_name (abfd, ELF_STRING_ia64_unwind);
if (s)
@@ -3605,13 +3837,13 @@ elfNN_ia64_final_link (abfd, info)
unwind_output_sec->contents
= bfd_malloc (unwind_output_sec->_raw_size);
if (unwind_output_sec->contents == NULL)
- return false;
+ return FALSE;
}
}
/* Invoke the regular ELF backend linker to do all the work. */
- if (!bfd_elfNN_bfd_final_link (abfd, info))
- return false;
+ if (!bfd_elf_final_link (abfd, info))
+ return FALSE;
if (unwind_output_sec)
{
@@ -3624,13 +3856,13 @@ elfNN_ia64_final_link (abfd, info)
if (! bfd_set_section_contents (abfd, unwind_output_sec,
unwind_output_sec->contents, (bfd_vma) 0,
unwind_output_sec->_raw_size))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
contents, relocs, local_syms, local_sections)
bfd *output_bfd;
@@ -3647,14 +3879,14 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
Elf_Internal_Rela *rel;
Elf_Internal_Rela *relend;
asection *srel;
- boolean ret_val = true; /* for non-fatal errors */
+ bfd_boolean ret_val = TRUE; /* for non-fatal errors */
bfd_vma gp_val;
symtab_hdr = &elf_tdata (input_bfd)->symtab_hdr;
ia64_info = elfNN_ia64_hash_table (info);
/* Infect various flags from the input section to the output section. */
- if (info->relocateable)
+ if (info->relocatable)
{
bfd_vma flags;
@@ -3663,11 +3895,11 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
elf_section_data(input_section->output_section)
->this_hdr.sh_flags |= flags;
- return true;
+ return TRUE;
}
gp_val = _bfd_get_gp_value (output_bfd);
- srel = get_reloc_section (input_bfd, ia64_info, input_section, false);
+ srel = get_reloc_section (input_bfd, ia64_info, input_section, FALSE);
rel = relocs;
relend = relocs + input_section->reloc_count;
@@ -3683,8 +3915,8 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
bfd_vma value;
asection *sym_sec;
bfd_byte *hit_addr;
- boolean dynamic_symbol_p;
- boolean undef_weak_ref;
+ bfd_boolean dynamic_symbol_p;
+ bfd_boolean undef_weak_ref;
r_type = ELFNN_R_TYPE (rel->r_info);
if (r_type > R_IA64_MAX_RELOC_CODE)
@@ -3693,7 +3925,7 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
(_("%s: unknown relocation type %d"),
bfd_archive_filename (input_bfd), (int)r_type);
bfd_set_error (bfd_error_bad_value);
- ret_val = false;
+ ret_val = FALSE;
continue;
}
@@ -3702,26 +3934,26 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
h = NULL;
sym = NULL;
sym_sec = NULL;
- undef_weak_ref = false;
+ undef_weak_ref = FALSE;
if (r_symndx < symtab_hdr->sh_info)
{
/* Reloc against local symbol. */
+ asection *msec;
sym = local_syms + r_symndx;
sym_sec = local_sections[r_symndx];
- value = _bfd_elf_rela_local_sym (output_bfd, sym, sym_sec, rel);
+ msec = sym_sec;
+ value = _bfd_elf_rela_local_sym (output_bfd, sym, &msec, rel);
if ((sym_sec->flags & SEC_MERGE)
&& ELF_ST_TYPE (sym->st_info) == STT_SECTION
- && (elf_section_data (sym_sec)->sec_info_type
- == ELF_INFO_TYPE_MERGE))
+ && sym_sec->sec_info_type == ELF_INFO_TYPE_MERGE)
{
struct elfNN_ia64_local_hash_entry *loc_h;
-
- loc_h = get_local_sym_hash (ia64_info, input_bfd, rel, false);
+
+ loc_h = get_local_sym_hash (ia64_info, input_bfd, rel, FALSE);
if (loc_h && ! loc_h->sec_merge_done)
{
struct elfNN_ia64_dyn_sym_info *dynent;
- asection *msec;
for (dynent = loc_h->info; dynent; dynent = dynent->next)
{
@@ -3745,59 +3977,24 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
}
else
{
- long indx;
-
- /* Reloc against global symbol. */
- indx = r_symndx - symtab_hdr->sh_info;
- h = elf_sym_hashes (input_bfd)[indx];
- while (h->root.type == bfd_link_hash_indirect
- || h->root.type == bfd_link_hash_warning)
- h = (struct elf_link_hash_entry *) h->root.u.i.link;
-
- value = 0;
- if (h->root.type == bfd_link_hash_defined
- || h->root.type == bfd_link_hash_defweak)
- {
- sym_sec = h->root.u.def.section;
-
- /* Detect the cases that sym_sec->output_section is
- expected to be NULL -- all cases in which the symbol
- is defined in another shared module. This includes
- PLT relocs for which we've created a PLT entry and
- other relocs for which we're prepared to create
- dynamic relocations. */
- /* ??? Just accept it NULL and continue. */
-
- if (sym_sec->output_section != NULL)
- {
- value = (h->root.u.def.value
- + sym_sec->output_section->vma
- + sym_sec->output_offset);
- }
- }
- else if (h->root.type == bfd_link_hash_undefweak)
- undef_weak_ref = true;
- else if (info->shared
- && (!info->symbolic || info->allow_shlib_undefined)
- && !info->no_undefined
- && ELF_ST_VISIBILITY (h->other) == STV_DEFAULT)
- ;
- else
- {
- if (! ((*info->callbacks->undefined_symbol)
- (info, h->root.root.string, input_bfd,
- input_section, rel->r_offset,
- (!info->shared || info->no_undefined
- || ELF_ST_VISIBILITY (h->other)))))
- return false;
- ret_val = false;
- continue;
- }
+ bfd_boolean unresolved_reloc;
+ bfd_boolean warned;
+ struct elf_link_hash_entry **sym_hashes = elf_sym_hashes (input_bfd);
+
+ RELOC_FOR_GLOBAL_SYMBOL (info, input_bfd, input_section, rel,
+ r_symndx, symtab_hdr, sym_hashes,
+ h, sym_sec, value,
+ unresolved_reloc, warned);
+
+ if (h->root.type == bfd_link_hash_undefweak)
+ undef_weak_ref = TRUE;
+ else if (warned)
+ continue;
}
hit_addr = contents + rel->r_offset;
value += rel->r_addend;
- dynamic_symbol_p = elfNN_ia64_dynamic_symbol_p (h, info);
+ dynamic_symbol_p = elfNN_ia64_dynamic_symbol_p (h, info, r_type);
switch (r_type)
{
@@ -3813,11 +4010,7 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
case R_IA64_DIR64MSB:
case R_IA64_DIR64LSB:
/* Install a dynamic relocation for this reloc. */
- if ((dynamic_symbol_p || info->shared
- || (elfNN_ia64_aix_vec (info->hash->creator)
- /* Don't emit relocs for __GLOB_DATA_PTR on AIX. */
- && (!h || strcmp (h->root.root.string,
- "__GLOB_DATA_PTR") != 0)))
+ if ((dynamic_symbol_p || info->shared)
&& r_symndx != 0
&& (input_section->flags & SEC_ALLOC) != 0)
{
@@ -3827,6 +4020,24 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
BFD_ASSERT (srel != NULL);
+ switch (r_type)
+ {
+ case R_IA64_IMM14:
+ case R_IA64_IMM22:
+ case R_IA64_IMM64:
+ /* ??? People shouldn't be doing non-pic code in
+ shared libraries nor dynamic executables. */
+ (*_bfd_error_handler)
+ (_("%s: non-pic code with imm relocation against dynamic symbol `%s'"),
+ bfd_archive_filename (input_bfd),
+ h->root.root.string);
+ ret_val = FALSE;
+ continue;
+
+ default:
+ break;
+ }
+
/* If we don't need dynamic symbol lookup, find a
matching RELATIVE relocation. */
dyn_r_type = r_type;
@@ -3854,29 +4065,17 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
break;
default:
- /* We can't represent this without a dynamic symbol.
- Adjust the relocation to be against an output
- section symbol, which are always present in the
- dynamic symbol table. */
- /* ??? People shouldn't be doing non-pic code in
- shared libraries. Hork. */
- (*_bfd_error_handler)
- (_("%s: linking non-pic code in a shared library"),
- bfd_archive_filename (input_bfd));
- ret_val = false;
- continue;
+ break;
}
dynindx = 0;
addend = value;
}
- if (elfNN_ia64_aix_vec (info->hash->creator))
- rel->r_addend = value;
elfNN_ia64_install_dyn_reloc (output_bfd, info, input_section,
srel, rel->r_offset, dyn_r_type,
dynindx, addend);
}
- /* FALLTHRU */
+ /* Fall through. */
case R_IA64_LTV32MSB:
case R_IA64_LTV32LSB:
@@ -3896,7 +4095,7 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
(*_bfd_error_handler)
(_("%s: @gprel relocation against dynamic symbol %s"),
bfd_archive_filename (input_bfd), h->root.root.string);
- ret_val = false;
+ ret_val = FALSE;
continue;
}
value -= gp_val;
@@ -3906,7 +4105,7 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
case R_IA64_LTOFF22:
case R_IA64_LTOFF22X:
case R_IA64_LTOFF64I:
- dyn_i = get_dyn_sym_info (ia64_info, h, input_bfd, rel, false);
+ dyn_i = get_dyn_sym_info (ia64_info, h, input_bfd, rel, FALSE);
value = set_got_entry (input_bfd, info, dyn_i, (h ? h->dynindx : -1),
rel->r_addend, value, R_IA64_DIR64LSB);
value -= gp_val;
@@ -3917,8 +4116,8 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
case R_IA64_PLTOFF64I:
case R_IA64_PLTOFF64MSB:
case R_IA64_PLTOFF64LSB:
- dyn_i = get_dyn_sym_info (ia64_info, h, input_bfd, rel, false);
- value = set_pltoff_entry (output_bfd, info, dyn_i, value, false);
+ dyn_i = get_dyn_sym_info (ia64_info, h, input_bfd, rel, FALSE);
+ value = set_pltoff_entry (output_bfd, info, dyn_i, value, FALSE);
value -= gp_val;
r = elfNN_ia64_install_value (output_bfd, hit_addr, value, r_type);
break;
@@ -3928,20 +4127,42 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
case R_IA64_FPTR32LSB:
case R_IA64_FPTR64MSB:
case R_IA64_FPTR64LSB:
- dyn_i = get_dyn_sym_info (ia64_info, h, input_bfd, rel, false);
+ dyn_i = get_dyn_sym_info (ia64_info, h, input_bfd, rel, FALSE);
if (dyn_i->want_fptr)
{
if (!undef_weak_ref)
value = set_fptr_entry (output_bfd, info, dyn_i, value);
}
- else
+ if (!dyn_i->want_fptr || info->pie)
{
long dynindx;
+ unsigned int dyn_r_type = r_type;
+ bfd_vma addend = rel->r_addend;
/* Otherwise, we expect the dynamic linker to create
the entry. */
- if (h)
+ if (dyn_i->want_fptr)
+ {
+ if (r_type == R_IA64_FPTR64I)
+ {
+ /* We can't represent this without a dynamic symbol.
+ Adjust the relocation to be against an output
+ section symbol, which are always present in the
+ dynamic symbol table. */
+ /* ??? People shouldn't be doing non-pic code in
+ shared libraries. Hork. */
+ (*_bfd_error_handler)
+ (_("%s: linking non-pic code in a position independent executable"),
+ bfd_archive_filename (input_bfd));
+ ret_val = FALSE;
+ continue;
+ }
+ dynindx = 0;
+ addend = value;
+ dyn_r_type = r_type + R_IA64_REL64LSB - R_IA64_FPTR64LSB;
+ }
+ else if (h)
{
if (h->dynindx != -1)
dynindx = h->dynindx;
@@ -3949,17 +4170,18 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
dynindx = (_bfd_elf_link_lookup_local_dynindx
(info, h->root.u.def.section->owner,
global_sym_index (h)));
+ value = 0;
}
else
{
dynindx = (_bfd_elf_link_lookup_local_dynindx
(info, input_bfd, (long) r_symndx));
+ value = 0;
}
elfNN_ia64_install_dyn_reloc (output_bfd, info, input_section,
- srel, rel->r_offset, r_type,
- dynindx, rel->r_addend);
- value = 0;
+ srel, rel->r_offset, dyn_r_type,
+ dynindx, addend);
}
r = elfNN_ia64_install_value (output_bfd, hit_addr, value, r_type);
@@ -3974,7 +4196,7 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
{
long dynindx;
- dyn_i = get_dyn_sym_info (ia64_info, h, input_bfd, rel, false);
+ dyn_i = get_dyn_sym_info (ia64_info, h, input_bfd, rel, FALSE);
if (dyn_i->want_fptr)
{
BFD_ASSERT (h == NULL || h->dynindx == -1)
@@ -4013,9 +4235,7 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
case R_IA64_PCREL64MSB:
case R_IA64_PCREL64LSB:
/* Install a dynamic relocation for this reloc. */
- if ((dynamic_symbol_p
- || elfNN_ia64_aix_vec (info->hash->creator))
- && r_symndx != 0)
+ if (dynamic_symbol_p && r_symndx != 0)
{
BFD_ASSERT (srel != NULL);
@@ -4025,35 +4245,12 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
}
goto finish_pcrel;
- case R_IA64_PCREL21BI:
- case R_IA64_PCREL21F:
- case R_IA64_PCREL21M:
- /* ??? These two are only used for speculation fixup code.
- They should never be dynamic. */
- if (dynamic_symbol_p)
- {
- (*_bfd_error_handler)
- (_("%s: dynamic relocation against speculation fixup"),
- bfd_archive_filename (input_bfd));
- ret_val = false;
- continue;
- }
- if (undef_weak_ref)
- {
- (*_bfd_error_handler)
- (_("%s: speculation fixup against undefined weak symbol"),
- bfd_archive_filename (input_bfd));
- ret_val = false;
- continue;
- }
- goto finish_pcrel;
-
case R_IA64_PCREL21B:
case R_IA64_PCREL60B:
/* We should have created a PLT entry for any dynamic symbol. */
dyn_i = NULL;
if (h)
- dyn_i = get_dyn_sym_info (ia64_info, h, NULL, NULL, false);
+ dyn_i = get_dyn_sym_info (ia64_info, h, NULL, NULL, FALSE);
if (dyn_i && dyn_i->want_plt2)
{
@@ -4079,8 +4276,32 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
}
goto finish_pcrel;
+ case R_IA64_PCREL21BI:
+ case R_IA64_PCREL21F:
+ case R_IA64_PCREL21M:
case R_IA64_PCREL22:
case R_IA64_PCREL64I:
+ /* The PCREL21BI reloc is specifically not intended for use with
+ dynamic relocs. PCREL21F and PCREL21M are used for speculation
+ fixup code, and thus probably ought not be dynamic. The
+ PCREL22 and PCREL64I relocs aren't emitted as dynamic relocs. */
+ if (dynamic_symbol_p)
+ {
+ const char *msg;
+
+ if (r_type == R_IA64_PCREL21BI)
+ msg = _("%s: @internal branch to dynamic symbol %s");
+ else if (r_type == R_IA64_PCREL21F || r_type == R_IA64_PCREL21M)
+ msg = _("%s: speculation fixup to dynamic symbol %s");
+ else
+ msg = _("%s: @pcrel relocation against dynamic symbol %s");
+ (*_bfd_error_handler) (msg, bfd_archive_filename (input_bfd),
+ h->root.root.string);
+ ret_val = FALSE;
+ continue;
+ }
+ goto finish_pcrel;
+
finish_pcrel:
/* Make pc-relative. */
value -= (input_section->output_section->vma
@@ -4112,7 +4333,7 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
{
int i;
for (i = m->count - 1; i >= 0; i--)
- if (m->sections[i] == sym_sec->output_section)
+ if (m->sections[i] == input_section->output_section)
break;
if (i >= 0)
break;
@@ -4158,7 +4379,7 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
/* If we don't need dynamic symbol lookup, install two
RELATIVE relocations. */
- if (! dynamic_symbol_p)
+ if (!dynamic_symbol_p)
{
unsigned int dyn_r_type;
@@ -4201,6 +4422,8 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
case R_IA64_DTPREL14:
case R_IA64_DTPREL22:
case R_IA64_DTPREL64I:
+ case R_IA64_DTPREL64LSB:
+ case R_IA64_DTPREL64MSB:
value -= elfNN_ia64_dtprel_base (info);
r = elfNN_ia64_install_value (output_bfd, hit_addr, value, r_type);
break;
@@ -4210,13 +4433,23 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
case R_IA64_LTOFF_DTPREL22:
{
int got_r_type;
+ long dynindx = h ? h->dynindx : -1;
+ bfd_vma r_addend = rel->r_addend;
switch (r_type)
{
default:
case R_IA64_LTOFF_TPREL22:
- if (!dynamic_symbol_p && !info->shared)
- value -= elfNN_ia64_tprel_base (info);
+ if (!dynamic_symbol_p)
+ {
+ if (!info->shared)
+ value -= elfNN_ia64_tprel_base (info);
+ else
+ {
+ r_addend += value - elfNN_ia64_dtprel_base (info);
+ dynindx = 0;
+ }
+ }
got_r_type = R_IA64_TPREL64LSB;
break;
case R_IA64_LTOFF_DTPMOD22:
@@ -4230,9 +4463,8 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
got_r_type = R_IA64_DTPREL64LSB;
break;
}
- dyn_i = get_dyn_sym_info (ia64_info, h, input_bfd, rel, false);
- value = set_got_entry (input_bfd, info, dyn_i,
- (h ? h->dynindx : -1), rel->r_addend,
+ dyn_i = get_dyn_sym_info (ia64_info, h, input_bfd, rel, FALSE);
+ value = set_got_entry (input_bfd, info, dyn_i, dynindx, r_addend,
value, got_r_type);
value -= gp_val;
r = elfNN_ia64_install_value (output_bfd, hit_addr, value,
@@ -4256,7 +4488,7 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
don't try to continue. */
(*info->callbacks->undefined_symbol)
(info, "__gp", input_bfd, input_section, rel->r_offset, 1);
- return false;
+ return FALSE;
case bfd_reloc_notsupported:
{
@@ -4270,15 +4502,15 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
symtab_hdr->sh_link,
sym->st_name);
if (name == NULL)
- return false;
+ return FALSE;
if (*name == '\0')
name = bfd_section_name (input_bfd, input_section);
}
if (!(*info->callbacks->warning) (info, _("unsupported reloc"),
name, input_bfd,
input_section, rel->r_offset))
- return false;
- ret_val = false;
+ return FALSE;
+ ret_val = FALSE;
}
break;
@@ -4297,7 +4529,7 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
symtab_hdr->sh_link,
sym->st_name);
if (name == NULL)
- return false;
+ return FALSE;
if (*name == '\0')
name = bfd_section_name (input_bfd, input_section);
}
@@ -4307,8 +4539,8 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
input_bfd,
input_section,
rel->r_offset))
- return false;
- ret_val = false;
+ return FALSE;
+ ret_val = FALSE;
}
break;
}
@@ -4317,7 +4549,7 @@ elfNN_ia64_relocate_section (output_bfd, info, input_bfd, input_section,
return ret_val;
}
-static boolean
+static bfd_boolean
elfNN_ia64_finish_dynamic_symbol (output_bfd, info, h, sym)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -4328,7 +4560,7 @@ elfNN_ia64_finish_dynamic_symbol (output_bfd, info, h, sym)
struct elfNN_ia64_dyn_sym_info *dyn_i;
ia64_info = elfNN_ia64_hash_table (info);
- dyn_i = get_dyn_sym_info (ia64_info, h, NULL, NULL, false);
+ dyn_i = get_dyn_sym_info (ia64_info, h, NULL, NULL, FALSE);
/* Fill in the PLT data, if required. */
if (dyn_i && dyn_i->want_plt)
@@ -4337,7 +4569,6 @@ elfNN_ia64_finish_dynamic_symbol (output_bfd, info, h, sym)
bfd_byte *loc;
asection *plt_sec;
bfd_vma plt_addr, pltoff_addr, gp_val, index;
- ElfNN_External_Rela *rel;
gp_val = _bfd_get_gp_value (output_bfd);
@@ -4355,7 +4586,7 @@ elfNN_ia64_finish_dynamic_symbol (output_bfd, info, h, sym)
plt_addr = (plt_sec->output_section->vma
+ plt_sec->output_offset
+ dyn_i->plt_offset);
- pltoff_addr = set_pltoff_entry (output_bfd, info, dyn_i, plt_addr, true);
+ pltoff_addr = set_pltoff_entry (output_bfd, info, dyn_i, plt_addr, TRUE);
/* Initialize the FULL PLT entry, if needed. */
if (dyn_i->want_plt2)
@@ -4369,7 +4600,7 @@ elfNN_ia64_finish_dynamic_symbol (output_bfd, info, h, sym)
/* Mark the symbol as undefined, rather than as defined in the
plt section. Leave the value alone. */
/* ??? We didn't redefine it in adjust_dynamic_symbol in the
- first place. But perhaps elflink.h did some for us. */
+ first place. But perhaps elflink.c did some for us. */
if ((h->elf_link_hash_flags & ELF_LINK_HASH_DEF_REGULAR) == 0)
sym->st_shndx = SHN_UNDEF;
}
@@ -4394,10 +4625,10 @@ elfNN_ia64_finish_dynamic_symbol (output_bfd, info, h, sym)
existing sec->reloc_count to be the base of the array of
PLT relocations. */
- rel = (ElfNN_External_Rela *)ia64_info->rel_pltoff_sec->contents;
- rel += ia64_info->rel_pltoff_sec->reloc_count;
-
- bfd_elfNN_swap_reloca_out (output_bfd, &outrel, rel + index);
+ loc = ia64_info->rel_pltoff_sec->contents;
+ loc += ((ia64_info->rel_pltoff_sec->reloc_count + index)
+ * sizeof (ElfNN_External_Rela));
+ bfd_elfNN_swap_reloca_out (output_bfd, &outrel, loc);
}
/* Mark some specially defined symbols as absolute. */
@@ -4406,10 +4637,10 @@ elfNN_ia64_finish_dynamic_symbol (output_bfd, info, h, sym)
|| strcmp (h->root.root.string, "_PROCEDURE_LINKAGE_TABLE_") == 0)
sym->st_shndx = SHN_ABS;
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
elfNN_ia64_finish_dynamic_sections (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -4475,7 +4706,7 @@ elfNN_ia64_finish_dynamic_sections (abfd, info)
bfd_elfNN_swap_dyn_out (abfd, &dyn, dyncon);
}
- /* Initialize the PLT0 entry */
+ /* Initialize the PLT0 entry. */
if (ia64_info->plt_sec)
{
bfd_byte *loc = ia64_info->plt_sec->contents;
@@ -4491,13 +4722,13 @@ elfNN_ia64_finish_dynamic_sections (abfd, info)
}
}
- return true;
+ return TRUE;
}
-/* ELF file flag handling: */
+/* ELF file flag handling: */
/* Function to keep IA-64 specific file flags. */
-static boolean
+static bfd_boolean
elfNN_ia64_set_private_flags (abfd, flags)
bfd *abfd;
flagword flags;
@@ -4506,31 +4737,31 @@ elfNN_ia64_set_private_flags (abfd, flags)
|| elf_elfheader (abfd)->e_flags == flags);
elf_elfheader (abfd)->e_flags = flags;
- elf_flags_init (abfd) = true;
- return true;
+ elf_flags_init (abfd) = TRUE;
+ return TRUE;
}
/* Merge backend specific data from an object file to the output
object file when linking. */
-static boolean
+static bfd_boolean
elfNN_ia64_merge_private_bfd_data (ibfd, obfd)
bfd *ibfd, *obfd;
{
flagword out_flags;
flagword in_flags;
- boolean ok = true;
+ bfd_boolean ok = TRUE;
/* Don't even pretend to support mixed-format linking. */
if (bfd_get_flavour (ibfd) != bfd_target_elf_flavour
|| bfd_get_flavour (obfd) != bfd_target_elf_flavour)
- return false;
+ return FALSE;
in_flags = elf_elfheader (ibfd)->e_flags;
out_flags = elf_elfheader (obfd)->e_flags;
if (! elf_flags_init (obfd))
{
- elf_flags_init (obfd) = true;
+ elf_flags_init (obfd) = TRUE;
elf_elfheader (obfd)->e_flags = in_flags;
if (bfd_get_arch (obfd) == bfd_get_arch (ibfd)
@@ -4540,12 +4771,12 @@ elfNN_ia64_merge_private_bfd_data (ibfd, obfd)
bfd_get_mach (ibfd));
}
- return true;
+ return TRUE;
}
/* Check flag compatibility. */
if (in_flags == out_flags)
- return true;
+ return TRUE;
/* Output has EF_IA_64_REDUCEDFP set only if all inputs have it set. */
if (!(in_flags & EF_IA_64_REDUCEDFP) && (out_flags & EF_IA_64_REDUCEDFP))
@@ -4558,7 +4789,7 @@ elfNN_ia64_merge_private_bfd_data (ibfd, obfd)
bfd_archive_filename (ibfd));
bfd_set_error (bfd_error_bad_value);
- ok = false;
+ ok = FALSE;
}
if ((in_flags & EF_IA_64_BE) != (out_flags & EF_IA_64_BE))
{
@@ -4567,7 +4798,7 @@ elfNN_ia64_merge_private_bfd_data (ibfd, obfd)
bfd_archive_filename (ibfd));
bfd_set_error (bfd_error_bad_value);
- ok = false;
+ ok = FALSE;
}
if ((in_flags & EF_IA_64_ABI64) != (out_flags & EF_IA_64_ABI64))
{
@@ -4576,7 +4807,7 @@ elfNN_ia64_merge_private_bfd_data (ibfd, obfd)
bfd_archive_filename (ibfd));
bfd_set_error (bfd_error_bad_value);
- ok = false;
+ ok = FALSE;
}
if ((in_flags & EF_IA_64_CONS_GP) != (out_flags & EF_IA_64_CONS_GP))
{
@@ -4585,7 +4816,7 @@ elfNN_ia64_merge_private_bfd_data (ibfd, obfd)
bfd_archive_filename (ibfd));
bfd_set_error (bfd_error_bad_value);
- ok = false;
+ ok = FALSE;
}
if ((in_flags & EF_IA_64_NOFUNCDESC_CONS_GP)
!= (out_flags & EF_IA_64_NOFUNCDESC_CONS_GP))
@@ -4595,13 +4826,13 @@ elfNN_ia64_merge_private_bfd_data (ibfd, obfd)
bfd_archive_filename (ibfd));
bfd_set_error (bfd_error_bad_value);
- ok = false;
+ ok = FALSE;
}
return ok;
}
-static boolean
+static bfd_boolean
elfNN_ia64_print_private_bfd_data (abfd, ptr)
bfd *abfd;
PTR ptr;
@@ -4622,7 +4853,7 @@ elfNN_ia64_print_private_bfd_data (abfd, ptr)
(flags & EF_IA_64_ABI64) ? "ABI64" : "ABI32");
_bfd_elf_print_private_bfd_data (abfd, ptr);
- return true;
+ return TRUE;
}
static enum elf_reloc_type_class
@@ -4646,7 +4877,14 @@ elfNN_ia64_reloc_type_class (rela)
}
}
-static boolean
+static struct bfd_elf_special_section const elfNN_ia64_special_sections[]=
+{
+ { ".sbss", 5, -1, SHT_NOBITS, SHF_ALLOC + SHF_WRITE + SHF_IA_64_SHORT },
+ { ".sdata", 6, -1, SHT_PROGBITS, SHF_ALLOC + SHF_WRITE + SHF_IA_64_SHORT },
+ { NULL, 0, 0, 0, 0 }
+};
+
+static bfd_boolean
elfNN_ia64_hpux_vec (const bfd_target *vec)
{
extern const bfd_target bfd_elfNN_ia64_hpux_big_vec;
@@ -4664,7 +4902,7 @@ elfNN_hpux_post_process_headers (abfd, info)
i_ehdrp->e_ident[EI_ABIVERSION] = 1;
}
-boolean
+bfd_boolean
elfNN_hpux_backend_section_from_bfd_section (abfd, sec, retval)
bfd *abfd ATTRIBUTE_UNUSED;
asection *sec;
@@ -4673,10 +4911,27 @@ elfNN_hpux_backend_section_from_bfd_section (abfd, sec, retval)
if (bfd_is_com_section (sec))
{
*retval = SHN_IA_64_ANSI_COMMON;
- return true;
+ return TRUE;
+ }
+ return FALSE;
+}
+
+static void
+elfNN_hpux_backend_symbol_processing (bfd *abfd ATTRIBUTE_UNUSED,
+ asymbol *asym)
+{
+ elf_symbol_type *elfsym = (elf_symbol_type *) asym;;
+
+ switch (elfsym->internal_elf_sym.st_shndx)
+ {
+ case SHN_IA_64_ANSI_COMMON:
+ asym->section = bfd_com_section_ptr;
+ asym->value = elfsym->internal_elf_sym.st_size;
+ asym->flags &= ~BSF_GLOBAL;
+ break;
}
- return false;
}
+
#define TARGET_LITTLE_SYM bfd_elfNN_ia64_little_vec
#define TARGET_LITTLE_NAME "elfNN-ia64-little"
@@ -4715,6 +4970,8 @@ elfNN_hpux_backend_section_from_bfd_section (abfd, sec, retval)
/* Stuff for the BFD linker: */
#define bfd_elfNN_bfd_link_hash_table_create \
elfNN_ia64_hash_table_create
+#define bfd_elfNN_bfd_link_hash_table_free \
+ elfNN_ia64_hash_table_free
#define elf_backend_create_dynamic_sections \
elfNN_ia64_create_dynamic_sections
#define elf_backend_check_relocs \
@@ -4743,7 +5000,6 @@ elfNN_hpux_backend_section_from_bfd_section (abfd, sec, retval)
#define elf_backend_want_plt_sym 0
#define elf_backend_plt_alignment 5
#define elf_backend_got_header_size 0
-#define elf_backend_plt_header_size PLT_HEADER_SIZE
#define elf_backend_want_got_plt 1
#define elf_backend_may_use_rel_p 1
#define elf_backend_may_use_rela_p 1
@@ -4753,27 +5009,7 @@ elfNN_hpux_backend_section_from_bfd_section (abfd, sec, retval)
#define elf_backend_hide_symbol elfNN_ia64_hash_hide_symbol
#define elf_backend_reloc_type_class elfNN_ia64_reloc_type_class
#define elf_backend_rela_normal 1
-
-#include "elfNN-target.h"
-
-/* AIX-specific vectors. */
-
-#undef TARGET_LITTLE_SYM
-#define TARGET_LITTLE_SYM bfd_elfNN_ia64_aix_little_vec
-#undef TARGET_LITTLE_NAME
-#define TARGET_LITTLE_NAME "elfNN-ia64-aix-little"
-#undef TARGET_BIG_SYM
-#define TARGET_BIG_SYM bfd_elfNN_ia64_aix_big_vec
-#undef TARGET_BIG_NAME
-#define TARGET_BIG_NAME "elfNN-ia64-aix-big"
-
-#undef elf_backend_add_symbol_hook
-#define elf_backend_add_symbol_hook elfNN_ia64_aix_add_symbol_hook
-
-#undef bfd_elfNN_bfd_link_add_symbols
-#define bfd_elfNN_bfd_link_add_symbols elfNN_ia64_aix_link_add_symbols
-
-#define elfNN_bed elfNN_ia64_aix_bed
+#define elf_backend_special_sections elfNN_ia64_special_sections
#include "elfNN-target.h"
@@ -4786,14 +5022,6 @@ elfNN_hpux_backend_section_from_bfd_section (abfd, sec, retval)
#undef TARGET_BIG_NAME
#define TARGET_BIG_NAME "elfNN-ia64-hpux-big"
-/* We need to undo the AIX specific functions. */
-
-#undef elf_backend_add_symbol_hook
-#define elf_backend_add_symbol_hook elfNN_ia64_add_symbol_hook
-
-#undef bfd_elfNN_bfd_link_add_symbols
-#define bfd_elfNN_bfd_link_add_symbols _bfd_generic_link_add_symbols
-
/* These are HP-UX specific functions. */
#undef elf_backend_post_process_headers
@@ -4802,6 +5030,9 @@ elfNN_hpux_backend_section_from_bfd_section (abfd, sec, retval)
#undef elf_backend_section_from_bfd_section
#define elf_backend_section_from_bfd_section elfNN_hpux_backend_section_from_bfd_section
+#undef elf_backend_symbol_processing
+#define elf_backend_symbol_processing elfNN_hpux_backend_symbol_processing
+
#undef elf_backend_want_p_paddr_set_to_zero
#define elf_backend_want_p_paddr_set_to_zero 1
diff --git a/contrib/binutils/bfd/elfxx-target.h b/contrib/binutils/bfd/elfxx-target.h
index 5d7efb0..e250a97 100644
--- a/contrib/binutils/bfd/elfxx-target.h
+++ b/contrib/binutils/bfd/elfxx-target.h
@@ -1,22 +1,22 @@
/* Target definitions for NN-bit ELF
- Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
- Free Software Foundation, Inc.
+ Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+ 2003 Free Software Foundation, Inc.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* This structure contains everything that BFD knows about a target.
It includes things like its byte order, name, what routines to call
@@ -32,14 +32,18 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define bfd_elfNN_get_section_contents _bfd_generic_get_section_contents
#endif
-#define bfd_elfNN_canonicalize_dynamic_symtab _bfd_elf_canonicalize_dynamic_symtab
+#define bfd_elfNN_canonicalize_dynamic_symtab \
+ _bfd_elf_canonicalize_dynamic_symtab
+#ifndef bfd_elfNN_canonicalize_reloc
#define bfd_elfNN_canonicalize_reloc _bfd_elf_canonicalize_reloc
+#endif
#ifndef bfd_elfNN_find_nearest_line
#define bfd_elfNN_find_nearest_line _bfd_elf_find_nearest_line
#endif
#define bfd_elfNN_read_minisymbols _bfd_elf_read_minisymbols
#define bfd_elfNN_minisymbol_to_symbol _bfd_elf_minisymbol_to_symbol
-#define bfd_elfNN_get_dynamic_symtab_upper_bound _bfd_elf_get_dynamic_symtab_upper_bound
+#define bfd_elfNN_get_dynamic_symtab_upper_bound \
+ _bfd_elf_get_dynamic_symtab_upper_bound
#define bfd_elfNN_get_lineno _bfd_elf_get_lineno
#ifndef bfd_elfNN_get_reloc_upper_bound
#define bfd_elfNN_get_reloc_upper_bound _bfd_elf_get_reloc_upper_bound
@@ -47,13 +51,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef bfd_elfNN_get_symbol_info
#define bfd_elfNN_get_symbol_info _bfd_elf_get_symbol_info
#endif
-#define bfd_elfNN_get_symtab _bfd_elf_get_symtab
+#define bfd_elfNN_canonicalize_symtab _bfd_elf_canonicalize_symtab
#define bfd_elfNN_get_symtab_upper_bound _bfd_elf_get_symtab_upper_bound
-#if 0 /* done in elf-bfd.h */
-#define bfd_elfNN_link_record_dynamic_symbol _bfd_elf_link_record_dynamic_symbol
-#endif
#define bfd_elfNN_make_empty_symbol _bfd_elf_make_empty_symbol
+#ifndef bfd_elfNN_new_section_hook
#define bfd_elfNN_new_section_hook _bfd_elf_new_section_hook
+#endif
#define bfd_elfNN_set_arch_mach _bfd_elf_set_arch_mach
#ifndef bfd_elfNN_set_section_contents
#define bfd_elfNN_set_section_contents _bfd_elf_set_section_contents
@@ -96,11 +99,11 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define bfd_elfNN_bfd_debug_info_start bfd_void
#define bfd_elfNN_bfd_debug_info_end bfd_void
#define bfd_elfNN_bfd_debug_info_accumulate \
- (void (*) PARAMS ((bfd*, struct sec *))) bfd_void
+ ((void (*) (bfd*, struct bfd_section *)) bfd_void)
#ifndef bfd_elfNN_bfd_get_relocated_section_contents
#define bfd_elfNN_bfd_get_relocated_section_contents \
- bfd_generic_get_relocated_section_contents
+ bfd_generic_get_relocated_section_contents
#endif
#ifndef bfd_elfNN_bfd_relax_section
@@ -123,7 +126,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define elf_backend_gc_sweep_hook NULL
#endif
#ifndef bfd_elfNN_bfd_gc_sections
-#define bfd_elfNN_bfd_gc_sections _bfd_elfNN_gc_sections
+#define bfd_elfNN_bfd_gc_sections bfd_elf_gc_sections
#endif
#ifndef bfd_elfNN_bfd_merge_sections
@@ -137,7 +140,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef bfd_elfNN_bfd_make_debug_symbol
#define bfd_elfNN_bfd_make_debug_symbol \
- ((asymbol *(*) PARAMS ((bfd *, void *, unsigned long))) bfd_nullvoidptr)
+ ((asymbol * (*) (bfd *, void *, unsigned long)) bfd_nullvoidptr)
#endif
#ifndef bfd_elfNN_bfd_copy_private_symbol_data
@@ -159,11 +162,11 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#endif
#ifndef bfd_elfNN_bfd_merge_private_bfd_data
#define bfd_elfNN_bfd_merge_private_bfd_data \
- ((boolean (*) PARAMS ((bfd *, bfd *))) bfd_true)
+ ((bfd_boolean (*) (bfd *, bfd *)) bfd_true)
#endif
#ifndef bfd_elfNN_bfd_set_private_flags
#define bfd_elfNN_bfd_set_private_flags \
- ((boolean (*) PARAMS ((bfd *, flagword))) bfd_true)
+ ((bfd_boolean (*) (bfd *, flagword)) bfd_true)
#endif
#ifndef bfd_elfNN_bfd_is_local_label_name
#define bfd_elfNN_bfd_is_local_label_name _bfd_elf_is_local_label_name
@@ -186,6 +189,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef bfd_elfNN_bfd_link_hash_table_create
#define bfd_elfNN_bfd_link_hash_table_create _bfd_elf_link_hash_table_create
#endif
+#ifndef bfd_elfNN_bfd_link_add_symbols
+#define bfd_elfNN_bfd_link_add_symbols bfd_elf_link_add_symbols
+#endif
+#ifndef bfd_elfNN_bfd_final_link
+#define bfd_elfNN_bfd_final_link bfd_elf_final_link
+#endif
#else /* ! defined (elf_backend_relocate_section) */
/* If no backend relocate_section routine, use the generic linker.
Note - this will prevent the port from being able to use some of
@@ -232,6 +241,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define bfd_elfNN_mkarchive _bfd_generic_mkarchive
#endif
+#ifndef bfd_elfNN_print_symbol
+#define bfd_elfNN_print_symbol bfd_elf_print_symbol
+#endif
+
#ifndef elf_symbol_leading_char
#define elf_symbol_leading_char 0
#endif
@@ -250,10 +263,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#endif
#ifndef elf_backend_collect
-#define elf_backend_collect false
+#define elf_backend_collect FALSE
#endif
#ifndef elf_backend_type_change_ok
-#define elf_backend_type_change_ok false
+#define elf_backend_type_change_ok FALSE
#endif
#ifndef elf_backend_sym_is_global
@@ -271,6 +284,9 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef elf_backend_get_symbol_type
#define elf_backend_get_symbol_type 0
#endif
+#ifndef elf_backend_name_local_section_symbols
+#define elf_backend_name_local_section_symbols 0
+#endif
#ifndef elf_backend_section_processing
#define elf_backend_section_processing 0
#endif
@@ -334,12 +350,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef elf_backend_ecoff_debug_swap
#define elf_backend_ecoff_debug_swap 0
#endif
+#ifndef elf_backend_bfd_from_remote_memory
+#define elf_backend_bfd_from_remote_memory _bfd_elfNN_bfd_from_remote_memory
+#endif
#ifndef elf_backend_got_header_size
#define elf_backend_got_header_size 0
#endif
-#ifndef elf_backend_plt_header_size
-#define elf_backend_plt_header_size 0
-#endif
#ifndef elf_backend_post_process_headers
#define elf_backend_post_process_headers NULL
#endif
@@ -355,6 +371,9 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef elf_backend_hide_symbol
#define elf_backend_hide_symbol _bfd_elf_link_hash_hide_symbol
#endif
+#ifndef elf_backend_merge_symbol_attribute
+#define elf_backend_merge_symbol_attribute NULL
+#endif
#ifndef elf_backend_emit_relocs
#define elf_backend_emit_relocs NULL
#endif
@@ -382,6 +401,15 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef elf_backend_ignore_discarded_relocs
#define elf_backend_ignore_discarded_relocs NULL
#endif
+#ifndef elf_backend_can_make_relative_eh_frame
+#define elf_backend_can_make_relative_eh_frame _bfd_elf_can_make_relative
+#endif
+#ifndef elf_backend_can_make_lsda_relative_eh_frame
+#define elf_backend_can_make_lsda_relative_eh_frame _bfd_elf_can_make_relative
+#endif
+#ifndef elf_backend_encode_eh_address
+#define elf_backend_encode_eh_address _bfd_elf_encode_eh_address
+#endif
#ifndef elf_backend_write_section
#define elf_backend_write_section NULL
#endif
@@ -398,9 +426,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
For backwards compatibility, we still support this usage. */
#ifndef USE_REL
#define USE_REL 0
-#else
-#undef USE_REL
-#define USE_REL 1
#endif
/* Use these in new code. */
@@ -430,6 +455,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define elf_backend_size_info _bfd_elfNN_size_info
#endif
+#ifndef elf_backend_special_sections
+#define elf_backend_special_sections NULL
+#endif
+
#ifndef elf_backend_sign_extend_vma
#define elf_backend_sign_extend_vma 0
#endif
@@ -449,6 +478,7 @@ static const struct elf_backend_data elfNN_bed =
elf_backend_symbol_processing,
elf_backend_symbol_table_processing,
elf_backend_get_symbol_type,
+ elf_backend_name_local_section_symbols,
elf_backend_section_processing,
elf_backend_section_from_shdr,
elf_backend_section_flags,
@@ -476,6 +506,7 @@ static const struct elf_backend_data elfNN_bed =
elf_backend_output_arch_syms,
elf_backend_copy_indirect_symbol,
elf_backend_hide_symbol,
+ elf_backend_merge_symbol_attribute,
elf_backend_emit_relocs,
elf_backend_count_relocs,
elf_backend_grok_prstatus,
@@ -485,16 +516,20 @@ static const struct elf_backend_data elfNN_bed =
elf_backend_reloc_type_class,
elf_backend_discard_info,
elf_backend_ignore_discarded_relocs,
+ elf_backend_can_make_relative_eh_frame,
+ elf_backend_can_make_lsda_relative_eh_frame,
+ elf_backend_encode_eh_address,
elf_backend_write_section,
elf_backend_mips_irix_compat,
elf_backend_mips_rtype_to_howto,
elf_backend_ecoff_debug_swap,
+ elf_backend_bfd_from_remote_memory,
ELF_MACHINE_ALT1,
ELF_MACHINE_ALT2,
&elf_backend_size_info,
+ elf_backend_special_sections,
elf_backend_got_symbol_offset,
elf_backend_got_header_size,
- elf_backend_plt_header_size,
elf_backend_collect,
elf_backend_type_change_ok,
elf_backend_may_use_rel_p,
@@ -590,19 +625,19 @@ const bfd_target TARGET_BIG_SYM =
bfd_elfNN_write_corefile_contents,
},
- BFD_JUMP_TABLE_GENERIC (bfd_elfNN),
- BFD_JUMP_TABLE_COPY (bfd_elfNN),
- BFD_JUMP_TABLE_CORE (bfd_elfNN),
+ BFD_JUMP_TABLE_GENERIC (bfd_elfNN),
+ BFD_JUMP_TABLE_COPY (bfd_elfNN),
+ BFD_JUMP_TABLE_CORE (bfd_elfNN),
#ifdef bfd_elfNN_archive_functions
- BFD_JUMP_TABLE_ARCHIVE (bfd_elfNN_archive),
+ BFD_JUMP_TABLE_ARCHIVE (bfd_elfNN_archive),
#else
- BFD_JUMP_TABLE_ARCHIVE (_bfd_archive_coff),
+ BFD_JUMP_TABLE_ARCHIVE (_bfd_archive_coff),
#endif
- BFD_JUMP_TABLE_SYMBOLS (bfd_elfNN),
- BFD_JUMP_TABLE_RELOCS (bfd_elfNN),
- BFD_JUMP_TABLE_WRITE (bfd_elfNN),
- BFD_JUMP_TABLE_LINK (bfd_elfNN),
- BFD_JUMP_TABLE_DYNAMIC (bfd_elfNN),
+ BFD_JUMP_TABLE_SYMBOLS (bfd_elfNN),
+ BFD_JUMP_TABLE_RELOCS (bfd_elfNN),
+ BFD_JUMP_TABLE_WRITE (bfd_elfNN),
+ BFD_JUMP_TABLE_LINK (bfd_elfNN),
+ BFD_JUMP_TABLE_DYNAMIC (bfd_elfNN),
/* Alternative endian target. */
#ifdef TARGET_LITTLE_SYM
@@ -612,7 +647,7 @@ const bfd_target TARGET_BIG_SYM =
#endif
/* backend_data: */
- (PTR) &elfNN_bed
+ &elfNN_bed
};
#endif
@@ -686,19 +721,19 @@ const bfd_target TARGET_LITTLE_SYM =
bfd_elfNN_write_corefile_contents,
},
- BFD_JUMP_TABLE_GENERIC (bfd_elfNN),
- BFD_JUMP_TABLE_COPY (bfd_elfNN),
- BFD_JUMP_TABLE_CORE (bfd_elfNN),
+ BFD_JUMP_TABLE_GENERIC (bfd_elfNN),
+ BFD_JUMP_TABLE_COPY (bfd_elfNN),
+ BFD_JUMP_TABLE_CORE (bfd_elfNN),
#ifdef bfd_elfNN_archive_functions
- BFD_JUMP_TABLE_ARCHIVE (bfd_elfNN_archive),
+ BFD_JUMP_TABLE_ARCHIVE (bfd_elfNN_archive),
#else
- BFD_JUMP_TABLE_ARCHIVE (_bfd_archive_coff),
+ BFD_JUMP_TABLE_ARCHIVE (_bfd_archive_coff),
#endif
- BFD_JUMP_TABLE_SYMBOLS (bfd_elfNN),
- BFD_JUMP_TABLE_RELOCS (bfd_elfNN),
- BFD_JUMP_TABLE_WRITE (bfd_elfNN),
- BFD_JUMP_TABLE_LINK (bfd_elfNN),
- BFD_JUMP_TABLE_DYNAMIC (bfd_elfNN),
+ BFD_JUMP_TABLE_SYMBOLS (bfd_elfNN),
+ BFD_JUMP_TABLE_RELOCS (bfd_elfNN),
+ BFD_JUMP_TABLE_WRITE (bfd_elfNN),
+ BFD_JUMP_TABLE_LINK (bfd_elfNN),
+ BFD_JUMP_TABLE_DYNAMIC (bfd_elfNN),
/* Alternative endian target. */
#ifdef TARGET_BIG_SYM
@@ -708,6 +743,6 @@ const bfd_target TARGET_LITTLE_SYM =
#endif
/* backend_data: */
- (PTR) &elfNN_bed
+ &elfNN_bed
};
#endif
diff --git a/contrib/binutils/bfd/format.c b/contrib/binutils/bfd/format.c
index ef6b46e..9d9ee86 100644
--- a/contrib/binutils/bfd/format.c
+++ b/contrib/binutils/bfd/format.c
@@ -1,23 +1,23 @@
/* Generic BFD support for file formats.
- Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1999, 2000, 2001, 2002
+ Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Support.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/*
SECTION
@@ -52,7 +52,7 @@ FUNCTION
bfd_check_format
SYNOPSIS
- boolean bfd_check_format(bfd *abfd, bfd_format format);
+ bfd_boolean bfd_check_format (bfd *abfd, bfd_format format);
DESCRIPTION
Verify if the file attached to the BFD @var{abfd} is compatible
@@ -67,7 +67,7 @@ DESCRIPTION
matches, it is used. If not, exactly one target must recognize
the file, or an error results.
- The function returns <<true>> on success, otherwise <<false>>
+ The function returns <<TRUE>> on success, otherwise <<FALSE>>
with one of the following error codes:
o <<bfd_error_invalid_operation>> -
@@ -85,10 +85,8 @@ DESCRIPTION
more than one backend recognised the file format.
*/
-boolean
-bfd_check_format (abfd, format)
- bfd *abfd;
- bfd_format format;
+bfd_boolean
+bfd_check_format (bfd *abfd, bfd_format format)
{
return bfd_check_format_matches (abfd, format, NULL);
}
@@ -98,10 +96,11 @@ FUNCTION
bfd_check_format_matches
SYNOPSIS
- boolean bfd_check_format_matches(bfd *abfd, bfd_format format, char ***matching);
+ bfd_boolean bfd_check_format_matches
+ (bfd *abfd, bfd_format format, char ***matching);
DESCRIPTION
- Like <<bfd_check_format>>, except when it returns false with
+ Like <<bfd_check_format>>, except when it returns FALSE with
<<bfd_errno>> set to <<bfd_error_file_ambiguously_recognized>>. In that
case, if @var{matching} is not NULL, it will be filled in with
a NULL-terminated list of the names of the formats that matched,
@@ -112,15 +111,13 @@ DESCRIPTION
should free it.
*/
-boolean
-bfd_check_format_matches (abfd, format, matching)
- bfd *abfd;
- bfd_format format;
- char ***matching;
+bfd_boolean
+bfd_check_format_matches (bfd *abfd, bfd_format format, char ***matching)
{
extern const bfd_target binary_vec;
- const bfd_target * const *target, *save_targ, *right_targ, *ar_right_targ;
- char **matching_vector = NULL;
+ const bfd_target * const *target;
+ const bfd_target **matching_vector = NULL;
+ const bfd_target *save_targ, *right_targ, *ar_right_targ;
int match_count;
int ar_match_index;
@@ -128,11 +125,11 @@ bfd_check_format_matches (abfd, format, matching)
|| (unsigned int) abfd->format >= (unsigned int) bfd_type_end)
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
if (abfd->format != bfd_unknown)
- return (boolean) (abfd->format == format);
+ return abfd->format == format;
/* Since the target type was defaulted, check them
all in the hope that one will be uniquely recognized. */
@@ -145,10 +142,10 @@ bfd_check_format_matches (abfd, format, matching)
bfd_size_type amt;
*matching = NULL;
- amt = sizeof (char *) * 2 * _bfd_target_vector_entries;
- matching_vector = (char **) bfd_malloc (amt);
+ amt = sizeof (*matching_vector) * 2 * _bfd_target_vector_entries;
+ matching_vector = bfd_malloc (amt);
if (!matching_vector)
- return false;
+ return FALSE;
}
right_targ = 0;
@@ -161,7 +158,11 @@ bfd_check_format_matches (abfd, format, matching)
if (!abfd->target_defaulted)
{
if (bfd_seek (abfd, (file_ptr) 0, SEEK_SET) != 0) /* rewind! */
- return false;
+ {
+ if (matching)
+ free (matching_vector);
+ return FALSE;
+ }
right_targ = BFD_SEND_FMT (abfd, _bfd_check_format, (abfd));
@@ -172,7 +173,7 @@ bfd_check_format_matches (abfd, format, matching)
if (matching)
free (matching_vector);
- return true; /* File position has moved, BTW. */
+ return TRUE; /* File position has moved, BTW. */
}
/* For a long time the code has dropped through to check all
@@ -197,7 +198,7 @@ bfd_check_format_matches (abfd, format, matching)
bfd_set_error (bfd_error_file_not_recognized);
- return false;
+ return FALSE;
}
}
@@ -209,10 +210,14 @@ bfd_check_format_matches (abfd, format, matching)
if (*target == &binary_vec)
continue;
- abfd->xvec = *target; /* Change BFD's target temporarily */
+ abfd->xvec = *target; /* Change BFD's target temporarily. */
if (bfd_seek (abfd, (file_ptr) 0, SEEK_SET) != 0)
- return false;
+ {
+ if (matching)
+ free (matching_vector);
+ return FALSE;
+ }
/* If _bfd_check_format neglects to set bfd_error, assume
bfd_error_wrong_format. We didn't used to even pay any
@@ -223,7 +228,8 @@ bfd_check_format_matches (abfd, format, matching)
temp = BFD_SEND_FMT (abfd, _bfd_check_format, (abfd));
if (temp)
- { /* This format checks out as ok! */
+ {
+ /* This format checks out as ok! */
right_targ = temp;
/* If this is the default target, accept it, even if other
@@ -236,7 +242,7 @@ bfd_check_format_matches (abfd, format, matching)
}
if (matching)
- matching_vector[match_count] = temp->name;
+ matching_vector[match_count] = temp;
match_count++;
@@ -259,7 +265,7 @@ bfd_check_format_matches (abfd, format, matching)
if (ar_right_targ != bfd_default_vector[0])
ar_right_targ = *target;
if (matching)
- matching_vector[ar_match_index] = (*target)->name;
+ matching_vector[ar_match_index] = *target;
ar_match_index++;
}
else if (err != bfd_error_wrong_format)
@@ -270,7 +276,7 @@ bfd_check_format_matches (abfd, format, matching)
if (matching)
free (matching_vector);
- return false;
+ return FALSE;
}
}
@@ -278,6 +284,7 @@ bfd_check_format_matches (abfd, format, matching)
{
/* Try partial matches. */
right_targ = ar_right_targ;
+
if (right_targ == bfd_default_vector[0])
{
match_count = 1;
@@ -285,11 +292,32 @@ bfd_check_format_matches (abfd, format, matching)
else
{
match_count = ar_match_index - _bfd_target_vector_entries;
+
if (matching && match_count > 1)
+ memcpy (matching_vector,
+ matching_vector + _bfd_target_vector_entries,
+ sizeof (*matching_vector) * match_count);
+ }
+ }
+
+ if (match_count > 1
+ && bfd_associated_vector != NULL
+ && matching)
+ {
+ const bfd_target * const *assoc = bfd_associated_vector;
+
+ while ((right_targ = *assoc++) != NULL)
+ {
+ int i = match_count;
+
+ while (--i >= 0)
+ if (matching_vector[i] == right_targ)
+ break;
+
+ if (i >= 0)
{
- memcpy (matching_vector,
- matching_vector + _bfd_target_vector_entries,
- sizeof (char *) * match_count);
+ match_count = 1;
+ break;
}
}
}
@@ -301,7 +329,7 @@ bfd_check_format_matches (abfd, format, matching)
if (matching)
free (matching_vector);
- return true; /* File position has moved, BTW. */
+ return TRUE; /* File position has moved, BTW. */
}
abfd->xvec = save_targ; /* Restore original target type. */
@@ -320,12 +348,19 @@ bfd_check_format_matches (abfd, format, matching)
if (matching)
{
- *matching = matching_vector;
+ *matching = (char **) matching_vector;
matching_vector[match_count] = NULL;
+ /* Return target names. This is a little nasty. Maybe we
+ should do another bfd_malloc? */
+ while (--match_count >= 0)
+ {
+ const char *name = matching_vector[match_count]->name;
+ *(const char **) &matching_vector[match_count] = name;
+ }
}
}
- return false;
+ return FALSE;
}
/*
@@ -333,7 +368,7 @@ FUNCTION
bfd_set_format
SYNOPSIS
- boolean bfd_set_format(bfd *abfd, bfd_format format);
+ bfd_boolean bfd_set_format (bfd *abfd, bfd_format format);
DESCRIPTION
This function sets the file format of the BFD @var{abfd} to the
@@ -342,20 +377,18 @@ DESCRIPTION
is not open for writing, then an error occurs.
*/
-boolean
-bfd_set_format (abfd, format)
- bfd *abfd;
- bfd_format format;
+bfd_boolean
+bfd_set_format (bfd *abfd, bfd_format format)
{
if (bfd_read_p (abfd)
|| (unsigned int) abfd->format >= (unsigned int) bfd_type_end)
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
if (abfd->format != bfd_unknown)
- return (boolean) (abfd->format == format);
+ return abfd->format == format;
/* Presume the answer is yes. */
abfd->format = format;
@@ -363,10 +396,10 @@ bfd_set_format (abfd, format)
if (!BFD_SEND_FMT (abfd, _bfd_set_format, (abfd)))
{
abfd->format = bfd_unknown;
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/*
@@ -374,7 +407,7 @@ FUNCTION
bfd_format_string
SYNOPSIS
- const char *bfd_format_string(bfd_format format);
+ const char *bfd_format_string (bfd_format format);
DESCRIPTION
Return a pointer to a const string
@@ -383,17 +416,16 @@ DESCRIPTION
*/
const char *
-bfd_format_string (format)
- bfd_format format;
+bfd_format_string (bfd_format format)
{
- if (((int)format <(int) bfd_unknown)
- || ((int)format >=(int) bfd_type_end))
+ if (((int) format < (int) bfd_unknown)
+ || ((int) format >= (int) bfd_type_end))
return "invalid";
switch (format)
{
case bfd_object:
- return "object"; /* Linker/assember/compiler output. */
+ return "object"; /* Linker/assembler/compiler output. */
case bfd_archive:
return "archive"; /* Object archive file. */
case bfd_core:
diff --git a/contrib/binutils/bfd/gen-aout.c b/contrib/binutils/bfd/gen-aout.c
index b6720e8..ea207db 100644
--- a/contrib/binutils/bfd/gen-aout.c
+++ b/contrib/binutils/bfd/gen-aout.c
@@ -1,5 +1,5 @@
/* Generate parameters for an a.out system.
- Copyright 1990, 1991, 1992, 1993, 1994, 1995, 2001
+ Copyright 1990, 1991, 1992, 1993, 1994, 1995, 2001, 2002
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
diff --git a/contrib/binutils/bfd/genlink.h b/contrib/binutils/bfd/genlink.h
index 215666a..bcdc34b 100644
--- a/contrib/binutils/bfd/genlink.h
+++ b/contrib/binutils/bfd/genlink.h
@@ -1,5 +1,5 @@
/* genlink.h -- interface to the BFD generic linker
- Copyright 1993, 1994, 1996 Free Software Foundation, Inc.
+ Copyright 1993, 1994, 1996, 2002 Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support.
This file is part of BFD, the Binary File Descriptor library.
@@ -42,7 +42,7 @@ struct generic_link_hash_entry
{
struct bfd_link_hash_entry root;
/* Whether this symbol has been written out. */
- boolean written;
+ bfd_boolean written;
/* Symbol from input BFD. */
asymbol *sym;
};
@@ -54,18 +54,18 @@ struct generic_link_hash_table
struct bfd_link_hash_table root;
};
-/* Look up an entry in an generic link hash table. */
+/* Look up an entry in a generic link hash table. */
#define _bfd_generic_link_hash_lookup(table, string, create, copy, follow) \
((struct generic_link_hash_entry *) \
bfd_link_hash_lookup (&(table)->root, (string), (create), (copy), (follow)))
-/* Traverse an generic link hash table. */
+/* Traverse a generic link hash table. */
#define _bfd_generic_link_hash_traverse(table, func, info) \
(bfd_link_hash_traverse \
(&(table)->root, \
- (boolean (*) PARAMS ((struct bfd_link_hash_entry *, PTR))) (func), \
+ (bfd_boolean (*) PARAMS ((struct bfd_link_hash_entry *, PTR))) (func), \
(info)))
/* Get the generic link hash table from the info structure. This is
@@ -82,7 +82,7 @@ struct generic_link_hash_table
/* Add the symbols of input_bfd to the symbols being built for
output_bfd. */
-extern boolean _bfd_generic_link_output_symbols
+extern bfd_boolean _bfd_generic_link_output_symbols
PARAMS ((bfd *output_bfd, bfd *input_bfd, struct bfd_link_info *,
size_t *psymalloc));
@@ -100,7 +100,7 @@ struct generic_write_global_symbol_info
/* Write out a single global symbol. This is expected to be called
via _bfd_generic_link_hash_traverse. The second argument must
actually be a struct generic_write_global_symbol_info *. */
-extern boolean _bfd_generic_link_write_global_symbol
+extern bfd_boolean _bfd_generic_link_write_global_symbol
PARAMS ((struct generic_link_hash_entry *, PTR));
/* Generic link hash table entry creation routine. */
diff --git a/contrib/binutils/bfd/hash.c b/contrib/binutils/bfd/hash.c
index e7c77fe..58fa532 100644
--- a/contrib/binutils/bfd/hash.c
+++ b/contrib/binutils/bfd/hash.c
@@ -1,5 +1,5 @@
/* hash.c -- hash table routines for BFD
- Copyright 1993, 1994, 1995, 1997, 1999, 2001, 2002
+ Copyright 1993, 1994, 1995, 1997, 1999, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Steve Chamberlain <sac@cygnus.com>
@@ -67,7 +67,7 @@ SUBSECTION
<<bfd_hash_table_init>> (if you know approximately how many
entries you will need, the function <<bfd_hash_table_init_n>>,
which takes a @var{size} argument, may be used).
- <<bfd_hash_table_init>> returns <<false>> if some sort of
+ <<bfd_hash_table_init>> returns <<FALSE>> if some sort of
error occurs.
@findex bfd_hash_newfunc
@@ -96,24 +96,24 @@ SUBSECTION
The function <<bfd_hash_lookup>> is used both to look up a
string in the hash table and to create a new entry.
- If the @var{create} argument is <<false>>, <<bfd_hash_lookup>>
+ If the @var{create} argument is <<FALSE>>, <<bfd_hash_lookup>>
will look up a string. If the string is found, it will
returns a pointer to a <<struct bfd_hash_entry>>. If the
string is not found in the table <<bfd_hash_lookup>> will
return <<NULL>>. You should not modify any of the fields in
the returns <<struct bfd_hash_entry>>.
- If the @var{create} argument is <<true>>, the string will be
+ If the @var{create} argument is <<TRUE>>, the string will be
entered into the hash table if it is not already there.
Either way a pointer to a <<struct bfd_hash_entry>> will be
returned, either to the existing structure or to a newly
created one. In this case, a <<NULL>> return means that an
error occurred.
- If the @var{create} argument is <<true>>, and a new entry is
+ If the @var{create} argument is <<TRUE>>, and a new entry is
created, the @var{copy} argument is used to decide whether to
copy the string onto the hash table objalloc or not. If
- @var{copy} is passed as <<false>>, you must be careful not to
+ @var{copy} is passed as <<FALSE>>, you must be careful not to
deallocate or modify the string as long as the hash table
exists.
@@ -133,7 +133,7 @@ SUBSECTION
generic pointer passed to <<bfd_hash_traverse>>. The function
must return a <<boolean>> value, which indicates whether to
continue traversing the hash table. If the function returns
- <<false>>, <<bfd_hash_traverse>> will stop the traversal and
+ <<FALSE>>, <<bfd_hash_traverse>> will stop the traversal and
return immediately.
INODE
@@ -299,7 +299,7 @@ SUBSUBSECTION
/* Create a new hash table, given a number of entries. */
-boolean
+bfd_boolean
bfd_hash_table_init_n (table, newfunc, size)
struct bfd_hash_table *table;
struct bfd_hash_entry *(*newfunc) PARAMS ((struct bfd_hash_entry *,
@@ -315,24 +315,24 @@ bfd_hash_table_init_n (table, newfunc, size)
if (table->memory == NULL)
{
bfd_set_error (bfd_error_no_memory);
- return false;
+ return FALSE;
}
table->table = ((struct bfd_hash_entry **)
objalloc_alloc ((struct objalloc *) table->memory, alloc));
if (table->table == NULL)
{
bfd_set_error (bfd_error_no_memory);
- return false;
+ return FALSE;
}
memset ((PTR) table->table, 0, alloc);
table->size = size;
table->newfunc = newfunc;
- return true;
+ return TRUE;
}
/* Create a new hash table with the default number of entries. */
-boolean
+bfd_boolean
bfd_hash_table_init (table, newfunc)
struct bfd_hash_table *table;
struct bfd_hash_entry *(*newfunc) PARAMS ((struct bfd_hash_entry *,
@@ -358,8 +358,8 @@ struct bfd_hash_entry *
bfd_hash_lookup (table, string, create, copy)
struct bfd_hash_table *table;
const char *string;
- boolean create;
- boolean copy;
+ bfd_boolean create;
+ bfd_boolean copy;
{
register const unsigned char *s;
register unsigned long hash;
@@ -446,7 +446,6 @@ bfd_hash_replace (table, old, nw)
/* Base method for creating a new hash table entry. */
-/*ARGSUSED*/
struct bfd_hash_entry *
bfd_hash_newfunc (entry, table, string)
struct bfd_hash_entry *entry;
@@ -479,7 +478,7 @@ bfd_hash_allocate (table, size)
void
bfd_hash_traverse (table, func, info)
struct bfd_hash_table *table;
- boolean (*func) PARAMS ((struct bfd_hash_entry *, PTR));
+ bfd_boolean (*func) PARAMS ((struct bfd_hash_entry *, PTR));
PTR info;
{
unsigned int i;
@@ -532,7 +531,7 @@ struct bfd_strtab_hash
struct strtab_hash_entry *last;
/* Whether to precede strings with a two byte length, as in the
XCOFF .debug section. */
- boolean xcoff;
+ bfd_boolean xcoff;
};
static struct bfd_hash_entry *strtab_hash_newfunc
@@ -597,7 +596,7 @@ _bfd_stringtab_init ()
table->size = 0;
table->first = NULL;
table->last = NULL;
- table->xcoff = false;
+ table->xcoff = FALSE;
return table;
}
@@ -613,7 +612,7 @@ _bfd_xcoff_stringtab_init ()
ret = _bfd_stringtab_init ();
if (ret != NULL)
- ret->xcoff = true;
+ ret->xcoff = TRUE;
return ret;
}
@@ -628,21 +627,21 @@ _bfd_stringtab_free (table)
}
/* Get the index of a string in a strtab, adding it if it is not
- already present. If HASH is false, we don't really use the hash
+ already present. If HASH is FALSE, we don't really use the hash
table, and we don't eliminate duplicate strings. */
bfd_size_type
_bfd_stringtab_add (tab, str, hash, copy)
struct bfd_strtab_hash *tab;
const char *str;
- boolean hash;
- boolean copy;
+ bfd_boolean hash;
+ bfd_boolean copy;
{
register struct strtab_hash_entry *entry;
if (hash)
{
- entry = strtab_hash_lookup (tab, str, true, copy);
+ entry = strtab_hash_lookup (tab, str, TRUE, copy);
if (entry == NULL)
return (bfd_size_type) -1;
}
@@ -699,12 +698,12 @@ _bfd_stringtab_size (tab)
/* Write out a strtab. ABFD must already be at the right location in
the file. */
-boolean
+bfd_boolean
_bfd_stringtab_emit (abfd, tab)
register bfd *abfd;
struct bfd_strtab_hash *tab;
{
- register boolean xcoff;
+ register bfd_boolean xcoff;
register struct strtab_hash_entry *entry;
xcoff = tab->xcoff;
@@ -724,12 +723,12 @@ _bfd_stringtab_emit (abfd, tab)
/* The output length includes the null byte. */
bfd_put_16 (abfd, (bfd_vma) len, buf);
if (bfd_bwrite ((PTR) buf, (bfd_size_type) 2, abfd) != 2)
- return false;
+ return FALSE;
}
if (bfd_bwrite ((PTR) str, (bfd_size_type) len, abfd) != len)
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
diff --git a/contrib/binutils/bfd/i386aout.c b/contrib/binutils/bfd/i386aout.c
index c68dbec..6b2948e 100644
--- a/contrib/binutils/bfd/i386aout.c
+++ b/contrib/binutils/bfd/i386aout.c
@@ -1,5 +1,5 @@
/* BFD back-end for i386 a.out binaries.
- Copyright 1990, 1991, 1992, 1994, 1996, 1997, 2001
+ Copyright 1990, 1991, 1992, 1994, 1996, 1997, 2001, 2002, 2003
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -26,7 +26,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
system, and I'll stick it in for the next release. */
#define N_HEADER_IN_TEXT(x) 0
-#define BYTES_IN_WORD 4
#define N_TXTOFF(x) 0x20
#define N_TXTADDR(x) (N_MAGIC(x)==ZMAGIC ? 0x1020 : 0)
@@ -54,12 +53,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "aout/aout64.h"
#include "libaout.h"
-static boolean i386aout_write_object_contents PARAMS ((bfd *));
-static boolean MY (set_sizes) PARAMS ((bfd *));
+static bfd_boolean i386aout_write_object_contents PARAMS ((bfd *));
+static bfd_boolean MY (set_sizes) PARAMS ((bfd *));
/* Set the machine type correctly. */
-static boolean
+static bfd_boolean
i386aout_write_object_contents (abfd)
bfd *abfd;
{
@@ -72,7 +71,7 @@ i386aout_write_object_contents (abfd)
WRITE_HEADERS (abfd, execp);
- return true;
+ return TRUE;
}
#define MY_write_object_contents i386aout_write_object_contents
diff --git a/contrib/binutils/bfd/i386linux.c b/contrib/binutils/bfd/i386linux.c
index c144822..da36e75 100644
--- a/contrib/binutils/bfd/i386linux.c
+++ b/contrib/binutils/bfd/i386linux.c
@@ -1,5 +1,5 @@
/* BFD back-end for linux flavored i386 a.out binaries.
- Copyright 1992, 1993, 1994, 1995, 1996, 1997, 2001, 2002
+ Copyright 1992, 1993, 1994, 1995, 1996, 1997, 2001, 2002, 2003
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -23,7 +23,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define SEGMENT_SIZE TARGET_PAGE_SIZE
#define TEXT_START_ADDR 0x0
#define N_SHARED_LIB(x) 0
-#define BYTES_IN_WORD 4
#define MACHTYPE_OK(mtype) ((mtype) == M_386 || (mtype) == M_UNKNOWN)
@@ -51,11 +50,11 @@ extern const bfd_target MY(vec);
static void MY_final_link_callback
PARAMS ((bfd *, file_ptr *, file_ptr *, file_ptr *));
-static boolean i386linux_bfd_final_link
+static bfd_boolean i386linux_bfd_final_link
PARAMS ((bfd *, struct bfd_link_info *));
-static boolean i386linux_write_object_contents PARAMS ((bfd *));
+static bfd_boolean i386linux_write_object_contents PARAMS ((bfd *));
-static boolean
+static bfd_boolean
i386linux_bfd_final_link (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -68,7 +67,7 @@ i386linux_bfd_final_link (abfd, info)
/* Set the machine type correctly. */
-static boolean
+static bfd_boolean
i386linux_write_object_contents (abfd)
bfd *abfd;
{
@@ -81,7 +80,7 @@ i386linux_write_object_contents (abfd)
WRITE_HEADERS(abfd, execp);
- return true;
+ return TRUE;
}
#define MY_write_object_contents i386linux_write_object_contents
@@ -113,7 +112,7 @@ i386linux_write_object_contents (abfd)
#endif
/* This special symbol is a set vector that contains a list of
- pointers to fixup tables. It will be present in any dynamicly
+ pointers to fixup tables. It will be present in any dynamically
linked file. The linker generated fixup table should also be added
to the list, and it should always appear in the second slot (the
first one is a dummy with a magic number that is defined in
@@ -179,15 +178,15 @@ static struct bfd_link_hash_table *linux_link_hash_table_create
static struct fixup *new_fixup
PARAMS ((struct bfd_link_info *, struct linux_link_hash_entry *,
bfd_vma, int));
-static boolean linux_link_create_dynamic_sections
+static bfd_boolean linux_link_create_dynamic_sections
PARAMS ((bfd *, struct bfd_link_info *));
-static boolean linux_add_one_symbol
+static bfd_boolean linux_add_one_symbol
PARAMS ((struct bfd_link_info *, bfd *, const char *, flagword, asection *,
- bfd_vma, const char *, boolean, boolean,
+ bfd_vma, const char *, bfd_boolean, bfd_boolean,
struct bfd_link_hash_entry **));
-static boolean linux_tally_symbols
+static bfd_boolean linux_tally_symbols
PARAMS ((struct linux_link_hash_entry *, PTR));
-static boolean linux_finish_dynamic_link
+static bfd_boolean linux_finish_dynamic_link
PARAMS ((bfd *, struct bfd_link_info *));
/* Routine to create an entry in an Linux link hash table. */
@@ -259,7 +258,7 @@ linux_link_hash_table_create (abfd)
#define linux_link_hash_traverse(table, func, info) \
(aout_link_hash_traverse \
(&(table)->root, \
- (boolean (*) PARAMS ((struct aout_link_hash_entry *, PTR))) (func), \
+ (bfd_boolean (*) PARAMS ((struct aout_link_hash_entry *, PTR))) (func), \
(info)))
/* Get the Linux link hash table from the info structure. This is
@@ -299,7 +298,7 @@ new_fixup (info, h, value, builtin)
know the size of the section, but that's OK - we just need to
create it for now. */
-static boolean
+static bfd_boolean
linux_link_create_dynamic_sections (abfd, info)
bfd *abfd;
struct bfd_link_info *info ATTRIBUTE_UNUSED;
@@ -316,18 +315,18 @@ linux_link_create_dynamic_sections (abfd, info)
if (s == NULL
|| ! bfd_set_section_flags (abfd, s, flags)
|| ! bfd_set_section_alignment (abfd, s, 2))
- return false;
+ return FALSE;
s->_raw_size = 0;
s->contents = 0;
- return true;
+ return TRUE;
}
/* Function to add a single symbol to the linker hash table. This is
a wrapper around _bfd_generic_link_add_one_symbol which handles the
tweaking needed for dynamic linking support. */
-static boolean
+static bfd_boolean
linux_add_one_symbol (info, abfd, name, flags, section, value, string,
copy, collect, hashp)
struct bfd_link_info *info;
@@ -337,12 +336,12 @@ linux_add_one_symbol (info, abfd, name, flags, section, value, string,
asection *section;
bfd_vma value;
const char *string;
- boolean copy;
- boolean collect;
+ bfd_boolean copy;
+ bfd_boolean collect;
struct bfd_link_hash_entry **hashp;
{
struct linux_link_hash_entry *h;
- boolean insert;
+ bfd_boolean insert;
/* Look up and see if we already have this symbol in the hash table.
If we do, and the defining entry is from a shared library, we
@@ -352,25 +351,25 @@ linux_add_one_symbol (info, abfd, name, flags, section, value, string,
be able to link Linux a.out and ELF objects together, but serious
confusion is possible. */
- insert = false;
+ insert = FALSE;
- if (! info->relocateable
+ if (! info->relocatable
&& linux_hash_table (info)->dynobj == NULL
&& strcmp (name, SHARABLE_CONFLICTS) == 0
&& (flags & BSF_CONSTRUCTOR) != 0
&& abfd->xvec == info->hash->creator)
{
if (! linux_link_create_dynamic_sections (abfd, info))
- return false;
+ return FALSE;
linux_hash_table (info)->dynobj = abfd;
- insert = true;
+ insert = TRUE;
}
if (bfd_is_abs_section (section)
&& abfd->xvec == info->hash->creator)
{
- h = linux_link_hash_lookup (linux_hash_table (info), name, false,
- false, false);
+ h = linux_link_hash_lookup (linux_hash_table (info), name, FALSE,
+ FALSE, FALSE);
if (h != NULL
&& (h->root.root.type == bfd_link_hash_defined
|| h->root.root.type == bfd_link_hash_defweak))
@@ -382,10 +381,10 @@ linux_add_one_symbol (info, abfd, name, flags, section, value, string,
f = new_fixup (info, h, value, ! IS_PLT_SYM (name));
if (f == NULL)
- return false;
+ return FALSE;
f->jump = IS_PLT_SYM (name);
- return true;
+ return TRUE;
}
}
@@ -393,7 +392,7 @@ linux_add_one_symbol (info, abfd, name, flags, section, value, string,
if (! _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section,
value, string, copy, collect,
hashp))
- return false;
+ return FALSE;
/* Insert a pointer to our table in the set vector. The dynamic
linker requires this information */
@@ -410,11 +409,11 @@ linux_add_one_symbol (info, abfd, name, flags, section, value, string,
if (! (_bfd_generic_link_add_one_symbol
(info, linux_hash_table (info)->dynobj, SHARABLE_CONFLICTS,
BSF_GLOBAL | BSF_CONSTRUCTOR, s, (bfd_vma) 0, NULL,
- false, false, NULL)))
- return false;
+ FALSE, FALSE, NULL)))
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* We will crawl the hash table and come here for every global symbol.
@@ -427,7 +426,7 @@ linux_add_one_symbol (info, abfd, name, flags, section, value, string,
This function is called via linux_link_hash_traverse. */
-static boolean
+static bfd_boolean
linux_tally_symbols (h, data)
struct linux_link_hash_entry *h;
PTR data;
@@ -436,7 +435,7 @@ linux_tally_symbols (h, data)
struct fixup *f, *f1;
int is_plt;
struct linux_link_hash_entry *h1, *h2;
- boolean exists;
+ bfd_boolean exists;
if (h->root.root.type == bfd_link_hash_warning)
h = (struct linux_link_hash_entry *) h->root.root.u.i.link;
@@ -482,12 +481,12 @@ linux_tally_symbols (h, data)
h1 = linux_link_hash_lookup (linux_hash_table (info),
(h->root.root.root.string
+ sizeof PLT_REF_PREFIX - 1),
- false, false, true);
+ FALSE, FALSE, TRUE);
/* h2 does not follow indirect symbols. */
h2 = linux_link_hash_lookup (linux_hash_table (info),
(h->root.root.root.string
+ sizeof PLT_REF_PREFIX - 1),
- false, false, false);
+ FALSE, FALSE, FALSE);
/* The real symbol must exist but if it is also an ABS symbol,
there is no need to have a fixup. This is because they both
@@ -505,7 +504,7 @@ linux_tally_symbols (h, data)
involving this symbol. If so, convert it to a regular
fixup. In the end, this relaxes some of the requirements
about the order of performing fixups. */
- exists = false;
+ exists = FALSE;
for (f1 = linux_hash_table (info)->fixup_list;
f1 != NULL;
f1 = f1->next)
@@ -514,7 +513,7 @@ linux_tally_symbols (h, data)
|| (! f1->builtin && ! f1->jump))
continue;
if (f1->h == h1)
- exists = true;
+ exists = TRUE;
if (! exists
&& bfd_is_abs_section (h->root.root.u.def.section))
{
@@ -524,7 +523,7 @@ linux_tally_symbols (h, data)
f1->h = h1;
f1->jump = is_plt;
f1->builtin = 0;
- exists = true;
+ exists = TRUE;
}
if (! exists
&& bfd_is_abs_section (h->root.root.u.def.section))
@@ -542,10 +541,10 @@ linux_tally_symbols (h, data)
/* Quick and dirty way of stripping these symbols from the
symtab. */
if (bfd_is_abs_section (h->root.root.u.def.section))
- h->root.written = true;
+ h->root.written = TRUE;
}
- return true;
+ return TRUE;
}
/* This is called to set the size of the .linux-dynamic section is.
@@ -554,7 +553,7 @@ linux_tally_symbols (h, data)
we just scan the hash tables to find out how many additional fixups
are required. */
-boolean
+bfd_boolean
bfd_i386linux_size_dynamic_sections (output_bfd, info)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -563,7 +562,7 @@ bfd_i386linux_size_dynamic_sections (output_bfd, info)
asection *s;
if (output_bfd->xvec != &MY(vec))
- return true;
+ return TRUE;
/* First find the fixups... */
linux_link_hash_traverse (linux_hash_table (info),
@@ -587,7 +586,7 @@ bfd_i386linux_size_dynamic_sections (output_bfd, info)
{
if (linux_hash_table (info)->fixup_count > 0)
abort ();
- return true;
+ return TRUE;
}
/* Allocate memory for our fixup table. We will fill it in later. */
@@ -599,17 +598,17 @@ bfd_i386linux_size_dynamic_sections (output_bfd, info)
s->_raw_size *= 8;
s->contents = (bfd_byte *) bfd_zalloc (output_bfd, s->_raw_size);
if (s->contents == NULL)
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* We come here once we are ready to actually write the fixup table to
the output file. Scan the fixup tables and so forth and generate
the stuff we need. */
-static boolean
+static bfd_boolean
linux_finish_dynamic_link (output_bfd, info)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -623,7 +622,7 @@ linux_finish_dynamic_link (output_bfd, info)
unsigned int fixups_written;
if (linux_hash_table (info)->dynobj == NULL)
- return true;
+ return TRUE;
s = bfd_get_section_by_name (linux_hash_table (info)->dynobj,
".linux-dynamic");
@@ -739,7 +738,7 @@ linux_finish_dynamic_link (output_bfd, info)
h = linux_link_hash_lookup (linux_hash_table (info),
"__BUILTIN_FIXUPS__",
- false, false, false);
+ FALSE, FALSE, FALSE);
if (h != NULL
&& (h->root.root.type == bfd_link_hash_defined
@@ -760,12 +759,12 @@ linux_finish_dynamic_link (output_bfd, info)
if (bfd_seek (output_bfd, (file_ptr) (os->filepos + s->output_offset),
SEEK_SET) != 0)
- return false;
+ return FALSE;
if (bfd_bwrite ((PTR) s->contents, s->_raw_size, output_bfd) != s->_raw_size)
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
#define MY_bfd_link_hash_table_create linux_link_hash_table_create
diff --git a/contrib/binutils/bfd/ieee.c b/contrib/binutils/bfd/ieee.c
index d1c5eb1..8a08028 100644
--- a/contrib/binutils/bfd/ieee.c
+++ b/contrib/binutils/bfd/ieee.c
@@ -1,6 +1,6 @@
/* BFD back-end for ieee-695 objects.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Steve Chamberlain of Cygnus Support.
@@ -40,93 +40,151 @@ struct output_buffer_struct
int buffer;
};
-static boolean ieee_write_byte PARAMS ((bfd *, int));
-static boolean ieee_write_2bytes PARAMS ((bfd *, int));
-static boolean ieee_write_int PARAMS ((bfd *, bfd_vma));
-static boolean ieee_write_id PARAMS ((bfd *, const char *));
-static unsigned short read_2bytes PARAMS ((common_header_type *));
-static void bfd_get_string PARAMS ((common_header_type *, char *, size_t));
-static char *read_id PARAMS ((common_header_type *));
-static boolean ieee_write_expression
- PARAMS ((bfd *, bfd_vma, asymbol *, boolean, unsigned int));
-static void ieee_write_int5 PARAMS ((bfd_byte *, bfd_vma));
-static boolean ieee_write_int5_out PARAMS ((bfd *, bfd_vma));
-static boolean parse_int PARAMS ((common_header_type *, bfd_vma *));
-static int parse_i PARAMS ((common_header_type *, boolean *));
-static bfd_vma must_parse_int PARAMS ((common_header_type *));
+static bfd_boolean ieee_write_byte
+ PARAMS ((bfd *, int));
+static bfd_boolean ieee_write_2bytes
+ PARAMS ((bfd *, int));
+static bfd_boolean ieee_write_int
+ PARAMS ((bfd *, bfd_vma));
+static bfd_boolean ieee_write_id
+ PARAMS ((bfd *, const char *));
+static unsigned short read_2bytes
+ PARAMS ((common_header_type *));
+static void bfd_get_string
+ PARAMS ((common_header_type *, char *, size_t));
+static char *read_id
+ PARAMS ((common_header_type *));
+static bfd_boolean ieee_write_expression
+ PARAMS ((bfd *, bfd_vma, asymbol *, bfd_boolean, unsigned int));
+static void ieee_write_int5
+ PARAMS ((bfd_byte *, bfd_vma));
+static bfd_boolean ieee_write_int5_out
+ PARAMS ((bfd *, bfd_vma));
+static bfd_boolean parse_int
+ PARAMS ((common_header_type *, bfd_vma *));
+static int parse_i
+ PARAMS ((common_header_type *, bfd_boolean *));
+static bfd_vma must_parse_int
+ PARAMS ((common_header_type *));
static void parse_expression
PARAMS ((ieee_data_type *, bfd_vma *, ieee_symbol_index_type *,
- boolean *, unsigned int *, asection **));
-static file_ptr ieee_part_after PARAMS ((ieee_data_type *, file_ptr));
+ bfd_boolean *, unsigned int *, asection **));
+static file_ptr ieee_part_after
+ PARAMS ((ieee_data_type *, file_ptr));
static ieee_symbol_type *get_symbol
PARAMS ((bfd *, ieee_data_type *, ieee_symbol_type *, unsigned int *,
ieee_symbol_type ***, unsigned int *, int));
-static boolean ieee_slurp_external_symbols PARAMS ((bfd *));
-static boolean ieee_slurp_symbol_table PARAMS ((bfd *));
-static long ieee_get_symtab_upper_bound PARAMS ((bfd *));
-static long ieee_get_symtab PARAMS ((bfd *, asymbol **));
+static bfd_boolean ieee_slurp_external_symbols
+ PARAMS ((bfd *));
+static bfd_boolean ieee_slurp_symbol_table
+ PARAMS ((bfd *));
+static long ieee_get_symtab_upper_bound
+ PARAMS ((bfd *));
+static long ieee_canonicalize_symtab
+ PARAMS ((bfd *, asymbol **));
static asection *get_section_entry
PARAMS ((bfd *, ieee_data_type *i, unsigned int));
-static void ieee_slurp_sections PARAMS ((bfd *));
-static boolean ieee_slurp_debug PARAMS ((bfd *));
-const bfd_target *ieee_archive_p PARAMS ((bfd *));
-const bfd_target *ieee_object_p PARAMS ((bfd *));
-static void ieee_get_symbol_info PARAMS ((bfd *, asymbol *, symbol_info *));
+static void ieee_slurp_sections
+ PARAMS ((bfd *));
+static bfd_boolean ieee_slurp_debug
+ PARAMS ((bfd *));
+const bfd_target *ieee_archive_p
+ PARAMS ((bfd *));
+const bfd_target *ieee_object_p
+ PARAMS ((bfd *));
+static void ieee_get_symbol_info
+ PARAMS ((bfd *, asymbol *, symbol_info *));
static void ieee_print_symbol
PARAMS ((bfd *, PTR, asymbol *, bfd_print_symbol_type));
-static boolean do_one
+static bfd_boolean do_one
PARAMS ((ieee_data_type *, ieee_per_section_type *, unsigned char *,
asection *, int));
-static boolean ieee_slurp_section_data PARAMS ((bfd *));
-static boolean ieee_new_section_hook PARAMS ((bfd *, asection *));
-static long ieee_get_reloc_upper_bound PARAMS ((bfd *, sec_ptr));
-static boolean ieee_get_section_contents
+static bfd_boolean ieee_slurp_section_data
+ PARAMS ((bfd *));
+static bfd_boolean ieee_new_section_hook
+ PARAMS ((bfd *, asection *));
+static long ieee_get_reloc_upper_bound
+ PARAMS ((bfd *, sec_ptr));
+static bfd_boolean ieee_get_section_contents
PARAMS ((bfd *, sec_ptr, PTR, file_ptr, bfd_size_type));
static long ieee_canonicalize_reloc
PARAMS ((bfd *, sec_ptr, arelent **, asymbol **));
-static int comp PARAMS ((const PTR, const PTR));
-static boolean ieee_write_section_part PARAMS ((bfd *));
-static boolean do_with_relocs PARAMS ((bfd *, asection *));
-static boolean do_as_repeat PARAMS ((bfd *, asection *));
-static boolean do_without_relocs PARAMS ((bfd *, asection *));
-static boolean ieee_mkobject PARAMS ((bfd *));
-static void fill PARAMS ((void));
-static void flush PARAMS ((void));
-static void write_int PARAMS ((int));
-static void copy_id PARAMS ((void));
-static void copy_expression PARAMS ((void));
-static void fill_int PARAMS ((struct output_buffer_struct *));
-static void drop_int PARAMS ((struct output_buffer_struct *));
-static void copy_int PARAMS ((void));
-static void f1_record PARAMS ((void));
-static void f0_record PARAMS ((void));
-static void copy_till_end PARAMS ((void));
-static void f2_record PARAMS ((void));
-static void f8_record PARAMS ((void));
-static void e2_record PARAMS ((void));
-static void block PARAMS ((void));
-static void relocate_debug PARAMS ((bfd *, bfd *));
-static boolean ieee_write_debug_part PARAMS ((bfd *));
-static boolean ieee_write_data_part PARAMS ((bfd *));
-static boolean init_for_output PARAMS ((bfd *));
-static boolean ieee_set_section_contents
- PARAMS ((bfd *, sec_ptr, PTR, file_ptr, bfd_size_type));
-static boolean ieee_write_external_part PARAMS ((bfd *));
-static boolean ieee_write_me_part PARAMS ((bfd *));
-static boolean ieee_write_processor PARAMS ((bfd *));
-static boolean ieee_write_object_contents PARAMS ((bfd *));
-static asymbol *ieee_make_empty_symbol PARAMS ((bfd *));
-static bfd *ieee_openr_next_archived_file PARAMS ((bfd *, bfd *));
-static boolean ieee_find_nearest_line
+static int comp
+ PARAMS ((const PTR, const PTR));
+static bfd_boolean ieee_write_section_part
+ PARAMS ((bfd *));
+static bfd_boolean do_with_relocs
+ PARAMS ((bfd *, asection *));
+static bfd_boolean do_as_repeat
+ PARAMS ((bfd *, asection *));
+static bfd_boolean do_without_relocs
+ PARAMS ((bfd *, asection *));
+static bfd_boolean ieee_mkobject
+ PARAMS ((bfd *));
+static void fill
+ PARAMS ((void));
+static void flush
+ PARAMS ((void));
+static void write_int
+ PARAMS ((int));
+static void copy_id
+ PARAMS ((void));
+static void copy_expression
+ PARAMS ((void));
+static void fill_int
+ PARAMS ((struct output_buffer_struct *));
+static void drop_int
+ PARAMS ((struct output_buffer_struct *));
+static void copy_int
+ PARAMS ((void));
+static void f1_record
+ PARAMS ((void));
+static void f0_record
+ PARAMS ((void));
+static void copy_till_end
+ PARAMS ((void));
+static void f2_record
+ PARAMS ((void));
+static void f8_record
+ PARAMS ((void));
+static void e2_record
+ PARAMS ((void));
+static void block
+ PARAMS ((void));
+static void relocate_debug
+ PARAMS ((bfd *, bfd *));
+static bfd_boolean ieee_write_debug_part
+ PARAMS ((bfd *));
+static bfd_boolean ieee_write_data_part
+ PARAMS ((bfd *));
+static bfd_boolean init_for_output
+ PARAMS ((bfd *));
+static bfd_boolean ieee_set_section_contents
+ PARAMS ((bfd *, sec_ptr, const PTR, file_ptr, bfd_size_type));
+static bfd_boolean ieee_write_external_part
+ PARAMS ((bfd *));
+static bfd_boolean ieee_write_me_part
+ PARAMS ((bfd *));
+static bfd_boolean ieee_write_processor
+ PARAMS ((bfd *));
+static bfd_boolean ieee_write_object_contents
+ PARAMS ((bfd *));
+static asymbol *ieee_make_empty_symbol
+ PARAMS ((bfd *));
+static bfd *ieee_openr_next_archived_file
+ PARAMS ((bfd *, bfd *));
+static bfd_boolean ieee_find_nearest_line
PARAMS ((bfd *, asection *, asymbol **, bfd_vma, const char **,
const char **, unsigned int *));
-static int ieee_generic_stat_arch_elt PARAMS ((bfd *, struct stat *));
-static int ieee_sizeof_headers PARAMS ((bfd *, boolean));
+static int ieee_generic_stat_arch_elt
+ PARAMS ((bfd *, struct stat *));
+static int ieee_sizeof_headers
+ PARAMS ((bfd *, bfd_boolean));
/* Functions for writing to ieee files in the strange way that the
standard requires. */
-static boolean
+static bfd_boolean
ieee_write_byte (abfd, barg)
bfd *abfd;
int barg;
@@ -135,11 +193,11 @@ ieee_write_byte (abfd, barg)
byte = barg;
if (bfd_bwrite ((PTR) &byte, (bfd_size_type) 1, abfd) != 1)
- return false;
- return true;
+ return FALSE;
+ return TRUE;
}
-static boolean
+static bfd_boolean
ieee_write_2bytes (abfd, bytes)
bfd *abfd;
int bytes;
@@ -149,11 +207,11 @@ ieee_write_2bytes (abfd, bytes)
buffer[0] = bytes >> 8;
buffer[1] = bytes & 0xff;
if (bfd_bwrite ((PTR) buffer, (bfd_size_type) 2, abfd) != 2)
- return false;
- return true;
+ return FALSE;
+ return TRUE;
}
-static boolean
+static bfd_boolean
ieee_write_int (abfd, value)
bfd *abfd;
bfd_vma value;
@@ -161,14 +219,14 @@ ieee_write_int (abfd, value)
if (value <= 127)
{
if (! ieee_write_byte (abfd, (bfd_byte) value))
- return false;
+ return FALSE;
}
else
{
unsigned int length;
- /* How many significant bytes ? */
- /* FIXME FOR LONGER INTS */
+ /* How many significant bytes ? */
+ /* FIXME FOR LONGER INTS. */
if (value & 0xff000000)
length = 4;
else if (value & 0x00ff0000)
@@ -181,31 +239,31 @@ ieee_write_int (abfd, value)
if (! ieee_write_byte (abfd,
(bfd_byte) ((int) ieee_number_repeat_start_enum
+ length)))
- return false;
+ return FALSE;
switch (length)
{
case 4:
if (! ieee_write_byte (abfd, (bfd_byte) (value >> 24)))
- return false;
+ return FALSE;
/* Fall through. */
case 3:
if (! ieee_write_byte (abfd, (bfd_byte) (value >> 16)))
- return false;
+ return FALSE;
/* Fall through. */
case 2:
if (! ieee_write_byte (abfd, (bfd_byte) (value >> 8)))
- return false;
+ return FALSE;
/* Fall through. */
case 1:
if (! ieee_write_byte (abfd, (bfd_byte) (value)))
- return false;
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
ieee_write_id (abfd, id)
bfd *abfd;
const char *id;
@@ -215,19 +273,19 @@ ieee_write_id (abfd, id)
if (length <= 127)
{
if (! ieee_write_byte (abfd, (bfd_byte) length))
- return false;
+ return FALSE;
}
else if (length < 255)
{
if (! ieee_write_byte (abfd, ieee_extension_length_1_enum)
|| ! ieee_write_byte (abfd, (bfd_byte) length))
- return false;
+ return FALSE;
}
else if (length < 65535)
{
if (! ieee_write_byte (abfd, ieee_extension_length_2_enum)
|| ! ieee_write_2bytes (abfd, (int) length))
- return false;
+ return FALSE;
}
else
{
@@ -235,18 +293,16 @@ ieee_write_id (abfd, id)
(_("%s: string too long (%d chars, max 65535)"),
bfd_get_filename (abfd), length);
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
if (bfd_bwrite ((PTR) id, (bfd_size_type) length, abfd) != length)
- return false;
- return true;
+ return FALSE;
+ return TRUE;
}
-/***************************************************************************
-Functions for reading from ieee files in the strange way that the
-standard requires:
-*/
+/* Functions for reading from ieee files in the strange way that the
+ standard requires. */
#define this_byte(ieee) *((ieee)->input_p)
#define next_byte(ieee) ((ieee)->input_p++)
@@ -258,6 +314,7 @@ read_2bytes (ieee)
{
unsigned char c1 = this_byte_and_next (ieee);
unsigned char c2 = this_byte_and_next (ieee);
+
return (c1 << 8) | c2;
}
@@ -268,10 +325,9 @@ bfd_get_string (ieee, string, length)
size_t length;
{
size_t i;
+
for (i = 0; i < length; i++)
- {
- string[i] = this_byte_and_next (ieee);
- }
+ string[i] = this_byte_and_next (ieee);
}
static char *
@@ -280,23 +336,25 @@ read_id (ieee)
{
size_t length;
char *string;
+
length = this_byte_and_next (ieee);
if (length <= 0x7f)
{
- /* Simple string of length 0 to 127 */
+ /* Simple string of length 0 to 127. */
}
else if (length == 0xde)
{
- /* Length is next byte, allowing 0..255 */
+ /* Length is next byte, allowing 0..255. */
length = this_byte_and_next (ieee);
}
else if (length == 0xdf)
{
- /* Length is next two bytes, allowing 0..65535 */
+ /* Length is next two bytes, allowing 0..65535. */
length = this_byte_and_next (ieee);
length = (length * 256) + this_byte_and_next (ieee);
}
- /* Buy memory and read string */
+
+ /* Buy memory and read string. */
string = bfd_alloc (ieee->abfd, (bfd_size_type) length + 1);
if (!string)
return NULL;
@@ -305,12 +363,12 @@ read_id (ieee)
return string;
}
-static boolean
+static bfd_boolean
ieee_write_expression (abfd, value, symbol, pcrel, index)
bfd *abfd;
bfd_vma value;
asymbol *symbol;
- boolean pcrel;
+ bfd_boolean pcrel;
unsigned int index;
{
unsigned int term_count = 0;
@@ -318,90 +376,91 @@ ieee_write_expression (abfd, value, symbol, pcrel, index)
if (value != 0)
{
if (! ieee_write_int (abfd, value))
- return false;
+ return FALSE;
term_count++;
}
- if (bfd_is_com_section (symbol->section)
- || bfd_is_und_section (symbol->section))
- {
- /* Def of a common symbol */
- if (! ieee_write_byte (abfd, ieee_variable_X_enum)
- || ! ieee_write_int (abfd, symbol->value))
- return false;
- term_count++;
- }
- else if (! bfd_is_abs_section (symbol->section))
+ /* Badly formatted binaries can have a missing symbol,
+ so test here to prevent a seg fault. */
+ if (symbol != NULL)
{
- /* Ref to defined symbol - */
-
- if (symbol->flags & BSF_GLOBAL)
+ if (bfd_is_com_section (symbol->section)
+ || bfd_is_und_section (symbol->section))
{
- if (! ieee_write_byte (abfd, ieee_variable_I_enum)
+ /* Def of a common symbol. */
+ if (! ieee_write_byte (abfd, ieee_variable_X_enum)
|| ! ieee_write_int (abfd, symbol->value))
- return false;
- term_count++;
+ return FALSE;
+ term_count ++;
}
- else if (symbol->flags & (BSF_LOCAL | BSF_SECTION_SYM))
+ else if (! bfd_is_abs_section (symbol->section))
{
- /* This is a reference to a defined local symbol. We can
- easily do a local as a section+offset. */
- if (! ieee_write_byte (abfd, ieee_variable_R_enum)
- || ! ieee_write_byte (abfd,
- (bfd_byte) (symbol->section->index
- + IEEE_SECTION_NUMBER_BASE)))
- return false;
- term_count++;
- if (symbol->value != 0)
+ /* Ref to defined symbol - */
+
+ if (symbol->flags & BSF_GLOBAL)
{
- if (! ieee_write_int (abfd, symbol->value))
- return false;
+ if (! ieee_write_byte (abfd, ieee_variable_I_enum)
+ || ! ieee_write_int (abfd, symbol->value))
+ return FALSE;
term_count++;
}
- }
- else
- {
- (*_bfd_error_handler)
- (_("%s: unrecognized symbol `%s' flags 0x%x"),
- bfd_get_filename (abfd), bfd_asymbol_name (symbol),
- symbol->flags);
- bfd_set_error (bfd_error_invalid_operation);
- return false;
+ else if (symbol->flags & (BSF_LOCAL | BSF_SECTION_SYM))
+ {
+ /* This is a reference to a defined local symbol. We can
+ easily do a local as a section+offset. */
+ if (! ieee_write_byte (abfd, ieee_variable_R_enum)
+ || ! ieee_write_byte (abfd,
+ (bfd_byte) (symbol->section->index
+ + IEEE_SECTION_NUMBER_BASE)))
+ return FALSE;
+
+ term_count++;
+ if (symbol->value != 0)
+ {
+ if (! ieee_write_int (abfd, symbol->value))
+ return FALSE;
+ term_count++;
+ }
+ }
+ else
+ {
+ (*_bfd_error_handler)
+ (_("%s: unrecognized symbol `%s' flags 0x%x"),
+ bfd_get_filename (abfd), bfd_asymbol_name (symbol),
+ symbol->flags);
+ bfd_set_error (bfd_error_invalid_operation);
+ return FALSE;
+ }
}
}
if (pcrel)
{
- /* subtract the pc from here by asking for PC of this section*/
+ /* Subtract the pc from here by asking for PC of this section. */
if (! ieee_write_byte (abfd, ieee_variable_P_enum)
|| ! ieee_write_byte (abfd,
(bfd_byte) (index + IEEE_SECTION_NUMBER_BASE))
|| ! ieee_write_byte (abfd, ieee_function_minus_enum))
- return false;
+ return FALSE;
}
/* Handle the degenerate case of a 0 address. */
if (term_count == 0)
- {
- if (! ieee_write_int (abfd, (bfd_vma) 0))
- return false;
- }
+ if (! ieee_write_int (abfd, (bfd_vma) 0))
+ return FALSE;
while (term_count > 1)
{
if (! ieee_write_byte (abfd, ieee_function_plus_enum))
- return false;
+ return FALSE;
term_count--;
}
- return true;
+ return TRUE;
}
-/*****************************************************************************/
+/* Writes any integer into the buffer supplied and always takes 5 bytes. */
-/*
-writes any integer into the buffer supplied and always takes 5 bytes
-*/
static void
ieee_write_int5 (buffer, value)
bfd_byte *buffer;
@@ -414,7 +473,7 @@ ieee_write_int5 (buffer, value)
buffer[4] = (value >> 0) & 0xff;
}
-static boolean
+static bfd_boolean
ieee_write_int5_out (abfd, value)
bfd *abfd;
bfd_vma value;
@@ -423,26 +482,28 @@ ieee_write_int5_out (abfd, value)
ieee_write_int5 (b, value);
if (bfd_bwrite ((PTR) b, (bfd_size_type) 5, abfd) != 5)
- return false;
- return true;
+ return FALSE;
+ return TRUE;
}
-static boolean
+static bfd_boolean
parse_int (ieee, value_ptr)
common_header_type *ieee;
bfd_vma *value_ptr;
{
int value = this_byte (ieee);
int result;
+
if (value >= 0 && value <= 127)
{
*value_ptr = value;
next_byte (ieee);
- return true;
+ return TRUE;
}
else if (value >= 0x80 && value <= 0x88)
{
unsigned int count = value & 0xf;
+
result = 0;
next_byte (ieee);
while (count)
@@ -451,15 +512,15 @@ parse_int (ieee, value_ptr)
count--;
}
*value_ptr = result;
- return true;
+ return TRUE;
}
- return false;
+ return FALSE;
}
static int
parse_i (ieee, ok)
common_header_type *ieee;
- boolean *ok;
+ bfd_boolean *ok;
{
bfd_vma x;
*ok = parse_int (ieee, &x);
@@ -486,12 +547,12 @@ typedef struct
#if KEEPMINUSPCININST
#define SRC_MASK(arg) arg
-#define PCREL_OFFSET false
+#define PCREL_OFFSET FALSE
#else
#define SRC_MASK(arg) 0
-#define PCREL_OFFSET true
+#define PCREL_OFFSET TRUE
#endif
@@ -500,57 +561,57 @@ static reloc_howto_type abs32_howto =
0,
2,
32,
- false,
+ FALSE,
0,
complain_overflow_bitfield,
0,
"abs32",
- true,
+ TRUE,
0xffffffff,
0xffffffff,
- false);
+ FALSE);
static reloc_howto_type abs16_howto =
HOWTO (1,
0,
1,
16,
- false,
+ FALSE,
0,
complain_overflow_bitfield,
0,
"abs16",
- true,
+ TRUE,
0x0000ffff,
0x0000ffff,
- false);
+ FALSE);
static reloc_howto_type abs8_howto =
HOWTO (1,
0,
0,
8,
- false,
+ FALSE,
0,
complain_overflow_bitfield,
0,
"abs8",
- true,
+ TRUE,
0x000000ff,
0x000000ff,
- false);
+ FALSE);
static reloc_howto_type rel32_howto =
HOWTO (1,
0,
2,
32,
- true,
+ TRUE,
0,
complain_overflow_signed,
0,
"rel32",
- true,
+ TRUE,
SRC_MASK (0xffffffff),
0xffffffff,
PCREL_OFFSET);
@@ -560,12 +621,12 @@ static reloc_howto_type rel16_howto =
0,
1,
16,
- true,
+ TRUE,
0,
complain_overflow_signed,
0,
"rel16",
- true,
+ TRUE,
SRC_MASK (0x0000ffff),
0x0000ffff,
PCREL_OFFSET);
@@ -575,12 +636,12 @@ static reloc_howto_type rel8_howto =
0,
0,
8,
- true,
+ TRUE,
0,
complain_overflow_signed,
0,
"rel8",
- true,
+ TRUE,
SRC_MASK (0x000000ff),
0x000000ff,
PCREL_OFFSET);
@@ -592,7 +653,7 @@ parse_expression (ieee, value, symbol, pcrel, extra, section)
ieee_data_type *ieee;
bfd_vma *value;
ieee_symbol_index_type *symbol;
- boolean *pcrel;
+ bfd_boolean *pcrel;
unsigned int *extra;
asection **section;
@@ -603,10 +664,10 @@ parse_expression (ieee, value, symbol, pcrel, extra, section)
#define INC sp++;
#define DEC sp--;
- boolean loop = true;
+ bfd_boolean loop = TRUE;
ieee_value_type stack[10];
- /* The stack pointer always points to the next unused location */
+ /* The stack pointer always points to the next unused location. */
#define PUSH(x,y,z) TOS.symbol=x;TOS.section=y;TOS.value=z;INC;
#define POP(x,y,z) DEC;x=TOS.symbol;y=TOS.section;z=TOS.value;
ieee_value_type *sp = stack;
@@ -617,35 +678,36 @@ parse_expression (ieee, value, symbol, pcrel, extra, section)
switch (this_byte (&(ieee->h)))
{
case ieee_variable_P_enum:
- /* P variable, current program counter for section n */
+ /* P variable, current program counter for section n. */
{
int section_n;
+
next_byte (&(ieee->h));
- *pcrel = true;
+ *pcrel = TRUE;
section_n = must_parse_int (&(ieee->h));
PUSH (NOSYMBOL, bfd_abs_section_ptr, 0);
break;
}
case ieee_variable_L_enum:
- /* L variable address of section N */
+ /* L variable address of section N. */
next_byte (&(ieee->h));
PUSH (NOSYMBOL, ieee->section_table[must_parse_int (&(ieee->h))], 0);
break;
case ieee_variable_R_enum:
- /* R variable, logical address of section module */
- /* FIXME, this should be different to L */
+ /* R variable, logical address of section module. */
+ /* FIXME, this should be different to L. */
next_byte (&(ieee->h));
PUSH (NOSYMBOL, ieee->section_table[must_parse_int (&(ieee->h))], 0);
break;
case ieee_variable_S_enum:
- /* S variable, size in MAUS of section module */
+ /* S variable, size in MAUS of section module. */
next_byte (&(ieee->h));
PUSH (NOSYMBOL,
0,
ieee->section_table[must_parse_int (&(ieee->h))]->_raw_size);
break;
case ieee_variable_I_enum:
- /* Push the address of variable n */
+ /* Push the address of variable n. */
{
ieee_symbol_index_type sy;
next_byte (&(ieee->h));
@@ -656,7 +718,7 @@ parse_expression (ieee, value, symbol, pcrel, extra, section)
}
break;
case ieee_variable_X_enum:
- /* Push the address of external variable n */
+ /* Push the address of external variable n. */
{
ieee_symbol_index_type sy;
next_byte (&(ieee->h));
@@ -706,7 +768,7 @@ parse_expression (ieee, value, symbol, pcrel, extra, section)
else
{
/* Thats all that we can understand. */
- loop = false;
+ loop = FALSE;
}
}
}
@@ -718,7 +780,6 @@ parse_expression (ieee, value, symbol, pcrel, extra, section)
terms. We can tell if that's the case by ensuring that
sp == stack here. If not, then we've pushed something too far,
so we keep adding. */
-
while (sp != stack + 1)
{
asection *section1;
@@ -764,7 +825,7 @@ ieee_part_after (ieee, here)
}
static unsigned int last_index;
-static char last_type; /* is the index for an X or a D */
+static char last_type; /* Is the index for an X or a D. */
static ieee_symbol_type *
get_symbol (abfd, ieee, last_symbol, symbol_count, pptr, max_index, this_type)
@@ -776,8 +837,9 @@ get_symbol (abfd, ieee, last_symbol, symbol_count, pptr, max_index, this_type)
unsigned int *max_index;
int this_type;
{
- /* Need a new symbol */
+ /* Need a new symbol. */
unsigned int new_index = must_parse_int (&(ieee->h));
+
if (new_index != last_index || this_type != last_type)
{
ieee_symbol_type *new_symbol;
@@ -793,9 +855,8 @@ get_symbol (abfd, ieee, last_symbol, symbol_count, pptr, max_index, this_type)
**pptr = new_symbol;
*pptr = &new_symbol->next;
if (new_index > *max_index)
- {
- *max_index = new_index;
- }
+ *max_index = new_index;
+
last_type = this_type;
new_symbol->symbol.section = bfd_abs_section_ptr;
return new_symbol;
@@ -803,7 +864,7 @@ get_symbol (abfd, ieee, last_symbol, symbol_count, pptr, max_index, this_type)
return last_symbol;
}
-static boolean
+static bfd_boolean
ieee_slurp_external_symbols (abfd)
bfd *abfd;
{
@@ -814,9 +875,9 @@ ieee_slurp_external_symbols (abfd)
ieee_symbol_type **prev_reference_ptr = &ieee->external_reference;
ieee_symbol_type *symbol = (ieee_symbol_type *) NULL;
unsigned int symbol_count = 0;
- boolean loop = true;
+ bfd_boolean loop = TRUE;
last_index = 0xffffff;
- ieee->symbol_table_full = true;
+ ieee->symbol_table_full = TRUE;
ieee_seek (ieee, offset);
@@ -831,7 +892,7 @@ ieee_slurp_external_symbols (abfd)
&prev_symbols_ptr,
&ieee->external_symbol_max_index, 'I');
if (symbol == NULL)
- return false;
+ return FALSE;
symbol->symbol.the_bfd = abfd;
symbol->symbol.name = read_id (&(ieee->h));
@@ -845,7 +906,7 @@ ieee_slurp_external_symbols (abfd)
&prev_symbols_ptr,
&ieee->external_symbol_max_index, 'D');
if (symbol == NULL)
- return false;
+ return FALSE;
BFD_ASSERT (symbol->index >= ieee->external_symbol_min_index);
@@ -878,12 +939,12 @@ ieee_slurp_external_symbols (abfd)
bfd_archive_filename (abfd), symbol_attribute_def,
symbol_name_index);
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
break;
}
break;
case ieee_external_reference_info_record_enum:
- /* Skip over ATX record. */
+ /* Skip over ATX record. */
parse_int (&(ieee->h), &value);
parse_int (&(ieee->h), &value);
parse_int (&(ieee->h), &value);
@@ -892,7 +953,7 @@ ieee_slurp_external_symbols (abfd)
case ieee_atn_record_enum:
/* We may get call optimization information here,
which we just ignore. The format is
- {$F1}${CE}{index}{$00}{$3F}{$3F}{#_of_ASNs} */
+ {$F1}${CE}{index}{$00}{$3F}{$3F}{#_of_ASNs}. */
parse_int (&ieee->h, &value);
parse_int (&ieee->h, &value);
parse_int (&ieee->h, &value);
@@ -902,7 +963,7 @@ ieee_slurp_external_symbols (abfd)
(_("%s: unexpected ATN type %d in external part"),
bfd_archive_filename (abfd), (int) value);
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
parse_int (&ieee->h, &value);
parse_int (&ieee->h, &value);
@@ -924,7 +985,7 @@ ieee_slurp_external_symbols (abfd)
(_("%s: unexpected type after ATN"),
bfd_archive_filename (abfd));
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
}
}
@@ -934,7 +995,7 @@ ieee_slurp_external_symbols (abfd)
{
unsigned int symbol_name_index;
ieee_symbol_index_type symbol_ignore;
- boolean pcrel_ignore;
+ bfd_boolean pcrel_ignore;
unsigned int extra;
next_byte (&(ieee->h));
next_byte (&(ieee->h));
@@ -978,16 +1039,16 @@ ieee_slurp_external_symbols (abfd)
bfd_vma size;
bfd_vma value;
next_byte (&(ieee->h));
- /* Throw away the external reference index */
+ /* Throw away the external reference index. */
(void) must_parse_int (&(ieee->h));
- /* Fetch the default size if not resolved */
+ /* Fetch the default size if not resolved. */
size = must_parse_int (&(ieee->h));
- /* Fetch the defautlt value if available */
+ /* Fetch the default value if available. */
if (! parse_int (&(ieee->h), &value))
{
value = 0;
}
- /* This turns into a common */
+ /* This turns into a common. */
symbol->symbol.section = bfd_com_section_ptr;
symbol->symbol.value = size;
}
@@ -1000,7 +1061,7 @@ ieee_slurp_external_symbols (abfd)
&prev_reference_ptr,
&ieee->external_reference_max_index, 'X');
if (symbol == NULL)
- return false;
+ return FALSE;
symbol->symbol.the_bfd = abfd;
symbol->symbol.name = read_id (&(ieee->h));
@@ -1013,7 +1074,7 @@ ieee_slurp_external_symbols (abfd)
break;
default:
- loop = false;
+ loop = FALSE;
}
}
@@ -1045,26 +1106,26 @@ ieee_slurp_external_symbols (abfd)
if (symbol_count != abfd->symcount)
{
/* There are gaps in the table -- */
- ieee->symbol_table_full = false;
+ ieee->symbol_table_full = FALSE;
}
*prev_symbols_ptr = (ieee_symbol_type *) NULL;
*prev_reference_ptr = (ieee_symbol_type *) NULL;
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
ieee_slurp_symbol_table (abfd)
bfd *abfd;
{
if (! IEEE_DATA (abfd)->read_symbols)
{
if (! ieee_slurp_external_symbols (abfd))
- return false;
- IEEE_DATA (abfd)->read_symbols = true;
+ return FALSE;
+ IEEE_DATA (abfd)->read_symbols = TRUE;
}
- return true;
+ return TRUE;
}
static long
@@ -1078,15 +1139,13 @@ ieee_get_symtab_upper_bound (abfd)
(abfd->symcount + 1) * (sizeof (ieee_symbol_type *)) : 0;
}
-/*
-Move from our internal lists to the canon table, and insert in
-symbol index order
-*/
+/* Move from our internal lists to the canon table, and insert in
+ symbol index order. */
extern const bfd_target ieee_vec;
static long
-ieee_get_symtab (abfd, location)
+ieee_canonicalize_symtab (abfd, location)
bfd *abfd;
asymbol **location;
{
@@ -1114,41 +1173,35 @@ ieee_get_symtab (abfd, location)
if (! ieee->symbol_table_full)
{
- /* Arrgh - there are gaps in the table, run through and fill them */
- /* up with pointers to a null place */
+ /* Arrgh - there are gaps in the table, run through and fill them
+ up with pointers to a null place. */
unsigned int i;
+
for (i = 0; i < abfd->symcount; i++)
- {
- location[i] = &empty_symbol;
- }
+ location[i] = &empty_symbol;
}
ieee->external_symbol_base_offset = -ieee->external_symbol_min_index;
for (symp = IEEE_DATA (abfd)->external_symbols;
symp != (ieee_symbol_type *) NULL;
symp = symp->next)
- {
- /* Place into table at correct index locations */
- location[symp->index + ieee->external_symbol_base_offset] = &symp->symbol;
- }
+ /* Place into table at correct index locations. */
+ location[symp->index + ieee->external_symbol_base_offset] = &symp->symbol;
- /* The external refs are indexed in a bit */
+ /* The external refs are indexed in a bit. */
ieee->external_reference_base_offset =
-ieee->external_reference_min_index + ieee->external_symbol_count;
for (symp = IEEE_DATA (abfd)->external_reference;
symp != (ieee_symbol_type *) NULL;
symp = symp->next)
- {
- location[symp->index + ieee->external_reference_base_offset] =
- &symp->symbol;
-
- }
+ location[symp->index + ieee->external_reference_base_offset] =
+ &symp->symbol;
}
+
if (abfd->symcount)
- {
- location[abfd->symcount] = (asymbol *) NULL;
- }
+ location[abfd->symcount] = (asymbol *) NULL;
+
return abfd->symcount;
}
@@ -1212,7 +1265,7 @@ ieee_slurp_sections (abfd)
{
bfd_byte section_type[3];
ieee_seek (ieee, offset);
- while (true)
+ while (TRUE)
{
switch (this_byte (&(ieee->h)))
{
@@ -1228,34 +1281,33 @@ ieee_slurp_sections (abfd)
section_type[0] = this_byte_and_next (&(ieee->h));
/* Set minimal section attributes. Attributes are
- extended later, based on section contents. */
-
+ extended later, based on section contents. */
switch (section_type[0])
{
case 0xC1:
- /* Normal attributes for absolute sections */
+ /* Normal attributes for absolute sections. */
section_type[1] = this_byte (&(ieee->h));
section->flags = SEC_ALLOC;
switch (section_type[1])
{
- case 0xD3: /* AS Absolute section attributes */
+ case 0xD3: /* AS Absolute section attributes. */
next_byte (&(ieee->h));
section_type[2] = this_byte (&(ieee->h));
switch (section_type[2])
{
case 0xD0:
- /* Normal code */
+ /* Normal code. */
next_byte (&(ieee->h));
section->flags |= SEC_CODE;
break;
case 0xC4:
- /* Normal data */
+ /* Normal data. */
next_byte (&(ieee->h));
section->flags |= SEC_DATA;
break;
case 0xD2:
next_byte (&(ieee->h));
- /* Normal rom data */
+ /* Normal rom data. */
section->flags |= SEC_ROM | SEC_DATA;
break;
default:
@@ -1263,20 +1315,20 @@ ieee_slurp_sections (abfd)
}
}
break;
- case 0xC3: /* Named relocatable sections (type C) */
+ case 0xC3: /* Named relocatable sections (type C). */
section_type[1] = this_byte (&(ieee->h));
section->flags = SEC_ALLOC;
switch (section_type[1])
{
- case 0xD0: /* Normal code (CP) */
+ case 0xD0: /* Normal code (CP). */
next_byte (&(ieee->h));
section->flags |= SEC_CODE;
break;
- case 0xC4: /* Normal data (CD) */
+ case 0xC4: /* Normal data (CD). */
next_byte (&(ieee->h));
section->flags |= SEC_DATA;
break;
- case 0xD2: /* Normal rom data (CR) */
+ case 0xD2: /* Normal rom data (CR). */
next_byte (&(ieee->h));
section->flags |= SEC_ROM | SEC_DATA;
break;
@@ -1285,12 +1337,12 @@ ieee_slurp_sections (abfd)
}
}
- /* Read section name, use it if non empty. */
+ /* Read section name, use it if non empty. */
name = read_id (&ieee->h);
if (name[0])
section->name = name;
- /* Skip these fields, which we don't care about */
+ /* Skip these fields, which we don't care about. */
{
bfd_vma parent, brother, context;
parse_int (&(ieee->h), &parent);
@@ -1371,7 +1423,7 @@ ieee_slurp_sections (abfd)
at the area in the file so that program which understand can dig it
out. */
-static boolean
+static bfd_boolean
ieee_slurp_debug (abfd)
bfd *abfd;
{
@@ -1380,23 +1432,21 @@ ieee_slurp_debug (abfd)
file_ptr debug_end;
if (ieee->w.r.debug_information_part == 0)
- return true;
+ return TRUE;
sec = bfd_make_section (abfd, ".debug");
if (sec == NULL)
- return false;
+ return FALSE;
sec->flags |= SEC_DEBUGGING | SEC_HAS_CONTENTS;
sec->filepos = ieee->w.r.debug_information_part;
debug_end = ieee_part_after (ieee, ieee->w.r.debug_information_part);
sec->_raw_size = debug_end - ieee->w.r.debug_information_part;
- return true;
+ return TRUE;
}
-/***********************************************************************
-* archive stuff
-*/
+/* Archive stuff. */
const bfd_target *
ieee_archive_p (abfd)
@@ -1566,8 +1616,8 @@ ieee_object_p (abfd)
if (this_byte_and_next (&(ieee->h)) != Module_Beginning)
goto got_wrong_format;
- ieee->read_symbols = false;
- ieee->read_data = false;
+ ieee->read_symbols = FALSE;
+ ieee->read_data = FALSE;
ieee->section_count = 0;
ieee->external_symbol_max_index = 0;
ieee->external_symbol_min_index = IEEE_PUBLIC_BASE;
@@ -1582,16 +1632,14 @@ ieee_object_p (abfd)
goto got_wrong_format;
ieee->mb.module_name = read_id (&(ieee->h));
if (abfd->filename == (const char *) NULL)
- {
- abfd->filename = ieee->mb.module_name;
- }
- /* Determine the architecture and machine type of the object file.
- */
+ abfd->filename = ieee->mb.module_name;
+
+ /* Determine the architecture and machine type of the object file. */
{
const bfd_arch_info_type *arch;
char family[10];
- /* IEEE does not specify the format of the processor identificaton
+ /* IEEE does not specify the format of the processor identification
string, so the compiler is free to put in it whatever it wants.
We try here to recognize different processors belonging to the
m68k family. Code for other processors can be added here. */
@@ -1627,7 +1675,7 @@ ieee_object_p (abfd)
}
else if (TOUPPER (processor[3]) == 'F') /* 68F333 */
strcpy (family, "68332"); /* CPU32 */
- else if ((TOUPPER (processor[3]) == 'C') /* Embedded controllers */
+ else if ((TOUPPER (processor[3]) == 'C') /* Embedded controllers. */
&& ((TOUPPER (processor[2]) == 'E')
|| (TOUPPER (processor[2]) == 'H')
|| (TOUPPER (processor[2]) == 'L')))
@@ -1636,7 +1684,7 @@ ieee_object_p (abfd)
strncat (family, processor + 4, 7);
family[9] = '\0';
}
- else /* "Regular" processors */
+ else /* "Regular" processors. */
{
strncpy (family, processor, 9);
family[9] = '\0';
@@ -1658,43 +1706,34 @@ ieee_object_p (abfd)
}
if (this_byte (&(ieee->h)) != (int) ieee_address_descriptor_enum)
- {
- goto fail;
- }
+ goto fail;
+
next_byte (&(ieee->h));
if (! parse_int (&(ieee->h), &ieee->ad.number_of_bits_mau))
- {
- goto fail;
- }
+ goto fail;
+
if (! parse_int (&(ieee->h), &ieee->ad.number_of_maus_in_address))
- {
- goto fail;
- }
+ goto fail;
- /* If there is a byte order info, take it */
- if (this_byte (&(ieee->h)) == (int) ieee_variable_L_enum ||
- this_byte (&(ieee->h)) == (int) ieee_variable_M_enum)
+ /* If there is a byte order info, take it. */
+ if (this_byte (&(ieee->h)) == (int) ieee_variable_L_enum
+ || this_byte (&(ieee->h)) == (int) ieee_variable_M_enum)
next_byte (&(ieee->h));
for (part = 0; part < N_W_VARIABLES; part++)
{
- boolean ok;
+ bfd_boolean ok;
+
if (read_2bytes (&(ieee->h)) != (int) ieee_assign_value_to_variable_enum)
- {
- goto fail;
- }
+ goto fail;
+
if (this_byte_and_next (&(ieee->h)) != part)
- {
- goto fail;
- }
+ goto fail;
ieee->w.offset[part] = parse_i (&(ieee->h), &ok);
if (! ok)
- {
- goto fail;
- }
-
+ goto fail;
}
if (ieee->w.r.external_part != 0)
@@ -1703,7 +1742,7 @@ ieee_object_p (abfd)
/* By now we know that this is a real IEEE file, we're going to read
the whole thing into memory so that we can run up and down it
quickly. We can work out how big the file is from the trailer
- record */
+ record. */
amt = ieee->w.r.me_record + 1;
IEEE_DATA (abfd)->h.first_byte =
@@ -1724,7 +1763,6 @@ ieee_object_p (abfd)
/* Parse section data to activate file and section flags implied by
section contents. */
-
if (! ieee_slurp_section_data (abfd))
goto fail;
@@ -1777,6 +1815,7 @@ ieee_print_symbol (abfd, afile, symbol, how)
(symbol->section == (asection *) NULL
? "*abs"
: symbol->section->name);
+
if (symbol->name[0] == ' ')
{
fprintf (file, "* empty table entry ");
@@ -1796,7 +1835,7 @@ ieee_print_symbol (abfd, afile, symbol, how)
}
}
-static boolean
+static bfd_boolean
do_one (ieee, current_map, location_ptr, s, iterations)
ieee_data_type *ieee;
ieee_per_section_type *current_map;
@@ -1810,6 +1849,7 @@ do_one (ieee, current_map, location_ptr, s, iterations)
{
unsigned int number_of_maus;
unsigned int i;
+
next_byte (&(ieee->h));
number_of_maus = must_parse_int (&(ieee->h));
@@ -1823,7 +1863,8 @@ do_one (ieee, current_map, location_ptr, s, iterations)
case ieee_load_with_relocation_enum:
{
- boolean loop = true;
+ bfd_boolean loop = TRUE;
+
next_byte (&(ieee->h));
while (loop)
{
@@ -1836,14 +1877,14 @@ do_one (ieee, current_map, location_ptr, s, iterations)
case ieee_function_either_open_b_enum:
{
unsigned int extra = 4;
- boolean pcrel = false;
+ bfd_boolean pcrel = FALSE;
asection *section;
ieee_reloc_type *r;
bfd_size_type amt = sizeof (ieee_reloc_type);
r = (ieee_reloc_type *) bfd_alloc (ieee->h.abfd, amt);
if (!r)
- return false;
+ return FALSE;
*(current_map->reloc_tail_ptr) = r;
current_map->reloc_tail_ptr = &r->next;
@@ -1865,7 +1906,7 @@ do_one (ieee, current_map, location_ptr, s, iterations)
if (this_byte (&(ieee->h)) == (int) ieee_comma)
{
next_byte (&(ieee->h));
- /* Fetch number of bytes to pad */
+ /* Fetch number of bytes to pad. */
extra = must_parse_int (&(ieee->h));
};
@@ -1883,7 +1924,7 @@ do_one (ieee, current_map, location_ptr, s, iterations)
default:
break;
}
- /* Build a relocation entry for this type */
+ /* Build a relocation entry for this type. */
/* If pc rel then stick -ve pc into instruction
and take out of reloc ..
@@ -1962,7 +2003,7 @@ do_one (ieee, current_map, location_ptr, s, iterations)
default:
BFD_FAIL ();
- return false;
+ return FALSE;
}
}
break;
@@ -1980,7 +2021,7 @@ do_one (ieee, current_map, location_ptr, s, iterations)
}
else
{
- loop = false;
+ loop = FALSE;
}
}
}
@@ -1988,15 +2029,16 @@ do_one (ieee, current_map, location_ptr, s, iterations)
/* Prevent more than the first load-item of an LR record
from being repeated (MRI convention). */
if (iterations != 1)
- loop = false;
+ loop = FALSE;
}
}
}
- return true;
+ return TRUE;
}
-/* Read in all the section data and relocation stuff too */
-static boolean
+/* Read in all the section data and relocation stuff too. */
+
+static bfd_boolean
ieee_slurp_section_data (abfd)
bfd *abfd;
{
@@ -2006,45 +2048,43 @@ ieee_slurp_section_data (abfd)
ieee_per_section_type *current_map = (ieee_per_section_type *) NULL;
asection *s;
- /* Seek to the start of the data area */
+ /* Seek to the start of the data area. */
if (ieee->read_data)
- return true;
- ieee->read_data = true;
+ return TRUE;
+ ieee->read_data = TRUE;
ieee_seek (ieee, ieee->w.r.data_part);
- /* Allocate enough space for all the section contents */
-
+ /* Allocate enough space for all the section contents. */
for (s = abfd->sections; s != (asection *) NULL; s = s->next)
{
- ieee_per_section_type *per = (ieee_per_section_type *) s->used_by_bfd;
+ ieee_per_section_type *per = ieee_per_section (s);
if ((s->flags & SEC_DEBUGGING) != 0)
continue;
per->data = (bfd_byte *) bfd_alloc (ieee->h.abfd, s->_raw_size);
if (!per->data)
- return false;
- /*SUPPRESS 68*/
+ return FALSE;
per->reloc_tail_ptr =
(ieee_reloc_type **) & (s->relocation);
}
- while (true)
+ while (TRUE)
{
switch (this_byte (&(ieee->h)))
{
- /* IF we see anything strange then quit */
+ /* IF we see anything strange then quit. */
default:
- return true;
+ return TRUE;
case ieee_set_current_section_enum:
next_byte (&(ieee->h));
section_number = must_parse_int (&(ieee->h));
s = ieee->section_table[section_number];
s->flags |= SEC_LOAD | SEC_HAS_CONTENTS;
- current_map = (ieee_per_section_type *) s->used_by_bfd;
+ current_map = ieee_per_section (s);
location_ptr = current_map->data - s->vma;
- /* The document I have says that Microtec's compilers reset */
- /* this after a sec section, even though the standard says not */
- /* to. SO .. */
+ /* The document I have says that Microtec's compilers reset
+ this after a sec section, even though the standard says not
+ to, SO... */
current_map->pc = s->vma;
break;
@@ -2057,9 +2097,10 @@ ieee_slurp_section_data (abfd)
bfd_vma value;
ieee_symbol_index_type symbol;
unsigned int extra;
- boolean pcrel;
+ bfd_boolean pcrel;
+
next_byte (&(ieee->h));
- must_parse_int (&(ieee->h)); /* Throw away section #*/
+ must_parse_int (&(ieee->h)); /* Throw away section #. */
parse_expression (ieee, &value,
&symbol,
&pcrel, &extra,
@@ -2074,28 +2115,27 @@ ieee_slurp_section_data (abfd)
if (this_byte (&(ieee->h)) == ieee_function_either_open_b_enum)
next_byte (&(ieee->h));
abfd->start_address = must_parse_int (&(ieee->h));
- /* We've got to the end of the data now - */
- return true;
+ /* We've got to the end of the data now - */
+ return TRUE;
default:
BFD_FAIL ();
- return false;
+ return FALSE;
}
break;
case ieee_repeat_data_enum:
{
/* Repeat the following LD or LR n times - we do this by
- remembering the stream pointer before running it and
- resetting it and running it n times. We special case
- the repetition of a repeat_data/load_constant
- */
-
+ remembering the stream pointer before running it and
+ resetting it and running it n times. We special case
+ the repetition of a repeat_data/load_constant. */
unsigned int iterations;
unsigned char *start;
+
next_byte (&(ieee->h));
iterations = must_parse_int (&(ieee->h));
start = ieee->h.input_p;
- if (start[0] == (int) ieee_load_constant_bytes_enum &&
- start[1] == 1)
+ if (start[0] == (int) ieee_load_constant_bytes_enum
+ && start[1] == 1)
{
while (iterations != 0)
{
@@ -2113,7 +2153,7 @@ ieee_slurp_section_data (abfd)
ieee->h.input_p = start;
if (!do_one (ieee, current_map, location_ptr, s,
(int) iterations))
- return false;
+ return FALSE;
iterations--;
}
}
@@ -2121,26 +2161,24 @@ ieee_slurp_section_data (abfd)
break;
case ieee_load_constant_bytes_enum:
case ieee_load_with_relocation_enum:
- {
- if (!do_one (ieee, current_map, location_ptr, s, 1))
- return false;
- }
+ if (!do_one (ieee, current_map, location_ptr, s, 1))
+ return FALSE;
}
}
}
-static boolean
+static bfd_boolean
ieee_new_section_hook (abfd, newsect)
bfd *abfd;
asection *newsect;
{
- newsect->used_by_bfd = (PTR)
- bfd_alloc (abfd, (bfd_size_type) sizeof (ieee_per_section_type));
+ newsect->used_by_bfd
+ = (PTR) bfd_alloc (abfd, (bfd_size_type) sizeof (ieee_per_section_type));
if (!newsect->used_by_bfd)
- return false;
+ return FALSE;
ieee_per_section (newsect)->data = (bfd_byte *) NULL;
ieee_per_section (newsect)->section = newsect;
- return true;
+ return TRUE;
}
static long
@@ -2155,7 +2193,7 @@ ieee_get_reloc_upper_bound (abfd, asect)
return (asect->reloc_count + 1) * sizeof (arelent *);
}
-static boolean
+static bfd_boolean
ieee_get_section_contents (abfd, section, location, offset, count)
bfd *abfd;
sec_ptr section;
@@ -2163,13 +2201,13 @@ ieee_get_section_contents (abfd, section, location, offset, count)
file_ptr offset;
bfd_size_type count;
{
- ieee_per_section_type *p = (ieee_per_section_type *) section->used_by_bfd;
+ ieee_per_section_type *p = ieee_per_section (section);
if ((section->flags & SEC_DEBUGGING) != 0)
return _bfd_generic_get_section_contents (abfd, section, location,
offset, count);
ieee_slurp_section_data (abfd);
(void) memcpy ((PTR) location, (PTR) (p->data + offset), (unsigned) count);
- return true;
+ return TRUE;
}
static long
@@ -2179,7 +2217,6 @@ ieee_canonicalize_reloc (abfd, section, relptr, symbols)
arelent **relptr;
asymbol **symbols;
{
-/* ieee_per_section_type *p = (ieee_per_section_type *) section->used_by_bfd;*/
ieee_reloc_type *src = (ieee_reloc_type *) (section->relocation);
ieee_data_type *ieee = IEEE_DATA (abfd);
@@ -2188,7 +2225,7 @@ ieee_canonicalize_reloc (abfd, section, relptr, symbols)
while (src != (ieee_reloc_type *) NULL)
{
- /* Work out which symbol to attach it this reloc to */
+ /* Work out which symbol to attach it this reloc to. */
switch (src->symbol.letter)
{
case 'I':
@@ -2227,7 +2264,7 @@ comp (ap, bp)
/* Write the section headers. */
-static boolean
+static bfd_boolean
ieee_write_section_part (abfd)
bfd *abfd;
{
@@ -2243,19 +2280,19 @@ ieee_write_section_part (abfd)
|| ! ieee_write_byte (abfd,
(bfd_byte) (s->index
+ IEEE_SECTION_NUMBER_BASE)))
- return false;
+ return FALSE;
if (abfd->flags & EXEC_P)
{
- /* This image is executable, so output absolute sections */
+ /* This image is executable, so output absolute sections. */
if (! ieee_write_byte (abfd, ieee_variable_A_enum)
|| ! ieee_write_byte (abfd, ieee_variable_S_enum))
- return false;
+ return FALSE;
}
else
{
if (! ieee_write_byte (abfd, ieee_variable_C_enum))
- return false;
+ return FALSE;
}
switch (s->flags & (SEC_CODE | SEC_DATA | SEC_ROM))
@@ -2263,64 +2300,64 @@ ieee_write_section_part (abfd)
case SEC_CODE | SEC_LOAD:
case SEC_CODE:
if (! ieee_write_byte (abfd, ieee_variable_P_enum))
- return false;
+ return FALSE;
break;
case SEC_DATA:
default:
if (! ieee_write_byte (abfd, ieee_variable_D_enum))
- return false;
+ return FALSE;
break;
case SEC_ROM:
case SEC_ROM | SEC_DATA:
case SEC_ROM | SEC_LOAD:
case SEC_ROM | SEC_DATA | SEC_LOAD:
if (! ieee_write_byte (abfd, ieee_variable_R_enum))
- return false;
+ return FALSE;
}
if (! ieee_write_id (abfd, s->name))
- return false;
+ return FALSE;
#if 0
ieee_write_int (abfd, 0); /* Parent */
ieee_write_int (abfd, 0); /* Brother */
ieee_write_int (abfd, 0); /* Context */
#endif
- /* Alignment */
+ /* Alignment. */
if (! ieee_write_byte (abfd, ieee_section_alignment_enum)
|| ! ieee_write_byte (abfd,
(bfd_byte) (s->index
+ IEEE_SECTION_NUMBER_BASE))
|| ! ieee_write_int (abfd, (bfd_vma) 1 << s->alignment_power))
- return false;
+ return FALSE;
- /* Size */
+ /* Size. */
if (! ieee_write_2bytes (abfd, ieee_section_size_enum)
|| ! ieee_write_byte (abfd,
(bfd_byte) (s->index
+ IEEE_SECTION_NUMBER_BASE))
|| ! ieee_write_int (abfd, s->_raw_size))
- return false;
+ return FALSE;
if (abfd->flags & EXEC_P)
{
- /* Relocateable sections don't have asl records */
- /* Vma */
+ /* Relocateable sections don't have asl records. */
+ /* Vma. */
if (! ieee_write_2bytes (abfd, ieee_section_base_address_enum)
|| ! ieee_write_byte (abfd,
((bfd_byte)
(s->index
+ IEEE_SECTION_NUMBER_BASE)))
|| ! ieee_write_int (abfd, s->lma))
- return false;
+ return FALSE;
}
}
}
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
do_with_relocs (abfd, s)
bfd *abfd;
asection *s;
@@ -2337,51 +2374,49 @@ do_with_relocs (abfd, s)
sizeof (arelent **),
comp);
- /* Output the section preheader */
+ /* Output the section preheader. */
if (! ieee_write_byte (abfd, ieee_set_current_section_enum)
|| ! ieee_write_byte (abfd,
(bfd_byte) (s->index + IEEE_SECTION_NUMBER_BASE))
|| ! ieee_write_2bytes (abfd, ieee_set_current_pc_enum)
|| ! ieee_write_byte (abfd,
(bfd_byte) (s->index + IEEE_SECTION_NUMBER_BASE)))
- return false;
+ return FALSE;
if ((abfd->flags & EXEC_P) != 0 && relocs_to_go == 0)
{
if (! ieee_write_int (abfd, s->lma))
- return false;
+ return FALSE;
}
else
{
if (! ieee_write_expression (abfd, (bfd_vma) 0, s->symbol, 0, 0))
- return false;
+ return FALSE;
}
if (relocs_to_go == 0)
{
/* If there aren't any relocations then output the load constant
- byte opcode rather than the load with relocation opcode */
-
+ byte opcode rather than the load with relocation opcode. */
while (current_byte_index < s->_raw_size)
{
bfd_size_type run;
unsigned int MAXRUN = 127;
+
run = MAXRUN;
if (run > s->_raw_size - current_byte_index)
- {
- run = s->_raw_size - current_byte_index;
- }
+ run = s->_raw_size - current_byte_index;
if (run != 0)
{
if (! ieee_write_byte (abfd, ieee_load_constant_bytes_enum))
- return false;
- /* Output a stream of bytes */
+ return FALSE;
+ /* Output a stream of bytes. */
if (! ieee_write_int (abfd, run))
- return false;
+ return FALSE;
if (bfd_bwrite ((PTR) (stream + current_byte_index), run, abfd)
!= run)
- return false;
+ return FALSE;
current_byte_index += run;
}
}
@@ -2389,7 +2424,7 @@ do_with_relocs (abfd, s)
else
{
if (! ieee_write_byte (abfd, ieee_load_with_relocation_enum))
- return false;
+ return FALSE;
/* Output the data stream as the longest sequence of bytes
possible, allowing for the a reasonable packet size and
@@ -2397,15 +2432,16 @@ do_with_relocs (abfd, s)
if ((PTR) stream == (PTR) NULL)
{
- /* Outputting a section without data, fill it up */
+ /* Outputting a section without data, fill it up. */
stream = (unsigned char *) bfd_zalloc (abfd, s->_raw_size);
if (!stream)
- return false;
+ return FALSE;
}
while (current_byte_index < s->_raw_size)
{
bfd_size_type run;
unsigned int MAXRUN = 127;
+
if (relocs_to_go)
{
run = (*p)->address - current_byte_index;
@@ -2413,25 +2449,23 @@ do_with_relocs (abfd, s)
run = MAXRUN;
}
else
- {
- run = MAXRUN;
- }
+ run = MAXRUN;
+
if (run > s->_raw_size - current_byte_index)
- {
- run = s->_raw_size - current_byte_index;
- }
+ run = s->_raw_size - current_byte_index;
if (run != 0)
{
- /* Output a stream of bytes */
+ /* Output a stream of bytes. */
if (! ieee_write_int (abfd, run))
- return false;
+ return FALSE;
if (bfd_bwrite ((PTR) (stream + current_byte_index), run, abfd)
!= run)
- return false;
+ return FALSE;
current_byte_index += run;
}
- /* Output any relocations here */
+
+ /* Output any relocations here. */
if (relocs_to_go && (*p) && (*p)->address == current_byte_index)
{
while (relocs_to_go
@@ -2439,14 +2473,10 @@ do_with_relocs (abfd, s)
{
arelent *r = *p;
bfd_signed_vma ov;
-
#if 0
if (r->howto->pc_relative)
- {
- r->addend += current_byte_index;
- }
+ r->addend += current_byte_index;
#endif
-
switch (r->howto->size)
{
case 2:
@@ -2468,7 +2498,7 @@ do_with_relocs (abfd, s)
default:
ov = 0;
BFD_FAIL ();
- return false;
+ return FALSE;
}
ov &= r->howto->src_mask;
@@ -2479,7 +2509,7 @@ do_with_relocs (abfd, s)
if (! ieee_write_byte (abfd,
ieee_function_either_open_b_enum))
- return false;
+ return FALSE;
/* abort();*/
@@ -2489,7 +2519,7 @@ do_with_relocs (abfd, s)
*(r->sym_ptr_ptr),
r->howto->pc_relative,
(unsigned) s->index))
- return false;
+ return FALSE;
}
else
{
@@ -2497,7 +2527,7 @@ do_with_relocs (abfd, s)
(asymbol *) NULL,
r->howto->pc_relative,
(unsigned) s->index))
- return false;
+ return FALSE;
}
if (number_of_maus_in_address
@@ -2505,11 +2535,11 @@ do_with_relocs (abfd, s)
{
bfd_vma rsize = bfd_get_reloc_size (r->howto);
if (! ieee_write_int (abfd, rsize))
- return false;
+ return FALSE;
}
if (! ieee_write_byte (abfd,
ieee_function_either_close_b_enum))
- return false;
+ return FALSE;
relocs_to_go--;
p++;
@@ -2519,14 +2549,14 @@ do_with_relocs (abfd, s)
}
}
- return true;
+ return TRUE;
}
/* If there are no relocations in the output section then we can be
clever about how we write. We block items up into a max of 127
bytes. */
-static boolean
+static bfd_boolean
do_as_repeat (abfd, s)
bfd *abfd;
asection *s;
@@ -2542,17 +2572,17 @@ do_as_repeat (abfd, s)
|| ! ieee_write_byte (abfd,
(bfd_byte) (s->index
+ IEEE_SECTION_NUMBER_BASE)))
- return false;
+ return FALSE;
if ((abfd->flags & EXEC_P) != 0)
{
if (! ieee_write_int (abfd, s->lma))
- return false;
+ return FALSE;
}
else
{
if (! ieee_write_expression (abfd, (bfd_vma) 0, s->symbol, 0, 0))
- return false;
+ return FALSE;
}
if (! ieee_write_byte (abfd, ieee_repeat_data_enum)
@@ -2560,13 +2590,13 @@ do_as_repeat (abfd, s)
|| ! ieee_write_byte (abfd, ieee_load_constant_bytes_enum)
|| ! ieee_write_byte (abfd, 1)
|| ! ieee_write_byte (abfd, 0))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
do_without_relocs (abfd, s)
bfd *abfd;
asection *s;
@@ -2576,25 +2606,26 @@ do_without_relocs (abfd, s)
if (stream == 0 || ((s->flags & SEC_LOAD) == 0))
{
if (! do_as_repeat (abfd, s))
- return false;
+ return FALSE;
}
else
{
unsigned int i;
+
for (i = 0; i < s->_raw_size; i++)
{
if (stream[i] != 0)
{
if (! do_with_relocs (abfd, s))
- return false;
- return true;
+ return FALSE;
+ return TRUE;
}
}
if (! do_as_repeat (abfd, s))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
@@ -2608,7 +2639,7 @@ static bfd *input_bfd;
static bfd *output_bfd;
static int output_buffer;
-static boolean
+static bfd_boolean
ieee_mkobject (abfd)
bfd *abfd;
{
@@ -2642,6 +2673,7 @@ static void
flush ()
{
bfd_size_type amt = output_ptr - output_ptr_start;
+
if (bfd_bwrite ((PTR) (output_ptr_start), amt, output_bfd) != amt)
abort ();
output_ptr = output_ptr_start;
@@ -2663,20 +2695,14 @@ write_int (value)
else
{
unsigned int length;
- /* How many significant bytes ? */
- /* FIXME FOR LONGER INTS */
+ /* How many significant bytes ? */
+ /* FIXME FOR LONGER INTS. */
if (value & 0xff000000)
- {
- length = 4;
- }
+ length = 4;
else if (value & 0x00ff0000)
- {
- length = 3;
- }
+ length = 3;
else if (value & 0x0000ff00)
- {
- length = 2;
- }
+ length = 2;
else
length = 1;
@@ -2692,7 +2718,6 @@ write_int (value)
case 1:
OUT (value);
}
-
}
}
@@ -2701,6 +2726,7 @@ copy_id ()
{
int length = THIS ();
char ch;
+
OUT (length);
NEXT ();
while (length--)
@@ -2718,6 +2744,7 @@ copy_expression ()
int stack[10];
int *tos = stack;
int value;
+
while (1)
{
switch (THIS ())
@@ -2765,7 +2792,7 @@ copy_expression ()
default:
if (THIS () > 0x84)
{
- /* Not a number, just bug out with the answer */
+ /* Not a number, just bug out with the answer. */
write_int (*(--tos));
return;
}
@@ -2773,7 +2800,7 @@ copy_expression ()
NEXT ();
break;
case 0xa5:
- /* PLUS anything */
+ /* PLUS anything. */
value = *(--tos);
value += *(--tos);
*tos++ = value;
@@ -2784,6 +2811,7 @@ copy_expression ()
int section_number;
ieee_data_type *ieee;
asection *s;
+
NEXT ();
section_number = THIS ();
@@ -2817,7 +2845,7 @@ fill_int (buf)
{
if (buf->buffer == output_buffer)
{
- /* Still a chance to output the size */
+ /* Still a chance to output the size. */
int value = output_ptr - buf->ptrp + 3;
buf->ptrp[0] = value >> 24;
buf->ptrp[1] = value >> 16;
@@ -2832,6 +2860,7 @@ drop_int (buf)
{
int type = THIS ();
int ch;
+
if (type <= 0x84)
{
NEXT ();
@@ -2905,7 +2934,8 @@ static void
f1_record ()
{
int ch;
- /* ATN record */
+
+ /* ATN record. */
NEXT ();
ch = THIS ();
switch (ch)
@@ -2945,7 +2975,7 @@ f1_record ()
}
break;
case 0xd8:
- /* EXternal ref */
+ /* EXternal ref. */
NEXT ();
OUT (0xf1);
OUT (0xd8);
@@ -2999,13 +3029,12 @@ f1_record ()
break;
}
}
-
}
static void
f0_record ()
{
- /* Attribute record */
+ /* Attribute record. */
NEXT ();
OUT (0xf0);
INTn (Symbol name);
@@ -3016,6 +3045,7 @@ static void
copy_till_end ()
{
int ch = THIS ();
+
while (1)
{
while (ch <= 0x80)
@@ -3074,11 +3104,12 @@ f8_record ()
case 0x01:
case 0x02:
case 0x03:
- /* Unique typedefs for module */
- /* GLobal typedefs */
- /* High level module scope beginning */
+ /* Unique typedefs for module. */
+ /* GLobal typedefs. */
+ /* High level module scope beginning. */
{
struct output_buffer_struct ob;
+
NEXT ();
OUT (0xf8);
OUT (ch);
@@ -3093,9 +3124,10 @@ f8_record ()
}
break;
case 0x04:
- /* Global function */
+ /* Global function. */
{
struct output_buffer_struct ob;
+
NEXT ();
OUT (0xf8);
OUT (0x04);
@@ -3115,9 +3147,10 @@ f8_record ()
break;
case 0x05:
- /* File name for source line numbers */
+ /* File name for source line numbers. */
{
struct output_buffer_struct ob;
+
NEXT ();
OUT (0xf8);
OUT (0x05);
@@ -3137,9 +3170,10 @@ f8_record ()
break;
case 0x06:
- /* Local function */
+ /* Local function. */
{
struct output_buffer_struct ob;
+
NEXT ();
OUT (0xf8);
OUT (0x06);
@@ -3157,7 +3191,7 @@ f8_record ()
break;
case 0x0a:
- /* Assembler module scope beginning -*/
+ /* Assembler module scope beginning - */
{
struct output_buffer_struct ob;
@@ -3186,6 +3220,7 @@ f8_record ()
case 0x0b:
{
struct output_buffer_struct ob;
+
NEXT ();
OUT (0xf8);
OUT (0x0b);
@@ -3222,6 +3257,7 @@ static void
block ()
{
int ch;
+
while (1)
{
ch = THIS ();
@@ -3253,11 +3289,8 @@ block ()
}
-
-/* relocate_debug,
- moves all the debug information from the source bfd to the output
- bfd, and relocates any expressions it finds
-*/
+/* Moves all the debug information from the source bfd to the output
+ bfd, and relocates any expressions it finds. */
static void
relocate_debug (output, input)
@@ -3280,14 +3313,14 @@ relocate_debug (output, input)
/* Gather together all the debug information from each input BFD into
one place, relocating it and emitting it as we go. */
-static boolean
+static bfd_boolean
ieee_write_debug_part (abfd)
bfd *abfd;
{
ieee_data_type *ieee = IEEE_DATA (abfd);
bfd_chain_type *chain = ieee->chain_root;
unsigned char obuff[OBS];
- boolean some_debug = false;
+ bfd_boolean some_debug = FALSE;
file_ptr here = bfd_tell (abfd);
output_ptr_start = output_ptr = obuff;
@@ -3305,12 +3338,12 @@ ieee_write_debug_part (abfd)
if (s == NULL)
{
ieee->w.r.debug_information_part = 0;
- return true;
+ return TRUE;
}
ieee->w.r.debug_information_part = here;
if (bfd_bwrite (s->contents, s->_raw_size, abfd) != s->_raw_size)
- return false;
+ return FALSE;
}
else
{
@@ -3318,40 +3351,40 @@ ieee_write_debug_part (abfd)
{
bfd *entry = chain->this;
ieee_data_type *entry_ieee = IEEE_DATA (entry);
+
if (entry_ieee->w.r.debug_information_part)
{
if (bfd_seek (entry, entry_ieee->w.r.debug_information_part,
SEEK_SET) != 0)
- return false;
+ return FALSE;
relocate_debug (abfd, entry);
}
chain = chain->next;
}
+
if (some_debug)
- {
- ieee->w.r.debug_information_part = here;
- }
+ ieee->w.r.debug_information_part = here;
else
- {
- ieee->w.r.debug_information_part = 0;
- }
+ ieee->w.r.debug_information_part = 0;
flush ();
}
- return true;
+ return TRUE;
}
/* Write the data in an ieee way. */
-static boolean
+static bfd_boolean
ieee_write_data_part (abfd)
bfd *abfd;
{
asection *s;
+
ieee_data_type *ieee = IEEE_DATA (abfd);
ieee->w.r.data_part = bfd_tell (abfd);
+
for (s = abfd->sections; s != (asection *) NULL; s = s->next)
{
/* Skip sections that have no loadable contents (.bss,
@@ -3364,24 +3397,25 @@ ieee_write_data_part (abfd)
if (s->reloc_count != 0)
{
if (! do_with_relocs (abfd, s))
- return false;
+ return FALSE;
}
else
{
if (! do_without_relocs (abfd, s))
- return false;
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
init_for_output (abfd)
bfd *abfd;
{
asection *s;
+
for (s = abfd->sections; s != (asection *) NULL; s = s->next)
{
if ((s->flags & SEC_DEBUGGING) != 0)
@@ -3391,22 +3425,22 @@ init_for_output (abfd)
bfd_size_type size = s->_raw_size;
ieee_per_section (s)->data = (bfd_byte *) (bfd_alloc (abfd, size));
if (!ieee_per_section (s)->data)
- return false;
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
-/** exec and core file sections */
+/* Exec and core file sections. */
-/* set section contents is complicated with IEEE since the format is
-* not a byte image, but a record stream.
-*/
-static boolean
+/* Set section contents is complicated with IEEE since the format is
+ not a byte image, but a record stream. */
+
+static bfd_boolean
ieee_set_section_contents (abfd, section, location, offset, count)
bfd *abfd;
sec_ptr section;
- PTR location;
+ const PTR location;
file_ptr offset;
bfd_size_type count;
{
@@ -3417,23 +3451,23 @@ ieee_set_section_contents (abfd, section, location, offset, count)
bfd_size_type size = section->_raw_size;
section->contents = (unsigned char *) bfd_alloc (abfd, size);
if (section->contents == NULL)
- return false;
+ return FALSE;
}
/* bfd_set_section_contents has already checked that everything
is within range. */
memcpy (section->contents + offset, location, (size_t) count);
- return true;
+ return TRUE;
}
if (ieee_per_section (section)->data == (bfd_byte *) NULL)
{
if (!init_for_output (abfd))
- return false;
+ return FALSE;
}
memcpy ((PTR) (ieee_per_section (section)->data + offset),
(PTR) location,
(unsigned int) count);
- return true;
+ return TRUE;
}
/* Write the external symbols of a file. IEEE considers two sorts of
@@ -3441,37 +3475,38 @@ ieee_set_section_contents (abfd, section, location, offset, count)
forms to index them as well. When we write them out we turn their
symbol values into indexes from the right base. */
-static boolean
+static bfd_boolean
ieee_write_external_part (abfd)
bfd *abfd;
{
asymbol **q;
ieee_data_type *ieee = IEEE_DATA (abfd);
-
unsigned int reference_index = IEEE_REFERENCE_BASE;
unsigned int public_index = IEEE_PUBLIC_BASE + 2;
file_ptr here = bfd_tell (abfd);
- boolean hadone = false;
+ bfd_boolean hadone = FALSE;
+
if (abfd->outsymbols != (asymbol **) NULL)
{
for (q = abfd->outsymbols; *q != (asymbol *) NULL; q++)
{
asymbol *p = *q;
+
if (bfd_is_und_section (p->section))
{
- /* This must be a symbol reference .. */
+ /* This must be a symbol reference. */
if (! ieee_write_byte (abfd, ieee_external_reference_enum)
|| ! ieee_write_int (abfd, (bfd_vma) reference_index)
|| ! ieee_write_id (abfd, p->name))
- return false;
+ return FALSE;
p->value = reference_index;
reference_index++;
- hadone = true;
+ hadone = TRUE;
}
else if (bfd_is_com_section (p->section))
{
- /* This is a weak reference */
+ /* This is a weak reference. */
if (! ieee_write_byte (abfd, ieee_external_reference_enum)
|| ! ieee_write_int (abfd, (bfd_vma) reference_index)
|| ! ieee_write_id (abfd, p->name)
@@ -3479,15 +3514,14 @@ ieee_write_external_part (abfd)
ieee_weak_external_reference_enum)
|| ! ieee_write_int (abfd, (bfd_vma) reference_index)
|| ! ieee_write_int (abfd, p->value))
- return false;
+ return FALSE;
p->value = reference_index;
reference_index++;
- hadone = true;
+ hadone = TRUE;
}
else if (p->flags & BSF_GLOBAL)
{
- /* This must be a symbol definition */
-
+ /* This must be a symbol definition. */
if (! ieee_write_byte (abfd, ieee_external_symbol_enum)
|| ! ieee_write_int (abfd, (bfd_vma) public_index)
|| ! ieee_write_id (abfd, p->name)
@@ -3496,24 +3530,24 @@ ieee_write_external_part (abfd)
|| ! ieee_write_byte (abfd, 15) /* instruction address */
|| ! ieee_write_byte (abfd, 19) /* static symbol */
|| ! ieee_write_byte (abfd, 1)) /* one of them */
- return false;
+ return FALSE;
- /* Write out the value */
+ /* Write out the value. */
if (! ieee_write_2bytes (abfd, ieee_value_record_enum)
|| ! ieee_write_int (abfd, (bfd_vma) public_index))
- return false;
+ return FALSE;
if (! bfd_is_abs_section (p->section))
{
if (abfd->flags & EXEC_P)
{
/* If fully linked, then output all symbols
- relocated */
+ relocated. */
if (! (ieee_write_int
(abfd,
(p->value
+ p->section->output_offset
+ p->section->output_section->vma))))
- return false;
+ return FALSE;
}
else
{
@@ -3521,8 +3555,8 @@ ieee_write_external_part (abfd)
(abfd,
p->value + p->section->output_offset,
p->section->output_section->symbol,
- false, 0)))
- return false;
+ FALSE, 0)))
+ return FALSE;
}
}
else
@@ -3530,33 +3564,33 @@ ieee_write_external_part (abfd)
if (! ieee_write_expression (abfd,
p->value,
bfd_abs_section_ptr->symbol,
- false, 0))
- return false;
+ FALSE, 0))
+ return FALSE;
}
p->value = public_index;
public_index++;
- hadone = true;
+ hadone = TRUE;
}
else
{
- /* This can happen - when there are gaps in the symbols read */
- /* from an input ieee file */
+ /* This can happen - when there are gaps in the symbols read
+ from an input ieee file. */
}
}
}
if (hadone)
ieee->w.r.external_part = here;
- return true;
+ return TRUE;
}
static const unsigned char exten[] =
{
0xf0, 0x20, 0x00,
- 0xf1, 0xce, 0x20, 0x00, 37, 3, 3, /* Set version 3 rev 3 */
- 0xf1, 0xce, 0x20, 0x00, 39, 2,/* keep symbol in original case */
- 0xf1, 0xce, 0x20, 0x00, 38 /* set object type relocateable to x */
+ 0xf1, 0xce, 0x20, 0x00, 37, 3, 3, /* Set version 3 rev 3. */
+ 0xf1, 0xce, 0x20, 0x00, 39, 2, /* Keep symbol in original case. */
+ 0xf1, 0xce, 0x20, 0x00, 38 /* Set object type relocatable to x. */
};
static const unsigned char envi[] =
@@ -3572,7 +3606,7 @@ static const unsigned char envi[] =
/* 0xf1, 0xce, 0x21, 0, 54, 2,1,1 tool & version # */
};
-static boolean
+static bfd_boolean
ieee_write_me_part (abfd)
bfd *abfd;
{
@@ -3584,17 +3618,17 @@ ieee_write_me_part (abfd)
|| ! ieee_write_byte (abfd, ieee_function_either_open_b_enum)
|| ! ieee_write_int (abfd, abfd->start_address)
|| ! ieee_write_byte (abfd, ieee_function_either_close_b_enum))
- return false;
+ return FALSE;
}
ieee->w.r.me_record = bfd_tell (abfd);
if (! ieee_write_byte (abfd, ieee_module_end_enum))
- return false;
- return true;
+ return FALSE;
+ return TRUE;
}
/* Write out the IEEE processor ID. */
-static boolean
+static bfd_boolean
ieee_write_processor (abfd)
bfd *abfd;
{
@@ -3605,22 +3639,22 @@ ieee_write_processor (abfd)
{
default:
if (! ieee_write_id (abfd, bfd_printable_name (abfd)))
- return false;
+ return FALSE;
break;
case bfd_arch_a29k:
if (! ieee_write_id (abfd, "29000"))
- return false;
+ return FALSE;
break;
case bfd_arch_h8300:
if (! ieee_write_id (abfd, "H8/300"))
- return false;
+ return FALSE;
break;
case bfd_arch_h8500:
if (! ieee_write_id (abfd, "H8/500"))
- return false;
+ return FALSE;
break;
case bfd_arch_i960:
@@ -3630,23 +3664,23 @@ ieee_write_processor (abfd)
case bfd_mach_i960_core:
case bfd_mach_i960_ka_sa:
if (! ieee_write_id (abfd, "80960KA"))
- return false;
+ return FALSE;
break;
case bfd_mach_i960_kb_sb:
if (! ieee_write_id (abfd, "80960KB"))
- return false;
+ return FALSE;
break;
case bfd_mach_i960_ca:
if (! ieee_write_id (abfd, "80960CA"))
- return false;
+ return FALSE;
break;
case bfd_mach_i960_mc:
case bfd_mach_i960_xa:
if (! ieee_write_id (abfd, "80960MC"))
- return false;
+ return FALSE;
break;
}
break;
@@ -3670,18 +3704,19 @@ ieee_write_processor (abfd)
case bfd_mach_mcf5206e:id = "5206e"; break;
case bfd_mach_mcf5307:id = "5307"; break;
case bfd_mach_mcf5407:id = "5407"; break;
+ case bfd_mach_mcf528x:id = "5282"; break;
}
if (! ieee_write_id (abfd, id))
- return false;
+ return FALSE;
}
break;
}
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
ieee_write_object_contents (abfd)
bfd *abfd;
{
@@ -3689,51 +3724,51 @@ ieee_write_object_contents (abfd)
unsigned int i;
file_ptr old;
- /* Fast forward over the header area */
+ /* Fast forward over the header area. */
if (bfd_seek (abfd, (file_ptr) 0, SEEK_SET) != 0)
- return false;
+ return FALSE;
if (! ieee_write_byte (abfd, ieee_module_beginning_enum)
|| ! ieee_write_processor (abfd)
|| ! ieee_write_id (abfd, abfd->filename))
- return false;
+ return FALSE;
- /* Fast forward over the variable bits */
+ /* Fast forward over the variable bits. */
if (! ieee_write_byte (abfd, ieee_address_descriptor_enum))
- return false;
+ return FALSE;
- /* Bits per MAU */
+ /* Bits per MAU. */
if (! ieee_write_byte (abfd, (bfd_byte) (bfd_arch_bits_per_byte (abfd))))
- return false;
- /* MAU's per address */
+ return FALSE;
+ /* MAU's per address. */
if (! ieee_write_byte (abfd,
(bfd_byte) (bfd_arch_bits_per_address (abfd)
/ bfd_arch_bits_per_byte (abfd))))
- return false;
+ return FALSE;
old = bfd_tell (abfd);
if (bfd_seek (abfd, (file_ptr) (8 * N_W_VARIABLES), SEEK_CUR) != 0)
- return false;
+ return FALSE;
ieee->w.r.extension_record = bfd_tell (abfd);
if (bfd_bwrite ((char *) exten, (bfd_size_type) sizeof (exten), abfd)
!= sizeof (exten))
- return false;
+ return FALSE;
if (abfd->flags & EXEC_P)
{
if (! ieee_write_byte (abfd, 0x1)) /* Absolute */
- return false;
+ return FALSE;
}
else
{
if (! ieee_write_byte (abfd, 0x2)) /* Relocateable */
- return false;
+ return FALSE;
}
ieee->w.r.environmental_record = bfd_tell (abfd);
if (bfd_bwrite ((char *) envi, (bfd_size_type) sizeof (envi), abfd)
!= sizeof (envi))
- return false;
+ return FALSE;
/* The HP emulator database requires a timestamp in the file. */
{
@@ -3752,7 +3787,7 @@ ieee_write_object_contents (abfd)
|| ! ieee_write_int (abfd, (bfd_vma) t->tm_hour)
|| ! ieee_write_int (abfd, (bfd_vma) t->tm_min)
|| ! ieee_write_int (abfd, (bfd_vma) t->tm_sec))
- return false;
+ return FALSE;
}
output_bfd = abfd;
@@ -3760,51 +3795,46 @@ ieee_write_object_contents (abfd)
flush ();
if (! ieee_write_section_part (abfd))
- return false;
+ return FALSE;
/* First write the symbols. This changes their values into table
indeces so we cant use it after this point. */
if (! ieee_write_external_part (abfd))
- return false;
-
- /* ieee_write_byte(abfd, ieee_record_seperator_enum);*/
-
- /* ieee_write_byte(abfd, ieee_record_seperator_enum);*/
-
+ return FALSE;
/* Write any debugs we have been told about. */
if (! ieee_write_debug_part (abfd))
- return false;
+ return FALSE;
/* Can only write the data once the symbols have been written, since
the data contains relocation information which points to the
symbols. */
if (! ieee_write_data_part (abfd))
- return false;
+ return FALSE;
/* At the end we put the end! */
if (! ieee_write_me_part (abfd))
- return false;
+ return FALSE;
- /* Generate the header */
+ /* Generate the header. */
if (bfd_seek (abfd, old, SEEK_SET) != 0)
- return false;
+ return FALSE;
for (i = 0; i < N_W_VARIABLES; i++)
{
if (! ieee_write_2bytes (abfd, ieee_assign_value_to_variable_enum)
|| ! ieee_write_byte (abfd, (bfd_byte) i)
|| ! ieee_write_int5_out (abfd, (bfd_vma) ieee->w.offset[i]))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Native-level interface to symbols. */
/* We read the symbols into a buffer, which is discarded when this
function exits. We read the strings into a buffer large enough to
- hold them all plus all the cached symbol entries. */
+ hold them all plus all the cached symbol entries. */
static asymbol *
ieee_make_empty_symbol (abfd)
@@ -3812,6 +3842,7 @@ ieee_make_empty_symbol (abfd)
{
bfd_size_type amt = sizeof (ieee_symbol_type);
ieee_symbol_type *new = (ieee_symbol_type *) bfd_zalloc (abfd, amt);
+
if (!new)
return NULL;
new->symbol.the_bfd = abfd;
@@ -3824,15 +3855,16 @@ ieee_openr_next_archived_file (arch, prev)
bfd *prev;
{
ieee_ar_data_type *ar = IEEE_AR_DATA (arch);
- /* take the next one from the arch state, or reset */
+
+ /* Take the next one from the arch state, or reset. */
if (prev == (bfd *) NULL)
- {
- /* Reset the index - the first two entries are bogus*/
- ar->element_index = 2;
- }
- while (true)
+ /* Reset the index - the first two entries are bogus. */
+ ar->element_index = 2;
+
+ while (TRUE)
{
ieee_ar_obstack_type *p = ar->elements + ar->element_index;
+
ar->element_index++;
if (ar->element_index <= ar->element_count)
{
@@ -3851,11 +3883,10 @@ ieee_openr_next_archived_file (arch, prev)
bfd_set_error (bfd_error_no_more_archived_files);
return (bfd *) NULL;
}
-
}
}
-static boolean
+static bfd_boolean
ieee_find_nearest_line (abfd, section, symbols, offset, filename_ptr,
functionname_ptr, line_ptr)
bfd *abfd ATTRIBUTE_UNUSED;
@@ -3866,7 +3897,7 @@ ieee_find_nearest_line (abfd, section, symbols, offset, filename_ptr,
const char **functionname_ptr ATTRIBUTE_UNUSED;
unsigned int *line_ptr ATTRIBUTE_UNUSED;
{
- return false;
+ return FALSE;
}
static int
@@ -3904,7 +3935,7 @@ ieee_generic_stat_arch_elt (abfd, buf)
static int
ieee_sizeof_headers (abfd, x)
bfd *abfd ATTRIBUTE_UNUSED;
- boolean x ATTRIBUTE_UNUSED;
+ bfd_boolean x ATTRIBUTE_UNUSED;
{
return 0;
}
@@ -3929,8 +3960,7 @@ ieee_bfd_debug_info_end (abfd)
/* Add this section to the list of sections we have debug info for, to
- be ready to output it at close time
- */
+ be ready to output it at close time. */
static void
ieee_bfd_debug_info_accumulate (abfd, section)
bfd *abfd;
@@ -3938,37 +3968,34 @@ ieee_bfd_debug_info_accumulate (abfd, section)
{
ieee_data_type *ieee = IEEE_DATA (section->owner);
ieee_data_type *output_ieee = IEEE_DATA (abfd);
- /* can only accumulate data from other ieee bfds */
+
+ /* Can only accumulate data from other ieee bfds. */
if (section->owner->xvec != abfd->xvec)
return;
- /* Only bother once per bfd */
+ /* Only bother once per bfd. */
if (ieee->done_debug)
return;
- ieee->done_debug = true;
+ ieee->done_debug = TRUE;
- /* Don't bother if there is no debug info */
+ /* Don't bother if there is no debug info. */
if (ieee->w.r.debug_information_part == 0)
return;
-
- /* Add to chain */
+ /* Add to chain. */
{
bfd_size_type amt = sizeof (bfd_chain_type);
bfd_chain_type *n = (bfd_chain_type *) bfd_alloc (abfd, amt);
+
if (!n)
abort (); /* FIXME */
n->this = section->owner;
n->next = (bfd_chain_type *) NULL;
if (output_ieee->chain_head)
- {
- output_ieee->chain_head->next = n;
- }
+ output_ieee->chain_head->next = n;
else
- {
- output_ieee->chain_root = n;
+ output_ieee->chain_root = n;
- }
output_ieee->chain_head = n;
}
}
@@ -3981,11 +4008,12 @@ ieee_bfd_debug_info_accumulate (abfd, section)
#define ieee_slurp_armap bfd_true
#define ieee_slurp_extended_name_table bfd_true
#define ieee_construct_extended_name_table \
- ((boolean (*) PARAMS ((bfd *, char **, bfd_size_type *, const char **))) \
+ ((bfd_boolean (*) \
+ PARAMS ((bfd *, char **, bfd_size_type *, const char **))) \
bfd_true)
#define ieee_truncate_arname bfd_dont_truncate_arname
#define ieee_write_armap \
- ((boolean (*) \
+ ((bfd_boolean (*) \
PARAMS ((bfd *, unsigned int, struct orl *, unsigned int, int))) \
bfd_true)
#define ieee_read_ar_hdr bfd_nullvoidptr
@@ -4017,7 +4045,6 @@ ieee_bfd_debug_info_accumulate (abfd, section)
#define ieee_bfd_final_link _bfd_generic_final_link
#define ieee_bfd_link_split_section _bfd_generic_link_split_section
-/*SUPPRESS 460 */
const bfd_target ieee_vec =
{
"ieee", /* name */
@@ -4071,10 +4098,11 @@ const bfd_target ieee_vec =
ieee_update_armap_timestamp */
BFD_JUMP_TABLE_ARCHIVE (ieee),
- /* ieee_get_symtab_upper_bound, ieee_get_symtab, ieee_make_empty_symbol,
- ieee_print_symbol, ieee_get_symbol_info, ieee_bfd_is_local_label_name,
- ieee_get_lineno, ieee_find_nearest_line, ieee_bfd_make_debug_symbol,
- ieee_read_minisymbols, ieee_minisymbol_to_symbol */
+ /* ieee_get_symtab_upper_bound, ieee_canonicalize_symtab,
+ ieee_make_empty_symbol, ieee_print_symbol, ieee_get_symbol_info,
+ ieee_bfd_is_local_label_name, ieee_get_lineno,
+ ieee_find_nearest_line, ieee_bfd_make_debug_symbol,
+ ieee_read_minisymbols, ieee_minisymbol_to_symbol */
BFD_JUMP_TABLE_SYMBOLS (ieee),
/* ieee_get_reloc_upper_bound, ieee_canonicalize_reloc,
diff --git a/contrib/binutils/bfd/ihex.c b/contrib/binutils/bfd/ihex.c
index 8188c01..5d2d47f 100644
--- a/contrib/binutils/bfd/ihex.c
+++ b/contrib/binutils/bfd/ihex.c
@@ -1,5 +1,5 @@
/* BFD back-end for Intel Hex objects.
- Copyright 1995, 1996, 1998, 1999, 2000, 2001, 2002
+ Copyright 1995, 1996, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Ian Lance Taylor of Cygnus Support <ian@cygnus.com>.
@@ -125,23 +125,32 @@ The MRI compiler uses this, which is a repeat of type 5:
#include "libiberty.h"
#include "safe-ctype.h"
-static void ihex_init PARAMS ((void));
-static boolean ihex_mkobject PARAMS ((bfd *));
-static INLINE int ihex_get_byte PARAMS ((bfd *, boolean *));
-static void ihex_bad_byte PARAMS ((bfd *, unsigned int, int, boolean));
-static boolean ihex_scan PARAMS ((bfd *));
-static const bfd_target *ihex_object_p PARAMS ((bfd *));
-static boolean ihex_read_section PARAMS ((bfd *, asection *, bfd_byte *));
-static boolean ihex_get_section_contents
+static void ihex_init
+ PARAMS ((void));
+static bfd_boolean ihex_mkobject
+ PARAMS ((bfd *));
+static INLINE int ihex_get_byte
+ PARAMS ((bfd *, bfd_boolean *));
+static void ihex_bad_byte
+ PARAMS ((bfd *, unsigned int, int, bfd_boolean));
+static bfd_boolean ihex_scan
+ PARAMS ((bfd *));
+static const bfd_target *ihex_object_p
+ PARAMS ((bfd *));
+static bfd_boolean ihex_read_section
+ PARAMS ((bfd *, asection *, bfd_byte *));
+static bfd_boolean ihex_get_section_contents
PARAMS ((bfd *, asection *, PTR, file_ptr, bfd_size_type));
-static boolean ihex_set_section_contents
- PARAMS ((bfd *, asection *, PTR, file_ptr, bfd_size_type));
-static boolean ihex_write_record
+static bfd_boolean ihex_set_section_contents
+ PARAMS ((bfd *, asection *, const PTR, file_ptr, bfd_size_type));
+static bfd_boolean ihex_write_record
PARAMS ((bfd *, size_t, unsigned int, unsigned int, bfd_byte *));
-static boolean ihex_write_object_contents PARAMS ((bfd *));
-static boolean ihex_set_arch_mach
+static bfd_boolean ihex_write_object_contents
+ PARAMS ((bfd *));
+static bfd_boolean ihex_set_arch_mach
PARAMS ((bfd *, enum bfd_architecture, unsigned long));
-static int ihex_sizeof_headers PARAMS ((bfd *, boolean));
+static int ihex_sizeof_headers
+ PARAMS ((bfd *, bfd_boolean));
/* The number of bytes we put on one line during output. */
@@ -178,18 +187,18 @@ struct ihex_data_struct
static void
ihex_init ()
{
- static boolean inited;
+ static bfd_boolean inited;
if (! inited)
{
- inited = true;
+ inited = TRUE;
hex_init ();
}
}
/* Create an ihex object. */
-static boolean
+static bfd_boolean
ihex_mkobject (abfd)
bfd *abfd;
{
@@ -198,12 +207,12 @@ ihex_mkobject (abfd)
tdata = (struct ihex_data_struct *) bfd_alloc (abfd, amt);
if (tdata == NULL)
- return false;
+ return FALSE;
abfd->tdata.ihex_data = tdata;
tdata->head = NULL;
tdata->tail = NULL;
- return true;
+ return TRUE;
}
/* Read a byte from a BFD. Set *ERRORPTR if an error occurred.
@@ -212,14 +221,14 @@ ihex_mkobject (abfd)
static INLINE int
ihex_get_byte (abfd, errorptr)
bfd *abfd;
- boolean *errorptr;
+ bfd_boolean *errorptr;
{
bfd_byte c;
if (bfd_bread (&c, (bfd_size_type) 1, abfd) != 1)
{
if (bfd_get_error () != bfd_error_file_truncated)
- *errorptr = true;
+ *errorptr = TRUE;
return EOF;
}
@@ -233,7 +242,7 @@ ihex_bad_byte (abfd, lineno, c, error)
bfd *abfd;
unsigned int lineno;
int c;
- boolean error;
+ bfd_boolean error;
{
if (c == EOF)
{
@@ -261,7 +270,7 @@ ihex_bad_byte (abfd, lineno, c, error)
/* Read an Intel hex file and turn it into sections. We create a new
section for each contiguous set of bytes. */
-static boolean
+static bfd_boolean
ihex_scan (abfd)
bfd *abfd;
{
@@ -269,7 +278,7 @@ ihex_scan (abfd)
bfd_vma extbase;
asection *sec;
unsigned int lineno;
- boolean error;
+ bfd_boolean error;
bfd_byte *buf = NULL;
size_t bufsize;
int c;
@@ -283,7 +292,7 @@ ihex_scan (abfd)
extbase = 0;
sec = NULL;
lineno = 1;
- error = false;
+ error = FALSE;
bufsize = 0;
while ((c = ihex_get_byte (abfd, &error)) != EOF)
@@ -407,7 +416,7 @@ ihex_scan (abfd)
abfd->start_address = addr;
if (buf != NULL)
free (buf);
- return true;
+ return TRUE;
case 2:
/* An extended address record. */
@@ -496,12 +505,12 @@ ihex_scan (abfd)
if (buf != NULL)
free (buf);
- return true;
+ return TRUE;
error_return:
if (buf != NULL)
free (buf);
- return false;
+ return FALSE;
}
/* Try to recognize an Intel Hex file. */
@@ -563,7 +572,7 @@ ihex_object_p (abfd)
/* Read the contents of a section in an Intel Hex file. */
-static boolean
+static bfd_boolean
ihex_read_section (abfd, section, contents)
bfd *abfd;
asection *section;
@@ -573,14 +582,14 @@ ihex_read_section (abfd, section, contents)
bfd_byte *p;
bfd_byte *buf = NULL;
size_t bufsize;
- boolean error;
+ bfd_boolean error;
if (bfd_seek (abfd, section->filepos, SEEK_SET) != 0)
goto error_return;
p = contents;
bufsize = 0;
- error = false;
+ error = FALSE;
while ((c = ihex_get_byte (abfd, &error)) != EOF)
{
char hdr[8];
@@ -631,7 +640,7 @@ ihex_read_section (abfd, section, contents)
/* We've read everything in the section. */
if (buf != NULL)
free (buf);
- return true;
+ return TRUE;
}
/* Skip the checksum. */
@@ -651,17 +660,17 @@ ihex_read_section (abfd, section, contents)
if (buf != NULL)
free (buf);
- return true;
+ return TRUE;
error_return:
if (buf != NULL)
free (buf);
- return false;
+ return FALSE;
}
/* Get the contents of a section in an Intel Hex file. */
-static boolean
+static bfd_boolean
ihex_get_section_contents (abfd, section, location, offset, count)
bfd *abfd;
asection *section;
@@ -673,24 +682,24 @@ ihex_get_section_contents (abfd, section, location, offset, count)
{
section->used_by_bfd = bfd_alloc (abfd, section->_raw_size);
if (section->used_by_bfd == NULL)
- return false;
+ return FALSE;
if (! ihex_read_section (abfd, section, section->used_by_bfd))
- return false;
+ return FALSE;
}
memcpy (location, (bfd_byte *) section->used_by_bfd + offset,
(size_t) count);
- return true;
+ return TRUE;
}
/* Set the contents of a section in an Intel Hex file. */
-static boolean
+static bfd_boolean
ihex_set_section_contents (abfd, section, location, offset, count)
bfd *abfd;
asection *section;
- PTR location;
+ const PTR location;
file_ptr offset;
bfd_size_type count;
{
@@ -702,16 +711,16 @@ ihex_set_section_contents (abfd, section, location, offset, count)
if (count == 0
|| (section->flags & SEC_ALLOC) == 0
|| (section->flags & SEC_LOAD) == 0)
- return true;
+ return TRUE;
amt = sizeof (struct ihex_data_list);
n = (struct ihex_data_list *) bfd_alloc (abfd, amt);
if (n == NULL)
- return false;
+ return FALSE;
data = (bfd_byte *) bfd_alloc (abfd, count);
if (data == NULL)
- return false;
+ return FALSE;
memcpy (data, location, (size_t) count);
n->data = data;
@@ -742,12 +751,12 @@ ihex_set_section_contents (abfd, section, location, offset, count)
tdata->tail = n;
}
- return true;
+ return TRUE;
}
/* Write a record out to an Intel Hex file. */
-static boolean
+static bfd_boolean
ihex_write_record (abfd, count, addr, type, data)
bfd *abfd;
size_t count;
@@ -785,14 +794,14 @@ ihex_write_record (abfd, count, addr, type, data)
total = 9 + count * 2 + 4;
if (bfd_bwrite (buf, (bfd_size_type) total, abfd) != total)
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
/* Write out an Intel Hex file. */
-static boolean
+static bfd_boolean
ihex_write_object_contents (abfd)
bfd *abfd;
{
@@ -834,7 +843,7 @@ ihex_write_object_contents (abfd)
addr[0] = (bfd_byte)(segbase >> 12) & 0xff;
addr[1] = (bfd_byte)(segbase >> 4) & 0xff;
if (! ihex_write_record (abfd, 2, 0, 2, addr))
- return false;
+ return FALSE;
}
else
{
@@ -849,7 +858,7 @@ ihex_write_object_contents (abfd)
addr[0] = 0;
addr[1] = 0;
if (! ihex_write_record (abfd, 2, 0, 2, addr))
- return false;
+ return FALSE;
segbase = 0;
}
@@ -863,12 +872,12 @@ ihex_write_object_contents (abfd)
(_("%s: address 0x%s out of range for Intel Hex file"),
bfd_get_filename (abfd), buf);
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
addr[0] = (bfd_byte)(extbase >> 24) & 0xff;
addr[1] = (bfd_byte)(extbase >> 16) & 0xff;
if (! ihex_write_record (abfd, 2, 0, 4, addr))
- return false;
+ return FALSE;
}
}
@@ -879,7 +888,7 @@ ihex_write_object_contents (abfd)
now = 0x10000 - rec_addr;
if (! ihex_write_record (abfd, now, rec_addr, 0, p))
- return false;
+ return FALSE;
where += now;
p += now;
@@ -901,7 +910,7 @@ ihex_write_object_contents (abfd)
startbuf[2] = (bfd_byte)(start >> 8) & 0xff;
startbuf[3] = (bfd_byte)start & 0xff;
if (! ihex_write_record (abfd, 4, 0, 3, startbuf))
- return false;
+ return FALSE;
}
else
{
@@ -910,20 +919,20 @@ ihex_write_object_contents (abfd)
startbuf[2] = (bfd_byte)(start >> 8) & 0xff;
startbuf[3] = (bfd_byte)start & 0xff;
if (! ihex_write_record (abfd, 4, 0, 5, startbuf))
- return false;
+ return FALSE;
}
}
if (! ihex_write_record (abfd, 0, 0, 1, NULL))
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
/* Set the architecture for the output file. The architecture is
irrelevant, so we ignore errors about unknown architectures. */
-static boolean
+static bfd_boolean
ihex_set_arch_mach (abfd, arch, mach)
bfd *abfd;
enum bfd_architecture arch;
@@ -932,18 +941,17 @@ ihex_set_arch_mach (abfd, arch, mach)
if (! bfd_default_set_arch_mach (abfd, arch, mach))
{
if (arch != bfd_arch_unknown)
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Get the size of the headers, for the linker. */
-/*ARGSUSED*/
static int
ihex_sizeof_headers (abfd, exec)
bfd *abfd ATTRIBUTE_UNUSED;
- boolean exec ATTRIBUTE_UNUSED;
+ bfd_boolean exec ATTRIBUTE_UNUSED;
{
return 0;
}
@@ -957,7 +965,7 @@ ihex_sizeof_headers (abfd, exec)
_bfd_generic_get_section_contents_in_window
#define ihex_get_symtab_upper_bound bfd_0l
-#define ihex_get_symtab \
+#define ihex_canonicalize_symtab \
((long (*) PARAMS ((bfd *, asymbol **))) bfd_0l)
#define ihex_make_empty_symbol _bfd_generic_make_empty_symbol
#define ihex_print_symbol _bfd_nosymbols_print_symbol
diff --git a/contrib/binutils/bfd/init.c b/contrib/binutils/bfd/init.c
index 198b979..07401eb 100644
--- a/contrib/binutils/bfd/init.c
+++ b/contrib/binutils/bfd/init.c
@@ -1,5 +1,5 @@
/* bfd initialization stuff
- Copyright 1990, 1991, 1992, 1993, 1994, 1995
+ Copyright 1990, 1991, 1992, 1993, 1994, 1995, 2003
Free Software Foundation, Inc.
Written by Steve Chamberlain of Cygnus Support.
@@ -35,7 +35,7 @@ FUNCTION
bfd_init
SYNOPSIS
- void bfd_init(void);
+ void bfd_init (void);
DESCRIPTION
This routine must be called before any other BFD function to
@@ -46,6 +46,6 @@ DESCRIPTION
However, someday it may be needed, so keep it around. */
void
-bfd_init ()
+bfd_init (void)
{
}
diff --git a/contrib/binutils/bfd/libaout.h b/contrib/binutils/bfd/libaout.h
index a76b935..67054e3 100644
--- a/contrib/binutils/bfd/libaout.h
+++ b/contrib/binutils/bfd/libaout.h
@@ -1,24 +1,24 @@
/* BFD back-end data structures for a.out (and similar) files.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Support.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef LIBAOUT_H
#define LIBAOUT_H
@@ -29,51 +29,23 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "bfdlink.h"
-/* Macros for accessing components in an aout header. Saves cluttering
- the source with (bfd_vma) and (bfd_byte *) casts. */
-
-#define H_PUT_64(abfd, val, where) \
- bfd_h_put_64 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-
-#define H_PUT_32(abfd, val, where) \
- bfd_h_put_32 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-
-#define H_PUT_16(abfd, val, where) \
- bfd_h_put_16 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
+/* Macros for accessing components in an aout header. */
+#define H_PUT_64 bfd_h_put_64
+#define H_PUT_32 bfd_h_put_32
+#define H_PUT_16 bfd_h_put_16
#define H_PUT_8 bfd_h_put_8
-
-#define H_PUT_S64(abfd, val, where) \
- bfd_h_put_signed_64 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-
-#define H_PUT_S32(abfd, val, where) \
- bfd_h_put_signed_32 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-
-#define H_PUT_S16(abfd, val, where) \
- bfd_h_put_signed_16 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-
+#define H_PUT_S64 bfd_h_put_signed_64
+#define H_PUT_S32 bfd_h_put_signed_32
+#define H_PUT_S16 bfd_h_put_signed_16
#define H_PUT_S8 bfd_h_put_signed_8
-
-#define H_GET_64(abfd, where) \
- bfd_h_get_64 ((abfd), (bfd_byte *) (where))
-
-#define H_GET_32(abfd, where) \
- bfd_h_get_32 ((abfd), (bfd_byte *) (where))
-
-#define H_GET_16(abfd, where) \
- bfd_h_get_16 ((abfd), (bfd_byte *) (where))
-
+#define H_GET_64 bfd_h_get_64
+#define H_GET_32 bfd_h_get_32
+#define H_GET_16 bfd_h_get_16
#define H_GET_8 bfd_h_get_8
-
-#define H_GET_S64(abfd, where) \
- bfd_h_get_signed_64 ((abfd), (bfd_byte *) (where))
-
-#define H_GET_S32(abfd, where) \
- bfd_h_get_signed_32 ((abfd), (bfd_byte *) (where))
-
-#define H_GET_S16(abfd, where) \
- bfd_h_get_signed_16 ((abfd), (bfd_byte *) (where))
-
+#define H_GET_S64 bfd_h_get_signed_64
+#define H_GET_S32 bfd_h_get_signed_32
+#define H_GET_S16 bfd_h_get_signed_16
#define H_GET_S8 bfd_h_get_signed_8
/* Parameterize the a.out code based on whether it is being built
@@ -131,7 +103,7 @@ struct aout_link_hash_entry
{
struct bfd_link_hash_entry root;
/* Whether this symbol has been written out. */
- boolean written;
+ bfd_boolean written;
/* Symbol index in output file. */
int indx;
};
@@ -154,7 +126,7 @@ struct aout_link_hash_table
#define aout_link_hash_traverse(table, func, info) \
(bfd_link_hash_traverse \
(&(table)->root, \
- (boolean (*) PARAMS ((struct bfd_link_hash_entry *, PTR))) (func), \
+ (bfd_boolean (*) PARAMS ((struct bfd_link_hash_entry *, PTR))) (func), \
(info)))
/* Get the a.out link hash table from the info structure. This is
@@ -193,7 +165,7 @@ struct aout_backend_data
/* Callback for setting the page and segment sizes, if they can't be
trivially determined from the architecture. */
- boolean (*set_sizes)
+ bfd_boolean (*set_sizes)
PARAMS ((bfd *));
/* zmagic files only. For go32, the length of the exec header contributes
@@ -203,39 +175,39 @@ struct aout_backend_data
/* Callback from the add symbols phase of the linker code to handle
a dynamic object. */
- boolean (*add_dynamic_symbols)
+ bfd_boolean (*add_dynamic_symbols)
PARAMS ((bfd *, struct bfd_link_info *, struct external_nlist **,
bfd_size_type *, char **));
/* Callback from the add symbols phase of the linker code to handle
adding a single symbol to the global linker hash table. */
- boolean (*add_one_symbol)
+ bfd_boolean (*add_one_symbol)
PARAMS ((struct bfd_link_info *, bfd *, const char *, flagword,
- asection *, bfd_vma, const char *, boolean, boolean,
+ asection *, bfd_vma, const char *, bfd_boolean, bfd_boolean,
struct bfd_link_hash_entry **));
/* Called to handle linking a dynamic object. */
- boolean (*link_dynamic_object)
+ bfd_boolean (*link_dynamic_object)
PARAMS ((struct bfd_link_info *, bfd *));
/* Called for each global symbol being written out by the linker.
This should write out the dynamic symbol information. */
- boolean (*write_dynamic_symbol)
+ bfd_boolean (*write_dynamic_symbol)
PARAMS ((bfd *, struct bfd_link_info *, struct aout_link_hash_entry *));
/* If this callback is not NULL, the linker calls it for each reloc.
RELOC is a pointer to the unswapped reloc. If *SKIP is set to
- true, the reloc will be skipped. *RELOCATION may be changed to
+ TRUE, the reloc will be skipped. *RELOCATION may be changed to
change the effects of the relocation. */
- boolean (*check_dynamic_reloc)
+ bfd_boolean (*check_dynamic_reloc)
PARAMS ((struct bfd_link_info *info, bfd *input_bfd,
asection *input_section, struct aout_link_hash_entry *h,
- PTR reloc, bfd_byte *contents, boolean *skip,
+ PTR reloc, bfd_byte *contents, bfd_boolean *skip,
bfd_vma *relocation));
/* Called at the end of a link to finish up any dynamic linking
information. */
- boolean (*finish_dynamic_link)
+ bfd_boolean (*finish_dynamic_link)
PARAMS ((bfd *, struct bfd_link_info *));
};
#define aout_backend_info(abfd) \
@@ -282,10 +254,10 @@ enum machine_type {
M_68010 = 1,
M_68020 = 2,
M_SPARC = 3,
- /* skip a bunch so we don't run into any of suns numbers */
- /* make these up for the ns32k*/
- M_NS32032 = (64), /* ns32032 running ? */
- M_NS32532 = (64 + 5), /* ns32532 running mach */
+ /* Skip a bunch so we don't run into any of SUN's numbers. */
+ /* Make these up for the ns32k. */
+ M_NS32032 = (64), /* ns32032 running ? */
+ M_NS32532 = (64 + 5), /* ns32532 running mach */
M_386 = 100,
M_29K = 101, /* AMD 29000 */
@@ -377,7 +349,7 @@ struct aoutdata {
struct internal_exec *hdr; /* exec file header */
aout_symbol_type *symbols; /* symtab for input bfd */
- /* For ease, we do this */
+ /* For ease, we do this. */
asection *textsec;
asection *datasec;
asection *bsssec;
@@ -387,16 +359,16 @@ struct aoutdata {
file_ptr sym_filepos;
file_ptr str_filepos;
- /* Size of a relocation entry in external form */
+ /* Size of a relocation entry in external form. */
unsigned reloc_entry_size;
- /* Size of a symbol table entry in external form */
+ /* Size of a symbol table entry in external form. */
unsigned symbol_entry_size;
- /* Page size - needed for alignment of demand paged files. */
+ /* Page size - needed for alignment of demand paged files. */
unsigned long page_size;
- /* Segment size - needed for alignment of demand paged files. */
+ /* Segment size - needed for alignment of demand paged files. */
unsigned long segment_size;
/* Zmagic disk block size - need to align the start of the text
@@ -406,7 +378,7 @@ struct aoutdata {
unsigned exec_bytes_size;
unsigned vma_adjusted : 1;
- /* used when a bfd supports several highly similar formats */
+ /* Used when a bfd supports several highly similar formats. */
enum
{
default_format = 0,
@@ -471,7 +443,7 @@ struct aout_data_struct {
#define obj_aout_dynamic_info(bfd) (adata(bfd).dynamic_info)
/* We take the address of the first element of an asymbol to ensure that the
- macro is only ever applied to an asymbol */
+ macro is only ever applied to an asymbol. */
#define aout_symbol(asymbol) ((aout_symbol_type *)(&(asymbol)->the_bfd))
/* Information we keep for each a.out section. This is currently only
@@ -489,43 +461,43 @@ struct aout_section_data_struct
#define set_aout_section_data(s,v) \
((s)->used_by_bfd = (PTR)&(v)->relocs)
-/* Prototype declarations for functions defined in aoutx.h */
+/* Prototype declarations for functions defined in aoutx.h. */
-extern boolean NAME(aout,squirt_out_relocs)
+extern bfd_boolean NAME(aout,squirt_out_relocs)
PARAMS ((bfd *, asection *));
-extern boolean NAME(aout,make_sections)
+extern bfd_boolean NAME(aout,make_sections)
PARAMS ((bfd *));
extern const bfd_target * NAME(aout,some_aout_object_p)
PARAMS ((bfd *, struct internal_exec *, const bfd_target *(*) (bfd *)));
-extern boolean NAME(aout,mkobject)
+extern bfd_boolean NAME(aout,mkobject)
PARAMS ((bfd *));
extern enum machine_type NAME(aout,machine_type)
- PARAMS ((enum bfd_architecture, unsigned long, boolean *));
+ PARAMS ((enum bfd_architecture, unsigned long, bfd_boolean *));
-extern boolean NAME(aout,set_arch_mach)
+extern bfd_boolean NAME(aout,set_arch_mach)
PARAMS ((bfd *, enum bfd_architecture, unsigned long));
-extern boolean NAME(aout,new_section_hook)
+extern bfd_boolean NAME(aout,new_section_hook)
PARAMS ((bfd *, asection *));
-extern boolean NAME(aout,set_section_contents)
- PARAMS ((bfd *, sec_ptr, PTR, file_ptr, bfd_size_type));
+extern bfd_boolean NAME(aout,set_section_contents)
+ PARAMS ((bfd *, sec_ptr, const PTR, file_ptr, bfd_size_type));
extern asymbol * NAME(aout,make_empty_symbol)
PARAMS ((bfd *));
-extern boolean NAME(aout,translate_symbol_table)
+extern bfd_boolean NAME(aout,translate_symbol_table)
PARAMS ((bfd *, aout_symbol_type *, struct external_nlist *, bfd_size_type,
- char *, bfd_size_type, boolean));
+ char *, bfd_size_type, bfd_boolean));
-extern boolean NAME(aout,slurp_symbol_table)
+extern bfd_boolean NAME(aout,slurp_symbol_table)
PARAMS ((bfd *));
-extern boolean NAME(aout,write_syms)
+extern bfd_boolean NAME(aout,write_syms)
PARAMS ((bfd *));
extern void NAME(aout,reclaim_symbol_table)
@@ -534,7 +506,7 @@ extern void NAME(aout,reclaim_symbol_table)
extern long NAME(aout,get_symtab_upper_bound)
PARAMS ((bfd *));
-extern long NAME(aout,get_symtab)
+extern long NAME(aout,canonicalize_symtab)
PARAMS ((bfd *, asymbol **));
extern void NAME(aout,swap_ext_reloc_in)
@@ -547,7 +519,7 @@ extern void NAME(aout,swap_std_reloc_in)
extern reloc_howto_type * NAME(aout,reloc_type_lookup)
PARAMS ((bfd *, bfd_reloc_code_real_type));
-extern boolean NAME(aout,slurp_reloc_table)
+extern bfd_boolean NAME(aout,slurp_reloc_table)
PARAMS ((bfd *, sec_ptr, asymbol **));
extern long NAME(aout,canonicalize_reloc)
@@ -568,20 +540,20 @@ extern void NAME(aout,print_symbol)
extern void NAME(aout,get_symbol_info)
PARAMS ((bfd *, asymbol *, symbol_info *));
-extern boolean NAME(aout,find_nearest_line)
+extern bfd_boolean NAME(aout,find_nearest_line)
PARAMS ((bfd *, asection *, asymbol **, bfd_vma, const char **,
const char **, unsigned int *));
extern long NAME(aout,read_minisymbols)
- PARAMS ((bfd *, boolean, PTR *, unsigned int *));
+ PARAMS ((bfd *, bfd_boolean, PTR *, unsigned int *));
extern asymbol * NAME(aout,minisymbol_to_symbol)
- PARAMS ((bfd *, boolean, const PTR, asymbol *));
+ PARAMS ((bfd *, bfd_boolean, const PTR, asymbol *));
extern int NAME(aout,sizeof_headers)
- PARAMS ((bfd *, boolean));
+ PARAMS ((bfd *, bfd_boolean));
-extern boolean NAME(aout,adjust_sizes_and_vmas)
+extern bfd_boolean NAME(aout,adjust_sizes_and_vmas)
PARAMS ((bfd *, bfd_size_type *, file_ptr *));
extern void NAME(aout,swap_exec_header_in)
@@ -593,7 +565,7 @@ extern void NAME(aout,swap_exec_header_out)
extern struct bfd_hash_entry * NAME(aout,link_hash_newfunc)
PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-extern boolean NAME(aout,link_hash_table_init)
+extern bfd_boolean NAME(aout,link_hash_table_init)
PARAMS ((struct aout_link_hash_table *, bfd *,
struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
struct bfd_hash_table *,
@@ -602,17 +574,17 @@ extern boolean NAME(aout,link_hash_table_init)
extern struct bfd_link_hash_table * NAME(aout,link_hash_table_create)
PARAMS ((bfd *));
-extern boolean NAME(aout,link_add_symbols)
+extern bfd_boolean NAME(aout,link_add_symbols)
PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean NAME(aout,final_link)
+extern bfd_boolean NAME(aout,final_link)
PARAMS ((bfd *, struct bfd_link_info *,
void (*) (bfd *, file_ptr *, file_ptr *, file_ptr *)));
-extern boolean NAME(aout,bfd_free_cached_info)
+extern bfd_boolean NAME(aout,bfd_free_cached_info)
PARAMS ((bfd *));
-/* A.out uses the generic versions of these routines... */
+/* A.out uses the generic versions of these routines... */
#define aout_16_get_section_contents _bfd_generic_get_section_contents
@@ -647,29 +619,48 @@ extern boolean NAME(aout,bfd_free_cached_info)
if (bfd_seek (abfd, (file_ptr) 0, SEEK_SET) != 0 \
|| bfd_bwrite ((PTR) &exec_bytes, (bfd_size_type) EXEC_BYTES_SIZE, \
abfd) != EXEC_BYTES_SIZE) \
- return false; \
- /* Now write out reloc info, followed by syms and strings */ \
+ return FALSE; \
+ /* Now write out reloc info, followed by syms and strings. */ \
\
if (bfd_get_outsymbols (abfd) != (asymbol **) NULL \
&& bfd_get_symcount (abfd) != 0) \
{ \
if (bfd_seek (abfd, (file_ptr) (N_SYMOFF(*execp)), SEEK_SET) != 0)\
- return false; \
+ return FALSE; \
\
if (! NAME(aout,write_syms) (abfd)) \
- return false; \
+ return FALSE; \
} \
\
if (bfd_seek (abfd, (file_ptr) (N_TRELOFF(*execp)), SEEK_SET) != 0) \
- return false; \
+ return FALSE; \
if (!NAME(aout,squirt_out_relocs) (abfd, obj_textsec (abfd))) \
- return false; \
+ return FALSE; \
\
if (bfd_seek (abfd, (file_ptr) (N_DRELOFF(*execp)), SEEK_SET) != 0) \
- return false; \
+ return FALSE; \
if (!NAME(aout,squirt_out_relocs) (abfd, obj_datasec (abfd))) \
- return false; \
+ return FALSE; \
}
#endif
+/* Test if a read-only section can be merged with .text. This is
+ possible if:
+
+ 1. Section has file contents and is read-only.
+ 2. The VMA of the section is after the end of .text and before
+ the start of .data.
+ 3. The image is demand-pageable (otherwise, a_text in the header
+ will not reflect the gap between .text and .data). */
+
+#define aout_section_merge_with_text_p(abfd, sec) \
+ (((sec)->flags & (SEC_HAS_CONTENTS | SEC_READONLY)) == \
+ (SEC_HAS_CONTENTS | SEC_READONLY) \
+ && obj_textsec (abfd) != NULL \
+ && obj_datasec (abfd) != NULL \
+ && (sec)->vma >= (obj_textsec (abfd)->vma + \
+ obj_textsec (abfd)->_cooked_size) \
+ && ((sec)->vma + (sec)->_cooked_size) <= obj_datasec (abfd)->vma \
+ && ((abfd)->flags & D_PAGED) != 0)
+
#endif /* ! defined (LIBAOUT_H) */
diff --git a/contrib/binutils/bfd/libbfd-in.h b/contrib/binutils/bfd/libbfd-in.h
index 776dcd6..10cafef 100644
--- a/contrib/binutils/bfd/libbfd-in.h
+++ b/contrib/binutils/bfd/libbfd-in.h
@@ -1,8 +1,9 @@
/* libbfd.h -- Declarations used by bfd library *implementation*.
(This include file is not for users of the library.)
- Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
- Free Software Foundation, Inc.
+
+ Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
+ 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
+
Written by Cygnus Support.
This file is part of BFD, the Binary File Descriptor library.
@@ -36,7 +37,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* Set a tdata field. Can't use the other macros for this, since they
do casts, and casting to the left of assignment isn't portable. */
-#define set_tdata(bfd, v) ((bfd)->tdata.any = (PTR) (v))
+#define set_tdata(bfd, v) ((bfd)->tdata.any = (v))
/* If BFD_IN_MEMORY is set for a BFD, then the iostream fields points
to an instance of this structure. */
@@ -69,7 +70,7 @@ struct artdata {
archive. */
file_ptr armap_datepos; /* Position within archive to seek to
rewrite the date field. */
- PTR tdata; /* Backend specific information. */
+ void *tdata; /* Backend specific information. */
};
#define bfd_ardata(bfd) ((bfd)->tdata.aout_ar_data)
@@ -83,70 +84,105 @@ struct areltdata {
#define arelt_size(bfd) (((struct areltdata *)((bfd)->arelt_data))->parsed_size)
-extern PTR bfd_malloc PARAMS ((bfd_size_type));
-extern PTR bfd_realloc PARAMS ((PTR, bfd_size_type));
-extern PTR bfd_zmalloc PARAMS ((bfd_size_type));
+extern void *bfd_malloc
+ (bfd_size_type);
+extern void *bfd_realloc
+ (void *, bfd_size_type);
+extern void *bfd_zmalloc
+ (bfd_size_type);
extern bfd_error_handler_type _bfd_error_handler;
/* These routines allocate and free things on the BFD's objalloc. */
-extern PTR bfd_alloc PARAMS ((bfd *, bfd_size_type));
-extern PTR bfd_zalloc PARAMS ((bfd *, bfd_size_type));
-extern void bfd_release PARAMS ((bfd *, PTR));
-
-bfd * _bfd_create_empty_archive_element_shell PARAMS ((bfd *obfd));
-bfd * _bfd_look_for_bfd_in_cache PARAMS ((bfd *, file_ptr));
-boolean _bfd_add_bfd_to_archive_cache PARAMS ((bfd *, file_ptr, bfd *));
-boolean _bfd_generic_mkarchive PARAMS ((bfd *abfd));
-const bfd_target *bfd_generic_archive_p PARAMS ((bfd *abfd));
-boolean bfd_slurp_armap PARAMS ((bfd *abfd));
-boolean bfd_slurp_bsd_armap_f2 PARAMS ((bfd *abfd));
+extern void *bfd_alloc
+ (bfd *, bfd_size_type);
+extern void *bfd_zalloc
+ (bfd *, bfd_size_type);
+extern void bfd_release
+ (bfd *, void *);
+
+bfd * _bfd_create_empty_archive_element_shell
+ (bfd *obfd);
+bfd * _bfd_look_for_bfd_in_cache
+ (bfd *, file_ptr);
+bfd_boolean _bfd_add_bfd_to_archive_cache
+ (bfd *, file_ptr, bfd *);
+bfd_boolean _bfd_generic_mkarchive
+ (bfd *abfd);
+const bfd_target *bfd_generic_archive_p
+ (bfd *abfd);
+bfd_boolean bfd_slurp_armap
+ (bfd *abfd);
+bfd_boolean bfd_slurp_bsd_armap_f2
+ (bfd *abfd);
#define bfd_slurp_bsd_armap bfd_slurp_armap
#define bfd_slurp_coff_armap bfd_slurp_armap
-boolean _bfd_slurp_extended_name_table PARAMS ((bfd *abfd));
-extern boolean _bfd_construct_extended_name_table
- PARAMS ((bfd *, boolean, char **, bfd_size_type *));
-boolean _bfd_write_archive_contents PARAMS ((bfd *abfd));
-boolean _bfd_compute_and_write_armap PARAMS ((bfd *, unsigned int elength));
-bfd *_bfd_get_elt_at_filepos PARAMS ((bfd *archive, file_ptr filepos));
-extern bfd *_bfd_generic_get_elt_at_index PARAMS ((bfd *, symindex));
-bfd * _bfd_new_bfd PARAMS ((void));
-void _bfd_delete_bfd PARAMS ((bfd *));
-
-boolean bfd_false PARAMS ((bfd *ignore));
-boolean bfd_true PARAMS ((bfd *ignore));
-PTR bfd_nullvoidptr PARAMS ((bfd *ignore));
-int bfd_0 PARAMS ((bfd *ignore));
-unsigned int bfd_0u PARAMS ((bfd *ignore));
-long bfd_0l PARAMS ((bfd *ignore));
-long _bfd_n1 PARAMS ((bfd *ignore));
-void bfd_void PARAMS ((bfd *ignore));
-
-bfd *_bfd_new_bfd_contained_in PARAMS ((bfd *));
-const bfd_target *_bfd_dummy_target PARAMS ((bfd *abfd));
-
-void bfd_dont_truncate_arname PARAMS ((bfd *abfd, const char *filename,
- char *hdr));
-void bfd_bsd_truncate_arname PARAMS ((bfd *abfd, const char *filename,
- char *hdr));
-void bfd_gnu_truncate_arname PARAMS ((bfd *abfd, const char *filename,
- char *hdr));
-
-boolean bsd_write_armap PARAMS ((bfd *arch, unsigned int elength,
- struct orl *map, unsigned int orl_count, int stridx));
-
-boolean coff_write_armap PARAMS ((bfd *arch, unsigned int elength,
- struct orl *map, unsigned int orl_count, int stridx));
-
-extern PTR _bfd_generic_read_ar_hdr PARAMS ((bfd *));
-
-extern PTR _bfd_generic_read_ar_hdr_mag PARAMS ((bfd *, const char *));
-
-bfd * bfd_generic_openr_next_archived_file PARAMS ((bfd *archive,
- bfd *last_file));
-
-int bfd_generic_stat_arch_elt PARAMS ((bfd *, struct stat *));
+bfd_boolean _bfd_slurp_extended_name_table
+ (bfd *abfd);
+extern bfd_boolean _bfd_construct_extended_name_table
+ (bfd *, bfd_boolean, char **, bfd_size_type *);
+bfd_boolean _bfd_write_archive_contents
+ (bfd *abfd);
+bfd_boolean _bfd_compute_and_write_armap
+ (bfd *, unsigned int elength);
+bfd *_bfd_get_elt_at_filepos
+ (bfd *archive, file_ptr filepos);
+extern bfd *_bfd_generic_get_elt_at_index
+ (bfd *, symindex);
+bfd * _bfd_new_bfd
+ (void);
+void _bfd_delete_bfd
+ (bfd *);
+
+bfd_boolean bfd_false
+ (bfd *ignore);
+bfd_boolean bfd_true
+ (bfd *ignore);
+void *bfd_nullvoidptr
+ (bfd *ignore);
+int bfd_0
+ (bfd *ignore);
+unsigned int bfd_0u
+ (bfd *ignore);
+long bfd_0l
+ (bfd *ignore);
+long _bfd_n1
+ (bfd *ignore);
+void bfd_void
+ (bfd *ignore);
+
+bfd *_bfd_new_bfd_contained_in
+ (bfd *);
+const bfd_target *_bfd_dummy_target
+ (bfd *abfd);
+
+void bfd_dont_truncate_arname
+ (bfd *abfd, const char *filename, char *hdr);
+void bfd_bsd_truncate_arname
+ (bfd *abfd, const char *filename, char *hdr);
+void bfd_gnu_truncate_arname
+ (bfd *abfd, const char *filename, char *hdr);
+
+bfd_boolean bsd_write_armap
+ (bfd *arch, unsigned int elength, struct orl *map, unsigned int orl_count,
+ int stridx);
+
+bfd_boolean coff_write_armap
+ (bfd *arch, unsigned int elength, struct orl *map, unsigned int orl_count,
+ int stridx);
+
+extern void *_bfd_generic_read_ar_hdr
+ (bfd *);
+
+extern void *_bfd_generic_read_ar_hdr_mag
+ (bfd *, const char *);
+
+bfd * bfd_generic_openr_next_archived_file
+ (bfd *archive, bfd *last_file);
+
+int bfd_generic_stat_arch_elt
+ (bfd *, struct stat *);
#define _bfd_read_ar_hdr(abfd) \
BFD_SEND (abfd, _bfd_read_ar_hdr_fn, (abfd))
@@ -157,35 +193,37 @@ int bfd_generic_stat_arch_elt PARAMS ((bfd *, struct stat *));
#define _bfd_generic_close_and_cleanup bfd_true
#define _bfd_generic_bfd_free_cached_info bfd_true
#define _bfd_generic_new_section_hook \
- ((boolean (*) PARAMS ((bfd *, asection *))) bfd_true)
-extern boolean _bfd_generic_get_section_contents
- PARAMS ((bfd *, asection *, PTR, file_ptr, bfd_size_type));
-extern boolean _bfd_generic_get_section_contents_in_window
- PARAMS ((bfd *, asection *, bfd_window *, file_ptr, bfd_size_type));
+ ((bfd_boolean (*) (bfd *, asection *)) bfd_true)
+extern bfd_boolean _bfd_generic_get_section_contents
+ (bfd *, asection *, void *, file_ptr, bfd_size_type);
+extern bfd_boolean _bfd_generic_get_section_contents_in_window
+ (bfd *, asection *, bfd_window *, file_ptr, bfd_size_type);
/* Generic routines to use for BFD_JUMP_TABLE_COPY. Use
BFD_JUMP_TABLE_COPY (_bfd_generic). */
#define _bfd_generic_bfd_copy_private_bfd_data \
- ((boolean (*) PARAMS ((bfd *, bfd *))) bfd_true)
+ ((bfd_boolean (*) (bfd *, bfd *)) bfd_true)
#define _bfd_generic_bfd_merge_private_bfd_data \
- ((boolean (*) PARAMS ((bfd *, bfd *))) bfd_true)
+ ((bfd_boolean (*) (bfd *, bfd *)) bfd_true)
#define _bfd_generic_bfd_set_private_flags \
- ((boolean (*) PARAMS ((bfd *, flagword))) bfd_true)
+ ((bfd_boolean (*) (bfd *, flagword)) bfd_true)
#define _bfd_generic_bfd_copy_private_section_data \
- ((boolean (*) PARAMS ((bfd *, asection *, bfd *, asection *))) bfd_true)
+ ((bfd_boolean (*) (bfd *, asection *, bfd *, asection *)) bfd_true)
#define _bfd_generic_bfd_copy_private_symbol_data \
- ((boolean (*) PARAMS ((bfd *, asymbol *, bfd *, asymbol *))) bfd_true)
+ ((bfd_boolean (*) (bfd *, asymbol *, bfd *, asymbol *)) bfd_true)
#define _bfd_generic_bfd_print_private_bfd_data \
- ((boolean (*) PARAMS ((bfd *, PTR))) bfd_true)
+ ((bfd_boolean (*) (bfd *, void *)) bfd_true)
/* Routines to use for BFD_JUMP_TABLE_CORE when there is no core file
support. Use BFD_JUMP_TABLE_CORE (_bfd_nocore). */
-extern char *_bfd_nocore_core_file_failing_command PARAMS ((bfd *));
-extern int _bfd_nocore_core_file_failing_signal PARAMS ((bfd *));
-extern boolean _bfd_nocore_core_file_matches_executable_p
- PARAMS ((bfd *, bfd *));
+extern char *_bfd_nocore_core_file_failing_command
+ (bfd *);
+extern int _bfd_nocore_core_file_failing_signal
+ (bfd *);
+extern bfd_boolean _bfd_nocore_core_file_matches_executable_p
+ (bfd *, bfd *);
/* Routines to use for BFD_JUMP_TABLE_ARCHIVE when there is no archive
file support. Use BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive). */
@@ -193,19 +231,18 @@ extern boolean _bfd_nocore_core_file_matches_executable_p
#define _bfd_noarchive_slurp_armap bfd_false
#define _bfd_noarchive_slurp_extended_name_table bfd_false
#define _bfd_noarchive_construct_extended_name_table \
- ((boolean (*) PARAMS ((bfd *, char **, bfd_size_type *, const char **))) \
+ ((bfd_boolean (*) (bfd *, char **, bfd_size_type *, const char **)) \
bfd_false)
#define _bfd_noarchive_truncate_arname \
- ((void (*) PARAMS ((bfd *, const char *, char *))) bfd_void)
+ ((void (*) (bfd *, const char *, char *)) bfd_void)
#define _bfd_noarchive_write_armap \
- ((boolean (*) \
- PARAMS ((bfd *, unsigned int, struct orl *, unsigned int, int))) \
+ ((bfd_boolean (*) (bfd *, unsigned int, struct orl *, unsigned int, int)) \
bfd_false)
#define _bfd_noarchive_read_ar_hdr bfd_nullvoidptr
#define _bfd_noarchive_openr_next_archived_file \
- ((bfd *(*) PARAMS ((bfd *, bfd *))) bfd_nullvoidptr)
+ ((bfd *(*) (bfd *, bfd *)) bfd_nullvoidptr)
#define _bfd_noarchive_get_elt_at_index \
- ((bfd *(*) PARAMS ((bfd *, symindex))) bfd_nullvoidptr)
+ ((bfd *(*) (bfd *, symindex)) bfd_nullvoidptr)
#define _bfd_noarchive_generic_stat_arch_elt bfd_generic_stat_arch_elt
#define _bfd_noarchive_update_armap_timestamp bfd_false
@@ -215,8 +252,8 @@ extern boolean _bfd_nocore_core_file_matches_executable_p
#define _bfd_archive_bsd_slurp_armap bfd_slurp_bsd_armap
#define _bfd_archive_bsd_slurp_extended_name_table \
_bfd_slurp_extended_name_table
-extern boolean _bfd_archive_bsd_construct_extended_name_table
- PARAMS ((bfd *, char **, bfd_size_type *, const char **));
+extern bfd_boolean _bfd_archive_bsd_construct_extended_name_table
+ (bfd *, char **, bfd_size_type *, const char **);
#define _bfd_archive_bsd_truncate_arname bfd_bsd_truncate_arname
#define _bfd_archive_bsd_write_armap bsd_write_armap
#define _bfd_archive_bsd_read_ar_hdr _bfd_generic_read_ar_hdr
@@ -225,7 +262,8 @@ extern boolean _bfd_archive_bsd_construct_extended_name_table
#define _bfd_archive_bsd_get_elt_at_index _bfd_generic_get_elt_at_index
#define _bfd_archive_bsd_generic_stat_arch_elt \
bfd_generic_stat_arch_elt
-extern boolean _bfd_archive_bsd_update_armap_timestamp PARAMS ((bfd *));
+extern bfd_boolean _bfd_archive_bsd_update_armap_timestamp
+ (bfd *);
/* Routines to use for BFD_JUMP_TABLE_ARCHIVE to get COFF style
archives. Use BFD_JUMP_TABLE_ARCHIVE (_bfd_archive_coff). */
@@ -233,8 +271,8 @@ extern boolean _bfd_archive_bsd_update_armap_timestamp PARAMS ((bfd *));
#define _bfd_archive_coff_slurp_armap bfd_slurp_coff_armap
#define _bfd_archive_coff_slurp_extended_name_table \
_bfd_slurp_extended_name_table
-extern boolean _bfd_archive_coff_construct_extended_name_table
- PARAMS ((bfd *, char **, bfd_size_type *, const char **));
+extern bfd_boolean _bfd_archive_coff_construct_extended_name_table
+ (bfd *, char **, bfd_size_type *, const char **);
#define _bfd_archive_coff_truncate_arname bfd_dont_truncate_arname
#define _bfd_archive_coff_write_armap coff_write_armap
#define _bfd_archive_coff_read_ar_hdr _bfd_generic_read_ar_hdr
@@ -249,95 +287,89 @@ extern boolean _bfd_archive_coff_construct_extended_name_table
support. Use BFD_JUMP_TABLE_SYMBOLS (_bfd_nosymbols). */
#define _bfd_nosymbols_get_symtab_upper_bound _bfd_n1
-#define _bfd_nosymbols_get_symtab \
- ((long (*) PARAMS ((bfd *, asymbol **))) _bfd_n1)
+#define _bfd_nosymbols_canonicalize_symtab \
+ ((long (*) (bfd *, asymbol **)) _bfd_n1)
#define _bfd_nosymbols_make_empty_symbol _bfd_generic_make_empty_symbol
#define _bfd_nosymbols_print_symbol \
- ((void (*) PARAMS ((bfd *, PTR, asymbol *, bfd_print_symbol_type))) bfd_void)
+ ((void (*) (bfd *, void *, asymbol *, bfd_print_symbol_type)) bfd_void)
#define _bfd_nosymbols_get_symbol_info \
- ((void (*) PARAMS ((bfd *, asymbol *, symbol_info *))) bfd_void)
+ ((void (*) (bfd *, asymbol *, symbol_info *)) bfd_void)
#define _bfd_nosymbols_bfd_is_local_label_name \
- ((boolean (*) PARAMS ((bfd *, const char *))) bfd_false)
+ ((bfd_boolean (*) (bfd *, const char *)) bfd_false)
#define _bfd_nosymbols_get_lineno \
- ((alent *(*) PARAMS ((bfd *, asymbol *))) bfd_nullvoidptr)
+ ((alent *(*) (bfd *, asymbol *)) bfd_nullvoidptr)
#define _bfd_nosymbols_find_nearest_line \
- ((boolean (*) \
- PARAMS ((bfd *, asection *, asymbol **, bfd_vma, const char **, \
- const char **, unsigned int *))) \
+ ((bfd_boolean (*) (bfd *, asection *, asymbol **, bfd_vma, const char **, \
+ const char **, unsigned int *)) \
bfd_false)
#define _bfd_nosymbols_bfd_make_debug_symbol \
- ((asymbol *(*) PARAMS ((bfd *, PTR, unsigned long))) bfd_nullvoidptr)
+ ((asymbol *(*) (bfd *, void *, unsigned long)) bfd_nullvoidptr)
#define _bfd_nosymbols_read_minisymbols \
- ((long (*) PARAMS ((bfd *, boolean, PTR *, unsigned int *))) _bfd_n1)
+ ((long (*) (bfd *, bfd_boolean, void **, unsigned int *)) _bfd_n1)
#define _bfd_nosymbols_minisymbol_to_symbol \
- ((asymbol *(*) PARAMS ((bfd *, boolean, const PTR, asymbol *))) \
+ ((asymbol *(*) (bfd *, bfd_boolean, const void *, asymbol *)) \
bfd_nullvoidptr)
/* Routines to use for BFD_JUMP_TABLE_RELOCS when there is no reloc
support. Use BFD_JUMP_TABLE_RELOCS (_bfd_norelocs). */
#define _bfd_norelocs_get_reloc_upper_bound \
- ((long (*) PARAMS ((bfd *, asection *))) _bfd_n1)
+ ((long (*) (bfd *, asection *)) _bfd_n1)
#define _bfd_norelocs_canonicalize_reloc \
- ((long (*) PARAMS ((bfd *, asection *, arelent **, asymbol **))) _bfd_n1)
+ ((long (*) (bfd *, asection *, arelent **, asymbol **)) _bfd_n1)
#define _bfd_norelocs_bfd_reloc_type_lookup \
- ((reloc_howto_type *(*) PARAMS ((bfd *, bfd_reloc_code_real_type))) \
- bfd_nullvoidptr)
+ ((reloc_howto_type *(*) (bfd *, bfd_reloc_code_real_type)) bfd_nullvoidptr)
/* Routines to use for BFD_JUMP_TABLE_WRITE for targets which may not
be written. Use BFD_JUMP_TABLE_WRITE (_bfd_nowrite). */
#define _bfd_nowrite_set_arch_mach \
- ((boolean (*) PARAMS ((bfd *, enum bfd_architecture, unsigned long))) \
+ ((bfd_boolean (*) (bfd *, enum bfd_architecture, unsigned long)) \
bfd_false)
#define _bfd_nowrite_set_section_contents \
- ((boolean (*) PARAMS ((bfd *, asection *, PTR, file_ptr, bfd_size_type))) \
+ ((bfd_boolean (*) (bfd *, asection *, const void *, file_ptr, bfd_size_type)) \
bfd_false)
/* Generic routines to use for BFD_JUMP_TABLE_WRITE. Use
BFD_JUMP_TABLE_WRITE (_bfd_generic). */
#define _bfd_generic_set_arch_mach bfd_default_set_arch_mach
-extern boolean _bfd_generic_set_section_contents
- PARAMS ((bfd *, asection *, PTR, file_ptr, bfd_size_type));
+extern bfd_boolean _bfd_generic_set_section_contents
+ (bfd *, asection *, const void *, file_ptr, bfd_size_type);
/* Routines to use for BFD_JUMP_TABLE_LINK for targets which do not
support linking. Use BFD_JUMP_TABLE_LINK (_bfd_nolink). */
-#define _bfd_nolink_sizeof_headers ((int (*) PARAMS ((bfd *, boolean))) bfd_0)
+#define _bfd_nolink_sizeof_headers ((int (*) (bfd *, bfd_boolean)) bfd_0)
#define _bfd_nolink_bfd_get_relocated_section_contents \
- ((bfd_byte *(*) \
- PARAMS ((bfd *, struct bfd_link_info *, struct bfd_link_order *, \
- bfd_byte *, boolean, asymbol **))) \
+ ((bfd_byte *(*) (bfd *, struct bfd_link_info *, struct bfd_link_order *, \
+ bfd_byte *, bfd_boolean, asymbol **)) \
bfd_nullvoidptr)
#define _bfd_nolink_bfd_relax_section \
- ((boolean (*) \
- PARAMS ((bfd *, asection *, struct bfd_link_info *, boolean *))) \
+ ((bfd_boolean (*) \
+ (bfd *, asection *, struct bfd_link_info *, bfd_boolean *)) \
bfd_false)
#define _bfd_nolink_bfd_gc_sections \
- ((boolean (*) \
- PARAMS ((bfd *, struct bfd_link_info *))) \
+ ((bfd_boolean (*) (bfd *, struct bfd_link_info *)) \
bfd_false)
#define _bfd_nolink_bfd_merge_sections \
- ((boolean (*) \
- PARAMS ((bfd *, struct bfd_link_info *))) \
+ ((bfd_boolean (*) (bfd *, struct bfd_link_info *)) \
bfd_false)
#define _bfd_nolink_bfd_discard_group \
- ((boolean (*) \
- PARAMS ((bfd *, struct sec *))) \
+ ((bfd_boolean (*) (bfd *, struct bfd_section *)) \
bfd_false)
#define _bfd_nolink_bfd_link_hash_table_create \
- ((struct bfd_link_hash_table *(*) PARAMS ((bfd *))) bfd_nullvoidptr)
+ ((struct bfd_link_hash_table *(*) (bfd *)) bfd_nullvoidptr)
#define _bfd_nolink_bfd_link_hash_table_free \
- ((void (*) PARAMS ((struct bfd_link_hash_table *))) bfd_void)
+ ((void (*) (struct bfd_link_hash_table *)) bfd_void)
#define _bfd_nolink_bfd_link_add_symbols \
- ((boolean (*) PARAMS ((bfd *, struct bfd_link_info *))) bfd_false)
+ ((bfd_boolean (*) (bfd *, struct bfd_link_info *)) bfd_false)
#define _bfd_nolink_bfd_link_just_syms \
- ((void (*) PARAMS ((asection *, struct bfd_link_info *))) bfd_void)
+ ((void (*) (asection *, struct bfd_link_info *)) bfd_void)
#define _bfd_nolink_bfd_final_link \
- ((boolean (*) PARAMS ((bfd *, struct bfd_link_info *))) bfd_false)
+ ((bfd_boolean (*) (bfd *, struct bfd_link_info *)) bfd_false)
#define _bfd_nolink_bfd_link_split_section \
- ((boolean (*) PARAMS ((bfd *, struct sec *))) bfd_false)
+ ((bfd_boolean (*) (bfd *, struct bfd_section *)) bfd_false)
/* Routines to use for BFD_JUMP_TABLE_DYNAMIC for targets which do not
have dynamic symbols or relocs. Use BFD_JUMP_TABLE_DYNAMIC
@@ -345,187 +377,189 @@ extern boolean _bfd_generic_set_section_contents
#define _bfd_nodynamic_get_dynamic_symtab_upper_bound _bfd_n1
#define _bfd_nodynamic_canonicalize_dynamic_symtab \
- ((long (*) PARAMS ((bfd *, asymbol **))) _bfd_n1)
+ ((long (*) (bfd *, asymbol **)) _bfd_n1)
#define _bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_n1
#define _bfd_nodynamic_canonicalize_dynamic_reloc \
- ((long (*) PARAMS ((bfd *, arelent **, asymbol **))) _bfd_n1)
+ ((long (*) (bfd *, arelent **, asymbol **)) _bfd_n1)
/* Generic routine to determine of the given symbol is a local
label. */
-extern boolean bfd_generic_is_local_label_name PARAMS ((bfd *, const char *));
+extern bfd_boolean bfd_generic_is_local_label_name
+ (bfd *, const char *);
/* Generic minisymbol routines. */
extern long _bfd_generic_read_minisymbols
- PARAMS ((bfd *, boolean, PTR *, unsigned int *));
+ (bfd *, bfd_boolean, void **, unsigned int *);
extern asymbol *_bfd_generic_minisymbol_to_symbol
- PARAMS ((bfd *, boolean, const PTR, asymbol *));
+ (bfd *, bfd_boolean, const void *, asymbol *);
/* Find the nearest line using .stab/.stabstr sections. */
-extern boolean _bfd_stab_section_find_nearest_line
- PARAMS ((bfd *, asymbol **, asection *, bfd_vma, boolean *, const char **,
- const char **, unsigned int *, PTR *));
+extern bfd_boolean _bfd_stab_section_find_nearest_line
+ (bfd *, asymbol **, asection *, bfd_vma, bfd_boolean *,
+ const char **, const char **, unsigned int *, void **);
/* Find the neaderst line using DWARF 1 debugging information. */
-extern boolean _bfd_dwarf1_find_nearest_line
- PARAMS ((bfd *, asection *, asymbol **, bfd_vma, const char **,
- const char **, unsigned int *));
+extern bfd_boolean _bfd_dwarf1_find_nearest_line
+ (bfd *, asection *, asymbol **, bfd_vma, const char **,
+ const char **, unsigned int *);
/* Find the nearest line using DWARF 2 debugging information. */
-extern boolean _bfd_dwarf2_find_nearest_line
- PARAMS ((bfd *, asection *, asymbol **, bfd_vma, const char **,
- const char **, unsigned int *, unsigned int,
- PTR *));
+extern bfd_boolean _bfd_dwarf2_find_nearest_line
+ (bfd *, asection *, asymbol **, bfd_vma, const char **, const char **,
+ unsigned int *, unsigned int, void **);
/* Create a new section entry. */
extern struct bfd_hash_entry *bfd_section_hash_newfunc
- PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
+ (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
/* A routine to create entries for a bfd_link_hash_table. */
extern struct bfd_hash_entry *_bfd_link_hash_newfunc
- PARAMS ((struct bfd_hash_entry *entry,
- struct bfd_hash_table *table,
- const char *string));
+ (struct bfd_hash_entry *entry, struct bfd_hash_table *table,
+ const char *string);
/* Initialize a bfd_link_hash_table. */
-extern boolean _bfd_link_hash_table_init
- PARAMS ((struct bfd_link_hash_table *, bfd *,
- struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
- struct bfd_hash_table *,
- const char *)));
+extern bfd_boolean _bfd_link_hash_table_init
+ (struct bfd_link_hash_table *, bfd *,
+ struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
+ struct bfd_hash_table *,
+ const char *));
/* Generic link hash table creation routine. */
extern struct bfd_link_hash_table *_bfd_generic_link_hash_table_create
- PARAMS ((bfd *));
+ (bfd *);
/* Generic link hash table destruction routine. */
extern void _bfd_generic_link_hash_table_free
- PARAMS ((struct bfd_link_hash_table *));
+ (struct bfd_link_hash_table *);
/* Generic add symbol routine. */
-extern boolean _bfd_generic_link_add_symbols
- PARAMS ((bfd *, struct bfd_link_info *));
+extern bfd_boolean _bfd_generic_link_add_symbols
+ (bfd *, struct bfd_link_info *);
/* Generic add symbol routine. This version is used by targets for
which the linker must collect constructors and destructors by name,
as the collect2 program does. */
-extern boolean _bfd_generic_link_add_symbols_collect
- PARAMS ((bfd *, struct bfd_link_info *));
+extern bfd_boolean _bfd_generic_link_add_symbols_collect
+ (bfd *, struct bfd_link_info *);
/* Generic archive add symbol routine. */
-extern boolean _bfd_generic_link_add_archive_symbols
- PARAMS ((bfd *, struct bfd_link_info *,
- boolean (*checkfn) (bfd *, struct bfd_link_info *, boolean *)));
+extern bfd_boolean _bfd_generic_link_add_archive_symbols
+ (bfd *, struct bfd_link_info *,
+ bfd_boolean (*) (bfd *, struct bfd_link_info *, bfd_boolean *));
/* Forward declaration to avoid prototype errors. */
typedef struct bfd_link_hash_entry _bfd_link_hash_entry;
/* Generic routine to add a single symbol. */
-extern boolean _bfd_generic_link_add_one_symbol
- PARAMS ((struct bfd_link_info *, bfd *, const char *name, flagword,
- asection *, bfd_vma, const char *, boolean copy,
- boolean constructor, struct bfd_link_hash_entry **));
+extern bfd_boolean _bfd_generic_link_add_one_symbol
+ (struct bfd_link_info *, bfd *, const char *name, flagword,
+ asection *, bfd_vma, const char *, bfd_boolean copy,
+ bfd_boolean constructor, struct bfd_link_hash_entry **);
/* Generic routine to mark section as supplying symbols only. */
extern void _bfd_generic_link_just_syms
- PARAMS ((asection *, struct bfd_link_info *));
+ (asection *, struct bfd_link_info *);
/* Generic link routine. */
-extern boolean _bfd_generic_final_link
- PARAMS ((bfd *, struct bfd_link_info *));
+extern bfd_boolean _bfd_generic_final_link
+ (bfd *, struct bfd_link_info *);
-extern boolean _bfd_generic_link_split_section
- PARAMS ((bfd *, struct sec *));
+extern bfd_boolean _bfd_generic_link_split_section
+ (bfd *, struct bfd_section *);
/* Generic reloc_link_order processing routine. */
-extern boolean _bfd_generic_reloc_link_order
- PARAMS ((bfd *, struct bfd_link_info *, asection *,
- struct bfd_link_order *));
+extern bfd_boolean _bfd_generic_reloc_link_order
+ (bfd *, struct bfd_link_info *, asection *, struct bfd_link_order *);
/* Default link order processing routine. */
-extern boolean _bfd_default_link_order
- PARAMS ((bfd *, struct bfd_link_info *, asection *,
- struct bfd_link_order *));
+extern bfd_boolean _bfd_default_link_order
+ (bfd *, struct bfd_link_info *, asection *, struct bfd_link_order *);
/* Count the number of reloc entries in a link order list. */
extern unsigned int _bfd_count_link_order_relocs
- PARAMS ((struct bfd_link_order *));
+ (struct bfd_link_order *);
/* Final link relocation routine. */
extern bfd_reloc_status_type _bfd_final_link_relocate
- PARAMS ((reloc_howto_type *, bfd *, asection *, bfd_byte *,
- bfd_vma, bfd_vma, bfd_vma));
+ (reloc_howto_type *, bfd *, asection *, bfd_byte *,
+ bfd_vma, bfd_vma, bfd_vma);
/* Relocate a particular location by a howto and a value. */
extern bfd_reloc_status_type _bfd_relocate_contents
- PARAMS ((reloc_howto_type *, bfd *, bfd_vma, bfd_byte *));
+ (reloc_howto_type *, bfd *, bfd_vma, bfd_byte *);
/* Link stabs in sections in the first pass. */
-extern boolean _bfd_link_section_stabs
- PARAMS ((bfd *, PTR *, asection *, asection *, PTR *));
+extern bfd_boolean _bfd_link_section_stabs
+ (bfd *, void **, asection *, asection *, void **, bfd_size_type *);
/* Eliminate stabs for discarded functions and symbols. */
-extern boolean _bfd_discard_section_stabs
- PARAMS ((bfd *, asection *, PTR,
- boolean (*) (bfd_vma, PTR), PTR));
+extern bfd_boolean _bfd_discard_section_stabs
+ (bfd *, asection *, void *, bfd_boolean (*) (bfd_vma, void *), void *);
/* Write out the .stab section when linking stabs in sections. */
-extern boolean _bfd_write_section_stabs
- PARAMS ((bfd *, PTR *, asection *, PTR *, bfd_byte *));
+extern bfd_boolean _bfd_write_section_stabs
+ (bfd *, void **, asection *, void **, bfd_byte *);
/* Write out the .stabstr string table when linking stabs in sections. */
-extern boolean _bfd_write_stab_strings PARAMS ((bfd *, PTR *));
+extern bfd_boolean _bfd_write_stab_strings
+ (bfd *, void **);
/* Find an offset within a .stab section when linking stabs in
sections. */
extern bfd_vma _bfd_stab_section_offset
- PARAMS ((bfd *, PTR *, asection *, PTR *, bfd_vma));
+ (bfd *, void **, asection *, void **, bfd_vma);
/* Attempt to merge a SEC_MERGE section. */
-extern boolean _bfd_merge_section
- PARAMS ((bfd *, PTR *, asection *, PTR *));
+extern bfd_boolean _bfd_merge_section
+ (bfd *, void **, asection *, void **);
/* Attempt to merge SEC_MERGE sections. */
-extern boolean _bfd_merge_sections
- PARAMS ((bfd *, PTR, void (*)(bfd *, asection *)));
+extern bfd_boolean _bfd_merge_sections
+ (bfd *, void *, void (*) (bfd *, asection *));
/* Write out a merged section. */
-extern boolean _bfd_write_merged_section
- PARAMS ((bfd *, asection *, PTR));
+extern bfd_boolean _bfd_write_merged_section
+ (bfd *, asection *, void *);
/* Find an offset within a modified SEC_MERGE section. */
extern bfd_vma _bfd_merged_section_offset
- PARAMS ((bfd *, asection **, PTR, bfd_vma, bfd_vma));
+ (bfd *, asection **, void *, bfd_vma, bfd_vma);
/* Create a string table. */
-extern struct bfd_strtab_hash *_bfd_stringtab_init PARAMS ((void));
+extern struct bfd_strtab_hash *_bfd_stringtab_init
+ (void);
/* Create an XCOFF .debug section style string table. */
-extern struct bfd_strtab_hash *_bfd_xcoff_stringtab_init PARAMS ((void));
+extern struct bfd_strtab_hash *_bfd_xcoff_stringtab_init
+ (void);
/* Free a string table. */
-extern void _bfd_stringtab_free PARAMS ((struct bfd_strtab_hash *));
+extern void _bfd_stringtab_free
+ (struct bfd_strtab_hash *);
/* Get the size of a string table. */
-extern bfd_size_type _bfd_stringtab_size PARAMS ((struct bfd_strtab_hash *));
+extern bfd_size_type _bfd_stringtab_size
+ (struct bfd_strtab_hash *);
/* Add a string to a string table. */
extern bfd_size_type _bfd_stringtab_add
- PARAMS ((struct bfd_strtab_hash *, const char *, boolean hash,
- boolean copy));
+ (struct bfd_strtab_hash *, const char *, bfd_boolean hash, bfd_boolean copy);
/* Write out a string table. */
-extern boolean _bfd_stringtab_emit PARAMS ((bfd *, struct bfd_strtab_hash *));
+extern bfd_boolean _bfd_stringtab_emit
+ (bfd *, struct bfd_strtab_hash *);
/* Check that endianness of input and output file match. */
-extern boolean _bfd_generic_verify_endian_match PARAMS ((bfd *, bfd *));
+extern bfd_boolean _bfd_generic_verify_endian_match
+ (bfd *, bfd *);
/* Macros to tell if bfds are read or write enabled.
@@ -536,19 +570,22 @@ extern boolean _bfd_generic_verify_endian_match PARAMS ((bfd *, bfd *));
!bfd_read_p, and only sometimes bfd_write_p.
*/
-#define bfd_read_p(abfd) ((abfd)->direction == read_direction || (abfd)->direction == both_direction)
-#define bfd_write_p(abfd) ((abfd)->direction == write_direction || (abfd)->direction == both_direction)
+#define bfd_read_p(abfd) \
+ ((abfd)->direction == read_direction || (abfd)->direction == both_direction)
+#define bfd_write_p(abfd) \
+ ((abfd)->direction == write_direction || (abfd)->direction == both_direction)
-void bfd_assert PARAMS ((const char*,int));
+void bfd_assert
+ (const char*,int);
#define BFD_ASSERT(x) \
-{ if (!(x)) bfd_assert(__FILE__,__LINE__); }
+ { if (!(x)) bfd_assert(__FILE__,__LINE__); }
#define BFD_FAIL() \
-{ bfd_assert(__FILE__,__LINE__); }
+ { bfd_assert(__FILE__,__LINE__); }
-extern void _bfd_abort PARAMS ((const char *, int, const char *))
- ATTRIBUTE_NORETURN;
+extern void _bfd_abort
+ (const char *, int, const char *) ATTRIBUTE_NORETURN;
/* if gcc >= 2.6, we can give a function name, too */
#if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 6)
@@ -558,7 +595,13 @@ extern void _bfd_abort PARAMS ((const char *, int, const char *))
#undef abort
#define abort() _bfd_abort (__FILE__, __LINE__, __PRETTY_FUNCTION__)
-FILE * bfd_cache_lookup_worker PARAMS ((bfd *));
+/* Manipulate a system FILE but using BFD's "file_ptr", rather than
+ the system "off_t" or "off64_t", as the offset. */
+extern file_ptr real_ftell (FILE *file);
+extern int real_fseek (FILE *file, file_ptr offset, int whence);
+
+FILE * bfd_cache_lookup_worker
+ (bfd *);
extern bfd *bfd_last_cache;
@@ -567,6 +610,9 @@ extern bfd *bfd_last_cache;
extern const bfd_target * const *bfd_target_vector;
extern const bfd_target *bfd_default_vector[];
+/* List of associated target vectors. */
+extern const bfd_target * const *bfd_associated_vector;
+
/* Functions shared by the ECOFF and MIPS ELF backends, which have no
other common header files. */
@@ -574,22 +620,28 @@ extern const bfd_target *bfd_default_vector[];
struct ecoff_find_line;
#endif
-extern boolean _bfd_ecoff_locate_line
- PARAMS ((bfd *, asection *, bfd_vma, struct ecoff_debug_info * const,
- const struct ecoff_debug_swap * const, struct ecoff_find_line *,
- const char **, const char **, unsigned int *));
-extern boolean _bfd_ecoff_get_accumulated_pdr PARAMS ((PTR, bfd_byte *));
-extern boolean _bfd_ecoff_get_accumulated_sym PARAMS ((PTR, bfd_byte *));
-extern boolean _bfd_ecoff_get_accumulated_ss PARAMS ((PTR, bfd_byte *));
-
-extern bfd_vma _bfd_get_gp_value PARAMS ((bfd *));
-extern void _bfd_set_gp_value PARAMS ((bfd *, bfd_vma));
+extern bfd_boolean _bfd_ecoff_locate_line
+ (bfd *, asection *, bfd_vma, struct ecoff_debug_info * const,
+ const struct ecoff_debug_swap * const, struct ecoff_find_line *,
+ const char **, const char **, unsigned int *);
+extern bfd_boolean _bfd_ecoff_get_accumulated_pdr
+ (void *, bfd_byte *);
+extern bfd_boolean _bfd_ecoff_get_accumulated_sym
+ (void *, bfd_byte *);
+extern bfd_boolean _bfd_ecoff_get_accumulated_ss
+ (void *, bfd_byte *);
+
+extern bfd_vma _bfd_get_gp_value
+ (bfd *);
+extern void _bfd_set_gp_value
+ (bfd *, bfd_vma);
/* Function shared by the COFF and ELF SH backends, which have no
other common header files. */
-extern boolean _bfd_sh_align_load_span
- PARAMS ((bfd *, asection *, bfd_byte *,
- boolean (*) (bfd *, asection *, PTR, bfd_byte *, bfd_vma),
- PTR, bfd_vma **, bfd_vma *, bfd_vma, bfd_vma, boolean *));
-
+#ifndef _bfd_sh_align_load_span
+extern bfd_boolean _bfd_sh_align_load_span
+ (bfd *, asection *, bfd_byte *,
+ bfd_boolean (*) (bfd *, asection *, void *, bfd_byte *, bfd_vma),
+ void *, bfd_vma **, bfd_vma *, bfd_vma, bfd_vma, bfd_boolean *);
+#endif
diff --git a/contrib/binutils/bfd/libbfd.c b/contrib/binutils/bfd/libbfd.c
index f21abbc..be090e9 100644
--- a/contrib/binutils/bfd/libbfd.c
+++ b/contrib/binutils/bfd/libbfd.c
@@ -1,6 +1,6 @@
/* Assorted BFD support routines, only used internally.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
Written by Cygnus Support.
@@ -28,8 +28,6 @@
#define getpagesize() 2048
#endif
-static size_t real_read PARAMS ((PTR, size_t, size_t, FILE *));
-
/*
SECTION
Internal functions
@@ -43,52 +41,46 @@ DESCRIPTION
/* A routine which is used in target vectors for unsupported
operations. */
-boolean
-bfd_false (ignore)
- bfd *ignore ATTRIBUTE_UNUSED;
+bfd_boolean
+bfd_false (bfd *ignore ATTRIBUTE_UNUSED)
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
/* A routine which is used in target vectors for supported operations
which do not actually do anything. */
-boolean
-bfd_true (ignore)
- bfd *ignore ATTRIBUTE_UNUSED;
+bfd_boolean
+bfd_true (bfd *ignore ATTRIBUTE_UNUSED)
{
- return true;
+ return TRUE;
}
/* A routine which is used in target vectors for unsupported
operations which return a pointer value. */
-PTR
-bfd_nullvoidptr (ignore)
- bfd *ignore ATTRIBUTE_UNUSED;
+void *
+bfd_nullvoidptr (bfd *ignore ATTRIBUTE_UNUSED)
{
bfd_set_error (bfd_error_invalid_operation);
return NULL;
}
int
-bfd_0 (ignore)
- bfd *ignore ATTRIBUTE_UNUSED;
+bfd_0 (bfd *ignore ATTRIBUTE_UNUSED)
{
return 0;
}
unsigned int
-bfd_0u (ignore)
- bfd *ignore ATTRIBUTE_UNUSED;
+bfd_0u (bfd *ignore ATTRIBUTE_UNUSED)
{
return 0;
}
long
-bfd_0l (ignore)
- bfd *ignore ATTRIBUTE_UNUSED;
+bfd_0l (bfd *ignore ATTRIBUTE_UNUSED)
{
return 0;
}
@@ -97,53 +89,48 @@ bfd_0l (ignore)
operations which return -1 on error. */
long
-_bfd_n1 (ignore_abfd)
- bfd *ignore_abfd ATTRIBUTE_UNUSED;
+_bfd_n1 (bfd *ignore_abfd ATTRIBUTE_UNUSED)
{
bfd_set_error (bfd_error_invalid_operation);
return -1;
}
void
-bfd_void (ignore)
- bfd *ignore ATTRIBUTE_UNUSED;
+bfd_void (bfd *ignore ATTRIBUTE_UNUSED)
{
}
-boolean
-_bfd_nocore_core_file_matches_executable_p (ignore_core_bfd, ignore_exec_bfd)
- bfd *ignore_core_bfd ATTRIBUTE_UNUSED;
- bfd *ignore_exec_bfd ATTRIBUTE_UNUSED;
+bfd_boolean
+_bfd_nocore_core_file_matches_executable_p
+ (bfd *ignore_core_bfd ATTRIBUTE_UNUSED,
+ bfd *ignore_exec_bfd ATTRIBUTE_UNUSED)
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
/* Routine to handle core_file_failing_command entry point for targets
without core file support. */
char *
-_bfd_nocore_core_file_failing_command (ignore_abfd)
- bfd *ignore_abfd ATTRIBUTE_UNUSED;
+_bfd_nocore_core_file_failing_command (bfd *ignore_abfd ATTRIBUTE_UNUSED)
{
bfd_set_error (bfd_error_invalid_operation);
- return (char *)NULL;
+ return NULL;
}
/* Routine to handle core_file_failing_signal entry point for targets
without core file support. */
int
-_bfd_nocore_core_file_failing_signal (ignore_abfd)
- bfd *ignore_abfd ATTRIBUTE_UNUSED;
+_bfd_nocore_core_file_failing_signal (bfd *ignore_abfd ATTRIBUTE_UNUSED)
{
bfd_set_error (bfd_error_invalid_operation);
return 0;
}
const bfd_target *
-_bfd_dummy_target (ignore_abfd)
- bfd *ignore_abfd ATTRIBUTE_UNUSED;
+_bfd_dummy_target (bfd *ignore_abfd ATTRIBUTE_UNUSED)
{
bfd_set_error (bfd_error_wrong_format);
return 0;
@@ -151,11 +138,10 @@ _bfd_dummy_target (ignore_abfd)
/* Allocate memory using malloc. */
-PTR
-bfd_malloc (size)
- bfd_size_type size;
+void *
+bfd_malloc (bfd_size_type size)
{
- PTR ptr;
+ void *ptr;
if (size != (size_t) size)
{
@@ -163,7 +149,7 @@ bfd_malloc (size)
return NULL;
}
- ptr = (PTR) malloc ((size_t) size);
+ ptr = malloc ((size_t) size);
if (ptr == NULL && (size_t) size != 0)
bfd_set_error (bfd_error_no_memory);
@@ -172,12 +158,10 @@ bfd_malloc (size)
/* Reallocate memory using realloc. */
-PTR
-bfd_realloc (ptr, size)
- PTR ptr;
- bfd_size_type size;
+void *
+bfd_realloc (void *ptr, bfd_size_type size)
{
- PTR ret;
+ void *ret;
if (size != (size_t) size)
{
@@ -186,9 +170,9 @@ bfd_realloc (ptr, size)
}
if (ptr == NULL)
- ret = (PTR) malloc ((size_t) size);
+ ret = malloc ((size_t) size);
else
- ret = (PTR) realloc (ptr, (size_t) size);
+ ret = realloc (ptr, (size_t) size);
if (ret == NULL && (size_t) size != 0)
bfd_set_error (bfd_error_no_memory);
@@ -198,11 +182,10 @@ bfd_realloc (ptr, size)
/* Allocate memory using malloc and clear it. */
-PTR
-bfd_zmalloc (size)
- bfd_size_type size;
+void *
+bfd_zmalloc (bfd_size_type size)
{
- PTR ptr;
+ void *ptr;
if (size != (size_t) size)
{
@@ -210,7 +193,7 @@ bfd_zmalloc (size)
return NULL;
}
- ptr = (PTR) malloc ((size_t) size);
+ ptr = malloc ((size_t) size);
if ((size_t) size != 0)
{
@@ -222,378 +205,12 @@ bfd_zmalloc (size)
return ptr;
}
-
-/* Some IO code */
-
-/* Note that archive entries don't have streams; they share their parent's.
- This allows someone to play with the iostream behind BFD's back.
-
- Also, note that the origin pointer points to the beginning of a file's
- contents (0 for non-archive elements). For archive entries this is the
- first octet in the file, NOT the beginning of the archive header. */
-
-static size_t
-real_read (where, a, b, file)
- PTR where;
- size_t a;
- size_t b;
- FILE *file;
-{
- /* FIXME - this looks like an optimization, but it's really to cover
- up for a feature of some OSs (not solaris - sigh) that
- ld/pe-dll.c takes advantage of (apparently) when it creates BFDs
- internally and tries to link against them. BFD seems to be smart
- enough to realize there are no symbol records in the "file" that
- doesn't exist but attempts to read them anyway. On Solaris,
- attempting to read zero bytes from a NULL file results in a core
- dump, but on other platforms it just returns zero bytes read.
- This makes it to something reasonable. - DJ */
- if (a == 0 || b == 0)
- return 0;
-
-
-#if defined (__VAX) && defined (VMS)
- /* Apparently fread on Vax VMS does not keep the record length
- information. */
- return read (fileno (file), where, a * b);
-#else
- return fread (where, a, b, file);
-#endif
-}
-
-/* Return value is amount read. */
-
-bfd_size_type
-bfd_bread (ptr, size, abfd)
- PTR ptr;
- bfd_size_type size;
- bfd *abfd;
-{
- size_t nread;
-
- if ((abfd->flags & BFD_IN_MEMORY) != 0)
- {
- struct bfd_in_memory *bim;
- bfd_size_type get;
-
- bim = (struct bfd_in_memory *) abfd->iostream;
- get = size;
- if (abfd->where + get > bim->size)
- {
- if (bim->size < (bfd_size_type) abfd->where)
- get = 0;
- else
- get = bim->size - abfd->where;
- bfd_set_error (bfd_error_file_truncated);
- }
- memcpy (ptr, bim->buffer + abfd->where, (size_t) get);
- abfd->where += get;
- return get;
- }
-
- nread = real_read (ptr, 1, (size_t) size, bfd_cache_lookup (abfd));
- if (nread != (size_t) -1)
- abfd->where += nread;
-
- /* Set bfd_error if we did not read as much data as we expected.
-
- If the read failed due to an error set the bfd_error_system_call,
- else set bfd_error_file_truncated.
-
- A BFD backend may wish to override bfd_error_file_truncated to
- provide something more useful (eg. no_symbols or wrong_format). */
- if (nread != size)
- {
- if (ferror (bfd_cache_lookup (abfd)))
- bfd_set_error (bfd_error_system_call);
- else
- bfd_set_error (bfd_error_file_truncated);
- }
-
- return nread;
-}
-
-/* The window support stuff should probably be broken out into
- another file.... */
-/* The idea behind the next and refcount fields is that one mapped
- region can suffice for multiple read-only windows or multiple
- non-overlapping read-write windows. It's not implemented yet
- though. */
-struct _bfd_window_internal {
- struct _bfd_window_internal *next;
- PTR data;
- bfd_size_type size;
- int refcount : 31; /* should be enough... */
- unsigned mapped : 1; /* 1 = mmap, 0 = malloc */
-};
-
-void
-bfd_init_window (windowp)
- bfd_window *windowp;
-{
- windowp->data = 0;
- windowp->i = 0;
- windowp->size = 0;
-}
-
-/* Currently, if USE_MMAP is undefined, none if the window stuff is
- used. Okay, so it's mis-named. At least the command-line option
- "--without-mmap" is more obvious than "--without-windows" or some
- such. */
-#ifdef USE_MMAP
-
-#undef HAVE_MPROTECT /* code's not tested yet */
-
-#if HAVE_MMAP || HAVE_MPROTECT || HAVE_MADVISE
-#include <sys/mman.h>
-#endif
-
-#ifndef MAP_FILE
-#define MAP_FILE 0
-#endif
-
-static int debug_windows;
-
-void
-bfd_free_window (windowp)
- bfd_window *windowp;
-{
- bfd_window_internal *i = windowp->i;
- windowp->i = 0;
- windowp->data = 0;
- if (i == 0)
- return;
- i->refcount--;
- if (debug_windows)
- fprintf (stderr, "freeing window @%p<%p,%lx,%p>\n",
- windowp, windowp->data, windowp->size, windowp->i);
- if (i->refcount != 0)
- return;
-
- if (i->mapped)
- {
-#ifdef HAVE_MMAP
- munmap (i->data, i->size);
- goto no_free;
-#else
- abort ();
-#endif
- }
-#ifdef HAVE_MPROTECT
- mprotect (i->data, i->size, PROT_READ | PROT_WRITE);
-#endif
- free (i->data);
-#ifdef HAVE_MMAP
- no_free:
-#endif
- i->data = 0;
- /* There should be no more references to i at this point. */
- free (i);
-}
-
-static int ok_to_map = 1;
-
-boolean
-bfd_get_file_window (abfd, offset, size, windowp, writable)
- bfd *abfd;
- file_ptr offset;
- bfd_size_type size;
- bfd_window *windowp;
- boolean writable;
-{
- static size_t pagesize;
- bfd_window_internal *i = windowp->i;
- bfd_size_type size_to_alloc = size;
-
- if (debug_windows)
- fprintf (stderr, "bfd_get_file_window (%p, %6ld, %6ld, %p<%p,%lx,%p>, %d)",
- abfd, (long) offset, (long) size,
- windowp, windowp->data, (unsigned long) windowp->size,
- windowp->i, writable);
-
- /* Make sure we know the page size, so we can be friendly to mmap. */
- if (pagesize == 0)
- pagesize = getpagesize ();
- if (pagesize == 0)
- abort ();
-
- if (i == 0)
- {
- i = ((bfd_window_internal *)
- bfd_zmalloc ((bfd_size_type) sizeof (bfd_window_internal)));
- windowp->i = i;
- if (i == 0)
- return false;
- i->data = 0;
- }
-#ifdef HAVE_MMAP
- if (ok_to_map
- && (i->data == 0 || i->mapped == 1)
- && (abfd->flags & BFD_IN_MEMORY) == 0)
- {
- file_ptr file_offset, offset2;
- size_t real_size;
- int fd;
- FILE *f;
-
- /* Find the real file and the real offset into it. */
- while (abfd->my_archive != NULL)
- {
- offset += abfd->origin;
- abfd = abfd->my_archive;
- }
- f = bfd_cache_lookup (abfd);
- fd = fileno (f);
-
- /* Compute offsets and size for mmap and for the user's data. */
- offset2 = offset % pagesize;
- if (offset2 < 0)
- abort ();
- file_offset = offset - offset2;
- real_size = offset + size - file_offset;
- real_size = real_size + pagesize - 1;
- real_size -= real_size % pagesize;
-
- /* If we're re-using a memory region, make sure it's big enough. */
- if (i->data && i->size < size)
- {
- munmap (i->data, i->size);
- i->data = 0;
- }
- i->data = mmap (i->data, real_size,
- writable ? PROT_WRITE | PROT_READ : PROT_READ,
- (writable
- ? MAP_FILE | MAP_PRIVATE
- : MAP_FILE | MAP_SHARED),
- fd, file_offset);
- if (i->data == (PTR) -1)
- {
- /* An error happened. Report it, or try using malloc, or
- something. */
- bfd_set_error (bfd_error_system_call);
- i->data = 0;
- windowp->data = 0;
- if (debug_windows)
- fprintf (stderr, "\t\tmmap failed!\n");
- return false;
- }
- if (debug_windows)
- fprintf (stderr, "\n\tmapped %ld at %p, offset is %ld\n",
- (long) real_size, i->data, (long) offset2);
- i->size = real_size;
- windowp->data = (PTR) ((bfd_byte *) i->data + offset2);
- windowp->size = size;
- i->mapped = 1;
- return true;
- }
- else if (debug_windows)
- {
- if (ok_to_map)
- fprintf (stderr, _("not mapping: data=%lx mapped=%d\n"),
- (unsigned long) i->data, (int) i->mapped);
- else
- fprintf (stderr, _("not mapping: env var not set\n"));
- }
-#else
- ok_to_map = 0;
-#endif
-
-#ifdef HAVE_MPROTECT
- if (!writable)
- {
- size_to_alloc += pagesize - 1;
- size_to_alloc -= size_to_alloc % pagesize;
- }
-#endif
- if (debug_windows)
- fprintf (stderr, "\n\t%s(%6ld)",
- i->data ? "realloc" : " malloc", (long) size_to_alloc);
- i->data = (PTR) bfd_realloc (i->data, size_to_alloc);
- if (debug_windows)
- fprintf (stderr, "\t-> %p\n", i->data);
- i->refcount = 1;
- if (i->data == NULL)
- {
- if (size_to_alloc == 0)
- return true;
- return false;
- }
- if (bfd_seek (abfd, offset, SEEK_SET) != 0)
- return false;
- i->size = bfd_bread (i->data, size, abfd);
- if (i->size != size)
- return false;
- i->mapped = 0;
-#ifdef HAVE_MPROTECT
- if (!writable)
- {
- if (debug_windows)
- fprintf (stderr, "\tmprotect (%p, %ld, PROT_READ)\n", i->data,
- (long) i->size);
- mprotect (i->data, i->size, PROT_READ);
- }
-#endif
- windowp->data = i->data;
- windowp->size = i->size;
- return true;
-}
-
-#endif /* USE_MMAP */
-
-bfd_size_type
-bfd_bwrite (ptr, size, abfd)
- const PTR ptr;
- bfd_size_type size;
- bfd *abfd;
-{
- size_t nwrote;
-
- if ((abfd->flags & BFD_IN_MEMORY) != 0)
- {
- struct bfd_in_memory *bim = (struct bfd_in_memory *) (abfd->iostream);
- size = (size_t) size;
- if (abfd->where + size > bim->size)
- {
- bfd_size_type newsize, oldsize;
-
- oldsize = (bim->size + 127) & ~(bfd_size_type) 127;
- bim->size = abfd->where + size;
- /* Round up to cut down on memory fragmentation */
- newsize = (bim->size + 127) & ~(bfd_size_type) 127;
- if (newsize > oldsize)
- {
- bim->buffer = (bfd_byte *) bfd_realloc (bim->buffer, newsize);
- if (bim->buffer == 0)
- {
- bim->size = 0;
- return 0;
- }
- }
- }
- memcpy (bim->buffer + abfd->where, ptr, (size_t) size);
- abfd->where += size;
- return size;
- }
-
- nwrote = fwrite (ptr, 1, (size_t) size, bfd_cache_lookup (abfd));
- if (nwrote != (size_t) -1)
- abfd->where += nwrote;
- if (nwrote != size)
- {
-#ifdef ENOSPC
- errno = ENOSPC;
-#endif
- bfd_set_error (bfd_error_system_call);
- }
- return nwrote;
-}
-
/*
INTERNAL_FUNCTION
bfd_write_bigendian_4byte_int
SYNOPSIS
- boolean bfd_write_bigendian_4byte_int (bfd *, unsigned int);
+ bfd_boolean bfd_write_bigendian_4byte_int (bfd *, unsigned int);
DESCRIPTION
Write a 4 byte integer @var{i} to the output BFD @var{abfd}, in big
@@ -601,196 +218,14 @@ DESCRIPTION
archives.
*/
-boolean
-bfd_write_bigendian_4byte_int (abfd, i)
- bfd *abfd;
- unsigned int i;
+bfd_boolean
+bfd_write_bigendian_4byte_int (bfd *abfd, unsigned int i)
{
bfd_byte buffer[4];
bfd_putb32 ((bfd_vma) i, buffer);
- return (boolean) (bfd_bwrite ((PTR) buffer, (bfd_size_type) 4, abfd) == 4);
-}
-
-bfd_vma
-bfd_tell (abfd)
- bfd *abfd;
-{
- file_ptr ptr;
-
- if ((abfd->flags & BFD_IN_MEMORY) != 0)
- return abfd->where;
-
- ptr = ftell (bfd_cache_lookup (abfd));
-
- if (abfd->my_archive)
- ptr -= abfd->origin;
- abfd->where = ptr;
- return ptr;
-}
-
-int
-bfd_flush (abfd)
- bfd *abfd;
-{
- if ((abfd->flags & BFD_IN_MEMORY) != 0)
- return 0;
- return fflush (bfd_cache_lookup(abfd));
-}
-
-/* Returns 0 for success, negative value for failure (in which case
- bfd_get_error can retrieve the error code). */
-int
-bfd_stat (abfd, statbuf)
- bfd *abfd;
- struct stat *statbuf;
-{
- FILE *f;
- int result;
-
- if ((abfd->flags & BFD_IN_MEMORY) != 0)
- abort ();
-
- f = bfd_cache_lookup (abfd);
- if (f == NULL)
- {
- bfd_set_error (bfd_error_system_call);
- return -1;
- }
- result = fstat (fileno (f), statbuf);
- if (result < 0)
- bfd_set_error (bfd_error_system_call);
- return result;
+ return bfd_bwrite (buffer, (bfd_size_type) 4, abfd) == 4;
}
-/* Returns 0 for success, nonzero for failure (in which case bfd_get_error
- can retrieve the error code). */
-
-int
-bfd_seek (abfd, position, direction)
- bfd *abfd;
- file_ptr position;
- int direction;
-{
- int result;
- FILE *f;
- long file_position;
- /* For the time being, a BFD may not seek to it's end. The problem
- is that we don't easily have a way to recognize the end of an
- element in an archive. */
-
- BFD_ASSERT (direction == SEEK_SET || direction == SEEK_CUR);
-
- if (direction == SEEK_CUR && position == 0)
- return 0;
-
- if ((abfd->flags & BFD_IN_MEMORY) != 0)
- {
- struct bfd_in_memory *bim;
-
- bim = (struct bfd_in_memory *) abfd->iostream;
-
- if (direction == SEEK_SET)
- abfd->where = position;
- else
- abfd->where += position;
-
- if (abfd->where > bim->size)
- {
- if ((abfd->direction == write_direction) ||
- (abfd->direction == both_direction))
- {
- bfd_size_type newsize, oldsize;
- oldsize = (bim->size + 127) & ~(bfd_size_type) 127;
- bim->size = abfd->where;
- /* Round up to cut down on memory fragmentation */
- newsize = (bim->size + 127) & ~(bfd_size_type) 127;
- if (newsize > oldsize)
- {
- bim->buffer = (bfd_byte *) bfd_realloc (bim->buffer, newsize);
- if (bim->buffer == 0)
- {
- bim->size = 0;
- return -1;
- }
- }
- }
- else
- {
- abfd->where = bim->size;
- bfd_set_error (bfd_error_file_truncated);
- return -1;
- }
- }
- return 0;
- }
-
- if (abfd->format != bfd_archive && abfd->my_archive == 0)
- {
-#if 0
- /* Explanation for this code: I'm only about 95+% sure that the above
- conditions are sufficient and that all i/o calls are properly
- adjusting the `where' field. So this is sort of an `assert'
- that the `where' field is correct. If we can go a while without
- tripping the abort, we can probably safely disable this code,
- so that the real optimizations happen. */
- file_ptr where_am_i_now;
- where_am_i_now = ftell (bfd_cache_lookup (abfd));
- if (abfd->my_archive)
- where_am_i_now -= abfd->origin;
- if (where_am_i_now != abfd->where)
- abort ();
-#endif
- if (direction == SEEK_SET && (bfd_vma) position == abfd->where)
- return 0;
- }
- else
- {
- /* We need something smarter to optimize access to archives.
- Currently, anything inside an archive is read via the file
- handle for the archive. Which means that a bfd_seek on one
- component affects the `current position' in the archive, as
- well as in any other component.
-
- It might be sufficient to put a spike through the cache
- abstraction, and look to the archive for the file position,
- but I think we should try for something cleaner.
-
- In the meantime, no optimization for archives. */
- }
-
- f = bfd_cache_lookup (abfd);
- file_position = position;
- if (direction == SEEK_SET && abfd->my_archive != NULL)
- file_position += abfd->origin;
-
- result = fseek (f, file_position, direction);
- if (result != 0)
- {
- int hold_errno = errno;
-
- /* Force redetermination of `where' field. */
- bfd_tell (abfd);
-
- /* An EINVAL error probably means that the file offset was
- absurd. */
- if (hold_errno == EINVAL)
- bfd_set_error (bfd_error_file_truncated);
- else
- {
- bfd_set_error (bfd_error_system_call);
- errno = hold_errno;
- }
- }
- else
- {
- /* Adjust `where' field. */
- if (direction == SEEK_SET)
- abfd->where = position;
- else
- abfd->where += position;
- }
- return result;
-}
/** The do-it-yourself (byte) sex-change kit */
@@ -831,54 +266,54 @@ DESCRIPTION
.{* Byte swapping macros for user section data. *}
.
.#define bfd_put_8(abfd, val, ptr) \
-. ((void) (*((unsigned char *) (ptr)) = (unsigned char) (val)))
+. ((void) (*((unsigned char *) (ptr)) = (val) & 0xff))
.#define bfd_put_signed_8 \
-. bfd_put_8
+. bfd_put_8
.#define bfd_get_8(abfd, ptr) \
-. (*(unsigned char *) (ptr) & 0xff)
+. (*(unsigned char *) (ptr) & 0xff)
.#define bfd_get_signed_8(abfd, ptr) \
-. (((*(unsigned char *) (ptr) & 0xff) ^ 0x80) - 0x80)
+. (((*(unsigned char *) (ptr) & 0xff) ^ 0x80) - 0x80)
.
.#define bfd_put_16(abfd, val, ptr) \
-. BFD_SEND(abfd, bfd_putx16, ((val),(ptr)))
+. BFD_SEND (abfd, bfd_putx16, ((val),(ptr)))
.#define bfd_put_signed_16 \
-. bfd_put_16
+. bfd_put_16
.#define bfd_get_16(abfd, ptr) \
-. BFD_SEND(abfd, bfd_getx16, (ptr))
+. BFD_SEND (abfd, bfd_getx16, (ptr))
.#define bfd_get_signed_16(abfd, ptr) \
-. BFD_SEND (abfd, bfd_getx_signed_16, (ptr))
+. BFD_SEND (abfd, bfd_getx_signed_16, (ptr))
.
.#define bfd_put_32(abfd, val, ptr) \
-. BFD_SEND(abfd, bfd_putx32, ((val),(ptr)))
+. BFD_SEND (abfd, bfd_putx32, ((val),(ptr)))
.#define bfd_put_signed_32 \
-. bfd_put_32
+. bfd_put_32
.#define bfd_get_32(abfd, ptr) \
-. BFD_SEND(abfd, bfd_getx32, (ptr))
+. BFD_SEND (abfd, bfd_getx32, (ptr))
.#define bfd_get_signed_32(abfd, ptr) \
-. BFD_SEND(abfd, bfd_getx_signed_32, (ptr))
+. BFD_SEND (abfd, bfd_getx_signed_32, (ptr))
.
.#define bfd_put_64(abfd, val, ptr) \
-. BFD_SEND(abfd, bfd_putx64, ((val), (ptr)))
+. BFD_SEND (abfd, bfd_putx64, ((val), (ptr)))
.#define bfd_put_signed_64 \
-. bfd_put_64
+. bfd_put_64
.#define bfd_get_64(abfd, ptr) \
-. BFD_SEND(abfd, bfd_getx64, (ptr))
+. BFD_SEND (abfd, bfd_getx64, (ptr))
.#define bfd_get_signed_64(abfd, ptr) \
-. BFD_SEND(abfd, bfd_getx_signed_64, (ptr))
+. BFD_SEND (abfd, bfd_getx_signed_64, (ptr))
.
-.#define bfd_get(bits, abfd, ptr) \
-. ( (bits) == 8 ? (bfd_vma) bfd_get_8 (abfd, ptr) \
-. : (bits) == 16 ? bfd_get_16 (abfd, ptr) \
-. : (bits) == 32 ? bfd_get_32 (abfd, ptr) \
-. : (bits) == 64 ? bfd_get_64 (abfd, ptr) \
-. : (abort (), (bfd_vma) - 1))
+.#define bfd_get(bits, abfd, ptr) \
+. ((bits) == 8 ? (bfd_vma) bfd_get_8 (abfd, ptr) \
+. : (bits) == 16 ? bfd_get_16 (abfd, ptr) \
+. : (bits) == 32 ? bfd_get_32 (abfd, ptr) \
+. : (bits) == 64 ? bfd_get_64 (abfd, ptr) \
+. : (abort (), (bfd_vma) - 1))
.
-.#define bfd_put(bits, abfd, val, ptr) \
-. ( (bits) == 8 ? bfd_put_8 (abfd, val, ptr) \
-. : (bits) == 16 ? bfd_put_16 (abfd, val, ptr) \
-. : (bits) == 32 ? bfd_put_32 (abfd, val, ptr) \
-. : (bits) == 64 ? bfd_put_64 (abfd, val, ptr) \
-. : (abort (), (void) 0))
+.#define bfd_put(bits, abfd, val, ptr) \
+. ((bits) == 8 ? bfd_put_8 (abfd, val, ptr) \
+. : (bits) == 16 ? bfd_put_16 (abfd, val, ptr) \
+. : (bits) == 32 ? bfd_put_32 (abfd, val, ptr) \
+. : (bits) == 64 ? bfd_put_64 (abfd, val, ptr) \
+. : (abort (), (void) 0))
.
*/
@@ -932,139 +367,108 @@ DESCRIPTION
.#define bfd_h_get_signed_64(abfd, ptr) \
. BFD_SEND (abfd, bfd_h_getx_signed_64, (ptr))
.
-.{* Refinements on the above, which should eventually go away. Save
-. cluttering the source with (bfd_vma) and (bfd_byte *) casts. *}
-.
-.#define H_PUT_64(abfd, val, where) \
-. bfd_h_put_64 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-.
-.#define H_PUT_32(abfd, val, where) \
-. bfd_h_put_32 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-.
-.#define H_PUT_16(abfd, val, where) \
-. bfd_h_put_16 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-.
-.#define H_PUT_8 bfd_h_put_8
-.
-.#define H_PUT_S64(abfd, val, where) \
-. bfd_h_put_signed_64 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
+.{* Aliases for the above, which should eventually go away. *}
.
-.#define H_PUT_S32(abfd, val, where) \
-. bfd_h_put_signed_32 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-.
-.#define H_PUT_S16(abfd, val, where) \
-. bfd_h_put_signed_16 ((abfd), (bfd_vma) (val), (bfd_byte *) (where))
-.
-.#define H_PUT_S8 bfd_h_put_signed_8
-.
-.#define H_GET_64(abfd, where) \
-. bfd_h_get_64 ((abfd), (bfd_byte *) (where))
-.
-.#define H_GET_32(abfd, where) \
-. bfd_h_get_32 ((abfd), (bfd_byte *) (where))
-.
-.#define H_GET_16(abfd, where) \
-. bfd_h_get_16 ((abfd), (bfd_byte *) (where))
-.
-.#define H_GET_8 bfd_h_get_8
-.
-.#define H_GET_S64(abfd, where) \
-. bfd_h_get_signed_64 ((abfd), (bfd_byte *) (where))
-.
-.#define H_GET_S32(abfd, where) \
-. bfd_h_get_signed_32 ((abfd), (bfd_byte *) (where))
-.
-.#define H_GET_S16(abfd, where) \
-. bfd_h_get_signed_16 ((abfd), (bfd_byte *) (where))
-.
-.#define H_GET_S8 bfd_h_get_signed_8
+.#define H_PUT_64 bfd_h_put_64
+.#define H_PUT_32 bfd_h_put_32
+.#define H_PUT_16 bfd_h_put_16
+.#define H_PUT_8 bfd_h_put_8
+.#define H_PUT_S64 bfd_h_put_signed_64
+.#define H_PUT_S32 bfd_h_put_signed_32
+.#define H_PUT_S16 bfd_h_put_signed_16
+.#define H_PUT_S8 bfd_h_put_signed_8
+.#define H_GET_64 bfd_h_get_64
+.#define H_GET_32 bfd_h_get_32
+.#define H_GET_16 bfd_h_get_16
+.#define H_GET_8 bfd_h_get_8
+.#define H_GET_S64 bfd_h_get_signed_64
+.#define H_GET_S32 bfd_h_get_signed_32
+.#define H_GET_S16 bfd_h_get_signed_16
+.#define H_GET_S8 bfd_h_get_signed_8
.
.*/
/* Sign extension to bfd_signed_vma. */
#define COERCE16(x) (((bfd_signed_vma) (x) ^ 0x8000) - 0x8000)
-#define COERCE32(x) \
- ((bfd_signed_vma) (long) (((unsigned long) (x) ^ 0x80000000) - 0x80000000))
-#define EIGHT_GAZILLION (((BFD_HOST_64_BIT)0x80000000) << 32)
+#define COERCE32(x) (((bfd_signed_vma) (x) ^ 0x80000000) - 0x80000000)
+#define EIGHT_GAZILLION ((bfd_int64_t) 1 << 63)
#define COERCE64(x) \
- (((bfd_signed_vma) (x) ^ EIGHT_GAZILLION) - EIGHT_GAZILLION)
+ (((bfd_int64_t) (x) ^ EIGHT_GAZILLION) - EIGHT_GAZILLION)
bfd_vma
-bfd_getb16 (addr)
- register const bfd_byte *addr;
+bfd_getb16 (const void *p)
{
+ const bfd_byte *addr = p;
return (addr[0] << 8) | addr[1];
}
bfd_vma
-bfd_getl16 (addr)
- register const bfd_byte *addr;
+bfd_getl16 (const void *p)
{
+ const bfd_byte *addr = p;
return (addr[1] << 8) | addr[0];
}
bfd_signed_vma
-bfd_getb_signed_16 (addr)
- register const bfd_byte *addr;
+bfd_getb_signed_16 (const void *p)
{
- return COERCE16((addr[0] << 8) | addr[1]);
+ const bfd_byte *addr = p;
+ return COERCE16 ((addr[0] << 8) | addr[1]);
}
bfd_signed_vma
-bfd_getl_signed_16 (addr)
- register const bfd_byte *addr;
+bfd_getl_signed_16 (const void *p)
{
- return COERCE16((addr[1] << 8) | addr[0]);
+ const bfd_byte *addr = p;
+ return COERCE16 ((addr[1] << 8) | addr[0]);
}
void
-bfd_putb16 (data, addr)
- bfd_vma data;
- register bfd_byte *addr;
+bfd_putb16 (bfd_vma data, void *p)
{
- addr[0] = (bfd_byte) (data >> 8);
- addr[1] = (bfd_byte) data;
+ bfd_byte *addr = p;
+ addr[0] = (data >> 8) & 0xff;
+ addr[1] = data & 0xff;
}
void
-bfd_putl16 (data, addr)
- bfd_vma data;
- register bfd_byte *addr;
+bfd_putl16 (bfd_vma data, void *p)
{
- addr[0] = (bfd_byte) data;
- addr[1] = (bfd_byte) (data >> 8);
+ bfd_byte *addr = p;
+ addr[0] = data & 0xff;
+ addr[1] = (data >> 8) & 0xff;
}
bfd_vma
-bfd_getb32 (addr)
- register const bfd_byte *addr;
+bfd_getb32 (const void *p)
{
+ const bfd_byte *addr = p;
unsigned long v;
v = (unsigned long) addr[0] << 24;
v |= (unsigned long) addr[1] << 16;
v |= (unsigned long) addr[2] << 8;
v |= (unsigned long) addr[3];
- return (bfd_vma) v;
+ return v;
}
bfd_vma
-bfd_getl32 (addr)
- register const bfd_byte *addr;
+bfd_getl32 (const void *p)
{
+ const bfd_byte *addr = p;
unsigned long v;
v = (unsigned long) addr[0];
v |= (unsigned long) addr[1] << 8;
v |= (unsigned long) addr[2] << 16;
v |= (unsigned long) addr[3] << 24;
- return (bfd_vma) v;
+ return v;
}
bfd_signed_vma
-bfd_getb_signed_32 (addr)
- register const bfd_byte *addr;
+bfd_getb_signed_32 (const void *p)
{
+ const bfd_byte *addr = p;
unsigned long v;
v = (unsigned long) addr[0] << 24;
@@ -1075,9 +479,9 @@ bfd_getb_signed_32 (addr)
}
bfd_signed_vma
-bfd_getl_signed_32 (addr)
- register const bfd_byte *addr;
+bfd_getl_signed_32 (const void *p)
{
+ const bfd_byte *addr = p;
unsigned long v;
v = (unsigned long) addr[0];
@@ -1087,47 +491,46 @@ bfd_getl_signed_32 (addr)
return COERCE32 (v);
}
-bfd_vma
-bfd_getb64 (addr)
- register const bfd_byte *addr ATTRIBUTE_UNUSED;
+bfd_uint64_t
+bfd_getb64 (const void *p ATTRIBUTE_UNUSED)
{
-#ifdef BFD64
- bfd_vma low, high;
-
- high= ((((((((addr[0]) << 8) |
- addr[1]) << 8) |
- addr[2]) << 8) |
- addr[3]) );
+#ifdef BFD_HOST_64_BIT
+ const bfd_byte *addr = p;
+ bfd_uint64_t v;
- low = (((((((((bfd_vma)addr[4]) << 8) |
- addr[5]) << 8) |
- addr[6]) << 8) |
- addr[7]));
+ v = addr[0]; v <<= 8;
+ v |= addr[1]; v <<= 8;
+ v |= addr[2]; v <<= 8;
+ v |= addr[3]; v <<= 8;
+ v |= addr[4]; v <<= 8;
+ v |= addr[5]; v <<= 8;
+ v |= addr[6]; v <<= 8;
+ v |= addr[7];
- return high << 32 | low;
+ return v;
#else
BFD_FAIL();
return 0;
#endif
}
-bfd_vma
-bfd_getl64 (addr)
- register const bfd_byte *addr ATTRIBUTE_UNUSED;
+bfd_uint64_t
+bfd_getl64 (const void *p ATTRIBUTE_UNUSED)
{
-#ifdef BFD64
- bfd_vma low, high;
- high= (((((((addr[7] << 8) |
- addr[6]) << 8) |
- addr[5]) << 8) |
- addr[4]));
-
- low = ((((((((bfd_vma)addr[3] << 8) |
- addr[2]) << 8) |
- addr[1]) << 8) |
- addr[0]) );
-
- return high << 32 | low;
+#ifdef BFD_HOST_64_BIT
+ const bfd_byte *addr = p;
+ bfd_uint64_t v;
+
+ v = addr[7]; v <<= 8;
+ v |= addr[6]; v <<= 8;
+ v |= addr[5]; v <<= 8;
+ v |= addr[4]; v <<= 8;
+ v |= addr[3]; v <<= 8;
+ v |= addr[2]; v <<= 8;
+ v |= addr[1]; v <<= 8;
+ v |= addr[0];
+
+ return v;
#else
BFD_FAIL();
return 0;
@@ -1135,47 +538,46 @@ bfd_getl64 (addr)
}
-bfd_signed_vma
-bfd_getb_signed_64 (addr)
- register const bfd_byte *addr ATTRIBUTE_UNUSED;
+bfd_int64_t
+bfd_getb_signed_64 (const void *p ATTRIBUTE_UNUSED)
{
-#ifdef BFD64
- bfd_vma low, high;
-
- high= ((((((((addr[0]) << 8) |
- addr[1]) << 8) |
- addr[2]) << 8) |
- addr[3]) );
+#ifdef BFD_HOST_64_BIT
+ const bfd_byte *addr = p;
+ bfd_uint64_t v;
- low = (((((((((bfd_vma)addr[4]) << 8) |
- addr[5]) << 8) |
- addr[6]) << 8) |
- addr[7]));
+ v = addr[0]; v <<= 8;
+ v |= addr[1]; v <<= 8;
+ v |= addr[2]; v <<= 8;
+ v |= addr[3]; v <<= 8;
+ v |= addr[4]; v <<= 8;
+ v |= addr[5]; v <<= 8;
+ v |= addr[6]; v <<= 8;
+ v |= addr[7];
- return COERCE64(high << 32 | low);
+ return COERCE64 (v);
#else
BFD_FAIL();
return 0;
#endif
}
-bfd_signed_vma
-bfd_getl_signed_64 (addr)
- register const bfd_byte *addr ATTRIBUTE_UNUSED;
+bfd_int64_t
+bfd_getl_signed_64 (const void *p ATTRIBUTE_UNUSED)
{
-#ifdef BFD64
- bfd_vma low, high;
- high= (((((((addr[7] << 8) |
- addr[6]) << 8) |
- addr[5]) << 8) |
- addr[4]));
-
- low = ((((((((bfd_vma)addr[3] << 8) |
- addr[2]) << 8) |
- addr[1]) << 8) |
- addr[0]) );
-
- return COERCE64(high << 32 | low);
+#ifdef BFD_HOST_64_BIT
+ const bfd_byte *addr = p;
+ bfd_uint64_t v;
+
+ v = addr[7]; v <<= 8;
+ v |= addr[6]; v <<= 8;
+ v |= addr[5]; v <<= 8;
+ v |= addr[4]; v <<= 8;
+ v |= addr[3]; v <<= 8;
+ v |= addr[2]; v <<= 8;
+ v |= addr[1]; v <<= 8;
+ v |= addr[0];
+
+ return COERCE64 (v);
#else
BFD_FAIL();
return 0;
@@ -1183,72 +585,65 @@ bfd_getl_signed_64 (addr)
}
void
-bfd_putb32 (data, addr)
- bfd_vma data;
- register bfd_byte *addr;
+bfd_putb32 (bfd_vma data, void *p)
{
- addr[0] = (bfd_byte) (data >> 24);
- addr[1] = (bfd_byte) (data >> 16);
- addr[2] = (bfd_byte) (data >> 8);
- addr[3] = (bfd_byte) data;
+ bfd_byte *addr = p;
+ addr[0] = (data >> 24) & 0xff;
+ addr[1] = (data >> 16) & 0xff;
+ addr[2] = (data >> 8) & 0xff;
+ addr[3] = data & 0xff;
}
void
-bfd_putl32 (data, addr)
- bfd_vma data;
- register bfd_byte *addr;
+bfd_putl32 (bfd_vma data, void *p)
{
- addr[0] = (bfd_byte) data;
- addr[1] = (bfd_byte) (data >> 8);
- addr[2] = (bfd_byte) (data >> 16);
- addr[3] = (bfd_byte) (data >> 24);
+ bfd_byte *addr = p;
+ addr[0] = data & 0xff;
+ addr[1] = (data >> 8) & 0xff;
+ addr[2] = (data >> 16) & 0xff;
+ addr[3] = (data >> 24) & 0xff;
}
void
-bfd_putb64 (data, addr)
- bfd_vma data ATTRIBUTE_UNUSED;
- register bfd_byte *addr ATTRIBUTE_UNUSED;
-{
-#ifdef BFD64
- addr[0] = (bfd_byte) (data >> (7*8));
- addr[1] = (bfd_byte) (data >> (6*8));
- addr[2] = (bfd_byte) (data >> (5*8));
- addr[3] = (bfd_byte) (data >> (4*8));
- addr[4] = (bfd_byte) (data >> (3*8));
- addr[5] = (bfd_byte) (data >> (2*8));
- addr[6] = (bfd_byte) (data >> (1*8));
- addr[7] = (bfd_byte) (data >> (0*8));
+bfd_putb64 (bfd_uint64_t data ATTRIBUTE_UNUSED, void *p ATTRIBUTE_UNUSED)
+{
+#ifdef BFD_HOST_64_BIT
+ bfd_byte *addr = p;
+ addr[0] = (data >> (7*8)) & 0xff;
+ addr[1] = (data >> (6*8)) & 0xff;
+ addr[2] = (data >> (5*8)) & 0xff;
+ addr[3] = (data >> (4*8)) & 0xff;
+ addr[4] = (data >> (3*8)) & 0xff;
+ addr[5] = (data >> (2*8)) & 0xff;
+ addr[6] = (data >> (1*8)) & 0xff;
+ addr[7] = (data >> (0*8)) & 0xff;
#else
BFD_FAIL();
#endif
}
void
-bfd_putl64 (data, addr)
- bfd_vma data ATTRIBUTE_UNUSED;
- register bfd_byte *addr ATTRIBUTE_UNUSED;
-{
-#ifdef BFD64
- addr[7] = (bfd_byte) (data >> (7*8));
- addr[6] = (bfd_byte) (data >> (6*8));
- addr[5] = (bfd_byte) (data >> (5*8));
- addr[4] = (bfd_byte) (data >> (4*8));
- addr[3] = (bfd_byte) (data >> (3*8));
- addr[2] = (bfd_byte) (data >> (2*8));
- addr[1] = (bfd_byte) (data >> (1*8));
- addr[0] = (bfd_byte) (data >> (0*8));
+bfd_putl64 (bfd_uint64_t data ATTRIBUTE_UNUSED, void *p ATTRIBUTE_UNUSED)
+{
+#ifdef BFD_HOST_64_BIT
+ bfd_byte *addr = p;
+ addr[7] = (data >> (7*8)) & 0xff;
+ addr[6] = (data >> (6*8)) & 0xff;
+ addr[5] = (data >> (5*8)) & 0xff;
+ addr[4] = (data >> (4*8)) & 0xff;
+ addr[3] = (data >> (3*8)) & 0xff;
+ addr[2] = (data >> (2*8)) & 0xff;
+ addr[1] = (data >> (1*8)) & 0xff;
+ addr[0] = (data >> (0*8)) & 0xff;
#else
BFD_FAIL();
#endif
}
void
-bfd_put_bits (data, addr, bits, big_p)
- bfd_vma data;
- bfd_byte *addr;
- int bits;
- boolean big_p;
+bfd_put_bits (bfd_uint64_t data, void *p, int bits, bfd_boolean big_p)
{
+ bfd_byte *addr = p;
int i;
int bytes;
@@ -1260,18 +655,16 @@ bfd_put_bits (data, addr, bits, big_p)
{
int index = big_p ? bytes - i - 1 : i;
- addr[index] = (bfd_byte) data;
+ addr[index] = data & 0xff;
data >>= 8;
}
}
-bfd_vma
-bfd_get_bits (addr, bits, big_p)
- bfd_byte *addr;
- int bits;
- boolean big_p;
+bfd_uint64_t
+bfd_get_bits (const void *p, int bits, bfd_boolean big_p)
{
- bfd_vma data;
+ const bfd_byte *addr = p;
+ bfd_uint64_t data;
int i;
int bytes;
@@ -1292,42 +685,42 @@ bfd_get_bits (addr, bits, big_p)
/* Default implementation */
-boolean
-_bfd_generic_get_section_contents (abfd, section, location, offset, count)
- bfd *abfd;
- sec_ptr section;
- PTR location;
- file_ptr offset;
- bfd_size_type count;
+bfd_boolean
+_bfd_generic_get_section_contents (bfd *abfd,
+ sec_ptr section,
+ void *location,
+ file_ptr offset,
+ bfd_size_type count)
{
if (count == 0)
- return true;
+ return TRUE;
if (offset + count > section->_raw_size)
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
if (bfd_seek (abfd, section->filepos + offset, SEEK_SET) != 0
|| bfd_bread (location, count, abfd) != count)
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
-boolean
-_bfd_generic_get_section_contents_in_window (abfd, section, w, offset, count)
- bfd *abfd ATTRIBUTE_UNUSED;
- sec_ptr section ATTRIBUTE_UNUSED;
- bfd_window *w ATTRIBUTE_UNUSED;
- file_ptr offset ATTRIBUTE_UNUSED;
- bfd_size_type count ATTRIBUTE_UNUSED;
+bfd_boolean
+_bfd_generic_get_section_contents_in_window
+ (bfd *abfd ATTRIBUTE_UNUSED,
+ sec_ptr section ATTRIBUTE_UNUSED,
+ bfd_window *w ATTRIBUTE_UNUSED,
+ file_ptr offset ATTRIBUTE_UNUSED,
+ bfd_size_type count ATTRIBUTE_UNUSED)
{
#ifdef USE_MMAP
if (count == 0)
- return true;
- if (abfd->xvec->_bfd_get_section_contents != _bfd_generic_get_section_contents)
+ return TRUE;
+ if (abfd->xvec->_bfd_get_section_contents
+ != _bfd_generic_get_section_contents)
{
/* We don't know what changes the bfd's get_section_contents
method may have to make. So punt trying to map the file
@@ -1335,16 +728,15 @@ _bfd_generic_get_section_contents_in_window (abfd, section, w, offset, count)
/* @@ FIXME : If the internal window has a refcount of 1 and was
allocated with malloc instead of mmap, just reuse it. */
bfd_free_window (w);
- w->i = ((bfd_window_internal *)
- bfd_zmalloc ((bfd_size_type) sizeof (bfd_window_internal)));
+ w->i = bfd_zmalloc (sizeof (bfd_window_internal));
if (w->i == NULL)
- return false;
- w->i->data = (PTR) bfd_malloc (count);
+ return FALSE;
+ w->i->data = bfd_malloc (count);
if (w->i->data == NULL)
{
free (w->i);
w->i = NULL;
- return false;
+ return FALSE;
}
w->i->mapped = 0;
w->i->refcount = 1;
@@ -1354,9 +746,9 @@ _bfd_generic_get_section_contents_in_window (abfd, section, w, offset, count)
}
if (offset + count > section->_raw_size
|| ! bfd_get_file_window (abfd, section->filepos + offset, count, w,
- true))
- return false;
- return true;
+ TRUE))
+ return FALSE;
+ return TRUE;
#else
abort ();
#endif
@@ -1366,22 +758,21 @@ _bfd_generic_get_section_contents_in_window (abfd, section, w, offset, count)
NEW sections is disallowed. It is useful in patching existing sections
in read-write files, though. See other set_section_contents functions
to see why it doesn't work for new sections. */
-boolean
-_bfd_generic_set_section_contents (abfd, section, location, offset, count)
- bfd *abfd;
- sec_ptr section;
- PTR location;
- file_ptr offset;
- bfd_size_type count;
+bfd_boolean
+_bfd_generic_set_section_contents (bfd *abfd,
+ sec_ptr section,
+ const void *location,
+ file_ptr offset,
+ bfd_size_type count)
{
if (count == 0)
- return true;
+ return TRUE;
if (bfd_seek (abfd, section->filepos + offset, SEEK_SET) != 0
|| bfd_bwrite (location, count, abfd) != count)
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
/*
@@ -1397,8 +788,7 @@ DESCRIPTION
*/
unsigned int
-bfd_log2 (x)
- bfd_vma x;
+bfd_log2 (bfd_vma x)
{
unsigned int result = 0;
@@ -1407,23 +797,19 @@ bfd_log2 (x)
return result;
}
-boolean
-bfd_generic_is_local_label_name (abfd, name)
- bfd *abfd;
- const char *name;
+bfd_boolean
+bfd_generic_is_local_label_name (bfd *abfd, const char *name)
{
char locals_prefix = (bfd_get_symbol_leading_char (abfd) == '_') ? 'L' : '.';
- return (boolean) (name[0] == locals_prefix);
+ return name[0] == locals_prefix;
}
/* Can be used from / for bfd_merge_private_bfd_data to check that
endianness matches between input and output file. Returns
- true for a match, otherwise returns false and emits an error. */
-boolean
-_bfd_generic_verify_endian_match (ibfd, obfd)
- bfd *ibfd;
- bfd *obfd;
+ TRUE for a match, otherwise returns FALSE and emits an error. */
+bfd_boolean
+_bfd_generic_verify_endian_match (bfd *ibfd, bfd *obfd)
{
if (ibfd->xvec->byteorder != obfd->xvec->byteorder
&& ibfd->xvec->byteorder != BFD_ENDIAN_UNKNOWN
@@ -1439,28 +825,27 @@ _bfd_generic_verify_endian_match (ibfd, obfd)
(*_bfd_error_handler) (msg, bfd_archive_filename (ibfd));
bfd_set_error (bfd_error_wrong_format);
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Give a warning at runtime if someone compiles code which calls
old routines. */
void
-warn_deprecated (what, file, line, func)
- const char *what;
- const char *file;
- int line;
- const char *func;
+warn_deprecated (const char *what,
+ const char *file,
+ int line,
+ const char *func)
{
/* Poor man's tracking of functions we've already warned about. */
static size_t mask = 0;
if (~(size_t) func & ~mask)
{
- /* Note: seperate sentances in order to allow
+ /* Note: separate sentences in order to allow
for translation into other languages. */
if (func)
fprintf (stderr, _("Deprecated %s called at %s line %d in %s\n"),
diff --git a/contrib/binutils/bfd/libbfd.h b/contrib/binutils/bfd/libbfd.h
index 3480114..62043f3 100644
--- a/contrib/binutils/bfd/libbfd.h
+++ b/contrib/binutils/bfd/libbfd.h
@@ -1,13 +1,14 @@
/* DO NOT EDIT! -*- buffer-read-only: t -*- This file is automatically
- generated from "libbfd-in.h", "init.c", "libbfd.c", "cache.c",
- "reloc.c", "archures.c" and "elf.c".
+ generated from "libbfd-in.h", "init.c", "libbfd.c", "bfdio.c",
+ "bfdwin.c", "cache.c", "reloc.c", "archures.c" and "elf.c".
Run "make headers" in your build bfd/ to regenerate. */
/* libbfd.h -- Declarations used by bfd library *implementation*.
(This include file is not for users of the library.)
- Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
- Free Software Foundation, Inc.
+
+ Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
+ 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
+
Written by Cygnus Support.
This file is part of BFD, the Binary File Descriptor library.
@@ -41,7 +42,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* Set a tdata field. Can't use the other macros for this, since they
do casts, and casting to the left of assignment isn't portable. */
-#define set_tdata(bfd, v) ((bfd)->tdata.any = (PTR) (v))
+#define set_tdata(bfd, v) ((bfd)->tdata.any = (v))
/* If BFD_IN_MEMORY is set for a BFD, then the iostream fields points
to an instance of this structure. */
@@ -74,7 +75,7 @@ struct artdata {
archive. */
file_ptr armap_datepos; /* Position within archive to seek to
rewrite the date field. */
- PTR tdata; /* Backend specific information. */
+ void *tdata; /* Backend specific information. */
};
#define bfd_ardata(bfd) ((bfd)->tdata.aout_ar_data)
@@ -88,70 +89,105 @@ struct areltdata {
#define arelt_size(bfd) (((struct areltdata *)((bfd)->arelt_data))->parsed_size)
-extern PTR bfd_malloc PARAMS ((bfd_size_type));
-extern PTR bfd_realloc PARAMS ((PTR, bfd_size_type));
-extern PTR bfd_zmalloc PARAMS ((bfd_size_type));
+extern void *bfd_malloc
+ (bfd_size_type);
+extern void *bfd_realloc
+ (void *, bfd_size_type);
+extern void *bfd_zmalloc
+ (bfd_size_type);
extern bfd_error_handler_type _bfd_error_handler;
/* These routines allocate and free things on the BFD's objalloc. */
-extern PTR bfd_alloc PARAMS ((bfd *, bfd_size_type));
-extern PTR bfd_zalloc PARAMS ((bfd *, bfd_size_type));
-extern void bfd_release PARAMS ((bfd *, PTR));
-
-bfd * _bfd_create_empty_archive_element_shell PARAMS ((bfd *obfd));
-bfd * _bfd_look_for_bfd_in_cache PARAMS ((bfd *, file_ptr));
-boolean _bfd_add_bfd_to_archive_cache PARAMS ((bfd *, file_ptr, bfd *));
-boolean _bfd_generic_mkarchive PARAMS ((bfd *abfd));
-const bfd_target *bfd_generic_archive_p PARAMS ((bfd *abfd));
-boolean bfd_slurp_armap PARAMS ((bfd *abfd));
-boolean bfd_slurp_bsd_armap_f2 PARAMS ((bfd *abfd));
+extern void *bfd_alloc
+ (bfd *, bfd_size_type);
+extern void *bfd_zalloc
+ (bfd *, bfd_size_type);
+extern void bfd_release
+ (bfd *, void *);
+
+bfd * _bfd_create_empty_archive_element_shell
+ (bfd *obfd);
+bfd * _bfd_look_for_bfd_in_cache
+ (bfd *, file_ptr);
+bfd_boolean _bfd_add_bfd_to_archive_cache
+ (bfd *, file_ptr, bfd *);
+bfd_boolean _bfd_generic_mkarchive
+ (bfd *abfd);
+const bfd_target *bfd_generic_archive_p
+ (bfd *abfd);
+bfd_boolean bfd_slurp_armap
+ (bfd *abfd);
+bfd_boolean bfd_slurp_bsd_armap_f2
+ (bfd *abfd);
#define bfd_slurp_bsd_armap bfd_slurp_armap
#define bfd_slurp_coff_armap bfd_slurp_armap
-boolean _bfd_slurp_extended_name_table PARAMS ((bfd *abfd));
-extern boolean _bfd_construct_extended_name_table
- PARAMS ((bfd *, boolean, char **, bfd_size_type *));
-boolean _bfd_write_archive_contents PARAMS ((bfd *abfd));
-boolean _bfd_compute_and_write_armap PARAMS ((bfd *, unsigned int elength));
-bfd *_bfd_get_elt_at_filepos PARAMS ((bfd *archive, file_ptr filepos));
-extern bfd *_bfd_generic_get_elt_at_index PARAMS ((bfd *, symindex));
-bfd * _bfd_new_bfd PARAMS ((void));
-void _bfd_delete_bfd PARAMS ((bfd *));
-
-boolean bfd_false PARAMS ((bfd *ignore));
-boolean bfd_true PARAMS ((bfd *ignore));
-PTR bfd_nullvoidptr PARAMS ((bfd *ignore));
-int bfd_0 PARAMS ((bfd *ignore));
-unsigned int bfd_0u PARAMS ((bfd *ignore));
-long bfd_0l PARAMS ((bfd *ignore));
-long _bfd_n1 PARAMS ((bfd *ignore));
-void bfd_void PARAMS ((bfd *ignore));
-
-bfd *_bfd_new_bfd_contained_in PARAMS ((bfd *));
-const bfd_target *_bfd_dummy_target PARAMS ((bfd *abfd));
-
-void bfd_dont_truncate_arname PARAMS ((bfd *abfd, const char *filename,
- char *hdr));
-void bfd_bsd_truncate_arname PARAMS ((bfd *abfd, const char *filename,
- char *hdr));
-void bfd_gnu_truncate_arname PARAMS ((bfd *abfd, const char *filename,
- char *hdr));
-
-boolean bsd_write_armap PARAMS ((bfd *arch, unsigned int elength,
- struct orl *map, unsigned int orl_count, int stridx));
-
-boolean coff_write_armap PARAMS ((bfd *arch, unsigned int elength,
- struct orl *map, unsigned int orl_count, int stridx));
-
-extern PTR _bfd_generic_read_ar_hdr PARAMS ((bfd *));
-
-extern PTR _bfd_generic_read_ar_hdr_mag PARAMS ((bfd *, const char *));
-
-bfd * bfd_generic_openr_next_archived_file PARAMS ((bfd *archive,
- bfd *last_file));
-
-int bfd_generic_stat_arch_elt PARAMS ((bfd *, struct stat *));
+bfd_boolean _bfd_slurp_extended_name_table
+ (bfd *abfd);
+extern bfd_boolean _bfd_construct_extended_name_table
+ (bfd *, bfd_boolean, char **, bfd_size_type *);
+bfd_boolean _bfd_write_archive_contents
+ (bfd *abfd);
+bfd_boolean _bfd_compute_and_write_armap
+ (bfd *, unsigned int elength);
+bfd *_bfd_get_elt_at_filepos
+ (bfd *archive, file_ptr filepos);
+extern bfd *_bfd_generic_get_elt_at_index
+ (bfd *, symindex);
+bfd * _bfd_new_bfd
+ (void);
+void _bfd_delete_bfd
+ (bfd *);
+
+bfd_boolean bfd_false
+ (bfd *ignore);
+bfd_boolean bfd_true
+ (bfd *ignore);
+void *bfd_nullvoidptr
+ (bfd *ignore);
+int bfd_0
+ (bfd *ignore);
+unsigned int bfd_0u
+ (bfd *ignore);
+long bfd_0l
+ (bfd *ignore);
+long _bfd_n1
+ (bfd *ignore);
+void bfd_void
+ (bfd *ignore);
+
+bfd *_bfd_new_bfd_contained_in
+ (bfd *);
+const bfd_target *_bfd_dummy_target
+ (bfd *abfd);
+
+void bfd_dont_truncate_arname
+ (bfd *abfd, const char *filename, char *hdr);
+void bfd_bsd_truncate_arname
+ (bfd *abfd, const char *filename, char *hdr);
+void bfd_gnu_truncate_arname
+ (bfd *abfd, const char *filename, char *hdr);
+
+bfd_boolean bsd_write_armap
+ (bfd *arch, unsigned int elength, struct orl *map, unsigned int orl_count,
+ int stridx);
+
+bfd_boolean coff_write_armap
+ (bfd *arch, unsigned int elength, struct orl *map, unsigned int orl_count,
+ int stridx);
+
+extern void *_bfd_generic_read_ar_hdr
+ (bfd *);
+
+extern void *_bfd_generic_read_ar_hdr_mag
+ (bfd *, const char *);
+
+bfd * bfd_generic_openr_next_archived_file
+ (bfd *archive, bfd *last_file);
+
+int bfd_generic_stat_arch_elt
+ (bfd *, struct stat *);
#define _bfd_read_ar_hdr(abfd) \
BFD_SEND (abfd, _bfd_read_ar_hdr_fn, (abfd))
@@ -162,35 +198,37 @@ int bfd_generic_stat_arch_elt PARAMS ((bfd *, struct stat *));
#define _bfd_generic_close_and_cleanup bfd_true
#define _bfd_generic_bfd_free_cached_info bfd_true
#define _bfd_generic_new_section_hook \
- ((boolean (*) PARAMS ((bfd *, asection *))) bfd_true)
-extern boolean _bfd_generic_get_section_contents
- PARAMS ((bfd *, asection *, PTR, file_ptr, bfd_size_type));
-extern boolean _bfd_generic_get_section_contents_in_window
- PARAMS ((bfd *, asection *, bfd_window *, file_ptr, bfd_size_type));
+ ((bfd_boolean (*) (bfd *, asection *)) bfd_true)
+extern bfd_boolean _bfd_generic_get_section_contents
+ (bfd *, asection *, void *, file_ptr, bfd_size_type);
+extern bfd_boolean _bfd_generic_get_section_contents_in_window
+ (bfd *, asection *, bfd_window *, file_ptr, bfd_size_type);
/* Generic routines to use for BFD_JUMP_TABLE_COPY. Use
BFD_JUMP_TABLE_COPY (_bfd_generic). */
#define _bfd_generic_bfd_copy_private_bfd_data \
- ((boolean (*) PARAMS ((bfd *, bfd *))) bfd_true)
+ ((bfd_boolean (*) (bfd *, bfd *)) bfd_true)
#define _bfd_generic_bfd_merge_private_bfd_data \
- ((boolean (*) PARAMS ((bfd *, bfd *))) bfd_true)
+ ((bfd_boolean (*) (bfd *, bfd *)) bfd_true)
#define _bfd_generic_bfd_set_private_flags \
- ((boolean (*) PARAMS ((bfd *, flagword))) bfd_true)
+ ((bfd_boolean (*) (bfd *, flagword)) bfd_true)
#define _bfd_generic_bfd_copy_private_section_data \
- ((boolean (*) PARAMS ((bfd *, asection *, bfd *, asection *))) bfd_true)
+ ((bfd_boolean (*) (bfd *, asection *, bfd *, asection *)) bfd_true)
#define _bfd_generic_bfd_copy_private_symbol_data \
- ((boolean (*) PARAMS ((bfd *, asymbol *, bfd *, asymbol *))) bfd_true)
+ ((bfd_boolean (*) (bfd *, asymbol *, bfd *, asymbol *)) bfd_true)
#define _bfd_generic_bfd_print_private_bfd_data \
- ((boolean (*) PARAMS ((bfd *, PTR))) bfd_true)
+ ((bfd_boolean (*) (bfd *, void *)) bfd_true)
/* Routines to use for BFD_JUMP_TABLE_CORE when there is no core file
support. Use BFD_JUMP_TABLE_CORE (_bfd_nocore). */
-extern char *_bfd_nocore_core_file_failing_command PARAMS ((bfd *));
-extern int _bfd_nocore_core_file_failing_signal PARAMS ((bfd *));
-extern boolean _bfd_nocore_core_file_matches_executable_p
- PARAMS ((bfd *, bfd *));
+extern char *_bfd_nocore_core_file_failing_command
+ (bfd *);
+extern int _bfd_nocore_core_file_failing_signal
+ (bfd *);
+extern bfd_boolean _bfd_nocore_core_file_matches_executable_p
+ (bfd *, bfd *);
/* Routines to use for BFD_JUMP_TABLE_ARCHIVE when there is no archive
file support. Use BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive). */
@@ -198,19 +236,18 @@ extern boolean _bfd_nocore_core_file_matches_executable_p
#define _bfd_noarchive_slurp_armap bfd_false
#define _bfd_noarchive_slurp_extended_name_table bfd_false
#define _bfd_noarchive_construct_extended_name_table \
- ((boolean (*) PARAMS ((bfd *, char **, bfd_size_type *, const char **))) \
+ ((bfd_boolean (*) (bfd *, char **, bfd_size_type *, const char **)) \
bfd_false)
#define _bfd_noarchive_truncate_arname \
- ((void (*) PARAMS ((bfd *, const char *, char *))) bfd_void)
+ ((void (*) (bfd *, const char *, char *)) bfd_void)
#define _bfd_noarchive_write_armap \
- ((boolean (*) \
- PARAMS ((bfd *, unsigned int, struct orl *, unsigned int, int))) \
+ ((bfd_boolean (*) (bfd *, unsigned int, struct orl *, unsigned int, int)) \
bfd_false)
#define _bfd_noarchive_read_ar_hdr bfd_nullvoidptr
#define _bfd_noarchive_openr_next_archived_file \
- ((bfd *(*) PARAMS ((bfd *, bfd *))) bfd_nullvoidptr)
+ ((bfd *(*) (bfd *, bfd *)) bfd_nullvoidptr)
#define _bfd_noarchive_get_elt_at_index \
- ((bfd *(*) PARAMS ((bfd *, symindex))) bfd_nullvoidptr)
+ ((bfd *(*) (bfd *, symindex)) bfd_nullvoidptr)
#define _bfd_noarchive_generic_stat_arch_elt bfd_generic_stat_arch_elt
#define _bfd_noarchive_update_armap_timestamp bfd_false
@@ -220,8 +257,8 @@ extern boolean _bfd_nocore_core_file_matches_executable_p
#define _bfd_archive_bsd_slurp_armap bfd_slurp_bsd_armap
#define _bfd_archive_bsd_slurp_extended_name_table \
_bfd_slurp_extended_name_table
-extern boolean _bfd_archive_bsd_construct_extended_name_table
- PARAMS ((bfd *, char **, bfd_size_type *, const char **));
+extern bfd_boolean _bfd_archive_bsd_construct_extended_name_table
+ (bfd *, char **, bfd_size_type *, const char **);
#define _bfd_archive_bsd_truncate_arname bfd_bsd_truncate_arname
#define _bfd_archive_bsd_write_armap bsd_write_armap
#define _bfd_archive_bsd_read_ar_hdr _bfd_generic_read_ar_hdr
@@ -230,7 +267,8 @@ extern boolean _bfd_archive_bsd_construct_extended_name_table
#define _bfd_archive_bsd_get_elt_at_index _bfd_generic_get_elt_at_index
#define _bfd_archive_bsd_generic_stat_arch_elt \
bfd_generic_stat_arch_elt
-extern boolean _bfd_archive_bsd_update_armap_timestamp PARAMS ((bfd *));
+extern bfd_boolean _bfd_archive_bsd_update_armap_timestamp
+ (bfd *);
/* Routines to use for BFD_JUMP_TABLE_ARCHIVE to get COFF style
archives. Use BFD_JUMP_TABLE_ARCHIVE (_bfd_archive_coff). */
@@ -238,8 +276,8 @@ extern boolean _bfd_archive_bsd_update_armap_timestamp PARAMS ((bfd *));
#define _bfd_archive_coff_slurp_armap bfd_slurp_coff_armap
#define _bfd_archive_coff_slurp_extended_name_table \
_bfd_slurp_extended_name_table
-extern boolean _bfd_archive_coff_construct_extended_name_table
- PARAMS ((bfd *, char **, bfd_size_type *, const char **));
+extern bfd_boolean _bfd_archive_coff_construct_extended_name_table
+ (bfd *, char **, bfd_size_type *, const char **);
#define _bfd_archive_coff_truncate_arname bfd_dont_truncate_arname
#define _bfd_archive_coff_write_armap coff_write_armap
#define _bfd_archive_coff_read_ar_hdr _bfd_generic_read_ar_hdr
@@ -254,95 +292,89 @@ extern boolean _bfd_archive_coff_construct_extended_name_table
support. Use BFD_JUMP_TABLE_SYMBOLS (_bfd_nosymbols). */
#define _bfd_nosymbols_get_symtab_upper_bound _bfd_n1
-#define _bfd_nosymbols_get_symtab \
- ((long (*) PARAMS ((bfd *, asymbol **))) _bfd_n1)
+#define _bfd_nosymbols_canonicalize_symtab \
+ ((long (*) (bfd *, asymbol **)) _bfd_n1)
#define _bfd_nosymbols_make_empty_symbol _bfd_generic_make_empty_symbol
#define _bfd_nosymbols_print_symbol \
- ((void (*) PARAMS ((bfd *, PTR, asymbol *, bfd_print_symbol_type))) bfd_void)
+ ((void (*) (bfd *, void *, asymbol *, bfd_print_symbol_type)) bfd_void)
#define _bfd_nosymbols_get_symbol_info \
- ((void (*) PARAMS ((bfd *, asymbol *, symbol_info *))) bfd_void)
+ ((void (*) (bfd *, asymbol *, symbol_info *)) bfd_void)
#define _bfd_nosymbols_bfd_is_local_label_name \
- ((boolean (*) PARAMS ((bfd *, const char *))) bfd_false)
+ ((bfd_boolean (*) (bfd *, const char *)) bfd_false)
#define _bfd_nosymbols_get_lineno \
- ((alent *(*) PARAMS ((bfd *, asymbol *))) bfd_nullvoidptr)
+ ((alent *(*) (bfd *, asymbol *)) bfd_nullvoidptr)
#define _bfd_nosymbols_find_nearest_line \
- ((boolean (*) \
- PARAMS ((bfd *, asection *, asymbol **, bfd_vma, const char **, \
- const char **, unsigned int *))) \
+ ((bfd_boolean (*) (bfd *, asection *, asymbol **, bfd_vma, const char **, \
+ const char **, unsigned int *)) \
bfd_false)
#define _bfd_nosymbols_bfd_make_debug_symbol \
- ((asymbol *(*) PARAMS ((bfd *, PTR, unsigned long))) bfd_nullvoidptr)
+ ((asymbol *(*) (bfd *, void *, unsigned long)) bfd_nullvoidptr)
#define _bfd_nosymbols_read_minisymbols \
- ((long (*) PARAMS ((bfd *, boolean, PTR *, unsigned int *))) _bfd_n1)
+ ((long (*) (bfd *, bfd_boolean, void **, unsigned int *)) _bfd_n1)
#define _bfd_nosymbols_minisymbol_to_symbol \
- ((asymbol *(*) PARAMS ((bfd *, boolean, const PTR, asymbol *))) \
+ ((asymbol *(*) (bfd *, bfd_boolean, const void *, asymbol *)) \
bfd_nullvoidptr)
/* Routines to use for BFD_JUMP_TABLE_RELOCS when there is no reloc
support. Use BFD_JUMP_TABLE_RELOCS (_bfd_norelocs). */
#define _bfd_norelocs_get_reloc_upper_bound \
- ((long (*) PARAMS ((bfd *, asection *))) _bfd_n1)
+ ((long (*) (bfd *, asection *)) _bfd_n1)
#define _bfd_norelocs_canonicalize_reloc \
- ((long (*) PARAMS ((bfd *, asection *, arelent **, asymbol **))) _bfd_n1)
+ ((long (*) (bfd *, asection *, arelent **, asymbol **)) _bfd_n1)
#define _bfd_norelocs_bfd_reloc_type_lookup \
- ((reloc_howto_type *(*) PARAMS ((bfd *, bfd_reloc_code_real_type))) \
- bfd_nullvoidptr)
+ ((reloc_howto_type *(*) (bfd *, bfd_reloc_code_real_type)) bfd_nullvoidptr)
/* Routines to use for BFD_JUMP_TABLE_WRITE for targets which may not
be written. Use BFD_JUMP_TABLE_WRITE (_bfd_nowrite). */
#define _bfd_nowrite_set_arch_mach \
- ((boolean (*) PARAMS ((bfd *, enum bfd_architecture, unsigned long))) \
+ ((bfd_boolean (*) (bfd *, enum bfd_architecture, unsigned long)) \
bfd_false)
#define _bfd_nowrite_set_section_contents \
- ((boolean (*) PARAMS ((bfd *, asection *, PTR, file_ptr, bfd_size_type))) \
+ ((bfd_boolean (*) (bfd *, asection *, const void *, file_ptr, bfd_size_type)) \
bfd_false)
/* Generic routines to use for BFD_JUMP_TABLE_WRITE. Use
BFD_JUMP_TABLE_WRITE (_bfd_generic). */
#define _bfd_generic_set_arch_mach bfd_default_set_arch_mach
-extern boolean _bfd_generic_set_section_contents
- PARAMS ((bfd *, asection *, PTR, file_ptr, bfd_size_type));
+extern bfd_boolean _bfd_generic_set_section_contents
+ (bfd *, asection *, const void *, file_ptr, bfd_size_type);
/* Routines to use for BFD_JUMP_TABLE_LINK for targets which do not
support linking. Use BFD_JUMP_TABLE_LINK (_bfd_nolink). */
-#define _bfd_nolink_sizeof_headers ((int (*) PARAMS ((bfd *, boolean))) bfd_0)
+#define _bfd_nolink_sizeof_headers ((int (*) (bfd *, bfd_boolean)) bfd_0)
#define _bfd_nolink_bfd_get_relocated_section_contents \
- ((bfd_byte *(*) \
- PARAMS ((bfd *, struct bfd_link_info *, struct bfd_link_order *, \
- bfd_byte *, boolean, asymbol **))) \
+ ((bfd_byte *(*) (bfd *, struct bfd_link_info *, struct bfd_link_order *, \
+ bfd_byte *, bfd_boolean, asymbol **)) \
bfd_nullvoidptr)
#define _bfd_nolink_bfd_relax_section \
- ((boolean (*) \
- PARAMS ((bfd *, asection *, struct bfd_link_info *, boolean *))) \
+ ((bfd_boolean (*) \
+ (bfd *, asection *, struct bfd_link_info *, bfd_boolean *)) \
bfd_false)
#define _bfd_nolink_bfd_gc_sections \
- ((boolean (*) \
- PARAMS ((bfd *, struct bfd_link_info *))) \
+ ((bfd_boolean (*) (bfd *, struct bfd_link_info *)) \
bfd_false)
#define _bfd_nolink_bfd_merge_sections \
- ((boolean (*) \
- PARAMS ((bfd *, struct bfd_link_info *))) \
+ ((bfd_boolean (*) (bfd *, struct bfd_link_info *)) \
bfd_false)
#define _bfd_nolink_bfd_discard_group \
- ((boolean (*) \
- PARAMS ((bfd *, struct sec *))) \
+ ((bfd_boolean (*) (bfd *, struct bfd_section *)) \
bfd_false)
#define _bfd_nolink_bfd_link_hash_table_create \
- ((struct bfd_link_hash_table *(*) PARAMS ((bfd *))) bfd_nullvoidptr)
+ ((struct bfd_link_hash_table *(*) (bfd *)) bfd_nullvoidptr)
#define _bfd_nolink_bfd_link_hash_table_free \
- ((void (*) PARAMS ((struct bfd_link_hash_table *))) bfd_void)
+ ((void (*) (struct bfd_link_hash_table *)) bfd_void)
#define _bfd_nolink_bfd_link_add_symbols \
- ((boolean (*) PARAMS ((bfd *, struct bfd_link_info *))) bfd_false)
+ ((bfd_boolean (*) (bfd *, struct bfd_link_info *)) bfd_false)
#define _bfd_nolink_bfd_link_just_syms \
- ((void (*) PARAMS ((asection *, struct bfd_link_info *))) bfd_void)
+ ((void (*) (asection *, struct bfd_link_info *)) bfd_void)
#define _bfd_nolink_bfd_final_link \
- ((boolean (*) PARAMS ((bfd *, struct bfd_link_info *))) bfd_false)
+ ((bfd_boolean (*) (bfd *, struct bfd_link_info *)) bfd_false)
#define _bfd_nolink_bfd_link_split_section \
- ((boolean (*) PARAMS ((bfd *, struct sec *))) bfd_false)
+ ((bfd_boolean (*) (bfd *, struct bfd_section *)) bfd_false)
/* Routines to use for BFD_JUMP_TABLE_DYNAMIC for targets which do not
have dynamic symbols or relocs. Use BFD_JUMP_TABLE_DYNAMIC
@@ -350,187 +382,189 @@ extern boolean _bfd_generic_set_section_contents
#define _bfd_nodynamic_get_dynamic_symtab_upper_bound _bfd_n1
#define _bfd_nodynamic_canonicalize_dynamic_symtab \
- ((long (*) PARAMS ((bfd *, asymbol **))) _bfd_n1)
+ ((long (*) (bfd *, asymbol **)) _bfd_n1)
#define _bfd_nodynamic_get_dynamic_reloc_upper_bound _bfd_n1
#define _bfd_nodynamic_canonicalize_dynamic_reloc \
- ((long (*) PARAMS ((bfd *, arelent **, asymbol **))) _bfd_n1)
+ ((long (*) (bfd *, arelent **, asymbol **)) _bfd_n1)
/* Generic routine to determine of the given symbol is a local
label. */
-extern boolean bfd_generic_is_local_label_name PARAMS ((bfd *, const char *));
+extern bfd_boolean bfd_generic_is_local_label_name
+ (bfd *, const char *);
/* Generic minisymbol routines. */
extern long _bfd_generic_read_minisymbols
- PARAMS ((bfd *, boolean, PTR *, unsigned int *));
+ (bfd *, bfd_boolean, void **, unsigned int *);
extern asymbol *_bfd_generic_minisymbol_to_symbol
- PARAMS ((bfd *, boolean, const PTR, asymbol *));
+ (bfd *, bfd_boolean, const void *, asymbol *);
/* Find the nearest line using .stab/.stabstr sections. */
-extern boolean _bfd_stab_section_find_nearest_line
- PARAMS ((bfd *, asymbol **, asection *, bfd_vma, boolean *, const char **,
- const char **, unsigned int *, PTR *));
+extern bfd_boolean _bfd_stab_section_find_nearest_line
+ (bfd *, asymbol **, asection *, bfd_vma, bfd_boolean *,
+ const char **, const char **, unsigned int *, void **);
/* Find the neaderst line using DWARF 1 debugging information. */
-extern boolean _bfd_dwarf1_find_nearest_line
- PARAMS ((bfd *, asection *, asymbol **, bfd_vma, const char **,
- const char **, unsigned int *));
+extern bfd_boolean _bfd_dwarf1_find_nearest_line
+ (bfd *, asection *, asymbol **, bfd_vma, const char **,
+ const char **, unsigned int *);
/* Find the nearest line using DWARF 2 debugging information. */
-extern boolean _bfd_dwarf2_find_nearest_line
- PARAMS ((bfd *, asection *, asymbol **, bfd_vma, const char **,
- const char **, unsigned int *, unsigned int,
- PTR *));
+extern bfd_boolean _bfd_dwarf2_find_nearest_line
+ (bfd *, asection *, asymbol **, bfd_vma, const char **, const char **,
+ unsigned int *, unsigned int, void **);
/* Create a new section entry. */
extern struct bfd_hash_entry *bfd_section_hash_newfunc
- PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
+ (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
/* A routine to create entries for a bfd_link_hash_table. */
extern struct bfd_hash_entry *_bfd_link_hash_newfunc
- PARAMS ((struct bfd_hash_entry *entry,
- struct bfd_hash_table *table,
- const char *string));
+ (struct bfd_hash_entry *entry, struct bfd_hash_table *table,
+ const char *string);
/* Initialize a bfd_link_hash_table. */
-extern boolean _bfd_link_hash_table_init
- PARAMS ((struct bfd_link_hash_table *, bfd *,
- struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
- struct bfd_hash_table *,
- const char *)));
+extern bfd_boolean _bfd_link_hash_table_init
+ (struct bfd_link_hash_table *, bfd *,
+ struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
+ struct bfd_hash_table *,
+ const char *));
/* Generic link hash table creation routine. */
extern struct bfd_link_hash_table *_bfd_generic_link_hash_table_create
- PARAMS ((bfd *));
+ (bfd *);
/* Generic link hash table destruction routine. */
extern void _bfd_generic_link_hash_table_free
- PARAMS ((struct bfd_link_hash_table *));
+ (struct bfd_link_hash_table *);
/* Generic add symbol routine. */
-extern boolean _bfd_generic_link_add_symbols
- PARAMS ((bfd *, struct bfd_link_info *));
+extern bfd_boolean _bfd_generic_link_add_symbols
+ (bfd *, struct bfd_link_info *);
/* Generic add symbol routine. This version is used by targets for
which the linker must collect constructors and destructors by name,
as the collect2 program does. */
-extern boolean _bfd_generic_link_add_symbols_collect
- PARAMS ((bfd *, struct bfd_link_info *));
+extern bfd_boolean _bfd_generic_link_add_symbols_collect
+ (bfd *, struct bfd_link_info *);
/* Generic archive add symbol routine. */
-extern boolean _bfd_generic_link_add_archive_symbols
- PARAMS ((bfd *, struct bfd_link_info *,
- boolean (*checkfn) (bfd *, struct bfd_link_info *, boolean *)));
+extern bfd_boolean _bfd_generic_link_add_archive_symbols
+ (bfd *, struct bfd_link_info *,
+ bfd_boolean (*) (bfd *, struct bfd_link_info *, bfd_boolean *));
/* Forward declaration to avoid prototype errors. */
typedef struct bfd_link_hash_entry _bfd_link_hash_entry;
/* Generic routine to add a single symbol. */
-extern boolean _bfd_generic_link_add_one_symbol
- PARAMS ((struct bfd_link_info *, bfd *, const char *name, flagword,
- asection *, bfd_vma, const char *, boolean copy,
- boolean constructor, struct bfd_link_hash_entry **));
+extern bfd_boolean _bfd_generic_link_add_one_symbol
+ (struct bfd_link_info *, bfd *, const char *name, flagword,
+ asection *, bfd_vma, const char *, bfd_boolean copy,
+ bfd_boolean constructor, struct bfd_link_hash_entry **);
/* Generic routine to mark section as supplying symbols only. */
extern void _bfd_generic_link_just_syms
- PARAMS ((asection *, struct bfd_link_info *));
+ (asection *, struct bfd_link_info *);
/* Generic link routine. */
-extern boolean _bfd_generic_final_link
- PARAMS ((bfd *, struct bfd_link_info *));
+extern bfd_boolean _bfd_generic_final_link
+ (bfd *, struct bfd_link_info *);
-extern boolean _bfd_generic_link_split_section
- PARAMS ((bfd *, struct sec *));
+extern bfd_boolean _bfd_generic_link_split_section
+ (bfd *, struct bfd_section *);
/* Generic reloc_link_order processing routine. */
-extern boolean _bfd_generic_reloc_link_order
- PARAMS ((bfd *, struct bfd_link_info *, asection *,
- struct bfd_link_order *));
+extern bfd_boolean _bfd_generic_reloc_link_order
+ (bfd *, struct bfd_link_info *, asection *, struct bfd_link_order *);
/* Default link order processing routine. */
-extern boolean _bfd_default_link_order
- PARAMS ((bfd *, struct bfd_link_info *, asection *,
- struct bfd_link_order *));
+extern bfd_boolean _bfd_default_link_order
+ (bfd *, struct bfd_link_info *, asection *, struct bfd_link_order *);
/* Count the number of reloc entries in a link order list. */
extern unsigned int _bfd_count_link_order_relocs
- PARAMS ((struct bfd_link_order *));
+ (struct bfd_link_order *);
/* Final link relocation routine. */
extern bfd_reloc_status_type _bfd_final_link_relocate
- PARAMS ((reloc_howto_type *, bfd *, asection *, bfd_byte *,
- bfd_vma, bfd_vma, bfd_vma));
+ (reloc_howto_type *, bfd *, asection *, bfd_byte *,
+ bfd_vma, bfd_vma, bfd_vma);
/* Relocate a particular location by a howto and a value. */
extern bfd_reloc_status_type _bfd_relocate_contents
- PARAMS ((reloc_howto_type *, bfd *, bfd_vma, bfd_byte *));
+ (reloc_howto_type *, bfd *, bfd_vma, bfd_byte *);
/* Link stabs in sections in the first pass. */
-extern boolean _bfd_link_section_stabs
- PARAMS ((bfd *, PTR *, asection *, asection *, PTR *));
+extern bfd_boolean _bfd_link_section_stabs
+ (bfd *, void **, asection *, asection *, void **, bfd_size_type *);
/* Eliminate stabs for discarded functions and symbols. */
-extern boolean _bfd_discard_section_stabs
- PARAMS ((bfd *, asection *, PTR,
- boolean (*) (bfd_vma, PTR), PTR));
+extern bfd_boolean _bfd_discard_section_stabs
+ (bfd *, asection *, void *, bfd_boolean (*) (bfd_vma, void *), void *);
/* Write out the .stab section when linking stabs in sections. */
-extern boolean _bfd_write_section_stabs
- PARAMS ((bfd *, PTR *, asection *, PTR *, bfd_byte *));
+extern bfd_boolean _bfd_write_section_stabs
+ (bfd *, void **, asection *, void **, bfd_byte *);
/* Write out the .stabstr string table when linking stabs in sections. */
-extern boolean _bfd_write_stab_strings PARAMS ((bfd *, PTR *));
+extern bfd_boolean _bfd_write_stab_strings
+ (bfd *, void **);
/* Find an offset within a .stab section when linking stabs in
sections. */
extern bfd_vma _bfd_stab_section_offset
- PARAMS ((bfd *, PTR *, asection *, PTR *, bfd_vma));
+ (bfd *, void **, asection *, void **, bfd_vma);
/* Attempt to merge a SEC_MERGE section. */
-extern boolean _bfd_merge_section
- PARAMS ((bfd *, PTR *, asection *, PTR *));
+extern bfd_boolean _bfd_merge_section
+ (bfd *, void **, asection *, void **);
/* Attempt to merge SEC_MERGE sections. */
-extern boolean _bfd_merge_sections
- PARAMS ((bfd *, PTR, void (*)(bfd *, asection *)));
+extern bfd_boolean _bfd_merge_sections
+ (bfd *, void *, void (*) (bfd *, asection *));
/* Write out a merged section. */
-extern boolean _bfd_write_merged_section
- PARAMS ((bfd *, asection *, PTR));
+extern bfd_boolean _bfd_write_merged_section
+ (bfd *, asection *, void *);
/* Find an offset within a modified SEC_MERGE section. */
extern bfd_vma _bfd_merged_section_offset
- PARAMS ((bfd *, asection **, PTR, bfd_vma, bfd_vma));
+ (bfd *, asection **, void *, bfd_vma, bfd_vma);
/* Create a string table. */
-extern struct bfd_strtab_hash *_bfd_stringtab_init PARAMS ((void));
+extern struct bfd_strtab_hash *_bfd_stringtab_init
+ (void);
/* Create an XCOFF .debug section style string table. */
-extern struct bfd_strtab_hash *_bfd_xcoff_stringtab_init PARAMS ((void));
+extern struct bfd_strtab_hash *_bfd_xcoff_stringtab_init
+ (void);
/* Free a string table. */
-extern void _bfd_stringtab_free PARAMS ((struct bfd_strtab_hash *));
+extern void _bfd_stringtab_free
+ (struct bfd_strtab_hash *);
/* Get the size of a string table. */
-extern bfd_size_type _bfd_stringtab_size PARAMS ((struct bfd_strtab_hash *));
+extern bfd_size_type _bfd_stringtab_size
+ (struct bfd_strtab_hash *);
/* Add a string to a string table. */
extern bfd_size_type _bfd_stringtab_add
- PARAMS ((struct bfd_strtab_hash *, const char *, boolean hash,
- boolean copy));
+ (struct bfd_strtab_hash *, const char *, bfd_boolean hash, bfd_boolean copy);
/* Write out a string table. */
-extern boolean _bfd_stringtab_emit PARAMS ((bfd *, struct bfd_strtab_hash *));
+extern bfd_boolean _bfd_stringtab_emit
+ (bfd *, struct bfd_strtab_hash *);
/* Check that endianness of input and output file match. */
-extern boolean _bfd_generic_verify_endian_match PARAMS ((bfd *, bfd *));
+extern bfd_boolean _bfd_generic_verify_endian_match
+ (bfd *, bfd *);
/* Macros to tell if bfds are read or write enabled.
@@ -541,19 +575,22 @@ extern boolean _bfd_generic_verify_endian_match PARAMS ((bfd *, bfd *));
!bfd_read_p, and only sometimes bfd_write_p.
*/
-#define bfd_read_p(abfd) ((abfd)->direction == read_direction || (abfd)->direction == both_direction)
-#define bfd_write_p(abfd) ((abfd)->direction == write_direction || (abfd)->direction == both_direction)
+#define bfd_read_p(abfd) \
+ ((abfd)->direction == read_direction || (abfd)->direction == both_direction)
+#define bfd_write_p(abfd) \
+ ((abfd)->direction == write_direction || (abfd)->direction == both_direction)
-void bfd_assert PARAMS ((const char*,int));
+void bfd_assert
+ (const char*,int);
#define BFD_ASSERT(x) \
-{ if (!(x)) bfd_assert(__FILE__,__LINE__); }
+ { if (!(x)) bfd_assert(__FILE__,__LINE__); }
#define BFD_FAIL() \
-{ bfd_assert(__FILE__,__LINE__); }
+ { bfd_assert(__FILE__,__LINE__); }
-extern void _bfd_abort PARAMS ((const char *, int, const char *))
- ATTRIBUTE_NORETURN;
+extern void _bfd_abort
+ (const char *, int, const char *) ATTRIBUTE_NORETURN;
/* if gcc >= 2.6, we can give a function name, too */
#if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 6)
@@ -563,7 +600,13 @@ extern void _bfd_abort PARAMS ((const char *, int, const char *))
#undef abort
#define abort() _bfd_abort (__FILE__, __LINE__, __PRETTY_FUNCTION__)
-FILE * bfd_cache_lookup_worker PARAMS ((bfd *));
+/* Manipulate a system FILE but using BFD's "file_ptr", rather than
+ the system "off_t" or "off64_t", as the offset. */
+extern file_ptr real_ftell (FILE *file);
+extern int real_fseek (FILE *file, file_ptr offset, int whence);
+
+FILE * bfd_cache_lookup_worker
+ (bfd *);
extern bfd *bfd_last_cache;
@@ -572,6 +615,9 @@ extern bfd *bfd_last_cache;
extern const bfd_target * const *bfd_target_vector;
extern const bfd_target *bfd_default_vector[];
+/* List of associated target vectors. */
+extern const bfd_target * const *bfd_associated_vector;
+
/* Functions shared by the ECOFF and MIPS ELF backends, which have no
other common header files. */
@@ -579,33 +625,46 @@ extern const bfd_target *bfd_default_vector[];
struct ecoff_find_line;
#endif
-extern boolean _bfd_ecoff_locate_line
- PARAMS ((bfd *, asection *, bfd_vma, struct ecoff_debug_info * const,
- const struct ecoff_debug_swap * const, struct ecoff_find_line *,
- const char **, const char **, unsigned int *));
-extern boolean _bfd_ecoff_get_accumulated_pdr PARAMS ((PTR, bfd_byte *));
-extern boolean _bfd_ecoff_get_accumulated_sym PARAMS ((PTR, bfd_byte *));
-extern boolean _bfd_ecoff_get_accumulated_ss PARAMS ((PTR, bfd_byte *));
-
-extern bfd_vma _bfd_get_gp_value PARAMS ((bfd *));
-extern void _bfd_set_gp_value PARAMS ((bfd *, bfd_vma));
+extern bfd_boolean _bfd_ecoff_locate_line
+ (bfd *, asection *, bfd_vma, struct ecoff_debug_info * const,
+ const struct ecoff_debug_swap * const, struct ecoff_find_line *,
+ const char **, const char **, unsigned int *);
+extern bfd_boolean _bfd_ecoff_get_accumulated_pdr
+ (void *, bfd_byte *);
+extern bfd_boolean _bfd_ecoff_get_accumulated_sym
+ (void *, bfd_byte *);
+extern bfd_boolean _bfd_ecoff_get_accumulated_ss
+ (void *, bfd_byte *);
+
+extern bfd_vma _bfd_get_gp_value
+ (bfd *);
+extern void _bfd_set_gp_value
+ (bfd *, bfd_vma);
/* Function shared by the COFF and ELF SH backends, which have no
other common header files. */
-extern boolean _bfd_sh_align_load_span
- PARAMS ((bfd *, asection *, bfd_byte *,
- boolean (*) (bfd *, asection *, PTR, bfd_byte *, bfd_vma),
- PTR, bfd_vma **, bfd_vma *, bfd_vma, bfd_vma, boolean *));
-
+#ifndef _bfd_sh_align_load_span
+extern bfd_boolean _bfd_sh_align_load_span
+ (bfd *, asection *, bfd_byte *,
+ bfd_boolean (*) (bfd *, asection *, void *, bfd_byte *, bfd_vma),
+ void *, bfd_vma **, bfd_vma *, bfd_vma, bfd_vma, bfd_boolean *);
+#endif
/* Extracted from init.c. */
/* Extracted from libbfd.c. */
-boolean
-bfd_write_bigendian_4byte_int PARAMS ((bfd *, unsigned int));
+bfd_boolean bfd_write_bigendian_4byte_int (bfd *, unsigned int);
-unsigned int
-bfd_log2 PARAMS ((bfd_vma x));
+unsigned int bfd_log2 (bfd_vma x);
+/* Extracted from bfdio.c. */
+/* Extracted from bfdwin.c. */
+struct _bfd_window_internal {
+ struct _bfd_window_internal *next;
+ void *data;
+ bfd_size_type size;
+ int refcount : 31; /* should be enough... */
+ unsigned mapped : 1; /* 1 = mmap, 0 = malloc */
+};
/* Extracted from cache.c. */
#define BFD_CACHE_MAX_OPEN 10
extern bfd *bfd_last_cache;
@@ -614,17 +673,13 @@ extern bfd *bfd_last_cache;
((x)==bfd_last_cache? \
(FILE*) (bfd_last_cache->iostream): \
bfd_cache_lookup_worker(x))
-boolean
-bfd_cache_init PARAMS ((bfd *abfd));
+bfd_boolean bfd_cache_init (bfd *abfd);
-boolean
-bfd_cache_close PARAMS ((bfd *abfd));
+bfd_boolean bfd_cache_close (bfd *abfd);
-FILE*
-bfd_open_file PARAMS ((bfd *abfd));
+FILE* bfd_open_file (bfd *abfd);
-FILE *
-bfd_cache_lookup_worker PARAMS ((bfd *abfd));
+FILE *bfd_cache_lookup_worker (bfd *abfd);
/* Extracted from reloc.c. */
#ifdef _BFD_MAKE_TABLE_bfd_reloc_code_real
@@ -726,6 +781,30 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
"BFD_RELOC_SPARC_L44",
"BFD_RELOC_SPARC_REGISTER",
"BFD_RELOC_SPARC_REV32",
+ "BFD_RELOC_SPARC_TLS_GD_HI22",
+ "BFD_RELOC_SPARC_TLS_GD_LO10",
+ "BFD_RELOC_SPARC_TLS_GD_ADD",
+ "BFD_RELOC_SPARC_TLS_GD_CALL",
+ "BFD_RELOC_SPARC_TLS_LDM_HI22",
+ "BFD_RELOC_SPARC_TLS_LDM_LO10",
+ "BFD_RELOC_SPARC_TLS_LDM_ADD",
+ "BFD_RELOC_SPARC_TLS_LDM_CALL",
+ "BFD_RELOC_SPARC_TLS_LDO_HIX22",
+ "BFD_RELOC_SPARC_TLS_LDO_LOX10",
+ "BFD_RELOC_SPARC_TLS_LDO_ADD",
+ "BFD_RELOC_SPARC_TLS_IE_HI22",
+ "BFD_RELOC_SPARC_TLS_IE_LO10",
+ "BFD_RELOC_SPARC_TLS_IE_LD",
+ "BFD_RELOC_SPARC_TLS_IE_LDX",
+ "BFD_RELOC_SPARC_TLS_IE_ADD",
+ "BFD_RELOC_SPARC_TLS_LE_HIX22",
+ "BFD_RELOC_SPARC_TLS_LE_LOX10",
+ "BFD_RELOC_SPARC_TLS_DTPMOD32",
+ "BFD_RELOC_SPARC_TLS_DTPMOD64",
+ "BFD_RELOC_SPARC_TLS_DTPOFF32",
+ "BFD_RELOC_SPARC_TLS_DTPOFF64",
+ "BFD_RELOC_SPARC_TLS_TPOFF32",
+ "BFD_RELOC_SPARC_TLS_TPOFF64",
"BFD_RELOC_ALPHA_GPDISP_HI16",
"BFD_RELOC_ALPHA_GPDISP_LO16",
"BFD_RELOC_ALPHA_GPDISP",
@@ -781,6 +860,7 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
"BFD_RELOC_MIPS_REL16",
"BFD_RELOC_MIPS_RELGOT",
"BFD_RELOC_MIPS_JALR",
+
"BFD_RELOC_FRV_LABEL16",
"BFD_RELOC_FRV_LABEL24",
"BFD_RELOC_FRV_LO16",
@@ -790,6 +870,29 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
"BFD_RELOC_FRV_GPREL32",
"BFD_RELOC_FRV_GPRELHI",
"BFD_RELOC_FRV_GPRELLO",
+ "BFD_RELOC_FRV_GOT12",
+ "BFD_RELOC_FRV_GOTHI",
+ "BFD_RELOC_FRV_GOTLO",
+ "BFD_RELOC_FRV_FUNCDESC",
+ "BFD_RELOC_FRV_FUNCDESC_GOT12",
+ "BFD_RELOC_FRV_FUNCDESC_GOTHI",
+ "BFD_RELOC_FRV_FUNCDESC_GOTLO",
+ "BFD_RELOC_FRV_FUNCDESC_VALUE",
+ "BFD_RELOC_FRV_FUNCDESC_GOTOFF12",
+ "BFD_RELOC_FRV_FUNCDESC_GOTOFFHI",
+ "BFD_RELOC_FRV_FUNCDESC_GOTOFFLO",
+ "BFD_RELOC_FRV_GOTOFF12",
+ "BFD_RELOC_FRV_GOTOFFHI",
+ "BFD_RELOC_FRV_GOTOFFLO",
+
+ "BFD_RELOC_MN10300_GOTOFF24",
+ "BFD_RELOC_MN10300_GOT32",
+ "BFD_RELOC_MN10300_GOT24",
+ "BFD_RELOC_MN10300_GOT16",
+ "BFD_RELOC_MN10300_COPY",
+ "BFD_RELOC_MN10300_GLOB_DAT",
+ "BFD_RELOC_MN10300_JMP_SLOT",
+ "BFD_RELOC_MN10300_RELATIVE",
"BFD_RELOC_386_GOT32",
"BFD_RELOC_386_PLT32",
@@ -819,6 +922,14 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
"BFD_RELOC_X86_64_RELATIVE",
"BFD_RELOC_X86_64_GOTPCREL",
"BFD_RELOC_X86_64_32S",
+ "BFD_RELOC_X86_64_DTPMOD64",
+ "BFD_RELOC_X86_64_DTPOFF64",
+ "BFD_RELOC_X86_64_TPOFF64",
+ "BFD_RELOC_X86_64_TLSGD",
+ "BFD_RELOC_X86_64_TLSLD",
+ "BFD_RELOC_X86_64_DTPOFF32",
+ "BFD_RELOC_X86_64_GOTTPOFF",
+ "BFD_RELOC_X86_64_TPOFF32",
"BFD_RELOC_NS32K_IMM_8",
"BFD_RELOC_NS32K_IMM_16",
"BFD_RELOC_NS32K_IMM_32",
@@ -892,6 +1003,46 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
"BFD_RELOC_PPC64_TOC16_LO_DS",
"BFD_RELOC_PPC64_PLTGOT16_DS",
"BFD_RELOC_PPC64_PLTGOT16_LO_DS",
+ "BFD_RELOC_PPC_TLS",
+ "BFD_RELOC_PPC_DTPMOD",
+ "BFD_RELOC_PPC_TPREL16",
+ "BFD_RELOC_PPC_TPREL16_LO",
+ "BFD_RELOC_PPC_TPREL16_HI",
+ "BFD_RELOC_PPC_TPREL16_HA",
+ "BFD_RELOC_PPC_TPREL",
+ "BFD_RELOC_PPC_DTPREL16",
+ "BFD_RELOC_PPC_DTPREL16_LO",
+ "BFD_RELOC_PPC_DTPREL16_HI",
+ "BFD_RELOC_PPC_DTPREL16_HA",
+ "BFD_RELOC_PPC_DTPREL",
+ "BFD_RELOC_PPC_GOT_TLSGD16",
+ "BFD_RELOC_PPC_GOT_TLSGD16_LO",
+ "BFD_RELOC_PPC_GOT_TLSGD16_HI",
+ "BFD_RELOC_PPC_GOT_TLSGD16_HA",
+ "BFD_RELOC_PPC_GOT_TLSLD16",
+ "BFD_RELOC_PPC_GOT_TLSLD16_LO",
+ "BFD_RELOC_PPC_GOT_TLSLD16_HI",
+ "BFD_RELOC_PPC_GOT_TLSLD16_HA",
+ "BFD_RELOC_PPC_GOT_TPREL16",
+ "BFD_RELOC_PPC_GOT_TPREL16_LO",
+ "BFD_RELOC_PPC_GOT_TPREL16_HI",
+ "BFD_RELOC_PPC_GOT_TPREL16_HA",
+ "BFD_RELOC_PPC_GOT_DTPREL16",
+ "BFD_RELOC_PPC_GOT_DTPREL16_LO",
+ "BFD_RELOC_PPC_GOT_DTPREL16_HI",
+ "BFD_RELOC_PPC_GOT_DTPREL16_HA",
+ "BFD_RELOC_PPC64_TPREL16_DS",
+ "BFD_RELOC_PPC64_TPREL16_LO_DS",
+ "BFD_RELOC_PPC64_TPREL16_HIGHER",
+ "BFD_RELOC_PPC64_TPREL16_HIGHERA",
+ "BFD_RELOC_PPC64_TPREL16_HIGHEST",
+ "BFD_RELOC_PPC64_TPREL16_HIGHESTA",
+ "BFD_RELOC_PPC64_DTPREL16_DS",
+ "BFD_RELOC_PPC64_DTPREL16_LO_DS",
+ "BFD_RELOC_PPC64_DTPREL16_HIGHER",
+ "BFD_RELOC_PPC64_DTPREL16_HIGHERA",
+ "BFD_RELOC_PPC64_DTPREL16_HIGHEST",
+ "BFD_RELOC_PPC64_DTPREL16_HIGHESTA",
"BFD_RELOC_I370_D12",
"BFD_RELOC_CTOR",
"BFD_RELOC_ARM_PCREL_BRANCH",
@@ -904,6 +1055,7 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
"BFD_RELOC_ARM_SWI",
"BFD_RELOC_ARM_MULTI",
"BFD_RELOC_ARM_CP_OFF_IMM",
+ "BFD_RELOC_ARM_CP_OFF_IMM_S2",
"BFD_RELOC_ARM_ADR_IMM",
"BFD_RELOC_ARM_LDR_IMM",
"BFD_RELOC_ARM_LITERAL",
@@ -997,6 +1149,14 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
"BFD_RELOC_SH_IMM_HI16",
"BFD_RELOC_SH_IMM_HI16_PCREL",
"BFD_RELOC_SH_PT_16",
+ "BFD_RELOC_SH_TLS_GD_32",
+ "BFD_RELOC_SH_TLS_LD_32",
+ "BFD_RELOC_SH_TLS_LDO_32",
+ "BFD_RELOC_SH_TLS_IE_32",
+ "BFD_RELOC_SH_TLS_LE_32",
+ "BFD_RELOC_SH_TLS_DTPMOD32",
+ "BFD_RELOC_SH_TLS_DTPOFF32",
+ "BFD_RELOC_SH_TLS_TPOFF32",
"BFD_RELOC_THUMB_PCREL_BRANCH9",
"BFD_RELOC_THUMB_PCREL_BRANCH12",
"BFD_RELOC_THUMB_PCREL_BRANCH23",
@@ -1028,6 +1188,20 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
"BFD_RELOC_M32R_HI16_SLO",
"BFD_RELOC_M32R_LO16",
"BFD_RELOC_M32R_SDA16",
+ "BFD_RELOC_M32R_GOT24",
+ "BFD_RELOC_M32R_26_PLTREL",
+ "BFD_RELOC_M32R_COPY",
+ "BFD_RELOC_M32R_GLOB_DAT",
+ "BFD_RELOC_M32R_JMP_SLOT",
+ "BFD_RELOC_M32R_RELATIVE",
+ "BFD_RELOC_M32R_GOTOFF",
+ "BFD_RELOC_M32R_GOTPC24",
+ "BFD_RELOC_M32R_GOT16_HI_ULO",
+ "BFD_RELOC_M32R_GOT16_HI_SLO",
+ "BFD_RELOC_M32R_GOT16_LO",
+ "BFD_RELOC_M32R_GOTPC_HI_ULO",
+ "BFD_RELOC_M32R_GOTPC_HI_SLO",
+ "BFD_RELOC_M32R_GOTPC_LO",
"BFD_RELOC_V850_9_PCREL",
"BFD_RELOC_V850_22_PCREL",
"BFD_RELOC_V850_SDA_16_16_OFFSET",
@@ -1044,7 +1218,9 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
"BFD_RELOC_V850_ZDA_16_16_SPLIT_OFFSET",
"BFD_RELOC_V850_CALLT_6_7_OFFSET",
"BFD_RELOC_V850_CALLT_16_16_OFFSET",
-
+ "BFD_RELOC_V850_LONGCALL",
+ "BFD_RELOC_V850_LONGJUMP",
+ "BFD_RELOC_V850_ALIGN",
"BFD_RELOC_MN10300_32_PCREL",
"BFD_RELOC_MN10300_16_PCREL",
"BFD_RELOC_TIC30_LDP",
@@ -1080,6 +1256,7 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
"BFD_RELOC_MMIX_PUSHJ_1",
"BFD_RELOC_MMIX_PUSHJ_2",
"BFD_RELOC_MMIX_PUSHJ_3",
+ "BFD_RELOC_MMIX_PUSHJ_STUBBABLE",
"BFD_RELOC_MMIX_JMP",
"BFD_RELOC_MMIX_JMP_1",
"BFD_RELOC_MMIX_JMP_2",
@@ -1123,6 +1300,53 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
"BFD_RELOC_390_GOT64",
"BFD_RELOC_390_PLT64",
"BFD_RELOC_390_GOTENT",
+ "BFD_RELOC_390_GOTOFF64",
+ "BFD_RELOC_390_GOTPLT12",
+ "BFD_RELOC_390_GOTPLT16",
+ "BFD_RELOC_390_GOTPLT32",
+ "BFD_RELOC_390_GOTPLT64",
+ "BFD_RELOC_390_GOTPLTENT",
+ "BFD_RELOC_390_PLTOFF16",
+ "BFD_RELOC_390_PLTOFF32",
+ "BFD_RELOC_390_PLTOFF64",
+ "BFD_RELOC_390_TLS_LOAD",
+ "BFD_RELOC_390_TLS_GDCALL",
+ "BFD_RELOC_390_TLS_LDCALL",
+ "BFD_RELOC_390_TLS_GD32",
+ "BFD_RELOC_390_TLS_GD64",
+ "BFD_RELOC_390_TLS_GOTIE12",
+ "BFD_RELOC_390_TLS_GOTIE32",
+ "BFD_RELOC_390_TLS_GOTIE64",
+ "BFD_RELOC_390_TLS_LDM32",
+ "BFD_RELOC_390_TLS_LDM64",
+ "BFD_RELOC_390_TLS_IE32",
+ "BFD_RELOC_390_TLS_IE64",
+ "BFD_RELOC_390_TLS_IEENT",
+ "BFD_RELOC_390_TLS_LE32",
+ "BFD_RELOC_390_TLS_LE64",
+ "BFD_RELOC_390_TLS_LDO32",
+ "BFD_RELOC_390_TLS_LDO64",
+ "BFD_RELOC_390_TLS_DTPMOD",
+ "BFD_RELOC_390_TLS_DTPOFF",
+ "BFD_RELOC_390_TLS_TPOFF",
+ "BFD_RELOC_390_20",
+ "BFD_RELOC_390_GOT20",
+ "BFD_RELOC_390_GOTPLT20",
+ "BFD_RELOC_390_TLS_GOTIE20",
+ "BFD_RELOC_IP2K_FR9",
+ "BFD_RELOC_IP2K_BANK",
+ "BFD_RELOC_IP2K_ADDR16CJP",
+ "BFD_RELOC_IP2K_PAGE3",
+ "BFD_RELOC_IP2K_LO8DATA",
+ "BFD_RELOC_IP2K_HI8DATA",
+ "BFD_RELOC_IP2K_EX8DATA",
+ "BFD_RELOC_IP2K_LO8INSN",
+ "BFD_RELOC_IP2K_HI8INSN",
+ "BFD_RELOC_IP2K_PC_SKIP",
+ "BFD_RELOC_IP2K_TEXT",
+ "BFD_RELOC_IP2K_FR_OFFSET",
+ "BFD_RELOC_VPE4KMATH_DATA",
+ "BFD_RELOC_VPE4KMATH_INSN",
"BFD_RELOC_VTABLE_INHERIT",
"BFD_RELOC_VTABLE_ENTRY",
"BFD_RELOC_IA64_IMM14",
@@ -1207,6 +1431,12 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
"BFD_RELOC_M68HC11_HI8",
"BFD_RELOC_M68HC11_LO8",
"BFD_RELOC_M68HC11_3B",
+ "BFD_RELOC_M68HC11_RL_JUMP",
+ "BFD_RELOC_M68HC11_RL_GROUP",
+ "BFD_RELOC_M68HC11_LO16",
+ "BFD_RELOC_M68HC11_PAGE",
+ "BFD_RELOC_M68HC11_24",
+ "BFD_RELOC_M68HC12_5B",
"BFD_RELOC_CRIS_BDISP8",
"BFD_RELOC_CRIS_UNSIGNED_5",
"BFD_RELOC_CRIS_SIGNED_6",
@@ -1263,53 +1493,68 @@ static const char *const bfd_reloc_code_real_names[] = { "@@uninitialized@@",
"BFD_RELOC_H8_DIR24R8",
"BFD_RELOC_H8_DIR32A16",
"BFD_RELOC_XSTORMY16_REL_12",
+ "BFD_RELOC_XSTORMY16_12",
"BFD_RELOC_XSTORMY16_24",
"BFD_RELOC_XSTORMY16_FPTR16",
"BFD_RELOC_VAX_GLOB_DAT",
"BFD_RELOC_VAX_JMP_SLOT",
"BFD_RELOC_VAX_RELATIVE",
+ "BFD_RELOC_MSP430_10_PCREL",
+ "BFD_RELOC_MSP430_16_PCREL",
+ "BFD_RELOC_MSP430_16",
+ "BFD_RELOC_MSP430_16_PCREL_BYTE",
+ "BFD_RELOC_MSP430_16_BYTE",
+ "BFD_RELOC_IQ2000_OFFSET_16",
+ "BFD_RELOC_IQ2000_OFFSET_21",
+ "BFD_RELOC_IQ2000_UHI16",
+ "BFD_RELOC_XTENSA_RTLD",
+ "BFD_RELOC_XTENSA_GLOB_DAT",
+ "BFD_RELOC_XTENSA_JMP_SLOT",
+ "BFD_RELOC_XTENSA_RELATIVE",
+ "BFD_RELOC_XTENSA_PLT",
+ "BFD_RELOC_XTENSA_OP0",
+ "BFD_RELOC_XTENSA_OP1",
+ "BFD_RELOC_XTENSA_OP2",
+ "BFD_RELOC_XTENSA_ASM_EXPAND",
+ "BFD_RELOC_XTENSA_ASM_SIMPLIFY",
"@@overflow: BFD_RELOC_UNUSED@@",
};
#endif
-reloc_howto_type *
-bfd_default_reloc_type_lookup PARAMS ((bfd *abfd, bfd_reloc_code_real_type code));
+reloc_howto_type *bfd_default_reloc_type_lookup
+ (bfd *abfd, bfd_reloc_code_real_type code);
-boolean
-bfd_generic_relax_section PARAMS ((bfd *abfd,
+bfd_boolean bfd_generic_relax_section
+ (bfd *abfd,
asection *section,
struct bfd_link_info *,
- boolean *));
+ bfd_boolean *);
-boolean
-bfd_generic_gc_sections PARAMS ((bfd *, struct bfd_link_info *));
+bfd_boolean bfd_generic_gc_sections
+ (bfd *, struct bfd_link_info *);
-boolean
-bfd_generic_merge_sections PARAMS ((bfd *, struct bfd_link_info *));
+bfd_boolean bfd_generic_merge_sections
+ (bfd *, struct bfd_link_info *);
-bfd_byte *
-bfd_generic_get_relocated_section_contents PARAMS ((bfd *abfd,
+bfd_byte *bfd_generic_get_relocated_section_contents
+ (bfd *abfd,
struct bfd_link_info *link_info,
struct bfd_link_order *link_order,
bfd_byte *data,
- boolean relocateable,
- asymbol **symbols));
+ bfd_boolean relocatable,
+ asymbol **symbols);
/* Extracted from archures.c. */
extern const bfd_arch_info_type bfd_default_arch_struct;
-boolean
-bfd_default_set_arch_mach PARAMS ((bfd *abfd,
- enum bfd_architecture arch,
- unsigned long mach));
+bfd_boolean bfd_default_set_arch_mach
+ (bfd *abfd, enum bfd_architecture arch, unsigned long mach);
-const bfd_arch_info_type *
-bfd_default_compatible PARAMS ((const bfd_arch_info_type *a,
- const bfd_arch_info_type *b));
+const bfd_arch_info_type *bfd_default_compatible
+ (const bfd_arch_info_type *a, const bfd_arch_info_type *b);
-boolean
-bfd_default_scan PARAMS ((const struct bfd_arch_info *info, const char *string));
+bfd_boolean bfd_default_scan
+ (const struct bfd_arch_info *info, const char *string);
/* Extracted from elf.c. */
-struct elf_internal_shdr *
-bfd_elf_find_section PARAMS ((bfd *abfd, char *name));
+struct elf_internal_shdr *bfd_elf_find_section (bfd *abfd, char *name);
diff --git a/contrib/binutils/bfd/libcoff-in.h b/contrib/binutils/bfd/libcoff-in.h
index efc2fee..6b5947c 100644
--- a/contrib/binutils/bfd/libcoff-in.h
+++ b/contrib/binutils/bfd/libcoff-in.h
@@ -1,6 +1,6 @@
/* BFD COFF object file private structure.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Support.
@@ -74,16 +74,16 @@ typedef struct coff_tdata
/* The unswapped external symbols. May be NULL. Read by
_bfd_coff_get_external_symbols. */
PTR external_syms;
- /* If this is true, the external_syms may not be freed. */
- boolean keep_syms;
+ /* If this is TRUE, the external_syms may not be freed. */
+ bfd_boolean keep_syms;
/* The string table. May be NULL. Read by
_bfd_coff_read_string_table. */
char *strings;
- /* If this is true, the strings may not be freed. */
- boolean keep_strings;
- /* If this is true, the strings have been written out already. */
- boolean strings_written;
+ /* If this is TRUE, the strings may not be freed. */
+ bfd_boolean keep_strings;
+ /* If this is TRUE, the strings have been written out already. */
+ bfd_boolean strings_written;
/* is this a PE format coff file */
int pe;
@@ -117,10 +117,10 @@ typedef struct pe_tdata
struct internal_extra_pe_aouthdr pe_opthdr;
int dll;
int has_reloc_section;
- boolean (*in_reloc_p) PARAMS((bfd *, reloc_howto_type *));
+ bfd_boolean (*in_reloc_p) PARAMS((bfd *, reloc_howto_type *));
flagword real_flags;
int target_subsystem;
- boolean force_minimum_alignment;
+ bfd_boolean force_minimum_alignment;
} pe_data_type;
#define pe_data(bfd) ((bfd)->tdata.pe_obj_data)
@@ -132,11 +132,11 @@ struct xcoff_tdata
/* Basic COFF information. */
coff_data_type coff;
- /* True if this is an XCOFF64 file. */
- boolean xcoff64;
+ /* TRUE if this is an XCOFF64 file. */
+ bfd_boolean xcoff64;
- /* True if a large a.out header should be generated. */
- boolean full_aouthdr;
+ /* TRUE if a large a.out header should be generated. */
+ bfd_boolean full_aouthdr;
/* TOC value. */
bfd_vma toc;
@@ -184,12 +184,12 @@ struct coff_section_tdata
{
/* The relocs, swapped into COFF internal form. This may be NULL. */
struct internal_reloc *relocs;
- /* If this is true, the relocs entry may not be freed. */
- boolean keep_relocs;
+ /* If this is TRUE, the relocs entry may not be freed. */
+ bfd_boolean keep_relocs;
/* The section contents. This may be NULL. */
bfd_byte *contents;
- /* If this is true, the contents entry may not be freed. */
- boolean keep_contents;
+ /* If this is TRUE, the contents entry may not be freed. */
+ bfd_boolean keep_contents;
/* Information cached by coff_find_nearest_line. */
bfd_vma offset;
unsigned int i;
@@ -291,7 +291,7 @@ struct coff_link_hash_table
#define coff_link_hash_traverse(table, func, info) \
(bfd_link_hash_traverse \
(&(table)->root, \
- (boolean (*) PARAMS ((struct bfd_link_hash_entry *, PTR))) (func), \
+ (bfd_boolean (*) PARAMS ((struct bfd_link_hash_entry *, PTR))) (func), \
(info)))
/* Get the COFF linker hash table from a link_info structure. */
@@ -301,33 +301,33 @@ struct coff_link_hash_table
/* Functions in coffgen.c. */
extern const bfd_target *coff_object_p
PARAMS ((bfd *));
-extern struct sec *coff_section_from_bfd_index
+extern struct bfd_section *coff_section_from_bfd_index
PARAMS ((bfd *, int));
extern long coff_get_symtab_upper_bound
PARAMS ((bfd *));
-extern long coff_get_symtab
+extern long coff_canonicalize_symtab
PARAMS ((bfd *, asymbol **));
extern int coff_count_linenumbers
PARAMS ((bfd *));
extern struct coff_symbol_struct *coff_symbol_from
PARAMS ((bfd *, asymbol *));
-extern boolean coff_renumber_symbols
+extern bfd_boolean coff_renumber_symbols
PARAMS ((bfd *, int *));
extern void coff_mangle_symbols
PARAMS ((bfd *));
-extern boolean coff_write_symbols
+extern bfd_boolean coff_write_symbols
PARAMS ((bfd *));
-extern boolean coff_write_linenumbers
+extern bfd_boolean coff_write_linenumbers
PARAMS ((bfd *));
extern alent *coff_get_lineno
PARAMS ((bfd *, asymbol *));
extern asymbol *coff_section_symbol
PARAMS ((bfd *, char *));
-extern boolean _bfd_coff_get_external_symbols
+extern bfd_boolean _bfd_coff_get_external_symbols
PARAMS ((bfd *));
extern const char *_bfd_coff_read_string_table
PARAMS ((bfd *));
-extern boolean _bfd_coff_free_symbols
+extern bfd_boolean _bfd_coff_free_symbols
PARAMS ((bfd *));
extern struct coff_ptr_struct *coff_get_normalized_symtab
PARAMS ((bfd *));
@@ -339,20 +339,20 @@ extern void coff_print_symbol
PARAMS ((bfd *, PTR filep, asymbol *, bfd_print_symbol_type));
extern void coff_get_symbol_info
PARAMS ((bfd *, asymbol *, symbol_info *ret));
-extern boolean _bfd_coff_is_local_label_name
+extern bfd_boolean _bfd_coff_is_local_label_name
PARAMS ((bfd *, const char *));
extern asymbol *coff_bfd_make_debug_symbol
PARAMS ((bfd *, PTR, unsigned long));
-extern boolean coff_find_nearest_line
+extern bfd_boolean coff_find_nearest_line
PARAMS ((bfd *, asection *, asymbol **, bfd_vma, const char **,
const char **, unsigned int *));
extern int coff_sizeof_headers
- PARAMS ((bfd *, boolean));
-extern boolean bfd_coff_reloc16_relax_section
- PARAMS ((bfd *, asection *, struct bfd_link_info *, boolean *));
+ PARAMS ((bfd *, bfd_boolean));
+extern bfd_boolean bfd_coff_reloc16_relax_section
+ PARAMS ((bfd *, asection *, struct bfd_link_info *, bfd_boolean *));
extern bfd_byte *bfd_coff_reloc16_get_relocated_section_contents
PARAMS ((bfd *, struct bfd_link_info *, struct bfd_link_order *,
- bfd_byte *, boolean, asymbol **));
+ bfd_byte *, bfd_boolean, asymbol **));
extern bfd_vma bfd_coff_reloc16_get_value
PARAMS ((arelent *, struct bfd_link_info *, asection *));
extern void bfd_perform_slip
@@ -434,7 +434,7 @@ struct coff_debug_merge_hash_table
bfd_hash_lookup (&(table)->root, (string), (create), (copy)))
/* Information we keep for each section in the output file when doing
- a relocateable link. */
+ a relocatable link. */
struct coff_link_section_info
{
@@ -454,14 +454,14 @@ struct coff_final_link_info
/* Output BFD. */
bfd *output_bfd;
/* Used to indicate failure in traversal routine. */
- boolean failed;
+ bfd_boolean failed;
/* If doing "task linking" set only during the time when we want the
global symbol writer to convert the storage class of defined global
symbols from global to static. */
- boolean global_to_static;
+ bfd_boolean global_to_static;
/* Hash table for long symbol names. */
struct bfd_strtab_hash *strtab;
- /* When doing a relocateable link, an array of information kept for
+ /* When doing a relocatable link, an array of information kept for
each output section, indexed by the target_index field. */
struct coff_link_section_info *section_info;
/* Symbol index of last C_FILE symbol (-1 if none). */
@@ -532,7 +532,7 @@ struct coff_section_alignment_entry
extern struct bfd_hash_entry *_bfd_coff_link_hash_newfunc
PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-extern boolean _bfd_coff_link_hash_table_init
+extern bfd_boolean _bfd_coff_link_hash_table_init
PARAMS ((struct coff_link_hash_table *, bfd *,
struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
struct bfd_hash_table *,
@@ -541,26 +541,26 @@ extern struct bfd_link_hash_table *_bfd_coff_link_hash_table_create
PARAMS ((bfd *));
extern const char *_bfd_coff_internal_syment_name
PARAMS ((bfd *, const struct internal_syment *, char *));
-extern boolean _bfd_coff_link_add_symbols
+extern bfd_boolean _bfd_coff_link_add_symbols
PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean _bfd_coff_final_link
+extern bfd_boolean _bfd_coff_final_link
PARAMS ((bfd *, struct bfd_link_info *));
extern struct internal_reloc *_bfd_coff_read_internal_relocs
- PARAMS ((bfd *, asection *, boolean, bfd_byte *, boolean,
+ PARAMS ((bfd *, asection *, bfd_boolean, bfd_byte *, bfd_boolean,
struct internal_reloc *));
-extern boolean _bfd_coff_generic_relocate_section
+extern bfd_boolean _bfd_coff_generic_relocate_section
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
struct internal_reloc *, struct internal_syment *, asection **));
extern struct bfd_hash_entry *_bfd_coff_debug_merge_hash_newfunc
PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-extern boolean _bfd_coff_write_global_sym
+extern bfd_boolean _bfd_coff_write_global_sym
PARAMS ((struct coff_link_hash_entry *, PTR));
-extern boolean _bfd_coff_write_task_globals
+extern bfd_boolean _bfd_coff_write_task_globals
PARAMS ((struct coff_link_hash_entry *, PTR));
-extern boolean _bfd_coff_link_input_bfd
+extern bfd_boolean _bfd_coff_link_input_bfd
PARAMS ((struct coff_final_link_info *, bfd *));
-extern boolean _bfd_coff_reloc_link_order
+extern bfd_boolean _bfd_coff_reloc_link_order
PARAMS ((bfd *, struct coff_final_link_info *, asection *,
struct bfd_link_order *));
@@ -582,19 +582,19 @@ extern struct bfd_link_hash_table *_bfd_xcoff_bfd_link_hash_table_create
PARAMS ((bfd *));
extern void _bfd_xcoff_bfd_link_hash_table_free
PARAMS ((struct bfd_link_hash_table *));
-extern boolean _bfd_xcoff_bfd_link_add_symbols
+extern bfd_boolean _bfd_xcoff_bfd_link_add_symbols
PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean _bfd_xcoff_bfd_final_link
+extern bfd_boolean _bfd_xcoff_bfd_final_link
PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean _bfd_ppc_xcoff_relocate_section
+extern bfd_boolean _bfd_ppc_xcoff_relocate_section
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
struct internal_reloc *, struct internal_syment *, asection **));
/* Functions in coff-ppc.c. FIXME: These are called be pe.em in the
linker, and so should start with bfd and be declared in bfd.h. */
-extern boolean ppc_allocate_toc_section
+extern bfd_boolean ppc_allocate_toc_section
PARAMS ((struct bfd_link_info *));
-extern boolean ppc_process_before_allocation
+extern bfd_boolean ppc_process_before_allocation
PARAMS ((bfd *, struct bfd_link_info *));
diff --git a/contrib/binutils/bfd/libcoff.h b/contrib/binutils/bfd/libcoff.h
index ea9c570..5771132 100644
--- a/contrib/binutils/bfd/libcoff.h
+++ b/contrib/binutils/bfd/libcoff.h
@@ -4,7 +4,7 @@
/* BFD COFF object file private structure.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Support.
@@ -78,16 +78,16 @@ typedef struct coff_tdata
/* The unswapped external symbols. May be NULL. Read by
_bfd_coff_get_external_symbols. */
PTR external_syms;
- /* If this is true, the external_syms may not be freed. */
- boolean keep_syms;
+ /* If this is TRUE, the external_syms may not be freed. */
+ bfd_boolean keep_syms;
/* The string table. May be NULL. Read by
_bfd_coff_read_string_table. */
char *strings;
- /* If this is true, the strings may not be freed. */
- boolean keep_strings;
- /* If this is true, the strings have been written out already. */
- boolean strings_written;
+ /* If this is TRUE, the strings may not be freed. */
+ bfd_boolean keep_strings;
+ /* If this is TRUE, the strings have been written out already. */
+ bfd_boolean strings_written;
/* is this a PE format coff file */
int pe;
@@ -121,10 +121,10 @@ typedef struct pe_tdata
struct internal_extra_pe_aouthdr pe_opthdr;
int dll;
int has_reloc_section;
- boolean (*in_reloc_p) PARAMS((bfd *, reloc_howto_type *));
+ bfd_boolean (*in_reloc_p) PARAMS((bfd *, reloc_howto_type *));
flagword real_flags;
int target_subsystem;
- boolean force_minimum_alignment;
+ bfd_boolean force_minimum_alignment;
} pe_data_type;
#define pe_data(bfd) ((bfd)->tdata.pe_obj_data)
@@ -136,11 +136,11 @@ struct xcoff_tdata
/* Basic COFF information. */
coff_data_type coff;
- /* True if this is an XCOFF64 file. */
- boolean xcoff64;
+ /* TRUE if this is an XCOFF64 file. */
+ bfd_boolean xcoff64;
- /* True if a large a.out header should be generated. */
- boolean full_aouthdr;
+ /* TRUE if a large a.out header should be generated. */
+ bfd_boolean full_aouthdr;
/* TOC value. */
bfd_vma toc;
@@ -188,12 +188,12 @@ struct coff_section_tdata
{
/* The relocs, swapped into COFF internal form. This may be NULL. */
struct internal_reloc *relocs;
- /* If this is true, the relocs entry may not be freed. */
- boolean keep_relocs;
+ /* If this is TRUE, the relocs entry may not be freed. */
+ bfd_boolean keep_relocs;
/* The section contents. This may be NULL. */
bfd_byte *contents;
- /* If this is true, the contents entry may not be freed. */
- boolean keep_contents;
+ /* If this is TRUE, the contents entry may not be freed. */
+ bfd_boolean keep_contents;
/* Information cached by coff_find_nearest_line. */
bfd_vma offset;
unsigned int i;
@@ -295,7 +295,7 @@ struct coff_link_hash_table
#define coff_link_hash_traverse(table, func, info) \
(bfd_link_hash_traverse \
(&(table)->root, \
- (boolean (*) PARAMS ((struct bfd_link_hash_entry *, PTR))) (func), \
+ (bfd_boolean (*) PARAMS ((struct bfd_link_hash_entry *, PTR))) (func), \
(info)))
/* Get the COFF linker hash table from a link_info structure. */
@@ -305,33 +305,33 @@ struct coff_link_hash_table
/* Functions in coffgen.c. */
extern const bfd_target *coff_object_p
PARAMS ((bfd *));
-extern struct sec *coff_section_from_bfd_index
+extern struct bfd_section *coff_section_from_bfd_index
PARAMS ((bfd *, int));
extern long coff_get_symtab_upper_bound
PARAMS ((bfd *));
-extern long coff_get_symtab
+extern long coff_canonicalize_symtab
PARAMS ((bfd *, asymbol **));
extern int coff_count_linenumbers
PARAMS ((bfd *));
extern struct coff_symbol_struct *coff_symbol_from
PARAMS ((bfd *, asymbol *));
-extern boolean coff_renumber_symbols
+extern bfd_boolean coff_renumber_symbols
PARAMS ((bfd *, int *));
extern void coff_mangle_symbols
PARAMS ((bfd *));
-extern boolean coff_write_symbols
+extern bfd_boolean coff_write_symbols
PARAMS ((bfd *));
-extern boolean coff_write_linenumbers
+extern bfd_boolean coff_write_linenumbers
PARAMS ((bfd *));
extern alent *coff_get_lineno
PARAMS ((bfd *, asymbol *));
extern asymbol *coff_section_symbol
PARAMS ((bfd *, char *));
-extern boolean _bfd_coff_get_external_symbols
+extern bfd_boolean _bfd_coff_get_external_symbols
PARAMS ((bfd *));
extern const char *_bfd_coff_read_string_table
PARAMS ((bfd *));
-extern boolean _bfd_coff_free_symbols
+extern bfd_boolean _bfd_coff_free_symbols
PARAMS ((bfd *));
extern struct coff_ptr_struct *coff_get_normalized_symtab
PARAMS ((bfd *));
@@ -343,20 +343,20 @@ extern void coff_print_symbol
PARAMS ((bfd *, PTR filep, asymbol *, bfd_print_symbol_type));
extern void coff_get_symbol_info
PARAMS ((bfd *, asymbol *, symbol_info *ret));
-extern boolean _bfd_coff_is_local_label_name
+extern bfd_boolean _bfd_coff_is_local_label_name
PARAMS ((bfd *, const char *));
extern asymbol *coff_bfd_make_debug_symbol
PARAMS ((bfd *, PTR, unsigned long));
-extern boolean coff_find_nearest_line
+extern bfd_boolean coff_find_nearest_line
PARAMS ((bfd *, asection *, asymbol **, bfd_vma, const char **,
const char **, unsigned int *));
extern int coff_sizeof_headers
- PARAMS ((bfd *, boolean));
-extern boolean bfd_coff_reloc16_relax_section
- PARAMS ((bfd *, asection *, struct bfd_link_info *, boolean *));
+ PARAMS ((bfd *, bfd_boolean));
+extern bfd_boolean bfd_coff_reloc16_relax_section
+ PARAMS ((bfd *, asection *, struct bfd_link_info *, bfd_boolean *));
extern bfd_byte *bfd_coff_reloc16_get_relocated_section_contents
PARAMS ((bfd *, struct bfd_link_info *, struct bfd_link_order *,
- bfd_byte *, boolean, asymbol **));
+ bfd_byte *, bfd_boolean, asymbol **));
extern bfd_vma bfd_coff_reloc16_get_value
PARAMS ((arelent *, struct bfd_link_info *, asection *));
extern void bfd_perform_slip
@@ -438,7 +438,7 @@ struct coff_debug_merge_hash_table
bfd_hash_lookup (&(table)->root, (string), (create), (copy)))
/* Information we keep for each section in the output file when doing
- a relocateable link. */
+ a relocatable link. */
struct coff_link_section_info
{
@@ -458,14 +458,14 @@ struct coff_final_link_info
/* Output BFD. */
bfd *output_bfd;
/* Used to indicate failure in traversal routine. */
- boolean failed;
+ bfd_boolean failed;
/* If doing "task linking" set only during the time when we want the
global symbol writer to convert the storage class of defined global
symbols from global to static. */
- boolean global_to_static;
+ bfd_boolean global_to_static;
/* Hash table for long symbol names. */
struct bfd_strtab_hash *strtab;
- /* When doing a relocateable link, an array of information kept for
+ /* When doing a relocatable link, an array of information kept for
each output section, indexed by the target_index field. */
struct coff_link_section_info *section_info;
/* Symbol index of last C_FILE symbol (-1 if none). */
@@ -536,7 +536,7 @@ struct coff_section_alignment_entry
extern struct bfd_hash_entry *_bfd_coff_link_hash_newfunc
PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-extern boolean _bfd_coff_link_hash_table_init
+extern bfd_boolean _bfd_coff_link_hash_table_init
PARAMS ((struct coff_link_hash_table *, bfd *,
struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
struct bfd_hash_table *,
@@ -545,26 +545,26 @@ extern struct bfd_link_hash_table *_bfd_coff_link_hash_table_create
PARAMS ((bfd *));
extern const char *_bfd_coff_internal_syment_name
PARAMS ((bfd *, const struct internal_syment *, char *));
-extern boolean _bfd_coff_link_add_symbols
+extern bfd_boolean _bfd_coff_link_add_symbols
PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean _bfd_coff_final_link
+extern bfd_boolean _bfd_coff_final_link
PARAMS ((bfd *, struct bfd_link_info *));
extern struct internal_reloc *_bfd_coff_read_internal_relocs
- PARAMS ((bfd *, asection *, boolean, bfd_byte *, boolean,
+ PARAMS ((bfd *, asection *, bfd_boolean, bfd_byte *, bfd_boolean,
struct internal_reloc *));
-extern boolean _bfd_coff_generic_relocate_section
+extern bfd_boolean _bfd_coff_generic_relocate_section
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
struct internal_reloc *, struct internal_syment *, asection **));
extern struct bfd_hash_entry *_bfd_coff_debug_merge_hash_newfunc
PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-extern boolean _bfd_coff_write_global_sym
+extern bfd_boolean _bfd_coff_write_global_sym
PARAMS ((struct coff_link_hash_entry *, PTR));
-extern boolean _bfd_coff_write_task_globals
+extern bfd_boolean _bfd_coff_write_task_globals
PARAMS ((struct coff_link_hash_entry *, PTR));
-extern boolean _bfd_coff_link_input_bfd
+extern bfd_boolean _bfd_coff_link_input_bfd
PARAMS ((struct coff_final_link_info *, bfd *));
-extern boolean _bfd_coff_reloc_link_order
+extern bfd_boolean _bfd_coff_reloc_link_order
PARAMS ((bfd *, struct coff_final_link_info *, asection *,
struct bfd_link_order *));
@@ -586,20 +586,20 @@ extern struct bfd_link_hash_table *_bfd_xcoff_bfd_link_hash_table_create
PARAMS ((bfd *));
extern void _bfd_xcoff_bfd_link_hash_table_free
PARAMS ((struct bfd_link_hash_table *));
-extern boolean _bfd_xcoff_bfd_link_add_symbols
+extern bfd_boolean _bfd_xcoff_bfd_link_add_symbols
PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean _bfd_xcoff_bfd_final_link
+extern bfd_boolean _bfd_xcoff_bfd_final_link
PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean _bfd_ppc_xcoff_relocate_section
+extern bfd_boolean _bfd_ppc_xcoff_relocate_section
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
struct internal_reloc *, struct internal_syment *, asection **));
/* Functions in coff-ppc.c. FIXME: These are called be pe.em in the
linker, and so should start with bfd and be declared in bfd.h. */
-extern boolean ppc_allocate_toc_section
+extern bfd_boolean ppc_allocate_toc_section
PARAMS ((struct bfd_link_info *));
-extern boolean ppc_process_before_allocation
+extern bfd_boolean ppc_process_before_allocation
PARAMS ((bfd *, struct bfd_link_info *));
/* Extracted from coffcode.h. */
@@ -653,7 +653,7 @@ typedef struct coff_symbol_struct
struct lineno_cache_entry *lineno;
/* Have the line numbers been relocated yet ? */
- boolean done_lineno;
+ bfd_boolean done_lineno;
} coff_symbol_type;
/* COFF symbol classifications. */
@@ -711,10 +711,10 @@ typedef struct
unsigned int _bfd_relsz;
unsigned int _bfd_linesz;
unsigned int _bfd_filnmlen;
- boolean _bfd_coff_long_filenames;
- boolean _bfd_coff_long_section_names;
+ bfd_boolean _bfd_coff_long_filenames;
+ bfd_boolean _bfd_coff_long_section_names;
unsigned int _bfd_coff_default_section_alignment_power;
- boolean _bfd_coff_force_symnames_in_strings;
+ bfd_boolean _bfd_coff_force_symnames_in_strings;
unsigned int _bfd_coff_debug_string_prefix_length;
void (*_bfd_coff_swap_filehdr_in)
@@ -729,32 +729,32 @@ typedef struct
void (*_bfd_coff_swap_reloc_in)
PARAMS ((bfd *abfd, PTR, PTR));
- boolean (*_bfd_coff_bad_format_hook)
+ bfd_boolean (*_bfd_coff_bad_format_hook)
PARAMS ((bfd *, PTR));
- boolean (*_bfd_coff_set_arch_mach_hook)
+ bfd_boolean (*_bfd_coff_set_arch_mach_hook)
PARAMS ((bfd *, PTR));
PTR (*_bfd_coff_mkobject_hook)
PARAMS ((bfd *, PTR, PTR));
- boolean (*_bfd_styp_to_sec_flags_hook)
+ bfd_boolean (*_bfd_styp_to_sec_flags_hook)
PARAMS ((bfd *, PTR, const char *, asection *, flagword *));
void (*_bfd_set_alignment_hook)
PARAMS ((bfd *, asection *, PTR));
- boolean (*_bfd_coff_slurp_symbol_table)
+ bfd_boolean (*_bfd_coff_slurp_symbol_table)
PARAMS ((bfd *));
- boolean (*_bfd_coff_symname_in_debug)
+ bfd_boolean (*_bfd_coff_symname_in_debug)
PARAMS ((bfd *, struct internal_syment *));
- boolean (*_bfd_coff_pointerize_aux_hook)
+ bfd_boolean (*_bfd_coff_pointerize_aux_hook)
PARAMS ((bfd *, combined_entry_type *, combined_entry_type *,
unsigned int, combined_entry_type *));
- boolean (*_bfd_coff_print_aux)
+ bfd_boolean (*_bfd_coff_print_aux)
PARAMS ((bfd *, FILE *, combined_entry_type *, combined_entry_type *,
combined_entry_type *, unsigned int));
@@ -769,13 +769,13 @@ typedef struct
enum coff_symbol_classification (*_bfd_coff_classify_symbol)
PARAMS ((bfd *, struct internal_syment *));
- boolean (*_bfd_coff_compute_section_file_positions)
+ bfd_boolean (*_bfd_coff_compute_section_file_positions)
PARAMS ((bfd *));
- boolean (*_bfd_coff_start_final_link)
+ bfd_boolean (*_bfd_coff_start_final_link)
PARAMS ((bfd *, struct bfd_link_info *));
- boolean (*_bfd_coff_relocate_section)
+ bfd_boolean (*_bfd_coff_relocate_section)
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *, bfd_byte *,
struct internal_reloc *, struct internal_syment *, asection **));
@@ -784,19 +784,19 @@ typedef struct
struct coff_link_hash_entry *, struct internal_syment *,
bfd_vma *));
- boolean (*_bfd_coff_adjust_symndx)
+ bfd_boolean (*_bfd_coff_adjust_symndx)
PARAMS ((bfd *, struct bfd_link_info *, bfd *, asection *,
- struct internal_reloc *, boolean *));
+ struct internal_reloc *, bfd_boolean *));
- boolean (*_bfd_coff_link_add_one_symbol)
+ bfd_boolean (*_bfd_coff_link_add_one_symbol)
PARAMS ((struct bfd_link_info *, bfd *, const char *, flagword,
- asection *, bfd_vma, const char *, boolean, boolean,
+ asection *, bfd_vma, const char *, bfd_boolean, bfd_boolean,
struct bfd_link_hash_entry **));
- boolean (*_bfd_coff_link_output_has_begun)
+ bfd_boolean (*_bfd_coff_link_output_has_begun)
PARAMS ((bfd *, struct coff_final_link_info *));
- boolean (*_bfd_coff_final_link_postscript)
+ bfd_boolean (*_bfd_coff_final_link_postscript)
PARAMS ((bfd *, struct coff_final_link_info *));
} bfd_coff_backend_data;
@@ -866,7 +866,8 @@ typedef struct
#define bfd_coff_set_arch_mach_hook(abfd, filehdr)\
((coff_backend_info (abfd)->_bfd_coff_set_arch_mach_hook) (abfd, filehdr))
#define bfd_coff_mkobject_hook(abfd, filehdr, aouthdr)\
- ((coff_backend_info (abfd)->_bfd_coff_mkobject_hook) (abfd, filehdr, aouthdr))
+ ((coff_backend_info (abfd)->_bfd_coff_mkobject_hook)\
+ (abfd, filehdr, aouthdr))
#define bfd_coff_styp_to_sec_flags_hook(abfd, scnhdr, name, section, flags_ptr)\
((coff_backend_info (abfd)->_bfd_styp_to_sec_flags_hook)\
@@ -891,7 +892,8 @@ typedef struct
((coff_backend_info (abfd)->_bfd_coff_print_aux)\
(abfd, file, base, symbol, aux, indaux))
-#define bfd_coff_reloc16_extra_cases(abfd, link_info, link_order, reloc, data, src_ptr, dst_ptr)\
+#define bfd_coff_reloc16_extra_cases(abfd, link_info, link_order,\
+ reloc, data, src_ptr, dst_ptr)\
((coff_backend_info (abfd)->_bfd_coff_reloc16_extra_cases)\
(abfd, link_info, link_order, reloc, data, src_ptr, dst_ptr))
@@ -919,7 +921,8 @@ typedef struct
#define bfd_coff_adjust_symndx(obfd, info, ibfd, sec, rel, adjustedp)\
((coff_backend_info (abfd)->_bfd_coff_adjust_symndx)\
(obfd, info, ibfd, sec, rel, adjustedp))
-#define bfd_coff_link_add_one_symbol(info,abfd,name,flags,section,value,string,cp,coll,hashp)\
+#define bfd_coff_link_add_one_symbol(info, abfd, name, flags, section,\
+ value, string, cp, coll, hashp)\
((coff_backend_info (abfd)->_bfd_coff_link_add_one_symbol)\
(info, abfd, name, flags, section, value, string, cp, coll, hashp))
diff --git a/contrib/binutils/bfd/libecoff.h b/contrib/binutils/bfd/libecoff.h
index eb90a8c..161f06c 100644
--- a/contrib/binutils/bfd/libecoff.h
+++ b/contrib/binutils/bfd/libecoff.h
@@ -1,5 +1,5 @@
/* BFD ECOFF object file private structure.
- Copyright 1993, 1994, 1995, 1996, 1999, 2001, 2002
+ Copyright 1993, 1994, 1995, 1996, 1999, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support.
@@ -44,10 +44,10 @@ struct ecoff_backend_data
/* The page boundary used to align sections in a demand-paged
executable file. E.g., 0x1000. */
bfd_vma round;
- /* True if the .rdata section is part of the text segment, as on the
- Alpha. False if .rdata is part of the data segment, as on the
+ /* TRUE if the .rdata section is part of the text segment, as on the
+ Alpha. FALSE if .rdata is part of the data segment, as on the
MIPS. */
- boolean rdata_in_text;
+ bfd_boolean rdata_in_text;
/* Bitsize of constructor entries. */
unsigned int constructor_bitsize;
/* Reloc to use for constructor entries. */
@@ -60,18 +60,18 @@ struct ecoff_backend_data
void (*swap_reloc_in) PARAMS ((bfd *, PTR, struct internal_reloc *));
void (*swap_reloc_out) PARAMS ((bfd *, const struct internal_reloc *, PTR));
/* Backend reloc tweaking. */
- void (*adjust_reloc_in) PARAMS ((bfd *, const struct internal_reloc *,
- arelent *));
- void (*adjust_reloc_out) PARAMS ((bfd *, const arelent *,
- struct internal_reloc *));
+ void (*adjust_reloc_in)
+ PARAMS ((bfd *, const struct internal_reloc *, arelent *));
+ void (*adjust_reloc_out)
+ PARAMS ((bfd *, const arelent *, struct internal_reloc *));
/* Relocate section contents while linking. */
- boolean (*relocate_section) PARAMS ((bfd *output_bfd, struct bfd_link_info *,
- bfd *input_bfd, asection *input_section,
- bfd_byte *contents,
- PTR external_relocs));
+ bfd_boolean (*relocate_section)
+ PARAMS ((bfd *output_bfd, struct bfd_link_info *, bfd *input_bfd,
+ asection *input_section, bfd_byte *contents,
+ PTR external_relocs));
/* Do final adjustments to filehdr and aouthdr. */
- boolean (*adjust_headers) PARAMS ((bfd *, struct internal_filehdr *,
- struct internal_aouthdr *));
+ bfd_boolean (*adjust_headers)
+ PARAMS ((bfd *, struct internal_filehdr *, struct internal_aouthdr *));
/* Read an element from an archive at a given file position. This
is needed because OSF/1 3.2 uses a weird archive format. */
bfd *(*get_elt_at_filepos) PARAMS ((bfd *, file_ptr));
@@ -128,12 +128,12 @@ typedef struct ecoff_tdata
linking. */
asection **symndx_to_section;
- /* True if this BFD was written by the backend linker. */
- boolean linker;
+ /* TRUE if this BFD was written by the backend linker. */
+ bfd_boolean linker;
- /* True if a warning that multiple global pointer values are
+ /* TRUE if a warning that multiple global pointer values are
needed in the output binary was issued already. */
- boolean issued_multiple_gp_warning;
+ bfd_boolean issued_multiple_gp_warning;
/* Used by find_nearest_line entry point. The structure could be
included directly in this one, but there's no point to wasting
@@ -143,7 +143,7 @@ typedef struct ecoff_tdata
/* Whether the .rdata section is in the text segment for this
particular ECOFF file. This is not valid until
ecoff_compute_section_file_positions is called. */
- boolean rdata_in_text;
+ bfd_boolean rdata_in_text;
} ecoff_data_type;
@@ -157,8 +157,8 @@ typedef struct ecoff_symbol_struct
/* The fdr for this symbol. */
FDR *fdr;
- /* true if this is a local symbol rather than an external one. */
- boolean local;
+ /* TRUE if this is a local symbol rather than an external one. */
+ bfd_boolean local;
/* A pointer to the unswapped hidden information for this symbol.
This is either a struct sym_ext or a struct ext_ext, depending on
@@ -249,27 +249,28 @@ struct ecoff_link_hash_table
};
/* Make an ECOFF object. */
-extern boolean _bfd_ecoff_mkobject PARAMS ((bfd *));
+extern bfd_boolean _bfd_ecoff_mkobject PARAMS ((bfd *));
/* Read in the ECOFF symbolic debugging information. */
-extern boolean _bfd_ecoff_slurp_symbolic_info
+extern bfd_boolean _bfd_ecoff_slurp_symbolic_info
PARAMS ((bfd *, asection *, struct ecoff_debug_info *));
/* Generic ECOFF BFD backend vectors. */
-extern boolean _bfd_ecoff_write_object_contents PARAMS ((bfd *abfd));
+extern bfd_boolean _bfd_ecoff_write_object_contents PARAMS ((bfd *abfd));
extern const bfd_target *_bfd_ecoff_archive_p PARAMS ((bfd *abfd));
#define _bfd_ecoff_close_and_cleanup _bfd_generic_close_and_cleanup
#define _bfd_ecoff_bfd_free_cached_info _bfd_generic_bfd_free_cached_info
-extern boolean _bfd_ecoff_new_section_hook
+extern bfd_boolean _bfd_ecoff_new_section_hook
PARAMS ((bfd *, asection *));
-extern boolean _bfd_ecoff_get_section_contents
+extern bfd_boolean _bfd_ecoff_get_section_contents
PARAMS ((bfd *, asection *, PTR location, file_ptr, bfd_size_type));
#define _bfd_ecoff_bfd_link_split_section _bfd_generic_link_split_section
-extern boolean _bfd_ecoff_bfd_copy_private_bfd_data PARAMS ((bfd *, bfd *));
+extern bfd_boolean _bfd_ecoff_bfd_copy_private_bfd_data
+ PARAMS ((bfd *, bfd *));
#define _bfd_ecoff_bfd_copy_private_section_data \
_bfd_generic_bfd_copy_private_section_data
@@ -283,12 +284,12 @@ extern boolean _bfd_ecoff_bfd_copy_private_bfd_data PARAMS ((bfd *, bfd *));
_bfd_generic_bfd_merge_private_bfd_data
#define _bfd_ecoff_bfd_set_private_flags _bfd_generic_bfd_set_private_flags
-extern boolean _bfd_ecoff_slurp_armap PARAMS ((bfd *abfd));
+extern bfd_boolean _bfd_ecoff_slurp_armap PARAMS ((bfd *abfd));
#define _bfd_ecoff_slurp_extended_name_table _bfd_slurp_extended_name_table
#define _bfd_ecoff_construct_extended_name_table \
_bfd_archive_bsd_construct_extended_name_table
#define _bfd_ecoff_truncate_arname bfd_dont_truncate_arname
-extern boolean _bfd_ecoff_write_armap
+extern bfd_boolean _bfd_ecoff_write_armap
PARAMS ((bfd *, unsigned int, struct orl *, unsigned int, int));
#define _bfd_ecoff_read_ar_hdr _bfd_generic_read_ar_hdr
#define _bfd_ecoff_openr_next_archived_file \
@@ -298,16 +299,16 @@ extern boolean _bfd_ecoff_write_armap
#define _bfd_ecoff_update_armap_timestamp bfd_true
extern long _bfd_ecoff_get_symtab_upper_bound PARAMS ((bfd *abfd));
-extern long _bfd_ecoff_get_symtab PARAMS ((bfd *abfd, asymbol **alocation));
+extern long _bfd_ecoff_canonicalize_symtab PARAMS ((bfd *abfd, asymbol **alocation));
extern asymbol *_bfd_ecoff_make_empty_symbol PARAMS ((bfd *abfd));
extern void _bfd_ecoff_print_symbol
PARAMS ((bfd *, PTR filep, asymbol *, bfd_print_symbol_type));
extern void _bfd_ecoff_get_symbol_info
PARAMS ((bfd *, asymbol *, symbol_info *));
-extern boolean _bfd_ecoff_bfd_is_local_label_name
+extern bfd_boolean _bfd_ecoff_bfd_is_local_label_name
PARAMS ((bfd *, const char *));
#define _bfd_ecoff_get_lineno _bfd_nosymbols_get_lineno
-extern boolean _bfd_ecoff_find_nearest_line
+extern bfd_boolean _bfd_ecoff_find_nearest_line
PARAMS ((bfd *, asection *, asymbol **, bfd_vma offset,
const char **filename_ptr, const char **fnname_ptr,
unsigned int *retline_ptr));
@@ -320,21 +321,21 @@ extern long _bfd_ecoff_canonicalize_reloc
PARAMS ((bfd *, asection *, arelent **, asymbol **symbols));
/* ecoff_bfd_reloc_type_lookup defined by backend. */
-extern boolean _bfd_ecoff_set_arch_mach
+extern bfd_boolean _bfd_ecoff_set_arch_mach
PARAMS ((bfd *, enum bfd_architecture, unsigned long));
-extern boolean _bfd_ecoff_set_section_contents
- PARAMS ((bfd *, asection *, PTR location, file_ptr, bfd_size_type));
+extern bfd_boolean _bfd_ecoff_set_section_contents
+ PARAMS ((bfd *, asection *, const PTR location, file_ptr, bfd_size_type));
-extern int _bfd_ecoff_sizeof_headers PARAMS ((bfd *abfd, boolean reloc));
+extern int _bfd_ecoff_sizeof_headers PARAMS ((bfd *abfd, bfd_boolean reloc));
/* ecoff_bfd_get_relocated_section_contents defined by backend. */
/* ecoff_bfd_relax_section defined by backend. */
extern struct bfd_link_hash_table *_bfd_ecoff_bfd_link_hash_table_create
PARAMS ((bfd *));
#define _bfd_ecoff_bfd_link_hash_table_free _bfd_generic_link_hash_table_free
-extern boolean _bfd_ecoff_bfd_link_add_symbols
+extern bfd_boolean _bfd_ecoff_bfd_link_add_symbols
PARAMS ((bfd *, struct bfd_link_info *));
#define _bfd_ecoff_bfd_link_just_syms _bfd_generic_link_just_syms
-extern boolean _bfd_ecoff_bfd_final_link
+extern bfd_boolean _bfd_ecoff_bfd_final_link
PARAMS ((bfd *, struct bfd_link_info *));
/* Hook functions for the generic COFF section reading code. */
@@ -342,10 +343,11 @@ extern boolean _bfd_ecoff_bfd_final_link
extern PTR _bfd_ecoff_mkobject_hook PARAMS ((bfd *, PTR filehdr, PTR aouthdr));
#define _bfd_ecoff_set_alignment_hook \
((void (*) PARAMS ((bfd *, asection *, PTR))) bfd_void)
-extern boolean _bfd_ecoff_set_arch_mach_hook PARAMS ((bfd *abfd, PTR filehdr));
-extern boolean _bfd_ecoff_styp_to_sec_flags
+extern bfd_boolean _bfd_ecoff_set_arch_mach_hook
+ PARAMS ((bfd *abfd, PTR filehdr));
+extern bfd_boolean _bfd_ecoff_styp_to_sec_flags
PARAMS ((bfd *, PTR, const char *, asection *, flagword *));
-extern boolean _bfd_ecoff_slurp_symbol_table PARAMS ((bfd *abfd));
+extern bfd_boolean _bfd_ecoff_slurp_symbol_table PARAMS ((bfd *abfd));
/* ECOFF auxiliary information swapping routines. These are the same
for all ECOFF targets, so they are defined in ecofflink.c. */
diff --git a/contrib/binutils/bfd/libieee.h b/contrib/binutils/bfd/libieee.h
index c48566c..56c7ce1 100644
--- a/contrib/binutils/bfd/libieee.h
+++ b/contrib/binutils/bfd/libieee.h
@@ -1,5 +1,5 @@
/* IEEE-695 object file formats: definitions internal to BFD.
- Copyright 1990, 1991, 1992, 1994, 1996, 2001
+ Copyright 1990, 1991, 1992, 1994, 1996, 2001, 2002
Free Software Foundation, Inc.
Written by Cygnus Support. Mostly Steve Chamberlain's fault.
@@ -56,7 +56,7 @@ typedef struct ieee_per_section
/* For output */
file_ptr current_pos;
unsigned int current_byte;
- boolean initialized;
+ bfd_boolean initialized;
ieee_reloc_type **reloc_tail_ptr;
} ieee_per_section_type;
@@ -72,8 +72,8 @@ typedef struct {
typedef struct ieee_data_struct
{
common_header_type h;
- boolean read_symbols;
- boolean read_data;
+ bfd_boolean read_symbols;
+ bfd_boolean read_data;
file_ptr output_cursor;
/* Map of section indexes to section ptrs */
asection **section_table;
@@ -103,10 +103,10 @@ typedef struct ieee_data_struct
int external_reference_base_offset;
- boolean symbol_table_full;
+ bfd_boolean symbol_table_full;
-boolean done_debug;
+bfd_boolean done_debug;
bfd_chain_type *chain_head;
diff --git a/contrib/binutils/bfd/libpei.h b/contrib/binutils/bfd/libpei.h
index 6b232b4..9ed9c12 100644
--- a/contrib/binutils/bfd/libpei.h
+++ b/contrib/binutils/bfd/libpei.h
@@ -1,31 +1,29 @@
/* Support for the generic parts of PE/PEI; common header information.
- Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001
+ Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Solutions.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-
-/*
-Most of this hacked by Steve Chamberlain,
+/* Most of this hacked by Steve Chamberlain,
sac@cygnus.com
-PE/PEI rearrangement (and code added): Donn Terry
- Softway Systems, Inc.
-*/
+ PE/PEI rearrangement (and code added): Donn Terry
+ Softway Systems, Inc. */
/* Hey look, some documentation [and in a place you expect to find it]!
@@ -53,8 +51,7 @@ PE/PEI rearrangement (and code added): Donn Terry
FIXME: Please add more docs here so the next poor fool that has to hack
on this code has a chance of getting something accomplished without
- wasting too much time.
-*/
+ wasting too much time. */
#ifndef GET_FCN_LNNOPTR
#define GET_FCN_LNNOPTR(abfd, ext) \
@@ -313,13 +310,13 @@ unsigned int _bfd_XXi_swap_aouthdr_out PARAMS ((bfd *, PTR, PTR));
unsigned int _bfd_XXi_swap_scnhdr_out PARAMS ((bfd *, PTR, PTR));
#define coff_swap_scnhdr_out _bfd_XXi_swap_scnhdr_out
-boolean _bfd_XX_print_private_bfd_data_common PARAMS ((bfd *, PTR));
+bfd_boolean _bfd_XX_print_private_bfd_data_common PARAMS ((bfd *, PTR));
-boolean _bfd_XX_bfd_copy_private_bfd_data_common PARAMS ((bfd *, bfd *));
+bfd_boolean _bfd_XX_bfd_copy_private_bfd_data_common PARAMS ((bfd *, bfd *));
void _bfd_XX_get_symbol_info PARAMS ((bfd *, asymbol *, symbol_info *));
-boolean _bfd_XXi_final_link_postscript
+bfd_boolean _bfd_XXi_final_link_postscript
PARAMS ((bfd *, struct coff_final_link_info *));
#ifndef coff_final_link_postscript
@@ -331,5 +328,10 @@ boolean _bfd_XXi_final_link_postscript
unsigned int _bfd_XX_only_swap_filehdr_out PARAMS ((bfd*, PTR, PTR));
unsigned int _bfd_XXi_only_swap_filehdr_out PARAMS ((bfd*, PTR, PTR));
-boolean _bfd_XX_bfd_copy_private_section_data
+bfd_boolean _bfd_XX_bfd_copy_private_section_data
PARAMS ((bfd *, asection *, bfd *, asection *));
+
+/* Macro: Returns true if the bfd is a PE executable as opposed to a PE object file. */
+#define bfd_pe_executable_p(abfd) \
+ (strncmp ((abfd)->xvec->name, "pei-", 4) == 0 \
+ || strncmp ((abfd)->xvec->name, "efi-app-", 8) == 0)
diff --git a/contrib/binutils/bfd/linker.c b/contrib/binutils/bfd/linker.c
index a5ded1f..58befc3 100644
--- a/contrib/binutils/bfd/linker.c
+++ b/contrib/binutils/bfd/linker.c
@@ -1,23 +1,23 @@
/* linker.c -- BFD linker routines
- Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
- Free Software Foundation, Inc.
+ Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+ 2003, 2004 Free Software Foundation, Inc.
Written by Steve Chamberlain and Ian Lance Taylor, Cygnus Support
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "bfd.h"
#include "sysdep.h"
@@ -88,7 +88,7 @@ SUBSECTION
For example, with each entry in the hash table the a.out
linker keeps the index the symbol has in the final output file
- (this index number is used so that when doing a relocateable
+ (this index number is used so that when doing a relocatable
link the symbol index used in the output file can be quickly
filled in when copying over a reloc). The a.out linker code
defines the required structures and functions for a hash table
@@ -200,7 +200,7 @@ SUBSUBSECTION
read the symbol information, the <<_bfd_link_add_symbols>>
routine should save it somewhere attached to the object file
BFD. However, the information should only be saved if the
- <<keep_memory>> field of the <<info>> argument is true, so
+ <<keep_memory>> field of the <<info>> argument is TRUE, so
that the <<-no-keep-memory>> linker switch is effective.
The a.out function which adds symbols from an object file is
@@ -277,7 +277,7 @@ SUBSECTION
the input sections and copy the data into the output sections.
It must build an output symbol table including any local
symbols from the input files and the global symbols from the
- hash table. When producing relocateable output, it must
+ hash table. When producing relocatable output, it must
modify the input relocs and write them into the output file.
There may also be object format dependent work to be done.
@@ -317,7 +317,7 @@ SUBSUBSECTION
types of information. They also describe relocs that must be
created by the BFD backend, but do not correspond to any input
file; this is used to support -Ur, which builds constructors
- while generating a relocateable object file.
+ while generating a relocatable object file.
INODE
Relocating the section contents, Writing the symbol table, Information provided by the linker, Performing the Final Link
@@ -339,7 +339,7 @@ SUBSUBSECTION
input files. The <<_bfd_final_link>> function should read the
contents of the section and any associated relocs, apply the
relocs to the section contents, and write out the modified
- section contents. If performing a relocateable link, the
+ section contents. If performing a relocatable link, the
relocs themselves must also be modified and written out.
@findex _bfd_relocate_contents
@@ -406,32 +406,26 @@ SUBSUBSECTION
file at the end of <<NAME(aout,final_link)>>.
*/
-static boolean generic_link_read_symbols
- PARAMS ((bfd *));
-static boolean generic_link_add_symbols
- PARAMS ((bfd *, struct bfd_link_info *, boolean collect));
-static boolean generic_link_add_object_symbols
- PARAMS ((bfd *, struct bfd_link_info *, boolean collect));
-static boolean generic_link_check_archive_element_no_collect
- PARAMS ((bfd *, struct bfd_link_info *, boolean *pneeded));
-static boolean generic_link_check_archive_element_collect
- PARAMS ((bfd *, struct bfd_link_info *, boolean *pneeded));
-static boolean generic_link_check_archive_element
- PARAMS ((bfd *, struct bfd_link_info *, boolean *pneeded, boolean collect));
-static boolean generic_link_add_symbol_list
- PARAMS ((bfd *, struct bfd_link_info *, bfd_size_type count, asymbol **,
- boolean collect));
-static bfd *hash_entry_bfd PARAMS ((struct bfd_link_hash_entry *));
-static void set_symbol_from_hash
- PARAMS ((asymbol *, struct bfd_link_hash_entry *));
-static boolean generic_add_output_symbol
- PARAMS ((bfd *, size_t *psymalloc, asymbol *));
-static boolean default_data_link_order
- PARAMS ((bfd *, struct bfd_link_info *, asection *,
- struct bfd_link_order *));
-static boolean default_indirect_link_order
- PARAMS ((bfd *, struct bfd_link_info *, asection *,
- struct bfd_link_order *, boolean));
+static bfd_boolean generic_link_add_object_symbols
+ (bfd *, struct bfd_link_info *, bfd_boolean collect);
+static bfd_boolean generic_link_add_symbols
+ (bfd *, struct bfd_link_info *, bfd_boolean);
+static bfd_boolean generic_link_check_archive_element_no_collect
+ (bfd *, struct bfd_link_info *, bfd_boolean *);
+static bfd_boolean generic_link_check_archive_element_collect
+ (bfd *, struct bfd_link_info *, bfd_boolean *);
+static bfd_boolean generic_link_check_archive_element
+ (bfd *, struct bfd_link_info *, bfd_boolean *, bfd_boolean);
+static bfd_boolean generic_link_add_symbol_list
+ (bfd *, struct bfd_link_info *, bfd_size_type count, asymbol **,
+ bfd_boolean);
+static bfd_boolean generic_add_output_symbol
+ (bfd *, size_t *psymalloc, asymbol *);
+static bfd_boolean default_data_link_order
+ (bfd *, struct bfd_link_info *, asection *, struct bfd_link_order *);
+static bfd_boolean default_indirect_link_order
+ (bfd *, struct bfd_link_info *, asection *, struct bfd_link_order *,
+ bfd_boolean);
/* The link hash table structure is defined in bfdlink.h. It provides
a base hash table which the backend specific hash tables are built
@@ -440,17 +434,15 @@ static boolean default_indirect_link_order
/* Routine to create an entry in the link hash table. */
struct bfd_hash_entry *
-_bfd_link_hash_newfunc (entry, table, string)
- struct bfd_hash_entry *entry;
- struct bfd_hash_table *table;
- const char *string;
+_bfd_link_hash_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table,
+ const char *string)
{
/* Allocate the structure if it has not already been allocated by a
subclass. */
if (entry == NULL)
{
- entry = (struct bfd_hash_entry *)
- bfd_hash_allocate (table, sizeof (struct bfd_link_hash_entry));
+ entry = bfd_hash_allocate (table, sizeof (struct bfd_link_hash_entry));
if (entry == NULL)
return entry;
}
@@ -463,7 +455,7 @@ _bfd_link_hash_newfunc (entry, table, string)
/* Initialize the local fields. */
h->type = bfd_link_hash_new;
- h->next = NULL;
+ h->und_next = NULL;
}
return entry;
@@ -472,13 +464,13 @@ _bfd_link_hash_newfunc (entry, table, string)
/* Initialize a link hash table. The BFD argument is the one
responsible for creating this table. */
-boolean
-_bfd_link_hash_table_init (table, abfd, newfunc)
- struct bfd_link_hash_table *table;
- bfd *abfd;
- struct bfd_hash_entry *(*newfunc) PARAMS ((struct bfd_hash_entry *,
- struct bfd_hash_table *,
- const char *));
+bfd_boolean
+_bfd_link_hash_table_init
+ (struct bfd_link_hash_table *table,
+ bfd *abfd,
+ struct bfd_hash_entry *(*newfunc) (struct bfd_hash_entry *,
+ struct bfd_hash_table *,
+ const char *))
{
table->creator = abfd->xvec;
table->undefs = NULL;
@@ -488,24 +480,23 @@ _bfd_link_hash_table_init (table, abfd, newfunc)
return bfd_hash_table_init (&table->table, newfunc);
}
-/* Look up a symbol in a link hash table. If follow is true, we
+/* Look up a symbol in a link hash table. If follow is TRUE, we
follow bfd_link_hash_indirect and bfd_link_hash_warning links to
the real symbol. */
struct bfd_link_hash_entry *
-bfd_link_hash_lookup (table, string, create, copy, follow)
- struct bfd_link_hash_table *table;
- const char *string;
- boolean create;
- boolean copy;
- boolean follow;
+bfd_link_hash_lookup (struct bfd_link_hash_table *table,
+ const char *string,
+ bfd_boolean create,
+ bfd_boolean copy,
+ bfd_boolean follow)
{
struct bfd_link_hash_entry *ret;
ret = ((struct bfd_link_hash_entry *)
bfd_hash_lookup (&table->table, string, create, copy));
- if (follow && ret != (struct bfd_link_hash_entry *) NULL)
+ if (follow && ret != NULL)
{
while (ret->type == bfd_link_hash_indirect
|| ret->type == bfd_link_hash_warning)
@@ -520,28 +511,31 @@ bfd_link_hash_lookup (table, string, create, copy, follow)
undefined symbol, not for definitions of a symbol. */
struct bfd_link_hash_entry *
-bfd_wrapped_link_hash_lookup (abfd, info, string, create, copy, follow)
- bfd *abfd;
- struct bfd_link_info *info;
- const char *string;
- boolean create;
- boolean copy;
- boolean follow;
+bfd_wrapped_link_hash_lookup (bfd *abfd,
+ struct bfd_link_info *info,
+ const char *string,
+ bfd_boolean create,
+ bfd_boolean copy,
+ bfd_boolean follow)
{
bfd_size_type amt;
if (info->wrap_hash != NULL)
{
const char *l;
+ char prefix = '\0';
l = string;
- if (*l == bfd_get_symbol_leading_char (abfd))
- ++l;
+ if (*l == bfd_get_symbol_leading_char (abfd) || *l == info->wrap_char)
+ {
+ prefix = *l;
+ ++l;
+ }
#undef WRAP
#define WRAP "__wrap_"
- if (bfd_hash_lookup (info->wrap_hash, l, false, false) != NULL)
+ if (bfd_hash_lookup (info->wrap_hash, l, FALSE, FALSE) != NULL)
{
char *n;
struct bfd_link_hash_entry *h;
@@ -550,16 +544,15 @@ bfd_wrapped_link_hash_lookup (abfd, info, string, create, copy, follow)
references to SYM with references to __wrap_SYM. */
amt = strlen (l) + sizeof WRAP + 1;
- n = (char *) bfd_malloc (amt);
+ n = bfd_malloc (amt);
if (n == NULL)
return NULL;
- /* Note that symbol_leading_char may be '\0'. */
- n[0] = bfd_get_symbol_leading_char (abfd);
+ n[0] = prefix;
n[1] = '\0';
strcat (n, WRAP);
strcat (n, l);
- h = bfd_link_hash_lookup (info->hash, n, create, true, follow);
+ h = bfd_link_hash_lookup (info->hash, n, create, TRUE, follow);
free (n);
return h;
}
@@ -572,7 +565,7 @@ bfd_wrapped_link_hash_lookup (abfd, info, string, create, copy, follow)
if (*l == '_'
&& strncmp (l, REAL, sizeof REAL - 1) == 0
&& bfd_hash_lookup (info->wrap_hash, l + sizeof REAL - 1,
- false, false) != NULL)
+ FALSE, FALSE) != NULL)
{
char *n;
struct bfd_link_hash_entry *h;
@@ -582,15 +575,14 @@ bfd_wrapped_link_hash_lookup (abfd, info, string, create, copy, follow)
with references to SYM. */
amt = strlen (l + sizeof REAL - 1) + 2;
- n = (char *) bfd_malloc (amt);
+ n = bfd_malloc (amt);
if (n == NULL)
return NULL;
- /* Note that symbol_leading_char may be '\0'. */
- n[0] = bfd_get_symbol_leading_char (abfd);
+ n[0] = prefix;
n[1] = '\0';
strcat (n, l + sizeof REAL - 1);
- h = bfd_link_hash_lookup (info->hash, n, create, true, follow);
+ h = bfd_link_hash_lookup (info->hash, n, create, TRUE, follow);
free (n);
return h;
}
@@ -608,45 +600,42 @@ bfd_wrapped_link_hash_lookup (abfd, info, string, create, copy, follow)
call. */
void
-bfd_link_hash_traverse (table, func, info)
- struct bfd_link_hash_table *table;
- boolean (*func) PARAMS ((struct bfd_link_hash_entry *, PTR));
- PTR info;
+bfd_link_hash_traverse
+ (struct bfd_link_hash_table *table,
+ bfd_boolean (*func) (struct bfd_link_hash_entry *, void *),
+ void *info)
{
bfd_hash_traverse (&table->table,
- ((boolean (*) PARAMS ((struct bfd_hash_entry *, PTR)))
- func),
+ (bfd_boolean (*) (struct bfd_hash_entry *, void *)) func,
info);
}
/* Add a symbol to the linker hash table undefs list. */
-INLINE void
-bfd_link_add_undef (table, h)
- struct bfd_link_hash_table *table;
- struct bfd_link_hash_entry *h;
+void
+bfd_link_add_undef (struct bfd_link_hash_table *table,
+ struct bfd_link_hash_entry *h)
{
- BFD_ASSERT (h->next == NULL);
- if (table->undefs_tail != (struct bfd_link_hash_entry *) NULL)
- table->undefs_tail->next = h;
- if (table->undefs == (struct bfd_link_hash_entry *) NULL)
+ BFD_ASSERT (h->und_next == NULL);
+ if (table->undefs_tail != NULL)
+ table->undefs_tail->und_next = h;
+ if (table->undefs == NULL)
table->undefs = h;
table->undefs_tail = h;
}
-/* Routine to create an entry in an generic link hash table. */
+/* Routine to create an entry in a generic link hash table. */
struct bfd_hash_entry *
-_bfd_generic_link_hash_newfunc (entry, table, string)
- struct bfd_hash_entry *entry;
- struct bfd_hash_table *table;
- const char *string;
+_bfd_generic_link_hash_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table,
+ const char *string)
{
/* Allocate the structure if it has not already been allocated by a
subclass. */
if (entry == NULL)
{
- entry = (struct bfd_hash_entry *)
+ entry =
bfd_hash_allocate (table, sizeof (struct generic_link_hash_entry));
if (entry == NULL)
return entry;
@@ -660,37 +649,35 @@ _bfd_generic_link_hash_newfunc (entry, table, string)
/* Set local fields. */
ret = (struct generic_link_hash_entry *) entry;
- ret->written = false;
+ ret->written = FALSE;
ret->sym = NULL;
}
return entry;
}
-/* Create an generic link hash table. */
+/* Create a generic link hash table. */
struct bfd_link_hash_table *
-_bfd_generic_link_hash_table_create (abfd)
- bfd *abfd;
+_bfd_generic_link_hash_table_create (bfd *abfd)
{
struct generic_link_hash_table *ret;
bfd_size_type amt = sizeof (struct generic_link_hash_table);
- ret = (struct generic_link_hash_table *) bfd_malloc (amt);
+ ret = bfd_malloc (amt);
if (ret == NULL)
- return (struct bfd_link_hash_table *) NULL;
+ return NULL;
if (! _bfd_link_hash_table_init (&ret->root, abfd,
_bfd_generic_link_hash_newfunc))
{
free (ret);
- return (struct bfd_link_hash_table *) NULL;
+ return NULL;
}
return &ret->root;
}
void
-_bfd_generic_link_hash_table_free (hash)
- struct bfd_link_hash_table *hash;
+_bfd_generic_link_hash_table_free (struct bfd_link_hash_table *hash)
{
struct generic_link_hash_table *ret
= (struct generic_link_hash_table *) hash;
@@ -706,41 +693,37 @@ _bfd_generic_link_hash_table_free (hash)
the hash table pointing to different instances of the symbol
structure. */
-static boolean
-generic_link_read_symbols (abfd)
- bfd *abfd;
+static bfd_boolean
+generic_link_read_symbols (bfd *abfd)
{
- if (bfd_get_outsymbols (abfd) == (asymbol **) NULL)
+ if (bfd_get_outsymbols (abfd) == NULL)
{
long symsize;
long symcount;
symsize = bfd_get_symtab_upper_bound (abfd);
if (symsize < 0)
- return false;
- bfd_get_outsymbols (abfd) =
- (asymbol **) bfd_alloc (abfd, (bfd_size_type) symsize);
+ return FALSE;
+ bfd_get_outsymbols (abfd) = bfd_alloc (abfd, symsize);
if (bfd_get_outsymbols (abfd) == NULL && symsize != 0)
- return false;
+ return FALSE;
symcount = bfd_canonicalize_symtab (abfd, bfd_get_outsymbols (abfd));
if (symcount < 0)
- return false;
+ return FALSE;
bfd_get_symcount (abfd) = symcount;
}
- return true;
+ return TRUE;
}
/* Generic function to add symbols to from an object file to the
global hash table. This version does not automatically collect
constructors by name. */
-boolean
-_bfd_generic_link_add_symbols (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info;
+bfd_boolean
+_bfd_generic_link_add_symbols (bfd *abfd, struct bfd_link_info *info)
{
- return generic_link_add_symbols (abfd, info, false);
+ return generic_link_add_symbols (abfd, info, FALSE);
}
/* Generic function to add symbols from an object file to the global
@@ -750,12 +733,10 @@ _bfd_generic_link_add_symbols (abfd, info)
constructors and destructors; these are approximately those targets
for which gcc uses collect2 and do not support stabs. */
-boolean
-_bfd_generic_link_add_symbols_collect (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info;
+bfd_boolean
+_bfd_generic_link_add_symbols_collect (bfd *abfd, struct bfd_link_info *info)
{
- return generic_link_add_symbols (abfd, info, true);
+ return generic_link_add_symbols (abfd, info, TRUE);
}
/* Indicate that we are only retrieving symbol values from this
@@ -763,9 +744,8 @@ _bfd_generic_link_add_symbols_collect (abfd, info)
file are absolute. */
void
-_bfd_generic_link_just_syms (sec, info)
- asection *sec;
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
+_bfd_generic_link_just_syms (asection *sec,
+ struct bfd_link_info *info ATTRIBUTE_UNUSED)
{
sec->output_section = bfd_abs_section_ptr;
sec->output_offset = sec->vma;
@@ -773,13 +753,12 @@ _bfd_generic_link_just_syms (sec, info)
/* Add symbols from an object file to the global hash table. */
-static boolean
-generic_link_add_symbols (abfd, info, collect)
- bfd *abfd;
- struct bfd_link_info *info;
- boolean collect;
+static bfd_boolean
+generic_link_add_symbols (bfd *abfd,
+ struct bfd_link_info *info,
+ bfd_boolean collect)
{
- boolean ret;
+ bfd_boolean ret;
switch (bfd_get_format (abfd))
{
@@ -795,7 +774,7 @@ generic_link_add_symbols (abfd, info, collect)
break;
default:
bfd_set_error (bfd_error_wrong_format);
- ret = false;
+ ret = FALSE;
}
return ret;
@@ -803,17 +782,16 @@ generic_link_add_symbols (abfd, info, collect)
/* Add symbols from an object file to the global hash table. */
-static boolean
-generic_link_add_object_symbols (abfd, info, collect)
- bfd *abfd;
- struct bfd_link_info *info;
- boolean collect;
+static bfd_boolean
+generic_link_add_object_symbols (bfd *abfd,
+ struct bfd_link_info *info,
+ bfd_boolean collect)
{
bfd_size_type symcount;
- struct symbol_cache_entry **outsyms;
+ struct bfd_symbol **outsyms;
if (! generic_link_read_symbols (abfd))
- return false;
+ return FALSE;
symcount = _bfd_generic_link_get_symcount (abfd);
outsyms = _bfd_generic_link_get_symbols (abfd);
return generic_link_add_symbol_list (abfd, info, symcount, outsyms, collect);
@@ -846,30 +824,20 @@ struct archive_hash_table
struct bfd_hash_table table;
};
-static struct bfd_hash_entry *archive_hash_newfunc
- PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-static boolean archive_hash_table_init
- PARAMS ((struct archive_hash_table *,
- struct bfd_hash_entry *(*) (struct bfd_hash_entry *,
- struct bfd_hash_table *,
- const char *)));
-
/* Create a new entry for an archive hash table. */
static struct bfd_hash_entry *
-archive_hash_newfunc (entry, table, string)
- struct bfd_hash_entry *entry;
- struct bfd_hash_table *table;
- const char *string;
+archive_hash_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table,
+ const char *string)
{
struct archive_hash_entry *ret = (struct archive_hash_entry *) entry;
/* Allocate the structure if it has not already been allocated by a
subclass. */
- if (ret == (struct archive_hash_entry *) NULL)
- ret = ((struct archive_hash_entry *)
- bfd_hash_allocate (table, sizeof (struct archive_hash_entry)));
- if (ret == (struct archive_hash_entry *) NULL)
+ if (ret == NULL)
+ ret = bfd_hash_allocate (table, sizeof (struct archive_hash_entry));
+ if (ret == NULL)
return NULL;
/* Call the allocation method of the superclass. */
@@ -879,20 +847,20 @@ archive_hash_newfunc (entry, table, string)
if (ret)
{
/* Initialize the local fields. */
- ret->defs = (struct archive_list *) NULL;
+ ret->defs = NULL;
}
- return (struct bfd_hash_entry *) ret;
+ return &ret->root;
}
/* Initialize an archive hash table. */
-static boolean
-archive_hash_table_init (table, newfunc)
- struct archive_hash_table *table;
- struct bfd_hash_entry *(*newfunc) PARAMS ((struct bfd_hash_entry *,
- struct bfd_hash_table *,
- const char *));
+static bfd_boolean
+archive_hash_table_init
+ (struct archive_hash_table *table,
+ struct bfd_hash_entry *(*newfunc) (struct bfd_hash_entry *,
+ struct bfd_hash_table *,
+ const char *))
{
return bfd_hash_table_init (&table->table, newfunc);
}
@@ -927,10 +895,10 @@ archive_hash_table_init (table, newfunc)
re-search the symbol table each time a new object file was added.
The CHECKFN argument is used to see if an object file should be
- included. CHECKFN should set *PNEEDED to true if the object file
+ included. CHECKFN should set *PNEEDED to TRUE if the object file
should be included, and must also call the bfd_link_info
add_archive_element callback function and handle adding the symbols
- to the global hash table. CHECKFN should only return false if some
+ to the global hash table. CHECKFN should only return FALSE if some
sort of error occurs.
For some formats, such as a.out, it is possible to look through an
@@ -944,12 +912,11 @@ archive_hash_table_init (table, newfunc)
may create new undefined symbols which cause a previously examined
object file to be included. */
-boolean
-_bfd_generic_link_add_archive_symbols (abfd, info, checkfn)
- bfd *abfd;
- struct bfd_link_info *info;
- boolean (*checkfn) PARAMS ((bfd *, struct bfd_link_info *,
- boolean *pneeded));
+bfd_boolean
+_bfd_generic_link_add_archive_symbols
+ (bfd *abfd,
+ struct bfd_link_info *info,
+ bfd_boolean (*checkfn) (bfd *, struct bfd_link_info *, bfd_boolean *))
{
carsym *arsyms;
carsym *arsym_end;
@@ -962,10 +929,10 @@ _bfd_generic_link_add_archive_symbols (abfd, info, checkfn)
if (! bfd_has_map (abfd))
{
/* An empty archive is a special case. */
- if (bfd_openr_next_archived_file (abfd, (bfd *) NULL) == NULL)
- return true;
+ if (bfd_openr_next_archived_file (abfd, NULL) == NULL)
+ return TRUE;
bfd_set_error (bfd_error_no_armap);
- return false;
+ return FALSE;
}
arsyms = bfd_ardata (abfd)->symdefs;
@@ -974,23 +941,21 @@ _bfd_generic_link_add_archive_symbols (abfd, info, checkfn)
/* In order to quickly determine whether an symbol is defined in
this archive, we build a hash table of the symbols. */
if (! archive_hash_table_init (&arsym_hash, archive_hash_newfunc))
- return false;
+ return FALSE;
for (arsym = arsyms, indx = 0; arsym < arsym_end; arsym++, indx++)
{
struct archive_hash_entry *arh;
struct archive_list *l, **pp;
- arh = archive_hash_lookup (&arsym_hash, arsym->name, true, false);
- if (arh == (struct archive_hash_entry *) NULL)
+ arh = archive_hash_lookup (&arsym_hash, arsym->name, TRUE, FALSE);
+ if (arh == NULL)
goto error_return;
l = ((struct archive_list *)
archive_hash_allocate (&arsym_hash, sizeof (struct archive_list)));
if (l == NULL)
goto error_return;
l->indx = indx;
- for (pp = &arh->defs;
- *pp != (struct archive_list *) NULL;
- pp = &(*pp)->next)
+ for (pp = &arh->defs; *pp != NULL; pp = &(*pp)->next)
;
*pp = l;
l->next = NULL;
@@ -1004,7 +969,7 @@ _bfd_generic_link_add_archive_symbols (abfd, info, checkfn)
/* New undefined symbols are added to the end of the list, so we
only need to look through it once. */
pundef = &info->hash->undefs;
- while (*pundef != (struct bfd_link_hash_entry *) NULL)
+ while (*pundef != NULL)
{
struct bfd_link_hash_entry *h;
struct archive_hash_entry *arh;
@@ -1025,40 +990,40 @@ _bfd_generic_link_add_archive_symbols (abfd, info, checkfn)
us to lose track of whether the symbol has been
referenced). */
if (*pundef != info->hash->undefs_tail)
- *pundef = (*pundef)->next;
+ *pundef = (*pundef)->und_next;
else
- pundef = &(*pundef)->next;
+ pundef = &(*pundef)->und_next;
continue;
}
/* Look for this symbol in the archive symbol map. */
- arh = archive_hash_lookup (&arsym_hash, h->root.string, false, false);
- if (arh == (struct archive_hash_entry *) NULL)
+ arh = archive_hash_lookup (&arsym_hash, h->root.string, FALSE, FALSE);
+ if (arh == NULL)
{
/* If we haven't found the exact symbol we're looking for,
let's look for its import thunk */
if (info->pei386_auto_import)
{
bfd_size_type amt = strlen (h->root.string) + 10;
- char *buf = (char *) bfd_malloc (amt);
+ char *buf = bfd_malloc (amt);
if (buf == NULL)
- return false;
+ return FALSE;
sprintf (buf, "__imp_%s", h->root.string);
- arh = archive_hash_lookup (&arsym_hash, buf, false, false);
+ arh = archive_hash_lookup (&arsym_hash, buf, FALSE, FALSE);
free(buf);
}
- if (arh == (struct archive_hash_entry *) NULL)
+ if (arh == NULL)
{
- pundef = &(*pundef)->next;
+ pundef = &(*pundef)->und_next;
continue;
}
}
/* Look at all the objects which define this symbol. */
- for (l = arh->defs; l != (struct archive_list *) NULL; l = l->next)
+ for (l = arh->defs; l != NULL; l = l->next)
{
bfd *element;
- boolean needed;
+ bfd_boolean needed;
/* If the symbol has gotten defined along the way, quit. */
if (h->type != bfd_link_hash_undefined
@@ -1066,7 +1031,7 @@ _bfd_generic_link_add_archive_symbols (abfd, info, checkfn)
break;
element = bfd_get_elt_at_index (abfd, l->indx);
- if (element == (bfd *) NULL)
+ if (element == NULL)
goto error_return;
/* If we've already included this element, or if we've
@@ -1099,7 +1064,7 @@ _bfd_generic_link_add_archive_symbols (abfd, info, checkfn)
}
}
- pundef = &(*pundef)->next;
+ pundef = &(*pundef)->und_next;
}
archive_hash_table_free (&arsym_hash);
@@ -1107,11 +1072,11 @@ _bfd_generic_link_add_archive_symbols (abfd, info, checkfn)
/* Save PASS in case we are called again. */
abfd->archive_pass = pass;
- return true;
+ return TRUE;
error_return:
archive_hash_table_free (&arsym_hash);
- return false;
+ return FALSE;
}
/* See if we should include an archive element. This version is used
@@ -1119,44 +1084,42 @@ _bfd_generic_link_add_archive_symbols (abfd, info, checkfn)
the symbol name, presumably because we have some other mechanism
for finding them. */
-static boolean
-generic_link_check_archive_element_no_collect (abfd, info, pneeded)
- bfd *abfd;
- struct bfd_link_info *info;
- boolean *pneeded;
+static bfd_boolean
+generic_link_check_archive_element_no_collect (
+ bfd *abfd,
+ struct bfd_link_info *info,
+ bfd_boolean *pneeded)
{
- return generic_link_check_archive_element (abfd, info, pneeded, false);
+ return generic_link_check_archive_element (abfd, info, pneeded, FALSE);
}
/* See if we should include an archive element. This version is used
when we want to automatically collect constructors based on the
symbol name, as collect2 does. */
-static boolean
-generic_link_check_archive_element_collect (abfd, info, pneeded)
- bfd *abfd;
- struct bfd_link_info *info;
- boolean *pneeded;
+static bfd_boolean
+generic_link_check_archive_element_collect (bfd *abfd,
+ struct bfd_link_info *info,
+ bfd_boolean *pneeded)
{
- return generic_link_check_archive_element (abfd, info, pneeded, true);
+ return generic_link_check_archive_element (abfd, info, pneeded, TRUE);
}
/* See if we should include an archive element. Optionally collect
constructors. */
-static boolean
-generic_link_check_archive_element (abfd, info, pneeded, collect)
- bfd *abfd;
- struct bfd_link_info *info;
- boolean *pneeded;
- boolean collect;
+static bfd_boolean
+generic_link_check_archive_element (bfd *abfd,
+ struct bfd_link_info *info,
+ bfd_boolean *pneeded,
+ bfd_boolean collect)
{
asymbol **pp, **ppend;
- *pneeded = false;
+ *pneeded = FALSE;
if (! generic_link_read_symbols (abfd))
- return false;
+ return FALSE;
pp = _bfd_generic_link_get_symbols (abfd);
ppend = pp + _bfd_generic_link_get_symcount (abfd);
@@ -1177,9 +1140,9 @@ generic_link_check_archive_element (abfd, info, pneeded, collect)
symbol (type bfd_link_hash_undefweak) is not considered to be
a reference when pulling files out of an archive. See the
SVR4 ABI, p. 4-27. */
- h = bfd_link_hash_lookup (info->hash, bfd_asymbol_name (p), false,
- false, true);
- if (h == (struct bfd_link_hash_entry *) NULL
+ h = bfd_link_hash_lookup (info->hash, bfd_asymbol_name (p), FALSE,
+ FALSE, TRUE);
+ if (h == NULL
|| (h->type != bfd_link_hash_undefined
&& h->type != bfd_link_hash_common))
continue;
@@ -1194,14 +1157,14 @@ generic_link_check_archive_element (abfd, info, pneeded, collect)
/* This object file defines this symbol, so pull it in. */
if (! (*info->callbacks->add_archive_element) (info, abfd,
bfd_asymbol_name (p)))
- return false;
+ return FALSE;
symcount = _bfd_generic_link_get_symcount (abfd);
symbols = _bfd_generic_link_get_symbols (abfd);
if (! generic_link_add_symbol_list (abfd, info, symcount,
symbols, collect))
- return false;
- *pneeded = true;
- return true;
+ return FALSE;
+ *pneeded = TRUE;
+ return TRUE;
}
/* P is a common symbol. */
@@ -1213,16 +1176,16 @@ generic_link_check_archive_element (abfd, info, pneeded, collect)
unsigned int power;
symbfd = h->u.undef.abfd;
- if (symbfd == (bfd *) NULL)
+ if (symbfd == NULL)
{
/* This symbol was created as undefined from outside
BFD. We assume that we should link in the object
file. This is for the -u option in the linker. */
if (! (*info->callbacks->add_archive_element)
(info, abfd, bfd_asymbol_name (p)))
- return false;
- *pneeded = true;
- return true;
+ return FALSE;
+ *pneeded = TRUE;
+ return TRUE;
}
/* Turn the symbol into a common symbol but do not link in
@@ -1234,11 +1197,10 @@ generic_link_check_archive_element (abfd, info, pneeded, collect)
will be linked in. */
h->type = bfd_link_hash_common;
h->u.c.p =
- ((struct bfd_link_hash_common_entry *)
- bfd_hash_allocate (&info->hash->table,
- sizeof (struct bfd_link_hash_common_entry)));
+ bfd_hash_allocate (&info->hash->table,
+ sizeof (struct bfd_link_hash_common_entry));
if (h->u.c.p == NULL)
- return false;
+ return FALSE;
size = bfd_asymbol_value (p);
h->u.c.size = size;
@@ -1267,22 +1229,21 @@ generic_link_check_archive_element (abfd, info, pneeded, collect)
}
/* This archive element is not needed. */
- return true;
+ return TRUE;
}
/* Add the symbols from an object file to the global hash table. ABFD
is the object file. INFO is the linker information. SYMBOL_COUNT
is the number of symbols. SYMBOLS is the list of symbols. COLLECT
- is true if constructors should be automatically collected by name
+ is TRUE if constructors should be automatically collected by name
as is done by collect2. */
-static boolean
-generic_link_add_symbol_list (abfd, info, symbol_count, symbols, collect)
- bfd *abfd;
- struct bfd_link_info *info;
- bfd_size_type symbol_count;
- asymbol **symbols;
- boolean collect;
+static bfd_boolean
+generic_link_add_symbol_list (bfd *abfd,
+ struct bfd_link_info *info,
+ bfd_size_type symbol_count,
+ asymbol **symbols,
+ bfd_boolean collect)
{
asymbol **pp, **ppend;
@@ -1331,8 +1292,8 @@ generic_link_add_symbol_list (abfd, info, symbol_count, symbols, collect)
bh = NULL;
if (! (_bfd_generic_link_add_one_symbol
(info, abfd, name, p->flags, bfd_get_section (p),
- p->value, string, false, collect, &bh)))
- return false;
+ p->value, string, FALSE, collect, &bh)))
+ return FALSE;
h = (struct generic_link_hash_entry *) bh;
/* If this is a constructor symbol, and the linker didn't do
@@ -1356,7 +1317,7 @@ generic_link_add_symbol_list (abfd, info, symbol_count, symbols, collect)
generic one. */
if (info->hash->creator == abfd->xvec)
{
- if (h->sym == (asymbol *) NULL
+ if (h->sym == NULL
|| (! bfd_is_und_section (bfd_get_section (p))
&& (! bfd_is_com_section (bfd_get_section (p))
|| bfd_is_und_section (bfd_get_section (h->sym)))))
@@ -1375,11 +1336,11 @@ generic_link_add_symbol_list (abfd, info, symbol_count, symbols, collect)
it gets rewritten to not use asymbol structures.
Setting this is also used to check whether these
symbols were set up by the generic linker. */
- p->udata.p = (PTR) h;
+ p->udata.p = h;
}
}
- return true;
+ return TRUE;
}
/* We use a state table to deal with adding symbols from an object
@@ -1475,8 +1436,7 @@ static const enum link_action link_action[8][8] =
/* Return the BFD in which a hash entry has been defined, if known. */
static bfd *
-hash_entry_bfd (h)
- struct bfd_link_hash_entry *h;
+hash_entry_bfd (struct bfd_link_hash_entry *h)
{
while (h->type == bfd_link_hash_warning)
h = h->u.i.link;
@@ -1506,31 +1466,29 @@ hash_entry_bfd (h)
STRING is used for either an indirect symbol, in which case it is
the name of the symbol to indirect to, or a warning symbol, in
which case it is the warning string.
- COPY is true if NAME or STRING must be copied into locally
+ COPY is TRUE if NAME or STRING must be copied into locally
allocated memory if they need to be saved.
- COLLECT is true if we should automatically collect gcc constructor
+ COLLECT is TRUE if we should automatically collect gcc constructor
or destructor names as collect2 does.
HASHP, if not NULL, is a place to store the created hash table
entry; if *HASHP is not NULL, the caller has already looked up
the hash table entry, and stored it in *HASHP. */
-boolean
-_bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
- string, copy, collect, hashp)
- struct bfd_link_info *info;
- bfd *abfd;
- const char *name;
- flagword flags;
- asection *section;
- bfd_vma value;
- const char *string;
- boolean copy;
- boolean collect;
- struct bfd_link_hash_entry **hashp;
+bfd_boolean
+_bfd_generic_link_add_one_symbol (struct bfd_link_info *info,
+ bfd *abfd,
+ const char *name,
+ flagword flags,
+ asection *section,
+ bfd_vma value,
+ const char *string,
+ bfd_boolean copy,
+ bfd_boolean collect,
+ struct bfd_link_hash_entry **hashp)
{
enum link_row row;
struct bfd_link_hash_entry *h;
- boolean cycle;
+ bfd_boolean cycle;
if (bfd_is_ind_section (section)
|| (flags & BSF_INDIRECT) != 0)
@@ -1558,35 +1516,34 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
else
{
if (row == UNDEF_ROW || row == UNDEFW_ROW)
- h = bfd_wrapped_link_hash_lookup (abfd, info, name, true, copy, false);
+ h = bfd_wrapped_link_hash_lookup (abfd, info, name, TRUE, copy, FALSE);
else
- h = bfd_link_hash_lookup (info->hash, name, true, copy, false);
+ h = bfd_link_hash_lookup (info->hash, name, TRUE, copy, FALSE);
if (h == NULL)
{
if (hashp != NULL)
*hashp = NULL;
- return false;
+ return FALSE;
}
}
if (info->notice_all
- || (info->notice_hash != (struct bfd_hash_table *) NULL
- && (bfd_hash_lookup (info->notice_hash, name, false, false)
- != (struct bfd_hash_entry *) NULL)))
+ || (info->notice_hash != NULL
+ && bfd_hash_lookup (info->notice_hash, name, FALSE, FALSE) != NULL))
{
if (! (*info->callbacks->notice) (info, h->root.string, abfd, section,
value))
- return false;
+ return FALSE;
}
- if (hashp != (struct bfd_link_hash_entry **) NULL)
+ if (hashp != NULL)
*hashp = h;
do
{
enum link_action action;
- cycle = false;
+ cycle = FALSE;
action = link_action[(int) row][(int) h->type];
switch (action)
{
@@ -1617,8 +1574,8 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
if (! ((*info->callbacks->multiple_common)
(info, h->root.string,
h->u.c.p->section->owner, bfd_link_hash_common, h->u.c.size,
- abfd, bfd_link_hash_defined, (bfd_vma) 0)))
- return false;
+ abfd, bfd_link_hash_defined, 0)))
+ return FALSE;
/* Fall through. */
case DEF:
case DEFW:
@@ -1678,7 +1635,7 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
if (! ((*info->callbacks->constructor)
(info, c == 'I',
h->root.string, abfd, section, value)))
- return false;
+ return FALSE;
}
}
}
@@ -1692,11 +1649,10 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
bfd_link_add_undef (info->hash, h);
h->type = bfd_link_hash_common;
h->u.c.p =
- ((struct bfd_link_hash_common_entry *)
- bfd_hash_allocate (&info->hash->table,
- sizeof (struct bfd_link_hash_common_entry)));
+ bfd_hash_allocate (&info->hash->table,
+ sizeof (struct bfd_link_hash_common_entry));
if (h->u.c.p == NULL)
- return false;
+ return FALSE;
h->u.c.size = value;
@@ -1738,8 +1694,8 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
case REF:
/* A reference to a defined symbol. */
- if (h->next == NULL && info->hash->undefs_tail != h)
- h->next = h;
+ if (h->und_next == NULL && info->hash->undefs_tail != h)
+ h->und_next = h;
break;
case BIG:
@@ -1751,7 +1707,7 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
(info, h->root.string,
h->u.c.p->section->owner, bfd_link_hash_common, h->u.c.size,
abfd, bfd_link_hash_common, value)))
- return false;
+ return FALSE;
if (value > h->u.c.size)
{
unsigned int power;
@@ -1800,9 +1756,9 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
else
obfd = NULL;
if (! ((*info->callbacks->multiple_common)
- (info, h->root.string, obfd, h->type, (bfd_vma) 0,
+ (info, h->root.string, obfd, h->type, 0,
abfd, bfd_link_hash_common, value)))
- return false;
+ return FALSE;
}
break;
@@ -1844,7 +1800,7 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
if (! ((*info->callbacks->multiple_definition)
(info, h->root.string, msec->owner, msec, mval,
abfd, section, value)))
- return false;
+ return FALSE;
}
break;
@@ -1854,8 +1810,8 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
if (! ((*info->callbacks->multiple_common)
(info, h->root.string,
h->u.c.p->section->owner, bfd_link_hash_common, h->u.c.size,
- abfd, bfd_link_hash_indirect, (bfd_vma) 0)))
- return false;
+ abfd, bfd_link_hash_indirect, 0)))
+ return FALSE;
/* Fall through. */
case IND:
/* Create an indirect symbol. */
@@ -1864,10 +1820,10 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
/* STRING is the name of the symbol we want to indirect
to. */
- inh = bfd_wrapped_link_hash_lookup (abfd, info, string, true,
- copy, false);
- if (inh == (struct bfd_link_hash_entry *) NULL)
- return false;
+ inh = bfd_wrapped_link_hash_lookup (abfd, info, string, TRUE,
+ copy, FALSE);
+ if (inh == NULL)
+ return FALSE;
if (inh->type == bfd_link_hash_indirect
&& inh->u.i.link == h)
{
@@ -1875,7 +1831,7 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
(_("%s: indirect symbol `%s' to `%s' is a loop"),
bfd_archive_filename (abfd), name, string);
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
if (inh->type == bfd_link_hash_new)
{
@@ -1890,7 +1846,7 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
if (h->type != bfd_link_hash_new)
{
row = UNDEF_ROW;
- cycle = true;
+ cycle = TRUE;
}
h->type = bfd_link_hash_indirect;
@@ -1902,7 +1858,7 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
/* Add an entry to a set. */
if (! (*info->callbacks->add_to_set) (info, h, BFD_RELOC_CTOR,
abfd, section, value))
- return false;
+ return FALSE;
break;
case WARNC:
@@ -1911,9 +1867,8 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
{
if (! (*info->callbacks->warning) (info, h->u.i.warning,
h->root.string, abfd,
- (asection *) NULL,
- (bfd_vma) 0))
- return false;
+ NULL, 0))
+ return FALSE;
/* Only issue a warning once. */
h->u.i.warning = NULL;
}
@@ -1921,38 +1876,35 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
case CYCLE:
/* Try again with the referenced symbol. */
h = h->u.i.link;
- cycle = true;
+ cycle = TRUE;
break;
case REFC:
/* A reference to an indirect symbol. */
- if (h->next == NULL && info->hash->undefs_tail != h)
- h->next = h;
+ if (h->und_next == NULL && info->hash->undefs_tail != h)
+ h->und_next = h;
h = h->u.i.link;
- cycle = true;
+ cycle = TRUE;
break;
case WARN:
/* Issue a warning. */
if (! (*info->callbacks->warning) (info, string, h->root.string,
- hash_entry_bfd (h),
- (asection *) NULL, (bfd_vma) 0))
- return false;
+ hash_entry_bfd (h), NULL, 0))
+ return FALSE;
break;
case CWARN:
/* Warn if this symbol has been referenced already,
otherwise add a warning. A symbol has been referenced if
- the next field is not NULL, or it is the tail of the
+ the und_next field is not NULL, or it is the tail of the
undefined symbol list. The REF case above helps to
ensure this. */
- if (h->next != NULL || info->hash->undefs_tail == h)
+ if (h->und_next != NULL || info->hash->undefs_tail == h)
{
if (! (*info->callbacks->warning) (info, string, h->root.string,
- hash_entry_bfd (h),
- (asection *) NULL,
- (bfd_vma) 0))
- return false;
+ hash_entry_bfd (h), NULL, 0))
+ return FALSE;
break;
}
/* Fall through. */
@@ -1964,10 +1916,9 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
/* STRING is the warning to give. */
sub = ((struct bfd_link_hash_entry *)
((*info->hash->table.newfunc)
- ((struct bfd_hash_entry *) NULL, &info->hash->table,
- h->root.string)));
+ (NULL, &info->hash->table, h->root.string)));
if (sub == NULL)
- return false;
+ return FALSE;
*sub = *h;
sub->type = bfd_link_hash_warning;
sub->u.i.link = h;
@@ -1980,7 +1931,7 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
w = bfd_hash_allocate (&info->hash->table, len);
if (w == NULL)
- return false;
+ return FALSE;
memcpy (w, string, len);
sub->u.i.warning = w;
}
@@ -1996,15 +1947,13 @@ _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section, value,
}
while (cycle);
- return true;
+ return TRUE;
}
/* Generic final link routine. */
-boolean
-_bfd_generic_final_link (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info;
+bfd_boolean
+_bfd_generic_final_link (bfd *abfd, struct bfd_link_info *info)
{
bfd *sub;
asection *o;
@@ -2012,7 +1961,7 @@ _bfd_generic_final_link (abfd, info)
size_t outsymalloc;
struct generic_write_global_symbol_info wginfo;
- bfd_get_outsymbols (abfd) = (asymbol **) NULL;
+ bfd_get_outsymbols (abfd) = NULL;
bfd_get_symcount (abfd) = 0;
outsymalloc = 0;
@@ -2020,12 +1969,12 @@ _bfd_generic_final_link (abfd, info)
for (o = abfd->sections; o != NULL; o = o->next)
for (p = o->link_order_head; p != NULL; p = p->next)
if (p->type == bfd_indirect_link_order)
- p->u.indirect.section->linker_mark = (unsigned int) true;
+ p->u.indirect.section->linker_mark = TRUE;
/* Build the output symbol table. */
- for (sub = info->input_bfds; sub != (bfd *) NULL; sub = sub->link_next)
+ for (sub = info->input_bfds; sub != NULL; sub = sub->link_next)
if (! _bfd_generic_link_output_symbols (abfd, sub, info, &outsymalloc))
- return false;
+ return FALSE;
/* Accumulate the global symbols. */
wginfo.info = info;
@@ -2033,25 +1982,21 @@ _bfd_generic_final_link (abfd, info)
wginfo.psymalloc = &outsymalloc;
_bfd_generic_link_hash_traverse (_bfd_generic_hash_table (info),
_bfd_generic_link_write_global_symbol,
- (PTR) &wginfo);
+ &wginfo);
/* Make sure we have a trailing NULL pointer on OUTSYMBOLS. We
shouldn't really need one, since we have SYMCOUNT, but some old
code still expects one. */
if (! generic_add_output_symbol (abfd, &outsymalloc, NULL))
- return false;
+ return FALSE;
- if (info->relocateable)
+ if (info->relocatable)
{
/* Allocate space for the output relocs for each section. */
- for (o = abfd->sections;
- o != (asection *) NULL;
- o = o->next)
+ for (o = abfd->sections; o != NULL; o = o->next)
{
o->reloc_count = 0;
- for (p = o->link_order_head;
- p != (struct bfd_link_order *) NULL;
- p = p->next)
+ for (p = o->link_order_head; p != NULL; p = p->next)
{
if (p->type == bfd_section_reloc_link_order
|| p->type == bfd_symbol_reloc_link_order)
@@ -2070,21 +2015,21 @@ _bfd_generic_final_link (abfd, info)
relsize = bfd_get_reloc_upper_bound (input_bfd,
input_section);
if (relsize < 0)
- return false;
- relocs = (arelent **) bfd_malloc ((bfd_size_type) relsize);
+ return FALSE;
+ relocs = bfd_malloc (relsize);
if (!relocs && relsize != 0)
- return false;
+ return FALSE;
symbols = _bfd_generic_link_get_symbols (input_bfd);
reloc_count = bfd_canonicalize_reloc (input_bfd,
input_section,
relocs,
symbols);
+ free (relocs);
if (reloc_count < 0)
- return false;
+ return FALSE;
BFD_ASSERT ((unsigned long) reloc_count
== input_section->reloc_count);
o->reloc_count += reloc_count;
- free (relocs);
}
}
if (o->reloc_count > 0)
@@ -2093,9 +2038,9 @@ _bfd_generic_final_link (abfd, info)
amt = o->reloc_count;
amt *= sizeof (arelent *);
- o->orelocation = (arelent **) bfd_alloc (abfd, amt);
+ o->orelocation = bfd_alloc (abfd, amt);
if (!o->orelocation)
- return false;
+ return FALSE;
o->flags |= SEC_RELOC;
/* Reset the count so that it can be used as an index
when putting in the output relocs. */
@@ -2105,43 +2050,36 @@ _bfd_generic_final_link (abfd, info)
}
/* Handle all the link order information for the sections. */
- for (o = abfd->sections;
- o != (asection *) NULL;
- o = o->next)
+ for (o = abfd->sections; o != NULL; o = o->next)
{
- for (p = o->link_order_head;
- p != (struct bfd_link_order *) NULL;
- p = p->next)
+ for (p = o->link_order_head; p != NULL; p = p->next)
{
switch (p->type)
{
case bfd_section_reloc_link_order:
case bfd_symbol_reloc_link_order:
if (! _bfd_generic_reloc_link_order (abfd, info, o, p))
- return false;
+ return FALSE;
break;
case bfd_indirect_link_order:
- if (! default_indirect_link_order (abfd, info, o, p, true))
- return false;
+ if (! default_indirect_link_order (abfd, info, o, p, TRUE))
+ return FALSE;
break;
default:
if (! _bfd_default_link_order (abfd, info, o, p))
- return false;
+ return FALSE;
break;
}
}
}
- return true;
+ return TRUE;
}
/* Add an output symbol to the output BFD. */
-static boolean
-generic_add_output_symbol (output_bfd, psymalloc, sym)
- bfd *output_bfd;
- size_t *psymalloc;
- asymbol *sym;
+static bfd_boolean
+generic_add_output_symbol (bfd *output_bfd, size_t *psymalloc, asymbol *sym)
{
if (bfd_get_symcount (output_bfd) >= *psymalloc)
{
@@ -2154,9 +2092,9 @@ generic_add_output_symbol (output_bfd, psymalloc, sym)
*psymalloc *= 2;
amt = *psymalloc;
amt *= sizeof (asymbol *);
- newsyms = (asymbol **) bfd_realloc (bfd_get_outsymbols (output_bfd), amt);
- if (newsyms == (asymbol **) NULL)
- return false;
+ newsyms = bfd_realloc (bfd_get_outsymbols (output_bfd), amt);
+ if (newsyms == NULL)
+ return FALSE;
bfd_get_outsymbols (output_bfd) = newsyms;
}
@@ -2164,32 +2102,29 @@ generic_add_output_symbol (output_bfd, psymalloc, sym)
if (sym != NULL)
++ bfd_get_symcount (output_bfd);
- return true;
+ return TRUE;
}
/* Handle the symbols for an input BFD. */
-boolean
-_bfd_generic_link_output_symbols (output_bfd, input_bfd, info, psymalloc)
- bfd *output_bfd;
- bfd *input_bfd;
- struct bfd_link_info *info;
- size_t *psymalloc;
+bfd_boolean
+_bfd_generic_link_output_symbols (bfd *output_bfd,
+ bfd *input_bfd,
+ struct bfd_link_info *info,
+ size_t *psymalloc)
{
asymbol **sym_ptr;
asymbol **sym_end;
if (! generic_link_read_symbols (input_bfd))
- return false;
+ return FALSE;
/* Create a filename symbol if we are supposed to. */
- if (info->create_object_symbols_section != (asection *) NULL)
+ if (info->create_object_symbols_section != NULL)
{
asection *sec;
- for (sec = input_bfd->sections;
- sec != (asection *) NULL;
- sec = sec->next)
+ for (sec = input_bfd->sections; sec != NULL; sec = sec->next)
{
if (sec->output_section == info->create_object_symbols_section)
{
@@ -2197,7 +2132,7 @@ _bfd_generic_link_output_symbols (output_bfd, input_bfd, info, psymalloc)
newsym = bfd_make_empty_symbol (input_bfd);
if (!newsym)
- return false;
+ return FALSE;
newsym->name = input_bfd->filename;
newsym->value = 0;
newsym->flags = BSF_LOCAL | BSF_FILE;
@@ -2205,7 +2140,7 @@ _bfd_generic_link_output_symbols (output_bfd, input_bfd, info, psymalloc)
if (! generic_add_output_symbol (output_bfd, psymalloc,
newsym))
- return false;
+ return FALSE;
break;
}
@@ -2220,9 +2155,9 @@ _bfd_generic_link_output_symbols (output_bfd, input_bfd, info, psymalloc)
{
asymbol *sym;
struct generic_link_hash_entry *h;
- boolean output;
+ bfd_boolean output;
- h = (struct generic_link_hash_entry *) NULL;
+ h = NULL;
sym = *sym_ptr;
if ((sym->flags & (BSF_INDIRECT
| BSF_WARNING
@@ -2234,7 +2169,7 @@ _bfd_generic_link_output_symbols (output_bfd, input_bfd, info, psymalloc)
|| bfd_is_ind_section (bfd_get_section (sym)))
{
if (sym->udata.p != NULL)
- h = (struct generic_link_hash_entry *) sym->udata.p;
+ h = sym->udata.p;
else if ((sym->flags & BSF_CONSTRUCTOR) != 0)
{
/* This case normally means that the main linker code
@@ -2251,13 +2186,13 @@ _bfd_generic_link_output_symbols (output_bfd, input_bfd, info, psymalloc)
h = ((struct generic_link_hash_entry *)
bfd_wrapped_link_hash_lookup (output_bfd, info,
bfd_asymbol_name (sym),
- false, false, true));
+ FALSE, FALSE, TRUE));
else
h = _bfd_generic_link_hash_lookup (_bfd_generic_hash_table (info),
bfd_asymbol_name (sym),
- false, false, true);
+ FALSE, FALSE, TRUE);
- if (h != (struct generic_link_hash_entry *) NULL)
+ if (h != NULL)
{
/* Force all references to this symbol to point to
the same area in memory. It is possible that
@@ -2266,7 +2201,7 @@ _bfd_generic_link_output_symbols (output_bfd, input_bfd, info, psymalloc)
check that. */
if (info->hash->creator == input_bfd->xvec)
{
- if (h->sym != (asymbol *) NULL)
+ if (h->sym != NULL)
*sym_ptr = sym = h->sym;
}
@@ -2318,10 +2253,9 @@ _bfd_generic_link_output_symbols (output_bfd, input_bfd, info, psymalloc)
write_file_locals in ldsym.c. */
if (info->strip == strip_all
|| (info->strip == strip_some
- && (bfd_hash_lookup (info->keep_hash, bfd_asymbol_name (sym),
- false, false)
- == (struct bfd_hash_entry *) NULL)))
- output = false;
+ && bfd_hash_lookup (info->keep_hash, bfd_asymbol_name (sym),
+ FALSE, FALSE) == NULL))
+ output = FALSE;
else if ((sym->flags & (BSF_GLOBAL | BSF_WEAK)) != 0)
{
/* If this symbol is marked as occurring now, rather
@@ -2330,48 +2264,48 @@ _bfd_generic_link_output_symbols (output_bfd, input_bfd, info, psymalloc)
better way. */
if (bfd_asymbol_bfd (sym) == input_bfd
&& (sym->flags & BSF_NOT_AT_END) != 0)
- output = true;
+ output = TRUE;
else
- output = false;
+ output = FALSE;
}
else if (bfd_is_ind_section (sym->section))
- output = false;
+ output = FALSE;
else if ((sym->flags & BSF_DEBUGGING) != 0)
{
if (info->strip == strip_none)
- output = true;
+ output = TRUE;
else
- output = false;
+ output = FALSE;
}
else if (bfd_is_und_section (sym->section)
|| bfd_is_com_section (sym->section))
- output = false;
+ output = FALSE;
else if ((sym->flags & BSF_LOCAL) != 0)
{
if ((sym->flags & BSF_WARNING) != 0)
- output = false;
+ output = FALSE;
else
{
switch (info->discard)
{
default:
case discard_all:
- output = false;
+ output = FALSE;
break;
case discard_sec_merge:
- output = true;
- if (info->relocateable
+ output = TRUE;
+ if (info->relocatable
|| ! (sym->section->flags & SEC_MERGE))
break;
/* FALLTHROUGH */
case discard_l:
if (bfd_is_local_label (input_bfd, sym))
- output = false;
+ output = FALSE;
else
- output = true;
+ output = TRUE;
break;
case discard_none:
- output = true;
+ output = TRUE;
break;
}
}
@@ -2379,9 +2313,9 @@ _bfd_generic_link_output_symbols (output_bfd, input_bfd, info, psymalloc)
else if ((sym->flags & BSF_CONSTRUCTOR))
{
if (info->strip != strip_all)
- output = true;
+ output = TRUE;
else
- output = false;
+ output = FALSE;
}
else
abort ();
@@ -2393,27 +2327,25 @@ _bfd_generic_link_output_symbols (output_bfd, input_bfd, info, psymalloc)
field set. */
if ((sym->section->flags & SEC_HAS_CONTENTS) != 0
&& ! sym->section->linker_mark)
- output = false;
+ output = FALSE;
if (output)
{
if (! generic_add_output_symbol (output_bfd, psymalloc, sym))
- return false;
- if (h != (struct generic_link_hash_entry *) NULL)
- h->written = true;
+ return FALSE;
+ if (h != NULL)
+ h->written = TRUE;
}
}
- return true;
+ return TRUE;
}
/* Set the section and value of a generic BFD symbol based on a linker
hash table entry. */
static void
-set_symbol_from_hash (sym, h)
- asymbol *sym;
- struct bfd_link_hash_entry *h;
+set_symbol_from_hash (asymbol *sym, struct bfd_link_hash_entry *h)
{
switch (h->type)
{
@@ -2473,36 +2405,34 @@ set_symbol_from_hash (sym, h)
/* Write out a global symbol, if it hasn't already been written out.
This is called for each symbol in the hash table. */
-boolean
-_bfd_generic_link_write_global_symbol (h, data)
- struct generic_link_hash_entry *h;
- PTR data;
+bfd_boolean
+_bfd_generic_link_write_global_symbol (struct generic_link_hash_entry *h,
+ void *data)
{
- struct generic_write_global_symbol_info *wginfo =
- (struct generic_write_global_symbol_info *) data;
+ struct generic_write_global_symbol_info *wginfo = data;
asymbol *sym;
if (h->root.type == bfd_link_hash_warning)
h = (struct generic_link_hash_entry *) h->root.u.i.link;
if (h->written)
- return true;
+ return TRUE;
- h->written = true;
+ h->written = TRUE;
if (wginfo->info->strip == strip_all
|| (wginfo->info->strip == strip_some
&& bfd_hash_lookup (wginfo->info->keep_hash, h->root.root.string,
- false, false) == NULL))
- return true;
+ FALSE, FALSE) == NULL))
+ return TRUE;
- if (h->sym != (asymbol *) NULL)
+ if (h->sym != NULL)
sym = h->sym;
else
{
sym = bfd_make_empty_symbol (wginfo->output_bfd);
if (!sym)
- return false;
+ return FALSE;
sym->name = h->root.root.string;
sym->flags = 0;
}
@@ -2518,35 +2448,34 @@ _bfd_generic_link_write_global_symbol (h, data)
abort ();
}
- return true;
+ return TRUE;
}
/* Create a relocation. */
-boolean
-_bfd_generic_reloc_link_order (abfd, info, sec, link_order)
- bfd *abfd;
- struct bfd_link_info *info;
- asection *sec;
- struct bfd_link_order *link_order;
+bfd_boolean
+_bfd_generic_reloc_link_order (bfd *abfd,
+ struct bfd_link_info *info,
+ asection *sec,
+ struct bfd_link_order *link_order)
{
arelent *r;
- if (! info->relocateable)
+ if (! info->relocatable)
abort ();
- if (sec->orelocation == (arelent **) NULL)
+ if (sec->orelocation == NULL)
abort ();
- r = (arelent *) bfd_alloc (abfd, (bfd_size_type) sizeof (arelent));
- if (r == (arelent *) NULL)
- return false;
+ r = bfd_alloc (abfd, sizeof (arelent));
+ if (r == NULL)
+ return FALSE;
r->address = link_order->offset;
r->howto = bfd_reloc_type_lookup (abfd, link_order->u.reloc.p->reloc);
if (r->howto == 0)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
/* Get the symbol to use for the relocation. */
@@ -2559,16 +2488,15 @@ _bfd_generic_reloc_link_order (abfd, info, sec, link_order)
h = ((struct generic_link_hash_entry *)
bfd_wrapped_link_hash_lookup (abfd, info,
link_order->u.reloc.p->u.name,
- false, false, true));
- if (h == (struct generic_link_hash_entry *) NULL
+ FALSE, FALSE, TRUE));
+ if (h == NULL
|| ! h->written)
{
if (! ((*info->callbacks->unattached_reloc)
- (info, link_order->u.reloc.p->u.name,
- (bfd *) NULL, (asection *) NULL, (bfd_vma) 0)))
- return false;
+ (info, link_order->u.reloc.p->u.name, NULL, NULL, 0)))
+ return FALSE;
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
r->sym_ptr_ptr = &h->sym;
}
@@ -2582,13 +2510,13 @@ _bfd_generic_reloc_link_order (abfd, info, sec, link_order)
bfd_size_type size;
bfd_reloc_status_type rstat;
bfd_byte *buf;
- boolean ok;
+ bfd_boolean ok;
file_ptr loc;
size = bfd_get_reloc_size (r->howto);
- buf = (bfd_byte *) bfd_zmalloc (size);
- if (buf == (bfd_byte *) NULL)
- return false;
+ buf = bfd_zmalloc (size);
+ if (buf == NULL)
+ return FALSE;
rstat = _bfd_relocate_contents (r->howto, abfd,
(bfd_vma) link_order->u.reloc.p->addend,
buf);
@@ -2606,19 +2534,18 @@ _bfd_generic_reloc_link_order (abfd, info, sec, link_order)
? bfd_section_name (abfd, link_order->u.reloc.p->u.section)
: link_order->u.reloc.p->u.name),
r->howto->name, link_order->u.reloc.p->addend,
- (bfd *) NULL, (asection *) NULL, (bfd_vma) 0)))
+ NULL, NULL, 0)))
{
free (buf);
- return false;
+ return FALSE;
}
break;
}
loc = link_order->offset * bfd_octets_per_byte (abfd);
- ok = bfd_set_section_contents (abfd, sec, (PTR) buf, loc,
- (bfd_size_type) size);
+ ok = bfd_set_section_contents (abfd, sec, buf, loc, size);
free (buf);
if (! ok)
- return false;
+ return FALSE;
r->addend = 0;
}
@@ -2626,26 +2553,24 @@ _bfd_generic_reloc_link_order (abfd, info, sec, link_order)
sec->orelocation[sec->reloc_count] = r;
++sec->reloc_count;
- return true;
+ return TRUE;
}
/* Allocate a new link_order for a section. */
struct bfd_link_order *
-bfd_new_link_order (abfd, section)
- bfd *abfd;
- asection *section;
+bfd_new_link_order (bfd *abfd, asection *section)
{
bfd_size_type amt = sizeof (struct bfd_link_order);
struct bfd_link_order *new;
- new = (struct bfd_link_order *) bfd_zalloc (abfd, amt);
+ new = bfd_zalloc (abfd, amt);
if (!new)
return NULL;
new->type = bfd_undefined_link_order;
- if (section->link_order_tail != (struct bfd_link_order *) NULL)
+ if (section->link_order_tail != NULL)
section->link_order_tail->next = new;
else
section->link_order_head = new;
@@ -2658,12 +2583,11 @@ bfd_new_link_order (abfd, section)
the reloc_link_order types here, since they depend upon the details
of how the particular backends generates relocs. */
-boolean
-_bfd_default_link_order (abfd, info, sec, link_order)
- bfd *abfd;
- struct bfd_link_info *info;
- asection *sec;
- struct bfd_link_order *link_order;
+bfd_boolean
+_bfd_default_link_order (bfd *abfd,
+ struct bfd_link_info *info,
+ asection *sec,
+ struct bfd_link_order *link_order)
{
switch (link_order->type)
{
@@ -2674,7 +2598,7 @@ _bfd_default_link_order (abfd, info, sec, link_order)
abort ();
case bfd_indirect_link_order:
return default_indirect_link_order (abfd, info, sec, link_order,
- false);
+ FALSE);
case bfd_data_link_order:
return default_data_link_order (abfd, info, sec, link_order);
}
@@ -2682,33 +2606,32 @@ _bfd_default_link_order (abfd, info, sec, link_order)
/* Default routine to handle a bfd_data_link_order. */
-static boolean
-default_data_link_order (abfd, info, sec, link_order)
- bfd *abfd;
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
- asection *sec;
- struct bfd_link_order *link_order;
+static bfd_boolean
+default_data_link_order (bfd *abfd,
+ struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ asection *sec,
+ struct bfd_link_order *link_order)
{
bfd_size_type size;
size_t fill_size;
bfd_byte *fill;
file_ptr loc;
- boolean result;
+ bfd_boolean result;
BFD_ASSERT ((sec->flags & SEC_HAS_CONTENTS) != 0);
size = link_order->size;
if (size == 0)
- return true;
+ return TRUE;
fill = link_order->u.data.contents;
fill_size = link_order->u.data.size;
if (fill_size != 0 && fill_size < size)
{
bfd_byte *p;
- fill = (bfd_byte *) bfd_malloc (size);
+ fill = bfd_malloc (size);
if (fill == NULL)
- return false;
+ return FALSE;
p = fill;
if (fill_size == 1)
memset (p, (int) link_order->u.data.contents[0], (size_t) size);
@@ -2737,14 +2660,12 @@ default_data_link_order (abfd, info, sec, link_order)
/* Default routine to handle a bfd_indirect_link_order. */
-static boolean
-default_indirect_link_order (output_bfd, info, output_section, link_order,
- generic_linker)
- bfd *output_bfd;
- struct bfd_link_info *info;
- asection *output_section;
- struct bfd_link_order *link_order;
- boolean generic_linker;
+static bfd_boolean
+default_indirect_link_order (bfd *output_bfd,
+ struct bfd_link_info *info,
+ asection *output_section,
+ struct bfd_link_order *link_order,
+ bfd_boolean generic_linker)
{
asection *input_section;
bfd *input_bfd;
@@ -2756,7 +2677,7 @@ default_indirect_link_order (output_bfd, info, output_section, link_order,
BFD_ASSERT ((output_section->flags & SEC_HAS_CONTENTS) != 0);
if (link_order->size == 0)
- return true;
+ return TRUE;
input_section = link_order->u.indirect.section;
input_bfd = input_section->owner;
@@ -2765,9 +2686,9 @@ default_indirect_link_order (output_bfd, info, output_section, link_order,
BFD_ASSERT (input_section->output_offset == link_order->offset);
BFD_ASSERT (input_section->_cooked_size == link_order->size);
- if (info->relocateable
+ if (info->relocatable
&& input_section->reloc_count > 0
- && output_section->orelocation == (arelent **) NULL)
+ && output_section->orelocation == NULL)
{
/* Space has not been allocated for the output relocations.
This can happen when we are called by a specific backend
@@ -2775,10 +2696,10 @@ default_indirect_link_order (output_bfd, info, output_section, link_order,
types of object files. Handling this case correctly is
difficult, and sometimes impossible. */
(*_bfd_error_handler)
- (_("Attempt to do relocateable link with %s input and %s output"),
+ (_("Attempt to do relocatable link with %s input and %s output"),
bfd_get_target (input_bfd), bfd_get_target (output_bfd));
bfd_set_error (bfd_error_wrong_format);
- return false;
+ return FALSE;
}
if (! generic_linker)
@@ -2791,7 +2712,7 @@ default_indirect_link_order (output_bfd, info, output_section, link_order,
a specific linker, presumably because we are linking
different types of object files together. */
if (! generic_link_read_symbols (input_bfd))
- return false;
+ return FALSE;
/* Since we have been called by a specific linker, rather than
the generic linker, the values of the symbols will not be
@@ -2819,15 +2740,15 @@ default_indirect_link_order (output_bfd, info, output_section, link_order,
/* sym->udata may have been set by
generic_link_add_symbol_list. */
if (sym->udata.p != NULL)
- h = (struct bfd_link_hash_entry *) sym->udata.p;
+ h = sym->udata.p;
else if (bfd_is_und_section (bfd_get_section (sym)))
h = bfd_wrapped_link_hash_lookup (output_bfd, info,
bfd_asymbol_name (sym),
- false, false, true);
+ FALSE, FALSE, TRUE);
else
h = bfd_link_hash_lookup (info->hash,
bfd_asymbol_name (sym),
- false, false, true);
+ FALSE, FALSE, TRUE);
if (h != NULL)
set_symbol_from_hash (sym, h);
}
@@ -2836,11 +2757,11 @@ default_indirect_link_order (output_bfd, info, output_section, link_order,
/* Get and relocate the section contents. */
sec_size = bfd_section_size (input_bfd, input_section);
- contents = ((bfd_byte *) bfd_malloc (sec_size));
+ contents = bfd_malloc (sec_size);
if (contents == NULL && sec_size != 0)
goto error_return;
new_contents = (bfd_get_relocated_section_contents
- (output_bfd, info, link_order, contents, info->relocateable,
+ (output_bfd, info, link_order, contents, info->relocatable,
_bfd_generic_link_get_symbols (input_bfd)));
if (!new_contents)
goto error_return;
@@ -2848,31 +2769,30 @@ default_indirect_link_order (output_bfd, info, output_section, link_order,
/* Output the section contents. */
loc = link_order->offset * bfd_octets_per_byte (output_bfd);
if (! bfd_set_section_contents (output_bfd, output_section,
- (PTR) new_contents, loc, link_order->size))
+ new_contents, loc, link_order->size))
goto error_return;
if (contents != NULL)
free (contents);
- return true;
+ return TRUE;
error_return:
if (contents != NULL)
free (contents);
- return false;
+ return FALSE;
}
/* A little routine to count the number of relocs in a link_order
list. */
unsigned int
-_bfd_count_link_order_relocs (link_order)
- struct bfd_link_order *link_order;
+_bfd_count_link_order_relocs (struct bfd_link_order *link_order)
{
register unsigned int c;
register struct bfd_link_order *l;
c = 0;
- for (l = link_order; l != (struct bfd_link_order *) NULL; l = l->next)
+ for (l = link_order; l != NULL; l = l->next)
{
if (l->type == bfd_section_reloc_link_order
|| l->type == bfd_symbol_reloc_link_order)
@@ -2887,7 +2807,7 @@ FUNCTION
bfd_link_split_section
SYNOPSIS
- boolean bfd_link_split_section(bfd *abfd, asection *sec);
+ bfd_boolean bfd_link_split_section (bfd *abfd, asection *sec);
DESCRIPTION
Return nonzero if @var{sec} should be split during a
@@ -2899,10 +2819,9 @@ DESCRIPTION
*/
-boolean
-_bfd_generic_link_split_section (abfd, sec)
- bfd *abfd ATTRIBUTE_UNUSED;
- asection *sec ATTRIBUTE_UNUSED;
+bfd_boolean
+_bfd_generic_link_split_section (bfd *abfd ATTRIBUTE_UNUSED,
+ asection *sec ATTRIBUTE_UNUSED)
{
- return false;
+ return FALSE;
}
diff --git a/contrib/binutils/bfd/merge.c b/contrib/binutils/bfd/merge.c
index 9dc2e70..89f45cd 100644
--- a/contrib/binutils/bfd/merge.c
+++ b/contrib/binutils/bfd/merge.c
@@ -1,5 +1,5 @@
/* SEC_MERGE support.
- Copyright 2001, 2002 Free Software Foundation, Inc.
+ Copyright 2001, 2002, 2003 Free Software Foundation, Inc.
Written by Jakub Jelinek <jakub@redhat.com>.
This file is part of BFD, the Binary File Descriptor library.
@@ -34,7 +34,7 @@ struct sec_merge_sec_info;
struct sec_merge_hash_entry
{
struct bfd_hash_entry root;
- /* Length of this entry. */
+ /* Length of this entry. This includes the zero terminator. */
unsigned int len;
/* Start of this string needs to be aligned to
alignment octets (not 1 << align). */
@@ -43,8 +43,6 @@ struct sec_merge_hash_entry
{
/* Index within the merged section. */
bfd_size_type index;
- /* Entity size (if present in suffix hash tables). */
- unsigned int entsize;
/* Entry this is a suffix of (if alignment is 0). */
struct sec_merge_hash_entry *suffix;
} u;
@@ -68,7 +66,7 @@ struct sec_merge_hash
/* Entity size. */
unsigned int entsize;
/* Are entries fixed size or zero terminated strings? */
- boolean strings;
+ bfd_boolean strings;
};
struct sec_merge_info
@@ -88,7 +86,7 @@ struct sec_merge_sec_info
/* The corresponding section. */
asection *sec;
/* Pointer to merge_info pointing to us. */
- PTR *psecinfo;
+ void **psecinfo;
/* A hash table used to hold section content. */
struct sec_merge_hash *htab;
/* First string in this section. */
@@ -97,31 +95,12 @@ struct sec_merge_sec_info
unsigned char contents[1];
};
-static struct bfd_hash_entry *sec_merge_hash_newfunc
- PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-static struct sec_merge_hash_entry *sec_merge_hash_lookup
- PARAMS ((struct sec_merge_hash *, const char *, unsigned int, boolean));
-static struct sec_merge_hash *sec_merge_init
- PARAMS ((unsigned int, boolean));
-static struct sec_merge_hash_entry *sec_merge_add
- PARAMS ((struct sec_merge_hash *, const char *, unsigned int,
- struct sec_merge_sec_info *));
-static boolean sec_merge_emit
- PARAMS ((bfd *, struct sec_merge_hash_entry *));
-static int cmplengthentry PARAMS ((const PTR, const PTR));
-static int last4_eq PARAMS ((const PTR, const PTR));
-static int last_eq PARAMS ((const PTR, const PTR));
-static boolean record_section
- PARAMS ((struct sec_merge_info *, struct sec_merge_sec_info *));
-static void merge_strings PARAMS ((struct sec_merge_info *));
/* Routine to create an entry in a section merge hashtab. */
static struct bfd_hash_entry *
-sec_merge_hash_newfunc (entry, table, string)
- struct bfd_hash_entry *entry;
- struct bfd_hash_table *table;
- const char *string;
+sec_merge_hash_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table, const char *string)
{
struct sec_merge_hash_entry *ret = (struct sec_merge_hash_entry *) entry;
@@ -152,11 +131,8 @@ sec_merge_hash_newfunc (entry, table, string)
/* Look up an entry in a section merge hash table. */
static struct sec_merge_hash_entry *
-sec_merge_hash_lookup (table, string, alignment, create)
- struct sec_merge_hash *table;
- const char *string;
- unsigned int alignment;
- boolean create;
+sec_merge_hash_lookup (struct sec_merge_hash *table, const char *string,
+ unsigned int alignment, bfd_boolean create)
{
register const unsigned char *s;
register unsigned long hash;
@@ -227,9 +203,12 @@ sec_merge_hash_lookup (table, string, alignment, create)
alignment, we need to insert another copy. */
if (hashp->alignment < alignment)
{
- /* Mark the less aligned copy as deleted. */
- hashp->len = 0;
- hashp->alignment = 0;
+ if (create)
+ {
+ /* Mark the less aligned copy as deleted. */
+ hashp->len = 0;
+ hashp->alignment = 0;
+ }
break;
}
return hashp;
@@ -257,9 +236,7 @@ sec_merge_hash_lookup (table, string, alignment, create)
/* Create a new hash table. */
static struct sec_merge_hash *
-sec_merge_init (entsize, strings)
- unsigned int entsize;
- boolean strings;
+sec_merge_init (unsigned int entsize, bfd_boolean strings)
{
struct sec_merge_hash *table;
bfd_size_type amt = sizeof (struct sec_merge_hash);
@@ -287,15 +264,12 @@ sec_merge_init (entsize, strings)
already present. */
static struct sec_merge_hash_entry *
-sec_merge_add (tab, str, alignment, secinfo)
- struct sec_merge_hash *tab;
- const char *str;
- unsigned int alignment;
- struct sec_merge_sec_info *secinfo;
+sec_merge_add (struct sec_merge_hash *tab, const char *str,
+ unsigned int alignment, struct sec_merge_sec_info *secinfo)
{
register struct sec_merge_hash_entry *entry;
- entry = sec_merge_hash_lookup (tab, str, alignment, true);
+ entry = sec_merge_hash_lookup (tab, str, alignment, TRUE);
if (entry == NULL)
return NULL;
@@ -313,10 +287,8 @@ sec_merge_add (tab, str, alignment, secinfo)
return entry;
}
-static boolean
-sec_merge_emit (abfd, entry)
- register bfd *abfd;
- struct sec_merge_hash_entry *entry;
+static bfd_boolean
+sec_merge_emit (bfd *abfd, struct sec_merge_hash_entry *entry)
{
struct sec_merge_sec_info *secinfo = entry->secinfo;
asection *sec = secinfo->sec;
@@ -336,7 +308,7 @@ sec_merge_emit (abfd, entry)
if (len)
{
len = entry->alignment - len;
- if (bfd_bwrite ((PTR) pad, (bfd_size_type) len, abfd) != len)
+ if (bfd_bwrite (pad, (bfd_size_type) len, abfd) != len)
break;
off += len;
}
@@ -344,7 +316,7 @@ sec_merge_emit (abfd, entry)
str = entry->root.string;
len = entry->len;
- if (bfd_bwrite ((PTR) str, (bfd_size_type) len, abfd) != len)
+ if (bfd_bwrite (str, (bfd_size_type) len, abfd) != len)
break;
off += len;
@@ -353,18 +325,14 @@ sec_merge_emit (abfd, entry)
if (alignment_power)
free (pad);
- return (boolean) (entry == NULL || entry->secinfo != secinfo);
+ return entry == NULL || entry->secinfo != secinfo;
}
/* This function is called for each input file from the add_symbols
pass of the linker. */
-boolean
-_bfd_merge_section (abfd, psinfo, sec, psecinfo)
- bfd *abfd;
- PTR *psinfo;
- asection *sec;
- PTR *psecinfo;
+bfd_boolean
+_bfd_merge_section (bfd *abfd, void **psinfo, asection *sec, void **psecinfo)
{
struct sec_merge_info *sinfo;
struct sec_merge_sec_info *secinfo;
@@ -375,12 +343,12 @@ _bfd_merge_section (abfd, psinfo, sec, psecinfo)
|| (sec->flags & SEC_EXCLUDE)
|| (sec->flags & SEC_MERGE) == 0
|| sec->entsize == 0)
- return true;
+ return TRUE;
if ((sec->flags & SEC_RELOC) != 0)
{
/* We aren't prepared to handle relocations in merged sections. */
- return true;
+ return TRUE;
}
align = bfd_get_section_alignment (sec->owner, sec);
@@ -396,7 +364,7 @@ _bfd_merge_section (abfd, psinfo, sec, psecinfo)
of alignment. For non-string constants, alignment must
be smaller than or equal to entity size and entity size
must be integer multiple of alignment. */
- return true;
+ return TRUE;
}
for (sinfo = (struct sec_merge_info *) *psinfo; sinfo; sinfo = sinfo->next)
@@ -415,7 +383,7 @@ _bfd_merge_section (abfd, psinfo, sec, psecinfo)
goto error_return;
sinfo->next = (struct sec_merge_info *) *psinfo;
sinfo->chain = NULL;
- *psinfo = (PTR) sinfo;
+ *psinfo = sinfo;
sinfo->htab = sec_merge_init (sec->entsize, (sec->flags & SEC_STRINGS));
if (sinfo->htab == NULL)
goto error_return;
@@ -446,108 +414,28 @@ _bfd_merge_section (abfd, psinfo, sec, psecinfo)
(bfd_vma) 0, sec->_raw_size))
goto error_return;
- return true;
+ return TRUE;
error_return:
*psecinfo = NULL;
- return false;
-}
-
-/* Compare two sec_merge_hash_entry structures. This is called via qsort. */
-
-static int
-cmplengthentry (a, b)
- const PTR a;
- const PTR b;
-{
- struct sec_merge_hash_entry * A = *(struct sec_merge_hash_entry **) a;
- struct sec_merge_hash_entry * B = *(struct sec_merge_hash_entry **) b;
-
- if (A->len < B->len)
- return 1;
- else if (A->len > B->len)
- return -1;
-
- return memcmp (A->root.string, B->root.string, A->len);
-}
-
-static int
-last4_eq (a, b)
- const PTR a;
- const PTR b;
-{
- struct sec_merge_hash_entry * A = (struct sec_merge_hash_entry *) a;
- struct sec_merge_hash_entry * B = (struct sec_merge_hash_entry *) b;
-
- if (memcmp (A->root.string + A->len - 5 * A->u.entsize,
- B->root.string + B->len - 5 * A->u.entsize,
- 4 * A->u.entsize) != 0)
- /* This was a hashtable collision. */
- return 0;
-
- if (A->len <= B->len)
- /* B cannot be a suffix of A unless A is equal to B, which is guaranteed
- not to be equal by the hash table. */
- return 0;
-
- if (A->alignment < B->alignment
- || ((A->len - B->len) & (B->alignment - 1)))
- /* The suffix is not sufficiently aligned. */
- return 0;
-
- return memcmp (A->root.string + (A->len - B->len),
- B->root.string, B->len - 5 * A->u.entsize) == 0;
-}
-
-static int
-last_eq (a, b)
- const PTR a;
- const PTR b;
-{
- struct sec_merge_hash_entry * A = (struct sec_merge_hash_entry *) a;
- struct sec_merge_hash_entry * B = (struct sec_merge_hash_entry *) b;
-
- if (B->len >= 5 * A->u.entsize)
- /* Longer strings are just pushed into the hash table,
- they'll be used when looking up for very short strings. */
- return 0;
-
- if (memcmp (A->root.string + A->len - 2 * A->u.entsize,
- B->root.string + B->len - 2 * A->u.entsize,
- A->u.entsize) != 0)
- /* This was a hashtable collision. */
- return 0;
-
- if (A->len <= B->len)
- /* B cannot be a suffix of A unless A is equal to B, which is guaranteed
- not to be equal by the hash table. */
- return 0;
-
- if (A->alignment < B->alignment
- || ((A->len - B->len) & (B->alignment - 1)))
- /* The suffix is not sufficiently aligned. */
- return 0;
-
- return memcmp (A->root.string + (A->len - B->len),
- B->root.string, B->len - 2 * A->u.entsize) == 0;
+ return FALSE;
}
/* Record one section into the hash table. */
-static boolean
-record_section (sinfo, secinfo)
- struct sec_merge_info *sinfo;
- struct sec_merge_sec_info *secinfo;
+static bfd_boolean
+record_section (struct sec_merge_info *sinfo,
+ struct sec_merge_sec_info *secinfo)
{
asection *sec = secinfo->sec;
struct sec_merge_hash_entry *entry;
- boolean nul;
+ bfd_boolean nul;
unsigned char *p, *end;
bfd_vma mask, eltalign;
unsigned int align, i;
align = bfd_get_section_alignment (sec->owner, sec);
end = secinfo->contents + sec->_raw_size;
- nul = false;
+ nul = FALSE;
mask = ((bfd_vma) 1 << align) - 1;
if (sec->flags & SEC_STRINGS)
{
@@ -567,14 +455,14 @@ record_section (sinfo, secinfo)
{
if (!nul && !((p - secinfo->contents) & mask))
{
- nul = true;
+ nul = TRUE;
entry = sec_merge_add (sinfo->htab, "",
(unsigned) mask + 1, secinfo);
if (! entry)
goto error_return;
}
p++;
- }
+ }
}
else
{
@@ -587,7 +475,7 @@ record_section (sinfo, secinfo)
break;
if (!nul && !((p - secinfo->contents) & mask))
{
- nul = true;
+ nul = TRUE;
entry = sec_merge_add (sinfo->htab, p,
(unsigned) mask + 1, secinfo);
if (! entry)
@@ -608,27 +496,89 @@ record_section (sinfo, secinfo)
}
}
- return true;
+ return TRUE;
error_return:
for (secinfo = sinfo->chain; secinfo; secinfo = secinfo->next)
*secinfo->psecinfo = NULL;
- return false;
+ return FALSE;
+}
+
+static int
+strrevcmp (const void *a, const void *b)
+{
+ struct sec_merge_hash_entry *A = *(struct sec_merge_hash_entry **) a;
+ struct sec_merge_hash_entry *B = *(struct sec_merge_hash_entry **) b;
+ unsigned int lenA = A->len;
+ unsigned int lenB = B->len;
+ const unsigned char *s = A->root.string + lenA - 1;
+ const unsigned char *t = B->root.string + lenB - 1;
+ int l = lenA < lenB ? lenA : lenB;
+
+ while (l)
+ {
+ if (*s != *t)
+ return (int) *s - (int) *t;
+ s--;
+ t--;
+ l--;
+ }
+ return lenA - lenB;
+}
+
+/* Like strrevcmp, but for the case where all strings have the same
+ alignment > entsize. */
+
+static int
+strrevcmp_align (const void *a, const void *b)
+{
+ struct sec_merge_hash_entry *A = *(struct sec_merge_hash_entry **) a;
+ struct sec_merge_hash_entry *B = *(struct sec_merge_hash_entry **) b;
+ unsigned int lenA = A->len;
+ unsigned int lenB = B->len;
+ const unsigned char *s = A->root.string + lenA - 1;
+ const unsigned char *t = B->root.string + lenB - 1;
+ int l = lenA < lenB ? lenA : lenB;
+ int tail_align = (lenA & (A->alignment - 1)) - (lenB & (A->alignment - 1));
+
+ if (tail_align != 0)
+ return tail_align;
+
+ while (l)
+ {
+ if (*s != *t)
+ return (int) *s - (int) *t;
+ s--;
+ t--;
+ l--;
+ }
+ return lenA - lenB;
+}
+
+static inline int
+is_suffix (const struct sec_merge_hash_entry *A,
+ const struct sec_merge_hash_entry *B)
+{
+ if (A->len <= B->len)
+ /* B cannot be a suffix of A unless A is equal to B, which is guaranteed
+ not to be equal by the hash table. */
+ return 0;
+
+ return memcmp (A->root.string + (A->len - B->len),
+ B->root.string, B->len) == 0;
}
/* This is a helper function for _bfd_merge_sections. It attempts to
merge strings matching suffixes of longer strings. */
static void
-merge_strings (sinfo)
- struct sec_merge_info *sinfo;
+merge_strings (struct sec_merge_info *sinfo)
{
- struct sec_merge_hash_entry **array, **a, **end, *e;
+ struct sec_merge_hash_entry **array, **a, *e;
struct sec_merge_sec_info *secinfo;
- htab_t lasttab = NULL, last4tab = NULL;
bfd_size_type size, amt;
+ unsigned int alignment = 0;
- /* Now sort the strings by length, longest first. */
- array = NULL;
+ /* Now sort the strings */
amt = sinfo->htab->size * sizeof (struct sec_merge_hash_entry *);
array = (struct sec_merge_hash_entry **) bfd_malloc (amt);
if (array == NULL)
@@ -636,90 +586,50 @@ merge_strings (sinfo)
for (e = sinfo->htab->first, a = array; e; e = e->next)
if (e->alignment)
- *a++ = e;
+ {
+ *a++ = e;
+ /* Adjust the length to not include the zero terminator. */
+ e->len -= sinfo->htab->entsize;
+ if (alignment != e->alignment)
+ {
+ if (alignment == 0)
+ alignment = e->alignment;
+ else
+ alignment = (unsigned) -1;
+ }
+ }
sinfo->htab->size = a - array;
-
- qsort (array, (size_t) sinfo->htab->size,
- sizeof (struct sec_merge_hash_entry *), cmplengthentry);
-
- last4tab = htab_create_alloc ((size_t) sinfo->htab->size * 4,
- NULL, last4_eq, NULL, calloc, free);
- lasttab = htab_create_alloc ((size_t) sinfo->htab->size * 4,
- NULL, last_eq, NULL, calloc, free);
- if (lasttab == NULL || last4tab == NULL)
- goto alloc_failure;
-
- /* Now insert the strings into hash tables (strings with last 4 characters
- and strings with last character equal), look for longer strings which
- we're suffix of. */
- for (a = array, end = array + sinfo->htab->size; a < end; a++)
+ if (sinfo->htab->size != 0)
{
- register hashval_t hash;
- unsigned int c;
- unsigned int i;
- const unsigned char *s;
- PTR *p;
-
- e = *a;
- e->u.entsize = sinfo->htab->entsize;
- if (e->len <= e->u.entsize)
- break;
- if (e->len > 4 * e->u.entsize)
+ qsort (array, (size_t) sinfo->htab->size,
+ sizeof (struct sec_merge_hash_entry *),
+ (alignment != (unsigned) -1 && alignment > sinfo->htab->entsize
+ ? strrevcmp_align : strrevcmp));
+
+ /* Loop over the sorted array and merge suffixes */
+ e = *--a;
+ e->len += sinfo->htab->entsize;
+ while (--a >= array)
{
- s = (const unsigned char *) (e->root.string + e->len - e->u.entsize);
- hash = 0;
- for (i = 0; i < 4 * e->u.entsize; i++)
- {
- c = *--s;
- hash += c + (c << 17);
- hash ^= hash >> 2;
- }
- p = htab_find_slot_with_hash (last4tab, e, hash, INSERT);
- if (p == NULL)
- goto alloc_failure;
- if (*p)
- {
- struct sec_merge_hash_entry *ent;
+ struct sec_merge_hash_entry *cmp = *a;
- ent = (struct sec_merge_hash_entry *) *p;
- e->u.suffix = ent;
- e->alignment = 0;
- continue;
+ cmp->len += sinfo->htab->entsize;
+ if (e->alignment >= cmp->alignment
+ && !((e->len - cmp->len) & (cmp->alignment - 1))
+ && is_suffix (e, cmp))
+ {
+ cmp->u.suffix = e;
+ cmp->alignment = 0;
}
else
- *p = (PTR) e;
+ e = cmp;
}
- s = (const unsigned char *) (e->root.string + e->len - e->u.entsize);
- hash = 0;
- for (i = 0; i < e->u.entsize; i++)
- {
- c = *--s;
- hash += c + (c << 17);
- hash ^= hash >> 2;
- }
- p = htab_find_slot_with_hash (lasttab, e, hash, INSERT);
- if (p == NULL)
- goto alloc_failure;
- if (*p)
- {
- struct sec_merge_hash_entry *ent;
-
- ent = (struct sec_merge_hash_entry *) *p;
- e->u.suffix = ent;
- e->alignment = 0;
- }
- else
- *p = (PTR) e;
}
alloc_failure:
if (array)
free (array);
- if (lasttab)
- htab_delete (lasttab);
- if (last4tab)
- htab_delete (last4tab);
/* Now assign positions to the strings we want to keep. */
size = 0;
@@ -765,11 +675,9 @@ alloc_failure:
/* This function is called once after all SEC_MERGE sections are registered
with _bfd_merge_section. */
-boolean
-_bfd_merge_sections (abfd, xsinfo, remove_hook)
- bfd *abfd ATTRIBUTE_UNUSED;
- PTR xsinfo;
- void (*remove_hook) PARAMS((bfd *, asection *));
+bfd_boolean
+_bfd_merge_sections (bfd *abfd ATTRIBUTE_UNUSED, void *xsinfo,
+ void (*remove_hook) (bfd *, asection *))
{
struct sec_merge_info *sinfo;
@@ -830,23 +738,23 @@ _bfd_merge_sections (abfd, xsinfo, remove_hook)
secinfo->sec->_cooked_size = size;
}
- /* Finally shrink all input sections which have not made it into
+ /* Finally remove all input sections which have not made it into
the hash table at all. */
for (secinfo = sinfo->chain; secinfo; secinfo = secinfo->next)
- if (secinfo->first == NULL)
- secinfo->sec->_cooked_size = 0;
+ if (secinfo->first == NULL)
+ {
+ secinfo->sec->_cooked_size = 0;
+ secinfo->sec->flags |= SEC_EXCLUDE;
+ }
}
- return true;
+ return TRUE;
}
/* Write out the merged section. */
-boolean
-_bfd_write_merged_section (output_bfd, sec, psecinfo)
- bfd *output_bfd;
- asection *sec;
- PTR psecinfo;
+bfd_boolean
+_bfd_write_merged_section (bfd *output_bfd, asection *sec, void *psecinfo)
{
struct sec_merge_sec_info *secinfo;
file_ptr pos;
@@ -854,16 +762,16 @@ _bfd_write_merged_section (output_bfd, sec, psecinfo)
secinfo = (struct sec_merge_sec_info *) psecinfo;
if (!secinfo->first)
- return true;
+ return TRUE;
pos = sec->output_section->filepos + sec->output_offset;
if (bfd_seek (output_bfd, pos, SEEK_SET) != 0)
- return false;
+ return FALSE;
if (! sec_merge_emit (output_bfd, secinfo->first))
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
/* Adjust an address in the SEC_MERGE section. Given OFFSET within
@@ -871,11 +779,8 @@ _bfd_write_merged_section (output_bfd, sec, psecinfo)
section and writes the new section back into *PSEC. */
bfd_vma
-_bfd_merged_section_offset (output_bfd, psec, psecinfo, offset, addend)
- bfd *output_bfd ATTRIBUTE_UNUSED;
- asection **psec;
- PTR psecinfo;
- bfd_vma offset, addend;
+_bfd_merged_section_offset (bfd *output_bfd ATTRIBUTE_UNUSED, asection **psec,
+ void *psecinfo, bfd_vma offset, bfd_vma addend)
{
struct sec_merge_sec_info *secinfo;
struct sec_merge_hash_entry *entry;
@@ -928,7 +833,7 @@ _bfd_merged_section_offset (output_bfd, psec, psecinfo, offset, addend)
p = secinfo->contents
+ ((offset + addend) / sec->entsize) * sec->entsize;
}
- entry = sec_merge_hash_lookup (secinfo->htab, p, 0, false);
+ entry = sec_merge_hash_lookup (secinfo->htab, p, 0, FALSE);
if (!entry)
{
if (! secinfo->htab->strings)
diff --git a/contrib/binutils/bfd/netbsd-core.c b/contrib/binutils/bfd/netbsd-core.c
index 2787c46..84f2ad7 100644
--- a/contrib/binutils/bfd/netbsd-core.c
+++ b/contrib/binutils/bfd/netbsd-core.c
@@ -1,6 +1,6 @@
/* BFD back end for NetBSD style core files
Copyright 1988, 1989, 1991, 1992, 1993, 1996, 1998, 1999, 2000, 2001,
- 2002
+ 2002, 2003, 2004
Free Software Foundation, Inc.
Written by Paul Kranenburg, EUR
@@ -34,22 +34,29 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
* FIXME: On NetBSD/sparc CORE_FPU_OFFSET should be (sizeof (struct trapframe))
*/
+/* Offset of StackGhost cookie within `struct md_coredump' on
+ OpenBSD/sparc. */
+#define CORE_WCOOKIE_OFFSET 344
+
struct netbsd_core_struct {
struct core core;
} *rawptr;
/* forward declarations */
-static const bfd_target *netbsd_core_file_p PARAMS ((bfd *abfd));
-static char *netbsd_core_file_failing_command PARAMS ((bfd *abfd));
-static int netbsd_core_file_failing_signal PARAMS ((bfd *abfd));
-static boolean netbsd_core_file_matches_executable_p
+static const bfd_target *netbsd_core_file_p
+ PARAMS ((bfd *abfd));
+static char *netbsd_core_file_failing_command
+ PARAMS ((bfd *abfd));
+static int netbsd_core_file_failing_signal
+ PARAMS ((bfd *abfd));
+static bfd_boolean netbsd_core_file_matches_executable_p
PARAMS ((bfd *core_bfd, bfd *exec_bfd));
-static void swap_abort PARAMS ((void));
+static void swap_abort
+ PARAMS ((void));
/* Handle NetBSD-style core dump file. */
-/* ARGSUSED */
static const bfd_target *
netbsd_core_file_p (abfd)
bfd *abfd;
@@ -136,6 +143,25 @@ netbsd_core_file_p (abfd)
asect->filepos = offset;
asect->alignment_power = 2;
+ if (CORE_GETMID (core) == M_SPARC_NETBSD
+ && CORE_GETFLAG (coreseg) == CORE_CPU
+ && coreseg.c_size > CORE_WCOOKIE_OFFSET)
+ {
+ /* Truncate the .reg section. */
+ asect->_raw_size = CORE_WCOOKIE_OFFSET;
+
+ /* And create the .wcookie section. */
+ asect = bfd_make_section_anyway (abfd, ".wcookie");
+ if (asect == NULL)
+ goto punt;
+
+ asect->flags = SEC_ALLOC + SEC_HAS_CONTENTS;
+ asect->_raw_size = 4;
+ asect->vma = 0;
+ asect->filepos = offset + CORE_WCOOKIE_OFFSET;
+ asect->alignment_power = 2;
+ }
+
offset += coreseg.c_size;
#ifdef CORE_FPU_OFFSET
@@ -175,7 +201,6 @@ netbsd_core_file_failing_command (abfd)
return abfd->tdata.netbsd_core_data->core.c_name;
}
-/* ARGSUSED */
static int
netbsd_core_file_failing_signal (abfd)
bfd *abfd;
@@ -184,13 +209,12 @@ netbsd_core_file_failing_signal (abfd)
return abfd->tdata.netbsd_core_data->core.c_signo;
}
-/* ARGSUSED */
-static boolean
+static bfd_boolean
netbsd_core_file_matches_executable_p (core_bfd, exec_bfd)
bfd *core_bfd ATTRIBUTE_UNUSED;
bfd *exec_bfd ATTRIBUTE_UNUSED;
{
- return true; /* FIXME, We have no way of telling at this point */
+ return TRUE; /* FIXME, We have no way of telling at this point */
}
/* If somebody calls any byte-swapping routines, shoot them. */
@@ -199,10 +223,13 @@ swap_abort ()
{
abort (); /* This way doesn't require any declaration for ANSI to fuck up */
}
-#define NO_GET ((bfd_vma (*) PARAMS (( const bfd_byte *))) swap_abort )
-#define NO_PUT ((void (*) PARAMS ((bfd_vma, bfd_byte *))) swap_abort )
-#define NO_SIGNED_GET \
- ((bfd_signed_vma (*) PARAMS ((const bfd_byte *))) swap_abort )
+
+#define NO_GET ((bfd_vma (*) (const void *)) swap_abort)
+#define NO_PUT ((void (*) (bfd_vma, void *)) swap_abort)
+#define NO_GETS ((bfd_signed_vma (*) (const void *)) swap_abort)
+#define NO_GET64 ((bfd_uint64_t (*) (const void *)) swap_abort)
+#define NO_PUT64 ((void (*) (bfd_uint64_t, void *)) swap_abort)
+#define NO_GETS64 ((bfd_int64_t (*) (const void *)) swap_abort)
const bfd_target netbsd_core_vec =
{
@@ -217,39 +244,39 @@ const bfd_target netbsd_core_vec =
0, /* symbol prefix */
' ', /* ar_pad_char */
16, /* ar_max_namelen */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 64 bit data */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 32 bit data */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 16 bit data */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 64 bit hdrs */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 32 bit hdrs */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 16 bit hdrs */
+ NO_GET64, NO_GETS64, NO_PUT64, /* 64 bit data. */
+ NO_GET, NO_GETS, NO_PUT, /* 32 bit data. */
+ NO_GET, NO_GETS, NO_PUT, /* 16 bit data. */
+ NO_GET64, NO_GETS64, NO_PUT64, /* 64 bit hdrs. */
+ NO_GET, NO_GETS, NO_PUT, /* 32 bit hdrs. */
+ NO_GET, NO_GETS, NO_PUT, /* 16 bit hdrs. */
{ /* bfd_check_format */
- _bfd_dummy_target, /* unknown format */
- _bfd_dummy_target, /* object file */
- _bfd_dummy_target, /* archive */
- netbsd_core_file_p /* a core file */
+ _bfd_dummy_target, /* unknown format */
+ _bfd_dummy_target, /* object file */
+ _bfd_dummy_target, /* archive */
+ netbsd_core_file_p /* a core file */
},
{ /* bfd_set_format */
- bfd_false, bfd_false,
- bfd_false, bfd_false
+ bfd_false, bfd_false,
+ bfd_false, bfd_false
},
{ /* bfd_write_contents */
- bfd_false, bfd_false,
- bfd_false, bfd_false
+ bfd_false, bfd_false,
+ bfd_false, bfd_false
},
- BFD_JUMP_TABLE_GENERIC (_bfd_generic),
- BFD_JUMP_TABLE_COPY (_bfd_generic),
- BFD_JUMP_TABLE_CORE (netbsd),
- BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive),
- BFD_JUMP_TABLE_SYMBOLS (_bfd_nosymbols),
- BFD_JUMP_TABLE_RELOCS (_bfd_norelocs),
- BFD_JUMP_TABLE_WRITE (_bfd_generic),
- BFD_JUMP_TABLE_LINK (_bfd_nolink),
- BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
+ BFD_JUMP_TABLE_GENERIC (_bfd_generic),
+ BFD_JUMP_TABLE_COPY (_bfd_generic),
+ BFD_JUMP_TABLE_CORE (netbsd),
+ BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive),
+ BFD_JUMP_TABLE_SYMBOLS (_bfd_nosymbols),
+ BFD_JUMP_TABLE_RELOCS (_bfd_norelocs),
+ BFD_JUMP_TABLE_WRITE (_bfd_generic),
+ BFD_JUMP_TABLE_LINK (_bfd_nolink),
+ BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
NULL,
(PTR) 0 /* backend_data */
-};
+ };
diff --git a/contrib/binutils/bfd/netbsd.h b/contrib/binutils/bfd/netbsd.h
index 0558032..04a4eab 100644
--- a/contrib/binutils/bfd/netbsd.h
+++ b/contrib/binutils/bfd/netbsd.h
@@ -1,5 +1,5 @@
/* BFD back-end definitions used by all NetBSD targets.
- Copyright 1990, 1991, 1992, 1994, 1995, 1996, 1997, 1998, 2000
+ Copyright 1990, 1991, 1992, 1994, 1995, 1996, 1997, 1998, 2000, 2002
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -64,7 +64,7 @@ USA. */
#define MY_entry_is_text_address 1
#define MY_write_object_contents MY(write_object_contents)
-static boolean MY(write_object_contents) PARAMS ((bfd *abfd));
+static bfd_boolean MY(write_object_contents) PARAMS ((bfd *abfd));
#define MY_text_includes_header 1
#include "aout-target.h"
@@ -73,7 +73,7 @@ static boolean MY(write_object_contents) PARAMS ((bfd *abfd));
Section contents have already been written. We write the
file header, symbols, and relocation. */
-static boolean
+static bfd_boolean
MY(write_object_contents) (abfd)
bfd *abfd;
{
@@ -114,5 +114,5 @@ MY(write_object_contents) (abfd)
WRITE_HEADERS(abfd, execp);
- return true;
+ return TRUE;
}
diff --git a/contrib/binutils/bfd/opncls.c b/contrib/binutils/bfd/opncls.c
index cdf08df..6abd405 100644
--- a/contrib/binutils/bfd/opncls.c
+++ b/contrib/binutils/bfd/opncls.c
@@ -1,6 +1,6 @@
/* opncls.c -- open and close a BFD.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000,
- 2001, 2002
+ 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Support.
@@ -25,6 +25,7 @@
#include "sysdep.h"
#include "objalloc.h"
#include "libbfd.h"
+#include "libiberty.h"
#ifndef S_IXUSR
#define S_IXUSR 0100 /* Execute by owner. */
@@ -36,21 +37,27 @@
#define S_IXOTH 0001 /* Execute by others. */
#endif
+/* Counter used to initialize the bfd identifier. */
+
+static unsigned int _bfd_id_counter = 0;
+
/* fdopen is a loser -- we should use stdio exclusively. Unfortunately
if we do that we can't use fcntl. */
/* Return a new BFD. All BFD's are allocated through this routine. */
bfd *
-_bfd_new_bfd ()
+_bfd_new_bfd (void)
{
bfd *nbfd;
- nbfd = (bfd *) bfd_zmalloc ((bfd_size_type) sizeof (bfd));
+ nbfd = bfd_zmalloc (sizeof (bfd));
if (nbfd == NULL)
return NULL;
- nbfd->memory = (PTR) objalloc_create ();
+ nbfd->id = _bfd_id_counter++;
+
+ nbfd->memory = objalloc_create ();
if (nbfd->memory == NULL)
{
bfd_set_error (bfd_error_no_memory);
@@ -63,23 +70,24 @@ _bfd_new_bfd ()
nbfd->direction = no_direction;
nbfd->iostream = NULL;
nbfd->where = 0;
- if (!bfd_hash_table_init (&nbfd->section_htab, bfd_section_hash_newfunc))
+ if (!bfd_hash_table_init_n (& nbfd->section_htab, bfd_section_hash_newfunc,
+ 251))
{
free (nbfd);
return NULL;
}
- nbfd->sections = (asection *) NULL;
+ nbfd->sections = NULL;
nbfd->section_tail = &nbfd->sections;
nbfd->format = bfd_unknown;
- nbfd->my_archive = (bfd *) NULL;
+ nbfd->my_archive = NULL;
nbfd->origin = 0;
- nbfd->opened_once = false;
- nbfd->output_has_begun = false;
+ nbfd->opened_once = FALSE;
+ nbfd->output_has_begun = FALSE;
nbfd->section_count = 0;
- nbfd->usrdata = (PTR) NULL;
- nbfd->cacheable = false;
+ nbfd->usrdata = NULL;
+ nbfd->cacheable = FALSE;
nbfd->flags = BFD_NO_FLAGS;
- nbfd->mtime_set = false;
+ nbfd->mtime_set = FALSE;
return nbfd;
}
@@ -87,8 +95,7 @@ _bfd_new_bfd ()
/* Allocate a new BFD as a member of archive OBFD. */
bfd *
-_bfd_new_bfd_contained_in (obfd)
- bfd *obfd;
+_bfd_new_bfd_contained_in (bfd *obfd)
{
bfd *nbfd;
@@ -105,8 +112,7 @@ _bfd_new_bfd_contained_in (obfd)
/* Delete a BFD. */
void
-_bfd_delete_bfd (abfd)
- bfd *abfd;
+_bfd_delete_bfd (bfd *abfd)
{
bfd_hash_table_free (&abfd->section_htab);
objalloc_free ((struct objalloc *) abfd->memory);
@@ -124,7 +130,7 @@ FUNCTION
bfd_openr
SYNOPSIS
- bfd *bfd_openr(const char *filename, const char *target);
+ bfd *bfd_openr (const char *filename, const char *target);
DESCRIPTION
Open the file @var{filename} (using <<fopen>>) with the target
@@ -134,13 +140,12 @@ DESCRIPTION
that function.
If <<NULL>> is returned then an error has occured. Possible errors
- are <<bfd_error_no_memory>>, <<bfd_error_invalid_target>> or <<system_call>> error.
+ are <<bfd_error_no_memory>>, <<bfd_error_invalid_target>> or
+ <<system_call>> error.
*/
bfd *
-bfd_openr (filename, target)
- const char *filename;
- const char *target;
+bfd_openr (const char *filename, const char *target)
{
bfd *nbfd;
const bfd_target *target_vec;
@@ -179,35 +184,32 @@ bfd_openr (filename, target)
the file descriptor too, even though we didn't open it. */
/*
FUNCTION
- bfd_fdopenr
+ bfd_fdopenr
SYNOPSIS
- bfd *bfd_fdopenr(const char *filename, const char *target, int fd);
+ bfd *bfd_fdopenr (const char *filename, const char *target, int fd);
DESCRIPTION
- <<bfd_fdopenr>> is to <<bfd_fopenr>> much like <<fdopen>> is to <<fopen>>.
- It opens a BFD on a file already described by the @var{fd}
- supplied.
-
- When the file is later <<bfd_close>>d, the file descriptor will be closed.
-
- If the caller desires that this file descriptor be cached by BFD
- (opened as needed, closed as needed to free descriptors for
- other opens), with the supplied @var{fd} used as an initial
- file descriptor (but subject to closure at any time), call
- bfd_set_cacheable(bfd, 1) on the returned BFD. The default is to
- assume no cacheing; the file descriptor will remain open until
- <<bfd_close>>, and will not be affected by BFD operations on other
- files.
-
- Possible errors are <<bfd_error_no_memory>>, <<bfd_error_invalid_target>> and <<bfd_error_system_call>>.
+ <<bfd_fdopenr>> is to <<bfd_fopenr>> much like <<fdopen>> is to
+ <<fopen>>. It opens a BFD on a file already described by the
+ @var{fd} supplied.
+
+ When the file is later <<bfd_close>>d, the file descriptor will
+ be closed. If the caller desires that this file descriptor be
+ cached by BFD (opened as needed, closed as needed to free
+ descriptors for other opens), with the supplied @var{fd} used as
+ an initial file descriptor (but subject to closure at any time),
+ call bfd_set_cacheable(bfd, 1) on the returned BFD. The default
+ is to assume no caching; the file descriptor will remain open
+ until <<bfd_close>>, and will not be affected by BFD operations
+ on other files.
+
+ Possible errors are <<bfd_error_no_memory>>,
+ <<bfd_error_invalid_target>> and <<bfd_error_system_call>>.
*/
bfd *
-bfd_fdopenr (filename, target, fd)
- const char *filename;
- const char *target;
- int fd;
+bfd_fdopenr (const char *filename, const char *target, int fd)
{
bfd *nbfd;
const bfd_target *target_vec;
@@ -234,14 +236,14 @@ bfd_fdopenr (filename, target, fd)
}
#ifndef HAVE_FDOPEN
- nbfd->iostream = (PTR) fopen (filename, FOPEN_RB);
+ nbfd->iostream = fopen (filename, FOPEN_RB);
#else
/* (O_ACCMODE) parens are to avoid Ultrix header file bug. */
switch (fdflags & (O_ACCMODE))
{
- case O_RDONLY: nbfd->iostream = (PTR) fdopen (fd, FOPEN_RB); break;
- case O_WRONLY: nbfd->iostream = (PTR) fdopen (fd, FOPEN_RUB); break;
- case O_RDWR: nbfd->iostream = (PTR) fdopen (fd, FOPEN_RUB); break;
+ case O_RDONLY: nbfd->iostream = fdopen (fd, FOPEN_RB); break;
+ case O_WRONLY: nbfd->iostream = fdopen (fd, FOPEN_RUB); break;
+ case O_RDWR: nbfd->iostream = fdopen (fd, FOPEN_RUB); break;
default: abort ();
}
#endif
@@ -272,7 +274,7 @@ bfd_fdopenr (filename, target, fd)
_bfd_delete_bfd (nbfd);
return NULL;
}
- nbfd->opened_once = true;
+ nbfd->opened_once = TRUE;
return nbfd;
}
@@ -282,7 +284,7 @@ FUNCTION
bfd_openstreamr
SYNOPSIS
- bfd *bfd_openstreamr(const char *, const char *, PTR);
+ bfd *bfd_openstreamr (const char *, const char *, void *);
DESCRIPTION
@@ -291,12 +293,9 @@ DESCRIPTION
*/
bfd *
-bfd_openstreamr (filename, target, streamarg)
- const char *filename;
- const char *target;
- PTR streamarg;
+bfd_openstreamr (const char *filename, const char *target, void *streamarg)
{
- FILE *stream = (FILE *) streamarg;
+ FILE *stream = streamarg;
bfd *nbfd;
const bfd_target *target_vec;
@@ -311,7 +310,7 @@ bfd_openstreamr (filename, target, streamarg)
return NULL;
}
- nbfd->iostream = (PTR) stream;
+ nbfd->iostream = stream;
nbfd->filename = filename;
nbfd->direction = read_direction;
@@ -334,7 +333,7 @@ FUNCTION
bfd_openw
SYNOPSIS
- bfd *bfd_openw(const char *filename, const char *target);
+ bfd *bfd_openw (const char *filename, const char *target);
DESCRIPTION
Create a BFD, associated with file @var{filename}, using the
@@ -345,9 +344,7 @@ DESCRIPTION
*/
bfd *
-bfd_openw (filename, target)
- const char *filename;
- const char *target;
+bfd_openw (const char *filename, const char *target)
{
bfd *nbfd;
const bfd_target *target_vec;
@@ -385,14 +382,14 @@ FUNCTION
bfd_close
SYNOPSIS
- boolean bfd_close(bfd *abfd);
+ bfd_boolean bfd_close (bfd *abfd);
DESCRIPTION
- Close a BFD. If the BFD was open for writing,
- then pending operations are completed and the file written out
- and closed. If the created file is executable, then
- <<chmod>> is called to mark it as such.
+ Close a BFD. If the BFD was open for writing, then pending
+ operations are completed and the file written out and closed.
+ If the created file is executable, then <<chmod>> is called
+ to mark it as such.
All memory attached to the BFD is released.
@@ -400,24 +397,23 @@ DESCRIPTION
if it was passed in to BFD by <<bfd_fdopenr>>).
RETURNS
- <<true>> is returned if all is ok, otherwise <<false>>.
+ <<TRUE>> is returned if all is ok, otherwise <<FALSE>>.
*/
-boolean
-bfd_close (abfd)
- bfd *abfd;
+bfd_boolean
+bfd_close (bfd *abfd)
{
- boolean ret;
+ bfd_boolean ret;
if (bfd_write_p (abfd))
{
if (! BFD_SEND_FMT (abfd, _bfd_write_contents, (abfd)))
- return false;
+ return FALSE;
}
if (! BFD_SEND (abfd, _close_and_cleanup, (abfd)))
- return false;
+ return FALSE;
ret = bfd_cache_close (abfd);
@@ -431,7 +427,7 @@ bfd_close (abfd)
if (stat (abfd->filename, &buf) == 0)
{
- unsigned int mask = umask (0);
+ unsigned int mask = umask (0);
umask (mask);
chmod (abfd->filename,
@@ -450,13 +446,13 @@ FUNCTION
bfd_close_all_done
SYNOPSIS
- boolean bfd_close_all_done(bfd *);
+ bfd_boolean bfd_close_all_done (bfd *);
DESCRIPTION
- Close a BFD. Differs from <<bfd_close>>
- since it does not complete any pending operations. This
- routine would be used if the application had just used BFD for
- swapping and didn't want to use any of the writing code.
+ Close a BFD. Differs from <<bfd_close>> since it does not
+ complete any pending operations. This routine would be used
+ if the application had just used BFD for swapping and didn't
+ want to use any of the writing code.
If the created file is executable, then <<chmod>> is called
to mark it as such.
@@ -464,14 +460,13 @@ DESCRIPTION
All memory attached to the BFD is released.
RETURNS
- <<true>> is returned if all is ok, otherwise <<false>>.
+ <<TRUE>> is returned if all is ok, otherwise <<FALSE>>.
*/
-boolean
-bfd_close_all_done (abfd)
- bfd *abfd;
+bfd_boolean
+bfd_close_all_done (bfd *abfd)
{
- boolean ret;
+ bfd_boolean ret;
ret = bfd_cache_close (abfd);
@@ -504,19 +499,16 @@ FUNCTION
bfd_create
SYNOPSIS
- bfd *bfd_create(const char *filename, bfd *templ);
+ bfd *bfd_create (const char *filename, bfd *templ);
DESCRIPTION
- Create a new BFD in the manner of
- <<bfd_openw>>, but without opening a file. The new BFD
- takes the target from the target used by @var{template}. The
- format is always set to <<bfd_object>>.
+ Create a new BFD in the manner of <<bfd_openw>>, but without
+ opening a file. The new BFD takes the target from the target
+ used by @var{template}. The format is always set to <<bfd_object>>.
*/
bfd *
-bfd_create (filename, templ)
- const char *filename;
- bfd *templ;
+bfd_create (const char *filename, bfd *templ)
{
bfd *nbfd;
@@ -537,7 +529,7 @@ FUNCTION
bfd_make_writable
SYNOPSIS
- boolean bfd_make_writable(bfd *abfd);
+ bfd_boolean bfd_make_writable (bfd *abfd);
DESCRIPTION
Takes a BFD as created by <<bfd_create>> and converts it
@@ -546,24 +538,22 @@ DESCRIPTION
you will call <<bfd_make_readable>> on this bfd later.
RETURNS
- <<true>> is returned if all is ok, otherwise <<false>>.
+ <<TRUE>> is returned if all is ok, otherwise <<FALSE>>.
*/
-boolean
-bfd_make_writable(abfd)
- bfd *abfd;
+bfd_boolean
+bfd_make_writable (bfd *abfd)
{
struct bfd_in_memory *bim;
if (abfd->direction != no_direction)
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
- bim = ((struct bfd_in_memory *)
- bfd_malloc ((bfd_size_type) sizeof (struct bfd_in_memory)));
- abfd->iostream = (PTR) bim;
+ bim = bfd_malloc (sizeof (struct bfd_in_memory));
+ abfd->iostream = bim;
/* bfd_bwrite will grow these as needed. */
bim->size = 0;
bim->buffer = 0;
@@ -572,7 +562,7 @@ bfd_make_writable(abfd)
abfd->direction = write_direction;
abfd->where = 0;
- return true;
+ return TRUE;
}
/*
@@ -580,7 +570,7 @@ FUNCTION
bfd_make_readable
SYNOPSIS
- boolean bfd_make_readable(bfd *abfd);
+ bfd_boolean bfd_make_readable (bfd *abfd);
DESCRIPTION
Takes a BFD as created by <<bfd_create>> and
@@ -590,40 +580,39 @@ DESCRIPTION
direction.
RETURNS
- <<true>> is returned if all is ok, otherwise <<false>>. */
+ <<TRUE>> is returned if all is ok, otherwise <<FALSE>>. */
-boolean
-bfd_make_readable(abfd)
- bfd *abfd;
+bfd_boolean
+bfd_make_readable (bfd *abfd)
{
if (abfd->direction != write_direction || !(abfd->flags & BFD_IN_MEMORY))
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
if (! BFD_SEND_FMT (abfd, _bfd_write_contents, (abfd)))
- return false;
+ return FALSE;
if (! BFD_SEND (abfd, _close_and_cleanup, (abfd)))
- return false;
+ return FALSE;
abfd->arch_info = &bfd_default_arch_struct;
abfd->where = 0;
abfd->format = bfd_unknown;
- abfd->my_archive = (bfd *) NULL;
+ abfd->my_archive = NULL;
abfd->origin = 0;
- abfd->opened_once = false;
- abfd->output_has_begun = false;
+ abfd->opened_once = FALSE;
+ abfd->output_has_begun = FALSE;
abfd->section_count = 0;
- abfd->usrdata = (PTR) NULL;
- abfd->cacheable = false;
+ abfd->usrdata = NULL;
+ abfd->cacheable = FALSE;
abfd->flags = BFD_IN_MEMORY;
- abfd->mtime_set = false;
+ abfd->mtime_set = FALSE;
- abfd->target_defaulted = true;
+ abfd->target_defaulted = TRUE;
abfd->direction = read_direction;
abfd->sections = 0;
abfd->symcount = 0;
@@ -633,7 +622,7 @@ bfd_make_readable(abfd)
bfd_section_list_clear (abfd);
bfd_check_format (abfd, bfd_object);
- return true;
+ return TRUE;
}
/*
@@ -641,7 +630,7 @@ INTERNAL_FUNCTION
bfd_alloc
SYNOPSIS
- PTR bfd_alloc (bfd *abfd, size_t wanted);
+ void *bfd_alloc (bfd *abfd, size_t wanted);
DESCRIPTION
Allocate a block of @var{wanted} bytes of memory attached to
@@ -649,12 +638,10 @@ DESCRIPTION
*/
-PTR
-bfd_alloc (abfd, size)
- bfd *abfd;
- bfd_size_type size;
+void *
+bfd_alloc (bfd *abfd, bfd_size_type size)
{
- PTR ret;
+ void *ret;
if (size != (unsigned long) size)
{
@@ -668,12 +655,10 @@ bfd_alloc (abfd, size)
return ret;
}
-PTR
-bfd_zalloc (abfd, size)
- bfd *abfd;
- bfd_size_type size;
+void *
+bfd_zalloc (bfd *abfd, bfd_size_type size)
{
- PTR res;
+ void *res;
res = bfd_alloc (abfd, size);
if (res)
@@ -685,9 +670,506 @@ bfd_zalloc (abfd, size)
Note: Also frees all more recently allocated blocks! */
void
-bfd_release (abfd, block)
- bfd *abfd;
- PTR block;
+bfd_release (bfd *abfd, void *block)
{
objalloc_free_block ((struct objalloc *) abfd->memory, block);
}
+
+
+/*
+ GNU Extension: separate debug-info files
+
+ The idea here is that a special section called .gnu_debuglink might be
+ embedded in a binary file, which indicates that some *other* file
+ contains the real debugging information. This special section contains a
+ filename and CRC32 checksum, which we read and resolve to another file,
+ if it exists.
+
+ This facilitates "optional" provision of debugging information, without
+ having to provide two complete copies of every binary object (with and
+ without debug symbols).
+*/
+
+#define GNU_DEBUGLINK ".gnu_debuglink"
+/*
+FUNCTION
+ bfd_calc_gnu_debuglink_crc32
+
+SYNOPSIS
+ unsigned long bfd_calc_gnu_debuglink_crc32
+ (unsigned long crc, const unsigned char *buf, bfd_size_type len);
+
+DESCRIPTION
+ Computes a CRC value as used in the .gnu_debuglink section.
+ Advances the previously computed @var{crc} value by computing
+ and adding in the crc32 for @var{len} bytes of @var{buf}.
+
+RETURNS
+ Return the updated CRC32 value.
+*/
+
+unsigned long
+bfd_calc_gnu_debuglink_crc32 (unsigned long crc,
+ const unsigned char *buf,
+ bfd_size_type len)
+{
+ static const unsigned long crc32_table[256] =
+ {
+ 0x00000000, 0x77073096, 0xee0e612c, 0x990951ba, 0x076dc419,
+ 0x706af48f, 0xe963a535, 0x9e6495a3, 0x0edb8832, 0x79dcb8a4,
+ 0xe0d5e91e, 0x97d2d988, 0x09b64c2b, 0x7eb17cbd, 0xe7b82d07,
+ 0x90bf1d91, 0x1db71064, 0x6ab020f2, 0xf3b97148, 0x84be41de,
+ 0x1adad47d, 0x6ddde4eb, 0xf4d4b551, 0x83d385c7, 0x136c9856,
+ 0x646ba8c0, 0xfd62f97a, 0x8a65c9ec, 0x14015c4f, 0x63066cd9,
+ 0xfa0f3d63, 0x8d080df5, 0x3b6e20c8, 0x4c69105e, 0xd56041e4,
+ 0xa2677172, 0x3c03e4d1, 0x4b04d447, 0xd20d85fd, 0xa50ab56b,
+ 0x35b5a8fa, 0x42b2986c, 0xdbbbc9d6, 0xacbcf940, 0x32d86ce3,
+ 0x45df5c75, 0xdcd60dcf, 0xabd13d59, 0x26d930ac, 0x51de003a,
+ 0xc8d75180, 0xbfd06116, 0x21b4f4b5, 0x56b3c423, 0xcfba9599,
+ 0xb8bda50f, 0x2802b89e, 0x5f058808, 0xc60cd9b2, 0xb10be924,
+ 0x2f6f7c87, 0x58684c11, 0xc1611dab, 0xb6662d3d, 0x76dc4190,
+ 0x01db7106, 0x98d220bc, 0xefd5102a, 0x71b18589, 0x06b6b51f,
+ 0x9fbfe4a5, 0xe8b8d433, 0x7807c9a2, 0x0f00f934, 0x9609a88e,
+ 0xe10e9818, 0x7f6a0dbb, 0x086d3d2d, 0x91646c97, 0xe6635c01,
+ 0x6b6b51f4, 0x1c6c6162, 0x856530d8, 0xf262004e, 0x6c0695ed,
+ 0x1b01a57b, 0x8208f4c1, 0xf50fc457, 0x65b0d9c6, 0x12b7e950,
+ 0x8bbeb8ea, 0xfcb9887c, 0x62dd1ddf, 0x15da2d49, 0x8cd37cf3,
+ 0xfbd44c65, 0x4db26158, 0x3ab551ce, 0xa3bc0074, 0xd4bb30e2,
+ 0x4adfa541, 0x3dd895d7, 0xa4d1c46d, 0xd3d6f4fb, 0x4369e96a,
+ 0x346ed9fc, 0xad678846, 0xda60b8d0, 0x44042d73, 0x33031de5,
+ 0xaa0a4c5f, 0xdd0d7cc9, 0x5005713c, 0x270241aa, 0xbe0b1010,
+ 0xc90c2086, 0x5768b525, 0x206f85b3, 0xb966d409, 0xce61e49f,
+ 0x5edef90e, 0x29d9c998, 0xb0d09822, 0xc7d7a8b4, 0x59b33d17,
+ 0x2eb40d81, 0xb7bd5c3b, 0xc0ba6cad, 0xedb88320, 0x9abfb3b6,
+ 0x03b6e20c, 0x74b1d29a, 0xead54739, 0x9dd277af, 0x04db2615,
+ 0x73dc1683, 0xe3630b12, 0x94643b84, 0x0d6d6a3e, 0x7a6a5aa8,
+ 0xe40ecf0b, 0x9309ff9d, 0x0a00ae27, 0x7d079eb1, 0xf00f9344,
+ 0x8708a3d2, 0x1e01f268, 0x6906c2fe, 0xf762575d, 0x806567cb,
+ 0x196c3671, 0x6e6b06e7, 0xfed41b76, 0x89d32be0, 0x10da7a5a,
+ 0x67dd4acc, 0xf9b9df6f, 0x8ebeeff9, 0x17b7be43, 0x60b08ed5,
+ 0xd6d6a3e8, 0xa1d1937e, 0x38d8c2c4, 0x4fdff252, 0xd1bb67f1,
+ 0xa6bc5767, 0x3fb506dd, 0x48b2364b, 0xd80d2bda, 0xaf0a1b4c,
+ 0x36034af6, 0x41047a60, 0xdf60efc3, 0xa867df55, 0x316e8eef,
+ 0x4669be79, 0xcb61b38c, 0xbc66831a, 0x256fd2a0, 0x5268e236,
+ 0xcc0c7795, 0xbb0b4703, 0x220216b9, 0x5505262f, 0xc5ba3bbe,
+ 0xb2bd0b28, 0x2bb45a92, 0x5cb36a04, 0xc2d7ffa7, 0xb5d0cf31,
+ 0x2cd99e8b, 0x5bdeae1d, 0x9b64c2b0, 0xec63f226, 0x756aa39c,
+ 0x026d930a, 0x9c0906a9, 0xeb0e363f, 0x72076785, 0x05005713,
+ 0x95bf4a82, 0xe2b87a14, 0x7bb12bae, 0x0cb61b38, 0x92d28e9b,
+ 0xe5d5be0d, 0x7cdcefb7, 0x0bdbdf21, 0x86d3d2d4, 0xf1d4e242,
+ 0x68ddb3f8, 0x1fda836e, 0x81be16cd, 0xf6b9265b, 0x6fb077e1,
+ 0x18b74777, 0x88085ae6, 0xff0f6a70, 0x66063bca, 0x11010b5c,
+ 0x8f659eff, 0xf862ae69, 0x616bffd3, 0x166ccf45, 0xa00ae278,
+ 0xd70dd2ee, 0x4e048354, 0x3903b3c2, 0xa7672661, 0xd06016f7,
+ 0x4969474d, 0x3e6e77db, 0xaed16a4a, 0xd9d65adc, 0x40df0b66,
+ 0x37d83bf0, 0xa9bcae53, 0xdebb9ec5, 0x47b2cf7f, 0x30b5ffe9,
+ 0xbdbdf21c, 0xcabac28a, 0x53b39330, 0x24b4a3a6, 0xbad03605,
+ 0xcdd70693, 0x54de5729, 0x23d967bf, 0xb3667a2e, 0xc4614ab8,
+ 0x5d681b02, 0x2a6f2b94, 0xb40bbe37, 0xc30c8ea1, 0x5a05df1b,
+ 0x2d02ef8d
+ };
+ const unsigned char *end;
+
+ crc = ~crc & 0xffffffff;
+ for (end = buf + len; buf < end; ++ buf)
+ crc = crc32_table[(crc ^ *buf) & 0xff] ^ (crc >> 8);
+ return ~crc & 0xffffffff;;
+}
+
+
+/*
+INTERNAL_FUNCTION
+ get_debug_link_info
+
+SYNOPSIS
+ char *get_debug_link_info (bfd *abfd, unsigned long *crc32_out);
+
+DESCRIPTION
+ fetch the filename and CRC32 value for any separate debuginfo
+ associated with @var{abfd}. Return NULL if no such info found,
+ otherwise return filename and update @var{crc32_out}.
+*/
+
+static char *
+get_debug_link_info (bfd *abfd, unsigned long *crc32_out)
+{
+ asection * sect;
+ bfd_size_type debuglink_size;
+ unsigned long crc32;
+ char * contents;
+ int crc_offset;
+ bfd_boolean ret;
+
+ BFD_ASSERT (abfd);
+ BFD_ASSERT (crc32_out);
+
+ sect = bfd_get_section_by_name (abfd, GNU_DEBUGLINK);
+
+ if (sect == NULL)
+ return NULL;
+
+ debuglink_size = bfd_section_size (abfd, sect);
+
+ contents = malloc (debuglink_size);
+ if (contents == NULL)
+ return NULL;
+
+ ret = bfd_get_section_contents (abfd, sect, contents, 0, debuglink_size);
+ if (! ret)
+ {
+ free (contents);
+ return NULL;
+ }
+
+ /* Crc value is stored after the filename, aligned up to 4 bytes. */
+ crc_offset = strlen (contents) + 1;
+ crc_offset = (crc_offset + 3) & ~3;
+
+ crc32 = bfd_get_32 (abfd, contents + crc_offset);
+
+ *crc32_out = crc32;
+ return contents;
+}
+
+/*
+INTERNAL_FUNCTION
+ separate_debug_file_exists
+
+SYNOPSIS
+ bfd_boolean separate_debug_file_exists
+ (char *name, unsigned long crc32);
+
+DESCRIPTION
+ Checks to see if @var{name} is a file and if its contents
+ match @var{crc32}.
+*/
+
+static bfd_boolean
+separate_debug_file_exists (const char *name, const unsigned long crc)
+{
+ static char buffer [8 * 1024];
+ unsigned long file_crc = 0;
+ int fd;
+ bfd_size_type count;
+
+ BFD_ASSERT (name);
+
+ fd = open (name, O_RDONLY);
+ if (fd < 0)
+ return FALSE;
+
+ while ((count = read (fd, buffer, sizeof (buffer))) > 0)
+ file_crc = bfd_calc_gnu_debuglink_crc32 (file_crc, buffer, count);
+
+ close (fd);
+
+ return crc == file_crc;
+}
+
+
+/*
+INTERNAL_FUNCTION
+ find_separate_debug_file
+
+SYNOPSIS
+ char *find_separate_debug_file (bfd *abfd);
+
+DESCRIPTION
+ Searches @var{abfd} for a reference to separate debugging
+ information, scans various locations in the filesystem, including
+ the file tree rooted at @var{debug_file_directory}, and returns a
+ filename of such debugging information if the file is found and has
+ matching CRC32. Returns NULL if no reference to debugging file
+ exists, or file cannot be found.
+*/
+
+static char *
+find_separate_debug_file (bfd *abfd, const char *debug_file_directory)
+{
+ char *basename;
+ char *dir;
+ char *debugfile;
+ unsigned long crc32;
+ int i;
+
+ BFD_ASSERT (abfd);
+ if (debug_file_directory == NULL)
+ debug_file_directory = ".";
+
+ /* BFD may have been opened from a stream. */
+ if (! abfd->filename)
+ return NULL;
+
+ basename = get_debug_link_info (abfd, & crc32);
+ if (basename == NULL)
+ return NULL;
+
+ if (strlen (basename) < 1)
+ {
+ free (basename);
+ return NULL;
+ }
+
+ dir = strdup (abfd->filename);
+ if (dir == NULL)
+ {
+ free (basename);
+ return NULL;
+ }
+ BFD_ASSERT (strlen (dir) != 0);
+
+ /* Strip off filename part. */
+ for (i = strlen (dir) - 1; i >= 0; i--)
+ if (IS_DIR_SEPARATOR (dir[i]))
+ break;
+
+ dir[i + 1] = '\0';
+ BFD_ASSERT (dir[i] == '/' || dir[0] == '\0')
+
+ debugfile = malloc (strlen (debug_file_directory) + 1
+ + strlen (dir)
+ + strlen (".debug/")
+ + strlen (basename)
+ + 1);
+ if (debugfile == NULL)
+ {
+ free (basename);
+ free (dir);
+ return NULL;
+ }
+
+ /* First try in the same directory as the original file: */
+ strcpy (debugfile, dir);
+ strcat (debugfile, basename);
+
+ if (separate_debug_file_exists (debugfile, crc32))
+ {
+ free (basename);
+ free (dir);
+ return debugfile;
+ }
+
+ /* Then try in a subdirectory called .debug. */
+ strcpy (debugfile, dir);
+ strcat (debugfile, ".debug/");
+ strcat (debugfile, basename);
+
+ if (separate_debug_file_exists (debugfile, crc32))
+ {
+ free (basename);
+ free (dir);
+ return debugfile;
+ }
+
+ /* Then try in the global debugfile directory. */
+ strcpy (debugfile, debug_file_directory);
+ i = strlen (debug_file_directory) - 1;
+ if (i > 0
+ && debug_file_directory[i] != '/'
+ && dir[0] != '/')
+ strcat (debugfile, "/");
+ strcat (debugfile, dir);
+ strcat (debugfile, basename);
+
+ if (separate_debug_file_exists (debugfile, crc32))
+ {
+ free (basename);
+ free (dir);
+ return debugfile;
+ }
+
+ free (debugfile);
+ free (basename);
+ free (dir);
+ return NULL;
+}
+
+
+/*
+FUNCTION
+ bfd_follow_gnu_debuglink
+
+SYNOPSIS
+ char *bfd_follow_gnu_debuglink (bfd *abfd, const char *dir);
+
+DESCRIPTION
+
+ Takes a BFD and searches it for a .gnu_debuglink section. If this
+ section is found, it examines the section for the name and checksum
+ of a '.debug' file containing auxiliary debugging information. It
+ then searches the filesystem for this .debug file in some standard
+ locations, including the directory tree rooted at @var{dir}, and if
+ found returns the full filename.
+
+ If @var{dir} is NULL, it will search a default path configured into
+ libbfd at build time. [XXX this feature is not currently
+ implemented].
+
+RETURNS
+ <<NULL>> on any errors or failure to locate the .debug file,
+ otherwise a pointer to a heap-allocated string containing the
+ filename. The caller is responsible for freeing this string.
+*/
+
+char *
+bfd_follow_gnu_debuglink (bfd *abfd, const char *dir)
+{
+#if 0 /* Disabled until DEBUGDIR can be defined by configure.in. */
+ if (dir == NULL)
+ dir = DEBUGDIR;
+#endif
+ return find_separate_debug_file (abfd, dir);
+}
+
+/*
+FUNCTION
+ bfd_create_gnu_debuglink_section
+
+SYNOPSIS
+ struct bfd_section *bfd_create_gnu_debuglink_section
+ (bfd *abfd, const char *filename);
+
+DESCRIPTION
+
+ Takes a @var{BFD} and adds a .gnu_debuglink section to it. The section is sized
+ to be big enough to contain a link to the specified @var{filename}.
+
+RETURNS
+ A pointer to the new section is returned if all is ok. Otherwise <<NULL>> is
+ returned and bfd_error is set.
+*/
+
+asection *
+bfd_create_gnu_debuglink_section (bfd *abfd, const char *filename)
+{
+ asection *sect;
+ bfd_size_type debuglink_size;
+
+ if (abfd == NULL || filename == NULL)
+ {
+ bfd_set_error (bfd_error_invalid_operation);
+ return NULL;
+ }
+
+ /* Strip off any path components in filename. */
+ filename = lbasename (filename);
+
+ sect = bfd_get_section_by_name (abfd, GNU_DEBUGLINK);
+ if (sect)
+ {
+ /* Section already exists. */
+ bfd_set_error (bfd_error_invalid_operation);
+ return NULL;
+ }
+
+ sect = bfd_make_section (abfd, GNU_DEBUGLINK);
+ if (sect == NULL)
+ return NULL;
+
+ if (! bfd_set_section_flags (abfd, sect,
+ SEC_HAS_CONTENTS | SEC_READONLY | SEC_DEBUGGING))
+ /* XXX Should we delete the section from the bfd ? */
+ return NULL;
+
+
+ debuglink_size = strlen (filename) + 1;
+ debuglink_size += 3;
+ debuglink_size &= ~3;
+ debuglink_size += 4;
+
+ if (! bfd_set_section_size (abfd, sect, debuglink_size))
+ /* XXX Should we delete the section from the bfd ? */
+ return NULL;
+
+ return sect;
+}
+
+
+/*
+FUNCTION
+ bfd_fill_in_gnu_debuglink_section
+
+SYNOPSIS
+ bfd_boolean bfd_fill_in_gnu_debuglink_section
+ (bfd *abfd, struct bfd_section *sect, const char *filename);
+
+DESCRIPTION
+
+ Takes a @var{BFD} and containing a .gnu_debuglink section @var{SECT}
+ and fills in the contents of the section to contain a link to the
+ specified @var{filename}. The filename should be relative to the
+ current directory.
+
+RETURNS
+ <<TRUE>> is returned if all is ok. Otherwise <<FALSE>> is returned
+ and bfd_error is set.
+*/
+
+bfd_boolean
+bfd_fill_in_gnu_debuglink_section (bfd *abfd,
+ struct bfd_section *sect,
+ const char *filename)
+{
+ bfd_size_type debuglink_size;
+ unsigned long crc32;
+ char * contents;
+ bfd_size_type crc_offset;
+ FILE * handle;
+ static char buffer[8 * 1024];
+ size_t count;
+
+ if (abfd == NULL || sect == NULL || filename == NULL)
+ {
+ bfd_set_error (bfd_error_invalid_operation);
+ return FALSE;
+ }
+
+ /* Make sure that we can read the file.
+ XXX - Should we attempt to locate the debug info file using the same
+ algorithm as gdb ? At the moment, since we are creating the
+ .gnu_debuglink section, we insist upon the user providing us with a
+ correct-for-section-creation-time path, but this need not conform to
+ the gdb location algorithm. */
+ handle = fopen (filename, FOPEN_RB);
+ if (handle == NULL)
+ {
+ bfd_set_error (bfd_error_system_call);
+ return FALSE;
+ }
+
+ crc32 = 0;
+ while ((count = fread (buffer, 1, sizeof buffer, handle)) > 0)
+ crc32 = bfd_calc_gnu_debuglink_crc32 (crc32, buffer, count);
+ fclose (handle);
+
+ /* Strip off any path components in filename,
+ now that we no longer need them. */
+ filename = lbasename (filename);
+
+ debuglink_size = strlen (filename) + 1;
+ debuglink_size += 3;
+ debuglink_size &= ~3;
+ debuglink_size += 4;
+
+ contents = malloc (debuglink_size);
+ if (contents == NULL)
+ {
+ /* XXX Should we delete the section from the bfd ? */
+ bfd_set_error (bfd_error_no_memory);
+ return FALSE;
+ }
+
+ strcpy (contents, filename);
+ crc_offset = debuglink_size - 4;
+
+ bfd_put_32 (abfd, crc32, contents + crc_offset);
+
+ if (! bfd_set_section_contents (abfd, sect, contents, 0, debuglink_size))
+ {
+ /* XXX Should we delete the section from the bfd ? */
+ free (contents);
+ return FALSE;
+ }
+
+ return TRUE;
+}
diff --git a/contrib/binutils/bfd/osf-core.c b/contrib/binutils/bfd/osf-core.c
index 862342e..8273504 100644
--- a/contrib/binutils/bfd/osf-core.c
+++ b/contrib/binutils/bfd/osf-core.c
@@ -1,5 +1,5 @@
/* BFD back-end for OSF/1 core files.
- Copyright 1993, 1994, 1995, 1998, 1999, 2001, 2002
+ Copyright 1993, 1994, 1995, 1998, 1999, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -32,11 +32,16 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
static asection *make_bfd_asection
PARAMS ((bfd *, const char *, flagword, bfd_size_type, bfd_vma, file_ptr));
-static const bfd_target *osf_core_core_file_p PARAMS ((bfd *));
-static char *osf_core_core_file_failing_command PARAMS ((bfd *));
-static int osf_core_core_file_failing_signal PARAMS ((bfd *));
-static boolean osf_core_core_file_matches_executable_p PARAMS ((bfd *, bfd *));
-static void swap_abort PARAMS ((void));
+static const bfd_target *osf_core_core_file_p
+ PARAMS ((bfd *));
+static char *osf_core_core_file_failing_command
+ PARAMS ((bfd *));
+static int osf_core_core_file_failing_signal
+ PARAMS ((bfd *));
+static bfd_boolean osf_core_core_file_matches_executable_p
+ PARAMS ((bfd *, bfd *));
+static void swap_abort
+ PARAMS ((void));
/* These are stored in the bfd's tdata */
@@ -159,7 +164,6 @@ osf_core_core_file_failing_command (abfd)
return core_command (abfd);
}
-/* ARGSUSED */
static int
osf_core_core_file_failing_signal (abfd)
bfd *abfd;
@@ -167,13 +171,12 @@ osf_core_core_file_failing_signal (abfd)
return core_signal (abfd);
}
-/* ARGSUSED */
-static boolean
+static bfd_boolean
osf_core_core_file_matches_executable_p (core_bfd, exec_bfd)
bfd *core_bfd ATTRIBUTE_UNUSED;
bfd *exec_bfd ATTRIBUTE_UNUSED;
{
- return true; /* FIXME, We have no way of telling at this point */
+ return TRUE; /* FIXME, We have no way of telling at this point */
}
/* If somebody calls any byte-swapping routines, shoot them. */
@@ -182,10 +185,13 @@ swap_abort()
{
abort(); /* This way doesn't require any declaration for ANSI to fuck up */
}
-#define NO_GET ((bfd_vma (*) PARAMS (( const bfd_byte *))) swap_abort )
-#define NO_PUT ((void (*) PARAMS ((bfd_vma, bfd_byte *))) swap_abort )
-#define NO_SIGNED_GET \
- ((bfd_signed_vma (*) PARAMS ((const bfd_byte *))) swap_abort )
+
+#define NO_GET ((bfd_vma (*) (const void *)) swap_abort)
+#define NO_PUT ((void (*) (bfd_vma, void *)) swap_abort)
+#define NO_GETS ((bfd_signed_vma (*) (const void *)) swap_abort)
+#define NO_GET64 ((bfd_uint64_t (*) (const void *)) swap_abort)
+#define NO_PUT64 ((void (*) (bfd_uint64_t, void *)) swap_abort)
+#define NO_GETS64 ((bfd_int64_t (*) (const void *)) swap_abort)
const bfd_target osf_core_vec =
{
@@ -200,26 +206,26 @@ const bfd_target osf_core_vec =
0, /* symbol prefix */
' ', /* ar_pad_char */
16, /* ar_max_namelen */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 64 bit data */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 32 bit data */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 16 bit data */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 64 bit hdrs */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 32 bit hdrs */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 16 bit hdrs */
+ NO_GET64, NO_GETS64, NO_PUT64, /* 64 bit data */
+ NO_GET, NO_GETS, NO_PUT, /* 32 bit data */
+ NO_GET, NO_GETS, NO_PUT, /* 16 bit data */
+ NO_GET64, NO_GETS64, NO_PUT64, /* 64 bit hdrs */
+ NO_GET, NO_GETS, NO_PUT, /* 32 bit hdrs */
+ NO_GET, NO_GETS, NO_PUT, /* 16 bit hdrs */
{ /* bfd_check_format */
- _bfd_dummy_target, /* unknown format */
- _bfd_dummy_target, /* object file */
- _bfd_dummy_target, /* archive */
- osf_core_core_file_p /* a core file */
+ _bfd_dummy_target, /* unknown format */
+ _bfd_dummy_target, /* object file */
+ _bfd_dummy_target, /* archive */
+ osf_core_core_file_p /* a core file */
},
{ /* bfd_set_format */
- bfd_false, bfd_false,
- bfd_false, bfd_false
+ bfd_false, bfd_false,
+ bfd_false, bfd_false
},
{ /* bfd_write_contents */
- bfd_false, bfd_false,
- bfd_false, bfd_false
+ bfd_false, bfd_false,
+ bfd_false, bfd_false
},
BFD_JUMP_TABLE_GENERIC (_bfd_generic),
@@ -235,4 +241,4 @@ const bfd_target osf_core_vec =
NULL,
(PTR) 0 /* backend_data */
-};
+ };
diff --git a/contrib/binutils/bfd/pe-arm.c b/contrib/binutils/bfd/pe-arm.c
index dbb4789..8b5d1c7 100644
--- a/contrib/binutils/bfd/pe-arm.c
+++ b/contrib/binutils/bfd/pe-arm.c
@@ -1,5 +1,5 @@
/* BFD back-end for ARM PECOFF files.
- Copyright 1995, 1996, 1999, 2000, 2001 Free Software Foundation, Inc.
+ Copyright 1995, 1996, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -28,7 +28,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#endif
#define COFF_WITH_PE
-#define PCRELOFFSET true
+#define PCRELOFFSET TRUE
#define COFF_LONG_SECTION_NAMES
#ifndef bfd_arm_allocate_interworking_sections
diff --git a/contrib/binutils/bfd/pe-i386.c b/contrib/binutils/bfd/pe-i386.c
index 9c75f95..a912cff 100644
--- a/contrib/binutils/bfd/pe-i386.c
+++ b/contrib/binutils/bfd/pe-i386.c
@@ -23,7 +23,7 @@
#define TARGET_SYM i386pe_vec
#define TARGET_NAME "pe-i386"
#define COFF_WITH_PE
-#define PCRELOFFSET true
+#define PCRELOFFSET TRUE
#define TARGET_UNDERSCORE '_'
#define COFF_LONG_SECTION_NAMES
#define COFF_LONG_FILENAMES
diff --git a/contrib/binutils/bfd/peXXigen.c b/contrib/binutils/bfd/peXXigen.c
index b643f3c..598aa7c 100644
--- a/contrib/binutils/bfd/peXXigen.c
+++ b/contrib/binutils/bfd/peXXigen.c
@@ -1,5 +1,5 @@
/* Support for the generic parts of PE/PEI; the common executable parts.
- Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
+ Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
Written by Cygnus Solutions.
@@ -91,10 +91,10 @@
static void add_data_entry
PARAMS ((bfd *, struct internal_extra_pe_aouthdr *, int, char *, bfd_vma));
-static boolean pe_print_pdata PARAMS ((bfd *, PTR));
-static boolean pe_print_reloc PARAMS ((bfd *, PTR));
-static boolean pe_print_idata PARAMS ((bfd *, PTR));
-static boolean pe_print_edata PARAMS ((bfd *, PTR));
+static bfd_boolean pe_print_pdata PARAMS ((bfd *, PTR));
+static bfd_boolean pe_print_reloc PARAMS ((bfd *, PTR));
+static bfd_boolean pe_print_idata PARAMS ((bfd *, PTR));
+static bfd_boolean pe_print_edata PARAMS ((bfd *, PTR));
void
@@ -570,7 +570,8 @@ _bfd_XXi_swap_aouthdr_out (abfd, in, out)
struct internal_extra_pe_aouthdr *extra = &pe->pe_opthdr;
PEAOUTHDR *aouthdr_out = (PEAOUTHDR *) out;
bfd_vma sa, fa, ib;
-
+ IMAGE_DATA_DIRECTORY idata2, idata5, tls;
+
if (pe->force_minimum_alignment)
{
if (!extra->FileAlignment)
@@ -586,6 +587,10 @@ _bfd_XXi_swap_aouthdr_out (abfd, in, out)
fa = extra->FileAlignment;
ib = extra->ImageBase;
+ idata2 = pe->pe_opthdr.DataDirectory[1];
+ idata5 = pe->pe_opthdr.DataDirectory[12];
+ tls = pe->pe_opthdr.DataDirectory[9];
+
if (aouthdr_in->tsize)
{
aouthdr_in->text_start -= ib;
@@ -614,28 +619,35 @@ _bfd_XXi_swap_aouthdr_out (abfd, in, out)
#define SA(x) (((x) + sa -1 ) & (- sa))
/* We like to have the sizes aligned. */
-
aouthdr_in->bsize = FA (aouthdr_in->bsize);
extra->NumberOfRvaAndSizes = IMAGE_NUMBEROF_DIRECTORY_ENTRIES;
- /* first null out all data directory entries .. */
+ /* First null out all data directory entries. */
memset (extra->DataDirectory, 0, sizeof (extra->DataDirectory));
add_data_entry (abfd, extra, 0, ".edata", ib);
-
- /* Don't call add_data_entry for .idata$2 or .idata$5. It's done in
- bfd_coff_final_link where all the required information is
- available. */
-
- /* However, until other .idata fixes are made (pending patch), the
- entry for .idata is needed for backwards compatability. FIXME. */
- add_data_entry (abfd, extra, 1, ".idata", ib);
-
add_data_entry (abfd, extra, 2, ".rsrc", ib);
-
add_data_entry (abfd, extra, 3, ".pdata", ib);
+ /* In theory we do not need to call add_data_entry for .idata$2 or
+ .idata$5. It will be done in bfd_coff_final_link where all the
+ required information is available. If however, we are not going
+ to perform a final link, eg because we have been invoked by objcopy
+ or strip, then we need to make sure that these Data Directory
+ entries are initialised properly.
+
+ So - we copy the input values into the output values, and then, if
+ a final link is going to be performed, it can overwrite them. */
+ extra->DataDirectory[1] = idata2;
+ extra->DataDirectory[12] = idata5;
+ extra->DataDirectory[9] = tls;
+
+ if (extra->DataDirectory[1].VirtualAddress == 0)
+ /* Until other .idata fixes are made (pending patch), the entry for
+ .idata is needed for backwards compatibility. FIXME. */
+ add_data_entry (abfd, extra, 1, ".idata", ib);
+
/* For some reason, the virtual size (which is what's set by
add_data_entry) for .reloc is not the same as the size recorded
in this slot by MSVC; it doesn't seem to cause problems (so far),
@@ -663,7 +675,9 @@ _bfd_XXi_swap_aouthdr_out (abfd, in, out)
5.0 link.exe) where the file size of the .data segment is
quite small compared to the virtual size. Without this
fix, strip munges the file. */
- isize += SA (FA (pei_section_data (abfd, sec)->virt_size));
+ if (coff_section_data (abfd, sec) != NULL
+ && pei_section_data (abfd, sec) != NULL)
+ isize += SA (FA (pei_section_data (abfd, sec)->virt_size));
}
aouthdr_in->dsize = dsize;
@@ -689,7 +703,7 @@ _bfd_XXi_swap_aouthdr_out (abfd, in, out)
aouthdr_out->standard.text_start);
#ifndef COFF_WITH_pep
- /* PE32+ does not have data_start member! */
+ /* PE32+ does not have data_start member! */
PUT_AOUTHDR_DATA_START (abfd, aouthdr_in->data_start,
aouthdr_out->standard.data_start);
#endif
@@ -895,12 +909,24 @@ _bfd_XXi_swap_scnhdr_out (abfd, in, out)
sometimes). */
if ((scnhdr_int->s_flags & IMAGE_SCN_CNT_UNINITIALIZED_DATA) != 0)
{
- ps = scnhdr_int->s_size;
- ss = 0;
+ if (bfd_pe_executable_p (abfd))
+ {
+ ps = scnhdr_int->s_size;
+ ss = 0;
+ }
+ else
+ {
+ ps = 0;
+ ss = scnhdr_int->s_size;
+ }
}
else
{
- ps = scnhdr_int->s_paddr;
+ if (bfd_pe_executable_p (abfd))
+ ps = scnhdr_int->s_paddr;
+ else
+ ps = 0;
+
ss = scnhdr_int->s_size;
}
@@ -917,33 +943,76 @@ _bfd_XXi_swap_scnhdr_out (abfd, in, out)
PUT_SCNHDR_LNNOPTR (abfd, scnhdr_int->s_lnnoptr,
scnhdr_ext->s_lnnoptr);
- /* Extra flags must be set when dealing with NT. All sections should also
- have the IMAGE_SCN_MEM_READ (0x40000000) flag set. In addition, the
- .text section must have IMAGE_SCN_MEM_EXECUTE (0x20000000) and the data
- sections (.idata, .data, .bss, .CRT) must have IMAGE_SCN_MEM_WRITE set
- (this is especially important when dealing with the .idata section since
- the addresses for routines from .dlls must be overwritten). If .reloc
- section data is ever generated, we must add IMAGE_SCN_MEM_DISCARDABLE
- (0x02000000). Also, the resource data should also be read and
- writable. */
-
- /* FIXME: alignment is also encoded in this field, at least on ppc (krk) */
- /* FIXME: even worse, I don't see how to get the original alignment field*/
- /* back... */
-
{
+ /* Extra flags must be set when dealing with PE. All sections should also
+ have the IMAGE_SCN_MEM_READ (0x40000000) flag set. In addition, the
+ .text section must have IMAGE_SCN_MEM_EXECUTE (0x20000000) and the data
+ sections (.idata, .data, .bss, .CRT) must have IMAGE_SCN_MEM_WRITE set
+ (this is especially important when dealing with the .idata section since
+ the addresses for routines from .dlls must be overwritten). If .reloc
+ section data is ever generated, we must add IMAGE_SCN_MEM_DISCARDABLE
+ (0x02000000). Also, the resource data should also be read and
+ writable. */
+
+ /* FIXME: Alignment is also encoded in this field, at least on PPC and
+ ARM-WINCE. Although - how do we get the original alignment field
+ back ? */
+
+ typedef struct
+ {
+ const char * section_name;
+ unsigned long must_have;
+ }
+ pe_required_section_flags;
+
+ pe_required_section_flags known_sections [] =
+ {
+ { ".arch", IMAGE_SCN_MEM_READ | IMAGE_SCN_CNT_INITIALIZED_DATA | IMAGE_SCN_MEM_DISCARDABLE | IMAGE_SCN_ALIGN_8BYTES },
+ { ".bss", IMAGE_SCN_MEM_READ | IMAGE_SCN_CNT_UNINITIALIZED_DATA | IMAGE_SCN_MEM_WRITE },
+ { ".data", IMAGE_SCN_MEM_READ | IMAGE_SCN_CNT_INITIALIZED_DATA | IMAGE_SCN_MEM_WRITE },
+ { ".edata", IMAGE_SCN_MEM_READ | IMAGE_SCN_CNT_INITIALIZED_DATA },
+ { ".idata", IMAGE_SCN_MEM_READ | IMAGE_SCN_CNT_INITIALIZED_DATA | IMAGE_SCN_MEM_WRITE },
+ { ".pdata", IMAGE_SCN_MEM_READ | IMAGE_SCN_CNT_INITIALIZED_DATA },
+ { ".rdata", IMAGE_SCN_MEM_READ | IMAGE_SCN_CNT_INITIALIZED_DATA },
+ { ".reloc", IMAGE_SCN_MEM_READ | IMAGE_SCN_CNT_INITIALIZED_DATA | IMAGE_SCN_MEM_DISCARDABLE },
+ { ".rsrc", IMAGE_SCN_MEM_READ | IMAGE_SCN_CNT_INITIALIZED_DATA | IMAGE_SCN_MEM_WRITE },
+ { ".text" , IMAGE_SCN_MEM_READ | IMAGE_SCN_CNT_CODE | IMAGE_SCN_MEM_EXECUTE },
+ { ".tls", IMAGE_SCN_MEM_READ | IMAGE_SCN_CNT_INITIALIZED_DATA | IMAGE_SCN_MEM_WRITE },
+ { ".xdata", IMAGE_SCN_MEM_READ | IMAGE_SCN_CNT_INITIALIZED_DATA },
+ { NULL, 0}
+ };
+
+ pe_required_section_flags * p;
int flags = scnhdr_int->s_flags;
+ /* We have defaulted to adding the IMAGE_SCN_MEM_WRITE flag, but now
+ we know exactly what this specific section wants so we remove it
+ and then allow the must_have field to add it back in if necessary.
+ However, we don't remove IMAGE_SCN_MEM_WRITE flag from .text if the
+ default WP_TEXT file flag has been cleared. WP_TEXT may be cleared
+ by ld --enable-auto-import (if auto-import is actually needed),
+ by ld --omagic, or by obcopy --writable-text. */
+
+ for (p = known_sections; p->section_name; p++)
+ if (strcmp (scnhdr_int->s_name, p->section_name) == 0)
+ {
+ if (strcmp (scnhdr_int->s_name, ".text")
+ || (bfd_get_file_flags (abfd) & WP_TEXT))
+ flags &= ~IMAGE_SCN_MEM_WRITE;
+ flags |= p->must_have;
+ break;
+ }
+
H_PUT_32 (abfd, flags, scnhdr_ext->s_flags);
}
if (coff_data (abfd)->link_info
- && ! coff_data (abfd)->link_info->relocateable
+ && ! coff_data (abfd)->link_info->relocatable
&& ! coff_data (abfd)->link_info->shared
&& strcmp (scnhdr_int->s_name, ".text") == 0)
{
/* By inference from looking at MS output, the 32 bit field
- which is the combintion of the number_of_relocs and
+ which is the combination of the number_of_relocs and
number_of_linenos is used for the line number count in
executables. A 16-bit field won't do for cc1. The MS
document says that the number of relocs is zero for
@@ -967,7 +1036,11 @@ _bfd_XXi_swap_scnhdr_out (abfd, in, out)
ret = 0;
}
- if (scnhdr_int->s_nreloc <= 0xffff)
+ /* Although we could encode 0xffff relocs here, we do not, to be
+ consistent with other parts of bfd. Also it lets us warn, as
+ we should never see 0xffff here w/o having the overflow flag
+ set. */
+ if (scnhdr_int->s_nreloc < 0xffff)
H_PUT_16 (abfd, scnhdr_int->s_nreloc, scnhdr_ext->s_nreloc);
else
{
@@ -1016,7 +1089,7 @@ static char * dir_names[IMAGE_NUMBEROF_DIRECTORY_ENTRIES] =
PPC- specific code. */
#endif
-static boolean
+static bfd_boolean
pe_print_idata (abfd, vfile)
bfd *abfd;
PTR vfile;
@@ -1048,12 +1121,12 @@ pe_print_idata (abfd, vfile)
/* Maybe the extra header isn't there. Look for the section. */
section = bfd_get_section_by_name (abfd, ".idata");
if (section == NULL)
- return true;
+ return TRUE;
addr = section->vma;
datasize = bfd_section_size (abfd, section);
if (datasize == 0)
- return true;
+ return TRUE;
}
else
{
@@ -1069,7 +1142,7 @@ pe_print_idata (abfd, vfile)
{
fprintf (file,
_("\nThere is an import table, but the section containing it could not be found\n"));
- return true;
+ return TRUE;
}
}
@@ -1098,7 +1171,7 @@ pe_print_idata (abfd, vfile)
amt = bfd_section_size (abfd, rel_section);
data = (bfd_byte *) bfd_malloc (amt);
if (data == NULL && amt != 0)
- return false;
+ return FALSE;
bfd_get_section_contents (abfd, rel_section, (PTR) data, (bfd_vma) 0,
amt);
@@ -1134,11 +1207,11 @@ pe_print_idata (abfd, vfile)
amt = dataoff + datasize;
data = (bfd_byte *) bfd_malloc (amt);
if (data == NULL)
- return false;
+ return FALSE;
/* Read the whole section. Some of the fields might be before dataoff. */
if (! bfd_get_section_contents (abfd, section, (PTR) data, (bfd_vma) 0, amt))
- return false;
+ return FALSE;
adj = section->vma - extra->ImageBase;
@@ -1290,10 +1363,10 @@ pe_print_idata (abfd, vfile)
free (data);
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
pe_print_edata (abfd, vfile)
bfd *abfd;
PTR vfile;
@@ -1332,12 +1405,12 @@ pe_print_edata (abfd, vfile)
/* Maybe the extra header isn't there. Look for the section. */
section = bfd_get_section_by_name (abfd, ".edata");
if (section == NULL)
- return true;
+ return TRUE;
addr = section->vma;
datasize = bfd_section_size (abfd, section);
if (datasize == 0)
- return true;
+ return TRUE;
}
else
{
@@ -1355,7 +1428,7 @@ pe_print_edata (abfd, vfile)
{
fprintf (file,
_("\nThere is an export table, but the section containing it could not be found\n"));
- return true;
+ return TRUE;
}
}
@@ -1367,11 +1440,11 @@ pe_print_edata (abfd, vfile)
data = (bfd_byte *) bfd_malloc (datasize);
if (data == NULL)
- return false;
+ return FALSE;
if (! bfd_get_section_contents (abfd, section, (PTR) data,
(file_ptr) dataoff, datasize))
- return false;
+ return FALSE;
/* Go get Export Directory Table. */
edt.export_flags = bfd_get_32 (abfd, data + 0);
@@ -1508,7 +1581,7 @@ pe_print_edata (abfd, vfile)
free (data);
- return true;
+ return TRUE;
}
/* This really is architecture dependent. On IA-64, a .pdata entry
@@ -1516,7 +1589,7 @@ pe_print_edata (abfd, vfile)
specify the start and end address of the code range the entry
covers and the address of the corresponding unwind info data. */
-static boolean
+static bfd_boolean
pe_print_pdata (abfd, vfile)
bfd *abfd;
PTR vfile;
@@ -1537,7 +1610,7 @@ pe_print_pdata (abfd, vfile)
if (section == NULL
|| coff_section_data (abfd, section) == NULL
|| pei_section_data (abfd, section) == NULL)
- return true;
+ return TRUE;
stop = pei_section_data (abfd, section)->virt_size;
if ((stop % onaline) != 0)
@@ -1558,11 +1631,11 @@ pe_print_pdata (abfd, vfile)
datasize = bfd_section_size (abfd, section);
if (datasize == 0)
- return true;
+ return TRUE;
data = (bfd_byte *) bfd_malloc (datasize);
if (data == NULL && datasize != 0)
- return false;
+ return FALSE;
bfd_get_section_contents (abfd, section, (PTR) data, (bfd_vma) 0,
datasize);
@@ -1639,7 +1712,7 @@ pe_print_pdata (abfd, vfile)
free (data);
- return true;
+ return TRUE;
}
#define IMAGE_REL_BASED_HIGHADJ 4
@@ -1660,7 +1733,7 @@ static const char * const tbl[] =
"UNKNOWN", /* MUST be last */
};
-static boolean
+static bfd_boolean
pe_print_reloc (abfd, vfile)
bfd *abfd;
PTR vfile;
@@ -1673,10 +1746,10 @@ pe_print_reloc (abfd, vfile)
bfd_size_type start, stop;
if (section == NULL)
- return true;
+ return TRUE;
if (bfd_section_size (abfd, section) == 0)
- return true;
+ return TRUE;
fprintf (file,
_("\n\nPE File Base Relocations (interpreted .reloc section contents)\n"));
@@ -1684,7 +1757,7 @@ pe_print_reloc (abfd, vfile)
datasize = bfd_section_size (abfd, section);
data = (bfd_byte *) bfd_malloc (datasize);
if (data == NULL && datasize != 0)
- return false;
+ return FALSE;
bfd_get_section_contents (abfd, section, (PTR) data, (bfd_vma) 0,
datasize);
@@ -1743,12 +1816,12 @@ pe_print_reloc (abfd, vfile)
free (data);
- return true;
+ return TRUE;
}
/* Print out the program headers. */
-boolean
+bfd_boolean
_bfd_XX_print_private_bfd_data_common (abfd, vfile)
bfd *abfd;
PTR vfile;
@@ -1859,20 +1932,20 @@ _bfd_XX_print_private_bfd_data_common (abfd, vfile)
pe_print_pdata (abfd, vfile);
pe_print_reloc (abfd, vfile);
- return true;
+ return TRUE;
}
/* Copy any private info we understand from the input bfd
to the output bfd. */
-boolean
+bfd_boolean
_bfd_XX_bfd_copy_private_bfd_data_common (ibfd, obfd)
bfd *ibfd, *obfd;
{
/* One day we may try to grok other private data. */
if (ibfd->xvec->flavour != bfd_target_coff_flavour
|| obfd->xvec->flavour != bfd_target_coff_flavour)
- return true;
+ return TRUE;
pe_data (obfd)->pe_opthdr = pe_data (ibfd)->pe_opthdr;
pe_data (obfd)->dll = pe_data (ibfd)->dll;
@@ -1884,12 +1957,12 @@ _bfd_XX_bfd_copy_private_bfd_data_common (ibfd, obfd)
pe_data (obfd)->pe_opthdr.DataDirectory[5].VirtualAddress = 0;
pe_data (obfd)->pe_opthdr.DataDirectory[5].Size = 0;
}
- return true;
+ return TRUE;
}
/* Copy private section data. */
-boolean
+bfd_boolean
_bfd_XX_bfd_copy_private_section_data (ibfd, isec, obfd, osec)
bfd *ibfd;
asection *isec;
@@ -1898,7 +1971,7 @@ _bfd_XX_bfd_copy_private_section_data (ibfd, isec, obfd, osec)
{
if (bfd_get_flavour (ibfd) != bfd_target_coff_flavour
|| bfd_get_flavour (obfd) != bfd_target_coff_flavour)
- return true;
+ return TRUE;
if (coff_section_data (ibfd, isec) != NULL
&& pei_section_data (ibfd, isec) != NULL)
@@ -1908,7 +1981,7 @@ _bfd_XX_bfd_copy_private_section_data (ibfd, isec, obfd, osec)
bfd_size_type amt = sizeof (struct coff_section_tdata);
osec->used_by_bfd = (PTR) bfd_zalloc (obfd, amt);
if (osec->used_by_bfd == NULL)
- return false;
+ return FALSE;
}
if (pei_section_data (obfd, osec) == NULL)
@@ -1916,7 +1989,7 @@ _bfd_XX_bfd_copy_private_section_data (ibfd, isec, obfd, osec)
bfd_size_type amt = sizeof (struct pei_section_tdata);
coff_section_data (obfd, osec)->tdata = (PTR) bfd_zalloc (obfd, amt);
if (coff_section_data (obfd, osec)->tdata == NULL)
- return false;
+ return FALSE;
}
pei_section_data (obfd, osec)->virt_size =
@@ -1925,7 +1998,7 @@ _bfd_XX_bfd_copy_private_section_data (ibfd, isec, obfd, osec)
pei_section_data (ibfd, isec)->pe_flags;
}
- return true;
+ return TRUE;
}
void
@@ -1948,7 +2021,7 @@ _bfd_XX_get_symbol_info (abfd, symbol, ret)
/* Handle the .idata section and other things that need symbol table
access. */
-boolean
+bfd_boolean
_bfd_XXi_final_link_postscript (abfd, pfinfo)
bfd *abfd;
struct coff_final_link_info *pfinfo;
@@ -1965,7 +2038,7 @@ _bfd_XXi_final_link_postscript (abfd, pfinfo)
/* The import directory. This is the address of .idata$2, with size
of .idata$2 + .idata$3. */
h1 = coff_link_hash_lookup (coff_hash_table (info),
- ".idata$2", false, false, true);
+ ".idata$2", FALSE, FALSE, TRUE);
if (h1 != NULL)
{
pe_data (abfd)->pe_opthdr.DataDirectory[1].VirtualAddress =
@@ -1973,7 +2046,7 @@ _bfd_XXi_final_link_postscript (abfd, pfinfo)
+ h1->root.u.def.section->output_section->vma
+ h1->root.u.def.section->output_offset);
h1 = coff_link_hash_lookup (coff_hash_table (info),
- ".idata$4", false, false, true);
+ ".idata$4", FALSE, FALSE, TRUE);
pe_data (abfd)->pe_opthdr.DataDirectory[1].Size =
((h1->root.u.def.value
+ h1->root.u.def.section->output_section->vma
@@ -1983,22 +2056,34 @@ _bfd_XXi_final_link_postscript (abfd, pfinfo)
/* The import address table. This is the size/address of
.idata$5. */
h1 = coff_link_hash_lookup (coff_hash_table (info),
- ".idata$5", false, false, true);
+ ".idata$5", FALSE, FALSE, TRUE);
pe_data (abfd)->pe_opthdr.DataDirectory[12].VirtualAddress =
(h1->root.u.def.value
+ h1->root.u.def.section->output_section->vma
+ h1->root.u.def.section->output_offset);
h1 = coff_link_hash_lookup (coff_hash_table (info),
- ".idata$6", false, false, true);
+ ".idata$6", FALSE, FALSE, TRUE);
pe_data (abfd)->pe_opthdr.DataDirectory[12].Size =
((h1->root.u.def.value
+ h1->root.u.def.section->output_section->vma
+ h1->root.u.def.section->output_offset)
- - pe_data (abfd)->pe_opthdr.DataDirectory[12].VirtualAddress);
+ - pe_data (abfd)->pe_opthdr.DataDirectory[12].VirtualAddress);
+ }
+
+ h1 = coff_link_hash_lookup (coff_hash_table (info),
+ "__tls_used", FALSE, FALSE, TRUE);
+ if (h1 != NULL)
+ {
+ pe_data (abfd)->pe_opthdr.DataDirectory[9].VirtualAddress =
+ (h1->root.u.def.value
+ + h1->root.u.def.section->output_section->vma
+ + h1->root.u.def.section->output_offset
+ - pe_data (abfd)->pe_opthdr.ImageBase);
+ pe_data (abfd)->pe_opthdr.DataDirectory[9].Size = 0x18;
}
/* If we couldn't find idata$2, we either have an excessively
trivial program or are in DEEP trouble; we have to assume trivial
program.... */
- return true;
+ return TRUE;
}
diff --git a/contrib/binutils/bfd/peicode.h b/contrib/binutils/bfd/peicode.h
index a621acc..41445e5 100644
--- a/contrib/binutils/bfd/peicode.h
+++ b/contrib/binutils/bfd/peicode.h
@@ -1,31 +1,29 @@
/* Support for the generic parts of PE/PEI, for BFD.
- Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
+ Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Solutions.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-/*
-Most of this hacked by Steve Chamberlain,
+/* Most of this hacked by Steve Chamberlain,
sac@cygnus.com
-PE/PEI rearrangement (and code added): Donn Terry
- Softway Systems, Inc.
-*/
+ PE/PEI rearrangement (and code added): Donn Terry
+ Softway Systems, Inc. */
/* Hey look, some documentation [and in a place you expect to find it]!
@@ -53,12 +51,11 @@ PE/PEI rearrangement (and code added): Donn Terry
FIXME: Please add more docs here so the next poor fool that has to hack
on this code has a chance of getting something accomplished without
- wasting too much time.
-*/
+ wasting too much time. */
#include "libpei.h"
-static boolean (*pe_saved_coff_bfd_print_private_bfd_data)
+static bfd_boolean (*pe_saved_coff_bfd_print_private_bfd_data)
PARAMS ((bfd *, PTR)) =
#ifndef coff_bfd_print_private_bfd_data
NULL;
@@ -67,10 +64,10 @@ static boolean (*pe_saved_coff_bfd_print_private_bfd_data)
#undef coff_bfd_print_private_bfd_data
#endif
-static boolean pe_print_private_bfd_data PARAMS ((bfd *, PTR));
+static bfd_boolean pe_print_private_bfd_data PARAMS ((bfd *, PTR));
#define coff_bfd_print_private_bfd_data pe_print_private_bfd_data
-static boolean (*pe_saved_coff_bfd_copy_private_bfd_data)
+static bfd_boolean (*pe_saved_coff_bfd_copy_private_bfd_data)
PARAMS ((bfd *, bfd *)) =
#ifndef coff_bfd_copy_private_bfd_data
NULL;
@@ -79,7 +76,7 @@ static boolean (*pe_saved_coff_bfd_copy_private_bfd_data)
#undef coff_bfd_copy_private_bfd_data
#endif
-static boolean pe_bfd_copy_private_bfd_data PARAMS ((bfd *, bfd *));
+static bfd_boolean pe_bfd_copy_private_bfd_data PARAMS ((bfd *, bfd *));
#define coff_bfd_copy_private_bfd_data pe_bfd_copy_private_bfd_data
#define coff_mkobject pe_mkobject
@@ -91,7 +88,7 @@ static unsigned int coff_swap_reloc_out PARAMS ((bfd *, PTR, PTR));
#endif
static void coff_swap_filehdr_in PARAMS ((bfd *, PTR, PTR));
static void coff_swap_scnhdr_in PARAMS ((bfd *, PTR, PTR));
-static boolean pe_mkobject PARAMS ((bfd *));
+static bfd_boolean pe_mkobject PARAMS ((bfd *));
static PTR pe_mkobject_hook PARAMS ((bfd *, PTR, PTR));
#ifdef COFF_IMAGE_WITH_PE
@@ -138,8 +135,8 @@ static asection_ptr pe_ILF_make_a_section PARAMS ((pe_ILF_vars *, const
static void pe_ILF_make_a_reloc PARAMS ((pe_ILF_vars *, bfd_vma, bfd_reloc_code_real_type, asection_ptr));
static void pe_ILF_make_a_symbol PARAMS ((pe_ILF_vars *, const char *, const char *, asection_ptr, flagword));
static void pe_ILF_save_relocs PARAMS ((pe_ILF_vars *, asection_ptr));
-static void pe_ILF_make_a_symbol_reloc PARAMS ((pe_ILF_vars *, bfd_vma, bfd_reloc_code_real_type, struct symbol_cache_entry **, unsigned int));
-static boolean pe_ILF_build_a_bfd PARAMS ((bfd *, unsigned int, bfd_byte *, bfd_byte *, unsigned int, unsigned int));
+static void pe_ILF_make_a_symbol_reloc PARAMS ((pe_ILF_vars *, bfd_vma, bfd_reloc_code_real_type, struct bfd_symbol **, unsigned int));
+static bfd_boolean pe_ILF_build_a_bfd PARAMS ((bfd *, unsigned int, bfd_byte *, bfd_byte *, unsigned int, unsigned int));
static const bfd_target * pe_ILF_object_p PARAMS ((bfd *));
static const bfd_target * pe_bfd_object_p PARAMS ((bfd *));
#endif /* COFF_IMAGE_WITH_PE */
@@ -259,12 +256,17 @@ coff_swap_scnhdr_in (abfd, ext, in)
}
#ifndef COFF_NO_HACK_SCNHDR_SIZE
- /* If this section holds uninitialized data, use the virtual size
- (stored in s_paddr) instead of the physical size. */
- if ((scnhdr_int->s_flags & IMAGE_SCN_CNT_UNINITIALIZED_DATA) != 0
- && (scnhdr_int->s_paddr > 0))
+ /* If this section holds uninitialized data and is from an object file
+ or from an executable image that has not initialized the field,
+ or if the image is an executable file and the physical size is padded,
+ use the virtual size (stored in s_paddr) instead. */
+ if (scnhdr_int->s_paddr > 0
+ && (((scnhdr_int->s_flags & IMAGE_SCN_CNT_UNINITIALIZED_DATA) != 0
+ && (! bfd_pe_executable_p (abfd) || scnhdr_int->s_size == 0))
+ || (bfd_pe_executable_p (abfd) && scnhdr_int->s_size > scnhdr_int->s_paddr)))
{
scnhdr_int->s_size = scnhdr_int->s_paddr;
+
/* This code used to set scnhdr_int->s_paddr to 0. However,
coff_set_alignment_hook stores s_paddr in virt_size, which
only works if it correctly holds the virtual size of the
@@ -273,7 +275,7 @@ coff_swap_scnhdr_in (abfd, ext, in)
#endif
}
-static boolean
+static bfd_boolean
pe_mkobject (abfd)
bfd * abfd;
{
@@ -283,7 +285,7 @@ pe_mkobject (abfd)
abfd->tdata.pe_obj_data = (struct pe_tdata *) bfd_zalloc (abfd, amt);
if (abfd->tdata.pe_obj_data == 0)
- return false;
+ return FALSE;
pe = pe_data (abfd);
@@ -299,7 +301,7 @@ pe_mkobject (abfd)
pe->target_subsystem = PEI_TARGET_SUBSYSTEM;
#endif
- return true;
+ return TRUE;
}
/* Create the COFF backend specific information. */
@@ -355,7 +357,7 @@ pe_mkobject_hook (abfd, filehdr, aouthdr)
return (PTR) pe;
}
-static boolean
+static bfd_boolean
pe_print_private_bfd_data (abfd, vfile)
bfd *abfd;
PTR vfile;
@@ -363,7 +365,7 @@ pe_print_private_bfd_data (abfd, vfile)
FILE *file = (FILE *) vfile;
if (!_bfd_XX_print_private_bfd_data_common (abfd, vfile))
- return false;
+ return FALSE;
if (pe_saved_coff_bfd_print_private_bfd_data != NULL)
{
@@ -372,23 +374,23 @@ pe_print_private_bfd_data (abfd, vfile)
return pe_saved_coff_bfd_print_private_bfd_data (abfd, vfile);
}
- return true;
+ return TRUE;
}
/* Copy any private info we understand from the input bfd
to the output bfd. */
-static boolean
+static bfd_boolean
pe_bfd_copy_private_bfd_data (ibfd, obfd)
bfd *ibfd, *obfd;
{
if (!_bfd_XX_bfd_copy_private_bfd_data_common (ibfd, obfd))
- return false;
+ return FALSE;
if (pe_saved_coff_bfd_copy_private_bfd_data)
return pe_saved_coff_bfd_copy_private_bfd_data (ibfd, obfd);
- return true;
+ return TRUE;
}
#define coff_bfd_copy_private_section_data \
@@ -468,7 +470,7 @@ static void
pe_ILF_make_a_symbol_reloc (pe_ILF_vars * vars,
bfd_vma address,
bfd_reloc_code_real_type reloc,
- struct symbol_cache_entry ** sym,
+ struct bfd_symbol ** sym,
unsigned int sym_index)
{
arelent * entry;
@@ -518,7 +520,7 @@ pe_ILF_save_relocs (pe_ILF_vars * vars,
abort ();
coff_section_data (vars->abfd, sec)->relocs = vars->int_reltab;
- coff_section_data (vars->abfd, sec)->keep_relocs = true;
+ coff_section_data (vars->abfd, sec)->keep_relocs = TRUE;
sec->relocation = vars->reltab;
sec->reloc_count = vars->relcount;
@@ -610,7 +612,7 @@ pe_ILF_make_a_symbol (pe_ILF_vars * vars,
#if 0 /* See comment above. */
sym->symbol.value = 0;
sym->symbol.udata.i = 0;
- sym->done_lineno = false;
+ sym->done_lineno = FALSE;
sym->lineno = NULL;
#endif
@@ -753,7 +755,7 @@ static jump_table jtab[] =
#endif
/* Build a full BFD from the information supplied in a ILF object. */
-static boolean
+static bfd_boolean
pe_ILF_build_a_bfd (bfd * abfd,
unsigned int magic,
bfd_byte * symbol_name,
@@ -784,12 +786,12 @@ pe_ILF_build_a_bfd (bfd * abfd,
/* XXX code yet to be written. */
_bfd_error_handler (_("%s: Unhandled import type; %x"),
bfd_archive_filename (abfd), import_type);
- return false;
+ return FALSE;
default:
_bfd_error_handler (_("%s: Unrecognised import type; %x"),
bfd_archive_filename (abfd), import_type);
- return false;
+ return FALSE;
}
switch (import_name_type)
@@ -803,7 +805,7 @@ pe_ILF_build_a_bfd (bfd * abfd,
default:
_bfd_error_handler (_("%s: Unrecognised import name type; %x"),
bfd_archive_filename (abfd), import_name_type);
- return false;
+ return FALSE;
}
/* Initialise local variables.
@@ -815,7 +817,7 @@ pe_ILF_build_a_bfd (bfd * abfd,
so allocate all the space that we will need right now. */
ptr = bfd_zalloc (abfd, (bfd_size_type) ILF_DATA_SIZE);
if (ptr == NULL)
- return false;
+ return FALSE;
/* Create a bfd_in_memory structure. */
vars.bim = (struct bfd_in_memory *) ptr;
@@ -875,7 +877,7 @@ pe_ILF_build_a_bfd (bfd * abfd,
id4 = pe_ILF_make_a_section (& vars, ".idata$4", SIZEOF_IDATA4, 0);
id5 = pe_ILF_make_a_section (& vars, ".idata$5", SIZEOF_IDATA5, 0);
if (id4 == NULL || id5 == NULL)
- return false;
+ return FALSE;
/* Fill in the contents of these sections. */
if (import_name_type == IMPORT_ORDINAL)
@@ -894,16 +896,46 @@ pe_ILF_build_a_bfd (bfd * abfd,
/* Create .idata$6 - the Hint Name Table. */
id6 = pe_ILF_make_a_section (& vars, ".idata$6", SIZEOF_IDATA6, 0);
if (id6 == NULL)
- return false;
+ return FALSE;
/* If necessary, trim the import symbol name. */
symbol = symbol_name;
if (import_name_type != IMPORT_NAME)
- /* Skip any prefix in symbol_name. */
- while (*symbol == '@' || * symbol == '?' || * symbol == '_')
- ++ symbol;
-
+ {
+ bfd_boolean skipped_leading_underscore = FALSE;
+ bfd_boolean skipped_leading_at = FALSE;
+ bfd_boolean skipped_leading_question_mark = FALSE;
+ bfd_boolean check_again;
+
+ /* Skip any prefix in symbol_name. */
+ -- symbol;
+ do
+ {
+ check_again = FALSE;
+ ++ symbol;
+
+ switch (*symbol)
+ {
+ case '@':
+ if (! skipped_leading_at)
+ check_again = skipped_leading_at = TRUE;
+ break;
+ case '?':
+ if (! skipped_leading_question_mark)
+ check_again = skipped_leading_question_mark = TRUE;
+ break;
+ case '_':
+ if (! skipped_leading_underscore)
+ check_again = skipped_leading_underscore = TRUE;
+ break;
+ default:
+ break;
+ }
+ }
+ while (check_again);
+ }
+
if (import_name_type == IMPORT_NAME_UNDECORATE)
{
/* Truncate at the first '@' */
@@ -950,7 +982,7 @@ pe_ILF_build_a_bfd (bfd * abfd,
/* Create the .text section. */
text = pe_ILF_make_a_section (& vars, ".text", jtab[i].size, SEC_CODE);
if (text == NULL)
- return false;
+ return FALSE;
/* Copy in the jump code. */
memcpy (text->contents, jtab[i].data, jtab[i].size);
@@ -965,11 +997,11 @@ pe_ILF_build_a_bfd (bfd * abfd,
if (magic == MIPS_ARCH_MAGIC_WINCE)
{
pe_ILF_make_a_symbol_reloc (&vars, (bfd_vma) 0, BFD_RELOC_HI16_S,
- (struct symbol_cache_entry **) imp_sym,
+ (struct bfd_symbol **) imp_sym,
imp_index);
pe_ILF_make_a_reloc (&vars, (bfd_vma) 0, BFD_RELOC_LO16, text);
pe_ILF_make_a_symbol_reloc (&vars, (bfd_vma) 4, BFD_RELOC_LO16,
- (struct symbol_cache_entry **) imp_sym,
+ (struct bfd_symbol **) imp_sym,
imp_index);
}
else
@@ -999,10 +1031,10 @@ pe_ILF_build_a_bfd (bfd * abfd,
if ( ! bfd_set_start_address (abfd, (bfd_vma) 0)
|| ! bfd_coff_set_arch_mach_hook (abfd, & internal_f))
- return false;
+ return FALSE;
if (bfd_coff_mkobject_hook (abfd, (PTR) & internal_f, NULL) == NULL)
- return false;
+ return FALSE;
coff_data (abfd)->pe = 1;
#ifdef THUMBPEMAGIC
@@ -1053,17 +1085,17 @@ pe_ILF_build_a_bfd (bfd * abfd,
obj_raw_syment_count (abfd) = vars.sym_index;
obj_coff_external_syms (abfd) = (PTR) vars.esym_table;
- obj_coff_keep_syms (abfd) = true;
+ obj_coff_keep_syms (abfd) = TRUE;
obj_convert (abfd) = vars.sym_table;
obj_conv_table_size (abfd) = vars.sym_index;
obj_coff_strings (abfd) = vars.string_table;
- obj_coff_keep_strings (abfd) = true;
+ obj_coff_keep_strings (abfd) = TRUE;
abfd->flags |= HAS_SYMS;
- return true;
+ return TRUE;
}
/* We have detected a Image Library Format archive element.
diff --git a/contrib/binutils/bfd/po/BLD-POTFILES.in b/contrib/binutils/bfd/po/BLD-POTFILES.in
index 28f599d..2dbe723 100644
--- a/contrib/binutils/bfd/po/BLD-POTFILES.in
+++ b/contrib/binutils/bfd/po/BLD-POTFILES.in
@@ -1,3 +1,4 @@
+bfdver.h
elf32-ia64.c
elf32-target.h
elf64-ia64.c
diff --git a/contrib/binutils/bfd/po/Make-in b/contrib/binutils/bfd/po/Make-in
index a288585..1608b2d 100644
--- a/contrib/binutils/bfd/po/Make-in
+++ b/contrib/binutils/bfd/po/Make-in
@@ -24,6 +24,8 @@ gnulocaledir = $(prefix)/share/locale
gettextsrcdir = $(prefix)/share/gettext/po
subdir = po
+DESTDIR =
+
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
MKINSTALLDIRS = @MKINSTALLDIRS@
@@ -124,9 +126,9 @@ install-data: install-data-@USE_NLS@
install-data-no: all
install-data-yes: all
if test -r $(MKINSTALLDIRS); then \
- $(MKINSTALLDIRS) $(datadir); \
+ $(MKINSTALLDIRS) $(DESTDIR)$(datadir); \
else \
- $(top_srcdir)/mkinstalldirs $(datadir); \
+ $(top_srcdir)/mkinstalldirs $(DESTDIR)$(datadir); \
fi
@catalogs='$(CATALOGS)'; \
for cat in $$catalogs; do \
@@ -136,7 +138,7 @@ install-data-yes: all
*) destdir=$(localedir);; \
esac; \
lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
- dir=$$destdir/$$lang/LC_MESSAGES; \
+ dir=$(DESTDIR)$$destdir/$$lang/LC_MESSAGES; \
if test -r $(MKINSTALLDIRS); then \
$(MKINSTALLDIRS) $$dir; \
else \
@@ -166,12 +168,12 @@ install-data-yes: all
done
if test "$(PACKAGE)" = "gettext"; then \
if test -r $(MKINSTALLDIRS); then \
- $(MKINSTALLDIRS) $(gettextsrcdir); \
+ $(MKINSTALLDIRS) $(DESTDIR)$(gettextsrcdir); \
else \
- $(top_srcdir)/mkinstalldirs $(gettextsrcdir); \
+ $(top_srcdir)/mkinstalldirs $(DESTDIR)$(gettextsrcdir); \
fi; \
$(INSTALL_DATA) $(srcdir)/Makefile.in.in \
- $(gettextsrcdir)/Makefile.in.in; \
+ $(DESTDIR)$(gettextsrcdir)/Makefile.in.in; \
else \
: ; \
fi
@@ -184,12 +186,12 @@ uninstall:
for cat in $$catalogs; do \
cat=`basename $$cat`; \
lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
- rm -f $(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
- rm -f $(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
- rm -f $(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
- rm -f $(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
+ rm -f $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
+ rm -f $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
+ rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
+ rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
done
- rm -f $(gettextsrcdir)/po-Makefile.in.in
+ rm -f $(DESTDIR)$(gettextsrcdir)/po-Makefile.in.in
check: all
diff --git a/contrib/binutils/bfd/po/SRC-POTFILES.in b/contrib/binutils/bfd/po/SRC-POTFILES.in
index 9a977f5..d29593d 100644
--- a/contrib/binutils/bfd/po/SRC-POTFILES.in
+++ b/contrib/binutils/bfd/po/SRC-POTFILES.in
@@ -1,22 +1,24 @@
aix386-core.c
aix5ppc-core.c
+aout0.c
+aout32.c
+aout64.c
aout-adobe.c
aout-arm.c
aout-cris.c
+aoutf1.h
aout-ns32k.c
aout-sparcle.c
aout-target.h
aout-tic30.c
-aout0.c
-aout32.c
-aout64.c
-aoutf1.h
aoutx.h
-archive.c
archive64.c
+archive.c
archures.c
armnetbsd.c
bfd.c
+bfdio.c
+bfdwin.c
binary.c
bout.c
cache.c
@@ -24,17 +26,21 @@ cf-i386lynx.c
cf-m68klynx.c
cf-sparclynx.c
cisco-core.c
+coff64-rs6000.c
coff-a29k.c
coff-alpha.c
coff-apollo.c
coff-arm.c
coff-aux.c
+coffcode.h
+coffgen.c
coff-go32.c
coff-h8300.c
coff-h8500.c
coff-i386.c
coff-i860.c
coff-i960.c
+cofflink.c
coff-m68k.c
coff-m88k.c
coff-mips.c
@@ -44,18 +50,15 @@ coff-sh.c
coff-sparc.c
coff-stgo32.c
coff-svm68k.c
+coffswap.h
coff-tic30.c
+coff-tic4x.c
coff-tic54x.c
coff-tic80.c
coff-u68k.c
coff-w65.c
coff-we32k.c
coff-z8k.c
-coff64-rs6000.c
-coffcode.h
-coffgen.c
-cofflink.c
-coffswap.h
corefile.c
cpu-a29k.c
cpu-alpha.c
@@ -76,6 +79,8 @@ cpu-i386.c
cpu-i860.c
cpu-i960.c
cpu-ia64.c
+cpu-ip2k.c
+cpu-iq2000.c
cpu-m10200.c
cpu-m10300.c
cpu-m32r.c
@@ -86,6 +91,7 @@ cpu-m88k.c
cpu-mcore.c
cpu-mips.c
cpu-mmix.c
+cpu-msp430.c
cpu-ns32k.c
cpu-openrisc.c
cpu-or32.c
@@ -97,6 +103,7 @@ cpu-s390.c
cpu-sh.c
cpu-sparc.c
cpu-tic30.c
+cpu-tic4x.c
cpu-tic54x.c
cpu-tic80.c
cpu-v850.c
@@ -104,6 +111,7 @@ cpu-vax.c
cpu-w65.c
cpu-we32k.c
cpu-xstormy16.c
+cpu-xtensa.c
cpu-z8k.c
demo64.c
dwarf1.c
@@ -113,16 +121,11 @@ ecofflink.c
ecoffswap.h
efi-app-ia32.c
efi-app-ia64.c
-elf-bfd.h
-elf-eh-frame.c
-elf-hppa.h
-elf-m10200.c
-elf-m10300.c
-elf-strtab.c
-elf.c
+elf32-am33lin.c
elf32-arc.c
elf32-arm.h
elf32-avr.c
+elf32.c
elf32-cris.c
elf32-d10v.c
elf32-d30v.c
@@ -134,36 +137,35 @@ elf32-h8300.c
elf32-hppa.c
elf32-hppa.h
elf32-i370.c
-elf32-i386-fbsd.c
elf32-i386.c
-elf32-i386qnx.c
elf32-i860.c
elf32-i960.c
+elf32-ip2k.c
+elf32-iq2000.c
elf32-m32r.c
elf32-m68hc11.c
elf32-m68hc12.c
+elf32-m68hc1x.c
elf32-m68k.c
elf32-m88k.c
elf32-mcore.c
elf32-mips.c
+elf32-msp430.c
elf32-openrisc.c
elf32-or32.c
elf32-pj.c
elf32-ppc.c
elf32-s390.c
-elf32-sh-lin.c
-elf32-sh-nbsd.c
-elf32-sh.c
-elf32-sh64-com.c
-elf32-sh64-nbsd.c
elf32-sh64.c
+elf32-sh64-com.c
+elf32-sh.c
elf32-sparc.c
elf32-v850.c
elf32-vax.c
elf32-xstormy16.c
-elf32.c
-elf64-alpha-fbsd.c
+elf32-xtensa.c
elf64-alpha.c
+elf64.c
elf64-gen.c
elf64-hppa.c
elf64-hppa.h
@@ -171,17 +173,22 @@ elf64-mips.c
elf64-mmix.c
elf64-ppc.c
elf64-s390.c
-elf64-sh64-nbsd.c
elf64-sh64.c
elf64-sparc.c
elf64-x86-64.c
-elf64.c
elfarm-nabi.c
elfarm-oabi.c
+elf-bfd.h
+elf.c
elfcode.h
elfcore.h
+elf-eh-frame.c
+elf-hppa.h
elflink.c
-elflink.h
+elf-m10200.c
+elf-m10300.c
+elfn32-mips.c
+elf-strtab.c
elfxx-mips.c
epoc-pe-arm.c
epoc-pei-arm.c
@@ -225,21 +232,23 @@ m68klinux.c
m68klynx.c
m68knetbsd.c
m88kmach3.c
+mach-o.c
+mach-o.h
merge.c
mipsbsd.c
mmo.c
netbsd.h
newsos3.c
-nlm-target.h
-nlm.c
nlm32-alpha.c
+nlm32.c
nlm32-i386.c
nlm32-ppc.c
nlm32-sparc.c
-nlm32.c
nlm64.c
+nlm.c
nlmcode.h
nlmswap.h
+nlm-target.h
ns32k.h
ns32knetbsd.c
oasys.c
@@ -248,32 +257,36 @@ osf-core.c
pc532-mach.c
pdp11.c
pe-arm.c
+pef.c
+pef.h
+pef-traceback.h
pe-i386.c
-pe-mcore.c
-pe-mips.c
-pe-ppc.c
-pe-sh.c
pei-arm.c
+peicode.h
pei-i386.c
pei-mcore.c
pei-mips.c
pei-ppc.c
pei-sh.c
-peicode.h
+pe-mcore.c
+pe-mips.c
+pe-ppc.c
+pe-sh.c
ppcboot.c
-reloc.c
reloc16.c
+reloc.c
riscix.c
sco5-core.c
section.c
+simple.c
som.c
som.h
sparclinux.c
sparclynx.c
sparcnetbsd.c
srec.c
-stab-syms.c
stabs.c
+stab-syms.c
sunos.c
syms.c
targets.c
@@ -284,11 +297,15 @@ vaxbsd.c
vaxnetbsd.c
versados.c
version.h
+vms.c
vms-gsd.c
+vms.h
vms-hdr.c
vms-misc.c
vms-tir.c
-vms.c
-vms.h
-xcoff-target.h
xcofflink.c
+xcoff-target.h
+xsym.c
+xsym.h
+xtensa-isa.c
+xtensa-modules.c
diff --git a/contrib/binutils/bfd/po/bfd.pot b/contrib/binutils/bfd/po/bfd.pot
index 8823e66..5d4f234 100644
--- a/contrib/binutils/bfd/po/bfd.pot
+++ b/contrib/binutils/bfd/po/bfd.pot
@@ -1,13 +1,12 @@
# SOME DESCRIPTIVE TITLE.
-# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
-# This file is distributed under the same license as the PACKAGE package.
+# Copyright (C) YEAR Free Software Foundation, Inc.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
-"POT-Creation-Date: 2002-10-30 10:06-0500\n"
+"POT-Creation-Date: 2003-07-17 14:52+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -15,922 +14,867 @@ msgstr ""
"Content-Type: text/plain; charset=CHARSET\n"
"Content-Transfer-Encoding: 8bit\n"
-#: aout-adobe.c:197
+#: aout-adobe.c:204
#, c-format
msgid "%s: Unknown section type in a.out.adobe file: %x\n"
msgstr ""
-#: aout-cris.c:208
+#: aout-cris.c:207
#, c-format
msgid "%s: Invalid relocation type exported: %d"
msgstr ""
-#: aout-cris.c:252
+#: aout-cris.c:251
#, c-format
msgid "%s: Invalid relocation type imported: %d"
msgstr ""
-#: aout-cris.c:263
+#: aout-cris.c:262
#, c-format
msgid "%s: Bad relocation record imported: %d"
msgstr ""
-#: aoutx.h:1282 aoutx.h:1699
+#: aoutx.h:1295 aoutx.h:1716
#, c-format
msgid "%s: can not represent section `%s' in a.out object file format"
msgstr ""
-#: aoutx.h:1669
+#: aoutx.h:1682
#, c-format
msgid ""
"%s: can not represent section for symbol `%s' in a.out object file format"
msgstr ""
-#: aoutx.h:1671
+#: aoutx.h:1684
msgid "*unknown*"
msgstr ""
-#: aoutx.h:3732
+#: aoutx.h:3776
#, c-format
-msgid "%s: relocateable link from %s to %s not supported"
+msgid "%s: relocatable link from %s to %s not supported"
msgstr ""
-#: archive.c:1818
+#: archive.c:1751
msgid "Warning: writing archive was slow: rewriting timestamp\n"
msgstr ""
-#: archive.c:2085
+#: archive.c:2014
msgid "Reading archive file mod timestamp"
msgstr ""
-#. FIXME: bfd can't call perror.
-#: archive.c:2112
+#: archive.c:2040
msgid "Writing updated armap timestamp"
msgstr ""
-#: bfd.c:277
+#: bfd.c:280
msgid "No error"
msgstr ""
-#: bfd.c:278
+#: bfd.c:281
msgid "System call error"
msgstr ""
-#: bfd.c:279
+#: bfd.c:282
msgid "Invalid bfd target"
msgstr ""
-#: bfd.c:280
+#: bfd.c:283
msgid "File in wrong format"
msgstr ""
-#: bfd.c:281
+#: bfd.c:284
msgid "Archive object file in wrong format"
msgstr ""
-#: bfd.c:282
+#: bfd.c:285
msgid "Invalid operation"
msgstr ""
-#: bfd.c:283
+#: bfd.c:286
msgid "Memory exhausted"
msgstr ""
-#: bfd.c:284
+#: bfd.c:287
msgid "No symbols"
msgstr ""
-#: bfd.c:285
+#: bfd.c:288
msgid "Archive has no index; run ranlib to add one"
msgstr ""
-#: bfd.c:286
+#: bfd.c:289
msgid "No more archived files"
msgstr ""
-#: bfd.c:287
+#: bfd.c:290
msgid "Malformed archive"
msgstr ""
-#: bfd.c:288
+#: bfd.c:291
msgid "File format not recognized"
msgstr ""
-#: bfd.c:289
+#: bfd.c:292
msgid "File format is ambiguous"
msgstr ""
-#: bfd.c:290
+#: bfd.c:293
msgid "Section has no contents"
msgstr ""
-#: bfd.c:291
+#: bfd.c:294
msgid "Nonrepresentable section on output"
msgstr ""
-#: bfd.c:292
+#: bfd.c:295
msgid "Symbol needs debug section which does not exist"
msgstr ""
-#: bfd.c:293
+#: bfd.c:296
msgid "Bad value"
msgstr ""
-#: bfd.c:294
+#: bfd.c:297
msgid "File truncated"
msgstr ""
-#: bfd.c:295
+#: bfd.c:298
msgid "File too big"
msgstr ""
-#: bfd.c:296
+#: bfd.c:299
msgid "#<Invalid error code>"
msgstr ""
-#: bfd.c:703
+#: bfd.c:687
#, c-format
msgid "BFD %s assertion fail %s:%d"
msgstr ""
-#: bfd.c:722
+#: bfd.c:703
#, c-format
msgid "BFD %s internal error, aborting at %s line %d in %s\n"
msgstr ""
-#: bfd.c:726
+#: bfd.c:707
#, c-format
msgid "BFD %s internal error, aborting at %s line %d\n"
msgstr ""
-#: bfd.c:728
+#: bfd.c:709
msgid "Please report this bug.\n"
msgstr ""
+#: bfdwin.c:202
+#, c-format
+msgid "not mapping: data=%lx mapped=%d\n"
+msgstr ""
+
+#: bfdwin.c:205
+msgid "not mapping: env var not set\n"
+msgstr ""
+
#: binary.c:306
#, c-format
msgid "Warning: Writing section `%s' to huge (ie negative) file offset 0x%lx."
msgstr ""
-#: coff-a29k.c:119
+#: coff-rs6000.c:3616 coff64-rs6000.c:2109
+#, c-format
+msgid "%s: symbol `%s' has unrecognized smclas %d"
+msgstr ""
+
+#: coff-a29k.c:120
msgid "Missing IHCONST"
msgstr ""
-#: coff-a29k.c:180
+#: coff-a29k.c:181
msgid "Missing IHIHALF"
msgstr ""
-#: coff-a29k.c:212 coff-or32.c:229
+#: coff-a29k.c:213 coff-or32.c:236
msgid "Unrecognized reloc"
msgstr ""
-#: coff-a29k.c:408
+#: coff-a29k.c:409
msgid "missing IHCONST reloc"
msgstr ""
-#: coff-a29k.c:498
+#: coff-a29k.c:499
msgid "missing IHIHALF reloc"
msgstr ""
-#: coff-alpha.c:881 coff-alpha.c:918 coff-alpha.c:1989 coff-mips.c:1432
+#: coff-alpha.c:884 coff-alpha.c:921 coff-alpha.c:1992 coff-mips.c:1397
msgid "GP relative relocation used when GP not defined"
msgstr ""
-#: coff-alpha.c:1485
+#: coff-alpha.c:1488
msgid "using multiple gp values"
msgstr ""
-#: coff-arm.c:1066 elf32-arm.h:285
+#: coff-arm.c:1066 elf32-arm.h:294
#, c-format
msgid "%s: unable to find THUMB glue '%s' for `%s'"
msgstr ""
-#: coff-arm.c:1096 elf32-arm.h:320
+#: coff-arm.c:1096 elf32-arm.h:329
#, c-format
msgid "%s: unable to find ARM glue '%s' for `%s'"
msgstr ""
-#: coff-arm.c:1391 coff-arm.c:1486 elf32-arm.h:888 elf32-arm.h:992
+#: coff-arm.c:1394 coff-arm.c:1489 elf32-arm.h:892 elf32-arm.h:999
#, c-format
msgid "%s(%s): warning: interworking not enabled."
msgstr ""
-#: coff-arm.c:1395 elf32-arm.h:995
+#: coff-arm.c:1398 elf32-arm.h:1002
#, c-format
msgid " first occurrence: %s: arm call to thumb"
msgstr ""
-#: coff-arm.c:1490 elf32-arm.h:891
+#: coff-arm.c:1493 elf32-arm.h:895
#, c-format
msgid " first occurrence: %s: thumb call to arm"
msgstr ""
-#: coff-arm.c:1493
+#: coff-arm.c:1496
msgid " consider relinking with --support-old-code enabled"
msgstr ""
-#: coff-arm.c:1785 coff-tic80.c:686 cofflink.c:3034
+#: coff-arm.c:1788 coff-tic80.c:687 cofflink.c:3038
#, c-format
msgid "%s: bad reloc address 0x%lx in section `%s'"
msgstr ""
-#: coff-arm.c:2129
+#: coff-arm.c:2132
#, c-format
msgid "%s: illegal symbol index in reloc: %d"
msgstr ""
-#: coff-arm.c:2257
+#: coff-arm.c:2265
#, c-format
msgid "ERROR: %s is compiled for APCS-%d, whereas %s is compiled for APCS-%d"
msgstr ""
-#: coff-arm.c:2272 elf32-arm.h:2298
+#: coff-arm.c:2280 elf32-arm.h:2328
#, c-format
msgid ""
"ERROR: %s passes floats in float registers, whereas %s passes them in "
"integer registers"
msgstr ""
-#: coff-arm.c:2275 elf32-arm.h:2303
+#: coff-arm.c:2283 elf32-arm.h:2333
#, c-format
msgid ""
"ERROR: %s passes floats in integer registers, whereas %s passes them in "
"float registers"
msgstr ""
-#: coff-arm.c:2290
+#: coff-arm.c:2298
#, c-format
msgid ""
"ERROR: %s is compiled as position independent code, whereas target %s is "
"absolute position"
msgstr ""
-#: coff-arm.c:2293
+#: coff-arm.c:2301
#, c-format
msgid ""
"ERROR: %s is compiled as absolute position code, whereas target %s is "
"position independent"
msgstr ""
-#: coff-arm.c:2322 elf32-arm.h:2359
+#: coff-arm.c:2330 elf32-arm.h:2405
#, c-format
msgid "Warning: %s supports interworking, whereas %s does not"
msgstr ""
-#: coff-arm.c:2325 elf32-arm.h:2366
+#: coff-arm.c:2333 elf32-arm.h:2412
#, c-format
msgid "Warning: %s does not support interworking, whereas %s does"
msgstr ""
-#: coff-arm.c:2352
+#: coff-arm.c:2360
#, c-format
msgid "private flags = %x:"
msgstr ""
-#: coff-arm.c:2360 elf32-arm.h:2419
+#: coff-arm.c:2368 elf32-arm.h:2467
msgid " [floats passed in float registers]"
msgstr ""
-#: coff-arm.c:2362
+#: coff-arm.c:2370
msgid " [floats passed in integer registers]"
msgstr ""
-#: coff-arm.c:2365 elf32-arm.h:2422
+#: coff-arm.c:2373 elf32-arm.h:2470
msgid " [position independent]"
msgstr ""
-#: coff-arm.c:2367
+#: coff-arm.c:2375
msgid " [absolute position]"
msgstr ""
-#: coff-arm.c:2371
+#: coff-arm.c:2379
msgid " [interworking flag not initialised]"
msgstr ""
-#: coff-arm.c:2373
+#: coff-arm.c:2381
msgid " [interworking supported]"
msgstr ""
-#: coff-arm.c:2375
+#: coff-arm.c:2383
msgid " [interworking not supported]"
msgstr ""
-#: coff-arm.c:2423 elf32-arm.h:2125
+#: coff-arm.c:2431 elf32-arm.h:2150
#, c-format
msgid ""
"Warning: Not setting interworking flag of %s since it has already been "
"specified as non-interworking"
msgstr ""
-#: coff-arm.c:2427 elf32-arm.h:2129
+#: coff-arm.c:2435 elf32-arm.h:2154
#, c-format
msgid "Warning: Clearing the interworking flag of %s due to outside request"
msgstr ""
-#: coff-i960.c:136 coff-i960.c:485
-msgid "uncertain calling convention for non-COFF symbol"
+#: coffcode.h:1108
+#, c-format
+msgid "%s (%s): Section flag %s (0x%x) ignored"
msgstr ""
-#: coff-m68k.c:481 coff-mips.c:2429 elf32-m68k.c:2157 elf32-mips.c:1844
-msgid "unsupported reloc type"
+#: coffcode.h:2214
+#, c-format
+msgid "Unrecognized TI COFF target id '0x%x'"
msgstr ""
-#: coff-mips.c:874 elf32-mips.c:1062 elf64-mips.c:1609
-msgid "GP relative relocation when _gp not defined"
+#: coffcode.h:4439
+#, c-format
+msgid "%s: warning: illegal symbol index %ld in line numbers"
msgstr ""
-#. No other sections should appear in -membedded-pic
-#. code.
-#: coff-mips.c:2466
-msgid "reloc against unsupported section"
+#: coffcode.h:4453
+#, c-format
+msgid "%s: warning: duplicate line number information for `%s'"
msgstr ""
-#: coff-mips.c:2474
-msgid "reloc not properly aligned"
+#: coffcode.h:4807
+#, c-format
+msgid "%s: Unrecognized storage class %d for %s symbol `%s'"
msgstr ""
-#: coff-rs6000.c:2760
+#: coffcode.h:4940
#, c-format
-msgid "%s: unsupported relocation type 0x%02x"
+msgid "warning: %s: local symbol `%s' has no section"
msgstr ""
-#: coff-rs6000.c:2853
+#: coff-tic4x.c:218 coff-tic54x.c:373 coffcode.h:5047
#, c-format
-msgid "%s: TOC reloc at 0x%x to symbol `%s' with no TOC entry"
+msgid "%s: warning: illegal symbol index %ld in relocs"
msgstr ""
-#: coff-rs6000.c:3586 coff64-rs6000.c:2080
+#: coffcode.h:5085
#, c-format
-msgid "%s: symbol `%s' has unrecognized smclas %d"
+msgid "%s: illegal relocation type %d at address 0x%lx"
msgstr ""
-#: coff-tic54x.c:279 coff-tic80.c:449
+#: coffgen.c:1666
#, c-format
-msgid "Unrecognized reloc type 0x%x"
+msgid "%s: bad string table size %lu"
msgstr ""
-#: coff-tic54x.c:390 coffcode.h:4981
+#: coff-h8300.c:1047
#, c-format
-msgid "%s: warning: illegal symbol index %ld in relocs"
+msgid "cannot handle R_MEM_INDIRECT reloc when using %s output"
msgstr ""
-#: coff-w65.c:363
-#, c-format
-msgid "ignoring reloc %s\n"
+#: coff-i960.c:137 coff-i960.c:486
+msgid "uncertain calling convention for non-COFF symbol"
msgstr ""
-#: coffcode.h:1086
+#: cofflink.c:538 elflink.h:1276
#, c-format
-msgid "%s (%s): Section flag %s (0x%x) ignored"
+msgid "Warning: type of symbol `%s' changed from %d to %d in %s"
msgstr ""
-#: coffcode.h:2143
+#: cofflink.c:2328
#, c-format
-msgid "Unrecognized TI COFF target id '0x%x'"
+msgid "%s: relocs in section `%s', but it has no contents"
msgstr ""
-#: coffcode.h:4372
+#: cofflink.c:2671 coffswap.h:890
#, c-format
-msgid "%s: warning: illegal symbol index %ld in line numbers"
+msgid "%s: %s: reloc overflow: 0x%lx > 0xffff"
msgstr ""
-#: coffcode.h:4386
+#: cofflink.c:2680 coffswap.h:876
#, c-format
-msgid "%s: warning: duplicate line number information for `%s'"
+msgid "%s: warning: %s: line number overflow: 0x%lx > 0xffff"
msgstr ""
-#: coffcode.h:4743
-#, c-format
-msgid "%s: Unrecognized storage class %d for %s symbol `%s'"
+#: coff-m68k.c:482 coff-mips.c:2394 elf32-m68k.c:2193 elf32-mips.c:1783
+msgid "unsupported reloc type"
msgstr ""
-#: coffcode.h:4874
-#, c-format
-msgid "warning: %s: local symbol `%s' has no section"
+#: coff-mips.c:839 elf32-mips.c:1088 elf64-mips.c:1590 elfn32-mips.c:1554
+msgid "GP relative relocation when _gp not defined"
+msgstr ""
+
+#. No other sections should appear in -membedded-pic
+#. code.
+#: coff-mips.c:2431
+msgid "reloc against unsupported section"
msgstr ""
-#: coffcode.h:5019
+#: coff-mips.c:2439
+msgid "reloc not properly aligned"
+msgstr ""
+
+#: coff-rs6000.c:2790
#, c-format
-msgid "%s: illegal relocation type %d at address 0x%lx"
+msgid "%s: unsupported relocation type 0x%02x"
msgstr ""
-#: coffgen.c:1668
+#: coff-rs6000.c:2883
#, c-format
-msgid "%s: bad string table size %lu"
+msgid "%s: TOC reloc at 0x%x to symbol `%s' with no TOC entry"
msgstr ""
-#: cofflink.c:534 elflink.h:1930
+#: coff-tic4x.c:170 coff-tic54x.c:288 coff-tic80.c:450
#, c-format
-msgid "Warning: type of symbol `%s' changed from %d to %d in %s"
+msgid "Unrecognized reloc type 0x%x"
msgstr ""
-#: cofflink.c:2324
+#: coff-w65.c:364
#, c-format
-msgid "%s: relocs in section `%s', but it has no contents"
+msgid "ignoring reloc %s\n"
msgstr ""
-#: cofflink.c:2667 coffswap.h:877
+#: cpu-arm.c:196 cpu-arm.c:206
#, c-format
-msgid "%s: %s: reloc overflow: 0x%lx > 0xffff"
+msgid "ERROR: %s is compiled for the EP9312, whereas %s is compiled for XScale"
msgstr ""
-#: cofflink.c:2676 coffswap.h:864
+#: cpu-arm.c:344
#, c-format
-msgid "%s: warning: %s: line number overflow: 0x%lx > 0xffff"
+msgid "warning: unable to update contents of %s section in %s"
msgstr ""
-#: dwarf2.c:382
+#: dwarf2.c:380
msgid "Dwarf Error: Can't find .debug_str section."
msgstr ""
-#: dwarf2.c:399
+#: dwarf2.c:397
#, c-format
msgid ""
"Dwarf Error: DW_FORM_strp offset (%lu) greater than or equal to .debug_str "
"size (%lu)."
msgstr ""
-#: dwarf2.c:543
+#: dwarf2.c:541
msgid "Dwarf Error: Can't find .debug_abbrev section."
msgstr ""
-#: dwarf2.c:560
+#: dwarf2.c:556
#, c-format
msgid ""
"Dwarf Error: Abbrev offset (%lu) greater than or equal to .debug_abbrev size "
"(%lu)."
msgstr ""
-#: dwarf2.c:760
+#: dwarf2.c:756
#, c-format
msgid "Dwarf Error: Invalid or unhandled FORM value: %u."
msgstr ""
-#: dwarf2.c:924
+#: dwarf2.c:933
msgid "Dwarf Error: mangled line number section (bad file number)."
msgstr ""
-#: dwarf2.c:1016
+#: dwarf2.c:1032
msgid "Dwarf Error: Can't find .debug_line section."
msgstr ""
-#: dwarf2.c:1039
+#: dwarf2.c:1049
#, c-format
msgid ""
"Dwarf Error: Line offset (%lu) greater than or equal to .debug_line size (%"
"lu)."
msgstr ""
-#: dwarf2.c:1245
+#: dwarf2.c:1255
msgid "Dwarf Error: mangled line number section."
msgstr ""
-#: dwarf2.c:1454 dwarf2.c:1665
+#: dwarf2.c:1470 dwarf2.c:1620
#, c-format
msgid "Dwarf Error: Could not find abbrev number %u."
msgstr ""
-#: dwarf2.c:1626
+#: dwarf2.c:1581
#, c-format
msgid ""
"Dwarf Error: found dwarf version '%u', this reader only handles version 2 "
"information."
msgstr ""
-#: dwarf2.c:1633
+#: dwarf2.c:1588
#, c-format
msgid ""
"Dwarf Error: found address size '%u', this reader can not handle sizes "
"greater than '%u'."
msgstr ""
-#: dwarf2.c:1656
+#: dwarf2.c:1611
#, c-format
msgid "Dwarf Error: Bad abbrev number: %u."
msgstr ""
-#: ecoff.c:1320
+#: ecoff.c:1339
#, c-format
msgid "Unknown basic type %d"
msgstr ""
-#: ecoff.c:1580
+#: ecoff.c:1599
#, c-format
msgid ""
"\n"
" End+1 symbol: %ld"
msgstr ""
-#: ecoff.c:1587 ecoff.c:1590
+#: ecoff.c:1606 ecoff.c:1609
#, c-format
msgid ""
"\n"
" First symbol: %ld"
msgstr ""
-#: ecoff.c:1602
+#: ecoff.c:1621
#, c-format
msgid ""
"\n"
" End+1 symbol: %-7ld Type: %s"
msgstr ""
-#: ecoff.c:1609
+#: ecoff.c:1628
#, c-format
msgid ""
"\n"
" Local symbol: %ld"
msgstr ""
-#: ecoff.c:1617
+#: ecoff.c:1636
#, c-format
msgid ""
"\n"
" struct; End+1 symbol: %ld"
msgstr ""
-#: ecoff.c:1622
+#: ecoff.c:1641
#, c-format
msgid ""
"\n"
" union; End+1 symbol: %ld"
msgstr ""
-#: ecoff.c:1627
+#: ecoff.c:1646
#, c-format
msgid ""
"\n"
" enum; End+1 symbol: %ld"
msgstr ""
-#: ecoff.c:1633
+#: ecoff.c:1652
#, c-format
msgid ""
"\n"
" Type: %s"
msgstr ""
-#: elf-hppa.h:1476 elf-hppa.h:1509 elf32-ppc.c:3091 elf32-sh.c:4537
-#: elf64-sh64.c:1659
-#, c-format
-msgid ""
-"%s: warning: unresolvable relocation against symbol `%s' from %s section"
-msgstr ""
-
-#: elf-m10200.c:446 elf-m10300.c:656 elf32-arm.h:2085 elf32-avr.c:833
-#: elf32-cris.c:1403 elf32-d10v.c:481 elf32-fr30.c:635 elf32-frv.c:809
-#: elf32-h8300.c:548 elf32-i860.c:1031 elf32-m32r.c:1280 elf32-openrisc.c:439
-#: elf32-v850.c:1691 elf32-xstormy16.c:933 elf64-mmix.c:1302
-msgid "internal error: out of range error"
-msgstr ""
-
-#: elf-m10200.c:450 elf-m10300.c:660 elf32-arm.h:2089 elf32-avr.c:837
-#: elf32-cris.c:1407 elf32-d10v.c:485 elf32-fr30.c:639 elf32-frv.c:813
-#: elf32-h8300.c:552 elf32-i860.c:1035 elf32-m32r.c:1284 elf32-openrisc.c:443
-#: elf32-v850.c:1695 elf32-xstormy16.c:937 elf64-mmix.c:1306 elfxx-mips.c:5258
-msgid "internal error: unsupported relocation error"
-msgstr ""
-
-#: elf-m10200.c:454 elf-m10300.c:664 elf32-arm.h:2093 elf32-d10v.c:489
-#: elf32-h8300.c:556 elf32-m32r.c:1288
-msgid "internal error: dangerous error"
-msgstr ""
-
-#: elf-m10200.c:458 elf-m10300.c:668 elf32-arm.h:2097 elf32-avr.c:845
-#: elf32-cris.c:1415 elf32-d10v.c:493 elf32-fr30.c:647 elf32-frv.c:821
-#: elf32-h8300.c:560 elf32-i860.c:1043 elf32-m32r.c:1292 elf32-openrisc.c:451
-#: elf32-v850.c:1715 elf32-xstormy16.c:945 elf64-mmix.c:1314
-msgid "internal error: unknown error"
-msgstr ""
-
-#: elf.c:343
-#, c-format
-msgid "%s: invalid string offset %u >= %lu for section `%s'"
-msgstr ""
-
-#: elf.c:589
-#, c-format
-msgid "%s: invalid SHT_GROUP entry"
-msgstr ""
-
-#: elf.c:660
-#, c-format
-msgid "%s: no group info for section %s"
-msgstr ""
-
-#: elf.c:1023
-msgid ""
-"\n"
-"Program Header:\n"
-msgstr ""
-
-#: elf.c:1073
-msgid ""
-"\n"
-"Dynamic Section:\n"
-msgstr ""
-
-#: elf.c:1202
-msgid ""
-"\n"
-"Version definitions:\n"
-msgstr ""
-
-#: elf.c:1225
-msgid ""
-"\n"
-"Version References:\n"
-msgstr ""
-
-#: elf.c:1230
-#, c-format
-msgid " required from %s:\n"
-msgstr ""
-
-#: elf.c:1904
+#: elf32-arm.h:1228
#, c-format
-msgid "%s: invalid link %lu for reloc section %s (index %u)"
+msgid "%s: Warning: Arm BLX instruction targets Arm function '%s'."
msgstr ""
-#: elf.c:3619
+#: elf32-arm.h:1424
#, c-format
-msgid "%s: Not enough room for program headers (allocated %u, need %u)"
+msgid "%s: Warning: Thumb BLX instruction targets thumb function '%s'."
msgstr ""
-#: elf.c:3724
+#: elf32-arm.h:1918 elf32-sh.c:4706 elf64-sh64.c:1613
#, c-format
-msgid "%s: Not enough room for program headers, try linking with -N"
+msgid "%s(%s+0x%lx): %s relocation against SEC_MERGE section"
msgstr ""
-#: elf.c:3849
+#: elf32-arm.h:2012
#, c-format
msgid ""
-"Error: First section in segment (%s) starts at 0x%x whereas the segment "
-"starts at 0x%x"
-msgstr ""
-
-#: elf.c:4164
-#, c-format
-msgid "%s: warning: allocated section `%s' not in segment"
-msgstr ""
-
-#: elf.c:4488
-#, c-format
-msgid "%s: symbol `%s' required but not present"
-msgstr ""
-
-#: elf.c:4765
-#, c-format
-msgid "%s: warning: Empty loadable segment detected, is this intentional ?\n"
-msgstr ""
-
-#: elf.c:6213
-#, c-format
-msgid "%s: unsupported relocation type %s"
+"%s: warning: unresolvable relocation %d against symbol `%s' from %s section"
msgstr ""
-#: elf32-arm.h:1222
-#, c-format
-msgid "%s: Warning: Arm BLX instruction targets Arm function '%s'."
+#: elf-m10200.c:442 elf-m10300.c:1695 elf32-arm.h:2088 elf32-avr.c:812
+#: elf32-cris.c:1390 elf32-d10v.c:482 elf32-fr30.c:634 elf32-frv.c:815
+#: elf32-h8300.c:509 elf32-i860.c:1028 elf32-ip2k.c:1586 elf32-iq2000.c:699
+#: elf32-m32r.c:1283 elf32-m68hc1x.c:1305 elf32-msp430.c:510
+#: elf32-openrisc.c:436 elf32-v850.c:1777 elf32-xstormy16.c:976
+#: elf64-mmix.c:1332
+msgid "internal error: out of range error"
msgstr ""
-#: elf32-arm.h:1418
-#, c-format
-msgid "%s: Warning: Thumb BLX instruction targets thumb function '%s'."
+#: elf-m10200.c:446 elf-m10300.c:1699 elf32-arm.h:2092 elf32-avr.c:816
+#: elf32-cris.c:1394 elf32-d10v.c:486 elf32-fr30.c:638 elf32-frv.c:819
+#: elf32-h8300.c:513 elf32-i860.c:1032 elf32-iq2000.c:703 elf32-m32r.c:1287
+#: elf32-m68hc1x.c:1309 elf32-msp430.c:514 elf32-openrisc.c:440
+#: elf32-v850.c:1781 elf32-xstormy16.c:980 elf64-mmix.c:1336 elfxx-mips.c:6452
+msgid "internal error: unsupported relocation error"
msgstr ""
-#: elf32-arm.h:1915 elf32-sh.c:4444
-#, c-format
-msgid "%s(%s+0x%lx): %s relocation against SEC_MERGE section"
+#: elf-m10200.c:450 elf-m10300.c:1703 elf32-arm.h:2096 elf32-d10v.c:490
+#: elf32-h8300.c:517 elf32-m32r.c:1291 elf32-m68hc1x.c:1313
+msgid "internal error: dangerous error"
msgstr ""
-#: elf32-arm.h:2009
-#, c-format
-msgid ""
-"%s: warning: unresolvable relocation %d against symbol `%s' from %s section"
+#: elf-m10200.c:454 elf-m10300.c:1707 elf32-arm.h:2100 elf32-avr.c:824
+#: elf32-cris.c:1402 elf32-d10v.c:494 elf32-fr30.c:646 elf32-frv.c:827
+#: elf32-h8300.c:521 elf32-i860.c:1040 elf32-ip2k.c:1601 elf32-iq2000.c:711
+#: elf32-m32r.c:1295 elf32-m68hc1x.c:1317 elf32-msp430.c:522
+#: elf32-openrisc.c:448 elf32-v850.c:1801 elf32-xstormy16.c:988
+#: elf64-mmix.c:1344
+msgid "internal error: unknown error"
msgstr ""
-#: elf32-arm.h:2177
+#: elf32-arm.h:2202
#, c-format
msgid ""
"Warning: Clearing the interworking flag of %s because non-interworking code "
"in %s has been linked with it"
msgstr ""
-#: elf32-arm.h:2272
+#: elf32-arm.h:2302
#, c-format
msgid ""
"ERROR: %s is compiled for EABI version %d, whereas %s is compiled for "
"version %d"
msgstr ""
-#: elf32-arm.h:2286
+#: elf32-arm.h:2316
#, c-format
msgid "ERROR: %s is compiled for APCS-%d, whereas target %s uses APCS-%d"
msgstr ""
-#: elf32-arm.h:2314
+#: elf32-arm.h:2344
#, c-format
-msgid "ERROR: %s uses VFP instructions, whereas %s uses FPA instructions"
+msgid "ERROR: %s uses VFP instructions, whereas %s does not"
msgstr ""
-#: elf32-arm.h:2319
+#: elf32-arm.h:2349
#, c-format
-msgid "ERROR: %s uses FPA instructions, whereas %s uses VFP instructions"
+msgid "ERROR: %s uses FPA instructions, whereas %s does not"
msgstr ""
-#: elf32-arm.h:2339
+#: elf32-arm.h:2360 elf32-arm.h:2365
+#, c-format
+msgid "ERROR: %s uses Maverick instructions, whereas %s does not"
+msgstr ""
+
+#: elf32-arm.h:2385
#, c-format
msgid "ERROR: %s uses software FP, whereas %s uses hardware FP"
msgstr ""
-#: elf32-arm.h:2344
+#: elf32-arm.h:2390
#, c-format
msgid "ERROR: %s uses hardware FP, whereas %s uses software FP"
msgstr ""
#. Ignore init flag - it may not be set, despite the flags field
#. containing valid data.
-#: elf32-arm.h:2397 elf32-cris.c:2989 elf32-m68k.c:410 elf32-vax.c:548
-#: elfxx-mips.c:7760
+#: elf32-arm.h:2443 elf32-cris.c:2975 elf32-m68hc1x.c:1459 elf32-m68k.c:397
+#: elf32-vax.c:546 elfxx-mips.c:9240
#, c-format
msgid "private flags = %lx:"
msgstr ""
-#: elf32-arm.h:2406
+#: elf32-arm.h:2452
msgid " [interworking enabled]"
msgstr ""
-#: elf32-arm.h:2414
+#: elf32-arm.h:2460
msgid " [VFP float format]"
msgstr ""
-#: elf32-arm.h:2416
+#: elf32-arm.h:2462
+msgid " [Maverick float format]"
+msgstr ""
+
+#: elf32-arm.h:2464
msgid " [FPA float format]"
msgstr ""
-#: elf32-arm.h:2425
+#: elf32-arm.h:2473
msgid " [new ABI]"
msgstr ""
-#: elf32-arm.h:2428
+#: elf32-arm.h:2476
msgid " [old ABI]"
msgstr ""
-#: elf32-arm.h:2431
+#: elf32-arm.h:2479
msgid " [software FP]"
msgstr ""
-#: elf32-arm.h:2439
+#: elf32-arm.h:2488
msgid " [Version1 EABI]"
msgstr ""
-#: elf32-arm.h:2442 elf32-arm.h:2453
+#: elf32-arm.h:2491 elf32-arm.h:2502
msgid " [sorted symbol table]"
msgstr ""
-#: elf32-arm.h:2444 elf32-arm.h:2455
+#: elf32-arm.h:2493 elf32-arm.h:2504
msgid " [unsorted symbol table]"
msgstr ""
-#: elf32-arm.h:2450
+#: elf32-arm.h:2499
msgid " [Version2 EABI]"
msgstr ""
-#: elf32-arm.h:2458
+#: elf32-arm.h:2507
msgid " [dynamic symbols use segment index]"
msgstr ""
-#: elf32-arm.h:2461
+#: elf32-arm.h:2510
msgid " [mapping symbols precede others]"
msgstr ""
-#: elf32-arm.h:2468
+#: elf32-arm.h:2517
msgid " <EABI version unrecognised>"
msgstr ""
-#: elf32-arm.h:2475
+#: elf32-arm.h:2524
msgid " [relocatable executable]"
msgstr ""
-#: elf32-arm.h:2478
+#: elf32-arm.h:2527
msgid " [has entry point]"
msgstr ""
-#: elf32-arm.h:2483
+#: elf32-arm.h:2532
msgid "<Unrecognised flag bits set>"
msgstr ""
-#: elf32-avr.c:841 elf32-cris.c:1411 elf32-fr30.c:643 elf32-frv.c:817
-#: elf32-i860.c:1039 elf32-openrisc.c:447 elf32-v850.c:1699
-#: elf32-xstormy16.c:941 elf64-mmix.c:1310
+#: elf32-avr.c:820 elf32-cris.c:1398 elf32-fr30.c:642 elf32-frv.c:823
+#: elf32-i860.c:1036 elf32-ip2k.c:1597 elf32-iq2000.c:707 elf32-msp430.c:518
+#: elf32-openrisc.c:444 elf32-v850.c:1785 elf32-xstormy16.c:984
+#: elf64-mmix.c:1340
msgid "internal error: dangerous relocation"
msgstr ""
-#: elf32-cris.c:949
+#: elf32-cris.c:931
#, c-format
msgid "%s: unresolvable relocation %s against symbol `%s' from %s section"
msgstr ""
-#: elf32-cris.c:1012
+#: elf32-cris.c:993
#, c-format
msgid ""
"%s: No PLT nor GOT for relocation %s against symbol `%s' from %s section"
msgstr ""
-#: elf32-cris.c:1015 elf32-cris.c:1141
+#: elf32-cris.c:996 elf32-cris.c:1122
msgid "[whose name is lost]"
msgstr ""
-#: elf32-cris.c:1130
+#: elf32-cris.c:1111
#, c-format
msgid ""
"%s: relocation %s with non-zero addend %d against local symbol from %s "
"section"
msgstr ""
-#: elf32-cris.c:1137
+#: elf32-cris.c:1118
#, c-format
msgid ""
"%s: relocation %s with non-zero addend %d against symbol `%s' from %s section"
msgstr ""
-#: elf32-cris.c:1155
+#: elf32-cris.c:1143
#, c-format
msgid ""
"%s: relocation %s is not allowed for global symbol: `%s' from %s section"
msgstr ""
-#: elf32-cris.c:1170
+#: elf32-cris.c:1158
#, c-format
msgid "%s: relocation %s in section %s with no GOT created"
msgstr ""
-#: elf32-cris.c:1288
+#: elf32-cris.c:1277
#, c-format
msgid "%s: Internal inconsistency; no relocation section %s"
msgstr ""
-#: elf32-cris.c:2514
+#: elf32-cris.c:2500
#, c-format
msgid ""
"%s, section %s:\n"
" relocation %s should not be used in a shared object; recompile with -fPIC"
msgstr ""
-#: elf32-cris.c:2992
+#: elf32-cris.c:2978
msgid " [symbols have a _ prefix]"
msgstr ""
-#: elf32-cris.c:3031
+#: elf32-cris.c:3017
#, c-format
msgid "%s: uses _-prefixed symbols, but writing file with non-prefixed symbols"
msgstr ""
-#: elf32-cris.c:3032
+#: elf32-cris.c:3018
#, c-format
msgid "%s: uses non-prefixed symbols, but writing file with _-prefixed symbols"
msgstr ""
-#: elf32-frv.c:1217
+#: elf32-frv.c:1223
#, c-format
msgid ""
"%s: compiled with %s and linked with modules that use non-pic relocations"
msgstr ""
-#: elf32-frv.c:1267
+#: elf32-frv.c:1273 elf32-iq2000.c:895
#, c-format
msgid "%s: compiled with %s and linked with modules compiled with %s"
msgstr ""
-#: elf32-frv.c:1279
+#: elf32-frv.c:1285
#, c-format
msgid ""
"%s: uses different unknown e_flags (0x%lx) fields than previous modules (0x%"
"lx)"
msgstr ""
-#: elf32-frv.c:1315
+#: elf32-frv.c:1321 elf32-iq2000.c:933
#, c-format
msgid "private flags = 0x%lx:"
msgstr ""
-#: elf32-gen.c:82 elf64-gen.c:82
+#: elf32-gen.c:83 elf64-gen.c:82
#, c-format
msgid "%s: Relocations in generic ELF (EM: %d)"
msgstr ""
-#: elf32-hppa.c:672 elf64-ppc.c:2324
+#: elf32-hppa.c:672 elf32-m68hc1x.c:176 elf64-ppc.c:3118
#, c-format
msgid "%s: cannot create stub entry %s"
msgstr ""
-#: elf32-hppa.c:957 elf32-hppa.c:3557
+#: elf32-hppa.c:957 elf32-hppa.c:3538
#, c-format
msgid "%s(%s+0x%lx): cannot reach %s, recompile with -ffunction-sections"
msgstr ""
-#: elf32-hppa.c:1340 elf64-x86-64.c:675
+#: elf32-hppa.c:1340 elf64-x86-64.c:672 elf64-x86-64.c:797
#, c-format
msgid ""
"%s: relocation %s can not be used when making a shared object; recompile "
@@ -949,437 +893,601 @@ msgstr ""
msgid "Could not find relocation section for %s"
msgstr ""
-#: elf32-hppa.c:2857
+#: elf32-hppa.c:2828
#, c-format
msgid "%s: duplicate export stub %s"
msgstr ""
-#: elf32-hppa.c:3435
+#: elf32-hppa.c:3416
#, c-format
msgid "%s(%s+0x%lx): fixing %s"
msgstr ""
-#: elf32-hppa.c:4082
+#: elf32-hppa.c:4039
#, c-format
msgid "%s(%s+0x%lx): cannot handle %s for %s"
msgstr ""
-#: elf32-hppa.c:4395
+#: elf32-hppa.c:4357
msgid ".got section not immediately after .plt section"
msgstr ""
-#: elf32-i386.c:401
+#: elf32-i386.c:326
#, c-format
msgid "%s: invalid relocation type %d"
msgstr ""
-#: elf32-i386.c:916 elf32-s390.c:651 elf64-s390.c:597 elf64-x86-64.c:593
+#: elf32-i386.c:841 elf32-s390.c:990 elf32-sparc.c:887 elf32-xtensa.c:637
+#: elf64-s390.c:943 elf64-x86-64.c:650
#, c-format
msgid "%s: bad symbol index: %d"
msgstr ""
-#: elf32-i386.c:1025
+#: elf32-i386.c:949 elf32-s390.c:1168 elf32-sh.c:6426 elf32-sparc.c:1011
+#: elf64-s390.c:1129
#, c-format
msgid "%s: `%s' accessed both as normal and thread local symbol"
msgstr ""
-#: elf32-i386.c:1137 elf32-s390.c:810 elf64-ppc.c:2829 elf64-s390.c:761
-#: elf64-x86-64.c:763
+#: elf32-i386.c:1064 elf32-s390.c:1279 elf64-ppc.c:3929 elf64-s390.c:1243
+#: elf64-x86-64.c:886
#, c-format
msgid "%s: bad relocation section name `%s'"
msgstr ""
-#: elf32-i386.c:2990 elf32-s390.c:1983 elf32-sparc.c:1572 elf64-ppc.c:5941
-#: elf64-s390.c:1947 elf64-sparc.c:2578 elf64-x86-64.c:1950
+#: elf32-i386.c:2908 elf32-m68k.c:1757 elf32-s390.c:3022 elf32-sparc.c:2879
+#: elf32-xtensa.c:2193 elf64-s390.c:3018 elf64-sparc.c:2664
+#: elf64-x86-64.c:2452
#, c-format
msgid "%s(%s+0x%lx): unresolvable relocation against symbol `%s'"
msgstr ""
-#: elf32-i386.c:3029 elf32-s390.c:2021 elf64-ppc.c:6000 elf64-s390.c:1985
-#: elf64-x86-64.c:1988
+#: elf32-i386.c:2947 elf32-m68k.c:1796 elf32-s390.c:3072 elf64-s390.c:3068
+#: elf64-x86-64.c:2490
#, c-format
msgid "%s(%s+0x%lx): reloc against `%s': error %d"
msgstr ""
-#: elf32-m32r.c:926
+#: elf32-ip2k.c:565 elf32-ip2k.c:571 elf32-ip2k.c:734 elf32-ip2k.c:740
+msgid ""
+"ip2k relaxer: switch table without complete matching relocation information."
+msgstr ""
+
+#: elf32-ip2k.c:588 elf32-ip2k.c:767
+msgid "ip2k relaxer: switch table header corrupt."
+msgstr ""
+
+#: elf32-ip2k.c:1395
+#, c-format
+msgid "ip2k linker: missing page instruction at 0x%08lx (dest = 0x%08lx)."
+msgstr ""
+
+#: elf32-ip2k.c:1409
+#, c-format
+msgid "ip2k linker: redundant page instruction at 0x%08lx (dest = 0x%08lx)."
+msgstr ""
+
+#. Only if it's not an unresolved symbol.
+#: elf32-ip2k.c:1593
+msgid "unsupported relocation between data/insn address spaces"
+msgstr ""
+
+#: elf32-iq2000.c:907 elf32-m68hc1x.c:1431 elf32-ppc.c:2175 elf64-sparc.c:3072
+#: elfxx-mips.c:9197
+#, c-format
+msgid "%s: uses different e_flags (0x%lx) fields than previous modules (0x%lx)"
+msgstr ""
+
+#: elf32-m32r.c:930
msgid "SDA relocation when _SDA_BASE_ not defined"
msgstr ""
-#: elf32-m32r.c:1015 elf32-ppc.c:2987 elf64-alpha.c:4186 elf64-alpha.c:4314
-#: elf32-ia64.c:3693 elf64-ia64.c:3693
+#: elf32-ia64.c:3817 elf32-m32r.c:1018 elf64-alpha.c:4279 elf64-alpha.c:4407
+#: elf64-ia64.c:3817
#, c-format
msgid "%s: unknown relocation type %d"
msgstr ""
-#: elf32-m32r.c:1223
+#: elf32-m32r.c:1226
#, c-format
msgid "%s: The target (%s) of an %s relocation is in the wrong section (%s)"
msgstr ""
-#: elf32-m32r.c:1949
+#: elf32-m32r.c:1952
#, c-format
msgid "%s: Instruction set mismatch with previous modules"
msgstr ""
-#: elf32-m32r.c:1972
+#: elf32-m32r.c:1975
#, c-format
msgid "private flags = %lx"
msgstr ""
-#: elf32-m32r.c:1977
+#: elf32-m32r.c:1980
msgid ": m32r instructions"
msgstr ""
-#: elf32-m32r.c:1978
+#: elf32-m32r.c:1981
msgid ": m32rx instructions"
msgstr ""
-#: elf32-m68k.c:413
+#: elf32-m68hc1x.c:1217
+#, c-format
+msgid ""
+"Reference to the far symbol `%s' using a wrong relocation may result in "
+"incorrect execution"
+msgstr ""
+
+#: elf32-m68hc1x.c:1240
+#, c-format
+msgid ""
+"banked address [%lx:%04lx] (%lx) is not in the same bank as current banked "
+"address [%lx:%04lx] (%lx)"
+msgstr ""
+
+#: elf32-m68hc1x.c:1259
+#, c-format
+msgid ""
+"reference to a banked address [%lx:%04lx] in the normal address space at %"
+"04lx"
+msgstr ""
+
+#: elf32-m68hc1x.c:1396
+#, c-format
+msgid ""
+"%s: linking files compiled for 16-bit integers (-mshort) and others for 32-"
+"bit integers"
+msgstr ""
+
+#: elf32-m68hc1x.c:1404
+#, c-format
+msgid ""
+"%s: linking files compiled for 32-bit double (-fshort-double) and others for "
+"64-bit double"
+msgstr ""
+
+#: elf32-m68hc1x.c:1414
+#, c-format
+msgid "%s: linking files compiled for HCS12 with others compiled for HC12"
+msgstr ""
+
+#: elf32-m68hc1x.c:1462
+msgid "[abi=32-bit int, "
+msgstr ""
+
+#: elf32-m68hc1x.c:1464
+msgid "[abi=16-bit int, "
+msgstr ""
+
+#: elf32-m68hc1x.c:1467
+msgid "64-bit double, "
+msgstr ""
+
+#: elf32-m68hc1x.c:1469
+msgid "32-bit double, "
+msgstr ""
+
+#: elf32-m68hc1x.c:1472
+msgid "cpu=HC11]"
+msgstr ""
+
+#: elf32-m68hc1x.c:1474
+msgid "cpu=HCS12]"
+msgstr ""
+
+#: elf32-m68hc1x.c:1476
+msgid "cpu=HC12]"
+msgstr ""
+
+#: elf32-m68hc1x.c:1479
+msgid " [memory=bank-model]"
+msgstr ""
+
+#: elf32-m68hc1x.c:1481
+msgid " [memory=flat]"
+msgstr ""
+
+#: elf32-m68k.c:400
msgid " [cpu32]"
msgstr ""
-#: elf32-m68k.c:416
+#: elf32-m68k.c:403
msgid " [m68000]"
msgstr ""
-#: elf32-mcore.c:354 elf32-mcore.c:457
+#: elf32-mcore.c:353 elf32-mcore.c:456
#, c-format
msgid "%s: Relocation %s (%d) is not currently supported.\n"
msgstr ""
-#: elf32-mcore.c:442
+#: elf32-mcore.c:441
#, c-format
msgid "%s: Unknown relocation type %d\n"
msgstr ""
-#: elf32-mips.c:1152 elf64-mips.c:1783
+#: elf32-mips.c:1170 elf64-mips.c:1717 elfn32-mips.c:1664
msgid "32bits gp relative relocation occurs for an external symbol"
msgstr ""
-#: elf32-mips.c:1301
+#: elf32-mips.c:1314 elf64-mips.c:1830 elfn32-mips.c:1783
#, c-format
msgid "Linking mips16 objects into %s format is not supported"
msgstr ""
-#: elf32-ppc.c:1460
+#: elf32-ppc.c:2056
+#, c-format
+msgid "generic linker can't handle %s"
+msgstr ""
+
+#: elf32-ppc.c:2138
#, c-format
msgid ""
"%s: compiled with -mrelocatable and linked with modules compiled normally"
msgstr ""
-#: elf32-ppc.c:1468
+#: elf32-ppc.c:2147
#, c-format
msgid ""
"%s: compiled normally and linked with modules compiled with -mrelocatable"
msgstr ""
-#: elf32-ppc.c:1494 elf64-sparc.c:2990 elfxx-mips.c:7717
+#: elf32-ppc.c:3413
#, c-format
-msgid "%s: uses different e_flags (0x%lx) fields than previous modules (0x%lx)"
+msgid "%s: relocation %s cannot be used when making a shared object"
msgstr ""
-#: elf32-ppc.c:1592
+#. It does not make sense to have a procedure linkage
+#. table entry for a local symbol.
+#: elf32-ppc.c:3619
#, c-format
-msgid "%s: Unknown special linker type %d"
+msgid "%s(%s+0x%lx): %s reloc against local symbol"
msgstr ""
-#: elf32-ppc.c:2273 elf32-ppc.c:2307 elf32-ppc.c:2342
+#: elf32-ppc.c:4862 elf64-ppc.c:7789
#, c-format
-msgid "%s: relocation %s cannot be used when making a shared object"
+msgid "%s: unknown relocation type %d for symbol %s"
msgstr ""
-#: elf32-ppc.c:3126 elf64-ppc.c:5496
+#: elf32-ppc.c:5113
#, c-format
-msgid "%s: unknown relocation type %d for symbol %s"
+msgid "%s(%s+0x%lx): non-zero addend on %s reloc against `%s'"
msgstr ""
-#: elf32-ppc.c:3489 elf32-ppc.c:3510 elf32-ppc.c:3560
+#: elf32-ppc.c:5399 elf32-ppc.c:5425 elf32-ppc.c:5484
#, c-format
msgid ""
-"%s: The target (%s) of a %s relocation is in the wrong output section (%s)"
+"%s: the target (%s) of a %s relocation is in the wrong output section (%s)"
msgstr ""
-#: elf32-ppc.c:3626
+#: elf32-ppc.c:5539
#, c-format
-msgid "%s: Relocation %s is not yet supported for symbol %s."
+msgid "%s: relocation %s is not yet supported for symbol %s."
msgstr ""
-#: elf32-sh.c:1973
+#: elf32-ppc.c:5594 elf64-ppc.c:8461
#, c-format
-msgid "%s: 0x%lx: warning: bad R_SH_USES offset"
+msgid "%s(%s+0x%lx): unresolvable %s relocation against symbol `%s'"
msgstr ""
-#: elf32-sh.c:1985
+#: elf32-ppc.c:5644 elf64-ppc.c:8507
#, c-format
-msgid "%s: 0x%lx: warning: R_SH_USES points to unrecognized insn 0x%x"
+msgid "%s(%s+0x%lx): %s reloc against `%s': error %d"
msgstr ""
-#: elf32-sh.c:2002
+#: elf32-ppc.c:5888
#, c-format
-msgid "%s: 0x%lx: warning: bad R_SH_USES load offset"
+msgid "corrupt or empty %s section in %s"
msgstr ""
-#: elf32-sh.c:2017
+#: elf32-ppc.c:5895
#, c-format
-msgid "%s: 0x%lx: warning: could not find expected reloc"
+msgid "unable to read in %s section from %s"
msgstr ""
-#: elf32-sh.c:2045
+#: elf32-ppc.c:5901
#, c-format
-msgid "%s: 0x%lx: warning: symbol in unexpected section"
+msgid "corrupt %s section in %s"
msgstr ""
-#: elf32-sh.c:2162
+#: elf32-ppc.c:5944
#, c-format
-msgid "%s: 0x%lx: warning: could not find expected COUNT reloc"
+msgid "warning: unable to set size of %s section in %s"
msgstr ""
-#: elf32-sh.c:2171
-#, c-format
-msgid "%s: 0x%lx: warning: bad count"
+#: elf32-ppc.c:5994
+msgid "failed to allocate space for new APUinfo section."
msgstr ""
-#: elf32-sh.c:2559 elf32-sh.c:2935
-#, c-format
-msgid "%s: 0x%lx: fatal: reloc overflow while relaxing"
+#: elf32-ppc.c:6013
+msgid "failed to compute new APUinfo section."
msgstr ""
-#: elf32-sh.c:4392 elf64-sh64.c:1576
-msgid "Unexpected STO_SH5_ISA32 on local symbol is not handled"
+#: elf32-ppc.c:6016
+msgid "failed to install new APUinfo section."
msgstr ""
-#: elf32-sh.c:4611
+#: elf32-s390.c:2256 elf64-s390.c:2226
#, c-format
-msgid "%s: 0x%lx: fatal: unaligned branch target for relax-support relocation"
+msgid "%s(%s+0x%lx): invalid instruction for TLS relocation %s"
msgstr ""
-#: elf32-sh64.c:203 elf64-sh64.c:2364
+#: elf32-sh64.c:221 elf64-sh64.c:2407
#, c-format
msgid "%s: compiled as 32-bit object and %s is 64-bit"
msgstr ""
-#: elf32-sh64.c:206 elf64-sh64.c:2367
+#: elf32-sh64.c:224 elf64-sh64.c:2410
#, c-format
msgid "%s: compiled as 64-bit object and %s is 32-bit"
msgstr ""
-#: elf32-sh64.c:208 elf64-sh64.c:2369
+#: elf32-sh64.c:226 elf64-sh64.c:2412
#, c-format
msgid "%s: object size does not match that of target %s"
msgstr ""
-#: elf32-sh64.c:443 elf64-sh64.c:2944
+#: elf32-sh64.c:461 elf64-sh64.c:2990
#, c-format
msgid "%s: encountered datalabel symbol in input"
msgstr ""
-#: elf32-sh64.c:526
+#: elf32-sh64.c:544
msgid "PTB mismatch: a SHmedia address (bit 0 == 1)"
msgstr ""
-#: elf32-sh64.c:529
+#: elf32-sh64.c:547
msgid "PTA mismatch: a SHcompact address (bit 0 == 0)"
msgstr ""
-#: elf32-sh64.c:547
+#: elf32-sh64.c:565
#, c-format
msgid "%s: GAS error: unexpected PTB insn with R_SH_PT_16"
msgstr ""
-#: elf32-sh64.c:596 elf64-sh64.c:1703
+#: elf32-sh64.c:614 elf64-sh64.c:1748
#, c-format
msgid "%s: error: unaligned relocation type %d at %08x reloc %08x\n"
msgstr ""
-#: elf32-sh64.c:680
+#: elf32-sh64.c:698
#, c-format
msgid "%s: could not write out added .cranges entries"
msgstr ""
-#: elf32-sh64.c:742
+#: elf32-sh64.c:760
#, c-format
msgid "%s: could not write out sorted .cranges entries"
msgstr ""
-#: elf32-sparc.c:1536 elf64-sparc.c:2224
+#: elf32-sh.c:2103
+#, c-format
+msgid "%s: 0x%lx: warning: bad R_SH_USES offset"
+msgstr ""
+
+#: elf32-sh.c:2115
+#, c-format
+msgid "%s: 0x%lx: warning: R_SH_USES points to unrecognized insn 0x%x"
+msgstr ""
+
+#: elf32-sh.c:2132
+#, c-format
+msgid "%s: 0x%lx: warning: bad R_SH_USES load offset"
+msgstr ""
+
+#: elf32-sh.c:2147
+#, c-format
+msgid "%s: 0x%lx: warning: could not find expected reloc"
+msgstr ""
+
+#: elf32-sh.c:2175
+#, c-format
+msgid "%s: 0x%lx: warning: symbol in unexpected section"
+msgstr ""
+
+#: elf32-sh.c:2300
+#, c-format
+msgid "%s: 0x%lx: warning: could not find expected COUNT reloc"
+msgstr ""
+
+#: elf32-sh.c:2309
+#, c-format
+msgid "%s: 0x%lx: warning: bad count"
+msgstr ""
+
+#: elf32-sh.c:2712 elf32-sh.c:3088
+#, c-format
+msgid "%s: 0x%lx: fatal: reloc overflow while relaxing"
+msgstr ""
+
+#: elf32-sh.c:4654 elf64-sh64.c:1585
+msgid "Unexpected STO_SH5_ISA32 on local symbol is not handled"
+msgstr ""
+
+#: elf32-sh.c:4809
+#, c-format
+msgid "%s: unresolvable relocation against symbol `%s' from %s section"
+msgstr ""
+
+#: elf32-sh.c:4881
+#, c-format
+msgid "%s: 0x%lx: fatal: unaligned branch target for relax-support relocation"
+msgstr ""
+
+#: elf32-sh.c:6627 elf64-alpha.c:4848
+#, c-format
+msgid "%s: TLS local exec code cannot be linked into shared objects"
+msgstr ""
+
+#: elf32-sparc.c:2521 elf64-sparc.c:2314
#, c-format
msgid "%s: probably compiled without -fPIC?"
msgstr ""
-#: elf32-sparc.c:2010
+#: elf32-sparc.c:3348
#, c-format
msgid "%s: compiled for a 64 bit system and target is 32 bit"
msgstr ""
-#: elf32-sparc.c:2024
+#: elf32-sparc.c:3362
#, c-format
msgid "%s: linking little endian files with big endian files"
msgstr ""
-#: elf32-v850.c:682
+#: elf32-v850.c:753
#, c-format
msgid "Variable `%s' cannot occupy in multiple small data regions"
msgstr ""
-#: elf32-v850.c:685
+#: elf32-v850.c:756
#, c-format
msgid ""
"Variable `%s' can only be in one of the small, zero, and tiny data regions"
msgstr ""
-#: elf32-v850.c:688
+#: elf32-v850.c:759
#, c-format
msgid ""
"Variable `%s' cannot be in both small and zero data regions simultaneously"
msgstr ""
-#: elf32-v850.c:691
+#: elf32-v850.c:762
#, c-format
msgid ""
"Variable `%s' cannot be in both small and tiny data regions simultaneously"
msgstr ""
-#: elf32-v850.c:694
+#: elf32-v850.c:765
#, c-format
msgid ""
"Variable `%s' cannot be in both zero and tiny data regions simultaneously"
msgstr ""
-#: elf32-v850.c:1072
+#: elf32-v850.c:1144
msgid "FAILED to find previous HI16 reloc\n"
msgstr ""
-#: elf32-v850.c:1703
+#: elf32-v850.c:1789
msgid "could not locate special linker symbol __gp"
msgstr ""
-#: elf32-v850.c:1707
+#: elf32-v850.c:1793
msgid "could not locate special linker symbol __ep"
msgstr ""
-#: elf32-v850.c:1711
+#: elf32-v850.c:1797
msgid "could not locate special linker symbol __ctbp"
msgstr ""
-#: elf32-v850.c:1875
+#: elf32-v850.c:1963
#, c-format
msgid "%s: Architecture mismatch with previous modules"
msgstr ""
-#: elf32-v850.c:1895
+#: elf32-v850.c:1983
#, c-format
msgid "private flags = %lx: "
msgstr ""
-#: elf32-v850.c:1900
+#: elf32-v850.c:1988
msgid "v850 architecture"
msgstr ""
-#: elf32-v850.c:1901
+#: elf32-v850.c:1989
msgid "v850e architecture"
msgstr ""
-#: elf32-v850.c:1902
-msgid "v850ea architecture"
-msgstr ""
-
-#: elf32-vax.c:551
+#: elf32-vax.c:549
msgid " [nonpic]"
msgstr ""
-#: elf32-vax.c:554
+#: elf32-vax.c:552
msgid " [d-float]"
msgstr ""
-#: elf32-vax.c:557
+#: elf32-vax.c:555
msgid " [g-float]"
msgstr ""
-#: elf32-vax.c:665
+#: elf32-vax.c:663
#, c-format
msgid ""
"%s: warning: GOT addend of %ld to `%s' does not match previous GOT addend of "
"%ld"
msgstr ""
-#: elf32-vax.c:1687
+#: elf32-vax.c:1667
#, c-format
msgid "%s: warning: PLT addend of %d to `%s' from %s section ignored"
msgstr ""
-#: elf32-vax.c:1822
+#: elf32-vax.c:1802
#, c-format
msgid "%s: warning: %s relocation against symbol `%s' from %s section"
msgstr ""
-#: elf32-vax.c:1828
+#: elf32-vax.c:1808
#, c-format
msgid "%s: warning: %s relocation to 0x%x from %s section"
msgstr ""
-#: elf32-xstormy16.c:414 elf32-ia64.c:2286 elf64-ia64.c:2286
+#: elf32-ia64.c:2326 elf32-xstormy16.c:462 elf64-ia64.c:2326
msgid "non-zero addend in @fptr reloc"
msgstr ""
-#: elf64-alpha.c:1097
+#: elf64-alpha.c:1108
msgid "GPDISP relocation did not find ldah and lda instructions"
msgstr ""
-#: elf64-alpha.c:3676
+#: elf64-alpha.c:3731
#, c-format
msgid "%s: .got subsegment exceeds 64K (size %d)"
msgstr ""
-#: elf64-alpha.c:4499 elf64-alpha.c:4511
+#: elf64-alpha.c:4602 elf64-alpha.c:4614
#, c-format
msgid "%s: gp-relative relocation against dynamic symbol %s"
msgstr ""
-#: elf64-alpha.c:4537 elf64-alpha.c:4677
+#: elf64-alpha.c:4640 elf64-alpha.c:4773
#, c-format
msgid "%s: pc-relative relocation against dynamic symbol %s"
msgstr ""
-#: elf64-alpha.c:4565
+#: elf64-alpha.c:4668
#, c-format
msgid "%s: change in gp: BRSGP %s"
msgstr ""
-#: elf64-alpha.c:4590
+#: elf64-alpha.c:4693
msgid "<unknown>"
msgstr ""
-#: elf64-alpha.c:4595
+#: elf64-alpha.c:4698
#, c-format
msgid "%s: !samegp reloc against symbol without .prologue: %s"
msgstr ""
-#: elf64-alpha.c:4640
+#: elf64-alpha.c:4749
#, c-format
msgid "%s: unhandled dynamic relocation against %s"
msgstr ""
-#: elf64-alpha.c:4753
+#: elf64-alpha.c:4832
#, c-format
msgid "%s: dtp-relative relocation against dynamic symbol %s"
msgstr ""
-#: elf64-alpha.c:4769
-#, c-format
-msgid "%s: TLS local exec code cannot be linked into shared objects"
-msgstr ""
-
-#: elf64-alpha.c:4776
+#: elf64-alpha.c:4855
#, c-format
msgid "%s: tp-relative relocation against dynamic symbol %s"
msgstr ""
-#: elf64-hppa.c:2080
+#: elf64-hppa.c:2086
#, c-format
msgid "stub entry for %s cannot load .plt, dp offset = %ld"
msgstr ""
-#: elf64-mmix.c:1002
+#: elf64-mmix.c:1032
#, c-format
msgid ""
"%s: Internal inconsistency error for value for\n"
@@ -1387,704 +1495,842 @@ msgid ""
"08lx\n"
msgstr ""
-#: elf64-mmix.c:1386
+#: elf64-mmix.c:1416
#, c-format
msgid ""
"%s: base-plus-offset relocation against register symbol: (unknown) in %s"
msgstr ""
-#: elf64-mmix.c:1391
+#: elf64-mmix.c:1421
#, c-format
msgid "%s: base-plus-offset relocation against register symbol: %s in %s"
msgstr ""
-#: elf64-mmix.c:1435
+#: elf64-mmix.c:1465
#, c-format
msgid "%s: register relocation against non-register symbol: (unknown) in %s"
msgstr ""
-#: elf64-mmix.c:1440
+#: elf64-mmix.c:1470
#, c-format
msgid "%s: register relocation against non-register symbol: %s in %s"
msgstr ""
-#: elf64-mmix.c:1477
+#: elf64-mmix.c:1507
#, c-format
msgid "%s: directive LOCAL valid only with a register or absolute value"
msgstr ""
-#: elf64-mmix.c:1505
+#: elf64-mmix.c:1535
#, c-format
msgid ""
"%s: LOCAL directive: Register $%ld is not a local register. First global "
"register is $%ld."
msgstr ""
-#: elf64-mmix.c:1965
+#: elf64-mmix.c:1994
#, c-format
msgid ""
"%s: Error: multiple definition of `%s'; start of %s is set in a earlier "
"linked file\n"
msgstr ""
-#: elf64-mmix.c:2024
+#: elf64-mmix.c:2053
msgid "Register section has contents\n"
msgstr ""
-#: elf64-mmix.c:2186
+#: elf64-mmix.c:2216
#, c-format
msgid ""
"Internal inconsistency: remaining %u != max %u.\n"
" Please report this bug."
msgstr ""
-#: elf64-ppc.c:1669 libbfd.c:1435
+#: elf64-ppc.c:2388 libbfd.c:831
#, c-format
msgid "%s: compiled for a big endian system and target is little endian"
msgstr ""
-#: elf64-ppc.c:1671 libbfd.c:1437
+#: elf64-ppc.c:2391 libbfd.c:833
#, c-format
msgid "%s: compiled for a little endian system and target is big endian"
msgstr ""
-#: elf64-ppc.c:3614
+#: elf64-ppc.c:4857
#, c-format
msgid "%s: unexpected reloc type %u in .opd section"
msgstr ""
-#: elf64-ppc.c:3634
+#: elf64-ppc.c:4877
#, c-format
msgid "%s: .opd is not a regular array of opd entries"
msgstr ""
-#: elf64-ppc.c:3676
+#: elf64-ppc.c:4897
#, c-format
msgid "%s: undefined sym `%s' in .opd section"
msgstr ""
-#: elf64-ppc.c:4421
+#: elf64-ppc.c:6136
#, c-format
msgid "can't find branch stub `%s'"
msgstr ""
-#: elf64-ppc.c:4460 elf64-ppc.c:4504
+#: elf64-ppc.c:6175 elf64-ppc.c:6250
#, c-format
msgid "linkage table error against `%s'"
msgstr ""
-#: elf64-ppc.c:4576
+#: elf64-ppc.c:6340
#, c-format
msgid "can't build branch stub `%s'"
msgstr ""
-#: elf64-ppc.c:5202
+#: elf64-ppc.c:7047
+msgid ".glink and .plt too far apart"
+msgstr ""
+
+#: elf64-ppc.c:7135
msgid "stubs don't match calculated size"
msgstr ""
-#: elf64-ppc.c:5851
+#: elf64-ppc.c:7147
#, c-format
-msgid "%s: Relocation %s is not supported for symbol %s."
+msgid ""
+"linker stubs in %u groups\n"
+" branch %lu\n"
+" toc adjust %lu\n"
+" long branch %lu\n"
+" long toc adj %lu\n"
+" plt call %lu"
+msgstr ""
+
+#: elf64-ppc.c:7723
+#, c-format
+msgid ""
+"%s(%s+0x%lx): automatic multiple TOCs not supported using your crt files; "
+"recompile with -mminimal-toc or upgrade gcc"
+msgstr ""
+
+#: elf64-ppc.c:7731
+#, c-format
+msgid ""
+"%s(%s+0x%lx): sibling call optimization to `%s' does not allow automatic "
+"multiple TOCs; recompile with -mminimal-toc or -fno-optimize-sibling-calls, "
+"or make `%s' extern"
+msgstr ""
+
+#: elf64-ppc.c:8329
+#, c-format
+msgid "%s: relocation %s is not supported for symbol %s."
msgstr ""
-#: elf64-ppc.c:5895
+#: elf64-ppc.c:8408
#, c-format
-msgid "%s: error: relocation %s not a multiple of 4"
+msgid "%s: error: relocation %s not a multiple of %d"
msgstr ""
-#: elf64-sparc.c:1280
+#: elf-hppa.h:1458 elf-hppa.h:1491 elf-m10300.c:1628 elf64-sh64.c:1704
+#, c-format
+msgid ""
+"%s: warning: unresolvable relocation against symbol `%s' from %s section"
+msgstr ""
+
+#: elf64-sparc.c:1370
#, c-format
msgid "%s: check_relocs: unhandled reloc type %d"
msgstr ""
-#: elf64-sparc.c:1317
+#: elf64-sparc.c:1407
#, c-format
msgid "%s: Only registers %%g[2367] can be declared using STT_REGISTER"
msgstr ""
-#: elf64-sparc.c:1337
+#: elf64-sparc.c:1427
#, c-format
msgid "Register %%g%d used incompatibly: %s in %s, previously %s in %s"
msgstr ""
-#: elf64-sparc.c:1360
+#: elf64-sparc.c:1450
#, c-format
msgid "Symbol `%s' has differing types: REGISTER in %s, previously %s in %s"
msgstr ""
-#: elf64-sparc.c:1406
+#: elf64-sparc.c:1496
#, c-format
msgid "Symbol `%s' has differing types: %s in %s, previously REGISTER in %s"
msgstr ""
-#: elf64-sparc.c:2971
+#: elf64-sparc.c:3053
#, c-format
msgid "%s: linking UltraSPARC specific with HAL specific code"
msgstr ""
-#: elfcode.h:1198
+#: elf64-x86-64.c:739
+#, c-format
+msgid "%s: %s' accessed both as normal and thread local symbol"
+msgstr ""
+
+#: elf.c:372
+#, c-format
+msgid "%s: invalid string offset %u >= %lu for section `%s'"
+msgstr ""
+
+#: elf.c:624
+#, c-format
+msgid "%s: invalid SHT_GROUP entry"
+msgstr ""
+
+#: elf.c:695
+#, c-format
+msgid "%s: no group info for section %s"
+msgstr ""
+
+#: elf.c:1055
+msgid ""
+"\n"
+"Program Header:\n"
+msgstr ""
+
+#: elf.c:1106
+msgid ""
+"\n"
+"Dynamic Section:\n"
+msgstr ""
+
+#: elf.c:1235
+msgid ""
+"\n"
+"Version definitions:\n"
+msgstr ""
+
+#: elf.c:1258
+msgid ""
+"\n"
+"Version References:\n"
+msgstr ""
+
+#: elf.c:1263
+#, c-format
+msgid " required from %s:\n"
+msgstr ""
+
+#: elf.c:1944
+#, c-format
+msgid "%s: invalid link %lu for reloc section %s (index %u)"
+msgstr ""
+
+#: elf.c:3686
+#, c-format
+msgid "%s: Not enough room for program headers (allocated %u, need %u)"
+msgstr ""
+
+#: elf.c:3791
+#, c-format
+msgid "%s: Not enough room for program headers, try linking with -N"
+msgstr ""
+
+#: elf.c:3922
+#, c-format
+msgid ""
+"Error: First section in segment (%s) starts at 0x%x whereas the segment "
+"starts at 0x%x"
+msgstr ""
+
+#: elf.c:4242
+#, c-format
+msgid "%s: warning: allocated section `%s' not in segment"
+msgstr ""
+
+#: elf.c:4566
+#, c-format
+msgid "%s: symbol `%s' required but not present"
+msgstr ""
+
+#: elf.c:4854
+#, c-format
+msgid "%s: warning: Empty loadable segment detected, is this intentional ?\n"
+msgstr ""
+
+#: elf.c:5485
+#, c-format
+msgid ""
+"Unable to find equivalent output section for symbol '%s' from section '%s'"
+msgstr ""
+
+#: elf.c:6298
+#, c-format
+msgid "%s: unsupported relocation type %s"
+msgstr ""
+
+#: elfcode.h:1113
#, c-format
msgid "%s: version count (%ld) does not match symbol count (%ld)"
msgstr ""
-#: elfcode.h:1433
+#: elfcode.h:1342
#, c-format
msgid "%s(%s): relocation %d has invalid symbol index %ld"
msgstr ""
-#: elflink.c:536
+#: elflink.c:1456
#, c-format
-msgid "%s: Section %s is too large to add hole of %ld bytes"
+msgid "%s: warning: unexpected redefinition of indirect versioned symbol `%s'"
msgstr ""
-#: elflink.h:1098
+#: elflink.c:1807
#, c-format
-msgid "%s: warning: unexpected redefinition of indirect versioned symbol `%s'"
+msgid "%s: undefined versioned symbol name %s"
msgstr ""
-#: elflink.h:1745
+#: elflink.c:2142
#, c-format
-msgid "%s: %s: invalid version %u (max %d)"
+msgid "%s: relocation size mismatch in %s section %s"
msgstr ""
-#: elflink.h:1786
+#: elflink.c:2434
#, c-format
-msgid "%s: %s: invalid needed version %d"
+msgid "warning: type and size of dynamic symbol `%s' are not defined"
msgstr ""
-#: elflink.h:1908
+#: elflink.h:1022
#, c-format
-msgid "Warning: size of symbol `%s' changed from %lu to %lu in %s"
+msgid "%s: %s: invalid version %u (max %d)"
msgstr ""
-#: elflink.h:3116
+#: elflink.h:1063
#, c-format
-msgid "%s: undefined version: %s"
+msgid "%s: %s: invalid needed version %d"
msgstr ""
-#: elflink.h:3182
+#: elflink.h:1238
#, c-format
-msgid "%s: .preinit_array section is not allowed in DSO"
+msgid "Warning: alignment %u of symbol `%s' in %s is smaller than %u in %s"
msgstr ""
-#: elflink.h:4039
+#: elflink.h:1252
#, c-format
-msgid "warning: type and size of dynamic symbol `%s' are not defined"
+msgid "Warning: size of symbol `%s' changed from %lu in %s to %lu in %s"
msgstr ""
-#: elflink.h:4354
+#: elflink.h:2160
#, c-format
-msgid "%s: undefined versioned symbol name %s"
+msgid "%s: undefined version: %s"
msgstr ""
-#: elflink.h:4595 elflink.h:4603 elflink.h:6494 elflink.h:7569
-msgid "Error: out of memory"
+#: elflink.h:2226
+#, c-format
+msgid "%s: .preinit_array section is not allowed in DSO"
msgstr ""
-#: elflink.h:4767
+#: elflink.h:3078
msgid "Not enough memory to sort relocations"
msgstr ""
-#: elflink.h:5668 elflink.h:5711
+#: elflink.h:3958 elflink.h:4001
#, c-format
msgid "%s: could not find output section %s"
msgstr ""
-#: elflink.h:5674
+#: elflink.h:3964
#, c-format
msgid "warning: %s section has zero size"
msgstr ""
-#: elflink.h:6261
+#: elflink.h:4483
#, c-format
-msgid "%s: could not find output section %s for input section %s"
+msgid "%s: %s symbol `%s' in %s is referenced by DSO"
msgstr ""
-#: elflink.h:6472
+#: elflink.h:4564
#, c-format
-msgid "%s: relocation size mismatch in %s section %s"
+msgid "%s: could not find output section %s for input section %s"
msgstr ""
-#: elflink.h:6862
+#: elflink.h:4666
#, c-format
-msgid "local symbols in discarded section %s"
+msgid "%s: %s symbol `%s' isn't defined"
msgstr ""
-#: elfxx-mips.c:734
+#: elflink.h:5053 elflink.h:5095
+msgid "%T: discarded in section `%s' from %s\n"
+msgstr ""
+
+#: elfxx-mips.c:887
msgid "static procedure (no name)"
msgstr ""
-#: elfxx-mips.c:1604
+#: elfxx-mips.c:1897
msgid "not enough GOT space for local GOT entries"
msgstr ""
-#: elfxx-mips.c:2755
+#: elfxx-mips.c:3691
#, c-format
msgid "%s: %s+0x%lx: jump to stub routine which is not jal"
msgstr ""
-#: elfxx-mips.c:4264
+#: elfxx-mips.c:5192
#, c-format
msgid "%s: Malformed reloc detected for section %s"
msgstr ""
-#: elfxx-mips.c:4342
+#: elfxx-mips.c:5266
#, c-format
msgid "%s: CALL16 reloc at 0x%lx not against global symbol"
msgstr ""
-#: elfxx-mips.c:7296
+#: elfxx-mips.c:8693
#, c-format
msgid "%s: illegal section name `%s'"
msgstr ""
-#: elfxx-mips.c:7610
+#: elfxx-mips.c:9027
+#, c-format
+msgid "%s: endianness incompatible with that of the selected emulation"
+msgstr ""
+
+#: elfxx-mips.c:9039
#, c-format
-msgid "%s: linking PIC files with non-PIC files"
+msgid "%s: ABI is incompatible with that of the selected emulation"
msgstr ""
-#: elfxx-mips.c:7620
+#: elfxx-mips.c:9106
#, c-format
-msgid "%s: linking abicalls files with non-abicalls files"
+msgid "%s: warning: linking PIC files with non-PIC files"
msgstr ""
-#: elfxx-mips.c:7649
+#: elfxx-mips.c:9123
#, c-format
-msgid "%s: ISA mismatch (-mips%d) with previous modules (-mips%d)"
+msgid "%s: linking 32-bit code with 64-bit code"
msgstr ""
-#: elfxx-mips.c:7671
+#: elfxx-mips.c:9151
#, c-format
-msgid "%s: ISA mismatch (%d) with previous modules (%d)"
+msgid "%s: linking %s module with previous %s modules"
msgstr ""
-#: elfxx-mips.c:7694
+#: elfxx-mips.c:9174
#, c-format
msgid "%s: ABI mismatch: linking %s module with previous %s modules"
msgstr ""
-#: elfxx-mips.c:7763
+#: elfxx-mips.c:9243
msgid " [abi=O32]"
msgstr ""
-#: elfxx-mips.c:7765
+#: elfxx-mips.c:9245
msgid " [abi=O64]"
msgstr ""
-#: elfxx-mips.c:7767
+#: elfxx-mips.c:9247
msgid " [abi=EABI32]"
msgstr ""
-#: elfxx-mips.c:7769
+#: elfxx-mips.c:9249
msgid " [abi=EABI64]"
msgstr ""
-#: elfxx-mips.c:7771
+#: elfxx-mips.c:9251
msgid " [abi unknown]"
msgstr ""
-#: elfxx-mips.c:7773
+#: elfxx-mips.c:9253
msgid " [abi=N32]"
msgstr ""
-#: elfxx-mips.c:7775
+#: elfxx-mips.c:9255
msgid " [abi=64]"
msgstr ""
-#: elfxx-mips.c:7777
+#: elfxx-mips.c:9257
msgid " [no abi set]"
msgstr ""
-#: elfxx-mips.c:7780
+#: elfxx-mips.c:9260
msgid " [mips1]"
msgstr ""
-#: elfxx-mips.c:7782
+#: elfxx-mips.c:9262
msgid " [mips2]"
msgstr ""
-#: elfxx-mips.c:7784
+#: elfxx-mips.c:9264
msgid " [mips3]"
msgstr ""
-#: elfxx-mips.c:7786
+#: elfxx-mips.c:9266
msgid " [mips4]"
msgstr ""
-#: elfxx-mips.c:7788
+#: elfxx-mips.c:9268
msgid " [mips5]"
msgstr ""
-#: elfxx-mips.c:7790
+#: elfxx-mips.c:9270
msgid " [mips32]"
msgstr ""
-#: elfxx-mips.c:7792
+#: elfxx-mips.c:9272
msgid " [mips64]"
msgstr ""
-#: elfxx-mips.c:7794
+#: elfxx-mips.c:9274
+msgid " [mips32r2]"
+msgstr ""
+
+#: elfxx-mips.c:9276
msgid " [unknown ISA]"
msgstr ""
-#: elfxx-mips.c:7797
+#: elfxx-mips.c:9279
msgid " [mdmx]"
msgstr ""
-#: elfxx-mips.c:7800
+#: elfxx-mips.c:9282
msgid " [mips16]"
msgstr ""
-#: elfxx-mips.c:7803
+#: elfxx-mips.c:9285
msgid " [32bitmode]"
msgstr ""
-#: elfxx-mips.c:7805
+#: elfxx-mips.c:9287
msgid " [not 32bitmode]"
msgstr ""
-#: i386linux.c:458 m68klinux.c:462 sparclinux.c:459
+#: i386linux.c:457 m68klinux.c:461 sparclinux.c:458
#, c-format
msgid "Output file requires shared library `%s'\n"
msgstr ""
-#: i386linux.c:466 m68klinux.c:470 sparclinux.c:467
+#: i386linux.c:465 m68klinux.c:469 sparclinux.c:466
#, c-format
msgid "Output file requires shared library `%s.so.%s'\n"
msgstr ""
-#: i386linux.c:655 i386linux.c:705 m68klinux.c:662 m68klinux.c:710
-#: sparclinux.c:657 sparclinux.c:707
+#: i386linux.c:654 i386linux.c:704 m68klinux.c:661 m68klinux.c:709
+#: sparclinux.c:656 sparclinux.c:706
#, c-format
msgid "Symbol %s not defined for fixups\n"
msgstr ""
-#: i386linux.c:729 m68klinux.c:734 sparclinux.c:731
+#: i386linux.c:728 m68klinux.c:733 sparclinux.c:730
msgid "Warning: fixup count mismatch\n"
msgstr ""
-#: ieee.c:235
+#: ieee.c:293
#, c-format
msgid "%s: string too long (%d chars, max 65535)"
msgstr ""
-#: ieee.c:365
+#: ieee.c:428
#, c-format
msgid "%s: unrecognized symbol `%s' flags 0x%x"
msgstr ""
-#: ieee.c:877
+#: ieee.c:938
#, c-format
msgid "%s: unimplemented ATI record %u for symbol %u"
msgstr ""
-#: ieee.c:902
+#: ieee.c:963
#, c-format
msgid "%s: unexpected ATN type %d in external part"
msgstr ""
-#: ieee.c:924
+#: ieee.c:985
#, c-format
msgid "%s: unexpected type after ATN"
msgstr ""
-#: ihex.c:255
+#: ihex.c:264
#, c-format
msgid "%s:%d: unexpected character `%s' in Intel Hex file\n"
msgstr ""
-#: ihex.c:363
+#: ihex.c:372
#, c-format
msgid "%s:%u: bad checksum in Intel Hex file (expected %u, found %u)"
msgstr ""
-#: ihex.c:417
+#: ihex.c:426
#, c-format
msgid "%s:%u: bad extended address record length in Intel Hex file"
msgstr ""
-#: ihex.c:434
+#: ihex.c:443
#, c-format
msgid "%s:%u: bad extended start address length in Intel Hex file"
msgstr ""
-#: ihex.c:451
+#: ihex.c:460
#, c-format
msgid "%s:%u: bad extended linear address record length in Intel Hex file"
msgstr ""
-#: ihex.c:468
+#: ihex.c:477
#, c-format
msgid "%s:%u: bad extended linear start address length in Intel Hex file"
msgstr ""
-#: ihex.c:485
+#: ihex.c:494
#, c-format
msgid "%s:%u: unrecognized ihex type %u in Intel Hex file\n"
msgstr ""
-#: ihex.c:610
+#: ihex.c:619
#, c-format
msgid "%s: internal error in ihex_read_section"
msgstr ""
-#: ihex.c:645
+#: ihex.c:654
#, c-format
msgid "%s: bad section length in ihex_read_section"
msgstr ""
-#: ihex.c:863
+#: ihex.c:872
#, c-format
msgid "%s: address 0x%s out of range for Intel Hex file"
msgstr ""
-#: libbfd.c:492
-#, c-format
-msgid "not mapping: data=%lx mapped=%d\n"
-msgstr ""
-
-#: libbfd.c:495
-msgid "not mapping: env var not set\n"
-msgstr ""
-
-#: libbfd.c:1466
+#: libbfd.c:861
#, c-format
msgid "Deprecated %s called at %s line %d in %s\n"
msgstr ""
-#: libbfd.c:1469
+#: libbfd.c:864
#, c-format
msgid "Deprecated %s called\n"
msgstr ""
-#: linker.c:1875
+#: linker.c:1829
#, c-format
msgid "%s: indirect symbol `%s' to `%s' is a loop"
msgstr ""
-#: linker.c:2778
+#: linker.c:2697
#, c-format
-msgid "Attempt to do relocateable link with %s input and %s output"
+msgid "Attempt to do relocatable link with %s input and %s output"
msgstr ""
-#: merge.c:892
+#: merge.c:896
#, c-format
msgid "%s: access beyond end of merged section (%ld + %ld)"
msgstr ""
-#: mmo.c:460
+#: mmo.c:503
#, c-format
msgid "%s: No core to allocate section name %s\n"
msgstr ""
-#: mmo.c:536
+#: mmo.c:579
#, c-format
msgid "%s: No core to allocate a symbol %d bytes long\n"
msgstr ""
-#: mmo.c:1245
+#: mmo.c:1287
#, c-format
msgid "%s: invalid mmo file: initialization value for $255 is not `Main'\n"
msgstr ""
-#: mmo.c:1391
+#: mmo.c:1433
#, c-format
msgid ""
"%s: unsupported wide character sequence 0x%02X 0x%02X after symbol name "
"starting with `%s'\n"
msgstr ""
-#: mmo.c:1633
+#: mmo.c:1674
#, c-format
msgid "%s: invalid mmo file: unsupported lopcode `%d'\n"
msgstr ""
-#: mmo.c:1643
+#: mmo.c:1684
#, c-format
msgid "%s: invalid mmo file: expected YZ = 1 got YZ = %d for lop_quote\n"
msgstr ""
-#: mmo.c:1679
+#: mmo.c:1720
#, c-format
msgid "%s: invalid mmo file: expected z = 1 or z = 2, got z = %d for lop_loc\n"
msgstr ""
-#: mmo.c:1725
+#: mmo.c:1766
#, c-format
msgid ""
"%s: invalid mmo file: expected z = 1 or z = 2, got z = %d for lop_fixo\n"
msgstr ""
-#: mmo.c:1764
+#: mmo.c:1805
#, c-format
msgid "%s: invalid mmo file: expected y = 0, got y = %d for lop_fixrx\n"
msgstr ""
-#: mmo.c:1773
+#: mmo.c:1814
#, c-format
msgid ""
"%s: invalid mmo file: expected z = 16 or z = 24, got z = %d for lop_fixrx\n"
msgstr ""
-#: mmo.c:1796
+#: mmo.c:1837
#, c-format
msgid ""
"%s: invalid mmo file: leading byte of operand word must be 0 or 1, got %d "
"for lop_fixrx\n"
msgstr ""
-#: mmo.c:1819
+#: mmo.c:1860
#, c-format
msgid "%s: cannot allocate file name for file number %d, %d bytes\n"
msgstr ""
-#: mmo.c:1839
+#: mmo.c:1880
#, c-format
msgid ""
"%s: invalid mmo file: file number %d `%s', was already entered as `%s'\n"
msgstr ""
-#: mmo.c:1852
+#: mmo.c:1893
#, c-format
msgid ""
"%s: invalid mmo file: file name for number %d was not specified before use\n"
msgstr ""
-#: mmo.c:1958
+#: mmo.c:1999
#, c-format
msgid ""
"%s: invalid mmo file: fields y and z of lop_stab non-zero, y: %d, z: %d\n"
msgstr ""
-#: mmo.c:1994
+#: mmo.c:2035
#, c-format
msgid "%s: invalid mmo file: lop_end not last item in file\n"
msgstr ""
-#: mmo.c:2007
+#: mmo.c:2048
#, c-format
msgid ""
"%s: invalid mmo file: YZ of lop_end (%ld) not equal to the number of tetras "
"to the preceding lop_stab (%ld)\n"
msgstr ""
-#: mmo.c:2670
+#: mmo.c:2698
#, c-format
msgid "%s: invalid symbol table: duplicate symbol `%s'\n"
msgstr ""
-#: mmo.c:2921
+#: mmo.c:2949
#, c-format
msgid ""
"%s: Bad symbol definition: `Main' set to %s rather than the start address %"
"s\n"
msgstr ""
-#: mmo.c:3011
+#: mmo.c:3039
#, c-format
msgid ""
"%s: warning: symbol table too large for mmo, larger than 65535 32-bit words: "
"%d. Only `Main' will be emitted.\n"
msgstr ""
-#: mmo.c:3056
+#: mmo.c:3084
#, c-format
msgid "%s: internal error, symbol table changed size from %d to %d words\n"
msgstr ""
-#: mmo.c:3111
+#: mmo.c:3139
#, c-format
msgid "%s: internal error, internal register section %s had contents\n"
msgstr ""
-#: mmo.c:3163
+#: mmo.c:3191
#, c-format
msgid "%s: no initialized registers; section length 0\n"
msgstr ""
-#: mmo.c:3169
+#: mmo.c:3197
#, c-format
msgid "%s: too many initialized registers; section length %ld\n"
msgstr ""
-#: mmo.c:3174
+#: mmo.c:3202
#, c-format
msgid ""
"%s: invalid start address for initialized registers of length %ld: 0x%lx%"
"08lx\n"
msgstr ""
-#: oasys.c:1029
+#: oasys.c:1052
#, c-format
msgid "%s: can not represent section `%s' in oasys"
msgstr ""
-#: osf-core.c:132
+#: osf-core.c:137
#, c-format
msgid "Unhandled OSF/1 core file section type %d\n"
msgstr ""
-#: pe-mips.c:658
+#. XXX code yet to be written.
+#: peicode.h:787
#, c-format
-msgid "%s: `ld -r' not supported with PE MIPS objects\n"
+msgid "%s: Unhandled import type; %x"
msgstr ""
-#. OK, at this point the following variables are set up:
-#. src = VMA of the memory we're fixing up
-#. mem = pointer to memory we're fixing up
-#. val = VMA of what we need to refer to
-#.
-#: pe-mips.c:794
+#: peicode.h:792
#, c-format
-msgid "%s: unimplemented %s\n"
+msgid "%s: Unrecognised import type; %x"
msgstr ""
-#: pe-mips.c:820
+#: peicode.h:806
#, c-format
-msgid "%s: jump too far away\n"
+msgid "%s: Unrecognised import name type; %x"
msgstr ""
-#: pe-mips.c:847
+#: peicode.h:1164
#, c-format
-msgid "%s: bad pair/reflo after refhi\n"
+msgid "%s: Unrecognised machine type (0x%x) in Import Library Format archive"
msgstr ""
-#. XXX code yet to be written.
-#: peicode.h:785
+#: peicode.h:1176
#, c-format
-msgid "%s: Unhandled import type; %x"
+msgid ""
+"%s: Recognised but unhandled machine type (0x%x) in Import Library Format "
+"archive"
msgstr ""
-#: peicode.h:790
+#: peicode.h:1193
#, c-format
-msgid "%s: Unrecognised import type; %x"
+msgid "%s: size field is zero in Import Library Format header"
msgstr ""
-#: peicode.h:804
+#: peicode.h:1224
#, c-format
-msgid "%s: Unrecognised import name type; %x"
+msgid "%s: string not null terminated in ILF object file."
msgstr ""
-#: peicode.h:1162
+#: pe-mips.c:659
#, c-format
-msgid "%s: Unrecognised machine type (0x%x) in Import Library Format archive"
+msgid "%s: `ld -r' not supported with PE MIPS objects\n"
msgstr ""
-#: peicode.h:1174
+#. OK, at this point the following variables are set up:
+#. src = VMA of the memory we're fixing up
+#. mem = pointer to memory we're fixing up
+#. val = VMA of what we need to refer to
+#.
+#: pe-mips.c:795
#, c-format
-msgid ""
-"%s: Recognised but unhandled machine type (0x%x) in Import Library Format "
-"archive"
+msgid "%s: unimplemented %s\n"
msgstr ""
-#: peicode.h:1191
+#: pe-mips.c:821
#, c-format
-msgid "%s: size field is zero in Import Library Format header"
+msgid "%s: jump too far away\n"
msgstr ""
-#: peicode.h:1222
+#: pe-mips.c:848
#, c-format
-msgid "%s: string not null terminated in ILF object file."
+msgid "%s: bad pair/reflo after refhi\n"
msgstr ""
#: ppcboot.c:416
@@ -2135,7 +2381,7 @@ msgstr ""
msgid "Partition[%d] length = 0x%.8lx (%ld)\n"
msgstr ""
-#: som.c:5398
+#: som.c:5422
msgid "som_sizeof_headers unimplemented"
msgstr ""
@@ -2149,7 +2395,7 @@ msgstr ""
msgid "%s(%s+0x%lx): Stabs entry has invalid string index."
msgstr ""
-#: syms.c:1044
+#: syms.c:1019
msgid "Unsupported .stab relocation"
msgstr ""
@@ -2168,12 +2414,12 @@ msgstr ""
msgid "Size mismatch section %s=%lx, %s=%lx"
msgstr ""
-#: vms-gsd.c:702
+#: vms-gsd.c:704
#, c-format
msgid "unknown gsd/egsd subtype %d"
msgstr ""
-#: vms-hdr.c:406
+#: vms-hdr.c:408
msgid "Object module NOT error-free !\n"
msgstr ""
@@ -2199,31 +2445,31 @@ msgstr ""
msgid "Symbol %s replaced by %s\n"
msgstr ""
-#: vms-misc.c:1116
+#: vms-misc.c:1117
#, c-format
msgid "failed to enter %s"
msgstr ""
-#: vms-tir.c:81
+#: vms-tir.c:102
msgid "No Mem !"
msgstr ""
-#: vms-tir.c:362
+#: vms-tir.c:383
#, c-format
msgid "bad section index in %s"
msgstr ""
-#: vms-tir.c:375
+#: vms-tir.c:396
#, c-format
msgid "unsupported STA cmd %s"
msgstr ""
-#: vms-tir.c:380 vms-tir.c:1240
+#: vms-tir.c:401 vms-tir.c:1261
#, c-format
msgid "reserved STA cmd %d"
msgstr ""
-#: vms-tir.c:491 vms-tir.c:514
+#: vms-tir.c:512 vms-tir.c:535
#, c-format
msgid "%s: no symbol \"%s\""
msgstr ""
@@ -2232,39 +2478,39 @@ msgstr ""
#. rotate
#. Redefine symbol to current location.
#. Define a literal.
-#: vms-tir.c:581 vms-tir.c:693 vms-tir.c:803 vms-tir.c:821 vms-tir.c:829
-#: vms-tir.c:838 vms-tir.c:1563
+#: vms-tir.c:602 vms-tir.c:714 vms-tir.c:824 vms-tir.c:842 vms-tir.c:850
+#: vms-tir.c:859 vms-tir.c:1584
#, c-format
msgid "%s: not supported"
msgstr ""
-#: vms-tir.c:586 vms-tir.c:1418
+#: vms-tir.c:607 vms-tir.c:1439
#, c-format
msgid "%s: not implemented"
msgstr ""
-#: vms-tir.c:590 vms-tir.c:1422
+#: vms-tir.c:611 vms-tir.c:1443
#, c-format
msgid "reserved STO cmd %d"
msgstr ""
-#: vms-tir.c:708 vms-tir.c:1568
+#: vms-tir.c:729 vms-tir.c:1589
#, c-format
msgid "reserved OPR cmd %d"
msgstr ""
-#: vms-tir.c:776 vms-tir.c:1632
+#: vms-tir.c:797 vms-tir.c:1653
#, c-format
msgid "reserved CTL cmd %d"
msgstr ""
#. stack byte from image
#. arg: none.
-#: vms-tir.c:1148
+#: vms-tir.c:1169
msgid "stack-from-image not implemented"
msgstr ""
-#: vms-tir.c:1166
+#: vms-tir.c:1187
msgid "stack-entry-mask not fully implemented"
msgstr ""
@@ -2275,99 +2521,99 @@ msgstr ""
#.
#. compare argument descriptor with symbol argument (ARG$V_PASSMECH)
#. and stack TRUE (args match) or FALSE (args dont match) value.
-#: vms-tir.c:1180
+#: vms-tir.c:1201
msgid "PASSMECH not fully implemented"
msgstr ""
-#: vms-tir.c:1199
+#: vms-tir.c:1220
msgid "stack-local-symbol not fully implemented"
msgstr ""
-#: vms-tir.c:1212
+#: vms-tir.c:1233
msgid "stack-literal not fully implemented"
msgstr ""
-#: vms-tir.c:1233
+#: vms-tir.c:1254
msgid "stack-local-symbol-entry-point-mask not fully implemented"
msgstr ""
-#: vms-tir.c:1510 vms-tir.c:1522 vms-tir.c:1534 vms-tir.c:1546 vms-tir.c:1611
-#: vms-tir.c:1619 vms-tir.c:1627
+#: vms-tir.c:1531 vms-tir.c:1543 vms-tir.c:1555 vms-tir.c:1567 vms-tir.c:1632
+#: vms-tir.c:1640 vms-tir.c:1648
#, c-format
msgid "%s: not fully implemented"
msgstr ""
-#: vms-tir.c:1684
+#: vms-tir.c:1705
#, c-format
msgid "obj code %d not found"
msgstr ""
-#: vms-tir.c:2019
+#: vms-tir.c:2043
#, c-format
msgid "SEC_RELOC with no relocs in section %s"
msgstr ""
-#: vms-tir.c:2307
+#: vms-tir.c:2331
#, c-format
msgid "Unhandled relocation %s"
msgstr ""
-#: xcofflink.c:1243
+#: xcofflink.c:1244
#, c-format
msgid "%s: `%s' has line numbers but no enclosing section"
msgstr ""
-#: xcofflink.c:1296
+#: xcofflink.c:1297
#, c-format
msgid "%s: class %d symbol `%s' has no aux entries"
msgstr ""
-#: xcofflink.c:1319
+#: xcofflink.c:1320
#, c-format
msgid "%s: symbol `%s' has unrecognized csect type %d"
msgstr ""
-#: xcofflink.c:1331
+#: xcofflink.c:1332
#, c-format
msgid "%s: bad XTY_ER symbol `%s': class %d scnum %d scnlen %d"
msgstr ""
-#: xcofflink.c:1367
+#: xcofflink.c:1368
#, c-format
msgid "%s: XMC_TC0 symbol `%s' is class %d scnlen %d"
msgstr ""
-#: xcofflink.c:1519
+#: xcofflink.c:1520
#, c-format
msgid "%s: csect `%s' not in enclosing section"
msgstr ""
-#: xcofflink.c:1626
+#: xcofflink.c:1627
#, c-format
msgid "%s: misplaced XTY_LD `%s'"
msgstr ""
-#: xcofflink.c:1957
+#: xcofflink.c:1958
#, c-format
msgid "%s: reloc %s:%d not in csect"
msgstr ""
-#: xcofflink.c:2094
+#: xcofflink.c:2095
#, c-format
msgid "%s: XCOFF shared object when not producing XCOFF output"
msgstr ""
-#: xcofflink.c:2115
+#: xcofflink.c:2116
#, c-format
msgid "%s: dynamic object with no .loader section"
msgstr ""
-#: xcofflink.c:2760
+#: xcofflink.c:2761
#, c-format
msgid "%s: no such symbol"
msgstr ""
-#: xcofflink.c:2893
+#: xcofflink.c:2894
msgid "error: undefined symbol __rtinit"
msgstr ""
@@ -2376,234 +2622,244 @@ msgstr ""
msgid "warning: attempt to export undefined symbol `%s'"
msgstr ""
-#: xcofflink.c:4449
+#: xcofflink.c:4448
#, c-format
msgid "TOC overflow: 0x%lx > 0x10000; try -mminimal-toc when compiling"
msgstr ""
-#: xcofflink.c:5289 xcofflink.c:5758 xcofflink.c:5820 xcofflink.c:6124
+#: xcofflink.c:5288 xcofflink.c:5755 xcofflink.c:5817 xcofflink.c:6119
#, c-format
msgid "%s: loader reloc in unrecognized section `%s'"
msgstr ""
-#: xcofflink.c:5311 xcofflink.c:6135
+#: xcofflink.c:5310 xcofflink.c:6130
#, c-format
msgid "%s: `%s' in loader reloc but not loader sym"
msgstr ""
-#: xcofflink.c:5326
+#: xcofflink.c:5325
#, c-format
msgid "%s: loader reloc in read-only section %s"
msgstr ""
-#: elf32-ia64.c:2228 elf64-ia64.c:2228
+#: elf32-ia64.c:2271 elf64-ia64.c:2271
msgid "@pltoff reloc against local symbol"
msgstr ""
-#: elf32-ia64.c:3568 elf64-ia64.c:3568
+#: elf32-ia64.c:3663 elf64-ia64.c:3663
#, c-format
msgid "%s: short data segment overflowed (0x%lx >= 0x400000)"
msgstr ""
-#: elf32-ia64.c:3579 elf64-ia64.c:3579
+#: elf32-ia64.c:3674 elf64-ia64.c:3674
#, c-format
msgid "%s: __gp does not cover short data segment"
msgstr ""
-#: elf32-ia64.c:3864 elf64-ia64.c:3864
+#: elf32-ia64.c:3986 elf64-ia64.c:3986
#, c-format
msgid "%s: linking non-pic code in a shared library"
msgstr ""
-#: elf32-ia64.c:3897 elf64-ia64.c:3897
+#: elf32-ia64.c:4017 elf64-ia64.c:4017
#, c-format
msgid "%s: @gprel relocation against dynamic symbol %s"
msgstr ""
-#: elf32-ia64.c:4036 elf64-ia64.c:4036
+#: elf32-ia64.c:4077 elf64-ia64.c:4077
+#, c-format
+msgid "%s: linking non-pic code in a position independent executable"
+msgstr ""
+
+#: elf32-ia64.c:4214 elf64-ia64.c:4214
+#, c-format
+msgid "%s: @internal branch to dynamic symbol %s"
+msgstr ""
+
+#: elf32-ia64.c:4216 elf64-ia64.c:4216
#, c-format
-msgid "%s: dynamic relocation against speculation fixup"
+msgid "%s: speculation fixup to dynamic symbol %s"
msgstr ""
-#: elf32-ia64.c:4044 elf64-ia64.c:4044
+#: elf32-ia64.c:4218 elf64-ia64.c:4218
#, c-format
-msgid "%s: speculation fixup against undefined weak symbol"
+msgid "%s: @pcrel relocation against dynamic symbol %s"
msgstr ""
-#: elf32-ia64.c:4277 elf64-ia64.c:4277
+#: elf32-ia64.c:4430 elf64-ia64.c:4430
msgid "unsupported reloc"
msgstr ""
-#: elf32-ia64.c:4557 elf64-ia64.c:4557
+#: elf32-ia64.c:4709 elf64-ia64.c:4709
#, c-format
msgid "%s: linking trap-on-NULL-dereference with non-trapping files"
msgstr ""
-#: elf32-ia64.c:4566 elf64-ia64.c:4566
+#: elf32-ia64.c:4718 elf64-ia64.c:4718
#, c-format
msgid "%s: linking big-endian files with little-endian files"
msgstr ""
-#: elf32-ia64.c:4575 elf64-ia64.c:4575
+#: elf32-ia64.c:4727 elf64-ia64.c:4727
#, c-format
msgid "%s: linking 64-bit files with 32-bit files"
msgstr ""
-#: elf32-ia64.c:4584 elf64-ia64.c:4584
+#: elf32-ia64.c:4736 elf64-ia64.c:4736
#, c-format
msgid "%s: linking constant-gp files with non-constant-gp files"
msgstr ""
-#: elf32-ia64.c:4594 elf64-ia64.c:4594
+#: elf32-ia64.c:4746 elf64-ia64.c:4746
#, c-format
msgid "%s: linking auto-pic files with non-auto-pic files"
msgstr ""
-#: peigen.c:962 pepigen.c:962
+#: peigen.c:985 pepigen.c:985
#, c-format
msgid "%s: line number overflow: 0x%lx > 0xffff"
msgstr ""
-#: peigen.c:979 pepigen.c:979
+#: peigen.c:1002 pepigen.c:1002
#, c-format
msgid "%s: reloc overflow 1: 0x%lx > 0xffff"
msgstr ""
-#: peigen.c:993 pepigen.c:993
+#: peigen.c:1016 pepigen.c:1016
msgid "Export Directory [.edata (or where ever we found it)]"
msgstr ""
-#: peigen.c:994 pepigen.c:994
+#: peigen.c:1017 pepigen.c:1017
msgid "Import Directory [parts of .idata]"
msgstr ""
-#: peigen.c:995 pepigen.c:995
+#: peigen.c:1018 pepigen.c:1018
msgid "Resource Directory [.rsrc]"
msgstr ""
-#: peigen.c:996 pepigen.c:996
+#: peigen.c:1019 pepigen.c:1019
msgid "Exception Directory [.pdata]"
msgstr ""
-#: peigen.c:997 pepigen.c:997
+#: peigen.c:1020 pepigen.c:1020
msgid "Security Directory"
msgstr ""
-#: peigen.c:998 pepigen.c:998
+#: peigen.c:1021 pepigen.c:1021
msgid "Base Relocation Directory [.reloc]"
msgstr ""
-#: peigen.c:999 pepigen.c:999
+#: peigen.c:1022 pepigen.c:1022
msgid "Debug Directory"
msgstr ""
-#: peigen.c:1000 pepigen.c:1000
+#: peigen.c:1023 pepigen.c:1023
msgid "Description Directory"
msgstr ""
-#: peigen.c:1001 pepigen.c:1001
+#: peigen.c:1024 pepigen.c:1024
msgid "Special Directory"
msgstr ""
-#: peigen.c:1002 pepigen.c:1002
+#: peigen.c:1025 pepigen.c:1025
msgid "Thread Storage Directory [.tls]"
msgstr ""
-#: peigen.c:1003 pepigen.c:1003
+#: peigen.c:1026 pepigen.c:1026
msgid "Load Configuration Directory"
msgstr ""
-#: peigen.c:1004 pepigen.c:1004
+#: peigen.c:1027 pepigen.c:1027
msgid "Bound Import Directory"
msgstr ""
-#: peigen.c:1005 pepigen.c:1005
+#: peigen.c:1028 pepigen.c:1028
msgid "Import Address Table Directory"
msgstr ""
-#: peigen.c:1006 pepigen.c:1006
+#: peigen.c:1029 pepigen.c:1029
msgid "Delay Import Directory"
msgstr ""
-#: peigen.c:1007 peigen.c:1008 pepigen.c:1007 pepigen.c:1008
+#: peigen.c:1030 peigen.c:1031 pepigen.c:1030 pepigen.c:1031
msgid "Reserved"
msgstr ""
-#: peigen.c:1071 pepigen.c:1071
+#: peigen.c:1094 pepigen.c:1094
msgid ""
"\n"
"There is an import table, but the section containing it could not be found\n"
msgstr ""
-#: peigen.c:1076 pepigen.c:1076
+#: peigen.c:1099 pepigen.c:1099
#, c-format
msgid ""
"\n"
"There is an import table in %s at 0x%lx\n"
msgstr ""
-#: peigen.c:1113 pepigen.c:1113
+#: peigen.c:1136 pepigen.c:1136
#, c-format
msgid ""
"\n"
"Function descriptor located at the start address: %04lx\n"
msgstr ""
-#: peigen.c:1116 pepigen.c:1116
+#: peigen.c:1139 pepigen.c:1139
#, c-format
msgid "\tcode-base %08lx toc (loadable/actual) %08lx/%08lx\n"
msgstr ""
-#: peigen.c:1122 pepigen.c:1122
+#: peigen.c:1145 pepigen.c:1145
msgid ""
"\n"
"No reldata section! Function descriptor not decoded.\n"
msgstr ""
-#: peigen.c:1127 pepigen.c:1127
+#: peigen.c:1150 pepigen.c:1150
#, c-format
msgid ""
"\n"
"The Import Tables (interpreted %s section contents)\n"
msgstr ""
-#: peigen.c:1130 pepigen.c:1130
+#: peigen.c:1153 pepigen.c:1153
msgid ""
" vma: Hint Time Forward DLL First\n"
" Table Stamp Chain Name Thunk\n"
msgstr ""
-#: peigen.c:1181 pepigen.c:1181
+#: peigen.c:1204 pepigen.c:1204
#, c-format
msgid ""
"\n"
"\tDLL Name: %s\n"
msgstr ""
-#: peigen.c:1192 pepigen.c:1192
+#: peigen.c:1215 pepigen.c:1215
msgid "\tvma: Hint/Ord Member-Name Bound-To\n"
msgstr ""
-#: peigen.c:1217 pepigen.c:1217
+#: peigen.c:1240 pepigen.c:1240
msgid ""
"\n"
"There is a first thunk, but the section containing it could not be found\n"
msgstr ""
-#: peigen.c:1357 pepigen.c:1357
+#: peigen.c:1380 pepigen.c:1380
msgid ""
"\n"
"There is an export table, but the section containing it could not be found\n"
msgstr ""
-#: peigen.c:1362 pepigen.c:1362
+#: peigen.c:1385 pepigen.c:1385
#, c-format
msgid ""
"\n"
"There is an export table in %s at 0x%lx\n"
msgstr ""
-#: peigen.c:1393 pepigen.c:1393
+#: peigen.c:1416 pepigen.c:1416
#, c-format
msgid ""
"\n"
@@ -2611,129 +2867,129 @@ msgid ""
"\n"
msgstr ""
-#: peigen.c:1397 pepigen.c:1397
+#: peigen.c:1420 pepigen.c:1420
#, c-format
msgid "Export Flags \t\t\t%lx\n"
msgstr ""
-#: peigen.c:1400 pepigen.c:1400
+#: peigen.c:1423 pepigen.c:1423
#, c-format
msgid "Time/Date stamp \t\t%lx\n"
msgstr ""
-#: peigen.c:1403 pepigen.c:1403
+#: peigen.c:1426 pepigen.c:1426
#, c-format
msgid "Major/Minor \t\t\t%d/%d\n"
msgstr ""
-#: peigen.c:1406 pepigen.c:1406
+#: peigen.c:1429 pepigen.c:1429
msgid "Name \t\t\t\t"
msgstr ""
-#: peigen.c:1412 pepigen.c:1412
+#: peigen.c:1435 pepigen.c:1435
#, c-format
msgid "Ordinal Base \t\t\t%ld\n"
msgstr ""
-#: peigen.c:1415 pepigen.c:1415
+#: peigen.c:1438 pepigen.c:1438
msgid "Number in:\n"
msgstr ""
-#: peigen.c:1418 pepigen.c:1418
+#: peigen.c:1441 pepigen.c:1441
#, c-format
msgid "\tExport Address Table \t\t%08lx\n"
msgstr ""
-#: peigen.c:1422 pepigen.c:1422
+#: peigen.c:1445 pepigen.c:1445
#, c-format
msgid "\t[Name Pointer/Ordinal] Table\t%08lx\n"
msgstr ""
-#: peigen.c:1425 pepigen.c:1425
+#: peigen.c:1448 pepigen.c:1448
msgid "Table Addresses\n"
msgstr ""
-#: peigen.c:1428 pepigen.c:1428
+#: peigen.c:1451 pepigen.c:1451
msgid "\tExport Address Table \t\t"
msgstr ""
-#: peigen.c:1433 pepigen.c:1433
+#: peigen.c:1456 pepigen.c:1456
msgid "\tName Pointer Table \t\t"
msgstr ""
-#: peigen.c:1438 pepigen.c:1438
+#: peigen.c:1461 pepigen.c:1461
msgid "\tOrdinal Table \t\t\t"
msgstr ""
-#: peigen.c:1453 pepigen.c:1453
+#: peigen.c:1476 pepigen.c:1476
#, c-format
msgid ""
"\n"
"Export Address Table -- Ordinal Base %ld\n"
msgstr ""
-#: peigen.c:1472 pepigen.c:1472
+#: peigen.c:1495 pepigen.c:1495
msgid "Forwarder RVA"
msgstr ""
-#: peigen.c:1483 pepigen.c:1483
+#: peigen.c:1506 pepigen.c:1506
msgid "Export RVA"
msgstr ""
-#: peigen.c:1490 pepigen.c:1490
+#: peigen.c:1513 pepigen.c:1513
msgid ""
"\n"
"[Ordinal/Name Pointer] Table\n"
msgstr ""
-#: peigen.c:1545 pepigen.c:1545
+#: peigen.c:1568 pepigen.c:1568
#, c-format
msgid "Warning, .pdata section size (%ld) is not a multiple of %d\n"
msgstr ""
-#: peigen.c:1549 pepigen.c:1549
+#: peigen.c:1572 pepigen.c:1572
msgid ""
"\n"
"The Function Table (interpreted .pdata section contents)\n"
msgstr ""
-#: peigen.c:1552 pepigen.c:1552
+#: peigen.c:1575 pepigen.c:1575
msgid " vma:\t\t\tBegin Address End Address Unwind Info\n"
msgstr ""
-#: peigen.c:1554 pepigen.c:1554
+#: peigen.c:1577 pepigen.c:1577
msgid ""
" vma:\t\tBegin End EH EH PrologEnd Exception\n"
" \t\tAddress Address Handler Data Address Mask\n"
msgstr ""
-#: peigen.c:1624 pepigen.c:1624
+#: peigen.c:1647 pepigen.c:1647
msgid " Register save millicode"
msgstr ""
-#: peigen.c:1627 pepigen.c:1627
+#: peigen.c:1650 pepigen.c:1650
msgid " Register restore millicode"
msgstr ""
-#: peigen.c:1630 pepigen.c:1630
+#: peigen.c:1653 pepigen.c:1653
msgid " Glue code sequence"
msgstr ""
-#: peigen.c:1682 pepigen.c:1682
+#: peigen.c:1705 pepigen.c:1705
msgid ""
"\n"
"\n"
"PE File Base Relocations (interpreted .reloc section contents)\n"
msgstr ""
-#: peigen.c:1712 pepigen.c:1712
+#: peigen.c:1735 pepigen.c:1735
#, c-format
msgid ""
"\n"
"Virtual Address: %08lx Chunk size %ld (0x%lx) Number of fixups %ld\n"
msgstr ""
-#: peigen.c:1725 pepigen.c:1725
+#: peigen.c:1748 pepigen.c:1748
#, c-format
msgid "\treloc %4d offset %4x [%4lx] %s"
msgstr ""
@@ -2741,7 +2997,7 @@ msgstr ""
#. The MS dumpbin program reportedly ands with 0xff0f before
#. printing the characteristics field. Not sure why. No reason to
#. emulate it here.
-#: peigen.c:1765 pepigen.c:1765
+#: peigen.c:1788 pepigen.c:1788
#, c-format
msgid ""
"\n"
diff --git a/contrib/binutils/bfd/ppcboot.c b/contrib/binutils/bfd/ppcboot.c
index 5b153bd..05fb7de 100644
--- a/contrib/binutils/bfd/ppcboot.c
+++ b/contrib/binutils/bfd/ppcboot.c
@@ -1,5 +1,5 @@
/* BFD back-end for PPCbug boot records.
- Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002
+ Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Michael Meissner, Cygnus Support, <meissner@cygnus.com>
@@ -87,27 +87,27 @@ typedef struct ppcboot_data {
a start symbol, an end symbol, and an absolute length symbol. */
#define PPCBOOT_SYMS 3
-static boolean ppcboot_mkobject PARAMS ((bfd *));
+static bfd_boolean ppcboot_mkobject PARAMS ((bfd *));
static const bfd_target *ppcboot_object_p PARAMS ((bfd *));
-static boolean ppcboot_set_arch_mach
+static bfd_boolean ppcboot_set_arch_mach
PARAMS ((bfd *, enum bfd_architecture, unsigned long));
-static boolean ppcboot_get_section_contents
+static bfd_boolean ppcboot_get_section_contents
PARAMS ((bfd *, asection *, PTR, file_ptr, bfd_size_type));
static long ppcboot_get_symtab_upper_bound PARAMS ((bfd *));
static char *mangle_name PARAMS ((bfd *, char *));
-static long ppcboot_get_symtab PARAMS ((bfd *, asymbol **));
+static long ppcboot_canonicalize_symtab PARAMS ((bfd *, asymbol **));
static void ppcboot_get_symbol_info PARAMS ((bfd *, asymbol *, symbol_info *));
-static boolean ppcboot_set_section_contents
- PARAMS ((bfd *, asection *, PTR, file_ptr, bfd_size_type));
-static int ppcboot_sizeof_headers PARAMS ((bfd *, boolean));
-static boolean ppcboot_bfd_print_private_bfd_data PARAMS ((bfd *, PTR));
+static bfd_boolean ppcboot_set_section_contents
+ PARAMS ((bfd *, asection *, const PTR, file_ptr, bfd_size_type));
+static int ppcboot_sizeof_headers PARAMS ((bfd *, bfd_boolean));
+static bfd_boolean ppcboot_bfd_print_private_bfd_data PARAMS ((bfd *, PTR));
#define ppcboot_set_tdata(abfd, ptr) ((abfd)->tdata.any = (PTR) (ptr))
#define ppcboot_get_tdata(abfd) ((ppcboot_data_t *) ((abfd)->tdata.any))
/* Create a ppcboot object. Invoked via bfd_set_format. */
-static boolean
+static bfd_boolean
ppcboot_mkobject (abfd)
bfd *abfd;
{
@@ -117,12 +117,12 @@ ppcboot_mkobject (abfd)
ppcboot_set_tdata (abfd, bfd_zalloc (abfd, amt));
}
- return true;
+ return TRUE;
}
/* Set the architecture to PowerPC */
-static boolean
+static bfd_boolean
ppcboot_set_arch_mach (abfd, arch, machine)
bfd *abfd;
enum bfd_architecture arch;
@@ -132,7 +132,7 @@ ppcboot_set_arch_mach (abfd, arch, machine)
arch = bfd_arch_powerpc;
else if (arch != bfd_arch_powerpc)
- return false;
+ return FALSE;
return bfd_default_set_arch_mach (abfd, arch, machine);
}
@@ -229,7 +229,7 @@ ppcboot_object_p (abfd)
/* Get contents of the only section. */
-static boolean
+static bfd_boolean
ppcboot_get_section_contents (abfd, section, location, offset, count)
bfd *abfd;
asection *section ATTRIBUTE_UNUSED;
@@ -239,8 +239,8 @@ ppcboot_get_section_contents (abfd, section, location, offset, count)
{
if (bfd_seek (abfd, offset + (file_ptr) sizeof (ppcboot_hdr_t), SEEK_SET) != 0
|| bfd_bread (location, count, abfd) != count)
- return false;
- return true;
+ return FALSE;
+ return TRUE;
}
@@ -287,7 +287,7 @@ mangle_name (abfd, suffix)
/* Return the symbol table. */
static long
-ppcboot_get_symtab (abfd, alocation)
+ppcboot_canonicalize_symtab (abfd, alocation)
bfd *abfd;
asymbol **alocation;
{
@@ -298,7 +298,7 @@ ppcboot_get_symtab (abfd, alocation)
syms = (asymbol *) bfd_alloc (abfd, amt);
if (syms == NULL)
- return false;
+ return FALSE;
/* Start symbol. */
syms[0].the_bfd = abfd;
@@ -360,11 +360,11 @@ ppcboot_get_symbol_info (ignore_abfd, symbol, ret)
/* Write section contents of a ppcboot file. */
-static boolean
+static bfd_boolean
ppcboot_set_section_contents (abfd, sec, data, offset, size)
bfd *abfd;
asection *sec;
- PTR data;
+ const PTR data;
file_ptr offset;
bfd_size_type size;
{
@@ -384,7 +384,7 @@ ppcboot_set_section_contents (abfd, sec, data, offset, size)
for (s = abfd->sections; s != NULL; s = s->next)
s->filepos = s->vma - low;
- abfd->output_has_begun = true;
+ abfd->output_has_begun = TRUE;
}
return _bfd_generic_set_section_contents (abfd, sec, data, offset, size);
@@ -394,7 +394,7 @@ ppcboot_set_section_contents (abfd, sec, data, offset, size)
static int
ppcboot_sizeof_headers (abfd, exec)
bfd *abfd ATTRIBUTE_UNUSED;
- boolean exec ATTRIBUTE_UNUSED;
+ bfd_boolean exec ATTRIBUTE_UNUSED;
{
return sizeof (ppcboot_hdr_t);
}
@@ -402,7 +402,7 @@ ppcboot_sizeof_headers (abfd, exec)
/* Print out the program headers. */
-static boolean
+static bfd_boolean
ppcboot_bfd_print_private_bfd_data (abfd, farg)
bfd *abfd;
PTR farg;
@@ -460,7 +460,7 @@ ppcboot_bfd_print_private_bfd_data (abfd, farg)
}
fprintf (f, "\n");
- return true;
+ return TRUE;
}
diff --git a/contrib/binutils/bfd/ptrace-core.c b/contrib/binutils/bfd/ptrace-core.c
index f8db927..15b6777 100644
--- a/contrib/binutils/bfd/ptrace-core.c
+++ b/contrib/binutils/bfd/ptrace-core.c
@@ -1,5 +1,5 @@
/* BFD backend for core files which use the ptrace_user structure
- Copyright 1993, 1994, 1995, 1996, 1998, 1999, 2001, 2002
+ Copyright 1993, 1994, 1995, 1996, 1998, 1999, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
The structure of this file is based on trad-core.c written by John Gilmore
of Cygnus Support.
@@ -49,13 +49,12 @@ struct trad_core_struct
/* forward declarations */
const bfd_target *ptrace_unix_core_file_p PARAMS ((bfd *abfd));
-char * ptrace_unix_core_file_failing_command PARAMS ((bfd *abfd));
-int ptrace_unix_core_file_failing_signal PARAMS ((bfd *abfd));
-boolean ptrace_unix_core_file_matches_executable_p
- PARAMS ((bfd *core_bfd, bfd *exec_bfd));
-static void swap_abort PARAMS ((void));
+char * ptrace_unix_core_file_failing_command PARAMS ((bfd *abfd));
+int ptrace_unix_core_file_failing_signal PARAMS ((bfd *abfd));
+bfd_boolean ptrace_unix_core_file_matches_executable_p
+ PARAMS ((bfd *core_bfd, bfd *exec_bfd));
+static void swap_abort PARAMS ((void));
-/* ARGSUSED */
const bfd_target *
ptrace_unix_core_file_p (abfd)
bfd *abfd;
@@ -146,7 +145,6 @@ ptrace_unix_core_file_failing_command (abfd)
return 0;
}
-/* ARGSUSED */
int
ptrace_unix_core_file_failing_signal (abfd)
bfd *abfd;
@@ -154,14 +152,13 @@ ptrace_unix_core_file_failing_signal (abfd)
return abfd->tdata.trad_core_data->u.pt_sigframe.sig_num;
}
-/* ARGSUSED */
-boolean
+bfd_boolean
ptrace_unix_core_file_matches_executable_p (core_bfd, exec_bfd)
bfd *core_bfd, *exec_bfd;
{
/* FIXME: Use pt_timdat field of the ptrace_user structure to match
the date of the executable */
- return true;
+ return TRUE;
}
/* If somebody calls any byte-swapping routines, shoot them. */
@@ -170,10 +167,13 @@ swap_abort ()
{
abort (); /* This way doesn't require any declaration for ANSI to fuck up */
}
-#define NO_GET ((bfd_vma (*) PARAMS (( const bfd_byte *))) swap_abort )
-#define NO_PUT ((void (*) PARAMS ((bfd_vma, bfd_byte *))) swap_abort )
-#define NO_SIGNED_GET \
- ((bfd_signed_vma (*) PARAMS ((const bfd_byte *))) swap_abort )
+
+#define NO_GET ((bfd_vma (*) (const void *)) swap_abort)
+#define NO_PUT ((void (*) (bfd_vma, void *)) swap_abort)
+#define NO_GETS ((bfd_signed_vma (*) (const void *)) swap_abort)
+#define NO_GET64 ((bfd_uint64_t (*) (const void *)) swap_abort)
+#define NO_PUT64 ((void (*) (bfd_uint64_t, void *)) swap_abort)
+#define NO_GETS64 ((bfd_int64_t (*) (const void *)) swap_abort)
const bfd_target ptrace_core_vec =
{
@@ -188,41 +188,41 @@ const bfd_target ptrace_core_vec =
0, /* symbol prefix */
' ', /* ar_pad_char */
16, /* ar_max_namelen */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 64 bit data */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 32 bit data */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 16 bit data */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 64 bit hdrs */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 32 bit hdrs */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 16 bit hdrs */
+ NO_GET64, NO_GETS64, NO_PUT64, /* 64 bit data */
+ NO_GET, NO_GETS, NO_PUT, /* 32 bit data */
+ NO_GET, NO_GETS, NO_PUT, /* 16 bit data */
+ NO_GET64, NO_GETS64, NO_PUT64, /* 64 bit hdrs */
+ NO_GET, NO_GETS, NO_PUT, /* 32 bit hdrs */
+ NO_GET, NO_GETS, NO_PUT, /* 16 bit hdrs */
{ /* bfd_check_format */
- _bfd_dummy_target, /* unknown format */
- _bfd_dummy_target, /* object file */
- _bfd_dummy_target, /* archive */
- ptrace_unix_core_file_p /* a core file */
+ _bfd_dummy_target, /* unknown format */
+ _bfd_dummy_target, /* object file */
+ _bfd_dummy_target, /* archive */
+ ptrace_unix_core_file_p /* a core file */
},
{ /* bfd_set_format */
- bfd_false, bfd_false,
- bfd_false, bfd_false
+ bfd_false, bfd_false,
+ bfd_false, bfd_false
},
{ /* bfd_write_contents */
- bfd_false, bfd_false,
- bfd_false, bfd_false
+ bfd_false, bfd_false,
+ bfd_false, bfd_false
},
- BFD_JUMP_TABLE_GENERIC (_bfd_generic),
- BFD_JUMP_TABLE_COPY (_bfd_generic),
- BFD_JUMP_TABLE_CORE (ptrace_unix),
- BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive),
- BFD_JUMP_TABLE_SYMBOLS (_bfd_nosymbols),
- BFD_JUMP_TABLE_RELOCS (_bfd_norelocs),
- BFD_JUMP_TABLE_WRITE (_bfd_generic),
- BFD_JUMP_TABLE_LINK (_bfd_nolink),
- BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
+ BFD_JUMP_TABLE_GENERIC (_bfd_generic),
+ BFD_JUMP_TABLE_COPY (_bfd_generic),
+ BFD_JUMP_TABLE_CORE (ptrace_unix),
+ BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive),
+ BFD_JUMP_TABLE_SYMBOLS (_bfd_nosymbols),
+ BFD_JUMP_TABLE_RELOCS (_bfd_norelocs),
+ BFD_JUMP_TABLE_WRITE (_bfd_generic),
+ BFD_JUMP_TABLE_LINK (_bfd_nolink),
+ BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
NULL,
(PTR) 0 /* backend_data */
-};
+ };
#endif /* PTRACE_CORE */
diff --git a/contrib/binutils/bfd/reloc.c b/contrib/binutils/bfd/reloc.c
index 01ff516..9bffaa3 100644
--- a/contrib/binutils/bfd/reloc.c
+++ b/contrib/binutils/bfd/reloc.c
@@ -1,24 +1,24 @@
/* BFD support for handling relocation entries.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
Written by Cygnus Support.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/*
SECTION
@@ -98,7 +98,7 @@ CODE_FRAGMENT
.typedef struct reloc_cache_entry
.{
. {* A pointer into the canonical table of pointers. *}
-. struct symbol_cache_entry **sym_ptr_ptr;
+. struct bfd_symbol **sym_ptr_ptr;
.
. {* offset in section. *}
. bfd_size_type address;
@@ -122,15 +122,16 @@ DESCRIPTION
o <<sym_ptr_ptr>>
The symbol table pointer points to a pointer to the symbol
- associated with the relocation request. It is
- the pointer into the table returned by the back end's
- <<get_symtab>> action. @xref{Symbols}. The symbol is referenced
- through a pointer to a pointer so that tools like the linker
- can fix up all the symbols of the same name by modifying only
- one pointer. The relocation routine looks in the symbol and
- uses the base of the section the symbol is attached to and the
- value of the symbol as the initial relocation offset. If the
- symbol pointer is zero, then the section provided is looked up.
+ associated with the relocation request. It is the pointer
+ into the table returned by the back end's
+ <<canonicalize_symtab>> action. @xref{Symbols}. The symbol is
+ referenced through a pointer to a pointer so that tools like
+ the linker can fix up all the symbols of the same name by
+ modifying only one pointer. The relocation routine looks in
+ the symbol and uses the base of the section the symbol is
+ attached to and the value of the symbol as the initial
+ relocation offset. If the symbol pointer is zero, then the
+ section provided is looked up.
o <<address>>
@@ -277,7 +278,7 @@ SUBSUBSECTION
information that libbfd needs to know to tie up a back end's data.
CODE_FRAGMENT
-.struct symbol_cache_entry; {* Forward declaration. *}
+.struct bfd_symbol; {* Forward declaration. *}
.
.struct reloc_howto_struct
.{
@@ -306,7 +307,7 @@ CODE_FRAGMENT
. data section of the addend. The relocation function will
. subtract from the relocation value the address of the location
. being relocated. *}
-. boolean pc_relative;
+. bfd_boolean pc_relative;
.
. {* The bit position of the reloc value in the destination.
. The relocated value is left shifted by this amount. *}
@@ -318,11 +319,11 @@ CODE_FRAGMENT
.
. {* If this field is non null, then the supplied function is
. called rather than the normal function. This allows really
-. strange relocation methods to be accomodated (e.g., i960 callj
+. strange relocation methods to be accommodated (e.g., i960 callj
. instructions). *}
. bfd_reloc_status_type (*special_function)
-. PARAMS ((bfd *, arelent *, struct symbol_cache_entry *, PTR, asection *,
-. bfd *, char **));
+. (bfd *, arelent *, struct bfd_symbol *, void *, asection *,
+. bfd *, char **);
.
. {* The textual name of the relocation type. *}
. char *name;
@@ -342,21 +343,20 @@ CODE_FRAGMENT
. USE_REL targets set this field to TRUE. Why this is so is peculiar
. to each particular target. For relocs that aren't used in partial
. links (e.g. GOT stuff) it doesn't matter what this is set to. *}
-. boolean partial_inplace;
+. bfd_boolean partial_inplace;
.
-. {* The src_mask selects which parts of the read in data
-. are to be used in the relocation sum. E.g., if this was an 8 bit
-. byte of data which we read and relocated, this would be
-. 0x000000ff. When we have relocs which have an addend, such as
-. sun4 extended relocs, the value in the offset part of a
-. relocating field is garbage so we never use it. In this case
-. the mask would be 0x00000000. *}
+. {* src_mask selects the part of the instruction (or data) to be used
+. in the relocation sum. If the target relocations don't have an
+. addend in the reloc, eg. ELF USE_REL, src_mask will normally equal
+. dst_mask to extract the addend from the section contents. If
+. relocations do have an addend in the reloc, eg. ELF USE_RELA, this
+. field should be zero. Non-zero values for ELF USE_RELA targets are
+. bogus as in those cases the value in the dst_mask part of the
+. section contents should be treated as garbage. *}
. bfd_vma src_mask;
.
-. {* The dst_mask selects which parts of the instruction are replaced
-. into the instruction. In most cases src_mask == dst_mask,
-. except in the above special case, where dst_mask would be
-. 0x000000ff, and src_mask would be 0x00000000. *}
+. {* dst_mask selects which parts of the instruction (or data) are
+. replaced with a relocated value. *}
. bfd_vma dst_mask;
.
. {* When some formats create PC relative instructions, they leave
@@ -365,7 +365,7 @@ CODE_FRAGMENT
. be made just by adding in an ordinary offset (e.g., sun3 a.out).
. Some formats leave the displacement part of an instruction
. empty (e.g., m88k bcs); this flag signals the fact. *}
-. boolean pcrel_offset;
+. bfd_boolean pcrel_offset;
.};
.
*/
@@ -386,15 +386,15 @@ DESCRIPTION
.#define NEWHOWTO(FUNCTION, NAME, SIZE, REL, IN) \
. HOWTO (0, 0, SIZE, 0, REL, 0, complain_overflow_dont, FUNCTION, \
-. NAME, false, 0, 0, IN)
+. NAME, FALSE, 0, 0, IN)
.
DESCRIPTION
This is used to fill in an empty howto entry in an array.
.#define EMPTY_HOWTO(C) \
-. HOWTO ((C), 0, 0, 0, false, 0, complain_overflow_dont, NULL, \
-. NULL, false, 0, 0, false)
+. HOWTO ((C), 0, 0, 0, FALSE, 0, complain_overflow_dont, NULL, \
+. NULL, FALSE, 0, 0, FALSE)
.
DESCRIPTION
@@ -402,7 +402,7 @@ DESCRIPTION
.#define HOWTO_PREPARE(relocation, symbol) \
. { \
-. if (symbol != (asymbol *) NULL) \
+. if (symbol != NULL) \
. { \
. if (bfd_is_com_section (symbol->section)) \
. { \
@@ -430,8 +430,7 @@ DESCRIPTION
*/
unsigned int
-bfd_get_reloc_size (howto)
- reloc_howto_type *howto;
+bfd_get_reloc_size (reloc_howto_type *howto)
{
switch (howto->size)
{
@@ -471,13 +470,12 @@ FUNCTION
bfd_check_overflow
SYNOPSIS
- bfd_reloc_status_type
- bfd_check_overflow
- (enum complain_overflow how,
- unsigned int bitsize,
- unsigned int rightshift,
- unsigned int addrsize,
- bfd_vma relocation);
+ bfd_reloc_status_type bfd_check_overflow
+ (enum complain_overflow how,
+ unsigned int bitsize,
+ unsigned int rightshift,
+ unsigned int addrsize,
+ bfd_vma relocation);
DESCRIPTION
Perform overflow checking on @var{relocation} which has
@@ -489,12 +487,11 @@ DESCRIPTION
*/
bfd_reloc_status_type
-bfd_check_overflow (how, bitsize, rightshift, addrsize, relocation)
- enum complain_overflow how;
- unsigned int bitsize;
- unsigned int rightshift;
- unsigned int addrsize;
- bfd_vma relocation;
+bfd_check_overflow (enum complain_overflow how,
+ unsigned int bitsize,
+ unsigned int rightshift,
+ unsigned int addrsize,
+ bfd_vma relocation)
{
bfd_vma fieldmask, addrmask, signmask, ss, a;
bfd_reloc_status_type flag = bfd_reloc_ok;
@@ -554,14 +551,13 @@ FUNCTION
bfd_perform_relocation
SYNOPSIS
- bfd_reloc_status_type
- bfd_perform_relocation
- (bfd *abfd,
- arelent *reloc_entry,
- PTR data,
- asection *input_section,
- bfd *output_bfd,
- char **error_message);
+ bfd_reloc_status_type bfd_perform_relocation
+ (bfd *abfd,
+ arelent *reloc_entry,
+ void *data,
+ asection *input_section,
+ bfd *output_bfd,
+ char **error_message);
DESCRIPTION
If @var{output_bfd} is supplied to this function, the
@@ -582,14 +578,12 @@ DESCRIPTION
*/
bfd_reloc_status_type
-bfd_perform_relocation (abfd, reloc_entry, data, input_section, output_bfd,
- error_message)
- bfd *abfd;
- arelent *reloc_entry;
- PTR data;
- asection *input_section;
- bfd *output_bfd;
- char **error_message;
+bfd_perform_relocation (bfd *abfd,
+ arelent *reloc_entry,
+ void *data,
+ asection *input_section,
+ bfd *output_bfd,
+ char **error_message)
{
bfd_vma relocation;
bfd_reloc_status_type flag = bfd_reloc_ok;
@@ -601,18 +595,18 @@ bfd_perform_relocation (abfd, reloc_entry, data, input_section, output_bfd,
symbol = *(reloc_entry->sym_ptr_ptr);
if (bfd_is_abs_section (symbol->section)
- && output_bfd != (bfd *) NULL)
+ && output_bfd != NULL)
{
reloc_entry->address += input_section->output_offset;
return bfd_reloc_ok;
}
- /* If we are not producing relocateable output, return an error if
+ /* If we are not producing relocatable output, return an error if
the symbol is not defined. An undefined weak symbol is
considered to have a value of zero (SVR4 ABI, p. 4-27). */
if (bfd_is_und_section (symbol->section)
&& (symbol->flags & BSF_WEAK) == 0
- && output_bfd == (bfd *) NULL)
+ && output_bfd == NULL)
flag = bfd_reloc_undefined;
/* If there is a function supplied to handle this relocation type,
@@ -633,7 +627,7 @@ bfd_perform_relocation (abfd, reloc_entry, data, input_section, output_bfd,
/ bfd_octets_per_byte (abfd)))
return bfd_reloc_outofrange;
- /* Work out which section the relocation is targetted at and the
+ /* Work out which section the relocation is targeted at and the
initial relocation command value. */
/* Get symbol value. (Common symbols are special.) */
@@ -645,7 +639,8 @@ bfd_perform_relocation (abfd, reloc_entry, data, input_section, output_bfd,
reloc_target_output_section = symbol->section->output_section;
/* Convert input-section-relative symbol value to absolute. */
- if (output_bfd && ! howto->partial_inplace)
+ if ((output_bfd && ! howto->partial_inplace)
+ || reloc_target_output_section == NULL)
output_base = 0;
else
output_base = reloc_target_output_section->vma;
@@ -671,20 +666,20 @@ bfd_perform_relocation (abfd, reloc_entry, data, input_section, output_bfd,
of the location within the section. Some targets arrange for
the addend to be the negative of the position of the location
within the section; for example, i386-aout does this. For
- i386-aout, pcrel_offset is false. Some other targets do not
+ i386-aout, pcrel_offset is FALSE. Some other targets do not
include the position of the location; for example, m88kbcs,
- or ELF. For those targets, pcrel_offset is true.
+ or ELF. For those targets, pcrel_offset is TRUE.
- If we are producing relocateable output, then we must ensure
+ If we are producing relocatable output, then we must ensure
that this reloc will be correctly computed when the final
- relocation is done. If pcrel_offset is false we want to wind
+ relocation is done. If pcrel_offset is FALSE we want to wind
up with the negative of the location within the section,
which means we must adjust the existing addend by the change
- in the location within the section. If pcrel_offset is true
+ in the location within the section. If pcrel_offset is TRUE
we do not want to adjust the existing addend at all.
FIXME: This seems logical to me, but for the case of
- producing relocateable output it is not what the code
+ producing relocatable output it is not what the code
actually does. I don't want to change it, because it seems
far too likely that something will break. */
@@ -695,7 +690,7 @@ bfd_perform_relocation (abfd, reloc_entry, data, input_section, output_bfd,
relocation -= reloc_entry->address;
}
- if (output_bfd != (bfd *) NULL)
+ if (output_bfd != NULL)
{
if (! howto->partial_inplace)
{
@@ -739,7 +734,7 @@ Hmmm. The first obvious point is that bfd_perform_relocation should
not have any tests that depend upon the flavour. It's seem like
entirely the wrong place for such a thing. The second obvious point
is that the current code ignores the reloc addend when producing
-relocateable output for COFF. That's peculiar. In fact, I really
+relocatable output for COFF. That's peculiar. In fact, I really
have no idea what the point of the line you want to remove is.
A typical COFF reloc subtracts the old value of the symbol and adds in
@@ -754,9 +749,9 @@ different story (we can't change it without losing backward
compatibility with old object files) (coff-i386 does subtract the old
value, to be compatible with existing coff-i386 targets, like SCO).
-So everything works fine when not producing relocateable output. When
-we are producing relocateable output, logically we should do exactly
-what we do when not producing relocateable output. Therefore, your
+So everything works fine when not producing relocatable output. When
+we are producing relocatable output, logically we should do exactly
+what we do when not producing relocatable output. Therefore, your
patch is correct. In fact, it should probably always just set
reloc_entry->addend to 0 for all cases, since it is, in fact, going to
add the value into the object file. This won't hurt the COFF code,
@@ -764,7 +759,7 @@ which doesn't use the addend; I'm not sure what it will do to other
formats (the thing to check for would be whether any formats both use
the addend and set partial_inplace).
-When I wanted to make coff-i386 produce relocateable output, I ran
+When I wanted to make coff-i386 produce relocatable output, I ran
into the problem that you are running into: I wanted to remove that
line. Rather than risk it, I made the coff-i386 relocs use a special
function; it's coff_i386_reloc in coff-i386.c. The function
@@ -958,13 +953,12 @@ FUNCTION
bfd_install_relocation
SYNOPSIS
- bfd_reloc_status_type
- bfd_install_relocation
- (bfd *abfd,
- arelent *reloc_entry,
- PTR data, bfd_vma data_start,
- asection *input_section,
- char **error_message);
+ bfd_reloc_status_type bfd_install_relocation
+ (bfd *abfd,
+ arelent *reloc_entry,
+ void *data, bfd_vma data_start,
+ asection *input_section,
+ char **error_message);
DESCRIPTION
This looks remarkably like <<bfd_perform_relocation>>, except it
@@ -977,14 +971,12 @@ DESCRIPTION
*/
bfd_reloc_status_type
-bfd_install_relocation (abfd, reloc_entry, data_start, data_start_offset,
- input_section, error_message)
- bfd *abfd;
- arelent *reloc_entry;
- PTR data_start;
- bfd_vma data_start_offset;
- asection *input_section;
- char **error_message;
+bfd_install_relocation (bfd *abfd,
+ arelent *reloc_entry,
+ void *data_start,
+ bfd_vma data_start_offset,
+ asection *input_section,
+ char **error_message)
{
bfd_vma relocation;
bfd_reloc_status_type flag = bfd_reloc_ok;
@@ -1025,7 +1017,7 @@ bfd_install_relocation (abfd, reloc_entry, data_start, data_start_offset,
/ bfd_octets_per_byte (abfd)))
return bfd_reloc_outofrange;
- /* Work out which section the relocation is targetted at and the
+ /* Work out which section the relocation is targeted at and the
initial relocation command value. */
/* Get symbol value. (Common symbols are special.) */
@@ -1063,20 +1055,20 @@ bfd_install_relocation (abfd, reloc_entry, data_start, data_start_offset,
of the location within the section. Some targets arrange for
the addend to be the negative of the position of the location
within the section; for example, i386-aout does this. For
- i386-aout, pcrel_offset is false. Some other targets do not
+ i386-aout, pcrel_offset is FALSE. Some other targets do not
include the position of the location; for example, m88kbcs,
- or ELF. For those targets, pcrel_offset is true.
+ or ELF. For those targets, pcrel_offset is TRUE.
- If we are producing relocateable output, then we must ensure
+ If we are producing relocatable output, then we must ensure
that this reloc will be correctly computed when the final
- relocation is done. If pcrel_offset is false we want to wind
+ relocation is done. If pcrel_offset is FALSE we want to wind
up with the negative of the location within the section,
which means we must adjust the existing addend by the change
- in the location within the section. If pcrel_offset is true
+ in the location within the section. If pcrel_offset is TRUE
we do not want to adjust the existing addend at all.
FIXME: This seems logical to me, but for the case of
- producing relocateable output it is not what the code
+ producing relocatable output it is not what the code
actually does. I don't want to change it, because it seems
far too likely that something will break. */
@@ -1128,7 +1120,7 @@ Hmmm. The first obvious point is that bfd_install_relocation should
not have any tests that depend upon the flavour. It's seem like
entirely the wrong place for such a thing. The second obvious point
is that the current code ignores the reloc addend when producing
-relocateable output for COFF. That's peculiar. In fact, I really
+relocatable output for COFF. That's peculiar. In fact, I really
have no idea what the point of the line you want to remove is.
A typical COFF reloc subtracts the old value of the symbol and adds in
@@ -1143,9 +1135,9 @@ different story (we can't change it without losing backward
compatibility with old object files) (coff-i386 does subtract the old
value, to be compatible with existing coff-i386 targets, like SCO).
-So everything works fine when not producing relocateable output. When
-we are producing relocateable output, logically we should do exactly
-what we do when not producing relocateable output. Therefore, your
+So everything works fine when not producing relocatable output. When
+we are producing relocatable output, logically we should do exactly
+what we do when not producing relocatable output. Therefore, your
patch is correct. In fact, it should probably always just set
reloc_entry->addend to 0 for all cases, since it is, in fact, going to
add the value into the object file. This won't hurt the COFF code,
@@ -1153,7 +1145,7 @@ which doesn't use the addend; I'm not sure what it will do to other
formats (the thing to check for would be whether any formats both use
the addend and set partial_inplace).
-When I wanted to make coff-i386 produce relocateable output, I ran
+When I wanted to make coff-i386 produce relocatable output, I ran
into the problem that you are running into: I wanted to remove that
line. Rather than risk it, I made the coff-i386 relocs use a special
function; it's coff_i386_reloc in coff-i386.c. The function
@@ -1277,32 +1269,32 @@ space consuming. For each target:
{
case 0:
{
- char x = bfd_get_8 (abfd, (char *) data);
+ char x = bfd_get_8 (abfd, data);
DOIT (x);
- bfd_put_8 (abfd, x, (unsigned char *) data);
+ bfd_put_8 (abfd, x, data);
}
break;
case 1:
{
- short x = bfd_get_16 (abfd, (bfd_byte *) data);
+ short x = bfd_get_16 (abfd, data);
DOIT (x);
- bfd_put_16 (abfd, (bfd_vma) x, (unsigned char *) data);
+ bfd_put_16 (abfd, (bfd_vma) x, data);
}
break;
case 2:
{
- long x = bfd_get_32 (abfd, (bfd_byte *) data);
+ long x = bfd_get_32 (abfd, data);
DOIT (x);
- bfd_put_32 (abfd, (bfd_vma) x, (bfd_byte *) data);
+ bfd_put_32 (abfd, (bfd_vma) x, data);
}
break;
case -2:
{
- long x = bfd_get_32 (abfd, (bfd_byte *) data);
+ long x = bfd_get_32 (abfd, data);
relocation = -relocation;
DOIT (x);
- bfd_put_32 (abfd, (bfd_vma) x, (bfd_byte *) data);
+ bfd_put_32 (abfd, (bfd_vma) x, data);
}
break;
@@ -1312,9 +1304,9 @@ space consuming. For each target:
case 4:
{
- bfd_vma x = bfd_get_64 (abfd, (bfd_byte *) data);
+ bfd_vma x = bfd_get_64 (abfd, data);
DOIT (x);
- bfd_put_64 (abfd, x, (bfd_byte *) data);
+ bfd_put_64 (abfd, x, data);
}
break;
default:
@@ -1331,7 +1323,7 @@ space consuming. For each target:
function than to try to deal with it.
This routine does a final relocation. Whether it is useful for a
- relocateable link depends upon how the object format defines
+ relocatable link depends upon how the object format defines
relocations.
FIXME: This routine ignores any special_function in the HOWTO,
@@ -1347,15 +1339,13 @@ space consuming. For each target:
ADDEND is the addend of the reloc. */
bfd_reloc_status_type
-_bfd_final_link_relocate (howto, input_bfd, input_section, contents, address,
- value, addend)
- reloc_howto_type *howto;
- bfd *input_bfd;
- asection *input_section;
- bfd_byte *contents;
- bfd_vma address;
- bfd_vma value;
- bfd_vma addend;
+_bfd_final_link_relocate (reloc_howto_type *howto,
+ bfd *input_bfd,
+ asection *input_section,
+ bfd_byte *contents,
+ bfd_vma address,
+ bfd_vma value,
+ bfd_vma addend)
{
bfd_vma relocation;
@@ -1374,9 +1364,9 @@ _bfd_final_link_relocate (howto, input_bfd, input_section, contents, address,
location we are relocating. Some targets (e.g., i386-aout)
arrange for the contents of the section to be the negative of the
offset of the location within the section; for such targets
- pcrel_offset is false. Other targets (e.g., m88kbcs or ELF)
+ pcrel_offset is FALSE. Other targets (e.g., m88kbcs or ELF)
simply leave the contents of the section as zero; for such
- targets pcrel_offset is true. If pcrel_offset is false we do not
+ targets pcrel_offset is TRUE. If pcrel_offset is FALSE we do not
need to subtract out the offset of the location within the
section (which is just ADDRESS). */
if (howto->pc_relative)
@@ -1394,11 +1384,10 @@ _bfd_final_link_relocate (howto, input_bfd, input_section, contents, address,
/* Relocate a given location using a given value and howto. */
bfd_reloc_status_type
-_bfd_relocate_contents (howto, input_bfd, relocation, location)
- reloc_howto_type *howto;
- bfd *input_bfd;
- bfd_vma relocation;
- bfd_byte *location;
+_bfd_relocate_contents (reloc_howto_type *howto,
+ bfd *input_bfd,
+ bfd_vma relocation,
+ bfd_byte *location)
{
int size;
bfd_vma x = 0;
@@ -1872,6 +1861,56 @@ ENUM
BFD_RELOC_SPARC_REV32
ENUMDOC
SPARC little endian relocation
+ENUM
+ BFD_RELOC_SPARC_TLS_GD_HI22
+ENUMX
+ BFD_RELOC_SPARC_TLS_GD_LO10
+ENUMX
+ BFD_RELOC_SPARC_TLS_GD_ADD
+ENUMX
+ BFD_RELOC_SPARC_TLS_GD_CALL
+ENUMX
+ BFD_RELOC_SPARC_TLS_LDM_HI22
+ENUMX
+ BFD_RELOC_SPARC_TLS_LDM_LO10
+ENUMX
+ BFD_RELOC_SPARC_TLS_LDM_ADD
+ENUMX
+ BFD_RELOC_SPARC_TLS_LDM_CALL
+ENUMX
+ BFD_RELOC_SPARC_TLS_LDO_HIX22
+ENUMX
+ BFD_RELOC_SPARC_TLS_LDO_LOX10
+ENUMX
+ BFD_RELOC_SPARC_TLS_LDO_ADD
+ENUMX
+ BFD_RELOC_SPARC_TLS_IE_HI22
+ENUMX
+ BFD_RELOC_SPARC_TLS_IE_LO10
+ENUMX
+ BFD_RELOC_SPARC_TLS_IE_LD
+ENUMX
+ BFD_RELOC_SPARC_TLS_IE_LDX
+ENUMX
+ BFD_RELOC_SPARC_TLS_IE_ADD
+ENUMX
+ BFD_RELOC_SPARC_TLS_LE_HIX22
+ENUMX
+ BFD_RELOC_SPARC_TLS_LE_LOX10
+ENUMX
+ BFD_RELOC_SPARC_TLS_DTPMOD32
+ENUMX
+ BFD_RELOC_SPARC_TLS_DTPMOD64
+ENUMX
+ BFD_RELOC_SPARC_TLS_DTPOFF32
+ENUMX
+ BFD_RELOC_SPARC_TLS_DTPOFF64
+ENUMX
+ BFD_RELOC_SPARC_TLS_TPOFF32
+ENUMX
+ BFD_RELOC_SPARC_TLS_TPOFF64
+ENUMDOC
+ SPARC TLS relocations
ENUM
BFD_RELOC_ALPHA_GPDISP_HI16
@@ -1959,7 +1998,7 @@ ENUM
BFD_RELOC_ALPHA_BRSGP
ENUMDOC
Like BFD_RELOC_23_PCREL_S2, except that the source and target must
- share a common GP, and the target address is adjusted for
+ share a common GP, and the target address is adjusted for
STO_ALPHA_STD_GPLOAD.
ENUM
@@ -2078,7 +2117,10 @@ ENUMX
BFD_RELOC_MIPS_RELGOT
ENUMX
BFD_RELOC_MIPS_JALR
+ENUMDOC
+ MIPS ELF relocations.
COMMENT
+
ENUM
BFD_RELOC_FRV_LABEL16
ENUMX
@@ -2097,13 +2139,73 @@ ENUMX
BFD_RELOC_FRV_GPRELHI
ENUMX
BFD_RELOC_FRV_GPRELLO
+ENUMX
+ BFD_RELOC_FRV_GOT12
+ENUMX
+ BFD_RELOC_FRV_GOTHI
+ENUMX
+ BFD_RELOC_FRV_GOTLO
+ENUMX
+ BFD_RELOC_FRV_FUNCDESC
+ENUMX
+ BFD_RELOC_FRV_FUNCDESC_GOT12
+ENUMX
+ BFD_RELOC_FRV_FUNCDESC_GOTHI
+ENUMX
+ BFD_RELOC_FRV_FUNCDESC_GOTLO
+ENUMX
+ BFD_RELOC_FRV_FUNCDESC_VALUE
+ENUMX
+ BFD_RELOC_FRV_FUNCDESC_GOTOFF12
+ENUMX
+ BFD_RELOC_FRV_FUNCDESC_GOTOFFHI
+ENUMX
+ BFD_RELOC_FRV_FUNCDESC_GOTOFFLO
+ENUMX
+ BFD_RELOC_FRV_GOTOFF12
+ENUMX
+ BFD_RELOC_FRV_GOTOFFHI
+ENUMX
+ BFD_RELOC_FRV_GOTOFFLO
ENUMDOC
Fujitsu Frv Relocations.
COMMENT
-COMMENT
-ENUMDOC
- MIPS ELF relocations.
+ENUM
+ BFD_RELOC_MN10300_GOTOFF24
+ENUMDOC
+ This is a 24bit GOT-relative reloc for the mn10300.
+ENUM
+ BFD_RELOC_MN10300_GOT32
+ENUMDOC
+ This is a 32bit GOT-relative reloc for the mn10300, offset by two bytes
+ in the instruction.
+ENUM
+ BFD_RELOC_MN10300_GOT24
+ENUMDOC
+ This is a 24bit GOT-relative reloc for the mn10300, offset by two bytes
+ in the instruction.
+ENUM
+ BFD_RELOC_MN10300_GOT16
+ENUMDOC
+ This is a 16bit GOT-relative reloc for the mn10300, offset by two bytes
+ in the instruction.
+ENUM
+ BFD_RELOC_MN10300_COPY
+ENUMDOC
+ Copy symbol at runtime.
+ENUM
+ BFD_RELOC_MN10300_GLOB_DAT
+ENUMDOC
+ Create GOT entry.
+ENUM
+ BFD_RELOC_MN10300_JMP_SLOT
+ENUMDOC
+ Create PLT entry.
+ENUM
+ BFD_RELOC_MN10300_RELATIVE
+ENUMDOC
+ Adjust by program base.
COMMENT
ENUM
@@ -2165,6 +2267,22 @@ ENUMX
BFD_RELOC_X86_64_GOTPCREL
ENUMX
BFD_RELOC_X86_64_32S
+ENUMX
+ BFD_RELOC_X86_64_DTPMOD64
+ENUMX
+ BFD_RELOC_X86_64_DTPOFF64
+ENUMX
+ BFD_RELOC_X86_64_TPOFF64
+ENUMX
+ BFD_RELOC_X86_64_TLSGD
+ENUMX
+ BFD_RELOC_X86_64_TLSLD
+ENUMX
+ BFD_RELOC_X86_64_DTPOFF32
+ENUMX
+ BFD_RELOC_X86_64_GOTTPOFF
+ENUMX
+ BFD_RELOC_X86_64_TPOFF32
ENUMDOC
x86-64/elf relocations
@@ -2327,6 +2445,89 @@ ENUMDOC
Power(rs6000) and PowerPC relocations.
ENUM
+ BFD_RELOC_PPC_TLS
+ENUMX
+ BFD_RELOC_PPC_DTPMOD
+ENUMX
+ BFD_RELOC_PPC_TPREL16
+ENUMX
+ BFD_RELOC_PPC_TPREL16_LO
+ENUMX
+ BFD_RELOC_PPC_TPREL16_HI
+ENUMX
+ BFD_RELOC_PPC_TPREL16_HA
+ENUMX
+ BFD_RELOC_PPC_TPREL
+ENUMX
+ BFD_RELOC_PPC_DTPREL16
+ENUMX
+ BFD_RELOC_PPC_DTPREL16_LO
+ENUMX
+ BFD_RELOC_PPC_DTPREL16_HI
+ENUMX
+ BFD_RELOC_PPC_DTPREL16_HA
+ENUMX
+ BFD_RELOC_PPC_DTPREL
+ENUMX
+ BFD_RELOC_PPC_GOT_TLSGD16
+ENUMX
+ BFD_RELOC_PPC_GOT_TLSGD16_LO
+ENUMX
+ BFD_RELOC_PPC_GOT_TLSGD16_HI
+ENUMX
+ BFD_RELOC_PPC_GOT_TLSGD16_HA
+ENUMX
+ BFD_RELOC_PPC_GOT_TLSLD16
+ENUMX
+ BFD_RELOC_PPC_GOT_TLSLD16_LO
+ENUMX
+ BFD_RELOC_PPC_GOT_TLSLD16_HI
+ENUMX
+ BFD_RELOC_PPC_GOT_TLSLD16_HA
+ENUMX
+ BFD_RELOC_PPC_GOT_TPREL16
+ENUMX
+ BFD_RELOC_PPC_GOT_TPREL16_LO
+ENUMX
+ BFD_RELOC_PPC_GOT_TPREL16_HI
+ENUMX
+ BFD_RELOC_PPC_GOT_TPREL16_HA
+ENUMX
+ BFD_RELOC_PPC_GOT_DTPREL16
+ENUMX
+ BFD_RELOC_PPC_GOT_DTPREL16_LO
+ENUMX
+ BFD_RELOC_PPC_GOT_DTPREL16_HI
+ENUMX
+ BFD_RELOC_PPC_GOT_DTPREL16_HA
+ENUMX
+ BFD_RELOC_PPC64_TPREL16_DS
+ENUMX
+ BFD_RELOC_PPC64_TPREL16_LO_DS
+ENUMX
+ BFD_RELOC_PPC64_TPREL16_HIGHER
+ENUMX
+ BFD_RELOC_PPC64_TPREL16_HIGHERA
+ENUMX
+ BFD_RELOC_PPC64_TPREL16_HIGHEST
+ENUMX
+ BFD_RELOC_PPC64_TPREL16_HIGHESTA
+ENUMX
+ BFD_RELOC_PPC64_DTPREL16_DS
+ENUMX
+ BFD_RELOC_PPC64_DTPREL16_LO_DS
+ENUMX
+ BFD_RELOC_PPC64_DTPREL16_HIGHER
+ENUMX
+ BFD_RELOC_PPC64_DTPREL16_HIGHERA
+ENUMX
+ BFD_RELOC_PPC64_DTPREL16_HIGHEST
+ENUMX
+ BFD_RELOC_PPC64_DTPREL16_HIGHESTA
+ENUMDOC
+ PowerPC and PowerPC64 thread-local storage relocations.
+
+ENUM
BFD_RELOC_I370_D12
ENUMDOC
IBM 370/390 relocations
@@ -2334,7 +2535,7 @@ ENUMDOC
ENUM
BFD_RELOC_CTOR
ENUMDOC
- The type of reloc used to build a contructor table - at the moment
+ The type of reloc used to build a constructor table - at the moment
probably a 32 bit wide absolute relocation, but the target can choose.
It generally does map to one of the other relocation types.
@@ -2370,6 +2571,8 @@ ENUMX
ENUMX
BFD_RELOC_ARM_CP_OFF_IMM
ENUMX
+ BFD_RELOC_ARM_CP_OFF_IMM_S2
+ENUMX
BFD_RELOC_ARM_ADR_IMM
ENUMX
BFD_RELOC_ARM_LDR_IMM
@@ -2559,8 +2762,24 @@ ENUMX
BFD_RELOC_SH_IMM_HI16_PCREL
ENUMX
BFD_RELOC_SH_PT_16
+ENUMX
+ BFD_RELOC_SH_TLS_GD_32
+ENUMX
+ BFD_RELOC_SH_TLS_LD_32
+ENUMX
+ BFD_RELOC_SH_TLS_LDO_32
+ENUMX
+ BFD_RELOC_SH_TLS_IE_32
+ENUMX
+ BFD_RELOC_SH_TLS_LE_32
+ENUMX
+ BFD_RELOC_SH_TLS_DTPMOD32
+ENUMX
+ BFD_RELOC_SH_TLS_DTPOFF32
+ENUMX
+ BFD_RELOC_SH_TLS_TPOFF32
ENUMDOC
- Hitachi SH relocs. Not all of these appear in object files.
+ Renesas / SuperH SH relocs. Not all of these appear in object files.
ENUM
BFD_RELOC_THUMB_PCREL_BRANCH9
@@ -2687,7 +2906,7 @@ ENUMDOC
ENUM
BFD_RELOC_M32R_24
ENUMDOC
- Mitsubishi M32R relocs.
+ Renesas M32R (formerly Mitsubishi M32R) relocs.
This is a 24 bit absolute address.
ENUM
BFD_RELOC_M32R_10_PCREL
@@ -2720,6 +2939,37 @@ ENUM
ENUMDOC
This is a 16-bit reloc containing the small data area offset for use in
add3, load, and store instructions.
+ENUM
+ BFD_RELOC_M32R_GOT24
+ENUMX
+ BFD_RELOC_M32R_26_PLTREL
+ENUMX
+ BFD_RELOC_M32R_COPY
+ENUMX
+ BFD_RELOC_M32R_GLOB_DAT
+ENUMX
+ BFD_RELOC_M32R_JMP_SLOT
+ENUMX
+ BFD_RELOC_M32R_RELATIVE
+ENUMX
+ BFD_RELOC_M32R_GOTOFF
+ENUMX
+ BFD_RELOC_M32R_GOTPC24
+ENUMX
+ BFD_RELOC_M32R_GOT16_HI_ULO
+ENUMX
+ BFD_RELOC_M32R_GOT16_HI_SLO
+ENUMX
+ BFD_RELOC_M32R_GOT16_LO
+ENUMX
+ BFD_RELOC_M32R_GOTPC_HI_ULO
+ENUMX
+ BFD_RELOC_M32R_GOTPC_HI_SLO
+ENUMX
+ BFD_RELOC_M32R_GOTPC_LO
+ENUMDOC
+ For PIC.
+
ENUM
BFD_RELOC_V850_9_PCREL
@@ -2780,12 +3030,12 @@ ENUM
BFD_RELOC_V850_SDA_16_16_SPLIT_OFFSET
ENUMDOC
This is a 16 bit offset from the short data area pointer, with the
- bits placed non-contigously in the instruction.
+ bits placed non-contiguously in the instruction.
ENUM
BFD_RELOC_V850_ZDA_16_16_SPLIT_OFFSET
ENUMDOC
This is a 16 bit offset from the zero data area pointer, with the
- bits placed non-contigously in the instruction.
+ bits placed non-contiguously in the instruction.
ENUM
BFD_RELOC_V850_CALLT_6_7_OFFSET
ENUMDOC
@@ -2794,8 +3044,18 @@ ENUM
BFD_RELOC_V850_CALLT_16_16_OFFSET
ENUMDOC
This is a 16 bit offset from the call table base pointer.
-COMMENT
-
+ENUM
+ BFD_RELOC_V850_LONGCALL
+ENUMDOC
+ Used for relaxing indirect function calls.
+ENUM
+ BFD_RELOC_V850_LONGJUMP
+ENUMDOC
+ Used for relaxing indirect jumps.
+ENUM
+ BFD_RELOC_V850_ALIGN
+ENUMDOC
+ Used to maintain alignment whilst relaxing.
ENUM
BFD_RELOC_MN10300_32_PCREL
ENUMDOC
@@ -2932,6 +3192,8 @@ ENUMX
BFD_RELOC_MMIX_PUSHJ_2
ENUMX
BFD_RELOC_MMIX_PUSHJ_3
+ENUMX
+ BFD_RELOC_MMIX_PUSHJ_STUBBABLE
ENUMDOC
These are relocations for the PUSHJ instruction.
ENUM
@@ -3127,6 +3389,145 @@ ENUM
BFD_RELOC_390_GOTENT
ENUMDOC
32 bit rel. offset to GOT entry.
+ENUM
+ BFD_RELOC_390_GOTOFF64
+ENUMDOC
+ 64 bit offset to GOT.
+ENUM
+ BFD_RELOC_390_GOTPLT12
+ENUMDOC
+ 12-bit offset to symbol-entry within GOT, with PLT handling.
+ENUM
+ BFD_RELOC_390_GOTPLT16
+ENUMDOC
+ 16-bit offset to symbol-entry within GOT, with PLT handling.
+ENUM
+ BFD_RELOC_390_GOTPLT32
+ENUMDOC
+ 32-bit offset to symbol-entry within GOT, with PLT handling.
+ENUM
+ BFD_RELOC_390_GOTPLT64
+ENUMDOC
+ 64-bit offset to symbol-entry within GOT, with PLT handling.
+ENUM
+ BFD_RELOC_390_GOTPLTENT
+ENUMDOC
+ 32-bit rel. offset to symbol-entry within GOT, with PLT handling.
+ENUM
+ BFD_RELOC_390_PLTOFF16
+ENUMDOC
+ 16-bit rel. offset from the GOT to a PLT entry.
+ENUM
+ BFD_RELOC_390_PLTOFF32
+ENUMDOC
+ 32-bit rel. offset from the GOT to a PLT entry.
+ENUM
+ BFD_RELOC_390_PLTOFF64
+ENUMDOC
+ 64-bit rel. offset from the GOT to a PLT entry.
+
+ENUM
+ BFD_RELOC_390_TLS_LOAD
+ENUMX
+ BFD_RELOC_390_TLS_GDCALL
+ENUMX
+ BFD_RELOC_390_TLS_LDCALL
+ENUMX
+ BFD_RELOC_390_TLS_GD32
+ENUMX
+ BFD_RELOC_390_TLS_GD64
+ENUMX
+ BFD_RELOC_390_TLS_GOTIE12
+ENUMX
+ BFD_RELOC_390_TLS_GOTIE32
+ENUMX
+ BFD_RELOC_390_TLS_GOTIE64
+ENUMX
+ BFD_RELOC_390_TLS_LDM32
+ENUMX
+ BFD_RELOC_390_TLS_LDM64
+ENUMX
+ BFD_RELOC_390_TLS_IE32
+ENUMX
+ BFD_RELOC_390_TLS_IE64
+ENUMX
+ BFD_RELOC_390_TLS_IEENT
+ENUMX
+ BFD_RELOC_390_TLS_LE32
+ENUMX
+ BFD_RELOC_390_TLS_LE64
+ENUMX
+ BFD_RELOC_390_TLS_LDO32
+ENUMX
+ BFD_RELOC_390_TLS_LDO64
+ENUMX
+ BFD_RELOC_390_TLS_DTPMOD
+ENUMX
+ BFD_RELOC_390_TLS_DTPOFF
+ENUMX
+ BFD_RELOC_390_TLS_TPOFF
+ENUMDOC
+ s390 tls relocations.
+
+ENUM
+ BFD_RELOC_390_20
+ENUMX
+ BFD_RELOC_390_GOT20
+ENUMX
+ BFD_RELOC_390_GOTPLT20
+ENUMX
+ BFD_RELOC_390_TLS_GOTIE20
+ENUMDOC
+ Long displacement extension.
+
+ENUM
+ BFD_RELOC_IP2K_FR9
+ENUMDOC
+ Scenix IP2K - 9-bit register number / data address
+ENUM
+ BFD_RELOC_IP2K_BANK
+ENUMDOC
+ Scenix IP2K - 4-bit register/data bank number
+ENUM
+ BFD_RELOC_IP2K_ADDR16CJP
+ENUMDOC
+ Scenix IP2K - low 13 bits of instruction word address
+ENUM
+ BFD_RELOC_IP2K_PAGE3
+ENUMDOC
+ Scenix IP2K - high 3 bits of instruction word address
+ENUM
+ BFD_RELOC_IP2K_LO8DATA
+ENUMX
+ BFD_RELOC_IP2K_HI8DATA
+ENUMX
+ BFD_RELOC_IP2K_EX8DATA
+ENUMDOC
+ Scenix IP2K - ext/low/high 8 bits of data address
+ENUM
+ BFD_RELOC_IP2K_LO8INSN
+ENUMX
+ BFD_RELOC_IP2K_HI8INSN
+ENUMDOC
+ Scenix IP2K - low/high 8 bits of instruction word address
+ENUM
+ BFD_RELOC_IP2K_PC_SKIP
+ENUMDOC
+ Scenix IP2K - even/odd PC modifier to modify snb pcl.0
+ENUM
+ BFD_RELOC_IP2K_TEXT
+ENUMDOC
+ Scenix IP2K - 16 bit word address in text section.
+ENUM
+ BFD_RELOC_IP2K_FR_OFFSET
+ENUMDOC
+ Scenix IP2K - 7-bit sp or dp offset
+ENUM
+ BFD_RELOC_VPE4KMATH_DATA
+ENUMX
+ BFD_RELOC_VPE4KMATH_INSN
+ENUMDOC
+ Scenix VPE4K coprocessor - data/insn-space addressing
ENUM
BFD_RELOC_VTABLE_INHERIT
@@ -3140,7 +3541,7 @@ ENUMDOC
included in the output.
VTABLE_INHERIT is a zero-space relocation used to describe to the
- linker the inheritence tree of a C++ virtual function table. The
+ linker the inheritance tree of a C++ virtual function table. The
relocation's symbol should be the parent class' vtable, and the
relocation should be located at the child vtable.
@@ -3316,17 +3717,58 @@ ENUM
BFD_RELOC_M68HC11_HI8
ENUMDOC
Motorola 68HC11 reloc.
- This is the 8 bits high part of an absolute address.
+ This is the 8 bit high part of an absolute address.
ENUM
BFD_RELOC_M68HC11_LO8
ENUMDOC
Motorola 68HC11 reloc.
- This is the 8 bits low part of an absolute address.
+ This is the 8 bit low part of an absolute address.
ENUM
BFD_RELOC_M68HC11_3B
ENUMDOC
Motorola 68HC11 reloc.
- This is the 3 bits of a value.
+ This is the 3 bit of a value.
+ENUM
+ BFD_RELOC_M68HC11_RL_JUMP
+ENUMDOC
+ Motorola 68HC11 reloc.
+ This reloc marks the beginning of a jump/call instruction.
+ It is used for linker relaxation to correctly identify beginning
+ of instruction and change some branches to use PC-relative
+ addressing mode.
+ENUM
+ BFD_RELOC_M68HC11_RL_GROUP
+ENUMDOC
+ Motorola 68HC11 reloc.
+ This reloc marks a group of several instructions that gcc generates
+ and for which the linker relaxation pass can modify and/or remove
+ some of them.
+ENUM
+ BFD_RELOC_M68HC11_LO16
+ENUMDOC
+ Motorola 68HC11 reloc.
+ This is the 16-bit lower part of an address. It is used for 'call'
+ instruction to specify the symbol address without any special
+ transformation (due to memory bank window).
+ENUM
+ BFD_RELOC_M68HC11_PAGE
+ENUMDOC
+ Motorola 68HC11 reloc.
+ This is a 8-bit reloc that specifies the page number of an address.
+ It is used by 'call' instruction to specify the page number of
+ the symbol.
+ENUM
+ BFD_RELOC_M68HC11_24
+ENUMDOC
+ Motorola 68HC11 reloc.
+ This is a 24-bit reloc that represents the address with a 16-bit
+ value and a 8-bit page number. The symbol address is transformed
+ to follow the 16K memory bank of 68HC12 (seen as mapped in the window).
+ENUM
+ BFD_RELOC_M68HC12_5B
+ENUMDOC
+ Motorola 68HC12 reloc.
+ This is the 5 bits of a value.
ENUM
BFD_RELOC_CRIS_BDISP8
@@ -3470,6 +3912,8 @@ ENUMDOC
ENUM
BFD_RELOC_XSTORMY16_REL_12
ENUMX
+ BFD_RELOC_XSTORMY16_12
+ENUMX
BFD_RELOC_XSTORMY16_24
ENUMX
BFD_RELOC_XSTORMY16_FPTR16
@@ -3484,6 +3928,71 @@ ENUMX
BFD_RELOC_VAX_RELATIVE
ENUMDOC
Relocations used by VAX ELF.
+
+ENUM
+ BFD_RELOC_MSP430_10_PCREL
+ENUMX
+ BFD_RELOC_MSP430_16_PCREL
+ENUMX
+ BFD_RELOC_MSP430_16
+ENUMX
+ BFD_RELOC_MSP430_16_PCREL_BYTE
+ENUMX
+ BFD_RELOC_MSP430_16_BYTE
+ENUMDOC
+ msp430 specific relocation codes
+
+ENUM
+ BFD_RELOC_IQ2000_OFFSET_16
+ENUMX
+ BFD_RELOC_IQ2000_OFFSET_21
+ENUMX
+ BFD_RELOC_IQ2000_UHI16
+ENUMDOC
+ IQ2000 Relocations.
+
+ENUM
+ BFD_RELOC_XTENSA_RTLD
+ENUMDOC
+ Special Xtensa relocation used only by PLT entries in ELF shared
+ objects to indicate that the runtime linker should set the value
+ to one of its own internal functions or data structures.
+ENUM
+ BFD_RELOC_XTENSA_GLOB_DAT
+ENUMX
+ BFD_RELOC_XTENSA_JMP_SLOT
+ENUMX
+ BFD_RELOC_XTENSA_RELATIVE
+ENUMDOC
+ Xtensa relocations for ELF shared objects.
+ENUM
+ BFD_RELOC_XTENSA_PLT
+ENUMDOC
+ Xtensa relocation used in ELF object files for symbols that may require
+ PLT entries. Otherwise, this is just a generic 32-bit relocation.
+ENUM
+ BFD_RELOC_XTENSA_OP0
+ENUMX
+ BFD_RELOC_XTENSA_OP1
+ENUMX
+ BFD_RELOC_XTENSA_OP2
+ENUMDOC
+ Generic Xtensa relocations. Only the operand number is encoded
+ in the relocation. The details are determined by extracting the
+ instruction opcode.
+ENUM
+ BFD_RELOC_XTENSA_ASM_EXPAND
+ENUMDOC
+ Xtensa relocation to mark that the assembler expanded the
+ instructions from an original target. The expansion size is
+ encoded in the reloc size.
+ENUM
+ BFD_RELOC_XTENSA_ASM_SIMPLIFY
+ENUMDOC
+ Xtensa relocation to mark that the linker should simplify
+ assembler-expanded instructions. This is commonly used
+ internally by the linker after analysis of a
+ BFD_RELOC_XTENSA_ASM_EXPAND.
ENDSENUM
BFD_RELOC_UNUSED
@@ -3497,8 +4006,8 @@ FUNCTION
bfd_reloc_type_lookup
SYNOPSIS
- reloc_howto_type *
- bfd_reloc_type_lookup (bfd *abfd, bfd_reloc_code_real_type code);
+ reloc_howto_type *bfd_reloc_type_lookup
+ (bfd *abfd, bfd_reloc_code_real_type code);
DESCRIPTION
Return a pointer to a howto structure which, when
@@ -3508,15 +4017,13 @@ DESCRIPTION
*/
reloc_howto_type *
-bfd_reloc_type_lookup (abfd, code)
- bfd *abfd;
- bfd_reloc_code_real_type code;
+bfd_reloc_type_lookup (bfd *abfd, bfd_reloc_code_real_type code)
{
return BFD_SEND (abfd, reloc_type_lookup, (abfd, code));
}
static reloc_howto_type bfd_howto_32 =
-HOWTO (0, 00, 2, 32, false, 0, complain_overflow_bitfield, 0, "VRT32", false, 0xffffffff, 0xffffffff, true);
+HOWTO (0, 00, 2, 32, FALSE, 0, complain_overflow_bitfield, 0, "VRT32", FALSE, 0xffffffff, 0xffffffff, TRUE);
/*
INTERNAL_FUNCTION
@@ -3524,7 +4031,7 @@ INTERNAL_FUNCTION
SYNOPSIS
reloc_howto_type *bfd_default_reloc_type_lookup
- (bfd *abfd, bfd_reloc_code_real_type code);
+ (bfd *abfd, bfd_reloc_code_real_type code);
DESCRIPTION
Provides a default relocation lookup routine for any architecture.
@@ -3532,9 +4039,7 @@ DESCRIPTION
*/
reloc_howto_type *
-bfd_default_reloc_type_lookup (abfd, code)
- bfd *abfd;
- bfd_reloc_code_real_type code;
+bfd_default_reloc_type_lookup (bfd *abfd, bfd_reloc_code_real_type code)
{
switch (code)
{
@@ -3555,7 +4060,7 @@ bfd_default_reloc_type_lookup (abfd, code)
default:
BFD_FAIL ();
}
- return (reloc_howto_type *) NULL;
+ return NULL;
}
/*
@@ -3571,12 +4076,11 @@ DESCRIPTION
*/
const char *
-bfd_get_reloc_code_name (code)
- bfd_reloc_code_real_type code;
+bfd_get_reloc_code_name (bfd_reloc_code_real_type code)
{
- if ((int) code > (int) BFD_RELOC_UNUSED)
+ if (code > BFD_RELOC_UNUSED)
return 0;
- return bfd_reloc_code_real_names[(int)code];
+ return bfd_reloc_code_real_names[code];
}
/*
@@ -3584,26 +4088,31 @@ INTERNAL_FUNCTION
bfd_generic_relax_section
SYNOPSIS
- boolean bfd_generic_relax_section
- (bfd *abfd,
- asection *section,
- struct bfd_link_info *,
- boolean *);
+ bfd_boolean bfd_generic_relax_section
+ (bfd *abfd,
+ asection *section,
+ struct bfd_link_info *,
+ bfd_boolean *);
DESCRIPTION
Provides default handling for relaxing for back ends which
- don't do relaxing -- i.e., does nothing.
+ don't do relaxing -- i.e., does nothing except make sure that the
+ final size of the section is set.
*/
-boolean
-bfd_generic_relax_section (abfd, section, link_info, again)
- bfd *abfd ATTRIBUTE_UNUSED;
- asection *section ATTRIBUTE_UNUSED;
- struct bfd_link_info *link_info ATTRIBUTE_UNUSED;
- boolean *again;
+bfd_boolean
+bfd_generic_relax_section (bfd *abfd ATTRIBUTE_UNUSED,
+ asection *section ATTRIBUTE_UNUSED,
+ struct bfd_link_info *link_info ATTRIBUTE_UNUSED,
+ bfd_boolean *again)
{
- *again = false;
- return true;
+ /* We're not relaxing the section, so just copy the size info if it's
+ zero. Someone else, like bfd_merge_sections, might have set it, so
+ don't overwrite a non-zero value. */
+ if (section->_cooked_size == 0)
+ section->_cooked_size = section->_raw_size;
+ *again = FALSE;
+ return TRUE;
}
/*
@@ -3611,20 +4120,19 @@ INTERNAL_FUNCTION
bfd_generic_gc_sections
SYNOPSIS
- boolean bfd_generic_gc_sections
- (bfd *, struct bfd_link_info *);
+ bfd_boolean bfd_generic_gc_sections
+ (bfd *, struct bfd_link_info *);
DESCRIPTION
Provides default handling for relaxing for back ends which
don't do section gc -- i.e., does nothing.
*/
-boolean
-bfd_generic_gc_sections (abfd, link_info)
- bfd *abfd ATTRIBUTE_UNUSED;
- struct bfd_link_info *link_info ATTRIBUTE_UNUSED;
+bfd_boolean
+bfd_generic_gc_sections (bfd *abfd ATTRIBUTE_UNUSED,
+ struct bfd_link_info *link_info ATTRIBUTE_UNUSED)
{
- return true;
+ return TRUE;
}
/*
@@ -3632,20 +4140,19 @@ INTERNAL_FUNCTION
bfd_generic_merge_sections
SYNOPSIS
- boolean bfd_generic_merge_sections
- (bfd *, struct bfd_link_info *);
+ bfd_boolean bfd_generic_merge_sections
+ (bfd *, struct bfd_link_info *);
DESCRIPTION
Provides default handling for SEC_MERGE section merging for back ends
which don't have SEC_MERGE support -- i.e., does nothing.
*/
-boolean
-bfd_generic_merge_sections (abfd, link_info)
- bfd *abfd ATTRIBUTE_UNUSED;
- struct bfd_link_info *link_info ATTRIBUTE_UNUSED;
+bfd_boolean
+bfd_generic_merge_sections (bfd *abfd ATTRIBUTE_UNUSED,
+ struct bfd_link_info *link_info ATTRIBUTE_UNUSED)
{
- return true;
+ return TRUE;
}
/*
@@ -3653,13 +4160,13 @@ INTERNAL_FUNCTION
bfd_generic_get_relocated_section_contents
SYNOPSIS
- bfd_byte *
- bfd_generic_get_relocated_section_contents (bfd *abfd,
- struct bfd_link_info *link_info,
- struct bfd_link_order *link_order,
- bfd_byte *data,
- boolean relocateable,
- asymbol **symbols);
+ bfd_byte *bfd_generic_get_relocated_section_contents
+ (bfd *abfd,
+ struct bfd_link_info *link_info,
+ struct bfd_link_order *link_order,
+ bfd_byte *data,
+ bfd_boolean relocatable,
+ asymbol **symbols);
DESCRIPTION
Provides default handling of relocation effort for back ends
@@ -3668,14 +4175,12 @@ DESCRIPTION
*/
bfd_byte *
-bfd_generic_get_relocated_section_contents (abfd, link_info, link_order, data,
- relocateable, symbols)
- bfd *abfd;
- struct bfd_link_info *link_info;
- struct bfd_link_order *link_order;
- bfd_byte *data;
- boolean relocateable;
- asymbol **symbols;
+bfd_generic_get_relocated_section_contents (bfd *abfd,
+ struct bfd_link_info *link_info,
+ struct bfd_link_order *link_order,
+ bfd_byte *data,
+ bfd_boolean relocatable,
+ asymbol **symbols)
{
/* Get enough memory to hold the stuff. */
bfd *input_bfd = link_order->u.indirect.section->owner;
@@ -3688,21 +4193,26 @@ bfd_generic_get_relocated_section_contents (abfd, link_info, link_order, data,
if (reloc_size < 0)
goto error_return;
- reloc_vector = (arelent **) bfd_malloc ((bfd_size_type) reloc_size);
+ reloc_vector = bfd_malloc (reloc_size);
if (reloc_vector == NULL && reloc_size != 0)
goto error_return;
/* Read in the section. */
if (!bfd_get_section_contents (input_bfd,
input_section,
- (PTR) data,
- (bfd_vma) 0,
+ data,
+ 0,
input_section->_raw_size))
goto error_return;
- /* We're not relaxing the section, so just copy the size info. */
- input_section->_cooked_size = input_section->_raw_size;
- input_section->reloc_done = (unsigned int) true;
+ /* Don't set input_section->_cooked_size here. The caller has set
+ _cooked_size or called bfd_relax_section, which sets _cooked_size.
+ Despite using this generic relocation function, some targets perform
+ target-specific relaxation or string merging, which happens before
+ this function is called. We do not want to clobber the _cooked_size
+ they computed. */
+
+ input_section->reloc_done = TRUE;
reloc_count = bfd_canonicalize_reloc (input_bfd,
input_section,
@@ -3714,19 +4224,18 @@ bfd_generic_get_relocated_section_contents (abfd, link_info, link_order, data,
if (reloc_count > 0)
{
arelent **parent;
- for (parent = reloc_vector; *parent != (arelent *) NULL;
- parent++)
+ for (parent = reloc_vector; *parent != NULL; parent++)
{
- char *error_message = (char *) NULL;
+ char *error_message = NULL;
bfd_reloc_status_type r =
bfd_perform_relocation (input_bfd,
*parent,
- (PTR) data,
+ data,
input_section,
- relocateable ? abfd : (bfd *) NULL,
+ relocatable ? abfd : NULL,
&error_message);
- if (relocateable)
+ if (relocatable)
{
asection *os = input_section->output_section;
@@ -3743,11 +4252,11 @@ bfd_generic_get_relocated_section_contents (abfd, link_info, link_order, data,
if (!((*link_info->callbacks->undefined_symbol)
(link_info, bfd_asymbol_name (*(*parent)->sym_ptr_ptr),
input_bfd, input_section, (*parent)->address,
- true)))
+ TRUE)))
goto error_return;
break;
case bfd_reloc_dangerous:
- BFD_ASSERT (error_message != (char *) NULL);
+ BFD_ASSERT (error_message != NULL);
if (!((*link_info->callbacks->reloc_dangerous)
(link_info, error_message, input_bfd, input_section,
(*parent)->address)))
diff --git a/contrib/binutils/bfd/reloc16.c b/contrib/binutils/bfd/reloc16.c
index 1db8daf..720e2d6 100644
--- a/contrib/binutils/bfd/reloc16.c
+++ b/contrib/binutils/bfd/reloc16.c
@@ -1,6 +1,6 @@
/* 8 and 16 bit COFF relocation functions, for BFD.
- Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1998, 2000, 2001
- Free Software Foundation, Inc.
+ Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1998, 2000, 2001,
+ 2002, 2003 Free Software Foundation, Inc.
Written by Cygnus Support.
This file is part of BFD, the Binary File Descriptor library.
@@ -29,7 +29,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
BFD generic relocs. They should store the relocs in some location
where coff_link_input_bfd can find them (and coff_link_input_bfd
should be changed to use this location rather than rereading the
- file) (unless info->keep_memory is false, in which case they should
+ file) (unless info->keep_memory is FALSE, in which case they should
free up the relocs after dealing with them). */
#include "bfd.h"
@@ -64,7 +64,7 @@ bfd_coff_reloc16_get_value (reloc, link_info, input_section)
the generic symbols. */
h = bfd_wrapped_link_hash_lookup (input_section->owner, link_info,
bfd_asymbol_name (symbol),
- false, false, true);
+ FALSE, FALSE, TRUE);
if (h != (struct bfd_link_hash_entry *) NULL
&& (h->type == bfd_link_hash_defined
|| h->type == bfd_link_hash_defweak))
@@ -79,7 +79,7 @@ bfd_coff_reloc16_get_value (reloc, link_info, input_section)
if (!((*link_info->callbacks->undefined_symbol)
(link_info, bfd_asymbol_name (symbol),
input_section->owner, input_section, reloc->address,
- true)))
+ TRUE)))
abort ();
value = 0;
}
@@ -136,12 +136,12 @@ bfd_perform_slip (abfd, slip, input_section, value)
}
}
-boolean
+bfd_boolean
bfd_coff_reloc16_relax_section (abfd, input_section, link_info, again)
bfd *abfd;
asection *input_section;
struct bfd_link_info *link_info;
- boolean *again;
+ bfd_boolean *again;
{
/* Get enough memory to hold the stuff. */
bfd *input_bfd = input_section->owner;
@@ -153,14 +153,14 @@ bfd_coff_reloc16_relax_section (abfd, input_section, link_info, again)
/* We only do global relaxation once. It is not safe to do it multiple
times (see discussion of the "shrinks" array below). */
- *again = false;
+ *again = FALSE;
if (reloc_size < 0)
- return false;
+ return FALSE;
reloc_vector = (arelent **) bfd_malloc ((bfd_size_type) reloc_size);
if (!reloc_vector && reloc_size > 0)
- return false;
+ return FALSE;
/* Get the relocs and think about them. */
reloc_count =
@@ -169,7 +169,7 @@ bfd_coff_reloc16_relax_section (abfd, input_section, link_info, again)
if (reloc_count < 0)
{
free (reloc_vector);
- return false;
+ return FALSE;
}
/* The reloc16.c and related relaxing code is very simple, the price
@@ -193,36 +193,37 @@ bfd_coff_reloc16_relax_section (abfd, input_section, link_info, again)
bfd_size_type amt;
/* Allocate and initialize the shrinks array for this section.
- The last element is used as an accumlator of shrinks. */
+ The last element is used as an accumulator of shrinks. */
amt = reloc_count + 1;
amt *= sizeof (unsigned);
shrinks = (unsigned *) bfd_zmalloc (amt);
/* Loop until nothing changes in this section. */
- do {
- arelent **parent;
- unsigned int i;
- long j;
-
- another_pass = 0;
-
- for (i = 0, parent = reloc_vector; *parent; parent++, i++)
- {
- /* Let the target/machine dependent code examine each reloc
- in this section and attempt to shrink it. */
- shrink = bfd_coff_reloc16_estimate (abfd, input_section, *parent,
- shrinks[i], link_info);
-
- /* If it shrunk, note it in the shrinks array and set up for
- another pass. */
- if (shrink != shrinks[i])
- {
- another_pass = 1;
- for (j = i + 1; j <= reloc_count; j++)
- shrinks[j] += shrink - shrinks[i];
- }
- }
- }
+ do
+ {
+ arelent **parent;
+ unsigned int i;
+ long j;
+
+ another_pass = 0;
+
+ for (i = 0, parent = reloc_vector; *parent; parent++, i++)
+ {
+ /* Let the target/machine dependent code examine each reloc
+ in this section and attempt to shrink it. */
+ shrink = bfd_coff_reloc16_estimate (abfd, input_section, *parent,
+ shrinks[i], link_info);
+
+ /* If it shrunk, note it in the shrinks array and set up for
+ another pass. */
+ if (shrink != shrinks[i])
+ {
+ another_pass = 1;
+ for (j = i + 1; j <= reloc_count; j++)
+ shrinks[j] += shrink - shrinks[i];
+ }
+ }
+ }
while (another_pass);
shrink = shrinks[reloc_count];
@@ -231,21 +232,21 @@ bfd_coff_reloc16_relax_section (abfd, input_section, link_info, again)
input_section->_cooked_size -= shrink;
free ((char *) reloc_vector);
- return true;
+ return TRUE;
}
bfd_byte *
-bfd_coff_reloc16_get_relocated_section_contents(in_abfd,
- link_info,
- link_order,
- data,
- relocateable,
- symbols)
+bfd_coff_reloc16_get_relocated_section_contents (in_abfd,
+ link_info,
+ link_order,
+ data,
+ relocatable,
+ symbols)
bfd *in_abfd;
struct bfd_link_info *link_info;
struct bfd_link_order *link_order;
bfd_byte *data;
- boolean relocateable;
+ bfd_boolean relocatable;
asymbol **symbols;
{
/* Get enough memory to hold the stuff. */
@@ -258,19 +259,19 @@ bfd_coff_reloc16_get_relocated_section_contents(in_abfd,
if (reloc_size < 0)
return NULL;
- /* If producing relocateable output, don't bother to relax. */
- if (relocateable)
+ /* If producing relocatable output, don't bother to relax. */
+ if (relocatable)
return bfd_generic_get_relocated_section_contents (in_abfd, link_info,
link_order,
- data, relocateable,
+ data, relocatable,
symbols);
/* Read in the section. */
- if (!bfd_get_section_contents(input_bfd,
- input_section,
- data,
- (bfd_vma) 0,
- input_section->_raw_size))
+ if (!bfd_get_section_contents (input_bfd,
+ input_section,
+ data,
+ (bfd_vma) 0,
+ input_section->_raw_size))
return NULL;
reloc_vector = (arelent **) bfd_malloc ((bfd_size_type) reloc_size);
diff --git a/contrib/binutils/bfd/rs6000-core.c b/contrib/binutils/bfd/rs6000-core.c
index a61f25c..3fa0975 100644
--- a/contrib/binutils/bfd/rs6000-core.c
+++ b/contrib/binutils/bfd/rs6000-core.c
@@ -253,19 +253,19 @@ typedef union {
/* Try to read into CORE the header from the core file associated with ABFD.
Return success. */
-static boolean
+static bfd_boolean
read_hdr (bfd *abfd, CoreHdr *core)
{
bfd_size_type size;
if (bfd_seek (abfd, (file_ptr) 0, SEEK_SET) != 0)
- return false;
+ return FALSE;
/* Read the leading portion that old and new core dump structures have in
common. */
size = CORE_COMMONSZ;
if (bfd_bread (core, size, abfd) != size)
- return false;
+ return FALSE;
/* Read the trailing portion of the structure. */
if (CORE_NEW (*core))
@@ -630,9 +630,9 @@ rs6000coff_core_p (abfd)
return NULL;
}
-/* Return `true' if given core is from the given executable. */
+/* Return `TRUE' if given core is from the given executable. */
-boolean
+bfd_boolean
rs6000coff_core_file_matches_executable_p (core_bfd, exec_bfd)
bfd *core_bfd;
bfd *exec_bfd;
@@ -642,11 +642,11 @@ rs6000coff_core_file_matches_executable_p (core_bfd, exec_bfd)
char *path, *s;
size_t alloc;
const char *str1, *str2;
- boolean ret;
+ bfd_boolean ret;
file_ptr c_loader;
if (!read_hdr (core_bfd, &core))
- return false;
+ return FALSE;
if (CORE_NEW (core))
c_loader = CNEW_LOADER (core.new);
@@ -659,12 +659,12 @@ rs6000coff_core_file_matches_executable_p (core_bfd, exec_bfd)
size = (int) ((LdInfo *) 0)->l32.ldinfo_filename;
if (bfd_seek (core_bfd, c_loader + size, SEEK_SET) != 0)
- return false;
+ return FALSE;
alloc = 100;
path = bfd_malloc ((bfd_size_type) alloc);
if (path == NULL)
- return false;
+ return FALSE;
s = path;
while (1)
@@ -672,7 +672,7 @@ rs6000coff_core_file_matches_executable_p (core_bfd, exec_bfd)
if (bfd_bread (s, (bfd_size_type) 1, core_bfd) != 1)
{
free (path);
- return false;
+ return FALSE;
}
if (*s == '\0')
break;
@@ -686,7 +686,7 @@ rs6000coff_core_file_matches_executable_p (core_bfd, exec_bfd)
if (n == NULL)
{
free (path);
- return false;
+ return FALSE;
}
s = n + (path - s);
path = n;
@@ -701,9 +701,9 @@ rs6000coff_core_file_matches_executable_p (core_bfd, exec_bfd)
str2 = str2 != NULL ? str2 + 1 : exec_bfd->filename;
if (strcmp (str1, str2) == 0)
- ret = true;
+ ret = TRUE;
else
- ret = false;
+ ret = FALSE;
free (path);
diff --git a/contrib/binutils/bfd/sco5-core.c b/contrib/binutils/bfd/sco5-core.c
index 9f5b793..5c34ff1 100644
--- a/contrib/binutils/bfd/sco5-core.c
+++ b/contrib/binutils/bfd/sco5-core.c
@@ -1,5 +1,6 @@
/* BFD back end for SCO5 core files (U-area and raw sections)
- Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004
+ Free Software Foundation, Inc.
Written by Jouke Numan <jnuman@hiscom.nl>
This file is part of BFD, the Binary File Descriptor library.
@@ -21,7 +22,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "bfd.h"
#include "sysdep.h"
#include "libbfd.h"
-#include "libaout.h" /* BFD a.out internal data structures */
+#include "libaout.h" /* BFD a.out internal data structures */
#include <stdio.h>
#include <sys/types.h>
@@ -29,7 +30,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include <sys/dir.h>
#include <signal.h>
-#include <sys/user.h> /* After a.out.h */
+#include <sys/user.h> /* After a.out.h */
#include <sys/paccess.h>
#include <sys/region.h>
@@ -40,15 +41,14 @@ struct sco5_core_struct
/* forward declarations */
-static asection *
-make_bfd_asection PARAMS ((bfd *, const char *, flagword, bfd_size_type,
- bfd_vma, file_ptr));
+static asection *make_bfd_asection
+ PARAMS ((bfd *, const char *, flagword, bfd_size_type, bfd_vma, file_ptr));
static struct user *read_uarea PARAMS ((bfd *, int));
const bfd_target *sco5_core_file_p PARAMS ((bfd *abfd));
char *sco5_core_file_failing_command PARAMS ((bfd *abfd));
int sco5_core_file_failing_signal PARAMS ((bfd *abfd));
-boolean sco5_core_file_matches_executable_p PARAMS ((bfd *core_bfd,
- bfd *exec_bfd));
+bfd_boolean sco5_core_file_matches_executable_p
+ PARAMS ((bfd *core_bfd, bfd *exec_bfd));
static void swap_abort PARAMS ((void));
static asection *
@@ -111,7 +111,6 @@ read_uarea(abfd, filepos)
return &rawptr->u;
}
-/* ARGSUSED */
const bfd_target *
sco5_core_file_p (abfd)
bfd *abfd;
@@ -133,8 +132,8 @@ sco5_core_file_p (abfd)
return NULL;
if (fstat (fileno (stream), &statbuf) < 0)
{
- bfd_set_error (bfd_error_system_call);
- return NULL;
+ bfd_set_error (bfd_error_system_call);
+ return NULL;
}
coresize = statbuf.st_size;
}
@@ -168,24 +167,24 @@ sco5_core_file_p (abfd)
goto fail;
if (!make_bfd_asection (abfd, ".reg", SEC_HAS_CONTENTS,
- (bfd_size_type) coffsets.u_usize,
- 0 - (bfd_vma) u->u_ar0,
- (file_ptr) coffsets.u_user))
+ (bfd_size_type) coffsets.u_usize,
+ 0 - (bfd_vma) u->u_ar0,
+ (file_ptr) coffsets.u_user))
goto fail;
if (!make_bfd_asection (abfd, ".data",
SEC_ALLOC + SEC_LOAD + SEC_HAS_CONTENTS,
- ((bfd_size_type) u->u_exdata.ux_dsize
+ ((bfd_size_type) u->u_exdata.ux_dsize
+ u->u_exdata.ux_bsize),
- (bfd_vma) u->u_exdata.ux_datorg,
- (file_ptr) coffsets.u_data))
+ (bfd_vma) u->u_exdata.ux_datorg,
+ (file_ptr) coffsets.u_data))
goto fail;
if (!make_bfd_asection (abfd, ".stack",
SEC_ALLOC + SEC_LOAD + SEC_HAS_CONTENTS,
- (bfd_size_type) u->u_ssize * NBPC,
- (bfd_vma) u->u_sub,
- (file_ptr) coffsets.u_stack))
+ (bfd_size_type) u->u_ssize * NBPC,
+ (bfd_vma) u->u_sub,
+ (file_ptr) coffsets.u_stack))
goto fail;
return abfd->xvec; /* Done for version 1 */
@@ -222,10 +221,10 @@ sco5_core_file_p (abfd)
if ((bfd_seek (abfd, (file_ptr) chead.cs_hseek, SEEK_SET) != 0)
|| (bfd_bread ((void *) &chead, (bfd_size_type) sizeof chead, abfd)
!= sizeof chead))
- {
- bfd_set_error (bfd_error_wrong_format);
+ {
+ bfd_set_error (bfd_error_wrong_format);
goto fail;
- }
+ }
switch (chead.cs_stype)
{
@@ -243,7 +242,7 @@ sco5_core_file_p (abfd)
if (! u)
goto fail;
- /* This is tricky. As the "register section", we give them
+ /* This is tricky. As the "register section", we give them
the entire upage and stack. u.u_ar0 points to where
"register 0" is stored. There are two tricks with this,
though. One is that the rest of the registers might be
@@ -263,33 +262,33 @@ sco5_core_file_p (abfd)
chead.cs_vaddr = 0 - (bfd_vma) u->u_ar0;
- secname = ".reg";
- flags = SEC_HAS_CONTENTS;
+ secname = ".reg";
+ flags = SEC_HAS_CONTENTS;
- break;
+ break;
case CORES_PREGION: /* A program region, map it */
switch (chead.cs_x.csx_preg.csxp_rtyp)
{
case PT_DATA:
- secname = ".data"; /* Data region. */
+ secname = ".data"; /* Data region. */
break;
case PT_STACK:
- secname = ".stack"; /* Stack region. */
+ secname = ".stack"; /* Stack region. */
break;
case PT_SHMEM:
- secname = ".shmem"; /* Shared memory */
+ secname = ".shmem"; /* Shared memory */
break;
case PT_LIBDAT:
- secname = ".libdat"; /* Shared library data */
+ secname = ".libdat"; /* Shared library data */
break;
case PT_V86:
- secname = ".virt86"; /* Virtual 8086 mode */
+ secname = ".virt86"; /* Virtual 8086 mode */
break;
case PT_SHFIL:
- secname = ".mmfile"; /* Memory mapped file */
+ secname = ".mmfile"; /* Memory mapped file */
break;
case PT_XDATA0:
- secname = ".Xdat0"; /* XENIX data region, virtual 0 */
+ secname = ".Xdat0"; /* XENIX data region, virtual 0 */
break;
default:
secname = "";
@@ -301,11 +300,11 @@ sco5_core_file_p (abfd)
case CORES_SCOUTSNAME: /* struct scoutsname */
secname = NULL; /* Ignore these */
break;
- default:
- (*_bfd_error_handler) ("Unhandled SCO core file section type %d\n",
- chead.cs_stype);
- continue;
- }
+ default:
+ (*_bfd_error_handler) ("Unhandled SCO core file section type %d\n",
+ chead.cs_stype);
+ continue;
+ }
if (secname
&& !make_bfd_asection (abfd, secname, flags,
@@ -339,7 +338,6 @@ sco5_core_file_failing_command (abfd)
return NULL;
}
-/* ARGSUSED */
int
sco5_core_file_failing_signal (ignore_abfd)
bfd *ignore_abfd;
@@ -349,13 +347,12 @@ sco5_core_file_failing_signal (ignore_abfd)
: -1);
}
-/* ARGSUSED */
-boolean
+bfd_boolean
sco5_core_file_matches_executable_p (core_bfd, exec_bfd)
bfd *core_bfd ATTRIBUTE_UNUSED;
bfd *exec_bfd ATTRIBUTE_UNUSED;
{
- return true; /* FIXME, We have no way of telling at this point */
+ return TRUE; /* FIXME, We have no way of telling at this point */
}
/* If somebody calls any byte-swapping routines, shoot them. */
@@ -364,44 +361,47 @@ swap_abort ()
{
abort (); /* This way doesn't require any declaration for ANSI to fuck up */
}
-#define NO_GET ((bfd_vma (*) PARAMS (( const bfd_byte *))) swap_abort )
-#define NO_PUT ((void (*) PARAMS ((bfd_vma, bfd_byte *))) swap_abort )
-#define NO_SIGNED_GET \
- ((bfd_signed_vma (*) PARAMS ((const bfd_byte *))) swap_abort )
+
+#define NO_GET ((bfd_vma (*) (const void *)) swap_abort)
+#define NO_PUT ((void (*) (bfd_vma, void *)) swap_abort)
+#define NO_GETS ((bfd_signed_vma (*) (const void *)) swap_abort)
+#define NO_GET64 ((bfd_uint64_t (*) (const void *)) swap_abort)
+#define NO_PUT64 ((void (*) (bfd_uint64_t, void *)) swap_abort)
+#define NO_GETS64 ((bfd_int64_t (*) (const void *)) swap_abort)
const bfd_target sco5_core_vec =
{
"sco5-core",
bfd_target_unknown_flavour,
- BFD_ENDIAN_LITTLE, /* target byte order */
- BFD_ENDIAN_LITTLE, /* target headers byte order */
- (HAS_RELOC | EXEC_P | /* object flags */
+ BFD_ENDIAN_LITTLE, /* target byte order */
+ BFD_ENDIAN_LITTLE, /* target headers byte order */
+ (HAS_RELOC | EXEC_P | /* object flags */
HAS_LINENO | HAS_DEBUG |
HAS_SYMS | HAS_LOCALS | WP_TEXT | D_PAGED),
(SEC_HAS_CONTENTS | SEC_ALLOC | SEC_LOAD | SEC_RELOC), /* section flags */
- 0, /* symbol prefix */
- ' ', /* ar_pad_char */
- 16, /* ar_max_namelen */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 64 bit data */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 32 bit data */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 16 bit data */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 64 bit hdrs */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 32 bit hdrs */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 16 bit hdrs */
-
- { /* bfd_check_format */
- _bfd_dummy_target, /* unknown format */
- _bfd_dummy_target, /* object file */
- _bfd_dummy_target, /* archive */
- sco5_core_file_p /* a core file */
+ 0, /* symbol prefix */
+ ' ', /* ar_pad_char */
+ 16, /* ar_max_namelen */
+ NO_GET64, NO_GETS64, NO_PUT64, /* 64 bit data */
+ NO_GET, NO_GETS, NO_PUT, /* 32 bit data */
+ NO_GET, NO_GETS, NO_PUT, /* 16 bit data */
+ NO_GET64, NO_GETS64, NO_PUT64, /* 64 bit hdrs */
+ NO_GET, NO_GETS, NO_PUT, /* 32 bit hdrs */
+ NO_GET, NO_GETS, NO_PUT, /* 16 bit hdrs */
+
+ { /* bfd_check_format */
+ _bfd_dummy_target, /* unknown format */
+ _bfd_dummy_target, /* object file */
+ _bfd_dummy_target, /* archive */
+ sco5_core_file_p /* a core file */
},
- { /* bfd_set_format */
- bfd_false, bfd_false,
- bfd_false, bfd_false
+ { /* bfd_set_format */
+ bfd_false, bfd_false,
+ bfd_false, bfd_false
},
- { /* bfd_write_contents */
- bfd_false, bfd_false,
- bfd_false, bfd_false
+ { /* bfd_write_contents */
+ bfd_false, bfd_false,
+ bfd_false, bfd_false
},
BFD_JUMP_TABLE_GENERIC (_bfd_generic),
@@ -416,5 +416,5 @@ const bfd_target sco5_core_vec =
NULL,
- (PTR) 0 /* backend_data */
-};
+ (PTR) 0 /* backend_data */
+ };
diff --git a/contrib/binutils/bfd/section.c b/contrib/binutils/bfd/section.c
index b5871e9..fce8e1e 100644
--- a/contrib/binutils/bfd/section.c
+++ b/contrib/binutils/bfd/section.c
@@ -1,6 +1,6 @@
/* Object file "section" support for the BFD library.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Support.
@@ -166,7 +166,7 @@ CODE_FRAGMENT
. long symbol;
.};
.
-.typedef struct sec
+.typedef struct bfd_section
.{
. {* The name of the section; the name isn't a copy, the pointer is
. the same as that passed to bfd_make_section. *}
@@ -179,7 +179,7 @@ CODE_FRAGMENT
. int index;
.
. {* The next section in the list belonging to the BFD, or NULL. *}
-. struct sec *next;
+. struct bfd_section *next;
.
. {* The field flags contains attributes of the section. Some
. flags are read in from the object file, and some are
@@ -377,10 +377,39 @@ CODE_FRAGMENT
. {* A mark flag used by some linker backends for garbage collection. *}
. unsigned int gc_mark : 1;
.
-. {* Used by the ELF code to mark sections which have been allocated
-. to segments. *}
+. {* The following flags are used by the ELF linker. *}
+.
+. {* Mark sections which have been allocated to segments. *}
. unsigned int segment_mark : 1;
.
+. {* Type of sec_info information. *}
+. unsigned int sec_info_type:3;
+.#define ELF_INFO_TYPE_NONE 0
+.#define ELF_INFO_TYPE_STABS 1
+.#define ELF_INFO_TYPE_MERGE 2
+.#define ELF_INFO_TYPE_EH_FRAME 3
+.#define ELF_INFO_TYPE_JUST_SYMS 4
+.
+. {* Nonzero if this section uses RELA relocations, rather than REL. *}
+. unsigned int use_rela_p:1;
+.
+. {* Bits used by various backends. *}
+. unsigned int has_tls_reloc:1;
+.
+. {* Nonzero if this section needs the relax finalize pass. *}
+. unsigned int need_finalize_relax:1;
+.
+. {* Nonzero if this section has a gp reloc. *}
+. unsigned int has_gp_reloc:1;
+.
+. {* Unused bits. *}
+. unsigned int flag13:1;
+. unsigned int flag14:1;
+. unsigned int flag15:1;
+. unsigned int flag16:4;
+. unsigned int flag20:4;
+. unsigned int flag24:8;
+.
. {* End of internal packed boolean fields. *}
.
. {* The virtual memory address of the section - where it will be
@@ -416,7 +445,7 @@ CODE_FRAGMENT
. bfd_vma output_offset;
.
. {* The output section through which to map on output. *}
-. struct sec *output_section;
+. struct bfd_section *output_section;
.
. {* The alignment requirement of the section, as an exponent of 2 -
. e.g., 3 aligns to 2^3 (or 8). *}
@@ -446,7 +475,7 @@ CODE_FRAGMENT
. file_ptr line_filepos;
.
. {* Pointer to data for applications. *}
-. PTR userdata;
+. void *userdata;
.
. {* If the SEC_IN_MEMORY flag is set, this points to the actual
. contents. *}
@@ -464,6 +493,10 @@ CODE_FRAGMENT
. {* Optional information about a COMDAT entry; NULL if not COMDAT. *}
. struct bfd_comdat_info *comdat;
.
+. {* Points to the kept section if this section is a link-once section,
+. and is discarded. *}
+. struct bfd_section *kept_section;
+.
. {* When a section is being output, this value changes as more
. linenumbers are written out. *}
. file_ptr moving_line_filepos;
@@ -471,7 +504,7 @@ CODE_FRAGMENT
. {* What the section number is in the target world. *}
. int target_index;
.
-. PTR used_by_bfd;
+. void *used_by_bfd;
.
. {* If this is a constructor section then here is a list of the
. relocations created to relocate items within it. *}
@@ -481,8 +514,8 @@ CODE_FRAGMENT
. bfd *owner;
.
. {* A symbol which points at this section only. *}
-. struct symbol_cache_entry *symbol;
-. struct symbol_cache_entry **symbol_ptr_ptr;
+. struct bfd_symbol *symbol;
+. struct bfd_symbol **symbol_ptr_ptr;
.
. struct bfd_link_order *link_order_head;
. struct bfd_link_order *link_order_tail;
@@ -499,18 +532,18 @@ CODE_FRAGMENT
.#define BFD_IND_SECTION_NAME "*IND*"
.
.{* The absolute section. *}
-.extern const asection bfd_abs_section;
+.extern asection bfd_abs_section;
.#define bfd_abs_section_ptr ((asection *) &bfd_abs_section)
.#define bfd_is_abs_section(sec) ((sec) == bfd_abs_section_ptr)
.{* Pointer to the undefined section. *}
-.extern const asection bfd_und_section;
+.extern asection bfd_und_section;
.#define bfd_und_section_ptr ((asection *) &bfd_und_section)
.#define bfd_is_und_section(sec) ((sec) == bfd_und_section_ptr)
.{* Pointer to the common section. *}
-.extern const asection bfd_com_section;
+.extern asection bfd_com_section;
.#define bfd_com_section_ptr ((asection *) &bfd_com_section)
.{* Pointer to the indirect section. *}
-.extern const asection bfd_ind_section;
+.extern asection bfd_ind_section;
.#define bfd_ind_section_ptr ((asection *) &bfd_ind_section)
.#define bfd_is_ind_section(sec) ((sec) == bfd_ind_section_ptr)
.
@@ -520,13 +553,12 @@ CODE_FRAGMENT
. || ((SEC) == bfd_com_section_ptr) \
. || ((SEC) == bfd_ind_section_ptr))
.
-.extern const struct symbol_cache_entry * const bfd_abs_symbol;
-.extern const struct symbol_cache_entry * const bfd_com_symbol;
-.extern const struct symbol_cache_entry * const bfd_und_symbol;
-.extern const struct symbol_cache_entry * const bfd_ind_symbol;
+.extern const struct bfd_symbol * const bfd_abs_symbol;
+.extern const struct bfd_symbol * const bfd_com_symbol;
+.extern const struct bfd_symbol * const bfd_und_symbol;
+.extern const struct bfd_symbol * const bfd_ind_symbol;
.#define bfd_get_section_size_before_reloc(section) \
-. ((section)->reloc_done ? (abort (), (bfd_size_type) 1) \
-. : (section)->_raw_size)
+. ((section)->_raw_size)
.#define bfd_get_section_size_after_reloc(section) \
. ((section)->reloc_done ? (section)->_cooked_size \
. : (abort (), (bfd_size_type) 1))
@@ -583,18 +615,27 @@ static const asymbol global_syms[] =
#define STD_SECTION(SEC, FLAGS, SYM, NAME, IDX) \
const asymbol * const SYM = (asymbol *) &global_syms[IDX]; \
- const asection SEC = \
+ asection SEC = \
/* name, id, index, next, flags, user_set_vma, reloc_done, */ \
{ NAME, IDX, 0, NULL, FLAGS, 0, 0, \
\
/* linker_mark, linker_has_input, gc_mark, segment_mark, */ \
0, 0, 1, 0, \
\
+ /* sec_info_type, use_rela_p, has_tls_reloc, */ \
+ 0, 0, 0, \
+ \
+ /* need_finalize_relax, has_gp_reloc, */ \
+ 0, 0, \
+ \
+ /* flag13, flag14, flag15, flag16, flag20, flag24, */ \
+ 0, 0, 0, 0, 0, 0, \
+ \
/* vma, lma, _cooked_size, _raw_size, */ \
0, 0, 0, 0, \
\
/* output_offset, output_section, alignment_power, */ \
- 0, (struct sec *) &SEC, 0, \
+ 0, (struct bfd_section *) &SEC, 0, \
\
/* relocation, orelocation, reloc_count, filepos, rel_filepos, */ \
NULL, NULL, 0, 0, 0, \
@@ -602,17 +643,17 @@ static const asymbol global_syms[] =
/* line_filepos, userdata, contents, lineno, lineno_count, */ \
0, NULL, NULL, NULL, 0, \
\
- /* entsize, comdat, moving_line_filepos, */ \
- 0, NULL, 0, \
+ /* entsize, comdat, kept_section, moving_line_filepos, */ \
+ 0, NULL, NULL, 0, \
\
/* target_index, used_by_bfd, constructor_chain, owner, */ \
0, NULL, NULL, NULL, \
\
/* symbol, */ \
- (struct symbol_cache_entry *) &global_syms[IDX], \
+ (struct bfd_symbol *) &global_syms[IDX], \
\
/* symbol_ptr_ptr, */ \
- (struct symbol_cache_entry **) &SYM, \
+ (struct bfd_symbol **) &SYM, \
\
/* link_order_head, link_order_tail */ \
NULL, NULL \
@@ -634,10 +675,9 @@ struct section_hash_entry
/* Initialize an entry in the section hash table. */
struct bfd_hash_entry *
-bfd_section_hash_newfunc (entry, table, string)
- struct bfd_hash_entry *entry;
- struct bfd_hash_table *table;
- const char *string;
+bfd_section_hash_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table,
+ const char *string)
{
/* Allocate the structure if it has not already been allocated by a
subclass. */
@@ -652,10 +692,8 @@ bfd_section_hash_newfunc (entry, table, string)
/* Call the allocation method of the superclass. */
entry = bfd_hash_newfunc (entry, table, string);
if (entry != NULL)
- {
- memset ((PTR) &((struct section_hash_entry *) entry)->section,
- 0, sizeof (asection));
- }
+ memset (&((struct section_hash_entry *) entry)->section, 0,
+ sizeof (asection));
return entry;
}
@@ -666,12 +704,8 @@ bfd_section_hash_newfunc (entry, table, string)
/* Initializes a new section. NEWSECT->NAME is already set. */
-static asection *bfd_section_init PARAMS ((bfd *, asection *));
-
static asection *
-bfd_section_init (abfd, newsect)
- bfd *abfd;
- asection *newsect;
+bfd_section_init (bfd *abfd, asection *newsect)
{
static int section_id = 0x10; /* id 0 to 3 used by STD_SECTION. */
@@ -726,13 +760,12 @@ DESCRIPTION
*/
void
-bfd_section_list_clear (abfd)
- bfd *abfd;
+bfd_section_list_clear (bfd *abfd)
{
abfd->sections = NULL;
abfd->section_tail = &abfd->sections;
abfd->section_count = 0;
- memset ((PTR) abfd->section_htab.table, 0,
+ memset (abfd->section_htab.table, 0,
abfd->section_htab.size * sizeof (struct bfd_hash_entry *));
}
@@ -741,7 +774,7 @@ FUNCTION
bfd_get_section_by_name
SYNOPSIS
- asection *bfd_get_section_by_name(bfd *abfd, const char *name);
+ asection *bfd_get_section_by_name (bfd *abfd, const char *name);
DESCRIPTION
Run through @var{abfd} and return the one of the
@@ -755,13 +788,11 @@ DESCRIPTION
*/
asection *
-bfd_get_section_by_name (abfd, name)
- bfd *abfd;
- const char *name;
+bfd_get_section_by_name (bfd *abfd, const char *name)
{
struct section_hash_entry *sh;
- sh = section_hash_lookup (&abfd->section_htab, name, false, false);
+ sh = section_hash_lookup (&abfd->section_htab, name, FALSE, FALSE);
if (sh != NULL)
return &sh->section;
@@ -773,9 +804,8 @@ FUNCTION
bfd_get_unique_section_name
SYNOPSIS
- char *bfd_get_unique_section_name(bfd *abfd,
- const char *templat,
- int *count);
+ char *bfd_get_unique_section_name
+ (bfd *abfd, const char *templat, int *count);
DESCRIPTION
Invent a section name that is unique in @var{abfd} by tacking
@@ -786,17 +816,14 @@ DESCRIPTION
*/
char *
-bfd_get_unique_section_name (abfd, templat, count)
- bfd *abfd;
- const char *templat;
- int *count;
+bfd_get_unique_section_name (bfd *abfd, const char *templat, int *count)
{
int num;
unsigned int len;
char *sname;
len = strlen (templat);
- sname = bfd_malloc ((bfd_size_type) len + 8);
+ sname = bfd_malloc (len + 8);
if (sname == NULL)
return NULL;
memcpy (sname, templat, len);
@@ -811,7 +838,7 @@ bfd_get_unique_section_name (abfd, templat, count)
abort ();
sprintf (sname + len, ".%d", num++);
}
- while (section_hash_lookup (&abfd->section_htab, sname, false, false));
+ while (section_hash_lookup (&abfd->section_htab, sname, FALSE, FALSE));
if (count != NULL)
*count = num;
@@ -823,7 +850,7 @@ FUNCTION
bfd_make_section_old_way
SYNOPSIS
- asection *bfd_make_section_old_way(bfd *abfd, const char *name);
+ asection *bfd_make_section_old_way (bfd *abfd, const char *name);
DESCRIPTION
Create a new empty section called @var{name}
@@ -844,9 +871,7 @@ DESCRIPTION
*/
asection *
-bfd_make_section_old_way (abfd, name)
- bfd *abfd;
- const char *name;
+bfd_make_section_old_way (bfd *abfd, const char *name)
{
struct section_hash_entry *sh;
asection *newsect;
@@ -869,7 +894,7 @@ bfd_make_section_old_way (abfd, name)
if (strcmp (name, BFD_IND_SECTION_NAME) == 0)
return bfd_ind_section_ptr;
- sh = section_hash_lookup (&abfd->section_htab, name, true, false);
+ sh = section_hash_lookup (&abfd->section_htab, name, TRUE, FALSE);
if (sh == NULL)
return NULL;
@@ -889,7 +914,7 @@ FUNCTION
bfd_make_section_anyway
SYNOPSIS
- asection *bfd_make_section_anyway(bfd *abfd, const char *name);
+ asection *bfd_make_section_anyway (bfd *abfd, const char *name);
DESCRIPTION
Create a new empty section called @var{name} and attach it to the end of
@@ -902,9 +927,7 @@ DESCRIPTION
*/
sec_ptr
-bfd_make_section_anyway (abfd, name)
- bfd *abfd;
- const char *name;
+bfd_make_section_anyway (bfd *abfd, const char *name)
{
struct section_hash_entry *sh;
asection *newsect;
@@ -915,7 +938,7 @@ bfd_make_section_anyway (abfd, name)
return NULL;
}
- sh = section_hash_lookup (&abfd->section_htab, name, true, false);
+ sh = section_hash_lookup (&abfd->section_htab, name, TRUE, FALSE);
if (sh == NULL)
return NULL;
@@ -926,7 +949,7 @@ bfd_make_section_anyway (abfd, name)
section_htab without generating a unique section name and
that would be pointless; We don't need to traverse the
hash table. */
- newsect = (asection *) bfd_zalloc (abfd, sizeof (asection));
+ newsect = bfd_zalloc (abfd, sizeof (asection));
if (newsect == NULL)
return NULL;
}
@@ -940,7 +963,7 @@ FUNCTION
bfd_make_section
SYNOPSIS
- asection *bfd_make_section(bfd *, const char *name);
+ asection *bfd_make_section (bfd *, const char *name);
DESCRIPTION
Like <<bfd_make_section_anyway>>, but return <<NULL>> (without calling
@@ -950,9 +973,7 @@ DESCRIPTION
*/
asection *
-bfd_make_section (abfd, name)
- bfd *abfd;
- const char *name;
+bfd_make_section (bfd *abfd, const char *name)
{
struct section_hash_entry *sh;
asection *newsect;
@@ -969,7 +990,7 @@ bfd_make_section (abfd, name)
|| strcmp (name, BFD_IND_SECTION_NAME) == 0)
return NULL;
- sh = section_hash_lookup (&abfd->section_htab, name, true, false);
+ sh = section_hash_lookup (&abfd->section_htab, name, TRUE, FALSE);
if (sh == NULL)
return NULL;
@@ -977,7 +998,7 @@ bfd_make_section (abfd, name)
if (newsect->name != NULL)
{
/* Section already exists. */
- return newsect;
+ return NULL;
}
newsect->name = name;
@@ -989,12 +1010,13 @@ FUNCTION
bfd_set_section_flags
SYNOPSIS
- boolean bfd_set_section_flags(bfd *abfd, asection *sec, flagword flags);
+ bfd_boolean bfd_set_section_flags
+ (bfd *abfd, asection *sec, flagword flags);
DESCRIPTION
Set the attributes of the section @var{sec} in the BFD
- @var{abfd} to the value @var{flags}. Return <<true>> on success,
- <<false>> on error. Possible error returns are:
+ @var{abfd} to the value @var{flags}. Return <<TRUE>> on success,
+ <<FALSE>> on error. Possible error returns are:
o <<bfd_error_invalid_operation>> -
The section cannot have one or more of the attributes
@@ -1003,12 +1025,10 @@ DESCRIPTION
*/
-/*ARGSUSED*/
-boolean
-bfd_set_section_flags (abfd, section, flags)
- bfd *abfd ATTRIBUTE_UNUSED;
- sec_ptr section;
- flagword flags;
+bfd_boolean
+bfd_set_section_flags (bfd *abfd ATTRIBUTE_UNUSED,
+ sec_ptr section,
+ flagword flags)
{
#if 0
/* If you try to copy a text section from an input file (where it
@@ -1019,12 +1039,12 @@ bfd_set_section_flags (abfd, section, flags)
if ((flags & bfd_applicable_section_flags (abfd)) != flags)
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
#endif
section->flags = flags;
- return true;
+ return TRUE;
}
/*
@@ -1032,34 +1052,31 @@ FUNCTION
bfd_map_over_sections
SYNOPSIS
- void bfd_map_over_sections(bfd *abfd,
- void (*func) (bfd *abfd,
- asection *sect,
- PTR obj),
- PTR obj);
+ void bfd_map_over_sections
+ (bfd *abfd,
+ void (*func) (bfd *abfd, asection *sect, void *obj),
+ void *obj);
DESCRIPTION
Call the provided function @var{func} for each section
attached to the BFD @var{abfd}, passing @var{obj} as an
argument. The function will be called as if by
-| func(abfd, the_section, obj);
+| func (abfd, the_section, obj);
- This is the prefered method for iterating over sections; an
+ This is the preferred method for iterating over sections; an
alternative would be to use a loop:
| section *p;
| for (p = abfd->sections; p != NULL; p = p->next)
-| func(abfd, p, ...)
+| func (abfd, p, ...)
*/
-/*VARARGS2*/
void
-bfd_map_over_sections (abfd, operation, user_storage)
- bfd *abfd;
- void (*operation) PARAMS ((bfd * abfd, asection * sect, PTR obj));
- PTR user_storage;
+bfd_map_over_sections (bfd *abfd,
+ void (*operation) (bfd *, asection *, void *),
+ void *user_storage)
{
asection *sect;
unsigned int i = 0;
@@ -1076,11 +1093,12 @@ FUNCTION
bfd_set_section_size
SYNOPSIS
- boolean bfd_set_section_size(bfd *abfd, asection *sec, bfd_size_type val);
+ bfd_boolean bfd_set_section_size
+ (bfd *abfd, asection *sec, bfd_size_type val);
DESCRIPTION
Set @var{sec} to the size @var{val}. If the operation is
- ok, then <<true>> is returned, else <<false>>.
+ ok, then <<TRUE>> is returned, else <<FALSE>>.
Possible error returns:
o <<bfd_error_invalid_operation>> -
@@ -1088,11 +1106,8 @@ DESCRIPTION
*/
-boolean
-bfd_set_section_size (abfd, ptr, val)
- bfd *abfd;
- sec_ptr ptr;
- bfd_size_type val;
+bfd_boolean
+bfd_set_section_size (bfd *abfd, sec_ptr ptr, bfd_size_type val)
{
/* Once you've started writing to any section you cannot create or change
the size of any others. */
@@ -1100,13 +1115,13 @@ bfd_set_section_size (abfd, ptr, val)
if (abfd->output_has_begun)
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
ptr->_cooked_size = val;
ptr->_raw_size = val;
- return true;
+ return TRUE;
}
/*
@@ -1114,9 +1129,9 @@ FUNCTION
bfd_set_section_contents
SYNOPSIS
- boolean bfd_set_section_contents (bfd *abfd, asection *section,
- PTR data, file_ptr offset,
- bfd_size_type count);
+ bfd_boolean bfd_set_section_contents
+ (bfd *abfd, asection *section, const void *data,
+ file_ptr offset, bfd_size_type count);
DESCRIPTION
Sets the contents of the section @var{section} in BFD
@@ -1124,7 +1139,7 @@ DESCRIPTION
data is written to the output section starting at offset
@var{offset} for @var{count} octets.
- Normally <<true>> is returned, else <<false>>. Possible error
+ Normally <<TRUE>> is returned, else <<FALSE>>. Possible error
returns are:
o <<bfd_error_no_contents>> -
The output section does not have the <<SEC_HAS_CONTENTS>>
@@ -1136,25 +1151,24 @@ DESCRIPTION
*/
-#define bfd_get_section_size_now(abfd,sec) \
-(sec->reloc_done \
- ? bfd_get_section_size_after_reloc (sec) \
- : bfd_get_section_size_before_reloc (sec))
-
-boolean
-bfd_set_section_contents (abfd, section, location, offset, count)
- bfd *abfd;
- sec_ptr section;
- PTR location;
- file_ptr offset;
- bfd_size_type count;
+#define bfd_get_section_size_now(abfd, sec) \
+ (sec->reloc_done \
+ ? bfd_get_section_size_after_reloc (sec) \
+ : bfd_get_section_size_before_reloc (sec))
+
+bfd_boolean
+bfd_set_section_contents (bfd *abfd,
+ sec_ptr section,
+ const void *location,
+ file_ptr offset,
+ bfd_size_type count)
{
bfd_size_type sz;
if (!(bfd_get_section_flags (abfd, section) & SEC_HAS_CONTENTS))
{
bfd_set_error (bfd_error_no_contents);
- return (false);
+ return FALSE;
}
sz = bfd_get_section_size_now (abfd, section);
@@ -1164,7 +1178,7 @@ bfd_set_section_contents (abfd, section, location, offset, count)
|| count != (size_t) count)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
switch (abfd->direction)
@@ -1172,7 +1186,7 @@ bfd_set_section_contents (abfd, section, location, offset, count)
case read_direction:
case no_direction:
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
case write_direction:
break;
@@ -1181,23 +1195,23 @@ bfd_set_section_contents (abfd, section, location, offset, count)
/* File is opened for update. `output_has_begun' some time ago when
the file was created. Do not recompute sections sizes or alignments
in _bfd_set_section_content. */
- abfd->output_has_begun = true;
+ abfd->output_has_begun = TRUE;
break;
}
/* Record a copy of the data in memory if desired. */
if (section->contents
- && location != (PTR) (section->contents + offset))
+ && location != section->contents + offset)
memcpy (section->contents + offset, location, (size_t) count);
if (BFD_SEND (abfd, _bfd_set_section_contents,
(abfd, section, location, offset, count)))
{
- abfd->output_has_begun = true;
- return true;
+ abfd->output_has_begun = TRUE;
+ return TRUE;
}
- return false;
+ return FALSE;
}
/*
@@ -1205,9 +1219,9 @@ FUNCTION
bfd_get_section_contents
SYNOPSIS
- boolean bfd_get_section_contents (bfd *abfd, asection *section,
- PTR location, file_ptr offset,
- bfd_size_type count);
+ bfd_boolean bfd_get_section_contents
+ (bfd *abfd, asection *section, void *location, file_ptr offset,
+ bfd_size_type count);
DESCRIPTION
Read data from @var{section} in BFD @var{abfd}
@@ -1218,27 +1232,26 @@ DESCRIPTION
If the contents of a constructor with the <<SEC_CONSTRUCTOR>>
flag set are requested or if the section does not have the
<<SEC_HAS_CONTENTS>> flag set, then the @var{location} is filled
- with zeroes. If no errors occur, <<true>> is returned, else
- <<false>>.
+ with zeroes. If no errors occur, <<TRUE>> is returned, else
+ <<FALSE>>.
*/
-boolean
-bfd_get_section_contents (abfd, section, location, offset, count)
- bfd *abfd;
- sec_ptr section;
- PTR location;
- file_ptr offset;
- bfd_size_type count;
+bfd_boolean
+bfd_get_section_contents (bfd *abfd,
+ sec_ptr section,
+ void *location,
+ file_ptr offset,
+ bfd_size_type count)
{
bfd_size_type sz;
if (section->flags & SEC_CONSTRUCTOR)
{
memset (location, 0, (size_t) count);
- return true;
+ return TRUE;
}
- /* Even if reloc_done is true, this function reads unrelocated
+ /* Even if reloc_done is TRUE, this function reads unrelocated
contents, so we want the raw size. */
sz = section->_raw_size;
if ((bfd_size_type) offset > sz
@@ -1247,23 +1260,23 @@ bfd_get_section_contents (abfd, section, location, offset, count)
|| count != (size_t) count)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
if (count == 0)
/* Don't bother. */
- return true;
+ return TRUE;
if ((section->flags & SEC_HAS_CONTENTS) == 0)
{
memset (location, 0, (size_t) count);
- return true;
+ return TRUE;
}
if ((section->flags & SEC_IN_MEMORY) != 0)
{
memcpy (location, section->contents + offset, (size_t) count);
- return true;
+ return TRUE;
}
return BFD_SEND (abfd, _bfd_get_section_contents,
@@ -1275,13 +1288,13 @@ FUNCTION
bfd_copy_private_section_data
SYNOPSIS
- boolean bfd_copy_private_section_data (bfd *ibfd, asection *isec,
- bfd *obfd, asection *osec);
+ bfd_boolean bfd_copy_private_section_data
+ (bfd *ibfd, asection *isec, bfd *obfd, asection *osec);
DESCRIPTION
Copy private section information from @var{isec} in the BFD
@var{ibfd} to the section @var{osec} in the BFD @var{obfd}.
- Return <<true>> on success, <<false>> on error. Possible error
+ Return <<TRUE>> on success, <<FALSE>> on error. Possible error
returns are:
o <<bfd_error_no_memory>> -
@@ -1298,7 +1311,7 @@ FUNCTION
SYNOPSIS
void _bfd_strip_section_from_output
- (struct bfd_link_info *info, asection *section);
+ (struct bfd_link_info *info, asection *section);
DESCRIPTION
Remove @var{section} from the output. If the output section
@@ -1309,9 +1322,7 @@ DESCRIPTION
to remove sections.
*/
void
-_bfd_strip_section_from_output (info, s)
- struct bfd_link_info *info;
- asection *s;
+_bfd_strip_section_from_output (struct bfd_link_info *info, asection *s)
{
asection *os;
asection *is;
@@ -1343,16 +1354,15 @@ FUNCTION
bfd_generic_discard_group
SYNOPSIS
- boolean bfd_generic_discard_group (bfd *abfd, asection *group);
+ bfd_boolean bfd_generic_discard_group (bfd *abfd, asection *group);
DESCRIPTION
Remove all members of @var{group} from the output.
*/
-boolean
-bfd_generic_discard_group (abfd, group)
- bfd *abfd ATTRIBUTE_UNUSED;
- asection *group ATTRIBUTE_UNUSED;
+bfd_boolean
+bfd_generic_discard_group (bfd *abfd ATTRIBUTE_UNUSED,
+ asection *group ATTRIBUTE_UNUSED)
{
- return true;
+ return TRUE;
}
diff --git a/contrib/binutils/bfd/simple.c b/contrib/binutils/bfd/simple.c
new file mode 100644
index 0000000..fc2472e
--- /dev/null
+++ b/contrib/binutils/bfd/simple.c
@@ -0,0 +1,257 @@
+/* simple.c -- BFD simple client routines
+ Copyright 2002, 2003, 2004
+ Free Software Foundation, Inc.
+ Contributed by MontaVista Software, Inc.
+
+ This file is part of BFD, the Binary File Descriptor library.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+#include "bfd.h"
+#include "sysdep.h"
+#include "libbfd.h"
+#include "bfdlink.h"
+
+static bfd_boolean
+simple_dummy_warning (struct bfd_link_info *link_info ATTRIBUTE_UNUSED,
+ const char *warning ATTRIBUTE_UNUSED,
+ const char *symbol ATTRIBUTE_UNUSED,
+ bfd *abfd ATTRIBUTE_UNUSED,
+ asection *section ATTRIBUTE_UNUSED,
+ bfd_vma address ATTRIBUTE_UNUSED)
+{
+ return TRUE;
+}
+
+static bfd_boolean
+simple_dummy_undefined_symbol (struct bfd_link_info *link_info ATTRIBUTE_UNUSED,
+ const char *name ATTRIBUTE_UNUSED,
+ bfd *abfd ATTRIBUTE_UNUSED,
+ asection *section ATTRIBUTE_UNUSED,
+ bfd_vma address ATTRIBUTE_UNUSED,
+ bfd_boolean fatal ATTRIBUTE_UNUSED)
+{
+ return TRUE;
+}
+
+static bfd_boolean
+simple_dummy_reloc_overflow (struct bfd_link_info *link_info ATTRIBUTE_UNUSED,
+ const char *name ATTRIBUTE_UNUSED,
+ const char *reloc_name ATTRIBUTE_UNUSED,
+ bfd_vma addend ATTRIBUTE_UNUSED,
+ bfd *abfd ATTRIBUTE_UNUSED,
+ asection *section ATTRIBUTE_UNUSED,
+ bfd_vma address ATTRIBUTE_UNUSED)
+{
+ return TRUE;
+}
+
+static bfd_boolean
+simple_dummy_reloc_dangerous (struct bfd_link_info *link_info ATTRIBUTE_UNUSED,
+ const char *message ATTRIBUTE_UNUSED,
+ bfd *abfd ATTRIBUTE_UNUSED,
+ asection *section ATTRIBUTE_UNUSED,
+ bfd_vma address ATTRIBUTE_UNUSED)
+{
+ return TRUE;
+}
+
+static bfd_boolean
+simple_dummy_unattached_reloc (struct bfd_link_info *link_info ATTRIBUTE_UNUSED,
+ const char *name ATTRIBUTE_UNUSED,
+ bfd *abfd ATTRIBUTE_UNUSED,
+ asection *section ATTRIBUTE_UNUSED,
+ bfd_vma address ATTRIBUTE_UNUSED)
+{
+ return TRUE;
+}
+
+struct saved_output_info
+{
+ bfd_vma offset;
+ asection *section;
+};
+
+static void
+simple_save_output_info (bfd *abfd ATTRIBUTE_UNUSED,
+ asection *section,
+ void *ptr)
+{
+ struct saved_output_info *output_info = ptr;
+ output_info[section->index].offset = section->output_offset;
+ output_info[section->index].section = section->output_section;
+ section->output_offset = 0;
+ section->output_section = section;
+}
+
+static void
+simple_restore_output_info (bfd *abfd ATTRIBUTE_UNUSED,
+ asection *section,
+ void *ptr)
+{
+ struct saved_output_info *output_info = ptr;
+ section->output_offset = output_info[section->index].offset;
+ section->output_section = output_info[section->index].section;
+}
+
+/*
+FUNCTION
+ bfd_simple_relocate_secton
+
+SYNOPSIS
+ bfd_byte *bfd_simple_get_relocated_section_contents
+ (bfd *abfd, asection *sec, bfd_byte *outbuf, asymbol **symbol_table);
+
+DESCRIPTION
+ Returns the relocated contents of section @var{sec}. The symbols in
+ @var{symbol_table} will be used, or the symbols from @var{abfd} if
+ @var{symbol_table} is NULL. The output offsets for all sections will
+ be temporarily reset to 0. The result will be stored at @var{outbuf}
+ or allocated with @code{bfd_malloc} if @var{outbuf} is @code{NULL}.
+
+ Generally all sections in @var{abfd} should have their
+ @code{output_section} pointing back to the original section.
+
+ Returns @code{NULL} on a fatal error; ignores errors applying
+ particular relocations.
+*/
+
+bfd_byte *
+bfd_simple_get_relocated_section_contents (bfd *abfd,
+ asection *sec,
+ bfd_byte *outbuf,
+ asymbol **symbol_table)
+{
+ struct bfd_link_info link_info;
+ struct bfd_link_order link_order;
+ struct bfd_link_callbacks callbacks;
+ bfd_byte *contents, *data;
+ int storage_needed;
+ void *saved_offsets;
+ bfd_size_type old_cooked_size;
+
+ if (! (sec->flags & SEC_RELOC))
+ {
+ bfd_size_type size = bfd_section_size (abfd, sec);
+
+ if (outbuf == NULL)
+ contents = bfd_malloc (size);
+ else
+ contents = outbuf;
+
+ if (contents)
+ bfd_get_section_contents (abfd, sec, contents, 0, size);
+
+ return contents;
+ }
+
+ /* In order to use bfd_get_relocated_section_contents, we need
+ to forge some data structures that it expects. */
+
+ /* Fill in the bare minimum number of fields for our purposes. */
+ memset (&link_info, 0, sizeof (link_info));
+ link_info.input_bfds = abfd;
+
+ link_info.hash = _bfd_generic_link_hash_table_create (abfd);
+ link_info.callbacks = &callbacks;
+ callbacks.warning = simple_dummy_warning;
+ callbacks.undefined_symbol = simple_dummy_undefined_symbol;
+ callbacks.reloc_overflow = simple_dummy_reloc_overflow;
+ callbacks.reloc_dangerous = simple_dummy_reloc_dangerous;
+ callbacks.unattached_reloc = simple_dummy_unattached_reloc;
+
+ memset (&link_order, 0, sizeof (link_order));
+ link_order.next = NULL;
+ link_order.type = bfd_indirect_link_order;
+ link_order.offset = 0;
+ link_order.size = bfd_section_size (abfd, sec);
+ link_order.u.indirect.section = sec;
+
+ data = NULL;
+ if (outbuf == NULL)
+ {
+ data = bfd_malloc (bfd_section_size (abfd, sec));
+ if (data == NULL)
+ return NULL;
+ outbuf = data;
+ }
+
+ /* The sections in ABFD may already have output sections and offsets set.
+ Because this function is primarily for debug sections, and GCC uses the
+ knowledge that debug sections will generally have VMA 0 when emitting
+ relocations between DWARF-2 sections (which are supposed to be
+ section-relative offsets anyway), we need to reset the output offsets
+ to zero. We also need to arrange for section->output_section->vma plus
+ section->output_offset to equal section->vma, which we do by setting
+ section->output_section to point back to section. Save the original
+ output offset and output section to restore later. */
+ saved_offsets = malloc (sizeof (struct saved_output_info)
+ * abfd->section_count);
+ if (saved_offsets == NULL)
+ {
+ if (data)
+ free (data);
+ return NULL;
+ }
+ bfd_map_over_sections (abfd, simple_save_output_info, saved_offsets);
+
+ if (symbol_table == NULL)
+ {
+ _bfd_generic_link_add_symbols (abfd, &link_info);
+
+ storage_needed = bfd_get_symtab_upper_bound (abfd);
+ symbol_table = bfd_malloc (storage_needed);
+ bfd_canonicalize_symtab (abfd, symbol_table);
+ }
+ else
+ storage_needed = 0;
+
+ /* This function might be called before _cooked_size has been set, and
+ bfd_perform_relocation needs _cooked_size to be valid. */
+ old_cooked_size = sec->_cooked_size;
+ if (old_cooked_size == 0)
+ sec->_cooked_size = sec->_raw_size;
+
+ contents = bfd_get_relocated_section_contents (abfd,
+ &link_info,
+ &link_order,
+ outbuf,
+ 0,
+ symbol_table);
+ if (contents == NULL && data != NULL)
+ free (data);
+
+#if 0
+ /* NOTE: cagney/2003-04-05: This free, which was introduced on
+ 2003-03-31 to stop a memory leak, caused a memory corruption
+ between GDB and BFD. The problem, which is stabs specific, can
+ be identified by a bunch of failures in relocate.exp vis:
+
+ gdb.base/relocate.exp: get address of static_bar
+
+ Details of the problem can be found on the binutils@ mailing
+ list, see the discussion thread: "gdb.mi/mi-cli.exp failures". */
+ if (storage_needed != 0)
+ free (symbol_table);
+#endif
+
+ sec->_cooked_size = old_cooked_size;
+ bfd_map_over_sections (abfd, simple_restore_output_info, saved_offsets);
+ free (saved_offsets);
+
+ _bfd_generic_link_hash_table_free (link_info.hash);
+
+ return contents;
+}
diff --git a/contrib/binutils/bfd/sparclinux.c b/contrib/binutils/bfd/sparclinux.c
index e55a4ff..ecaaa0f 100644
--- a/contrib/binutils/bfd/sparclinux.c
+++ b/contrib/binutils/bfd/sparclinux.c
@@ -1,5 +1,5 @@
/* BFD back-end for linux flavored sparc a.out binaries.
- Copyright 1992, 1993, 1994, 1995, 1996, 1997, 2000, 2001, 2002
+ Copyright 1992, 1993, 1994, 1995, 1996, 1997, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -19,12 +19,11 @@ along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
USA. */
-#define TARGET_PAGE_SIZE 4096
-#define ZMAGIC_DISK_BLOCK_SIZE 1024
-#define SEGMENT_SIZE TARGET_PAGE_SIZE
-#define TEXT_START_ADDR 0x0
-#define N_SHARED_LIB(x) 0
-#define BYTES_IN_WORD 4
+#define TARGET_PAGE_SIZE 4096
+#define ZMAGIC_DISK_BLOCK_SIZE 1024
+#define SEGMENT_SIZE TARGET_PAGE_SIZE
+#define TEXT_START_ADDR 0x0
+#define N_SHARED_LIB(x) 0
#define MACHTYPE_OK(mtype) ((mtype) == M_SPARC || (mtype) == M_UNKNOWN)
@@ -52,10 +51,10 @@ extern const bfd_target MY(vec);
static void MY_final_link_callback
PARAMS ((bfd *, file_ptr *, file_ptr *, file_ptr *));
-static boolean sparclinux_bfd_final_link
+static bfd_boolean sparclinux_bfd_final_link
PARAMS ((bfd *abfd, struct bfd_link_info *info));
-static boolean
+static bfd_boolean
sparclinux_bfd_final_link (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -68,9 +67,9 @@ sparclinux_bfd_final_link (abfd, info)
/* Set the machine type correctly. */
-static boolean sparclinux_write_object_contents PARAMS ((bfd *abfd));
+static bfd_boolean sparclinux_write_object_contents PARAMS ((bfd *abfd));
-static boolean
+static bfd_boolean
sparclinux_write_object_contents (abfd)
bfd *abfd;
{
@@ -83,7 +82,7 @@ sparclinux_write_object_contents (abfd)
WRITE_HEADERS(abfd, execp);
- return true;
+ return TRUE;
}
#define MY_write_object_contents sparclinux_write_object_contents
@@ -92,7 +91,7 @@ sparclinux_write_object_contents (abfd)
/* See if a symbol name is a reference to the global offset table. */
#ifndef GOT_REF_PREFIX
-#define GOT_REF_PREFIX "__GOT_"
+#define GOT_REF_PREFIX "__GOT_"
#endif
#define IS_GOT_SYM(name) \
@@ -101,7 +100,7 @@ sparclinux_write_object_contents (abfd)
/* See if a symbol name is a reference to the procedure linkage table. */
#ifndef PLT_REF_PREFIX
-#define PLT_REF_PREFIX "__PLT_"
+#define PLT_REF_PREFIX "__PLT_"
#endif
#define IS_PLT_SYM(name) \
@@ -114,7 +113,7 @@ sparclinux_write_object_contents (abfd)
#endif
/* This special symbol is a set vector that contains a list of
- pointers to fixup tables. It will be present in any dynamicly
+ pointers to fixup tables. It will be present in any dynamically
linked file. The linker generated fixup table should also be added
to the list, and it should always appear in the second slot (the
first one is a dummy with a magic number that is defined in
@@ -179,16 +178,16 @@ static struct bfd_link_hash_table *linux_link_hash_table_create
PARAMS ((bfd *));
static struct fixup *new_fixup
PARAMS ((struct bfd_link_info *, struct linux_link_hash_entry *,
- bfd_vma, int));
-static boolean linux_link_create_dynamic_sections
+ bfd_vma, int));
+static bfd_boolean linux_link_create_dynamic_sections
PARAMS ((bfd *, struct bfd_link_info *));
-static boolean linux_add_one_symbol
+static bfd_boolean linux_add_one_symbol
PARAMS ((struct bfd_link_info *, bfd *, const char *, flagword, asection *,
- bfd_vma, const char *, boolean, boolean,
- struct bfd_link_hash_entry **));
-static boolean linux_tally_symbols
+ bfd_vma, const char *, bfd_boolean, bfd_boolean,
+ struct bfd_link_hash_entry **));
+static bfd_boolean linux_tally_symbols
PARAMS ((struct linux_link_hash_entry *, PTR));
-static boolean linux_finish_dynamic_link
+static bfd_boolean linux_finish_dynamic_link
PARAMS ((bfd *, struct bfd_link_info *));
/* Routine to create an entry in an Linux link hash table. */
@@ -205,14 +204,14 @@ linux_link_hash_newfunc (entry, table, string)
subclass. */
if (ret == (struct linux_link_hash_entry *) NULL)
ret = ((struct linux_link_hash_entry *)
- bfd_hash_allocate (table, sizeof (struct linux_link_hash_entry)));
+ bfd_hash_allocate (table, sizeof (struct linux_link_hash_entry)));
if (ret == NULL)
return (struct bfd_hash_entry *) ret;
/* Call the allocation method of the superclass. */
ret = ((struct linux_link_hash_entry *)
- NAME(aout,link_hash_newfunc) ((struct bfd_hash_entry *) ret,
- table, string));
+ NAME(aout,link_hash_newfunc) ((struct bfd_hash_entry *) ret,
+ table, string));
if (ret != NULL)
{
/* Set local fields; there aren't any. */
@@ -234,7 +233,7 @@ linux_link_hash_table_create (abfd)
if (ret == (struct linux_link_hash_table *) NULL)
return (struct bfd_link_hash_table *) NULL;
if (! NAME(aout,link_hash_table_init) (&ret->root, abfd,
- linux_link_hash_newfunc))
+ linux_link_hash_newfunc))
{
free (ret);
return (struct bfd_link_hash_table *) NULL;
@@ -253,14 +252,14 @@ linux_link_hash_table_create (abfd)
#define linux_link_hash_lookup(table, string, create, copy, follow) \
((struct linux_link_hash_entry *) \
aout_link_hash_lookup (&(table)->root, (string), (create), (copy),\
- (follow)))
+ (follow)))
/* Traverse a Linux link hash table. */
-#define linux_link_hash_traverse(table, func, info) \
- (aout_link_hash_traverse \
- (&(table)->root, \
- (boolean (*) PARAMS ((struct aout_link_hash_entry *, PTR))) (func), \
+#define linux_link_hash_traverse(table, func, info) \
+ (aout_link_hash_traverse \
+ (&(table)->root, \
+ (bfd_boolean (*) PARAMS ((struct aout_link_hash_entry *, PTR))) (func), \
(info)))
/* Get the Linux link hash table from the info structure. This is
@@ -280,7 +279,7 @@ new_fixup (info, h, value, builtin)
struct fixup *f;
f = (struct fixup *) bfd_hash_allocate (&info->hash->table,
- sizeof (struct fixup));
+ sizeof (struct fixup));
if (f == NULL)
return f;
f->next = linux_hash_table (info)->fixup_list;
@@ -300,7 +299,7 @@ new_fixup (info, h, value, builtin)
know the size of the section, but that's OK - we just need to
create it for now. */
-static boolean
+static bfd_boolean
linux_link_create_dynamic_sections (abfd, info)
bfd *abfd;
struct bfd_link_info *info ATTRIBUTE_UNUSED;
@@ -312,25 +311,25 @@ linux_link_create_dynamic_sections (abfd, info)
flags = SEC_ALLOC | SEC_LOAD | SEC_HAS_CONTENTS | SEC_IN_MEMORY;
/* We choose to use the name ".linux-dynamic" for the fixup table.
- Why not? */
+ Why not? */
s = bfd_make_section (abfd, ".linux-dynamic");
if (s == NULL
|| ! bfd_set_section_flags (abfd, s, flags)
|| ! bfd_set_section_alignment (abfd, s, 2))
- return false;
+ return FALSE;
s->_raw_size = 0;
s->contents = 0;
- return true;
+ return TRUE;
}
/* Function to add a single symbol to the linker hash table. This is
a wrapper around _bfd_generic_link_add_one_symbol which handles the
tweaking needed for dynamic linking support. */
-static boolean
+static bfd_boolean
linux_add_one_symbol (info, abfd, name, flags, section, value, string,
- copy, collect, hashp)
+ copy, collect, hashp)
struct bfd_link_info *info;
bfd *abfd;
const char *name;
@@ -338,12 +337,12 @@ linux_add_one_symbol (info, abfd, name, flags, section, value, string,
asection *section;
bfd_vma value;
const char *string;
- boolean copy;
- boolean collect;
+ bfd_boolean copy;
+ bfd_boolean collect;
struct bfd_link_hash_entry **hashp;
{
struct linux_link_hash_entry *h;
- boolean insert;
+ bfd_boolean insert;
/* Look up and see if we already have this symbol in the hash table.
If we do, and the defining entry is from a shared library, we
@@ -353,69 +352,69 @@ linux_add_one_symbol (info, abfd, name, flags, section, value, string,
be able to link Linux a.out and ELF objects together, but serious
confusion is possible. */
- insert = false;
+ insert = FALSE;
- if (! info->relocateable
+ if (! info->relocatable
&& linux_hash_table (info)->dynobj == NULL
&& strcmp (name, SHARABLE_CONFLICTS) == 0
&& (flags & BSF_CONSTRUCTOR) != 0
&& abfd->xvec == info->hash->creator)
{
if (! linux_link_create_dynamic_sections (abfd, info))
- return false;
+ return FALSE;
linux_hash_table (info)->dynobj = abfd;
- insert = true;
+ insert = TRUE;
}
if (bfd_is_abs_section (section)
&& abfd->xvec == info->hash->creator)
{
- h = linux_link_hash_lookup (linux_hash_table (info), name, false,
- false, false);
+ h = linux_link_hash_lookup (linux_hash_table (info), name, FALSE,
+ FALSE, FALSE);
if (h != NULL
- && (h->root.root.type == bfd_link_hash_defined
- || h->root.root.type == bfd_link_hash_defweak))
- {
- struct fixup *f;
+ && (h->root.root.type == bfd_link_hash_defined
+ || h->root.root.type == bfd_link_hash_defweak))
+ {
+ struct fixup *f;
- if (hashp != NULL)
- *hashp = (struct bfd_link_hash_entry *) h;
+ if (hashp != NULL)
+ *hashp = (struct bfd_link_hash_entry *) h;
- f = new_fixup (info, h, value, ! IS_PLT_SYM (name));
- if (f == NULL)
- return false;
- f->jump = IS_PLT_SYM (name);
+ f = new_fixup (info, h, value, ! IS_PLT_SYM (name));
+ if (f == NULL)
+ return FALSE;
+ f->jump = IS_PLT_SYM (name);
- return true;
- }
+ return TRUE;
+ }
}
/* Do the usual procedure for adding a symbol. */
if (! _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section,
- value, string, copy, collect,
- hashp))
- return false;
+ value, string, copy, collect,
+ hashp))
+ return FALSE;
/* Insert a pointer to our table in the set vector. The dynamic
- linker requires this information */
+ linker requires this information. */
if (insert)
{
asection *s;
/* Here we do our special thing to add the pointer to the
- dynamic section in the SHARABLE_CONFLICTS set vector. */
+ dynamic section in the SHARABLE_CONFLICTS set vector. */
s = bfd_get_section_by_name (linux_hash_table (info)->dynobj,
- ".linux-dynamic");
+ ".linux-dynamic");
BFD_ASSERT (s != NULL);
if (! (_bfd_generic_link_add_one_symbol
- (info, linux_hash_table (info)->dynobj, SHARABLE_CONFLICTS,
- BSF_GLOBAL | BSF_CONSTRUCTOR, s, (bfd_vma) 0, NULL,
- false, false, NULL)))
- return false;
+ (info, linux_hash_table (info)->dynobj, SHARABLE_CONFLICTS,
+ BSF_GLOBAL | BSF_CONSTRUCTOR, s, (bfd_vma) 0, NULL,
+ FALSE, FALSE, NULL)))
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* We will crawl the hash table and come here for every global symbol.
@@ -428,7 +427,7 @@ linux_add_one_symbol (info, abfd, name, flags, section, value, string,
This function is called via linux_link_hash_traverse. */
-static boolean
+static bfd_boolean
linux_tally_symbols (h, data)
struct linux_link_hash_entry *h;
PTR data;
@@ -437,14 +436,14 @@ linux_tally_symbols (h, data)
struct fixup *f, *f1;
int is_plt;
struct linux_link_hash_entry *h1, *h2;
- boolean exists;
+ bfd_boolean exists;
if (h->root.root.type == bfd_link_hash_warning)
h = (struct linux_link_hash_entry *) h->root.root.u.i.link;
if (h->root.root.type == bfd_link_hash_undefined
&& strncmp (h->root.root.root.string, NEEDS_SHRLIB,
- sizeof NEEDS_SHRLIB - 1) == 0)
+ sizeof NEEDS_SHRLIB - 1) == 0)
{
const char *name;
char *p;
@@ -453,21 +452,21 @@ linux_tally_symbols (h, data)
name = h->root.root.root.string + sizeof NEEDS_SHRLIB - 1;
p = strrchr (name, '_');
if (p != NULL)
- alloc = (char *) bfd_malloc ((bfd_size_type) strlen (name) + 1);
+ alloc = (char *) bfd_malloc ((bfd_size_type) strlen (name) + 1);
if (p == NULL || alloc == NULL)
- (*_bfd_error_handler) (_("Output file requires shared library `%s'\n"),
- name);
+ (*_bfd_error_handler) (_("Output file requires shared library `%s'\n"),
+ name);
else
- {
- strcpy (alloc, name);
- p = strrchr (alloc, '_');
- *p++ = '\0';
- (*_bfd_error_handler)
- (_("Output file requires shared library `%s.so.%s'\n"),
- alloc, p);
- free (alloc);
- }
+ {
+ strcpy (alloc, name);
+ p = strrchr (alloc, '_');
+ *p++ = '\0';
+ (*_bfd_error_handler)
+ (_("Output file requires shared library `%s.so.%s'\n"),
+ alloc, p);
+ free (alloc);
+ }
abort ();
}
@@ -479,75 +478,75 @@ linux_tally_symbols (h, data)
if (is_plt || IS_GOT_SYM (h->root.root.root.string))
{
/* Look up this symbol twice. Once just as a regular lookup,
- and then again following all of the indirect links until we
- reach a real symbol. */
+ and then again following all of the indirect links until we
+ reach a real symbol. */
h1 = linux_link_hash_lookup (linux_hash_table (info),
- (h->root.root.root.string
- + sizeof PLT_REF_PREFIX - 1),
- false, false, true);
+ (h->root.root.root.string
+ + sizeof PLT_REF_PREFIX - 1),
+ FALSE, FALSE, TRUE);
/* h2 does not follow indirect symbols. */
h2 = linux_link_hash_lookup (linux_hash_table (info),
- (h->root.root.root.string
- + sizeof PLT_REF_PREFIX - 1),
- false, false, false);
+ (h->root.root.root.string
+ + sizeof PLT_REF_PREFIX - 1),
+ FALSE, FALSE, FALSE);
/* The real symbol must exist but if it is also an ABS symbol,
- there is no need to have a fixup. This is because they both
- came from the same library. If on the other hand, we had to
- use an indirect symbol to get to the real symbol, we add the
- fixup anyway, since there are cases where these symbols come
- from different shared libraries */
+ there is no need to have a fixup. This is because they both
+ came from the same library. If on the other hand, we had to
+ use an indirect symbol to get to the real symbol, we add the
+ fixup anyway, since there are cases where these symbols come
+ from different shared libraries */
if (h1 != NULL
- && (((h1->root.root.type == bfd_link_hash_defined
- || h1->root.root.type == bfd_link_hash_defweak)
- && ! bfd_is_abs_section (h1->root.root.u.def.section))
- || h2->root.root.type == bfd_link_hash_indirect))
- {
- /* See if there is a "builtin" fixup already present
- involving this symbol. If so, convert it to a regular
- fixup. In the end, this relaxes some of the requirements
- about the order of performing fixups. */
- exists = false;
- for (f1 = linux_hash_table (info)->fixup_list;
- f1 != NULL;
- f1 = f1->next)
- {
- if ((f1->h != h && f1->h != h1)
- || (! f1->builtin && ! f1->jump))
- continue;
- if (f1->h == h1)
- exists = true;
- if (! exists
- && bfd_is_abs_section (h->root.root.u.def.section))
- {
- f = new_fixup (info, h1, f1->h->root.root.u.def.value, 0);
- f->jump = is_plt;
- }
- f1->h = h1;
- f1->jump = is_plt;
- f1->builtin = 0;
- exists = true;
- }
- if (! exists
- && bfd_is_abs_section (h->root.root.u.def.section))
- {
- f = new_fixup (info, h1, h->root.root.u.def.value, 0);
- if (f == NULL)
- {
- /* FIXME: No way to return error. */
- abort ();
- }
- f->jump = is_plt;
- }
- }
+ && (((h1->root.root.type == bfd_link_hash_defined
+ || h1->root.root.type == bfd_link_hash_defweak)
+ && ! bfd_is_abs_section (h1->root.root.u.def.section))
+ || h2->root.root.type == bfd_link_hash_indirect))
+ {
+ /* See if there is a "builtin" fixup already present
+ involving this symbol. If so, convert it to a regular
+ fixup. In the end, this relaxes some of the requirements
+ about the order of performing fixups. */
+ exists = FALSE;
+ for (f1 = linux_hash_table (info)->fixup_list;
+ f1 != NULL;
+ f1 = f1->next)
+ {
+ if ((f1->h != h && f1->h != h1)
+ || (! f1->builtin && ! f1->jump))
+ continue;
+ if (f1->h == h1)
+ exists = TRUE;
+ if (! exists
+ && bfd_is_abs_section (h->root.root.u.def.section))
+ {
+ f = new_fixup (info, h1, f1->h->root.root.u.def.value, 0);
+ f->jump = is_plt;
+ }
+ f1->h = h1;
+ f1->jump = is_plt;
+ f1->builtin = 0;
+ exists = TRUE;
+ }
+ if (! exists
+ && bfd_is_abs_section (h->root.root.u.def.section))
+ {
+ f = new_fixup (info, h1, h->root.root.u.def.value, 0);
+ if (f == NULL)
+ {
+ /* FIXME: No way to return error. */
+ abort ();
+ }
+ f->jump = is_plt;
+ }
+ }
/* Quick and dirty way of stripping these symbols from the
- symtab. */
+ symtab. */
if (bfd_is_abs_section (h->root.root.u.def.section))
- h->root.written = true;
+ h->root.written = TRUE;
}
- return true;
+ return TRUE;
}
/* This is called to set the size of the .linux-dynamic section is.
@@ -556,7 +555,7 @@ linux_tally_symbols (h, data)
we just scan the hash tables to find out how many additional fixups
are required. */
-boolean
+bfd_boolean
bfd_sparclinux_size_dynamic_sections (output_bfd, info)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -565,12 +564,12 @@ bfd_sparclinux_size_dynamic_sections (output_bfd, info)
asection *s;
if (output_bfd->xvec != &MY(vec))
- return true;
+ return TRUE;
/* First find the fixups... */
linux_link_hash_traverse (linux_hash_table (info),
- linux_tally_symbols,
- (PTR) info);
+ linux_tally_symbols,
+ (PTR) info);
/* If there are builtin fixups, leave room for a marker. This is
used by the dynamic linker so that it knows that all that follow
@@ -578,40 +577,40 @@ bfd_sparclinux_size_dynamic_sections (output_bfd, info)
for (f = linux_hash_table (info)->fixup_list; f != NULL; f = f->next)
{
if (f->builtin)
- {
- ++linux_hash_table (info)->fixup_count;
- ++linux_hash_table (info)->local_builtins;
- break;
- }
+ {
+ ++linux_hash_table (info)->fixup_count;
+ ++linux_hash_table (info)->local_builtins;
+ break;
+ }
}
if (linux_hash_table (info)->dynobj == NULL)
{
if (linux_hash_table (info)->fixup_count > 0)
- abort ();
- return true;
+ abort ();
+ return TRUE;
}
/* Allocate memory for our fixup table. We will fill it in later. */
s = bfd_get_section_by_name (linux_hash_table (info)->dynobj,
- ".linux-dynamic");
+ ".linux-dynamic");
if (s != NULL)
{
s->_raw_size = linux_hash_table (info)->fixup_count + 1;
s->_raw_size *= 8;
s->contents = (bfd_byte *) bfd_zalloc (output_bfd, s->_raw_size);
if (s->contents == NULL)
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* We come here once we are ready to actually write the fixup table to
the output file. Scan the fixup tables and so forth and generate
the stuff we need. */
-static boolean
+static bfd_boolean
linux_finish_dynamic_link (output_bfd, info)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -625,18 +624,18 @@ linux_finish_dynamic_link (output_bfd, info)
unsigned int fixups_written;
if (linux_hash_table (info)->dynobj == NULL)
- return true;
+ return TRUE;
s = bfd_get_section_by_name (linux_hash_table (info)->dynobj,
- ".linux-dynamic");
+ ".linux-dynamic");
BFD_ASSERT (s != NULL);
os = s->output_section;
fixups_written = 0;
#ifdef LINUX_LINK_DEBUG
printf ("Fixup table file offset: %x VMA: %x\n",
- os->filepos + s->output_offset,
- os->vma + s->output_offset);
+ os->filepos + s->output_offset,
+ os->vma + s->output_offset);
#endif
fixup_table = s->contents;
@@ -648,16 +647,16 @@ linux_finish_dynamic_link (output_bfd, info)
for (f = linux_hash_table (info)->fixup_list; f != NULL; f = f->next)
{
if (f->builtin)
- continue;
+ continue;
if (f->h->root.root.type != bfd_link_hash_defined
- && f->h->root.root.type != bfd_link_hash_defweak)
- {
- (*_bfd_error_handler)
- (_("Symbol %s not defined for fixups\n"),
- f->h->root.root.root.string);
- continue;
- }
+ && f->h->root.root.type != bfd_link_hash_defweak)
+ {
+ (*_bfd_error_handler)
+ (_("Symbol %s not defined for fixups\n"),
+ f->h->root.root.root.string);
+ continue;
+ }
is = f->h->root.root.u.def.section;
section_offset = is->output_section->vma + is->output_offset;
@@ -665,25 +664,25 @@ linux_finish_dynamic_link (output_bfd, info)
#ifdef LINUX_LINK_DEBUG
printf ("Fixup(%d) %s: %x %x\n",f->jump, f->h->root.root.string,
- new_addr, f->value);
+ new_addr, f->value);
#endif
if (f->jump)
- {
- /* Relative address */
- new_addr = new_addr - (f->value + 5);
- bfd_put_32 (output_bfd, (bfd_vma) new_addr, fixup_table);
- fixup_table += 4;
- bfd_put_32 (output_bfd, f->value + 1, fixup_table);
- fixup_table += 4;
- }
+ {
+ /* Relative address */
+ new_addr = new_addr - (f->value + 5);
+ bfd_put_32 (output_bfd, (bfd_vma) new_addr, fixup_table);
+ fixup_table += 4;
+ bfd_put_32 (output_bfd, f->value + 1, fixup_table);
+ fixup_table += 4;
+ }
else
- {
- bfd_put_32 (output_bfd, (bfd_vma) new_addr, fixup_table);
- fixup_table += 4;
- bfd_put_32 (output_bfd, f->value, fixup_table);
- fixup_table += 4;
- }
+ {
+ bfd_put_32 (output_bfd, (bfd_vma) new_addr, fixup_table);
+ fixup_table += 4;
+ bfd_put_32 (output_bfd, f->value, fixup_table);
+ fixup_table += 4;
+ }
++fixups_written;
}
@@ -696,56 +695,56 @@ linux_finish_dynamic_link (output_bfd, info)
fixup_table += 4;
++fixups_written;
for (f = linux_hash_table (info)->fixup_list; f != NULL; f = f->next)
- {
- if (! f->builtin)
- continue;
-
- if (f->h->root.root.type != bfd_link_hash_defined
- && f->h->root.root.type != bfd_link_hash_defweak)
- {
- (*_bfd_error_handler)
- (_("Symbol %s not defined for fixups\n"),
- f->h->root.root.root.string);
- continue;
- }
-
- is = f->h->root.root.u.def.section;
- section_offset = is->output_section->vma + is->output_offset;
- new_addr = f->h->root.root.u.def.value + section_offset;
+ {
+ if (! f->builtin)
+ continue;
+
+ if (f->h->root.root.type != bfd_link_hash_defined
+ && f->h->root.root.type != bfd_link_hash_defweak)
+ {
+ (*_bfd_error_handler)
+ (_("Symbol %s not defined for fixups\n"),
+ f->h->root.root.root.string);
+ continue;
+ }
+
+ is = f->h->root.root.u.def.section;
+ section_offset = is->output_section->vma + is->output_offset;
+ new_addr = f->h->root.root.u.def.value + section_offset;
#ifdef LINUX_LINK_DEBUG
- printf ("Fixup(B) %s: %x %x\n", f->h->root.root.string,
- new_addr, f->value);
+ printf ("Fixup(B) %s: %x %x\n", f->h->root.root.string,
+ new_addr, f->value);
#endif
- bfd_put_32 (output_bfd, (bfd_vma) new_addr, fixup_table);
- fixup_table += 4;
- bfd_put_32 (output_bfd, f->value, fixup_table);
- fixup_table += 4;
- ++fixups_written;
- }
- }
+ bfd_put_32 (output_bfd, (bfd_vma) new_addr, fixup_table);
+ fixup_table += 4;
+ bfd_put_32 (output_bfd, f->value, fixup_table);
+ fixup_table += 4;
+ ++fixups_written;
+ }
+ }
if (linux_hash_table (info)->fixup_count != fixups_written)
{
(*_bfd_error_handler) (_("Warning: fixup count mismatch\n"));
while (linux_hash_table (info)->fixup_count > fixups_written)
- {
- bfd_put_32 (output_bfd, (bfd_vma) 0, fixup_table);
- fixup_table += 4;
- bfd_put_32 (output_bfd, (bfd_vma) 0, fixup_table);
- fixup_table += 4;
- ++fixups_written;
- }
+ {
+ bfd_put_32 (output_bfd, (bfd_vma) 0, fixup_table);
+ fixup_table += 4;
+ bfd_put_32 (output_bfd, (bfd_vma) 0, fixup_table);
+ fixup_table += 4;
+ ++fixups_written;
+ }
}
h = linux_link_hash_lookup (linux_hash_table (info),
- "__BUILTIN_FIXUPS__",
- false, false, false);
+ "__BUILTIN_FIXUPS__",
+ FALSE, FALSE, FALSE);
if (h != NULL
&& (h->root.root.type == bfd_link_hash_defined
- || h->root.root.type == bfd_link_hash_defweak))
+ || h->root.root.type == bfd_link_hash_defweak))
{
is = h->root.root.u.def.section;
section_offset = is->output_section->vma + is->output_offset;
@@ -762,13 +761,12 @@ linux_finish_dynamic_link (output_bfd, info)
if (bfd_seek (output_bfd, (file_ptr) (os->filepos + s->output_offset),
SEEK_SET) != 0)
- return false;
+ return FALSE;
- if (bfd_bwrite ((PTR) s->contents, s->_raw_size, output_bfd)
- != s->_raw_size)
- return false;
+ if (bfd_bwrite ((PTR) s->contents, s->_raw_size, output_bfd) != s->_raw_size)
+ return FALSE;
- return true;
+ return TRUE;
}
#define MY_bfd_link_hash_table_create linux_link_hash_table_create
diff --git a/contrib/binutils/bfd/sparcnetbsd.c b/contrib/binutils/bfd/sparcnetbsd.c
index 64d0eb1..be8e536 100644
--- a/contrib/binutils/bfd/sparcnetbsd.c
+++ b/contrib/binutils/bfd/sparcnetbsd.c
@@ -1,5 +1,5 @@
/* BFD back-end for NetBSD/sparc a.out-ish binaries.
- Copyright 1990, 1991, 1992, 1994, 1995, 1997, 1998, 2000, 2001
+ Copyright 1990, 1991, 1992, 1994, 1995, 1997, 1998, 2000, 2001, 2003
Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -18,7 +18,6 @@ You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-#define BYTES_IN_WORD 4
#define TARGET_IS_BIG_ENDIAN_P
/* SPARC chips use either 4K or 8K pages, but object files always
diff --git a/contrib/binutils/bfd/srec.c b/contrib/binutils/bfd/srec.c
index 6c29fa1..c0a3d58 100644
--- a/contrib/binutils/bfd/srec.c
+++ b/contrib/binutils/bfd/srec.c
@@ -1,6 +1,6 @@
/* BFD back-end for s-record objects.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Steve Chamberlain of Cygnus Support <sac@cygnus.com>.
@@ -114,32 +114,31 @@ static void srec_get_symbol_info PARAMS ((bfd *, asymbol *, symbol_info *));
static void srec_print_symbol
PARAMS ((bfd *, PTR, asymbol *, bfd_print_symbol_type));
static void srec_init PARAMS ((void));
-static boolean srec_mkobject PARAMS ((bfd *));
-static int srec_get_byte PARAMS ((bfd *, boolean *));
-static void srec_bad_byte PARAMS ((bfd *, unsigned int, int, boolean));
-static boolean srec_scan PARAMS ((bfd *));
+static bfd_boolean srec_mkobject PARAMS ((bfd *));
+static int srec_get_byte PARAMS ((bfd *, bfd_boolean *));
+static void srec_bad_byte PARAMS ((bfd *, unsigned int, int, bfd_boolean));
+static bfd_boolean srec_scan PARAMS ((bfd *));
static const bfd_target *srec_object_p PARAMS ((bfd *));
static const bfd_target *symbolsrec_object_p PARAMS ((bfd *));
-static boolean srec_read_section PARAMS ((bfd *, asection *, bfd_byte *));
-
-static boolean srec_write_record PARAMS ((bfd *, unsigned int, bfd_vma,
- const bfd_byte *,
- const bfd_byte *));
-static boolean srec_write_header PARAMS ((bfd *));
-static boolean srec_write_symbols PARAMS ((bfd *));
-static boolean srec_new_symbol PARAMS ((bfd *, const char *, bfd_vma));
-static boolean srec_get_section_contents
+static bfd_boolean srec_read_section PARAMS ((bfd *, asection *, bfd_byte *));
+
+static bfd_boolean srec_write_record
+ PARAMS ((bfd *, unsigned int, bfd_vma, const bfd_byte *, const bfd_byte *));
+static bfd_boolean srec_write_header PARAMS ((bfd *));
+static bfd_boolean srec_write_symbols PARAMS ((bfd *));
+static bfd_boolean srec_new_symbol PARAMS ((bfd *, const char *, bfd_vma));
+static bfd_boolean srec_get_section_contents
PARAMS ((bfd *, asection *, PTR, file_ptr, bfd_size_type));
-static boolean srec_set_arch_mach
+static bfd_boolean srec_set_arch_mach
PARAMS ((bfd *, enum bfd_architecture, unsigned long));
-static boolean srec_set_section_contents
- PARAMS ((bfd *, sec_ptr, PTR, file_ptr, bfd_size_type));
-static boolean internal_srec_write_object_contents PARAMS ((bfd *, int));
-static boolean srec_write_object_contents PARAMS ((bfd *));
-static boolean symbolsrec_write_object_contents PARAMS ((bfd *));
-static int srec_sizeof_headers PARAMS ((bfd *, boolean));
+static bfd_boolean srec_set_section_contents
+ PARAMS ((bfd *, sec_ptr, const PTR, file_ptr, bfd_size_type));
+static bfd_boolean internal_srec_write_object_contents PARAMS ((bfd *, int));
+static bfd_boolean srec_write_object_contents PARAMS ((bfd *));
+static bfd_boolean symbolsrec_write_object_contents PARAMS ((bfd *));
+static int srec_sizeof_headers PARAMS ((bfd *, bfd_boolean));
static long srec_get_symtab_upper_bound PARAMS ((bfd *));
-static long srec_get_symtab PARAMS ((bfd *, asymbol **));
+static long srec_canonicalize_symtab PARAMS ((bfd *, asymbol **));
/* Macros for converting between hex and binary. */
@@ -158,11 +157,11 @@ static const char digs[] = "0123456789ABCDEF";
static void
srec_init ()
{
- static boolean inited = false;
+ static bfd_boolean inited = FALSE;
if (! inited)
{
- inited = true;
+ inited = TRUE;
hex_init ();
}
}
@@ -181,7 +180,7 @@ unsigned int Chunk = DEFAULT_CHUNK;
/* The type of srec output (free or forced to S3).
This variable can be modified by objcopy's --srec-forceS3
parameter. */
-boolean S3Forced = false;
+bfd_boolean S3Forced = FALSE;
/* When writing an S-record file, the S-records can not be output as
they are seen. This structure is used to hold them in memory. */
@@ -220,13 +219,14 @@ typedef struct srec_data_struct
}
tdata_type;
-static boolean srec_write_section PARAMS ((bfd *, tdata_type *,
- srec_data_list_type *));
-static boolean srec_write_terminator PARAMS ((bfd *, tdata_type *));
+static bfd_boolean srec_write_section
+ PARAMS ((bfd *, tdata_type *, srec_data_list_type *));
+static bfd_boolean srec_write_terminator
+ PARAMS ((bfd *, tdata_type *));
/* Set up the S-record tdata information. */
-static boolean
+static bfd_boolean
srec_mkobject (abfd)
bfd *abfd;
{
@@ -238,8 +238,8 @@ srec_mkobject (abfd)
amt = sizeof (tdata_type);
tdata = (tdata_type *) bfd_alloc (abfd, amt);
if (tdata == NULL)
- return false;
-
+ return FALSE;
+
abfd->tdata.srec_data = tdata;
tdata->type = 1;
tdata->head = NULL;
@@ -248,7 +248,7 @@ srec_mkobject (abfd)
tdata->symtail = NULL;
tdata->csymbols = NULL;
- return true;
+ return TRUE;
}
/* Read a byte from an S record file. Set *ERRORPTR if an error
@@ -257,14 +257,14 @@ srec_mkobject (abfd)
static int
srec_get_byte (abfd, errorptr)
bfd *abfd;
- boolean *errorptr;
+ bfd_boolean *errorptr;
{
bfd_byte c;
if (bfd_bread (&c, (bfd_size_type) 1, abfd) != 1)
{
if (bfd_get_error () != bfd_error_file_truncated)
- *errorptr = true;
+ *errorptr = TRUE;
return EOF;
}
@@ -280,7 +280,7 @@ srec_bad_byte (abfd, lineno, c, error)
bfd *abfd;
unsigned int lineno;
int c;
- boolean error;
+ bfd_boolean error;
{
if (c == EOF)
{
@@ -307,7 +307,7 @@ srec_bad_byte (abfd, lineno, c, error)
/* Add a new symbol found in an S-record file. */
-static boolean
+static bfd_boolean
srec_new_symbol (abfd, name, val)
bfd *abfd;
const char *name;
@@ -318,7 +318,7 @@ srec_new_symbol (abfd, name, val)
n = (struct srec_symbol *) bfd_alloc (abfd, amt);
if (n == NULL)
- return false;
+ return FALSE;
n->name = name;
n->val = val;
@@ -332,19 +332,19 @@ srec_new_symbol (abfd, name, val)
++abfd->symcount;
- return true;
+ return TRUE;
}
/* Read the S record file and turn it into sections. We create a new
section for each contiguous set of bytes. */
-static boolean
+static bfd_boolean
srec_scan (abfd)
bfd *abfd;
{
int c;
unsigned int lineno = 1;
- boolean error = false;
+ bfd_boolean error = FALSE;
bfd_byte *buf = NULL;
size_t bufsize = 0;
asection *sec = NULL;
@@ -356,7 +356,7 @@ srec_scan (abfd)
while ((c = srec_get_byte (abfd, &error)) != EOF)
{
/* We only build sections from contiguous S-records, so if this
- is not an S-record, then stop building a section. */
+ is not an S-record, then stop building a section. */
if (c != 'S' && c != '\r' && c != '\n')
sec = NULL;
@@ -542,7 +542,7 @@ srec_scan (abfd)
case '0':
case '5':
/* Prologue--ignore the file name, but stop building a
- section at this point. */
+ section at this point. */
sec = NULL;
break;
@@ -567,7 +567,7 @@ srec_scan (abfd)
&& sec->vma + sec->_raw_size == address)
{
/* This data goes at the end of the section we are
- currently building. */
+ currently building. */
sec->_raw_size += bytes;
}
else
@@ -612,7 +612,7 @@ srec_scan (abfd)
if (buf != NULL)
free (buf);
- return true;
+ return TRUE;
}
}
break;
@@ -625,14 +625,14 @@ srec_scan (abfd)
if (buf != NULL)
free (buf);
- return true;
+ return TRUE;
error_return:
if (symbuf != NULL)
free (symbuf);
if (buf != NULL)
free (buf);
- return false;
+ return FALSE;
}
/* Check whether an existing file is an S-record file. */
@@ -709,7 +709,7 @@ symbolsrec_object_p (abfd)
/* Read in the contents of a section in an S-record file. */
-static boolean
+static bfd_boolean
srec_read_section (abfd, section, contents)
bfd *abfd;
asection *section;
@@ -717,7 +717,7 @@ srec_read_section (abfd, section, contents)
{
int c;
bfd_size_type sofar = 0;
- boolean error = false;
+ bfd_boolean error = FALSE;
bfd_byte *buf = NULL;
size_t bufsize = 0;
@@ -735,7 +735,7 @@ srec_read_section (abfd, section, contents)
continue;
/* This is called after srec_scan has already been called, so we
- ought to know the exact format. */
+ ought to know the exact format. */
BFD_ASSERT (c == 'S');
if (bfd_bread (hdr, (bfd_size_type) 3, abfd) != 3)
@@ -766,7 +766,7 @@ srec_read_section (abfd, section, contents)
BFD_ASSERT (sofar == section->_raw_size);
if (buf != NULL)
free (buf);
- return true;
+ return TRUE;
case '3':
address = HEX (data);
@@ -791,7 +791,7 @@ srec_read_section (abfd, section, contents)
BFD_ASSERT (sofar == section->_raw_size);
if (buf != NULL)
free (buf);
- return true;
+ return TRUE;
}
/* Don't consider checksum. */
@@ -816,17 +816,17 @@ srec_read_section (abfd, section, contents)
if (buf != NULL)
free (buf);
- return true;
+ return TRUE;
error_return:
if (buf != NULL)
free (buf);
- return false;
+ return FALSE;
}
/* Get the contents of a section in an S-record file. */
-static boolean
+static bfd_boolean
srec_get_section_contents (abfd, section, location, offset, count)
bfd *abfd;
asection *section;
@@ -838,21 +838,21 @@ srec_get_section_contents (abfd, section, location, offset, count)
{
section->used_by_bfd = bfd_alloc (abfd, section->_raw_size);
if (section->used_by_bfd == NULL && section->_raw_size != 0)
- return false;
+ return FALSE;
if (! srec_read_section (abfd, section, section->used_by_bfd))
- return false;
+ return FALSE;
}
memcpy (location, (bfd_byte *) section->used_by_bfd + offset,
(size_t) count);
- return true;
+ return TRUE;
}
/* Set the architecture. We accept an unknown architecture here. */
-static boolean
+static bfd_boolean
srec_set_arch_mach (abfd, arch, mach)
bfd *abfd;
enum bfd_architecture arch;
@@ -861,18 +861,18 @@ srec_set_arch_mach (abfd, arch, mach)
if (arch == bfd_arch_unknown)
{
abfd->arch_info = &bfd_default_arch_struct;
- return true;
+ return TRUE;
}
return bfd_default_set_arch_mach (abfd, arch, mach);
}
/* We have to save up all the Srecords for a splurge before output. */
-static boolean
+static bfd_boolean
srec_set_section_contents (abfd, section, location, offset, bytes_to_do)
bfd *abfd;
sec_ptr section;
- PTR location;
+ const PTR location;
file_ptr offset;
bfd_size_type bytes_to_do;
{
@@ -882,7 +882,7 @@ srec_set_section_contents (abfd, section, location, offset, bytes_to_do)
entry = ((srec_data_list_type *)
bfd_alloc (abfd, (bfd_size_type) sizeof (srec_data_list_type)));
if (entry == NULL)
- return false;
+ return FALSE;
if (bytes_to_do
&& (section->flags & SEC_ALLOC)
@@ -892,10 +892,10 @@ srec_set_section_contents (abfd, section, location, offset, bytes_to_do)
data = (bfd_byte *) bfd_alloc (abfd, bytes_to_do);
if (data == NULL)
- return false;
+ return FALSE;
memcpy ((PTR) data, location, (size_t) bytes_to_do);
- /* Ff S3Forced is true then always select S3 records,
+ /* Ff S3Forced is TRUE then always select S3 records,
regardless of the siez of the addresses. */
if (S3Forced)
tdata->type = 3;
@@ -912,7 +912,7 @@ srec_set_section_contents (abfd, section, location, offset, bytes_to_do)
entry->size = bytes_to_do;
/* Sort the records by address. Optimize for the common case of
- adding a record to the end of the list. */
+ adding a record to the end of the list. */
if (tdata->tail != NULL
&& entry->where >= tdata->tail->where)
{
@@ -934,14 +934,14 @@ srec_set_section_contents (abfd, section, location, offset, bytes_to_do)
tdata->tail = entry;
}
}
- return true;
+ return TRUE;
}
/* Write a record of type, of the supplied number of bytes. The
supplied bytes and length don't have a checksum. That's worked out
here. */
-static boolean
+static bfd_boolean
srec_write_record (abfd, type, address, data, end)
bfd *abfd;
unsigned int type;
@@ -999,17 +999,17 @@ srec_write_record (abfd, type, address, data, end)
*dst++ = '\n';
wrlen = dst - buffer;
if (bfd_bwrite ((PTR) buffer, wrlen, abfd) != wrlen)
- return false;
- return true;
+ return FALSE;
+ return TRUE;
}
-static boolean
+static bfd_boolean
srec_write_header (abfd)
bfd *abfd;
{
unsigned int len = strlen (abfd->filename);
- /* I'll put an arbitary 40 char limit on header size. */
+ /* I'll put an arbitrary 40 char limit on header size. */
if (len > 40)
len = 40;
@@ -1017,7 +1017,7 @@ srec_write_header (abfd)
abfd->filename, abfd->filename + len);
}
-static boolean
+static bfd_boolean
srec_write_section (abfd, tdata, list)
bfd *abfd;
tdata_type *tdata;
@@ -1052,16 +1052,16 @@ srec_write_section (abfd, tdata, list)
address,
location,
location + octets_this_chunk))
- return false;
+ return FALSE;
octets_written += octets_this_chunk;
location += octets_this_chunk;
}
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
srec_write_terminator (abfd, tdata)
bfd *abfd;
tdata_type *tdata;
@@ -1070,7 +1070,7 @@ srec_write_terminator (abfd, tdata)
abfd->start_address, NULL, NULL);
}
-static boolean
+static bfd_boolean
srec_write_symbols (abfd)
bfd *abfd;
{
@@ -1086,7 +1086,7 @@ srec_write_symbols (abfd)
if (bfd_bwrite ("$$ ", (bfd_size_type) 3, abfd) != 3
|| bfd_bwrite (abfd->filename, len, abfd) != len
|| bfd_bwrite ("\r\n", (bfd_size_type) 2, abfd) != 2)
- return false;
+ return FALSE;
for (i = 0; i < count; i++)
{
@@ -1095,36 +1095,37 @@ srec_write_symbols (abfd)
&& (s->flags & BSF_DEBUGGING) == 0)
{
/* Just dump out non debug symbols. */
- char buf[42], *p;
+ char buf[43], *p;
len = strlen (s->name);
if (bfd_bwrite (" ", (bfd_size_type) 2, abfd) != 2
|| bfd_bwrite (s->name, len, abfd) != len)
- return false;
+ return FALSE;
- sprintf_vma (buf + 1, (s->value
+ sprintf_vma (buf + 2, (s->value
+ s->section->output_section->lma
+ s->section->output_offset));
- p = buf + 1;
+ p = buf + 2;
while (p[0] == '0' && p[1] != 0)
p++;
len = strlen (p);
p[len] = '\r';
p[len + 1] = '\n';
+ *--p = '$';
*--p = ' ';
- len += 3;
+ len += 4;
if (bfd_bwrite (p, len, abfd) != len)
- return false;
+ return FALSE;
}
}
if (bfd_bwrite ("$$ \r\n", (bfd_size_type) 5, abfd) != 5)
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
-static boolean
+static bfd_boolean
internal_srec_write_object_contents (abfd, symbols)
bfd *abfd;
int symbols;
@@ -1135,11 +1136,11 @@ internal_srec_write_object_contents (abfd, symbols)
if (symbols)
{
if (! srec_write_symbols (abfd))
- return false;
+ return FALSE;
}
if (! srec_write_header (abfd))
- return false;
+ return FALSE;
/* Now wander though all the sections provided and output them. */
list = tdata->head;
@@ -1147,20 +1148,20 @@ internal_srec_write_object_contents (abfd, symbols)
while (list != (srec_data_list_type *) NULL)
{
if (! srec_write_section (abfd, tdata, list))
- return false;
+ return FALSE;
list = list->next;
}
return srec_write_terminator (abfd, tdata);
}
-static boolean
+static bfd_boolean
srec_write_object_contents (abfd)
bfd *abfd;
{
return internal_srec_write_object_contents (abfd, 0);
}
-static boolean
+static bfd_boolean
symbolsrec_write_object_contents (abfd)
bfd *abfd;
{
@@ -1170,7 +1171,7 @@ symbolsrec_write_object_contents (abfd)
static int
srec_sizeof_headers (abfd, exec)
bfd *abfd ATTRIBUTE_UNUSED;
- boolean exec ATTRIBUTE_UNUSED;
+ bfd_boolean exec ATTRIBUTE_UNUSED;
{
return 0;
}
@@ -1187,7 +1188,7 @@ srec_get_symtab_upper_bound (abfd)
/* Return the symbol table. */
static long
-srec_get_symtab (abfd, alocation)
+srec_canonicalize_symtab (abfd, alocation)
bfd *abfd;
asymbol **alocation;
{
@@ -1203,7 +1204,7 @@ srec_get_symtab (abfd, alocation)
csymbols = (asymbol *) bfd_alloc (abfd, symcount * sizeof (asymbol));
if (csymbols == NULL && symcount != 0)
- return (long) false;
+ return 0;
abfd->tdata.srec_data->csymbols = csymbols;
for (s = abfd->tdata.srec_data->symbols, c = csymbols;
diff --git a/contrib/binutils/bfd/stabs.c b/contrib/binutils/bfd/stabs.c
index 0cb3741..04b91f6 100644
--- a/contrib/binutils/bfd/stabs.c
+++ b/contrib/binutils/bfd/stabs.c
@@ -1,23 +1,23 @@
/* Stabs in sections linking support.
- Copyright 1996, 1997, 1998, 1999, 2000, 2001
+ Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* This file contains support for linking stabs in sections, as used
on COFF and ELF. */
@@ -56,12 +56,19 @@ struct stab_link_includes_table
};
/* A linked list of totals that we have found for a particular header
- file. */
+ file. A total is a unique identifier for a particular BINCL...EINCL
+ sequence of STABs that can be used to identify duplicate sequences.
+ It consists of three fields, 'sum_chars' which is the sum of all the
+ STABS characters; 'num_chars' which is the number of these charactes
+ and 'symb' which is a buffer of all the symbols in the sequence. This
+ buffer is only checked as a last resort. */
struct stab_link_includes_totals
{
struct stab_link_includes_totals *next;
- bfd_vma total;
+ bfd_vma sum_chars; /* Accumulated sum of STABS characters. */
+ bfd_vma num_chars; /* Number of STABS characters. */
+ const char* symb; /* The STABS characters themselves. */
};
/* An entry in the header file hash table. */
@@ -168,15 +175,16 @@ stab_link_includes_newfunc (entry, table, string)
/* This function is called for each input file from the add_symbols
pass of the linker. */
-boolean
-_bfd_link_section_stabs (abfd, psinfo, stabsec, stabstrsec, psecinfo)
+bfd_boolean
+_bfd_link_section_stabs (abfd, psinfo, stabsec, stabstrsec, psecinfo, pstring_offset)
bfd *abfd;
PTR *psinfo;
asection *stabsec;
asection *stabstrsec;
PTR *psecinfo;
+ bfd_size_type *pstring_offset;
{
- boolean first;
+ bfd_boolean first;
struct stab_info *sinfo;
bfd_size_type count, amt;
struct stab_section_info *secinfo;
@@ -190,21 +198,21 @@ _bfd_link_section_stabs (abfd, psinfo, stabsec, stabstrsec, psecinfo)
|| stabstrsec->_raw_size == 0)
{
/* This file does not contain stabs debugging information. */
- return true;
+ return TRUE;
}
if (stabsec->_raw_size % STABSIZE != 0)
{
/* Something is wrong with the format of these stab symbols.
- Don't try to optimize them. */
- return true;
+ Don't try to optimize them. */
+ return TRUE;
}
if ((stabstrsec->flags & SEC_RELOC) != 0)
{
/* We shouldn't see relocations in the strings, and we aren't
- prepared to handle them. */
- return true;
+ prepared to handle them. */
+ return TRUE;
}
if ((stabsec->output_section != NULL
@@ -213,16 +221,16 @@ _bfd_link_section_stabs (abfd, psinfo, stabsec, stabstrsec, psecinfo)
&& bfd_is_abs_section (stabstrsec->output_section)))
{
/* At least one of the sections is being discarded from the
- link, so we should just ignore them. */
- return true;
+ link, so we should just ignore them. */
+ return TRUE;
}
- first = false;
+ first = FALSE;
if (*psinfo == NULL)
{
/* Initialize the stabs information we need to keep track of. */
- first = true;
+ first = TRUE;
amt = sizeof (struct stab_info);
*psinfo = (PTR) bfd_alloc (abfd, amt);
if (*psinfo == NULL)
@@ -232,7 +240,7 @@ _bfd_link_section_stabs (abfd, psinfo, stabsec, stabstrsec, psecinfo)
if (sinfo->strings == NULL)
goto error_return;
/* Make sure the first byte is zero. */
- (void) _bfd_stringtab_add (sinfo->strings, "", true, true);
+ (void) _bfd_stringtab_add (sinfo->strings, "", TRUE, TRUE);
if (! bfd_hash_table_init_n (&sinfo->includes.root,
stab_link_includes_newfunc,
251))
@@ -276,7 +284,11 @@ _bfd_link_section_stabs (abfd, psinfo, stabsec, stabstrsec, psecinfo)
and identify N_BINCL symbols which can be eliminated. */
stroff = 0;
- next_stroff = 0;
+ /* The stabs sections can be split when
+ -split-by-reloc/-split-by-file is used. We must keep track of
+ each stab section's place in the single concatenated string
+ table. */
+ next_stroff = pstring_offset ? *pstring_offset : 0;
skip = 0;
symend = stabbuf + stabsec->_raw_size;
@@ -299,16 +311,18 @@ _bfd_link_section_stabs (abfd, psinfo, stabsec, stabstrsec, psecinfo)
if (type == 0)
{
/* Special type 0 stabs indicate the offset to the next
- string table. We only copy the very first one. */
+ string table. We only copy the very first one. */
stroff = next_stroff;
next_stroff += bfd_get_32 (abfd, sym + 8);
+ if (pstring_offset)
+ *pstring_offset = next_stroff;
if (! first)
{
*pstridx = (bfd_size_type) -1;
++skip;
continue;
}
- first = false;
+ first = FALSE;
}
/* Store the string in the hash table, and record the index. */
@@ -324,7 +338,7 @@ _bfd_link_section_stabs (abfd, psinfo, stabsec, stabstrsec, psecinfo)
goto error_return;
}
string = (char *) stabstrbuf + symstroff;
- *pstridx = _bfd_stringtab_add (sinfo->strings, string, true, true);
+ *pstridx = _bfd_stringtab_add (sinfo->strings, string, TRUE, TRUE);
/* An N_BINCL symbol indicates the start of the stabs entries
for a header file. We need to scan ahead to the next N_EINCL
@@ -333,15 +347,21 @@ _bfd_link_section_stabs (abfd, psinfo, stabsec, stabstrsec, psecinfo)
first number after an open parenthesis). */
if (type == (int) N_BINCL)
{
- bfd_vma val;
+ bfd_vma sum_chars;
+ bfd_vma num_chars;
+ bfd_vma buf_len = 0;
+ char * symb;
+ char * symb_rover;
int nest;
- bfd_byte *incl_sym;
- struct stab_link_includes_entry *incl_entry;
- struct stab_link_includes_totals *t;
- struct stab_excl_list *ne;
+ bfd_byte * incl_sym;
+ struct stab_link_includes_entry * incl_entry;
+ struct stab_link_includes_totals * t;
+ struct stab_excl_list * ne;
- val = 0;
+ symb = symb_rover = NULL;
+ sum_chars = num_chars = 0;
nest = 0;
+
for (incl_sym = sym + STABSIZE;
incl_sym < symend;
incl_sym += STABSIZE)
@@ -351,6 +371,8 @@ _bfd_link_section_stabs (abfd, psinfo, stabsec, stabstrsec, psecinfo)
incl_type = incl_sym[TYPEOFF];
if (incl_type == 0)
break;
+ else if (incl_type == (int) N_EXCL)
+ continue;
else if (incl_type == (int) N_EINCL)
{
if (nest == 0)
@@ -368,7 +390,17 @@ _bfd_link_section_stabs (abfd, psinfo, stabsec, stabstrsec, psecinfo)
+ bfd_get_32 (abfd, incl_sym + STRDXOFF));
for (; *str != '\0'; str++)
{
- val += *str;
+ if (num_chars >= buf_len)
+ {
+ buf_len += 32 * 1024;
+ symb = bfd_realloc (symb, buf_len);
+ if (symb == NULL)
+ goto error_return;
+ symb_rover = symb + num_chars;
+ }
+ * symb_rover ++ = * str;
+ sum_chars += *str;
+ num_chars ++;
if (*str == '(')
{
/* Skip the file number. */
@@ -381,25 +413,29 @@ _bfd_link_section_stabs (abfd, psinfo, stabsec, stabstrsec, psecinfo)
}
}
+ BFD_ASSERT (num_chars == (bfd_vma) (symb_rover - symb));
+
/* If we have already included a header file with the same
value, then replaced this one with an N_EXCL symbol. */
incl_entry = stab_link_includes_lookup (&sinfo->includes, string,
- true, true);
+ TRUE, TRUE);
if (incl_entry == NULL)
goto error_return;
for (t = incl_entry->totals; t != NULL; t = t->next)
- if (t->total == val)
+ if (t->sum_chars == sum_chars
+ && t->num_chars == num_chars
+ && memcmp (t->symb, symb, num_chars) == 0)
break;
/* Record this symbol, so that we can set the value
- correctly. */
+ correctly. */
amt = sizeof *ne;
ne = (struct stab_excl_list *) bfd_alloc (abfd, amt);
if (ne == NULL)
goto error_return;
ne->offset = sym - stabbuf;
- ne->val = val;
+ ne->val = sum_chars;
ne->type = (int) N_BINCL;
ne->next = secinfo->excls;
secinfo->excls = ne;
@@ -412,7 +448,9 @@ _bfd_link_section_stabs (abfd, psinfo, stabsec, stabstrsec, psecinfo)
bfd_hash_allocate (&sinfo->includes.root, sizeof *t));
if (t == NULL)
goto error_return;
- t->total = val;
+ t->sum_chars = sum_chars;
+ t->num_chars = num_chars;
+ t->symb = bfd_realloc (symb, num_chars); /* Trim data down. */
t->next = incl_entry->totals;
incl_entry->totals = t;
}
@@ -424,6 +462,9 @@ _bfd_link_section_stabs (abfd, psinfo, stabsec, stabstrsec, psecinfo)
pass to change the type to N_EXCL. */
ne->type = (int) N_EXCL;
+ /* Free off superfluous symbols. */
+ free (symb);
+
/* Mark the skipped symbols. */
nest = 0;
@@ -447,6 +488,9 @@ _bfd_link_section_stabs (abfd, psinfo, stabsec, stabstrsec, psecinfo)
}
else if (incl_type == (int) N_BINCL)
++nest;
+ else if (incl_type == (int) N_EXCL)
+ /* Keep existing exclusion marks. */
+ continue;
else if (nest == 0)
{
*incl_pstridx = (bfd_size_type) -1;
@@ -502,30 +546,30 @@ _bfd_link_section_stabs (abfd, psinfo, stabsec, stabstrsec, psecinfo)
BFD_ASSERT (offset != 0);
}
- return true;
+ return TRUE;
error_return:
if (stabbuf != NULL)
free (stabbuf);
if (stabstrbuf != NULL)
free (stabstrbuf);
- return false;
+ return FALSE;
}
/* This function is called for each input file before the stab
section is relocated. It discards stab entries for discarded
- functions and variables. The function returns true iff
+ functions and variables. The function returns TRUE iff
any entries have been deleted.
*/
-boolean
+bfd_boolean
_bfd_discard_section_stabs (abfd, stabsec, psecinfo,
reloc_symbol_deleted_p, cookie)
bfd *abfd;
asection *stabsec;
PTR psecinfo;
- boolean (*reloc_symbol_deleted_p) PARAMS ((bfd_vma, PTR));
+ bfd_boolean (*reloc_symbol_deleted_p) PARAMS ((bfd_vma, PTR));
PTR cookie;
{
bfd_size_type count, amt;
@@ -539,29 +583,29 @@ _bfd_discard_section_stabs (abfd, stabsec, psecinfo,
if (stabsec->_raw_size == 0)
{
/* This file does not contain stabs debugging information. */
- return false;
+ return FALSE;
}
if (stabsec->_raw_size % STABSIZE != 0)
{
/* Something is wrong with the format of these stab symbols.
- Don't try to optimize them. */
- return false;
+ Don't try to optimize them. */
+ return FALSE;
}
if ((stabsec->output_section != NULL
&& bfd_is_abs_section (stabsec->output_section)))
{
/* At least one of the sections is being discarded from the
- link, so we should just ignore them. */
- return false;
+ link, so we should just ignore them. */
+ return FALSE;
}
/* We should have initialized our data in _bfd_link_stab_sections.
If there was some bizarre error reading the string sections, though,
we might not have. Bail rather than asserting. */
if (psecinfo == NULL)
- return false;
+ return FALSE;
count = stabsec->_raw_size / STABSIZE;
secinfo = (struct stab_section_info *) psecinfo;
@@ -674,18 +718,18 @@ _bfd_discard_section_stabs (abfd, stabsec, psecinfo,
BFD_ASSERT (offset != 0);
}
- return (boolean) (skip > 0);
+ return skip > 0;
error_return:
if (stabbuf != NULL)
free (stabbuf);
- return false;
+ return FALSE;
}
/* Write out the stab section. This is called with the relocated
contents. */
-boolean
+bfd_boolean
_bfd_write_section_stabs (output_bfd, psinfo, stabsec, psecinfo, contents)
bfd *output_bfd;
PTR *psinfo;
@@ -736,9 +780,9 @@ _bfd_write_section_stabs (output_bfd, psinfo, stabsec, psecinfo, contents)
if (sym[TYPEOFF] == 0)
{
/* This is the header symbol for the stabs section. We
- don't really need one, since we have merged all the
- input stabs sections into one, but we generate one
- for the benefit of readers which expect to see one. */
+ don't really need one, since we have merged all the
+ input stabs sections into one, but we generate one
+ for the benefit of readers which expect to see one. */
BFD_ASSERT (sym == contents);
bfd_put_32 (output_bfd, _bfd_stringtab_size (sinfo->strings),
tosym + VALOFF);
@@ -760,7 +804,7 @@ _bfd_write_section_stabs (output_bfd, psinfo, stabsec, psecinfo, contents)
/* Write out the .stabstr section. */
-boolean
+bfd_boolean
_bfd_write_stab_strings (output_bfd, psinfo)
bfd *output_bfd;
PTR *psinfo;
@@ -770,12 +814,12 @@ _bfd_write_stab_strings (output_bfd, psinfo)
sinfo = (struct stab_info *) *psinfo;
if (sinfo == NULL)
- return true;
+ return TRUE;
if (bfd_is_abs_section (sinfo->stabstr->output_section))
{
/* The section was discarded from the link. */
- return true;
+ return TRUE;
}
BFD_ASSERT ((sinfo->stabstr->output_offset
@@ -786,16 +830,16 @@ _bfd_write_stab_strings (output_bfd, psinfo)
(file_ptr) (sinfo->stabstr->output_section->filepos
+ sinfo->stabstr->output_offset),
SEEK_SET) != 0)
- return false;
+ return FALSE;
if (! _bfd_stringtab_emit (output_bfd, sinfo->strings))
- return false;
+ return FALSE;
/* We no longer need the stabs information. */
_bfd_stringtab_free (sinfo->strings);
bfd_hash_table_free (&sinfo->includes.root);
- return true;
+ return TRUE;
}
/* Adjust an address in the .stab section. Given OFFSET within
diff --git a/contrib/binutils/bfd/sunos.c b/contrib/binutils/bfd/sunos.c
index 5fec6f9..5b1b18b 100644
--- a/contrib/binutils/bfd/sunos.c
+++ b/contrib/binutils/bfd/sunos.c
@@ -1,7 +1,6 @@
/* BFD backend for SunOS binaries.
Copyright 1990, 1991, 1992, 1994, 1995, 1996, 1997, 1998, 2000, 2001,
- 2002
- Free Software Foundation, Inc.
+ 2002, 2003 Free Software Foundation, Inc.
Written by Cygnus Support.
This file is part of BFD, the Binary File Descriptor library.
@@ -33,9 +32,9 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* Static routines defined in this file. */
-static boolean sunos_read_dynamic_info PARAMS ((bfd *));
+static bfd_boolean sunos_read_dynamic_info PARAMS ((bfd *));
static long sunos_get_dynamic_symtab_upper_bound PARAMS ((bfd *));
-static boolean sunos_slurp_dynamic_symtab PARAMS ((bfd *));
+static bfd_boolean sunos_slurp_dynamic_symtab PARAMS ((bfd *));
static long sunos_canonicalize_dynamic_symtab PARAMS ((bfd *, asymbol **));
static long sunos_get_dynamic_reloc_upper_bound PARAMS ((bfd *));
static long sunos_canonicalize_dynamic_reloc
@@ -44,32 +43,32 @@ static struct bfd_hash_entry *sunos_link_hash_newfunc
PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
static struct bfd_link_hash_table *sunos_link_hash_table_create
PARAMS ((bfd *));
-static boolean sunos_create_dynamic_sections
- PARAMS ((bfd *, struct bfd_link_info *, boolean));
-static boolean sunos_add_dynamic_symbols
+static bfd_boolean sunos_create_dynamic_sections
+ PARAMS ((bfd *, struct bfd_link_info *, bfd_boolean));
+static bfd_boolean sunos_add_dynamic_symbols
PARAMS ((bfd *, struct bfd_link_info *, struct external_nlist **,
bfd_size_type *, char **));
-static boolean sunos_add_one_symbol
+static bfd_boolean sunos_add_one_symbol
PARAMS ((struct bfd_link_info *, bfd *, const char *, flagword, asection *,
- bfd_vma, const char *, boolean, boolean,
+ bfd_vma, const char *, bfd_boolean, bfd_boolean,
struct bfd_link_hash_entry **));
-static boolean sunos_scan_relocs
+static bfd_boolean sunos_scan_relocs
PARAMS ((struct bfd_link_info *, bfd *, asection *, bfd_size_type));
-static boolean sunos_scan_std_relocs
+static bfd_boolean sunos_scan_std_relocs
PARAMS ((struct bfd_link_info *, bfd *, asection *,
const struct reloc_std_external *, bfd_size_type));
-static boolean sunos_scan_ext_relocs
+static bfd_boolean sunos_scan_ext_relocs
PARAMS ((struct bfd_link_info *, bfd *, asection *,
const struct reloc_ext_external *, bfd_size_type));
-static boolean sunos_link_dynamic_object
+static bfd_boolean sunos_link_dynamic_object
PARAMS ((struct bfd_link_info *, bfd *));
-static boolean sunos_write_dynamic_symbol
+static bfd_boolean sunos_write_dynamic_symbol
PARAMS ((bfd *, struct bfd_link_info *, struct aout_link_hash_entry *));
-static boolean sunos_check_dynamic_reloc
+static bfd_boolean sunos_check_dynamic_reloc
PARAMS ((struct bfd_link_info *, bfd *, asection *,
- struct aout_link_hash_entry *, PTR, bfd_byte *, boolean *,
+ struct aout_link_hash_entry *, PTR, bfd_byte *, bfd_boolean *,
bfd_vma *));
-static boolean sunos_finish_dynamic_link
+static bfd_boolean sunos_finish_dynamic_link
PARAMS ((bfd *, struct bfd_link_info *));
#define MY_get_dynamic_symtab_upper_bound sunos_get_dynamic_symtab_upper_bound
@@ -106,7 +105,7 @@ static boolean sunos_finish_dynamic_link
struct sunos_dynamic_info
{
/* Whether we found any dynamic information. */
- boolean valid;
+ bfd_boolean valid;
/* Dynamic information. */
struct internal_sun4_dynamic_link dyninfo;
/* Number of dynamic symbols. */
@@ -135,9 +134,9 @@ struct sunos_dynamic_info
structure and uses it to find the dynamic_link structure. It
creates and saves a sunos_dynamic_info structure. If it can't find
__DYNAMIC, it sets the valid field of the sunos_dynamic_info
- structure to false to avoid doing this work again. */
+ structure to FALSE to avoid doing this work again. */
-static boolean
+static bfd_boolean
sunos_read_dynamic_info (abfd)
bfd *abfd;
{
@@ -150,19 +149,19 @@ sunos_read_dynamic_info (abfd)
bfd_size_type amt;
if (obj_aout_dynamic_info (abfd) != (PTR) NULL)
- return true;
+ return TRUE;
if ((abfd->flags & DYNAMIC) == 0)
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
amt = sizeof (struct sunos_dynamic_info);
info = (struct sunos_dynamic_info *) bfd_zalloc (abfd, amt);
if (!info)
- return false;
- info->valid = false;
+ return FALSE;
+ info->valid = FALSE;
info->dynsym = NULL;
info->dynstr = NULL;
info->canonical_dynsym = NULL;
@@ -178,15 +177,15 @@ sunos_read_dynamic_info (abfd)
We could verify this assumption later by looking through the dynamic
symbols for the __DYNAMIC symbol. */
if ((abfd->flags & DYNAMIC) == 0)
- return true;
+ return TRUE;
if (! bfd_get_section_contents (abfd, obj_datasec (abfd), (PTR) &dyninfo,
(file_ptr) 0,
(bfd_size_type) sizeof dyninfo))
- return true;
+ return TRUE;
dynver = GET_WORD (abfd, dyninfo.ld_version);
if (dynver != 2 && dynver != 3)
- return true;
+ return TRUE;
dynoff = GET_WORD (abfd, dyninfo.ld);
@@ -198,14 +197,14 @@ sunos_read_dynamic_info (abfd)
dynsec = obj_datasec (abfd);
dynoff -= bfd_get_section_vma (abfd, dynsec);
if (dynoff > bfd_section_size (abfd, dynsec))
- return true;
+ return TRUE;
/* This executable appears to be dynamically linked in a way that we
can understand. */
if (! bfd_get_section_contents (abfd, dynsec, (PTR) &linkinfo,
(file_ptr) dynoff,
(bfd_size_type) sizeof linkinfo))
- return true;
+ return TRUE;
/* Swap in the dynamic link information. */
info->dyninfo.ld_loaded = GET_WORD (abfd, linkinfo.ld_loaded);
@@ -252,9 +251,9 @@ sunos_read_dynamic_info (abfd)
== (unsigned long) (info->dyninfo.ld_hash
- info->dyninfo.ld_rel));
- info->valid = true;
+ info->valid = TRUE;
- return true;
+ return TRUE;
}
/* Return the amount of memory required for the dynamic symbols. */
@@ -280,7 +279,7 @@ sunos_get_dynamic_symtab_upper_bound (abfd)
/* Read the external dynamic symbols. */
-static boolean
+static bfd_boolean
sunos_slurp_dynamic_symtab (abfd)
bfd *abfd;
{
@@ -291,14 +290,14 @@ sunos_slurp_dynamic_symtab (abfd)
if (obj_aout_dynamic_info (abfd) == NULL)
{
if (! sunos_read_dynamic_info (abfd))
- return false;
+ return FALSE;
}
info = (struct sunos_dynamic_info *) obj_aout_dynamic_info (abfd);
if (! info->valid)
{
bfd_set_error (bfd_error_no_symbols);
- return false;
+ return FALSE;
}
/* Get the dynamic nlist structures. */
@@ -307,7 +306,7 @@ sunos_slurp_dynamic_symtab (abfd)
amt = (bfd_size_type) info->dynsym_count * EXTERNAL_NLIST_SIZE;
info->dynsym = (struct external_nlist *) bfd_alloc (abfd, amt);
if (info->dynsym == NULL && info->dynsym_count != 0)
- return false;
+ return FALSE;
if (bfd_seek (abfd, (file_ptr) info->dyninfo.ld_stab, SEEK_SET) != 0
|| bfd_bread ((PTR) info->dynsym, amt, abfd) != amt)
{
@@ -316,7 +315,7 @@ sunos_slurp_dynamic_symtab (abfd)
bfd_release (abfd, info->dynsym);
info->dynsym = NULL;
}
- return false;
+ return FALSE;
}
}
@@ -326,7 +325,7 @@ sunos_slurp_dynamic_symtab (abfd)
amt = info->dyninfo.ld_symb_size;
info->dynstr = (char *) bfd_alloc (abfd, amt);
if (info->dynstr == NULL && info->dyninfo.ld_symb_size != 0)
- return false;
+ return FALSE;
if (bfd_seek (abfd, (file_ptr) info->dyninfo.ld_symbols, SEEK_SET) != 0
|| bfd_bread ((PTR) info->dynstr, amt, abfd) != amt)
{
@@ -335,11 +334,11 @@ sunos_slurp_dynamic_symtab (abfd)
bfd_release (abfd, info->dynstr);
info->dynstr = NULL;
}
- return false;
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
/* Read in the dynamic symbols. */
@@ -413,7 +412,7 @@ sunos_canonicalize_dynamic_symtab (abfd, storage)
if (! aout_32_translate_symbol_table (abfd, info->canonical_dynsym,
info->dynsym,
(bfd_size_type) info->dynsym_count,
- info->dynstr, strsize, true))
+ info->dynstr, strsize, TRUE))
{
if (info->canonical_dynsym != NULL)
{
@@ -651,13 +650,13 @@ struct sunos_link_hash_table
bfd *dynobj;
/* Whether we have created the dynamic sections. */
- boolean dynamic_sections_created;
+ bfd_boolean dynamic_sections_created;
/* Whether we need the dynamic sections. */
- boolean dynamic_sections_needed;
+ bfd_boolean dynamic_sections_needed;
/* Whether we need the .got table. */
- boolean got_needed;
+ bfd_boolean got_needed;
/* The number of dynamic symbols. */
size_t dynsymcount;
@@ -728,9 +727,9 @@ sunos_link_hash_table_create (abfd)
}
ret->dynobj = NULL;
- ret->dynamic_sections_created = false;
- ret->dynamic_sections_needed = false;
- ret->got_needed = false;
+ ret->dynamic_sections_created = FALSE;
+ ret->dynamic_sections_needed = FALSE;
+ ret->got_needed = FALSE;
ret->dynsymcount = 0;
ret->bucketcount = 0;
ret->needed = NULL;
@@ -751,7 +750,7 @@ sunos_link_hash_table_create (abfd)
#define sunos_link_hash_traverse(table, func, info) \
(aout_link_hash_traverse \
(&(table)->root, \
- (boolean (*) PARAMS ((struct aout_link_hash_entry *, PTR))) (func), \
+ (bfd_boolean (*) PARAMS ((struct aout_link_hash_entry *, PTR))) (func), \
(info)))
/* Get the SunOS link hash table from the info structure. This is
@@ -759,7 +758,7 @@ sunos_link_hash_table_create (abfd)
#define sunos_hash_table(p) ((struct sunos_link_hash_table *) ((p)->hash))
-static boolean sunos_scan_dynamic_symbol
+static bfd_boolean sunos_scan_dynamic_symbol
PARAMS ((struct sunos_link_hash_entry *, PTR));
/* Create the dynamic sections needed if we are linking against a
@@ -769,11 +768,11 @@ static boolean sunos_scan_dynamic_symbol
place in the output file. See include/aout/sun4.h for more details
of the dynamic linking information. */
-static boolean
+static bfd_boolean
sunos_create_dynamic_sections (abfd, info, needed)
bfd *abfd;
struct bfd_link_info *info;
- boolean needed;
+ bfd_boolean needed;
{
asection *s;
@@ -793,7 +792,7 @@ sunos_create_dynamic_sections (abfd, info, needed)
if (s == NULL
|| ! bfd_set_section_flags (abfd, s, flags)
|| ! bfd_set_section_alignment (abfd, s, 2))
- return false;
+ return FALSE;
/* The .got section holds the global offset table. The address
is put in the ld_got field. */
@@ -801,7 +800,7 @@ sunos_create_dynamic_sections (abfd, info, needed)
if (s == NULL
|| ! bfd_set_section_flags (abfd, s, flags)
|| ! bfd_set_section_alignment (abfd, s, 2))
- return false;
+ return FALSE;
/* The .plt section holds the procedure linkage table. The
address is put in the ld_plt field. */
@@ -809,7 +808,7 @@ sunos_create_dynamic_sections (abfd, info, needed)
if (s == NULL
|| ! bfd_set_section_flags (abfd, s, flags | SEC_CODE)
|| ! bfd_set_section_alignment (abfd, s, 2))
- return false;
+ return FALSE;
/* The .dynrel section holds the dynamic relocs. The address is
put in the ld_rel field. */
@@ -817,7 +816,7 @@ sunos_create_dynamic_sections (abfd, info, needed)
if (s == NULL
|| ! bfd_set_section_flags (abfd, s, flags | SEC_READONLY)
|| ! bfd_set_section_alignment (abfd, s, 2))
- return false;
+ return FALSE;
/* The .hash section holds the dynamic hash table. The address
is put in the ld_hash field. */
@@ -825,7 +824,7 @@ sunos_create_dynamic_sections (abfd, info, needed)
if (s == NULL
|| ! bfd_set_section_flags (abfd, s, flags | SEC_READONLY)
|| ! bfd_set_section_alignment (abfd, s, 2))
- return false;
+ return FALSE;
/* The .dynsym section holds the dynamic symbols. The address
is put in the ld_stab field. */
@@ -833,7 +832,7 @@ sunos_create_dynamic_sections (abfd, info, needed)
if (s == NULL
|| ! bfd_set_section_flags (abfd, s, flags | SEC_READONLY)
|| ! bfd_set_section_alignment (abfd, s, 2))
- return false;
+ return FALSE;
/* The .dynstr section holds the dynamic symbol string table.
The address is put in the ld_symbols field. */
@@ -841,9 +840,9 @@ sunos_create_dynamic_sections (abfd, info, needed)
if (s == NULL
|| ! bfd_set_section_flags (abfd, s, flags | SEC_READONLY)
|| ! bfd_set_section_alignment (abfd, s, 2))
- return false;
+ return FALSE;
- sunos_hash_table (info)->dynamic_sections_created = true;
+ sunos_hash_table (info)->dynamic_sections_created = TRUE;
}
if ((needed && ! sunos_hash_table (info)->dynamic_sections_needed)
@@ -857,17 +856,17 @@ sunos_create_dynamic_sections (abfd, info, needed)
if (s->_raw_size == 0)
s->_raw_size = BYTES_IN_WORD;
- sunos_hash_table (info)->dynamic_sections_needed = true;
- sunos_hash_table (info)->got_needed = true;
+ sunos_hash_table (info)->dynamic_sections_needed = TRUE;
+ sunos_hash_table (info)->got_needed = TRUE;
}
- return true;
+ return TRUE;
}
/* Add dynamic symbols during a link. This is called by the a.out
backend linker for each object it encounters. */
-static boolean
+static bfd_boolean
sunos_add_dynamic_symbols (abfd, info, symsp, sym_countp, stringsp)
bfd *abfd;
struct bfd_link_info *info;
@@ -884,16 +883,14 @@ sunos_add_dynamic_symbols (abfd, info, symsp, sym_countp, stringsp)
if (info->hash->creator == abfd->xvec)
{
if (! sunos_create_dynamic_sections (abfd, info,
- (((abfd->flags & DYNAMIC) != 0
- && ! info->relocateable)
- ? true
- : false)))
- return false;
+ ((abfd->flags & DYNAMIC) != 0
+ && !info->relocatable)))
+ return FALSE;
}
/* There is nothing else to do for a normal object. */
if ((abfd->flags & DYNAMIC) == 0)
- return true;
+ return TRUE;
dynobj = sunos_hash_table (info)->dynobj;
@@ -914,15 +911,15 @@ sunos_add_dynamic_symbols (abfd, info, symsp, sym_countp, stringsp)
/* The native linker seems to just ignore dynamic objects when -r is
used. */
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
/* There's no hope of using a dynamic object which does not exactly
match the format of the output file. */
if (info->hash->creator != abfd->xvec)
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
/* Make sure we have a .need and a .rules sections. These are only
@@ -942,7 +939,7 @@ sunos_add_dynamic_symbols (abfd, info, symsp, sym_countp, stringsp)
| SEC_IN_MEMORY
| SEC_READONLY))
|| ! bfd_set_section_alignment (dynobj, s, 2))
- return false;
+ return FALSE;
}
if (bfd_get_section_by_name (dynobj, ".rules") == NULL)
@@ -959,12 +956,12 @@ sunos_add_dynamic_symbols (abfd, info, symsp, sym_countp, stringsp)
| SEC_IN_MEMORY
| SEC_READONLY))
|| ! bfd_set_section_alignment (dynobj, s, 2))
- return false;
+ return FALSE;
}
/* Pick up the dynamic symbols and return them to the caller. */
if (! sunos_slurp_dynamic_symtab (abfd))
- return false;
+ return FALSE;
dinfo = (struct sunos_dynamic_info *) obj_aout_dynamic_info (abfd);
*symsp = dinfo->dynsym;
@@ -986,10 +983,10 @@ sunos_add_dynamic_symbols (abfd, info, symsp, sym_countp, stringsp)
if (bfd_seek (abfd, (file_ptr) need, SEEK_SET) != 0
|| bfd_bread (buf, (bfd_size_type) 16, abfd) != 16)
- return false;
+ return FALSE;
/* For the format of an ld_need entry, see aout/sun4.h. We
- should probably define structs for this manipulation. */
+ should probably define structs for this manipulation. */
name = bfd_get_32 (abfd, buf);
flags = bfd_get_32 (abfd, buf + 4);
@@ -1000,14 +997,14 @@ sunos_add_dynamic_symbols (abfd, info, symsp, sym_countp, stringsp)
alc = sizeof (struct bfd_link_needed_list);
needed = (struct bfd_link_needed_list *) bfd_alloc (abfd, alc);
if (needed == NULL)
- return false;
+ return FALSE;
needed->by = abfd;
/* We return the name as [-l]name[.maj][.min]. */
alc = 30;
namebuf = (char *) bfd_malloc (alc + 1);
if (namebuf == NULL)
- return false;
+ return FALSE;
p = namebuf;
if ((flags & 0x80000000) != 0)
@@ -1018,7 +1015,7 @@ sunos_add_dynamic_symbols (abfd, info, symsp, sym_countp, stringsp)
if (bfd_seek (abfd, (file_ptr) name, SEEK_SET) != 0)
{
free (namebuf);
- return false;
+ return FALSE;
}
do
@@ -1026,7 +1023,7 @@ sunos_add_dynamic_symbols (abfd, info, symsp, sym_countp, stringsp)
if (bfd_bread (&b, (bfd_size_type) 1, abfd) != 1)
{
free (namebuf);
- return false;
+ return FALSE;
}
if ((bfd_size_type) (p - namebuf) >= alc)
@@ -1038,7 +1035,7 @@ sunos_add_dynamic_symbols (abfd, info, symsp, sym_countp, stringsp)
if (n == NULL)
{
free (namebuf);
- return false;
+ return FALSE;
}
p = n + (p - namebuf);
namebuf = n;
@@ -1070,7 +1067,7 @@ sunos_add_dynamic_symbols (abfd, info, symsp, sym_countp, stringsp)
if (n == NULL)
{
free (namebuf);
- return false;
+ return FALSE;
}
p = n + (p - namebuf);
namebuf = n;
@@ -1084,7 +1081,7 @@ sunos_add_dynamic_symbols (abfd, info, symsp, sym_countp, stringsp)
if (namecopy == NULL)
{
free (namebuf);
- return false;
+ return FALSE;
}
strcpy (namecopy, namebuf);
free (namebuf);
@@ -1099,14 +1096,14 @@ sunos_add_dynamic_symbols (abfd, info, symsp, sym_countp, stringsp)
*pp = needed;
}
- return true;
+ return TRUE;
}
/* Function to add a single symbol to the linker hash table. This is
a wrapper around _bfd_generic_link_add_one_symbol which handles the
tweaking needed for dynamic linking support. */
-static boolean
+static bfd_boolean
sunos_add_one_symbol (info, abfd, name, flags, section, value, string,
copy, collect, hashp)
struct bfd_link_info *info;
@@ -1116,8 +1113,8 @@ sunos_add_one_symbol (info, abfd, name, flags, section, value, string,
asection *section;
bfd_vma value;
const char *string;
- boolean copy;
- boolean collect;
+ bfd_boolean copy;
+ bfd_boolean collect;
struct bfd_link_hash_entry **hashp;
{
struct sunos_link_hash_entry *h;
@@ -1125,13 +1122,13 @@ sunos_add_one_symbol (info, abfd, name, flags, section, value, string,
if ((flags & (BSF_INDIRECT | BSF_WARNING | BSF_CONSTRUCTOR)) != 0
|| ! bfd_is_und_section (section))
- h = sunos_link_hash_lookup (sunos_hash_table (info), name, true, copy,
- false);
+ h = sunos_link_hash_lookup (sunos_hash_table (info), name, TRUE, copy,
+ FALSE);
else
h = ((struct sunos_link_hash_entry *)
- bfd_wrapped_link_hash_lookup (abfd, info, name, true, copy, false));
+ bfd_wrapped_link_hash_lookup (abfd, info, name, TRUE, copy, FALSE));
if (h == NULL)
- return false;
+ return FALSE;
if (hashp != NULL)
*hashp = (struct bfd_link_hash_entry *) h;
@@ -1185,10 +1182,10 @@ sunos_add_one_symbol (info, abfd, name, flags, section, value, string,
&& (h->flags & SUNOS_CONSTRUCTOR) != 0)
{
/* The existing symbol is a constructor symbol, and this symbol
- is from a dynamic object. A constructor symbol is actually a
- definition, although the type will be bfd_link_hash_undefined
- at this point. We want to ignore the definition from the
- dynamic object. */
+ is from a dynamic object. A constructor symbol is actually a
+ definition, although the type will be bfd_link_hash_undefined
+ at this point. We want to ignore the definition from the
+ dynamic object. */
section = bfd_und_section_ptr;
}
else if ((flags & BSF_CONSTRUCTOR) != 0
@@ -1198,8 +1195,8 @@ sunos_add_one_symbol (info, abfd, name, flags, section, value, string,
&& (h->root.root.u.def.section->owner->flags & DYNAMIC) != 0)
{
/* The existing symbol is defined by a dynamic object, and this
- is a constructor symbol. As above, we want to force the use
- of the constructor symbol from the regular object. */
+ is a constructor symbol. As above, we want to force the use
+ of the constructor symbol from the regular object. */
h->root.root.type = bfd_link_hash_new;
}
@@ -1207,7 +1204,7 @@ sunos_add_one_symbol (info, abfd, name, flags, section, value, string,
if (! _bfd_generic_link_add_one_symbol (info, abfd, name, flags, section,
value, string, copy, collect,
hashp))
- return false;
+ return FALSE;
if (abfd->xvec == info->hash->creator)
{
@@ -1244,12 +1241,11 @@ sunos_add_one_symbol (info, abfd, name, flags, section, value, string,
h->flags |= SUNOS_CONSTRUCTOR;
}
- return true;
+ return TRUE;
}
/* Return the list of objects needed by BFD. */
-/*ARGSUSED*/
struct bfd_link_needed_list *
bfd_sunos_get_needed_list (abfd, info)
bfd *abfd ATTRIBUTE_UNUSED;
@@ -1263,7 +1259,7 @@ bfd_sunos_get_needed_list (abfd, info)
/* Record an assignment made to a symbol by a linker script. We need
this in case some dynamic object refers to this symbol. */
-boolean
+bfd_boolean
bfd_sunos_record_link_assignment (output_bfd, info, name)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -1272,15 +1268,15 @@ bfd_sunos_record_link_assignment (output_bfd, info, name)
struct sunos_link_hash_entry *h;
if (output_bfd->xvec != &MY(vec))
- return true;
+ return TRUE;
/* This is called after we have examined all the input objects. If
the symbol does not exist, it merely means that no object refers
to it, and we can just ignore it at this point. */
h = sunos_link_hash_lookup (sunos_hash_table (info), name,
- false, false, false);
+ FALSE, FALSE, FALSE);
if (h == NULL)
- return true;
+ return TRUE;
/* In a shared library, the __DYNAMIC symbol does not appear in the
dynamic symbol table. */
@@ -1295,7 +1291,7 @@ bfd_sunos_record_link_assignment (output_bfd, info, name)
}
}
- return true;
+ return TRUE;
}
/* Set up the sizes and contents of the dynamic sections created in
@@ -1304,10 +1300,10 @@ bfd_sunos_record_link_assignment (output_bfd, info, name)
sections before the linker sets the addresses of the various
sections. This unfortunately requires reading all the relocs so
that we can work out which ones need to become dynamic relocs. If
- info->keep_memory is true, we keep the relocs in memory; otherwise,
+ info->keep_memory is TRUE, we keep the relocs in memory; otherwise,
we discard them, and will read them again later. */
-boolean
+bfd_boolean
bfd_sunos_size_dynamic_sections (output_bfd, info, sdynptr, sneedptr,
srulesptr)
bfd *output_bfd;
@@ -1329,11 +1325,11 @@ bfd_sunos_size_dynamic_sections (output_bfd, info, sdynptr, sneedptr,
*sneedptr = NULL;
*srulesptr = NULL;
- if (info->relocateable)
- return true;
+ if (info->relocatable)
+ return TRUE;
if (output_bfd->xvec != &MY(vec))
- return true;
+ return TRUE;
/* Look through all the input BFD's and read their relocs. It would
be better if we didn't have to do this, but there is no other way
@@ -1349,7 +1345,7 @@ bfd_sunos_size_dynamic_sections (output_bfd, info, sdynptr, sneedptr,
exec_hdr (sub)->a_trsize)
|| ! sunos_scan_relocs (info, sub, obj_datasec (sub),
exec_hdr (sub)->a_drsize))
- return false;
+ return FALSE;
}
}
@@ -1360,11 +1356,11 @@ bfd_sunos_size_dynamic_sections (output_bfd, info, sdynptr, sneedptr,
to build a global offset table, there is nothing to do here. */
if (! sunos_hash_table (info)->dynamic_sections_needed
&& ! sunos_hash_table (info)->got_needed)
- return true;
+ return TRUE;
/* If __GLOBAL_OFFSET_TABLE_ was mentioned, define it. */
h = sunos_link_hash_lookup (sunos_hash_table (info),
- "__GLOBAL_OFFSET_TABLE_", false, false, false);
+ "__GLOBAL_OFFSET_TABLE_", FALSE, FALSE, FALSE);
if (h != NULL && (h->flags & SUNOS_REF_REGULAR) != 0)
{
h->flags |= SUNOS_DEF_REGULAR;
@@ -1377,8 +1373,8 @@ bfd_sunos_size_dynamic_sections (output_bfd, info, sdynptr, sneedptr,
h->root.root.u.def.section = bfd_get_section_by_name (dynobj, ".got");
/* If the .got section is more than 0x1000 bytes, we set
- __GLOBAL_OFFSET_TABLE_ to be 0x1000 bytes into the section,
- so that 13 bit relocations have a greater chance of working. */
+ __GLOBAL_OFFSET_TABLE_ to be 0x1000 bytes into the section,
+ so that 13 bit relocations have a greater chance of working. */
s = bfd_get_section_by_name (dynobj, ".got");
BFD_ASSERT (s != NULL);
if (s->_raw_size >= 0x1000)
@@ -1415,7 +1411,7 @@ bfd_sunos_size_dynamic_sections (output_bfd, info, sdynptr, sneedptr,
s->_raw_size = dynsymcount * sizeof (struct external_nlist);
s->contents = (bfd_byte *) bfd_alloc (output_bfd, s->_raw_size);
if (s->contents == NULL && s->_raw_size != 0)
- return false;
+ return FALSE;
/* The number of buckets is just the number of symbols divided
by four. To compute the final size of the hash table, we
@@ -1436,7 +1432,7 @@ bfd_sunos_size_dynamic_sections (output_bfd, info, sdynptr, sneedptr,
hashalloc = (dynsymcount + bucketcount - 1) * HASH_ENTRY_SIZE;
s->contents = (bfd_byte *) bfd_zalloc (dynobj, hashalloc);
if (s->contents == NULL && dynsymcount > 0)
- return false;
+ return FALSE;
for (i = 0; i < bucketcount; i++)
PUT_WORD (output_bfd, (bfd_vma) -1, s->contents + i * HASH_ENTRY_SIZE);
s->_raw_size = bucketcount * HASH_ENTRY_SIZE;
@@ -1466,7 +1462,7 @@ bfd_sunos_size_dynamic_sections (output_bfd, info, sdynptr, sneedptr,
contents = (bfd_byte *) bfd_realloc (s->contents,
s->_raw_size + add);
if (contents == NULL)
- return false;
+ return FALSE;
memset (contents + s->_raw_size, 0, (size_t) add);
s->contents = contents;
s->_raw_size += add;
@@ -1481,7 +1477,7 @@ bfd_sunos_size_dynamic_sections (output_bfd, info, sdynptr, sneedptr,
{
s->contents = (bfd_byte *) bfd_alloc (dynobj, s->_raw_size);
if (s->contents == NULL)
- return false;
+ return FALSE;
/* Fill in the first entry in the table. */
switch (bfd_get_arch (dynobj))
@@ -1504,7 +1500,7 @@ bfd_sunos_size_dynamic_sections (output_bfd, info, sdynptr, sneedptr,
{
s->contents = (bfd_byte *) bfd_alloc (dynobj, s->_raw_size);
if (s->contents == NULL)
- return false;
+ return FALSE;
}
/* We use the reloc_count field to keep track of how many of the
relocs we have output so far. */
@@ -1514,17 +1510,17 @@ bfd_sunos_size_dynamic_sections (output_bfd, info, sdynptr, sneedptr,
s = bfd_get_section_by_name (dynobj, ".got");
s->contents = (bfd_byte *) bfd_alloc (dynobj, s->_raw_size);
if (s->contents == NULL)
- return false;
+ return FALSE;
*sneedptr = bfd_get_section_by_name (dynobj, ".need");
*srulesptr = bfd_get_section_by_name (dynobj, ".rules");
- return true;
+ return TRUE;
}
/* Scan the relocs for an input section. */
-static boolean
+static bfd_boolean
sunos_scan_relocs (info, abfd, sec, rel_size)
struct bfd_link_info *info;
bfd *abfd;
@@ -1535,7 +1531,7 @@ sunos_scan_relocs (info, abfd, sec, rel_size)
PTR free_relocs = NULL;
if (rel_size == 0)
- return true;
+ return TRUE;
if (! info->keep_memory)
relocs = free_relocs = bfd_malloc (rel_size);
@@ -1555,7 +1551,7 @@ sunos_scan_relocs (info, abfd, sec, rel_size)
}
}
if (relocs == NULL)
- return false;
+ return FALSE;
if (bfd_seek (abfd, sec->rel_filepos, SEEK_SET) != 0
|| bfd_bread (relocs, rel_size, abfd) != rel_size)
@@ -1579,12 +1575,12 @@ sunos_scan_relocs (info, abfd, sec, rel_size)
if (free_relocs != NULL)
free (free_relocs);
- return true;
+ return TRUE;
error_return:
if (free_relocs != NULL)
free (free_relocs);
- return false;
+ return FALSE;
}
/* Scan the relocs for an input section using standard relocs. We
@@ -1597,7 +1593,7 @@ sunos_scan_relocs (info, abfd, sec, rel_size)
reloc. FIXME: We should also handle the PIC relocs here by
building global offset table entries. */
-static boolean
+static bfd_boolean
sunos_scan_std_relocs (info, abfd, sec, relocs, rel_size)
struct bfd_link_info *info;
bfd *abfd;
@@ -1615,7 +1611,7 @@ sunos_scan_std_relocs (info, abfd, sec, relocs, rel_size)
if (bfd_get_arch (abfd) != bfd_arch_m68k)
{
bfd_set_error (bfd_error_invalid_target);
- return false;
+ return FALSE;
}
dynobj = NULL;
@@ -1677,8 +1673,8 @@ sunos_scan_std_relocs (info, abfd, sec, relocs, rel_size)
{
asection *sgot;
- if (! sunos_create_dynamic_sections (abfd, info, false))
- return false;
+ if (! sunos_create_dynamic_sections (abfd, info, FALSE))
+ return FALSE;
dynobj = sunos_hash_table (info)->dynobj;
splt = bfd_get_section_by_name (dynobj, ".plt");
srel = bfd_get_section_by_name (dynobj, ".dynrel");
@@ -1688,7 +1684,7 @@ sunos_scan_std_relocs (info, abfd, sec, relocs, rel_size)
BFD_ASSERT (sgot != NULL);
if (sgot->_raw_size == 0)
sgot->_raw_size = BYTES_IN_WORD;
- sunos_hash_table (info)->got_needed = true;
+ sunos_hash_table (info)->got_needed = TRUE;
}
BFD_ASSERT ((h->flags & SUNOS_REF_REGULAR) != 0);
@@ -1748,7 +1744,7 @@ sunos_scan_std_relocs (info, abfd, sec, relocs, rel_size)
}
}
- return true;
+ return TRUE;
}
/* Scan the relocs for an input section using extended relocs. We
@@ -1757,7 +1753,7 @@ sunos_scan_std_relocs (info, abfd, sec, relocs, rel_size)
section, an entry is made in the procedure linkage table.
Otherwise, we must preserve the reloc as a dynamic reloc. */
-static boolean
+static bfd_boolean
sunos_scan_ext_relocs (info, abfd, sec, relocs, rel_size)
struct bfd_link_info *info;
bfd *abfd;
@@ -1777,7 +1773,7 @@ sunos_scan_ext_relocs (info, abfd, sec, relocs, rel_size)
if (bfd_get_arch (abfd) != bfd_arch_sparc)
{
bfd_set_error (bfd_error_invalid_target);
- return false;
+ return FALSE;
}
dynobj = NULL;
@@ -1824,15 +1820,15 @@ sunos_scan_ext_relocs (info, abfd, sec, relocs, rel_size)
}
/* If this is a base relative reloc, we need to make an entry in
- the .got section. */
+ the .got section. */
if (r_type == RELOC_BASE10
|| r_type == RELOC_BASE13
|| r_type == RELOC_BASE22)
{
if (dynobj == NULL)
{
- if (! sunos_create_dynamic_sections (abfd, info, false))
- return false;
+ if (! sunos_create_dynamic_sections (abfd, info, FALSE))
+ return FALSE;
dynobj = sunos_hash_table (info)->dynobj;
splt = bfd_get_section_by_name (dynobj, ".plt");
sgot = bfd_get_section_by_name (dynobj, ".got");
@@ -1842,7 +1838,7 @@ sunos_scan_ext_relocs (info, abfd, sec, relocs, rel_size)
/* Make sure we have an initial entry in the .got table. */
if (sgot->_raw_size == 0)
sgot->_raw_size = BYTES_IN_WORD;
- sunos_hash_table (info)->got_needed = true;
+ sunos_hash_table (info)->got_needed = TRUE;
}
if (r_extern)
@@ -1868,7 +1864,7 @@ sunos_scan_ext_relocs (info, abfd, sec, relocs, rel_size)
adata (abfd).local_got_offsets =
(bfd_vma *) bfd_zalloc (abfd, amt);
if (adata (abfd).local_got_offsets == NULL)
- return false;
+ return FALSE;
}
if (adata (abfd).local_got_offsets[r_index] != 0)
@@ -1892,18 +1888,18 @@ sunos_scan_ext_relocs (info, abfd, sec, relocs, rel_size)
}
/* Otherwise, we are only interested in relocs against symbols
- defined in dynamic objects but not in regular objects. We
- only need to consider relocs against external symbols. */
+ defined in dynamic objects but not in regular objects. We
+ only need to consider relocs against external symbols. */
if (! r_extern)
{
/* But, if we are creating a shared library, we need to
- generate an absolute reloc. */
+ generate an absolute reloc. */
if (info->shared)
{
if (dynobj == NULL)
{
- if (! sunos_create_dynamic_sections (abfd, info, true))
- return false;
+ if (! sunos_create_dynamic_sections (abfd, info, TRUE))
+ return FALSE;
dynobj = sunos_hash_table (info)->dynobj;
splt = bfd_get_section_by_name (dynobj, ".plt");
sgot = bfd_get_section_by_name (dynobj, ".got");
@@ -1939,8 +1935,8 @@ sunos_scan_ext_relocs (info, abfd, sec, relocs, rel_size)
&& (h->flags & SUNOS_DEF_REGULAR) == 0)
{
/* This symbol is apparently undefined. Don't do anything
- here; just let the relocation routine report an undefined
- symbol. */
+ here; just let the relocation routine report an undefined
+ symbol. */
continue;
}
@@ -1949,8 +1945,8 @@ sunos_scan_ext_relocs (info, abfd, sec, relocs, rel_size)
if (dynobj == NULL)
{
- if (! sunos_create_dynamic_sections (abfd, info, false))
- return false;
+ if (! sunos_create_dynamic_sections (abfd, info, FALSE))
+ return FALSE;
dynobj = sunos_hash_table (info)->dynobj;
splt = bfd_get_section_by_name (dynobj, ".plt");
sgot = bfd_get_section_by_name (dynobj, ".got");
@@ -1960,7 +1956,7 @@ sunos_scan_ext_relocs (info, abfd, sec, relocs, rel_size)
/* Make sure we have an initial entry in the .got table. */
if (sgot->_raw_size == 0)
sgot->_raw_size = BYTES_IN_WORD;
- sunos_hash_table (info)->got_needed = true;
+ sunos_hash_table (info)->got_needed = TRUE;
}
BFD_ASSERT (r_type == RELOC_JMP_TBL
@@ -2025,26 +2021,26 @@ sunos_scan_ext_relocs (info, abfd, sec, relocs, rel_size)
splt->_raw_size += SPARC_PLT_ENTRY_SIZE;
/* We will also need a dynamic reloc entry, unless this
- is a JMP_TBL reloc produced by linking PIC compiled
- code, and we are not making a shared library. */
+ is a JMP_TBL reloc produced by linking PIC compiled
+ code, and we are not making a shared library. */
if (info->shared || (h->flags & SUNOS_DEF_REGULAR) == 0)
srel->_raw_size += RELOC_EXT_SIZE;
}
/* If we are creating a shared library, we need to copy over
- any reloc other than a jump table reloc. */
+ any reloc other than a jump table reloc. */
if (info->shared && r_type != RELOC_JMP_TBL)
srel->_raw_size += RELOC_EXT_SIZE;
}
}
- return true;
+ return TRUE;
}
/* Build the hash table of dynamic symbols, and to mark as written all
symbols from dynamic objects which we do not plan to write out. */
-static boolean
+static bfd_boolean
sunos_scan_dynamic_symbol (h, data)
struct sunos_link_hash_entry *h;
PTR data;
@@ -2066,7 +2062,7 @@ sunos_scan_dynamic_symbol (h, data)
if ((h->flags & SUNOS_DEF_REGULAR) == 0
&& (h->flags & SUNOS_DEF_DYNAMIC) != 0
&& strcmp (h->root.root.root.string, "__DYNAMIC") != 0)
- h->root.written = true;
+ h->root.written = TRUE;
/* If this symbol is defined by a dynamic object and referenced by a
regular object, see whether we gave it a reasonable value while
@@ -2125,7 +2121,7 @@ sunos_scan_dynamic_symbol (h, data)
contents = (bfd_byte *) bfd_realloc (s->contents,
s->_raw_size + len + 1);
if (contents == NULL)
- return false;
+ return FALSE;
s->contents = contents;
h->dynstr_index = s->_raw_size;
@@ -2161,26 +2157,25 @@ sunos_scan_dynamic_symbol (h, data)
}
}
- return true;
+ return TRUE;
}
/* Link a dynamic object. We actually don't have anything to do at
this point. This entry point exists to prevent the regular linker
code from doing anything with the object. */
-/*ARGSUSED*/
-static boolean
+static bfd_boolean
sunos_link_dynamic_object (info, abfd)
struct bfd_link_info *info ATTRIBUTE_UNUSED;
bfd *abfd ATTRIBUTE_UNUSED;
{
- return true;
+ return TRUE;
}
/* Write out a dynamic symbol. This is called by the final traversal
over the symbol table. */
-static boolean
+static bfd_boolean
sunos_write_dynamic_symbol (output_bfd, info, harg)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -2254,7 +2249,7 @@ sunos_write_dynamic_symbol (output_bfd, info, harg)
}
/* We also need to add a jump table reloc, unless this is the
- result of a JMP_TBL reloc from PIC compiled code. */
+ result of a JMP_TBL reloc from PIC compiled code. */
if (info->shared || (h->flags & SUNOS_DEF_REGULAR) == 0)
{
BFD_ASSERT (h->dynindx >= 0);
@@ -2320,7 +2315,7 @@ sunos_write_dynamic_symbol (output_bfd, info, harg)
we can have a PLT entry for a nondynamic symbol when linking PIC
compiled code from a regular object. */
if (h->dynindx < 0)
- return true;
+ return TRUE;
switch (h->root.root.type)
{
@@ -2328,7 +2323,7 @@ sunos_write_dynamic_symbol (output_bfd, info, harg)
case bfd_link_hash_new:
abort ();
/* Avoid variable not initialized warnings. */
- return true;
+ return TRUE;
case bfd_link_hash_undefined:
type = N_UNDF | N_EXT;
val = 0;
@@ -2386,7 +2381,7 @@ sunos_write_dynamic_symbol (output_bfd, info, harg)
case bfd_link_hash_warning:
/* FIXME: Ignore these for now. The circumstances under which
they should be written out are not clear to me. */
- return true;
+ return TRUE;
}
s = bfd_get_section_by_name (sunos_hash_table (info)->dynobj, ".dynsym");
@@ -2405,7 +2400,7 @@ sunos_write_dynamic_symbol (output_bfd, info, harg)
PUT_WORD (output_bfd, h->dynstr_index, outsym->e_strx);
PUT_WORD (output_bfd, val, outsym->e_value);
- return true;
+ return TRUE;
}
/* This is called for each reloc against an external symbol. If this
@@ -2413,8 +2408,7 @@ sunos_write_dynamic_symbol (output_bfd, info, harg)
copy it over, and tell the caller to not bother processing this
reloc. */
-/*ARGSUSED*/
-static boolean
+static bfd_boolean
sunos_check_dynamic_reloc (info, input_bfd, input_section, harg, reloc,
contents, skip, relocationp)
struct bfd_link_info *info;
@@ -2423,19 +2417,19 @@ sunos_check_dynamic_reloc (info, input_bfd, input_section, harg, reloc,
struct aout_link_hash_entry *harg;
PTR reloc;
bfd_byte *contents ATTRIBUTE_UNUSED;
- boolean *skip;
+ bfd_boolean *skip;
bfd_vma *relocationp;
{
struct sunos_link_hash_entry *h = (struct sunos_link_hash_entry *) harg;
bfd *dynobj;
- boolean baserel;
- boolean jmptbl;
- boolean pcrel;
+ bfd_boolean baserel;
+ bfd_boolean jmptbl;
+ bfd_boolean pcrel;
asection *s;
bfd_byte *p;
long indx;
- *skip = false;
+ *skip = FALSE;
dynobj = sunos_hash_table (info)->dynobj;
@@ -2493,7 +2487,7 @@ sunos_check_dynamic_reloc (info, input_bfd, input_section, harg, reloc,
|| r_type == RELOC_WDISP30
|| r_type == RELOC_WDISP22);
/* We don't consider the PC10 and PC22 types to be PC relative,
- because they are pcrel_offset. */
+ because they are pcrel_offset. */
}
if (baserel)
@@ -2562,7 +2556,7 @@ sunos_check_dynamic_reloc (info, input_bfd, input_section, harg, reloc,
&& (h->flags & SUNOS_DEF_REGULAR) == 0))
{
/* We need to create a GLOB_DAT or 32 reloc to tell the
- dynamic linker to fill in this entry in the table. */
+ dynamic linker to fill in this entry in the table. */
s = bfd_get_section_by_name (dynobj, ".dynrel");
BFD_ASSERT (s != NULL);
@@ -2667,11 +2661,11 @@ sunos_check_dynamic_reloc (info, input_bfd, input_section, harg, reloc,
- sunos_hash_table (info)->got_base);
/* There is nothing else to do for a base relative reloc. */
- return true;
+ return TRUE;
}
if (! sunos_hash_table (info)->dynamic_sections_needed)
- return true;
+ return TRUE;
if (! info->shared)
{
if (h == NULL
@@ -2680,7 +2674,7 @@ sunos_check_dynamic_reloc (info, input_bfd, input_section, harg, reloc,
|| (h->flags & SUNOS_DEF_REGULAR) != 0
|| (h->flags & SUNOS_DEF_DYNAMIC) == 0
|| (h->root.root.u.undef.abfd->flags & DYNAMIC) == 0)
- return true;
+ return TRUE;
}
else
{
@@ -2689,7 +2683,7 @@ sunos_check_dynamic_reloc (info, input_bfd, input_section, harg, reloc,
|| jmptbl
|| strcmp (h->root.root.root.string,
"__GLOBAL_OFFSET_TABLE_") == 0))
- return true;
+ return TRUE;
}
/* It looks like this is a reloc we are supposed to copy. */
@@ -2732,7 +2726,7 @@ sunos_check_dynamic_reloc (info, input_bfd, input_section, harg, reloc,
srel->r_index[0] = (bfd_byte)indx;
}
/* FIXME: We may have to change the addend for a PC relative
- reloc. */
+ reloc. */
}
else
{
@@ -2771,14 +2765,14 @@ sunos_check_dynamic_reloc (info, input_bfd, input_section, harg, reloc,
++s->reloc_count;
if (h != NULL)
- *skip = true;
+ *skip = TRUE;
- return true;
+ return TRUE;
}
/* Finish up the dynamic linking information. */
-static boolean
+static bfd_boolean
sunos_finish_dynamic_link (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -2790,7 +2784,7 @@ sunos_finish_dynamic_link (abfd, info)
if (! sunos_hash_table (info)->dynamic_sections_needed
&& ! sunos_hash_table (info)->got_needed)
- return true;
+ return TRUE;
dynobj = sunos_hash_table (info)->dynobj;
@@ -2843,7 +2837,7 @@ sunos_finish_dynamic_link (abfd, info)
o->contents,
(file_ptr) o->output_offset,
o->_raw_size))
- return false;
+ return FALSE;
}
}
@@ -2868,7 +2862,7 @@ sunos_finish_dynamic_link (abfd, info)
if (! bfd_set_section_contents (abfd, sdyn->output_section, &esd,
(file_ptr) sdyn->output_offset,
(bfd_size_type) sizeof esd))
- return false;
+ return FALSE;
PUT_WORD (dynobj, (bfd_vma) 0, esdl.ld_loaded);
@@ -2936,10 +2930,10 @@ sunos_finish_dynamic_link (abfd, info)
pos += sizeof esd + EXTERNAL_SUN4_DYNAMIC_DEBUGGER_SIZE;
if (! bfd_set_section_contents (abfd, sdyn->output_section, &esdl,
pos, (bfd_size_type) sizeof esdl))
- return false;
+ return FALSE;
abfd->flags |= DYNAMIC;
}
- return true;
+ return TRUE;
}
diff --git a/contrib/binutils/bfd/syms.c b/contrib/binutils/bfd/syms.c
index da71d80..c07f48b 100644
--- a/contrib/binutils/bfd/syms.c
+++ b/contrib/binutils/bfd/syms.c
@@ -1,24 +1,24 @@
/* Generic symbol-table support for the BFD library.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Cygnus Support.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/*
SECTION
@@ -74,10 +74,10 @@ SUBSECTION
| if (storage_needed < 0)
| FAIL
|
-| if (storage_needed == 0) {
-| return ;
-| }
-| symbol_table = (asymbol **) xmalloc (storage_needed);
+| if (storage_needed == 0)
+| return;
+|
+| symbol_table = xmalloc (storage_needed);
| ...
| number_of_symbols =
| bfd_canonicalize_symtab (abfd, symbol_table);
@@ -85,9 +85,8 @@ SUBSECTION
| if (number_of_symbols < 0)
| FAIL
|
-| for (i = 0; i < number_of_symbols; i++) {
-| process_symbol (symbol_table[i]);
-| }
+| for (i = 0; i < number_of_symbols; i++)
+| process_symbol (symbol_table[i]);
All storage for the symbols themselves is in an objalloc
connected to the BFD; it is freed when the BFD is closed.
@@ -108,34 +107,35 @@ SUBSECTION
example showing the creation of a symbol table with only one element:
| #include "bfd.h"
-| main()
+| int main (void)
| {
| bfd *abfd;
| asymbol *ptrs[2];
| asymbol *new;
|
-| abfd = bfd_openw("foo","a.out-sunos-big");
-| bfd_set_format(abfd, bfd_object);
-| new = bfd_make_empty_symbol(abfd);
+| abfd = bfd_openw ("foo","a.out-sunos-big");
+| bfd_set_format (abfd, bfd_object);
+| new = bfd_make_empty_symbol (abfd);
| new->name = "dummy_symbol";
-| new->section = bfd_make_section_old_way(abfd, ".text");
+| new->section = bfd_make_section_old_way (abfd, ".text");
| new->flags = BSF_GLOBAL;
| new->value = 0x12345;
|
| ptrs[0] = new;
-| ptrs[1] = (asymbol *)0;
+| ptrs[1] = 0;
|
-| bfd_set_symtab(abfd, ptrs, 1);
-| bfd_close(abfd);
+| bfd_set_symtab (abfd, ptrs, 1);
+| bfd_close (abfd);
+| return 0;
| }
|
| ./makesym
| nm foo
| 00012345 A dummy_symbol
- Many formats cannot represent arbitary symbol information; for
+ Many formats cannot represent arbitrary symbol information; for
instance, the <<a.out>> object format does not allow an
- arbitary number of sections. A symbol pointing to a section
+ arbitrary number of sections. A symbol pointing to a section
which is not one of <<.text>>, <<.data>> or <<.bss>> cannot
be described.
@@ -181,7 +181,7 @@ SUBSECTION
CODE_FRAGMENT
.
-.typedef struct symbol_cache_entry
+.typedef struct bfd_symbol
.{
. {* A pointer to the BFD which owns the symbol. This information
. is necessary so that a back end can work out what additional
@@ -192,7 +192,7 @@ CODE_FRAGMENT
. instead, except that some symbols point to the global sections
. bfd_{abs,com,und}_section. This could be fixed by making
. these globals be per-bfd (or per-target-flavor). FIXME. *}
-. struct _bfd *the_bfd; {* Use bfd_asymbol_bfd(sym) to access this field. *}
+. struct bfd *the_bfd; {* Use bfd_asymbol_bfd(sym) to access this field. *}
.
. {* The text of the symbol. The name is left alone, and not copied; the
. application may not alter it. *}
@@ -222,7 +222,7 @@ CODE_FRAGMENT
. <<BSF_LOCAL>>, <<BSF_FORT_COMM>>, <<BSF_UNDEFINED>> or
. <<BSF_GLOBAL>>. *}
.
-. {* The symbol is a debugging record. The value has an arbitary
+. {* The symbol is a debugging record. The value has an arbitrary
. meaning, unless BSF_DEBUGGING_RELOC is also set. *}
.#define BSF_DEBUGGING 0x08
.
@@ -293,12 +293,12 @@ CODE_FRAGMENT
. {* A pointer to the section to which this symbol is
. relative. This will always be non NULL, there are special
. sections for undefined and absolute symbols. *}
-. struct sec *section;
+. struct bfd_section *section;
.
. {* Back end special data. *}
. union
. {
-. PTR p;
+. void *p;
. bfd_vma i;
. }
. udata;
@@ -314,10 +314,6 @@ CODE_FRAGMENT
#include "bfdlink.h"
#include "aout/stab_gnu.h"
-static char coff_section_type PARAMS ((const char *));
-static char decode_section_type PARAMS ((const struct sec *));
-static int cmpindexentry PARAMS ((const PTR, const PTR));
-
/*
DOCDD
INODE
@@ -346,25 +342,23 @@ FUNCTION
bfd_is_local_label
SYNOPSIS
- boolean bfd_is_local_label(bfd *abfd, asymbol *sym);
+ bfd_boolean bfd_is_local_label (bfd *abfd, asymbol *sym);
DESCRIPTION
- Return true if the given symbol @var{sym} in the BFD @var{abfd} is
- a compiler generated local label, else return false.
+ Return TRUE if the given symbol @var{sym} in the BFD @var{abfd} is
+ a compiler generated local label, else return FALSE.
*/
-boolean
-bfd_is_local_label (abfd, sym)
- bfd *abfd;
- asymbol *sym;
+bfd_boolean
+bfd_is_local_label (bfd *abfd, asymbol *sym)
{
/* The BSF_SECTION_SYM check is needed for IA-64, where every label that
starts with '.' is local. This would accidentally catch section names
if we didn't reject them here. */
if ((sym->flags & (BSF_GLOBAL | BSF_WEAK | BSF_SECTION_SYM)) != 0)
- return false;
+ return FALSE;
if (sym->name == NULL)
- return false;
+ return FALSE;
return bfd_is_local_label_name (abfd, sym->name);
}
@@ -373,16 +367,16 @@ FUNCTION
bfd_is_local_label_name
SYNOPSIS
- boolean bfd_is_local_label_name(bfd *abfd, const char *name);
+ bfd_boolean bfd_is_local_label_name (bfd *abfd, const char *name);
DESCRIPTION
- Return true if a symbol with the name @var{name} in the BFD
+ Return TRUE if a symbol with the name @var{name} in the BFD
@var{abfd} is a compiler generated local label, else return
- false. This just checks whether the name has the form of a
+ FALSE. This just checks whether the name has the form of a
local label.
.#define bfd_is_local_label_name(abfd, name) \
-. BFD_SEND (abfd, _bfd_is_local_label_name, (abfd, name))
+. BFD_SEND (abfd, _bfd_is_local_label_name, (abfd, name))
.
*/
@@ -398,8 +392,7 @@ DESCRIPTION
including the NULL.
.#define bfd_canonicalize_symtab(abfd, location) \
-. BFD_SEND (abfd, _bfd_canonicalize_symtab,\
-. (abfd, location))
+. BFD_SEND (abfd, _bfd_canonicalize_symtab, (abfd, location))
.
*/
@@ -408,7 +401,8 @@ FUNCTION
bfd_set_symtab
SYNOPSIS
- boolean bfd_set_symtab (bfd *abfd, asymbol **location, unsigned int count);
+ bfd_boolean bfd_set_symtab
+ (bfd *abfd, asymbol **location, unsigned int count);
DESCRIPTION
Arrange that when the output BFD @var{abfd} is closed,
@@ -416,21 +410,18 @@ DESCRIPTION
will be written.
*/
-boolean
-bfd_set_symtab (abfd, location, symcount)
- bfd *abfd;
- asymbol **location;
- unsigned int symcount;
+bfd_boolean
+bfd_set_symtab (bfd *abfd, asymbol **location, unsigned int symcount)
{
- if ((abfd->format != bfd_object) || (bfd_read_p (abfd)))
+ if (abfd->format != bfd_object || bfd_read_p (abfd))
{
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
bfd_get_outsymbols (abfd) = location;
bfd_get_symcount (abfd) = symcount;
- return true;
+ return TRUE;
}
/*
@@ -438,29 +429,23 @@ FUNCTION
bfd_print_symbol_vandf
SYNOPSIS
- void bfd_print_symbol_vandf(bfd *abfd, PTR file, asymbol *symbol);
+ void bfd_print_symbol_vandf (bfd *abfd, void *file, asymbol *symbol);
DESCRIPTION
Print the value and flags of the @var{symbol} supplied to the
stream @var{file}.
*/
void
-bfd_print_symbol_vandf (abfd, arg, symbol)
- bfd *abfd;
- PTR arg;
- asymbol *symbol;
+bfd_print_symbol_vandf (bfd *abfd, void *arg, asymbol *symbol)
{
- FILE *file = (FILE *) arg;
+ FILE *file = arg;
+
flagword type = symbol->flags;
- if (symbol->section != (asection *) NULL)
- {
- bfd_fprintf_vma (abfd, file,
- symbol->value + symbol->section->vma);
- }
+
+ if (symbol->section != NULL)
+ bfd_fprintf_vma (abfd, file, symbol->value + symbol->section->vma);
else
- {
- bfd_fprintf_vma (abfd, file, symbol->value);
- }
+ bfd_fprintf_vma (abfd, file, symbol->value);
/* This presumes that a symbol can not be both BSF_DEBUGGING and
BSF_DYNAMIC, nor more than one of BSF_FUNCTION, BSF_FILE, and
@@ -495,7 +480,7 @@ DESCRIPTION
information, and will cause problems later on.
.#define bfd_make_empty_symbol(abfd) \
-. BFD_SEND (abfd, _bfd_make_empty_symbol, (abfd))
+. BFD_SEND (abfd, _bfd_make_empty_symbol, (abfd))
.
*/
@@ -514,11 +499,10 @@ DESCRIPTION
*/
asymbol *
-_bfd_generic_make_empty_symbol (abfd)
- bfd *abfd;
+_bfd_generic_make_empty_symbol (bfd *abfd)
{
bfd_size_type amt = sizeof (asymbol);
- asymbol *new = (asymbol *) bfd_zalloc (abfd, amt);
+ asymbol *new = bfd_zalloc (abfd, amt);
if (new)
new->the_bfd = abfd;
return new;
@@ -534,7 +518,7 @@ DESCRIPTION
yet to be worked out.
.#define bfd_make_debug_symbol(abfd,ptr,size) \
-. BFD_SEND (abfd, _bfd_make_debug_symbol, (abfd, ptr, size))
+. BFD_SEND (abfd, _bfd_make_debug_symbol, (abfd, ptr, size))
.
*/
@@ -578,8 +562,7 @@ static const struct section_to_type stt[] =
't' as well as .text */
static char
-coff_section_type (s)
- const char *s;
+coff_section_type (const char *s)
{
const struct section_to_type *t;
@@ -598,8 +581,7 @@ coff_section_type (s)
we could perhaps obsolete coff_section_type. */
static char
-decode_section_type (section)
- const struct sec *section;
+decode_section_type (const struct bfd_section *section)
{
if (section->flags & SEC_CODE)
return 't';
@@ -621,6 +603,8 @@ decode_section_type (section)
}
if (section->flags & SEC_DEBUGGING)
return 'N';
+ if ((section->flags & SEC_HAS_CONTENTS) && (section->flags & SEC_READONLY))
+ return 'n';
return '?';
}
@@ -634,11 +618,10 @@ DESCRIPTION
class of @var{symbol}, or '?' for an unknown class.
SYNOPSIS
- int bfd_decode_symclass(asymbol *symbol);
+ int bfd_decode_symclass (asymbol *symbol);
*/
int
-bfd_decode_symclass (symbol)
- asymbol *symbol;
+bfd_decode_symclass (asymbol *symbol)
{
char c;
@@ -706,14 +689,13 @@ DESCRIPTION
Returns zero otherwise.
SYNOPSIS
- boolean bfd_is_undefined_symclass (int symclass);
+ bfd_boolean bfd_is_undefined_symclass (int symclass);
*/
-boolean
-bfd_is_undefined_symclass (symclass)
- int symclass;
+bfd_boolean
+bfd_is_undefined_symclass (int symclass)
{
- return (boolean) (symclass == 'U' || symclass == 'w' || symclass == 'v');
+ return symclass == 'U' || symclass == 'w' || symclass == 'v';
}
/*
@@ -726,13 +708,11 @@ DESCRIPTION
calling this function.
SYNOPSIS
- void bfd_symbol_info(asymbol *symbol, symbol_info *ret);
+ void bfd_symbol_info (asymbol *symbol, symbol_info *ret);
*/
void
-bfd_symbol_info (symbol, ret)
- asymbol *symbol;
- symbol_info *ret;
+bfd_symbol_info (asymbol *symbol, symbol_info *ret)
{
ret->type = bfd_decode_symclass (symbol);
@@ -749,20 +729,21 @@ FUNCTION
bfd_copy_private_symbol_data
SYNOPSIS
- boolean bfd_copy_private_symbol_data(bfd *ibfd, asymbol *isym, bfd *obfd, asymbol *osym);
+ bfd_boolean bfd_copy_private_symbol_data
+ (bfd *ibfd, asymbol *isym, bfd *obfd, asymbol *osym);
DESCRIPTION
Copy private symbol information from @var{isym} in the BFD
@var{ibfd} to the symbol @var{osym} in the BFD @var{obfd}.
- Return <<true>> on success, <<false>> on error. Possible error
+ Return <<TRUE>> on success, <<FALSE>> on error. Possible error
returns are:
o <<bfd_error_no_memory>> -
Not enough memory exists to create private data for @var{osec}.
.#define bfd_copy_private_symbol_data(ibfd, isymbol, obfd, osymbol) \
-. BFD_SEND (obfd, _bfd_copy_private_symbol_data, \
-. (ibfd, isymbol, obfd, osymbol))
+. BFD_SEND (obfd, _bfd_copy_private_symbol_data, \
+. (ibfd, isymbol, obfd, osymbol))
.
*/
@@ -771,11 +752,10 @@ DESCRIPTION
version. It just uses BFD asymbol structures as mini symbols. */
long
-_bfd_generic_read_minisymbols (abfd, dynamic, minisymsp, sizep)
- bfd *abfd;
- boolean dynamic;
- PTR *minisymsp;
- unsigned int *sizep;
+_bfd_generic_read_minisymbols (bfd *abfd,
+ bfd_boolean dynamic,
+ void **minisymsp,
+ unsigned int *sizep)
{
long storage;
asymbol **syms = NULL;
@@ -790,7 +770,7 @@ _bfd_generic_read_minisymbols (abfd, dynamic, minisymsp, sizep)
if (storage == 0)
return 0;
- syms = (asymbol **) bfd_malloc ((bfd_size_type) storage);
+ syms = bfd_malloc (storage);
if (syms == NULL)
goto error_return;
@@ -801,11 +781,12 @@ _bfd_generic_read_minisymbols (abfd, dynamic, minisymsp, sizep)
if (symcount < 0)
goto error_return;
- *minisymsp = (PTR) syms;
+ *minisymsp = syms;
*sizep = sizeof (asymbol *);
return symcount;
error_return:
+ bfd_set_error (bfd_error_no_symbols);
if (syms != NULL)
free (syms);
return -1;
@@ -815,13 +796,11 @@ _bfd_generic_read_minisymbols (abfd, dynamic, minisymsp, sizep)
an asymbol. We don't worry about the sym argument we are passed;
we just return the asymbol the minisymbol points to. */
-/*ARGSUSED*/
asymbol *
-_bfd_generic_minisymbol_to_symbol (abfd, dynamic, minisym, sym)
- bfd *abfd ATTRIBUTE_UNUSED;
- boolean dynamic ATTRIBUTE_UNUSED;
- const PTR minisym;
- asymbol *sym ATTRIBUTE_UNUSED;
+_bfd_generic_minisymbol_to_symbol (bfd *abfd ATTRIBUTE_UNUSED,
+ bfd_boolean dynamic ATTRIBUTE_UNUSED,
+ const void *minisym,
+ asymbol *sym ATTRIBUTE_UNUSED)
{
return *(asymbol **) minisym;
}
@@ -829,7 +808,7 @@ _bfd_generic_minisymbol_to_symbol (abfd, dynamic, minisym, sym)
/* Look through stabs debugging information in .stab and .stabstr
sections to find the source file and line closest to a desired
location. This is used by COFF and ELF targets. It sets *pfound
- to true if it finds some information. The *pinfo field is used to
+ to TRUE if it finds some information. The *pinfo field is used to
pass cached information in and out of this routine; this first time
the routine is called for a BFD, *pinfo should be NULL. The value
placed in *pinfo should be saved with the BFD, and passed back each
@@ -856,12 +835,10 @@ struct indexentry
/* Compare two indexentry structures. This is called via qsort. */
static int
-cmpindexentry (a, b)
- const PTR a;
- const PTR b;
+cmpindexentry (const void *a, const void *b)
{
- const struct indexentry *contestantA = (const struct indexentry *) a;
- const struct indexentry *contestantB = (const struct indexentry *) b;
+ const struct indexentry *contestantA = a;
+ const struct indexentry *contestantB = b;
if (contestantA->val < contestantB->val)
return -1;
@@ -901,18 +878,16 @@ struct stab_find_info
char *filename;
};
-boolean
-_bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
- pfilename, pfnname, pline, pinfo)
- bfd *abfd;
- asymbol **symbols;
- asection *section;
- bfd_vma offset;
- boolean *pfound;
- const char **pfilename;
- const char **pfnname;
- unsigned int *pline;
- PTR *pinfo;
+bfd_boolean
+_bfd_stab_section_find_nearest_line (bfd *abfd,
+ asymbol **symbols,
+ asection *section,
+ bfd_vma offset,
+ bfd_boolean *pfound,
+ const char **pfilename,
+ const char **pfnname,
+ unsigned int *pline,
+ void **pinfo)
{
struct stab_find_info *info;
bfd_size_type stabsize, strsize;
@@ -923,9 +898,9 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
char *file_name;
char *directory_name;
int saw_fun;
- boolean saw_line, saw_func;
+ bfd_boolean saw_line, saw_func;
- *pfound = false;
+ *pfound = FALSE;
*pfilename = bfd_get_filename (abfd);
*pfnname = NULL;
*pline = 0;
@@ -950,13 +925,13 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
#define VALOFF (8)
#define STABSIZE (12)
- info = (struct stab_find_info *) *pinfo;
+ info = *pinfo;
if (info != NULL)
{
if (info->stabsec == NULL || info->strsec == NULL)
{
/* No stabs debugging information. */
- return true;
+ return TRUE;
}
stabsize = info->stabsec->_raw_size;
@@ -971,9 +946,9 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
char *function_name;
bfd_size_type amt = sizeof *info;
- info = (struct stab_find_info *) bfd_zalloc (abfd, amt);
+ info = bfd_zalloc (abfd, amt);
if (info == NULL)
- return false;
+ return FALSE;
/* FIXME: When using the linker --split-by-file or
--split-by-reloc options, it is possible for the .stab and
@@ -986,41 +961,41 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
{
/* No stabs debugging information. Set *pinfo so that we
can return quickly in the info != NULL case above. */
- *pinfo = (PTR) info;
- return true;
+ *pinfo = info;
+ return TRUE;
}
stabsize = info->stabsec->_raw_size;
strsize = info->strsec->_raw_size;
- info->stabs = (bfd_byte *) bfd_alloc (abfd, stabsize);
- info->strs = (bfd_byte *) bfd_alloc (abfd, strsize);
+ info->stabs = bfd_alloc (abfd, stabsize);
+ info->strs = bfd_alloc (abfd, strsize);
if (info->stabs == NULL || info->strs == NULL)
- return false;
+ return FALSE;
if (! bfd_get_section_contents (abfd, info->stabsec, info->stabs,
(bfd_vma) 0, stabsize)
|| ! bfd_get_section_contents (abfd, info->strsec, info->strs,
(bfd_vma) 0, strsize))
- return false;
+ return FALSE;
- /* If this is a relocateable object file, we have to relocate
+ /* If this is a relocatable object file, we have to relocate
the entries in .stab. This should always be simple 32 bit
relocations against symbols defined in this object file, so
this should be no big deal. */
reloc_size = bfd_get_reloc_upper_bound (abfd, info->stabsec);
if (reloc_size < 0)
- return false;
- reloc_vector = (arelent **) bfd_malloc ((bfd_size_type) reloc_size);
+ return FALSE;
+ reloc_vector = bfd_malloc (reloc_size);
if (reloc_vector == NULL && reloc_size != 0)
- return false;
+ return FALSE;
reloc_count = bfd_canonicalize_reloc (abfd, info->stabsec, reloc_vector,
symbols);
if (reloc_count < 0)
{
if (reloc_vector != NULL)
free (reloc_vector);
- return false;
+ return FALSE;
}
if (reloc_count > 0)
{
@@ -1045,7 +1020,7 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
bfd_set_error (bfd_error_invalid_operation);
if (reloc_vector != NULL)
free (reloc_vector);
- return false;
+ return FALSE;
}
val = bfd_get_32 (abfd, info->stabs + r->address);
@@ -1099,14 +1074,14 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
++info->indextablesize;
if (info->indextablesize == 0)
- return true;
+ return TRUE;
++info->indextablesize;
amt = info->indextablesize;
amt *= sizeof (struct indexentry);
- info->indextable = (struct indexentry *) bfd_alloc (abfd, amt);
+ info->indextable = bfd_alloc (abfd, amt);
if (info->indextable == NULL)
- return false;
+ return FALSE;
file_name = NULL;
directory_name = NULL;
@@ -1225,7 +1200,7 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
qsort (info->indextable, (size_t) i, sizeof (struct indexentry),
cmpindexentry);
- *pinfo = (PTR) info;
+ *pinfo = info;
}
/* We are passed a section relative offset. The offsets in the
@@ -1244,12 +1219,11 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
else
#endif
{
- /* Cache non-existant or invalid. Do binary search on
- indextable. */
-
long low, high;
long mid = -1;
+ /* Cache non-existent or invalid. Do binary search on
+ indextable. */
indexentry = NULL;
low = 0;
@@ -1271,7 +1245,7 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
}
if (indexentry == NULL)
- return true;
+ return TRUE;
stab = indexentry->stab + STABSIZE;
file_name = indexentry->file_name;
@@ -1280,14 +1254,14 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
directory_name = indexentry->directory_name;
str = indexentry->str;
- saw_line = false;
- saw_func = false;
+ saw_line = FALSE;
+ saw_func = FALSE;
for (; stab < (indexentry+1)->stab; stab += STABSIZE)
{
- boolean done;
+ bfd_boolean done;
bfd_vma val;
- done = false;
+ done = FALSE;
switch (stab[TYPEOFF])
{
@@ -1304,9 +1278,11 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
case N_SLINE:
case N_DSLINE:
case N_BSLINE:
- /* A line number. The value is relative to the start of the
- current function. */
- val = indexentry->val + bfd_get_32 (abfd, stab + VALOFF);
+ /* A line number. If the function was specified, then the value
+ is relative to the start of the function. Otherwise, the
+ value is an absolute address. */
+ val = ((indexentry->function_name ? indexentry->val : 0)
+ + bfd_get_32 (abfd, stab + VALOFF));
/* If this line starts before our desired offset, or if it's
the first line we've been able to find, use it. The
!saw_line check works around a bug in GCC 2.95.3, which emits
@@ -1323,15 +1299,15 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
#endif
}
if (val > offset)
- done = true;
- saw_line = true;
+ done = TRUE;
+ saw_line = TRUE;
break;
case N_FUN:
case N_SO:
if (saw_func || saw_line)
- done = true;
- saw_func = true;
+ done = TRUE;
+ saw_func = TRUE;
break;
}
@@ -1339,7 +1315,7 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
break;
}
- *pfound = true;
+ *pfound = TRUE;
if (file_name == NULL || IS_ABSOLUTE_PATH (file_name)
|| directory_name == NULL)
@@ -1358,9 +1334,9 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
if (info->filename != NULL)
free (info->filename);
len = strlen (file_name) + 1;
- info->filename = (char *) bfd_malloc ((bfd_size_type) dirlen + len);
+ info->filename = bfd_malloc (dirlen + len);
if (info->filename == NULL)
- return false;
+ return FALSE;
memcpy (info->filename, directory_name, dirlen);
memcpy (info->filename + dirlen, file_name, len);
}
@@ -1375,7 +1351,6 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
/* This will typically be something like main:F(0,1), so we want
to clobber the colon. It's OK to change the name, since the
string is in our own local storage anyhow. */
-
s = strchr (indexentry->function_name, ':');
if (s != NULL)
*s = '\0';
@@ -1383,5 +1358,5 @@ _bfd_stab_section_find_nearest_line (abfd, symbols, section, offset, pfound,
*pfnname = indexentry->function_name;
}
- return true;
+ return TRUE;
}
diff --git a/contrib/binutils/bfd/sysdep.h b/contrib/binutils/bfd/sysdep.h
index 1338d6b..1954470 100644
--- a/contrib/binutils/bfd/sysdep.h
+++ b/contrib/binutils/bfd/sysdep.h
@@ -1,5 +1,5 @@
/* sysdep.h -- handle host dependencies for the BFD library
- Copyright 1995, 1996, 1997, 1998, 1999, 2000
+ Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001
Free Software Foundation, Inc.
Written by Cygnus Support.
diff --git a/contrib/binutils/bfd/targets.c b/contrib/binutils/bfd/targets.c
index 2d0ec04..cec339c 100644
--- a/contrib/binutils/bfd/targets.c
+++ b/contrib/binutils/bfd/targets.c
@@ -1,24 +1,24 @@
/* Generic target-file-type support for the BFD library.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
Written by Cygnus Support.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "bfd.h"
#include "sysdep.h"
@@ -30,7 +30,7 @@ SECTION
Targets
DESCRIPTION
- Each port of BFD to a different machine requries the creation
+ Each port of BFD to a different machine requires the creation
of a target back end. All the back end provides to the root
part of BFD is a structure containing pointers to functions
which perform certain low level operations on files. BFD
@@ -70,7 +70,7 @@ DESCRIPTION
<<bfd_check_format>> on the BFD with a suggested format.
If <<target_defaulted>> has been set, each possible target
type is tried to see if it recognizes the specified format.
- <<bfd_check_format>> returns <<true>> when the caller guesses right.
+ <<bfd_check_format>> returns <<TRUE>> when the caller guesses right.
@menu
@* bfd_target::
@end menu
@@ -103,7 +103,7 @@ DESCRIPTION
someone wants to fix this and not break the above, please do.
.#define BFD_SEND(bfd, message, arglist) \
-. ((*((bfd)->xvec->message)) arglist)
+. ((*((bfd)->xvec->message)) arglist)
.
.#ifdef DEBUG_BFD_SEND
.#undef BFD_SEND
@@ -116,7 +116,7 @@ DESCRIPTION
For operations which index on the BFD format:
.#define BFD_SEND_FMT(bfd, message, arglist) \
-. (((bfd)->xvec->message[(int) ((bfd)->format)]) arglist)
+. (((bfd)->xvec->message[(int) ((bfd)->format)]) arglist)
.
.#ifdef DEBUG_BFD_SEND
.#undef BFD_SEND_FMT
@@ -155,7 +155,11 @@ DESCRIPTION
. bfd_target_msdos_flavour,
. bfd_target_ovax_flavour,
. bfd_target_evax_flavour,
-. bfd_target_mmo_flavour
+. bfd_target_mmo_flavour,
+. bfd_target_mach_o_flavour,
+. bfd_target_pef_flavour,
+. bfd_target_pef_xlib_flavour,
+. bfd_target_sym_flavour
.};
.
.enum bfd_endian { BFD_ENDIAN_BIG, BFD_ENDIAN_LITTLE, BFD_ENDIAN_UNKNOWN };
@@ -199,262 +203,266 @@ DESCRIPTION
. {* Entries for byte swapping for data. These are different from the
. other entry points, since they don't take a BFD asthe first argument.
. Certain other handlers could do the same. *}
-. bfd_vma (*bfd_getx64) PARAMS ((const bfd_byte *));
-. bfd_signed_vma (*bfd_getx_signed_64) PARAMS ((const bfd_byte *));
-. void (*bfd_putx64) PARAMS ((bfd_vma, bfd_byte *));
-. bfd_vma (*bfd_getx32) PARAMS ((const bfd_byte *));
-. bfd_signed_vma (*bfd_getx_signed_32) PARAMS ((const bfd_byte *));
-. void (*bfd_putx32) PARAMS ((bfd_vma, bfd_byte *));
-. bfd_vma (*bfd_getx16) PARAMS ((const bfd_byte *));
-. bfd_signed_vma (*bfd_getx_signed_16) PARAMS ((const bfd_byte *));
-. void (*bfd_putx16) PARAMS ((bfd_vma, bfd_byte *));
+. bfd_uint64_t (*bfd_getx64) (const void *);
+. bfd_int64_t (*bfd_getx_signed_64) (const void *);
+. void (*bfd_putx64) (bfd_uint64_t, void *);
+. bfd_vma (*bfd_getx32) (const void *);
+. bfd_signed_vma (*bfd_getx_signed_32) (const void *);
+. void (*bfd_putx32) (bfd_vma, void *);
+. bfd_vma (*bfd_getx16) (const void *);
+. bfd_signed_vma (*bfd_getx_signed_16) (const void *);
+. void (*bfd_putx16) (bfd_vma, void *);
.
. {* Byte swapping for the headers. *}
-. bfd_vma (*bfd_h_getx64) PARAMS ((const bfd_byte *));
-. bfd_signed_vma (*bfd_h_getx_signed_64) PARAMS ((const bfd_byte *));
-. void (*bfd_h_putx64) PARAMS ((bfd_vma, bfd_byte *));
-. bfd_vma (*bfd_h_getx32) PARAMS ((const bfd_byte *));
-. bfd_signed_vma (*bfd_h_getx_signed_32) PARAMS ((const bfd_byte *));
-. void (*bfd_h_putx32) PARAMS ((bfd_vma, bfd_byte *));
-. bfd_vma (*bfd_h_getx16) PARAMS ((const bfd_byte *));
-. bfd_signed_vma (*bfd_h_getx_signed_16) PARAMS ((const bfd_byte *));
-. void (*bfd_h_putx16) PARAMS ((bfd_vma, bfd_byte *));
+. bfd_uint64_t (*bfd_h_getx64) (const void *);
+. bfd_int64_t (*bfd_h_getx_signed_64) (const void *);
+. void (*bfd_h_putx64) (bfd_uint64_t, void *);
+. bfd_vma (*bfd_h_getx32) (const void *);
+. bfd_signed_vma (*bfd_h_getx_signed_32) (const void *);
+. void (*bfd_h_putx32) (bfd_vma, void *);
+. bfd_vma (*bfd_h_getx16) (const void *);
+. bfd_signed_vma (*bfd_h_getx_signed_16) (const void *);
+. void (*bfd_h_putx16) (bfd_vma, void *);
.
. {* Format dependent routines: these are vectors of entry points
. within the target vector structure, one for each format to check. *}
.
. {* Check the format of a file being read. Return a <<bfd_target *>> or zero. *}
-. const struct bfd_target *(*_bfd_check_format[bfd_type_end]) PARAMS ((bfd *));
+. const struct bfd_target *(*_bfd_check_format[bfd_type_end]) (bfd *);
.
. {* Set the format of a file being written. *}
-. boolean (*_bfd_set_format[bfd_type_end]) PARAMS ((bfd *));
+. bfd_boolean (*_bfd_set_format[bfd_type_end]) (bfd *);
.
. {* Write cached information into a file being written, at <<bfd_close>>. *}
-. boolean (*_bfd_write_contents[bfd_type_end]) PARAMS ((bfd *));
+. bfd_boolean (*_bfd_write_contents[bfd_type_end]) (bfd *);
.
The general target vector. These vectors are initialized using the
BFD_JUMP_TABLE macros.
.
. {* Generic entry points. *}
-Do not "beautify" the CONCAT* macro args. Traditional C will not
-remove whitespace added here, and thus will fail to concatenate
-the tokens.
.#define BFD_JUMP_TABLE_GENERIC(NAME) \
-.CONCAT2 (NAME,_close_and_cleanup), \
-.CONCAT2 (NAME,_bfd_free_cached_info), \
-.CONCAT2 (NAME,_new_section_hook), \
-.CONCAT2 (NAME,_get_section_contents), \
-.CONCAT2 (NAME,_get_section_contents_in_window)
+. NAME##_close_and_cleanup, \
+. NAME##_bfd_free_cached_info, \
+. NAME##_new_section_hook, \
+. NAME##_get_section_contents, \
+. NAME##_get_section_contents_in_window
.
. {* Called when the BFD is being closed to do any necessary cleanup. *}
-. boolean (*_close_and_cleanup) PARAMS ((bfd *));
+. bfd_boolean (*_close_and_cleanup) (bfd *);
. {* Ask the BFD to free all cached information. *}
-. boolean (*_bfd_free_cached_info) PARAMS ((bfd *));
+. bfd_boolean (*_bfd_free_cached_info) (bfd *);
. {* Called when a new section is created. *}
-. boolean (*_new_section_hook) PARAMS ((bfd *, sec_ptr));
+. bfd_boolean (*_new_section_hook) (bfd *, sec_ptr);
. {* Read the contents of a section. *}
-. boolean (*_bfd_get_section_contents) PARAMS ((bfd *, sec_ptr, PTR,
-. file_ptr, bfd_size_type));
-. boolean (*_bfd_get_section_contents_in_window)
-. PARAMS ((bfd *, sec_ptr, bfd_window *, file_ptr, bfd_size_type));
+. bfd_boolean (*_bfd_get_section_contents)
+. (bfd *, sec_ptr, void *, file_ptr, bfd_size_type);
+. bfd_boolean (*_bfd_get_section_contents_in_window)
+. (bfd *, sec_ptr, bfd_window *, file_ptr, bfd_size_type);
.
. {* Entry points to copy private data. *}
.#define BFD_JUMP_TABLE_COPY(NAME) \
-.CONCAT2 (NAME,_bfd_copy_private_bfd_data), \
-.CONCAT2 (NAME,_bfd_merge_private_bfd_data), \
-.CONCAT2 (NAME,_bfd_copy_private_section_data), \
-.CONCAT2 (NAME,_bfd_copy_private_symbol_data), \
-.CONCAT2 (NAME,_bfd_set_private_flags), \
-.CONCAT2 (NAME,_bfd_print_private_bfd_data) \
+. NAME##_bfd_copy_private_bfd_data, \
+. NAME##_bfd_merge_private_bfd_data, \
+. NAME##_bfd_copy_private_section_data, \
+. NAME##_bfd_copy_private_symbol_data, \
+. NAME##_bfd_set_private_flags, \
+. NAME##_bfd_print_private_bfd_data
+.
. {* Called to copy BFD general private data from one object file
. to another. *}
-. boolean (*_bfd_copy_private_bfd_data) PARAMS ((bfd *, bfd *));
+. bfd_boolean (*_bfd_copy_private_bfd_data) (bfd *, bfd *);
. {* Called to merge BFD general private data from one object file
. to a common output file when linking. *}
-. boolean (*_bfd_merge_private_bfd_data) PARAMS ((bfd *, bfd *));
+. bfd_boolean (*_bfd_merge_private_bfd_data) (bfd *, bfd *);
. {* Called to copy BFD private section data from one object file
. to another. *}
-. boolean (*_bfd_copy_private_section_data) PARAMS ((bfd *, sec_ptr,
-. bfd *, sec_ptr));
+. bfd_boolean (*_bfd_copy_private_section_data)
+. (bfd *, sec_ptr, bfd *, sec_ptr);
. {* Called to copy BFD private symbol data from one symbol
. to another. *}
-. boolean (*_bfd_copy_private_symbol_data) PARAMS ((bfd *, asymbol *,
-. bfd *, asymbol *));
+. bfd_boolean (*_bfd_copy_private_symbol_data)
+. (bfd *, asymbol *, bfd *, asymbol *);
. {* Called to set private backend flags. *}
-. boolean (*_bfd_set_private_flags) PARAMS ((bfd *, flagword));
+. bfd_boolean (*_bfd_set_private_flags) (bfd *, flagword);
.
. {* Called to print private BFD data. *}
-. boolean (*_bfd_print_private_bfd_data) PARAMS ((bfd *, PTR));
+. bfd_boolean (*_bfd_print_private_bfd_data) (bfd *, void *);
.
. {* Core file entry points. *}
.#define BFD_JUMP_TABLE_CORE(NAME) \
-.CONCAT2 (NAME,_core_file_failing_command), \
-.CONCAT2 (NAME,_core_file_failing_signal), \
-.CONCAT2 (NAME,_core_file_matches_executable_p)
-. char * (*_core_file_failing_command) PARAMS ((bfd *));
-. int (*_core_file_failing_signal) PARAMS ((bfd *));
-. boolean (*_core_file_matches_executable_p) PARAMS ((bfd *, bfd *));
+. NAME##_core_file_failing_command, \
+. NAME##_core_file_failing_signal, \
+. NAME##_core_file_matches_executable_p
+.
+. char * (*_core_file_failing_command) (bfd *);
+. int (*_core_file_failing_signal) (bfd *);
+. bfd_boolean (*_core_file_matches_executable_p) (bfd *, bfd *);
.
. {* Archive entry points. *}
.#define BFD_JUMP_TABLE_ARCHIVE(NAME) \
-.CONCAT2 (NAME,_slurp_armap), \
-.CONCAT2 (NAME,_slurp_extended_name_table), \
-.CONCAT2 (NAME,_construct_extended_name_table), \
-.CONCAT2 (NAME,_truncate_arname), \
-.CONCAT2 (NAME,_write_armap), \
-.CONCAT2 (NAME,_read_ar_hdr), \
-.CONCAT2 (NAME,_openr_next_archived_file), \
-.CONCAT2 (NAME,_get_elt_at_index), \
-.CONCAT2 (NAME,_generic_stat_arch_elt), \
-.CONCAT2 (NAME,_update_armap_timestamp)
-. boolean (*_bfd_slurp_armap) PARAMS ((bfd *));
-. boolean (*_bfd_slurp_extended_name_table) PARAMS ((bfd *));
-. boolean (*_bfd_construct_extended_name_table)
-. PARAMS ((bfd *, char **, bfd_size_type *, const char **));
-. void (*_bfd_truncate_arname) PARAMS ((bfd *, const char *, char *));
-. boolean (*write_armap)
-. PARAMS ((bfd *, unsigned int, struct orl *, unsigned int, int));
-. PTR (*_bfd_read_ar_hdr_fn) PARAMS ((bfd *));
-. bfd * (*openr_next_archived_file) PARAMS ((bfd *, bfd *));
-.#define bfd_get_elt_at_index(b,i) BFD_SEND(b, _bfd_get_elt_at_index, (b,i))
-. bfd * (*_bfd_get_elt_at_index) PARAMS ((bfd *, symindex));
-. int (*_bfd_stat_arch_elt) PARAMS ((bfd *, struct stat *));
-. boolean (*_bfd_update_armap_timestamp) PARAMS ((bfd *));
+. NAME##_slurp_armap, \
+. NAME##_slurp_extended_name_table, \
+. NAME##_construct_extended_name_table, \
+. NAME##_truncate_arname, \
+. NAME##_write_armap, \
+. NAME##_read_ar_hdr, \
+. NAME##_openr_next_archived_file, \
+. NAME##_get_elt_at_index, \
+. NAME##_generic_stat_arch_elt, \
+. NAME##_update_armap_timestamp
+.
+. bfd_boolean (*_bfd_slurp_armap) (bfd *);
+. bfd_boolean (*_bfd_slurp_extended_name_table) (bfd *);
+. bfd_boolean (*_bfd_construct_extended_name_table)
+. (bfd *, char **, bfd_size_type *, const char **);
+. void (*_bfd_truncate_arname) (bfd *, const char *, char *);
+. bfd_boolean (*write_armap)
+. (bfd *, unsigned int, struct orl *, unsigned int, int);
+. void * (*_bfd_read_ar_hdr_fn) (bfd *);
+. bfd * (*openr_next_archived_file) (bfd *, bfd *);
+.#define bfd_get_elt_at_index(b,i) BFD_SEND (b, _bfd_get_elt_at_index, (b,i))
+. bfd * (*_bfd_get_elt_at_index) (bfd *, symindex);
+. int (*_bfd_stat_arch_elt) (bfd *, struct stat *);
+. bfd_boolean (*_bfd_update_armap_timestamp) (bfd *);
.
. {* Entry points used for symbols. *}
.#define BFD_JUMP_TABLE_SYMBOLS(NAME) \
-.CONCAT2 (NAME,_get_symtab_upper_bound), \
-.CONCAT2 (NAME,_get_symtab), \
-.CONCAT2 (NAME,_make_empty_symbol), \
-.CONCAT2 (NAME,_print_symbol), \
-.CONCAT2 (NAME,_get_symbol_info), \
-.CONCAT2 (NAME,_bfd_is_local_label_name), \
-.CONCAT2 (NAME,_get_lineno), \
-.CONCAT2 (NAME,_find_nearest_line), \
-.CONCAT2 (NAME,_bfd_make_debug_symbol), \
-.CONCAT2 (NAME,_read_minisymbols), \
-.CONCAT2 (NAME,_minisymbol_to_symbol)
-. long (*_bfd_get_symtab_upper_bound) PARAMS ((bfd *));
-. long (*_bfd_canonicalize_symtab) PARAMS ((bfd *,
-. struct symbol_cache_entry **));
-. struct symbol_cache_entry *
-. (*_bfd_make_empty_symbol) PARAMS ((bfd *));
-. void (*_bfd_print_symbol) PARAMS ((bfd *, PTR,
-. struct symbol_cache_entry *,
-. bfd_print_symbol_type));
-.#define bfd_print_symbol(b,p,s,e) BFD_SEND(b, _bfd_print_symbol, (b,p,s,e))
-. void (*_bfd_get_symbol_info) PARAMS ((bfd *,
-. struct symbol_cache_entry *,
-. symbol_info *));
-.#define bfd_get_symbol_info(b,p,e) BFD_SEND(b, _bfd_get_symbol_info, (b,p,e))
-. boolean (*_bfd_is_local_label_name) PARAMS ((bfd *, const char *));
+. NAME##_get_symtab_upper_bound, \
+. NAME##_canonicalize_symtab, \
+. NAME##_make_empty_symbol, \
+. NAME##_print_symbol, \
+. NAME##_get_symbol_info, \
+. NAME##_bfd_is_local_label_name, \
+. NAME##_get_lineno, \
+. NAME##_find_nearest_line, \
+. NAME##_bfd_make_debug_symbol, \
+. NAME##_read_minisymbols, \
+. NAME##_minisymbol_to_symbol
.
-. alent * (*_get_lineno) PARAMS ((bfd *, struct symbol_cache_entry *));
-. boolean (*_bfd_find_nearest_line)
-. PARAMS ((bfd *, struct sec *, struct symbol_cache_entry **, bfd_vma,
-. const char **, const char **, unsigned int *));
+. long (*_bfd_get_symtab_upper_bound) (bfd *);
+. long (*_bfd_canonicalize_symtab)
+. (bfd *, struct bfd_symbol **);
+. struct bfd_symbol *
+. (*_bfd_make_empty_symbol) (bfd *);
+. void (*_bfd_print_symbol)
+. (bfd *, void *, struct bfd_symbol *, bfd_print_symbol_type);
+.#define bfd_print_symbol(b,p,s,e) BFD_SEND (b, _bfd_print_symbol, (b,p,s,e))
+. void (*_bfd_get_symbol_info)
+. (bfd *, struct bfd_symbol *, symbol_info *);
+.#define bfd_get_symbol_info(b,p,e) BFD_SEND (b, _bfd_get_symbol_info, (b,p,e))
+. bfd_boolean (*_bfd_is_local_label_name) (bfd *, const char *);
+.
+. alent * (*_get_lineno) (bfd *, struct bfd_symbol *);
+. bfd_boolean (*_bfd_find_nearest_line)
+. (bfd *, struct bfd_section *, struct bfd_symbol **, bfd_vma,
+. const char **, const char **, unsigned int *);
. {* Back-door to allow format-aware applications to create debug symbols
. while using BFD for everything else. Currently used by the assembler
. when creating COFF files. *}
-. asymbol *(*_bfd_make_debug_symbol) PARAMS ((bfd *, void *,
-. unsigned long size));
+. asymbol * (*_bfd_make_debug_symbol)
+. (bfd *, void *, unsigned long size);
.#define bfd_read_minisymbols(b, d, m, s) \
. BFD_SEND (b, _read_minisymbols, (b, d, m, s))
-. long (*_read_minisymbols) PARAMS ((bfd *, boolean, PTR *,
-. unsigned int *));
+. long (*_read_minisymbols)
+. (bfd *, bfd_boolean, void **, unsigned int *);
.#define bfd_minisymbol_to_symbol(b, d, m, f) \
. BFD_SEND (b, _minisymbol_to_symbol, (b, d, m, f))
-. asymbol *(*_minisymbol_to_symbol) PARAMS ((bfd *, boolean, const PTR,
-. asymbol *));
+. asymbol * (*_minisymbol_to_symbol)
+. (bfd *, bfd_boolean, const void *, asymbol *);
.
. {* Routines for relocs. *}
.#define BFD_JUMP_TABLE_RELOCS(NAME) \
-.CONCAT2 (NAME,_get_reloc_upper_bound), \
-.CONCAT2 (NAME,_canonicalize_reloc), \
-.CONCAT2 (NAME,_bfd_reloc_type_lookup)
-. long (*_get_reloc_upper_bound) PARAMS ((bfd *, sec_ptr));
-. long (*_bfd_canonicalize_reloc) PARAMS ((bfd *, sec_ptr, arelent **,
-. struct symbol_cache_entry **));
+. NAME##_get_reloc_upper_bound, \
+. NAME##_canonicalize_reloc, \
+. NAME##_bfd_reloc_type_lookup
+.
+. long (*_get_reloc_upper_bound) (bfd *, sec_ptr);
+. long (*_bfd_canonicalize_reloc)
+. (bfd *, sec_ptr, arelent **, struct bfd_symbol **);
. {* See documentation on reloc types. *}
. reloc_howto_type *
-. (*reloc_type_lookup) PARAMS ((bfd *, bfd_reloc_code_real_type));
+. (*reloc_type_lookup) (bfd *, bfd_reloc_code_real_type);
.
. {* Routines used when writing an object file. *}
.#define BFD_JUMP_TABLE_WRITE(NAME) \
-.CONCAT2 (NAME,_set_arch_mach), \
-.CONCAT2 (NAME,_set_section_contents)
-. boolean (*_bfd_set_arch_mach) PARAMS ((bfd *, enum bfd_architecture,
-. unsigned long));
-. boolean (*_bfd_set_section_contents) PARAMS ((bfd *, sec_ptr, PTR,
-. file_ptr, bfd_size_type));
+. NAME##_set_arch_mach, \
+. NAME##_set_section_contents
+.
+. bfd_boolean (*_bfd_set_arch_mach)
+. (bfd *, enum bfd_architecture, unsigned long);
+. bfd_boolean (*_bfd_set_section_contents)
+. (bfd *, sec_ptr, const void *, file_ptr, bfd_size_type);
.
. {* Routines used by the linker. *}
.#define BFD_JUMP_TABLE_LINK(NAME) \
-.CONCAT2 (NAME,_sizeof_headers), \
-.CONCAT2 (NAME,_bfd_get_relocated_section_contents), \
-.CONCAT2 (NAME,_bfd_relax_section), \
-.CONCAT2 (NAME,_bfd_link_hash_table_create), \
-.CONCAT2 (NAME,_bfd_link_hash_table_free), \
-.CONCAT2 (NAME,_bfd_link_add_symbols), \
-.CONCAT2 (NAME,_bfd_link_just_syms), \
-.CONCAT2 (NAME,_bfd_final_link), \
-.CONCAT2 (NAME,_bfd_link_split_section), \
-.CONCAT2 (NAME,_bfd_gc_sections), \
-.CONCAT2 (NAME,_bfd_merge_sections), \
-.CONCAT2 (NAME,_bfd_discard_group)
-. int (*_bfd_sizeof_headers) PARAMS ((bfd *, boolean));
-. bfd_byte *(*_bfd_get_relocated_section_contents)
-. PARAMS ((bfd *, struct bfd_link_info *, struct bfd_link_order *,
-. bfd_byte *, boolean, struct symbol_cache_entry **));
+. NAME##_sizeof_headers, \
+. NAME##_bfd_get_relocated_section_contents, \
+. NAME##_bfd_relax_section, \
+. NAME##_bfd_link_hash_table_create, \
+. NAME##_bfd_link_hash_table_free, \
+. NAME##_bfd_link_add_symbols, \
+. NAME##_bfd_link_just_syms, \
+. NAME##_bfd_final_link, \
+. NAME##_bfd_link_split_section, \
+. NAME##_bfd_gc_sections, \
+. NAME##_bfd_merge_sections, \
+. NAME##_bfd_discard_group
+.
+. int (*_bfd_sizeof_headers) (bfd *, bfd_boolean);
+. bfd_byte * (*_bfd_get_relocated_section_contents)
+. (bfd *, struct bfd_link_info *, struct bfd_link_order *,
+. bfd_byte *, bfd_boolean, struct bfd_symbol **);
.
-. boolean (*_bfd_relax_section)
-. PARAMS ((bfd *, struct sec *, struct bfd_link_info *, boolean *));
+. bfd_boolean (*_bfd_relax_section)
+. (bfd *, struct bfd_section *, struct bfd_link_info *, bfd_boolean *);
.
. {* Create a hash table for the linker. Different backends store
. different information in this table. *}
-. struct bfd_link_hash_table *(*_bfd_link_hash_table_create) PARAMS ((bfd *));
+. struct bfd_link_hash_table *
+. (*_bfd_link_hash_table_create) (bfd *);
.
. {* Release the memory associated with the linker hash table. *}
-. void (*_bfd_link_hash_table_free) PARAMS ((struct bfd_link_hash_table *));
+. void (*_bfd_link_hash_table_free) (struct bfd_link_hash_table *);
.
. {* Add symbols from this object file into the hash table. *}
-. boolean (*_bfd_link_add_symbols) PARAMS ((bfd *, struct bfd_link_info *));
+. bfd_boolean (*_bfd_link_add_symbols) (bfd *, struct bfd_link_info *);
.
. {* Indicate that we are only retrieving symbol values from this section. *}
-. void (*_bfd_link_just_syms) PARAMS ((asection *, struct bfd_link_info *));
+. void (*_bfd_link_just_syms) (asection *, struct bfd_link_info *);
.
. {* Do a link based on the link_order structures attached to each
. section of the BFD. *}
-. boolean (*_bfd_final_link) PARAMS ((bfd *, struct bfd_link_info *));
+. bfd_boolean (*_bfd_final_link) (bfd *, struct bfd_link_info *);
.
. {* Should this section be split up into smaller pieces during linking. *}
-. boolean (*_bfd_link_split_section) PARAMS ((bfd *, struct sec *));
+. bfd_boolean (*_bfd_link_split_section) (bfd *, struct bfd_section *);
.
. {* Remove sections that are not referenced from the output. *}
-. boolean (*_bfd_gc_sections) PARAMS ((bfd *, struct bfd_link_info *));
+. bfd_boolean (*_bfd_gc_sections) (bfd *, struct bfd_link_info *);
.
. {* Attempt to merge SEC_MERGE sections. *}
-. boolean (*_bfd_merge_sections) PARAMS ((bfd *, struct bfd_link_info *));
+. bfd_boolean (*_bfd_merge_sections) (bfd *, struct bfd_link_info *);
.
. {* Discard members of a group. *}
-. boolean (*_bfd_discard_group) PARAMS ((bfd *, struct sec *));
+. bfd_boolean (*_bfd_discard_group) (bfd *, struct bfd_section *);
.
. {* Routines to handle dynamic symbols and relocs. *}
.#define BFD_JUMP_TABLE_DYNAMIC(NAME) \
-.CONCAT2 (NAME,_get_dynamic_symtab_upper_bound), \
-.CONCAT2 (NAME,_canonicalize_dynamic_symtab), \
-.CONCAT2 (NAME,_get_dynamic_reloc_upper_bound), \
-.CONCAT2 (NAME,_canonicalize_dynamic_reloc)
+. NAME##_get_dynamic_symtab_upper_bound, \
+. NAME##_canonicalize_dynamic_symtab, \
+. NAME##_get_dynamic_reloc_upper_bound, \
+. NAME##_canonicalize_dynamic_reloc
+.
. {* Get the amount of memory required to hold the dynamic symbols. *}
-. long (*_bfd_get_dynamic_symtab_upper_bound) PARAMS ((bfd *));
+. long (*_bfd_get_dynamic_symtab_upper_bound) (bfd *);
. {* Read in the dynamic symbols. *}
-. long (*_bfd_canonicalize_dynamic_symtab)
-. PARAMS ((bfd *, struct symbol_cache_entry **));
+. long (*_bfd_canonicalize_dynamic_symtab)
+. (bfd *, struct bfd_symbol **);
. {* Get the amount of memory required to hold the dynamic relocs. *}
-. long (*_bfd_get_dynamic_reloc_upper_bound) PARAMS ((bfd *));
+. long (*_bfd_get_dynamic_reloc_upper_bound) (bfd *);
. {* Read in the dynamic relocs. *}
-. long (*_bfd_canonicalize_dynamic_reloc)
-. PARAMS ((bfd *, arelent **, struct symbol_cache_entry **));
+. long (*_bfd_canonicalize_dynamic_reloc)
+. (bfd *, arelent **, struct bfd_symbol **);
.
A pointer to an alternative bfd_target in case the current one is not
@@ -469,7 +477,7 @@ to find an alternative output format that is suitable.
. {* Data for use by back-end routines, which isn't
. generic enough to belong in this structure. *}
-. PTR backend_data;
+. const void *backend_data;
.
.} bfd_target;
.
@@ -515,6 +523,7 @@ extern const bfd_target bfd_elf32_d30v_vec;
extern const bfd_target bfd_elf32_dlx_big_vec;
extern const bfd_target bfd_elf32_fr30_vec;
extern const bfd_target bfd_elf32_frv_vec;
+extern const bfd_target bfd_elf32_frvfdpic_vec;
extern const bfd_target bfd_elf32_h8300_vec;
extern const bfd_target bfd_elf32_hppa_linux_vec;
extern const bfd_target bfd_elf32_hppa_vec;
@@ -526,12 +535,17 @@ extern const bfd_target bfd_elf32_i860_vec;
extern const bfd_target bfd_elf32_i960_vec;
extern const bfd_target bfd_elf32_ia64_big_vec;
extern const bfd_target bfd_elf32_ia64_hpux_big_vec;
+extern const bfd_target bfd_elf32_ip2k_vec;
+extern const bfd_target bfd_elf32_iq2000_vec;
extern const bfd_target bfd_elf32_little_generic_vec;
extern const bfd_target bfd_elf32_littlearc_vec;
extern const bfd_target bfd_elf32_littlearm_oabi_vec;
extern const bfd_target bfd_elf32_littlearm_vec;
extern const bfd_target bfd_elf32_littlemips_vec;
extern const bfd_target bfd_elf32_m32r_vec;
+extern const bfd_target bfd_elf32_m32rle_vec;
+extern const bfd_target bfd_elf32_m32rlin_vec;
+extern const bfd_target bfd_elf32_m32rlelin_vec;
extern const bfd_target bfd_elf32_m68hc11_vec;
extern const bfd_target bfd_elf32_m68hc12_vec;
extern const bfd_target bfd_elf32_m68k_vec;
@@ -540,6 +554,11 @@ extern const bfd_target bfd_elf32_mcore_big_vec;
extern const bfd_target bfd_elf32_mcore_little_vec;
extern const bfd_target bfd_elf32_mn10200_vec;
extern const bfd_target bfd_elf32_mn10300_vec;
+extern const bfd_target bfd_elf32_msp430_vec;
+extern const bfd_target bfd_elf32_nbigmips_vec;
+extern const bfd_target bfd_elf32_nlittlemips_vec;
+extern const bfd_target bfd_elf32_ntradbigmips_vec;
+extern const bfd_target bfd_elf32_ntradlittlemips_vec;
extern const bfd_target bfd_elf32_openrisc_vec;
extern const bfd_target bfd_elf32_or32_big_vec;
extern const bfd_target bfd_elf32_pj_vec;
@@ -549,6 +568,8 @@ extern const bfd_target bfd_elf32_powerpcle_vec;
extern const bfd_target bfd_elf32_s390_vec;
extern const bfd_target bfd_elf32_sh64_vec;
extern const bfd_target bfd_elf32_sh64l_vec;
+extern const bfd_target bfd_elf32_sh64lin_vec;
+extern const bfd_target bfd_elf32_sh64blin_vec;
extern const bfd_target bfd_elf32_sh64lnbsd_vec;
extern const bfd_target bfd_elf32_sh64nbsd_vec;
extern const bfd_target bfd_elf32_sh_vec;
@@ -564,14 +585,14 @@ extern const bfd_target bfd_elf32_us_cris_vec;
extern const bfd_target bfd_elf32_v850_vec;
extern const bfd_target bfd_elf32_vax_vec;
extern const bfd_target bfd_elf32_xstormy16_vec;
+extern const bfd_target bfd_elf32_xtensa_be_vec;
+extern const bfd_target bfd_elf32_xtensa_le_vec;
extern const bfd_target bfd_elf64_alpha_freebsd_vec;
extern const bfd_target bfd_elf64_alpha_vec;
extern const bfd_target bfd_elf64_big_generic_vec;
extern const bfd_target bfd_elf64_bigmips_vec;
extern const bfd_target bfd_elf64_hppa_linux_vec;
extern const bfd_target bfd_elf64_hppa_vec;
-extern const bfd_target bfd_elf64_ia64_aix_big_vec;
-extern const bfd_target bfd_elf64_ia64_aix_little_vec;
extern const bfd_target bfd_elf64_ia64_big_vec;
extern const bfd_target bfd_elf64_ia64_hpux_big_vec;
extern const bfd_target bfd_elf64_ia64_little_vec;
@@ -583,6 +604,8 @@ extern const bfd_target bfd_elf64_powerpcle_vec;
extern const bfd_target bfd_elf64_s390_vec;
extern const bfd_target bfd_elf64_sh64_vec;
extern const bfd_target bfd_elf64_sh64l_vec;
+extern const bfd_target bfd_elf64_sh64lin_vec;
+extern const bfd_target bfd_elf64_sh64blin_vec;
extern const bfd_target bfd_elf64_sh64lnbsd_vec;
extern const bfd_target bfd_elf64_sh64nbsd_vec;
extern const bfd_target bfd_elf64_sparc_vec;
@@ -636,6 +659,9 @@ extern const bfd_target m68knetbsd_vec;
extern const bfd_target m68ksysvcoff_vec;
extern const bfd_target m88kbcs_vec;
extern const bfd_target m88kmach3_vec;
+extern const bfd_target mach_o_be_vec;
+extern const bfd_target mach_o_le_vec;
+extern const bfd_target mach_o_fat_vec;
extern const bfd_target mcore_pe_big_vec;
extern const bfd_target mcore_pe_little_vec;
extern const bfd_target mcore_pei_big_vec;
@@ -652,6 +678,8 @@ extern const bfd_target or32coff_big_vec;
extern const bfd_target pc532machaout_vec;
extern const bfd_target pc532netbsd_vec;
extern const bfd_target pdp11_aout_vec;
+extern const bfd_target pef_vec;
+extern const bfd_target pef_xlib_vec;
extern const bfd_target pmac_xcoff_vec;
extern const bfd_target ppcboot_vec;
extern const bfd_target riscix_vec;
@@ -671,8 +699,15 @@ extern const bfd_target sparclynx_aout_vec;
extern const bfd_target sparclynx_coff_vec;
extern const bfd_target sparcnetbsd_vec;
extern const bfd_target sunos_big_vec;
+extern const bfd_target sym_vec;
extern const bfd_target tic30_aout_vec;
extern const bfd_target tic30_coff_vec;
+extern const bfd_target tic4x_coff0_beh_vec;
+extern const bfd_target tic4x_coff0_vec;
+extern const bfd_target tic4x_coff1_beh_vec;
+extern const bfd_target tic4x_coff1_vec;
+extern const bfd_target tic4x_coff2_beh_vec;
+extern const bfd_target tic4x_coff2_vec;
extern const bfd_target tic54x_coff0_beh_vec;
extern const bfd_target tic54x_coff0_vec;
extern const bfd_target tic54x_coff1_beh_vec;
@@ -710,6 +745,7 @@ extern const bfd_target ptrace_core_vec;
extern const bfd_target sco5_core_vec;
extern const bfd_target trad_core_vec;
+extern const bfd_target bfd_elf32_am33lin_vec;
static const bfd_target * const _bfd_target_vector[] = {
#ifdef SELECT_VECS
@@ -734,7 +770,7 @@ static const bfd_target * const _bfd_target_vector[] = {
#endif
&aout0_big_vec,
#if 0
- /* We have no way of distinguishing these from other a.out variants */
+ /* We have no way of distinguishing these from other a.out variants. */
&aout_arm_big_vec,
&aout_arm_little_vec,
/* No one seems to use this. */
@@ -778,6 +814,7 @@ static const bfd_target * const _bfd_target_vector[] = {
&bfd_elf32_dlx_big_vec,
&bfd_elf32_fr30_vec,
&bfd_elf32_frv_vec,
+ &bfd_elf32_frvfdpic_vec,
&bfd_elf32_h8300_vec,
&bfd_elf32_hppa_linux_vec,
&bfd_elf32_hppa_vec,
@@ -791,12 +828,17 @@ static const bfd_target * const _bfd_target_vector[] = {
&bfd_elf32_ia64_big_vec,
#endif
&bfd_elf32_ia64_hpux_big_vec,
+ &bfd_elf32_ip2k_vec,
+ &bfd_elf32_iq2000_vec,
&bfd_elf32_little_generic_vec,
&bfd_elf32_littlearc_vec,
&bfd_elf32_littlearm_oabi_vec,
&bfd_elf32_littlearm_vec,
&bfd_elf32_littlemips_vec,
&bfd_elf32_m32r_vec,
+ &bfd_elf32_m32rle_vec,
+ &bfd_elf32_m32rlin_vec,
+ &bfd_elf32_m32rlelin_vec,
&bfd_elf32_m68hc11_vec,
&bfd_elf32_m68hc12_vec,
&bfd_elf32_m68k_vec,
@@ -805,6 +847,13 @@ static const bfd_target * const _bfd_target_vector[] = {
&bfd_elf32_mcore_little_vec,
&bfd_elf32_mn10200_vec,
&bfd_elf32_mn10300_vec,
+ &bfd_elf32_msp430_vec,
+#ifdef BFD64
+ &bfd_elf32_nbigmips_vec,
+ &bfd_elf32_nlittlemips_vec,
+ &bfd_elf32_ntradbigmips_vec,
+ &bfd_elf32_ntradlittlemips_vec,
+#endif
&bfd_elf32_openrisc_vec,
&bfd_elf32_or32_big_vec,
&bfd_elf32_pj_vec,
@@ -823,6 +872,8 @@ static const bfd_target * const _bfd_target_vector[] = {
&bfd_elf32_sh64l_vec,
&bfd_elf32_sh64lnbsd_vec,
&bfd_elf32_sh64nbsd_vec,
+ &bfd_elf32_sh64lin_vec,
+ &bfd_elf32_sh64blin_vec,
#endif
&bfd_elf32_sparc_vec,
&bfd_elf32_tradbigmips_vec,
@@ -831,6 +882,8 @@ static const bfd_target * const _bfd_target_vector[] = {
&bfd_elf32_v850_vec,
&bfd_elf32_vax_vec,
&bfd_elf32_xstormy16_vec,
+ &bfd_elf32_xtensa_be_vec,
+ &bfd_elf32_xtensa_le_vec,
#ifdef BFD64
&bfd_elf64_alpha_freebsd_vec,
&bfd_elf64_alpha_vec,
@@ -838,8 +891,6 @@ static const bfd_target * const _bfd_target_vector[] = {
&bfd_elf64_bigmips_vec,
&bfd_elf64_hppa_linux_vec,
&bfd_elf64_hppa_vec,
- &bfd_elf64_ia64_aix_big_vec,
- &bfd_elf64_ia64_aix_little_vec,
&bfd_elf64_ia64_big_vec,
&bfd_elf64_ia64_hpux_big_vec,
&bfd_elf64_ia64_little_vec,
@@ -853,9 +904,9 @@ static const bfd_target * const _bfd_target_vector[] = {
&bfd_elf64_sh64l_vec,
&bfd_elf64_sh64lnbsd_vec,
&bfd_elf64_sh64nbsd_vec,
-#if 0
+ &bfd_elf64_sh64lin_vec,
+ &bfd_elf64_sh64blin_vec,
&bfd_elf64_sparc_vec,
-#endif
&bfd_elf64_tradbigmips_vec,
&bfd_elf64_tradlittlemips_vec,
&bfd_elf64_x86_64_vec,
@@ -867,7 +918,7 @@ static const bfd_target * const _bfd_target_vector[] = {
&bfd_powerpcle_pei_vec,
&cris_aout_vec,
#ifdef BFD64
- &demo_64_vec, /* Only compiled if host has long-long support */
+ &demo_64_vec, /* Only compiled if host has long-long support. */
#endif
&ecoff_big_vec,
&ecoff_biglittle_vec,
@@ -931,6 +982,9 @@ static const bfd_target * const _bfd_target_vector[] = {
&m68ksysvcoff_vec,
&m88kbcs_vec,
&m88kmach3_vec,
+ &mach_o_be_vec,
+ &mach_o_le_vec,
+ &mach_o_fat_vec,
&mcore_pe_big_vec,
&mcore_pe_little_vec,
&mcore_pei_big_vec,
@@ -958,13 +1012,15 @@ static const bfd_target * const _bfd_target_vector[] = {
&pc532machaout_vec,
&pc532netbsd_vec,
&pdp11_aout_vec,
+ &pef_vec,
+ &pef_xlib_vec,
#if 0
/* This has the same magic number as RS/6000. */
&pmac_xcoff_vec,
#endif
&ppcboot_vec,
#if 0
- /* We have no way of distinguishing these from other a.out variants */
+ /* We have no way of distinguishing these from other a.out variants. */
&riscix_vec,
#endif
#ifdef BFD64
@@ -987,6 +1043,7 @@ static const bfd_target * const _bfd_target_vector[] = {
&sparclynx_coff_vec,
&sparcnetbsd_vec,
&sunos_big_vec,
+ &sym_vec,
&tic30_aout_vec,
&tic30_coff_vec,
&tic54x_coff0_beh_vec,
@@ -1007,6 +1064,7 @@ static const bfd_target * const _bfd_target_vector[] = {
&w65_vec,
&we32kcoff_vec,
&z8kcoff_vec,
+ &bfd_elf32_am33lin_vec,
#endif /* not SELECT_VECS */
/* Always support S-records, for convenience. */
@@ -1070,6 +1128,17 @@ const bfd_target *bfd_default_vector[] = {
NULL
};
+/* bfd_associated_vector[] contains the associated target vectors used
+ to reduce the ambiguity in bfd_check_format_matches. */
+
+static const bfd_target *_bfd_associated_vector[] = {
+#ifdef ASSOCIATED_VECS
+ ASSOCIATED_VECS,
+#endif
+ NULL
+};
+const bfd_target * const *bfd_associated_vector = _bfd_associated_vector;
+
/* When there is an ambiguous match, bfd_check_format_matches puts the
names of the matching targets in an array. This variable is the maximum
number of entries that the array could possibly need. */
@@ -1093,13 +1162,10 @@ static const struct targmatch bfd_target_match[] = {
{ NULL, NULL }
};
-static const bfd_target *find_target PARAMS ((const char *));
-
/* Find a target vector, given a name or configuration triplet. */
static const bfd_target *
-find_target (name)
- const char *name;
+find_target (const char *name)
{
const bfd_target * const *target;
const struct targmatch *match;
@@ -1131,7 +1197,7 @@ FUNCTION
bfd_set_default_target
SYNOPSIS
- boolean bfd_set_default_target (const char *name);
+ bfd_boolean bfd_set_default_target (const char *name);
DESCRIPTION
Set the default target vector to use when recognizing a BFD.
@@ -1139,22 +1205,21 @@ DESCRIPTION
name or a configuration triplet.
*/
-boolean
-bfd_set_default_target (name)
- const char *name;
+bfd_boolean
+bfd_set_default_target (const char *name)
{
const bfd_target *target;
if (bfd_default_vector[0] != NULL
&& strcmp (name, bfd_default_vector[0]->name) == 0)
- return true;
+ return TRUE;
target = find_target (name);
if (target == NULL)
- return false;
+ return FALSE;
bfd_default_vector[0] = target;
- return true;
+ return TRUE;
}
/*
@@ -1162,7 +1227,7 @@ FUNCTION
bfd_find_target
SYNOPSIS
- const bfd_target *bfd_find_target(const char *target_name, bfd *abfd);
+ const bfd_target *bfd_find_target (const char *target_name, bfd *abfd);
DESCRIPTION
Return a pointer to the transfer vector for the object target
@@ -1177,9 +1242,7 @@ DESCRIPTION
*/
const bfd_target *
-bfd_find_target (target_name, abfd)
- const char *target_name;
- bfd *abfd;
+bfd_find_target (const char *target_name, bfd *abfd)
{
const char *targname;
const bfd_target *target;
@@ -1189,10 +1252,10 @@ bfd_find_target (target_name, abfd)
else
targname = getenv ("GNUTARGET");
- /* This is safe; the vector cannot be null */
+ /* This is safe; the vector cannot be null. */
if (targname == NULL || strcmp (targname, "default") == 0)
{
- abfd->target_defaulted = true;
+ abfd->target_defaulted = TRUE;
if (bfd_default_vector[0] != NULL)
abfd->xvec = bfd_default_vector[0];
else
@@ -1200,7 +1263,7 @@ bfd_find_target (target_name, abfd)
return abfd->xvec;
}
- abfd->target_defaulted = false;
+ abfd->target_defaulted = FALSE;
target = find_target (targname);
if (target == NULL)
@@ -1215,7 +1278,7 @@ FUNCTION
bfd_target_list
SYNOPSIS
- const char **bfd_target_list(void);
+ const char ** bfd_target_list (void);
DESCRIPTION
Return a freshly malloced NULL-terminated
@@ -1225,9 +1288,9 @@ DESCRIPTION
*/
const char **
-bfd_target_list ()
+bfd_target_list (void)
{
- int vec_length= 0;
+ int vec_length = 0;
bfd_size_type amt;
#if defined (HOST_HPPAHPUX) && ! defined (__STDC__)
/* The native compiler on the HP9000/700 has a bug which causes it
@@ -1241,7 +1304,7 @@ bfd_target_list ()
vec_length++;
amt = (vec_length + 1) * sizeof (char **);
- name_ptr = name_list = (const char **) bfd_zmalloc (amt);
+ name_ptr = name_list = bfd_malloc (amt);
if (name_list == NULL)
return NULL;
@@ -1251,6 +1314,7 @@ bfd_target_list ()
|| *target != bfd_target_vector[0])
*name_ptr++ = (*target)->name;
+ *name_ptr = NULL;
return name_list;
}
@@ -1259,7 +1323,9 @@ FUNCTION
bfd_seach_for_target
SYNOPSIS
- const bfd_target * bfd_search_for_target (int (* search_func) (const bfd_target *, void *), void *);
+ const bfd_target *bfd_search_for_target
+ (int (*search_func) (const bfd_target *, void *),
+ void *);
DESCRIPTION
Return a pointer to the first transfer vector in the list of
@@ -1270,15 +1336,14 @@ DESCRIPTION
*/
const bfd_target *
-bfd_search_for_target (search_func, data)
- int (* search_func) PARAMS ((const bfd_target * target, void * data));
- void * data;
+bfd_search_for_target (int (*search_func) (const bfd_target *, void *),
+ void *data)
{
- const bfd_target * const * target;
+ const bfd_target * const *target;
- for (target = bfd_target_vector; * target != NULL; target ++)
- if (search_func (* target, data))
- return * target;
+ for (target = bfd_target_vector; *target != NULL; target ++)
+ if (search_func (*target, data))
+ return *target;
return NULL;
}
diff --git a/contrib/binutils/bfd/tekhex.c b/contrib/binutils/bfd/tekhex.c
index 19dcb87..f828fe7 100644
--- a/contrib/binutils/bfd/tekhex.c
+++ b/contrib/binutils/bfd/tekhex.c
@@ -1,5 +1,5 @@
/* BFD backend for Extended Tektronix Hex Format objects.
- Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
+ Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Steve Chamberlain of Cygnus Support <sac@cygnus.com>.
@@ -29,7 +29,7 @@ DESCRIPTION
relocations. Their main application is communication with
devices like PROM programmers and ICE equipment.
- It seems that the sections are descibed as being really big,
+ It seems that the sections are described as being really big,
the example I have says that the text section is 0..ffffffff.
BFD would barf with this, many apps would try to alloc 4GB to
read in the file.
@@ -104,23 +104,23 @@ static void tekhex_print_symbol
PARAMS ((bfd *, PTR, asymbol *, bfd_print_symbol_type));
static void tekhex_get_symbol_info PARAMS ((bfd *, asymbol *, symbol_info *));
static asymbol *tekhex_make_empty_symbol PARAMS ((bfd *));
-static int tekhex_sizeof_headers PARAMS ((bfd *, boolean));
-static boolean tekhex_write_object_contents PARAMS ((bfd *));
+static int tekhex_sizeof_headers PARAMS ((bfd *, bfd_boolean));
+static bfd_boolean tekhex_write_object_contents PARAMS ((bfd *));
static void out PARAMS ((bfd *, int, char *, char *));
static void writesym PARAMS ((char **, const char *));
static void writevalue PARAMS ((char **, bfd_vma));
-static boolean tekhex_set_section_contents
- PARAMS ((bfd*, sec_ptr, PTR, file_ptr, bfd_size_type));
-static boolean tekhex_set_arch_mach
+static bfd_boolean tekhex_set_section_contents
+ PARAMS ((bfd*, sec_ptr, const PTR, file_ptr, bfd_size_type));
+static bfd_boolean tekhex_set_arch_mach
PARAMS ((bfd *, enum bfd_architecture, unsigned long));
-static boolean tekhex_get_section_contents
+static bfd_boolean tekhex_get_section_contents
PARAMS ((bfd *, asection *, PTR, file_ptr, bfd_size_type));
static void move_section_contents
- PARAMS ((bfd *, asection *, PTR, file_ptr, bfd_size_type, boolean));
+ PARAMS ((bfd *, asection *, const PTR, file_ptr, bfd_size_type, bfd_boolean));
static const bfd_target *tekhex_object_p PARAMS ((bfd *));
-static boolean tekhex_mkobject PARAMS ((bfd *));
+static bfd_boolean tekhex_mkobject PARAMS ((bfd *));
static long tekhex_get_symtab_upper_bound PARAMS ((bfd *));
-static long tekhex_get_symtab PARAMS ((bfd *, asymbol **));
+static long tekhex_canonicalize_symtab PARAMS ((bfd *, asymbol **));
static void pass_over PARAMS ((bfd *, void (*) (bfd*, int, char *)));
static void first_phase PARAMS ((bfd *, int, char *));
static void insert_byte PARAMS ((bfd *, int, bfd_vma));
@@ -239,12 +239,12 @@ static void
tekhex_init ()
{
unsigned int i;
- static boolean inited = false;
+ static bfd_boolean inited = FALSE;
int val;
if (! inited)
{
- inited = true;
+ inited = TRUE;
hex_init ();
val = 0;
for (i = 0; i < 10; i++)
@@ -471,7 +471,7 @@ first_phase (abfd, type, src)
}
}
-/* Pass over an tekhex, calling one of the above functions on each
+/* Pass over a tekhex, calling one of the above functions on each
record. */
static void
@@ -480,7 +480,7 @@ pass_over (abfd, func)
void (*func) PARAMS ((bfd *, int, char *));
{
unsigned int chars_on_line;
- boolean eof = false;
+ bfd_boolean eof = FALSE;
/* To the front of the file */
if (bfd_seek (abfd, (file_ptr) 0, SEEK_SET) != 0)
@@ -492,10 +492,10 @@ pass_over (abfd, func)
char type;
/* Find first '%' */
- eof = (boolean) (bfd_bread (src, (bfd_size_type) 1, abfd) != 1);
+ eof = (bfd_boolean) (bfd_bread (src, (bfd_size_type) 1, abfd) != 1);
while (*src != '%' && !eof)
{
- eof = (boolean) (bfd_bread (src, (bfd_size_type) 1, abfd) != 1);
+ eof = (bfd_boolean) (bfd_bread (src, (bfd_size_type) 1, abfd) != 1);
}
if (eof)
break;
@@ -522,7 +522,7 @@ pass_over (abfd, func)
}
static long
-tekhex_get_symtab (abfd, table)
+tekhex_canonicalize_symtab (abfd, table)
bfd *abfd;
asymbol **table;
{
@@ -547,7 +547,7 @@ tekhex_get_symtab_upper_bound (abfd)
}
-static boolean
+static bfd_boolean
tekhex_mkobject (abfd)
bfd *abfd;
{
@@ -555,17 +555,17 @@ tekhex_mkobject (abfd)
tdata = (tdata_type *) bfd_alloc (abfd, (bfd_size_type) sizeof (tdata_type));
if (!tdata)
- return false;
+ return FALSE;
abfd->tdata.tekhex_data = tdata;
tdata->type = 1;
tdata->head = (tekhex_data_list_type *) NULL;
tdata->symbols = (struct tekhex_symbol_struct *) NULL;
tdata->data = (struct data_struct *) NULL;
- return true;
+ return TRUE;
}
/*
- Return true if the file looks like it's in TekHex format. Just look
+ Return TRUE if the file looks like it's in TekHex format. Just look
for a percent sign and some hex digits */
static const bfd_target *
@@ -593,10 +593,10 @@ static void
move_section_contents (abfd, section, locationp, offset, count, get)
bfd *abfd;
asection *section;
- PTR locationp;
+ const PTR locationp;
file_ptr offset;
bfd_size_type count;
- boolean get;
+ bfd_boolean get;
{
bfd_vma addr;
char *location = (char *) locationp;
@@ -639,7 +639,7 @@ move_section_contents (abfd, section, locationp, offset, count, get)
}
-static boolean
+static bfd_boolean
tekhex_get_section_contents (abfd, section, locationp, offset, count)
bfd *abfd;
asection *section;
@@ -649,14 +649,14 @@ tekhex_get_section_contents (abfd, section, locationp, offset, count)
{
if (section->flags & (SEC_LOAD | SEC_ALLOC))
{
- move_section_contents (abfd, section, locationp, offset, count, true);
- return true;
+ move_section_contents (abfd, section, locationp, offset, count, TRUE);
+ return TRUE;
}
else
- return false;
+ return FALSE;
}
-static boolean
+static bfd_boolean
tekhex_set_arch_mach (abfd, arch, machine)
bfd *abfd;
enum bfd_architecture arch;
@@ -668,11 +668,11 @@ tekhex_set_arch_mach (abfd, arch, machine)
/* we have to save up all the Tekhexords for a splurge before output,
*/
-static boolean
+static bfd_boolean
tekhex_set_section_contents (abfd, section, locationp, offset, bytes_to_do)
bfd *abfd;
sec_ptr section;
- PTR locationp;
+ const PTR locationp;
file_ptr offset;
bfd_size_type bytes_to_do;
{
@@ -698,11 +698,11 @@ tekhex_set_section_contents (abfd, section, locationp, offset, bytes_to_do)
if (section->flags & (SEC_LOAD | SEC_ALLOC))
{
move_section_contents (abfd, section, locationp, offset, bytes_to_do,
- false);
- return true;
+ FALSE);
+ return TRUE;
}
else
- return false;
+ return FALSE;
}
@@ -804,7 +804,7 @@ out (abfd, type, start, end)
abort ();
}
-static boolean
+static bfd_boolean
tekhex_write_object_contents (abfd)
bfd *abfd;
{
@@ -907,7 +907,7 @@ tekhex_write_object_contents (abfd)
case 'C':
case 'U':
bfd_set_error (bfd_error_wrong_format);
- return false;
+ return FALSE;
}
writesym (&dst, sym->name);
@@ -920,13 +920,13 @@ tekhex_write_object_contents (abfd)
/* And the terminator */
if (bfd_bwrite ("%0781010\n", (bfd_size_type) 9, abfd) != 9)
abort ();
- return true;
+ return TRUE;
}
static int
tekhex_sizeof_headers (abfd, exec)
bfd *abfd ATTRIBUTE_UNUSED;
- boolean exec ATTRIBUTE_UNUSED;
+ bfd_boolean exec ATTRIBUTE_UNUSED;
{
return 0;
diff --git a/contrib/binutils/bfd/trad-core.c b/contrib/binutils/bfd/trad-core.c
index e27cd35..f8c03d7 100644
--- a/contrib/binutils/bfd/trad-core.c
+++ b/contrib/binutils/bfd/trad-core.c
@@ -1,6 +1,6 @@
/* BFD back end for traditional Unix core files (U-area and raw sections)
Copyright 1988, 1989, 1991, 1992, 1993, 1994, 1995, 1996, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
Written by John Gilmore of Cygnus Support.
@@ -47,13 +47,13 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include TRAD_HEADER
#endif
- struct trad_core_struct
- {
- asection *data_section;
- asection *stack_section;
- asection *reg_section;
- struct user u;
- };
+struct trad_core_struct
+{
+ asection *data_section;
+ asection *stack_section;
+ asection *reg_section;
+ struct user u;
+};
#define core_upage(bfd) (&((bfd)->tdata.trad_core_data->u))
#define core_datasec(bfd) ((bfd)->tdata.trad_core_data->data_section)
@@ -63,15 +63,14 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* forward declarations */
const bfd_target *trad_unix_core_file_p PARAMS ((bfd *abfd));
-char * trad_unix_core_file_failing_command PARAMS ((bfd *abfd));
-int trad_unix_core_file_failing_signal PARAMS ((bfd *abfd));
-boolean trad_unix_core_file_matches_executable_p
- PARAMS ((bfd *core_bfd, bfd *exec_bfd));
-static void swap_abort PARAMS ((void));
+char * trad_unix_core_file_failing_command PARAMS ((bfd *abfd));
+int trad_unix_core_file_failing_signal PARAMS ((bfd *abfd));
+bfd_boolean trad_unix_core_file_matches_executable_p
+ PARAMS ((bfd *core_bfd, bfd *exec_bfd));
+static void swap_abort PARAMS ((void));
/* Handle 4.2-style (and perhaps also sysV-style) core dump file. */
-/* ARGSUSED */
const bfd_target *
trad_unix_core_file_p (abfd)
bfd *abfd;
@@ -248,7 +247,6 @@ trad_unix_core_file_failing_command (abfd)
return 0;
}
-/* ARGSUSED */
int
trad_unix_core_file_failing_signal (ignore_abfd)
bfd *ignore_abfd ATTRIBUTE_UNUSED;
@@ -260,13 +258,12 @@ trad_unix_core_file_failing_signal (ignore_abfd)
#endif
}
-/* ARGSUSED */
-boolean
+bfd_boolean
trad_unix_core_file_matches_executable_p (core_bfd, exec_bfd)
bfd *core_bfd ATTRIBUTE_UNUSED;
bfd *exec_bfd ATTRIBUTE_UNUSED;
{
- return true; /* FIXME, We have no way of telling at this point */
+ return TRUE; /* FIXME, We have no way of telling at this point */
}
/* If somebody calls any byte-swapping routines, shoot them. */
@@ -275,10 +272,13 @@ swap_abort ()
{
abort (); /* This way doesn't require any declaration for ANSI to fuck up */
}
-#define NO_GET ((bfd_vma (*) PARAMS (( const bfd_byte *))) swap_abort )
-#define NO_PUT ((void (*) PARAMS ((bfd_vma, bfd_byte *))) swap_abort )
-#define NO_SIGNED_GET \
- ((bfd_signed_vma (*) PARAMS ((const bfd_byte *))) swap_abort )
+
+#define NO_GET ((bfd_vma (*) (const void *)) swap_abort)
+#define NO_PUT ((void (*) (bfd_vma, void *)) swap_abort)
+#define NO_GETS ((bfd_signed_vma (*) (const void *)) swap_abort)
+#define NO_GET64 ((bfd_uint64_t (*) (const void *)) swap_abort)
+#define NO_PUT64 ((void (*) (bfd_uint64_t, void *)) swap_abort)
+#define NO_GETS64 ((bfd_int64_t (*) (const void *)) swap_abort)
const bfd_target trad_core_vec =
{
@@ -293,39 +293,39 @@ const bfd_target trad_core_vec =
0, /* symbol prefix */
' ', /* ar_pad_char */
16, /* ar_max_namelen */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 64 bit data */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 32 bit data */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 16 bit data */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 64 bit hdrs */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 32 bit hdrs */
- NO_GET, NO_SIGNED_GET, NO_PUT, /* 16 bit hdrs */
+ NO_GET64, NO_GETS64, NO_PUT64, /* 64 bit data */
+ NO_GET, NO_GETS, NO_PUT, /* 32 bit data */
+ NO_GET, NO_GETS, NO_PUT, /* 16 bit data */
+ NO_GET64, NO_GETS64, NO_PUT64, /* 64 bit hdrs */
+ NO_GET, NO_GETS, NO_PUT, /* 32 bit hdrs */
+ NO_GET, NO_GETS, NO_PUT, /* 16 bit hdrs */
{ /* bfd_check_format */
- _bfd_dummy_target, /* unknown format */
- _bfd_dummy_target, /* object file */
- _bfd_dummy_target, /* archive */
- trad_unix_core_file_p /* a core file */
+ _bfd_dummy_target, /* unknown format */
+ _bfd_dummy_target, /* object file */
+ _bfd_dummy_target, /* archive */
+ trad_unix_core_file_p /* a core file */
},
{ /* bfd_set_format */
- bfd_false, bfd_false,
- bfd_false, bfd_false
+ bfd_false, bfd_false,
+ bfd_false, bfd_false
},
{ /* bfd_write_contents */
- bfd_false, bfd_false,
- bfd_false, bfd_false
+ bfd_false, bfd_false,
+ bfd_false, bfd_false
},
- BFD_JUMP_TABLE_GENERIC (_bfd_generic),
- BFD_JUMP_TABLE_COPY (_bfd_generic),
- BFD_JUMP_TABLE_CORE (trad_unix),
- BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive),
- BFD_JUMP_TABLE_SYMBOLS (_bfd_nosymbols),
- BFD_JUMP_TABLE_RELOCS (_bfd_norelocs),
- BFD_JUMP_TABLE_WRITE (_bfd_generic),
- BFD_JUMP_TABLE_LINK (_bfd_nolink),
- BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
+ BFD_JUMP_TABLE_GENERIC (_bfd_generic),
+ BFD_JUMP_TABLE_COPY (_bfd_generic),
+ BFD_JUMP_TABLE_CORE (trad_unix),
+ BFD_JUMP_TABLE_ARCHIVE (_bfd_noarchive),
+ BFD_JUMP_TABLE_SYMBOLS (_bfd_nosymbols),
+ BFD_JUMP_TABLE_RELOCS (_bfd_norelocs),
+ BFD_JUMP_TABLE_WRITE (_bfd_generic),
+ BFD_JUMP_TABLE_LINK (_bfd_nolink),
+ BFD_JUMP_TABLE_DYNAMIC (_bfd_nodynamic),
NULL,
(PTR) 0 /* backend_data */
-};
+ };
diff --git a/contrib/binutils/bfd/version.h b/contrib/binutils/bfd/version.h
index 6dac811..ab4618d 100644
--- a/contrib/binutils/bfd/version.h
+++ b/contrib/binutils/bfd/version.h
@@ -1 +1,3 @@
-#define BFD_VERSION_DATE 20021127
+#define BFD_VERSION_DATE 20040523
+#define BFD_VERSION @bfd_version@
+#define BFD_VERSION_STRING @bfd_version_string@
diff --git a/contrib/binutils/bfd/xcoff-target.h b/contrib/binutils/bfd/xcoff-target.h
index 413511b..7bf3de7 100644
--- a/contrib/binutils/bfd/xcoff-target.h
+++ b/contrib/binutils/bfd/xcoff-target.h
@@ -57,7 +57,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#undef CORE_FILE_P
#define CORE_FILE_P rs6000coff_core_p
extern const bfd_target * rs6000coff_core_p ();
-extern boolean rs6000coff_core_file_matches_executable_p ();
+extern bfd_boolean rs6000coff_core_file_matches_executable_p ();
#undef coff_core_file_matches_executable_p
#define coff_core_file_matches_executable_p \
@@ -78,8 +78,8 @@ extern int rs6000coff_core_file_failing_signal PARAMS ((bfd *abfd));
#define CORE_FILE_P lynx_core_file_p
extern const bfd_target *lynx_core_file_p PARAMS ((bfd *abfd));
-extern boolean lynx_core_file_matches_executable_p PARAMS ((bfd *core_bfd,
- bfd *exec_bfd));
+extern bfd_boolean lynx_core_file_matches_executable_p
+ PARAMS ((bfd *core_bfd, bfd *exec_bfd));
#undef coff_core_file_matches_executable_p
#define coff_core_file_matches_executable_p lynx_core_file_matches_executable_p
@@ -106,7 +106,7 @@ extern int lynx_core_file_failing_signal PARAMS ((bfd *abfd));
#define _bfd_xcoff_slurp_extended_name_table bfd_false
#define _bfd_xcoff_construct_extended_name_table \
- ((boolean (*) PARAMS ((bfd *, char **, bfd_size_type *, const char **))) \
+ ((bfd_boolean (*) PARAMS ((bfd *, char **, bfd_size_type *, const char **))) \
bfd_false)
#define _bfd_xcoff_truncate_arname bfd_dont_truncate_arname
@@ -118,22 +118,22 @@ extern int lynx_core_file_failing_signal PARAMS ((bfd *abfd));
#define _bfd_xcoff_update_armap_timestamp bfd_true
-extern boolean _bfd_xcoff_mkobject PARAMS ((bfd *));
-extern boolean _bfd_xcoff_copy_private_bfd_data PARAMS ((bfd *, bfd *));
-extern boolean _bfd_xcoff_is_local_label_name PARAMS ((bfd *, const char *));
+extern bfd_boolean _bfd_xcoff_mkobject PARAMS ((bfd *));
+extern bfd_boolean _bfd_xcoff_copy_private_bfd_data PARAMS ((bfd *, bfd *));
+extern bfd_boolean _bfd_xcoff_is_local_label_name PARAMS ((bfd *, const char *));
extern void _bfd_xcoff_rtype2howto
PARAMS ((arelent *, struct internal_reloc *));
extern reloc_howto_type *_bfd_xcoff_reloc_type_lookup
PARAMS ((bfd *, bfd_reloc_code_real_type));
-extern boolean _bfd_xcoff_slurp_armap PARAMS ((bfd *));
+extern bfd_boolean _bfd_xcoff_slurp_armap PARAMS ((bfd *));
extern const bfd_target *_bfd_xcoff_archive_p PARAMS ((bfd *));
extern PTR _bfd_xcoff_read_ar_hdr PARAMS ((bfd *));
extern bfd *_bfd_xcoff_openr_next_archived_file PARAMS ((bfd *, bfd *));
extern int _bfd_xcoff_generic_stat_arch_elt PARAMS ((bfd *, struct stat *));
-extern boolean _bfd_xcoff_write_armap
+extern bfd_boolean _bfd_xcoff_write_armap
PARAMS ((bfd *, unsigned int, struct orl *, unsigned int, int));
-extern boolean _bfd_xcoff_write_archive_contents PARAMS ((bfd *));
-extern int _bfd_xcoff_sizeof_headers PARAMS ((bfd *, boolean));
+extern bfd_boolean _bfd_xcoff_write_archive_contents PARAMS ((bfd *));
+extern int _bfd_xcoff_sizeof_headers PARAMS ((bfd *, bfd_boolean));
extern void _bfd_xcoff_swap_sym_in PARAMS ((bfd *, PTR, PTR));
extern unsigned int _bfd_xcoff_swap_sym_out PARAMS ((bfd *, PTR, PTR));
extern void _bfd_xcoff_swap_aux_in PARAMS ((bfd *, PTR, int, int, int, int, PTR));
diff --git a/contrib/binutils/bfd/xcofflink.c b/contrib/binutils/bfd/xcofflink.c
index e4e4755..ccd82be 100644
--- a/contrib/binutils/bfd/xcofflink.c
+++ b/contrib/binutils/bfd/xcofflink.c
@@ -1,5 +1,5 @@
/* POWER/PowerPC XCOFF linker support.
- Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
+ Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Ian Lance Taylor <ian@cygnus.com>, Cygnus Support.
@@ -115,34 +115,35 @@ struct xcoff_final_link_info
static struct bfd_hash_entry *xcoff_link_hash_newfunc
PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-static boolean xcoff_get_section_contents PARAMS ((bfd *, asection *));
+static bfd_boolean xcoff_get_section_contents PARAMS ((bfd *, asection *));
static struct internal_reloc *xcoff_read_internal_relocs
- PARAMS ((bfd *, asection *, boolean, bfd_byte *, boolean,
+ PARAMS ((bfd *, asection *, bfd_boolean, bfd_byte *, bfd_boolean,
struct internal_reloc *));
-static boolean xcoff_link_add_object_symbols
+static bfd_boolean xcoff_link_add_object_symbols
PARAMS ((bfd *, struct bfd_link_info *));
-static boolean xcoff_link_check_archive_element
- PARAMS ((bfd *, struct bfd_link_info *, boolean *));
-static boolean xcoff_link_check_ar_symbols
- PARAMS ((bfd *, struct bfd_link_info *, boolean *));
-static boolean xcoff_link_check_dynamic_ar_symbols
- PARAMS ((bfd *, struct bfd_link_info *, boolean *));
+static bfd_boolean xcoff_link_check_archive_element
+ PARAMS ((bfd *, struct bfd_link_info *, bfd_boolean *));
+static bfd_boolean xcoff_link_check_ar_symbols
+ PARAMS ((bfd *, struct bfd_link_info *, bfd_boolean *));
+static bfd_boolean xcoff_link_check_dynamic_ar_symbols
+ PARAMS ((bfd *, struct bfd_link_info *, bfd_boolean *));
static bfd_size_type xcoff_find_reloc
PARAMS ((struct internal_reloc *, bfd_size_type, bfd_vma));
-static boolean xcoff_link_add_symbols PARAMS ((bfd *, struct bfd_link_info *));
-static boolean xcoff_link_add_dynamic_symbols
+static bfd_boolean xcoff_link_add_symbols
PARAMS ((bfd *, struct bfd_link_info *));
-static boolean xcoff_mark_symbol
+static bfd_boolean xcoff_link_add_dynamic_symbols
+ PARAMS ((bfd *, struct bfd_link_info *));
+static bfd_boolean xcoff_mark_symbol
PARAMS ((struct bfd_link_info *, struct xcoff_link_hash_entry *));
-static boolean xcoff_mark PARAMS ((struct bfd_link_info *, asection *));
+static bfd_boolean xcoff_mark PARAMS ((struct bfd_link_info *, asection *));
static void xcoff_sweep PARAMS ((struct bfd_link_info *));
-static boolean xcoff_build_ldsyms
+static bfd_boolean xcoff_build_ldsyms
PARAMS ((struct xcoff_link_hash_entry *, PTR));
-static boolean xcoff_link_input_bfd
+static bfd_boolean xcoff_link_input_bfd
PARAMS ((struct xcoff_final_link_info *, bfd *));
-static boolean xcoff_write_global_symbol
+static bfd_boolean xcoff_write_global_symbol
PARAMS ((struct xcoff_link_hash_entry *, PTR));
-static boolean xcoff_reloc_link_order
+static bfd_boolean xcoff_reloc_link_order
PARAMS ((bfd *, struct xcoff_final_link_info *, asection *,
struct bfd_link_order *));
static int xcoff_sort_relocs PARAMS ((const PTR, const PTR));
@@ -154,7 +155,7 @@ static int xcoff_sort_relocs PARAMS ((const PTR, const PTR));
/* Read the contents of a section. */
-static boolean
+static bfd_boolean
xcoff_get_section_contents (abfd, sec)
bfd *abfd;
asection *sec;
@@ -165,7 +166,7 @@ xcoff_get_section_contents (abfd, sec)
bfd_size_type amt = sizeof (struct coff_section_tdata);
sec->used_by_bfd = bfd_zalloc (abfd, amt);
if (sec->used_by_bfd == NULL)
- return false;
+ return FALSE;
}
if (coff_section_data (abfd, sec)->contents == NULL)
@@ -173,15 +174,15 @@ xcoff_get_section_contents (abfd, sec)
coff_section_data (abfd, sec)->contents = ((bfd_byte *)
bfd_malloc (sec->_raw_size));
if (coff_section_data (abfd, sec)->contents == NULL)
- return false;
+ return FALSE;
if (! bfd_get_section_contents (abfd, sec,
coff_section_data (abfd, sec)->contents,
(file_ptr) 0, sec->_raw_size))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Get the size required to hold the dynamic symbols. */
@@ -247,7 +248,7 @@ _bfd_xcoff_canonicalize_dynamic_symtab (abfd, psyms)
return -1;
contents = coff_section_data (abfd, lsec)->contents;
- coff_section_data (abfd, lsec)->keep_contents = true;
+ coff_section_data (abfd, lsec)->keep_contents = TRUE;
bfd_xcoff_swap_ldhdr_in (abfd, contents, &ldhdr);
@@ -295,7 +296,7 @@ _bfd_xcoff_canonicalize_dynamic_symtab (abfd, psyms)
symbuf->symbol.flags |= BSF_GLOBAL;
/* FIXME: We have no way to record the other information stored
- with the loader symbol. */
+ with the loader symbol. */
*psyms = (asymbol *) symbuf;
}
@@ -421,8 +422,8 @@ _bfd_xcoff_canonicalize_dynamic_reloc (abfd, prelocs, syms)
relbuf->addend = 0;
/* Most dynamic relocs have the same type. FIXME: This is only
- correct if ldrel.l_rtype == 0. In other cases, we should use
- a different howto. */
+ correct if ldrel.l_rtype == 0. In other cases, we should use
+ a different howto. */
relbuf->howto = bfd_xcoff_dynamic_reloc_howto(abfd);
/* FIXME: We have no way to record the l_rsecnm field. */
@@ -501,14 +502,14 @@ _bfd_xcoff_bfd_link_hash_table_create (abfd)
ret->descriptor_section = NULL;
ret->imports = NULL;
ret->file_align = 0;
- ret->textro = false;
- ret->gc = false;
+ ret->textro = FALSE;
+ ret->gc = FALSE;
memset (ret->special_sections, 0, sizeof ret->special_sections);
/* The linker will always generate a full a.out header. We need to
record that fact now, before the sizeof_headers routine could be
called. */
- xcoff_data (abfd)->full_aouthdr = true;
+ xcoff_data (abfd)->full_aouthdr = TRUE;
return &ret->root;
}
@@ -535,9 +536,9 @@ xcoff_read_internal_relocs (abfd, sec, cache, external_relocs,
require_internal, internal_relocs)
bfd *abfd;
asection *sec;
- boolean cache;
+ bfd_boolean cache;
bfd_byte *external_relocs;
- boolean require_internal;
+ bfd_boolean require_internal;
struct internal_reloc *internal_relocs;
{
@@ -555,8 +556,8 @@ xcoff_read_internal_relocs (abfd, sec, cache, external_relocs,
&& cache
&& enclosing->reloc_count > 0)
{
- if (_bfd_coff_read_internal_relocs (abfd, enclosing, true,
- external_relocs, false,
+ if (_bfd_coff_read_internal_relocs (abfd, enclosing, TRUE,
+ external_relocs, FALSE,
(struct internal_reloc *) NULL)
== NULL)
return NULL;
@@ -587,7 +588,7 @@ xcoff_read_internal_relocs (abfd, sec, cache, external_relocs,
/* Given an XCOFF BFD, add symbols to the global hash table as
appropriate. */
-boolean
+bfd_boolean
_bfd_xcoff_bfd_link_add_symbols (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -600,21 +601,21 @@ _bfd_xcoff_bfd_link_add_symbols (abfd, info)
case bfd_archive:
/* If the archive has a map, do the usual search. We then need
- to check the archive for dynamic objects, because they may not
- appear in the archive map even though they should, perhaps, be
- included. If the archive has no map, we just consider each object
- file in turn, since that apparently is what the AIX native linker
+ to check the archive for dynamic objects, because they may not
+ appear in the archive map even though they should, perhaps, be
+ included. If the archive has no map, we just consider each object
+ file in turn, since that apparently is what the AIX native linker
does. */
if (bfd_has_map (abfd))
{
if (! (_bfd_generic_link_add_archive_symbols
(abfd, info, xcoff_link_check_archive_element)))
- return false;
+ return FALSE;
}
{
bfd *member;
-
+
member = bfd_openr_next_archived_file (abfd, (bfd *) NULL);
while (member != NULL)
{
@@ -622,11 +623,11 @@ _bfd_xcoff_bfd_link_add_symbols (abfd, info)
&& (info->hash->creator == member->xvec)
&& (! bfd_has_map (abfd) || (member->flags & DYNAMIC) != 0))
{
- boolean needed;
-
- if (! xcoff_link_check_archive_element (member, info,
+ bfd_boolean needed;
+
+ if (! xcoff_link_check_archive_element (member, info,
&needed))
- return false;
+ return FALSE;
if (needed)
member->archive_pass = -1;
}
@@ -634,32 +635,32 @@ _bfd_xcoff_bfd_link_add_symbols (abfd, info)
}
}
- return true;
+ return TRUE;
default:
bfd_set_error (bfd_error_wrong_format);
- return false;
+ return FALSE;
}
}
/* Add symbols from an XCOFF object file. */
-static boolean
+static bfd_boolean
xcoff_link_add_object_symbols (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
{
if (! _bfd_coff_get_external_symbols (abfd))
- return false;
+ return FALSE;
if (! xcoff_link_add_symbols (abfd, info))
- return false;
+ return FALSE;
if (! info->keep_memory)
{
if (! _bfd_coff_free_symbols (abfd))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Check a single archive element to see if we need to include it in
@@ -667,48 +668,48 @@ xcoff_link_add_object_symbols (abfd, info)
needed in the link or not. This is called via
_bfd_generic_link_add_archive_symbols. */
-static boolean
+static bfd_boolean
xcoff_link_check_archive_element (abfd, info, pneeded)
bfd *abfd;
struct bfd_link_info *info;
- boolean *pneeded;
+ bfd_boolean *pneeded;
{
if (! _bfd_coff_get_external_symbols (abfd))
- return false;
+ return FALSE;
if (! xcoff_link_check_ar_symbols (abfd, info, pneeded))
- return false;
+ return FALSE;
if (*pneeded)
{
if (! xcoff_link_add_symbols (abfd, info))
- return false;
+ return FALSE;
}
if (! info->keep_memory || ! *pneeded)
{
if (! _bfd_coff_free_symbols (abfd))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Look through the symbols to see if this object file should be
included in the link. */
-static boolean
+static bfd_boolean
xcoff_link_check_ar_symbols (abfd, info, pneeded)
bfd *abfd;
struct bfd_link_info *info;
- boolean *pneeded;
+ bfd_boolean *pneeded;
{
bfd_size_type symesz;
bfd_byte *esym;
bfd_byte *esym_end;
- *pneeded = false;
+ *pneeded = FALSE;
if ((abfd->flags & DYNAMIC) != 0
&& ! info->static_link
@@ -731,13 +732,13 @@ xcoff_link_check_ar_symbols (abfd, info, pneeded)
struct bfd_link_hash_entry *h;
/* This symbol is externally visible, and is defined by this
- object file. */
+ object file. */
name = _bfd_coff_internal_syment_name (abfd, &sym, buf);
if (name == NULL)
- return false;
- h = bfd_link_hash_lookup (info->hash, name, false, false, true);
+ return FALSE;
+ h = bfd_link_hash_lookup (info->hash, name, FALSE, FALSE, TRUE);
/* We are only interested in symbols that are currently
undefined. If a symbol is currently known to be common,
@@ -751,9 +752,9 @@ xcoff_link_check_ar_symbols (abfd, info, pneeded)
& XCOFF_DEF_DYNAMIC) == 0))
{
if (! (*info->callbacks->add_archive_element) (info, abfd, name))
- return false;
- *pneeded = true;
- return true;
+ return FALSE;
+ *pneeded = TRUE;
+ return TRUE;
}
}
@@ -761,18 +762,18 @@ xcoff_link_check_ar_symbols (abfd, info, pneeded)
}
/* We do not need this object file. */
- return true;
+ return TRUE;
}
/* Look through the loader symbols to see if this dynamic object
should be included in the link. The native linker uses the loader
symbols, not the normal symbol table, so we do too. */
-static boolean
+static bfd_boolean
xcoff_link_check_dynamic_ar_symbols (abfd, info, pneeded)
bfd *abfd;
struct bfd_link_info *info;
- boolean *pneeded;
+ bfd_boolean *pneeded;
{
asection *lsec;
bfd_byte *contents;
@@ -780,17 +781,17 @@ xcoff_link_check_dynamic_ar_symbols (abfd, info, pneeded)
const char *strings;
bfd_byte *elsym, *elsymend;
- *pneeded = false;
+ *pneeded = FALSE;
lsec = bfd_get_section_by_name (abfd, ".loader");
if (lsec == NULL)
{
/* There are no symbols, so don't try to include it. */
- return true;
+ return TRUE;
}
if (! xcoff_get_section_contents (abfd, lsec))
- return false;
+ return FALSE;
contents = coff_section_data (abfd, lsec)->contents;
bfd_xcoff_swap_ldhdr_in (abfd, contents, &ldhdr);
@@ -822,20 +823,20 @@ xcoff_link_check_dynamic_ar_symbols (abfd, info, pneeded)
name = nambuf;
}
- h = bfd_link_hash_lookup (info->hash, name, false, false, true);
+ h = bfd_link_hash_lookup (info->hash, name, FALSE, FALSE, TRUE);
/* We are only interested in symbols that are currently
- undefined. At this point we know that we are using an XCOFF
- hash table. */
+ undefined. At this point we know that we are using an XCOFF
+ hash table. */
if (h != NULL
&& h->type == bfd_link_hash_undefined
&& (((struct xcoff_link_hash_entry *) h)->flags
& XCOFF_DEF_DYNAMIC) == 0)
{
if (! (*info->callbacks->add_archive_element) (info, abfd, name))
- return false;
- *pneeded = true;
- return true;
+ return FALSE;
+ *pneeded = TRUE;
+ return TRUE;
}
}
@@ -847,7 +848,7 @@ xcoff_link_check_dynamic_ar_symbols (abfd, info, pneeded)
coff_section_data (abfd, lsec)->contents = NULL;
}
- return true;
+ return TRUE;
}
/* Returns the index of reloc in RELOCS with the least address greater
@@ -905,11 +906,11 @@ xcoff_find_reloc (relocs, count, address)
Takes care of creating the .loader, .gl, .ds, .debug and sections. */
-static boolean
+static bfd_boolean
xcoff_link_create_extra_sections(bfd * abfd, struct bfd_link_info *info)
{
- boolean return_value = false;
+ bfd_boolean return_value = FALSE;
if (info->hash->creator == abfd->xvec)
{
@@ -998,7 +999,7 @@ xcoff_link_create_extra_sections(bfd * abfd, struct bfd_link_info *info)
}
}
- return_value = true;
+ return_value = TRUE;
end_return:
@@ -1023,21 +1024,21 @@ xcoff_link_create_extra_sections(bfd * abfd, struct bfd_link_info *info)
relocation entries carefully, since the only way to tell which
csect they belong to is to examine the address. */
-static boolean
+static bfd_boolean
xcoff_link_add_symbols (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
{
unsigned int n_tmask;
unsigned int n_btshft;
- boolean default_copy;
+ bfd_boolean default_copy;
bfd_size_type symcount;
struct xcoff_link_hash_entry **sym_hash;
asection **csect_cache;
bfd_size_type linesz;
asection *o;
asection *last_real;
- boolean keep_syms;
+ bfd_boolean keep_syms;
asection *csect;
unsigned int csect_index;
asection *first_csect;
@@ -1058,16 +1059,16 @@ xcoff_link_add_symbols (abfd, info)
&& ! info->static_link)
{
if (! xcoff_link_add_dynamic_symbols (abfd, info))
- return false;
+ return FALSE;
}
/* create the loader, toc, gl, ds and debug sections, if needed */
- if (false == xcoff_link_create_extra_sections(abfd, info))
+ if (! xcoff_link_create_extra_sections (abfd, info))
goto error_return;
if ((abfd->flags & DYNAMIC) != 0
&& ! info->static_link)
- return true;
+ return TRUE;
n_tmask = coff_data (abfd)->local_n_tmask;
n_btshft = coff_data (abfd)->local_n_btshft;
@@ -1077,9 +1078,9 @@ xcoff_link_add_symbols (abfd, info)
#define N_BTSHFT n_btshft
if (info->keep_memory)
- default_copy = false;
+ default_copy = FALSE;
else
- default_copy = true;
+ default_copy = TRUE;
symcount = obj_raw_syment_count (abfd);
@@ -1122,8 +1123,8 @@ xcoff_link_add_symbols (abfd, info)
{
reloc_info[o->target_index].relocs =
- xcoff_read_internal_relocs (abfd, o, true, (bfd_byte *) NULL,
- false, (struct internal_reloc *) NULL);
+ xcoff_read_internal_relocs (abfd, o, TRUE, (bfd_byte *) NULL,
+ FALSE, (struct internal_reloc *) NULL);
amt = o->reloc_count;
amt *= sizeof (asection *);
reloc_info[o->target_index].csects = (asection **) bfd_zmalloc (amt);
@@ -1150,7 +1151,7 @@ xcoff_link_add_symbols (abfd, info)
}
/* Don't let the linker relocation routines discard the symbols. */
- obj_coff_keep_syms (abfd) = true;
+ obj_coff_keep_syms (abfd) = TRUE;
csect = NULL;
csect_index = 0;
@@ -1214,11 +1215,11 @@ xcoff_link_add_symbols (abfd, info)
goto error_return;
/* If this symbol has line number information attached to it,
- and we're not stripping it, count the number of entries and
- add them to the count for this csect. In the final link pass
- we are going to attach line number information by symbol,
- rather than by section, in order to more easily handle
- garbage collection. */
+ and we're not stripping it, count the number of entries and
+ add them to the count for this csect. In the final link pass
+ we are going to attach line number information by symbol,
+ rather than by section, in order to more easily handle
+ garbage collection. */
if ((info->strip == strip_none || info->strip == strip_some)
&& sym.n_numaux > 1
&& csect != NULL
@@ -1247,7 +1248,7 @@ xcoff_link_add_symbols (abfd, info)
}
linoff = (auxlin.x_sym.x_fcnary.x_fcn.x_lnnoptr
- enclosing->line_filepos);
- /* explict cast to bfd_signed_vma for compiler */
+ /* explicit cast to bfd_signed_vma for compiler */
if (linoff < (bfd_signed_vma) (enclosing->lineno_count * linesz))
{
struct internal_lineno lin;
@@ -1336,7 +1337,7 @@ xcoff_link_add_symbols (abfd, info)
}
/* An XMC_XO external reference is actually a reference to
- an absolute location. */
+ an absolute location. */
if (aux.x_csect.x_smclas != XMC_XO)
section = bfd_und_section_ptr;
else
@@ -1430,7 +1431,7 @@ xcoff_link_add_symbols (abfd, info)
{
const char *relname;
char relbuf[SYMNMLEN + 1];
- boolean copy;
+ bfd_boolean copy;
struct xcoff_link_hash_entry *h;
/* At this point we know that the TOC entry is
@@ -1453,8 +1454,8 @@ xcoff_link_add_symbols (abfd, info)
|| relsym._n._n_n._n_zeroes != 0
|| relsym._n._n_n._n_offset == 0);
h = xcoff_link_hash_lookup (xcoff_hash_table (info),
- relname, true, copy,
- false);
+ relname, TRUE, copy,
+ FALSE);
if (h == NULL)
goto error_return;
@@ -1606,19 +1607,19 @@ xcoff_link_add_symbols (abfd, info)
follow its appropriate XTY_SD symbol. The .set pseudo op can
cause the XTY_LD to not follow the XTY_SD symbol. */
{
- boolean bad;
+ bfd_boolean bad;
- bad = false;
+ bad = FALSE;
if (aux.x_csect.x_scnlen.l < 0
|| (aux.x_csect.x_scnlen.l
>= esym - (bfd_byte *) obj_coff_external_syms (abfd)))
- bad = true;
+ bad = TRUE;
if (! bad)
{
section = xcoff_data (abfd)->csects[aux.x_csect.x_scnlen.l];
if (section == NULL
|| (section->flags & SEC_HAS_CONTENTS) == 0)
- bad = true;
+ bad = TRUE;
}
if (bad)
{
@@ -1635,11 +1636,11 @@ xcoff_link_add_symbols (abfd, info)
case XTY_CM:
/* This is an unitialized csect. We could base the name on
- the storage mapping class, but we don't bother except for
- an XMC_TD symbol. If this csect is externally visible,
- it is a common symbol. We put XMC_TD symbols in sections
- named .tocbss, and rely on the linker script to put that
- in the TOC area. */
+ the storage mapping class, but we don't bother except for
+ an XMC_TD symbol. If this csect is externally visible,
+ it is a common symbol. We put XMC_TD symbols in sections
+ named .tocbss, and rely on the linker script to put that
+ in the TOC area. */
if (csect != NULL)
{
@@ -1730,20 +1731,20 @@ xcoff_link_add_symbols (abfd, info)
}
/* Now we have enough information to add the symbol to the
- linker hash table. */
+ linker hash table. */
if (sym.n_sclass == C_EXT)
{
- boolean copy;
+ bfd_boolean copy;
BFD_ASSERT (section != NULL);
/* We must copy the name into memory if we got it from the
- syment itself, rather than the string table. */
+ syment itself, rather than the string table. */
copy = default_copy;
if (sym._n._n_n._n_zeroes != 0
|| sym._n._n_n._n_offset == 0)
- copy = true;
+ copy = TRUE;
/* The AIX linker appears to only detect multiple symbol
definitions when there is a reference to the symbol. If
@@ -1775,7 +1776,7 @@ xcoff_link_add_symbols (abfd, info)
if (! bfd_is_und_section (section))
{
*sym_hash = xcoff_link_hash_lookup (xcoff_hash_table (info),
- name, true, copy, false);
+ name, TRUE, copy, FALSE);
}
else
{
@@ -1783,8 +1784,8 @@ xcoff_link_add_symbols (abfd, info)
merging symbols. */
*sym_hash = ((struct xcoff_link_hash_entry *)
bfd_wrapped_link_hash_lookup (abfd, info, name,
- true, true,
- false));
+ TRUE, TRUE,
+ FALSE));
}
if (*sym_hash == NULL)
goto error_return;
@@ -1801,11 +1802,11 @@ xcoff_link_add_symbols (abfd, info)
& DYNAMIC) == 0))
{
/* The new symbol is from a shared library, and
- either the existing symbol is not global
- linkage code or this symbol is global linkage
- code. If the existing symbol is global
- linkage code and the new symbol is not, then
- we want to use the new symbol. */
+ either the existing symbol is not global
+ linkage code or this symbol is global linkage
+ code. If the existing symbol is global
+ linkage code and the new symbol is not, then
+ we want to use the new symbol. */
section = bfd_und_section_ptr;
value = 0;
}
@@ -1813,7 +1814,7 @@ xcoff_link_add_symbols (abfd, info)
& DYNAMIC) != 0)
{
/* The existing symbol is from a shared library.
- Replace it. */
+ Replace it. */
(*sym_hash)->root.type = bfd_link_hash_undefined;
(*sym_hash)->root.u.undef.abfd =
(*sym_hash)->root.u.def.section->owner;
@@ -1821,24 +1822,24 @@ xcoff_link_add_symbols (abfd, info)
else if (abfd->my_archive != NULL)
{
/* This is a redefinition in an object contained
- in an archive. Just ignore it. See the
- comment above. */
+ in an archive. Just ignore it. See the
+ comment above. */
section = bfd_und_section_ptr;
value = 0;
}
- else if ((*sym_hash)->root.next != NULL
+ else if ((*sym_hash)->root.und_next != NULL
|| info->hash->undefs_tail == &(*sym_hash)->root)
{
/* This symbol has been referenced. In this
- case, we just continue and permit the
- multiple definition error. See the comment
- above about the behaviour of the AIX linker. */
+ case, we just continue and permit the
+ multiple definition error. See the comment
+ above about the behaviour of the AIX linker. */
}
else if ((*sym_hash)->smclas == aux.x_csect.x_smclas)
{
/* The symbols are both csects of the same
- class. There is at least a chance that this
- is a semi-legitimate redefinition. */
+ class. There is at least a chance that this
+ is a semi-legitimate redefinition. */
section = bfd_und_section_ptr;
value = 0;
(*sym_hash)->flags |= XCOFF_MULTIPLY_DEFINED;
@@ -1883,7 +1884,7 @@ xcoff_link_add_symbols (abfd, info)
last_real->next = NULL;
if (! (_bfd_generic_link_add_one_symbol
(info, abfd, name, flags, section, value,
- (const char *) NULL, copy, true,
+ (const char *) NULL, copy, TRUE,
(struct bfd_link_hash_entry **) sym_hash)))
goto error_return;
last_real->next = first_csect;
@@ -1974,14 +1975,14 @@ xcoff_link_add_symbols (abfd, info)
h = obj_xcoff_sym_hashes (abfd)[rel->r_symndx];
h->flags |= XCOFF_CALLED;
/* If the symbol name starts with a period, it is
- the code of a function. If the symbol is
- currently undefined, then add an undefined symbol
- for the function descriptor. This should do no
- harm, because any regular object that defines the
- function should also define the function
- descriptor. It helps, because it means that we
- will identify the function descriptor with a
- dynamic object if a dynamic object defines it. */
+ the code of a function. If the symbol is
+ currently undefined, then add an undefined symbol
+ for the function descriptor. This should do no
+ harm, because any regular object that defines the
+ function should also define the function
+ descriptor. It helps, because it means that we
+ will identify the function descriptor with a
+ dynamic object if a dynamic object defines it. */
if (h->root.root.string[0] == '.'
&& h->descriptor == NULL)
{
@@ -1990,7 +1991,7 @@ xcoff_link_add_symbols (abfd, info)
hds = xcoff_link_hash_lookup (xcoff_hash_table (info),
h->root.root.string + 1,
- true, false, true);
+ TRUE, FALSE, TRUE);
if (hds == NULL)
goto error_return;
if (hds->root.type == bfd_link_hash_new)
@@ -1999,8 +2000,8 @@ xcoff_link_add_symbols (abfd, info)
if (! (_bfd_generic_link_add_one_symbol
(info, abfd, hds->root.root.string,
(flagword) 0, bfd_und_section_ptr,
- (bfd_vma) 0, (const char *) NULL, false,
- true, &bh)))
+ (bfd_vma) 0, (const char *) NULL, FALSE,
+ TRUE, &bh)))
goto error_return;
hds = (struct xcoff_link_hash_entry *) bh;
}
@@ -2033,7 +2034,7 @@ xcoff_link_add_symbols (abfd, info)
}
/* Free up the line numbers. FIXME: We could cache these
- somewhere for the final link, to avoid reading them again. */
+ somewhere for the final link, to avoid reading them again. */
if (reloc_info[o->target_index].linenos != NULL)
{
free (reloc_info[o->target_index].linenos);
@@ -2045,7 +2046,7 @@ xcoff_link_add_symbols (abfd, info)
obj_coff_keep_syms (abfd) = keep_syms;
- return true;
+ return TRUE;
error_return:
if (reloc_info != NULL)
@@ -2060,7 +2061,7 @@ xcoff_link_add_symbols (abfd, info)
free (reloc_info);
}
obj_coff_keep_syms (abfd) = keep_syms;
- return false;
+ return FALSE;
}
#undef N_TMASK
@@ -2069,7 +2070,7 @@ xcoff_link_add_symbols (abfd, info)
/* This function is used to add symbols from a dynamic object to the
global symbol table. */
-static boolean
+static bfd_boolean
xcoff_link_add_dynamic_symbols (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -2094,7 +2095,7 @@ xcoff_link_add_dynamic_symbols (abfd, info)
(_("%s: XCOFF shared object when not producing XCOFF output"),
bfd_get_filename (abfd));
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
/* The symbols we use from a dynamic object are not the symbols in
@@ -2115,12 +2116,12 @@ xcoff_link_add_dynamic_symbols (abfd, info)
(_("%s: dynamic object with no .loader section"),
bfd_get_filename (abfd));
bfd_set_error (bfd_error_no_symbols);
- return false;
+ return FALSE;
}
if (! xcoff_get_section_contents (abfd, lsec))
- return false;
+ return FALSE;
contents = coff_section_data (abfd, lsec)->contents;
/* Remove the sections from this object, so that they do not get
@@ -2162,10 +2163,10 @@ xcoff_link_add_dynamic_symbols (abfd, info)
table. However, we verified above that we are using an XCOFF
hash table. */
- h = xcoff_link_hash_lookup (xcoff_hash_table (info), name, true,
- true, true);
+ h = xcoff_link_hash_lookup (xcoff_hash_table (info), name, TRUE,
+ TRUE, TRUE);
if (h == NULL)
- return false;
+ return FALSE;
h->flags |= XCOFF_DEF_DYNAMIC;
@@ -2191,9 +2192,9 @@ xcoff_link_add_dynamic_symbols (abfd, info)
h->smclas = ldsym.l_smclas;
/* Unless this is an XMC_XO symbol, we don't bother to actually
- define it, since we don't have a section to put it in anyhow.
- Instead, the relocation routines handle the DEF_DYNAMIC flag
- correctly. */
+ define it, since we don't have a section to put it in anyhow.
+ Instead, the relocation routines handle the DEF_DYNAMIC flag
+ correctly. */
if (h->smclas == XMC_XO
&& (h->root.type == bfd_link_hash_undefined
@@ -2221,21 +2222,21 @@ xcoff_link_add_dynamic_symbols (abfd, info)
dsnm = bfd_malloc ((bfd_size_type) strlen (name) + 2);
if (dsnm == NULL)
- return false;
+ return FALSE;
dsnm[0] = '.';
strcpy (dsnm + 1, name);
hds = xcoff_link_hash_lookup (xcoff_hash_table (info), dsnm,
- true, true, true);
+ TRUE, TRUE, TRUE);
free (dsnm);
if (hds == NULL)
- return false;
+ return FALSE;
if (hds->root.type == bfd_link_hash_new)
{
hds->root.type = bfd_link_hash_undefined;
hds->root.u.undef.abfd = abfd;
/* We do not want to add this to the undefined
- symbol list. */
+ symbol list. */
}
hds->descriptor = h;
@@ -2272,7 +2273,7 @@ xcoff_link_add_dynamic_symbols (abfd, info)
n = ((struct xcoff_import_file *)
bfd_alloc (abfd, (bfd_size_type) sizeof (struct xcoff_import_file)));
if (n == NULL)
- return false;
+ return FALSE;
n->next = NULL;
/* For some reason, the path entry in the import file list for a
@@ -2305,7 +2306,7 @@ xcoff_link_add_dynamic_symbols (abfd, info)
xcoff_data (abfd)->import_file_id = c;
- return true;
+ return TRUE;
}
/* Routines that are called after all the input files have been
@@ -2314,14 +2315,14 @@ xcoff_link_add_dynamic_symbols (abfd, info)
/* Mark a symbol as not being garbage, including the section in which
it is defined. */
-static INLINE boolean
+static INLINE bfd_boolean
xcoff_mark_symbol (info, h)
struct bfd_link_info *info;
struct xcoff_link_hash_entry *h;
{
if ((h->flags & XCOFF_MARK) != 0)
- return true;
+ return TRUE;
h->flags |= XCOFF_MARK;
if (h->root.type == bfd_link_hash_defined
@@ -2334,7 +2335,7 @@ xcoff_mark_symbol (info, h)
&& (hsec->flags & SEC_MARK) == 0)
{
if (! xcoff_mark (info, hsec))
- return false;
+ return FALSE;
}
}
@@ -2342,10 +2343,10 @@ xcoff_mark_symbol (info, h)
&& (h->toc_section->flags & SEC_MARK) == 0)
{
if (! xcoff_mark (info, h->toc_section))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* The mark phase of garbage collection. For a given section, mark
@@ -2354,14 +2355,14 @@ xcoff_mark_symbol (info, h)
the number of relocs which need to be copied into the .loader
section. */
-static boolean
+static bfd_boolean
xcoff_mark (info, sec)
struct bfd_link_info *info;
asection *sec;
{
if (bfd_is_abs_section (sec)
|| (sec->flags & SEC_MARK) != 0)
- return true;
+ return TRUE;
sec->flags |= SEC_MARK;
@@ -2387,7 +2388,7 @@ xcoff_mark (info, sec)
&& (h->flags & XCOFF_MARK) == 0)
{
if (! xcoff_mark_symbol (info, h))
- return false;
+ return FALSE;
}
}
@@ -2396,11 +2397,11 @@ xcoff_mark (info, sec)
if ((sec->flags & SEC_RELOC) != 0
&& sec->reloc_count > 0)
{
- rel = xcoff_read_internal_relocs (sec->owner, sec, true,
- (bfd_byte *) NULL, false,
+ rel = xcoff_read_internal_relocs (sec->owner, sec, TRUE,
+ (bfd_byte *) NULL, FALSE,
(struct internal_reloc *) NULL);
if (rel == NULL)
- return false;
+ return FALSE;
relend = rel + sec->reloc_count;
for (; rel < relend; rel++)
{
@@ -2416,7 +2417,7 @@ xcoff_mark (info, sec)
&& (h->flags & XCOFF_MARK) == 0)
{
if (! xcoff_mark_symbol (info, h))
- return false;
+ return FALSE;
}
rsec = xcoff_data (sec->owner)->csects[rel->r_symndx];
@@ -2424,11 +2425,11 @@ xcoff_mark (info, sec)
&& (rsec->flags & SEC_MARK) == 0)
{
if (! xcoff_mark (info, rsec))
- return false;
+ return FALSE;
}
/* See if this reloc needs to be copied into the .loader
- section. */
+ section. */
switch (rel->r_type)
{
default:
@@ -2477,7 +2478,7 @@ xcoff_mark (info, sec)
}
}
- return true;
+ return TRUE;
}
/* The sweep phase of garbage collection. Remove all garbage
@@ -2498,8 +2499,8 @@ xcoff_sweep (info)
if ((o->flags & SEC_MARK) == 0)
{
/* Keep all sections from non-XCOFF input files. Keep
- special sections. Keep .debug sections for the
- moment. */
+ special sections. Keep .debug sections for the
+ moment. */
if (sub->xvec != info->hash->creator
|| o == xcoff_hash_table (info)->debug_section
|| o == xcoff_hash_table (info)->loader_section
@@ -2522,7 +2523,7 @@ xcoff_sweep (info)
/* Record the number of elements in a set. This is used to output the
correct csect length. */
-boolean
+bfd_boolean
bfd_xcoff_link_record_set (output_bfd, info, harg, size)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -2534,7 +2535,7 @@ bfd_xcoff_link_record_set (output_bfd, info, harg, size)
bfd_size_type amt;
if (bfd_get_flavour (output_bfd) != bfd_target_xcoff_flavour)
- return true;
+ return TRUE;
/* This will hardly ever be called. I don't want to burn four bytes
per global symbol, so instead the size is kept on a linked list
@@ -2543,7 +2544,7 @@ bfd_xcoff_link_record_set (output_bfd, info, harg, size)
amt = sizeof (struct xcoff_link_size_list);
n = (struct xcoff_link_size_list *) bfd_alloc (output_bfd, amt);
if (n == NULL)
- return false;
+ return FALSE;
n->next = xcoff_hash_table (info)->size_list;
n->h = h;
n->size = size;
@@ -2551,12 +2552,12 @@ bfd_xcoff_link_record_set (output_bfd, info, harg, size)
h->flags |= XCOFF_HAS_SIZE;
- return true;
+ return TRUE;
}
/* Import a symbol. */
-boolean
+bfd_boolean
bfd_xcoff_import_symbol (output_bfd, info, harg, val, imppath, impfile,
impmember, syscall_flag)
bfd *output_bfd;
@@ -2571,7 +2572,7 @@ bfd_xcoff_import_symbol (output_bfd, info, harg, val, imppath, impfile,
struct xcoff_link_hash_entry *h = (struct xcoff_link_hash_entry *) harg;
if (bfd_get_flavour (output_bfd) != bfd_target_xcoff_flavour)
- return true;
+ return TRUE;
/* A symbol name which starts with a period is the code for a
function. If the symbol is undefined, then add an undefined
@@ -2587,9 +2588,9 @@ bfd_xcoff_import_symbol (output_bfd, info, harg, val, imppath, impfile,
{
hds = xcoff_link_hash_lookup (xcoff_hash_table (info),
h->root.root.string + 1,
- true, false, true);
+ TRUE, FALSE, TRUE);
if (hds == NULL)
- return false;
+ return FALSE;
if (hds->root.type == bfd_link_hash_new)
{
hds->root.type = bfd_link_hash_undefined;
@@ -2603,8 +2604,8 @@ bfd_xcoff_import_symbol (output_bfd, info, harg, val, imppath, impfile,
}
/* Now, if the descriptor is undefined, import the descriptor
- rather than the symbol we were told to import. FIXME: Is
- this correct in all cases? */
+ rather than the symbol we were told to import. FIXME: Is
+ this correct in all cases? */
if (hds->root.type == bfd_link_hash_undefined)
h = hds;
}
@@ -2621,7 +2622,7 @@ bfd_xcoff_import_symbol (output_bfd, info, harg, val, imppath, impfile,
(info, h->root.root.string, h->root.u.def.section->owner,
h->root.u.def.section, h->root.u.def.value,
output_bfd, bfd_abs_section_ptr, val)))
- return false;
+ return FALSE;
}
h->root.type = bfd_link_hash_defined;
@@ -2641,7 +2642,7 @@ bfd_xcoff_import_symbol (output_bfd, info, harg, val, imppath, impfile,
struct xcoff_import_file **pp;
/* We start c at 1 because the first entry in the import list is
- reserved for the library search path. */
+ reserved for the library search path. */
for (pp = &xcoff_hash_table (info)->imports, c = 1;
*pp != NULL;
pp = &(*pp)->next, ++c)
@@ -2659,7 +2660,7 @@ bfd_xcoff_import_symbol (output_bfd, info, harg, val, imppath, impfile,
n = (struct xcoff_import_file *) bfd_alloc (output_bfd, amt);
if (n == NULL)
- return false;
+ return FALSE;
n->next = NULL;
n->path = imppath;
n->file = impfile;
@@ -2670,12 +2671,12 @@ bfd_xcoff_import_symbol (output_bfd, info, harg, val, imppath, impfile,
h->ldindx = c;
}
- return true;
+ return TRUE;
}
/* Export a symbol. */
-boolean
+bfd_boolean
bfd_xcoff_export_symbol (output_bfd, info, harg)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -2684,7 +2685,7 @@ bfd_xcoff_export_symbol (output_bfd, info, harg)
struct xcoff_link_hash_entry *h = (struct xcoff_link_hash_entry *) harg;
if (bfd_get_flavour (output_bfd) != bfd_target_xcoff_flavour)
- return true;
+ return TRUE;
h->flags |= XCOFF_EXPORT;
@@ -2702,11 +2703,11 @@ bfd_xcoff_export_symbol (output_bfd, info, harg)
fnname = (char *) bfd_malloc (amt);
if (fnname == NULL)
- return false;
+ return FALSE;
fnname[0] = '.';
strcpy (fnname + 1, h->root.root.string);
hfn = xcoff_link_hash_lookup (xcoff_hash_table (info),
- fnname, false, false, true);
+ fnname, FALSE, FALSE, TRUE);
free (fnname);
if (hfn != NULL
&& hfn->smclas == XMC_PR
@@ -2721,7 +2722,7 @@ bfd_xcoff_export_symbol (output_bfd, info, harg)
/* Make sure we don't garbage collect this symbol. */
if (! xcoff_mark_symbol (info, h))
- return false;
+ return FALSE;
/* If this is a function descriptor, make sure we don't garbage
collect the associated function code. We normally don't have to
@@ -2731,17 +2732,17 @@ bfd_xcoff_export_symbol (output_bfd, info, harg)
if ((h->flags & XCOFF_DESCRIPTOR) != 0)
{
if (! xcoff_mark_symbol (info, h->descriptor))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Count a reloc against a symbol. This is called for relocs
generated by the linker script, typically for global constructors
and destructors. */
-boolean
+bfd_boolean
bfd_xcoff_link_count_reloc (output_bfd, info, name)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -2750,16 +2751,16 @@ bfd_xcoff_link_count_reloc (output_bfd, info, name)
struct xcoff_link_hash_entry *h;
if (bfd_get_flavour (output_bfd) != bfd_target_xcoff_flavour)
- return true;
+ return TRUE;
h = ((struct xcoff_link_hash_entry *)
- bfd_wrapped_link_hash_lookup (output_bfd, info, name, false, false,
- false));
+ bfd_wrapped_link_hash_lookup (output_bfd, info, name, FALSE, FALSE,
+ FALSE));
if (h == NULL)
{
(*_bfd_error_handler) (_("%s: no such symbol"), name);
bfd_set_error (bfd_error_no_symbols);
- return false;
+ return FALSE;
}
h->flags |= XCOFF_REF_REGULAR | XCOFF_LDREL;
@@ -2767,15 +2768,15 @@ bfd_xcoff_link_count_reloc (output_bfd, info, name)
/* Mark the symbol to avoid garbage collection. */
if (! xcoff_mark_symbol (info, h))
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
/* This function is called for each symbol to which the linker script
assigns a value. */
-boolean
+bfd_boolean
bfd_xcoff_record_link_assignment (output_bfd, info, name)
bfd *output_bfd;
struct bfd_link_info *info;
@@ -2784,16 +2785,16 @@ bfd_xcoff_record_link_assignment (output_bfd, info, name)
struct xcoff_link_hash_entry *h;
if (bfd_get_flavour (output_bfd) != bfd_target_xcoff_flavour)
- return true;
+ return TRUE;
- h = xcoff_link_hash_lookup (xcoff_hash_table (info), name, true, true,
- false);
+ h = xcoff_link_hash_lookup (xcoff_hash_table (info), name, TRUE, TRUE,
+ FALSE);
if (h == NULL)
- return false;
+ return FALSE;
h->flags |= XCOFF_DEF_REGULAR;
- return true;
+ return TRUE;
}
/* Build the .loader section. This is called by the XCOFF linker
@@ -2813,7 +2814,7 @@ bfd_xcoff_record_link_assignment (output_bfd, info, name)
option). SPECIAL_SECTIONS is set by this routine to csects with
magic names like _end. */
-boolean
+bfd_boolean
bfd_xcoff_size_dynamic_sections (output_bfd, info, libpath, entry,
file_align, maxstack, maxdata, gc,
modtype, textro, export_defineds,
@@ -2825,12 +2826,12 @@ bfd_xcoff_size_dynamic_sections (output_bfd, info, libpath, entry,
unsigned long file_align;
unsigned long maxstack;
unsigned long maxdata;
- boolean gc;
+ bfd_boolean gc;
int modtype;
- boolean textro;
- boolean export_defineds;
+ bfd_boolean textro;
+ bfd_boolean export_defineds;
asection **special_sections;
- boolean rtld;
+ bfd_boolean rtld;
{
struct xcoff_link_hash_entry *hentry;
asection *lsec;
@@ -2851,10 +2852,10 @@ bfd_xcoff_size_dynamic_sections (output_bfd, info, libpath, entry,
{
for (i = 0; i < XCOFF_NUMBER_OF_SPECIAL_SECTIONS; i++)
special_sections[i] = NULL;
- return true;
+ return TRUE;
}
- ldinfo.failed = false;
+ ldinfo.failed = FALSE;
ldinfo.output_bfd = output_bfd;
ldinfo.info = info;
ldinfo.export_defineds = export_defineds;
@@ -2874,56 +2875,55 @@ bfd_xcoff_size_dynamic_sections (output_bfd, info, libpath, entry,
if (entry != NULL)
{
hentry = xcoff_link_hash_lookup (xcoff_hash_table (info), entry,
- false, false, true);
+ FALSE, FALSE, TRUE);
if (hentry != NULL)
hentry->flags |= XCOFF_ENTRY;
}
/* __rtinit */
- if (info->init_function || info->fini_function || rtld)
+ if (info->init_function || info->fini_function || rtld)
{
struct xcoff_link_hash_entry *hsym;
struct internal_ldsym *ldsym;
-
+
hsym = xcoff_link_hash_lookup (xcoff_hash_table (info),
- "__rtinit", false, false, true);
+ "__rtinit", FALSE, FALSE, TRUE);
if (hsym == NULL)
{
(*_bfd_error_handler)
(_("error: undefined symbol __rtinit"));
- return false;
+ return FALSE;
}
-
+
xcoff_mark_symbol (info, hsym);
hsym->flags |= (XCOFF_DEF_REGULAR | XCOFF_RTINIT);
- /* __rtinit initalized */
+ /* __rtinit initialized */
amt = sizeof (struct internal_ldsym);
ldsym = (struct internal_ldsym *) bfd_malloc (amt);
-
- ldsym->l_value = 0; /* will be filled in later */
- ldsym->l_scnum = 2; /* data section */
- ldsym->l_smtype = XTY_SD; /* csect section definition */
- ldsym->l_smclas = 5; /* .rw */
- ldsym->l_ifile = 0; /* special system loader symbol */
- ldsym->l_parm = 0; /* NA */
-
+
+ ldsym->l_value = 0; /* will be filled in later */
+ ldsym->l_scnum = 2; /* data section */
+ ldsym->l_smtype = XTY_SD; /* csect section definition */
+ ldsym->l_smclas = 5; /* .rw */
+ ldsym->l_ifile = 0; /* special system loader symbol */
+ ldsym->l_parm = 0; /* NA */
+
/* Force __rtinit to be the first symbol in the loader symbol table
See xcoff_build_ldsyms
-
+
The first 3 symbol table indices are reserved to indicate the data,
text and bss sections. */
BFD_ASSERT (0 == ldinfo.ldsym_count);
-
+
hsym->ldindx = 3;
ldinfo.ldsym_count = 1;
hsym->ldsym = ldsym;
-
- if (false == bfd_xcoff_put_ldsymbol_name (ldinfo.output_bfd, &ldinfo,
- hsym->ldsym,
- hsym->root.root.string))
- return false;
-
+
+ if (! bfd_xcoff_put_ldsymbol_name (ldinfo.output_bfd, &ldinfo,
+ hsym->ldsym, hsym->root.root.string))
+ return FALSE;
+
/* This symbol is written out by xcoff_write_global_symbol
Set stuff up so xcoff_write_global_symbol logic works. */
hsym->flags |= XCOFF_DEF_REGULAR | XCOFF_MARK;
@@ -2932,17 +2932,17 @@ bfd_xcoff_size_dynamic_sections (output_bfd, info, libpath, entry,
}
/* Garbage collect unused sections. */
- if (info->relocateable
+ if (info->relocatable
|| ! gc
|| hentry == NULL
|| (hentry->root.type != bfd_link_hash_defined
&& hentry->root.type != bfd_link_hash_defweak))
{
- gc = false;
- xcoff_hash_table (info)->gc = false;
+ gc = FALSE;
+ xcoff_hash_table (info)->gc = FALSE;
/* We still need to call xcoff_mark, in order to set ldrel_count
- correctly. */
+ correctly. */
for (sub = info->input_bfds; sub != NULL; sub = sub->link_next)
{
asection *o;
@@ -2962,7 +2962,7 @@ bfd_xcoff_size_dynamic_sections (output_bfd, info, libpath, entry,
if (! xcoff_mark (info, hentry->root.u.def.section))
goto error_return;
xcoff_sweep (info);
- xcoff_hash_table (info)->gc = true;
+ xcoff_hash_table (info)->gc = TRUE;
}
/* Return special sections to the caller. */
@@ -2982,7 +2982,7 @@ bfd_xcoff_size_dynamic_sections (output_bfd, info, libpath, entry,
if (info->input_bfds == NULL)
{
/* I'm not sure what to do in this bizarre case. */
- return true;
+ return TRUE;
}
xcoff_link_hash_traverse (xcoff_hash_table (info), xcoff_build_ldsyms,
@@ -3158,7 +3158,7 @@ bfd_xcoff_size_dynamic_sections (output_bfd, info, libpath, entry,
csectpp = xcoff_data (sub)->csects;
/* Dynamic object do not have csectpp's. */
- if (NULL != csectpp)
+ if (NULL != csectpp)
{
symesz = bfd_coff_symesz (sub);
esym = (bfd_byte *) obj_coff_external_syms (sub);
@@ -3183,7 +3183,7 @@ bfd_xcoff_size_dynamic_sections (output_bfd, info, libpath, entry,
bfd_size_type indx;
name = (char *) debug_contents + sym._n._n_n._n_offset;
- indx = _bfd_stringtab_add (debug_strtab, name, true, true);
+ indx = _bfd_stringtab_add (debug_strtab, name, TRUE, TRUE);
if (indx == (bfd_size_type) -1)
goto error_return;
*debug_index = indx;
@@ -3213,29 +3213,29 @@ bfd_xcoff_size_dynamic_sections (output_bfd, info, libpath, entry,
xcoff_hash_table (info)->debug_section->_raw_size =
_bfd_stringtab_size (debug_strtab);
- return true;
+ return TRUE;
error_return:
if (ldinfo.strings != NULL)
free (ldinfo.strings);
if (debug_contents != NULL)
free (debug_contents);
- return false;
+ return FALSE;
}
-boolean
+bfd_boolean
bfd_xcoff_link_generate_rtinit (abfd, init, fini, rtld)
bfd *abfd;
const char *init;
const char *fini;
- boolean rtld;
+ bfd_boolean rtld;
{
struct bfd_in_memory *bim;
-
+
bim = ((struct bfd_in_memory *)
bfd_malloc ((bfd_size_type) sizeof (struct bfd_in_memory)));
if (bim == NULL)
- return false;
+ return FALSE;
bim->size = 0;
bim->buffer = 0;
@@ -3247,21 +3247,21 @@ bfd_xcoff_link_generate_rtinit (abfd, init, fini, rtld)
abfd->direction = write_direction;
abfd->where = 0;
- if (false == bfd_xcoff_generate_rtinit (abfd, init, fini, rtld))
- return false;
+ if (! bfd_xcoff_generate_rtinit (abfd, init, fini, rtld))
+ return FALSE;
/* need to reset to unknown or it will not be read back in correctly */
abfd->format = bfd_unknown;
abfd->direction = read_direction;
abfd->where = 0;
- return true;
+ return TRUE;
}
/* Add a symbol to the .loader symbols, if necessary. */
-static boolean
+static bfd_boolean
xcoff_build_ldsyms (h, p)
struct xcoff_link_hash_entry *h;
PTR p;
@@ -3274,7 +3274,7 @@ xcoff_build_ldsyms (h, p)
/* __rtinit, this symbol has special handling. */
if (h->flags & XCOFF_RTINIT)
- return true;
+ return TRUE;
/* If this is a final link, and the symbol was defined as a common
symbol in a regular object file, and there was no definition in
@@ -3296,7 +3296,7 @@ xcoff_build_ldsyms (h, p)
&& (h->flags & XCOFF_DEF_REGULAR) != 0
&& h->root.root.string[0] != '.')
{
- boolean export;
+ bfd_boolean export;
/* We don't export a symbol which is being defined by an object
included from an archive which contains a shared object. The
@@ -3312,7 +3312,7 @@ xcoff_build_ldsyms (h, p)
them. This is confusing, but I haven't been able to think of
a different approach. Note that the symbols can, of course,
be exported explicitly. */
- export = true;
+ export = TRUE;
if ((h->root.type == bfd_link_hash_defined
|| h->root.type == bfd_link_hash_defweak)
&& h->root.u.def.section->owner != NULL
@@ -3326,7 +3326,7 @@ xcoff_build_ldsyms (h, p)
{
if ((member->flags & DYNAMIC) != 0)
{
- export = false;
+ export = FALSE;
break;
}
member = bfd_openr_next_archived_file (arbfd, member);
@@ -3375,7 +3375,7 @@ xcoff_build_ldsyms (h, p)
sec->_raw_size += bfd_xcoff_glink_code_size(ldinfo->output_bfd);
/* The global linkage code requires a TOC entry for the
- descriptor. */
+ descriptor. */
hds = h->descriptor;
BFD_ASSERT ((hds->root.type == bfd_link_hash_undefined
|| hds->root.type == bfd_link_hash_undefweak)
@@ -3393,7 +3393,7 @@ xcoff_build_ldsyms (h, p)
else if (bfd_xcoff_is_xcoff32 (ldinfo->output_bfd))
byte_size = 4;
else
- return false;
+ return FALSE;
hds->toc_section = xcoff_hash_table (ldinfo->info)->toc_section;
hds->u.toc_offset = hds->toc_section->_raw_size;
@@ -3425,10 +3425,10 @@ xcoff_build_ldsyms (h, p)
asection *sec;
/* This is an undefined function descriptor associated with
- a defined entry point. We can build up a function
- descriptor ourselves. Believe it or not, the AIX linker
- actually does this, and there are cases where we need to
- do it as well. */
+ a defined entry point. We can build up a function
+ descriptor ourselves. Believe it or not, the AIX linker
+ actually does this, and there are cases where we need to
+ do it as well. */
sec = xcoff_hash_table (ldinfo->info)->descriptor_section;
h->root.type = bfd_link_hash_defined;
h->root.u.def.section = sec;
@@ -3455,7 +3455,7 @@ xcoff_build_ldsyms (h, p)
(_("warning: attempt to export undefined symbol `%s'"),
h->root.root.string);
h->ldsym = NULL;
- return true;
+ return TRUE;
}
}
@@ -3484,7 +3484,7 @@ xcoff_build_ldsyms (h, p)
&& (h->flags & XCOFF_EXPORT) == 0)
{
h->ldsym = NULL;
- return true;
+ return TRUE;
}
/* We don't need to add this symbol if we did garbage collection and
@@ -3493,13 +3493,13 @@ xcoff_build_ldsyms (h, p)
&& (h->flags & XCOFF_MARK) == 0)
{
h->ldsym = NULL;
- return true;
+ return TRUE;
}
/* We may have already processed this symbol due to the recursive
call above. */
if ((h->flags & XCOFF_BUILT_LDSYM) != 0)
- return true;
+ return TRUE;
/* We need to add this symbol to the .loader symbols. */
@@ -3508,8 +3508,8 @@ xcoff_build_ldsyms (h, p)
h->ldsym = (struct internal_ldsym *) bfd_zalloc (ldinfo->output_bfd, amt);
if (h->ldsym == NULL)
{
- ldinfo->failed = true;
- return false;
+ ldinfo->failed = TRUE;
+ return FALSE;
}
if ((h->flags & XCOFF_IMPORT) != 0)
@@ -3521,21 +3521,20 @@ xcoff_build_ldsyms (h, p)
++ldinfo->ldsym_count;
- if (false == bfd_xcoff_put_ldsymbol_name (ldinfo->output_bfd, ldinfo,
- h->ldsym,
- h->root.root.string))
+ if (! bfd_xcoff_put_ldsymbol_name (ldinfo->output_bfd, ldinfo,
+ h->ldsym, h->root.root.string))
{
- return false;
+ return FALSE;
}
h->flags |= XCOFF_BUILT_LDSYM;
- return true;
+ return TRUE;
}
/* Do the final link step. */
-boolean
+bfd_boolean
_bfd_xcoff_bfd_final_link (abfd, info)
bfd *abfd;
struct bfd_link_info *info;
@@ -3611,7 +3610,7 @@ _bfd_xcoff_bfd_final_link (abfd, info)
link. This will normally be every section. We need
to do this so that we can identify any sections which
the linker has decided to not include. */
- sec->linker_mark = true;
+ sec->linker_mark = TRUE;
if (info->strip == strip_none
|| info->strip == strip_some)
@@ -3651,49 +3650,49 @@ _bfd_xcoff_bfd_final_link (abfd, info)
file_align = xcoff_hash_table (info)->file_align;
if (file_align != 0)
{
- boolean saw_contents;
+ bfd_boolean saw_contents;
int indx;
asection **op;
file_ptr sofar;
-
+
/* Insert .pad sections before every section which has
- contents and is loaded, if it is preceded by some other
- section which has contents and is loaded. */
- saw_contents = true;
+ contents and is loaded, if it is preceded by some other
+ section which has contents and is loaded. */
+ saw_contents = TRUE;
for (op = &abfd->sections; *op != NULL; op = &(*op)->next)
{
if (strcmp ((*op)->name, ".pad") == 0)
- saw_contents = false;
+ saw_contents = FALSE;
else if (((*op)->flags & SEC_HAS_CONTENTS) != 0
&& ((*op)->flags & SEC_LOAD) != 0)
{
if (! saw_contents)
- saw_contents = true;
+ saw_contents = TRUE;
else
{
asection *n, **st;
-
+
/* Create a pad section and place it before the section
- that needs padding. This requires unlinking and
+ that needs padding. This requires unlinking and
relinking the bfd's section list. */
-
+
st = abfd->section_tail;
n = bfd_make_section_anyway (abfd, ".pad");
n->flags = SEC_HAS_CONTENTS;
- n->alignment_power = 0;
+ n->alignment_power = 0;
BFD_ASSERT (*st == n);
bfd_section_list_remove (abfd, st);
bfd_section_list_insert (abfd, op, n);
op = &n->next;
- saw_contents = false;
+ saw_contents = FALSE;
}
}
}
-
+
/* Reset the section indices after inserting the new
- sections. */
+ sections. */
indx = 0;
for (o = abfd->sections; o != NULL; o = o->next)
{
@@ -3703,9 +3702,9 @@ _bfd_xcoff_bfd_final_link (abfd, info)
BFD_ASSERT ((unsigned int) indx == abfd->section_count);
/* Work out appropriate sizes for the .pad sections to force
- each section to land on a page boundary. This bit of
- code knows what compute_section_file_positions is going
- to do. */
+ each section to land on a page boundary. This bit of
+ code knows what compute_section_file_positions is going
+ to do. */
sofar = bfd_coff_filhsz (abfd);
sofar += bfd_coff_aoutsz (abfd);
sofar += abfd->section_count * bfd_coff_scnhsz (abfd);
@@ -3775,8 +3774,8 @@ _bfd_xcoff_bfd_final_link (abfd, info)
else
{
/* A stripped file has no relocs. However, we still
- allocate the buffers, so that later code doesn't have to
- worry about whether we are stripping or not. */
+ allocate the buffers, so that later code doesn't have to
+ worry about whether we are stripping or not. */
if (info->strip == strip_all)
o->rel_filepos = 0;
else
@@ -3787,13 +3786,13 @@ _bfd_xcoff_bfd_final_link (abfd, info)
}
/* We don't know the indices of global symbols until we have
- written out all the local symbols. For each section in
- the output file, we keep an array of pointers to hash
- table entries. Each entry in the array corresponds to a
- reloc. When we find a reloc against a global symbol, we
- set the corresponding entry in this array so that we can
- fix up the symbol index after we have written out all the
- local symbols.
+ written out all the local symbols. For each section in
+ the output file, we keep an array of pointers to hash
+ table entries. Each entry in the array corresponds to a
+ reloc. When we find a reloc against a global symbol, we
+ set the corresponding entry in this array so that we can
+ fix up the symbol index after we have written out all the
+ local symbols.
Because of this problem, we also keep the relocs in
memory until the end of the link. This wastes memory.
@@ -3850,7 +3849,7 @@ _bfd_xcoff_bfd_final_link (abfd, info)
{
bfd_size_type sz;
- sub->output_has_begun = false;
+ sub->output_has_begun = FALSE;
sz = obj_raw_syment_count (sub);
if (sz > max_sym_count)
max_sym_count = sz;
@@ -3903,7 +3902,7 @@ _bfd_xcoff_bfd_final_link (abfd, info)
{
if (! xcoff_link_input_bfd (&finfo, sub))
goto error_return;
- sub->output_has_begun = true;
+ sub->output_has_begun = TRUE;
}
}
else if (p->type == bfd_section_reloc_link_order
@@ -4142,7 +4141,7 @@ _bfd_xcoff_bfd_final_link (abfd, info)
not try to write out the symbols. */
bfd_get_symcount (abfd) = 0;
- return true;
+ return TRUE;
error_return:
if (finfo.strtab != NULL)
@@ -4176,13 +4175,13 @@ _bfd_xcoff_bfd_final_link (abfd, info)
free (finfo.external_relocs);
if (external_relocs != NULL)
free (external_relocs);
- return false;
+ return FALSE;
}
/* Link an input file into the linker output file. This function
handles all the sections and relocations of the input file at once. */
-static boolean
+static bfd_boolean
xcoff_link_input_bfd (finfo, input_bfd)
struct xcoff_final_link_info *finfo;
bfd *input_bfd;
@@ -4192,7 +4191,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
bfd_size_type syment_base;
unsigned int n_tmask;
unsigned int n_btshft;
- boolean copy, hash;
+ bfd_boolean copy, hash;
bfd_size_type isymesz;
bfd_size_type osymesz;
bfd_size_type linesz;
@@ -4207,13 +4206,13 @@ xcoff_link_input_bfd (finfo, input_bfd)
bfd_byte *outsym;
unsigned int incls;
asection *oline;
- boolean keep_syms;
+ bfd_boolean keep_syms;
asection *o;
/* We can just skip DYNAMIC files, unless this is a static link. */
if ((input_bfd->flags & DYNAMIC) != 0
&& ! finfo->info->static_link)
- return true;
+ return TRUE;
/* Move all the symbols to the output file. */
@@ -4232,15 +4231,15 @@ xcoff_link_input_bfd (finfo, input_bfd)
#define N_TMASK n_tmask
#define N_BTSHFT n_btshft
- copy = false;
+ copy = FALSE;
if (! finfo->info->keep_memory)
- copy = true;
- hash = true;
+ copy = TRUE;
+ hash = TRUE;
if ((output_bfd->flags & BFD_TRADITIONAL_FORMAT) != 0)
- hash = false;
+ hash = FALSE;
if (! _bfd_coff_get_external_symbols (input_bfd))
- return false;
+ return FALSE;
esym = (bfd_byte *) obj_coff_external_syms (input_bfd);
esym_end = esym + obj_raw_syment_count (input_bfd) * isymesz;
@@ -4260,14 +4259,14 @@ xcoff_link_input_bfd (finfo, input_bfd)
struct internal_syment isym;
union internal_auxent aux;
int smtyp = 0;
- boolean skip;
- boolean require;
+ bfd_boolean skip;
+ bfd_boolean require;
int add;
bfd_coff_swap_sym_in (input_bfd, (PTR) esym, (PTR) isymp);
/* If this is a C_EXT or C_HIDEXT symbol, we need the csect
- information. */
+ information. */
if (isymp->n_sclass == C_EXT || isymp->n_sclass == C_HIDEXT)
{
BFD_ASSERT (isymp->n_numaux > 0);
@@ -4287,9 +4286,9 @@ xcoff_link_input_bfd (finfo, input_bfd)
isym = *isymp;
/* If this symbol is in the .loader section, swap out the
- .loader symbol information. If this is an external symbol
- reference to a defined symbol, though, then wait until we get
- to the definition. */
+ .loader symbol information. If this is an external symbol
+ reference to a defined symbol, though, then wait until we get
+ to the definition. */
if (isym.n_sclass == C_EXT
&& *sym_hash != NULL
&& (*sym_hash)->ldsym != NULL
@@ -4379,26 +4378,26 @@ xcoff_link_input_bfd (finfo, input_bfd)
*indexp = -1;
- skip = false;
- require = false;
+ skip = FALSE;
+ require = FALSE;
add = 1 + isym.n_numaux;
/* If we are skipping this csect, we want to skip this symbol. */
if (*csectpp == NULL)
- skip = true;
+ skip = TRUE;
/* If we garbage collected this csect, we want to skip this
- symbol. */
+ symbol. */
if (! skip
&& xcoff_hash_table (finfo->info)->gc
&& ((*csectpp)->flags & SEC_MARK) == 0
&& *csectpp != bfd_abs_section_ptr)
- skip = true;
+ skip = TRUE;
/* An XCOFF linker always skips C_STAT symbols. */
if (! skip
&& isymp->n_sclass == C_STAT)
- skip = true;
+ skip = TRUE;
/* We skip all but the first TOC anchor. */
if (! skip
@@ -4406,7 +4405,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
&& aux.x_csect.x_smclas == XMC_TC0)
{
if (finfo->toc_symindx != -1)
- skip = true;
+ skip = TRUE;
else
{
bfd_vma tocval, tocend;
@@ -4418,11 +4417,11 @@ xcoff_link_input_bfd (finfo, input_bfd)
- (*csectpp)->vma);
/* We want to find out if tocval is a good value to use
- as the TOC anchor--that is, whether we can access all
- of the TOC using a 16 bit offset from tocval. This
- test assumes that the TOC comes at the end of the
- output section, as it does in the default linker
- script. */
+ as the TOC anchor--that is, whether we can access all
+ of the TOC using a 16 bit offset from tocval. This
+ test assumes that the TOC comes at the end of the
+ output section, as it does in the default linker
+ script. */
tocend = ((*csectpp)->output_section->vma
+ (*csectpp)->output_section->_raw_size);
for (inp = finfo->info->input_bfds;
@@ -4449,7 +4448,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
(_("TOC overflow: 0x%lx > 0x10000; try -mminimal-toc when compiling"),
(unsigned long) (tocend - tocval));
bfd_set_error (bfd_error_file_too_big);
- return false;
+ return FALSE;
}
if (tocval + 0x8000 < tocend)
@@ -4465,7 +4464,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
xcoff_data (finfo->output_bfd)->toc = tocval;
xcoff_data (finfo->output_bfd)->sntoc =
(*csectpp)->output_section->target_index;
- require = true;
+ require = TRUE;
}
}
@@ -4473,17 +4472,17 @@ xcoff_link_input_bfd (finfo, input_bfd)
/* If we are stripping all symbols, we want to skip this one. */
if (! skip
&& finfo->info->strip == strip_all)
- skip = true;
+ skip = TRUE;
/* We can skip resolved external references. */
if (! skip
&& isym.n_sclass == C_EXT
&& smtyp == XTY_ER
&& (*sym_hash)->root.type != bfd_link_hash_undefined)
- skip = true;
+ skip = TRUE;
/* We can skip common symbols if they got defined somewhere
- else. */
+ else. */
if (! skip
&& isym.n_sclass == C_EXT
&& smtyp == XTY_CM
@@ -4491,7 +4490,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
|| (*sym_hash)->root.u.c.p->section != *csectpp)
&& ((*sym_hash)->root.type != bfd_link_hash_defined
|| (*sym_hash)->root.u.def.section != *csectpp))
- skip = true;
+ skip = TRUE;
/* Skip local symbols if we are discarding them. */
if (! skip
@@ -4499,14 +4498,14 @@ xcoff_link_input_bfd (finfo, input_bfd)
&& isym.n_sclass != C_EXT
&& (isym.n_sclass != C_HIDEXT
|| smtyp != XTY_SD))
- skip = true;
+ skip = TRUE;
/* If we stripping debugging symbols, and this is a debugging
- symbol, then skip it. */
+ symbol, then skip it. */
if (! skip
&& finfo->info->strip == strip_debugger
&& isym.n_scnum == N_DEBUG)
- skip = true;
+ skip = TRUE;
/* If some symbols are stripped based on the name, work out the
name and decide whether to skip this symbol. We don't handle
@@ -4524,24 +4523,24 @@ xcoff_link_input_bfd (finfo, input_bfd)
name = _bfd_coff_internal_syment_name (input_bfd, &isym, buf);
if (name == NULL)
- return false;
+ return FALSE;
if ((finfo->info->strip == strip_some
- && (bfd_hash_lookup (finfo->info->keep_hash, name, false,
- false) == NULL))
+ && (bfd_hash_lookup (finfo->info->keep_hash, name, FALSE,
+ FALSE) == NULL))
|| (finfo->info->discard == discard_l
&& (isym.n_sclass != C_EXT
&& (isym.n_sclass != C_HIDEXT
|| smtyp != XTY_SD))
&& bfd_is_local_label_name (input_bfd, name)))
- skip = true;
+ skip = TRUE;
}
/* We can not skip the first TOC anchor. */
if (skip
&& require
&& finfo->info->strip != strip_all)
- skip = false;
+ skip = FALSE;
/* We now know whether we are to skip this symbol or not. */
if (! skip)
@@ -4565,10 +4564,10 @@ xcoff_link_input_bfd (finfo, input_bfd)
(char *) NULL);
if (name == NULL)
- return false;
+ return FALSE;
indx = _bfd_stringtab_add (finfo->strtab, name, hash, copy);
if (indx == (bfd_size_type) -1)
- return false;
+ return FALSE;
isym._n._n_n._n_offset = STRING_SIZE_SIZE + indx;
}
}
@@ -4622,7 +4621,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
if (bfd_seek (output_bfd, pos, SEEK_SET) != 0
|| (bfd_bwrite (outsym, osymesz, output_bfd)
!= osymesz))
- return false;
+ return FALSE;
}
}
@@ -4631,8 +4630,8 @@ xcoff_link_input_bfd (finfo, input_bfd)
}
/* The value of a C_BINCL or C_EINCL symbol is a file offset
- into the line numbers. We update the symbol values when
- we handle the line numbers. */
+ into the line numbers. We update the symbol values when
+ we handle the line numbers. */
if (isym.n_sclass == C_BINCL
|| isym.n_sclass == C_EINCL)
{
@@ -4659,8 +4658,8 @@ xcoff_link_input_bfd (finfo, input_bfd)
}
/* If this is a symbol in the TOC which we may have merged
- (class XMC_TC), remember the symbol index of the TOC
- symbol. */
+ (class XMC_TC), remember the symbol index of the TOC
+ symbol. */
if (isym.n_sclass == C_HIDEXT
&& aux.x_csect.x_smclas == XMC_TC
&& *sym_hash != NULL)
@@ -4715,7 +4714,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
bfd_vma indx;
/* The value of a C_BSTAT symbol is the symbol table
- index of the containing csect. */
+ index of the containing csect. */
bfd_coff_swap_sym_in (output_bfd, (PTR) outsym, (PTR) &isym);
indx = isym.n_value;
if (indx < obj_raw_syment_count (input_bfd))
@@ -4760,13 +4759,13 @@ xcoff_link_input_bfd (finfo, input_bfd)
{
strings = _bfd_coff_read_string_table (input_bfd);
if (strings == NULL)
- return false;
+ return FALSE;
}
filename = strings + aux.x_file.x_n.x_offset;
indx = _bfd_stringtab_add (finfo->strtab, filename,
hash, copy);
if (indx == (bfd_size_type) -1)
- return false;
+ return FALSE;
aux.x_file.x_n.x_offset = STRING_SIZE_SIZE + indx;
}
}
@@ -4776,10 +4775,10 @@ xcoff_link_input_bfd (finfo, input_bfd)
{
/* We don't support type checking. I don't know if
- anybody does. */
+ anybody does. */
aux.x_csect.x_parmhash = 0;
/* I don't think anybody uses these fields, but we'd
- better clobber them just in case. */
+ better clobber them just in case. */
aux.x_csect.x_stab = 0;
aux.x_csect.x_snstab = 0;
@@ -4818,9 +4817,9 @@ xcoff_link_input_bfd (finfo, input_bfd)
&& indx < obj_raw_syment_count (input_bfd))
{
/* We look forward through the symbol for
- the index of the next symbol we are going
- to include. I don't know if this is
- entirely right. */
+ the index of the next symbol we are going
+ to include. I don't know if this is
+ entirely right. */
while (finfo->sym_indices[indx] < 0
&& indx < obj_raw_syment_count (input_bfd))
++indx;
@@ -4877,7 +4876,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
if (bfd_seek (input_bfd, pos, SEEK_SET) != 0
|| (bfd_bread (finfo->linenos, amt, input_bfd)
!= amt))
- return false;
+ return FALSE;
oline = enclosing;
}
@@ -4937,7 +4936,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
|| (bfd_bwrite (finfo->linenos + linoff,
linesz * count, output_bfd)
!= linesz * count))
- return false;
+ return FALSE;
o->output_section->lineno_count += count;
@@ -4949,8 +4948,8 @@ xcoff_link_input_bfd (finfo, input_bfd)
int iiadd;
/* Update any C_BINCL or C_EINCL symbols
- that refer to a line number in the
- range we just output. */
+ that refer to a line number in the
+ range we just output. */
iisp = finfo->internal_syms;
iispend = (iisp
+ obj_raw_syment_count (input_bfd));
@@ -5028,7 +5027,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
bfd_size_type amt = outsym - finfo->outsyms;
if (bfd_seek (output_bfd, pos, SEEK_SET) != 0
|| bfd_bwrite (finfo->outsyms, amt, output_bfd) != amt)
- return false;
+ return FALSE;
BFD_ASSERT ((obj_raw_syment_count (output_bfd)
+ (outsym - finfo->outsyms) / osymesz)
@@ -5039,7 +5038,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
/* Don't let the linker relocation routines discard the symbols. */
keep_syms = obj_coff_keep_syms (input_bfd);
- obj_coff_keep_syms (input_bfd) = true;
+ obj_coff_keep_syms (input_bfd) = TRUE;
/* Relocate the contents of each section. */
for (o = input_bfd->sections; o != NULL; o = o->next)
@@ -5066,7 +5065,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
else {
if (! bfd_get_section_contents (input_bfd, o, finfo->contents,
(file_ptr) 0, o->_raw_size))
- return false;
+ return FALSE;
contents = finfo->contents;
}
@@ -5083,12 +5082,12 @@ xcoff_link_input_bfd (finfo, input_bfd)
/* Read in the relocs. */
target_index = o->output_section->target_index;
internal_relocs = (xcoff_read_internal_relocs
- (input_bfd, o, false, finfo->external_relocs,
- true,
+ (input_bfd, o, FALSE, finfo->external_relocs,
+ TRUE,
(finfo->section_info[target_index].relocs
+ o->output_section->reloc_count)));
if (internal_relocs == NULL)
- return false;
+ return FALSE;
/* Call processor specific code to relocate the section
contents. */
@@ -5098,7 +5097,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
internal_relocs,
finfo->internal_syms,
xcoff_data (input_bfd)->csects))
- return false;
+ return FALSE;
offset = o->output_section->vma + o->output_offset - o->vma;
irel = internal_relocs;
@@ -5109,7 +5108,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
{
struct xcoff_link_hash_entry *h = NULL;
struct internal_ldrel ldrel;
- boolean quiet;
+ bfd_boolean quiet;
*rel_hash = NULL;
@@ -5153,7 +5152,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
n = ((struct xcoff_toc_rel_hash *)
bfd_alloc (finfo->output_bfd, amt));
if (n == NULL)
- return false;
+ return FALSE;
si = finfo->section_info + target_index;
n->next = si->toc_rel_hashes;
n->h = h;
@@ -5233,17 +5232,17 @@ xcoff_link_input_bfd (finfo, input_bfd)
(input_bfd, is, buf));
if (name == NULL)
- return false;
+ return FALSE;
if (! ((*finfo->info->callbacks->unattached_reloc)
(finfo->info, name, input_bfd, o,
irel->r_vaddr)))
- return false;
+ return FALSE;
}
}
}
- quiet = false;
+ quiet = FALSE;
switch (irel->r_type)
{
default:
@@ -5290,12 +5289,12 @@ xcoff_link_input_bfd (finfo, input_bfd)
bfd_archive_filename (input_bfd),
sec->name);
bfd_set_error (bfd_error_nonrepresentable_section);
- return false;
+ return FALSE;
}
}
else
{
- if (! finfo->info->relocateable
+ if (! finfo->info->relocatable
&& (h->flags & XCOFF_DEF_DYNAMIC) == 0
&& (h->flags & XCOFF_IMPORT) == 0)
{
@@ -5303,7 +5302,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
callback for this relocation, in
_bfd_ppc_xcoff_relocate_section. Don't
issue any more warnings. */
- quiet = true;
+ quiet = TRUE;
}
if (h->ldindx < 0 && ! quiet)
{
@@ -5312,7 +5311,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
bfd_archive_filename (input_bfd),
h->root.root.string);
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
ldrel.l_symndx = h->ldindx;
}
@@ -5328,7 +5327,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
bfd_get_section_name (finfo->output_bfd,
o->output_section));
bfd_set_error (bfd_error_invalid_operation);
- return false;
+ return FALSE;
}
bfd_xcoff_swap_ldrel_out (output_bfd, &ldrel,
finfo->ldrel);
@@ -5356,7 +5355,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
(o->_cooked_size != 0
? o->_cooked_size
: o->_raw_size)))
- return false;
+ return FALSE;
}
obj_coff_keep_syms (input_bfd) = keep_syms;
@@ -5364,10 +5363,10 @@ xcoff_link_input_bfd (finfo, input_bfd)
if (! finfo->info->keep_memory)
{
if (! _bfd_coff_free_symbols (input_bfd))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
#undef N_TMASK
@@ -5376,7 +5375,7 @@ xcoff_link_input_bfd (finfo, input_bfd)
/* Write out a non-XCOFF global symbol. */
-static boolean
+static bfd_boolean
xcoff_write_global_symbol (h, inf)
struct xcoff_link_hash_entry *h;
PTR inf;
@@ -5386,7 +5385,7 @@ xcoff_write_global_symbol (h, inf)
bfd_byte *outsym;
struct internal_syment isym;
union internal_auxent aux;
- boolean result;
+ bfd_boolean result;
file_ptr pos;
bfd_size_type amt;
@@ -5397,13 +5396,13 @@ xcoff_write_global_symbol (h, inf)
{
h = (struct xcoff_link_hash_entry *) h->root.u.i.link;
if (h->root.type == bfd_link_hash_new)
- return true;
+ return TRUE;
}
/* If this symbol was garbage collected, just skip it. */
if (xcoff_hash_table (finfo->info)->gc
&& (h->flags & XCOFF_MARK) == 0)
- return true;
+ return TRUE;
/* If we need a .loader section entry, write it out. */
if (h->ldsym != NULL)
@@ -5625,7 +5624,7 @@ xcoff_write_global_symbol (h, inf)
}
else
{
- return false;
+ return FALSE;
}
irel->r_type = R_POS;
finfo->section_info[oindx].rel_hashes[osec->reloc_count] = NULL;
@@ -5645,10 +5644,8 @@ xcoff_write_global_symbol (h, inf)
result = bfd_xcoff_put_symbol_name (output_bfd, finfo->strtab,
&irsym, h->root.root.string);
- if (false == result)
- {
- return false;
- }
+ if (!result)
+ return FALSE;
irsym.n_value = irel->r_vaddr;
irsym.n_scnum = osec->target_index;
@@ -5674,7 +5671,7 @@ xcoff_write_global_symbol (h, inf)
amt = outsym - finfo->outsyms;
if (bfd_seek (output_bfd, pos, SEEK_SET) != 0
|| bfd_bwrite (finfo->outsyms, amt, output_bfd) != amt)
- return false;
+ return FALSE;
obj_raw_syment_count (output_bfd) +=
(outsym - finfo->outsyms) / bfd_coff_symesz (output_bfd);
@@ -5721,7 +5718,7 @@ xcoff_write_global_symbol (h, inf)
}
else
{
- return false;
+ return FALSE;
}
sec = h->root.u.def.section;
@@ -5759,7 +5756,7 @@ xcoff_write_global_symbol (h, inf)
bfd_get_filename (output_bfd),
esec->output_section->name);
bfd_set_error (bfd_error_nonrepresentable_section);
- return false;
+ return FALSE;
}
ldrel.l_rtype = (reloc_size << 8) | R_POS;
ldrel.l_rsecnm = oindx;
@@ -5821,7 +5818,7 @@ xcoff_write_global_symbol (h, inf)
bfd_get_filename (output_bfd),
tsec->output_section->name);
bfd_set_error (bfd_error_nonrepresentable_section);
- return false;
+ return FALSE;
}
ldrel.l_rtype = (reloc_size << 8) | R_POS;
ldrel.l_rsecnm = oindx;
@@ -5832,24 +5829,24 @@ xcoff_write_global_symbol (h, inf)
if (h->indx >= 0 || finfo->info->strip == strip_all)
{
BFD_ASSERT (outsym == finfo->outsyms);
- return true;
+ return TRUE;
}
if (h->indx != -2
&& (finfo->info->strip == strip_all
|| (finfo->info->strip == strip_some
&& bfd_hash_lookup (finfo->info->keep_hash, h->root.root.string,
- false, false) == NULL)))
+ FALSE, FALSE) == NULL)))
{
BFD_ASSERT (outsym == finfo->outsyms);
- return true;
+ return TRUE;
}
if (h->indx != -2
&& (h->flags & (XCOFF_REF_REGULAR | XCOFF_DEF_REGULAR)) == 0)
{
BFD_ASSERT (outsym == finfo->outsyms);
- return true;
+ return TRUE;
}
memset (&aux, 0, sizeof aux);
@@ -5858,10 +5855,8 @@ xcoff_write_global_symbol (h, inf)
result = bfd_xcoff_put_symbol_name (output_bfd, finfo->strtab, &isym,
h->root.root.string);
- if (false == result)
- {
- return false;
- }
+ if (!result)
+ return FALSE;
if (h->root.type == bfd_link_hash_undefined
|| h->root.type == bfd_link_hash_undefweak)
@@ -5957,16 +5952,16 @@ xcoff_write_global_symbol (h, inf)
amt = outsym - finfo->outsyms;
if (bfd_seek (output_bfd, pos, SEEK_SET) != 0
|| bfd_bwrite (finfo->outsyms, amt, output_bfd) != amt)
- return false;
+ return FALSE;
obj_raw_syment_count (output_bfd) +=
(outsym - finfo->outsyms) / bfd_coff_symesz (output_bfd);
- return true;
+ return TRUE;
}
/* Handle a link order which is supposed to generate a reloc. */
-static boolean
+static bfd_boolean
xcoff_reloc_link_order (output_bfd, finfo, output_section, link_order)
bfd *output_bfd;
struct xcoff_final_link_info *finfo;
@@ -5985,9 +5980,9 @@ xcoff_reloc_link_order (output_bfd, finfo, output_section, link_order)
if (link_order->type == bfd_section_reloc_link_order)
{
/* We need to somehow locate a symbol in the right section. The
- symbol must either have a value of zero, or we must adjust
- the addend by the value of the symbol. FIXME: Write this
- when we need it. The old linker couldn't handle this anyhow. */
+ symbol must either have a value of zero, or we must adjust
+ the addend by the value of the symbol. FIXME: Write this
+ when we need it. The old linker couldn't handle this anyhow. */
abort ();
}
@@ -5995,20 +5990,20 @@ xcoff_reloc_link_order (output_bfd, finfo, output_section, link_order)
if (howto == NULL)
{
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
h = ((struct xcoff_link_hash_entry *)
bfd_wrapped_link_hash_lookup (output_bfd, finfo->info,
link_order->u.reloc.p->u.name,
- false, false, true));
+ FALSE, FALSE, TRUE));
if (h == NULL)
{
if (! ((*finfo->info->callbacks->unattached_reloc)
(finfo->info, link_order->u.reloc.p->u.name, (bfd *) NULL,
(asection *) NULL, (bfd_vma) 0)))
- return false;
- return true;
+ return FALSE;
+ return TRUE;
}
if (h->root.type == bfd_link_hash_common)
@@ -6039,12 +6034,12 @@ xcoff_reloc_link_order (output_bfd, finfo, output_section, link_order)
bfd_size_type size;
bfd_byte *buf;
bfd_reloc_status_type rstat;
- boolean ok;
+ bfd_boolean ok;
size = bfd_get_reloc_size (howto);
buf = (bfd_byte *) bfd_zmalloc (size);
if (buf == NULL)
- return false;
+ return FALSE;
rstat = _bfd_relocate_contents (howto, output_bfd, addend, buf);
switch (rstat)
@@ -6061,7 +6056,7 @@ xcoff_reloc_link_order (output_bfd, finfo, output_section, link_order)
(bfd_vma) 0)))
{
free (buf);
- return false;
+ return FALSE;
}
break;
}
@@ -6069,7 +6064,7 @@ xcoff_reloc_link_order (output_bfd, finfo, output_section, link_order)
(file_ptr) link_order->offset, size);
free (buf);
if (! ok)
- return false;
+ return FALSE;
}
/* Store the reloc information in the right place. It will get
@@ -6124,7 +6119,7 @@ xcoff_reloc_link_order (output_bfd, finfo, output_section, link_order)
(_("%s: loader reloc in unrecognized section `%s'"),
bfd_get_filename (output_bfd), secname);
bfd_set_error (bfd_error_nonrepresentable_section);
- return false;
+ return FALSE;
}
}
else
@@ -6136,7 +6131,7 @@ xcoff_reloc_link_order (output_bfd, finfo, output_section, link_order)
bfd_get_filename (output_bfd),
h->root.root.string);
bfd_set_error (bfd_error_bad_value);
- return false;
+ return FALSE;
}
ldrel.l_symndx = h->ldindx;
}
@@ -6146,7 +6141,7 @@ xcoff_reloc_link_order (output_bfd, finfo, output_section, link_order)
bfd_xcoff_swap_ldrel_out (output_bfd, &ldrel, finfo->ldrel);
finfo->ldrel += bfd_xcoff_ldrelsz(output_bfd);
- return true;
+ return TRUE;
}
/* Sort relocs by VMA. This is called via qsort. */
diff --git a/contrib/binutils/binutils/ChangeLog b/contrib/binutils/binutils/ChangeLog
index 95d72cf..185b21b 100644
--- a/contrib/binutils/binutils/ChangeLog
+++ b/contrib/binutils/binutils/ChangeLog
@@ -1,2880 +1,132 @@
-2002-11-07 Nick Clifton <nickc@redhat.com>
-
- * configure.in (LINGUAS): Add 'da'.
- * configure: Regenerate.
- * po/da.po: New Danish translation.
-
-2002-10-30 Daniel Jacobowitz <drow@mvista.com>
-
- * po/binutils.pot: Regenerated.
-
-2002-10-28 Daniel Jacobowitz <drow@mvista.com>
-
- Merge from mainline:
- 2002-10-21 Alan Modra <amodra@bigpond.net.au>
- * bucomm.c (list_supported_targets): Use bfd_target_list.
-
- 2002-10-09 Daniel Jacobowitz <drow@mvista.com>
- * readelf.c (display_debug_info): Ignore empty .rela.debug_info
- sections. Allow relocations against the absolute symbol. Don't
- use the value in compunit.cu_abbrev_offset if we found a RELA
- relocation.
-
-2002-10-21 Svein E. Seldal <Svein.Seldal@solidas.com>
-
- * objdump.c (dump_data): Correct addr_offset for opb != 1.
-
-2002-09-23 Daniel Jacobowitz <drow@mvista.com>
-
- Merge from mainline:
- 2002-09-11 Nick Clifton <nickc@redhat.com>
- * po/tr.po: Updated Turkish translation.
-
- 2002-08-14 Luke Dunstan <infidel@users.sourceforge.net>
- * rcparse.y (acc_entry): Don't warn about ALT use with
- non-VIRTKEY.
-
- 2002-08-09 Nick Clifton <nickc@redhat.com>
- * po/sv.po: Updated Swedish translation.
-
- 2002-07-31 Nick Clifton <nickc@redhat.com>
- * addr2line.c (process_file): Rename parameter 'filename' to
- 'file_name' in order to avoid shadowing global symbol of the
- same name.
- (main): Likewise.
-
-2002-07-30 Daniel Jacobowitz <drow@mvista.com>
-
- Merge from mainline:
- 2002-07-30 Jakub Jelinek <jakub@redhat.com>
- * readelf.c (OPTION_DEBUG_DUMP): Define.
- (options): Use it.
- (usage): Update help.
- (parse_args): Handle --debug-dump separately from -w.
- * doc/binutils.texi (readelf): Update documentation.
-
-2002-07-25 Nick Clifton <nickc@redhat.com>
-
- * po/es.po: Updated Spanish translation.
- * po/fr.po: Updated French translation.
-
-2002-07-24 Nick Clifton <nickc@redhat.com>
-
- * po/es.po: Updated Spanish translation.
-
-2002-07-23 Daniel Jacobowitz <drow@mvista.com>
-
- * po/binutils.pot: Regenerated.
-
-2002-07-23 Nick Clifton <nickc@redhat.com>
+2004-05-13 Nick Clifton <nickc@redhat.com>
* po/fr.po: Updated French translation.
-2002-07-23 Eric S. Raymond <esr@golux.thyrsus.com>
-
- * doc/binutils.texi (addr2line <man synopsis>): Correct brackets.
-
-2002-07-20 Alan Modra <amodra@bigpond.net.au>
-
- * budemang.c: Include config.h and string.h/strings.h.
-
-2002-07-16 Nick Clifton <nickc@cambridge.redhat.com>
-
- * NEWS: Add 'Changes in 2.13'.
-
-2002-07-10 Jakub Jelinek <jakub@redhat.com>
-
- * readelf.c (get_dynamic_type): Handle DT_GNU_PRELINKED,
- DT_GNU_CONFLICT* and DT_GNU_LIBLISZ*.
- (get_section_type_name): Handle SHT_GNU_LIBLIST.
- (process_dynamic_segment): Handle DT_GNU_CONFLICTSZ,
- DT_GNU_LIBLISTSZ and DT_GNU_PRELINKED.
- (process_gnu_liblist): New.
- (process_file): Call it.
-
-2002-07-03 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am (check-DEJAGNU): Revert 2002-06-25 change.
- * Makefile.in: Regenerate.
-
-2002-07-02 Alan Modra <amodra@bigpond.net.au>
-
- * budemang.c: New file, "demangle" function.
- * budemang.h: New file.
- * addr2line.c (translate_addresses): Use "demangle".
- * nm.c (print_symname): Likewise.
- * objdump.c (objdump_print_symname): Likewise.
- (dump_symbols): Likewise. Also, don't use bfd_asymbol_name macro
- here since that obfuscates.
- * rdcoff.c: Don't #include demangle.h.
- * Makefile.am (CFILES): Add budemang.c, emul_aix.c,
- emul_vanilla.c. Remove emul_$(EMULATION).c. Sort.
- (HFILES): Add budemang.h. Sort.
- (nm_new_SOURCES, objdump_SOURCES, addr2line_SOURCES): Add budemang.c.
- Run "make dep-am".
- * Makefile.in: Regenerate.
-
-2002-07-01 Matt Thomas <matt@3am-software.com>
-
- * readelf.c: Include "elf/vax.h".
- (guess_is_rela): Move EM_VAX from unknown to RELA case.
- (dump_relocations): Handle VAX relocations.
- (get_machine_flags): Handle VAX machine flags.
-
-2002-06-29 Stephane Carrez <stcarrez@nerim.fr>
-
- * readelf.c (dump_relocations): Handle 68HC11/68HC12 relocations.
-
-2002-06-26 Nick Clifton <nickc@cambridge.redhat.com>
-
- * MAINTAINERS: Remove Tom Rix from d10v and pcc maintainerships.
-
-2002-06-26 Alan Modra <amodra@bigpond.net.au>
-
- * nm.c (print_symname): When demangling, strip leading dots from
- symbol names to avoid confusing the demangler.
-
-2002-06-25 H.J. Lu <hjl@gnu.org>
-
- * Makefile.am (check-DEJAGNU): Set LC_ALL=C and export it.
- * Makefile.in: Regenerated.
-
-2002-06-21 Igor Schein <igor@txc.com>
-
- * configure.in: Quote bu_cv_have_fopen64.
- * configure: Regenerate.
-
-2002-06-21 Mitsru Chinen <chinen@jp.ibm.com>
-
- * configure.in: Check for strcoll.
- * configure: Regenerate.
- * config.in: Regenerate.
- * nm.c (main): Set locale for LC_COLLATE category.
- (non_numeric_forward): Use strcoll if available.
-
-2002-06-20 Dave Brolley <brolley@redhat.com>
-
- * MAINTAINERS: Add self as fr30 and frv maintainer.
-
-2002-06-18 H.J. Lu (hjl@gnu.org)
-
- * nm.c: Include "elf/common.h".
- (extended_symbol_info): Add elfinfo, a pointer to
- elf_symbol_type.
- (SYM_SIZE): Use elfinfo if it is not NULL.
- (get_symbol_type): New function.
- (display_archive): Set print_width for each archive member.
- (display_file): Likewise.
- (display_rel_file): Don't set print_width here.
- (print_object_filename_sysv): Handle print_width.
- (print_archive_member_sysv): Likewise.
- (print_symbols): Pass (bfd_vma) 0 to print_symbol.
- (print_symbol): Set the elfinfo field in extended_symbol_info
- for ELF.
- (print_object_filename_sysv): Fix the output format.
- (print_symbol_info_sysv): Print type and section for ELF.
-
-2002-06-18 Elias Athanasopoulos <eathan@otenet.gr>
-
- * nm.c (print_size_symbols): Remove assignment, which makes
- the symbol's size equal to its value when --size-sort is
- used.
-
-2002-06-18 Dave Brolley <brolley@redhat.com>
-
- From Catherine Moore:
- * readelf.c (elf/frv.h): #include it.
- (guess_is_rela): Support EM_CYGNUS_FRV.
- (dump_relocations): Ditto.
- (get_machine_name): Ditto.
- * Makefile.am (readelf.o): add dependency on $(INCDIR)/elf/frv.h.
-
-2002-06-18 Jakub Jelinek <jakub@redhat.com>
-
- * readelf.c (get_file_header): Only read the first section header if
- e_shoff is non-zero.
-
-2002-06-15 H.J. Lu (hjl@gnu.org)
-
- * nm.c (print_size): New variable. Initialize to 0.
- (long_options): Add 'S'/"print-size".
- (main): Handle 'S'.
- (print_symbol_info_bsd): Print size only if print_size is not
- 0.
-
- * doc/binutils.texi: Document -S/--print-size.
-
-2002-6-13 Elias Athanasopoulos <eathan@otenet.gr>
-
- * nm.c (struct extended_symbol_info): New strcuture: Add the size
- of the symbols to the information provided by the symbol_info
- structure.
- (print_symbols): Pass the symbol size to print_symbol.
- (print_size_symbols): Pass the symbol size to print_symbol.
- (print_symbol): Extra argument: The size of the symbol. Store
- this in the extended_symbol_info structure.
- (print_symbol_info): Change type of info parameter to
- extended_symbol_info. Display the size, if known.
- (print_symbol_info_posix): Likewise.
- (print_symbol_info_sysv): Likewise.
-
-2002-06-08 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: Run "make dep-am".
- * Makefile.in: Regenerate.
- * doc/Makefile.in: Regnerate.
-
- * bucomm.c: Replace CONST with const.
- * nm.c: Likewise.
- * objdump.c: Likewise.
-
-2002-06-07 H.J. Lu <hjl@gnu.org>
-
- * readelf.c (DW_CFA_GNU_args_size): Don't define.
- (DW_CFA_GNU_negative_offset_extended): Likewise.
- (DW_CFA_GNU_window_save): Likewise.
- (display_debug_frames): Handle DW_CFA_offset_extended_sf,
- DW_CFA_def_cfa_sf and DW_CFA_def_cfa_offset_sf.
-
-2002-06-07 Elias Athanasopoulos <eathan@otenet.gr>
-
- * nm.c: When computing size of symbols for an ELF target use the
- internal size field.
-
-2002-06-06 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * testsuite/binutils-all/objcopy.exp: clear xfail for
- "hppa*64*-*-hpux*".
- * testsuite/binutils-all/hppa/objdump.exp: Return if
- "*64*-*-*".
-
-2002-06-05 Alan Modra <amodra@bigpond.net.au>
-
- * objcopy.c (copy_section): Don't copy SEC_GROUP sections.
-
-2002-06-03 Elias Athanasopoulos <eathan@otenet.gr>
-
- * objdump.c: Fix formatting.
-
-2002-05-29 Ben Elliston <bje@redhat.com>
-
- * MAINTAINERS: Add self as M68k maintainer.
-
-2002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
-
- * readelf.c: Modified/Added DLX elf support.
-
-2002-05-27 Nick Clifton <nickc@cambridge.redhat.com>
-
- * arsup.c: Fix formatting.
- * debug.c (debug_record_label): Add missing colon to error
- message.
- * ieee.c (parse_ieee_ty): Fix spelling typo.
- * readelf.c (process_program_headers): Remove English assumption
- about making a plural word.
- (process_section_headers): Likewise.
- (process_relocs): Allow quotes to be translated.
- (process_unwind): Likewise,
- (process_mips_specific): Improve error message.
- (get_note_type): Fix spelling typo.
-
- * configure.in (ALL_LINGUAS): Add sv
- * po/sv.po: New file.
-
-2002-05-27 Alan Modra <amodra@bigpond.net.au>
-
- * unwind-ia64.c (unw_print_brmask): Don't use sprintf.
- (unw_print_grmask): Likewise.
- (unw_print_frmask): Likewise.
-
-2002-05-26 Kazu Hirata <kazu@cs.umass.edu>
-
- * arsup.c: Remove ARGSUSED.
- * debug.c: Likewise.
- * ieee.c: Likewise.
- * nlmconv.c: Likewise.
- * prdbg.c: Likewise.
- * stabs.c: Likewise.
- * wrstabs.c: Likewise.
-
-2002-05-25 Alan Modra <amodra@bigpond.net.au>
-
- * arlex.l: Use #include "" instead of <> for local header files.
- * coffdump.c: Likewise.
- * coffgrok.c: Likewise.
- * nlmconv.c: Likewise.
- * nlmheader.y: Likewise.
- * srconv.c: Likewise.
- * strings.c: Likewise.
- * sysdump.c: Likewise.
- * unwind-ia64.h: Likewise.
- * windres.h: Likewise.
- * winduni.h: Likewise.
-
-2002-05-24 Tom Rix <trix@redhat.com>
-
- * MAINTAINERS: Add self as the d10v maintainer.
-
-2002-05-24 TAMURA Kent <kent@netbsd.org>
-
- * configure.in: Builds dlltool for i386-netbsdpe.
- * configure: Regenerate.
-
-2002-05-23 Kazu Hirata <kazu@cs.umass.edu>
-
- * size.c: Fix formatting.
- * srconv.c: Likewise.
- * stabs.c: Likewise.
- * sysdump.c: Likewise.
- * unwind-ia64.c: Likewise.
- * wrstabs.c: Likewise.
-
-2002-05-23 Jakub Jelinek <jakub@redhat.com>
-
- * readelf.c (get_segment_type): Add PT_TLS.
- (get_elf_section_flags): Add SHF_TLS.
- (get_dynamic_flags): Optimize. Add DF_STATIC_TLS.
- (process_dynamic_segment): Use puts instead of printf.
- (get_symbol_type): Support STT_TLS.
- * objdump.c (dump_section_header): Remove SEC_CONSTRUCTOR_TEXT,
- SEC_CONSTRUCTOR_DATA, SEC_CONSTRUCTOR_BSS.
- Add SEC_THREAD_LOCAL.
-
-2002-05-23 Kazu Hirata <kazu@cs.umass.edu>
-
- * rdcoff.c: Fix formatting.
- * rddbg.c: Likewise.
- * readelf.c: Likewise.
- * rename.c: Likewise.
- * resbin.c: Likewise.
- * resrc.c: Likewise.
- * resres.c: Likewise.
-
-2002-05-21 Kazu Hirata <kazu@cs.umass.edu>
-
- * filemode.c: Fix formatting.
- * ieee.c: Likewise.
- * is-ranlib.c: Likewise.
- * is-strip.c: Likewise.
- * maybe-ranlib.c: Likewise.
- * maybe-strip.c: Likewise.
- * nlmconv.c: Likewise.
- * nm.c: Likewise.
- * not-ranlib.c: Likewise.
- * not-strip.c: Likewise.
- * objcopy.c: Likewise.
- * objdump.c: Likewise.
-
-2002-05-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * objdump.c (dump_headers): Fix output formatting for ELF32
- architectures in a BFD64 enabled toolchain.
-
-2002-05-20 Kazu Hirata <kazu@cs.umass.edu>
-
- * debug.c: Fix formatting.
- * debug.h: Likewise.
- * dlltool.c: Likewise.
- * dllwrap.c: Likewise.
- * emul_aix.c: Likewise.
- * emul_vanilla.c: Likewise.
-
-2002-05-19 Kazu Hirata <kazu@cs.umass.edu>
-
- * addr2line.c: Fix formatting.
- * ar.c: Likewise.
- * arsup.c: Likewise.
- * arsup.h: Likewise.
- * binemul.c: Likewise.
- * binemul.h: Likewise.
- * bucomm.c: Likewise.
- * coffdump.c: Likewise.
- * coffgrok.c: Likewise.
- * coffgrok.h: Likewise.
-
-2002-05-16 Marek Michalkiewicz <marekm@amelek.gda.pl>
-
- * MAINTAINERS: Add myself as the second AVR port maintainer.
-
-2002-05-16 Stephane Carrez <stcarrez@nerim.fr>
-
- * MAINTAINERS: Update my email address.
-
-2002-05-09 Nick Clifton <nickc@cambridge.redhat.com>
-
- * MAINTAINERS: Add Jason Thorpe as VAX maintainer.
-
-2002-05-09 Alan Modra <amodra@bigpond.net.au>
-
- * configure.in: Replace `*pe' with `pe' throughout.
- * configure: Regenerate.
-
-2002-05-07 Federico G. Schwindt <fgsch@olimpo.com.br>
-
- * Makefile.am: Honour DESTDIR.
- * Makefile.in: Regenerate.
-
-2002-05-06 Alan Modra <amodra@bigpond.net.au>
-
- * dlltool.c (process_def_file): Add missing prototype.
- (new_directive, assemble_file, main): Likewise.
- (process_def_file, new_directive): Make static.
- (inform): Rewrite using VA_FIXEDARG.
- * dllwrap.c (mybasename): Add missing prototype.
- (strhash, main): Likewise.
- (inform): Rewrite using VA_FIXEDARG.
- (warn): Likewise.
- (cleanup_and_exit): Use old style function definition.
- (strhash): Likewise.
- * windres.c (define_resource): Use one memset to clear all of
- struct res_resource.
-
- * rcparse.y: Remove newcmd rule. Move rcparse_discard_strings
- call to rules that need no lookahead. Check for no lookahead.
-
-2002-05-06 Borut Razem <borut.razem@siol.net>
-
- * rclex.l (get_string): Correct "strings" list handling.
- * resrc.c (read_rc_file): Discard strings.
-
-2002-05-04 Alan Modra <amodra@bigpond.net.au>
-
- * ar.c (replace_members): Remove unused var. Formatting fix.
- * binemul.c (ar_emul_default_parse_arg): Add ATTRIBUTE_UNUSED.
-
- * MAINTAINERS: Sort port maintainers by CPU.
-
-2002-05-04 Bob Byrnes <byrnes@curl.com>
-
- * size.c (display_archive): Add last_arfile and code to close archives.
-
-2002-05-01 Alan Modra <amodra@bigpond.net.au>
-
- * nm.c (print_symbol): Check returned filename from
- bfd_find_nearest_line is non-NULL.
-
-2002-04-25 Elena Zannoni <ezannoni@redhat.com>
-
- * readelf.c (get_AT_name): Handle DW_AT_GNU_vector.
-
-2002-04-24 Christian Groessler <chris@groessler.org>
-
- * MAINTAINERS: Changed my email address.
-
-2002-04-17 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * arparse.y: Fix syntax warning.
-
-2002-04-16 Nick Clifton <nickc@cambridge.redhat.com>
-
- * readelf.c (fetch_location_list): Remove unused function.
-
- * readelf.c (process_corefile_note_segment): Catch corrupt notes
- and display a warning message, then exit the loop.
-
- * rcparse.y: Set MEMFLAG_DISCARDABLE by default.
-
-2002-04-15 Nick Clifton <nickc@cambridge.redhat.com>
-
- * resrc.c (write_rc_dialog): If charset is non-default value
- display all of the DIALOGEX parameters.
-
-2002-04-15 Eric Kohl <ekohl@rz-online.de>
-
- * rcparse.y: Allow two to five parameter in FONT statement of
- DIALOGEX resources.
- * resbin.c (bin_to_res_dialog): Fixed read/write code for dialogex
- resource data.
- (res_to_bin_dialog): Likewise.
- * windres.h: Added misssing charset variable to dialog_ex
- structure.
-
-2002-04-10 Nick Clifton <nickc@cambridge.redhat.com>
-
- * rcparse.y: Set MEMFLAG_PURE by default.
-
-2002-04-09 Bernd Herd <info@herdsoft.com>
-
- * rcparse.y: CLASS definitions in DIALOG resources
- are quoted.
- Fix typo in BEDIT warning.
- Don't add default dialog style when explicit style specified.
- Add WS_CAPTION dialog style if CAPTION is specified.
-
- * rclex.l (handle_quotes): "\xhex" encoding in strings corrected.
- (handle_quotes) "\a" escape (used for right justified key
- definitions in menus) is encodes as binary 8.
-
- * resrc.c (write_rc_dialog): Print style even if it is 0.
- (write_rc_directory): Fix overlooked sublang shift bug.
- (bin_to_res_dialog): Don't print empty dialog caption.
-
- * resbin.c (bin_to_res_dialog): Use signature to identify
- DIALOGEX.
-
- * windres.c (main): Set default LANGUAGE to english/us.
-
-2002-04-09 Gunnar Degnbol <degnbol@danbbs.dk>
-
- * resrc.c: print CLASS names in quotes
-
-2002-04-09 J"orn Rennecke <joern.rennecke@superh.com>
-
- * MAINTAINERS: Update my email address.
-
-2002-04-04 Alan Modra <amodra@bigpond.net.au>
-
- * dep-in.sed: Cope with absolute paths.
- * Makefile.am (dep.sed): Subst TOPDIR.
- Run "make dep-am".
- * Makefile.in: Regenerate.
-
-2002-03-27 Peter Targett <peter.targett@arc.com>
-
- * MAINTAINERS: Update my email address.
-
-2002-03-21 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: Run "make dep-am".
- * Makefile.in: Regenerate.
- * doc/Makefile.in: Regenerate.
- * po/POTFILES.in: Regenerate.
- * aclocal.m4: Regenerate.
- * config.in: Regenerate.
- * configure: Regenerate.
-
-2002-03-20 Daniel Berlin <dan@dberlin.org>
-
- * readelf.c: Add support for displaying dwarf2 location lists.
- (do_debug_loc, debug_loc_section, debug_loc_size): New.
- (parse_args): Use 'O' as shorthand for displaying location list
- section.
- (process_section_headers): Handle debug_loc as well.
- (load_debug_loc): New.
- (free_debug_loc): New.
- (fetch_location_list): New.
- (display_debug_loc): New.
- (display_debug_info): Call load_debug_loc and free_debug_loc.
- (debug_displays): We can display .debug_loc now, too.
- (usage): Update usage string.
- (read_and_display_attr_value): Note location lists, but don't
- display them inline.
-
-2002-03-18 Tom Rix <trix@redhat.com>
-
- * Makefile.am: Add binutils emulation support.
- * configure.in: Same.
- * configure.tgt: New file. Same.
- * ar.c (main): Use ar_emul_parse_arg.
- (usage): Use ar_emul_usage.
- (replace_members): Use ar_emul_replace, ar_emul_append.
- * binemul.c: New file. Define the binutils emulation
- layer. Define default methods.
- * binemul.h: New file. Binutils emulation layer header file.
- * emul_aix.c: New file. AIX binutils emulation.
- * emul_vanilla.c: New file. Default binutils emulation.
- * Makefile.in: Regenerate.
- * configure: Same.
-
-2002-03-18 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/fr.po: Updated version.
-
-2002-03-13 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/fr.po: Updated version.
-
-2002-03-07 Daniel Jacobowitz <drow@mvista.com>
-
- * README: Update some version numbers.
-
-2002-03-07 Daniel Jacobowitz <drow@mvista.com>
-
- * doc/binutils.texi (Target Selection): Fix LD crossreferences.
- (Architecture Selection): Likewise.
-
-2002-03-01 Dmitry Timoshkov <dmitry@baikal.ru>
-
- * dlltool.c (gen_exp_file): Take into account --kill-at (-k) while
- generating .exp file.
-
-2002-02-21 Nick Clifton <nickc@cambridge.redhat.com>
-
- * readelf.c (dump_relocations): Fix typo.
-
-2002-02-20 Nick Clifton <nickc@cambridge.redhat.com>
-
- * NEWS: Mark 2.12 branch.
-
-2002-02-18 Timothy Daly <remote_bob@yahoo.com>
-
- * readelf.c (dump_relocations): Display 2nd and 3rd reloc
- types for 64-bit MIPS. Narrow some fields for 80-char
- output.
- (dump_relocations): Change spelling from 'unrecognised'
- to 'unrecognized'.
- (decode_ARM_machine_flags): Likewise.
- (parse_args): Likewise.
- (read_and_display_attr_value): Likewise.
- (display_debug_section): Likewise.
-
-2002-02-15 Hans-Peter Nilsson <hp@bitrange.com>
-
- * NEWS: Mention support for MMIX.
-
-2002-02-13 Matt Fredette <fredette@netbsd.org>
-
- * readelf.c (get_machine_flags): Recognize EF_M68000.
-
-2002-02-12 Alexandre Oliva <aoliva@redhat.com>
-
- * MAINTAINERS: Added self as MN10300 co-maintainer.
-
-2002-02-12 Alan Modra <amodra@bigpond.net.au>
-
- * readelf.c (get_ppc64_dynamic_type): Handle DT_PPC64_OPD and
- DT_PPC64_OPDSZ.
-
-2002-02-11 Daniel Jacobowitz <drow@mvista.com>
-
- * MAINTAINERS: List myself as branch maintainer.
-
-2002-02-11 Alan Modra <amodra@bigpond.net.au>
-
- * configure: Regenerate.
- * objcopy.c: Update copyright date.
- * doc/Makefile.in: Regenerate.
-
-2002-02-10 Daniel Jacobowitz <drow@mvista.com>
-
- * nlmconv.c: Back out localtime PARAMS change.
-
-2002-02-11 Alan Modra <amodra@bigpond.net.au>
-
- * objcopy.c (MKDIR): Define.
- (copy_archive): Make name_list.name const. Use MKDIR.
- Handle duplicate files in archives by making more temp dirs.
-
-2002-02-10 Daniel Jacobowitz <drow@mvista.com>
-
- * coffdump.c: Include "getopt.h" after "bucomm.h"
- so that macros are defined correctly.
- * nlmconv.c: Add PARAMS ((const time_t *)) to localtime
- prototype. Prototype main.
- * nlmheader.y: Add PARAMS ((int)) to strerror prototype.
-
-2002-02-06 Alexandre Oliva <aoliva@redhat.com>
-
- * MAINTAINERS: Added self as SH co-maintainer.
-
-2002-02-05 Nick Clifton <nickc@redhat.com>
+2004-04-09 Daniel Jacobowitz <drow@mvista.com>
- * po/tr.po: Updated translation.
-
-2002-02-01 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: Run "make dep-am"
- * Makefile.in: Regenerate.
-
-2002-01-29 Daniel Jacobowitz <drow@mvista.com>
-
- * nm.c (print_value): Mark abfd unused.
-
-2002-01-29 Daniel Jacobowitz <drow@mvista.com>
-
- * unwind-ia64.c (unw_decoder): Change second argument
- to unsigned int, to match function prototypes.
-
-2002-01-29 Daniel Jacobowitz <drow@mvista.com>
-
- * objdump.c: Include "getopt.h" after "bucomm.h" so that
- __GNU_LIBRARY__ will be defined.
- * size.c: Likewise.
-
-2002-01-27 Daniel Jacobowitz <drow@mvista.com>
-
- * configure: Regenerated.
-
-2002-01-26 Hans-Peter Nilsson <hp@bitrange.com>
-
- * doc/Makefile.am (install): Depend on install-info.
- * doc/Makefile.in: Regenerate.
-
-2002-01-25 Jason R. Thorpe <thorpej@wasabisystems.com>
-
- * objcopy.c (strip_usage): Document -d as an alias
- --strip-debug.
-
- * size.c (usage): Document [-t | --totals] options.
- (long_options): Add --totals option.
- (main): If the [-t | --totals] option is specified and
- the output format is Berkeley-style, print the total
- text, data, and bss sizes of all objects listed.
- (print_berkeley_format): If the [-t | --totals] option
- is specified, track the total text, data, and bss
- sizes.
- * doc/binutils.texi (size): Document [-t | --totals] options.
- (strip): Document -d as an alias for --strip-debug.
- * NEWS: Mention new feature of size.
-
-2002-01-25 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/fr.po: Updated version.
- * po/es.po: Updated version.
-
-2002-01-23 Nick Clifton <nickc@cambridge.redhat.com>
-
- * addr2line.c (usage): Update text to provide verbose
- description of the command line options.
- * ar.c (usage): Update text to provide verbose
- description of the command line options.
- (main): Accept -h and -H when running as ranlib.
- * coffdump.c (show_usage): Update text to provide verbose
- description of the command line options.
- * dlltool.c (main): Accept -H as an alias for --help.
- * nlmconv.c (show_usage): Update text to provide verbose
- description of the command line options.
- * nm.c (usage): Replace OPTIONS with option(s).
- (main): Accept -H as an alias for --help.
- * objcopy.c (strip_main): Accept -H as an alias for --help.
- * objdump.c (main): Accept -v as an alias for --verbose.
- * readelf.c (usage): Adjust format to match style used in
- other binutils.
- * size.c (usage): Update text to provide verbose description
- of the command line options.
- (main): Accept -v, -h and -H as command line options.
- * srconv.c (show_usage): Update text to provide verbose
- description of the command line options.
- * strings.c (main): Accept -H and -v as command line options.
- (usage): Update text to provide verbose description of the
- command line options.
- * sysdump.c (show_usage): Update text to provide verbose
- description of the command line options.
- * windres.c (usage): Adjust format to match style used in
- other binutils.
-
- * coffdump.c: Fix formatting.
- * nlmconv.c: Fix formatting.
- * srconv.c: Fix formatting.
- * sysdump.c: Fix formatting.
-
-2002-01-22 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: Run "make dep-am".
- * Makefile.in: Regenerate.
-
-2002-01-18 Andreas Jaeger <aj@suse.de>
-
- * version.c (print_version): Update year.
-
-2002-01-17 Alan Modra <amodra@bigpond.net.au>
-
- * readelf.c (get_machine_name): Handle EM_PPC64.
- (guess_is_rela): Here too.
-
-2002-01-17 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/binutils.pot: Regenerate.
- * po/fr.po: Regenerate.
- * po/tr.po: Regenerate.
-
-2002-01-16 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/tr.po: Import new version.
-
-2002-01-16 Alan Modra <amodra@bigpond.net.au>
-
- * readelf.c (get_ppc64_dynamic_type): New.
- (get_dynamic_type): Call it.
-
-2002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
-
- * objcopy.c (copy_usage): Use "options" instead of "switches".
- (strip_usage): Use "options" instead of "switches".
- * doc/binutils.texi (dlltool): Refer to "options" instead of
- "switches".
-
-2002-01-14 Richard Earnshaw <rearnsha@arm.com>
-
- * MAINTAINERS: Add self as co-maintainer for the ARM code.
-
-2001-12-18 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/es.po: Import from translation project.
- * configure.in (ALL_LINGUAS): Add es.
- * configure: Regenerate.
-
-2002-01-09 Jason Thorpe <thorpej@wasabisystems.com>
-
- * readelf.c (get_netbsd_elfcore_note_type): Use
- NT_NETBSDCORE_PROCINFO and NT_NETBSDCORE_FIRSTMACH.
-
-2002-01-09 Jason Thorpe <thorpej@wasabisystems.com>
-
- * readelf.c: Update copyright years.
- (get_note_type): Return a const char *.
- (get_netbsd_elfcore_note_type): New function.
- (process_note): Use get_netbsd_elfcore_note_type to get
- the note type string for NetBSD ELF core files.
-
-2002-01-06 Steve Ellcey <sje@cup.hp.com>
-
- * readelf.c (get_ia64_segment_type): Add support for macros.
- (get_segment_type): Add support for IA64 specific macros.
-
-2001-12-20 Julian v. Bock <julian@wongr.net>
-
- * readelf.c (print_symbol): New function: Print a formatted symbol
- name. If --wide is specified do not truncate it.
- (dump_relocations): Use print_symbol() to print symbol names.
- (process_symbol_table): Likewise.
- (process_syminfo): Likewise.
- (process_mips_specific): Likewise.
- (usage): Document new feature of --wide switch.
- * doc/binutils.texi (objdump): Document additional behaviour of
- --wide.
-
-2001-12-18 Michael Snyder <msnyder@redhat.com>
-
- * objcopy.c (copy_file): Accept corefiles (format bfd_core).
- (copy_object): Don't set the start address or flags of a core file.
- (copy_section): Don't relocate a core file. Don't copy contents
- if the input section has the contents flag set, but the output
- section does not (which happens with the fake 'note' pseudo-
- sections that BFD creates for corefiles).
-
-2001-12-18 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * readelf.c (get_machine_flags): Recognize header flags for ABI and
- ASE extensions. More robust code for ISA checking. Ignore empty fields
- in header flags for GNU extensions.
-
-2001-12-18 Alan Modra <amodra@bigpond.net.au>
-
- * objcopy.c (copy_archive): Set output bfd format outside the loop.
-
-2001-12-18 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/ja.po: Import from translation project.
- * configure.in (ALL_LINGUAS): Add ja.
- * configure: Regenerate.
-
-2001-12-18 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * addr2line.c (main): Protoype.
- * ar.c (main): Protoype.
- * nm.c (main): Protoype.
- * objcopy.c (main): Protoype.
- * objdump.c (main): Protoype.
- * size.c (main): Protoype.
- * strings.c (main): Protoype.
-
-2001-12-17 Alan Modra <amodra@bigpond.net.au>
-
- * readelf.c (symtab_shndx_hdr): New global.
- (SECTION_HEADER_INDEX): Define.
- (SECTION_HEADER_NUM): Define.
- (SECTION_HEADER): Define.
- (GET_ELF_SYMBOLS): Pass two params rather than three.
- (get_32bit_elf_symbols): Take file and section args. Read and
- use SHT_SYMTAB_SHNDX.
- (get_64bit_elf_symbols): Likewise.
- (dump_relocations): Use SECTION_HEADER to index "section_headers".
- (process_section_headers): Likewise. Use SECTION_HEADER_NUM too.
- Remember symtab_shdx_hdr.
- (process_program_headers): Scan from index 1 for segment map.
- (slurp_ia64_unwind_table): Use SECTION_HEADER to index
- "section_headers".
- (process_relocs): Likewise. Also adjust call to GET_ELF_SYMBOLS.
- (process_unwind): Likewise.
- (process_version_sections): Likewise.
- (process_symbol_table): Likewise.
- (display_debug_info): Likewise.
- (process_dynamic_segment): Fake up a symtab section for changed
- GET_ELF_SYMBOLS.
- (get_symbol_index_type): Check SHN_LOOS before SHN_LORESERVE.
- (process_program_headers): Kill signed/unsigned warning.
- (load_debug_str): Likewise.
- (display_debug_info): Likewise.
-
-2001-12-13 Jakub Jelinek <jakub@redhat.com>
-
- * readelf.c (get_segment_type): Support PT_GNU_EH_FRAME.
-
-2001-12-11 Alan Modra <amodra@bigpond.net.au>
-
- * readelf.c (process_file_header): Print extended e_shnum and
- e_shdtrndx values. Set elf_header values for same.
- (get_32bit_section_headers): Add "num" arg to read "num" headers.
- (get_64bit_section_headers): Likewise.
- (process_section_headers): Update calls.
- (get_file_header): Call get_32bit_section_headers or 64bit variant.
-
-2001-12-10 Jakub Jelinek <jakub@redhat.com>
-
- * objcopy.c (setup_section): Copy entsize.
-
-2001-12-07 Geoffrey Keating <geoffk@redhat.com>
-
- * readelf.c (guess_is_rela): Add support for stormy16.
- (dump_relocations): Likewise.
- (get_machine_name): Likewise.
-
-2001-12-05 Nick Clifton <nickc@cambridge.redhat.com>
-
- * dllwrap.c (main) Replace multiple strings describing a
- single error with a single, newline escaped sentence to permit
- better translation into foreign languages.
-
- * readelf.c (get_elf_class): Remove internalionalisation of ELF
- class names.
-
-2001-12-04 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * strings.c (get_char): Initialize value.
-
-2001-12-04 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * arlex.l: Silence compile warnings.
- * arsup.h: Likewise. Fix formatting.
-
-2001-12-04 Jakub Jelinek <jakub@redhat.com>
-
- * strings.c: Include config.h before bfd.h.
- (file_off): New type.
- (file_open): Define.
- (print_strings): Use file_off instead of file_ptr. Print addresses
- which don't fit into long correctly.
- (get_char): Use file_off instead of file_ptr. Use getc_unlocked if
- available.
- (strings_file): Use file_off instead of file_ptr. Use file_open.
- * configure.in: Check for getc_unlocked.
- Check for fopen64 and whether _LARGEFILE64_SOURCE needs to
- be defined for it.
- * configure: Rebuilt.
- * config.h.in: Rebuilt.
-
-2001-11-29 H.J. Lu <hjl@gnu.org>
-
- * bucomm.c (make_tempname): Revert the changes made on
- 2001-11-14 and 2001-11-12. They won't work with directories.
-
-2001-11-23 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * binutils/Makefile.am (check-DEJAGNU): Pass CC_FOR_TARGET and
- CFLAGS_FOR_TARGET to runtest in environment.
- * Makefile.in: Rebuild.
- * doc/Makefile.in: Rebuild.
-
-2001-11-28 Mike Stump <mrs@wrs.com>
-
- * objcopy.c (setup_section): Preserve SEC_RELOC when
- --set-section-flags is used.
-
-2001-11-19 Nick Clifton <nickc@cambridge.redhat.com>
-
- * readelf.c (do_debug_str): New variable.
- (display_debug_str): New function: Display the contents of a
- .debug_str section.
- (load_debug_str): New function: Load in the contents of a
- .debug_str section.
- (free_debug_str): New function: Free the memory used by
- load_debug_str().
- (fetch_indirect_string): Retrieve a string from the .debug_str
- section.
- (usage): Add -ws.
- (parse_args): Accept -ws.
- (process_section_headers): Allow the display of the .debug_str
+ Merge from mainline:
+ 2004-04-07 Benjamin Monate <benjamin.monate@cea.fr>
+ PR 86
+ * arsup.c (ar_save): Use smart_rename.
+
+ 2004-04-01 Dean Luick <luick@cray.com>
+ * readelf.c (display_debug_pubnames): Align offset and data
+ columns.
+ (read_and_display_attr_value): Add missing break;
+ (debug_displays): Enable the display of the .debug_pubtypes
section.
- (read_and_display_attr_value): Use fetch_indirect_string. Show
- offset into .debug_str section.
- (display_debug_info): Use load_debug_str and free_debug_str.
- (debug_displays): Add .debug_str.
- * doc/binutils.texi: Document -ws.
-
-2001-11-19 Andreas Jaeger <aj@suse.de>
-
- * testsuite/binutils-all/objdump.exp: Add x86-64.
-
-2001-11-15 Andreas Schwab <schwab@suse.de>
-
- * readelf.c: Fix warnings without terminating newline.
-
-2001-11-15 Alan Modra <amodra@bigpond.net.au>
-
- * doc/binutils.texi (objdump): Document ppc -M options.
-
-2001-11-14 Andreas Jaeger <aj@suse.de>
-
- * doc/binutils.texi (objdump): Fix description to use x86-64.
-
-2001-11-14 Nick Clifton <nickc@cambridge.redhat.com>
-
- * bucomm.c (make_tempname): Use mkstemps instead of mkstemp, since
- not all systems provide mkstemp.
-
-2001-11-14 Alan Modra <amodra@bigpond.net.au>
-
- * doc/binutils.texi (objdump): Document x86 -M options.
-
-2001-11-13 Keith Walker <keith.walker@arm.com>
-
- * readelf.c (read_and_display_attr_value): New function to
- handle DW_FORM_indirect.
- (read_and_display_attr): Use it.
-
-2001-11-13 Geoffrey Keating <geoffk@redhat.com>
-
- * readelf.c (display_debug_lines): Deal with unknown standard
- opcodes. Handle DW_LNS_set_prologue_end, DW_LNS_set_epilogue_begin,
- DW_LNS_set_isa.
-
-2001-11-13 Timothy Wall <twall@alum.mit.edu>
-
- * MAINTAINERS: Add self as tic54x maintainer. This target
- includes the IBM C54XDSP clone.
-
-2001-11-12 * Steven J. Hill <sjhill@realitydiluted.com>
-
- * bucomm.c (make_tempname): Use mkstemp in place of mktemp.
-
-2001-11-09 Jeffrey A Law (law@cygnus.com)
-
- * unwind-ia64.c (unw_print_brmask): Fix ISO C portability glitch.
- (unw_print_grmask, unw_print_frmask, unw_print_abreg): Likewise.
- (unw_print_xyreg, unw_decode_x1, unw_decode_x2): Likewise.
- (unw_decode_x3, unw_decode_r1, unw_decode_r2): Likewise.
- (unw_decode_r3, unw_decode_p1, unw_decode_p2_p5): Likewise.
- (unw_decode_p6, unw_decode_p7_p10, unw_decode_b1): Likewise.
- (unw_decode_b2, unw_decode_b3_b4): Likewise.
-
- * readelf.c (get_elf_class): Fix ISO portability glitch.
- (get_data_encoding, get_osabi_name, request_dump): Likewise.
-
-2001-11-07 Jakub Jelinek <jakub@redhat.com>
-
- * readelf.c (debug_str, debug_str_size): New.
- (display_debug_abbrev): If no abbrevs were read, skip the CU.
- Call free_abbrevs.
- (read_and_display_addr): Handle DW_FORM_strp.
- (display_debug_info): Read .debug_str section if present,
- so that DW_FORM_strp can be handled.
- Fix test for non-existant .debug_abbrev section.
-
-2001-11-05 Jakub Jelinek <jakub@redhat.com>
-
- * arlex.l: Accept `\' in filenames. Patch by <earl_chew@agilent.com>.
-
- * arsup.c (ar_open): Prepend tmp- to basename, not whole path.
-
-2001-11-05 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * MAINTAINERS: Add self as s390/s390x maintainer.
-
-2001-11-02 Tom Rix <trix@bluey.cygnus.com>
-
- * MAINTAINERS: Add self as PPC XCOFF maintainer.
-
-2001-11-02 Nick Clifton <nickc@cambridge.redhat.com>
-
- * configure.in (ALL_LINGUAS): Add "fr" and "tr".
- * configure: Regernate.
- * po/fr.po: New file.
- * po/tr.po: New file.
-
-2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
-
- * MAINTAINERS: Add self as MMIX port maintainer.
- * readelf.c: Include elf/mmix.h.
- (guess_is_rela): MMIX is RELA.
- (dump_relocations): Handle MMIX relocations.
- * Makefile.am: Regenerate dependencies.
- * Makefile.in: Regenerate.
-
-2001-10-13 Nick Clifton <nickc@cambridge.redhat.com>
-
- * readelf.c (parse_args): Handle multiple options to the -w
- switch.
-
-2001-10-12 Jakub Jelinek <jakub@redhat.com>
-
- * readelf.c (get_section_type_name): Don't print SHT_ prefix for
- LOPROC, LOOS and LOUSER.
-
-2001-10-11 J"orn Rennecke <amylaar@onetel.net.uk>
-
- * MAINTAINERS: Update my email address.
-
-2001-10-03 Alan Modra <amodra@bigpond.net.au>
-
- * doc/Makefile.in: Regenerate.
- * configure: Regenerate.
-
-2001-10-02 Nick Clifton <nickc@cambridge.redhat.com>
-
- * readelf.c (display_debug_line, display_debug_pubnames,
- display_debug_info, display_debug_frames): Detect and warn
- about 64-bit format entries.
- (display_debug_aranges): Reword 64-bit warning.
- (debug_displays): Add .debug_pubtypes as a known, but not yet
- supported, debug section.
-
-2001-10-02 Alan Modra <amodra@bigpond.net.au>
-
- * coffdump.c (PROGRAM_VERSION): Delete.
- (main <'V'>): Call print_version.
- * srconv.c: Likewise.
- * sysdump.c: Likewise.
- * version.c (program_version): Remove.
- (print_version): Use BFD_VERSION_STRING. Just print the current
- year in copyright message.
- * addr2line.c (program_version): Remove unused declaration.
- * objdump.c (display_target_tables): Use BFD_VERSION_STRING in
- place of BFD_VERSION.
- * Makefile.am (Makefile): Depend on bfd/configure.in.
- (cplus-dem.o): Depend on Makefile.
- Run "make dep-am".
- * Makefile.in: Regenerate.
-
-2001-10-01 Nick Clifton <nickc@cambridge.redhat.com>
-
- * readelf.c (display_debug_aranges): Detect and warn about DWARF64
- format .debug_arange sections.
- (main): Add missing prototype.
-
-2001-09-30 Hans-Peter Nilsson <hp@bitrange.com>
-
- * Makefile.am: Update dependencies with "make dep-am".
- * Makefile.in: Regenerate.
-
-2001-09-28 Richard Henderson <rth@redhat.com>
-
- * objdump.c (dump_section_header): Dump SEC_ARCH_BIT_0.
-
-2001-09-26 Alan Modra <amodra@bigpond.net.au>
-
- * bucomm.c (fatal): Define using VPARAMS, VA_OPEN, VA_FIXEDARG,
- VA_CLOSE.
- (non_fatal): Likewise.
- * objdump.c (objdump_sprintf): Likewise.
- * readelf.c (error): Likewise.
- (warn): Likewise.
-
-2001-09-25 Jakub Jelinek <jakub@redhat.com>
-
- * readelf.c (do_wide): New.
- (options): Add --wide.
- (usage, parse_args): Likewise.
- (process_program_headers): Put each segment on a single line if
- --wide is given.
- (process_section_headers): Put each section on a single line if
- --wide is given.
- * doc/binutils.texi: Document it.
- * NEWS: Likewise.
-
-2001-09-25 Alan Modra <amodra@bigpond.net.au>
-
- * readelf.c (print_vma): Print 8 digits of low hex value.
-
-2001-09-24 Andreas Jaeger <aj@suse.de>
-
- * nlmconv.c: Fix warnings about unused attributes and function
- prototypes.
-
- * strings.c: Add prototype for get_char.
-
-2000-09-19 H.J. Lu <hjl@gnu.org>
-
- * doc/Makefile.am ($(DEMANGLER_NAME).1): Try cxxfilt.man and
- $(srcdir)/cxxfilt.man.
- * doc/Makefile.in: Rebuild.
-
-2001-09-19 Alan Modra <amodra@bigpond.net.au>
-
- * objcopy.c (copy_main): Correct rename-section string parsing.
- Consolidate new_name parsing, and error messages.
-
-2001-09-18 Bruno Haible <haible@clisp.cons.org>
-
- * addr2line.c: Don't include <ctype.h>.
- (main): For gettext, also set the LC_CTYPE locate facet.
- * ar.c (main): Likewise.
- * coffdump.c (main): Likewise.
- * dlltool.c: Include "safe-ctype.h" instead of <ctype.h>.
- (main): For gettext, also set the LC_CTYPE locate facet.
- Use ISALNUM instead of isalpha/isdigit.
- * dllwrap.c: Don't include <ctype.h>.
- (main): For gettext, also set the LC_CTYPE locate facet.
- * nlmconv.c: Include "safe-ctype.h" instead of <ctype.h>.
- (main): For gettext, also set the LC_CTYPE locate facet.
- Use TOUPPER instead of islower/toupper.
- * nlmheader.y: Include "safe-ctype.h" instead of <ctype.h>.
- (yylex): Use ISSPACE/ISALNUM instead of isspace/isalnum.
- Use TOUPPER instead of islower/toupper.
- * nm.c (main): For gettext, also set the LC_CTYPE locate facet.
- * objcopy.c (main): Likewise.
- * objdump.c: Include "safe-ctype.h" instead of <ctype.h>.
- (disassemble_bytes): Use ISPRINT instead of isprint.
- (dump_section_stabs): Use ISDIGIT instead of isdigit.
- (dump_data): Use ISPRINT instead of isprint.
- (main): For gettext, also set the LC_CTYPE locate facet.
- * rclex.l: Include "safe-ctype.h" instead of <ctype.h>.
- (cpp_line, handle_quotes): Use ISSPACE instead of isspace.
- * rcparse.y: Include "safe-ctype.h" instead of <ctype.h>.
- Use TOUPPER instead of islower/toupper.
- * readelf.c (main): For gettext, also set the LC_CTYPE locate facet.
- * resrc.c: Include "safe-ctype.h" instead of <ctype.h>.
- (write_rc_accelerators): Use ISPRINT instead of isprint.
- (write_rc_rcdata): Likewise.
- * size.c (main): For gettext, also set the LC_CTYPE locate facet.
- * srconv.c (main): Likewise.
- * stabs.c: Include "safe-ctype.h" instead of <ctype.h>.
- (parse_number): Use ISDIGIT/ISUPPER/ISLOWER instead of
- isdigit/isupper/islower.
- (parse_stab_string, parse_stab_type, parse_stab_argtypes,
- parse_stab_array_type, stab_demangle_count, stab_demangle_get_count,
- stab_demangle_prefix, stab_demangle_qualified,
- stab_demangle_template, stab_demangle_type,
- stab_demangle_fund_type): Use ISDIGIT instead of isdigit.
- * strings.c: Include "safe-ctype.h" instead of <ctype.h>.
- (isgraphic): Use ISPRINT instead of isascii/isprint.
- (main): Remove HAVE_LC_MESSAGES dependency.
- * sysdump.c: Include "safe-ctype.h" instead of <ctype.h>.
- (pbarray): Use ISPRINT instead of isprint.
- (main): For gettext, also set the LC_CTYPE locate facet.
- * windres.c: Include "safe-ctype.h" instead of <ctype.h>.
- (format_from_filename): Use ISPRINT instead of isprint.
- (main): For gettext, also set the LC_CTYPE locate facet.
- * winduni.c: Include "safe-ctype.h" instead of <ctype.h>.
- (unicode_print): Use ISPRINT instead of isprint.
- * wrstabs.c: Include "safe-ctype.h" instead of <ctype.h>.
- (stab_variable): Use ISDIGIT instead of isdigit.
-
-2001-09-18 Alan Modra <amodra@bigpond.net.au>
-
- * ar.c (print_contents): Cast args of bfd_seek to the right types.
- Replace bfd_read call with call to bfd_bread.
- (extract_file): Likewise.
-
- * objdump.c (dump_section_header): Cast section->filepos to
- unsigned long to suit printf format string.
- * readelf.c (process_section_headers): Similarly for sh_offset.
- (process_unwind): Likewise.
-
-2001-09-14 Nick Clifton <nickc@cambridge.redhat.com>
-
- * strings.c (encoding, encoding_bytes): New variables.
- (long_options): Add --encoding.
- (main): Accept -e and --encoding.
- (get_char): New function. Read a, possibly wide, character from
- the input stream.
- (print_strings): Use get_char().
- (usage): Document new command line option.
- * doc/binutils.texi: Document new command line option.
- * NEWS: Announce new command line option.
-
-2001-09-12 Alexandre Oliva <aoliva@redhat.com>
-
- * readelf.c (guess_is_rela, dump_relocations, get_machine_name,
- get_machine_flags): Added EM_M32R, EM_D10V, EM_V850, EM_D30V,
- EM_MN10200, EM_MN10300, EM_FR30, EM_AVR_OLD and EM_PJ_OLD.
- Removed EM_CYGNUS_ARC.
-
-2001-09-04 Jeffrey A Law (law@cygnus.com)
-
- * readelf.c: Include elf/h8 for H8 series definitions.
- (guess_is_rela): H8 series if RELA.
- (dump_relocations): Handle H8 series relocations.
-
-2001-08-31 Eric Christopher <echristo@redhat.com>
-
- * readelf.c (get_machine_flags): Remove E_MIPS_MACH_MIPS32_4K.
-
-2001-08-29 Peter Targett <peter.targett@arccores.com>
-
- * MAINTAINERS: Include ARC Maintainer.
-
-2001-08-29 Ben Elliston <bje@redhat.com>
-
- * stabs.c (stab_demangle_template): Initialise s4.
-
-2001-08-27 Alan Modra <amodra@bigpond.net.au>
-
- * readelf.c (dump_relocations): Recognise EM_PPC64.
-
-2001-08-26 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * readelf.c (get_machine_flags): Add detection of EF_MIPS_32BITMODE.
-
-2001-08-25 H.J. Lu <hjl@gnu.org>
-
- * nm.c (print_width): New.
- (display_rel_file): Set `print_width' according to
- bfd_sprintf_vma.
- (print_symbol_info_bsd): Check `print_width' instead of BFD64.
-
-2001-08-24 Alexandre Oliva <aoliva@redhat.com>
-
- * objcopy.c (use_alt_mach_code): New variable.
- (OPTION_ALT_MACH_CODE): Define.
- (copy_options): Added --alt-machine-code.
- (copy_main): Handle it.
- (copy_object): Switch to alternate machine code if requested.
- * doc/binutils.texi: Document new option.
- * NEWS: Likewise.
-
-2001-08-22 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * readelf.c (get_machine_flags): Add detection of EF_MIPS_UCODE.
-
-2001-08-21 H.J. Lu <hjl@gnu.org>
-
- * readelf.c (dump_relocations): Support ELF64 on 32bit hosts.
- (display_debug_info): Cast for 64bit hosts.
- (display_debug_frames): Likewise.
- (process_mips_specific): Likewise.
-
-2001-08-21 Andreas Jaeger <aj@suse.de>
-
- * coffgrok.h: Add missing parameter for prototype of coff_grok.
-
- * sysdump.c: Add missing prototypes.
- * srconv.c: Likewise.
- * unwind-ia64.c: Likewise.
- * coffdump.c: Likewise.
-
- * sysinfo.y: Print prototypes, include <ansidecl.h>.
-
- * coffgrok.c: Add missing prototypes, include libiberty.h instead
- of declaring xcalloc.
-
-2001-08-10 H.J. Lu <hjl@gnu.org>
-
- * nm.c (print_value): Add one arg, bfd *.
- (print_value): Replace fprintf_vma with bfd_fprintf_vma.
- (print_symbol_info_bsd): Also pass `abfd' to print_value ().
- (print_symbol_info_sysv): Likewise.
- (print_symbol_info_posix): Likewise.
-
- * objdump.c (dump_section_header): Replace printf_vma with
- bfd_printf_vma.
- (print_section_stabs): Likewise.
- (dump_bfd_header): Likewise.
- (objdump_print_value): Replace sprintf_vma with
- bfd_sprintf_vma.
- (disassemble_bytes): Likewise.
- (dump_reloc_set): Likewise.
-
-2001-08-10 Andreas Jaeger <aj@suse.de>
-
- * configure.in: Add -Wstrict-prototypes and -Wmissing-prototypes
- to build warnings.
- * configure: Regenerate.
-
-2001-08-09 Alan Modra <amodra@bigpond.net.au>
-
- * readelf.c: Add missing prototypes.
- * objdump.c: Likewise. Format existing prototypes.
-
-2001-08-08 Alexandre Oliva <aoliva@redhat.com>
-
- * readelf.c (display_debug_info): Add to abbrev_offset the addend
- of any RELA relocation for the abbrev_offset memory location that
- refers to the .debug_abbrev section symbol.
-
-2001-08-07 H.J. Lu <hjl@gnu.org>
-
- * readelf.c (process_file): Return 0 if OK, otherwise return 1.
- (main): Return process_file ().
-
-2001-08-05 Philip Blundell <philb@gnu.org>
-
- * doc/binutils.texi: Use "Thumb" not "THUMB".
-
-2001-08-03 John Healy <jhealy@redhat.com>
-
- Patch suggested by Frank Eigler <fche@redhat.com>.
- * objdump.c (disassemble_data): Fill in section member of the
- disasm_info structure.
-
-2001-08-03 Tom Walsh <tom@cyberiansoftware.com>
-
- * configure.in: Added --with-windres option.
- * configure: Regenerated.
-
-2001-07-11 Stephane Carrez <Stephane.Carrez@worldnet.fr>
-
- * doc/binutils.texi: Use @command{name} for commands;
- use @option{-opt} for options; use @table @env for list of options;
- remove spaces arround [ | ] in synopsis.
-
- * doc/Makefile.am (POD2MAN): Use 'GNU Development Tools' for the
- center title.
-
-2001-07-31 Nick Clifton <nickc@cambridge.redhat.com>
-
- * objcopy.c: Fix formatting.
- (section_rename): New structure.
- (OPTION_RENAME_SECTION): New switch.
- (copy_usage): Document new switch.
- (add_section_rename): New function: Add a node to the section
- rename list.
- (find_section_rename): New function: Find the new name and
- flags for a section.
- (setup_section): Call find_section_name to determine the name
- of the output section.
- (copy_main): Handle OPTION_RENAME_SECTION.
- * binutils.texi: Document new switch.
- * NEWS: Mention new switch.
-
-2001-07-30 Nick Clifton <nickc@cambridge.redhat.com>
- * README: Rename bug-gnu-utils@gcc.org to bug-binutils@gcc.org.
- * MAINTAINERS: Rename bug-gnu-utils@gcc.org to
- bug-binutils@gcc.org.
+ 2004-03-21 Richard Henderson <rth@redhat.com>
+ * readelf.c (display_debug_frames): Don't crash for mismatched
+ DW_CFA_restore_state.
-2001-07-28 Matthias Kramm <kramm@quiss.org>
+ 2004-03-10 Ben Elliston <bje@gnu.org>
+ * MAINTAINERS: Update my mail address.
- * bucomm.c (list_supported_architectures): New function.
- * bucomm.h (list_supported_architectures): Declare.
- * objdump.c (usage): Call the above.
+ 2004-03-08 Danny Smith <dannysmith@users.sourceforge.net>
+ * deflex.l: Handle "PRIVATE" string.
+ * defparse.y (%token): Add PRIVATE.
+ (%type): Add opt_PRIVATE.
+ (expline): Pass opt_PRIVATE to def_exports.
+ (opt_PRIVATE): Handle PRIVATE token.
+ * dlltool.h (def_exports): Add 7th param for private flag to
+ declaration.
+ * dlltool.c: Add PRIVATE to comment on EXPORTS syntax.
+ (struct export): Add 'private' field.
+ (def_exports): Set 'private' field of struct exports.
+ (scan_drectve_symbols): Adjust calls to def_exports.
+ (scan_filtered_symbols): Likewise.
+ (dump_def_info): Print 'private' field.
+ (gen_def_file): Likewise.
+ (gen_lib_file): Skip generation of lib object if private.
+ Delete tmp object files in same order as they were generated.
+ Don't delete non-existent private object files.
-2001-07-25 Dave Brolley <brolley@redhat.com>
+ 2004-02-27 Andreas Schwab <schwab@suse.de>
+ * ar.c (main): Support POSIX-compatible argument parsing.
- * objdump.c (SKIP_ZEROES): Only define it if it is not already defined.
- (SKIP_ZEROES_AT_END): Only define it if it is not already defined.
+ 2004-02-23 Daniel Lucq <daniel@lucq.org>
+ * readelf.c (process_mips_specific): Print conflictsno as an
+ unsigned long.
-2001-07-19 Nick Clifton <nickc@cambridge.redhat.com>
+ 2004-02-21 Dmitry Timoshkov <dmitry@baikal.ru>
+ * dlltool.c (gen_exp_file): Always output names for forwarded symbols.
- * README: Update for 2.11. Change bug reporting email address.
- * MAINTAINERS: Tidy up. Change bug reporting email address.
+ 2004-02-19 Jakub Jelinek <jakub@redhat.com>
+ * objcopy.c (copy_section): Avoid warnings.
-2001-07-16 DJ Delorie <dj@redhat.com>
+2004-02-14 Andrew Cagney <cagney@redhat.com>
- * resres.c (write_res_header): Align header size.
- (res_align_file): Calculate alignment correctly.
+ * ar.c (remove_output): Use bfd_cache_close.
+ * arsup.c (ar_end): Ditto.
- * rcparse.y (styles): use SUBLANG_SHIFT instead of 8 (or the more
- correct 10).
- * resrc.c (write_rc_resource): Likewise.
- * windres.h (SUBLANG_SHIFT): Define - as 10.
+2004-01-21 Roland McGrath <roland@redhat.com>
-2001-07-15 Nick Clifton <nickc@cambridge.redhat.com>
+ * readelf.c (get_note_type): Match NT_AUXV.
- * MAINTAINERS: Add Christian Groessler as maintainer for z8k port.
+2004-01-20 Nick Clifton <nickc@redhat.com>
-2001-07-11 Nick Clifton <nickc@cambridge.redhat.com>
+ * version.c (print_version): Update copyright year to 2004.
- * MAINTAINERS: Add notes about branch checkins.
+2004-01-14 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
-2001-07-05 Daniel Berlin <dan@cgsoftware.com>
-
- * readelf.c (display_debug_macinfo): New function, display
- .debug_macinfo section.
- (do_debug_macinfo): New variable.
- (parse_args): Handle "-w[mM]" to mean display macro info.
- (process_section_headers): Handle debug_macinfo.
- (debug_displays): Replace unsupported function with macinfo
- function for .debug_macinfo display.
- * doc/binutils.texi: Document new command line switch.
- * NEWS: Document new feature of readelf.
-
-2001-07-05 H.J. Lu <hjl@gnu.org>
-
- * objcopy.c (filter_symbols): Don't turn undefined symbols
- into local.
-
-2001-07-03 H.J. Lu <hjl@gnu.org>
-
- * doc/Makefile.am (addr2line.1): Use addr2line.pod instead of
- $@.pod.
- (ar.1): Likewise.
- (dlltool.1): Likewise.
- (nlmconv.1): Likewise.
- (nm.1): Likewise.
- (objcopy.1): Likewise.
- (objdump.1): Likewise.
- (ranlib.1): Likewise.
- (readelf.1): Likewise.
- (size.1): Likewise.
- (strings.1): Likewise.
- (strip.1): Likewise.
- (windres.1): Likewise.
- (cxxfilt.man): Use $(DEMANGLER_NAME).pod instead of $@.pod.
- ($(DEMANGLER_NAME).1): Also substitute cxxfilt with
- $(DEMANGLER_NAME).
- (as.1): Removed.
- * doc/Makefile.in: Regenerated.
-
-2001-07-03 Nick Clifton <nickc@cambridge.redhat.com>
-
- * MAINTAINERS: Change MIPS maintainer to Eric Christopher.
-
-2001-07-01 Daniel Berlin <dan@cgsoftware.com>
-
- * readelf.c: Support DWARF 2.1 tags, encodings, languages.
-
-2001-06-29 James Cownie <jcownie@etnus.com>
-
- * readelf.c: Support DWARF 2.1 attributes.
-
-2001-06-28 Alan Modra <amodra@bigpond.net.au>
-
- * readelf.c (GET_DATA_ALLOC): Remove.
- (GET_DATA): Remove.
- (get_data): New function combining above macros, with an extra
- test for zero size.
- (slurp_rela_relocs): Use get_data, and catch error return.
- (slurp_rel_relocs): Likewise.
- (get_32bit_program_headers): Likewise.
- (get_64bit_program_headers): Likewise.
- (get_32bit_section_headers): Likewise.
- (get_64bit_section_headers): Likewise.
- (get_32bit_elf_symbols): Likewise.
- (get_64bit_elf_symbols): Likewise.
- (process_section_headers): Likewise.
- (process_relocs): Likewise.
- (slurp_ia64_unwind_table): Likewise.
- (process_unwind): Likewise.
- (get_32bit_dynamic_segment): Likewise.
- (get_64bit_dynamic_segment): Likewise.
- (process_dynamic_segment): Likewise.
- (process_version_sections): Likewise.
- (process_symbol_table): Likewise.
- (dump_section): Likewise.
- (display_debug_info): Likewise.
- (display_debug_section): Likewise.
- (process_section_contents): Likewise.
- (process_corefile_note_segment): Likewise.
- (process_mips_specific): Likewise. Also free econf32, econf64.
-
-2001-06-25 Alan Modra <amodra@bigpond.net.au>
-
- * readelf.c (dump_relocations): Print "bad symbol index" if
- symtab == NULL with non-zero symtab_index.
- (process_relocs): Don't bomb if reloc section has no symsec.
-
-2001-06-24 H.J. Lu <hjl@gnu.org>
-
- * objcopy.c (strip_main): Revert the change made on 2001-05-30
- by accident.
- (copy_main): Apply the the change made to strip_main on
- 2001-05-30 by accident.
-
-2001-06-23 Andreas Jaeger <aj@suse.de>
-
- * unwind-ia64.c (unw_decode_x1): Add unused attribute for
- parameter 'code'.
- (unw_decode_x2): Likewise.
- (unw_decode_x3): Likewise.
- (unw_decode_x4): Likewise.
-
-2001-06-23 Ben Elliston <bje@redhat.com>
-
- * MAINTAINERS: Add myself as M88k maintainer.
-
-2001-06-22 Jocelyn Mayer <jocelyn.mayer@netgem.com>
-
- * objcopy.c (strip_main): Support -o or --output-file command lien
- switch.
-
-2001-06-19 H.J. Lu <hjl@gnu.org>
-
- * doc/Makefile.in: Regenerated.
-
-2001-06-19 Nick Clifton <nickc@cambridge.redhat.com>
-
- * readelf.c: Restore formatting.
-
-2001-06-18 H.J. Lu <hjl@gnu.org> & Nick Clifton <nickc@redhat.com>
-
- * Makefile.am: Move documentation into doc subdirectory.
- * Makefile.in: Regenerated.
- * binutils.texi: Move into doc subdirectory.
- * addr2line.1: Removed.
- * ar.1: Likewise.
- * dlltool.1: Likewise.
- * nlmconv.1: Likewise.
- * nm.1: Likewise.
- * objcopy.1: Likewise.
- * objdump.1: Likewise.
- * ranlib.1: Likewise.
- * readelf.1: Likewise.
- * size.1: Likewise.
- * strings.1: Likewise.
- * strip.1: Likewise.
- * windres.1: Likewise.
- * cxxfilt.man: Likewise.
- * doc: New Directory.
- * doc/Makefile.am: New file.
- * doc/Makefile.in: Generate.
-
-2001-06-09 Alan Modra <amodra@bigpond.net.au>
-
- * NEWS: Fix a typo. Mention hppa64-elf. Add binutils-2.11 marker.
-
-2001-06-01 Alan Modra <amodra@bigpond.net.au>
-
- * MAINTAINERS: Update my email address.
-
-2001-05-30 Honda Hiroki <hhonda@kobe-catv.ne.jp>
-
- * objcopy.c: Add new switches: --keep-global-symbol,
- --keep-symbols, --localize-symbols, --keep-global-symbols and
- --weaken-symbols.
- * binutils.texi: Document new switches.
- * objcopy.1: Regenerate.
- * NEWS: Announce new feature.
-
-2001-05-28 Andreas Jaeger <aj@suse.de>
-
- * readelf.c (display_debug_frames): Fix warnings: Remove unused
- variables, fix format strings.
-
-2001-05-28 Nick Clifton <nickc@cambridge.redhat.com>
-
- * objdump.c (disassemble_bytes): Remove section VMA adjustment
- when computing the address of the line to show.
-
-2001-05-16 Richard Henderson <rth@redhat.com>
-
- * readelf.c (do_debug_frames_interp): New.
- (byte_get_little_endian): If BFD64, always read entire 8-byte fields.
- (byte_get_big_endian): Likewise.
- (parse_args) ['F']: Set do_debug_frames_interp.
- (Frame_Chunk): Make data_factor signed, add fde_encoding.
- (frame_display_row): Don't trunc pc_begin to int.
- (size_of_encoded_value): New.
- (display_debug_frames): Handle 64-bit targets. Print raw data
- unless do_debug_frames_interp.
- (debug_displays): Remove duplicate .debug_frame.
-
-2001-05-15 Ralf Baechle <ralf@gnu.org>
-
- * readelf.c: Replace uses of EM_MIPS_RS4_BE with EM_MIPS_RS3_LE.
- The former constant was never in active use and is used otherwise
- by the ABI.
-
-2001-05-11 Jakub Jelinek <jakub@redhat.com>
-
- * readelf.c (process_unwind): Print all unwind sections, not just
- one.
-
-2001-05-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * readelf.c (process_unwind): Remove const specifier.
-
-2001-04-27 Michal Svec <rebel@atrey.karlin.mff.cuni.cz>
-
- * strings.c (isgraphic): Do not use isascii() unless it is needed
- for isprint() to work.
- (main): Set the locale domain to LC_ALL not just LC_MESSAGES.
-
-2001-04-27 Johan Rydberg <jrydberg@opencores.org>
-
- * NEWS: Announce support for OpenRISC.
-
-2001-04-17 Danny Smith <dannysmith@users.sourceforge.net>
-
- * dlltool.c (do_default_excludes): Initialise to true.
-
-2001-04-10 Alan Modra <amodra@one.net.au>
-
- * MAINTAINERS: Update my email address
- * nm.c (print_symbol_info_bsd): Use a simple printf string.
-
-2001-04-05 Hans-Peter Nilsson <hp@axis.com>
-
- * readelf.c (display_debug_lines): Fix typo for "Prologue".
-
-2001-03-30 H.J. Lu <hjl@gnu.org>
-
- * readelf.c (process_unwind): Just return if do_unwind is 0.
-
-2001-03-28 Roger Sayle <roger@metaphorics.com>
-
- * dlltool.c (make_one_lib_file): Fix section flags for
- .text, .data and .bss in stub ds*.o files to match those
- generated by gas.
-
-2001-03-29 H.J. Lu <hjl@gnu.org>
-
- * readelf.c (process_unwind): Only do unwind sections for
- IA64.
-
-2001-03-28 H.J. Lu <hjl@gnu.org>
-
- * Makefile.am ($(srcdir)/dlltool.1): Remove the extra target.
- * Makefile.in: Regenerate.
-
-2001-03-26 Andreas Jaeger <aj@suse.de>
-
- * binutils.texi (nm): Fix texi syntax.
-
-2001-03-25 Stephane Carrez <Stephane.Carrez@worldnet.fr>
-
- * binutils.texi: Put @c man begin and @c man end indications
- to generate man pages using texi2pod and pod2man. Put @c man title
- to identify each man. Add SEEALSO entries.
- * Makefile.am (MANCONF, TEXI2POD, POD2MAN): New variable.
- (man_MANS): Add dlltool.1, nlmconv.1, readelf.1, windres.1,
- sort the list.
- (*.1): Build the man pages from binutils.texi.
- * Makefile.in: Regenerate.
-
-2001-03-13 Eric Kohl <ekohl@rz-online.de>
-
- * defparse.y (opt_equal_name): allow "." in name.
- * dlltool.c (def_exports): Added ability to generate forwarded exports.
- (gen_exp_file): Likewise.
-
-2001-03-12 Stefan Geuken <mail@stefan-geuken.de>
-
- * NEWS: Document addition of -B switch to objcopy.
- * binutils.texi: Document addition of -B switch to objcopy.
- * objcopy.c: (copy_options): Add --binary-architecture.
- (copy_usage): Document -B/--binary-architecture.
- (copy_main): Support -B/--binary-architecture. Set
- bfd_external_binary_architecture.
-
-2001-03-11 Andreas Jaeger <aj@suse.de>
-
- * readelf.c (guess_is_rela): Handle EM_S390_OLD.
- (dump_relocations): Likewise.
- (get_machine_name): Likewise.
-
-2001-02-28 Nick Clifton <nickc@redhat.com>
-
- * readelf.c: (struct unw_aux_info): Remove const modifier for
- 'strtab' field.
- (process_unwind): Remove non-K&R compliant LHS type cast in call
- to GET_DATA_ALLOC macro.
-
-2001-02-28 Philip Blundell <pb@futuretv.com>
-
- * readelf.c (decode_ARM_machine_flags): Explicitly mention which
- ABI is in use; remove ambiguity between the "unknown" EABI and
- unrecognised ABIs. Handle version 2 ARM EABI. Update uses of
- renamed EF_xx constants.
-
-2001-02-27 Alan Modra <alan@linuxcare.com.au>
-
- * configure.in (BFD_VERSION): New.
- (AM_INIT_AUTOMAKE): Use $BFD_VERSION.
- * configure: Regenerate.
- * Makefile.am: Run "make dep-am"
- * Makefile.in: Regenerate.
-
-2001-02-14 Nick Clifton <nickc@redhat.com>
-
- * MAINTAINERS: Add "Obvious Fix" rule.
-
-2001-02-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
-
- * unwind-ia64.c: Don't use ANSI C preprocessor stringisation and string
- literal concatenation.
-
-2001-02-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
-
- * readelf.c (struct unw_aux_info): Remove const from the info member.
- (process_unwind): Don't type-cast the third argument to the
- GET_DATA_ALLOC macro.
-
-2001-02-11 Nick Clifton <nickc@redhat.com>
-
- * readelf.c (dump_relocations): Free corrected allocated
- array.
- (process_unwind): Fix compile time warning.
-
-2001-02-10 Nick Clifton <nickc@redhat.com>
-
- * binutils.texi: Document new --unwind option to readelf.
-
-2001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * readelf.c: Add linux target for S/390.
-
-2001-02-10 Alan Modra <alan@linuxcare.com.au>
-
- * nm.c (print_symbol_info_bsd): Don't #ifdef inside printf in case
- printf is a macro.
-
-2001-02-08 Hans-Peter Nilsson <hp@bitrange.com>
-
- * acinclude.m4 (AM_PROG_LEX): Override installed definition.
+ * acinclude.m4: Quote names of macros to be defined by AC_DEFUN
+ throughout.
* aclocal.m4: Regenerate.
* configure: Regenerate.
-2001-02-07 Todd Vierling <tv@wasabisystems.com>
-
- * bucomm.c (bfd_target_vector): Change extern array to pointer.
- * objdump.c (bfd_target_vector): Likewise.
-
-2001-02-07 David Mosberger <davidm@hpl.hp.com>
-
- * readelf.c (process_unwind): New function.
- (slurp_ia64_unwind_table): Ditto.
- (dump_ia64_unwind): Ditto.
- (find_symbol_for_address): Ditto.
- (slurp_rela_relocs): New function (split off from dump_relocations()).
- (slurp_rel_relocs): Ditto.
- (parse_args): Handle '-u' option.
-
- * unwind-ia64.c: New file.
- * unwind-ia64.h: New file.
- * Makefile.am: Include unwind-ia64.c in readelf build.
- * Makefile.in: Regenerate.
- * po/binutils.pot: Regenerate.
-
-2001-02-04 Philip Blundell <philb@gnu.org>
-
- * configure.in (OBJDUMP_DEFS): Match `arm*-*', not just `arm-*'.
- * configure: Regenerate.
-
-2001-01-31 Steve deRosier <sderosier@vari-lite.com>
-
- * ieee.c (ieee_add_bb11): Don't check for backslashes
- unless HAVE_DOS_BASED_FILE_SYSTEM is defined.
-
-2001-01-24 Mark Elbrecht <snowball3@bigfoot.com>
-
- * ieee.c: Update copyright.
- (ieee_start_compilation_unit): Don't check for backslashes
- unless HAVE_DOS_BASED_FILE_SYSTEM is defined.
-
- * stabs.c: Update copyright. Include "filenames.h".
- (parse_stab): Use IS_ABSOLUTE_PATH. Ignore N_WARNING stabs.
-
-2001-01-23 Jakub Jelinek <jakub@redhat.com>
-
- * readelf.c (process_version_sections): Check if VERDEF or VERNEED
- sections are present before using them. Remove code duplication.
- (process_symbol_table): Check if VERDEF or VERNEED sections are
- present before using them.
-
-2001-01-17 Nick Clifton <nickc@redhat.com>
-
- * objcopy.c (copy_object): Fail if attempting to convert the
- endianness of the input object file.
-
- * binutils.texi: Explain that objcopy cannot convert endianness.
-
-2001-01-16 Nick Clifton <nickc@redhat.com>
-
- * readelf.c (string_table_length): New variable.
- (SECTION_NAME): Catch out of range indices and missing section
- pointers.
- (process_section_headers): Delete useless local variable
- string_table_offset. Set the value of string_table_length
- after loading the string table.
- (process_mips_specific): Use SECTION_NAME macro.
- (process_file): Set string_table_length to 0 when it is freed.
-
-2001-01-12 Nick Clifton <nickc@redhat.com>
-
- * version.c (print_version): Update copyright date.
-
-2001-01-11 Peter Targett <peter.targett@arccores.com>
-
- * readelf.c (dump_relocations): Include selection with EM_ARC.
- (get_machine_name) Update name to "ARC".
-
-2001-01-09 Nick Clifton <nickc@redhat.com>
-
- * Makefile.am: Add rule to build objdump.o from objdump.c and
- using OBJDUMP_DEFS.
- * Makefile.in: Regenerate.
-
- * configure.in: Define OBJDUMP_DEFS. Default to empty.
- (arm, xscale, d10v): For these targets define OBJDUMP_DEFS to
- -DDISASSEMBLER_NEEDS_RELOCS.
- * configure: Regenerate.
-
- * objdump.c (disassemble_bytes): If DISASSEMBLER_NEEDS_RELOCS
- is defined read in the relocs even if dump_reloc_info is
- false.
-
-2001-01-07 Philip Blundell <philb@gnu.org>
-
- * binutils.texi (Bug Reporting): Replace `bug-gnu-utils' with
- `bug-binutils'.
- * README: Likewise.
-
-2000-12-19 Nick Clifton <nickc@redhat.com>
-
- * dlltool.c: Add missing support for arm-epoc-pe.
- * configure.in: Add missing support for arm-epoc-pe.
- * configure: Regenerate.
-
-2000-12-15 Nick Clifton <nickc@redhat.com>
-
- * MAINTAINERS: Add Diego Novillo as a maintainer for the Intel
- Mode parts of the x86 port.
-
-2000-12-04 Andreas Jaeger <aj@suse.de>
-
- * readelf.c (guess_is_rela): Add EM_X86_64.
- (dump_relocations): Add EM_X86_64.
- (get_machine_name): Add EM_X86_64.
- Include "elf/x86-64.h".
-
-2000-12-12 Nick Clifton <nickc@redhat.com>
-
- * readelf.c: Fix formatting.
-
-2000-12-11 Jan Hubicka <jh@suse.cz>
-
- * MAINTAINERS: Add myself and Andreas Jaeger as x86_64 maintainer.
-
-2000-12-07 Andrew Haley <aph@redhat.com>
-
- * readelf.c (display_debug_frames): Only display columns that are
- referenced by the frame debug info.
-
-2000-12-05 Nick Clifton <nickc@redhat.com>
-
- * MAINTAINERS: Add Jason Merrill as DWARF2 maintainer.
-
-2000-12-04 Jason Merrill <jason@redhat.com>
-
- * readelf.c (process_section_headers): Handle linkonce.wi sections.
- (display_debug_section): Likewise.
- (display_debug_info): Display CU header before bailing.
-
-2000-12-01 Chris Demetriou <cgd@sibyte.com>
-
- * readelf.c (get_machine_flags): Recognize MIPS32 ISA in
- EF_MIPS_ARCH. Replace use of E_MIPS_MACH_MIPS32 with
- E_MIPS_MACH_MIPS32_4K and adjust printed CPU name similarly.
-
- * readelf.c (get_machine_flags): Add cases for E_MIPS_ARCH_5,
- and E_MIPS_ARCH_64.
-
- * readelf.c (get_machine_flags): Add case for
- E_MIPS_MACH_SB1.
-
-2000-11-30 Richard Earnshaw <rearnsha@arm.com>
-
- * readelf.c (frame_display_row): Output 's' for DW_CFA_same_value.
-
-2000-11-28 Hans-Peter Nilsson <hp@bitrange.com>
-
- * MAINTAINERS: Add Jörn Rennecke and self as SH maintainers.
- Change sourceware.cygnus.com to sources.redhat.com.
- Fix typo for "amongst".
-
-2000-11-28 Nick Clifton <nickc@redhat.com>
-
- * strip.1 (COPYING): Mention that the GNU Free Documentation
- License is present in the sources, but not the output, and
- also available from the GNU website.
- (GNU Free Documentation License): Comment out this section.
- * strings.1: Ditto.
- * size.1: Ditto.
- * ranlib.1: Ditto.
- * objdump.1: Ditto.
- * objcopy.1: Ditto.
- * nm.1: Ditto.
- * nlmconv.1: Ditto.
- * ar.1: Ditto.
- * addr2line.1: Ditto.
-
-2000-11-27 DJ Delorie <dj@redhat.com>
-
- * readelf.c (usage): Add -wf (--debug-dump=frames) option.
- (parse_args): Support -wf option.
- (process_section_headers): Ditto.
- (debug_displays): Ditto.
- (display_debug_frames): New, dump *_frame sections.
- (frame_need_space): Support for above.
- (frame_display_row): Ditto.
- * binutils.texi: Document it.
-
-2000-11-24 Nick Clifton <nickc@redhat.com>
-
- * NEWS: Announce support for v5t, v5te and XScale.
-
-2000-11-22 Nick Clifton <nickc@redhat.com>
-
- * readelf.c (get_machine_name): Add EM_JAVELIN, EM_FIREPATH,
- EM_ZSP, EM_MMIX, EM_HUANY, EM_PRISM.
- (get_section_type_name): Add SHT_GROUP and SHT_SYMTAB_SHNDX.
- (get_elf_section_flags: Add SHF_GROUP.
- (process_section_headers): Adjust output for 32-bit binaries
- to look nice on an 80 column terminal.
-
-2000-11-20 H.J. Lu <hjl@gnu.org>
-
- * readelf.c (get_osabi_name): Change ELFOSABI_MONTEREY to
- ELFOSABI_AIX.
-
-2000-11-17 Richard Henderson <rth@redhat.com>
-
- * readelf.c (display_debug_lines): Adjust last change to
- use sizeof (external->li_length).
-
-2000-11-17 Richard Henderson <rth@redhat.com>
-
- * readelf.c (display_debug_lines): Fix section length check
- and end_of_sequence computation.
-
-2000-11-06 Nick Clifton <nickc@redhat.com>
-
- * binutils.texi: Add GNU Free Documentation License.
- * objcopy.1: Add GNU Free Documentation License.
- * objdump.1: Add GNU Free Documentation License.
- * addr2line.1: Add GNU Free Documentation License.
- * ar.1: Add GNU Free Documentation License.
- * nlmconv.1: Add GNU Free Documentation License.
- * nm.1: Add GNU Free Documentation License.
- * ranlib.1: Add GNU Free Documentation License.
- * size.1: Add GNU Free Documentation License.
- * strings.1: Add GNU Free Documentation License.
- * strip.1: Add GNU Free Documentation License.
-
-2000-10-06 Luciano Gemme <ishitawa@yahoo.com>
-
- * objcopy.c (--srec-len=nn): New parameter to set the
- maximum length of generated Srecords.
- (--srec-forceS3): New parameter that restricts the generation of
- Srecords to type S3 only.
- * binutils.texi: Document new command line switches.
- * objcopy.1: Docuemnt the new command line switches.
- * NEWS: Announce the existence of the new command line switches.
-
-2000-10-31 Nick Clifton <nickc@redhat.com>
-
- * MAINTAINERS: Add Jim Wilson as the maintainer for the IA64
- code. Add Eric Chrisopher as maintainer of MN10300 port.
-
-2000-10-12 Roger Sayle <roger@metaphorics.com>
-
- * Make comma after string after icon/control optional.
-
-2000-09-13 Anders Norlander <anorland@acc.umu.se>
-
- * readelf.c (get_machine_flags): Also print EF_MIPS_MACH field.
-
- * NEWS: Mention support for MIPS32.
-
-2000-09-08 Nick Clifton <nickc@redhat.com>
-
- * MAINTAINERS: Add Stephane Carrez as maintainer for 68HC[11|12].
-
-2000-09-07 H.J. Lu <hjl@gnu.org>
-
- * configure.in (AC_ISC_POSIX): Put after AC_CANONICAL_SYSTEM.
- * configure: Rebuild.
-
-2000-09-06 Alexandre Oliva <aoliva@redhat.com>
-
- * configure: Rebuilt with new libtool.m4.
-
-2000-09-05 Nick Clifton <nickc@redhat.com>
-
- * aclocal.m4: Regenerate.
- * config.in: Regenerate.
- * configure: Regenerate.
-
-2000-09-04 Todd Vierling <tv@wasabisystems.com>
-
- * strip.1: Fix stray '\' in -o formatting.
-
-2000-09-02 Nick Clifton <nickc@redhat.com>
-
- * configure.in: Increase version number to 2.10.91.
- * configure: Regenerate.
- * aclocal.m4: Regenerate.
- * config.in: Regenerate.
- * po/binutils.pot: Regenerate.
-
-2000-08-31 Alexandre Oliva <aoliva@redhat.com>
-
- * acinclude.m4: Include libtool and gettext macros from the
- top level.
- * aclocal.m4, configure: Rebuilt.
-
-2000-08-30 Jamie Guinan <guinan@bluebutton.com>
-
- * resrc.c (close_input_stream): Delete extraneous logic
-
-2000-08-24 Hans-Peter Nilsson <hp@axis.com>
-
- * NEWS: Mention support for CRIS.
-
-2000-08-21 Nick Clifton <nickc@redhat.com>
-
- * addr2line.c: Changed email address for Ulrich Lauther.
-
-2000-08-17 Christopher C. Chimelis <chris@debian.org>
-
- * objdump.c (LONGEST_ARCH): Set to sizeof("powerpc:common").
-
-2000-08-17 Nick Clifton <nickc@redhat.com>
-
- * readelf.c (display_debug_pubnames): Only issue warning
- message once. Terminate message with a new line.
- (display_debug_aranges): Only display version 2 debug info.
-
-2000-08-14 Todd Vierling <tv@wasabisystems.com>
-
- * objcopy.c (strip_main): Silently accept -d as an alias for -g
- for compatability with old BSD systems.
-
-2000-08-14 Jason Eckhardt <jle@cygnus.com>
-
- * NEWS: Mention i860 support.
-
-2000-08-11 Carlo Wood <carlo@alinoe.com>
-
- * addr2line.c (main): Add const to char *.
-
-2000-08-11 Geoff Keating <geoffk@cygnus.com>
-
- * ar.c (main): Don't crash if called with no arguments
- or only '-X32_64' as an argument.
-
-2000-08-08 DJ Delorie <dj@redhat.com>
-
- * resrc.c: use "gcc -xc" instead of -xc-header
-
-2000-08-05 Jason Eckhardt <jle@cygnus.com>
-
- * readelf.c (elf/i860.h): Include.
- (dump_relocations): Add recognition of i860 architecture.
- (guess_is_rela): Add recognition of i860 architecture.
-
-2000-08-03 Nick Clifton <nickc@cygnus.com>
-
- * MAINTAINERS: Add information about CGEN maintainers.
-
-2000-07-26 Geoff Keating <geoffk@cygnus.com>
-
- * nm.c (main): Ignore '-X32_64' as an option.
- * ar.c (main): Likewise.
- * binutils.texi (nm): Document new option.
- (ar): Likewise.
-
-2000-07-23 Michael Sokolov <msokolov@ivan.Harhan.ORG>
-
- * rdcoff.c (external_coff_symbol_p): K&R-ise.
-
-2000-07-20 H.J. Lu <hjl@gnu.org>
-
- * binutils.texi: Put back "@end table" deleted by
- accident.
-
-2000-07-05 Kenneth Block <krblock@computer.org>
-
- * nm.c: Add optional style to demangle switch.
- * objdump.c: Add optional style to demangle switch.
- * addr2line.c: Add optional style to demangle switch.
- * binutils.texi: Document optional style to demangle
- switch.
-
-2000-07-20 Hans-Peter Nilsson <hp@axis.com>
-
- * MAINTAINERS: Add self as CRIS port maintainer.
- * readelf.c: Include elf/cris.h.
- (guess_is_rela): Handle EM_CRIS.
- (dump_relocations): Ditto.
- (get_machine_name): Ditto.
- * Makefile.am: Rebuild dependencies.
- * Makefile.in: Regenerate.
- * po/binutils.pot: Regenerate.
-
-2000-07-19 H.J. Lu <hjl@gnu.org>
-
- * readelf.c (get_dynamic_type): Change "AUXILARY" to
- "AUXILIARY".
- (process_dynamic_segment): Print out strings for DT_CONFIG,
- DT_DEPAUDIT, DT_AUDIT and DT_RUNPATH.
-
-2000-07-19 Mark Kettenis <kettenis@gnu.org>
-
- * nm.c (usage): Change output of `nm --help' to include a
- description of the purpose of the program and a detailed
- description of the accepted options.
-
-2000-07-19 H.J. Lu <hjl@gnu.org>
-
- * readelf.c (process_dynamic_segment): Change DF_1_NODEPLIB
- to DF_1_NODEFLIB.
-
-2000-07-19 H.J. Lu <hjl@gnu.org>
-
- * readelf.c (get_dynamic_type): Fix DT_CHECKSUM.
-
-2000-07-19 H.J. Lu <hjl@gnu.org>
-
- * readelf.c (get_dynamic_type): Change DT_FEATURE_1 to
- DT_FEATURE.
- (process_dynamic_segment): Likewise.
-
- * readelf.c (get_dynamic_type): Handle DT_CONFIG, DT_DEPAUDIT,
- DT_AUDIT, DT_PLTPAD, DT_MOVETAB and DT_CHECKSUM.
- (process_dynamic_segment): Handle DTF_1_CONFEXP, DF_1_NODEPLIB,
- DF_1_NODUMP and DF_1_CONLFAT.
-
-2000-07-18 Nick Clifton <nickc@cygnus.com>
-
- * binutils.texi (readelf): Fix spelling typo.
-
-2000-07-11 Mark Kettenis <kettenis@gnu.org>
-
- * objdump.c (usage): Make output of `objdump --help' more
- consistent with the rest of the GNU world. Add a line describing
- the purpose of the program.
-
-2000-07-10 David Huggins-Daines <dhd@linuxcare.com>
-
- * stabs.c (parse_stab_range_type): Cast to proper type to fix
- warning.
-
-2000-07-10 Ryan Bradetich <rbradetich@uswest.net>
-
- * readelf.c (get_dynamic_data): Add casts and use unsigned chars
- to fix warnings.
- (process_symbol_table): Ditto.
- (procesS_extended_line_op): Ditto.
- (display_debug_lines): Ditto.
- (display_debug_pubnames): Ditto.
- (read_and_display_attr): Ditto.
-
-2000-07-09 Nick Clifton <nickc@cygnus.com>
-
- * MAINTAINERS: Add several more port specific maintainers.
-
-2000-07-05 Nick Clifton <nickc@cygnus.com>
-
- * MAINTAINERS: Add blanket write privs for Michael Meissner.
-
-2000-06-05 DJ Delorie <dj@redhat.com>
-
- * MAINTAINERS: New.
-
-2000-07-01 Eric Fifer <EFifer@sanwaint.com>
-
- * dllwrap.c: Changed mistaken dyn_string_append() calls
- to dyn_string_append_cstr().
-
-2000-07-01 Alexander Aganichev <AAganichev@hypercom.com>
-
- * stabs.c (parse_stab_type): Divide size in bits by 8 as binutils
- struct debug_type stores size in bytes.
-
-2000-07-01 Alan Modra <alan@linuxcare.com.au>
-
- * Makefile.am (DEP): Fix 2000-06-22. grep after running dep.sed
- (CLEANFILES): Add DEPA.
- * Makefile.in: Regenerate.
-
-2000-06-27 Alan Modra <alan@linuxcare.com.au>
-
- * ar.c: Revert incorrect 2000-06-25 patch.
- * bucomm.c: Likewise.
-
-2000-06-25 Mark Elbrecht <snowball3@bigfoot.com>
-
- * rdcoff (parse_coff_symbol): Treat GNU weak symbols as external.
- (external_coff_symbol_p): New function.
- (parse_coff): Use it.
-
-2000-06-25 Alexander Aganichev <AAganichev@hypercom.com>
-
- * ar.c (normalize): Advance past both characters in a DOS based
- <letter>: filepath prefix.
- (main): Likewise.
- * bucomm.c (make_tempname): Likewise.
-
-2000-06-24 Nick Clifton <nickc@cygnus.com>
-
- * objdump.c (usage): Fix description of --stabs switch.
-
-2000-06-22 Alan Modra <alan@linuxcare.com.au>
-
- * Makefile.am (DEP): grep for leading `/' in DEP1, and fail if we
- find one.
- * Makefile.in: Regenerate.
-
-2000-06-20 Alexander Aganichev <AAganichev@hypercom.com>
-
- * ar.c (normalize): Correct pointer comparison when checking for
- backslashes.
- (main): Likewise.
- * bucomm.c (make_tempname): Likewise.
-
- * ieee.c (ieee_start_compilation_unit): Correct pointer comparison
- and search for backslashes in the original pathname.
- (ieee_add_bb11): Likewise.
-
-2000-06-18 Nick Clifton <nickc@redhat.com>
-
- * ar.c (print_contents): Improve verbose message.
-
-2000-06-15 H.J. Lu <hjl@gnu.org>
-
- * dyn-string.c: Removed. Not needed with dyn-string.c in
- libiberty.
- * dyn-string.h: Likewise.
-
- * Makefile.am: Remove references to dyn-string.c and
- dyn-string.h. Rebuild dependency.
- * Makefile.in: Rebuild.
-
-2000-06-15 H.J. Lu <hjl@gnu.org>
-
- * binutils.texi: Put a warning on copying relocatable object
- files between two different formats.
-
-2000-06-13 DJ Delorie <dj@cygnus.com>
-
- * rcparse.y (control): ICON controls take an id as the first
- parameter, not an optional string. Also, call new convenience
- function that takes res_id's.
- * resrc.c (define_control): missing text means zero-length string,
- not zero ID.
- (define_icon_control): New.
- * windres.h: declare define_icon_control.
-
-2000-06-13 H.J. Lu <hjl@gnu.org>
-
- * configure: Regenerate.
-
-2000-06-08 David O'Brien <obrien@FreeBSD.org>
-
- * configure.in (VERSION): Update to show this is the CVS mainline.
-
-2000-06-02 David O'Brien <obrien@FreeBSD.org>
-
- * strings.c (isgraphic): Interpret <TAB> as a printable character,
- analogous to <SPACE>.
-
-2000-05-30 Alan Modra <alan@linuxcare.com.au>
-
- * objdump.c (display_target_list): Use bfd_close_all_done, not
- bfd_close to fix crash caused by 2000-05-24 change.
-
-2000-05-25 DJ Delorie <dj@cygnus.com>
-
- * resrc.c (close_input_stream): zero out cpp_pipe after closing it.
-
-2000-05-26 Alan Modra <alan@linuxcare.com.au>
-
- * Makefile.am: Update dependencies with "make dep-am"
- * Makefile.in: Regenerate.
-
-2000-05-26 Eli Zaretskii <eliz@is.elta.co.il>
-
- * ar.c: Include filenames.h.
- (normalize) [HAVE_DOS_BASED_FILE_SYSTEM]: Support backslashes
- and drive letters in file names.
- (main): Support backslashes and drive letters in argv[0]. Drop
- the .exe suffix, if any, in argv[0] if is_ranlib is negative. Use
- FILENAME_CMP instead of strcmp to compare file names.
- (open_inarch) [__GO32__]: Don't ifdef errno != ENOENT test for
- DJGPP v2.
- (do_quick_append) [__GO32__]: Ditto.
- (get_pos_bfd, delete_members, move_members, replace_members):
- Compare file names with FILENAME_CMP.
-
- * bucomm.c: Include filenames.h.
- (make_tempname) [HAVE_DOS_BASED_FILE_SYSTEM]: Support mixed
- forward/backward slashes and drive letters in file names.
-
- * ieee.c (ieee_start_compilation_unit, ieee_add_bb11): Support
- mixed forward/backward slashes and drive letters in file names.
-
- * strings.c (O_BINARY, setmode, SET_BINARY): Define.
- (main) [SET_BINARY]: Use SET_BINARY to switch stdin into binary
- mode.
-
- * objcopy.c: Include filenames.h.
- (main) [HAVE_DOS_BASED_FILE_SYSTEM]: Drop the .exe suffix
- before comparing to "strip".
- Use FILENAME_CMP to compare file names.
-
- * arsup.c: Include filenames.h.
- (map_over_list, ar_delete, ar_replace, ar_extract): Use
- FILENAME_CMP to compare file names.
- (ar_open): Prepend "tmp-" instead of appending "-tmp", to create
- the temporary file name.
-
- * configure.in: Check for setmode.
- * configure: Regenerate.
-
-2000-05-24 Alan Modra <alan@linuxcare.com.au>
-
- * objdump.c (display_target_list): Close the bfd.
- (display_info_table): Likewise.
-
-2000-05-14 H.J. Lu (hjl@gnu.org)
-
- * objcopy.c (filter_symbols): Don't strip global symbols in
- relocatable object files.
-
-2000-05-14 Alan Modra <alan@linuxcare.com.au>
-
- * size.c (usage): Associate short options with corresponding long
- option to give a clue as to their function.
-
-2000-05-14 Philippe De Muyter <phdm@macqel.be>
-
- * size.c (main): Accept and ignore `-f' option.
-
-2000-05-13 Alan Modra <alan@linuxcare.com.au>
-
- * bucomm.h (gettext, dgettext, dcgettext, textdomain,
- bindtextdomain): Replace defines with those from intl/libgettext.h
- to quieten gcc warnings.
-
-2000-05-12 H.J. Lu <hjl@gnu.org>
-
- * nlmconv.c (temp_filename): Removed.
-
- * nlmconv.c (link_inputs): Use make_temp_file () instead of
- choose_temp_base ().
- * objdump.c (display_target_list): Likewise.
- (display_info_table): Likewise.
-
-2000-05-08 Alan Modra <alan@linuxcare.com.au>
-
- * objcopy.c (setup_section): Add const and gettext calls for err.
+2004-01-12 Jakub Jelinek <jakub@redhat.com>
-2000-05-02 H.J. Lu <hjl@gnu.org>
+ * objcopy.c: Include elf-bfd.h.
+ (is_strip_section): Don't strip debugging sections if
+ STRIP_NONDEBUG.
+ (setup_section): If STRIP_NONDEBUG make SEC_ALLOC sections
+ ~(SEC_LOAD | SEC_HAS_CONTENTS) and on ELF targets also SHT_NOBITS.
- * readelf.c (get_osabi_name): Handle ELFOSABI_NONE instead of
- ELFOSABI_SYSV. Also handle ELFOSABI_NETBSD, ELFOSABI_HURD,
- ELFOSABI_SOLARIS, ELFOSABI_MONTEREY, ELFOSABI_IRIX,
- ELFOSABI_FREEBSD, ELFOSABI_TRU64, ELFOSABI_MODESTO
- and ELFOSABI_OPENBSD.
+ * objcopy.c (copy_section): Free relpp if relcount == 0.
-2000-05-02 Kazu Hirata <kazu@hxi.com>
+2004-01-12 Ian Lance Taylor <ian@wasabisystems.com>
- * coffgrok.c: Add ATTRIBUTE_UNUSED as appropriate.
- * srconv.c: Likewise.
- * sysdump.c: Likewise.
+ * stabs.c (parse_stab_argtypes): Handle g++ ABI version 3 names.
+ (stab_demangle_argtypes): Likewise.
+ (stab_demangle_v3_argtypes): New static function.
+ (stab_demangle_v3_arg): New static function.
-2000-04-23 Denis Chertykov <denisc@overta.ru>
+2004-01-12 Nick Clifton <nickc@redhat.com>
- * readelf.c (guess_is_rela): AVR uses RELA relocations.
- (get_machine_name): machine name for EM_AVR added.
+ * objcopy.c (copy_object): Make the function boolean, returning
+ FALSE upon failure.
+ (copy_archive): Handle the return value from copy_object.
+ (copy_file): Likewise.
-2000-04-21 Richard Henderson <rth@cygnus.com>
- David Mosberger <davidm@hpl.hp.com>
+2004-01-07 Nick Clifton <nickc@redhat.com>
- * Makefile.am (readelf.o): Add elf/ia64.h.
- * Makefile.in: Rebuild.
- * readelf.c: Include elf/ia64.h.
- (guess_is_rela, dump_relocations): Handle EM_IA_64.
-
-2000-04-17 Timothy Wall <twall@cygnus.com>
-
- * objdump.c (disassemble_data): Set octets per byte *after*
- resolving arch/mach for binary files.
-
-2000-04-14 Michael Sokolov <msokolov@ivan.Harhan.ORG>
-
- * arlex.l: Add directives to increase lex buffer size.
-
- * objdump.c, readelf.c: Don't include strarg.h or varargs.h. They are
- already included by bucomm.h.
-
-2000-04-10 Philippe De Muyter <phdm@macqel.be>
-
- * readelf.c (dynamic_segment_mips_val): Call `sprintf', not
- `strftime' since strftime is not available on all systems.
- (process_mips_specific): Ditto.
-
-2000-04-07 Andrew Cagney <cagney@b1.cygnus.com>
-
- * configure.in (WARN_CFLAGS): Set to -W -Wall by default. Add
- --enable-build-warnings option.
- * Makefile.am (AM_CFLAGS, WARN_CFLAGS): Add definitions.
- * Makefile.in, configure: Re-generate.
-
-2000-04-06 Alan Modra <alan@linuxcare.com.au>
-
- * addr2line.c: Update copyright.
- * objcopy.1: Likewise, and title.
- * strings.1: Likewise.
-
- * version.c (print_version): Add 2000.
-
- * rddbg.c (read_section_stabs_debugging_info): Don't use
- bfd_size_type for strx to avoid printf problems if BFD64.
-
- * bucomm.c: (report): Remove `static'.
- Move inclusion of stdarg.h/vararg.h from here.
- * bucomm.h: To here.
- (CONST): Change all occurences to const.
- (report): Declare it.
- (bfd_fatal): Add ATTRIBUTE_NORETURN.
- (fatal): Add ATTRIBUTE_PRINTF_1 ATTRIBUTE_NORETURN.
- (non_fatal): Add ATTRIBUTE_PRINTF_1.
-
- * ar.c (main): Use fatal or non_fatal instead of fprintf.
- Correct a typo in an error message.
- (do_quick_append): Use non_fatal instead of fprintf.
- (move_members): Use fatal instead of fprintf, exit.
- * coffdump.c (main): Same here.
-
- * dlltool.c (display): Delete.
- (warn): Delete.
- (inform): Use `report' instead of `display'.
- (rvaafter): Remove trailing \n from fatal error msg.
- (rvabefore): Ditto.
- (asm_prefix): Ditto.
- (yyerror): Replace `warn' with `non_fatal', and remove \n.
- (def_name): Likewise.
- (run): Likewise.
- (scan_all_symbols): Likewise.
- (gen_lib_file): Likewise.
- (def_library): Likewise. Remove extra program_name too.
- (run): Remove \n from inform strings.
- (scan_drectve_symbols): Likewise.
- (add_excludes): Likewise.
- (scan_open_obj_file): Likewise.
- (gen_exp_file): Likewise.
- (gen_lib_file): Likewise.
- (process_duplicates): Likewise.
-
- * Makefile.am (dllwrap_SOURCES): Add version.c.
- * dllwrap.c (program_version): Delete.
- (print_version): Delete.
- (display): Always print trailing \n.
- (warn): New.
- (delete_temp_files): Use warn instead of fprintf. Use gettext.
- (run): Here too.
- (main): And here.
- (usage): gettext'ify.
- (long_options): Add missing initialisers.
-
- * nlmconv.c (main): Use fatal/non_fatal instead of fprintf.
- (select_output_format): Likewise.
- (powerpc_mangle_relocs): Likewise.
- (link_inputs): Likewise.
-
- * nm.c (set_print_radix): Use fatal instead of fprintf, exit.
- (set_output_format): Likewise.
- (main): Use non_fatal instead of fprintf.
- (display_rel_file): Likewise.
-
- * objdump.c (slurp_symtab): Use non_fatal instead of fprintf.
- (slurp_dynamic_symtab): Same here.
- (disassemble_data): And here.
- (read_section_stabs): And here.
- (read_section_stabs): And here.
- (dump_bfd): And here.
- (main): And here.
- (objdump_sprintf): Use fatal instead of fprintf, exit.
- (disassemble_data): Same here.
-
- * rdcoff.c (parse_coff_type): Use non_fatal instead of fprintf.
- (parse_coff_struct_type): Same here.
- (parse_coff_enum_type): And here.
- (parse_coff): And here.
- * rddbg.c (read_debugging_info): And here.
- * size.c (main): And here.
- * windres.c (format_from_name): And here.
- * wrstabs.c (stab_write_symbol): Here too.
- (write_stabs_in_sections_debugging_info): And here.
- (stab_int_type): And here.
- (stab_struct_field): And here.
- (stab_typdef): And here.
-
- * rescoff.c (read_coff_rsrc): Use fatal instead of fprintf, exit.
- * srconv.c (main): Same here.
- * strings.c (main): And here.
- (integer_arg): And here.
- * sysdump.c (main): And here.
-
-2000-04-06 Timothy Wall <twall@cygnus.com>
-
- * objdump.c (dump_section_header): Print CLINK and BLOCK flags.
-
-2000-04-06 Jason Merrill <jason@yorick.cygnus.com>
-
- * readelf.c (decode_location_expression): Loop through multiple
- operations.
- (read_and_display_attr): Pass in length.
-
- * readelf.c (read_and_display_attr): Add CU offset to references.
- (display_debug_info): Pass it in.
-
-2000-04-06 Nick Clifton <nickc@cygnus.com>
-
- * readelf.c (decode_ARM_machine_flags): New function.
- (get_machine_flags): Call decode_ARM_machine_flags for ARM
- targets.
-
- (get_machine_name): Catch EM_AVR
-
-2000-04-05 Alan Modra <alan@linuxcare.com.au>
-
- * binutils.texi: Remove optional `=' from long options that have
- an `=' in the argument.
- * objcopy.1: Here too. Remove extra space on discard-all.
-
- * binutils.texi (objcopy): Mention --redefine-sym.
- * objcopy.1: Here too.
- * NEWS: And here.
-
- * objcopy.c (parse_flags): Split off flag names from error message
- gettext as they are not translated.
- (copy_main): Similarly split off option name for --add-section,
- --set-section-flags, --change-section-vma, --change-section-lma
- error messages.
- Some white space changes.
-
- from Matthew Benjamin <matt@linuxbox.nu>
- * objcopy.c (struct redefine_node): New.
- (redefine_sym_list): New.
- (redefine_list_append): New.
- (lookup_sym_redefinition): New.
- (OPTION_REDEFINE_SYM): New.
- (copy_options): Add --redefine-sym option.
- (copy_usage): Mention it.
- (filter_symbols): Rename symbols on redefine_sym_list.
- (copy_object): Call filter_symbols if redefine_sym_list != NULL.
- (copy_main): Handle OPTION_REDEFINE_SYM.
-
-2000-04-04 H.J. Lu <hjl@gnu.org>
-
- * readelf.c (process_symbol_table): Correctly read in symbol
- versioning information.
-
-2000-04-04 Alan Modra <alan@linuxcare.com.au>
-
- * po/binutils.pot: Regenerate.
-
- * addr2line.c (usage): Restore translated part of bug string.
- * ar.c (usage): Likewise.
- * nlmconv.c (show_usage): Likewise.
- * nm.c (usage): Likewise.
- * objcopy.c (copy_usage): Likewise.
- (strip_usage): Likewise.
- * objdump.c (usage): Likewise.
- * readelf.c (usage): Likewise.
- * size.c (usage): Likewise.
- * strings.c (usage): Likewise.
- * windres.c (usage): Likewise.
-
- * Makefile.am (MKDEP): Use gcc -MM rather than mkdep.
- (DEP): Quote when passing vars to sub-make. Add warning
- message to end.
- (DEP1): Rewrite for "gcc -MM".
- (CLEANFILES): Add DEP2.
- Update dependencies.
- * Makefile.in: Regenerate.
-
-2000-04-04 H.J. Lu <hjl@gnu.org>
-
- * Makefile.am (GENERATED_HFILES): Add rcparse.h
- (arparse.h): Depend on arparse.c
- (defparse.h, nlmheader.h, rcparse.h, sysinfo.h): Similarly.
-
-2000-04-03 H.J. Lu (hjl@gnu.org)
-
- * size.c (usage): Use REPORT_BUGS_TO.
-
-2000-04-03 Alan Modra <alan@linuxcare.com.au>
-
- * bucomm.h: #include "bin-bugs.h"
- * addr2line.c (usage): Use REPORT_BUGS_TO.
- * ar.c (usage): Likewise.
- * nlmconv.c (show_usage): Likewise.
- * nm.c (usage): Likewise.
- (OPTION_TARGET): Define.
- (long_options): Use OPTION_TARGET rather than 200.
- (main): Likewise.
-
- * objcopy.c (copy_usage): Use REPORT_BUGS_TO.
- (strip_usage): Likewise.
- * objdump.c (usage): Likewise.
- * readelf.c (usage): Likewise.
- * strings.c (usage): Likewise.
- * windres.c (usage): Likewise.
-
-2000-03-31 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * readelf.c: Include sys/types.h before sys/stat.h for ultrix.
-
-2000-03-27 Nick Clifton <nickc@cygnus.com>
-
- * rddbg.c (read_section_stabs_debugging_info): Catch out of range
- string offsets in corrupt stabs entries.
-
-2000-03-27 Alan Modra <alan@linuxcare.com.au>
-
- * readelf.c: Include elf/avr.h
- (dump_relocations): Add EM_AVR case.
-
-2000-03-09 Tim Waugh <twaugh@redhat.com>
-
- * strings.1: Correct '-bytes' to '--bytes'.
-
-2000-03-08 H.J. Lu <hjl@gnu.org>
-
- * Makefile.am (install-exec-local): Depend on
- install-binPROGRAMS for parallel make.
- * Makefile.in: Regenerated.
-
-2000-02-27 Ian Lance Taylor <ian@zembu.com>
-
- From Brad Lucier <lucier@math.purdue.edu>:
- * readelf.c (process_dynamic_segment): Add cast to make sure
- argument to %* is int.
+ * readelf.c (find_section): New function. Locates a named
+ section.
+ (get_debug_line_pointer_sizes): New function: Initialises the
+ debug_line_pointer_sizes array.
+ (display_debug_lines): Call get_debug_line_pointer_sizes.
+ (display_debug_loc): Likewise.
+ (load_debug_loc): Use find_section.
+ (load_debug_str): Likewise.
+ (display_debug_info): Likewise.
+ (prescan_debug_info): Delete.
+ (debug_displays): Remove prescan field.
+ (process_section_contents): Do not perform prescans.
-2000-02-25 H.J. Lu <hjl@gnu.org>
+2004-01-03 Alan Modra <amodra@bigpond.net.au>
- * configure.in (AC_SEARCH_LIBS): Pass m, not -lm.
+ * objcopy.c (filter_bytes): Delete. Move code to..
+ (copy_section): ..here. Simplify size adjustment. Divide
+ section lma by interleave.
-2000-02-24 Nick Clifton <nickc@cygnus.com>
+2004-01-02 Nick Clifton <nickc@redhat.com>
- * configure.in: Add arm-wince, mips-pe and sh-pe targets.
+ * po/ru.po: New file: Russian translation.
+ * configure.in (ALL_LINGUAS): Add ru
* configure: Regenerate.
- * dlltool.c: Add support for sh-pe and mips-pe targets.
- * rescoff.c: Add support for sh-pe and mips-pe targets.
-
-2000-02-23 H.J. Lu <hjl@gnu.org>
-
- * readelf.c (get_osabi_name): Handle ELFOSABI_LINUX.
-
-2000-02-22 Nick Clifton <nickc@cygnus.com>
-
- * readelf.c (process_symbol_table): Remove use of ELF_ST_OTHER.
-
-2000-02-22 Ian Lance Taylor <ian@zembu.com>
-
- From Brad Lucier <lucier@math.purdue.edu>:
- * readelf.c (process_version_sections): Add casts to make sure
- argument to %* is an int.
- (process_mips_specific): Add casts to make printf arguments match
- format.
-
-2000-02-21 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * objdump.c (dump_section_header): Change `opb' to unsigned.
- (find_symbol_for_address): Same here.
- (disassemble_data): And here. Change `addr_offset',
- `stop_offset', `nextstop_offset' to unsigned long.
- (dump_data): Change opb to unsigned.
-
-2000-02-18 Frank Ch. Eigler <fche@redhat.com>
-
- * resrc.c: Remove unmatched #if for cygwin.
-
-2000-02-14 Fernando Nasser <fnasser@totem.to.cygnus.com>
-
- * binutils.texi: Document the change of flavor name from atpcs-special
- to special-atpcs to prevent name conflict in gdb.
-
-2000-02-08 Timothy Wall <twall@redhat.com>
-
- * objdump.c (show_line): Fix bug preventing printing of the very
- first line (line zero) of a file when interlisting source and
- assembly. Added option to print entire context from start of file
- when the first line from that file is encountered.
-
-2000-02-03 Timothy Wall <twall@redhat.com>
-
- * objdump.c (dump_section_header, find_symbol_for_address,
- show_line, disassemble_bytes, disassemble_data, dump_data):
- distinguish between octets and bytes.
-
-2000-01-27 Thomas de Lellis <tdel@windriver.com>
-
- * nm.c (print_symbol_info_bsd): Use bfd_is_undefined_symclass to
- check to unresolved symbols.
- (print_symbol_info_sysv): Ditto.
- (print_symbol_info_posix): Ditto.
-
- * binutils.texi: Document new 'V' symclass flag for nm.
-
-2000-01-27 Nick Clifton <nickc@redhat.com>
-
- * binutils.texi (objdump): Document new ARM specific
- disassembler options.
-
- * objdump.c (usage): Call disassembler_usage().
-
-2000-01-27 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * readelf.c (get_dynamic_flags): Return buff.
- (process_dynamic_segment): Don't pass error strings to printf
- as format arg.
- (read_and_display_attr): Use lx and ld to print longs.
- (process_corefile_note_segment): Cast bfd_vma to unsigned long
- before printing.
- Update copyright.
-
-2000-01-17 Nick Clifton <nickc@cygnus.com>
-
- * readelf.c (get_osabi_name): Recognise ELFOSABI_ARM.
-
-2000-01-15 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * debug.c (debug_name_type): Return DEBUG_TYPE_NULL rather than
- false.
- (debug_tag_type): Here too.
- * ieee.c (ieee_builtin_type): And here.
- * stabs.c (parse_stab_type, parse_stab_array_type): And here.
-
-2000-01-13 Nick Clifton <nickc@cygnus.com>
-
- * readelf.c (get_machine_name): Change EM_S370 to return "IBM
- System/370".
-
-2000-01-11 Nick Clifton <nickc@cygnus.com>
-
- * readelf.c (get_dynamic_type): Remove DT_ENCODING.
-
-2000-01-10 Nick Clifton <nickc@cygnus.com>
-
- * readelf.c (get_note_type): Display NT_WIN32PSTATUS notes.
-
-2000-01-07 Mumit Khan <khan@xraylith.wisc.edu>
-
- * windres.c (long_options): Add --use-temp-file and
- --no-use-temp-file options.
- (usage): Document.
- (main): Handle.
-
- * windres.h: Update read_rc_file prototype.
-
- * resrc.c (cpp_temp_file): New static variable.
- (istream_type): New static variable.
- (close_pipe): Delete function.
- (run_cmd): New static function.
- (open_input_stream): New static function.
- (close_input_stream): New static function.
- (look_for_default): Handle DOS directory separator. Use
- open_input_stream instead of popen.
- (read_rc_file): Likewise.
-
- * binutils.texi: Document --use-temp-file, --no-use-temp-file
- options.
-
-2000-01-04 Mumit Khan <khan@xraylith.wisc.edu>
-
- * dlltool.c (create_compat_implib): New variable.
- (gen_exp_file): Use.
- (make_one_lib_file): Use.
- (long_options): Add --compat-implib option.
- (usage): Handle.
- (main): Handle.
-
- * dllwrap.c (enum target_type): Rename MINGW32_TARGET to MINGW_TARGET.
- (main): Use. Don't look for "32" in cygwin and mingw target names.
-
-2000-01-03 Nick Clifton <nickc@cygnus.com>
-
- * binutils.texi: Document new, ARM specific disassembler
- command line switch "-M force-thumb".
-
-For older changes see ChangeLog-9899
+For older changes see ChangeLog-0203
Local Variables:
mode: change-log
diff --git a/contrib/binutils/binutils/ChangeLog-0001 b/contrib/binutils/binutils/ChangeLog-0001
new file mode 100644
index 0000000..9d14894
--- /dev/null
+++ b/contrib/binutils/binutils/ChangeLog-0001
@@ -0,0 +1,2060 @@
+2001-12-20 Julian v. Bock <julian@wongr.net>
+
+ * readelf.c (print_symbol): New function: Print a formatted symbol
+ name. If --wide is specified do not truncate it.
+ (dump_relocations): Use print_symbol() to print symbol names.
+ (process_symbol_table): Likewise.
+ (process_syminfo): Likewise.
+ (process_mips_specific): Likewise.
+ (usage): Document new feature of --wide switch.
+ * doc/binutils.texi (objdump): Document additional behaviour of
+ --wide.
+
+2001-12-18 Michael Snyder <msnyder@redhat.com>
+
+ * objcopy.c (copy_file): Accept corefiles (format bfd_core).
+ (copy_object): Don't set the start address or flags of a core file.
+ (copy_section): Don't relocate a core file. Don't copy contents
+ if the input section has the contents flag set, but the output
+ section does not (which happens with the fake 'note' pseudo-
+ sections that BFD creates for corefiles).
+
+2001-12-18 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * readelf.c (get_machine_flags): Recognize header flags for ABI and
+ ASE extensions. More robust code for ISA checking. Ignore empty fields
+ in header flags for GNU extensions.
+
+2001-12-18 Alan Modra <amodra@bigpond.net.au>
+
+ * objcopy.c (copy_archive): Set output bfd format outside the loop.
+
+2001-12-18 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/ja.po: Import from translation project.
+ * configure.in (ALL_LINGUAS): Add ja.
+ * configure: Regenerate.
+
+2001-12-18 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * addr2line.c (main): Protoype.
+ * ar.c (main): Protoype.
+ * nm.c (main): Protoype.
+ * objcopy.c (main): Protoype.
+ * objdump.c (main): Protoype.
+ * size.c (main): Protoype.
+ * strings.c (main): Protoype.
+
+2001-12-17 Alan Modra <amodra@bigpond.net.au>
+
+ * readelf.c (symtab_shndx_hdr): New global.
+ (SECTION_HEADER_INDEX): Define.
+ (SECTION_HEADER_NUM): Define.
+ (SECTION_HEADER): Define.
+ (GET_ELF_SYMBOLS): Pass two params rather than three.
+ (get_32bit_elf_symbols): Take file and section args. Read and
+ use SHT_SYMTAB_SHNDX.
+ (get_64bit_elf_symbols): Likewise.
+ (dump_relocations): Use SECTION_HEADER to index "section_headers".
+ (process_section_headers): Likewise. Use SECTION_HEADER_NUM too.
+ Remember symtab_shdx_hdr.
+ (process_program_headers): Scan from index 1 for segment map.
+ (slurp_ia64_unwind_table): Use SECTION_HEADER to index
+ "section_headers".
+ (process_relocs): Likewise. Also adjust call to GET_ELF_SYMBOLS.
+ (process_unwind): Likewise.
+ (process_version_sections): Likewise.
+ (process_symbol_table): Likewise.
+ (display_debug_info): Likewise.
+ (process_dynamic_segment): Fake up a symtab section for changed
+ GET_ELF_SYMBOLS.
+ (get_symbol_index_type): Check SHN_LOOS before SHN_LORESERVE.
+ (process_program_headers): Kill signed/unsigned warning.
+ (load_debug_str): Likewise.
+ (display_debug_info): Likewise.
+
+2001-12-13 Jakub Jelinek <jakub@redhat.com>
+
+ * readelf.c (get_segment_type): Support PT_GNU_EH_FRAME.
+
+2001-12-11 Alan Modra <amodra@bigpond.net.au>
+
+ * readelf.c (process_file_header): Print extended e_shnum and
+ e_shdtrndx values. Set elf_header values for same.
+ (get_32bit_section_headers): Add "num" arg to read "num" headers.
+ (get_64bit_section_headers): Likewise.
+ (process_section_headers): Update calls.
+ (get_file_header): Call get_32bit_section_headers or 64bit variant.
+
+2001-12-10 Jakub Jelinek <jakub@redhat.com>
+
+ * objcopy.c (setup_section): Copy entsize.
+
+2001-12-07 Geoffrey Keating <geoffk@redhat.com>
+
+ * readelf.c (guess_is_rela): Add support for stormy16.
+ (dump_relocations): Likewise.
+ (get_machine_name): Likewise.
+
+2001-12-05 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * dllwrap.c (main) Replace multiple strings describing a
+ single error with a single, newline escaped sentence to permit
+ better translation into foreign languages.
+
+ * readelf.c (get_elf_class): Remove internalionalisation of ELF
+ class names.
+
+2001-12-04 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * strings.c (get_char): Initialize value.
+
+2001-12-04 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * arlex.l: Silence compile warnings.
+ * arsup.h: Likewise. Fix formatting.
+
+2001-12-04 Jakub Jelinek <jakub@redhat.com>
+
+ * strings.c: Include config.h before bfd.h.
+ (file_off): New type.
+ (file_open): Define.
+ (print_strings): Use file_off instead of file_ptr. Print addresses
+ which don't fit into long correctly.
+ (get_char): Use file_off instead of file_ptr. Use getc_unlocked if
+ available.
+ (strings_file): Use file_off instead of file_ptr. Use file_open.
+ * configure.in: Check for getc_unlocked.
+ Check for fopen64 and whether _LARGEFILE64_SOURCE needs to
+ be defined for it.
+ * configure: Rebuilt.
+ * config.h.in: Rebuilt.
+
+2001-11-29 H.J. Lu <hjl@gnu.org>
+
+ * bucomm.c (make_tempname): Revert the changes made on
+ 2001-11-14 and 2001-11-12. They won't work with directories.
+
+2001-11-23 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * binutils/Makefile.am (check-DEJAGNU): Pass CC_FOR_TARGET and
+ CFLAGS_FOR_TARGET to runtest in environment.
+ * Makefile.in: Rebuild.
+ * doc/Makefile.in: Rebuild.
+
+2001-11-28 Mike Stump <mrs@wrs.com>
+
+ * objcopy.c (setup_section): Preserve SEC_RELOC when
+ --set-section-flags is used.
+
+2001-11-19 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * readelf.c (do_debug_str): New variable.
+ (display_debug_str): New function: Display the contents of a
+ .debug_str section.
+ (load_debug_str): New function: Load in the contents of a
+ .debug_str section.
+ (free_debug_str): New function: Free the memory used by
+ load_debug_str().
+ (fetch_indirect_string): Retrieve a string from the .debug_str
+ section.
+ (usage): Add -ws.
+ (parse_args): Accept -ws.
+ (process_section_headers): Allow the display of the .debug_str
+ section.
+ (read_and_display_attr_value): Use fetch_indirect_string. Show
+ offset into .debug_str section.
+ (display_debug_info): Use load_debug_str and free_debug_str.
+ (debug_displays): Add .debug_str.
+ * doc/binutils.texi: Document -ws.
+
+2001-11-19 Andreas Jaeger <aj@suse.de>
+
+ * testsuite/binutils-all/objdump.exp: Add x86-64.
+
+2001-11-15 Andreas Schwab <schwab@suse.de>
+
+ * readelf.c: Fix warnings without terminating newline.
+
+2001-11-15 Alan Modra <amodra@bigpond.net.au>
+
+ * doc/binutils.texi (objdump): Document ppc -M options.
+
+2001-11-14 Andreas Jaeger <aj@suse.de>
+
+ * doc/binutils.texi (objdump): Fix description to use x86-64.
+
+2001-11-14 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * bucomm.c (make_tempname): Use mkstemps instead of mkstemp, since
+ not all systems provide mkstemp.
+
+2001-11-14 Alan Modra <amodra@bigpond.net.au>
+
+ * doc/binutils.texi (objdump): Document x86 -M options.
+
+2001-11-13 Keith Walker <keith.walker@arm.com>
+
+ * readelf.c (read_and_display_attr_value): New function to
+ handle DW_FORM_indirect.
+ (read_and_display_attr): Use it.
+
+2001-11-13 Geoffrey Keating <geoffk@redhat.com>
+
+ * readelf.c (display_debug_lines): Deal with unknown standard
+ opcodes. Handle DW_LNS_set_prologue_end, DW_LNS_set_epilogue_begin,
+ DW_LNS_set_isa.
+
+2001-11-13 Timothy Wall <twall@alum.mit.edu>
+
+ * MAINTAINERS: Add self as tic54x maintainer. This target
+ includes the IBM C54XDSP clone.
+
+2001-11-12 * Steven J. Hill <sjhill@realitydiluted.com>
+
+ * bucomm.c (make_tempname): Use mkstemp in place of mktemp.
+
+2001-11-09 Jeffrey A Law (law@cygnus.com)
+
+ * unwind-ia64.c (unw_print_brmask): Fix ISO C portability glitch.
+ (unw_print_grmask, unw_print_frmask, unw_print_abreg): Likewise.
+ (unw_print_xyreg, unw_decode_x1, unw_decode_x2): Likewise.
+ (unw_decode_x3, unw_decode_r1, unw_decode_r2): Likewise.
+ (unw_decode_r3, unw_decode_p1, unw_decode_p2_p5): Likewise.
+ (unw_decode_p6, unw_decode_p7_p10, unw_decode_b1): Likewise.
+ (unw_decode_b2, unw_decode_b3_b4): Likewise.
+
+ * readelf.c (get_elf_class): Fix ISO portability glitch.
+ (get_data_encoding, get_osabi_name, request_dump): Likewise.
+
+2001-11-07 Jakub Jelinek <jakub@redhat.com>
+
+ * readelf.c (debug_str, debug_str_size): New.
+ (display_debug_abbrev): If no abbrevs were read, skip the CU.
+ Call free_abbrevs.
+ (read_and_display_addr): Handle DW_FORM_strp.
+ (display_debug_info): Read .debug_str section if present,
+ so that DW_FORM_strp can be handled.
+ Fix test for non-existant .debug_abbrev section.
+
+2001-11-05 Jakub Jelinek <jakub@redhat.com>
+
+ * arlex.l: Accept `\' in filenames. Patch by <earl_chew@agilent.com>.
+
+ * arsup.c (ar_open): Prepend tmp- to basename, not whole path.
+
+2001-11-05 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * MAINTAINERS: Add self as s390/s390x maintainer.
+
+2001-11-02 Tom Rix <trix@bluey.cygnus.com>
+
+ * MAINTAINERS: Add self as PPC XCOFF maintainer.
+
+2001-11-02 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * configure.in (ALL_LINGUAS): Add "fr" and "tr".
+ * configure: Regernate.
+ * po/fr.po: New file.
+ * po/tr.po: New file.
+
+2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * MAINTAINERS: Add self as MMIX port maintainer.
+ * readelf.c: Include elf/mmix.h.
+ (guess_is_rela): MMIX is RELA.
+ (dump_relocations): Handle MMIX relocations.
+ * Makefile.am: Regenerate dependencies.
+ * Makefile.in: Regenerate.
+
+2001-10-13 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * readelf.c (parse_args): Handle multiple options to the -w
+ switch.
+
+2001-10-12 Jakub Jelinek <jakub@redhat.com>
+
+ * readelf.c (get_section_type_name): Don't print SHT_ prefix for
+ LOPROC, LOOS and LOUSER.
+
+2001-10-11 J"orn Rennecke <amylaar@onetel.net.uk>
+
+ * MAINTAINERS: Update my email address.
+
+2001-10-03 Alan Modra <amodra@bigpond.net.au>
+
+ * doc/Makefile.in: Regenerate.
+ * configure: Regenerate.
+
+2001-10-02 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * readelf.c (display_debug_line, display_debug_pubnames,
+ display_debug_info, display_debug_frames): Detect and warn
+ about 64-bit format entries.
+ (display_debug_aranges): Reword 64-bit warning.
+ (debug_displays): Add .debug_pubtypes as a known, but not yet
+ supported, debug section.
+
+2001-10-02 Alan Modra <amodra@bigpond.net.au>
+
+ * coffdump.c (PROGRAM_VERSION): Delete.
+ (main <'V'>): Call print_version.
+ * srconv.c: Likewise.
+ * sysdump.c: Likewise.
+ * version.c (program_version): Remove.
+ (print_version): Use BFD_VERSION_STRING. Just print the current
+ year in copyright message.
+ * addr2line.c (program_version): Remove unused declaration.
+ * objdump.c (display_target_tables): Use BFD_VERSION_STRING in
+ place of BFD_VERSION.
+ * Makefile.am (Makefile): Depend on bfd/configure.in.
+ (cplus-dem.o): Depend on Makefile.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2001-10-01 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * readelf.c (display_debug_aranges): Detect and warn about DWARF64
+ format .debug_arange sections.
+ (main): Add missing prototype.
+
+2001-09-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * Makefile.am: Update dependencies with "make dep-am".
+ * Makefile.in: Regenerate.
+
+2001-09-28 Richard Henderson <rth@redhat.com>
+
+ * objdump.c (dump_section_header): Dump SEC_ARCH_BIT_0.
+
+2001-09-26 Alan Modra <amodra@bigpond.net.au>
+
+ * bucomm.c (fatal): Define using VPARAMS, VA_OPEN, VA_FIXEDARG,
+ VA_CLOSE.
+ (non_fatal): Likewise.
+ * objdump.c (objdump_sprintf): Likewise.
+ * readelf.c (error): Likewise.
+ (warn): Likewise.
+
+2001-09-25 Jakub Jelinek <jakub@redhat.com>
+
+ * readelf.c (do_wide): New.
+ (options): Add --wide.
+ (usage, parse_args): Likewise.
+ (process_program_headers): Put each segment on a single line if
+ --wide is given.
+ (process_section_headers): Put each section on a single line if
+ --wide is given.
+ * doc/binutils.texi: Document it.
+ * NEWS: Likewise.
+
+2001-09-25 Alan Modra <amodra@bigpond.net.au>
+
+ * readelf.c (print_vma): Print 8 digits of low hex value.
+
+2001-09-24 Andreas Jaeger <aj@suse.de>
+
+ * nlmconv.c: Fix warnings about unused attributes and function
+ prototypes.
+
+ * strings.c: Add prototype for get_char.
+
+2000-09-19 H.J. Lu <hjl@gnu.org>
+
+ * doc/Makefile.am ($(DEMANGLER_NAME).1): Try cxxfilt.man and
+ $(srcdir)/cxxfilt.man.
+ * doc/Makefile.in: Rebuild.
+
+2001-09-19 Alan Modra <amodra@bigpond.net.au>
+
+ * objcopy.c (copy_main): Correct rename-section string parsing.
+ Consolidate new_name parsing, and error messages.
+
+2001-09-18 Bruno Haible <haible@clisp.cons.org>
+
+ * addr2line.c: Don't include <ctype.h>.
+ (main): For gettext, also set the LC_CTYPE locate facet.
+ * ar.c (main): Likewise.
+ * coffdump.c (main): Likewise.
+ * dlltool.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (main): For gettext, also set the LC_CTYPE locate facet.
+ Use ISALNUM instead of isalpha/isdigit.
+ * dllwrap.c: Don't include <ctype.h>.
+ (main): For gettext, also set the LC_CTYPE locate facet.
+ * nlmconv.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (main): For gettext, also set the LC_CTYPE locate facet.
+ Use TOUPPER instead of islower/toupper.
+ * nlmheader.y: Include "safe-ctype.h" instead of <ctype.h>.
+ (yylex): Use ISSPACE/ISALNUM instead of isspace/isalnum.
+ Use TOUPPER instead of islower/toupper.
+ * nm.c (main): For gettext, also set the LC_CTYPE locate facet.
+ * objcopy.c (main): Likewise.
+ * objdump.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (disassemble_bytes): Use ISPRINT instead of isprint.
+ (dump_section_stabs): Use ISDIGIT instead of isdigit.
+ (dump_data): Use ISPRINT instead of isprint.
+ (main): For gettext, also set the LC_CTYPE locate facet.
+ * rclex.l: Include "safe-ctype.h" instead of <ctype.h>.
+ (cpp_line, handle_quotes): Use ISSPACE instead of isspace.
+ * rcparse.y: Include "safe-ctype.h" instead of <ctype.h>.
+ Use TOUPPER instead of islower/toupper.
+ * readelf.c (main): For gettext, also set the LC_CTYPE locate facet.
+ * resrc.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (write_rc_accelerators): Use ISPRINT instead of isprint.
+ (write_rc_rcdata): Likewise.
+ * size.c (main): For gettext, also set the LC_CTYPE locate facet.
+ * srconv.c (main): Likewise.
+ * stabs.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (parse_number): Use ISDIGIT/ISUPPER/ISLOWER instead of
+ isdigit/isupper/islower.
+ (parse_stab_string, parse_stab_type, parse_stab_argtypes,
+ parse_stab_array_type, stab_demangle_count, stab_demangle_get_count,
+ stab_demangle_prefix, stab_demangle_qualified,
+ stab_demangle_template, stab_demangle_type,
+ stab_demangle_fund_type): Use ISDIGIT instead of isdigit.
+ * strings.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (isgraphic): Use ISPRINT instead of isascii/isprint.
+ (main): Remove HAVE_LC_MESSAGES dependency.
+ * sysdump.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (pbarray): Use ISPRINT instead of isprint.
+ (main): For gettext, also set the LC_CTYPE locate facet.
+ * windres.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (format_from_filename): Use ISPRINT instead of isprint.
+ (main): For gettext, also set the LC_CTYPE locate facet.
+ * winduni.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (unicode_print): Use ISPRINT instead of isprint.
+ * wrstabs.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (stab_variable): Use ISDIGIT instead of isdigit.
+
+2001-09-18 Alan Modra <amodra@bigpond.net.au>
+
+ * ar.c (print_contents): Cast args of bfd_seek to the right types.
+ Replace bfd_read call with call to bfd_bread.
+ (extract_file): Likewise.
+
+ * objdump.c (dump_section_header): Cast section->filepos to
+ unsigned long to suit printf format string.
+ * readelf.c (process_section_headers): Similarly for sh_offset.
+ (process_unwind): Likewise.
+
+2001-09-14 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * strings.c (encoding, encoding_bytes): New variables.
+ (long_options): Add --encoding.
+ (main): Accept -e and --encoding.
+ (get_char): New function. Read a, possibly wide, character from
+ the input stream.
+ (print_strings): Use get_char().
+ (usage): Document new command line option.
+ * doc/binutils.texi: Document new command line option.
+ * NEWS: Announce new command line option.
+
+2001-09-12 Alexandre Oliva <aoliva@redhat.com>
+
+ * readelf.c (guess_is_rela, dump_relocations, get_machine_name,
+ get_machine_flags): Added EM_M32R, EM_D10V, EM_V850, EM_D30V,
+ EM_MN10200, EM_MN10300, EM_FR30, EM_AVR_OLD and EM_PJ_OLD.
+ Removed EM_CYGNUS_ARC.
+
+2001-09-04 Jeffrey A Law (law@cygnus.com)
+
+ * readelf.c: Include elf/h8 for H8 series definitions.
+ (guess_is_rela): H8 series if RELA.
+ (dump_relocations): Handle H8 series relocations.
+
+2001-08-31 Eric Christopher <echristo@redhat.com>
+
+ * readelf.c (get_machine_flags): Remove E_MIPS_MACH_MIPS32_4K.
+
+2001-08-29 Peter Targett <peter.targett@arccores.com>
+
+ * MAINTAINERS: Include ARC Maintainer.
+
+2001-08-29 Ben Elliston <bje@redhat.com>
+
+ * stabs.c (stab_demangle_template): Initialise s4.
+
+2001-08-27 Alan Modra <amodra@bigpond.net.au>
+
+ * readelf.c (dump_relocations): Recognise EM_PPC64.
+
+2001-08-26 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * readelf.c (get_machine_flags): Add detection of EF_MIPS_32BITMODE.
+
+2001-08-25 H.J. Lu <hjl@gnu.org>
+
+ * nm.c (print_width): New.
+ (display_rel_file): Set `print_width' according to
+ bfd_sprintf_vma.
+ (print_symbol_info_bsd): Check `print_width' instead of BFD64.
+
+2001-08-24 Alexandre Oliva <aoliva@redhat.com>
+
+ * objcopy.c (use_alt_mach_code): New variable.
+ (OPTION_ALT_MACH_CODE): Define.
+ (copy_options): Added --alt-machine-code.
+ (copy_main): Handle it.
+ (copy_object): Switch to alternate machine code if requested.
+ * doc/binutils.texi: Document new option.
+ * NEWS: Likewise.
+
+2001-08-22 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * readelf.c (get_machine_flags): Add detection of EF_MIPS_UCODE.
+
+2001-08-21 H.J. Lu <hjl@gnu.org>
+
+ * readelf.c (dump_relocations): Support ELF64 on 32bit hosts.
+ (display_debug_info): Cast for 64bit hosts.
+ (display_debug_frames): Likewise.
+ (process_mips_specific): Likewise.
+
+2001-08-21 Andreas Jaeger <aj@suse.de>
+
+ * coffgrok.h: Add missing parameter for prototype of coff_grok.
+
+ * sysdump.c: Add missing prototypes.
+ * srconv.c: Likewise.
+ * unwind-ia64.c: Likewise.
+ * coffdump.c: Likewise.
+
+ * sysinfo.y: Print prototypes, include <ansidecl.h>.
+
+ * coffgrok.c: Add missing prototypes, include libiberty.h instead
+ of declaring xcalloc.
+
+2001-08-10 H.J. Lu <hjl@gnu.org>
+
+ * nm.c (print_value): Add one arg, bfd *.
+ (print_value): Replace fprintf_vma with bfd_fprintf_vma.
+ (print_symbol_info_bsd): Also pass `abfd' to print_value ().
+ (print_symbol_info_sysv): Likewise.
+ (print_symbol_info_posix): Likewise.
+
+ * objdump.c (dump_section_header): Replace printf_vma with
+ bfd_printf_vma.
+ (print_section_stabs): Likewise.
+ (dump_bfd_header): Likewise.
+ (objdump_print_value): Replace sprintf_vma with
+ bfd_sprintf_vma.
+ (disassemble_bytes): Likewise.
+ (dump_reloc_set): Likewise.
+
+2001-08-10 Andreas Jaeger <aj@suse.de>
+
+ * configure.in: Add -Wstrict-prototypes and -Wmissing-prototypes
+ to build warnings.
+ * configure: Regenerate.
+
+2001-08-09 Alan Modra <amodra@bigpond.net.au>
+
+ * readelf.c: Add missing prototypes.
+ * objdump.c: Likewise. Format existing prototypes.
+
+2001-08-08 Alexandre Oliva <aoliva@redhat.com>
+
+ * readelf.c (display_debug_info): Add to abbrev_offset the addend
+ of any RELA relocation for the abbrev_offset memory location that
+ refers to the .debug_abbrev section symbol.
+
+2001-08-07 H.J. Lu <hjl@gnu.org>
+
+ * readelf.c (process_file): Return 0 if OK, otherwise return 1.
+ (main): Return process_file ().
+
+2001-08-05 Philip Blundell <philb@gnu.org>
+
+ * doc/binutils.texi: Use "Thumb" not "THUMB".
+
+2001-08-03 John Healy <jhealy@redhat.com>
+
+ Patch suggested by Frank Eigler <fche@redhat.com>.
+ * objdump.c (disassemble_data): Fill in section member of the
+ disasm_info structure.
+
+2001-08-03 Tom Walsh <tom@cyberiansoftware.com>
+
+ * configure.in: Added --with-windres option.
+ * configure: Regenerated.
+
+2001-07-11 Stephane Carrez <Stephane.Carrez@worldnet.fr>
+
+ * doc/binutils.texi: Use @command{name} for commands;
+ use @option{-opt} for options; use @table @env for list of options;
+ remove spaces arround [ | ] in synopsis.
+
+ * doc/Makefile.am (POD2MAN): Use 'GNU Development Tools' for the
+ center title.
+
+2001-07-31 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * objcopy.c: Fix formatting.
+ (section_rename): New structure.
+ (OPTION_RENAME_SECTION): New switch.
+ (copy_usage): Document new switch.
+ (add_section_rename): New function: Add a node to the section
+ rename list.
+ (find_section_rename): New function: Find the new name and
+ flags for a section.
+ (setup_section): Call find_section_name to determine the name
+ of the output section.
+ (copy_main): Handle OPTION_RENAME_SECTION.
+ * binutils.texi: Document new switch.
+ * NEWS: Mention new switch.
+
+2001-07-30 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * README: Rename bug-gnu-utils@gcc.org to bug-binutils@gcc.org.
+ * MAINTAINERS: Rename bug-gnu-utils@gcc.org to
+ bug-binutils@gcc.org.
+
+2001-07-28 Matthias Kramm <kramm@quiss.org>
+
+ * bucomm.c (list_supported_architectures): New function.
+ * bucomm.h (list_supported_architectures): Declare.
+ * objdump.c (usage): Call the above.
+
+2001-07-25 Dave Brolley <brolley@redhat.com>
+
+ * objdump.c (SKIP_ZEROES): Only define it if it is not already defined.
+ (SKIP_ZEROES_AT_END): Only define it if it is not already defined.
+
+2001-07-19 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * README: Update for 2.11. Change bug reporting email address.
+ * MAINTAINERS: Tidy up. Change bug reporting email address.
+
+2001-07-16 DJ Delorie <dj@redhat.com>
+
+ * resres.c (write_res_header): Align header size.
+ (res_align_file): Calculate alignment correctly.
+
+ * rcparse.y (styles): use SUBLANG_SHIFT instead of 8 (or the more
+ correct 10).
+ * resrc.c (write_rc_resource): Likewise.
+ * windres.h (SUBLANG_SHIFT): Define - as 10.
+
+2001-07-15 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * MAINTAINERS: Add Christian Groessler as maintainer for z8k port.
+
+2001-07-11 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * MAINTAINERS: Add notes about branch checkins.
+
+2001-07-05 Daniel Berlin <dan@cgsoftware.com>
+
+ * readelf.c (display_debug_macinfo): New function, display
+ .debug_macinfo section.
+ (do_debug_macinfo): New variable.
+ (parse_args): Handle "-w[mM]" to mean display macro info.
+ (process_section_headers): Handle debug_macinfo.
+ (debug_displays): Replace unsupported function with macinfo
+ function for .debug_macinfo display.
+ * doc/binutils.texi: Document new command line switch.
+ * NEWS: Document new feature of readelf.
+
+2001-07-05 H.J. Lu <hjl@gnu.org>
+
+ * objcopy.c (filter_symbols): Don't turn undefined symbols
+ into local.
+
+2001-07-03 H.J. Lu <hjl@gnu.org>
+
+ * doc/Makefile.am (addr2line.1): Use addr2line.pod instead of
+ $@.pod.
+ (ar.1): Likewise.
+ (dlltool.1): Likewise.
+ (nlmconv.1): Likewise.
+ (nm.1): Likewise.
+ (objcopy.1): Likewise.
+ (objdump.1): Likewise.
+ (ranlib.1): Likewise.
+ (readelf.1): Likewise.
+ (size.1): Likewise.
+ (strings.1): Likewise.
+ (strip.1): Likewise.
+ (windres.1): Likewise.
+ (cxxfilt.man): Use $(DEMANGLER_NAME).pod instead of $@.pod.
+ ($(DEMANGLER_NAME).1): Also substitute cxxfilt with
+ $(DEMANGLER_NAME).
+ (as.1): Removed.
+ * doc/Makefile.in: Regenerated.
+
+2001-07-03 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * MAINTAINERS: Change MIPS maintainer to Eric Christopher.
+
+2001-07-01 Daniel Berlin <dan@cgsoftware.com>
+
+ * readelf.c: Support DWARF 2.1 tags, encodings, languages.
+
+2001-06-29 James Cownie <jcownie@etnus.com>
+
+ * readelf.c: Support DWARF 2.1 attributes.
+
+2001-06-28 Alan Modra <amodra@bigpond.net.au>
+
+ * readelf.c (GET_DATA_ALLOC): Remove.
+ (GET_DATA): Remove.
+ (get_data): New function combining above macros, with an extra
+ test for zero size.
+ (slurp_rela_relocs): Use get_data, and catch error return.
+ (slurp_rel_relocs): Likewise.
+ (get_32bit_program_headers): Likewise.
+ (get_64bit_program_headers): Likewise.
+ (get_32bit_section_headers): Likewise.
+ (get_64bit_section_headers): Likewise.
+ (get_32bit_elf_symbols): Likewise.
+ (get_64bit_elf_symbols): Likewise.
+ (process_section_headers): Likewise.
+ (process_relocs): Likewise.
+ (slurp_ia64_unwind_table): Likewise.
+ (process_unwind): Likewise.
+ (get_32bit_dynamic_segment): Likewise.
+ (get_64bit_dynamic_segment): Likewise.
+ (process_dynamic_segment): Likewise.
+ (process_version_sections): Likewise.
+ (process_symbol_table): Likewise.
+ (dump_section): Likewise.
+ (display_debug_info): Likewise.
+ (display_debug_section): Likewise.
+ (process_section_contents): Likewise.
+ (process_corefile_note_segment): Likewise.
+ (process_mips_specific): Likewise. Also free econf32, econf64.
+
+2001-06-25 Alan Modra <amodra@bigpond.net.au>
+
+ * readelf.c (dump_relocations): Print "bad symbol index" if
+ symtab == NULL with non-zero symtab_index.
+ (process_relocs): Don't bomb if reloc section has no symsec.
+
+2001-06-24 H.J. Lu <hjl@gnu.org>
+
+ * objcopy.c (strip_main): Revert the change made on 2001-05-30
+ by accident.
+ (copy_main): Apply the the change made to strip_main on
+ 2001-05-30 by accident.
+
+2001-06-23 Andreas Jaeger <aj@suse.de>
+
+ * unwind-ia64.c (unw_decode_x1): Add unused attribute for
+ parameter 'code'.
+ (unw_decode_x2): Likewise.
+ (unw_decode_x3): Likewise.
+ (unw_decode_x4): Likewise.
+
+2001-06-23 Ben Elliston <bje@redhat.com>
+
+ * MAINTAINERS: Add myself as M88k maintainer.
+
+2001-06-22 Jocelyn Mayer <jocelyn.mayer@netgem.com>
+
+ * objcopy.c (strip_main): Support -o or --output-file command lien
+ switch.
+
+2001-06-19 H.J. Lu <hjl@gnu.org>
+
+ * doc/Makefile.in: Regenerated.
+
+2001-06-19 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * readelf.c: Restore formatting.
+
+2001-06-18 H.J. Lu <hjl@gnu.org> & Nick Clifton <nickc@redhat.com>
+
+ * Makefile.am: Move documentation into doc subdirectory.
+ * Makefile.in: Regenerated.
+ * binutils.texi: Move into doc subdirectory.
+ * addr2line.1: Removed.
+ * ar.1: Likewise.
+ * dlltool.1: Likewise.
+ * nlmconv.1: Likewise.
+ * nm.1: Likewise.
+ * objcopy.1: Likewise.
+ * objdump.1: Likewise.
+ * ranlib.1: Likewise.
+ * readelf.1: Likewise.
+ * size.1: Likewise.
+ * strings.1: Likewise.
+ * strip.1: Likewise.
+ * windres.1: Likewise.
+ * cxxfilt.man: Likewise.
+ * doc: New Directory.
+ * doc/Makefile.am: New file.
+ * doc/Makefile.in: Generate.
+
+2001-06-09 Alan Modra <amodra@bigpond.net.au>
+
+ * NEWS: Fix a typo. Mention hppa64-elf. Add binutils-2.11 marker.
+
+2001-06-01 Alan Modra <amodra@bigpond.net.au>
+
+ * MAINTAINERS: Update my email address.
+
+2001-05-30 Honda Hiroki <hhonda@kobe-catv.ne.jp>
+
+ * objcopy.c: Add new switches: --keep-global-symbol,
+ --keep-symbols, --localize-symbols, --keep-global-symbols and
+ --weaken-symbols.
+ * binutils.texi: Document new switches.
+ * objcopy.1: Regenerate.
+ * NEWS: Announce new feature.
+
+2001-05-28 Andreas Jaeger <aj@suse.de>
+
+ * readelf.c (display_debug_frames): Fix warnings: Remove unused
+ variables, fix format strings.
+
+2001-05-28 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * objdump.c (disassemble_bytes): Remove section VMA adjustment
+ when computing the address of the line to show.
+
+2001-05-16 Richard Henderson <rth@redhat.com>
+
+ * readelf.c (do_debug_frames_interp): New.
+ (byte_get_little_endian): If BFD64, always read entire 8-byte fields.
+ (byte_get_big_endian): Likewise.
+ (parse_args) ['F']: Set do_debug_frames_interp.
+ (Frame_Chunk): Make data_factor signed, add fde_encoding.
+ (frame_display_row): Don't trunc pc_begin to int.
+ (size_of_encoded_value): New.
+ (display_debug_frames): Handle 64-bit targets. Print raw data
+ unless do_debug_frames_interp.
+ (debug_displays): Remove duplicate .debug_frame.
+
+2001-05-15 Ralf Baechle <ralf@gnu.org>
+
+ * readelf.c: Replace uses of EM_MIPS_RS4_BE with EM_MIPS_RS3_LE.
+ The former constant was never in active use and is used otherwise
+ by the ABI.
+
+2001-05-11 Jakub Jelinek <jakub@redhat.com>
+
+ * readelf.c (process_unwind): Print all unwind sections, not just
+ one.
+
+2001-05-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * readelf.c (process_unwind): Remove const specifier.
+
+2001-04-27 Michal Svec <rebel@atrey.karlin.mff.cuni.cz>
+
+ * strings.c (isgraphic): Do not use isascii() unless it is needed
+ for isprint() to work.
+ (main): Set the locale domain to LC_ALL not just LC_MESSAGES.
+
+2001-04-27 Johan Rydberg <jrydberg@opencores.org>
+
+ * NEWS: Announce support for OpenRISC.
+
+2001-04-17 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * dlltool.c (do_default_excludes): Initialise to true.
+
+2001-04-10 Alan Modra <amodra@one.net.au>
+
+ * MAINTAINERS: Update my email address
+ * nm.c (print_symbol_info_bsd): Use a simple printf string.
+
+2001-04-05 Hans-Peter Nilsson <hp@axis.com>
+
+ * readelf.c (display_debug_lines): Fix typo for "Prologue".
+
+2001-03-30 H.J. Lu <hjl@gnu.org>
+
+ * readelf.c (process_unwind): Just return if do_unwind is 0.
+
+2001-03-28 Roger Sayle <roger@metaphorics.com>
+
+ * dlltool.c (make_one_lib_file): Fix section flags for
+ .text, .data and .bss in stub ds*.o files to match those
+ generated by gas.
+
+2001-03-29 H.J. Lu <hjl@gnu.org>
+
+ * readelf.c (process_unwind): Only do unwind sections for
+ IA64.
+
+2001-03-28 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.am ($(srcdir)/dlltool.1): Remove the extra target.
+ * Makefile.in: Regenerate.
+
+2001-03-26 Andreas Jaeger <aj@suse.de>
+
+ * binutils.texi (nm): Fix texi syntax.
+
+2001-03-25 Stephane Carrez <Stephane.Carrez@worldnet.fr>
+
+ * binutils.texi: Put @c man begin and @c man end indications
+ to generate man pages using texi2pod and pod2man. Put @c man title
+ to identify each man. Add SEEALSO entries.
+ * Makefile.am (MANCONF, TEXI2POD, POD2MAN): New variable.
+ (man_MANS): Add dlltool.1, nlmconv.1, readelf.1, windres.1,
+ sort the list.
+ (*.1): Build the man pages from binutils.texi.
+ * Makefile.in: Regenerate.
+
+2001-03-13 Eric Kohl <ekohl@rz-online.de>
+
+ * defparse.y (opt_equal_name): allow "." in name.
+ * dlltool.c (def_exports): Added ability to generate forwarded exports.
+ (gen_exp_file): Likewise.
+
+2001-03-12 Stefan Geuken <mail@stefan-geuken.de>
+
+ * NEWS: Document addition of -B switch to objcopy.
+ * binutils.texi: Document addition of -B switch to objcopy.
+ * objcopy.c: (copy_options): Add --binary-architecture.
+ (copy_usage): Document -B/--binary-architecture.
+ (copy_main): Support -B/--binary-architecture. Set
+ bfd_external_binary_architecture.
+
+2001-03-11 Andreas Jaeger <aj@suse.de>
+
+ * readelf.c (guess_is_rela): Handle EM_S390_OLD.
+ (dump_relocations): Likewise.
+ (get_machine_name): Likewise.
+
+2001-02-28 Nick Clifton <nickc@redhat.com>
+
+ * readelf.c: (struct unw_aux_info): Remove const modifier for
+ 'strtab' field.
+ (process_unwind): Remove non-K&R compliant LHS type cast in call
+ to GET_DATA_ALLOC macro.
+
+2001-02-28 Philip Blundell <pb@futuretv.com>
+
+ * readelf.c (decode_ARM_machine_flags): Explicitly mention which
+ ABI is in use; remove ambiguity between the "unknown" EABI and
+ unrecognised ABIs. Handle version 2 ARM EABI. Update uses of
+ renamed EF_xx constants.
+
+2001-02-27 Alan Modra <alan@linuxcare.com.au>
+
+ * configure.in (BFD_VERSION): New.
+ (AM_INIT_AUTOMAKE): Use $BFD_VERSION.
+ * configure: Regenerate.
+ * Makefile.am: Run "make dep-am"
+ * Makefile.in: Regenerate.
+
+2001-02-14 Nick Clifton <nickc@redhat.com>
+
+ * MAINTAINERS: Add "Obvious Fix" rule.
+
+2001-02-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
+
+ * unwind-ia64.c: Don't use ANSI C preprocessor stringisation and string
+ literal concatenation.
+
+2001-02-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
+
+ * readelf.c (struct unw_aux_info): Remove const from the info member.
+ (process_unwind): Don't type-cast the third argument to the
+ GET_DATA_ALLOC macro.
+
+2001-02-11 Nick Clifton <nickc@redhat.com>
+
+ * readelf.c (dump_relocations): Free corrected allocated
+ array.
+ (process_unwind): Fix compile time warning.
+
+2001-02-10 Nick Clifton <nickc@redhat.com>
+
+ * binutils.texi: Document new --unwind option to readelf.
+
+2001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * readelf.c: Add linux target for S/390.
+
+2001-02-10 Alan Modra <alan@linuxcare.com.au>
+
+ * nm.c (print_symbol_info_bsd): Don't #ifdef inside printf in case
+ printf is a macro.
+
+2001-02-08 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * acinclude.m4 (AM_PROG_LEX): Override installed definition.
+ * aclocal.m4: Regenerate.
+ * configure: Regenerate.
+
+2001-02-07 Todd Vierling <tv@wasabisystems.com>
+
+ * bucomm.c (bfd_target_vector): Change extern array to pointer.
+ * objdump.c (bfd_target_vector): Likewise.
+
+2001-02-07 David Mosberger <davidm@hpl.hp.com>
+
+ * readelf.c (process_unwind): New function.
+ (slurp_ia64_unwind_table): Ditto.
+ (dump_ia64_unwind): Ditto.
+ (find_symbol_for_address): Ditto.
+ (slurp_rela_relocs): New function (split off from dump_relocations()).
+ (slurp_rel_relocs): Ditto.
+ (parse_args): Handle '-u' option.
+
+ * unwind-ia64.c: New file.
+ * unwind-ia64.h: New file.
+ * Makefile.am: Include unwind-ia64.c in readelf build.
+ * Makefile.in: Regenerate.
+ * po/binutils.pot: Regenerate.
+
+2001-02-04 Philip Blundell <philb@gnu.org>
+
+ * configure.in (OBJDUMP_DEFS): Match `arm*-*', not just `arm-*'.
+ * configure: Regenerate.
+
+2001-01-31 Steve deRosier <sderosier@vari-lite.com>
+
+ * ieee.c (ieee_add_bb11): Don't check for backslashes
+ unless HAVE_DOS_BASED_FILE_SYSTEM is defined.
+
+2001-01-24 Mark Elbrecht <snowball3@bigfoot.com>
+
+ * ieee.c: Update copyright.
+ (ieee_start_compilation_unit): Don't check for backslashes
+ unless HAVE_DOS_BASED_FILE_SYSTEM is defined.
+
+ * stabs.c: Update copyright. Include "filenames.h".
+ (parse_stab): Use IS_ABSOLUTE_PATH. Ignore N_WARNING stabs.
+
+2001-01-23 Jakub Jelinek <jakub@redhat.com>
+
+ * readelf.c (process_version_sections): Check if VERDEF or VERNEED
+ sections are present before using them. Remove code duplication.
+ (process_symbol_table): Check if VERDEF or VERNEED sections are
+ present before using them.
+
+2001-01-17 Nick Clifton <nickc@redhat.com>
+
+ * objcopy.c (copy_object): Fail if attempting to convert the
+ endianness of the input object file.
+
+ * binutils.texi: Explain that objcopy cannot convert endianness.
+
+2001-01-16 Nick Clifton <nickc@redhat.com>
+
+ * readelf.c (string_table_length): New variable.
+ (SECTION_NAME): Catch out of range indices and missing section
+ pointers.
+ (process_section_headers): Delete useless local variable
+ string_table_offset. Set the value of string_table_length
+ after loading the string table.
+ (process_mips_specific): Use SECTION_NAME macro.
+ (process_file): Set string_table_length to 0 when it is freed.
+
+2001-01-12 Nick Clifton <nickc@redhat.com>
+
+ * version.c (print_version): Update copyright date.
+
+2001-01-11 Peter Targett <peter.targett@arccores.com>
+
+ * readelf.c (dump_relocations): Include selection with EM_ARC.
+ (get_machine_name) Update name to "ARC".
+
+2001-01-09 Nick Clifton <nickc@redhat.com>
+
+ * Makefile.am: Add rule to build objdump.o from objdump.c and
+ using OBJDUMP_DEFS.
+ * Makefile.in: Regenerate.
+
+ * configure.in: Define OBJDUMP_DEFS. Default to empty.
+ (arm, xscale, d10v): For these targets define OBJDUMP_DEFS to
+ -DDISASSEMBLER_NEEDS_RELOCS.
+ * configure: Regenerate.
+
+ * objdump.c (disassemble_bytes): If DISASSEMBLER_NEEDS_RELOCS
+ is defined read in the relocs even if dump_reloc_info is
+ false.
+
+2001-01-07 Philip Blundell <philb@gnu.org>
+
+ * binutils.texi (Bug Reporting): Replace `bug-gnu-utils' with
+ `bug-binutils'.
+ * README: Likewise.
+
+2000-12-19 Nick Clifton <nickc@redhat.com>
+
+ * dlltool.c: Add missing support for arm-epoc-pe.
+ * configure.in: Add missing support for arm-epoc-pe.
+ * configure: Regenerate.
+
+2000-12-15 Nick Clifton <nickc@redhat.com>
+
+ * MAINTAINERS: Add Diego Novillo as a maintainer for the Intel
+ Mode parts of the x86 port.
+
+2000-12-04 Andreas Jaeger <aj@suse.de>
+
+ * readelf.c (guess_is_rela): Add EM_X86_64.
+ (dump_relocations): Add EM_X86_64.
+ (get_machine_name): Add EM_X86_64.
+ Include "elf/x86-64.h".
+
+2000-12-12 Nick Clifton <nickc@redhat.com>
+
+ * readelf.c: Fix formatting.
+
+2000-12-11 Jan Hubicka <jh@suse.cz>
+
+ * MAINTAINERS: Add myself and Andreas Jaeger as x86_64 maintainer.
+
+2000-12-07 Andrew Haley <aph@redhat.com>
+
+ * readelf.c (display_debug_frames): Only display columns that are
+ referenced by the frame debug info.
+
+2000-12-05 Nick Clifton <nickc@redhat.com>
+
+ * MAINTAINERS: Add Jason Merrill as DWARF2 maintainer.
+
+2000-12-04 Jason Merrill <jason@redhat.com>
+
+ * readelf.c (process_section_headers): Handle linkonce.wi sections.
+ (display_debug_section): Likewise.
+ (display_debug_info): Display CU header before bailing.
+
+2000-12-01 Chris Demetriou <cgd@sibyte.com>
+
+ * readelf.c (get_machine_flags): Recognize MIPS32 ISA in
+ EF_MIPS_ARCH. Replace use of E_MIPS_MACH_MIPS32 with
+ E_MIPS_MACH_MIPS32_4K and adjust printed CPU name similarly.
+
+ * readelf.c (get_machine_flags): Add cases for E_MIPS_ARCH_5,
+ and E_MIPS_ARCH_64.
+
+ * readelf.c (get_machine_flags): Add case for
+ E_MIPS_MACH_SB1.
+
+2000-11-30 Richard Earnshaw <rearnsha@arm.com>
+
+ * readelf.c (frame_display_row): Output 's' for DW_CFA_same_value.
+
+2000-11-28 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * MAINTAINERS: Add Jörn Rennecke and self as SH maintainers.
+ Change sourceware.cygnus.com to sources.redhat.com.
+ Fix typo for "amongst".
+
+2000-11-28 Nick Clifton <nickc@redhat.com>
+
+ * strip.1 (COPYING): Mention that the GNU Free Documentation
+ License is present in the sources, but not the output, and
+ also available from the GNU website.
+ (GNU Free Documentation License): Comment out this section.
+ * strings.1: Ditto.
+ * size.1: Ditto.
+ * ranlib.1: Ditto.
+ * objdump.1: Ditto.
+ * objcopy.1: Ditto.
+ * nm.1: Ditto.
+ * nlmconv.1: Ditto.
+ * ar.1: Ditto.
+ * addr2line.1: Ditto.
+
+2000-11-27 DJ Delorie <dj@redhat.com>
+
+ * readelf.c (usage): Add -wf (--debug-dump=frames) option.
+ (parse_args): Support -wf option.
+ (process_section_headers): Ditto.
+ (debug_displays): Ditto.
+ (display_debug_frames): New, dump *_frame sections.
+ (frame_need_space): Support for above.
+ (frame_display_row): Ditto.
+ * binutils.texi: Document it.
+
+2000-11-24 Nick Clifton <nickc@redhat.com>
+
+ * NEWS: Announce support for v5t, v5te and XScale.
+
+2000-11-22 Nick Clifton <nickc@redhat.com>
+
+ * readelf.c (get_machine_name): Add EM_JAVELIN, EM_FIREPATH,
+ EM_ZSP, EM_MMIX, EM_HUANY, EM_PRISM.
+ (get_section_type_name): Add SHT_GROUP and SHT_SYMTAB_SHNDX.
+ (get_elf_section_flags: Add SHF_GROUP.
+ (process_section_headers): Adjust output for 32-bit binaries
+ to look nice on an 80 column terminal.
+
+2000-11-20 H.J. Lu <hjl@gnu.org>
+
+ * readelf.c (get_osabi_name): Change ELFOSABI_MONTEREY to
+ ELFOSABI_AIX.
+
+2000-11-17 Richard Henderson <rth@redhat.com>
+
+ * readelf.c (display_debug_lines): Adjust last change to
+ use sizeof (external->li_length).
+
+2000-11-17 Richard Henderson <rth@redhat.com>
+
+ * readelf.c (display_debug_lines): Fix section length check
+ and end_of_sequence computation.
+
+2000-11-06 Nick Clifton <nickc@redhat.com>
+
+ * binutils.texi: Add GNU Free Documentation License.
+ * objcopy.1: Add GNU Free Documentation License.
+ * objdump.1: Add GNU Free Documentation License.
+ * addr2line.1: Add GNU Free Documentation License.
+ * ar.1: Add GNU Free Documentation License.
+ * nlmconv.1: Add GNU Free Documentation License.
+ * nm.1: Add GNU Free Documentation License.
+ * ranlib.1: Add GNU Free Documentation License.
+ * size.1: Add GNU Free Documentation License.
+ * strings.1: Add GNU Free Documentation License.
+ * strip.1: Add GNU Free Documentation License.
+
+2000-10-06 Luciano Gemme <ishitawa@yahoo.com>
+
+ * objcopy.c (--srec-len=nn): New parameter to set the
+ maximum length of generated Srecords.
+ (--srec-forceS3): New parameter that restricts the generation of
+ Srecords to type S3 only.
+ * binutils.texi: Document new command line switches.
+ * objcopy.1: Docuemnt the new command line switches.
+ * NEWS: Announce the existence of the new command line switches.
+
+2000-10-31 Nick Clifton <nickc@redhat.com>
+
+ * MAINTAINERS: Add Jim Wilson as the maintainer for the IA64
+ code. Add Eric Chrisopher as maintainer of MN10300 port.
+
+2000-10-12 Roger Sayle <roger@metaphorics.com>
+
+ * Make comma after string after icon/control optional.
+
+2000-09-13 Anders Norlander <anorland@acc.umu.se>
+
+ * readelf.c (get_machine_flags): Also print EF_MIPS_MACH field.
+
+ * NEWS: Mention support for MIPS32.
+
+2000-09-08 Nick Clifton <nickc@redhat.com>
+
+ * MAINTAINERS: Add Stephane Carrez as maintainer for 68HC[11|12].
+
+2000-09-07 H.J. Lu <hjl@gnu.org>
+
+ * configure.in (AC_ISC_POSIX): Put after AC_CANONICAL_SYSTEM.
+ * configure: Rebuild.
+
+2000-09-06 Alexandre Oliva <aoliva@redhat.com>
+
+ * configure: Rebuilt with new libtool.m4.
+
+2000-09-05 Nick Clifton <nickc@redhat.com>
+
+ * aclocal.m4: Regenerate.
+ * config.in: Regenerate.
+ * configure: Regenerate.
+
+2000-09-04 Todd Vierling <tv@wasabisystems.com>
+
+ * strip.1: Fix stray '\' in -o formatting.
+
+2000-09-02 Nick Clifton <nickc@redhat.com>
+
+ * configure.in: Increase version number to 2.10.91.
+ * configure: Regenerate.
+ * aclocal.m4: Regenerate.
+ * config.in: Regenerate.
+ * po/binutils.pot: Regenerate.
+
+2000-08-31 Alexandre Oliva <aoliva@redhat.com>
+
+ * acinclude.m4: Include libtool and gettext macros from the
+ top level.
+ * aclocal.m4, configure: Rebuilt.
+
+2000-08-30 Jamie Guinan <guinan@bluebutton.com>
+
+ * resrc.c (close_input_stream): Delete extraneous logic
+
+2000-08-24 Hans-Peter Nilsson <hp@axis.com>
+
+ * NEWS: Mention support for CRIS.
+
+2000-08-21 Nick Clifton <nickc@redhat.com>
+
+ * addr2line.c: Changed email address for Ulrich Lauther.
+
+2000-08-17 Christopher C. Chimelis <chris@debian.org>
+
+ * objdump.c (LONGEST_ARCH): Set to sizeof("powerpc:common").
+
+2000-08-17 Nick Clifton <nickc@redhat.com>
+
+ * readelf.c (display_debug_pubnames): Only issue warning
+ message once. Terminate message with a new line.
+ (display_debug_aranges): Only display version 2 debug info.
+
+2000-08-14 Todd Vierling <tv@wasabisystems.com>
+
+ * objcopy.c (strip_main): Silently accept -d as an alias for -g
+ for compatibility with old BSD systems.
+
+2000-08-14 Jason Eckhardt <jle@cygnus.com>
+
+ * NEWS: Mention i860 support.
+
+2000-08-11 Carlo Wood <carlo@alinoe.com>
+
+ * addr2line.c (main): Add const to char *.
+
+2000-08-11 Geoff Keating <geoffk@cygnus.com>
+
+ * ar.c (main): Don't crash if called with no arguments
+ or only '-X32_64' as an argument.
+
+2000-08-08 DJ Delorie <dj@redhat.com>
+
+ * resrc.c: use "gcc -xc" instead of -xc-header
+
+2000-08-05 Jason Eckhardt <jle@cygnus.com>
+
+ * readelf.c (elf/i860.h): Include.
+ (dump_relocations): Add recognition of i860 architecture.
+ (guess_is_rela): Add recognition of i860 architecture.
+
+2000-08-03 Nick Clifton <nickc@cygnus.com>
+
+ * MAINTAINERS: Add information about CGEN maintainers.
+
+2000-07-26 Geoff Keating <geoffk@cygnus.com>
+
+ * nm.c (main): Ignore '-X32_64' as an option.
+ * ar.c (main): Likewise.
+ * binutils.texi (nm): Document new option.
+ (ar): Likewise.
+
+2000-07-23 Michael Sokolov <msokolov@ivan.Harhan.ORG>
+
+ * rdcoff.c (external_coff_symbol_p): K&R-ise.
+
+2000-07-20 H.J. Lu <hjl@gnu.org>
+
+ * binutils.texi: Put back "@end table" deleted by
+ accident.
+
+2000-07-05 Kenneth Block <krblock@computer.org>
+
+ * nm.c: Add optional style to demangle switch.
+ * objdump.c: Add optional style to demangle switch.
+ * addr2line.c: Add optional style to demangle switch.
+ * binutils.texi: Document optional style to demangle
+ switch.
+
+2000-07-20 Hans-Peter Nilsson <hp@axis.com>
+
+ * MAINTAINERS: Add self as CRIS port maintainer.
+ * readelf.c: Include elf/cris.h.
+ (guess_is_rela): Handle EM_CRIS.
+ (dump_relocations): Ditto.
+ (get_machine_name): Ditto.
+ * Makefile.am: Rebuild dependencies.
+ * Makefile.in: Regenerate.
+ * po/binutils.pot: Regenerate.
+
+2000-07-19 H.J. Lu <hjl@gnu.org>
+
+ * readelf.c (get_dynamic_type): Change "AUXILARY" to
+ "AUXILIARY".
+ (process_dynamic_segment): Print out strings for DT_CONFIG,
+ DT_DEPAUDIT, DT_AUDIT and DT_RUNPATH.
+
+2000-07-19 Mark Kettenis <kettenis@gnu.org>
+
+ * nm.c (usage): Change output of `nm --help' to include a
+ description of the purpose of the program and a detailed
+ description of the accepted options.
+
+2000-07-19 H.J. Lu <hjl@gnu.org>
+
+ * readelf.c (process_dynamic_segment): Change DF_1_NODEPLIB
+ to DF_1_NODEFLIB.
+
+2000-07-19 H.J. Lu <hjl@gnu.org>
+
+ * readelf.c (get_dynamic_type): Fix DT_CHECKSUM.
+
+2000-07-19 H.J. Lu <hjl@gnu.org>
+
+ * readelf.c (get_dynamic_type): Change DT_FEATURE_1 to
+ DT_FEATURE.
+ (process_dynamic_segment): Likewise.
+
+ * readelf.c (get_dynamic_type): Handle DT_CONFIG, DT_DEPAUDIT,
+ DT_AUDIT, DT_PLTPAD, DT_MOVETAB and DT_CHECKSUM.
+ (process_dynamic_segment): Handle DTF_1_CONFEXP, DF_1_NODEPLIB,
+ DF_1_NODUMP and DF_1_CONLFAT.
+
+2000-07-18 Nick Clifton <nickc@cygnus.com>
+
+ * binutils.texi (readelf): Fix spelling typo.
+
+2000-07-11 Mark Kettenis <kettenis@gnu.org>
+
+ * objdump.c (usage): Make output of `objdump --help' more
+ consistent with the rest of the GNU world. Add a line describing
+ the purpose of the program.
+
+2000-07-10 David Huggins-Daines <dhd@linuxcare.com>
+
+ * stabs.c (parse_stab_range_type): Cast to proper type to fix
+ warning.
+
+2000-07-10 Ryan Bradetich <rbradetich@uswest.net>
+
+ * readelf.c (get_dynamic_data): Add casts and use unsigned chars
+ to fix warnings.
+ (process_symbol_table): Ditto.
+ (procesS_extended_line_op): Ditto.
+ (display_debug_lines): Ditto.
+ (display_debug_pubnames): Ditto.
+ (read_and_display_attr): Ditto.
+
+2000-07-09 Nick Clifton <nickc@cygnus.com>
+
+ * MAINTAINERS: Add several more port specific maintainers.
+
+2000-07-05 Nick Clifton <nickc@cygnus.com>
+
+ * MAINTAINERS: Add blanket write privs for Michael Meissner.
+
+2000-06-05 DJ Delorie <dj@redhat.com>
+
+ * MAINTAINERS: New.
+
+2000-07-01 Eric Fifer <EFifer@sanwaint.com>
+
+ * dllwrap.c: Changed mistaken dyn_string_append() calls
+ to dyn_string_append_cstr().
+
+2000-07-01 Alexander Aganichev <AAganichev@hypercom.com>
+
+ * stabs.c (parse_stab_type): Divide size in bits by 8 as binutils
+ struct debug_type stores size in bytes.
+
+2000-07-01 Alan Modra <alan@linuxcare.com.au>
+
+ * Makefile.am (DEP): Fix 2000-06-22. grep after running dep.sed
+ (CLEANFILES): Add DEPA.
+ * Makefile.in: Regenerate.
+
+2000-06-27 Alan Modra <alan@linuxcare.com.au>
+
+ * ar.c: Revert incorrect 2000-06-25 patch.
+ * bucomm.c: Likewise.
+
+2000-06-25 Mark Elbrecht <snowball3@bigfoot.com>
+
+ * rdcoff (parse_coff_symbol): Treat GNU weak symbols as external.
+ (external_coff_symbol_p): New function.
+ (parse_coff): Use it.
+
+2000-06-25 Alexander Aganichev <AAganichev@hypercom.com>
+
+ * ar.c (normalize): Advance past both characters in a DOS based
+ <letter>: filepath prefix.
+ (main): Likewise.
+ * bucomm.c (make_tempname): Likewise.
+
+2000-06-24 Nick Clifton <nickc@cygnus.com>
+
+ * objdump.c (usage): Fix description of --stabs switch.
+
+2000-06-22 Alan Modra <alan@linuxcare.com.au>
+
+ * Makefile.am (DEP): grep for leading `/' in DEP1, and fail if we
+ find one.
+ * Makefile.in: Regenerate.
+
+2000-06-20 Alexander Aganichev <AAganichev@hypercom.com>
+
+ * ar.c (normalize): Correct pointer comparison when checking for
+ backslashes.
+ (main): Likewise.
+ * bucomm.c (make_tempname): Likewise.
+
+ * ieee.c (ieee_start_compilation_unit): Correct pointer comparison
+ and search for backslashes in the original pathname.
+ (ieee_add_bb11): Likewise.
+
+2000-06-18 Nick Clifton <nickc@redhat.com>
+
+ * ar.c (print_contents): Improve verbose message.
+
+2000-06-15 H.J. Lu <hjl@gnu.org>
+
+ * dyn-string.c: Removed. Not needed with dyn-string.c in
+ libiberty.
+ * dyn-string.h: Likewise.
+
+ * Makefile.am: Remove references to dyn-string.c and
+ dyn-string.h. Rebuild dependency.
+ * Makefile.in: Rebuild.
+
+2000-06-15 H.J. Lu <hjl@gnu.org>
+
+ * binutils.texi: Put a warning on copying relocatable object
+ files between two different formats.
+
+2000-06-13 DJ Delorie <dj@cygnus.com>
+
+ * rcparse.y (control): ICON controls take an id as the first
+ parameter, not an optional string. Also, call new convenience
+ function that takes res_id's.
+ * resrc.c (define_control): missing text means zero-length string,
+ not zero ID.
+ (define_icon_control): New.
+ * windres.h: declare define_icon_control.
+
+2000-06-13 H.J. Lu <hjl@gnu.org>
+
+ * configure: Regenerate.
+
+2000-06-08 David O'Brien <obrien@FreeBSD.org>
+
+ * configure.in (VERSION): Update to show this is the CVS mainline.
+
+2000-06-02 David O'Brien <obrien@FreeBSD.org>
+
+ * strings.c (isgraphic): Interpret <TAB> as a printable character,
+ analogous to <SPACE>.
+
+2000-05-30 Alan Modra <alan@linuxcare.com.au>
+
+ * objdump.c (display_target_list): Use bfd_close_all_done, not
+ bfd_close to fix crash caused by 2000-05-24 change.
+
+2000-05-25 DJ Delorie <dj@cygnus.com>
+
+ * resrc.c (close_input_stream): zero out cpp_pipe after closing it.
+
+2000-05-26 Alan Modra <alan@linuxcare.com.au>
+
+ * Makefile.am: Update dependencies with "make dep-am"
+ * Makefile.in: Regenerate.
+
+2000-05-26 Eli Zaretskii <eliz@is.elta.co.il>
+
+ * ar.c: Include filenames.h.
+ (normalize) [HAVE_DOS_BASED_FILE_SYSTEM]: Support backslashes
+ and drive letters in file names.
+ (main): Support backslashes and drive letters in argv[0]. Drop
+ the .exe suffix, if any, in argv[0] if is_ranlib is negative. Use
+ FILENAME_CMP instead of strcmp to compare file names.
+ (open_inarch) [__GO32__]: Don't ifdef errno != ENOENT test for
+ DJGPP v2.
+ (do_quick_append) [__GO32__]: Ditto.
+ (get_pos_bfd, delete_members, move_members, replace_members):
+ Compare file names with FILENAME_CMP.
+
+ * bucomm.c: Include filenames.h.
+ (make_tempname) [HAVE_DOS_BASED_FILE_SYSTEM]: Support mixed
+ forward/backward slashes and drive letters in file names.
+
+ * ieee.c (ieee_start_compilation_unit, ieee_add_bb11): Support
+ mixed forward/backward slashes and drive letters in file names.
+
+ * strings.c (O_BINARY, setmode, SET_BINARY): Define.
+ (main) [SET_BINARY]: Use SET_BINARY to switch stdin into binary
+ mode.
+
+ * objcopy.c: Include filenames.h.
+ (main) [HAVE_DOS_BASED_FILE_SYSTEM]: Drop the .exe suffix
+ before comparing to "strip".
+ Use FILENAME_CMP to compare file names.
+
+ * arsup.c: Include filenames.h.
+ (map_over_list, ar_delete, ar_replace, ar_extract): Use
+ FILENAME_CMP to compare file names.
+ (ar_open): Prepend "tmp-" instead of appending "-tmp", to create
+ the temporary file name.
+
+ * configure.in: Check for setmode.
+ * configure: Regenerate.
+
+2000-05-24 Alan Modra <alan@linuxcare.com.au>
+
+ * objdump.c (display_target_list): Close the bfd.
+ (display_info_table): Likewise.
+
+2000-05-14 H.J. Lu (hjl@gnu.org)
+
+ * objcopy.c (filter_symbols): Don't strip global symbols in
+ relocatable object files.
+
+2000-05-14 Alan Modra <alan@linuxcare.com.au>
+
+ * size.c (usage): Associate short options with corresponding long
+ option to give a clue as to their function.
+
+2000-05-14 Philippe De Muyter <phdm@macqel.be>
+
+ * size.c (main): Accept and ignore `-f' option.
+
+2000-05-13 Alan Modra <alan@linuxcare.com.au>
+
+ * bucomm.h (gettext, dgettext, dcgettext, textdomain,
+ bindtextdomain): Replace defines with those from intl/libgettext.h
+ to quieten gcc warnings.
+
+2000-05-12 H.J. Lu <hjl@gnu.org>
+
+ * nlmconv.c (temp_filename): Removed.
+
+ * nlmconv.c (link_inputs): Use make_temp_file () instead of
+ choose_temp_base ().
+ * objdump.c (display_target_list): Likewise.
+ (display_info_table): Likewise.
+
+2000-05-08 Alan Modra <alan@linuxcare.com.au>
+
+ * objcopy.c (setup_section): Add const and gettext calls for err.
+
+2000-05-02 H.J. Lu <hjl@gnu.org>
+
+ * readelf.c (get_osabi_name): Handle ELFOSABI_NONE instead of
+ ELFOSABI_SYSV. Also handle ELFOSABI_NETBSD, ELFOSABI_HURD,
+ ELFOSABI_SOLARIS, ELFOSABI_MONTEREY, ELFOSABI_IRIX,
+ ELFOSABI_FREEBSD, ELFOSABI_TRU64, ELFOSABI_MODESTO
+ and ELFOSABI_OPENBSD.
+
+2000-05-02 Kazu Hirata <kazu@hxi.com>
+
+ * coffgrok.c: Add ATTRIBUTE_UNUSED as appropriate.
+ * srconv.c: Likewise.
+ * sysdump.c: Likewise.
+
+2000-04-23 Denis Chertykov <denisc@overta.ru>
+
+ * readelf.c (guess_is_rela): AVR uses RELA relocations.
+ (get_machine_name): machine name for EM_AVR added.
+
+2000-04-21 Richard Henderson <rth@cygnus.com>
+ David Mosberger <davidm@hpl.hp.com>
+
+ * Makefile.am (readelf.o): Add elf/ia64.h.
+ * Makefile.in: Rebuild.
+ * readelf.c: Include elf/ia64.h.
+ (guess_is_rela, dump_relocations): Handle EM_IA_64.
+
+2000-04-17 Timothy Wall <twall@cygnus.com>
+
+ * objdump.c (disassemble_data): Set octets per byte *after*
+ resolving arch/mach for binary files.
+
+2000-04-14 Michael Sokolov <msokolov@ivan.Harhan.ORG>
+
+ * arlex.l: Add directives to increase lex buffer size.
+
+ * objdump.c, readelf.c: Don't include strarg.h or varargs.h. They are
+ already included by bucomm.h.
+
+2000-04-10 Philippe De Muyter <phdm@macqel.be>
+
+ * readelf.c (dynamic_segment_mips_val): Call `sprintf', not
+ `strftime' since strftime is not available on all systems.
+ (process_mips_specific): Ditto.
+
+2000-04-07 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * configure.in (WARN_CFLAGS): Set to -W -Wall by default. Add
+ --enable-build-warnings option.
+ * Makefile.am (AM_CFLAGS, WARN_CFLAGS): Add definitions.
+ * Makefile.in, configure: Re-generate.
+
+2000-04-06 Alan Modra <alan@linuxcare.com.au>
+
+ * addr2line.c: Update copyright.
+ * objcopy.1: Likewise, and title.
+ * strings.1: Likewise.
+
+ * version.c (print_version): Add 2000.
+
+ * rddbg.c (read_section_stabs_debugging_info): Don't use
+ bfd_size_type for strx to avoid printf problems if BFD64.
+
+ * bucomm.c: (report): Remove `static'.
+ Move inclusion of stdarg.h/vararg.h from here.
+ * bucomm.h: To here.
+ (CONST): Change all occurences to const.
+ (report): Declare it.
+ (bfd_fatal): Add ATTRIBUTE_NORETURN.
+ (fatal): Add ATTRIBUTE_PRINTF_1 ATTRIBUTE_NORETURN.
+ (non_fatal): Add ATTRIBUTE_PRINTF_1.
+
+ * ar.c (main): Use fatal or non_fatal instead of fprintf.
+ Correct a typo in an error message.
+ (do_quick_append): Use non_fatal instead of fprintf.
+ (move_members): Use fatal instead of fprintf, exit.
+ * coffdump.c (main): Same here.
+
+ * dlltool.c (display): Delete.
+ (warn): Delete.
+ (inform): Use `report' instead of `display'.
+ (rvaafter): Remove trailing \n from fatal error msg.
+ (rvabefore): Ditto.
+ (asm_prefix): Ditto.
+ (yyerror): Replace `warn' with `non_fatal', and remove \n.
+ (def_name): Likewise.
+ (run): Likewise.
+ (scan_all_symbols): Likewise.
+ (gen_lib_file): Likewise.
+ (def_library): Likewise. Remove extra program_name too.
+ (run): Remove \n from inform strings.
+ (scan_drectve_symbols): Likewise.
+ (add_excludes): Likewise.
+ (scan_open_obj_file): Likewise.
+ (gen_exp_file): Likewise.
+ (gen_lib_file): Likewise.
+ (process_duplicates): Likewise.
+
+ * Makefile.am (dllwrap_SOURCES): Add version.c.
+ * dllwrap.c (program_version): Delete.
+ (print_version): Delete.
+ (display): Always print trailing \n.
+ (warn): New.
+ (delete_temp_files): Use warn instead of fprintf. Use gettext.
+ (run): Here too.
+ (main): And here.
+ (usage): gettext'ify.
+ (long_options): Add missing initialisers.
+
+ * nlmconv.c (main): Use fatal/non_fatal instead of fprintf.
+ (select_output_format): Likewise.
+ (powerpc_mangle_relocs): Likewise.
+ (link_inputs): Likewise.
+
+ * nm.c (set_print_radix): Use fatal instead of fprintf, exit.
+ (set_output_format): Likewise.
+ (main): Use non_fatal instead of fprintf.
+ (display_rel_file): Likewise.
+
+ * objdump.c (slurp_symtab): Use non_fatal instead of fprintf.
+ (slurp_dynamic_symtab): Same here.
+ (disassemble_data): And here.
+ (read_section_stabs): And here.
+ (read_section_stabs): And here.
+ (dump_bfd): And here.
+ (main): And here.
+ (objdump_sprintf): Use fatal instead of fprintf, exit.
+ (disassemble_data): Same here.
+
+ * rdcoff.c (parse_coff_type): Use non_fatal instead of fprintf.
+ (parse_coff_struct_type): Same here.
+ (parse_coff_enum_type): And here.
+ (parse_coff): And here.
+ * rddbg.c (read_debugging_info): And here.
+ * size.c (main): And here.
+ * windres.c (format_from_name): And here.
+ * wrstabs.c (stab_write_symbol): Here too.
+ (write_stabs_in_sections_debugging_info): And here.
+ (stab_int_type): And here.
+ (stab_struct_field): And here.
+ (stab_typdef): And here.
+
+ * rescoff.c (read_coff_rsrc): Use fatal instead of fprintf, exit.
+ * srconv.c (main): Same here.
+ * strings.c (main): And here.
+ (integer_arg): And here.
+ * sysdump.c (main): And here.
+
+2000-04-06 Timothy Wall <twall@cygnus.com>
+
+ * objdump.c (dump_section_header): Print CLINK and BLOCK flags.
+
+2000-04-06 Jason Merrill <jason@yorick.cygnus.com>
+
+ * readelf.c (decode_location_expression): Loop through multiple
+ operations.
+ (read_and_display_attr): Pass in length.
+
+ * readelf.c (read_and_display_attr): Add CU offset to references.
+ (display_debug_info): Pass it in.
+
+2000-04-06 Nick Clifton <nickc@cygnus.com>
+
+ * readelf.c (decode_ARM_machine_flags): New function.
+ (get_machine_flags): Call decode_ARM_machine_flags for ARM
+ targets.
+
+ (get_machine_name): Catch EM_AVR
+
+2000-04-05 Alan Modra <alan@linuxcare.com.au>
+
+ * binutils.texi: Remove optional `=' from long options that have
+ an `=' in the argument.
+ * objcopy.1: Here too. Remove extra space on discard-all.
+
+ * binutils.texi (objcopy): Mention --redefine-sym.
+ * objcopy.1: Here too.
+ * NEWS: And here.
+
+ * objcopy.c (parse_flags): Split off flag names from error message
+ gettext as they are not translated.
+ (copy_main): Similarly split off option name for --add-section,
+ --set-section-flags, --change-section-vma, --change-section-lma
+ error messages.
+ Some white space changes.
+
+ from Matthew Benjamin <matt@linuxbox.nu>
+ * objcopy.c (struct redefine_node): New.
+ (redefine_sym_list): New.
+ (redefine_list_append): New.
+ (lookup_sym_redefinition): New.
+ (OPTION_REDEFINE_SYM): New.
+ (copy_options): Add --redefine-sym option.
+ (copy_usage): Mention it.
+ (filter_symbols): Rename symbols on redefine_sym_list.
+ (copy_object): Call filter_symbols if redefine_sym_list != NULL.
+ (copy_main): Handle OPTION_REDEFINE_SYM.
+
+2000-04-04 H.J. Lu <hjl@gnu.org>
+
+ * readelf.c (process_symbol_table): Correctly read in symbol
+ versioning information.
+
+2000-04-04 Alan Modra <alan@linuxcare.com.au>
+
+ * po/binutils.pot: Regenerate.
+
+ * addr2line.c (usage): Restore translated part of bug string.
+ * ar.c (usage): Likewise.
+ * nlmconv.c (show_usage): Likewise.
+ * nm.c (usage): Likewise.
+ * objcopy.c (copy_usage): Likewise.
+ (strip_usage): Likewise.
+ * objdump.c (usage): Likewise.
+ * readelf.c (usage): Likewise.
+ * size.c (usage): Likewise.
+ * strings.c (usage): Likewise.
+ * windres.c (usage): Likewise.
+
+ * Makefile.am (MKDEP): Use gcc -MM rather than mkdep.
+ (DEP): Quote when passing vars to sub-make. Add warning
+ message to end.
+ (DEP1): Rewrite for "gcc -MM".
+ (CLEANFILES): Add DEP2.
+ Update dependencies.
+ * Makefile.in: Regenerate.
+
+2000-04-04 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.am (GENERATED_HFILES): Add rcparse.h
+ (arparse.h): Depend on arparse.c
+ (defparse.h, nlmheader.h, rcparse.h, sysinfo.h): Similarly.
+
+2000-04-03 H.J. Lu (hjl@gnu.org)
+
+ * size.c (usage): Use REPORT_BUGS_TO.
+
+2000-04-03 Alan Modra <alan@linuxcare.com.au>
+
+ * bucomm.h: #include "bin-bugs.h"
+ * addr2line.c (usage): Use REPORT_BUGS_TO.
+ * ar.c (usage): Likewise.
+ * nlmconv.c (show_usage): Likewise.
+ * nm.c (usage): Likewise.
+ (OPTION_TARGET): Define.
+ (long_options): Use OPTION_TARGET rather than 200.
+ (main): Likewise.
+
+ * objcopy.c (copy_usage): Use REPORT_BUGS_TO.
+ (strip_usage): Likewise.
+ * objdump.c (usage): Likewise.
+ * readelf.c (usage): Likewise.
+ * strings.c (usage): Likewise.
+ * windres.c (usage): Likewise.
+
+2000-03-31 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * readelf.c: Include sys/types.h before sys/stat.h for ultrix.
+
+2000-03-27 Nick Clifton <nickc@cygnus.com>
+
+ * rddbg.c (read_section_stabs_debugging_info): Catch out of range
+ string offsets in corrupt stabs entries.
+
+2000-03-27 Alan Modra <alan@linuxcare.com.au>
+
+ * readelf.c: Include elf/avr.h
+ (dump_relocations): Add EM_AVR case.
+
+2000-03-09 Tim Waugh <twaugh@redhat.com>
+
+ * strings.1: Correct '-bytes' to '--bytes'.
+
+2000-03-08 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.am (install-exec-local): Depend on
+ install-binPROGRAMS for parallel make.
+ * Makefile.in: Regenerated.
+
+2000-02-27 Ian Lance Taylor <ian@zembu.com>
+
+ From Brad Lucier <lucier@math.purdue.edu>:
+ * readelf.c (process_dynamic_segment): Add cast to make sure
+ argument to %* is int.
+
+2000-02-25 H.J. Lu <hjl@gnu.org>
+
+ * configure.in (AC_SEARCH_LIBS): Pass m, not -lm.
+
+2000-02-24 Nick Clifton <nickc@cygnus.com>
+
+ * configure.in: Add arm-wince, mips-pe and sh-pe targets.
+ * configure: Regenerate.
+
+ * dlltool.c: Add support for sh-pe and mips-pe targets.
+ * rescoff.c: Add support for sh-pe and mips-pe targets.
+
+2000-02-23 H.J. Lu <hjl@gnu.org>
+
+ * readelf.c (get_osabi_name): Handle ELFOSABI_LINUX.
+
+2000-02-22 Nick Clifton <nickc@cygnus.com>
+
+ * readelf.c (process_symbol_table): Remove use of ELF_ST_OTHER.
+
+2000-02-22 Ian Lance Taylor <ian@zembu.com>
+
+ From Brad Lucier <lucier@math.purdue.edu>:
+ * readelf.c (process_version_sections): Add casts to make sure
+ argument to %* is an int.
+ (process_mips_specific): Add casts to make printf arguments match
+ format.
+
+2000-02-21 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * objdump.c (dump_section_header): Change `opb' to unsigned.
+ (find_symbol_for_address): Same here.
+ (disassemble_data): And here. Change `addr_offset',
+ `stop_offset', `nextstop_offset' to unsigned long.
+ (dump_data): Change opb to unsigned.
+
+2000-02-18 Frank Ch. Eigler <fche@redhat.com>
+
+ * resrc.c: Remove unmatched #if for cygwin.
+
+2000-02-14 Fernando Nasser <fnasser@totem.to.cygnus.com>
+
+ * binutils.texi: Document the change of flavor name from atpcs-special
+ to special-atpcs to prevent name conflict in gdb.
+
+2000-02-08 Timothy Wall <twall@redhat.com>
+
+ * objdump.c (show_line): Fix bug preventing printing of the very
+ first line (line zero) of a file when interlisting source and
+ assembly. Added option to print entire context from start of file
+ when the first line from that file is encountered.
+
+2000-02-03 Timothy Wall <twall@redhat.com>
+
+ * objdump.c (dump_section_header, find_symbol_for_address,
+ show_line, disassemble_bytes, disassemble_data, dump_data):
+ distinguish between octets and bytes.
+
+2000-01-27 Thomas de Lellis <tdel@windriver.com>
+
+ * nm.c (print_symbol_info_bsd): Use bfd_is_undefined_symclass to
+ check to unresolved symbols.
+ (print_symbol_info_sysv): Ditto.
+ (print_symbol_info_posix): Ditto.
+
+ * binutils.texi: Document new 'V' symclass flag for nm.
+
+2000-01-27 Nick Clifton <nickc@redhat.com>
+
+ * binutils.texi (objdump): Document new ARM specific
+ disassembler options.
+
+ * objdump.c (usage): Call disassembler_usage().
+
+2000-01-27 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * readelf.c (get_dynamic_flags): Return buff.
+ (process_dynamic_segment): Don't pass error strings to printf
+ as format arg.
+ (read_and_display_attr): Use lx and ld to print longs.
+ (process_corefile_note_segment): Cast bfd_vma to unsigned long
+ before printing.
+ Update copyright.
+
+2000-01-17 Nick Clifton <nickc@cygnus.com>
+
+ * readelf.c (get_osabi_name): Recognise ELFOSABI_ARM.
+
+2000-01-15 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * debug.c (debug_name_type): Return DEBUG_TYPE_NULL rather than
+ false.
+ (debug_tag_type): Here too.
+ * ieee.c (ieee_builtin_type): And here.
+ * stabs.c (parse_stab_type, parse_stab_array_type): And here.
+
+2000-01-13 Nick Clifton <nickc@cygnus.com>
+
+ * readelf.c (get_machine_name): Change EM_S370 to return "IBM
+ System/370".
+
+2000-01-11 Nick Clifton <nickc@cygnus.com>
+
+ * readelf.c (get_dynamic_type): Remove DT_ENCODING.
+
+2000-01-10 Nick Clifton <nickc@cygnus.com>
+
+ * readelf.c (get_note_type): Display NT_WIN32PSTATUS notes.
+
+2000-01-07 Mumit Khan <khan@xraylith.wisc.edu>
+
+ * windres.c (long_options): Add --use-temp-file and
+ --no-use-temp-file options.
+ (usage): Document.
+ (main): Handle.
+
+ * windres.h: Update read_rc_file prototype.
+
+ * resrc.c (cpp_temp_file): New static variable.
+ (istream_type): New static variable.
+ (close_pipe): Delete function.
+ (run_cmd): New static function.
+ (open_input_stream): New static function.
+ (close_input_stream): New static function.
+ (look_for_default): Handle DOS directory separator. Use
+ open_input_stream instead of popen.
+ (read_rc_file): Likewise.
+
+ * binutils.texi: Document --use-temp-file, --no-use-temp-file
+ options.
+
+2000-01-04 Mumit Khan <khan@xraylith.wisc.edu>
+
+ * dlltool.c (create_compat_implib): New variable.
+ (gen_exp_file): Use.
+ (make_one_lib_file): Use.
+ (long_options): Add --compat-implib option.
+ (usage): Handle.
+ (main): Handle.
+
+ * dllwrap.c (enum target_type): Rename MINGW32_TARGET to MINGW_TARGET.
+ (main): Use. Don't look for "32" in cygwin and mingw target names.
+
+2000-01-03 Nick Clifton <nickc@cygnus.com>
+
+ * binutils.texi: Document new, ARM specific disassembler
+ command line switch "-M force-thumb".
+
+For older changes see ChangeLog-9899
+
+Local Variables:
+mode: change-log
+left-margin: 8
+fill-column: 74
+version-control: never
+End:
diff --git a/contrib/binutils/binutils/ChangeLog-0203 b/contrib/binutils/binutils/ChangeLog-0203
new file mode 100644
index 0000000..c633775
--- /dev/null
+++ b/contrib/binutils/binutils/ChangeLog-0203
@@ -0,0 +1,2181 @@
+2003-12-31 Daniel Jacobowitz <drow@mvista.com>
+
+ * MAINTAINERS: Rename CONFIGURE to BUILD SYSTEM and add myself.
+
+2003-12-29 Nick Clifton <nickc@redhat.com>
+
+ * readelf.c (debug_line_pointer_size): Replace with an array
+ called 'debug_line_pointer_sizes'.
+ (num_debug_line_pointer_sizes): New variable.
+ (display_debug_lines): Extract pointer size from the
+ debug_line_pointer_sizes array.
+ (display_debug_loc): Likewise.
+ (prescan_debug_info): Fill in the debug_line_pointer_sizes
+ array.
+
+2003-12-23 Ralf Baechle <ralf@gnu.org>
+ Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * objcopy.c (bfd_flags_to_set, bfd_flags_to_clear): New variables
+ to handle flags for tweaking.
+ (copy_options): New options: impure, pure, readonly-text,
+ writable-text.
+ (copy_usage, copy_object, command_line_switch): Handle the new
+ options.
+ * doc/binutils.texi: Document the new options.
+
+2003-12-22 Jakub Jelinek <jakub@redhat.com>
+
+ * objdump.c (disassemble_bytes): Subtract rel_offset from printed
+ reloc address.
+ (disassemble_section): Set rel_offset to section->vma instead of
+ pinfo->buffer_vma.
+
+2003-12-19 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
+
+ * readelf.c (guess_is_rela): Changed m32r's default type to RELA.
+
+2003-12-11 Nick Clifton <nickc@redhat.com>
+
+ * objcopy.c (strip_usage): Add --only-keep-debug.
+ (copy_usage): Likewise.
+
+2003-12-04 Nick Clifton <nickc@redhat.com>
+
+ * objcopy.c (copy_object): Do not copy the object if the
+ output file's format cannot be set to that of the input file.
+ If the input file's format is unknown, fail.
+
+2003-11-28 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * cxxfilt.c (usage): Mention new -p/--no-params options.
+
+2003-11-28 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (install-exec-local): Remove common term from string
+ comparison.
+ * Makefile.in: Regenerate.
+ * doc/Makefile.am: Don't use $<.
+ * doc/Makefile.in: Regenerate.
+
+2003-11-27 Nick Clifton <nickc@redhat.com>
+
+ * rename.c (smart_rename): Make sure that we have write
+ permission on the destination file before renaming.
+
+2003-11-26 Daniel Jacobowitz <drow@mvista.com>
+ Nick Clifton <nickc@redhat.com>
+
+ * readelf.c: Add a comment describing the difference between
+ readelf and objdump.
+ * doc/binutils.texi (readelf): Likewise.
+
+2003-11-25 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * doc/binutils.texi (dlltool): Document dlltool --temp-prefix
+ option.
+ * dlltool.c (usage): Likewise.
+
+2003-11-22 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * cxxfilt.c (long_options): Add --no-params.
+ (main): Handle -p/--no-params.
+ * doc/binutils.texi (c++filt): Document -p/--no-params.
+
+2003-11-19 Alan Modra <amodra@bigpond.net.au>
+
+ * objdump.c: Wrap long lines, init vars separately from decl.
+ (disassemble_section): Reset require_sec after call to
+ find_symbol_for_address.
+
+2003-11-14 Nick Clifton <nickc@redhat.com>
+
+ * objdump.c (find_symbol_for_address): Change parameters so
+ that the entire disassemble_info structure is passed, not just
+ a few fields. Use the symbol_is_valid field to check the
+ validity of located symbols and continue searching if they are
+ not valid.
+ (objdump_print_addr): Alter parameters passed to
+ find_symbol_for_address.
+ (objdump_symbol_at_address): Likewise.
+ (disassemble_section): Likewise. Also use symbol_is_valid
+ function to check the validity of located symbols.
+
+2003-11-13 Tobias Burnus <tobias.burnus@physik.fu-berlin.de>
+
+ * ar.c (open_inarch): Emit a warning when an archive is created
+ (only shown with -v) in order to confrom to POSIX specification.
+
+2003-11-11 Wang Li <charles@linux.net.cn>
+
+ * objcopy.c (wildcard): New variable. True if wildcard pattern
+ matching is allowed in symbol names.
+ (strip_options): Add -w option to enable wildcard pattern
+ matching.
+ (copy_options): Likewise.
+ (copy_usage): Mention new switch.
+ (strip_usage): Likewise.
+ (is_specified_symbol): If performing wildcard matches use fnmatch
+ to compare symbol names with entries on the symbol list.
+ (strip_main): Accept -w switch.
+ (copy_main): Likewise.
+ * Makefile.am: Add dependency on fnmatch.h for objcopy.c
+ * Makefile.in: Regenerate.
+ * doc/binutils.texi: Document new switch.
+ * NEWS: Mention new switch.
+
+2003-11-11 Alan Modra <amodra@bigpond.net.au>
+
+ * objdump.c: Revert rev 1.81 commit.
+
+2003-11-10 Tobias Burnus <tobias.burnus@physik.fu-berlin.de>
+
+ * ar.c (print_contents): Remove "member" from verbose output in
+ order to conform to POSIX specification.
+
+2003-11-10 Alan Modra <amodra@bigpond.net.au>
+
+ * README: Expand bug reporting information.
+
+2003-11-07 Jonathan R. Grant <jg-binutils@jguk.org>
+
+ * bucomm,c (get_file_size): New function. Returns the size of a
+ file.
+ * bucomm.h: Add prototype for get_file_size.
+ * addr2line.c (process_file): Use new function.
+ * ar.c (main, ranlib_only, ranlib_touch): Likewise.
+ * nm.c (display_file): Likewise.
+ * objcopy.c (add_specific_symbols, copy_file, strip_main,
+ copy_main): Likewise.
+ * objdump.c (display_file): Likewise.
+ * size.c (display_file): Likewise.
+ * strings.c (strings_file): Likewise.
+ * readelf.c (process_file): Use similar code to get_file_size.
+
+2003-11-06 Bruno Rohee <bruno@rohee.com>
+
+ * ieee.c: Fix "the the" typo.
+ * stabs.c: Likewise.
+
+2003-10-30 Marshall T. Vandegrift <llasram@wuli.nu>
+
+ * readelf.c (dump_section): Do not dump the contents of SHT_NOBITS
+ sections - they have no file space assigned to their contents.
+
+2003-10-28 Segher Boessenkool <segher@kernel.crashing.org>
+
+ * readelf.c (dump_section): Don't display DEL characters.
+
+2003-10-27 Kazu Hirata <kazu@cs.umass.edu>
+
+ * ChangeLog: Fix typos.
+ * ChangeLog-9197: Likewise.
+ * ChangeLog-9899: Likewise.
+ * NEWS: Likewise.
+ * ar.c: Fix comment typos.
+ * arsup.c: Likewise.
+ * coffgrok.c: Likewise.
+ * debug.c: Likewise.
+ * debug.h: Likewise.
+ * dlltool.c: Likewise.
+ * ieee.c: Likewise.
+ * nm.c: Likewise.
+ * objdump.c: Likewise.
+ * prdbg.c: Likewise.
+ * readelf.c: Likewise.
+ * resrc.c: Likewise.
+ * sysinfo.y: Likewise.
+ * windres.c: Likewise.
+
+2003-10-27 Nick Clifton <nickc@redhat.com>
+
+ * objcopy.c (copy_section): Do not complain when a target does not
+ support relocations.
+ (mark_symbols_used_in_relocations): Likewise.
+
+2003-10-14 Anil Paranjpe <anilp1@KPITCummins.com>
+
+ * objcopy.c (copy_main): Reads machine flags from arch_info
+ structure.
+
+2003-10-20 Andrew Cagney <cagney@redhat.com>
+
+ * coffgrok.h (coff_section): Replace 'struct sec" with "struct
+ bfd_section".
+
+2003-10-07 Nathan Sidwell <nathan@codesourcery.com>
+
+ * objdump.c (read_section_stabs): Just read one section, return
+ pointer to it. Add size parameter.
+ (print_section_stabs): Add string offset parameter. Adjust.
+ (struct stab_section_names): Add string offset member.
+ (find_stabs_sections): Correct check for split section suffix,
+ adjust read_section_stabs and print_section_stabs calls.
+ (dump_stabs_section): Clear string_offset, free string table.
+
+2003-10-01 Martin Fuchs <martin-fuchs@gmx.net>
+
+ * resrc.c (define_icon): Fix storage of color attributes 'planes' and
+ 'bit count' in icon groups.
+
+2003-09-30 Chris Demetriou <cgd@broadcom.com>
+
+ * NEWS: Add an indication of the cutoff for 2.14.
+
+2003-09-30 Chris Demetriou <cgd@broadcom.com>
+
+ * readelf.c (get_machine_flags): Handle E_MIPS_ARCH_64R2.
+
+2003-09-29 H.J. Lu <hongjiu.lu@intel.com>
+
+ * readelf.c (dump_relocations): Support SHN_IA_64_ANSI_COMMON.
+ (get_symbol_index_type): Likewise.
+
+2003-09-25 H.J. Lu <hongjiu.lu@intel.com>
+
+ * readelf.c (process_version_sections): Indent version names.
+
+2003-09-15 Anthony Green <green@redhat.com>
+
+ * dlltool.c (prefix_encode): Fix ISO C90 conversion.
+ (dlltmp): Ditto.
+ (dtab): Ditto.
+
+2003-09-14 Andreas Jaeger <aj@suse.de>
+
+ * addr2line.c: Convert to ISO C90 prototypes, change PTR, remove
+ unneeded (void *) casts.
+ * ar.c: Likewise.
+ * arlex.l: Likewise.
+ * arparse.y: Likewise.
+ * arsup.c: Likewise.
+ * binemul.c: Likewise.
+ * binemul.h: Likewise.
+ * bucomm.c: Likewise.
+ * bucomm.h: Likewise.
+ * budbg.h: Likewise.
+ * budemang.c: Likewise.
+ * budemang.h: Likewise.
+ * coffdump.c: Likewise.
+ * coffgrok.c: Likewise.
+ * cxxfilt.c: Likewise.
+ * debug.c: Likewise.
+ * debug.h: Likewise.
+ * deflex.l: Likewise.
+ * dlltool.c: Likewise.
+ * dlltool.h: Likewise.
+ * dllwrap.c: Likewise.
+ * emul_aix.c: Likewise.
+ * filemode.c: Likewise.
+ * ieee.c: Likewise.
+ * nlmconv.c: Likewise.
+ * nlmconv.h: Likewise.
+ * nlmheader.y: Likewise.
+ * nm.c: Likewise.
+ * prdbg.c: Likewise.
+ * rclex.l: Likewise.
+ * rcparse.y: Likewise.
+ * rdcoff.c: Likewise.
+ * rddbg.c: Likewise.
+ * rename.c: Likewise.
+ * resbin.c: Likewise.
+ * rescoff.c: Likewise.
+ * resrc.c: Likewise.
+ * size.c: Likewise.
+ * srconv.c: Likewise.
+ * stabs.c: Likewise.
+ * strings.c: Likewise.
+ * sysdump.c: Likewise.
+ * sysinfo.y: Likewise.
+ * syslex.l: Likewise.
+ * unwind-ia64.c: Likewise.
+ * unwind-ia64.h: Likewise.
+ * version.c: Likewise.
+ * windres.c: Likewise.
+ * windres.h: Likewise.
+ * winduni.c: Likewise.
+ * wrstabs.c: Likewise.
+
+2003-09-10 James E Wilson <wilson@specifixinc.com>
+
+ * MAINTAINERS: Update my e-mail address.
+
+2003-09-09 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * MAINTAINERS: Update my e-mail address.
+
+2003-09-04 Nick Clifton <nickc@redhat.com>
+
+ * MAINTAINERS: Make it clear what should be done with patches to
+ the top level configure files (other than config.guess and
+ config.sub). Add binutils@sources.redhat.com as an address to
+ which patches can be sent.
+
+2003-09-04 Nick Clifton <nickc@redhat.com>
+
+ * readelf.c (get_machine_flags): Recognise V850E1 machine type.
+
+2003-09-03 Andrew Cagney <cagney@redhat.com>
+
+ * objdump.c: Refer to init_disassemble_info in comments.
+ (disassemble_data): Replace INIT_DISASSEMBLE_INFO with
+ init_disassemble_info.
+
+2003-09-03 Nick Clifton <nickc@redhat.com>
+
+ * objdump.c (struct objdump_disasm_info): Add new fields
+ 'dynrelbuf', 'dynrelcount' and 'disassemble_fn'.
+ (process_section_p): New function: Returns TRUE if a section
+ can be dumped.
+ (disassemble_section): New function: Contains the body of
+ disassemble_data(), but just for one section.
+ (disassemble_data): Use bfd_map_over_sections to walk section
+ chain.
+ (find_stabs_section): New function: Find a stabs containing
+ section and then dump it.
+ (dump_stabs_section): New function: Use bfd_map_over_sections
+ to find the section to dump.
+ (dump_stabs): Use dump_stabs_section.
+ (dump_section): New function: Display the contents of a
+ section.
+ (dump_data): Use bfd_map_over_sections to display section
+ contents.
+ (dump_relocs_in_section): Display the relocs in a given section.
+ (dump_relocs): Use bfd_map_over_sections to display relocs.
+ (adjust_addresses): New function: Adjust the vma and lma of
+ sections.
+ (dump_bfd): Use bfd_map_over_sections.
+ * doc/binutils.texi: Document the "objdump -s" (no longer)
+ dumps empty sections.
+
+2003-08-24 Jonathan R. Grant <jg-binutils@jguk.org>
+
+ * objdump.c: Improve comments/documentation.
+ dump_data: Eliminate duplicate function calls to bfd_section_size.
+
+2003-09-02 Alan Modra <amodra@bigpond.net.au>
+
+ * MAINTAINERS: Move Dave Anglin's entry to where it belongs.
+
+2003-08-21 Nick Clifton <nickc@redhat.com>
+
+ * po/tr.po: Updated Turkish translation.
+
+2003-08-14 Alan Modra <amodra@bigpond.net.au>
+
+ * dep-in.sed: Remove libintl.h.
+ * Makefile.am (POTFILES.in): Unset LC_COLLATE.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2003-08-11 Ian Lance Taylor <ian@airs.com>
+
+ * readelf.c (process_archive): Fix error handling. Remove memory
+ leak.
+
+ * readelf.c: Add ability to read archives.
+ (archive_file_offset): New variable.
+ (archive_file_size): New variable.
+ (get_data): Include archive_file_offset in file offset
+ calculation when fseeking.
+ (process_program_headers): Likewise.
+ (process_symbol_table): Likewise.
+ (process_dynamic_segment): Handle computation of end of file
+ position when the file is in an archive.
+ (process_object): New function. Contains the body of
+ process_file().
+ (process_archive): New function. Call process_object on each
+ member of an archive.
+ (process_file): Detect archives and handle appropriately.
+ * Makefile.am: Add dependency on aout/ar.h for readelf.c
+ * Makefile.in: Regenerate.
+ * NEWS: Document readelf's new ability.
+ * doc/binutils: Alter text to say that readelf supports archives
+ and 64-bit ELF files.
+
+2003-08-08 Nick Clifton <nickc@redhat.com>
+
+ * po/fr.po: Updated French translation.
+
+2003-08-05 Alan Modra <amodra@bigpond.net.au>
+
+ * objcopy.c: Remove unnecessary prototypes and casts.
+ * objdump.c: Remove unnecessary casts.
+ * readelf.c: Convert to C90. Remove unnecessary prototypes and casts.
+ (get_osabi_name): Move so we don't need a forward declaration.
+
+2003-08-04 Bradley Harrington <bharring@us.ibm.com>
+ Alan Modra <amodra@bigpond.net.au>
+
+ * objdump.c (include_paths, include_path_count): New vars.
+ (usage): Describe --include.
+ (long_options): Add "include".
+ (add_include_path): New function.
+ (struct print_file_list): Make filename const. Add modname.
+ (try_print_file_open, update_source_path): New functions.
+ (show_line): Use them.
+ (main): Handle 'I' option. Don't check for NULL xrealloc arg.
+
+2003-07-30 Alan Modra <amodra@bigpond.net.au>
+
+ * objdump.c: Remove unnecessary prototypes.
+ (disassemble_bytes): Add rel_offset parameter. Simplify reloc skipping
+ code, and print relocs when dump_dynamic_reloc_info.
+ (disassemble_data): Read and handle dynamic relocs. Correct reloc
+ skip code. Formatting.
+ (dump_bfd): Don't dump dynamic relocs when disassembling.
+
+2003-07-29 Ben Elliston <bje@wasabisystems.com>
+
+ * MAINTAINERS: Remove self as M88k maintainer. Future M88k
+ maintenance defaults to the blanket write privilege maintainers.
+
+2003-07-29 Michael Meissner <gnu@the-meissners.org>
+
+ * MAINTAINERS: Updated my email address.
+
+2003-07-29 Nick Clifton <nickc@redhat.com>
+
+ * objdump.c: Update to ISO C.
+
+2003-07-24 Nick Clifton <nickc@redhat.com>
+
+ * objdump.c (disassemble_data): Do not ignore sections without the
+ LOAD flag when disassemble_all is true. Only print a message
+ about disassembling a section if it contains some data.
+
+ * po/fr.po: Updated French translation.
+
+2003-07-23 Nick Clifton <nickc@redhat.com>
+
+ * objcopy.c: Switch to ISO C. Remove debugging code accidentally
+ left in. Some formatting tidy ups.
+
+2003-07-22 Salvador Eduardo Tropea <set@computer.org>
+
+ * objdump.c: New command line option --debugging-tags.
+ * doc/binutils.texi: Document new command line option.
+ * prdbg.c: Code to print the debug info as tags compatible
+ with ctags.
+ * budbg.h: Adjust prototype.
+ * NEWS: Mention new switch
+
+2003-07-18 Nick Clifton <nickc@redhat.com>
+
+ * objdump.c (main) :Accept multiple -M switch.
+ * doc/binutils.texi: Document that multiple -M switches are
+ accepted and that a single -M switch can contain comma
+ separated options.
+
+2003-07-17 Nick Clifton <nickc@redhat.com>
+
+ * objdump.c (main): Issue a warning message if multiple -M
+ switches are used.
+
+ * doc/binutils.texi (objdump): Update documentation about -M
+ option.
+
+2003-07-17 Nick Clifton <nickc@redhat.com>
+
+ * po/es.po: New Spanish translation.
+
+2003-07-11 Alan Modra <amodra@bigpond.net.au>
+
+ * po/binutils.pot: Regenerate.
+
+2003-07-05 Christopher Faylor <cgf@redhat.com>
+
+ * dlltool.c (prefix_encode): Use a fixed length for alpha.
+
+2003-07-04 Christopher Faylor <cgf@redhat.com>
+
+ * dlltool.c (prefix_encode): New function. Encode temp file prefix
+ from pid.
+ (dlltmp): Pass address of pointer being alloced or suffer neverending
+ mallocs.
+ (make_one_lib_file): Allocate enough space for new longer stub names.
+ (gen_lib_file): Ditto.
+ (main): Generate the temp file prefix from the pid if prefix was not
+ specified on the command line.
+
+2003-07-04 Nick Clifton <nickc@redhat.com>
+
+ * readelf.c (get_data): Print (unsigned) hex values for size and
+ offset in error messages.
+ (process_section_headers): If the string table could not be
+ allocated, do not continue.
+
+2003-07-01 Jakub Jelinek <jakub@redhat.com>
+
+ * readelf.c (dynamic_segment_ia64_val): Print address and newline
+ for sections by default. Comment fix.
+
+2003-06-28 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * rcparse.y (res_text_field): New res_id variable.
+ (res_null_text): New static const struct res_id object,
+ with empty unicode name field.
+ (control): Pop parsing of optresidc up one level. Set
+ res_text_field to $2 except for controls which do not accept
+ a text field. Set res_text_field to res_null_text for the
+ special cases (viz. COMBOBOX, EDITTEXT, LISTBOX, SCROLLBAR).
+ (control_params): Adjust to use res_text_field rather
+ than optresidc.
+ (COMBOBOX): Add comment about discrepency between documented
+ vs. observed default style.
+ * resrc.c (define_control): Make first param const.
+ * windres.h (define_control): Adjust prototype.
+
+2003-06-27 Nick Clifton <nickc@redhat.com>
+
+ * objcopy.c (copy_object): Replace call to
+ bfd_create_gnu_debuglink_section with separate calls to
+ bfd_add_gnu_debuglink_section and
+ bfd_fill_in_gnu_debuglink_section, separated by a walk over the
+ symbol tables.
+
+2003-06-26 Roland McGrath <roland@redhat.com>
+
+ * readelf.c (loadaddr): Variable removed.
+ (dynamic_info, version_info): Fix type long -> bfd_vma.
+ (program_headers): New variable.
+ (get_program_headers): New function, broken out of
+ process_program_headers.
+ (process_program_headers): Call it. Don't set `loadaddr'.
+ (slurp_ia64_unwind_table): Use get_program_headers.
+ (process_corefile_note_segments): Likewise.
+ (offset_from_vma): New function.
+ (process_relocs, process_dynamic_segment): Call that instead of
+ subtracting `loadaddr'.
+ (process_version_sections, process_symbol_table): Likewise.
+ (process_mips_specific): Likewise.
+
+2003-06-26 Nick Clifton <nickc@redhat.com>
+
+ * objcopy (enum strip_action): Add STRIP_NONDEBUG.
+ (OPTION_ONLY_KEEP_DEBUG): New.
+ (strip_options): Add --only-keep-debug.
+ (copy_options): Likewise.
+ (is_strip_section): Invert return value if STRIP_NONDEBUG is
+ active.
+ (copy_object): Do not copy private data when STRIP_NONDEBUG is
+ active.
+ (setup_section): Likewise.
+ (strip_main): Handle --only-keep-debug.
+ (copy_main): Likewise.
+ * NEWS: Mention new switch
+ * doc/binutils.texi: Document new switch.
+
+2003-06-25 Alan Modra <amodra@bigpond.net.au>
+
+ * NEWS: Correct spelling of "relocatable".
+ * objdump.c: Likewise.
+ * sysroff.info: Likewise.
+
+2003-06-19 Nick Clifton <nickc@redhat.com>
+
+ * readelf.c (print_vma): When printing DEC_5 values, if the
+ number is bigger than 99999 switch to using hexadecimal
+ notation.
+
+2003-06-11 Nick Clifton <nickc@redhat.com>
+
+ * objcopy.c (gnu_debuglink_filename): New variable.
+ (OPTION_ADD_GNU_DEBUGLINK): New switch
+ (copy_options): Describe --add-gnu-debuglink switch.
+ Mention that --strip-debug removes sections as well.
+ (is_strip_section): Process the sections removed and kept
+ lists before checking for debugging sections.
+ (add_redefine_syms_file): Make function static.
+ (copy_object): Use is_strip_section.
+ Check to see if a .gnu_debuglink section should be added. If
+ so, call bfd_add_gnu_debuglink.
+ (setup_section): Use is_strip_section.
+ (copy_section): Use is_strip_section.
+ (copy_main): Handle OPTION_ADD_GNU_DEBUGLINK.
+ * NEWS: Mention new objcopy switch.
+ * doc/binutils.texi: Document new switch.
+
+2003-06-11 H.J. Lu <hongjiu.lu@intel.com>
+
+ * po/Make-in (DESTDIR): New.
+ (install-data-yes): Support $(DESTDIR).
+ (uninstall): Likewise.
+
+2003-06-11 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.in: Regenerate.
+
+2003-05-23 Jakub Jelinek <jakub@redhat.com>
+
+ * readelf.c (get_segment_type): Handle PT_GNU_STACK.
+
+2003-06-03 Elias Athanasopoulos <elathan@phys.uoa.gr>
+
+ * NEWS: Document the new BSD/POSIX single-character mapping for
+ .comment/.note sections.
+
+2003-06-02 Chris Demetriou <cgd@broadcom.com>
+ Jason Thorpe <thorpej@wasabisystems.com>
+
+ * objcopy.c (redefine_list_append): Add an argument that
+ indicates the context from which this function is being
+ called. Change all callers.
+ (copy_options): Add a new option, --redefine-syms.
+ (copy_usage): Document new option.
+ (copy_main): Handle the --redefine-syms option.
+ * doc/binutils.text (objcopy): Document new option.
+
+2003-05-31 Richard Henderson <rth@redhat.com>
+
+ * readelf.c (byte_get_signed): New.
+ (get_encoded_value): New.
+ (display_debug_frames): Use it. Always pre-process opcodes.
+
+2003-05-20 Michal Ludvig <mludvig@suse.cz>
+
+ * readelf.c (display_debug_frames): Print both registers
+ for DW_CFA_register.
+
+2003-05-16 Kelley Cook <kelleycook@wideopenwest.com>
+
+ * configure.in: Accept i[3-7]86 variants. Escape '[]' for
+ i[3-7]86-*-interix.
+ * configure.in: Regenerate.
+
+2003-05-13 Michael Eager <eager@mvista.com>
+
+ * objcopy.c: Treat identical src/dst file names as if only one
+ entered. One Windows creating an output file of the same name as
+ the input file will delete the input file before it is read.
+
+2003-05-12 Salvador Eduardo Tropea <salvador@inti.gov.ar>
+
+ * debug.c (debug_get_real_type): Extend test for circular debug
+ references.
+
+2003-05-12 Nick Clifton <nickc@redhat.com>
+
+ * configure.in (ALL_LINGUAS): Add zh_CN.
+ * configure: Regenerate.
+ * po/zh_CN.po: New file: Chinese (simplified) translation.
+
+2003-05-11 Jason Eckhardt <jle@rice.edu>
+
+ * MAINTAINERS: Update my mail address.
+
+2003-05-07 H.J. Lu <hongjiu.lu@intel.com>
+
+ * readelf.c (dump_relocations): Enlarge the type field in wide
+ mode by one character.
+
+2003-05-03 Richard Henderson <rth@redhat.com>
+
+ * readelf.c (struct Frame_Chunk): Add cfa_exp.
+ (frame_display_row): Just print "exp" for cfa or register
+ defined by a location expression.
+ (display_debug_frames): Handle DW_CFA_def_cfa_expression,
+ DW_CFA_expression, DW_CFA_MIPS_advance_loc8.
+
+2003-04-30 H.J. Lu <hjl@gnu.org>
+
+ * objdump.c (only): Change it to char **.
+ (only_size): New.
+ (only_used): New.
+ (disassemble_data): Check only as an array.
+ (dump_data): Likewise.
+ (dump_relocs): Likewise.
+ (main): Treat only as an array.
+
+2003-04-24 Dimitrie O. Paun <dpaun@rogers.com>
+
+ * doc/binutils.texi: Fix the documentation for the -fo option.
+
+2003-04-23 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * readelf.c (get_machine_name) <EM_SH>: Amend return value
+ to refer to SuperH.
+
+ * readelf.c (decode_location_expression): Don't add a trailing ';'.
+
+2003-04-23 Dimitrie O. Paun <dpaun@rogers.com>
+ Nick Clifton <nickc@redhat.com>
+
+ * windres.c (long_options): Move close to main, where it is used.
+ Add 'input' and 'output' long options.
+ (main): Accept "-fo" as an alias for "-o". This is for rc
+ comptibility.
+ * doc/binutils.texi: Mention that -fo is accepted as an alias for
+ -o, but discourage its use.
+
+2003-04-22 Dimitrie O. Paun <dpaun@rogers.com>
+
+ * windres.c (format_from_name): Make the exit on error
+ behaviour optional.
+ (main): Rename the -I option to -J. Introduce -I as a synonym
+ for --include-dir. For backwards compatibility also support the
+ old -I behaviour, but issue a deprecation warning.
+ * doc/binutils.texi: Rename -I to -J. Document the new behaviour
+ of the -I option.
+
+2003-04-22 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
+
+ * readelf.c: Replace references to Mitsubishi M32R with
+ references to Renesas M32R.
+
+2003-04-15 Rohit Kumar Srivastava <rohits@kpitcummins.com>
+
+ * readelf.c: Replace occurrances of 'Hitachi' with 'Renesas'.
+
+2003-04-09 Alexandre Oliva <aoliva@redhat.com>
+
+ * doc/binutils.texi (objdump) [--debugging]: Suggest readelf -w
+ for debugging information types not supported by objdump.
+
+2003-04-09 Bernd Jendrissek <berndj@prism.co.za>
+
+ * configure.in: Recognize canonical form of i[3-6]86-pe*.
+ * configure: Regenerate.
+
+2003-04-09 Alexandre Oliva <aoliva@redhat.com>
+
+ * readelf.c (display_debug_info): Apply RELA relocations on the
+ entire section.
+ (byte_put_little_endian, byte_put_big_endian): New functions.
+ (byte_put): New variable.
+ (get_file_header): Initialize it.
+
+2003-04-05 Dimitrie O. Paun <dpaun@rogers.com>
+
+ * windres.c: Add -l for compatibility with wrc, and rc.
+ Use the short option as a key for long options that have
+ a synonymous short option.
+ * doc/binutils.texi: Added -l to the list of options.
+
+2003-04-03 Dimitrie O. Paun <dpaun@rogers.com>
+
+ * windres.c: Add -U for compatibility with wrc, rc, and cpp.
+ (main): Just pass the -U option down to the preprocessor.
+ * doc/binutils.texi: Added -U to the list of options.
+
+2003-04-01 Dimitrie O. Paun <dpaun@rogers.com>
+
+ * windres.c (usage): Report -r option.
+ (main): Ignore the -r option.
+ * doc/binutils.texi: Add -r to the list of options.
+
+2003-04-01 Bob Wilson <bob.wilson@acm.org>
+
+ * MAINTAINERS: Add myself as Xtensa maintainer.
+
+2003-04-01 Bob Wilson <bob.wilson@acm.org>
+
+ * readelf.c: Include "elf/xtensa.h".
+ (guess_is_rela): Add EM_XTENSA and EM_XTENSA_OLD to list of
+ targets that use RELA relocations.
+ (dump_relocations): Call elf_xtensa_reloc_type for
+ EM_XTENSA and EM_XTENSA_OLD.
+ (get_machine_name): Handle EM_XTENSA and EM_XTENSA_OLD.
+
+2003-04-01 Nick Clifton <nickc@redhat.com>
+
+ * configure.in: Change "arm-pe*" to "arm-*-pe*". Similarly for
+ thumb-pe*, mcore-pe and mcore-*elf.
+ * configure: Regenerate.
+
+2003-03-31 Alexandre Oliva <aoliva@redhat.com>
+
+ * objdump.c (dump_data): Don't truncate the address to long; make
+ the width large enough, and uniform for all entries in a section.
+
+2003-03-31 H.J. Lu <hjl@gnu.org>
+
+ * readelf.c: Include "libiberty.h".
+ (dynamic_relocations): New.
+ (process_relocs): Properly handle dynamic relocation.
+ (process_dynamic_segment): Fill relocation elements in
+ dynamic_info.
+
+2003-03-31 Kevin Buettner <kevinb@redhat.com>
+
+ * readelf.c (read_and_display_attr, read_and_display_attr_value):
+ Add new arguments ``offset_size'' and ``dwarf_version''. Adjust
+ all callers.
+ (display_debug_lines, display_debug_pubnames, display_debug_info)
+ (display_debug_aranges, display_debug_frames, read_and_display_attr)
+ (read_and_display_attr_value): Add 64-bit DWARF support.
+
+2003-03-31 Ian Lance Taylor <ian@airs.com>
+
+ * rcparse.y: Replace uses of 'optstringrc' with 'optresid'.
+ (optresid): Handle a resource id that can be a string or a number.
+ * resrc.c (define_control): Replace 'text' parameter with 'iid' a
+ struct res_id.
+ (define_icon_control): Pass a struct res_id to define_control.
+ * windres.h (define_control): Change prototype.
+
+2003-03-24 Elias Athanasopoulos <elathan@phys.uoa.gr>
+
+ * objcopy (OPTION_FORMATS_INFO): Define.
+ (strip_options): Add "info"/OPTION_FORMATS_INFO option.
+ (copy_options): Likewise.
+ (strip_usage): Add "--info" to usage.
+ (copy_usage): Likewise.
+ (strip_main): Declare formats_info. Iniatilize it to FALSE.
+ Handle "info".
+ (copy_main). Likewise.
+ * doc/binutils.texi. Document the "--info" option for
+ objcopy/strip.
+ * NEWS: Mention the new command line switch.
+
+ * objdump.c (endian_string): Move to bucomm.c.
+ (display_info): Likewise.
+ (display_target_list): Likewise.
+ (display_info_table): Likewise.
+ (display_target_tables): Likewise.
+ (main): Assign the return value of display_info to exit_status.
+ * bucomm.c: Include bfdver.h and libbfd.h
+ (display_target_list): Call bfd_nonfatal instead of nonfatal and
+ return 0 on a non-fatal error, 1 on success.
+ (display_info_table): Likewise.
+ * bucomm.h (display_info): Provide a prototype.
+ * Makefile.am (bucomm.o): Add dependencies on bfdver.h and
+ libbfd.h.
+ * Makefile.in: Regenerate.
+
+2003-03-22 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * dlltool.c (gen_def_file): Put demangled name comments on
+ own line preceding export name.
+
+2003-03-17 Nick Clifton <nickc@redhat.com>
+
+ * objdump.c (disassemble_data): Use disasm_info.fprintf_func not
+ printf for emitting new lines.
+
+2003-03-16 Elias Athanasopoulos <elathan@phys.uoa.gr>
+
+ * nm.c (print_symbol_info_bsd): Print the symbol's size instead of
+ the symbol's value when --size-sort is used, unless -S is used.
+ doc/binutils.texi (--size-sort): For non-bsd formats both the
+ value and size of the symbols are displayed.
+
+2003-03-13 Nick Clifton <nickc@redhat.com>
+
+ * po/da.po: Update.
+
+2003-03-12 Nick Clifton <nickc@redhat.com>
+
+ * MAINTAINERS: Remove Peter Targett as ARC maintainer.
+
+2003-03-10 Ben Elliston <bje@wasabisystems.com>
+
+ * MAINTAINERS: Update my mail address.
+
+2003-03-06 Elias Athanasopoulos <elathan@phys.uoa.gr>
+
+ * stabs.c (BYTES_IN_WORD): Remove definition.
+ * wrstabs.c (BYTES_IN_WORD): Likewise.
+
+2003-03-04 Nick Clifton <nickc@redhat.com>
+
+ * nm.c (main): Print a warning message if --size-sort and
+ --undefined-only are used together.
+
+2003-03-04 Elias Athanasopoulos <elathan@phys.uoa.gr>
+
+ * nm.c (print_symbol): Remove check for undefined_only.
+
+2003-03-03 Nick Clifton <nickc@redhat.com>
+
+ * po/da.po: Installed latest translation.
+
+2003-02-24 Nick Clifton <nickc@redhat.com>
+
+ * README: Update binutils references to 2.13.
+ Add paragraph about using --disable-nls.
+
+2003-02-24 Elias Athanasopoulos <elathan@phys.uoa.gr>
+
+ * doc/binutils.texi (nm --size-sort): Update.
+
+2003-02-21 James E Wilson <wilson@tuliptree.org>
+
+ * MAINTAINERS: Update email address.
+
+2003-02-21 Ian Wienand <ianw@gelato.unsw.edu.au>
+
+ * readelf.c (get_ia64_dynamic_type): New function.
+ (dynamic_segment_ia64_val): New function.
+ (get_dynamic_type): If machine type is EM_IA_64 call
+ get_ia64_dynamic_val.
+ (get_ia64_section_type_name): Handle sections with types in the
+ SHT_IA_64_LOPSREG to SHT_IA_64_HIPSREG range.
+ (get_dynamic_flags): If machine type is EM_IA_64 call
+ dynamic_segment_ia64_val.
+
+2003-02-21 Bob Wilson <bob.wilson@acm.org>
+
+ * doc/binutils.texi: Fix typos and obvious texinfo mistakes. Make
+ section title capitalization more consistent. Update descriptions
+ of various options to be consistent with the code. Fix errors and
+ incomplete list in the description of c++filt format options. Remove
+ information about the linker. Change to be more polite about poor
+ bug reports. Replace FDL appendix with include of fdl.texi.
+ * doc/fdl.texi: New file.
+
+2003-02-21 Roger Sayle <roger@eyesopen.com>
+
+ * objcopy.c (filter_symbols): Fix compilation problems with
+ HP-UX's C compiler.
+
+2003-02-19 Christopher Faylor <cgf@redhat.com>
+
+ * rclex.l (handle_quotes): Fix minor formatting problems introduced in
+ previous change.
+
+2003-02-19 Mark Blackburn <marklist@fangorn.ca>
+
+ * rclex.l (handle_quotes): Handle strings spanning more than one line.
+
+2003-02-12 Bob Wilson <bob.wilson@acm.org>
+
+ * nm.c (usage): Add `java' and `gnat' demangle styles and make
+ quotes consistent.
+ * objdump.c (usage): Ditto. Also fix some typos.
+
+ * readelf.c (parse_args): Include 'H' option in call to getopt_long.
+
+ * debug.c (debug_record_variable): Handle global register variables.
+
+ * stabs.c (parse_stab): For N_SLINE only include
+ function_start_offset if the symbol is within a function;
+ otherwise, the value is absolute.
+
+2003-02-10 Nick Clifton <nickc@redhat.com>
+
+ * readelf.c (decode_ARM_machine_flags): Handle the
+ EF_ARM_MAVERICK_FLOAT flag.
+
+2003-02-04 Andreas Schwab <schwab@suse.de>
+
+ * rddbg.c (read_section_stabs_debugging_info): Cast ptrdiff_t to
+ long and use %ld in printf format.
+
+2003-01-28 Richard Sandiford <rsandifo@redhat.com>
+
+ * readelf.c (dump_relocations): Reorder the r_info field for
+ little-endian mips elf64. Move #ifdef BFD64 to cover the new code.
+
+2003-01-21 Daniel Berlin <dan@dberlin.org>
+
+ * readelf.c (display_debug_loc): Skip address base changes.
+
+2003-01-17 Fabio Alemagna <falemagn@aros.org>
+
+ * readelf.c (get_osabi_name): Handle ELFOSABI_AROS, ELFOSABI_OPENVMS
+ and ELFOSABI_NSK.
+
+2003-01-16 Alan Modra <amodra@bigpond.net.au>
+
+ * readelf.c: Include elf/ppc64.h.
+ (dump_relocations <EM_PPC64>): Use elf_ppc64_reloc_type.
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2003-01-02 Ben Elliston <bje@redhat.com>
+
+ * readelf.c (guess_is_rela): Handle EM_IQ2000.
+ (get_machine_name): Likewise.
+ (dump_relocations): Likewise.
+ * NEWS: Mention IQ2000 support.
+
+2003-01-02 Richard Sandiford <rsandifo@redhat.com>
+
+ * readelf.c (get_machine_flags): Handle E_MIPS_ARCH_32R2.
+
+2002-12-30 Chris Demetriou <cgd@broadcom.com>
+
+ * doc/binutils.texi (objdump): Note MIPS HWR (Hardware Register)
+ changes in MIPS -M options.
+
+2002-12-30 Dmitry Diky <diwil@mail.ru>
+
+ * Makefile.am: Add msp430 target.
+ * Makefile.in: Regenerate.
+ * readelf.c: Add support for msp430 target.
+
+2002-12-27 Chris Demetriou <cgd@broadcom.com>
+
+ * doc/binutils.texi (objdump): Document MIPS -M options.
+
+2002-12-23 Andreas Schwab <schwab@suse.de>
+
+ * readelf.c (main): Reset dump request after each file.
+
+2002-12-23 Nick Clifton <nickc@redhat.com>
+
+ * nlmconv.c (main): Pass TRUE as third argument to
+ bfd_arch_get_compatible.
+
+2002-12-23 Nick Clifton <nickc@redhat.com>
+
+ * strings.c (isgraphic): Replace definition with STRING_ISGRAPHIC
+ macro. Handle 'S' encoding, accepting 8-bit characters.
+ (main): Parse 'S' encoding.
+ (get_char): Accept 'S' encoding.
+ (print_strings): Use STRING_ISGRAPHIC.
+ (usage): Document support of 'S' encoding.
+ * doc/binutils.texi: Document support of 'S' encoding/
+ * NEWS: Mention new feature.
+
+2002-12-20 Alan Modra <amodra@bigpond.net.au>
+
+ * README <building ar>: Don't use libibery's needed_list or
+ required_list, instead link libiberty/*.o.
+
+2002-12-19 Kazu Hirata <kazu@cs.umass.edu>
+
+ * doc/binutils.texi: Fix typos.
+
+2002-12-14 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * doc/binutils.texi: Add missing parenthesis.
+
+2002-12-15 Nick Kelsey <nickk@ubicom.com>
+
+ * objcopy.c: Add --prefix-symbols=<prefix> option to rename all
+ symbols by adding the given prefix to the begining of the symbol
+ name. This is useful to provide name space separation regardless
+ of how the object file was created. Added --prefix-sections=
+ <prefix> and --prefix-alloc-sections=<prefix> options to rename all
+ sections (or all sections with the alloc flag set) by adding the given
+ prefix to the begining of the symbol name.
+ * NEWS: Mention this new feature.
+ * doc/binutils.texi: Document this new feature.
+
+2002-12-13 Alan Modra <amodra@bigpond.net.au>
+
+ * dlltool.c (mcore_elf_gen_out_file): Replace all occurrences of
+ dyn_string_append with dyn_string_append_cstr.
+
+ * emul_aix.c (ar_emul_aix_create): Remove unused function.
+
+2002-12-10 James Cownie <jcownie@etnus.com>
+
+ * readelf.h (get_TAG_name, get_AT_name,
+ read_and_display_attr_value): Add support for UPC extensions to
+ DWARF2 spec.
+ * NEWS: Mention this new support.
+
+2002-12-08 Alan Modra <amodra@bigpond.net.au>
+
+ * NEWS: Mention that bfd no longer declares a "boolean" type.
+
+2002-12-07 Alan Modra <amodra@bigpond.net.au>
+
+ * readelf.c (process_program_headers): When setting loadaddr, don't
+ assume segment size is 4k. Use p_align instead.
+ (loadaddr): Change from int to long.
+ (dynamic_addr, dynamic_info, version_info): Likewise.
+ (process_dynamic_segment <syminsz>): Likewise.
+ (process_dynamic_segment): Adjust print format string.
+ (rela_addr, rela_size): Delete.
+ (process_relocs): Formatting.
+
+2002-12-05 Jim Wilson <wilson@redhat.com>
+
+ * configure.in (OBJDUMP_DEFS): Define SKIP_ZEROES as 16 for IA-64.
+ * configure: Regenerate.
+
+2002-12-04 Ian Lance Taylor <ian@airs.com>
+
+ * MAINTAINERS: Change e-mail address back to airs.com.
+
+2002-12-04 Aldy Hernandez <aldyh@redhat.com>
+
+ * MAINTAINERS: Add self.
+
+2002-11-30 Alan Modra <amodra@bigpond.net.au>
+
+ * addr2line.c, ar.c, arsup.c, binemul.c, binemul.h, bucomm.c, bucomm.h,
+ budbg.h, debug.c, debug.h, dlltool.c, emul_aix.c, ieee.c, nlmconv.c,
+ nlmconv.h, nlmheader.y, nm.c, objcopy.c, objdump.c, prdbg.c, rdcoff.c,
+ rddbg.c, readelf.c, rename.c, size.c, stabs.c, strings.c,
+ unwind-ia64.h, wrstabs.c: Replace boolean with bfd_boolean, true with
+ TRUE, false with FALSE. Simplify comparisons of bfd_boolean vars
+ with TRUE/FALSE. Formatting.
+
+2002-11-29 Jakub Jelinek <jakub@redhat.com>
+
+ * readelf.c Replace occurrences of Elf32_Internal_* and
+ Elf64_Internal_* with Elf_Internal_*.
+ (slurp_rel_relocs): Change Elf_Internal_Rel to Elf_Internal_Rela.
+ Zero r_addend fields.
+ (dump_relocations): Remove relas variable, change Elf_Internal_Rel to
+ Elf_Internal_Rela.
+
+2002-11-23 Nick Clifton <nickc@redhat.com>
+
+ * size.c (usage): Fix typo describing switch for hex format.
+
+2002-11-18 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * testsuite/binutils-all/objcopy.exp: Disable tic4x from test
+ * testsuite/binutils-all/objdump.exp: Setup proper values for tic4x
+ testcase
+
+2002-11-14 Nick Clifton <nickc@redhat.com>
+
+ * readelf.c (process_program_headers): Add comment about return
+ value. Ensure that 0 is returned if the headers are not loaded.
+ (process_file): If process_section_headers failed to load the
+ headers disable any tests that rely upon them. Similarly for
+ process_program_headers.
+
+2002-11-12 Nick Clifton <nickc@redhat.com>
+
+ * po/da.po: Updated Danish translation.
+
+2002-11-12 Klee Dienes <kdienes@apple.com>
+
+ * rddbg.c (read_section_stabs_debugging_info): Also recognize
+ LC_SYMTAB.stab/LC_SYMTAB.stabstr as a valid pair of sections.
+
+2002-11-11 Christopher Faylor <cgf@redhat.com>
+
+ * MAINTAINERS: Reinstate DJ Delorie as COFF maintainer. Drop COFF from
+ cgf maintainership.
+
+2002-11-11 Christopher Faylor <cgf@redhat.com>
+
+ * MAINTAINERS: Replace DJ Delorie as PE/COFF maintainer.
+
+2002-11-07 Nick Clifton <nickc@redhat.com>
+
+ * configure.in (ALL_LINGUAS): Add 'da'.
+ * configure: Regenerate.
+ * po/da.po: New Danish translation.
+
+ * readelf.c (get_symbol_index_type): Revert part of previous
+ patch: Display unknown symbol types in decimal, not hex.
+
+2002-11-07 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * dlltool.c (add_excludes): Don't prefix excluded fastcall
+ symbols with underscore.
+ (xlate): Ignore add_underscore for decorated fastcall symbols.
+
+2002-11-07 Eric Kohl <ekohl@rz-online.de>
+
+ * deflex.l: Accept '@' as first character of an ID.
+ * dlltool.c (gen_exp_file): Use existing '@' prefix rather than
+ ASM_PREFIX for fastcall symbols.
+ (scan_drectve_symbols): Handle fastcall symbols when generating
+ undecorated aliases for symbols in drectve section.
+ (scan_filtered_symbols): Likewise, with export-all.
+ (xlate): Likewise, with --kill-at.
+ (make_imp_label): New function to handle fastcall symbols
+ correctly.
+ (make_one_lib_file): Use make_imp_label instead of make_label
+ for imp symbols.
+
+2002-11-06 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * MAINTAINERS: Add self as TIC4X maintainer.
+
+2002-11-06 Hiroyuki Machida <machida@sm.sony.co.jp>
+
+ * readelf.c (get_symbol_index_type): Add hex number to
+ PROCESSOR-specific, OS-specific, reserved and unknown symbol
+ types.
+
+2002-11-04 Alan Modra <amodra@bigpond.net.au>
+
+ * readelf.c (byte_get_little_endian): Comment typo fix.
+ (print_symbol): Constify "symbol" arg. Don't pass "symbol" to printf
+ as the format string.
+ (dump_relocations): Correct section sym names.
+ (process_section_headers): Clear symtab_shndx_hdr.
+ (read_and_display_attr_value): Don't pass indirect string to printf
+ as the format string.
+ (display_debug_frames): Indicate when zero terminator found. Decode
+ DW_EH_PE_pcrel addresses.
+
+2002-10-23 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * configure.in: Define SKIP_ZEROES as 32 for tic4x target in
+ order to ensure proper disassembly of the valid 0-value opcode.
+ * configure: Regenerate.
+ * aclocal.m4: Regenerate.
+ * config.in: Regenerate.
+ * configure.in: Regenerate.
+ * doc/Makefile.in: Regenerate.
+ * po/binutils.pot: Regenerate.
+
+2002-10-23 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * MAINTAINERS: Add self as SH maintainer.
+
+2002-10-23 Ben Elliston <bje@redhat.com>
+
+ * doc/binutils.texi (objdump): Document -z and move the entry for
+ --disassemble-zeroes to the end of the options section (for `z').
+
+2002-10-21 Nick Clifton <nickc@redhat.com>
+
+ * MAINTAINERS: Discontinue Hans-Peter Nilsson as SH maintainer.
+
+2002-10-21 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * objdump.c (dump_data): Correct addr_offset for opb != 1.
+
+2002-10-15 Alan Modra <amodra@bigpond.net.au>
+
+ * bucomm.c (list_supported_targets): Use bfd_target_list.
+
+ * objcopy.c (copy_file): Report ambiguous bfd_object matches, and
+ other object errors in preference to bfd_core errors.
+
+2002-10-14 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * objdump.c: #include "bfdver.h".
+ * version.c: Likewise.
+ * Makefile.in: Regenerate.
+ * config.in: Regenerate.
+ * configure: Regenerate.
+ * po/POTFILES.in: Regenerate.
+
+2002-10-09 Daniel Jacobowitz <drow@mvista.com>
+
+ * readelf.c (display_debug_info): Ignore empty .rela.debug_info
+ sections. Allow relocations against the absolute symbol. Don't
+ use the value in compunit.cu_abbrev_offset if we found a RELA
+ relocation.
+
+2002-10-07 Gordon Chaffee <chaffee@netvmg.com>
+
+ * addr2line.c (slurp_symtab): Read in dynamic symbols if no
+ ordinary ones are available.
+
+2002-09-30 H.J. Lu <hjl@gnu.org>
+
+ * readelf.c (get_machine_flags): Handle E_MIPS_MACH_4120,
+ E_MIPS_MACH_5400 and E_MIPS_MACH_5500.
+
+2002-09-17 Zack Weinberg <zack@codesourcery.com>
+
+ * Makefile.am (CFILES): Add cxxfilt.c.
+ (cxxfilt_SOURCES): Now just cxxfilt.c $(BULIBS).
+ (cxxfilt_LDADD): Delete.
+ Remove all references to underscore.c.
+ Regen dependencies.
+ * configure.in: Define TARGET_PREPENDS_UNDERSCORE in
+ config.h from $UNDERSCORE, rather than AC_SUBSTing it.
+ * binutils/cxxfilt.c: Moved here from gcc/cp, minor
+ adjustments to fit into binutils framework.
+ * configure, config.in, Makefile.in, doc/Makefile.in: Regenerate.
+
+2002-09-12 Roland McGrath <roland@redhat.com>
+
+ * readelf.c (decode_location_expression): DW_OP_calli -> DW_OP_call_ref
+ Handle DW_OP_GNU_push_tls_address.
+
+2002-09-11 Nick Clifton <nickc@redhat.com>
+
+ * po/tr.po: Updated Turkish translation.
+
+2002-09-10 Nick Clifton <nickc@redhat.com>
+
+ * MAINTAINERS: Add Ben Elliston as a maintainer for configure and
+ testsuite changes. Add paragraphs about testsuite and config
+ patches.
+
+2002-08-29 Nick Clifton <nickc@redhat.com>
+
+ * readelf.c (get_machine_flags): Remove redundant reference to
+ E_V850EA_ARCH.
+
+2002-08-28 Alan Modra <amodra@bigpond.net.au>
+
+ * objdump.c (dump_bfd): Restore lines accidentally deleted in
+ last commit.
+
+2002-08-28 Michael Hayes <m.hayes@elec.canterbury.ac.nz>
+
+ * objdump.c (dump_headers): Add printing of HAS_LOAD_PAGE flag.
+ (dump_bfd_header): Likewise.
+
+2002-08-27 Alan Modra <amodra@bigpond.net.au>
+
+ * nm.c: Revert last change.
+
+2002-08-26 Alan Modra <amodra@bigpond.net.au>
+
+ * nm.c (display_rel_file): Don't report "no symbols" as an error.
+ * objdump.c (slurp_symtab): Likewise.
+ (slurp_dynamic_symtab): Likewise.
+ (dump_symbols): Likewise. Do print "no symbols" to stdout.
+
+2002-08-24 Geoffrey Keating <geoffk@redhat.com>
+
+ * MAINTAINERS: Change my mailing address.
+
+2002-08-23 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * MAINTAINERS: Add Dave Anglin as HPPA co-maintainer.
+
+2002-08-22 Nick Clifton <nickc@redhat.com>
+
+ * MAINTAINERS: Add Jeff Law as (maintainance) maintainer for
+ HPPA.
+
+2002-08-21 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * readelf.c (parse_args): Change debug_dump_opt to static.
+
+2002-08-16 Sivaguru Sankaridurg <siva@eternal-systems.com>
+
+ * stabs.c (parse_stab_argtype): Pass length of physname to
+ stab_demangle_argtypes.
+ (stab_demangle_argtypes): Add new parameter - length of physname.
+ Pass length of physname on to stab_demangle_prefix.
+ (stab_demangle_prefix): Add new parameter - length of physname.
+ Use length of physname (if supplied) to compute end of function
+ name.
+
+2002-08-15 Alan Modra <amodra@bigpond.net.au>
+
+ * readelf.c: Include elf/i370.h.
+ (dump_relocations): Handle EM_S370.
+ (dynamic_segment_parisc_val): Print \n.
+ (process_dynamic_segment <DT_BIND_NOW>): Here too.
+
+2002-08-14 Nick Clifton <nickc@redhat.com>
+
+ * nm.c (usage): Change 'gnu-new-abi' to 'gnu-v3'.
+ * objdump.c (usage): Likewise.
+ * doc/binutils.texi: Likewise.
+
+2002-08-14 Luke Dunstan <infidel@users.sourceforge.net>
+
+ * rcparse.y (acc_entry): Don't warn about ALT use with
+ non-VIRTKEY.
+
+2002-08-13 H.J. Lu <hjl@gnu.org>
+
+ * objcopy.c (copy_object): Don't warn about the unsupported
+ architecture unless the input target is defaulted or the
+ output architecture is different from the input.
+
+2002-08-09 Nick Clifton <nickc@redhat.com>
+
+ * po/sv.po: Updated Swedish translation.
+
+2002-08-05 Alan Modra <amodra@bigpond.net.au>
+
+ * prdbg.c (pr_fix_visibility): Remove assert.
+
+2002-07-31 Nick Clifton <nickc@redhat.com>
+
+ * addr2line.c (process_file): Rename parameter 'filename' to
+ 'file_name' in order to avoid shadowing global symbol of the
+ same name.
+ (main): Likewise.
+
+2002-07-30 Jakub Jelinek <jakub@redhat.com>
+
+ * readelf.c (OPTION_DEBUG_DUMP): Define.
+ (options): Use it.
+ (usage): Update help.
+ (parse_args): Handle --debug-dump separately from -w.
+ * doc/binutils.texi (readelf): Update documentation.
+
+2002-07-25 Nick Clifton <nickc@redhat.com>
+
+ * po/es.po: Updated Spanish translation.
+ * po/fr.po: Updated French translation.
+
+2002-07-24 Nick Clifton <nickc@redhat.com>
+
+ * po/es.po: Updated Spanish translation.
+
+2002-07-23 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2002-07-23 Nick Clifton <nickc@redhat.com>
+
+ * po/fr.po: Updated French translation.
+
+2002-07-23 Eric S. Raymond <esr@golux.thyrsus.com>
+
+ * doc/binutils.texi (addr2line <man synopsis>): Correct brackets.
+
+2002-07-20 Alan Modra <amodra@bigpond.net.au>
+
+ * budemang.c: Include config.h and string.h/strings.h.
+
+2002-07-18 Denis Chertykov <denisc@overta.ru>
+ Frank Ch. Eigler <fche@redhat.com>
+
+ * readelf.c: Include "elf/ip2k.h".
+ (guess_is_rela): Add support for EM_IP2K and EM_IP2K_OLD.
+ (dump_relocations): Likewise.
+ (get_machine_name): Likewise.
+ * NEWS: Mention IP2K support.
+
+2002-07-16 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * NEWS: Add 'Changes in 2.13'.
+
+2002-07-10 Jakub Jelinek <jakub@redhat.com>
+
+ * readelf.c (get_dynamic_type): Handle DT_GNU_PRELINKED,
+ DT_GNU_CONFLICT* and DT_GNU_LIBLISZ*.
+ (get_section_type_name): Handle SHT_GNU_LIBLIST.
+ (process_dynamic_segment): Handle DT_GNU_CONFLICTSZ,
+ DT_GNU_LIBLISTSZ and DT_GNU_PRELINKED.
+ (process_gnu_liblist): New.
+ (process_file): Call it.
+
+2002-07-03 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (check-DEJAGNU): Revert 2002-06-25 change.
+ * Makefile.in: Regenerate.
+
+2002-07-02 Alan Modra <amodra@bigpond.net.au>
+
+ * budemang.c: New file, "demangle" function.
+ * budemang.h: New file.
+ * addr2line.c (translate_addresses): Use "demangle".
+ * nm.c (print_symname): Likewise.
+ * objdump.c (objdump_print_symname): Likewise.
+ (dump_symbols): Likewise. Also, don't use bfd_asymbol_name macro
+ here since that obfuscates.
+ * rdcoff.c: Don't #include demangle.h.
+ * Makefile.am (CFILES): Add budemang.c, emul_aix.c,
+ emul_vanilla.c. Remove emul_$(EMULATION).c. Sort.
+ (HFILES): Add budemang.h. Sort.
+ (nm_new_SOURCES, objdump_SOURCES, addr2line_SOURCES): Add budemang.c.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2002-07-01 Matt Thomas <matt@3am-software.com>
+
+ * readelf.c: Include "elf/vax.h".
+ (guess_is_rela): Move EM_VAX from unknown to RELA case.
+ (dump_relocations): Handle VAX relocations.
+ (get_machine_flags): Handle VAX machine flags.
+
+2002-06-29 Stephane Carrez <stcarrez@nerim.fr>
+
+ * readelf.c (dump_relocations): Handle 68HC11/68HC12 relocations.
+
+2002-06-26 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * MAINTAINERS: Remove Tom Rix from d10v and pcc maintainerships.
+
+2002-06-26 Alan Modra <amodra@bigpond.net.au>
+
+ * nm.c (print_symname): When demangling, strip leading dots from
+ symbol names to avoid confusing the demangler.
+
+2002-06-25 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.am (check-DEJAGNU): Set LC_ALL=C and export it.
+ * Makefile.in: Regenerated.
+
+2002-06-21 Igor Schein <igor@txc.com>
+
+ * configure.in: Quote bu_cv_have_fopen64.
+ * configure: Regenerate.
+
+2002-06-21 Mitsru Chinen <chinen@jp.ibm.com>
+
+ * configure.in: Check for strcoll.
+ * configure: Regenerate.
+ * config.in: Regenerate.
+ * nm.c (main): Set locale for LC_COLLATE category.
+ (non_numeric_forward): Use strcoll if available.
+
+2002-06-20 Dave Brolley <brolley@redhat.com>
+
+ * MAINTAINERS: Add self as fr30 and frv maintainer.
+
+2002-06-18 H.J. Lu (hjl@gnu.org)
+
+ * nm.c: Include "elf/common.h".
+ (extended_symbol_info): Add elfinfo, a pointer to
+ elf_symbol_type.
+ (SYM_SIZE): Use elfinfo if it is not NULL.
+ (get_symbol_type): New function.
+ (display_archive): Set print_width for each archive member.
+ (display_file): Likewise.
+ (display_rel_file): Don't set print_width here.
+ (print_object_filename_sysv): Handle print_width.
+ (print_archive_member_sysv): Likewise.
+ (print_symbols): Pass (bfd_vma) 0 to print_symbol.
+ (print_symbol): Set the elfinfo field in extended_symbol_info
+ for ELF.
+ (print_object_filename_sysv): Fix the output format.
+ (print_symbol_info_sysv): Print type and section for ELF.
+
+2002-06-18 Elias Athanasopoulos <eathan@otenet.gr>
+
+ * nm.c (print_size_symbols): Remove assignment, which makes
+ the symbol's size equal to its value when --size-sort is
+ used.
+
+2002-06-18 Dave Brolley <brolley@redhat.com>
+
+ From Catherine Moore:
+ * readelf.c (elf/frv.h): #include it.
+ (guess_is_rela): Support EM_CYGNUS_FRV.
+ (dump_relocations): Ditto.
+ (get_machine_name): Ditto.
+ * Makefile.am (readelf.o): add dependency on $(INCDIR)/elf/frv.h.
+
+2002-06-18 Jakub Jelinek <jakub@redhat.com>
+
+ * readelf.c (get_file_header): Only read the first section header if
+ e_shoff is non-zero.
+
+2002-06-15 H.J. Lu (hjl@gnu.org)
+
+ * nm.c (print_size): New variable. Initialize to 0.
+ (long_options): Add 'S'/"print-size".
+ (main): Handle 'S'.
+ (print_symbol_info_bsd): Print size only if print_size is not
+ 0.
+
+ * doc/binutils.texi: Document -S/--print-size.
+
+2002-6-13 Elias Athanasopoulos <eathan@otenet.gr>
+
+ * nm.c (struct extended_symbol_info): New structure: Add the size
+ of the symbols to the information provided by the symbol_info
+ structure.
+ (print_symbols): Pass the symbol size to print_symbol.
+ (print_size_symbols): Pass the symbol size to print_symbol.
+ (print_symbol): Extra argument: The size of the symbol. Store
+ this in the extended_symbol_info structure.
+ (print_symbol_info): Change type of info parameter to
+ extended_symbol_info. Display the size, if known.
+ (print_symbol_info_posix): Likewise.
+ (print_symbol_info_sysv): Likewise.
+
+2002-06-08 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * doc/Makefile.in: Regnerate.
+
+ * bucomm.c: Replace CONST with const.
+ * nm.c: Likewise.
+ * objdump.c: Likewise.
+
+2002-06-07 H.J. Lu <hjl@gnu.org>
+
+ * readelf.c (DW_CFA_GNU_args_size): Don't define.
+ (DW_CFA_GNU_negative_offset_extended): Likewise.
+ (DW_CFA_GNU_window_save): Likewise.
+ (display_debug_frames): Handle DW_CFA_offset_extended_sf,
+ DW_CFA_def_cfa_sf and DW_CFA_def_cfa_offset_sf.
+
+2002-06-07 Elias Athanasopoulos <eathan@otenet.gr>
+
+ * nm.c: When computing size of symbols for an ELF target use the
+ internal size field.
+
+2002-06-06 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * testsuite/binutils-all/objcopy.exp: clear xfail for
+ "hppa*64*-*-hpux*".
+ * testsuite/binutils-all/hppa/objdump.exp: Return if
+ "*64*-*-*".
+
+2002-06-05 Alan Modra <amodra@bigpond.net.au>
+
+ * objcopy.c (copy_section): Don't copy SEC_GROUP sections.
+
+2002-06-03 Elias Athanasopoulos <eathan@otenet.gr>
+
+ * objdump.c: Fix formatting.
+
+2002-05-29 Ben Elliston <bje@redhat.com>
+
+ * MAINTAINERS: Add self as M68k maintainer.
+
+2002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
+
+ * readelf.c: Modified/Added DLX elf support.
+
+2002-05-27 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * arsup.c: Fix formatting.
+ * debug.c (debug_record_label): Add missing colon to error
+ message.
+ * ieee.c (parse_ieee_ty): Fix spelling typo.
+ * readelf.c (process_program_headers): Remove English assumption
+ about making a plural word.
+ (process_section_headers): Likewise.
+ (process_relocs): Allow quotes to be translated.
+ (process_unwind): Likewise,
+ (process_mips_specific): Improve error message.
+ (get_note_type): Fix spelling typo.
+
+ * configure.in (ALL_LINGUAS): Add sv
+ * po/sv.po: New file.
+
+2002-05-27 Alan Modra <amodra@bigpond.net.au>
+
+ * unwind-ia64.c (unw_print_brmask): Don't use sprintf.
+ (unw_print_grmask): Likewise.
+ (unw_print_frmask): Likewise.
+
+2002-05-26 Kazu Hirata <kazu@cs.umass.edu>
+
+ * arsup.c: Remove ARGSUSED.
+ * debug.c: Likewise.
+ * ieee.c: Likewise.
+ * nlmconv.c: Likewise.
+ * prdbg.c: Likewise.
+ * stabs.c: Likewise.
+ * wrstabs.c: Likewise.
+
+2002-05-25 Alan Modra <amodra@bigpond.net.au>
+
+ * arlex.l: Use #include "" instead of <> for local header files.
+ * coffdump.c: Likewise.
+ * coffgrok.c: Likewise.
+ * nlmconv.c: Likewise.
+ * nlmheader.y: Likewise.
+ * srconv.c: Likewise.
+ * strings.c: Likewise.
+ * sysdump.c: Likewise.
+ * unwind-ia64.h: Likewise.
+ * windres.h: Likewise.
+ * winduni.h: Likewise.
+
+2002-05-24 Tom Rix <trix@redhat.com>
+
+ * MAINTAINERS: Add self as the d10v maintainer.
+
+2002-05-24 TAMURA Kent <kent@netbsd.org>
+
+ * configure.in: Builds dlltool for i386-netbsdpe.
+ * configure: Regenerate.
+
+2002-05-23 Kazu Hirata <kazu@cs.umass.edu>
+
+ * size.c: Fix formatting.
+ * srconv.c: Likewise.
+ * stabs.c: Likewise.
+ * sysdump.c: Likewise.
+ * unwind-ia64.c: Likewise.
+ * wrstabs.c: Likewise.
+
+2002-05-23 Jakub Jelinek <jakub@redhat.com>
+
+ * readelf.c (get_segment_type): Add PT_TLS.
+ (get_elf_section_flags): Add SHF_TLS.
+ (get_dynamic_flags): Optimize. Add DF_STATIC_TLS.
+ (process_dynamic_segment): Use puts instead of printf.
+ (get_symbol_type): Support STT_TLS.
+ * objdump.c (dump_section_header): Remove SEC_CONSTRUCTOR_TEXT,
+ SEC_CONSTRUCTOR_DATA, SEC_CONSTRUCTOR_BSS.
+ Add SEC_THREAD_LOCAL.
+
+2002-05-23 Kazu Hirata <kazu@cs.umass.edu>
+
+ * rdcoff.c: Fix formatting.
+ * rddbg.c: Likewise.
+ * readelf.c: Likewise.
+ * rename.c: Likewise.
+ * resbin.c: Likewise.
+ * resrc.c: Likewise.
+ * resres.c: Likewise.
+
+2002-05-21 Kazu Hirata <kazu@cs.umass.edu>
+
+ * filemode.c: Fix formatting.
+ * ieee.c: Likewise.
+ * is-ranlib.c: Likewise.
+ * is-strip.c: Likewise.
+ * maybe-ranlib.c: Likewise.
+ * maybe-strip.c: Likewise.
+ * nlmconv.c: Likewise.
+ * nm.c: Likewise.
+ * not-ranlib.c: Likewise.
+ * not-strip.c: Likewise.
+ * objcopy.c: Likewise.
+ * objdump.c: Likewise.
+
+2002-05-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * objdump.c (dump_headers): Fix output formatting for ELF32
+ architectures in a BFD64 enabled toolchain.
+
+2002-05-20 Kazu Hirata <kazu@cs.umass.edu>
+
+ * debug.c: Fix formatting.
+ * debug.h: Likewise.
+ * dlltool.c: Likewise.
+ * dllwrap.c: Likewise.
+ * emul_aix.c: Likewise.
+ * emul_vanilla.c: Likewise.
+
+2002-05-19 Kazu Hirata <kazu@cs.umass.edu>
+
+ * addr2line.c: Fix formatting.
+ * ar.c: Likewise.
+ * arsup.c: Likewise.
+ * arsup.h: Likewise.
+ * binemul.c: Likewise.
+ * binemul.h: Likewise.
+ * bucomm.c: Likewise.
+ * coffdump.c: Likewise.
+ * coffgrok.c: Likewise.
+ * coffgrok.h: Likewise.
+
+2002-05-16 Marek Michalkiewicz <marekm@amelek.gda.pl>
+
+ * MAINTAINERS: Add myself as the second AVR port maintainer.
+
+2002-05-16 Stephane Carrez <stcarrez@nerim.fr>
+
+ * MAINTAINERS: Update my email address.
+
+2002-05-09 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * MAINTAINERS: Add Jason Thorpe as VAX maintainer.
+
+2002-05-09 Alan Modra <amodra@bigpond.net.au>
+
+ * configure.in: Replace `*pe' with `pe' throughout.
+ * configure: Regenerate.
+
+2002-05-07 Federico G. Schwindt <fgsch@olimpo.com.br>
+
+ * Makefile.am: Honour DESTDIR.
+ * Makefile.in: Regenerate.
+
+2002-05-06 Alan Modra <amodra@bigpond.net.au>
+
+ * dlltool.c (process_def_file): Add missing prototype.
+ (new_directive, assemble_file, main): Likewise.
+ (process_def_file, new_directive): Make static.
+ (inform): Rewrite using VA_FIXEDARG.
+ * dllwrap.c (mybasename): Add missing prototype.
+ (strhash, main): Likewise.
+ (inform): Rewrite using VA_FIXEDARG.
+ (warn): Likewise.
+ (cleanup_and_exit): Use old style function definition.
+ (strhash): Likewise.
+ * windres.c (define_resource): Use one memset to clear all of
+ struct res_resource.
+
+ * rcparse.y: Remove newcmd rule. Move rcparse_discard_strings
+ call to rules that need no lookahead. Check for no lookahead.
+
+2002-05-06 Borut Razem <borut.razem@siol.net>
+
+ * rclex.l (get_string): Correct "strings" list handling.
+ * resrc.c (read_rc_file): Discard strings.
+
+2002-05-04 Alan Modra <amodra@bigpond.net.au>
+
+ * ar.c (replace_members): Remove unused var. Formatting fix.
+ * binemul.c (ar_emul_default_parse_arg): Add ATTRIBUTE_UNUSED.
+
+ * MAINTAINERS: Sort port maintainers by CPU.
+
+2002-05-04 Bob Byrnes <byrnes@curl.com>
+
+ * size.c (display_archive): Add last_arfile and code to close archives.
+
+2002-05-01 Alan Modra <amodra@bigpond.net.au>
+
+ * nm.c (print_symbol): Check returned filename from
+ bfd_find_nearest_line is non-NULL.
+
+2002-04-25 Elena Zannoni <ezannoni@redhat.com>
+
+ * readelf.c (get_AT_name): Handle DW_AT_GNU_vector.
+
+2002-04-24 Christian Groessler <chris@groessler.org>
+
+ * MAINTAINERS: Changed my email address.
+
+2002-04-17 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * arparse.y: Fix syntax warning.
+
+2002-04-16 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * readelf.c (fetch_location_list): Remove unused function.
+
+ * readelf.c (process_corefile_note_segment): Catch corrupt notes
+ and display a warning message, then exit the loop.
+
+ * rcparse.y: Set MEMFLAG_DISCARDABLE by default.
+
+2002-04-15 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * resrc.c (write_rc_dialog): If charset is non-default value
+ display all of the DIALOGEX parameters.
+
+2002-04-15 Eric Kohl <ekohl@rz-online.de>
+
+ * rcparse.y: Allow two to five parameter in FONT statement of
+ DIALOGEX resources.
+ * resbin.c (bin_to_res_dialog): Fixed read/write code for dialogex
+ resource data.
+ (res_to_bin_dialog): Likewise.
+ * windres.h: Added misssing charset variable to dialog_ex
+ structure.
+
+2002-04-10 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * rcparse.y: Set MEMFLAG_PURE by default.
+
+2002-04-09 Bernd Herd <info@herdsoft.com>
+
+ * rcparse.y: CLASS definitions in DIALOG resources
+ are quoted.
+ Fix typo in BEDIT warning.
+ Don't add default dialog style when explicit style specified.
+ Add WS_CAPTION dialog style if CAPTION is specified.
+
+ * rclex.l (handle_quotes): "\xhex" encoding in strings corrected.
+ (handle_quotes) "\a" escape (used for right justified key
+ definitions in menus) is encodes as binary 8.
+
+ * resrc.c (write_rc_dialog): Print style even if it is 0.
+ (write_rc_directory): Fix overlooked sublang shift bug.
+ (bin_to_res_dialog): Don't print empty dialog caption.
+
+ * resbin.c (bin_to_res_dialog): Use signature to identify
+ DIALOGEX.
+
+ * windres.c (main): Set default LANGUAGE to english/us.
+
+2002-04-09 Gunnar Degnbol <degnbol@danbbs.dk>
+
+ * resrc.c: print CLASS names in quotes
+
+2002-04-09 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * MAINTAINERS: Update my email address.
+
+2002-04-04 Alan Modra <amodra@bigpond.net.au>
+
+ * dep-in.sed: Cope with absolute paths.
+ * Makefile.am (dep.sed): Subst TOPDIR.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2002-03-27 Peter Targett <peter.targett@arc.com>
+
+ * MAINTAINERS: Update my email address.
+
+2002-03-21 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * doc/Makefile.in: Regenerate.
+ * po/POTFILES.in: Regenerate.
+ * aclocal.m4: Regenerate.
+ * config.in: Regenerate.
+ * configure: Regenerate.
+
+2002-03-20 Daniel Berlin <dan@dberlin.org>
+
+ * readelf.c: Add support for displaying dwarf2 location lists.
+ (do_debug_loc, debug_loc_section, debug_loc_size): New.
+ (parse_args): Use 'O' as shorthand for displaying location list
+ section.
+ (process_section_headers): Handle debug_loc as well.
+ (load_debug_loc): New.
+ (free_debug_loc): New.
+ (fetch_location_list): New.
+ (display_debug_loc): New.
+ (display_debug_info): Call load_debug_loc and free_debug_loc.
+ (debug_displays): We can display .debug_loc now, too.
+ (usage): Update usage string.
+ (read_and_display_attr_value): Note location lists, but don't
+ display them inline.
+
+2002-03-18 Tom Rix <trix@redhat.com>
+
+ * Makefile.am: Add binutils emulation support.
+ * configure.in: Same.
+ * configure.tgt: New file. Same.
+ * ar.c (main): Use ar_emul_parse_arg.
+ (usage): Use ar_emul_usage.
+ (replace_members): Use ar_emul_replace, ar_emul_append.
+ * binemul.c: New file. Define the binutils emulation
+ layer. Define default methods.
+ * binemul.h: New file. Binutils emulation layer header file.
+ * emul_aix.c: New file. AIX binutils emulation.
+ * emul_vanilla.c: New file. Default binutils emulation.
+ * Makefile.in: Regenerate.
+ * configure: Same.
+
+2002-03-18 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/fr.po: Updated version.
+
+2002-03-13 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/fr.po: Updated version.
+
+2002-03-07 Daniel Jacobowitz <drow@mvista.com>
+
+ * README: Update some version numbers.
+
+2002-03-07 Daniel Jacobowitz <drow@mvista.com>
+
+ * doc/binutils.texi (Target Selection): Fix LD crossreferences.
+ (Architecture Selection): Likewise.
+
+2002-03-01 Dmitry Timoshkov <dmitry@baikal.ru>
+
+ * dlltool.c (gen_exp_file): Take into account --kill-at (-k) while
+ generating .exp file.
+
+2002-02-21 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * readelf.c (dump_relocations): Fix typo.
+
+2002-02-20 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * NEWS: Mark 2.12 branch.
+
+2002-02-18 Timothy Daly <remote_bob@yahoo.com>
+
+ * readelf.c (dump_relocations): Display 2nd and 3rd reloc
+ types for 64-bit MIPS. Narrow some fields for 80-char
+ output.
+ (dump_relocations): Change spelling from 'unrecognised'
+ to 'unrecognized'.
+ (decode_ARM_machine_flags): Likewise.
+ (parse_args): Likewise.
+ (read_and_display_attr_value): Likewise.
+ (display_debug_section): Likewise.
+
+2002-02-15 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * NEWS: Mention support for MMIX.
+
+2002-02-13 Matt Fredette <fredette@netbsd.org>
+
+ * readelf.c (get_machine_flags): Recognize EF_M68000.
+
+2002-02-12 Alexandre Oliva <aoliva@redhat.com>
+
+ * MAINTAINERS: Added self as MN10300 co-maintainer.
+
+2002-02-12 Alan Modra <amodra@bigpond.net.au>
+
+ * readelf.c (get_ppc64_dynamic_type): Handle DT_PPC64_OPD and
+ DT_PPC64_OPDSZ.
+
+2002-02-11 Daniel Jacobowitz <drow@mvista.com>
+
+ * MAINTAINERS: List myself as branch maintainer.
+
+2002-02-11 Alan Modra <amodra@bigpond.net.au>
+
+ * configure: Regenerate.
+ * objcopy.c: Update copyright date.
+ * doc/Makefile.in: Regenerate.
+
+2002-02-10 Daniel Jacobowitz <drow@mvista.com>
+
+ * nlmconv.c: Back out localtime PARAMS change.
+
+2002-02-11 Alan Modra <amodra@bigpond.net.au>
+
+ * objcopy.c (MKDIR): Define.
+ (copy_archive): Make name_list.name const. Use MKDIR.
+ Handle duplicate files in archives by making more temp dirs.
+
+2002-02-10 Daniel Jacobowitz <drow@mvista.com>
+
+ * coffdump.c: Include "getopt.h" after "bucomm.h"
+ so that macros are defined correctly.
+ * nlmconv.c: Add PARAMS ((const time_t *)) to localtime
+ prototype. Prototype main.
+ * nlmheader.y: Add PARAMS ((int)) to strerror prototype.
+
+2002-02-06 Alexandre Oliva <aoliva@redhat.com>
+
+ * MAINTAINERS: Added self as SH co-maintainer.
+
+2002-02-05 Nick Clifton <nickc@redhat.com>
+
+ * po/tr.po: Updated translation.
+
+2002-02-01 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am"
+ * Makefile.in: Regenerate.
+
+2002-01-29 Daniel Jacobowitz <drow@mvista.com>
+
+ * nm.c (print_value): Mark abfd unused.
+
+2002-01-29 Daniel Jacobowitz <drow@mvista.com>
+
+ * unwind-ia64.c (unw_decoder): Change second argument
+ to unsigned int, to match function prototypes.
+
+2002-01-29 Daniel Jacobowitz <drow@mvista.com>
+
+ * objdump.c: Include "getopt.h" after "bucomm.h" so that
+ __GNU_LIBRARY__ will be defined.
+ * size.c: Likewise.
+
+2002-01-27 Daniel Jacobowitz <drow@mvista.com>
+
+ * configure: Regenerated.
+
+2002-01-26 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * doc/Makefile.am (install): Depend on install-info.
+ * doc/Makefile.in: Regenerate.
+
+2002-01-25 Jason R. Thorpe <thorpej@wasabisystems.com>
+
+ * objcopy.c (strip_usage): Document -d as an alias
+ --strip-debug.
+
+ * size.c (usage): Document [-t | --totals] options.
+ (long_options): Add --totals option.
+ (main): If the [-t | --totals] option is specified and
+ the output format is Berkeley-style, print the total
+ text, data, and bss sizes of all objects listed.
+ (print_berkeley_format): If the [-t | --totals] option
+ is specified, track the total text, data, and bss
+ sizes.
+ * doc/binutils.texi (size): Document [-t | --totals] options.
+ (strip): Document -d as an alias for --strip-debug.
+ * NEWS: Mention new feature of size.
+
+2002-01-25 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/fr.po: Updated version.
+ * po/es.po: Updated version.
+
+2002-01-23 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * addr2line.c (usage): Update text to provide verbose
+ description of the command line options.
+ * ar.c (usage): Update text to provide verbose
+ description of the command line options.
+ (main): Accept -h and -H when running as ranlib.
+ * coffdump.c (show_usage): Update text to provide verbose
+ description of the command line options.
+ * dlltool.c (main): Accept -H as an alias for --help.
+ * nlmconv.c (show_usage): Update text to provide verbose
+ description of the command line options.
+ * nm.c (usage): Replace OPTIONS with option(s).
+ (main): Accept -H as an alias for --help.
+ * objcopy.c (strip_main): Accept -H as an alias for --help.
+ * objdump.c (main): Accept -v as an alias for --verbose.
+ * readelf.c (usage): Adjust format to match style used in
+ other binutils.
+ * size.c (usage): Update text to provide verbose description
+ of the command line options.
+ (main): Accept -v, -h and -H as command line options.
+ * srconv.c (show_usage): Update text to provide verbose
+ description of the command line options.
+ * strings.c (main): Accept -H and -v as command line options.
+ (usage): Update text to provide verbose description of the
+ command line options.
+ * sysdump.c (show_usage): Update text to provide verbose
+ description of the command line options.
+ * windres.c (usage): Adjust format to match style used in
+ other binutils.
+
+ * coffdump.c: Fix formatting.
+ * nlmconv.c: Fix formatting.
+ * srconv.c: Fix formatting.
+ * sysdump.c: Fix formatting.
+
+2002-01-22 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2002-01-18 Andreas Jaeger <aj@suse.de>
+
+ * version.c (print_version): Update year.
+
+2002-01-17 Alan Modra <amodra@bigpond.net.au>
+
+ * readelf.c (get_machine_name): Handle EM_PPC64.
+ (guess_is_rela): Here too.
+
+2002-01-17 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/binutils.pot: Regenerate.
+ * po/fr.po: Regenerate.
+ * po/tr.po: Regenerate.
+
+2002-01-16 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/tr.po: Import new version.
+
+2002-01-16 Alan Modra <amodra@bigpond.net.au>
+
+ * readelf.c (get_ppc64_dynamic_type): New.
+ (get_dynamic_type): Call it.
+
+2002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * objcopy.c (copy_usage): Use "options" instead of "switches".
+ (strip_usage): Use "options" instead of "switches".
+ * doc/binutils.texi (dlltool): Refer to "options" instead of
+ "switches".
+
+2002-01-14 Richard Earnshaw <rearnsha@arm.com>
+
+ * MAINTAINERS: Add self as co-maintainer for the ARM code.
+
+2001-12-18 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/es.po: Import from translation project.
+ * configure.in (ALL_LINGUAS): Add es.
+ * configure: Regenerate.
+
+2002-01-09 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * readelf.c (get_netbsd_elfcore_note_type): Use
+ NT_NETBSDCORE_PROCINFO and NT_NETBSDCORE_FIRSTMACH.
+
+2002-01-09 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * readelf.c: Update copyright years.
+ (get_note_type): Return a const char *.
+ (get_netbsd_elfcore_note_type): New function.
+ (process_note): Use get_netbsd_elfcore_note_type to get
+ the note type string for NetBSD ELF core files.
+
+2002-01-06 Steve Ellcey <sje@cup.hp.com>
+
+ * readelf.c (get_ia64_segment_type): Add support for macros.
+ (get_segment_type): Add support for IA64 specific macros.
+
+For older changes see ChangeLog-0001
+
+Local Variables:
+mode: change-log
+left-margin: 8
+fill-column: 74
+version-control: never
+End:
diff --git a/contrib/binutils/binutils/ChangeLog-9197 b/contrib/binutils/binutils/ChangeLog-9197
index 1ed5416..9861315 100644
--- a/contrib/binutils/binutils/ChangeLog-9197
+++ b/contrib/binutils/binutils/ChangeLog-9197
@@ -2394,7 +2394,7 @@ Thu Jul 13 10:43:59 1995 Ian Lance Taylor <ian@cygnus.com>
* nlmconv.c (powerpc_mangle_relocs): Cast memset arg to size_t.
* objcopy.c (copy_object): Likewise.
- * nm.c (HAVE_SBRK): Define execpt on amigados and WINDOWS_NT.
+ * nm.c (HAVE_SBRK): Define except on amigados and WINDOWS_NT.
(struct size_sym): Define.
(show_stats): New static variable.
(long_options): Add undocumented option "stats".
@@ -5200,7 +5200,7 @@ Thu May 16 16:06:55 1991 Steve Chamberlain (steve at cygint.cygnus.com)
consistent with gdb and as: Add 0x when printing hex.
Don't print extra leading zeros.
Attempt to not print "filename.o".
- * objdump.c: Add some enum-to-int casts to accomodate old compilers.
+ * objdump.c: Add some enum-to-int casts to accommodate old compilers.
Fri May 3 22:21:44 1991 John Gilmore (gnu at cygint.cygnus.com)
diff --git a/contrib/binutils/binutils/ChangeLog-9899 b/contrib/binutils/binutils/ChangeLog-9899
index 22f21e2..ad1fdc7 100644
--- a/contrib/binutils/binutils/ChangeLog-9899
+++ b/contrib/binutils/binutils/ChangeLog-9899
@@ -552,7 +552,7 @@ Mon Jun 7 12:14:57 1999 Andreas Schwab <schwab@issan.cs.uni-dortmund.de>
1999-06-04 Nick Clifton <nickc@cygnus.com>
- * readelf.c: Use 64bit wide fields in internal strcutures even if
+ * readelf.c: Use 64bit wide fields in internal structures even if
targetting a 32bit architecture.
(dump_relocations): Take a new parameter - the number of symbols
in the symbol table.
diff --git a/contrib/binutils/binutils/MAINTAINERS b/contrib/binutils/binutils/MAINTAINERS
index 4ca6ae8..28c9144 100644
--- a/contrib/binutils/binutils/MAINTAINERS
+++ b/contrib/binutils/binutils/MAINTAINERS
@@ -14,14 +14,18 @@ The home page for binutils is:
and patches should be sent to:
- bug-binutils@gnu.org
+ bug-binutils@gnu.org or binutils@sources.redhat.com
with "[Patch]" as part of the subject line. Note - patches to the
-top level configure.in and config.sub scripts should be sent to:
+top level config.guess and config.sub scripts should be sent to:
config-patches@gnu.org
-and not to the binutils list.
+and not to the binutils lists. Patches to the other top level
+configure files (configure, configure.in, config-if, config-ml.in)
+should be sent to the binutils lists, and copied to the gcc and gdb
+lists as well (gcc-patches@gcc.gnu.org and
+gdb-patches@sources.redhat.com).
--------- Blanket Write Privs ---------
@@ -30,12 +34,12 @@ repository without obtaining approval first:
Nick Clifton <nickc@redhat.com> (head maintainer)
Richard Henderson <rth@redhat.com>
- Ian Taylor <ian@zembu.com>
+ Ian Taylor <ian@wasabisystems.com>
Jeff Law <law@redhat.com>
- Jim Wilson <wilson@redhat.com>
+ Jim Wilson <wilson@specifixinc.com>
DJ Delorie <dj@redhat.com>
Alan Modra <amodra@bigpond.net.au>
- Michael Meissner <meissner@redhat.com>
+ Michael Meissner <gnu@the-meissners.org>
--------- Maintainers ---------
@@ -50,39 +54,49 @@ maintainers for a given domain then responsibility falls to the first
maintainer. The first maintainer is free to devolve that
responsibility among the other maintainers.
- ARC Peter Targett <peter.targett@arc.com>
+ ALPHA Richard Henderson <rth@redhat.com>
ARM Nick Clifton <nickc@redhat.com>
ARM Richard Earnshaw <rearnsha@arm.com>
AVR Denis Chertykov <denisc@overta.ru>
AVR Marek Michalkiewicz <marekm@amelek.gda.pl>
+ BUILD SYSTEM Ben Elliston <bje@gnu.org>
+ BUILD SYSTEM Daniel Jacobowitz <dan@debian.org>
CRIS Hans-Peter Nilsson <hp@axis.com>
DWARF2 Jason Merrill <jason@redhat.com>
FR30 Dave Brolley <brolley@redhat.com>
FRV Dave Brolley <brolley@redhat.com>
+ HPPA Dave Anglin <dave.anglin@nrc.ca>
HPPA elf32 Alan Modra <amodra@bigpond.net.au>
- IA64 Jim Wilson <wilson@redhat.com>
- i860 Jason Eckhardt <jle@redhat.com>
+ HPPA elf64 Jeff Law <law@redhat.com> [Basic maintainance only]
+ IA-64 Jim Wilson <wilson@specifixinc.com>
+ IQ2000 Stan Cox <scox@redhat.com>
+ i860 Jason Eckhardt <jle@rice.edu>
ix86 Alan Modra <amodra@bigpond.net.au>
- ix86 COFF,PE DJ Delorie <dj@redhat.com>
+ ix86 PE Christopher Faylor <cgf@redhat.com>
+ ix86 COFF DJ Delorie <dj@redhat.com>
ix86 H.J.Lu <hjl@gnu.org>
ix86 INTEL MODE Diego Novillo <dnovillo@redhat.com>
M68HC11 M68HC12 Stephane Carrez <stcarrez@nerim.fr>
- M68k Ben Elliston <bje@redhat.com>
- M88k Ben Elliston <bje@redhat.com>
+ M68k Ben Elliston <bje@gnu.org>
MIPS Eric Christopher <echristo@redhat.com>
+ MIPS Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
MMIX Hans-Peter Nilsson <hp@bitrange.com>
MN10300 Eric Christopher <echristo@redhat.com>
MN10300 Alexandre Oliva <aoliva@redhat.com>
- PPC Geoff Keating <geoffk@redhat.com>
+ PPC Geoff Keating <geoffk@geoffk.org>
+ PPC vector ext Aldy Hernandez <aldyh@redhat.com>
s390, s390x Martin Schwidefsky <schwidefsky@de.ibm.com>
SH Jörn Rennecke <joern.rennecke@superh.com>
- SH Hans-Peter Nilsson <hp@bitrange.com>
SH Alexandre Oliva <aoliva@redhat.com>
+ SH Kaz Kojima <kkojima@rr.iij4u.or.jp>
SPARC Jakub Jelinek <jakub@redhat.com>
+ TESTSUITES Ben Elliston <bje@gnu.org>
+ TIC4X Svein Seldal <svein.seldal@solidas.com>
TIC54X Timothy Wall <twall@alum.mit.edu>
VAX Jason R Thorpe <thorpej@wasabisystems.com>
x86_64 Jan Hubicka <jh@suse.cz>
x86_64 Andreas Jaeger <aj@suse.de>
+ Xtensa Bob Wilson <bob.wilson@acm.org>
z8k Christian Groessler <chris@groessler.org>
@@ -134,3 +148,21 @@ great). If you are uncertain as to whether a patch is appropriate for
the branch, ask the branch maintainer. This is:
Daniel Jacobowitz <dan@debian.org>
+
+ -------- Testsuites ---------------
+
+In general patches to any of the binutils testsuites should be
+considered generic and sent to the binutils mailing list for
+approval. Patches to target specific tests are the responsibility the
+relevent port maintainer(s), and can be approved/checked in by them.
+Other testsuite patches need the approval of a blanket-write-priveleges
+person.
+
+ -------- Configure patches ----------
+
+Patches to the top level configure files (config.sub & config.guess)
+are not the domain of the binutils project and they cannot be approved
+by the binutils group. Instead they should be submitted to the config
+maintainer at:
+
+ config-patches@gnu.org
diff --git a/contrib/binutils/binutils/Makefile.am b/contrib/binutils/binutils/Makefile.am
index 1fd97ab..324c0ea 100644
--- a/contrib/binutils/binutils/Makefile.am
+++ b/contrib/binutils/binutils/Makefile.am
@@ -87,7 +87,7 @@ GENERATED_HFILES = arparse.h sysroff.h sysinfo.h defparse.h rcparse.h
CFILES = \
addr2line.c ar.c arsup.c binemul.c bucomm.c budemang.c \
- coffdump.c coffgrok.c debug.c dlltool.c dllwrap.c \
+ coffdump.c coffgrok.c cxxfilt.c debug.c dlltool.c dllwrap.c \
emul_aix.c emul_vanilla.c filemode.c \
ieee.c is-ranlib.c is-strip.c maybe-ranlib.c maybe-strip.c \
nlmconv.c nm.c not-ranlib.c not-strip.c \
@@ -98,7 +98,7 @@ CFILES = \
windres.c winduni.c wrstabs.c
GENERATED_CFILES = \
- underscore.c arparse.c arlex.c sysroff.c sysinfo.c syslex.c \
+ arparse.c arlex.c sysroff.c sysinfo.c syslex.c \
defparse.c deflex.c nlmheader.c rcparse.c rclex.c
DEBUG_SRCS = rddbg.c debug.c stabs.c ieee.c rdcoff.c
@@ -115,7 +115,7 @@ LIBIBERTY = ../libiberty/libiberty.a
POTFILES = $(CFILES) $(DEBUG_SRCS) $(HFILES)
po/POTFILES.in: @MAINT@ Makefile
- for file in $(POTFILES); do echo $$file; done | sort > tmp \
+ for f in $(POTFILES); do echo $$f; done | LC_COLLATE= sort > tmp \
&& mv tmp $(srcdir)/po/POTFILES.in
EXPECT = `if [ -f $$r/../expect/expect ] ; then \
@@ -180,19 +180,7 @@ objdump_LDADD = $(OPCODES) $(BFDLIB) $(LIBIBERTY) $(INTLLIBS)
objdump.o:objdump.c
$(COMPILE) -c $(OBJDUMP_DEFS) $(srcdir)/objdump.c
-underscore.c: stamp-under ; @true
-
-stamp-under: Makefile
- echo '/*WARNING: This file is automatically generated!*/' >underscore.t
- echo "int prepends_underscore = @UNDERSCORE@;" >>underscore.t
- $(SHELL) $(srcdir)/../move-if-change underscore.t underscore.c
- touch stamp-under
-
-cplus-dem.o: $(BASEDIR)/libiberty/cplus-dem.c $(INCDIR)/getopt.h Makefile
- $(COMPILE) -c -DMAIN -DVERSION='"$(VERSION)"' $(BASEDIR)/libiberty/cplus-dem.c
-
-cxxfilt_SOURCES =
-cxxfilt_LDADD = cplus-dem.o underscore.o $(LIBIBERTY) $(INTLLIBS)
+cxxfilt_SOURCES = cxxfilt.c $(BULIBS)
ar_SOURCES = arparse.y arlex.l ar.c not-ranlib.c arsup.c rename.c binemul.c \
emul_$(EMULATION).c $(BULIBS)
@@ -290,7 +278,7 @@ EXTRA_DIST = arparse.c arparse.h arlex.c nlmheader.c sysinfo.c sysinfo.h \
diststuff: $(EXTRA_DIST) info
-DISTCLEANFILES = stamp-under sysinfo underscore.c sysroff.c sysroff.h \
+DISTCLEANFILES = sysinfo sysroff.c sysroff.h \
site.exp site.bak
Makefile: $(BFDDIR)/configure.in
@@ -362,7 +350,7 @@ install-exec-local: install-binPROGRAMS $(bin_PROGRAMS) $(noinst_PROGRAMS)
if [ -f $$i$(EXEEXT) ]; then \
j=`echo $$i | sed -e 's/-new//'`; \
k=`echo $$j | sed '$(transform)'`; \
- if [ "$(DESTDIR)$(bindir)/$$k$(EXEEXT)" != "$(DESTDIR)$(tooldir)/bin/$$j$(EXEEXT)" ]; then \
+ if [ "$(bindir)/$$k" != "$(tooldir)/bin/$$j" ]; then \
rm -f $(DESTDIR)$(tooldir)/bin/$$j$(EXEEXT); \
ln $(DESTDIR)$(bindir)/$$k$(EXEEXT) $(DESTDIR)$(tooldir)/bin/$$j$(EXEEXT) >/dev/null 2>/dev/null \
|| $(LIBTOOL) --mode=install $(INSTALL_PROGRAM) $$i$(EXEEXT) $(DESTDIR)$(tooldir)/bin/$$j$(EXEEXT); \
@@ -392,9 +380,10 @@ binemul.o: binemul.c binemul.h ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h bucomm.h config.h $(INCDIR)/bin-bugs.h \
$(INCDIR)/fopen-same.h
bucomm.o: bucomm.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/symcat.h $(INCDIR)/libiberty.h bucomm.h config.h \
- $(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h $(INCDIR)/filenames.h
-budemang.o: budemang.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/symcat.h ../bfd/bfdver.h $(INCDIR)/libiberty.h \
+ bucomm.h config.h $(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h \
+ $(INCDIR)/filenames.h $(BFDDIR)/libbfd.h
+budemang.o: budemang.c config.h ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h $(INCDIR)/libiberty.h $(INCDIR)/demangle.h \
budemang.h
coffdump.o: coffdump.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
@@ -404,6 +393,9 @@ coffgrok.o: coffgrok.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h $(INCDIR)/libiberty.h bucomm.h config.h \
$(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h coffgrok.h
+cxxfilt.o: cxxfilt.c config.h ../bfd/bfd.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/symcat.h bucomm.h $(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h \
+ $(INCDIR)/libiberty.h $(INCDIR)/demangle.h $(INCDIR)/safe-ctype.h
debug.o: debug.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h bucomm.h config.h $(INCDIR)/bin-bugs.h \
$(INCDIR)/fopen-same.h $(INCDIR)/libiberty.h debug.h
@@ -448,12 +440,13 @@ not-strip.o: not-strip.c
objcopy.o: objcopy.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h $(INCDIR)/progress.h bucomm.h config.h \
$(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h $(INCDIR)/libiberty.h \
- budbg.h $(INCDIR)/filenames.h
+ budbg.h $(INCDIR)/filenames.h $(INCDIR)/fnmatch.h
objdump.o: objdump.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/symcat.h $(INCDIR)/progress.h bucomm.h config.h \
- $(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h budemang.h \
- $(INCDIR)/safe-ctype.h $(INCDIR)/dis-asm.h $(INCDIR)/libiberty.h \
- $(INCDIR)/demangle.h debug.h budbg.h $(INCDIR)/aout/aout64.h
+ $(INCDIR)/symcat.h ../bfd/bfdver.h $(INCDIR)/progress.h \
+ bucomm.h config.h $(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h \
+ budemang.h $(INCDIR)/safe-ctype.h $(INCDIR)/dis-asm.h \
+ $(INCDIR)/libiberty.h $(INCDIR)/demangle.h debug.h \
+ budbg.h $(INCDIR)/aout/aout64.h
prdbg.o: prdbg.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h bucomm.h config.h $(INCDIR)/bin-bugs.h \
$(INCDIR)/fopen-same.h $(INCDIR)/libiberty.h debug.h \
@@ -474,15 +467,18 @@ readelf.o: readelf.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/elf/avr.h $(INCDIR)/elf/cris.h $(INCDIR)/elf/d10v.h \
$(INCDIR)/elf/d30v.h $(INCDIR)/elf/dlx.h $(INCDIR)/elf/fr30.h \
$(INCDIR)/elf/frv.h $(INCDIR)/elf/h8.h $(INCDIR)/elf/hppa.h \
- $(INCDIR)/elf/i386.h $(INCDIR)/elf/i860.h $(INCDIR)/elf/i960.h \
- $(INCDIR)/elf/ia64.h $(INCDIR)/elf/m32r.h $(INCDIR)/elf/m68k.h \
- $(INCDIR)/elf/m68hc11.h $(INCDIR)/elf/mcore.h $(INCDIR)/elf/mips.h \
- $(INCDIR)/elf/mmix.h $(INCDIR)/elf/mn10200.h $(INCDIR)/elf/mn10300.h \
+ $(INCDIR)/elf/i386.h $(INCDIR)/elf/i370.h $(INCDIR)/elf/i860.h \
+ $(INCDIR)/elf/i960.h $(INCDIR)/elf/ia64.h $(INCDIR)/elf/ip2k.h \
+ $(INCDIR)/elf/m32r.h $(INCDIR)/elf/m68k.h $(INCDIR)/elf/m68hc11.h \
+ $(INCDIR)/elf/mcore.h $(INCDIR)/elf/mips.h $(INCDIR)/elf/mmix.h \
+ $(INCDIR)/elf/mn10200.h $(INCDIR)/elf/mn10300.h $(INCDIR)/elf/msp430.h \
$(INCDIR)/elf/or32.h $(INCDIR)/elf/pj.h $(INCDIR)/elf/ppc.h \
- $(INCDIR)/elf/s390.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/sparc.h \
- $(INCDIR)/elf/v850.h $(INCDIR)/elf/vax.h $(INCDIR)/elf/x86-64.h \
- $(INCDIR)/elf/xstormy16.h bucomm.h config.h $(INCDIR)/bin-bugs.h \
- $(INCDIR)/fopen-same.h unwind-ia64.h
+ $(INCDIR)/elf/ppc64.h $(INCDIR)/elf/s390.h $(INCDIR)/elf/sh.h \
+ $(INCDIR)/elf/sparc.h $(INCDIR)/elf/v850.h $(INCDIR)/elf/vax.h \
+ $(INCDIR)/elf/x86-64.h $(INCDIR)/elf/xstormy16.h $(INCDIR)/elf/iq2000.h \
+ $(INCDIR)/elf/xtensa.h $(INCDIR)/aout/ar.h bucomm.h \
+ config.h $(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h \
+ $(INCDIR)/libiberty.h unwind-ia64.h
rename.o: rename.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h bucomm.h config.h $(INCDIR)/bin-bugs.h \
$(INCDIR)/fopen-same.h
@@ -525,8 +521,8 @@ sysdump.o: sysdump.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/fopen-same.h $(INCDIR)/safe-ctype.h $(INCDIR)/libiberty.h \
sysroff.h sysroff.c
version.o: version.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/symcat.h bucomm.h config.h $(INCDIR)/bin-bugs.h \
- $(INCDIR)/fopen-same.h
+ $(INCDIR)/symcat.h ../bfd/bfdver.h bucomm.h config.h \
+ $(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h
windres.o: windres.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h $(INCDIR)/getopt.h bucomm.h config.h \
$(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h $(INCDIR)/libiberty.h \
@@ -540,7 +536,6 @@ wrstabs.o: wrstabs.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/fopen-same.h $(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h \
debug.h budbg.h $(INCDIR)/aout/aout64.h $(INCDIR)/aout/stab_gnu.h \
$(INCDIR)/aout/stab.def
-underscore.o: underscore.c
arparse.o: arparse.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h bucomm.h config.h $(INCDIR)/bin-bugs.h \
$(INCDIR)/fopen-same.h arsup.h
diff --git a/contrib/binutils/binutils/Makefile.in b/contrib/binutils/binutils/Makefile.in
index 9208082..46eeac8 100644
--- a/contrib/binutils/binutils/Makefile.in
+++ b/contrib/binutils/binutils/Makefile.in
@@ -1,4 +1,4 @@
-# Makefile.in generated automatically by automake 1.4-p5 from Makefile.am
+# Makefile.in generated automatically by automake 1.4-p6 from Makefile.am
# Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
@@ -109,7 +109,6 @@ POFILES = @POFILES@
POSUB = @POSUB@
RANLIB = @RANLIB@
STRIP = @STRIP@
-UNDERSCORE = @UNDERSCORE@
USE_INCLUDED_LIBINTL = @USE_INCLUDED_LIBINTL@
USE_NLS = @USE_NLS@
VERSION = @VERSION@
@@ -200,7 +199,7 @@ GENERATED_HFILES = arparse.h sysroff.h sysinfo.h defparse.h rcparse.h
CFILES = \
addr2line.c ar.c arsup.c binemul.c bucomm.c budemang.c \
- coffdump.c coffgrok.c debug.c dlltool.c dllwrap.c \
+ coffdump.c coffgrok.c cxxfilt.c debug.c dlltool.c dllwrap.c \
emul_aix.c emul_vanilla.c filemode.c \
ieee.c is-ranlib.c is-strip.c maybe-ranlib.c maybe-strip.c \
nlmconv.c nm.c not-ranlib.c not-strip.c \
@@ -212,7 +211,7 @@ CFILES = \
GENERATED_CFILES = \
- underscore.c arparse.c arlex.c sysroff.c sysinfo.c syslex.c \
+ arparse.c arlex.c sysroff.c sysinfo.c syslex.c \
defparse.c deflex.c nlmheader.c rcparse.c rclex.c
@@ -273,8 +272,7 @@ nm_new_SOURCES = nm.c budemang.c $(BULIBS)
objdump_SOURCES = objdump.c budemang.c prdbg.c $(DEBUG_SRCS) $(BULIBS)
objdump_LDADD = $(OPCODES) $(BFDLIB) $(LIBIBERTY) $(INTLLIBS)
-cxxfilt_SOURCES =
-cxxfilt_LDADD = cplus-dem.o underscore.o $(LIBIBERTY) $(INTLLIBS)
+cxxfilt_SOURCES = cxxfilt.c $(BULIBS)
ar_SOURCES = arparse.y arlex.l ar.c not-ranlib.c arsup.c rename.c binemul.c \
emul_$(EMULATION).c $(BULIBS)
@@ -311,7 +309,7 @@ EXTRA_DIST = arparse.c arparse.h arlex.c nlmheader.c sysinfo.c sysinfo.h \
syslex.c deflex.c defparse.h defparse.c rclex.c rcparse.h rcparse.c
-DISTCLEANFILES = stamp-under sysinfo underscore.c sysroff.c sysroff.h \
+DISTCLEANFILES = sysinfo sysroff.c sysroff.h \
site.exp site.bak
@@ -424,9 +422,10 @@ version.$(OBJEXT) filemode.$(OBJEXT)
strip_new_LDADD = $(LDADD)
strip_new_DEPENDENCIES = ../bfd/libbfd.la ../libiberty/libiberty.a
strip_new_LDFLAGS =
-cxxfilt_OBJECTS =
-cxxfilt_DEPENDENCIES = cplus-dem.o underscore.o \
-../libiberty/libiberty.a
+cxxfilt_OBJECTS = cxxfilt.$(OBJEXT) bucomm.$(OBJEXT) version.$(OBJEXT) \
+filemode.$(OBJEXT)
+cxxfilt_LDADD = $(LDADD)
+cxxfilt_DEPENDENCIES = ../bfd/libbfd.la ../libiberty/libiberty.a
cxxfilt_LDFLAGS =
LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
LEXLIB = @LEXLIB@
@@ -871,7 +870,7 @@ distclean-generic:
-test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES)
maintainer-clean-generic:
- -test -z "arlexldeflexlrclexlarparseharparsecdefparsehdefparsecnlmheaderhnlmheadercrcparsehrcparsec" || rm -f arlexl deflexl rclexl arparseh arparsec defparseh defparsec nlmheaderh nlmheaderc rcparseh rcparsec
+ -test -z "arlex.cdeflex.crclex.carparse.harparse.cdefparse.hdefparse.cnlmheader.hnlmheader.crcparse.hrcparse.c" || rm -f arlex.c deflex.c rclex.c arparse.h arparse.c defparse.h defparse.c nlmheader.h nlmheader.c rcparse.h rcparse.c
mostlyclean-am: mostlyclean-hdr mostlyclean-binPROGRAMS \
mostlyclean-noinstPROGRAMS mostlyclean-compile \
mostlyclean-libtool mostlyclean-tags \
@@ -927,7 +926,7 @@ installdirs mostlyclean-generic distclean-generic clean-generic \
maintainer-clean-generic clean mostlyclean distclean maintainer-clean
po/POTFILES.in: @MAINT@ Makefile
- for file in $(POTFILES); do echo $$file; done | sort > tmp \
+ for f in $(POTFILES); do echo $$f; done | LC_COLLATE= sort > tmp \
&& mv tmp $(srcdir)/po/POTFILES.in
check-DEJAGNU: site.exp
@@ -952,17 +951,6 @@ installcheck:
objdump.o:objdump.c
$(COMPILE) -c $(OBJDUMP_DEFS) $(srcdir)/objdump.c
-underscore.c: stamp-under ; @true
-
-stamp-under: Makefile
- echo '/*WARNING: This file is automatically generated!*/' >underscore.t
- echo "int prepends_underscore = @UNDERSCORE@;" >>underscore.t
- $(SHELL) $(srcdir)/../move-if-change underscore.t underscore.c
- touch stamp-under
-
-cplus-dem.o: $(BASEDIR)/libiberty/cplus-dem.c $(INCDIR)/getopt.h Makefile
- $(COMPILE) -c -DMAIN -DVERSION='"$(VERSION)"' $(BASEDIR)/libiberty/cplus-dem.c
-
# The following is commented out for the conversion to automake.
# This rule creates a single binary that switches between ar and ranlib
# by looking at argv[0]. Use this kludge to save some disk space.
@@ -1090,7 +1078,7 @@ install-exec-local: install-binPROGRAMS $(bin_PROGRAMS) $(noinst_PROGRAMS)
if [ -f $$i$(EXEEXT) ]; then \
j=`echo $$i | sed -e 's/-new//'`; \
k=`echo $$j | sed '$(transform)'`; \
- if [ "$(DESTDIR)$(bindir)/$$k$(EXEEXT)" != "$(DESTDIR)$(tooldir)/bin/$$j$(EXEEXT)" ]; then \
+ if [ "$(bindir)/$$k" != "$(tooldir)/bin/$$j" ]; then \
rm -f $(DESTDIR)$(tooldir)/bin/$$j$(EXEEXT); \
ln $(DESTDIR)$(bindir)/$$k$(EXEEXT) $(DESTDIR)$(tooldir)/bin/$$j$(EXEEXT) >/dev/null 2>/dev/null \
|| $(LIBTOOL) --mode=install $(INSTALL_PROGRAM) $$i$(EXEEXT) $(DESTDIR)$(tooldir)/bin/$$j$(EXEEXT); \
@@ -1120,9 +1108,10 @@ binemul.o: binemul.c binemul.h ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h bucomm.h config.h $(INCDIR)/bin-bugs.h \
$(INCDIR)/fopen-same.h
bucomm.o: bucomm.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/symcat.h $(INCDIR)/libiberty.h bucomm.h config.h \
- $(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h $(INCDIR)/filenames.h
-budemang.o: budemang.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/symcat.h ../bfd/bfdver.h $(INCDIR)/libiberty.h \
+ bucomm.h config.h $(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h \
+ $(INCDIR)/filenames.h $(BFDDIR)/libbfd.h
+budemang.o: budemang.c config.h ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h $(INCDIR)/libiberty.h $(INCDIR)/demangle.h \
budemang.h
coffdump.o: coffdump.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
@@ -1132,6 +1121,9 @@ coffgrok.o: coffgrok.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h $(INCDIR)/libiberty.h bucomm.h config.h \
$(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h coffgrok.h
+cxxfilt.o: cxxfilt.c config.h ../bfd/bfd.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/symcat.h bucomm.h $(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h \
+ $(INCDIR)/libiberty.h $(INCDIR)/demangle.h $(INCDIR)/safe-ctype.h
debug.o: debug.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h bucomm.h config.h $(INCDIR)/bin-bugs.h \
$(INCDIR)/fopen-same.h $(INCDIR)/libiberty.h debug.h
@@ -1176,12 +1168,13 @@ not-strip.o: not-strip.c
objcopy.o: objcopy.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h $(INCDIR)/progress.h bucomm.h config.h \
$(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h $(INCDIR)/libiberty.h \
- budbg.h $(INCDIR)/filenames.h
+ budbg.h $(INCDIR)/filenames.h $(INCDIR)/fnmatch.h
objdump.o: objdump.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/symcat.h $(INCDIR)/progress.h bucomm.h config.h \
- $(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h budemang.h \
- $(INCDIR)/safe-ctype.h $(INCDIR)/dis-asm.h $(INCDIR)/libiberty.h \
- $(INCDIR)/demangle.h debug.h budbg.h $(INCDIR)/aout/aout64.h
+ $(INCDIR)/symcat.h ../bfd/bfdver.h $(INCDIR)/progress.h \
+ bucomm.h config.h $(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h \
+ budemang.h $(INCDIR)/safe-ctype.h $(INCDIR)/dis-asm.h \
+ $(INCDIR)/libiberty.h $(INCDIR)/demangle.h debug.h \
+ budbg.h $(INCDIR)/aout/aout64.h
prdbg.o: prdbg.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h bucomm.h config.h $(INCDIR)/bin-bugs.h \
$(INCDIR)/fopen-same.h $(INCDIR)/libiberty.h debug.h \
@@ -1202,15 +1195,18 @@ readelf.o: readelf.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/elf/avr.h $(INCDIR)/elf/cris.h $(INCDIR)/elf/d10v.h \
$(INCDIR)/elf/d30v.h $(INCDIR)/elf/dlx.h $(INCDIR)/elf/fr30.h \
$(INCDIR)/elf/frv.h $(INCDIR)/elf/h8.h $(INCDIR)/elf/hppa.h \
- $(INCDIR)/elf/i386.h $(INCDIR)/elf/i860.h $(INCDIR)/elf/i960.h \
- $(INCDIR)/elf/ia64.h $(INCDIR)/elf/m32r.h $(INCDIR)/elf/m68k.h \
- $(INCDIR)/elf/m68hc11.h $(INCDIR)/elf/mcore.h $(INCDIR)/elf/mips.h \
- $(INCDIR)/elf/mmix.h $(INCDIR)/elf/mn10200.h $(INCDIR)/elf/mn10300.h \
+ $(INCDIR)/elf/i386.h $(INCDIR)/elf/i370.h $(INCDIR)/elf/i860.h \
+ $(INCDIR)/elf/i960.h $(INCDIR)/elf/ia64.h $(INCDIR)/elf/ip2k.h \
+ $(INCDIR)/elf/m32r.h $(INCDIR)/elf/m68k.h $(INCDIR)/elf/m68hc11.h \
+ $(INCDIR)/elf/mcore.h $(INCDIR)/elf/mips.h $(INCDIR)/elf/mmix.h \
+ $(INCDIR)/elf/mn10200.h $(INCDIR)/elf/mn10300.h $(INCDIR)/elf/msp430.h \
$(INCDIR)/elf/or32.h $(INCDIR)/elf/pj.h $(INCDIR)/elf/ppc.h \
- $(INCDIR)/elf/s390.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/sparc.h \
- $(INCDIR)/elf/v850.h $(INCDIR)/elf/vax.h $(INCDIR)/elf/x86-64.h \
- $(INCDIR)/elf/xstormy16.h bucomm.h config.h $(INCDIR)/bin-bugs.h \
- $(INCDIR)/fopen-same.h unwind-ia64.h
+ $(INCDIR)/elf/ppc64.h $(INCDIR)/elf/s390.h $(INCDIR)/elf/sh.h \
+ $(INCDIR)/elf/sparc.h $(INCDIR)/elf/v850.h $(INCDIR)/elf/vax.h \
+ $(INCDIR)/elf/x86-64.h $(INCDIR)/elf/xstormy16.h $(INCDIR)/elf/iq2000.h \
+ $(INCDIR)/elf/xtensa.h $(INCDIR)/aout/ar.h bucomm.h \
+ config.h $(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h \
+ $(INCDIR)/libiberty.h unwind-ia64.h
rename.o: rename.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h bucomm.h config.h $(INCDIR)/bin-bugs.h \
$(INCDIR)/fopen-same.h
@@ -1253,8 +1249,8 @@ sysdump.o: sysdump.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/fopen-same.h $(INCDIR)/safe-ctype.h $(INCDIR)/libiberty.h \
sysroff.h sysroff.c
version.o: version.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/symcat.h bucomm.h config.h $(INCDIR)/bin-bugs.h \
- $(INCDIR)/fopen-same.h
+ $(INCDIR)/symcat.h ../bfd/bfdver.h bucomm.h config.h \
+ $(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h
windres.o: windres.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h $(INCDIR)/getopt.h bucomm.h config.h \
$(INCDIR)/bin-bugs.h $(INCDIR)/fopen-same.h $(INCDIR)/libiberty.h \
@@ -1268,7 +1264,6 @@ wrstabs.o: wrstabs.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/fopen-same.h $(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h \
debug.h budbg.h $(INCDIR)/aout/aout64.h $(INCDIR)/aout/stab_gnu.h \
$(INCDIR)/aout/stab.def
-underscore.o: underscore.c
arparse.o: arparse.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h bucomm.h config.h $(INCDIR)/bin-bugs.h \
$(INCDIR)/fopen-same.h arsup.h
diff --git a/contrib/binutils/binutils/NEWS b/contrib/binutils/binutils/NEWS
index 5091e3b..a72826e 100644
--- a/contrib/binutils/binutils/NEWS
+++ b/contrib/binutils/binutils/NEWS
@@ -1,4 +1,47 @@
-*- text -*-
+
+* objcopy and strip can now take wildcard patterns in symbol names specified on
+ the command line provided that the --wildcard switch is used to enable them.
+
+* readelf can now parse archives.
+
+* objdump now accepts --debugging-tags to print the debug information in a
+ format compatible with ctags tool.
+
+* objcopy and strip now accept --only-keep-debug to create a file containing
+ those sections that would be stripped out by --strip-debug. The idea is that
+ this can be used in conjunction with the --add-gnu-debuglink switch to create
+ a two part program distribution - one a stripped executable and the other the
+ debugging info.
+
+* objcopy now accepts --add-gnu-debuglink=<file> to insert a .gnu_debuglink
+ section into a (presumably stripped) executable. This allows the debug
+ information for the file to be held in a separate file.
+
+* BFD marks the sections .comment and .note as 'n' in the BSD/POSIX
+ single-character representation. This can be checked by running nm
+ with the -a switch.
+
+Changes in 2.14:
+
+* Added --info switch to objcopy and strip.
+
+* Support for Vitesse IQ2000 added by Red Hat.
+
+* Added 'S' encoding to strings to allow the display of 8-bit characters.
+
+* Added --prefix-symbols=<text>, --prefix-sections=<text> and
+ --prefix-alloc-sections=<text> to objcopy.
+
+* readelf can handle the extensions to the DWARF2 spec used by the Unified
+ Parallel C compiler.
+
+* BFD no longer declares a "boolean" type, to avoid clashes with other
+ headers that declare the same. Users of BFD should replace boolean,
+ false and true, with int, 0 and 1, or define their own boolean type.
+
+* Support for IP2K added by Denis Chertykov.
+
Changes in 2.13:
* Support for the Fujitsu FRV architecture added by Red Hat. Models for FR400
@@ -44,7 +87,7 @@ Changes in binutils 2.11:
* Add --srec-len and --srec-forceS3 command line switch to objcopy.
By Luciano Gemme.
-
+
* Support for the MIPS32, by Anders Norlander.
* Support for the i860, by Jason Eckhardt.
@@ -57,13 +100,13 @@ Changes in binutils 2.10:
* New command line switch to objdump --file-start-context which shows the
entire file contents up to the source line first encountered for a given
- file.
+ file.
* New command line switch to objdump -M (or --disassembler-options) which takes
a parameter which can then be interpreted on a per-target basis by the
disassembler. Used by ARM targets to select register name sets, ISA, APCS or
raw verions.
-
+
* objdump support for -mi386:intel which causes disassembly to be displayed
with intel syntax.
@@ -154,7 +197,7 @@ Changes in binutils 2.6:
Changes in binutils 2.5:
* Changed objdump -dr to dump the relocs interspersed with the assembly
- listing, for a more useful listing of relocateable files.
+ listing, for a more useful listing of relocatable files.
* Changed objdump -d/--disassemble to only disassemble SEC_CODE sections.
Added -D/--disassemble-all option to disassemble all sections.
diff --git a/contrib/binutils/binutils/README b/contrib/binutils/binutils/README
index 6633792..5bc2508 100644
--- a/contrib/binutils/binutils/README
+++ b/contrib/binutils/binutils/README
@@ -18,7 +18,7 @@ Unpacking and Installation -- quick overview
When you unpack the binutils archive file, you will get a directory
called something like `binutils-XXX', where XXX is the number of the
-release. (Probably 2.12 or higher). This directory contains
+release. (Probably 2.13 or higher). This directory contains
various files and sub-directories. Most of the files in the top
directory are for information and for configuration. The actual
source code is in sub-directories.
@@ -83,6 +83,18 @@ To build under openVMS/AXP, see the file makefile.vms in the top level
directory.
+Native Language Support
+=======================
+
+By default Native Language Support will be enabled for binutils. On
+some systems however this support is not present and can lead to error
+messages such as "undefined reference to `libintl_gettext'" when
+building there tools. If that happens the NLS support can be disabled
+by adding the --disable-nls switch to the configure line like this:
+
+ ../binutils-XXX/configure --disable-nls
+
+
If you don't have ar
====================
@@ -100,7 +112,7 @@ ${MAKE} $* all-bfd
cd binutils
MAKE="${MAKE_PROG}"
export MAKE
-${MAKE} $* ar_DEPENDENCIES= ar_LDADD='../bfd/*.o `cat ../libiberty/required-list ../libiberty/needed-list | sed -e "s,\([^ ][^ ]*\),../libiberty/\1,g"` `if test -f ../intl/gettext.o; then echo '../intl/*.o'; fi`' ar
+${MAKE} $* ar_DEPENDENCIES= ar_LDADD='../bfd/*.o ../libiberty/*.o `if test -f ../intl/gettext.o; then echo '../intl/*.o'; fi`' ar
This script will build an ar program in binutils/ar. Move binutils/ar
into a directory on your PATH. After doing this, you can run make as
@@ -110,7 +122,7 @@ the ranlib program in order to build the distribution.
Porting
=======
-Binutils-2.12 supports many different architectures, but there
+Binutils-2.13 supports many different architectures, but there
are many more not supported, including some that were supported
by earlier versions. We are hoping for volunteers to improve this
situation.
@@ -127,9 +139,66 @@ Send bug reports and patches to:
bug-binutils@gnu.org.
+Please include the following in bug reports:
+
+- A description of exactly what went wrong, and exactly what should have
+ happened instead.
+
+- The configuration name(s) given to the "configure" script. The
+ "config.status" file should have this information. This is assuming
+ you built binutils yourself. If you didn't build binutils youself,
+ then we need information regarding your machine and operating system,
+ and it may be more appropriate to report bugs to wherever you obtained
+ binutils.
+
+- The options given to the tool (gas, objcopy, ld etc.) at run time.
+
+- The actual input file that caused the problem.
+
Always mention the version number you are running; this is printed by
running any of the binutils with the --version option. We appreciate
-reports about bugs, but we do not promise to fix them.
+reports about bugs, but we do not promise to fix them, particularly so
+when the bug report is against an old version. If you are able, please
+consider building the latest tools from CVS to check that your bug has
+not already been fixed.
+
+When reporting problems about gas and ld, it's useful to provide a
+testcase that triggers the problem. In the case of a gas problem, we
+want input files to gas and command line switches used. The inputs to
+gas are _NOT_ .c or .i files, but rather .s files. If your original
+source was a C program, you can generate the .s file and see the command
+line options by passing -v -save-temps to gcc in addition to all the
+usual options you use. The reason we don't want C files is that we
+might not have a C compiler around for the target you use. While it
+might be possible to build a compiler, that takes considerable time and
+disk space, and we might not end up with exactly the same compiler you
+use.
+
+In the case of a ld problem, the input files are .o, .a and .so files,
+and possibly a linker script specified with -T. Again, when using gcc
+to link, you can see these files by adding options to the gcc command
+line. Use -v -save-temps -Wl,-t, except that on targets that use gcc's
+collect2, you would add -v -save-temps -Wl,-t,-debug. The -t option
+tells ld to print all files and libraries used, so that, for example,
+you can associate -lc on the ld command line with the actual libc used.
+Note that your simple two line C program to trigger a problem typically
+expands into several megabytes of objects by the time you include
+libraries.
+
+It is antisocial to post megabyte sized attachments to mailing lists, so
+please put large testcases somewhere on an ftp or web site so that only
+interested developers need to download them, or offer to email them on
+request. Better still, try to reduce the testcase, for example, try to
+develop a ld testcase that doesn't use system libraries. However,
+please be sure it is a complete testcase and that it really does
+demonstrate the problem. Also, don't bother paring it down if that will
+cause large delays in filing the bug report.
+
+If you expect to be contributing a large number of test cases, it would
+be helpful if you would look at the test suite included in the release
+(based on the Deja Gnu testing framework, available from the usual ftp
+sites) and write test cases to fit into that framework. This is
+certainly not required.
VMS
===
diff --git a/contrib/binutils/binutils/acinclude.m4 b/contrib/binutils/binutils/acinclude.m4
index 7ffc031..c5ae4d4 100644
--- a/contrib/binutils/binutils/acinclude.m4
+++ b/contrib/binutils/binutils/acinclude.m4
@@ -25,7 +25,7 @@ AC_SUBST(INTLLIBS)
dnl AM_PROG_LEX
dnl Look for flex, lex or missing, then run AC_PROG_LEX and AC_DECL_YYTEXT
-AC_DEFUN(AM_PROG_LEX,
+AC_DEFUN([AM_PROG_LEX],
[missing_dir=ifelse([$1],,`cd $ac_aux_dir && pwd`,$1)
AC_CHECK_PROGS(LEX, flex lex, [$missing_dir/missing flex])
AC_PROG_LEX
diff --git a/contrib/binutils/binutils/aclocal.m4 b/contrib/binutils/binutils/aclocal.m4
index 1c78dc1..d1f4a36 100644
--- a/contrib/binutils/binutils/aclocal.m4
+++ b/contrib/binutils/binutils/aclocal.m4
@@ -37,6 +37,24 @@ AC_CHECK_PROGS(LEX, flex lex, [$missing_dir/missing flex])
AC_PROG_LEX
AC_DECL_YYTEXT])
+#serial 1
+# This test replaces the one in autoconf.
+# Currently this macro should have the same name as the autoconf macro
+# because gettext's gettext.m4 (distributed in the automake package)
+# still uses it. Otherwise, the use in gettext.m4 makes autoheader
+# give these diagnostics:
+# configure.in:556: AC_TRY_COMPILE was called before AC_ISC_POSIX
+# configure.in:556: AC_TRY_RUN was called before AC_ISC_POSIX
+
+undefine([AC_ISC_POSIX])
+
+AC_DEFUN([AC_ISC_POSIX],
+ [
+ dnl This test replaces the obsolescent AC_ISC_POSIX kludge.
+ AC_CHECK_LIB(cposix, strerror, [LIBS="$LIBS -lcposix"])
+ ]
+)
+
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
diff --git a/contrib/binutils/binutils/addr2line.c b/contrib/binutils/binutils/addr2line.c
index 174a034..354153e 100644
--- a/contrib/binutils/binutils/addr2line.c
+++ b/contrib/binutils/binutils/addr2line.c
@@ -1,5 +1,6 @@
/* addr2line.c -- convert addresses to line number and function name
- Copyright 1997, 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 1997, 1998, 1999, 2000, 2001, 2002, 2003
+ Free Software Foundation, Inc.
Contributed by Ulrich Lauther <Ulrich.Lauther@mchp.siemens.de>
This file is part of GNU Binutils.
@@ -37,9 +38,9 @@
#include "bucomm.h"
#include "budemang.h"
-static boolean with_functions; /* -f, show function names. */
-static boolean do_demangle; /* -C, demangle names. */
-static boolean base_names; /* -s, strip directory names. */
+static bfd_boolean with_functions; /* -f, show function names. */
+static bfd_boolean do_demangle; /* -C, demangle names. */
+static bfd_boolean base_names; /* -s, strip directory names. */
static int naddr; /* Number of addresses to process. */
static char **addr; /* Hex addresses to process. */
@@ -58,18 +59,16 @@ static struct option long_options[] =
{0, no_argument, 0, 0}
};
-static void usage PARAMS ((FILE *, int));
-static void slurp_symtab PARAMS ((bfd *));
-static void find_address_in_section PARAMS ((bfd *, asection *, PTR));
-static void translate_addresses PARAMS ((bfd *));
-static void process_file PARAMS ((const char *, const char *));
+static void usage (FILE *, int);
+static void slurp_symtab (bfd *);
+static void find_address_in_section (bfd *, asection *, void *);
+static void translate_addresses (bfd *);
+static void process_file (const char *, const char *);
/* Print a usage message to STREAM and exit with STATUS. */
static void
-usage (stream, status)
- FILE *stream;
- int status;
+usage (FILE *stream, int status)
{
fprintf (stream, _("Usage: %s [option(s)] [addr(s)]\n"), program_name);
fprintf (stream, _(" Convert addresses into line number/file name pairs.\n"));
@@ -93,22 +92,18 @@ usage (stream, status)
/* Read in the symbol table. */
static void
-slurp_symtab (abfd)
- bfd *abfd;
+slurp_symtab (bfd *abfd)
{
- long storage;
long symcount;
+ unsigned int size;
if ((bfd_get_file_flags (abfd) & HAS_SYMS) == 0)
return;
- storage = bfd_get_symtab_upper_bound (abfd);
- if (storage < 0)
- bfd_fatal (bfd_get_filename (abfd));
-
- syms = (asymbol **) xmalloc (storage);
+ symcount = bfd_read_minisymbols (abfd, FALSE, (void *) &syms, &size);
+ if (symcount == 0)
+ symcount = bfd_read_minisymbols (abfd, TRUE /* dynamic */, (void *) &syms, &size);
- symcount = bfd_canonicalize_symtab (abfd, syms);
if (symcount < 0)
bfd_fatal (bfd_get_filename (abfd));
}
@@ -120,16 +115,14 @@ static bfd_vma pc;
static const char *filename;
static const char *functionname;
static unsigned int line;
-static boolean found;
+static bfd_boolean found;
/* Look for an address in a section. This is called via
bfd_map_over_sections. */
static void
-find_address_in_section (abfd, section, data)
- bfd *abfd;
- asection *section;
- PTR data ATTRIBUTE_UNUSED;
+find_address_in_section (bfd *abfd, asection *section,
+ void *data ATTRIBUTE_UNUSED)
{
bfd_vma vma;
bfd_size_type size;
@@ -156,8 +149,7 @@ find_address_in_section (abfd, section, data)
file_name:line_number and optionally function name. */
static void
-translate_addresses (abfd)
- bfd *abfd;
+translate_addresses (bfd *abfd)
{
int read_stdin = (naddr == 0);
@@ -179,8 +171,8 @@ translate_addresses (abfd)
pc = bfd_scan_vma (*addr++, NULL, 16);
}
- found = false;
- bfd_map_over_sections (abfd, find_address_in_section, (PTR) NULL);
+ found = FALSE;
+ bfd_map_over_sections (abfd, find_address_in_section, NULL);
if (! found)
{
@@ -233,13 +225,14 @@ translate_addresses (abfd)
/* Process a file. */
static void
-process_file (file_name, target)
- const char *file_name;
- const char *target;
+process_file (const char *file_name, const char *target)
{
bfd *abfd;
char **matching;
+ if (get_file_size (file_name) < 1)
+ return;
+
abfd = bfd_openr (file_name, target);
if (abfd == NULL)
bfd_fatal (file_name);
@@ -271,12 +264,10 @@ process_file (file_name, target)
bfd_close (abfd);
}
-int main PARAMS ((int, char **));
+int main (int, char **);
int
-main (argc, argv)
- int argc;
- char **argv;
+main (int argc, char **argv)
{
const char *file_name;
char *target;
@@ -310,7 +301,7 @@ main (argc, argv)
target = optarg;
break;
case 'C':
- do_demangle = true;
+ do_demangle = TRUE;
if (optarg != NULL)
{
enum demangling_styles style;
@@ -327,10 +318,10 @@ main (argc, argv)
file_name = optarg;
break;
case 's':
- base_names = true;
+ base_names = TRUE;
break;
case 'f':
- with_functions = true;
+ with_functions = TRUE;
break;
case 'v':
case 'V':
diff --git a/contrib/binutils/binutils/ar.c b/contrib/binutils/binutils/ar.c
index ea1b456..ec0657d 100644
--- a/contrib/binutils/binutils/ar.c
+++ b/contrib/binutils/binutils/ar.c
@@ -1,6 +1,6 @@
/* ar.c - Archive modify and extract.
Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
- 2001, 2002
+ 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -24,7 +24,7 @@
should have long options too. GNU ar used to check file against filesystem
in quick_update and replace operations (would check mtime). Doesn't warn
when name truncated. No way to specify pos_end. Error messages should be
- more consistant. */
+ more consistent. */
#include "bfd.h"
#include "libiberty.h"
@@ -54,54 +54,30 @@
/* Kludge declaration from BFD! This is ugly! FIXME! XXX */
struct ar_hdr *
- bfd_special_undocumented_glue PARAMS ((bfd * abfd, const char *filename));
+ bfd_special_undocumented_glue (bfd * abfd, const char *filename);
/* Static declarations */
-static void
-mri_emul PARAMS ((void));
-
-static const char *
-normalize PARAMS ((const char *, bfd *));
-
-static void
-remove_output PARAMS ((void));
-
-static void
-map_over_members PARAMS ((bfd *, void (*)(bfd *), char **, int));
-
-static void
-print_contents PARAMS ((bfd * member));
-
-static void
-delete_members PARAMS ((bfd *, char **files_to_delete));
+static void mri_emul (void);
+static const char *normalize (const char *, bfd *);
+static void remove_output (void);
+static void map_over_members (bfd *, void (*)(bfd *), char **, int);
+static void print_contents (bfd * member);
+static void delete_members (bfd *, char **files_to_delete);
#if 0
-static void
-do_quick_append PARAMS ((const char *archive_filename,
- char **files_to_append));
+static void do_quick_append
+ (const char *archive_filename, char **files_to_append);
#endif
-static void
-move_members PARAMS ((bfd *, char **files_to_move));
-
-static void
-replace_members PARAMS ((bfd *, char **files_to_replace, boolean quick));
-
-static void
-print_descr PARAMS ((bfd * abfd));
-
-static void
-write_archive PARAMS ((bfd *));
-
-static void
-ranlib_only PARAMS ((const char *archname));
-
-static void
-ranlib_touch PARAMS ((const char *archname));
-
-static void
-usage PARAMS ((int));
+static void move_members (bfd *, char **files_to_move);
+static void replace_members
+ (bfd *, char **files_to_replace, bfd_boolean quick);
+static void print_descr (bfd * abfd);
+static void write_archive (bfd *);
+static void ranlib_only (const char *archname);
+static void ranlib_touch (const char *archname);
+static void usage (int);
/** Globals and flags */
@@ -127,7 +103,7 @@ int newer_only = 0;
/* Controls the writing of an archive symbol table (in BSD: a __.SYMDEF
member). -1 means we've been explicitly asked to not write a symbol table;
- +1 means we've been explictly asked to write it;
+ +1 means we've been explicitly asked to write it;
0 is the default.
Traditionally, the default in BSD has been to not write the table.
However, for POSIX.2 compliance the default is now to write a symbol table
@@ -148,25 +124,25 @@ enum pos
} postype = pos_default;
static bfd **
-get_pos_bfd PARAMS ((bfd **, enum pos, const char *));
+get_pos_bfd (bfd **, enum pos, const char *);
-/* For extract/delete only. If COUNTED_NAME_MODE is true, we only
+/* For extract/delete only. If COUNTED_NAME_MODE is TRUE, we only
extract the COUNTED_NAME_COUNTER instance of that name. */
-static boolean counted_name_mode = 0;
+static bfd_boolean counted_name_mode = 0;
static int counted_name_counter = 0;
/* Whether to truncate names of files stored in the archive. */
-static boolean ar_truncate = false;
+static bfd_boolean ar_truncate = FALSE;
/* Whether to use a full file name match when searching an archive.
This is convenient for archives created by the Microsoft lib
program. */
-static boolean full_pathname = false;
+static bfd_boolean full_pathname = FALSE;
int interactive = 0;
static void
-mri_emul ()
+mri_emul (void)
{
interactive = isatty (fileno (stdin));
yyparse ();
@@ -177,11 +153,7 @@ mri_emul ()
whose name matches one in FILES. */
static void
-map_over_members (arch, function, files, count)
- bfd *arch;
- void (*function) PARAMS ((bfd *));
- char **files;
- int count;
+map_over_members (bfd *arch, void (*function)(bfd *), char **files, int count)
{
bfd *head;
int match_count;
@@ -204,7 +176,7 @@ map_over_members (arch, function, files, count)
for (; count > 0; files++, count--)
{
- boolean found = false;
+ bfd_boolean found = FALSE;
match_count = 0;
for (head = arch->next; head; head = head->next)
@@ -229,7 +201,7 @@ map_over_members (arch, function, files, count)
continue;
}
- found = true;
+ found = TRUE;
function (head);
}
}
@@ -239,11 +211,10 @@ map_over_members (arch, function, files, count)
}
}
-boolean operation_alters_arch = false;
+bfd_boolean operation_alters_arch = FALSE;
static void
-usage (help)
- int help;
+usage (int help)
{
FILE *s;
@@ -303,9 +274,7 @@ usage (help)
name which we will use in an archive. */
static const char *
-normalize (file, abfd)
- const char *file;
- bfd *abfd;
+normalize (const char *file, bfd *abfd)
{
const char *filename;
@@ -351,12 +320,12 @@ static FILE *output_file = NULL;
static bfd *output_bfd = NULL;
static void
-remove_output ()
+remove_output (void)
{
if (output_filename != NULL)
{
- if (output_bfd != NULL && output_bfd->iostream != NULL)
- fclose ((FILE *) (output_bfd->iostream));
+ if (output_bfd != NULL)
+ bfd_cache_close (output_bfd);
if (output_file != NULL)
fclose (output_file);
unlink (output_filename);
@@ -366,12 +335,10 @@ remove_output ()
/* The option parsing should be in its own function.
It will be when I have getopt working. */
-int main PARAMS ((int, char **));
+int main (int, char **);
int
-main (argc, argv)
- int argc;
- char **argv;
+main (int argc, char **argv)
{
char *arg_ptr;
char c;
@@ -386,6 +353,7 @@ main (argc, argv)
char *inarch_filename;
int show_version;
int i;
+ int do_posix = 0;
#if defined (HAVE_SETLOCALE) && defined (HAVE_LC_MESSAGES)
setlocale (LC_MESSAGES, "");
@@ -455,7 +423,7 @@ main (argc, argv)
if (is_ranlib)
{
- boolean touch = false;
+ bfd_boolean touch = FALSE;
if (argc < 2
|| strcmp (argv[1], "--help") == 0
@@ -470,7 +438,7 @@ main (argc, argv)
if (strcmp (argv[1], "-t") == 0)
{
++arg_index;
- touch = true;
+ touch = TRUE;
}
while (arg_index < argc)
{
@@ -492,107 +460,125 @@ main (argc, argv)
if (argc < 2)
usage (0);
- arg_ptr = argv[1];
+ arg_index = 1;
+ arg_ptr = argv[arg_index];
if (*arg_ptr == '-')
- ++arg_ptr; /* compatibility */
+ {
+ /* When the first option starts with '-' we support POSIX-compatible
+ option parsing. */
+ do_posix = 1;
+ ++arg_ptr; /* compatibility */
+ }
- while ((c = *arg_ptr++) != '\0')
+ do
{
- switch (c)
+ while ((c = *arg_ptr++) != '\0')
{
- case 'd':
- case 'm':
- case 'p':
- case 'q':
- case 'r':
- case 't':
- case 'x':
- if (operation != none)
- fatal (_("two different operation options specified"));
switch (c)
{
case 'd':
- operation = delete;
- operation_alters_arch = true;
- break;
case 'm':
- operation = move;
- operation_alters_arch = true;
- break;
case 'p':
- operation = print_files;
- break;
case 'q':
- operation = quick_append;
- operation_alters_arch = true;
- break;
case 'r':
- operation = replace;
- operation_alters_arch = true;
- break;
case 't':
- operation = print_table;
- break;
case 'x':
- operation = extract;
+ if (operation != none)
+ fatal (_("two different operation options specified"));
+ switch (c)
+ {
+ case 'd':
+ operation = delete;
+ operation_alters_arch = TRUE;
+ break;
+ case 'm':
+ operation = move;
+ operation_alters_arch = TRUE;
+ break;
+ case 'p':
+ operation = print_files;
+ break;
+ case 'q':
+ operation = quick_append;
+ operation_alters_arch = TRUE;
+ break;
+ case 'r':
+ operation = replace;
+ operation_alters_arch = TRUE;
+ break;
+ case 't':
+ operation = print_table;
+ break;
+ case 'x':
+ operation = extract;
+ break;
+ }
+ case 'l':
+ break;
+ case 'c':
+ silent_create = 1;
+ break;
+ case 'o':
+ preserve_dates = 1;
+ break;
+ case 'V':
+ show_version = TRUE;
+ break;
+ case 's':
+ write_armap = 1;
+ break;
+ case 'S':
+ write_armap = -1;
+ break;
+ case 'u':
+ newer_only = 1;
+ break;
+ case 'v':
+ verbose = 1;
break;
+ case 'a':
+ postype = pos_after;
+ break;
+ case 'b':
+ postype = pos_before;
+ break;
+ case 'i':
+ postype = pos_before;
+ break;
+ case 'M':
+ mri_mode = 1;
+ break;
+ case 'N':
+ counted_name_mode = TRUE;
+ break;
+ case 'f':
+ ar_truncate = TRUE;
+ break;
+ case 'P':
+ full_pathname = TRUE;
+ break;
+ default:
+ /* xgettext:c-format */
+ non_fatal (_("illegal option -- %c"), c);
+ usage (0);
}
- case 'l':
- break;
- case 'c':
- silent_create = 1;
- break;
- case 'o':
- preserve_dates = 1;
- break;
- case 'V':
- show_version = true;
- break;
- case 's':
- write_armap = 1;
- break;
- case 'S':
- write_armap = -1;
- break;
- case 'u':
- newer_only = 1;
- break;
- case 'v':
- verbose = 1;
- break;
- case 'a':
- postype = pos_after;
- break;
- case 'b':
- postype = pos_before;
- break;
- case 'i':
- postype = pos_before;
- break;
- case 'M':
- mri_mode = 1;
- break;
- case 'N':
- counted_name_mode = true;
- break;
- case 'f':
- ar_truncate = true;
- break;
- case 'P':
- full_pathname = true;
- break;
- default:
- /* xgettext:c-format */
- non_fatal (_("illegal option -- %c"), c);
- usage (0);
}
+
+ /* With POSIX-compatible option parsing continue with the next
+ argument if it starts with '-'. */
+ if (do_posix && arg_index + 1 < argc && argv[arg_index + 1][0] == '-')
+ arg_ptr = argv[++arg_index] + 1;
+ else
+ do_posix = 0;
}
+ while (do_posix);
if (show_version)
print_version ("ar");
- if (argc < 3)
+ ++arg_index;
+ if (arg_index >= argc)
usage (0);
if (mri_mode)
@@ -611,7 +597,7 @@ main (argc, argv)
if ((operation == none || operation == print_table)
&& write_armap == 1)
{
- ranlib_only (argv[2]);
+ ranlib_only (argv[arg_index]);
xexit (0);
}
@@ -621,8 +607,6 @@ main (argc, argv)
if (newer_only && operation != replace)
fatal (_("`u' is only meaningful with the `r' option."));
- arg_index = 2;
-
if (postype != pos_default)
posname = argv[arg_index++];
@@ -726,9 +710,7 @@ main (argc, argv)
}
bfd *
-open_inarch (archive_filename, file)
- const char *archive_filename;
- const char *file;
+open_inarch (const char *archive_filename, const char *file)
{
const char *target;
bfd **last_one;
@@ -785,6 +767,8 @@ open_inarch (archive_filename, file)
|| ! bfd_set_format (arch, bfd_archive)
|| ! bfd_close (arch))
bfd_fatal (archive_filename);
+ else if (!silent_create)
+ non_fatal (_("creating %s"), archive_filename);
/* If we die creating a new archive, don't leave it around. */
output_filename = archive_filename;
@@ -825,8 +809,7 @@ open_inarch (archive_filename, file)
}
static void
-print_contents (abfd)
- bfd *abfd;
+print_contents (bfd *abfd)
{
int ncopied = 0;
char *cbuf = xmalloc (BUFSIZE);
@@ -838,7 +821,7 @@ print_contents (abfd)
if (verbose)
/* xgettext:c-format */
- printf (_("\n<member %s>\n\n"), bfd_get_filename (abfd));
+ printf (_("\n<%s>\n\n"), bfd_get_filename (abfd));
bfd_seek (abfd, (file_ptr) 0, SEEK_SET);
@@ -873,8 +856,7 @@ print_contents (abfd)
Gilmore */
void
-extract_file (abfd)
- bfd *abfd;
+extract_file (bfd *abfd)
{
FILE *ostream;
char *cbuf = xmalloc (BUFSIZE);
@@ -966,16 +948,14 @@ extract_file (abfd)
/* Just do it quickly; don't worry about dups, armap, or anything like that */
static void
-do_quick_append (archive_filename, files_to_append)
- const char *archive_filename;
- char **files_to_append;
+do_quick_append (const char *archive_filename, char **files_to_append)
{
FILE *ofile, *ifile;
char *buf = xmalloc (BUFSIZE);
long tocopy, thistime;
bfd *temp;
struct stat sbuf;
- boolean newfile = false;
+ bfd_boolean newfile = FALSE;
bfd_set_error (bfd_error_no_error);
if (stat (archive_filename, &sbuf) != 0)
@@ -998,7 +978,7 @@ do_quick_append (archive_filename, files_to_append)
bfd_fatal (archive_filename);
#endif
- newfile = true;
+ newfile = TRUE;
}
ofile = fopen (archive_filename, FOPEN_AUB);
@@ -1013,9 +993,9 @@ do_quick_append (archive_filename, files_to_append)
{
bfd_fatal (archive_filename);
}
- if (newfile == false)
+ if (!newfile)
{
- if (bfd_check_format (temp, bfd_archive) != true)
+ if (!bfd_check_format (temp, bfd_archive))
/* xgettext:c-format */
fatal (_("%s is not an archive"), archive_filename);
}
@@ -1030,7 +1010,7 @@ do_quick_append (archive_filename, files_to_append)
if (ar_truncate)
temp->flags |= BFD_TRADITIONAL_FORMAT;
- /* assume it's an achive, go straight to the end, sans $200 */
+ /* assume it's an archive, go straight to the end, sans $200 */
fseek (ofile, 0, 2);
for (; files_to_append && *files_to_append; ++files_to_append)
@@ -1080,8 +1060,7 @@ do_quick_append (archive_filename, files_to_append)
#endif /* 0 */
static void
-write_archive (iarch)
- bfd *iarch;
+write_archive (bfd *iarch)
{
bfd *obfd;
char *old_name, *new_name;
@@ -1113,7 +1092,7 @@ write_archive (iarch)
obfd->flags |= BFD_TRADITIONAL_FORMAT;
}
- if (bfd_set_archive_head (obfd, contents_head) != true)
+ if (!bfd_set_archive_head (obfd, contents_head))
bfd_fatal (old_name);
if (!bfd_close (obfd))
@@ -1134,10 +1113,7 @@ write_archive (iarch)
and should be a pos value. */
static bfd **
-get_pos_bfd (contents, default_pos, default_posname)
- bfd **contents;
- enum pos default_pos;
- const char *default_posname;
+get_pos_bfd (bfd **contents, enum pos default_pos, const char *default_posname)
{
bfd **after_bfd = contents;
enum pos realpos;
@@ -1173,13 +1149,11 @@ get_pos_bfd (contents, default_pos, default_posname)
}
static void
-delete_members (arch, files_to_delete)
- bfd *arch;
- char **files_to_delete;
+delete_members (bfd *arch, char **files_to_delete)
{
bfd **current_ptr_ptr;
- boolean found;
- boolean something_changed = false;
+ bfd_boolean found;
+ bfd_boolean something_changed = FALSE;
int match_count;
for (; *files_to_delete != NULL; ++files_to_delete)
@@ -1192,12 +1166,12 @@ delete_members (arch, files_to_delete)
if (!strcmp (*files_to_delete, "__.SYMDEF"))
{
- arch->has_armap = false;
+ arch->has_armap = FALSE;
write_armap = -1;
continue;
}
- found = false;
+ found = FALSE;
match_count = 0;
current_ptr_ptr = &(arch->next);
while (*current_ptr_ptr)
@@ -1214,8 +1188,8 @@ delete_members (arch, files_to_delete)
}
else
{
- found = true;
- something_changed = true;
+ found = TRUE;
+ something_changed = TRUE;
if (verbose)
printf ("d - %s\n",
*files_to_delete);
@@ -1227,7 +1201,7 @@ delete_members (arch, files_to_delete)
current_ptr_ptr = &((*current_ptr_ptr)->next);
}
- if (verbose && found == false)
+ if (verbose && !found)
{
/* xgettext:c-format */
printf (_("No member named `%s'\n"), *files_to_delete);
@@ -1236,7 +1210,7 @@ delete_members (arch, files_to_delete)
;
}
- if (something_changed == true)
+ if (something_changed)
write_archive (arch);
else
output_filename = NULL;
@@ -1246,9 +1220,7 @@ delete_members (arch, files_to_delete)
/* Reposition existing members within an archive */
static void
-move_members (arch, files_to_move)
- bfd *arch;
- char **files_to_move;
+move_members (bfd *arch, char **files_to_move)
{
bfd **after_bfd; /* New entries go after this one */
bfd **current_ptr_ptr; /* cdr pointer into contents */
@@ -1293,12 +1265,9 @@ move_members (arch, files_to_move)
/* Ought to default to replacing in place, but this is existing practice! */
static void
-replace_members (arch, files_to_move, quick)
- bfd *arch;
- char **files_to_move;
- boolean quick;
+replace_members (bfd *arch, char **files_to_move, bfd_boolean quick)
{
- boolean changed = false;
+ bfd_boolean changed = FALSE;
bfd **after_bfd; /* New entries go after this one */
bfd *current;
bfd **current_ptr;
@@ -1344,7 +1313,7 @@ replace_members (arch, files_to_move, quick)
{
/* Snip out this entry from the chain. */
*current_ptr = (*current_ptr)->next;
- changed = true;
+ changed = TRUE;
}
goto next_file;
@@ -1355,8 +1324,10 @@ replace_members (arch, files_to_move, quick)
/* Add to the end of the archive. */
after_bfd = get_pos_bfd (&arch->next, pos_end, NULL);
- if (ar_emul_append (after_bfd, *files_to_move, verbose))
- changed = true;
+
+ if (get_file_size (* files_to_move) > 0
+ && ar_emul_append (after_bfd, *files_to_move, verbose))
+ changed = TRUE;
next_file:;
@@ -1370,11 +1341,12 @@ replace_members (arch, files_to_move, quick)
}
static void
-ranlib_only (archname)
- const char *archname;
+ranlib_only (const char *archname)
{
bfd *arch;
+ if (get_file_size (archname) < 1)
+ return;
write_armap = 1;
arch = open_inarch (archname, (char *) NULL);
if (arch == NULL)
@@ -1385,8 +1357,7 @@ ranlib_only (archname)
/* Update the timestamp of the symbol map of an archive. */
static void
-ranlib_touch (archname)
- const char *archname;
+ranlib_touch (const char *archname)
{
#ifdef __GO32__
/* I don't think updating works on go32. */
@@ -1396,6 +1367,8 @@ ranlib_touch (archname)
bfd *arch;
char **matching;
+ if (get_file_size (archname) < 1)
+ return;
f = open (archname, O_RDWR | O_BINARY, 0);
if (f < 0)
{
@@ -1431,8 +1404,7 @@ ranlib_touch (archname)
/* Things which are interesting to map over all or some of the files: */
static void
-print_descr (abfd)
- bfd *abfd;
+print_descr (bfd *abfd)
{
print_arelt_descr (stdout, abfd, verbose);
}
diff --git a/contrib/binutils/binutils/arlex.l b/contrib/binutils/binutils/arlex.l
index c1771a5..ab1ff16 100644
--- a/contrib/binutils/binutils/arlex.l
+++ b/contrib/binutils/binutils/arlex.l
@@ -1,7 +1,7 @@
%{
/* arlex.l - Strange script language lexer */
-/* Copyright 1992, 1997, 2000, 2002 Free Software Foundation, Inc.
+/* Copyright 1992, 1997, 2000, 2002, 2003 Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -31,7 +31,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define YY_NO_UNPUT
-extern int yylex PARAMS ((void));
+extern int yylex (void);
int linenumber;
%}
@@ -87,5 +87,5 @@ int linenumber;
%%
#ifndef yywrap
/* Needed for lex, though not flex. */
-int yywrap() { return 1; }
+int yywrap(void) { return 1; }
#endif
diff --git a/contrib/binutils/binutils/arparse.y b/contrib/binutils/binutils/arparse.y
index cf0ece1..d54de24 100644
--- a/contrib/binutils/binutils/arparse.y
+++ b/contrib/binutils/binutils/arparse.y
@@ -1,7 +1,8 @@
%{
/* arparse.y - Stange script language parser */
-/* Copyright 1992, 1993, 1995, 1997, 1999 Free Software Foundation, Inc.
+/* Copyright 1992, 1993, 1995, 1997, 1999, 2003
+ Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -29,8 +30,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "bucomm.h"
#include "arsup.h"
extern int verbose;
-extern int yylex PARAMS ((void));
-static int yyerror PARAMS ((const char *));
+extern int yylex (void);
+static int yyerror (const char *);
%}
%union {
@@ -193,8 +194,7 @@ verbose_command:
%%
static int
-yyerror (x)
- const char *x ATTRIBUTE_UNUSED;
+yyerror (const char *x ATTRIBUTE_UNUSED)
{
extern int linenumber;
diff --git a/contrib/binutils/binutils/arsup.c b/contrib/binutils/binutils/arsup.c
index 7b01d37..5160dc4 100644
--- a/contrib/binutils/binutils/arsup.c
+++ b/contrib/binutils/binutils/arsup.c
@@ -1,5 +1,5 @@
/* arsup.c - Archive support for MRI compatibility
- Copyright 1992, 1994, 1995, 1996, 1997, 2000, 2002
+ Copyright 1992, 1994, 1995, 1996, 1997, 2000, 2002, 2003, 2004
Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -32,17 +32,14 @@
#include "filenames.h"
static void map_over_list
- PARAMS ((bfd *, void (*function) (bfd *, bfd *), struct list *));
-static void ar_directory_doer PARAMS ((bfd *, bfd *));
-static void ar_addlib_doer PARAMS ((bfd *, bfd *));
+ (bfd *, void (*function) (bfd *, bfd *), struct list *);
+static void ar_directory_doer (bfd *, bfd *);
+static void ar_addlib_doer (bfd *, bfd *);
extern int verbose;
static void
-map_over_list (arch, function, list)
- bfd *arch;
- void (*function) PARAMS ((bfd *, bfd *));
- struct list *list;
+map_over_list (bfd *arch, void (*function) (bfd *, bfd *), struct list *list)
{
bfd *head;
@@ -69,7 +66,7 @@ map_over_list (arch, function, list)
want to hack multiple references. */
for (ptr = list; ptr; ptr = ptr->next)
{
- boolean found = false;
+ bfd_boolean found = FALSE;
bfd *prev = arch;
for (head = arch->next; head; head = head->next)
@@ -77,7 +74,7 @@ map_over_list (arch, function, list)
if (head->filename != NULL
&& FILENAME_CMP (ptr->name, head->filename) == 0)
{
- found = true;
+ found = TRUE;
function (head, prev);
}
prev = head;
@@ -92,18 +89,13 @@ map_over_list (arch, function, list)
FILE *outfile;
static void
-ar_directory_doer (abfd, ignore)
- bfd *abfd;
- bfd *ignore ATTRIBUTE_UNUSED;
+ar_directory_doer (bfd *abfd, bfd *ignore ATTRIBUTE_UNUSED)
{
print_arelt_descr(outfile, abfd, verbose);
}
void
-ar_directory (ar_name, list, output)
- char *ar_name;
- struct list *list;
- char *output;
+ar_directory (char *ar_name, struct list *list, char *output)
{
bfd *arch;
@@ -130,7 +122,7 @@ ar_directory (ar_name, list, output)
}
void
-DEFUN_VOID(prompt)
+prompt (void)
{
extern int interactive;
@@ -142,7 +134,7 @@ DEFUN_VOID(prompt)
}
void
-maybequit ()
+maybequit (void)
{
if (! interactive)
xexit (9);
@@ -153,9 +145,7 @@ bfd *obfd;
char *real_name;
void
-ar_open (name, t)
- char *name;
- int t;
+ar_open (char *name, int t)
{
char *tname = (char *) xmalloc (strlen (name) + 10);
const char *bname = lbasename (name);
@@ -192,7 +182,7 @@ ar_open (name, t)
return;
}
- if (bfd_check_format(ibfd, bfd_archive) != true)
+ if (!bfd_check_format(ibfd, bfd_archive))
{
fprintf (stderr,
_("%s: file %s is not an archive\n"),
@@ -219,9 +209,7 @@ ar_open (name, t)
}
static void
-ar_addlib_doer (abfd, prev)
- bfd *abfd;
- bfd *prev;
+ar_addlib_doer (bfd *abfd, bfd *prev)
{
/* Add this module to the output bfd. */
if (prev != NULL)
@@ -232,9 +220,7 @@ ar_addlib_doer (abfd, prev)
}
void
-ar_addlib (name, list)
- char *name;
- struct list *list;
+ar_addlib (char *name, struct list *list)
{
if (obfd == NULL)
{
@@ -249,13 +235,12 @@ ar_addlib (name, list)
if (arch != NULL)
map_over_list (arch, ar_addlib_doer, list);
- /* Don't close the bfd, since it will make the elements disasppear. */
+ /* Don't close the bfd, since it will make the elements disappear. */
}
}
void
-ar_addmod (list)
- struct list *list;
+ar_addmod (struct list *list)
{
if (!obfd)
{
@@ -286,15 +271,14 @@ ar_addmod (list)
void
-ar_clear ()
+ar_clear (void)
{
if (obfd)
obfd->archive_head = 0;
}
void
-ar_delete (list)
- struct list *list;
+ar_delete (struct list *list)
{
if (!obfd)
{
@@ -336,7 +320,7 @@ ar_delete (list)
}
void
-ar_save ()
+ar_save (void)
{
if (!obfd)
{
@@ -349,15 +333,14 @@ ar_save ()
bfd_close (obfd);
- rename (ofilename, real_name);
+ smart_rename (ofilename, real_name, 0);
obfd = 0;
free (ofilename);
}
}
void
-ar_replace (list)
- struct list *list;
+ar_replace (struct list *list)
{
if (!obfd)
{
@@ -423,7 +406,7 @@ ar_replace (list)
/* And I added this one. */
void
-ar_list ()
+ar_list (void)
{
if (!obfd)
{
@@ -446,18 +429,17 @@ ar_list ()
}
void
-ar_end ()
+ar_end (void)
{
if (obfd)
{
- fclose ((FILE *)(obfd->iostream));
+ bfd_cache_close (obfd);
unlink (bfd_get_filename (obfd));
}
}
void
-ar_extract (list)
- struct list *list;
+ar_extract (struct list *list)
{
if (!obfd)
{
diff --git a/contrib/binutils/binutils/arsup.h b/contrib/binutils/binutils/arsup.h
index aeec258..e3a1807 100644
--- a/contrib/binutils/binutils/arsup.h
+++ b/contrib/binutils/binutils/arsup.h
@@ -1,5 +1,5 @@
/* arsup.h - archive support header file
- Copyright 1992, 1993, 1994, 1996 Free Software Foundation, Inc.
+ Copyright 1992, 1993, 1994, 1996, 2003 Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -22,40 +22,40 @@ struct list {
struct list *next;
};
-void maybequit PARAMS ((void));
+void maybequit (void);
-void prompt PARAMS ((void));
+void prompt (void);
-void ar_clear PARAMS ((void));
+void ar_clear (void);
-void ar_replace PARAMS ((struct list *));
+void ar_replace (struct list *);
-void ar_delete PARAMS ((struct list *));
+void ar_delete (struct list *);
-void ar_save PARAMS ((void));
+void ar_save (void);
-void ar_list PARAMS ((void));
+void ar_list (void);
-void ar_open PARAMS ((char *, int));
+void ar_open (char *, int);
-void ar_directory PARAMS ((char *, struct list *, char *));
+void ar_directory (char *, struct list *, char *);
-void ar_addmod PARAMS ((struct list *));
+void ar_addmod (struct list *);
-void ar_addlib PARAMS ((char *, struct list *));
+void ar_addlib (char *, struct list *);
-void ar_end PARAMS ((void));
+void ar_end (void);
-void ar_extract PARAMS ((struct list *));
+void ar_extract (struct list *);
-bfd *open_inarch PARAMS ((const char *archive_filename, const char *));
+bfd *open_inarch (const char *archive_filename, const char *);
-extern int yylex PARAMS ((void));
+extern int yylex (void);
-int yyparse PARAMS ((void));
+int yyparse (void);
/* Functions from ar.c */
-void extract_file PARAMS ((bfd * abfd));
+void extract_file (bfd * abfd);
extern int interactive;
diff --git a/contrib/binutils/binutils/binemul.c b/contrib/binutils/binutils/binemul.c
index 5144793..3f6ed65 100644
--- a/contrib/binutils/binutils/binemul.c
+++ b/contrib/binutils/binutils/binemul.c
@@ -1,5 +1,5 @@
/* Binutils emulation layer.
- Copyright (C) 2002 Free Software Foundation, Inc.
+ Copyright 2002, 2003 Free Software Foundation, Inc.
Written by Tom Rix, Redhat.
This file is part of GNU Binutils.
@@ -23,39 +23,32 @@
extern bin_emulation_xfer_type bin_dummy_emulation;
void
-ar_emul_usage (fp)
- FILE *fp;
+ar_emul_usage (FILE *fp)
{
if (bin_dummy_emulation.ar_usage)
bin_dummy_emulation.ar_usage (fp);
}
void
-ar_emul_default_usage (fp)
- FILE *fp;
+ar_emul_default_usage (FILE *fp)
{
AR_EMUL_USAGE_PRINT_OPTION_HEADER (fp);
/* xgettext:c-format */
fprintf (fp, _(" No emulation specific options\n"));
}
-boolean
-ar_emul_append (after_bfd, file_name, verbose)
- bfd **after_bfd;
- char *file_name;
- boolean verbose;
+bfd_boolean
+ar_emul_append (bfd **after_bfd, char *file_name, bfd_boolean verbose)
{
if (bin_dummy_emulation.ar_append)
return bin_dummy_emulation.ar_append (after_bfd, file_name, verbose);
- return false;
+ return FALSE;
}
-boolean
-ar_emul_default_append (after_bfd, file_name, verbose)
- bfd **after_bfd;
- char *file_name;
- boolean verbose;
+bfd_boolean
+ar_emul_default_append (bfd **after_bfd, char *file_name,
+ bfd_boolean verbose)
{
bfd *temp;
@@ -67,26 +60,21 @@ ar_emul_default_append (after_bfd, file_name, verbose)
(*after_bfd)->next = temp;
- return true;
+ return TRUE;
}
-boolean
-ar_emul_replace (after_bfd, file_name, verbose)
- bfd **after_bfd;
- char *file_name;
- boolean verbose;
+bfd_boolean
+ar_emul_replace (bfd **after_bfd, char *file_name, bfd_boolean verbose)
{
if (bin_dummy_emulation.ar_replace)
return bin_dummy_emulation.ar_replace (after_bfd, file_name, verbose);
- return false;
+ return FALSE;
}
-boolean
-ar_emul_default_replace (after_bfd, file_name, verbose)
- bfd **after_bfd;
- char *file_name;
- boolean verbose;
+bfd_boolean
+ar_emul_default_replace (bfd **after_bfd, char *file_name,
+ bfd_boolean verbose)
{
bfd *temp;
@@ -98,27 +86,22 @@ ar_emul_default_replace (after_bfd, file_name, verbose)
(*after_bfd)->next = temp;
- return true;
+ return TRUE;
}
-boolean
-ar_emul_create (abfd_out, archive_file_name, file_name)
- bfd **abfd_out;
- char *archive_file_name;
- char *file_name;
+bfd_boolean
+ar_emul_create (bfd **abfd_out, char *archive_file_name, char *file_name)
{
if (bin_dummy_emulation.ar_create)
return bin_dummy_emulation.ar_create (abfd_out, archive_file_name,
file_name);
- return false;
+ return FALSE;
}
-boolean
-ar_emul_default_create (abfd_out, archive_file_name, file_name)
- bfd **abfd_out;
- char *archive_file_name;
- char *file_name;
+bfd_boolean
+ar_emul_default_create (bfd **abfd_out, char *archive_file_name,
+ char *file_name)
{
char *target = NULL;
@@ -144,22 +127,20 @@ ar_emul_default_create (abfd_out, archive_file_name, file_name)
|| ! bfd_close (*abfd_out))
bfd_fatal (archive_file_name);
- return true;
+ return TRUE;
}
-boolean
-ar_emul_parse_arg (arg)
- char *arg;
+bfd_boolean
+ar_emul_parse_arg (char *arg)
{
if (bin_dummy_emulation.ar_parse_arg)
return bin_dummy_emulation.ar_parse_arg (arg);
- return false;
+ return FALSE;
}
-boolean
-ar_emul_default_parse_arg (arg)
- char *arg ATTRIBUTE_UNUSED;
+bfd_boolean
+ar_emul_default_parse_arg (char *arg ATTRIBUTE_UNUSED)
{
- return false;
+ return FALSE;
}
diff --git a/contrib/binutils/binutils/binemul.h b/contrib/binutils/binutils/binemul.h
index bbcb16e..59dc2bd 100644
--- a/contrib/binutils/binutils/binemul.h
+++ b/contrib/binutils/binutils/binemul.h
@@ -1,5 +1,5 @@
/* Binutils emulation layer.
- Copyright (C) 2002 Free Software Foundation, Inc.
+ Copyright 2002, 2003 Free Software Foundation, Inc.
Written by Tom Rix, Redhat.
This file is part of GNU Binutils.
@@ -24,16 +24,16 @@
#include "bfd.h"
#include "bucomm.h"
-extern void ar_emul_usage PARAMS ((FILE *));
-extern void ar_emul_default_usage PARAMS ((FILE *));
-extern boolean ar_emul_append PARAMS ((bfd **, char *, boolean));
-extern boolean ar_emul_default_append PARAMS ((bfd **, char *, boolean));
-extern boolean ar_emul_replace PARAMS ((bfd **, char *, boolean));
-extern boolean ar_emul_default_replace PARAMS ((bfd **, char *, boolean));
-extern boolean ar_emul_create PARAMS ((bfd **, char *, char *));
-extern boolean ar_emul_default_create PARAMS ((bfd **, char *, char *));
-extern boolean ar_emul_parse_arg PARAMS ((char *));
-extern boolean ar_emul_default_parse_arg PARAMS ((char *));
+extern void ar_emul_usage (FILE *);
+extern void ar_emul_default_usage (FILE *);
+extern bfd_boolean ar_emul_append (bfd **, char *, bfd_boolean);
+extern bfd_boolean ar_emul_default_append (bfd **, char *, bfd_boolean);
+extern bfd_boolean ar_emul_replace (bfd **, char *, bfd_boolean);
+extern bfd_boolean ar_emul_default_replace (bfd **, char *, bfd_boolean);
+extern bfd_boolean ar_emul_create (bfd **, char *, char *);
+extern bfd_boolean ar_emul_default_create (bfd **, char *, char *);
+extern bfd_boolean ar_emul_parse_arg (char *);
+extern bfd_boolean ar_emul_default_parse_arg (char *);
/* Macros for common output. */
@@ -53,11 +53,11 @@ extern boolean ar_emul_default_parse_arg PARAMS ((char *));
typedef struct bin_emulation_xfer_struct
{
/* Print out the extra options. */
- void (* ar_usage) PARAMS ((FILE *fp));
- boolean (* ar_append) PARAMS ((bfd **, char *, boolean));
- boolean (* ar_replace) PARAMS ((bfd **, char *, boolean));
- boolean (* ar_create) PARAMS ((bfd **, char *, char *));
- boolean (* ar_parse_arg) PARAMS ((char *));
+ void (* ar_usage) (FILE *fp);
+ bfd_boolean (* ar_append) (bfd **, char *, bfd_boolean);
+ bfd_boolean (* ar_replace) (bfd **, char *, bfd_boolean);
+ bfd_boolean (* ar_create) (bfd **, char *, char *);
+ bfd_boolean (* ar_parse_arg) (char *);
}
bin_emulation_xfer_type;
diff --git a/contrib/binutils/binutils/bucomm.c b/contrib/binutils/binutils/bucomm.c
index 7ffcaba..6573e2d 100644
--- a/contrib/binutils/binutils/bucomm.c
+++ b/contrib/binutils/binutils/bucomm.c
@@ -1,5 +1,5 @@
/* bucomm.c -- Bin Utils COMmon code.
- Copyright 1991, 1992, 1993, 1994, 1995, 1997, 1998, 2000, 2001, 2002
+ Copyright 1991, 1992, 1993, 1994, 1995, 1997, 1998, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -23,9 +23,11 @@
loaded, but for now it's not necessary. */
#include "bfd.h"
+#include "bfdver.h"
#include "libiberty.h"
#include "bucomm.h"
#include "filenames.h"
+#include "libbfd.h"
#include <sys/stat.h>
#include <time.h> /* ctime, maybe time_t */
@@ -35,14 +37,18 @@
typedef long time_t;
#endif
#endif
+
+static const char * endian_string (enum bfd_endian);
+static int display_target_list (void);
+static int display_info_table (int, int);
+static int display_target_tables (void);
-/* Error reporting */
+/* Error reporting. */
char *program_name;
void
-bfd_nonfatal (string)
- const char *string;
+bfd_nonfatal (const char *string)
{
const char *errmsg = bfd_errmsg (bfd_get_error ());
@@ -53,17 +59,14 @@ bfd_nonfatal (string)
}
void
-bfd_fatal (string)
- const char *string;
+bfd_fatal (const char *string)
{
bfd_nonfatal (string);
xexit (1);
}
void
-report (format, args)
- const char * format;
- va_list args;
+report (const char * format, va_list args)
{
fprintf (stderr, "%s: ", program_name);
vfprintf (stderr, format, args);
@@ -97,7 +100,7 @@ non_fatal VPARAMS ((const char *format, ...))
different target. */
void
-set_default_bfd_target ()
+set_default_bfd_target (void)
{
/* The macro TARGET is defined by Makefile. */
const char *target = TARGET;
@@ -107,13 +110,12 @@ set_default_bfd_target ()
target, bfd_errmsg (bfd_get_error ()));
}
-/* After a false return from bfd_check_format_matches with
+/* After a FALSE return from bfd_check_format_matches with
bfd_get_error () == bfd_error_file_ambiguously_recognized, print
the possible matching targets. */
void
-list_matching_formats (p)
- char **p;
+list_matching_formats (char **p)
{
fprintf (stderr, _("%s: Matching formats:"), program_name);
while (*p)
@@ -124,9 +126,7 @@ list_matching_formats (p)
/* List the supported targets. */
void
-list_supported_targets (name, f)
- const char *name;
- FILE *f;
+list_supported_targets (const char *name, FILE *f)
{
int t;
const char **targ_names = bfd_target_list ();
@@ -145,11 +145,9 @@ list_supported_targets (name, f)
/* List the supported architectures. */
void
-list_supported_architectures (name, f)
- const char *name;
- FILE *f;
+list_supported_architectures (const char *name, FILE *f)
{
- const char** arch;
+ const char **arch;
if (name == NULL)
fprintf (f, _("Supported architectures:"));
@@ -161,15 +159,205 @@ list_supported_architectures (name, f)
fprintf (f, "\n");
}
+/* The length of the longest architecture name + 1. */
+#define LONGEST_ARCH sizeof ("powerpc:common")
+
+static const char *
+endian_string (enum bfd_endian endian)
+{
+ switch (endian)
+ {
+ case BFD_ENDIAN_BIG: return "big endian";
+ case BFD_ENDIAN_LITTLE: return "little endian";
+ default: return "endianness unknown";
+ }
+}
+
+/* List the targets that BFD is configured to support, each followed
+ by its endianness and the architectures it supports. */
+
+static int
+display_target_list (void)
+{
+ char *dummy_name;
+ int t;
+ int ret = 1;
+
+ dummy_name = make_temp_file (NULL);
+ for (t = 0; bfd_target_vector[t]; t++)
+ {
+ const bfd_target *p = bfd_target_vector[t];
+ bfd *abfd = bfd_openw (dummy_name, p->name);
+ int a;
+
+ printf ("%s\n (header %s, data %s)\n", p->name,
+ endian_string (p->header_byteorder),
+ endian_string (p->byteorder));
+
+ if (abfd == NULL)
+ {
+ bfd_nonfatal (dummy_name);
+ ret = 0;
+ continue;
+ }
+
+ if (! bfd_set_format (abfd, bfd_object))
+ {
+ if (bfd_get_error () != bfd_error_invalid_operation)
+ {
+ bfd_nonfatal (p->name);
+ ret = 0;
+ }
+ bfd_close_all_done (abfd);
+ continue;
+ }
+
+ for (a = (int) bfd_arch_obscure + 1; a < (int) bfd_arch_last; a++)
+ if (bfd_set_arch_mach (abfd, (enum bfd_architecture) a, 0))
+ printf (" %s\n",
+ bfd_printable_arch_mach ((enum bfd_architecture) a, 0));
+ bfd_close_all_done (abfd);
+ }
+ unlink (dummy_name);
+ free (dummy_name);
+
+ return ret;
+}
+
+/* Print a table showing which architectures are supported for entries
+ FIRST through LAST-1 of bfd_target_vector (targets across,
+ architectures down). */
+
+static int
+display_info_table (int first, int last)
+{
+ int t;
+ int a;
+ int ret = 1;
+ char *dummy_name;
+
+ /* Print heading of target names. */
+ printf ("\n%*s", (int) LONGEST_ARCH, " ");
+ for (t = first; t < last && bfd_target_vector[t]; t++)
+ printf ("%s ", bfd_target_vector[t]->name);
+ putchar ('\n');
+
+ dummy_name = make_temp_file (NULL);
+ for (a = (int) bfd_arch_obscure + 1; a < (int) bfd_arch_last; a++)
+ if (strcmp (bfd_printable_arch_mach (a, 0), "UNKNOWN!") != 0)
+ {
+ printf ("%*s ", (int) LONGEST_ARCH - 1,
+ bfd_printable_arch_mach (a, 0));
+ for (t = first; t < last && bfd_target_vector[t]; t++)
+ {
+ const bfd_target *p = bfd_target_vector[t];
+ bfd_boolean ok = TRUE;
+ bfd *abfd = bfd_openw (dummy_name, p->name);
+
+ if (abfd == NULL)
+ {
+ bfd_nonfatal (p->name);
+ ret = 0;
+ ok = FALSE;
+ }
+
+ if (ok)
+ {
+ if (! bfd_set_format (abfd, bfd_object))
+ {
+ if (bfd_get_error () != bfd_error_invalid_operation)
+ {
+ bfd_nonfatal (p->name);
+ ret = 0;
+ }
+ ok = FALSE;
+ }
+ }
+
+ if (ok)
+ {
+ if (! bfd_set_arch_mach (abfd, a, 0))
+ ok = FALSE;
+ }
+
+ if (ok)
+ printf ("%s ", p->name);
+ else
+ {
+ int l = strlen (p->name);
+ while (l--)
+ putchar ('-');
+ putchar (' ');
+ }
+ if (abfd != NULL)
+ bfd_close_all_done (abfd);
+ }
+ putchar ('\n');
+ }
+ unlink (dummy_name);
+ free (dummy_name);
+
+ return ret;
+}
+
+/* Print tables of all the target-architecture combinations that
+ BFD has been configured to support. */
+
+static int
+display_target_tables (void)
+{
+ int t;
+ int columns;
+ int ret = 1;
+ char *colum;
+
+ columns = 0;
+ colum = getenv ("COLUMNS");
+ if (colum != NULL)
+ columns = atoi (colum);
+ if (columns == 0)
+ columns = 80;
+
+ t = 0;
+ while (bfd_target_vector[t] != NULL)
+ {
+ int oldt = t, wid;
+
+ wid = LONGEST_ARCH + strlen (bfd_target_vector[t]->name) + 1;
+ ++t;
+ while (wid < columns && bfd_target_vector[t] != NULL)
+ {
+ int newwid;
+
+ newwid = wid + strlen (bfd_target_vector[t]->name) + 1;
+ if (newwid >= columns)
+ break;
+ wid = newwid;
+ ++t;
+ }
+ if (! display_info_table (oldt, t))
+ ret = 0;
+ }
+
+ return ret;
+}
+
+int
+display_info (void)
+{
+ printf (_("BFD header file version %s\n"), BFD_VERSION_STRING);
+ if (! display_target_list () || ! display_target_tables ())
+ return 1;
+ else
+ return 0;
+}
+
/* Display the archive header for an element as if it were an ls -l listing:
Mode User\tGroup\tSize\tDate Name */
void
-print_arelt_descr (file, abfd, verbose)
- FILE *file;
- bfd *abfd;
- boolean verbose;
+print_arelt_descr (FILE *file, bfd *abfd, bfd_boolean verbose)
{
struct stat buf;
@@ -200,8 +388,7 @@ print_arelt_descr (file, abfd, verbose)
/* Return the name of a temporary file in the same directory as FILENAME. */
char *
-make_tempname (filename)
- char *filename;
+make_tempname (char *filename)
{
static char template[] = "stXXXXXX";
char *tmpname;
@@ -251,9 +438,7 @@ make_tempname (filename)
parsed. */
bfd_vma
-parse_vma (s, arg)
- const char *s;
- const char *arg;
+parse_vma (const char *s, const char *arg)
{
bfd_vma ret;
const char *end;
@@ -265,3 +450,28 @@ parse_vma (s, arg)
return ret;
}
+
+/* Returns the size of the named file. If the file does not
+ exist, or if it is not a real file, then a suitable non-fatal
+ error message is printed and zero is returned. */
+
+off_t
+get_file_size (const char * file_name)
+{
+ struct stat statbuf;
+
+ if (stat (file_name, &statbuf) < 0)
+ {
+ if (errno == ENOENT)
+ non_fatal (_("'%s': No such file"), file_name);
+ else
+ non_fatal (_("Warning: could not locate '%s'. reason: %s"),
+ file_name, strerror (errno));
+ }
+ else if (! S_ISREG (statbuf.st_mode))
+ non_fatal (_("Warning: '%s' is not an ordinary file"), file_name);
+ else
+ return statbuf.st_size;
+
+ return 0;
+}
diff --git a/contrib/binutils/binutils/bucomm.h b/contrib/binutils/binutils/bucomm.h
index 0c98a7f..f604053 100644
--- a/contrib/binutils/binutils/bucomm.h
+++ b/contrib/binutils/binutils/bucomm.h
@@ -1,22 +1,22 @@
/* bucomm.h -- binutils common include file.
- Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000
- Free Software Foundation, Inc.
+ Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
+ 2002, 2003 Free Software Foundation, Inc.
-This file is part of GNU Binutils.
+ This file is part of GNU Binutils.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef _BUCOMM_H
#define _BUCOMM_H
@@ -148,46 +148,50 @@ void *alloca ();
#endif
/* bucomm.c */
-void bfd_nonfatal PARAMS ((const char *));
+void bfd_nonfatal (const char *);
-void bfd_fatal PARAMS ((const char *)) ATTRIBUTE_NORETURN;
+void bfd_fatal (const char *) ATTRIBUTE_NORETURN;
-void report PARAMS ((const char *, va_list));
+void report (const char *, va_list);
-void fatal PARAMS ((const char *, ...)) ATTRIBUTE_PRINTF_1 ATTRIBUTE_NORETURN;
+void fatal (const char *, ...) ATTRIBUTE_PRINTF_1 ATTRIBUTE_NORETURN;
-void non_fatal PARAMS ((const char *, ...)) ATTRIBUTE_PRINTF_1;
+void non_fatal (const char *, ...) ATTRIBUTE_PRINTF_1;
-void set_default_bfd_target PARAMS ((void));
+void set_default_bfd_target (void);
-void list_matching_formats PARAMS ((char **p));
+void list_matching_formats (char **);
-void list_supported_targets PARAMS ((const char *, FILE *));
+void list_supported_targets (const char *, FILE *);
-void list_supported_architectures PARAMS ((const char *, FILE *));
+void list_supported_architectures (const char *, FILE *);
-void print_arelt_descr PARAMS ((FILE *file, bfd *abfd, boolean verbose));
+int display_info (void);
-char *make_tempname PARAMS ((char *));
+void print_arelt_descr (FILE *, bfd *, bfd_boolean);
-bfd_vma parse_vma PARAMS ((const char *, const char *));
+char *make_tempname (char *);
+
+bfd_vma parse_vma (const char *, const char *);
+
+off_t get_file_size (const char *);
extern char *program_name;
/* filemode.c */
-void mode_string PARAMS ((unsigned long mode, char *buf));
+void mode_string (unsigned long, char *);
/* version.c */
-extern void print_version PARAMS ((const char *));
+extern void print_version (const char *);
/* rename.c */
-extern void set_times PARAMS ((const char *, const struct stat *));
+extern void set_times (const char *, const struct stat *);
-extern int smart_rename PARAMS ((const char *, const char *, int));
+extern int smart_rename (const char *, const char *, int);
-/* libiberty */
-PTR xmalloc PARAMS ((size_t));
+/* libiberty. */
+void *xmalloc (size_t);
-PTR xrealloc PARAMS ((PTR, size_t));
+void *xrealloc (void *, size_t);
#endif /* _BUCOMM_H */
diff --git a/contrib/binutils/binutils/budbg.h b/contrib/binutils/binutils/budbg.h
index 2bbf72e..f5c03bd 100644
--- a/contrib/binutils/binutils/budbg.h
+++ b/contrib/binutils/binutils/budbg.h
@@ -1,5 +1,5 @@
/* budbg.c -- Interfaces to the generic debugging information routines.
- Copyright 1995, 1996 Free Software Foundation, Inc.
+ Copyright 1995, 1996, 2002, 2003 Free Software Foundation, Inc.
Written by Ian Lance Taylor <ian@cygnus.com>.
This file is part of GNU Binutils.
@@ -26,33 +26,33 @@
/* Routine used to read generic debugging information. */
-extern PTR read_debugging_info PARAMS ((bfd *, asymbol **, long));
+extern void *read_debugging_info (bfd *, asymbol **, long);
/* Routine used to print generic debugging information. */
-extern boolean print_debugging_info PARAMS ((FILE *, PTR));
+extern bfd_boolean print_debugging_info
+ (FILE *, void *, bfd *, asymbol **, void *, bfd_boolean);
/* Routines used to read and write stabs information. */
-extern PTR start_stab PARAMS ((PTR, bfd *, boolean, asymbol **, long));
+extern void *start_stab (void *, bfd *, bfd_boolean, asymbol **, long);
-extern boolean finish_stab PARAMS ((PTR, PTR));
+extern bfd_boolean finish_stab (void *, void *);
-extern boolean parse_stab PARAMS ((PTR, PTR, int, int, bfd_vma, const char *));
+extern bfd_boolean parse_stab
+ (void *, void *, int, int, bfd_vma, const char *);
-extern boolean write_stabs_in_sections_debugging_info
- PARAMS ((bfd *, PTR, bfd_byte **, bfd_size_type *, bfd_byte **,
- bfd_size_type *));
+extern bfd_boolean write_stabs_in_sections_debugging_info
+ (bfd *, void *, bfd_byte **, bfd_size_type *, bfd_byte **, bfd_size_type *);
/* Routines used to read and write IEEE debugging information. */
-extern boolean parse_ieee
- PARAMS ((PTR, bfd *, const bfd_byte *, bfd_size_type));
+extern bfd_boolean parse_ieee (void *, bfd *, const bfd_byte *, bfd_size_type);
-extern boolean write_ieee_debugging_info PARAMS ((bfd *, PTR));
+extern bfd_boolean write_ieee_debugging_info (bfd *, void *);
/* Routine used to read COFF debugging information. */
-extern boolean parse_coff PARAMS ((bfd *, asymbol **, long, PTR));
+extern bfd_boolean parse_coff (bfd *, asymbol **, long, void *);
#endif
diff --git a/contrib/binutils/binutils/budemang.c b/contrib/binutils/binutils/budemang.c
index 3f8d385..525a1c8 100644
--- a/contrib/binutils/binutils/budemang.c
+++ b/contrib/binutils/binutils/budemang.c
@@ -1,5 +1,5 @@
/* demangle.c -- A wrapper calling libiberty cplus_demangle
- Copyright 2002 Free Software Foundation, Inc.
+ Copyright 2002, 2003 Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -36,9 +36,7 @@
other such chars that would otherwise confuse the demangler. */
char *
-demangle (abfd, name)
- bfd *abfd;
- const char *name;
+demangle (bfd *abfd, const char *name)
{
char *res;
const char *p;
diff --git a/contrib/binutils/binutils/budemang.h b/contrib/binutils/binutils/budemang.h
index 60a3c2d..b837d71 100644
--- a/contrib/binutils/binutils/budemang.h
+++ b/contrib/binutils/binutils/budemang.h
@@ -1,5 +1,5 @@
/* demangle.h -- A wrapper calling libiberty cplus_demangle
- Copyright 2002 Free Software Foundation, Inc.
+ Copyright 2002, 2003 Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -20,6 +20,6 @@
#ifndef BUDEMANG_H
#define BUDEMANG_H
-char *demangle PARAMS ((bfd *, const char *));
+char *demangle (bfd *, const char *);
#endif
diff --git a/contrib/binutils/binutils/coffdump.c b/contrib/binutils/binutils/coffdump.c
index 8f538e8..039b955 100644
--- a/contrib/binutils/binutils/coffdump.c
+++ b/contrib/binutils/binutils/coffdump.c
@@ -1,5 +1,5 @@
/* Coff file dumper.
- Copyright 1994, 1995, 1998, 1999, 2000, 2001, 2002
+ Copyright 1994, 1995, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -32,23 +32,22 @@
static int atnl;
-static void tab PARAMS ((int));
-static void nl PARAMS ((void));
-static void dump_coff_lines PARAMS ((struct coff_line *));
-static void dump_coff_type PARAMS ((struct coff_type *));
-static void dump_coff_where PARAMS ((struct coff_where *));
-static void dump_coff_visible PARAMS ((struct coff_visible *));
-extern void dump_coff_symbol PARAMS ((struct coff_symbol *));
-static void dump_coff_scope PARAMS ((struct coff_scope *));
-static void dump_coff_sfile PARAMS ((struct coff_sfile *));
-static void dump_coff_section PARAMS ((struct coff_section *));
-extern void coff_dump PARAMS ((struct coff_ofile *));
-static void show_usage PARAMS ((FILE *, int));
-extern int main PARAMS ((int, char **));
+static void tab (int);
+static void nl (void);
+static void dump_coff_lines (struct coff_line *);
+static void dump_coff_type (struct coff_type *);
+static void dump_coff_where (struct coff_where *);
+static void dump_coff_visible (struct coff_visible *);
+extern void dump_coff_symbol (struct coff_symbol *);
+static void dump_coff_scope (struct coff_scope *);
+static void dump_coff_sfile (struct coff_sfile *);
+static void dump_coff_section (struct coff_section *);
+extern void coff_dump (struct coff_ofile *);
+static void show_usage (FILE *, int);
+extern int main (int, char **);
static void
-tab (x)
- int x;
+tab (int x)
{
static int indent;
int i;
@@ -91,14 +90,13 @@ tab (x)
}
static void
-nl ()
+nl (void)
{
atnl = 1;
}
static void
-dump_coff_lines (p)
- struct coff_line *p;
+dump_coff_lines (struct coff_line *p)
{
int i;
int online = 0;
@@ -124,8 +122,7 @@ dump_coff_lines (p)
}
static void
-dump_coff_type (p)
- struct coff_type *p;
+dump_coff_type (struct coff_type *p)
{
tab (1);
printf ("size %d ", p->size);
@@ -244,8 +241,7 @@ dump_coff_type (p)
}
static void
-dump_coff_where (p)
- struct coff_where *p;
+dump_coff_where (struct coff_where *p)
{
tab (1);
switch (p->where)
@@ -284,8 +280,7 @@ dump_coff_where (p)
}
static void
-dump_coff_visible (p)
- struct coff_visible *p;
+dump_coff_visible (struct coff_visible *p)
{
tab (1);
switch (p->type)
@@ -331,8 +326,7 @@ dump_coff_visible (p)
}
void
-dump_coff_symbol (p)
- struct coff_symbol *p;
+dump_coff_symbol (struct coff_symbol *p)
{
tab (1);
printf ("List of symbols");
@@ -365,8 +359,7 @@ dump_coff_symbol (p)
}
static void
-dump_coff_scope (p)
- struct coff_scope *p;
+dump_coff_scope (struct coff_scope *p)
{
if (p)
{
@@ -402,8 +395,7 @@ dump_coff_scope (p)
}
static void
-dump_coff_sfile (p)
- struct coff_sfile *p;
+dump_coff_sfile (struct coff_sfile *p)
{
tab (1);
printf ("List of source files");
@@ -421,8 +413,7 @@ dump_coff_sfile (p)
}
static void
-dump_coff_section(ptr)
- struct coff_section *ptr;
+dump_coff_section (struct coff_section *ptr)
{
int i;
@@ -446,8 +437,7 @@ dump_coff_section(ptr)
}
void
-coff_dump (ptr)
- struct coff_ofile *ptr;
+coff_dump (struct coff_ofile *ptr)
{
int i;
@@ -464,9 +454,7 @@ coff_dump (ptr)
char * program_name;
static void
-show_usage (file, status)
- FILE *file;
- int status;
+show_usage (FILE *file, int status)
{
fprintf (file, _("Usage: %s [option(s)] in-file\n"), program_name);
fprintf (file, _(" Print a human readable interpretation of a SYSROFF object file\n"));
@@ -482,9 +470,7 @@ show_usage (file, status)
}
int
-main (ac, av)
- int ac;
- char *av[];
+main (int ac, char **av)
{
bfd *abfd;
struct coff_ofile *tree;
diff --git a/contrib/binutils/binutils/coffgrok.c b/contrib/binutils/binutils/coffgrok.c
index 8cab8d5..b2ec98c 100644
--- a/contrib/binutils/binutils/coffgrok.c
+++ b/contrib/binutils/binutils/coffgrok.c
@@ -1,5 +1,5 @@
/* coffgrok.c
- Copyright 1994, 1995, 1997, 1998, 2000, 2001, 2002
+ Copyright 1994, 1995, 1997, 1998, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -56,30 +56,30 @@ static struct coff_ptr_struct *rawsyms;
static int rawcount;
static bfd *abfd;
-#define PTR_SIZE 4
-#define SHORT_SIZE 2
-#define INT_SIZE 4
-#define LONG_SIZE 4
-#define FLOAT_SIZE 4
-#define DOUBLE_SIZE 8
+#define PTR_SIZE 4
+#define SHORT_SIZE 2
+#define INT_SIZE 4
+#define LONG_SIZE 4
+#define FLOAT_SIZE 4
+#define DOUBLE_SIZE 8
#define INDEXOF(p) ((struct coff_ptr_struct *)(p)-(rawsyms))
-static struct coff_scope *empty_scope PARAMS ((void));
-static struct coff_symbol *empty_symbol PARAMS ((void));
-static void push_scope PARAMS ((int));
-static void pop_scope PARAMS ((void));
-static void do_sections_p1 PARAMS ((struct coff_ofile *));
-static void do_sections_p2 PARAMS ((struct coff_ofile *));
-static struct coff_where *do_where PARAMS ((int));
-static struct coff_line *do_lines PARAMS ((int, char *));
-static struct coff_type *do_type PARAMS ((int));
-static struct coff_visible *do_visible PARAMS ((int));
-static int do_define PARAMS ((int, struct coff_scope *));
-static struct coff_ofile *doit PARAMS ((void));
+static struct coff_scope *empty_scope (void);
+static struct coff_symbol *empty_symbol (void);
+static void push_scope (int);
+static void pop_scope (void);
+static void do_sections_p1 (struct coff_ofile *);
+static void do_sections_p2 (struct coff_ofile *);
+static struct coff_where *do_where (int);
+static struct coff_line *do_lines (int, char *);
+static struct coff_type *do_type (int);
+static struct coff_visible *do_visible (int);
+static int do_define (int, struct coff_scope *);
+static struct coff_ofile *doit (void);
static struct coff_scope *
-empty_scope ()
+empty_scope (void)
{
struct coff_scope *l;
l = (struct coff_scope *) (xcalloc (sizeof (struct coff_scope), 1));
@@ -87,15 +87,14 @@ empty_scope ()
}
static struct coff_symbol *
-empty_symbol ()
+empty_symbol (void)
{
return (struct coff_symbol *) (xcalloc (sizeof (struct coff_symbol), 1));
}
/*int l;*/
static void
-push_scope (link)
- int link;
+push_scope (int link)
{
struct coff_scope *n = empty_scope ();
if (link)
@@ -119,14 +118,13 @@ push_scope (link)
}
static void
-pop_scope ()
+pop_scope (void)
{
top_scope = top_scope->parent;
}
static void
-do_sections_p1 (head)
- struct coff_ofile *head;
+do_sections_p1 (struct coff_ofile *head)
{
asection *section;
int idx;
@@ -175,8 +173,7 @@ do_sections_p1 (head)
}
static void
-do_sections_p2 (head)
- struct coff_ofile *head;
+do_sections_p2 (struct coff_ofile *head)
{
asection *section;
for (section = abfd->sections; section; section = section->next)
@@ -198,8 +195,7 @@ do_sections_p2 (head)
}
static struct coff_where *
-do_where (i)
- int i;
+do_where (int i)
{
struct internal_syment *sym = &rawsyms[i].u.syment;
struct coff_where *where =
@@ -258,9 +254,7 @@ do_where (i)
static
struct coff_line *
-do_lines (i, name)
- int i;
- char *name ATTRIBUTE_UNUSED;
+do_lines (int i, char *name ATTRIBUTE_UNUSED)
{
struct coff_line *res = (struct coff_line *) xcalloc (sizeof (struct coff_line), 1);
asection *s;
@@ -307,8 +301,7 @@ do_lines (i, name)
static
struct coff_type *
-do_type (i)
- int i;
+do_type (int i)
{
struct internal_syment *sym = &rawsyms[i].u.syment;
union internal_auxent *aux = &rawsyms[i + 1].u.auxent;
@@ -377,7 +370,7 @@ do_type (i)
{
if (aux->x_sym.x_tagndx.p)
{
- /* Refering to a struct defined elsewhere */
+ /* Referring to a struct defined elsewhere */
res->type = coff_structref_type;
res->u.astructref.ref = tindex[INDEXOF (aux->x_sym.x_tagndx.p)];
res->size = res->u.astructref.ref ?
@@ -396,7 +389,7 @@ do_type (i)
}
else
{
- /* No auxents - it's anonynmous */
+ /* No auxents - it's anonymous */
res->type = coff_structref_type;
res->u.astructref.ref = 0;
res->size = 0;
@@ -405,7 +398,7 @@ do_type (i)
case T_ENUM:
if (aux->x_sym.x_tagndx.p)
{
- /* Refering to a enum defined elsewhere */
+ /* Referring to a enum defined elsewhere */
res->type = coff_enumref_type;
res->u.aenumref.ref = tindex[INDEXOF (aux->x_sym.x_tagndx.p)];
res->size = res->u.aenumref.ref->type->size;
@@ -474,8 +467,7 @@ do_type (i)
}
static struct coff_visible *
-do_visible (i)
- int i;
+do_visible (int i)
{
struct internal_syment *sym = &rawsyms[i].u.syment;
struct coff_visible *visible =
@@ -539,9 +531,7 @@ do_visible (i)
}
static int
-do_define (i, b)
- int i;
- struct coff_scope *b;
+do_define (int i, struct coff_scope *b)
{
static int symbol_index;
struct internal_syment *sym = &rawsyms[i].u.syment;
@@ -601,7 +591,7 @@ do_define (i, b)
static
struct coff_ofile *
-doit ()
+doit (void)
{
int i;
int infile = 0;
@@ -728,8 +718,7 @@ doit ()
}
struct coff_ofile *
-coff_grok (inabfd)
- bfd *inabfd;
+coff_grok (bfd *inabfd)
{
long storage;
struct coff_ofile *p;
diff --git a/contrib/binutils/binutils/coffgrok.h b/contrib/binutils/binutils/coffgrok.h
index d071d24..c063f1d 100644
--- a/contrib/binutils/binutils/coffgrok.h
+++ b/contrib/binutils/binutils/coffgrok.h
@@ -53,7 +53,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
int nrelocs;
int size;
struct coff_reloc *relocs;
- struct sec *bfd_section;
+ struct bfd_section *bfd_section;
};
struct coff_ofile
diff --git a/contrib/binutils/binutils/config.in b/contrib/binutils/binutils/config.in
index d404762..f2bd049 100644
--- a/contrib/binutils/binutils/config.in
+++ b/contrib/binutils/binutils/config.in
@@ -28,9 +28,6 @@
/* Define to `long' if <sys/types.h> doesn't define. */
#undef off_t
-/* Define if you need to in order for stat and other things to work. */
-#undef _POSIX_SOURCE
-
/* Define to `unsigned' if <sys/types.h> doesn't define. */
#undef size_t
@@ -136,12 +133,6 @@
/* Define if you have the <sys/param.h> header file. */
#undef HAVE_SYS_PARAM_H
-/* Define if you have the <sys/stat.h> header file. */
-#undef HAVE_SYS_STAT_H
-
-/* Define if you have the <sys/types.h> header file. */
-#undef HAVE_SYS_TYPES_H
-
/* Define if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
@@ -208,3 +199,6 @@
/* Configured target name. */
#undef TARGET
+/* Define to 1 if user symbol names have a leading underscore, 0 if not. */
+#undef TARGET_PREPENDS_UNDERSCORE
+
diff --git a/contrib/binutils/binutils/configure b/contrib/binutils/binutils/configure
index 7c163c9..8210910 100755
--- a/contrib/binutils/binutils/configure
+++ b/contrib/binutils/binutils/configure
@@ -53,6 +53,7 @@ program_suffix=NONE
program_transform_name=s,x,x,
silent=
site=
+sitefile=
srcdir=
target=NONE
verbose=
@@ -167,6 +168,7 @@ Configuration:
--help print this message
--no-create do not create output files
--quiet, --silent do not print \`checking...' messages
+ --site-file=FILE use FILE as the site file
--version print the version of autoconf that created configure
Directory and file names:
--prefix=PREFIX install architecture-independent files in PREFIX
@@ -337,6 +339,11 @@ EOF
-site=* | --site=* | --sit=*)
site="$ac_optarg" ;;
+ -site-file | --site-file | --site-fil | --site-fi | --site-f)
+ ac_prev=sitefile ;;
+ -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
+ sitefile="$ac_optarg" ;;
+
-srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
ac_prev=srcdir ;;
-srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
@@ -502,12 +509,16 @@ fi
srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
# Prefer explicitly selected file to automatically selected ones.
-if test -z "$CONFIG_SITE"; then
- if test "x$prefix" != xNONE; then
- CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
- else
- CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
+if test -z "$sitefile"; then
+ if test -z "$CONFIG_SITE"; then
+ if test "x$prefix" != xNONE; then
+ CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
+ else
+ CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
+ fi
fi
+else
+ CONFIG_SITE="$sitefile"
fi
for ac_site_file in $CONFIG_SITE; do
if test -r "$ac_site_file"; then
@@ -546,12 +557,12 @@ else
fi
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:550: checking for Cygwin environment" >&5
+echo "configure:561: checking for Cygwin environment" >&5
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 555 "configure"
+#line 566 "configure"
#include "confdefs.h"
int main() {
@@ -562,7 +573,7 @@ int main() {
return __CYGWIN__;
; return 0; }
EOF
-if { (eval echo configure:566: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:577: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_cygwin=yes
else
@@ -579,19 +590,19 @@ echo "$ac_t""$ac_cv_cygwin" 1>&6
CYGWIN=
test "$ac_cv_cygwin" = yes && CYGWIN=yes
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:583: checking for mingw32 environment" >&5
+echo "configure:594: checking for mingw32 environment" >&5
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 588 "configure"
+#line 599 "configure"
#include "confdefs.h"
int main() {
return __MINGW32__;
; return 0; }
EOF
-if { (eval echo configure:595: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:606: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_mingw32=yes
else
@@ -656,7 +667,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:660: checking host system type" >&5
+echo "configure:671: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -677,7 +688,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:681: checking target system type" >&5
+echo "configure:692: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -695,7 +706,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:699: checking build system type" >&5
+echo "configure:710: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -717,249 +728,49 @@ test "$host_alias" != "$target_alias" &&
NONENONEs,x,x, &&
program_prefix=${target_alias}-
-# Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:724: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_CC="gcc"
- break
- fi
- done
- IFS="$ac_save_ifs"
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-if test -z "$CC"; then
- # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:754: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_prog_rejected=no
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
- ac_prog_rejected=yes
- continue
- fi
- ac_cv_prog_CC="cc"
- break
- fi
- done
- IFS="$ac_save_ifs"
-if test $ac_prog_rejected = yes; then
- # We found a bogon in the path, so make sure we never use it.
- set dummy $ac_cv_prog_CC
- shift
- if test $# -gt 0; then
- # We chose a different compiler from the bogus one.
- # However, it has the same basename, so the bogon will be chosen
- # first if we set CC to just the basename; use the full file name.
- shift
- set dummy "$ac_dir/$ac_word" "$@"
- shift
- ac_cv_prog_CC="$@"
- fi
-fi
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
- if test -z "$CC"; then
- case "`uname -s`" in
- *win32* | *WIN32*)
- # Extract the first word of "cl", so it can be a program name with args.
-set dummy cl; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:805: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+ echo $ac_n "checking for strerror in -lcposix""... $ac_c" 1>&6
+echo "configure:734: checking for strerror in -lcposix" >&5
+ac_lib_var=`echo cposix'_'strerror | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_CC="cl"
- break
- fi
- done
- IFS="$ac_save_ifs"
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
- ;;
- esac
- fi
- test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
-fi
-
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:837: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
-
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-cat > conftest.$ac_ext << EOF
-
-#line 848 "configure"
+ ac_save_LIBS="$LIBS"
+LIBS="-lcposix $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 742 "configure"
#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error. */
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char strerror();
-main(){return(0);}
+int main() {
+strerror()
+; return 0; }
EOF
-if { (eval echo configure:853: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- ac_cv_prog_cc_works=yes
- # If we can't run a trivial program, we are probably using a cross compiler.
- if (./conftest; exit) 2>/dev/null; then
- ac_cv_prog_cc_cross=no
- else
- ac_cv_prog_cc_cross=yes
- fi
+if { (eval echo configure:753: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ rm -rf conftest*
+ eval "ac_cv_lib_$ac_lib_var=yes"
else
echo "configure: failed program was:" >&5
cat conftest.$ac_ext >&5
- ac_cv_prog_cc_works=no
-fi
-rm -fr conftest*
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
-if test $ac_cv_prog_cc_works = no; then
- { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
-fi
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:879: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
-echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
-cross_compiling=$ac_cv_prog_cc_cross
-
-echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:884: checking whether we are using GNU C" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.c <<EOF
-#ifdef __GNUC__
- yes;
-#endif
-EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:893: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
- ac_cv_prog_gcc=yes
-else
- ac_cv_prog_gcc=no
-fi
-fi
-
-echo "$ac_t""$ac_cv_prog_gcc" 1>&6
-
-if test $ac_cv_prog_gcc = yes; then
- GCC=yes
-else
- GCC=
-fi
-
-ac_test_CFLAGS="${CFLAGS+set}"
-ac_save_CFLAGS="$CFLAGS"
-CFLAGS=
-echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:912: checking whether ${CC-cc} accepts -g" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- echo 'void f(){}' > conftest.c
-if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
- ac_cv_prog_cc_g=yes
-else
- ac_cv_prog_cc_g=no
+ rm -rf conftest*
+ eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
+LIBS="$ac_save_LIBS"
fi
-
-echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
-if test "$ac_test_CFLAGS" = set; then
- CFLAGS="$ac_save_CFLAGS"
-elif test $ac_cv_prog_cc_g = yes; then
- if test "$GCC" = yes; then
- CFLAGS="-g -O2"
- else
- CFLAGS="-g"
- fi
-else
- if test "$GCC" = yes; then
- CFLAGS="-O2"
- else
- CFLAGS=
- fi
-fi
-
-echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
-echo "configure:944: checking for POSIXized ISC" >&5
-if test -d /etc/conf/kconfig.d &&
- grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
-then
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
- ISC=yes # If later tests want to check for ISC.
- cat >> confdefs.h <<\EOF
-#define _POSIX_SOURCE 1
-EOF
-
- if test "$GCC" = yes; then
- CC="$CC -posix"
- else
- CC="$CC -Xp"
- fi
+ LIBS="$LIBS -lcposix"
else
echo "$ac_t""no" 1>&6
- ISC=
fi
+
+
BFD_VERSION=`sed -n -e 's/^.._INIT_AUTOMAKE.*,[ ]*\([^ ]*\)[ ]*).*/\1/p' < ${srcdir}/../bfd/configure.in`
# Find a good install program. We prefer a C program (faster),
@@ -974,7 +785,7 @@ BFD_VERSION=`sed -n -e 's/^.._INIT_AUTOMAKE.*,[ ]*\([^ ]*\)[ ]*).*/\1/p' < ${
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:978: checking for a BSD compatible install" >&5
+echo "configure:789: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1027,7 +838,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:1031: checking whether build environment is sane" >&5
+echo "configure:842: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -1084,7 +895,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:1088: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:899: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1130,7 +941,7 @@ EOF
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:1134: checking for working aclocal" >&5
+echo "configure:945: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1143,7 +954,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:1147: checking for working autoconf" >&5
+echo "configure:958: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1156,7 +967,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:1160: checking for working automake" >&5
+echo "configure:971: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1169,7 +980,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:1173: checking for working autoheader" >&5
+echo "configure:984: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1182,7 +993,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:1186: checking for working makeinfo" >&5
+echo "configure:997: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1265,6 +1076,228 @@ else
enable_fast_install=yes
fi
+# Extract the first word of "gcc", so it can be a program name with args.
+set dummy gcc; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:1083: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$CC"; then
+ ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_CC="gcc"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+CC="$ac_cv_prog_CC"
+if test -n "$CC"; then
+ echo "$ac_t""$CC" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+if test -z "$CC"; then
+ # Extract the first word of "cc", so it can be a program name with args.
+set dummy cc; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:1113: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$CC"; then
+ ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_prog_rejected=no
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
+ ac_prog_rejected=yes
+ continue
+ fi
+ ac_cv_prog_CC="cc"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+if test $ac_prog_rejected = yes; then
+ # We found a bogon in the path, so make sure we never use it.
+ set dummy $ac_cv_prog_CC
+ shift
+ if test $# -gt 0; then
+ # We chose a different compiler from the bogus one.
+ # However, it has the same basename, so the bogon will be chosen
+ # first if we set CC to just the basename; use the full file name.
+ shift
+ set dummy "$ac_dir/$ac_word" "$@"
+ shift
+ ac_cv_prog_CC="$@"
+ fi
+fi
+fi
+fi
+CC="$ac_cv_prog_CC"
+if test -n "$CC"; then
+ echo "$ac_t""$CC" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ if test -z "$CC"; then
+ case "`uname -s`" in
+ *win32* | *WIN32*)
+ # Extract the first word of "cl", so it can be a program name with args.
+set dummy cl; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:1164: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$CC"; then
+ ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_CC="cl"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+CC="$ac_cv_prog_CC"
+if test -n "$CC"; then
+ echo "$ac_t""$CC" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+ ;;
+ esac
+ fi
+ test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
+fi
+
+echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
+echo "configure:1196: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+
+ac_ext=c
+# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
+ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
+cross_compiling=$ac_cv_prog_cc_cross
+
+cat > conftest.$ac_ext << EOF
+
+#line 1207 "configure"
+#include "confdefs.h"
+
+main(){return(0);}
+EOF
+if { (eval echo configure:1212: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ ac_cv_prog_cc_works=yes
+ # If we can't run a trivial program, we are probably using a cross compiler.
+ if (./conftest; exit) 2>/dev/null; then
+ ac_cv_prog_cc_cross=no
+ else
+ ac_cv_prog_cc_cross=yes
+ fi
+else
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+ ac_cv_prog_cc_works=no
+fi
+rm -fr conftest*
+ac_ext=c
+# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
+ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
+cross_compiling=$ac_cv_prog_cc_cross
+
+echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
+if test $ac_cv_prog_cc_works = no; then
+ { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
+fi
+echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
+echo "configure:1238: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
+cross_compiling=$ac_cv_prog_cc_cross
+
+echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
+echo "configure:1243: checking whether we are using GNU C" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ cat > conftest.c <<EOF
+#ifdef __GNUC__
+ yes;
+#endif
+EOF
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1252: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+ ac_cv_prog_gcc=yes
+else
+ ac_cv_prog_gcc=no
+fi
+fi
+
+echo "$ac_t""$ac_cv_prog_gcc" 1>&6
+
+if test $ac_cv_prog_gcc = yes; then
+ GCC=yes
+else
+ GCC=
+fi
+
+ac_test_CFLAGS="${CFLAGS+set}"
+ac_save_CFLAGS="$CFLAGS"
+CFLAGS=
+echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
+echo "configure:1271: checking whether ${CC-cc} accepts -g" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ echo 'void f(){}' > conftest.c
+if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
+ ac_cv_prog_cc_g=yes
+else
+ ac_cv_prog_cc_g=no
+fi
+rm -f conftest*
+
+fi
+
+echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
+if test "$ac_test_CFLAGS" = set; then
+ CFLAGS="$ac_save_CFLAGS"
+elif test $ac_cv_prog_cc_g = yes; then
+ if test "$GCC" = yes; then
+ CFLAGS="-g -O2"
+ else
+ CFLAGS="-g"
+ fi
+else
+ if test "$GCC" = yes; then
+ CFLAGS="-O2"
+ else
+ CFLAGS=
+ fi
+fi
+
# Check whether --with-gnu-ld or --without-gnu-ld was given.
if test "${with_gnu_ld+set}" = set; then
withval="$with_gnu_ld"
@@ -1277,7 +1310,7 @@ ac_prog=ld
if test "$GCC" = yes; then
# Check if gcc -print-prog-name=ld gives a path.
echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
-echo "configure:1281: checking for ld used by GCC" >&5
+echo "configure:1314: checking for ld used by GCC" >&5
case $host in
*-*-mingw*)
# gcc leaves a trailing carriage return which upsets mingw
@@ -1307,10 +1340,10 @@ echo "configure:1281: checking for ld used by GCC" >&5
esac
elif test "$with_gnu_ld" = yes; then
echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
-echo "configure:1311: checking for GNU ld" >&5
+echo "configure:1344: checking for GNU ld" >&5
else
echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
-echo "configure:1314: checking for non-GNU ld" >&5
+echo "configure:1347: checking for non-GNU ld" >&5
fi
if eval "test \"`echo '$''{'lt_cv_path_LD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1345,7 +1378,7 @@ else
fi
test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
-echo "configure:1349: checking if the linker ($LD) is GNU ld" >&5
+echo "configure:1382: checking if the linker ($LD) is GNU ld" >&5
if eval "test \"`echo '$''{'lt_cv_prog_gnu_ld'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1362,7 +1395,7 @@ with_gnu_ld=$lt_cv_prog_gnu_ld
echo $ac_n "checking for $LD option to reload object files""... $ac_c" 1>&6
-echo "configure:1366: checking for $LD option to reload object files" >&5
+echo "configure:1399: checking for $LD option to reload object files" >&5
if eval "test \"`echo '$''{'lt_cv_ld_reload_flag'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1374,7 +1407,7 @@ reload_flag=$lt_cv_ld_reload_flag
test -n "$reload_flag" && reload_flag=" $reload_flag"
echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
-echo "configure:1378: checking for BSD-compatible nm" >&5
+echo "configure:1411: checking for BSD-compatible nm" >&5
if eval "test \"`echo '$''{'lt_cv_path_NM'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1412,7 +1445,7 @@ NM="$lt_cv_path_NM"
echo "$ac_t""$NM" 1>&6
echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:1416: checking whether ln -s works" >&5
+echo "configure:1449: checking whether ln -s works" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1433,7 +1466,7 @@ else
fi
echo $ac_n "checking how to recognise dependant libraries""... $ac_c" 1>&6
-echo "configure:1437: checking how to recognise dependant libraries" >&5
+echo "configure:1470: checking how to recognise dependant libraries" >&5
if eval "test \"`echo '$''{'lt_cv_deplibs_check_method'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1543,7 +1576,7 @@ irix5* | irix6*)
# This must be Linux ELF.
linux-gnu*)
case $host_cpu in
- alpha* | hppa* | i*86 | powerpc* | sparc* | ia64* )
+ alpha* | mips* | hppa* | i*86 | powerpc* | sparc* | ia64* )
lt_cv_deplibs_check_method=pass_all ;;
*)
# glibc up to 2.1.1 does not perform some relocations on ARM
@@ -1606,13 +1639,13 @@ file_magic_cmd=$lt_cv_file_magic_cmd
deplibs_check_method=$lt_cv_deplibs_check_method
echo $ac_n "checking for object suffix""... $ac_c" 1>&6
-echo "configure:1610: checking for object suffix" >&5
+echo "configure:1643: checking for object suffix" >&5
if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
rm -f conftest*
echo 'int i = 1;' > conftest.$ac_ext
-if { (eval echo configure:1616: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1649: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
for ac_file in conftest.*; do
case $ac_file in
*.c) ;;
@@ -1632,7 +1665,7 @@ ac_objext=$ac_cv_objext
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:1636: checking for executable suffix" >&5
+echo "configure:1669: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1642,10 +1675,10 @@ else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:1646: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:1679: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
- *.c | *.o | *.obj) ;;
+ *.c | *.o | *.obj | *.ilk | *.pdb) ;;
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
esac
done
@@ -1675,7 +1708,7 @@ case $deplibs_check_method in
file_magic*)
if test "$file_magic_cmd" = '$MAGIC_CMD'; then
echo $ac_n "checking for ${ac_tool_prefix}file""... $ac_c" 1>&6
-echo "configure:1679: checking for ${ac_tool_prefix}file" >&5
+echo "configure:1712: checking for ${ac_tool_prefix}file" >&5
if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1737,7 +1770,7 @@ fi
if test -z "$lt_cv_path_MAGIC_CMD"; then
if test -n "$ac_tool_prefix"; then
echo $ac_n "checking for file""... $ac_c" 1>&6
-echo "configure:1741: checking for file" >&5
+echo "configure:1774: checking for file" >&5
if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1808,7 +1841,7 @@ esac
# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1812: checking for $ac_word" >&5
+echo "configure:1845: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1840,7 +1873,7 @@ if test -n "$ac_tool_prefix"; then
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1844: checking for $ac_word" >&5
+echo "configure:1877: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1875,7 +1908,7 @@ fi
# Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
set dummy ${ac_tool_prefix}strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1879: checking for $ac_word" >&5
+echo "configure:1912: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1907,7 +1940,7 @@ if test -n "$ac_tool_prefix"; then
# Extract the first word of "strip", so it can be a program name with args.
set dummy strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1911: checking for $ac_word" >&5
+echo "configure:1944: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1974,8 +2007,21 @@ test x"$pic_mode" = xno && libtool_flags="$libtool_flags --prefer-non-pic"
case $host in
*-*-irix6*)
# Find out which ABI we are using.
- echo '#line 1978 "configure"' > conftest.$ac_ext
- if { (eval echo configure:1979: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ echo '#line 2011 "configure"' > conftest.$ac_ext
+ if { (eval echo configure:2012: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ if test "$lt_cv_prog_gnu_ld" = yes; then
+ case `/usr/bin/file conftest.$ac_objext` in
+ *32-bit*)
+ LD="${LD-ld} -melf32bsmip"
+ ;;
+ *N32*)
+ LD="${LD-ld} -melf32bmipn32"
+ ;;
+ *64-bit*)
+ LD="${LD-ld} -melf64bmip"
+ ;;
+ esac
+ else
case `/usr/bin/file conftest.$ac_objext` in
*32-bit*)
LD="${LD-ld} -32"
@@ -1987,6 +2033,7 @@ case $host in
LD="${LD-ld} -64"
;;
esac
+ fi
fi
rm -rf conftest*
;;
@@ -1994,7 +2041,7 @@ case $host in
ia64-*-hpux*)
# Find out which ABI we are using.
echo 'int i;' > conftest.$ac_ext
- if { (eval echo configure:1998: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ if { (eval echo configure:2045: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
case "`/usr/bin/file conftest.o`" in
*ELF-32*)
HPUX_IA64_MODE="32"
@@ -2012,7 +2059,7 @@ ia64-*-hpux*)
SAVE_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -belf"
echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
-echo "configure:2016: checking whether the C compiler needs -belf" >&5
+echo "configure:2063: checking whether the C compiler needs -belf" >&5
if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2025,14 +2072,14 @@ ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$a
cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext <<EOF
-#line 2029 "configure"
+#line 2076 "configure"
#include "confdefs.h"
int main() {
; return 0; }
EOF
-if { (eval echo configure:2036: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2083: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
lt_cv_cc_needs_belf=yes
else
@@ -2205,7 +2252,7 @@ fi
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2209: checking for $ac_word" >&5
+echo "configure:2256: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2235,7 +2282,7 @@ if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2239: checking for $ac_word" >&5
+echo "configure:2286: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2286,7 +2333,7 @@ fi
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2290: checking for $ac_word" >&5
+echo "configure:2337: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2318,7 +2365,7 @@ fi
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:2322: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:2369: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -2329,12 +2376,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 2333 "configure"
+#line 2380 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:2338: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2385: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -2360,12 +2407,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:2364: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:2411: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:2369: checking whether we are using GNU C" >&5
+echo "configure:2416: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2374,7 +2421,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2378: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2425: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -2393,7 +2440,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:2397: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:2444: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2430,7 +2477,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2434: checking for $ac_word" >&5
+echo "configure:2481: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2461,7 +2508,7 @@ done
test -n "$YACC" || YACC="yacc"
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:2465: checking how to run the C preprocessor" >&5
+echo "configure:2512: checking how to run the C preprocessor" >&5
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
@@ -2476,13 +2523,13 @@ else
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp.
cat > conftest.$ac_ext <<EOF
-#line 2480 "configure"
+#line 2527 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2486: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2533: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -2493,13 +2540,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF
-#line 2497 "configure"
+#line 2544 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2503: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2550: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -2510,13 +2557,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -nologo -E"
cat > conftest.$ac_ext <<EOF
-#line 2514 "configure"
+#line 2561 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2520: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2567: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -2546,7 +2593,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2550: checking for $ac_word" >&5
+echo "configure:2597: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2579,7 +2626,7 @@ test -n "$LEX" || LEX="$missing_dir/missing flex"
# Extract the first word of "flex", so it can be a program name with args.
set dummy flex; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2583: checking for $ac_word" >&5
+echo "configure:2630: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2613,7 +2660,7 @@ then
*) ac_lib=l ;;
esac
echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6
-echo "configure:2617: checking for yywrap in -l$ac_lib" >&5
+echo "configure:2664: checking for yywrap in -l$ac_lib" >&5
ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -2621,7 +2668,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-l$ac_lib $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2625 "configure"
+#line 2672 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -2632,7 +2679,7 @@ int main() {
yywrap()
; return 0; }
EOF
-if { (eval echo configure:2636: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2683: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -2655,7 +2702,7 @@ fi
fi
echo $ac_n "checking lex output file root""... $ac_c" 1>&6
-echo "configure:2659: checking lex output file root" >&5
+echo "configure:2706: checking lex output file root" >&5
if eval "test \"`echo '$''{'ac_cv_prog_lex_root'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2676,7 +2723,7 @@ echo "$ac_t""$ac_cv_prog_lex_root" 1>&6
LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
echo $ac_n "checking whether yytext is a pointer""... $ac_c" 1>&6
-echo "configure:2680: checking whether yytext is a pointer" >&5
+echo "configure:2727: checking whether yytext is a pointer" >&5
if eval "test \"`echo '$''{'ac_cv_prog_lex_yytext_pointer'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2688,14 +2735,14 @@ echo 'extern char *yytext;' >>$LEX_OUTPUT_ROOT.c
ac_save_LIBS="$LIBS"
LIBS="$LIBS $LEXLIB"
cat > conftest.$ac_ext <<EOF
-#line 2692 "configure"
+#line 2739 "configure"
#include "confdefs.h"
`cat $LEX_OUTPUT_ROOT.c`
int main() {
; return 0; }
EOF
-if { (eval echo configure:2699: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2746: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_prog_lex_yytext_pointer=yes
else
@@ -2717,11 +2764,11 @@ EOF
fi
-ALL_LINGUAS="fr tr ja es sv da"
+ALL_LINGUAS="fr tr ja es sv da zh_CN ru"
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2725: checking for $ac_word" >&5
+echo "configure:2772: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2749,12 +2796,12 @@ else
fi
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:2753: checking for ANSI C header files" >&5
+echo "configure:2800: checking for ANSI C header files" >&5
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2758 "configure"
+#line 2805 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
@@ -2762,7 +2809,7 @@ else
#include <float.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2766: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2813: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -2779,7 +2826,7 @@ rm -f conftest*
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 2783 "configure"
+#line 2830 "configure"
#include "confdefs.h"
#include <string.h>
EOF
@@ -2797,7 +2844,7 @@ fi
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 2801 "configure"
+#line 2848 "configure"
#include "confdefs.h"
#include <stdlib.h>
EOF
@@ -2818,7 +2865,7 @@ if test "$cross_compiling" = yes; then
:
else
cat > conftest.$ac_ext <<EOF
-#line 2822 "configure"
+#line 2869 "configure"
#include "confdefs.h"
#include <ctype.h>
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -2829,7 +2876,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
exit (0); }
EOF
-if { (eval echo configure:2833: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2880: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
else
@@ -2853,12 +2900,12 @@ EOF
fi
echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:2857: checking for working const" >&5
+echo "configure:2904: checking for working const" >&5
if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2862 "configure"
+#line 2909 "configure"
#include "confdefs.h"
int main() {
@@ -2907,7 +2954,7 @@ ccp = (char const *const *) p;
; return 0; }
EOF
-if { (eval echo configure:2911: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2958: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_const=yes
else
@@ -2928,21 +2975,21 @@ EOF
fi
echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:2932: checking for inline" >&5
+echo "configure:2979: checking for inline" >&5
if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
cat > conftest.$ac_ext <<EOF
-#line 2939 "configure"
+#line 2986 "configure"
#include "confdefs.h"
int main() {
} $ac_kw foo() {
; return 0; }
EOF
-if { (eval echo configure:2946: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2993: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_inline=$ac_kw; break
else
@@ -2968,12 +3015,12 @@ EOF
esac
echo $ac_n "checking for off_t""... $ac_c" 1>&6
-echo "configure:2972: checking for off_t" >&5
+echo "configure:3019: checking for off_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2977 "configure"
+#line 3024 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -3001,12 +3048,12 @@ EOF
fi
echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:3005: checking for size_t" >&5
+echo "configure:3052: checking for size_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3010 "configure"
+#line 3057 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -3036,19 +3083,19 @@ fi
# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
# for constant arguments. Useless!
echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:3040: checking for working alloca.h" >&5
+echo "configure:3087: checking for working alloca.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3045 "configure"
+#line 3092 "configure"
#include "confdefs.h"
#include <alloca.h>
int main() {
char *p = alloca(2 * sizeof(int));
; return 0; }
EOF
-if { (eval echo configure:3052: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3099: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_header_alloca_h=yes
else
@@ -3069,12 +3116,12 @@ EOF
fi
echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:3073: checking for alloca" >&5
+echo "configure:3120: checking for alloca" >&5
if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3078 "configure"
+#line 3125 "configure"
#include "confdefs.h"
#ifdef __GNUC__
@@ -3102,7 +3149,7 @@ int main() {
char *p = (char *) alloca(1);
; return 0; }
EOF
-if { (eval echo configure:3106: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3153: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_func_alloca_works=yes
else
@@ -3134,12 +3181,12 @@ EOF
echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:3138: checking whether alloca needs Cray hooks" >&5
+echo "configure:3185: checking whether alloca needs Cray hooks" >&5
if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3143 "configure"
+#line 3190 "configure"
#include "confdefs.h"
#if defined(CRAY) && ! defined(CRAY2)
webecray
@@ -3164,12 +3211,12 @@ echo "$ac_t""$ac_cv_os_cray" 1>&6
if test $ac_cv_os_cray = yes; then
for ac_func in _getb67 GETB67 getb67; do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3168: checking for $ac_func" >&5
+echo "configure:3215: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3173 "configure"
+#line 3220 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3192,7 +3239,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3196: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3243: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3219,7 +3266,7 @@ done
fi
echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:3223: checking stack direction for C alloca" >&5
+echo "configure:3270: checking stack direction for C alloca" >&5
if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3227,7 +3274,7 @@ else
ac_cv_c_stack_direction=0
else
cat > conftest.$ac_ext <<EOF
-#line 3231 "configure"
+#line 3278 "configure"
#include "confdefs.h"
find_stack_direction ()
{
@@ -3246,7 +3293,7 @@ main ()
exit (find_stack_direction() < 0);
}
EOF
-if { (eval echo configure:3250: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3297: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_stack_direction=1
else
@@ -3267,21 +3314,21 @@ EOF
fi
-for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
+for ac_hdr in unistd.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3275: checking for $ac_hdr" >&5
+echo "configure:3322: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3280 "configure"
+#line 3327 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3285: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3332: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -3310,12 +3357,12 @@ done
for ac_func in getpagesize
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3314: checking for $ac_func" >&5
+echo "configure:3361: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3319 "configure"
+#line 3366 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3338,7 +3385,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3342: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3389: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3363,7 +3410,7 @@ fi
done
echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:3367: checking for working mmap" >&5
+echo "configure:3414: checking for working mmap" >&5
if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3371,7 +3418,7 @@ else
ac_cv_func_mmap_fixed_mapped=no
else
cat > conftest.$ac_ext <<EOF
-#line 3375 "configure"
+#line 3422 "configure"
#include "confdefs.h"
/* Thanks to Mike Haertel and Jim Avera for this test.
@@ -3399,24 +3446,11 @@ else
#include <fcntl.h>
#include <sys/mman.h>
-#if HAVE_SYS_TYPES_H
-# include <sys/types.h>
-#endif
-
-#if HAVE_STDLIB_H
-# include <stdlib.h>
-#endif
-
-#if HAVE_SYS_STAT_H
-# include <sys/stat.h>
-#endif
-
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
-
/* This mess was copied from the GNU getpagesize.h. */
#ifndef HAVE_GETPAGESIZE
+# ifdef HAVE_UNISTD_H
+# include <unistd.h>
+# endif
/* Assume that all systems that can run configure have sys/param.h. */
# ifndef HAVE_SYS_PARAM_H
@@ -3524,7 +3558,7 @@ main()
}
EOF
-if { (eval echo configure:3528: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3562: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_func_mmap_fixed_mapped=yes
else
@@ -3552,17 +3586,17 @@ unistd.h values.h sys/param.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3556: checking for $ac_hdr" >&5
+echo "configure:3590: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3561 "configure"
+#line 3595 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3566: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3600: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -3592,12 +3626,12 @@ done
__argz_count __argz_stringify __argz_next
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3596: checking for $ac_func" >&5
+echo "configure:3630: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3601 "configure"
+#line 3635 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3620,7 +3654,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3624: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3658: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3649,12 +3683,12 @@ done
for ac_func in stpcpy
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3653: checking for $ac_func" >&5
+echo "configure:3687: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3658 "configure"
+#line 3692 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3677,7 +3711,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3681: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3715: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3711,19 +3745,19 @@ EOF
if test $ac_cv_header_locale_h = yes; then
echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
-echo "configure:3715: checking for LC_MESSAGES" >&5
+echo "configure:3749: checking for LC_MESSAGES" >&5
if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3720 "configure"
+#line 3754 "configure"
#include "confdefs.h"
#include <locale.h>
int main() {
return LC_MESSAGES
; return 0; }
EOF
-if { (eval echo configure:3727: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3761: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
am_cv_val_LC_MESSAGES=yes
else
@@ -3744,7 +3778,7 @@ EOF
fi
fi
echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
-echo "configure:3748: checking whether NLS is requested" >&5
+echo "configure:3782: checking whether NLS is requested" >&5
# Check whether --enable-nls or --disable-nls was given.
if test "${enable_nls+set}" = set; then
enableval="$enable_nls"
@@ -3764,7 +3798,7 @@ fi
EOF
echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
-echo "configure:3768: checking whether included gettext is requested" >&5
+echo "configure:3802: checking whether included gettext is requested" >&5
# Check whether --with-included-gettext or --without-included-gettext was given.
if test "${with_included_gettext+set}" = set; then
withval="$with_included_gettext"
@@ -3783,17 +3817,17 @@ fi
ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
-echo "configure:3787: checking for libintl.h" >&5
+echo "configure:3821: checking for libintl.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3792 "configure"
+#line 3826 "configure"
#include "confdefs.h"
#include <libintl.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3797: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3831: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -3810,19 +3844,19 @@ fi
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
-echo "configure:3814: checking for gettext in libc" >&5
+echo "configure:3848: checking for gettext in libc" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3819 "configure"
+#line 3853 "configure"
#include "confdefs.h"
#include <libintl.h>
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:3826: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3860: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libc=yes
else
@@ -3838,7 +3872,7 @@ echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
if test "$gt_cv_func_gettext_libc" != "yes"; then
echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
-echo "configure:3842: checking for bindtextdomain in -lintl" >&5
+echo "configure:3876: checking for bindtextdomain in -lintl" >&5
ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -3846,7 +3880,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lintl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 3850 "configure"
+#line 3884 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -3857,7 +3891,7 @@ int main() {
bindtextdomain()
; return 0; }
EOF
-if { (eval echo configure:3861: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3895: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -3873,19 +3907,19 @@ fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
-echo "configure:3877: checking for gettext in libintl" >&5
+echo "configure:3911: checking for gettext in libintl" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3882 "configure"
+#line 3916 "configure"
#include "confdefs.h"
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:3889: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3923: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libintl=yes
else
@@ -3913,7 +3947,7 @@ EOF
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3917: checking for $ac_word" >&5
+echo "configure:3951: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3947,12 +3981,12 @@ fi
for ac_func in dcgettext
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3951: checking for $ac_func" >&5
+echo "configure:3985: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3956 "configure"
+#line 3990 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3975,7 +4009,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3979: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4013: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -4002,7 +4036,7 @@ done
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4006: checking for $ac_word" >&5
+echo "configure:4040: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4038,7 +4072,7 @@ fi
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4042: checking for $ac_word" >&5
+echo "configure:4076: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4070,7 +4104,7 @@ else
fi
cat > conftest.$ac_ext <<EOF
-#line 4074 "configure"
+#line 4108 "configure"
#include "confdefs.h"
int main() {
@@ -4078,7 +4112,7 @@ extern int _nl_msg_cat_cntr;
return _nl_msg_cat_cntr
; return 0; }
EOF
-if { (eval echo configure:4082: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4116: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
CATOBJEXT=.gmo
DATADIRNAME=share
@@ -4110,7 +4144,7 @@ fi
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4114: checking for $ac_word" >&5
+echo "configure:4148: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4144,7 +4178,7 @@ fi
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4148: checking for $ac_word" >&5
+echo "configure:4182: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4180,7 +4214,7 @@ fi
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4184: checking for $ac_word" >&5
+echo "configure:4218: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4270,7 +4304,7 @@ fi
LINGUAS=
else
echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
-echo "configure:4274: checking for catalogs to be installed" >&5
+echo "configure:4308: checking for catalogs to be installed" >&5
NEW_LINGUAS=
for lang in ${LINGUAS=$ALL_LINGUAS}; do
case "$ALL_LINGUAS" in
@@ -4298,17 +4332,17 @@ echo "configure:4274: checking for catalogs to be installed" >&5
if test "$CATOBJEXT" = ".cat"; then
ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
-echo "configure:4302: checking for linux/version.h" >&5
+echo "configure:4336: checking for linux/version.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4307 "configure"
+#line 4341 "configure"
#include "confdefs.h"
#include <linux/version.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4312: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4346: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -4371,7 +4405,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:4375: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:4409: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -4396,7 +4430,7 @@ fi
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:4400: checking for executable suffix" >&5
+echo "configure:4434: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4406,10 +4440,10 @@ else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:4410: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:4444: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
- *.c | *.o | *.obj) ;;
+ *.c | *.o | *.obj | *.ilk | *.pdb) ;;
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
esac
done
@@ -4449,7 +4483,7 @@ AR=${AR-ar}
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4453: checking for $ac_word" >&5
+echo "configure:4487: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4488,7 +4522,7 @@ fi
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:4492: checking for a BSD compatible install" >&5
+echo "configure:4526: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -4555,7 +4589,7 @@ if test "x$cross_compiling" = "xno"; then
EXEEXT_FOR_BUILD='$(EXEEXT)'
else
echo $ac_n "checking for build system executable suffix""... $ac_c" 1>&6
-echo "configure:4559: checking for build system executable suffix" >&5
+echo "configure:4593: checking for build system executable suffix" >&5
if eval "test \"`echo '$''{'bfd_cv_build_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4590,17 +4624,17 @@ for ac_hdr in string.h strings.h stdlib.h unistd.h fcntl.h sys/file.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:4594: checking for $ac_hdr" >&5
+echo "configure:4628: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4599 "configure"
+#line 4633 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4604: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4638: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -4627,12 +4661,12 @@ fi
done
echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6
-echo "configure:4631: checking for sys/wait.h that is POSIX.1 compatible" >&5
+echo "configure:4665: checking for sys/wait.h that is POSIX.1 compatible" >&5
if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4636 "configure"
+#line 4670 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/wait.h>
@@ -4648,7 +4682,7 @@ wait (&s);
s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
; return 0; }
EOF
-if { (eval echo configure:4652: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4686: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_header_sys_wait_h=yes
else
@@ -4671,19 +4705,19 @@ fi
# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
# for constant arguments. Useless!
echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:4675: checking for working alloca.h" >&5
+echo "configure:4709: checking for working alloca.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4680 "configure"
+#line 4714 "configure"
#include "confdefs.h"
#include <alloca.h>
int main() {
char *p = alloca(2 * sizeof(int));
; return 0; }
EOF
-if { (eval echo configure:4687: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4721: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_header_alloca_h=yes
else
@@ -4704,12 +4738,12 @@ EOF
fi
echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:4708: checking for alloca" >&5
+echo "configure:4742: checking for alloca" >&5
if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4713 "configure"
+#line 4747 "configure"
#include "confdefs.h"
#ifdef __GNUC__
@@ -4737,7 +4771,7 @@ int main() {
char *p = (char *) alloca(1);
; return 0; }
EOF
-if { (eval echo configure:4741: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4775: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_func_alloca_works=yes
else
@@ -4769,12 +4803,12 @@ EOF
echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:4773: checking whether alloca needs Cray hooks" >&5
+echo "configure:4807: checking whether alloca needs Cray hooks" >&5
if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4778 "configure"
+#line 4812 "configure"
#include "confdefs.h"
#if defined(CRAY) && ! defined(CRAY2)
webecray
@@ -4799,12 +4833,12 @@ echo "$ac_t""$ac_cv_os_cray" 1>&6
if test $ac_cv_os_cray = yes; then
for ac_func in _getb67 GETB67 getb67; do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:4803: checking for $ac_func" >&5
+echo "configure:4837: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4808 "configure"
+#line 4842 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -4827,7 +4861,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:4831: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4865: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -4854,7 +4888,7 @@ done
fi
echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:4858: checking stack direction for C alloca" >&5
+echo "configure:4892: checking stack direction for C alloca" >&5
if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4862,7 +4896,7 @@ else
ac_cv_c_stack_direction=0
else
cat > conftest.$ac_ext <<EOF
-#line 4866 "configure"
+#line 4900 "configure"
#include "confdefs.h"
find_stack_direction ()
{
@@ -4881,7 +4915,7 @@ main ()
exit (find_stack_direction() < 0);
}
EOF
-if { (eval echo configure:4885: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4919: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_stack_direction=1
else
@@ -4905,12 +4939,12 @@ fi
for ac_func in sbrk utimes setmode getc_unlocked strcoll
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:4909: checking for $ac_func" >&5
+echo "configure:4943: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4914 "configure"
+#line 4948 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -4933,7 +4967,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:4937: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4971: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -4961,19 +4995,19 @@ done
# Check whether fopen64 is available and whether _LARGEFILE64_SOURCE
# needs to be defined for it
echo $ac_n "checking for fopen64""... $ac_c" 1>&6
-echo "configure:4965: checking for fopen64" >&5
+echo "configure:4999: checking for fopen64" >&5
if eval "test \"`echo '$''{'bu_cv_have_fopen64'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4970 "configure"
+#line 5004 "configure"
#include "confdefs.h"
#include <stdio.h>
int main() {
FILE *f = fopen64 ("/tmp/foo","r");
; return 0; }
EOF
-if { (eval echo configure:4977: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5011: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
bu_cv_have_fopen64=yes
else
@@ -4983,14 +5017,14 @@ else
saved_CPPFLAGS=$CPPFLAGS
CPPFLAGS="$CPPFLAGS -D_LARGEFILE64_SOURCE"
cat > conftest.$ac_ext <<EOF
-#line 4987 "configure"
+#line 5021 "configure"
#include "confdefs.h"
#include <stdio.h>
int main() {
FILE *f = fopen64 ("/tmp/foo","r");
; return 0; }
EOF
-if { (eval echo configure:4994: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5028: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
bu_cv_have_fopen64="need -D_LARGEFILE64_SOURCE"
else
@@ -5022,14 +5056,14 @@ fi
# Some systems have frexp only in -lm, not in -lc.
echo $ac_n "checking for library containing frexp""... $ac_c" 1>&6
-echo "configure:5026: checking for library containing frexp" >&5
+echo "configure:5060: checking for library containing frexp" >&5
if eval "test \"`echo '$''{'ac_cv_search_frexp'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_func_search_save_LIBS="$LIBS"
ac_cv_search_frexp="no"
cat > conftest.$ac_ext <<EOF
-#line 5033 "configure"
+#line 5067 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -5040,7 +5074,7 @@ int main() {
frexp()
; return 0; }
EOF
-if { (eval echo configure:5044: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5078: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_search_frexp="none required"
else
@@ -5051,7 +5085,7 @@ rm -f conftest*
test "$ac_cv_search_frexp" = "no" && for i in m; do
LIBS="-l$i $ac_func_search_save_LIBS"
cat > conftest.$ac_ext <<EOF
-#line 5055 "configure"
+#line 5089 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -5062,7 +5096,7 @@ int main() {
frexp()
; return 0; }
EOF
-if { (eval echo configure:5066: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5100: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_search_frexp="-l$i"
break
@@ -5084,19 +5118,19 @@ else :
fi
echo $ac_n "checking for time_t in time.h""... $ac_c" 1>&6
-echo "configure:5088: checking for time_t in time.h" >&5
+echo "configure:5122: checking for time_t in time.h" >&5
if eval "test \"`echo '$''{'bu_cv_decl_time_t_time_h'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5093 "configure"
+#line 5127 "configure"
#include "confdefs.h"
#include <time.h>
int main() {
time_t i;
; return 0; }
EOF
-if { (eval echo configure:5100: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5134: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bu_cv_decl_time_t_time_h=yes
else
@@ -5117,19 +5151,19 @@ EOF
fi
echo $ac_n "checking for time_t in sys/types.h""... $ac_c" 1>&6
-echo "configure:5121: checking for time_t in sys/types.h" >&5
+echo "configure:5155: checking for time_t in sys/types.h" >&5
if eval "test \"`echo '$''{'bu_cv_decl_time_t_types_h'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5126 "configure"
+#line 5160 "configure"
#include "confdefs.h"
#include <sys/types.h>
int main() {
time_t i;
; return 0; }
EOF
-if { (eval echo configure:5133: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5167: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bu_cv_decl_time_t_types_h=yes
else
@@ -5152,12 +5186,12 @@ fi
# Under Next 3.2 <utime.h> apparently does not define struct utimbuf
# by default.
echo $ac_n "checking for utime.h""... $ac_c" 1>&6
-echo "configure:5156: checking for utime.h" >&5
+echo "configure:5190: checking for utime.h" >&5
if eval "test \"`echo '$''{'bu_cv_header_utime_h'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5161 "configure"
+#line 5195 "configure"
#include "confdefs.h"
#include <sys/types.h>
#ifdef HAVE_TIME_H
@@ -5168,7 +5202,7 @@ int main() {
struct utimbuf s;
; return 0; }
EOF
-if { (eval echo configure:5172: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5206: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bu_cv_header_utime_h=yes
else
@@ -5189,12 +5223,12 @@ EOF
fi
echo $ac_n "checking whether fprintf must be declared""... $ac_c" 1>&6
-echo "configure:5193: checking whether fprintf must be declared" >&5
+echo "configure:5227: checking whether fprintf must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_fprintf'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5198 "configure"
+#line 5232 "configure"
#include "confdefs.h"
#include <stdio.h>
@@ -5215,7 +5249,7 @@ int main() {
char *(*pfn) = (char *(*)) fprintf
; return 0; }
EOF
-if { (eval echo configure:5219: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5253: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_fprintf=no
else
@@ -5236,12 +5270,12 @@ EOF
fi
echo $ac_n "checking whether strstr must be declared""... $ac_c" 1>&6
-echo "configure:5240: checking whether strstr must be declared" >&5
+echo "configure:5274: checking whether strstr must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_strstr'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5245 "configure"
+#line 5279 "configure"
#include "confdefs.h"
#include <stdio.h>
@@ -5262,7 +5296,7 @@ int main() {
char *(*pfn) = (char *(*)) strstr
; return 0; }
EOF
-if { (eval echo configure:5266: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5300: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_strstr=no
else
@@ -5283,12 +5317,12 @@ EOF
fi
echo $ac_n "checking whether sbrk must be declared""... $ac_c" 1>&6
-echo "configure:5287: checking whether sbrk must be declared" >&5
+echo "configure:5321: checking whether sbrk must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_sbrk'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5292 "configure"
+#line 5326 "configure"
#include "confdefs.h"
#include <stdio.h>
@@ -5309,7 +5343,7 @@ int main() {
char *(*pfn) = (char *(*)) sbrk
; return 0; }
EOF
-if { (eval echo configure:5313: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5347: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_sbrk=no
else
@@ -5330,12 +5364,12 @@ EOF
fi
echo $ac_n "checking whether getenv must be declared""... $ac_c" 1>&6
-echo "configure:5334: checking whether getenv must be declared" >&5
+echo "configure:5368: checking whether getenv must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_getenv'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5339 "configure"
+#line 5373 "configure"
#include "confdefs.h"
#include <stdio.h>
@@ -5356,7 +5390,7 @@ int main() {
char *(*pfn) = (char *(*)) getenv
; return 0; }
EOF
-if { (eval echo configure:5360: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5394: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_getenv=no
else
@@ -5377,12 +5411,12 @@ EOF
fi
echo $ac_n "checking whether environ must be declared""... $ac_c" 1>&6
-echo "configure:5381: checking whether environ must be declared" >&5
+echo "configure:5415: checking whether environ must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_environ'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5386 "configure"
+#line 5420 "configure"
#include "confdefs.h"
#include <stdio.h>
@@ -5403,7 +5437,7 @@ int main() {
char *(*pfn) = (char *(*)) environ
; return 0; }
EOF
-if { (eval echo configure:5407: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5441: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_environ=no
else
@@ -5469,7 +5503,7 @@ do
NLMCONV_DEFS="-DNLMCONV_I386 -DNLMCONV_ALPHA -DNLMCONV_POWERPC -DNLMCONV_SPARC"
else
case $targ in
- i[3456]86*-*-netware*)
+ i[3-7]86*-*-netware*)
BUILD_NLMCONV='$(NLMCONV_PROG)$(EXEEXT)'
NLMCONV_DEFS="$NLMCONV_DEFS -DNLMCONV_I386"
;;
@@ -5495,12 +5529,12 @@ do
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM_EPOC -DDLLTOOL_ARM"
BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
;;
- arm-pe* | arm-*-wince)
+ arm-*-pe* | arm-*-wince)
BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM"
BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
;;
- thumb-pe*)
+ thumb-*-pe*)
BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM"
BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
@@ -5508,16 +5542,21 @@ do
arm*-* | xscale-* | strongarm-* | d10v-*)
OBJDUMP_DEFS="-DDISASSEMBLER_NEEDS_RELOCS"
;;
- i[3-6]86-pe* | i[3-6]86-*-cygwin* | i[3-6]86-*-mingw32** | i[3-6]86-*-netbsdpe*)
+ i[3-7]86-*-pe* | i[3-7]86-*-cygwin* | i[3-7]86-*-mingw32** | i[3-7]86-*-netbsdpe*)
BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_I386"
BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
BUILD_DLLWRAP='$(DLLWRAP_PROG)$(EXEEXT)'
;;
- i3-686-*-interix)
+ i[3-7]86-*-interix)
BUILD_DLLTOOL='$(DLLTOOL_PROG)'
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_I386"
;;
+ powerpc*-aix5.[01])
+ ;;
+ powerpc*-aix5.*)
+ OBJDUMP_DEFS="-DAIX_WEAK_SUPPORT"
+ ;;
powerpc*-*-pe* | powerpc*-*-cygwin*)
BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_PPC"
@@ -5533,15 +5572,21 @@ do
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MIPS"
BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
;;
- mcore-pe)
+ mcore-*-pe)
BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MCORE"
BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
;;
- mcore-*elf)
+ mcore-*-elf)
BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MCORE_ELF"
;;
+ c4x-*-* | tic4x-*-*)
+ OBJDUMP_DEFS="$OBJDUMP_DEFS -DSKIP_ZEROES=32"
+ ;;
+ ia64-*-*)
+ OBJDUMP_DEFS="$OBJDUMP_DEFS -DSKIP_ZEROES=16"
+ ;;
esac
fi
done
@@ -5572,6 +5617,9 @@ if test "x$targ_underscore" = "xyes"; then
else
UNDERSCORE=0
fi
+cat >> confdefs.h <<EOF
+#define TARGET_PREPENDS_UNDERSCORE $UNDERSCORE
+EOF
# Emulation
@@ -5742,7 +5790,6 @@ s%@build_alias@%$build_alias%g
s%@build_cpu@%$build_cpu%g
s%@build_vendor@%$build_vendor%g
s%@build_os@%$build_os%g
-s%@CC@%$CC%g
s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
s%@INSTALL_DATA@%$INSTALL_DATA%g
@@ -5754,6 +5801,7 @@ s%@AUTOMAKE@%$AUTOMAKE%g
s%@AUTOHEADER@%$AUTOHEADER%g
s%@MAKEINFO@%$MAKEINFO%g
s%@SET_MAKE@%$SET_MAKE%g
+s%@CC@%$CC%g
s%@LN_S@%$LN_S%g
s%@OBJEXT@%$OBJEXT%g
s%@EXEEXT@%$EXEEXT%g
@@ -5804,7 +5852,6 @@ s%@BUILD_WINDRES@%$BUILD_WINDRES%g
s%@BUILD_DLLWRAP@%$BUILD_DLLWRAP%g
s%@BUILD_MISC@%$BUILD_MISC%g
s%@OBJDUMP_DEFS@%$OBJDUMP_DEFS%g
-s%@UNDERSCORE@%$UNDERSCORE%g
s%@EMULATION@%$EMULATION%g
s%@EMULATION_VECTOR@%$EMULATION_VECTOR%g
diff --git a/contrib/binutils/binutils/configure.in b/contrib/binutils/binutils/configure.in
index 9ca88e8..8889084 100644
--- a/contrib/binutils/binutils/configure.in
+++ b/contrib/binutils/binutils/configure.in
@@ -64,7 +64,7 @@ AC_PROG_CC
AC_PROG_YACC
AM_PROG_LEX
-ALL_LINGUAS="fr tr ja es sv da"
+ALL_LINGUAS="fr tr ja es sv da zh_CN ru"
CY_GNU_GETTEXT
AM_MAINTAINER_MODE
@@ -208,7 +208,7 @@ do
else
case $targ in
changequote(,)dnl
- i[3456]86*-*-netware*)
+ i[3-7]86*-*-netware*)
changequote([,])dnl
BUILD_NLMCONV='$(NLMCONV_PROG)$(EXEEXT)'
NLMCONV_DEFS="$NLMCONV_DEFS -DNLMCONV_I386"
@@ -235,12 +235,12 @@ changequote([,])dnl
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM_EPOC -DDLLTOOL_ARM"
BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
;;
- arm-pe* | arm-*-wince)
+ arm-*-pe* | arm-*-wince)
BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM"
BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
;;
- thumb-pe*)
+ thumb-*-pe*)
BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_ARM"
BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
@@ -249,17 +249,26 @@ changequote([,])dnl
OBJDUMP_DEFS="-DDISASSEMBLER_NEEDS_RELOCS"
;;
changequote(,)dnl
- i[3-6]86-pe* | i[3-6]86-*-cygwin* | i[3-6]86-*-mingw32** | i[3-6]86-*-netbsdpe*)
+ i[3-7]86-*-pe* | i[3-7]86-*-cygwin* | i[3-7]86-*-mingw32** | i[3-7]86-*-netbsdpe*)
changequote([,])dnl
BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_I386"
BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
BUILD_DLLWRAP='$(DLLWRAP_PROG)$(EXEEXT)'
;;
- i[3-6]86-*-interix)
+changequote(,)dnl
+ i[3-7]86-*-interix)
+changequote([,])dnl
BUILD_DLLTOOL='$(DLLTOOL_PROG)'
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_I386"
;;
+changequote(,)dnl
+ powerpc*-aix5.[01])
+changequote([,])dnl
+ ;;
+ powerpc*-aix5.*)
+ OBJDUMP_DEFS="-DAIX_WEAK_SUPPORT"
+ ;;
powerpc*-*-pe* | powerpc*-*-cygwin*)
BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_PPC"
@@ -275,15 +284,21 @@ changequote([,])dnl
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MIPS"
BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
;;
- mcore-pe)
+ mcore-*-pe)
BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MCORE"
BUILD_WINDRES='$(WINDRES_PROG)$(EXEEXT)'
;;
- mcore-*elf)
+ mcore-*-elf)
BUILD_DLLTOOL='$(DLLTOOL_PROG)$(EXEEXT)'
DLLTOOL_DEFS="$DLLTOOL_DEFS -DDLLTOOL_MCORE_ELF"
;;
+ c4x-*-* | tic4x-*-*)
+ OBJDUMP_DEFS="$OBJDUMP_DEFS -DSKIP_ZEROES=32"
+ ;;
+ ia64-*-*)
+ OBJDUMP_DEFS="$OBJDUMP_DEFS -DSKIP_ZEROES=16"
+ ;;
esac
fi
done
@@ -311,7 +326,8 @@ if test "x$targ_underscore" = "xyes"; then
else
UNDERSCORE=0
fi
-AC_SUBST(UNDERSCORE)
+AC_DEFINE_UNQUOTED(TARGET_PREPENDS_UNDERSCORE, $UNDERSCORE,
+ [Define to 1 if user symbol names have a leading underscore, 0 if not.])
# Emulation
for targ_alias in `echo $target_alias $enable_targets | sed 's/,/ /g'`
diff --git a/contrib/binutils/binutils/cxxfilt.c b/contrib/binutils/binutils/cxxfilt.c
new file mode 100644
index 0000000..1b297fd
--- /dev/null
+++ b/contrib/binutils/binutils/cxxfilt.c
@@ -0,0 +1,291 @@
+/* Demangler for GNU C++ - main program
+ Copyright 1989, 1991, 1994, 1995, 1996, 1997, 1998, 1999,
+ 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
+ Written by James Clark (jjc@jclark.uucp)
+ Rewritten by Fred Fish (fnf@cygnus.com) for ARM and Lucid demangling
+ Modified by Satish Pai (pai@apollo.hp.com) for HP demangling
+
+This file is part of GCC.
+
+GCC is free software; you can redistribute it and/or modify it under
+the terms of the GNU General Public License as published by the Free
+Software Foundation; either version 2, or (at your option) any later
+version.
+
+GCC is distributed in the hope that it will be useful, but WITHOUT ANY
+WARRANTY; without even the implied warranty of MERCHANTABILITY or
+FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+for more details.
+
+You should have received a copy of the GNU General Public License
+along with GCC; see the file COPYING. If not, write to the Free
+Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+02111-1307, USA. */
+
+#include "config.h"
+#include "bfd.h"
+#include "bucomm.h"
+#include "libiberty.h"
+#include "demangle.h"
+#include "getopt.h"
+#include "safe-ctype.h"
+
+static int flags = DMGL_PARAMS | DMGL_ANSI | DMGL_VERBOSE;
+
+static void demangle_it (char *);
+static void usage (FILE *, int) ATTRIBUTE_NORETURN;
+static void print_demangler_list (FILE *);
+
+static void
+demangle_it (char *mangled_name)
+{
+ char *result;
+
+ /* For command line args, also try to demangle type encodings. */
+ result = cplus_demangle (mangled_name, flags | DMGL_TYPES);
+ if (result == NULL)
+ {
+ printf ("%s\n", mangled_name);
+ }
+ else
+ {
+ printf ("%s\n", result);
+ free (result);
+ }
+}
+
+static void
+print_demangler_list (FILE *stream)
+{
+ const struct demangler_engine *demangler;
+
+ fprintf (stream, "{%s", libiberty_demanglers->demangling_style_name);
+
+ for (demangler = libiberty_demanglers + 1;
+ demangler->demangling_style != unknown_demangling;
+ ++demangler)
+ fprintf (stream, ",%s", demangler->demangling_style_name);
+
+ fprintf (stream, "}");
+}
+
+static void
+usage (FILE *stream, int status)
+{
+ fprintf (stream, "\
+Usage: %s [-_] [-n] [--strip-underscores] [--no-strip-underscores]\n\
+ [-p] [--no-params]\n",
+ program_name);
+
+ fprintf (stream, "\
+ [-s ");
+ print_demangler_list (stream);
+ fprintf (stream, "]\n");
+
+ fprintf (stream, "\
+ [--format ");
+ print_demangler_list (stream);
+ fprintf (stream, "]\n");
+
+ fprintf (stream, "\
+ [--help] [--version] [arg...]\n");
+ exit (status);
+}
+
+#define MBUF_SIZE 32767
+char mbuffer[MBUF_SIZE];
+
+int strip_underscore = 0;
+
+static const struct option long_options[] = {
+ {"strip-underscores", no_argument, 0, '_'},
+ {"format", required_argument, 0, 's'},
+ {"help", no_argument, 0, 'h'},
+ {"no-params", no_argument, 0, 'p'},
+ {"no-strip-underscores", no_argument, 0, 'n'},
+ {"version", no_argument, 0, 'v'},
+ {0, no_argument, 0, 0}
+};
+
+static const char *standard_symbol_characters (void);
+
+static const char *hp_symbol_characters (void);
+
+/* Return the string of non-alnum characters that may occur
+ as a valid symbol component, in the standard assembler symbol
+ syntax. */
+
+static const char *
+standard_symbol_characters (void)
+{
+ return "_$.";
+}
+
+
+/* Return the string of non-alnum characters that may occur
+ as a valid symbol name component in an HP object file.
+
+ Note that, since HP's compiler generates object code straight from
+ C++ source, without going through an assembler, its mangled
+ identifiers can use all sorts of characters that no assembler would
+ tolerate, so the alphabet this function creates is a little odd.
+ Here are some sample mangled identifiers offered by HP:
+
+ typeid*__XT24AddressIndExpClassMember_
+ [Vftptr]key:__dt__32OrdinaryCompareIndExpClassMemberFv
+ __ct__Q2_9Elf64_Dyn18{unnamed.union.#1}Fv
+
+ This still seems really weird to me, since nowhere else in this
+ file is there anything to recognize curly brackets, parens, etc.
+ I've talked with Srikanth <srikanth@cup.hp.com>, and he assures me
+ this is right, but I still strongly suspect that there's a
+ misunderstanding here.
+
+ If we decide it's better for c++filt to use HP's assembler syntax
+ to scrape identifiers out of its input, here's the definition of
+ the symbol name syntax from the HP assembler manual:
+
+ Symbols are composed of uppercase and lowercase letters, decimal
+ digits, dollar symbol, period (.), ampersand (&), pound sign(#) and
+ underscore (_). A symbol can begin with a letter, digit underscore or
+ dollar sign. If a symbol begins with a digit, it must contain a
+ non-digit character.
+
+ So have fun. */
+static const char *
+hp_symbol_characters (void)
+{
+ return "_$.<>#,*&[]:(){}";
+}
+
+extern int main (int, char **);
+
+int
+main (int argc, char **argv)
+{
+ char *result;
+ int c;
+ const char *valid_symbols;
+ enum demangling_styles style = auto_demangling;
+
+ program_name = argv[0];
+ xmalloc_set_program_name (program_name);
+
+ strip_underscore = TARGET_PREPENDS_UNDERSCORE;
+
+ while ((c = getopt_long (argc, argv, "_nps:", long_options, (int *) 0)) != EOF)
+ {
+ switch (c)
+ {
+ case '?':
+ usage (stderr, 1);
+ break;
+ case 'h':
+ usage (stdout, 0);
+ case 'n':
+ strip_underscore = 0;
+ break;
+ case 'p':
+ flags &= ~ DMGL_PARAMS;
+ break;
+ case 'v':
+ print_version ("c++filt");
+ return (0);
+ case '_':
+ strip_underscore = 1;
+ break;
+ case 's':
+ {
+ style = cplus_demangle_name_to_style (optarg);
+ if (style == unknown_demangling)
+ {
+ fprintf (stderr, "%s: unknown demangling style `%s'\n",
+ program_name, optarg);
+ return (1);
+ }
+ else
+ cplus_demangle_set_style (style);
+ }
+ break;
+ }
+ }
+
+ if (optind < argc)
+ {
+ for ( ; optind < argc; optind++)
+ {
+ demangle_it (argv[optind]);
+ }
+ }
+ else
+ {
+ switch (current_demangling_style)
+ {
+ case gnu_demangling:
+ case lucid_demangling:
+ case arm_demangling:
+ case java_demangling:
+ case edg_demangling:
+ case gnat_demangling:
+ case gnu_v3_demangling:
+ case auto_demangling:
+ valid_symbols = standard_symbol_characters ();
+ break;
+ case hp_demangling:
+ valid_symbols = hp_symbol_characters ();
+ break;
+ default:
+ /* Folks should explicitly indicate the appropriate alphabet for
+ each demangling. Providing a default would allow the
+ question to go unconsidered. */
+ fatal ("Internal error: no symbol alphabet for current style");
+ }
+
+ for (;;)
+ {
+ int i = 0;
+ c = getchar ();
+ /* Try to read a label. */
+ while (c != EOF && (ISALNUM (c) || strchr (valid_symbols, c)))
+ {
+ if (i >= MBUF_SIZE-1)
+ break;
+ mbuffer[i++] = c;
+ c = getchar ();
+ }
+ if (i > 0)
+ {
+ int skip_first = 0;
+
+ mbuffer[i] = 0;
+ if (mbuffer[0] == '.' || mbuffer[0] == '$')
+ ++skip_first;
+ if (strip_underscore && mbuffer[skip_first] == '_')
+ ++skip_first;
+
+ if (skip_first > i)
+ skip_first = i;
+
+ flags |= (int) style;
+ result = cplus_demangle (mbuffer + skip_first, flags);
+ if (result)
+ {
+ if (mbuffer[0] == '.')
+ putc ('.', stdout);
+ fputs (result, stdout);
+ free (result);
+ }
+ else
+ fputs (mbuffer, stdout);
+
+ fflush (stdout);
+ }
+ if (c == EOF)
+ break;
+ putchar (c);
+ fflush (stdout);
+ }
+ }
+
+ return (0);
+}
diff --git a/contrib/binutils/binutils/debug.c b/contrib/binutils/binutils/debug.c
index 3ce609b..5d46b78 100644
--- a/contrib/binutils/binutils/debug.c
+++ b/contrib/binutils/binutils/debug.c
@@ -1,5 +1,5 @@
/* debug.c -- Handle generic debugging information.
- Copyright 1995, 1996, 1997, 1998, 2000, 2002 Free Software Foundation, Inc.
+ Copyright 1995, 1996, 1997, 1998, 2000, 2002, 2003 Free Software Foundation, Inc.
Written by Ian Lance Taylor <ian@cygnus.com>.
This file is part of GNU Binutils.
@@ -22,7 +22,7 @@
/* This file implements a generic debugging format. We may eventually
have readers which convert different formats into this generic
format, and writers which write it out. The initial impetus for
- this was writing a convertor from stabs to HP IEEE-695 debugging
+ this was writing a converter from stabs to HP IEEE-695 debugging
format. */
#include <stdio.h>
@@ -111,7 +111,7 @@ struct debug_type
struct debug_indirect_type *kindirect;
/* DEBUG_KIND_INT. */
/* Whether the integer is unsigned. */
- boolean kint;
+ bfd_boolean kint;
/* DEBUG_KIND_STRUCT, DEBUG_KIND_UNION, DEBUG_KIND_CLASS,
DEBUG_KIND_UNION_CLASS. */
struct debug_class_type *kclass;
@@ -194,7 +194,7 @@ struct debug_function_type
/* NULL terminated array of argument types. */
debug_type *arg_types;
/* Whether the function takes a variable number of arguments. */
- boolean varargs;
+ bfd_boolean varargs;
};
/* Information kept for a range. */
@@ -222,7 +222,7 @@ struct debug_array_type
/* Upper bound. */
bfd_signed_vma upper;
/* Whether this array is really a string. */
- boolean stringp;
+ bfd_boolean stringp;
};
/* Information kept for a set. */
@@ -232,7 +232,7 @@ struct debug_set_type
/* Base type. */
debug_type type;
/* Whether this set is really a bitstring. */
- boolean bitstringp;
+ bfd_boolean bitstringp;
};
/* Information kept for an offset type (a based pointer). */
@@ -256,7 +256,7 @@ struct debug_method_type
/* A NULL terminated array of argument types. */
debug_type *arg_types;
/* Whether the method takes a variable number of arguments. */
- boolean varargs;
+ bfd_boolean varargs;
};
/* Information kept for a named type. */
@@ -280,7 +280,7 @@ struct debug_field
/* Visibility of the field. */
enum debug_visibility visibility;
/* Whether this is a static member. */
- boolean static_member;
+ bfd_boolean static_member;
union
{
/* If static_member is false. */
@@ -308,7 +308,7 @@ struct debug_baseclass
/* Bit position of the base class in the object. */
unsigned int bitpos;
/* Whether the base class is virtual. */
- boolean virtual;
+ bfd_boolean virtual;
/* Visibility of the base class. */
enum debug_visibility visibility;
};
@@ -335,9 +335,9 @@ struct debug_method_variant
/* The visibility of the function. */
enum debug_visibility visibility;
/* Whether the function is const. */
- boolean constp;
+ bfd_boolean constp;
/* Whether the function is volatile. */
- boolean volatilep;
+ bfd_boolean volatilep;
/* The offset to the function in the virtual function table. */
bfd_vma voffset;
/* If voffset is VOFFSET_STATIC_METHOD, this is a static method. */
@@ -554,47 +554,45 @@ struct debug_type_real_list
/* Local functions. */
-static void debug_error PARAMS ((const char *));
+static void debug_error (const char *);
static struct debug_name *debug_add_to_namespace
- PARAMS ((struct debug_handle *, struct debug_namespace **, const char *,
- enum debug_object_kind, enum debug_object_linkage));
+ (struct debug_handle *, struct debug_namespace **, const char *,
+ enum debug_object_kind, enum debug_object_linkage);
static struct debug_name *debug_add_to_current_namespace
- PARAMS ((struct debug_handle *, const char *, enum debug_object_kind,
- enum debug_object_linkage));
+ (struct debug_handle *, const char *, enum debug_object_kind,
+ enum debug_object_linkage);
static struct debug_type *debug_make_type
- PARAMS ((struct debug_handle *, enum debug_type_kind, unsigned int));
+ (struct debug_handle *, enum debug_type_kind, unsigned int);
static struct debug_type *debug_get_real_type
- PARAMS ((PTR, debug_type, struct debug_type_real_list *));
-static boolean debug_write_name
- PARAMS ((struct debug_handle *, const struct debug_write_fns *, PTR,
- struct debug_name *));
-static boolean debug_write_type
- PARAMS ((struct debug_handle *, const struct debug_write_fns *, PTR,
- struct debug_type *, struct debug_name *));
-static boolean debug_write_class_type
- PARAMS ((struct debug_handle *, const struct debug_write_fns *, PTR,
- struct debug_type *, const char *));
-static boolean debug_write_function
- PARAMS ((struct debug_handle *, const struct debug_write_fns *, PTR,
- const char *, enum debug_object_linkage, struct debug_function *));
-static boolean debug_write_block
- PARAMS ((struct debug_handle *, const struct debug_write_fns *, PTR,
- struct debug_block *));
-static boolean debug_write_linenos
- PARAMS ((struct debug_handle *, const struct debug_write_fns *, PTR,
- bfd_vma));
-static boolean debug_set_class_id
- PARAMS ((struct debug_handle *, const char *, struct debug_type *));
-static boolean debug_type_samep
- PARAMS ((struct debug_handle *, struct debug_type *, struct debug_type *));
-static boolean debug_class_type_samep
- PARAMS ((struct debug_handle *, struct debug_type *, struct debug_type *));
+ (void *, debug_type, struct debug_type_real_list *);
+static bfd_boolean debug_write_name
+ (struct debug_handle *, const struct debug_write_fns *, void *,
+ struct debug_name *);
+static bfd_boolean debug_write_type
+ (struct debug_handle *, const struct debug_write_fns *, void *,
+ struct debug_type *, struct debug_name *);
+static bfd_boolean debug_write_class_type
+ (struct debug_handle *, const struct debug_write_fns *, void *,
+ struct debug_type *, const char *);
+static bfd_boolean debug_write_function
+ (struct debug_handle *, const struct debug_write_fns *, void *,
+ const char *, enum debug_object_linkage, struct debug_function *);
+static bfd_boolean debug_write_block
+ (struct debug_handle *, const struct debug_write_fns *, void *,
+ struct debug_block *);
+static bfd_boolean debug_write_linenos
+ (struct debug_handle *, const struct debug_write_fns *, void *, bfd_vma);
+static bfd_boolean debug_set_class_id
+ (struct debug_handle *, const char *, struct debug_type *);
+static bfd_boolean debug_type_samep
+ (struct debug_handle *, struct debug_type *, struct debug_type *);
+static bfd_boolean debug_class_type_samep
+ (struct debug_handle *, struct debug_type *, struct debug_type *);
/* Issue an error message. */
static void
-debug_error (message)
- const char *message;
+debug_error (const char *message)
{
fprintf (stderr, "%s\n", message);
}
@@ -602,12 +600,10 @@ debug_error (message)
/* Add an object to a namespace. */
static struct debug_name *
-debug_add_to_namespace (info, nsp, name, kind, linkage)
- struct debug_handle *info ATTRIBUTE_UNUSED;
- struct debug_namespace **nsp;
- const char *name;
- enum debug_object_kind kind;
- enum debug_object_linkage linkage;
+debug_add_to_namespace (struct debug_handle *info ATTRIBUTE_UNUSED,
+ struct debug_namespace **nsp, const char *name,
+ enum debug_object_kind kind,
+ enum debug_object_linkage linkage)
{
struct debug_name *n;
struct debug_namespace *ns;
@@ -639,11 +635,9 @@ debug_add_to_namespace (info, nsp, name, kind, linkage)
/* Add an object to the current namespace. */
static struct debug_name *
-debug_add_to_current_namespace (info, name, kind, linkage)
- struct debug_handle *info;
- const char *name;
- enum debug_object_kind kind;
- enum debug_object_linkage linkage;
+debug_add_to_current_namespace (struct debug_handle *info, const char *name,
+ enum debug_object_kind kind,
+ enum debug_object_linkage linkage)
{
struct debug_namespace **nsp;
@@ -664,23 +658,21 @@ debug_add_to_current_namespace (info, name, kind, linkage)
/* Return a handle for debugging information. */
-PTR
-debug_init ()
+void *
+debug_init (void)
{
struct debug_handle *ret;
ret = (struct debug_handle *) xmalloc (sizeof *ret);
memset (ret, 0, sizeof *ret);
- return (PTR) ret;
+ return (void *) ret;
}
/* Set the source filename. This implicitly starts a new compilation
unit. */
-boolean
-debug_set_filename (handle, name)
- PTR handle;
- const char *name;
+bfd_boolean
+debug_set_filename (void *handle, const char *name)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_file *nfile;
@@ -714,16 +706,14 @@ debug_set_filename (handle, name)
info->current_block = NULL;
info->current_lineno = NULL;
- return true;
+ return TRUE;
}
/* Change source files to the given file name. This is used for
include files in a single compilation unit. */
-boolean
-debug_start_source (handle, name)
- PTR handle;
- const char *name;
+bfd_boolean
+debug_start_source (void *handle, const char *name)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_file *f, **pf;
@@ -734,7 +724,7 @@ debug_start_source (handle, name)
if (info->current_unit == NULL)
{
debug_error (_("debug_start_source: no debug_set_filename call"));
- return false;
+ return FALSE;
}
for (f = info->current_unit->files; f != NULL; f = f->next)
@@ -744,7 +734,7 @@ debug_start_source (handle, name)
&& strcmp (f->filename, name) == 0)
{
info->current_file = f;
- return true;
+ return TRUE;
}
}
@@ -761,7 +751,7 @@ debug_start_source (handle, name)
info->current_file = f;
- return true;
+ return TRUE;
}
/* Record a function definition. This implicitly starts a function
@@ -772,13 +762,10 @@ debug_start_source (handle, name)
debug_record_parameter. FIXME: There is no way to specify nested
functions. */
-boolean
-debug_record_function (handle, name, return_type, global, addr)
- PTR handle;
- const char *name;
- debug_type return_type;
- boolean global;
- bfd_vma addr;
+bfd_boolean
+debug_record_function (void *handle, const char *name,
+ debug_type return_type, bfd_boolean global,
+ bfd_vma addr)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_function *f;
@@ -788,12 +775,12 @@ debug_record_function (handle, name, return_type, global, addr)
if (name == NULL)
name = "";
if (return_type == NULL)
- return false;
+ return FALSE;
if (info->current_unit == NULL)
{
debug_error (_("debug_record_function: no debug_set_filename call"));
- return false;
+ return FALSE;
}
f = (struct debug_function *) xmalloc (sizeof *f);
@@ -822,34 +809,30 @@ debug_record_function (handle, name, return_type, global, addr)
? DEBUG_LINKAGE_GLOBAL
: DEBUG_LINKAGE_STATIC));
if (n == NULL)
- return false;
+ return FALSE;
n->u.function = f;
- return true;
+ return TRUE;
}
/* Record a parameter for the current function. */
-boolean
-debug_record_parameter (handle, name, type, kind, val)
- PTR handle;
- const char *name;
- debug_type type;
- enum debug_parm_kind kind;
- bfd_vma val;
+bfd_boolean
+debug_record_parameter (void *handle, const char *name, debug_type type,
+ enum debug_parm_kind kind, bfd_vma val)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_parameter *p, **pp;
if (name == NULL || type == NULL)
- return false;
+ return FALSE;
if (info->current_unit == NULL
|| info->current_function == NULL)
{
debug_error (_("debug_record_parameter: no current function"));
- return false;
+ return FALSE;
}
p = (struct debug_parameter *) xmalloc (sizeof *p);
@@ -866,15 +849,13 @@ debug_record_parameter (handle, name, type, kind, val)
;
*pp = p;
- return true;
+ return TRUE;
}
/* End a function. FIXME: This should handle function nesting. */
-boolean
-debug_end_function (handle, addr)
- PTR handle;
- bfd_vma addr;
+bfd_boolean
+debug_end_function (void *handle, bfd_vma addr)
{
struct debug_handle *info = (struct debug_handle *) handle;
@@ -883,13 +864,13 @@ debug_end_function (handle, addr)
|| info->current_function == NULL)
{
debug_error (_("debug_end_function: no current function"));
- return false;
+ return FALSE;
}
if (info->current_block->parent != NULL)
{
debug_error (_("debug_end_function: some blocks were not closed"));
- return false;
+ return FALSE;
}
info->current_block->end = addr;
@@ -897,7 +878,7 @@ debug_end_function (handle, addr)
info->current_function = NULL;
info->current_block = NULL;
- return true;
+ return TRUE;
}
/* Start a block in a function. All local information will be
@@ -905,10 +886,8 @@ debug_end_function (handle, addr)
debug_start_block and debug_end_block may be nested. The bfd_vma
argument is the address at which this block starts. */
-boolean
-debug_start_block (handle, addr)
- PTR handle;
- bfd_vma addr;
+bfd_boolean
+debug_start_block (void *handle, bfd_vma addr)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_block *b, **pb;
@@ -919,7 +898,7 @@ debug_start_block (handle, addr)
|| info->current_block == NULL)
{
debug_error (_("debug_start_block: no current block"));
- return false;
+ return FALSE;
}
b = (struct debug_block *) xmalloc (sizeof *b);
@@ -938,17 +917,15 @@ debug_start_block (handle, addr)
info->current_block = b;
- return true;
+ return TRUE;
}
/* Finish a block in a function. This matches the call to
debug_start_block. The argument is the address at which this block
ends. */
-boolean
-debug_end_block (handle, addr)
- PTR handle;
- bfd_vma addr;
+bfd_boolean
+debug_end_block (void *handle, bfd_vma addr)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_block *parent;
@@ -957,31 +934,28 @@ debug_end_block (handle, addr)
|| info->current_block == NULL)
{
debug_error (_("debug_end_block: no current block"));
- return false;
+ return FALSE;
}
parent = info->current_block->parent;
if (parent == NULL)
{
debug_error (_("debug_end_block: attempt to close top level block"));
- return false;
+ return FALSE;
}
info->current_block->end = addr;
info->current_block = parent;
- return true;
+ return TRUE;
}
/* Associate a line number in the current source file and function
with a given address. */
-boolean
-debug_record_line (handle, lineno, addr)
- PTR handle;
- unsigned long lineno;
- bfd_vma addr;
+bfd_boolean
+debug_record_line (void *handle, unsigned long lineno, bfd_vma addr)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_lineno *l;
@@ -990,7 +964,7 @@ debug_record_line (handle, lineno, addr)
if (info->current_unit == NULL)
{
debug_error (_("debug_record_line: no current unit"));
- return false;
+ return FALSE;
}
l = info->current_lineno;
@@ -1002,7 +976,7 @@ debug_record_line (handle, lineno, addr)
{
l->linenos[i] = lineno;
l->addrs[i] = addr;
- return true;
+ return TRUE;
}
}
}
@@ -1031,102 +1005,91 @@ debug_record_line (handle, lineno, addr)
info->current_lineno = l;
- return true;
+ return TRUE;
}
/* Start a named common block. This is a block of variables that may
move in memory. */
-boolean
-debug_start_common_block (handle, name)
- PTR handle ATTRIBUTE_UNUSED;
- const char *name ATTRIBUTE_UNUSED;
+bfd_boolean
+debug_start_common_block (void *handle ATTRIBUTE_UNUSED,
+ const char *name ATTRIBUTE_UNUSED)
{
/* FIXME */
debug_error (_("debug_start_common_block: not implemented"));
- return false;
+ return FALSE;
}
/* End a named common block. */
-boolean
-debug_end_common_block (handle, name)
- PTR handle ATTRIBUTE_UNUSED;
- const char *name ATTRIBUTE_UNUSED;
+bfd_boolean
+debug_end_common_block (void *handle ATTRIBUTE_UNUSED,
+ const char *name ATTRIBUTE_UNUSED)
{
/* FIXME */
debug_error (_("debug_end_common_block: not implemented"));
- return false;
+ return FALSE;
}
/* Record a named integer constant. */
-boolean
-debug_record_int_const (handle, name, val)
- PTR handle;
- const char *name;
- bfd_vma val;
+bfd_boolean
+debug_record_int_const (void *handle, const char *name, bfd_vma val)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_name *n;
if (name == NULL)
- return false;
+ return FALSE;
n = debug_add_to_current_namespace (info, name, DEBUG_OBJECT_INT_CONSTANT,
DEBUG_LINKAGE_NONE);
if (n == NULL)
- return false;
+ return FALSE;
n->u.int_constant = val;
- return true;
+ return TRUE;
}
/* Record a named floating point constant. */
-boolean
-debug_record_float_const (handle, name, val)
- PTR handle;
- const char *name;
- double val;
+bfd_boolean
+debug_record_float_const (void *handle, const char *name, double val)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_name *n;
if (name == NULL)
- return false;
+ return FALSE;
n = debug_add_to_current_namespace (info, name, DEBUG_OBJECT_FLOAT_CONSTANT,
DEBUG_LINKAGE_NONE);
if (n == NULL)
- return false;
+ return FALSE;
n->u.float_constant = val;
- return true;
+ return TRUE;
}
/* Record a typed constant with an integral value. */
-boolean
-debug_record_typed_const (handle, name, type, val)
- PTR handle;
- const char *name;
- debug_type type;
- bfd_vma val;
+bfd_boolean
+debug_record_typed_const (void *handle, const char *name, debug_type type,
+ bfd_vma val)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_name *n;
struct debug_typed_constant *tc;
if (name == NULL || type == NULL)
- return false;
+ return FALSE;
n = debug_add_to_current_namespace (info, name, DEBUG_OBJECT_TYPED_CONSTANT,
DEBUG_LINKAGE_NONE);
if (n == NULL)
- return false;
+ return FALSE;
tc = (struct debug_typed_constant *) xmalloc (sizeof *tc);
memset (tc, 0, sizeof *tc);
@@ -1136,32 +1099,27 @@ debug_record_typed_const (handle, name, type, val)
n->u.typed_constant = tc;
- return true;
+ return TRUE;
}
/* Record a label. */
-boolean
-debug_record_label (handle, name, type, addr)
- PTR handle ATTRIBUTE_UNUSED;
- const char *name ATTRIBUTE_UNUSED;
- debug_type type ATTRIBUTE_UNUSED;
- bfd_vma addr ATTRIBUTE_UNUSED;
+bfd_boolean
+debug_record_label (void *handle ATTRIBUTE_UNUSED,
+ const char *name ATTRIBUTE_UNUSED,
+ debug_type type ATTRIBUTE_UNUSED,
+ bfd_vma addr ATTRIBUTE_UNUSED)
{
/* FIXME. */
debug_error (_("debug_record_label: not implemented"));
- return false;
+ return FALSE;
}
/* Record a variable. */
-boolean
-debug_record_variable (handle, name, type, kind, val)
- PTR handle;
- const char *name;
- debug_type type;
- enum debug_var_kind kind;
- bfd_vma val;
+bfd_boolean
+debug_record_variable (void *handle, const char *name, debug_type type,
+ enum debug_var_kind kind, bfd_vma val)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_namespace **nsp;
@@ -1170,13 +1128,13 @@ debug_record_variable (handle, name, type, kind, val)
struct debug_variable *v;
if (name == NULL || type == NULL)
- return false;
+ return FALSE;
if (info->current_unit == NULL
|| info->current_file == NULL)
{
debug_error (_("debug_record_variable: no current file"));
- return false;
+ return FALSE;
}
if (kind == DEBUG_GLOBAL || kind == DEBUG_STATIC)
@@ -1190,17 +1148,15 @@ debug_record_variable (handle, name, type, kind, val)
else
{
if (info->current_block == NULL)
- {
- debug_error (_("debug_record_variable: no current block"));
- return false;
- }
- nsp = &info->current_block->locals;
+ nsp = &info->current_file->globals;
+ else
+ nsp = &info->current_block->locals;
linkage = DEBUG_LINKAGE_AUTOMATIC;
}
n = debug_add_to_namespace (info, nsp, name, DEBUG_OBJECT_VARIABLE, linkage);
if (n == NULL)
- return false;
+ return FALSE;
v = (struct debug_variable *) xmalloc (sizeof *v);
memset (v, 0, sizeof *v);
@@ -1211,16 +1167,14 @@ debug_record_variable (handle, name, type, kind, val)
n->u.variable = v;
- return true;
+ return TRUE;
}
/* Make a type with a given kind and size. */
static struct debug_type *
-debug_make_type (info, kind, size)
- struct debug_handle *info ATTRIBUTE_UNUSED;
- enum debug_type_kind kind;
- unsigned int size;
+debug_make_type (struct debug_handle *info ATTRIBUTE_UNUSED,
+ enum debug_type_kind kind, unsigned int size)
{
struct debug_type *t;
@@ -1237,10 +1191,7 @@ debug_make_type (info, kind, size)
which is referenced before it is defined. */
debug_type
-debug_make_indirect_type (handle, slot, tag)
- PTR handle;
- debug_type *slot;
- const char *tag;
+debug_make_indirect_type (void *handle, debug_type *slot, const char *tag)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -1264,8 +1215,7 @@ debug_make_indirect_type (handle, slot, tag)
/* Make a void type. There is only one of these. */
debug_type
-debug_make_void_type (handle)
- PTR handle;
+debug_make_void_type (void *handle)
{
struct debug_handle *info = (struct debug_handle *) handle;
@@ -1276,10 +1226,7 @@ debug_make_void_type (handle)
if the integer is unsigned. */
debug_type
-debug_make_int_type (handle, size, unsignedp)
- PTR handle;
- unsigned int size;
- boolean unsignedp;
+debug_make_int_type (void *handle, unsigned int size, bfd_boolean unsignedp)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -1298,9 +1245,7 @@ debug_make_int_type (handle, size, unsignedp)
the format. */
debug_type
-debug_make_float_type (handle, size)
- PTR handle;
- unsigned int size;
+debug_make_float_type (void *handle, unsigned int size)
{
struct debug_handle *info = (struct debug_handle *) handle;
@@ -1310,9 +1255,7 @@ debug_make_float_type (handle, size)
/* Make a boolean type of a given size. */
debug_type
-debug_make_bool_type (handle, size)
- PTR handle;
- unsigned int size;
+debug_make_bool_type (void *handle, unsigned int size)
{
struct debug_handle *info = (struct debug_handle *) handle;
@@ -1322,9 +1265,7 @@ debug_make_bool_type (handle, size)
/* Make a complex type of a given size. */
debug_type
-debug_make_complex_type (handle, size)
- PTR handle;
- unsigned int size;
+debug_make_complex_type (void *handle, unsigned int size)
{
struct debug_handle *info = (struct debug_handle *) handle;
@@ -1336,11 +1277,8 @@ debug_make_complex_type (handle, size)
The fourth argument is a NULL terminated array of fields. */
debug_type
-debug_make_struct_type (handle, structp, size, fields)
- PTR handle;
- boolean structp;
- bfd_vma size;
- debug_field *fields;
+debug_make_struct_type (void *handle, bfd_boolean structp, bfd_vma size,
+ debug_field *fields)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -1370,16 +1308,10 @@ debug_make_struct_type (handle, structp, size, fields)
object has its own virtual function table. */
debug_type
-debug_make_object_type (handle, structp, size, fields, baseclasses,
- methods, vptrbase, ownvptr)
- PTR handle;
- boolean structp;
- bfd_vma size;
- debug_field *fields;
- debug_baseclass *baseclasses;
- debug_method *methods;
- debug_type vptrbase;
- boolean ownvptr;
+debug_make_object_type (void *handle, bfd_boolean structp, bfd_vma size,
+ debug_field *fields, debug_baseclass *baseclasses,
+ debug_method *methods, debug_type vptrbase,
+ bfd_boolean ownvptr)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -1411,10 +1343,8 @@ debug_make_object_type (handle, structp, size, fields, baseclasses,
array of strings, and an array of corresponding values. */
debug_type
-debug_make_enum_type (handle, names, values)
- PTR handle;
- const char **names;
- bfd_signed_vma *values;
+debug_make_enum_type (void *handle, const char **names,
+ bfd_signed_vma *values)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -1438,9 +1368,7 @@ debug_make_enum_type (handle, names, values)
/* Make a pointer to a given type. */
debug_type
-debug_make_pointer_type (handle, type)
- PTR handle;
- debug_type type;
+debug_make_pointer_type (void *handle, debug_type type)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -1466,11 +1394,8 @@ debug_make_pointer_type (handle, type)
to record the parameter types. */
debug_type
-debug_make_function_type (handle, type, arg_types, varargs)
- PTR handle;
- debug_type type;
- debug_type *arg_types;
- boolean varargs;
+debug_make_function_type (void *handle, debug_type type,
+ debug_type *arg_types, bfd_boolean varargs)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -1498,9 +1423,7 @@ debug_make_function_type (handle, type, arg_types, varargs)
/* Make a reference to a given type. */
debug_type
-debug_make_reference_type (handle, type)
- PTR handle;
- debug_type type;
+debug_make_reference_type (void *handle, debug_type type)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -1520,11 +1443,8 @@ debug_make_reference_type (handle, type)
/* Make a range of a given type from a lower to an upper bound. */
debug_type
-debug_make_range_type (handle, type, lower, upper)
- PTR handle;
- debug_type type;
- bfd_signed_vma lower;
- bfd_signed_vma upper;
+debug_make_range_type (void *handle, debug_type type, bfd_signed_vma lower,
+ bfd_signed_vma upper)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -1556,14 +1476,9 @@ debug_make_range_type (handle, type, lower, upper)
actually a string, as in C. */
debug_type
-debug_make_array_type (handle, element_type, range_type, lower, upper,
- stringp)
- PTR handle;
- debug_type element_type;
- debug_type range_type;
- bfd_signed_vma lower;
- bfd_signed_vma upper;
- boolean stringp;
+debug_make_array_type (void *handle, debug_type element_type,
+ debug_type range_type, bfd_signed_vma lower,
+ bfd_signed_vma upper, bfd_boolean stringp)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -1595,10 +1510,7 @@ debug_make_array_type (handle, element_type, range_type, lower, upper,
CHILL. */
debug_type
-debug_make_set_type (handle, type, bitstringp)
- PTR handle;
- debug_type type;
- boolean bitstringp;
+debug_make_set_type (void *handle, debug_type type, bfd_boolean bitstringp)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -1628,10 +1540,8 @@ debug_make_set_type (handle, type, bitstringp)
to. */
debug_type
-debug_make_offset_type (handle, base_type, target_type)
- PTR handle;
- debug_type base_type;
- debug_type target_type;
+debug_make_offset_type (void *handle, debug_type base_type,
+ debug_type target_type)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -1660,12 +1570,9 @@ debug_make_offset_type (handle, base_type, target_type)
argument is a NULL terminated array of argument types. */
debug_type
-debug_make_method_type (handle, return_type, domain_type, arg_types, varargs)
- PTR handle;
- debug_type return_type;
- debug_type domain_type;
- debug_type *arg_types;
- boolean varargs;
+debug_make_method_type (void *handle, debug_type return_type,
+ debug_type domain_type, debug_type *arg_types,
+ bfd_boolean varargs)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -1694,9 +1601,7 @@ debug_make_method_type (handle, return_type, domain_type, arg_types, varargs)
/* Make a const qualified version of a given type. */
debug_type
-debug_make_const_type (handle, type)
- PTR handle;
- debug_type type;
+debug_make_const_type (void *handle, debug_type type)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -1716,9 +1621,7 @@ debug_make_const_type (handle, type)
/* Make a volatile qualified version of a given type. */
debug_type
-debug_make_volatile_type (handle, type)
- PTR handle;
- debug_type type;
+debug_make_volatile_type (void *handle, debug_type type)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -1739,10 +1642,8 @@ debug_make_volatile_type (handle, type)
been mentioned, but not defined. */
debug_type
-debug_make_undefined_tagged_type (handle, name, kind)
- PTR handle;
- const char *name;
- enum debug_type_kind kind;
+debug_make_undefined_tagged_type (void *handle, const char *name,
+ enum debug_type_kind kind)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -1778,12 +1679,9 @@ debug_make_undefined_tagged_type (handle, name, kind)
argument is the visibility of the base class. */
debug_baseclass
-debug_make_baseclass (handle, type, bitpos, virtual, visibility)
- PTR handle ATTRIBUTE_UNUSED;
- debug_type type;
- bfd_vma bitpos;
- boolean virtual;
- enum debug_visibility visibility;
+debug_make_baseclass (void *handle ATTRIBUTE_UNUSED, debug_type type,
+ bfd_vma bitpos, bfd_boolean virtual,
+ enum debug_visibility visibility)
{
struct debug_baseclass *b;
@@ -1805,13 +1703,9 @@ debug_make_baseclass (handle, type, bitpos, virtual, visibility)
of the field. */
debug_field
-debug_make_field (handle, name, type, bitpos, bitsize, visibility)
- PTR handle ATTRIBUTE_UNUSED;
- const char *name;
- debug_type type;
- bfd_vma bitpos;
- bfd_vma bitsize;
- enum debug_visibility visibility;
+debug_make_field (void *handle ATTRIBUTE_UNUSED, const char *name,
+ debug_type type, bfd_vma bitpos, bfd_vma bitsize,
+ enum debug_visibility visibility)
{
struct debug_field *f;
@@ -1820,7 +1714,7 @@ debug_make_field (handle, name, type, bitpos, bitsize, visibility)
f->name = name;
f->type = type;
- f->static_member = false;
+ f->static_member = FALSE;
f->u.f.bitpos = bitpos;
f->u.f.bitsize = bitsize;
f->visibility = visibility;
@@ -1835,12 +1729,9 @@ debug_make_field (handle, name, type, bitpos, bitsize, visibility)
member. */
debug_field
-debug_make_static_member (handle, name, type, physname, visibility)
- PTR handle ATTRIBUTE_UNUSED;
- const char *name;
- debug_type type;
- const char *physname;
- enum debug_visibility visibility;
+debug_make_static_member (void *handle ATTRIBUTE_UNUSED, const char *name,
+ debug_type type, const char *physname,
+ enum debug_visibility visibility)
{
struct debug_field *f;
@@ -1849,7 +1740,7 @@ debug_make_static_member (handle, name, type, physname, visibility)
f->name = name;
f->type = type;
- f->static_member = true;
+ f->static_member = TRUE;
f->u.s.physname = physname;
f->visibility = visibility;
@@ -1860,10 +1751,8 @@ debug_make_static_member (handle, name, type, physname, visibility)
argument is a NULL terminated array of method variants. */
debug_method
-debug_make_method (handle, name, variants)
- PTR handle ATTRIBUTE_UNUSED;
- const char *name;
- debug_method_variant *variants;
+debug_make_method (void *handle ATTRIBUTE_UNUSED, const char *name,
+ debug_method_variant *variants)
{
struct debug_method *m;
@@ -1886,16 +1775,11 @@ debug_make_method (handle, name, variants)
necessary? Could we just use debug_make_const_type? */
debug_method_variant
-debug_make_method_variant (handle, physname, type, visibility, constp,
- volatilep, voffset, context)
- PTR handle ATTRIBUTE_UNUSED;
- const char *physname;
- debug_type type;
- enum debug_visibility visibility;
- boolean constp;
- boolean volatilep;
- bfd_vma voffset;
- debug_type context;
+debug_make_method_variant (void *handle ATTRIBUTE_UNUSED,
+ const char *physname, debug_type type,
+ enum debug_visibility visibility,
+ bfd_boolean constp, bfd_boolean volatilep,
+ bfd_vma voffset, debug_type context)
{
struct debug_method_variant *m;
@@ -1918,14 +1802,10 @@ debug_make_method_variant (handle, physname, type, visibility, constp,
since a static method can not also be virtual. */
debug_method_variant
-debug_make_static_method_variant (handle, physname, type, visibility,
- constp, volatilep)
- PTR handle ATTRIBUTE_UNUSED;
- const char *physname;
- debug_type type;
- enum debug_visibility visibility;
- boolean constp;
- boolean volatilep;
+debug_make_static_method_variant (void *handle ATTRIBUTE_UNUSED,
+ const char *physname, debug_type type,
+ enum debug_visibility visibility,
+ bfd_boolean constp, bfd_boolean volatilep)
{
struct debug_method_variant *m;
@@ -1945,10 +1825,7 @@ debug_make_static_method_variant (handle, physname, type, visibility,
/* Name a type. */
debug_type
-debug_name_type (handle, name, type)
- PTR handle;
- const char *name;
- debug_type type;
+debug_name_type (void *handle, const char *name, debug_type type)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -1994,10 +1871,7 @@ debug_name_type (handle, name, type)
/* Tag a type. */
debug_type
-debug_tag_type (handle, name, type)
- PTR handle;
- const char *name;
- debug_type type;
+debug_tag_type (void *handle, const char *name, debug_type type)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_type *t;
@@ -2049,11 +1923,9 @@ debug_tag_type (handle, name, type)
/* Record the size of a given type. */
-boolean
-debug_record_type_size (handle, type, size)
- PTR handle ATTRIBUTE_UNUSED;
- debug_type type;
- unsigned int size;
+bfd_boolean
+debug_record_type_size (void *handle ATTRIBUTE_UNUSED, debug_type type,
+ unsigned int size)
{
if (type->size != 0 && type->size != size)
fprintf (stderr, _("Warning: changing type size from %d to %d\n"),
@@ -2061,15 +1933,13 @@ debug_record_type_size (handle, type, size)
type->size = size;
- return true;
+ return TRUE;
}
/* Find a named type. */
debug_type
-debug_find_named_type (handle, name)
- PTR handle;
- const char *name;
+debug_find_named_type (void *handle, const char *name)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_block *b;
@@ -2122,10 +1992,8 @@ debug_find_named_type (handle, name)
/* Find a tagged type. */
debug_type
-debug_find_tagged_type (handle, name, kind)
- PTR handle;
- const char *name;
- enum debug_type_kind kind;
+debug_find_tagged_type (void *handle, const char *name,
+ enum debug_type_kind kind)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_unit *u;
@@ -2163,10 +2031,8 @@ debug_find_tagged_type (handle, name, kind)
crashing if the type is defined circularly. */
static struct debug_type *
-debug_get_real_type (handle, type, list)
- PTR handle;
- debug_type type;
- struct debug_type_real_list *list;
+debug_get_real_type (void *handle, debug_type type,
+ struct debug_type_real_list *list)
{
struct debug_type_real_list *l;
struct debug_type_real_list rl;
@@ -2184,7 +2050,7 @@ debug_get_real_type (handle, type, list)
for (l = list; l != NULL; l = l->next)
{
- if (l->t == type)
+ if (l->t == type || l == l->next)
{
fprintf (stderr,
_("debug_get_real_type: circular debug information for %s\n"),
@@ -2214,9 +2080,7 @@ debug_get_real_type (handle, type, list)
/* Get the kind of a type. */
enum debug_type_kind
-debug_get_type_kind (handle, type)
- PTR handle;
- debug_type type;
+debug_get_type_kind (void *handle, debug_type type)
{
if (type == NULL)
return DEBUG_KIND_ILLEGAL;
@@ -2229,9 +2093,7 @@ debug_get_type_kind (handle, type)
/* Get the name of a type. */
const char *
-debug_get_type_name (handle, type)
- PTR handle;
- debug_type type;
+debug_get_type_name (void *handle, debug_type type)
{
if (type->kind == DEBUG_KIND_INDIRECT)
{
@@ -2248,9 +2110,7 @@ debug_get_type_name (handle, type)
/* Get the size of a type. */
bfd_vma
-debug_get_type_size (handle, type)
- PTR handle;
- debug_type type;
+debug_get_type_size (void *handle, debug_type type)
{
if (type == NULL)
return 0;
@@ -2279,15 +2139,15 @@ debug_get_type_size (handle, type)
/* Get the return type of a function or method type. */
debug_type
-debug_get_return_type (handle, type)
- PTR handle;
- debug_type type;
+debug_get_return_type (void *handle, debug_type type)
{
if (type == NULL)
return DEBUG_TYPE_NULL;
+
type = debug_get_real_type (handle, type, NULL);
if (type == NULL)
return DEBUG_TYPE_NULL;
+
switch (type->kind)
{
default:
@@ -2304,16 +2164,16 @@ debug_get_return_type (handle, type)
we don't currently store the parameter types of a function). */
const debug_type *
-debug_get_parameter_types (handle, type, pvarargs)
- PTR handle;
- debug_type type;
- boolean *pvarargs;
+debug_get_parameter_types (void *handle, debug_type type,
+ bfd_boolean *pvarargs)
{
if (type == NULL)
return NULL;
+
type = debug_get_real_type (handle, type, NULL);
if (type == NULL)
return NULL;
+
switch (type->kind)
{
default:
@@ -2331,15 +2191,15 @@ debug_get_parameter_types (handle, type, pvarargs)
/* Get the target type of a type. */
debug_type
-debug_get_target_type (handle, type)
- PTR handle;
- debug_type type;
+debug_get_target_type (void *handle, debug_type type)
{
if (type == NULL)
return NULL;
+
type = debug_get_real_type (handle, type, NULL);
if (type == NULL)
return NULL;
+
switch (type->kind)
{
default:
@@ -2360,15 +2220,15 @@ debug_get_target_type (handle, type)
class. */
const debug_field *
-debug_get_fields (handle, type)
- PTR handle;
- debug_type type;
+debug_get_fields (void *handle, debug_type type)
{
if (type == NULL)
return NULL;
+
type = debug_get_real_type (handle, type, NULL);
if (type == NULL)
return NULL;
+
switch (type->kind)
{
default:
@@ -2385,9 +2245,7 @@ debug_get_fields (handle, type)
/* Get the type of a field. */
debug_type
-debug_get_field_type (handle, field)
- PTR handle ATTRIBUTE_UNUSED;
- debug_field field;
+debug_get_field_type (void *handle ATTRIBUTE_UNUSED, debug_field field)
{
if (field == NULL)
return NULL;
@@ -2397,9 +2255,7 @@ debug_get_field_type (handle, field)
/* Get the name of a field. */
const char *
-debug_get_field_name (handle, field)
- PTR handle ATTRIBUTE_UNUSED;
- debug_field field;
+debug_get_field_name (void *handle ATTRIBUTE_UNUSED, debug_field field)
{
if (field == NULL)
return NULL;
@@ -2409,9 +2265,7 @@ debug_get_field_name (handle, field)
/* Get the bit position of a field. */
bfd_vma
-debug_get_field_bitpos (handle, field)
- PTR handle ATTRIBUTE_UNUSED;
- debug_field field;
+debug_get_field_bitpos (void *handle ATTRIBUTE_UNUSED, debug_field field)
{
if (field == NULL || field->static_member)
return (bfd_vma) -1;
@@ -2421,9 +2275,7 @@ debug_get_field_bitpos (handle, field)
/* Get the bit size of a field. */
bfd_vma
-debug_get_field_bitsize (handle, field)
- PTR handle ATTRIBUTE_UNUSED;
- debug_field field;
+debug_get_field_bitsize (void *handle ATTRIBUTE_UNUSED, debug_field field)
{
if (field == NULL || field->static_member)
return (bfd_vma) -1;
@@ -2433,9 +2285,7 @@ debug_get_field_bitsize (handle, field)
/* Get the visibility of a field. */
enum debug_visibility
-debug_get_field_visibility (handle, field)
- PTR handle ATTRIBUTE_UNUSED;
- debug_field field;
+debug_get_field_visibility (void *handle ATTRIBUTE_UNUSED, debug_field field)
{
if (field == NULL)
return DEBUG_VISIBILITY_IGNORE;
@@ -2445,9 +2295,7 @@ debug_get_field_visibility (handle, field)
/* Get the physical name of a field. */
const char *
-debug_get_field_physname (handle, field)
- PTR handle ATTRIBUTE_UNUSED;
- debug_field field;
+debug_get_field_physname (void *handle ATTRIBUTE_UNUSED, debug_field field)
{
if (field == NULL || ! field->static_member)
return NULL;
@@ -2457,11 +2305,8 @@ debug_get_field_physname (handle, field)
/* Write out the debugging information. This is given a handle to
debugging information, and a set of function pointers to call. */
-boolean
-debug_write (handle, fns, fhandle)
- PTR handle;
- const struct debug_write_fns *fns;
- PTR fhandle;
+bfd_boolean
+debug_write (void *handle, const struct debug_write_fns *fns, void *fhandle)
{
struct debug_handle *info = (struct debug_handle *) handle;
struct debug_unit *u;
@@ -2484,70 +2329,61 @@ debug_write (handle, fns, fhandle)
for (u = info->units; u != NULL; u = u->next)
{
struct debug_file *f;
- boolean first_file;
+ bfd_boolean first_file;
info->current_write_lineno = u->linenos;
info->current_write_lineno_index = 0;
if (! (*fns->start_compilation_unit) (fhandle, u->files->filename))
- return false;
+ return FALSE;
- first_file = true;
+ first_file = TRUE;
for (f = u->files; f != NULL; f = f->next)
{
struct debug_name *n;
if (first_file)
- first_file = false;
- else
- {
- if (! (*fns->start_source) (fhandle, f->filename))
- return false;
- }
+ first_file = FALSE;
+ else if (! (*fns->start_source) (fhandle, f->filename))
+ return FALSE;
if (f->globals != NULL)
- {
- for (n = f->globals->list; n != NULL; n = n->next)
- {
- if (! debug_write_name (info, fns, fhandle, n))
- return false;
- }
- }
+ for (n = f->globals->list; n != NULL; n = n->next)
+ if (! debug_write_name (info, fns, fhandle, n))
+ return FALSE;
}
/* Output any line number information which hasn't already been
handled. */
if (! debug_write_linenos (info, fns, fhandle, (bfd_vma) -1))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Write out an element in a namespace. */
-static boolean
-debug_write_name (info, fns, fhandle, n)
- struct debug_handle *info;
- const struct debug_write_fns *fns;
- PTR fhandle;
- struct debug_name *n;
+static bfd_boolean
+debug_write_name (struct debug_handle *info,
+ const struct debug_write_fns *fns, void *fhandle,
+ struct debug_name *n)
{
switch (n->kind)
{
case DEBUG_OBJECT_TYPE:
if (! debug_write_type (info, fns, fhandle, n->u.type, n)
|| ! (*fns->typdef) (fhandle, n->name))
- return false;
- return true;
+ return FALSE;
+ return TRUE;
case DEBUG_OBJECT_TAG:
if (! debug_write_type (info, fns, fhandle, n->u.tag, n))
- return false;
+ return FALSE;
return (*fns->tag) (fhandle, n->name);
case DEBUG_OBJECT_VARIABLE:
if (! debug_write_type (info, fns, fhandle, n->u.variable->type,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
return (*fns->variable) (fhandle, n->name, n->u.variable->kind,
n->u.variable->val);
case DEBUG_OBJECT_FUNCTION:
@@ -2560,12 +2396,12 @@ debug_write_name (info, fns, fhandle, n)
case DEBUG_OBJECT_TYPED_CONSTANT:
if (! debug_write_type (info, fns, fhandle, n->u.typed_constant->type,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
return (*fns->typed_constant) (fhandle, n->name,
n->u.typed_constant->val);
default:
abort ();
- return false;
+ return FALSE;
}
/*NOTREACHED*/
}
@@ -2576,13 +2412,10 @@ debug_write_name (info, fns, fhandle, n)
then the name argument is a tag from a DEBUG_KIND_TAGGED type which
points to this one. */
-static boolean
-debug_write_type (info, fns, fhandle, type, name)
- struct debug_handle *info;
- const struct debug_write_fns *fns;
- PTR fhandle;
- struct debug_type *type;
- struct debug_name *name;
+static bfd_boolean
+debug_write_type (struct debug_handle *info,
+ const struct debug_write_fns *fns, void *fhandle,
+ struct debug_type *type, struct debug_name *name)
{
unsigned int i;
int is;
@@ -2604,7 +2437,7 @@ debug_write_type (info, fns, fhandle, type, name)
struct debug_type *real;
unsigned int id;
- real = debug_get_real_type ((PTR) info, type, NULL);
+ real = debug_get_real_type ((void *) info, type, NULL);
if (real == NULL)
return (*fns->empty_type) (fhandle);
id = 0;
@@ -2619,7 +2452,7 @@ debug_write_type (info, fns, fhandle, type, name)
if (! debug_set_class_id (info,
type->u.knamed->name->name,
real))
- return false;
+ return FALSE;
}
id = real->u.kclass->id;
}
@@ -2648,7 +2481,7 @@ debug_write_type (info, fns, fhandle, type, name)
{
case DEBUG_KIND_ILLEGAL:
debug_error (_("debug_write_type: illegal type encountered"));
- return false;
+ return FALSE;
case DEBUG_KIND_INDIRECT:
if (*type->u.kindirect->slot == DEBUG_TYPE_NULL)
return (*fns->empty_type) (fhandle);
@@ -2671,7 +2504,7 @@ debug_write_type (info, fns, fhandle, type, name)
if (type->u.kclass->id <= info->base_id)
{
if (! debug_set_class_id (info, tag, type))
- return false;
+ return FALSE;
}
if (info->mark == type->u.kclass->mark)
@@ -2692,7 +2525,7 @@ debug_write_type (info, fns, fhandle, type, name)
: 0),
type->kind == DEBUG_KIND_STRUCT,
type->size))
- return false;
+ return FALSE;
if (type->u.kclass != NULL
&& type->u.kclass->fields != NULL)
{
@@ -2705,7 +2538,7 @@ debug_write_type (info, fns, fhandle, type, name)
(struct debug_name *) NULL)
|| ! (*fns->struct_field) (fhandle, f->name, f->u.f.bitpos,
f->u.f.bitsize, f->visibility))
- return false;
+ return FALSE;
}
}
return (*fns->end_struct_type) (fhandle);
@@ -2721,13 +2554,13 @@ debug_write_type (info, fns, fhandle, type, name)
case DEBUG_KIND_POINTER:
if (! debug_write_type (info, fns, fhandle, type->u.kpointer,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
return (*fns->pointer_type) (fhandle);
case DEBUG_KIND_FUNCTION:
if (! debug_write_type (info, fns, fhandle,
type->u.kfunction->return_type,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
if (type->u.kfunction->arg_types == NULL)
is = -1;
else
@@ -2736,19 +2569,19 @@ debug_write_type (info, fns, fhandle, type, name)
if (! debug_write_type (info, fns, fhandle,
type->u.kfunction->arg_types[is],
(struct debug_name *) NULL))
- return false;
+ return FALSE;
}
return (*fns->function_type) (fhandle, is,
type->u.kfunction->varargs);
case DEBUG_KIND_REFERENCE:
if (! debug_write_type (info, fns, fhandle, type->u.kreference,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
return (*fns->reference_type) (fhandle);
case DEBUG_KIND_RANGE:
if (! debug_write_type (info, fns, fhandle, type->u.krange->type,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
return (*fns->range_type) (fhandle, type->u.krange->lower,
type->u.krange->upper);
case DEBUG_KIND_ARRAY:
@@ -2757,14 +2590,14 @@ debug_write_type (info, fns, fhandle, type, name)
|| ! debug_write_type (info, fns, fhandle,
type->u.karray->range_type,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
return (*fns->array_type) (fhandle, type->u.karray->lower,
type->u.karray->upper,
type->u.karray->stringp);
case DEBUG_KIND_SET:
if (! debug_write_type (info, fns, fhandle, type->u.kset->type,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
return (*fns->set_type) (fhandle, type->u.kset->bitstringp);
case DEBUG_KIND_OFFSET:
if (! debug_write_type (info, fns, fhandle, type->u.koffset->base_type,
@@ -2772,13 +2605,13 @@ debug_write_type (info, fns, fhandle, type, name)
|| ! debug_write_type (info, fns, fhandle,
type->u.koffset->target_type,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
return (*fns->offset_type) (fhandle);
case DEBUG_KIND_METHOD:
if (! debug_write_type (info, fns, fhandle,
type->u.kmethod->return_type,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
if (type->u.kmethod->arg_types == NULL)
is = -1;
else
@@ -2787,14 +2620,14 @@ debug_write_type (info, fns, fhandle, type, name)
if (! debug_write_type (info, fns, fhandle,
type->u.kmethod->arg_types[is],
(struct debug_name *) NULL))
- return false;
+ return FALSE;
}
if (type->u.kmethod->domain_type != NULL)
{
if (! debug_write_type (info, fns, fhandle,
type->u.kmethod->domain_type,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
}
return (*fns->method_type) (fhandle,
type->u.kmethod->domain_type != NULL,
@@ -2803,12 +2636,12 @@ debug_write_type (info, fns, fhandle, type, name)
case DEBUG_KIND_CONST:
if (! debug_write_type (info, fns, fhandle, type->u.kconst,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
return (*fns->const_type) (fhandle);
case DEBUG_KIND_VOLATILE:
if (! debug_write_type (info, fns, fhandle, type->u.kvolatile,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
return (*fns->volatile_type) (fhandle);
case DEBUG_KIND_NAMED:
return debug_write_type (info, fns, fhandle, type->u.knamed->type,
@@ -2818,19 +2651,16 @@ debug_write_type (info, fns, fhandle, type, name)
type->u.knamed->name);
default:
abort ();
- return false;
+ return FALSE;
}
}
/* Write out a class type. */
-static boolean
-debug_write_class_type (info, fns, fhandle, type, tag)
- struct debug_handle *info;
- const struct debug_write_fns *fns;
- PTR fhandle;
- struct debug_type *type;
- const char *tag;
+static bfd_boolean
+debug_write_class_type (struct debug_handle *info,
+ const struct debug_write_fns *fns, void *fhandle,
+ struct debug_type *type, const char *tag)
{
unsigned int i;
unsigned int id;
@@ -2846,7 +2676,7 @@ debug_write_class_type (info, fns, fhandle, type, tag)
if (type->u.kclass->id <= info->base_id)
{
if (! debug_set_class_id (info, tag, type))
- return false;
+ return FALSE;
}
if (info->mark == type->u.kclass->mark)
@@ -2866,7 +2696,7 @@ debug_write_class_type (info, fns, fhandle, type, tag)
{
if (! debug_write_type (info, fns, fhandle, vptrbase,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
}
}
@@ -2875,7 +2705,7 @@ debug_write_class_type (info, fns, fhandle, type, tag)
type->size,
vptrbase != NULL,
vptrbase == type))
- return false;
+ return FALSE;
if (type->u.kclass != NULL)
{
@@ -2888,19 +2718,19 @@ debug_write_class_type (info, fns, fhandle, type, tag)
f = type->u.kclass->fields[i];
if (! debug_write_type (info, fns, fhandle, f->type,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
if (f->static_member)
{
if (! (*fns->class_static_member) (fhandle, f->name,
f->u.s.physname,
f->visibility))
- return false;
+ return FALSE;
}
else
{
if (! (*fns->struct_field) (fhandle, f->name, f->u.f.bitpos,
f->u.f.bitsize, f->visibility))
- return false;
+ return FALSE;
}
}
}
@@ -2914,10 +2744,10 @@ debug_write_class_type (info, fns, fhandle, type, tag)
b = type->u.kclass->baseclasses[i];
if (! debug_write_type (info, fns, fhandle, b->type,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
if (! (*fns->class_baseclass) (fhandle, b->bitpos, b->virtual,
b->visibility))
- return false;
+ return FALSE;
}
}
@@ -2930,7 +2760,7 @@ debug_write_class_type (info, fns, fhandle, type, tag)
m = type->u.kclass->methods[i];
if (! (*fns->class_start_method) (fhandle, m->name))
- return false;
+ return FALSE;
for (j = 0; m->variants[j] != NULL; j++)
{
struct debug_method_variant *v;
@@ -2940,11 +2770,11 @@ debug_write_class_type (info, fns, fhandle, type, tag)
{
if (! debug_write_type (info, fns, fhandle, v->context,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
}
if (! debug_write_type (info, fns, fhandle, v->type,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
if (v->voffset != VOFFSET_STATIC_METHOD)
{
if (! (*fns->class_method_variant) (fhandle, v->physname,
@@ -2953,7 +2783,7 @@ debug_write_class_type (info, fns, fhandle, type, tag)
v->volatilep,
v->voffset,
v->context != NULL))
- return false;
+ return FALSE;
}
else
{
@@ -2962,11 +2792,11 @@ debug_write_class_type (info, fns, fhandle, type, tag)
v->visibility,
v->constp,
v->volatilep))
- return false;
+ return FALSE;
}
}
if (! (*fns->class_end_method) (fhandle))
- return false;
+ return FALSE;
}
}
}
@@ -2976,41 +2806,38 @@ debug_write_class_type (info, fns, fhandle, type, tag)
/* Write out information for a function. */
-static boolean
-debug_write_function (info, fns, fhandle, name, linkage, function)
- struct debug_handle *info;
- const struct debug_write_fns *fns;
- PTR fhandle;
- const char *name;
- enum debug_object_linkage linkage;
- struct debug_function *function;
+static bfd_boolean
+debug_write_function (struct debug_handle *info,
+ const struct debug_write_fns *fns, void *fhandle,
+ const char *name, enum debug_object_linkage linkage,
+ struct debug_function *function)
{
struct debug_parameter *p;
struct debug_block *b;
if (! debug_write_linenos (info, fns, fhandle, function->blocks->start))
- return false;
+ return FALSE;
if (! debug_write_type (info, fns, fhandle, function->return_type,
(struct debug_name *) NULL))
- return false;
+ return FALSE;
if (! (*fns->start_function) (fhandle, name,
linkage == DEBUG_LINKAGE_GLOBAL))
- return false;
+ return FALSE;
for (p = function->parameters; p != NULL; p = p->next)
{
if (! debug_write_type (info, fns, fhandle, p->type,
(struct debug_name *) NULL)
|| ! (*fns->function_parameter) (fhandle, p->name, p->kind, p->val))
- return false;
+ return FALSE;
}
for (b = function->blocks; b != NULL; b = b->next)
{
if (! debug_write_block (info, fns, fhandle, b))
- return false;
+ return FALSE;
}
return (*fns->end_function) (fhandle);
@@ -3018,25 +2845,23 @@ debug_write_function (info, fns, fhandle, name, linkage, function)
/* Write out information for a block. */
-static boolean
-debug_write_block (info, fns, fhandle, block)
- struct debug_handle *info;
- const struct debug_write_fns *fns;
- PTR fhandle;
- struct debug_block *block;
+static bfd_boolean
+debug_write_block (struct debug_handle *info,
+ const struct debug_write_fns *fns, void *fhandle,
+ struct debug_block *block)
{
struct debug_name *n;
struct debug_block *b;
if (! debug_write_linenos (info, fns, fhandle, block->start))
- return false;
+ return FALSE;
/* I can't see any point to writing out a block with no local
variables, so we don't bother, except for the top level block. */
if (block->locals != NULL || block->parent == NULL)
{
if (! (*fns->start_block) (fhandle, block->start))
- return false;
+ return FALSE;
}
if (block->locals != NULL)
@@ -3044,36 +2869,34 @@ debug_write_block (info, fns, fhandle, block)
for (n = block->locals->list; n != NULL; n = n->next)
{
if (! debug_write_name (info, fns, fhandle, n))
- return false;
+ return FALSE;
}
}
for (b = block->children; b != NULL; b = b->next)
{
if (! debug_write_block (info, fns, fhandle, b))
- return false;
+ return FALSE;
}
if (! debug_write_linenos (info, fns, fhandle, block->end))
- return false;
+ return FALSE;
if (block->locals != NULL || block->parent == NULL)
{
if (! (*fns->end_block) (fhandle, block->end))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Write out line number information up to ADDRESS. */
-static boolean
-debug_write_linenos (info, fns, fhandle, address)
- struct debug_handle *info;
- const struct debug_write_fns *fns;
- PTR fhandle;
- bfd_vma address;
+static bfd_boolean
+debug_write_linenos (struct debug_handle *info,
+ const struct debug_write_fns *fns, void *fhandle,
+ bfd_vma address)
{
while (info->current_write_lineno != NULL)
{
@@ -3088,12 +2911,12 @@ debug_write_linenos (info, fns, fhandle, address)
break;
if (l->addrs[info->current_write_lineno_index] >= address)
- return true;
+ return TRUE;
if (! (*fns->lineno) (fhandle, l->file->filename,
l->linenos[info->current_write_lineno_index],
l->addrs[info->current_write_lineno_index]))
- return false;
+ return FALSE;
++info->current_write_lineno_index;
}
@@ -3102,7 +2925,7 @@ debug_write_linenos (info, fns, fhandle, address)
info->current_write_lineno_index = 0;
}
- return true;
+ return TRUE;
}
/* Get the ID number for a class. If during the same call to
@@ -3110,11 +2933,9 @@ debug_write_linenos (info, fns, fhandle, address)
name, we use the same ID. This type of things happens because the
same struct will be defined by multiple compilation units. */
-static boolean
-debug_set_class_id (info, tag, type)
- struct debug_handle *info;
- const char *tag;
- struct debug_type *type;
+static bfd_boolean
+debug_set_class_id (struct debug_handle *info, const char *tag,
+ struct debug_type *type)
{
struct debug_class_type *c;
struct debug_class_id *l;
@@ -3127,7 +2948,7 @@ debug_set_class_id (info, tag, type)
c = type->u.kclass;
if (c->id > info->base_id)
- return true;
+ return TRUE;
for (l = info->id_list; l != NULL; l = l->next)
{
@@ -3150,7 +2971,7 @@ debug_set_class_id (info, tag, type)
if (debug_type_samep (info, l->type, type))
{
c->id = l->type->u.kclass->id;
- return true;
+ return TRUE;
}
}
@@ -3168,42 +2989,40 @@ debug_set_class_id (info, tag, type)
l->next = info->id_list;
info->id_list = l;
- return true;
+ return TRUE;
}
/* See if two types are the same. At this point, we don't care about
tags and the like. */
-static boolean
-debug_type_samep (info, t1, t2)
- struct debug_handle *info;
- struct debug_type *t1;
- struct debug_type *t2;
+static bfd_boolean
+debug_type_samep (struct debug_handle *info, struct debug_type *t1,
+ struct debug_type *t2)
{
struct debug_type_compare_list *l;
struct debug_type_compare_list top;
- boolean ret;
+ bfd_boolean ret;
if (t1 == NULL)
return t2 == NULL;
if (t2 == NULL)
- return false;
+ return FALSE;
while (t1->kind == DEBUG_KIND_INDIRECT)
{
t1 = *t1->u.kindirect->slot;
if (t1 == NULL)
- return false;
+ return FALSE;
}
while (t2->kind == DEBUG_KIND_INDIRECT)
{
t2 = *t2->u.kindirect->slot;
if (t2 == NULL)
- return false;
+ return FALSE;
}
if (t1 == t2)
- return true;
+ return TRUE;
/* As a special case, permit a typedef to match a tag, since C++
debugging output will sometimes add a typedef where C debugging
@@ -3217,7 +3036,7 @@ debug_type_samep (info, t1, t2)
if (t1->kind != t2->kind
|| t1->size != t2->size)
- return false;
+ return FALSE;
/* Get rid of the trivial cases first. */
switch (t1->kind)
@@ -3228,7 +3047,7 @@ debug_type_samep (info, t1, t2)
case DEBUG_KIND_FLOAT:
case DEBUG_KIND_COMPLEX:
case DEBUG_KIND_BOOL:
- return true;
+ return TRUE;
case DEBUG_KIND_INT:
return t1->u.kint == t2->u.kint;
}
@@ -3240,7 +3059,7 @@ debug_type_samep (info, t1, t2)
for (l = info->compare_list; l != NULL; l = l->next)
{
if (l->t1 == t1 && l->t2 == t2)
- return true;
+ return TRUE;
}
top.t1 = t1;
@@ -3252,7 +3071,7 @@ debug_type_samep (info, t1, t2)
{
default:
abort ();
- ret = false;
+ ret = FALSE;
break;
case DEBUG_KIND_STRUCT:
@@ -3262,10 +3081,10 @@ debug_type_samep (info, t1, t2)
if (t1->u.kclass == NULL)
ret = t2->u.kclass == NULL;
else if (t2->u.kclass == NULL)
- ret = false;
+ ret = FALSE;
else if (t1->u.kclass->id > info->base_id
&& t1->u.kclass->id == t2->u.kclass->id)
- ret = true;
+ ret = TRUE;
else
ret = debug_class_type_samep (info, t1, t2);
break;
@@ -3274,7 +3093,7 @@ debug_type_samep (info, t1, t2)
if (t1->u.kenum == NULL)
ret = t2->u.kenum == NULL;
else if (t2->u.kenum == NULL)
- ret = false;
+ ret = FALSE;
else
{
const char **pn1, **pn2;
@@ -3309,9 +3128,9 @@ debug_type_samep (info, t1, t2)
t2->u.kfunction->return_type)
|| ((t1->u.kfunction->arg_types == NULL)
!= (t2->u.kfunction->arg_types == NULL)))
- ret = false;
+ ret = FALSE;
else if (t1->u.kfunction->arg_types == NULL)
- ret = true;
+ ret = TRUE;
else
{
struct debug_type **a1, **a2;
@@ -3367,9 +3186,9 @@ debug_type_samep (info, t1, t2)
t2->u.kmethod->domain_type)
|| ((t1->u.kmethod->arg_types == NULL)
!= (t2->u.kmethod->arg_types == NULL)))
- ret = false;
+ ret = FALSE;
else if (t1->u.kmethod->arg_types == NULL)
- ret = true;
+ ret = TRUE;
else
{
struct debug_type **a1, **a2;
@@ -3411,11 +3230,9 @@ debug_type_samep (info, t1, t2)
/* See if two classes are the same. This is a subroutine of
debug_type_samep. */
-static boolean
-debug_class_type_samep (info, t1, t2)
- struct debug_handle *info;
- struct debug_type *t1;
- struct debug_type *t2;
+static bfd_boolean
+debug_class_type_samep (struct debug_handle *info, struct debug_type *t1,
+ struct debug_type *t2)
{
struct debug_class_type *c1, *c2;
@@ -3426,7 +3243,7 @@ debug_class_type_samep (info, t1, t2)
|| (c1->baseclasses == NULL) != (c2->baseclasses == NULL)
|| (c1->methods == NULL) != (c2->methods == NULL)
|| (c1->vptrbase == NULL) != (c2->vptrbase == NULL))
- return false;
+ return FALSE;
if (c1->fields != NULL)
{
@@ -3443,17 +3260,17 @@ debug_class_type_samep (info, t1, t2)
if (f1->name[0] != f2->name[0]
|| f1->visibility != f2->visibility
|| f1->static_member != f2->static_member)
- return false;
+ return FALSE;
if (f1->static_member)
{
if (strcmp (f1->u.s.physname, f2->u.s.physname) != 0)
- return false;
+ return FALSE;
}
else
{
if (f1->u.f.bitpos != f2->u.f.bitpos
|| f1->u.f.bitsize != f2->u.f.bitsize)
- return false;
+ return FALSE;
}
/* We do the checks which require function calls last. We
don't require that the types of fields have the same
@@ -3461,20 +3278,20 @@ debug_class_type_samep (info, t1, t2)
typedefs and we really don't care. */
if (strcmp (f1->name, f2->name) != 0
|| ! debug_type_samep (info,
- debug_get_real_type ((PTR) info,
+ debug_get_real_type ((void *) info,
f1->type, NULL),
- debug_get_real_type ((PTR) info,
+ debug_get_real_type ((void *) info,
f2->type, NULL)))
- return false;
+ return FALSE;
}
if (*pf1 != NULL || *pf2 != NULL)
- return false;
+ return FALSE;
}
if (c1->vptrbase != NULL)
{
if (! debug_type_samep (info, c1->vptrbase, c2->vptrbase))
- return false;
+ return FALSE;
}
if (c1->baseclasses != NULL)
@@ -3493,10 +3310,10 @@ debug_class_type_samep (info, t1, t2)
|| b1->virtual != b2->virtual
|| b1->visibility != b2->visibility
|| ! debug_type_samep (info, b1->type, b2->type))
- return false;
+ return FALSE;
}
if (*pb1 != NULL || *pb2 != NULL)
- return false;
+ return FALSE;
}
if (c1->methods != NULL)
@@ -3514,7 +3331,7 @@ debug_class_type_samep (info, t1, t2)
if (m1->name[0] != m2->name[0]
|| strcmp (m1->name, m2->name) != 0
|| (m1->variants == NULL) != (m2->variants == NULL))
- return false;
+ return FALSE;
if (m1->variants == NULL)
{
struct debug_method_variant **pv1, **pv2;
@@ -3535,21 +3352,21 @@ debug_class_type_samep (info, t1, t2)
|| (v1->context == NULL) != (v2->context == NULL)
|| strcmp (v1->physname, v2->physname) != 0
|| ! debug_type_samep (info, v1->type, v2->type))
- return false;
+ return FALSE;
if (v1->context != NULL)
{
if (! debug_type_samep (info, v1->context,
v2->context))
- return false;
+ return FALSE;
}
}
if (*pv1 != NULL || *pv2 != NULL)
- return false;
+ return FALSE;
}
}
if (*pm1 != NULL || *pm2 != NULL)
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
diff --git a/contrib/binutils/binutils/debug.h b/contrib/binutils/binutils/debug.h
index c439be3..3331e0b 100644
--- a/contrib/binutils/binutils/debug.h
+++ b/contrib/binutils/binutils/debug.h
@@ -1,5 +1,5 @@
/* debug.h -- Describe generic debugging information.
- Copyright 1995, 1996 Free Software Foundation, Inc.
+ Copyright 1995, 1996, 2002, 2003 Free Software Foundation, Inc.
Written by Ian Lance Taylor <ian@cygnus.com>.
This file is part of GNU Binutils.
@@ -25,7 +25,7 @@
/* This header file describes a generic debugging information format.
We may eventually have readers which convert different formats into
this generic format, and writers which write it out. The initial
- impetus for this was writing a convertor from stabs to HP IEEE-695
+ impetus for this was writing a converter from stabs to HP IEEE-695
debugging format. */
/* Different kinds of types. */
@@ -169,126 +169,126 @@ struct debug_write_fns
{
/* This is called at the start of each new compilation unit with the
name of the main file in the new unit. */
- boolean (*start_compilation_unit) PARAMS ((PTR, const char *));
+ bfd_boolean (*start_compilation_unit) (void *, const char *);
/* This is called at the start of each source file within a
compilation unit, before outputting any global information for
that file. The argument is the name of the file. */
- boolean (*start_source) PARAMS ((PTR, const char *));
+ bfd_boolean (*start_source) (void *, const char *);
/* Each writer must keep a stack of types. */
/* Push an empty type onto the type stack. This type can appear if
there is a reference to a type which is never defined. */
- boolean (*empty_type) PARAMS ((PTR));
+ bfd_boolean (*empty_type) (void *);
/* Push a void type onto the type stack. */
- boolean (*void_type) PARAMS ((PTR));
+ bfd_boolean (*void_type) (void *);
/* Push an integer type onto the type stack, given the size and
whether it is unsigned. */
- boolean (*int_type) PARAMS ((PTR, unsigned int, boolean));
+ bfd_boolean (*int_type) (void *, unsigned int, bfd_boolean);
/* Push a floating type onto the type stack, given the size. */
- boolean (*float_type) PARAMS ((PTR, unsigned int));
+ bfd_boolean (*float_type) (void *, unsigned int);
/* Push a complex type onto the type stack, given the size. */
- boolean (*complex_type) PARAMS ((PTR, unsigned int));
+ bfd_boolean (*complex_type) (void *, unsigned int);
- /* Push a boolean type onto the type stack, given the size. */
- boolean (*bool_type) PARAMS ((PTR, unsigned int));
+ /* Push a bfd_boolean type onto the type stack, given the size. */
+ bfd_boolean (*bool_type) (void *, unsigned int);
/* Push an enum type onto the type stack, given the tag, a NULL
terminated array of names and the associated values. If there is
no tag, the tag argument will be NULL. If this is an undefined
enum, the names and values arguments will be NULL. */
- boolean (*enum_type) PARAMS ((PTR, const char *, const char **,
- bfd_signed_vma *));
+ bfd_boolean (*enum_type)
+ (void *, const char *, const char **, bfd_signed_vma *);
/* Pop the top type on the type stack, and push a pointer to that
type onto the type stack. */
- boolean (*pointer_type) PARAMS ((PTR));
+ bfd_boolean (*pointer_type) (void *);
/* Push a function type onto the type stack. The second argument
indicates the number of argument types that have been pushed onto
the stack. If the number of argument types is passed as -1, then
the argument types of the function are unknown, and no types have
- been pushed onto the stack. The third argument is true if the
+ been pushed onto the stack. The third argument is TRUE if the
function takes a variable number of arguments. The return type
of the function is pushed onto the type stack below the argument
types, if any. */
- boolean (*function_type) PARAMS ((PTR, int, boolean));
+ bfd_boolean (*function_type) (void *, int, bfd_boolean);
/* Pop the top type on the type stack, and push a reference to that
type onto the type stack. */
- boolean (*reference_type) PARAMS ((PTR));
+ bfd_boolean (*reference_type) (void *);
/* Pop the top type on the type stack, and push a range of that type
with the given lower and upper bounds onto the type stack. */
- boolean (*range_type) PARAMS ((PTR, bfd_signed_vma, bfd_signed_vma));
+ bfd_boolean (*range_type) (void *, bfd_signed_vma, bfd_signed_vma);
/* Push an array type onto the type stack. The top type on the type
stack is the range, and the next type on the type stack is the
element type. These should be popped before the array type is
pushed. The arguments are the lower bound, the upper bound, and
whether the array is a string. */
- boolean (*array_type) PARAMS ((PTR, bfd_signed_vma, bfd_signed_vma,
- boolean));
+ bfd_boolean (*array_type)
+ (void *, bfd_signed_vma, bfd_signed_vma, bfd_boolean);
/* Pop the top type on the type stack, and push a set of that type
onto the type stack. The argument indicates whether this set is
a bitstring. */
- boolean (*set_type) PARAMS ((PTR, boolean));
+ bfd_boolean (*set_type) (void *, bfd_boolean);
/* Push an offset type onto the type stack. The top type on the
type stack is the target type, and the next type on the type
stack is the base type. These should be popped before the offset
type is pushed. */
- boolean (*offset_type) PARAMS ((PTR));
+ bfd_boolean (*offset_type) (void *);
/* Push a method type onto the type stack. If the second argument
- is true, the top type on the stack is the class to which the
+ is TRUE, the top type on the stack is the class to which the
method belongs; otherwise, the class must be determined by the
class to which the method is attached. The third argument is the
number of argument types; these are pushed onto the type stack in
reverse order (the first type popped is the last argument to the
method). A value of -1 for the third argument means that no
- argument information is available. The fourth argument is true
+ argument information is available. The fourth argument is TRUE
if the function takes a variable number of arguments. The next
type on the type stack below the domain and the argument types is
the return type of the method. All these types must be popped,
and then the method type must be pushed. */
- boolean (*method_type) PARAMS ((PTR, boolean, int, boolean));
+ bfd_boolean (*method_type) (void *, bfd_boolean, int, bfd_boolean);
/* Pop the top type off the type stack, and push a const qualified
version of that type onto the type stack. */
- boolean (*const_type) PARAMS ((PTR));
+ bfd_boolean (*const_type) (void *);
/* Pop the top type off the type stack, and push a volatile
qualified version of that type onto the type stack. */
- boolean (*volatile_type) PARAMS ((PTR));
+ bfd_boolean (*volatile_type) (void *);
/* Start building a struct. This is followed by calls to the
struct_field function, and finished by a call to the
end_struct_type function. The second argument is the tag; this
will be NULL if there isn't one. If the second argument is NULL,
the third argument is a constant identifying this struct for use
- with tag_type. The fourth argument is true for a struct, false
+ with tag_type. The fourth argument is TRUE for a struct, FALSE
for a union. The fifth argument is the size. If this is an
undefined struct or union, the size will be 0 and struct_field
will not be called before end_struct_type is called. */
- boolean (*start_struct_type) PARAMS ((PTR, const char *, unsigned int,
- boolean, unsigned int));
+ bfd_boolean (*start_struct_type)
+ (void *, const char *, unsigned int, bfd_boolean, unsigned int);
/* Add a field to the struct type currently being built. The type
of the field should be popped off the type stack. The arguments
are the name, the bit position, the bit size (may be zero if the
field is not packed), and the visibility. */
- boolean (*struct_field) PARAMS ((PTR, const char *, bfd_vma, bfd_vma,
- enum debug_visibility));
+ bfd_boolean (*struct_field)
+ (void *, const char *, bfd_vma, bfd_vma, enum debug_visibility);
/* Finish building a struct, and push it onto the type stack. */
- boolean (*end_struct_type) PARAMS ((PTR));
+ bfd_boolean (*end_struct_type) (void *);
/* Start building a class. This is followed by calls to several
functions: struct_field, class_static_member, class_baseclass,
@@ -296,27 +296,27 @@ struct debug_write_fns
class_static_method_variant, and class_end_method. The class is
finished by a call to end_class_type. The first five arguments
are the same as for start_struct_type. The sixth argument is
- true if there is a virtual function table; if there is, the
- seventh argument is true if the virtual function table can be
- found in the type itself, and is false if the type of the object
+ TRUE if there is a virtual function table; if there is, the
+ seventh argument is TRUE if the virtual function table can be
+ found in the type itself, and is FALSE if the type of the object
holding the virtual function table should be popped from the type
stack. */
- boolean (*start_class_type) PARAMS ((PTR, const char *, unsigned int,
- boolean, unsigned int, boolean,
- boolean));
+ bfd_boolean (*start_class_type)
+ (void *, const char *, unsigned int, bfd_boolean, unsigned int,
+ bfd_boolean, bfd_boolean);
/* Add a static member to the class currently being built. The
arguments are the field name, the physical name, and the
visibility. The type must be popped off the type stack. */
- boolean (*class_static_member) PARAMS ((PTR, const char *, const char *,
- enum debug_visibility));
+ bfd_boolean (*class_static_member)
+ (void *, const char *, const char *, enum debug_visibility);
/* Add a baseclass to the class currently being built. The type of
the baseclass must be popped off the type stack. The arguments
are the bit position, whether the class is virtual, and the
visibility. */
- boolean (*class_baseclass) PARAMS ((PTR, bfd_vma, boolean,
- enum debug_visibility));
+ bfd_boolean (*class_baseclass)
+ (void *, bfd_vma, bfd_boolean, enum debug_visibility);
/* Start adding a method to the class currently being built. This
is followed by calls to class_method_variant and
@@ -324,7 +324,7 @@ struct debug_write_fns
method which take different arguments. The method is finished
with a call to class_end_method. The argument is the method
name. */
- boolean (*class_start_method) PARAMS ((PTR, const char *));
+ bfd_boolean (*class_start_method) (void *, const char *);
/* Describe a variant to the class method currently being built.
The type of the variant must be popped off the type stack. The
@@ -333,28 +333,27 @@ struct debug_write_fns
const, whether the variant is volatile, the offset in the virtual
function table, and whether the context is on the type stack
(below the variant type). */
- boolean (*class_method_variant) PARAMS ((PTR, const char *,
- enum debug_visibility,
- boolean, boolean,
- bfd_vma, boolean));
+ bfd_boolean (*class_method_variant)
+ (void *, const char *, enum debug_visibility, bfd_boolean,
+ bfd_boolean, bfd_vma, bfd_boolean);
/* Describe a static variant to the class method currently being
built. The arguments are the same as for class_method_variant,
except that the last two arguments are omitted. The type of the
variant must be popped off the type stack. */
- boolean (*class_static_method_variant) PARAMS ((PTR, const char *,
- enum debug_visibility,
- boolean, boolean));
+ bfd_boolean (*class_static_method_variant)
+ (void *, const char *, enum debug_visibility, bfd_boolean,
+ bfd_boolean);
/* Finish describing a class method. */
- boolean (*class_end_method) PARAMS ((PTR));
+ bfd_boolean (*class_end_method) (void *);
/* Finish describing a class, and push it onto the type stack. */
- boolean (*end_class_type) PARAMS ((PTR));
+ bfd_boolean (*end_class_type) (void *);
/* Push a type on the stack which was given a name by an earlier
call to typdef. */
- boolean (*typedef_type) PARAMS ((PTR, const char *));
+ bfd_boolean (*typedef_type) (void *, const char *);
/* Push a tagged type on the stack which was defined earlier. If
the second argument is not NULL, the type was defined by a call
@@ -365,58 +364,58 @@ struct debug_write_fns
for a struct (class) being defined, in between the call to
start_struct_type (start_class_type) and the call to
end_struct_type (end_class_type). */
- boolean (*tag_type) PARAMS ((PTR, const char *, unsigned int,
- enum debug_type_kind));
+ bfd_boolean (*tag_type)
+ (void *, const char *, unsigned int, enum debug_type_kind);
/* Pop the type stack, and typedef it to the given name. */
- boolean (*typdef) PARAMS ((PTR, const char *));
+ bfd_boolean (*typdef) (void *, const char *);
/* Pop the type stack, and declare it as a tagged struct or union or
enum or whatever. The tag passed down here is redundant, since
was also passed when enum_type, start_struct_type, or
start_class_type was called. */
- boolean (*tag) PARAMS ((PTR, const char *));
+ bfd_boolean (*tag) (void *, const char *);
/* This is called to record a named integer constant. */
- boolean (*int_constant) PARAMS ((PTR, const char *, bfd_vma));
+ bfd_boolean (*int_constant) (void *, const char *, bfd_vma);
/* This is called to record a named floating point constant. */
- boolean (*float_constant) PARAMS ((PTR, const char *, double));
+ bfd_boolean (*float_constant) (void *, const char *, double);
/* This is called to record a typed integer constant. The type is
popped off the type stack. */
- boolean (*typed_constant) PARAMS ((PTR, const char *, bfd_vma));
+ bfd_boolean (*typed_constant) (void *, const char *, bfd_vma);
/* This is called to record a variable. The type is popped off the
type stack. */
- boolean (*variable) PARAMS ((PTR, const char *, enum debug_var_kind,
- bfd_vma));
+ bfd_boolean (*variable)
+ (void *, const char *, enum debug_var_kind, bfd_vma);
/* Start writing out a function. The return type must be popped off
- the stack. The boolean is true if the function is global. This
+ the stack. The bfd_boolean is TRUE if the function is global. This
is followed by calls to function_parameter, followed by block
information. */
- boolean (*start_function) PARAMS ((PTR, const char *, boolean));
+ bfd_boolean (*start_function) (void *, const char *, bfd_boolean);
/* Record a function parameter for the current function. The type
must be popped off the stack. */
- boolean (*function_parameter) PARAMS ((PTR, const char *,
- enum debug_parm_kind, bfd_vma));
+ bfd_boolean (*function_parameter)
+ (void *, const char *, enum debug_parm_kind, bfd_vma);
/* Start writing out a block. There is at least one top level block
per function. Blocks may be nested. The argument is the
starting address of the block. */
- boolean (*start_block) PARAMS ((PTR, bfd_vma));
+ bfd_boolean (*start_block) (void *, bfd_vma);
/* Finish writing out a block. The argument is the ending address
of the block. */
- boolean (*end_block) PARAMS ((PTR, bfd_vma));
+ bfd_boolean (*end_block) (void *, bfd_vma);
/* Finish writing out a function. */
- boolean (*end_function) PARAMS ((PTR));
+ bfd_boolean (*end_function) (void *);
/* Record line number information for the current compilation unit. */
- boolean (*lineno) PARAMS ((PTR, const char *, unsigned long, bfd_vma));
+ bfd_boolean (*lineno) (void *, const char *, unsigned long, bfd_vma);
};
/* Exported functions. */
@@ -429,87 +428,87 @@ struct debug_write_fns
/* Return a debugging handle. */
-extern PTR debug_init PARAMS ((void));
+extern void *debug_init (void);
/* Set the source filename. This implicitly starts a new compilation
unit. */
-extern boolean debug_set_filename PARAMS ((PTR, const char *));
+extern bfd_boolean debug_set_filename (void *, const char *);
/* Change source files to the given file name. This is used for
include files in a single compilation unit. */
-extern boolean debug_start_source PARAMS ((PTR, const char *));
+extern bfd_boolean debug_start_source (void *, const char *);
/* Record a function definition. This implicitly starts a function
block. The debug_type argument is the type of the return value.
- The boolean indicates whether the function is globally visible.
+ The bfd_boolean indicates whether the function is globally visible.
The bfd_vma is the address of the start of the function. Currently
the parameter types are specified by calls to
debug_record_parameter. */
-extern boolean debug_record_function
- PARAMS ((PTR, const char *, debug_type, boolean, bfd_vma));
+extern bfd_boolean debug_record_function
+ (void *, const char *, debug_type, bfd_boolean, bfd_vma);
/* Record a parameter for the current function. */
-extern boolean debug_record_parameter
- PARAMS ((PTR, const char *, debug_type, enum debug_parm_kind, bfd_vma));
+extern bfd_boolean debug_record_parameter
+ (void *, const char *, debug_type, enum debug_parm_kind, bfd_vma);
/* End a function definition. The argument is the address where the
function ends. */
-extern boolean debug_end_function PARAMS ((PTR, bfd_vma));
+extern bfd_boolean debug_end_function (void *, bfd_vma);
/* Start a block in a function. All local information will be
recorded in this block, until the matching call to debug_end_block.
debug_start_block and debug_end_block may be nested. The argument
is the address at which this block starts. */
-extern boolean debug_start_block PARAMS ((PTR, bfd_vma));
+extern bfd_boolean debug_start_block (void *, bfd_vma);
/* Finish a block in a function. This matches the call to
debug_start_block. The argument is the address at which this block
ends. */
-extern boolean debug_end_block PARAMS ((PTR, bfd_vma));
+extern bfd_boolean debug_end_block (void *, bfd_vma);
/* Associate a line number in the current source file with a given
address. */
-extern boolean debug_record_line PARAMS ((PTR, unsigned long, bfd_vma));
+extern bfd_boolean debug_record_line (void *, unsigned long, bfd_vma);
/* Start a named common block. This is a block of variables that may
move in memory. */
-extern boolean debug_start_common_block PARAMS ((PTR, const char *));
+extern bfd_boolean debug_start_common_block (void *, const char *);
/* End a named common block. */
-extern boolean debug_end_common_block PARAMS ((PTR, const char *));
+extern bfd_boolean debug_end_common_block (void *, const char *);
/* Record a named integer constant. */
-extern boolean debug_record_int_const PARAMS ((PTR, const char *, bfd_vma));
+extern bfd_boolean debug_record_int_const (void *, const char *, bfd_vma);
/* Record a named floating point constant. */
-extern boolean debug_record_float_const PARAMS ((PTR, const char *, double));
+extern bfd_boolean debug_record_float_const (void *, const char *, double);
/* Record a typed constant with an integral value. */
-extern boolean debug_record_typed_const
- PARAMS ((PTR, const char *, debug_type, bfd_vma));
+extern bfd_boolean debug_record_typed_const
+ (void *, const char *, debug_type, bfd_vma);
/* Record a label. */
-extern boolean debug_record_label
- PARAMS ((PTR, const char *, debug_type, bfd_vma));
+extern bfd_boolean debug_record_label
+ (void *, const char *, debug_type, bfd_vma);
/* Record a variable. */
-extern boolean debug_record_variable
- PARAMS ((PTR, const char *, debug_type, enum debug_var_kind, bfd_vma));
+extern bfd_boolean debug_record_variable
+ (void *, const char *, debug_type, enum debug_var_kind, bfd_vma);
/* Make an indirect type. The first argument is a pointer to the
location where the real type will be placed. The second argument
@@ -519,107 +518,105 @@ extern boolean debug_record_variable
referenced before it is defined. */
extern debug_type debug_make_indirect_type
- PARAMS ((PTR, debug_type *, const char *));
+ (void *, debug_type *, const char *);
/* Make a void type. */
-extern debug_type debug_make_void_type PARAMS ((PTR));
+extern debug_type debug_make_void_type (void *);
-/* Make an integer type of a given size. The boolean argument is true
+/* Make an integer type of a given size. The bfd_boolean argument is TRUE
if the integer is unsigned. */
-extern debug_type debug_make_int_type PARAMS ((PTR, unsigned int, boolean));
+extern debug_type debug_make_int_type (void *, unsigned int, bfd_boolean);
/* Make a floating point type of a given size. FIXME: On some
platforms, like an Alpha, you probably need to be able to specify
the format. */
-extern debug_type debug_make_float_type PARAMS ((PTR, unsigned int));
+extern debug_type debug_make_float_type (void *, unsigned int);
/* Make a boolean type of a given size. */
-extern debug_type debug_make_bool_type PARAMS ((PTR, unsigned int));
+extern debug_type debug_make_bool_type (void *, unsigned int);
/* Make a complex type of a given size. */
-extern debug_type debug_make_complex_type PARAMS ((PTR, unsigned int));
+extern debug_type debug_make_complex_type (void *, unsigned int);
-/* Make a structure type. The second argument is true for a struct,
- false for a union. The third argument is the size of the struct.
+/* Make a structure type. The second argument is TRUE for a struct,
+ FALSE for a union. The third argument is the size of the struct.
The fourth argument is a NULL terminated array of fields. */
extern debug_type debug_make_struct_type
- PARAMS ((PTR, boolean, bfd_vma, debug_field *));
+ (void *, bfd_boolean, bfd_vma, debug_field *);
/* Make an object type. The first three arguments after the handle
are the same as for debug_make_struct_type. The next arguments are
a NULL terminated array of base classes, a NULL terminated array of
methods, the type of the object holding the virtual function table
- if it is not this object, and a boolean which is true if this
+ if it is not this object, and a bfd_boolean which is TRUE if this
object has its own virtual function table. */
extern debug_type debug_make_object_type
- PARAMS ((PTR, boolean, bfd_vma, debug_field *, debug_baseclass *,
- debug_method *, debug_type, boolean));
+ (void *, bfd_boolean, bfd_vma, debug_field *, debug_baseclass *,
+ debug_method *, debug_type, bfd_boolean);
/* Make an enumeration type. The arguments are a null terminated
array of strings, and an array of corresponding values. */
extern debug_type debug_make_enum_type
- PARAMS ((PTR, const char **, bfd_signed_vma *));
+ (void *, const char **, bfd_signed_vma *);
/* Make a pointer to a given type. */
-extern debug_type debug_make_pointer_type
- PARAMS ((PTR, debug_type));
+extern debug_type debug_make_pointer_type (void *, debug_type);
/* Make a function type. The second argument is the return type. The
third argument is a NULL terminated array of argument types. The
- fourth argument is true if the function takes a variable number of
+ fourth argument is TRUE if the function takes a variable number of
arguments. If the third argument is NULL, then the argument types
are unknown. */
extern debug_type debug_make_function_type
- PARAMS ((PTR, debug_type, debug_type *, boolean));
+ (void *, debug_type, debug_type *, bfd_boolean);
/* Make a reference to a given type. */
-extern debug_type debug_make_reference_type PARAMS ((PTR, debug_type));
+extern debug_type debug_make_reference_type (void *, debug_type);
/* Make a range of a given type from a lower to an upper bound. */
extern debug_type debug_make_range_type
- PARAMS ((PTR, debug_type, bfd_signed_vma, bfd_signed_vma));
+ (void *, debug_type, bfd_signed_vma, bfd_signed_vma);
/* Make an array type. The second argument is the type of an element
of the array. The third argument is the type of a range of the
array. The fourth and fifth argument are the lower and upper
bounds, respectively (if the bounds are not known, lower should be
- 0 and upper should be -1). The sixth argument is true if this
+ 0 and upper should be -1). The sixth argument is TRUE if this
array is actually a string, as in C. */
extern debug_type debug_make_array_type
- PARAMS ((PTR, debug_type, debug_type, bfd_signed_vma, bfd_signed_vma,
- boolean));
+ (void *, debug_type, debug_type, bfd_signed_vma, bfd_signed_vma,
+ bfd_boolean);
/* Make a set of a given type. For example, a Pascal set type. The
- boolean argument is true if this set is actually a bitstring, as in
+ bfd_boolean argument is TRUE if this set is actually a bitstring, as in
CHILL. */
-extern debug_type debug_make_set_type PARAMS ((PTR, debug_type, boolean));
+extern debug_type debug_make_set_type (void *, debug_type, bfd_boolean);
/* Make a type for a pointer which is relative to an object. The
second argument is the type of the object to which the pointer is
relative. The third argument is the type that the pointer points
to. */
-extern debug_type debug_make_offset_type
- PARAMS ((PTR, debug_type, debug_type));
+extern debug_type debug_make_offset_type (void *, debug_type, debug_type);
/* Make a type for a method function. The second argument is the
return type. The third argument is the domain. The fourth
argument is a NULL terminated array of argument types. The fifth
- argument is true if the function takes a variable number of
+ argument is TRUE if the function takes a variable number of
arguments, in which case the array of argument types indicates the
types of the first arguments. The domain and the argument array
may be NULL, in which case this is a stub method and that
@@ -627,21 +624,21 @@ extern debug_type debug_make_offset_type
the argument types from the mangled name. */
extern debug_type debug_make_method_type
- PARAMS ((PTR, debug_type, debug_type, debug_type *, boolean));
+ (void *, debug_type, debug_type, debug_type *, bfd_boolean);
/* Make a const qualified version of a given type. */
-extern debug_type debug_make_const_type PARAMS ((PTR, debug_type));
+extern debug_type debug_make_const_type (void *, debug_type);
/* Make a volatile qualified version of a given type. */
-extern debug_type debug_make_volatile_type PARAMS ((PTR, debug_type));
+extern debug_type debug_make_volatile_type (void *, debug_type);
/* Make an undefined tagged type. For example, a struct which has
been mentioned, but not defined. */
extern debug_type debug_make_undefined_tagged_type
- PARAMS ((PTR, const char *, enum debug_type_kind));
+ (void *, const char *, enum debug_type_kind);
/* Make a base class for an object. The second argument is the base
class type. The third argument is the bit position of this base
@@ -650,7 +647,7 @@ extern debug_type debug_make_undefined_tagged_type
class. */
extern debug_baseclass debug_make_baseclass
- PARAMS ((PTR, debug_type, bfd_vma, boolean, enum debug_visibility));
+ (void *, debug_type, bfd_vma, bfd_boolean, enum debug_visibility);
/* Make a field for a struct. The second argument is the name. The
third argument is the type of the field. The fourth argument is
@@ -659,8 +656,7 @@ extern debug_baseclass debug_make_baseclass
of the field. */
extern debug_field debug_make_field
- PARAMS ((PTR, const char *, debug_type, bfd_vma, bfd_vma,
- enum debug_visibility));
+ (void *, const char *, debug_type, bfd_vma, bfd_vma, enum debug_visibility);
/* Make a static member of an object. The second argument is the
name. The third argument is the type of the member. The fourth
@@ -669,8 +665,7 @@ extern debug_field debug_make_field
member. */
extern debug_field debug_make_static_member
- PARAMS ((PTR, const char *, debug_type, const char *,
- enum debug_visibility));
+ (void *, const char *, debug_type, const char *, enum debug_visibility);
/* Make a method. The second argument is the name, and the third
argument is a NULL terminated array of method variants. Each
@@ -678,7 +673,7 @@ extern debug_field debug_make_static_member
argument types. */
extern debug_method debug_make_method
- PARAMS ((PTR, const char *, debug_method_variant *));
+ (void *, const char *, debug_method_variant *);
/* Make a method variant. The second argument is the physical name of
the function. The third argument is the type of the function,
@@ -690,109 +685,108 @@ extern debug_method debug_make_method
function context. */
extern debug_method_variant debug_make_method_variant
- PARAMS ((PTR, const char *, debug_type, enum debug_visibility, boolean,
- boolean, bfd_vma, debug_type));
+ (void *, const char *, debug_type, enum debug_visibility, bfd_boolean,
+ bfd_boolean, bfd_vma, debug_type);
/* Make a static method argument. The arguments are the same as for
debug_make_method_variant, except that the last two are omitted
since a static method can not also be virtual. */
extern debug_method_variant debug_make_static_method_variant
- PARAMS ((PTR, const char *, debug_type, enum debug_visibility, boolean,
- boolean));
+ (void *, const char *, debug_type, enum debug_visibility, bfd_boolean,
+ bfd_boolean);
/* Name a type. This returns a new type with an attached name. */
-extern debug_type debug_name_type PARAMS ((PTR, const char *, debug_type));
+extern debug_type debug_name_type (void *, const char *, debug_type);
/* Give a tag to a type, such as a struct or union. This returns a
new type with an attached tag. */
-extern debug_type debug_tag_type PARAMS ((PTR, const char *, debug_type));
+extern debug_type debug_tag_type (void *, const char *, debug_type);
/* Record the size of a given type. */
-extern boolean debug_record_type_size PARAMS ((PTR, debug_type, unsigned int));
+extern bfd_boolean debug_record_type_size (void *, debug_type, unsigned int);
/* Find a named type. */
-extern debug_type debug_find_named_type PARAMS ((PTR, const char *));
+extern debug_type debug_find_named_type (void *, const char *);
/* Find a tagged type. */
extern debug_type debug_find_tagged_type
- PARAMS ((PTR, const char *, enum debug_type_kind));
+ (void *, const char *, enum debug_type_kind);
/* Get the kind of a type. */
-extern enum debug_type_kind debug_get_type_kind PARAMS ((PTR, debug_type));
+extern enum debug_type_kind debug_get_type_kind (void *, debug_type);
/* Get the name of a type. */
-extern const char *debug_get_type_name PARAMS ((PTR, debug_type));
+extern const char *debug_get_type_name (void *, debug_type);
/* Get the size of a type. */
-extern bfd_vma debug_get_type_size PARAMS ((PTR, debug_type));
+extern bfd_vma debug_get_type_size (void *, debug_type);
/* Get the return type of a function or method type. */
-extern debug_type debug_get_return_type PARAMS ((PTR, debug_type));
+extern debug_type debug_get_return_type (void *, debug_type);
/* Get the NULL terminated array of parameter types for a function or
method type (actually, parameter types are not currently stored for
function types). This may be used to determine whether a method
type is a stub method or not. The last argument points to a
- boolean which is set to true if the function takes a variable
+ bfd_boolean which is set to TRUE if the function takes a variable
number of arguments. */
-extern const debug_type *debug_get_parameter_types PARAMS ((PTR,
- debug_type,
- boolean *));
+extern const debug_type *debug_get_parameter_types
+ (void *, debug_type, bfd_boolean *);
/* Get the target type of a pointer or reference or const or volatile
type. */
-extern debug_type debug_get_target_type PARAMS ((PTR, debug_type));
+extern debug_type debug_get_target_type (void *, debug_type);
/* Get the NULL terminated array of fields for a struct, union, or
class. */
-extern const debug_field *debug_get_fields PARAMS ((PTR, debug_type));
+extern const debug_field *debug_get_fields (void *, debug_type);
/* Get the type of a field. */
-extern debug_type debug_get_field_type PARAMS ((PTR, debug_field));
+extern debug_type debug_get_field_type (void *, debug_field);
/* Get the name of a field. */
-extern const char *debug_get_field_name PARAMS ((PTR, debug_field));
+extern const char *debug_get_field_name (void *, debug_field);
/* Get the bit position of a field within the containing structure.
If the field is a static member, this will return (bfd_vma) -1. */
-extern bfd_vma debug_get_field_bitpos PARAMS ((PTR, debug_field));
+extern bfd_vma debug_get_field_bitpos (void *, debug_field);
/* Get the bit size of a field. If the field is a static member, this
will return (bfd_vma) -1. */
-extern bfd_vma debug_get_field_bitsize PARAMS ((PTR, debug_field));
+extern bfd_vma debug_get_field_bitsize (void *, debug_field);
/* Get the visibility of a field. */
-extern enum debug_visibility debug_get_field_visibility
- PARAMS ((PTR, debug_field));
+extern enum debug_visibility debug_get_field_visibility (void *, debug_field);
/* Get the physical name of a field, if it is a static member. If the
field is not a static member, this will return NULL. */
-extern const char *debug_get_field_physname PARAMS ((PTR, debug_field));
+extern const char *debug_get_field_physname (void *, debug_field);
/* Write out the recorded debugging information. This takes a set of
function pointers which are called to do the actual writing. The
- first PTR is the debugging handle. The second PTR is a handle
+ first void * is the debugging handle. The second void * is a handle
which is passed to the functions. */
-extern boolean debug_write PARAMS ((PTR, const struct debug_write_fns *, PTR));
+extern bfd_boolean debug_write
+ (void *, const struct debug_write_fns *, void *);
#endif /* DEBUG_H */
diff --git a/contrib/binutils/binutils/deflex.l b/contrib/binutils/binutils/deflex.l
index 8ff72b8..bdf15d3 100644
--- a/contrib/binutils/binutils/deflex.l
+++ b/contrib/binutils/binutils/deflex.l
@@ -1,28 +1,27 @@
%{/* deflex.l - Lexer for .def files */
-/* Copyright 1995, 1997, 1998, 1999 Free Software Foundation, Inc.
+/* Copyright 1995, 1997, 1998, 1999, 2002, 2003, 2004
+ Free Software Foundation, Inc.
-This file is part of GNU Binutils.
+ This file is part of GNU Binutils.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-/* Contributed by Steve Chamberlain
- sac@cygnus.com
+/* Contributed by Steve Chamberlain: sac@cygnus.com */
-*/
#define DONTDECLARE_MALLOC
#include "libiberty.h"
#include "defparse.h"
@@ -46,6 +45,7 @@ int linenumber;
"BASE" { return BASE;}
"CONSTANT" { return CONSTANT; }
"NONAME" { return NONAME; }
+"PRIVATE" { return PRIVATE; }
"READ" { return READ;}
"WRITE" { return WRITE;}
"EXECUTE" { return EXECUTE;}
@@ -61,7 +61,7 @@ int linenumber;
[0-9][x0-9A-Fa-f]* { yylval.number = strtol (yytext,0,0);
return NUMBER; }
-[A-Za-z$:\-\_?][A-Za-z0-9/$:\-\_@?]* {
+(@)?[A-Za-z$:\-\_?][A-Za-z0-9/$:\-\_@?]* {
yylval.id = xstrdup (yytext);
return ID;
}
@@ -89,5 +89,5 @@ int linenumber;
%%
#ifndef yywrap
/* Needed for lex, though not flex. */
-int yywrap() { return 1; }
+int yywrap(void) { return 1; }
#endif
diff --git a/contrib/binutils/binutils/dep-in.sed b/contrib/binutils/binutils/dep-in.sed
index 0981dfc..aeb22a1 100644
--- a/contrib/binutils/binutils/dep-in.sed
+++ b/contrib/binutils/binutils/dep-in.sed
@@ -8,6 +8,7 @@ s!@BFDDIR@!$(BFDDIR)!g
s!@TOPDIR@/bfd!$(BFDDIR)!g
s!@SRCDIR@/!!g
s!@OBJDIR@/!!g
+s! \.\./intl/libintl\.h!!g
s/\\\n */ /g
diff --git a/contrib/binutils/binutils/dlltool.c b/contrib/binutils/binutils/dlltool.c
index 9a1afbc..5f921ae 100644
--- a/contrib/binutils/binutils/dlltool.c
+++ b/contrib/binutils/binutils/dlltool.c
@@ -1,5 +1,5 @@
/* dlltool.c -- tool to generate stuff for PE style DLLs
- Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
+ Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -20,8 +20,7 @@
02111-1307, USA. */
-/*
- This program allows you to build the files necessary to create
+/* This program allows you to build the files necessary to create
DLLs to run on a system which understands PE format image files.
(eg, Windows NT)
@@ -50,7 +49,7 @@
EXPORTS ( ( ( <name1> [ = <name2> ] )
| ( <name1> = <module-name> . <external-name>))
- [ @ <integer> ] [ NONAME ] [CONSTANT] [DATA] ) *
+ [ @ <integer> ] [ NONAME ] [CONSTANT] [DATA] [PRIVATE] ) *
Declares name1 as an exported symbol from the
DLL, with optional ordinal number <integer>.
Or declares name1 as an alias (forward) of the function <external-name>
@@ -61,7 +60,7 @@
Declares that <external-name> or the exported function whoes ordinal number
is <integer> is to be imported from the file <module-name>. If
<internal-name> is specified then this is the name that the imported
- function will be refered to in the body of the DLL.
+ function will be refereed to in the body of the DLL.
DESCRIPTION <string>
Puts <string> into output .exp file in the .rdata section
@@ -195,8 +194,7 @@
# Build the dll with file1.o, file2.o and the export table
- ld -o thedll.dll thedll.exp file1.o file2.o
- */
+ ld -o thedll.dll thedll.exp file1.o file2.o */
/* .idata section description
@@ -232,8 +230,7 @@
= Array of { short, asciz } entries, one for each imported function.
The `short' is the function's ordinal number.
- .idata$7 = dll name (eg: "kernel32.dll"). (.idata$6 for ppc)
-*/
+ .idata$7 = dll name (eg: "kernel32.dll"). (.idata$6 for ppc). */
/* AIX requires this to be the first thing in the file. */
#ifndef __GNUC__
@@ -270,8 +267,8 @@
#endif
/* Forward references. */
-static char *look_for_prog PARAMS ((const char *, const char *, int));
-static char *deduce_name PARAMS ((const char *));
+static char *look_for_prog (const char *, const char *, int);
+static char *deduce_name (const char *);
#ifdef DLLTOOL_MCORE_ELF
static void mcore_elf_cache_filename (char *);
@@ -283,10 +280,10 @@ static void mcore_elf_gen_out_file (void);
#else /* ! HAVE_SYS_WAIT_H */
#if ! defined (_WIN32) || defined (__CYGWIN32__)
#ifndef WIFEXITED
-#define WIFEXITED(w) (((w)&0377) == 0)
+#define WIFEXITED(w) (((w) & 0377) == 0)
#endif
#ifndef WIFSIGNALED
-#define WIFSIGNALED(w) (((w)&0377) != 0177 && ((w)&~0377) == 0)
+#define WIFSIGNALED(w) (((w) & 0377) != 0177 && ((w) & ~0377) == 0)
#endif
#ifndef WTERMSIG
#define WTERMSIG(w) ((w) & 0177)
@@ -327,18 +324,18 @@ static void mcore_elf_gen_out_file (void);
typedef struct ifunct
{
- char *name; /* name of function being imported */
- int ord; /* two-byte ordinal value associated with function */
+ char * name; /* Name of function being imported. */
+ int ord; /* Two-byte ordinal value associated with function. */
struct ifunct *next;
} ifunctype;
typedef struct iheadt
{
- char *dllname; /* name of dll file imported from */
- long nfuncs; /* number of functions in list */
- struct ifunct *funchead; /* first function in list */
- struct ifunct *functail; /* last function in list */
- struct iheadt *next; /* next dll file in list */
+ char *dllname; /* Name of dll file imported from. */
+ long nfuncs; /* Number of functions in list. */
+ struct ifunct *funchead; /* First function in list. */
+ struct ifunct *functail; /* Last function in list. */
+ struct iheadt *next; /* Next dll file in list. */
} iheadtype;
/* Structure containing all import information as defined in .def file
@@ -349,6 +346,8 @@ static iheadtype *import_list = NULL;
static char *as_name = NULL;
static char * as_flags = "";
+static char *tmp_prefix;
+
static int no_idata4;
static int no_idata5;
static char *exp_name;
@@ -361,20 +360,20 @@ static int add_indirect = 0;
static int add_underscore = 0;
static int dontdeltemps = 0;
-/* True if we should export all symbols. Otherwise, we only export
+/* TRUE if we should export all symbols. Otherwise, we only export
symbols listed in .drectve sections or in the def file. */
-static boolean export_all_symbols;
+static bfd_boolean export_all_symbols;
-/* True if we should exclude the symbols in DEFAULT_EXCLUDES when
+/* TRUE if we should exclude the symbols in DEFAULT_EXCLUDES when
exporting all symbols. */
-static boolean do_default_excludes=true;
+static bfd_boolean do_default_excludes = TRUE;
/* Default symbols to exclude when exporting all the symbols. */
static const char *default_excludes = "DllMain@12,DllEntryPoint@0,impure_ptr";
-/* True if we should add __imp_<SYMBOL> to import libraries for backward
+/* TRUE if we should add __imp_<SYMBOL> to import libraries for backward
compatibility to old Cygwin releases. */
-static boolean create_compat_implib;
+static bfd_boolean create_compat_implib;
static char *def_file;
@@ -428,16 +427,23 @@ static char * mcore_elf_linker_flags = NULL;
#define DRECTVE_SECTION_NAME ".drectve"
#endif
-#define PATHMAX 250 /* What's the right name for this ? */
+#define PATHMAX 250 /* What's the right name for this ? */
+
+char *tmp_asm_buf;
+char *tmp_head_s_buf;
+char *tmp_head_o_buf;
+char *tmp_tail_s_buf;
+char *tmp_tail_o_buf;
+char *tmp_stub_buf;
-#define TMP_ASM "dc.s"
-#define TMP_HEAD_S "dh.s"
-#define TMP_HEAD_O "dh.o"
-#define TMP_TAIL_S "dt.s"
-#define TMP_TAIL_O "dt.o"
-#define TMP_STUB "ds"
+#define TMP_ASM dlltmp (&tmp_asm_buf, "%sc.s")
+#define TMP_HEAD_S dlltmp (&tmp_head_s_buf, "%sh.s")
+#define TMP_HEAD_O dlltmp (&tmp_head_o_buf, "%sh.o")
+#define TMP_TAIL_S dlltmp (&tmp_tail_s_buf, "%st.s")
+#define TMP_TAIL_O dlltmp (&tmp_tail_o_buf, "%st.o")
+#define TMP_STUB dlltmp (&tmp_stub_buf, "%ss")
-/* This bit of assemly does jmp * .... */
+/* This bit of assembly does jmp * .... */
static const unsigned char i386_jtab[] =
{
0xff, 0x25, 0x00, 0x00, 0x00, 0x00, 0x90, 0x90
@@ -487,11 +493,11 @@ static const unsigned char mcore_le_jtab[] =
0x00, 0x00, 0x00, 0x00 /* <address> */
};
-/* This is the glue sequence for PowerPC PE. There is a */
-/* tocrel16-tocdefn reloc against the first instruction. */
-/* We also need a IMGLUE reloc against the glue function */
-/* to restore the toc saved by the third instruction in */
-/* the glue. */
+/* This is the glue sequence for PowerPC PE. There is a
+ tocrel16-tocdefn reloc against the first instruction.
+ We also need a IMGLUE reloc against the glue function
+ to restore the toc saved by the third instruction in
+ the glue. */
static const unsigned char ppc_jtab[] =
{
0x00, 0x00, 0x62, 0x81, /* lwz r11,0(r2) */
@@ -504,8 +510,8 @@ static const unsigned char ppc_jtab[] =
};
#ifdef DLLTOOL_PPC
-/* the glue instruction, picks up the toc from the stw in */
-/* the above code: "lwz r2,4(r1)" */
+/* The glue instruction, picks up the toc from the stw in
+ the above code: "lwz r2,4(r1)". */
static bfd_vma ppc_glue_insn = 0x80410004;
#endif
@@ -526,8 +532,8 @@ struct mac
const char *how_bfd_target;
enum bfd_architecture how_bfd_arch;
const unsigned char *how_jtab;
- int how_jtab_size; /* size of the jtab entry */
- int how_jtab_roff; /* offset into it for the ind 32 reloc into idata 5 */
+ int how_jtab_size; /* Size of the jtab entry. */
+ int how_jtab_roff; /* Offset into it for the ind 32 reloc into idata 5. */
};
static const struct mac
@@ -637,10 +643,11 @@ typedef struct export
const char *internal_name;
int ordinal;
int constant;
- int noname;
+ int noname; /* Don't put name in image file. */
+ int private; /* Don't put reference in import lib. */
int data;
int hint;
- int forward; /* number of forward label, 0 means no forward */
+ int forward; /* Number of forward label, 0 means no forward. */
struct export *next;
}
export_type;
@@ -655,52 +662,78 @@ struct string_list
static struct string_list *excludes;
-static const char *rvaafter PARAMS ((int));
-static const char *rvabefore PARAMS ((int));
-static const char *asm_prefix PARAMS ((int));
-static void process_def_file PARAMS ((const char *));
-static void new_directive PARAMS ((char *));
-static void append_import PARAMS ((const char *, const char *, int));
-static void run PARAMS ((const char *, char *));
-static void scan_drectve_symbols PARAMS ((bfd *));
-static void scan_filtered_symbols PARAMS ((bfd *, PTR, long, unsigned int));
-static void add_excludes PARAMS ((const char *));
-static boolean match_exclude PARAMS ((const char *));
-static void set_default_excludes PARAMS ((void));
-static long filter_symbols PARAMS ((bfd *, PTR, long, unsigned int));
-static void scan_all_symbols PARAMS ((bfd *));
-static void scan_open_obj_file PARAMS ((bfd *));
-static void scan_obj_file PARAMS ((const char *));
-static void dump_def_info PARAMS ((FILE *));
-static int sfunc PARAMS ((const void *, const void *));
-static void flush_page PARAMS ((FILE *, long *, int, int));
-static void gen_def_file PARAMS ((void));
-static void generate_idata_ofile PARAMS ((FILE *));
-static void assemble_file PARAMS ((const char *, const char *));
-static void gen_exp_file PARAMS ((void));
-static const char *xlate PARAMS ((const char *));
+static const char *rvaafter (int);
+static const char *rvabefore (int);
+static const char *asm_prefix (int);
+static void process_def_file (const char *);
+static void new_directive (char *);
+static void append_import (const char *, const char *, int);
+static void run (const char *, char *);
+static void scan_drectve_symbols (bfd *);
+static void scan_filtered_symbols (bfd *, void *, long, unsigned int);
+static void add_excludes (const char *);
+static bfd_boolean match_exclude (const char *);
+static void set_default_excludes (void);
+static long filter_symbols (bfd *, void *, long, unsigned int);
+static void scan_all_symbols (bfd *);
+static void scan_open_obj_file (bfd *);
+static void scan_obj_file (const char *);
+static void dump_def_info (FILE *);
+static int sfunc (const void *, const void *);
+static void flush_page (FILE *, long *, int, int);
+static void gen_def_file (void);
+static void generate_idata_ofile (FILE *);
+static void assemble_file (const char *, const char *);
+static void gen_exp_file (void);
+static const char *xlate (const char *);
#if 0
-static void dump_iat PARAMS ((FILE *, export_type *));
+static void dump_iat (FILE *, export_type *);
#endif
-static char *make_label PARAMS ((const char *, const char *));
-static bfd *make_one_lib_file PARAMS ((export_type *, int));
-static bfd *make_head PARAMS ((void));
-static bfd *make_tail PARAMS ((void));
-static void gen_lib_file PARAMS ((void));
-static int pfunc PARAMS ((const void *, const void *));
-static int nfunc PARAMS ((const void *, const void *));
-static void remove_null_names PARAMS ((export_type **));
-static void dtab PARAMS ((export_type **));
-static void process_duplicates PARAMS ((export_type **));
-static void fill_ordinals PARAMS ((export_type **));
-static int alphafunc PARAMS ((const void *, const void *));
-static void mangle_defs PARAMS ((void));
-static void usage PARAMS ((FILE *, int));
-static void inform PARAMS ((const char *, ...));
+static char *make_label (const char *, const char *);
+static char *make_imp_label (const char *, const char *);
+static bfd *make_one_lib_file (export_type *, int);
+static bfd *make_head (void);
+static bfd *make_tail (void);
+static void gen_lib_file (void);
+static int pfunc (const void *, const void *);
+static int nfunc (const void *, const void *);
+static void remove_null_names (export_type **);
+static void dtab (export_type **);
+static void process_duplicates (export_type **);
+static void fill_ordinals (export_type **);
+static int alphafunc (const void *, const void *);
+static void mangle_defs (void);
+static void usage (FILE *, int);
+static void inform (const char *, ...);
+
+static char *
+prefix_encode (char *start, unsigned code)
+{
+ static char alpha[26] = "abcdefghijklmnopqrstuvwxyz";
+ static char buf[32];
+ char *p;
+ strcpy (buf, start);
+ p = strchr (buf, '\0');
+ do
+ *p++ = alpha[code % sizeof (alpha)];
+ while ((code /= sizeof (alpha)) != 0);
+ *p = '\0';
+ return buf;
+}
+static char *
+dlltmp (char **buf, const char *fmt)
+{
+ if (!*buf)
+ {
+ *buf = malloc (strlen (tmp_prefix) + 64);
+ sprintf (*buf, fmt, tmp_prefix);
+ }
+ return *buf;
+}
static void
-inform VPARAMS ((const char *message, ...))
+inform VPARAMS ((const char * message, ...))
{
VA_OPEN (args, message);
VA_FIXEDARG (args, const char *, message);
@@ -714,8 +747,7 @@ inform VPARAMS ((const char *message, ...))
}
static const char *
-rvaafter (machine)
- int machine;
+rvaafter (int machine)
{
switch (machine)
{
@@ -739,8 +771,7 @@ rvaafter (machine)
}
static const char *
-rvabefore (machine)
- int machine;
+rvabefore (int machine)
{
switch (machine)
{
@@ -764,8 +795,7 @@ rvabefore (machine)
}
static const char *
-asm_prefix (machine)
- int machine;
+asm_prefix (int machine)
{
switch (machine)
{
@@ -789,17 +819,17 @@ asm_prefix (machine)
return "";
}
-#define ASM_BYTE mtable[machine].how_byte
-#define ASM_SHORT mtable[machine].how_short
+#define ASM_BYTE mtable[machine].how_byte
+#define ASM_SHORT mtable[machine].how_short
#define ASM_LONG mtable[machine].how_long
#define ASM_TEXT mtable[machine].how_asciz
-#define ASM_C mtable[machine].how_comment
-#define ASM_JUMP mtable[machine].how_jump
+#define ASM_C mtable[machine].how_comment
+#define ASM_JUMP mtable[machine].how_jump
#define ASM_GLOBAL mtable[machine].how_global
#define ASM_SPACE mtable[machine].how_space
#define ASM_ALIGN_SHORT mtable[machine].how_align_short
-#define ASM_RVA_BEFORE rvabefore(machine)
-#define ASM_RVA_AFTER rvaafter(machine)
+#define ASM_RVA_BEFORE rvabefore(machine)
+#define ASM_RVA_AFTER rvaafter(machine)
#define ASM_PREFIX asm_prefix(machine)
#define ASM_ALIGN_LONG mtable[machine].how_align_long
#define HOW_BFD_READ_TARGET 0 /* always default*/
@@ -813,8 +843,7 @@ asm_prefix (machine)
static char **oav;
static void
-process_def_file (name)
- const char *name;
+process_def_file (const char *name)
{
FILE *f = fopen (name, FOPEN_RT);
@@ -834,25 +863,24 @@ process_def_file (name)
/**********************************************************************/
-/* Communications with the parser */
+/* Communications with the parser. */
-static const char *d_name; /* Arg to NAME or LIBRARY */
-static int d_nfuncs; /* Number of functions exported */
-static int d_named_nfuncs; /* Number of named functions exported */
-static int d_low_ord; /* Lowest ordinal index */
-static int d_high_ord; /* Highest ordinal index */
-static export_type *d_exports; /*list of exported functions */
-static export_type **d_exports_lexically; /* vector of exported functions in alpha order */
-static dlist_type *d_list; /* Descriptions */
-static dlist_type *a_list; /* Stuff to go in directives */
-static int d_nforwards = 0; /* Number of forwarded exports */
+static const char *d_name; /* Arg to NAME or LIBRARY. */
+static int d_nfuncs; /* Number of functions exported. */
+static int d_named_nfuncs; /* Number of named functions exported. */
+static int d_low_ord; /* Lowest ordinal index. */
+static int d_high_ord; /* Highest ordinal index. */
+static export_type *d_exports; /* List of exported functions. */
+static export_type **d_exports_lexically; /* Vector of exported functions in alpha order. */
+static dlist_type *d_list; /* Descriptions. */
+static dlist_type *a_list; /* Stuff to go in directives. */
+static int d_nforwards = 0; /* Number of forwarded exports. */
static int d_is_dll;
static int d_is_exe;
int
-yyerror (err)
- const char * err ATTRIBUTE_UNUSED;
+yyerror (const char * err ATTRIBUTE_UNUSED)
{
/* xgettext:c-format */
non_fatal (_("Syntax error in def file %s:%d"), def_file, linenumber);
@@ -861,13 +889,8 @@ yyerror (err)
}
void
-def_exports (name, internal_name, ordinal, noname, constant, data)
- const char *name;
- const char *internal_name;
- int ordinal;
- int noname;
- int constant;
- int data;
+def_exports (const char *name, const char *internal_name, int ordinal,
+ int noname, int constant, int data, int private)
{
struct export *p = (struct export *) xmalloc (sizeof (*p));
@@ -876,6 +899,7 @@ def_exports (name, internal_name, ordinal, noname, constant, data)
p->ordinal = ordinal;
p->constant = constant;
p->noname = noname;
+ p->private = private;
p->data = data;
p->next = d_exports;
d_exports = p;
@@ -889,9 +913,7 @@ def_exports (name, internal_name, ordinal, noname, constant, data)
}
void
-def_name (name, base)
- const char *name;
- int base;
+def_name (const char *name, int base)
{
/* xgettext:c-format */
inform (_("NAME: %s base: %x"), name, base);
@@ -900,17 +922,15 @@ def_name (name, base)
non_fatal (_("Can't have LIBRARY and NAME"));
d_name = name;
- /* if --dllname not provided, use the one in the DEF file.
- FIXME: Is this appropriate for executables? */
+ /* If --dllname not provided, use the one in the DEF file.
+ FIXME: Is this appropriate for executables? */
if (! dll_name)
dll_name = xstrdup (name);
d_is_exe = 1;
}
void
-def_library (name, base)
- const char *name;
- int base;
+def_library (const char *name, int base)
{
/* xgettext:c-format */
inform (_("LIBRARY: %s base: %x"), name, base);
@@ -919,15 +939,14 @@ def_library (name, base)
non_fatal (_("Can't have LIBRARY and NAME"));
d_name = name;
- /* if --dllname not provided, use the one in the DEF file. */
+ /* If --dllname not provided, use the one in the DEF file. */
if (! dll_name)
dll_name = xstrdup (name);
d_is_dll = 1;
}
void
-def_description (desc)
- const char *desc;
+def_description (const char *desc)
{
dlist_type *d = (dlist_type *) xmalloc (sizeof (dlist_type));
d->text = xstrdup (desc);
@@ -936,8 +955,7 @@ def_description (desc)
}
static void
-new_directive (dir)
- char *dir;
+new_directive (char *dir)
{
dlist_type *d = (dlist_type *) xmalloc (sizeof (dlist_type));
d->text = xstrdup (dir);
@@ -946,9 +964,7 @@ new_directive (dir)
}
void
-def_heapsize (reserve, commit)
- int reserve;
- int commit;
+def_heapsize (int reserve, int commit)
{
char b[200];
if (commit > 0)
@@ -959,9 +975,7 @@ def_heapsize (reserve, commit)
}
void
-def_stacksize (reserve, commit)
- int reserve;
- int commit;
+def_stacksize (int reserve, int commit)
{
char b[200];
if (commit > 0)
@@ -975,10 +989,7 @@ def_stacksize (reserve, commit)
import_list. It is used by def_import. */
static void
-append_import (symbol_name, dll_name, func_ordinal)
- const char *symbol_name;
- const char *dll_name;
- int func_ordinal;
+append_import (const char *symbol_name, const char *dll_name, int func_ordinal)
{
iheadtype **pq;
iheadtype *q;
@@ -1042,12 +1053,8 @@ append_import (symbol_name, dll_name, func_ordinal)
present (i.e., not NULL). */
void
-def_import (app_name, module, dllext, entry, ord_val)
- const char *app_name;
- const char *module;
- const char *dllext;
- const char *entry;
- int ord_val;
+def_import (const char *app_name, const char *module, const char *dllext,
+ const char *entry, int ord_val)
{
const char *application_name;
char *buf;
@@ -1073,17 +1080,13 @@ def_import (app_name, module, dllext, entry, ord_val)
}
void
-def_version (major, minor)
- int major;
- int minor;
+def_version (int major, int minor)
{
printf ("VERSION %d.%d\n", major, minor);
}
void
-def_section (name, attr)
- const char *name;
- int attr;
+def_section (const char *name, int attr)
{
char buf[200];
char atts[5];
@@ -1103,16 +1106,14 @@ def_section (name, attr)
}
void
-def_code (attr)
- int attr;
+def_code (int attr)
{
def_section ("CODE", attr);
}
void
-def_data (attr)
- int attr;
+def_data (int attr)
{
def_section ("DATA", attr);
}
@@ -1120,9 +1121,7 @@ def_data (attr)
/**********************************************************************/
static void
-run (what, args)
- const char *what;
- char *args;
+run (const char *what, char *args)
{
char *s;
int pid, wait_status;
@@ -1193,8 +1192,7 @@ run (what, args)
ABFD. Pass each one to def_exports. */
static void
-scan_drectve_symbols (abfd)
- bfd *abfd;
+scan_drectve_symbols (bfd *abfd)
{
asection * s;
int size;
@@ -1250,15 +1248,16 @@ scan_drectve_symbols (abfd)
/* FIXME: The 5th arg is for the `constant' field.
What should it be? Not that it matters since it's not
currently useful. */
- def_exports (c, 0, -1, 0, 0, ! (flags & BSF_FUNCTION));
+ def_exports (c, 0, -1, 0, 0, ! (flags & BSF_FUNCTION), 0);
if (add_stdcall_alias && strchr (c, '@'))
{
- char *exported_name = xstrdup (c);
+ int lead_at = (*c == '@') ;
+ char *exported_name = xstrdup (c + lead_at);
char *atsym = strchr (exported_name, '@');
*atsym = '\0';
/* Note: stdcall alias symbols can never be data. */
- def_exports (exported_name, xstrdup (c), -1, 0, 0, 0);
+ def_exports (exported_name, xstrdup (c), -1, 0, 0, 0, 0);
}
}
else
@@ -1271,11 +1270,8 @@ scan_drectve_symbols (abfd)
symbols to export. */
static void
-scan_filtered_symbols (abfd, minisyms, symcount, size)
- bfd *abfd;
- PTR minisyms;
- long symcount;
- unsigned int size;
+scan_filtered_symbols (bfd *abfd, void *minisyms, long symcount,
+ unsigned int size)
{
asymbol *store;
bfd_byte *from, *fromend;
@@ -1291,7 +1287,7 @@ scan_filtered_symbols (abfd, minisyms, symcount, size)
asymbol *sym;
const char *symbol_name;
- sym = bfd_minisymbol_to_symbol (abfd, false, from, store);
+ sym = bfd_minisymbol_to_symbol (abfd, FALSE, from, store);
if (sym == NULL)
bfd_fatal (bfd_get_filename (abfd));
@@ -1300,15 +1296,16 @@ scan_filtered_symbols (abfd, minisyms, symcount, size)
++symbol_name;
def_exports (xstrdup (symbol_name) , 0, -1, 0, 0,
- ! (sym->flags & BSF_FUNCTION));
+ ! (sym->flags & BSF_FUNCTION), 0);
if (add_stdcall_alias && strchr (symbol_name, '@'))
{
- char *exported_name = xstrdup (symbol_name);
+ int lead_at = (*symbol_name == '@');
+ char *exported_name = xstrdup (symbol_name + lead_at);
char *atsym = strchr (exported_name, '@');
*atsym = '\0';
/* Note: stdcall alias symbols can never be data. */
- def_exports (exported_name, xstrdup (symbol_name), -1, 0, 0, 0);
+ def_exports (exported_name, xstrdup (symbol_name), -1, 0, 0, 0, 0);
}
}
}
@@ -1316,8 +1313,7 @@ scan_filtered_symbols (abfd, minisyms, symcount, size)
/* Add a list of symbols to exclude. */
static void
-add_excludes (new_excludes)
- const char *new_excludes;
+add_excludes (const char *new_excludes)
{
char *local_copy;
char *exclude_string;
@@ -1332,8 +1328,11 @@ add_excludes (new_excludes)
new_exclude = ((struct string_list *)
xmalloc (sizeof (struct string_list)));
new_exclude->string = (char *) xmalloc (strlen (exclude_string) + 2);
- /* FIXME: Is it always right to add a leading underscore? */
- sprintf (new_exclude->string, "_%s", exclude_string);
+ /* Don't add a leading underscore for fastcall symbols. */
+ if (*exclude_string == '@')
+ sprintf (new_exclude->string, "%s", exclude_string);
+ else
+ sprintf (new_exclude->string, "_%s", exclude_string);
new_exclude->next = excludes;
excludes = new_exclude;
@@ -1346,16 +1345,15 @@ add_excludes (new_excludes)
/* See if STRING is on the list of symbols to exclude. */
-static boolean
-match_exclude (string)
- const char *string;
+static bfd_boolean
+match_exclude (const char *string)
{
struct string_list *excl_item;
for (excl_item = excludes; excl_item; excl_item = excl_item->next)
if (strcmp (string, excl_item->string) == 0)
- return true;
- return false;
+ return TRUE;
+ return FALSE;
}
/* Add the default list of symbols to exclude. */
@@ -1369,11 +1367,7 @@ set_default_excludes (void)
/* Choose which symbols to export. */
static long
-filter_symbols (abfd, minisyms, symcount, size)
- bfd *abfd;
- PTR minisyms;
- long symcount;
- unsigned int size;
+filter_symbols (bfd *abfd, void *minisyms, long symcount, unsigned int size)
{
bfd_byte *from, *fromend, *to;
asymbol *store;
@@ -1391,7 +1385,7 @@ filter_symbols (abfd, minisyms, symcount, size)
int keep = 0;
asymbol *sym;
- sym = bfd_minisymbol_to_symbol (abfd, false, (const PTR) from, store);
+ sym = bfd_minisymbol_to_symbol (abfd, FALSE, (const void *) from, store);
if (sym == NULL)
bfd_fatal (bfd_get_filename (abfd));
@@ -1417,11 +1411,10 @@ filter_symbols (abfd, minisyms, symcount, size)
export. */
static void
-scan_all_symbols (abfd)
- bfd *abfd;
+scan_all_symbols (bfd *abfd)
{
long symcount;
- PTR minisyms;
+ void *minisyms;
unsigned int size;
/* Ignore bfds with an import descriptor table. We assume that any
@@ -1437,7 +1430,7 @@ scan_all_symbols (abfd)
return;
}
- symcount = bfd_read_minisymbols (abfd, false, &minisyms, &size);
+ symcount = bfd_read_minisymbols (abfd, FALSE, &minisyms, &size);
if (symcount < 0)
bfd_fatal (bfd_get_filename (abfd));
@@ -1460,23 +1453,21 @@ scan_all_symbols (abfd)
/* Look at the object file to decide which symbols to export. */
static void
-scan_open_obj_file (abfd)
- bfd *abfd;
+scan_open_obj_file (bfd *abfd)
{
if (export_all_symbols)
scan_all_symbols (abfd);
else
scan_drectve_symbols (abfd);
- /* FIXME: we ought to read in and block out the base relocations */
+ /* FIXME: we ought to read in and block out the base relocations. */
/* xgettext:c-format */
inform (_("Done reading %s"), bfd_get_filename (abfd));
}
static void
-scan_obj_file (filename)
- const char *filename;
+scan_obj_file (const char *filename)
{
bfd * f = bfd_openr (filename, 0);
@@ -1519,8 +1510,7 @@ scan_obj_file (filename)
/**********************************************************************/
static void
-dump_def_info (f)
- FILE *f;
+dump_def_info (FILE *f)
{
int i;
export_type *exp;
@@ -1530,38 +1520,33 @@ dump_def_info (f)
fprintf (f, "\n");
for (i = 0, exp = d_exports; exp; i++, exp = exp->next)
{
- fprintf (f, "%s %d = %s %s @ %d %s%s%s\n",
+ fprintf (f, "%s %d = %s %s @ %d %s%s%s%s\n",
ASM_C,
i,
exp->name,
exp->internal_name,
exp->ordinal,
exp->noname ? "NONAME " : "",
+ exp->private ? "PRIVATE " : "",
exp->constant ? "CONSTANT" : "",
exp->data ? "DATA" : "");
}
}
-/* Generate the .exp file */
+/* Generate the .exp file. */
static int
-sfunc (a, b)
- const void *a;
- const void *b;
+sfunc (const void *a, const void *b)
{
return *(const long *) a - *(const long *) b;
}
static void
-flush_page (f, need, page_addr, on_page)
- FILE *f;
- long *need;
- int page_addr;
- int on_page;
+flush_page (FILE *f, long *need, int page_addr, int on_page)
{
int i;
- /* Flush this page */
+ /* Flush this page. */
fprintf (f, "\t%s\t0x%08x\t%s Starting RVA for chunk\n",
ASM_LONG,
page_addr,
@@ -1587,7 +1572,7 @@ flush_page (f, need, page_addr, on_page)
}
static void
-gen_def_file ()
+gen_def_file (void)
{
int i;
export_type *exp;
@@ -1605,23 +1590,28 @@ gen_def_file ()
char *quote = strchr (exp->name, '.') ? "\"" : "";
char *res = cplus_demangle (exp->internal_name, DMGL_ANSI | DMGL_PARAMS);
- if (strcmp (exp->name, exp->internal_name) == 0)
+ if (res)
{
+ fprintf (output_def,";\t%s\n", res);
+ free (res);
+ }
- fprintf (output_def, "\t%s%s%s @ %d%s%s ; %s\n",
+ if (strcmp (exp->name, exp->internal_name) == 0)
+ {
+ fprintf (output_def, "\t%s%s%s @ %d%s%s%s\n",
quote,
exp->name,
quote,
exp->ordinal,
exp->noname ? " NONAME" : "",
- exp->data ? " DATA" : "",
- res ? res : "");
+ exp->private ? "PRIVATE " : "",
+ exp->data ? " DATA" : "");
}
else
{
- char *quote1 = strchr (exp->internal_name, '.') ? "\"" : "";
+ char * quote1 = strchr (exp->internal_name, '.') ? "\"" : "";
/* char *alias = */
- fprintf (output_def, "\t%s%s%s = %s%s%s @ %d%s%s ; %s\n",
+ fprintf (output_def, "\t%s%s%s = %s%s%s @ %d%s%s%s\n",
quote,
exp->name,
quote,
@@ -1630,11 +1620,9 @@ gen_def_file ()
quote1,
exp->ordinal,
exp->noname ? " NONAME" : "",
- exp->data ? " DATA" : "",
- res ? res : "");
+ exp->private ? "PRIVATE " : "",
+ exp->data ? " DATA" : "");
}
- if (res)
- free (res);
}
inform (_("Added exports to output file"));
@@ -1645,8 +1633,7 @@ gen_def_file ()
the file. */
static void
-generate_idata_ofile (filvar)
- FILE *filvar;
+generate_idata_ofile (FILE *filvar)
{
iheadtype *headptr;
ifunctype *funcptr;
@@ -1738,9 +1725,7 @@ generate_idata_ofile (filvar)
/* Assemble the specified file. */
static void
-assemble_file (source, dest)
- const char * source;
- const char * dest;
+assemble_file (const char * source, const char * dest)
{
char * cmd;
@@ -1753,7 +1738,7 @@ assemble_file (source, dest)
}
static void
-gen_exp_file ()
+gen_exp_file (void)
{
FILE *f;
int i;
@@ -1825,9 +1810,15 @@ gen_exp_file ()
}
if (exp->forward == 0)
- fprintf (f, "\t%s%s%s%s\t%s %d\n", ASM_RVA_BEFORE,
- ASM_PREFIX,
- exp->internal_name, ASM_RVA_AFTER, ASM_C, exp->ordinal);
+ {
+ if (exp->internal_name[0] == '@')
+ fprintf (f, "\t%s%s%s\t%s %d\n", ASM_RVA_BEFORE,
+ exp->internal_name, ASM_RVA_AFTER, ASM_C, exp->ordinal);
+ else
+ fprintf (f, "\t%s%s%s%s\t%s %d\n", ASM_RVA_BEFORE,
+ ASM_PREFIX,
+ exp->internal_name, ASM_RVA_AFTER, ASM_C, exp->ordinal);
+ }
else
fprintf (f, "\t%sf%d%s\t%s %d\n", ASM_RVA_BEFORE,
exp->forward, ASM_RVA_AFTER, ASM_C, exp->ordinal);
@@ -1854,14 +1845,14 @@ gen_exp_file ()
fprintf(f,"%s Export Name Table\n", ASM_C);
for (i = 0; (exp = d_exports_lexically[i]); i++)
- if (!exp->noname || show_allnames)
- {
+ {
+ if (!exp->noname || show_allnames)
fprintf (f, "n%d: %s \"%s\"\n",
exp->ordinal, ASM_TEXT, xlate (exp->name));
- if (exp->forward != 0)
- fprintf (f, "f%d: %s \"%s\"\n",
- exp->forward, ASM_TEXT, exp->internal_name);
- }
+ if (exp->forward != 0)
+ fprintf (f, "f%d: %s \"%s\"\n",
+ exp->forward, ASM_TEXT, exp->internal_name);
+ }
if (a_list)
{
@@ -1927,7 +1918,7 @@ gen_exp_file ()
}
}
- /* Dump the reloc section if a base file is provided */
+ /* Dump the reloc section if a base file is provided. */
if (base_file)
{
int addr;
@@ -1956,7 +1947,7 @@ gen_exp_file ()
int dst = 0;
int last = -1;
qsort (copy, num_entries, sizeof (long), sfunc);
- /* Delete duplcates */
+ /* Delete duplicates */
for (src = 0; src < num_entries; src++)
{
if (last != copy[src])
@@ -1987,7 +1978,7 @@ gen_exp_file ()
fclose (f);
- /* assemble the file */
+ /* Assemble the file. */
assemble_file (TMP_ASM, exp_name);
if (dontdeltemps == 0)
@@ -1997,12 +1988,14 @@ gen_exp_file ()
}
static const char *
-xlate (name)
- const char *name;
+xlate (const char *name)
{
- if (add_underscore)
+ int lead_at = (*name == '@');
+
+ if (add_underscore && !lead_at)
{
char *copy = xmalloc (strlen (name) + 2);
+
copy[0] = '_';
strcpy (copy + 1, name);
name = copy;
@@ -2011,6 +2004,8 @@ xlate (name)
if (killat)
{
char *p;
+
+ name += lead_at;
p = strchr (name, '@');
if (p)
*p = 0;
@@ -2023,9 +2018,7 @@ xlate (name)
#if 0
static void
-dump_iat (f, exp)
- FILE *f;
- export_type *exp;
+dump_iat (FILE *f, export_type *exp)
{
if (exp->noname && !show_allnames )
{
@@ -2053,7 +2046,7 @@ typedef struct
asymbol *sym;
asymbol **sympp;
int size;
- unsigned char *data;
+ unsigned char *data;
} sinfo;
#ifndef DLLTOOL_PPC
@@ -2088,8 +2081,8 @@ static sinfo secdata[NSECS] =
#else
-/* Sections numbered to make the order the same as other PowerPC NT */
-/* compilers. This also keeps funny alignment thingies from happening. */
+/* Sections numbered to make the order the same as other PowerPC NT
+ compilers. This also keeps funny alignment thingies from happening. */
#define TEXT 0
#define PDATA 1
#define RDATA 2
@@ -2117,9 +2110,8 @@ static sinfo secdata[NSECS] =
#endif
-/*
-This is what we're trying to make. We generate the imp symbols with
-both single and double underscores, for compatibility.
+/* This is what we're trying to make. We generate the imp symbols with
+ both single and double underscores, for compatibility.
.text
.global _GetFileVersionInfoSizeW@8
@@ -2142,7 +2134,7 @@ ID2: .short 2
.asciz "GetFileVersionInfoSizeW"
-For the PowerPC, here's the variation on the above scheme:
+ For the PowerPC, here's the variation on the above scheme:
# Rather than a simple "jmp *", the code to get to the dll function
# looks like:
@@ -2153,26 +2145,46 @@ For the PowerPC, here's the variation on the above scheme:
stw r2,4(r1)
mtctr r12
lwz r2,4(r11)
- bctr
-*/
+ bctr */
static char *
-make_label (prefix, name)
- const char *prefix;
- const char *name;
+make_label (const char *prefix, const char *name)
{
int len = strlen (ASM_PREFIX) + strlen (prefix) + strlen (name);
char *copy = xmalloc (len +1 );
+
strcpy (copy, ASM_PREFIX);
strcat (copy, prefix);
strcat (copy, name);
return copy;
}
+static char *
+make_imp_label (const char *prefix, const char *name)
+{
+ int len;
+ char *copy;
+
+ if (name[0] == '@')
+ {
+ len = strlen (prefix) + strlen (name);
+ copy = xmalloc (len + 1);
+ strcpy (copy, prefix);
+ strcat (copy, name);
+ }
+ else
+ {
+ len = strlen (ASM_PREFIX) + strlen (prefix) + strlen (name);
+ copy = xmalloc (len + 1);
+ strcpy (copy, prefix);
+ strcat (copy, ASM_PREFIX);
+ strcat (copy, name);
+ }
+ return copy;
+}
+
static bfd *
-make_one_lib_file (exp, i)
- export_type *exp;
- int i;
+make_one_lib_file (export_type *exp, int i)
{
#if 0
{
@@ -2245,7 +2257,7 @@ make_one_lib_file (exp, i)
asymbol * ptrs[NSECS + 4 + EXTRA + 1];
flagword applicable;
- char * outname = xmalloc (10);
+ char * outname = xmalloc (strlen (TMP_STUB) + 10);
int oidx = 0;
@@ -2270,7 +2282,7 @@ make_one_lib_file (exp, i)
applicable = bfd_applicable_section_flags (abfd);
- /* First make symbols for the sections */
+ /* First make symbols for the sections. */
for (i = 0; i < NSECS; i++)
{
sinfo *si = secdata + i;
@@ -2299,12 +2311,12 @@ make_one_lib_file (exp, i)
if (! exp->data)
{
exp_label = bfd_make_empty_symbol (abfd);
- exp_label->name = make_label ("", exp->name);
+ exp_label->name = make_imp_label ("", exp->name);
/* On PowerPC, the function name points to a descriptor in
the rdata section, the first element of which is a
pointer to the code (..function_name), and the second
- points to the .toc */
+ points to the .toc. */
#ifdef DLLTOOL_PPC
if (machine == MPPC)
exp_label->section = secdata[RDATA].sec;
@@ -2328,14 +2340,14 @@ make_one_lib_file (exp, i)
if (create_compat_implib)
{
iname = bfd_make_empty_symbol (abfd);
- iname->name = make_label ("__imp_", exp->name);
+ iname->name = make_imp_label ("___imp", exp->name);
iname->section = secdata[IDATA5].sec;
iname->flags = BSF_GLOBAL;
iname->value = 0;
}
iname2 = bfd_make_empty_symbol (abfd);
- iname2->name = make_label ("_imp__", exp->name);
+ iname2->name = make_imp_label ("__imp_", exp->name);
iname2->section = secdata[IDATA5].sec;
iname2->flags = BSF_GLOBAL;
iname2->value = 0;
@@ -2347,7 +2359,6 @@ make_one_lib_file (exp, i)
iname_lab->flags = 0;
iname_lab->value = 0;
-
iname_pp = ptrs + oidx;
if (create_compat_implib)
ptrs[oidx++] = iname;
@@ -2357,7 +2368,7 @@ make_one_lib_file (exp, i)
ptrs[oidx++] = iname_lab;
#ifdef DLLTOOL_PPC
- /* The symbol refering to the code (.text) */
+ /* The symbol referring to the code (.text). */
{
asymbol *function_name;
@@ -2371,9 +2382,9 @@ make_one_lib_file (exp, i)
ptrs[oidx++] = function_name;
}
- /* The .toc symbol */
+ /* The .toc symbol. */
{
- asymbol *toc_symbol; /* The .toc symbol */
+ asymbol *toc_symbol;
toc_symbol = bfd_make_empty_symbol (abfd);
toc_symbol->name = make_label (".", "toc");
@@ -2432,7 +2443,7 @@ make_one_lib_file (exp, i)
case IDATA4:
case IDATA5:
/* An idata$4 or idata$5 is one word long, and has an
- rva to idata$6 */
+ rva to idata$6. */
si->data = xmalloc (4);
si->size = 4;
@@ -2477,7 +2488,7 @@ make_one_lib_file (exp, i)
break;
case IDATA7:
si->size = 4;
- si->data =xmalloc(4);
+ si->data =xmalloc (4);
memset (si->data, 0, si->size);
rel = xmalloc (sizeof (arelent));
rpp = xmalloc (sizeof (arelent *) * 2);
@@ -2493,16 +2504,16 @@ make_one_lib_file (exp, i)
#ifdef DLLTOOL_PPC
case PDATA:
{
- /* The .pdata section is 5 words long. */
- /* Think of it as: */
- /* struct */
- /* { */
- /* bfd_vma BeginAddress, [0x00] */
- /* EndAddress, [0x04] */
- /* ExceptionHandler, [0x08] */
- /* HandlerData, [0x0c] */
- /* PrologEndAddress; [0x10] */
- /* }; */
+ /* The .pdata section is 5 words long.
+ Think of it as:
+ struct
+ {
+ bfd_vma BeginAddress, [0x00]
+ EndAddress, [0x04]
+ ExceptionHandler, [0x08]
+ HandlerData, [0x0c]
+ PrologEndAddress; [0x10]
+ }; */
/* So this pdata section setups up this as a glue linkage to
a dll routine. There are a number of house keeping things
@@ -2517,15 +2528,14 @@ make_one_lib_file (exp, i)
So we need a total of four relocs for this section.
3. Lastly, the HandlerData field is set to 0x03, to indicate
- that this is a glue routine.
- */
+ that this is a glue routine. */
arelent *imglue, *ba_rel, *ea_rel, *pea_rel;
- /* alignment must be set to 2**2 or you get extra stuff */
+ /* Alignment must be set to 2**2 or you get extra stuff. */
bfd_set_section_alignment(abfd, sec, 2);
si->size = 4 * 5;
- si->data =xmalloc(4 * 5);
+ si->data = xmalloc (si->size);
memset (si->data, 0, si->size);
rpp = xmalloc (sizeof (arelent *) * 5);
rpp[0] = imglue = xmalloc (sizeof (arelent));
@@ -2534,7 +2544,7 @@ make_one_lib_file (exp, i)
rpp[3] = pea_rel = xmalloc (sizeof (arelent));
rpp[4] = 0;
- /* stick the toc reload instruction in the glue reloc */
+ /* Stick the toc reload instruction in the glue reloc. */
bfd_put_32(abfd, ppc_glue_insn, (char *) &imglue->address);
imglue->addend = 0;
@@ -2547,17 +2557,17 @@ make_one_lib_file (exp, i)
ba_rel->howto = bfd_reloc_type_lookup (abfd, BFD_RELOC_32);
ba_rel->sym_ptr_ptr = fn_pp;
- bfd_put_32(abfd, 0x18, si->data + 0x04);
+ bfd_put_32 (abfd, 0x18, si->data + 0x04);
ea_rel->address = 4;
ea_rel->addend = 0;
ea_rel->howto = bfd_reloc_type_lookup (abfd, BFD_RELOC_32);
ea_rel->sym_ptr_ptr = fn_pp;
- /* mark it as glue */
- bfd_put_32(abfd, 0x03, si->data + 0x0c);
+ /* Mark it as glue. */
+ bfd_put_32 (abfd, 0x03, si->data + 0x0c);
- /* mark the prolog end address */
- bfd_put_32(abfd, 0x0D, si->data + 0x10);
+ /* Mark the prolog end address. */
+ bfd_put_32 (abfd, 0x0D, si->data + 0x10);
pea_rel->address = 0x10;
pea_rel->addend = 0;
pea_rel->howto = bfd_reloc_type_lookup (abfd, BFD_RELOC_32);
@@ -2572,9 +2582,7 @@ make_one_lib_file (exp, i)
descriptor consisting of:
1. The address of the code.
2. The address of the appropriate .toc
- We use relocs to build this.
- */
-
+ We use relocs to build this. */
si->size = 8;
si->data = xmalloc (8);
memset (si->data, 0, si->size);
@@ -2605,7 +2613,7 @@ make_one_lib_file (exp, i)
{
bfd_vma vma = 0;
- /* Size up all the sections */
+ /* Size up all the sections. */
for (i = 0; i < NSECS; i++)
{
sinfo *si = secdata + i;
@@ -2616,7 +2624,7 @@ make_one_lib_file (exp, i)
/* vma += si->size;*/
}
}
- /* Write them out */
+ /* Write them out. */
for (i = 0; i < NSECS; i++)
{
sinfo *si = secdata + i;
@@ -2641,7 +2649,7 @@ make_one_lib_file (exp, i)
}
static bfd *
-make_head ()
+make_head (void)
{
FILE *f = fopen (TMP_HEAD_S, FOPEN_WT);
@@ -2700,7 +2708,7 @@ make_head ()
}
static bfd *
-make_tail ()
+make_tail (void)
{
FILE *f = fopen (TMP_TAIL_S, FOPEN_WT);
@@ -2728,8 +2736,7 @@ make_tail ()
would be to mark this section as a comdat type 2 section, so
only one would appear in the final .exe (if our linker supported
comdat, that is) or cause it to be inserted by something else (say
- crt0)
- */
+ crt0). */
fprintf (f, "\t.section .idata$3\n");
fprintf (f, "\t%s\t0\n", ASM_LONG);
@@ -2741,7 +2748,7 @@ make_tail ()
#ifdef DLLTOOL_PPC
/* Other PowerPC NT compilers use idata$6 for the dllname, so I
- do too. Original, huh? */
+ do too. Original, huh? */
fprintf (f, "\t.section .idata$6\n");
#else
fprintf (f, "\t.section .idata$7\n");
@@ -2755,11 +2762,11 @@ make_tail ()
assemble_file (TMP_TAIL_S, TMP_TAIL_O);
- return bfd_openr (TMP_TAIL_O, HOW_BFD_READ_TARGET);
+ return bfd_openr (TMP_TAIL_O, HOW_BFD_READ_TARGET);
}
static void
-gen_lib_file ()
+gen_lib_file (void)
{
int i;
export_type *exp;
@@ -2783,7 +2790,6 @@ gen_lib_file ()
outarch->has_armap = 1;
/* Work out a reasonable size of things to put onto one line. */
-
ar_head = make_head ();
ar_tail = make_tail();
@@ -2792,13 +2798,16 @@ gen_lib_file ()
for (i = 0; (exp = d_exports_lexically[i]); i++)
{
- bfd *n = make_one_lib_file (exp, i);
+ bfd *n;
+ /* Don't add PRIVATE entries to import lib. */
+ if (exp->private)
+ continue;
+ n = make_one_lib_file (exp, i);
n->next = head;
head = n;
}
- /* Now stick them all into the archive */
-
+ /* Now stick them all into the archive. */
ar_head->next = head;
ar_tail->next = ar_head;
head = ar_tail;
@@ -2816,8 +2825,7 @@ gen_lib_file ()
head = n;
}
- /* Delete all the temp files */
-
+ /* Delete all the temp files. */
if (dontdeltemps == 0)
{
unlink (TMP_HEAD_O);
@@ -2830,9 +2838,12 @@ gen_lib_file ()
{
char *name;
- name = (char *) alloca (sizeof TMP_STUB + 10);
- for (i = 0, exp = d_exports; exp; i++, exp = exp->next)
+ name = (char *) alloca (strlen (TMP_STUB) + 10);
+ for (i = 0; (exp = d_exports_lexically[i]); i++)
{
+ /* Don't delete non-existent stubs for PRIVATE entries. */
+ if (exp->private)
+ continue;
sprintf (name, "%s%05d.o", TMP_STUB, i);
if (unlink (name) < 0)
/* xgettext:c-format */
@@ -2843,21 +2854,18 @@ gen_lib_file ()
inform (_("Created lib file"));
}
-/**********************************************************************/
-
/* Run through the information gathered from the .o files and the
- .def file and work out the best stuff */
+ .def file and work out the best stuff. */
+
static int
-pfunc (a, b)
- const void *a;
- const void *b;
+pfunc (const void *a, const void *b)
{
export_type *ap = *(export_type **) a;
export_type *bp = *(export_type **) b;
if (ap->ordinal == bp->ordinal)
return 0;
- /* unset ordinals go to the bottom */
+ /* Unset ordinals go to the bottom. */
if (ap->ordinal == -1)
return 1;
if (bp->ordinal == -1)
@@ -2866,9 +2874,7 @@ pfunc (a, b)
}
static int
-nfunc (a, b)
- const void *a;
- const void *b;
+nfunc (const void *a, const void *b)
{
export_type *ap = *(export_type **) a;
export_type *bp = *(export_type **) b;
@@ -2877,11 +2883,11 @@ nfunc (a, b)
}
static void
-remove_null_names (ptr)
- export_type **ptr;
+remove_null_names (export_type **ptr)
{
int src;
int dst;
+
for (dst = src = 0; src < d_nfuncs; src++)
{
if (ptr[src])
@@ -2894,12 +2900,7 @@ remove_null_names (ptr)
}
static void
-dtab (ptr)
- export_type ** ptr
-#ifndef SACDEBUG
-ATTRIBUTE_UNUSED
-#endif
- ;
+dtab (export_type **ptr ATTRIBUTE_UNUSED)
{
#ifdef SACDEBUG
int i;
@@ -2920,16 +2921,15 @@ ATTRIBUTE_UNUSED
}
static void
-process_duplicates (d_export_vec)
- export_type **d_export_vec;
+process_duplicates (export_type **d_export_vec)
{
int more = 1;
int i;
+
while (more)
{
-
more = 0;
- /* Remove duplicates */
+ /* Remove duplicates. */
qsort (d_export_vec, d_nfuncs, sizeof (export_type *), nfunc);
dtab (d_export_vec);
@@ -2938,7 +2938,6 @@ process_duplicates (d_export_vec)
if (strcmp (d_export_vec[i]->name,
d_export_vec[i + 1]->name) == 0)
{
-
export_type *a = d_export_vec[i];
export_type *b = d_export_vec[i + 1];
@@ -2954,7 +2953,7 @@ process_duplicates (d_export_vec)
fatal (_("Error, duplicate EXPORT with oridinals: %s"),
a->name);
- /* Merge attributes */
+ /* Merge attributes. */
b->ordinal = a->ordinal > 0 ? a->ordinal : b->ordinal;
b->constant |= a->constant;
b->noname |= a->noname;
@@ -2968,18 +2967,14 @@ process_duplicates (d_export_vec)
}
}
-
- /* Count the names */
+ /* Count the names. */
for (i = 0; i < d_nfuncs; i++)
- {
- if (!d_export_vec[i]->noname)
- d_named_nfuncs++;
- }
+ if (!d_export_vec[i]->noname)
+ d_named_nfuncs++;
}
static void
-fill_ordinals (d_export_vec)
- export_type **d_export_vec;
+fill_ordinals (export_type **d_export_vec)
{
int lowest = -1;
int i;
@@ -2988,22 +2983,20 @@ fill_ordinals (d_export_vec)
qsort (d_export_vec, d_nfuncs, sizeof (export_type *), pfunc);
- /* fill in the unset ordinals with ones from our range */
-
+ /* Fill in the unset ordinals with ones from our range. */
ptr = (char *) xmalloc (size);
memset (ptr, 0, size);
- /* Mark in our large vector all the numbers that are taken */
+ /* Mark in our large vector all the numbers that are taken. */
for (i = 0; i < d_nfuncs; i++)
{
if (d_export_vec[i]->ordinal != -1)
{
ptr[d_export_vec[i]->ordinal] = 1;
+
if (lowest == -1 || d_export_vec[i]->ordinal < lowest)
- {
- lowest = d_export_vec[i]->ordinal;
- }
+ lowest = d_export_vec[i]->ordinal;
}
}
@@ -3016,7 +3009,7 @@ fill_ordinals (d_export_vec)
{
if (d_export_vec[i]->ordinal == -1)
{
- register int j;
+ int j;
/* First try within or after any user supplied range. */
for (j = lowest; j < size; j++)
@@ -3041,8 +3034,7 @@ fill_ordinals (d_export_vec)
free (ptr);
- /* And resort */
-
+ /* And resort. */
qsort (d_export_vec, d_nfuncs, sizeof (export_type *), pfunc);
/* Work out the lowest and highest ordinal numbers. */
@@ -3056,9 +3048,7 @@ fill_ordinals (d_export_vec)
}
static int
-alphafunc (av,bv)
- const void *av;
- const void *bv;
+alphafunc (const void *av, const void *bv)
{
const export_type **a = (const export_type **) av;
const export_type **b = (const export_type **) bv;
@@ -3067,28 +3057,24 @@ alphafunc (av,bv)
}
static void
-mangle_defs ()
+mangle_defs (void)
{
- /* First work out the minimum ordinal chosen */
-
+ /* First work out the minimum ordinal chosen. */
export_type *exp;
int i;
int hint = 0;
- export_type **d_export_vec
- = (export_type **) xmalloc (sizeof (export_type *) * d_nfuncs);
+ export_type **d_export_vec = xmalloc (sizeof (export_type *) * d_nfuncs);
inform (_("Processing definitions"));
for (i = 0, exp = d_exports; exp; i++, exp = exp->next)
- {
- d_export_vec[i] = exp;
- }
+ d_export_vec[i] = exp;
process_duplicates (d_export_vec);
fill_ordinals (d_export_vec);
- /* Put back the list in the new order */
+ /* Put back the list in the new order. */
d_exports = 0;
for (i = d_nfuncs - 1; i >= 0; i--)
{
@@ -3096,35 +3082,27 @@ mangle_defs ()
d_exports = d_export_vec[i];
}
- /* Build list in alpha order */
+ /* Build list in alpha order. */
d_exports_lexically = (export_type **)
xmalloc (sizeof (export_type *) * (d_nfuncs + 1));
for (i = 0, exp = d_exports; exp; i++, exp = exp->next)
- {
- d_exports_lexically[i] = exp;
- }
+ d_exports_lexically[i] = exp;
+
d_exports_lexically[i] = 0;
qsort (d_exports_lexically, i, sizeof (export_type *), alphafunc);
- /* Fill exp entries with their hint values */
-
+ /* Fill exp entries with their hint values. */
for (i = 0; i < d_nfuncs; i++)
- {
- if (!d_exports_lexically[i]->noname || show_allnames)
- d_exports_lexically[i]->hint = hint++;
- }
+ if (!d_exports_lexically[i]->noname || show_allnames)
+ d_exports_lexically[i]->hint = hint++;
inform (_("Processed definitions"));
}
-/**********************************************************************/
-
static void
-usage (file, status)
- FILE *file;
- int status;
+usage (FILE *file, int status)
{
/* xgetext:c-format */
fprintf (file, _("Usage %s <option(s)> <object-file(s)>\n"), program_name);
@@ -3151,6 +3129,7 @@ usage (file, status)
fprintf (file, _(" -f --as-flags <flags> Pass <flags> to the assembler.\n"));
fprintf (file, _(" -C --compat-implib Create backward compatible import library.\n"));
fprintf (file, _(" -n --no-delete Keep temp files (repeat for extra preservation).\n"));
+ fprintf (file, _(" -t --temp-prefix <prefix> Use <prefix> to construct temp file names.\n"));
fprintf (file, _(" -v --verbose Be verbose.\n"));
fprintf (file, _(" -V --version Display the program version.\n"));
fprintf (file, _(" -h --help Display this information.\n"));
@@ -3180,7 +3159,7 @@ static const struct option long_options[] =
{"exclude-symbols", required_argument, NULL, OPTION_EXCLUDE_SYMS},
{"no-default-excludes", no_argument, NULL, OPTION_NO_DEFAULT_EXCLUDES},
{"output-lib", required_argument, NULL, 'l'},
- {"def", required_argument, NULL, 'd'}, /* for compatiblity with older versions */
+ {"def", required_argument, NULL, 'd'}, /* for compatibility with older versions */
{"input-def", required_argument, NULL, 'd'},
{"add-underscore", no_argument, NULL, 'U'},
{"kill-at", no_argument, NULL, 'k'},
@@ -3195,15 +3174,14 @@ static const struct option long_options[] =
{"as-flags", required_argument, NULL, 'f'},
{"mcore-elf", required_argument, NULL, 'M'},
{"compat-implib", no_argument, NULL, 'C'},
+ {"temp-prefix", required_argument, NULL, 't'},
{NULL,0,NULL,0}
};
-int main PARAMS ((int, char **));
+int main (int, char **);
int
-main (ac, av)
- int ac;
- char **av;
+main (int ac, char **av)
{
int c;
int i;
@@ -3232,16 +3210,16 @@ main (ac, av)
switch (c)
{
case OPTION_EXPORT_ALL_SYMS:
- export_all_symbols = true;
+ export_all_symbols = TRUE;
break;
case OPTION_NO_EXPORT_ALL_SYMS:
- export_all_symbols = false;
+ export_all_symbols = FALSE;
break;
case OPTION_EXCLUDE_SYMS:
add_excludes (optarg);
break;
case OPTION_NO_DEFAULT_EXCLUDES:
- do_default_excludes = false;
+ do_default_excludes = FALSE;
break;
case 'x':
no_idata4 = 1;
@@ -3252,11 +3230,14 @@ main (ac, av)
case 'S':
as_name = optarg;
break;
+ case 't':
+ tmp_prefix = optarg;
+ break;
case 'f':
as_flags = optarg;
break;
- /* ignored for compatibility */
+ /* Ignored for compatibility. */
case 'u':
break;
case 'a':
@@ -3330,6 +3311,9 @@ main (ac, av)
}
}
+ if (!tmp_prefix)
+ tmp_prefix = prefix_encode ("d", getpid ());
+
for (i = 0; mtable[i].type; i++)
if (strcmp (mtable[i].type, mname) == 0)
break;
@@ -3355,7 +3339,7 @@ main (ac, av)
symbols in the .drectve section. The default excludes are meant
to avoid exporting DLL entry point and Cygwin32 impure_ptr. */
if (! export_all_symbols)
- do_default_excludes = false;
+ do_default_excludes = FALSE;
if (do_default_excludes)
set_default_excludes ();
@@ -3408,10 +3392,7 @@ main (ac, av)
appropriate. */
static char *
-look_for_prog (prog_name, prefix, end_prefix)
- const char *prog_name;
- const char *prefix;
- int end_prefix;
+look_for_prog (const char *prog_name, const char *prefix, int end_prefix)
{
struct stat s;
char *cmd;
@@ -3477,8 +3458,7 @@ look_for_prog (prog_name, prefix, end_prefix)
Returns a dynamically allocated string. */
static char *
-deduce_name (prog_name)
- const char *prog_name;
+deduce_name (const char *prog_name)
{
char *cmd;
char *dash, *slash, *cp;
@@ -3566,21 +3546,21 @@ mcore_elf_gen_out_file (void)
ptr = & fnames;
ds = dyn_string_new (100);
- dyn_string_append (ds, "-r ");
+ dyn_string_append_cstr (ds, "-r ");
if (mcore_elf_linker_flags != NULL)
- dyn_string_append (ds, mcore_elf_linker_flags);
+ dyn_string_append_cstr (ds, mcore_elf_linker_flags);
while (ptr->next != NULL)
{
- dyn_string_append (ds, ptr->filename);
- dyn_string_append (ds, " ");
+ dyn_string_append_cstr (ds, ptr->filename);
+ dyn_string_append_cstr (ds, " ");
ptr = ptr->next;
}
- dyn_string_append (ds, "-o ");
- dyn_string_append (ds, MCORE_ELF_TMP_OBJ);
+ dyn_string_append_cstr (ds, "-o ");
+ dyn_string_append_cstr (ds, MCORE_ELF_TMP_OBJ);
if (mcore_elf_linker == NULL)
mcore_elf_linker = deduce_name ("ld");
@@ -3590,32 +3570,31 @@ mcore_elf_gen_out_file (void)
dyn_string_delete (ds);
/* Step two. Create a .exp file and a .lib file from the temporary file.
- Do this by recursively invoking dlltool....*/
+ Do this by recursively invoking dlltool... */
ds = dyn_string_new (100);
- dyn_string_append (ds, "-S ");
- dyn_string_append (ds, as_name);
+ dyn_string_append_cstr (ds, "-S ");
+ dyn_string_append_cstr (ds, as_name);
- dyn_string_append (ds, " -e ");
- dyn_string_append (ds, MCORE_ELF_TMP_EXP);
- dyn_string_append (ds, " -l ");
- dyn_string_append (ds, MCORE_ELF_TMP_LIB);
- dyn_string_append (ds, " " );
- dyn_string_append (ds, MCORE_ELF_TMP_OBJ);
+ dyn_string_append_cstr (ds, " -e ");
+ dyn_string_append_cstr (ds, MCORE_ELF_TMP_EXP);
+ dyn_string_append_cstr (ds, " -l ");
+ dyn_string_append_cstr (ds, MCORE_ELF_TMP_LIB);
+ dyn_string_append_cstr (ds, " " );
+ dyn_string_append_cstr (ds, MCORE_ELF_TMP_OBJ);
if (verbose)
- dyn_string_append (ds, " -v");
+ dyn_string_append_cstr (ds, " -v");
if (dontdeltemps)
{
- dyn_string_append (ds, " -n");
+ dyn_string_append_cstr (ds, " -n");
if (dontdeltemps > 1)
- dyn_string_append (ds, " -n");
+ dyn_string_append_cstr (ds, " -n");
}
/* XXX - FIME: ought to check/copy other command line options as well. */
-
run (program_name, ds->s);
dyn_string_delete (ds);
@@ -3623,17 +3602,17 @@ mcore_elf_gen_out_file (void)
/* Step four. Feed the .exp and object files to ld -shared to create the dll. */
ds = dyn_string_new (100);
- dyn_string_append (ds, "-shared ");
+ dyn_string_append_cstr (ds, "-shared ");
if (mcore_elf_linker_flags)
- dyn_string_append (ds, mcore_elf_linker_flags);
-
- dyn_string_append (ds, " ");
- dyn_string_append (ds, MCORE_ELF_TMP_EXP);
- dyn_string_append (ds, " ");
- dyn_string_append (ds, MCORE_ELF_TMP_OBJ);
- dyn_string_append (ds, " -o ");
- dyn_string_append (ds, mcore_elf_out_file);
+ dyn_string_append_cstr (ds, mcore_elf_linker_flags);
+
+ dyn_string_append_cstr (ds, " ");
+ dyn_string_append_cstr (ds, MCORE_ELF_TMP_EXP);
+ dyn_string_append_cstr (ds, " ");
+ dyn_string_append_cstr (ds, MCORE_ELF_TMP_OBJ);
+ dyn_string_append_cstr (ds, " -o ");
+ dyn_string_append_cstr (ds, mcore_elf_out_file);
run (mcore_elf_linker, ds->s);
diff --git a/contrib/binutils/binutils/dlltool.h b/contrib/binutils/binutils/dlltool.h
index 29c825d..f488d96 100644
--- a/contrib/binutils/binutils/dlltool.h
+++ b/contrib/binutils/binutils/dlltool.h
@@ -1,5 +1,5 @@
/* dlltool.h -- header file for dlltool
- Copyright 1997, 1998 Free Software Foundation, Inc.
+ Copyright 1997, 1998, 2003, 2004 Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -21,22 +21,22 @@
#include "ansidecl.h"
#include <stdio.h>
-extern void def_code PARAMS ((int));
-extern void def_data PARAMS ((int));
-extern void def_description PARAMS ((const char *));
-extern void def_exports
- PARAMS ((const char *, const char *, int, int, int, int));
-extern void def_heapsize PARAMS ((int, int));
+extern void def_code (int);
+extern void def_data (int);
+extern void def_description (const char *);
+extern void def_exports (const char *, const char *, int, int, int, int, int);
+extern void def_heapsize (int, int);
extern void def_import
- PARAMS ((const char *, const char *, const char *, const char *, int));
-extern void def_library PARAMS ((const char *, int));
-extern void def_name PARAMS ((const char *, int));
-extern void def_section PARAMS ((const char *, int));
-extern void def_stacksize PARAMS ((int, int));
-extern void def_version PARAMS ((int, int));
-extern int yyparse PARAMS ((void));
-extern int yyerror PARAMS ((const char *));
+ (const char *, const char *, const char *, const char *, int);
+extern void def_library (const char *, int);
+extern void def_name (const char *, int);
+extern void def_section (const char *, int);
+extern void def_stacksize (int, int);
+extern void def_version (int, int);
+extern int yyparse (void);
+extern int yyerror (const char *);
+extern int yylex (void);
+
extern int yydebug;
-extern int yylex PARAMS ((void));
extern FILE *yyin;
extern int linenumber;
diff --git a/contrib/binutils/binutils/dllwrap.c b/contrib/binutils/binutils/dllwrap.c
index 4ca5936..e4db7ba 100644
--- a/contrib/binutils/binutils/dllwrap.c
+++ b/contrib/binutils/binutils/dllwrap.c
@@ -1,5 +1,5 @@
/* dllwrap.c -- wrapper for DLLTOOL and GCC to generate PE style DLLs
- Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
Contributed by Mumit Khan (khan@xraylith.wisc.edu).
This file is part of GNU Binutils.
@@ -114,17 +114,17 @@ static int delete_base_file = 1;
static int delete_exp_file = 1;
static int delete_def_file = 1;
-static int run PARAMS ((const char *, char *));
-static char *mybasename PARAMS ((const char *));
-static int strhash PARAMS ((const char *));
-static void usage PARAMS ((FILE *, int));
-static void display PARAMS ((const char *, va_list));
-static void inform PARAMS ((const char *, ...));
-static void warn PARAMS ((const char *, ...));
-static char *look_for_prog PARAMS ((const char *, const char *, int));
-static char *deduce_name PARAMS ((const char *));
-static void delete_temp_files PARAMS ((void));
-static void cleanup_and_exit PARAMS ((int));
+static int run (const char *, char *);
+static char *mybasename (const char *);
+static int strhash (const char *);
+static void usage (FILE *, int);
+static void display (const char *, va_list);
+static void inform (const char *, ...);
+static void warn (const char *, ...);
+static char *look_for_prog (const char *, const char *, int);
+static char *deduce_name (const char *);
+static void delete_temp_files (void);
+static void cleanup_and_exit (int);
/**********************************************************************/
@@ -137,9 +137,7 @@ static void cleanup_and_exit PARAMS ((int));
(hopefully) soon be retired in favor of `ld --shared. */
static void
-display (message, args)
- const char * message;
- va_list args;
+display (const char * message, va_list args)
{
if (program_name != NULL)
fprintf (stderr, "%s: ", program_name);
@@ -180,10 +178,7 @@ warn VPARAMS ((const char *format, ...))
appropriate. */
static char *
-look_for_prog (prog_name, prefix, end_prefix)
- const char *prog_name;
- const char *prefix;
- int end_prefix;
+look_for_prog (const char *prog_name, const char *prefix, int end_prefix)
{
struct stat s;
char *cmd;
@@ -249,8 +244,7 @@ look_for_prog (prog_name, prefix, end_prefix)
Returns a dynamically allocated string. */
static char *
-deduce_name (prog_name)
- const char *prog_name;
+deduce_name (const char *prog_name)
{
char *cmd;
char *dash, *slash, *cp;
@@ -298,7 +292,7 @@ deduce_name (prog_name)
}
static void
-delete_temp_files ()
+delete_temp_files (void)
{
if (delete_base_file && base_file_name)
{
@@ -349,17 +343,14 @@ delete_temp_files ()
}
static void
-cleanup_and_exit (status)
- int status;
+cleanup_and_exit (int status)
{
delete_temp_files ();
exit (status);
}
static int
-run (what, args)
- const char *what;
- char *args;
+run (const char *what, char *args)
{
char *s;
int pid, wait_status, retcode;
@@ -445,8 +436,7 @@ run (what, args)
}
static char *
-mybasename (name)
- const char *name;
+mybasename (const char *name)
{
const char *base = name;
@@ -462,8 +452,7 @@ mybasename (name)
}
static int
-strhash (str)
- const char *str;
+strhash (const char *str)
{
const unsigned char *s;
unsigned long hash;
@@ -488,9 +477,7 @@ strhash (str)
/**********************************************************************/
static void
-usage (file, status)
- FILE *file;
- int status;
+usage (FILE *file, int status)
{
fprintf (file, _("Usage %s <option(s)> <object-file(s)>\n"), program_name);
fprintf (file, _(" Generic options:\n"));
@@ -552,7 +539,7 @@ usage (file, status)
/* DLLTOOL options. */
#define OPTION_NODELETE (OPTION_MNO_CYGWIN + 1)
#define OPTION_DLLNAME (OPTION_NODELETE + 1)
-#define OPTION_NO_IDATA4 (OPTION_DLLNAME + 1)
+#define OPTION_NO_IDATA4 (OPTION_DLLNAME + 1)
#define OPTION_NO_IDATA5 (OPTION_NO_IDATA4 + 1)
#define OPTION_OUTPUT_EXP (OPTION_NO_IDATA5 + 1)
#define OPTION_OUTPUT_DEF (OPTION_OUTPUT_EXP + 1)
@@ -611,12 +598,10 @@ static const struct option long_options[] =
{0, 0, 0, 0}
};
-int main PARAMS ((int, char **));
+int main (int, char **);
int
-main (argc, argv)
- int argc;
- char **argv;
+main (int argc, char **argv)
{
int c;
int i;
diff --git a/contrib/binutils/binutils/doc/Makefile.am b/contrib/binutils/binutils/doc/Makefile.am
index 9db5819..851f205 100644
--- a/contrib/binutils/binutils/doc/Makefile.am
+++ b/contrib/binutils/binutils/doc/Makefile.am
@@ -45,98 +45,98 @@ binutils.info: $(binutils_TEXI) config.texi
# Man page generation from texinfo
addr2line.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Daddr2line < $< > addr2line.pod
+ -$(TEXI2POD) $(MANCONF) -Daddr2line < $(binutils_TEXI) > addr2line.pod
-($(POD2MAN) addr2line.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f addr2line.pod
ar.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dar < $< > ar.pod
+ -$(TEXI2POD) $(MANCONF) -Dar < $(binutils_TEXI) > ar.pod
-($(POD2MAN) ar.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f ar.pod
dlltool.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Ddlltool < $< > dlltool.pod
+ -$(TEXI2POD) $(MANCONF) -Ddlltool < $(binutils_TEXI) > dlltool.pod
-($(POD2MAN) dlltool.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f dlltool.pod
nlmconv.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dnlmconv < $< > nlmconv.pod
+ -$(TEXI2POD) $(MANCONF) -Dnlmconv < $(binutils_TEXI) > nlmconv.pod
-($(POD2MAN) nlmconv.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f nlmconv.pod
nm.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dnm < $< > nm.pod
+ -$(TEXI2POD) $(MANCONF) -Dnm < $(binutils_TEXI) > nm.pod
-($(POD2MAN) nm.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f nm.pod
objcopy.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dobjcopy < $< > objcopy.pod
+ -$(TEXI2POD) $(MANCONF) -Dobjcopy < $(binutils_TEXI) > objcopy.pod
-($(POD2MAN) objcopy.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f objcopy.pod
objdump.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dobjdump < $< > objdump.pod
+ -$(TEXI2POD) $(MANCONF) -Dobjdump < $(binutils_TEXI) > objdump.pod
-($(POD2MAN) objdump.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f objdump.pod
ranlib.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dranlib < $< > ranlib.pod
+ -$(TEXI2POD) $(MANCONF) -Dranlib < $(binutils_TEXI) > ranlib.pod
-($(POD2MAN) ranlib.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f ranlib.pod
readelf.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dreadelf < $< > readelf.pod
+ -$(TEXI2POD) $(MANCONF) -Dreadelf < $(binutils_TEXI) > readelf.pod
-($(POD2MAN) readelf.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f readelf.pod
size.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dsize < $< > size.pod
+ -$(TEXI2POD) $(MANCONF) -Dsize < $(binutils_TEXI) > size.pod
-($(POD2MAN) size.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f size.pod
strings.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dstrings < $< > strings.pod
+ -$(TEXI2POD) $(MANCONF) -Dstrings < $(binutils_TEXI) > strings.pod
-($(POD2MAN) strings.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f strings.pod
strip.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dstrip < $< > strip.pod
+ -$(TEXI2POD) $(MANCONF) -Dstrip < $(binutils_TEXI) > strip.pod
-($(POD2MAN) strip.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f strip.pod
windres.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dwindres < $< > windres.pod
+ -$(TEXI2POD) $(MANCONF) -Dwindres < $(binutils_TEXI) > windres.pod
-($(POD2MAN) windres.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f windres.pod
cxxfilt.man: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dcxxfilt < $< > $(DEMANGLER_NAME).pod
+ -$(TEXI2POD) $(MANCONF) -Dcxxfilt < $(binutils_TEXI) > $(DEMANGLER_NAME).pod
-($(POD2MAN) $(DEMANGLER_NAME).pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f $(DEMANGLER_NAME).pod
diff --git a/contrib/binutils/binutils/doc/Makefile.in b/contrib/binutils/binutils/doc/Makefile.in
index eeef90f..e05f5be 100644
--- a/contrib/binutils/binutils/doc/Makefile.in
+++ b/contrib/binutils/binutils/doc/Makefile.in
@@ -1,4 +1,4 @@
-# Makefile.in generated automatically by automake 1.4-p5 from Makefile.am
+# Makefile.in generated automatically by automake 1.4-p6 from Makefile.am
# Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
@@ -113,7 +113,6 @@ POFILES = @POFILES@
POSUB = @POSUB@
RANLIB = @RANLIB@
STRIP = @STRIP@
-UNDERSCORE = @UNDERSCORE@
USE_INCLUDED_LIBINTL = @USE_INCLUDED_LIBINTL@
USE_NLS = @USE_NLS@
VERSION = @VERSION@
@@ -445,98 +444,98 @@ binutils.info: $(binutils_TEXI) config.texi
# Man page generation from texinfo
addr2line.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Daddr2line < $< > addr2line.pod
+ -$(TEXI2POD) $(MANCONF) -Daddr2line < $(binutils_TEXI) > addr2line.pod
-($(POD2MAN) addr2line.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f addr2line.pod
ar.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dar < $< > ar.pod
+ -$(TEXI2POD) $(MANCONF) -Dar < $(binutils_TEXI) > ar.pod
-($(POD2MAN) ar.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f ar.pod
dlltool.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Ddlltool < $< > dlltool.pod
+ -$(TEXI2POD) $(MANCONF) -Ddlltool < $(binutils_TEXI) > dlltool.pod
-($(POD2MAN) dlltool.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f dlltool.pod
nlmconv.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dnlmconv < $< > nlmconv.pod
+ -$(TEXI2POD) $(MANCONF) -Dnlmconv < $(binutils_TEXI) > nlmconv.pod
-($(POD2MAN) nlmconv.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f nlmconv.pod
nm.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dnm < $< > nm.pod
+ -$(TEXI2POD) $(MANCONF) -Dnm < $(binutils_TEXI) > nm.pod
-($(POD2MAN) nm.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f nm.pod
objcopy.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dobjcopy < $< > objcopy.pod
+ -$(TEXI2POD) $(MANCONF) -Dobjcopy < $(binutils_TEXI) > objcopy.pod
-($(POD2MAN) objcopy.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f objcopy.pod
objdump.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dobjdump < $< > objdump.pod
+ -$(TEXI2POD) $(MANCONF) -Dobjdump < $(binutils_TEXI) > objdump.pod
-($(POD2MAN) objdump.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f objdump.pod
ranlib.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dranlib < $< > ranlib.pod
+ -$(TEXI2POD) $(MANCONF) -Dranlib < $(binutils_TEXI) > ranlib.pod
-($(POD2MAN) ranlib.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f ranlib.pod
readelf.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dreadelf < $< > readelf.pod
+ -$(TEXI2POD) $(MANCONF) -Dreadelf < $(binutils_TEXI) > readelf.pod
-($(POD2MAN) readelf.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f readelf.pod
size.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dsize < $< > size.pod
+ -$(TEXI2POD) $(MANCONF) -Dsize < $(binutils_TEXI) > size.pod
-($(POD2MAN) size.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f size.pod
strings.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dstrings < $< > strings.pod
+ -$(TEXI2POD) $(MANCONF) -Dstrings < $(binutils_TEXI) > strings.pod
-($(POD2MAN) strings.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f strings.pod
strip.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dstrip < $< > strip.pod
+ -$(TEXI2POD) $(MANCONF) -Dstrip < $(binutils_TEXI) > strip.pod
-($(POD2MAN) strip.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f strip.pod
windres.1: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dwindres < $< > windres.pod
+ -$(TEXI2POD) $(MANCONF) -Dwindres < $(binutils_TEXI) > windres.pod
-($(POD2MAN) windres.pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f windres.pod
cxxfilt.man: $(binutils_TEXI)
touch $@
- -$(TEXI2POD) $(MANCONF) -Dcxxfilt < $< > $(DEMANGLER_NAME).pod
+ -$(TEXI2POD) $(MANCONF) -Dcxxfilt < $(binutils_TEXI) > $(DEMANGLER_NAME).pod
-($(POD2MAN) $(DEMANGLER_NAME).pod | sed -e '/^.if n .na/d' > $@.T$$$$ && \
mv -f $@.T$$$$ $@) || (rm -f $@.T$$$$ && exit 1)
rm -f $(DEMANGLER_NAME).pod
diff --git a/contrib/binutils/binutils/doc/addr2line.1 b/contrib/binutils/binutils/doc/addr2line.1
index f343f5d..5808d65 100644
--- a/contrib/binutils/binutils/doc/addr2line.1
+++ b/contrib/binutils/binutils/doc/addr2line.1
@@ -1,4 +1,4 @@
-.\" Automatically generated by Pod::Man v1.3, Pod::Parser v1.13
+.\" Automatically generated by Pod::Man v1.37, Pod::Parser v1.14
.\"
.\" Standard preamble:
.\" ========================================================================
@@ -21,7 +21,6 @@
..
.de Ve \" End verbatim text
.ft R
-
.fi
..
.\" Set up some character translations and predefined strings. \*(-- will
@@ -129,8 +128,7 @@
.\" ========================================================================
.\"
.IX Title "ADDR2LINE 1"
-.TH ADDR2LINE 1 "2002-08-05" "binutils-2.12.91" "GNU Development Tools"
-.UC
+.TH ADDR2LINE 1 "2004-04-09" "binutils-2.14.91" "GNU Development Tools"
.SH "NAME"
addr2line \- convert addresses into file names and line numbers.
.SH "SYNOPSIS"
@@ -221,11 +219,12 @@ Display only the base of each file name.
Info entries for \fIbinutils\fR.
.SH "COPYRIGHT"
.IX Header "COPYRIGHT"
-Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001, 2002 Free Software Foundation, Inc.
+Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000,
+2001, 2002, 2003 Free Software Foundation, Inc.
.PP
Permission is granted to copy, distribute and/or modify this document
under the terms of the \s-1GNU\s0 Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
-section entitled \*(L"\s-1GNU\s0 Free Documentation License\*(R".
+section entitled ``\s-1GNU\s0 Free Documentation License''.
diff --git a/contrib/binutils/binutils/doc/ar.1 b/contrib/binutils/binutils/doc/ar.1
index b17417c..6708cf4 100644
--- a/contrib/binutils/binutils/doc/ar.1
+++ b/contrib/binutils/binutils/doc/ar.1
@@ -1,4 +1,4 @@
-.\" Automatically generated by Pod::Man v1.3, Pod::Parser v1.13
+.\" Automatically generated by Pod::Man v1.37, Pod::Parser v1.14
.\"
.\" Standard preamble:
.\" ========================================================================
@@ -21,7 +21,6 @@
..
.de Ve \" End verbatim text
.ft R
-
.fi
..
.\" Set up some character translations and predefined strings. \*(-- will
@@ -129,8 +128,7 @@
.\" ========================================================================
.\"
.IX Title "AR 1"
-.TH AR 1 "2002-08-05" "binutils-2.12.91" "GNU Development Tools"
-.UC
+.TH AR 1 "2004-04-09" "binutils-2.14.91" "GNU Development Tools"
.SH "NAME"
ar \- create, modify, and extract from archives
.SH "SYNOPSIS"
@@ -229,7 +227,7 @@ index is not updated, even if it already existed; you can use \fBar s\fR or
\&\fBranlib\fR explicitly to update the symbol table index.
.Sp
However, too many different systems assume quick append rebuilds the
-index, so \s-1GNU\s0 ar implements \f(CW\*(C`q\*(C'\fR as a synonym for \f(CW\*(C`r\*(C'\fR.
+index, so \s-1GNU\s0 \fBar\fR implements \fBq\fR as a synonym for \fBr\fR.
.IP "\fBr\fR" 4
.IX Item "r"
Insert the files \fImember\fR... into \fIarchive\fR (with
@@ -368,11 +366,12 @@ which is the default for \s-1AIX\s0 \fBar\fR.
\&\fInm\fR\|(1), \fIranlib\fR\|(1), and the Info entries for \fIbinutils\fR.
.SH "COPYRIGHT"
.IX Header "COPYRIGHT"
-Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001, 2002 Free Software Foundation, Inc.
+Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000,
+2001, 2002, 2003 Free Software Foundation, Inc.
.PP
Permission is granted to copy, distribute and/or modify this document
under the terms of the \s-1GNU\s0 Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
-section entitled \*(L"\s-1GNU\s0 Free Documentation License\*(R".
+section entitled ``\s-1GNU\s0 Free Documentation License''.
diff --git a/contrib/binutils/binutils/doc/binutils.texi b/contrib/binutils/binutils/doc/binutils.texi
index 3006d9e..2e78720 100644
--- a/contrib/binutils/binutils/doc/binutils.texi
+++ b/contrib/binutils/binutils/doc/binutils.texi
@@ -1,6 +1,6 @@
\input texinfo @c -*- Texinfo -*-
@setfilename binutils.info
-@c Copyright 2001, 2002 Free Software Foundation, Inc.
+@c Copyright 2001, 2002, 2003 Free Software Foundation, Inc.
@include config.texi
@@ -29,14 +29,15 @@ END-INFO-DIR-ENTRY
@ifinfo
@c man begin COPYRIGHT
-Copyright @copyright{} 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001, 2002 Free Software Foundation, Inc.
+Copyright @copyright{} 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000,
+2001, 2002, 2003 Free Software Foundation, Inc.
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
-section entitled "GNU Free Documentation License".
+section entitled ``GNU Free Documentation License''.
@c man end
@ignore
@@ -53,7 +54,8 @@ notice identical to this one except for the removal of this paragraph
@c This file documents the GNU binary utilities "ar", "ld", "objcopy",
@c "objdump", "nm", "size", "strings", "strip", "readelf" and "ranlib".
@c
-@c Copyright (C) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001, 2002 Free Software Foundation, Inc.
+@c Copyright (C) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001,
+@c 2002, 2003 Free Software Foundation, Inc.
@c
@c This text may be freely distributed under the terms of the GNU
@c Free Documentation License.
@@ -78,14 +80,15 @@ notice identical to this one except for the removal of this paragraph
@end tex
@vskip 0pt plus 1filll
-Copyright @copyright{} 1991, 92, 93, 94, 95, 96, 97, 1998, 2000, 2001, 2002 Free Software Foundation, Inc.
+Copyright @copyright{} 1991, 92, 93, 94, 95, 96, 97, 1998, 2000, 2001,
+2002, 2003 Free Software Foundation, Inc.
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
- section entitled "GNU Free Documentation License".
+ section entitled ``GNU Free Documentation License''.
@end titlepage
@@ -93,7 +96,7 @@ Copyright @copyright{} 1991, 92, 93, 94, 95, 96, 97, 1998, 2000, 2001, 2002 Free
@top Introduction
@cindex version
-This brief manual contains preliminary documentation for the @sc{gnu} binary
+This brief manual contains documentation for the @sc{gnu} binary
utilities (collectively version @value{VERSION}):
@iftex
@@ -238,7 +241,7 @@ program.
@page
@node ar cmdline
-@section Controlling @command{ar} on the command line
+@section Controlling @command{ar} on the Command Line
@smallexample
@c man begin SYNOPSIS ar
@@ -314,7 +317,7 @@ index is not updated, even if it already existed; you can use @samp{ar s} or
@command{ranlib} explicitly to update the symbol table index.
However, too many different systems assume quick append rebuilds the
-index, so GNU ar implements @code{q} as a synonym for @code{r}.
+index, so @sc{gnu} @command{ar} implements @samp{q} as a synonym for @samp{r}.
@item r
@cindex replacement in archive
@@ -464,7 +467,7 @@ This modifier shows the version number of @command{ar}.
@command{ar} ignores an initial option spelt @samp{-X32_64}, for
compatibility with AIX. The behaviour produced by this option is the
-default for GNU @command{ar}. @command{ar} does not support any of the other
+default for @sc{gnu} @command{ar}. @command{ar} does not support any of the other
@samp{-X} options; in particular, it does not support @option{-X32}
which is the default for AIX @command{ar}.
@@ -477,7 +480,7 @@ nm(1), ranlib(1), and the Info entries for @file{binutils}.
@end ignore
@node ar scripts
-@section Controlling @command{ar} with a script
+@section Controlling @command{ar} with a Script
@smallexample
ar -M [ <@var{script} ]
@@ -716,7 +719,7 @@ object file formats permit more efficient access to small data objects,
such as a global int variable as opposed to a large global array.
@item I
-The symbol is an indirect reference to another symbol. This is a GNU
+The symbol is an indirect reference to another symbol. This is a @sc{gnu}
extension to the a.out object file format which is rarely used.
@item N
@@ -854,7 +857,7 @@ Equivalent to @samp{-f posix}.
@item -S
@itemx --print-size
-Print size of defined symbols for the @code{bsd} output format.
+Print size, not the value, of defined symbols for the @code{bsd} output format.
@item -s
@itemx --print-armap
@@ -871,7 +874,9 @@ last come first.
@item --size-sort
Sort symbols by size. The size is computed as the difference between
the value of the symbol and the value of the symbol with the next higher
-value. The size of the symbol is printed, rather than the value.
+value. If the @code{bsd} output format is used the size of the symbol
+is printed, rather than the value, and @samp{-S} must be used in order
+both size and value to be printed.
@item -t @var{radix}
@itemx --radix=@var{radix}
@@ -927,21 +932,26 @@ objcopy [@option{-F} @var{bfdname}|@option{--target=}@var{bfdname}]
[@option{-I} @var{bfdname}|@option{--input-target=}@var{bfdname}]
[@option{-O} @var{bfdname}|@option{--output-target=}@var{bfdname}]
[@option{-B} @var{bfdarch}|@option{--binary-architecture=}@var{bfdarch}]
- [@option{-S}|@option{--strip-all}] [@option{-g}|@option{--strip-debug}]
+ [@option{-S}|@option{--strip-all}]
+ [@option{-g}|@option{--strip-debug}]
[@option{-K} @var{symbolname}|@option{--keep-symbol=}@var{symbolname}]
[@option{-N} @var{symbolname}|@option{--strip-symbol=}@var{symbolname}]
[@option{-G} @var{symbolname}|@option{--keep-global-symbol=}@var{symbolname}]
[@option{-L} @var{symbolname}|@option{--localize-symbol=}@var{symbolname}]
[@option{-W} @var{symbolname}|@option{--weaken-symbol=}@var{symbolname}]
- [@option{-x}|@option{--discard-all}] [@option{-X}|@option{--discard-locals}]
+ [@option{-w}|@option{--wildcard}]
+ [@option{-x}|@option{--discard-all}]
+ [@option{-X}|@option{--discard-locals}]
[@option{-b} @var{byte}|@option{--byte=}@var{byte}]
[@option{-i} @var{interleave}|@option{--interleave=}@var{interleave}]
[@option{-j} @var{sectionname}|@option{--only-section=}@var{sectionname}]
[@option{-R} @var{sectionname}|@option{--remove-section=}@var{sectionname}]
[@option{-p}|@option{--preserve-dates}]
[@option{--debugging}]
- [@option{--gap-fill=}@var{val}] [@option{--pad-to=}@var{address}]
- [@option{--set-start=}@var{val}] [@option{--adjust-start=}@var{incr}]
+ [@option{--gap-fill=}@var{val}]
+ [@option{--pad-to=}@var{address}]
+ [@option{--set-start=}@var{val}]
+ [@option{--adjust-start=}@var{incr}]
[@option{--change-addresses=}@var{incr}]
[@option{--change-section-address} @var{section}@{=,+,-@}@var{val}]
[@option{--change-section-lma} @var{section}@{=,+,-@}@var{val}]
@@ -950,19 +960,29 @@ objcopy [@option{-F} @var{bfdname}|@option{--target=}@var{bfdname}]
[@option{--set-section-flags} @var{section}=@var{flags}]
[@option{--add-section} @var{sectionname}=@var{filename}]
[@option{--rename-section} @var{oldname}=@var{newname}[,@var{flags}]]
- [@option{--change-leading-char} ] [@option{--remove-leading-char}]
- [@option{--srec-len=}@var{ival} ] [@option{--srec-forceS3}]
- [@option{--redefine-sym} @var{old}=@var{new} ]
+ [@option{--change-leading-char}] [@option{--remove-leading-char}]
+ [@option{--srec-len=}@var{ival}] [@option{--srec-forceS3}]
+ [@option{--redefine-sym} @var{old}=@var{new}]
+ [@option{--redefine-syms=}@var{filename}]
[@option{--weaken}]
[@option{--keep-symbols=}@var{filename}]
[@option{--strip-symbols=}@var{filename}]
[@option{--keep-global-symbols=}@var{filename}]
[@option{--localize-symbols=}@var{filename}]
[@option{--weaken-symbols=}@var{filename}]
- [@option{--alt-machine-code=@var{index}}]
+ [@option{--alt-machine-code=}@var{index}]
+ [@option{--prefix-symbols=}@var{string}]
+ [@option{--prefix-sections=}@var{string}]
+ [@option{--prefix-alloc-sections=}@var{string}]
+ [@option{--add-gnu-debuglink=}@var{path-to-file}]
+ [@option{--only-keep-debug}]
+ [@option{--writable-text}]
+ [@option{--readonly-text}]
+ [@option{--pure}]
+ [@option{--impure}]
[@option{-v}|@option{--verbose}]
[@option{-V}|@option{--version}]
- [@option{--help}]
+ [@option{--help}] [@option{--info}]
@var{infile} [@var{outfile}]
@c man end
@end smallexample
@@ -998,10 +1018,10 @@ use @option{-S} to remove sections containing debugging information. In
some cases @option{-R} will be useful to remove sections which contain
information that is not needed by the binary file.
-Note - @command{objcopy} is not able to change the endianness of its input
-files. If the input format has an endianness, (some formats do not),
+Note---@command{objcopy} is not able to change the endianness of its input
+files. If the input format has an endianness (some formats do not),
@command{objcopy} can only copy the inputs into file formats that have the
-same endianness or which have no endianness (eg @samp{srec}).
+same endianness or which have no endianness (e.g., @samp{srec}).
@c man end
@@ -1060,7 +1080,7 @@ Do not copy relocation and symbol information from the source file.
@item -g
@itemx --strip-debug
-Do not copy debugging symbols from the source file.
+Do not copy debugging symbols or sections from the source file.
@item --strip-unneeded
Strip all symbols that are not needed for relocation processing.
@@ -1090,6 +1110,22 @@ visible externally. This option may be given more than once.
@itemx --weaken-symbol=@var{symbolname}
Make symbol @var{symbolname} weak. This option may be given more than once.
+@item -w
+@itemx --wildcard
+Permit regular expressions in @var{symbolname}s used in other command
+line options. The question mark (?), asterisk (*), backslash (\) and
+square brackets ([]) operators can be used anywhere in the symbol
+name. If the first character of the symbol name is the exclamation
+point (!) then the sense of the switch is reversed for that symbol.
+For example:
+
+@smallexample
+ -w -W !foo -W fo*
+@end smallexample
+
+would cause objcopy to weaken all symbols that start with ``fo''
+except for the symbol ``foo''.
+
@item -x
@itemx --discard-all
Do not copy non-global symbols from the source file.
@@ -1276,6 +1312,12 @@ Change the name of a symbol @var{old}, to @var{new}. This can be useful
when one is trying link two things together for which you have no
source, and there are name collisions.
+@item --redefine-syms=@var{filename}
+Apply @option{--redefine-sym} to each symbol pair "@var{old} @var{new}"
+listed in the file @var{filename}. @var{filename} is simply a flat file,
+with one symbol pair per line. Line comments may be introduced by the hash
+character. This option may be given more than once.
+
@item --weaken
Change all global symbols in the file to be weak. This can be useful
when building an object which will be linked against other objects using
@@ -1319,6 +1361,73 @@ a machine is assigned an official code and the tool-chain adopts the
new code, but other applications still depend on the original code
being used.
+@item --writable-text
+Mark the output text as writable. This option isn't meaningful for all
+object file formats.
+
+@item --readonly-text
+Make the output text write protected. This option isn't meaningful for all
+object file formats.
+
+@item --pure
+Mark the output file as demand paged. This option isn't meaningful for all
+object file formats.
+
+@item --impure
+Mark the output file as impure. This option isn't meaningful for all
+object file formats.
+
+@item --prefix-symbols=@var{string}
+Prefix all symbols in the output file with @var{string}.
+
+@item --prefix-sections=@var{string}
+Prefix all section names in the output file with @var{string}.
+
+@item --prefix-alloc-sections=@var{string}
+Prefix all the names of all allocated sections in the output file with
+@var{string}.
+
+@item --add-gnu-debuglink=@var{path-to-file}
+Creates a .gnu_debuglink section which contains a reference to @var{path-to-file}
+and adds it to the output file.
+
+@item --only-keep-debug
+Strip a file, removing any sections that would be stripped by
+@option{--strip-debug} and leaving the debugging sections.
+
+The intention is that this option will be used in conjunction with
+@option{--add-gnu-debuglink} to create a two part executable. One a
+stripped binary which will occupy less space in RAM and in a
+distribution and the second a debugging information file which is only
+needed if debugging abilities are required. The suggested procedure
+to create these files is as follows:
+
+@enumerate
+@item Link the executable as normal. Assuming that is is called
+@code{foo} then...
+@item Run @code{objcopy --only-keep-debug foo foo.dbg} to
+create a file containing the debugging info.
+@item Run @code{objcopy --strip-debug foo} to create a
+stripped executable.
+@item Run @code{objcopy --add-gnu-debuglink=foo.dbg foo}
+to add a link to the debugging info into the stripped executable.
+@end enumerate
+
+Note - the choice of @code{.dbg} as an extension for the debug info
+file is arbitrary. Also the @code{--only-keep-debug} step is
+optional. You could instead do this:
+
+@enumerate
+@item Link the executable as normal.
+@item Copy @code{foo} to @code{foo.full}
+@item Run @code{objcopy --strip-debug foo}
+@item Run @code{objcopy --add-gnu-debuglink=foo.full foo}
+@end enumerate
+
+ie the file pointed to by the @option{--add-gnu-debuglink} can be the
+full executable. It does not have to be a file created by the
+@option{--only-keep-debug} switch.
+
@item -V
@itemx --version
Show the version number of @command{objcopy}.
@@ -1330,6 +1439,9 @@ archives, @samp{objcopy -V} lists all members of the archive.
@item --help
Show a summary of the options to @command{objcopy}.
+
+@item --info
+Display a list showing all architectures and object formats available.
@end table
@c man end
@@ -1360,6 +1472,7 @@ objdump [@option{-a}|@option{--archive-headers}]
[@option{-f}|@option{--file-headers}]
[@option{--file-start-context}]
[@option{-g}|@option{--debugging}]
+ [@option{-e}|@option{--debugging-tags}]
[@option{-h}|@option{--section-headers}|@option{--headers}]
[@option{-i}|@option{--info}]
[@option{-j} @var{section}|@option{--section=}@var{section}]
@@ -1405,7 +1518,7 @@ object files.
The long and short forms of options, shown here as alternatives, are
equivalent. At least one option from the list
-@option{-a,-d,-D,-f,-g,-G,-h,-H,-p,-r,-R,-S,-t,-T,-V,-x} must be given.
+@option{-a,-d,-D,-e,-f,-g,-G,-h,-H,-p,-r,-R,-s,-S,-t,-T,-V,-x} must be given.
@table @env
@item -a
@@ -1453,11 +1566,18 @@ mangling styles. The optional demangling style argument can be used to
choose an appropriate demangling style for your compiler. @xref{c++filt},
for more information on demangling.
-@item -G
-@item --debugging
+@item -g
+@itemx --debugging
Display debugging information. This attempts to parse debugging
information stored in the file and print it out using a C like syntax.
Only certain types of debugging information have been implemented.
+Some other types are supported by @command{readelf -w}.
+@xref{readelf}.
+
+@item -e
+@itemx --debugging-tags
+Like @option{-g}, but the information is generated in a format compatible
+with ctags tool.
@item -d
@itemx --disassemble
@@ -1476,11 +1596,6 @@ those expected to contain instructions.
When disassembling, print the complete address on each line. This is
the older disassembly format.
-@item --disassemble-zeroes
-Normally the disassembly output will skip blocks of zeroes. This
-option directs the disassembler to disassemble those blocks, just like
-any other data.
-
@item -EB
@itemx -EL
@itemx --endian=@{big|little@}
@@ -1491,7 +1606,7 @@ disassembly. This can be useful when disassembling a file format which
does not describe endianness information, such as S-records.
@item -f
-@itemx --file-header
+@itemx --file-headers
@cindex object file header
Display summary information from the overall header of
each of the @var{objfile} files.
@@ -1503,8 +1618,8 @@ Specify that when displaying interlisted source code/disassembly
context to the start of the file.
@item -h
-@itemx --section-header
-@itemx --header
+@itemx --section-headers
+@itemx --headers
@cindex section headers
Display summary information from the section headers of the
object file.
@@ -1518,7 +1633,8 @@ although @command{ld} relocates the sections correctly, using @samp{objdump
Instead, it shows the usual addresses, which are implicit for the
target.
-@item --help
+@item -H
+@itemx --help
Print a summary of the options to @command{objdump} and exit.
@item -i
@@ -1552,7 +1668,9 @@ architectures with the @option{-i} option.
@item -M @var{options}
@itemx --disassembler-options=@var{options}
Pass target specific information to the disassembler. Only supported on
-some targets.
+some targets. If it is necessary to specify more than one
+disassembler option then multiple @option{-M} options can be used or
+can be placed together into a comma separated list.
If the target is an ARM architecture then this switch can be used to
select which register name set is used during disassembler. Specifying
@@ -1566,7 +1684,7 @@ just use @samp{r} followed by the register number.
There are also two variants on the APCS register naming scheme enabled
by @option{-M reg-names-atpcs} and @option{-M reg-names-special-atpcs} which
use the ARM/Thumb Procedure Call Standard naming conventions. (Either
-with the normal register name or the special register names).
+with the normal register names or the special register names).
This option can also be used for ARM architectures to force the
disassembler to interpret all instructions as Thumb instructions by
@@ -1584,13 +1702,55 @@ intel syntax mode and AT&T syntax mode. @option{addr32},
address size and operand size. These four options will be overridden if
@option{x86-64}, @option{i386} or @option{i8086} appear later in the
option string. Lastly, @option{suffix}, when in AT&T mode,
-instructs the dissassembler to print a mnemonic suffix even when the
+instructs the disassembler to print a mnemonic suffix even when the
suffix could be inferred by the operands.
For PPC, @option{booke}, @option{booke32} and @option{booke64} select
disassembly of BookE instructions. @option{32} and @option{64} select
PowerPC and PowerPC64 disassembly, respectively.
+For MIPS, this option controls the printing of register names in
+disassembled instructions. Multiple selections from the
+following may be specified as a comma separated string, and invalid
+options are ignored:
+
+@table @code
+@item gpr-names=@var{ABI}
+Print GPR (general-purpose register) names as appropriate
+for the specified ABI. By default, GPR names are selected according to
+the ABI of the binary being disassembled.
+
+@item fpr-names=@var{ABI}
+Print FPR (floating-point register) names as
+appropriate for the specified ABI. By default, FPR numbers are printed
+rather than names.
+
+@item cp0-names=@var{ARCH}
+Print CP0 (system control coprocessor; coprocessor 0) register names
+as appropriate for the CPU or architecture specified by
+@var{ARCH}. By default, CP0 register names are selected according to
+the architecture and CPU of the binary being disassembled.
+
+@item hwr-names=@var{ARCH}
+Print HWR (hardware register, used by the @code{rdhwr} instruction) names
+as appropriate for the CPU or architecture specified by
+@var{ARCH}. By default, HWR names are selected according to
+the architecture and CPU of the binary being disassembled.
+
+@item reg-names=@var{ABI}
+Print GPR and FPR names as appropriate for the selected ABI.
+
+@item reg-names=@var{ARCH}
+Print CPU-specific register names (CP0 register and HWR names)
+as appropriate for the selected CPU or architecture.
+@end table
+
+For any of the options listed above, @var{ABI} or
+@var{ARCH} may be specified as @samp{numeric} to have numbers printed
+rather than names, for the selected types of registers.
+You can list the available values of @var{ABI} and @var{ARCH} using
+the @option{--help} option.
+
@item -p
@itemx --private-headers
Print information that is specific to the object file format. The exact
@@ -1615,7 +1775,8 @@ libraries.
@itemx --full-contents
@cindex sections, full contents
@cindex object file sections
-Display the full contents of any sections requested.
+Display the full contents of any sections requested. By default all
+non-empty sections are displayed.
@item -S
@itemx --source
@@ -1634,7 +1795,7 @@ When disassembling instructions, do not print the instruction bytes.
This is the default when @option{--prefix-addresses} is used.
@item -G
-@item --stabs
+@itemx --stabs
@cindex stab
@cindex .stab
@cindex debug symbols
@@ -1675,11 +1836,12 @@ meaningful for dynamic objects, such as certain types of shared
libraries. This is similar to the information provided by the @samp{nm}
program when given the @option{-D} (@option{--dynamic}) option.
-@item --version
+@item -V
+@itemx --version
Print the version number of @command{objdump} and exit.
@item -x
-@itemx --all-header
+@itemx --all-headers
@cindex all header information, object file
@cindex header information, all
Display all available header information, including the symbol table and
@@ -1691,6 +1853,12 @@ relocation entries. Using @option{-x} is equivalent to specifying all of
@cindex wide output, printing
Format some lines for output devices that have more than 80 columns.
Also do not truncate symbol names when they are displayed.
+
+@item -z
+@itemx --disassemble-zeroes
+Normally the disassembly output will skip blocks of zeroes. This
+option directs the disassembler to disassemble those blocks, just like
+any other data.
@end table
@c man end
@@ -1942,11 +2110,11 @@ octal, @samp{x} for hexadecimal, or @samp{d} for decimal.
@item -e @var{encoding}
@itemx --encoding=@var{encoding}
Select the character encoding of the strings that are to be found.
-Possible values for @var{encoding} are: @samp{s} = single-byte
-characters (ASCII, ISO 8859, etc., default), @samp{b} = 16-bit
-Bigendian, @samp{l} = 16-bit Littleendian, @samp{B} = 32-bit Bigendian,
-@samp{L} = 32-bit Littleendian. Useful for finding wide character
-strings.
+Possible values for @var{encoding} are: @samp{s} = single-7-bit-byte
+characters (ASCII, ISO 8859, etc., default), @samp{S} =
+single-8-bit-byte characters, @samp{b} = 16-bit bigendian, @samp{l} =
+16-bit littleendian, @samp{B} = 32-bit bigendian, @samp{L} = 32-bit
+littleendian. Useful for finding wide character strings.
@item --target=@var{bfdname}
@cindex object code format
@@ -1979,16 +2147,20 @@ and the Info entries for @file{binutils}.
@smallexample
@c man begin SYNOPSIS strip
-strip [@option{-F} @var{bfdname} |@option{--target=}@var{bfdname} ]
- [@option{-I} @var{bfdname} |@option{--input-target=}@var{bfdname} ]
- [@option{-O} @var{bfdname} |@option{--output-target=}@var{bfdname} ]
- [@option{-s}|@option{--strip-all}] [@option{-S}|@option{-g}|@option{-d}|@option{--strip-debug}]
- [@option{-K} @var{symbolname} |@option{--keep-symbol=}@var{symbolname} ]
- [@option{-N} @var{symbolname} |@option{--strip-symbol=}@var{symbolname} ]
- [@option{-x}|@option{--discard-all} ] [@option{-X} |@option{--discard-locals}]
- [@option{-R} @var{sectionname} |@option{--remove-section=}@var{sectionname} ]
- [@option{-o} @var{file} ] [@option{-p}|@option{--preserve-dates}]
- [@option{-v} |@option{--verbose}] [@option{-V}|@option{--version}] [@option{--help}]
+strip [@option{-F} @var{bfdname} |@option{--target=}@var{bfdname}]
+ [@option{-I} @var{bfdname} |@option{--input-target=}@var{bfdname}]
+ [@option{-O} @var{bfdname} |@option{--output-target=}@var{bfdname}]
+ [@option{-s}|@option{--strip-all}]
+ [@option{-S}|@option{-g}|@option{-d}|@option{--strip-debug}]
+ [@option{-K} @var{symbolname} |@option{--keep-symbol=}@var{symbolname}]
+ [@option{-N} @var{symbolname} |@option{--strip-symbol=}@var{symbolname}]
+ [@option{-w}|@option{--wildcard}]
+ [@option{-x}|@option{--discard-all}] [@option{-X} |@option{--discard-locals}]
+ [@option{-R} @var{sectionname} |@option{--remove-section=}@var{sectionname}]
+ [@option{-o} @var{file}] [@option{-p}|@option{--preserve-dates}]
+ [@option{--only-keep-debug}]
+ [@option{-v} |@option{--verbose}] [@option{-V}|@option{--version}]
+ [@option{--help}] [@option{--info}]
@var{objfile}@dots{}
@c man end
@end smallexample
@@ -2016,7 +2188,10 @@ code format @var{bfdname}, and rewrite it in the same format.
@item --help
Show a summary of the options to @command{strip} and exit.
-@item -I @var{bfdname}
+@item --info
+Display a list showing all architectures and object formats available.
+
+@item -I @var{bfdname}
@itemx --input-target=@var{bfdname}
Treat the original @var{objfile} as a file with the object
code format @var{bfdname}.
@@ -2066,6 +2241,22 @@ argument may be specified.
@itemx --preserve-dates
Preserve the access and modification dates of the file.
+@item -w
+@itemx --wildcard
+Permit regular expressions in @var{symbolname}s used in other command
+line options. The question mark (?), asterisk (*), backslash (\) and
+square brackets ([]) operators can be used anywhere in the symbol
+name. If the first character of the symbol name is the exclamation
+point (!) then the sense of the switch is reversed for that symbol.
+For example:
+
+@smallexample
+ -w -K !foo -K fo*
+@end smallexample
+
+would cause strip to only keep symbols that start with the letters
+``fo'', but to discard the symbol ``foo''.
+
@item -x
@itemx --discard-all
Remove non-global symbols.
@@ -2075,6 +2266,43 @@ Remove non-global symbols.
Remove compiler-generated local symbols.
(These usually start with @samp{L} or @samp{.}.)
+@item --only-keep-debug
+Strip a file, removing any sections that would be stripped by
+@option{--strip-debug} and leaving the debugging sections.
+
+The intention is that this option will be used in conjunction with
+@option{--add-gnu-debuglink} to create a two part executable. One a
+stripped binary which will occupy less space in RAM and in a
+distribution and the second a debugging information file which is only
+needed if debugging abilities are required. The suggested procedure
+to create these files is as follows:
+
+@enumerate
+@item Link the executable as normal. Assuming that is is called
+@code{foo} then...
+@item Run @code{objcopy --only-keep-debug foo foo.dbg} to
+create a file containing the debugging info.
+@item Run @code{objcopy --strip-debug foo} to create a
+stripped executable.
+@item Run @code{objcopy --add-gnu-debuglink=foo.dbg foo}
+to add a link to the debugging info into the stripped executable.
+@end enumerate
+
+Note - the choice of @code{.dbg} as an extension for the debug info
+file is arbitrary. Also the @code{--only-keep-debug} step is
+optional. You could instead do this:
+
+@enumerate
+@item Link the executable as normal.
+@item Copy @code{foo} to @code{foo.full}
+@item Run @code{strip --strip-debug foo}
+@item Run @code{objcopy --add-gnu-debuglink=foo.full foo}
+@end enumerate
+
+ie the file pointed to by the @option{--add-gnu-debuglink} can be the
+full executable. It does not have to be a file created by the
+@option{--only-keep-debug} switch.
+
@item -V
@itemx --version
Show the version number for @command{strip}.
@@ -2106,6 +2334,7 @@ the Info entries for @file{binutils}.
c++filt [@option{-_}|@option{--strip-underscores}]
[@option{-j}|@option{--java}]
[@option{-n}|@option{--no-strip-underscores}]
+ [@option{-p}|@option{--no-params}]
[@option{-s} @var{format}|@option{--format=}@var{format}]
[@option{--help}] [@option{--version}] [@var{symbol}@dots{}]
@c man end
@@ -2161,25 +2390,36 @@ syntax.
@itemx --no-strip-underscores
Do not remove the initial underscore.
+@item -p
+@itemx --no-params
+When demangling the name of a function, do not display the types of
+the function's parameters.
+
@item -s @var{format}
@itemx --format=@var{format}
-@sc{gnu} @command{nm} can decode three different methods of mangling, used by
-different C++ compilers. The argument to this option selects which
+@command{c++filt} can decode various methods of mangling, used by
+different compilers. The argument to this option selects which
method it uses:
@table @code
+@item auto
+Automatic selection based on executable (the default method)
@item gnu
-the one used by the @sc{gnu} compiler (the default method)
+the one used by the @sc{gnu} C++ compiler (g++)
@item lucid
-the one used by the Lucid compiler
+the one used by the Lucid compiler (lcc)
@item arm
the one specified by the C++ Annotated Reference Manual
@item hp
-the one used by the HP compiler
+the one used by the HP compiler (aCC)
@item edg
the one used by the EDG compiler
-@item gnu-new-abi
-the one used by the @sc{gnu} compiler with the new ABI.
+@item gnu-v3
+the one used by the @sc{gnu} C++ compiler (g++) with the V3 ABI.
+@item java
+the one used by the @sc{gnu} Java compiler (gcj)
+@item gnat
+the one used by the @sc{gnu} Ada compiler (GNAT).
@end table
@item --help
@@ -2497,9 +2737,11 @@ The name of the output file. If this option is not used, then
@command{windres} will use the first non-option argument, after any used
for the input file name, as the output file name. If there is no
non-option argument, then @command{windres} will write to standard output.
-@command{windres} can not write a COFF file to standard output.
+@command{windres} can not write a COFF file to standard output. Note,
+for compatability with @command{rc} the option @option{-fo} is also
+accepted, but its use is not recommended.
-@item -I @var{format}
+@item -J @var{format}
@itemx --input-format @var{format}
The input format to read. @var{format} may be @samp{res}, @samp{rc}, or
@samp{coff}. If no input format is specified, @command{windres} will
@@ -2527,21 +2769,36 @@ preprocessor first. This option may be used to specify the preprocessor
to use, including any leading arguments. The default preprocessor
argument is @code{gcc -E -xc-header -DRC_INVOKED}.
-@item --include-dir @var{directory}
+@item -I @var{directory}
+@itemx --include-dir @var{directory}
Specify an include directory to use when reading an @code{rc} file.
@command{windres} will pass this to the preprocessor as an @option{-I}
option. @command{windres} will also search this directory when looking for
-files named in the @code{rc} file.
+files named in the @code{rc} file. If the argument passed to this command
+matches any of the supported @var{formats} (as descrived in the @option{-J}
+option), it will issue a deprecation warning, and behave just like the
+@option{-J} option. New programs should not use this behaviour. If a
+directory happens to match a @var{format}, simple prefix it with @samp{./}
+to disable the backward compatibility.
@item -D @var{target}
@itemx --define @var{sym}[=@var{val}]
Specify a @option{-D} option to pass to the preprocessor when reading an
@code{rc} file.
+@item -U @var{target}
+@itemx --undefine @var{sym}
+Specify a @option{-U} option to pass to the preprocessor when reading an
+@code{rc} file.
+
+@item -r
+Ignored for compatibility with rc.
+
@item -v
Enable verbose mode. This tells you what the preprocessor is if you
didn't specify one.
+@item -l @var{val}
@item --language @var{val}
Specify the default language to use when reading an @code{rc} file.
@var{val} should be a hexadecimal language code. The low eight bits are
@@ -2558,9 +2815,11 @@ go the console).
Use popen, not a temporary file, to read the output of the preprocessor.
This is the default behaviour.
+@item -h
@item --help
Prints a usage summary.
+@item -V
@item --version
Prints the version number for @command{windres}.
@@ -2607,7 +2866,8 @@ dlltool [@option{-d}|@option{--input-def} @var{def-file-name}]
[@option{-a}|@option{--add-indirect}] [@option{-U}|@option{--add-underscore}] [@option{-k}|@option{--kill-at}]
[@option{-A}|@option{--add-stdcall-alias}]
[@option{-x}|@option{--no-idata4}] [@option{-c}|@option{--no-idata5}] [@option{-i}|@option{--interwork}]
- [@option{-n}|@option{--nodelete}] [@option{-v}|@option{--verbose}]
+ [@option{-n}|@option{--nodelete}] [@option{-t}|@option{--temp-prefix} @var{prefix}]
+ [@option{-v}|@option{--verbose}]
[@option{-h}|@option{--help}] [@option{-V}|@option{--version}]
[object-file @dots{}]
@c man end
@@ -2817,7 +3077,13 @@ between ARM and Thumb code.
Makes @command{dlltool} preserve the temporary assembler files it used to
create the exports file. If this option is repeated then dlltool will
also preserve the temporary object files it uses to create the library
-file.
+file.
+
+@item -t @var{prefix}
+@itemx --temp-prefix @var{prefix}
+Makes @command{dlltool} use @var{prefix} when constructing the names of
+temporary assembler and object files. By default, the temp file prefix
+is generated from the pid.
@item -v
@itemx --verbose
@@ -2862,10 +3128,12 @@ readelf [@option{-a}|@option{--all}]
[@option{-u}|@option{--unwind}]
[@option{-d}|@option{--dynamic}]
[@option{-V}|@option{--version-info}]
+ [@option{-A}|@option{--arch-specific}]
[@option{-D}|@option{--use-dynamic}]
[@option{-x} <number>|@option{--hex-dump=}<number>]
- [@option{-w[liaprmfFso]}|@option{--debug-dump}[=line,=info,=abbrev,=pubnames,=ranges,=macro,=frames,=str,=loc]]
- [@option{-histogram}]
+ [@option{-w[liaprmfFso]}|
+ @option{--debug-dump}[=line,=info,=abbrev,=pubnames,=ranges,=macro,=frames,=frames-interp,=str,=loc]]
+ [@option{-I}|@option{-histogram}]
[@option{-v}|@option{--version}]
[@option{-W}|@option{--wide}]
[@option{-H}|@option{--help}]
@@ -2878,9 +3146,13 @@ readelf [@option{-a}|@option{--all}]
@command{readelf} displays information about one or more ELF format object
files. The options control what particular information to display.
-@var{elffile}@dots{} are the object files to be examined. At the
-moment, @command{readelf} does not support examining archives, nor does it
-support examing 64 bit ELF files.
+@var{elffile}@dots{} are the object files to be examined. 32-bit and
+64-bit ELF files are supported, as are archives containing ELF files.
+
+This program performs a similar function to @command{objdump} but it
+goes into more detail and it exists independently of the @sc{bfd}
+library, so if there is a bug in @sc{bfd} then readelf will not be
+affected.
@c man end
@@ -2945,6 +3217,12 @@ Displays the contents of the file's relocation section, if it has one.
Displays the contents of the file's unwind section, if it has one. Only
the unwind sections for IA64 ELF files are currently supported.
+@item -u
+@itemx --unwind
+@cindex unwind information
+Displays the contents of the file's unwind section, if it has one. Only
+the unwind sections for IA64 ELF files are currently supported.
+
@item -d
@itemx --dynamic
@cindex ELF dynamic section information
@@ -2956,6 +3234,11 @@ Displays the contents of the file's dynamic section, if it has one.
Displays the contents of the version sections in the file, it they
exist.
+@item -A
+@itemx --arch-specific
+Displays architecture-specific information in the file, if there
+is any.
+
@item -D
@itemx --use-dynamic
When displaying symbols, this option makes @command{readelf} use the
@@ -2967,12 +3250,13 @@ symbols section.
Displays the contents of the indicated section as a hexadecimal dump.
@item -w[liaprmfFso]
-@itemx --debug-dump[=line,=info,=abbrev,=pubnames,=ranges,=macro,=frames,=str,=loc]
+@itemx --debug-dump[=line,=info,=abbrev,=pubnames,=ranges,=macro,=frames,=frames-interp,=str,=loc]
Displays the contents of the debug sections in the file, if any are
present. If one of the optional letters or words follows the switch
then only data found in those specific sections will be dumped.
-@item --histogram
+@item -I
+@itemx --histogram
Display a histogram of bucket list lengths when displaying the contents
of the symbol tables.
@@ -3003,9 +3287,9 @@ objdump(1), and the Info entries for @file{binutils}.
@end ignore
@node Selecting The Target System
-@chapter Selecting the target system
+@chapter Selecting the Target System
-You can specify three aspects of the target system to the @sc{gnu}
+You can specify two aspects of the target system to the @sc{gnu}
binary file utilities, each in several ways:
@itemize @bullet
@@ -3014,9 +3298,6 @@ the target
@item
the architecture
-
-@item
-the linker emulation (which applies to the linker only)
@end itemize
In the following summaries, the lists of ways to specify values are in
@@ -3033,7 +3314,6 @@ with the same type as the target system).
@menu
* Target Selection::
* Architecture Selection::
-* Linker Emulation Selection::
@end menu
@node Target Selection
@@ -3123,47 +3403,8 @@ environment variable @code{GNUTARGET}
deduced from the input file
@end enumerate
-@subheading Linker Input Target
-
-Ways to specify:
-
-@enumerate
-@item
-command line option: @option{-b} or @option{--format}
-(@pxref{Options,,Options,ld.info,Using LD})
-
-@item
-script command @code{TARGET}
-(@pxref{Format Commands,,Format Commands,ld.info,Using LD})
-
-@item
-environment variable @code{GNUTARGET}
-(@pxref{Environment,,Environment,ld.info,Using LD})
-
-@item
-the default target of the selected linker emulation
-(@pxref{Linker Emulation Selection})
-@end enumerate
-
-@subheading Linker Output Target
-
-Ways to specify:
-
-@enumerate
-@item
-command line option: @option{-oformat}
-(@pxref{Options,,Options,ld.info,Using LD})
-
-@item
-script command @code{OUTPUT_FORMAT}
-(@pxref{Format Commands,,Format Commands,ld.info,Using LD})
-
-@item
-the linker input target (see ``Linker Input Target'' above)
-@end enumerate
-
@node Architecture Selection
-@section Architecture selection
+@section Architecture Selection
An @dfn{architecture} is a type of @sc{cpu} on which an object file is
to run. Its name may contain a colon, separating the name of the
@@ -3195,67 +3436,6 @@ Ways to specify:
deduced from the input file
@end enumerate
-@subheading Linker Input Architecture
-
-Ways to specify:
-
-@enumerate
-@item
-deduced from the input file
-@end enumerate
-
-@subheading Linker Output Architecture
-
-Ways to specify:
-
-@enumerate
-@item
-script command @code{OUTPUT_ARCH}
-(@pxref{Miscellaneous Commands,,Miscellaneous Commands,ld.info,Using LD})
-
-@item
-the default architecture from the linker output target
-(@pxref{Target Selection})
-@end enumerate
-
-@node Linker Emulation Selection
-@section Linker emulation selection
-
-A linker @dfn{emulation} is a ``personality'' of the linker, which gives
-the linker default values for the other aspects of the target system.
-In particular, it consists of
-
-@itemize @bullet
-@item
-the linker script
-
-@item
-the target
-
-@item
-several ``hook'' functions that are run at certain stages of the linking
-process to do special things that some targets require
-@end itemize
-
-The command to list valid linker emulation values is @samp{ld -V}.
-
-Sample values: @samp{hp300bsd}, @samp{mipslit}, @samp{sun4}.
-
-Ways to specify:
-
-@enumerate
-@item
-command line option: @option{-m}
-(@pxref{Options,,Options,ld.info,Using LD})
-
-@item
-environment variable @code{LDEMULATION}
-
-@item
-compiled-in @code{DEFAULT_EMULATION} from @file{Makefile},
-which comes from @code{EMUL} in @file{config/@var{target}.mt}
-@end enumerate
-
@node Reporting Bugs
@chapter Reporting Bugs
@cindex bugs
@@ -3279,7 +3459,7 @@ information that enables us to fix the bug.
@end menu
@node Bug Criteria
-@section Have you found a bug?
+@section Have You Found a Bug?
@cindex bug criteria
If you are not sure whether you have found a bug, here are some guidelines:
@@ -3302,7 +3482,7 @@ improvement are welcome in any case.
@end itemize
@node Bug Reporting
-@section How to report bugs
+@section How to Report Bugs
@cindex bug reports
@cindex bugs, reporting
@@ -3337,9 +3517,9 @@ it is new to us. Therefore, always write your bug reports on the assumption
that the bug has not been reported previously.
Sometimes people give a few sketchy facts and ask, ``Does this ring a
-bell?'' Those bug reports are useless, and we urge everyone to
-@emph{refuse to respond to them} except to chide the sender to report
-bugs properly.
+bell?'' This cannot help us fix a bug, so it is basically useless. We
+respond by asking for enough details to enable us to investigate.
+You might as well expedite matters by sending them to begin with.
To enable us to fix the bug, you should include all these things:
@@ -3464,369 +3644,7 @@ Such guesses are usually wrong. Even we cannot guess right about such
things without first using the debugger to find the facts.
@end itemize
-@node GNU Free Documentation License
-@chapter GNU Free Documentation License
-@cindex GNU Free Documentation License
-
- GNU Free Documentation License
-
- Version 1.1, March 2000
-
- Copyright (C) 2000 Free Software Foundation, Inc.
- 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-
- Everyone is permitted to copy and distribute verbatim copies
- of this license document, but changing it is not allowed.
-
-
-0. PREAMBLE
-
-The purpose of this License is to make a manual, textbook, or other
-written document "free" in the sense of freedom: to assure everyone
-the effective freedom to copy and redistribute it, with or without
-modifying it, either commercially or noncommercially. Secondarily,
-this License preserves for the author and publisher a way to get
-credit for their work, while not being considered responsible for
-modifications made by others.
-
-This License is a kind of "copyleft", which means that derivative
-works of the document must themselves be free in the same sense. It
-complements the GNU General Public License, which is a copyleft
-license designed for free software.
-
-We have designed this License in order to use it for manuals for free
-software, because free software needs free documentation: a free
-program should come with manuals providing the same freedoms that the
-software does. But this License is not limited to software manuals;
-it can be used for any textual work, regardless of subject matter or
-whether it is published as a printed book. We recommend this License
-principally for works whose purpose is instruction or reference.
-
-
-1. APPLICABILITY AND DEFINITIONS
-
-This License applies to any manual or other work that contains a
-notice placed by the copyright holder saying it can be distributed
-under the terms of this License. The "Document", below, refers to any
-such manual or work. Any member of the public is a licensee, and is
-addressed as "you".
-
-A "Modified Version" of the Document means any work containing the
-Document or a portion of it, either copied verbatim, or with
-modifications and/or translated into another language.
-
-A "Secondary Section" is a named appendix or a front-matter section of
-the Document that deals exclusively with the relationship of the
-publishers or authors of the Document to the Document's overall subject
-(or to related matters) and contains nothing that could fall directly
-within that overall subject. (For example, if the Document is in part a
-textbook of mathematics, a Secondary Section may not explain any
-mathematics.) The relationship could be a matter of historical
-connection with the subject or with related matters, or of legal,
-commercial, philosophical, ethical or political position regarding
-them.
-
-The "Invariant Sections" are certain Secondary Sections whose titles
-are designated, as being those of Invariant Sections, in the notice
-that says that the Document is released under this License.
-
-The "Cover Texts" are certain short passages of text that are listed,
-as Front-Cover Texts or Back-Cover Texts, in the notice that says that
-the Document is released under this License.
-
-A "Transparent" copy of the Document means a machine-readable copy,
-represented in a format whose specification is available to the
-general public, whose contents can be viewed and edited directly and
-straightforwardly with generic text editors or (for images composed of
-pixels) generic paint programs or (for drawings) some widely available
-drawing editor, and that is suitable for input to text formatters or
-for automatic translation to a variety of formats suitable for input
-to text formatters. A copy made in an otherwise Transparent file
-format whose markup has been designed to thwart or discourage
-subsequent modification by readers is not Transparent. A copy that is
-not "Transparent" is called "Opaque".
-
-Examples of suitable formats for Transparent copies include plain
-ASCII without markup, Texinfo input format, LaTeX input format, SGML
-or XML using a publicly available DTD, and standard-conforming simple
-HTML designed for human modification. Opaque formats include
-PostScript, PDF, proprietary formats that can be read and edited only
-by proprietary word processors, SGML or XML for which the DTD and/or
-processing tools are not generally available, and the
-machine-generated HTML produced by some word processors for output
-purposes only.
-
-The "Title Page" means, for a printed book, the title page itself,
-plus such following pages as are needed to hold, legibly, the material
-this License requires to appear in the title page. For works in
-formats which do not have any title page as such, "Title Page" means
-the text near the most prominent appearance of the work's title,
-preceding the beginning of the body of the text.
-
-
-2. VERBATIM COPYING
-
-You may copy and distribute the Document in any medium, either
-commercially or noncommercially, provided that this License, the
-copyright notices, and the license notice saying this License applies
-to the Document are reproduced in all copies, and that you add no other
-conditions whatsoever to those of this License. You may not use
-technical measures to obstruct or control the reading or further
-copying of the copies you make or distribute. However, you may accept
-compensation in exchange for copies. If you distribute a large enough
-number of copies you must also follow the conditions in section 3.
-
-You may also lend copies, under the same conditions stated above, and
-you may publicly display copies.
-
-
-3. COPYING IN QUANTITY
-
-If you publish printed copies of the Document numbering more than 100,
-and the Document's license notice requires Cover Texts, you must enclose
-the copies in covers that carry, clearly and legibly, all these Cover
-Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on
-the back cover. Both covers must also clearly and legibly identify
-you as the publisher of these copies. The front cover must present
-the full title with all words of the title equally prominent and
-visible. You may add other material on the covers in addition.
-Copying with changes limited to the covers, as long as they preserve
-the title of the Document and satisfy these conditions, can be treated
-as verbatim copying in other respects.
-
-If the required texts for either cover are too voluminous to fit
-legibly, you should put the first ones listed (as many as fit
-reasonably) on the actual cover, and continue the rest onto adjacent
-pages.
-
-If you publish or distribute Opaque copies of the Document numbering
-more than 100, you must either include a machine-readable Transparent
-copy along with each Opaque copy, or state in or with each Opaque copy
-a publicly-accessible computer-network location containing a complete
-Transparent copy of the Document, free of added material, which the
-general network-using public has access to download anonymously at no
-charge using public-standard network protocols. If you use the latter
-option, you must take reasonably prudent steps, when you begin
-distribution of Opaque copies in quantity, to ensure that this
-Transparent copy will remain thus accessible at the stated location
-until at least one year after the last time you distribute an Opaque
-copy (directly or through your agents or retailers) of that edition to
-the public.
-
-It is requested, but not required, that you contact the authors of the
-Document well before redistributing any large number of copies, to give
-them a chance to provide you with an updated version of the Document.
-
-
-4. MODIFICATIONS
-
-You may copy and distribute a Modified Version of the Document under
-the conditions of sections 2 and 3 above, provided that you release
-the Modified Version under precisely this License, with the Modified
-Version filling the role of the Document, thus licensing distribution
-and modification of the Modified Version to whoever possesses a copy
-of it. In addition, you must do these things in the Modified Version:
-
-A. Use in the Title Page (and on the covers, if any) a title distinct
- from that of the Document, and from those of previous versions
- (which should, if there were any, be listed in the History section
- of the Document). You may use the same title as a previous version
- if the original publisher of that version gives permission.
-B. List on the Title Page, as authors, one or more persons or entities
- responsible for authorship of the modifications in the Modified
- Version, together with at least five of the principal authors of the
- Document (all of its principal authors, if it has less than five).
-C. State on the Title page the name of the publisher of the
- Modified Version, as the publisher.
-D. Preserve all the copyright notices of the Document.
-E. Add an appropriate copyright notice for your modifications
- adjacent to the other copyright notices.
-F. Include, immediately after the copyright notices, a license notice
- giving the public permission to use the Modified Version under the
- terms of this License, in the form shown in the Addendum below.
-G. Preserve in that license notice the full lists of Invariant Sections
- and required Cover Texts given in the Document's license notice.
-H. Include an unaltered copy of this License.
-I. Preserve the section entitled "History", and its title, and add to
- it an item stating at least the title, year, new authors, and
- publisher of the Modified Version as given on the Title Page. If
- there is no section entitled "History" in the Document, create one
- stating the title, year, authors, and publisher of the Document as
- given on its Title Page, then add an item describing the Modified
- Version as stated in the previous sentence.
-J. Preserve the network location, if any, given in the Document for
- public access to a Transparent copy of the Document, and likewise
- the network locations given in the Document for previous versions
- it was based on. These may be placed in the "History" section.
- You may omit a network location for a work that was published at
- least four years before the Document itself, or if the original
- publisher of the version it refers to gives permission.
-K. In any section entitled "Acknowledgements" or "Dedications",
- preserve the section's title, and preserve in the section all the
- substance and tone of each of the contributor acknowledgements
- and/or dedications given therein.
-L. Preserve all the Invariant Sections of the Document,
- unaltered in their text and in their titles. Section numbers
- or the equivalent are not considered part of the section titles.
-M. Delete any section entitled "Endorsements". Such a section
- may not be included in the Modified Version.
-N. Do not retitle any existing section as "Endorsements"
- or to conflict in title with any Invariant Section.
-
-If the Modified Version includes new front-matter sections or
-appendices that qualify as Secondary Sections and contain no material
-copied from the Document, you may at your option designate some or all
-of these sections as invariant. To do this, add their titles to the
-list of Invariant Sections in the Modified Version's license notice.
-These titles must be distinct from any other section titles.
-
-You may add a section entitled "Endorsements", provided it contains
-nothing but endorsements of your Modified Version by various
-parties--for example, statements of peer review or that the text has
-been approved by an organization as the authoritative definition of a
-standard.
-
-You may add a passage of up to five words as a Front-Cover Text, and a
-passage of up to 25 words as a Back-Cover Text, to the end of the list
-of Cover Texts in the Modified Version. Only one passage of
-Front-Cover Text and one of Back-Cover Text may be added by (or
-through arrangements made by) any one entity. If the Document already
-includes a cover text for the same cover, previously added by you or
-by arrangement made by the same entity you are acting on behalf of,
-you may not add another; but you may replace the old one, on explicit
-permission from the previous publisher that added the old one.
-
-The author(s) and publisher(s) of the Document do not by this License
-give permission to use their names for publicity for or to assert or
-imply endorsement of any Modified Version.
-
-
-5. COMBINING DOCUMENTS
-
-You may combine the Document with other documents released under this
-License, under the terms defined in section 4 above for modified
-versions, provided that you include in the combination all of the
-Invariant Sections of all of the original documents, unmodified, and
-list them all as Invariant Sections of your combined work in its
-license notice.
-
-The combined work need only contain one copy of this License, and
-multiple identical Invariant Sections may be replaced with a single
-copy. If there are multiple Invariant Sections with the same name but
-different contents, make the title of each such section unique by
-adding at the end of it, in parentheses, the name of the original
-author or publisher of that section if known, or else a unique number.
-Make the same adjustment to the section titles in the list of
-Invariant Sections in the license notice of the combined work.
-
-In the combination, you must combine any sections entitled "History"
-in the various original documents, forming one section entitled
-"History"; likewise combine any sections entitled "Acknowledgements",
-and any sections entitled "Dedications". You must delete all sections
-entitled "Endorsements."
-
-
-6. COLLECTIONS OF DOCUMENTS
-
-You may make a collection consisting of the Document and other documents
-released under this License, and replace the individual copies of this
-License in the various documents with a single copy that is included in
-the collection, provided that you follow the rules of this License for
-verbatim copying of each of the documents in all other respects.
-
-You may extract a single document from such a collection, and distribute
-it individually under this License, provided you insert a copy of this
-License into the extracted document, and follow this License in all
-other respects regarding verbatim copying of that document.
-
-
-7. AGGREGATION WITH INDEPENDENT WORKS
-
-A compilation of the Document or its derivatives with other separate
-and independent documents or works, in or on a volume of a storage or
-distribution medium, does not as a whole count as a Modified Version
-of the Document, provided no compilation copyright is claimed for the
-compilation. Such a compilation is called an "aggregate", and this
-License does not apply to the other self-contained works thus compiled
-with the Document, on account of their being thus compiled, if they
-are not themselves derivative works of the Document.
-
-If the Cover Text requirement of section 3 is applicable to these
-copies of the Document, then if the Document is less than one quarter
-of the entire aggregate, the Document's Cover Texts may be placed on
-covers that surround only the Document within the aggregate.
-Otherwise they must appear on covers around the whole aggregate.
-
-
-8. TRANSLATION
-
-Translation is considered a kind of modification, so you may
-distribute translations of the Document under the terms of section 4.
-Replacing Invariant Sections with translations requires special
-permission from their copyright holders, but you may include
-translations of some or all Invariant Sections in addition to the
-original versions of these Invariant Sections. You may include a
-translation of this License provided that you also include the
-original English version of this License. In case of a disagreement
-between the translation and the original English version of this
-License, the original English version will prevail.
-
-
-9. TERMINATION
-
-You may not copy, modify, sublicense, or distribute the Document except
-as expressly provided for under this License. Any other attempt to
-copy, modify, sublicense or distribute the Document is void, and will
-automatically terminate your rights under this License. However,
-parties who have received copies, or rights, from you under this
-License will not have their licenses terminated so long as such
-parties remain in full compliance.
-
-
-10. FUTURE REVISIONS OF THIS LICENSE
-
-The Free Software Foundation may publish new, revised versions
-of the GNU Free Documentation License from time to time. Such new
-versions will be similar in spirit to the present version, but may
-differ in detail to address new problems or concerns. See
-http://www.gnu.org/copyleft/.
-
-Each version of the License is given a distinguishing version number.
-If the Document specifies that a particular numbered version of this
-License "or any later version" applies to it, you have the option of
-following the terms and conditions either of that specified version or
-of any later version that has been published (not as a draft) by the
-Free Software Foundation. If the Document does not specify a version
-number of this License, you may choose any version ever published (not
-as a draft) by the Free Software Foundation.
-
-
-ADDENDUM: How to use this License for your documents
-
-To use this License in a document you have written, include a copy of
-the License in the document and put the following copyright and
-license notices just after the title page:
-
-@smallexample
- Copyright (c) YEAR YOUR NAME.
- Permission is granted to copy, distribute and/or modify this document
- under the terms of the GNU Free Documentation License, Version 1.1
- or any later version published by the Free Software Foundation;
- with the Invariant Sections being LIST THEIR TITLES, with the
- Front-Cover Texts being LIST, and with the Back-Cover Texts being LIST.
- A copy of the license is included in the section entitled "GNU
- Free Documentation License".
-@end smallexample
-
-If you have no Invariant Sections, write "with no Invariant Sections"
-instead of saying which ones are invariant. If you have no
-Front-Cover Texts, write "no Front-Cover Texts" instead of
-"Front-Cover Texts being LIST"; likewise for Back-Cover Texts.
-
-If your document contains nontrivial examples of program code, we
-recommend releasing these examples in parallel under your choice of
-free software license, such as the GNU General Public License,
-to permit their use in free software.
+@include fdl.texi
@node Index
@unnumbered Index
diff --git a/contrib/binutils/binutils/doc/cxxfilt.man b/contrib/binutils/binutils/doc/cxxfilt.man
index 3e95060..8cc8eb2 100644
--- a/contrib/binutils/binutils/doc/cxxfilt.man
+++ b/contrib/binutils/binutils/doc/cxxfilt.man
@@ -1,4 +1,4 @@
-.\" Automatically generated by Pod::Man v1.3, Pod::Parser v1.13
+.\" Automatically generated by Pod::Man v1.37, Pod::Parser v1.14
.\"
.\" Standard preamble:
.\" ========================================================================
@@ -21,7 +21,6 @@
..
.de Ve \" End verbatim text
.ft R
-
.fi
..
.\" Set up some character translations and predefined strings. \*(-- will
@@ -129,15 +128,15 @@
.\" ========================================================================
.\"
.IX Title "C++FILT 1"
-.TH C++FILT 1 "2002-08-05" "binutils-2.12.91" "GNU Development Tools"
-.UC
+.TH C++FILT 1 "2004-04-09" "binutils-2.14.91" "GNU Development Tools"
.SH "NAME"
-cxxfilt \- Demangle \*(C+ and Java symbols.
+cxxfilt \- Demangle C++ and Java symbols.
.SH "SYNOPSIS"
.IX Header "SYNOPSIS"
c++filt [\fB\-_\fR|\fB\-\-strip\-underscores\fR]
[\fB\-j\fR|\fB\-\-java\fR]
[\fB\-n\fR|\fB\-\-no\-strip\-underscores\fR]
+ [\fB\-p\fR|\fB\-\-no\-params\fR]
[\fB\-s\fR \fIformat\fR|\fB\-\-format=\fR\fIformat\fR]
[\fB\-\-help\fR] [\fB\-\-version\fR] [\fIsymbol\fR...]
.SH "DESCRIPTION"
@@ -162,6 +161,7 @@ You can use \fBc++filt\fR to decipher individual symbols:
.Vb 1
\& c++filt <symbol>
.Ve
+.PP
If no \fIsymbol\fR arguments are given, \fBc++filt\fR reads symbol
names from the standard input and writes the demangled names to the
standard output. All results are printed on the standard output.
@@ -192,24 +192,36 @@ syntax.
.IX Item "--no-strip-underscores"
.PD
Do not remove the initial underscore.
+.IP "\fB\-p\fR" 4
+.IX Item "-p"
+.PD 0
+.IP "\fB\-\-no\-params\fR" 4
+.IX Item "--no-params"
+.PD
+When demangling the name of a function, do not display the types of
+the function's parameters.
.IP "\fB\-s\fR \fIformat\fR" 4
.IX Item "-s format"
.PD 0
.IP "\fB\-\-format=\fR\fIformat\fR" 4
.IX Item "--format=format"
.PD
-\&\s-1GNU\s0 \fBnm\fR can decode three different methods of mangling, used by
-different \*(C+ compilers. The argument to this option selects which
+\&\fBc++filt\fR can decode various methods of mangling, used by
+different compilers. The argument to this option selects which
method it uses:
.RS 4
+.ie n .IP """auto""" 4
+.el .IP "\f(CWauto\fR" 4
+.IX Item "auto"
+Automatic selection based on executable (the default method)
.ie n .IP """gnu""" 4
.el .IP "\f(CWgnu\fR" 4
.IX Item "gnu"
-the one used by the \s-1GNU\s0 compiler (the default method)
+the one used by the \s-1GNU\s0 \*(C+ compiler (g++)
.ie n .IP """lucid""" 4
.el .IP "\f(CWlucid\fR" 4
.IX Item "lucid"
-the one used by the Lucid compiler
+the one used by the Lucid compiler (lcc)
.ie n .IP """arm""" 4
.el .IP "\f(CWarm\fR" 4
.IX Item "arm"
@@ -217,15 +229,23 @@ the one specified by the \*(C+ Annotated Reference Manual
.ie n .IP """hp""" 4
.el .IP "\f(CWhp\fR" 4
.IX Item "hp"
-the one used by the \s-1HP\s0 compiler
+the one used by the \s-1HP\s0 compiler (aCC)
.ie n .IP """edg""" 4
.el .IP "\f(CWedg\fR" 4
.IX Item "edg"
the one used by the \s-1EDG\s0 compiler
-.ie n .IP """gnu\-new\-abi""" 4
-.el .IP "\f(CWgnu\-new\-abi\fR" 4
-.IX Item "gnu-new-abi"
-the one used by the \s-1GNU\s0 compiler with the new \s-1ABI\s0.
+.ie n .IP """gnu\-v3""" 4
+.el .IP "\f(CWgnu\-v3\fR" 4
+.IX Item "gnu-v3"
+the one used by the \s-1GNU\s0 \*(C+ compiler (g++) with the V3 \s-1ABI\s0.
+.ie n .IP """java""" 4
+.el .IP "\f(CWjava\fR" 4
+.IX Item "java"
+the one used by the \s-1GNU\s0 Java compiler (gcj)
+.ie n .IP """gnat""" 4
+.el .IP "\f(CWgnat\fR" 4
+.IX Item "gnat"
+the one used by the \s-1GNU\s0 Ada compiler (\s-1GNAT\s0).
.RE
.RS 4
.RE
@@ -245,11 +265,12 @@ MS-DOS this program is named \fBcxxfilt\fR.
the Info entries for \fIbinutils\fR.
.SH "COPYRIGHT"
.IX Header "COPYRIGHT"
-Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001, 2002 Free Software Foundation, Inc.
+Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000,
+2001, 2002, 2003 Free Software Foundation, Inc.
.PP
Permission is granted to copy, distribute and/or modify this document
under the terms of the \s-1GNU\s0 Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
-section entitled \*(L"\s-1GNU\s0 Free Documentation License\*(R".
+section entitled ``\s-1GNU\s0 Free Documentation License''.
diff --git a/contrib/binutils/binutils/doc/dlltool.1 b/contrib/binutils/binutils/doc/dlltool.1
index 47539b1..c1e4642 100644
--- a/contrib/binutils/binutils/doc/dlltool.1
+++ b/contrib/binutils/binutils/doc/dlltool.1
@@ -1,4 +1,4 @@
-.\" Automatically generated by Pod::Man v1.3, Pod::Parser v1.13
+.\" Automatically generated by Pod::Man v1.37, Pod::Parser v1.14
.\"
.\" Standard preamble:
.\" ========================================================================
@@ -21,7 +21,6 @@
..
.de Ve \" End verbatim text
.ft R
-
.fi
..
.\" Set up some character translations and predefined strings. \*(-- will
@@ -129,8 +128,7 @@
.\" ========================================================================
.\"
.IX Title "DLLTOOL 1"
-.TH DLLTOOL 1 "2002-08-05" "binutils-2.12.91" "GNU Development Tools"
-.UC
+.TH DLLTOOL 1 "2004-04-09" "binutils-2.14.91" "GNU Development Tools"
.SH "NAME"
dlltool \- Create files needed to build and use DLLs.
.SH "SYNOPSIS"
@@ -148,7 +146,8 @@ dlltool [\fB\-d\fR|\fB\-\-input\-def\fR \fIdef-file-name\fR]
[\fB\-a\fR|\fB\-\-add\-indirect\fR] [\fB\-U\fR|\fB\-\-add\-underscore\fR] [\fB\-k\fR|\fB\-\-kill\-at\fR]
[\fB\-A\fR|\fB\-\-add\-stdcall\-alias\fR]
[\fB\-x\fR|\fB\-\-no\-idata4\fR] [\fB\-c\fR|\fB\-\-no\-idata5\fR] [\fB\-i\fR|\fB\-\-interwork\fR]
- [\fB\-n\fR|\fB\-\-nodelete\fR] [\fB\-v\fR|\fB\-\-verbose\fR]
+ [\fB\-n\fR|\fB\-\-nodelete\fR] [\fB\-t\fR|\fB\-\-temp\-prefix\fR \fIprefix\fR]
+ [\fB\-v\fR|\fB\-\-verbose\fR]
[\fB\-h\fR|\fB\-\-help\fR] [\fB\-V\fR|\fB\-\-version\fR]
[object\-file ...]
.SH "DESCRIPTION"
@@ -183,9 +182,11 @@ section of the object file. This can be done in C by using the
\& asm (".section .drectve");
\& asm (".ascii \e"-export:my_func\e"");
.Ve
+.PP
.Vb 1
\& int my_func (void) { ... }
.Ve
+.PP
The second file needed for \s-1DLL\s0 creation is an exports file. This file
is linked with the object files that make up the body of the \s-1DLL\s0 and it
handles the interface between the \s-1DLL\s0 and the outside world. This is a
@@ -399,7 +400,16 @@ between \s-1ARM\s0 and Thumb code.
Makes \fBdlltool\fR preserve the temporary assembler files it used to
create the exports file. If this option is repeated then dlltool will
also preserve the temporary object files it uses to create the library
-file.
+file.
+.IP "\fB\-t\fR \fIprefix\fR" 4
+.IX Item "-t prefix"
+.PD 0
+.IP "\fB\-\-temp\-prefix\fR \fIprefix\fR" 4
+.IX Item "--temp-prefix prefix"
+.PD
+Makes \fBdlltool\fR use \fIprefix\fR when constructing the names of
+temporary assembler and object files. By default, the temp file prefix
+is generated from the pid.
.IP "\fB\-v\fR" 4
.IX Item "-v"
.PD 0
@@ -426,11 +436,12 @@ Displays dlltool's version number and then exits.
the Info entries for \fIbinutils\fR.
.SH "COPYRIGHT"
.IX Header "COPYRIGHT"
-Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001, 2002 Free Software Foundation, Inc.
+Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000,
+2001, 2002, 2003 Free Software Foundation, Inc.
.PP
Permission is granted to copy, distribute and/or modify this document
under the terms of the \s-1GNU\s0 Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
-section entitled \*(L"\s-1GNU\s0 Free Documentation License\*(R".
+section entitled ``\s-1GNU\s0 Free Documentation License''.
diff --git a/contrib/binutils/binutils/doc/fdl.texi b/contrib/binutils/binutils/doc/fdl.texi
new file mode 100644
index 0000000..f4726b9
--- /dev/null
+++ b/contrib/binutils/binutils/doc/fdl.texi
@@ -0,0 +1,368 @@
+@c -*-texinfo-*-
+@node GNU Free Documentation License
+
+@appendix GNU Free Documentation License
+@center Version 1.1, March 2000
+
+@display
+Copyright (C) 2000 Free Software Foundation, Inc.
+59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+Everyone is permitted to copy and distribute verbatim copies
+of this license document, but changing it is not allowed.
+@end display
+@sp 1
+@enumerate 0
+@item
+PREAMBLE
+
+The purpose of this License is to make a manual, textbook, or other
+written document ``free'' in the sense of freedom: to assure everyone
+the effective freedom to copy and redistribute it, with or without
+modifying it, either commercially or noncommercially. Secondarily,
+this License preserves for the author and publisher a way to get
+credit for their work, while not being considered responsible for
+modifications made by others.
+
+This License is a kind of ``copyleft'', which means that derivative
+works of the document must themselves be free in the same sense. It
+complements the GNU General Public License, which is a copyleft
+license designed for free software.
+
+We have designed this License in order to use it for manuals for free
+software, because free software needs free documentation: a free
+program should come with manuals providing the same freedoms that the
+software does. But this License is not limited to software manuals;
+it can be used for any textual work, regardless of subject matter or
+whether it is published as a printed book. We recommend this License
+principally for works whose purpose is instruction or reference.
+
+@sp 1
+@item
+APPLICABILITY AND DEFINITIONS
+
+This License applies to any manual or other work that contains a
+notice placed by the copyright holder saying it can be distributed
+under the terms of this License. The ``Document'', below, refers to any
+such manual or work. Any member of the public is a licensee, and is
+addressed as ``you.''
+
+A ``Modified Version'' of the Document means any work containing the
+Document or a portion of it, either copied verbatim, or with
+modifications and/or translated into another language.
+
+A ``Secondary Section'' is a named appendix or a front-matter section of
+the Document that deals exclusively with the relationship of the
+publishers or authors of the Document to the Document's overall subject
+(or to related matters) and contains nothing that could fall directly
+within that overall subject. (For example, if the Document is in part a
+textbook of mathematics, a Secondary Section may not explain any
+mathematics.) The relationship could be a matter of historical
+connection with the subject or with related matters, or of legal,
+commercial, philosophical, ethical or political position regarding
+them.
+
+The ``Invariant Sections'' are certain Secondary Sections whose titles
+are designated, as being those of Invariant Sections, in the notice
+that says that the Document is released under this License.
+
+The ``Cover Texts'' are certain short passages of text that are listed,
+as Front-Cover Texts or Back-Cover Texts, in the notice that says that
+the Document is released under this License.
+
+A ``Transparent'' copy of the Document means a machine-readable copy,
+represented in a format whose specification is available to the
+general public, whose contents can be viewed and edited directly and
+straightforwardly with generic text editors or (for images composed of
+pixels) generic paint programs or (for drawings) some widely available
+drawing editor, and that is suitable for input to text formatters or
+for automatic translation to a variety of formats suitable for input
+to text formatters. A copy made in an otherwise Transparent file
+format whose markup has been designed to thwart or discourage
+subsequent modification by readers is not Transparent. A copy that is
+not ``Transparent'' is called ``Opaque.''
+
+Examples of suitable formats for Transparent copies include plain
+ASCII without markup, Texinfo input format, LaTeX input format, SGML
+or XML using a publicly available DTD, and standard-conforming simple
+HTML designed for human modification. Opaque formats include
+PostScript, PDF, proprietary formats that can be read and edited only
+by proprietary word processors, SGML or XML for which the DTD and/or
+processing tools are not generally available, and the
+machine-generated HTML produced by some word processors for output
+purposes only.
+
+The ``Title Page'' means, for a printed book, the title page itself,
+plus such following pages as are needed to hold, legibly, the material
+this License requires to appear in the title page. For works in
+formats which do not have any title page as such, ``Title Page'' means
+the text near the most prominent appearance of the work's title,
+preceding the beginning of the body of the text.
+@sp 1
+@item
+VERBATIM COPYING
+
+You may copy and distribute the Document in any medium, either
+commercially or noncommercially, provided that this License, the
+copyright notices, and the license notice saying this License applies
+to the Document are reproduced in all copies, and that you add no other
+conditions whatsoever to those of this License. You may not use
+technical measures to obstruct or control the reading or further
+copying of the copies you make or distribute. However, you may accept
+compensation in exchange for copies. If you distribute a large enough
+number of copies you must also follow the conditions in section 3.
+
+You may also lend copies, under the same conditions stated above, and
+you may publicly display copies.
+@sp 1
+@item
+COPYING IN QUANTITY
+
+If you publish printed copies of the Document numbering more than 100,
+and the Document's license notice requires Cover Texts, you must enclose
+the copies in covers that carry, clearly and legibly, all these Cover
+Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on
+the back cover. Both covers must also clearly and legibly identify
+you as the publisher of these copies. The front cover must present
+the full title with all words of the title equally prominent and
+visible. You may add other material on the covers in addition.
+Copying with changes limited to the covers, as long as they preserve
+the title of the Document and satisfy these conditions, can be treated
+as verbatim copying in other respects.
+
+If the required texts for either cover are too voluminous to fit
+legibly, you should put the first ones listed (as many as fit
+reasonably) on the actual cover, and continue the rest onto adjacent
+pages.
+
+If you publish or distribute Opaque copies of the Document numbering
+more than 100, you must either include a machine-readable Transparent
+copy along with each Opaque copy, or state in or with each Opaque copy
+a publicly-accessible computer-network location containing a complete
+Transparent copy of the Document, free of added material, which the
+general network-using public has access to download anonymously at no
+charge using public-standard network protocols. If you use the latter
+option, you must take reasonably prudent steps, when you begin
+distribution of Opaque copies in quantity, to ensure that this
+Transparent copy will remain thus accessible at the stated location
+until at least one year after the last time you distribute an Opaque
+copy (directly or through your agents or retailers) of that edition to
+the public.
+
+It is requested, but not required, that you contact the authors of the
+Document well before redistributing any large number of copies, to give
+them a chance to provide you with an updated version of the Document.
+@sp 1
+@item
+MODIFICATIONS
+
+You may copy and distribute a Modified Version of the Document under
+the conditions of sections 2 and 3 above, provided that you release
+the Modified Version under precisely this License, with the Modified
+Version filling the role of the Document, thus licensing distribution
+and modification of the Modified Version to whoever possesses a copy
+of it. In addition, you must do these things in the Modified Version:
+
+A. Use in the Title Page (and on the covers, if any) a title distinct
+ from that of the Document, and from those of previous versions
+ (which should, if there were any, be listed in the History section
+ of the Document). You may use the same title as a previous version
+ if the original publisher of that version gives permission.@*
+B. List on the Title Page, as authors, one or more persons or entities
+ responsible for authorship of the modifications in the Modified
+ Version, together with at least five of the principal authors of the
+ Document (all of its principal authors, if it has less than five).@*
+C. State on the Title page the name of the publisher of the
+ Modified Version, as the publisher.@*
+D. Preserve all the copyright notices of the Document.@*
+E. Add an appropriate copyright notice for your modifications
+ adjacent to the other copyright notices.@*
+F. Include, immediately after the copyright notices, a license notice
+ giving the public permission to use the Modified Version under the
+ terms of this License, in the form shown in the Addendum below.@*
+G. Preserve in that license notice the full lists of Invariant Sections
+ and required Cover Texts given in the Document's license notice.@*
+H. Include an unaltered copy of this License.@*
+I. Preserve the section entitled ``History'', and its title, and add to
+ it an item stating at least the title, year, new authors, and
+ publisher of the Modified Version as given on the Title Page. If
+ there is no section entitled ``History'' in the Document, create one
+ stating the title, year, authors, and publisher of the Document as
+ given on its Title Page, then add an item describing the Modified
+ Version as stated in the previous sentence.@*
+J. Preserve the network location, if any, given in the Document for
+ public access to a Transparent copy of the Document, and likewise
+ the network locations given in the Document for previous versions
+ it was based on. These may be placed in the ``History'' section.
+ You may omit a network location for a work that was published at
+ least four years before the Document itself, or if the original
+ publisher of the version it refers to gives permission.@*
+K. In any section entitled ``Acknowledgements'' or ``Dedications'',
+ preserve the section's title, and preserve in the section all the
+ substance and tone of each of the contributor acknowledgements
+ and/or dedications given therein.@*
+L. Preserve all the Invariant Sections of the Document,
+ unaltered in their text and in their titles. Section numbers
+ or the equivalent are not considered part of the section titles.@*
+M. Delete any section entitled ``Endorsements.'' Such a section
+ may not be included in the Modified Version.@*
+N. Do not retitle any existing section as ``Endorsements''
+ or to conflict in title with any Invariant Section.@*
+@sp 1
+If the Modified Version includes new front-matter sections or
+appendices that qualify as Secondary Sections and contain no material
+copied from the Document, you may at your option designate some or all
+of these sections as invariant. To do this, add their titles to the
+list of Invariant Sections in the Modified Version's license notice.
+These titles must be distinct from any other section titles.
+
+You may add a section entitled ``Endorsements'', provided it contains
+nothing but endorsements of your Modified Version by various
+parties--for example, statements of peer review or that the text has
+been approved by an organization as the authoritative definition of a
+standard.
+
+You may add a passage of up to five words as a Front-Cover Text, and a
+passage of up to 25 words as a Back-Cover Text, to the end of the list
+of Cover Texts in the Modified Version. Only one passage of
+Front-Cover Text and one of Back-Cover Text may be added by (or
+through arrangements made by) any one entity. If the Document already
+includes a cover text for the same cover, previously added by you or
+by arrangement made by the same entity you are acting on behalf of,
+you may not add another; but you may replace the old one, on explicit
+permission from the previous publisher that added the old one.
+
+The author(s) and publisher(s) of the Document do not by this License
+give permission to use their names for publicity for or to assert or
+imply endorsement of any Modified Version.
+@sp 1
+@item
+COMBINING DOCUMENTS
+
+You may combine the Document with other documents released under this
+License, under the terms defined in section 4 above for modified
+versions, provided that you include in the combination all of the
+Invariant Sections of all of the original documents, unmodified, and
+list them all as Invariant Sections of your combined work in its
+license notice.
+
+The combined work need only contain one copy of this License, and
+multiple identical Invariant Sections may be replaced with a single
+copy. If there are multiple Invariant Sections with the same name but
+different contents, make the title of each such section unique by
+adding at the end of it, in parentheses, the name of the original
+author or publisher of that section if known, or else a unique number.
+Make the same adjustment to the section titles in the list of
+Invariant Sections in the license notice of the combined work.
+
+In the combination, you must combine any sections entitled ``History''
+in the various original documents, forming one section entitled
+``History''; likewise combine any sections entitled ``Acknowledgements'',
+and any sections entitled ``Dedications.'' You must delete all sections
+entitled ``Endorsements.''
+@sp 1
+@item
+COLLECTIONS OF DOCUMENTS
+
+You may make a collection consisting of the Document and other documents
+released under this License, and replace the individual copies of this
+License in the various documents with a single copy that is included in
+the collection, provided that you follow the rules of this License for
+verbatim copying of each of the documents in all other respects.
+
+You may extract a single document from such a collection, and distribute
+it individually under this License, provided you insert a copy of this
+License into the extracted document, and follow this License in all
+other respects regarding verbatim copying of that document.
+@sp 1
+@item
+AGGREGATION WITH INDEPENDENT WORKS
+
+A compilation of the Document or its derivatives with other separate
+and independent documents or works, in or on a volume of a storage or
+distribution medium, does not as a whole count as a Modified Version
+of the Document, provided no compilation copyright is claimed for the
+compilation. Such a compilation is called an ``aggregate'', and this
+License does not apply to the other self-contained works thus compiled
+with the Document, on account of their being thus compiled, if they
+are not themselves derivative works of the Document.
+
+If the Cover Text requirement of section 3 is applicable to these
+copies of the Document, then if the Document is less than one quarter
+of the entire aggregate, the Document's Cover Texts may be placed on
+covers that surround only the Document within the aggregate.
+Otherwise they must appear on covers around the whole aggregate.
+@sp 1
+@item
+TRANSLATION
+
+Translation is considered a kind of modification, so you may
+distribute translations of the Document under the terms of section 4.
+Replacing Invariant Sections with translations requires special
+permission from their copyright holders, but you may include
+translations of some or all Invariant Sections in addition to the
+original versions of these Invariant Sections. You may include a
+translation of this License provided that you also include the
+original English version of this License. In case of a disagreement
+between the translation and the original English version of this
+License, the original English version will prevail.
+@sp 1
+@item
+TERMINATION
+
+You may not copy, modify, sublicense, or distribute the Document except
+as expressly provided for under this License. Any other attempt to
+copy, modify, sublicense or distribute the Document is void, and will
+automatically terminate your rights under this License. However,
+parties who have received copies, or rights, from you under this
+License will not have their licenses terminated so long as such
+parties remain in full compliance.
+@sp 1
+@item
+FUTURE REVISIONS OF THIS LICENSE
+
+The Free Software Foundation may publish new, revised versions
+of the GNU Free Documentation License from time to time. Such new
+versions will be similar in spirit to the present version, but may
+differ in detail to address new problems or concerns. See
+http://www.gnu.org/copyleft/.
+
+Each version of the License is given a distinguishing version number.
+If the Document specifies that a particular numbered version of this
+License ``or any later version'' applies to it, you have the option of
+following the terms and conditions either of that specified version or
+of any later version that has been published (not as a draft) by the
+Free Software Foundation. If the Document does not specify a version
+number of this License, you may choose any version ever published (not
+as a draft) by the Free Software Foundation.
+
+@end enumerate
+
+@unnumberedsec ADDENDUM: How to use this License for your documents
+
+To use this License in a document you have written, include a copy of
+the License in the document and put the following copyright and
+license notices just after the title page:
+
+@smallexample
+@group
+Copyright (C) @var{year} @var{your name}.
+Permission is granted to copy, distribute and/or modify this document
+under the terms of the GNU Free Documentation License, Version 1.1
+or any later version published by the Free Software Foundation;
+with the Invariant Sections being @var{list their titles}, with the
+Front-Cover Texts being @var{list}, and with the Back-Cover Texts being @var{list}.
+A copy of the license is included in the section entitled "GNU
+Free Documentation License."
+@end group
+@end smallexample
+
+If you have no Invariant Sections, write ``with no Invariant Sections''
+instead of saying which ones are invariant. If you have no
+Front-Cover Texts, write ``no Front-Cover Texts'' instead of
+``Front-Cover Texts being @var{list}''; likewise for Back-Cover Texts.
+
+If your document contains nontrivial examples of program code, we
+recommend releasing these examples in parallel under your choice of
+free software license, such as the GNU General Public License,
+to permit their use in free software.
diff --git a/contrib/binutils/binutils/doc/nm.1 b/contrib/binutils/binutils/doc/nm.1
index 5702c4a..c472775 100644
--- a/contrib/binutils/binutils/doc/nm.1
+++ b/contrib/binutils/binutils/doc/nm.1
@@ -1,4 +1,4 @@
-.\" Automatically generated by Pod::Man v1.3, Pod::Parser v1.13
+.\" Automatically generated by Pod::Man v1.37, Pod::Parser v1.14
.\"
.\" Standard preamble:
.\" ========================================================================
@@ -21,7 +21,6 @@
..
.de Ve \" End verbatim text
.ft R
-
.fi
..
.\" Set up some character translations and predefined strings. \*(-- will
@@ -129,8 +128,7 @@
.\" ========================================================================
.\"
.IX Title "NM 1"
-.TH NM 1 "2002-08-05" "binutils-2.12.91" "GNU Development Tools"
-.UC
+.TH NM 1 "2004-04-09" "binutils-2.14.91" "GNU Development Tools"
.SH "NAME"
nm \- list symbols from object files
.SH "SYNOPSIS"
@@ -350,7 +348,7 @@ Equivalent to \fB\-f posix\fR.
.IP "\fB\-\-print\-size\fR" 4
.IX Item "--print-size"
.PD
-Print size of defined symbols for the \f(CW\*(C`bsd\*(C'\fR output format.
+Print size, not the value, of defined symbols for the \f(CW\*(C`bsd\*(C'\fR output format.
.IP "\fB\-s\fR" 4
.IX Item "-s"
.PD 0
@@ -372,7 +370,9 @@ last come first.
.IX Item "--size-sort"
Sort symbols by size. The size is computed as the difference between
the value of the symbol and the value of the symbol with the next higher
-value. The size of the symbol is printed, rather than the value.
+value. If the \f(CW\*(C`bsd\*(C'\fR output format is used the size of the symbol
+is printed, rather than the value, and \fB\-S\fR must be used in order
+both size and value to be printed.
.IP "\fB\-t\fR \fIradix\fR" 4
.IX Item "-t radix"
.PD 0
@@ -415,11 +415,12 @@ Show a summary of the options to \fBnm\fR and exit.
\&\fIar\fR\|(1), \fIobjdump\fR\|(1), \fIranlib\fR\|(1), and the Info entries for \fIbinutils\fR.
.SH "COPYRIGHT"
.IX Header "COPYRIGHT"
-Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001, 2002 Free Software Foundation, Inc.
+Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000,
+2001, 2002, 2003 Free Software Foundation, Inc.
.PP
Permission is granted to copy, distribute and/or modify this document
under the terms of the \s-1GNU\s0 Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
-section entitled \*(L"\s-1GNU\s0 Free Documentation License\*(R".
+section entitled ``\s-1GNU\s0 Free Documentation License''.
diff --git a/contrib/binutils/binutils/doc/objcopy.1 b/contrib/binutils/binutils/doc/objcopy.1
index a59a47a..43871d6 100644
--- a/contrib/binutils/binutils/doc/objcopy.1
+++ b/contrib/binutils/binutils/doc/objcopy.1
@@ -1,4 +1,4 @@
-.\" Automatically generated by Pod::Man v1.3, Pod::Parser v1.13
+.\" Automatically generated by Pod::Man v1.37, Pod::Parser v1.14
.\"
.\" Standard preamble:
.\" ========================================================================
@@ -21,7 +21,6 @@
..
.de Ve \" End verbatim text
.ft R
-
.fi
..
.\" Set up some character translations and predefined strings. \*(-- will
@@ -129,8 +128,7 @@
.\" ========================================================================
.\"
.IX Title "OBJCOPY 1"
-.TH OBJCOPY 1 "2002-08-05" "binutils-2.12.91" "GNU Development Tools"
-.UC
+.TH OBJCOPY 1 "2004-04-09" "binutils-2.14.91" "GNU Development Tools"
.SH "NAME"
objcopy \- copy and translate object files
.SH "SYNOPSIS"
@@ -139,21 +137,26 @@ objcopy [\fB\-F\fR \fIbfdname\fR|\fB\-\-target=\fR\fIbfdname\fR]
[\fB\-I\fR \fIbfdname\fR|\fB\-\-input\-target=\fR\fIbfdname\fR]
[\fB\-O\fR \fIbfdname\fR|\fB\-\-output\-target=\fR\fIbfdname\fR]
[\fB\-B\fR \fIbfdarch\fR|\fB\-\-binary\-architecture=\fR\fIbfdarch\fR]
- [\fB\-S\fR|\fB\-\-strip\-all\fR] [\fB\-g\fR|\fB\-\-strip\-debug\fR]
+ [\fB\-S\fR|\fB\-\-strip\-all\fR]
+ [\fB\-g\fR|\fB\-\-strip\-debug\fR]
[\fB\-K\fR \fIsymbolname\fR|\fB\-\-keep\-symbol=\fR\fIsymbolname\fR]
[\fB\-N\fR \fIsymbolname\fR|\fB\-\-strip\-symbol=\fR\fIsymbolname\fR]
[\fB\-G\fR \fIsymbolname\fR|\fB\-\-keep\-global\-symbol=\fR\fIsymbolname\fR]
[\fB\-L\fR \fIsymbolname\fR|\fB\-\-localize\-symbol=\fR\fIsymbolname\fR]
[\fB\-W\fR \fIsymbolname\fR|\fB\-\-weaken\-symbol=\fR\fIsymbolname\fR]
- [\fB\-x\fR|\fB\-\-discard\-all\fR] [\fB\-X\fR|\fB\-\-discard\-locals\fR]
+ [\fB\-w\fR|\fB\-\-wildcard\fR]
+ [\fB\-x\fR|\fB\-\-discard\-all\fR]
+ [\fB\-X\fR|\fB\-\-discard\-locals\fR]
[\fB\-b\fR \fIbyte\fR|\fB\-\-byte=\fR\fIbyte\fR]
[\fB\-i\fR \fIinterleave\fR|\fB\-\-interleave=\fR\fIinterleave\fR]
[\fB\-j\fR \fIsectionname\fR|\fB\-\-only\-section=\fR\fIsectionname\fR]
[\fB\-R\fR \fIsectionname\fR|\fB\-\-remove\-section=\fR\fIsectionname\fR]
[\fB\-p\fR|\fB\-\-preserve\-dates\fR]
[\fB\-\-debugging\fR]
- [\fB\-\-gap\-fill=\fR\fIval\fR] [\fB\-\-pad\-to=\fR\fIaddress\fR]
- [\fB\-\-set\-start=\fR\fIval\fR] [\fB\-\-adjust\-start=\fR\fIincr\fR]
+ [\fB\-\-gap\-fill=\fR\fIval\fR]
+ [\fB\-\-pad\-to=\fR\fIaddress\fR]
+ [\fB\-\-set\-start=\fR\fIval\fR]
+ [\fB\-\-adjust\-start=\fR\fIincr\fR]
[\fB\-\-change\-addresses=\fR\fIincr\fR]
[\fB\-\-change\-section\-address\fR \fIsection\fR{=,+,\-}\fIval\fR]
[\fB\-\-change\-section\-lma\fR \fIsection\fR{=,+,\-}\fIval\fR]
@@ -162,9 +165,10 @@ objcopy [\fB\-F\fR \fIbfdname\fR|\fB\-\-target=\fR\fIbfdname\fR]
[\fB\-\-set\-section\-flags\fR \fIsection\fR=\fIflags\fR]
[\fB\-\-add\-section\fR \fIsectionname\fR=\fIfilename\fR]
[\fB\-\-rename\-section\fR \fIoldname\fR=\fInewname\fR[,\fIflags\fR]]
- [\fB\-\-change\-leading\-char\fR ] [\fB\-\-remove\-leading\-char\fR]
- [\fB\-\-srec\-len=\fR\fIival\fR ] [\fB\-\-srec\-forceS3\fR]
- [\fB\-\-redefine\-sym\fR \fIold\fR=\fInew\fR ]
+ [\fB\-\-change\-leading\-char\fR] [\fB\-\-remove\-leading\-char\fR]
+ [\fB\-\-srec\-len=\fR\fIival\fR] [\fB\-\-srec\-forceS3\fR]
+ [\fB\-\-redefine\-sym\fR \fIold\fR=\fInew\fR]
+ [\fB\-\-redefine\-syms=\fR\fIfilename\fR]
[\fB\-\-weaken\fR]
[\fB\-\-keep\-symbols=\fR\fIfilename\fR]
[\fB\-\-strip\-symbols=\fR\fIfilename\fR]
@@ -172,9 +176,18 @@ objcopy [\fB\-F\fR \fIbfdname\fR|\fB\-\-target=\fR\fIbfdname\fR]
[\fB\-\-localize\-symbols=\fR\fIfilename\fR]
[\fB\-\-weaken\-symbols=\fR\fIfilename\fR]
[\fB\-\-alt\-machine\-code=\fR\fIindex\fR]
+ [\fB\-\-prefix\-symbols=\fR\fIstring\fR]
+ [\fB\-\-prefix\-sections=\fR\fIstring\fR]
+ [\fB\-\-prefix\-alloc\-sections=\fR\fIstring\fR]
+ [\fB\-\-add\-gnu\-debuglink=\fR\fIpath-to-file\fR]
+ [\fB\-\-only\-keep\-debug\fR]
+ [\fB\-\-writable\-text\fR]
+ [\fB\-\-readonly\-text\fR]
+ [\fB\-\-pure\fR]
+ [\fB\-\-impure\fR]
[\fB\-v\fR|\fB\-\-verbose\fR]
[\fB\-V\fR|\fB\-\-version\fR]
- [\fB\-\-help\fR]
+ [\fB\-\-help\fR] [\fB\-\-info\fR]
\fIinfile\fR [\fIoutfile\fR]
.SH "DESCRIPTION"
.IX Header "DESCRIPTION"
@@ -208,10 +221,10 @@ use \fB\-S\fR to remove sections containing debugging information. In
some cases \fB\-R\fR will be useful to remove sections which contain
information that is not needed by the binary file.
.PP
-Note \- \fBobjcopy\fR is not able to change the endianness of its input
-files. If the input format has an endianness, (some formats do not),
+Note\-\-\-\fBobjcopy\fR is not able to change the endianness of its input
+files. If the input format has an endianness (some formats do not),
\&\fBobjcopy\fR can only copy the inputs into file formats that have the
-same endianness or which have no endianness (eg \fBsrec\fR).
+same endianness or which have no endianness (e.g., \fBsrec\fR).
.SH "OPTIONS"
.IX Header "OPTIONS"
.IP "\fIinfile\fR" 4
@@ -293,7 +306,7 @@ Do not copy relocation and symbol information from the source file.
.IP "\fB\-\-strip\-debug\fR" 4
.IX Item "--strip-debug"
.PD
-Do not copy debugging symbols from the source file.
+Do not copy debugging symbols or sections from the source file.
.IP "\fB\-\-strip\-unneeded\fR" 4
.IX Item "--strip-unneeded"
Strip all symbols that are not needed for relocation processing.
@@ -337,6 +350,25 @@ visible externally. This option may be given more than once.
.IX Item "--weaken-symbol=symbolname"
.PD
Make symbol \fIsymbolname\fR weak. This option may be given more than once.
+.IP "\fB\-w\fR" 4
+.IX Item "-w"
+.PD 0
+.IP "\fB\-\-wildcard\fR" 4
+.IX Item "--wildcard"
+.PD
+Permit regular expressions in \fIsymbolname\fRs used in other command
+line options. The question mark (?), asterisk (*), backslash (\e) and
+square brackets ([]) operators can be used anywhere in the symbol
+name. If the first character of the symbol name is the exclamation
+point (!) then the sense of the switch is reversed for that symbol.
+For example:
+.Sp
+.Vb 1
+\& -w -W !foo -W fo*
+.Ve
+.Sp
+would cause objcopy to weaken all symbols that start with ``fo''
+except for the symbol ``foo''.
.IP "\fB\-x\fR" 4
.IX Item "-x"
.PD 0
@@ -547,6 +579,12 @@ creating S3\-only record format.
Change the name of a symbol \fIold\fR, to \fInew\fR. This can be useful
when one is trying link two things together for which you have no
source, and there are name collisions.
+.IP "\fB\-\-redefine\-syms=\fR\fIfilename\fR" 4
+.IX Item "--redefine-syms=filename"
+Apply \fB\-\-redefine\-sym\fR to each symbol pair "\fIold\fR \fInew\fR"
+listed in the file \fIfilename\fR. \fIfilename\fR is simply a flat file,
+with one symbol pair per line. Line comments may be introduced by the hash
+character. This option may be given more than once.
.IP "\fB\-\-weaken\fR" 4
.IX Item "--weaken"
Change all global symbols in the file to be weak. This can be useful
@@ -590,6 +628,89 @@ If the output architecture has alternate machine codes, use the
a machine is assigned an official code and the tool-chain adopts the
new code, but other applications still depend on the original code
being used.
+.IP "\fB\-\-writable\-text\fR" 4
+.IX Item "--writable-text"
+Mark the output text as writable. This option isn't meaningful for all
+object file formats.
+.IP "\fB\-\-readonly\-text\fR" 4
+.IX Item "--readonly-text"
+Make the output text write protected. This option isn't meaningful for all
+object file formats.
+.IP "\fB\-\-pure\fR" 4
+.IX Item "--pure"
+Mark the output file as demand paged. This option isn't meaningful for all
+object file formats.
+.IP "\fB\-\-impure\fR" 4
+.IX Item "--impure"
+Mark the output file as impure. This option isn't meaningful for all
+object file formats.
+.IP "\fB\-\-prefix\-symbols=\fR\fIstring\fR" 4
+.IX Item "--prefix-symbols=string"
+Prefix all symbols in the output file with \fIstring\fR.
+.IP "\fB\-\-prefix\-sections=\fR\fIstring\fR" 4
+.IX Item "--prefix-sections=string"
+Prefix all section names in the output file with \fIstring\fR.
+.IP "\fB\-\-prefix\-alloc\-sections=\fR\fIstring\fR" 4
+.IX Item "--prefix-alloc-sections=string"
+Prefix all the names of all allocated sections in the output file with
+\&\fIstring\fR.
+.IP "\fB\-\-add\-gnu\-debuglink=\fR\fIpath-to-file\fR" 4
+.IX Item "--add-gnu-debuglink=path-to-file"
+Creates a .gnu_debuglink section which contains a reference to \fIpath-to-file\fR
+and adds it to the output file.
+.IP "\fB\-\-only\-keep\-debug\fR" 4
+.IX Item "--only-keep-debug"
+Strip a file, removing any sections that would be stripped by
+\&\fB\-\-strip\-debug\fR and leaving the debugging sections.
+.Sp
+The intention is that this option will be used in conjunction with
+\&\fB\-\-add\-gnu\-debuglink\fR to create a two part executable. One a
+stripped binary which will occupy less space in \s-1RAM\s0 and in a
+distribution and the second a debugging information file which is only
+needed if debugging abilities are required. The suggested procedure
+to create these files is as follows:
+.RS 4
+.IP "1.<Link the executable as normal. Assuming that is is called>" 4
+.IX Item "1.<Link the executable as normal. Assuming that is is called>"
+\&\f(CW\*(C`foo\*(C'\fR then...
+.ie n .IP "1.<Run ""objcopy \-\-only\-keep\-debug foo foo.dbg"" to>" 4
+.el .IP "1.<Run \f(CWobjcopy \-\-only\-keep\-debug foo foo.dbg\fR to>" 4
+.IX Item "1.<Run objcopy --only-keep-debug foo foo.dbg to>"
+create a file containing the debugging info.
+.ie n .IP "1.<Run ""objcopy \-\-strip\-debug foo"" to create a>" 4
+.el .IP "1.<Run \f(CWobjcopy \-\-strip\-debug foo\fR to create a>" 4
+.IX Item "1.<Run objcopy --strip-debug foo to create a>"
+stripped executable.
+.ie n .IP "1.<Run ""objcopy \-\-add\-gnu\-debuglink=foo.dbg foo"">" 4
+.el .IP "1.<Run \f(CWobjcopy \-\-add\-gnu\-debuglink=foo.dbg foo\fR>" 4
+.IX Item "1.<Run objcopy --add-gnu-debuglink=foo.dbg foo>"
+to add a link to the debugging info into the stripped executable.
+.RE
+.RS 4
+.Sp
+Note \- the choice of \f(CW\*(C`.dbg\*(C'\fR as an extension for the debug info
+file is arbitrary. Also the \f(CW\*(C`\-\-only\-keep\-debug\*(C'\fR step is
+optional. You could instead do this:
+.IP "1.<Link the executable as normal.>" 4
+.IX Item "1.<Link the executable as normal.>"
+.PD 0
+.ie n .IP "1.<Copy ""foo""\fR to \f(CW""foo.full"">" 4
+.el .IP "1.<Copy \f(CWfoo\fR to \f(CWfoo.full\fR>" 4
+.IX Item "1.<Copy foo to foo.full>"
+.ie n .IP "1.<Run ""objcopy \-\-strip\-debug foo"">" 4
+.el .IP "1.<Run \f(CWobjcopy \-\-strip\-debug foo\fR>" 4
+.IX Item "1.<Run objcopy --strip-debug foo>"
+.ie n .IP "1.<Run ""objcopy \-\-add\-gnu\-debuglink=foo.full foo"">" 4
+.el .IP "1.<Run \f(CWobjcopy \-\-add\-gnu\-debuglink=foo.full foo\fR>" 4
+.IX Item "1.<Run objcopy --add-gnu-debuglink=foo.full foo>"
+.RE
+.RS 4
+.PD
+.Sp
+ie the file pointed to by the \fB\-\-add\-gnu\-debuglink\fR can be the
+full executable. It does not have to be a file created by the
+\&\fB\-\-only\-keep\-debug\fR switch.
+.RE
.IP "\fB\-V\fR" 4
.IX Item "-V"
.PD 0
@@ -608,16 +729,20 @@ archives, \fBobjcopy \-V\fR lists all members of the archive.
.IP "\fB\-\-help\fR" 4
.IX Item "--help"
Show a summary of the options to \fBobjcopy\fR.
+.IP "\fB\-\-info\fR" 4
+.IX Item "--info"
+Display a list showing all architectures and object formats available.
.SH "SEE ALSO"
.IX Header "SEE ALSO"
\&\fIld\fR\|(1), \fIobjdump\fR\|(1), and the Info entries for \fIbinutils\fR.
.SH "COPYRIGHT"
.IX Header "COPYRIGHT"
-Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001, 2002 Free Software Foundation, Inc.
+Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000,
+2001, 2002, 2003 Free Software Foundation, Inc.
.PP
Permission is granted to copy, distribute and/or modify this document
under the terms of the \s-1GNU\s0 Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
-section entitled \*(L"\s-1GNU\s0 Free Documentation License\*(R".
+section entitled ``\s-1GNU\s0 Free Documentation License''.
diff --git a/contrib/binutils/binutils/doc/objdump.1 b/contrib/binutils/binutils/doc/objdump.1
index 24d8951..1e9baf5 100644
--- a/contrib/binutils/binutils/doc/objdump.1
+++ b/contrib/binutils/binutils/doc/objdump.1
@@ -1,4 +1,4 @@
-.\" Automatically generated by Pod::Man v1.3, Pod::Parser v1.13
+.\" Automatically generated by Pod::Man v1.37, Pod::Parser v1.14
.\"
.\" Standard preamble:
.\" ========================================================================
@@ -21,7 +21,6 @@
..
.de Ve \" End verbatim text
.ft R
-
.fi
..
.\" Set up some character translations and predefined strings. \*(-- will
@@ -129,8 +128,7 @@
.\" ========================================================================
.\"
.IX Title "OBJDUMP 1"
-.TH OBJDUMP 1 "2002-08-05" "binutils-2.12.91" "GNU Development Tools"
-.UC
+.TH OBJDUMP 1 "2004-04-09" "binutils-2.14.91" "GNU Development Tools"
.SH "NAME"
objdump \- display information from object files.
.SH "SYNOPSIS"
@@ -145,6 +143,7 @@ objdump [\fB\-a\fR|\fB\-\-archive\-headers\fR]
[\fB\-f\fR|\fB\-\-file\-headers\fR]
[\fB\-\-file\-start\-context\fR]
[\fB\-g\fR|\fB\-\-debugging\fR]
+ [\fB\-e\fR|\fB\-\-debugging\-tags\fR]
[\fB\-h\fR|\fB\-\-section\-headers\fR|\fB\-\-headers\fR]
[\fB\-i\fR|\fB\-\-info\fR]
[\fB\-j\fR \fIsection\fR|\fB\-\-section=\fR\fIsection\fR]
@@ -184,7 +183,7 @@ object files.
.IX Header "OPTIONS"
The long and short forms of options, shown here as alternatives, are
equivalent. At least one option from the list
-\&\fB\-a,\-d,\-D,\-f,\-g,\-G,\-h,\-H,\-p,\-r,\-R,\-S,\-t,\-T,\-V,\-x\fR must be given.
+\&\fB\-a,\-d,\-D,\-e,\-f,\-g,\-G,\-h,\-H,\-p,\-r,\-R,\-s,\-S,\-t,\-T,\-V,\-x\fR must be given.
.IP "\fB\-a\fR" 4
.IX Item "-a"
.PD 0
@@ -217,6 +216,7 @@ For example,
.Vb 1
\& objdump -b oasys -m vax -h fu.o
.Ve
+.Sp
displays summary information from the section headers (\fB\-h\fR) of
\&\fIfu.o\fR, which is explicitly identified (\fB\-m\fR) as a \s-1VAX\s0 object
file in the format produced by Oasys compilers. You can list the
@@ -232,8 +232,8 @@ Besides removing any initial underscore prepended by the system, this
makes \*(C+ function names readable. Different compilers have different
mangling styles. The optional demangling style argument can be used to
choose an appropriate demangling style for your compiler.
-.IP "\fB\-G\fR" 4
-.IX Item "-G"
+.IP "\fB\-g\fR" 4
+.IX Item "-g"
.PD 0
.IP "\fB\-\-debugging\fR" 4
.IX Item "--debugging"
@@ -241,6 +241,15 @@ choose an appropriate demangling style for your compiler.
Display debugging information. This attempts to parse debugging
information stored in the file and print it out using a C like syntax.
Only certain types of debugging information have been implemented.
+Some other types are supported by \fBreadelf \-w\fR.
+.IP "\fB\-e\fR" 4
+.IX Item "-e"
+.PD 0
+.IP "\fB\-\-debugging\-tags\fR" 4
+.IX Item "--debugging-tags"
+.PD
+Like \fB\-g\fR, but the information is generated in a format compatible
+with ctags tool.
.IP "\fB\-d\fR" 4
.IX Item "-d"
.PD 0
@@ -262,11 +271,6 @@ those expected to contain instructions.
.IX Item "--prefix-addresses"
When disassembling, print the complete address on each line. This is
the older disassembly format.
-.IP "\fB\-\-disassemble\-zeroes\fR" 4
-.IX Item "--disassemble-zeroes"
-Normally the disassembly output will skip blocks of zeroes. This
-option directs the disassembler to disassemble those blocks, just like
-any other data.
.IP "\fB\-EB\fR" 4
.IX Item "-EB"
.PD 0
@@ -281,8 +285,8 @@ does not describe endianness information, such as S\-records.
.IP "\fB\-f\fR" 4
.IX Item "-f"
.PD 0
-.IP "\fB\-\-file\-header\fR" 4
-.IX Item "--file-header"
+.IP "\fB\-\-file\-headers\fR" 4
+.IX Item "--file-headers"
.PD
Display summary information from the overall header of
each of the \fIobjfile\fR files.
@@ -294,10 +298,10 @@ context to the start of the file.
.IP "\fB\-h\fR" 4
.IX Item "-h"
.PD 0
-.IP "\fB\-\-section\-header\fR" 4
-.IX Item "--section-header"
-.IP "\fB\-\-header\fR" 4
-.IX Item "--header"
+.IP "\fB\-\-section\-headers\fR" 4
+.IX Item "--section-headers"
+.IP "\fB\-\-headers\fR" 4
+.IX Item "--headers"
.PD
Display summary information from the section headers of the
object file.
@@ -310,8 +314,12 @@ although \fBld\fR relocates the sections correctly, using \fBobjdump
\&\-h\fR to list the file section headers cannot show the correct addresses.
Instead, it shows the usual addresses, which are implicit for the
target.
+.IP "\fB\-H\fR" 4
+.IX Item "-H"
+.PD 0
.IP "\fB\-\-help\fR" 4
.IX Item "--help"
+.PD
Print a summary of the options to \fBobjdump\fR and exit.
.IP "\fB\-i\fR" 4
.IX Item "-i"
@@ -354,7 +362,9 @@ architectures with the \fB\-i\fR option.
.IX Item "--disassembler-options=options"
.PD
Pass target specific information to the disassembler. Only supported on
-some targets.
+some targets. If it is necessary to specify more than one
+disassembler option then multiple \fB\-M\fR options can be used or
+can be placed together into a comma separated list.
.Sp
If the target is an \s-1ARM\s0 architecture then this switch can be used to
select which register name set is used during disassembler. Specifying
@@ -368,7 +378,7 @@ just use \fBr\fR followed by the register number.
There are also two variants on the \s-1APCS\s0 register naming scheme enabled
by \fB\-M reg-names-atpcs\fR and \fB\-M reg-names-special-atpcs\fR which
use the ARM/Thumb Procedure Call Standard naming conventions. (Either
-with the normal register name or the special register names).
+with the normal register names or the special register names).
.Sp
This option can also be used for \s-1ARM\s0 architectures to force the
disassembler to interpret all instructions as Thumb instructions by
@@ -386,12 +396,62 @@ intel syntax mode and \s-1AT&T\s0 syntax mode. \fBaddr32\fR,
address size and operand size. These four options will be overridden if
\&\fBx86\-64\fR, \fBi386\fR or \fBi8086\fR appear later in the
option string. Lastly, \fBsuffix\fR, when in \s-1AT&T\s0 mode,
-instructs the dissassembler to print a mnemonic suffix even when the
+instructs the disassembler to print a mnemonic suffix even when the
suffix could be inferred by the operands.
.Sp
For \s-1PPC\s0, \fBbooke\fR, \fBbooke32\fR and \fBbooke64\fR select
disassembly of BookE instructions. \fB32\fR and \fB64\fR select
PowerPC and PowerPC64 disassembly, respectively.
+.Sp
+For \s-1MIPS\s0, this option controls the printing of register names in
+disassembled instructions. Multiple selections from the
+following may be specified as a comma separated string, and invalid
+options are ignored:
+.RS 4
+.ie n .IP """gpr\-names=\f(CI\s-1ABI\s0\f(CW""" 4
+.el .IP "\f(CWgpr\-names=\f(CI\s-1ABI\s0\f(CW\fR" 4
+.IX Item "gpr-names=ABI"
+Print \s-1GPR\s0 (general\-purpose register) names as appropriate
+for the specified \s-1ABI\s0. By default, \s-1GPR\s0 names are selected according to
+the \s-1ABI\s0 of the binary being disassembled.
+.ie n .IP """fpr\-names=\f(CI\s-1ABI\s0\f(CW""" 4
+.el .IP "\f(CWfpr\-names=\f(CI\s-1ABI\s0\f(CW\fR" 4
+.IX Item "fpr-names=ABI"
+Print \s-1FPR\s0 (floating\-point register) names as
+appropriate for the specified \s-1ABI\s0. By default, \s-1FPR\s0 numbers are printed
+rather than names.
+.ie n .IP """cp0\-names=\f(CI\s-1ARCH\s0\f(CW""" 4
+.el .IP "\f(CWcp0\-names=\f(CI\s-1ARCH\s0\f(CW\fR" 4
+.IX Item "cp0-names=ARCH"
+Print \s-1CP0\s0 (system control coprocessor; coprocessor 0) register names
+as appropriate for the \s-1CPU\s0 or architecture specified by
+\&\fI\s-1ARCH\s0\fR. By default, \s-1CP0\s0 register names are selected according to
+the architecture and \s-1CPU\s0 of the binary being disassembled.
+.ie n .IP """hwr\-names=\f(CI\s-1ARCH\s0\f(CW""" 4
+.el .IP "\f(CWhwr\-names=\f(CI\s-1ARCH\s0\f(CW\fR" 4
+.IX Item "hwr-names=ARCH"
+Print \s-1HWR\s0 (hardware register, used by the \f(CW\*(C`rdhwr\*(C'\fR instruction) names
+as appropriate for the \s-1CPU\s0 or architecture specified by
+\&\fI\s-1ARCH\s0\fR. By default, \s-1HWR\s0 names are selected according to
+the architecture and \s-1CPU\s0 of the binary being disassembled.
+.ie n .IP """reg\-names=\f(CI\s-1ABI\s0\f(CW""" 4
+.el .IP "\f(CWreg\-names=\f(CI\s-1ABI\s0\f(CW\fR" 4
+.IX Item "reg-names=ABI"
+Print \s-1GPR\s0 and \s-1FPR\s0 names as appropriate for the selected \s-1ABI\s0.
+.ie n .IP """reg\-names=\f(CI\s-1ARCH\s0\f(CW""" 4
+.el .IP "\f(CWreg\-names=\f(CI\s-1ARCH\s0\f(CW\fR" 4
+.IX Item "reg-names=ARCH"
+Print CPU-specific register names (\s-1CP0\s0 register and \s-1HWR\s0 names)
+as appropriate for the selected \s-1CPU\s0 or architecture.
+.RE
+.RS 4
+.Sp
+For any of the options listed above, \fI\s-1ABI\s0\fR or
+\&\fI\s-1ARCH\s0\fR may be specified as \fBnumeric\fR to have numbers printed
+rather than names, for the selected types of registers.
+You can list the available values of \fI\s-1ABI\s0\fR and \fI\s-1ARCH\s0\fR using
+the \fB\-\-help\fR option.
+.RE
.IP "\fB\-p\fR" 4
.IX Item "-p"
.PD 0
@@ -425,7 +485,8 @@ libraries.
.IP "\fB\-\-full\-contents\fR" 4
.IX Item "--full-contents"
.PD
-Display the full contents of any sections requested.
+Display the full contents of any sections requested. By default all
+non-empty sections are displayed.
.IP "\fB\-S\fR" 4
.IX Item "-S"
.PD 0
@@ -482,14 +543,18 @@ Print the dynamic symbol table entries of the file. This is only
meaningful for dynamic objects, such as certain types of shared
libraries. This is similar to the information provided by the \fBnm\fR
program when given the \fB\-D\fR (\fB\-\-dynamic\fR) option.
+.IP "\fB\-V\fR" 4
+.IX Item "-V"
+.PD 0
.IP "\fB\-\-version\fR" 4
.IX Item "--version"
+.PD
Print the version number of \fBobjdump\fR and exit.
.IP "\fB\-x\fR" 4
.IX Item "-x"
.PD 0
-.IP "\fB\-\-all\-header\fR" 4
-.IX Item "--all-header"
+.IP "\fB\-\-all\-headers\fR" 4
+.IX Item "--all-headers"
.PD
Display all available header information, including the symbol table and
relocation entries. Using \fB\-x\fR is equivalent to specifying all of
@@ -502,16 +567,26 @@ relocation entries. Using \fB\-x\fR is equivalent to specifying all of
.PD
Format some lines for output devices that have more than 80 columns.
Also do not truncate symbol names when they are displayed.
+.IP "\fB\-z\fR" 4
+.IX Item "-z"
+.PD 0
+.IP "\fB\-\-disassemble\-zeroes\fR" 4
+.IX Item "--disassemble-zeroes"
+.PD
+Normally the disassembly output will skip blocks of zeroes. This
+option directs the disassembler to disassemble those blocks, just like
+any other data.
.SH "SEE ALSO"
.IX Header "SEE ALSO"
\&\fInm\fR\|(1), \fIreadelf\fR\|(1), and the Info entries for \fIbinutils\fR.
.SH "COPYRIGHT"
.IX Header "COPYRIGHT"
-Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001, 2002 Free Software Foundation, Inc.
+Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000,
+2001, 2002, 2003 Free Software Foundation, Inc.
.PP
Permission is granted to copy, distribute and/or modify this document
under the terms of the \s-1GNU\s0 Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
-section entitled \*(L"\s-1GNU\s0 Free Documentation License\*(R".
+section entitled ``\s-1GNU\s0 Free Documentation License''.
diff --git a/contrib/binutils/binutils/doc/ranlib.1 b/contrib/binutils/binutils/doc/ranlib.1
index 5512755..0d8e4ac 100644
--- a/contrib/binutils/binutils/doc/ranlib.1
+++ b/contrib/binutils/binutils/doc/ranlib.1
@@ -1,4 +1,4 @@
-.\" Automatically generated by Pod::Man v1.3, Pod::Parser v1.13
+.\" Automatically generated by Pod::Man v1.37, Pod::Parser v1.14
.\"
.\" Standard preamble:
.\" ========================================================================
@@ -21,7 +21,6 @@
..
.de Ve \" End verbatim text
.ft R
-
.fi
..
.\" Set up some character translations and predefined strings. \*(-- will
@@ -129,8 +128,7 @@
.\" ========================================================================
.\"
.IX Title "RANLIB 1"
-.TH RANLIB 1 "2002-08-05" "binutils-2.12.91" "GNU Development Tools"
-.UC
+.TH RANLIB 1 "2004-04-09" "binutils-2.14.91" "GNU Development Tools"
.SH "NAME"
ranlib \- generate index to archive.
.SH "SYNOPSIS"
@@ -166,11 +164,12 @@ Show the version number of \fBranlib\fR.
\&\fIar\fR\|(1), \fInm\fR\|(1), and the Info entries for \fIbinutils\fR.
.SH "COPYRIGHT"
.IX Header "COPYRIGHT"
-Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001, 2002 Free Software Foundation, Inc.
+Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000,
+2001, 2002, 2003 Free Software Foundation, Inc.
.PP
Permission is granted to copy, distribute and/or modify this document
under the terms of the \s-1GNU\s0 Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
-section entitled \*(L"\s-1GNU\s0 Free Documentation License\*(R".
+section entitled ``\s-1GNU\s0 Free Documentation License''.
diff --git a/contrib/binutils/binutils/doc/readelf.1 b/contrib/binutils/binutils/doc/readelf.1
index 81f655d..7b48563 100644
--- a/contrib/binutils/binutils/doc/readelf.1
+++ b/contrib/binutils/binutils/doc/readelf.1
@@ -1,4 +1,4 @@
-.\" Automatically generated by Pod::Man v1.3, Pod::Parser v1.13
+.\" Automatically generated by Pod::Man v1.37, Pod::Parser v1.14
.\"
.\" Standard preamble:
.\" ========================================================================
@@ -21,7 +21,6 @@
..
.de Ve \" End verbatim text
.ft R
-
.fi
..
.\" Set up some character translations and predefined strings. \*(-- will
@@ -129,10 +128,9 @@
.\" ========================================================================
.\"
.IX Title "READELF 1"
-.TH READELF 1 "2002-08-05" "binutils-2.12.91" "GNU Development Tools"
-.UC
+.TH READELF 1 "2004-04-09" "binutils-2.14.91" "GNU Development Tools"
.SH "NAME"
-readelf \- Displays information about \s-1ELF\s0 files.
+readelf \- Displays information about ELF files.
.SH "SYNOPSIS"
.IX Header "SYNOPSIS"
readelf [\fB\-a\fR|\fB\-\-all\fR]
@@ -146,10 +144,12 @@ readelf [\fB\-a\fR|\fB\-\-all\fR]
[\fB\-u\fR|\fB\-\-unwind\fR]
[\fB\-d\fR|\fB\-\-dynamic\fR]
[\fB\-V\fR|\fB\-\-version\-info\fR]
+ [\fB\-A\fR|\fB\-\-arch\-specific\fR]
[\fB\-D\fR|\fB\-\-use\-dynamic\fR]
[\fB\-x\fR <number>|\fB\-\-hex\-dump=\fR<number>]
- [\fB\-w[liaprmfFso]\fR|\fB\-\-debug\-dump\fR[=line,=info,=abbrev,=pubnames,=ranges,=macro,=frames,=str,=loc]]
- [\fB\-histogram\fR]
+ [\fB\-w[liaprmfFso]\fR|
+ \fB\-\-debug\-dump\fR[=line,=info,=abbrev,=pubnames,=ranges,=macro,=frames,=frames\-interp,=str,=loc]]
+ [\fB\-I\fR|\fB\-histogram\fR]
[\fB\-v\fR|\fB\-\-version\fR]
[\fB\-W\fR|\fB\-\-wide\fR]
[\fB\-H\fR|\fB\-\-help\fR]
@@ -159,9 +159,13 @@ readelf [\fB\-a\fR|\fB\-\-all\fR]
\&\fBreadelf\fR displays information about one or more \s-1ELF\s0 format object
files. The options control what particular information to display.
.PP
-\&\fIelffile\fR... are the object files to be examined. At the
-moment, \fBreadelf\fR does not support examining archives, nor does it
-support examing 64 bit \s-1ELF\s0 files.
+\&\fIelffile\fR... are the object files to be examined. 32\-bit and
+64\-bit \s-1ELF\s0 files are supported, as are archives containing \s-1ELF\s0 files.
+.PP
+This program performs a similar function to \fBobjdump\fR but it
+goes into more detail and it exists independently of the \s-1BFD\s0
+library, so if there is a bug in \s-1BFD\s0 then readelf will not be
+affected.
.SH "OPTIONS"
.IX Header "OPTIONS"
The long and short forms of options, shown here as alternatives, are
@@ -243,6 +247,14 @@ Displays the contents of the file's relocation section, if it has one.
.PD
Displays the contents of the file's unwind section, if it has one. Only
the unwind sections for \s-1IA64\s0 \s-1ELF\s0 files are currently supported.
+.IP "\fB\-u\fR" 4
+.IX Item "-u"
+.PD 0
+.IP "\fB\-\-unwind\fR" 4
+.IX Item "--unwind"
+.PD
+Displays the contents of the file's unwind section, if it has one. Only
+the unwind sections for \s-1IA64\s0 \s-1ELF\s0 files are currently supported.
.IP "\fB\-d\fR" 4
.IX Item "-d"
.PD 0
@@ -258,6 +270,14 @@ Displays the contents of the file's dynamic section, if it has one.
.PD
Displays the contents of the version sections in the file, it they
exist.
+.IP "\fB\-A\fR" 4
+.IX Item "-A"
+.PD 0
+.IP "\fB\-\-arch\-specific\fR" 4
+.IX Item "--arch-specific"
+.PD
+Displays architecture-specific information in the file, if there
+is any.
.IP "\fB\-D\fR" 4
.IX Item "-D"
.PD 0
@@ -277,14 +297,18 @@ Displays the contents of the indicated section as a hexadecimal dump.
.IP "\fB\-w[liaprmfFso]\fR" 4
.IX Item "-w[liaprmfFso]"
.PD 0
-.IP "\fB\-\-debug\-dump[=line,=info,=abbrev,=pubnames,=ranges,=macro,=frames,=str,=loc]\fR" 4
-.IX Item "--debug-dump[=line,=info,=abbrev,=pubnames,=ranges,=macro,=frames,=str,=loc]"
+.IP "\fB\-\-debug\-dump[=line,=info,=abbrev,=pubnames,=ranges,=macro,=frames,=frames\-interp,=str,=loc]\fR" 4
+.IX Item "--debug-dump[=line,=info,=abbrev,=pubnames,=ranges,=macro,=frames,=frames-interp,=str,=loc]"
.PD
Displays the contents of the debug sections in the file, if any are
present. If one of the optional letters or words follows the switch
then only data found in those specific sections will be dumped.
+.IP "\fB\-I\fR" 4
+.IX Item "-I"
+.PD 0
.IP "\fB\-\-histogram\fR" 4
.IX Item "--histogram"
+.PD
Display a histogram of bucket list lengths when displaying the contents
of the symbol tables.
.IP "\fB\-v\fR" 4
@@ -317,11 +341,12 @@ Display the command line options understood by \fBreadelf\fR.
\&\fIobjdump\fR\|(1), and the Info entries for \fIbinutils\fR.
.SH "COPYRIGHT"
.IX Header "COPYRIGHT"
-Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001, 2002 Free Software Foundation, Inc.
+Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000,
+2001, 2002, 2003 Free Software Foundation, Inc.
.PP
Permission is granted to copy, distribute and/or modify this document
under the terms of the \s-1GNU\s0 Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
-section entitled \*(L"\s-1GNU\s0 Free Documentation License\*(R".
+section entitled ``\s-1GNU\s0 Free Documentation License''.
diff --git a/contrib/binutils/binutils/doc/size.1 b/contrib/binutils/binutils/doc/size.1
index 09a8156..4bf0512 100644
--- a/contrib/binutils/binutils/doc/size.1
+++ b/contrib/binutils/binutils/doc/size.1
@@ -1,4 +1,4 @@
-.\" Automatically generated by Pod::Man v1.3, Pod::Parser v1.13
+.\" Automatically generated by Pod::Man v1.37, Pod::Parser v1.14
.\"
.\" Standard preamble:
.\" ========================================================================
@@ -21,7 +21,6 @@
..
.de Ve \" End verbatim text
.ft R
-
.fi
..
.\" Set up some character translations and predefined strings. \*(-- will
@@ -129,8 +128,7 @@
.\" ========================================================================
.\"
.IX Title "SIZE 1"
-.TH SIZE 1 "2002-08-05" "binutils-2.12.91" "GNU Development Tools"
-.UC
+.TH SIZE 1 "2004-04-09" "binutils-2.14.91" "GNU Development Tools"
.SH "NAME"
size \- list section sizes and total size.
.SH "SYNOPSIS"
@@ -176,6 +174,7 @@ Here is an example of the Berkeley (default) format of output from
\& 294880 81920 11592 388392 5ed28 ranlib
\& 294880 81920 11888 388688 5ee50 size
.Ve
+.Sp
This is the same data, but displayed closer to System V conventions:
.Sp
.Vb 7
@@ -187,6 +186,7 @@ This is the same data, but displayed closer to System V conventions:
\& .bss 11592 385024
\& Total 388392
.Ve
+.Sp
.Vb 6
\& size :
\& section size addr
@@ -239,11 +239,12 @@ Display the version number of \fBsize\fR.
\&\fIar\fR\|(1), \fIobjdump\fR\|(1), \fIreadelf\fR\|(1), and the Info entries for \fIbinutils\fR.
.SH "COPYRIGHT"
.IX Header "COPYRIGHT"
-Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001, 2002 Free Software Foundation, Inc.
+Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000,
+2001, 2002, 2003 Free Software Foundation, Inc.
.PP
Permission is granted to copy, distribute and/or modify this document
under the terms of the \s-1GNU\s0 Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
-section entitled \*(L"\s-1GNU\s0 Free Documentation License\*(R".
+section entitled ``\s-1GNU\s0 Free Documentation License''.
diff --git a/contrib/binutils/binutils/doc/strings.1 b/contrib/binutils/binutils/doc/strings.1
index 74d9112..f3b9be0 100644
--- a/contrib/binutils/binutils/doc/strings.1
+++ b/contrib/binutils/binutils/doc/strings.1
@@ -1,4 +1,4 @@
-.\" Automatically generated by Pod::Man v1.3, Pod::Parser v1.13
+.\" Automatically generated by Pod::Man v1.37, Pod::Parser v1.14
.\"
.\" Standard preamble:
.\" ========================================================================
@@ -21,7 +21,6 @@
..
.de Ve \" End verbatim text
.ft R
-
.fi
..
.\" Set up some character translations and predefined strings. \*(-- will
@@ -129,8 +128,7 @@
.\" ========================================================================
.\"
.IX Title "STRINGS 1"
-.TH STRINGS 1 "2002-08-05" "binutils-2.12.91" "GNU Development Tools"
-.UC
+.TH STRINGS 1 "2004-04-09" "binutils-2.14.91" "GNU Development Tools"
.SH "NAME"
strings \- print the strings of printable characters in files.
.SH "SYNOPSIS"
@@ -206,11 +204,11 @@ octal, \fBx\fR for hexadecimal, or \fBd\fR for decimal.
.IX Item "--encoding=encoding"
.PD
Select the character encoding of the strings that are to be found.
-Possible values for \fIencoding\fR are: \fBs\fR = single-byte
-characters (\s-1ASCII\s0, \s-1ISO\s0 8859, etc., default), \fBb\fR = 16\-bit
-Bigendian, \fBl\fR = 16\-bit Littleendian, \fBB\fR = 32\-bit Bigendian,
-\&\fBL\fR = 32\-bit Littleendian. Useful for finding wide character
-strings.
+Possible values for \fIencoding\fR are: \fBs\fR = single\-7\-bit\-byte
+characters (\s-1ASCII\s0, \s-1ISO\s0 8859, etc., default), \fBS\fR =
+single\-8\-bit\-byte characters, \fBb\fR = 16\-bit bigendian, \fBl\fR =
+16\-bit littleendian, \fBB\fR = 32\-bit bigendian, \fBL\fR = 32\-bit
+littleendian. Useful for finding wide character strings.
.IP "\fB\-\-target=\fR\fIbfdname\fR" 4
.IX Item "--target=bfdname"
Specify an object code format other than your system's default format.
@@ -227,11 +225,12 @@ Print the program version number on the standard output and exit.
and the Info entries for \fIbinutils\fR.
.SH "COPYRIGHT"
.IX Header "COPYRIGHT"
-Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001, 2002 Free Software Foundation, Inc.
+Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000,
+2001, 2002, 2003 Free Software Foundation, Inc.
.PP
Permission is granted to copy, distribute and/or modify this document
under the terms of the \s-1GNU\s0 Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
-section entitled \*(L"\s-1GNU\s0 Free Documentation License\*(R".
+section entitled ``\s-1GNU\s0 Free Documentation License''.
diff --git a/contrib/binutils/binutils/doc/strip.1 b/contrib/binutils/binutils/doc/strip.1
index f8cca3b..2073020 100644
--- a/contrib/binutils/binutils/doc/strip.1
+++ b/contrib/binutils/binutils/doc/strip.1
@@ -1,4 +1,4 @@
-.\" Automatically generated by Pod::Man v1.3, Pod::Parser v1.13
+.\" Automatically generated by Pod::Man v1.37, Pod::Parser v1.14
.\"
.\" Standard preamble:
.\" ========================================================================
@@ -21,7 +21,6 @@
..
.de Ve \" End verbatim text
.ft R
-
.fi
..
.\" Set up some character translations and predefined strings. \*(-- will
@@ -129,22 +128,25 @@
.\" ========================================================================
.\"
.IX Title "STRIP 1"
-.TH STRIP 1 "2002-08-05" "binutils-2.12.91" "GNU Development Tools"
-.UC
+.TH STRIP 1 "2004-04-09" "binutils-2.14.91" "GNU Development Tools"
.SH "NAME"
strip \- Discard symbols from object files.
.SH "SYNOPSIS"
.IX Header "SYNOPSIS"
-strip [\fB\-F\fR \fIbfdname\fR |\fB\-\-target=\fR\fIbfdname\fR ]
- [\fB\-I\fR \fIbfdname\fR |\fB\-\-input\-target=\fR\fIbfdname\fR ]
- [\fB\-O\fR \fIbfdname\fR |\fB\-\-output\-target=\fR\fIbfdname\fR ]
- [\fB\-s\fR|\fB\-\-strip\-all\fR] [\fB\-S\fR|\fB\-g\fR|\fB\-d\fR|\fB\-\-strip\-debug\fR]
- [\fB\-K\fR \fIsymbolname\fR |\fB\-\-keep\-symbol=\fR\fIsymbolname\fR ]
- [\fB\-N\fR \fIsymbolname\fR |\fB\-\-strip\-symbol=\fR\fIsymbolname\fR ]
- [\fB\-x\fR|\fB\-\-discard\-all\fR ] [\fB\-X\fR |\fB\-\-discard\-locals\fR]
- [\fB\-R\fR \fIsectionname\fR |\fB\-\-remove\-section=\fR\fIsectionname\fR ]
- [\fB\-o\fR \fIfile\fR ] [\fB\-p\fR|\fB\-\-preserve\-dates\fR]
- [\fB\-v\fR |\fB\-\-verbose\fR] [\fB\-V\fR|\fB\-\-version\fR] [\fB\-\-help\fR]
+strip [\fB\-F\fR \fIbfdname\fR |\fB\-\-target=\fR\fIbfdname\fR]
+ [\fB\-I\fR \fIbfdname\fR |\fB\-\-input\-target=\fR\fIbfdname\fR]
+ [\fB\-O\fR \fIbfdname\fR |\fB\-\-output\-target=\fR\fIbfdname\fR]
+ [\fB\-s\fR|\fB\-\-strip\-all\fR]
+ [\fB\-S\fR|\fB\-g\fR|\fB\-d\fR|\fB\-\-strip\-debug\fR]
+ [\fB\-K\fR \fIsymbolname\fR |\fB\-\-keep\-symbol=\fR\fIsymbolname\fR]
+ [\fB\-N\fR \fIsymbolname\fR |\fB\-\-strip\-symbol=\fR\fIsymbolname\fR]
+ [\fB\-w\fR|\fB\-\-wildcard\fR]
+ [\fB\-x\fR|\fB\-\-discard\-all\fR] [\fB\-X\fR |\fB\-\-discard\-locals\fR]
+ [\fB\-R\fR \fIsectionname\fR |\fB\-\-remove\-section=\fR\fIsectionname\fR]
+ [\fB\-o\fR \fIfile\fR] [\fB\-p\fR|\fB\-\-preserve\-dates\fR]
+ [\fB\-\-only\-keep\-debug\fR]
+ [\fB\-v\fR |\fB\-\-verbose\fR] [\fB\-V\fR|\fB\-\-version\fR]
+ [\fB\-\-help\fR] [\fB\-\-info\fR]
\fIobjfile\fR...
.SH "DESCRIPTION"
.IX Header "DESCRIPTION"
@@ -167,8 +169,11 @@ code format \fIbfdname\fR, and rewrite it in the same format.
.IP "\fB\-\-help\fR" 4
.IX Item "--help"
Show a summary of the options to \fBstrip\fR and exit.
-.IP "\fB\-I\fR \fIbfdname\fR\fB \fR" 4
-.IX Item "-I bfdname "
+.IP "\fB\-\-info\fR" 4
+.IX Item "--info"
+Display a list showing all architectures and object formats available.
+.IP "\fB\-I\fR \fIbfdname\fR" 4
+.IX Item "-I bfdname"
.PD 0
.IP "\fB\-\-input\-target=\fR\fIbfdname\fR" 4
.IX Item "--input-target=bfdname"
@@ -241,6 +246,25 @@ argument may be specified.
.IX Item "--preserve-dates"
.PD
Preserve the access and modification dates of the file.
+.IP "\fB\-w\fR" 4
+.IX Item "-w"
+.PD 0
+.IP "\fB\-\-wildcard\fR" 4
+.IX Item "--wildcard"
+.PD
+Permit regular expressions in \fIsymbolname\fRs used in other command
+line options. The question mark (?), asterisk (*), backslash (\e) and
+square brackets ([]) operators can be used anywhere in the symbol
+name. If the first character of the symbol name is the exclamation
+point (!) then the sense of the switch is reversed for that symbol.
+For example:
+.Sp
+.Vb 1
+\& -w -K !foo -K fo*
+.Ve
+.Sp
+would cause strip to only keep symbols that start with the letters
+``fo'', but to discard the symbol ``foo''.
.IP "\fB\-x\fR" 4
.IX Item "-x"
.PD 0
@@ -256,6 +280,59 @@ Remove non-global symbols.
.PD
Remove compiler-generated local symbols.
(These usually start with \fBL\fR or \fB.\fR.)
+.IP "\fB\-\-only\-keep\-debug\fR" 4
+.IX Item "--only-keep-debug"
+Strip a file, removing any sections that would be stripped by
+\&\fB\-\-strip\-debug\fR and leaving the debugging sections.
+.Sp
+The intention is that this option will be used in conjunction with
+\&\fB\-\-add\-gnu\-debuglink\fR to create a two part executable. One a
+stripped binary which will occupy less space in \s-1RAM\s0 and in a
+distribution and the second a debugging information file which is only
+needed if debugging abilities are required. The suggested procedure
+to create these files is as follows:
+.RS 4
+.IP "1.<Link the executable as normal. Assuming that is is called>" 4
+.IX Item "1.<Link the executable as normal. Assuming that is is called>"
+\&\f(CW\*(C`foo\*(C'\fR then...
+.ie n .IP "1.<Run ""objcopy \-\-only\-keep\-debug foo foo.dbg"" to>" 4
+.el .IP "1.<Run \f(CWobjcopy \-\-only\-keep\-debug foo foo.dbg\fR to>" 4
+.IX Item "1.<Run objcopy --only-keep-debug foo foo.dbg to>"
+create a file containing the debugging info.
+.ie n .IP "1.<Run ""objcopy \-\-strip\-debug foo"" to create a>" 4
+.el .IP "1.<Run \f(CWobjcopy \-\-strip\-debug foo\fR to create a>" 4
+.IX Item "1.<Run objcopy --strip-debug foo to create a>"
+stripped executable.
+.ie n .IP "1.<Run ""objcopy \-\-add\-gnu\-debuglink=foo.dbg foo"">" 4
+.el .IP "1.<Run \f(CWobjcopy \-\-add\-gnu\-debuglink=foo.dbg foo\fR>" 4
+.IX Item "1.<Run objcopy --add-gnu-debuglink=foo.dbg foo>"
+to add a link to the debugging info into the stripped executable.
+.RE
+.RS 4
+.Sp
+Note \- the choice of \f(CW\*(C`.dbg\*(C'\fR as an extension for the debug info
+file is arbitrary. Also the \f(CW\*(C`\-\-only\-keep\-debug\*(C'\fR step is
+optional. You could instead do this:
+.IP "1.<Link the executable as normal.>" 4
+.IX Item "1.<Link the executable as normal.>"
+.PD 0
+.ie n .IP "1.<Copy ""foo""\fR to \f(CW""foo.full"">" 4
+.el .IP "1.<Copy \f(CWfoo\fR to \f(CWfoo.full\fR>" 4
+.IX Item "1.<Copy foo to foo.full>"
+.ie n .IP "1.<Run ""strip \-\-strip\-debug foo"">" 4
+.el .IP "1.<Run \f(CWstrip \-\-strip\-debug foo\fR>" 4
+.IX Item "1.<Run strip --strip-debug foo>"
+.ie n .IP "1.<Run ""objcopy \-\-add\-gnu\-debuglink=foo.full foo"">" 4
+.el .IP "1.<Run \f(CWobjcopy \-\-add\-gnu\-debuglink=foo.full foo\fR>" 4
+.IX Item "1.<Run objcopy --add-gnu-debuglink=foo.full foo>"
+.RE
+.RS 4
+.PD
+.Sp
+ie the file pointed to by the \fB\-\-add\-gnu\-debuglink\fR can be the
+full executable. It does not have to be a file created by the
+\&\fB\-\-only\-keep\-debug\fR switch.
+.RE
.IP "\fB\-V\fR" 4
.IX Item "-V"
.PD 0
@@ -276,11 +353,12 @@ archives, \fBstrip \-v\fR lists all members of the archive.
the Info entries for \fIbinutils\fR.
.SH "COPYRIGHT"
.IX Header "COPYRIGHT"
-Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001, 2002 Free Software Foundation, Inc.
+Copyright (c) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000,
+2001, 2002, 2003 Free Software Foundation, Inc.
.PP
Permission is granted to copy, distribute and/or modify this document
under the terms of the \s-1GNU\s0 Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
-section entitled \*(L"\s-1GNU\s0 Free Documentation License\*(R".
+section entitled ``\s-1GNU\s0 Free Documentation License''.
diff --git a/contrib/binutils/binutils/filemode.c b/contrib/binutils/binutils/filemode.c
index ca00694f..8b438a9 100644
--- a/contrib/binutils/binutils/filemode.c
+++ b/contrib/binutils/binutils/filemode.c
@@ -1,5 +1,5 @@
/* filemode.c -- make a string describing file modes
- Copyright 1985, 1990, 1991, 1994, 1995, 1997
+ Copyright 1985, 1990, 1991, 1994, 1995, 1997, 2003
Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
@@ -20,8 +20,8 @@
#include "bfd.h"
#include "bucomm.h"
-static char ftypelet PARAMS ((unsigned long));
-static void setst PARAMS ((unsigned long, char *));
+static char ftypelet (unsigned long);
+static void setst (unsigned long, char *);
/* filemodestring - fill in string STR with an ls-style ASCII
representation of the st_mode field of file stats block STATP.
@@ -64,9 +64,7 @@ static void setst PARAMS ((unsigned long, char *));
/* This is not used; only mode_string is used. */
void
-filemodestring (statp, str)
- struct stat *statp;
- char *str;
+filemodestring (struct stat *statp, char *str)
{
mode_string ((unsigned long) statp->st_mode, str);
}
@@ -118,9 +116,7 @@ filemodestring (statp, str)
is given as an argument. */
void
-mode_string (mode, str)
- unsigned long mode;
- char *str;
+mode_string (unsigned long mode, char *str)
{
str[0] = ftypelet ((unsigned long) mode);
str[1] = (mode & S_IRUSR) != 0 ? 'r' : '-';
@@ -140,7 +136,7 @@ mode_string (mode, str)
'd' for directories
'b' for block special files
'c' for character special files
- 'm' for multiplexor files
+ 'm' for multiplexer files
'l' for symbolic links
's' for sockets
'p' for fifos
@@ -195,8 +191,7 @@ mode_string (mode, str)
#endif /* ! defined (S_ISLNK) */
static char
-ftypelet (bits)
- unsigned long bits;
+ftypelet (unsigned long bits)
{
if (S_ISDIR (bits))
return 'd';
@@ -230,9 +225,7 @@ ftypelet (bits)
according to the file mode BITS. */
static void
-setst (bits, chars)
- unsigned long bits ATTRIBUTE_UNUSED;
- char *chars ATTRIBUTE_UNUSED;
+setst (unsigned long bits ATTRIBUTE_UNUSED, char *chars ATTRIBUTE_UNUSED)
{
#ifdef S_ISUID
if (bits & S_ISUID)
diff --git a/contrib/binutils/binutils/ieee.c b/contrib/binutils/binutils/ieee.c
index 4735fb3..1ced603 100644
--- a/contrib/binutils/binutils/ieee.c
+++ b/contrib/binutils/binutils/ieee.c
@@ -1,5 +1,5 @@
/* ieee.c -- Read and write IEEE-695 debugging information.
- Copyright 1996, 1998, 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 1996, 1998, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
Written by Ian Lance Taylor <ian@cygnus.com>.
This file is part of GNU Binutils.
@@ -42,8 +42,8 @@ struct ieee_block
const char *filename;
/* The index of the function type, for a BB4 or BB6 block. */
unsigned int fnindx;
- /* True if this function is being skipped. */
- boolean skip;
+ /* TRUE if this function is being skipped. */
+ bfd_boolean skip;
};
/* This structure is the block stack. */
@@ -146,7 +146,7 @@ struct ieee_tag
struct ieee_info
{
/* The debugging handle. */
- PTR dhandle;
+ void *dhandle;
/* The BFD. */
bfd *abfd;
/* The start of the bytes to be parsed. */
@@ -156,7 +156,7 @@ struct ieee_info
/* The block stack. */
struct ieee_blockstack blockstack;
/* Whether we have seen a BB1 or BB2. */
- boolean saw_filename;
+ bfd_boolean saw_filename;
/* The variables. */
struct ieee_vars vars;
/* The global variables, after a global typedef block. */
@@ -249,56 +249,50 @@ enum builtin_types
/* Local functions. */
-static void ieee_error
- PARAMS ((struct ieee_info *, const bfd_byte *, const char *));
-static void ieee_eof PARAMS ((struct ieee_info *));
-static char *savestring PARAMS ((const char *, unsigned long));
-static boolean ieee_read_number
- PARAMS ((struct ieee_info *, const bfd_byte **, bfd_vma *));
-static boolean ieee_read_optional_number
- PARAMS ((struct ieee_info *, const bfd_byte **, bfd_vma *, boolean *));
-static boolean ieee_read_id
- PARAMS ((struct ieee_info *, const bfd_byte **, const char **,
- unsigned long *));
-static boolean ieee_read_optional_id
- PARAMS ((struct ieee_info *, const bfd_byte **, const char **,
- unsigned long *, boolean *));
-static boolean ieee_read_expression
- PARAMS ((struct ieee_info *, const bfd_byte **, bfd_vma *));
+static void ieee_error (struct ieee_info *, const bfd_byte *, const char *);
+static void ieee_eof (struct ieee_info *);
+static char *savestring (const char *, unsigned long);
+static bfd_boolean ieee_read_number
+ (struct ieee_info *, const bfd_byte **, bfd_vma *);
+static bfd_boolean ieee_read_optional_number
+ (struct ieee_info *, const bfd_byte **, bfd_vma *, bfd_boolean *);
+static bfd_boolean ieee_read_id
+ (struct ieee_info *, const bfd_byte **, const char **, unsigned long *);
+static bfd_boolean ieee_read_optional_id
+ (struct ieee_info *, const bfd_byte **, const char **, unsigned long *,
+ bfd_boolean *);
+static bfd_boolean ieee_read_expression
+ (struct ieee_info *, const bfd_byte **, bfd_vma *);
static debug_type ieee_builtin_type
- PARAMS ((struct ieee_info *, const bfd_byte *, unsigned int));
-static boolean ieee_alloc_type
- PARAMS ((struct ieee_info *, unsigned int, boolean));
-static boolean ieee_read_type_index
- PARAMS ((struct ieee_info *, const bfd_byte **, debug_type *));
-static int ieee_regno_to_genreg PARAMS ((bfd *, int));
-static int ieee_genreg_to_regno PARAMS ((bfd *, int));
-static boolean parse_ieee_bb PARAMS ((struct ieee_info *, const bfd_byte **));
-static boolean parse_ieee_be PARAMS ((struct ieee_info *, const bfd_byte **));
-static boolean parse_ieee_nn PARAMS ((struct ieee_info *, const bfd_byte **));
-static boolean parse_ieee_ty PARAMS ((struct ieee_info *, const bfd_byte **));
-static boolean parse_ieee_atn PARAMS ((struct ieee_info *, const bfd_byte **));
-static boolean ieee_read_cxx_misc
- PARAMS ((struct ieee_info *, const bfd_byte **, unsigned long));
-static boolean ieee_read_cxx_class
- PARAMS ((struct ieee_info *, const bfd_byte **, unsigned long));
-static boolean ieee_read_cxx_defaults
- PARAMS ((struct ieee_info *, const bfd_byte **, unsigned long));
-static boolean ieee_read_reference
- PARAMS ((struct ieee_info *, const bfd_byte **));
-static boolean ieee_require_asn
- PARAMS ((struct ieee_info *, const bfd_byte **, bfd_vma *));
-static boolean ieee_require_atn65
- PARAMS ((struct ieee_info *, const bfd_byte **, const char **,
- unsigned long *));
+ (struct ieee_info *, const bfd_byte *, unsigned int);
+static bfd_boolean ieee_alloc_type
+ (struct ieee_info *, unsigned int, bfd_boolean);
+static bfd_boolean ieee_read_type_index
+ (struct ieee_info *, const bfd_byte **, debug_type *);
+static int ieee_regno_to_genreg (bfd *, int);
+static int ieee_genreg_to_regno (bfd *, int);
+static bfd_boolean parse_ieee_bb (struct ieee_info *, const bfd_byte **);
+static bfd_boolean parse_ieee_be (struct ieee_info *, const bfd_byte **);
+static bfd_boolean parse_ieee_nn (struct ieee_info *, const bfd_byte **);
+static bfd_boolean parse_ieee_ty (struct ieee_info *, const bfd_byte **);
+static bfd_boolean parse_ieee_atn (struct ieee_info *, const bfd_byte **);
+static bfd_boolean ieee_read_cxx_misc
+ (struct ieee_info *, const bfd_byte **, unsigned long);
+static bfd_boolean ieee_read_cxx_class
+ (struct ieee_info *, const bfd_byte **, unsigned long);
+static bfd_boolean ieee_read_cxx_defaults
+ (struct ieee_info *, const bfd_byte **, unsigned long);
+static bfd_boolean ieee_read_reference
+ (struct ieee_info *, const bfd_byte **);
+static bfd_boolean ieee_require_asn
+ (struct ieee_info *, const bfd_byte **, bfd_vma *);
+static bfd_boolean ieee_require_atn65
+ (struct ieee_info *, const bfd_byte **, const char **, unsigned long *);
/* Report an error in the IEEE debugging information. */
static void
-ieee_error (info, p, s)
- struct ieee_info *info;
- const bfd_byte *p;
- const char *s;
+ieee_error (struct ieee_info *info, const bfd_byte *p, const char *s)
{
if (p != NULL)
fprintf (stderr, "%s: 0x%lx: %s (0x%x)\n", bfd_get_filename (info->abfd),
@@ -310,8 +304,7 @@ ieee_error (info, p, s)
/* Report an unexpected EOF in the IEEE debugging information. */
static void
-ieee_eof (info)
- struct ieee_info *info;
+ieee_eof (struct ieee_info *info)
{
ieee_error (info, (const bfd_byte *) NULL,
_("unexpected end of debugging information"));
@@ -320,9 +313,7 @@ ieee_eof (info)
/* Save a string in memory. */
static char *
-savestring (start, len)
- const char *start;
- unsigned long len;
+savestring (const char *start, unsigned long len)
{
char *ret;
@@ -334,24 +325,18 @@ savestring (start, len)
/* Read a number which must be present in an IEEE file. */
-static boolean
-ieee_read_number (info, pp, pv)
- struct ieee_info *info;
- const bfd_byte **pp;
- bfd_vma *pv;
+static bfd_boolean
+ieee_read_number (struct ieee_info *info, const bfd_byte **pp, bfd_vma *pv)
{
- return ieee_read_optional_number (info, pp, pv, (boolean *) NULL);
+ return ieee_read_optional_number (info, pp, pv, (bfd_boolean *) NULL);
}
/* Read a number in an IEEE file. If ppresent is not NULL, the number
need not be there. */
-static boolean
-ieee_read_optional_number (info, pp, pv, ppresent)
- struct ieee_info *info;
- const bfd_byte **pp;
- bfd_vma *pv;
- boolean *ppresent;
+static bfd_boolean
+ieee_read_optional_number (struct ieee_info *info, const bfd_byte **pp,
+ bfd_vma *pv, bfd_boolean *ppresent)
{
ieee_record_enum_type b;
@@ -359,11 +344,11 @@ ieee_read_optional_number (info, pp, pv, ppresent)
{
if (ppresent != NULL)
{
- *ppresent = false;
- return true;
+ *ppresent = FALSE;
+ return TRUE;
}
ieee_eof (info);
- return false;
+ return FALSE;
}
b = (ieee_record_enum_type) **pp;
@@ -373,8 +358,8 @@ ieee_read_optional_number (info, pp, pv, ppresent)
{
*pv = (bfd_vma) b;
if (ppresent != NULL)
- *ppresent = true;
- return true;
+ *ppresent = TRUE;
+ return TRUE;
}
if (b >= ieee_number_repeat_start_enum && b <= ieee_number_repeat_end_enum)
@@ -385,7 +370,7 @@ ieee_read_optional_number (info, pp, pv, ppresent)
if (*pp + i - 1 >= info->pend)
{
ieee_eof (info);
- return false;
+ return FALSE;
}
*pv = 0;
@@ -397,44 +382,38 @@ ieee_read_optional_number (info, pp, pv, ppresent)
}
if (ppresent != NULL)
- *ppresent = true;
+ *ppresent = TRUE;
- return true;
+ return TRUE;
}
if (ppresent != NULL)
{
--*pp;
- *ppresent = false;
- return true;
+ *ppresent = FALSE;
+ return TRUE;
}
ieee_error (info, *pp - 1, _("invalid number"));
- return false;
+ return FALSE;
}
/* Read a required string from an IEEE file. */
-static boolean
-ieee_read_id (info, pp, pname, pnamlen)
- struct ieee_info *info;
- const bfd_byte **pp;
- const char **pname;
- unsigned long *pnamlen;
+static bfd_boolean
+ieee_read_id (struct ieee_info *info, const bfd_byte **pp,
+ const char **pname, unsigned long *pnamlen)
{
- return ieee_read_optional_id (info, pp, pname, pnamlen, (boolean *) NULL);
+ return ieee_read_optional_id (info, pp, pname, pnamlen, (bfd_boolean *) NULL);
}
/* Read a string from an IEEE file. If ppresent is not NULL, the
string is optional. */
-static boolean
-ieee_read_optional_id (info, pp, pname, pnamlen, ppresent)
- struct ieee_info *info;
- const bfd_byte **pp;
- const char **pname;
- unsigned long *pnamlen;
- boolean *ppresent;
+static bfd_boolean
+ieee_read_optional_id (struct ieee_info *info, const bfd_byte **pp,
+ const char **pname, unsigned long *pnamlen,
+ bfd_boolean *ppresent)
{
bfd_byte b;
unsigned long len;
@@ -442,7 +421,7 @@ ieee_read_optional_id (info, pp, pname, pnamlen, ppresent)
if (*pp >= info->pend)
{
ieee_eof (info);
- return false;
+ return FALSE;
}
b = **pp;
@@ -465,17 +444,17 @@ ieee_read_optional_id (info, pp, pname, pnamlen, ppresent)
if (ppresent != NULL)
{
--*pp;
- *ppresent = false;
- return true;
+ *ppresent = FALSE;
+ return TRUE;
}
ieee_error (info, *pp - 1, _("invalid string length"));
- return false;
+ return FALSE;
}
if ((unsigned long) (info->pend - *pp) < len)
{
ieee_eof (info);
- return false;
+ return FALSE;
}
*pname = (const char *) *pp;
@@ -483,9 +462,9 @@ ieee_read_optional_id (info, pp, pname, pnamlen, ppresent)
*pp += len;
if (ppresent != NULL)
- *ppresent = true;
+ *ppresent = TRUE;
- return true;
+ return TRUE;
}
/* Read an expression from an IEEE file. Since this code is only used
@@ -494,11 +473,9 @@ ieee_read_optional_id (info, pp, pname, pnamlen, ppresent)
seen in debugging information. This can be easily extended if
necessary. */
-static boolean
-ieee_read_expression (info, pp, pv)
- struct ieee_info *info;
- const bfd_byte **pp;
- bfd_vma *pv;
+static bfd_boolean
+ieee_read_expression (struct ieee_info *info, const bfd_byte **pp,
+ bfd_vma *pv)
{
const bfd_byte *expr_start;
#define EXPR_STACK_SIZE (10)
@@ -513,20 +490,20 @@ ieee_read_expression (info, pp, pv)
{
const bfd_byte *start;
bfd_vma val;
- boolean present;
+ bfd_boolean present;
ieee_record_enum_type c;
start = *pp;
if (! ieee_read_optional_number (info, pp, &val, &present))
- return false;
+ return FALSE;
if (present)
{
if (esp - expr_stack >= EXPR_STACK_SIZE)
{
ieee_error (info, start, _("expression stack overflow"));
- return false;
+ return FALSE;
}
*esp++ = val;
continue;
@@ -554,20 +531,20 @@ ieee_read_expression (info, pp, pv)
asection *s;
if (! ieee_read_number (info, pp, &indx))
- return false;
+ return FALSE;
for (s = info->abfd->sections; s != NULL; s = s->next)
if ((bfd_vma) s->target_index == indx)
break;
if (s == NULL)
{
ieee_error (info, start, _("unknown section"));
- return false;
+ return FALSE;
}
if (esp - expr_stack >= EXPR_STACK_SIZE)
{
ieee_error (info, start, _("expression stack overflow"));
- return false;
+ return FALSE;
}
*esp++ = bfd_get_section_vma (info->abfd, s);
@@ -582,7 +559,7 @@ ieee_read_expression (info, pp, pv)
if (esp - expr_stack < 2)
{
ieee_error (info, start, _("expression stack underflow"));
- return false;
+ return FALSE;
}
v1 = *--esp;
@@ -596,23 +573,21 @@ ieee_read_expression (info, pp, pv)
if (esp - 1 != expr_stack)
{
ieee_error (info, expr_start, _("expression stack mismatch"));
- return false;
+ return FALSE;
}
*pv = *--esp;
- return true;
+ return TRUE;
}
/* Return an IEEE builtin type. */
static debug_type
-ieee_builtin_type (info, p, indx)
- struct ieee_info *info;
- const bfd_byte *p;
- unsigned int indx;
+ieee_builtin_type (struct ieee_info *info, const bfd_byte *p,
+ unsigned int indx)
{
- PTR dhandle;
+ void *dhandle;
debug_type type;
const char *name;
@@ -648,42 +623,42 @@ ieee_builtin_type (info, p, indx)
break;
case builtin_signed_char:
- type = debug_make_int_type (dhandle, 1, false);
+ type = debug_make_int_type (dhandle, 1, FALSE);
name = "signed char";
break;
case builtin_unsigned_char:
- type = debug_make_int_type (dhandle, 1, true);
+ type = debug_make_int_type (dhandle, 1, TRUE);
name = "unsigned char";
break;
case builtin_signed_short_int:
- type = debug_make_int_type (dhandle, 2, false);
+ type = debug_make_int_type (dhandle, 2, FALSE);
name = "signed short int";
break;
case builtin_unsigned_short_int:
- type = debug_make_int_type (dhandle, 2, true);
+ type = debug_make_int_type (dhandle, 2, TRUE);
name = "unsigned short int";
break;
case builtin_signed_long:
- type = debug_make_int_type (dhandle, 4, false);
+ type = debug_make_int_type (dhandle, 4, FALSE);
name = "signed long";
break;
case builtin_unsigned_long:
- type = debug_make_int_type (dhandle, 4, true);
+ type = debug_make_int_type (dhandle, 4, TRUE);
name = "unsigned long";
break;
case builtin_signed_long_long:
- type = debug_make_int_type (dhandle, 8, false);
+ type = debug_make_int_type (dhandle, 8, FALSE);
name = "signed long long";
break;
case builtin_unsigned_long_long:
- type = debug_make_int_type (dhandle, 8, true);
+ type = debug_make_int_type (dhandle, 8, TRUE);
name = "unsigned long long";
break;
@@ -717,64 +692,64 @@ ieee_builtin_type (info, p, indx)
ieee_builtin_type (info, p,
((unsigned int)
builtin_int)),
- 0, -1, true);
+ 0, -1, TRUE);
name = "QUOTED STRING";
break;
case builtin_instruction_address:
/* FIXME: This should be a code address. */
- type = debug_make_int_type (dhandle, 4, true);
+ type = debug_make_int_type (dhandle, 4, TRUE);
name = "instruction address";
break;
case builtin_int:
/* FIXME: The size for this type should depend upon the
processor. */
- type = debug_make_int_type (dhandle, 4, false);
+ type = debug_make_int_type (dhandle, 4, FALSE);
name = "int";
break;
case builtin_unsigned:
/* FIXME: The size for this type should depend upon the
processor. */
- type = debug_make_int_type (dhandle, 4, true);
+ type = debug_make_int_type (dhandle, 4, TRUE);
name = "unsigned";
break;
case builtin_unsigned_int:
/* FIXME: The size for this type should depend upon the
processor. */
- type = debug_make_int_type (dhandle, 4, true);
+ type = debug_make_int_type (dhandle, 4, TRUE);
name = "unsigned int";
break;
case builtin_char:
- type = debug_make_int_type (dhandle, 1, false);
+ type = debug_make_int_type (dhandle, 1, FALSE);
name = "char";
break;
case builtin_long:
- type = debug_make_int_type (dhandle, 4, false);
+ type = debug_make_int_type (dhandle, 4, FALSE);
name = "long";
break;
case builtin_short:
- type = debug_make_int_type (dhandle, 2, false);
+ type = debug_make_int_type (dhandle, 2, FALSE);
name = "short";
break;
case builtin_unsigned_short:
- type = debug_make_int_type (dhandle, 2, true);
+ type = debug_make_int_type (dhandle, 2, TRUE);
name = "unsigned short";
break;
case builtin_short_int:
- type = debug_make_int_type (dhandle, 2, false);
+ type = debug_make_int_type (dhandle, 2, FALSE);
name = "short int";
break;
case builtin_signed_short:
- type = debug_make_int_type (dhandle, 2, false);
+ type = debug_make_int_type (dhandle, 2, FALSE);
name = "signed short";
break;
@@ -793,15 +768,12 @@ ieee_builtin_type (info, p, indx)
return type;
}
-/* Allocate more space in the type table. If ref is true, this is a
+/* Allocate more space in the type table. If ref is TRUE, this is a
reference to the type; if it is not already defined, we should set
up an indirect type. */
-static boolean
-ieee_alloc_type (info, indx, ref)
- struct ieee_info *info;
- unsigned int indx;
- boolean ref;
+static bfd_boolean
+ieee_alloc_type (struct ieee_info *info, unsigned int indx, bfd_boolean ref)
{
unsigned int nalloc;
register struct ieee_type *t;
@@ -839,20 +811,18 @@ ieee_alloc_type (info, indx, ref)
t->type = debug_make_indirect_type (info->dhandle, t->pslot,
(const char *) NULL);
if (t->type == NULL)
- return false;
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
/* Read a type index and return the corresponding type. */
-static boolean
-ieee_read_type_index (info, pp, ptype)
- struct ieee_info *info;
- const bfd_byte **pp;
- debug_type *ptype;
+static bfd_boolean
+ieee_read_type_index (struct ieee_info *info, const bfd_byte **pp,
+ debug_type *ptype)
{
const bfd_byte *start;
bfd_vma indx;
@@ -860,34 +830,30 @@ ieee_read_type_index (info, pp, ptype)
start = *pp;
if (! ieee_read_number (info, pp, &indx))
- return false;
+ return FALSE;
if (indx < 256)
{
*ptype = ieee_builtin_type (info, start, indx);
if (*ptype == NULL)
- return false;
- return true;
+ return FALSE;
+ return TRUE;
}
indx -= 256;
- if (! ieee_alloc_type (info, indx, true))
- return false;
+ if (! ieee_alloc_type (info, indx, TRUE))
+ return FALSE;
*ptype = info->types.types[indx].type;
- return true;
+ return TRUE;
}
/* Parse IEEE debugging information for a file. This is passed the
bytes which compose the Debug Information Part of an IEEE file. */
-boolean
-parse_ieee (dhandle, abfd, bytes, len)
- PTR dhandle;
- bfd *abfd;
- const bfd_byte *bytes;
- bfd_size_type len;
+bfd_boolean
+parse_ieee (void *dhandle, bfd *abfd, const bfd_byte *bytes, bfd_size_type len)
{
struct ieee_info info;
unsigned int i;
@@ -898,7 +864,7 @@ parse_ieee (dhandle, abfd, bytes, len)
info.bytes = bytes;
info.pend = bytes + len;
info.blockstack.bsp = info.blockstack.stack;
- info.saw_filename = false;
+ info.saw_filename = FALSE;
info.vars.alloc = 0;
info.vars.vars = NULL;
info.global_vars = NULL;
@@ -926,38 +892,38 @@ parse_ieee (dhandle, abfd, bytes, len)
if (c <= ieee_number_repeat_end_enum)
{
ieee_error (&info, record_start, _("unexpected number"));
- return false;
+ return FALSE;
}
switch (c)
{
default:
ieee_error (&info, record_start, _("unexpected record type"));
- return false;
+ return FALSE;
case ieee_bb_record_enum:
if (! parse_ieee_bb (&info, &p))
- return false;
+ return FALSE;
break;
case ieee_be_record_enum:
if (! parse_ieee_be (&info, &p))
- return false;
+ return FALSE;
break;
case ieee_nn_record:
if (! parse_ieee_nn (&info, &p))
- return false;
+ return FALSE;
break;
case ieee_ty_record_enum:
if (! parse_ieee_ty (&info, &p))
- return false;
+ return FALSE;
break;
case ieee_atn_record_enum:
if (! parse_ieee_atn (&info, &p))
- return false;
+ return FALSE;
break;
}
}
@@ -966,18 +932,16 @@ parse_ieee (dhandle, abfd, bytes, len)
{
ieee_error (&info, (const bfd_byte *) NULL,
_("blocks left on stack at end"));
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Handle an IEEE BB record. */
-static boolean
-parse_ieee_bb (info, pp)
- struct ieee_info *info;
- const bfd_byte **pp;
+static bfd_boolean
+parse_ieee_bb (struct ieee_info *info, const bfd_byte **pp)
{
const bfd_byte *block_start;
bfd_byte b;
@@ -986,7 +950,7 @@ parse_ieee_bb (info, pp)
unsigned long namlen;
char *namcopy = NULL;
unsigned int fnindx;
- boolean skip;
+ bfd_boolean skip;
block_start = *pp;
@@ -995,10 +959,10 @@ parse_ieee_bb (info, pp)
if (! ieee_read_number (info, pp, &size)
|| ! ieee_read_id (info, pp, &name, &namlen))
- return false;
+ return FALSE;
fnindx = (unsigned int) -1;
- skip = false;
+ skip = FALSE;
switch (b)
{
@@ -1006,10 +970,10 @@ parse_ieee_bb (info, pp)
/* BB1: Type definitions local to a module. */
namcopy = savestring (name, namlen);
if (namcopy == NULL)
- return false;
+ return FALSE;
if (! debug_set_filename (info->dhandle, namcopy))
- return false;
- info->saw_filename = true;
+ return FALSE;
+ info->saw_filename = TRUE;
/* Discard any variables or types we may have seen before. */
if (info->vars.vars != NULL)
@@ -1038,8 +1002,8 @@ parse_ieee_bb (info, pp)
/* BB2: Global type definitions. The name is supposed to be
empty, but we don't check. */
if (! debug_set_filename (info->dhandle, "*global*"))
- return false;
- info->saw_filename = true;
+ return FALSE;
+ info->saw_filename = TRUE;
break;
case 3:
@@ -1057,7 +1021,7 @@ parse_ieee_bb (info, pp)
if (! ieee_read_number (info, pp, &stackspace)
|| ! ieee_read_number (info, pp, &typindx)
|| ! ieee_read_expression (info, pp, &offset))
- return false;
+ return FALSE;
/* We have no way to record the stack space. FIXME. */
@@ -1065,13 +1029,13 @@ parse_ieee_bb (info, pp)
{
return_type = ieee_builtin_type (info, block_start, typindx);
if (return_type == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
}
else
{
typindx -= 256;
- if (! ieee_alloc_type (info, typindx, true))
- return false;
+ if (! ieee_alloc_type (info, typindx, TRUE))
+ return FALSE;
fnindx = typindx;
return_type = info->types.types[typindx].type;
if (debug_get_type_kind (info->dhandle, return_type)
@@ -1082,10 +1046,10 @@ parse_ieee_bb (info, pp)
namcopy = savestring (name, namlen);
if (namcopy == NULL)
- return false;
+ return FALSE;
if (! debug_record_function (info->dhandle, namcopy, return_type,
- true, offset))
- return false;
+ TRUE, offset))
+ return FALSE;
}
break;
@@ -1098,19 +1062,19 @@ parse_ieee_bb (info, pp)
for (i = 0; i < 6; i++)
{
bfd_vma ignore;
- boolean present;
+ bfd_boolean present;
if (! ieee_read_optional_number (info, pp, &ignore, &present))
- return false;
+ return FALSE;
if (! present)
break;
}
namcopy = savestring (name, namlen);
if (namcopy == NULL)
- return false;
+ return FALSE;
if (! debug_start_source (info->dhandle, namcopy))
- return false;
+ return FALSE;
}
break;
@@ -1122,14 +1086,14 @@ parse_ieee_bb (info, pp)
if (! ieee_read_number (info, pp, &stackspace)
|| ! ieee_read_number (info, pp, &typindx)
|| ! ieee_read_expression (info, pp, &offset))
- return false;
+ return FALSE;
/* We have no way to record the stack space. FIXME. */
if (namlen == 0)
{
if (! debug_start_block (info->dhandle, offset))
- return false;
+ return FALSE;
/* Change b to indicate that this is a block
rather than a function. */
b = 0x86;
@@ -1142,7 +1106,7 @@ parse_ieee_bb (info, pp)
converting from IEEE to other debug formats work
better. */
if (strncmp (name, "__XRYCPP", namlen) == 0)
- skip = true;
+ skip = TRUE;
else
{
debug_type return_type;
@@ -1152,13 +1116,13 @@ parse_ieee_bb (info, pp)
return_type = ieee_builtin_type (info, block_start,
typindx);
if (return_type == NULL)
- return false;
+ return FALSE;
}
else
{
typindx -= 256;
- if (! ieee_alloc_type (info, typindx, true))
- return false;
+ if (! ieee_alloc_type (info, typindx, TRUE))
+ return FALSE;
fnindx = typindx;
return_type = info->types.types[typindx].type;
if (debug_get_type_kind (info->dhandle, return_type)
@@ -1169,10 +1133,10 @@ parse_ieee_bb (info, pp)
namcopy = savestring (name, namlen);
if (namcopy == NULL)
- return false;
+ return FALSE;
if (! debug_record_function (info->dhandle, namcopy,
- return_type, false, offset))
- return false;
+ return_type, FALSE, offset))
+ return FALSE;
}
}
}
@@ -1185,29 +1149,29 @@ parse_ieee_bb (info, pp)
const char *inam, *vstr;
unsigned long inamlen, vstrlen;
bfd_vma tool_type;
- boolean present;
+ bfd_boolean present;
unsigned int i;
if (! info->saw_filename)
{
namcopy = savestring (name, namlen);
if (namcopy == NULL)
- return false;
+ return FALSE;
if (! debug_set_filename (info->dhandle, namcopy))
- return false;
- info->saw_filename = true;
+ return FALSE;
+ info->saw_filename = TRUE;
}
if (! ieee_read_id (info, pp, &inam, &inamlen)
|| ! ieee_read_number (info, pp, &tool_type)
|| ! ieee_read_optional_id (info, pp, &vstr, &vstrlen, &present))
- return false;
+ return FALSE;
for (i = 0; i < 6; i++)
{
bfd_vma ignore;
if (! ieee_read_optional_number (info, pp, &ignore, &present))
- return false;
+ return FALSE;
if (! present)
break;
}
@@ -1219,19 +1183,19 @@ parse_ieee_bb (info, pp)
information. FIXME. */
{
bfd_vma sectype, secindx, offset, map;
- boolean present;
+ bfd_boolean present;
if (! ieee_read_number (info, pp, &sectype)
|| ! ieee_read_number (info, pp, &secindx)
|| ! ieee_read_expression (info, pp, &offset)
|| ! ieee_read_optional_number (info, pp, &map, &present))
- return false;
+ return FALSE;
}
break;
default:
ieee_error (info, block_start, _("unknown BB type"));
- return false;
+ return FALSE;
}
@@ -1240,7 +1204,7 @@ parse_ieee_bb (info, pp)
if (info->blockstack.bsp >= info->blockstack.stack + BLOCKSTACK_SIZE)
{
ieee_error (info, (const bfd_byte *) NULL, _("stack overflow"));
- return false;
+ return FALSE;
}
info->blockstack.bsp->kind = b;
@@ -1250,29 +1214,27 @@ parse_ieee_bb (info, pp)
info->blockstack.bsp->skip = skip;
++info->blockstack.bsp;
- return true;
+ return TRUE;
}
/* Handle an IEEE BE record. */
-static boolean
-parse_ieee_be (info, pp)
- struct ieee_info *info;
- const bfd_byte **pp;
+static bfd_boolean
+parse_ieee_be (struct ieee_info *info, const bfd_byte **pp)
{
bfd_vma offset;
if (info->blockstack.bsp <= info->blockstack.stack)
{
ieee_error (info, *pp, _("stack underflow"));
- return false;
+ return FALSE;
}
--info->blockstack.bsp;
switch (info->blockstack.bsp->kind)
{
case 2:
- /* When we end the global typedefs block, we copy out the the
+ /* When we end the global typedefs block, we copy out the
contents of info->vars. This is because the variable indices
may be reused in the local blocks. However, we need to
preserve them so that we can locate a function returning a
@@ -1305,11 +1267,11 @@ parse_ieee_be (info, pp)
case 4:
case 6:
if (! ieee_read_expression (info, pp, &offset))
- return false;
+ return FALSE;
if (! info->blockstack.bsp->skip)
{
if (! debug_end_function (info->dhandle, offset + 1))
- return false;
+ return FALSE;
}
break;
@@ -1317,9 +1279,9 @@ parse_ieee_be (info, pp)
/* This is BE6 when BB6 started a block rather than a local
function. */
if (! ieee_read_expression (info, pp, &offset))
- return false;
+ return FALSE;
if (! debug_end_block (info->dhandle, offset + 1))
- return false;
+ return FALSE;
break;
case 5:
@@ -1336,7 +1298,7 @@ parse_ieee_be (info, pp)
if (bl->kind == 5)
{
if (! debug_start_source (info->dhandle, bl->filename))
- return false;
+ return FALSE;
break;
}
}
@@ -1346,7 +1308,7 @@ parse_ieee_be (info, pp)
case 11:
if (! ieee_read_expression (info, pp, &offset))
- return false;
+ return FALSE;
/* We just ignore the module size. FIXME. */
break;
@@ -1355,15 +1317,13 @@ parse_ieee_be (info, pp)
break;
}
- return true;
+ return TRUE;
}
/* Parse an NN record. */
-static boolean
-parse_ieee_nn (info, pp)
- struct ieee_info *info;
- const bfd_byte **pp;
+static bfd_boolean
+parse_ieee_nn (struct ieee_info *info, const bfd_byte **pp)
{
const bfd_byte *nn_start;
bfd_vma varindx;
@@ -1374,12 +1334,12 @@ parse_ieee_nn (info, pp)
if (! ieee_read_number (info, pp, &varindx)
|| ! ieee_read_id (info, pp, &name, &namlen))
- return false;
+ return FALSE;
if (varindx < 32)
{
ieee_error (info, nn_start, _("illegal variable index"));
- return false;
+ return FALSE;
}
varindx -= 32;
@@ -1403,20 +1363,18 @@ parse_ieee_nn (info, pp)
info->vars.vars[varindx].name = name;
info->vars.vars[varindx].namlen = namlen;
- return true;
+ return TRUE;
}
/* Parse a TY record. */
-static boolean
-parse_ieee_ty (info, pp)
- struct ieee_info *info;
- const bfd_byte **pp;
+static bfd_boolean
+parse_ieee_ty (struct ieee_info *info, const bfd_byte **pp)
{
const bfd_byte *ty_start, *ty_var_start, *ty_code_start;
bfd_vma typeindx, varindx, tc;
- PTR dhandle;
- boolean tag, typdef;
+ void *dhandle;
+ bfd_boolean tag, typdef;
debug_type *arg_slots;
unsigned long type_bitsize;
debug_type type;
@@ -1424,59 +1382,59 @@ parse_ieee_ty (info, pp)
ty_start = *pp;
if (! ieee_read_number (info, pp, &typeindx))
- return false;
+ return FALSE;
if (typeindx < 256)
{
ieee_error (info, ty_start, _("illegal type index"));
- return false;
+ return FALSE;
}
typeindx -= 256;
- if (! ieee_alloc_type (info, typeindx, false))
- return false;
+ if (! ieee_alloc_type (info, typeindx, FALSE))
+ return FALSE;
if (**pp != 0xce)
{
ieee_error (info, *pp, _("unknown TY code"));
- return false;
+ return FALSE;
}
++*pp;
ty_var_start = *pp;
if (! ieee_read_number (info, pp, &varindx))
- return false;
+ return FALSE;
if (varindx < 32)
{
ieee_error (info, ty_var_start, _("illegal variable index"));
- return false;
+ return FALSE;
}
varindx -= 32;
if (varindx >= info->vars.alloc || info->vars.vars[varindx].name == NULL)
{
ieee_error (info, ty_var_start, _("undefined variable in TY"));
- return false;
+ return FALSE;
}
ty_code_start = *pp;
if (! ieee_read_number (info, pp, &tc))
- return false;
+ return FALSE;
dhandle = info->dhandle;
- tag = false;
- typdef = false;
+ tag = FALSE;
+ typdef = FALSE;
arg_slots = NULL;
type_bitsize = 0;
switch (tc)
{
default:
ieee_error (info, ty_code_start, _("unknown TY code"));
- return false;
+ return FALSE;
case '!':
/* Unknown type, with size. We treat it as int. FIXME. */
@@ -1484,8 +1442,8 @@ parse_ieee_ty (info, pp)
bfd_vma size;
if (! ieee_read_number (info, pp, &size))
- return false;
- type = debug_make_int_type (dhandle, size, false);
+ return FALSE;
+ type = debug_make_int_type (dhandle, size, FALSE);
}
break;
@@ -1499,14 +1457,14 @@ parse_ieee_ty (info, pp)
if (! ieee_read_type_index (info, pp, &ele_type)
|| ! ieee_read_number (info, pp, &lower)
|| ! ieee_read_number (info, pp, &upper))
- return false;
+ return FALSE;
type = debug_make_array_type (dhandle, ele_type,
ieee_builtin_type (info, ty_code_start,
((unsigned int)
builtin_int)),
(bfd_signed_vma) lower,
(bfd_signed_vma) upper,
- false);
+ FALSE);
}
break;
@@ -1521,7 +1479,7 @@ parse_ieee_ty (info, pp)
unsigned int i;
if (! ieee_read_number (info, pp, &size))
- return false;
+ return FALSE;
/* FIXME: we ignore the enumeration size. */
alloc = 10;
@@ -1532,10 +1490,10 @@ parse_ieee_ty (info, pp)
{
const char *name;
unsigned long namlen;
- boolean present;
+ bfd_boolean present;
if (! ieee_read_optional_id (info, pp, &name, &namlen, &present))
- return false;
+ return FALSE;
if (! present)
break;
@@ -1548,7 +1506,7 @@ parse_ieee_ty (info, pp)
names[c] = savestring (name, namlen);
if (names[c] == NULL)
- return false;
+ return FALSE;
++c;
}
@@ -1559,7 +1517,7 @@ parse_ieee_ty (info, pp)
vals[i] = i;
type = debug_make_enum_type (dhandle, names, vals);
- tag = true;
+ tag = TRUE;
}
break;
@@ -1572,7 +1530,7 @@ parse_ieee_ty (info, pp)
unsigned int c;
if (! ieee_read_number (info, pp, &size))
- return false;
+ return FALSE;
alloc = 10;
fields = (debug_field *) xmalloc (alloc * sizeof *fields);
@@ -1581,18 +1539,18 @@ parse_ieee_ty (info, pp)
{
const char *name;
unsigned long namlen;
- boolean present;
+ bfd_boolean present;
debug_type ftype;
bfd_vma bitpos, bitsize;
if (! ieee_read_optional_id (info, pp, &name, &namlen, &present))
- return false;
+ return FALSE;
if (! present)
break;
if (! ieee_read_type_index (info, pp, &ftype)
|| ! ieee_read_number (info, pp, &bitpos)
|| ! ieee_read_number (info, pp, &bitsize))
- return false;
+ return FALSE;
if (c + 1 >= alloc)
{
@@ -1605,14 +1563,14 @@ parse_ieee_ty (info, pp)
ftype, bitpos, bitsize,
DEBUG_VISIBILITY_PUBLIC);
if (fields[c] == NULL)
- return false;
+ return FALSE;
++c;
}
fields[c] = NULL;
- type = debug_make_struct_type (dhandle, true, size, fields);
- tag = true;
+ type = debug_make_struct_type (dhandle, TRUE, size, fields);
+ tag = TRUE;
}
break;
@@ -1632,15 +1590,15 @@ parse_ieee_ty (info, pp)
{
const char *name;
unsigned long namlen;
- boolean present;
+ bfd_boolean present;
bfd_vma val;
if (! ieee_read_optional_id (info, pp, &name, &namlen, &present))
- return false;
+ return FALSE;
if (! present)
break;
if (! ieee_read_number (info, pp, &val))
- return false;
+ return FALSE;
/* If the length of the name is zero, then the value is
actually the size of the enum. We ignore this
@@ -1659,7 +1617,7 @@ parse_ieee_ty (info, pp)
names[c] = savestring (name, namlen);
if (names[c] == NULL)
- return false;
+ return FALSE;
vals[c] = (bfd_signed_vma) val;
++c;
}
@@ -1667,7 +1625,7 @@ parse_ieee_ty (info, pp)
names[c] = NULL;
type = debug_make_enum_type (dhandle, names, vals);
- tag = true;
+ tag = TRUE;
}
break;
@@ -1678,7 +1636,7 @@ parse_ieee_ty (info, pp)
debug_type t;
if (! ieee_read_type_index (info, pp, &t))
- return false;
+ return FALSE;
type = debug_make_pointer_type (dhandle, t);
}
break;
@@ -1692,7 +1650,7 @@ parse_ieee_ty (info, pp)
|| ! ieee_read_number (info, pp, &high)
|| ! ieee_read_number (info, pp, &signedp)
|| ! ieee_read_number (info, pp, &size))
- return false;
+ return FALSE;
type = debug_make_range_type (dhandle,
debug_make_int_type (dhandle, size,
@@ -1711,7 +1669,7 @@ parse_ieee_ty (info, pp)
unsigned int c;
if (! ieee_read_number (info, pp, &size))
- return false;
+ return FALSE;
alloc = 10;
fields = (debug_field *) xmalloc (alloc * sizeof *fields);
@@ -1720,19 +1678,19 @@ parse_ieee_ty (info, pp)
{
const char *name;
unsigned long namlen;
- boolean present;
+ bfd_boolean present;
bfd_vma tindx;
bfd_vma offset;
debug_type ftype;
bfd_vma bitsize;
if (! ieee_read_optional_id (info, pp, &name, &namlen, &present))
- return false;
+ return FALSE;
if (! present)
break;
if (! ieee_read_number (info, pp, &tindx)
|| ! ieee_read_number (info, pp, &offset))
- return false;
+ return FALSE;
if (tindx < 256)
{
@@ -1745,8 +1703,8 @@ parse_ieee_ty (info, pp)
struct ieee_type *t;
tindx -= 256;
- if (! ieee_alloc_type (info, tindx, true))
- return false;
+ if (! ieee_alloc_type (info, tindx, TRUE))
+ return FALSE;
t = info->types.types + tindx;
ftype = t->type;
bitsize = t->bitsize;
@@ -1765,22 +1723,22 @@ parse_ieee_ty (info, pp)
ftype, offset, bitsize,
DEBUG_VISIBILITY_PUBLIC);
if (fields[c] == NULL)
- return false;
+ return FALSE;
++c;
}
fields[c] = NULL;
type = debug_make_struct_type (dhandle, tc == 'S', size, fields);
- tag = true;
+ tag = TRUE;
}
break;
case 'T':
/* Typedef. */
if (! ieee_read_type_index (info, pp, &type))
- return false;
- typdef = true;
+ return FALSE;
+ typdef = TRUE;
break;
case 'X':
@@ -1790,7 +1748,7 @@ parse_ieee_ty (info, pp)
bfd_vma attr;
debug_type rtype;
bfd_vma nargs;
- boolean present;
+ bfd_boolean present;
struct ieee_var *pv;
/* FIXME: We ignore the attribute and the argument names. */
@@ -1798,14 +1756,14 @@ parse_ieee_ty (info, pp)
if (! ieee_read_number (info, pp, &attr)
|| ! ieee_read_type_index (info, pp, &rtype)
|| ! ieee_read_number (info, pp, &nargs))
- return false;
+ return FALSE;
do
{
const char *name;
unsigned long namlen;
if (! ieee_read_optional_id (info, pp, &name, &namlen, &present))
- return false;
+ return FALSE;
}
while (present);
@@ -1824,7 +1782,7 @@ parse_ieee_ty (info, pp)
}
type = debug_make_function_type (dhandle, rtype, (debug_type *) NULL,
- false);
+ FALSE);
}
break;
@@ -1841,13 +1799,13 @@ parse_ieee_ty (info, pp)
if (! ieee_read_type_index (info, pp, &etype)
|| ! ieee_read_number (info, pp, &high))
- return false;
+ return FALSE;
type = debug_make_array_type (dhandle, etype,
ieee_builtin_type (info, ty_code_start,
((unsigned int)
builtin_int)),
- 0, (bfd_signed_vma) high, false);
+ 0, (bfd_signed_vma) high, FALSE);
}
break;
@@ -1860,7 +1818,7 @@ parse_ieee_ty (info, pp)
/* FIXME: I don't know what the name means. */
if (! ieee_read_id (info, pp, &name, &namlen))
- return false;
+ return FALSE;
type = debug_make_complex_type (dhandle, tc == 'c' ? 4 : 8);
}
@@ -1869,35 +1827,35 @@ parse_ieee_ty (info, pp)
case 'f':
/* Pascal file name. FIXME. */
ieee_error (info, ty_code_start, _("Pascal file name not supported"));
- return false;
+ return FALSE;
case 'g':
/* Bitfield type. */
{
bfd_vma signedp, bitsize, dummy;
const bfd_byte *hold;
- boolean present;
+ bfd_boolean present;
if (! ieee_read_number (info, pp, &signedp)
|| ! ieee_read_number (info, pp, &bitsize))
- return false;
+ return FALSE;
/* I think the documentation says that there is a type index,
but some actual files do not have one. */
hold = *pp;
if (! ieee_read_optional_number (info, pp, &dummy, &present))
- return false;
+ return FALSE;
if (! present)
{
/* FIXME: This is just a guess. */
type = debug_make_int_type (dhandle, 4,
- signedp ? false : true);
+ signedp ? FALSE : TRUE);
}
else
{
*pp = hold;
if (! ieee_read_type_index (info, pp, &type))
- return false;
+ return FALSE;
}
type_bitsize = bitsize;
}
@@ -1911,13 +1869,13 @@ parse_ieee_ty (info, pp)
if (! ieee_read_number (info, pp, &kind)
|| ! ieee_read_type_index (info, pp, &t))
- return false;
+ return FALSE;
switch (kind)
{
default:
ieee_error (info, ty_start, _("unsupported qualifier"));
- return false;
+ return FALSE;
case 1:
type = debug_make_const_type (dhandle, t);
@@ -1938,11 +1896,11 @@ parse_ieee_ty (info, pp)
if (! ieee_read_number (info, pp, &size)
|| ! ieee_read_type_index (info, pp, &etype))
- return false;
+ return FALSE;
/* FIXME: We ignore the size. */
- type = debug_make_set_type (dhandle, etype, false);
+ type = debug_make_set_type (dhandle, etype, FALSE);
}
break;
@@ -1953,8 +1911,8 @@ parse_ieee_ty (info, pp)
bfd_vma attr, frame_type, push_mask, nargs, level, father;
debug_type rtype;
debug_type *arg_types;
- boolean varargs;
- boolean present;
+ bfd_boolean varargs;
+ bfd_boolean present;
/* FIXME: We ignore some of this information. */
@@ -1965,11 +1923,11 @@ parse_ieee_ty (info, pp)
|| ! ieee_read_number (info, pp, &push_mask)
|| ! ieee_read_type_index (info, pp, &rtype)
|| ! ieee_read_number (info, pp, &nargs))
- return false;
+ return FALSE;
if (nargs == (bfd_vma) -1)
{
arg_types = NULL;
- varargs = false;
+ varargs = FALSE;
}
else
{
@@ -1979,11 +1937,11 @@ parse_ieee_ty (info, pp)
xmalloc ((nargs + 1) * sizeof *arg_types));
for (i = 0; i < nargs; i++)
if (! ieee_read_type_index (info, pp, arg_types + i))
- return false;
+ return FALSE;
/* If the last type is pointer to void, this is really a
varargs function. */
- varargs = false;
+ varargs = FALSE;
if (nargs > 0)
{
debug_type last;
@@ -1996,7 +1954,7 @@ parse_ieee_ty (info, pp)
== DEBUG_KIND_VOID))
{
--nargs;
- varargs = true;
+ varargs = TRUE;
}
}
@@ -2026,7 +1984,7 @@ parse_ieee_ty (info, pp)
}
if (! ieee_read_number (info, pp, &level)
|| ! ieee_read_optional_number (info, pp, &father, &present))
- return false;
+ return FALSE;
/* We can't distinguish between a global function and a static
function. */
@@ -2052,7 +2010,7 @@ parse_ieee_ty (info, pp)
/* Record the type in the table. */
if (type == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
info->vars.vars[varindx].type = type;
@@ -2088,7 +2046,7 @@ parse_ieee_ty (info, pp)
it->type = type;
}
if (type == NULL)
- return false;
+ return FALSE;
}
info->types.types[typeindx].type = type;
@@ -2102,39 +2060,37 @@ parse_ieee_ty (info, pp)
if (info->types.types[typeindx].pslot != NULL)
*info->types.types[typeindx].pslot = type;
- return true;
+ return TRUE;
}
/* Parse an ATN record. */
-static boolean
-parse_ieee_atn (info, pp)
- struct ieee_info *info;
- const bfd_byte **pp;
+static bfd_boolean
+parse_ieee_atn (struct ieee_info *info, const bfd_byte **pp)
{
const bfd_byte *atn_start, *atn_code_start;
bfd_vma varindx;
struct ieee_var *pvar;
debug_type type;
bfd_vma atn_code;
- PTR dhandle;
+ void *dhandle;
bfd_vma v, v2, v3, v4, v5;
const char *name;
unsigned long namlen;
char *namcopy;
- boolean present;
+ bfd_boolean present;
int blocktype;
atn_start = *pp;
if (! ieee_read_number (info, pp, &varindx)
|| ! ieee_read_type_index (info, pp, &type))
- return false;
+ return FALSE;
atn_code_start = *pp;
if (! ieee_read_number (info, pp, &atn_code))
- return false;
+ return FALSE;
if (varindx == 0)
{
@@ -2150,7 +2106,7 @@ parse_ieee_atn (info, pp)
return ieee_read_number (info, pp, &v);
ieee_error (info, atn_start, _("illegal variable index"));
- return false;
+ return FALSE;
}
else
{
@@ -2188,7 +2144,7 @@ parse_ieee_atn (info, pp)
else
{
ieee_error (info, atn_start, _("undefined variable in ATN"));
- return false;
+ return FALSE;
}
}
@@ -2231,12 +2187,12 @@ parse_ieee_atn (info, pp)
{
default:
ieee_error (info, atn_code_start, _("unknown ATN type"));
- return false;
+ return FALSE;
case 1:
/* Automatic variable. */
if (! ieee_read_number (info, pp, &v))
- return false;
+ return FALSE;
namcopy = savestring (name, namlen);
if (type == NULL)
type = debug_make_void_type (dhandle);
@@ -2247,7 +2203,7 @@ parse_ieee_atn (info, pp)
case 2:
/* Register variable. */
if (! ieee_read_number (info, pp, &v))
- return false;
+ return FALSE;
namcopy = savestring (name, namlen);
if (type == NULL)
type = debug_make_void_type (dhandle);
@@ -2259,7 +2215,7 @@ parse_ieee_atn (info, pp)
case 3:
/* Static variable. */
if (! ieee_require_asn (info, pp, &v))
- return false;
+ return FALSE;
namcopy = savestring (name, namlen);
if (type == NULL)
type = debug_make_void_type (dhandle);
@@ -2284,30 +2240,30 @@ parse_ieee_atn (info, pp)
/* External function. We don't currently record these. FIXME. */
if (pvar != NULL)
pvar->kind = IEEE_EXTERNAL;
- return true;
+ return TRUE;
case 5:
/* External variable. We don't currently record these. FIXME. */
if (pvar != NULL)
pvar->kind = IEEE_EXTERNAL;
- return true;
+ return TRUE;
case 7:
if (! ieee_read_number (info, pp, &v)
|| ! ieee_read_number (info, pp, &v2)
|| ! ieee_read_optional_number (info, pp, &v3, &present))
- return false;
+ return FALSE;
if (present)
{
if (! ieee_read_optional_number (info, pp, &v4, &present))
- return false;
+ return FALSE;
}
/* We just ignore the two optional fields in v3 and v4, since
they are not defined. */
if (! ieee_require_asn (info, pp, &v3))
- return false;
+ return FALSE;
/* We have no way to record the column number. FIXME. */
@@ -2316,7 +2272,7 @@ parse_ieee_atn (info, pp)
case 8:
/* Global variable. */
if (! ieee_require_asn (info, pp, &v))
- return false;
+ return FALSE;
namcopy = savestring (name, namlen);
if (type == NULL)
type = debug_make_void_type (dhandle);
@@ -2327,10 +2283,10 @@ parse_ieee_atn (info, pp)
case 9:
/* Variable lifetime information. */
if (! ieee_read_number (info, pp, &v))
- return false;
+ return FALSE;
/* We have no way to record this information. FIXME. */
- return true;
+ return TRUE;
case 10:
/* Locked register. The spec says that there are two required
@@ -2338,7 +2294,7 @@ parse_ieee_atn (info, pp)
one. */
if (! ieee_read_number (info, pp, &v)
|| ! ieee_read_optional_number (info, pp, &v2, &present))
- return false;
+ return FALSE;
/* I think this means a variable that is both in a register and
a frame slot. We ignore the frame slot. FIXME. */
@@ -2354,8 +2310,8 @@ parse_ieee_atn (info, pp)
/* Reserved for FORTRAN common. */
ieee_error (info, atn_code_start, _("unsupported ATN11"));
- /* Return true to keep going. */
- return true;
+ /* Return TRUE to keep going. */
+ return TRUE;
case 12:
/* Based variable. */
@@ -2365,15 +2321,15 @@ parse_ieee_atn (info, pp)
if (! ieee_read_number (info, pp, &v)
|| ! ieee_read_number (info, pp, &v2)
|| ! ieee_read_optional_number (info, pp, &v3, &present))
- return false;
+ return FALSE;
if (present)
{
if (! ieee_read_optional_number (info, pp, &v4, &present))
- return false;
+ return FALSE;
if (present)
{
if (! ieee_read_optional_number (info, pp, &v5, &present))
- return false;
+ return FALSE;
}
}
@@ -2381,33 +2337,33 @@ parse_ieee_atn (info, pp)
ieee_error (info, atn_code_start, _("unsupported ATN12"));
- /* Return true to keep going. */
- return true;
+ /* Return TRUE to keep going. */
+ return TRUE;
case 16:
/* Constant. The description of this that I have is ambiguous,
so I'm not going to try to implement it. */
if (! ieee_read_number (info, pp, &v)
|| ! ieee_read_optional_number (info, pp, &v2, &present))
- return false;
+ return FALSE;
if (present)
{
if (! ieee_read_optional_number (info, pp, &v2, &present))
- return false;
+ return FALSE;
if (present)
{
if (! ieee_read_optional_id (info, pp, &name, &namlen, &present))
- return false;
+ return FALSE;
}
}
if ((ieee_record_enum_type) **pp == ieee_e2_first_byte_enum)
{
if (! ieee_require_asn (info, pp, &v3))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
case 19:
/* Static variable from assembler. */
@@ -2415,7 +2371,7 @@ parse_ieee_atn (info, pp)
if (! ieee_read_number (info, pp, &v)
|| ! ieee_read_optional_number (info, pp, &v2, &present)
|| ! ieee_require_asn (info, pp, &v3))
- return false;
+ return FALSE;
namcopy = savestring (name, namlen);
/* We don't really handle this correctly. FIXME. */
return debug_record_variable (dhandle, namcopy,
@@ -2432,7 +2388,7 @@ parse_ieee_atn (info, pp)
if (! ieee_read_number (info, pp, &v)
|| ! ieee_read_number (info, pp, &v2)
|| ! ieee_read_optional_id (info, pp, &name, &namlen, &present))
- return false;
+ return FALSE;
if (atn_code == 62 && v == 80)
{
@@ -2440,7 +2396,7 @@ parse_ieee_atn (info, pp)
{
ieee_error (info, atn_code_start,
_("unexpected string in C++ misc"));
- return false;
+ return FALSE;
}
return ieee_read_cxx_misc (info, pp, v2);
}
@@ -2453,21 +2409,21 @@ parse_ieee_atn (info, pp)
{
default:
ieee_error (info, *pp, _("bad misc record"));
- return false;
+ return FALSE;
case ieee_at_record_enum:
if (! ieee_require_atn65 (info, pp, &name, &namlen))
- return false;
+ return FALSE;
break;
case ieee_e2_first_byte_enum:
if (! ieee_require_asn (info, pp, &v3))
- return false;
+ return FALSE;
break;
}
}
- return true;
+ return TRUE;
}
/*NOTREACHED*/
@@ -2476,11 +2432,9 @@ parse_ieee_atn (info, pp)
/* Handle C++ debugging miscellaneous records. This is called for
procedure miscellaneous records of type 80. */
-static boolean
-ieee_read_cxx_misc (info, pp, count)
- struct ieee_info *info;
- const bfd_byte **pp;
- unsigned long count;
+static bfd_boolean
+ieee_read_cxx_misc (struct ieee_info *info, const bfd_byte **pp,
+ unsigned long count)
{
const bfd_byte *start;
bfd_vma category;
@@ -2489,18 +2443,18 @@ ieee_read_cxx_misc (info, pp, count)
/* Get the category of C++ misc record. */
if (! ieee_require_asn (info, pp, &category))
- return false;
+ return FALSE;
--count;
switch (category)
{
default:
ieee_error (info, start, _("unrecognized C++ misc record"));
- return false;
+ return FALSE;
case 'T':
if (! ieee_read_cxx_class (info, pp, count))
- return false;
+ return FALSE;
break;
case 'M':
@@ -2514,12 +2468,12 @@ ieee_read_cxx_misc (info, pp, count)
function. */
if (! ieee_require_asn (info, pp, &flags))
- return false;
+ return FALSE;
if (*pp < info->pend
&& (ieee_record_enum_type) **pp == ieee_at_record_enum)
{
if (! ieee_require_atn65 (info, pp, &name, &namlen))
- return false;
+ return FALSE;
}
/* This is emitted for method functions, but I don't think we
@@ -2531,7 +2485,7 @@ ieee_read_cxx_misc (info, pp, count)
case 'B':
if (! ieee_read_cxx_defaults (info, pp, count))
- return false;
+ return FALSE;
break;
case 'z':
@@ -2546,7 +2500,7 @@ ieee_read_cxx_misc (info, pp, count)
|| ! ieee_require_atn65 (info, pp, &mangled, &mangledlen)
|| ! ieee_require_atn65 (info, pp, &class, &classlen)
|| ! ieee_require_asn (info, pp, &control))
- return false;
+ return FALSE;
/* FIXME: We should now track down name and change its type. */
}
@@ -2554,28 +2508,26 @@ ieee_read_cxx_misc (info, pp, count)
case 'R':
if (! ieee_read_reference (info, pp))
- return false;
+ return FALSE;
break;
}
- return true;
+ return TRUE;
}
/* Read a C++ class definition. This is a pmisc type 80 record of
category 'T'. */
-static boolean
-ieee_read_cxx_class (info, pp, count)
- struct ieee_info *info;
- const bfd_byte **pp;
- unsigned long count;
+static bfd_boolean
+ieee_read_cxx_class (struct ieee_info *info, const bfd_byte **pp,
+ unsigned long count)
{
const bfd_byte *start;
bfd_vma class;
const char *tag;
unsigned long taglen;
struct ieee_tag *it;
- PTR dhandle;
+ void *dhandle;
debug_field *fields;
unsigned int field_count, field_alloc;
debug_baseclass *baseclasses;
@@ -2591,17 +2543,17 @@ ieee_read_cxx_class (info, pp, count)
} *methods;
unsigned int methods_count, methods_alloc;
debug_type vptrbase;
- boolean ownvptr;
+ bfd_boolean ownvptr;
debug_method *dmethods;
start = *pp;
if (! ieee_require_asn (info, pp, &class))
- return false;
+ return FALSE;
--count;
if (! ieee_require_atn65 (info, pp, &tag, &taglen))
- return false;
+ return FALSE;
--count;
/* Find the C struct with this name. */
@@ -2613,7 +2565,7 @@ ieee_read_cxx_class (info, pp, count)
if (it == NULL)
{
ieee_error (info, start, _("undefined C++ object"));
- return false;
+ return FALSE;
}
dhandle = info->dhandle;
@@ -2628,7 +2580,7 @@ ieee_read_cxx_class (info, pp, count)
methods_count = 0;
methods_alloc = 0;
vptrbase = DEBUG_TYPE_NULL;
- ownvptr = false;
+ ownvptr = FALSE;
structfields = debug_get_fields (dhandle, it->type);
@@ -2640,14 +2592,14 @@ ieee_read_cxx_class (info, pp, count)
spec_start = *pp;
if (! ieee_require_asn (info, pp, &id))
- return false;
+ return FALSE;
--count;
switch (id)
{
default:
ieee_error (info, spec_start, _("unrecognized C++ object spec"));
- return false;
+ return FALSE;
case 'b':
{
@@ -2657,7 +2609,7 @@ ieee_read_cxx_class (info, pp, count)
char *basecopy;
debug_type basetype;
bfd_vma bitpos;
- boolean virtualp;
+ bfd_boolean virtualp;
enum debug_visibility visibility;
debug_baseclass baseclass;
@@ -2667,7 +2619,7 @@ ieee_read_cxx_class (info, pp, count)
|| ! ieee_require_atn65 (info, pp, &basename, &baselen)
|| ! ieee_require_asn (info, pp, &cinline)
|| ! ieee_require_atn65 (info, pp, &fieldname, &fieldlen))
- return false;
+ return FALSE;
count -= 4;
/* We have no way of recording friend information, so we
@@ -2683,7 +2635,7 @@ ieee_read_cxx_class (info, pp, count)
if ((fieldlen == 0) == (cinline == 0))
{
ieee_error (info, start, _("unsupported C++ object type"));
- return false;
+ return FALSE;
}
basecopy = savestring (basename, baselen);
@@ -2693,7 +2645,7 @@ ieee_read_cxx_class (info, pp, count)
if (basetype == DEBUG_TYPE_NULL)
{
ieee_error (info, start, _("C++ base class not defined"));
- return false;
+ return FALSE;
}
if (fieldlen == 0)
@@ -2705,7 +2657,7 @@ ieee_read_cxx_class (info, pp, count)
if (structfields == NULL)
{
ieee_error (info, start, _("C++ object has no fields"));
- return false;
+ return FALSE;
}
for (pf = structfields; *pf != DEBUG_FIELD_NULL; pf++)
@@ -2714,7 +2666,7 @@ ieee_read_cxx_class (info, pp, count)
fname = debug_get_field_name (dhandle, *pf);
if (fname == NULL)
- return false;
+ return FALSE;
if (fname[0] == fieldname[0]
&& strncmp (fname, fieldname, fieldlen) == 0
&& strlen (fname) == fieldlen)
@@ -2724,16 +2676,16 @@ ieee_read_cxx_class (info, pp, count)
{
ieee_error (info, start,
_("C++ base class not found in container"));
- return false;
+ return FALSE;
}
bitpos = debug_get_field_bitpos (dhandle, *pf);
}
if ((flags & BASEFLAGS_VIRTUAL) != 0)
- virtualp = true;
+ virtualp = TRUE;
else
- virtualp = false;
+ virtualp = FALSE;
if ((flags & BASEFLAGS_PRIVATE) != 0)
visibility = DEBUG_VISIBILITY_PRIVATE;
else
@@ -2742,7 +2694,7 @@ ieee_read_cxx_class (info, pp, count)
baseclass = debug_make_baseclass (dhandle, basetype, bitpos,
virtualp, visibility);
if (baseclass == DEBUG_BASECLASS_NULL)
- return false;
+ return FALSE;
if (baseclasses_count + 1 >= baseclasses_alloc)
{
@@ -2765,7 +2717,7 @@ ieee_read_cxx_class (info, pp, count)
const char *fieldname, *mangledname;
unsigned long fieldlen, mangledlen;
char *fieldcopy;
- boolean staticp;
+ bfd_boolean staticp;
debug_type ftype;
const debug_field *pf = NULL;
enum debug_visibility visibility;
@@ -2776,12 +2728,12 @@ ieee_read_cxx_class (info, pp, count)
if (! ieee_require_asn (info, pp, &flags)
|| ! ieee_require_atn65 (info, pp, &fieldname, &fieldlen)
|| ! ieee_require_atn65 (info, pp, &mangledname, &mangledlen))
- return false;
+ return FALSE;
count -= 3;
fieldcopy = savestring (fieldname, fieldlen);
- staticp = (flags & CXXFLAGS_STATIC) != 0 ? true : false;
+ staticp = (flags & CXXFLAGS_STATIC) != 0 ? TRUE : FALSE;
if (staticp)
{
@@ -2810,7 +2762,7 @@ ieee_read_cxx_class (info, pp, count)
if (structfields == NULL)
{
ieee_error (info, start, _("C++ object has no fields"));
- return false;
+ return FALSE;
}
for (pf = structfields, findx = 0;
@@ -2821,7 +2773,7 @@ ieee_read_cxx_class (info, pp, count)
fname = debug_get_field_name (dhandle, *pf);
if (fname == NULL)
- return false;
+ return FALSE;
if (fname[0] == mangledname[0]
&& strncmp (fname, mangledname, mangledlen) == 0
&& strlen (fname) == mangledlen)
@@ -2831,7 +2783,7 @@ ieee_read_cxx_class (info, pp, count)
{
ieee_error (info, start,
_("C++ data member not found in container"));
- return false;
+ return FALSE;
}
ftype = debug_get_field_type (dhandle, *pf);
@@ -2858,7 +2810,7 @@ ieee_read_cxx_class (info, pp, count)
}
if (ftype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
it->fslots[findx] = ftype;
ftype = debug_make_indirect_type (dhandle,
it->fslots + findx,
@@ -2866,13 +2818,13 @@ ieee_read_cxx_class (info, pp, count)
}
}
if (ftype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
switch (flags & CXXFLAGS_VISIBILITY)
{
default:
ieee_error (info, start, _("unknown C++ visibility"));
- return false;
+ return FALSE;
case CXXFLAGS_VISIBILITY_PUBLIC:
visibility = DEBUG_VISIBILITY_PUBLIC;
@@ -2906,14 +2858,14 @@ ieee_read_cxx_class (info, pp, count)
if (bitpos == (bfd_vma) -1 || bitsize == (bfd_vma) -1)
{
ieee_error (info, start, _("bad C++ field bit pos or size"));
- return false;
+ return FALSE;
}
field = debug_make_field (dhandle, fieldcopy, ftype, bitpos,
bitsize, visibility);
}
if (field == DEBUG_FIELD_NULL)
- return false;
+ return FALSE;
if (field_count + 1 >= field_alloc)
{
@@ -2937,7 +2889,7 @@ ieee_read_cxx_class (info, pp, count)
struct ieee_var *pv, *pvend;
debug_type type;
enum debug_visibility visibility;
- boolean constp, volatilep;
+ bfd_boolean constp, volatilep;
char *mangledcopy;
debug_method_variant mv;
struct ieee_method *meth;
@@ -2946,18 +2898,18 @@ ieee_read_cxx_class (info, pp, count)
if (! ieee_require_asn (info, pp, &flags)
|| ! ieee_require_atn65 (info, pp, &name, &namlen)
|| ! ieee_require_atn65 (info, pp, &mangled, &mangledlen))
- return false;
+ return FALSE;
count -= 3;
if (id != 'v')
voffset = 0;
else
{
if (! ieee_require_asn (info, pp, &voffset))
- return false;
+ return FALSE;
--count;
}
if (! ieee_require_asn (info, pp, &control))
- return false;
+ return FALSE;
--count;
/* We just ignore the control information. */
@@ -2985,20 +2937,20 @@ ieee_read_cxx_class (info, pp, count)
ieee_builtin_type (info, start,
(unsigned int) builtin_void),
(debug_type *) NULL,
- false));
+ FALSE));
}
else
{
debug_type return_type;
const debug_type *arg_types;
- boolean varargs;
+ bfd_boolean varargs;
if (debug_get_type_kind (dhandle, pv->type)
!= DEBUG_KIND_FUNCTION)
{
ieee_error (info, start,
_("bad type for C++ method function"));
- return false;
+ return FALSE;
}
return_type = debug_get_return_type (dhandle, pv->type);
@@ -3008,7 +2960,7 @@ ieee_read_cxx_class (info, pp, count)
{
ieee_error (info, start,
_("no type information for C++ method function"));
- return false;
+ return FALSE;
}
type = debug_make_method_type (dhandle, return_type, it->type,
@@ -3016,13 +2968,13 @@ ieee_read_cxx_class (info, pp, count)
varargs);
}
if (type == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
switch (flags & CXXFLAGS_VISIBILITY)
{
default:
ieee_error (info, start, _("unknown C++ visibility"));
- return false;
+ return FALSE;
case CXXFLAGS_VISIBILITY_PUBLIC:
visibility = DEBUG_VISIBILITY_PUBLIC;
@@ -3037,8 +2989,8 @@ ieee_read_cxx_class (info, pp, count)
break;
}
- constp = (flags & CXXFLAGS_CONST) != 0 ? true : false;
- volatilep = (flags & CXXFLAGS_VOLATILE) != 0 ? true : false;
+ constp = (flags & CXXFLAGS_CONST) != 0 ? TRUE : FALSE;
+ volatilep = (flags & CXXFLAGS_VOLATILE) != 0 ? TRUE : FALSE;
mangledcopy = savestring (mangled, mangledlen);
@@ -3047,7 +2999,7 @@ ieee_read_cxx_class (info, pp, count)
if (id == 'v')
{
ieee_error (info, start, _("C++ static virtual method"));
- return false;
+ return FALSE;
}
mv = debug_make_static_method_variant (dhandle, mangledcopy,
type, visibility,
@@ -3070,7 +3022,7 @@ ieee_read_cxx_class (info, pp, count)
vcontext);
}
if (mv == DEBUG_METHOD_VARIANT_NULL)
- return false;
+ return FALSE;
for (meth = methods, im = 0; im < methods_count; meth++, im++)
if (meth->namlen == namlen
@@ -3116,7 +3068,7 @@ ieee_read_cxx_class (info, pp, count)
/* We have no way to store this information, so we just
ignore it. */
if (! ieee_require_asn (info, pp, &spec))
- return false;
+ return FALSE;
--count;
if ((spec & 4) != 0)
{
@@ -3126,7 +3078,7 @@ ieee_read_cxx_class (info, pp, count)
if (! ieee_require_atn65 (info, pp, &filename, &filenamlen)
|| ! ieee_require_asn (info, pp, &lineno))
- return false;
+ return FALSE;
count -= 2;
}
else if ((spec & 8) != 0)
@@ -3135,14 +3087,14 @@ ieee_read_cxx_class (info, pp, count)
unsigned long mangledlen;
if (! ieee_require_atn65 (info, pp, &mangled, &mangledlen))
- return false;
+ return FALSE;
--count;
}
else
{
ieee_error (info, start,
_("unrecognized C++ object overhead spec"));
- return false;
+ return FALSE;
}
}
break;
@@ -3159,7 +3111,7 @@ ieee_read_cxx_class (info, pp, count)
|| ! ieee_require_asn (info, pp, &vsize)
|| ! ieee_require_atn65 (info, pp, &basename, &baselen)
|| ! ieee_require_asn (info, pp, &control))
- return false;
+ return FALSE;
count -= 4;
/* We just ignore the control number. We don't care what
@@ -3169,7 +3121,7 @@ ieee_read_cxx_class (info, pp, count)
/* FIXME: We can't handle multiple virtual table pointers. */
if (baselen == 0)
- ownvptr = true;
+ ownvptr = TRUE;
else
{
char *basecopy;
@@ -3181,7 +3133,7 @@ ieee_read_cxx_class (info, pp, count)
if (vptrbase == DEBUG_TYPE_NULL)
{
ieee_error (info, start, _("undefined C++ vtable"));
- return false;
+ return FALSE;
}
}
}
@@ -3208,7 +3160,7 @@ ieee_read_cxx_class (info, pp, count)
dmethods[i] = debug_make_method (dhandle, namcopy,
methods[i].variants);
if (dmethods[i] == DEBUG_METHOD_NULL)
- return false;
+ return FALSE;
}
dmethods[i] = DEBUG_METHOD_NULL;
free (methods);
@@ -3224,18 +3176,16 @@ ieee_read_cxx_class (info, pp, count)
fields, baseclasses, dmethods,
vptrbase, ownvptr);
if (it->slot == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
/* Read C++ default argument value and reference type information. */
-static boolean
-ieee_read_cxx_defaults (info, pp, count)
- struct ieee_info *info;
- const bfd_byte **pp;
- unsigned long count;
+static bfd_boolean
+ieee_read_cxx_defaults (struct ieee_info *info, const bfd_byte **pp,
+ unsigned long count)
{
const bfd_byte *start;
const char *fnname;
@@ -3252,12 +3202,12 @@ ieee_read_cxx_defaults (info, pp, count)
|| info->blockstack.bsp[-1].fnindx == (unsigned int) -1)
{
ieee_error (info, start, _("C++ default values not in a function"));
- return false;
+ return FALSE;
}
if (! ieee_require_atn65 (info, pp, &fnname, &fnlen)
|| ! ieee_require_asn (info, pp, &defcount))
- return false;
+ return FALSE;
count -= 2;
while (defcount-- > 0)
@@ -3267,7 +3217,7 @@ ieee_read_cxx_defaults (info, pp, count)
unsigned long strvallen;
if (! ieee_require_asn (info, pp, &type))
- return false;
+ return FALSE;
--count;
switch (type)
@@ -3279,20 +3229,20 @@ ieee_read_cxx_defaults (info, pp, count)
case 1:
case 2:
if (! ieee_require_asn (info, pp, &val))
- return false;
+ return FALSE;
--count;
break;
case 3:
case 7:
if (! ieee_require_atn65 (info, pp, &strval, &strvallen))
- return false;
+ return FALSE;
--count;
break;
default:
ieee_error (info, start, _("unrecognized C++ default type"));
- return false;
+ return FALSE;
}
/* We have no way to record the default argument values, so we
@@ -3303,7 +3253,7 @@ ieee_read_cxx_defaults (info, pp, count)
reference type. */
if (count > 0)
{
- PTR dhandle;
+ void *dhandle;
debug_type *arg_slots;
dhandle = info->dhandle;
@@ -3314,7 +3264,7 @@ ieee_read_cxx_defaults (info, pp, count)
debug_type target;
if (! ieee_require_asn (info, pp, &indx))
- return false;
+ return FALSE;
/* The index is 1 based. */
--indx;
if (arg_slots == NULL
@@ -3323,25 +3273,23 @@ ieee_read_cxx_defaults (info, pp, count)
!= DEBUG_KIND_POINTER))
{
ieee_error (info, start, _("reference parameter is not a pointer"));
- return false;
+ return FALSE;
}
target = debug_get_target_type (dhandle, arg_slots[indx]);
arg_slots[indx] = debug_make_reference_type (dhandle, target);
if (arg_slots[indx] == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
/* Read a C++ reference definition. */
-static boolean
-ieee_read_reference (info, pp)
- struct ieee_info *info;
- const bfd_byte **pp;
+static bfd_boolean
+ieee_read_reference (struct ieee_info *info, const bfd_byte **pp)
{
const bfd_byte *start;
bfd_vma flags;
@@ -3353,18 +3301,18 @@ ieee_read_reference (info, pp)
start = *pp;
if (! ieee_require_asn (info, pp, &flags))
- return false;
+ return FALSE;
/* Giving the class name before the member name is in an addendum to
the spec. */
if (flags == 3)
{
if (! ieee_require_atn65 (info, pp, &class, &classlen))
- return false;
+ return FALSE;
}
if (! ieee_require_atn65 (info, pp, &name, &namlen))
- return false;
+ return FALSE;
pslot = NULL;
if (flags != 3)
@@ -3393,7 +3341,7 @@ ieee_read_reference (info, pp)
for (i = (int) vars->alloc - 1; i >= 0; i--)
{
- boolean found;
+ bfd_boolean found;
pv = vars->vars + i;
@@ -3402,33 +3350,33 @@ ieee_read_reference (info, pp)
|| strncmp (pv->name, name, namlen) != 0)
continue;
- found = false;
+ found = FALSE;
switch (flags)
{
default:
ieee_error (info, start,
_("unrecognized C++ reference type"));
- return false;
+ return FALSE;
case 0:
/* Global variable or function. */
if (pv->kind == IEEE_GLOBAL
|| pv->kind == IEEE_EXTERNAL
|| pv->kind == IEEE_FUNCTION)
- found = true;
+ found = TRUE;
break;
case 1:
/* Global static variable or function. */
if (pv->kind == IEEE_STATIC
|| pv->kind == IEEE_FUNCTION)
- found = true;
+ found = TRUE;
break;
case 2:
/* Local variable. */
if (pv->kind == IEEE_LOCAL)
- found = true;
+ found = TRUE;
break;
}
@@ -3463,7 +3411,7 @@ ieee_read_reference (info, pp)
{
ieee_error (info, start,
"C++ reference in class with no fields");
- return false;
+ return FALSE;
}
for (findx = 0; *pf != DEBUG_FIELD_NULL; pf++, findx++)
@@ -3472,7 +3420,7 @@ ieee_read_reference (info, pp)
fname = debug_get_field_name (info->dhandle, *pf);
if (fname == NULL)
- return false;
+ return FALSE;
if (strncmp (fname, name, namlen) == 0
&& strlen (fname) == namlen)
{
@@ -3490,7 +3438,7 @@ ieee_read_reference (info, pp)
if (pslot == NULL)
{
ieee_error (info, start, _("C++ reference not found"));
- return false;
+ return FALSE;
}
/* We allocated the type of the object as an indirect type pointing
@@ -3498,24 +3446,21 @@ ieee_read_reference (info, pp)
if (debug_get_type_kind (info->dhandle, *pslot) != DEBUG_KIND_POINTER)
{
ieee_error (info, start, _("C++ reference is not pointer"));
- return false;
+ return FALSE;
}
target = debug_get_target_type (info->dhandle, *pslot);
*pslot = debug_make_reference_type (info->dhandle, target);
if (*pslot == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
/* Require an ASN record. */
-static boolean
-ieee_require_asn (info, pp, pv)
- struct ieee_info *info;
- const bfd_byte **pp;
- bfd_vma *pv;
+static bfd_boolean
+ieee_require_asn (struct ieee_info *info, const bfd_byte **pp, bfd_vma *pv)
{
const bfd_byte *start;
ieee_record_enum_type c;
@@ -3527,7 +3472,7 @@ ieee_require_asn (info, pp, pv)
if (c != ieee_e2_first_byte_enum)
{
ieee_error (info, start, _("missing required ASN"));
- return false;
+ return FALSE;
}
++*pp;
@@ -3535,25 +3480,22 @@ ieee_require_asn (info, pp, pv)
if (c != ieee_asn_record_enum)
{
ieee_error (info, start, _("missing required ASN"));
- return false;
+ return FALSE;
}
++*pp;
/* Just ignore the variable index. */
if (! ieee_read_number (info, pp, &varindx))
- return false;
+ return FALSE;
return ieee_read_expression (info, pp, pv);
}
/* Require an ATN65 record. */
-static boolean
-ieee_require_atn65 (info, pp, pname, pnamlen)
- struct ieee_info *info;
- const bfd_byte **pp;
- const char **pname;
- unsigned long *pnamlen;
+static bfd_boolean
+ieee_require_atn65 (struct ieee_info *info, const bfd_byte **pp,
+ const char **pname, unsigned long *pnamlen)
{
const bfd_byte *start;
ieee_record_enum_type c;
@@ -3565,7 +3507,7 @@ ieee_require_atn65 (info, pp, pname, pnamlen)
if (c != ieee_at_record_enum)
{
ieee_error (info, start, _("missing required ATN65"));
- return false;
+ return FALSE;
}
++*pp;
@@ -3573,21 +3515,21 @@ ieee_require_atn65 (info, pp, pname, pnamlen)
if (c != ieee_atn_record_enum)
{
ieee_error (info, start, _("missing required ATN65"));
- return false;
+ return FALSE;
}
++*pp;
if (! ieee_read_number (info, pp, &name_indx)
|| ! ieee_read_number (info, pp, &type_indx)
|| ! ieee_read_number (info, pp, &atn_code))
- return false;
+ return FALSE;
/* Just ignore name_indx. */
if (type_indx != 0 || atn_code != 65)
{
ieee_error (info, start, _("bad ATN65 record"));
- return false;
+ return FALSE;
}
return ieee_read_id (info, pp, pname, pnamlen);
@@ -3597,9 +3539,7 @@ ieee_require_atn65 (info, pp, pname, pnamlen)
generic register number. */
static int
-ieee_regno_to_genreg (abfd, r)
- bfd *abfd;
- int r;
+ieee_regno_to_genreg (bfd *abfd, int r)
{
switch (bfd_get_arch (abfd))
{
@@ -3626,9 +3566,7 @@ ieee_regno_to_genreg (abfd, r)
/* Convert a generic register number to an IEEE specific one. */
static int
-ieee_genreg_to_regno (abfd, r)
- bfd *abfd;
- int r;
+ieee_genreg_to_regno (bfd *abfd, int r)
{
switch (bfd_get_arch (abfd))
{
@@ -3709,7 +3647,7 @@ struct ieee_type_class
class. */
const char *vclass;
/* Whether this class holds its own virtual table. */
- boolean ownvptr;
+ bfd_boolean ownvptr;
/* The largest virtual table offset seen so far. */
bfd_vma voffset;
/* The current method. */
@@ -3800,7 +3738,7 @@ struct ieee_defined_enum
/* Type index. */
unsigned int indx;
/* Whether this enum has been defined. */
- boolean defined;
+ bfd_boolean defined;
/* Tag. */
const char *tag;
/* Names. */
@@ -3852,7 +3790,7 @@ struct ieee_pending_parm
/* Type index. */
unsigned int type;
/* Whether the type is a reference. */
- boolean referencep;
+ bfd_boolean referencep;
/* Kind. */
enum debug_parm_kind kind;
/* Value. */
@@ -3867,7 +3805,7 @@ struct ieee_handle
bfd *abfd;
/* Whether we got an error in a subroutine called via traverse or
map_over_sections. */
- boolean error;
+ bfd_boolean error;
/* Current data buffer list. */
struct ieee_buflist *current;
/* Current data buffer. */
@@ -3945,112 +3883,109 @@ struct ieee_handle
bfd_vma highaddr;
};
-static boolean ieee_init_buffer
- PARAMS ((struct ieee_handle *, struct ieee_buflist *));
-static boolean ieee_change_buffer
- PARAMS ((struct ieee_handle *, struct ieee_buflist *));
-static boolean ieee_append_buffer
- PARAMS ((struct ieee_handle *, struct ieee_buflist *,
- struct ieee_buflist *));
-static boolean ieee_real_write_byte PARAMS ((struct ieee_handle *, int));
-static boolean ieee_write_2bytes PARAMS ((struct ieee_handle *, int));
-static boolean ieee_write_number PARAMS ((struct ieee_handle *, bfd_vma));
-static boolean ieee_write_id PARAMS ((struct ieee_handle *, const char *));
-static boolean ieee_write_asn
- PARAMS ((struct ieee_handle *, unsigned int, bfd_vma));
-static boolean ieee_write_atn65
- PARAMS ((struct ieee_handle *, unsigned int, const char *));
-static boolean ieee_push_type
- PARAMS ((struct ieee_handle *, unsigned int, unsigned int, boolean,
- boolean));
-static unsigned int ieee_pop_type PARAMS ((struct ieee_handle *));
-static void ieee_pop_unused_type PARAMS ((struct ieee_handle *));
-static unsigned int ieee_pop_type_used
- PARAMS ((struct ieee_handle *, boolean));
-static boolean ieee_add_range
- PARAMS ((struct ieee_handle *, boolean, bfd_vma, bfd_vma));
-static boolean ieee_start_range PARAMS ((struct ieee_handle *, bfd_vma));
-static boolean ieee_end_range PARAMS ((struct ieee_handle *, bfd_vma));
-static boolean ieee_define_type
- PARAMS ((struct ieee_handle *, unsigned int, boolean, boolean));
-static boolean ieee_define_named_type
- PARAMS ((struct ieee_handle *, const char *, unsigned int, unsigned int,
- boolean, boolean, struct ieee_buflist *));
+static bfd_boolean ieee_init_buffer
+ (struct ieee_handle *, struct ieee_buflist *);
+static bfd_boolean ieee_change_buffer
+ (struct ieee_handle *, struct ieee_buflist *);
+static bfd_boolean ieee_append_buffer
+ (struct ieee_handle *, struct ieee_buflist *, struct ieee_buflist *);
+static bfd_boolean ieee_real_write_byte (struct ieee_handle *, int);
+static bfd_boolean ieee_write_2bytes (struct ieee_handle *, int);
+static bfd_boolean ieee_write_number (struct ieee_handle *, bfd_vma);
+static bfd_boolean ieee_write_id (struct ieee_handle *, const char *);
+static bfd_boolean ieee_write_asn
+ (struct ieee_handle *, unsigned int, bfd_vma);
+static bfd_boolean ieee_write_atn65
+ (struct ieee_handle *, unsigned int, const char *);
+static bfd_boolean ieee_push_type
+ (struct ieee_handle *, unsigned int, unsigned int, bfd_boolean,
+ bfd_boolean);
+static unsigned int ieee_pop_type (struct ieee_handle *);
+static void ieee_pop_unused_type (struct ieee_handle *);
+static unsigned int ieee_pop_type_used (struct ieee_handle *, bfd_boolean);
+static bfd_boolean ieee_add_range
+ (struct ieee_handle *, bfd_boolean, bfd_vma, bfd_vma);
+static bfd_boolean ieee_start_range (struct ieee_handle *, bfd_vma);
+static bfd_boolean ieee_end_range (struct ieee_handle *, bfd_vma);
+static bfd_boolean ieee_define_type
+ (struct ieee_handle *, unsigned int, bfd_boolean, bfd_boolean);
+static bfd_boolean ieee_define_named_type
+ (struct ieee_handle *, const char *, unsigned int, unsigned int,
+ bfd_boolean, bfd_boolean, struct ieee_buflist *);
static struct ieee_modified_type *ieee_get_modified_info
- PARAMS ((struct ieee_handle *, unsigned int));
+ (struct ieee_handle *, unsigned int);
static struct bfd_hash_entry *ieee_name_type_newfunc
- PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-static boolean ieee_write_undefined_tag
- PARAMS ((struct ieee_name_type_hash_entry *, PTR));
-static boolean ieee_finish_compilation_unit PARAMS ((struct ieee_handle *));
-static void ieee_add_bb11_blocks PARAMS ((bfd *, asection *, PTR));
-static boolean ieee_add_bb11
- PARAMS ((struct ieee_handle *, asection *, bfd_vma, bfd_vma));
-static boolean ieee_output_pending_parms PARAMS ((struct ieee_handle *));
-static unsigned int ieee_vis_to_flags PARAMS ((enum debug_visibility));
-static boolean ieee_class_method_var
- PARAMS ((struct ieee_handle *, const char *, enum debug_visibility, boolean,
- boolean, boolean, bfd_vma, boolean));
-
-static boolean ieee_start_compilation_unit PARAMS ((PTR, const char *));
-static boolean ieee_start_source PARAMS ((PTR, const char *));
-static boolean ieee_empty_type PARAMS ((PTR));
-static boolean ieee_void_type PARAMS ((PTR));
-static boolean ieee_int_type PARAMS ((PTR, unsigned int, boolean));
-static boolean ieee_float_type PARAMS ((PTR, unsigned int));
-static boolean ieee_complex_type PARAMS ((PTR, unsigned int));
-static boolean ieee_bool_type PARAMS ((PTR, unsigned int));
-static boolean ieee_enum_type
- PARAMS ((PTR, const char *, const char **, bfd_signed_vma *));
-static boolean ieee_pointer_type PARAMS ((PTR));
-static boolean ieee_function_type PARAMS ((PTR, int, boolean));
-static boolean ieee_reference_type PARAMS ((PTR));
-static boolean ieee_range_type PARAMS ((PTR, bfd_signed_vma, bfd_signed_vma));
-static boolean ieee_array_type
- PARAMS ((PTR, bfd_signed_vma, bfd_signed_vma, boolean));
-static boolean ieee_set_type PARAMS ((PTR, boolean));
-static boolean ieee_offset_type PARAMS ((PTR));
-static boolean ieee_method_type PARAMS ((PTR, boolean, int, boolean));
-static boolean ieee_const_type PARAMS ((PTR));
-static boolean ieee_volatile_type PARAMS ((PTR));
-static boolean ieee_start_struct_type
- PARAMS ((PTR, const char *, unsigned int, boolean, unsigned int));
-static boolean ieee_struct_field
- PARAMS ((PTR, const char *, bfd_vma, bfd_vma, enum debug_visibility));
-static boolean ieee_end_struct_type PARAMS ((PTR));
-static boolean ieee_start_class_type
- PARAMS ((PTR, const char *, unsigned int, boolean, unsigned int, boolean,
- boolean));
-static boolean ieee_class_static_member
- PARAMS ((PTR, const char *, const char *, enum debug_visibility));
-static boolean ieee_class_baseclass
- PARAMS ((PTR, bfd_vma, boolean, enum debug_visibility));
-static boolean ieee_class_start_method PARAMS ((PTR, const char *));
-static boolean ieee_class_method_variant
- PARAMS ((PTR, const char *, enum debug_visibility, boolean, boolean,
- bfd_vma, boolean));
-static boolean ieee_class_static_method_variant
- PARAMS ((PTR, const char *, enum debug_visibility, boolean, boolean));
-static boolean ieee_class_end_method PARAMS ((PTR));
-static boolean ieee_end_class_type PARAMS ((PTR));
-static boolean ieee_typedef_type PARAMS ((PTR, const char *));
-static boolean ieee_tag_type
- PARAMS ((PTR, const char *, unsigned int, enum debug_type_kind));
-static boolean ieee_typdef PARAMS ((PTR, const char *));
-static boolean ieee_tag PARAMS ((PTR, const char *));
-static boolean ieee_int_constant PARAMS ((PTR, const char *, bfd_vma));
-static boolean ieee_float_constant PARAMS ((PTR, const char *, double));
-static boolean ieee_typed_constant PARAMS ((PTR, const char *, bfd_vma));
-static boolean ieee_variable
- PARAMS ((PTR, const char *, enum debug_var_kind, bfd_vma));
-static boolean ieee_start_function PARAMS ((PTR, const char *, boolean));
-static boolean ieee_function_parameter
- PARAMS ((PTR, const char *, enum debug_parm_kind, bfd_vma));
-static boolean ieee_start_block PARAMS ((PTR, bfd_vma));
-static boolean ieee_end_block PARAMS ((PTR, bfd_vma));
-static boolean ieee_end_function PARAMS ((PTR));
-static boolean ieee_lineno
- PARAMS ((PTR, const char *, unsigned long, bfd_vma));
+ (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
+static bfd_boolean ieee_write_undefined_tag
+ (struct ieee_name_type_hash_entry *, void *);
+static bfd_boolean ieee_finish_compilation_unit (struct ieee_handle *);
+static void ieee_add_bb11_blocks (bfd *, asection *, void *);
+static bfd_boolean ieee_add_bb11
+ (struct ieee_handle *, asection *, bfd_vma, bfd_vma);
+static bfd_boolean ieee_output_pending_parms (struct ieee_handle *);
+static unsigned int ieee_vis_to_flags (enum debug_visibility);
+static bfd_boolean ieee_class_method_var
+ (struct ieee_handle *, const char *, enum debug_visibility, bfd_boolean,
+ bfd_boolean, bfd_boolean, bfd_vma, bfd_boolean);
+
+static bfd_boolean ieee_start_compilation_unit (void *, const char *);
+static bfd_boolean ieee_start_source (void *, const char *);
+static bfd_boolean ieee_empty_type (void *);
+static bfd_boolean ieee_void_type (void *);
+static bfd_boolean ieee_int_type (void *, unsigned int, bfd_boolean);
+static bfd_boolean ieee_float_type (void *, unsigned int);
+static bfd_boolean ieee_complex_type (void *, unsigned int);
+static bfd_boolean ieee_bool_type (void *, unsigned int);
+static bfd_boolean ieee_enum_type
+ (void *, const char *, const char **, bfd_signed_vma *);
+static bfd_boolean ieee_pointer_type (void *);
+static bfd_boolean ieee_function_type (void *, int, bfd_boolean);
+static bfd_boolean ieee_reference_type (void *);
+static bfd_boolean ieee_range_type (void *, bfd_signed_vma, bfd_signed_vma);
+static bfd_boolean ieee_array_type
+ (void *, bfd_signed_vma, bfd_signed_vma, bfd_boolean);
+static bfd_boolean ieee_set_type (void *, bfd_boolean);
+static bfd_boolean ieee_offset_type (void *);
+static bfd_boolean ieee_method_type (void *, bfd_boolean, int, bfd_boolean);
+static bfd_boolean ieee_const_type (void *);
+static bfd_boolean ieee_volatile_type (void *);
+static bfd_boolean ieee_start_struct_type
+ (void *, const char *, unsigned int, bfd_boolean, unsigned int);
+static bfd_boolean ieee_struct_field
+ (void *, const char *, bfd_vma, bfd_vma, enum debug_visibility);
+static bfd_boolean ieee_end_struct_type (void *);
+static bfd_boolean ieee_start_class_type
+ (void *, const char *, unsigned int, bfd_boolean, unsigned int, bfd_boolean,
+ bfd_boolean);
+static bfd_boolean ieee_class_static_member
+ (void *, const char *, const char *, enum debug_visibility);
+static bfd_boolean ieee_class_baseclass
+ (void *, bfd_vma, bfd_boolean, enum debug_visibility);
+static bfd_boolean ieee_class_start_method (void *, const char *);
+static bfd_boolean ieee_class_method_variant
+ (void *, const char *, enum debug_visibility, bfd_boolean, bfd_boolean,
+ bfd_vma, bfd_boolean);
+static bfd_boolean ieee_class_static_method_variant
+ (void *, const char *, enum debug_visibility, bfd_boolean, bfd_boolean);
+static bfd_boolean ieee_class_end_method (void *);
+static bfd_boolean ieee_end_class_type (void *);
+static bfd_boolean ieee_typedef_type (void *, const char *);
+static bfd_boolean ieee_tag_type
+ (void *, const char *, unsigned int, enum debug_type_kind);
+static bfd_boolean ieee_typdef (void *, const char *);
+static bfd_boolean ieee_tag (void *, const char *);
+static bfd_boolean ieee_int_constant (void *, const char *, bfd_vma);
+static bfd_boolean ieee_float_constant (void *, const char *, double);
+static bfd_boolean ieee_typed_constant (void *, const char *, bfd_vma);
+static bfd_boolean ieee_variable
+ (void *, const char *, enum debug_var_kind, bfd_vma);
+static bfd_boolean ieee_start_function (void *, const char *, bfd_boolean);
+static bfd_boolean ieee_function_parameter
+ (void *, const char *, enum debug_parm_kind, bfd_vma);
+static bfd_boolean ieee_start_block (void *, bfd_vma);
+static bfd_boolean ieee_end_block (void *, bfd_vma);
+static bfd_boolean ieee_end_function (void *);
+static bfd_boolean ieee_lineno (void *, const char *, unsigned long, bfd_vma);
static const struct debug_write_fns ieee_fns =
{
@@ -4102,14 +4037,13 @@ static const struct debug_write_fns ieee_fns =
/* Initialize a buffer to be empty. */
-static boolean
-ieee_init_buffer (info, buflist)
- struct ieee_handle *info ATTRIBUTE_UNUSED;
- struct ieee_buflist *buflist;
+static bfd_boolean
+ieee_init_buffer (struct ieee_handle *info ATTRIBUTE_UNUSED,
+ struct ieee_buflist *buflist)
{
buflist->head = NULL;
buflist->tail = NULL;
- return true;
+ return TRUE;
}
/* See whether a buffer list has any data. */
@@ -4118,10 +4052,8 @@ ieee_init_buffer (info, buflist)
/* Change the current buffer to a specified buffer chain. */
-static boolean
-ieee_change_buffer (info, buflist)
- struct ieee_handle *info;
- struct ieee_buflist *buflist;
+static bfd_boolean
+ieee_change_buffer (struct ieee_handle *info, struct ieee_buflist *buflist)
{
if (buflist->head == NULL)
{
@@ -4137,16 +4069,15 @@ ieee_change_buffer (info, buflist)
info->current = buflist;
info->curbuf = buflist->tail;
- return true;
+ return TRUE;
}
/* Append a buffer chain. */
-static boolean
-ieee_append_buffer (info, mainbuf, newbuf)
- struct ieee_handle *info ATTRIBUTE_UNUSED;
- struct ieee_buflist *mainbuf;
- struct ieee_buflist *newbuf;
+static bfd_boolean
+ieee_append_buffer (struct ieee_handle *info ATTRIBUTE_UNUSED,
+ struct ieee_buflist *mainbuf,
+ struct ieee_buflist *newbuf)
{
if (newbuf->head != NULL)
{
@@ -4156,7 +4087,7 @@ ieee_append_buffer (info, mainbuf, newbuf)
mainbuf->tail->next = newbuf->head;
mainbuf->tail = newbuf->tail;
}
- return true;
+ return TRUE;
}
/* Write a byte into the buffer. We use a macro for speed and a
@@ -4164,13 +4095,11 @@ ieee_append_buffer (info, mainbuf, newbuf)
#define ieee_write_byte(info, b) \
((info)->curbuf->c < IEEE_BUFSIZE \
- ? ((info)->curbuf->buf[(info)->curbuf->c++] = (b), true) \
+ ? ((info)->curbuf->buf[(info)->curbuf->c++] = (b), TRUE) \
: ieee_real_write_byte ((info), (b)))
-static boolean
-ieee_real_write_byte (info, b)
- struct ieee_handle *info;
- int b;
+static bfd_boolean
+ieee_real_write_byte (struct ieee_handle *info, int b)
{
if (info->curbuf->c >= IEEE_BUFSIZE)
{
@@ -4190,15 +4119,13 @@ ieee_real_write_byte (info, b)
info->curbuf->buf[info->curbuf->c] = b;
++info->curbuf->c;
- return true;
+ return TRUE;
}
/* Write out two bytes. */
-static boolean
-ieee_write_2bytes (info, i)
- struct ieee_handle *info;
- int i;
+static bfd_boolean
+ieee_write_2bytes (struct ieee_handle *info, int i)
{
return (ieee_write_byte (info, i >> 8)
&& ieee_write_byte (info, i & 0xff));
@@ -4206,10 +4133,8 @@ ieee_write_2bytes (info, i)
/* Write out an integer. */
-static boolean
-ieee_write_number (info, v)
- struct ieee_handle *info;
- bfd_vma v;
+static bfd_boolean
+ieee_write_number (struct ieee_handle *info, bfd_vma v)
{
bfd_vma t;
bfd_byte ab[20];
@@ -4234,26 +4159,24 @@ ieee_write_number (info, v)
fprintf (stderr, _("IEEE numeric overflow: 0x"));
fprintf_vma (stderr, v);
fprintf (stderr, "\n");
- return false;
+ return FALSE;
}
if (! ieee_write_byte (info, (int) ieee_number_repeat_start_enum + c))
- return false;
+ return FALSE;
for (; c > 0; --c, ++p)
{
if (! ieee_write_byte (info, *p))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Write out a string. */
-static boolean
-ieee_write_id (info, s)
- struct ieee_handle *info;
- const char *s;
+static bfd_boolean
+ieee_write_id (struct ieee_handle *info, const char *s)
{
unsigned int len;
@@ -4261,40 +4184,37 @@ ieee_write_id (info, s)
if (len <= 0x7f)
{
if (! ieee_write_byte (info, len))
- return false;
+ return FALSE;
}
else if (len <= 0xff)
{
if (! ieee_write_byte (info, (int) ieee_extension_length_1_enum)
|| ! ieee_write_byte (info, len))
- return false;
+ return FALSE;
}
else if (len <= 0xffff)
{
if (! ieee_write_byte (info, (int) ieee_extension_length_2_enum)
|| ! ieee_write_2bytes (info, len))
- return false;
+ return FALSE;
}
else
{
fprintf (stderr, _("IEEE string length overflow: %u\n"), len);
- return false;
+ return FALSE;
}
for (; *s != '\0'; s++)
if (! ieee_write_byte (info, *s))
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
/* Write out an ASN record. */
-static boolean
-ieee_write_asn (info, indx, val)
- struct ieee_handle *info;
- unsigned int indx;
- bfd_vma val;
+static bfd_boolean
+ieee_write_asn (struct ieee_handle *info, unsigned int indx, bfd_vma val)
{
return (ieee_write_2bytes (info, (int) ieee_asn_record_enum)
&& ieee_write_number (info, indx)
@@ -4303,11 +4223,8 @@ ieee_write_asn (info, indx, val)
/* Write out an ATN65 record. */
-static boolean
-ieee_write_atn65 (info, indx, s)
- struct ieee_handle *info;
- unsigned int indx;
- const char *s;
+static bfd_boolean
+ieee_write_atn65 (struct ieee_handle *info, unsigned int indx, const char *s)
{
return (ieee_write_2bytes (info, (int) ieee_atn_record_enum)
&& ieee_write_number (info, indx)
@@ -4318,13 +4235,9 @@ ieee_write_atn65 (info, indx, s)
/* Push a type index onto the type stack. */
-static boolean
-ieee_push_type (info, indx, size, unsignedp, localp)
- struct ieee_handle *info;
- unsigned int indx;
- unsigned int size;
- boolean unsignedp;
- boolean localp;
+static bfd_boolean
+ieee_push_type (struct ieee_handle *info, unsigned int indx,
+ unsigned int size, bfd_boolean unsignedp, bfd_boolean localp)
{
struct ieee_type_stack *ts;
@@ -4339,33 +4252,29 @@ ieee_push_type (info, indx, size, unsignedp, localp)
ts->next = info->type_stack;
info->type_stack = ts;
- return true;
+ return TRUE;
}
/* Pop a type index off the type stack. */
static unsigned int
-ieee_pop_type (info)
- struct ieee_handle *info;
+ieee_pop_type (struct ieee_handle *info)
{
- return ieee_pop_type_used (info, true);
+ return ieee_pop_type_used (info, TRUE);
}
/* Pop an unused type index off the type stack. */
static void
-ieee_pop_unused_type (info)
- struct ieee_handle *info;
+ieee_pop_unused_type (struct ieee_handle *info)
{
- (void) ieee_pop_type_used (info, false);
+ (void) ieee_pop_type_used (info, FALSE);
}
/* Pop a used or unused type index off the type stack. */
static unsigned int
-ieee_pop_type_used (info, used)
- struct ieee_handle *info;
- boolean used;
+ieee_pop_type_used (struct ieee_handle *info, bfd_boolean used)
{
struct ieee_type_stack *ts;
unsigned int ret;
@@ -4389,7 +4298,7 @@ ieee_pop_type_used (info, used)
|| ! ieee_write_byte (info, 1)
|| ! ieee_write_number (info, 0)
|| ! ieee_write_id (info, info->modname))
- return false;
+ return FALSE;
}
buflist = &info->types;
}
@@ -4403,13 +4312,13 @@ ieee_pop_type_used (info, used)
|| ! ieee_write_byte (info, 2)
|| ! ieee_write_number (info, 0)
|| ! ieee_write_id (info, ""))
- return false;
+ return FALSE;
}
buflist = &info->global_types;
}
if (! ieee_append_buffer (info, buflist, &ts->type.fndef))
- return false;
+ return FALSE;
}
ret = ts->type.indx;
@@ -4420,17 +4329,14 @@ ieee_pop_type_used (info, used)
/* Add a range of bytes included in the current compilation unit. */
-static boolean
-ieee_add_range (info, global, low, high)
- struct ieee_handle *info;
- boolean global;
- bfd_vma low;
- bfd_vma high;
+static bfd_boolean
+ieee_add_range (struct ieee_handle *info, bfd_boolean global, bfd_vma low,
+ bfd_vma high)
{
struct ieee_range **plist, *r, **pr;
if (low == (bfd_vma) -1 || high == (bfd_vma) -1 || low == high)
- return true;
+ return TRUE;
if (global)
plist = &info->global_ranges;
@@ -4457,7 +4363,7 @@ ieee_add_range (info, global, low, high)
free (*pr);
*pr = n;
}
- return true;
+ return TRUE;
}
}
@@ -4474,15 +4380,13 @@ ieee_add_range (info, global, low, high)
r->next = *pr;
*pr = r;
- return true;
+ return TRUE;
}
/* Start a new range for which we only have the low address. */
-static boolean
-ieee_start_range (info, low)
- struct ieee_handle *info;
- bfd_vma low;
+static bfd_boolean
+ieee_start_range (struct ieee_handle *info, bfd_vma low)
{
struct ieee_range *r;
@@ -4491,15 +4395,13 @@ ieee_start_range (info, low)
r->low = low;
r->next = info->pending_ranges;
info->pending_ranges = r;
- return true;
+ return TRUE;
}
/* Finish a range started by ieee_start_range. */
-static boolean
-ieee_end_range (info, high)
- struct ieee_handle *info;
- bfd_vma high;
+static bfd_boolean
+ieee_end_range (struct ieee_handle *info, bfd_vma high)
{
struct ieee_range *r;
bfd_vma low;
@@ -4509,17 +4411,14 @@ ieee_end_range (info, high)
low = r->low;
info->pending_ranges = r->next;
free (r);
- return ieee_add_range (info, false, low, high);
+ return ieee_add_range (info, FALSE, low, high);
}
/* Start defining a type. */
-static boolean
-ieee_define_type (info, size, unsignedp, localp)
- struct ieee_handle *info;
- unsigned int size;
- boolean unsignedp;
- boolean localp;
+static bfd_boolean
+ieee_define_type (struct ieee_handle *info, unsigned int size,
+ bfd_boolean unsignedp, bfd_boolean localp)
{
return ieee_define_named_type (info, (const char *) NULL,
(unsigned int) -1, size, unsignedp,
@@ -4528,15 +4427,11 @@ ieee_define_type (info, size, unsignedp, localp)
/* Start defining a named type. */
-static boolean
-ieee_define_named_type (info, name, indx, size, unsignedp, localp, buflist)
- struct ieee_handle *info;
- const char *name;
- unsigned int indx;
- unsigned int size;
- boolean unsignedp;
- boolean localp;
- struct ieee_buflist *buflist;
+static bfd_boolean
+ieee_define_named_type (struct ieee_handle *info, const char *name,
+ unsigned int indx, unsigned int size,
+ bfd_boolean unsignedp, bfd_boolean localp,
+ struct ieee_buflist *buflist)
{
unsigned int type_indx;
unsigned int name_indx;
@@ -4561,14 +4456,14 @@ ieee_define_named_type (info, name, indx, size, unsignedp, localp, buflist)
if (buflist != NULL)
{
if (! ieee_change_buffer (info, buflist))
- return false;
+ return FALSE;
}
else if (localp)
{
if (! ieee_buffer_emptyp (&info->types))
{
if (! ieee_change_buffer (info, &info->types))
- return false;
+ return FALSE;
}
else
{
@@ -4577,7 +4472,7 @@ ieee_define_named_type (info, name, indx, size, unsignedp, localp, buflist)
|| ! ieee_write_byte (info, 1)
|| ! ieee_write_number (info, 0)
|| ! ieee_write_id (info, info->modname))
- return false;
+ return FALSE;
}
}
else
@@ -4585,7 +4480,7 @@ ieee_define_named_type (info, name, indx, size, unsignedp, localp, buflist)
if (! ieee_buffer_emptyp (&info->global_types))
{
if (! ieee_change_buffer (info, &info->global_types))
- return false;
+ return FALSE;
}
else
{
@@ -4594,7 +4489,7 @@ ieee_define_named_type (info, name, indx, size, unsignedp, localp, buflist)
|| ! ieee_write_byte (info, 2)
|| ! ieee_write_number (info, 0)
|| ! ieee_write_id (info, ""))
- return false;
+ return FALSE;
}
}
@@ -4602,7 +4497,7 @@ ieee_define_named_type (info, name, indx, size, unsignedp, localp, buflist)
write out the start of a TY record. The caller will then finish
the TY record. */
if (! ieee_push_type (info, type_indx, size, unsignedp, localp))
- return false;
+ return FALSE;
return (ieee_write_byte (info, (int) ieee_nn_record)
&& ieee_write_number (info, name_indx)
@@ -4616,9 +4511,7 @@ ieee_define_named_type (info, name, indx, size, unsignedp, localp, buflist)
/* Get an entry to the list of modified versions of a type. */
static struct ieee_modified_type *
-ieee_get_modified_info (info, indx)
- struct ieee_handle *info;
- unsigned int indx;
+ieee_get_modified_info (struct ieee_handle *info, unsigned int indx)
{
if (indx >= info->modified_alloc)
{
@@ -4645,10 +4538,8 @@ ieee_get_modified_info (info, indx)
/* Initialize an entry in the hash table. */
static struct bfd_hash_entry *
-ieee_name_type_newfunc (entry, table, string)
- struct bfd_hash_entry *entry;
- struct bfd_hash_table *table;
- const char *string;
+ieee_name_type_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table, const char *string)
{
struct ieee_name_type_hash_entry *ret =
(struct ieee_name_type_hash_entry *) entry;
@@ -4684,15 +4575,13 @@ ieee_name_type_newfunc (entry, table, string)
#define ieee_name_type_hash_traverse(table, func, info) \
(bfd_hash_traverse \
(&(table)->root, \
- (boolean (*) PARAMS ((struct bfd_hash_entry *, PTR))) (func), \
+ (bfd_boolean (*) (struct bfd_hash_entry *, void *)) (func), \
(info)))
/* The general routine to write out IEEE debugging information. */
-boolean
-write_ieee_debugging_info (abfd, dhandle)
- bfd *abfd;
- PTR dhandle;
+bfd_boolean
+write_ieee_debugging_info (bfd *abfd, void *dhandle)
{
struct ieee_handle info;
asection *s;
@@ -4706,7 +4595,7 @@ write_ieee_debugging_info (abfd, dhandle)
if (! bfd_hash_table_init (&info.typedefs.root, ieee_name_type_newfunc)
|| ! bfd_hash_table_init (&info.tags.root, ieee_name_type_newfunc))
- return false;
+ return FALSE;
if (! ieee_init_buffer (&info, &info.global_types)
|| ! ieee_init_buffer (&info, &info.data)
@@ -4716,24 +4605,24 @@ write_ieee_debugging_info (abfd, dhandle)
|| ! ieee_init_buffer (&info, &info.linenos)
|| ! ieee_init_buffer (&info, &info.fntype)
|| ! ieee_init_buffer (&info, &info.fnargs))
- return false;
+ return FALSE;
- if (! debug_write (dhandle, &ieee_fns, (PTR) &info))
- return false;
+ if (! debug_write (dhandle, &ieee_fns, (void *) &info))
+ return FALSE;
if (info.filename != NULL)
{
if (! ieee_finish_compilation_unit (&info))
- return false;
+ return FALSE;
}
/* Put any undefined tags in the global typedef information. */
- info.error = false;
+ info.error = FALSE;
ieee_name_type_hash_traverse (&info.tags,
ieee_write_undefined_tag,
- (PTR) &info);
+ (void *) &info);
if (info.error)
- return false;
+ return FALSE;
/* Prepend the global typedef information to the other data. */
if (! ieee_buffer_emptyp (&info.global_types))
@@ -4751,29 +4640,29 @@ write_ieee_debugging_info (abfd, dhandle)
|| ! ieee_write_number (&info, 'P')
|| ! ieee_write_number (&info, (int) builtin_void + 32)
|| ! ieee_write_byte (&info, (int) ieee_be_record_enum))
- return false;
+ return FALSE;
if (! ieee_append_buffer (&info, &info.global_types, &info.data))
- return false;
+ return FALSE;
info.data = info.global_types;
}
/* Make sure that we have declare BB11 blocks for each range in the
file. They are added to info->vars. */
- info.error = false;
+ info.error = FALSE;
if (! ieee_init_buffer (&info, &info.vars))
- return false;
- bfd_map_over_sections (abfd, ieee_add_bb11_blocks, (PTR) &info);
+ return FALSE;
+ bfd_map_over_sections (abfd, ieee_add_bb11_blocks, (void *) &info);
if (info.error)
- return false;
+ return FALSE;
if (! ieee_buffer_emptyp (&info.vars))
{
if (! ieee_change_buffer (&info, &info.vars)
|| ! ieee_write_byte (&info, (int) ieee_be_record_enum))
- return false;
+ return FALSE;
if (! ieee_append_buffer (&info, &info.data, &info.vars))
- return false;
+ return FALSE;
}
/* Now all the data is in info.data. Write it out to the BFD. We
@@ -4783,7 +4672,7 @@ write_ieee_debugging_info (abfd, dhandle)
if (ieee_buffer_emptyp (&info.data))
{
/* There is no debugging information. */
- return true;
+ return TRUE;
}
err = NULL;
s = bfd_make_section (abfd, ".debug");
@@ -4824,22 +4713,20 @@ write_ieee_debugging_info (abfd, dhandle)
{
fprintf (stderr, "%s: %s: %s\n", bfd_get_filename (abfd), err,
bfd_errmsg (bfd_get_error ()));
- return false;
+ return FALSE;
}
bfd_hash_table_free (&info.typedefs.root);
bfd_hash_table_free (&info.tags.root);
- return true;
+ return TRUE;
}
/* Write out information for an undefined tag. This is called via
ieee_name_type_hash_traverse. */
-static boolean
-ieee_write_undefined_tag (h, p)
- struct ieee_name_type_hash_entry *h;
- PTR p;
+static bfd_boolean
+ieee_write_undefined_tag (struct ieee_name_type_hash_entry *h, void *p)
{
struct ieee_handle *info = (struct ieee_handle *) p;
struct ieee_name_type *nt;
@@ -4860,16 +4747,16 @@ ieee_write_undefined_tag (h, p)
|| ! ieee_write_number (info, 0)
|| ! ieee_write_id (info, ""))
{
- info->error = true;
- return false;
+ info->error = TRUE;
+ return FALSE;
}
}
else
{
if (! ieee_change_buffer (info, &info->global_types))
{
- info->error = true;
- return false;
+ info->error = TRUE;
+ return FALSE;
}
}
@@ -4883,16 +4770,16 @@ ieee_write_undefined_tag (h, p)
|| ! ieee_write_byte (info, 0xce)
|| ! ieee_write_number (info, name_indx))
{
- info->error = true;
- return false;
+ info->error = TRUE;
+ return FALSE;
}
switch (nt->kind)
{
default:
abort ();
- info->error = true;
- return false;
+ info->error = TRUE;
+ return FALSE;
case DEBUG_KIND_STRUCT:
case DEBUG_KIND_CLASS:
code = 'S';
@@ -4908,20 +4795,18 @@ ieee_write_undefined_tag (h, p)
if (! ieee_write_number (info, code)
|| ! ieee_write_number (info, 0))
{
- info->error = true;
- return false;
+ info->error = TRUE;
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
/* Start writing out information for a compilation unit. */
-static boolean
-ieee_start_compilation_unit (p, filename)
- PTR p;
- const char *filename;
+static bfd_boolean
+ieee_start_compilation_unit (void *p, const char *filename)
{
struct ieee_handle *info = (struct ieee_handle *) p;
const char *modname;
@@ -4934,7 +4819,7 @@ ieee_start_compilation_unit (p, filename)
if (info->filename != NULL)
{
if (! ieee_finish_compilation_unit (info))
- return false;
+ return FALSE;
}
info->filename = filename;
@@ -4965,7 +4850,7 @@ ieee_start_compilation_unit (p, filename)
|| ! ieee_init_buffer (info, &info->vars)
|| ! ieee_init_buffer (info, &info->cxx)
|| ! ieee_init_buffer (info, &info->linenos))
- return false;
+ return FALSE;
info->ranges = NULL;
/* Always include a BB1 and a BB3 block. That is what the output of
@@ -4975,7 +4860,7 @@ ieee_start_compilation_unit (p, filename)
|| ! ieee_write_byte (info, 1)
|| ! ieee_write_number (info, 0)
|| ! ieee_write_id (info, info->modname))
- return false;
+ return FALSE;
nindx = info->name_indx;
++info->name_indx;
@@ -4984,16 +4869,15 @@ ieee_start_compilation_unit (p, filename)
|| ! ieee_write_byte (info, 3)
|| ! ieee_write_number (info, 0)
|| ! ieee_write_id (info, info->modname))
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
/* Finish up a compilation unit. */
-static boolean
-ieee_finish_compilation_unit (info)
- struct ieee_handle *info;
+static bfd_boolean
+ieee_finish_compilation_unit (struct ieee_handle *info)
{
struct ieee_range *r;
@@ -5001,7 +4885,7 @@ ieee_finish_compilation_unit (info)
{
if (! ieee_change_buffer (info, &info->types)
|| ! ieee_write_byte (info, (int) ieee_be_record_enum))
- return false;
+ return FALSE;
}
if (! ieee_buffer_emptyp (&info->cxx))
@@ -5010,7 +4894,7 @@ ieee_finish_compilation_unit (info)
variable information. */
assert (! ieee_buffer_emptyp (&info->vars));
if (! ieee_change_buffer (info, &info->vars))
- return false;
+ return FALSE;
/* We put the pmisc records in a dummy procedure, just as the
MRI compiler does. */
@@ -5025,45 +4909,45 @@ ieee_finish_compilation_unit (info)
|| ! ieee_change_buffer (info, &info->vars)
|| ! ieee_write_byte (info, (int) ieee_be_record_enum)
|| ! ieee_write_number (info, info->highaddr - 1))
- return false;
+ return FALSE;
}
if (! ieee_buffer_emptyp (&info->vars))
{
if (! ieee_change_buffer (info, &info->vars)
|| ! ieee_write_byte (info, (int) ieee_be_record_enum))
- return false;
+ return FALSE;
}
if (info->pending_lineno_filename != NULL)
{
/* Force out the pending line number. */
- if (! ieee_lineno ((PTR) info, (const char *) NULL, 0, (bfd_vma) -1))
- return false;
+ if (! ieee_lineno ((void *) info, (const char *) NULL, 0, (bfd_vma) -1))
+ return FALSE;
}
if (! ieee_buffer_emptyp (&info->linenos))
{
if (! ieee_change_buffer (info, &info->linenos)
|| ! ieee_write_byte (info, (int) ieee_be_record_enum))
- return false;
+ return FALSE;
if (strcmp (info->filename, info->lineno_filename) != 0)
{
/* We were not in the main file. We just closed the
included line number block, and now we must close the
main line number block. */
if (! ieee_write_byte (info, (int) ieee_be_record_enum))
- return false;
+ return FALSE;
}
}
if (! ieee_append_buffer (info, &info->data, &info->types)
|| ! ieee_append_buffer (info, &info->data, &info->vars)
|| ! ieee_append_buffer (info, &info->data, &info->linenos))
- return false;
+ return FALSE;
/* Build BB10/BB11 blocks based on the ranges we recorded. */
if (! ieee_change_buffer (info, &info->data))
- return false;
+ return FALSE;
if (! ieee_write_byte (info, (int) ieee_bb_record_enum)
|| ! ieee_write_byte (info, 10)
@@ -5072,7 +4956,7 @@ ieee_finish_compilation_unit (info)
|| ! ieee_write_id (info, "")
|| ! ieee_write_number (info, 0)
|| ! ieee_write_id (info, "GNU objcopy"))
- return false;
+ return FALSE;
for (r = info->ranges; r != NULL; r = r->next)
{
@@ -5125,27 +5009,24 @@ ieee_finish_compilation_unit (info)
|| ! ieee_write_number (info, low)
|| ! ieee_write_byte (info, (int) ieee_be_record_enum)
|| ! ieee_write_number (info, high - low))
- return false;
+ return FALSE;
/* Add this range to the list of global ranges. */
- if (! ieee_add_range (info, true, low, high))
- return false;
+ if (! ieee_add_range (info, TRUE, low, high))
+ return FALSE;
}
if (! ieee_write_byte (info, (int) ieee_be_record_enum))
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
/* Add BB11 blocks describing each range that we have not already
described. */
static void
-ieee_add_bb11_blocks (abfd, sec, data)
- bfd *abfd ATTRIBUTE_UNUSED;
- asection *sec;
- PTR data;
+ieee_add_bb11_blocks (bfd *abfd ATTRIBUTE_UNUSED, asection *sec, void *data)
{
struct ieee_handle *info = (struct ieee_handle *) data;
bfd_vma low, high;
@@ -5165,7 +5046,7 @@ ieee_add_bb11_blocks (abfd, sec, data)
if (r == NULL || r->low >= high)
{
if (! ieee_add_bb11 (info, sec, low, high))
- info->error = true;
+ info->error = TRUE;
return;
}
@@ -5174,7 +5055,7 @@ ieee_add_bb11_blocks (abfd, sec, data)
{
if (! ieee_add_bb11 (info, sec, low, r->low))
{
- info->error = true;
+ info->error = TRUE;
return;
}
}
@@ -5186,19 +5067,16 @@ ieee_add_bb11_blocks (abfd, sec, data)
/* Add a single BB11 block for a range. We add it to info->vars. */
-static boolean
-ieee_add_bb11 (info, sec, low, high)
- struct ieee_handle *info;
- asection *sec;
- bfd_vma low;
- bfd_vma high;
+static bfd_boolean
+ieee_add_bb11 (struct ieee_handle *info, asection *sec, bfd_vma low,
+ bfd_vma high)
{
int kind;
if (! ieee_buffer_emptyp (&info->vars))
{
if (! ieee_change_buffer (info, &info->vars))
- return false;
+ return FALSE;
}
else
{
@@ -5239,7 +5117,7 @@ ieee_add_bb11 (info, sec, low, high)
|| ! ieee_write_id (info, "")
|| ! ieee_write_number (info, 0)
|| ! ieee_write_id (info, "GNU objcopy"))
- return false;
+ return FALSE;
free (c);
}
@@ -5260,9 +5138,9 @@ ieee_add_bb11 (info, sec, low, high)
|| ! ieee_write_number (info, low)
|| ! ieee_write_byte (info, (int) ieee_be_record_enum)
|| ! ieee_write_number (info, high - low))
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
/* Start recording information from a particular source file. This is
@@ -5271,43 +5149,37 @@ ieee_add_bb11 (info, sec, low, high)
down the file name anyhow. IEEE debugging information doesn't seem
to store this information anywhere. */
-static boolean
-ieee_start_source (p, filename)
- PTR p ATTRIBUTE_UNUSED;
- const char *filename ATTRIBUTE_UNUSED;
+static bfd_boolean
+ieee_start_source (void *p ATTRIBUTE_UNUSED,
+ const char *filename ATTRIBUTE_UNUSED)
{
- return true;
+ return TRUE;
}
/* Make an empty type. */
-static boolean
-ieee_empty_type (p)
- PTR p;
+static bfd_boolean
+ieee_empty_type (void *p)
{
struct ieee_handle *info = (struct ieee_handle *) p;
- return ieee_push_type (info, (int) builtin_unknown, 0, false, false);
+ return ieee_push_type (info, (int) builtin_unknown, 0, FALSE, FALSE);
}
/* Make a void type. */
-static boolean
-ieee_void_type (p)
- PTR p;
+static bfd_boolean
+ieee_void_type (void *p)
{
struct ieee_handle *info = (struct ieee_handle *) p;
- return ieee_push_type (info, (int) builtin_void, 0, false, false);
+ return ieee_push_type (info, (int) builtin_void, 0, FALSE, FALSE);
}
/* Make an integer type. */
-static boolean
-ieee_int_type (p, size, unsignedp)
- PTR p;
- unsigned int size;
- boolean unsignedp;
+static bfd_boolean
+ieee_int_type (void *p, unsigned int size, bfd_boolean unsignedp)
{
struct ieee_handle *info = (struct ieee_handle *) p;
unsigned int indx;
@@ -5328,21 +5200,19 @@ ieee_int_type (p, size, unsignedp)
break;
default:
fprintf (stderr, _("IEEE unsupported integer type size %u\n"), size);
- return false;
+ return FALSE;
}
if (unsignedp)
++indx;
- return ieee_push_type (info, indx, size, unsignedp, false);
+ return ieee_push_type (info, indx, size, unsignedp, FALSE);
}
/* Make a floating point type. */
-static boolean
-ieee_float_type (p, size)
- PTR p;
- unsigned int size;
+static bfd_boolean
+ieee_float_type (void *p, unsigned int size)
{
struct ieee_handle *info = (struct ieee_handle *) p;
unsigned int indx;
@@ -5364,18 +5234,16 @@ ieee_float_type (p, size)
break;
default:
fprintf (stderr, _("IEEE unsupported float type size %u\n"), size);
- return false;
+ return FALSE;
}
- return ieee_push_type (info, indx, size, false, false);
+ return ieee_push_type (info, indx, size, FALSE, FALSE);
}
/* Make a complex type. */
-static boolean
-ieee_complex_type (p, size)
- PTR p;
- unsigned int size;
+static bfd_boolean
+ieee_complex_type (void *p, unsigned int size)
{
struct ieee_handle *info = (struct ieee_handle *) p;
char code;
@@ -5385,7 +5253,7 @@ ieee_complex_type (p, size)
case 4:
if (info->complex_float_index != 0)
return ieee_push_type (info, info->complex_float_index, size * 2,
- false, false);
+ FALSE, FALSE);
code = 'c';
break;
case 12:
@@ -5395,55 +5263,50 @@ ieee_complex_type (p, size)
case 8:
if (info->complex_double_index != 0)
return ieee_push_type (info, info->complex_double_index, size * 2,
- false, false);
+ FALSE, FALSE);
code = 'd';
break;
default:
fprintf (stderr, _("IEEE unsupported complex type size %u\n"), size);
- return false;
+ return FALSE;
}
/* FIXME: I don't know what the string is for. */
- if (! ieee_define_type (info, size * 2, false, false)
+ if (! ieee_define_type (info, size * 2, FALSE, FALSE)
|| ! ieee_write_number (info, code)
|| ! ieee_write_id (info, ""))
- return false;
+ return FALSE;
if (size == 4)
info->complex_float_index = info->type_stack->type.indx;
else
info->complex_double_index = info->type_stack->type.indx;
- return true;
+ return TRUE;
}
/* Make a boolean type. IEEE doesn't support these, so we just make
an integer type instead. */
-static boolean
-ieee_bool_type (p, size)
- PTR p;
- unsigned int size;
+static bfd_boolean
+ieee_bool_type (void *p, unsigned int size)
{
- return ieee_int_type (p, size, true);
+ return ieee_int_type (p, size, TRUE);
}
/* Make an enumeration. */
-static boolean
-ieee_enum_type (p, tag, names, vals)
- PTR p;
- const char *tag;
- const char **names;
- bfd_signed_vma *vals;
+static bfd_boolean
+ieee_enum_type (void *p, const char *tag, const char **names,
+ bfd_signed_vma *vals)
{
struct ieee_handle *info = (struct ieee_handle *) p;
struct ieee_defined_enum *e;
- boolean localp, simple;
+ bfd_boolean localp, simple;
unsigned int indx;
int i = 0;
- localp = false;
+ localp = FALSE;
indx = (unsigned int) -1;
for (e = info->enums; e != NULL; e = e->next)
{
@@ -5485,14 +5348,14 @@ ieee_enum_type (p, tag, names, vals)
&& e->names[i] == NULL))
{
/* We've seen this enum before. */
- return ieee_push_type (info, e->indx, 0, true, false);
+ return ieee_push_type (info, e->indx, 0, TRUE, FALSE);
}
if (tag != NULL)
{
/* We've already seen an enum of the same name, so we must make
sure to output this one locally. */
- localp = true;
+ localp = TRUE;
break;
}
}
@@ -5501,40 +5364,40 @@ ieee_enum_type (p, tag, names, vals)
and always increment by 1, we can use type E. Otherwise we must
use type N. */
- simple = true;
+ simple = TRUE;
if (names != NULL)
{
for (i = 0; names[i] != NULL; i++)
{
if (vals[i] != i)
{
- simple = false;
+ simple = FALSE;
break;
}
}
}
- if (! ieee_define_named_type (info, tag, indx, 0, true, localp,
+ if (! ieee_define_named_type (info, tag, indx, 0, TRUE, localp,
(struct ieee_buflist *) NULL)
|| ! ieee_write_number (info, simple ? 'E' : 'N'))
- return false;
+ return FALSE;
if (simple)
{
/* FIXME: This is supposed to be the enumeration size, but we
don't store that. */
if (! ieee_write_number (info, 4))
- return false;
+ return FALSE;
}
if (names != NULL)
{
for (i = 0; names[i] != NULL; i++)
{
if (! ieee_write_id (info, names[i]))
- return false;
+ return FALSE;
if (! simple)
{
if (! ieee_write_number (info, vals[i]))
- return false;
+ return FALSE;
}
}
}
@@ -5554,20 +5417,19 @@ ieee_enum_type (p, tag, names, vals)
e->names = names;
e->vals = vals;
- e->defined = true;
+ e->defined = TRUE;
}
- return true;
+ return TRUE;
}
/* Make a pointer type. */
-static boolean
-ieee_pointer_type (p)
- PTR p;
+static bfd_boolean
+ieee_pointer_type (void *p)
{
struct ieee_handle *info = (struct ieee_handle *) p;
- boolean localp;
+ bfd_boolean localp;
unsigned int indx;
struct ieee_modified_type *m = NULL;
@@ -5577,28 +5439,28 @@ ieee_pointer_type (p)
/* A pointer to a simple builtin type can be obtained by adding 32.
FIXME: Will this be a short pointer, and will that matter? */
if (indx < 32)
- return ieee_push_type (info, indx + 32, 0, true, false);
+ return ieee_push_type (info, indx + 32, 0, TRUE, FALSE);
if (! localp)
{
m = ieee_get_modified_info (p, indx);
if (m == NULL)
- return false;
+ return FALSE;
/* FIXME: The size should depend upon the architecture. */
if (m->pointer > 0)
- return ieee_push_type (info, m->pointer, 4, true, false);
+ return ieee_push_type (info, m->pointer, 4, TRUE, FALSE);
}
- if (! ieee_define_type (info, 4, true, localp)
+ if (! ieee_define_type (info, 4, TRUE, localp)
|| ! ieee_write_number (info, 'P')
|| ! ieee_write_number (info, indx))
- return false;
+ return FALSE;
if (! localp)
m->pointer = info->type_stack->type.indx;
- return true;
+ return TRUE;
}
/* Make a function type. This will be called for a method, but we
@@ -5606,21 +5468,18 @@ ieee_pointer_type (p)
handle this by defining the type in a private buffer, and only
adding that buffer to the typedef block if we are going to use it. */
-static boolean
-ieee_function_type (p, argcount, varargs)
- PTR p;
- int argcount;
- boolean varargs;
+static bfd_boolean
+ieee_function_type (void *p, int argcount, bfd_boolean varargs)
{
struct ieee_handle *info = (struct ieee_handle *) p;
- boolean localp;
+ bfd_boolean localp;
unsigned int *args = NULL;
int i;
unsigned int retindx;
struct ieee_buflist fndef;
struct ieee_modified_type *m;
- localp = false;
+ localp = FALSE;
if (argcount > 0)
{
@@ -5628,15 +5487,15 @@ ieee_function_type (p, argcount, varargs)
for (i = argcount - 1; i >= 0; i--)
{
if (info->type_stack->type.localp)
- localp = true;
+ localp = TRUE;
args[i] = ieee_pop_type (info);
}
}
else if (argcount < 0)
- varargs = false;
+ varargs = FALSE;
if (info->type_stack->type.localp)
- localp = true;
+ localp = TRUE;
retindx = ieee_pop_type (info);
m = NULL;
@@ -5644,17 +5503,17 @@ ieee_function_type (p, argcount, varargs)
{
m = ieee_get_modified_info (p, retindx);
if (m == NULL)
- return false;
+ return FALSE;
if (m->function > 0)
- return ieee_push_type (info, m->function, 0, true, false);
+ return ieee_push_type (info, m->function, 0, TRUE, FALSE);
}
/* An attribute of 0x41 means that the frame and push mask are
unknown. */
if (! ieee_init_buffer (info, &fndef)
|| ! ieee_define_named_type (info, (const char *) NULL,
- (unsigned int) -1, 0, true, localp,
+ (unsigned int) -1, 0, TRUE, localp,
&fndef)
|| ! ieee_write_number (info, 'x')
|| ! ieee_write_number (info, 0x41)
@@ -5662,12 +5521,12 @@ ieee_function_type (p, argcount, varargs)
|| ! ieee_write_number (info, 0)
|| ! ieee_write_number (info, retindx)
|| ! ieee_write_number (info, (bfd_vma) argcount + (varargs ? 1 : 0)))
- return false;
+ return FALSE;
if (argcount > 0)
{
for (i = 0; i < argcount; i++)
if (! ieee_write_number (info, args[i]))
- return false;
+ return FALSE;
free (args);
}
if (varargs)
@@ -5675,11 +5534,11 @@ ieee_function_type (p, argcount, varargs)
/* A varargs function is represented by writing out the last
argument as type void *, although this makes little sense. */
if (! ieee_write_number (info, (bfd_vma) builtin_void + 32))
- return false;
+ return FALSE;
}
if (! ieee_write_number (info, 0))
- return false;
+ return FALSE;
/* We wrote the information into fndef, in case we don't need it.
It will be appended to info->types by ieee_pop_type. */
@@ -5688,14 +5547,13 @@ ieee_function_type (p, argcount, varargs)
if (m != NULL)
m->function = info->type_stack->type.indx;
- return true;
+ return TRUE;
}
/* Make a reference type. */
-static boolean
-ieee_reference_type (p)
- PTR p;
+static bfd_boolean
+ieee_reference_type (void *p)
{
struct ieee_handle *info = (struct ieee_handle *) p;
@@ -5703,22 +5561,19 @@ ieee_reference_type (p)
pmisc record to indicate that it is really a reference. */
if (! ieee_pointer_type (p))
- return false;
- info->type_stack->type.referencep = true;
- return true;
+ return FALSE;
+ info->type_stack->type.referencep = TRUE;
+ return TRUE;
}
/* Make a range type. */
-static boolean
-ieee_range_type (p, low, high)
- PTR p;
- bfd_signed_vma low;
- bfd_signed_vma high;
+static bfd_boolean
+ieee_range_type (void *p, bfd_signed_vma low, bfd_signed_vma high)
{
struct ieee_handle *info = (struct ieee_handle *) p;
unsigned int size;
- boolean unsignedp, localp;
+ bfd_boolean unsignedp, localp;
size = info->type_stack->type.size;
unsignedp = info->type_stack->type.unsignedp;
@@ -5734,16 +5589,13 @@ ieee_range_type (p, low, high)
/* Make an array type. */
-static boolean
-ieee_array_type (p, low, high, stringp)
- PTR p;
- bfd_signed_vma low;
- bfd_signed_vma high;
- boolean stringp ATTRIBUTE_UNUSED;
+static bfd_boolean
+ieee_array_type (void *p, bfd_signed_vma low, bfd_signed_vma high,
+ bfd_boolean stringp ATTRIBUTE_UNUSED)
{
struct ieee_handle *info = (struct ieee_handle *) p;
unsigned int eleindx;
- boolean localp;
+ bfd_boolean localp;
unsigned int size;
struct ieee_modified_type *m = NULL;
struct ieee_modified_array_type *a;
@@ -5763,27 +5615,27 @@ ieee_array_type (p, low, high, stringp)
{
m = ieee_get_modified_info (info, eleindx);
if (m == NULL)
- return false;
+ return FALSE;
for (a = m->arrays; a != NULL; a = a->next)
{
if (a->low == low && a->high == high)
- return ieee_push_type (info, a->indx, size, false, false);
+ return ieee_push_type (info, a->indx, size, FALSE, FALSE);
}
}
- if (! ieee_define_type (info, size, false, localp)
+ if (! ieee_define_type (info, size, FALSE, localp)
|| ! ieee_write_number (info, low == 0 ? 'Z' : 'C')
|| ! ieee_write_number (info, eleindx))
- return false;
+ return FALSE;
if (low != 0)
{
if (! ieee_write_number (info, low))
- return false;
+ return FALSE;
}
if (! ieee_write_number (info, high + 1))
- return false;
+ return FALSE;
if (! localp)
{
@@ -5798,18 +5650,16 @@ ieee_array_type (p, low, high, stringp)
m->arrays = a;
}
- return true;
+ return TRUE;
}
/* Make a set type. */
-static boolean
-ieee_set_type (p, bitstringp)
- PTR p;
- boolean bitstringp ATTRIBUTE_UNUSED;
+static bfd_boolean
+ieee_set_type (void *p, bfd_boolean bitstringp ATTRIBUTE_UNUSED)
{
struct ieee_handle *info = (struct ieee_handle *) p;
- boolean localp;
+ bfd_boolean localp;
unsigned int eleindx;
localp = info->type_stack->type.localp;
@@ -5817,7 +5667,7 @@ ieee_set_type (p, bitstringp)
/* FIXME: We don't know the size, so we just use 4. */
- return (ieee_define_type (info, 0, true, localp)
+ return (ieee_define_type (info, 0, TRUE, localp)
&& ieee_write_number (info, 's')
&& ieee_write_number (info, 4)
&& ieee_write_number (info, eleindx));
@@ -5825,9 +5675,8 @@ ieee_set_type (p, bitstringp)
/* Make an offset type. */
-static boolean
-ieee_offset_type (p)
- PTR p;
+static bfd_boolean
+ieee_offset_type (void *p)
{
struct ieee_handle *info = (struct ieee_handle *) p;
unsigned int targetindx, baseindx;
@@ -5842,17 +5691,14 @@ ieee_offset_type (p)
member. Unfortunately, it does not describe the target type,
which seems pretty important. I'm going to punt this for now. */
- return ieee_int_type (p, 4, true);
+ return ieee_int_type (p, 4, TRUE);
}
/* Make a method type. */
-static boolean
-ieee_method_type (p, domain, argcount, varargs)
- PTR p;
- boolean domain;
- int argcount;
- boolean varargs;
+static bfd_boolean
+ieee_method_type (void *p, bfd_boolean domain, int argcount,
+ bfd_boolean varargs)
{
struct ieee_handle *info = (struct ieee_handle *) p;
@@ -5868,13 +5714,12 @@ ieee_method_type (p, domain, argcount, varargs)
/* Make a const qualified type. */
-static boolean
-ieee_const_type (p)
- PTR p;
+static bfd_boolean
+ieee_const_type (void *p)
{
struct ieee_handle *info = (struct ieee_handle *) p;
unsigned int size;
- boolean unsignedp, localp;
+ bfd_boolean unsignedp, localp;
unsigned int indx;
struct ieee_modified_type *m = NULL;
@@ -5887,34 +5732,33 @@ ieee_const_type (p)
{
m = ieee_get_modified_info (info, indx);
if (m == NULL)
- return false;
+ return FALSE;
if (m->const_qualified > 0)
return ieee_push_type (info, m->const_qualified, size, unsignedp,
- false);
+ FALSE);
}
if (! ieee_define_type (info, size, unsignedp, localp)
|| ! ieee_write_number (info, 'n')
|| ! ieee_write_number (info, 1)
|| ! ieee_write_number (info, indx))
- return false;
+ return FALSE;
if (! localp)
m->const_qualified = info->type_stack->type.indx;
- return true;
+ return TRUE;
}
/* Make a volatile qualified type. */
-static boolean
-ieee_volatile_type (p)
- PTR p;
+static bfd_boolean
+ieee_volatile_type (void *p)
{
struct ieee_handle *info = (struct ieee_handle *) p;
unsigned int size;
- boolean unsignedp, localp;
+ bfd_boolean unsignedp, localp;
unsigned int indx;
struct ieee_modified_type *m = NULL;
@@ -5927,30 +5771,29 @@ ieee_volatile_type (p)
{
m = ieee_get_modified_info (info, indx);
if (m == NULL)
- return false;
+ return FALSE;
if (m->volatile_qualified > 0)
return ieee_push_type (info, m->volatile_qualified, size, unsignedp,
- false);
+ FALSE);
}
if (! ieee_define_type (info, size, unsignedp, localp)
|| ! ieee_write_number (info, 'n')
|| ! ieee_write_number (info, 2)
|| ! ieee_write_number (info, indx))
- return false;
+ return FALSE;
if (! localp)
m->volatile_qualified = info->type_stack->type.indx;
- return true;
+ return TRUE;
}
/* Convert an enum debug_visibility into a CXXFLAGS value. */
static unsigned int
-ieee_vis_to_flags (visibility)
- enum debug_visibility visibility;
+ieee_vis_to_flags (enum debug_visibility visibility)
{
switch (visibility)
{
@@ -5970,25 +5813,21 @@ ieee_vis_to_flags (visibility)
the stack, to avoid confusing type definitions required by the
fields with the struct type itself. */
-static boolean
-ieee_start_struct_type (p, tag, id, structp, size)
- PTR p;
- const char *tag;
- unsigned int id;
- boolean structp;
- unsigned int size;
+static bfd_boolean
+ieee_start_struct_type (void *p, const char *tag, unsigned int id,
+ bfd_boolean structp, unsigned int size)
{
struct ieee_handle *info = (struct ieee_handle *) p;
- boolean localp, ignorep;
- boolean copy;
+ bfd_boolean localp, ignorep;
+ bfd_boolean copy;
char ab[20];
const char *look;
struct ieee_name_type_hash_entry *h;
struct ieee_name_type *nt, *ntlook;
struct ieee_buflist strdef;
- localp = false;
- ignorep = false;
+ localp = FALSE;
+ ignorep = FALSE;
/* We need to create a tag for internal use even if we don't want
one for external use. This will let us refer to an anonymous
@@ -5996,20 +5835,20 @@ ieee_start_struct_type (p, tag, id, structp, size)
if (tag != NULL)
{
look = tag;
- copy = false;
+ copy = FALSE;
}
else
{
sprintf (ab, "__anon%u", id);
look = ab;
- copy = true;
+ copy = TRUE;
}
/* If we already have references to the tag, we must use the
existing type index. */
- h = ieee_name_type_hash_lookup (&info->tags, look, true, copy);
+ h = ieee_name_type_hash_lookup (&info->tags, look, TRUE, copy);
if (h == NULL)
- return false;
+ return FALSE;
nt = NULL;
for (ntlook = h->types; ntlook != NULL; ntlook = ntlook->next)
@@ -6021,7 +5860,7 @@ ieee_start_struct_type (p, tag, id, structp, size)
/* We are creating a duplicate definition of a globally
defined tag. Force it to be local to avoid
confusion. */
- localp = true;
+ localp = TRUE;
}
}
@@ -6032,7 +5871,7 @@ ieee_start_struct_type (p, tag, id, structp, size)
{
/* We've already seen a global definition of the type.
Ignore this new definition. */
- ignorep = true;
+ ignorep = TRUE;
}
}
else
@@ -6050,11 +5889,11 @@ ieee_start_struct_type (p, tag, id, structp, size)
nt->kind = DEBUG_KIND_ILLEGAL;
if (! ieee_init_buffer (info, &strdef)
- || ! ieee_define_named_type (info, tag, nt->type.indx, size, true,
+ || ! ieee_define_named_type (info, tag, nt->type.indx, size, TRUE,
localp, &strdef)
|| ! ieee_write_number (info, structp ? 'S' : 'U')
|| ! ieee_write_number (info, size))
- return false;
+ return FALSE;
if (! ignorep)
{
@@ -6072,24 +5911,20 @@ ieee_start_struct_type (p, tag, id, structp, size)
info->type_stack->type.strdef = strdef;
info->type_stack->type.ignorep = ignorep;
- return true;
+ return TRUE;
}
/* Add a field to a struct. */
-static boolean
-ieee_struct_field (p, name, bitpos, bitsize, visibility)
- PTR p;
- const char *name;
- bfd_vma bitpos;
- bfd_vma bitsize;
- enum debug_visibility visibility;
+static bfd_boolean
+ieee_struct_field (void *p, const char *name, bfd_vma bitpos, bfd_vma bitsize,
+ enum debug_visibility visibility)
{
struct ieee_handle *info = (struct ieee_handle *) p;
unsigned int size;
- boolean unsignedp;
- boolean referencep;
- boolean localp;
+ bfd_boolean unsignedp;
+ bfd_boolean referencep;
+ bfd_boolean localp;
unsigned int indx;
bfd_vma offset;
@@ -6102,7 +5937,7 @@ ieee_struct_field (p, name, bitpos, bitsize, visibility)
if (info->type_stack->next->type.ignorep)
{
ieee_pop_unused_type (info);
- return true;
+ return TRUE;
}
size = info->type_stack->type.size;
@@ -6112,7 +5947,7 @@ ieee_struct_field (p, name, bitpos, bitsize, visibility)
indx = ieee_pop_type (info);
if (localp)
- info->type_stack->type.localp = true;
+ info->type_stack->type.localp = TRUE;
if (info->type_stack->type.classdef != NULL)
{
@@ -6130,7 +5965,7 @@ ieee_struct_field (p, name, bitpos, bitsize, visibility)
|| ! ieee_write_asn (info, nindx, flags)
|| ! ieee_write_atn65 (info, nindx, name)
|| ! ieee_write_atn65 (info, nindx, name))
- return false;
+ return FALSE;
info->type_stack->type.classdef->pmisccount += 4;
if (referencep)
@@ -6160,7 +5995,7 @@ ieee_struct_field (p, name, bitpos, bitsize, visibility)
|| ! ieee_write_asn (info, nindx, 3)
|| ! ieee_write_atn65 (info, nindx, info->type_stack->type.name)
|| ! ieee_write_atn65 (info, nindx, name))
- return false;
+ return FALSE;
}
}
@@ -6176,7 +6011,7 @@ ieee_struct_field (p, name, bitpos, bitsize, visibility)
|| ! ieee_write_number (info, unsignedp ? 0 : 1)
|| ! ieee_write_number (info, bitsize)
|| ! ieee_write_number (info, indx))
- return false;
+ return FALSE;
indx = ieee_pop_type (info);
offset = bitpos;
}
@@ -6191,9 +6026,8 @@ ieee_struct_field (p, name, bitpos, bitsize, visibility)
/* Finish up a struct type. */
-static boolean
-ieee_end_struct_type (p)
- PTR p;
+static bfd_boolean
+ieee_end_struct_type (void *p)
{
struct ieee_handle *info = (struct ieee_handle *) p;
struct ieee_buflist *pb;
@@ -6202,13 +6036,13 @@ ieee_end_struct_type (p)
&& ! ieee_buffer_emptyp (&info->type_stack->type.strdef));
/* If we were ignoring this struct definition because it was a
- duplicate defintion, just through away whatever bytes we have
+ duplicate definition, just through away whatever bytes we have
accumulated. Leave the type on the stack. */
if (info->type_stack->type.ignorep)
- return true;
+ return TRUE;
/* If this is not a duplicate definition of this tag, then localp
- will be false, and we can put it in the global type block.
+ will be FALSE, and we can put it in the global type block.
FIXME: We should avoid outputting duplicate definitions which are
the same. */
if (! info->type_stack->type.localp)
@@ -6221,7 +6055,7 @@ ieee_end_struct_type (p)
|| ! ieee_write_byte (info, 2)
|| ! ieee_write_number (info, 0)
|| ! ieee_write_id (info, ""))
- return false;
+ return FALSE;
}
pb = &info->global_types;
}
@@ -6235,7 +6069,7 @@ ieee_end_struct_type (p)
|| ! ieee_write_byte (info, 1)
|| ! ieee_write_number (info, 0)
|| ! ieee_write_id (info, info->modname))
- return false;
+ return FALSE;
}
pb = &info->types;
}
@@ -6243,24 +6077,19 @@ ieee_end_struct_type (p)
/* Append the struct definition to the types. */
if (! ieee_append_buffer (info, pb, &info->type_stack->type.strdef)
|| ! ieee_init_buffer (info, &info->type_stack->type.strdef))
- return false;
+ return FALSE;
/* Leave the struct on the type stack. */
- return true;
+ return TRUE;
}
/* Start a class type. */
-static boolean
-ieee_start_class_type (p, tag, id, structp, size, vptr, ownvptr)
- PTR p;
- const char *tag;
- unsigned int id;
- boolean structp;
- unsigned int size;
- boolean vptr;
- boolean ownvptr;
+static bfd_boolean
+ieee_start_class_type (void *p, const char *tag, unsigned int id,
+ bfd_boolean structp, unsigned int size,
+ bfd_boolean vptr, bfd_boolean ownvptr)
{
struct ieee_handle *info = (struct ieee_handle *) p;
const char *vclass;
@@ -6296,7 +6125,7 @@ ieee_start_class_type (p, tag, id, structp, size, vptr, ownvptr)
}
if (! ieee_start_struct_type (p, tag, id, structp, size))
- return false;
+ return FALSE;
indx = info->name_indx;
++info->name_indx;
@@ -6309,7 +6138,7 @@ ieee_start_class_type (p, tag, id, structp, size, vptr, ownvptr)
|| ! ieee_write_asn (info, indx, 'T')
|| ! ieee_write_asn (info, indx, structp ? 'o' : 'u')
|| ! ieee_write_atn65 (info, indx, tag))
- return false;
+ return FALSE;
classdef = (struct ieee_type_class *) xmalloc (sizeof *classdef);
memset (classdef, 0, sizeof *classdef);
@@ -6322,17 +6151,14 @@ ieee_start_class_type (p, tag, id, structp, size, vptr, ownvptr)
info->type_stack->type.classdef = classdef;
- return true;
+ return TRUE;
}
/* Add a static member to a class. */
-static boolean
-ieee_class_static_member (p, name, physname, visibility)
- PTR p;
- const char *name;
- const char *physname;
- enum debug_visibility visibility;
+static bfd_boolean
+ieee_class_static_member (void *p, const char *name, const char *physname,
+ enum debug_visibility visibility)
{
struct ieee_handle *info = (struct ieee_handle *) p;
unsigned int flags;
@@ -6356,24 +6182,21 @@ ieee_class_static_member (p, name, physname, visibility)
|| ! ieee_write_asn (info, nindx, flags)
|| ! ieee_write_atn65 (info, nindx, name)
|| ! ieee_write_atn65 (info, nindx, physname))
- return false;
+ return FALSE;
info->type_stack->type.classdef->pmisccount += 4;
- return true;
+ return TRUE;
}
/* Add a base class to a class. */
-static boolean
-ieee_class_baseclass (p, bitpos, virtual, visibility)
- PTR p;
- bfd_vma bitpos;
- boolean virtual;
- enum debug_visibility visibility;
+static bfd_boolean
+ieee_class_baseclass (void *p, bfd_vma bitpos, bfd_boolean virtual,
+ enum debug_visibility visibility)
{
struct ieee_handle *info = (struct ieee_handle *) p;
const char *bname;
- boolean localp;
+ bfd_boolean localp;
unsigned int bindx;
char *fname;
unsigned int flags;
@@ -6403,7 +6226,7 @@ ieee_class_baseclass (p, bitpos, virtual, visibility)
else
{
if (localp)
- info->type_stack->type.localp = true;
+ info->type_stack->type.localp = TRUE;
fname = (char *) xmalloc (strlen (bname) + sizeof "_b$");
sprintf (fname, "_b$%s", bname);
@@ -6412,7 +6235,7 @@ ieee_class_baseclass (p, bitpos, virtual, visibility)
|| ! ieee_write_id (info, fname)
|| ! ieee_write_number (info, bindx)
|| ! ieee_write_number (info, bitpos / 8))
- return false;
+ return FALSE;
flags = 0;
}
@@ -6427,20 +6250,18 @@ ieee_class_baseclass (p, bitpos, virtual, visibility)
|| ! ieee_write_atn65 (info, nindx, bname)
|| ! ieee_write_asn (info, nindx, 0)
|| ! ieee_write_atn65 (info, nindx, fname))
- return false;
+ return FALSE;
info->type_stack->type.classdef->pmisccount += 5;
free (fname);
- return true;
+ return TRUE;
}
/* Start building a method for a class. */
-static boolean
-ieee_class_start_method (p, name)
- PTR p;
- const char *name;
+static bfd_boolean
+ieee_class_start_method (void *p, const char *name)
{
struct ieee_handle *info = (struct ieee_handle *) p;
@@ -6450,26 +6271,21 @@ ieee_class_start_method (p, name)
info->type_stack->type.classdef->method = name;
- return true;
+ return TRUE;
}
/* Define a new method variant, either static or not. */
-static boolean
-ieee_class_method_var (info, physname, visibility, staticp, constp,
- volatilep, voffset, context)
- struct ieee_handle *info;
- const char *physname;
- enum debug_visibility visibility;
- boolean staticp;
- boolean constp;
- boolean volatilep;
- bfd_vma voffset;
- boolean context;
+static bfd_boolean
+ieee_class_method_var (struct ieee_handle *info, const char *physname,
+ enum debug_visibility visibility,
+ bfd_boolean staticp, bfd_boolean constp,
+ bfd_boolean volatilep, bfd_vma voffset,
+ bfd_boolean context)
{
unsigned int flags;
unsigned int nindx;
- boolean virtual;
+ bfd_boolean virtual;
/* We don't need the type of the method. An IEEE consumer which
wants the type must track down the function by the physical name
@@ -6508,65 +6324,56 @@ ieee_class_method_var (info, physname, visibility, staticp, constp,
|| ! ieee_write_atn65 (info, nindx,
info->type_stack->type.classdef->method)
|| ! ieee_write_atn65 (info, nindx, physname))
- return false;
+ return FALSE;
if (virtual)
{
if (voffset > info->type_stack->type.classdef->voffset)
info->type_stack->type.classdef->voffset = voffset;
if (! ieee_write_asn (info, nindx, voffset))
- return false;
+ return FALSE;
++info->type_stack->type.classdef->pmisccount;
}
if (! ieee_write_asn (info, nindx, 0))
- return false;
+ return FALSE;
info->type_stack->type.classdef->pmisccount += 5;
- return true;
+ return TRUE;
}
/* Define a new method variant. */
-static boolean
-ieee_class_method_variant (p, physname, visibility, constp, volatilep,
- voffset, context)
- PTR p;
- const char *physname;
- enum debug_visibility visibility;
- boolean constp;
- boolean volatilep;
- bfd_vma voffset;
- boolean context;
+static bfd_boolean
+ieee_class_method_variant (void *p, const char *physname,
+ enum debug_visibility visibility,
+ bfd_boolean constp, bfd_boolean volatilep,
+ bfd_vma voffset, bfd_boolean context)
{
struct ieee_handle *info = (struct ieee_handle *) p;
- return ieee_class_method_var (info, physname, visibility, false, constp,
+ return ieee_class_method_var (info, physname, visibility, FALSE, constp,
volatilep, voffset, context);
}
/* Define a new static method variant. */
-static boolean
-ieee_class_static_method_variant (p, physname, visibility, constp, volatilep)
- PTR p;
- const char *physname;
- enum debug_visibility visibility;
- boolean constp;
- boolean volatilep;
+static bfd_boolean
+ieee_class_static_method_variant (void *p, const char *physname,
+ enum debug_visibility visibility,
+ bfd_boolean constp, bfd_boolean volatilep)
{
struct ieee_handle *info = (struct ieee_handle *) p;
- return ieee_class_method_var (info, physname, visibility, true, constp,
- volatilep, 0, false);
+ return ieee_class_method_var (info, physname, visibility, TRUE, constp,
+ volatilep, 0, FALSE);
}
/* Finish up a method. */
-static boolean
-ieee_class_end_method (p)
- PTR p;
+static bfd_boolean
+ieee_class_end_method (void *p)
{
struct ieee_handle *info = (struct ieee_handle *) p;
@@ -6576,14 +6383,13 @@ ieee_class_end_method (p)
info->type_stack->type.classdef->method = NULL;
- return true;
+ return TRUE;
}
/* Finish up a class. */
-static boolean
-ieee_end_class_type (p)
- PTR p;
+static bfd_boolean
+ieee_end_class_type (void *p)
{
struct ieee_handle *info = (struct ieee_handle *) p;
unsigned int nindx;
@@ -6595,7 +6401,7 @@ ieee_end_class_type (p)
duplicate definition, just through away whatever bytes we have
accumulated. Leave the type on the stack. */
if (info->type_stack->type.ignorep)
- return true;
+ return TRUE;
nindx = info->type_stack->type.classdef->indx;
@@ -6609,20 +6415,20 @@ ieee_end_class_type (p)
|| ! ieee_write_atn65 (info, nindx, "")
|| ! ieee_write_asn (info, nindx,
info->type_stack->type.classdef->voffset))
- return false;
+ return FALSE;
if (info->type_stack->type.classdef->ownvptr)
{
if (! ieee_write_atn65 (info, nindx, ""))
- return false;
+ return FALSE;
}
else
{
if (! ieee_write_atn65 (info, nindx,
info->type_stack->type.classdef->vclass))
- return false;
+ return FALSE;
}
if (! ieee_write_asn (info, nindx, 0))
- return false;
+ return FALSE;
info->type_stack->type.classdef->pmisccount += 5;
}
@@ -6641,16 +6447,16 @@ ieee_end_class_type (p)
|| ! ieee_write_number (info, 80)
|| ! ieee_write_number (info,
info->type_stack->type.classdef->pmisccount))
- return false;
+ return FALSE;
if (! ieee_append_buffer (info, &info->cxx,
&info->type_stack->type.classdef->pmiscbuf))
- return false;
+ return FALSE;
if (! ieee_buffer_emptyp (&info->type_stack->type.classdef->refs))
{
if (! ieee_append_buffer (info, &info->cxx,
&info->type_stack->type.classdef->refs))
- return false;
+ return FALSE;
}
return ieee_end_struct_type (p);
@@ -6658,16 +6464,14 @@ ieee_end_class_type (p)
/* Push a previously seen typedef onto the type stack. */
-static boolean
-ieee_typedef_type (p, name)
- PTR p;
- const char *name;
+static bfd_boolean
+ieee_typedef_type (void *p, const char *name)
{
struct ieee_handle *info = (struct ieee_handle *) p;
struct ieee_name_type_hash_entry *h;
struct ieee_name_type *nt;
- h = ieee_name_type_hash_lookup (&info->typedefs, name, false, false);
+ h = ieee_name_type_hash_lookup (&info->typedefs, name, FALSE, FALSE);
/* h should never be NULL, since that would imply that the generic
debugging code has asked for a typedef which it has not yet
@@ -6680,26 +6484,23 @@ ieee_typedef_type (p, name)
nt = h->types;
if (! ieee_push_type (info, nt->type.indx, nt->type.size,
nt->type.unsignedp, nt->type.localp))
- return false;
+ return FALSE;
/* Copy over any other type information we may have. */
info->type_stack->type = nt->type;
- return true;
+ return TRUE;
}
/* Push a tagged type onto the type stack. */
-static boolean
-ieee_tag_type (p, name, id, kind)
- PTR p;
- const char *name;
- unsigned int id;
- enum debug_type_kind kind;
+static bfd_boolean
+ieee_tag_type (void *p, const char *name, unsigned int id,
+ enum debug_type_kind kind)
{
struct ieee_handle *info = (struct ieee_handle *) p;
- boolean localp;
- boolean copy;
+ bfd_boolean localp;
+ bfd_boolean copy;
char ab[20];
struct ieee_name_type_hash_entry *h;
struct ieee_name_type *nt;
@@ -6712,7 +6513,7 @@ ieee_tag_type (p, name, id, kind)
abort ();
for (e = info->enums; e != NULL; e = e->next)
if (e->tag != NULL && strcmp (e->tag, name) == 0)
- return ieee_push_type (info, e->indx, 0, true, false);
+ return ieee_push_type (info, e->indx, 0, TRUE, FALSE);
e = (struct ieee_defined_enum *) xmalloc (sizeof *e);
memset (e, 0, sizeof *e);
@@ -6720,27 +6521,27 @@ ieee_tag_type (p, name, id, kind)
e->indx = info->type_indx;
++info->type_indx;
e->tag = name;
- e->defined = false;
+ e->defined = FALSE;
e->next = info->enums;
info->enums = e;
- return ieee_push_type (info, e->indx, 0, true, false);
+ return ieee_push_type (info, e->indx, 0, TRUE, FALSE);
}
- localp = false;
+ localp = FALSE;
- copy = false;
+ copy = FALSE;
if (name == NULL)
{
sprintf (ab, "__anon%u", id);
name = ab;
- copy = true;
+ copy = TRUE;
}
- h = ieee_name_type_hash_lookup (&info->tags, name, true, copy);
+ h = ieee_name_type_hash_lookup (&info->tags, name, TRUE, copy);
if (h == NULL)
- return false;
+ return FALSE;
for (nt = h->types; nt != NULL; nt = nt->next)
{
@@ -6748,17 +6549,17 @@ ieee_tag_type (p, name, id, kind)
{
if (! ieee_push_type (info, nt->type.indx, nt->type.size,
nt->type.unsignedp, nt->type.localp))
- return false;
+ return FALSE;
/* Copy over any other type information we may have. */
info->type_stack->type = nt->type;
- return true;
+ return TRUE;
}
if (! nt->type.localp)
{
/* This is a duplicate of a global type, so it must be
local. */
- localp = true;
+ localp = TRUE;
}
}
@@ -6775,26 +6576,24 @@ ieee_tag_type (p, name, id, kind)
nt->next = h->types;
h->types = nt;
- if (! ieee_push_type (info, nt->type.indx, 0, false, localp))
- return false;
+ if (! ieee_push_type (info, nt->type.indx, 0, FALSE, localp))
+ return FALSE;
info->type_stack->type.name = h->root.string;
- return true;
+ return TRUE;
}
/* Output a typedef. */
-static boolean
-ieee_typdef (p, name)
- PTR p;
- const char *name;
+static bfd_boolean
+ieee_typdef (void *p, const char *name)
{
struct ieee_handle *info = (struct ieee_handle *) p;
struct ieee_write_type type;
unsigned int indx;
- boolean found;
- boolean localp;
+ bfd_boolean found;
+ bfd_boolean localp;
struct ieee_name_type_hash_entry *h;
struct ieee_name_type *nt;
@@ -6806,7 +6605,7 @@ ieee_typdef (p, name)
type index to correspond to the name being used. We recognize
names used in stabs debugging output even if they don't exactly
correspond to the names used for the IEEE builtin types. */
- found = false;
+ found = FALSE;
if (indx <= (unsigned int) builtin_bcd_float)
{
switch ((enum builtin_types) indx)
@@ -6816,7 +6615,7 @@ ieee_typdef (p, name)
case builtin_void:
if (strcmp (name, "void") == 0)
- found = true;
+ found = TRUE;
break;
case builtin_signed_char:
@@ -6824,18 +6623,18 @@ ieee_typdef (p, name)
if (strcmp (name, "signed char") == 0)
{
indx = (unsigned int) builtin_signed_char;
- found = true;
+ found = TRUE;
}
else if (strcmp (name, "char") == 0)
{
indx = (unsigned int) builtin_char;
- found = true;
+ found = TRUE;
}
break;
case builtin_unsigned_char:
if (strcmp (name, "unsigned char") == 0)
- found = true;
+ found = TRUE;
break;
case builtin_signed_short_int:
@@ -6845,22 +6644,22 @@ ieee_typdef (p, name)
if (strcmp (name, "signed short int") == 0)
{
indx = (unsigned int) builtin_signed_short_int;
- found = true;
+ found = TRUE;
}
else if (strcmp (name, "short") == 0)
{
indx = (unsigned int) builtin_short;
- found = true;
+ found = TRUE;
}
else if (strcmp (name, "short int") == 0)
{
indx = (unsigned int) builtin_short_int;
- found = true;
+ found = TRUE;
}
else if (strcmp (name, "signed short") == 0)
{
indx = (unsigned int) builtin_signed_short;
- found = true;
+ found = TRUE;
}
break;
@@ -6870,12 +6669,12 @@ ieee_typdef (p, name)
|| strcmp (name, "short unsigned int") == 0)
{
indx = builtin_unsigned_short_int;
- found = true;
+ found = TRUE;
}
else if (strcmp (name, "unsigned short") == 0)
{
indx = builtin_unsigned_short;
- found = true;
+ found = TRUE;
}
break;
@@ -6885,18 +6684,18 @@ ieee_typdef (p, name)
if (strcmp (name, "signed long") == 0)
{
indx = builtin_signed_long;
- found = true;
+ found = TRUE;
}
else if (strcmp (name, "int") == 0)
{
indx = builtin_int;
- found = true;
+ found = TRUE;
}
else if (strcmp (name, "long") == 0
|| strcmp (name, "long int") == 0)
{
indx = builtin_long;
- found = true;
+ found = TRUE;
}
break;
@@ -6907,50 +6706,50 @@ ieee_typdef (p, name)
|| strcmp (name, "long unsigned int") == 0)
{
indx = builtin_unsigned_long;
- found = true;
+ found = TRUE;
}
else if (strcmp (name, "unsigned") == 0)
{
indx = builtin_unsigned;
- found = true;
+ found = TRUE;
}
else if (strcmp (name, "unsigned int") == 0)
{
indx = builtin_unsigned_int;
- found = true;
+ found = TRUE;
}
break;
case builtin_signed_long_long:
if (strcmp (name, "signed long long") == 0
|| strcmp (name, "long long int") == 0)
- found = true;
+ found = TRUE;
break;
case builtin_unsigned_long_long:
if (strcmp (name, "unsigned long long") == 0
|| strcmp (name, "long long unsigned int") == 0)
- found = true;
+ found = TRUE;
break;
case builtin_float:
if (strcmp (name, "float") == 0)
- found = true;
+ found = TRUE;
break;
case builtin_double:
if (strcmp (name, "double") == 0)
- found = true;
+ found = TRUE;
break;
case builtin_long_double:
if (strcmp (name, "long double") == 0)
- found = true;
+ found = TRUE;
break;
case builtin_long_long_double:
if (strcmp (name, "long long double") == 0)
- found = true;
+ found = TRUE;
break;
}
@@ -6958,9 +6757,9 @@ ieee_typdef (p, name)
type.indx = indx;
}
- h = ieee_name_type_hash_lookup (&info->typedefs, name, true, false);
+ h = ieee_name_type_hash_lookup (&info->typedefs, name, TRUE, FALSE);
if (h == NULL)
- return false;
+ return FALSE;
/* See if we have already defined this type with this name. */
localp = type.localp;
@@ -6973,13 +6772,13 @@ ieee_typdef (p, name)
if (! nt->type.localp)
{
ieee_pop_unused_type (info);
- return true;
+ return TRUE;
}
}
else
{
/* This is a duplicate definition, so make this one local. */
- localp = true;
+ localp = TRUE;
}
}
@@ -7001,7 +6800,7 @@ ieee_typdef (p, name)
/* This is one of the builtin typedefs, so we don't need to
actually define it. */
ieee_pop_unused_type (info);
- return true;
+ return TRUE;
}
indx = ieee_pop_type (info);
@@ -7011,85 +6810,75 @@ ieee_typdef (p, name)
(struct ieee_buflist *) NULL)
|| ! ieee_write_number (info, 'T')
|| ! ieee_write_number (info, indx))
- return false;
+ return FALSE;
/* Remove the type we just added to the type stack. This should not
be ieee_pop_unused_type, since the type is used, we just don't
need it now. */
(void) ieee_pop_type (info);
- return true;
+ return TRUE;
}
/* Output a tag for a type. We don't have to do anything here. */
-static boolean
-ieee_tag (p, name)
- PTR p;
- const char *name ATTRIBUTE_UNUSED;
+static bfd_boolean
+ieee_tag (void *p, const char *name ATTRIBUTE_UNUSED)
{
struct ieee_handle *info = (struct ieee_handle *) p;
/* This should not be ieee_pop_unused_type, since we want the type
to be defined. */
(void) ieee_pop_type (info);
- return true;
+ return TRUE;
}
/* Output an integer constant. */
-static boolean
-ieee_int_constant (p, name, val)
- PTR p ATTRIBUTE_UNUSED;
- const char *name ATTRIBUTE_UNUSED;
- bfd_vma val ATTRIBUTE_UNUSED;
+static bfd_boolean
+ieee_int_constant (void *p ATTRIBUTE_UNUSED, const char *name ATTRIBUTE_UNUSED,
+ bfd_vma val ATTRIBUTE_UNUSED)
{
/* FIXME. */
- return true;
+ return TRUE;
}
/* Output a floating point constant. */
-static boolean
-ieee_float_constant (p, name, val)
- PTR p ATTRIBUTE_UNUSED;
- const char *name ATTRIBUTE_UNUSED;
- double val ATTRIBUTE_UNUSED;
+static bfd_boolean
+ieee_float_constant (void *p ATTRIBUTE_UNUSED,
+ const char *name ATTRIBUTE_UNUSED,
+ double val ATTRIBUTE_UNUSED)
{
/* FIXME. */
- return true;
+ return TRUE;
}
/* Output a typed constant. */
-static boolean
-ieee_typed_constant (p, name, val)
- PTR p;
- const char *name ATTRIBUTE_UNUSED;
- bfd_vma val ATTRIBUTE_UNUSED;
+static bfd_boolean
+ieee_typed_constant (void *p, const char *name ATTRIBUTE_UNUSED,
+ bfd_vma val ATTRIBUTE_UNUSED)
{
struct ieee_handle *info = (struct ieee_handle *) p;
/* FIXME. */
ieee_pop_unused_type (info);
- return true;
+ return TRUE;
}
/* Output a variable. */
-static boolean
-ieee_variable (p, name, kind, val)
- PTR p;
- const char *name;
- enum debug_var_kind kind;
- bfd_vma val;
+static bfd_boolean
+ieee_variable (void *p, const char *name, enum debug_var_kind kind,
+ bfd_vma val)
{
struct ieee_handle *info = (struct ieee_handle *) p;
unsigned int name_indx;
unsigned int size;
- boolean referencep;
+ bfd_boolean referencep;
unsigned int type_indx;
- boolean asn;
+ bfd_boolean asn;
int refflag;
size = info->type_stack->type.size;
@@ -7098,7 +6887,7 @@ ieee_variable (p, name, kind, val)
assert (! ieee_buffer_emptyp (&info->vars));
if (! ieee_change_buffer (info, &info->vars))
- return false;
+ return FALSE;
name_indx = info->name_indx;
++info->name_indx;
@@ -7110,54 +6899,54 @@ ieee_variable (p, name, kind, val)
|| ! ieee_write_2bytes (info, (int) ieee_atn_record_enum)
|| ! ieee_write_number (info, name_indx)
|| ! ieee_write_number (info, type_indx))
- return false;
+ return FALSE;
switch (kind)
{
default:
abort ();
- return false;
+ return FALSE;
case DEBUG_GLOBAL:
if (! ieee_write_number (info, 8)
- || ! ieee_add_range (info, false, val, val + size))
- return false;
+ || ! ieee_add_range (info, FALSE, val, val + size))
+ return FALSE;
refflag = 0;
- asn = true;
+ asn = TRUE;
break;
case DEBUG_STATIC:
if (! ieee_write_number (info, 3)
- || ! ieee_add_range (info, false, val, val + size))
- return false;
+ || ! ieee_add_range (info, FALSE, val, val + size))
+ return FALSE;
refflag = 1;
- asn = true;
+ asn = TRUE;
break;
case DEBUG_LOCAL_STATIC:
if (! ieee_write_number (info, 3)
- || ! ieee_add_range (info, false, val, val + size))
- return false;
+ || ! ieee_add_range (info, FALSE, val, val + size))
+ return FALSE;
refflag = 2;
- asn = true;
+ asn = TRUE;
break;
case DEBUG_LOCAL:
if (! ieee_write_number (info, 1)
|| ! ieee_write_number (info, val))
- return false;
+ return FALSE;
refflag = 2;
- asn = false;
+ asn = FALSE;
break;
case DEBUG_REGISTER:
if (! ieee_write_number (info, 2)
|| ! ieee_write_number (info,
ieee_genreg_to_regno (info->abfd, val)))
- return false;
+ return FALSE;
refflag = 2;
- asn = false;
+ asn = FALSE;
break;
}
if (asn)
{
if (! ieee_write_asn (info, name_indx, val))
- return false;
+ return FALSE;
}
/* If this is really a reference type, then we just output it with
@@ -7177,7 +6966,7 @@ ieee_variable (p, name, kind, val)
if (refflag != 2)
{
if (! ieee_change_buffer (info, &info->cxx))
- return false;
+ return FALSE;
}
if (! ieee_write_byte (info, (int) ieee_nn_record)
@@ -7192,22 +6981,19 @@ ieee_variable (p, name, kind, val)
|| ! ieee_write_asn (info, nindx, 'R')
|| ! ieee_write_asn (info, nindx, refflag)
|| ! ieee_write_atn65 (info, nindx, name))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Start outputting information for a function. */
-static boolean
-ieee_start_function (p, name, global)
- PTR p;
- const char *name;
- boolean global;
+static bfd_boolean
+ieee_start_function (void *p, const char *name, bfd_boolean global)
{
struct ieee_handle *info = (struct ieee_handle *) p;
- boolean referencep;
+ bfd_boolean referencep;
unsigned int retindx, typeindx;
referencep = info->type_stack->type.referencep;
@@ -7227,19 +7013,19 @@ ieee_start_function (p, name, global)
info->fnname = name;
/* An attribute of 0x40 means that the push mask is unknown. */
- if (! ieee_define_named_type (info, name, (unsigned int) -1, 0, false, true,
+ if (! ieee_define_named_type (info, name, (unsigned int) -1, 0, FALSE, TRUE,
&info->fntype)
|| ! ieee_write_number (info, 'x')
|| ! ieee_write_number (info, 0x40)
|| ! ieee_write_number (info, 0)
|| ! ieee_write_number (info, 0)
|| ! ieee_write_number (info, retindx))
- return false;
+ return FALSE;
typeindx = ieee_pop_type (info);
if (! ieee_init_buffer (info, &info->fnargs))
- return false;
+ return FALSE;
info->fnargcount = 0;
/* If the function return value is actually a reference type, we
@@ -7263,12 +7049,12 @@ ieee_start_function (p, name, global)
|| ! ieee_write_asn (info, nindx, 'R')
|| ! ieee_write_asn (info, nindx, global ? 0 : 1)
|| ! ieee_write_atn65 (info, nindx, name))
- return false;
+ return FALSE;
}
assert (! ieee_buffer_emptyp (&info->vars));
if (! ieee_change_buffer (info, &info->vars))
- return false;
+ return FALSE;
/* The address is written out as the first block. */
@@ -7285,12 +7071,9 @@ ieee_start_function (p, name, global)
/* Add a function parameter. This will normally be called before the
first block, so we postpone them until we see the block. */
-static boolean
-ieee_function_parameter (p, name, kind, val)
- PTR p;
- const char *name;
- enum debug_parm_kind kind;
- bfd_vma val;
+static bfd_boolean
+ieee_function_parameter (void *p, const char *name, enum debug_parm_kind kind,
+ bfd_vma val)
{
struct ieee_handle *info = (struct ieee_handle *) p;
struct ieee_pending_parm *m, **pm;
@@ -7314,17 +7097,16 @@ ieee_function_parameter (p, name, kind, val)
/* Add the type to the fnargs list. */
if (! ieee_change_buffer (info, &info->fnargs)
|| ! ieee_write_number (info, m->type))
- return false;
+ return FALSE;
++info->fnargcount;
- return true;
+ return TRUE;
}
/* Output pending function parameters. */
-static boolean
-ieee_output_pending_parms (info)
- struct ieee_handle *info;
+static bfd_boolean
+ieee_output_pending_parms (struct ieee_handle *info)
{
struct ieee_pending_parm *m;
unsigned int refcount;
@@ -7338,7 +7120,7 @@ ieee_output_pending_parms (info)
{
default:
abort ();
- return false;
+ return FALSE;
case DEBUG_PARM_STACK:
case DEBUG_PARM_REFERENCE:
vkind = DEBUG_LOCAL;
@@ -7349,13 +7131,13 @@ ieee_output_pending_parms (info)
break;
}
- if (! ieee_push_type (info, m->type, 0, false, false))
- return false;
+ if (! ieee_push_type (info, m->type, 0, FALSE, FALSE))
+ return FALSE;
info->type_stack->type.referencep = m->referencep;
if (m->referencep)
++refcount;
- if (! ieee_variable ((PTR) info, m->name, vkind, m->val))
- return false;
+ if (! ieee_variable ((void *) info, m->name, vkind, m->val))
+ return FALSE;
}
/* If there are any reference parameters, we need to output a
@@ -7381,7 +7163,7 @@ ieee_output_pending_parms (info)
|| ! ieee_write_asn (info, nindx, 'B')
|| ! ieee_write_atn65 (info, nindx, info->fnname)
|| ! ieee_write_asn (info, nindx, 0))
- return false;
+ return FALSE;
for (m = info->pending_parms, varindx = 1;
m != NULL;
m = m->next, varindx++)
@@ -7389,7 +7171,7 @@ ieee_output_pending_parms (info)
if (m->referencep)
{
if (! ieee_write_asn (info, nindx, varindx))
- return false;
+ return FALSE;
}
}
}
@@ -7406,27 +7188,25 @@ ieee_output_pending_parms (info)
info->pending_parms = NULL;
- return true;
+ return TRUE;
}
/* Start a block. If this is the first block, we output the address
to finish the BB4 or BB6, and then output the function parameters. */
-static boolean
-ieee_start_block (p, addr)
- PTR p;
- bfd_vma addr;
+static bfd_boolean
+ieee_start_block (void *p, bfd_vma addr)
{
struct ieee_handle *info = (struct ieee_handle *) p;
if (! ieee_change_buffer (info, &info->vars))
- return false;
+ return FALSE;
if (info->block_depth == 1)
{
if (! ieee_write_number (info, addr)
|| ! ieee_output_pending_parms (info))
- return false;
+ return FALSE;
}
else
{
@@ -7437,23 +7217,21 @@ ieee_start_block (p, addr)
|| ! ieee_write_number (info, 0)
|| ! ieee_write_number (info, 0)
|| ! ieee_write_number (info, addr))
- return false;
+ return FALSE;
}
if (! ieee_start_range (info, addr))
- return false;
+ return FALSE;
++info->block_depth;
- return true;
+ return TRUE;
}
/* End a block. */
-static boolean
-ieee_end_block (p, addr)
- PTR p;
- bfd_vma addr;
+static bfd_boolean
+ieee_end_block (void *p, bfd_vma addr)
{
struct ieee_handle *info = (struct ieee_handle *) p;
@@ -7463,24 +7241,23 @@ ieee_end_block (p, addr)
if (! ieee_change_buffer (info, &info->vars)
|| ! ieee_write_byte (info, (int) ieee_be_record_enum)
|| ! ieee_write_number (info, addr - 1))
- return false;
+ return FALSE;
if (! ieee_end_range (info, addr))
- return false;
+ return FALSE;
--info->block_depth;
if (addr > info->highaddr)
info->highaddr = addr;
- return true;
+ return TRUE;
}
/* End a function. */
-static boolean
-ieee_end_function (p)
- PTR p;
+static bfd_boolean
+ieee_end_function (void *p)
{
struct ieee_handle *info = (struct ieee_handle *) p;
@@ -7498,7 +7275,7 @@ ieee_end_function (p)
|| ! ieee_write_number (info, info->fnargcount)
|| ! ieee_change_buffer (info, &info->fnargs)
|| ! ieee_write_number (info, 0))
- return false;
+ return FALSE;
/* Make sure the typdef block has been started. */
if (ieee_buffer_emptyp (&info->types))
@@ -7508,30 +7285,26 @@ ieee_end_function (p)
|| ! ieee_write_byte (info, 1)
|| ! ieee_write_number (info, 0)
|| ! ieee_write_id (info, info->modname))
- return false;
+ return FALSE;
}
if (! ieee_append_buffer (info, &info->types, &info->fntype)
|| ! ieee_append_buffer (info, &info->types, &info->fnargs))
- return false;
+ return FALSE;
info->fnname = NULL;
if (! ieee_init_buffer (info, &info->fntype)
|| ! ieee_init_buffer (info, &info->fnargs))
- return false;
+ return FALSE;
info->fnargcount = 0;
- return true;
+ return TRUE;
}
/* Record line number information. */
-static boolean
-ieee_lineno (p, filename, lineno, addr)
- PTR p;
- const char *filename;
- unsigned long lineno;
- bfd_vma addr;
+static bfd_boolean
+ieee_lineno (void *p, const char *filename, unsigned long lineno, bfd_vma addr)
{
struct ieee_handle *info = (struct ieee_handle *) p;
@@ -7548,7 +7321,7 @@ ieee_lineno (p, filename, lineno, addr)
if (! ieee_buffer_emptyp (&info->linenos))
{
if (! ieee_change_buffer (info, &info->linenos))
- return false;
+ return FALSE;
}
else
{
@@ -7562,7 +7335,7 @@ ieee_lineno (p, filename, lineno, addr)
|| ! ieee_write_byte (info, (int) ieee_nn_record)
|| ! ieee_write_number (info, info->lineno_name_indx)
|| ! ieee_write_id (info, ""))
- return false;
+ return FALSE;
info->lineno_filename = info->filename;
}
@@ -7573,7 +7346,7 @@ ieee_lineno (p, filename, lineno, addr)
/* We were not in the main file. Close the block for the
included file. */
if (! ieee_write_byte (info, (int) ieee_be_record_enum))
- return false;
+ return FALSE;
if (strcmp (info->filename, info->pending_lineno_filename) == 0)
{
/* We need a new NN record, and we aren't about to
@@ -7583,7 +7356,7 @@ ieee_lineno (p, filename, lineno, addr)
if (! ieee_write_byte (info, (int) ieee_nn_record)
|| ! ieee_write_number (info, info->lineno_name_indx)
|| ! ieee_write_id (info, ""))
- return false;
+ return FALSE;
}
}
if (strcmp (info->filename, info->pending_lineno_filename) != 0)
@@ -7599,7 +7372,7 @@ ieee_lineno (p, filename, lineno, addr)
|| ! ieee_write_byte (info, (int) ieee_nn_record)
|| ! ieee_write_number (info, info->lineno_name_indx)
|| ! ieee_write_id (info, ""))
- return false;
+ return FALSE;
}
info->lineno_filename = info->pending_lineno_filename;
}
@@ -7612,12 +7385,12 @@ ieee_lineno (p, filename, lineno, addr)
|| ! ieee_write_number (info, 0)
|| ! ieee_write_asn (info, info->lineno_name_indx,
info->pending_lineno_addr))
- return false;
+ return FALSE;
}
info->pending_lineno_filename = filename;
info->pending_lineno = lineno;
info->pending_lineno_addr = addr;
- return true;
+ return TRUE;
}
diff --git a/contrib/binutils/binutils/objcopy.c b/contrib/binutils/binutils/objcopy.c
index 241a2c6..9623398 100644
--- a/contrib/binutils/binutils/objcopy.c
+++ b/contrib/binutils/binutils/objcopy.c
@@ -1,6 +1,6 @@
/* objcopy.c -- copy object file from input to output, optionally massaging it.
Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
- 2001, 2002
+ 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -27,6 +27,8 @@
#include "libiberty.h"
#include "budbg.h"
#include "filenames.h"
+#include "fnmatch.h"
+#include "elf-bfd.h"
#include <sys/stat.h>
/* A list of symbols to explicitly strip out, or to keep. A linked
@@ -58,56 +60,29 @@ typedef struct section_rename
section_rename;
/* List of sections to be renamed. */
-static section_rename * section_rename_list;
-
-static void copy_usage PARAMS ((FILE *, int));
-static void strip_usage PARAMS ((FILE *, int));
-static flagword parse_flags PARAMS ((const char *));
-static struct section_list *find_section_list PARAMS ((const char *, boolean));
-static void setup_section PARAMS ((bfd *, asection *, PTR));
-static void copy_section PARAMS ((bfd *, asection *, PTR));
-static void get_sections PARAMS ((bfd *, asection *, PTR));
-static int compare_section_lma PARAMS ((const PTR, const PTR));
-static void add_specific_symbol PARAMS ((const char *, struct symlist **));
-static void add_specific_symbols PARAMS ((const char *, struct symlist **));
-static boolean is_specified_symbol PARAMS ((const char *, struct symlist *));
-static boolean is_strip_section PARAMS ((bfd *, asection *));
-static unsigned int filter_symbols
- PARAMS ((bfd *, bfd *, asymbol **, asymbol **, long));
-static void mark_symbols_used_in_relocations PARAMS ((bfd *, asection *, PTR));
-static void filter_bytes PARAMS ((char *, bfd_size_type *));
-static boolean write_debugging_info PARAMS ((bfd *, PTR, long *, asymbol ***));
-static void copy_object PARAMS ((bfd *, bfd *));
-static void copy_archive PARAMS ((bfd *, bfd *, const char *));
-static void copy_file
- PARAMS ((const char *, const char *, const char *, const char *));
-static int strip_main PARAMS ((int, char **));
-static int copy_main PARAMS ((int, char **));
-static const char *lookup_sym_redefinition PARAMS((const char *));
-static void redefine_list_append PARAMS ((const char *, const char *));
-static const char * find_section_rename PARAMS ((bfd *, sec_ptr, flagword *));
-static void add_section_rename PARAMS ((const char *, const char *, flagword));
+static section_rename *section_rename_list;
#define RETURN_NONFATAL(s) {bfd_nonfatal (s); status = 1; return;}
-static asymbol **isympp = NULL; /* Input symbols */
-static asymbol **osympp = NULL; /* Output symbols that survive stripping */
+static asymbol **isympp = NULL; /* Input symbols. */
+static asymbol **osympp = NULL; /* Output symbols that survive stripping. */
/* If `copy_byte' >= 0, copy only that byte of every `interleave' bytes. */
static int copy_byte = -1;
static int interleave = 4;
-static boolean verbose; /* Print file and target names. */
-static boolean preserve_dates; /* Preserve input file timestamp. */
+static bfd_boolean verbose; /* Print file and target names. */
+static bfd_boolean preserve_dates; /* Preserve input file timestamp. */
static int status = 0; /* Exit status. */
enum strip_action
{
STRIP_UNDEF,
- STRIP_NONE, /* don't strip */
- STRIP_DEBUG, /* strip all debugger symbols */
- STRIP_UNNEEDED, /* strip unnecessary symbols */
- STRIP_ALL /* strip all symbols */
+ STRIP_NONE, /* Don't strip. */
+ STRIP_DEBUG, /* Strip all debugger symbols. */
+ STRIP_UNNEEDED, /* Strip unnecessary symbols. */
+ STRIP_NONDEBUG, /* Strip everything but debug info. */
+ STRIP_ALL /* Strip all symbols. */
};
/* Which symbols to remove. */
@@ -116,8 +91,8 @@ static enum strip_action strip_symbols;
enum locals_action
{
LOCALS_UNDEF,
- LOCALS_START_L, /* discard locals starting with L */
- LOCALS_ALL /* discard all locals */
+ LOCALS_START_L, /* Discard locals starting with L. */
+ LOCALS_ALL /* Discard all locals. */
};
/* Which local symbols to remove. Overrides STRIP_ALL. */
@@ -134,46 +109,50 @@ enum change_action
/* Structure used to hold lists of sections and actions to take. */
struct section_list
{
- struct section_list * next; /* Next section to change. */
- const char * name; /* Section name. */
- boolean used; /* Whether this entry was used. */
- boolean remove; /* Whether to remove this section. */
- boolean copy; /* Whether to copy this section. */
- enum change_action change_vma;/* Whether to change or set VMA. */
- bfd_vma vma_val; /* Amount to change by or set to. */
- enum change_action change_lma;/* Whether to change or set LMA. */
- bfd_vma lma_val; /* Amount to change by or set to. */
- boolean set_flags; /* Whether to set the section flags. */
- flagword flags; /* What to set the section flags to. */
+ struct section_list * next; /* Next section to change. */
+ const char * name; /* Section name. */
+ bfd_boolean used; /* Whether this entry was used. */
+ bfd_boolean remove; /* Whether to remove this section. */
+ bfd_boolean copy; /* Whether to copy this section. */
+ enum change_action change_vma;/* Whether to change or set VMA. */
+ bfd_vma vma_val; /* Amount to change by or set to. */
+ enum change_action change_lma;/* Whether to change or set LMA. */
+ bfd_vma lma_val; /* Amount to change by or set to. */
+ bfd_boolean set_flags; /* Whether to set the section flags. */
+ flagword flags; /* What to set the section flags to. */
};
static struct section_list *change_sections;
-/* True if some sections are to be removed. */
-static boolean sections_removed;
+/* TRUE if some sections are to be removed. */
+static bfd_boolean sections_removed;
-/* True if only some sections are to be copied. */
-static boolean sections_copied;
+/* TRUE if only some sections are to be copied. */
+static bfd_boolean sections_copied;
/* Changes to the start address. */
static bfd_vma change_start = 0;
-static boolean set_start_set = false;
+static bfd_boolean set_start_set = FALSE;
static bfd_vma set_start;
/* Changes to section addresses. */
static bfd_vma change_section_address = 0;
/* Filling gaps between sections. */
-static boolean gap_fill_set = false;
+static bfd_boolean gap_fill_set = FALSE;
static bfd_byte gap_fill = 0;
/* Pad to a given address. */
-static boolean pad_to_set = false;
+static bfd_boolean pad_to_set = FALSE;
static bfd_vma pad_to;
/* Use alternate machine code? */
static int use_alt_mach_code = 0;
+/* Output BFD flags user wants to set or clear */
+static flagword bfd_flags_to_set;
+static flagword bfd_flags_to_clear;
+
/* List of sections to add. */
struct section_add
{
@@ -194,14 +173,21 @@ struct section_add
/* List of sections to add to the output BFD. */
static struct section_add *add_sections;
+/* If non-NULL the argument to --add-gnu-debuglink.
+ This should be the filename to store in the .gnu_debuglink section. */
+static const char * gnu_debuglink_filename = NULL;
+
/* Whether to convert debugging information. */
-static boolean convert_debugging = false;
+static bfd_boolean convert_debugging = FALSE;
/* Whether to change the leading character in symbol names. */
-static boolean change_leading_char = false;
+static bfd_boolean change_leading_char = FALSE;
/* Whether to remove the leading character from global symbol names. */
-static boolean remove_leading_char = false;
+static bfd_boolean remove_leading_char = FALSE;
+
+/* Whether to permit wildcard in symbol comparison. */
+static bfd_boolean wildcard = FALSE;
/* List of symbols to strip, keep, localize, keep-global, weaken,
or redefine. */
@@ -212,38 +198,56 @@ static struct symlist *keepglobal_specific_list = NULL;
static struct symlist *weaken_specific_list = NULL;
static struct redefine_node *redefine_sym_list = NULL;
-/* If this is true, we weaken global symbols (set BSF_WEAK). */
-static boolean weaken = false;
+/* If this is TRUE, we weaken global symbols (set BSF_WEAK). */
+static bfd_boolean weaken = FALSE;
-/* 150 isn't special; it's just an arbitrary non-ASCII char value. */
+/* Prefix symbols/sections. */
+static char *prefix_symbols_string = 0;
+static char *prefix_sections_string = 0;
+static char *prefix_alloc_sections_string = 0;
-#define OPTION_ADD_SECTION 150
-#define OPTION_CHANGE_ADDRESSES (OPTION_ADD_SECTION + 1)
-#define OPTION_CHANGE_LEADING_CHAR (OPTION_CHANGE_ADDRESSES + 1)
-#define OPTION_CHANGE_START (OPTION_CHANGE_LEADING_CHAR + 1)
-#define OPTION_CHANGE_SECTION_ADDRESS (OPTION_CHANGE_START + 1)
-#define OPTION_CHANGE_SECTION_LMA (OPTION_CHANGE_SECTION_ADDRESS + 1)
-#define OPTION_CHANGE_SECTION_VMA (OPTION_CHANGE_SECTION_LMA + 1)
-#define OPTION_CHANGE_WARNINGS (OPTION_CHANGE_SECTION_VMA + 1)
-#define OPTION_DEBUGGING (OPTION_CHANGE_WARNINGS + 1)
-#define OPTION_GAP_FILL (OPTION_DEBUGGING + 1)
-#define OPTION_NO_CHANGE_WARNINGS (OPTION_GAP_FILL + 1)
-#define OPTION_PAD_TO (OPTION_NO_CHANGE_WARNINGS + 1)
-#define OPTION_REMOVE_LEADING_CHAR (OPTION_PAD_TO + 1)
-#define OPTION_SET_SECTION_FLAGS (OPTION_REMOVE_LEADING_CHAR + 1)
-#define OPTION_SET_START (OPTION_SET_SECTION_FLAGS + 1)
-#define OPTION_STRIP_UNNEEDED (OPTION_SET_START + 1)
-#define OPTION_WEAKEN (OPTION_STRIP_UNNEEDED + 1)
-#define OPTION_REDEFINE_SYM (OPTION_WEAKEN + 1)
-#define OPTION_SREC_LEN (OPTION_REDEFINE_SYM + 1)
-#define OPTION_SREC_FORCES3 (OPTION_SREC_LEN + 1)
-#define OPTION_STRIP_SYMBOLS (OPTION_SREC_FORCES3 + 1)
-#define OPTION_KEEP_SYMBOLS (OPTION_STRIP_SYMBOLS + 1)
-#define OPTION_LOCALIZE_SYMBOLS (OPTION_KEEP_SYMBOLS + 1)
-#define OPTION_KEEPGLOBAL_SYMBOLS (OPTION_LOCALIZE_SYMBOLS + 1)
-#define OPTION_WEAKEN_SYMBOLS (OPTION_KEEPGLOBAL_SYMBOLS + 1)
-#define OPTION_RENAME_SECTION (OPTION_WEAKEN_SYMBOLS + 1)
-#define OPTION_ALT_MACH_CODE (OPTION_RENAME_SECTION + 1)
+/* 150 isn't special; it's just an arbitrary non-ASCII char value. */
+enum command_line_switch
+ {
+ OPTION_ADD_SECTION=150,
+ OPTION_CHANGE_ADDRESSES,
+ OPTION_CHANGE_LEADING_CHAR,
+ OPTION_CHANGE_START,
+ OPTION_CHANGE_SECTION_ADDRESS,
+ OPTION_CHANGE_SECTION_LMA,
+ OPTION_CHANGE_SECTION_VMA,
+ OPTION_CHANGE_WARNINGS,
+ OPTION_DEBUGGING,
+ OPTION_GAP_FILL,
+ OPTION_NO_CHANGE_WARNINGS,
+ OPTION_PAD_TO,
+ OPTION_REMOVE_LEADING_CHAR,
+ OPTION_SET_SECTION_FLAGS,
+ OPTION_SET_START,
+ OPTION_STRIP_UNNEEDED,
+ OPTION_WEAKEN,
+ OPTION_REDEFINE_SYM,
+ OPTION_REDEFINE_SYMS,
+ OPTION_SREC_LEN,
+ OPTION_SREC_FORCES3,
+ OPTION_STRIP_SYMBOLS,
+ OPTION_KEEP_SYMBOLS,
+ OPTION_LOCALIZE_SYMBOLS,
+ OPTION_KEEPGLOBAL_SYMBOLS,
+ OPTION_WEAKEN_SYMBOLS,
+ OPTION_RENAME_SECTION,
+ OPTION_ALT_MACH_CODE,
+ OPTION_PREFIX_SYMBOLS,
+ OPTION_PREFIX_SECTIONS,
+ OPTION_PREFIX_ALLOC_SECTIONS,
+ OPTION_FORMATS_INFO,
+ OPTION_ADD_GNU_DEBUGLINK,
+ OPTION_ONLY_KEEP_DEBUG,
+ OPTION_READONLY_TEXT,
+ OPTION_WRITABLE_TEXT,
+ OPTION_PURE,
+ OPTION_IMPURE
+ };
/* Options to handle if running as "strip". */
@@ -253,9 +257,11 @@ static struct option strip_options[] =
{"discard-locals", no_argument, 0, 'X'},
{"format", required_argument, 0, 'F'}, /* Obsolete */
{"help", no_argument, 0, 'h'},
+ {"info", no_argument, 0, OPTION_FORMATS_INFO},
{"input-format", required_argument, 0, 'I'}, /* Obsolete */
{"input-target", required_argument, 0, 'I'},
{"keep-symbol", required_argument, 0, 'K'},
+ {"only-keep-debug", no_argument, 0, OPTION_ONLY_KEEP_DEBUG},
{"output-format", required_argument, 0, 'O'}, /* Obsolete */
{"output-target", required_argument, 0, 'O'},
{"output-file", required_argument, 0, 'o'},
@@ -268,6 +274,7 @@ static struct option strip_options[] =
{"target", required_argument, 0, 'F'},
{"verbose", no_argument, 0, 'v'},
{"version", no_argument, 0, 'V'},
+ {"wildcard", no_argument, 0, 'w'},
{0, no_argument, 0, 0}
};
@@ -275,11 +282,13 @@ static struct option strip_options[] =
static struct option copy_options[] =
{
+ {"add-gnu-debuglink", required_argument, 0, OPTION_ADD_GNU_DEBUGLINK},
{"add-section", required_argument, 0, OPTION_ADD_SECTION},
{"adjust-start", required_argument, 0, OPTION_CHANGE_START},
{"adjust-vma", required_argument, 0, OPTION_CHANGE_ADDRESSES},
{"adjust-section-vma", required_argument, 0, OPTION_CHANGE_SECTION_ADDRESS},
{"adjust-warnings", no_argument, 0, OPTION_CHANGE_WARNINGS},
+ {"alt-machine-code", required_argument, 0, OPTION_ALT_MACH_CODE},
{"binary-architecture", required_argument, 0, 'B'},
{"byte", required_argument, 0, 'b'},
{"change-addresses", required_argument, 0, OPTION_CHANGE_ADDRESSES},
@@ -292,45 +301,55 @@ static struct option copy_options[] =
{"debugging", no_argument, 0, OPTION_DEBUGGING},
{"discard-all", no_argument, 0, 'x'},
{"discard-locals", no_argument, 0, 'X'},
- {"only-section", required_argument, 0, 'j'},
{"format", required_argument, 0, 'F'}, /* Obsolete */
{"gap-fill", required_argument, 0, OPTION_GAP_FILL},
{"help", no_argument, 0, 'h'},
+ {"impure", no_argument, 0, OPTION_IMPURE},
+ {"info", no_argument, 0, OPTION_FORMATS_INFO},
{"input-format", required_argument, 0, 'I'}, /* Obsolete */
{"input-target", required_argument, 0, 'I'},
{"interleave", required_argument, 0, 'i'},
+ {"keep-global-symbol", required_argument, 0, 'G'},
+ {"keep-global-symbols", required_argument, 0, OPTION_KEEPGLOBAL_SYMBOLS},
{"keep-symbol", required_argument, 0, 'K'},
+ {"keep-symbols", required_argument, 0, OPTION_KEEP_SYMBOLS},
+ {"localize-symbol", required_argument, 0, 'L'},
+ {"localize-symbols", required_argument, 0, OPTION_LOCALIZE_SYMBOLS},
{"no-adjust-warnings", no_argument, 0, OPTION_NO_CHANGE_WARNINGS},
{"no-change-warnings", no_argument, 0, OPTION_NO_CHANGE_WARNINGS},
+ {"only-keep-debug", no_argument, 0, OPTION_ONLY_KEEP_DEBUG},
+ {"only-section", required_argument, 0, 'j'},
{"output-format", required_argument, 0, 'O'}, /* Obsolete */
{"output-target", required_argument, 0, 'O'},
{"pad-to", required_argument, 0, OPTION_PAD_TO},
+ {"prefix-symbols", required_argument, 0, OPTION_PREFIX_SYMBOLS},
+ {"prefix-sections", required_argument, 0, OPTION_PREFIX_SECTIONS},
+ {"prefix-alloc-sections", required_argument, 0, OPTION_PREFIX_ALLOC_SECTIONS},
{"preserve-dates", no_argument, 0, 'p'},
- {"localize-symbol", required_argument, 0, 'L'},
- {"keep-global-symbol", required_argument, 0, 'G'},
+ {"pure", no_argument, 0, OPTION_PURE},
+ {"readonly-text", no_argument, 0, OPTION_READONLY_TEXT},
+ {"redefine-sym", required_argument, 0, OPTION_REDEFINE_SYM},
+ {"redefine-syms", required_argument, 0, OPTION_REDEFINE_SYMS},
{"remove-leading-char", no_argument, 0, OPTION_REMOVE_LEADING_CHAR},
{"remove-section", required_argument, 0, 'R'},
{"rename-section", required_argument, 0, OPTION_RENAME_SECTION},
{"set-section-flags", required_argument, 0, OPTION_SET_SECTION_FLAGS},
{"set-start", required_argument, 0, OPTION_SET_START},
+ {"srec-len", required_argument, 0, OPTION_SREC_LEN},
+ {"srec-forceS3", no_argument, 0, OPTION_SREC_FORCES3},
{"strip-all", no_argument, 0, 'S'},
{"strip-debug", no_argument, 0, 'g'},
{"strip-unneeded", no_argument, 0, OPTION_STRIP_UNNEEDED},
{"strip-symbol", required_argument, 0, 'N'},
+ {"strip-symbols", required_argument, 0, OPTION_STRIP_SYMBOLS},
{"target", required_argument, 0, 'F'},
{"verbose", no_argument, 0, 'v'},
{"version", no_argument, 0, 'V'},
{"weaken", no_argument, 0, OPTION_WEAKEN},
{"weaken-symbol", required_argument, 0, 'W'},
- {"redefine-sym", required_argument, 0, OPTION_REDEFINE_SYM},
- {"srec-len", required_argument, 0, OPTION_SREC_LEN},
- {"srec-forceS3", no_argument, 0, OPTION_SREC_FORCES3},
- {"keep-symbols", required_argument, 0, OPTION_KEEP_SYMBOLS},
- {"strip-symbols", required_argument, 0, OPTION_STRIP_SYMBOLS},
- {"keep-global-symbols", required_argument, 0, OPTION_KEEPGLOBAL_SYMBOLS},
- {"localize-symbols", required_argument, 0, OPTION_LOCALIZE_SYMBOLS},
{"weaken-symbols", required_argument, 0, OPTION_WEAKEN_SYMBOLS},
- {"alt-machine-code", required_argument, 0, OPTION_ALT_MACH_CODE},
+ {"wildcard", no_argument, 0, 'w'},
+ {"writable-text", no_argument, 0, OPTION_WRITABLE_TEXT},
{0, no_argument, 0, 0}
};
@@ -349,16 +368,24 @@ extern unsigned int Chunk;
/* Restrict the generation of Srecords to type S3 only.
This variable is declare in bfd/srec.c and can be toggled
on by the --srec-forceS3 command line switch. */
-extern boolean S3Forced;
-
-/* Defined in bfd/binary.c. Used to set architecture of input binary files. */
-extern enum bfd_architecture bfd_external_binary_architecture;
-
+extern bfd_boolean S3Forced;
+
+/* Defined in bfd/binary.c. Used to set architecture and machine of input
+ binary files. */
+extern enum bfd_architecture bfd_external_binary_architecture;
+extern unsigned long bfd_external_machine;
+
+/* Forward declarations. */
+static void setup_section (bfd *, asection *, void *);
+static void copy_section (bfd *, asection *, void *);
+static void get_sections (bfd *, asection *, void *);
+static int compare_section_lma (const void *, const void *);
+static void mark_symbols_used_in_relocations (bfd *, asection *, void *);
+static bfd_boolean write_debugging_info (bfd *, void *, long *, asymbol ***);
+static const char *lookup_sym_redefinition (const char *);
static void
-copy_usage (stream, exit_status)
- FILE *stream;
- int exit_status;
+copy_usage (FILE *stream, int exit_status)
{
fprintf (stream, _("Usage: %s [option(s)] in-file [out-file]\n"), program_name);
fprintf (stream, _(" Copies a binary file, possibly transforming it in the process\n"));
@@ -371,16 +398,19 @@ copy_usage (stream, exit_status)
--debugging Convert debugging information, if possible\n\
-p --preserve-dates Copy modified/access timestamps to the output\n\
-j --only-section <name> Only copy section <name> into the output\n\
+ --add-gnu-debuglink=<file> Add section .gnu_debuglink linking to <file>\n\
-R --remove-section <name> Remove section <name> from the output\n\
-S --strip-all Remove all symbol and relocation information\n\
- -g --strip-debug Remove all debugging symbols\n\
+ -g --strip-debug Remove all debugging symbols & sections\n\
--strip-unneeded Remove all symbols not needed by relocations\n\
-N --strip-symbol <name> Do not copy symbol <name>\n\
+ --only-keep-debug Strip everything but the debug information\n\
-K --keep-symbol <name> Only copy symbol <name>\n\
-L --localize-symbol <name> Force symbol <name> to be marked as a local\n\
-G --keep-global-symbol <name> Localize all symbols except <name>\n\
-W --weaken-symbol <name> Force symbol <name> to be marked as a weak\n\
--weaken Force all global symbols to be marked as weak\n\
+ -w --wildcard Permit wildcard in symbol comparasion\n\
-x --discard-all Remove all non-global symbols\n\
-X --discard-locals Remove any compiler-generated symbols\n\
-i --interleave <number> Only copy one out of every <number> bytes\n\
@@ -407,6 +437,8 @@ copy_usage (stream, exit_status)
--change-leading-char Force output format's leading character style\n\
--remove-leading-char Remove leading character from global symbols\n\
--redefine-sym <old>=<new> Redefine symbol name <old> to <new>\n\
+ --redefine-syms <file> --redefine-sym for all symbol pairs \n\
+ listed in <file>\n\
--srec-len <number> Restrict the length of generated Srecords\n\
--srec-forceS3 Restrict the type of generated Srecords to S3\n\
--strip-symbols <file> -N for all symbols listed in <file>\n\
@@ -415,9 +447,19 @@ copy_usage (stream, exit_status)
--keep-global-symbols <file> -G for all symbols listed in <file>\n\
--weaken-symbols <file> -W for all symbols listed in <file>\n\
--alt-machine-code <index> Use alternate machine code for output\n\
+ --writable-text Mark the output text as writable\n\
+ --readonly-text Make the output text write protected\n\
+ --pure Mark the output file as demand paged\n\
+ --impure Mark the output file as impure\n\
+ --prefix-symbols <prefix> Add <prefix> to start of every symbol name\n\
+ --prefix-sections <prefix> Add <prefix> to start of every section name\n\
+ --prefix-alloc-sections <prefix>\n\
+ Add <prefix> to start of every allocatable\n\
+ section name\n\
-v --verbose List all object files modified\n\
-V --version Display this program's version number\n\
-h --help Display this output\n\
+ --info List object formats & architectures supported\n\
"));
list_supported_targets (program_name, stream);
if (exit_status == 0)
@@ -426,9 +468,7 @@ copy_usage (stream, exit_status)
}
static void
-strip_usage (stream, exit_status)
- FILE *stream;
- int exit_status;
+strip_usage (FILE *stream, int exit_status)
{
fprintf (stream, _("Usage: %s <option(s)> in-file(s)\n"), program_name);
fprintf (stream, _(" Removes symbols and sections from files\n"));
@@ -440,15 +480,18 @@ strip_usage (stream, exit_status)
-p --preserve-dates Copy modified/access timestamps to the output\n\
-R --remove-section=<name> Remove section <name> from the output\n\
-s --strip-all Remove all symbol and relocation information\n\
- -g -S -d --strip-debug Remove all debugging symbols\n\
+ -g -S -d --strip-debug Remove all debugging symbols & sections\n\
--strip-unneeded Remove all symbols not needed by relocations\n\
+ --only-keep-debug Strip everything but the debug information\n\
-N --strip-symbol=<name> Do not copy symbol <name>\n\
-K --keep-symbol=<name> Only copy symbol <name>\n\
+ -w --wildcard Permit wildcard in symbol comparasion\n\
-x --discard-all Remove all non-global symbols\n\
-X --discard-locals Remove any compiler-generated symbols\n\
-v --verbose List all object files modified\n\
-V --version Display this program's version number\n\
-h --help Display this output\n\
+ --info List object formats & architectures supported\n\
-o <file> Place stripped output into <file>\n\
"));
@@ -462,8 +505,7 @@ strip_usage (stream, exit_status)
string can't be parsed. */
static flagword
-parse_flags (s)
- const char *s;
+parse_flags (const char *s)
{
flagword ret;
const char *snext;
@@ -518,11 +560,9 @@ parse_flags (s)
/* Find and optionally add an entry in the change_sections list. */
static struct section_list *
-find_section_list (name, add)
- const char *name;
- boolean add;
+find_section_list (const char *name, bfd_boolean add)
{
- register struct section_list *p;
+ struct section_list *p;
for (p = change_sections; p != NULL; p = p->next)
if (strcmp (p->name, name) == 0)
@@ -531,16 +571,16 @@ find_section_list (name, add)
if (! add)
return NULL;
- p = (struct section_list *) xmalloc (sizeof (struct section_list));
+ p = xmalloc (sizeof (struct section_list));
p->name = name;
- p->used = false;
- p->remove = false;
- p->copy = false;
+ p->used = FALSE;
+ p->remove = FALSE;
+ p->copy = FALSE;
p->change_vma = CHANGE_IGNORE;
p->change_lma = CHANGE_IGNORE;
p->vma_val = 0;
p->lma_val = 0;
- p->set_flags = false;
+ p->set_flags = FALSE;
p->flags = 0;
p->next = change_sections;
@@ -552,13 +592,11 @@ find_section_list (name, add)
/* Add a symbol to strip_specific_list. */
static void
-add_specific_symbol (name, list)
- const char *name;
- struct symlist **list;
+add_specific_symbol (const char *name, struct symlist **list)
{
struct symlist *tmp_list;
- tmp_list = (struct symlist *) xmalloc (sizeof (struct symlist));
+ tmp_list = xmalloc (sizeof (struct symlist));
tmp_list->name = name;
tmp_list->next = *list;
*list = tmp_list;
@@ -570,32 +608,29 @@ add_specific_symbol (name, list)
#define IS_LINE_TERMINATOR(c) ((c) == '\n' || (c) == '\r' || (c) == '\0')
static void
-add_specific_symbols (filename, list)
- const char *filename;
- struct symlist **list;
+add_specific_symbols (const char *filename, struct symlist **list)
{
- struct stat st;
+ off_t size;
FILE * f;
char * line;
char * buffer;
unsigned int line_count;
- if (stat (filename, & st) < 0)
- fatal (_("cannot stat: %s: %s"), filename, strerror (errno));
- if (st.st_size == 0)
+ size = get_file_size (filename);
+ if (size == 0)
return;
- buffer = (char *) xmalloc (st.st_size + 2);
+ buffer = xmalloc (size + 2);
f = fopen (filename, FOPEN_RT);
if (f == NULL)
- fatal (_("cannot open: %s: %s"), filename, strerror (errno));
+ fatal (_("cannot open '%s': %s"), filename, strerror (errno));
- if (fread (buffer, 1, st.st_size, f) == 0 || ferror (f))
+ if (fread (buffer, 1, size, f) == 0 || ferror (f))
fatal (_("%s: fread failed"), filename);
fclose (f);
- buffer [st.st_size] = '\n';
- buffer [st.st_size + 1] = '\0';
+ buffer [size] = '\n';
+ buffer [size + 1] = '\0';
line_count = 1;
@@ -604,7 +639,7 @@ add_specific_symbols (filename, list)
char * eol;
char * name;
char * name_end;
- int finished = false;
+ int finished = FALSE;
for (eol = line;; eol ++)
{
@@ -615,7 +650,7 @@ add_specific_symbols (filename, list)
/* Cope with \n\r. */
if (eol[1] == '\r')
++ eol;
- finished = true;
+ finished = TRUE;
break;
case '\r':
@@ -623,11 +658,11 @@ add_specific_symbols (filename, list)
/* Cope with \r\n. */
if (eol[1] == '\n')
++ eol;
- finished = true;
+ finished = TRUE;
break;
case 0:
- finished = true;
+ finished = TRUE;
break;
case '#':
@@ -683,46 +718,66 @@ add_specific_symbols (filename, list)
/* See whether a symbol should be stripped or kept based on
strip_specific_list and keep_symbols. */
-static boolean
-is_specified_symbol (name, list)
- const char *name;
- struct symlist *list;
+static bfd_boolean
+is_specified_symbol (const char *name, struct symlist *list)
{
struct symlist *tmp_list;
- for (tmp_list = list; tmp_list; tmp_list = tmp_list->next)
- if (strcmp (name, tmp_list->name) == 0)
- return true;
+ if (wildcard)
+ {
+ for (tmp_list = list; tmp_list; tmp_list = tmp_list->next)
+ if (*(tmp_list->name) != '!')
+ {
+ if (!fnmatch (tmp_list->name, name, 0))
+ return TRUE;
+ }
+ else
+ {
+ if (fnmatch (tmp_list->name + 1, name, 0))
+ return TRUE;
+ }
+ }
+ else
+ {
+ for (tmp_list = list; tmp_list; tmp_list = tmp_list->next)
+ if (strcmp (name, tmp_list->name) == 0)
+ return TRUE;
+ }
- return false;
+ return FALSE;
}
/* See if a section is being removed. */
-static boolean
-is_strip_section (abfd, sec)
- bfd *abfd ATTRIBUTE_UNUSED;
- asection *sec;
+static bfd_boolean
+is_strip_section (bfd *abfd ATTRIBUTE_UNUSED, asection *sec)
{
- struct section_list *p;
+ if (sections_removed || sections_copied)
+ {
+ struct section_list *p;
+
+ p = find_section_list (bfd_get_section_name (abfd, sec), FALSE);
- if ((bfd_get_section_flags (abfd, sec) & SEC_DEBUGGING) != 0
- && (strip_symbols == STRIP_DEBUG
+ if (sections_removed && p != NULL && p->remove)
+ return TRUE;
+ if (sections_copied && (p == NULL || ! p->copy))
+ return TRUE;
+ }
+
+ if ((bfd_get_section_flags (abfd, sec) & SEC_DEBUGGING) != 0)
+ {
+ if (strip_symbols == STRIP_DEBUG
|| strip_symbols == STRIP_UNNEEDED
|| strip_symbols == STRIP_ALL
|| discard_locals == LOCALS_ALL
- || convert_debugging))
- return true;
-
- if (! sections_removed && ! sections_copied)
- return false;
-
- p = find_section_list (bfd_get_section_name (abfd, sec), false);
- if (sections_removed && p != NULL && p->remove)
- return true;
- if (sections_copied && (p == NULL || ! p->copy))
- return true;
- return false;
+ || convert_debugging)
+ return TRUE;
+
+ if (strip_symbols == STRIP_NONDEBUG)
+ return FALSE;
+ }
+
+ return FALSE;
}
/* Choose which symbol entries to copy; put the result in OSYMS.
@@ -730,13 +785,10 @@ is_strip_section (abfd, sec)
Return the number of symbols to print. */
static unsigned int
-filter_symbols (abfd, obfd, osyms, isyms, symcount)
- bfd *abfd;
- bfd *obfd;
- asymbol **osyms, **isyms;
- long symcount;
+filter_symbols (bfd *abfd, bfd *obfd, asymbol **osyms,
+ asymbol **isyms, long symcount)
{
- register asymbol **from = isyms, **to = osyms;
+ asymbol **from = isyms, **to = osyms;
long src_count = 0, dst_count = 0;
int relocatable = (abfd->flags & (HAS_RELOC | EXEC_P | DYNAMIC))
== HAS_RELOC;
@@ -745,51 +797,74 @@ filter_symbols (abfd, obfd, osyms, isyms, symcount)
{
asymbol *sym = from[src_count];
flagword flags = sym->flags;
- const char *name = bfd_asymbol_name (sym);
+ char *name = (char *) bfd_asymbol_name (sym);
int keep;
- boolean undefined;
+ bfd_boolean undefined;
+ bfd_boolean rem_leading_char;
+ bfd_boolean add_leading_char;
+
+ undefined = bfd_is_und_section (bfd_get_section (sym));
if (redefine_sym_list)
{
- const char *old_name, *new_name;
+ char *old_name, *new_name;
- old_name = bfd_asymbol_name (sym);
- new_name = lookup_sym_redefinition (old_name);
- name = bfd_asymbol_name (sym) = new_name;
+ old_name = (char *) bfd_asymbol_name (sym);
+ new_name = (char *) lookup_sym_redefinition (old_name);
+ bfd_asymbol_name (sym) = new_name;
+ name = new_name;
}
- if (change_leading_char
- && (bfd_get_symbol_leading_char (abfd)
- != bfd_get_symbol_leading_char (obfd))
- && (bfd_get_symbol_leading_char (abfd) == '\0'
- || (name[0] == bfd_get_symbol_leading_char (abfd))))
- {
- if (bfd_get_symbol_leading_char (obfd) == '\0')
- name = bfd_asymbol_name (sym) = name + 1;
- else
- {
- char *n;
-
- n = xmalloc (strlen (name) + 2);
- n[0] = bfd_get_symbol_leading_char (obfd);
- if (bfd_get_symbol_leading_char (abfd) == '\0')
- strcpy (n + 1, name);
- else
- strcpy (n + 1, name + 1);
- name = bfd_asymbol_name (sym) = n;
- }
+ /* Check if we will remove the current leading character. */
+ rem_leading_char =
+ (name[0] == bfd_get_symbol_leading_char (abfd))
+ && (change_leading_char
+ || (remove_leading_char
+ && ((flags & (BSF_GLOBAL | BSF_WEAK)) != 0
+ || undefined
+ || bfd_is_com_section (bfd_get_section (sym)))));
+
+ /* Check if we will add a new leading character. */
+ add_leading_char =
+ change_leading_char
+ && (bfd_get_symbol_leading_char (obfd) != '\0')
+ && (bfd_get_symbol_leading_char (abfd) == '\0'
+ || (name[0] == bfd_get_symbol_leading_char (abfd)));
+
+ /* Short circuit for change_leading_char if we can do it in-place. */
+ if (rem_leading_char && add_leading_char && !prefix_symbols_string)
+ {
+ name[0] = bfd_get_symbol_leading_char (obfd);
+ bfd_asymbol_name (sym) = name;
+ rem_leading_char = FALSE;
+ add_leading_char = FALSE;
+ }
+
+ /* Remove leading char. */
+ if (rem_leading_char)
+ bfd_asymbol_name (sym) = ++name;
+
+ /* Add new leading char and/or prefix. */
+ if (add_leading_char || prefix_symbols_string)
+ {
+ char *n, *ptr;
+
+ ptr = n = xmalloc (1 + strlen (prefix_symbols_string)
+ + strlen (name) + 1);
+ if (add_leading_char)
+ *ptr++ = bfd_get_symbol_leading_char (obfd);
+
+ if (prefix_symbols_string)
+ {
+ strcpy (ptr, prefix_symbols_string);
+ ptr += strlen (prefix_symbols_string);
+ }
+
+ strcpy (ptr, name);
+ bfd_asymbol_name (sym) = n;
+ name = n;
}
- undefined = bfd_is_und_section (bfd_get_section (sym));
-
- if (remove_leading_char
- && ((flags & BSF_GLOBAL) != 0
- || (flags & BSF_WEAK) != 0
- || undefined
- || bfd_is_com_section (bfd_get_section (sym)))
- && name[0] == bfd_get_symbol_leading_char (abfd))
- name = bfd_asymbol_name (sym) = name + 1;
-
if (strip_symbols == STRIP_ALL)
keep = 0;
else if ((flags & BSF_KEEP) != 0 /* Used in relocation. */
@@ -802,7 +877,7 @@ filter_symbols (abfd, obfd, osyms, isyms, symcount)
keep = 1;
else if (bfd_decode_symclass (sym) == 'I')
/* Global symbols in $idata sections need to be retained
- even if relocatable is false. External users of the
+ even if relocatable is FALSE. External users of the
library containing the $idata section may reference these
symbols. */
keep = 1;
@@ -859,8 +934,7 @@ filter_symbols (abfd, obfd, osyms, isyms, symcount)
/* Find the redefined name of symbol SOURCE. */
static const char *
-lookup_sym_redefinition (source)
- const char *source;
+lookup_sym_redefinition (const char *source)
{
struct redefine_node *list;
@@ -874,9 +948,7 @@ lookup_sym_redefinition (source)
/* Add a node to a symbol redefine list. */
static void
-redefine_list_append (source, target)
- const char *source;
- const char *target;
+redefine_list_append (const char *cause, const char *source, const char *target)
{
struct redefine_node **p;
struct redefine_node *list;
@@ -886,16 +958,14 @@ redefine_list_append (source, target)
{
if (strcmp (source, list->source) == 0)
fatal (_("%s: Multiple redefinition of symbol \"%s\""),
- "--redefine-sym",
- source);
+ cause, source);
if (strcmp (target, list->target) == 0)
fatal (_("%s: Symbol \"%s\" is target of more than one redefinition"),
- "--redefine-sym",
- target);
+ cause, target);
}
- new_node = (struct redefine_node *) xmalloc (sizeof (struct redefine_node));
+ new_node = xmalloc (sizeof (struct redefine_node));
new_node->source = strdup (source);
new_node->target = strdup (target);
@@ -904,50 +974,144 @@ redefine_list_append (source, target)
*p = new_node;
}
-/* Keep only every `copy_byte'th byte in MEMHUNK, which is *SIZE bytes long.
- Adjust *SIZE. */
+/* Handle the --redefine-syms option. Read lines containing "old new"
+ from the file, and add them to the symbol redefine list. */
static void
-filter_bytes (memhunk, size)
- char *memhunk;
- bfd_size_type *size;
+add_redefine_syms_file (const char *filename)
{
- char *from = memhunk + copy_byte, *to = memhunk, *end = memhunk + *size;
+ FILE *file;
+ char *buf;
+ size_t bufsize;
+ size_t len;
+ size_t outsym_off;
+ int c, lineno;
+
+ file = fopen (filename, "r");
+ if (file == NULL)
+ fatal (_("couldn't open symbol redefinition file %s (error: %s)"),
+ filename, strerror (errno));
+
+ bufsize = 100;
+ buf = xmalloc (bufsize);
+
+ lineno = 1;
+ c = getc (file);
+ len = 0;
+ outsym_off = 0;
+ while (c != EOF)
+ {
+ /* Collect the input symbol name. */
+ while (! IS_WHITESPACE (c) && ! IS_LINE_TERMINATOR (c) && c != EOF)
+ {
+ if (c == '#')
+ goto comment;
+ buf[len++] = c;
+ if (len >= bufsize)
+ {
+ bufsize *= 2;
+ buf = xrealloc (buf, bufsize);
+ }
+ c = getc (file);
+ }
+ buf[len++] = '\0';
+ if (c == EOF)
+ break;
+
+ /* Eat white space between the symbol names. */
+ while (IS_WHITESPACE (c))
+ c = getc (file);
+ if (c == '#' || IS_LINE_TERMINATOR (c))
+ goto comment;
+ if (c == EOF)
+ break;
+
+ /* Collect the output symbol name. */
+ outsym_off = len;
+ while (! IS_WHITESPACE (c) && ! IS_LINE_TERMINATOR (c) && c != EOF)
+ {
+ if (c == '#')
+ goto comment;
+ buf[len++] = c;
+ if (len >= bufsize)
+ {
+ bufsize *= 2;
+ buf = xrealloc (buf, bufsize);
+ }
+ c = getc (file);
+ }
+ buf[len++] = '\0';
+ if (c == EOF)
+ break;
+
+ /* Eat white space at end of line. */
+ while (! IS_LINE_TERMINATOR(c) && c != EOF && IS_WHITESPACE (c))
+ c = getc (file);
+ if (c == '#')
+ goto comment;
+ /* Handle \r\n. */
+ if ((c == '\r' && (c = getc (file)) == '\n')
+ || c == '\n' || c == EOF)
+ {
+ end_of_line:
+ /* Append the redefinition to the list. */
+ if (buf[0] != '\0')
+ redefine_list_append (filename, &buf[0], &buf[outsym_off]);
+
+ lineno++;
+ len = 0;
+ outsym_off = 0;
+ if (c == EOF)
+ break;
+ c = getc (file);
+ continue;
+ }
+ else
+ fatal (_("%s: garbage at end of line %d"), filename, lineno);
+ comment:
+ if (len != 0 && (outsym_off == 0 || outsym_off == len))
+ fatal (_("%s: missing new symbol name at line %d"), filename, lineno);
+ buf[len++] = '\0';
+
+ /* Eat the rest of the line and finish it. */
+ while (c != '\n' && c != EOF)
+ c = getc (file);
+ goto end_of_line;
+ }
- for (; from < end; from += interleave)
- *to++ = *from;
+ if (len != 0)
+ fatal (_("%s: premature end of file at line %d"), filename, lineno);
- if (*size % interleave > (bfd_size_type) copy_byte)
- *size = (*size / interleave) + 1;
- else
- *size /= interleave;
+ free (buf);
}
-/* Copy object file IBFD onto OBFD. */
+/* Copy object file IBFD onto OBFD.
+ Returns TRUE upon success, FALSE otherwise. */
-static void
-copy_object (ibfd, obfd)
- bfd *ibfd;
- bfd *obfd;
+static bfd_boolean
+copy_object (bfd *ibfd, bfd *obfd)
{
bfd_vma start;
long symcount;
asection **osections = NULL;
+ asection *gnu_debuglink_section = NULL;
bfd_size_type *gaps = NULL;
bfd_size_type max_gap = 0;
long symsize;
- PTR dhandle;
+ void *dhandle;
+ enum bfd_architecture iarch;
+ unsigned int imach;
if (ibfd->xvec->byteorder != obfd->xvec->byteorder
&& ibfd->xvec->byteorder != BFD_ENDIAN_UNKNOWN
&& obfd->xvec->byteorder != BFD_ENDIAN_UNKNOWN)
- {
- fatal (_("Unable to change endianness of input file(s)"));
- return;
- }
+ fatal (_("Unable to change endianness of input file(s)"));
if (!bfd_set_format (obfd, bfd_get_format (ibfd)))
- RETURN_NONFATAL (bfd_get_filename (obfd));
+ {
+ bfd_nonfatal (bfd_get_filename (obfd));
+ return FALSE;
+ }
if (verbose)
printf (_("copy from %s(%s) to %s(%s)\n"),
@@ -964,22 +1128,45 @@ copy_object (ibfd, obfd)
need to be set for a core file. */
if (bfd_get_format (obfd) != bfd_core)
{
+ flagword flags;
+
+ flags = bfd_get_file_flags (ibfd);
+ flags |= bfd_flags_to_set;
+ flags &= ~bfd_flags_to_clear;
+ flags &= bfd_applicable_file_flags (obfd);
+
if (!bfd_set_start_address (obfd, start)
- || !bfd_set_file_flags (obfd,
- (bfd_get_file_flags (ibfd)
- & bfd_applicable_file_flags (obfd))))
- RETURN_NONFATAL (bfd_get_filename (ibfd));
+ || !bfd_set_file_flags (obfd, flags))
+ {
+ bfd_nonfatal (bfd_get_filename (ibfd));
+ return FALSE;
+ }
}
/* Copy architecture of input file to output file. */
- if (!bfd_set_arch_mach (obfd, bfd_get_arch (ibfd),
- bfd_get_mach (ibfd)))
- non_fatal (_("Warning: Output file cannot represent architecture %s"),
- bfd_printable_arch_mach (bfd_get_arch (ibfd),
- bfd_get_mach (ibfd)));
+ iarch = bfd_get_arch (ibfd);
+ imach = bfd_get_mach (ibfd);
+ if (!bfd_set_arch_mach (obfd, iarch, imach)
+ && (ibfd->target_defaulted
+ || bfd_get_arch (ibfd) != bfd_get_arch (obfd)))
+ {
+ if (bfd_get_arch (ibfd) == bfd_arch_unknown)
+ fatal (_("Unable to recognise the format of the input file %s"),
+ bfd_get_filename (ibfd));
+ else
+ {
+ non_fatal (_("Warning: Output file cannot represent architecture %s"),
+ bfd_printable_arch_mach (bfd_get_arch (ibfd),
+ bfd_get_mach (ibfd)));
+ return FALSE;
+ }
+ }
if (!bfd_set_format (obfd, bfd_get_format (ibfd)))
- RETURN_NONFATAL (bfd_get_filename (ibfd));
+ {
+ bfd_nonfatal (bfd_get_filename (ibfd));
+ return FALSE;
+ }
if (isympp)
free (isympp);
@@ -989,7 +1176,7 @@ copy_object (ibfd, obfd)
/* BFD mandates that all output sections be created and sizes set before
any output is done. Thus, we traverse all sections multiple times. */
- bfd_map_over_sections (ibfd, setup_section, (void *) obfd);
+ bfd_map_over_sections (ibfd, setup_section, obfd);
if (add_sections != NULL)
{
@@ -998,53 +1185,81 @@ copy_object (ibfd, obfd)
for (padd = add_sections; padd != NULL; padd = padd->next)
{
+ flagword flags;
+
padd->section = bfd_make_section (obfd, padd->name);
if (padd->section == NULL)
{
non_fatal (_("can't create section `%s': %s"),
padd->name, bfd_errmsg (bfd_get_error ()));
- status = 1;
- return;
+ return FALSE;
}
- else
+
+ if (! bfd_set_section_size (obfd, padd->section, padd->size))
{
- flagword flags;
+ bfd_nonfatal (bfd_get_filename (obfd));
+ return FALSE;
+ }
- if (! bfd_set_section_size (obfd, padd->section, padd->size))
- RETURN_NONFATAL (bfd_get_filename (obfd));
+ pset = find_section_list (padd->name, FALSE);
+ if (pset != NULL)
+ pset->used = TRUE;
- pset = find_section_list (padd->name, false);
- if (pset != NULL)
- pset->used = true;
+ if (pset != NULL && pset->set_flags)
+ flags = pset->flags | SEC_HAS_CONTENTS;
+ else
+ flags = SEC_HAS_CONTENTS | SEC_READONLY | SEC_DATA;
- if (pset != NULL && pset->set_flags)
- flags = pset->flags | SEC_HAS_CONTENTS;
- else
- flags = SEC_HAS_CONTENTS | SEC_READONLY | SEC_DATA;
+ if (! bfd_set_section_flags (obfd, padd->section, flags))
+ {
+ bfd_nonfatal (bfd_get_filename (obfd));
+ return FALSE;
+ }
- if (! bfd_set_section_flags (obfd, padd->section, flags))
- RETURN_NONFATAL (bfd_get_filename (obfd));
+ if (pset != NULL)
+ {
+ if (pset->change_vma != CHANGE_IGNORE)
+ if (! bfd_set_section_vma (obfd, padd->section,
+ pset->vma_val))
+ {
+ bfd_nonfatal (bfd_get_filename (obfd));
+ return FALSE;
+ }
- if (pset != NULL)
+ if (pset->change_lma != CHANGE_IGNORE)
{
- if (pset->change_vma != CHANGE_IGNORE)
- if (! bfd_set_section_vma (obfd, padd->section, pset->vma_val))
- RETURN_NONFATAL (bfd_get_filename (obfd));
+ padd->section->lma = pset->lma_val;
- if (pset->change_lma != CHANGE_IGNORE)
+ if (! bfd_set_section_alignment
+ (obfd, padd->section,
+ bfd_section_alignment (obfd, padd->section)))
{
- padd->section->lma = pset->lma_val;
-
- if (! bfd_set_section_alignment
- (obfd, padd->section,
- bfd_section_alignment (obfd, padd->section)))
- RETURN_NONFATAL (bfd_get_filename (obfd));
+ bfd_nonfatal (bfd_get_filename (obfd));
+ return FALSE;
}
}
}
}
}
+ if (gnu_debuglink_filename != NULL)
+ {
+ gnu_debuglink_section = bfd_create_gnu_debuglink_section
+ (obfd, gnu_debuglink_filename);
+
+ if (gnu_debuglink_section == NULL)
+ {
+ bfd_nonfatal (gnu_debuglink_filename);
+ return FALSE;
+ }
+ }
+
+ if (bfd_count_sections (obfd) == 0)
+ {
+ non_fatal (_("there are no sections to be copied!"));
+ return FALSE;
+ }
+
if (gap_fill_set || pad_to_set)
{
asection **set;
@@ -1057,13 +1272,13 @@ copy_object (ibfd, obfd)
We write out the gap contents below. */
c = bfd_count_sections (obfd);
- osections = (asection **) xmalloc (c * sizeof (asection *));
+ osections = xmalloc (c * sizeof (asection *));
set = osections;
- bfd_map_over_sections (obfd, get_sections, (void *) &set);
+ bfd_map_over_sections (obfd, get_sections, &set);
qsort (osections, c, sizeof (asection *), compare_section_lma);
- gaps = (bfd_size_type *) xmalloc (c * sizeof (bfd_size_type));
+ gaps = xmalloc (c * sizeof (bfd_size_type));
memset (gaps, 0, c * sizeof (bfd_size_type));
if (gap_fill_set)
@@ -1132,12 +1347,18 @@ copy_object (ibfd, obfd)
dhandle = NULL;
symsize = bfd_get_symtab_upper_bound (ibfd);
if (symsize < 0)
- RETURN_NONFATAL (bfd_get_filename (ibfd));
+ {
+ bfd_nonfatal (bfd_get_filename (ibfd));
+ return FALSE;
+ }
- osympp = isympp = (asymbol **) xmalloc (symsize);
+ osympp = isympp = xmalloc (symsize);
symcount = bfd_canonicalize_symtab (ibfd, isympp);
if (symcount < 0)
- RETURN_NONFATAL (bfd_get_filename (ibfd));
+ {
+ bfd_nonfatal (bfd_get_filename (ibfd));
+ return FALSE;
+ }
if (convert_debugging)
dhandle = read_debugging_info (ibfd, isympp, symcount);
@@ -1145,12 +1366,14 @@ copy_object (ibfd, obfd)
if (strip_symbols == STRIP_DEBUG
|| strip_symbols == STRIP_ALL
|| strip_symbols == STRIP_UNNEEDED
+ || strip_symbols == STRIP_NONDEBUG
|| discard_locals != LOCALS_UNDEF
|| strip_specific_list != NULL
|| keep_specific_list != NULL
|| localize_specific_list != NULL
|| keepglobal_specific_list != NULL
|| weaken_specific_list != NULL
+ || prefix_symbols_string
|| sections_removed
|| sections_copied
|| convert_debugging
@@ -1170,8 +1393,8 @@ copy_object (ibfd, obfd)
if (strip_symbols != STRIP_ALL)
bfd_map_over_sections (ibfd,
mark_symbols_used_in_relocations,
- (PTR)isympp);
- osympp = (asymbol **) xmalloc ((symcount + 1) * sizeof (asymbol *));
+ isympp);
+ osympp = xmalloc ((symcount + 1) * sizeof (asymbol *));
symcount = filter_symbols (ibfd, obfd, osympp, isympp, symcount);
}
@@ -1180,14 +1403,14 @@ copy_object (ibfd, obfd)
if (! write_debugging_info (obfd, dhandle, &symcount, &osympp))
{
status = 1;
- return;
+ return FALSE;
}
}
bfd_set_symtab (obfd, osympp, symcount);
/* This has to happen after the symbol table has been set. */
- bfd_map_over_sections (ibfd, copy_section, (void *) obfd);
+ bfd_map_over_sections (ibfd, copy_section, obfd);
if (add_sections != NULL)
{
@@ -1195,11 +1418,22 @@ copy_object (ibfd, obfd)
for (padd = add_sections; padd != NULL; padd = padd->next)
{
- if (! bfd_set_section_contents (obfd, padd->section,
- (PTR) padd->contents,
- (file_ptr) 0,
- (bfd_size_type) padd->size))
- RETURN_NONFATAL (bfd_get_filename (obfd));
+ if (! bfd_set_section_contents (obfd, padd->section, padd->contents,
+ 0, padd->size))
+ {
+ bfd_nonfatal (bfd_get_filename (obfd));
+ return FALSE;
+ }
+ }
+ }
+
+ if (gnu_debuglink_filename != NULL)
+ {
+ if (! bfd_fill_in_gnu_debuglink_section
+ (obfd, gnu_debuglink_section, gnu_debuglink_filename))
+ {
+ bfd_nonfatal (gnu_debuglink_filename);
+ return FALSE;
}
}
@@ -1211,8 +1445,8 @@ copy_object (ibfd, obfd)
/* Fill in the gaps. */
if (max_gap > 8192)
max_gap = 8192;
- buf = (bfd_byte *) xmalloc (max_gap);
- memset (buf, gap_fill, (size_t) max_gap);
+ buf = xmalloc (max_gap);
+ memset (buf, gap_fill, max_gap);
c = bfd_count_sections (obfd);
for (i = 0; i < c; i++)
@@ -1236,7 +1470,10 @@ copy_object (ibfd, obfd)
if (! bfd_set_section_contents (obfd, osections[i], buf,
off, now))
- RETURN_NONFATAL (bfd_get_filename (obfd));
+ {
+ bfd_nonfatal (bfd_get_filename (obfd));
+ return FALSE;
+ }
left -= now;
off += now;
@@ -1249,23 +1486,27 @@ copy_object (ibfd, obfd)
from the input BFD to the output BFD. This is done last to
permit the routine to look at the filtered symbol table, which is
important for the ECOFF code at least. */
- if (! bfd_copy_private_bfd_data (ibfd, obfd))
+ if (bfd_get_flavour (ibfd) == bfd_target_elf_flavour
+ && strip_symbols == STRIP_NONDEBUG)
+ /* Do not copy the private data when creating an ELF format
+ debug info file. We do not want the program headers. */
+ ;
+ else if (! bfd_copy_private_bfd_data (ibfd, obfd))
{
non_fatal (_("%s: error copying private BFD data: %s"),
bfd_get_filename (obfd),
bfd_errmsg (bfd_get_error ()));
- status = 1;
- return;
+ return FALSE;
}
/* Switch to the alternate machine code. We have to do this at the
very end, because we only initialize the header when we create
the first section. */
- if (use_alt_mach_code != 0)
- {
- if (!bfd_alt_mach_code (obfd, use_alt_mach_code))
- non_fatal (_("unknown alternate machine code, ignored"));
- }
+ if (use_alt_mach_code != 0
+ && ! bfd_alt_mach_code (obfd, use_alt_mach_code))
+ non_fatal (_("unknown alternate machine code, ignored"));
+
+ return TRUE;
}
#undef MKDIR
@@ -1279,10 +1520,7 @@ copy_object (ibfd, obfd)
contents to temp file, and keep the temp file handle. */
static void
-copy_archive (ibfd, obfd, output_target)
- bfd *ibfd;
- bfd *obfd;
- const char *output_target;
+copy_archive (bfd *ibfd, bfd *obfd, const char *output_target)
{
struct name_list
{
@@ -1296,10 +1534,9 @@ copy_archive (ibfd, obfd, output_target)
/* Make a temp directory to hold the contents. */
if (MKDIR (dir, 0700) != 0)
- {
- fatal (_("cannot mkdir %s for archive copying (error: %s)"),
- dir, strerror (errno));
- }
+ fatal (_("cannot mkdir %s for archive copying (error: %s)"),
+ dir, strerror (errno));
+
obfd->has_armap = ibfd->has_armap;
list = NULL;
@@ -1309,13 +1546,14 @@ copy_archive (ibfd, obfd, output_target)
if (!bfd_set_format (obfd, bfd_get_format (ibfd)))
RETURN_NONFATAL (bfd_get_filename (obfd));
- while (!status && this_element != (bfd *) NULL)
+ while (!status && this_element != NULL)
{
char *output_name;
bfd *output_bfd;
bfd *last_element;
struct stat buf;
int stat_status = 0;
+ bfd_boolean delete = TRUE;
/* Create an output file for this member. */
output_name = concat (dir, "/",
@@ -1326,11 +1564,10 @@ copy_archive (ibfd, obfd, output_target)
{
output_name = make_tempname (output_name);
if (MKDIR (output_name, 0700) != 0)
- {
- fatal (_("cannot mkdir %s for archive copying (error: %s)"),
- output_name, strerror (errno));
- }
- l = (struct name_list *) xmalloc (sizeof (struct name_list));
+ fatal (_("cannot mkdir %s for archive copying (error: %s)"),
+ output_name, strerror (errno));
+
+ l = xmalloc (sizeof (struct name_list));
l->name = output_name;
l->next = list;
l->obfd = NULL;
@@ -1349,16 +1586,16 @@ copy_archive (ibfd, obfd, output_target)
bfd_get_filename (this_element));
}
- l = (struct name_list *) xmalloc (sizeof (struct name_list));
+ l = xmalloc (sizeof (struct name_list));
l->name = output_name;
l->next = list;
list = l;
- if (output_bfd == (bfd *) NULL)
+ if (output_bfd == NULL)
RETURN_NONFATAL (output_name);
- if (bfd_check_format (this_element, bfd_object) == true)
- copy_object (this_element, output_bfd);
+ if (bfd_check_format (this_element, bfd_object))
+ delete = ! copy_object (this_element, output_bfd);
if (!bfd_close (output_bfd))
{
@@ -1367,24 +1604,32 @@ copy_archive (ibfd, obfd, output_target)
status = 1;
}
- if (preserve_dates && stat_status == 0)
- set_times (output_name, &buf);
+ if (delete)
+ {
+ unlink (output_name);
+ status = 1;
+ }
+ else
+ {
+ if (preserve_dates && stat_status == 0)
+ set_times (output_name, &buf);
- /* Open the newly output file and attach to our list. */
- output_bfd = bfd_openr (output_name, output_target);
+ /* Open the newly output file and attach to our list. */
+ output_bfd = bfd_openr (output_name, output_target);
- l->obfd = output_bfd;
+ l->obfd = output_bfd;
- *ptr = output_bfd;
- ptr = &output_bfd->next;
+ *ptr = output_bfd;
+ ptr = &output_bfd->next;
- last_element = this_element;
+ last_element = this_element;
- this_element = bfd_openr_next_archived_file (ibfd, last_element);
+ this_element = bfd_openr_next_archived_file (ibfd, last_element);
- bfd_close (last_element);
+ bfd_close (last_element);
+ }
}
- *ptr = (bfd *) NULL;
+ *ptr = NULL;
if (!bfd_close (obfd))
RETURN_NONFATAL (bfd_get_filename (obfd));
@@ -1409,14 +1654,18 @@ copy_archive (ibfd, obfd, output_target)
/* The top-level control. */
static void
-copy_file (input_filename, output_filename, input_target, output_target)
- const char *input_filename;
- const char *output_filename;
- const char *input_target;
- const char *output_target;
+copy_file (const char *input_filename, const char *output_filename,
+ const char *input_target, const char *output_target)
{
bfd *ibfd;
- char **matching;
+ char **obj_matching;
+ char **core_matching;
+
+ if (get_file_size (input_filename) < 1)
+ {
+ status = 1;
+ return;
+ }
/* To allow us to do "strip *" without dying on the first
non-object file, failures are nonfatal. */
@@ -1439,10 +1688,11 @@ copy_file (input_filename, output_filename, input_target, output_target)
copy_archive (ibfd, obfd, output_target);
}
- else if (bfd_check_format_matches (ibfd, bfd_object, &matching)
- || bfd_check_format_matches (ibfd, bfd_core, &matching))
+ else if (bfd_check_format_matches (ibfd, bfd_object, &obj_matching))
{
bfd *obfd;
+ bfd_boolean delete;
+ do_copy:
/* bfd_get_target does not return the correct value until
bfd_check_format succeeds. */
@@ -1453,22 +1703,49 @@ copy_file (input_filename, output_filename, input_target, output_target)
if (obfd == NULL)
RETURN_NONFATAL (output_filename);
- copy_object (ibfd, obfd);
+ delete = ! copy_object (ibfd, obfd);
if (!bfd_close (obfd))
RETURN_NONFATAL (output_filename);
if (!bfd_close (ibfd))
RETURN_NONFATAL (input_filename);
+
+ if (delete)
+ {
+ unlink (output_filename);
+ status = 1;
+ }
}
else
{
+ bfd_error_type obj_error = bfd_get_error ();
+ bfd_error_type core_error;
+
+ if (bfd_check_format_matches (ibfd, bfd_core, &core_matching))
+ {
+ /* This probably can't happen.. */
+ if (obj_error == bfd_error_file_ambiguously_recognized)
+ free (obj_matching);
+ goto do_copy;
+ }
+
+ core_error = bfd_get_error ();
+ /* Report the object error in preference to the core error. */
+ if (obj_error != core_error)
+ bfd_set_error (obj_error);
+
bfd_nonfatal (input_filename);
- if (bfd_get_error () == bfd_error_file_ambiguously_recognized)
+ if (obj_error == bfd_error_file_ambiguously_recognized)
{
- list_matching_formats (matching);
- free (matching);
+ list_matching_formats (obj_matching);
+ free (obj_matching);
+ }
+ if (core_error == bfd_error_file_ambiguously_recognized)
+ {
+ list_matching_formats (core_matching);
+ free (core_matching);
}
status = 1;
@@ -1478,10 +1755,8 @@ copy_file (input_filename, output_filename, input_target, output_target)
/* Add a name to the section renaming list. */
static void
-add_section_rename (old_name, new_name, flags)
- const char * old_name;
- const char * new_name;
- flagword flags;
+add_section_rename (const char * old_name, const char * new_name,
+ flagword flags)
{
section_rename * rename;
@@ -1497,7 +1772,7 @@ add_section_rename (old_name, new_name, flags)
fatal (_("Multiple renames of section %s"), old_name);
}
- rename = (section_rename *) xmalloc (sizeof (* rename));
+ rename = xmalloc (sizeof (* rename));
rename->old_name = old_name;
rename->new_name = new_name;
@@ -1512,10 +1787,8 @@ add_section_rename (old_name, new_name, flags)
Also set RETURNED_FLAGS to the flags to be used for this section. */
static const char *
-find_section_rename (ibfd, isection, returned_flags)
- bfd * ibfd ATTRIBUTE_UNUSED;
- sec_ptr isection;
- flagword * returned_flags;
+find_section_rename (bfd * ibfd ATTRIBUTE_UNUSED, sec_ptr isection,
+ flagword * returned_flags)
{
const char * old_name = bfd_section_name (ibfd, isection);
section_rename * rename;
@@ -1539,12 +1812,9 @@ find_section_rename (ibfd, isection, returned_flags)
name and attributes as ISECTION in IBFD. */
static void
-setup_section (ibfd, isection, obfdarg)
- bfd *ibfd;
- sec_ptr isection;
- PTR obfdarg;
+setup_section (bfd *ibfd, sec_ptr isection, void *obfdarg)
{
- bfd *obfd = (bfd *) obfdarg;
+ bfd *obfd = obfdarg;
struct section_list *p;
sec_ptr osection;
bfd_size_type size;
@@ -1553,27 +1823,35 @@ setup_section (ibfd, isection, obfdarg)
flagword flags;
const char *err;
const char * name;
+ char *prefix = NULL;
- if ((bfd_get_section_flags (ibfd, isection) & SEC_DEBUGGING) != 0
- && (strip_symbols == STRIP_DEBUG
- || strip_symbols == STRIP_UNNEEDED
- || strip_symbols == STRIP_ALL
- || discard_locals == LOCALS_ALL
- || convert_debugging))
+ if (is_strip_section (ibfd, isection))
return;
- p = find_section_list (bfd_section_name (ibfd, isection), false);
+ p = find_section_list (bfd_section_name (ibfd, isection), FALSE);
if (p != NULL)
- p->used = true;
-
- if (sections_removed && p != NULL && p->remove)
- return;
- if (sections_copied && (p == NULL || ! p->copy))
- return;
+ p->used = TRUE;
/* Get the, possibly new, name of the output section. */
name = find_section_rename (ibfd, isection, & flags);
+ /* Prefix sections. */
+ if ((prefix_alloc_sections_string)
+ && (bfd_get_section_flags (ibfd, isection) & SEC_ALLOC))
+ prefix = prefix_alloc_sections_string;
+ else if (prefix_sections_string)
+ prefix = prefix_sections_string;
+
+ if (prefix)
+ {
+ char *n;
+
+ n = xmalloc (strlen (prefix) + strlen (name) + 1);
+ strcpy (n, prefix);
+ strcat (n, name);
+ name = n;
+ }
+
osection = bfd_make_section_anyway (obfd, name);
if (osection == NULL)
@@ -1622,10 +1900,9 @@ setup_section (ibfd, isection, obfdarg)
/* FIXME: This is probably not enough. If we change the LMA we
may have to recompute the header for the file as well. */
- if (bfd_set_section_alignment (obfd,
- osection,
- bfd_section_alignment (ibfd, isection))
- == false)
+ if (!bfd_set_section_alignment (obfd,
+ osection,
+ bfd_section_alignment (ibfd, isection)))
{
err = _("alignment");
goto loser;
@@ -1633,6 +1910,13 @@ setup_section (ibfd, isection, obfdarg)
if (p != NULL && p->set_flags)
flags = p->flags | (flags & (SEC_HAS_CONTENTS | SEC_RELOC));
+ else if (strip_symbols == STRIP_NONDEBUG && (flags & SEC_ALLOC) != 0)
+ {
+ flags &= ~(SEC_HAS_CONTENTS | SEC_LOAD);
+ if (obfd->xvec->flavour == bfd_target_elf_flavour)
+ elf_section_type (osection) = SHT_NOBITS;
+ }
+
if (!bfd_set_section_flags (obfd, osection, flags))
{
err = _("flags");
@@ -1650,7 +1934,12 @@ setup_section (ibfd, isection, obfdarg)
/* Allow the BFD backend to copy any private data it understands
from the input section to the output section. */
- if (!bfd_copy_private_section_data (ibfd, isection, obfd, osection))
+ if (bfd_get_flavour (ibfd) == bfd_target_elf_flavour
+ && strip_symbols == STRIP_NONDEBUG)
+ /* Do not copy the private data when creating an ELF format
+ debug info file. We do not want the program headers. */
+ ;
+ else if (!bfd_copy_private_section_data (ibfd, isection, obfd, osection))
{
err = _("private data");
goto loser;
@@ -1672,12 +1961,9 @@ loser:
If stripping then don't copy any relocation info. */
static void
-copy_section (ibfd, isection, obfdarg)
- bfd *ibfd;
- sec_ptr isection;
- PTR obfdarg;
+copy_section (bfd *ibfd, sec_ptr isection, void *obfdarg)
{
- bfd *obfd = (bfd *) obfdarg;
+ bfd *obfd = obfdarg;
struct section_list *p;
arelent **relpp;
long relcount;
@@ -1691,45 +1977,43 @@ copy_section (ibfd, isection, obfdarg)
if (status != 0)
return;
- flags = bfd_get_section_flags (ibfd, isection);
- if ((flags & SEC_DEBUGGING) != 0
- && (strip_symbols == STRIP_DEBUG
- || strip_symbols == STRIP_UNNEEDED
- || strip_symbols == STRIP_ALL
- || discard_locals == LOCALS_ALL
- || convert_debugging))
+ if (is_strip_section (ibfd, isection))
return;
+ flags = bfd_get_section_flags (ibfd, isection);
if ((flags & SEC_GROUP) != 0)
return;
- p = find_section_list (bfd_section_name (ibfd, isection), false);
-
- if (sections_removed && p != NULL && p->remove)
- return;
- if (sections_copied && (p == NULL || ! p->copy))
- return;
-
osection = isection->output_section;
size = bfd_get_section_size_before_reloc (isection);
if (size == 0 || osection == 0)
return;
+ p = find_section_list (bfd_get_section_name (ibfd, isection), FALSE);
+
/* Core files do not need to be relocated. */
if (bfd_get_format (obfd) == bfd_core)
relsize = 0;
else
- relsize = bfd_get_reloc_upper_bound (ibfd, isection);
+ {
+ relsize = bfd_get_reloc_upper_bound (ibfd, isection);
- if (relsize < 0)
- RETURN_NONFATAL (bfd_get_filename (ibfd));
+ if (relsize < 0)
+ {
+ /* Do not complain if the target does not support relocations. */
+ if (relsize == -1 && bfd_get_error () == bfd_error_invalid_operation)
+ relsize = 0;
+ else
+ RETURN_NONFATAL (bfd_get_filename (ibfd));
+ }
+ }
if (relsize == 0)
- bfd_set_reloc (obfd, osection, (arelent **) NULL, 0);
+ bfd_set_reloc (obfd, osection, NULL, 0);
else
{
- relpp = (arelent **) xmalloc (relsize);
+ relpp = xmalloc (relsize);
relcount = bfd_canonicalize_reloc (ibfd, isection, relpp, isympp);
if (relcount < 0)
RETURN_NONFATAL (bfd_get_filename (ibfd));
@@ -1742,45 +2026,54 @@ copy_section (ibfd, isection, obfdarg)
long temp_relcount = 0;
long i;
- temp_relpp = (arelent **) xmalloc (relsize);
+ temp_relpp = xmalloc (relsize);
for (i = 0; i < relcount; i++)
- if (is_specified_symbol
- (bfd_asymbol_name (*relpp [i]->sym_ptr_ptr),
- keep_specific_list))
+ if (is_specified_symbol (bfd_asymbol_name (*relpp[i]->sym_ptr_ptr),
+ keep_specific_list))
temp_relpp [temp_relcount++] = relpp [i];
relcount = temp_relcount;
free (relpp);
relpp = temp_relpp;
}
- bfd_set_reloc (obfd, osection,
- (relcount == 0 ? (arelent **) NULL : relpp), relcount);
+ bfd_set_reloc (obfd, osection, relcount == 0 ? NULL : relpp, relcount);
+ if (relcount == 0)
+ free (relpp);
}
isection->_cooked_size = isection->_raw_size;
- isection->reloc_done = true;
+ isection->reloc_done = TRUE;
if (bfd_get_section_flags (ibfd, isection) & SEC_HAS_CONTENTS
&& bfd_get_section_flags (obfd, osection) & SEC_HAS_CONTENTS)
{
- PTR memhunk = (PTR) xmalloc ((unsigned) size);
+ void *memhunk = xmalloc (size);
- if (!bfd_get_section_contents (ibfd, isection, memhunk, (file_ptr) 0,
- size))
+ if (!bfd_get_section_contents (ibfd, isection, memhunk, 0, size))
RETURN_NONFATAL (bfd_get_filename (ibfd));
if (copy_byte >= 0)
- filter_bytes (memhunk, &size);
+ {
+ /* Keep only every `copy_byte'th byte in MEMHUNK. */
+ char *from = (char *) memhunk + copy_byte;
+ char *to = memhunk;
+ char *end = (char *) memhunk + size;
+
+ for (; from < end; from += interleave)
+ *to++ = *from;
- if (!bfd_set_section_contents (obfd, osection, memhunk, (file_ptr) 0,
- size))
+ size = (size + interleave - 1 - copy_byte) / interleave;
+ osection->lma /= interleave;
+ }
+
+ if (!bfd_set_section_contents (obfd, osection, memhunk, 0, size))
RETURN_NONFATAL (bfd_get_filename (obfd));
free (memhunk);
}
else if (p != NULL && p->set_flags && (p->flags & SEC_HAS_CONTENTS) != 0)
{
- PTR memhunk = (PTR) xmalloc ((unsigned) size);
+ void *memhunk = xmalloc (size);
/* We don't permit the user to turn off the SEC_HAS_CONTENTS
flag--they can just remove the section entirely and add it
@@ -1789,8 +2082,7 @@ copy_section (ibfd, isection, obfdarg)
contents should be zeroed out. */
memset (memhunk, 0, size);
- if (! bfd_set_section_contents (obfd, osection, memhunk, (file_ptr) 0,
- size))
+ if (! bfd_set_section_contents (obfd, osection, memhunk, 0, size))
RETURN_NONFATAL (bfd_get_filename (obfd));
free (memhunk);
}
@@ -1800,12 +2092,9 @@ copy_section (ibfd, isection, obfdarg)
used. */
static void
-get_sections (obfd, osection, secppparg)
- bfd *obfd ATTRIBUTE_UNUSED;
- asection *osection;
- PTR secppparg;
+get_sections (bfd *obfd ATTRIBUTE_UNUSED, asection *osection, void *secppparg)
{
- asection ***secppp = (asection ***) secppparg;
+ asection ***secppp = secppparg;
**secppp = osection;
++(*secppp);
@@ -1816,12 +2105,10 @@ get_sections (obfd, osection, secppparg)
sections to the front, where they are easier to ignore. */
static int
-compare_section_lma (arg1, arg2)
- const PTR arg1;
- const PTR arg2;
+compare_section_lma (const void *arg1, const void *arg2)
{
- const asection **sec1 = (const asection **) arg1;
- const asection **sec2 = (const asection **) arg2;
+ const asection *const *sec1 = arg1;
+ const asection *const *sec2 = arg2;
flagword flags1, flags2;
/* Sort non loadable sections to the front. */
@@ -1862,12 +2149,9 @@ compare_section_lma (arg1, arg2)
Ignore relocations which will not appear in the output file. */
static void
-mark_symbols_used_in_relocations (ibfd, isection, symbolsarg)
- bfd *ibfd;
- sec_ptr isection;
- PTR symbolsarg;
+mark_symbols_used_in_relocations (bfd *ibfd, sec_ptr isection, void *symbolsarg)
{
- asymbol **symbols = (asymbol **) symbolsarg;
+ asymbol **symbols = symbolsarg;
long relsize;
arelent **relpp;
long relcount, i;
@@ -1878,12 +2162,17 @@ mark_symbols_used_in_relocations (ibfd, isection, symbolsarg)
relsize = bfd_get_reloc_upper_bound (ibfd, isection);
if (relsize < 0)
- bfd_fatal (bfd_get_filename (ibfd));
+ {
+ /* Do not complain if the target does not support relocations. */
+ if (relsize == -1 && bfd_get_error () == bfd_error_invalid_operation)
+ return;
+ bfd_fatal (bfd_get_filename (ibfd));
+ }
if (relsize == 0)
return;
- relpp = (arelent **) xmalloc (relsize);
+ relpp = xmalloc (relsize);
relcount = bfd_canonicalize_reloc (ibfd, isection, relpp, symbols);
if (relcount < 0)
bfd_fatal (bfd_get_filename (ibfd));
@@ -1904,12 +2193,10 @@ mark_symbols_used_in_relocations (ibfd, isection, symbolsarg)
/* Write out debugging information. */
-static boolean
-write_debugging_info (obfd, dhandle, symcountp, symppp)
- bfd *obfd;
- PTR dhandle;
- long *symcountp ATTRIBUTE_UNUSED;
- asymbol ***symppp ATTRIBUTE_UNUSED;
+static bfd_boolean
+write_debugging_info (bfd *obfd, void *dhandle,
+ long *symcountp ATTRIBUTE_UNUSED,
+ asymbol ***symppp ATTRIBUTE_UNUSED)
{
if (bfd_get_flavour (obfd) == bfd_target_ieee_flavour)
return write_ieee_debugging_info (obfd, dhandle);
@@ -1924,7 +2211,7 @@ write_debugging_info (obfd, dhandle, symcountp, symppp)
if (! write_stabs_in_sections_debugging_info (obfd, dhandle, &syms,
&symsize, &strings,
&stringsize))
- return false;
+ return FALSE;
stabsec = bfd_make_section (obfd, ".stab");
stabstrsec = bfd_make_section (obfd, ".stabstr");
@@ -1946,44 +2233,44 @@ write_debugging_info (obfd, dhandle, symcountp, symppp)
non_fatal (_("%s: can't create debugging section: %s"),
bfd_get_filename (obfd),
bfd_errmsg (bfd_get_error ()));
- return false;
+ return FALSE;
}
/* We can get away with setting the section contents now because
the next thing the caller is going to do is copy over the
real sections. We may someday have to split the contents
setting out of this function. */
- if (! bfd_set_section_contents (obfd, stabsec, syms, (file_ptr) 0,
- symsize)
- || ! bfd_set_section_contents (obfd, stabstrsec, strings,
- (file_ptr) 0, stringsize))
+ if (! bfd_set_section_contents (obfd, stabsec, syms, 0, symsize)
+ || ! bfd_set_section_contents (obfd, stabstrsec, strings, 0,
+ stringsize))
{
non_fatal (_("%s: can't set debugging section contents: %s"),
bfd_get_filename (obfd),
bfd_errmsg (bfd_get_error ()));
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
non_fatal (_("%s: don't know how to write debugging information for %s"),
bfd_get_filename (obfd), bfd_get_target (obfd));
- return false;
+ return FALSE;
}
static int
-strip_main (argc, argv)
- int argc;
- char *argv[];
+strip_main (int argc, char *argv[])
{
- char *input_target = NULL, *output_target = NULL;
- boolean show_version = false;
- int c, i;
+ char *input_target = NULL;
+ char *output_target = NULL;
+ bfd_boolean show_version = FALSE;
+ bfd_boolean formats_info = FALSE;
+ int c;
+ int i;
struct section_list *p;
char *output_file = NULL;
- while ((c = getopt_long (argc, argv, "I:O:F:K:N:R:o:sSpdgxXHhVv",
+ while ((c = getopt_long (argc, argv, "I:O:F:K:N:R:o:sSpdgxXHhVvw",
strip_options, (int *) 0)) != EOF)
{
switch (c)
@@ -1998,9 +2285,9 @@ strip_main (argc, argv)
input_target = output_target = optarg;
break;
case 'R':
- p = find_section_list (optarg, true);
- p->remove = true;
- sections_removed = true;
+ p = find_section_list (optarg, TRUE);
+ p->remove = TRUE;
+ sections_removed = TRUE;
break;
case 's':
strip_symbols = STRIP_ALL;
@@ -2023,7 +2310,7 @@ strip_main (argc, argv)
output_file = optarg;
break;
case 'p':
- preserve_dates = true;
+ preserve_dates = TRUE;
break;
case 'x':
discard_locals = LOCALS_ALL;
@@ -2032,14 +2319,23 @@ strip_main (argc, argv)
discard_locals = LOCALS_START_L;
break;
case 'v':
- verbose = true;
+ verbose = TRUE;
break;
case 'V':
- show_version = true;
+ show_version = TRUE;
+ break;
+ case OPTION_FORMATS_INFO:
+ formats_info = TRUE;
+ break;
+ case OPTION_ONLY_KEEP_DEBUG:
+ strip_symbols = STRIP_NONDEBUG;
break;
case 0:
/* We've been given a long option. */
break;
+ case 'w':
+ wildcard = TRUE;
+ break;
case 'H':
case 'h':
strip_usage (stdout, 0);
@@ -2048,6 +2344,12 @@ strip_main (argc, argv)
}
}
+ if (formats_info)
+ {
+ display_info ();
+ return 0;
+ }
+
if (show_version)
print_version ("strip");
@@ -2057,7 +2359,7 @@ strip_main (argc, argv)
&& strip_specific_list == NULL)
strip_symbols = STRIP_ALL;
- if (output_target == (char *) NULL)
+ if (output_target == NULL)
output_target = input_target;
i = optind;
@@ -2071,14 +2373,13 @@ strip_main (argc, argv)
struct stat statbuf;
char *tmpname;
+ if (get_file_size (argv[i]) < 1)
+ continue;
+
if (preserve_dates)
- {
- if (stat (argv[i], &statbuf) < 0)
- {
- non_fatal (_("%s: cannot stat: %s"), argv[i], strerror (errno));
- continue;
- }
- }
+ /* No need to check the return value of stat().
+ It has already been checked in get_file_size(). */
+ stat (argv[i], &statbuf);
if (output_file != NULL)
tmpname = output_file;
@@ -2105,20 +2406,21 @@ strip_main (argc, argv)
}
static int
-copy_main (argc, argv)
- int argc;
- char *argv[];
+copy_main (int argc, char *argv[])
{
char * binary_architecture = NULL;
- char *input_filename = NULL, *output_filename = NULL;
- char *input_target = NULL, *output_target = NULL;
- boolean show_version = false;
- boolean change_warn = true;
+ char *input_filename = NULL;
+ char *output_filename = NULL;
+ char *input_target = NULL;
+ char *output_target = NULL;
+ bfd_boolean show_version = FALSE;
+ bfd_boolean change_warn = TRUE;
+ bfd_boolean formats_info = FALSE;
int c;
struct section_list *p;
struct stat statbuf;
- while ((c = getopt_long (argc, argv, "b:B:i:I:j:K:N:s:O:d:F:L:G:R:SpgxXHhVvW:",
+ while ((c = getopt_long (argc, argv, "b:B:i:I:j:K:N:s:O:d:F:L:G:R:SpgxXHhVvW:w",
copy_options, (int *) 0)) != EOF)
{
switch (c)
@@ -2154,19 +2456,19 @@ copy_main (argc, argv)
break;
case 'j':
- p = find_section_list (optarg, true);
+ p = find_section_list (optarg, TRUE);
if (p->remove)
fatal (_("%s both copied and removed"), optarg);
- p->copy = true;
- sections_copied = true;
+ p->copy = TRUE;
+ sections_copied = TRUE;
break;
case 'R':
- p = find_section_list (optarg, true);
+ p = find_section_list (optarg, TRUE);
if (p->copy)
fatal (_("%s both copied and removed"), optarg);
- p->remove = true;
- sections_removed = true;
+ p->remove = TRUE;
+ sections_removed = TRUE;
break;
case 'S':
@@ -2181,6 +2483,14 @@ copy_main (argc, argv)
strip_symbols = STRIP_UNNEEDED;
break;
+ case OPTION_ONLY_KEEP_DEBUG:
+ strip_symbols = STRIP_NONDEBUG;
+ break;
+
+ case OPTION_ADD_GNU_DEBUGLINK:
+ gnu_debuglink_filename = optarg;
+ break;
+
case 'K':
add_specific_symbol (optarg, &keep_specific_list);
break;
@@ -2202,7 +2512,11 @@ copy_main (argc, argv)
break;
case 'p':
- preserve_dates = true;
+ preserve_dates = TRUE;
+ break;
+
+ case 'w':
+ wildcard = TRUE;
break;
case 'x':
@@ -2214,21 +2528,25 @@ copy_main (argc, argv)
break;
case 'v':
- verbose = true;
+ verbose = TRUE;
break;
case 'V':
- show_version = true;
+ show_version = TRUE;
+ break;
+
+ case OPTION_FORMATS_INFO:
+ formats_info = TRUE;
break;
case OPTION_WEAKEN:
- weaken = true;
+ weaken = TRUE;
break;
case OPTION_ADD_SECTION:
{
const char *s;
- struct stat st;
+ off_t size;
struct section_add *pa;
int len;
char *name;
@@ -2239,26 +2557,27 @@ copy_main (argc, argv)
if (s == NULL)
fatal (_("bad format for %s"), "--add-section");
- if (stat (s + 1, & st) < 0)
- fatal (_("cannot stat: %s: %s"), s + 1, strerror (errno));
+ size = get_file_size (s + 1);
+ if (size < 1)
+ break;
- pa = (struct section_add *) xmalloc (sizeof (struct section_add));
+ pa = xmalloc (sizeof (struct section_add));
len = s - optarg;
- name = (char *) xmalloc (len + 1);
+ name = xmalloc (len + 1);
strncpy (name, optarg, len);
name[len] = '\0';
pa->name = name;
pa->filename = s + 1;
+ pa->size = size;
+ pa->contents = xmalloc (size);
- pa->size = st.st_size;
-
- pa->contents = (bfd_byte *) xmalloc (pa->size);
f = fopen (pa->filename, FOPEN_RB);
if (f == NULL)
- fatal (_("cannot open: %s: %s"), pa->filename, strerror (errno));
+ fatal (_("cannot open: %s: %s"),
+ pa->filename, strerror (errno));
if (fread (pa->contents, 1, pa->size, f) == 0
|| ferror (f))
@@ -2312,11 +2631,11 @@ copy_main (argc, argv)
}
len = s - optarg;
- name = (char *) xmalloc (len + 1);
+ name = xmalloc (len + 1);
strncpy (name, optarg, len);
name[len] = '\0';
- p = find_section_list (name, true);
+ p = find_section_list (name, TRUE);
val = parse_vma (s + 1, option);
@@ -2353,15 +2672,15 @@ copy_main (argc, argv)
break;
case OPTION_CHANGE_WARNINGS:
- change_warn = true;
+ change_warn = TRUE;
break;
case OPTION_CHANGE_LEADING_CHAR:
- change_leading_char = true;
+ change_leading_char = TRUE;
break;
case OPTION_DEBUGGING:
- convert_debugging = true;
+ convert_debugging = TRUE;
break;
case OPTION_GAP_FILL:
@@ -2379,21 +2698,21 @@ copy_main (argc, argv)
non_fatal (_("Warning: truncating gap-fill from 0x%s to 0x%x"),
buff, gap_fill);
}
- gap_fill_set = true;
+ gap_fill_set = TRUE;
}
break;
case OPTION_NO_CHANGE_WARNINGS:
- change_warn = false;
+ change_warn = FALSE;
break;
case OPTION_PAD_TO:
pad_to = parse_vma (optarg, "--pad-to");
- pad_to_set = true;
+ pad_to_set = TRUE;
break;
case OPTION_REMOVE_LEADING_CHAR:
- remove_leading_char = true;
+ remove_leading_char = TRUE;
break;
case OPTION_REDEFINE_SYM:
@@ -2410,22 +2729,26 @@ copy_main (argc, argv)
fatal (_("bad format for %s"), "--redefine-sym");
len = s - optarg;
- source = (char *) xmalloc (len + 1);
+ source = xmalloc (len + 1);
strncpy (source, optarg, len);
source[len] = '\0';
nextarg = s + 1;
len = strlen (nextarg);
- target = (char *) xmalloc (len + 1);
+ target = xmalloc (len + 1);
strcpy (target, nextarg);
- redefine_list_append (source, target);
+ redefine_list_append ("--redefine-sym", source, target);
free (source);
free (target);
}
break;
+ case OPTION_REDEFINE_SYMS:
+ add_redefine_syms_file (optarg);
+ break;
+
case OPTION_SET_SECTION_FLAGS:
{
const char *s;
@@ -2437,13 +2760,13 @@ copy_main (argc, argv)
fatal (_("bad format for %s"), "--set-section-flags");
len = s - optarg;
- name = (char *) xmalloc (len + 1);
+ name = xmalloc (len + 1);
strncpy (name, optarg, len);
name[len] = '\0';
- p = find_section_list (name, true);
+ p = find_section_list (name, TRUE);
- p->set_flags = true;
+ p->set_flags = TRUE;
p->flags = parse_flags (s + 1);
}
break;
@@ -2464,7 +2787,7 @@ copy_main (argc, argv)
if (len == 0)
fatal (_("bad format for %s"), "--rename-section");
- old_name = (char *) xmalloc (len + 1);
+ old_name = xmalloc (len + 1);
strncpy (old_name, optarg, len);
old_name[len] = 0;
@@ -2484,7 +2807,7 @@ copy_main (argc, argv)
if (len == 0)
fatal (_("bad format for %s"), "--rename-section");
- new_name = (char *) xmalloc (len + 1);
+ new_name = xmalloc (len + 1);
strncpy (new_name, eq, len);
new_name[len] = 0;
@@ -2494,7 +2817,7 @@ copy_main (argc, argv)
case OPTION_SET_START:
set_start = parse_vma (optarg, "--set-start");
- set_start_set = true;
+ set_start_set = TRUE;
break;
case OPTION_SREC_LEN:
@@ -2502,7 +2825,7 @@ copy_main (argc, argv)
break;
case OPTION_SREC_FORCES3:
- S3Forced = true;
+ S3Forced = TRUE;
break;
case OPTION_STRIP_SYMBOLS:
@@ -2531,8 +2854,41 @@ copy_main (argc, argv)
fatal (_("alternate machine code index must be positive"));
break;
+ case OPTION_PREFIX_SYMBOLS:
+ prefix_symbols_string = optarg;
+ break;
+
+ case OPTION_PREFIX_SECTIONS:
+ prefix_sections_string = optarg;
+ break;
+
+ case OPTION_PREFIX_ALLOC_SECTIONS:
+ prefix_alloc_sections_string = optarg;
+ break;
+
+ case OPTION_READONLY_TEXT:
+ bfd_flags_to_set |= WP_TEXT;
+ bfd_flags_to_clear &= ~WP_TEXT;
+ break;
+
+ case OPTION_WRITABLE_TEXT:
+ bfd_flags_to_clear |= WP_TEXT;
+ bfd_flags_to_set &= ~WP_TEXT;
+ break;
+
+ case OPTION_PURE:
+ bfd_flags_to_set |= D_PAGED;
+ bfd_flags_to_clear &= ~D_PAGED;
+ break;
+
+ case OPTION_IMPURE:
+ bfd_flags_to_clear |= D_PAGED;
+ bfd_flags_to_set &= ~D_PAGED;
+ break;
+
case 0:
- break; /* we've been given a long option */
+ /* We've been given a long option. */
+ break;
case 'H':
case 'h':
@@ -2543,6 +2899,12 @@ copy_main (argc, argv)
}
}
+ if (formats_info)
+ {
+ display_info ();
+ return 0;
+ }
+
if (show_version)
print_version ("objcopy");
@@ -2560,10 +2922,10 @@ copy_main (argc, argv)
if (strip_symbols == STRIP_UNDEF && discard_locals == LOCALS_UNDEF)
strip_symbols = STRIP_NONE;
- if (output_target == (char *) NULL)
+ if (output_target == NULL)
output_target = input_target;
- if (binary_architecture != (char *) NULL)
+ if (binary_architecture != NULL)
{
if (input_target && strcmp (input_target, "binary") == 0)
{
@@ -2572,7 +2934,10 @@ copy_main (argc, argv)
temp_arch_info = bfd_scan_arch (binary_architecture);
if (temp_arch_info != NULL)
- bfd_external_binary_architecture = temp_arch_info->arch;
+ {
+ bfd_external_binary_architecture = temp_arch_info->arch;
+ bfd_external_machine = temp_arch_info->mach;
+ }
else
fatal (_("architecture %s unknown"), binary_architecture);
}
@@ -2585,12 +2950,12 @@ copy_main (argc, argv)
if (preserve_dates)
if (stat (input_filename, & statbuf) < 0)
- fatal (_("Cannot stat: %s: %s"), input_filename, strerror (errno));
-
- /* If there is no destination file then create a temp and rename
- the result into the input. */
+ fatal (_("warning: could not locate '%s'. System error message: %s"),
+ input_filename, strerror (errno));
- if (output_filename == (char *) NULL)
+ /* If there is no destination file, or the source and destination files
+ are the same, then create a temp and rename the result into the input. */
+ if (output_filename == NULL || strcmp (input_filename, output_filename) == 0)
{
char *tmpname = make_tempname (input_filename);
@@ -2652,12 +3017,8 @@ copy_main (argc, argv)
return 0;
}
-int main PARAMS ((int, char **));
-
int
-main (argc, argv)
- int argc;
- char *argv[];
+main (int argc, char *argv[])
{
#if defined (HAVE_SETLOCALE) && defined (HAVE_LC_MESSAGES)
setlocale (LC_MESSAGES, "");
diff --git a/contrib/binutils/binutils/objdump.c b/contrib/binutils/binutils/objdump.c
index d09b6e5..f67aacb 100644
--- a/contrib/binutils/binutils/objdump.c
+++ b/contrib/binutils/binutils/objdump.c
@@ -1,25 +1,55 @@
/* objdump.c -- dump information about an object file.
Copyright 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
-This file is part of GNU Binutils.
-
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ This file is part of GNU Binutils.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+/* Objdump overview.
+
+ Objdump displays information about one or more object files, either on
+ their own, or inside libraries. It is commonly used as a disassembler,
+ but it can also display information about file headers, symbol tables,
+ relocations, debugging directives and more.
+
+ The flow of execution is as follows:
+
+ 1. Command line arguments are checked for control switches and the
+ information to be displayed is selected.
+
+ 2. Any remaining arguments are assumed to be object files, and they are
+ processed in order by display_bfd(). If the file is an archive each
+ of its elements is processed in turn.
+
+ 3. The file's target architecture and binary file format are determined
+ by bfd_check_format(). If they are recognised, then dump_bfd() is
+ called.
+
+ 4. dump_bfd() in turn calls separate functions to display the requested
+ item(s) of information(s). For example disassemble_data() is called if
+ a disassembly has been requested.
+
+ When disassembling the code loops through blocks of instructions bounded
+ by symbols, calling disassemble_bytes() on each block. The actual
+ disassembling is done by the libopcodes library, via a function pointer
+ supplied by the disassembler() function. */
#include "bfd.h"
+#include "bfdver.h"
#include "progress.h"
#include "bucomm.h"
#include "budemang.h"
@@ -36,19 +66,21 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "aout/aout64.h"
#ifdef NEED_DECLARATION_FPRINTF
-/* This is needed by INIT_DISASSEMBLE_INFO. */
-extern int fprintf PARAMS ((FILE *, const char *, ...));
+/* This is needed by init_disassemble_info(). */
+extern int fprintf (FILE *, const char *, ...);
#endif
/* Exit status. */
static int exit_status = 0;
-static char *default_target = NULL; /* default at runtime */
+static char *default_target = NULL; /* Default at runtime. */
-static int show_version = 0; /* show the version number */
+/* The following variables are set based on arguments passed on the
+ command line. */
+static int show_version = 0; /* Show the version number. */
static int dump_section_contents; /* -s */
static int dump_section_headers; /* -h */
-static boolean dump_file_header; /* -f */
+static bfd_boolean dump_file_header; /* -f */
static int dump_symtab; /* -t */
static int dump_dynamic_symtab; /* -T */
static int dump_reloc_info; /* -r */
@@ -57,34 +89,51 @@ static int dump_ar_hdrs; /* -a */
static int dump_private_headers; /* -p */
static int prefix_addresses; /* --prefix-addresses */
static int with_line_numbers; /* -l */
-static boolean with_source_code; /* -S */
+static bfd_boolean with_source_code; /* -S */
static int show_raw_insn; /* --show-raw-insn */
static int dump_stab_section_info; /* --stabs */
static int do_demangle; /* -C, --demangle */
-static boolean disassemble; /* -d */
-static boolean disassemble_all; /* -D */
+static bfd_boolean disassemble; /* -d */
+static bfd_boolean disassemble_all; /* -D */
static int disassemble_zeroes; /* --disassemble-zeroes */
-static boolean formats_info; /* -i */
-static char *only; /* -j secname */
+static bfd_boolean formats_info; /* -i */
static int wide_output; /* -w */
static bfd_vma start_address = (bfd_vma) -1; /* --start-address */
static bfd_vma stop_address = (bfd_vma) -1; /* --stop-address */
static int dump_debugging; /* --debugging */
+static int dump_debugging_tags; /* --debugging-tags */
static bfd_vma adjust_section_vma = 0; /* --adjust-vma */
static int file_start_context = 0; /* --file-start-context */
-/* Extra info to pass to the disassembler address printing function. */
-struct objdump_disasm_info {
- bfd *abfd;
- asection *sec;
- boolean require_sec;
+/* Pointer to an array of section names provided by
+ one or more "-j secname" command line options. */
+static char **only;
+/* The total number of slots in the only[] array. */
+static size_t only_size = 0;
+/* The number of occupied slots in the only[] array. */
+static size_t only_used = 0;
+
+/* Variables for handling include file path table. */
+static const char **include_paths;
+static int include_path_count;
+
+/* Extra info to pass to the section disassembler and address printing
+ function. */
+struct objdump_disasm_info
+{
+ bfd * abfd;
+ asection * sec;
+ bfd_boolean require_sec;
+ arelent ** dynrelbuf;
+ long dynrelcount;
+ disassembler_ftype disassemble_fn;
};
/* Architecture to disassemble for, or default if NULL. */
-static char *machine = (char *) NULL;
+static char *machine = NULL;
/* Target specific options to the disassembler. */
-static char *disassembler_options = (char *) NULL;
+static char *disassembler_options = NULL;
/* Endianness to disassemble for, or default if BFD_ENDIAN_UNKNOWN. */
static enum bfd_endian endian = BFD_ENDIAN_UNKNOWN;
@@ -107,60 +156,14 @@ static asymbol **dynsyms;
/* Number of symbols in `dynsyms'. */
static long dynsymcount = 0;
-/* Static declarations. */
-
-static void usage PARAMS ((FILE *, int));
-static void nonfatal PARAMS ((const char *));
-static void display_file PARAMS ((char *filename, char *target));
-static void dump_section_header PARAMS ((bfd *, asection *, PTR));
-static void dump_headers PARAMS ((bfd *));
-static void dump_data PARAMS ((bfd *abfd));
-static void dump_relocs PARAMS ((bfd *abfd));
-static void dump_dynamic_relocs PARAMS ((bfd * abfd));
-static void dump_reloc_set PARAMS ((bfd *, asection *, arelent **, long));
-static void dump_symbols PARAMS ((bfd *abfd, boolean dynamic));
-static void dump_bfd_header PARAMS ((bfd *));
-static void dump_bfd_private_header PARAMS ((bfd *));
-static void dump_bfd PARAMS ((bfd *));
-static void display_bfd PARAMS ((bfd *abfd));
-static void display_target_list PARAMS ((void));
-static void display_info_table PARAMS ((int, int));
-static void display_target_tables PARAMS ((void));
-static void display_info PARAMS ((void));
-static void objdump_print_value
- PARAMS ((bfd_vma, struct disassemble_info *, boolean));
-static void objdump_print_symname
- PARAMS ((bfd *, struct disassemble_info *, asymbol *));
-static asymbol *find_symbol_for_address
- PARAMS ((bfd *, asection *, bfd_vma, boolean, long *));
-static void objdump_print_addr_with_sym
- PARAMS ((bfd *, asection *, asymbol *, bfd_vma,
- struct disassemble_info *, boolean));
-static void objdump_print_addr
- PARAMS ((bfd_vma, struct disassemble_info *, boolean));
-static void objdump_print_address
- PARAMS ((bfd_vma, struct disassemble_info *));
-static int objdump_symbol_at_address
- PARAMS ((bfd_vma, struct disassemble_info *));
-static void show_line PARAMS ((bfd *, asection *, bfd_vma));
-static void disassemble_bytes
- PARAMS ((struct disassemble_info *, disassembler_ftype, boolean,
- bfd_byte *, bfd_vma, bfd_vma, arelent ***, arelent **));
-static void disassemble_data PARAMS ((bfd *));
-static const char *endian_string PARAMS ((enum bfd_endian));
-static asymbol ** slurp_symtab PARAMS ((bfd *));
-static asymbol ** slurp_dynamic_symtab PARAMS ((bfd *));
-static long remove_useless_symbols PARAMS ((asymbol **, long));
-static int compare_symbols PARAMS ((const PTR, const PTR));
-static int compare_relocs PARAMS ((const PTR, const PTR));
-static void dump_stabs PARAMS ((bfd *));
-static boolean read_section_stabs PARAMS ((bfd *, const char *, const char *));
-static void print_section_stabs PARAMS ((bfd *, const char *, const char *));
+static bfd_byte *stabs;
+static bfd_size_type stab_size;
+
+static char *strtab;
+static bfd_size_type stabstr_size;
static void
-usage (stream, status)
- FILE *stream;
- int status;
+usage (FILE *stream, int status)
{
fprintf (stream, _("Usage: %s <option(s)> <file(s)>\n"), program_name);
fprintf (stream, _(" Display information from object <file(s)>.\n"));
@@ -176,6 +179,7 @@ usage (stream, status)
-S, --source Intermix source code with disassembly\n\
-s, --full-contents Display the full contents of all sections requested\n\
-g, --debugging Display debug information in object file\n\
+ -e, --debugging-tags Display debug information using ctags style\n\
-G, --stabs Display (in raw form) any STABS info in the file\n\
-t, --syms Display the contents of the symbol table(s)\n\
-T, --dynamic-syms Display the contents of the dynamic symbol table\n\
@@ -196,14 +200,16 @@ usage (stream, status)
-EB --endian=big Assume big endian format when disassembling\n\
-EL --endian=little Assume little endian format when disassembling\n\
--file-start-context Include context from start of file (with -S)\n\
+ -I, --include=DIR Add DIR to search list for source files\n\
-l, --line-numbers Include line numbers and filenames in output\n\
-C, --demangle[=STYLE] Decode mangled/processed symbol names\n\
- The STYLE, if specified, can be `auto', 'gnu',\n\
- 'lucid', 'arm', 'hp', 'edg', or 'gnu-new-abi'\n\
+ The STYLE, if specified, can be `auto', `gnu',\n\
+ `lucid', `arm', `hp', `edg', `gnu-v3', `java'\n\
+ or `gnat'\n\
-w, --wide Format output for more than 80 columns\n\
-z, --disassemble-zeroes Do not skip blocks of zeroes when disassembling\n\
- --start-address=ADDR Only process data whoes address is >= ADDR\n\
- --stop-address=ADDR Only process data whoes address is <= ADDR\n\
+ --start-address=ADDR Only process data whose address is >= ADDR\n\
+ --stop-address=ADDR Only process data whose address is <= ADDR\n\
--prefix-addresses Print complete address alongside disassembly\n\
--[no-]show-raw-insn Display hex alongside symbolic disassembly\n\
--adjust-vma=OFFSET Add OFFSET to all displayed section addresses\n\
@@ -219,11 +225,13 @@ usage (stream, status)
}
/* 150 isn't special; it's just an arbitrary non-ASCII char value. */
-
-#define OPTION_ENDIAN (150)
-#define OPTION_START_ADDRESS (OPTION_ENDIAN + 1)
-#define OPTION_STOP_ADDRESS (OPTION_START_ADDRESS + 1)
-#define OPTION_ADJUST_VMA (OPTION_STOP_ADDRESS + 1)
+enum option_values
+ {
+ OPTION_ENDIAN=150,
+ OPTION_START_ADDRESS,
+ OPTION_STOP_ADDRESS,
+ OPTION_ADJUST_VMA
+ };
static struct option long_options[]=
{
@@ -233,6 +241,7 @@ static struct option long_options[]=
{"architecture", required_argument, NULL, 'm'},
{"archive-headers", no_argument, NULL, 'a'},
{"debugging", no_argument, NULL, 'g'},
+ {"debugging-tags", no_argument, NULL, 'e'},
{"demangle", optional_argument, NULL, 'C'},
{"disassemble", no_argument, NULL, 'd'},
{"disassemble-all", no_argument, NULL, 'D'},
@@ -255,6 +264,7 @@ static struct option long_options[]=
{"section-headers", no_argument, NULL, 'h'},
{"show-raw-insn", no_argument, &show_raw_insn, 1},
{"source", no_argument, NULL, 'S'},
+ {"include", required_argument, NULL, 'I'},
{"stabs", no_argument, NULL, 'G'},
{"start-address", required_argument, NULL, OPTION_START_ADDRESS},
{"stop-address", required_argument, NULL, OPTION_STOP_ADDRESS},
@@ -266,18 +276,15 @@ static struct option long_options[]=
};
static void
-nonfatal (msg)
- const char *msg;
+nonfatal (const char *msg)
{
bfd_nonfatal (msg);
exit_status = 1;
}
static void
-dump_section_header (abfd, section, ignored)
- bfd *abfd ATTRIBUTE_UNUSED;
- asection *section;
- PTR ignored ATTRIBUTE_UNUSED;
+dump_section_header (bfd *abfd ATTRIBUTE_UNUSED, asection *section,
+ void *ignored ATTRIBUTE_UNUSED)
{
char *comma = "";
unsigned int opb = bfd_octets_per_byte (abfd);
@@ -352,8 +359,7 @@ dump_section_header (abfd, section, ignored)
}
static void
-dump_headers (abfd)
- bfd *abfd;
+dump_headers (bfd *abfd)
{
printf (_("Sections:\n"));
@@ -369,21 +375,21 @@ dump_headers (abfd)
if (wide_output)
printf (_(" Flags"));
+ if (abfd->flags & HAS_LOAD_PAGE)
+ printf (_(" Pg"));
printf ("\n");
- bfd_map_over_sections (abfd, dump_section_header, (PTR) NULL);
+ bfd_map_over_sections (abfd, dump_section_header, NULL);
}
static asymbol **
-slurp_symtab (abfd)
- bfd *abfd;
+slurp_symtab (bfd *abfd)
{
- asymbol **sy = (asymbol **) NULL;
+ asymbol **sy = NULL;
long storage;
if (!(bfd_get_file_flags (abfd) & HAS_SYMS))
{
- non_fatal (_("%s: no symbols"), bfd_get_filename (abfd));
symcount = 0;
return NULL;
}
@@ -392,23 +398,20 @@ slurp_symtab (abfd)
if (storage < 0)
bfd_fatal (bfd_get_filename (abfd));
if (storage)
- sy = (asymbol **) xmalloc (storage);
+ sy = xmalloc (storage);
symcount = bfd_canonicalize_symtab (abfd, sy);
if (symcount < 0)
bfd_fatal (bfd_get_filename (abfd));
- if (symcount == 0)
- non_fatal (_("%s: no symbols"), bfd_get_filename (abfd));
return sy;
}
/* Read in the dynamic symbols. */
static asymbol **
-slurp_dynamic_symtab (abfd)
- bfd *abfd;
+slurp_dynamic_symtab (bfd *abfd)
{
- asymbol **sy = (asymbol **) NULL;
+ asymbol **sy = NULL;
long storage;
storage = bfd_get_dynamic_symtab_upper_bound (abfd);
@@ -424,13 +427,11 @@ slurp_dynamic_symtab (abfd)
bfd_fatal (bfd_get_filename (abfd));
}
if (storage)
- sy = (asymbol **) xmalloc (storage);
+ sy = xmalloc (storage);
dynsymcount = bfd_canonicalize_dynamic_symtab (abfd, sy);
if (dynsymcount < 0)
bfd_fatal (bfd_get_filename (abfd));
- if (dynsymcount == 0)
- non_fatal (_("%s: No dynamic symbols"), bfd_get_filename (abfd));
return sy;
}
@@ -439,11 +440,9 @@ slurp_dynamic_symtab (abfd)
Return the number of useful symbols. */
static long
-remove_useless_symbols (symbols, count)
- asymbol **symbols;
- long count;
+remove_useless_symbols (asymbol **symbols, long count)
{
- register asymbol **in_ptr = symbols, **out_ptr = symbols;
+ asymbol **in_ptr = symbols, **out_ptr = symbols;
while (--count >= 0)
{
@@ -465,16 +464,18 @@ remove_useless_symbols (symbols, count)
/* Sort symbols into value order. */
static int
-compare_symbols (ap, bp)
- const PTR ap;
- const PTR bp;
+compare_symbols (const void *ap, const void *bp)
{
- const asymbol *a = *(const asymbol **)ap;
- const asymbol *b = *(const asymbol **)bp;
- const char *an, *bn;
- size_t anl, bnl;
- boolean af, bf;
- flagword aflags, bflags;
+ const asymbol *a = * (const asymbol **) ap;
+ const asymbol *b = * (const asymbol **) bp;
+ const char *an;
+ const char *bn;
+ size_t anl;
+ size_t bnl;
+ bfd_boolean af;
+ bfd_boolean bf;
+ flagword aflags;
+ flagword bflags;
if (bfd_asymbol_value (a) > bfd_asymbol_value (b))
return 1;
@@ -493,7 +494,6 @@ compare_symbols (ap, bp)
/* The symbols gnu_compiled and gcc2_compiled convey no real
information, so put them after other symbols with the same value. */
-
af = (strstr (an, "gnu_compiled") != NULL
|| strstr (an, "gcc2_compiled") != NULL);
bf = (strstr (bn, "gnu_compiled") != NULL
@@ -573,12 +573,10 @@ compare_symbols (ap, bp)
/* Sort relocs into address order. */
static int
-compare_relocs (ap, bp)
- const PTR ap;
- const PTR bp;
+compare_relocs (const void *ap, const void *bp)
{
- const arelent *a = *(const arelent **)ap;
- const arelent *b = *(const arelent **)bp;
+ const arelent *a = * (const arelent **) ap;
+ const arelent *b = * (const arelent **) bp;
if (a->address > b->address)
return 1;
@@ -595,19 +593,18 @@ compare_relocs (ap, bp)
return 0;
}
-/* Print VMA to STREAM. If SKIP_ZEROES is true, omit leading zeroes. */
+/* Print an address (VMA) to the output stream in INFO.
+ If SKIP_ZEROES is TRUE, omit leading zeroes. */
static void
-objdump_print_value (vma, info, skip_zeroes)
- bfd_vma vma;
- struct disassemble_info *info;
- boolean skip_zeroes;
+objdump_print_value (bfd_vma vma, struct disassemble_info *info,
+ bfd_boolean skip_zeroes)
{
char buf[30];
char *p;
- struct objdump_disasm_info *aux
- = (struct objdump_disasm_info *) info->application_data;
+ struct objdump_disasm_info *aux;
+ aux = (struct objdump_disasm_info *) info->application_data;
bfd_sprintf_vma (aux->abfd, buf, vma);
if (! skip_zeroes)
p = buf;
@@ -624,10 +621,8 @@ objdump_print_value (vma, info, skip_zeroes)
/* Print the name of a symbol. */
static void
-objdump_print_symname (abfd, info, sym)
- bfd *abfd;
- struct disassemble_info *info;
- asymbol *sym;
+objdump_print_symname (bfd *abfd, struct disassemble_info *info,
+ asymbol *sym)
{
char *alloc;
const char *name;
@@ -650,18 +645,16 @@ objdump_print_symname (abfd, info, sym)
free (alloc);
}
-/* Locate a symbol given a bfd, a section, and a VMA. If REQUIRE_SEC
- is true, then always require the symbol to be in the section. This
- returns NULL if there is no suitable symbol. If PLACE is not NULL,
- then *PLACE is set to the index of the symbol in sorted_syms. */
+/* Locate a symbol given a bfd and a section (from INFO->application_data),
+ and a VMA. If INFO->application_data->require_sec is TRUE, then always
+ require the symbol to be in the section. Returns NULL if there is no
+ suitable symbol. If PLACE is not NULL, then *PLACE is set to the index
+ of the symbol in sorted_syms. */
static asymbol *
-find_symbol_for_address (abfd, sec, vma, require_sec, place)
- bfd *abfd;
- asection *sec;
- bfd_vma vma;
- boolean require_sec;
- long *place;
+find_symbol_for_address (bfd_vma vma,
+ struct disassemble_info *info,
+ long *place)
{
/* @@ Would it speed things up to cache the last two symbols returned,
and maybe their address ranges? For many processors, only one memory
@@ -672,11 +665,19 @@ find_symbol_for_address (abfd, sec, vma, require_sec, place)
long min = 0;
long max = sorted_symcount;
long thisplace;
- unsigned int opb = bfd_octets_per_byte (abfd);
+ struct objdump_disasm_info *aux;
+ bfd *abfd;
+ asection *sec;
+ unsigned int opb;
if (sorted_symcount < 1)
return NULL;
+ aux = (struct objdump_disasm_info *) info->application_data;
+ abfd = aux->abfd;
+ sec = aux->sec;
+ opb = bfd_octets_per_byte (abfd);
+
/* Perform a binary search looking for the closest symbol to the
required value. We are searching the range (min, max]. */
while (min + 1 < max)
@@ -706,7 +707,7 @@ find_symbol_for_address (abfd, sec, vma, require_sec, place)
== bfd_asymbol_value (sorted_syms[thisplace - 1])))
--thisplace;
- /* If the file is relocateable, and the symbol could be from this
+ /* If the file is relocatable, and the symbol could be from this
section, prefer a symbol from this section over symbols from
others, even if the other symbol's value might be closer.
@@ -714,9 +715,8 @@ find_symbol_for_address (abfd, sec, vma, require_sec, place)
sections have overlapping memory ranges, but in that case there's
no way to tell what's desired without looking at the relocation
table. */
-
if (sorted_syms[thisplace]->section != sec
- && (require_sec
+ && (aux->require_sec
|| ((abfd->flags & HAS_RELOC) != 0
&& vma >= bfd_get_section_vma (abfd, sec)
&& vma < (bfd_get_section_vma (abfd, sec)
@@ -730,7 +730,9 @@ find_symbol_for_address (abfd, sec, vma, require_sec, place)
!= bfd_asymbol_value (sorted_syms[thisplace]))
break;
}
+
--i;
+
for (; i >= 0; i--)
{
if (sorted_syms[i]->section == sec
@@ -759,15 +761,22 @@ find_symbol_for_address (abfd, sec, vma, require_sec, place)
}
if (sorted_syms[thisplace]->section != sec
- && (require_sec
+ && (aux->require_sec
|| ((abfd->flags & HAS_RELOC) != 0
&& vma >= bfd_get_section_vma (abfd, sec)
&& vma < (bfd_get_section_vma (abfd, sec)
+ bfd_section_size (abfd, sec)))))
- {
- /* There is no suitable symbol. */
- return NULL;
- }
+ /* There is no suitable symbol. */
+ return NULL;
+ }
+
+ /* Give the target a chance to reject the symbol. */
+ while (! info->symbol_is_valid (sorted_syms [thisplace], info))
+ {
+ ++ thisplace;
+ if (thisplace >= sorted_symcount
+ || bfd_asymbol_value (sorted_syms [thisplace]) > vma)
+ return NULL;
}
if (place != NULL)
@@ -776,16 +785,12 @@ find_symbol_for_address (abfd, sec, vma, require_sec, place)
return sorted_syms[thisplace];
}
-/* Print an address to INFO symbolically. */
+/* Print an address and the offset to the nearest symbol. */
static void
-objdump_print_addr_with_sym (abfd, sec, sym, vma, info, skip_zeroes)
- bfd *abfd;
- asection *sec;
- asymbol *sym;
- bfd_vma vma;
- struct disassemble_info *info;
- boolean skip_zeroes;
+objdump_print_addr_with_sym (bfd *abfd, asection *sec, asymbol *sym,
+ bfd_vma vma, struct disassemble_info *info,
+ bfd_boolean skip_zeroes)
{
objdump_print_value (vma, info, skip_zeroes);
@@ -799,12 +804,12 @@ objdump_print_addr_with_sym (abfd, sec, sym, vma, info, skip_zeroes)
if (vma < secaddr)
{
(*info->fprintf_func) (info->stream, "-0x");
- objdump_print_value (secaddr - vma, info, true);
+ objdump_print_value (secaddr - vma, info, TRUE);
}
else if (vma > secaddr)
{
(*info->fprintf_func) (info->stream, "+0x");
- objdump_print_value (vma - secaddr, info, true);
+ objdump_print_value (vma - secaddr, info, TRUE);
}
(*info->fprintf_func) (info->stream, ">");
}
@@ -815,25 +820,24 @@ objdump_print_addr_with_sym (abfd, sec, sym, vma, info, skip_zeroes)
if (bfd_asymbol_value (sym) > vma)
{
(*info->fprintf_func) (info->stream, "-0x");
- objdump_print_value (bfd_asymbol_value (sym) - vma, info, true);
+ objdump_print_value (bfd_asymbol_value (sym) - vma, info, TRUE);
}
else if (vma > bfd_asymbol_value (sym))
{
(*info->fprintf_func) (info->stream, "+0x");
- objdump_print_value (vma - bfd_asymbol_value (sym), info, true);
+ objdump_print_value (vma - bfd_asymbol_value (sym), info, TRUE);
}
(*info->fprintf_func) (info->stream, ">");
}
}
-/* Print VMA to INFO, symbolically if possible. If SKIP_ZEROES is
- true, don't output leading zeroes. */
+/* Print an address (VMA), symbolically if possible.
+ If SKIP_ZEROES is TRUE, don't output leading zeroes. */
static void
-objdump_print_addr (vma, info, skip_zeroes)
- bfd_vma vma;
- struct disassemble_info *info;
- boolean skip_zeroes;
+objdump_print_addr (bfd_vma vma,
+ struct disassemble_info *info,
+ bfd_boolean skip_zeroes)
{
struct objdump_disasm_info *aux;
asymbol *sym;
@@ -846,8 +850,7 @@ objdump_print_addr (vma, info, skip_zeroes)
}
aux = (struct objdump_disasm_info *) info->application_data;
- sym = find_symbol_for_address (aux->abfd, aux->sec, vma, aux->require_sec,
- (long *) NULL);
+ sym = find_symbol_for_address (vma, info, NULL);
objdump_print_addr_with_sym (aux->abfd, aux->sec, sym, vma, info,
skip_zeroes);
}
@@ -856,9 +859,7 @@ objdump_print_addr (vma, info, skip_zeroes)
routine. */
static void
-objdump_print_address (vma, info)
- bfd_vma vma;
- struct disassemble_info *info;
+objdump_print_address (bfd_vma vma, struct disassemble_info *info)
{
objdump_print_addr (vma, info, ! prefix_addresses);
}
@@ -866,20 +867,11 @@ objdump_print_address (vma, info)
/* Determine of the given address has a symbol associated with it. */
static int
-objdump_symbol_at_address (vma, info)
- bfd_vma vma;
- struct disassemble_info * info;
+objdump_symbol_at_address (bfd_vma vma, struct disassemble_info * info)
{
- struct objdump_disasm_info * aux;
asymbol * sym;
- /* No symbols - do not bother checking. */
- if (sorted_symcount < 1)
- return 0;
-
- aux = (struct objdump_disasm_info *) info->application_data;
- sym = find_symbol_for_address (aux->abfd, aux->sec, vma, aux->require_sec,
- (long *) NULL);
+ sym = find_symbol_for_address (vma, info, NULL);
return (sym != NULL && (bfd_asymbol_value (sym) == vma));
}
@@ -891,13 +883,14 @@ static char *prev_functionname;
static unsigned int prev_line;
/* We keep a list of all files that we have seen when doing a
- dissassembly with source, so that we know how much of the file to
+ disassembly with source, so that we know how much of the file to
display. This can be important for inlined functions. */
struct print_file_list
{
struct print_file_list *next;
- char *filename;
+ const char *filename;
+ const char *modname;
unsigned int line;
FILE *f;
};
@@ -909,17 +902,95 @@ static struct print_file_list *print_files;
#define SHOW_PRECEDING_CONTEXT_LINES (5)
+/* Tries to open MODNAME, and if successful adds a node to print_files
+ linked list and returns that node. Returns NULL on failure. */
+
+static struct print_file_list *
+try_print_file_open (const char *origname, const char *modname)
+{
+ struct print_file_list *p;
+ FILE *f;
+
+ f = fopen (modname, "r");
+ if (f == NULL)
+ return NULL;
+
+ if (print_files != NULL && print_files->f != NULL)
+ {
+ fclose (print_files->f);
+ print_files->f = NULL;
+ }
+
+ p = xmalloc (sizeof (struct print_file_list));
+ p->filename = origname;
+ p->modname = modname;
+ p->line = 0;
+ p->f = f;
+ p->next = print_files;
+ print_files = p;
+ return p;
+}
+
+/* If the the source file, as described in the symtab, is not found
+ try to locate it in one of the paths specified with -I
+ If found, add location to print_files linked list. */
+
+static struct print_file_list *
+update_source_path (const char *filename)
+{
+ struct print_file_list *p;
+ const char *fname;
+ int i;
+
+ if (filename == NULL)
+ return NULL;
+
+ p = try_print_file_open (filename, filename);
+ if (p != NULL)
+ return p;
+
+ if (include_path_count == 0)
+ return NULL;
+
+ /* Get the name of the file. */
+ fname = strrchr (filename, '/');
+#ifdef HAVE_DOS_BASED_FILE_SYSTEM
+ {
+ /* We could have a mixed forward/back slash case. */
+ char *backslash = strrchr (filename, '\\');
+ if (fname == NULL || (backslash != NULL && backslash > fname))
+ fname = backslash;
+ if (fname == NULL && filename[0] != '\0' && filename[1] == ':')
+ fname = filename + 1;
+ }
+#endif
+ if (fname == NULL)
+ fname = filename;
+ else
+ ++fname;
+
+ /* If file exists under a new path, we need to add it to the list
+ so that show_line knows about it. */
+ for (i = 0; i < include_path_count; i++)
+ {
+ char *modname = concat (include_paths[i], "/", fname, (const char *) 0);
+
+ p = try_print_file_open (filename, modname);
+ if (p)
+ return p;
+
+ free (modname);
+ }
+
+ return NULL;
+}
+
/* Skip ahead to a given line in a file, optionally printing each
line. */
static void
-skip_to_line PARAMS ((struct print_file_list *, unsigned int, boolean));
-
-static void
-skip_to_line (p, line, show)
- struct print_file_list *p;
- unsigned int line;
- boolean show;
+skip_to_line (struct print_file_list *p, unsigned int line,
+ bfd_boolean show)
{
while (p->line < line)
{
@@ -940,14 +1011,11 @@ skip_to_line (p, line, show)
}
}
-/* Show the line number, or the source line, in a dissassembly
+/* Show the line number, or the source line, in a disassembly
listing. */
static void
-show_line (abfd, section, addr_offset)
- bfd *abfd;
- asection *section;
- bfd_vma addr_offset;
+show_line (bfd *abfd, asection *section, bfd_vma addr_offset)
{
const char *filename;
const char *functionname;
@@ -1014,11 +1082,11 @@ show_line (abfd, section, addr_offset)
if (p->f == NULL)
{
- p->f = fopen (p->filename, "r");
+ p->f = fopen (p->modname, "r");
p->line = 0;
}
if (p->f != NULL)
- skip_to_line (p, l, false);
+ skip_to_line (p, l, FALSE);
if (print_files->f != NULL)
{
@@ -1029,7 +1097,7 @@ show_line (abfd, section, addr_offset)
if (p->f != NULL)
{
- skip_to_line (p, line, true);
+ skip_to_line (p, line, TRUE);
*pp = p->next;
p->next = print_files;
print_files = p;
@@ -1037,37 +1105,21 @@ show_line (abfd, section, addr_offset)
}
else
{
- FILE *f;
+ p = update_source_path (filename);
- f = fopen (filename, "r");
- if (f != NULL)
+ if (p != NULL)
{
int l;
- p = ((struct print_file_list *)
- xmalloc (sizeof (struct print_file_list)));
- p->filename = xmalloc (strlen (filename) + 1);
- strcpy (p->filename, filename);
- p->line = 0;
- p->f = f;
-
- if (print_files != NULL && print_files->f != NULL)
- {
- fclose (print_files->f);
- print_files->f = NULL;
- }
- p->next = print_files;
- print_files = p;
-
if (file_start_context)
l = 0;
else
l = line - SHOW_PRECEDING_CONTEXT_LINES;
if (l < 0)
l = 0;
- skip_to_line (p, l, false);
+ skip_to_line (p, l, FALSE);
if (p->f != NULL)
- skip_to_line (p, line, true);
+ skip_to_line (p, line, TRUE);
}
}
}
@@ -1094,17 +1146,16 @@ typedef struct
char *current;
} SFILE;
-/* sprintf to a "stream" */
+/* sprintf to a "stream". */
static int
-objdump_sprintf VPARAMS ((SFILE *f, const char *format, ...))
+objdump_sprintf (SFILE *f, const char *format, ...)
{
char *buf;
size_t n;
+ va_list args;
- VA_OPEN (args, format);
- VA_FIXEDARG (args, SFILE *, f);
- VA_FIXEDARG (args, const char *, format);
+ va_start (args, format);
vasprintf (&buf, format, args);
@@ -1132,10 +1183,28 @@ objdump_sprintf VPARAMS ((SFILE *f, const char *format, ...))
free (buf);
- VA_CLOSE (args);
+ va_end (args);
return n;
}
+/* Returns TRUE if the specified section should be dumped. */
+
+static bfd_boolean
+process_section_p (asection * section)
+{
+ size_t i;
+
+ if (only == NULL)
+ return TRUE;
+
+ for (i = 0; i < only_used; i++)
+ if (strcmp (only [i], section->name) == 0)
+ return TRUE;
+
+ return FALSE;
+}
+
+
/* The number of zeroes we want to see before we start skipping them.
The number is arbitrarily chosen. */
@@ -1157,22 +1226,20 @@ objdump_sprintf VPARAMS ((SFILE *f, const char *format, ...))
/* Disassemble some data in memory between given values. */
static void
-disassemble_bytes (info, disassemble_fn, insns, data,
- start_offset, stop_offset, relppp,
- relppend)
- struct disassemble_info *info;
- disassembler_ftype disassemble_fn;
- boolean insns;
- bfd_byte *data;
- bfd_vma start_offset;
- bfd_vma stop_offset;
- arelent ***relppp;
- arelent **relppend;
+disassemble_bytes (struct disassemble_info * info,
+ disassembler_ftype disassemble_fn,
+ bfd_boolean insns,
+ bfd_byte * data,
+ bfd_vma start_offset,
+ bfd_vma stop_offset,
+ bfd_vma rel_offset,
+ arelent *** relppp,
+ arelent ** relppend)
{
struct objdump_disasm_info *aux;
asection *section;
int octets_per_line;
- boolean done_dot;
+ bfd_boolean done_dot;
int skip_addr_chars;
bfd_vma addr_offset;
int opb = info->octets_per_byte;
@@ -1210,16 +1277,16 @@ disassemble_bytes (info, disassemble_fn, insns, data,
info->insn_info_valid = 0;
- done_dot = false;
+ done_dot = FALSE;
addr_offset = start_offset;
while (addr_offset < stop_offset)
{
bfd_vma z;
int octets = 0;
- boolean need_nl = false;
+ bfd_boolean need_nl = FALSE;
/* If we see more than SKIP_ZEROES octets of zeroes, we just
- print `...'. */
+ print `...'. */
for (z = addr_offset * opb; z < stop_offset * opb; z++)
if (data[z] != 0)
break;
@@ -1233,9 +1300,9 @@ disassemble_bytes (info, disassemble_fn, insns, data,
printf ("\t...\n");
/* If there are more nonzero octets to follow, we only skip
- zeroes in multiples of 4, to try to avoid running over
- the start of an instruction which happens to start with
- zero. */
+ zeroes in multiples of 4, to try to avoid running over
+ the start of an instruction which happens to start with
+ zero. */
if (z != stop_offset * opb)
z = addr_offset * opb + ((z - addr_offset * opb) &~ 3);
@@ -1248,7 +1315,7 @@ disassemble_bytes (info, disassemble_fn, insns, data,
int bpc = 0;
int pb = 0;
- done_dot = false;
+ done_dot = FALSE;
if (with_line_numbers || with_source_code)
/* The line number tables will refer to unadjusted
@@ -1269,9 +1336,9 @@ disassemble_bytes (info, disassemble_fn, insns, data,
}
else
{
- aux->require_sec = true;
+ aux->require_sec = TRUE;
objdump_print_address (section->vma + addr_offset, info);
- aux->require_sec = false;
+ aux->require_sec = FALSE;
putchar (' ');
}
@@ -1287,10 +1354,11 @@ disassemble_bytes (info, disassemble_fn, insns, data,
#ifdef DISASSEMBLER_NEEDS_RELOCS
/* FIXME: This is wrong. It tests the number of octets
- in the last instruction, not the current one. */
+ in the last instruction, not the current one. */
if (*relppp < relppend
- && (**relppp)->address >= addr_offset
- && (**relppp)->address <= addr_offset + octets / opb)
+ && (**relppp)->address >= rel_offset + addr_offset
+ && ((**relppp)->address
+ < rel_offset + addr_offset + octets / opb))
info->flags = INSN_HAS_RELOC;
else
#endif
@@ -1334,7 +1402,7 @@ disassemble_bytes (info, disassemble_fn, insns, data,
bfd_vma j;
/* If ! prefix_addresses and ! wide_output, we print
- octets_per_line octets per line. */
+ octets_per_line octets per line. */
pb = octets;
if (pb > octets_per_line && ! prefix_addresses && ! wide_output)
pb = octets_per_line;
@@ -1430,23 +1498,13 @@ disassemble_bytes (info, disassemble_fn, insns, data,
if (!wide_output)
putchar ('\n');
else
- need_nl = true;
+ need_nl = TRUE;
}
- if ((section->flags & SEC_RELOC) != 0
-#ifndef DISASSEMBLER_NEEDS_RELOCS
- && dump_reloc_info
-#endif
- )
+ while ((*relppp) < relppend
+ && (**relppp)->address < rel_offset + addr_offset + octets / opb)
{
- while ((*relppp) < relppend
- && ((**relppp)->address >= (bfd_vma) addr_offset
- && (**relppp)->address < (bfd_vma) addr_offset + octets / opb))
-#ifdef DISASSEMBLER_NEEDS_RELOCS
- if (! dump_reloc_info)
- ++(*relppp);
- else
-#endif
+ if (dump_reloc_info || dump_dynamic_reloc_info)
{
arelent *q;
@@ -1457,7 +1515,8 @@ disassemble_bytes (info, disassemble_fn, insns, data,
else
printf ("\t\t\t");
- objdump_print_value (section->vma + q->address, info, true);
+ objdump_print_value (section->vma - rel_offset + q->address,
+ info, TRUE);
printf (": %s\t", q->howto->name);
@@ -1485,13 +1544,13 @@ disassemble_bytes (info, disassemble_fn, insns, data,
if (q->addend)
{
printf ("+0x");
- objdump_print_value (q->addend, info, true);
+ objdump_print_value (q->addend, info, TRUE);
}
printf ("\n");
- need_nl = false;
- ++(*relppp);
+ need_nl = FALSE;
}
+ ++(*relppp);
}
if (need_nl)
@@ -1501,18 +1560,235 @@ disassemble_bytes (info, disassemble_fn, insns, data,
}
}
+static void
+disassemble_section (bfd *abfd, asection *section, void *info)
+{
+ struct disassemble_info * pinfo = (struct disassemble_info *) info;
+ struct objdump_disasm_info * paux;
+ unsigned int opb = pinfo->octets_per_byte;
+ bfd_byte * data = NULL;
+ bfd_size_type datasize = 0;
+ arelent ** rel_pp = NULL;
+ arelent ** rel_ppstart = NULL;
+ arelent ** rel_ppend;
+ unsigned long stop_offset;
+ asymbol * sym = NULL;
+ long place = 0;
+ long rel_count;
+ bfd_vma rel_offset;
+ unsigned long addr_offset;
+
+ /* Sections that do not contain machine
+ code are not normally disassembled. */
+ if (! disassemble_all
+ && only == NULL
+ && (section->flags & SEC_CODE) == 0)
+ return;
+
+ if (! process_section_p (section))
+ return;
+
+ datasize = bfd_get_section_size_before_reloc (section);
+ if (datasize == 0)
+ return;
+
+ /* Decide which set of relocs to use. Load them if necessary. */
+ paux = (struct objdump_disasm_info *) pinfo->application_data;
+ if (paux->dynrelbuf)
+ {
+ rel_pp = paux->dynrelbuf;
+ rel_count = paux->dynrelcount;
+ /* Dynamic reloc addresses are absolute, non-dynamic are section
+ relative. REL_OFFSET specifies the reloc address corresponding
+ to the start of this section. */
+ rel_offset = section->vma;
+ }
+ else
+ {
+ rel_count = 0;
+ rel_pp = NULL;
+ rel_offset = 0;
+
+ if ((section->flags & SEC_RELOC) != 0
+#ifndef DISASSEMBLER_NEEDS_RELOCS
+ && dump_reloc_info
+#endif
+ )
+ {
+ long relsize;
+
+ relsize = bfd_get_reloc_upper_bound (abfd, section);
+ if (relsize < 0)
+ bfd_fatal (bfd_get_filename (abfd));
+
+ if (relsize > 0)
+ {
+ rel_ppstart = rel_pp = xmalloc (relsize);
+ rel_count = bfd_canonicalize_reloc (abfd, section, rel_pp, syms);
+ if (rel_count < 0)
+ bfd_fatal (bfd_get_filename (abfd));
+
+ /* Sort the relocs by address. */
+ qsort (rel_pp, rel_count, sizeof (arelent *), compare_relocs);
+ }
+ }
+
+ }
+ rel_ppend = rel_pp + rel_count;
+
+ data = xmalloc (datasize);
+
+ bfd_get_section_contents (abfd, section, data, 0, datasize);
+
+ paux->sec = section;
+ pinfo->buffer = data;
+ pinfo->buffer_vma = section->vma;
+ pinfo->buffer_length = datasize;
+ pinfo->section = section;
+
+ if (start_address == (bfd_vma) -1
+ || start_address < pinfo->buffer_vma)
+ addr_offset = 0;
+ else
+ addr_offset = start_address - pinfo->buffer_vma;
+
+ if (stop_address == (bfd_vma) -1)
+ stop_offset = datasize / opb;
+ else
+ {
+ if (stop_address < pinfo->buffer_vma)
+ stop_offset = 0;
+ else
+ stop_offset = stop_address - pinfo->buffer_vma;
+ if (stop_offset > pinfo->buffer_length / opb)
+ stop_offset = pinfo->buffer_length / opb;
+ }
+
+ /* Skip over the relocs belonging to addresses below the
+ start address. */
+ while (rel_pp < rel_ppend
+ && (*rel_pp)->address < rel_offset + addr_offset)
+ ++rel_pp;
+
+ printf (_("Disassembly of section %s:\n"), section->name);
+
+ /* Find the nearest symbol forwards from our current position. */
+ paux->require_sec = TRUE;
+ sym = find_symbol_for_address (section->vma + addr_offset, info, &place);
+ paux->require_sec = FALSE;
+
+ /* Disassemble a block of instructions up to the address associated with
+ the symbol we have just found. Then print the symbol and find the
+ next symbol on. Repeat until we have disassembled the entire section
+ or we have reached the end of the address range we are interested in. */
+ while (addr_offset < stop_offset)
+ {
+ bfd_vma addr;
+ asymbol *nextsym;
+ unsigned long nextstop_offset;
+ bfd_boolean insns;
+
+ addr = section->vma + addr_offset;
+
+ if (sym != NULL && bfd_asymbol_value (sym) <= addr)
+ {
+ int x;
+
+ for (x = place;
+ (x < sorted_symcount
+ && (bfd_asymbol_value (sorted_syms[x]) <= addr));
+ ++x)
+ continue;
+
+ pinfo->symbols = sorted_syms + place;
+ pinfo->num_symbols = x - place;
+ }
+ else
+ {
+ pinfo->symbols = NULL;
+ pinfo->num_symbols = 0;
+ }
+
+ if (! prefix_addresses)
+ {
+ pinfo->fprintf_func (pinfo->stream, "\n");
+ objdump_print_addr_with_sym (abfd, section, sym, addr,
+ pinfo, FALSE);
+ pinfo->fprintf_func (pinfo->stream, ":\n");
+ }
+
+ if (sym != NULL && bfd_asymbol_value (sym) > addr)
+ nextsym = sym;
+ else if (sym == NULL)
+ nextsym = NULL;
+ else
+ {
+#define is_valid_next_sym(SYM) \
+ ((SYM)->section == section \
+ && (bfd_asymbol_value (SYM) > bfd_asymbol_value (sym)) \
+ && pinfo->symbol_is_valid (SYM, pinfo))
+
+ /* Search forward for the next appropriate symbol in
+ SECTION. Note that all the symbols are sorted
+ together into one big array, and that some sections
+ may have overlapping addresses. */
+ while (place < sorted_symcount
+ && ! is_valid_next_sym (sorted_syms [place]))
+ ++place;
+
+ if (place >= sorted_symcount)
+ nextsym = NULL;
+ else
+ nextsym = sorted_syms[place];
+ }
+
+ if (sym != NULL && bfd_asymbol_value (sym) > addr)
+ nextstop_offset = bfd_asymbol_value (sym) - section->vma;
+ else if (nextsym == NULL)
+ nextstop_offset = stop_offset;
+ else
+ nextstop_offset = bfd_asymbol_value (nextsym) - section->vma;
+
+ if (nextstop_offset > stop_offset)
+ nextstop_offset = stop_offset;
+
+ /* If a symbol is explicitly marked as being an object
+ rather than a function, just dump the bytes without
+ disassembling them. */
+ if (disassemble_all
+ || sym == NULL
+ || bfd_asymbol_value (sym) > addr
+ || ((sym->flags & BSF_OBJECT) == 0
+ && (strstr (bfd_asymbol_name (sym), "gnu_compiled")
+ == NULL)
+ && (strstr (bfd_asymbol_name (sym), "gcc2_compiled")
+ == NULL))
+ || (sym->flags & BSF_FUNCTION) != 0)
+ insns = TRUE;
+ else
+ insns = FALSE;
+
+ disassemble_bytes (pinfo, paux->disassemble_fn, insns, data,
+ addr_offset, nextstop_offset,
+ rel_offset, &rel_pp, rel_ppend);
+
+ addr_offset = nextstop_offset;
+ sym = nextsym;
+ }
+
+ free (data);
+
+ if (rel_ppstart != NULL)
+ free (rel_ppstart);
+}
+
/* Disassemble the contents of an object file. */
static void
-disassemble_data (abfd)
- bfd *abfd;
+disassemble_data (bfd *abfd)
{
- unsigned long addr_offset;
- disassembler_ftype disassemble_fn;
struct disassemble_info disasm_info;
struct objdump_disasm_info aux;
- asection *section;
- unsigned int opb;
print_files = NULL;
prev_functionname = NULL;
@@ -1520,28 +1796,32 @@ disassemble_data (abfd)
/* We make a copy of syms to sort. We don't want to sort syms
because that will screw up the relocs. */
- sorted_syms = (asymbol **) xmalloc (symcount * sizeof (asymbol *));
+ sorted_syms = xmalloc (symcount * sizeof (asymbol *));
memcpy (sorted_syms, syms, symcount * sizeof (asymbol *));
sorted_symcount = remove_useless_symbols (sorted_syms, symcount);
- /* Sort the symbols into section and symbol order */
+ /* Sort the symbols into section and symbol order. */
qsort (sorted_syms, sorted_symcount, sizeof (asymbol *), compare_symbols);
- INIT_DISASSEMBLE_INFO(disasm_info, stdout, fprintf);
- disasm_info.application_data = (PTR) &aux;
+ init_disassemble_info (&disasm_info, stdout, (fprintf_ftype) fprintf);
+
+ disasm_info.application_data = (void *) &aux;
aux.abfd = abfd;
- aux.require_sec = false;
+ aux.require_sec = FALSE;
+ aux.dynrelbuf = NULL;
+ aux.dynrelcount = 0;
+
disasm_info.print_address_func = objdump_print_address;
disasm_info.symbol_at_address_func = objdump_symbol_at_address;
- if (machine != (char *) NULL)
+ if (machine != NULL)
{
const bfd_arch_info_type *info = bfd_scan_arch (machine);
+
if (info == NULL)
- {
- fatal (_("Can't use supplied machine %s"), machine);
- }
+ fatal (_("Can't use supplied machine %s"), machine);
+
abfd->arch_info = info;
}
@@ -1549,14 +1829,15 @@ disassemble_data (abfd)
{
struct bfd_target *xvec;
- xvec = (struct bfd_target *) xmalloc (sizeof (struct bfd_target));
+ xvec = xmalloc (sizeof (struct bfd_target));
memcpy (xvec, abfd->xvec, sizeof (struct bfd_target));
xvec->byteorder = endian;
abfd->xvec = xvec;
}
- disassemble_fn = disassembler (abfd);
- if (!disassemble_fn)
+ /* Use libopcodes to locate a suitable disassembler. */
+ aux.disassemble_fn = disassembler (abfd);
+ if (!aux.disassemble_fn)
{
non_fatal (_("Can't disassemble for architecture %s\n"),
bfd_printable_arch_mach (bfd_get_arch (abfd), 0));
@@ -1564,13 +1845,11 @@ disassemble_data (abfd)
return;
}
- opb = bfd_octets_per_byte (abfd);
-
disasm_info.flavour = bfd_get_flavour (abfd);
disasm_info.arch = bfd_get_arch (abfd);
disasm_info.mach = bfd_get_mach (abfd);
disasm_info.disassembler_options = disassembler_options;
- disasm_info.octets_per_byte = opb;
+ disasm_info.octets_per_byte = bfd_octets_per_byte (abfd);
if (bfd_big_endian (abfd))
disasm_info.display_endian = disasm_info.endian = BFD_ENDIAN_BIG;
@@ -1581,283 +1860,73 @@ disassemble_data (abfd)
instead. */
disasm_info.endian = BFD_ENDIAN_UNKNOWN;
- for (section = abfd->sections;
- section != (asection *) NULL;
- section = section->next)
+ /* Allow the target to customize the info structure. */
+ disassemble_init_for_target (& disasm_info);
+
+ /* Pre-load the dynamic relocs if we are going
+ to be dumping them along with the disassembly. */
+ if (dump_dynamic_reloc_info)
{
- bfd_byte *data = NULL;
- bfd_size_type datasize = 0;
- arelent **relbuf = NULL;
- arelent **relpp = NULL;
- arelent **relppend = NULL;
- unsigned long stop_offset;
- asymbol *sym = NULL;
- long place = 0;
-
- if ((section->flags & SEC_LOAD) == 0
- || (! disassemble_all
- && only == NULL
- && (section->flags & SEC_CODE) == 0))
- continue;
- if (only != (char *) NULL && strcmp (only, section->name) != 0)
- continue;
+ long relsize = bfd_get_dynamic_reloc_upper_bound (abfd);
+
+ if (relsize < 0)
+ bfd_fatal (bfd_get_filename (abfd));
- if ((section->flags & SEC_RELOC) != 0
-#ifndef DISASSEMBLER_NEEDS_RELOCS
- && dump_reloc_info
-#endif
- )
+ if (relsize > 0)
{
- long relsize;
-
- relsize = bfd_get_reloc_upper_bound (abfd, section);
- if (relsize < 0)
+ aux.dynrelbuf = xmalloc (relsize);
+ aux.dynrelcount = bfd_canonicalize_dynamic_reloc (abfd,
+ aux.dynrelbuf,
+ dynsyms);
+ if (aux.dynrelcount < 0)
bfd_fatal (bfd_get_filename (abfd));
- if (relsize > 0)
- {
- long relcount;
-
- relbuf = (arelent **) xmalloc (relsize);
- relcount = bfd_canonicalize_reloc (abfd, section, relbuf, syms);
- if (relcount < 0)
- bfd_fatal (bfd_get_filename (abfd));
-
- /* Sort the relocs by address. */
- qsort (relbuf, relcount, sizeof (arelent *), compare_relocs);
-
- relpp = relbuf;
- relppend = relpp + relcount;
-
- /* Skip over the relocs belonging to addresses below the
- start address. */
- if (start_address != (bfd_vma) -1)
- {
- while (relpp < relppend
- && (*relpp)->address < start_address)
- ++relpp;
- }
- }
- }
-
- printf (_("Disassembly of section %s:\n"), section->name);
-
- datasize = bfd_get_section_size_before_reloc (section);
- if (datasize == 0)
- continue;
-
- data = (bfd_byte *) xmalloc ((size_t) datasize);
-
- bfd_get_section_contents (abfd, section, data, 0, datasize);
-
- aux.sec = section;
- disasm_info.buffer = data;
- disasm_info.buffer_vma = section->vma;
- disasm_info.buffer_length = datasize;
- disasm_info.section = section;
- if (start_address == (bfd_vma) -1
- || start_address < disasm_info.buffer_vma)
- addr_offset = 0;
- else
- addr_offset = start_address - disasm_info.buffer_vma;
- if (stop_address == (bfd_vma) -1)
- stop_offset = datasize / opb;
- else
- {
- if (stop_address < disasm_info.buffer_vma)
- stop_offset = 0;
- else
- stop_offset = stop_address - disasm_info.buffer_vma;
- if (stop_offset > disasm_info.buffer_length / opb)
- stop_offset = disasm_info.buffer_length / opb;
+ /* Sort the relocs by address. */
+ qsort (aux.dynrelbuf, aux.dynrelcount, sizeof (arelent *),
+ compare_relocs);
}
+ }
- sym = find_symbol_for_address (abfd, section, section->vma + addr_offset,
- true, &place);
-
- while (addr_offset < stop_offset)
- {
- asymbol *nextsym;
- unsigned long nextstop_offset;
- boolean insns;
-
- if (sym != NULL && bfd_asymbol_value (sym) <= section->vma + addr_offset)
- {
- int x;
-
- for (x = place;
- (x < sorted_symcount
- && bfd_asymbol_value (sorted_syms[x]) <= section->vma + addr_offset);
- ++x)
- continue;
- disasm_info.symbols = & sorted_syms[place];
- disasm_info.num_symbols = x - place;
- }
- else
- disasm_info.symbols = NULL;
-
- if (! prefix_addresses)
- {
- printf ("\n");
- objdump_print_addr_with_sym (abfd, section, sym,
- section->vma + addr_offset,
- &disasm_info,
- false);
- printf (":\n");
- }
-
- if (sym != NULL && bfd_asymbol_value (sym) > section->vma + addr_offset)
- nextsym = sym;
- else if (sym == NULL)
- nextsym = NULL;
- else
- {
- /* Search forward for the next appropriate symbol in
- SECTION. Note that all the symbols are sorted
- together into one big array, and that some sections
- may have overlapping addresses. */
- while (place < sorted_symcount
- && (sorted_syms[place]->section != section
- || (bfd_asymbol_value (sorted_syms[place])
- <= bfd_asymbol_value (sym))))
- ++place;
- if (place >= sorted_symcount)
- nextsym = NULL;
- else
- nextsym = sorted_syms[place];
- }
-
- if (sym != NULL && bfd_asymbol_value (sym) > section->vma + addr_offset)
- {
- nextstop_offset = bfd_asymbol_value (sym) - section->vma;
- if (nextstop_offset > stop_offset)
- nextstop_offset = stop_offset;
- }
- else if (nextsym == NULL)
- nextstop_offset = stop_offset;
- else
- {
- nextstop_offset = bfd_asymbol_value (nextsym) - section->vma;
- if (nextstop_offset > stop_offset)
- nextstop_offset = stop_offset;
- }
-
- /* If a symbol is explicitly marked as being an object
- rather than a function, just dump the bytes without
- disassembling them. */
- if (disassemble_all
- || sym == NULL
- || bfd_asymbol_value (sym) > section->vma + addr_offset
- || ((sym->flags & BSF_OBJECT) == 0
- && (strstr (bfd_asymbol_name (sym), "gnu_compiled")
- == NULL)
- && (strstr (bfd_asymbol_name (sym), "gcc2_compiled")
- == NULL))
- || (sym->flags & BSF_FUNCTION) != 0)
- insns = true;
- else
- insns = false;
-
- disassemble_bytes (&disasm_info, disassemble_fn, insns, data,
- addr_offset, nextstop_offset, &relpp, relppend);
-
- addr_offset = nextstop_offset;
- sym = nextsym;
- }
+ bfd_map_over_sections (abfd, disassemble_section, & disasm_info);
- free (data);
- if (relbuf != NULL)
- free (relbuf);
- }
+ if (aux.dynrelbuf != NULL)
+ free (aux.dynrelbuf);
free (sorted_syms);
}
+/* Read ABFD's stabs section STABSECT_NAME, and return a pointer to
+ it. Return NULL on failure. */
-/* Define a table of stab values and print-strings. We wish the initializer
- could be a direct-mapped table, but instead we build one the first
- time we need it. */
-
-static void dump_section_stabs PARAMS ((bfd *abfd, char *stabsect_name,
- char *strsect_name));
-
-/* Dump the stabs sections from an object file that has a section that
- uses Sun stabs encoding. */
-
-static void
-dump_stabs (abfd)
- bfd *abfd;
+static char *
+read_section_stabs (bfd *abfd, const char *sect_name, bfd_size_type *size_ptr)
{
- dump_section_stabs (abfd, ".stab", ".stabstr");
- dump_section_stabs (abfd, ".stab.excl", ".stab.exclstr");
- dump_section_stabs (abfd, ".stab.index", ".stab.indexstr");
- dump_section_stabs (abfd, "$GDB_SYMBOLS$", "$GDB_STRINGS$");
-}
-
-static bfd_byte *stabs;
-static bfd_size_type stab_size;
+ asection *stabsect;
+ bfd_size_type size;
+ char *contents;
-static char *strtab;
-static bfd_size_type stabstr_size;
-
-/* Read ABFD's stabs section STABSECT_NAME into `stabs'
- and string table section STRSECT_NAME into `strtab'.
- If the section exists and was read, allocate the space and return true.
- Otherwise return false. */
-
-static boolean
-read_section_stabs (abfd, stabsect_name, strsect_name)
- bfd *abfd;
- const char *stabsect_name;
- const char *strsect_name;
-{
- asection *stabsect, *stabstrsect;
-
- stabsect = bfd_get_section_by_name (abfd, stabsect_name);
- if (0 == stabsect)
+ stabsect = bfd_get_section_by_name (abfd, sect_name);
+ if (stabsect == NULL)
{
- printf (_("No %s section present\n\n"), stabsect_name);
- return false;
+ printf (_("No %s section present\n\n"), sect_name);
+ return FALSE;
}
- stabstrsect = bfd_get_section_by_name (abfd, strsect_name);
- if (0 == stabstrsect)
- {
- non_fatal (_("%s has no %s section"),
- bfd_get_filename (abfd), strsect_name);
- exit_status = 1;
- return false;
- }
+ size = bfd_section_size (abfd, stabsect);
+ contents = xmalloc (size);
- stab_size = bfd_section_size (abfd, stabsect);
- stabstr_size = bfd_section_size (abfd, stabstrsect);
-
- stabs = (bfd_byte *) xmalloc (stab_size);
- strtab = (char *) xmalloc (stabstr_size);
-
- if (! bfd_get_section_contents (abfd, stabsect, (PTR) stabs, 0, stab_size))
+ if (! bfd_get_section_contents (abfd, stabsect, contents, 0, size))
{
non_fatal (_("Reading %s section of %s failed: %s"),
- stabsect_name, bfd_get_filename (abfd),
+ sect_name, bfd_get_filename (abfd),
bfd_errmsg (bfd_get_error ()));
- free (stabs);
- free (strtab);
+ free (contents);
exit_status = 1;
- return false;
+ return NULL;
}
- if (! bfd_get_section_contents (abfd, stabstrsect, (PTR) strtab, 0,
- stabstr_size))
- {
- non_fatal (_("Reading %s section of %s failed: %s\n"),
- strsect_name, bfd_get_filename (abfd),
- bfd_errmsg (bfd_get_error ()));
- free (stabs);
- free (strtab);
- exit_status = 1;
- return false;
- }
+ *size_ptr = size;
- return true;
+ return contents;
}
/* Stabs entries use a 12 byte format:
@@ -1868,24 +1937,24 @@ read_section_stabs (abfd, stabsect_name, strsect_name)
4 byte stab value
FIXME: This will have to change for a 64 bit object format. */
-#define STRDXOFF (0)
-#define TYPEOFF (4)
-#define OTHEROFF (5)
-#define DESCOFF (6)
-#define VALOFF (8)
+#define STRDXOFF (0)
+#define TYPEOFF (4)
+#define OTHEROFF (5)
+#define DESCOFF (6)
+#define VALOFF (8)
#define STABSIZE (12)
/* Print ABFD's stabs section STABSECT_NAME (in `stabs'),
using string table section STRSECT_NAME (in `strtab'). */
static void
-print_section_stabs (abfd, stabsect_name, strsect_name)
- bfd *abfd;
- const char *stabsect_name;
- const char *strsect_name ATTRIBUTE_UNUSED;
+print_section_stabs (bfd *abfd,
+ const char *stabsect_name,
+ unsigned *string_offset_ptr)
{
int i;
- unsigned file_string_table_offset = 0, next_file_string_table_offset = 0;
+ unsigned file_string_table_offset = 0;
+ unsigned next_file_string_table_offset = *string_offset_ptr;
bfd_byte *stabp, *stabs_end;
stabp = stabs;
@@ -1898,7 +1967,6 @@ print_section_stabs (abfd, stabsect_name, strsect_name)
We start the index at -1 because there is a dummy symbol on
the front of stabs-in-{coff,elf} sections that supplies sizes. */
-
for (i = -1; stabp < stabs_end; stabp += STABSIZE, i++)
{
const char *name;
@@ -1930,7 +1998,6 @@ print_section_stabs (abfd, stabsect_name, strsect_name)
/* Symbols with type == 0 (N_UNDF) specify the length of the
string table associated with this file. We use that info
to know how to relocate the *next* file's string table indices. */
-
if (type == N_UNDF)
{
file_string_table_offset = next_file_string_table_offset;
@@ -1940,7 +2007,6 @@ print_section_stabs (abfd, stabsect_name, strsect_name)
{
/* Using the (possibly updated) string table offset, print the
string (if any) associated with this symbol. */
-
if ((strx + file_string_table_offset) < stabstr_size)
printf (" %s", &strtab[strx + file_string_table_offset]);
else
@@ -1948,46 +2014,75 @@ print_section_stabs (abfd, stabsect_name, strsect_name)
}
}
printf ("\n\n");
+ *string_offset_ptr = next_file_string_table_offset;
+}
+
+typedef struct
+{
+ const char * section_name;
+ const char * string_section_name;
+ unsigned string_offset;
}
+stab_section_names;
static void
-dump_section_stabs (abfd, stabsect_name, strsect_name)
- bfd *abfd;
- char *stabsect_name;
- char *strsect_name;
+find_stabs_section (bfd *abfd, asection *section, void *names)
{
- asection *s;
+ int len;
+ stab_section_names * sought = (stab_section_names *) names;
/* Check for section names for which stabsect_name is a prefix, to
- handle .stab0, etc. */
- for (s = abfd->sections;
- s != NULL;
- s = s->next)
+ handle .stab.N, etc. */
+ len = strlen (sought->section_name);
+
+ /* If the prefix matches, and the files section name ends with a
+ nul or a digit, then we match. I.e., we want either an exact
+ match or a section followed by a number. */
+ if (strncmp (sought->section_name, section->name, len) == 0
+ && (section->name[len] == 0
+ || (section->name[len] == '.' && ISDIGIT (section->name[len + 1]))))
{
- int len;
-
- len = strlen (stabsect_name);
-
- /* If the prefix matches, and the files section name ends with a
- nul or a digit, then we match. I.e., we want either an exact
- match or a section followed by a number. */
- if (strncmp (stabsect_name, s->name, len) == 0
- && (s->name[len] == '\000'
- || ISDIGIT (s->name[len])))
+ if (strtab == NULL)
+ strtab = read_section_stabs (abfd, sought->string_section_name,
+ &stabstr_size);
+
+ if (strtab)
{
- if (read_section_stabs (abfd, s->name, strsect_name))
- {
- print_section_stabs (abfd, s->name, strsect_name);
- free (stabs);
- free (strtab);
- }
+ stabs = read_section_stabs (abfd, section->name, &stab_size);
+ if (stabs)
+ print_section_stabs (abfd, section->name, &sought->string_offset);
}
}
}
+
+static void
+dump_stabs_section (bfd *abfd, char *stabsect_name, char *strsect_name)
+{
+ stab_section_names s;
+
+ s.section_name = stabsect_name;
+ s.string_section_name = strsect_name;
+ s.string_offset = 0;
+
+ bfd_map_over_sections (abfd, find_stabs_section, & s);
+
+ free (strtab);
+ strtab = NULL;
+}
+
+/* Dump the any sections containing stabs debugging information. */
+
+static void
+dump_stabs (bfd *abfd)
+{
+ dump_stabs_section (abfd, ".stab", ".stabstr");
+ dump_stabs_section (abfd, ".stab.excl", ".stab.exclstr");
+ dump_stabs_section (abfd, ".stab.index", ".stab.indexstr");
+ dump_stabs_section (abfd, "$GDB_SYMBOLS$", "$GDB_STRINGS$");
+}
static void
-dump_bfd_header (abfd)
- bfd *abfd;
+dump_bfd_header (bfd *abfd)
{
char *comma = "";
@@ -2007,275 +2102,153 @@ dump_bfd_header (abfd)
PF (WP_TEXT, "WP_TEXT");
PF (D_PAGED, "D_PAGED");
PF (BFD_IS_RELAXABLE, "BFD_IS_RELAXABLE");
+ PF (HAS_LOAD_PAGE, "HAS_LOAD_PAGE");
printf (_("\nstart address 0x"));
bfd_printf_vma (abfd, abfd->start_address);
printf ("\n");
}
+
static void
-dump_bfd_private_header (abfd)
-bfd *abfd;
+dump_bfd_private_header (bfd *abfd)
{
bfd_print_private_bfd_data (abfd, stdout);
}
-/* Dump selected contents of ABFD */
+
+/* Display a section in hexadecimal format with associated characters.
+ Each line prefixed by the zero padded address. */
static void
-dump_bfd (abfd)
- bfd *abfd;
+dump_section (bfd *abfd, asection *section, void *dummy ATTRIBUTE_UNUSED)
{
- /* If we are adjusting section VMA's, change them all now. Changing
- the BFD information is a hack. However, we must do it, or
- bfd_find_nearest_line will not do the right thing. */
- if (adjust_section_vma != 0)
- {
- asection *s;
+ bfd_byte *data = 0;
+ bfd_size_type datasize;
+ bfd_size_type addr_offset;
+ bfd_size_type start_offset;
+ bfd_size_type stop_offset;
+ unsigned int opb = bfd_octets_per_byte (abfd);
+ /* Bytes per line. */
+ const int onaline = 16;
+ char buf[64];
+ int count;
+ int width;
- for (s = abfd->sections; s != NULL; s = s->next)
- {
- s->vma += adjust_section_vma;
- s->lma += adjust_section_vma;
- }
- }
+ if ((section->flags & SEC_HAS_CONTENTS) == 0)
+ return;
- printf (_("\n%s: file format %s\n"), bfd_get_filename (abfd),
- abfd->xvec->name);
- if (dump_ar_hdrs)
- print_arelt_descr (stdout, abfd, true);
- if (dump_file_header)
- dump_bfd_header (abfd);
- if (dump_private_headers)
- dump_bfd_private_header (abfd);
- putchar ('\n');
- if (dump_section_headers)
- dump_headers (abfd);
- if (dump_symtab || dump_reloc_info || disassemble || dump_debugging)
- {
- syms = slurp_symtab (abfd);
- }
- if (dump_dynamic_symtab || dump_dynamic_reloc_info)
- {
- dynsyms = slurp_dynamic_symtab (abfd);
- }
- if (dump_symtab)
- dump_symbols (abfd, false);
- if (dump_dynamic_symtab)
- dump_symbols (abfd, true);
- if (dump_stab_section_info)
- dump_stabs (abfd);
- if (dump_reloc_info && ! disassemble)
- dump_relocs (abfd);
- if (dump_dynamic_reloc_info)
- dump_dynamic_relocs (abfd);
- if (dump_section_contents)
- dump_data (abfd);
- if (disassemble)
- disassemble_data (abfd);
- if (dump_debugging)
- {
- PTR dhandle;
+ if (! process_section_p (section))
+ return;
+
+ if ((datasize = bfd_section_size (abfd, section)) == 0)
+ return;
- dhandle = read_debugging_info (abfd, syms, symcount);
- if (dhandle != NULL)
- {
- if (! print_debugging_info (stdout, dhandle))
- {
- non_fatal (_("%s: printing debugging information failed"),
- bfd_get_filename (abfd));
- exit_status = 1;
- }
- }
- }
- if (syms)
- {
- free (syms);
- syms = NULL;
- }
- if (dynsyms)
- {
- free (dynsyms);
- dynsyms = NULL;
- }
-}
+ printf (_("Contents of section %s:\n"), section->name);
-static void
-display_bfd (abfd)
- bfd *abfd;
-{
- char **matching;
+ data = xmalloc (datasize);
- if (bfd_check_format_matches (abfd, bfd_object, &matching))
- {
- dump_bfd (abfd);
- return;
- }
+ bfd_get_section_contents (abfd, section, data, 0, datasize);
- if (bfd_get_error () == bfd_error_file_ambiguously_recognized)
- {
- nonfatal (bfd_get_filename (abfd));
- list_matching_formats (matching);
- free (matching);
- return;
- }
+ /* Compute the address range to display. */
+ if (start_address == (bfd_vma) -1
+ || start_address < section->vma)
+ start_offset = 0;
+ else
+ start_offset = start_address - section->vma;
- if (bfd_get_error () != bfd_error_file_not_recognized)
+ if (stop_address == (bfd_vma) -1)
+ stop_offset = datasize / opb;
+ else
{
- nonfatal (bfd_get_filename (abfd));
- return;
- }
+ if (stop_address < section->vma)
+ stop_offset = 0;
+ else
+ stop_offset = stop_address - section->vma;
- if (bfd_check_format_matches (abfd, bfd_core, &matching))
- {
- dump_bfd (abfd);
- return;
+ if (stop_offset > datasize / opb)
+ stop_offset = datasize / opb;
}
- nonfatal (bfd_get_filename (abfd));
+ width = 4;
- if (bfd_get_error () == bfd_error_file_ambiguously_recognized)
- {
- list_matching_formats (matching);
- free (matching);
- }
-}
+ bfd_sprintf_vma (abfd, buf, start_offset + section->vma);
+ if (strlen (buf) >= sizeof (buf))
+ abort ();
-static void
-display_file (filename, target)
- char *filename;
- char *target;
-{
- bfd *file, *arfile = (bfd *) NULL;
+ count = 0;
+ while (buf[count] == '0' && buf[count+1] != '\0')
+ count++;
+ count = strlen (buf) - count;
+ if (count > width)
+ width = count;
- file = bfd_openr (filename, target);
- if (file == NULL)
- {
- nonfatal (filename);
- return;
- }
+ bfd_sprintf_vma (abfd, buf, stop_offset + section->vma - 1);
+ if (strlen (buf) >= sizeof (buf))
+ abort ();
- if (bfd_check_format (file, bfd_archive) == true)
- {
- bfd *last_arfile = NULL;
+ count = 0;
+ while (buf[count] == '0' && buf[count+1] != '\0')
+ count++;
+ count = strlen (buf) - count;
+ if (count > width)
+ width = count;
- printf (_("In archive %s:\n"), bfd_get_filename (file));
- for (;;)
- {
- bfd_set_error (bfd_error_no_error);
+ for (addr_offset = start_offset;
+ addr_offset < stop_offset; addr_offset += onaline / opb)
+ {
+ bfd_size_type j;
- arfile = bfd_openr_next_archived_file (file, arfile);
- if (arfile == NULL)
- {
- if (bfd_get_error () != bfd_error_no_more_archived_files)
- nonfatal (bfd_get_filename (file));
- break;
- }
+ bfd_sprintf_vma (abfd, buf, (addr_offset + section->vma));
+ count = strlen (buf);
+ if ((size_t) count >= sizeof (buf))
+ abort ();
- display_bfd (arfile);
+ putchar (' ');
+ while (count < width)
+ {
+ putchar ('0');
+ count++;
+ }
+ fputs (buf + count - width, stdout);
+ putchar (' ');
- if (last_arfile != NULL)
- bfd_close (last_arfile);
- last_arfile = arfile;
+ for (j = addr_offset * opb;
+ j < addr_offset * opb + onaline; j++)
+ {
+ if (j < stop_offset * opb)
+ printf ("%02x", (unsigned) (data[j]));
+ else
+ printf (" ");
+ if ((j & 3) == 3)
+ printf (" ");
}
- if (last_arfile != NULL)
- bfd_close (last_arfile);
+ printf (" ");
+ for (j = addr_offset * opb;
+ j < addr_offset * opb + onaline; j++)
+ {
+ if (j >= stop_offset * opb)
+ printf (" ");
+ else
+ printf ("%c", ISPRINT (data[j]) ? data[j] : '.');
+ }
+ putchar ('\n');
}
- else
- display_bfd (file);
-
- bfd_close (file);
+ free (data);
}
-
-/* Actually display the various requested regions */
+
+/* Actually display the various requested regions. */
static void
-dump_data (abfd)
- bfd *abfd;
+dump_data (bfd *abfd)
{
- asection *section;
- bfd_byte *data = 0;
- bfd_size_type datasize = 0;
- bfd_size_type addr_offset;
- bfd_size_type start_offset, stop_offset;
- unsigned int opb = bfd_octets_per_byte (abfd);
-
- for (section = abfd->sections; section != NULL; section =
- section->next)
- {
- int onaline = 16;
-
- if (only == (char *) NULL ||
- strcmp (only, section->name) == 0)
- {
- if (section->flags & SEC_HAS_CONTENTS)
- {
- printf (_("Contents of section %s:\n"), section->name);
-
- if (bfd_section_size (abfd, section) == 0)
- continue;
- data = (bfd_byte *) xmalloc ((size_t) bfd_section_size (abfd, section));
- datasize = bfd_section_size (abfd, section);
-
-
- bfd_get_section_contents (abfd, section, (PTR) data, 0, bfd_section_size (abfd, section));
-
- if (start_address == (bfd_vma) -1
- || start_address < section->vma)
- start_offset = 0;
- else
- start_offset = start_address - section->vma;
- if (stop_address == (bfd_vma) -1)
- stop_offset = bfd_section_size (abfd, section) / opb;
- else
- {
- if (stop_address < section->vma)
- stop_offset = 0;
- else
- stop_offset = stop_address - section->vma;
- if (stop_offset > bfd_section_size (abfd, section) / opb)
- stop_offset = bfd_section_size (abfd, section) / opb;
- }
- for (addr_offset = start_offset;
- addr_offset < stop_offset; addr_offset += onaline / opb)
- {
- bfd_size_type j;
-
- printf (" %04lx ", (unsigned long int)
- (addr_offset + section->vma));
- for (j = addr_offset * opb;
- j < addr_offset * opb + onaline; j++)
- {
- if (j < stop_offset * opb)
- printf ("%02x", (unsigned) (data[j]));
- else
- printf (" ");
- if ((j & 3) == 3)
- printf (" ");
- }
-
- printf (" ");
- for (j = addr_offset * opb;
- j < addr_offset * opb + onaline; j++)
- {
- if (j >= stop_offset * opb)
- printf (" ");
- else
- printf ("%c", ISPRINT (data[j]) ? data[j] : '.');
- }
- putchar ('\n');
- }
- free (data);
- }
- }
- }
+ bfd_map_over_sections (abfd, dump_section, NULL);
}
-/* Should perhaps share code and display with nm? */
+/* Should perhaps share code and display with nm? */
+
static void
-dump_symbols (abfd, dynamic)
- bfd *abfd ATTRIBUTE_UNUSED;
- boolean dynamic;
+dump_symbols (bfd *abfd ATTRIBUTE_UNUSED, bfd_boolean dynamic)
{
asymbol **current;
long max;
@@ -2285,160 +2258,60 @@ dump_symbols (abfd, dynamic)
{
current = dynsyms;
max = dynsymcount;
- if (max == 0)
- return;
printf ("DYNAMIC SYMBOL TABLE:\n");
}
else
{
current = syms;
max = symcount;
- if (max == 0)
- return;
printf ("SYMBOL TABLE:\n");
}
+ if (max == 0)
+ printf (_("no symbols\n"));
+
for (count = 0; count < max; count++)
{
- if (*current)
+ bfd *cur_bfd;
+
+ if (*current == NULL)
+ printf (_("no information for the %ld'th symbol"), count);
+
+ else if ((cur_bfd = bfd_asymbol_bfd (*current)) == NULL)
+ printf (_("could not determine the type of the %ld'th symbol"),
+ count);
+
+ else
{
- bfd *cur_bfd = bfd_asymbol_bfd (*current);
+ const char *name = (*current)->name;
- if (cur_bfd != NULL)
+ if (do_demangle && name != NULL && *name != '\0')
{
- const char *name;
char *alloc;
- name = (*current)->name;
- alloc = NULL;
- if (do_demangle && name != NULL && *name != '\0')
- {
- /* If we want to demangle the name, we demangle it
- here, and temporarily clobber it while calling
- bfd_print_symbol. FIXME: This is a gross hack. */
-
- alloc = demangle (cur_bfd, name);
- (*current)->name = alloc;
- }
-
+ /* If we want to demangle the name, we demangle it
+ here, and temporarily clobber it while calling
+ bfd_print_symbol. FIXME: This is a gross hack. */
+ alloc = demangle (cur_bfd, name);
+ (*current)->name = alloc;
bfd_print_symbol (cur_bfd, stdout, *current,
bfd_print_symbol_all);
-
(*current)->name = name;
- if (alloc != NULL)
- free (alloc);
-
- printf ("\n");
- }
- }
- current++;
- }
- printf ("\n");
- printf ("\n");
-}
-
-static void
-dump_relocs (abfd)
- bfd *abfd;
-{
- arelent **relpp;
- long relcount;
- asection *a;
-
- for (a = abfd->sections; a != (asection *) NULL; a = a->next)
- {
- long relsize;
-
- if (bfd_is_abs_section (a))
- continue;
- if (bfd_is_und_section (a))
- continue;
- if (bfd_is_com_section (a))
- continue;
-
- if (only)
- {
- if (strcmp (only, a->name))
- continue;
- }
- else if ((a->flags & SEC_RELOC) == 0)
- continue;
-
- relsize = bfd_get_reloc_upper_bound (abfd, a);
- if (relsize < 0)
- bfd_fatal (bfd_get_filename (abfd));
-
- printf ("RELOCATION RECORDS FOR [%s]:", a->name);
-
- if (relsize == 0)
- {
- printf (" (none)\n\n");
- }
- else
- {
- relpp = (arelent **) xmalloc (relsize);
- relcount = bfd_canonicalize_reloc (abfd, a, relpp, syms);
- if (relcount < 0)
- bfd_fatal (bfd_get_filename (abfd));
- else if (relcount == 0)
- {
- printf (" (none)\n\n");
+ free (alloc);
}
else
- {
- printf ("\n");
- dump_reloc_set (abfd, a, relpp, relcount);
- printf ("\n\n");
- }
- free (relpp);
+ bfd_print_symbol (cur_bfd, stdout, *current,
+ bfd_print_symbol_all);
}
- }
-}
-
-static void
-dump_dynamic_relocs (abfd)
- bfd *abfd;
-{
- long relsize;
- arelent **relpp;
- long relcount;
-
- relsize = bfd_get_dynamic_reloc_upper_bound (abfd);
- if (relsize < 0)
- bfd_fatal (bfd_get_filename (abfd));
- printf ("DYNAMIC RELOCATION RECORDS");
-
- if (relsize == 0)
- {
- printf (" (none)\n\n");
- }
- else
- {
- relpp = (arelent **) xmalloc (relsize);
- relcount = bfd_canonicalize_dynamic_reloc (abfd, relpp, dynsyms);
- if (relcount < 0)
- bfd_fatal (bfd_get_filename (abfd));
- else if (relcount == 0)
- {
- printf (" (none)\n\n");
- }
- else
- {
- printf ("\n");
- dump_reloc_set (abfd, (asection *) NULL, relpp, relcount);
- printf ("\n\n");
- }
- free (relpp);
+ printf ("\n");
+ current++;
}
+ printf ("\n\n");
}
-
+
static void
-dump_reloc_set (abfd, sec, relpp, relcount)
- bfd *abfd;
- asection *sec;
- arelent **relpp;
- long relcount;
+dump_reloc_set (bfd *abfd, asection *sec, arelent **relpp, long relcount)
{
arelent **p;
char *last_filename, *last_functionname;
@@ -2447,9 +2320,11 @@ dump_reloc_set (abfd, sec, relpp, relcount)
/* Get column headers lined up reasonably. */
{
static int width;
+
if (width == 0)
{
char buf[30];
+
bfd_sprintf_vma (abfd, buf, (bfd_vma) -1);
width = strlen (buf) - 7;
}
@@ -2460,7 +2335,7 @@ dump_reloc_set (abfd, sec, relpp, relcount)
last_functionname = NULL;
last_line = 0;
- for (p = relpp; relcount && *p != (arelent *) NULL; p++, relcount--)
+ for (p = relpp; relcount && *p != NULL; p++, relcount--)
{
arelent *q = *p;
const char *filename, *functionname;
@@ -2489,6 +2364,7 @@ dump_reloc_set (abfd, sec, relpp, relcount)
free (last_functionname);
last_functionname = xstrdup (functionname);
}
+
if (line > 0
&& (line != last_line
|| (filename != NULL
@@ -2516,6 +2392,7 @@ dump_reloc_set (abfd, sec, relpp, relcount)
sym_name = NULL;
section_name = NULL;
}
+
if (sym_name)
{
bfd_printf_vma (abfd, q->address);
@@ -2523,221 +2400,317 @@ dump_reloc_set (abfd, sec, relpp, relcount)
printf (" %-16s ", q->howto->name);
else
printf (" %-16d ", q->howto->type);
- objdump_print_symname (abfd, (struct disassemble_info *) NULL,
- *q->sym_ptr_ptr);
+ objdump_print_symname (abfd, NULL, *q->sym_ptr_ptr);
}
else
{
- if (section_name == (const char *) NULL)
+ if (section_name == NULL)
section_name = "*unknown*";
bfd_printf_vma (abfd, q->address);
printf (" %-16s [%s]",
q->howto->name,
section_name);
}
+
if (q->addend)
{
printf ("+0x");
bfd_printf_vma (abfd, q->addend);
}
+
printf ("\n");
}
}
-
-/* The length of the longest architecture name + 1. */
-#define LONGEST_ARCH sizeof("powerpc:common")
-static const char *
-endian_string (endian)
- enum bfd_endian endian;
+static void
+dump_relocs_in_section (bfd *abfd,
+ asection *section,
+ void *dummy ATTRIBUTE_UNUSED)
{
- if (endian == BFD_ENDIAN_BIG)
- return "big endian";
- else if (endian == BFD_ENDIAN_LITTLE)
- return "little endian";
+ arelent **relpp;
+ long relcount;
+ long relsize;
+
+ if ( bfd_is_abs_section (section)
+ || bfd_is_und_section (section)
+ || bfd_is_com_section (section)
+ || (! process_section_p (section))
+ || ((section->flags & SEC_RELOC) == 0))
+ return;
+
+ relsize = bfd_get_reloc_upper_bound (abfd, section);
+ if (relsize < 0)
+ bfd_fatal (bfd_get_filename (abfd));
+
+ printf ("RELOCATION RECORDS FOR [%s]:", section->name);
+
+ if (relsize == 0)
+ {
+ printf (" (none)\n\n");
+ return;
+ }
+
+ relpp = xmalloc (relsize);
+ relcount = bfd_canonicalize_reloc (abfd, section, relpp, syms);
+
+ if (relcount < 0)
+ bfd_fatal (bfd_get_filename (abfd));
+ else if (relcount == 0)
+ printf (" (none)\n\n");
else
- return "endianness unknown";
+ {
+ printf ("\n");
+ dump_reloc_set (abfd, section, relpp, relcount);
+ printf ("\n\n");
+ }
+ free (relpp);
}
-/* List the targets that BFD is configured to support, each followed
- by its endianness and the architectures it supports. */
+static void
+dump_relocs (bfd *abfd)
+{
+ bfd_map_over_sections (abfd, dump_relocs_in_section, NULL);
+}
static void
-display_target_list ()
+dump_dynamic_relocs (bfd *abfd)
{
- extern const bfd_target *const *bfd_target_vector;
- char *dummy_name;
- int t;
+ long relsize;
+ arelent **relpp;
+ long relcount;
- dummy_name = make_temp_file (NULL);
- for (t = 0; bfd_target_vector[t]; t++)
- {
- const bfd_target *p = bfd_target_vector[t];
- bfd *abfd = bfd_openw (dummy_name, p->name);
- int a;
+ relsize = bfd_get_dynamic_reloc_upper_bound (abfd);
+ if (relsize < 0)
+ bfd_fatal (bfd_get_filename (abfd));
- printf ("%s\n (header %s, data %s)\n", p->name,
- endian_string (p->header_byteorder),
- endian_string (p->byteorder));
+ printf ("DYNAMIC RELOCATION RECORDS");
- if (abfd == NULL)
- {
- nonfatal (dummy_name);
- continue;
- }
+ if (relsize == 0)
+ printf (" (none)\n\n");
+ else
+ {
+ relpp = xmalloc (relsize);
+ relcount = bfd_canonicalize_dynamic_reloc (abfd, relpp, dynsyms);
- if (! bfd_set_format (abfd, bfd_object))
+ if (relcount < 0)
+ bfd_fatal (bfd_get_filename (abfd));
+ else if (relcount == 0)
+ printf (" (none)\n\n");
+ else
{
- if (bfd_get_error () != bfd_error_invalid_operation)
- nonfatal (p->name);
- bfd_close_all_done (abfd);
- continue;
+ printf ("\n");
+ dump_reloc_set (abfd, NULL, relpp, relcount);
+ printf ("\n\n");
}
-
- for (a = (int) bfd_arch_obscure + 1; a < (int) bfd_arch_last; a++)
- if (bfd_set_arch_mach (abfd, (enum bfd_architecture) a, 0))
- printf (" %s\n",
- bfd_printable_arch_mach ((enum bfd_architecture) a, 0));
- bfd_close_all_done (abfd);
+ free (relpp);
}
- unlink (dummy_name);
- free (dummy_name);
}
-/* Print a table showing which architectures are supported for entries
- FIRST through LAST-1 of bfd_target_vector (targets across,
- architectures down). */
+/* Creates a table of paths, to search for source files. */
static void
-display_info_table (first, last)
- int first;
- int last;
+add_include_path (const char *path)
{
- extern const bfd_target *const *bfd_target_vector;
- int t, a;
- char *dummy_name;
-
- /* Print heading of target names. */
- printf ("\n%*s", (int) LONGEST_ARCH, " ");
- for (t = first; t < last && bfd_target_vector[t]; t++)
- printf ("%s ", bfd_target_vector[t]->name);
- putchar ('\n');
-
- dummy_name = make_temp_file (NULL);
- for (a = (int) bfd_arch_obscure + 1; a < (int) bfd_arch_last; a++)
- if (strcmp (bfd_printable_arch_mach (a, 0), "UNKNOWN!") != 0)
- {
- printf ("%*s ", (int) LONGEST_ARCH - 1,
- bfd_printable_arch_mach (a, 0));
- for (t = first; t < last && bfd_target_vector[t]; t++)
- {
- const bfd_target *p = bfd_target_vector[t];
- boolean ok = true;
- bfd *abfd = bfd_openw (dummy_name, p->name);
-
- if (abfd == NULL)
- {
- nonfatal (p->name);
- ok = false;
- }
-
- if (ok)
- {
- if (! bfd_set_format (abfd, bfd_object))
- {
- if (bfd_get_error () != bfd_error_invalid_operation)
- nonfatal (p->name);
- ok = false;
- }
- }
-
- if (ok)
- {
- if (! bfd_set_arch_mach (abfd, a, 0))
- ok = false;
- }
-
- if (ok)
- printf ("%s ", p->name);
- else
- {
- int l = strlen (p->name);
- while (l--)
- putchar ('-');
- putchar (' ');
- }
- if (abfd != NULL)
- bfd_close_all_done (abfd);
- }
- putchar ('\n');
- }
- unlink (dummy_name);
- free (dummy_name);
+ if (path[0] == 0)
+ return;
+ include_path_count++;
+ include_paths = xrealloc (include_paths,
+ include_path_count * sizeof (*include_paths));
+#ifdef HAVE_DOS_BASED_FILE_SYSTEM
+ if (path[1] == ':' && path[2] == 0)
+ path = concat (path, ".", (const char *) 0);
+#endif
+ include_paths[include_path_count - 1] = path;
}
-/* Print tables of all the target-architecture combinations that
- BFD has been configured to support. */
+static void
+adjust_addresses (bfd *abfd ATTRIBUTE_UNUSED,
+ asection *section,
+ void *dummy ATTRIBUTE_UNUSED)
+{
+ section->vma += adjust_section_vma;
+ section->lma += adjust_section_vma;
+}
+
+/* Dump selected contents of ABFD. */
static void
-display_target_tables ()
+dump_bfd (bfd *abfd)
{
- int t, columns;
- extern const bfd_target *const *bfd_target_vector;
- char *colum;
-
- columns = 0;
- colum = getenv ("COLUMNS");
- if (colum != NULL)
- columns = atoi (colum);
- if (columns == 0)
- columns = 80;
-
- t = 0;
- while (bfd_target_vector[t] != NULL)
+ /* If we are adjusting section VMA's, change them all now. Changing
+ the BFD information is a hack. However, we must do it, or
+ bfd_find_nearest_line will not do the right thing. */
+ if (adjust_section_vma != 0)
+ bfd_map_over_sections (abfd, adjust_addresses, NULL);
+
+ if (! dump_debugging_tags)
+ printf (_("\n%s: file format %s\n"), bfd_get_filename (abfd),
+ abfd->xvec->name);
+ if (dump_ar_hdrs)
+ print_arelt_descr (stdout, abfd, TRUE);
+ if (dump_file_header)
+ dump_bfd_header (abfd);
+ if (dump_private_headers)
+ dump_bfd_private_header (abfd);
+ if (! dump_debugging_tags)
+ putchar ('\n');
+ if (dump_section_headers)
+ dump_headers (abfd);
+
+ if (dump_symtab || dump_reloc_info || disassemble || dump_debugging)
+ syms = slurp_symtab (abfd);
+ if (dump_dynamic_symtab || dump_dynamic_reloc_info)
+ dynsyms = slurp_dynamic_symtab (abfd);
+
+ if (dump_symtab)
+ dump_symbols (abfd, FALSE);
+ if (dump_dynamic_symtab)
+ dump_symbols (abfd, TRUE);
+ if (dump_stab_section_info)
+ dump_stabs (abfd);
+ if (dump_reloc_info && ! disassemble)
+ dump_relocs (abfd);
+ if (dump_dynamic_reloc_info && ! disassemble)
+ dump_dynamic_relocs (abfd);
+ if (dump_section_contents)
+ dump_data (abfd);
+ if (disassemble)
+ disassemble_data (abfd);
+
+ if (dump_debugging)
{
- int oldt = t, wid;
+ void *dhandle;
- wid = LONGEST_ARCH + strlen (bfd_target_vector[t]->name) + 1;
- ++t;
- while (wid < columns && bfd_target_vector[t] != NULL)
+ dhandle = read_debugging_info (abfd, syms, symcount);
+ if (dhandle != NULL)
{
- int newwid;
-
- newwid = wid + strlen (bfd_target_vector[t]->name) + 1;
- if (newwid >= columns)
- break;
- wid = newwid;
- ++t;
+ if (! print_debugging_info (stdout, dhandle, abfd, syms, demangle,
+ dump_debugging_tags ? TRUE : FALSE))
+ {
+ non_fatal (_("%s: printing debugging information failed"),
+ bfd_get_filename (abfd));
+ exit_status = 1;
+ }
}
- display_info_table (oldt, t);
+ }
+
+ if (syms)
+ {
+ free (syms);
+ syms = NULL;
+ }
+
+ if (dynsyms)
+ {
+ free (dynsyms);
+ dynsyms = NULL;
}
}
static void
-display_info ()
+display_bfd (bfd *abfd)
{
- printf (_("BFD header file version %s\n"), BFD_VERSION_STRING);
- display_target_list ();
- display_target_tables ();
+ char **matching;
+
+ if (bfd_check_format_matches (abfd, bfd_object, &matching))
+ {
+ dump_bfd (abfd);
+ return;
+ }
+
+ if (bfd_get_error () == bfd_error_file_ambiguously_recognized)
+ {
+ nonfatal (bfd_get_filename (abfd));
+ list_matching_formats (matching);
+ free (matching);
+ return;
+ }
+
+ if (bfd_get_error () != bfd_error_file_not_recognized)
+ {
+ nonfatal (bfd_get_filename (abfd));
+ return;
+ }
+
+ if (bfd_check_format_matches (abfd, bfd_core, &matching))
+ {
+ dump_bfd (abfd);
+ return;
+ }
+
+ nonfatal (bfd_get_filename (abfd));
+
+ if (bfd_get_error () == bfd_error_file_ambiguously_recognized)
+ {
+ list_matching_formats (matching);
+ free (matching);
+ }
}
-int main PARAMS ((int, char **));
+static void
+display_file (char *filename, char *target)
+{
+ bfd *file;
+ bfd *arfile = NULL;
+
+ if (get_file_size (filename) < 1)
+ return;
+
+ file = bfd_openr (filename, target);
+ if (file == NULL)
+ {
+ nonfatal (filename);
+ return;
+ }
+
+ /* If the file is an archive, process all of its elements. */
+ if (bfd_check_format (file, bfd_archive))
+ {
+ bfd *last_arfile = NULL;
+
+ printf (_("In archive %s:\n"), bfd_get_filename (file));
+ for (;;)
+ {
+ bfd_set_error (bfd_error_no_error);
+
+ arfile = bfd_openr_next_archived_file (file, arfile);
+ if (arfile == NULL)
+ {
+ if (bfd_get_error () != bfd_error_no_more_archived_files)
+ nonfatal (bfd_get_filename (file));
+ break;
+ }
+
+ display_bfd (arfile);
+ if (last_arfile != NULL)
+ bfd_close (last_arfile);
+ last_arfile = arfile;
+ }
+
+ if (last_arfile != NULL)
+ bfd_close (last_arfile);
+ }
+ else
+ display_bfd (file);
+
+ bfd_close (file);
+}
+
int
-main (argc, argv)
- int argc;
- char **argv;
+main (int argc, char **argv)
{
int c;
char *target = default_target;
- boolean seenflag = false;
+ bfd_boolean seenflag = FALSE;
-#if defined (HAVE_SETLOCALE) && defined (HAVE_LC_MESSAGES)
+#if defined (HAVE_SETLOCALE)
+#if defined (HAVE_LC_MESSAGES)
setlocale (LC_MESSAGES, "");
#endif
-#if defined (HAVE_SETLOCALE)
setlocale (LC_CTYPE, "");
#endif
+
bindtextdomain (PACKAGE, LOCALEDIR);
textdomain (PACKAGE);
@@ -2749,7 +2722,7 @@ main (argc, argv)
bfd_init ();
set_default_bfd_target ();
- while ((c = getopt_long (argc, argv, "pib:m:M:VvCdDlfaHhrRtTxsSj:wE:zgG",
+ while ((c = getopt_long (argc, argv, "pib:m:M:VvCdDlfaHhrRtTxsSI:j:wE:zgeG",
long_options, (int *) 0))
!= EOF)
{
@@ -2761,19 +2734,29 @@ main (argc, argv)
machine = optarg;
break;
case 'M':
- disassembler_options = optarg;
+ if (disassembler_options)
+ /* Ignore potential memory leak for now. */
+ disassembler_options = concat (disassembler_options, ",",
+ optarg, NULL);
+ else
+ disassembler_options = optarg;
break;
case 'j':
- only = optarg;
+ if (only_used == only_size)
+ {
+ only_size += 8;
+ only = xrealloc (only, only_size * sizeof (char *));
+ }
+ only [only_used++] = optarg;
break;
case 'l':
- with_line_numbers = true;
+ with_line_numbers = TRUE;
break;
case 'b':
target = optarg;
break;
case 'C':
- do_demangle = true;
+ do_demangle = TRUE;
if (optarg != NULL)
{
enum demangling_styles style;
@@ -2787,7 +2770,7 @@ main (argc, argv)
}
break;
case 'w':
- wide_output = true;
+ wide_output = TRUE;
break;
case OPTION_ADJUST_VMA:
adjust_section_vma = parse_vma (optarg, "--adjust-vma");
@@ -2822,86 +2805,95 @@ main (argc, argv)
break;
case 'f':
- dump_file_header = true;
- seenflag = true;
+ dump_file_header = TRUE;
+ seenflag = TRUE;
break;
case 'i':
- formats_info = true;
- seenflag = true;
+ formats_info = TRUE;
+ seenflag = TRUE;
+ break;
+ case 'I':
+ add_include_path (optarg);
break;
case 'p':
- dump_private_headers = true;
- seenflag = true;
+ dump_private_headers = TRUE;
+ seenflag = TRUE;
break;
case 'x':
- dump_private_headers = true;
- dump_symtab = true;
- dump_reloc_info = true;
- dump_file_header = true;
- dump_ar_hdrs = true;
- dump_section_headers = true;
- seenflag = true;
+ dump_private_headers = TRUE;
+ dump_symtab = TRUE;
+ dump_reloc_info = TRUE;
+ dump_file_header = TRUE;
+ dump_ar_hdrs = TRUE;
+ dump_section_headers = TRUE;
+ seenflag = TRUE;
break;
case 't':
- dump_symtab = true;
- seenflag = true;
+ dump_symtab = TRUE;
+ seenflag = TRUE;
break;
case 'T':
- dump_dynamic_symtab = true;
- seenflag = true;
+ dump_dynamic_symtab = TRUE;
+ seenflag = TRUE;
break;
case 'd':
- disassemble = true;
- seenflag = true;
+ disassemble = TRUE;
+ seenflag = TRUE;
break;
case 'z':
- disassemble_zeroes = true;
+ disassemble_zeroes = TRUE;
break;
case 'D':
- disassemble = true;
- disassemble_all = true;
- seenflag = true;
+ disassemble = TRUE;
+ disassemble_all = TRUE;
+ seenflag = TRUE;
break;
case 'S':
- disassemble = true;
- with_source_code = true;
- seenflag = true;
+ disassemble = TRUE;
+ with_source_code = TRUE;
+ seenflag = TRUE;
break;
case 'g':
dump_debugging = 1;
- seenflag = true;
+ seenflag = TRUE;
+ break;
+ case 'e':
+ dump_debugging = 1;
+ dump_debugging_tags = 1;
+ do_demangle = TRUE;
+ seenflag = TRUE;
break;
case 'G':
- dump_stab_section_info = true;
- seenflag = true;
+ dump_stab_section_info = TRUE;
+ seenflag = TRUE;
break;
case 's':
- dump_section_contents = true;
- seenflag = true;
+ dump_section_contents = TRUE;
+ seenflag = TRUE;
break;
case 'r':
- dump_reloc_info = true;
- seenflag = true;
+ dump_reloc_info = TRUE;
+ seenflag = TRUE;
break;
case 'R':
- dump_dynamic_reloc_info = true;
- seenflag = true;
+ dump_dynamic_reloc_info = TRUE;
+ seenflag = TRUE;
break;
case 'a':
- dump_ar_hdrs = true;
- seenflag = true;
+ dump_ar_hdrs = TRUE;
+ seenflag = TRUE;
break;
case 'h':
- dump_section_headers = true;
- seenflag = true;
+ dump_section_headers = TRUE;
+ seenflag = TRUE;
break;
case 'H':
usage (stdout, 0);
- seenflag = true;
+ seenflag = TRUE;
case 'v':
case 'V':
- show_version = true;
- seenflag = true;
+ show_version = TRUE;
+ seenflag = TRUE;
break;
default:
@@ -2912,11 +2904,11 @@ main (argc, argv)
if (show_version)
print_version ("objdump");
- if (seenflag == false)
+ if (!seenflag)
usage (stderr, 2);
if (formats_info)
- display_info ();
+ exit_status = display_info ();
else
{
if (optind == argc)
diff --git a/contrib/binutils/binutils/po/Make-in b/contrib/binutils/binutils/po/Make-in
index 0552db1..6176dbf 100644
--- a/contrib/binutils/binutils/po/Make-in
+++ b/contrib/binutils/binutils/po/Make-in
@@ -24,6 +24,8 @@ gnulocaledir = $(prefix)/share/locale
gettextsrcdir = $(prefix)/share/gettext/po
subdir = po
+DESTDIR =
+
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
MKINSTALLDIRS = @MKINSTALLDIRS@
@@ -111,9 +113,9 @@ install-data: install-data-@USE_NLS@
install-data-no: all
install-data-yes: all
if test -r $(MKINSTALLDIRS); then \
- $(MKINSTALLDIRS) $(datadir); \
+ $(MKINSTALLDIRS) $(DESTDIR)$(datadir); \
else \
- $(top_srcdir)/mkinstalldirs $(datadir); \
+ $(top_srcdir)/mkinstalldirs $(DESTDIR)$(datadir); \
fi
@catalogs='$(CATALOGS)'; \
for cat in $$catalogs; do \
@@ -123,7 +125,7 @@ install-data-yes: all
*) destdir=$(localedir);; \
esac; \
lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
- dir=$$destdir/$$lang/LC_MESSAGES; \
+ dir=$(DESTDIR)$$destdir/$$lang/LC_MESSAGES; \
if test -r $(MKINSTALLDIRS); then \
$(MKINSTALLDIRS) $$dir; \
else \
@@ -153,12 +155,12 @@ install-data-yes: all
done
if test "$(PACKAGE)" = "gettext"; then \
if test -r $(MKINSTALLDIRS); then \
- $(MKINSTALLDIRS) $(gettextsrcdir); \
+ $(MKINSTALLDIRS) $(DESTDIR)$(gettextsrcdir); \
else \
- $(top_srcdir)/mkinstalldirs $(gettextsrcdir); \
+ $(top_srcdir)/mkinstalldirs $(DESTDIR)$(gettextsrcdir); \
fi; \
$(INSTALL_DATA) $(srcdir)/Makefile.in.in \
- $(gettextsrcdir)/Makefile.in.in; \
+ $(DESTDIR)$(gettextsrcdir)/Makefile.in.in; \
else \
: ; \
fi
@@ -171,12 +173,12 @@ uninstall:
for cat in $$catalogs; do \
cat=`basename $$cat`; \
lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
- rm -f $(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
- rm -f $(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
- rm -f $(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
- rm -f $(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
+ rm -f $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
+ rm -f $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
+ rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
+ rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
done
- rm -f $(gettextsrcdir)/po-Makefile.in.in
+ rm -f $(DESTDIR)$(gettextsrcdir)/po-Makefile.in.in
check: all
diff --git a/contrib/binutils/binutils/po/POTFILES.in b/contrib/binutils/binutils/po/POTFILES.in
index 1a3e585..9e9e6a5 100644
--- a/contrib/binutils/binutils/po/POTFILES.in
+++ b/contrib/binutils/binutils/po/POTFILES.in
@@ -12,6 +12,7 @@ budemang.h
coffdump.c
coffgrok.c
coffgrok.h
+cxxfilt.c
debug.c
debug.c
debug.h
diff --git a/contrib/binutils/binutils/po/binutils.pot b/contrib/binutils/binutils/po/binutils.pot
index 6097147..73c60b3 100644
--- a/contrib/binutils/binutils/po/binutils.pot
+++ b/contrib/binutils/binutils/po/binutils.pot
@@ -7,7 +7,7 @@
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
-"POT-Creation-Date: 2002-10-30 10:07-0500\n"
+"POT-Creation-Date: 2003-07-11 13:56+0930\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -43,19 +43,19 @@ msgid ""
"\n"
msgstr ""
-#: addr2line.c:89 ar.c:297 coffdump.c:479 nlmconv.c:1119 objcopy.c:424
-#: objcopy.c:457 readelf.c:2313 size.c:104 srconv.c:1962 strings.c:666
-#: sysdump.c:774 windres.c:733
+#: addr2line.c:89 ar.c:297 coffdump.c:479 nlmconv.c:1121 objcopy.c:484
+#: objcopy.c:518 readelf.c:2649 size.c:104 srconv.c:1962 strings.c:673
+#: sysdump.c:774 windres.c:702
#, c-format
msgid "Report bugs to %s\n"
msgstr ""
-#: addr2line.c:248
+#: addr2line.c:245
#, c-format
msgid "%s: can not get addresses from archive"
msgstr ""
-#: addr2line.c:320 nm.c:395 objdump.c:2783
+#: addr2line.c:317 nm.c:433 objdump.c:2693
#, c-format
msgid "unknown demangling style `%s'"
msgstr ""
@@ -214,7 +214,7 @@ msgstr ""
msgid "internal error -- this option not implemented"
msgstr ""
-#: ar.c:837 ar.c:888 ar.c:1333 objcopy.c:1348
+#: ar.c:837 ar.c:888 ar.c:1333 objcopy.c:1579
#, c-format
msgid "internal stat error on %s"
msgstr ""
@@ -323,40 +323,45 @@ msgid " No emulation specific options\n"
msgstr ""
#. Macros for common output.
-#: binemul.h:42
+#: binemul.h:52
#, c-format
msgid " emulation options: \n"
msgstr ""
-#: bucomm.c:106
+#: bucomm.c:113
#, c-format
msgid "can't set BFD default target to `%s': %s"
msgstr ""
-#: bucomm.c:118
+#: bucomm.c:125
#, c-format
msgid "%s: Matching formats:"
msgstr ""
-#: bucomm.c:135
+#: bucomm.c:142
msgid "Supported targets:"
msgstr ""
-#: bucomm.c:137
+#: bucomm.c:144
#, c-format
msgid "%s: supported targets:"
msgstr ""
-#: bucomm.c:155
+#: bucomm.c:162
msgid "Supported architectures:"
msgstr ""
-#: bucomm.c:157
+#: bucomm.c:164
#, c-format
msgid "%s: supported architectures:"
msgstr ""
-#: bucomm.c:264
+#: bucomm.c:360
+#, c-format
+msgid "BFD header file version %s\n"
+msgstr ""
+
+#: bucomm.c:467
#, c-format
msgid "%s: bad number: %s"
msgstr ""
@@ -387,95 +392,91 @@ msgstr ""
msgid "no input file specified"
msgstr ""
-#: debug.c:653
+#: debug.c:654
msgid "debug_add_to_current_namespace: no current file"
msgstr ""
-#: debug.c:736
+#: debug.c:737
msgid "debug_start_source: no debug_set_filename call"
msgstr ""
-#: debug.c:795
+#: debug.c:796
msgid "debug_record_function: no debug_set_filename call"
msgstr ""
-#: debug.c:851
+#: debug.c:852
msgid "debug_record_parameter: no current function"
msgstr ""
-#: debug.c:885
+#: debug.c:886
msgid "debug_end_function: no current function"
msgstr ""
-#: debug.c:891
+#: debug.c:892
msgid "debug_end_function: some blocks were not closed"
msgstr ""
-#: debug.c:921
+#: debug.c:922
msgid "debug_start_block: no current block"
msgstr ""
-#: debug.c:959
+#: debug.c:960
msgid "debug_end_block: no current block"
msgstr ""
-#: debug.c:966
+#: debug.c:967
msgid "debug_end_block: attempt to close top level block"
msgstr ""
-#: debug.c:992
+#: debug.c:993
msgid "debug_record_line: no current unit"
msgstr ""
#. FIXME
-#: debug.c:1046
+#: debug.c:1047
msgid "debug_start_common_block: not implemented"
msgstr ""
#. FIXME
-#: debug.c:1058
+#: debug.c:1059
msgid "debug_end_common_block: not implemented"
msgstr ""
#. FIXME.
-#: debug.c:1152
+#: debug.c:1153
msgid "debug_record_label: not implemented"
msgstr ""
-#: debug.c:1178
+#: debug.c:1179
msgid "debug_record_variable: no current file"
msgstr ""
-#: debug.c:1194
-msgid "debug_record_variable: no current block"
-msgstr ""
-
-#: debug.c:1763
+#: debug.c:1762
msgid "debug_make_undefined_type: unsupported kind"
msgstr ""
-#: debug.c:1964
+#: debug.c:1963
msgid "debug_name_type: no current file"
msgstr ""
-#: debug.c:2012
+#: debug.c:2011
msgid "debug_tag_type: no current file"
msgstr ""
-#: debug.c:2020
+#: debug.c:2019
msgid "debug_tag_type: extra tag attempted"
msgstr ""
-#: debug.c:2059
+#: debug.c:2058
#, c-format
msgid "Warning: changing type size from %d to %d\n"
msgstr ""
-#: debug.c:2083
+#: debug.c:2082
msgid "debug_find_named_type: no current compilation unit"
msgstr ""
-#: debug.c:2190
+#: debug.c:2189
#, c-format
msgid "debug_get_real_type: circular debug information for %s\n"
msgstr ""
@@ -484,325 +485,325 @@ msgstr ""
msgid "debug_write_type: illegal type encountered"
msgstr ""
-#: dlltool.c:735 dlltool.c:760 dlltool.c:786
+#: dlltool.c:812 dlltool.c:837 dlltool.c:863
#, c-format
msgid "Internal error: Unknown machine type: %d"
msgstr ""
-#: dlltool.c:823
+#: dlltool.c:900
#, c-format
msgid "Can't open def file: %s"
msgstr ""
-#: dlltool.c:828
+#: dlltool.c:905
#, c-format
msgid "Processing def file: %s"
msgstr ""
-#: dlltool.c:832
+#: dlltool.c:909
msgid "Processed def file"
msgstr ""
-#: dlltool.c:858
+#: dlltool.c:935
#, c-format
msgid "Syntax error in def file %s:%d"
msgstr ""
-#: dlltool.c:897
+#: dlltool.c:974
#, c-format
msgid "NAME: %s base: %x"
msgstr ""
-#: dlltool.c:900 dlltool.c:919
+#: dlltool.c:977 dlltool.c:996
msgid "Can't have LIBRARY and NAME"
msgstr ""
-#: dlltool.c:916
+#: dlltool.c:993
#, c-format
msgid "LIBRARY: %s base: %x"
msgstr ""
-#: dlltool.c:1174 resrc.c:271
+#: dlltool.c:1251 resrc.c:271
#, c-format
msgid "wait: %s"
msgstr ""
-#: dlltool.c:1179 dllwrap.c:430 resrc.c:276
+#: dlltool.c:1256 dllwrap.c:430 resrc.c:276
#, c-format
msgid "subprocess got fatal signal %d"
msgstr ""
-#: dlltool.c:1185 dllwrap.c:437 resrc.c:283
+#: dlltool.c:1262 dllwrap.c:437 resrc.c:283
#, c-format
msgid "%s exited with status %d"
msgstr ""
-#: dlltool.c:1217
+#: dlltool.c:1294
#, c-format
msgid "Sucking in info from %s section in %s"
msgstr ""
-#: dlltool.c:1341
+#: dlltool.c:1423
#, c-format
msgid "Excluding symbol: %s"
msgstr ""
-#: dlltool.c:1436 dlltool.c:1447 nm.c:959 nm.c:970 objdump.c:386 objdump.c:401
+#: dlltool.c:1518 dlltool.c:1529 nm.c:1004 nm.c:1015
#, c-format
msgid "%s: no symbols"
msgstr ""
-#. FIXME: we ought to read in and block out the base relocations
-#: dlltool.c:1474
+#. FIXME: we ought to read in and block out the base relocations.
+#: dlltool.c:1556
#, c-format
msgid "Done reading %s"
msgstr ""
-#: dlltool.c:1485
+#: dlltool.c:1567
#, c-format
msgid "Unable to open object file: %s"
msgstr ""
-#: dlltool.c:1488
+#: dlltool.c:1570
#, c-format
msgid "Scanning object file %s"
msgstr ""
-#: dlltool.c:1503
+#: dlltool.c:1585
#, c-format
msgid "Cannot produce mcore-elf dll from archive file: %s"
msgstr ""
-#: dlltool.c:1595
+#: dlltool.c:1677
msgid "Adding exports to output file"
msgstr ""
-#: dlltool.c:1640
+#: dlltool.c:1724
msgid "Added exports to output file"
msgstr ""
-#: dlltool.c:1764
+#: dlltool.c:1848
#, c-format
msgid "Generating export file: %s"
msgstr ""
-#: dlltool.c:1769
+#: dlltool.c:1853
#, c-format
msgid "Unable to open temporary assembler file: %s"
msgstr ""
-#: dlltool.c:1772
+#: dlltool.c:1856
#, c-format
msgid "Opened temporary file: %s"
msgstr ""
-#: dlltool.c:1996
+#: dlltool.c:2086
msgid "Generated exports file"
msgstr ""
-#: dlltool.c:2258
+#: dlltool.c:2378
#, c-format
msgid "bfd_open failed open stub file: %s"
msgstr ""
-#: dlltool.c:2261
+#: dlltool.c:2381
#, c-format
msgid "Creating stub file: %s"
msgstr ""
-#: dlltool.c:2650
+#: dlltool.c:2766
#, c-format
msgid "failed to open temporary head file: %s"
msgstr ""
-#: dlltool.c:2709
+#: dlltool.c:2825
#, c-format
msgid "failed to open temporary tail file: %s"
msgstr ""
-#: dlltool.c:2777
+#: dlltool.c:2892
#, c-format
msgid "Can't open .lib file: %s"
msgstr ""
-#: dlltool.c:2780
+#: dlltool.c:2895
#, c-format
msgid "Creating library file: %s"
msgstr ""
-#: dlltool.c:2839
+#: dlltool.c:2951
#, c-format
msgid "cannot delete %s: %s"
msgstr ""
-#: dlltool.c:2843
+#: dlltool.c:2955
msgid "Created lib file"
msgstr ""
-#: dlltool.c:2948
+#: dlltool.c:3062
#, c-format
msgid "Warning, ignoring duplicate EXPORT %s %d,%d"
msgstr ""
-#: dlltool.c:2954
+#: dlltool.c:3068
#, c-format
msgid "Error, duplicate EXPORT with oridinals: %s"
msgstr ""
-#: dlltool.c:3081
+#: dlltool.c:3191
msgid "Processing definitions"
msgstr ""
-#: dlltool.c:3119
+#: dlltool.c:3223
msgid "Processed definitions"
msgstr ""
#. xgetext:c-format
-#: dlltool.c:3130 dllwrap.c:495
+#: dlltool.c:3234 dllwrap.c:495
#, c-format
msgid "Usage %s <option(s)> <object-file(s)>\n"
msgstr ""
#. xgetext:c-format
-#: dlltool.c:3132
+#: dlltool.c:3236
#, c-format
msgid ""
" -m --machine <machine> Create as DLL for <machine>. [default: %s]\n"
msgstr ""
-#: dlltool.c:3133
+#: dlltool.c:3237
msgid ""
" possible <machine>: arm[_interwork], i386, mcore[-elf]{-le|-be}, "
"ppc, thumb\n"
msgstr ""
-#: dlltool.c:3134
+#: dlltool.c:3238
msgid " -e --output-exp <outname> Generate an export file.\n"
msgstr ""
-#: dlltool.c:3135
+#: dlltool.c:3239
msgid " -l --output-lib <outname> Generate an interface library.\n"
msgstr ""
-#: dlltool.c:3136
+#: dlltool.c:3240
msgid " -a --add-indirect Add dll indirects to export file.\n"
msgstr ""
-#: dlltool.c:3137
+#: dlltool.c:3241
msgid ""
" -D --dllname <name> Name of input dll to put into interface lib.\n"
msgstr ""
-#: dlltool.c:3138
+#: dlltool.c:3242
msgid " -d --input-def <deffile> Name of .def file to be read in.\n"
msgstr ""
-#: dlltool.c:3139
+#: dlltool.c:3243
msgid " -z --output-def <deffile> Name of .def file to be created.\n"
msgstr ""
-#: dlltool.c:3140
+#: dlltool.c:3244
msgid " --export-all-symbols Export all symbols to .def\n"
msgstr ""
-#: dlltool.c:3141
+#: dlltool.c:3245
msgid " --no-export-all-symbols Only export listed symbols\n"
msgstr ""
-#: dlltool.c:3142
+#: dlltool.c:3246
msgid " --exclude-symbols <list> Don't export <list>\n"
msgstr ""
-#: dlltool.c:3143
+#: dlltool.c:3247
msgid " --no-default-excludes Clear default exclude symbols\n"
msgstr ""
-#: dlltool.c:3144
+#: dlltool.c:3248
msgid " -b --base-file <basefile> Read linker generated base file.\n"
msgstr ""
-#: dlltool.c:3145
+#: dlltool.c:3249
msgid " -x --no-idata4 Don't generate idata$4 section.\n"
msgstr ""
-#: dlltool.c:3146
+#: dlltool.c:3250
msgid " -c --no-idata5 Don't generate idata$5 section.\n"
msgstr ""
-#: dlltool.c:3147
+#: dlltool.c:3251
msgid ""
" -U --add-underscore Add underscores to symbols in interface "
"library.\n"
msgstr ""
-#: dlltool.c:3148
+#: dlltool.c:3252
msgid " -k --kill-at Kill @<n> from exported names.\n"
msgstr ""
-#: dlltool.c:3149
+#: dlltool.c:3253
msgid " -A --add-stdcall-alias Add aliases without @<n>.\n"
msgstr ""
-#: dlltool.c:3150
+#: dlltool.c:3254
msgid " -S --as <name> Use <name> for assembler.\n"
msgstr ""
-#: dlltool.c:3151
+#: dlltool.c:3255
msgid " -f --as-flags <flags> Pass <flags> to the assembler.\n"
msgstr ""
-#: dlltool.c:3152
+#: dlltool.c:3256
msgid ""
" -C --compat-implib Create backward compatible import library.\n"
msgstr ""
-#: dlltool.c:3153
+#: dlltool.c:3257
msgid ""
" -n --no-delete Keep temp files (repeat for extra "
"preservation).\n"
msgstr ""
-#: dlltool.c:3154
+#: dlltool.c:3258
msgid " -v --verbose Be verbose.\n"
msgstr ""
-#: dlltool.c:3155
+#: dlltool.c:3259
msgid " -V --version Display the program version.\n"
msgstr ""
-#: dlltool.c:3156
+#: dlltool.c:3260
msgid " -h --help Display this information.\n"
msgstr ""
-#: dlltool.c:3158
+#: dlltool.c:3262
msgid ""
" -M --mcore-elf <outname> Process mcore-elf object files into <outname>.\n"
msgstr ""
-#: dlltool.c:3159
+#: dlltool.c:3263
msgid " -L --linker <name> Use <name> as the linker.\n"
msgstr ""
-#: dlltool.c:3160
+#: dlltool.c:3264
msgid " -F --linker-flags <flags> Pass <flags> to the linker.\n"
msgstr ""
-#: dlltool.c:3310
+#: dlltool.c:3418
#, c-format
msgid "Unable to open base-file: %s"
msgstr ""
-#: dlltool.c:3339
+#: dlltool.c:3450
#, c-format
msgid "Machine '%s' not supported"
msgstr ""
-#: dlltool.c:3442 dllwrap.c:214
+#: dlltool.c:3553 dllwrap.c:214
#, c-format
msgid "Tried file: %s"
msgstr ""
-#: dlltool.c:3449 dllwrap.c:221
+#: dlltool.c:3560 dllwrap.c:221
#, c-format
msgid "Using file: %s"
msgstr ""
@@ -1008,375 +1009,375 @@ msgstr ""
msgid "DRIVER options : %s\n"
msgstr ""
-#: emul_aix.c:52
+#: emul_aix.c:58
#, c-format
msgid " [-g] - 32 bit small archive\n"
msgstr ""
-#: emul_aix.c:53
+#: emul_aix.c:59
msgid " [-X32] - ignores 64 bit objects\n"
msgstr ""
-#: emul_aix.c:54
+#: emul_aix.c:60
msgid " [-X64] - ignores 32 bit objects\n"
msgstr ""
-#: emul_aix.c:55
+#: emul_aix.c:61
msgid " [-X32_64] - accepts 32 and 64 bit objects\n"
msgstr ""
-#: ieee.c:317
+#: ieee.c:326
msgid "unexpected end of debugging information"
msgstr ""
-#: ieee.c:412
+#: ieee.c:421
msgid "invalid number"
msgstr ""
-#: ieee.c:471
+#: ieee.c:480
msgid "invalid string length"
msgstr ""
-#: ieee.c:528 ieee.c:569
+#: ieee.c:537 ieee.c:578
msgid "expression stack overflow"
msgstr ""
-#: ieee.c:548
+#: ieee.c:557
msgid "unsupported IEEE expression operator"
msgstr ""
-#: ieee.c:563
+#: ieee.c:572
msgid "unknown section"
msgstr ""
-#: ieee.c:584
+#: ieee.c:593
msgid "expression stack underflow"
msgstr ""
-#: ieee.c:598
+#: ieee.c:607
msgid "expression stack mismatch"
msgstr ""
-#: ieee.c:637
+#: ieee.c:646
msgid "unknown builtin type"
msgstr ""
-#: ieee.c:782
+#: ieee.c:791
msgid "BCD float type not supported"
msgstr ""
-#: ieee.c:928
+#: ieee.c:937
msgid "unexpected number"
msgstr ""
-#: ieee.c:935
+#: ieee.c:944
msgid "unexpected record type"
msgstr ""
-#: ieee.c:968
+#: ieee.c:977
msgid "blocks left on stack at end"
msgstr ""
-#: ieee.c:1233
+#: ieee.c:1242
msgid "unknown BB type"
msgstr ""
-#: ieee.c:1242
+#: ieee.c:1251
msgid "stack overflow"
msgstr ""
-#: ieee.c:1267
+#: ieee.c:1276
msgid "stack underflow"
msgstr ""
-#: ieee.c:1381 ieee.c:1453 ieee.c:2152
+#: ieee.c:1390 ieee.c:1462 ieee.c:2161
msgid "illegal variable index"
msgstr ""
-#: ieee.c:1431
+#: ieee.c:1440
msgid "illegal type index"
msgstr ""
-#: ieee.c:1441 ieee.c:1478
+#: ieee.c:1450 ieee.c:1487
msgid "unknown TY code"
msgstr ""
-#: ieee.c:1460
+#: ieee.c:1469
msgid "undefined variable in TY"
msgstr ""
#. Pascal file name. FIXME.
-#: ieee.c:1871
+#: ieee.c:1880
msgid "Pascal file name not supported"
msgstr ""
-#: ieee.c:1919
+#: ieee.c:1928
msgid "unsupported qualifier"
msgstr ""
-#: ieee.c:2190
+#: ieee.c:2199
msgid "undefined variable in ATN"
msgstr ""
-#: ieee.c:2233
+#: ieee.c:2242
msgid "unknown ATN type"
msgstr ""
#. Reserved for FORTRAN common.
-#: ieee.c:2355
+#: ieee.c:2364
msgid "unsupported ATN11"
msgstr ""
#. We have no way to record this information. FIXME.
-#: ieee.c:2382
+#: ieee.c:2391
msgid "unsupported ATN12"
msgstr ""
-#: ieee.c:2442
+#: ieee.c:2451
msgid "unexpected string in C++ misc"
msgstr ""
-#: ieee.c:2455
+#: ieee.c:2464
msgid "bad misc record"
msgstr ""
-#: ieee.c:2498
+#: ieee.c:2507
msgid "unrecognized C++ misc record"
msgstr ""
-#: ieee.c:2615
+#: ieee.c:2624
msgid "undefined C++ object"
msgstr ""
-#: ieee.c:2649
+#: ieee.c:2658
msgid "unrecognized C++ object spec"
msgstr ""
-#: ieee.c:2685
+#: ieee.c:2694
msgid "unsupported C++ object type"
msgstr ""
-#: ieee.c:2695
+#: ieee.c:2704
msgid "C++ base class not defined"
msgstr ""
-#: ieee.c:2707 ieee.c:2812
+#: ieee.c:2716 ieee.c:2821
msgid "C++ object has no fields"
msgstr ""
-#: ieee.c:2726
+#: ieee.c:2735
msgid "C++ base class not found in container"
msgstr ""
-#: ieee.c:2833
+#: ieee.c:2842
msgid "C++ data member not found in container"
msgstr ""
-#: ieee.c:2874 ieee.c:3024
+#: ieee.c:2883 ieee.c:3033
msgid "unknown C++ visibility"
msgstr ""
-#: ieee.c:2908
+#: ieee.c:2917
msgid "bad C++ field bit pos or size"
msgstr ""
-#: ieee.c:3000
+#: ieee.c:3009
msgid "bad type for C++ method function"
msgstr ""
-#: ieee.c:3010
+#: ieee.c:3019
msgid "no type information for C++ method function"
msgstr ""
-#: ieee.c:3049
+#: ieee.c:3058
msgid "C++ static virtual method"
msgstr ""
-#: ieee.c:3144
+#: ieee.c:3153
msgid "unrecognized C++ object overhead spec"
msgstr ""
-#: ieee.c:3183
+#: ieee.c:3192
msgid "undefined C++ vtable"
msgstr ""
-#: ieee.c:3254
+#: ieee.c:3263
msgid "C++ default values not in a function"
msgstr ""
-#: ieee.c:3294
+#: ieee.c:3303
msgid "unrecognized C++ default type"
msgstr ""
-#: ieee.c:3325
+#: ieee.c:3334
msgid "reference parameter is not a pointer"
msgstr ""
-#: ieee.c:3410
+#: ieee.c:3419
msgid "unrecognized C++ reference type"
msgstr ""
-#: ieee.c:3492
+#: ieee.c:3501
msgid "C++ reference not found"
msgstr ""
-#: ieee.c:3500
+#: ieee.c:3509
msgid "C++ reference is not pointer"
msgstr ""
-#: ieee.c:3529 ieee.c:3537
+#: ieee.c:3538 ieee.c:3546
msgid "missing required ASN"
msgstr ""
-#: ieee.c:3567 ieee.c:3575
+#: ieee.c:3576 ieee.c:3584
msgid "missing required ATN65"
msgstr ""
-#: ieee.c:3589
+#: ieee.c:3598
msgid "bad ATN65 record"
msgstr ""
-#: ieee.c:4234
+#: ieee.c:4286
msgid "IEEE numeric overflow: 0x"
msgstr ""
-#: ieee.c:4280
+#: ieee.c:4332
#, c-format
msgid "IEEE string length overflow: %u\n"
msgstr ""
-#: ieee.c:5330
+#: ieee.c:5382
#, c-format
msgid "IEEE unsupported integer type size %u\n"
msgstr ""
-#: ieee.c:5366
+#: ieee.c:5418
#, c-format
msgid "IEEE unsupported float type size %u\n"
msgstr ""
-#: ieee.c:5402
+#: ieee.c:5454
#, c-format
msgid "IEEE unsupported complex type size %u\n"
msgstr ""
-#: nlmconv.c:281 srconv.c:2043
+#: nlmconv.c:282 srconv.c:2043
msgid "input and output files must be different"
msgstr ""
-#: nlmconv.c:328
+#: nlmconv.c:329
msgid "input file named both on command line and with INPUT"
msgstr ""
-#: nlmconv.c:337
+#: nlmconv.c:338
msgid "no input file"
msgstr ""
-#: nlmconv.c:367
+#: nlmconv.c:368
msgid "no name for output file"
msgstr ""
-#: nlmconv.c:380
+#: nlmconv.c:382
msgid "warning: input and output formats are not compatible"
msgstr ""
-#: nlmconv.c:409
+#: nlmconv.c:411
msgid "make .bss section"
msgstr ""
-#: nlmconv.c:418
+#: nlmconv.c:420
msgid "make .nlmsections section"
msgstr ""
-#: nlmconv.c:420
+#: nlmconv.c:422
msgid "set .nlmsections flags"
msgstr ""
-#: nlmconv.c:448
+#: nlmconv.c:450
msgid "set .bss vma"
msgstr ""
-#: nlmconv.c:455
+#: nlmconv.c:457
msgid "set .data size"
msgstr ""
-#: nlmconv.c:635
+#: nlmconv.c:637
#, c-format
msgid "warning: symbol %s imported but not in import list"
msgstr ""
-#: nlmconv.c:655
+#: nlmconv.c:657
msgid "set start address"
msgstr ""
-#: nlmconv.c:704
+#: nlmconv.c:706
#, c-format
msgid "warning: START procedure %s not defined"
msgstr ""
-#: nlmconv.c:706
+#: nlmconv.c:708
#, c-format
msgid "warning: EXIT procedure %s not defined"
msgstr ""
-#: nlmconv.c:708
+#: nlmconv.c:710
#, c-format
msgid "warning: CHECK procedure %s not defined"
msgstr ""
-#: nlmconv.c:729 nlmconv.c:918
+#: nlmconv.c:731 nlmconv.c:920
msgid "custom section"
msgstr ""
-#: nlmconv.c:750 nlmconv.c:947
+#: nlmconv.c:752 nlmconv.c:949
msgid "help section"
msgstr ""
-#: nlmconv.c:772 nlmconv.c:965
+#: nlmconv.c:774 nlmconv.c:967
msgid "message section"
msgstr ""
-#: nlmconv.c:788 nlmconv.c:998
+#: nlmconv.c:790 nlmconv.c:1000
msgid "module section"
msgstr ""
-#: nlmconv.c:808 nlmconv.c:1014
+#: nlmconv.c:810 nlmconv.c:1016
msgid "rpc section"
msgstr ""
#. There is no place to record this information.
-#: nlmconv.c:844
+#: nlmconv.c:846
#, c-format
msgid "%s: warning: shared libraries can not have uninitialized data"
msgstr ""
-#: nlmconv.c:865 nlmconv.c:1033
+#: nlmconv.c:867 nlmconv.c:1035
msgid "shared section"
msgstr ""
-#: nlmconv.c:873
+#: nlmconv.c:875
msgid "warning: No version number given"
msgstr ""
-#: nlmconv.c:913 nlmconv.c:942 nlmconv.c:960 nlmconv.c:1009 nlmconv.c:1028
+#: nlmconv.c:915 nlmconv.c:944 nlmconv.c:962 nlmconv.c:1011 nlmconv.c:1030
#, c-format
msgid "%s: read: %s"
msgstr ""
-#: nlmconv.c:935
+#: nlmconv.c:937
msgid "warning: MAP and FULLMAP are not supported; try ld -M"
msgstr ""
-#: nlmconv.c:1107
+#: nlmconv.c:1109
#, c-format
msgid "Usage: %s [option(s)] [in-file [out-file]]\n"
msgstr ""
-#: nlmconv.c:1108
+#: nlmconv.c:1110
msgid " Convert an object file into a NetWare Loadable Module\n"
msgstr ""
-#: nlmconv.c:1109
+#: nlmconv.c:1111
msgid ""
" The options are:\n"
" -I --input-target=<bfdname> Set the input binary file format\n"
@@ -1388,73 +1389,73 @@ msgid ""
" -v --version Display the program's version\n"
msgstr ""
-#: nlmconv.c:1151
+#: nlmconv.c:1153
#, c-format
msgid "support not compiled in for %s"
msgstr ""
-#: nlmconv.c:1191
+#: nlmconv.c:1193
msgid "make section"
msgstr ""
-#: nlmconv.c:1205
+#: nlmconv.c:1207
msgid "set section size"
msgstr ""
-#: nlmconv.c:1211
+#: nlmconv.c:1213
msgid "set section alignment"
msgstr ""
-#: nlmconv.c:1215
+#: nlmconv.c:1217
msgid "set section flags"
msgstr ""
-#: nlmconv.c:1226
+#: nlmconv.c:1228
msgid "set .nlmsections size"
msgstr ""
-#: nlmconv.c:1314 nlmconv.c:1322 nlmconv.c:1331 nlmconv.c:1336
+#: nlmconv.c:1316 nlmconv.c:1324 nlmconv.c:1333 nlmconv.c:1338
msgid "set .nlmsection contents"
msgstr ""
-#: nlmconv.c:1837
+#: nlmconv.c:1839
msgid "stub section sizes"
msgstr ""
-#: nlmconv.c:1886
+#: nlmconv.c:1888
msgid "writing stub"
msgstr ""
-#: nlmconv.c:1975
+#: nlmconv.c:1977
#, c-format
msgid "unresolved PC relative reloc against %s"
msgstr ""
-#: nlmconv.c:2039
+#: nlmconv.c:2041
#, c-format
msgid "overflow when adjusting relocation against %s"
msgstr ""
-#: nlmconv.c:2156
+#: nlmconv.c:2158
#, c-format
msgid "%s: execution of %s failed: "
msgstr ""
-#: nlmconv.c:2171
+#: nlmconv.c:2173
#, c-format
msgid "Execution of %s failed"
msgstr ""
-#: nm.c:246 size.c:85 strings.c:650
+#: nm.c:283 size.c:85 strings.c:657
#, c-format
msgid "Usage: %s [option(s)] [file(s)]\n"
msgstr ""
-#: nm.c:247
+#: nm.c:284
msgid " List symbols in [file(s)] (a.out by default).\n"
msgstr ""
-#: nm.c:248
+#: nm.c:285
msgid ""
" The options are:\n"
" -a, --debug-syms Display debugger-only symbols\n"
@@ -1464,8 +1465,9 @@ msgid ""
"names\n"
" The STYLE, if specified, can be `auto' (the "
"default),\n"
-" `gnu', 'lucid', 'arm', 'hp', 'edg' or 'gnu-new-"
-"abi'\n"
+" `gnu', `lucid', `arm', `hp', `edg', `gnu-v3', "
+"`java'\n"
+" or `gnat'\n"
" --no-demangle Do not demangle low-level symbol names\n"
" -D, --dynamic Display dynamic symbols instead of normal symbols\n"
" --defined-only Display only defined symbols\n"
@@ -1493,46 +1495,54 @@ msgid ""
"\n"
msgstr ""
-#: nm.c:281 objdump.c:217
+#: nm.c:319 objdump.c:250
#, c-format
msgid "Report bugs to %s.\n"
msgstr ""
-#: nm.c:314
+#: nm.c:352
#, c-format
msgid "%s: invalid radix"
msgstr ""
-#: nm.c:339
+#: nm.c:377
#, c-format
msgid "%s: invalid output format"
msgstr ""
-#: nm.c:456
+#: nm.c:494
msgid "Only -X 32_64 is supported"
msgstr ""
-#: nm.c:498
+#: nm.c:514
+msgid "Using the --size-sort and --undefined-only options together"
+msgstr ""
+
+#: nm.c:515
+msgid "will produce no output, since undefined symbols have no size."
+msgstr ""
+
+#: nm.c:543
#, c-format
msgid "data size %ld"
msgstr ""
-#: nm.c:523 readelf.c:5391 readelf.c:5427
+#: nm.c:568 readelf.c:5809 readelf.c:5845
#, c-format
msgid "<processor specific>: %d"
msgstr ""
-#: nm.c:525 readelf.c:5393 readelf.c:5439
+#: nm.c:570 readelf.c:5811 readelf.c:5857
#, c-format
msgid "<OS specific>: %d"
msgstr ""
-#: nm.c:527 readelf.c:5395 readelf.c:5442
+#: nm.c:572 readelf.c:5813 readelf.c:5860
#, c-format
msgid "<unknown>: %d"
msgstr ""
-#: nm.c:1339
+#: nm.c:1376
#, c-format
msgid ""
"\n"
@@ -1541,7 +1551,7 @@ msgid ""
"\n"
msgstr ""
-#: nm.c:1341
+#: nm.c:1378
#, c-format
msgid ""
"\n"
@@ -1550,21 +1560,21 @@ msgid ""
"\n"
msgstr ""
-#: nm.c:1343 nm.c:1401
+#: nm.c:1380 nm.c:1438
msgid ""
"Name Value Class Type Size Line "
"Section\n"
"\n"
msgstr ""
-#: nm.c:1346 nm.c:1404
+#: nm.c:1383 nm.c:1441
msgid ""
"Name Value Class Type "
"Size Line Section\n"
"\n"
msgstr ""
-#: nm.c:1397
+#: nm.c:1434
#, c-format
msgid ""
"\n"
@@ -1573,7 +1583,7 @@ msgid ""
"\n"
msgstr ""
-#: nm.c:1399
+#: nm.c:1436
#, c-format
msgid ""
"\n"
@@ -1582,26 +1592,26 @@ msgid ""
"\n"
msgstr ""
-#: nm.c:1614
+#: nm.c:1658
msgid ""
"\n"
"Archive index:\n"
msgstr ""
-#: objcopy.c:363 srconv.c:1952
+#: objcopy.c:414 srconv.c:1952
#, c-format
msgid "Usage: %s [option(s)] in-file [out-file]\n"
msgstr ""
-#: objcopy.c:364
+#: objcopy.c:415
msgid " Copies a binary file, possibly transforming it in the process\n"
msgstr ""
-#: objcopy.c:365 objcopy.c:435
+#: objcopy.c:416 objcopy.c:495
msgid " The options are:\n"
msgstr ""
-#: objcopy.c:366
+#: objcopy.c:417
msgid ""
" -I --input-target <bfdname> Assume input file is in format <bfdname>\n"
" -O --output-target <bfdname> Create an output file in format "
@@ -1615,10 +1625,12 @@ msgid ""
" -p --preserve-dates Copy modified/access timestamps to the "
"output\n"
" -j --only-section <name> Only copy section <name> into the output\n"
+" --add-gnu-debuglink=<file> Add section .gnu_debuglink linking to "
+"<file>\n"
" -R --remove-section <name> Remove section <name> from the output\n"
" -S --strip-all Remove all symbol and relocation "
"information\n"
-" -g --strip-debug Remove all debugging symbols\n"
+" -g --strip-debug Remove all debugging symbols & sections\n"
" --strip-unneeded Remove all symbols not needed by "
"relocations\n"
" -N --strip-symbol <name> Do not copy symbol <name>\n"
@@ -1667,6 +1679,8 @@ msgid ""
" --remove-leading-char Remove leading character from global "
"symbols\n"
" --redefine-sym <old>=<new> Redefine symbol name <old> to <new>\n"
+" --redefine-syms <file> --redefine-sym for all symbol pairs \n"
+" listed in <file>\n"
" --srec-len <number> Restrict the length of generated "
"Srecords\n"
" --srec-forceS3 Restrict the type of generated Srecords "
@@ -1677,21 +1691,31 @@ msgid ""
" --keep-global-symbols <file> -G for all symbols listed in <file>\n"
" --weaken-symbols <file> -W for all symbols listed in <file>\n"
" --alt-machine-code <index> Use alternate machine code for output\n"
+" --prefix-symbols <prefix> Add <prefix> to start of every symbol "
+"name\n"
+" --prefix-sections <prefix> Add <prefix> to start of every section "
+"name\n"
+" --prefix-alloc-sections <prefix>\n"
+" Add <prefix> to start of every "
+"allocatable\n"
+" section name\n"
" -v --verbose List all object files modified\n"
" -V --version Display this program's version number\n"
" -h --help Display this output\n"
+" --info List object formats & architectures "
+"supported\n"
msgstr ""
-#: objcopy.c:433
+#: objcopy.c:493
#, c-format
msgid "Usage: %s <option(s)> in-file(s)\n"
msgstr ""
-#: objcopy.c:434
+#: objcopy.c:494
msgid " Removes symbols and sections from files\n"
msgstr ""
-#: objcopy.c:436
+#: objcopy.c:496
msgid ""
" -I --input-target=<bfdname> Assume input file is in format <bfdname>\n"
" -O --output-target=<bfdname> Create an output file in format "
@@ -1703,7 +1727,7 @@ msgid ""
" -R --remove-section=<name> Remove section <name> from the output\n"
" -s --strip-all Remove all symbol and relocation "
"information\n"
-" -g -S -d --strip-debug Remove all debugging symbols\n"
+" -g -S -d --strip-debug Remove all debugging symbols & sections\n"
" --strip-unneeded Remove all symbols not needed by "
"relocations\n"
" -N --strip-symbol=<name> Do not copy symbol <name>\n"
@@ -1713,217 +1737,239 @@ msgid ""
" -v --verbose List all object files modified\n"
" -V --version Display this program's version number\n"
" -h --help Display this output\n"
+" --info List object formats & architectures "
+"supported\n"
" -o <file> Place stripped output into <file>\n"
msgstr ""
-#: objcopy.c:506
+#: objcopy.c:567
#, c-format
msgid "unrecognized section flag `%s'"
msgstr ""
-#: objcopy.c:507
+#: objcopy.c:568
#, c-format
msgid "supported flags: %s"
msgstr ""
-#: objcopy.c:584 objcopy.c:2243
+#: objcopy.c:645 objcopy.c:2526
#, c-format
msgid "cannot stat: %s: %s"
msgstr ""
-#: objcopy.c:591 objcopy.c:2261
+#: objcopy.c:652 objcopy.c:2544
#, c-format
msgid "cannot open: %s: %s"
msgstr ""
-#: objcopy.c:594 objcopy.c:2265
+#: objcopy.c:655 objcopy.c:2548
#, c-format
msgid "%s: fread failed"
msgstr ""
-#: objcopy.c:667
+#: objcopy.c:728
#, c-format
msgid "Ignoring rubbish found on line %d of %s"
msgstr ""
-#: objcopy.c:888
+#: objcopy.c:979
#, c-format
msgid "%s: Multiple redefinition of symbol \"%s\""
msgstr ""
-#: objcopy.c:893
+#: objcopy.c:983
#, c-format
msgid "%s: Symbol \"%s\" is target of more than one redefinition"
msgstr ""
-#: objcopy.c:945
+#: objcopy.c:1010
+#, c-format
+msgid "couldn't open symbol redefinition file %s (error: %s)"
+msgstr ""
+
+#: objcopy.c:1088
+#, c-format
+msgid "%s: garbage at end of line %d"
+msgstr ""
+
+#: objcopy.c:1091
+#, c-format
+msgid "%s: missing new symbol name at line %d"
+msgstr ""
+
+#: objcopy.c:1101
+#, c-format
+msgid "%s: premature end of file at line %d"
+msgstr ""
+
+#: objcopy.c:1147
msgid "Unable to change endianness of input file(s)"
msgstr ""
-#: objcopy.c:953
+#: objcopy.c:1155
#, c-format
msgid "copy from %s(%s) to %s(%s)\n"
msgstr ""
-#: objcopy.c:977
+#: objcopy.c:1182
#, c-format
msgid "Warning: Output file cannot represent architecture %s"
msgstr ""
-#: objcopy.c:1004
+#: objcopy.c:1211
#, c-format
msgid "can't create section `%s': %s"
msgstr ""
-#: objcopy.c:1090
+#: objcopy.c:1304
#, c-format
msgid "Can't fill gap after %s: %s"
msgstr ""
-#: objcopy.c:1115
+#: objcopy.c:1329
#, c-format
msgid "Can't add padding to %s: %s"
msgstr ""
-#: objcopy.c:1254
+#: objcopy.c:1485
#, c-format
msgid "%s: error copying private BFD data: %s"
msgstr ""
-#: objcopy.c:1267
+#: objcopy.c:1498
msgid "unknown alternate machine code, ignored"
msgstr ""
-#: objcopy.c:1300 objcopy.c:1330
+#: objcopy.c:1531 objcopy.c:1561
#, c-format
msgid "cannot mkdir %s for archive copying (error: %s)"
msgstr ""
-#: objcopy.c:1497
+#: objcopy.c:1749
#, c-format
msgid "Multiple renames of section %s"
msgstr ""
-#: objcopy.c:1581
+#: objcopy.c:1840
msgid "making"
msgstr ""
-#: objcopy.c:1590
+#: objcopy.c:1849
msgid "size"
msgstr ""
-#: objcopy.c:1604
+#: objcopy.c:1863
msgid "vma"
msgstr ""
-#: objcopy.c:1630
+#: objcopy.c:1888
msgid "alignment"
msgstr ""
-#: objcopy.c:1638
+#: objcopy.c:1896
msgid "flags"
msgstr ""
-#: objcopy.c:1655
+#: objcopy.c:1918
msgid "private data"
msgstr ""
-#: objcopy.c:1663
+#: objcopy.c:1926
#, c-format
msgid "%s: section `%s': error in %s: %s"
msgstr ""
-#: objcopy.c:1946
+#: objcopy.c:2199
#, c-format
msgid "%s: can't create debugging section: %s"
msgstr ""
-#: objcopy.c:1961
+#: objcopy.c:2214
#, c-format
msgid "%s: can't set debugging section contents: %s"
msgstr ""
-#: objcopy.c:1970
+#: objcopy.c:2223
#, c-format
msgid "%s: don't know how to write debugging information for %s"
msgstr ""
-#: objcopy.c:2078
+#: objcopy.c:2346
#, c-format
msgid "%s: cannot stat: %s"
msgstr ""
-#: objcopy.c:2129
+#: objcopy.c:2400
msgid "byte number must be non-negative"
msgstr ""
-#: objcopy.c:2139
+#: objcopy.c:2410
msgid "interleave must be positive"
msgstr ""
-#: objcopy.c:2159 objcopy.c:2167
+#: objcopy.c:2430 objcopy.c:2438
#, c-format
msgid "%s both copied and removed"
msgstr ""
-#: objcopy.c:2240 objcopy.c:2310 objcopy.c:2410 objcopy.c:2437 objcopy.c:2461
-#: objcopy.c:2465 objcopy.c:2485
+#: objcopy.c:2523 objcopy.c:2593 objcopy.c:2693 objcopy.c:2724 objcopy.c:2748
+#: objcopy.c:2752 objcopy.c:2772
#, c-format
msgid "bad format for %s"
msgstr ""
-#: objcopy.c:2379
+#: objcopy.c:2662
#, c-format
msgid "Warning: truncating gap-fill from 0x%s to 0x%x"
msgstr ""
-#: objcopy.c:2531
+#: objcopy.c:2818
msgid "alternate machine code index must be positive"
msgstr ""
-#: objcopy.c:2550
+#: objcopy.c:2856
msgid "byte number must be less than interleave"
msgstr ""
-#: objcopy.c:2577
+#: objcopy.c:2883
#, c-format
msgid "architecture %s unknown"
msgstr ""
-#: objcopy.c:2581
+#: objcopy.c:2887
msgid ""
"Warning: input target 'binary' required for binary architecture parameter."
msgstr ""
-#: objcopy.c:2582
+#: objcopy.c:2888
#, c-format
msgid " Argument %s ignored"
msgstr ""
-#: objcopy.c:2588
+#: objcopy.c:2894
#, c-format
msgid "Cannot stat: %s: %s"
msgstr ""
-#: objcopy.c:2628 objcopy.c:2642
+#: objcopy.c:2934 objcopy.c:2948
#, c-format
msgid "%s %s%c0x%s never used"
msgstr ""
-#: objdump.c:165
+#: objdump.c:197
#, c-format
msgid "Usage: %s <option(s)> <file(s)>\n"
msgstr ""
-#: objdump.c:166
+#: objdump.c:198
msgid " Display information from object <file(s)>.\n"
msgstr ""
-#: objdump.c:167
+#: objdump.c:199
msgid " At least one of the following switches must be given:\n"
msgstr ""
-#: objdump.c:168
+#: objdump.c:200
msgid ""
" -a, --archive-headers Display archive header information\n"
" -f, --file-headers Display the contents of the overall file header\n"
@@ -1949,13 +1995,13 @@ msgid ""
" -H, --help Display this information\n"
msgstr ""
-#: objdump.c:190
+#: objdump.c:222
msgid ""
"\n"
" The following switches are optional:\n"
msgstr ""
-#: objdump.c:191
+#: objdump.c:223
msgid ""
" -b, --target=BFDNAME Specify the target object format as "
"BFDNAME\n"
@@ -1972,14 +2018,15 @@ msgid ""
"output\n"
" -C, --demangle[=STYLE] Decode mangled/processed symbol names\n"
" The STYLE, if specified, can be `auto', "
-"'gnu',\n"
-" 'lucid', 'arm', 'hp', 'edg', or 'gnu-new-"
-"abi'\n"
+"`gnu',\n"
+" `lucid', `arm', `hp', `edg', `gnu-v3', "
+"`java'\n"
+" or `gnat'\n"
" -w, --wide Format output for more than 80 columns\n"
" -z, --disassemble-zeroes Do not skip blocks of zeroes when "
"disassembling\n"
-" --start-address=ADDR Only process data whoes address is >= ADDR\n"
-" --stop-address=ADDR Only process data whoes address is <= ADDR\n"
+" --start-address=ADDR Only process data whose address is >= ADDR\n"
+" --stop-address=ADDR Only process data whose address is <= ADDR\n"
" --prefix-addresses Print complete address alongside "
"disassembly\n"
" --[no-]show-raw-insn Display hex alongside symbolic disassembly\n"
@@ -1988,324 +2035,322 @@ msgid ""
"\n"
msgstr ""
-#: objdump.c:358
+#: objdump.c:391
msgid "Sections:\n"
msgstr ""
-#: objdump.c:361 objdump.c:365
+#: objdump.c:394 objdump.c:398
msgid "Idx Name Size VMA LMA File off Algn"
msgstr ""
-#: objdump.c:367
+#: objdump.c:400
msgid ""
"Idx Name Size VMA LMA File off "
"Algn"
msgstr ""
-#: objdump.c:371
+#: objdump.c:404
msgid " Flags"
msgstr ""
-#: objdump.c:419
-#, c-format
-msgid "%s: not a dynamic object"
+#: objdump.c:406
+msgid " Pg"
msgstr ""
-#: objdump.c:433
+#: objdump.c:451
#, c-format
-msgid "%s: No dynamic symbols"
+msgid "%s: not a dynamic object"
msgstr ""
-#: objdump.c:1114
+#: objdump.c:1144
msgid "Out of virtual memory"
msgstr ""
-#: objdump.c:1543
+#: objdump.c:1574
#, c-format
msgid "Can't use supplied machine %s"
msgstr ""
-#: objdump.c:1561
+#: objdump.c:1592
#, c-format
msgid "Can't disassemble for architecture %s\n"
msgstr ""
-#: objdump.c:1643
+#: objdump.c:1682
#, c-format
msgid "Disassembly of section %s:\n"
msgstr ""
-#: objdump.c:1818
+#: objdump.c:1847
#, c-format
msgid ""
"No %s section present\n"
"\n"
msgstr ""
-#: objdump.c:1825
+#: objdump.c:1854
#, c-format
msgid "%s has no %s section"
msgstr ""
-#: objdump.c:1839
+#: objdump.c:1868
#, c-format
msgid "Reading %s section of %s failed: %s"
msgstr ""
-#: objdump.c:1851
+#: objdump.c:1880
#, c-format
msgid "Reading %s section of %s failed: %s\n"
msgstr ""
-#: objdump.c:1894
+#: objdump.c:1923
#, c-format
msgid ""
"Contents of %s section:\n"
"\n"
msgstr ""
-#: objdump.c:1994
+#: objdump.c:2021
#, c-format
msgid "architecture: %s, "
msgstr ""
-#: objdump.c:1997
+#: objdump.c:2024
#, c-format
msgid "flags 0x%08x:\n"
msgstr ""
-#: objdump.c:2010
+#: objdump.c:2038
msgid ""
"\n"
"start address 0x"
msgstr ""
-#: objdump.c:2042
+#: objdump.c:2071
#, c-format
msgid ""
"\n"
"%s: file format %s\n"
msgstr ""
-#: objdump.c:2084
+#: objdump.c:2111
#, c-format
msgid "%s: printing debugging information failed"
msgstr ""
-#: objdump.c:2161
+#: objdump.c:2190
#, c-format
msgid "In archive %s:\n"
msgstr ""
-#: objdump.c:2213
+#: objdump.c:2249
#, c-format
msgid "Contents of section %s:\n"
msgstr ""
-#: objdump.c:2719
-#, c-format
-msgid "BFD header file version %s\n"
+#: objdump.c:2369
+msgid "no symbols\n"
msgstr ""
-#: objdump.c:2808
+#: objdump.c:2718
msgid "unrecognized -E option"
msgstr ""
-#: objdump.c:2819
+#: objdump.c:2729
#, c-format
msgid "unrecognized --endian type `%s'"
msgstr ""
-#: rdcoff.c:204
+#: rdcoff.c:206
#, c-format
msgid "parse_coff_type: Bad type code 0x%x"
msgstr ""
-#: rdcoff.c:422 rdcoff.c:530 rdcoff.c:729
+#: rdcoff.c:424 rdcoff.c:532 rdcoff.c:731
#, c-format
msgid "bfd_coff_get_syment failed: %s"
msgstr ""
-#: rdcoff.c:438 rdcoff.c:749
+#: rdcoff.c:440 rdcoff.c:751
#, c-format
msgid "bfd_coff_get_auxent failed: %s"
msgstr ""
-#: rdcoff.c:816
+#: rdcoff.c:818
#, c-format
msgid "%ld: .bf without preceding function"
msgstr ""
-#: rdcoff.c:866
+#: rdcoff.c:868
#, c-format
msgid "%ld: unexpected .ef\n"
msgstr ""
-#: rddbg.c:87
+#: rddbg.c:91
#, c-format
msgid "%s: no recognized debugging information"
msgstr ""
-#: rddbg.c:410
+#: rddbg.c:415
msgid "Last stabs entries before error:\n"
msgstr ""
-#: readelf.c:328
+#: readelf.c:455
#, c-format
msgid "%s: Error: "
msgstr ""
-#: readelf.c:339
+#: readelf.c:466
#, c-format
msgid "%s: Warning: "
msgstr ""
-#: readelf.c:361
+#: readelf.c:488
#, c-format
-msgid "Unable to seek to %x for %s\n"
+msgid "Unable to seek to 0x%x for %s\n"
msgstr ""
-#: readelf.c:372
+#: readelf.c:499
#, c-format
-msgid "Out of memory allocating %d bytes for %s\n"
+msgid "Out of memory allocating 0x%x bytes for %s\n"
msgstr ""
-#: readelf.c:380
+#: readelf.c:507
#, c-format
-msgid "Unable to read in %d bytes of %s\n"
+msgid "Unable to read in 0x%x bytes of %s\n"
msgstr ""
-#: readelf.c:433 readelf.c:591
+#: readelf.c:560 readelf.c:614 readelf.c:798 readelf.c:833
#, c-format
msgid "Unhandled data length: %d\n"
msgstr ""
-#: readelf.c:675
+#: readelf.c:924
msgid "Don't know about relocations on this machine architecture\n"
msgstr ""
-#: readelf.c:697 readelf.c:726 readelf.c:772 readelf.c:799
+#: readelf.c:946 readelf.c:975 readelf.c:1021 readelf.c:1049
msgid "relocs"
msgstr ""
-#: readelf.c:708 readelf.c:737 readelf.c:782 readelf.c:809
+#: readelf.c:957 readelf.c:986 readelf.c:1031 readelf.c:1059
msgid "out of memory parsing relocs"
msgstr ""
-#: readelf.c:861
+#: readelf.c:1112
msgid ""
" Offset Info Type Sym. Value Symbol's Name + Addend\n"
msgstr ""
-#: readelf.c:863
+#: readelf.c:1114
msgid " Offset Info Type Sym.Value Sym. Name + Addend\n"
msgstr ""
-#: readelf.c:868
+#: readelf.c:1119
msgid " Offset Info Type Sym. Value Symbol's Name\n"
msgstr ""
-#: readelf.c:870
+#: readelf.c:1121
msgid " Offset Info Type Sym.Value Sym. Name\n"
msgstr ""
-#: readelf.c:878
+#: readelf.c:1129
msgid ""
-" Offset Info Type Symbol's Value "
+" Offset Info Type Symbol's Value "
"Symbol's Name + Addend\n"
msgstr ""
-#: readelf.c:880
+#: readelf.c:1131
msgid ""
" Offset Info Type Sym. Value Sym. Name + "
"Addend\n"
msgstr ""
-#: readelf.c:885
+#: readelf.c:1136
msgid ""
-" Offset Info Type Symbol's Value "
+" Offset Info Type Symbol's Value "
"Symbol's Name\n"
msgstr ""
-#: readelf.c:887
+#: readelf.c:1138
msgid ""
" Offset Info Type Sym. Value Sym. Name\n"
msgstr ""
-#: readelf.c:1134 readelf.c:1136 readelf.c:1184 readelf.c:1186 readelf.c:1195
-#: readelf.c:1197
+#: readelf.c:1414 readelf.c:1416 readelf.c:1492 readelf.c:1494 readelf.c:1503
+#: readelf.c:1505
#, c-format
msgid "unrecognized: %-7lx"
msgstr ""
-#: readelf.c:1158
+#: readelf.c:1466
#, c-format
msgid "<string table index %3ld>"
msgstr ""
-#: readelf.c:1423
+#: readelf.c:1743
#, c-format
msgid "Processor Specific: %lx"
msgstr ""
-#: readelf.c:1442
+#: readelf.c:1762
#, c-format
msgid "Operating System specific: %lx"
msgstr ""
-#: readelf.c:1445 readelf.c:2086
+#: readelf.c:1765 readelf.c:2417
#, c-format
msgid "<unknown>: %lx"
msgstr ""
-#: readelf.c:1459
+#: readelf.c:1779
msgid "NONE (None)"
msgstr ""
-#: readelf.c:1460
+#: readelf.c:1780
msgid "REL (Relocatable file)"
msgstr ""
-#: readelf.c:1461
+#: readelf.c:1781
msgid "EXEC (Executable file)"
msgstr ""
-#: readelf.c:1462
+#: readelf.c:1782
msgid "DYN (Shared object file)"
msgstr ""
-#: readelf.c:1463
+#: readelf.c:1783
msgid "CORE (Core file)"
msgstr ""
-#: readelf.c:1467
+#: readelf.c:1787
#, c-format
msgid "Processor Specific: (%x)"
msgstr ""
-#: readelf.c:1469
+#: readelf.c:1789
#, c-format
msgid "OS Specific: (%x)"
msgstr ""
-#: readelf.c:1471 readelf.c:1573 readelf.c:2238
+#: readelf.c:1791 readelf.c:1898 readelf.c:2574
#, c-format
msgid "<unknown>: %x"
msgstr ""
-#: readelf.c:1484
+#: readelf.c:1804
msgid "None"
msgstr ""
-#: readelf.c:2280
+#: readelf.c:2616
msgid "Usage: readelf <option(s)> elf-file(s)\n"
msgstr ""
-#: readelf.c:2281
+#: readelf.c:2617
msgid " Display information about the contents of ELF format files\n"
msgstr ""
-#: readelf.c:2282
+#: readelf.c:2618
msgid ""
" Options are:\n"
" -a --all Equivalent to: -h -l -S -s -r -d -V -A -I\n"
@@ -2333,13 +2378,13 @@ msgid ""
" Display the contents of DWARF2 debug sections\n"
msgstr ""
-#: readelf.c:2304
+#: readelf.c:2640
msgid ""
" -i --instruction-dump=<number>\n"
" Disassemble the contents of section <number>\n"
msgstr ""
-#: readelf.c:2308
+#: readelf.c:2644
msgid ""
" -I --histogram Display histogram of bucket list lengths\n"
" -W --wide Allow output width to exceed 80 characters\n"
@@ -2347,312 +2392,321 @@ msgid ""
" -v --version Display the version number of readelf\n"
msgstr ""
-#: readelf.c:2330
+#: readelf.c:2666 readelf.c:10765
msgid "Out of memory allocating dump request table."
msgstr ""
-#: readelf.c:2494 readelf.c:2570
+#: readelf.c:2830 readelf.c:2906
#, c-format
msgid "Unrecognized debug option '%s'\n"
msgstr ""
-#: readelf.c:2604
+#: readelf.c:2940
#, c-format
msgid "Invalid option '-%c'\n"
msgstr ""
-#: readelf.c:2617
+#: readelf.c:2953
msgid "Nothing to do.\n"
msgstr ""
-#: readelf.c:2630 readelf.c:2647 readelf.c:4952
+#: readelf.c:2966 readelf.c:2983 readelf.c:5366
msgid "none"
msgstr ""
-#: readelf.c:2634 readelf.c:2651 readelf.c:2679
+#: readelf.c:2970 readelf.c:2987 readelf.c:3018
#, c-format
msgid "<unknown: %x>"
msgstr ""
-#: readelf.c:2648
+#: readelf.c:2984
msgid "2's complement, little endian"
msgstr ""
-#: readelf.c:2649
+#: readelf.c:2985
msgid "2's complement, big endian"
msgstr ""
-#: readelf.c:2676
+#: readelf.c:3015
msgid "Standalone App"
msgstr ""
-#: readelf.c:2694
+#: readelf.c:3034
msgid "Not an ELF file - it has the wrong magic bytes at the start\n"
msgstr ""
-#: readelf.c:2702
+#: readelf.c:3042
msgid "ELF Header:\n"
msgstr ""
-#: readelf.c:2703
+#: readelf.c:3043
msgid " Magic: "
msgstr ""
-#: readelf.c:2707
+#: readelf.c:3047
#, c-format
msgid " Class: %s\n"
msgstr ""
-#: readelf.c:2709
+#: readelf.c:3049
#, c-format
msgid " Data: %s\n"
msgstr ""
-#: readelf.c:2711
+#: readelf.c:3051
#, c-format
msgid " Version: %d %s\n"
msgstr ""
-#: readelf.c:2718
+#: readelf.c:3058
#, c-format
msgid " OS/ABI: %s\n"
msgstr ""
-#: readelf.c:2720
+#: readelf.c:3060
#, c-format
msgid " ABI Version: %d\n"
msgstr ""
-#: readelf.c:2722
+#: readelf.c:3062
#, c-format
msgid " Type: %s\n"
msgstr ""
-#: readelf.c:2724
+#: readelf.c:3064
#, c-format
msgid " Machine: %s\n"
msgstr ""
-#: readelf.c:2726
+#: readelf.c:3066
#, c-format
msgid " Version: 0x%lx\n"
msgstr ""
-#: readelf.c:2729
+#: readelf.c:3069
msgid " Entry point address: "
msgstr ""
-#: readelf.c:2731
+#: readelf.c:3071
msgid ""
"\n"
" Start of program headers: "
msgstr ""
-#: readelf.c:2733
+#: readelf.c:3073
msgid ""
" (bytes into file)\n"
" Start of section headers: "
msgstr ""
-#: readelf.c:2735
+#: readelf.c:3075
msgid " (bytes into file)\n"
msgstr ""
-#: readelf.c:2737
+#: readelf.c:3077
#, c-format
msgid " Flags: 0x%lx%s\n"
msgstr ""
-#: readelf.c:2740
+#: readelf.c:3080
#, c-format
msgid " Size of this header: %ld (bytes)\n"
msgstr ""
-#: readelf.c:2742
+#: readelf.c:3082
#, c-format
msgid " Size of program headers: %ld (bytes)\n"
msgstr ""
-#: readelf.c:2744
+#: readelf.c:3084
#, c-format
msgid " Number of program headers: %ld\n"
msgstr ""
-#: readelf.c:2746
+#: readelf.c:3086
#, c-format
msgid " Size of section headers: %ld (bytes)\n"
msgstr ""
-#: readelf.c:2748
+#: readelf.c:3088
#, c-format
msgid " Number of section headers: %ld"
msgstr ""
-#: readelf.c:2753
+#: readelf.c:3093
#, c-format
msgid " Section header string table index: %ld"
msgstr ""
-#: readelf.c:2787 readelf.c:2823
+#: readelf.c:3127 readelf.c:3163
msgid "program headers"
msgstr ""
-#: readelf.c:2857
+#: readelf.c:3203 readelf.c:3480 readelf.c:3526 readelf.c:3589 readelf.c:3656
+#: readelf.c:4715 readelf.c:4758 readelf.c:4948 readelf.c:5917 readelf.c:5931
+#: readelf.c:10411
+msgid "Out of memory\n"
+msgstr ""
+
+#: readelf.c:3231
msgid ""
"\n"
"There are no program headers in this file.\n"
msgstr ""
-#: readelf.c:2863
+#: readelf.c:3237
#, c-format
msgid ""
"\n"
"Elf file type is %s\n"
msgstr ""
-#: readelf.c:2864
+#: readelf.c:3238
msgid "Entry point "
msgstr ""
-#: readelf.c:2866
+#: readelf.c:3240
#, c-format
msgid ""
"\n"
"There are %d program headers, starting at offset "
msgstr ""
-#: readelf.c:2877 readelf.c:3104 readelf.c:3150 readelf.c:3213 readelf.c:3280
-#: readelf.c:4314 readelf.c:4357 readelf.c:4546 readelf.c:5499 readelf.c:5513
-#: readelf.c:9747 readelf.c:9787
-msgid "Out of memory\n"
-msgstr ""
-
-#: readelf.c:2895 readelf.c:2897
+#: readelf.c:3252 readelf.c:3254
msgid ""
"\n"
"Program Headers:\n"
msgstr ""
-#: readelf.c:2901
+#: readelf.c:3258
msgid ""
" Type Offset VirtAddr PhysAddr FileSiz MemSiz Flg Align\n"
msgstr ""
-#: readelf.c:2904
+#: readelf.c:3261
msgid ""
" Type Offset VirtAddr PhysAddr FileSiz "
"MemSiz Flg Align\n"
msgstr ""
-#: readelf.c:2908
+#: readelf.c:3265
msgid " Type Offset VirtAddr PhysAddr\n"
msgstr ""
-#: readelf.c:2910
+#: readelf.c:3267
msgid " FileSiz MemSiz Flags Align\n"
msgstr ""
-#: readelf.c:3010
+#: readelf.c:3360
msgid "more than one dynamic segment\n"
msgstr ""
-#: readelf.c:3018
+#: readelf.c:3368
msgid "Unable to find program interpreter name\n"
msgstr ""
-#: readelf.c:3025
+#: readelf.c:3375
#, c-format
msgid ""
"\n"
" [Requesting program interpreter: %s]"
msgstr ""
-#: readelf.c:3043
+#: readelf.c:3387
msgid ""
"\n"
" Section to Segment mapping:\n"
msgstr ""
-#: readelf.c:3044
+#: readelf.c:3388
msgid " Segment Sections...\n"
msgstr ""
-#: readelf.c:3095 readelf.c:3141
+#: readelf.c:3437
+msgid "Cannot interpret virtual addresses without program headers.\n"
+msgstr ""
+
+#: readelf.c:3453
+#, c-format
+msgid "Virtual address 0x%lx not located in any PT_LOAD segment.\n"
+msgstr ""
+
+#: readelf.c:3471 readelf.c:3517
msgid "section headers"
msgstr ""
-#: readelf.c:3189 readelf.c:3256
+#: readelf.c:3565 readelf.c:3632
msgid "symbols"
msgstr ""
-#: readelf.c:3200 readelf.c:3267
+#: readelf.c:3576 readelf.c:3643
msgid "symtab shndx"
msgstr ""
-#: readelf.c:3369
+#: readelf.c:3745
msgid ""
"\n"
"There are no sections in this file.\n"
msgstr ""
-#: readelf.c:3375
+#: readelf.c:3751
#, c-format
msgid "There are %d section headers, starting at offset 0x%lx:\n"
msgstr ""
-#: readelf.c:3392 readelf.c:3706 readelf.c:4053 readelf.c:5650
+#: readelf.c:3768 readelf.c:4098 readelf.c:4433 readelf.c:6070
msgid "string table"
msgstr ""
-#: readelf.c:3413
+#: readelf.c:3793
msgid "File contains multiple dynamic symbol tables\n"
msgstr ""
-#: readelf.c:3425
+#: readelf.c:3805
msgid "File contains multiple dynamic string tables\n"
msgstr ""
-#: readelf.c:3431
+#: readelf.c:3811
msgid "dynamic strings"
msgstr ""
-#: readelf.c:3437
+#: readelf.c:3817
msgid "File contains multiple symtab shndx tables\n"
msgstr ""
-#: readelf.c:3475
+#: readelf.c:3855
msgid ""
"\n"
"Section Headers:\n"
msgstr ""
-#: readelf.c:3477
+#: readelf.c:3857
msgid ""
"\n"
"Section Header:\n"
msgstr ""
-#: readelf.c:3481
+#: readelf.c:3861
msgid ""
" [Nr] Name Type Addr Off Size ES Flg Lk "
"Inf Al\n"
msgstr ""
-#: readelf.c:3484
+#: readelf.c:3864
msgid ""
" [Nr] Name Type Address Off Size ES "
"Flg Lk Inf Al\n"
msgstr ""
-#: readelf.c:3487
+#: readelf.c:3867
msgid " [Nr] Name Type Address Offset\n"
msgstr ""
-#: readelf.c:3488
+#: readelf.c:3868
msgid " Size EntSize Flags Link Info Align\n"
msgstr ""
-#: readelf.c:3583
+#: readelf.c:3963
msgid ""
"Key to Flags:\n"
" W (write), A (alloc), X (execute), M (merge), S (strings)\n"
@@ -2660,500 +2714,500 @@ msgid ""
" O (extra OS processing required) o (OS specific), p (processor specific)\n"
msgstr ""
-#: readelf.c:3644
+#: readelf.c:4031
#, c-format
msgid ""
"\n"
-"Relocation section at offset 0x%lx contains %ld bytes:\n"
+"'%s' relocation section at offset 0x%lx contains %ld bytes:\n"
msgstr ""
-#: readelf.c:3651
+#: readelf.c:4043
msgid ""
"\n"
"There are no dynamic relocations in this file.\n"
msgstr ""
-#: readelf.c:3678
+#: readelf.c:4070
msgid ""
"\n"
"Relocation section "
msgstr ""
-#: readelf.c:3683 readelf.c:4116 readelf.c:4130
+#: readelf.c:4075 readelf.c:4496 readelf.c:4510
#, c-format
msgid "'%s'"
msgstr ""
-#: readelf.c:3685 readelf.c:4132
+#: readelf.c:4077 readelf.c:4512
#, c-format
msgid " at offset 0x%lx contains %lu entries:\n"
msgstr ""
-#: readelf.c:3723
+#: readelf.c:4115
msgid ""
"\n"
"There are no relocations in this file.\n"
msgstr ""
-#: readelf.c:3919
+#: readelf.c:4299
msgid "unwind table"
msgstr ""
-#: readelf.c:3970 readelf.c:3982 readelf.c:7977 readelf.c:7989
+#: readelf.c:4350 readelf.c:4362 readelf.c:8499 readelf.c:8511
#, c-format
msgid "Skipping unexpected symbol type %u\n"
msgstr ""
-#: readelf.c:3990
+#: readelf.c:4370
#, c-format
msgid "Skipping unexpected relocation type %s\n"
msgstr ""
-#: readelf.c:4035 readelf.c:4060
+#: readelf.c:4415 readelf.c:4440
msgid ""
"\n"
"There are no unwind sections in this file.\n"
msgstr ""
-#: readelf.c:4111
+#: readelf.c:4491
msgid ""
"\n"
"Could not find unwind info section for "
msgstr ""
-#: readelf.c:4123
+#: readelf.c:4503
msgid "unwind info"
msgstr ""
-#: readelf.c:4125
+#: readelf.c:4505
msgid ""
"\n"
"Unwind section "
msgstr ""
-#: readelf.c:4298 readelf.c:4341
+#: readelf.c:4699 readelf.c:4742
msgid "dynamic segment"
msgstr ""
-#: readelf.c:4419
+#: readelf.c:4820
msgid ""
"\n"
"There is no dynamic segment in this file.\n"
msgstr ""
-#: readelf.c:4453
+#: readelf.c:4854
msgid "Unable to seek to end of file!"
msgstr ""
-#: readelf.c:4464
+#: readelf.c:4865
msgid "Unable to determine the number of symbols to load\n"
msgstr ""
-#: readelf.c:4494
+#: readelf.c:4895
msgid "Unable to seek to end of file\n"
msgstr ""
-#: readelf.c:4500
+#: readelf.c:4901
msgid "Unable to determine the length of the dynamic string table\n"
msgstr ""
-#: readelf.c:4505
+#: readelf.c:4906
msgid "dynamic string table"
msgstr ""
-#: readelf.c:4539
+#: readelf.c:4941
msgid "symbol information"
msgstr ""
-#: readelf.c:4563
+#: readelf.c:4965
#, c-format
msgid ""
"\n"
-"Dynamic segment at offset 0x%x contains %ld entries:\n"
+"Dynamic segment at offset 0x%lx contains %ld entries:\n"
msgstr ""
-#: readelf.c:4566
+#: readelf.c:4968
msgid " Tag Type Name/Value\n"
msgstr ""
-#: readelf.c:4602
+#: readelf.c:5004
msgid "Auxiliary library"
msgstr ""
-#: readelf.c:4606
+#: readelf.c:5008
msgid "Filter library"
msgstr ""
-#: readelf.c:4610
+#: readelf.c:5012
msgid "Configuration file"
msgstr ""
-#: readelf.c:4614
+#: readelf.c:5016
msgid "Dependency audit library"
msgstr ""
-#: readelf.c:4618
+#: readelf.c:5020
msgid "Audit library"
msgstr ""
-#: readelf.c:4636 readelf.c:4662 readelf.c:4688
+#: readelf.c:5038 readelf.c:5066 readelf.c:5094
msgid "Flags:"
msgstr ""
-#: readelf.c:4638 readelf.c:4664 readelf.c:4690
+#: readelf.c:5041 readelf.c:5069 readelf.c:5096
msgid " None\n"
msgstr ""
-#: readelf.c:4809
+#: readelf.c:5217
#, c-format
msgid "Shared library: [%s]"
msgstr ""
-#: readelf.c:4812
+#: readelf.c:5220
msgid " program interpreter"
msgstr ""
-#: readelf.c:4816
+#: readelf.c:5224
#, c-format
msgid "Library soname: [%s]"
msgstr ""
-#: readelf.c:4820
+#: readelf.c:5228
#, c-format
msgid "Library rpath: [%s]"
msgstr ""
-#: readelf.c:4824
+#: readelf.c:5232
#, c-format
msgid "Library runpath: [%s]"
msgstr ""
-#: readelf.c:4887
+#: readelf.c:5296
#, c-format
msgid "Not needed object: [%s]\n"
msgstr ""
-#: readelf.c:4998
+#: readelf.c:5412
#, c-format
msgid ""
"\n"
"Version definition section '%s' contains %ld entries:\n"
msgstr ""
-#: readelf.c:5001
+#: readelf.c:5415
msgid " Addr: 0x"
msgstr ""
-#: readelf.c:5003 readelf.c:5198
+#: readelf.c:5417 readelf.c:5612
#, c-format
msgid " Offset: %#08lx Link: %lx (%s)\n"
msgstr ""
-#: readelf.c:5010
+#: readelf.c:5424
msgid "version definition section"
msgstr ""
-#: readelf.c:5036
+#: readelf.c:5450
#, c-format
msgid " %#06x: Rev: %d Flags: %s"
msgstr ""
-#: readelf.c:5039
+#: readelf.c:5453
#, c-format
msgid " Index: %d Cnt: %d "
msgstr ""
-#: readelf.c:5050
+#: readelf.c:5464
#, c-format
msgid "Name: %s\n"
msgstr ""
-#: readelf.c:5052
+#: readelf.c:5466
#, c-format
msgid "Name index: %ld\n"
msgstr ""
-#: readelf.c:5067
+#: readelf.c:5481
#, c-format
msgid " %#06x: Parent %d: %s\n"
msgstr ""
-#: readelf.c:5070
+#: readelf.c:5484
#, c-format
msgid " %#06x: Parent %d, name index: %ld\n"
msgstr ""
-#: readelf.c:5089
+#: readelf.c:5503
#, c-format
msgid ""
"\n"
"Version needs section '%s' contains %ld entries:\n"
msgstr ""
-#: readelf.c:5092
+#: readelf.c:5506
msgid " Addr: 0x"
msgstr ""
-#: readelf.c:5094
+#: readelf.c:5508
#, c-format
msgid " Offset: %#08lx Link to section: %ld (%s)\n"
msgstr ""
-#: readelf.c:5100
+#: readelf.c:5514
msgid "version need section"
msgstr ""
-#: readelf.c:5122
+#: readelf.c:5536
#, c-format
msgid " %#06x: Version: %d"
msgstr ""
-#: readelf.c:5125
+#: readelf.c:5539
#, c-format
msgid " File: %s"
msgstr ""
-#: readelf.c:5127
+#: readelf.c:5541
#, c-format
msgid " File: %lx"
msgstr ""
-#: readelf.c:5129
+#: readelf.c:5543
#, c-format
msgid " Cnt: %d\n"
msgstr ""
-#: readelf.c:5147
+#: readelf.c:5561
#, c-format
msgid " %#06x: Name: %s"
msgstr ""
-#: readelf.c:5150
+#: readelf.c:5564
#, c-format
msgid " %#06x: Name index: %lx"
msgstr ""
-#: readelf.c:5153
+#: readelf.c:5567
#, c-format
msgid " Flags: %s Version: %d\n"
msgstr ""
-#: readelf.c:5189
+#: readelf.c:5603
msgid "version string table"
msgstr ""
-#: readelf.c:5193
+#: readelf.c:5607
#, c-format
msgid ""
"\n"
"Version symbols section '%s' contains %d entries:\n"
msgstr ""
-#: readelf.c:5196
+#: readelf.c:5610
msgid " Addr: "
msgstr ""
-#: readelf.c:5206
+#: readelf.c:5622
msgid "version symbol data"
msgstr ""
-#: readelf.c:5233
+#: readelf.c:5649
msgid " 0 (*local*) "
msgstr ""
-#: readelf.c:5237
+#: readelf.c:5653
msgid " 1 (*global*) "
msgstr ""
-#: readelf.c:5272 readelf.c:5707
+#: readelf.c:5689 readelf.c:6129
msgid "version need"
msgstr ""
-#: readelf.c:5282
+#: readelf.c:5699
msgid "version need aux (2)"
msgstr ""
-#: readelf.c:5323 readelf.c:5769
+#: readelf.c:5741 readelf.c:6192
msgid "version def"
msgstr ""
-#: readelf.c:5342 readelf.c:5784
+#: readelf.c:5760 readelf.c:6207
msgid "version def aux"
msgstr ""
-#: readelf.c:5373
+#: readelf.c:5791
msgid ""
"\n"
"No version information found in this file.\n"
msgstr ""
-#: readelf.c:5505
+#: readelf.c:5923
msgid "Unable to read in dynamic data\n"
msgstr ""
-#: readelf.c:5547
+#: readelf.c:5967
msgid "Unable to seek to start of dynamic information"
msgstr ""
-#: readelf.c:5553
+#: readelf.c:5973
msgid "Failed to read in number of buckets\n"
msgstr ""
-#: readelf.c:5559
+#: readelf.c:5979
msgid "Failed to read in number of chains\n"
msgstr ""
-#: readelf.c:5579
+#: readelf.c:5999
msgid ""
"\n"
"Symbol table for image:\n"
msgstr ""
-#: readelf.c:5581
+#: readelf.c:6001
msgid " Num Buc: Value Size Type Bind Vis Ndx Name\n"
msgstr ""
-#: readelf.c:5583
+#: readelf.c:6003
msgid " Num Buc: Value Size Type Bind Vis Ndx Name\n"
msgstr ""
-#: readelf.c:5628
+#: readelf.c:6048
#, c-format
msgid ""
"\n"
"Symbol table '%s' contains %lu entries:\n"
msgstr ""
-#: readelf.c:5632
+#: readelf.c:6052
msgid " Num: Value Size Type Bind Vis Ndx Name\n"
msgstr ""
-#: readelf.c:5634
+#: readelf.c:6054
msgid " Num: Value Size Type Bind Vis Ndx Name\n"
msgstr ""
-#: readelf.c:5680
+#: readelf.c:6101
msgid "version data"
msgstr ""
-#: readelf.c:5720
+#: readelf.c:6142
msgid "version need aux (3)"
msgstr ""
-#: readelf.c:5745
+#: readelf.c:6167
msgid "bad dynamic symbol"
msgstr ""
-#: readelf.c:5807
+#: readelf.c:6230
msgid ""
"\n"
"Dynamic symbol information is not available for displaying symbols.\n"
msgstr ""
-#: readelf.c:5819
+#: readelf.c:6242
#, c-format
msgid ""
"\n"
"Histogram for bucket list length (total of %d buckets):\n"
msgstr ""
-#: readelf.c:5821
+#: readelf.c:6244
#, c-format
msgid " Length Number %% of total Coverage\n"
msgstr ""
-#: readelf.c:5826 readelf.c:5845 readelf.c:9234 readelf.c:9426
+#: readelf.c:6249 readelf.c:6268 readelf.c:9898 readelf.c:10090
msgid "Out of memory"
msgstr ""
-#: readelf.c:5894
+#: readelf.c:6317
#, c-format
msgid ""
"\n"
"Dynamic info segment at offset 0x%lx contains %d entries:\n"
msgstr ""
-#: readelf.c:5897
+#: readelf.c:6320
msgid " Num: Name BoundTo Flags\n"
msgstr ""
-#: readelf.c:5949
+#: readelf.c:6373
#, c-format
msgid ""
"\n"
"Assembly dump of section %s\n"
msgstr ""
-#: readelf.c:5972
+#: readelf.c:6396
#, c-format
msgid ""
"\n"
"Section '%s' has no data to dump.\n"
msgstr ""
-#: readelf.c:5977
+#: readelf.c:6401
#, c-format
msgid ""
"\n"
"Hex dump of section '%s':\n"
msgstr ""
-#: readelf.c:5982
+#: readelf.c:6406
msgid "section data"
msgstr ""
-#: readelf.c:6131
+#: readelf.c:6555
msgid "badly formed extended line op encountered!\n"
msgstr ""
-#: readelf.c:6138
+#: readelf.c:6562
#, c-format
msgid " Extended opcode %d: "
msgstr ""
-#: readelf.c:6143
+#: readelf.c:6567
msgid ""
"End of Sequence\n"
"\n"
msgstr ""
-#: readelf.c:6149
+#: readelf.c:6573
#, c-format
msgid "set Address to 0x%lx\n"
msgstr ""
-#: readelf.c:6154
+#: readelf.c:6578
msgid " define new File Table entry\n"
msgstr ""
-#: readelf.c:6155 readelf.c:6284
+#: readelf.c:6579 readelf.c:6726
msgid " Entry\tDir\tTime\tSize\tName\n"
msgstr ""
-#: readelf.c:6157
+#: readelf.c:6581
#, c-format
msgid " %d\t"
msgstr ""
-#: readelf.c:6160 readelf.c:6162 readelf.c:6164 readelf.c:6296 readelf.c:6298
-#: readelf.c:6300
+#: readelf.c:6584 readelf.c:6586 readelf.c:6588 readelf.c:6738 readelf.c:6740
+#: readelf.c:6742
#, c-format
msgid "%lu\t"
msgstr ""
-#: readelf.c:6165
+#: readelf.c:6589
#, c-format
msgid ""
"%s\n"
"\n"
msgstr ""
-#: readelf.c:6169
+#: readelf.c:6593
#, c-format
msgid "UNKNOWN: length %d\n"
msgstr ""
-#: readelf.c:6195
+#: readelf.c:6621
#, c-format
msgid ""
"\n"
@@ -3161,690 +3215,674 @@ msgid ""
"\n"
msgstr ""
-#: readelf.c:6207
-msgid "64-bit DWARF line info is not supported yet.\n"
-msgstr ""
-
-#: readelf.c:6214
+#: readelf.c:6649
msgid "The line info appears to be corrupt - the section is too small\n"
msgstr ""
-#: readelf.c:6222
-msgid "Only DWARF version 2 line info is currently supported.\n"
+#: readelf.c:6658
+msgid "Only DWARF version 2 and 3 line info is currently supported.\n"
msgstr ""
-#: readelf.c:6237
+#: readelf.c:6679
#, c-format
msgid " Length: %ld\n"
msgstr ""
-#: readelf.c:6238
+#: readelf.c:6680
#, c-format
msgid " DWARF Version: %d\n"
msgstr ""
-#: readelf.c:6239
+#: readelf.c:6681
#, c-format
msgid " Prologue Length: %d\n"
msgstr ""
-#: readelf.c:6240
+#: readelf.c:6682
#, c-format
msgid " Minimum Instruction Length: %d\n"
msgstr ""
-#: readelf.c:6241
+#: readelf.c:6683
#, c-format
msgid " Initial value of 'is_stmt': %d\n"
msgstr ""
-#: readelf.c:6242
+#: readelf.c:6684
#, c-format
msgid " Line Base: %d\n"
msgstr ""
-#: readelf.c:6243
+#: readelf.c:6685
#, c-format
msgid " Line Range: %d\n"
msgstr ""
-#: readelf.c:6244
+#: readelf.c:6686
#, c-format
msgid " Opcode Base: %d\n"
msgstr ""
-#: readelf.c:6253
+#: readelf.c:6695
msgid ""
"\n"
" Opcodes:\n"
msgstr ""
-#: readelf.c:6256
+#: readelf.c:6698
#, c-format
msgid " Opcode %d has %d args\n"
msgstr ""
-#: readelf.c:6262
+#: readelf.c:6704
msgid ""
"\n"
" The Directory Table is empty.\n"
msgstr ""
-#: readelf.c:6265
+#: readelf.c:6707
msgid ""
"\n"
" The Directory Table:\n"
msgstr ""
-#: readelf.c:6269
+#: readelf.c:6711
#, c-format
msgid " %s\n"
msgstr ""
-#: readelf.c:6280
+#: readelf.c:6722
msgid ""
"\n"
" The File Name Table is empty.\n"
msgstr ""
-#: readelf.c:6283
+#: readelf.c:6725
msgid ""
"\n"
" The File Name Table:\n"
msgstr ""
-#: readelf.c:6291
+#: readelf.c:6733
#, c-format
msgid " %d\t"
msgstr ""
-#: readelf.c:6302
+#: readelf.c:6744
#, c-format
msgid "%s\n"
msgstr ""
#. Now display the statements.
-#: readelf.c:6310
+#: readelf.c:6752
msgid ""
"\n"
" Line Number Statements:\n"
msgstr ""
-#: readelf.c:6326
+#: readelf.c:6768
#, c-format
msgid " Special opcode %d: advance Address by %d to 0x%lx"
msgstr ""
-#: readelf.c:6330
+#: readelf.c:6772
#, c-format
msgid " and Line by %d to %d\n"
msgstr ""
-#: readelf.c:6341
+#: readelf.c:6783
msgid " Copy\n"
msgstr ""
-#: readelf.c:6348
+#: readelf.c:6790
#, c-format
msgid " Advance PC by %d to %lx\n"
msgstr ""
-#: readelf.c:6356
+#: readelf.c:6798
#, c-format
msgid " Advance Line by %d to %d\n"
msgstr ""
-#: readelf.c:6363
+#: readelf.c:6805
#, c-format
msgid " Set File Name to entry %d in the File Name Table\n"
msgstr ""
-#: readelf.c:6371
+#: readelf.c:6813
#, c-format
msgid " Set column to %d\n"
msgstr ""
-#: readelf.c:6378
+#: readelf.c:6820
#, c-format
msgid " Set is_stmt to %d\n"
msgstr ""
-#: readelf.c:6383
+#: readelf.c:6825
msgid " Set basic block\n"
msgstr ""
-#: readelf.c:6391
+#: readelf.c:6833
#, c-format
msgid " Advance PC by constant %d to 0x%lx\n"
msgstr ""
-#: readelf.c:6399
+#: readelf.c:6841
#, c-format
msgid " Advance PC by fixed size amount %d to 0x%lx\n"
msgstr ""
-#: readelf.c:6404
+#: readelf.c:6846
msgid " Set prologue_end to true\n"
msgstr ""
-#: readelf.c:6408
+#: readelf.c:6850
msgid " Set epilogue_begin to true\n"
msgstr ""
-#: readelf.c:6414
+#: readelf.c:6856
#, c-format
msgid " Set ISA to %d\n"
msgstr ""
-#: readelf.c:6418
+#: readelf.c:6860
#, c-format
msgid " Unknown opcode %d with operands: "
msgstr ""
-#: readelf.c:6450 readelf.c:6912 readelf.c:6984
+#: readelf.c:6891 readelf.c:7371 readelf.c:7443
#, c-format
msgid ""
"Contents of the %s section:\n"
"\n"
msgstr ""
-#: readelf.c:6469
-msgid "64-bit DWARF pubnames are not supported yet.\n"
+#: readelf.c:6931
+msgid "Only DWARF 2 and 3 pubnames are currently supported\n"
msgstr ""
-#: readelf.c:6479
-msgid "Only DWARF 2 pubnames are currently supported\n"
-msgstr ""
-
-#: readelf.c:6486
+#: readelf.c:6938
#, c-format
msgid " Length: %ld\n"
msgstr ""
-#: readelf.c:6488
+#: readelf.c:6940
#, c-format
msgid " Version: %d\n"
msgstr ""
-#: readelf.c:6490
+#: readelf.c:6942
#, c-format
msgid " Offset into .debug_info section: %ld\n"
msgstr ""
-#: readelf.c:6492
+#: readelf.c:6944
#, c-format
msgid " Size of area in .debug_info section: %ld\n"
msgstr ""
-#: readelf.c:6495
+#: readelf.c:6947
msgid ""
"\n"
" Offset\tName\n"
msgstr ""
-#: readelf.c:6586
+#: readelf.c:7042
#, c-format
msgid "Unknown TAG value: %lx"
msgstr ""
-#: readelf.c:6697
+#: readelf.c:7156
#, c-format
msgid "Unknown AT value: %lx"
msgstr ""
-#: readelf.c:6734
+#: readelf.c:7193
#, c-format
msgid "Unknown FORM value: %lx"
msgstr ""
-#: readelf.c:6933
+#: readelf.c:7392
#, c-format
msgid " DW_MACINFO_start_file - lineno: %d filenum: %d\n"
msgstr ""
-#: readelf.c:6938
+#: readelf.c:7397
msgid " DW_MACINFO_end_file\n"
msgstr ""
-#: readelf.c:6946
+#: readelf.c:7405
#, c-format
msgid " DW_MACINFO_define - lineno : %d macro : %s\n"
msgstr ""
-#: readelf.c:6954
+#: readelf.c:7413
#, c-format
msgid " DW_MACINFO_undef - lineno : %d macro : %s\n"
msgstr ""
-#: readelf.c:6965
+#: readelf.c:7424
#, c-format
msgid " DW_MACINFO_vendor_ext - constant : %d string : %s\n"
msgstr ""
-#: readelf.c:6993
+#: readelf.c:7452
msgid " Number TAG\n"
msgstr ""
-#: readelf.c:6999
+#: readelf.c:7458
#, c-format
msgid " %ld %s [%s]\n"
msgstr ""
-#: readelf.c:7002
+#: readelf.c:7461
msgid "has children"
msgstr ""
-#: readelf.c:7002
+#: readelf.c:7461
msgid "no children"
msgstr ""
-#: readelf.c:7006
+#: readelf.c:7465
#, c-format
msgid " %-18s %s\n"
msgstr ""
-#: readelf.c:7027
+#: readelf.c:7486
#, c-format
msgid " %lu byte block: "
msgstr ""
-#: readelf.c:7350
+#: readelf.c:7814
msgid "(User defined location op)"
msgstr ""
-#: readelf.c:7352
+#: readelf.c:7816
msgid "(Unknown location op)"
msgstr ""
-#: readelf.c:7390
+#: readelf.c:7855
msgid "debug_loc section data"
msgstr ""
-#: readelf.c:7421
+#: readelf.c:7887
msgid ""
"\n"
"The .debug_loc section is empty.\n"
msgstr ""
-#: readelf.c:7424
+#: readelf.c:7891
msgid ""
"Contents of the .debug_loc section:\n"
"\n"
msgstr ""
-#: readelf.c:7425
+#: readelf.c:7892
msgid ""
"\n"
" Offset Begin End Expression\n"
msgstr ""
-#: readelf.c:7497
+#: readelf.c:7968
msgid "debug_str section data"
msgstr ""
-#: readelf.c:7516
+#: readelf.c:7987
msgid "<no .debug_str section>"
msgstr ""
-#: readelf.c:7519
+#: readelf.c:7990
msgid "<offset is too big>"
msgstr ""
-#: readelf.c:7539
+#: readelf.c:8009
msgid ""
"\n"
"The .debug_str section is empty.\n"
msgstr ""
-#: readelf.c:7543
+#: readelf.c:8013
msgid ""
"Contents of the .debug_str section:\n"
"\n"
msgstr ""
-#: readelf.c:7714
+#: readelf.c:8088
+msgid "Internal error: DWARF version is not 2 or 3.\n"
+msgstr ""
+
+#: readelf.c:8203
#, c-format
-msgid " (indirect string, offset: 0x%lx): "
+msgid " (indirect string, offset: 0x%lx): %s"
msgstr ""
-#: readelf.c:7723
+#: readelf.c:8212
#, c-format
msgid "Unrecognized form: %d\n"
msgstr ""
-#: readelf.c:7736
+#: readelf.c:8226
msgid "(not inlined)"
msgstr ""
-#: readelf.c:7737
+#: readelf.c:8229
msgid "(inlined)"
msgstr ""
-#: readelf.c:7738
+#: readelf.c:8232
msgid "(declared as inline but ignored)"
msgstr ""
-#: readelf.c:7739
+#: readelf.c:8235
msgid "(declared as inline and inlined)"
msgstr ""
-#: readelf.c:7740
+#: readelf.c:8238
#, c-format
msgid " (Unknown inline attribute value: %lx)"
msgstr ""
-#: readelf.c:7911 readelf.c:8117
+#: readelf.c:8419 readelf.c:8646
#, c-format
msgid ""
"The section %s contains:\n"
"\n"
msgstr ""
-#: readelf.c:7935
-msgid "64-bit DWARF debug info is not supported yet.\n"
-msgstr ""
-
-#: readelf.c:8007
+#: readelf.c:8535
#, c-format
msgid " Compilation Unit @ %lx:\n"
msgstr ""
-#: readelf.c:8008
+#: readelf.c:8536
#, c-format
msgid " Length: %ld\n"
msgstr ""
-#: readelf.c:8009
+#: readelf.c:8537
#, c-format
msgid " Version: %d\n"
msgstr ""
-#: readelf.c:8010
+#: readelf.c:8538
#, c-format
msgid " Abbrev Offset: %ld\n"
msgstr ""
-#: readelf.c:8011
+#: readelf.c:8539
#, c-format
msgid " Pointer Size: %d\n"
msgstr ""
-#: readelf.c:8015
-msgid "Only version 2 DWARF debug information is currently supported.\n"
+#: readelf.c:8543
+msgid "Only version 2 and 3 DWARF debug information is currently supported.\n"
msgstr ""
-#: readelf.c:8036
+#: readelf.c:8563
msgid "Unable to locate .debug_abbrev section!\n"
msgstr ""
-#: readelf.c:8042
+#: readelf.c:8569
msgid "debug_abbrev section data"
msgstr ""
-#: readelf.c:8079
+#: readelf.c:8606
#, c-format
msgid "Unable to locate entry %lu in the abbreviation table\n"
msgstr ""
-#: readelf.c:8084
+#: readelf.c:8611
#, c-format
msgid " <%d><%lx>: Abbrev Number: %lu (%s)\n"
msgstr ""
-#: readelf.c:8138
-msgid "64-bit DWARF aranges are not supported yet.\n"
-msgstr ""
-
-#: readelf.c:8144
-msgid "Only DWARF 2 aranges are currently supported.\n"
+#: readelf.c:8691
+msgid "Only DWARF 2 and 3 aranges are currently supported.\n"
msgstr ""
-#: readelf.c:8148
+#: readelf.c:8695
#, c-format
msgid " Length: %ld\n"
msgstr ""
-#: readelf.c:8149
+#: readelf.c:8696
#, c-format
msgid " Version: %d\n"
msgstr ""
-#: readelf.c:8150
+#: readelf.c:8697
#, c-format
msgid " Offset into .debug_info: %lx\n"
msgstr ""
-#: readelf.c:8151
+#: readelf.c:8698
#, c-format
msgid " Pointer Size: %d\n"
msgstr ""
-#: readelf.c:8152
+#: readelf.c:8699
#, c-format
msgid " Segment Size: %d\n"
msgstr ""
-#: readelf.c:8154
+#: readelf.c:8701
msgid ""
"\n"
" Address Length\n"
msgstr ""
-#: readelf.c:8336
+#: readelf.c:8903
#, c-format
msgid "The section %s contains:\n"
msgstr ""
-#: readelf.c:8359
-msgid "64-bit DWARF format frames are not supported yet.\n"
-msgstr ""
-
-#: readelf.c:8908
+#: readelf.c:9538
#, c-format
msgid "Displaying the debug contents of section %s is not yet supported.\n"
msgstr ""
-#: readelf.c:8974
+#: readelf.c:9634
#, c-format
msgid ""
"\n"
"Section '%s' has no debugging data.\n"
msgstr ""
-#: readelf.c:8979 readelf.c:9041
+#: readelf.c:9639 readelf.c:9701
msgid "debug section data"
msgstr ""
-#: readelf.c:8995
+#: readelf.c:9655
#, c-format
msgid "Unrecognized debug section: %s\n"
msgstr ""
-#: readelf.c:9069
+#: readelf.c:9729
msgid "Some sections were not dumped because they do not exist!\n"
msgstr ""
-#: readelf.c:9142 readelf.c:9506
+#: readelf.c:9806 readelf.c:10170
msgid "liblist"
msgstr ""
-#: readelf.c:9227
+#: readelf.c:9891
msgid "options"
msgstr ""
-#: readelf.c:9258
+#: readelf.c:9922
#, c-format
msgid ""
"\n"
"Section '%s' contains %d entries:\n"
msgstr ""
-#: readelf.c:9419
+#: readelf.c:10083
msgid "conflict list found without a dynamic symbol table"
msgstr ""
-#: readelf.c:9437 readelf.c:9453
+#: readelf.c:10101 readelf.c:10117
msgid "conflict"
msgstr ""
-#: readelf.c:9463
+#: readelf.c:10127
#, c-format
msgid ""
"\n"
"Section '.conflict' contains %ld entries:\n"
msgstr ""
-#: readelf.c:9465
+#: readelf.c:10129
msgid " Num: Index Value Name"
msgstr ""
-#: readelf.c:9514
+#: readelf.c:10178
msgid "liblist string table"
msgstr ""
-#: readelf.c:9523
+#: readelf.c:10187
#, c-format
msgid ""
"\n"
"Library list section '%s' contains %lu entries:\n"
msgstr ""
-#: readelf.c:9572
+#: readelf.c:10236
msgid "NT_PRSTATUS (prstatus structure)"
msgstr ""
-#: readelf.c:9573
+#: readelf.c:10237
msgid "NT_FPREGSET (floating point registers)"
msgstr ""
-#: readelf.c:9574
+#: readelf.c:10238
msgid "NT_PRPSINFO (prpsinfo structure)"
msgstr ""
-#: readelf.c:9575
+#: readelf.c:10239
msgid "NT_TASKSTRUCT (task structure)"
msgstr ""
-#: readelf.c:9576
+#: readelf.c:10240
msgid "NT_PRXFPREG (user_xfpregs structure)"
msgstr ""
-#: readelf.c:9577
+#: readelf.c:10241
msgid "NT_PSTATUS (pstatus structure)"
msgstr ""
-#: readelf.c:9578
+#: readelf.c:10242
msgid "NT_FPREGS (floating point registers)"
msgstr ""
-#: readelf.c:9579
+#: readelf.c:10243
msgid "NT_PSINFO (psinfo structure)"
msgstr ""
-#: readelf.c:9580
+#: readelf.c:10244
msgid "NT_LWPSTATUS (lwpstatus_t structure)"
msgstr ""
-#: readelf.c:9581
+#: readelf.c:10245
msgid "NT_LWPSINFO (lwpsinfo_t structure)"
msgstr ""
-#: readelf.c:9582
+#: readelf.c:10246
msgid "NT_WIN32PSTATUS (win32_pstatus structure)"
msgstr ""
-#: readelf.c:9584 readelf.c:9608
+#: readelf.c:10248 readelf.c:10272
#, c-format
msgid "Unknown note type: (0x%08x)"
msgstr ""
#. NetBSD core "procinfo" structure.
-#: readelf.c:9598
+#: readelf.c:10262
msgid "NetBSD procinfo structure"
msgstr ""
-#: readelf.c:9625 readelf.c:9639
+#: readelf.c:10289 readelf.c:10303
msgid "PT_GETREGS (reg structure)"
msgstr ""
-#: readelf.c:9627 readelf.c:9641
+#: readelf.c:10291 readelf.c:10305
msgid "PT_GETFPREGS (fpreg structure)"
msgstr ""
-#: readelf.c:9647
+#: readelf.c:10311
#, c-format
msgid "PT_FIRSTMACH+%d"
msgstr ""
-#: readelf.c:9701
+#: readelf.c:10365
msgid "notes"
msgstr ""
-#: readelf.c:9707
+#: readelf.c:10371
#, c-format
msgid ""
"\n"
"Notes at offset 0x%08lx with length 0x%08lx:\n"
msgstr ""
-#: readelf.c:9709
+#: readelf.c:10373
msgid " Owner\t\tData size\tDescription\n"
msgstr ""
-#: readelf.c:9728
+#: readelf.c:10392
#, c-format
msgid "corrupt note found at offset %x into core notes\n"
msgstr ""
-#: readelf.c:9730
+#: readelf.c:10394
#, c-format
msgid " type: %x, namesize: %08lx, descsize: %08lx\n"
msgstr ""
-#: readelf.c:9832
+#: readelf.c:10476
msgid "No note segments present in the core file.\n"
msgstr ""
-#: readelf.c:9910
+#: readelf.c:10560
msgid ""
"This instance of readelf has been built without support for a\n"
"64 bit data type and so it cannot read 64 bit ELF files.\n"
msgstr ""
-#: readelf.c:9956
+#: readelf.c:10606
#, c-format
msgid "Cannot stat input file %s.\n"
msgstr ""
-#: readelf.c:9963
+#: readelf.c:10613
#, c-format
msgid "Input file %s not found.\n"
msgstr ""
-#: readelf.c:9969
+#: readelf.c:10619
#, c-format
msgid "%s: Failed to read file header\n"
msgstr ""
-#: readelf.c:9983
+#: readelf.c:10633
#, c-format
msgid ""
"\n"
"File: %s\n"
msgstr ""
-#: rename.c:131
+#: rename.c:132
#, c-format
msgid "%s: cannot set time: %s"
msgstr ""
#. We have to clean up here.
-#: rename.c:170 rename.c:203
+#: rename.c:171 rename.c:204
#, c-format
msgid "%s: rename: %s"
msgstr ""
-#: rename.c:211
+#: rename.c:212
#, c-format
msgid "%s: simple_copy: %s"
msgstr ""
@@ -4182,7 +4220,7 @@ msgstr ""
msgid "%s: read of %lu returned %lu"
msgstr ""
-#: resrc.c:650 resrc.c:904 resrc.c:1177 resrc.c:1331
+#: resrc.c:650 resrc.c:905 resrc.c:1178 resrc.c:1332
#, c-format
msgid "stat failed on bitmap file `%s': %s"
msgstr ""
@@ -4192,25 +4230,25 @@ msgstr ""
msgid "cursor file `%s' does not contain cursor data"
msgstr ""
-#: resrc.c:735 resrc.c:1048
+#: resrc.c:735 resrc.c:1049
#, c-format
msgid "%s: fseek to %lu failed: %s"
msgstr ""
-#: resrc.c:872
+#: resrc.c:873
msgid "help ID requires DIALOGEX"
msgstr ""
-#: resrc.c:874
+#: resrc.c:875
msgid "control data requires DIALOGEX"
msgstr ""
-#: resrc.c:1017
+#: resrc.c:1018
#, c-format
msgid "icon file `%s' does not contain icon data"
msgstr ""
-#: resrc.c:1536
+#: resrc.c:1537
#, c-format
msgid "can't open `%s' for output: %s"
msgstr ""
@@ -4228,7 +4266,7 @@ msgstr ""
msgid ""
" The options are:\n"
" -A|-B --format={sysv|berkeley} Select output style (default is %s)\n"
-" -o|-d|-h --radix={8|10|16} Display numbers in octal, decimal or "
+" -o|-d|-x --radix={8|10|16} Display numbers in octal, decimal or "
"hex\n"
" -t --totals Display the total sizes (Berkeley "
"only)\n"
@@ -4267,88 +4305,88 @@ msgstr ""
msgid "unable to open output file %s"
msgstr ""
-#: stabs.c:343 stabs.c:1759
+#: stabs.c:346 stabs.c:1755
msgid "numeric overflow"
msgstr ""
-#: stabs.c:354
+#: stabs.c:357
#, c-format
msgid "Bad stab: %s\n"
msgstr ""
-#: stabs.c:364
+#: stabs.c:367
#, c-format
msgid "Warning: %s: %s\n"
msgstr ""
-#: stabs.c:485
+#: stabs.c:488
msgid "N_LBRAC not within function\n"
msgstr ""
-#: stabs.c:524
+#: stabs.c:527
msgid "Too many N_RBRACs\n"
msgstr ""
-#: stabs.c:769
+#: stabs.c:773
msgid "unknown C++ encoded name"
msgstr ""
#. Complain and keep going, so compilers can invent new
#. cross-reference types.
-#: stabs.c:1296
+#: stabs.c:1293
msgid "unrecognized cross reference type"
msgstr ""
#. Does this actually ever happen? Is that why we are worrying
#. about dealing with it rather than just calling error_type?
-#: stabs.c:1851
+#: stabs.c:1847
msgid "missing index type"
msgstr ""
-#: stabs.c:2178
+#: stabs.c:2174
msgid "unknown virtual character for baseclass"
msgstr ""
-#: stabs.c:2196
+#: stabs.c:2192
msgid "unknown visibility character for baseclass"
msgstr ""
-#: stabs.c:2388
+#: stabs.c:2384
msgid "unnamed $vb type"
msgstr ""
-#: stabs.c:2394
+#: stabs.c:2390
msgid "unrecognized C++ abbreviation"
msgstr ""
-#: stabs.c:2474
+#: stabs.c:2470
msgid "unknown visibility character for field"
msgstr ""
-#: stabs.c:2730
+#: stabs.c:2726
msgid "const/volatile indicator missing"
msgstr ""
-#: stabs.c:2970
+#: stabs.c:2967
#, c-format
msgid "No mangling for \"%s\"\n"
msgstr ""
-#: stabs.c:3283
+#: stabs.c:3281
msgid "Undefined N_EXCL"
msgstr ""
-#: stabs.c:3371
+#: stabs.c:3369
#, c-format
msgid "Type file number %d out of range\n"
msgstr ""
-#: stabs.c:3376
+#: stabs.c:3374
#, c-format
msgid "Type index number %d out of range\n"
msgstr ""
-#: stabs.c:3463
+#: stabs.c:3461
#, c-format
msgid "Unrecognized XCOFF type %d\n"
msgstr ""
@@ -4358,25 +4396,25 @@ msgstr ""
msgid "bad mangled name `%s'\n"
msgstr ""
-#: stabs.c:3858
+#: stabs.c:3859
msgid "no argument types in mangled string\n"
msgstr ""
-#: strings.c:200
+#: strings.c:208
#, c-format
msgid "invalid number %s"
msgstr ""
-#: strings.c:640
+#: strings.c:647
#, c-format
msgid "invalid integer argument %s"
msgstr ""
-#: strings.c:651
+#: strings.c:658
msgid " Display printable strings in [file(s)] (stdin by default)\n"
msgstr ""
-#: strings.c:652
+#: strings.c:659
msgid ""
" The options are:\n"
" -a - --all Scan the entire file, not just the data section\n"
@@ -4388,8 +4426,9 @@ msgid ""
"or 16\n"
" -o An alias for --radix=o\n"
" -T --target=<BFDNAME> Specify the binary file format\n"
-" -e --encoding={s,b,l,B,L} Select character size and endianness:\n"
-" s = 8-bit, {b,l} = 16-bit, {B,L} = 32-bit\n"
+" -e --encoding={s,S,b,l,B,L} Select character size and endianness:\n"
+" s = 7-bit, S = 8-bit, {b,l} = 16-bit, {B,L} = 32-"
+"bit\n"
" -h --help Display this information\n"
" -v --version Print the program's version number\n"
msgstr ""
@@ -4410,110 +4449,126 @@ msgstr ""
msgid "cannot open input file %s"
msgstr ""
-#: version.c:35
+#: version.c:36
msgid "Copyright 2002 Free Software Foundation, Inc.\n"
msgstr ""
-#: version.c:36
+#: version.c:37
msgid ""
"This program is free software; you may redistribute it under the terms of\n"
"the GNU General Public License. This program has absolutely no warranty.\n"
msgstr ""
-#: windres.c:239
+#: windres.c:205
#, c-format
msgid "can't open %s `%s': %s"
msgstr ""
-#: windres.c:418
+#: windres.c:384
msgid ": expected to be a directory\n"
msgstr ""
-#: windres.c:430
+#: windres.c:396
msgid ": expected to be a leaf\n"
msgstr ""
-#: windres.c:439
+#: windres.c:405
#, c-format
msgid "%s: warning: "
msgstr ""
-#: windres.c:441
+#: windres.c:407
msgid ": duplicate value\n"
msgstr ""
-#: windres.c:602
+#: windres.c:569
#, c-format
msgid "unknown format type `%s'"
msgstr ""
-#: windres.c:603
+#: windres.c:570
#, c-format
msgid "%s: supported formats:"
msgstr ""
#. Otherwise, we give up.
-#: windres.c:688
+#: windres.c:655
#, c-format
msgid "can not determine type of file `%s'; use the -I option"
msgstr ""
-#: windres.c:702
+#: windres.c:669
#, c-format
msgid "Usage: %s [option(s)] [input-file] [output-file]\n"
msgstr ""
-#: windres.c:704
+#: windres.c:671
msgid ""
" The options are:\n"
" -i --input=<file> Name input file\n"
" -o --output=<file> Name output file\n"
-" -I --input-format=<format> Specify input format\n"
+" -J --input-format=<format> Specify input format\n"
" -O --output-format=<format> Specify output format\n"
" -F --target=<target> Specify COFF target\n"
" --preprocessor=<program> Program to use to preprocess rc file\n"
-" --include-dir=<dir> Include directory when preprocessing rc file\n"
+" -I --include-dir=<dir> Include directory when preprocessing rc file\n"
" -D --define <sym>[=<val>] Define SYM when preprocessing rc file\n"
+" -U --undefine <sym> Undefine SYM when preprocessing rc file\n"
" -v --verbose Verbose - tells you what it's doing\n"
-" --language=<val> Set language when reading rc file\n"
+" -l --language=<val> Set language when reading rc file\n"
" --use-temp-file Use a temporary file instead of popen to "
"read\n"
" the preprocessor output\n"
" --no-use-temp-file Use popen (default)\n"
msgstr ""
-#: windres.c:719
+#: windres.c:687
msgid " --yydebug Turn on parser debugging\n"
msgstr ""
-#: windres.c:722
+#: windres.c:690
msgid ""
+" -r Ignored for compatibility with rc\n"
" -h --help Print this help message\n"
" -V --version Print version information\n"
msgstr ""
-#: windres.c:725
+#: windres.c:694
msgid ""
"FORMAT is one of rc, res, or coff, and is deduced from the file name\n"
"extension if not specified. A single file name is an input file.\n"
"No input-file is stdin, default rc. No output-file is stdout, default rc.\n"
msgstr ""
-#: windres.c:988
+#: windres.c:833
+msgid "invalid option -f\n"
+msgstr ""
+
+#: windres.c:838
+msgid "No filename following the -fo option.\n"
+msgstr ""
+
+#: windres.c:896
+msgid ""
+"Option -I is deprecated for setting the input format, please use -J "
+"instead.\n"
+msgstr ""
+
+#: windres.c:1014
msgid "no resources"
msgstr ""
-#: wrstabs.c:366 wrstabs.c:2026
+#: wrstabs.c:395 wrstabs.c:2055
#, c-format
msgid "string_hash_lookup failed: %s"
msgstr ""
-#: wrstabs.c:666
+#: wrstabs.c:695
#, c-format
msgid "stab_int_type: bad size %u"
msgstr ""
-#: wrstabs.c:1466
+#: wrstabs.c:1495
#, c-format
msgid "%s: warning: unknown size for field `%s' in struct"
msgstr ""
diff --git a/contrib/binutils/binutils/prdbg.c b/contrib/binutils/binutils/prdbg.c
index 8bb0053..5b6b047 100644
--- a/contrib/binutils/binutils/prdbg.c
+++ b/contrib/binutils/binutils/prdbg.c
@@ -1,6 +1,7 @@
/* prdbg.c -- Print out generic debugging information.
- Copyright 1995, 1996 Free Software Foundation, Inc.
+ Copyright 1995, 1996, 2002, 2003 Free Software Foundation, Inc.
Written by Ian Lance Taylor <ian@cygnus.com>.
+ Tags style generation written by Salvador E. Tropea <set@computer.org>.
This file is part of GNU Binutils.
@@ -43,6 +44,15 @@ struct pr_handle
struct pr_stack *stack;
/* Parameter number we are about to output. */
int parameter;
+ /* The following are used only by the tags code (tg_). */
+ /* Name of the file we are using. */
+ char *filename;
+ /* The BFD. */
+ bfd *abfd;
+ /* The symbols table for this BFD. */
+ asymbol **syms;
+ /* Pointer to a function to demangle symbols. */
+ char *(*demangler) (bfd *, const char *);
};
/* The type stack. */
@@ -57,78 +67,131 @@ struct pr_stack
enum debug_visibility visibility;
/* Name of the current method we are handling. */
const char *method;
+ /* The following are used only by the tags code (tg_). */
+ /* Type for the container (struct, union, class, union class). */
+ const char *flavor;
+ /* A comma separated list of parent classes. */
+ char *parents;
+ /* How many parents contains parents. */
+ int num_parents;
};
-static void indent PARAMS ((struct pr_handle *));
-static boolean push_type PARAMS ((struct pr_handle *, const char *));
-static boolean prepend_type PARAMS ((struct pr_handle *, const char *));
-static boolean append_type PARAMS ((struct pr_handle *, const char *));
-static boolean substitute_type PARAMS ((struct pr_handle *, const char *));
-static boolean indent_type PARAMS ((struct pr_handle *));
-static char *pop_type PARAMS ((struct pr_handle *));
-static void print_vma PARAMS ((bfd_vma, char *, boolean, boolean));
-static boolean pr_fix_visibility
- PARAMS ((struct pr_handle *, enum debug_visibility));
-
-static boolean pr_start_compilation_unit PARAMS ((PTR, const char *));
-static boolean pr_start_source PARAMS ((PTR, const char *));
-static boolean pr_empty_type PARAMS ((PTR));
-static boolean pr_void_type PARAMS ((PTR));
-static boolean pr_int_type PARAMS ((PTR, unsigned int, boolean));
-static boolean pr_float_type PARAMS ((PTR, unsigned int));
-static boolean pr_complex_type PARAMS ((PTR, unsigned int));
-static boolean pr_bool_type PARAMS ((PTR, unsigned int));
-static boolean pr_enum_type
- PARAMS ((PTR, const char *, const char **, bfd_signed_vma *));
-static boolean pr_pointer_type PARAMS ((PTR));
-static boolean pr_function_type PARAMS ((PTR, int, boolean));
-static boolean pr_reference_type PARAMS ((PTR));
-static boolean pr_range_type PARAMS ((PTR, bfd_signed_vma, bfd_signed_vma));
-static boolean pr_array_type
- PARAMS ((PTR, bfd_signed_vma, bfd_signed_vma, boolean));
-static boolean pr_set_type PARAMS ((PTR, boolean));
-static boolean pr_offset_type PARAMS ((PTR));
-static boolean pr_method_type PARAMS ((PTR, boolean, int, boolean));
-static boolean pr_const_type PARAMS ((PTR));
-static boolean pr_volatile_type PARAMS ((PTR));
-static boolean pr_start_struct_type
- PARAMS ((PTR, const char *, unsigned int, boolean, unsigned int));
-static boolean pr_struct_field
- PARAMS ((PTR, const char *, bfd_vma, bfd_vma, enum debug_visibility));
-static boolean pr_end_struct_type PARAMS ((PTR));
-static boolean pr_start_class_type
- PARAMS ((PTR, const char *, unsigned int, boolean, unsigned int, boolean,
- boolean));
-static boolean pr_class_static_member
- PARAMS ((PTR, const char *, const char *, enum debug_visibility));
-static boolean pr_class_baseclass
- PARAMS ((PTR, bfd_vma, boolean, enum debug_visibility));
-static boolean pr_class_start_method PARAMS ((PTR, const char *));
-static boolean pr_class_method_variant
- PARAMS ((PTR, const char *, enum debug_visibility, boolean, boolean,
- bfd_vma, boolean));
-static boolean pr_class_static_method_variant
- PARAMS ((PTR, const char *, enum debug_visibility, boolean, boolean));
-static boolean pr_class_end_method PARAMS ((PTR));
-static boolean pr_end_class_type PARAMS ((PTR));
-static boolean pr_typedef_type PARAMS ((PTR, const char *));
-static boolean pr_tag_type
- PARAMS ((PTR, const char *, unsigned int, enum debug_type_kind));
-static boolean pr_typdef PARAMS ((PTR, const char *));
-static boolean pr_tag PARAMS ((PTR, const char *));
-static boolean pr_int_constant PARAMS ((PTR, const char *, bfd_vma));
-static boolean pr_float_constant PARAMS ((PTR, const char *, double));
-static boolean pr_typed_constant PARAMS ((PTR, const char *, bfd_vma));
-static boolean pr_variable
- PARAMS ((PTR, const char *, enum debug_var_kind, bfd_vma));
-static boolean pr_start_function PARAMS ((PTR, const char *, boolean));
-static boolean pr_function_parameter
- PARAMS ((PTR, const char *, enum debug_parm_kind, bfd_vma));
-static boolean pr_start_block PARAMS ((PTR, bfd_vma));
-static boolean pr_end_block PARAMS ((PTR, bfd_vma));
-static boolean pr_end_function PARAMS ((PTR));
-static boolean pr_lineno PARAMS ((PTR, const char *, unsigned long, bfd_vma));
-
+static void indent (struct pr_handle *);
+static bfd_boolean push_type (struct pr_handle *, const char *);
+static bfd_boolean prepend_type (struct pr_handle *, const char *);
+static bfd_boolean append_type (struct pr_handle *, const char *);
+static bfd_boolean substitute_type (struct pr_handle *, const char *);
+static bfd_boolean indent_type (struct pr_handle *);
+static char *pop_type (struct pr_handle *);
+static void print_vma (bfd_vma, char *, bfd_boolean, bfd_boolean);
+static bfd_boolean pr_fix_visibility
+ (struct pr_handle *, enum debug_visibility);
+static bfd_boolean pr_start_compilation_unit (void *, const char *);
+static bfd_boolean pr_start_source (void *, const char *);
+static bfd_boolean pr_empty_type (void *);
+static bfd_boolean pr_void_type (void *);
+static bfd_boolean pr_int_type (void *, unsigned int, bfd_boolean);
+static bfd_boolean pr_float_type (void *, unsigned int);
+static bfd_boolean pr_complex_type (void *, unsigned int);
+static bfd_boolean pr_bool_type (void *, unsigned int);
+static bfd_boolean pr_enum_type
+ (void *, const char *, const char **, bfd_signed_vma *);
+static bfd_boolean pr_pointer_type (void *);
+static bfd_boolean pr_function_type (void *, int, bfd_boolean);
+static bfd_boolean pr_reference_type (void *);
+static bfd_boolean pr_range_type (void *, bfd_signed_vma, bfd_signed_vma);
+static bfd_boolean pr_array_type
+ (void *, bfd_signed_vma, bfd_signed_vma, bfd_boolean);
+static bfd_boolean pr_set_type (void *, bfd_boolean);
+static bfd_boolean pr_offset_type (void *);
+static bfd_boolean pr_method_type (void *, bfd_boolean, int, bfd_boolean);
+static bfd_boolean pr_const_type (void *);
+static bfd_boolean pr_volatile_type (void *);
+static bfd_boolean pr_start_struct_type
+ (void *, const char *, unsigned int, bfd_boolean, unsigned int);
+static bfd_boolean pr_struct_field
+ (void *, const char *, bfd_vma, bfd_vma, enum debug_visibility);
+static bfd_boolean pr_end_struct_type (void *);
+static bfd_boolean pr_start_class_type
+ (void *, const char *, unsigned int, bfd_boolean, unsigned int,
+ bfd_boolean, bfd_boolean);
+static bfd_boolean pr_class_static_member
+ (void *, const char *, const char *, enum debug_visibility);
+static bfd_boolean pr_class_baseclass
+ (void *, bfd_vma, bfd_boolean, enum debug_visibility);
+static bfd_boolean pr_class_start_method (void *, const char *);
+static bfd_boolean pr_class_method_variant
+ (void *, const char *, enum debug_visibility, bfd_boolean, bfd_boolean,
+ bfd_vma, bfd_boolean);
+static bfd_boolean pr_class_static_method_variant
+ (void *, const char *, enum debug_visibility, bfd_boolean, bfd_boolean);
+static bfd_boolean pr_class_end_method (void *);
+static bfd_boolean pr_end_class_type (void *);
+static bfd_boolean pr_typedef_type (void *, const char *);
+static bfd_boolean pr_tag_type
+ (void *, const char *, unsigned int, enum debug_type_kind);
+static bfd_boolean pr_typdef (void *, const char *);
+static bfd_boolean pr_tag (void *, const char *);
+static bfd_boolean pr_int_constant (void *, const char *, bfd_vma);
+static bfd_boolean pr_float_constant (void *, const char *, double);
+static bfd_boolean pr_typed_constant (void *, const char *, bfd_vma);
+static bfd_boolean pr_variable
+ (void *, const char *, enum debug_var_kind, bfd_vma);
+static bfd_boolean pr_start_function (void *, const char *, bfd_boolean);
+static bfd_boolean pr_function_parameter
+ (void *, const char *, enum debug_parm_kind, bfd_vma);
+static bfd_boolean pr_start_block (void *, bfd_vma);
+static bfd_boolean pr_end_block (void *, bfd_vma);
+static bfd_boolean pr_end_function (void *);
+static bfd_boolean pr_lineno (void *, const char *, unsigned long, bfd_vma);
+static bfd_boolean append_parent (struct pr_handle *, const char *);
+/* Only used by tg_ code. */
+static bfd_boolean tg_fix_visibility
+ (struct pr_handle *, enum debug_visibility);
+static void find_address_in_section (bfd *, asection *, void *);
+static void translate_addresses (bfd *, char *, FILE *, asymbol **);
+static const char *visibility_name (enum debug_visibility);
+/* Tags style replacements. */
+static bfd_boolean tg_start_compilation_unit (void *, const char *);
+static bfd_boolean tg_start_source (void *, const char *);
+static bfd_boolean tg_enum_type
+ (void *, const char *, const char **, bfd_signed_vma *);
+static bfd_boolean tg_start_struct_type
+ (void *, const char *, unsigned int, bfd_boolean, unsigned int);
+static bfd_boolean pr_struct_field
+ (void *, const char *, bfd_vma, bfd_vma, enum debug_visibility);
+static bfd_boolean tg_struct_field
+ (void *, const char *, bfd_vma, bfd_vma, enum debug_visibility);
+static bfd_boolean tg_struct_field
+ (void *, const char *, bfd_vma, bfd_vma, enum debug_visibility);
+static bfd_boolean tg_end_struct_type (void *);
+static bfd_boolean tg_start_class_type
+ (void *, const char *, unsigned int, bfd_boolean, unsigned int, bfd_boolean, bfd_boolean);
+static bfd_boolean tg_class_static_member
+ (void *, const char *, const char *, enum debug_visibility);
+static bfd_boolean tg_class_baseclass
+ (void *, bfd_vma, bfd_boolean, enum debug_visibility);
+static bfd_boolean tg_class_method_variant
+ (void *, const char *, enum debug_visibility, bfd_boolean, bfd_boolean, bfd_vma, bfd_boolean);
+static bfd_boolean tg_class_static_method_variant
+ (void *, const char *, enum debug_visibility, bfd_boolean, bfd_boolean);
+static bfd_boolean tg_end_class_type (void *);
+static bfd_boolean tg_tag_type
+ (void *, const char *, unsigned int, enum debug_type_kind);
+static bfd_boolean tg_typdef (void *, const char *);
+static bfd_boolean tg_tag (void *, const char *);
+static bfd_boolean tg_int_constant (void *, const char *, bfd_vma);
+static bfd_boolean tg_float_constant (void *, const char *, double);
+static bfd_boolean tg_typed_constant (void *, const char *, bfd_vma);
+static bfd_boolean tg_variable
+ (void *, const char *, enum debug_var_kind, bfd_vma);
+static bfd_boolean tg_start_function (void *, const char *, bfd_boolean);
+static bfd_boolean tg_function_parameter
+ (void *, const char *, enum debug_parm_kind, bfd_vma);
+static bfd_boolean tg_start_block (void *, bfd_vma);
+static bfd_boolean tg_end_block (void *, bfd_vma);
+static bfd_boolean tg_lineno (void *, const char *, unsigned long, bfd_vma);
+
static const struct debug_write_fns pr_fns =
{
pr_start_compilation_unit,
@@ -177,12 +240,59 @@ static const struct debug_write_fns pr_fns =
pr_lineno
};
+static const struct debug_write_fns tg_fns =
+{
+ tg_start_compilation_unit,
+ tg_start_source,
+ pr_empty_type, /* Same, push_type. */
+ pr_void_type, /* Same, push_type. */
+ pr_int_type, /* Same, push_type. */
+ pr_float_type, /* Same, push_type. */
+ pr_complex_type, /* Same, push_type. */
+ pr_bool_type, /* Same, push_type. */
+ tg_enum_type,
+ pr_pointer_type, /* Same, changes to pointer. */
+ pr_function_type, /* Same, push_type. */
+ pr_reference_type, /* Same, changes to reference. */
+ pr_range_type, /* FIXME: What's that?. */
+ pr_array_type, /* Same, push_type. */
+ pr_set_type, /* FIXME: What's that?. */
+ pr_offset_type, /* FIXME: What's that?. */
+ pr_method_type, /* Same. */
+ pr_const_type, /* Same, changes to const. */
+ pr_volatile_type, /* Same, changes to volatile. */
+ tg_start_struct_type,
+ tg_struct_field,
+ tg_end_struct_type,
+ tg_start_class_type,
+ tg_class_static_member,
+ tg_class_baseclass,
+ pr_class_start_method, /* Same, remembers that's a method. */
+ tg_class_method_variant,
+ tg_class_static_method_variant,
+ pr_class_end_method, /* Same, forgets that's a method. */
+ tg_end_class_type,
+ pr_typedef_type, /* Same, just push type. */
+ tg_tag_type,
+ tg_typdef,
+ tg_tag,
+ tg_int_constant, /* Untested. */
+ tg_float_constant, /* Untested. */
+ tg_typed_constant, /* Untested. */
+ tg_variable,
+ tg_start_function,
+ tg_function_parameter,
+ tg_start_block,
+ tg_end_block,
+ pr_end_function, /* Same, does nothing. */
+ tg_lineno
+};
+
/* Print out the generic debugging information recorded in dhandle. */
-boolean
-print_debugging_info (f, dhandle)
- FILE *f;
- PTR dhandle;
+bfd_boolean
+print_debugging_info (FILE *f, void *dhandle, bfd *abfd, asymbol **syms,
+ void *demangler, bfd_boolean as_tags)
{
struct pr_handle info;
@@ -190,15 +300,27 @@ print_debugging_info (f, dhandle)
info.indent = 0;
info.stack = NULL;
info.parameter = 0;
+ info.filename = NULL;
+ info.abfd = abfd;
+ info.syms = syms;
+ info.demangler = demangler;
- return debug_write (dhandle, &pr_fns, (PTR) &info);
+ if (as_tags)
+ {
+ fputs ("!_TAG_FILE_FORMAT\t2\t/extended format/\n", f);
+ fputs ("!_TAG_FILE_SORTED\t0\t/0=unsorted, 1=sorted/\n", f);
+ fputs ("!_TAG_PROGRAM_AUTHOR\tIan Lance Taylor, Salvador E. Tropea and others\t//\n", f);
+ fputs ("!_TAG_PROGRAM_NAME\tobjdump\t/From GNU binutils/\n", f);
+ }
+
+ return as_tags ? debug_write (dhandle, &tg_fns, (void *) & info)
+ : debug_write (dhandle, &pr_fns, (void *) & info);
}
/* Indent to the current indentation level. */
static void
-indent (info)
- struct pr_handle *info;
+indent (struct pr_handle *info)
{
unsigned int i;
@@ -208,15 +330,13 @@ indent (info)
/* Push a type on the type stack. */
-static boolean
-push_type (info, type)
- struct pr_handle *info;
- const char *type;
+static bfd_boolean
+push_type (struct pr_handle *info, const char *type)
{
struct pr_stack *n;
if (type == NULL)
- return false;
+ return FALSE;
n = (struct pr_stack *) xmalloc (sizeof *n);
memset (n, 0, sizeof *n);
@@ -227,15 +347,13 @@ push_type (info, type)
n->next = info->stack;
info->stack = n;
- return true;
+ return TRUE;
}
/* Prepend a string onto the type on the top of the type stack. */
-static boolean
-prepend_type (info, s)
- struct pr_handle *info;
- const char *s;
+static bfd_boolean
+prepend_type (struct pr_handle *info, const char *s)
{
char *n;
@@ -246,20 +364,18 @@ prepend_type (info, s)
free (info->stack->type);
info->stack->type = n;
- return true;
+ return TRUE;
}
/* Append a string to the type on the top of the type stack. */
-static boolean
-append_type (info, s)
- struct pr_handle *info;
- const char *s;
+static bfd_boolean
+append_type (struct pr_handle *info, const char *s)
{
unsigned int len;
if (s == NULL)
- return false;
+ return FALSE;
assert (info->stack != NULL);
@@ -268,17 +384,35 @@ append_type (info, s)
len + strlen (s) + 1);
strcpy (info->stack->type + len, s);
- return true;
+ return TRUE;
+}
+
+/* Append a string to the parents on the top of the type stack. */
+
+static bfd_boolean
+append_parent (struct pr_handle *info, const char *s)
+{
+ unsigned int len;
+
+ if (s == NULL)
+ return FALSE;
+
+ assert (info->stack != NULL);
+
+ len = info->stack->parents ? strlen (info->stack->parents) : 0;
+ info->stack->parents = (char *) xrealloc (info->stack->parents,
+ len + strlen (s) + 1);
+ strcpy (info->stack->parents + len, s);
+
+ return TRUE;
}
/* We use an underscore to indicate where the name should go in a type
string. This function substitutes a string for the underscore. If
there is no underscore, the name follows the type. */
-static boolean
-substitute_type (info, s)
- struct pr_handle *info;
- const char *s;
+static bfd_boolean
+substitute_type (struct pr_handle *info, const char *s)
{
char *u;
@@ -298,7 +432,7 @@ substitute_type (info, s)
free (info->stack->type);
info->stack->type = n;
- return true;
+ return TRUE;
}
if (strchr (s, '|') != NULL
@@ -307,11 +441,11 @@ substitute_type (info, s)
{
if (! prepend_type (info, "(")
|| ! append_type (info, ")"))
- return false;
+ return FALSE;
}
if (*s == '\0')
- return true;
+ return TRUE;
return (append_type (info, " ")
&& append_type (info, s));
@@ -319,26 +453,24 @@ substitute_type (info, s)
/* Indent the type at the top of the stack by appending spaces. */
-static boolean
-indent_type (info)
- struct pr_handle *info;
+static bfd_boolean
+indent_type (struct pr_handle *info)
{
unsigned int i;
for (i = 0; i < info->indent; i++)
{
if (! append_type (info, " "))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Pop a type from the type stack. */
static char *
-pop_type (info)
- struct pr_handle *info;
+pop_type (struct pr_handle *info)
{
struct pr_stack *o;
char *ret;
@@ -356,11 +488,7 @@ pop_type (info)
/* Print a VMA value into a string. */
static void
-print_vma (vma, buf, unsignedp, hexp)
- bfd_vma vma;
- char *buf;
- boolean unsignedp;
- boolean hexp;
+print_vma (bfd_vma vma, char *buf, bfd_boolean unsignedp, bfd_boolean hexp)
{
if (sizeof (vma) <= sizeof (unsigned long))
{
@@ -381,10 +509,8 @@ print_vma (vma, buf, unsignedp, hexp)
/* Start a new compilation unit. */
-static boolean
-pr_start_compilation_unit (p, filename)
- PTR p;
- const char *filename;
+static bfd_boolean
+pr_start_compilation_unit (void *p, const char *filename)
{
struct pr_handle *info = (struct pr_handle *) p;
@@ -392,15 +518,13 @@ pr_start_compilation_unit (p, filename)
fprintf (info->f, "%s:\n", filename);
- return true;
+ return TRUE;
}
/* Start a source file within a compilation unit. */
-static boolean
-pr_start_source (p, filename)
- PTR p;
- const char *filename;
+static bfd_boolean
+pr_start_source (void *p, const char *filename)
{
struct pr_handle *info = (struct pr_handle *) p;
@@ -408,14 +532,13 @@ pr_start_source (p, filename)
fprintf (info->f, " %s:\n", filename);
- return true;
+ return TRUE;
}
/* Push an empty type onto the type stack. */
-static boolean
-pr_empty_type (p)
- PTR p;
+static bfd_boolean
+pr_empty_type (void *p)
{
struct pr_handle *info = (struct pr_handle *) p;
@@ -424,9 +547,8 @@ pr_empty_type (p)
/* Push a void type onto the type stack. */
-static boolean
-pr_void_type (p)
- PTR p;
+static bfd_boolean
+pr_void_type (void *p)
{
struct pr_handle *info = (struct pr_handle *) p;
@@ -435,11 +557,8 @@ pr_void_type (p)
/* Push an integer type onto the type stack. */
-static boolean
-pr_int_type (p, size, unsignedp)
- PTR p;
- unsigned int size;
- boolean unsignedp;
+static bfd_boolean
+pr_int_type (void *p, unsigned int size, bfd_boolean unsignedp)
{
struct pr_handle *info = (struct pr_handle *) p;
char ab[10];
@@ -450,10 +569,8 @@ pr_int_type (p, size, unsignedp)
/* Push a floating type onto the type stack. */
-static boolean
-pr_float_type (p, size)
- PTR p;
- unsigned int size;
+static bfd_boolean
+pr_float_type (void *p, unsigned int size)
{
struct pr_handle *info = (struct pr_handle *) p;
char ab[10];
@@ -469,25 +586,21 @@ pr_float_type (p, size)
/* Push a complex type onto the type stack. */
-static boolean
-pr_complex_type (p, size)
- PTR p;
- unsigned int size;
+static bfd_boolean
+pr_complex_type (void *p, unsigned int size)
{
struct pr_handle *info = (struct pr_handle *) p;
if (! pr_float_type (p, size))
- return false;
+ return FALSE;
return prepend_type (info, "complex ");
}
-/* Push a boolean type onto the type stack. */
+/* Push a bfd_boolean type onto the type stack. */
-static boolean
-pr_bool_type (p, size)
- PTR p;
- unsigned int size;
+static bfd_boolean
+pr_bool_type (void *p, unsigned int size)
{
struct pr_handle *info = (struct pr_handle *) p;
char ab[10];
@@ -499,32 +612,29 @@ pr_bool_type (p, size)
/* Push an enum type onto the type stack. */
-static boolean
-pr_enum_type (p, tag, names, values)
- PTR p;
- const char *tag;
- const char **names;
- bfd_signed_vma *values;
+static bfd_boolean
+pr_enum_type (void *p, const char *tag, const char **names,
+ bfd_signed_vma *values)
{
struct pr_handle *info = (struct pr_handle *) p;
unsigned int i;
bfd_signed_vma val;
if (! push_type (info, "enum "))
- return false;
+ return FALSE;
if (tag != NULL)
{
if (! append_type (info, tag)
|| ! append_type (info, " "))
- return false;
+ return FALSE;
}
if (! append_type (info, "{ "))
- return false;
+ return FALSE;
if (names == NULL)
{
if (! append_type (info, "/* undefined */"))
- return false;
+ return FALSE;
}
else
{
@@ -534,20 +644,20 @@ pr_enum_type (p, tag, names, values)
if (i > 0)
{
if (! append_type (info, ", "))
- return false;
+ return FALSE;
}
if (! append_type (info, names[i]))
- return false;
+ return FALSE;
if (values[i] != val)
{
char ab[20];
- print_vma (values[i], ab, false, false);
+ print_vma (values[i], ab, FALSE, FALSE);
if (! append_type (info, " = ")
|| ! append_type (info, ab))
- return false;
+ return FALSE;
val = values[i];
}
@@ -560,9 +670,8 @@ pr_enum_type (p, tag, names, values)
/* Turn the top type on the stack into a pointer. */
-static boolean
-pr_pointer_type (p)
- PTR p;
+static bfd_boolean
+pr_pointer_type (void *p)
{
struct pr_handle *info = (struct pr_handle *) p;
char *s;
@@ -577,11 +686,8 @@ pr_pointer_type (p)
/* Turn the top type on the stack into a function returning that type. */
-static boolean
-pr_function_type (p, argcount, varargs)
- PTR p;
- int argcount;
- boolean varargs;
+static bfd_boolean
+pr_function_type (void *p, int argcount, bfd_boolean varargs)
{
struct pr_handle *info = (struct pr_handle *) p;
char **arg_types;
@@ -605,10 +711,10 @@ pr_function_type (p, argcount, varargs)
for (i = argcount - 1; i >= 0; i--)
{
if (! substitute_type (info, ""))
- return false;
+ return FALSE;
arg_types[i] = pop_type (info);
if (arg_types[i] == NULL)
- return false;
+ return FALSE;
len += strlen (arg_types[i]) + 2;
}
if (varargs)
@@ -645,18 +751,17 @@ pr_function_type (p, argcount, varargs)
strcat (s, ")");
if (! substitute_type (info, s))
- return false;
+ return FALSE;
free (s);
- return true;
+ return TRUE;
}
/* Turn the top type on the stack into a reference to that type. */
-static boolean
-pr_reference_type (p)
- PTR p;
+static bfd_boolean
+pr_reference_type (void *p)
{
struct pr_handle *info = (struct pr_handle *) p;
@@ -667,11 +772,8 @@ pr_reference_type (p)
/* Make a range type. */
-static boolean
-pr_range_type (p, lower, upper)
- PTR p;
- bfd_signed_vma lower;
- bfd_signed_vma upper;
+static bfd_boolean
+pr_range_type (void *p, bfd_signed_vma lower, bfd_signed_vma upper)
{
struct pr_handle *info = (struct pr_handle *) p;
char abl[20], abu[20];
@@ -679,10 +781,10 @@ pr_range_type (p, lower, upper)
assert (info->stack != NULL);
if (! substitute_type (info, ""))
- return false;
+ return FALSE;
- print_vma (lower, abl, false, false);
- print_vma (upper, abu, false, false);
+ print_vma (lower, abl, FALSE, FALSE);
+ print_vma (upper, abu, FALSE, FALSE);
return (prepend_type (info, "range (")
&& append_type (info, "):")
@@ -693,12 +795,9 @@ pr_range_type (p, lower, upper)
/* Make an array type. */
-static boolean
-pr_array_type (p, lower, upper, stringp)
- PTR p;
- bfd_signed_vma lower;
- bfd_signed_vma upper;
- boolean stringp;
+static bfd_boolean
+pr_array_type (void *p, bfd_signed_vma lower, bfd_signed_vma upper,
+ bfd_boolean stringp)
{
struct pr_handle *info = (struct pr_handle *) p;
char *range_type;
@@ -706,7 +805,7 @@ pr_array_type (p, lower, upper, stringp)
range_type = pop_type (info);
if (range_type == NULL)
- return false;
+ return FALSE;
if (lower == 0)
{
@@ -714,76 +813,73 @@ pr_array_type (p, lower, upper, stringp)
sprintf (ab, "|[]");
else
{
- print_vma (upper + 1, abu, false, false);
+ print_vma (upper + 1, abu, FALSE, FALSE);
sprintf (ab, "|[%s]", abu);
}
}
else
{
- print_vma (lower, abl, false, false);
- print_vma (upper, abu, false, false);
+ print_vma (lower, abl, FALSE, FALSE);
+ print_vma (upper, abu, FALSE, FALSE);
sprintf (ab, "|[%s:%s]", abl, abu);
}
if (! substitute_type (info, ab))
- return false;
+ return FALSE;
if (strcmp (range_type, "int") != 0)
{
if (! append_type (info, ":")
|| ! append_type (info, range_type))
- return false;
+ return FALSE;
}
if (stringp)
{
if (! append_type (info, " /* string */"))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Make a set type. */
-static boolean
-pr_set_type (p, bitstringp)
- PTR p;
- boolean bitstringp;
+static bfd_boolean
+pr_set_type (void *p, bfd_boolean bitstringp)
{
struct pr_handle *info = (struct pr_handle *) p;
if (! substitute_type (info, ""))
- return false;
+ return FALSE;
if (! prepend_type (info, "set { ")
|| ! append_type (info, " }"))
- return false;
+ return FALSE;
if (bitstringp)
{
if (! append_type (info, "/* bitstring */"))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Make an offset type. */
-static boolean
-pr_offset_type (p)
- PTR p;
+static bfd_boolean
+pr_offset_type (void *p)
{
struct pr_handle *info = (struct pr_handle *) p;
char *t;
if (! substitute_type (info, ""))
- return false;
+ return FALSE;
t = pop_type (info);
if (t == NULL)
- return false;
+ return FALSE;
return (substitute_type (info, "")
&& prepend_type (info, " ")
@@ -793,12 +889,8 @@ pr_offset_type (p)
/* Make a method type. */
-static boolean
-pr_method_type (p, domain, argcount, varargs)
- PTR p;
- boolean domain;
- int argcount;
- boolean varargs;
+static bfd_boolean
+pr_method_type (void *p, bfd_boolean domain, int argcount, bfd_boolean varargs)
{
struct pr_handle *info = (struct pr_handle *) p;
unsigned int len;
@@ -813,10 +905,10 @@ pr_method_type (p, domain, argcount, varargs)
else
{
if (! substitute_type (info, ""))
- return false;
+ return FALSE;
domain_type = pop_type (info);
if (domain_type == NULL)
- return false;
+ return FALSE;
if (strncmp (domain_type, "class ", sizeof "class " - 1) == 0
&& strchr (domain_type + sizeof "class " - 1, ' ') == NULL)
domain_type += sizeof "class " - 1;
@@ -841,10 +933,10 @@ pr_method_type (p, domain, argcount, varargs)
for (i = argcount - 1; i >= 0; i--)
{
if (! substitute_type (info, ""))
- return false;
+ return FALSE;
arg_types[i] = pop_type (info);
if (arg_types[i] == NULL)
- return false;
+ return FALSE;
len += strlen (arg_types[i]) + 2;
}
if (varargs)
@@ -885,18 +977,17 @@ pr_method_type (p, domain, argcount, varargs)
strcat (s, ")");
if (! substitute_type (info, s))
- return false;
+ return FALSE;
free (s);
- return true;
+ return TRUE;
}
/* Make a const qualified type. */
-static boolean
-pr_const_type (p)
- PTR p;
+static bfd_boolean
+pr_const_type (void *p)
{
struct pr_handle *info = (struct pr_handle *) p;
@@ -905,9 +996,8 @@ pr_const_type (p)
/* Make a volatile qualified type. */
-static boolean
-pr_volatile_type (p)
- PTR p;
+static bfd_boolean
+pr_volatile_type (void *p)
{
struct pr_handle *info = (struct pr_handle *) p;
@@ -916,24 +1006,20 @@ pr_volatile_type (p)
/* Start accumulating a struct type. */
-static boolean
-pr_start_struct_type (p, tag, id, structp, size)
- PTR p;
- const char *tag;
- unsigned int id;
- boolean structp;
- unsigned int size;
+static bfd_boolean
+pr_start_struct_type (void *p, const char *tag, unsigned int id,
+ bfd_boolean structp, unsigned int size)
{
struct pr_handle *info = (struct pr_handle *) p;
info->indent += 2;
if (! push_type (info, structp ? "struct " : "union "))
- return false;
+ return FALSE;
if (tag != NULL)
{
if (! append_type (info, tag))
- return false;
+ return FALSE;
}
else
{
@@ -941,35 +1027,35 @@ pr_start_struct_type (p, tag, id, structp, size)
sprintf (idbuf, "%%anon%u", id);
if (! append_type (info, idbuf))
- return false;
+ return FALSE;
}
if (! append_type (info, " {"))
- return false;
+ return FALSE;
if (size != 0 || tag != NULL)
{
char ab[30];
if (! append_type (info, " /*"))
- return false;
+ return FALSE;
if (size != 0)
{
sprintf (ab, " size %u", size);
if (! append_type (info, ab))
- return false;
+ return FALSE;
}
if (tag != NULL)
{
sprintf (ab, " id %u", id);
if (! append_type (info, ab))
- return false;
+ return FALSE;
}
if (! append_type (info, " */"))
- return false;
+ return FALSE;
}
if (! append_type (info, "\n"))
- return false;
+ return FALSE;
info->stack->visibility = DEBUG_VISIBILITY_PUBLIC;
@@ -978,10 +1064,8 @@ pr_start_struct_type (p, tag, id, structp, size)
/* Output the visibility of a field in a struct. */
-static boolean
-pr_fix_visibility (info, visibility)
- struct pr_handle *info;
- enum debug_visibility visibility;
+static bfd_boolean
+pr_fix_visibility (struct pr_handle *info, enum debug_visibility visibility)
{
const char *s = NULL;
char *t;
@@ -990,9 +1074,7 @@ pr_fix_visibility (info, visibility)
assert (info->stack != NULL);
if (info->stack->visibility == visibility)
- return true;
-
- assert (info->stack->visibility != DEBUG_VISIBILITY_IGNORE);
+ return TRUE;
switch (visibility)
{
@@ -1010,7 +1092,7 @@ pr_fix_visibility (info, visibility)
break;
default:
abort ();
- return false;
+ return FALSE;
}
/* Trim off a trailing space in the struct string, to make the
@@ -1024,64 +1106,59 @@ pr_fix_visibility (info, visibility)
if (! append_type (info, s)
|| ! append_type (info, ":\n")
|| ! indent_type (info))
- return false;
+ return FALSE;
info->stack->visibility = visibility;
- return true;
+ return TRUE;
}
/* Add a field to a struct type. */
-static boolean
-pr_struct_field (p, name, bitpos, bitsize, visibility)
- PTR p;
- const char *name;
- bfd_vma bitpos;
- bfd_vma bitsize;
- enum debug_visibility visibility;
+static bfd_boolean
+pr_struct_field (void *p, const char *name, bfd_vma bitpos, bfd_vma bitsize,
+ enum debug_visibility visibility)
{
struct pr_handle *info = (struct pr_handle *) p;
char ab[20];
char *t;
if (! substitute_type (info, name))
- return false;
+ return FALSE;
if (! append_type (info, "; /* "))
- return false;
+ return FALSE;
if (bitsize != 0)
{
- print_vma (bitsize, ab, true, false);
+ print_vma (bitsize, ab, TRUE, FALSE);
if (! append_type (info, "bitsize ")
|| ! append_type (info, ab)
|| ! append_type (info, ", "))
- return false;
+ return FALSE;
}
- print_vma (bitpos, ab, true, false);
+ print_vma (bitpos, ab, TRUE, FALSE);
if (! append_type (info, "bitpos ")
|| ! append_type (info, ab)
|| ! append_type (info, " */\n")
|| ! indent_type (info))
- return false;
+ return FALSE;
t = pop_type (info);
if (t == NULL)
- return false;
+ return FALSE;
if (! pr_fix_visibility (info, visibility))
- return false;
+ return FALSE;
return append_type (info, t);
}
/* Finish a struct type. */
-static boolean
-pr_end_struct_type (p)
- PTR p;
+static bfd_boolean
+pr_end_struct_type (void *p)
{
struct pr_handle *info = (struct pr_handle *) p;
char *s;
@@ -1098,20 +1175,15 @@ pr_end_struct_type (p)
*s++ = '}';
*s = '\0';
- return true;
+ return TRUE;
}
/* Start a class type. */
-static boolean
-pr_start_class_type (p, tag, id, structp, size, vptr, ownvptr)
- PTR p;
- const char *tag;
- unsigned int id;
- boolean structp;
- unsigned int size;
- boolean vptr;
- boolean ownvptr;
+static bfd_boolean
+pr_start_class_type (void *p, const char *tag, unsigned int id,
+ bfd_boolean structp, unsigned int size,
+ bfd_boolean vptr, bfd_boolean ownvptr)
{
struct pr_handle *info = (struct pr_handle *) p;
char *tv = NULL;
@@ -1122,15 +1194,15 @@ pr_start_class_type (p, tag, id, structp, size, vptr, ownvptr)
{
tv = pop_type (info);
if (tv == NULL)
- return false;
+ return FALSE;
}
if (! push_type (info, structp ? "class " : "union class "))
- return false;
+ return FALSE;
if (tag != NULL)
{
if (! append_type (info, tag))
- return false;
+ return FALSE;
}
else
{
@@ -1138,15 +1210,15 @@ pr_start_class_type (p, tag, id, structp, size, vptr, ownvptr)
sprintf (idbuf, "%%anon%u", id);
if (! append_type (info, idbuf))
- return false;
+ return FALSE;
}
if (! append_type (info, " {"))
- return false;
+ return FALSE;
if (size != 0 || vptr || ownvptr || tag != NULL)
{
if (! append_type (info, " /*"))
- return false;
+ return FALSE;
if (size != 0)
{
@@ -1155,23 +1227,23 @@ pr_start_class_type (p, tag, id, structp, size, vptr, ownvptr)
sprintf (ab, "%u", size);
if (! append_type (info, " size ")
|| ! append_type (info, ab))
- return false;
+ return FALSE;
}
if (vptr)
{
if (! append_type (info, " vtable "))
- return false;
+ return FALSE;
if (ownvptr)
{
if (! append_type (info, "self "))
- return false;
+ return FALSE;
}
else
{
if (! append_type (info, tv)
|| ! append_type (info, " "))
- return false;
+ return FALSE;
}
}
@@ -1181,11 +1253,11 @@ pr_start_class_type (p, tag, id, structp, size, vptr, ownvptr)
sprintf (ab, " id %u", id);
if (! append_type (info, ab))
- return false;
+ return FALSE;
}
if (! append_type (info, " */"))
- return false;
+ return FALSE;
}
info->stack->visibility = DEBUG_VISIBILITY_PRIVATE;
@@ -1196,44 +1268,38 @@ pr_start_class_type (p, tag, id, structp, size, vptr, ownvptr)
/* Add a static member to a class. */
-static boolean
-pr_class_static_member (p, name, physname, visibility)
- PTR p;
- const char *name;
- const char *physname;
- enum debug_visibility visibility;
+static bfd_boolean
+pr_class_static_member (void *p, const char *name, const char *physname,
+ enum debug_visibility visibility)
{
struct pr_handle *info = (struct pr_handle *) p;
char *t;
if (! substitute_type (info, name))
- return false;
+ return FALSE;
if (! prepend_type (info, "static ")
|| ! append_type (info, "; /* ")
|| ! append_type (info, physname)
|| ! append_type (info, " */\n")
|| ! indent_type (info))
- return false;
+ return FALSE;
t = pop_type (info);
if (t == NULL)
- return false;
+ return FALSE;
if (! pr_fix_visibility (info, visibility))
- return false;
+ return FALSE;
return append_type (info, t);
}
/* Add a base class to a class. */
-static boolean
-pr_class_baseclass (p, bitpos, virtual, visibility)
- PTR p;
- bfd_vma bitpos;
- boolean virtual;
- enum debug_visibility visibility;
+static bfd_boolean
+pr_class_baseclass (void *p, bfd_vma bitpos, bfd_boolean virtual,
+ enum debug_visibility visibility)
{
struct pr_handle *info = (struct pr_handle *) p;
char *t;
@@ -1244,11 +1310,11 @@ pr_class_baseclass (p, bitpos, virtual, visibility)
assert (info->stack != NULL && info->stack->next != NULL);
if (! substitute_type (info, ""))
- return false;
+ return FALSE;
t = pop_type (info);
if (t == NULL)
- return false;
+ return FALSE;
if (strncmp (t, "class ", sizeof "class " - 1) == 0)
t += sizeof "class " - 1;
@@ -1256,12 +1322,12 @@ pr_class_baseclass (p, bitpos, virtual, visibility)
/* Push it back on to take advantage of the prepend_type and
append_type routines. */
if (! push_type (info, t))
- return false;
+ return FALSE;
if (virtual)
{
if (! prepend_type (info, "virtual "))
- return false;
+ return FALSE;
}
switch (visibility)
@@ -1281,15 +1347,15 @@ pr_class_baseclass (p, bitpos, virtual, visibility)
}
if (! prepend_type (info, prefix))
- return false;
+ return FALSE;
if (bitpos != 0)
{
- print_vma (bitpos, ab, true, false);
+ print_vma (bitpos, ab, TRUE, FALSE);
if (! append_type (info, " /* bitpos ")
|| ! append_type (info, ab)
|| ! append_type (info, " */"))
- return false;
+ return FALSE;
}
/* Now the top of the stack is something like "public A / * bitpos
@@ -1306,11 +1372,11 @@ pr_class_baseclass (p, bitpos, virtual, visibility)
if (*l == ':')
break;
if (! prepend_type (info, l == s ? " : " : ", "))
- return false;
+ return FALSE;
t = pop_type (info);
if (t == NULL)
- return false;
+ return FALSE;
n = (char *) xmalloc (strlen (info->stack->type) + strlen (t) + 1);
memcpy (n, info->stack->type, s - info->stack->type);
@@ -1322,35 +1388,28 @@ pr_class_baseclass (p, bitpos, virtual, visibility)
free (t);
- return true;
+ return TRUE;
}
/* Start adding a method to a class. */
-static boolean
-pr_class_start_method (p, name)
- PTR p;
- const char *name;
+static bfd_boolean
+pr_class_start_method (void *p, const char *name)
{
struct pr_handle *info = (struct pr_handle *) p;
assert (info->stack != NULL);
info->stack->method = name;
- return true;
+ return TRUE;
}
/* Add a variant to a method. */
-static boolean
-pr_class_method_variant (p, physname, visibility, constp, volatilep, voffset,
- context)
- PTR p;
- const char *physname;
- enum debug_visibility visibility;
- boolean constp;
- boolean volatilep;
- bfd_vma voffset;
- boolean context;
+static bfd_boolean
+pr_class_method_variant (void *p, const char *physname,
+ enum debug_visibility visibility,
+ bfd_boolean constp, bfd_boolean volatilep,
+ bfd_vma voffset, bfd_boolean context)
{
struct pr_handle *info = (struct pr_handle *) p;
char *method_type;
@@ -1363,12 +1422,12 @@ pr_class_method_variant (p, physname, visibility, constp, volatilep, voffset,
if (volatilep)
{
if (! append_type (info, " volatile"))
- return false;
+ return FALSE;
}
if (constp)
{
if (! append_type (info, " const"))
- return false;
+ return FALSE;
}
/* Stick the name of the method into its type. */
@@ -1376,12 +1435,12 @@ pr_class_method_variant (p, physname, visibility, constp, volatilep, voffset,
(context
? info->stack->next->next->method
: info->stack->next->method)))
- return false;
+ return FALSE;
/* Get the type. */
method_type = pop_type (info);
if (method_type == NULL)
- return false;
+ return FALSE;
/* Pull off the context type if there is one. */
if (! context)
@@ -1390,19 +1449,19 @@ pr_class_method_variant (p, physname, visibility, constp, volatilep, voffset,
{
context_type = pop_type (info);
if (context_type == NULL)
- return false;
+ return FALSE;
}
/* Now the top of the stack is the class. */
if (! pr_fix_visibility (info, visibility))
- return false;
+ return FALSE;
if (! append_type (info, method_type)
|| ! append_type (info, " /* ")
|| ! append_type (info, physname)
|| ! append_type (info, " "))
- return false;
+ return FALSE;
if (context || voffset != 0)
{
char ab[20];
@@ -1412,12 +1471,12 @@ pr_class_method_variant (p, physname, visibility, constp, volatilep, voffset,
if (! append_type (info, "context ")
|| ! append_type (info, context_type)
|| ! append_type (info, " "))
- return false;
+ return FALSE;
}
- print_vma (voffset, ab, true, false);
+ print_vma (voffset, ab, TRUE, FALSE);
if (! append_type (info, "voffset ")
|| ! append_type (info, ab))
- return false;
+ return FALSE;
}
return (append_type (info, " */;\n")
@@ -1426,13 +1485,10 @@ pr_class_method_variant (p, physname, visibility, constp, volatilep, voffset,
/* Add a static variant to a method. */
-static boolean
-pr_class_static_method_variant (p, physname, visibility, constp, volatilep)
- PTR p;
- const char *physname;
- enum debug_visibility visibility;
- boolean constp;
- boolean volatilep;
+static bfd_boolean
+pr_class_static_method_variant (void *p, const char *physname,
+ enum debug_visibility visibility,
+ bfd_boolean constp, bfd_boolean volatilep)
{
struct pr_handle *info = (struct pr_handle *) p;
char *method_type;
@@ -1445,31 +1501,31 @@ pr_class_static_method_variant (p, physname, visibility, constp, volatilep)
if (volatilep)
{
if (! append_type (info, " volatile"))
- return false;
+ return FALSE;
}
if (constp)
{
if (! append_type (info, " const"))
- return false;
+ return FALSE;
}
/* Mark it as static. */
if (! prepend_type (info, "static "))
- return false;
+ return FALSE;
/* Stick the name of the method into its type. */
if (! substitute_type (info, info->stack->next->method))
- return false;
+ return FALSE;
/* Get the type. */
method_type = pop_type (info);
if (method_type == NULL)
- return false;
+ return FALSE;
/* Now the top of the stack is the class. */
if (! pr_fix_visibility (info, visibility))
- return false;
+ return FALSE;
return (append_type (info, method_type)
&& append_type (info, " /* ")
@@ -1480,31 +1536,27 @@ pr_class_static_method_variant (p, physname, visibility, constp, volatilep)
/* Finish up a method. */
-static boolean
-pr_class_end_method (p)
- PTR p;
+static bfd_boolean
+pr_class_end_method (void *p)
{
struct pr_handle *info = (struct pr_handle *) p;
info->stack->method = NULL;
- return true;
+ return TRUE;
}
/* Finish up a class. */
-static boolean
-pr_end_class_type (p)
- PTR p;
+static bfd_boolean
+pr_end_class_type (void *p)
{
return pr_end_struct_type (p);
}
/* Push a type on the stack using a typedef name. */
-static boolean
-pr_typedef_type (p, name)
- PTR p;
- const char *name;
+static bfd_boolean
+pr_typedef_type (void *p, const char *name)
{
struct pr_handle *info = (struct pr_handle *) p;
@@ -1513,12 +1565,9 @@ pr_typedef_type (p, name)
/* Push a type on the stack using a tag name. */
-static boolean
-pr_tag_type (p, name, id, kind)
- PTR p;
- const char *name;
- unsigned int id;
- enum debug_type_kind kind;
+static bfd_boolean
+pr_tag_type (void *p, const char *name, unsigned int id,
+ enum debug_type_kind kind)
{
struct pr_handle *info = (struct pr_handle *) p;
const char *t, *tag;
@@ -1543,11 +1592,11 @@ pr_tag_type (p, name, id, kind)
break;
default:
abort ();
- return false;
+ return FALSE;
}
if (! push_type (info, t))
- return false;
+ return FALSE;
if (name != NULL)
tag = name;
else
@@ -1557,104 +1606,91 @@ pr_tag_type (p, name, id, kind)
}
if (! append_type (info, tag))
- return false;
+ return FALSE;
if (name != NULL && kind != DEBUG_KIND_ENUM)
{
sprintf (idbuf, " /* id %u */", id);
if (! append_type (info, idbuf))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Output a typedef. */
-static boolean
-pr_typdef (p, name)
- PTR p;
- const char *name;
+static bfd_boolean
+pr_typdef (void *p, const char *name)
{
struct pr_handle *info = (struct pr_handle *) p;
char *s;
if (! substitute_type (info, name))
- return false;
+ return FALSE;
s = pop_type (info);
if (s == NULL)
- return false;
+ return FALSE;
indent (info);
fprintf (info->f, "typedef %s;\n", s);
free (s);
- return true;
+ return TRUE;
}
/* Output a tag. The tag should already be in the string on the
stack, so all we have to do here is print it out. */
-static boolean
-pr_tag (p, name)
- PTR p;
- const char *name ATTRIBUTE_UNUSED;
+static bfd_boolean
+pr_tag (void *p, const char *name ATTRIBUTE_UNUSED)
{
struct pr_handle *info = (struct pr_handle *) p;
char *t;
t = pop_type (info);
if (t == NULL)
- return false;
+ return FALSE;
indent (info);
fprintf (info->f, "%s;\n", t);
free (t);
- return true;
+ return TRUE;
}
/* Output an integer constant. */
-static boolean
-pr_int_constant (p, name, val)
- PTR p;
- const char *name;
- bfd_vma val;
+static bfd_boolean
+pr_int_constant (void *p, const char *name, bfd_vma val)
{
struct pr_handle *info = (struct pr_handle *) p;
char ab[20];
indent (info);
- print_vma (val, ab, false, false);
+ print_vma (val, ab, FALSE, FALSE);
fprintf (info->f, "const int %s = %s;\n", name, ab);
- return true;
+ return TRUE;
}
/* Output a floating point constant. */
-static boolean
-pr_float_constant (p, name, val)
- PTR p;
- const char *name;
- double val;
+static bfd_boolean
+pr_float_constant (void *p, const char *name, double val)
{
struct pr_handle *info = (struct pr_handle *) p;
indent (info);
fprintf (info->f, "const double %s = %g;\n", name, val);
- return true;
+ return TRUE;
}
/* Output a typed constant. */
-static boolean
-pr_typed_constant (p, name, val)
- PTR p;
- const char *name;
- bfd_vma val;
+static bfd_boolean
+pr_typed_constant (void *p, const char *name, bfd_vma val)
{
struct pr_handle *info = (struct pr_handle *) p;
char *t;
@@ -1662,36 +1698,33 @@ pr_typed_constant (p, name, val)
t = pop_type (info);
if (t == NULL)
- return false;
+ return FALSE;
indent (info);
- print_vma (val, ab, false, false);
+ print_vma (val, ab, FALSE, FALSE);
fprintf (info->f, "const %s %s = %s;\n", t, name, ab);
free (t);
- return true;
+ return TRUE;
}
/* Output a variable. */
-static boolean
-pr_variable (p, name, kind, val)
- PTR p;
- const char *name;
- enum debug_var_kind kind;
- bfd_vma val;
+static bfd_boolean
+pr_variable (void *p, const char *name, enum debug_var_kind kind,
+ bfd_vma val)
{
struct pr_handle *info = (struct pr_handle *) p;
char *t;
char ab[20];
if (! substitute_type (info, name))
- return false;
+ return FALSE;
t = pop_type (info);
if (t == NULL)
- return false;
+ return FALSE;
indent (info);
switch (kind)
@@ -1706,31 +1739,28 @@ pr_variable (p, name, kind, val)
default:
break;
}
- print_vma (val, ab, true, true);
+ print_vma (val, ab, TRUE, TRUE);
fprintf (info->f, "%s /* %s */;\n", t, ab);
free (t);
- return true;
+ return TRUE;
}
/* Start outputting a function. */
-static boolean
-pr_start_function (p, name, global)
- PTR p;
- const char *name;
- boolean global;
+static bfd_boolean
+pr_start_function (void *p, const char *name, bfd_boolean global)
{
struct pr_handle *info = (struct pr_handle *) p;
char *t;
if (! substitute_type (info, name))
- return false;
+ return FALSE;
t = pop_type (info);
if (t == NULL)
- return false;
+ return FALSE;
indent (info);
if (! global)
@@ -1739,17 +1769,14 @@ pr_start_function (p, name, global)
info->parameter = 1;
- return true;
+ return TRUE;
}
/* Output a function parameter. */
-static boolean
-pr_function_parameter (p, name, kind, val)
- PTR p;
- const char *name;
- enum debug_parm_kind kind;
- bfd_vma val;
+static bfd_boolean
+pr_function_parameter (void *p, const char *name,
+ enum debug_parm_kind kind, bfd_vma val)
{
struct pr_handle *info = (struct pr_handle *) p;
char *t;
@@ -1759,15 +1786,15 @@ pr_function_parameter (p, name, kind, val)
|| kind == DEBUG_PARM_REF_REG)
{
if (! pr_reference_type (p))
- return false;
+ return FALSE;
}
if (! substitute_type (info, name))
- return false;
+ return FALSE;
t = pop_type (info);
if (t == NULL)
- return false;
+ return FALSE;
if (info->parameter != 1)
fprintf (info->f, ", ");
@@ -1775,22 +1802,20 @@ pr_function_parameter (p, name, kind, val)
if (kind == DEBUG_PARM_REG || kind == DEBUG_PARM_REF_REG)
fprintf (info->f, "register ");
- print_vma (val, ab, true, true);
+ print_vma (val, ab, TRUE, TRUE);
fprintf (info->f, "%s /* %s */", t, ab);
free (t);
++info->parameter;
- return true;
+ return TRUE;
}
/* Start writing out a block. */
-static boolean
-pr_start_block (p, addr)
- PTR p;
- bfd_vma addr;
+static bfd_boolean
+pr_start_block (void *p, bfd_vma addr)
{
struct pr_handle *info = (struct pr_handle *) p;
char ab[20];
@@ -1802,39 +1827,33 @@ pr_start_block (p, addr)
}
indent (info);
- print_vma (addr, ab, true, true);
+ print_vma (addr, ab, TRUE, TRUE);
fprintf (info->f, "{ /* %s */\n", ab);
info->indent += 2;
- return true;
+ return TRUE;
}
/* Write out line number information. */
-static boolean
-pr_lineno (p, filename, lineno, addr)
- PTR p;
- const char *filename;
- unsigned long lineno;
- bfd_vma addr;
+static bfd_boolean
+pr_lineno (void *p, const char *filename, unsigned long lineno, bfd_vma addr)
{
struct pr_handle *info = (struct pr_handle *) p;
char ab[20];
indent (info);
- print_vma (addr, ab, true, true);
+ print_vma (addr, ab, TRUE, TRUE);
fprintf (info->f, "/* file %s line %lu addr %s */\n", filename, lineno, ab);
- return true;
+ return TRUE;
}
/* Finish writing out a block. */
-static boolean
-pr_end_block (p, addr)
- PTR p;
- bfd_vma addr;
+static bfd_boolean
+pr_end_block (void *p, bfd_vma addr)
{
struct pr_handle *info = (struct pr_handle *) p;
char ab[20];
@@ -1842,17 +1861,934 @@ pr_end_block (p, addr)
info->indent -= 2;
indent (info);
- print_vma (addr, ab, true, true);
+ print_vma (addr, ab, TRUE, TRUE);
fprintf (info->f, "} /* %s */\n", ab);
- return true;
+ return TRUE;
}
/* Finish writing out a function. */
-static boolean
-pr_end_function (p)
- PTR p ATTRIBUTE_UNUSED;
+static bfd_boolean
+pr_end_function (void *p ATTRIBUTE_UNUSED)
+{
+ return TRUE;
+}
+
+/* Tags style generation functions start here. */
+
+/* Variables for address to line translation. */
+static bfd_vma pc;
+static const char *filename;
+static const char *functionname;
+static unsigned int line;
+static bfd_boolean found;
+
+/* Look for an address in a section. This is called via
+ bfd_map_over_sections. */
+
+static void
+find_address_in_section (bfd *abfd, asection *section, void *data)
+{
+ bfd_vma vma;
+ bfd_size_type size;
+ asymbol **syms = (asymbol **) data;
+
+ if (found)
+ return;
+
+ if ((bfd_get_section_flags (abfd, section) & SEC_ALLOC) == 0)
+ return;
+
+ vma = bfd_get_section_vma (abfd, section);
+ if (pc < vma)
+ return;
+
+ size = bfd_get_section_size_before_reloc (section);
+ if (pc >= vma + size)
+ return;
+
+ found = bfd_find_nearest_line (abfd, section, syms, pc - vma,
+ &filename, &functionname, &line);
+}
+
+static void
+translate_addresses (bfd *abfd, char *addr_hex, FILE *f, asymbol **syms)
+{
+ pc = bfd_scan_vma (addr_hex, NULL, 16);
+ found = FALSE;
+ bfd_map_over_sections (abfd, find_address_in_section, syms);
+
+ if (! found)
+ fprintf (f, "??");
+ else
+ fprintf (f, "%u", line);
+}
+
+/* Start a new compilation unit. */
+
+static bfd_boolean
+tg_start_compilation_unit (void * p, const char *filename ATTRIBUTE_UNUSED)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+
+ fprintf (stderr, "New compilation unit: %s\n", filename);
+
+ free (info->filename);
+ /* Should it be relative? best way to do it here?. */
+ info->filename = strdup (filename);
+
+ return TRUE;
+}
+
+/* Start a source file within a compilation unit. */
+
+static bfd_boolean
+tg_start_source (void *p, const char *filename)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+
+ free (info->filename);
+ /* Should it be relative? best way to do it here?. */
+ info->filename = strdup (filename);
+
+ return TRUE;
+}
+
+/* Push an enum type onto the type stack. */
+
+static bfd_boolean
+tg_enum_type (void *p, const char *tag, const char **names,
+ bfd_signed_vma *values)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+ unsigned int i;
+ const char *name;
+ char ab[20];
+
+ if (! pr_enum_type (p, tag, names, values))
+ return FALSE;
+
+ name = tag ? tag : "unknown";
+ /* Generate an entry for the enum. */
+ if (tag)
+ fprintf (info->f, "%s\t%s\t0;\"\tkind:e\ttype:%s\n", tag,
+ info->filename, info->stack->type);
+
+ /* Generate entries for the values. */
+ if (names != NULL)
+ {
+ for (i = 0; names[i] != NULL; i++)
+ {
+ print_vma (values[i], ab, FALSE, FALSE);
+ fprintf (info->f, "%s\t%s\t0;\"\tkind:g\tenum:%s\tvalue:%s\n",
+ names[i], info->filename, name, ab);
+ }
+ }
+
+ return TRUE;
+}
+
+/* Start accumulating a struct type. */
+
+static bfd_boolean
+tg_start_struct_type (void *p, const char *tag, unsigned int id,
+ bfd_boolean structp,
+ unsigned int size ATTRIBUTE_UNUSED)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+ const char *name;
+ char idbuf[20];
+
+ if (tag != NULL)
+ name = tag;
+ else
+ {
+ name = idbuf;
+ sprintf (idbuf, "%%anon%u", id);
+ }
+
+ if (! push_type (info, name))
+ return FALSE;
+
+ info->stack->flavor = structp ? "struct" : "union";
+
+ fprintf (info->f, "%s\t%s\t0;\"\tkind:%c\n", name, info->filename,
+ info->stack->flavor[0]);
+
+ info->stack->visibility = DEBUG_VISIBILITY_PUBLIC;
+
+ return indent_type (info);
+}
+
+/* Output the visibility of a field in a struct. */
+
+static bfd_boolean
+tg_fix_visibility (struct pr_handle *info, enum debug_visibility visibility)
+{
+ assert (info->stack != NULL);
+
+ if (info->stack->visibility == visibility)
+ return TRUE;
+
+ assert (info->stack->visibility != DEBUG_VISIBILITY_IGNORE);
+
+ info->stack->visibility = visibility;
+
+ return TRUE;
+}
+
+/* Add a field to a struct type. */
+
+static bfd_boolean
+tg_struct_field (void *p, const char *name, bfd_vma bitpos ATTRIBUTE_UNUSED,
+ bfd_vma bitsize ATTRIBUTE_UNUSED,
+ enum debug_visibility visibility)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+ char *t;
+
+ t = pop_type (info);
+ if (t == NULL)
+ return FALSE;
+
+ if (! tg_fix_visibility (info, visibility))
+ return FALSE;
+
+ /* It happens, a bug? */
+ if (! name[0])
+ return TRUE;
+
+ fprintf (info->f, "%s\t%s\t0;\"\tkind:m\ttype:%s\t%s:%s\taccess:%s\n",
+ name, info->filename, t, info->stack->flavor, info->stack->type,
+ visibility_name (visibility));
+
+ return TRUE;
+}
+
+/* Finish a struct type. */
+
+static bfd_boolean
+tg_end_struct_type (void *p ATTRIBUTE_UNUSED)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+ assert (info->stack != NULL);
+
+ return TRUE;
+}
+
+/* Start a class type. */
+
+static bfd_boolean
+tg_start_class_type (void *p, const char *tag, unsigned int id,
+ bfd_boolean structp, unsigned int size,
+ bfd_boolean vptr, bfd_boolean ownvptr)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+ char *tv = NULL;
+ const char *name;
+
+ info->indent += 2;
+
+ if (vptr && ! ownvptr)
+ {
+ tv = pop_type (info);
+ if (tv == NULL)
+ return FALSE;
+ }
+
+ if (tag != NULL)
+ name = tag;
+ else
+ {
+ char idbuf[20];
+
+ sprintf (idbuf, "%%anon%u", id);
+ name = idbuf;
+ }
+
+ if (! push_type (info, name))
+ return FALSE;
+
+ info->stack->flavor = structp ? "class" : "union class";
+ info->stack->parents = NULL;
+ info->stack->num_parents = 0;
+
+ if (size != 0 || vptr || ownvptr || tag != NULL)
+ {
+ if (vptr)
+ {
+ if (! append_type (info, " vtable "))
+ return FALSE;
+ if (ownvptr)
+ {
+ if (! append_type (info, "self "))
+ return FALSE;
+ }
+ else
+ {
+ if (! append_type (info, tv)
+ || ! append_type (info, " "))
+ return FALSE;
+ }
+ }
+ }
+
+ info->stack->visibility = DEBUG_VISIBILITY_PRIVATE;
+
+ return TRUE;
+}
+
+/* Add a static member to a class. */
+
+static bfd_boolean
+tg_class_static_member (void *p, const char *name,
+ const char *physname ATTRIBUTE_UNUSED,
+ enum debug_visibility visibility)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+ char *t;
+ int len_var, len_class;
+ char *full_name;
+
+ len_var = strlen (name);
+ len_class = strlen (info->stack->next->type);
+ full_name = (char *) xmalloc (len_var + len_class + 3);
+ if (! full_name)
+ return FALSE;
+ memcpy (full_name, info->stack->next->type, len_class);
+ memcpy (full_name + len_class, "::", 2);
+ memcpy (full_name + len_class + 2, name, len_var + 1);
+
+ if (! substitute_type (info, full_name))
+ return FALSE;
+
+ if (! prepend_type (info, "static "))
+ return FALSE;
+
+ t = pop_type (info);
+ if (t == NULL)
+ return FALSE;
+
+ if (! tg_fix_visibility (info, visibility))
+ return FALSE;
+
+ fprintf (info->f, "%s\t%s\t0;\"\tkind:x\ttype:%s\tclass:%s\taccess:%s\n",
+ name, info->filename, t, info->stack->type,
+ visibility_name (visibility));
+ free (t);
+ free (full_name);
+
+ return TRUE;
+}
+
+/* Add a base class to a class. */
+
+static bfd_boolean
+tg_class_baseclass (void *p, bfd_vma bitpos ATTRIBUTE_UNUSED,
+ bfd_boolean virtual, enum debug_visibility visibility)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+ char *t;
+ const char *prefix;
+
+ assert (info->stack != NULL && info->stack->next != NULL);
+
+ t = pop_type (info);
+ if (t == NULL)
+ return FALSE;
+
+ if (strncmp (t, "class ", sizeof "class " - 1) == 0)
+ t += sizeof "class " - 1;
+
+ /* Push it back on to take advantage of the prepend_type and
+ append_type routines. */
+ if (! push_type (info, t))
+ return FALSE;
+
+ if (virtual)
+ {
+ if (! prepend_type (info, "virtual "))
+ return FALSE;
+ }
+
+ switch (visibility)
+ {
+ case DEBUG_VISIBILITY_PUBLIC:
+ prefix = "public ";
+ break;
+ case DEBUG_VISIBILITY_PROTECTED:
+ prefix = "protected ";
+ break;
+ case DEBUG_VISIBILITY_PRIVATE:
+ prefix = "private ";
+ break;
+ default:
+ prefix = "/* unknown visibility */ ";
+ break;
+ }
+
+ if (! prepend_type (info, prefix))
+ return FALSE;
+
+ t = pop_type (info);
+ if (t == NULL)
+ return FALSE;
+
+ if (info->stack->num_parents && ! append_parent (info, ", "))
+ return FALSE;
+
+ if (! append_parent (info, t))
+ return FALSE;
+ info->stack->num_parents++;
+
+ free (t);
+
+ return TRUE;
+}
+
+/* Add a variant to a method. */
+
+static bfd_boolean
+tg_class_method_variant (void *p, const char *physname ATTRIBUTE_UNUSED,
+ enum debug_visibility visibility,
+ bfd_boolean constp, bfd_boolean volatilep,
+ bfd_vma voffset ATTRIBUTE_UNUSED,
+ bfd_boolean context)
{
- return true;
+ struct pr_handle *info = (struct pr_handle *) p;
+ char *method_type;
+ char *context_type;
+ char *method_name;
+
+ assert (info->stack != NULL);
+ assert (info->stack->next != NULL);
+
+ /* Put the const and volatile qualifiers on the type. */
+ if (volatilep)
+ {
+ if (! append_type (info, " volatile"))
+ return FALSE;
+ }
+ if (constp)
+ {
+ if (! append_type (info, " const"))
+ return FALSE;
+ }
+
+ method_name = strdup (context ? info->stack->next->next->method
+ : info->stack->next->method);
+
+ /* Stick the name of the method into its type. */
+ if (! substitute_type (info, method_name))
+ return FALSE;
+
+ /* Get the type. */
+ method_type = pop_type (info);
+ if (method_type == NULL)
+ return FALSE;
+
+ /* Pull off the context type if there is one. */
+ if (! context)
+ context_type = NULL;
+ else
+ {
+ context_type = pop_type (info);
+ if (context_type == NULL)
+ return FALSE;
+ }
+
+ /* Now the top of the stack is the class. */
+ if (! tg_fix_visibility (info, visibility))
+ return FALSE;
+
+ fprintf (info->f, "%s\t%s\t0;\"\tkind:p\ttype:%s\tclass:%s\n",
+ method_name, info->filename, method_type, info->stack->type);
+ free (method_type);
+ free (method_name);
+ free (context_type);
+
+ return TRUE;
+}
+
+/* Add a static variant to a method. */
+
+static bfd_boolean
+tg_class_static_method_variant (void *p,
+ const char *physname ATTRIBUTE_UNUSED,
+ enum debug_visibility visibility,
+ bfd_boolean constp, bfd_boolean volatilep)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+ char *method_type;
+ char *method_name;
+
+ assert (info->stack != NULL);
+ assert (info->stack->next != NULL);
+ assert (info->stack->next->method != NULL);
+
+ /* Put the const and volatile qualifiers on the type. */
+ if (volatilep)
+ {
+ if (! append_type (info, " volatile"))
+ return FALSE;
+ }
+ if (constp)
+ {
+ if (! append_type (info, " const"))
+ return FALSE;
+ }
+
+ /* Mark it as static. */
+ if (! prepend_type (info, "static "))
+ return FALSE;
+
+ method_name = strdup (info->stack->next->method);
+ /* Stick the name of the method into its type. */
+ if (! substitute_type (info, info->stack->next->method))
+ return FALSE;
+
+ /* Get the type. */
+ method_type = pop_type (info);
+ if (method_type == NULL)
+ return FALSE;
+
+ /* Now the top of the stack is the class. */
+ if (! tg_fix_visibility (info, visibility))
+ return FALSE;
+
+ fprintf (info->f, "%s\t%s\t0;\"\tkind:p\ttype:%s\tclass:%s\taccess:%s\n",
+ method_name, info->filename, method_type, info->stack->type,
+ visibility_name (visibility));
+ free (method_type);
+ free (method_name);
+
+ return TRUE;
+}
+
+/* Finish up a class. */
+
+static bfd_boolean
+tg_end_class_type (void *p)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+
+ fprintf (info->f, "%s\t%s\t0;\"\tkind:c\ttype:%s", info->stack->type,
+ info->filename, info->stack->flavor);
+ if (info->stack->num_parents)
+ {
+ fprintf (info->f, "\tinherits:%s", info->stack->parents);
+ free (info->stack->parents);
+ }
+ fputc ('\n', info->f);
+
+ return tg_end_struct_type (p);
+}
+
+/* Push a type on the stack using a tag name. */
+
+static bfd_boolean
+tg_tag_type (void *p, const char *name, unsigned int id,
+ enum debug_type_kind kind)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+ const char *t, *tag;
+ char idbuf[20];
+
+ switch (kind)
+ {
+ case DEBUG_KIND_STRUCT:
+ t = "struct ";
+ break;
+ case DEBUG_KIND_UNION:
+ t = "union ";
+ break;
+ case DEBUG_KIND_ENUM:
+ t = "enum ";
+ break;
+ case DEBUG_KIND_CLASS:
+ t = "class ";
+ break;
+ case DEBUG_KIND_UNION_CLASS:
+ t = "union class ";
+ break;
+ default:
+ abort ();
+ return FALSE;
+ }
+
+ if (! push_type (info, t))
+ return FALSE;
+ if (name != NULL)
+ tag = name;
+ else
+ {
+ sprintf (idbuf, "%%anon%u", id);
+ tag = idbuf;
+ }
+
+ if (! append_type (info, tag))
+ return FALSE;
+
+ return TRUE;
+}
+
+/* Output a typedef. */
+
+static bfd_boolean
+tg_typdef (void *p, const char *name)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+ char *s;
+
+ s = pop_type (info);
+ if (s == NULL)
+ return FALSE;
+
+ fprintf (info->f, "%s\t%s\t0;\"\tkind:t\ttype:%s\n", name,
+ info->filename, s);
+
+ free (s);
+
+ return TRUE;
+}
+
+/* Output a tag. The tag should already be in the string on the
+ stack, so all we have to do here is print it out. */
+
+static bfd_boolean
+tg_tag (void *p ATTRIBUTE_UNUSED, const char *name ATTRIBUTE_UNUSED)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+ char *t;
+
+ t = pop_type (info);
+ if (t == NULL)
+ return FALSE;
+ free (t);
+
+ return TRUE;
+}
+
+/* Output an integer constant. */
+
+static bfd_boolean
+tg_int_constant (void *p, const char *name, bfd_vma val)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+ char ab[20];
+
+ indent (info);
+ print_vma (val, ab, FALSE, FALSE);
+ fprintf (info->f, "%s\t%s\t0;\"\tkind:v\ttype:const int\tvalue:%s\n",
+ name, info->filename, ab);
+ return TRUE;
+}
+
+/* Output a floating point constant. */
+
+static bfd_boolean
+tg_float_constant (void *p, const char *name, double val)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+
+ indent (info);
+ fprintf (info->f, "%s\t%s\t0;\"\tkind:v\ttype:const double\tvalue:%g\n",
+ name, info->filename, val);
+ return TRUE;
+}
+
+/* Output a typed constant. */
+
+static bfd_boolean
+tg_typed_constant (void *p, const char *name, bfd_vma val)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+ char *t;
+ char ab[20];
+
+ t = pop_type (info);
+ if (t == NULL)
+ return FALSE;
+
+ indent (info);
+ print_vma (val, ab, FALSE, FALSE);
+ fprintf (info->f, "%s\t%s\t0;\"\tkind:v\ttype:const %s\tvalue:%s\n",
+ name, info->filename, t, ab);
+
+ free (t);
+
+ return TRUE;
+}
+
+/* Output a variable. */
+
+static bfd_boolean
+tg_variable (void *p, const char *name, enum debug_var_kind kind,
+ bfd_vma val ATTRIBUTE_UNUSED)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+ char *t;
+ const char *dname, *from_class;
+
+ t = pop_type (info);
+ if (t == NULL)
+ return FALSE;
+
+ dname = name;
+ if (info->demangler)
+ {
+ dname = info->demangler (info->abfd, name);
+ if (strcmp (name, dname) == 0)
+ {
+ free ((char *) dname);
+ dname = name;
+ }
+ }
+
+ if (dname != name)
+ {
+ char *sep;
+ sep = strstr (dname, "::");
+ if (sep)
+ {
+ *sep = 0;
+ name = sep + 2;
+ from_class = dname;
+ }
+ else
+ {
+ /* Obscure types as vts and type_info nodes. */
+ name = dname;
+ from_class = NULL;
+ }
+ }
+ else
+ from_class = NULL;
+
+ fprintf (info->f, "%s\t%s\t0;\"\tkind:v\ttype:%s", name, info->filename, t);
+
+ switch (kind)
+ {
+ case DEBUG_STATIC:
+ case DEBUG_LOCAL_STATIC:
+ fprintf (info->f, "\tfile:");
+ break;
+ case DEBUG_REGISTER:
+ fprintf (info->f, "\tregister:");
+ break;
+ default:
+ break;
+ }
+
+ if (from_class)
+ {
+ fprintf (info->f, "\tclass:%s",from_class);
+ free ((char *) dname);
+ }
+
+ fprintf (info->f, "\n");
+
+ free (t);
+
+ return TRUE;
+}
+
+/* Start outputting a function. */
+
+static bfd_boolean
+tg_start_function (void *p, const char *name, bfd_boolean global)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+ const char *dname;
+
+ if (! global)
+ info->stack->flavor = "static";
+ else
+ info->stack->flavor = NULL;
+
+ dname = name;
+ if (info->demangler)
+ {
+ dname = info->demangler (info->abfd, name);
+ if (strcmp (name, dname) == 0)
+ {
+ free ((char *) dname);
+ dname = name;
+ }
+ }
+
+ if (! substitute_type (info, dname))
+ return FALSE;
+
+ if (dname != name)
+ {
+ char *sep;
+ sep = strstr (dname, "::");
+ if (sep)
+ {
+ info->stack->method = dname;
+ *sep = 0;
+ name = sep + 2;
+ }
+ else
+ {
+ info->stack->method = "";
+ name = dname;
+ }
+ sep = strchr (name, '(');
+ if (sep)
+ *sep = 0;
+ /* Obscure functions as type_info function. */
+ }
+ else
+ info->stack->method = NULL;
+
+ info->stack->parents = strdup (name);
+
+ if (! info->stack->method && ! append_type (info, "("))
+ return FALSE;
+
+ info->parameter = 1;
+
+ return TRUE;
+}
+
+/* Output a function parameter. */
+
+static bfd_boolean
+tg_function_parameter (void *p, const char *name, enum debug_parm_kind kind,
+ bfd_vma val ATTRIBUTE_UNUSED)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+ char *t;
+
+ if (kind == DEBUG_PARM_REFERENCE
+ || kind == DEBUG_PARM_REF_REG)
+ {
+ if (! pr_reference_type (p))
+ return FALSE;
+ }
+
+ if (! substitute_type (info, name))
+ return FALSE;
+
+ t = pop_type (info);
+ if (t == NULL)
+ return FALSE;
+
+ if (! info->stack->method)
+ {
+ if (info->parameter != 1 && ! append_type (info, ", "))
+ return FALSE;
+
+ if (kind == DEBUG_PARM_REG || kind == DEBUG_PARM_REF_REG)
+ if (! append_type (info, "register "))
+ return FALSE;
+
+ if (! append_type (info, t))
+ return FALSE;
+ }
+
+ free (t);
+
+ ++info->parameter;
+
+ return TRUE;
+}
+
+/* Start writing out a block. */
+
+static bfd_boolean
+tg_start_block (void *p, bfd_vma addr)
+{
+ struct pr_handle *info = (struct pr_handle *) p;
+ char ab[20], kind, *partof;
+ char *t;
+ bfd_boolean local;
+
+ if (info->parameter > 0)
+ {
+ info->parameter = 0;
+
+ /* Delayed name. */
+ fprintf (info->f, "%s\t%s\t", info->stack->parents, info->filename);
+ free (info->stack->parents);
+
+ print_vma (addr, ab, TRUE, TRUE);
+ translate_addresses (info->abfd, ab, info->f, info->syms);
+ local = info->stack->flavor != NULL;
+ if (info->stack->method && *info->stack->method)
+ {
+ kind = 'm';
+ partof = (char *) info->stack->method;
+ }
+ else
+ {
+ kind = 'f';
+ partof = NULL;
+ if (! info->stack->method && ! append_type (info, ")"))
+ return FALSE;
+ }
+ t = pop_type (info);
+ if (t == NULL)
+ return FALSE;
+ fprintf (info->f, ";\"\tkind:%c\ttype:%s", kind, t);
+ if (local)
+ fputs ("\tfile:", info->f);
+ if (partof)
+ {
+ fprintf (info->f, "\tclass:%s", partof);
+ free (partof);
+ }
+ fputc ('\n', info->f);
+ }
+
+ return TRUE;
+}
+
+/* Write out line number information. */
+
+static bfd_boolean
+tg_lineno (void *p ATTRIBUTE_UNUSED, const char *filename ATTRIBUTE_UNUSED,
+ unsigned long lineno ATTRIBUTE_UNUSED,
+ bfd_vma addr ATTRIBUTE_UNUSED)
+{
+ return TRUE;
+}
+
+/* Finish writing out a block. */
+
+static bfd_boolean
+tg_end_block (void *p ATTRIBUTE_UNUSED, bfd_vma addr ATTRIBUTE_UNUSED)
+{
+ return TRUE;
+}
+
+/* Convert the visibility value into a human readable name. */
+
+static const char *
+visibility_name (enum debug_visibility visibility)
+{
+ const char *s;
+
+ switch (visibility)
+ {
+ case DEBUG_VISIBILITY_PUBLIC:
+ s = "public";
+ break;
+ case DEBUG_VISIBILITY_PRIVATE:
+ s = "private";
+ break;
+ case DEBUG_VISIBILITY_PROTECTED:
+ s = "protected";
+ break;
+ case DEBUG_VISIBILITY_IGNORE:
+ s = "/* ignore */";
+ break;
+ default:
+ abort ();
+ return FALSE;
+ }
+ return s;
}
diff --git a/contrib/binutils/binutils/rclex.c b/contrib/binutils/binutils/rclex.c
index bc9e68c..e5070e3 100644
--- a/contrib/binutils/binutils/rclex.c
+++ b/contrib/binutils/binutils/rclex.c
@@ -1,7 +1,7 @@
/* A lexical scanner generated by flex */
/* Scanner skeleton version:
- * $Header: /cvs/src/src/binutils/Attic/rclex.c,v 1.1.8.1 2002/08/05 20:43:45 drow Exp $
+ * $Header: /cvs/src/src/binutils/Attic/rclex.c,v 1.1.12.1 2004/04/09 19:32:15 drow Exp $
*/
#define FLEX_SCANNER
@@ -64,6 +64,7 @@
#define YY_PROTO(proto) ()
#endif
+
/* Returned upon end-of-file. */
#define YY_NULL 0
@@ -383,58 +384,58 @@ static yyconst int yy_meta[36] =
static yyconst short int yy_base[476] =
{ 0,
- 0, 0, 515, 516, 34, 516, 509, 0, 492, 25,
- 26, 45, 25, 28, 24, 486, 497, 49, 0, 40,
- 43, 486, 51, 66, 67, 482, 35, 516, 516, 81,
- 503, 84, 0, 486, 516, 0, 494, 477, 492, 475,
- 74, 474, 477, 475, 46, 489, 69, 484, 471, 481,
- 55, 477, 481, 466, 67, 469, 83, 83, 467, 477,
- 464, 478, 464, 459, 475, 470, 74, 453, 81, 457,
- 86, 76, 468, 467, 465, 452, 452, 458, 95, 461,
- 453, 447, 446, 106, 466, 456, 0, 451, 444, 449,
- 448, 443, 452, 435, 436, 449, 433, 448, 430, 426,
-
- 429, 430, 433, 441, 424, 0, 423, 436, 435, 420,
- 415, 417, 427, 419, 420, 424, 412, 428, 423, 410,
- 424, 405, 406, 407, 419, 409, 0, 402, 409, 416,
- 414, 410, 408, 415, 393, 399, 412, 406, 392, 401,
- 397, 391, 387, 388, 386, 392, 394, 103, 383, 387,
- 399, 388, 389, 396, 385, 377, 379, 376, 373, 376,
- 370, 374, 387, 368, 363, 98, 381, 0, 379, 367,
- 363, 0, 0, 362, 363, 360, 358, 375, 361, 356,
- 105, 373, 372, 351, 355, 355, 349, 0, 366, 352,
- 347, 346, 352, 346, 343, 356, 346, 354, 356, 352,
-
- 347, 344, 349, 0, 335, 344, 350, 0, 0, 334,
- 115, 334, 345, 119, 0, 345, 331, 0, 328, 326,
- 336, 325, 336, 328, 327, 320, 317, 313, 330, 0,
- 330, 331, 0, 0, 327, 322, 329, 314, 314, 0,
- 114, 305, 307, 318, 322, 318, 0, 321, 318, 107,
- 318, 318, 0, 306, 316, 0, 316, 308, 0, 294,
- 0, 298, 307, 294, 291, 304, 304, 0, 132, 137,
- 293, 287, 290, 300, 288, 290, 0, 293, 295, 295,
- 276, 292, 295, 0, 293, 278, 276, 0, 277, 0,
- 270, 283, 267, 285, 270, 281, 0, 280, 279, 271,
-
- 265, 277, 261, 257, 259, 257, 0, 274, 256, 0,
- 255, 254, 258, 248, 269, 268, 265, 258, 270, 143,
- 269, 149, 0, 259, 241, 0, 240, 0, 259, 238,
- 258, 239, 0, 250, 237, 250, 236, 231, 247, 246,
- 0, 249, 247, 247, 234, 227, 240, 225, 0, 222,
- 0, 223, 222, 239, 224, 237, 218, 227, 0, 216,
- 215, 222, 217, 235, 213, 0, 0, 209, 0, 226,
- 0, 209, 203, 0, 216, 0, 0, 0, 212, 206,
- 211, 0, 220, 0, 0, 215, 204, 199, 200, 199,
- 213, 199, 199, 197, 206, 208, 207, 199, 188, 194,
-
- 192, 188, 188, 190, 196, 0, 198, 182, 184, 182,
- 0, 0, 184, 181, 188, 176, 0, 177, 171, 172,
- 170, 183, 186, 181, 171, 0, 183, 171, 164, 0,
- 167, 175, 0, 164, 160, 155, 157, 156, 159, 0,
- 155, 0, 0, 160, 165, 156, 0, 0, 0, 0,
- 0, 141, 150, 141, 139, 0, 0, 128, 122, 126,
- 0, 0, 109, 91, 79, 0, 0, 0, 516, 156,
- 161, 65, 166, 171, 176
+ 0, 0, 517, 518, 34, 518, 511, 0, 494, 25,
+ 26, 45, 25, 28, 24, 488, 499, 49, 0, 40,
+ 43, 488, 51, 66, 67, 484, 35, 518, 518, 81,
+ 505, 84, 0, 488, 518, 0, 496, 479, 494, 477,
+ 75, 476, 479, 477, 46, 491, 70, 486, 473, 483,
+ 55, 479, 483, 468, 69, 471, 86, 84, 469, 479,
+ 466, 480, 466, 461, 477, 472, 75, 455, 81, 459,
+ 87, 77, 470, 469, 467, 454, 454, 460, 96, 463,
+ 455, 449, 448, 110, 468, 458, 0, 453, 446, 451,
+ 450, 445, 454, 437, 438, 451, 435, 450, 432, 428,
+
+ 431, 432, 435, 443, 426, 0, 425, 438, 437, 422,
+ 417, 419, 429, 421, 422, 426, 414, 430, 425, 412,
+ 426, 407, 408, 409, 421, 411, 0, 404, 411, 418,
+ 416, 412, 410, 417, 395, 401, 414, 408, 394, 403,
+ 399, 393, 389, 390, 388, 394, 396, 105, 385, 389,
+ 401, 390, 391, 398, 387, 379, 381, 378, 375, 378,
+ 372, 376, 389, 370, 365, 105, 383, 0, 381, 369,
+ 365, 0, 0, 364, 365, 362, 360, 377, 363, 358,
+ 105, 375, 374, 353, 357, 357, 351, 0, 368, 354,
+ 349, 348, 354, 348, 345, 358, 348, 356, 358, 354,
+
+ 349, 346, 351, 0, 337, 346, 352, 0, 0, 336,
+ 122, 336, 347, 107, 0, 347, 333, 0, 330, 328,
+ 338, 327, 338, 330, 329, 322, 319, 315, 332, 0,
+ 332, 333, 0, 0, 329, 324, 331, 316, 316, 0,
+ 116, 307, 309, 320, 324, 320, 0, 323, 320, 110,
+ 320, 320, 0, 308, 318, 0, 318, 310, 0, 296,
+ 0, 300, 309, 296, 293, 306, 306, 0, 135, 139,
+ 295, 289, 292, 302, 290, 292, 0, 295, 297, 297,
+ 278, 294, 297, 0, 295, 280, 278, 0, 279, 0,
+ 272, 285, 269, 287, 272, 283, 0, 282, 281, 273,
+
+ 267, 279, 263, 259, 261, 259, 0, 276, 258, 0,
+ 257, 256, 260, 250, 271, 270, 267, 260, 272, 145,
+ 271, 151, 0, 261, 243, 0, 242, 0, 261, 240,
+ 260, 241, 0, 252, 239, 252, 238, 233, 249, 248,
+ 0, 251, 249, 249, 236, 229, 242, 227, 0, 224,
+ 0, 225, 224, 241, 226, 239, 220, 229, 0, 218,
+ 217, 224, 219, 237, 215, 0, 0, 211, 0, 228,
+ 0, 211, 205, 0, 218, 0, 0, 0, 214, 208,
+ 213, 0, 222, 0, 0, 217, 206, 201, 202, 201,
+ 215, 201, 201, 199, 208, 210, 209, 201, 190, 196,
+
+ 194, 190, 190, 192, 198, 0, 200, 184, 186, 184,
+ 0, 0, 186, 183, 190, 178, 0, 179, 173, 174,
+ 172, 185, 188, 183, 173, 0, 185, 173, 166, 0,
+ 169, 177, 0, 166, 162, 157, 159, 158, 161, 0,
+ 157, 0, 0, 162, 167, 158, 0, 0, 0, 0,
+ 0, 143, 152, 143, 141, 0, 0, 130, 124, 124,
+ 0, 0, 107, 85, 80, 0, 0, 0, 518, 158,
+ 163, 65, 168, 173, 178
} ;
static yyconst short int yy_def[476] =
@@ -493,7 +494,7 @@ static yyconst short int yy_def[476] =
469, 469, 469, 469, 469
} ;
-static yyconst short int yy_nxt[552] =
+static yyconst short int yy_nxt[554] =
{ 0,
4, 5, 6, 5, 7, 8, 4, 9, 9, 10,
11, 12, 13, 14, 15, 16, 17, 18, 19, 19,
@@ -503,62 +504,62 @@ static yyconst short int yy_nxt[552] =
53, 39, 83, 40, 44, 95, 67, 64, 54, 96,
59, 45, 60, 65, 103, 46, 68, 66, 47, 34,
61, 62, 48, 49, 70, 73, 71, 74, 76, 72,
- 77, 104, 30, 78, 30, 84, 90, 108, 85, 91,
- 98, 99, 111, 75, 79, 113, 123, 109, 126, 129,
-
- 124, 131, 132, 114, 139, 468, 112, 84, 127, 130,
- 85, 205, 225, 467, 206, 241, 269, 269, 242, 270,
- 140, 226, 243, 295, 227, 228, 141, 229, 207, 273,
- 304, 466, 274, 269, 269, 305, 319, 465, 321, 296,
- 321, 322, 36, 321, 321, 464, 321, 322, 36, 321,
- 321, 463, 321, 322, 36, 321, 31, 31, 462, 31,
- 31, 33, 33, 461, 33, 33, 36, 460, 459, 36,
- 36, 320, 320, 458, 320, 320, 321, 321, 457, 456,
- 321, 455, 454, 453, 452, 451, 450, 449, 448, 447,
- 446, 445, 444, 443, 442, 441, 440, 439, 438, 437,
-
- 436, 435, 434, 433, 432, 431, 430, 429, 428, 427,
- 426, 425, 424, 423, 422, 421, 420, 419, 418, 417,
- 416, 415, 414, 413, 412, 411, 410, 409, 408, 407,
- 406, 405, 404, 403, 402, 401, 400, 399, 398, 364,
- 397, 396, 395, 394, 393, 392, 391, 390, 389, 388,
- 387, 386, 385, 384, 383, 382, 381, 380, 379, 378,
- 377, 376, 375, 374, 373, 372, 371, 370, 369, 368,
- 367, 366, 365, 364, 364, 363, 362, 361, 360, 359,
- 358, 357, 356, 355, 354, 353, 352, 351, 350, 349,
- 348, 347, 346, 345, 344, 343, 342, 341, 340, 339,
-
- 338, 337, 336, 335, 334, 333, 332, 331, 330, 329,
- 328, 327, 326, 325, 324, 323, 318, 317, 316, 315,
- 314, 313, 312, 311, 310, 309, 308, 307, 306, 303,
- 302, 301, 300, 299, 298, 297, 294, 293, 292, 291,
- 290, 289, 288, 287, 286, 285, 284, 283, 282, 281,
- 280, 279, 278, 277, 276, 275, 272, 271, 268, 267,
- 266, 265, 264, 263, 262, 261, 260, 259, 258, 257,
- 256, 255, 254, 253, 252, 251, 250, 249, 248, 247,
- 246, 245, 244, 240, 239, 238, 237, 236, 235, 234,
- 233, 232, 231, 230, 224, 223, 222, 221, 220, 219,
-
- 218, 217, 216, 215, 214, 213, 212, 211, 210, 209,
- 208, 204, 203, 202, 201, 200, 199, 198, 197, 196,
- 195, 194, 193, 192, 191, 190, 189, 188, 187, 186,
- 185, 184, 183, 182, 181, 180, 179, 178, 177, 176,
- 175, 174, 173, 172, 171, 170, 169, 168, 167, 166,
- 165, 164, 163, 162, 161, 160, 159, 158, 157, 156,
- 155, 154, 153, 152, 151, 150, 149, 148, 147, 146,
- 32, 145, 144, 143, 142, 138, 137, 136, 135, 134,
- 133, 128, 125, 122, 121, 120, 119, 118, 117, 116,
- 115, 110, 107, 106, 105, 102, 101, 100, 97, 94,
-
- 93, 92, 89, 88, 87, 86, 35, 32, 80, 69,
- 58, 57, 35, 32, 469, 3, 469, 469, 469, 469,
+ 77, 104, 30, 78, 30, 84, 84, 90, 85, 108,
+ 91, 98, 99, 75, 79, 111, 113, 123, 126, 109,
+
+ 129, 124, 131, 132, 114, 139, 468, 467, 127, 112,
+ 130, 84, 84, 205, 85, 241, 206, 273, 242, 225,
+ 274, 140, 243, 269, 269, 295, 270, 141, 226, 466,
+ 207, 227, 228, 304, 229, 465, 269, 269, 305, 319,
+ 321, 296, 321, 322, 36, 321, 321, 464, 321, 322,
+ 36, 321, 321, 463, 321, 322, 36, 321, 31, 31,
+ 462, 31, 31, 33, 33, 461, 33, 33, 36, 460,
+ 459, 36, 36, 320, 320, 458, 320, 320, 321, 321,
+ 457, 456, 321, 455, 454, 453, 452, 451, 450, 449,
+ 448, 447, 446, 445, 444, 443, 442, 441, 440, 439,
+
+ 438, 437, 436, 435, 434, 433, 432, 431, 430, 429,
+ 428, 427, 426, 425, 424, 423, 422, 421, 420, 419,
+ 418, 417, 416, 415, 414, 413, 412, 411, 410, 409,
+ 408, 407, 406, 405, 404, 403, 402, 401, 400, 399,
+ 398, 364, 397, 396, 395, 394, 393, 392, 391, 390,
+ 389, 388, 387, 386, 385, 384, 383, 382, 381, 380,
+ 379, 378, 377, 376, 375, 374, 373, 372, 371, 370,
+ 369, 368, 367, 366, 365, 364, 364, 363, 362, 361,
+ 360, 359, 358, 357, 356, 355, 354, 353, 352, 351,
+ 350, 349, 348, 347, 346, 345, 344, 343, 342, 341,
+
+ 340, 339, 338, 337, 336, 335, 334, 333, 332, 331,
+ 330, 329, 328, 327, 326, 325, 324, 323, 318, 317,
+ 316, 315, 314, 313, 312, 311, 310, 309, 308, 307,
+ 306, 303, 302, 301, 300, 299, 298, 297, 294, 293,
+ 292, 291, 290, 289, 288, 287, 286, 285, 284, 283,
+ 282, 281, 280, 279, 278, 277, 276, 275, 272, 271,
+ 268, 267, 266, 265, 264, 263, 262, 261, 260, 259,
+ 258, 257, 256, 255, 254, 253, 252, 251, 250, 249,
+ 248, 247, 246, 245, 244, 240, 239, 238, 237, 236,
+ 235, 234, 233, 232, 231, 230, 224, 223, 222, 221,
+
+ 220, 219, 218, 217, 216, 215, 214, 213, 212, 211,
+ 210, 209, 208, 204, 203, 202, 201, 200, 199, 198,
+ 197, 196, 195, 194, 193, 192, 191, 190, 189, 188,
+ 187, 186, 185, 184, 183, 182, 181, 180, 179, 178,
+ 177, 176, 175, 174, 173, 172, 171, 170, 169, 168,
+ 167, 166, 165, 164, 163, 162, 161, 160, 159, 158,
+ 157, 156, 155, 154, 153, 152, 151, 150, 149, 148,
+ 147, 146, 32, 145, 144, 143, 142, 138, 137, 136,
+ 135, 134, 133, 128, 125, 122, 121, 120, 119, 118,
+ 117, 116, 115, 110, 107, 106, 105, 102, 101, 100,
+
+ 97, 94, 93, 92, 89, 88, 87, 86, 35, 32,
+ 80, 69, 58, 57, 35, 32, 469, 3, 469, 469,
469, 469, 469, 469, 469, 469, 469, 469, 469, 469,
469, 469, 469, 469, 469, 469, 469, 469, 469, 469,
469, 469, 469, 469, 469, 469, 469, 469, 469, 469,
- 469
+ 469, 469, 469
} ;
-static yyconst short int yy_chk[552] =
+static yyconst short int yy_chk[554] =
{ 0,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
@@ -568,59 +569,59 @@ static yyconst short int yy_chk[552] =
14, 10, 27, 10, 12, 45, 21, 20, 14, 45,
18, 12, 18, 20, 51, 12, 21, 20, 12, 472,
18, 18, 12, 12, 23, 24, 23, 24, 25, 23,
- 25, 51, 30, 25, 30, 32, 41, 55, 32, 41,
- 47, 47, 57, 24, 25, 58, 67, 55, 69, 71,
-
- 67, 72, 72, 58, 79, 465, 57, 84, 69, 71,
- 84, 148, 166, 464, 148, 181, 211, 211, 181, 211,
- 79, 166, 181, 241, 166, 166, 79, 166, 148, 214,
- 250, 463, 214, 269, 269, 250, 269, 460, 270, 241,
- 270, 270, 270, 270, 320, 459, 320, 320, 320, 320,
- 322, 458, 322, 322, 322, 322, 470, 470, 455, 470,
- 470, 471, 471, 454, 471, 471, 473, 453, 452, 473,
- 473, 474, 474, 446, 474, 474, 475, 475, 445, 444,
- 475, 441, 439, 438, 437, 436, 435, 434, 432, 431,
- 429, 428, 427, 425, 424, 423, 422, 421, 420, 419,
-
- 418, 416, 415, 414, 413, 410, 409, 408, 407, 405,
- 404, 403, 402, 401, 400, 399, 398, 397, 396, 395,
- 394, 393, 392, 391, 390, 389, 388, 387, 386, 383,
- 381, 380, 379, 375, 373, 372, 370, 368, 365, 364,
- 363, 362, 361, 360, 358, 357, 356, 355, 354, 353,
- 352, 350, 348, 347, 346, 345, 344, 343, 342, 340,
- 339, 338, 337, 336, 335, 334, 332, 331, 330, 329,
- 327, 325, 324, 321, 319, 318, 317, 316, 315, 314,
- 313, 312, 311, 309, 308, 306, 305, 304, 303, 302,
- 301, 300, 299, 298, 296, 295, 294, 293, 292, 291,
-
- 289, 287, 286, 285, 283, 282, 281, 280, 279, 278,
- 276, 275, 274, 273, 272, 271, 267, 266, 265, 264,
- 263, 262, 260, 258, 257, 255, 254, 252, 251, 249,
- 248, 246, 245, 244, 243, 242, 239, 238, 237, 236,
- 235, 232, 231, 229, 228, 227, 226, 225, 224, 223,
- 222, 221, 220, 219, 217, 216, 213, 212, 210, 207,
- 206, 205, 203, 202, 201, 200, 199, 198, 197, 196,
- 195, 194, 193, 192, 191, 190, 189, 187, 186, 185,
- 184, 183, 182, 180, 179, 178, 177, 176, 175, 174,
- 171, 170, 169, 167, 165, 164, 163, 162, 161, 160,
-
- 159, 158, 157, 156, 155, 154, 153, 152, 151, 150,
- 149, 147, 146, 145, 144, 143, 142, 141, 140, 139,
- 138, 137, 136, 135, 134, 133, 132, 131, 130, 129,
- 128, 126, 125, 124, 123, 122, 121, 120, 119, 118,
- 117, 116, 115, 114, 113, 112, 111, 110, 109, 108,
- 107, 105, 104, 103, 102, 101, 100, 99, 98, 97,
- 96, 95, 94, 93, 92, 91, 90, 89, 88, 86,
- 85, 83, 82, 81, 80, 78, 77, 76, 75, 74,
- 73, 70, 68, 66, 65, 64, 63, 62, 61, 60,
- 59, 56, 54, 53, 52, 50, 49, 48, 46, 44,
-
- 43, 42, 40, 39, 38, 37, 34, 31, 26, 22,
- 17, 16, 9, 7, 3, 469, 469, 469, 469, 469,
+ 25, 51, 30, 25, 30, 32, 32, 41, 32, 55,
+ 41, 47, 47, 24, 25, 57, 58, 67, 69, 55,
+
+ 71, 67, 72, 72, 58, 79, 465, 464, 69, 57,
+ 71, 84, 84, 148, 84, 181, 148, 214, 181, 166,
+ 214, 79, 181, 211, 211, 241, 211, 79, 166, 463,
+ 148, 166, 166, 250, 166, 460, 269, 269, 250, 269,
+ 270, 241, 270, 270, 270, 270, 320, 459, 320, 320,
+ 320, 320, 322, 458, 322, 322, 322, 322, 470, 470,
+ 455, 470, 470, 471, 471, 454, 471, 471, 473, 453,
+ 452, 473, 473, 474, 474, 446, 474, 474, 475, 475,
+ 445, 444, 475, 441, 439, 438, 437, 436, 435, 434,
+ 432, 431, 429, 428, 427, 425, 424, 423, 422, 421,
+
+ 420, 419, 418, 416, 415, 414, 413, 410, 409, 408,
+ 407, 405, 404, 403, 402, 401, 400, 399, 398, 397,
+ 396, 395, 394, 393, 392, 391, 390, 389, 388, 387,
+ 386, 383, 381, 380, 379, 375, 373, 372, 370, 368,
+ 365, 364, 363, 362, 361, 360, 358, 357, 356, 355,
+ 354, 353, 352, 350, 348, 347, 346, 345, 344, 343,
+ 342, 340, 339, 338, 337, 336, 335, 334, 332, 331,
+ 330, 329, 327, 325, 324, 321, 319, 318, 317, 316,
+ 315, 314, 313, 312, 311, 309, 308, 306, 305, 304,
+ 303, 302, 301, 300, 299, 298, 296, 295, 294, 293,
+
+ 292, 291, 289, 287, 286, 285, 283, 282, 281, 280,
+ 279, 278, 276, 275, 274, 273, 272, 271, 267, 266,
+ 265, 264, 263, 262, 260, 258, 257, 255, 254, 252,
+ 251, 249, 248, 246, 245, 244, 243, 242, 239, 238,
+ 237, 236, 235, 232, 231, 229, 228, 227, 226, 225,
+ 224, 223, 222, 221, 220, 219, 217, 216, 213, 212,
+ 210, 207, 206, 205, 203, 202, 201, 200, 199, 198,
+ 197, 196, 195, 194, 193, 192, 191, 190, 189, 187,
+ 186, 185, 184, 183, 182, 180, 179, 178, 177, 176,
+ 175, 174, 171, 170, 169, 167, 165, 164, 163, 162,
+
+ 161, 160, 159, 158, 157, 156, 155, 154, 153, 152,
+ 151, 150, 149, 147, 146, 145, 144, 143, 142, 141,
+ 140, 139, 138, 137, 136, 135, 134, 133, 132, 131,
+ 130, 129, 128, 126, 125, 124, 123, 122, 121, 120,
+ 119, 118, 117, 116, 115, 114, 113, 112, 111, 110,
+ 109, 108, 107, 105, 104, 103, 102, 101, 100, 99,
+ 98, 97, 96, 95, 94, 93, 92, 91, 90, 89,
+ 88, 86, 85, 83, 82, 81, 80, 78, 77, 76,
+ 75, 74, 73, 70, 68, 66, 65, 64, 63, 62,
+ 61, 60, 59, 56, 54, 53, 52, 50, 49, 48,
+
+ 46, 44, 43, 42, 40, 39, 38, 37, 34, 31,
+ 26, 22, 17, 16, 9, 7, 3, 469, 469, 469,
469, 469, 469, 469, 469, 469, 469, 469, 469, 469,
469, 469, 469, 469, 469, 469, 469, 469, 469, 469,
469, 469, 469, 469, 469, 469, 469, 469, 469, 469,
- 469
+ 469, 469, 469
} ;
static yy_state_type yy_last_accepting_state;
@@ -637,7 +638,7 @@ char *yytext;
#line 1 "rclex.l"
#define INITIAL 0
#line 2 "rclex.l"
-/* Copyright 1997, 1998, 1999, 2001, 2002 Free Software Foundation, Inc.
+/* Copyright 1997, 1998, 1999, 2001, 2002, 2003 Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support.
This file is part of GNU Binutils.
@@ -704,11 +705,11 @@ static struct alloc_string *strings;
/* Local functions. */
-static void cpp_line PARAMS ((const char *));
-static char *handle_quotes PARAMS ((const char *, unsigned long *));
-static char *get_string PARAMS ((int));
+static void cpp_line (const char *);
+static char *handle_quotes (const char *, unsigned long *);
+static char *get_string (int);
-#line 712 "lex.yy.c"
+#line 713 "lex.yy.c"
/* Macros after this point can all be overridden by user definitions in
* section 1.
@@ -873,7 +874,7 @@ YY_DECL
#line 75 "rclex.l"
-#line 877 "lex.yy.c"
+#line 878 "lex.yy.c"
if ( yy_init )
{
@@ -930,7 +931,7 @@ yy_match:
yy_current_state = yy_nxt[yy_base[yy_current_state] + (unsigned int) yy_c];
++yy_cp;
}
- while ( yy_base[yy_current_state] != 516 );
+ while ( yy_base[yy_current_state] != 518 );
yy_find_action:
yy_act = yy_accept[yy_current_state];
@@ -1452,7 +1453,7 @@ YY_RULE_SETUP
#line 236 "rclex.l"
ECHO;
YY_BREAK
-#line 1456 "lex.yy.c"
+#line 1457 "lex.yy.c"
case YY_STATE_EOF(INITIAL):
yyterminate();
@@ -2346,7 +2347,7 @@ int main()
#ifndef yywrap
/* This is needed for some versions of lex. */
-int yywrap ()
+int yywrap (void)
{
return 1;
}
@@ -2355,8 +2356,7 @@ int yywrap ()
/* Handle a C preprocessor line. */
static void
-cpp_line (s)
- const char *s;
+cpp_line (const char *s)
{
int line;
char *send, *fn;
@@ -2411,9 +2411,7 @@ cpp_line (s)
merged separated by whitespace are merged, as in C. */
static char *
-handle_quotes (input, len)
- const char *input;
- unsigned long *len;
+handle_quotes (const char *input, unsigned long *len)
{
char *ret, *s;
const char *t;
@@ -2535,7 +2533,11 @@ handle_quotes (input, len)
++t;
assert (ISSPACE (*t));
while (ISSPACE (*t))
- ++t;
+ {
+ if ((*t) == '\n')
+ ++rc_lineno;
+ ++t;
+ }
if (*t == '\0')
break;
assert (*t == '"');
@@ -2553,8 +2555,7 @@ handle_quotes (input, len)
/* Allocate a string of a given length. */
static char *
-get_string (len)
- int len;
+get_string (int len)
{
struct alloc_string *as;
@@ -2571,7 +2572,7 @@ get_string (len)
when it no longer needs them. */
void
-rcparse_discard_strings ()
+rcparse_discard_strings (void)
{
struct alloc_string *as;
@@ -2592,7 +2593,7 @@ rcparse_discard_strings ()
/* Enter rcdata mode. */
void
-rcparse_rcdata ()
+rcparse_rcdata (void)
{
rcdata_mode = 1;
}
@@ -2600,7 +2601,7 @@ rcparse_rcdata ()
/* Go back to normal mode from rcdata mode. */
void
-rcparse_normal ()
+rcparse_normal (void)
{
rcdata_mode = 0;
}
diff --git a/contrib/binutils/binutils/rclex.l b/contrib/binutils/binutils/rclex.l
index 600e38e..2735cc1 100644
--- a/contrib/binutils/binutils/rclex.l
+++ b/contrib/binutils/binutils/rclex.l
@@ -1,5 +1,5 @@
%{ /* rclex.l -- lexer for Windows rc files parser */
-/* Copyright 1997, 1998, 1999, 2001, 2002 Free Software Foundation, Inc.
+/* Copyright 1997, 1998, 1999, 2001, 2002, 2003 Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support.
This file is part of GNU Binutils.
@@ -66,9 +66,9 @@ static struct alloc_string *strings;
/* Local functions. */
-static void cpp_line PARAMS ((const char *));
-static char *handle_quotes PARAMS ((const char *, unsigned long *));
-static char *get_string PARAMS ((int));
+static void cpp_line (const char *);
+static char *handle_quotes (const char *, unsigned long *);
+static char *get_string (int);
%}
@@ -196,7 +196,7 @@ static char *get_string PARAMS ((int));
MAYBE_RETURN (NUMBER);
}
-("\""[^\"\n]*"\""[ \t]*)+ {
+("\""[^\"\n]*"\""[ \t\n]*)+ {
char *s;
unsigned long length;
@@ -236,7 +236,7 @@ static char *get_string PARAMS ((int));
%%
#ifndef yywrap
/* This is needed for some versions of lex. */
-int yywrap ()
+int yywrap (void)
{
return 1;
}
@@ -245,8 +245,7 @@ int yywrap ()
/* Handle a C preprocessor line. */
static void
-cpp_line (s)
- const char *s;
+cpp_line (const char *s)
{
int line;
char *send, *fn;
@@ -301,9 +300,7 @@ cpp_line (s)
merged separated by whitespace are merged, as in C. */
static char *
-handle_quotes (input, len)
- const char *input;
- unsigned long *len;
+handle_quotes (const char *input, unsigned long *len)
{
char *ret, *s;
const char *t;
@@ -425,7 +422,11 @@ handle_quotes (input, len)
++t;
assert (ISSPACE (*t));
while (ISSPACE (*t))
- ++t;
+ {
+ if ((*t) == '\n')
+ ++rc_lineno;
+ ++t;
+ }
if (*t == '\0')
break;
assert (*t == '"');
@@ -443,8 +444,7 @@ handle_quotes (input, len)
/* Allocate a string of a given length. */
static char *
-get_string (len)
- int len;
+get_string (int len)
{
struct alloc_string *as;
@@ -461,7 +461,7 @@ get_string (len)
when it no longer needs them. */
void
-rcparse_discard_strings ()
+rcparse_discard_strings (void)
{
struct alloc_string *as;
@@ -482,7 +482,7 @@ rcparse_discard_strings ()
/* Enter rcdata mode. */
void
-rcparse_rcdata ()
+rcparse_rcdata (void)
{
rcdata_mode = 1;
}
@@ -490,7 +490,7 @@ rcparse_rcdata ()
/* Go back to normal mode from rcdata mode. */
void
-rcparse_normal ()
+rcparse_normal (void)
{
rcdata_mode = 0;
}
diff --git a/contrib/binutils/binutils/rdcoff.c b/contrib/binutils/binutils/rdcoff.c
index 2091964..84788e0 100644
--- a/contrib/binutils/binutils/rdcoff.c
+++ b/contrib/binutils/binutils/rdcoff.c
@@ -1,5 +1,5 @@
/* stabs.c -- Parse COFF debugging information
- Copyright 1996, 2000 Free Software Foundation, Inc.
+ Copyright 1996, 2000, 2002, 2003 Free Software Foundation, Inc.
Written by Ian Lance Taylor <ian@cygnus.com>.
This file is part of GNU Binutils.
@@ -82,30 +82,28 @@ struct coff_types
debug_type basic[T_MAX + 1];
};
-static debug_type *coff_get_slot PARAMS ((struct coff_types *, int));
+static debug_type *coff_get_slot (struct coff_types *, int);
static debug_type parse_coff_type
- PARAMS ((bfd *, struct coff_symbols *, struct coff_types *, long, int,
- union internal_auxent *, boolean, PTR));
+ (bfd *, struct coff_symbols *, struct coff_types *, long, int,
+ union internal_auxent *, bfd_boolean, void *);
static debug_type parse_coff_base_type
- PARAMS ((bfd *, struct coff_symbols *, struct coff_types *, long, int,
- union internal_auxent *, PTR));
+ (bfd *, struct coff_symbols *, struct coff_types *, long, int,
+ union internal_auxent *, void *);
static debug_type parse_coff_struct_type
- PARAMS ((bfd *, struct coff_symbols *, struct coff_types *, int,
- union internal_auxent *, PTR));
+ (bfd *, struct coff_symbols *, struct coff_types *, int,
+ union internal_auxent *, void *);
static debug_type parse_coff_enum_type
- PARAMS ((bfd *, struct coff_symbols *, struct coff_types *,
- union internal_auxent *, PTR));
-static boolean parse_coff_symbol
- PARAMS ((bfd *, struct coff_types *, asymbol *, long,
- struct internal_syment *, PTR, debug_type, boolean));
-static boolean external_coff_symbol_p PARAMS ((int sym_class));
+ (bfd *, struct coff_symbols *, struct coff_types *,
+ union internal_auxent *, void *);
+static bfd_boolean parse_coff_symbol
+ (bfd *, struct coff_types *, asymbol *, long, struct internal_syment *,
+ void *, debug_type, bfd_boolean);
+static bfd_boolean external_coff_symbol_p (int sym_class);
/* Return the slot for a type. */
static debug_type *
-coff_get_slot (types, indx)
- struct coff_types *types;
- int indx;
+coff_get_slot (struct coff_types *types, int indx)
{
struct coff_slots **pps;
@@ -134,16 +132,10 @@ coff_get_slot (types, indx)
/* Parse a COFF type code in NTYPE. */
static debug_type
-parse_coff_type (abfd, symbols, types, coff_symno, ntype, pauxent, useaux,
- dhandle)
- bfd *abfd;
- struct coff_symbols *symbols;
- struct coff_types *types;
- long coff_symno;
- int ntype;
- union internal_auxent *pauxent;
- boolean useaux;
- PTR dhandle;
+parse_coff_type (bfd *abfd, struct coff_symbols *symbols,
+ struct coff_types *types, long coff_symno, int ntype,
+ union internal_auxent *pauxent, bfd_boolean useaux,
+ void *dhandle)
{
debug_type type;
@@ -164,7 +156,7 @@ parse_coff_type (abfd, symbols, types, coff_symno, ntype, pauxent, useaux,
type = parse_coff_type (abfd, symbols, types, coff_symno, newtype,
pauxent, useaux, dhandle);
type = debug_make_function_type (dhandle, type, (debug_type *) NULL,
- false);
+ FALSE);
}
else if (ISARY (ntype))
{
@@ -190,14 +182,14 @@ parse_coff_type (abfd, symbols, types, coff_symno, ntype, pauxent, useaux,
}
type = parse_coff_type (abfd, symbols, types, coff_symno, newtype,
- pauxent, false, dhandle);
+ pauxent, FALSE, dhandle);
type = debug_make_array_type (dhandle, type,
parse_coff_base_type (abfd, symbols,
types,
coff_symno,
T_INT,
NULL, dhandle),
- 0, n - 1, false);
+ 0, n - 1, FALSE);
}
else
{
@@ -237,18 +229,12 @@ parse_coff_type (abfd, symbols, types, coff_symno, ntype, pauxent, useaux,
/* Parse a basic COFF type in NTYPE. */
static debug_type
-parse_coff_base_type (abfd, symbols, types, coff_symno, ntype, pauxent,
- dhandle)
- bfd *abfd;
- struct coff_symbols *symbols;
- struct coff_types *types;
- long coff_symno;
- int ntype;
- union internal_auxent *pauxent;
- PTR dhandle;
+parse_coff_base_type (bfd *abfd, struct coff_symbols *symbols,
+ struct coff_types *types, long coff_symno, int ntype,
+ union internal_auxent *pauxent, void *dhandle)
{
debug_type ret;
- boolean set_basic;
+ bfd_boolean set_basic;
const char *name;
debug_type *slot;
@@ -257,7 +243,7 @@ parse_coff_base_type (abfd, symbols, types, coff_symno, ntype, pauxent,
&& types->basic[ntype] != DEBUG_TYPE_NULL)
return types->basic[ntype];
- set_basic = true;
+ set_basic = TRUE;
name = NULL;
switch (ntype)
@@ -273,23 +259,23 @@ parse_coff_base_type (abfd, symbols, types, coff_symno, ntype, pauxent,
break;
case T_CHAR:
- ret = debug_make_int_type (dhandle, 1, false);
+ ret = debug_make_int_type (dhandle, 1, FALSE);
name = "char";
break;
case T_SHORT:
- ret = debug_make_int_type (dhandle, 2, false);
+ ret = debug_make_int_type (dhandle, 2, FALSE);
name = "short";
break;
case T_INT:
/* FIXME: Perhaps the size should depend upon the architecture. */
- ret = debug_make_int_type (dhandle, 4, false);
+ ret = debug_make_int_type (dhandle, 4, FALSE);
name = "int";
break;
case T_LONG:
- ret = debug_make_int_type (dhandle, 4, false);
+ ret = debug_make_int_type (dhandle, 4, FALSE);
name = "long";
break;
@@ -309,28 +295,28 @@ parse_coff_base_type (abfd, symbols, types, coff_symno, ntype, pauxent,
break;
case T_UCHAR:
- ret = debug_make_int_type (dhandle, 1, true);
+ ret = debug_make_int_type (dhandle, 1, TRUE);
name = "unsigned char";
break;
case T_USHORT:
- ret = debug_make_int_type (dhandle, 2, true);
+ ret = debug_make_int_type (dhandle, 2, TRUE);
name = "unsigned short";
break;
case T_UINT:
- ret = debug_make_int_type (dhandle, 4, true);
+ ret = debug_make_int_type (dhandle, 4, TRUE);
name = "unsigned int";
break;
case T_ULONG:
- ret = debug_make_int_type (dhandle, 4, true);
+ ret = debug_make_int_type (dhandle, 4, TRUE);
name = "unsigned long";
break;
case T_STRUCT:
if (pauxent == NULL)
- ret = debug_make_struct_type (dhandle, true, 0,
+ ret = debug_make_struct_type (dhandle, TRUE, 0,
(debug_field *) NULL);
else
ret = parse_coff_struct_type (abfd, symbols, types, ntype, pauxent,
@@ -339,12 +325,12 @@ parse_coff_base_type (abfd, symbols, types, coff_symno, ntype, pauxent,
slot = coff_get_slot (types, coff_symno);
*slot = ret;
- set_basic = false;
+ set_basic = FALSE;
break;
case T_UNION:
if (pauxent == NULL)
- ret = debug_make_struct_type (dhandle, false, 0, (debug_field *) NULL);
+ ret = debug_make_struct_type (dhandle, FALSE, 0, (debug_field *) NULL);
else
ret = parse_coff_struct_type (abfd, symbols, types, ntype, pauxent,
dhandle);
@@ -352,7 +338,7 @@ parse_coff_base_type (abfd, symbols, types, coff_symno, ntype, pauxent,
slot = coff_get_slot (types, coff_symno);
*slot = ret;
- set_basic = false;
+ set_basic = FALSE;
break;
case T_ENUM:
@@ -365,7 +351,7 @@ parse_coff_base_type (abfd, symbols, types, coff_symno, ntype, pauxent,
slot = coff_get_slot (types, coff_symno);
*slot = ret;
- set_basic = false;
+ set_basic = FALSE;
break;
}
@@ -383,19 +369,15 @@ parse_coff_base_type (abfd, symbols, types, coff_symno, ntype, pauxent,
/* Parse a struct type. */
static debug_type
-parse_coff_struct_type (abfd, symbols, types, ntype, pauxent, dhandle)
- bfd *abfd;
- struct coff_symbols *symbols;
- struct coff_types *types;
- int ntype;
- union internal_auxent *pauxent;
- PTR dhandle;
+parse_coff_struct_type (bfd *abfd, struct coff_symbols *symbols,
+ struct coff_types *types, int ntype,
+ union internal_auxent *pauxent, void *dhandle)
{
long symend;
int alloc;
debug_field *fields;
int count;
- boolean done;
+ bfd_boolean done;
symend = pauxent->x_sym.x_fcnary.x_fcn.x_endndx.l;
@@ -403,7 +385,7 @@ parse_coff_struct_type (abfd, symbols, types, ntype, pauxent, dhandle)
fields = (debug_field *) xmalloc (alloc * sizeof *fields);
count = 0;
- done = false;
+ done = FALSE;
while (! done
&& symbols->coff_symno < symend
&& symbols->symno < symbols->symcount)
@@ -456,7 +438,7 @@ parse_coff_struct_type (abfd, symbols, types, ntype, pauxent, dhandle)
break;
case C_EOS:
- done = true;
+ done = TRUE;
break;
}
@@ -466,7 +448,7 @@ parse_coff_struct_type (abfd, symbols, types, ntype, pauxent, dhandle)
debug_field f;
ftype = parse_coff_type (abfd, symbols, types, this_coff_symno,
- syment.n_type, psubaux, true, dhandle);
+ syment.n_type, psubaux, TRUE, dhandle);
f = debug_make_field (dhandle, bfd_asymbol_name (sym), ftype,
bitpos, bitsize, DEBUG_VISIBILITY_PUBLIC);
if (f == DEBUG_FIELD_NULL)
@@ -494,19 +476,16 @@ parse_coff_struct_type (abfd, symbols, types, ntype, pauxent, dhandle)
/* Parse an enum type. */
static debug_type
-parse_coff_enum_type (abfd, symbols, types, pauxent, dhandle)
- bfd *abfd;
- struct coff_symbols *symbols;
- struct coff_types *types ATTRIBUTE_UNUSED;
- union internal_auxent *pauxent;
- PTR dhandle;
+parse_coff_enum_type (bfd *abfd, struct coff_symbols *symbols,
+ struct coff_types *types ATTRIBUTE_UNUSED,
+ union internal_auxent *pauxent, void *dhandle)
{
long symend;
int alloc;
const char **names;
bfd_signed_vma *vals;
int count;
- boolean done;
+ bfd_boolean done;
symend = pauxent->x_sym.x_fcnary.x_fcn.x_endndx.l;
@@ -515,7 +494,7 @@ parse_coff_enum_type (abfd, symbols, types, pauxent, dhandle)
vals = (bfd_signed_vma *) xmalloc (alloc * sizeof *vals);
count = 0;
- done = false;
+ done = FALSE;
while (! done
&& symbols->coff_symno < symend
&& symbols->symno < symbols->symcount)
@@ -553,7 +532,7 @@ parse_coff_enum_type (abfd, symbols, types, pauxent, dhandle)
break;
case C_EOS:
- done = true;
+ done = TRUE;
break;
}
}
@@ -565,17 +544,11 @@ parse_coff_enum_type (abfd, symbols, types, pauxent, dhandle)
/* Handle a single COFF symbol. */
-static boolean
-parse_coff_symbol (abfd, types, sym, coff_symno, psyment, dhandle, type,
- within_function)
- bfd *abfd ATTRIBUTE_UNUSED;
- struct coff_types *types;
- asymbol *sym;
- long coff_symno;
- struct internal_syment *psyment;
- PTR dhandle;
- debug_type type;
- boolean within_function;
+static bfd_boolean
+parse_coff_symbol (bfd *abfd ATTRIBUTE_UNUSED, struct coff_types *types,
+ asymbol *sym, long coff_symno,
+ struct internal_syment *psyment, void *dhandle,
+ debug_type type, bfd_boolean within_function)
{
switch (psyment->n_sclass)
{
@@ -585,14 +558,14 @@ parse_coff_symbol (abfd, types, sym, coff_symno, psyment, dhandle, type,
case C_AUTO:
if (! debug_record_variable (dhandle, bfd_asymbol_name (sym), type,
DEBUG_LOCAL, bfd_asymbol_value (sym)))
- return false;
+ return FALSE;
break;
case C_WEAKEXT:
case C_EXT:
if (! debug_record_variable (dhandle, bfd_asymbol_name (sym), type,
DEBUG_GLOBAL, bfd_asymbol_value (sym)))
- return false;
+ return FALSE;
break;
case C_STAT:
@@ -601,14 +574,14 @@ parse_coff_symbol (abfd, types, sym, coff_symno, psyment, dhandle, type,
? DEBUG_LOCAL_STATIC
: DEBUG_STATIC),
bfd_asymbol_value (sym)))
- return false;
+ return FALSE;
break;
case C_REG:
/* FIXME: We may need to convert the register number. */
if (! debug_record_variable (dhandle, bfd_asymbol_name (sym), type,
DEBUG_REGISTER, bfd_asymbol_value (sym)))
- return false;
+ return FALSE;
break;
case C_LABEL:
@@ -617,20 +590,20 @@ parse_coff_symbol (abfd, types, sym, coff_symno, psyment, dhandle, type,
case C_ARG:
if (! debug_record_parameter (dhandle, bfd_asymbol_name (sym), type,
DEBUG_PARM_STACK, bfd_asymbol_value (sym)))
- return false;
+ return FALSE;
break;
case C_REGPARM:
/* FIXME: We may need to convert the register number. */
if (! debug_record_parameter (dhandle, bfd_asymbol_name (sym), type,
DEBUG_PARM_REG, bfd_asymbol_value (sym)))
- return false;
+ return FALSE;
break;
case C_TPDEF:
type = debug_name_type (dhandle, bfd_asymbol_name (sym), type);
if (type == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
break;
case C_STRTAG:
@@ -641,7 +614,7 @@ parse_coff_symbol (abfd, types, sym, coff_symno, psyment, dhandle, type,
type = debug_tag_type (dhandle, bfd_asymbol_name (sym), type);
if (type == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
/* Store the named type into the slot, so that references get
the name. */
@@ -654,35 +627,30 @@ parse_coff_symbol (abfd, types, sym, coff_symno, psyment, dhandle, type,
break;
}
- return true;
+ return TRUE;
}
/* Determine if a symbol has external visibility. */
-static boolean
-external_coff_symbol_p (sym_class)
- int sym_class;
+static bfd_boolean
+external_coff_symbol_p (int sym_class)
{
switch (sym_class)
{
case C_EXT:
case C_WEAKEXT:
- return true;
+ return TRUE;
default:
break;
}
- return false;
+ return FALSE;
}
/* This is the main routine. It looks through all the symbols and
handles them. */
-boolean
-parse_coff (abfd, syms, symcount, dhandle)
- bfd *abfd;
- asymbol **syms;
- long symcount;
- PTR dhandle;
+bfd_boolean
+parse_coff (bfd *abfd, asymbol **syms, long symcount, void *dhandle)
{
struct coff_symbols symbols;
struct coff_types types;
@@ -693,7 +661,7 @@ parse_coff (abfd, syms, symcount, dhandle)
int fntype;
bfd_vma fnend;
alent *linenos;
- boolean within_function;
+ bfd_boolean within_function;
long this_coff_symno;
symbols.syms = syms;
@@ -711,7 +679,7 @@ parse_coff (abfd, syms, symcount, dhandle)
fntype = 0;
fnend = 0;
linenos = NULL;
- within_function = false;
+ within_function = FALSE;
while (symbols.symno < symcount)
{
@@ -728,7 +696,7 @@ parse_coff (abfd, syms, symcount, dhandle)
{
non_fatal (_("bfd_coff_get_syment failed: %s"),
bfd_errmsg (bfd_get_error ()));
- return false;
+ return FALSE;
}
name = bfd_asymbol_name (sym);
@@ -748,7 +716,7 @@ parse_coff (abfd, syms, symcount, dhandle)
{
non_fatal (_("bfd_coff_get_auxent failed: %s"),
bfd_errmsg (bfd_get_error ()));
- return false;
+ return FALSE;
}
paux = &auxent;
}
@@ -758,7 +726,7 @@ parse_coff (abfd, syms, symcount, dhandle)
/* The last C_FILE symbol points to the first external
symbol. */
if (! debug_set_filename (dhandle, "*globals*"))
- return false;
+ return FALSE;
}
switch (syment.n_sclass)
@@ -776,7 +744,7 @@ parse_coff (abfd, syms, symcount, dhandle)
case C_FILE:
next_c_file = syment.n_value;
if (! debug_set_filename (dhandle, name))
- return false;
+ return FALSE;
break;
case C_STAT:
@@ -800,12 +768,12 @@ parse_coff (abfd, syms, symcount, dhandle)
break;
}
type = parse_coff_type (abfd, &symbols, &types, this_coff_symno,
- syment.n_type, paux, true, dhandle);
+ syment.n_type, paux, TRUE, dhandle);
if (type == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (! parse_coff_symbol (abfd, &types, sym, this_coff_symno, &syment,
dhandle, type, within_function))
- return false;
+ return FALSE;
break;
case C_FCN:
@@ -815,18 +783,18 @@ parse_coff (abfd, syms, symcount, dhandle)
{
non_fatal (_("%ld: .bf without preceding function"),
this_coff_symno);
- return false;
+ return FALSE;
}
type = parse_coff_type (abfd, &symbols, &types, this_coff_symno,
- DECREF (fntype), paux, false, dhandle);
+ DECREF (fntype), paux, FALSE, dhandle);
if (type == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (! debug_record_function (dhandle, fnname, type,
external_coff_symbol_p (fnclass),
bfd_asymbol_value (sym)))
- return false;
+ return FALSE;
if (linenos != NULL)
{
@@ -847,7 +815,7 @@ parse_coff (abfd, syms, symcount, dhandle)
if (! debug_record_line (dhandle,
linenos->line_number + base,
linenos->u.offset + addr))
- return false;
+ return FALSE;
++linenos;
}
}
@@ -857,23 +825,23 @@ parse_coff (abfd, syms, symcount, dhandle)
fnclass = 0;
fntype = 0;
- within_function = true;
+ within_function = TRUE;
}
else if (strcmp (name, ".ef") == 0)
{
if (! within_function)
{
non_fatal (_("%ld: unexpected .ef\n"), this_coff_symno);
- return false;
+ return FALSE;
}
if (bfd_asymbol_value (sym) > fnend)
fnend = bfd_asymbol_value (sym);
if (! debug_end_function (dhandle, fnend))
- return false;
+ return FALSE;
fnend = 0;
- within_function = false;
+ within_function = FALSE;
}
break;
@@ -881,26 +849,26 @@ parse_coff (abfd, syms, symcount, dhandle)
if (strcmp (name, ".bb") == 0)
{
if (! debug_start_block (dhandle, bfd_asymbol_value (sym)))
- return false;
+ return FALSE;
}
else if (strcmp (name, ".eb") == 0)
{
if (! debug_end_block (dhandle, bfd_asymbol_value (sym)))
- return false;
+ return FALSE;
}
break;
default:
type = parse_coff_type (abfd, &symbols, &types, this_coff_symno,
- syment.n_type, paux, true, dhandle);
+ syment.n_type, paux, TRUE, dhandle);
if (type == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (! parse_coff_symbol (abfd, &types, sym, this_coff_symno, &syment,
dhandle, type, within_function))
- return false;
+ return FALSE;
break;
}
}
- return true;
+ return TRUE;
}
diff --git a/contrib/binutils/binutils/rddbg.c b/contrib/binutils/binutils/rddbg.c
index 3430c02..75ddab5 100644
--- a/contrib/binutils/binutils/rddbg.c
+++ b/contrib/binutils/binutils/rddbg.c
@@ -1,5 +1,6 @@
/* rddbg.c -- Read debugging information into a generic form.
- Copyright 1995, 1996, 1997, 2000 Free Software Foundation, Inc.
+ Copyright 1995, 1996, 1997, 2000, 2002, 2003
+ Free Software Foundation, Inc.
Written by Ian Lance Taylor <ian@cygnus.com>.
This file is part of GNU Binutils.
@@ -29,26 +30,23 @@
#include "debug.h"
#include "budbg.h"
-static boolean read_section_stabs_debugging_info
- PARAMS ((bfd *, asymbol **, long, PTR, boolean *));
-static boolean read_symbol_stabs_debugging_info
- PARAMS ((bfd *, asymbol **, long, PTR, boolean *));
-static boolean read_ieee_debugging_info PARAMS ((bfd *, PTR, boolean *));
-static void save_stab PARAMS ((int, int, bfd_vma, const char *));
-static void stab_context PARAMS ((void));
-static void free_saved_stabs PARAMS ((void));
+static bfd_boolean read_section_stabs_debugging_info
+ (bfd *, asymbol **, long, void *, bfd_boolean *);
+static bfd_boolean read_symbol_stabs_debugging_info
+ (bfd *, asymbol **, long, void *, bfd_boolean *);
+static bfd_boolean read_ieee_debugging_info (bfd *, void *, bfd_boolean *);
+static void save_stab (int, int, bfd_vma, const char *);
+static void stab_context (void);
+static void free_saved_stabs (void);
/* Read debugging information from a BFD. Returns a generic debugging
pointer. */
-PTR
-read_debugging_info (abfd, syms, symcount)
- bfd *abfd;
- asymbol **syms;
- long symcount;
+void *
+read_debugging_info (bfd *abfd, asymbol **syms, long symcount)
{
- PTR dhandle;
- boolean found;
+ void *dhandle;
+ bfd_boolean found;
dhandle = debug_init ();
if (dhandle == NULL)
@@ -79,7 +77,7 @@ read_debugging_info (abfd, syms, symcount)
{
if (! parse_coff (abfd, syms, symcount, dhandle))
return NULL;
- found = true;
+ found = TRUE;
}
if (! found)
@@ -94,23 +92,20 @@ read_debugging_info (abfd, syms, symcount)
/* Read stabs in sections debugging information from a BFD. */
-static boolean
-read_section_stabs_debugging_info (abfd, syms, symcount, dhandle, pfound)
- bfd *abfd;
- asymbol **syms;
- long symcount;
- PTR dhandle;
- boolean *pfound;
+static bfd_boolean
+read_section_stabs_debugging_info (bfd *abfd, asymbol **syms, long symcount,
+ void *dhandle, bfd_boolean *pfound)
{
static struct
{
const char *secname;
const char *strsecname;
- } names[] = { { ".stab", ".stabstr" } };
+ } names[] = { { ".stab", ".stabstr" },
+ { "LC_SYMTAB.stabs", "LC_SYMTAB.stabstr" } };
unsigned int i;
- PTR shandle;
+ void *shandle;
- *pfound = false;
+ *pfound = FALSE;
shandle = NULL;
for (i = 0; i < sizeof names / sizeof names[0]; i++)
@@ -133,7 +128,7 @@ read_section_stabs_debugging_info (abfd, syms, symcount, dhandle, pfound)
fprintf (stderr, "%s: %s: %s\n",
bfd_get_filename (abfd), names[i].secname,
bfd_errmsg (bfd_get_error ()));
- return false;
+ return FALSE;
}
strsize = bfd_section_size (abfd, strsec);
@@ -143,17 +138,17 @@ read_section_stabs_debugging_info (abfd, syms, symcount, dhandle, pfound)
fprintf (stderr, "%s: %s: %s\n",
bfd_get_filename (abfd), names[i].strsecname,
bfd_errmsg (bfd_get_error ()));
- return false;
+ return FALSE;
}
if (shandle == NULL)
{
- shandle = start_stab (dhandle, abfd, true, syms, symcount);
+ shandle = start_stab (dhandle, abfd, TRUE, syms, symcount);
if (shandle == NULL)
- return false;
+ return FALSE;
}
- *pfound = true;
+ *pfound = TRUE;
stroff = 0;
next_stroff = 0;
@@ -176,7 +171,7 @@ read_section_stabs_debugging_info (abfd, syms, symcount, dhandle, pfound)
if (type == 0)
{
/* Special type 0 stabs indicate the offset to the
- next string table. */
+ next string table. */
stroff = next_stroff;
next_stroff += value;
}
@@ -188,9 +183,9 @@ read_section_stabs_debugging_info (abfd, syms, symcount, dhandle, pfound)
if (stroff + strx > strsize)
{
- fprintf (stderr, "%s: %s: stab entry %d is corrupt, strx = 0x%x, type = %d\n",
+ fprintf (stderr, "%s: %s: stab entry %ld is corrupt, strx = 0x%x, type = %d\n",
bfd_get_filename (abfd), names[i].secname,
- (stab - stabs) / 12, strx, type);
+ (long) (stab - stabs) / 12, strx, type);
continue;
}
@@ -211,8 +206,8 @@ read_section_stabs_debugging_info (abfd, syms, symcount, dhandle, pfound)
(const char *) NULL);
/* We have to restore the backslash, because, if
- the linker is hashing stabs strings, we may
- see the same string more than once. */
+ the linker is hashing stabs strings, we may
+ see the same string more than once. */
*p = '\\';
if (f != NULL)
@@ -226,12 +221,12 @@ read_section_stabs_debugging_info (abfd, syms, symcount, dhandle, pfound)
{
stab_context ();
free_saved_stabs ();
- return false;
+ return FALSE;
}
/* Don't free f, since I think the stabs code
- expects strings to hang around. This should be
- straightened out. FIXME. */
+ expects strings to hang around. This should be
+ straightened out. FIXME. */
}
}
@@ -239,31 +234,27 @@ read_section_stabs_debugging_info (abfd, syms, symcount, dhandle, pfound)
free (stabs);
/* Don't free strings, since I think the stabs code expects
- the strings to hang around. This should be straightened
- out. FIXME. */
+ the strings to hang around. This should be straightened
+ out. FIXME. */
}
}
if (shandle != NULL)
{
if (! finish_stab (dhandle, shandle))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Read stabs in the symbol table. */
-static boolean
-read_symbol_stabs_debugging_info (abfd, syms, symcount, dhandle, pfound)
- bfd *abfd;
- asymbol **syms;
- long symcount;
- PTR dhandle;
- boolean *pfound;
+static bfd_boolean
+read_symbol_stabs_debugging_info (bfd *abfd, asymbol **syms, long symcount,
+ void *dhandle, bfd_boolean *pfound)
{
- PTR shandle;
+ void *shandle;
asymbol **ps, **symend;
shandle = NULL;
@@ -281,12 +272,12 @@ read_symbol_stabs_debugging_info (abfd, syms, symcount, dhandle, pfound)
if (shandle == NULL)
{
- shandle = start_stab (dhandle, abfd, false, syms, symcount);
+ shandle = start_stab (dhandle, abfd, FALSE, syms, symcount);
if (shandle == NULL)
- return false;
+ return FALSE;
}
- *pfound = true;
+ *pfound = TRUE;
s = i.name;
f = NULL;
@@ -313,7 +304,7 @@ read_symbol_stabs_debugging_info (abfd, syms, symcount, dhandle, pfound)
{
stab_context ();
free_saved_stabs ();
- return false;
+ return FALSE;
}
/* Don't free f, since I think the stabs code expects
@@ -327,19 +318,16 @@ read_symbol_stabs_debugging_info (abfd, syms, symcount, dhandle, pfound)
if (shandle != NULL)
{
if (! finish_stab (dhandle, shandle))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Read IEEE debugging information. */
-static boolean
-read_ieee_debugging_info (abfd, dhandle, pfound)
- bfd *abfd;
- PTR dhandle;
- boolean *pfound;
+static bfd_boolean
+read_ieee_debugging_info (bfd *abfd, void *dhandle, bfd_boolean *pfound)
{
asection *dsec;
bfd_size_type size;
@@ -350,21 +338,21 @@ read_ieee_debugging_info (abfd, dhandle, pfound)
dsec = bfd_get_section_by_name (abfd, ".debug");
if (dsec == NULL)
- return true;
+ return TRUE;
size = bfd_section_size (abfd, dsec);
contents = (bfd_byte *) xmalloc (size);
if (! bfd_get_section_contents (abfd, dsec, contents, 0, size))
- return false;
+ return FALSE;
if (! parse_ieee (dhandle, abfd, contents, size))
- return false;
+ return FALSE;
free (contents);
- *pfound = true;
+ *pfound = TRUE;
- return true;
+ return TRUE;
}
/* Record stabs strings, so that we can give some context for errors. */
@@ -385,11 +373,7 @@ static int saved_stabs_index;
/* Save a stabs string. */
static void
-save_stab (type, desc, value, string)
- int type;
- int desc;
- bfd_vma value;
- const char *string;
+save_stab (int type, int desc, bfd_vma value, const char *string)
{
if (saved_stabs[saved_stabs_index].string != NULL)
free (saved_stabs[saved_stabs_index].string);
@@ -403,7 +387,7 @@ save_stab (type, desc, value, string)
/* Provide context for an error. */
static void
-stab_context ()
+stab_context (void)
{
int i;
@@ -441,7 +425,7 @@ stab_context ()
/* Free the saved stab strings. */
static void
-free_saved_stabs ()
+free_saved_stabs (void)
{
int i;
diff --git a/contrib/binutils/binutils/readelf.c b/contrib/binutils/binutils/readelf.c
index d397032..e95a501 100644
--- a/contrib/binutils/binutils/readelf.c
+++ b/contrib/binutils/binutils/readelf.c
@@ -1,5 +1,5 @@
/* readelf.c -- display contents of an ELF format file
- Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
Originally developed by Eric Youngdale <eric@andante.jic.com>
Modifications by Nick Clifton <nickc@redhat.com>
@@ -21,7 +21,25 @@
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
02111-1307, USA. */
+/* The difference between readelf and objdump:
+ Both programs are capabale of displaying the contents of ELF format files,
+ so why does the binutils project have two file dumpers ?
+
+ The reason is that objdump sees an ELF file through a BFD filter of the
+ world; if BFD has a bug where, say, it disagrees about a machine constant
+ in e_flags, then the odds are good that it will remain internally
+ consistent. The linker sees it the BFD way, objdump sees it the BFD way,
+ GAS sees it the BFD way. There was need for a tool to go find out what
+ the file actually says.
+
+ This is why the readelf program does not link against the BFD library - it
+ exists as an independent program to help verify the correct working of BFD.
+
+ There is also the case that readelf can provide more information about an
+ ELF file than is provided by objdump. In particular it can display DWARF
+ debugging information which (at the moment) objdump cannot. */
+
#include <assert.h>
#include <sys/types.h>
#include <sys/stat.h>
@@ -31,7 +49,7 @@
#if __GNUC__ >= 2
/* Define BFD64 here, even if our default architecture is 32 bit ELF
as this will allow us to read in and parse 64bit and 32bit ELF files.
- Only do this if we belive that the compiler can support a 64 bit
+ Only do this if we believe that the compiler can support a 64 bit
data type. For now we only rely on GCC being able to do this. */
#define BFD64
#endif
@@ -62,9 +80,11 @@
#include "elf/h8.h"
#include "elf/hppa.h"
#include "elf/i386.h"
+#include "elf/i370.h"
#include "elf/i860.h"
#include "elf/i960.h"
#include "elf/ia64.h"
+#include "elf/ip2k.h"
#include "elf/m32r.h"
#include "elf/m68k.h"
#include "elf/m68hc11.h"
@@ -73,9 +93,11 @@
#include "elf/mmix.h"
#include "elf/mn10200.h"
#include "elf/mn10300.h"
+#include "elf/msp430.h"
#include "elf/or32.h"
#include "elf/pj.h"
#include "elf/ppc.h"
+#include "elf/ppc64.h"
#include "elf/s390.h"
#include "elf/sh.h"
#include "elf/sparc.h"
@@ -83,62 +105,67 @@
#include "elf/vax.h"
#include "elf/x86-64.h"
#include "elf/xstormy16.h"
+#include "elf/iq2000.h"
+#include "elf/xtensa.h"
+
+#include "aout/ar.h"
#include "bucomm.h"
#include "getopt.h"
-
-char * program_name = "readelf";
-unsigned int dynamic_addr;
-bfd_size_type dynamic_size;
-unsigned int rela_addr;
-unsigned int rela_size;
-char * dynamic_strings;
-char * string_table;
-unsigned long string_table_length;
-unsigned long num_dynamic_syms;
-Elf_Internal_Sym * dynamic_symbols;
-Elf_Internal_Syminfo * dynamic_syminfo;
-unsigned long dynamic_syminfo_offset;
-unsigned int dynamic_syminfo_nent;
-char program_interpreter [64];
-int dynamic_info[DT_JMPREL + 1];
-int version_info[16];
-int loadaddr = 0;
-Elf_Internal_Ehdr elf_header;
-Elf_Internal_Shdr * section_headers;
-Elf_Internal_Dyn * dynamic_segment;
-Elf_Internal_Shdr * symtab_shndx_hdr;
-int show_name;
-int do_dynamic;
-int do_syms;
-int do_reloc;
-int do_sections;
-int do_segments;
-int do_unwind;
-int do_using_dynamic;
-int do_header;
-int do_dump;
-int do_version;
-int do_wide;
-int do_histogram;
-int do_debugging;
-int do_debug_info;
-int do_debug_abbrevs;
-int do_debug_lines;
-int do_debug_pubnames;
-int do_debug_aranges;
-int do_debug_frames;
-int do_debug_frames_interp;
-int do_debug_macinfo;
-int do_debug_str;
-int do_debug_loc;
-int do_arch;
-int do_notes;
-int is_32bit_elf;
+#include "libiberty.h"
+
+char *program_name = "readelf";
+long archive_file_offset;
+unsigned long archive_file_size;
+unsigned long dynamic_addr;
+bfd_size_type dynamic_size;
+char *dynamic_strings;
+char *string_table;
+unsigned long string_table_length;
+unsigned long num_dynamic_syms;
+Elf_Internal_Sym *dynamic_symbols;
+Elf_Internal_Syminfo *dynamic_syminfo;
+unsigned long dynamic_syminfo_offset;
+unsigned int dynamic_syminfo_nent;
+char program_interpreter[64];
+bfd_vma dynamic_info[DT_JMPREL + 1];
+bfd_vma version_info[16];
+Elf_Internal_Ehdr elf_header;
+Elf_Internal_Shdr *section_headers;
+Elf_Internal_Phdr *program_headers;
+Elf_Internal_Dyn *dynamic_segment;
+Elf_Internal_Shdr *symtab_shndx_hdr;
+int show_name;
+int do_dynamic;
+int do_syms;
+int do_reloc;
+int do_sections;
+int do_segments;
+int do_unwind;
+int do_using_dynamic;
+int do_header;
+int do_dump;
+int do_version;
+int do_wide;
+int do_histogram;
+int do_debugging;
+int do_debug_info;
+int do_debug_abbrevs;
+int do_debug_lines;
+int do_debug_pubnames;
+int do_debug_aranges;
+int do_debug_frames;
+int do_debug_frames_interp;
+int do_debug_macinfo;
+int do_debug_str;
+int do_debug_loc;
+int do_arch;
+int do_notes;
+int is_32bit_elf;
/* A dynamic array of flags indicating which sections require dumping. */
-char * dump_sects = NULL;
-unsigned int num_dump_sects = 0;
+char *dump_sects = NULL;
+unsigned int num_dump_sects = 0;
#define HEX_DUMP (1 << 0)
#define DISASS_DUMP (1 << 1)
@@ -157,121 +184,11 @@ typedef enum print_mode
}
print_mode;
-/* Forward declarations for dumb compilers. */
-static void print_vma PARAMS ((bfd_vma, print_mode));
-static void print_symbol PARAMS ((int, char *));
-static bfd_vma (* byte_get) PARAMS ((unsigned char *, int));
-static bfd_vma byte_get_little_endian PARAMS ((unsigned char *, int));
-static bfd_vma byte_get_big_endian PARAMS ((unsigned char *, int));
-static const char * get_mips_dynamic_type PARAMS ((unsigned long));
-static const char * get_sparc64_dynamic_type PARAMS ((unsigned long));
-static const char * get_ppc64_dynamic_type PARAMS ((unsigned long));
-static const char * get_parisc_dynamic_type PARAMS ((unsigned long));
-static const char * get_dynamic_type PARAMS ((unsigned long));
-static int slurp_rela_relocs PARAMS ((FILE *, unsigned long, unsigned long, Elf_Internal_Rela **, unsigned long *));
-static int slurp_rel_relocs PARAMS ((FILE *, unsigned long, unsigned long, Elf_Internal_Rel **, unsigned long *));
-static int dump_relocations PARAMS ((FILE *, unsigned long, unsigned long, Elf_Internal_Sym *, unsigned long, char *, int));
-static char * get_file_type PARAMS ((unsigned));
-static char * get_machine_name PARAMS ((unsigned));
-static void decode_ARM_machine_flags PARAMS ((unsigned, char []));
-static char * get_machine_flags PARAMS ((unsigned, unsigned));
-static const char * get_mips_segment_type PARAMS ((unsigned long));
-static const char * get_parisc_segment_type PARAMS ((unsigned long));
-static const char * get_ia64_segment_type PARAMS ((unsigned long));
-static const char * get_segment_type PARAMS ((unsigned long));
-static const char * get_mips_section_type_name PARAMS ((unsigned int));
-static const char * get_parisc_section_type_name PARAMS ((unsigned int));
-static const char * get_ia64_section_type_name PARAMS ((unsigned int));
-static const char * get_section_type_name PARAMS ((unsigned int));
-static const char * get_symbol_binding PARAMS ((unsigned int));
-static const char * get_symbol_type PARAMS ((unsigned int));
-static const char * get_symbol_visibility PARAMS ((unsigned int));
-static const char * get_symbol_index_type PARAMS ((unsigned int));
-static const char * get_dynamic_flags PARAMS ((bfd_vma));
-static void usage PARAMS ((void));
-static void parse_args PARAMS ((int, char **));
-static int process_file_header PARAMS ((void));
-static int process_program_headers PARAMS ((FILE *));
-static int process_section_headers PARAMS ((FILE *));
-static int process_unwind PARAMS ((FILE *));
-static void dynamic_segment_mips_val PARAMS ((Elf_Internal_Dyn *));
-static void dynamic_segment_parisc_val PARAMS ((Elf_Internal_Dyn *));
-static int process_dynamic_segment PARAMS ((FILE *));
-static int process_symbol_table PARAMS ((FILE *));
-static int process_syminfo PARAMS ((FILE *));
-static int process_section_contents PARAMS ((FILE *));
-static void process_mips_fpe_exception PARAMS ((int));
-static int process_mips_specific PARAMS ((FILE *));
-static int process_file PARAMS ((char *));
-static int process_relocs PARAMS ((FILE *));
-static int process_version_sections PARAMS ((FILE *));
-static char * get_ver_flags PARAMS ((unsigned int));
-static int get_32bit_section_headers PARAMS ((FILE *, unsigned int));
-static int get_64bit_section_headers PARAMS ((FILE *, unsigned int));
-static int get_32bit_program_headers PARAMS ((FILE *, Elf_Internal_Phdr *));
-static int get_64bit_program_headers PARAMS ((FILE *, Elf_Internal_Phdr *));
-static int get_file_header PARAMS ((FILE *));
-static Elf_Internal_Sym * get_32bit_elf_symbols PARAMS ((FILE *, Elf_Internal_Shdr *));
-static Elf_Internal_Sym * get_64bit_elf_symbols PARAMS ((FILE *, Elf_Internal_Shdr *));
-static const char * get_elf_section_flags PARAMS ((bfd_vma));
-static int * get_dynamic_data PARAMS ((FILE *, unsigned int));
-static int get_32bit_dynamic_segment PARAMS ((FILE *));
-static int get_64bit_dynamic_segment PARAMS ((FILE *));
-#ifdef SUPPORT_DISASSEMBLY
-static int disassemble_section PARAMS ((Elf32_Internal_Shdr *, FILE *));
-#endif
-static int dump_section PARAMS ((Elf32_Internal_Shdr *, FILE *));
-static int display_debug_section PARAMS ((Elf32_Internal_Shdr *, FILE *));
-static int display_debug_info PARAMS ((Elf32_Internal_Shdr *, unsigned char *, FILE *));
-static int display_debug_not_supported PARAMS ((Elf32_Internal_Shdr *, unsigned char *, FILE *));
-static int prescan_debug_info PARAMS ((Elf32_Internal_Shdr *, unsigned char *, FILE *));
-static int display_debug_lines PARAMS ((Elf32_Internal_Shdr *, unsigned char *, FILE *));
-static int display_debug_pubnames PARAMS ((Elf32_Internal_Shdr *, unsigned char *, FILE *));
-static int display_debug_abbrev PARAMS ((Elf32_Internal_Shdr *, unsigned char *, FILE *));
-static int display_debug_aranges PARAMS ((Elf32_Internal_Shdr *, unsigned char *, FILE *));
-static int display_debug_frames PARAMS ((Elf32_Internal_Shdr *, unsigned char *, FILE *));
-static int display_debug_macinfo PARAMS ((Elf32_Internal_Shdr *, unsigned char *, FILE *));
-static int display_debug_str PARAMS ((Elf32_Internal_Shdr *, unsigned char *, FILE *));
-static int display_debug_loc PARAMS ((Elf32_Internal_Shdr *, unsigned char *, FILE *));
-static unsigned char * process_abbrev_section PARAMS ((unsigned char *, unsigned char *));
-static void load_debug_str PARAMS ((FILE *));
-static void free_debug_str PARAMS ((void));
-static const char * fetch_indirect_string PARAMS ((unsigned long));
-static void load_debug_loc PARAMS ((FILE *));
-static void free_debug_loc PARAMS ((void));
-static unsigned long read_leb128 PARAMS ((unsigned char *, int *, int));
-static int process_extended_line_op PARAMS ((unsigned char *, int, int));
-static void reset_state_machine PARAMS ((int));
-static char * get_TAG_name PARAMS ((unsigned long));
-static char * get_AT_name PARAMS ((unsigned long));
-static char * get_FORM_name PARAMS ((unsigned long));
-static void free_abbrevs PARAMS ((void));
-static void add_abbrev PARAMS ((unsigned long, unsigned long, int));
-static void add_abbrev_attr PARAMS ((unsigned long, unsigned long));
-static unsigned char * read_and_display_attr PARAMS ((unsigned long, unsigned long, unsigned char *, unsigned long, unsigned long));
-static unsigned char * read_and_display_attr_value PARAMS ((unsigned long, unsigned long, unsigned char *, unsigned long, unsigned long));
-static unsigned char * display_block PARAMS ((unsigned char *, unsigned long));
-static void decode_location_expression PARAMS ((unsigned char *, unsigned int, unsigned long));
-static void request_dump PARAMS ((unsigned int, int));
-static const char * get_elf_class PARAMS ((unsigned int));
-static const char * get_data_encoding PARAMS ((unsigned int));
-static const char * get_osabi_name PARAMS ((unsigned int));
-static int guess_is_rela PARAMS ((unsigned long));
-static const char * get_note_type PARAMS ((unsigned int));
-static const char * get_netbsd_elfcore_note_type PARAMS ((unsigned int));
-static int process_note PARAMS ((Elf32_Internal_Note *));
-static int process_corefile_note_segment PARAMS ((FILE *, bfd_vma, bfd_vma));
-static int process_corefile_note_segments PARAMS ((FILE *));
-static int process_corefile_contents PARAMS ((FILE *));
-static int process_arch_specific PARAMS ((FILE *));
-static int process_gnu_liblist PARAMS ((FILE *));
+static bfd_vma (*byte_get) (unsigned char *, int);
+static void (*byte_put) (unsigned char *, bfd_vma, int);
typedef int Elf32_Word;
-#ifndef TRUE
-#define TRUE 1
-#define FALSE 0
-#endif
#define UNKNOWN -1
#define SECTION_NAME(X) ((X) == NULL ? "<none>" : \
@@ -294,7 +211,7 @@ typedef int Elf32_Word;
#define SECTION_HEADER(I) (section_headers + SECTION_HEADER_INDEX (I))
-#define DT_VERSIONTAGIDX(tag) (DT_VERNEEDNUM - (tag)) /* Reverse order! */
+#define DT_VERSIONTAGIDX(tag) (DT_VERNEEDNUM - (tag)) /* Reverse order! */
#define BYTE_GET(field) byte_get (field, sizeof (field))
@@ -320,56 +237,50 @@ typedef int Elf32_Word;
static void
-error VPARAMS ((const char *message, ...))
+error (const char *message, ...)
{
- VA_OPEN (args, message);
- VA_FIXEDARG (args, const char *, message);
+ va_list args;
+ va_start (args, message);
fprintf (stderr, _("%s: Error: "), program_name);
vfprintf (stderr, message, args);
- VA_CLOSE (args);
+ va_end (args);
}
static void
-warn VPARAMS ((const char *message, ...))
+warn (const char *message, ...)
{
- VA_OPEN (args, message);
- VA_FIXEDARG (args, const char *, message);
+ va_list args;
+ va_start (args, message);
fprintf (stderr, _("%s: Warning: "), program_name);
vfprintf (stderr, message, args);
- VA_CLOSE (args);
+ va_end (args);
}
-static PTR get_data PARAMS ((PTR, FILE *, long, size_t, const char *));
-
-static PTR
-get_data (var, file, offset, size, reason)
- PTR var;
- FILE *file;
- long offset;
- size_t size;
- const char *reason;
+static void *
+get_data (void *var, FILE *file, long offset, size_t size, const char *reason)
{
- PTR mvar;
+ void *mvar;
if (size == 0)
return NULL;
- if (fseek (file, offset, SEEK_SET))
+ if (fseek (file, archive_file_offset + offset, SEEK_SET))
{
- error (_("Unable to seek to %x for %s\n"), offset, reason);
+ error (_("Unable to seek to 0x%x for %s\n"),
+ archive_file_offset + offset, reason);
return NULL;
}
mvar = var;
if (mvar == NULL)
{
- mvar = (PTR) malloc (size);
+ mvar = malloc (size);
if (mvar == NULL)
{
- error (_("Out of memory allocating %d bytes for %s\n"),
+ error (_("Out of memory allocating 0x%x bytes for %s\n"),
size, reason);
return NULL;
}
@@ -377,7 +288,7 @@ get_data (var, file, offset, size, reason)
if (fread (mvar, size, 1, file) != 1)
{
- error (_("Unable to read in %d bytes of %s\n"), size, reason);
+ error (_("Unable to read in 0x%x bytes of %s\n"), size, reason);
if (mvar != var)
free (mvar);
return NULL;
@@ -387,31 +298,29 @@ get_data (var, file, offset, size, reason)
}
static bfd_vma
-byte_get_little_endian (field, size)
- unsigned char * field;
- int size;
+byte_get_little_endian (unsigned char *field, int size)
{
switch (size)
{
case 1:
- return * field;
+ return *field;
case 2:
- return ((unsigned int) (field [0]))
- | (((unsigned int) (field [1])) << 8);
+ return ((unsigned int) (field[0]))
+ | (((unsigned int) (field[1])) << 8);
#ifndef BFD64
case 8:
/* We want to extract data from an 8 byte wide field and
place it into a 4 byte wide field. Since this is a little
- endian source we can juts use the 4 byte extraction code. */
+ endian source we can just use the 4 byte extraction code. */
/* Fall through. */
#endif
case 4:
- return ((unsigned long) (field [0]))
- | (((unsigned long) (field [1])) << 8)
- | (((unsigned long) (field [2])) << 16)
- | (((unsigned long) (field [3])) << 24);
+ return ((unsigned long) (field[0]))
+ | (((unsigned long) (field[1])) << 8)
+ | (((unsigned long) (field[2])) << 16)
+ | (((unsigned long) (field[3])) << 24);
#ifdef BFD64
case 8:
@@ -419,15 +328,15 @@ byte_get_little_endian (field, size)
/* This is a special case, generated by the BYTE_GET8 macro.
It means that we are loading an 8 byte value from a field
in an external structure into an 8 byte value in a field
- in an internal strcuture. */
- return ((bfd_vma) (field [0]))
- | (((bfd_vma) (field [1])) << 8)
- | (((bfd_vma) (field [2])) << 16)
- | (((bfd_vma) (field [3])) << 24)
- | (((bfd_vma) (field [4])) << 32)
- | (((bfd_vma) (field [5])) << 40)
- | (((bfd_vma) (field [6])) << 48)
- | (((bfd_vma) (field [7])) << 56);
+ in an internal structure. */
+ return ((bfd_vma) (field[0]))
+ | (((bfd_vma) (field[1])) << 8)
+ | (((bfd_vma) (field[2])) << 16)
+ | (((bfd_vma) (field[3])) << 24)
+ | (((bfd_vma) (field[4])) << 32)
+ | (((bfd_vma) (field[5])) << 40)
+ | (((bfd_vma) (field[6])) << 48)
+ | (((bfd_vma) (field[7])) << 56);
#endif
default:
error (_("Unhandled data length: %d\n"), size);
@@ -435,11 +344,58 @@ byte_get_little_endian (field, size)
}
}
+static bfd_vma
+byte_get_signed (unsigned char *field, int size)
+{
+ bfd_vma x = byte_get (field, size);
+
+ switch (size)
+ {
+ case 1:
+ return (x ^ 0x80) - 0x80;
+ case 2:
+ return (x ^ 0x8000) - 0x8000;
+ case 4:
+ return (x ^ 0x80000000) - 0x80000000;
+ case 8:
+ case -8:
+ return x;
+ default:
+ abort ();
+ }
+}
+
+static void
+byte_put_little_endian (unsigned char *field, bfd_vma value, int size)
+{
+ switch (size)
+ {
+ case 8:
+ field[7] = (((value >> 24) >> 24) >> 8) & 0xff;
+ field[6] = ((value >> 24) >> 24) & 0xff;
+ field[5] = ((value >> 24) >> 16) & 0xff;
+ field[4] = ((value >> 24) >> 8) & 0xff;
+ /* Fall through. */
+ case 4:
+ field[3] = (value >> 24) & 0xff;
+ field[2] = (value >> 16) & 0xff;
+ /* Fall through. */
+ case 2:
+ field[1] = (value >> 8) & 0xff;
+ /* Fall through. */
+ case 1:
+ field[0] = value & 0xff;
+ break;
+
+ default:
+ error (_("Unhandled data length: %d\n"), size);
+ abort ();
+ }
+}
+
/* Print a VMA value. */
static void
-print_vma (vma, mode)
- bfd_vma vma;
- print_mode mode;
+print_vma (bfd_vma vma, print_mode mode)
{
#ifdef BFD64
if (is_32bit_elf)
@@ -447,13 +403,34 @@ print_vma (vma, mode)
{
switch (mode)
{
- case FULL_HEX: printf ("0x"); /* drop through */
- case LONG_HEX: printf ("%8.8lx", (unsigned long) vma); break;
- case PREFIX_HEX: printf ("0x"); /* drop through */
- case HEX: printf ("%lx", (unsigned long) vma); break;
- case DEC: printf ("%ld", (unsigned long) vma); break;
- case DEC_5: printf ("%5ld", (long) vma); break;
- case UNSIGNED: printf ("%lu", (unsigned long) vma); break;
+ case FULL_HEX:
+ printf ("0x");
+ /* Drop through. */
+ case LONG_HEX:
+ printf ("%8.8lx", (unsigned long) vma);
+ break;
+
+ case DEC_5:
+ if (vma <= 99999)
+ {
+ printf ("%5ld", (long) vma);
+ break;
+ }
+ /* Drop through. */
+ case PREFIX_HEX:
+ printf ("0x");
+ /* Drop through. */
+ case HEX:
+ printf ("%lx", (unsigned long) vma);
+ break;
+
+ case DEC:
+ printf ("%ld", (unsigned long) vma);
+ break;
+
+ case UNSIGNED:
+ printf ("%lu", (unsigned long) vma);
+ break;
}
}
#ifdef BFD64
@@ -463,7 +440,7 @@ print_vma (vma, mode)
{
case FULL_HEX:
printf ("0x");
- /* drop through */
+ /* Drop through. */
case LONG_HEX:
printf_vma (vma);
@@ -471,7 +448,7 @@ print_vma (vma, mode)
case PREFIX_HEX:
printf ("0x");
- /* drop through */
+ /* Drop through. */
case HEX:
#if BFD_HOST_64BIT_LONG
@@ -498,13 +475,18 @@ print_vma (vma, mode)
case DEC_5:
#if BFD_HOST_64BIT_LONG
- printf ("%5ld", vma);
+ if (vma <= 99999)
+ printf ("%5ld", vma);
+ else
+ printf ("%#lx", vma);
#else
if (_bfd_int64_high (vma))
/* ugg */
printf ("++%ld", _bfd_int64_low (vma));
- else
+ else if (vma <= 99999)
printf ("%5ld", _bfd_int64_low (vma));
+ else
+ printf ("%#lx", _bfd_int64_low (vma));
#endif
break;
@@ -531,12 +513,10 @@ print_vma (vma, mode)
truncating or padding as necessary. */
static void
-print_symbol (width, symbol)
- int width;
- char * symbol;
+print_symbol (int width, const char *symbol)
{
if (do_wide)
- printf (symbol);
+ printf ("%s", symbol);
else if (width < 0)
printf ("%-*.*s", width, width, symbol);
else
@@ -544,47 +524,45 @@ print_symbol (width, symbol)
}
static bfd_vma
-byte_get_big_endian (field, size)
- unsigned char * field;
- int size;
+byte_get_big_endian (unsigned char *field, int size)
{
switch (size)
{
case 1:
- return * field;
+ return *field;
case 2:
- return ((unsigned int) (field [1])) | (((int) (field [0])) << 8);
+ return ((unsigned int) (field[1])) | (((int) (field[0])) << 8);
case 4:
- return ((unsigned long) (field [3]))
- | (((unsigned long) (field [2])) << 8)
- | (((unsigned long) (field [1])) << 16)
- | (((unsigned long) (field [0])) << 24);
+ return ((unsigned long) (field[3]))
+ | (((unsigned long) (field[2])) << 8)
+ | (((unsigned long) (field[1])) << 16)
+ | (((unsigned long) (field[0])) << 24);
#ifndef BFD64
case 8:
/* Although we are extracing data from an 8 byte wide field, we
are returning only 4 bytes of data. */
- return ((unsigned long) (field [7]))
- | (((unsigned long) (field [6])) << 8)
- | (((unsigned long) (field [5])) << 16)
- | (((unsigned long) (field [4])) << 24);
+ return ((unsigned long) (field[7]))
+ | (((unsigned long) (field[6])) << 8)
+ | (((unsigned long) (field[5])) << 16)
+ | (((unsigned long) (field[4])) << 24);
#else
case 8:
case -8:
/* This is a special case, generated by the BYTE_GET8 macro.
It means that we are loading an 8 byte value from a field
in an external structure into an 8 byte value in a field
- in an internal strcuture. */
- return ((bfd_vma) (field [7]))
- | (((bfd_vma) (field [6])) << 8)
- | (((bfd_vma) (field [5])) << 16)
- | (((bfd_vma) (field [4])) << 24)
- | (((bfd_vma) (field [3])) << 32)
- | (((bfd_vma) (field [2])) << 40)
- | (((bfd_vma) (field [1])) << 48)
- | (((bfd_vma) (field [0])) << 56);
+ in an internal structure. */
+ return ((bfd_vma) (field[7]))
+ | (((bfd_vma) (field[6])) << 8)
+ | (((bfd_vma) (field[5])) << 16)
+ | (((bfd_vma) (field[4])) << 24)
+ | (((bfd_vma) (field[3])) << 32)
+ | (((bfd_vma) (field[2])) << 40)
+ | (((bfd_vma) (field[1])) << 48)
+ | (((bfd_vma) (field[0])) << 56);
#endif
default:
@@ -593,11 +571,42 @@ byte_get_big_endian (field, size)
}
}
+static void
+byte_put_big_endian (unsigned char *field, bfd_vma value, int size)
+{
+ switch (size)
+ {
+ case 8:
+ field[7] = value & 0xff;
+ field[6] = (value >> 8) & 0xff;
+ field[5] = (value >> 16) & 0xff;
+ field[4] = (value >> 24) & 0xff;
+ value >>= 16;
+ value >>= 16;
+ /* Fall through. */
+ case 4:
+ field[3] = value & 0xff;
+ field[2] = (value >> 8) & 0xff;
+ value >>= 16;
+ /* Fall through. */
+ case 2:
+ field[1] = value & 0xff;
+ value >>= 8;
+ /* Fall through. */
+ case 1:
+ field[0] = value & 0xff;
+ break;
+
+ default:
+ error (_("Unhandled data length: %d\n"), size);
+ abort ();
+ }
+}
+
/* Guess the relocation size commonly used by the specific machines. */
static int
-guess_is_rela (e_machine)
- unsigned long e_machine;
+guess_is_rela (unsigned long e_machine)
{
switch (e_machine)
{
@@ -609,7 +618,6 @@ guess_is_rela (e_machine)
case EM_DLX:
case EM_OPENRISC:
case EM_OR32:
- case EM_M32R:
case EM_CYGNUS_M32R:
case EM_D10V:
case EM_CYGNUS_D10V:
@@ -650,8 +658,16 @@ guess_is_rela (e_machine)
case EM_S390:
case EM_S390_OLD:
case EM_MMIX:
+ case EM_MSP430:
+ case EM_MSP430_OLD:
case EM_XSTORMY16:
case EM_VAX:
+ case EM_IP2K:
+ case EM_IP2K_OLD:
+ case EM_IQ2000:
+ case EM_XTENSA:
+ case EM_XTENSA_OLD:
+ case EM_M32R:
return TRUE;
case EM_MMA:
@@ -678,12 +694,11 @@ guess_is_rela (e_machine)
}
static int
-slurp_rela_relocs (file, rel_offset, rel_size, relasp, nrelasp)
- FILE *file;
- unsigned long rel_offset;
- unsigned long rel_size;
- Elf_Internal_Rela **relasp;
- unsigned long *nrelasp;
+slurp_rela_relocs (FILE *file,
+ unsigned long rel_offset,
+ unsigned long rel_size,
+ Elf_Internal_Rela **relasp,
+ unsigned long *nrelasp)
{
Elf_Internal_Rela *relas;
unsigned long nrelas;
@@ -691,17 +706,15 @@ slurp_rela_relocs (file, rel_offset, rel_size, relasp, nrelasp)
if (is_32bit_elf)
{
- Elf32_External_Rela * erelas;
+ Elf32_External_Rela *erelas;
- erelas = (Elf32_External_Rela *) get_data (NULL, file, rel_offset,
- rel_size, _("relocs"));
+ erelas = get_data (NULL, file, rel_offset, rel_size, _("relocs"));
if (!erelas)
return 0;
nrelas = rel_size / sizeof (Elf32_External_Rela);
- relas = (Elf_Internal_Rela *)
- malloc (nrelas * sizeof (Elf_Internal_Rela));
+ relas = malloc (nrelas * sizeof (Elf_Internal_Rela));
if (relas == NULL)
{
@@ -720,17 +733,15 @@ slurp_rela_relocs (file, rel_offset, rel_size, relasp, nrelasp)
}
else
{
- Elf64_External_Rela * erelas;
+ Elf64_External_Rela *erelas;
- erelas = (Elf64_External_Rela *) get_data (NULL, file, rel_offset,
- rel_size, _("relocs"));
+ erelas = get_data (NULL, file, rel_offset, rel_size, _("relocs"));
if (!erelas)
return 0;
nrelas = rel_size / sizeof (Elf64_External_Rela);
- relas = (Elf_Internal_Rela *)
- malloc (nrelas * sizeof (Elf_Internal_Rela));
+ relas = malloc (nrelas * sizeof (Elf_Internal_Rela));
if (relas == NULL)
{
@@ -753,29 +764,27 @@ slurp_rela_relocs (file, rel_offset, rel_size, relasp, nrelasp)
}
static int
-slurp_rel_relocs (file, rel_offset, rel_size, relsp, nrelsp)
- FILE *file;
- unsigned long rel_offset;
- unsigned long rel_size;
- Elf_Internal_Rel **relsp;
- unsigned long *nrelsp;
-{
- Elf_Internal_Rel *rels;
+slurp_rel_relocs (FILE *file,
+ unsigned long rel_offset,
+ unsigned long rel_size,
+ Elf_Internal_Rela **relsp,
+ unsigned long *nrelsp)
+{
+ Elf_Internal_Rela *rels;
unsigned long nrels;
unsigned int i;
if (is_32bit_elf)
{
- Elf32_External_Rel * erels;
+ Elf32_External_Rel *erels;
- erels = (Elf32_External_Rel *) get_data (NULL, file, rel_offset,
- rel_size, _("relocs"));
+ erels = get_data (NULL, file, rel_offset, rel_size, _("relocs"));
if (!erels)
return 0;
nrels = rel_size / sizeof (Elf32_External_Rel);
- rels = (Elf_Internal_Rel *) malloc (nrels * sizeof (Elf_Internal_Rel));
+ rels = malloc (nrels * sizeof (Elf_Internal_Rela));
if (rels == NULL)
{
@@ -787,22 +796,22 @@ slurp_rel_relocs (file, rel_offset, rel_size, relsp, nrelsp)
{
rels[i].r_offset = BYTE_GET (erels[i].r_offset);
rels[i].r_info = BYTE_GET (erels[i].r_info);
+ rels[i].r_addend = 0;
}
free (erels);
}
else
{
- Elf64_External_Rel * erels;
+ Elf64_External_Rel *erels;
- erels = (Elf64_External_Rel *) get_data (NULL, file, rel_offset,
- rel_size, _("relocs"));
+ erels = get_data (NULL, file, rel_offset, rel_size, _("relocs"));
if (!erels)
return 0;
nrels = rel_size / sizeof (Elf64_External_Rel);
- rels = (Elf_Internal_Rel *) malloc (nrels * sizeof (Elf_Internal_Rel));
+ rels = malloc (nrels * sizeof (Elf_Internal_Rela));
if (rels == NULL)
{
@@ -814,6 +823,7 @@ slurp_rel_relocs (file, rel_offset, rel_size, relsp, nrelsp)
{
rels[i].r_offset = BYTE_GET8 (erels[i].r_offset);
rels[i].r_info = BYTE_GET8 (erels[i].r_info);
+ rels[i].r_addend = 0;
}
free (erels);
@@ -823,20 +833,20 @@ slurp_rel_relocs (file, rel_offset, rel_size, relsp, nrelsp)
return 1;
}
-/* Display the contents of the relocation data found at the specified offset. */
+/* Display the contents of the relocation data found at the specified
+ offset. */
+
static int
-dump_relocations (file, rel_offset, rel_size, symtab, nsyms, strtab, is_rela)
- FILE * file;
- unsigned long rel_offset;
- unsigned long rel_size;
- Elf_Internal_Sym * symtab;
- unsigned long nsyms;
- char * strtab;
- int is_rela;
+dump_relocations (FILE *file,
+ unsigned long rel_offset,
+ unsigned long rel_size,
+ Elf_Internal_Sym *symtab,
+ unsigned long nsyms,
+ char *strtab,
+ int is_rela)
{
- unsigned int i;
- Elf_Internal_Rel * rels;
- Elf_Internal_Rela * relas;
+ unsigned int i;
+ Elf_Internal_Rela *rels;
if (is_rela == UNKNOWN)
@@ -844,7 +854,7 @@ dump_relocations (file, rel_offset, rel_size, symtab, nsyms, strtab, is_rela)
if (is_rela)
{
- if (!slurp_rela_relocs (file, rel_offset, rel_size, &relas, &rel_size))
+ if (!slurp_rela_relocs (file, rel_offset, rel_size, &rels, &rel_size))
return 0;
}
else
@@ -875,14 +885,14 @@ dump_relocations (file, rel_offset, rel_size, symtab, nsyms, strtab, is_rela)
if (is_rela)
{
if (do_wide)
- printf (_(" Offset Info Type Symbol's Value Symbol's Name + Addend\n"));
+ printf (_(" Offset Info Type Symbol's Value Symbol's Name + Addend\n"));
else
printf (_(" Offset Info Type Sym. Value Sym. Name + Addend\n"));
}
else
{
if (do_wide)
- printf (_(" Offset Info Type Symbol's Value Symbol's Name\n"));
+ printf (_(" Offset Info Type Symbol's Value Symbol's Name\n"));
else
printf (_(" Offset Info Type Sym. Value Sym. Name\n"));
}
@@ -890,26 +900,18 @@ dump_relocations (file, rel_offset, rel_size, symtab, nsyms, strtab, is_rela)
for (i = 0; i < rel_size; i++)
{
- const char * rtype;
- const char * rtype2 = NULL;
- const char * rtype3 = NULL;
- bfd_vma offset;
- bfd_vma info;
- bfd_vma symtab_index;
- bfd_vma type;
- bfd_vma type2 = (bfd_vma) NULL;
- bfd_vma type3 = (bfd_vma) NULL;
+ const char *rtype;
+ const char *rtype2 = NULL;
+ const char *rtype3 = NULL;
+ bfd_vma offset;
+ bfd_vma info;
+ bfd_vma symtab_index;
+ bfd_vma type;
+ bfd_vma type2 = 0;
+ bfd_vma type3 = 0;
- if (is_rela)
- {
- offset = relas [i].r_offset;
- info = relas [i].r_info;
- }
- else
- {
- offset = rels [i].r_offset;
- info = rels [i].r_info;
- }
+ offset = rels[i].r_offset;
+ info = rels[i].r_info;
if (is_32bit_elf)
{
@@ -918,8 +920,22 @@ dump_relocations (file, rel_offset, rel_size, symtab, nsyms, strtab, is_rela)
}
else
{
+ /* The #ifdef BFD64 below is to prevent a compile time warning.
+ We know that if we do not have a 64 bit data type that we
+ will never execute this code anyway. */
+#ifdef BFD64
if (elf_header.e_machine == EM_MIPS)
{
+ /* In little-endian objects, r_info isn't really a 64-bit
+ little-endian value: it has a 32-bit little-endian
+ symbol index followed by four individual byte fields.
+ Reorder INFO accordingly. */
+ if (elf_header.e_ident[EI_DATA] != ELFDATA2MSB)
+ info = (((info & 0xffffffff) << 32)
+ | ((info >> 56) & 0xff)
+ | ((info >> 40) & 0xff00)
+ | ((info >> 24) & 0xff0000)
+ | ((info >> 8) & 0xff000000));
type = ELF64_MIPS_R_TYPE (info);
type2 = ELF64_MIPS_R_TYPE2 (info);
type3 = ELF64_MIPS_R_TYPE3 (info);
@@ -928,10 +944,7 @@ dump_relocations (file, rel_offset, rel_size, symtab, nsyms, strtab, is_rela)
type = ELF64_R_TYPE_ID (info);
else
type = ELF64_R_TYPE (info);
- /* The #ifdef BFD64 below is to prevent a compile time warning.
- We know that if we do not have a 64 bit data type that we
- will never execute this code anyway. */
-#ifdef BFD64
+
symtab_index = ELF64_R_SYM (info);
#endif
}
@@ -1053,11 +1066,19 @@ dump_relocations (file, rel_offset, rel_size, symtab, nsyms, strtab, is_rela)
rtype = elf_mmix_reloc_type (type);
break;
+ case EM_MSP430:
+ case EM_MSP430_OLD:
+ rtype = elf_msp430_reloc_type (type);
+ break;
+
case EM_PPC:
- case EM_PPC64:
rtype = elf_ppc_reloc_type (type);
break;
+ case EM_PPC64:
+ rtype = elf_ppc64_reloc_type (type);
+ break;
+
case EM_MIPS:
case EM_MIPS_RS3_LE:
rtype = elf_mips_reloc_type (type);
@@ -1115,6 +1136,10 @@ dump_relocations (file, rel_offset, rel_size, symtab, nsyms, strtab, is_rela)
rtype = elf_x86_64_reloc_type (type);
break;
+ case EM_S370:
+ rtype = i370_reloc_type (type);
+ break;
+
case EM_S390_OLD:
case EM_S390:
rtype = elf_s390_reloc_type (type);
@@ -1127,6 +1152,20 @@ dump_relocations (file, rel_offset, rel_size, symtab, nsyms, strtab, is_rela)
case EM_VAX:
rtype = elf_vax_reloc_type (type);
break;
+
+ case EM_IP2K:
+ case EM_IP2K_OLD:
+ rtype = elf_ip2k_reloc_type (type);
+ break;
+
+ case EM_IQ2000:
+ rtype = elf_iq2000_reloc_type (type);
+ break;
+
+ case EM_XTENSA_OLD:
+ case EM_XTENSA:
+ rtype = elf_xtensa_reloc_type (type);
+ break;
}
if (rtype == NULL)
@@ -1136,7 +1175,7 @@ dump_relocations (file, rel_offset, rel_size, symtab, nsyms, strtab, is_rela)
printf (_("unrecognized: %-7lx"), type);
#endif
else
- printf (do_wide ? "%-21.21s" : "%-17.17s", rtype);
+ printf (do_wide ? "%-22.22s" : "%-17.17s", rtype);
if (symtab_index)
{
@@ -1144,7 +1183,7 @@ dump_relocations (file, rel_offset, rel_size, symtab, nsyms, strtab, is_rela)
printf (" bad symbol index: %08lx", (unsigned long) symtab_index);
else
{
- Elf_Internal_Sym * psym;
+ Elf_Internal_Sym *psym;
psym = symtab + symtab_index;
@@ -1153,20 +1192,52 @@ dump_relocations (file, rel_offset, rel_size, symtab, nsyms, strtab, is_rela)
printf (is_32bit_elf ? " " : " ");
if (psym->st_name == 0)
- print_symbol (22, SECTION_NAME (section_headers + psym->st_shndx));
+ {
+ const char *sec_name = "<null>";
+ char name_buf[40];
+
+ if (ELF_ST_TYPE (psym->st_info) == STT_SECTION)
+ {
+ bfd_vma sec_index = (bfd_vma) -1;
+
+ if (psym->st_shndx < SHN_LORESERVE)
+ sec_index = psym->st_shndx;
+ else if (psym->st_shndx > SHN_LORESERVE)
+ sec_index = psym->st_shndx - (SHN_HIRESERVE + 1
+ - SHN_LORESERVE);
+
+ if (sec_index != (bfd_vma) -1)
+ sec_name = SECTION_NAME (section_headers + sec_index);
+ else if (psym->st_shndx == SHN_ABS)
+ sec_name = "ABS";
+ else if (psym->st_shndx == SHN_COMMON)
+ sec_name = "COMMON";
+ else if (elf_header.e_machine == EM_IA_64
+ && elf_header.e_ident[EI_OSABI] == ELFOSABI_HPUX
+ && psym->st_shndx == SHN_IA_64_ANSI_COMMON)
+ sec_name = "ANSI_COM";
+ else
+ {
+ sprintf (name_buf, "<section 0x%x>",
+ (unsigned int) psym->st_shndx);
+ sec_name = name_buf;
+ }
+ }
+ print_symbol (22, sec_name);
+ }
else if (strtab == NULL)
printf (_("<string table index %3ld>"), psym->st_name);
else
print_symbol (22, strtab + psym->st_name);
if (is_rela)
- printf (" + %lx", (unsigned long) relas [i].r_addend);
+ printf (" + %lx", (unsigned long) rels[i].r_addend);
}
}
else if (is_rela)
{
printf ("%*c", is_32bit_elf ? (do_wide ? 34 : 28) : (do_wide ? 26 : 20), ' ');
- print_vma (relas[i].r_addend, LONG_HEX);
+ print_vma (rels[i].r_addend, LONG_HEX);
}
if (elf_header.e_machine == EM_SPARCV9
@@ -1203,17 +1274,13 @@ dump_relocations (file, rel_offset, rel_size, symtab, nsyms, strtab, is_rela)
}
}
- if (is_rela)
- free (relas);
- else
- free (rels);
+ free (rels);
return 1;
}
static const char *
-get_mips_dynamic_type (type)
- unsigned long type;
+get_mips_dynamic_type (unsigned long type)
{
switch (type)
{
@@ -1266,8 +1333,7 @@ get_mips_dynamic_type (type)
}
static const char *
-get_sparc64_dynamic_type (type)
- unsigned long type;
+get_sparc64_dynamic_type (unsigned long type)
{
switch (type)
{
@@ -1278,8 +1344,7 @@ get_sparc64_dynamic_type (type)
}
static const char *
-get_ppc64_dynamic_type (type)
- unsigned long type;
+get_ppc64_dynamic_type (unsigned long type)
{
switch (type)
{
@@ -1292,8 +1357,7 @@ get_ppc64_dynamic_type (type)
}
static const char *
-get_parisc_dynamic_type (type)
- unsigned long type;
+get_parisc_dynamic_type (unsigned long type)
{
switch (type)
{
@@ -1316,10 +1380,20 @@ get_parisc_dynamic_type (type)
}
static const char *
-get_dynamic_type (type)
- unsigned long type;
+get_ia64_dynamic_type (unsigned long type)
{
- static char buff [32];
+ switch (type)
+ {
+ case DT_IA_64_PLT_RESERVE: return "IA_64_PLT_RESERVE";
+ default:
+ return NULL;
+ }
+}
+
+static const char *
+get_dynamic_type (unsigned long type)
+{
+ static char buff[32];
switch (type)
{
@@ -1398,7 +1472,7 @@ get_dynamic_type (type)
default:
if ((type >= DT_LOPROC) && (type <= DT_HIPROC))
{
- const char * result;
+ const char *result;
switch (elf_header.e_machine)
{
@@ -1412,6 +1486,9 @@ get_dynamic_type (type)
case EM_PPC64:
result = get_ppc64_dynamic_type (type);
break;
+ case EM_IA_64:
+ result = get_ia64_dynamic_type (type);
+ break;
default:
result = NULL;
break;
@@ -1424,7 +1501,7 @@ get_dynamic_type (type)
}
else if ((type >= DT_LOOS) && (type <= DT_HIOS))
{
- const char * result;
+ const char *result;
switch (elf_header.e_machine)
{
@@ -1449,10 +1526,9 @@ get_dynamic_type (type)
}
static char *
-get_file_type (e_type)
- unsigned e_type;
+get_file_type (unsigned e_type)
{
- static char buff [32];
+ static char buff[32];
switch (e_type)
{
@@ -1474,10 +1550,9 @@ get_file_type (e_type)
}
static char *
-get_machine_name (e_machine)
- unsigned e_machine;
+get_machine_name (unsigned e_machine)
{
- static char buff [64]; /* XXX */
+ static char buff[64]; /* XXX */
switch (e_machine)
{
@@ -1502,17 +1577,17 @@ get_machine_name (e_machine)
case EM_V800: return "NEC V800";
case EM_FR20: return "Fujitsu FR20";
case EM_RH32: return "TRW RH32";
- case EM_MCORE: return "MCORE";
+ case EM_MCORE: return "MCORE";
case EM_ARM: return "ARM";
case EM_OLD_ALPHA: return "Digital Alpha (old)";
- case EM_SH: return "Hitachi SH";
+ case EM_SH: return "Renesas / SuperH SH";
case EM_SPARCV9: return "Sparc v9";
case EM_TRICORE: return "Siemens Tricore";
case EM_ARC: return "ARC";
- case EM_H8_300: return "Hitachi H8/300";
- case EM_H8_300H: return "Hitachi H8/300H";
- case EM_H8S: return "Hitachi H8S";
- case EM_H8_500: return "Hitachi H8/500";
+ case EM_H8_300: return "Renesas H8/300";
+ case EM_H8_300H: return "Renesas H8/300H";
+ case EM_H8S: return "Renesas H8S";
+ case EM_H8_500: return "Renesas H8/500";
case EM_IA_64: return "Intel IA-64";
case EM_MIPS_X: return "Stanford MIPS-X";
case EM_COLDFIRE: return "Motorola Coldfire";
@@ -1521,9 +1596,9 @@ get_machine_name (e_machine)
case EM_CYGNUS_D10V:
case EM_D10V: return "d10v";
case EM_CYGNUS_D30V:
- case EM_D30V: return "d30v";
+ case EM_D30V: return "d30v";
case EM_CYGNUS_M32R:
- case EM_M32R: return "Mitsubishi M32r";
+ case EM_M32R: return "Renesas M32R (formerly Mitsubishi M32r)";
case EM_CYGNUS_V850:
case EM_V850: return "NEC v850";
case EM_CYGNUS_MN10300:
@@ -1532,9 +1607,9 @@ get_machine_name (e_machine)
case EM_MN10200: return "mn10200";
case EM_CYGNUS_FR30:
case EM_FR30: return "Fujitsu FR30";
- case EM_CYGNUS_FRV: return "Fujitsu FR-V";
+ case EM_CYGNUS_FRV: return "Fujitsu FR-V";
case EM_PJ_OLD:
- case EM_PJ: return "picoJava";
+ case EM_PJ: return "picoJava";
case EM_MMA: return "Fujitsu Multimedia Accelerator";
case EM_PCP: return "Siemens PCP";
case EM_NCPU: return "Sony nCPU embedded RISC processor";
@@ -1554,21 +1629,26 @@ get_machine_name (e_machine)
case EM_ST19: return "STMicroelectronics ST19 8-bit microcontroller";
case EM_VAX: return "Digital VAX";
case EM_AVR_OLD:
- case EM_AVR: return "Atmel AVR 8-bit microcontroller";
+ case EM_AVR: return "Atmel AVR 8-bit microcontroller";
case EM_CRIS: return "Axis Communications 32-bit embedded processor";
case EM_JAVELIN: return "Infineon Technologies 32-bit embedded cpu";
case EM_FIREPATH: return "Element 14 64-bit DSP processor";
case EM_ZSP: return "LSI Logic's 16-bit DSP processor";
- case EM_MMIX: return "Donald Knuth's educational 64-bit processor";
+ case EM_MMIX: return "Donald Knuth's educational 64-bit processor";
case EM_HUANY: return "Harvard Universitys's machine-independent object format";
- case EM_PRISM: return "SiTera Prism";
+ case EM_PRISM: return "Vitesse Prism";
case EM_X86_64: return "Advanced Micro Devices X86-64";
case EM_S390_OLD:
- case EM_S390: return "IBM S/390";
+ case EM_S390: return "IBM S/390";
case EM_XSTORMY16: return "Sanyo Xstormy16 CPU core";
case EM_OPENRISC:
case EM_OR32: return "OpenRISC";
case EM_DLX: return "OpenDLX";
+ case EM_IP2K_OLD:
+ case EM_IP2K: return "Ubicom IP2xxx 8-bit microcontrollers";
+ case EM_IQ2000: return "Vitesse IQ2000";
+ case EM_XTENSA_OLD:
+ case EM_XTENSA: return "Tensilica Xtensa Processor";
default:
sprintf (buff, _("<unknown>: %x"), e_machine);
return buff;
@@ -1576,9 +1656,7 @@ get_machine_name (e_machine)
}
static void
-decode_ARM_machine_flags (e_flags, buf)
- unsigned e_flags;
- char buf[];
+decode_ARM_machine_flags (unsigned e_flags, char buf[])
{
unsigned eabi;
int unknown = 0;
@@ -1706,6 +1784,10 @@ decode_ARM_machine_flags (e_flags, buf)
strcat (buf, ", software FP");
break;
+ case EF_ARM_MAVERICK_FLOAT:
+ strcat (buf, ", Maverick FP");
+ break;
+
default:
unknown = 1;
break;
@@ -1718,11 +1800,9 @@ decode_ARM_machine_flags (e_flags, buf)
}
static char *
-get_machine_flags (e_flags, e_machine)
- unsigned e_flags;
- unsigned e_machine;
+get_machine_flags (unsigned e_flags, unsigned e_machine)
{
- static char buf [1024];
+ static char buf[1024];
buf[0] = '\0';
@@ -1759,12 +1839,12 @@ get_machine_flags (e_flags, e_machine)
case EM_CYGNUS_V850:
switch (e_flags & EF_V850_ARCH)
{
+ case E_V850E1_ARCH:
+ strcat (buf, ", v850e1");
+ break;
case E_V850E_ARCH:
strcat (buf, ", v850e");
break;
- case E_V850EA_ARCH:
- strcat (buf, ", v850ea");
- break;
case E_V850_ARCH:
strcat (buf, ", v850");
break;
@@ -1809,8 +1889,11 @@ get_machine_flags (e_flags, e_machine)
case E_MIPS_MACH_3900: strcat (buf, ", 3900"); break;
case E_MIPS_MACH_4010: strcat (buf, ", 4010"); break;
case E_MIPS_MACH_4100: strcat (buf, ", 4100"); break;
- case E_MIPS_MACH_4650: strcat (buf, ", 4650"); break;
case E_MIPS_MACH_4111: strcat (buf, ", 4111"); break;
+ case E_MIPS_MACH_4120: strcat (buf, ", 4120"); break;
+ case E_MIPS_MACH_4650: strcat (buf, ", 4650"); break;
+ case E_MIPS_MACH_5400: strcat (buf, ", 5400"); break;
+ case E_MIPS_MACH_5500: strcat (buf, ", 5500"); break;
case E_MIPS_MACH_SB1: strcat (buf, ", sb1"); break;
case 0:
/* We simply ignore the field in this case to avoid confusion:
@@ -1849,7 +1932,9 @@ get_machine_flags (e_flags, e_machine)
case E_MIPS_ARCH_4: strcat (buf, ", mips4"); break;
case E_MIPS_ARCH_5: strcat (buf, ", mips5"); break;
case E_MIPS_ARCH_32: strcat (buf, ", mips32"); break;
+ case E_MIPS_ARCH_32R2: strcat (buf, ", mips32r2"); break;
case E_MIPS_ARCH_64: strcat (buf, ", mips64"); break;
+ case E_MIPS_ARCH_64R2: strcat (buf, ", mips64r2"); break;
default: strcat (buf, ", unknown ISA"); break;
}
@@ -1949,8 +2034,37 @@ get_machine_flags (e_flags, e_machine)
}
static const char *
-get_mips_segment_type (type)
- unsigned long type;
+get_osabi_name (unsigned int osabi)
+{
+ static char buff[32];
+
+ switch (osabi)
+ {
+ case ELFOSABI_NONE: return "UNIX - System V";
+ case ELFOSABI_HPUX: return "UNIX - HP-UX";
+ case ELFOSABI_NETBSD: return "UNIX - NetBSD";
+ case ELFOSABI_LINUX: return "UNIX - Linux";
+ case ELFOSABI_HURD: return "GNU/Hurd";
+ case ELFOSABI_SOLARIS: return "UNIX - Solaris";
+ case ELFOSABI_AIX: return "UNIX - AIX";
+ case ELFOSABI_IRIX: return "UNIX - IRIX";
+ case ELFOSABI_FREEBSD: return "UNIX - FreeBSD";
+ case ELFOSABI_TRU64: return "UNIX - TRU64";
+ case ELFOSABI_MODESTO: return "Novell - Modesto";
+ case ELFOSABI_OPENBSD: return "UNIX - OpenBSD";
+ case ELFOSABI_OPENVMS: return "VMS - OpenVMS";
+ case ELFOSABI_NSK: return "HP - Non-Stop Kernel";
+ case ELFOSABI_AROS: return "Amiga Research OS";
+ case ELFOSABI_STANDALONE: return _("Standalone App");
+ case ELFOSABI_ARM: return "ARM";
+ default:
+ sprintf (buff, _("<unknown: %x>"), osabi);
+ return buff;
+ }
+}
+
+static const char *
+get_mips_segment_type (unsigned long type)
{
switch (type)
{
@@ -1968,8 +2082,7 @@ get_mips_segment_type (type)
}
static const char *
-get_parisc_segment_type (type)
- unsigned long type;
+get_parisc_segment_type (unsigned long type)
{
switch (type)
{
@@ -1995,8 +2108,7 @@ get_parisc_segment_type (type)
}
static const char *
-get_ia64_segment_type (type)
- unsigned long type;
+get_ia64_segment_type (unsigned long type)
{
switch (type)
{
@@ -2014,29 +2126,29 @@ get_ia64_segment_type (type)
}
static const char *
-get_segment_type (p_type)
- unsigned long p_type;
+get_segment_type (unsigned long p_type)
{
- static char buff [32];
+ static char buff[32];
switch (p_type)
{
- case PT_NULL: return "NULL";
- case PT_LOAD: return "LOAD";
+ case PT_NULL: return "NULL";
+ case PT_LOAD: return "LOAD";
case PT_DYNAMIC: return "DYNAMIC";
- case PT_INTERP: return "INTERP";
- case PT_NOTE: return "NOTE";
- case PT_SHLIB: return "SHLIB";
- case PT_PHDR: return "PHDR";
+ case PT_INTERP: return "INTERP";
+ case PT_NOTE: return "NOTE";
+ case PT_SHLIB: return "SHLIB";
+ case PT_PHDR: return "PHDR";
case PT_TLS: return "TLS";
case PT_GNU_EH_FRAME:
return "GNU_EH_FRAME";
+ case PT_GNU_STACK: return "STACK";
default:
if ((p_type >= PT_LOPROC) && (p_type <= PT_HIPROC))
{
- const char * result;
+ const char *result;
switch (elf_header.e_machine)
{
@@ -2062,7 +2174,7 @@ get_segment_type (p_type)
}
else if ((p_type >= PT_LOOS) && (p_type <= PT_HIOS))
{
- const char * result;
+ const char *result;
switch (elf_header.e_machine)
{
@@ -2090,49 +2202,48 @@ get_segment_type (p_type)
}
static const char *
-get_mips_section_type_name (sh_type)
- unsigned int sh_type;
+get_mips_section_type_name (unsigned int sh_type)
{
switch (sh_type)
{
- case SHT_MIPS_LIBLIST: return "MIPS_LIBLIST";
- case SHT_MIPS_MSYM: return "MIPS_MSYM";
- case SHT_MIPS_CONFLICT: return "MIPS_CONFLICT";
- case SHT_MIPS_GPTAB: return "MIPS_GPTAB";
- case SHT_MIPS_UCODE: return "MIPS_UCODE";
- case SHT_MIPS_DEBUG: return "MIPS_DEBUG";
- case SHT_MIPS_REGINFO: return "MIPS_REGINFO";
- case SHT_MIPS_PACKAGE: return "MIPS_PACKAGE";
- case SHT_MIPS_PACKSYM: return "MIPS_PACKSYM";
- case SHT_MIPS_RELD: return "MIPS_RELD";
- case SHT_MIPS_IFACE: return "MIPS_IFACE";
- case SHT_MIPS_CONTENT: return "MIPS_CONTENT";
- case SHT_MIPS_OPTIONS: return "MIPS_OPTIONS";
- case SHT_MIPS_SHDR: return "MIPS_SHDR";
- case SHT_MIPS_FDESC: return "MIPS_FDESC";
- case SHT_MIPS_EXTSYM: return "MIPS_EXTSYM";
- case SHT_MIPS_DENSE: return "MIPS_DENSE";
- case SHT_MIPS_PDESC: return "MIPS_PDESC";
- case SHT_MIPS_LOCSYM: return "MIPS_LOCSYM";
- case SHT_MIPS_AUXSYM: return "MIPS_AUXSYM";
- case SHT_MIPS_OPTSYM: return "MIPS_OPTSYM";
- case SHT_MIPS_LOCSTR: return "MIPS_LOCSTR";
- case SHT_MIPS_LINE: return "MIPS_LINE";
- case SHT_MIPS_RFDESC: return "MIPS_RFDESC";
- case SHT_MIPS_DELTASYM: return "MIPS_DELTASYM";
- case SHT_MIPS_DELTAINST: return "MIPS_DELTAINST";
- case SHT_MIPS_DELTACLASS: return "MIPS_DELTACLASS";
- case SHT_MIPS_DWARF: return "MIPS_DWARF";
- case SHT_MIPS_DELTADECL: return "MIPS_DELTADECL";
- case SHT_MIPS_SYMBOL_LIB: return "MIPS_SYMBOL_LIB";
- case SHT_MIPS_EVENTS: return "MIPS_EVENTS";
- case SHT_MIPS_TRANSLATE: return "MIPS_TRANSLATE";
- case SHT_MIPS_PIXIE: return "MIPS_PIXIE";
- case SHT_MIPS_XLATE: return "MIPS_XLATE";
- case SHT_MIPS_XLATE_DEBUG: return "MIPS_XLATE_DEBUG";
- case SHT_MIPS_WHIRL: return "MIPS_WHIRL";
- case SHT_MIPS_EH_REGION: return "MIPS_EH_REGION";
- case SHT_MIPS_XLATE_OLD: return "MIPS_XLATE_OLD";
+ case SHT_MIPS_LIBLIST: return "MIPS_LIBLIST";
+ case SHT_MIPS_MSYM: return "MIPS_MSYM";
+ case SHT_MIPS_CONFLICT: return "MIPS_CONFLICT";
+ case SHT_MIPS_GPTAB: return "MIPS_GPTAB";
+ case SHT_MIPS_UCODE: return "MIPS_UCODE";
+ case SHT_MIPS_DEBUG: return "MIPS_DEBUG";
+ case SHT_MIPS_REGINFO: return "MIPS_REGINFO";
+ case SHT_MIPS_PACKAGE: return "MIPS_PACKAGE";
+ case SHT_MIPS_PACKSYM: return "MIPS_PACKSYM";
+ case SHT_MIPS_RELD: return "MIPS_RELD";
+ case SHT_MIPS_IFACE: return "MIPS_IFACE";
+ case SHT_MIPS_CONTENT: return "MIPS_CONTENT";
+ case SHT_MIPS_OPTIONS: return "MIPS_OPTIONS";
+ case SHT_MIPS_SHDR: return "MIPS_SHDR";
+ case SHT_MIPS_FDESC: return "MIPS_FDESC";
+ case SHT_MIPS_EXTSYM: return "MIPS_EXTSYM";
+ case SHT_MIPS_DENSE: return "MIPS_DENSE";
+ case SHT_MIPS_PDESC: return "MIPS_PDESC";
+ case SHT_MIPS_LOCSYM: return "MIPS_LOCSYM";
+ case SHT_MIPS_AUXSYM: return "MIPS_AUXSYM";
+ case SHT_MIPS_OPTSYM: return "MIPS_OPTSYM";
+ case SHT_MIPS_LOCSTR: return "MIPS_LOCSTR";
+ case SHT_MIPS_LINE: return "MIPS_LINE";
+ case SHT_MIPS_RFDESC: return "MIPS_RFDESC";
+ case SHT_MIPS_DELTASYM: return "MIPS_DELTASYM";
+ case SHT_MIPS_DELTAINST: return "MIPS_DELTAINST";
+ case SHT_MIPS_DELTACLASS: return "MIPS_DELTACLASS";
+ case SHT_MIPS_DWARF: return "MIPS_DWARF";
+ case SHT_MIPS_DELTADECL: return "MIPS_DELTADECL";
+ case SHT_MIPS_SYMBOL_LIB: return "MIPS_SYMBOL_LIB";
+ case SHT_MIPS_EVENTS: return "MIPS_EVENTS";
+ case SHT_MIPS_TRANSLATE: return "MIPS_TRANSLATE";
+ case SHT_MIPS_PIXIE: return "MIPS_PIXIE";
+ case SHT_MIPS_XLATE: return "MIPS_XLATE";
+ case SHT_MIPS_XLATE_DEBUG: return "MIPS_XLATE_DEBUG";
+ case SHT_MIPS_WHIRL: return "MIPS_WHIRL";
+ case SHT_MIPS_EH_REGION: return "MIPS_EH_REGION";
+ case SHT_MIPS_XLATE_OLD: return "MIPS_XLATE_OLD";
case SHT_MIPS_PDR_EXCEPTION: return "MIPS_PDR_EXCEPTION";
default:
break;
@@ -2141,8 +2252,7 @@ get_mips_section_type_name (sh_type)
}
static const char *
-get_parisc_section_type_name (sh_type)
- unsigned int sh_type;
+get_parisc_section_type_name (unsigned int sh_type)
{
switch (sh_type)
{
@@ -2156,13 +2266,17 @@ get_parisc_section_type_name (sh_type)
}
static const char *
-get_ia64_section_type_name (sh_type)
- unsigned int sh_type;
+get_ia64_section_type_name (unsigned int sh_type)
{
+ /* If the top 8 bits are 0x78 the next 8 are the os/abi ID. */
+ if ((sh_type & 0xFF000000) == SHT_IA_64_LOPSREG)
+ return get_osabi_name ((sh_type & 0x00FF0000) >> 16);
+
switch (sh_type)
{
- case SHT_IA_64_EXT: return "IA_64_EXT";
- case SHT_IA_64_UNWIND: return "IA_64_UNWIND";
+ case SHT_IA_64_EXT: return "IA_64_EXT";
+ case SHT_IA_64_UNWIND: return "IA_64_UNWIND";
+ case SHT_IA_64_PRIORITY_INIT: return "IA_64_PRIORITY_INIT";
default:
break;
}
@@ -2170,10 +2284,9 @@ get_ia64_section_type_name (sh_type)
}
static const char *
-get_section_type_name (sh_type)
- unsigned int sh_type;
+get_section_type_name (unsigned int sh_type)
{
- static char buff [32];
+ static char buff[32];
switch (sh_type)
{
@@ -2197,8 +2310,8 @@ get_section_type_name (sh_type)
case SHT_GNU_verdef: return "VERDEF";
case SHT_GNU_verneed: return "VERNEED";
case SHT_GNU_versym: return "VERSYM";
- case 0x6ffffff0: return "VERSYM";
- case 0x6ffffffc: return "VERDEF";
+ case 0x6ffffff0: return "VERSYM";
+ case 0x6ffffffc: return "VERDEF";
case 0x7ffffffd: return "AUXILIARY";
case 0x7fffffff: return "FILTER";
case SHT_GNU_LIBLIST: return "GNU_LIBLIST";
@@ -2206,7 +2319,7 @@ get_section_type_name (sh_type)
default:
if ((sh_type >= SHT_LOPROC) && (sh_type <= SHT_HIPROC))
{
- const char * result;
+ const char *result;
switch (elf_header.e_machine)
{
@@ -2243,39 +2356,39 @@ get_section_type_name (sh_type)
#define OPTION_DEBUG_DUMP 512
-struct option options [] =
+struct option options[] =
{
- {"all", no_argument, 0, 'a'},
+ {"all", no_argument, 0, 'a'},
{"file-header", no_argument, 0, 'h'},
{"program-headers", no_argument, 0, 'l'},
- {"headers", no_argument, 0, 'e'},
- {"histogram", no_argument, 0, 'I'},
- {"segments", no_argument, 0, 'l'},
- {"sections", no_argument, 0, 'S'},
+ {"headers", no_argument, 0, 'e'},
+ {"histogram", no_argument, 0, 'I'},
+ {"segments", no_argument, 0, 'l'},
+ {"sections", no_argument, 0, 'S'},
{"section-headers", no_argument, 0, 'S'},
- {"symbols", no_argument, 0, 's'},
- {"syms", no_argument, 0, 's'},
- {"relocs", no_argument, 0, 'r'},
- {"notes", no_argument, 0, 'n'},
- {"dynamic", no_argument, 0, 'd'},
+ {"symbols", no_argument, 0, 's'},
+ {"syms", no_argument, 0, 's'},
+ {"relocs", no_argument, 0, 'r'},
+ {"notes", no_argument, 0, 'n'},
+ {"dynamic", no_argument, 0, 'd'},
{"arch-specific", no_argument, 0, 'A'},
{"version-info", no_argument, 0, 'V'},
{"use-dynamic", no_argument, 0, 'D'},
- {"hex-dump", required_argument, 0, 'x'},
+ {"hex-dump", required_argument, 0, 'x'},
{"debug-dump", optional_argument, 0, OPTION_DEBUG_DUMP},
{"unwind", no_argument, 0, 'u'},
#ifdef SUPPORT_DISASSEMBLY
{"instruction-dump", required_argument, 0, 'i'},
#endif
- {"version", no_argument, 0, 'v'},
- {"wide", no_argument, 0, 'W'},
- {"help", no_argument, 0, 'H'},
- {0, no_argument, 0, 0}
+ {"version", no_argument, 0, 'v'},
+ {"wide", no_argument, 0, 'W'},
+ {"help", no_argument, 0, 'H'},
+ {0, no_argument, 0, 0}
};
static void
-usage ()
+usage (void)
{
fprintf (stdout, _("Usage: readelf <option(s)> elf-file(s)\n"));
fprintf (stdout, _(" Display information about the contents of ELF format files\n"));
@@ -2316,15 +2429,13 @@ usage ()
}
static void
-request_dump (section, type)
- unsigned int section;
- int type;
+request_dump (unsigned int section, int type)
{
if (section >= num_dump_sects)
{
- char * new_dump_sects;
+ char *new_dump_sects;
- new_dump_sects = (char *) calloc (section + 1, 1);
+ new_dump_sects = calloc (section + 1, 1);
if (new_dump_sects == NULL)
error (_("Out of memory allocating dump request table."));
@@ -2341,15 +2452,13 @@ request_dump (section, type)
}
if (dump_sects)
- dump_sects [section] |= type;
+ dump_sects[section] |= type;
return;
}
static void
-parse_args (argc, argv)
- int argc;
- char ** argv;
+parse_args (int argc, char **argv)
{
int c;
@@ -2357,10 +2466,10 @@ parse_args (argc, argv)
usage ();
while ((c = getopt_long
- (argc, argv, "ersuahnldSDAIw::x:i:vVW", options, NULL)) != EOF)
+ (argc, argv, "ersuahnldSDAIw::x:i:vVWH", options, NULL)) != EOF)
{
- char * cp;
- int section;
+ char *cp;
+ int section;
switch (c)
{
@@ -2372,67 +2481,67 @@ parse_args (argc, argv)
break;
case 'a':
- do_syms ++;
- do_reloc ++;
- do_unwind ++;
- do_dynamic ++;
- do_header ++;
- do_sections ++;
- do_segments ++;
- do_version ++;
- do_histogram ++;
- do_arch ++;
- do_notes ++;
+ do_syms++;
+ do_reloc++;
+ do_unwind++;
+ do_dynamic++;
+ do_header++;
+ do_sections++;
+ do_segments++;
+ do_version++;
+ do_histogram++;
+ do_arch++;
+ do_notes++;
break;
case 'e':
- do_header ++;
- do_sections ++;
- do_segments ++;
+ do_header++;
+ do_sections++;
+ do_segments++;
break;
case 'A':
- do_arch ++;
+ do_arch++;
break;
case 'D':
- do_using_dynamic ++;
+ do_using_dynamic++;
break;
case 'r':
- do_reloc ++;
+ do_reloc++;
break;
case 'u':
- do_unwind ++;
+ do_unwind++;
break;
case 'h':
- do_header ++;
+ do_header++;
break;
case 'l':
- do_segments ++;
+ do_segments++;
break;
case 's':
- do_syms ++;
+ do_syms++;
break;
case 'S':
- do_sections ++;
+ do_sections++;
break;
case 'd':
- do_dynamic ++;
+ do_dynamic++;
break;
case 'I':
- do_histogram ++;
+ do_histogram++;
break;
case 'n':
- do_notes ++;
+ do_notes++;
break;
case 'x':
- do_dump ++;
+ do_dump++;
section = strtoul (optarg, & cp, 0);
- if (! * cp && section >= 0)
+ if (! *cp && section >= 0)
{
request_dump (section, HEX_DUMP);
break;
}
goto oops;
case 'w':
- do_dump ++;
+ do_dump++;
if (optarg == 0)
do_debugging = 1;
else
@@ -2497,12 +2606,12 @@ parse_args (argc, argv)
}
break;
case OPTION_DEBUG_DUMP:
- do_dump ++;
+ do_dump++;
if (optarg == 0)
do_debugging = 1;
else
{
- const char *debug_dump_opt[]
+ static const char *debug_dump_opt[]
= { "line", "info", "abbrev", "pubnames", "ranges",
"macro", "frames", "frames-interp", "str", "loc", NULL };
unsigned int index;
@@ -2580,9 +2689,9 @@ parse_args (argc, argv)
break;
#ifdef SUPPORT_DISASSEMBLY
case 'i':
- do_dump ++;
+ do_dump++;
section = strtoul (optarg, & cp, 0);
- if (! * cp && section >= 0)
+ if (! *cp && section >= 0)
{
request_dump (section, DISASS_DUMP);
break;
@@ -2593,10 +2702,10 @@ parse_args (argc, argv)
print_version (program_name);
break;
case 'V':
- do_version ++;
+ do_version++;
break;
case 'W':
- do_wide ++;
+ do_wide++;
break;
default:
oops:
@@ -2620,10 +2729,9 @@ parse_args (argc, argv)
}
static const char *
-get_elf_class (elf_class)
- unsigned int elf_class;
+get_elf_class (unsigned int elf_class)
{
- static char buff [32];
+ static char buff[32];
switch (elf_class)
{
@@ -2637,10 +2745,9 @@ get_elf_class (elf_class)
}
static const char *
-get_data_encoding (encoding)
- unsigned int encoding;
+get_data_encoding (unsigned int encoding)
{
- static char buff [32];
+ static char buff[32];
switch (encoding)
{
@@ -2653,42 +2760,15 @@ get_data_encoding (encoding)
}
}
-static const char *
-get_osabi_name (osabi)
- unsigned int osabi;
-{
- static char buff [32];
-
- switch (osabi)
- {
- case ELFOSABI_NONE: return "UNIX - System V";
- case ELFOSABI_HPUX: return "UNIX - HP-UX";
- case ELFOSABI_NETBSD: return "UNIX - NetBSD";
- case ELFOSABI_LINUX: return "UNIX - Linux";
- case ELFOSABI_HURD: return "GNU/Hurd";
- case ELFOSABI_SOLARIS: return "UNIX - Solaris";
- case ELFOSABI_AIX: return "UNIX - AIX";
- case ELFOSABI_IRIX: return "UNIX - IRIX";
- case ELFOSABI_FREEBSD: return "UNIX - FreeBSD";
- case ELFOSABI_TRU64: return "UNIX - TRU64";
- case ELFOSABI_MODESTO: return "Novell - Modesto";
- case ELFOSABI_OPENBSD: return "UNIX - OpenBSD";
- case ELFOSABI_STANDALONE: return _("Standalone App");
- case ELFOSABI_ARM: return "ARM";
- default:
- sprintf (buff, _("<unknown: %x>"), osabi);
- return buff;
- }
-}
-
/* Decode the data held in 'elf_header'. */
+
static int
-process_file_header ()
+process_file_header (void)
{
- if ( elf_header.e_ident [EI_MAG0] != ELFMAG0
- || elf_header.e_ident [EI_MAG1] != ELFMAG1
- || elf_header.e_ident [EI_MAG2] != ELFMAG2
- || elf_header.e_ident [EI_MAG3] != ELFMAG3)
+ if ( elf_header.e_ident[EI_MAG0] != ELFMAG0
+ || elf_header.e_ident[EI_MAG1] != ELFMAG1
+ || elf_header.e_ident[EI_MAG2] != ELFMAG2
+ || elf_header.e_ident[EI_MAG3] != ELFMAG3)
{
error
(_("Not an ELF file - it has the wrong magic bytes at the start\n"));
@@ -2701,24 +2781,24 @@ process_file_header ()
printf (_("ELF Header:\n"));
printf (_(" Magic: "));
- for (i = 0; i < EI_NIDENT; i ++)
- printf ("%2.2x ", elf_header.e_ident [i]);
+ for (i = 0; i < EI_NIDENT; i++)
+ printf ("%2.2x ", elf_header.e_ident[i]);
printf ("\n");
printf (_(" Class: %s\n"),
- get_elf_class (elf_header.e_ident [EI_CLASS]));
+ get_elf_class (elf_header.e_ident[EI_CLASS]));
printf (_(" Data: %s\n"),
- get_data_encoding (elf_header.e_ident [EI_DATA]));
+ get_data_encoding (elf_header.e_ident[EI_DATA]));
printf (_(" Version: %d %s\n"),
- elf_header.e_ident [EI_VERSION],
- (elf_header.e_ident [EI_VERSION] == EV_CURRENT
+ elf_header.e_ident[EI_VERSION],
+ (elf_header.e_ident[EI_VERSION] == EV_CURRENT
? "(current)"
- : (elf_header.e_ident [EI_VERSION] != EV_NONE
+ : (elf_header.e_ident[EI_VERSION] != EV_NONE
? "<unknown: %lx>"
: "")));
printf (_(" OS/ABI: %s\n"),
- get_osabi_name (elf_header.e_ident [EI_OSABI]));
+ get_osabi_name (elf_header.e_ident[EI_OSABI]));
printf (_(" ABI Version: %d\n"),
- elf_header.e_ident [EI_ABIVERSION]);
+ elf_header.e_ident[EI_ABIVERSION]);
printf (_(" Type: %s\n"),
get_file_type (elf_header.e_type));
printf (_(" Machine: %s\n"),
@@ -2772,25 +2852,22 @@ process_file_header ()
static int
-get_32bit_program_headers (file, program_headers)
- FILE * file;
- Elf_Internal_Phdr * program_headers;
-{
- Elf32_External_Phdr * phdrs;
- Elf32_External_Phdr * external;
- Elf32_Internal_Phdr * internal;
- unsigned int i;
-
- phdrs = ((Elf32_External_Phdr *)
- get_data (NULL, file, elf_header.e_phoff,
- elf_header.e_phentsize * elf_header.e_phnum,
- _("program headers")));
+get_32bit_program_headers (FILE *file, Elf_Internal_Phdr *program_headers)
+{
+ Elf32_External_Phdr *phdrs;
+ Elf32_External_Phdr *external;
+ Elf_Internal_Phdr *internal;
+ unsigned int i;
+
+ phdrs = get_data (NULL, file, elf_header.e_phoff,
+ elf_header.e_phentsize * elf_header.e_phnum,
+ _("program headers"));
if (!phdrs)
return 0;
for (i = 0, internal = program_headers, external = phdrs;
i < elf_header.e_phnum;
- i ++, internal ++, external ++)
+ i++, internal++, external++)
{
internal->p_type = BYTE_GET (external->p_type);
internal->p_offset = BYTE_GET (external->p_offset);
@@ -2808,25 +2885,22 @@ get_32bit_program_headers (file, program_headers)
}
static int
-get_64bit_program_headers (file, program_headers)
- FILE * file;
- Elf_Internal_Phdr * program_headers;
-{
- Elf64_External_Phdr * phdrs;
- Elf64_External_Phdr * external;
- Elf64_Internal_Phdr * internal;
- unsigned int i;
-
- phdrs = ((Elf64_External_Phdr *)
- get_data (NULL, file, elf_header.e_phoff,
- elf_header.e_phentsize * elf_header.e_phnum,
- _("program headers")));
+get_64bit_program_headers (FILE *file, Elf_Internal_Phdr *program_headers)
+{
+ Elf64_External_Phdr *phdrs;
+ Elf64_External_Phdr *external;
+ Elf_Internal_Phdr *internal;
+ unsigned int i;
+
+ phdrs = get_data (NULL, file, elf_header.e_phoff,
+ elf_header.e_phentsize * elf_header.e_phnum,
+ _("program headers"));
if (!phdrs)
return 0;
for (i = 0, internal = program_headers, external = phdrs;
i < elf_header.e_phnum;
- i ++, internal ++, external ++)
+ i++, internal++, external++)
{
internal->p_type = BYTE_GET (external->p_type);
internal->p_flags = BYTE_GET (external->p_flags);
@@ -2843,19 +2917,50 @@ get_64bit_program_headers (file, program_headers)
return 1;
}
+/* Returns 1 if the program headers were read into `program_headers'. */
+
static int
-process_program_headers (file)
- FILE * file;
+get_program_headers (FILE *file)
{
- Elf_Internal_Phdr * program_headers;
- Elf_Internal_Phdr * segment;
- unsigned int i;
+ Elf_Internal_Phdr *phdrs;
+
+ /* Check cache of prior read. */
+ if (program_headers != NULL)
+ return 1;
+
+ phdrs = malloc (elf_header.e_phnum * sizeof (Elf_Internal_Phdr));
+
+ if (phdrs == NULL)
+ {
+ error (_("Out of memory\n"));
+ return 0;
+ }
+
+ if (is_32bit_elf
+ ? get_32bit_program_headers (file, phdrs)
+ : get_64bit_program_headers (file, phdrs))
+ {
+ program_headers = phdrs;
+ return 1;
+ }
+
+ free (phdrs);
+ return 0;
+}
+
+/* Returns 1 if the program headers were loaded. */
+
+static int
+process_program_headers (FILE *file)
+{
+ Elf_Internal_Phdr *segment;
+ unsigned int i;
if (elf_header.e_phnum == 0)
{
if (do_segments)
printf (_("\nThere are no program headers in this file.\n"));
- return 1;
+ return 0;
}
if (do_segments && !do_header)
@@ -2869,25 +2974,8 @@ process_program_headers (file)
printf ("\n");
}
- program_headers = (Elf_Internal_Phdr *) malloc
- (elf_header.e_phnum * sizeof (Elf_Internal_Phdr));
-
- if (program_headers == NULL)
- {
- error (_("Out of memory\n"));
- return 0;
- }
-
- if (is_32bit_elf)
- i = get_32bit_program_headers (file, program_headers);
- else
- i = get_64bit_program_headers (file, program_headers);
-
- if (i == 0)
- {
- free (program_headers);
+ if (! get_program_headers (file))
return 0;
- }
if (do_segments)
{
@@ -2911,13 +2999,12 @@ process_program_headers (file)
}
}
- loadaddr = -1;
dynamic_addr = 0;
dynamic_size = 0;
for (i = 0, segment = program_headers;
i < elf_header.e_phnum;
- i ++, segment ++)
+ i++, segment++)
{
if (do_segments)
{
@@ -2999,12 +3086,6 @@ process_program_headers (file)
switch (segment->p_type)
{
- case PT_LOAD:
- if (loadaddr == -1)
- loadaddr = (segment->p_vaddr & 0xfffff000)
- - (segment->p_offset & 0xfffff000);
- break;
-
case PT_DYNAMIC:
if (dynamic_addr)
error (_("more than one dynamic segment\n"));
@@ -3014,7 +3095,8 @@ process_program_headers (file)
break;
case PT_INTERP:
- if (fseek (file, (long) segment->p_offset, SEEK_SET))
+ if (fseek (file, archive_file_offset + (long) segment->p_offset,
+ SEEK_SET))
error (_("Unable to find program interpreter name\n"));
else
{
@@ -3032,12 +3114,6 @@ process_program_headers (file)
putc ('\n', stdout);
}
- if (loadaddr == -1)
- {
- /* Very strange. */
- loadaddr = 0;
- }
-
if (do_segments && section_headers != NULL)
{
printf (_("\n Section to Segment mapping:\n"));
@@ -3048,14 +3124,14 @@ process_program_headers (file)
for (i = 0; i < elf_header.e_phnum; i++)
{
unsigned int j;
- Elf_Internal_Shdr * section;
+ Elf_Internal_Shdr *section;
segment = program_headers + i;
section = section_headers;
printf (" %2.2d ", i);
- for (j = 1; j < elf_header.e_shnum; j++, section ++)
+ for (j = 1; j < elf_header.e_shnum; j++, section++)
{
if (section->sh_size > 0
/* Compare allocated sections by VMA, unallocated
@@ -3074,30 +3150,54 @@ process_program_headers (file)
}
}
- free (program_headers);
-
return 1;
}
+/* Find the file offset corresponding to VMA by using the program headers. */
+
+static long
+offset_from_vma (FILE *file, bfd_vma vma, bfd_size_type size)
+{
+ Elf_Internal_Phdr *seg;
+
+ if (! get_program_headers (file))
+ {
+ warn (_("Cannot interpret virtual addresses without program headers.\n"));
+ return (long) vma;
+ }
+
+ for (seg = program_headers;
+ seg < program_headers + elf_header.e_phnum;
+ ++seg)
+ {
+ if (seg->p_type != PT_LOAD)
+ continue;
+
+ if (vma >= (seg->p_vaddr & -seg->p_align)
+ && vma + size <= seg->p_vaddr + seg->p_filesz)
+ return vma - seg->p_vaddr + seg->p_offset;
+ }
+
+ warn (_("Virtual address 0x%lx not located in any PT_LOAD segment.\n"),
+ (long) vma);
+ return (long) vma;
+}
+
+
static int
-get_32bit_section_headers (file, num)
- FILE * file;
- unsigned int num;
-{
- Elf32_External_Shdr * shdrs;
- Elf32_Internal_Shdr * internal;
- unsigned int i;
-
- shdrs = ((Elf32_External_Shdr *)
- get_data (NULL, file, elf_header.e_shoff,
- elf_header.e_shentsize * num,
- _("section headers")));
+get_32bit_section_headers (FILE *file, unsigned int num)
+{
+ Elf32_External_Shdr *shdrs;
+ Elf_Internal_Shdr *internal;
+ unsigned int i;
+
+ shdrs = get_data (NULL, file, elf_header.e_shoff,
+ elf_header.e_shentsize * num, _("section headers"));
if (!shdrs)
return 0;
- section_headers = ((Elf_Internal_Shdr *)
- malloc (num * sizeof (Elf_Internal_Shdr)));
+ section_headers = malloc (num * sizeof (Elf_Internal_Shdr));
if (section_headers == NULL)
{
@@ -3107,7 +3207,7 @@ get_32bit_section_headers (file, num)
for (i = 0, internal = section_headers;
i < num;
- i ++, internal ++)
+ i++, internal++)
{
internal->sh_name = BYTE_GET (shdrs[i].sh_name);
internal->sh_type = BYTE_GET (shdrs[i].sh_type);
@@ -3127,23 +3227,18 @@ get_32bit_section_headers (file, num)
}
static int
-get_64bit_section_headers (file, num)
- FILE * file;
- unsigned int num;
-{
- Elf64_External_Shdr * shdrs;
- Elf64_Internal_Shdr * internal;
- unsigned int i;
-
- shdrs = ((Elf64_External_Shdr *)
- get_data (NULL, file, elf_header.e_shoff,
- elf_header.e_shentsize * num,
- _("section headers")));
+get_64bit_section_headers (FILE *file, unsigned int num)
+{
+ Elf64_External_Shdr *shdrs;
+ Elf_Internal_Shdr *internal;
+ unsigned int i;
+
+ shdrs = get_data (NULL, file, elf_header.e_shoff,
+ elf_header.e_shentsize * num, _("section headers"));
if (!shdrs)
return 0;
- section_headers = ((Elf_Internal_Shdr *)
- malloc (num * sizeof (Elf_Internal_Shdr)));
+ section_headers = malloc (num * sizeof (Elf_Internal_Shdr));
if (section_headers == NULL)
{
@@ -3153,7 +3248,7 @@ get_64bit_section_headers (file, num)
for (i = 0, internal = section_headers;
i < num;
- i ++, internal ++)
+ i++, internal++)
{
internal->sh_name = BYTE_GET (shdrs[i].sh_name);
internal->sh_type = BYTE_GET (shdrs[i].sh_type);
@@ -3173,20 +3268,17 @@ get_64bit_section_headers (file, num)
}
static Elf_Internal_Sym *
-get_32bit_elf_symbols (file, section)
- FILE * file;
- Elf_Internal_Shdr *section;
+get_32bit_elf_symbols (FILE *file, Elf_Internal_Shdr *section)
{
unsigned long number;
- Elf32_External_Sym * esyms;
+ Elf32_External_Sym *esyms;
Elf_External_Sym_Shndx *shndx;
- Elf_Internal_Sym * isyms;
- Elf_Internal_Sym * psym;
- unsigned int j;
+ Elf_Internal_Sym *isyms;
+ Elf_Internal_Sym *psym;
+ unsigned int j;
- esyms = ((Elf32_External_Sym *)
- get_data (NULL, file, section->sh_offset,
- section->sh_size, _("symbols")));
+ esyms = get_data (NULL, file, section->sh_offset, section->sh_size,
+ _("symbols"));
if (!esyms)
return NULL;
@@ -3195,9 +3287,8 @@ get_32bit_elf_symbols (file, section)
&& (symtab_shndx_hdr->sh_link
== (unsigned long) SECTION_HEADER_NUM (section - section_headers)))
{
- shndx = ((Elf_External_Sym_Shndx *)
- get_data (NULL, file, symtab_shndx_hdr->sh_offset,
- symtab_shndx_hdr->sh_size, _("symtab shndx")));
+ shndx = get_data (NULL, file, symtab_shndx_hdr->sh_offset,
+ symtab_shndx_hdr->sh_size, _("symtab shndx"));
if (!shndx)
{
free (esyms);
@@ -3206,7 +3297,7 @@ get_32bit_elf_symbols (file, section)
}
number = section->sh_size / section->sh_entsize;
- isyms = (Elf_Internal_Sym *) malloc (number * sizeof (Elf_Internal_Sym));
+ isyms = malloc (number * sizeof (Elf_Internal_Sym));
if (isyms == NULL)
{
@@ -3219,7 +3310,7 @@ get_32bit_elf_symbols (file, section)
for (j = 0, psym = isyms;
j < number;
- j ++, psym ++)
+ j++, psym++)
{
psym->st_name = BYTE_GET (esyms[j].st_name);
psym->st_value = BYTE_GET (esyms[j].st_value);
@@ -3240,20 +3331,17 @@ get_32bit_elf_symbols (file, section)
}
static Elf_Internal_Sym *
-get_64bit_elf_symbols (file, section)
- FILE * file;
- Elf_Internal_Shdr *section;
+get_64bit_elf_symbols (FILE *file, Elf_Internal_Shdr *section)
{
unsigned long number;
- Elf64_External_Sym * esyms;
+ Elf64_External_Sym *esyms;
Elf_External_Sym_Shndx *shndx;
- Elf_Internal_Sym * isyms;
- Elf_Internal_Sym * psym;
- unsigned int j;
+ Elf_Internal_Sym *isyms;
+ Elf_Internal_Sym *psym;
+ unsigned int j;
- esyms = ((Elf64_External_Sym *)
- get_data (NULL, file, section->sh_offset,
- section->sh_size, _("symbols")));
+ esyms = get_data (NULL, file, section->sh_offset, section->sh_size,
+ _("symbols"));
if (!esyms)
return NULL;
@@ -3262,9 +3350,8 @@ get_64bit_elf_symbols (file, section)
&& (symtab_shndx_hdr->sh_link
== (unsigned long) SECTION_HEADER_NUM (section - section_headers)))
{
- shndx = ((Elf_External_Sym_Shndx *)
- get_data (NULL, file, symtab_shndx_hdr->sh_offset,
- symtab_shndx_hdr->sh_size, _("symtab shndx")));
+ shndx = get_data (NULL, file, symtab_shndx_hdr->sh_offset,
+ symtab_shndx_hdr->sh_size, _("symtab shndx"));
if (!shndx)
{
free (esyms);
@@ -3273,7 +3360,7 @@ get_64bit_elf_symbols (file, section)
}
number = section->sh_size / section->sh_entsize;
- isyms = (Elf_Internal_Sym *) malloc (number * sizeof (Elf_Internal_Sym));
+ isyms = malloc (number * sizeof (Elf_Internal_Sym));
if (isyms == NULL)
{
@@ -3286,7 +3373,7 @@ get_64bit_elf_symbols (file, section)
for (j = 0, psym = isyms;
j < number;
- j ++, psym ++)
+ j++, psym++)
{
psym->st_name = BYTE_GET (esyms[j].st_name);
psym->st_info = BYTE_GET (esyms[j].st_info);
@@ -3307,12 +3394,11 @@ get_64bit_elf_symbols (file, section)
}
static const char *
-get_elf_section_flags (sh_flags)
- bfd_vma sh_flags;
+get_elf_section_flags (bfd_vma sh_flags)
{
- static char buff [32];
+ static char buff[32];
- * buff = 0;
+ *buff = 0;
while (sh_flags)
{
@@ -3323,15 +3409,15 @@ get_elf_section_flags (sh_flags)
switch (flag)
{
- case SHF_WRITE: strcat (buff, "W"); break;
- case SHF_ALLOC: strcat (buff, "A"); break;
- case SHF_EXECINSTR: strcat (buff, "X"); break;
- case SHF_MERGE: strcat (buff, "M"); break;
- case SHF_STRINGS: strcat (buff, "S"); break;
- case SHF_INFO_LINK: strcat (buff, "I"); break;
- case SHF_LINK_ORDER: strcat (buff, "L"); break;
+ case SHF_WRITE: strcat (buff, "W"); break;
+ case SHF_ALLOC: strcat (buff, "A"); break;
+ case SHF_EXECINSTR: strcat (buff, "X"); break;
+ case SHF_MERGE: strcat (buff, "M"); break;
+ case SHF_STRINGS: strcat (buff, "S"); break;
+ case SHF_INFO_LINK: strcat (buff, "I"); break;
+ case SHF_LINK_ORDER: strcat (buff, "L"); break;
case SHF_OS_NONCONFORMING: strcat (buff, "O"); break;
- case SHF_GROUP: strcat (buff, "G"); break;
+ case SHF_GROUP: strcat (buff, "G"); break;
case SHF_TLS: strcat (buff, "T"); break;
default:
@@ -3355,11 +3441,10 @@ get_elf_section_flags (sh_flags)
}
static int
-process_section_headers (file)
- FILE * file;
+process_section_headers (FILE *file)
{
- Elf_Internal_Shdr * section;
- unsigned int i;
+ Elf_Internal_Shdr *section;
+ unsigned int i;
section_headers = NULL;
@@ -3388,8 +3473,11 @@ process_section_headers (file)
if (section->sh_size != 0)
{
- string_table = (char *) get_data (NULL, file, section->sh_offset,
- section->sh_size, _("string table"));
+ string_table = get_data (NULL, file, section->sh_offset,
+ section->sh_size, _("string table"));
+
+ if (string_table == NULL)
+ return 0;
string_table_length = section->sh_size;
}
@@ -3399,12 +3487,13 @@ process_section_headers (file)
dynamic_symbols = NULL;
dynamic_strings = NULL;
dynamic_syminfo = NULL;
+ symtab_shndx_hdr = NULL;
for (i = 0, section = section_headers;
i < elf_header.e_shnum;
- i ++, section ++)
+ i++, section++)
{
- char * name = SECTION_NAME (section);
+ char *name = SECTION_NAME (section);
if (section->sh_type == SHT_DYNSYM)
{
@@ -3426,9 +3515,8 @@ process_section_headers (file)
continue;
}
- dynamic_strings = (char *) get_data (NULL, file, section->sh_offset,
- section->sh_size,
- _("dynamic strings"));
+ dynamic_strings = get_data (NULL, file, section->sh_offset,
+ section->sh_size, _("dynamic strings"));
}
else if (section->sh_type == SHT_SYMTAB_SHNDX)
{
@@ -3490,7 +3578,7 @@ process_section_headers (file)
for (i = 0, section = section_headers;
i < elf_header.e_shnum;
- i ++, section ++)
+ i++, section++)
{
printf (" [%2u] %-17.17s %-15.15s ",
SECTION_HEADER_NUM (i),
@@ -3588,13 +3676,25 @@ process_section_headers (file)
return 1;
}
+struct
+{
+ const char *name;
+ int reloc;
+ int size;
+ int rela;
+} dynamic_relocations [] =
+{
+ { "REL", DT_REL, DT_RELSZ, FALSE },
+ { "RELA", DT_RELA, DT_RELASZ, TRUE },
+ { "PLT", DT_JMPREL, DT_PLTRELSZ, UNKNOWN }
+};
+
/* Process the reloc section. */
static int
-process_relocs (file)
- FILE * file;
+process_relocs (FILE *file)
{
- unsigned long rel_size;
- unsigned long rel_offset;
+ unsigned long rel_size;
+ unsigned long rel_offset;
if (!do_reloc)
@@ -3602,63 +3702,62 @@ process_relocs (file)
if (do_using_dynamic)
{
- int is_rela = FALSE;
+ int is_rela;
+ const char *name;
+ int has_dynamic_reloc;
+ unsigned int i;
- rel_size = 0;
- rel_offset = 0;
+ has_dynamic_reloc = 0;
- if (dynamic_info[DT_REL])
- {
- rel_offset = dynamic_info[DT_REL];
- rel_size = dynamic_info[DT_RELSZ];
- is_rela = FALSE;
- }
- else if (dynamic_info [DT_RELA])
- {
- rel_offset = dynamic_info[DT_RELA];
- rel_size = dynamic_info[DT_RELASZ];
- is_rela = TRUE;
- }
- else if (dynamic_info[DT_JMPREL])
+ for (i = 0; i < ARRAY_SIZE (dynamic_relocations); i++)
{
- rel_offset = dynamic_info[DT_JMPREL];
- rel_size = dynamic_info[DT_PLTRELSZ];
+ is_rela = dynamic_relocations [i].rela;
+ name = dynamic_relocations [i].name;
+ rel_size = dynamic_info [dynamic_relocations [i].size];
+ rel_offset = dynamic_info [dynamic_relocations [i].reloc];
- switch (dynamic_info[DT_PLTREL])
+ has_dynamic_reloc |= rel_size;
+
+ if (is_rela == UNKNOWN)
{
- case DT_REL:
- is_rela = FALSE;
- break;
- case DT_RELA:
- is_rela = TRUE;
- break;
- default:
- is_rela = UNKNOWN;
- break;
+ if (dynamic_relocations [i].reloc == DT_JMPREL)
+ switch (dynamic_info[DT_PLTREL])
+ {
+ case DT_REL:
+ is_rela = FALSE;
+ break;
+ case DT_RELA:
+ is_rela = TRUE;
+ break;
+ }
}
- }
-
- if (rel_size)
- {
- printf
- (_("\nRelocation section at offset 0x%lx contains %ld bytes:\n"),
- rel_offset, rel_size);
- dump_relocations (file, rel_offset - loadaddr, rel_size,
- dynamic_symbols, num_dynamic_syms, dynamic_strings, is_rela);
+ if (rel_size)
+ {
+ printf
+ (_("\n'%s' relocation section at offset 0x%lx contains %ld bytes:\n"),
+ name, rel_offset, rel_size);
+
+ dump_relocations (file,
+ offset_from_vma (file, rel_offset, rel_size),
+ rel_size,
+ dynamic_symbols, num_dynamic_syms,
+ dynamic_strings, is_rela);
+ }
}
- else
+
+ if (! has_dynamic_reloc)
printf (_("\nThere are no dynamic relocations in this file.\n"));
}
else
{
- Elf32_Internal_Shdr * section;
- unsigned long i;
- int found = 0;
+ Elf_Internal_Shdr *section;
+ unsigned long i;
+ int found = 0;
for (i = 0, section = section_headers;
i < elf_header.e_shnum;
- i++, section ++)
+ i++, section++)
{
if ( section->sh_type != SHT_RELA
&& section->sh_type != SHT_REL)
@@ -3669,11 +3768,11 @@ process_relocs (file)
if (rel_size)
{
- Elf32_Internal_Shdr * strsec;
- Elf_Internal_Sym * symtab;
- char * strtab;
- int is_rela;
- unsigned long nsyms;
+ Elf_Internal_Shdr *strsec;
+ Elf_Internal_Sym *symtab;
+ char *strtab;
+ int is_rela;
+ unsigned long nsyms;
printf (_("\nRelocation section "));
@@ -3690,7 +3789,7 @@ process_relocs (file)
nsyms = 0;
if (section->sh_link)
{
- Elf32_Internal_Shdr * symsec;
+ Elf_Internal_Shdr *symsec;
symsec = SECTION_HEADER (section->sh_link);
nsyms = symsec->sh_size / symsec->sh_entsize;
@@ -3701,9 +3800,8 @@ process_relocs (file)
strsec = SECTION_HEADER (symsec->sh_link);
- strtab = (char *) get_data (NULL, file, strsec->sh_offset,
- strsec->sh_size,
- _("string table"));
+ strtab = get_data (NULL, file, strsec->sh_offset,
+ strsec->sh_size, _("string table"));
}
is_rela = section->sh_type == SHT_RELA;
@@ -3742,37 +3840,29 @@ struct unw_aux_info
{
struct unw_table_entry
{
- struct absaddr start;
- struct absaddr end;
- struct absaddr info;
+ struct absaddr start;
+ struct absaddr end;
+ struct absaddr info;
}
- *table; /* Unwind table. */
- unsigned long table_len; /* Length of unwind table. */
- unsigned char * info; /* Unwind info. */
- unsigned long info_size; /* Size of unwind info. */
- bfd_vma info_addr; /* starting address of unwind info. */
- bfd_vma seg_base; /* Starting address of segment. */
- Elf_Internal_Sym * symtab; /* The symbol table. */
- unsigned long nsyms; /* Number of symbols. */
- char * strtab; /* The string table. */
- unsigned long strtab_size; /* Size of string table. */
+ *table; /* Unwind table. */
+ unsigned long table_len; /* Length of unwind table. */
+ unsigned char *info; /* Unwind info. */
+ unsigned long info_size; /* Size of unwind info. */
+ bfd_vma info_addr; /* starting address of unwind info. */
+ bfd_vma seg_base; /* Starting address of segment. */
+ Elf_Internal_Sym *symtab; /* The symbol table. */
+ unsigned long nsyms; /* Number of symbols. */
+ char *strtab; /* The string table. */
+ unsigned long strtab_size; /* Size of string table. */
};
-static void find_symbol_for_address PARAMS ((struct unw_aux_info *,
- struct absaddr, const char **,
- bfd_vma *));
-static void dump_ia64_unwind PARAMS ((struct unw_aux_info *));
-static int slurp_ia64_unwind_table PARAMS ((FILE *, struct unw_aux_info *,
- Elf32_Internal_Shdr *));
-
static void
-find_symbol_for_address (aux, addr, symname, offset)
- struct unw_aux_info *aux;
- struct absaddr addr;
- const char **symname;
- bfd_vma *offset;
+find_symbol_for_address (struct unw_aux_info *aux,
+ struct absaddr addr,
+ const char **symname,
+ bfd_vma *offset)
{
- bfd_vma dist = (bfd_vma) 0x100000;
+ bfd_vma dist = 0x100000;
Elf_Internal_Sym *sym, *best = NULL;
unsigned long i;
@@ -3802,11 +3892,10 @@ find_symbol_for_address (aux, addr, symname, offset)
}
static void
-dump_ia64_unwind (aux)
- struct unw_aux_info *aux;
+dump_ia64_unwind (struct unw_aux_info *aux)
{
bfd_vma addr_size;
- struct unw_table_entry * tp;
+ struct unw_table_entry *tp;
int in_body;
addr_size = is_32bit_elf ? 4 : 8;
@@ -3815,9 +3904,9 @@ dump_ia64_unwind (aux)
{
bfd_vma stamp;
bfd_vma offset;
- const unsigned char * dp;
- const unsigned char * head;
- const char * procname;
+ const unsigned char *dp;
+ const unsigned char *head;
+ const char *procname;
find_symbol_for_address (aux, tp->start, &procname, &offset);
@@ -3835,13 +3924,13 @@ dump_ia64_unwind (aux)
print_vma (tp->start.offset, PREFIX_HEX);
fputc ('-', stdout);
print_vma (tp->end.offset, PREFIX_HEX);
- printf ("), info at +0x%lx\n",
+ printf ("], info at +0x%lx\n",
(unsigned long) (tp->info.offset - aux->seg_base));
head = aux->info + (tp->info.offset - aux->info_addr);
stamp = BYTE_GET8 ((unsigned char *) head);
- printf (" v%u, flags=0x%lx (%s%s ), len=%lu bytes\n",
+ printf (" v%u, flags=0x%lx (%s%s), len=%lu bytes\n",
(unsigned) UNW_VER (stamp),
(unsigned long) ((stamp & UNW_FLAG_MASK) >> 32),
UNW_FLAG_EHANDLER (stamp) ? " ehandler" : "",
@@ -3861,20 +3950,18 @@ dump_ia64_unwind (aux)
}
static int
-slurp_ia64_unwind_table (file, aux, sec)
- FILE *file;
- struct unw_aux_info *aux;
- Elf32_Internal_Shdr *sec;
+slurp_ia64_unwind_table (FILE *file,
+ struct unw_aux_info *aux,
+ Elf_Internal_Shdr *sec)
{
unsigned long size, addr_size, nrelas, i;
- Elf_Internal_Phdr *prog_hdrs, *seg;
+ Elf_Internal_Phdr *seg;
struct unw_table_entry *tep;
- Elf32_Internal_Shdr *relsec;
+ Elf_Internal_Shdr *relsec;
Elf_Internal_Rela *rela, *rp;
unsigned char *table, *tp;
Elf_Internal_Sym *sym;
const char *relname;
- int result;
addr_size = is_32bit_elf ? 4 : 8;
@@ -3883,21 +3970,12 @@ slurp_ia64_unwind_table (file, aux, sec)
if (elf_header.e_phnum)
{
- prog_hdrs = (Elf_Internal_Phdr *)
- xmalloc (elf_header.e_phnum * sizeof (Elf_Internal_Phdr));
-
- if (is_32bit_elf)
- result = get_32bit_program_headers (file, prog_hdrs);
- else
- result = get_64bit_program_headers (file, prog_hdrs);
-
- if (!result)
- {
- free (prog_hdrs);
+ if (! get_program_headers (file))
return 0;
- }
- for (seg = prog_hdrs; seg < prog_hdrs + elf_header.e_phnum; ++seg)
+ for (seg = program_headers;
+ seg < program_headers + elf_header.e_phnum;
+ ++seg)
{
if (seg->p_type != PT_LOAD)
continue;
@@ -3909,19 +3987,16 @@ slurp_ia64_unwind_table (file, aux, sec)
break;
}
}
-
- free (prog_hdrs);
}
/* Second, build the unwind table from the contents of the unwind section: */
size = sec->sh_size;
- table = (char *) get_data (NULL, file, sec->sh_offset,
- size, _("unwind table"));
+ table = get_data (NULL, file, sec->sh_offset, size, _("unwind table"));
if (!table)
return 0;
tep = aux->table = xmalloc (size / (3 * addr_size) * sizeof (aux->table[0]));
- for (tp = table; tp < table + size; tp += 3 * addr_size, ++ tep)
+ for (tp = table; tp < table + size; tp += 3 * addr_size, ++tep)
{
tep->start.section = SHN_UNDEF;
tep->end.section = SHN_UNDEF;
@@ -4020,10 +4095,9 @@ slurp_ia64_unwind_table (file, aux, sec)
}
static int
-process_unwind (file)
- FILE * file;
+process_unwind (FILE *file)
{
- Elf32_Internal_Shdr *sec, *unwsec = NULL, *strsec;
+ Elf_Internal_Shdr *sec, *unwsec = NULL, *strsec;
unsigned long i, addr_size, unwcount = 0, unwstart = 0;
struct unw_aux_info aux;
@@ -4049,8 +4123,8 @@ process_unwind (file)
strsec = SECTION_HEADER (sec->sh_link);
aux.strtab_size = strsec->sh_size;
- aux.strtab = (char *) get_data (NULL, file, strsec->sh_offset,
- aux.strtab_size, _("string table"));
+ aux.strtab = get_data (NULL, file, strsec->sh_offset,
+ aux.strtab_size, _("string table"));
}
else if (sec->sh_type == SHT_IA_64_UNWIND)
unwcount++;
@@ -4119,8 +4193,8 @@ process_unwind (file)
{
aux.info_size = sec->sh_size;
aux.info_addr = sec->sh_addr;
- aux.info = (char *) get_data (NULL, file, sec->sh_offset,
- aux.info_size, _("unwind info"));
+ aux.info = get_data (NULL, file, sec->sh_offset, aux.info_size,
+ _("unwind info"));
printf (_("\nUnwind section "));
@@ -4156,8 +4230,7 @@ process_unwind (file)
}
static void
-dynamic_segment_mips_val (entry)
- Elf_Internal_Dyn * entry;
+dynamic_segment_mips_val (Elf_Internal_Dyn *entry)
{
switch (entry->d_tag)
{
@@ -4176,7 +4249,7 @@ dynamic_segment_mips_val (entry)
};
unsigned int cnt;
int first = 1;
- for (cnt = 0; cnt < NUM_ELEM (opts); ++ cnt)
+ for (cnt = 0; cnt < NUM_ELEM (opts); ++cnt)
if (entry->d_un.d_val & (1 << cnt))
{
printf ("%s%s", first ? "" : " ", opts[cnt]);
@@ -4197,7 +4270,7 @@ dynamic_segment_mips_val (entry)
case DT_MIPS_TIME_STAMP:
{
char timebuf[20];
- struct tm * tmp;
+ struct tm *tmp;
time_t time = entry->d_un.d_val;
tmp = gmtime (&time);
@@ -4231,8 +4304,7 @@ dynamic_segment_mips_val (entry)
static void
-dynamic_segment_parisc_val (entry)
- Elf_Internal_Dyn * entry;
+dynamic_segment_parisc_val (Elf_Internal_Dyn *entry)
{
switch (entry->d_tag)
{
@@ -4241,7 +4313,7 @@ dynamic_segment_parisc_val (entry)
static struct
{
long int bit;
- const char * str;
+ const char *str;
}
flags[] =
{
@@ -4284,18 +4356,37 @@ dynamic_segment_parisc_val (entry)
print_vma (entry->d_un.d_ptr, PREFIX_HEX);
break;
}
+ putchar ('\n');
+}
+
+static void
+dynamic_segment_ia64_val (Elf_Internal_Dyn *entry)
+{
+ switch (entry->d_tag)
+ {
+ case DT_IA_64_PLT_RESERVE:
+ /* First 3 slots reserved. */
+ print_vma (entry->d_un.d_ptr, PREFIX_HEX);
+ printf (" -- ");
+ print_vma (entry->d_un.d_ptr + (3 * 8), PREFIX_HEX);
+ break;
+
+ default:
+ print_vma (entry->d_un.d_ptr, PREFIX_HEX);
+ break;
+ }
+ putchar ('\n');
}
static int
-get_32bit_dynamic_segment (file)
- FILE * file;
+get_32bit_dynamic_segment (FILE *file)
{
- Elf32_External_Dyn * edyn;
- Elf_Internal_Dyn * entry;
- bfd_size_type i;
+ Elf32_External_Dyn *edyn;
+ Elf_Internal_Dyn *entry;
+ bfd_size_type i;
- edyn = (Elf32_External_Dyn *) get_data (NULL, file, dynamic_addr,
- dynamic_size, _("dynamic segment"));
+ edyn = get_data (NULL, file, dynamic_addr, dynamic_size,
+ _("dynamic segment"));
if (!edyn)
return 0;
@@ -4303,11 +4394,10 @@ get_32bit_dynamic_segment (file)
how large this .dynamic is now. We can do this even before the byte
swapping since the DT_NULL tag is recognizable. */
dynamic_size = 0;
- while (*(Elf32_Word *) edyn [dynamic_size++].d_tag != DT_NULL)
+ while (*(Elf32_Word *) edyn[dynamic_size++].d_tag != DT_NULL)
;
- dynamic_segment = (Elf_Internal_Dyn *)
- malloc (dynamic_size * sizeof (Elf_Internal_Dyn));
+ dynamic_segment = malloc (dynamic_size * sizeof (Elf_Internal_Dyn));
if (dynamic_segment == NULL)
{
@@ -4318,10 +4408,10 @@ get_32bit_dynamic_segment (file)
for (i = 0, entry = dynamic_segment;
i < dynamic_size;
- i ++, entry ++)
+ i++, entry++)
{
- entry->d_tag = BYTE_GET (edyn [i].d_tag);
- entry->d_un.d_val = BYTE_GET (edyn [i].d_un.d_val);
+ entry->d_tag = BYTE_GET (edyn[i].d_tag);
+ entry->d_un.d_val = BYTE_GET (edyn[i].d_un.d_val);
}
free (edyn);
@@ -4330,15 +4420,14 @@ get_32bit_dynamic_segment (file)
}
static int
-get_64bit_dynamic_segment (file)
- FILE * file;
+get_64bit_dynamic_segment (FILE *file)
{
- Elf64_External_Dyn * edyn;
- Elf_Internal_Dyn * entry;
- bfd_size_type i;
+ Elf64_External_Dyn *edyn;
+ Elf_Internal_Dyn *entry;
+ bfd_size_type i;
- edyn = (Elf64_External_Dyn *) get_data (NULL, file, dynamic_addr,
- dynamic_size, _("dynamic segment"));
+ edyn = get_data (NULL, file, dynamic_addr, dynamic_size,
+ _("dynamic segment"));
if (!edyn)
return 0;
@@ -4346,11 +4435,10 @@ get_64bit_dynamic_segment (file)
how large this .dynamic is now. We can do this even before the byte
swapping since the DT_NULL tag is recognizable. */
dynamic_size = 0;
- while (*(bfd_vma *) edyn [dynamic_size ++].d_tag != DT_NULL)
+ while (*(bfd_vma *) edyn[dynamic_size++].d_tag != DT_NULL)
;
- dynamic_segment = (Elf_Internal_Dyn *)
- malloc (dynamic_size * sizeof (Elf_Internal_Dyn));
+ dynamic_segment = malloc (dynamic_size * sizeof (Elf_Internal_Dyn));
if (dynamic_segment == NULL)
{
@@ -4361,10 +4449,10 @@ get_64bit_dynamic_segment (file)
for (i = 0, entry = dynamic_segment;
i < dynamic_size;
- i ++, entry ++)
+ i++, entry++)
{
- entry->d_tag = BYTE_GET8 (edyn [i].d_tag);
- entry->d_un.d_val = BYTE_GET8 (edyn [i].d_un.d_val);
+ entry->d_tag = BYTE_GET8 (edyn[i].d_tag);
+ entry->d_un.d_val = BYTE_GET8 (edyn[i].d_un.d_val);
}
free (edyn);
@@ -4373,10 +4461,9 @@ get_64bit_dynamic_segment (file)
}
static const char *
-get_dynamic_flags (flags)
- bfd_vma flags;
+get_dynamic_flags (bfd_vma flags)
{
- static char buff [128];
+ static char buff[128];
char *p = buff;
*p = '\0';
@@ -4392,12 +4479,12 @@ get_dynamic_flags (flags)
switch (flag)
{
- case DF_ORIGIN: strcpy (p, "ORIGIN"); break;
- case DF_SYMBOLIC: strcpy (p, "SYMBOLIC"); break;
- case DF_TEXTREL: strcpy (p, "TEXTREL"); break;
- case DF_BIND_NOW: strcpy (p, "BIND_NOW"); break;
- case DF_STATIC_TLS: strcpy (p, "STATIC_TLS"); break;
- default: strcpy (p, "unknown"); break;
+ case DF_ORIGIN: strcpy (p, "ORIGIN"); break;
+ case DF_SYMBOLIC: strcpy (p, "SYMBOLIC"); break;
+ case DF_TEXTREL: strcpy (p, "TEXTREL"); break;
+ case DF_BIND_NOW: strcpy (p, "BIND_NOW"); break;
+ case DF_STATIC_TLS: strcpy (p, "STATIC_TLS"); break;
+ default: strcpy (p, "unknown"); break;
}
p = strchr (p, '\0');
@@ -4407,11 +4494,10 @@ get_dynamic_flags (flags)
/* Parse and display the contents of the dynamic segment. */
static int
-process_dynamic_segment (file)
- FILE * file;
+process_dynamic_segment (FILE *file)
{
- Elf_Internal_Dyn * entry;
- bfd_size_type i;
+ Elf_Internal_Dyn *entry;
+ bfd_size_type i;
if (dynamic_size == 0)
{
@@ -4434,9 +4520,9 @@ process_dynamic_segment (file)
{
for (i = 0, entry = dynamic_segment;
i < dynamic_size;
- ++i, ++ entry)
+ ++i, ++entry)
{
- Elf32_Internal_Shdr section;
+ Elf_Internal_Shdr section;
if (entry->d_tag != DT_SYMTAB)
continue;
@@ -4447,12 +4533,18 @@ process_dynamic_segment (file)
we default to reading in the entire file (!) and
processing that. This is overkill, I know, but it
should work. */
- section.sh_offset = entry->d_un.d_val - loadaddr;
+ section.sh_offset = offset_from_vma (file, entry->d_un.d_val, 0);
- if (fseek (file, 0, SEEK_END))
- error (_("Unable to seek to end of file!"));
+ if (archive_file_offset != 0)
+ section.sh_size = archive_file_size - section.sh_offset;
+ else
+ {
+ if (fseek (file, 0, SEEK_END))
+ error (_("Unable to seek to end of file!"));
+
+ section.sh_size = ftell (file) - section.sh_offset;
+ }
- section.sh_size = ftell (file) - section.sh_offset;
if (is_32bit_elf)
section.sh_entsize = sizeof (Elf32_External_Sym);
else
@@ -4474,10 +4566,10 @@ process_dynamic_segment (file)
{
for (i = 0, entry = dynamic_segment;
i < dynamic_size;
- ++i, ++ entry)
+ ++i, ++entry)
{
unsigned long offset;
- long str_tab_len;
+ long str_tab_len;
if (entry->d_tag != DT_STRTAB)
continue;
@@ -4489,10 +4581,16 @@ process_dynamic_segment (file)
processing that. This is overkill, I know, but it
should work. */
- offset = entry->d_un.d_val - loadaddr;
- if (fseek (file, 0, SEEK_END))
- error (_("Unable to seek to end of file\n"));
- str_tab_len = ftell (file) - offset;
+ offset = offset_from_vma (file, entry->d_un.d_val, 0);
+
+ if (archive_file_offset != 0)
+ str_tab_len = archive_file_size - offset;
+ else
+ {
+ if (fseek (file, 0, SEEK_END))
+ error (_("Unable to seek to end of file\n"));
+ str_tab_len = ftell (file) - offset;
+ }
if (str_tab_len < 1)
{
@@ -4501,8 +4599,8 @@ process_dynamic_segment (file)
continue;
}
- dynamic_strings = (char *) get_data (NULL, file, offset, str_tab_len,
- _("dynamic string table"));
+ dynamic_strings = get_data (NULL, file, offset, str_tab_len,
+ _("dynamic string table"));
break;
}
}
@@ -4510,11 +4608,11 @@ process_dynamic_segment (file)
/* And find the syminfo section if available. */
if (dynamic_syminfo == NULL)
{
- unsigned int syminsz = 0;
+ unsigned long syminsz = 0;
for (i = 0, entry = dynamic_segment;
i < dynamic_size;
- ++i, ++ entry)
+ ++i, ++entry)
{
if (entry->d_tag == DT_SYMINENT)
{
@@ -4525,22 +4623,22 @@ process_dynamic_segment (file)
else if (entry->d_tag == DT_SYMINSZ)
syminsz = entry->d_un.d_val;
else if (entry->d_tag == DT_SYMINFO)
- dynamic_syminfo_offset = entry->d_un.d_val - loadaddr;
+ dynamic_syminfo_offset = offset_from_vma (file, entry->d_un.d_val,
+ syminsz);
}
if (dynamic_syminfo_offset != 0 && syminsz != 0)
{
- Elf_External_Syminfo * extsyminfo;
- Elf_Internal_Syminfo * syminfo;
+ Elf_External_Syminfo *extsyminfo;
+ Elf_Internal_Syminfo *syminfo;
/* There is a syminfo section. Read the data. */
- extsyminfo = ((Elf_External_Syminfo *)
- get_data (NULL, file, dynamic_syminfo_offset,
- syminsz, _("symbol information")));
+ extsyminfo = get_data (NULL, file, dynamic_syminfo_offset, syminsz,
+ _("symbol information"));
if (!extsyminfo)
return 0;
- dynamic_syminfo = (Elf_Internal_Syminfo *) malloc (syminsz);
+ dynamic_syminfo = malloc (syminsz);
if (dynamic_syminfo == NULL)
{
error (_("Out of memory\n"));
@@ -4560,18 +4658,18 @@ process_dynamic_segment (file)
}
if (do_dynamic && dynamic_addr)
- printf (_("\nDynamic segment at offset 0x%x contains %ld entries:\n"),
+ printf (_("\nDynamic segment at offset 0x%lx contains %ld entries:\n"),
dynamic_addr, (long) dynamic_size);
if (do_dynamic)
printf (_(" Tag Type Name/Value\n"));
for (i = 0, entry = dynamic_segment;
i < dynamic_size;
- i++, entry ++)
+ i++, entry++)
{
if (do_dynamic)
{
- const char * dtype;
+ const char *dtype;
putchar (' ');
print_vma (entry->d_tag, FULL_HEX);
@@ -4597,7 +4695,7 @@ process_dynamic_segment (file)
if (do_dynamic)
{
switch (entry->d_tag)
- {
+ {
case DT_AUXILIARY:
printf (_("Auxiliary library"));
break;
@@ -4606,7 +4704,7 @@ process_dynamic_segment (file)
printf (_("Filter library"));
break;
- case DT_CONFIG:
+ case DT_CONFIG:
printf (_("Configuration file"));
break;
@@ -4634,11 +4732,13 @@ process_dynamic_segment (file)
if (do_dynamic)
{
printf (_("Flags:"));
+
if (entry->d_un.d_val == 0)
printf (_(" None\n"));
else
{
unsigned long int val = entry->d_un.d_val;
+
if (val & DTF_1_PARINIT)
{
printf (" PARINIT");
@@ -4660,11 +4760,13 @@ process_dynamic_segment (file)
if (do_dynamic)
{
printf (_("Flags:"));
+
if (entry->d_un.d_val == 0)
printf (_(" None\n"));
else
{
unsigned long int val = entry->d_un.d_val;
+
if (val & DF_P1_LAZYLOAD)
{
printf (" LAZYLOAD");
@@ -4691,6 +4793,7 @@ process_dynamic_segment (file)
else
{
unsigned long int val = entry->d_un.d_val;
+
if (val & DF_1_NOW)
{
printf (" NOW");
@@ -4769,6 +4872,7 @@ process_dynamic_segment (file)
break;
case DT_PLTREL:
+ dynamic_info[entry->d_tag] = entry->d_un.d_val;
if (do_dynamic)
puts (get_dynamic_type (entry->d_un.d_val));
break;
@@ -4794,7 +4898,7 @@ process_dynamic_segment (file)
if (do_dynamic)
{
- char * name;
+ char *name;
if (dynamic_strings == NULL)
name = NULL;
@@ -4843,6 +4947,7 @@ process_dynamic_segment (file)
case DT_RELAENT :
case DT_SYMENT :
case DT_RELENT :
+ dynamic_info[entry->d_tag] = entry->d_un.d_val;
case DT_PLTPADSZ:
case DT_MOVEENT :
case DT_MOVESZ :
@@ -4878,11 +4983,11 @@ process_dynamic_segment (file)
{
if (dynamic_strings != NULL && entry->d_tag == DT_USED)
{
- char * name;
+ char *name;
name = dynamic_strings + entry->d_un.d_val;
- if (* name)
+ if (*name)
{
printf (_("Not needed object: [%s]\n"), name);
break;
@@ -4896,12 +5001,14 @@ process_dynamic_segment (file)
case DT_BIND_NOW:
/* The value of this entry is ignored. */
+ if (do_dynamic)
+ putchar ('\n');
break;
case DT_GNU_PRELINKED:
if (do_dynamic)
{
- struct tm * tmp;
+ struct tm *tmp;
time_t time = entry->d_un.d_val;
tmp = gmtime (&time);
@@ -4914,7 +5021,7 @@ process_dynamic_segment (file)
default:
if ((entry->d_tag >= DT_VERSYM) && (entry->d_tag <= DT_VERNEEDNUM))
- version_info [DT_VERSIONTAGIDX (entry->d_tag)] =
+ version_info[DT_VERSIONTAGIDX (entry->d_tag)] =
entry->d_un.d_val;
if (do_dynamic)
@@ -4928,6 +5035,9 @@ process_dynamic_segment (file)
case EM_PARISC:
dynamic_segment_parisc_val (entry);
break;
+ case EM_IA_64:
+ dynamic_segment_ia64_val (entry);
+ break;
default:
print_vma (entry->d_un.d_val, PREFIX_HEX);
putchar ('\n');
@@ -4941,10 +5051,9 @@ process_dynamic_segment (file)
}
static char *
-get_ver_flags (flags)
- unsigned int flags;
+get_ver_flags (unsigned int flags)
{
- static char buff [32];
+ static char buff[32];
buff[0] = 0;
@@ -4970,27 +5079,26 @@ get_ver_flags (flags)
/* Display the contents of the version sections. */
static int
-process_version_sections (file)
- FILE * file;
+process_version_sections (FILE *file)
{
- Elf32_Internal_Shdr * section;
- unsigned i;
- int found = 0;
+ Elf_Internal_Shdr *section;
+ unsigned i;
+ int found = 0;
if (! do_version)
return 1;
for (i = 0, section = section_headers;
i < elf_header.e_shnum;
- i++, section ++)
+ i++, section++)
{
switch (section->sh_type)
{
case SHT_GNU_verdef:
{
- Elf_External_Verdef * edefs;
- unsigned int idx;
- unsigned int cnt;
+ Elf_External_Verdef *edefs;
+ unsigned int idx;
+ unsigned int cnt;
found = 1;
@@ -5004,22 +5112,20 @@ process_version_sections (file)
(unsigned long) section->sh_offset, section->sh_link,
SECTION_NAME (SECTION_HEADER (section->sh_link)));
- edefs = ((Elf_External_Verdef *)
- get_data (NULL, file, section->sh_offset,
- section->sh_size,
- _("version definition section")));
+ edefs = get_data (NULL, file, section->sh_offset, section->sh_size,
+ _("version definition section"));
if (!edefs)
break;
- for (idx = cnt = 0; cnt < section->sh_info; ++ cnt)
+ for (idx = cnt = 0; cnt < section->sh_info; ++cnt)
{
- char * vstart;
- Elf_External_Verdef * edef;
- Elf_Internal_Verdef ent;
- Elf_External_Verdaux * eaux;
- Elf_Internal_Verdaux aux;
- int j;
- int isum;
+ char *vstart;
+ Elf_External_Verdef *edef;
+ Elf_Internal_Verdef ent;
+ Elf_External_Verdaux *eaux;
+ Elf_Internal_Verdaux aux;
+ int j;
+ int isum;
vstart = ((char *) edefs) + idx;
@@ -5053,7 +5159,7 @@ process_version_sections (file)
isum = idx + ent.vd_aux;
- for (j = 1; j < ent.vd_cnt; j ++)
+ for (j = 1; j < ent.vd_cnt; j++)
{
isum += aux.vda_next;
vstart += aux.vda_next;
@@ -5080,9 +5186,9 @@ process_version_sections (file)
case SHT_GNU_verneed:
{
- Elf_External_Verneed * eneed;
- unsigned int idx;
- unsigned int cnt;
+ Elf_External_Verneed *eneed;
+ unsigned int idx;
+ unsigned int cnt;
found = 1;
@@ -5095,19 +5201,18 @@ process_version_sections (file)
(unsigned long) section->sh_offset, section->sh_link,
SECTION_NAME (SECTION_HEADER (section->sh_link)));
- eneed = ((Elf_External_Verneed *)
- get_data (NULL, file, section->sh_offset,
- section->sh_size, _("version need section")));
+ eneed = get_data (NULL, file, section->sh_offset, section->sh_size,
+ _("version need section"));
if (!eneed)
break;
for (idx = cnt = 0; cnt < section->sh_info; ++cnt)
{
- Elf_External_Verneed * entry;
- Elf_Internal_Verneed ent;
- int j;
- int isum;
- char * vstart;
+ Elf_External_Verneed *entry;
+ Elf_Internal_Verneed ent;
+ int j;
+ int isum;
+ char *vstart;
vstart = ((char *) eneed) + idx;
@@ -5132,8 +5237,8 @@ process_version_sections (file)
for (j = 0, isum = idx + ent.vn_aux; j < ent.vn_cnt; ++j)
{
- Elf_External_Vernaux * eaux;
- Elf_Internal_Vernaux aux;
+ Elf_External_Vernaux *eaux;
+ Elf_Internal_Vernaux aux;
eaux = (Elf_External_Vernaux *) vstart;
@@ -5144,10 +5249,10 @@ process_version_sections (file)
aux.vna_next = BYTE_GET (eaux->vna_next);
if (dynamic_strings)
- printf (_(" %#06x: Name: %s"),
+ printf (_(" %#06x: Name: %s"),
isum, dynamic_strings + aux.vna_name);
else
- printf (_(" %#06x: Name index: %lx"),
+ printf (_(" %#06x: Name index: %lx"),
isum, aux.vna_name);
printf (_(" Flags: %s Version: %d\n"),
@@ -5166,14 +5271,15 @@ process_version_sections (file)
case SHT_GNU_versym:
{
- Elf32_Internal_Shdr * link_section;
- int total;
- int cnt;
- unsigned char * edata;
- unsigned short * data;
- char * strtab;
- Elf_Internal_Sym * symbols;
- Elf32_Internal_Shdr * string_sec;
+ Elf_Internal_Shdr *link_section;
+ int total;
+ int cnt;
+ unsigned char *edata;
+ unsigned short *data;
+ char *strtab;
+ Elf_Internal_Sym *symbols;
+ Elf_Internal_Shdr *string_sec;
+ long off;
link_section = SECTION_HEADER (section->sh_link);
total = section->sh_size / section->sh_entsize;
@@ -5184,9 +5290,8 @@ process_version_sections (file)
string_sec = SECTION_HEADER (link_section->sh_link);
- strtab = (char *) get_data (NULL, file, string_sec->sh_offset,
- string_sec->sh_size,
- _("version string table"));
+ strtab = get_data (NULL, file, string_sec->sh_offset,
+ string_sec->sh_size, _("version string table"));
if (!strtab)
break;
@@ -5199,22 +5304,22 @@ process_version_sections (file)
(unsigned long) section->sh_offset, section->sh_link,
SECTION_NAME (link_section));
- edata =
- ((unsigned char *)
- get_data (NULL, file,
- version_info[DT_VERSIONTAGIDX (DT_VERSYM)] - loadaddr,
- total * sizeof (short), _("version symbol data")));
+ off = offset_from_vma (file,
+ version_info[DT_VERSIONTAGIDX (DT_VERSYM)],
+ total * sizeof (short));
+ edata = get_data (NULL, file, off, total * sizeof (short),
+ _("version symbol data"));
if (!edata)
{
free (strtab);
break;
}
- data = (unsigned short *) malloc (total * sizeof (short));
+ data = malloc (total * sizeof (short));
for (cnt = total; cnt --;)
- data [cnt] = byte_get (edata + cnt * sizeof (short),
- sizeof (short));
+ data[cnt] = byte_get (edata + cnt * sizeof (short),
+ sizeof (short));
free (edata);
@@ -5222,12 +5327,12 @@ process_version_sections (file)
{
int j, nn;
int check_def, check_need;
- char * name;
+ char *name;
printf (" %03x:", cnt);
for (j = 0; (j < 4) && (cnt + j) < total; ++j)
- switch (data [cnt + j])
+ switch (data[cnt + j])
{
case 0:
fputs (_(" 0 (*local*) "), stdout);
@@ -5238,35 +5343,36 @@ process_version_sections (file)
break;
default:
- nn = printf ("%4x%c", data [cnt + j] & 0x7fff,
- data [cnt + j] & 0x8000 ? 'h' : ' ');
+ nn = printf ("%4x%c", data[cnt + j] & 0x7fff,
+ data[cnt + j] & 0x8000 ? 'h' : ' ');
check_def = 1;
check_need = 1;
- if (SECTION_HEADER (symbols [cnt + j].st_shndx)->sh_type
+ if (SECTION_HEADER (symbols[cnt + j].st_shndx)->sh_type
!= SHT_NOBITS)
{
- if (symbols [cnt + j].st_shndx == SHN_UNDEF)
+ if (symbols[cnt + j].st_shndx == SHN_UNDEF)
check_def = 0;
else
check_need = 0;
}
if (check_need
- && version_info [DT_VERSIONTAGIDX (DT_VERNEED)])
+ && version_info[DT_VERSIONTAGIDX (DT_VERNEED)])
{
- Elf_Internal_Verneed ivn;
- unsigned long offset;
+ Elf_Internal_Verneed ivn;
+ unsigned long offset;
- offset = version_info [DT_VERSIONTAGIDX (DT_VERNEED)]
- - loadaddr;
+ offset = offset_from_vma
+ (file, version_info[DT_VERSIONTAGIDX (DT_VERNEED)],
+ sizeof (Elf_External_Verneed));
- do
+ do
{
- Elf_Internal_Vernaux ivna;
- Elf_External_Verneed evn;
- Elf_External_Vernaux evna;
- unsigned long a_off;
+ Elf_Internal_Vernaux ivna;
+ Elf_External_Verneed evn;
+ Elf_External_Vernaux evna;
+ unsigned long a_off;
get_data (&evn, file, offset, sizeof (evn),
_("version need"));
@@ -5286,10 +5392,10 @@ process_version_sections (file)
a_off += ivna.vna_next;
}
- while (ivna.vna_other != data [cnt + j]
+ while (ivna.vna_other != data[cnt + j]
&& ivna.vna_next != 0);
- if (ivna.vna_other == data [cnt + j])
+ if (ivna.vna_other == data[cnt + j])
{
ivna.vna_name = BYTE_GET (evna.vna_name);
@@ -5307,15 +5413,16 @@ process_version_sections (file)
while (ivn.vn_next);
}
- if (check_def && data [cnt + j] != 0x8001
- && version_info [DT_VERSIONTAGIDX (DT_VERDEF)])
+ if (check_def && data[cnt + j] != 0x8001
+ && version_info[DT_VERSIONTAGIDX (DT_VERDEF)])
{
- Elf_Internal_Verdef ivd;
- Elf_External_Verdef evd;
- unsigned long offset;
+ Elf_Internal_Verdef ivd;
+ Elf_External_Verdef evd;
+ unsigned long offset;
- offset = version_info
- [DT_VERSIONTAGIDX (DT_VERDEF)] - loadaddr;
+ offset = offset_from_vma
+ (file, version_info[DT_VERSIONTAGIDX (DT_VERDEF)],
+ sizeof evd);
do
{
@@ -5327,13 +5434,13 @@ process_version_sections (file)
offset += ivd.vd_next;
}
- while (ivd.vd_ndx != (data [cnt + j] & 0x7fff)
+ while (ivd.vd_ndx != (data[cnt + j] & 0x7fff)
&& ivd.vd_next != 0);
- if (ivd.vd_ndx == (data [cnt + j] & 0x7fff))
+ if (ivd.vd_ndx == (data[cnt + j] & 0x7fff))
{
- Elf_External_Verdaux evda;
- Elf_Internal_Verdaux ivda;
+ Elf_External_Verdaux evda;
+ Elf_Internal_Verdaux ivda;
ivd.vd_aux = BYTE_GET (evd.vd_aux);
@@ -5376,16 +5483,15 @@ process_version_sections (file)
}
static const char *
-get_symbol_binding (binding)
- unsigned int binding;
+get_symbol_binding (unsigned int binding)
{
- static char buff [32];
+ static char buff[32];
switch (binding)
{
- case STB_LOCAL: return "LOCAL";
- case STB_GLOBAL: return "GLOBAL";
- case STB_WEAK: return "WEAK";
+ case STB_LOCAL: return "LOCAL";
+ case STB_GLOBAL: return "GLOBAL";
+ case STB_WEAK: return "WEAK";
default:
if (binding >= STB_LOPROC && binding <= STB_HIPROC)
sprintf (buff, _("<processor specific>: %d"), binding);
@@ -5398,20 +5504,19 @@ get_symbol_binding (binding)
}
static const char *
-get_symbol_type (type)
- unsigned int type;
+get_symbol_type (unsigned int type)
{
- static char buff [32];
+ static char buff[32];
switch (type)
{
- case STT_NOTYPE: return "NOTYPE";
- case STT_OBJECT: return "OBJECT";
- case STT_FUNC: return "FUNC";
- case STT_SECTION: return "SECTION";
- case STT_FILE: return "FILE";
- case STT_COMMON: return "COMMON";
- case STT_TLS: return "TLS";
+ case STT_NOTYPE: return "NOTYPE";
+ case STT_OBJECT: return "OBJECT";
+ case STT_FUNC: return "FUNC";
+ case STT_SECTION: return "SECTION";
+ case STT_FILE: return "FILE";
+ case STT_COMMON: return "COMMON";
+ case STT_TLS: return "TLS";
default:
if (type >= STT_LOPROC && type <= STT_HIPROC)
{
@@ -5445,54 +5550,54 @@ get_symbol_type (type)
}
static const char *
-get_symbol_visibility (visibility)
- unsigned int visibility;
+get_symbol_visibility (unsigned int visibility)
{
switch (visibility)
{
- case STV_DEFAULT: return "DEFAULT";
- case STV_INTERNAL: return "INTERNAL";
- case STV_HIDDEN: return "HIDDEN";
+ case STV_DEFAULT: return "DEFAULT";
+ case STV_INTERNAL: return "INTERNAL";
+ case STV_HIDDEN: return "HIDDEN";
case STV_PROTECTED: return "PROTECTED";
default: abort ();
}
}
static const char *
-get_symbol_index_type (type)
- unsigned int type;
+get_symbol_index_type (unsigned int type)
{
+ static char buff[32];
+
switch (type)
{
- case SHN_UNDEF: return "UND";
- case SHN_ABS: return "ABS";
- case SHN_COMMON: return "COM";
+ case SHN_UNDEF: return "UND";
+ case SHN_ABS: return "ABS";
+ case SHN_COMMON: return "COM";
default:
- if (type >= SHN_LOPROC && type <= SHN_HIPROC)
- return "PRC";
+ if (type == SHN_IA_64_ANSI_COMMON
+ && elf_header.e_machine == EM_IA_64
+ && elf_header.e_ident[EI_OSABI] == ELFOSABI_HPUX)
+ return "ANSI_COM";
+ else if (type >= SHN_LOPROC && type <= SHN_HIPROC)
+ sprintf (buff, "PRC[0x%04x]", type);
else if (type >= SHN_LOOS && type <= SHN_HIOS)
- return "OS ";
+ sprintf (buff, "OS [0x%04x]", type);
else if (type >= SHN_LORESERVE && type <= SHN_HIRESERVE)
- return "RSV";
+ sprintf (buff, "RSV[0x%04x]", type);
else
- {
- static char buff [32];
-
- sprintf (buff, "%3d", type);
- return buff;
- }
+ sprintf (buff, "%3d", type);
+ break;
}
+
+ return buff;
}
static int *
-get_dynamic_data (file, number)
- FILE * file;
- unsigned int number;
+get_dynamic_data (FILE *file, unsigned int number)
{
- unsigned char * e_data;
- int * i_data;
+ unsigned char *e_data;
+ int *i_data;
- e_data = (unsigned char *) malloc (number * 4);
+ e_data = malloc (number * 4);
if (e_data == NULL)
{
@@ -5506,7 +5611,7 @@ get_dynamic_data (file, number)
return NULL;
}
- i_data = (int *) malloc (number * sizeof (* i_data));
+ i_data = malloc (number * sizeof (*i_data));
if (i_data == NULL)
{
@@ -5516,7 +5621,7 @@ get_dynamic_data (file, number)
}
while (number--)
- i_data [number] = byte_get (e_data + number * 4, 4);
+ i_data[number] = byte_get (e_data + number * 4, 4);
free (e_data);
@@ -5525,16 +5630,15 @@ get_dynamic_data (file, number)
/* Dump the symbol table. */
static int
-process_symbol_table (file)
- FILE * file;
+process_symbol_table (FILE *file)
{
- Elf32_Internal_Shdr * section;
- unsigned char nb [4];
- unsigned char nc [4];
- int nbuckets = 0;
- int nchains = 0;
- int * buckets = NULL;
- int * chains = NULL;
+ Elf_Internal_Shdr *section;
+ unsigned char nb[4];
+ unsigned char nc[4];
+ int nbuckets = 0;
+ int nchains = 0;
+ int *buckets = NULL;
+ int *chains = NULL;
if (! do_syms && !do_histogram)
return 1;
@@ -5542,7 +5646,11 @@ process_symbol_table (file)
if (dynamic_info[DT_HASH] && ((do_using_dynamic && dynamic_strings != NULL)
|| do_histogram))
{
- if (fseek (file, dynamic_info[DT_HASH] - loadaddr, SEEK_SET))
+ if (fseek (file,
+ (archive_file_offset
+ + offset_from_vma (file, dynamic_info[DT_HASH],
+ sizeof nb + sizeof nc)),
+ SEEK_SET))
{
error (_("Unable to seek to start of dynamic information"));
return 0;
@@ -5573,8 +5681,8 @@ process_symbol_table (file)
if (do_syms
&& dynamic_info[DT_HASH] && do_using_dynamic && dynamic_strings != NULL)
{
- int hn;
- int si;
+ int hn;
+ int si;
printf (_("\nSymbol table for image:\n"));
if (is_32bit_elf)
@@ -5584,12 +5692,12 @@ process_symbol_table (file)
for (hn = 0; hn < nbuckets; hn++)
{
- if (! buckets [hn])
+ if (! buckets[hn])
continue;
- for (si = buckets [hn]; si < nchains && si > 0; si = chains [si])
+ for (si = buckets[hn]; si < nchains && si > 0; si = chains[si])
{
- Elf_Internal_Sym * psym;
+ Elf_Internal_Sym *psym;
psym = dynamic_symbols + si;
@@ -5609,16 +5717,16 @@ process_symbol_table (file)
}
else if (do_syms && !do_using_dynamic)
{
- unsigned int i;
+ unsigned int i;
for (i = 0, section = section_headers;
i < elf_header.e_shnum;
i++, section++)
{
- unsigned int si;
- char * strtab;
- Elf_Internal_Sym * symtab;
- Elf_Internal_Sym * psym;
+ unsigned int si;
+ char *strtab;
+ Elf_Internal_Sym *symtab;
+ Elf_Internal_Sym *psym;
if ( section->sh_type != SHT_SYMTAB
@@ -5641,18 +5749,17 @@ process_symbol_table (file)
strtab = string_table;
else
{
- Elf32_Internal_Shdr * string_sec;
+ Elf_Internal_Shdr *string_sec;
string_sec = SECTION_HEADER (section->sh_link);
- strtab = (char *) get_data (NULL, file, string_sec->sh_offset,
- string_sec->sh_size,
- _("string table"));
+ strtab = get_data (NULL, file, string_sec->sh_offset,
+ string_sec->sh_size, _("string table"));
}
for (si = 0, psym = symtab;
si < section->sh_size / section->sh_entsize;
- si ++, psym ++)
+ si++, psym++)
{
printf ("%6d: ", si);
print_vma (psym->st_value, LONG_HEX);
@@ -5665,16 +5772,17 @@ process_symbol_table (file)
print_symbol (25, strtab + psym->st_name);
if (section->sh_type == SHT_DYNSYM &&
- version_info [DT_VERSIONTAGIDX (DT_VERSYM)] != 0)
+ version_info[DT_VERSIONTAGIDX (DT_VERSYM)] != 0)
{
- unsigned char data[2];
- unsigned short vers_data;
- unsigned long offset;
- int is_nobits;
- int check_def;
+ unsigned char data[2];
+ unsigned short vers_data;
+ unsigned long offset;
+ int is_nobits;
+ int check_def;
- offset = version_info [DT_VERSIONTAGIDX (DT_VERSYM)]
- - loadaddr;
+ offset = offset_from_vma
+ (file, version_info[DT_VERSIONTAGIDX (DT_VERSYM)],
+ sizeof data + si * sizeof (vers_data));
get_data (&data, file, offset + si * sizeof (vers_data),
sizeof (data), _("version data"));
@@ -5688,20 +5796,21 @@ process_symbol_table (file)
if ((vers_data & 0x8000) || vers_data > 1)
{
- if (version_info [DT_VERSIONTAGIDX (DT_VERNEED)]
+ if (version_info[DT_VERSIONTAGIDX (DT_VERNEED)]
&& (is_nobits || ! check_def))
{
- Elf_External_Verneed evn;
- Elf_Internal_Verneed ivn;
- Elf_Internal_Vernaux ivna;
+ Elf_External_Verneed evn;
+ Elf_Internal_Verneed ivn;
+ Elf_Internal_Vernaux ivna;
/* We must test both. */
- offset = version_info
- [DT_VERSIONTAGIDX (DT_VERNEED)] - loadaddr;
+ offset = offset_from_vma
+ (file, version_info[DT_VERSIONTAGIDX (DT_VERNEED)],
+ sizeof evn);
do
{
- unsigned long vna_off;
+ unsigned long vna_off;
get_data (&evn, file, offset, sizeof (evn),
_("version need"));
@@ -5713,7 +5822,7 @@ process_symbol_table (file)
do
{
- Elf_External_Vernaux evna;
+ Elf_External_Vernaux evna;
get_data (&evna, file, vna_off,
sizeof (evna),
@@ -5750,26 +5859,27 @@ process_symbol_table (file)
if (check_def)
{
if (vers_data != 0x8001
- && version_info [DT_VERSIONTAGIDX (DT_VERDEF)])
+ && version_info[DT_VERSIONTAGIDX (DT_VERDEF)])
{
- Elf_Internal_Verdef ivd;
- Elf_Internal_Verdaux ivda;
- Elf_External_Verdaux evda;
- unsigned long offset;
+ Elf_Internal_Verdef ivd;
+ Elf_Internal_Verdaux ivda;
+ Elf_External_Verdaux evda;
+ unsigned long offset;
- offset =
- version_info [DT_VERSIONTAGIDX (DT_VERDEF)]
- - loadaddr;
+ offset = offset_from_vma
+ (file,
+ version_info[DT_VERSIONTAGIDX (DT_VERDEF)],
+ sizeof (Elf_External_Verdef));
do
{
- Elf_External_Verdef evd;
+ Elf_External_Verdef evd;
get_data (&evd, file, offset, sizeof (evd),
_("version def"));
- ivd.vd_ndx = BYTE_GET (evd.vd_ndx);
- ivd.vd_aux = BYTE_GET (evd.vd_aux);
+ ivd.vd_ndx = BYTE_GET (evd.vd_ndx);
+ ivd.vd_aux = BYTE_GET (evd.vd_aux);
ivd.vd_next = BYTE_GET (evd.vd_next);
offset += ivd.vd_next;
@@ -5808,19 +5918,19 @@ process_symbol_table (file)
if (do_histogram && buckets != NULL)
{
- int * lengths;
- int * counts;
- int hn;
- int si;
- int maxlength = 0;
- int nzero_counts = 0;
- int nsyms = 0;
+ int *lengths;
+ int *counts;
+ int hn;
+ int si;
+ int maxlength = 0;
+ int nzero_counts = 0;
+ int nsyms = 0;
printf (_("\nHistogram for bucket list length (total of %d buckets):\n"),
nbuckets);
printf (_(" Length Number %% of total Coverage\n"));
- lengths = (int *) calloc (nbuckets, sizeof (int));
+ lengths = calloc (nbuckets, sizeof (int));
if (lengths == NULL)
{
error (_("Out of memory"));
@@ -5828,18 +5938,18 @@ process_symbol_table (file)
}
for (hn = 0; hn < nbuckets; ++hn)
{
- if (! buckets [hn])
+ if (! buckets[hn])
continue;
for (si = buckets[hn]; si > 0 && si < nchains; si = chains[si])
{
- ++ nsyms;
+ ++nsyms;
if (maxlength < ++lengths[hn])
- ++ maxlength;
+ ++maxlength;
}
}
- counts = (int *) calloc (maxlength + 1, sizeof (int));
+ counts = calloc (maxlength + 1, sizeof (int));
if (counts == NULL)
{
error (_("Out of memory"));
@@ -5847,7 +5957,7 @@ process_symbol_table (file)
}
for (hn = 0; hn < nbuckets; ++hn)
- ++ counts [lengths [hn]];
+ ++counts[lengths[hn]];
if (nbuckets > 0)
{
@@ -5876,8 +5986,7 @@ process_symbol_table (file)
}
static int
-process_syminfo (file)
- FILE * file ATTRIBUTE_UNUSED;
+process_syminfo (FILE *file ATTRIBUTE_UNUSED)
{
unsigned int i;
@@ -5915,9 +6024,10 @@ process_syminfo (file)
if (dynamic_syminfo[i].si_boundto > 0
&& dynamic_syminfo[i].si_boundto < dynamic_size)
{
- print_symbol (10, dynamic_strings
- + dynamic_segment
- [dynamic_syminfo[i].si_boundto].d_un.d_val);
+ print_symbol (10,
+ dynamic_strings
+ + (dynamic_segment
+ [dynamic_syminfo[i].si_boundto].d_un.d_val));
putchar (' ' );
}
else
@@ -5942,9 +6052,7 @@ process_syminfo (file)
#ifdef SUPPORT_DISASSEMBLY
static void
-disassemble_section (section, file)
- Elf32_Internal_Shdr * section;
- FILE * file;
+disassemble_section (Elf_Internal_Shdr *section, FILE *file)
{
printf (_("\nAssembly dump of section %s\n"),
SECTION_NAME (section));
@@ -5956,18 +6064,16 @@ disassemble_section (section, file)
#endif
static int
-dump_section (section, file)
- Elf32_Internal_Shdr * section;
- FILE * file;
+dump_section (Elf_Internal_Shdr *section, FILE *file)
{
- bfd_size_type bytes;
- bfd_vma addr;
- unsigned char * data;
- unsigned char * start;
+ bfd_size_type bytes;
+ bfd_vma addr;
+ unsigned char *data;
+ unsigned char *start;
bytes = section->sh_size;
- if (bytes == 0)
+ if (bytes == 0 || section->sh_type == SHT_NOBITS)
{
printf (_("\nSection '%s' has no data to dump.\n"),
SECTION_NAME (section));
@@ -5978,8 +6084,7 @@ dump_section (section, file)
addr = section->sh_addr;
- start = (unsigned char *) get_data (NULL, file, section->sh_offset, bytes,
- _("section data"));
+ start = get_data (NULL, file, section->sh_offset, bytes, _("section data"));
if (!start)
return 0;
@@ -5995,14 +6100,14 @@ dump_section (section, file)
printf (" 0x%8.8lx ", (unsigned long) addr);
- switch (elf_header.e_ident [EI_DATA])
+ switch (elf_header.e_ident[EI_DATA])
{
default:
case ELFDATA2LSB:
for (j = 15; j >= 0; j --)
{
if (j < lbytes)
- printf ("%2.2x", data [j]);
+ printf ("%2.2x", data[j]);
else
printf (" ");
@@ -6015,7 +6120,7 @@ dump_section (section, file)
for (j = 0; j < 16; j++)
{
if (j < lbytes)
- printf ("%2.2x", data [j]);
+ printf ("%2.2x", data[j]);
else
printf (" ");
@@ -6027,8 +6132,8 @@ dump_section (section, file)
for (j = 0; j < lbytes; j++)
{
- k = data [j];
- if (k >= ' ' && k < 0x80)
+ k = data[j];
+ if (k >= ' ' && k < 0x7f)
printf ("%c", k);
else
printf (".");
@@ -6048,20 +6153,17 @@ dump_section (section, file)
static unsigned long int
-read_leb128 (data, length_return, sign)
- unsigned char * data;
- int * length_return;
- int sign;
+read_leb128 (unsigned char *data, int *length_return, int sign)
{
unsigned long int result = 0;
- unsigned int num_read = 0;
- int shift = 0;
- unsigned char byte;
+ unsigned int num_read = 0;
+ int shift = 0;
+ unsigned char byte;
do
{
- byte = * data ++;
- num_read ++;
+ byte = *data++;
+ num_read++;
result |= (byte & 0x7f) << shift;
@@ -6071,7 +6173,7 @@ read_leb128 (data, length_return, sign)
while (byte & 0x80);
if (length_return != NULL)
- * length_return = num_read;
+ *length_return = num_read;
if (sign && (shift < 32) && (byte & 0x40))
result |= -1 << shift;
@@ -6081,23 +6183,22 @@ read_leb128 (data, length_return, sign)
typedef struct State_Machine_Registers
{
- unsigned long address;
- unsigned int file;
- unsigned int line;
- unsigned int column;
- int is_stmt;
- int basic_block;
- int end_sequence;
+ unsigned long address;
+ unsigned int file;
+ unsigned int line;
+ unsigned int column;
+ int is_stmt;
+ int basic_block;
+ int end_sequence;
/* This variable hold the number of the last entry seen
in the File Table. */
- unsigned int last_file_entry;
+ unsigned int last_file_entry;
} SMR;
static SMR state_machine_regs;
static void
-reset_state_machine (is_stmt)
- int is_stmt;
+reset_state_machine (int is_stmt)
{
state_machine_regs.address = 0;
state_machine_regs.file = 1;
@@ -6112,16 +6213,13 @@ reset_state_machine (is_stmt)
/* Handled an extend line op. Returns true if this is the end
of sequence. */
static int
-process_extended_line_op (data, is_stmt, pointer_size)
- unsigned char * data;
- int is_stmt;
- int pointer_size;
+process_extended_line_op (unsigned char *data, int is_stmt, int pointer_size)
{
- unsigned char op_code;
- int bytes_read;
- unsigned int len;
- unsigned char * name;
- unsigned long adr;
+ unsigned char op_code;
+ int bytes_read;
+ unsigned int len;
+ unsigned char *name;
+ unsigned long adr;
len = read_leb128 (data, & bytes_read, 0);
data += bytes_read;
@@ -6133,7 +6231,7 @@ process_extended_line_op (data, is_stmt, pointer_size)
}
len += bytes_read;
- op_code = * data ++;
+ op_code = *data++;
printf (_(" Extended opcode %d: "), op_code);
@@ -6154,7 +6252,7 @@ process_extended_line_op (data, is_stmt, pointer_size)
printf (_(" define new File Table entry\n"));
printf (_(" Entry\tDir\tTime\tSize\tName\n"));
- printf (_(" %d\t"), ++ state_machine_regs.last_file_entry);
+ printf (_(" %d\t"), ++state_machine_regs.last_file_entry);
name = data;
data += strlen ((char *) data) + 1;
printf (_("%lu\t"), read_leb128 (data, & bytes_read, 0));
@@ -6173,42 +6271,180 @@ process_extended_line_op (data, is_stmt, pointer_size)
return len;
}
+/* Finds section NAME inside FILE and returns a
+ pointer to it, or NULL upon failure. */
+
+static Elf_Internal_Shdr *
+find_section (const char * name)
+{
+ Elf_Internal_Shdr *sec;
+ unsigned int i;
+
+ for (i = elf_header.e_shnum, sec = section_headers + i - 1;
+ i; --i, --sec)
+ if (strcmp (SECTION_NAME (sec), name) == 0)
+ break;
+
+ if (i && sec && sec->sh_size != 0)
+ return sec;
+
+ return NULL;
+}
+
/* Size of pointers in the .debug_line section. This information is not
really present in that section. It's obtained before dumping the debug
sections by doing some pre-scan of the .debug_info section. */
-static int debug_line_pointer_size = 4;
+static unsigned int * debug_line_pointer_sizes = NULL;
+static unsigned int num_debug_line_pointer_sizes = 0;
+
+/* Locate and scan the .debug_info section in the file and record the pointer
+ sizes for the compilation units in it. Usually an executable will have
+ just one pointer size, but this is not guaranteed, and so we try not to
+ make any assumptions. Returns zero upon failure, or the number of
+ compilation units upon success. */
+
+static unsigned int
+get_debug_line_pointer_sizes (FILE * file)
+{
+ Elf_Internal_Shdr * section;
+ unsigned char * start;
+ unsigned char * end;
+ unsigned char * begin;
+ unsigned long length;
+ unsigned int num_units;
+ unsigned int unit;
+
+ section = find_section (".debug_info");
+ if (section == NULL)
+ return 0;
+
+ length = section->sh_size;
+ start = get_data (NULL, file, section->sh_offset, section->sh_size,
+ _("extracting pointer sizes from .debug_info section"));
+ if (start == NULL)
+ return 0;
+
+ end = start + section->sh_size;
+ /* First scan the section to get the number of comp units. */
+ for (begin = start, num_units = 0; begin < end; num_units++)
+ {
+ /* Read the first 4 bytes. For a 32-bit DWARF section, this will
+ be the length. For a 64-bit DWARF section, it'll be the escape
+ code 0xffffffff followed by an 8 byte length. */
+ length = byte_get (begin, 4);
+
+ if (length == 0xffffffff)
+ {
+ length = byte_get (begin + 4, 8);
+ begin += length + 12;
+ }
+ else
+ begin += length + 4;
+ }
+
+ if (num_units == 0)
+ {
+ error (_("No comp units in .debug_info section ?"));
+ free (start);
+ return 0;
+ }
+
+ /* Then allocate an array to hold the pointer sizes. */
+ debug_line_pointer_sizes = malloc (num_units * sizeof * debug_line_pointer_sizes);
+ if (debug_line_pointer_sizes == NULL)
+ {
+ error (_("Not enough memory for a pointer size array of %u entries"),
+ num_units);
+ free (start);
+ return 0;
+ }
+
+ /* Populate the array. */
+ for (begin = start, unit = 0; begin < end; unit++)
+ {
+ length = byte_get (begin, 4);
+ if (length == 0xffffffff)
+ {
+ /* For 64-bit DWARF, the 1-byte address_size field is 22 bytes
+ from the start of the section. This is computed as follows:
+
+ unit_length: 12 bytes
+ version: 2 bytes
+ debug_abbrev_offset: 8 bytes
+ -----------------------------
+ Total: 22 bytes */
+
+ debug_line_pointer_sizes [unit] = byte_get (begin + 22, 1);
+ length = byte_get (begin + 4, 8);
+ begin += length + 12;
+ }
+ else
+ {
+ /* For 32-bit DWARF, the 1-byte address_size field is 10 bytes from
+ the start of the section:
+
+ unit_length: 4 bytes
+ version: 2 bytes
+ debug_abbrev_offset: 4 bytes
+ -----------------------------
+ Total: 10 bytes */
+
+ debug_line_pointer_sizes [unit] = byte_get (begin + 10, 1);
+ begin += length + 4;
+ }
+ }
+
+ free (start);
+ num_debug_line_pointer_sizes = num_units;
+ return num_units;
+}
static int
-display_debug_lines (section, start, file)
- Elf32_Internal_Shdr * section;
- unsigned char * start;
- FILE * file ATTRIBUTE_UNUSED;
-{
- DWARF2_External_LineInfo * external;
- DWARF2_Internal_LineInfo info;
- unsigned char * standard_opcodes;
- unsigned char * data = start;
- unsigned char * end = start + section->sh_size;
- unsigned char * end_of_sequence;
- int i;
+display_debug_lines (Elf_Internal_Shdr *section,
+ unsigned char *start, FILE *file)
+{
+ unsigned char *hdrptr;
+ DWARF2_Internal_LineInfo info;
+ unsigned char *standard_opcodes;
+ unsigned char *data = start;
+ unsigned char *end = start + section->sh_size;
+ unsigned char *end_of_sequence;
+ int i;
+ int offset_size;
+ int initial_length_size;
+ unsigned int comp_unit = 0;
printf (_("\nDump of debug contents of section %s:\n\n"),
SECTION_NAME (section));
+ if (num_debug_line_pointer_sizes == 0)
+ get_debug_line_pointer_sizes (file);
+
while (data < end)
{
- external = (DWARF2_External_LineInfo *) data;
+ unsigned int pointer_size;
+
+ hdrptr = data;
/* Check the length of the block. */
- info.li_length = BYTE_GET (external->li_length);
+ info.li_length = byte_get (hdrptr, 4);
+ hdrptr += 4;
if (info.li_length == 0xffffffff)
{
- warn (_("64-bit DWARF line info is not supported yet.\n"));
- break;
+ /* This section is 64-bit DWARF 3. */
+ info.li_length = byte_get (hdrptr, 8);
+ hdrptr += 8;
+ offset_size = 8;
+ initial_length_size = 12;
+ }
+ else
+ {
+ offset_size = 4;
+ initial_length_size = 4;
}
- if (info.li_length + sizeof (external->li_length) > section->sh_size)
+ if (info.li_length + initial_length_size > section->sh_size)
{
warn
(_("The line info appears to be corrupt - the section is too small\n"));
@@ -6216,24 +6452,44 @@ display_debug_lines (section, start, file)
}
/* Check its version number. */
- info.li_version = BYTE_GET (external->li_version);
- if (info.li_version != 2)
+ info.li_version = byte_get (hdrptr, 2);
+ hdrptr += 2;
+ if (info.li_version != 2 && info.li_version != 3)
{
- warn (_("Only DWARF version 2 line info is currently supported.\n"));
+ warn (_("Only DWARF version 2 and 3 line info is currently supported.\n"));
return 0;
}
- info.li_prologue_length = BYTE_GET (external->li_prologue_length);
- info.li_min_insn_length = BYTE_GET (external->li_min_insn_length);
- info.li_default_is_stmt = BYTE_GET (external->li_default_is_stmt);
- info.li_line_base = BYTE_GET (external->li_line_base);
- info.li_line_range = BYTE_GET (external->li_line_range);
- info.li_opcode_base = BYTE_GET (external->li_opcode_base);
+ info.li_prologue_length = byte_get (hdrptr, offset_size);
+ hdrptr += offset_size;
+ info.li_min_insn_length = byte_get (hdrptr, 1);
+ hdrptr++;
+ info.li_default_is_stmt = byte_get (hdrptr, 1);
+ hdrptr++;
+ info.li_line_base = byte_get (hdrptr, 1);
+ hdrptr++;
+ info.li_line_range = byte_get (hdrptr, 1);
+ hdrptr++;
+ info.li_opcode_base = byte_get (hdrptr, 1);
+ hdrptr++;
/* Sign extend the line base field. */
info.li_line_base <<= 24;
info.li_line_base >>= 24;
+ /* Get the pointer size from the comp unit associated
+ with this block of line number information. */
+ if (comp_unit >= num_debug_line_pointer_sizes)
+ {
+ error (_("Not enough comp units for .debug_lines section\n"));
+ return 0;
+ }
+ else
+ {
+ pointer_size = debug_line_pointer_sizes [comp_unit];
+ comp_unit ++;
+ }
+
printf (_(" Length: %ld\n"), info.li_length);
printf (_(" DWARF Version: %d\n"), info.li_version);
printf (_(" Prologue Length: %d\n"), info.li_prologue_length);
@@ -6242,13 +6498,14 @@ display_debug_lines (section, start, file)
printf (_(" Line Base: %d\n"), info.li_line_base);
printf (_(" Line Range: %d\n"), info.li_line_range);
printf (_(" Opcode Base: %d\n"), info.li_opcode_base);
+ printf (_(" (Pointer size: %u)\n"), pointer_size);
- end_of_sequence = data + info.li_length + sizeof (external->li_length);
+ end_of_sequence = data + info.li_length + initial_length_size;
reset_state_machine (info.li_default_is_stmt);
/* Display the contents of the Opcodes table. */
- standard_opcodes = data + sizeof (* external);
+ standard_opcodes = hdrptr;
printf (_("\n Opcodes:\n"));
@@ -6258,13 +6515,13 @@ display_debug_lines (section, start, file)
/* Display the contents of the Directory table. */
data = standard_opcodes + info.li_opcode_base - 1;
- if (* data == 0)
+ if (*data == 0)
printf (_("\n The Directory Table is empty.\n"));
else
{
printf (_("\n The Directory Table:\n"));
- while (* data != 0)
+ while (*data != 0)
{
printf (_(" %s\n"), data);
@@ -6273,22 +6530,22 @@ display_debug_lines (section, start, file)
}
/* Skip the NUL at the end of the table. */
- data ++;
+ data++;
/* Display the contents of the File Name table. */
- if (* data == 0)
+ if (*data == 0)
printf (_("\n The File Name Table is empty.\n"));
else
{
printf (_("\n The File Name Table:\n"));
printf (_(" Entry\tDir\tTime\tSize\tName\n"));
- while (* data != 0)
+ while (*data != 0)
{
- unsigned char * name;
+ unsigned char *name;
int bytes_read;
- printf (_(" %d\t"), ++ state_machine_regs.last_file_entry);
+ printf (_(" %d\t"), ++state_machine_regs.last_file_entry);
name = data;
data += strlen ((char *) data) + 1;
@@ -6304,7 +6561,7 @@ display_debug_lines (section, start, file)
}
/* Skip the NUL at the end of the table. */
- data ++;
+ data++;
/* Now display the statements. */
printf (_("\n Line Number Statements:\n"));
@@ -6313,10 +6570,10 @@ display_debug_lines (section, start, file)
while (data < end_of_sequence)
{
unsigned char op_code;
- int adv;
- int bytes_read;
+ int adv;
+ int bytes_read;
- op_code = * data ++;
+ op_code = *data++;
if (op_code >= info.li_opcode_base)
{
@@ -6334,7 +6591,7 @@ display_debug_lines (section, start, file)
{
case DW_LNS_extended_op:
data += process_extended_line_op (data, info.li_default_is_stmt,
- debug_line_pointer_size);
+ pointer_size);
break;
case DW_LNS_copy:
@@ -6436,14 +6693,12 @@ display_debug_lines (section, start, file)
}
static int
-display_debug_pubnames (section, start, file)
- Elf32_Internal_Shdr * section;
- unsigned char * start;
- FILE * file ATTRIBUTE_UNUSED;
+display_debug_pubnames (Elf_Internal_Shdr *section,
+ unsigned char *start,
+ FILE *file ATTRIBUTE_UNUSED)
{
- DWARF2_External_PubNames * external;
- DWARF2_Internal_PubNames pubnames;
- unsigned char * end;
+ DWARF2_Internal_PubNames pubnames;
+ unsigned char *end;
end = start + section->sh_size;
@@ -6451,32 +6706,43 @@ display_debug_pubnames (section, start, file)
while (start < end)
{
- unsigned char * data;
- unsigned long offset;
-
- external = (DWARF2_External_PubNames *) start;
-
- pubnames.pn_length = BYTE_GET (external->pn_length);
- pubnames.pn_version = BYTE_GET (external->pn_version);
- pubnames.pn_offset = BYTE_GET (external->pn_offset);
- pubnames.pn_size = BYTE_GET (external->pn_size);
+ unsigned char *data;
+ unsigned long offset;
+ int offset_size, initial_length_size;
- data = start + sizeof (* external);
- start += pubnames.pn_length + sizeof (external->pn_length);
+ data = start;
+ pubnames.pn_length = byte_get (data, 4);
+ data += 4;
if (pubnames.pn_length == 0xffffffff)
{
- warn (_("64-bit DWARF pubnames are not supported yet.\n"));
- break;
+ pubnames.pn_length = byte_get (data, 8);
+ data += 8;
+ offset_size = 8;
+ initial_length_size = 12;
}
+ else
+ {
+ offset_size = 4;
+ initial_length_size = 4;
+ }
+
+ pubnames.pn_version = byte_get (data, 2);
+ data += 2;
+ pubnames.pn_offset = byte_get (data, offset_size);
+ data += offset_size;
+ pubnames.pn_size = byte_get (data, offset_size);
+ data += offset_size;
- if (pubnames.pn_version != 2)
+ start += pubnames.pn_length + initial_length_size;
+
+ if (pubnames.pn_version != 2 && pubnames.pn_version != 3)
{
static int warned = 0;
if (! warned)
{
- warn (_("Only DWARF 2 pubnames are currently supported\n"));
+ warn (_("Only DWARF 2 and 3 pubnames are currently supported\n"));
warned = 1;
}
@@ -6496,12 +6762,12 @@ display_debug_pubnames (section, start, file)
do
{
- offset = byte_get (data, 4);
+ offset = byte_get (data, offset_size);
if (offset != 0)
{
- data += 4;
- printf (" %ld\t\t%s\n", offset, data);
+ data += offset_size;
+ printf (" %-6ld\t\t%s\n", offset, data);
data += strlen ((char *) data) + 1;
}
}
@@ -6513,75 +6779,78 @@ display_debug_pubnames (section, start, file)
}
static char *
-get_TAG_name (tag)
- unsigned long tag;
+get_TAG_name (unsigned long tag)
{
switch (tag)
{
- case DW_TAG_padding: return "DW_TAG_padding";
- case DW_TAG_array_type: return "DW_TAG_array_type";
- case DW_TAG_class_type: return "DW_TAG_class_type";
- case DW_TAG_entry_point: return "DW_TAG_entry_point";
- case DW_TAG_enumeration_type: return "DW_TAG_enumeration_type";
- case DW_TAG_formal_parameter: return "DW_TAG_formal_parameter";
- case DW_TAG_imported_declaration: return "DW_TAG_imported_declaration";
- case DW_TAG_label: return "DW_TAG_label";
- case DW_TAG_lexical_block: return "DW_TAG_lexical_block";
- case DW_TAG_member: return "DW_TAG_member";
- case DW_TAG_pointer_type: return "DW_TAG_pointer_type";
- case DW_TAG_reference_type: return "DW_TAG_reference_type";
- case DW_TAG_compile_unit: return "DW_TAG_compile_unit";
- case DW_TAG_string_type: return "DW_TAG_string_type";
- case DW_TAG_structure_type: return "DW_TAG_structure_type";
- case DW_TAG_subroutine_type: return "DW_TAG_subroutine_type";
- case DW_TAG_typedef: return "DW_TAG_typedef";
- case DW_TAG_union_type: return "DW_TAG_union_type";
+ case DW_TAG_padding: return "DW_TAG_padding";
+ case DW_TAG_array_type: return "DW_TAG_array_type";
+ case DW_TAG_class_type: return "DW_TAG_class_type";
+ case DW_TAG_entry_point: return "DW_TAG_entry_point";
+ case DW_TAG_enumeration_type: return "DW_TAG_enumeration_type";
+ case DW_TAG_formal_parameter: return "DW_TAG_formal_parameter";
+ case DW_TAG_imported_declaration: return "DW_TAG_imported_declaration";
+ case DW_TAG_label: return "DW_TAG_label";
+ case DW_TAG_lexical_block: return "DW_TAG_lexical_block";
+ case DW_TAG_member: return "DW_TAG_member";
+ case DW_TAG_pointer_type: return "DW_TAG_pointer_type";
+ case DW_TAG_reference_type: return "DW_TAG_reference_type";
+ case DW_TAG_compile_unit: return "DW_TAG_compile_unit";
+ case DW_TAG_string_type: return "DW_TAG_string_type";
+ case DW_TAG_structure_type: return "DW_TAG_structure_type";
+ case DW_TAG_subroutine_type: return "DW_TAG_subroutine_type";
+ case DW_TAG_typedef: return "DW_TAG_typedef";
+ case DW_TAG_union_type: return "DW_TAG_union_type";
case DW_TAG_unspecified_parameters: return "DW_TAG_unspecified_parameters";
- case DW_TAG_variant: return "DW_TAG_variant";
- case DW_TAG_common_block: return "DW_TAG_common_block";
- case DW_TAG_common_inclusion: return "DW_TAG_common_inclusion";
- case DW_TAG_inheritance: return "DW_TAG_inheritance";
- case DW_TAG_inlined_subroutine: return "DW_TAG_inlined_subroutine";
- case DW_TAG_module: return "DW_TAG_module";
- case DW_TAG_ptr_to_member_type: return "DW_TAG_ptr_to_member_type";
- case DW_TAG_set_type: return "DW_TAG_set_type";
- case DW_TAG_subrange_type: return "DW_TAG_subrange_type";
- case DW_TAG_with_stmt: return "DW_TAG_with_stmt";
- case DW_TAG_access_declaration: return "DW_TAG_access_declaration";
- case DW_TAG_base_type: return "DW_TAG_base_type";
- case DW_TAG_catch_block: return "DW_TAG_catch_block";
- case DW_TAG_const_type: return "DW_TAG_const_type";
- case DW_TAG_constant: return "DW_TAG_constant";
- case DW_TAG_enumerator: return "DW_TAG_enumerator";
- case DW_TAG_file_type: return "DW_TAG_file_type";
- case DW_TAG_friend: return "DW_TAG_friend";
- case DW_TAG_namelist: return "DW_TAG_namelist";
- case DW_TAG_namelist_item: return "DW_TAG_namelist_item";
- case DW_TAG_packed_type: return "DW_TAG_packed_type";
- case DW_TAG_subprogram: return "DW_TAG_subprogram";
- case DW_TAG_template_type_param: return "DW_TAG_template_type_param";
- case DW_TAG_template_value_param: return "DW_TAG_template_value_param";
- case DW_TAG_thrown_type: return "DW_TAG_thrown_type";
- case DW_TAG_try_block: return "DW_TAG_try_block";
- case DW_TAG_variant_part: return "DW_TAG_variant_part";
- case DW_TAG_variable: return "DW_TAG_variable";
- case DW_TAG_volatile_type: return "DW_TAG_volatile_type";
- case DW_TAG_MIPS_loop: return "DW_TAG_MIPS_loop";
- case DW_TAG_format_label: return "DW_TAG_format_label";
- case DW_TAG_function_template: return "DW_TAG_function_template";
- case DW_TAG_class_template: return "DW_TAG_class_template";
+ case DW_TAG_variant: return "DW_TAG_variant";
+ case DW_TAG_common_block: return "DW_TAG_common_block";
+ case DW_TAG_common_inclusion: return "DW_TAG_common_inclusion";
+ case DW_TAG_inheritance: return "DW_TAG_inheritance";
+ case DW_TAG_inlined_subroutine: return "DW_TAG_inlined_subroutine";
+ case DW_TAG_module: return "DW_TAG_module";
+ case DW_TAG_ptr_to_member_type: return "DW_TAG_ptr_to_member_type";
+ case DW_TAG_set_type: return "DW_TAG_set_type";
+ case DW_TAG_subrange_type: return "DW_TAG_subrange_type";
+ case DW_TAG_with_stmt: return "DW_TAG_with_stmt";
+ case DW_TAG_access_declaration: return "DW_TAG_access_declaration";
+ case DW_TAG_base_type: return "DW_TAG_base_type";
+ case DW_TAG_catch_block: return "DW_TAG_catch_block";
+ case DW_TAG_const_type: return "DW_TAG_const_type";
+ case DW_TAG_constant: return "DW_TAG_constant";
+ case DW_TAG_enumerator: return "DW_TAG_enumerator";
+ case DW_TAG_file_type: return "DW_TAG_file_type";
+ case DW_TAG_friend: return "DW_TAG_friend";
+ case DW_TAG_namelist: return "DW_TAG_namelist";
+ case DW_TAG_namelist_item: return "DW_TAG_namelist_item";
+ case DW_TAG_packed_type: return "DW_TAG_packed_type";
+ case DW_TAG_subprogram: return "DW_TAG_subprogram";
+ case DW_TAG_template_type_param: return "DW_TAG_template_type_param";
+ case DW_TAG_template_value_param: return "DW_TAG_template_value_param";
+ case DW_TAG_thrown_type: return "DW_TAG_thrown_type";
+ case DW_TAG_try_block: return "DW_TAG_try_block";
+ case DW_TAG_variant_part: return "DW_TAG_variant_part";
+ case DW_TAG_variable: return "DW_TAG_variable";
+ case DW_TAG_volatile_type: return "DW_TAG_volatile_type";
+ case DW_TAG_MIPS_loop: return "DW_TAG_MIPS_loop";
+ case DW_TAG_format_label: return "DW_TAG_format_label";
+ case DW_TAG_function_template: return "DW_TAG_function_template";
+ case DW_TAG_class_template: return "DW_TAG_class_template";
/* DWARF 2.1 values. */
- case DW_TAG_dwarf_procedure: return "DW_TAG_dwarf_procedure";
- case DW_TAG_restrict_type: return "DW_TAG_restrict_type";
- case DW_TAG_interface_type: return "DW_TAG_interface_type";
- case DW_TAG_namespace: return "DW_TAG_namespace";
- case DW_TAG_imported_module: return "DW_TAG_imported_module";
- case DW_TAG_unspecified_type: return "DW_TAG_unspecified_type";
- case DW_TAG_partial_unit: return "DW_TAG_partial_unit";
- case DW_TAG_imported_unit: return "DW_TAG_imported_unit";
+ case DW_TAG_dwarf_procedure: return "DW_TAG_dwarf_procedure";
+ case DW_TAG_restrict_type: return "DW_TAG_restrict_type";
+ case DW_TAG_interface_type: return "DW_TAG_interface_type";
+ case DW_TAG_namespace: return "DW_TAG_namespace";
+ case DW_TAG_imported_module: return "DW_TAG_imported_module";
+ case DW_TAG_unspecified_type: return "DW_TAG_unspecified_type";
+ case DW_TAG_partial_unit: return "DW_TAG_partial_unit";
+ case DW_TAG_imported_unit: return "DW_TAG_imported_unit";
+ /* UPC values. */
+ case DW_TAG_upc_shared_type: return "DW_TAG_upc_shared_type";
+ case DW_TAG_upc_strict_type: return "DW_TAG_upc_strict_type";
+ case DW_TAG_upc_relaxed_type: return "DW_TAG_upc_relaxed_type";
default:
{
- static char buffer [100];
+ static char buffer[100];
sprintf (buffer, _("Unknown TAG value: %lx"), tag);
return buffer;
@@ -6590,109 +6859,111 @@ get_TAG_name (tag)
}
static char *
-get_AT_name (attribute)
- unsigned long attribute;
+get_AT_name (unsigned long attribute)
{
switch (attribute)
{
- case DW_AT_sibling: return "DW_AT_sibling";
- case DW_AT_location: return "DW_AT_location";
- case DW_AT_name: return "DW_AT_name";
- case DW_AT_ordering: return "DW_AT_ordering";
- case DW_AT_subscr_data: return "DW_AT_subscr_data";
- case DW_AT_byte_size: return "DW_AT_byte_size";
- case DW_AT_bit_offset: return "DW_AT_bit_offset";
- case DW_AT_bit_size: return "DW_AT_bit_size";
- case DW_AT_element_list: return "DW_AT_element_list";
- case DW_AT_stmt_list: return "DW_AT_stmt_list";
- case DW_AT_low_pc: return "DW_AT_low_pc";
- case DW_AT_high_pc: return "DW_AT_high_pc";
- case DW_AT_language: return "DW_AT_language";
- case DW_AT_member: return "DW_AT_member";
- case DW_AT_discr: return "DW_AT_discr";
- case DW_AT_discr_value: return "DW_AT_discr_value";
- case DW_AT_visibility: return "DW_AT_visibility";
- case DW_AT_import: return "DW_AT_import";
- case DW_AT_string_length: return "DW_AT_string_length";
- case DW_AT_common_reference: return "DW_AT_common_reference";
- case DW_AT_comp_dir: return "DW_AT_comp_dir";
- case DW_AT_const_value: return "DW_AT_const_value";
- case DW_AT_containing_type: return "DW_AT_containing_type";
- case DW_AT_default_value: return "DW_AT_default_value";
- case DW_AT_inline: return "DW_AT_inline";
- case DW_AT_is_optional: return "DW_AT_is_optional";
- case DW_AT_lower_bound: return "DW_AT_lower_bound";
- case DW_AT_producer: return "DW_AT_producer";
- case DW_AT_prototyped: return "DW_AT_prototyped";
- case DW_AT_return_addr: return "DW_AT_return_addr";
- case DW_AT_start_scope: return "DW_AT_start_scope";
- case DW_AT_stride_size: return "DW_AT_stride_size";
- case DW_AT_upper_bound: return "DW_AT_upper_bound";
- case DW_AT_abstract_origin: return "DW_AT_abstract_origin";
- case DW_AT_accessibility: return "DW_AT_accessibility";
- case DW_AT_address_class: return "DW_AT_address_class";
- case DW_AT_artificial: return "DW_AT_artificial";
- case DW_AT_base_types: return "DW_AT_base_types";
- case DW_AT_calling_convention: return "DW_AT_calling_convention";
- case DW_AT_count: return "DW_AT_count";
- case DW_AT_data_member_location: return "DW_AT_data_member_location";
- case DW_AT_decl_column: return "DW_AT_decl_column";
- case DW_AT_decl_file: return "DW_AT_decl_file";
- case DW_AT_decl_line: return "DW_AT_decl_line";
- case DW_AT_declaration: return "DW_AT_declaration";
- case DW_AT_discr_list: return "DW_AT_discr_list";
- case DW_AT_encoding: return "DW_AT_encoding";
- case DW_AT_external: return "DW_AT_external";
- case DW_AT_frame_base: return "DW_AT_frame_base";
- case DW_AT_friend: return "DW_AT_friend";
- case DW_AT_identifier_case: return "DW_AT_identifier_case";
- case DW_AT_macro_info: return "DW_AT_macro_info";
- case DW_AT_namelist_items: return "DW_AT_namelist_items";
- case DW_AT_priority: return "DW_AT_priority";
- case DW_AT_segment: return "DW_AT_segment";
- case DW_AT_specification: return "DW_AT_specification";
- case DW_AT_static_link: return "DW_AT_static_link";
- case DW_AT_type: return "DW_AT_type";
- case DW_AT_use_location: return "DW_AT_use_location";
- case DW_AT_variable_parameter: return "DW_AT_variable_parameter";
- case DW_AT_virtuality: return "DW_AT_virtuality";
- case DW_AT_vtable_elem_location: return "DW_AT_vtable_elem_location";
+ case DW_AT_sibling: return "DW_AT_sibling";
+ case DW_AT_location: return "DW_AT_location";
+ case DW_AT_name: return "DW_AT_name";
+ case DW_AT_ordering: return "DW_AT_ordering";
+ case DW_AT_subscr_data: return "DW_AT_subscr_data";
+ case DW_AT_byte_size: return "DW_AT_byte_size";
+ case DW_AT_bit_offset: return "DW_AT_bit_offset";
+ case DW_AT_bit_size: return "DW_AT_bit_size";
+ case DW_AT_element_list: return "DW_AT_element_list";
+ case DW_AT_stmt_list: return "DW_AT_stmt_list";
+ case DW_AT_low_pc: return "DW_AT_low_pc";
+ case DW_AT_high_pc: return "DW_AT_high_pc";
+ case DW_AT_language: return "DW_AT_language";
+ case DW_AT_member: return "DW_AT_member";
+ case DW_AT_discr: return "DW_AT_discr";
+ case DW_AT_discr_value: return "DW_AT_discr_value";
+ case DW_AT_visibility: return "DW_AT_visibility";
+ case DW_AT_import: return "DW_AT_import";
+ case DW_AT_string_length: return "DW_AT_string_length";
+ case DW_AT_common_reference: return "DW_AT_common_reference";
+ case DW_AT_comp_dir: return "DW_AT_comp_dir";
+ case DW_AT_const_value: return "DW_AT_const_value";
+ case DW_AT_containing_type: return "DW_AT_containing_type";
+ case DW_AT_default_value: return "DW_AT_default_value";
+ case DW_AT_inline: return "DW_AT_inline";
+ case DW_AT_is_optional: return "DW_AT_is_optional";
+ case DW_AT_lower_bound: return "DW_AT_lower_bound";
+ case DW_AT_producer: return "DW_AT_producer";
+ case DW_AT_prototyped: return "DW_AT_prototyped";
+ case DW_AT_return_addr: return "DW_AT_return_addr";
+ case DW_AT_start_scope: return "DW_AT_start_scope";
+ case DW_AT_stride_size: return "DW_AT_stride_size";
+ case DW_AT_upper_bound: return "DW_AT_upper_bound";
+ case DW_AT_abstract_origin: return "DW_AT_abstract_origin";
+ case DW_AT_accessibility: return "DW_AT_accessibility";
+ case DW_AT_address_class: return "DW_AT_address_class";
+ case DW_AT_artificial: return "DW_AT_artificial";
+ case DW_AT_base_types: return "DW_AT_base_types";
+ case DW_AT_calling_convention: return "DW_AT_calling_convention";
+ case DW_AT_count: return "DW_AT_count";
+ case DW_AT_data_member_location: return "DW_AT_data_member_location";
+ case DW_AT_decl_column: return "DW_AT_decl_column";
+ case DW_AT_decl_file: return "DW_AT_decl_file";
+ case DW_AT_decl_line: return "DW_AT_decl_line";
+ case DW_AT_declaration: return "DW_AT_declaration";
+ case DW_AT_discr_list: return "DW_AT_discr_list";
+ case DW_AT_encoding: return "DW_AT_encoding";
+ case DW_AT_external: return "DW_AT_external";
+ case DW_AT_frame_base: return "DW_AT_frame_base";
+ case DW_AT_friend: return "DW_AT_friend";
+ case DW_AT_identifier_case: return "DW_AT_identifier_case";
+ case DW_AT_macro_info: return "DW_AT_macro_info";
+ case DW_AT_namelist_items: return "DW_AT_namelist_items";
+ case DW_AT_priority: return "DW_AT_priority";
+ case DW_AT_segment: return "DW_AT_segment";
+ case DW_AT_specification: return "DW_AT_specification";
+ case DW_AT_static_link: return "DW_AT_static_link";
+ case DW_AT_type: return "DW_AT_type";
+ case DW_AT_use_location: return "DW_AT_use_location";
+ case DW_AT_variable_parameter: return "DW_AT_variable_parameter";
+ case DW_AT_virtuality: return "DW_AT_virtuality";
+ case DW_AT_vtable_elem_location: return "DW_AT_vtable_elem_location";
/* DWARF 2.1 values. */
- case DW_AT_allocated: return "DW_AT_allocated";
- case DW_AT_associated: return "DW_AT_associated";
- case DW_AT_data_location: return "DW_AT_data_location";
- case DW_AT_stride: return "DW_AT_stride";
- case DW_AT_entry_pc: return "DW_AT_entry_pc";
- case DW_AT_use_UTF8: return "DW_AT_use_UTF8";
- case DW_AT_extension: return "DW_AT_extension";
- case DW_AT_ranges: return "DW_AT_ranges";
- case DW_AT_trampoline: return "DW_AT_trampoline";
- case DW_AT_call_column: return "DW_AT_call_column";
- case DW_AT_call_file: return "DW_AT_call_file";
- case DW_AT_call_line: return "DW_AT_call_line";
+ case DW_AT_allocated: return "DW_AT_allocated";
+ case DW_AT_associated: return "DW_AT_associated";
+ case DW_AT_data_location: return "DW_AT_data_location";
+ case DW_AT_stride: return "DW_AT_stride";
+ case DW_AT_entry_pc: return "DW_AT_entry_pc";
+ case DW_AT_use_UTF8: return "DW_AT_use_UTF8";
+ case DW_AT_extension: return "DW_AT_extension";
+ case DW_AT_ranges: return "DW_AT_ranges";
+ case DW_AT_trampoline: return "DW_AT_trampoline";
+ case DW_AT_call_column: return "DW_AT_call_column";
+ case DW_AT_call_file: return "DW_AT_call_file";
+ case DW_AT_call_line: return "DW_AT_call_line";
/* SGI/MIPS extensions. */
- case DW_AT_MIPS_fde: return "DW_AT_MIPS_fde";
- case DW_AT_MIPS_loop_begin: return "DW_AT_MIPS_loop_begin";
- case DW_AT_MIPS_tail_loop_begin: return "DW_AT_MIPS_tail_loop_begin";
- case DW_AT_MIPS_epilog_begin: return "DW_AT_MIPS_epilog_begin";
+ case DW_AT_MIPS_fde: return "DW_AT_MIPS_fde";
+ case DW_AT_MIPS_loop_begin: return "DW_AT_MIPS_loop_begin";
+ case DW_AT_MIPS_tail_loop_begin: return "DW_AT_MIPS_tail_loop_begin";
+ case DW_AT_MIPS_epilog_begin: return "DW_AT_MIPS_epilog_begin";
case DW_AT_MIPS_loop_unroll_factor: return "DW_AT_MIPS_loop_unroll_factor";
- case DW_AT_MIPS_software_pipeline_depth: return "DW_AT_MIPS_software_pipeline_depth";
- case DW_AT_MIPS_linkage_name: return "DW_AT_MIPS_linkage_name";
- case DW_AT_MIPS_stride: return "DW_AT_MIPS_stride";
- case DW_AT_MIPS_abstract_name: return "DW_AT_MIPS_abstract_name";
- case DW_AT_MIPS_clone_origin: return "DW_AT_MIPS_clone_origin";
- case DW_AT_MIPS_has_inlines: return "DW_AT_MIPS_has_inlines";
+ case DW_AT_MIPS_software_pipeline_depth:
+ return "DW_AT_MIPS_software_pipeline_depth";
+ case DW_AT_MIPS_linkage_name: return "DW_AT_MIPS_linkage_name";
+ case DW_AT_MIPS_stride: return "DW_AT_MIPS_stride";
+ case DW_AT_MIPS_abstract_name: return "DW_AT_MIPS_abstract_name";
+ case DW_AT_MIPS_clone_origin: return "DW_AT_MIPS_clone_origin";
+ case DW_AT_MIPS_has_inlines: return "DW_AT_MIPS_has_inlines";
/* GNU extensions. */
- case DW_AT_sf_names: return "DW_AT_sf_names";
- case DW_AT_src_info: return "DW_AT_src_info";
- case DW_AT_mac_info: return "DW_AT_mac_info";
- case DW_AT_src_coords: return "DW_AT_src_coords";
- case DW_AT_body_begin: return "DW_AT_body_begin";
- case DW_AT_body_end: return "DW_AT_body_end";
- case DW_AT_GNU_vector: return "DW_AT_GNU_vector";
+ case DW_AT_sf_names: return "DW_AT_sf_names";
+ case DW_AT_src_info: return "DW_AT_src_info";
+ case DW_AT_mac_info: return "DW_AT_mac_info";
+ case DW_AT_src_coords: return "DW_AT_src_coords";
+ case DW_AT_body_begin: return "DW_AT_body_begin";
+ case DW_AT_body_end: return "DW_AT_body_end";
+ case DW_AT_GNU_vector: return "DW_AT_GNU_vector";
+ /* UPC extension. */
+ case DW_AT_upc_threads_scaled: return "DW_AT_upc_threads_scaled";
default:
{
- static char buffer [100];
+ static char buffer[100];
sprintf (buffer, _("Unknown AT value: %lx"), attribute);
return buffer;
@@ -6701,35 +6972,34 @@ get_AT_name (attribute)
}
static char *
-get_FORM_name (form)
- unsigned long form;
+get_FORM_name (unsigned long form)
{
switch (form)
{
- case DW_FORM_addr: return "DW_FORM_addr";
- case DW_FORM_block2: return "DW_FORM_block2";
- case DW_FORM_block4: return "DW_FORM_block4";
- case DW_FORM_data2: return "DW_FORM_data2";
- case DW_FORM_data4: return "DW_FORM_data4";
- case DW_FORM_data8: return "DW_FORM_data8";
- case DW_FORM_string: return "DW_FORM_string";
- case DW_FORM_block: return "DW_FORM_block";
- case DW_FORM_block1: return "DW_FORM_block1";
- case DW_FORM_data1: return "DW_FORM_data1";
- case DW_FORM_flag: return "DW_FORM_flag";
- case DW_FORM_sdata: return "DW_FORM_sdata";
- case DW_FORM_strp: return "DW_FORM_strp";
- case DW_FORM_udata: return "DW_FORM_udata";
- case DW_FORM_ref_addr: return "DW_FORM_ref_addr";
- case DW_FORM_ref1: return "DW_FORM_ref1";
- case DW_FORM_ref2: return "DW_FORM_ref2";
- case DW_FORM_ref4: return "DW_FORM_ref4";
- case DW_FORM_ref8: return "DW_FORM_ref8";
- case DW_FORM_ref_udata: return "DW_FORM_ref_udata";
- case DW_FORM_indirect: return "DW_FORM_indirect";
+ case DW_FORM_addr: return "DW_FORM_addr";
+ case DW_FORM_block2: return "DW_FORM_block2";
+ case DW_FORM_block4: return "DW_FORM_block4";
+ case DW_FORM_data2: return "DW_FORM_data2";
+ case DW_FORM_data4: return "DW_FORM_data4";
+ case DW_FORM_data8: return "DW_FORM_data8";
+ case DW_FORM_string: return "DW_FORM_string";
+ case DW_FORM_block: return "DW_FORM_block";
+ case DW_FORM_block1: return "DW_FORM_block1";
+ case DW_FORM_data1: return "DW_FORM_data1";
+ case DW_FORM_flag: return "DW_FORM_flag";
+ case DW_FORM_sdata: return "DW_FORM_sdata";
+ case DW_FORM_strp: return "DW_FORM_strp";
+ case DW_FORM_udata: return "DW_FORM_udata";
+ case DW_FORM_ref_addr: return "DW_FORM_ref_addr";
+ case DW_FORM_ref1: return "DW_FORM_ref1";
+ case DW_FORM_ref2: return "DW_FORM_ref2";
+ case DW_FORM_ref4: return "DW_FORM_ref4";
+ case DW_FORM_ref8: return "DW_FORM_ref8";
+ case DW_FORM_ref_udata: return "DW_FORM_ref_udata";
+ case DW_FORM_indirect: return "DW_FORM_indirect";
default:
{
- static char buffer [100];
+ static char buffer[100];
sprintf (buffer, _("Unknown FORM value: %lx"), form);
return buffer;
@@ -6737,44 +7007,44 @@ get_FORM_name (form)
}
}
-/* FIXME: There are better and more effiecint ways to handle
+/* FIXME: There are better and more efficient ways to handle
these structures. For now though, I just want something that
is simple to implement. */
typedef struct abbrev_attr
{
- unsigned long attribute;
- unsigned long form;
- struct abbrev_attr * next;
+ unsigned long attribute;
+ unsigned long form;
+ struct abbrev_attr *next;
}
abbrev_attr;
typedef struct abbrev_entry
{
- unsigned long entry;
- unsigned long tag;
- int children;
- struct abbrev_attr * first_attr;
- struct abbrev_attr * last_attr;
- struct abbrev_entry * next;
+ unsigned long entry;
+ unsigned long tag;
+ int children;
+ struct abbrev_attr *first_attr;
+ struct abbrev_attr *last_attr;
+ struct abbrev_entry *next;
}
abbrev_entry;
-static abbrev_entry * first_abbrev = NULL;
-static abbrev_entry * last_abbrev = NULL;
+static abbrev_entry *first_abbrev = NULL;
+static abbrev_entry *last_abbrev = NULL;
static void
-free_abbrevs PARAMS ((void))
+free_abbrevs (void)
{
- abbrev_entry * abbrev;
+ abbrev_entry *abbrev;
for (abbrev = first_abbrev; abbrev;)
{
- abbrev_entry * next = abbrev->next;
- abbrev_attr * attr;
+ abbrev_entry *next = abbrev->next;
+ abbrev_attr *attr;
for (attr = abbrev->first_attr; attr;)
{
- abbrev_attr * next = attr->next;
+ abbrev_attr *next = attr->next;
free (attr);
attr = next;
@@ -6788,14 +7058,11 @@ free_abbrevs PARAMS ((void))
}
static void
-add_abbrev (number, tag, children)
- unsigned long number;
- unsigned long tag;
- int children;
+add_abbrev (unsigned long number, unsigned long tag, int children)
{
- abbrev_entry * entry;
+ abbrev_entry *entry;
- entry = (abbrev_entry *) malloc (sizeof (* entry));
+ entry = malloc (sizeof (*entry));
if (entry == NULL)
/* ugg */
@@ -6817,13 +7084,11 @@ add_abbrev (number, tag, children)
}
static void
-add_abbrev_attr (attribute, form)
- unsigned long attribute;
- unsigned long form;
+add_abbrev_attr (unsigned long attribute, unsigned long form)
{
- abbrev_attr * attr;
+ abbrev_attr *attr;
- attr = (abbrev_attr *) malloc (sizeof (* attr));
+ attr = malloc (sizeof (*attr));
if (attr == NULL)
/* ugg */
@@ -6847,20 +7112,18 @@ add_abbrev_attr (attribute, form)
an abbreviation set was found. */
static unsigned char *
-process_abbrev_section (start, end)
- unsigned char * start;
- unsigned char * end;
+process_abbrev_section (unsigned char *start, unsigned char *end)
{
if (first_abbrev != NULL)
return NULL;
while (start < end)
{
- int bytes_read;
+ int bytes_read;
unsigned long entry;
unsigned long tag;
unsigned long attribute;
- int children;
+ int children;
entry = read_leb128 (start, & bytes_read, 0);
start += bytes_read;
@@ -6874,7 +7137,7 @@ process_abbrev_section (start, end)
tag = read_leb128 (start, & bytes_read, 0);
start += bytes_read;
- children = * start ++;
+ children = *start++;
add_abbrev (entry, tag, children);
@@ -6899,13 +7162,12 @@ process_abbrev_section (start, end)
static int
-display_debug_macinfo (section, start, file)
- Elf32_Internal_Shdr * section;
- unsigned char * start;
- FILE * file ATTRIBUTE_UNUSED;
+display_debug_macinfo (Elf_Internal_Shdr *section,
+ unsigned char *start,
+ FILE *file ATTRIBUTE_UNUSED)
{
- unsigned char * end = start + section->sh_size;
- unsigned char * curr = start;
+ unsigned char *end = start + section->sh_size;
+ unsigned char *curr = start;
unsigned int bytes_read;
enum dwarf_macinfo_record_type op;
@@ -6914,10 +7176,10 @@ display_debug_macinfo (section, start, file)
while (curr < end)
{
unsigned int lineno;
- const char * string;
+ const char *string;
- op = * curr;
- curr ++;
+ op = *curr;
+ curr++;
switch (op)
{
@@ -6973,13 +7235,12 @@ display_debug_macinfo (section, start, file)
static int
-display_debug_abbrev (section, start, file)
- Elf32_Internal_Shdr * section;
- unsigned char * start;
- FILE * file ATTRIBUTE_UNUSED;
+display_debug_abbrev (Elf_Internal_Shdr *section,
+ unsigned char *start,
+ FILE *file ATTRIBUTE_UNUSED)
{
- abbrev_entry * entry;
- unsigned char * end = start + section->sh_size;
+ abbrev_entry *entry;
+ unsigned char *end = start + section->sh_size;
printf (_("Contents of the %s section:\n\n"), SECTION_NAME (section));
@@ -6994,7 +7255,7 @@ display_debug_abbrev (section, start, file)
for (entry = first_abbrev; entry; entry = entry->next)
{
- abbrev_attr * attr;
+ abbrev_attr *attr;
printf (_(" %ld %s [%s]\n"),
entry->entry,
@@ -7020,32 +7281,29 @@ display_debug_abbrev (section, start, file)
static unsigned char *
-display_block (data, length)
- unsigned char * data;
- unsigned long length;
+display_block (unsigned char *data, unsigned long length)
{
printf (_(" %lu byte block: "), length);
while (length --)
- printf ("%lx ", (unsigned long) byte_get (data ++, 1));
+ printf ("%lx ", (unsigned long) byte_get (data++, 1));
return data;
}
static void
-decode_location_expression (data, pointer_size, length)
- unsigned char * data;
- unsigned int pointer_size;
- unsigned long length;
+decode_location_expression (unsigned char * data,
+ unsigned int pointer_size,
+ unsigned long length)
{
- unsigned op;
- int bytes_read;
- unsigned long uvalue;
- unsigned char * end = data + length;
+ unsigned op;
+ int bytes_read;
+ unsigned long uvalue;
+ unsigned char *end = data + length;
while (data < end)
{
- op = * data ++;
+ op = *data++;
switch (op)
{
@@ -7328,7 +7586,7 @@ decode_location_expression (data, pointer_size, length)
printf ("DW_OP_nop");
break;
- /* DWARF 2.1 extensions. */
+ /* DWARF 3 extensions. */
case DW_OP_push_object_address:
printf ("DW_OP_push_object_address");
break;
@@ -7340,8 +7598,13 @@ decode_location_expression (data, pointer_size, length)
printf ("DW_OP_call4: <%lx>", (long) byte_get (data, 4));
data += 4;
break;
- case DW_OP_calli:
- printf ("DW_OP_calli");
+ case DW_OP_call_ref:
+ printf ("DW_OP_call_ref");
+ break;
+
+ /* GNU extensions. */
+ case DW_OP_GNU_push_tls_address:
+ printf ("DW_OP_GNU_push_tls_address");
break;
default:
@@ -7355,43 +7618,36 @@ decode_location_expression (data, pointer_size, length)
}
/* Separate the ops. */
- printf ("; ");
+ if (data < end)
+ printf ("; ");
}
}
-static const char * debug_loc_contents;
-static bfd_vma debug_loc_size;
+static const char *debug_loc_contents;
+static bfd_vma debug_loc_size;
static void
-load_debug_loc (file)
- FILE * file;
+load_debug_loc (FILE *file)
{
- Elf32_Internal_Shdr * sec;
- unsigned int i;
+ Elf_Internal_Shdr *sec;
/* If it is already loaded, do nothing. */
if (debug_loc_contents != NULL)
return;
/* Locate the .debug_loc section. */
- for (i = 0, sec = section_headers;
- i < elf_header.e_shnum;
- i ++, sec ++)
- if (strcmp (SECTION_NAME (sec), ".debug_loc") == 0)
- break;
-
- if (i == elf_header.e_shnum || sec->sh_size == 0)
+ sec = find_section (".debug_loc");
+ if (sec == NULL)
return;
debug_loc_size = sec->sh_size;
- debug_loc_contents = ((char *)
- get_data (NULL, file, sec->sh_offset, sec->sh_size,
- _("debug_loc section data")));
+ debug_loc_contents = get_data (NULL, file, sec->sh_offset, sec->sh_size,
+ _("debug_loc section data"));
}
static void
-free_debug_loc ()
+free_debug_loc (void)
{
if (debug_loc_contents == NULL)
return;
@@ -7403,52 +7659,68 @@ free_debug_loc ()
static int
-display_debug_loc (section, start, file)
- Elf32_Internal_Shdr * section;
- unsigned char * start;
- FILE * file ATTRIBUTE_UNUSED;
+display_debug_loc (Elf_Internal_Shdr *section,
+ unsigned char *start, FILE *file)
{
unsigned char *section_end;
unsigned long bytes;
unsigned char *section_begin = start;
bfd_vma addr;
+ unsigned int comp_unit = 0;
addr = section->sh_addr;
bytes = section->sh_size;
section_end = start + bytes;
+
if (bytes == 0)
{
printf (_("\nThe .debug_loc section is empty.\n"));
return 0;
}
+
+ if (num_debug_line_pointer_sizes == 0)
+ get_debug_line_pointer_sizes (file);
+
printf (_("Contents of the .debug_loc section:\n\n"));
printf (_("\n Offset Begin End Expression\n"));
+
while (start < section_end)
{
unsigned long begin;
unsigned long end;
unsigned short length;
unsigned long offset;
+ unsigned int pointer_size;
offset = start - section_begin;
+ /* Get the pointer size from the comp unit associated
+ with this block of location information. */
+ if (comp_unit >= num_debug_line_pointer_sizes)
+ {
+ error (_("Not enough comp units for .debug_loc section\n"));
+ return 0;
+ }
+ else
+ {
+ pointer_size = debug_line_pointer_sizes [comp_unit];
+ comp_unit ++;
+ }
+
while (1)
{
- /* Normally, the lists in the debug_loc section are related to a
- given compilation unit, and thus, we would use the
- pointer size of that compilation unit. However, since we are
- displaying it seperately here, we either have to store
- pointer sizes of all compilation units, or assume they don't
- change. We assume, like the debug_line display, that
- it doesn't change. */
- begin = byte_get (start, debug_line_pointer_size);
- start += debug_line_pointer_size;
- end = byte_get (start, debug_line_pointer_size);
- start += debug_line_pointer_size;
+ begin = byte_get (start, pointer_size);
+ start += pointer_size;
+ end = byte_get (start, pointer_size);
+ start += pointer_size;
if (begin == 0 && end == 0)
break;
+ /* For now, skip any base address specifiers. */
+ if (begin == 0xffffffff)
+ continue;
+
begin += addr;
end += addr;
@@ -7456,7 +7728,7 @@ display_debug_loc (section, start, file)
start += 2;
printf (" %8.8lx %8.8lx %8.8lx (", offset, begin, end);
- decode_location_expression (start, debug_line_pointer_size, length);
+ decode_location_expression (start, pointer_size, length);
printf (")\n");
start += length;
@@ -7466,39 +7738,31 @@ display_debug_loc (section, start, file)
return 1;
}
-static const char * debug_str_contents;
-static bfd_vma debug_str_size;
+static const char *debug_str_contents;
+static bfd_vma debug_str_size;
static void
-load_debug_str (file)
- FILE * file;
+load_debug_str (FILE *file)
{
- Elf32_Internal_Shdr * sec;
- unsigned int i;
+ Elf_Internal_Shdr *sec;
/* If it is already loaded, do nothing. */
if (debug_str_contents != NULL)
return;
/* Locate the .debug_str section. */
- for (i = 0, sec = section_headers;
- i < elf_header.e_shnum;
- i ++, sec ++)
- if (strcmp (SECTION_NAME (sec), ".debug_str") == 0)
- break;
-
- if (i == elf_header.e_shnum || sec->sh_size == 0)
+ sec = find_section (".debug_str");
+ if (sec == NULL)
return;
debug_str_size = sec->sh_size;
- debug_str_contents = ((char *)
- get_data (NULL, file, sec->sh_offset, sec->sh_size,
- _("debug_str section data")));
+ debug_str_contents = get_data (NULL, file, sec->sh_offset, sec->sh_size,
+ _("debug_str section data"));
}
static void
-free_debug_str ()
+free_debug_str (void)
{
if (debug_str_contents == NULL)
return;
@@ -7509,8 +7773,7 @@ free_debug_str ()
}
static const char *
-fetch_indirect_string (offset)
- unsigned long offset;
+fetch_indirect_string (unsigned long offset)
{
if (debug_str_contents == NULL)
return _("<no .debug_str section>");
@@ -7521,15 +7784,13 @@ fetch_indirect_string (offset)
return debug_str_contents + offset;
}
-
static int
-display_debug_str (section, start, file)
- Elf32_Internal_Shdr * section;
- unsigned char * start;
- FILE * file ATTRIBUTE_UNUSED;
+display_debug_str (Elf_Internal_Shdr *section,
+ unsigned char *start,
+ FILE *file ATTRIBUTE_UNUSED)
{
- unsigned long bytes;
- bfd_vma addr;
+ unsigned long bytes;
+ bfd_vma addr;
addr = section->sh_addr;
bytes = section->sh_size;
@@ -7555,7 +7816,7 @@ display_debug_str (section, start, file)
for (j = 0; j < 16; j++)
{
if (j < lbytes)
- printf ("%2.2x", start [j]);
+ printf ("%2.2x", start[j]);
else
printf (" ");
@@ -7565,7 +7826,7 @@ display_debug_str (section, start, file)
for (j = 0; j < lbytes; j++)
{
- k = start [j];
+ k = start[j];
if (k >= ' ' && k < 0x80)
printf ("%c", k);
else
@@ -7582,18 +7843,18 @@ display_debug_str (section, start, file)
return 1;
}
-
static unsigned char *
-read_and_display_attr_value (attribute, form, data, cu_offset, pointer_size)
- unsigned long attribute;
- unsigned long form;
- unsigned char * data;
- unsigned long cu_offset;
- unsigned long pointer_size;
+read_and_display_attr_value (unsigned long attribute,
+ unsigned long form,
+ unsigned char *data,
+ unsigned long cu_offset,
+ unsigned long pointer_size,
+ unsigned long offset_size,
+ int dwarf_version)
{
- unsigned long uvalue = 0;
- unsigned char * block_start = NULL;
- int bytes_read;
+ unsigned long uvalue = 0;
+ unsigned char *block_start = NULL;
+ int bytes_read;
switch (form)
{
@@ -7601,20 +7862,36 @@ read_and_display_attr_value (attribute, form, data, cu_offset, pointer_size)
break;
case DW_FORM_ref_addr:
+ if (dwarf_version == 2)
+ {
+ uvalue = byte_get (data, pointer_size);
+ data += pointer_size;
+ }
+ else if (dwarf_version == 3)
+ {
+ uvalue = byte_get (data, offset_size);
+ data += offset_size;
+ }
+ else
+ {
+ error (_("Internal error: DWARF version is not 2 or 3.\n"));
+ }
+ break;
+
case DW_FORM_addr:
uvalue = byte_get (data, pointer_size);
data += pointer_size;
break;
case DW_FORM_strp:
- uvalue = byte_get (data, /* offset_size */ 4);
- data += /* offset_size */ 4;
+ uvalue = byte_get (data, offset_size);
+ data += offset_size;
break;
case DW_FORM_ref1:
case DW_FORM_flag:
case DW_FORM_data1:
- uvalue = byte_get (data ++, 1);
+ uvalue = byte_get (data++, 1);
break;
case DW_FORM_ref2:
@@ -7645,7 +7922,8 @@ read_and_display_attr_value (attribute, form, data, cu_offset, pointer_size)
data += bytes_read;
printf (" %s", get_FORM_name (form));
return read_and_display_attr_value (attribute, form, data, cu_offset,
- pointer_size);
+ pointer_size, offset_size,
+ dwarf_version);
}
switch (form)
@@ -7663,6 +7941,7 @@ read_and_display_attr_value (attribute, form, data, cu_offset, pointer_size)
case DW_FORM_addr:
printf (" %#lx", uvalue);
+ break;
case DW_FORM_flag:
case DW_FORM_data1:
@@ -7711,8 +7990,8 @@ read_and_display_attr_value (attribute, form, data, cu_offset, pointer_size)
break;
case DW_FORM_strp:
- printf (_(" (indirect string, offset: 0x%lx): "), uvalue);
- printf (fetch_indirect_string (uvalue));
+ printf (_(" (indirect string, offset: 0x%lx): %s"),
+ uvalue, fetch_indirect_string (uvalue));
break;
case DW_FORM_indirect:
@@ -7724,7 +8003,7 @@ read_and_display_attr_value (attribute, form, data, cu_offset, pointer_size)
break;
}
- /* For some attributes we can display futher information. */
+ /* For some attributes we can display further information. */
printf ("\t");
@@ -7733,51 +8012,65 @@ read_and_display_attr_value (attribute, form, data, cu_offset, pointer_size)
case DW_AT_inline:
switch (uvalue)
{
- case DW_INL_not_inlined: printf (_("(not inlined)")); break;
- case DW_INL_inlined: printf (_("(inlined)")); break;
- case DW_INL_declared_not_inlined: printf (_("(declared as inline but ignored)")); break;
- case DW_INL_declared_inlined: printf (_("(declared as inline and inlined)")); break;
- default: printf (_(" (Unknown inline attribute value: %lx)"), uvalue); break;
+ case DW_INL_not_inlined:
+ printf (_("(not inlined)"));
+ break;
+ case DW_INL_inlined:
+ printf (_("(inlined)"));
+ break;
+ case DW_INL_declared_not_inlined:
+ printf (_("(declared as inline but ignored)"));
+ break;
+ case DW_INL_declared_inlined:
+ printf (_("(declared as inline and inlined)"));
+ break;
+ default:
+ printf (_(" (Unknown inline attribute value: %lx)"), uvalue);
+ break;
}
break;
case DW_AT_language:
switch (uvalue)
{
- case DW_LANG_C: printf ("(non-ANSI C)"); break;
- case DW_LANG_C89: printf ("(ANSI C)"); break;
- case DW_LANG_C_plus_plus: printf ("(C++)"); break;
- case DW_LANG_Fortran77: printf ("(FORTRAN 77)"); break;
- case DW_LANG_Fortran90: printf ("(Fortran 90)"); break;
- case DW_LANG_Modula2: printf ("(Modula 2)"); break;
- case DW_LANG_Pascal83: printf ("(ANSI Pascal)"); break;
- case DW_LANG_Ada83: printf ("(Ada)"); break;
- case DW_LANG_Cobol74: printf ("(Cobol 74)"); break;
- case DW_LANG_Cobol85: printf ("(Cobol 85)"); break;
- /* DWARF 2.1 values. */
- case DW_LANG_C99: printf ("(ANSI C99)"); break;
- case DW_LANG_Ada95: printf ("(ADA 95)"); break;
- case DW_LANG_Fortran95: printf ("(Fortran 95)"); break;
+ case DW_LANG_C: printf ("(non-ANSI C)"); break;
+ case DW_LANG_C89: printf ("(ANSI C)"); break;
+ case DW_LANG_C_plus_plus: printf ("(C++)"); break;
+ case DW_LANG_Fortran77: printf ("(FORTRAN 77)"); break;
+ case DW_LANG_Fortran90: printf ("(Fortran 90)"); break;
+ case DW_LANG_Modula2: printf ("(Modula 2)"); break;
+ case DW_LANG_Pascal83: printf ("(ANSI Pascal)"); break;
+ case DW_LANG_Ada83: printf ("(Ada)"); break;
+ case DW_LANG_Cobol74: printf ("(Cobol 74)"); break;
+ case DW_LANG_Cobol85: printf ("(Cobol 85)"); break;
+ /* DWARF 2.1 values. */
+ case DW_LANG_C99: printf ("(ANSI C99)"); break;
+ case DW_LANG_Ada95: printf ("(ADA 95)"); break;
+ case DW_LANG_Fortran95: printf ("(Fortran 95)"); break;
/* MIPS extension. */
- case DW_LANG_Mips_Assembler: printf ("(MIPS assembler)"); break;
- default: printf ("(Unknown: %lx)", uvalue); break;
+ case DW_LANG_Mips_Assembler: printf ("(MIPS assembler)"); break;
+ /* UPC extension. */
+ case DW_LANG_Upc: printf ("(Unified Parallel C)"); break;
+ default:
+ printf ("(Unknown: %lx)", uvalue);
+ break;
}
break;
case DW_AT_encoding:
switch (uvalue)
{
- case DW_ATE_void: printf ("(void)"); break;
- case DW_ATE_address: printf ("(machine address)"); break;
- case DW_ATE_boolean: printf ("(boolean)"); break;
- case DW_ATE_complex_float: printf ("(complex float)"); break;
- case DW_ATE_float: printf ("(float)"); break;
- case DW_ATE_signed: printf ("(signed)"); break;
- case DW_ATE_signed_char: printf ("(signed char)"); break;
- case DW_ATE_unsigned: printf ("(unsigned)"); break;
- case DW_ATE_unsigned_char: printf ("(unsigned char)"); break;
+ case DW_ATE_void: printf ("(void)"); break;
+ case DW_ATE_address: printf ("(machine address)"); break;
+ case DW_ATE_boolean: printf ("(boolean)"); break;
+ case DW_ATE_complex_float: printf ("(complex float)"); break;
+ case DW_ATE_float: printf ("(float)"); break;
+ case DW_ATE_signed: printf ("(signed)"); break;
+ case DW_ATE_signed_char: printf ("(signed char)"); break;
+ case DW_ATE_unsigned: printf ("(unsigned)"); break;
+ case DW_ATE_unsigned_char: printf ("(unsigned char)"); break;
/* DWARF 2.1 value. */
- case DW_ATE_imaginary_float: printf ("(imaginary float)"); break;
+ case DW_ATE_imaginary_float: printf ("(imaginary float)"); break;
default:
if (uvalue >= DW_ATE_lo_user
&& uvalue <= DW_ATE_hi_user)
@@ -7794,17 +8087,19 @@ read_and_display_attr_value (attribute, form, data, cu_offset, pointer_size)
case DW_ACCESS_public: printf ("(public)"); break;
case DW_ACCESS_protected: printf ("(protected)"); break;
case DW_ACCESS_private: printf ("(private)"); break;
- default: printf ("(unknown accessibility)"); break;
+ default:
+ printf ("(unknown accessibility)");
+ break;
}
break;
case DW_AT_visibility:
switch (uvalue)
{
- case DW_VIS_local: printf ("(local)"); break;
- case DW_VIS_exported: printf ("(exported)"); break;
- case DW_VIS_qualified: printf ("(qualified)"); break;
- default: printf ("(unknown visibility)"); break;
+ case DW_VIS_local: printf ("(local)"); break;
+ case DW_VIS_exported: printf ("(exported)"); break;
+ case DW_VIS_qualified: printf ("(qualified)"); break;
+ default: printf ("(unknown visibility)"); break;
}
break;
@@ -7814,7 +8109,7 @@ read_and_display_attr_value (attribute, form, data, cu_offset, pointer_size)
case DW_VIRTUALITY_none: printf ("(none)"); break;
case DW_VIRTUALITY_virtual: printf ("(virtual)"); break;
case DW_VIRTUALITY_pure_virtual:printf ("(pure_virtual)"); break;
- default: printf ("(unknown virtuality)"); break;
+ default: printf ("(unknown virtuality)"); break;
}
break;
@@ -7825,7 +8120,7 @@ read_and_display_attr_value (attribute, form, data, cu_offset, pointer_size)
case DW_ID_up_case: printf ("(up_case)"); break;
case DW_ID_down_case: printf ("(down_case)"); break;
case DW_ID_case_insensitive: printf ("(case_insensitive)"); break;
- default: printf ("(unknown case)"); break;
+ default: printf ("(unknown case)"); break;
}
break;
@@ -7869,7 +8164,7 @@ read_and_display_attr_value (attribute, form, data, cu_offset, pointer_size)
decode_location_expression (block_start, pointer_size, uvalue);
printf (")");
}
- else if (form == DW_FORM_data4)
+ else if (form == DW_FORM_data4 || form == DW_FORM_data8)
{
printf ("(");
printf ("location list");
@@ -7885,28 +8180,28 @@ read_and_display_attr_value (attribute, form, data, cu_offset, pointer_size)
}
static unsigned char *
-read_and_display_attr (attribute, form, data, cu_offset, pointer_size)
- unsigned long attribute;
- unsigned long form;
- unsigned char * data;
- unsigned long cu_offset;
- unsigned long pointer_size;
+read_and_display_attr (unsigned long attribute,
+ unsigned long form,
+ unsigned char *data,
+ unsigned long cu_offset,
+ unsigned long pointer_size,
+ unsigned long offset_size,
+ int dwarf_version)
{
printf (" %-18s:", get_AT_name (attribute));
data = read_and_display_attr_value (attribute, form, data, cu_offset,
- pointer_size);
+ pointer_size, offset_size, dwarf_version);
printf ("\n");
return data;
}
static int
-display_debug_info (section, start, file)
- Elf32_Internal_Shdr * section;
- unsigned char * start;
- FILE * file;
+display_debug_info (Elf_Internal_Shdr *section,
+ unsigned char *start,
+ FILE *file)
{
- unsigned char * end = start + section->sh_size;
- unsigned char * section_begin = start;
+ unsigned char *end = start + section->sh_size;
+ unsigned char *section_begin = start;
printf (_("The section %s contains:\n\n"), SECTION_NAME (section));
@@ -7915,36 +8210,45 @@ display_debug_info (section, start, file)
while (start < end)
{
- DWARF2_External_CompUnit * external;
- DWARF2_Internal_CompUnit compunit;
- Elf32_Internal_Shdr * relsec;
- unsigned char * tags;
- unsigned int i;
- int level;
- unsigned long cu_offset;
+ DWARF2_Internal_CompUnit compunit;
+ Elf_Internal_Shdr *relsec;
+ unsigned char *hdrptr;
+ unsigned char *cu_abbrev_offset_ptr;
+ unsigned char *tags;
+ int level;
+ unsigned long cu_offset;
+ int offset_size;
+ int initial_length_size;
- external = (DWARF2_External_CompUnit *) start;
+ hdrptr = start;
- compunit.cu_length = BYTE_GET (external->cu_length);
- compunit.cu_version = BYTE_GET (external->cu_version);
- compunit.cu_abbrev_offset = BYTE_GET (external->cu_abbrev_offset);
- compunit.cu_pointer_size = BYTE_GET (external->cu_pointer_size);
+ compunit.cu_length = byte_get (hdrptr, 4);
+ hdrptr += 4;
if (compunit.cu_length == 0xffffffff)
{
- warn (_("64-bit DWARF debug info is not supported yet.\n"));
- break;
+ compunit.cu_length = byte_get (hdrptr, 8);
+ hdrptr += 8;
+ offset_size = 8;
+ initial_length_size = 12;
+ }
+ else
+ {
+ offset_size = 4;
+ initial_length_size = 4;
}
- /* Check for RELA relocations in the abbrev_offset address, and
- apply them. */
+ compunit.cu_version = byte_get (hdrptr, 2);
+ hdrptr += 2;
+
+ /* Apply addends of RELA relocations. */
for (relsec = section_headers;
relsec < section_headers + elf_header.e_shnum;
++relsec)
{
unsigned long nrelas;
Elf_Internal_Rela *rela, *rp;
- Elf32_Internal_Shdr *symsec;
+ Elf_Internal_Shdr *symsec;
Elf_Internal_Sym *symtab;
Elf_Internal_Sym *sym;
@@ -7962,9 +8266,13 @@ display_debug_info (section, start, file)
for (rp = rela; rp < rela + nrelas; ++rp)
{
- if (rp->r_offset
- != (bfd_vma) ((unsigned char *) &external->cu_abbrev_offset
- - section_begin))
+ unsigned char *loc;
+
+ if (rp->r_offset >= (bfd_vma) (hdrptr - section_begin)
+ && section->sh_size > (bfd_vma) offset_size
+ && rp->r_offset <= section->sh_size - offset_size)
+ loc = section_begin + rp->r_offset;
+ else
continue;
if (is_32bit_elf)
@@ -7992,17 +8300,23 @@ display_debug_info (section, start, file)
}
}
- compunit.cu_abbrev_offset = rp->r_addend;
- break;
+ byte_put (loc, rp->r_addend, offset_size);
}
free (rela);
break;
}
- tags = start + sizeof (* external);
+ cu_abbrev_offset_ptr = hdrptr;
+ compunit.cu_abbrev_offset = byte_get (hdrptr, offset_size);
+ hdrptr += offset_size;
+
+ compunit.cu_pointer_size = byte_get (hdrptr, 1);
+ hdrptr += 1;
+
+ tags = hdrptr;
cu_offset = start - section_begin;
- start += compunit.cu_length + sizeof (external->cu_length);
+ start += compunit.cu_length + initial_length_size;
printf (_(" Compilation Unit @ %lx:\n"), cu_offset);
printf (_(" Length: %ld\n"), compunit.cu_length);
@@ -8010,36 +8324,29 @@ display_debug_info (section, start, file)
printf (_(" Abbrev Offset: %ld\n"), compunit.cu_abbrev_offset);
printf (_(" Pointer Size: %d\n"), compunit.cu_pointer_size);
- if (compunit.cu_version != 2)
+ if (compunit.cu_version != 2 && compunit.cu_version != 3)
{
- warn (_("Only version 2 DWARF debug information is currently supported.\n"));
+ warn (_("Only version 2 and 3 DWARF debug information is currently supported.\n"));
continue;
}
free_abbrevs ();
/* Read in the abbrevs used by this compilation unit. */
-
{
- Elf32_Internal_Shdr * sec;
- unsigned char * begin;
+ Elf_Internal_Shdr *sec;
+ unsigned char *begin;
/* Locate the .debug_abbrev section and process it. */
- for (i = 0, sec = section_headers;
- i < elf_header.e_shnum;
- i ++, sec ++)
- if (strcmp (SECTION_NAME (sec), ".debug_abbrev") == 0)
- break;
-
- if (i == elf_header.e_shnum || sec->sh_size == 0)
+ sec = find_section (".debug_abbrev");
+ if (sec == NULL)
{
warn (_("Unable to locate .debug_abbrev section!\n"));
return 0;
}
- begin = ((unsigned char *)
- get_data (NULL, file, sec->sh_offset, sec->sh_size,
- _("debug_abbrev section data")));
+ begin = get_data (NULL, file, sec->sh_offset, sec->sh_size,
+ _("debug_abbrev section data"));
if (!begin)
return 0;
@@ -8052,10 +8359,10 @@ display_debug_info (section, start, file)
level = 0;
while (tags < start)
{
- int bytes_read;
- unsigned long abbrev_number;
- abbrev_entry * entry;
- abbrev_attr * attr;
+ int bytes_read;
+ unsigned long abbrev_number;
+ abbrev_entry *entry;
+ abbrev_attr *attr;
abbrev_number = read_leb128 (tags, & bytes_read, 0);
tags += bytes_read;
@@ -8091,7 +8398,9 @@ display_debug_info (section, start, file)
tags = read_and_display_attr (attr->attribute,
attr->form,
tags, cu_offset,
- compunit.cu_pointer_size);
+ compunit.cu_pointer_size,
+ offset_size,
+ compunit.cu_version);
if (entry->children)
++level;
@@ -8107,41 +8416,58 @@ display_debug_info (section, start, file)
}
static int
-display_debug_aranges (section, start, file)
- Elf32_Internal_Shdr * section;
- unsigned char * start;
- FILE * file ATTRIBUTE_UNUSED;
+display_debug_aranges (Elf_Internal_Shdr *section,
+ unsigned char *start,
+ FILE *file ATTRIBUTE_UNUSED)
{
- unsigned char * end = start + section->sh_size;
+ unsigned char *end = start + section->sh_size;
printf (_("The section %s contains:\n\n"), SECTION_NAME (section));
while (start < end)
{
- DWARF2_External_ARange * external;
- DWARF2_Internal_ARange arange;
- unsigned char * ranges;
- unsigned long length;
- unsigned long address;
- int excess;
+ unsigned char *hdrptr;
+ DWARF2_Internal_ARange arange;
+ unsigned char *ranges;
+ unsigned long length;
+ unsigned long address;
+ int excess;
+ int offset_size;
+ int initial_length_size;
- external = (DWARF2_External_ARange *) start;
+ hdrptr = start;
- arange.ar_length = BYTE_GET (external->ar_length);
- arange.ar_version = BYTE_GET (external->ar_version);
- arange.ar_info_offset = BYTE_GET (external->ar_info_offset);
- arange.ar_pointer_size = BYTE_GET (external->ar_pointer_size);
- arange.ar_segment_size = BYTE_GET (external->ar_segment_size);
+ arange.ar_length = byte_get (hdrptr, 4);
+ hdrptr += 4;
if (arange.ar_length == 0xffffffff)
{
- warn (_("64-bit DWARF aranges are not supported yet.\n"));
- break;
+ arange.ar_length = byte_get (hdrptr, 8);
+ hdrptr += 8;
+ offset_size = 8;
+ initial_length_size = 12;
}
+ else
+ {
+ offset_size = 4;
+ initial_length_size = 4;
+ }
+
+ arange.ar_version = byte_get (hdrptr, 2);
+ hdrptr += 2;
- if (arange.ar_version != 2)
+ arange.ar_info_offset = byte_get (hdrptr, offset_size);
+ hdrptr += offset_size;
+
+ arange.ar_pointer_size = byte_get (hdrptr, 1);
+ hdrptr += 1;
+
+ arange.ar_segment_size = byte_get (hdrptr, 1);
+ hdrptr += 1;
+
+ if (arange.ar_version != 2 && arange.ar_version != 3)
{
- warn (_("Only DWARF 2 aranges are currently supported.\n"));
+ warn (_("Only DWARF 2 and 3 aranges are currently supported.\n"));
break;
}
@@ -8153,10 +8479,10 @@ display_debug_aranges (section, start, file)
printf (_("\n Address Length\n"));
- ranges = start + sizeof (* external);
+ ranges = hdrptr;
/* Must pad to an alignment boundary that is twice the pointer size. */
- excess = sizeof (* external) % (2 * arange.ar_pointer_size);
+ excess = (hdrptr - start) % (2 * arange.ar_pointer_size);
if (excess)
ranges += (2 * arange.ar_pointer_size) - excess;
@@ -8177,7 +8503,7 @@ display_debug_aranges (section, start, file)
printf (" %8.8lx %lu\n", address, length);
}
- start += arange.ar_length + sizeof (external->ar_length);
+ start += arange.ar_length + initial_length_size;
}
printf ("\n");
@@ -8187,21 +8513,22 @@ display_debug_aranges (section, start, file)
typedef struct Frame_Chunk
{
- struct Frame_Chunk * next;
- unsigned char * chunk_start;
- int ncols;
+ struct Frame_Chunk *next;
+ unsigned char *chunk_start;
+ int ncols;
/* DW_CFA_{undefined,same_value,offset,register,unreferenced} */
- short int * col_type;
- int * col_offset;
- char * augmentation;
- unsigned int code_factor;
- int data_factor;
- unsigned long pc_begin;
- unsigned long pc_range;
- int cfa_reg;
- int cfa_offset;
- int ra;
- unsigned char fde_encoding;
+ short int *col_type;
+ int *col_offset;
+ char *augmentation;
+ unsigned int code_factor;
+ int data_factor;
+ unsigned long pc_begin;
+ unsigned long pc_range;
+ int cfa_reg;
+ int cfa_offset;
+ int ra;
+ unsigned char fde_encoding;
+ unsigned char cfa_exp;
}
Frame_Chunk;
@@ -8209,14 +8536,8 @@ Frame_Chunk;
in the frame info. */
#define DW_CFA_unreferenced (-1)
-static void frame_need_space PARAMS ((Frame_Chunk *, int));
-static void frame_display_row PARAMS ((Frame_Chunk *, int *, int *));
-static int size_of_encoded_value PARAMS ((int));
-
static void
-frame_need_space (fc, reg)
- Frame_Chunk * fc;
- int reg;
+frame_need_space (Frame_Chunk *fc, int reg)
{
int prev = fc->ncols;
@@ -8224,10 +8545,8 @@ frame_need_space (fc, reg)
return;
fc->ncols = reg + 1;
- fc->col_type = (short int *) xrealloc (fc->col_type,
- fc->ncols * sizeof (short int));
- fc->col_offset = (int *) xrealloc (fc->col_offset,
- fc->ncols * sizeof (int));
+ fc->col_type = xrealloc (fc->col_type, fc->ncols * sizeof (short int));
+ fc->col_offset = xrealloc (fc->col_offset, fc->ncols * sizeof (int));
while (prev < fc->ncols)
{
@@ -8238,24 +8557,21 @@ frame_need_space (fc, reg)
}
static void
-frame_display_row (fc, need_col_headers, max_regs)
- Frame_Chunk * fc;
- int * need_col_headers;
- int * max_regs;
+frame_display_row (Frame_Chunk *fc, int *need_col_headers, int *max_regs)
{
int r;
char tmp[100];
- if (* max_regs < fc->ncols)
- * max_regs = fc->ncols;
+ if (*max_regs < fc->ncols)
+ *max_regs = fc->ncols;
- if (* need_col_headers)
+ if (*need_col_headers)
{
- * need_col_headers = 0;
+ *need_col_headers = 0;
printf (" LOC CFA ");
- for (r = 0; r < * max_regs; r++)
+ for (r = 0; r < *max_regs; r++)
if (fc->col_type[r] != DW_CFA_unreferenced)
{
if (r == fc->ra)
@@ -8268,7 +8584,10 @@ frame_display_row (fc, need_col_headers, max_regs)
}
printf ("%08lx ", fc->pc_begin);
- sprintf (tmp, "r%d%+d", fc->cfa_reg, fc->cfa_offset);
+ if (fc->cfa_exp)
+ strcpy (tmp, "exp");
+ else
+ sprintf (tmp, "r%d%+d", fc->cfa_reg, fc->cfa_offset);
printf ("%-8s ", tmp);
for (r = 0; r < fc->ncols; r++)
@@ -8289,6 +8608,9 @@ frame_display_row (fc, need_col_headers, max_regs)
case DW_CFA_register:
sprintf (tmp, "r%d", fc->col_offset[r]);
break;
+ case DW_CFA_expression:
+ strcpy (tmp, "exp");
+ break;
default:
strcpy (tmp, "n/a");
break;
@@ -8300,8 +8622,7 @@ frame_display_row (fc, need_col_headers, max_regs)
}
static int
-size_of_encoded_value (encoding)
- int encoding;
+size_of_encoded_value (int encoding)
{
switch (encoding & 0x7)
{
@@ -8313,69 +8634,91 @@ size_of_encoded_value (encoding)
}
}
+static bfd_vma
+get_encoded_value (unsigned char *data, int encoding)
+{
+ int size = size_of_encoded_value (encoding);
+ if (encoding & DW_EH_PE_signed)
+ return byte_get_signed (data, size);
+ else
+ return byte_get (data, size);
+}
+
#define GET(N) byte_get (start, N); start += N
#define LEB() read_leb128 (start, & length_return, 0); start += length_return
#define SLEB() read_leb128 (start, & length_return, 1); start += length_return
static int
-display_debug_frames (section, start, file)
- Elf32_Internal_Shdr * section;
- unsigned char * start;
- FILE * file ATTRIBUTE_UNUSED;
-{
- unsigned char * end = start + section->sh_size;
- unsigned char * section_start = start;
- Frame_Chunk * chunks = 0;
- Frame_Chunk * remembered_state = 0;
- Frame_Chunk * rs;
- int is_eh = (strcmp (SECTION_NAME (section), ".eh_frame") == 0);
- int length_return;
- int max_regs = 0;
- int addr_size = is_32bit_elf ? 4 : 8;
+display_debug_frames (Elf_Internal_Shdr *section,
+ unsigned char *start,
+ FILE *file ATTRIBUTE_UNUSED)
+{
+ unsigned char *end = start + section->sh_size;
+ unsigned char *section_start = start;
+ Frame_Chunk *chunks = 0;
+ Frame_Chunk *remembered_state = 0;
+ Frame_Chunk *rs;
+ int is_eh = (strcmp (SECTION_NAME (section), ".eh_frame") == 0);
+ int length_return;
+ int max_regs = 0;
+ int addr_size = is_32bit_elf ? 4 : 8;
printf (_("The section %s contains:\n"), SECTION_NAME (section));
while (start < end)
{
- unsigned char * saved_start;
- unsigned char * block_end;
- unsigned long length;
- unsigned long cie_id;
- Frame_Chunk * fc;
- Frame_Chunk * cie;
- int need_col_headers = 1;
- unsigned char * augmentation_data = NULL;
- unsigned long augmentation_data_len = 0;
- int encoded_ptr_size = addr_size;
+ unsigned char *saved_start;
+ unsigned char *block_end;
+ unsigned long length;
+ unsigned long cie_id;
+ Frame_Chunk *fc;
+ Frame_Chunk *cie;
+ int need_col_headers = 1;
+ unsigned char *augmentation_data = NULL;
+ unsigned long augmentation_data_len = 0;
+ int encoded_ptr_size = addr_size;
+ int offset_size;
+ int initial_length_size;
saved_start = start;
length = byte_get (start, 4); start += 4;
if (length == 0)
- return 1;
+ {
+ printf ("\n%08lx ZERO terminator\n\n",
+ (unsigned long)(saved_start - section_start));
+ return 1;
+ }
if (length == 0xffffffff)
{
- warn (_("64-bit DWARF format frames are not supported yet.\n"));
- break;
+ length = byte_get (start, 8);
+ start += 8;
+ offset_size = 8;
+ initial_length_size = 12;
+ }
+ else
+ {
+ offset_size = 4;
+ initial_length_size = 4;
}
- block_end = saved_start + length + 4;
- cie_id = byte_get (start, 4); start += 4;
+ block_end = saved_start + length + initial_length_size;
+ cie_id = byte_get (start, offset_size); start += offset_size;
if (is_eh ? (cie_id == 0) : (cie_id == DW_CIE_ID))
{
int version;
- fc = (Frame_Chunk *) xmalloc (sizeof (Frame_Chunk));
+ fc = xmalloc (sizeof (Frame_Chunk));
memset (fc, 0, sizeof (Frame_Chunk));
fc->next = chunks;
chunks = fc;
fc->chunk_start = saved_start;
fc->ncols = 0;
- fc->col_type = (short int *) xmalloc (sizeof (short int));
- fc->col_offset = (int *) xmalloc (sizeof (int));
+ fc->col_type = xmalloc (sizeof (short int));
+ fc->col_offset = xmalloc (sizeof (int));
frame_need_space (fc, max_regs-1);
version = *start++;
@@ -8460,7 +8803,7 @@ display_debug_frames (section, start, file)
}
else
{
- unsigned char * look_for;
+ unsigned char *look_for;
static Frame_Chunk fde_fc;
fc = & fde_fc;
@@ -8478,8 +8821,8 @@ display_debug_frames (section, start, file)
cie_id, saved_start);
start = block_end;
fc->ncols = 0;
- fc->col_type = (short int *) xmalloc (sizeof (short int));
- fc->col_offset = (int *) xmalloc (sizeof (int));
+ fc->col_type = xmalloc (sizeof (short int));
+ fc->col_offset = xmalloc (sizeof (int));
frame_need_space (fc, max_regs - 1);
cie = fc;
fc->augmentation = "";
@@ -8488,8 +8831,8 @@ display_debug_frames (section, start, file)
else
{
fc->ncols = cie->ncols;
- fc->col_type = (short int *) xmalloc (fc->ncols * sizeof (short int));
- fc->col_offset = (int *) xmalloc (fc->ncols * sizeof (int));
+ fc->col_type = xmalloc (fc->ncols * sizeof (short int));
+ fc->col_offset = xmalloc (fc->ncols * sizeof (int));
memcpy (fc->col_type, cie->col_type, fc->ncols * sizeof (short int));
memcpy (fc->col_offset, cie->col_offset, fc->ncols * sizeof (int));
fc->augmentation = cie->augmentation;
@@ -8505,7 +8848,9 @@ display_debug_frames (section, start, file)
if (fc->fde_encoding)
encoded_ptr_size = size_of_encoded_value (fc->fde_encoding);
- fc->pc_begin = byte_get (start, encoded_ptr_size);
+ fc->pc_begin = get_encoded_value (start, fc->fde_encoding);
+ if ((fc->fde_encoding & 0x70) == DW_EH_PE_pcrel)
+ fc->pc_begin += section->sh_addr + (start - section_start);
start += encoded_ptr_size;
fc->pc_range = byte_get (start, encoded_ptr_size);
start += encoded_ptr_size;
@@ -8534,19 +8879,23 @@ display_debug_frames (section, start, file)
/* At this point, fc is the current chunk, cie (if any) is set, and we're
about to interpret instructions for the chunk. */
-
- if (do_debug_frames_interp)
+ /* ??? At present we need to do this always, since this sizes the
+ fc->col_type and fc->col_offset arrays, which we write into always.
+ We should probably split the interpreted and non-interpreted bits
+ into two different routines, since there's so much that doesn't
+ really overlap between them. */
+ if (1 || do_debug_frames_interp)
{
/* Start by making a pass over the chunk, allocating storage
and taking note of what registers are used. */
- unsigned char * tmp = start;
+ unsigned char *tmp = start;
while (start < block_end)
{
unsigned op, opa;
- unsigned long reg;
+ unsigned long reg, tmp;
- op = * start ++;
+ op = *start++;
opa = op & 0x3f;
if (op & 0xc0)
op &= 0xc0;
@@ -8612,6 +8961,17 @@ display_debug_frames (section, start, file)
case DW_CFA_def_cfa_offset:
LEB ();
break;
+ case DW_CFA_def_cfa_expression:
+ tmp = LEB ();
+ start += tmp;
+ break;
+ case DW_CFA_expression:
+ reg = LEB ();
+ tmp = LEB ();
+ start += tmp;
+ frame_need_space (fc, reg);
+ fc->col_type[reg] = DW_CFA_undefined;
+ break;
case DW_CFA_offset_extended_sf:
reg = LEB (); SLEB ();
frame_need_space (fc, reg);
@@ -8623,6 +8983,9 @@ display_debug_frames (section, start, file)
case DW_CFA_def_cfa_offset_sf:
SLEB ();
break;
+ case DW_CFA_MIPS_advance_loc8:
+ start += 8;
+ break;
case DW_CFA_GNU_args_size:
LEB ();
break;
@@ -8648,7 +9011,7 @@ display_debug_frames (section, start, file)
long l, ofs;
bfd_vma vma;
- op = * start ++;
+ op = *start++;
opa = op & 0x3f;
if (op & 0xc0)
op &= 0xc0;
@@ -8684,7 +9047,9 @@ display_debug_frames (section, start, file)
break;
case DW_CFA_set_loc:
- vma = byte_get (start, encoded_ptr_size);
+ vma = get_encoded_value (start, fc->fde_encoding);
+ if ((fc->fde_encoding & 0x70) == DW_EH_PE_pcrel)
+ vma += section->sh_addr + (start - section_start);
start += encoded_ptr_size;
if (do_debug_frames_interp)
frame_display_row (fc, &need_col_headers, &max_regs);
@@ -8764,7 +9129,7 @@ display_debug_frames (section, start, file)
reg = LEB ();
roffs = LEB ();
if (! do_debug_frames_interp)
- printf (" DW_CFA_register: r%ld\n", reg);
+ printf (" DW_CFA_register: r%ld in r%ld\n", reg, roffs);
fc->col_type[reg] = DW_CFA_register;
fc->col_offset[reg] = roffs;
break;
@@ -8772,10 +9137,10 @@ display_debug_frames (section, start, file)
case DW_CFA_remember_state:
if (! do_debug_frames_interp)
printf (" DW_CFA_remember_state\n");
- rs = (Frame_Chunk *) xmalloc (sizeof (Frame_Chunk));
+ rs = xmalloc (sizeof (Frame_Chunk));
rs->ncols = fc->ncols;
- rs->col_type = (short int *) xmalloc (rs->ncols * sizeof (short int));
- rs->col_offset = (int *) xmalloc (rs->ncols * sizeof (int));
+ rs->col_type = xmalloc (rs->ncols * sizeof (short int));
+ rs->col_offset = xmalloc (rs->ncols * sizeof (int));
memcpy (rs->col_type, fc->col_type, rs->ncols);
memcpy (rs->col_offset, fc->col_offset, rs->ncols * sizeof (int));
rs->next = remembered_state;
@@ -8786,18 +9151,25 @@ display_debug_frames (section, start, file)
if (! do_debug_frames_interp)
printf (" DW_CFA_restore_state\n");
rs = remembered_state;
- remembered_state = rs->next;
- frame_need_space (fc, rs->ncols-1);
- memcpy (fc->col_type, rs->col_type, rs->ncols);
- memcpy (fc->col_offset, rs->col_offset, rs->ncols * sizeof (int));
- free (rs->col_type);
- free (rs->col_offset);
- free (rs);
+ if (rs)
+ {
+ remembered_state = rs->next;
+ frame_need_space (fc, rs->ncols-1);
+ memcpy (fc->col_type, rs->col_type, rs->ncols);
+ memcpy (fc->col_offset, rs->col_offset,
+ rs->ncols * sizeof (int));
+ free (rs->col_type);
+ free (rs->col_offset);
+ free (rs);
+ }
+ else if (do_debug_frames_interp)
+ printf ("Mismatched DW_CFA_restore_state\n");
break;
case DW_CFA_def_cfa:
fc->cfa_reg = LEB ();
fc->cfa_offset = LEB ();
+ fc->cfa_exp = 0;
if (! do_debug_frames_interp)
printf (" DW_CFA_def_cfa: r%d ofs %d\n",
fc->cfa_reg, fc->cfa_offset);
@@ -8805,6 +9177,7 @@ display_debug_frames (section, start, file)
case DW_CFA_def_cfa_register:
fc->cfa_reg = LEB ();
+ fc->cfa_exp = 0;
if (! do_debug_frames_interp)
printf (" DW_CFA_def_cfa_reg: r%d\n", fc->cfa_reg);
break;
@@ -8820,6 +9193,31 @@ display_debug_frames (section, start, file)
printf (" DW_CFA_nop\n");
break;
+ case DW_CFA_def_cfa_expression:
+ ul = LEB ();
+ if (! do_debug_frames_interp)
+ {
+ printf (" DW_CFA_def_cfa_expression (");
+ decode_location_expression (start, addr_size, ul);
+ printf (")\n");
+ }
+ fc->cfa_exp = 1;
+ start += ul;
+ break;
+
+ case DW_CFA_expression:
+ reg = LEB ();
+ ul = LEB ();
+ if (! do_debug_frames_interp)
+ {
+ printf (" DW_CFA_expression: r%ld (", reg);
+ decode_location_expression (start, addr_size, ul);
+ printf (")\n");
+ }
+ fc->col_type[reg] = DW_CFA_expression;
+ start += ul;
+ break;
+
case DW_CFA_offset_extended_sf:
reg = LEB ();
l = SLEB ();
@@ -8834,6 +9232,7 @@ display_debug_frames (section, start, file)
case DW_CFA_def_cfa_sf:
fc->cfa_reg = LEB ();
fc->cfa_offset = SLEB ();
+ fc->cfa_exp = 0;
if (! do_debug_frames_interp)
printf (" DW_CFA_def_cfa_sf: r%d ofs %d\n",
fc->cfa_reg, fc->cfa_offset);
@@ -8845,6 +9244,17 @@ display_debug_frames (section, start, file)
printf (" DW_CFA_def_cfa_offset_sf: %d\n", fc->cfa_offset);
break;
+ case DW_CFA_MIPS_advance_loc8:
+ ofs = byte_get (start, 8); start += 8;
+ if (do_debug_frames_interp)
+ frame_display_row (fc, &need_col_headers, &max_regs);
+ else
+ printf (" DW_CFA_MIPS_advance_loc8: %ld to %08lx\n",
+ ofs * fc->code_factor,
+ fc->pc_begin + ofs * fc->code_factor);
+ fc->pc_begin += ofs * fc->code_factor;
+ break;
+
case DW_CFA_GNU_window_save:
if (! do_debug_frames_interp)
printf (" DW_CFA_GNU_window_save\n");
@@ -8867,17 +9277,6 @@ display_debug_frames (section, start, file)
fc->col_offset[reg] = l * fc->data_factor;
break;
- /* FIXME: How do we handle these? */
- case DW_CFA_def_cfa_expression:
- fprintf (stderr, "unsupported DW_CFA_def_cfa_expression\n");
- start = block_end;
- break;
-
- case DW_CFA_expression:
- fprintf (stderr, "unsupported DW_CFA_expression\n");
- start = block_end;
- break;
-
default:
fprintf (stderr, "unsupported or unknown DW_CFA_%d\n", op);
start = block_end;
@@ -8900,10 +9299,9 @@ display_debug_frames (section, start, file)
#undef SLEB
static int
-display_debug_not_supported (section, start, file)
- Elf32_Internal_Shdr * section;
- unsigned char * start ATTRIBUTE_UNUSED;
- FILE * file ATTRIBUTE_UNUSED;
+display_debug_not_supported (Elf_Internal_Shdr *section,
+ unsigned char *start ATTRIBUTE_UNUSED,
+ FILE *file ATTRIBUTE_UNUSED)
{
printf (_("Displaying the debug contents of section %s is not yet supported.\n"),
SECTION_NAME (section));
@@ -8911,62 +9309,40 @@ display_debug_not_supported (section, start, file)
return 1;
}
-/* Pre-scan the .debug_info section to record the size of address.
- When dumping the .debug_line, we use that size information, assuming
- that all compilation units have the same address size. */
-static int
-prescan_debug_info (section, start, file)
- Elf32_Internal_Shdr * section ATTRIBUTE_UNUSED;
- unsigned char * start;
- FILE * file ATTRIBUTE_UNUSED;
-{
- DWARF2_External_CompUnit * external;
-
- external = (DWARF2_External_CompUnit *) start;
-
- debug_line_pointer_size = BYTE_GET (external->cu_pointer_size);
- return 0;
-}
-
- /* A structure containing the name of a debug section and a pointer
- to a function that can decode it. The third field is a prescan
- function to be run over the section before displaying any of the
- sections. */
+/* A structure containing the name of a debug section
+ and a pointer to a function that can decode it. */
struct
{
- const char * const name;
- int (* display) PARAMS ((Elf32_Internal_Shdr *, unsigned char *, FILE *));
- int (* prescan) PARAMS ((Elf32_Internal_Shdr *, unsigned char *, FILE *));
+ const char *const name;
+ int (*display) (Elf_Internal_Shdr *, unsigned char *, FILE *);
}
debug_displays[] =
{
- { ".debug_abbrev", display_debug_abbrev, NULL },
- { ".debug_aranges", display_debug_aranges, NULL },
- { ".debug_frame", display_debug_frames, NULL },
- { ".debug_info", display_debug_info, prescan_debug_info },
- { ".debug_line", display_debug_lines, NULL },
- { ".debug_pubnames", display_debug_pubnames, NULL },
- { ".eh_frame", display_debug_frames, NULL },
- { ".debug_macinfo", display_debug_macinfo, NULL },
- { ".debug_str", display_debug_str, NULL },
- { ".debug_loc", display_debug_loc, NULL },
- { ".debug_pubtypes", display_debug_not_supported, NULL },
- { ".debug_ranges", display_debug_not_supported, NULL },
- { ".debug_static_func", display_debug_not_supported, NULL },
- { ".debug_static_vars", display_debug_not_supported, NULL },
- { ".debug_types", display_debug_not_supported, NULL },
- { ".debug_weaknames", display_debug_not_supported, NULL }
+ { ".debug_abbrev", display_debug_abbrev },
+ { ".debug_aranges", display_debug_aranges },
+ { ".debug_frame", display_debug_frames },
+ { ".debug_info", display_debug_info },
+ { ".debug_line", display_debug_lines },
+ { ".debug_pubnames", display_debug_pubnames },
+ { ".eh_frame", display_debug_frames },
+ { ".debug_macinfo", display_debug_macinfo },
+ { ".debug_str", display_debug_str },
+ { ".debug_loc", display_debug_loc },
+ { ".debug_pubtypes", display_debug_pubnames },
+ { ".debug_ranges", display_debug_not_supported },
+ { ".debug_static_func", display_debug_not_supported },
+ { ".debug_static_vars", display_debug_not_supported },
+ { ".debug_types", display_debug_not_supported },
+ { ".debug_weaknames", display_debug_not_supported }
};
static int
-display_debug_section (section, file)
- Elf32_Internal_Shdr * section;
- FILE * file;
+display_debug_section (Elf_Internal_Shdr *section, FILE *file)
{
- char * name = SECTION_NAME (section);
- bfd_size_type length;
- unsigned char * start;
- int i;
+ char *name = SECTION_NAME (section);
+ bfd_size_type length;
+ unsigned char *start;
+ int i;
length = section->sh_size;
if (length == 0)
@@ -8975,8 +9351,8 @@ display_debug_section (section, file)
return 0;
}
- start = (unsigned char *) get_data (NULL, file, section->sh_offset, length,
- _("debug section data"));
+ start = get_data (NULL, file, section->sh_offset, length,
+ _("debug section data"));
if (!start)
return 0;
@@ -9004,55 +9380,17 @@ display_debug_section (section, file)
}
static int
-process_section_contents (file)
- FILE * file;
+process_section_contents (FILE *file)
{
- Elf32_Internal_Shdr * section;
- unsigned int i;
+ Elf_Internal_Shdr *section;
+ unsigned int i;
if (! do_dump)
return 1;
- /* Pre-scan the debug sections to find some debug information not
- present in some of them. For the .debug_line, we must find out the
- size of address (specified in .debug_info and .debug_aranges). */
for (i = 0, section = section_headers;
i < elf_header.e_shnum && i < num_dump_sects;
- i ++, section ++)
- {
- char * name = SECTION_NAME (section);
- int j;
-
- if (section->sh_size == 0)
- continue;
-
- /* See if there is some pre-scan operation for this section. */
- for (j = NUM_ELEM (debug_displays); j--;)
- if (strcmp (debug_displays[j].name, name) == 0)
- {
- if (debug_displays[j].prescan != NULL)
- {
- bfd_size_type length;
- unsigned char * start;
-
- length = section->sh_size;
- start = ((unsigned char *)
- get_data (NULL, file, section->sh_offset, length,
- _("debug section data")));
- if (!start)
- return 0;
-
- debug_displays[j].prescan (section, start, file);
- free (start);
- }
-
- break;
- }
- }
-
- for (i = 0, section = section_headers;
- i < elf_header.e_shnum && i < num_dump_sects;
- i ++, section ++)
+ i++, section++)
{
#ifdef SUPPORT_DISASSEMBLY
if (dump_sects[i] & DISASS_DUMP)
@@ -9072,8 +9410,7 @@ process_section_contents (file)
}
static void
-process_mips_fpe_exception (mask)
- int mask;
+process_mips_fpe_exception (int mask)
{
if (mask)
{
@@ -9094,10 +9431,9 @@ process_mips_fpe_exception (mask)
}
static int
-process_mips_specific (file)
- FILE * file;
+process_mips_specific (FILE *file)
{
- Elf_Internal_Dyn * entry;
+ Elf_Internal_Dyn *entry;
size_t liblist_offset = 0;
size_t liblistno = 0;
size_t conflictsno = 0;
@@ -9113,16 +9449,20 @@ process_mips_specific (file)
switch (entry->d_tag)
{
case DT_MIPS_LIBLIST:
- liblist_offset = entry->d_un.d_val - loadaddr;
+ liblist_offset
+ = offset_from_vma (file, entry->d_un.d_val,
+ liblistno * sizeof (Elf32_External_Lib));
break;
case DT_MIPS_LIBLISTNO:
liblistno = entry->d_un.d_val;
break;
case DT_MIPS_OPTIONS:
- options_offset = entry->d_un.d_val - loadaddr;
+ options_offset = offset_from_vma (file, entry->d_un.d_val, 0);
break;
case DT_MIPS_CONFLICT:
- conflicts_offset = entry->d_un.d_val - loadaddr;
+ conflicts_offset
+ = offset_from_vma (file, entry->d_un.d_val,
+ conflictsno * sizeof (Elf32_External_Conflict));
break;
case DT_MIPS_CONFLICTNO:
conflictsno = entry->d_un.d_val;
@@ -9133,13 +9473,12 @@ process_mips_specific (file)
if (liblist_offset != 0 && liblistno != 0 && do_dynamic)
{
- Elf32_External_Lib * elib;
+ Elf32_External_Lib *elib;
size_t cnt;
- elib = ((Elf32_External_Lib *)
- get_data (NULL, file, liblist_offset,
- liblistno * sizeof (Elf32_External_Lib),
- _("liblist")));
+ elib = get_data (NULL, file, liblist_offset,
+ liblistno * sizeof (Elf32_External_Lib),
+ _("liblist"));
if (elib)
{
printf ("\nSection '.liblist' contains %lu entries:\n",
@@ -9152,7 +9491,7 @@ process_mips_specific (file)
Elf32_Lib liblist;
time_t time;
char timebuf[20];
- struct tm * tmp;
+ struct tm *tmp;
liblist.l_name = BYTE_GET (elib[cnt].l_name);
time = BYTE_GET (elib[cnt].l_time_stamp);
@@ -9176,7 +9515,7 @@ process_mips_specific (file)
{
static const struct
{
- const char * name;
+ const char *name;
int bit;
}
l_flags_vals[] =
@@ -9212,23 +9551,22 @@ process_mips_specific (file)
if (options_offset != 0)
{
- Elf_External_Options * eopt;
- Elf_Internal_Shdr * sect = section_headers;
- Elf_Internal_Options * iopt;
- Elf_Internal_Options * option;
+ Elf_External_Options *eopt;
+ Elf_Internal_Shdr *sect = section_headers;
+ Elf_Internal_Options *iopt;
+ Elf_Internal_Options *option;
size_t offset;
int cnt;
/* Find the section header so that we get the size. */
while (sect->sh_type != SHT_MIPS_OPTIONS)
- ++ sect;
+ ++sect;
- eopt = (Elf_External_Options *) get_data (NULL, file, options_offset,
- sect->sh_size, _("options"));
+ eopt = get_data (NULL, file, options_offset, sect->sh_size,
+ _("options"));
if (eopt)
{
- iopt = ((Elf_Internal_Options *)
- malloc ((sect->sh_size / sizeof (eopt)) * sizeof (* iopt)));
+ iopt = malloc ((sect->sh_size / sizeof (eopt)) * sizeof (*iopt));
if (iopt == NULL)
{
error (_("Out of memory"));
@@ -9240,7 +9578,7 @@ process_mips_specific (file)
while (offset < sect->sh_size)
{
- Elf_External_Options * eoption;
+ Elf_External_Options *eoption;
eoption = (Elf_External_Options *) ((char *) eopt + offset);
@@ -9275,8 +9613,8 @@ process_mips_specific (file)
if (elf_header.e_machine == EM_MIPS)
{
/* 32bit form. */
- Elf32_External_RegInfo * ereg;
- Elf32_RegInfo reginfo;
+ Elf32_External_RegInfo *ereg;
+ Elf32_RegInfo reginfo;
ereg = (Elf32_External_RegInfo *) (option + 1);
reginfo.ri_gprmask = BYTE_GET (ereg->ri_gprmask);
@@ -9296,7 +9634,7 @@ process_mips_specific (file)
else
{
/* 64 bit form. */
- Elf64_External_RegInfo * ereg;
+ Elf64_External_RegInfo *ereg;
Elf64_Internal_RegInfo reginfo;
ereg = (Elf64_External_RegInfo *) (option + 1);
@@ -9393,7 +9731,7 @@ process_mips_specific (file)
break;
}
- len = sizeof (* eopt);
+ len = sizeof (*eopt);
while (len < option->size)
if (((char *) option)[len] >= ' '
&& ((char *) option)[len] < 0x7f)
@@ -9411,7 +9749,7 @@ process_mips_specific (file)
if (conflicts_offset != 0 && conflictsno != 0)
{
- Elf32_Conflict * iconf;
+ Elf32_Conflict *iconf;
size_t cnt;
if (dynamic_symbols == NULL)
@@ -9420,7 +9758,7 @@ process_mips_specific (file)
return 0;
}
- iconf = (Elf32_Conflict *) malloc (conflictsno * sizeof (* iconf));
+ iconf = malloc (conflictsno * sizeof (*iconf));
if (iconf == NULL)
{
error (_("Out of memory"));
@@ -9429,12 +9767,10 @@ process_mips_specific (file)
if (is_32bit_elf)
{
- Elf32_External_Conflict * econf32;
+ Elf32_External_Conflict *econf32;
- econf32 = ((Elf32_External_Conflict *)
- get_data (NULL, file, conflicts_offset,
- conflictsno * sizeof (* econf32),
- _("conflict")));
+ econf32 = get_data (NULL, file, conflicts_offset,
+ conflictsno * sizeof (*econf32), _("conflict"));
if (!econf32)
return 0;
@@ -9445,12 +9781,10 @@ process_mips_specific (file)
}
else
{
- Elf64_External_Conflict * econf64;
+ Elf64_External_Conflict *econf64;
- econf64 = ((Elf64_External_Conflict *)
- get_data (NULL, file, conflicts_offset,
- conflictsno * sizeof (* econf64),
- _("conflict")));
+ econf64 = get_data (NULL, file, conflicts_offset,
+ conflictsno * sizeof (*econf64), _("conflict"));
if (!econf64)
return 0;
@@ -9460,15 +9794,15 @@ process_mips_specific (file)
free (econf64);
}
- printf (_("\nSection '.conflict' contains %ld entries:\n"),
- (long) conflictsno);
+ printf (_("\nSection '.conflict' contains %lu entries:\n"),
+ (unsigned long) conflictsno);
puts (_(" Num: Index Value Name"));
for (cnt = 0; cnt < conflictsno; ++cnt)
{
- Elf_Internal_Sym * psym = & dynamic_symbols [iconf [cnt]];
+ Elf_Internal_Sym *psym = & dynamic_symbols[iconf[cnt]];
- printf ("%5lu: %8lu ", (unsigned long) cnt, iconf [cnt]);
+ printf ("%5lu: %8lu ", (unsigned long) cnt, iconf[cnt]);
print_vma (psym->st_value, FULL_HEX);
putchar (' ');
print_symbol (25, dynamic_strings + psym->st_name);
@@ -9482,12 +9816,11 @@ process_mips_specific (file)
}
static int
-process_gnu_liblist (file)
- FILE * file;
+process_gnu_liblist (FILE *file)
{
- Elf_Internal_Shdr * section, * string_sec;
- Elf32_External_Lib * elib;
- char * strtab;
+ Elf_Internal_Shdr *section, *string_sec;
+ Elf32_External_Lib *elib;
+ char *strtab;
size_t cnt;
unsigned i;
@@ -9496,22 +9829,20 @@ process_gnu_liblist (file)
for (i = 0, section = section_headers;
i < elf_header.e_shnum;
- i++, section ++)
+ i++, section++)
{
switch (section->sh_type)
{
case SHT_GNU_LIBLIST:
- elib = ((Elf32_External_Lib *)
- get_data (NULL, file, section->sh_offset, section->sh_size,
- _("liblist")));
+ elib = get_data (NULL, file, section->sh_offset, section->sh_size,
+ _("liblist"));
if (elib == NULL)
break;
string_sec = SECTION_HEADER (section->sh_link);
- strtab = (char *) get_data (NULL, file, string_sec->sh_offset,
- string_sec->sh_size,
- _("liblist string table"));
+ strtab = get_data (NULL, file, string_sec->sh_offset,
+ string_sec->sh_size, _("liblist string table"));
if (strtab == NULL
|| section->sh_entsize != sizeof (Elf32_External_Lib))
@@ -9532,7 +9863,7 @@ process_gnu_liblist (file)
Elf32_Lib liblist;
time_t time;
char timebuf[20];
- struct tm * tmp;
+ struct tm *tmp;
liblist.l_name = BYTE_GET (elib[cnt].l_name);
time = BYTE_GET (elib[cnt].l_time_stamp);
@@ -9562,18 +9893,18 @@ process_gnu_liblist (file)
}
static const char *
-get_note_type (e_type)
- unsigned e_type;
+get_note_type (unsigned e_type)
{
static char buff[64];
switch (e_type)
{
+ case NT_AUXV: return _("NT_AUXV (auxiliary vector)");
case NT_PRSTATUS: return _("NT_PRSTATUS (prstatus structure)");
case NT_FPREGSET: return _("NT_FPREGSET (floating point registers)");
- case NT_PRPSINFO: return _("NT_PRPSINFO (prpsinfo structure)");
- case NT_TASKSTRUCT: return _("NT_TASKSTRUCT (task structure)");
- case NT_PRXFPREG: return _("NT_PRXFPREG (user_xfpregs structure)");
+ case NT_PRPSINFO: return _("NT_PRPSINFO (prpsinfo structure)");
+ case NT_TASKSTRUCT: return _("NT_TASKSTRUCT (task structure)");
+ case NT_PRXFPREG: return _("NT_PRXFPREG (user_xfpregs structure)");
case NT_PSTATUS: return _("NT_PSTATUS (pstatus structure)");
case NT_FPREGS: return _("NT_FPREGS (floating point registers)");
case NT_PSINFO: return _("NT_PSINFO (psinfo structure)");
@@ -9587,8 +9918,7 @@ get_note_type (e_type)
}
static const char *
-get_netbsd_elfcore_note_type (e_type)
- unsigned e_type;
+get_netbsd_elfcore_note_type (unsigned e_type)
{
static char buff[64];
@@ -9654,8 +9984,7 @@ get_netbsd_elfcore_note_type (e_type)
If the value of namesz is zero, there is no name present. */
static int
-process_note (pnote)
- Elf32_Internal_Note * pnote;
+process_note (Elf_Internal_Note *pnote)
{
const char *nt;
@@ -9685,20 +10014,16 @@ process_note (pnote)
static int
-process_corefile_note_segment (file, offset, length)
- FILE * file;
- bfd_vma offset;
- bfd_vma length;
+process_corefile_note_segment (FILE *file, bfd_vma offset, bfd_vma length)
{
- Elf_External_Note * pnotes;
- Elf_External_Note * external;
- int res = 1;
+ Elf_External_Note *pnotes;
+ Elf_External_Note *external;
+ int res = 1;
if (length <= 0)
return 0;
- pnotes = (Elf_External_Note *) get_data (NULL, file, offset, length,
- _("notes"));
+ pnotes = get_data (NULL, file, offset, length, _("notes"));
if (!pnotes)
return 0;
@@ -9710,9 +10035,9 @@ process_corefile_note_segment (file, offset, length)
while (external < (Elf_External_Note *)((char *) pnotes + length))
{
- Elf_External_Note * next;
- Elf32_Internal_Note inote;
- char * temp = NULL;
+ Elf_External_Note *next;
+ Elf_Internal_Note inote;
+ char *temp = NULL;
inote.type = BYTE_GET (external->type);
inote.namesz = BYTE_GET (external->namesz);
@@ -9771,37 +10096,18 @@ process_corefile_note_segment (file, offset, length)
}
static int
-process_corefile_note_segments (file)
- FILE * file;
+process_corefile_note_segments (FILE *file)
{
- Elf_Internal_Phdr * program_headers;
- Elf_Internal_Phdr * segment;
- unsigned int i;
- int res = 1;
-
- program_headers = (Elf_Internal_Phdr *) malloc
- (elf_header.e_phnum * sizeof (Elf_Internal_Phdr));
-
- if (program_headers == NULL)
- {
- error (_("Out of memory\n"));
- return 0;
- }
-
- if (is_32bit_elf)
- i = get_32bit_program_headers (file, program_headers);
- else
- i = get_64bit_program_headers (file, program_headers);
+ Elf_Internal_Phdr *segment;
+ unsigned int i;
+ int res = 1;
- if (i == 0)
- {
- free (program_headers);
+ if (! get_program_headers (file))
return 0;
- }
for (i = 0, segment = program_headers;
i < elf_header.e_phnum;
- i ++, segment ++)
+ i++, segment++)
{
if (segment->p_type == PT_NOTE)
res &= process_corefile_note_segment (file,
@@ -9809,14 +10115,11 @@ process_corefile_note_segments (file)
(bfd_vma) segment->p_filesz);
}
- free (program_headers);
-
return res;
}
static int
-process_corefile_contents (file)
- FILE * file;
+process_corefile_contents (FILE *file)
{
/* If we have not been asked to display the notes then do nothing. */
if (! do_notes)
@@ -9837,8 +10140,7 @@ process_corefile_contents (file)
}
static int
-process_arch_specific (file)
- FILE * file;
+process_arch_specific (FILE *file)
{
if (! do_arch)
return 1;
@@ -9856,24 +10158,29 @@ process_arch_specific (file)
}
static int
-get_file_header (file)
- FILE * file;
+get_file_header (FILE *file)
{
/* Read in the identity array. */
if (fread (elf_header.e_ident, EI_NIDENT, 1, file) != 1)
return 0;
/* Determine how to read the rest of the header. */
- switch (elf_header.e_ident [EI_DATA])
+ switch (elf_header.e_ident[EI_DATA])
{
default: /* fall through */
case ELFDATANONE: /* fall through */
- case ELFDATA2LSB: byte_get = byte_get_little_endian; break;
- case ELFDATA2MSB: byte_get = byte_get_big_endian; break;
+ case ELFDATA2LSB:
+ byte_get = byte_get_little_endian;
+ byte_put = byte_put_little_endian;
+ break;
+ case ELFDATA2MSB:
+ byte_get = byte_get_big_endian;
+ byte_put = byte_put_big_endian;
+ break;
}
/* For now we only support 32 bit and 64 bit ELF files. */
- is_32bit_elf = (elf_header.e_ident [EI_CLASS] != ELFCLASS64);
+ is_32bit_elf = (elf_header.e_ident[EI_CLASS] != ELFCLASS64);
/* Read in the rest of the header. */
if (is_32bit_elf)
@@ -9904,7 +10211,7 @@ get_file_header (file)
/* If we have been compiled with sizeof (bfd_vma) == 4, then
we will not be able to cope with the 64bit data found in
64 ELF files. Detect this now and abort before we start
- overwritting things. */
+ overwriting things. */
if (sizeof (bfd_vma) < 8)
{
error (_("This instance of readelf has been built without support for a\n\
@@ -9943,31 +10250,18 @@ get_file_header (file)
return 1;
}
+/* Process one ELF object file according to the command line options.
+ This file may actually be stored in an archive. The file is
+ positioned at the start of the ELF object. */
+
static int
-process_file (file_name)
- char * file_name;
+process_object (char *file_name, FILE *file)
{
- FILE * file;
- struct stat statbuf;
unsigned int i;
- if (stat (file_name, & statbuf) < 0)
- {
- error (_("Cannot stat input file %s.\n"), file_name);
- return 1;
- }
-
- file = fopen (file_name, "rb");
- if (file == NULL)
- {
- error (_("Input file %s not found.\n"), file_name);
- return 1;
- }
-
if (! get_file_header (file))
{
error (_("%s: Failed to read file header\n"), file_name);
- fclose (file);
return 1;
}
@@ -9983,16 +10277,20 @@ process_file (file_name)
printf (_("\nFile: %s\n"), file_name);
if (! process_file_header ())
- {
- fclose (file);
- return 1;
- }
+ return 1;
- process_section_headers (file);
+ if (! process_section_headers (file))
+ {
+ /* Without loaded section headers we
+ cannot process lots of things. */
+ do_unwind = do_version = do_dump = do_arch = 0;
- process_program_headers (file);
+ if (! do_using_dynamic)
+ do_syms = do_reloc = 0;
+ }
- process_dynamic_segment (file);
+ if (process_program_headers (file))
+ process_dynamic_segment (file);
process_relocs (file);
@@ -10012,7 +10310,11 @@ process_file (file_name)
process_arch_specific (file);
- fclose (file);
+ if (program_headers)
+ {
+ free (program_headers);
+ program_headers = NULL;
+ }
if (section_headers)
{
@@ -10049,13 +10351,237 @@ process_file (file_name)
return 0;
}
+/* Process an ELF archive. The file is positioned just after the
+ ARMAG string. */
+
+static int
+process_archive (char *file_name, FILE *file)
+{
+ struct ar_hdr arhdr;
+ size_t got;
+ unsigned long size;
+ char *longnames = NULL;
+ unsigned long longnames_size = 0;
+ size_t file_name_size;
+ int ret;
+
+ show_name = 1;
+
+ got = fread (&arhdr, 1, sizeof arhdr, file);
+ if (got != sizeof arhdr)
+ {
+ if (got == 0)
+ return 0;
+
+ error (_("%s: failed to read archive header\n"), file_name);
+ return 1;
+ }
+
+ if (memcmp (arhdr.ar_name, "/ ", 16) == 0)
+ {
+ /* This is the archive symbol table. Skip it.
+ FIXME: We should have an option to dump it. */
+ size = strtoul (arhdr.ar_size, NULL, 10);
+ if (fseek (file, size + (size & 1), SEEK_CUR) != 0)
+ {
+ error (_("%s: failed to skip archive symbol table\n"), file_name);
+ return 1;
+ }
+
+ got = fread (&arhdr, 1, sizeof arhdr, file);
+ if (got != sizeof arhdr)
+ {
+ if (got == 0)
+ return 0;
+
+ error (_("%s: failed to read archive header\n"), file_name);
+ return 1;
+ }
+ }
+
+ if (memcmp (arhdr.ar_name, "// ", 16) == 0)
+ {
+ /* This is the archive string table holding long member
+ names. */
+
+ longnames_size = strtoul (arhdr.ar_size, NULL, 10);
+
+ longnames = malloc (longnames_size);
+ if (longnames == NULL)
+ {
+ error (_("Out of memory\n"));
+ return 1;
+ }
+
+ if (fread (longnames, longnames_size, 1, file) != 1)
+ {
+ free (longnames);
+ error(_("%s: failed to read string table\n"), file_name);
+ return 1;
+ }
+
+ if ((longnames_size & 1) != 0)
+ getc (file);
+
+ got = fread (&arhdr, 1, sizeof arhdr, file);
+ if (got != sizeof arhdr)
+ {
+ free (longnames);
+
+ if (got == 0)
+ return 0;
+
+ error (_("%s: failed to read archive header\n"), file_name);
+ return 1;
+ }
+ }
+
+ file_name_size = strlen (file_name);
+ ret = 0;
+
+ while (1)
+ {
+ char *name;
+ char *nameend;
+ char *namealc;
+
+ if (arhdr.ar_name[0] == '/')
+ {
+ unsigned long off;
+
+ off = strtoul (arhdr.ar_name + 1, NULL, 10);
+ if (off >= longnames_size)
+ {
+ error (_("%s: invalid archive string table offset %lu\n"), off);
+ ret = 1;
+ break;
+ }
+
+ name = longnames + off;
+ nameend = memchr (name, '/', longnames_size - off);
+ }
+ else
+ {
+ name = arhdr.ar_name;
+ nameend = memchr (name, '/', 16);
+ }
+
+ if (nameend == NULL)
+ {
+ error (_("%s: bad archive file name\n"));
+ ret = 1;
+ break;
+ }
+
+ namealc = malloc (file_name_size + (nameend - name) + 3);
+ if (namealc == NULL)
+ {
+ error (_("Out of memory\n"));
+ ret = 1;
+ break;
+ }
+
+ memcpy (namealc, file_name, file_name_size);
+ namealc[file_name_size] = '(';
+ memcpy (namealc + file_name_size + 1, name, nameend - name);
+ namealc[file_name_size + 1 + (nameend - name)] = ')';
+ namealc[file_name_size + 2 + (nameend - name)] = '\0';
+
+ archive_file_offset = ftell (file);
+ archive_file_size = strtoul (arhdr.ar_size, NULL, 10);
+
+ ret |= process_object (namealc, file);
+
+ free (namealc);
+
+ if (fseek (file,
+ (archive_file_offset
+ + archive_file_size
+ + (archive_file_size & 1)),
+ SEEK_SET) != 0)
+ {
+ error (_("%s: failed to seek to next archive header\n"), file_name);
+ ret = 1;
+ break;
+ }
+
+ got = fread (&arhdr, 1, sizeof arhdr, file);
+ if (got != sizeof arhdr)
+ {
+ if (got == 0)
+ break;
+
+ error (_("%s: failed to read archive header\n"), file_name);
+ ret = 1;
+ break;
+ }
+ }
+
+ if (longnames != 0)
+ free (longnames);
+
+ return ret;
+}
+
+static int
+process_file (char *file_name)
+{
+ FILE *file;
+ struct stat statbuf;
+ char armag[SARMAG];
+ int ret;
+
+ if (stat (file_name, &statbuf) < 0)
+ {
+ if (errno == ENOENT)
+ error (_("'%s': No such file\n"), file_name);
+ else
+ error (_("Could not locate '%s'. System error message: %s\n"),
+ file_name, strerror (errno));
+ return 1;
+ }
+
+ if (! S_ISREG (statbuf.st_mode))
+ {
+ error (_("'%s' is not an ordinary file\n"), file_name);
+ return 1;
+ }
+
+ file = fopen (file_name, "rb");
+ if (file == NULL)
+ {
+ error (_("Input file '%s' is not readable.\n"), file_name);
+ return 1;
+ }
+
+ if (fread (armag, SARMAG, 1, file) != 1)
+ {
+ error (_("%s: Failed to read file header\n"), file_name);
+ fclose (file);
+ return 1;
+ }
+
+ if (memcmp (armag, ARMAG, SARMAG) == 0)
+ ret = process_archive (file_name, file);
+ else
+ {
+ rewind (file);
+ archive_file_size = archive_file_offset = 0;
+ ret = process_object (file_name, file);
+ }
+
+ fclose (file);
+
+ return ret;
+}
+
#ifdef SUPPORT_DISASSEMBLY
/* Needed by the i386 disassembler. For extra credit, someone could
fix this so that we insert symbolic addresses here, esp for GOT/PLT
symbols. */
void
-print_address (unsigned int addr, FILE * outfile)
+print_address (unsigned int addr, FILE *outfile)
{
fprintf (outfile,"0x%8.8x", addr);
}
@@ -10068,14 +10594,12 @@ db_task_printsym (unsigned int addr)
}
#endif
-int main PARAMS ((int, char **));
-
int
-main (argc, argv)
- int argc;
- char ** argv;
+main (int argc, char **argv)
{
int err;
+ char *cmdline_dump_sects = NULL;
+ unsigned num_cmdline_dump_sects = 0;
#if defined (HAVE_SETLOCALE) && defined (HAVE_LC_MESSAGES)
setlocale (LC_MESSAGES, "");
@@ -10091,12 +10615,38 @@ main (argc, argv)
if (optind < (argc - 1))
show_name = 1;
+ /* When processing more than one file remember the dump requests
+ issued on command line to reset them after each file. */
+ if (optind + 1 < argc && dump_sects != NULL)
+ {
+ cmdline_dump_sects = malloc (num_dump_sects);
+ if (cmdline_dump_sects == NULL)
+ error (_("Out of memory allocating dump request table."));
+ else
+ {
+ memcpy (cmdline_dump_sects, dump_sects, num_dump_sects);
+ num_cmdline_dump_sects = num_dump_sects;
+ }
+ }
+
err = 0;
while (optind < argc)
- err |= process_file (argv [optind ++]);
+ {
+ err |= process_file (argv[optind++]);
+
+ /* Reset dump requests. */
+ if (optind < argc && dump_sects != NULL)
+ {
+ num_dump_sects = num_cmdline_dump_sects;
+ if (num_cmdline_dump_sects > 0)
+ memcpy (dump_sects, cmdline_dump_sects, num_cmdline_dump_sects);
+ }
+ }
if (dump_sects != NULL)
free (dump_sects);
+ if (cmdline_dump_sects != NULL)
+ free (cmdline_dump_sects);
return err;
}
diff --git a/contrib/binutils/binutils/rename.c b/contrib/binutils/binutils/rename.c
index 1a6a86b..398152e 100644
--- a/contrib/binutils/binutils/rename.c
+++ b/contrib/binutils/binutils/rename.c
@@ -1,5 +1,5 @@
/* rename.c -- rename a file, preserving symlinks.
- Copyright 1999 Free Software Foundation, Inc.
+ Copyright 1999, 2002, 2003 Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -37,7 +37,7 @@
#define O_BINARY 0
#endif
-static int simple_copy PARAMS ((const char *, const char *));
+static int simple_copy (const char *, const char *);
/* The number of bytes to copy at once. */
#define COPY_BUF 8192
@@ -46,9 +46,7 @@ static int simple_copy PARAMS ((const char *, const char *));
Return 0 if ok, -1 if error. */
static int
-simple_copy (from, to)
- const char *from;
- const char *to;
+simple_copy (const char *from, const char *to)
{
int fromfd, tofd, nread;
int saved;
@@ -95,9 +93,7 @@ simple_copy (from, to)
STATBUF. */
void
-set_times (destination, statbuf)
- const char *destination;
- const struct stat *statbuf;
+set_times (const char *destination, const struct stat *statbuf)
{
int result;
@@ -144,12 +140,9 @@ set_times (destination, statbuf)
Return 0 if ok, -1 if error. */
int
-smart_rename (from, to, preserve_dates)
- const char *from;
- const char *to;
- int preserve_dates;
+smart_rename (const char *from, const char *to, int preserve_dates)
{
- boolean exists;
+ bfd_boolean exists;
struct stat s;
int ret = 0;
@@ -166,14 +159,18 @@ smart_rename (from, to, preserve_dates)
if (ret != 0)
{
/* We have to clean up here. */
-
- non_fatal (_("%s: rename: %s"), to, strerror (errno));
+ non_fatal (_("unable to rename '%s' reason: %s"), to, strerror (errno));
unlink (from);
}
#else
/* Use rename only if TO is not a symbolic link and has
- only one hard link. */
- if (! exists || (!S_ISLNK (s.st_mode) && s.st_nlink == 1))
+ only one hard link, and we have permission to write to it. */
+ if (! exists
+ || (!S_ISLNK (s.st_mode)
+ && S_ISREG (s.st_mode)
+ && (s.st_mode & S_IWUSR)
+ && s.st_nlink == 1)
+ )
{
ret = rename (from, to);
if (ret == 0)
@@ -200,7 +197,7 @@ smart_rename (from, to, preserve_dates)
else
{
/* We have to clean up here. */
- non_fatal (_("%s: rename: %s"), to, strerror (errno));
+ non_fatal (_("unable to rename '%s' reason: %s"), to, strerror (errno));
unlink (from);
}
}
@@ -208,7 +205,7 @@ smart_rename (from, to, preserve_dates)
{
ret = simple_copy (from, to);
if (ret != 0)
- non_fatal (_("%s: simple_copy: %s"), to, strerror (errno));
+ non_fatal (_("unable to copy file '%s' reason: %s"), to, strerror (errno));
if (preserve_dates)
set_times (to, &s);
diff --git a/contrib/binutils/binutils/resbin.c b/contrib/binutils/binutils/resbin.c
index 079818c..ad14bda 100644
--- a/contrib/binutils/binutils/resbin.c
+++ b/contrib/binutils/binutils/resbin.c
@@ -1,5 +1,6 @@
/* resbin.c -- manipulate the Windows binary resource format.
- Copyright 1997, 1998, 1999, 2002 Free Software Foundation, Inc.
+ Copyright 1997, 1998, 1999, 2002, 2003
+ Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support.
This file is part of GNU Binutils.
@@ -36,42 +37,43 @@
/* Local functions. */
-static void toosmall PARAMS ((const char *));
+static void toosmall (const char *);
+
static unichar *get_unicode
- PARAMS ((const unsigned char *, unsigned long, int, int *));
+ (const unsigned char *, unsigned long, int, int *);
static int get_resid
- PARAMS ((struct res_id *, const unsigned char *, unsigned long, int));
+ (struct res_id *, const unsigned char *, unsigned long, int);
static struct res_resource *bin_to_res_generic
- PARAMS ((enum res_type, const unsigned char *, unsigned long));
+ (enum res_type, const unsigned char *, unsigned long);
static struct res_resource *bin_to_res_cursor
- PARAMS ((const unsigned char *, unsigned long, int));
+ (const unsigned char *, unsigned long, int);
static struct res_resource *bin_to_res_menu
- PARAMS ((const unsigned char *, unsigned long, int));
+ (const unsigned char *, unsigned long, int);
static struct menuitem *bin_to_res_menuitems
- PARAMS ((const unsigned char *, unsigned long, int, int *));
+ (const unsigned char *, unsigned long, int, int *);
static struct menuitem *bin_to_res_menuexitems
- PARAMS ((const unsigned char *, unsigned long, int, int *));
+ (const unsigned char *, unsigned long, int, int *);
static struct res_resource *bin_to_res_dialog
- PARAMS ((const unsigned char *, unsigned long, int));
+ (const unsigned char *, unsigned long, int);
static struct res_resource *bin_to_res_string
- PARAMS ((const unsigned char *, unsigned long, int));
+ (const unsigned char *, unsigned long, int);
static struct res_resource *bin_to_res_fontdir
- PARAMS ((const unsigned char *, unsigned long, int));
+ (const unsigned char *, unsigned long, int);
static struct res_resource *bin_to_res_accelerators
- PARAMS ((const unsigned char *, unsigned long, int));
+ (const unsigned char *, unsigned long, int);
static struct res_resource *bin_to_res_rcdata
- PARAMS ((const unsigned char *, unsigned long, int));
+ (const unsigned char *, unsigned long, int);
static struct res_resource *bin_to_res_group_cursor
- PARAMS ((const unsigned char *, unsigned long, int));
+ (const unsigned char *, unsigned long, int);
static struct res_resource *bin_to_res_group_icon
- PARAMS ((const unsigned char *, unsigned long, int));
+ (const unsigned char *, unsigned long, int);
static struct res_resource *bin_to_res_version
- PARAMS ((const unsigned char *, unsigned long, int));
+ (const unsigned char *, unsigned long, int);
static struct res_resource *bin_to_res_userdata
- PARAMS ((const unsigned char *, unsigned long, int));
+ (const unsigned char *, unsigned long, int);
static void get_version_header
- PARAMS ((const unsigned char *, unsigned long, int, const char *,
- unichar **, int *, int *, int *, int *));
+ (const unsigned char *, unsigned long, int, const char *,
+ unichar **, int *, int *, int *, int *);
/* Given a resource type ID, a pointer to data, a length, return a
res_resource structure which represents that resource. The caller
@@ -79,11 +81,8 @@ static void get_version_header
of the returned structure. */
struct res_resource *
-bin_to_res (type, data, length, big_endian)
- struct res_id type;
- const unsigned char *data;
- unsigned long length;
- int big_endian;
+bin_to_res (struct res_id type, const unsigned char *data,
+ unsigned long length, int big_endian)
{
if (type.named)
return bin_to_res_userdata (data, length, big_endian);
@@ -128,8 +127,7 @@ bin_to_res (type, data, length, big_endian)
/* Give an error if the binary data is too small. */
static void
-toosmall (msg)
- const char *msg;
+toosmall (const char *msg)
{
fatal (_("%s: not enough binary data"), msg);
}
@@ -137,11 +135,8 @@ toosmall (msg)
/* Swap in a NULL terminated unicode string. */
static unichar *
-get_unicode (data, length, big_endian, retlen)
- const unsigned char *data;
- unsigned long length;
- int big_endian;
- int *retlen;
+get_unicode (const unsigned char *data, unsigned long length,
+ int big_endian, int *retlen)
{
int c, i;
unichar *ret;
@@ -171,11 +166,8 @@ get_unicode (data, length, big_endian, retlen)
/* Get a resource identifier. This returns the number of bytes used. */
static int
-get_resid (id, data, length, big_endian)
- struct res_id *id;
- const unsigned char *data;
- unsigned long length;
- int big_endian;
+get_resid (struct res_id *id, const unsigned char *data,
+ unsigned long length, int big_endian)
{
int first;
@@ -203,10 +195,8 @@ get_resid (id, data, length, big_endian)
binary. */
struct res_resource *
-bin_to_res_generic (type, data, length)
- enum res_type type;
- const unsigned char *data;
- unsigned long length;
+bin_to_res_generic (enum res_type type, const unsigned char *data,
+ unsigned long length)
{
struct res_resource *r;
@@ -221,10 +211,8 @@ bin_to_res_generic (type, data, length)
/* Convert a cursor resource from binary. */
struct res_resource *
-bin_to_res_cursor (data, length, big_endian)
- const unsigned char *data;
- unsigned long length;
- int big_endian;
+bin_to_res_cursor (const unsigned char *data, unsigned long length,
+ int big_endian)
{
struct cursor *c;
struct res_resource *r;
@@ -248,10 +236,8 @@ bin_to_res_cursor (data, length, big_endian)
/* Convert a menu resource from binary. */
struct res_resource *
-bin_to_res_menu (data, length, big_endian)
- const unsigned char *data;
- unsigned long length;
- int big_endian;
+bin_to_res_menu (const unsigned char *data, unsigned long length,
+ int big_endian)
{
struct res_resource *r;
struct menu *m;
@@ -300,11 +286,8 @@ bin_to_res_menu (data, length, big_endian)
/* Convert menu items from binary. */
static struct menuitem *
-bin_to_res_menuitems (data, length, big_endian, read)
- const unsigned char *data;
- unsigned long length;
- int big_endian;
- int *read;
+bin_to_res_menuitems (const unsigned char *data, unsigned long length,
+ int big_endian, int *read)
{
struct menuitem *first, **pp;
@@ -381,11 +364,8 @@ bin_to_res_menuitems (data, length, big_endian, read)
/* Convert menuex items from binary. */
static struct menuitem *
-bin_to_res_menuexitems (data, length, big_endian, read)
- const unsigned char *data;
- unsigned long length;
- int big_endian;
- int *read;
+bin_to_res_menuexitems (const unsigned char *data, unsigned long length,
+ int big_endian, int *read)
{
struct menuitem *first, **pp;
@@ -459,10 +439,8 @@ bin_to_res_menuexitems (data, length, big_endian, read)
/* Convert a dialog resource from binary. */
static struct res_resource *
-bin_to_res_dialog (data, length, big_endian)
- const unsigned char *data;
- unsigned long length;
- int big_endian;
+bin_to_res_dialog (const unsigned char *data, unsigned long length,
+ int big_endian)
{
int signature;
struct dialog *d;
@@ -647,10 +625,8 @@ bin_to_res_dialog (data, length, big_endian)
/* Convert a stringtable resource from binary. */
static struct res_resource *
-bin_to_res_string (data, length, big_endian)
- const unsigned char *data;
- unsigned long length;
- int big_endian;
+bin_to_res_string (const unsigned char *data, unsigned long length,
+ int big_endian)
{
struct stringtable *st;
int i;
@@ -696,10 +672,8 @@ bin_to_res_string (data, length, big_endian)
/* Convert a fontdir resource from binary. */
static struct res_resource *
-bin_to_res_fontdir (data, length, big_endian)
- const unsigned char *data;
- unsigned long length;
- int big_endian;
+bin_to_res_fontdir (const unsigned char *data, unsigned long length,
+ int big_endian)
{
int c, i;
struct fontdir *first, **pp;
@@ -768,10 +742,8 @@ bin_to_res_fontdir (data, length, big_endian)
/* Convert an accelerators resource from binary. */
static struct res_resource *
-bin_to_res_accelerators (data, length, big_endian)
- const unsigned char *data;
- unsigned long length;
- int big_endian;
+bin_to_res_accelerators (const unsigned char *data, unsigned long length,
+ int big_endian)
{
struct accelerator *first, **pp;
struct res_resource *r;
@@ -813,10 +785,8 @@ bin_to_res_accelerators (data, length, big_endian)
/* Convert an rcdata resource from binary. */
static struct res_resource *
-bin_to_res_rcdata (data, length, big_endian)
- const unsigned char *data;
- unsigned long length;
- int big_endian ATTRIBUTE_UNUSED;
+bin_to_res_rcdata (const unsigned char *data, unsigned long length,
+ int big_endian ATTRIBUTE_UNUSED)
{
struct rcdata_item *ri;
struct res_resource *r;
@@ -838,10 +808,8 @@ bin_to_res_rcdata (data, length, big_endian)
/* Convert a group cursor resource from binary. */
static struct res_resource *
-bin_to_res_group_cursor (data, length, big_endian)
- const unsigned char *data;
- unsigned long length;
- int big_endian;
+bin_to_res_group_cursor (const unsigned char *data, unsigned long length,
+ int big_endian)
{
int type, c, i;
struct group_cursor *first, **pp;
@@ -896,10 +864,8 @@ bin_to_res_group_cursor (data, length, big_endian)
/* Convert a group icon resource from binary. */
static struct res_resource *
-bin_to_res_group_icon (data, length, big_endian)
- const unsigned char *data;
- unsigned long length;
- int big_endian;
+bin_to_res_group_icon (const unsigned char *data, unsigned long length,
+ int big_endian)
{
int type, c, i;
struct group_icon *first, **pp;
@@ -958,17 +924,9 @@ bin_to_res_group_icon (data, length, big_endian)
to the type, and *OFF to the offset to the children. */
static void
-get_version_header (data, length, big_endian, key, pkey, len, vallen, type,
- off)
- const unsigned char *data;
- unsigned long length;
- int big_endian;
- const char *key;
- unichar **pkey;
- int *len;
- int *vallen;
- int *type;
- int *off;
+get_version_header (const unsigned char *data, unsigned long length,
+ int big_endian, const char *key, unichar **pkey,
+ int *len, int *vallen, int *type, int *off)
{
if (length < 8)
toosmall (key);
@@ -1015,10 +973,8 @@ get_version_header (data, length, big_endian, key, pkey, len, vallen, type,
/* Convert a version resource from binary. */
static struct res_resource *
-bin_to_res_version (data, length, big_endian)
- const unsigned char *data;
- unsigned long length;
- int big_endian;
+bin_to_res_version (const unsigned char *data, unsigned long length,
+ int big_endian)
{
int verlen, vallen, type, off;
struct fixed_versioninfo *fi;
@@ -1236,10 +1192,8 @@ bin_to_res_version (data, length, big_endian)
/* Convert an arbitrary user defined resource from binary. */
static struct res_resource *
-bin_to_res_userdata (data, length, big_endian)
- const unsigned char *data;
- unsigned long length;
- int big_endian ATTRIBUTE_UNUSED;
+bin_to_res_userdata (const unsigned char *data, unsigned long length,
+ int big_endian ATTRIBUTE_UNUSED)
{
struct rcdata_item *ri;
struct res_resource *r;
@@ -1266,43 +1220,41 @@ bin_to_res_userdata (data, length, big_endian)
/* Local functions used to convert resources to binary format. */
-static void dword_align_bin PARAMS ((struct bindata ***, unsigned long *));
-static struct bindata *resid_to_bin PARAMS ((struct res_id, int));
-static struct bindata *unicode_to_bin PARAMS ((const unichar *, int));
+static void dword_align_bin (struct bindata ***, unsigned long *);
+static struct bindata *resid_to_bin (struct res_id, int);
+static struct bindata *unicode_to_bin (const unichar *, int);
static struct bindata *res_to_bin_accelerator
- PARAMS ((const struct accelerator *, int));
+ (const struct accelerator *, int);
static struct bindata *res_to_bin_cursor
- PARAMS ((const struct cursor *, int));
+ (const struct cursor *, int);
static struct bindata *res_to_bin_group_cursor
- PARAMS ((const struct group_cursor *, int));
+ (const struct group_cursor *, int);
static struct bindata *res_to_bin_dialog
- PARAMS ((const struct dialog *, int));
+ (const struct dialog *, int);
static struct bindata *res_to_bin_fontdir
- PARAMS ((const struct fontdir *, int));
+ (const struct fontdir *, int);
static struct bindata *res_to_bin_group_icon
- PARAMS ((const struct group_icon *, int));
+ (const struct group_icon *, int);
static struct bindata *res_to_bin_menu
- PARAMS ((const struct menu *, int));
+ (const struct menu *, int);
static struct bindata *res_to_bin_menuitems
- PARAMS ((const struct menuitem *, int));
+ (const struct menuitem *, int);
static struct bindata *res_to_bin_menuexitems
- PARAMS ((const struct menuitem *, int));
+ (const struct menuitem *, int);
static struct bindata *res_to_bin_rcdata
- PARAMS ((const struct rcdata_item *, int));
+ (const struct rcdata_item *, int);
static struct bindata *res_to_bin_stringtable
- PARAMS ((const struct stringtable *, int));
-static struct bindata *string_to_unicode_bin PARAMS ((const char *, int));
+ (const struct stringtable *, int);
+static struct bindata *string_to_unicode_bin (const char *, int);
static struct bindata *res_to_bin_versioninfo
- PARAMS ((const struct versioninfo *, int));
+ (const struct versioninfo *, int);
static struct bindata *res_to_bin_generic
- PARAMS ((unsigned long, const unsigned char *));
+ (unsigned long, const unsigned char *);
/* Convert a resource to binary. */
struct bindata *
-res_to_bin (res, big_endian)
- const struct res_resource *res;
- int big_endian;
+res_to_bin (const struct res_resource *res, int big_endian)
{
switch (res->type)
{
@@ -1344,9 +1296,7 @@ res_to_bin (res, big_endian)
boundary. It updates *PPP and *LENGTH. */
static void
-dword_align_bin (ppp, length)
- struct bindata ***ppp;
- unsigned long *length;
+dword_align_bin (struct bindata ***ppp, unsigned long *length)
{
int add;
struct bindata *d;
@@ -1372,9 +1322,7 @@ dword_align_bin (ppp, length)
bindata structure. */
static struct bindata *
-resid_to_bin (id, big_endian)
- struct res_id id;
- int big_endian;
+resid_to_bin (struct res_id id, int big_endian)
{
struct bindata *d;
@@ -1407,9 +1355,7 @@ resid_to_bin (id, big_endian)
returns exactly one bindata structure. */
static struct bindata *
-unicode_to_bin (str, big_endian)
- const unichar *str;
- int big_endian;
+unicode_to_bin (const unichar *str, int big_endian)
{
int len;
struct bindata *d;
@@ -1447,9 +1393,8 @@ unicode_to_bin (str, big_endian)
/* Convert an accelerator resource to binary. */
static struct bindata *
-res_to_bin_accelerator (accelerators, big_endian)
- const struct accelerator *accelerators;
- int big_endian;
+res_to_bin_accelerator (const struct accelerator *accelerators,
+ int big_endian)
{
struct bindata *first, **pp;
const struct accelerator *a;
@@ -1483,9 +1428,7 @@ res_to_bin_accelerator (accelerators, big_endian)
/* Convert a cursor resource to binary. */
static struct bindata *
-res_to_bin_cursor (c, big_endian)
- const struct cursor *c;
- int big_endian;
+res_to_bin_cursor (const struct cursor *c, int big_endian)
{
struct bindata *d;
@@ -1507,9 +1450,8 @@ res_to_bin_cursor (c, big_endian)
/* Convert a group cursor resource to binary. */
static struct bindata *
-res_to_bin_group_cursor (group_cursors, big_endian)
- const struct group_cursor *group_cursors;
- int big_endian;
+res_to_bin_group_cursor (const struct group_cursor *group_cursors,
+ int big_endian)
{
struct bindata *first, **pp;
int c;
@@ -1556,9 +1498,7 @@ res_to_bin_group_cursor (group_cursors, big_endian)
/* Convert a dialog resource to binary. */
static struct bindata *
-res_to_bin_dialog (dialog, big_endian)
- const struct dialog *dialog;
- int big_endian;
+res_to_bin_dialog (const struct dialog *dialog, int big_endian)
{
int dialogex;
struct bindata *first, **pp;
@@ -1739,9 +1679,7 @@ res_to_bin_dialog (dialog, big_endian)
/* Convert a fontdir resource to binary. */
static struct bindata *
-res_to_bin_fontdir (fontdirs, big_endian)
- const struct fontdir *fontdirs;
- int big_endian;
+res_to_bin_fontdir (const struct fontdir *fontdirs, int big_endian)
{
struct bindata *first, **pp;
int c;
@@ -1787,9 +1725,7 @@ res_to_bin_fontdir (fontdirs, big_endian)
/* Convert a group icon resource to binary. */
static struct bindata *
-res_to_bin_group_icon (group_icons, big_endian)
- const struct group_icon *group_icons;
- int big_endian;
+res_to_bin_group_icon (const struct group_icon *group_icons, int big_endian)
{
struct bindata *first, **pp;
int c;
@@ -1838,9 +1774,7 @@ res_to_bin_group_icon (group_icons, big_endian)
/* Convert a menu resource to binary. */
static struct bindata *
-res_to_bin_menu (menu, big_endian)
- const struct menu *menu;
- int big_endian;
+res_to_bin_menu (const struct menu *menu, int big_endian)
{
int menuex;
struct bindata *d;
@@ -1873,9 +1807,7 @@ res_to_bin_menu (menu, big_endian)
/* Convert menu items to binary. */
static struct bindata *
-res_to_bin_menuitems (items, big_endian)
- const struct menuitem *items;
- int big_endian;
+res_to_bin_menuitems (const struct menuitem *items, int big_endian)
{
struct bindata *first, **pp;
const struct menuitem *mi;
@@ -1923,9 +1855,7 @@ res_to_bin_menuitems (items, big_endian)
/* Convert menuex items to binary. */
static struct bindata *
-res_to_bin_menuexitems (items, big_endian)
- const struct menuitem *items;
- int big_endian;
+res_to_bin_menuexitems (const struct menuitem *items, int big_endian)
{
struct bindata *first, **pp;
unsigned long length;
@@ -1997,9 +1927,7 @@ res_to_bin_menuexitems (items, big_endian)
to binary. */
static struct bindata *
-res_to_bin_rcdata (items, big_endian)
- const struct rcdata_item *items;
- int big_endian;
+res_to_bin_rcdata (const struct rcdata_item *items, int big_endian)
{
struct bindata *first, **pp;
const struct rcdata_item *ri;
@@ -2063,9 +1991,7 @@ res_to_bin_rcdata (items, big_endian)
/* Convert a stringtable resource to binary. */
static struct bindata *
-res_to_bin_stringtable (st, big_endian)
- const struct stringtable *st;
- int big_endian;
+res_to_bin_stringtable (const struct stringtable *st, int big_endian)
{
struct bindata *first, **pp;
int i;
@@ -2103,9 +2029,7 @@ res_to_bin_stringtable (st, big_endian)
returns exactly one bindata structure. */
static struct bindata *
-string_to_unicode_bin (s, big_endian)
- const char *s;
- int big_endian;
+string_to_unicode_bin (const char *s, int big_endian)
{
size_t len, i;
struct bindata *d;
@@ -2128,9 +2052,7 @@ string_to_unicode_bin (s, big_endian)
/* Convert a versioninfo resource to binary. */
static struct bindata *
-res_to_bin_versioninfo (versioninfo, big_endian)
- const struct versioninfo *versioninfo;
- int big_endian;
+res_to_bin_versioninfo (const struct versioninfo *versioninfo, int big_endian)
{
struct bindata *first, **pp;
unsigned long length;
@@ -2382,9 +2304,7 @@ res_to_bin_versioninfo (versioninfo, big_endian)
/* Convert a generic resource to binary. */
static struct bindata *
-res_to_bin_generic (length, data)
- unsigned long length;
- const unsigned char *data;
+res_to_bin_generic (unsigned long length, const unsigned char *data)
{
struct bindata *d;
diff --git a/contrib/binutils/binutils/rescoff.c b/contrib/binutils/binutils/rescoff.c
index e24402b..60122de 100644
--- a/contrib/binutils/binutils/rescoff.c
+++ b/contrib/binutils/binutils/rescoff.c
@@ -1,5 +1,6 @@
/* rescoff.c -- read and write resources in Windows COFF files.
- Copyright 1997, 1998, 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1997, 1998, 1999, 2000, 2003
+ Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support.
This file is part of GNU Binutils.
@@ -102,20 +103,17 @@ struct extern_res_data
/* Local functions. */
-static void overrun PARAMS ((const struct coff_file_info *, const char *));
+static void overrun (const struct coff_file_info *, const char *);
static struct res_directory *read_coff_res_dir
- PARAMS ((const bfd_byte *, const struct coff_file_info *,
- const struct res_id *, int));
+ (const bfd_byte *, const struct coff_file_info *,
+ const struct res_id *, int);
static struct res_resource *read_coff_data_entry
- PARAMS ((const bfd_byte *, const struct coff_file_info *,
- const struct res_id *));
+ (const bfd_byte *, const struct coff_file_info *, const struct res_id *);
/* Read the resources in a COFF file. */
struct res_directory *
-read_coff_rsrc (filename, target)
- const char *filename;
- const char *target;
+read_coff_rsrc (const char *filename, const char *target)
{
bfd *abfd;
char **matching;
@@ -171,9 +169,7 @@ read_coff_rsrc (filename, target)
/* Give an error if we are out of bounds. */
static void
-overrun (finfo, msg)
- const struct coff_file_info *finfo;
- const char *msg;
+overrun (const struct coff_file_info *finfo, const char *msg)
{
fatal (_("%s: %s: address out of bounds"), finfo->filename, msg);
}
@@ -181,11 +177,8 @@ overrun (finfo, msg)
/* Read a resource directory. */
static struct res_directory *
-read_coff_res_dir (data, finfo, type, level)
- const bfd_byte *data;
- const struct coff_file_info *finfo;
- const struct res_id *type;
- int level;
+read_coff_res_dir (const bfd_byte *data, const struct coff_file_info *finfo,
+ const struct res_id *type, int level)
{
const struct extern_res_directory *erd;
struct res_directory *rd;
@@ -314,10 +307,7 @@ read_coff_res_dir (data, finfo, type, level)
/* Read a resource data entry. */
static struct res_resource *
-read_coff_data_entry (data, finfo, type)
- const bfd_byte *data;
- const struct coff_file_info *finfo;
- const struct res_id *type;
+read_coff_data_entry (const bfd_byte *data, const struct coff_file_info *finfo, const struct res_id *type)
{
const struct extern_res_data *erd;
struct res_resource *r;
@@ -408,12 +398,12 @@ struct coff_write_info
((cwi->big_endian) ? bfd_putb32 ((v), (s)) : bfd_putl32 ((v), (s)))
static void coff_bin_sizes
- PARAMS ((const struct res_directory *, struct coff_write_info *));
-static unsigned char *coff_alloc PARAMS ((struct bindata_build *, size_t));
+ (const struct res_directory *, struct coff_write_info *);
+static unsigned char *coff_alloc (struct bindata_build *, size_t);
static void coff_to_bin
- PARAMS ((const struct res_directory *, struct coff_write_info *));
+ (const struct res_directory *, struct coff_write_info *);
static void coff_res_to_bin
- PARAMS ((const struct res_resource *, struct coff_write_info *));
+ (const struct res_resource *, struct coff_write_info *);
/* Write resources to a COFF file. RESOURCES should already be
sorted.
@@ -424,10 +414,8 @@ static void coff_res_to_bin
adding the .rsrc section. */
void
-write_coff_file (filename, target, resources)
- const char *filename;
- const char *target;
- const struct res_directory *resources;
+write_coff_file (const char *filename, const char *target,
+ const struct res_directory *resources)
{
bfd *abfd;
asection *sec;
@@ -584,9 +572,8 @@ write_coff_file (filename, target, resources)
entries. This updates fields in CWI. */
static void
-coff_bin_sizes (resdir, cwi)
- const struct res_directory *resdir;
- struct coff_write_info *cwi;
+coff_bin_sizes (const struct res_directory *resdir,
+ struct coff_write_info *cwi)
{
const struct res_entry *re;
@@ -609,9 +596,7 @@ coff_bin_sizes (resdir, cwi)
/* Allocate data for a particular list. */
static unsigned char *
-coff_alloc (bb, size)
- struct bindata_build *bb;
- size_t size;
+coff_alloc (struct bindata_build *bb, size_t size)
{
struct bindata *d;
@@ -634,9 +619,7 @@ coff_alloc (bb, size)
/* Convert the resource directory RESDIR to binary. */
static void
-coff_to_bin (resdir, cwi)
- const struct res_directory *resdir;
- struct coff_write_info *cwi;
+coff_to_bin (const struct res_directory *resdir, struct coff_write_info *cwi)
{
struct extern_res_directory *erd;
int ci, cn;
@@ -713,9 +696,7 @@ coff_to_bin (resdir, cwi)
/* Convert the resource RES to binary. */
static void
-coff_res_to_bin (res, cwi)
- const struct res_resource *res;
- struct coff_write_info *cwi;
+coff_res_to_bin (const struct res_resource *res, struct coff_write_info *cwi)
{
arelent *r;
struct extern_res_data *erd;
diff --git a/contrib/binutils/binutils/resrc.c b/contrib/binutils/binutils/resrc.c
index 3cf708a..c290a9d 100644
--- a/contrib/binutils/binutils/resrc.c
+++ b/contrib/binutils/binutils/resrc.c
@@ -1,5 +1,5 @@
/* resrc.c -- read and write Windows rc files.
- Copyright 1997, 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 1997, 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support.
This file is part of GNU Binutils.
@@ -161,24 +161,21 @@ static int icons;
/* Local functions. */
-static int run_cmd PARAMS ((char *, const char *));
-static FILE *open_input_stream PARAMS ((char *));
-static FILE *look_for_default PARAMS ((char *, const char *, int,
- const char *, const char *));
-static void close_input_stream PARAMS ((void));
-static void unexpected_eof PARAMS ((const char *));
-static int get_word PARAMS ((FILE *, const char *));
-static unsigned long get_long PARAMS ((FILE *, const char *));
-static void get_data
- PARAMS ((FILE *, unsigned char *, unsigned long, const char *));
-static void define_fontdirs PARAMS ((void));
+static int run_cmd (char *, const char *);
+static FILE *open_input_stream (char *);
+static FILE *look_for_default
+ (char *, const char *, int, const char *, const char *);
+static void close_input_stream (void);
+static void unexpected_eof (const char *);
+static int get_word (FILE *, const char *);
+static unsigned long get_long (FILE *, const char *);
+static void get_data (FILE *, unsigned char *, unsigned long, const char *);
+static void define_fontdirs (void);
/* Run `cmd' and redirect the output to `redir'. */
static int
-run_cmd (cmd, redir)
- char *cmd;
- const char *redir;
+run_cmd (char *cmd, const char *redir)
{
char *s;
int pid, wait_status, retcode;
@@ -254,7 +251,7 @@ run_cmd (cmd, redir)
/* Restore stdout to its previous setting. */
dup2 (stdout_save, STDOUT_FILENO);
- /* Close reponse file. */
+ /* Close response file. */
close (redir_handle);
if (pid == -1)
@@ -292,8 +289,7 @@ run_cmd (cmd, redir)
}
static FILE *
-open_input_stream (cmd)
- char *cmd;
+open_input_stream (char *cmd)
{
if (istream_type == ISTREAM_FILE)
{
@@ -333,12 +329,8 @@ open_input_stream (cmd)
/* look for the preprocessor program */
static FILE *
-look_for_default (cmd, prefix, end_prefix, preprocargs, filename)
- char *cmd;
- const char *prefix;
- int end_prefix;
- const char *preprocargs;
- const char *filename;
+look_for_default (char *cmd, const char *prefix, int end_prefix,
+ const char *preprocargs, const char *filename)
{
char *space;
int found;
@@ -386,12 +378,8 @@ look_for_default (cmd, prefix, end_prefix, preprocargs, filename)
/* Read an rc file. */
struct res_directory *
-read_rc_file (filename, preprocessor, preprocargs, language, use_temp_file)
- const char *filename;
- const char *preprocessor;
- const char *preprocargs;
- int language;
- int use_temp_file;
+read_rc_file (const char *filename, const char *preprocessor,
+ const char *preprocargs, int language, int use_temp_file)
{
char *cmd;
@@ -497,7 +485,7 @@ read_rc_file (filename, preprocessor, preprocargs, language, use_temp_file)
/* Close the input stream if it is open. */
static void
-close_input_stream ()
+close_input_stream (void)
{
if (istream_type == ISTREAM_FILE)
{
@@ -527,8 +515,7 @@ close_input_stream ()
/* Report an error while reading an rc file. */
void
-yyerror (msg)
- const char *msg;
+yyerror (const char *msg)
{
fatal ("%s:%d: %s", rc_filename, rc_lineno, msg);
}
@@ -536,8 +523,7 @@ yyerror (msg)
/* Issue a warning while reading an rc file. */
void
-rcparse_warning (msg)
- const char *msg;
+rcparse_warning (const char *msg)
{
fprintf (stderr, _("%s:%d: %s\n"), rc_filename, rc_lineno, msg);
}
@@ -545,8 +531,7 @@ rcparse_warning (msg)
/* Die if we get an unexpected end of file. */
static void
-unexpected_eof (msg)
- const char *msg;
+unexpected_eof (const char *msg)
{
fatal (_("%s: unexpected EOF"), msg);
}
@@ -555,9 +540,7 @@ unexpected_eof (msg)
endian. */
static int
-get_word (e, msg)
- FILE *e;
- const char *msg;
+get_word (FILE *e, const char *msg)
{
int b1, b2;
@@ -572,9 +555,7 @@ get_word (e, msg)
endian. */
static unsigned long
-get_long (e, msg)
- FILE *e;
- const char *msg;
+get_long (FILE *e, const char *msg)
{
int b1, b2, b3, b4;
@@ -593,11 +574,7 @@ get_long (e, msg)
/* Read data from a file. This is a wrapper to do error checking. */
static void
-get_data (e, p, c, msg)
- FILE *e;
- unsigned char *p;
- unsigned long c;
- const char *msg;
+get_data (FILE *e, unsigned char *p, unsigned long c, const char *msg)
{
unsigned long got;
@@ -611,10 +588,8 @@ get_data (e, p, c, msg)
/* Define an accelerator resource. */
void
-define_accelerator (id, resinfo, data)
- struct res_id id;
- const struct res_res_info *resinfo;
- struct accelerator *data;
+define_accelerator (struct res_id id, const struct res_res_info *resinfo,
+ struct accelerator *data)
{
struct res_resource *r;
@@ -632,10 +607,8 @@ define_accelerator (id, resinfo, data)
#define BITMAP_SKIP (14)
void
-define_bitmap (id, resinfo, filename)
- struct res_id id;
- const struct res_res_info *resinfo;
- const char *filename;
+define_bitmap (struct res_id id, const struct res_res_info *resinfo,
+ const char *filename)
{
FILE *e;
char *real_filename;
@@ -676,10 +649,8 @@ define_bitmap (id, resinfo, filename)
select one of the actual cursors. */
void
-define_cursor (id, resinfo, filename)
- struct res_id id;
- const struct res_res_info *resinfo;
- const char *filename;
+define_cursor (struct res_id id, const struct res_res_info *resinfo,
+ const char *filename)
{
FILE *e;
char *real_filename;
@@ -796,10 +767,8 @@ define_cursor (id, resinfo, filename)
/* Define a dialog resource. */
void
-define_dialog (id, resinfo, dialog)
- struct res_id id;
- const struct res_res_info *resinfo;
- const struct dialog *dialog;
+define_dialog (struct res_id id, const struct res_res_info *resinfo,
+ const struct dialog *dialog)
{
struct dialog *copy;
struct res_resource *r;
@@ -818,16 +787,10 @@ define_dialog (id, resinfo, dialog)
merely allocates and fills in a structure. */
struct dialog_control *
-define_control (text, id, x, y, width, height, class, style, exstyle)
- const char *text;
- unsigned long id;
- unsigned long x;
- unsigned long y;
- unsigned long width;
- unsigned long height;
- unsigned long class;
- unsigned long style;
- unsigned long exstyle;
+define_control (const struct res_id iid, unsigned long id, unsigned long x,
+ unsigned long y, unsigned long width, unsigned long height,
+ unsigned long class, unsigned long style,
+ unsigned long exstyle)
{
struct dialog_control *n;
@@ -842,9 +805,7 @@ define_control (text, id, x, y, width, height, class, style, exstyle)
n->height = height;
n->class.named = 0;
n->class.u.id = class;
- if (text == NULL)
- text = "";
- res_string_to_id (&n->text, text);
+ n->text = iid;
n->data = NULL;
n->help = 0;
@@ -852,21 +813,18 @@ define_control (text, id, x, y, width, height, class, style, exstyle)
}
struct dialog_control *
-define_icon_control (iid, id, x, y, style, exstyle, help, data, ex)
- struct res_id iid;
- unsigned long id;
- unsigned long x;
- unsigned long y;
- unsigned long style;
- unsigned long exstyle;
- unsigned long help;
- struct rcdata_item *data;
- struct dialog_ex *ex;
+define_icon_control (struct res_id iid, unsigned long id, unsigned long x,
+ unsigned long y, unsigned long style,
+ unsigned long exstyle, unsigned long help,
+ struct rcdata_item *data, struct dialog_ex *ex)
{
struct dialog_control *n;
+ struct res_id tid;
+
if (style == 0)
style = SS_ICON | WS_CHILD | WS_VISIBLE;
- n = define_control (0, id, x, y, 0, 0, CTL_STATIC, style, exstyle);
+ res_string_to_id (&tid, "");
+ n = define_control (tid, id, x, y, 0, 0, CTL_STATIC, style, exstyle);
n->text = iid;
if (help && !ex)
rcparse_warning (_("help ID requires DIALOGEX"));
@@ -881,10 +839,8 @@ define_icon_control (iid, id, x, y, style, exstyle, help, data, ex)
/* Define a font resource. */
void
-define_font (id, resinfo, filename)
- struct res_id id;
- const struct res_res_info *resinfo;
- const char *filename;
+define_font (struct res_id id, const struct res_res_info *resinfo,
+ const char *filename)
{
FILE *e;
char *real_filename;
@@ -969,7 +925,7 @@ define_font (id, resinfo, filename)
file has been parsed, if any font resources were seen. */
static void
-define_fontdirs ()
+define_fontdirs (void)
{
struct res_resource *r;
struct res_id id;
@@ -991,10 +947,8 @@ define_fontdirs ()
select one of the actual icon bitmaps. */
void
-define_icon (id, resinfo, filename)
- struct res_id id;
- const struct res_res_info *resinfo;
- const char *filename;
+define_icon (struct res_id id, const struct res_res_info *resinfo,
+ const char *filename)
{
FILE *e;
char *real_filename;
@@ -1086,10 +1040,20 @@ define_icon (id, resinfo, filename)
cg->height = icondirs[i].height;
cg->colors = icondirs[i].colorcount;
- cg->planes = 1;
- cg->bits = 0;
- while ((1 << cg->bits) < cg->colors)
- ++cg->bits;
+ if (icondirs[i].u.icon.planes)
+ cg->planes = icondirs[i].u.icon.planes;
+ else
+ cg->planes = 1;
+
+ if (icondirs[i].u.icon.bits)
+ cg->bits = icondirs[i].u.icon.bits;
+ else
+ {
+ cg->bits = 0;
+
+ while ((1L << cg->bits) < cg->colors)
+ ++cg->bits;
+ }
cg->bytes = icondirs[i].bytes;
cg->index = first_icon + i + 1;
@@ -1110,10 +1074,8 @@ define_icon (id, resinfo, filename)
/* Define a menu resource. */
void
-define_menu (id, resinfo, menuitems)
- struct res_id id;
- const struct res_res_info *resinfo;
- struct menuitem *menuitems;
+define_menu (struct res_id id, const struct res_res_info *resinfo,
+ struct menuitem *menuitems)
{
struct menu *m;
struct res_resource *r;
@@ -1132,13 +1094,9 @@ define_menu (id, resinfo, menuitems)
allocates and fills in a structure. */
struct menuitem *
-define_menuitem (text, menuid, type, state, help, menuitems)
- const char *text;
- int menuid;
- unsigned long type;
- unsigned long state;
- unsigned long help;
- struct menuitem *menuitems;
+define_menuitem (const char *text, int menuid, unsigned long type,
+ unsigned long state, unsigned long help,
+ struct menuitem *menuitems)
{
struct menuitem *mi;
@@ -1159,10 +1117,8 @@ define_menuitem (text, menuid, type, state, help, menuitems)
/* Define a messagetable resource. */
void
-define_messagetable (id, resinfo, filename)
- struct res_id id;
- const struct res_res_info *resinfo;
- const char *filename;
+define_messagetable (struct res_id id, const struct res_res_info *resinfo,
+ const char *filename)
{
FILE *e;
char *real_filename;
@@ -1196,10 +1152,8 @@ define_messagetable (id, resinfo, filename)
/* Define an rcdata resource. */
void
-define_rcdata (id, resinfo, data)
- struct res_id id;
- const struct res_res_info *resinfo;
- struct rcdata_item *data;
+define_rcdata (struct res_id id, const struct res_res_info *resinfo,
+ struct rcdata_item *data)
{
struct res_resource *r;
@@ -1213,9 +1167,7 @@ define_rcdata (id, resinfo, data)
/* Create an rcdata item holding a string. */
struct rcdata_item *
-define_rcdata_string (string, len)
- const char *string;
- unsigned long len;
+define_rcdata_string (const char *string, unsigned long len)
{
struct rcdata_item *ri;
char *s;
@@ -1234,9 +1186,7 @@ define_rcdata_string (string, len)
/* Create an rcdata item holding a number. */
struct rcdata_item *
-define_rcdata_number (val, dword)
- unsigned long val;
- int dword;
+define_rcdata_number (unsigned long val, int dword)
{
struct rcdata_item *ri;
@@ -1252,10 +1202,8 @@ define_rcdata_number (val, dword)
which appears in a STRINGTABLE statement. */
void
-define_stringtable (resinfo, stringid, string)
- const struct res_res_info *resinfo;
- unsigned long stringid;
- const char *string;
+define_stringtable (const struct res_res_info *resinfo,
+ unsigned long stringid, const char *string)
{
struct res_id id;
struct res_resource *r;
@@ -1289,11 +1237,9 @@ define_stringtable (resinfo, stringid, string)
/* Define a user data resource where the data is in the rc file. */
void
-define_user_data (id, type, resinfo, data)
- struct res_id id;
- struct res_id type;
- const struct res_res_info *resinfo;
- struct rcdata_item *data;
+define_user_data (struct res_id id, struct res_id type,
+ const struct res_res_info *resinfo,
+ struct rcdata_item *data)
{
struct res_id ids[3];
struct res_resource *r;
@@ -1312,11 +1258,8 @@ define_user_data (id, type, resinfo, data)
/* Define a user data resource where the data is in a file. */
void
-define_user_file (id, type, resinfo, filename)
- struct res_id id;
- struct res_id type;
- const struct res_res_info *resinfo;
- const char *filename;
+define_user_file (struct res_id id, struct res_id type,
+ const struct res_res_info *resinfo, const char *filename)
{
FILE *e;
char *real_filename;
@@ -1357,11 +1300,9 @@ define_user_file (id, type, resinfo, filename)
/* Define a versioninfo resource. */
void
-define_versioninfo (id, language, fixedverinfo, verinfo)
- struct res_id id;
- int language;
- struct fixed_versioninfo *fixedverinfo;
- struct ver_info *verinfo;
+define_versioninfo (struct res_id id, int language,
+ struct fixed_versioninfo *fixedverinfo,
+ struct ver_info *verinfo)
{
struct res_resource *r;
@@ -1377,10 +1318,8 @@ define_versioninfo (id, language, fixedverinfo, verinfo)
/* Add string version info to a list of version information. */
struct ver_info *
-append_ver_stringfileinfo (verinfo, language, strings)
- struct ver_info *verinfo;
- const char *language;
- struct ver_stringinfo *strings;
+append_ver_stringfileinfo (struct ver_info *verinfo, const char *language,
+ struct ver_stringinfo *strings)
{
struct ver_info *vi, **pp;
@@ -1400,10 +1339,8 @@ append_ver_stringfileinfo (verinfo, language, strings)
/* Add variable version info to a list of version information. */
struct ver_info *
-append_ver_varfileinfo (verinfo, key, var)
- struct ver_info *verinfo;
- const char *key;
- struct ver_varinfo *var;
+append_ver_varfileinfo (struct ver_info *verinfo, const char *key,
+ struct ver_varinfo *var)
{
struct ver_info *vi, **pp;
@@ -1423,10 +1360,8 @@ append_ver_varfileinfo (verinfo, key, var)
/* Append version string information to a list. */
struct ver_stringinfo *
-append_verval (strings, key, value)
- struct ver_stringinfo *strings;
- const char *key;
- const char *value;
+append_verval (struct ver_stringinfo *strings, const char *key,
+ const char *value)
{
struct ver_stringinfo *vs, **pp;
@@ -1445,10 +1380,8 @@ append_verval (strings, key, value)
/* Append version variable information to a list. */
struct ver_varinfo *
-append_vertrans (var, language, charset)
- struct ver_varinfo *var;
- unsigned long language;
- unsigned long charset;
+append_vertrans (struct ver_varinfo *var, unsigned long language,
+ unsigned long charset)
{
struct ver_varinfo *vv, **pp;
@@ -1466,42 +1399,35 @@ append_vertrans (var, language, charset)
/* Local functions used to write out an rc file. */
-static void indent PARAMS ((FILE *, int));
+static void indent (FILE *, int);
static void write_rc_directory
- PARAMS ((FILE *, const struct res_directory *, const struct res_id *,
- const struct res_id *, int *, int));
+ (FILE *, const struct res_directory *, const struct res_id *,
+ const struct res_id *, int *, int);
static void write_rc_subdir
- PARAMS ((FILE *, const struct res_entry *, const struct res_id *,
- const struct res_id *, int *, int));
+ (FILE *, const struct res_entry *, const struct res_id *,
+ const struct res_id *, int *, int);
static void write_rc_resource
- PARAMS ((FILE *, const struct res_id *, const struct res_id *,
- const struct res_resource *, int *));
-static void write_rc_accelerators
- PARAMS ((FILE *, const struct accelerator *));
-static void write_rc_cursor PARAMS ((FILE *, const struct cursor *));
-static void write_rc_group_cursor
- PARAMS ((FILE *, const struct group_cursor *));
-static void write_rc_dialog PARAMS ((FILE *, const struct dialog *));
-static void write_rc_dialog_control
- PARAMS ((FILE *, const struct dialog_control *));
-static void write_rc_fontdir PARAMS ((FILE *, const struct fontdir *));
-static void write_rc_group_icon PARAMS ((FILE *, const struct group_icon *));
-static void write_rc_menu PARAMS ((FILE *, const struct menu *, int));
-static void write_rc_menuitems
- PARAMS ((FILE *, const struct menuitem *, int, int));
-static void write_rc_rcdata PARAMS ((FILE *, const struct rcdata_item *, int));
+ (FILE *, const struct res_id *, const struct res_id *,
+ const struct res_resource *, int *);
+static void write_rc_accelerators (FILE *, const struct accelerator *);
+static void write_rc_cursor (FILE *, const struct cursor *);
+static void write_rc_group_cursor (FILE *, const struct group_cursor *);
+static void write_rc_dialog (FILE *, const struct dialog *);
+static void write_rc_dialog_control (FILE *, const struct dialog_control *);
+static void write_rc_fontdir (FILE *, const struct fontdir *);
+static void write_rc_group_icon (FILE *, const struct group_icon *);
+static void write_rc_menu (FILE *, const struct menu *, int);
+static void write_rc_menuitems (FILE *, const struct menuitem *, int, int);
+static void write_rc_rcdata (FILE *, const struct rcdata_item *, int);
static void write_rc_stringtable
- PARAMS ((FILE *, const struct res_id *, const struct stringtable *));
-static void write_rc_versioninfo PARAMS ((FILE *, const struct versioninfo *));
-static void write_rc_filedata
- PARAMS ((FILE *, unsigned long, const unsigned char *));
+ (FILE *, const struct res_id *, const struct stringtable *);
+static void write_rc_versioninfo (FILE *, const struct versioninfo *);
+static void write_rc_filedata (FILE *, unsigned long, const unsigned char *);
/* Indent a given number of spaces. */
static void
-indent (e, c)
- FILE *e;
- int c;
+indent (FILE *e, int c)
{
int i;
@@ -1520,9 +1446,7 @@ indent (e, c)
comes, this code will have to be fixed up. */
void
-write_rc_file (filename, resources)
- const char *filename;
- const struct res_directory *resources;
+write_rc_file (const char *filename, const struct res_directory *resources)
{
FILE *e;
int language;
@@ -1548,13 +1472,9 @@ write_rc_file (filename, resources)
language. LEVEL is the level in the tree. */
static void
-write_rc_directory (e, rd, type, name, language, level)
- FILE *e;
- const struct res_directory *rd;
- const struct res_id *type;
- const struct res_id *name;
- int *language;
- int level;
+write_rc_directory (FILE *e, const struct res_directory *rd,
+ const struct res_id *type, const struct res_id *name,
+ int *language, int level)
{
const struct res_entry *re;
@@ -1632,13 +1552,9 @@ write_rc_directory (e, rd, type, name, language, level)
LEVEL is the level in the tree. */
static void
-write_rc_subdir (e, re, type, name, language, level)
- FILE *e;
- const struct res_entry *re;
- const struct res_id *type;
- const struct res_id *name;
- int *language;
- int level;
+write_rc_subdir (FILE *e, const struct res_entry *re,
+ const struct res_id *type, const struct res_id *name,
+ int *language, int level)
{
fprintf (e, "\n");
switch (level)
@@ -1711,12 +1627,9 @@ write_rc_subdir (e, re, type, name, language, level)
language. */
static void
-write_rc_resource (e, type, name, res, language)
- FILE *e;
- const struct res_id *type;
- const struct res_id *name;
- const struct res_resource *res;
- int *language;
+write_rc_resource (FILE *e, const struct res_id *type,
+ const struct res_id *name, const struct res_resource *res,
+ int *language)
{
const char *s;
int rt;
@@ -1964,9 +1877,7 @@ write_rc_resource (e, type, name, res, language)
/* Write out accelerator information. */
static void
-write_rc_accelerators (e, accelerators)
- FILE *e;
- const struct accelerator *accelerators;
+write_rc_accelerators (FILE *e, const struct accelerator *accelerators)
{
const struct accelerator *acc;
@@ -2017,9 +1928,7 @@ write_rc_accelerators (e, accelerators)
file, which the rc file would include. */
static void
-write_rc_cursor (e, cursor)
- FILE *e;
- const struct cursor *cursor;
+write_rc_cursor (FILE *e, const struct cursor *cursor)
{
fprintf (e, "// Hotspot: x: %d; y: %d\n", cursor->xhotspot,
cursor->yhotspot);
@@ -2030,9 +1939,7 @@ write_rc_cursor (e, cursor)
cursor data. */
static void
-write_rc_group_cursor (e, group_cursor)
- FILE *e;
- const struct group_cursor *group_cursor;
+write_rc_group_cursor (FILE *e, const struct group_cursor *group_cursor)
{
const struct group_cursor *gc;
@@ -2048,9 +1955,7 @@ write_rc_group_cursor (e, group_cursor)
/* Write dialog data. */
static void
-write_rc_dialog (e, dialog)
- FILE *e;
- const struct dialog *dialog;
+write_rc_dialog (FILE *e, const struct dialog *dialog)
{
const struct dialog_control *control;
@@ -2143,9 +2048,7 @@ static const struct control_info control_info[] =
/* Write a dialog control. */
static void
-write_rc_dialog_control (e, control)
- FILE *e;
- const struct dialog_control *control;
+write_rc_dialog_control (FILE *e, const struct dialog_control *control)
{
const struct control_info *ci;
@@ -2216,9 +2119,7 @@ write_rc_dialog_control (e, control)
the font data. */
static void
-write_rc_fontdir (e, fontdir)
- FILE *e;
- const struct fontdir *fontdir;
+write_rc_fontdir (FILE *e, const struct fontdir *fontdir)
{
const struct fontdir *fc;
@@ -2233,9 +2134,7 @@ write_rc_fontdir (e, fontdir)
icon data. */
static void
-write_rc_group_icon (e, group_icon)
- FILE *e;
- const struct group_icon *group_icon;
+write_rc_group_icon (FILE *e, const struct group_icon *group_icon)
{
const struct group_icon *gi;
@@ -2251,10 +2150,7 @@ write_rc_group_icon (e, group_icon)
/* Write out a menu resource. */
static void
-write_rc_menu (e, menu, menuex)
- FILE *e;
- const struct menu *menu;
- int menuex;
+write_rc_menu (FILE *e, const struct menu *menu, int menuex)
{
if (menu->help != 0)
fprintf (e, "// Help ID: %lu\n", menu->help);
@@ -2264,11 +2160,8 @@ write_rc_menu (e, menu, menuex)
/* Write out menuitems. */
static void
-write_rc_menuitems (e, menuitems, menuex, ind)
- FILE *e;
- const struct menuitem *menuitems;
- int menuex;
- int ind;
+write_rc_menuitems (FILE *e, const struct menuitem *menuitems, int menuex,
+ int ind)
{
const struct menuitem *mi;
@@ -2353,10 +2246,7 @@ write_rc_menuitems (e, menuitems, menuex, ind)
resources that need to print arbitrary data. */
static void
-write_rc_rcdata (e, rcdata, ind)
- FILE *e;
- const struct rcdata_item *rcdata;
- int ind;
+write_rc_rcdata (FILE *e, const struct rcdata_item *rcdata, int ind)
{
const struct rcdata_item *ri;
@@ -2521,10 +2411,8 @@ write_rc_rcdata (e, rcdata, ind)
/* Write out a stringtable resource. */
static void
-write_rc_stringtable (e, name, stringtable)
- FILE *e;
- const struct res_id *name;
- const struct stringtable *stringtable;
+write_rc_stringtable (FILE *e, const struct res_id *name,
+ const struct stringtable *stringtable)
{
unsigned long offset;
int i;
@@ -2557,9 +2445,7 @@ write_rc_stringtable (e, name, stringtable)
/* Write out a versioninfo resource. */
static void
-write_rc_versioninfo (e, versioninfo)
- FILE *e;
- const struct versioninfo *versioninfo;
+write_rc_versioninfo (FILE *e, const struct versioninfo *versioninfo)
{
const struct fixed_versioninfo *f;
const struct ver_info *vi;
@@ -2648,10 +2534,7 @@ write_rc_versioninfo (e, versioninfo)
/* Write out data which would normally be read from a file. */
static void
-write_rc_filedata (e, length, data)
- FILE *e;
- unsigned long length;
- const unsigned char *data;
+write_rc_filedata (FILE *e, unsigned long length, const unsigned char *data)
{
unsigned long i;
diff --git a/contrib/binutils/binutils/size.c b/contrib/binutils/binutils/size.c
index 792cb82..9875493 100644
--- a/contrib/binutils/binutils/size.c
+++ b/contrib/binutils/binutils/size.c
@@ -1,6 +1,6 @@
/* size.c -- report size of various sections of an executable file.
- Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
- Free Software Foundation, Inc.
+ Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
+ 2002, 2003 Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -61,33 +61,31 @@ static char *target = NULL;
/* Static declarations. */
-static void usage PARAMS ((FILE *, int));
-static void display_file PARAMS ((char *));
-static void display_bfd PARAMS ((bfd *));
-static void display_archive PARAMS ((bfd *));
-static int size_number PARAMS ((bfd_size_type));
+static void usage (FILE *, int);
+static void display_file (char *);
+static void display_bfd (bfd *);
+static void display_archive (bfd *);
+static int size_number (bfd_size_type);
#if 0
-static void lprint_number PARAMS ((int, bfd_size_type));
+static void lprint_number (int, bfd_size_type);
#endif
-static void rprint_number PARAMS ((int, bfd_size_type));
-static void print_berkeley_format PARAMS ((bfd *));
-static void sysv_internal_sizer PARAMS ((bfd *, asection *, PTR));
-static void sysv_internal_printer PARAMS ((bfd *, asection *, PTR));
-static void print_sysv_format PARAMS ((bfd *));
-static void print_sizes PARAMS ((bfd * file));
-static void berkeley_sum PARAMS ((bfd *, sec_ptr, PTR));
+static void rprint_number (int, bfd_size_type);
+static void print_berkeley_format (bfd *);
+static void sysv_internal_sizer (bfd *, asection *, void *);
+static void sysv_internal_printer (bfd *, asection *, void *);
+static void print_sysv_format (bfd *);
+static void print_sizes (bfd * file);
+static void berkeley_sum (bfd *, sec_ptr, void *);
static void
-usage (stream, status)
- FILE *stream;
- int status;
+usage (FILE *stream, int status)
{
fprintf (stream, _("Usage: %s [option(s)] [file(s)]\n"), program_name);
fprintf (stream, _(" Displays the sizes of sections inside binary files\n"));
fprintf (stream, _(" If no input file(s) are specified, a.out is assumed\n"));
fprintf (stream, _(" The options are:\n\
-A|-B --format={sysv|berkeley} Select output style (default is %s)\n\
- -o|-d|-h --radix={8|10|16} Display numbers in octal, decimal or hex\n\
+ -o|-d|-x --radix={8|10|16} Display numbers in octal, decimal or hex\n\
-t --totals Display the total sizes (Berkeley only)\n\
--target=<bfdname> Set the binary file format\n\
-h --help Display this information\n\
@@ -116,12 +114,10 @@ struct option long_options[] =
{0, no_argument, 0, 0}
};
-int main PARAMS ((int, char **));
+int main (int, char **);
int
-main (argc, argv)
- int argc;
- char **argv;
+main (int argc, char **argv)
{
int temp;
int c;
@@ -260,8 +256,7 @@ main (argc, argv)
/* Display stats on file or archive member ABFD. */
static void
-display_bfd (abfd)
- bfd *abfd;
+display_bfd (bfd *abfd)
{
char **matching;
@@ -312,8 +307,7 @@ display_bfd (abfd)
}
static void
-display_archive (file)
- bfd *file;
+display_archive (bfd *file)
{
bfd *arfile = (bfd *) NULL;
bfd *last_arfile = (bfd *) NULL;
@@ -345,11 +339,14 @@ display_archive (file)
}
static void
-display_file (filename)
- char *filename;
+display_file (char *filename)
{
- bfd *file = bfd_openr (filename, target);
+ bfd *file;
+ if (get_file_size (filename) < 1)
+ return;
+
+ file = bfd_openr (filename, target);
if (file == NULL)
{
bfd_nonfatal (filename);
@@ -357,12 +354,12 @@ display_file (filename)
return;
}
- if (bfd_check_format (file, bfd_archive) == true)
+ if (bfd_check_format (file, bfd_archive))
display_archive (file);
else
display_bfd (file);
- if (bfd_close (file) == false)
+ if (!bfd_close (file))
{
bfd_nonfatal (filename);
return_code = 1;
@@ -373,8 +370,7 @@ display_file (filename)
/* This is what lexical functions are for. */
static int
-size_number (num)
- bfd_size_type num;
+size_number (bfd_size_type num)
{
char buffer[40];
@@ -391,9 +387,7 @@ size_number (num)
/* This is not used. */
static void
-lprint_number (width, num)
- int width;
- bfd_size_type num;
+lprint_number (int width, bfd_size_type num)
{
char buffer[40];
@@ -408,9 +402,7 @@ lprint_number (width, num)
#endif
static void
-rprint_number (width, num)
- int width;
- bfd_size_type num;
+rprint_number (int width, bfd_size_type num)
{
char buffer[40];
@@ -427,10 +419,8 @@ static bfd_size_type datasize;
static bfd_size_type textsize;
static void
-berkeley_sum (abfd, sec, ignore)
- bfd *abfd ATTRIBUTE_UNUSED;
- sec_ptr sec;
- PTR ignore ATTRIBUTE_UNUSED;
+berkeley_sum (bfd *abfd ATTRIBUTE_UNUSED, sec_ptr sec,
+ void *ignore ATTRIBUTE_UNUSED)
{
flagword flags;
bfd_size_type size;
@@ -449,8 +439,7 @@ berkeley_sum (abfd, sec, ignore)
}
static void
-print_berkeley_format (abfd)
- bfd *abfd;
+print_berkeley_format (bfd *abfd)
{
static int files_seen = 0;
bfd_size_type total;
@@ -459,7 +448,7 @@ print_berkeley_format (abfd)
datasize = 0;
textsize = 0;
- bfd_map_over_sections (abfd, berkeley_sum, (PTR) NULL);
+ bfd_map_over_sections (abfd, berkeley_sum, NULL);
if (files_seen++ == 0)
#if 0
@@ -502,10 +491,8 @@ int svi_vmalen = 0;
int svi_sizelen = 0;
static void
-sysv_internal_sizer (file, sec, ignore)
- bfd *file ATTRIBUTE_UNUSED;
- sec_ptr sec;
- PTR ignore ATTRIBUTE_UNUSED;
+sysv_internal_sizer (bfd *file ATTRIBUTE_UNUSED, sec_ptr sec,
+ void *ignore ATTRIBUTE_UNUSED)
{
bfd_size_type size = bfd_section_size (file, sec);
@@ -526,10 +513,8 @@ sysv_internal_sizer (file, sec, ignore)
}
static void
-sysv_internal_printer (file, sec, ignore)
- bfd *file ATTRIBUTE_UNUSED;
- sec_ptr sec;
- PTR ignore ATTRIBUTE_UNUSED;
+sysv_internal_printer (bfd *file ATTRIBUTE_UNUSED, sec_ptr sec,
+ void *ignore ATTRIBUTE_UNUSED)
{
bfd_size_type size = bfd_section_size (file, sec);
@@ -548,14 +533,13 @@ sysv_internal_printer (file, sec, ignore)
}
static void
-print_sysv_format (file)
- bfd *file;
+print_sysv_format (bfd *file)
{
/* Size all of the columns. */
svi_total = 0;
svi_maxvma = 0;
svi_namelen = 0;
- bfd_map_over_sections (file, sysv_internal_sizer, (PTR) NULL);
+ bfd_map_over_sections (file, sysv_internal_sizer, NULL);
svi_vmalen = size_number ((bfd_size_type)svi_maxvma);
if ((size_t) svi_vmalen < sizeof ("addr") - 1)
@@ -574,7 +558,7 @@ print_sysv_format (file)
printf (":\n%-*s %*s %*s\n", svi_namelen, "section",
svi_sizelen, "size", svi_vmalen, "addr");
- bfd_map_over_sections (file, sysv_internal_printer, (PTR) NULL);
+ bfd_map_over_sections (file, sysv_internal_printer, NULL);
printf ("%-*s ", svi_namelen, "Total");
rprint_number (svi_sizelen, svi_total);
@@ -582,8 +566,7 @@ print_sysv_format (file)
}
static void
-print_sizes (file)
- bfd *file;
+print_sizes (bfd *file)
{
if (berkeley_format)
print_berkeley_format (file);
diff --git a/contrib/binutils/binutils/srconv.c b/contrib/binutils/binutils/srconv.c
index a45437f..0ffa058 100644
--- a/contrib/binutils/binutils/srconv.c
+++ b/contrib/binutils/binutils/srconv.c
@@ -1,5 +1,5 @@
/* srconv.c -- Sysroff conversion program
- Copyright 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
+ Copyright 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -42,61 +42,52 @@ static int addrsize;
static char *toolname;
static char **rnames;
-static int get_member_id PARAMS ((int));
-static int get_ordinary_id PARAMS ((int));
-static char *section_translate PARAMS ((char *));
-static char *strip_suffix PARAMS ((char *));
-static void checksum PARAMS ((FILE *, char *, int, int));
-static void writeINT PARAMS ((int, char *, int *, int, FILE *));
-static void writeBITS PARAMS ((int, char *, int *, int));
-static void writeBARRAY PARAMS ((barray, char *, int *, int, FILE *));
-static void writeCHARS PARAMS ((char *, char *, int *, int, FILE *));
-static void wr_tr PARAMS ((void));
-static void wr_un PARAMS ((struct coff_ofile *, struct coff_sfile *, int, int));
-static void wr_hd PARAMS ((struct coff_ofile *));
-static void wr_sh PARAMS ((struct coff_ofile *, struct coff_section *));
-static void wr_ob PARAMS ((struct coff_ofile *, struct coff_section *));
-static void wr_rl PARAMS ((struct coff_ofile *, struct coff_section *));
-static void wr_object_body PARAMS ((struct coff_ofile *));
+static int get_member_id (int);
+static int get_ordinary_id (int);
+static char *section_translate (char *);
+static char *strip_suffix (char *);
+static void checksum (FILE *, char *, int, int);
+static void writeINT (int, char *, int *, int, FILE *);
+static void writeBITS (int, char *, int *, int);
+static void writeBARRAY (barray, char *, int *, int, FILE *);
+static void writeCHARS (char *, char *, int *, int, FILE *);
+static void wr_tr (void);
+static void wr_un (struct coff_ofile *, struct coff_sfile *, int, int);
+static void wr_hd (struct coff_ofile *);
+static void wr_sh (struct coff_ofile *, struct coff_section *);
+static void wr_ob (struct coff_ofile *, struct coff_section *);
+static void wr_rl (struct coff_ofile *, struct coff_section *);
+static void wr_object_body (struct coff_ofile *);
static void wr_dps_start
- PARAMS ((struct coff_sfile *, struct coff_section *, struct coff_scope *,
- int, int));
-static void wr_dps_end
- PARAMS ((struct coff_section *, struct coff_scope *, int));
-static int *nints PARAMS ((int));
+ (struct coff_sfile *, struct coff_section *, struct coff_scope *, int, int);
+static void wr_dps_end (struct coff_section *, struct coff_scope *, int);
+static int *nints (int);
static void walk_tree_type_1
- PARAMS ((struct coff_sfile *, struct coff_symbol *, struct coff_type *,
- int));
+ (struct coff_sfile *, struct coff_symbol *, struct coff_type *, int);
static void walk_tree_type
- PARAMS ((struct coff_sfile *, struct coff_symbol *, struct coff_type *,
- int));
+ (struct coff_sfile *, struct coff_symbol *, struct coff_type *, int);
static void walk_tree_symbol
- PARAMS ((struct coff_sfile *, struct coff_section *,
- struct coff_symbol *, int));
+ (struct coff_sfile *, struct coff_section *, struct coff_symbol *, int);
static void walk_tree_scope
- PARAMS ((struct coff_section *, struct coff_sfile *, struct coff_scope *,
- int, int));
-static void walk_tree_sfile
- PARAMS ((struct coff_section *, struct coff_sfile *));
-static void wr_program_structure
- PARAMS ((struct coff_ofile *, struct coff_sfile *));
-static void wr_du PARAMS ((struct coff_ofile *, struct coff_sfile *, int));
-static void wr_dus PARAMS ((struct coff_ofile *, struct coff_sfile *));
-static int find_base PARAMS ((struct coff_sfile *, struct coff_section *));
-static void wr_dln PARAMS ((struct coff_ofile *, struct coff_sfile *, int));
-static void wr_globals
- PARAMS ((struct coff_ofile *, struct coff_sfile *, int));
-static void wr_debug PARAMS ((struct coff_ofile *));
-static void wr_cs PARAMS ((void));
-static int wr_sc PARAMS ((struct coff_ofile *, struct coff_sfile *));
-static void wr_er PARAMS ((struct coff_ofile *, struct coff_sfile *, int));
-static void wr_ed PARAMS ((struct coff_ofile *, struct coff_sfile *, int));
-static void wr_unit_info PARAMS ((struct coff_ofile *));
-static void wr_module PARAMS ((struct coff_ofile *));
-static int align PARAMS ((int));
-static void prescan PARAMS ((struct coff_ofile *));
-static void show_usage PARAMS ((FILE *, int));
-extern int main PARAMS ((int, char **));
+ (struct coff_section *, struct coff_sfile *, struct coff_scope *, int, int);
+static void walk_tree_sfile (struct coff_section *, struct coff_sfile *);
+static void wr_program_structure (struct coff_ofile *, struct coff_sfile *);
+static void wr_du (struct coff_ofile *, struct coff_sfile *, int);
+static void wr_dus (struct coff_ofile *, struct coff_sfile *);
+static int find_base (struct coff_sfile *, struct coff_section *);
+static void wr_dln (struct coff_ofile *, struct coff_sfile *, int);
+static void wr_globals (struct coff_ofile *, struct coff_sfile *, int);
+static void wr_debug (struct coff_ofile *);
+static void wr_cs (void);
+static int wr_sc (struct coff_ofile *, struct coff_sfile *);
+static void wr_er (struct coff_ofile *, struct coff_sfile *, int);
+static void wr_ed (struct coff_ofile *, struct coff_sfile *, int);
+static void wr_unit_info (struct coff_ofile *);
+static void wr_module (struct coff_ofile *);
+static int align (int);
+static void prescan (struct coff_ofile *);
+static void show_usage (FILE *, int);
+extern int main (int, char **);
static FILE *file;
static bfd *abfd;
@@ -118,8 +109,7 @@ static int base1 = 0x18;
static int base2 = 0x2018;
static int
-get_member_id (x)
- int x;
+get_member_id (int x)
{
if (ids2[x])
return ids2[x];
@@ -129,8 +119,7 @@ get_member_id (x)
}
static int
-get_ordinary_id (x)
- int x;
+get_ordinary_id (int x)
{
if (ids1[x])
return ids1[x];
@@ -139,8 +128,7 @@ get_ordinary_id (x)
return ids1[x];
}
static char *
-section_translate (n)
- char *n;
+section_translate (char *n)
{
if (strcmp (n, ".text") == 0)
return "P";
@@ -155,8 +143,7 @@ section_translate (n)
static
char *
-strip_suffix (name)
- char *name;
+strip_suffix (char *name)
{
int i;
char *res;
@@ -171,11 +158,7 @@ strip_suffix (name)
/* IT LEN stuff CS */
static void
-checksum (file, ptr, size, code)
- FILE *file;
- char *ptr;
- int size;
- int code;
+checksum (FILE *file, char *ptr, int size, int code)
{
int j;
int last;
@@ -198,12 +181,7 @@ checksum (file, ptr, size, code)
static void
-writeINT (n, ptr, idx, size, file)
- int n;
- char *ptr;
- int *idx;
- int size;
- FILE *file;
+writeINT (int n, char *ptr, int *idx, int size, FILE *file)
{
int byte = *idx / 8;
@@ -244,11 +222,7 @@ writeINT (n, ptr, idx, size, file)
}
static void
-writeBITS (val, ptr, idx, size)
- int val;
- char *ptr;
- int *idx;
- int size;
+writeBITS (int val, char *ptr, int *idx, int size)
{
int byte = *idx / 8;
int bit = *idx % 8;
@@ -265,12 +239,8 @@ writeBITS (val, ptr, idx, size)
}
static void
-writeBARRAY (data, ptr, idx, size, file)
- barray data;
- char *ptr;
- int *idx;
- int size ATTRIBUTE_UNUSED;
- FILE *file;
+writeBARRAY (barray data, char *ptr, int *idx, int size ATTRIBUTE_UNUSED,
+ FILE *file)
{
int i;
@@ -280,12 +250,7 @@ writeBARRAY (data, ptr, idx, size, file)
}
static void
-writeCHARS (string, ptr, idx, size, file)
- char *string;
- char *ptr;
- int *idx;
- int size;
- FILE *file;
+writeCHARS (char *string, char *ptr, int *idx, int size, FILE *file)
{
int i = *idx / 8;
@@ -324,7 +289,7 @@ static char *rname_h8300[] =
};
static void
-wr_tr ()
+wr_tr (void)
{
/* The TR block is not normal - it doesn't have any contents. */
@@ -338,11 +303,8 @@ wr_tr ()
}
static void
-wr_un (ptr, sfile, first, nsecs)
- struct coff_ofile *ptr;
- struct coff_sfile *sfile;
- int first;
- int nsecs ATTRIBUTE_UNUSED;
+wr_un (struct coff_ofile *ptr, struct coff_sfile *sfile, int first,
+ int nsecs ATTRIBUTE_UNUSED)
{
struct IT_un un;
struct coff_symbol *s;
@@ -387,8 +349,7 @@ wr_un (ptr, sfile, first, nsecs)
}
static void
-wr_hd (p)
- struct coff_ofile *p;
+wr_hd (struct coff_ofile *p)
{
struct IT_hd hd;
@@ -475,9 +436,7 @@ wr_hd (p)
static void
-wr_sh (p, sec)
- struct coff_ofile *p ATTRIBUTE_UNUSED;
- struct coff_section *sec;
+wr_sh (struct coff_ofile *p ATTRIBUTE_UNUSED, struct coff_section *sec)
{
struct IT_sh sh;
sh.unit = 0;
@@ -490,9 +449,7 @@ wr_sh (p, sec)
static void
-wr_ob (p, section)
- struct coff_ofile *p ATTRIBUTE_UNUSED;
- struct coff_section *section;
+wr_ob (struct coff_ofile *p ATTRIBUTE_UNUSED, struct coff_section *section)
{
bfd_size_type i;
int first = 1;
@@ -553,9 +510,7 @@ wr_ob (p, section)
}
static void
-wr_rl (ptr, sec)
- struct coff_ofile *ptr ATTRIBUTE_UNUSED;
- struct coff_section *sec;
+wr_rl (struct coff_ofile *ptr ATTRIBUTE_UNUSED, struct coff_section *sec)
{
int nr = sec->nrelocs;
int i;
@@ -613,8 +568,7 @@ wr_rl (ptr, sec)
}
static void
-wr_object_body (p)
- struct coff_ofile *p;
+wr_object_body (struct coff_ofile *p)
{
int i;
@@ -627,12 +581,9 @@ wr_object_body (p)
}
static void
-wr_dps_start (sfile, section, scope, type, nest)
- struct coff_sfile *sfile;
- struct coff_section *section ATTRIBUTE_UNUSED;
- struct coff_scope *scope;
- int type;
- int nest;
+wr_dps_start (struct coff_sfile *sfile,
+ struct coff_section *section ATTRIBUTE_UNUSED,
+ struct coff_scope *scope, int type, int nest)
{
struct IT_dps dps;
@@ -667,10 +618,8 @@ wr_dps_start (sfile, section, scope, type, nest)
}
static void
-wr_dps_end (section, scope, type)
- struct coff_section *section ATTRIBUTE_UNUSED;
- struct coff_scope *scope ATTRIBUTE_UNUSED;
- int type;
+wr_dps_end (struct coff_section *section ATTRIBUTE_UNUSED,
+ struct coff_scope *scope ATTRIBUTE_UNUSED, int type)
{
struct IT_dps dps;
@@ -680,18 +629,14 @@ wr_dps_end (section, scope, type)
}
static int *
-nints (x)
- int x;
+nints (int x)
{
return (int *) (xcalloc (sizeof (int), x));
}
static void
-walk_tree_type_1 (sfile, symbol, type, nest)
- struct coff_sfile *sfile;
- struct coff_symbol *symbol;
- struct coff_type *type;
- int nest;
+walk_tree_type_1 (struct coff_sfile *sfile, struct coff_symbol *symbol,
+ struct coff_type *type, int nest)
{
switch (type->type)
{
@@ -962,11 +907,8 @@ walk_tree_type_1 (sfile, symbol, type, nest)
*/
static void
-walk_tree_type (sfile, symbol, type, nest)
- struct coff_sfile *sfile;
- struct coff_symbol *symbol;
- struct coff_type *type;
- int nest;
+walk_tree_type (struct coff_sfile *sfile, struct coff_symbol *symbol,
+ struct coff_type *type, int nest)
{
if (symbol->type->type == coff_function_type)
{
@@ -1012,11 +954,7 @@ walk_tree_type (sfile, symbol, type, nest)
}
static void
-walk_tree_symbol (sfile, section, symbol, nest)
- struct coff_sfile *sfile;
- struct coff_section *section ATTRIBUTE_UNUSED;
- struct coff_symbol *symbol;
- int nest;
+walk_tree_symbol (struct coff_sfile *sfile, struct coff_section *section ATTRIBUTE_UNUSED, struct coff_symbol *symbol, int nest)
{
struct IT_dsy dsy;
@@ -1230,12 +1168,7 @@ walk_tree_symbol (sfile, section, symbol, nest)
}
static void
-walk_tree_scope (section, sfile, scope, nest, type)
- struct coff_section *section;
- struct coff_sfile *sfile;
- struct coff_scope *scope;
- int nest;
- int type;
+walk_tree_scope (struct coff_section *section, struct coff_sfile *sfile, struct coff_scope *scope, int nest, int type)
{
struct coff_symbol *vars;
struct coff_scope *child;
@@ -1259,26 +1192,19 @@ walk_tree_scope (section, sfile, scope, nest, type)
}
static void
-walk_tree_sfile (section, sfile)
- struct coff_section *section;
- struct coff_sfile *sfile;
+walk_tree_sfile (struct coff_section *section, struct coff_sfile *sfile)
{
walk_tree_scope (section, sfile, sfile->scope, 0, BLOCK_TYPE_COMPUNIT);
}
static void
-wr_program_structure (p, sfile)
- struct coff_ofile *p;
- struct coff_sfile *sfile;
+wr_program_structure (struct coff_ofile *p, struct coff_sfile *sfile)
{
walk_tree_sfile (p->sections + 4, sfile);
}
static void
-wr_du (p, sfile, n)
- struct coff_ofile *p;
- struct coff_sfile *sfile;
- int n;
+wr_du (struct coff_ofile *p, struct coff_sfile *sfile, int n)
{
struct IT_du du;
int lim;
@@ -1391,9 +1317,7 @@ wr_du (p, sfile, n)
}
static void
-wr_dus (p, sfile)
- struct coff_ofile *p ATTRIBUTE_UNUSED;
- struct coff_sfile *sfile;
+wr_dus (struct coff_ofile *p ATTRIBUTE_UNUSED, struct coff_sfile *sfile)
{
struct IT_dus dus;
@@ -1429,19 +1353,14 @@ wr_dus (p, sfile)
.text section for the output file. */
static int
-find_base (sfile, section)
- struct coff_sfile *sfile;
- struct coff_section *section;
+find_base (struct coff_sfile *sfile, struct coff_section *section)
{
return sfile->section[section->number].low;
}
static void
-wr_dln (p, sfile, n)
- struct coff_ofile *p ATTRIBUTE_UNUSED;
- struct coff_sfile *sfile;
- int n ATTRIBUTE_UNUSED;
-
+wr_dln (struct coff_ofile *p ATTRIBUTE_UNUSED, struct coff_sfile *sfile,
+ int n ATTRIBUTE_UNUSED)
{
#if 0
if (n == 0)
@@ -1578,10 +1497,8 @@ wr_dln (p, sfile, n)
/* Write the global symbols out to the debug info. */
static void
-wr_globals (p, sfile, n)
- struct coff_ofile *p;
- struct coff_sfile *sfile;
- int n ATTRIBUTE_UNUSED;
+wr_globals (struct coff_ofile *p, struct coff_sfile *sfile,
+ int n ATTRIBUTE_UNUSED)
{
struct coff_symbol *sy;
@@ -1601,8 +1518,7 @@ wr_globals (p, sfile, n)
}
static void
-wr_debug (p)
- struct coff_ofile *p;
+wr_debug (struct coff_ofile *p)
{
struct coff_sfile *sfile;
int n = 0;
@@ -1623,7 +1539,7 @@ wr_debug (p)
}
static void
-wr_cs ()
+wr_cs (void)
{
/* It seems that the CS struct is not normal - the size is wrong
heres one I prepared earlier. */
@@ -1671,9 +1587,7 @@ wr_cs ()
if there isn't an equivalent one on the input. */
static int
-wr_sc (ptr, sfile)
- struct coff_ofile *ptr;
- struct coff_sfile *sfile;
+wr_sc (struct coff_ofile *ptr, struct coff_sfile *sfile)
{
int i;
int scount = 0;
@@ -1795,10 +1709,8 @@ wr_sc (ptr, sfile)
/* Write out the ER records for a unit. */
static void
-wr_er (ptr, sfile, first)
- struct coff_ofile *ptr;
- struct coff_sfile *sfile ATTRIBUTE_UNUSED;
- int first;
+wr_er (struct coff_ofile *ptr, struct coff_sfile *sfile ATTRIBUTE_UNUSED,
+ int first)
{
int idx = 0;
struct coff_symbol *sym;
@@ -1824,10 +1736,8 @@ wr_er (ptr, sfile, first)
/* Write out the ED records for a unit. */
static void
-wr_ed (ptr, sfile, first)
- struct coff_ofile *ptr;
- struct coff_sfile *sfile ATTRIBUTE_UNUSED;
- int first;
+wr_ed (struct coff_ofile *ptr, struct coff_sfile *sfile ATTRIBUTE_UNUSED,
+ int first)
{
struct coff_symbol *s;
@@ -1866,8 +1776,7 @@ wr_ed (ptr, sfile, first)
}
static void
-wr_unit_info (ptr)
- struct coff_ofile *ptr;
+wr_unit_info (struct coff_ofile *ptr)
{
struct coff_sfile *sfile;
int first = 1;
@@ -1894,8 +1803,7 @@ wr_unit_info (ptr)
}
static void
-wr_module (p)
- struct coff_ofile *p;
+wr_module (struct coff_ofile *p)
{
wr_cs ();
wr_hd (p);
@@ -1906,8 +1814,7 @@ wr_module (p)
}
static int
-align (x)
- int x;
+align (int x)
{
return (x + 3) & ~3;
}
@@ -1916,8 +1823,7 @@ align (x)
ordinary defs - dunno why, but thats what hitachi does with 'em. */
static void
-prescan (tree)
- struct coff_ofile *tree;
+prescan (struct coff_ofile *tree)
{
struct coff_symbol *s;
struct coff_section *common_section;
@@ -1945,9 +1851,7 @@ prescan (tree)
char *program_name;
static void
-show_usage (file, status)
- FILE *file;
- int status;
+show_usage (FILE *file, int status)
{
fprintf (file, _("Usage: %s [option(s)] in-file [out-file]\n"), program_name);
fprintf (file, _("Convert a COFF object file into a SYSROFF object file\n"));
@@ -1964,9 +1868,7 @@ show_usage (file, status)
}
int
-main (ac, av)
- int ac;
- char *av[];
+main (int ac, char **av)
{
int opt;
static struct option long_options[] =
diff --git a/contrib/binutils/binutils/stabs.c b/contrib/binutils/binutils/stabs.c
index 0873582..7af10ef 100644
--- a/contrib/binutils/binutils/stabs.c
+++ b/contrib/binutils/binutils/stabs.c
@@ -1,5 +1,5 @@
/* stabs.c -- Parse stabs debugging information
- Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001
+ Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
Written by Ian Lance Taylor <ian@cygnus.com>.
@@ -35,10 +35,6 @@
#include "debug.h"
#include "budbg.h"
#include "filenames.h"
-
-/* Meaningless definition needs by aout64.h. FIXME. */
-#define BYTES_IN_WORD 4
-
#include "aout/aout64.h"
#include "aout/stab_gnu.h"
@@ -53,8 +49,8 @@ struct stab_handle
{
/* The BFD. */
bfd *abfd;
- /* True if this is stabs in sections. */
- boolean sections;
+ /* TRUE if this is stabs in sections. */
+ bfd_boolean sections;
/* The symbol table. */
asymbol **syms;
/* The number of symbols. */
@@ -74,7 +70,7 @@ struct stab_handle
int gcc_compiled;
/* Whether an N_OPT symbol was seen that was not generated by gcc,
so that we can detect the SunPRO compiler. */
- boolean n_opt_found;
+ bfd_boolean n_opt_found;
/* The main file name. */
char *main_filename;
/* A stack of unfinished N_BINCL files. */
@@ -82,7 +78,7 @@ struct stab_handle
/* A list of finished N_BINCL files. */
struct bincl_file *bincl_list;
/* Whether we are inside a function or not. */
- boolean within_function;
+ bfd_boolean within_function;
/* The address of the end of the function, used if we have seen an
N_FUN symbol while in a function. This is -1 if we have not seen
an N_FUN (the normal case). */
@@ -101,7 +97,7 @@ struct stab_handle
struct stab_tag *tags;
/* Set by parse_stab_type if it sees a structure defined as a cross
reference to itself. Reset by parse_stab_type otherwise. */
- boolean self_crossref;
+ bfd_boolean self_crossref;
};
/* A list of these structures is used to hold pending variable
@@ -151,76 +147,70 @@ struct stab_tag
debug_type type;
};
-static char *savestring PARAMS ((const char *, int));
-static bfd_vma parse_number PARAMS ((const char **, boolean *));
-static void bad_stab PARAMS ((const char *));
-static void warn_stab PARAMS ((const char *, const char *));
-static boolean parse_stab_string
- PARAMS ((PTR, struct stab_handle *, int, int, bfd_vma, const char *));
+static char *savestring (const char *, int);
+static bfd_vma parse_number (const char **, bfd_boolean *);
+static void bad_stab (const char *);
+static void warn_stab (const char *, const char *);
+static bfd_boolean parse_stab_string
+ (void *, struct stab_handle *, int, int, bfd_vma, const char *);
static debug_type parse_stab_type
- PARAMS ((PTR, struct stab_handle *, const char *, const char **,
- debug_type **));
-static boolean parse_stab_type_number
- PARAMS ((const char **, int *));
+ (void *, struct stab_handle *, const char *, const char **, debug_type **);
+static bfd_boolean parse_stab_type_number (const char **, int *);
static debug_type parse_stab_range_type
- PARAMS ((PTR, struct stab_handle *, const char *, const char **,
- const int *));
-static debug_type parse_stab_sun_builtin_type PARAMS ((PTR, const char **));
-static debug_type parse_stab_sun_floating_type
- PARAMS ((PTR, const char **));
-static debug_type parse_stab_enum_type PARAMS ((PTR, const char **));
+ (void *, struct stab_handle *, const char *, const char **, const int *);
+static debug_type parse_stab_sun_builtin_type (void *, const char **);
+static debug_type parse_stab_sun_floating_type (void *, const char **);
+static debug_type parse_stab_enum_type (void *, const char **);
static debug_type parse_stab_struct_type
- PARAMS ((PTR, struct stab_handle *, const char *, const char **, boolean,
- const int *));
-static boolean parse_stab_baseclasses
- PARAMS ((PTR, struct stab_handle *, const char **, debug_baseclass **));
-static boolean parse_stab_struct_fields
- PARAMS ((PTR, struct stab_handle *, const char **, debug_field **,
- boolean *));
-static boolean parse_stab_cpp_abbrev
- PARAMS ((PTR, struct stab_handle *, const char **, debug_field *));
-static boolean parse_stab_one_struct_field
- PARAMS ((PTR, struct stab_handle *, const char **, const char *,
- debug_field *, boolean *));
-static boolean parse_stab_members
- PARAMS ((PTR, struct stab_handle *, const char *, const char **,
- const int *, debug_method **));
+ (void *, struct stab_handle *, const char *, const char **,
+ bfd_boolean, const int *);
+static bfd_boolean parse_stab_baseclasses
+ (void *, struct stab_handle *, const char **, debug_baseclass **);
+static bfd_boolean parse_stab_struct_fields
+ (void *, struct stab_handle *, const char **, debug_field **, bfd_boolean *);
+static bfd_boolean parse_stab_cpp_abbrev
+ (void *, struct stab_handle *, const char **, debug_field *);
+static bfd_boolean parse_stab_one_struct_field
+ (void *, struct stab_handle *, const char **, const char *,
+ debug_field *, bfd_boolean *);
+static bfd_boolean parse_stab_members
+ (void *, struct stab_handle *, const char *, const char **, const int *,
+ debug_method **);
static debug_type parse_stab_argtypes
- PARAMS ((PTR, struct stab_handle *, debug_type, const char *, const char *,
- debug_type, const char *, boolean, boolean, const char **));
-static boolean parse_stab_tilde_field
- PARAMS ((PTR, struct stab_handle *, const char **, const int *,
- debug_type *, boolean *));
+ (void *, struct stab_handle *, debug_type, const char *, const char *,
+ debug_type, const char *, bfd_boolean, bfd_boolean, const char **);
+static bfd_boolean parse_stab_tilde_field
+ (void *, struct stab_handle *, const char **, const int *, debug_type *,
+ bfd_boolean *);
static debug_type parse_stab_array_type
- PARAMS ((PTR, struct stab_handle *, const char **, boolean));
-static void push_bincl PARAMS ((struct stab_handle *, const char *, bfd_vma));
-static const char *pop_bincl PARAMS ((struct stab_handle *));
-static boolean find_excl
- PARAMS ((struct stab_handle *, const char *, bfd_vma));
-static boolean stab_record_variable
- PARAMS ((PTR, struct stab_handle *, const char *, debug_type,
- enum debug_var_kind, bfd_vma));
-static boolean stab_emit_pending_vars PARAMS ((PTR, struct stab_handle *));
-static debug_type *stab_find_slot
- PARAMS ((struct stab_handle *, const int *));
-static debug_type stab_find_type
- PARAMS ((PTR, struct stab_handle *, const int *));
-static boolean stab_record_type
- PARAMS ((PTR, struct stab_handle *, const int *, debug_type));
+ (void *, struct stab_handle *, const char **, bfd_boolean);
+static void push_bincl (struct stab_handle *, const char *, bfd_vma);
+static const char *pop_bincl (struct stab_handle *);
+static bfd_boolean find_excl (struct stab_handle *, const char *, bfd_vma);
+static bfd_boolean stab_record_variable
+ (void *, struct stab_handle *, const char *, debug_type,
+ enum debug_var_kind, bfd_vma);
+static bfd_boolean stab_emit_pending_vars (void *, struct stab_handle *);
+static debug_type *stab_find_slot (struct stab_handle *, const int *);
+static debug_type stab_find_type (void *, struct stab_handle *, const int *);
+static bfd_boolean stab_record_type
+ (void *, struct stab_handle *, const int *, debug_type);
static debug_type stab_xcoff_builtin_type
- PARAMS ((PTR, struct stab_handle *, int));
+ (void *, struct stab_handle *, int);
static debug_type stab_find_tagged_type
- PARAMS ((PTR, struct stab_handle *, const char *, int,
- enum debug_type_kind));
+ (void *, struct stab_handle *, const char *, int, enum debug_type_kind);
static debug_type *stab_demangle_argtypes
- PARAMS ((PTR, struct stab_handle *, const char *, boolean *));
+ (void *, struct stab_handle *, const char *, bfd_boolean *, unsigned int);
+static debug_type *stab_demangle_v3_argtypes
+ (void *, struct stab_handle *, const char *, bfd_boolean *);
+static debug_type stab_demangle_v3_arg
+ (void *, struct stab_handle *, struct demangle_component *, debug_type,
+ bfd_boolean *);
/* Save a string in memory. */
static char *
-savestring (start, len)
- const char *start;
- int len;
+savestring (const char *start, int len)
{
char *ret;
@@ -233,15 +223,13 @@ savestring (start, len)
/* Read a number from a string. */
static bfd_vma
-parse_number (pp, poverflow)
- const char **pp;
- boolean *poverflow;
+parse_number (const char **pp, bfd_boolean *poverflow)
{
unsigned long ul;
const char *orig;
if (poverflow != NULL)
- *poverflow = false;
+ *poverflow = FALSE;
orig = *pp;
@@ -259,26 +247,24 @@ parse_number (pp, poverflow)
/* Note that even though strtoul overflowed, it should have set *pp
to the end of the number, which is where we want it. */
-
if (sizeof (bfd_vma) > sizeof (unsigned long))
{
const char *p;
- boolean neg;
+ bfd_boolean neg;
int base;
bfd_vma over, lastdig;
- boolean overflow;
+ bfd_boolean overflow;
bfd_vma v;
/* Our own version of strtoul, for a bfd_vma. */
-
p = orig;
- neg = false;
+ neg = FALSE;
if (*p == '+')
++p;
else if (*p == '-')
{
- neg = true;
+ neg = TRUE;
++p;
}
@@ -300,7 +286,7 @@ parse_number (pp, poverflow)
over = ((bfd_vma) (bfd_signed_vma) -1) / (bfd_vma) base;
lastdig = ((bfd_vma) (bfd_signed_vma) -1) % (bfd_vma) base;
- overflow = false;
+ overflow = FALSE;
v = 0;
while (1)
{
@@ -321,7 +307,7 @@ parse_number (pp, poverflow)
if (v > over || (v == over && (bfd_vma) d > lastdig))
{
- overflow = true;
+ overflow = TRUE;
break;
}
}
@@ -336,9 +322,8 @@ parse_number (pp, poverflow)
/* If we get here, the number is too large to represent in a
bfd_vma. */
-
if (poverflow != NULL)
- *poverflow = true;
+ *poverflow = TRUE;
else
warn_stab (orig, _("numeric overflow"));
@@ -348,8 +333,7 @@ parse_number (pp, poverflow)
/* Give an error for a bad stab string. */
static void
-bad_stab (p)
- const char *p;
+bad_stab (const char *p)
{
fprintf (stderr, _("Bad stab: %s\n"), p);
}
@@ -357,22 +341,16 @@ bad_stab (p)
/* Warn about something in a stab string. */
static void
-warn_stab (p, err)
- const char *p;
- const char *err;
+warn_stab (const char *p, const char *err)
{
fprintf (stderr, _("Warning: %s: %s\n"), err, p);
}
/* Create a handle to parse stabs symbols with. */
-PTR
-start_stab (dhandle, abfd, sections, syms, symcount)
- PTR dhandle ATTRIBUTE_UNUSED;
- bfd *abfd;
- boolean sections;
- asymbol **syms;
- long symcount;
+void *
+start_stab (void *dhandle ATTRIBUTE_UNUSED, bfd *abfd, bfd_boolean sections,
+ asymbol **syms, long symcount)
{
struct stab_handle *ret;
@@ -386,16 +364,14 @@ start_stab (dhandle, abfd, sections, syms, symcount)
ret->file_types = (struct stab_types **) xmalloc (sizeof *ret->file_types);
ret->file_types[0] = NULL;
ret->function_end = (bfd_vma) -1;
- return (PTR) ret;
+ return (void *) ret;
}
/* When we have processed all the stabs information, we need to go
through and fill in all the undefined tags. */
-boolean
-finish_stab (dhandle, handle)
- PTR dhandle;
- PTR handle;
+bfd_boolean
+finish_stab (void *dhandle, void *handle)
{
struct stab_handle *info = (struct stab_handle *) handle;
struct stab_tag *st;
@@ -404,8 +380,8 @@ finish_stab (dhandle, handle)
{
if (! stab_emit_pending_vars (dhandle, info)
|| ! debug_end_function (dhandle, info->function_end))
- return false;
- info->within_function = false;
+ return FALSE;
+ info->within_function = FALSE;
info->function_end = (bfd_vma) -1;
}
@@ -418,22 +394,17 @@ finish_stab (dhandle, handle)
kind = DEBUG_KIND_STRUCT;
st->slot = debug_make_undefined_tagged_type (dhandle, st->name, kind);
if (st->slot == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Handle a single stabs symbol. */
-boolean
-parse_stab (dhandle, handle, type, desc, value, string)
- PTR dhandle;
- PTR handle;
- int type;
- int desc;
- bfd_vma value;
- const char *string;
+bfd_boolean
+parse_stab (void *dhandle, void *handle, int type, int desc, bfd_vma value,
+ const char *string)
{
struct stab_handle *info = (struct stab_handle *) handle;
@@ -445,11 +416,11 @@ parse_stab (dhandle, handle, type, desc, value, string)
&& (type != N_SO || *string == '\0' || value != info->so_value))
{
if (! debug_set_filename (dhandle, info->so_string))
- return false;
+ return FALSE;
info->main_filename = info->so_string;
info->gcc_compiled = 0;
- info->n_opt_found = false;
+ info->n_opt_found = FALSE;
/* Generally, for stabs in the symbol table, the N_LBRAC and
N_RBRAC symbols are relative to the N_SO symbol value. */
@@ -483,7 +454,7 @@ parse_stab (dhandle, handle, type, desc, value, string)
if (! info->within_function)
{
fprintf (stderr, _("N_LBRAC not within function\n"));
- return false;
+ return FALSE;
}
/* Start an inner lexical block. */
@@ -491,11 +462,11 @@ parse_stab (dhandle, handle, type, desc, value, string)
(value
+ info->file_start_offset
+ info->function_start_offset)))
- return false;
+ return FALSE;
/* Emit any pending variable definitions. */
if (! stab_emit_pending_vars (dhandle, info))
- return false;
+ return FALSE;
++info->block_depth;
break;
@@ -509,20 +480,20 @@ parse_stab (dhandle, handle, type, desc, value, string)
if we do, we probably need to emit them before closing the
block. */
if (! stab_emit_pending_vars (dhandle, info))
- return false;
+ return FALSE;
/* End an inner lexical block. */
if (! debug_end_block (dhandle,
(value
+ info->file_start_offset
+ info->function_start_offset)))
- return false;
+ return FALSE;
--info->block_depth;
if (info->block_depth < 0)
{
fprintf (stderr, _("Too many N_RBRACs\n"));
- return false;
+ return FALSE;
}
break;
@@ -539,15 +510,15 @@ parse_stab (dhandle, handle, type, desc, value, string)
endval = info->function_end;
if (! stab_emit_pending_vars (dhandle, info)
|| ! debug_end_function (dhandle, endval))
- return false;
- info->within_function = false;
+ return FALSE;
+ info->within_function = FALSE;
info->function_end = (bfd_vma) -1;
}
/* An empty string is emitted by gcc at the end of a compilation
unit. */
if (*string == '\0')
- return true;
+ return TRUE;
/* Just accumulate strings until we see a non N_SO symbol. If
the string starts with a directory separator or some other
@@ -576,43 +547,44 @@ parse_stab (dhandle, handle, type, desc, value, string)
case N_SOL:
/* Start an include file. */
if (! debug_start_source (dhandle, string))
- return false;
+ return FALSE;
break;
case N_BINCL:
/* Start an include file which may be replaced. */
push_bincl (info, string, value);
if (! debug_start_source (dhandle, string))
- return false;
+ return FALSE;
break;
case N_EINCL:
/* End an N_BINCL include. */
if (! debug_start_source (dhandle, pop_bincl (info)))
- return false;
+ return FALSE;
break;
case N_EXCL:
/* This is a duplicate of a header file named by N_BINCL which
was eliminated by the linker. */
if (! find_excl (info, string, value))
- return false;
+ return FALSE;
break;
case N_SLINE:
if (! debug_record_line (dhandle, desc,
- value + info->function_start_offset))
- return false;
+ value + (info->within_function
+ ? info->function_start_offset : 0)))
+ return FALSE;
break;
case N_BCOMM:
if (! debug_start_common_block (dhandle, string))
- return false;
+ return FALSE;
break;
case N_ECOMM:
if (! debug_end_common_block (dhandle, string))
- return false;
+ return FALSE;
break;
case N_FUN:
@@ -626,8 +598,8 @@ parse_stab (dhandle, handle, type, desc, value, string)
value += info->function_start_offset;
if (! stab_emit_pending_vars (dhandle, info)
|| ! debug_end_function (dhandle, value))
- return false;
- info->within_function = false;
+ return FALSE;
+ info->within_function = FALSE;
info->function_end = (bfd_vma) -1;
}
break;
@@ -667,18 +639,18 @@ parse_stab (dhandle, handle, type, desc, value, string)
endval = info->function_end;
if (! stab_emit_pending_vars (dhandle, info)
|| ! debug_end_function (dhandle, endval))
- return false;
+ return FALSE;
info->function_end = (bfd_vma) -1;
}
/* For stabs in sections, line numbers and block addresses
are offsets from the start of the function. */
if (info->sections)
info->function_start_offset = value;
- info->within_function = true;
+ info->within_function = TRUE;
}
if (! parse_stab_string (dhandle, info, type, desc, value, string))
- return false;
+ return FALSE;
}
break;
@@ -688,7 +660,7 @@ parse_stab (dhandle, handle, type, desc, value, string)
else if (string != NULL && strcmp (string, "gcc_compiled.") == 0)
info->gcc_compiled = 1;
else
- info->n_opt_found = true;
+ info->n_opt_found = TRUE;
break;
case N_OBJ:
@@ -698,32 +670,27 @@ parse_stab (dhandle, handle, type, desc, value, string)
break;
}
- return true;
+ return TRUE;
}
/* Parse the stabs string. */
-static boolean
-parse_stab_string (dhandle, info, stabtype, desc, value, string)
- PTR dhandle;
- struct stab_handle *info;
- int stabtype;
- int desc;
- bfd_vma value;
- const char *string;
+static bfd_boolean
+parse_stab_string (void *dhandle, struct stab_handle *info, int stabtype,
+ int desc, bfd_vma value, const char *string)
{
const char *p;
char *name;
int type;
debug_type dtype;
- boolean synonym;
- boolean self_crossref;
+ bfd_boolean synonym;
+ bfd_boolean self_crossref;
unsigned int lineno;
debug_type *slot;
p = strchr (string, ':');
if (p == NULL)
- return true;
+ return TRUE;
while (p[1] == ':')
{
@@ -732,7 +699,7 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
if (p == NULL)
{
bad_stab (string);
- return false;
+ return FALSE;
}
}
@@ -797,7 +764,7 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
if (*p != '=')
{
bad_stab (string);
- return false;
+ return FALSE;
}
++p;
switch (*p++)
@@ -805,7 +772,7 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
case 'r':
/* Floating point constant. */
if (! debug_record_float_const (dhandle, name, atof (p)))
- return false;
+ return FALSE;
break;
case 'i':
/* Integer constant. */
@@ -816,7 +783,7 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
other languages probably should have at least unsigned as
well as signed constants. */
if (! debug_record_int_const (dhandle, name, atoi (p)))
- return false;
+ return FALSE;
break;
case 'e':
/* SYMBOL:c=eTYPE,INTVALUE for a constant symbol whose value
@@ -826,18 +793,18 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
dtype = parse_stab_type (dhandle, info, (const char *) NULL,
&p, (debug_type **) NULL);
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (*p != ',')
{
bad_stab (string);
- return false;
+ return FALSE;
}
if (! debug_record_typed_const (dhandle, name, dtype, atoi (p)))
- return false;
+ return FALSE;
break;
default:
bad_stab (string);
- return false;
+ return FALSE;
}
break;
@@ -847,9 +814,9 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
dtype = parse_stab_type (dhandle, info, (const char *) NULL,
&p, (debug_type **) NULL);
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (! debug_record_label (dhandle, name, dtype, value))
- return false;
+ return FALSE;
break;
case 'f':
@@ -858,9 +825,9 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
dtype = parse_stab_type (dhandle, info, (const char *) NULL, &p,
(debug_type **) NULL);
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (! debug_record_function (dhandle, name, dtype, type == 'F', value))
- return false;
+ return FALSE;
/* Sun acc puts declared types of arguments here. We don't care
about their actual types (FIXME -- we should remember the whole
@@ -872,7 +839,7 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
if (parse_stab_type (dhandle, info, (const char *) NULL, &p,
(debug_type **) NULL)
== DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
}
break;
@@ -888,7 +855,7 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
dtype = parse_stab_type (dhandle, info, (const char *) NULL, &p,
(debug_type **) NULL);
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
leading = bfd_get_symbol_leading_char (info->abfd);
for (c = info->symcount, ps = info->syms; c > 0; --c, ++ps)
{
@@ -904,7 +871,7 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
value = bfd_asymbol_value (*ps);
if (! stab_record_variable (dhandle, info, name, dtype, DEBUG_GLOBAL,
value))
- return false;
+ return FALSE;
}
break;
@@ -916,10 +883,10 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
dtype = parse_stab_type (dhandle, info, (const char *) NULL, &p,
(debug_type **) NULL);
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (! stab_record_variable (dhandle, info, name, dtype, DEBUG_LOCAL,
value))
- return false;
+ return FALSE;
break;
case 'p':
@@ -940,21 +907,20 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
debug_type ftype;
ftype = debug_make_function_type (dhandle, dtype,
- (debug_type *) NULL, false);
+ (debug_type *) NULL, FALSE);
dtype = debug_make_pointer_type (dhandle, ftype);
}
}
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (! debug_record_parameter (dhandle, name, dtype, DEBUG_PARM_STACK,
value))
- return false;
+ return FALSE;
/* FIXME: At this point gdb considers rearranging the parameter
address on a big endian machine if it is smaller than an int.
We have no way to do that, since we don't really know much
about the target. */
-
break;
case 'P':
@@ -967,7 +933,7 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
if (parse_stab_type (dhandle, info, (const char *) NULL, &p,
(debug_type **) NULL)
== DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
}
break;
}
@@ -977,10 +943,10 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
dtype = parse_stab_type (dhandle, info, (const char *) NULL, &p,
(debug_type **) NULL);
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (! debug_record_parameter (dhandle, name, dtype, DEBUG_PARM_REG,
value))
- return false;
+ return FALSE;
break;
case 'r':
@@ -988,41 +954,40 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
dtype = parse_stab_type (dhandle, info, (const char *) NULL, &p,
(debug_type **) NULL);
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (! stab_record_variable (dhandle, info, name, dtype, DEBUG_REGISTER,
value))
- return false;
+ return FALSE;
/* FIXME: At this point gdb checks to combine pairs of 'p' and
'r' stabs into a single 'P' stab. */
-
break;
case 'S':
- /* Static symbol at top level of file */
+ /* Static symbol at top level of file. */
dtype = parse_stab_type (dhandle, info, (const char *) NULL, &p,
(debug_type **) NULL);
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (! stab_record_variable (dhandle, info, name, dtype, DEBUG_STATIC,
value))
- return false;
+ return FALSE;
break;
case 't':
/* A typedef. */
dtype = parse_stab_type (dhandle, info, name, &p, &slot);
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (name == NULL)
{
/* A nameless type. Nothing to do. */
- return true;
+ return TRUE;
}
dtype = debug_name_type (dhandle, name, dtype);
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (slot != NULL)
*slot = dtype;
@@ -1034,21 +999,21 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
by 't' which means we are typedef'ing it as well. */
if (*p != 't')
{
- synonym = false;
- /* FIXME: gdb sets synonym to true if the current language
+ synonym = FALSE;
+ /* FIXME: gdb sets synonym to TRUE if the current language
is C++. */
}
else
{
- synonym = true;
+ synonym = TRUE;
++p;
}
dtype = parse_stab_type (dhandle, info, name, &p, &slot);
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (name == NULL)
- return true;
+ return TRUE;
/* INFO->SELF_CROSSREF is set by parse_stab_type if this type is
a cross reference to itself. These are generated by some
@@ -1057,7 +1022,7 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
dtype = debug_tag_type (dhandle, name, dtype);
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (slot != NULL)
*slot = dtype;
@@ -1084,7 +1049,7 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
{
dtype = debug_name_type (dhandle, name, dtype);
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (slot != NULL)
*slot = dtype;
@@ -1097,11 +1062,11 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
dtype = parse_stab_type (dhandle, info, (const char *) NULL, &p,
(debug_type **) NULL);
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
/* FIXME: gdb checks os9k_stabs here. */
if (! stab_record_variable (dhandle, info, name, dtype,
DEBUG_LOCAL_STATIC, value))
- return false;
+ return FALSE;
break;
case 'v':
@@ -1109,10 +1074,10 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
dtype = parse_stab_type (dhandle, info, (const char *) NULL, &p,
(debug_type **) NULL);
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (! debug_record_parameter (dhandle, name, dtype, DEBUG_PARM_REFERENCE,
value))
- return false;
+ return FALSE;
break;
case 'a':
@@ -1120,10 +1085,10 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
dtype = parse_stab_type (dhandle, info, (const char *) NULL, &p,
(debug_type **) NULL);
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (! debug_record_parameter (dhandle, name, dtype, DEBUG_PARM_REF_REG,
value))
- return false;
+ return FALSE;
break;
case 'X':
@@ -1134,21 +1099,21 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
dtype = parse_stab_type (dhandle, info, (const char *) NULL, &p,
(debug_type **) NULL);
if (dtype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (! stab_record_variable (dhandle, info, name, dtype, DEBUG_LOCAL,
value))
- return false;
+ return FALSE;
break;
default:
bad_stab (string);
- return false;
+ return FALSE;
}
/* FIXME: gdb converts structure values to structure pointers in a
couple of cases, depending upon the target. */
- return true;
+ return TRUE;
}
/* Parse a stabs type. The typename argument is non-NULL if this is a
@@ -1157,17 +1122,12 @@ parse_stab_string (dhandle, info, stabtype, desc, value, string)
store the slot used if the type is being defined. */
static debug_type
-parse_stab_type (dhandle, info, typename, pp, slotp)
- PTR dhandle;
- struct stab_handle *info;
- const char *typename;
- const char **pp;
- debug_type **slotp;
+parse_stab_type (void *dhandle, struct stab_handle *info, const char *typename, const char **pp, debug_type **slotp)
{
const char *orig;
int typenums[2];
int size;
- boolean stringp;
+ bfd_boolean stringp;
int descriptor;
debug_type dtype;
@@ -1177,9 +1137,9 @@ parse_stab_type (dhandle, info, typename, pp, slotp)
orig = *pp;
size = -1;
- stringp = false;
+ stringp = FALSE;
- info->self_crossref = false;
+ info->self_crossref = FALSE;
/* Read type number if present. The type number may be omitted.
for instance in a two-dimensional array declared with type
@@ -1196,11 +1156,9 @@ parse_stab_type (dhandle, info, typename, pp, slotp)
return DEBUG_TYPE_NULL;
if (**pp != '=')
- {
- /* Type is not being defined here. Either it already
- exists, or this is a forward reference to it. */
- return stab_find_type (dhandle, info, typenums);
- }
+ /* Type is not being defined here. Either it already
+ exists, or this is a forward reference to it. */
+ return stab_find_type (dhandle, info, typenums);
/* Only set the slot if the type is being defined. This means
that the mapping from type numbers to types will only record
@@ -1228,10 +1186,8 @@ parse_stab_type (dhandle, info, typename, pp, slotp)
const char *attr;
if (ISDIGIT (*p) || *p == '(' || *p == '-')
- {
- /* Member type. */
- break;
- }
+ /* Member type. */
+ break;
/* Type attributes. */
attr = p;
@@ -1256,7 +1212,7 @@ parse_stab_type (dhandle, info, typename, pp, slotp)
break;
case 'S':
- stringp = true;
+ stringp = TRUE;
break;
default:
@@ -1278,7 +1234,6 @@ parse_stab_type (dhandle, info, typename, pp, slotp)
const char *q1, *q2, *p;
/* A cross reference to another type. */
-
switch (**pp)
{
case 's':
@@ -1334,7 +1289,7 @@ parse_stab_type (dhandle, info, typename, pp, slotp)
if (typename != NULL
&& strncmp (typename, *pp, p - *pp) == 0
&& typename[p - *pp] == '\0')
- info->self_crossref = true;
+ info->self_crossref = TRUE;
dtype = stab_find_tagged_type (dhandle, info, *pp, p - *pp, code);
@@ -1359,7 +1314,6 @@ parse_stab_type (dhandle, info, typename, pp, slotp)
int xtypenums[2];
/* This type is defined as another type. */
-
(*pp)--;
hold = *pp;
@@ -1418,7 +1372,7 @@ parse_stab_type (dhandle, info, typename, pp, slotp)
(dhandle,
parse_stab_type (dhandle, info, (const char *) NULL, pp,
(debug_type **) NULL),
- (debug_type *) NULL, false));
+ (debug_type *) NULL, FALSE));
break;
case 'k':
@@ -1489,7 +1443,7 @@ parse_stab_type (dhandle, info, typename, pp, slotp)
++*pp;
dtype = debug_make_method_type (dhandle, return_type,
DEBUG_TYPE_NULL,
- (debug_type *) NULL, false);
+ (debug_type *) NULL, FALSE);
}
else
{
@@ -1498,7 +1452,7 @@ parse_stab_type (dhandle, info, typename, pp, slotp)
debug_type *args;
unsigned int n;
unsigned int alloc;
- boolean varargs;
+ bfd_boolean varargs;
domain = parse_stab_type (dhandle, info, (const char *) NULL,
pp, (debug_type **) NULL);
@@ -1533,7 +1487,7 @@ parse_stab_type (dhandle, info, typename, pp, slotp)
{
alloc += 10;
args = ((debug_type *)
- xrealloc ((PTR) args, alloc * sizeof *args));
+ xrealloc (args, alloc * sizeof *args));
}
args[n] = parse_stab_type (dhandle, info, (const char *) NULL,
@@ -1549,11 +1503,11 @@ parse_stab_type (dhandle, info, typename, pp, slotp)
the void type. */
if (n == 0
|| debug_get_type_kind (dhandle, args[n - 1]) != DEBUG_KIND_VOID)
- varargs = true;
+ varargs = TRUE;
else
{
--n;
- varargs = false;
+ varargs = FALSE;
}
args[n] = DEBUG_TYPE_NULL;
@@ -1640,10 +1594,8 @@ parse_stab_type (dhandle, info, typename, pp, slotp)
single number N is equivalent to (0,N). Return the two numbers by
storing them in the vector TYPENUMS. */
-static boolean
-parse_stab_type_number (pp, typenums)
- const char **pp;
- int *typenums;
+static bfd_boolean
+parse_stab_type_number (const char **pp, int *typenums)
{
const char *orig;
@@ -1652,47 +1604,42 @@ parse_stab_type_number (pp, typenums)
if (**pp != '(')
{
typenums[0] = 0;
- typenums[1] = (int) parse_number (pp, (boolean *) NULL);
+ typenums[1] = (int) parse_number (pp, (bfd_boolean *) NULL);
}
else
{
++*pp;
- typenums[0] = (int) parse_number (pp, (boolean *) NULL);
+ typenums[0] = (int) parse_number (pp, (bfd_boolean *) NULL);
if (**pp != ',')
{
bad_stab (orig);
- return false;
+ return FALSE;
}
++*pp;
- typenums[1] = (int) parse_number (pp, (boolean *) NULL);
+ typenums[1] = (int) parse_number (pp, (bfd_boolean *) NULL);
if (**pp != ')')
{
bad_stab (orig);
- return false;
+ return FALSE;
}
++*pp;
}
- return true;
+ return TRUE;
}
/* Parse a range type. */
static debug_type
-parse_stab_range_type (dhandle, info, typename, pp, typenums)
- PTR dhandle;
- struct stab_handle *info;
- const char *typename;
- const char **pp;
- const int *typenums;
+parse_stab_range_type (void *dhandle, struct stab_handle *info, const char *typename, const char **pp, const int *typenums)
{
const char *orig;
int rangenums[2];
- boolean self_subrange;
+ bfd_boolean self_subrange;
debug_type index_type;
const char *s2, *s3;
bfd_signed_vma n2, n3;
- boolean ov2, ov3;
+ bfd_boolean ov2, ov3;
orig = *pp;
@@ -1742,18 +1689,18 @@ parse_stab_range_type (dhandle, info, typename, pp, typenums)
{
/* gcc will emit range stabs for long long types. Handle this
as a special case. FIXME: This needs to be more general. */
-#define LLLOW "01000000000000000000000;"
-#define LLHIGH "0777777777777777777777;"
+#define LLLOW "01000000000000000000000;"
+#define LLHIGH "0777777777777777777777;"
#define ULLHIGH "01777777777777777777777;"
if (index_type == DEBUG_TYPE_NULL)
{
if (strncmp (s2, LLLOW, sizeof LLLOW - 1) == 0
&& strncmp (s3, LLHIGH, sizeof LLHIGH - 1) == 0)
- return debug_make_int_type (dhandle, 8, false);
+ return debug_make_int_type (dhandle, 8, FALSE);
if (! ov2
&& n2 == 0
&& strncmp (s3, ULLHIGH, sizeof ULLHIGH - 1) == 0)
- return debug_make_int_type (dhandle, 8, true);
+ return debug_make_int_type (dhandle, 8, TRUE);
}
warn_stab (orig, _("numeric overflow"));
@@ -1786,50 +1733,50 @@ parse_stab_range_type (dhandle, info, typename, pp, typenums)
if (typename != NULL)
{
if (strcmp (typename, "long long int") == 0)
- return debug_make_int_type (dhandle, 8, false);
+ return debug_make_int_type (dhandle, 8, FALSE);
else if (strcmp (typename, "long long unsigned int") == 0)
- return debug_make_int_type (dhandle, 8, true);
+ return debug_make_int_type (dhandle, 8, TRUE);
}
/* FIXME: The size here really depends upon the target. */
- return debug_make_int_type (dhandle, 4, true);
+ return debug_make_int_type (dhandle, 4, TRUE);
}
/* A range of 0 to 127 is char. */
if (self_subrange && n2 == 0 && n3 == 127)
- return debug_make_int_type (dhandle, 1, false);
+ return debug_make_int_type (dhandle, 1, FALSE);
/* FIXME: gdb checks for the language CHILL here. */
if (n2 == 0)
{
if (n3 < 0)
- return debug_make_int_type (dhandle, - n3, true);
+ return debug_make_int_type (dhandle, - n3, TRUE);
else if (n3 == 0xff)
- return debug_make_int_type (dhandle, 1, true);
+ return debug_make_int_type (dhandle, 1, TRUE);
else if (n3 == 0xffff)
- return debug_make_int_type (dhandle, 2, true);
+ return debug_make_int_type (dhandle, 2, TRUE);
else if (n3 == (bfd_signed_vma) 0xffffffff)
- return debug_make_int_type (dhandle, 4, true);
+ return debug_make_int_type (dhandle, 4, TRUE);
#ifdef BFD64
else if (n3 == ((((bfd_signed_vma) 0xffffffff) << 32) | 0xffffffff))
- return debug_make_int_type (dhandle, 8, true);
+ return debug_make_int_type (dhandle, 8, TRUE);
#endif
}
else if (n3 == 0
&& n2 < 0
&& (self_subrange || n2 == -8))
- return debug_make_int_type (dhandle, - n2, true);
+ return debug_make_int_type (dhandle, - n2, TRUE);
else if (n2 == - n3 - 1 || n2 == n3 + 1)
{
if (n3 == 0x7f)
- return debug_make_int_type (dhandle, 1, false);
+ return debug_make_int_type (dhandle, 1, FALSE);
else if (n3 == 0x7fff)
- return debug_make_int_type (dhandle, 2, false);
+ return debug_make_int_type (dhandle, 2, FALSE);
else if (n3 == 0x7fffffff)
- return debug_make_int_type (dhandle, 4, false);
+ return debug_make_int_type (dhandle, 4, FALSE);
#ifdef BFD64
else if (n3 == ((((bfd_vma) 0x7fffffff) << 32) | 0xffffffff))
- return debug_make_int_type (dhandle, 8, false);
+ return debug_make_int_type (dhandle, 8, FALSE);
#endif
}
}
@@ -1849,7 +1796,7 @@ parse_stab_range_type (dhandle, info, typename, pp, typenums)
/* Does this actually ever happen? Is that why we are worrying
about dealing with it rather than just calling error_type? */
warn_stab (orig, _("missing index type"));
- index_type = debug_make_int_type (dhandle, 4, false);
+ index_type = debug_make_int_type (dhandle, 4, FALSE);
}
return debug_make_range_type (dhandle, index_type, n2, n3);
@@ -1868,12 +1815,10 @@ parse_stab_range_type (dhandle, info, typename, pp, typenums)
FIXME. */
static debug_type
-parse_stab_sun_builtin_type (dhandle, pp)
- PTR dhandle;
- const char **pp;
+parse_stab_sun_builtin_type (void *dhandle, const char **pp)
{
const char *orig;
- boolean unsignedp;
+ bfd_boolean unsignedp;
bfd_vma bits;
orig = *pp;
@@ -1881,10 +1826,10 @@ parse_stab_sun_builtin_type (dhandle, pp)
switch (**pp)
{
case 's':
- unsignedp = false;
+ unsignedp = FALSE;
break;
case 'u':
- unsignedp = true;
+ unsignedp = TRUE;
break;
default:
bad_stab (orig);
@@ -1903,7 +1848,7 @@ parse_stab_sun_builtin_type (dhandle, pp)
by this type, except that unsigned short is 4 instead of 2.
Since this information is redundant with the third number,
we will ignore it. */
- (void) parse_number (pp, (boolean *) NULL);
+ (void) parse_number (pp, (bfd_boolean *) NULL);
if (**pp != ';')
{
bad_stab (orig);
@@ -1912,7 +1857,7 @@ parse_stab_sun_builtin_type (dhandle, pp)
++*pp;
/* The second number is always 0, so ignore it too. */
- (void) parse_number (pp, (boolean *) NULL);
+ (void) parse_number (pp, (bfd_boolean *) NULL);
if (**pp != ';')
{
bad_stab (orig);
@@ -1921,7 +1866,7 @@ parse_stab_sun_builtin_type (dhandle, pp)
++*pp;
/* The third number is the number of bits for this type. */
- bits = parse_number (pp, (boolean *) NULL);
+ bits = parse_number (pp, (bfd_boolean *) NULL);
/* The type *should* end with a semicolon. If it are embedded
in a larger type the semicolon may be the only way to know where
@@ -1941,9 +1886,7 @@ parse_stab_sun_builtin_type (dhandle, pp)
/* Parse a builtin floating type generated by the Sun compiler. */
static debug_type
-parse_stab_sun_floating_type (dhandle, pp)
- PTR dhandle;
- const char **pp;
+parse_stab_sun_floating_type (void *dhandle, const char **pp)
{
const char *orig;
bfd_vma details;
@@ -1953,7 +1896,7 @@ parse_stab_sun_floating_type (dhandle, pp)
/* The first number has more details about the type, for example
FN_COMPLEX. */
- details = parse_number (pp, (boolean *) NULL);
+ details = parse_number (pp, (bfd_boolean *) NULL);
if (**pp != ';')
{
bad_stab (orig);
@@ -1961,7 +1904,7 @@ parse_stab_sun_floating_type (dhandle, pp)
}
/* The second number is the number of bytes occupied by this type */
- bytes = parse_number (pp, (boolean *) NULL);
+ bytes = parse_number (pp, (bfd_boolean *) NULL);
if (**pp != ';')
{
bad_stab (orig);
@@ -1979,9 +1922,7 @@ parse_stab_sun_floating_type (dhandle, pp)
/* Handle an enum type. */
static debug_type
-parse_stab_enum_type (dhandle, pp)
- PTR dhandle;
- const char **pp;
+parse_stab_enum_type (void *dhandle, const char **pp)
{
const char *orig;
const char **names;
@@ -2022,7 +1963,7 @@ parse_stab_enum_type (dhandle, pp)
name = savestring (*pp, p - *pp);
*pp = p + 1;
- val = (bfd_signed_vma) parse_number (pp, (boolean *) NULL);
+ val = (bfd_signed_vma) parse_number (pp, (bfd_boolean *) NULL);
if (**pp != ',')
{
bad_stab (orig);
@@ -2034,9 +1975,9 @@ parse_stab_enum_type (dhandle, pp)
{
alloc += 10;
names = ((const char **)
- xrealloc ((PTR) names, alloc * sizeof *names));
+ xrealloc (names, alloc * sizeof *names));
values = ((bfd_signed_vma *)
- xrealloc ((PTR) values, alloc * sizeof *values));
+ xrealloc (values, alloc * sizeof *values));
}
names[n] = name;
@@ -2057,31 +1998,27 @@ parse_stab_enum_type (dhandle, pp)
describing the type.
PP points to a character pointer that points to the next unconsumed token
- in the the stabs string. For example, given stabs "A:T4=s4a:1,0,32;;",
+ in the stabs string. For example, given stabs "A:T4=s4a:1,0,32;;",
*PP will point to "4a:1,0,32;;". */
static debug_type
-parse_stab_struct_type (dhandle, info, tagname, pp, structp, typenums)
- PTR dhandle;
- struct stab_handle *info;
- const char *tagname;
- const char **pp;
- boolean structp;
- const int *typenums;
+parse_stab_struct_type (void *dhandle, struct stab_handle *info,
+ const char *tagname, const char **pp,
+ bfd_boolean structp, const int *typenums)
{
const char *orig;
bfd_vma size;
debug_baseclass *baseclasses;
debug_field *fields;
- boolean statics;
+ bfd_boolean statics;
debug_method *methods;
debug_type vptrbase;
- boolean ownvptr;
+ bfd_boolean ownvptr;
orig = *pp;
/* Get the size. */
- size = parse_number (pp, (boolean *) NULL);
+ size = parse_number (pp, (bfd_boolean *) NULL);
/* Get the other information. */
if (! parse_stab_baseclasses (dhandle, info, pp, &baseclasses)
@@ -2114,7 +2051,7 @@ parse_stab_struct_type (dhandle, info, tagname, pp, structp, typenums)
the type for the base class, and a terminating semicolon.
A typical example, with two base classes, would be "!2,020,19;0264,21;".
- ^^ ^ ^ ^ ^ ^ ^
+ ^^ ^ ^ ^ ^ ^ ^
Baseclass information marker __________________|| | | | | | |
Number of baseclasses __________________________| | | | | | |
Visibility specifiers (2) ________________________| | | | | |
@@ -2124,14 +2061,11 @@ parse_stab_struct_type (dhandle, info, tagname, pp, structp, typenums)
Offset in bits from start of class ________________________| |
Type number of base class ____________________________________|
- Return true for success, false for failure. */
+ Return TRUE for success, FALSE for failure. */
-static boolean
-parse_stab_baseclasses (dhandle, info, pp, retp)
- PTR dhandle;
- struct stab_handle *info;
- const char **pp;
- debug_baseclass **retp;
+static bfd_boolean
+parse_stab_baseclasses (void *dhandle, struct stab_handle *info,
+ const char **pp, debug_baseclass **retp)
{
const char *orig;
unsigned int c, i;
@@ -2144,16 +2078,16 @@ parse_stab_baseclasses (dhandle, info, pp, retp)
if (**pp != '!')
{
/* No base classes. */
- return true;
+ return TRUE;
}
++*pp;
- c = (unsigned int) parse_number (pp, (boolean *) NULL);
+ c = (unsigned int) parse_number (pp, (bfd_boolean *) NULL);
if (**pp != ',')
{
bad_stab (orig);
- return false;
+ return FALSE;
}
++*pp;
@@ -2161,7 +2095,7 @@ parse_stab_baseclasses (dhandle, info, pp, retp)
for (i = 0; i < c; i++)
{
- boolean virtual;
+ bfd_boolean virtual;
enum debug_visibility visibility;
bfd_vma bitpos;
debug_type type;
@@ -2169,14 +2103,14 @@ parse_stab_baseclasses (dhandle, info, pp, retp)
switch (**pp)
{
case '0':
- virtual = false;
+ virtual = FALSE;
break;
case '1':
- virtual = true;
+ virtual = TRUE;
break;
default:
warn_stab (orig, _("unknown virtual character for baseclass"));
- virtual = false;
+ virtual = FALSE;
break;
}
++*pp;
@@ -2202,26 +2136,26 @@ parse_stab_baseclasses (dhandle, info, pp, retp)
/* The remaining value is the bit offset of the portion of the
object corresponding to this baseclass. Always zero in the
absence of multiple inheritance. */
- bitpos = parse_number (pp, (boolean *) NULL);
+ bitpos = parse_number (pp, (bfd_boolean *) NULL);
if (**pp != ',')
{
bad_stab (orig);
- return false;
+ return FALSE;
}
++*pp;
type = parse_stab_type (dhandle, info, (const char *) NULL, pp,
(debug_type **) NULL);
if (type == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
classes[i] = debug_make_baseclass (dhandle, type, bitpos, virtual,
visibility);
if (classes[i] == DEBUG_BASECLASS_NULL)
- return false;
+ return FALSE;
if (**pp != ';')
- return false;
+ return FALSE;
++*pp;
}
@@ -2229,12 +2163,12 @@ parse_stab_baseclasses (dhandle, info, pp, retp)
*retp = classes;
- return true;
+ return TRUE;
}
/* Read struct or class data fields. They have the form:
- NAME : [VISIBILITY] TYPENUM , BITPOS , BITSIZE ;
+ NAME : [VISIBILITY] TYPENUM , BITPOS , BITSIZE ;
At the end, we see a semicolon instead of a field.
@@ -2243,7 +2177,7 @@ parse_stab_baseclasses (dhandle, info, pp, retp)
The optional VISIBILITY is one of:
- '/0' (VISIBILITY_PRIVATE)
+ '/0' (VISIBILITY_PRIVATE)
'/1' (VISIBILITY_PROTECTED)
'/2' (VISIBILITY_PUBLIC)
'/9' (VISIBILITY_IGNORE)
@@ -2252,13 +2186,10 @@ parse_stab_baseclasses (dhandle, info, pp, retp)
Returns 1 for success, 0 for failure. */
-static boolean
-parse_stab_struct_fields (dhandle, info, pp, retp, staticsp)
- PTR dhandle;
- struct stab_handle *info;
- const char **pp;
- debug_field **retp;
- boolean *staticsp;
+static bfd_boolean
+parse_stab_struct_fields (void *dhandle, struct stab_handle *info,
+ const char **pp, debug_field **retp,
+ bfd_boolean *staticsp)
{
const char *orig;
const char *p;
@@ -2267,7 +2198,7 @@ parse_stab_struct_fields (dhandle, info, pp, retp, staticsp)
unsigned int alloc;
*retp = NULL;
- *staticsp = false;
+ *staticsp = FALSE;
orig = *pp;
@@ -2285,7 +2216,7 @@ parse_stab_struct_fields (dhandle, info, pp, retp, staticsp)
{
alloc += 10;
fields = ((debug_field *)
- xrealloc ((PTR) fields, alloc * sizeof *fields));
+ xrealloc (fields, alloc * sizeof *fields));
}
/* If it starts with CPLUS_MARKER it is a special abbreviation,
@@ -2299,7 +2230,7 @@ parse_stab_struct_fields (dhandle, info, pp, retp, staticsp)
{
++*pp;
if (! parse_stab_cpp_abbrev (dhandle, info, pp, fields + c))
- return false;
+ return FALSE;
++c;
continue;
}
@@ -2313,7 +2244,7 @@ parse_stab_struct_fields (dhandle, info, pp, retp, staticsp)
if (p == NULL)
{
bad_stab (orig);
- return false;
+ return FALSE;
}
if (p[1] == ':')
@@ -2321,7 +2252,7 @@ parse_stab_struct_fields (dhandle, info, pp, retp, staticsp)
if (! parse_stab_one_struct_field (dhandle, info, pp, p, fields + c,
staticsp))
- return false;
+ return FALSE;
++c;
}
@@ -2330,17 +2261,14 @@ parse_stab_struct_fields (dhandle, info, pp, retp, staticsp)
*retp = fields;
- return true;
+ return TRUE;
}
/* Special GNU C++ name. */
-static boolean
-parse_stab_cpp_abbrev (dhandle, info, pp, retp)
- PTR dhandle;
- struct stab_handle *info;
- const char **pp;
- debug_field *retp;
+static bfd_boolean
+parse_stab_cpp_abbrev (void *dhandle, struct stab_handle *info,
+ const char **pp, debug_field *retp)
{
const char *orig;
int cpp_abbrev;
@@ -2357,7 +2285,7 @@ parse_stab_cpp_abbrev (dhandle, info, pp, retp)
if (**pp != 'v')
{
bad_stab (*pp);
- return false;
+ return FALSE;
}
++*pp;
@@ -2372,7 +2300,7 @@ parse_stab_cpp_abbrev (dhandle, info, pp, retp)
context = parse_stab_type (dhandle, info, (const char *) NULL, pp,
(debug_type **) NULL);
if (context == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
switch (cpp_abbrev)
{
@@ -2399,7 +2327,7 @@ parse_stab_cpp_abbrev (dhandle, info, pp, retp)
if (**pp != ':')
{
bad_stab (orig);
- return false;
+ return FALSE;
}
++*pp;
@@ -2408,36 +2336,32 @@ parse_stab_cpp_abbrev (dhandle, info, pp, retp)
if (**pp != ',')
{
bad_stab (orig);
- return false;
+ return FALSE;
}
++*pp;
- bitpos = parse_number (pp, (boolean *) NULL);
+ bitpos = parse_number (pp, (bfd_boolean *) NULL);
if (**pp != ';')
{
bad_stab (orig);
- return false;
+ return FALSE;
}
++*pp;
*retp = debug_make_field (dhandle, name, type, bitpos, 0,
DEBUG_VISIBILITY_PRIVATE);
if (*retp == DEBUG_FIELD_NULL)
- return false;
+ return FALSE;
- return true;
+ return TRUE;
}
/* Parse a single field in a struct or union. */
-static boolean
-parse_stab_one_struct_field (dhandle, info, pp, p, retp, staticsp)
- PTR dhandle;
- struct stab_handle *info;
- const char **pp;
- const char *p;
- debug_field *retp;
- boolean *staticsp;
+static bfd_boolean
+parse_stab_one_struct_field (void *dhandle, struct stab_handle *info,
+ const char **pp, const char *p,
+ debug_field *retp, bfd_boolean *staticsp)
{
const char *orig;
char *name;
@@ -2481,7 +2405,7 @@ parse_stab_one_struct_field (dhandle, info, pp, p, retp, staticsp)
type = parse_stab_type (dhandle, info, (const char *) NULL, pp,
(debug_type **) NULL);
if (type == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (**pp == ':')
{
@@ -2493,7 +2417,7 @@ parse_stab_one_struct_field (dhandle, info, pp, p, retp, staticsp)
if (p == NULL)
{
bad_stab (orig);
- return false;
+ return FALSE;
}
varname = savestring (*pp, p - *pp);
@@ -2502,31 +2426,31 @@ parse_stab_one_struct_field (dhandle, info, pp, p, retp, staticsp)
*retp = debug_make_static_member (dhandle, name, type, varname,
visibility);
- *staticsp = true;
+ *staticsp = TRUE;
- return true;
+ return TRUE;
}
if (**pp != ',')
{
bad_stab (orig);
- return false;
+ return FALSE;
}
++*pp;
- bitpos = parse_number (pp, (boolean *) NULL);
+ bitpos = parse_number (pp, (bfd_boolean *) NULL);
if (**pp != ',')
{
bad_stab (orig);
- return false;
+ return FALSE;
}
++*pp;
- bitsize = parse_number (pp, (boolean *) NULL);
+ bitsize = parse_number (pp, (bfd_boolean *) NULL);
if (**pp != ';')
{
bad_stab (orig);
- return false;
+ return FALSE;
}
++*pp;
@@ -2552,7 +2476,7 @@ parse_stab_one_struct_field (dhandle, info, pp, p, retp, staticsp)
*retp = debug_make_field (dhandle, name, type, bitpos, bitsize, visibility);
- return true;
+ return TRUE;
}
/* Read member function stabs info for C++ classes. The form of each member
@@ -2568,14 +2492,10 @@ parse_stab_one_struct_field (dhandle, info, pp, p, retp, staticsp)
$ is the CPLUS_MARKER (usually '$'), `*' holds the place for an operator
name (such as `+=') and `.' marks the end of the operator name. */
-static boolean
-parse_stab_members (dhandle, info, tagname, pp, typenums, retp)
- PTR dhandle;
- struct stab_handle *info;
- const char *tagname;
- const char **pp;
- const int *typenums;
- debug_method **retp;
+static bfd_boolean
+parse_stab_members (void *dhandle, struct stab_handle *info,
+ const char *tagname, const char **pp,
+ const int *typenums, debug_method **retp)
{
const char *orig;
debug_method *methods;
@@ -2611,7 +2531,7 @@ parse_stab_members (dhandle, info, tagname, pp, typenums, retp)
}
else
{
- /* This is a completely wierd case. In order to stuff in the
+ /* This is a completely weird case. In order to stuff in the
names that might contain colons (the usual name delimiter),
Mike Tiemann defined a different name format which is
signalled if the identifier is "op$". In that case, the
@@ -2623,7 +2543,7 @@ parse_stab_members (dhandle, info, tagname, pp, typenums, retp)
if (*p != '.')
{
bad_stab (orig);
- return false;
+ return FALSE;
}
name = savestring (*pp, p - *pp);
*pp = p + 1;
@@ -2639,14 +2559,14 @@ parse_stab_members (dhandle, info, tagname, pp, typenums, retp)
do
{
debug_type type;
- boolean stub;
+ bfd_boolean stub;
char *argtypes;
enum debug_visibility visibility;
- boolean constp, volatilep, staticp;
+ bfd_boolean constp, volatilep, staticp;
bfd_vma voffset;
debug_type context;
const char *physname;
- boolean varargs;
+ bfd_boolean varargs;
if (look_ahead_type != DEBUG_TYPE_NULL)
{
@@ -2659,11 +2579,11 @@ parse_stab_members (dhandle, info, tagname, pp, typenums, retp)
type = parse_stab_type (dhandle, info, (const char *) NULL, pp,
(debug_type **) NULL);
if (type == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (**pp != ':')
{
bad_stab (orig);
- return false;
+ return FALSE;
}
}
@@ -2672,13 +2592,13 @@ parse_stab_members (dhandle, info, tagname, pp, typenums, retp)
if (p == NULL)
{
bad_stab (orig);
- return false;
+ return FALSE;
}
- stub = false;
+ stub = FALSE;
if (debug_get_type_kind (dhandle, type) == DEBUG_KIND_METHOD
&& debug_get_parameter_types (dhandle, type, &varargs) == NULL)
- stub = true;
+ stub = TRUE;
argtypes = savestring (*pp, p - *pp);
*pp = p + 1;
@@ -2697,8 +2617,8 @@ parse_stab_members (dhandle, info, tagname, pp, typenums, retp)
}
++*pp;
- constp = false;
- volatilep = false;
+ constp = FALSE;
+ volatilep = FALSE;
switch (**pp)
{
case 'A':
@@ -2707,18 +2627,18 @@ parse_stab_members (dhandle, info, tagname, pp, typenums, retp)
break;
case 'B':
/* const member function. */
- constp = true;
+ constp = TRUE;
++*pp;
break;
case 'C':
/* volatile member function. */
- volatilep = true;
+ volatilep = TRUE;
++*pp;
break;
case 'D':
/* const volatile member function. */
- constp = true;
- volatilep = true;
+ constp = TRUE;
+ volatilep = TRUE;
++*pp;
break;
case '*':
@@ -2731,7 +2651,7 @@ parse_stab_members (dhandle, info, tagname, pp, typenums, retp)
break;
}
- staticp = false;
+ staticp = FALSE;
switch (**pp)
{
case '*':
@@ -2739,11 +2659,11 @@ parse_stab_members (dhandle, info, tagname, pp, typenums, retp)
bit is supposedly set to distinguish
pointers-to-methods from virtual function indicies. */
++*pp;
- voffset = parse_number (pp, (boolean *) NULL);
+ voffset = parse_number (pp, (bfd_boolean *) NULL);
if (**pp != ';')
{
bad_stab (orig);
- return false;
+ return FALSE;
}
++*pp;
voffset &= 0x7fffffff;
@@ -2774,7 +2694,7 @@ parse_stab_members (dhandle, info, tagname, pp, typenums, retp)
if (**pp != ';')
{
bad_stab (orig);
- return false;
+ return FALSE;
}
++*pp;
}
@@ -2784,11 +2704,11 @@ parse_stab_members (dhandle, info, tagname, pp, typenums, retp)
case '?':
/* static member function. */
++*pp;
- staticp = true;
+ staticp = TRUE;
voffset = 0;
context = DEBUG_TYPE_NULL;
if (strncmp (argtypes, name, strlen (name)) != 0)
- stub = true;
+ stub = TRUE;
break;
default:
@@ -2817,25 +2737,25 @@ parse_stab_members (dhandle, info, tagname, pp, typenums, retp)
class_type = stab_find_type (dhandle, info, typenums);
if (class_type == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
return_type = debug_get_return_type (dhandle, type);
if (return_type == DEBUG_TYPE_NULL)
{
bad_stab (orig);
- return false;
+ return FALSE;
}
type = parse_stab_argtypes (dhandle, info, class_type, name,
tagname, return_type, argtypes,
constp, volatilep, &physname);
if (type == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
}
if (cvars + 1 >= allocvars)
{
allocvars += 10;
variants = ((debug_method_variant *)
- xrealloc ((PTR) variants,
+ xrealloc (variants,
allocvars * sizeof *variants));
}
@@ -2852,7 +2772,7 @@ parse_stab_members (dhandle, info, tagname, pp, typenums, retp)
constp,
volatilep);
if (variants[cvars] == DEBUG_METHOD_VARIANT_NULL)
- return false;
+ return FALSE;
++cvars;
}
@@ -2867,7 +2787,7 @@ parse_stab_members (dhandle, info, tagname, pp, typenums, retp)
{
alloc += 10;
methods = ((debug_method *)
- xrealloc ((PTR) methods, alloc * sizeof *methods));
+ xrealloc (methods, alloc * sizeof *methods));
}
methods[c] = debug_make_method (dhandle, name, variants);
@@ -2880,7 +2800,7 @@ parse_stab_members (dhandle, info, tagname, pp, typenums, retp)
*retp = methods;
- return true;
+ return TRUE;
}
/* Parse a string representing argument types for a method. Stabs
@@ -2890,24 +2810,19 @@ parse_stab_members (dhandle, info, tagname, pp, typenums, retp)
the tag name. */
static debug_type
-parse_stab_argtypes (dhandle, info, class_type, fieldname, tagname,
- return_type, argtypes, constp, volatilep, pphysname)
- PTR dhandle;
- struct stab_handle *info;
- debug_type class_type;
- const char *fieldname;
- const char *tagname;
- debug_type return_type;
- const char *argtypes;
- boolean constp;
- boolean volatilep;
- const char **pphysname;
+parse_stab_argtypes (void *dhandle, struct stab_handle *info,
+ debug_type class_type, const char *fieldname,
+ const char *tagname, debug_type return_type,
+ const char *argtypes, bfd_boolean constp,
+ bfd_boolean volatilep, const char **pphysname)
{
- boolean is_full_physname_constructor;
- boolean is_constructor;
- boolean is_destructor;
+ bfd_boolean is_full_physname_constructor;
+ bfd_boolean is_constructor;
+ bfd_boolean is_destructor;
+ bfd_boolean is_v3;
debug_type *args;
- boolean varargs;
+ bfd_boolean varargs;
+ unsigned int physname_len = 0;
/* Constructors are sometimes handled specially. */
is_full_physname_constructor = ((argtypes[0] == '_'
@@ -2924,8 +2839,9 @@ parse_stab_argtypes (dhandle, info, class_type, fieldname, tagname,
&& (argtypes[1] == '$' || argtypes[1] == '.')
&& argtypes[2] == '_')
|| strncmp (argtypes, "__dt", 4) == 0);
+ is_v3 = argtypes[0] == '_' && argtypes[1] == 'Z';
- if (is_destructor || is_full_physname_constructor)
+ if (is_destructor || is_full_physname_constructor || is_v3)
*pphysname = argtypes;
else
{
@@ -2984,6 +2900,7 @@ parse_stab_argtypes (dhandle, info, class_type, fieldname, tagname,
strcpy (physname, fieldname);
}
+ physname_len = strlen (physname);
strcat (physname, buf);
if (tagname != NULL)
strcat (physname, tagname);
@@ -2997,10 +2914,10 @@ parse_stab_argtypes (dhandle, info, class_type, fieldname, tagname,
args = (debug_type *) xmalloc (sizeof *args);
*args = NULL;
return debug_make_method_type (dhandle, return_type, class_type, args,
- false);
+ FALSE);
}
- args = stab_demangle_argtypes (dhandle, info, *pphysname, &varargs);
+ args = stab_demangle_argtypes (dhandle, info, *pphysname, &varargs, physname_len);
if (args == NULL)
return DEBUG_TYPE_NULL;
@@ -3016,21 +2933,17 @@ parse_stab_argtypes (dhandle, info, class_type, fieldname, tagname,
This function is called when we have parsed all the method declarations,
so we can look for the vptr base class info. */
-static boolean
-parse_stab_tilde_field (dhandle, info, pp, typenums, retvptrbase, retownvptr)
- PTR dhandle;
- struct stab_handle *info;
- const char **pp;
- const int *typenums;
- debug_type *retvptrbase;
- boolean *retownvptr;
+static bfd_boolean
+parse_stab_tilde_field (void *dhandle, struct stab_handle *info,
+ const char **pp, const int *typenums,
+ debug_type *retvptrbase, bfd_boolean *retownvptr)
{
const char *orig;
const char *hold;
int vtypenums[2];
*retvptrbase = DEBUG_TYPE_NULL;
- *retownvptr = false;
+ *retownvptr = FALSE;
orig = *pp;
@@ -3039,7 +2952,7 @@ parse_stab_tilde_field (dhandle, info, pp, typenums, retvptrbase, retownvptr)
++*pp;
if (**pp != '~')
- return true;
+ return TRUE;
++*pp;
@@ -3051,7 +2964,7 @@ parse_stab_tilde_field (dhandle, info, pp, typenums, retvptrbase, retownvptr)
}
if (**pp != '%')
- return true;
+ return TRUE;
++*pp;
@@ -3060,11 +2973,11 @@ parse_stab_tilde_field (dhandle, info, pp, typenums, retvptrbase, retownvptr)
/* The next number is the type number of the base class (possibly
our own class) which supplies the vtable for this class. */
if (! parse_stab_type_number (pp, vtypenums))
- return false;
+ return FALSE;
if (vtypenums[0] == typenums[0]
&& vtypenums[1] == typenums[1])
- *retownvptr = true;
+ *retownvptr = TRUE;
else
{
debug_type vtype;
@@ -3079,7 +2992,7 @@ parse_stab_tilde_field (dhandle, info, pp, typenums, retvptrbase, retownvptr)
if (*p != ';')
{
bad_stab (orig);
- return false;
+ return FALSE;
}
*retvptrbase = vtype;
@@ -3087,23 +3000,20 @@ parse_stab_tilde_field (dhandle, info, pp, typenums, retvptrbase, retownvptr)
*pp = p + 1;
}
- return true;
+ return TRUE;
}
/* Read a definition of an array type. */
static debug_type
-parse_stab_array_type (dhandle, info, pp, stringp)
- PTR dhandle;
- struct stab_handle *info;
- const char **pp;
- boolean stringp;
+parse_stab_array_type (void *dhandle, struct stab_handle *info,
+ const char **pp, bfd_boolean stringp)
{
const char *orig;
const char *p;
int typenums[2];
debug_type index_type;
- boolean adjustable;
+ bfd_boolean adjustable;
bfd_signed_vma lower, upper;
debug_type element_type;
@@ -3127,7 +3037,7 @@ parse_stab_array_type (dhandle, info, pp, stringp)
index_type = debug_find_named_type (dhandle, "int");
if (index_type == DEBUG_TYPE_NULL)
{
- index_type = debug_make_int_type (dhandle, 4, false);
+ index_type = debug_make_int_type (dhandle, 4, FALSE);
if (index_type == DEBUG_TYPE_NULL)
return DEBUG_TYPE_NULL;
}
@@ -3146,15 +3056,15 @@ parse_stab_array_type (dhandle, info, pp, stringp)
}
++*pp;
- adjustable = false;
+ adjustable = FALSE;
if (! ISDIGIT (**pp) && **pp != '-')
{
++*pp;
- adjustable = true;
+ adjustable = TRUE;
}
- lower = (bfd_signed_vma) parse_number (pp, (boolean *) NULL);
+ lower = (bfd_signed_vma) parse_number (pp, (bfd_boolean *) NULL);
if (**pp != ';')
{
bad_stab (orig);
@@ -3165,10 +3075,10 @@ parse_stab_array_type (dhandle, info, pp, stringp)
if (! ISDIGIT (**pp) && **pp != '-')
{
++*pp;
- adjustable = true;
+ adjustable = TRUE;
}
- upper = (bfd_signed_vma) parse_number (pp, (boolean *) NULL);
+ upper = (bfd_signed_vma) parse_number (pp, (bfd_boolean *) NULL);
if (**pp != ';')
{
bad_stab (orig);
@@ -3213,10 +3123,7 @@ struct bincl_file
/* Start a new N_BINCL file, pushing it onto the stack. */
static void
-push_bincl (info, name, hash)
- struct stab_handle *info;
- const char *name;
- bfd_vma hash;
+push_bincl (struct stab_handle *info, const char *name, bfd_vma hash)
{
struct bincl_file *n;
@@ -3232,7 +3139,7 @@ push_bincl (info, name, hash)
++info->files;
info->file_types = ((struct stab_types **)
- xrealloc ((PTR) info->file_types,
+ xrealloc (info->file_types,
(info->files
* sizeof *info->file_types)));
info->file_types[n->file] = NULL;
@@ -3242,8 +3149,7 @@ push_bincl (info, name, hash)
stack. */
static const char *
-pop_bincl (info)
- struct stab_handle *info;
+pop_bincl (struct stab_handle *info)
{
struct bincl_file *o;
@@ -3261,17 +3167,14 @@ pop_bincl (info)
/* Handle an N_EXCL: get the types from the corresponding N_BINCL. */
-static boolean
-find_excl (info, name, hash)
- struct stab_handle *info;
- const char *name;
- bfd_vma hash;
+static bfd_boolean
+find_excl (struct stab_handle *info, const char *name, bfd_vma hash)
{
struct bincl_file *l;
++info->files;
info->file_types = ((struct stab_types **)
- xrealloc ((PTR) info->file_types,
+ xrealloc (info->file_types,
(info->files
* sizeof *info->file_types)));
@@ -3282,12 +3185,12 @@ find_excl (info, name, hash)
{
warn_stab (name, _("Undefined N_EXCL"));
info->file_types[info->files - 1] = NULL;
- return true;
+ return TRUE;
}
info->file_types[info->files - 1] = l->file_types;
- return true;
+ return TRUE;
}
/* Handle a variable definition. gcc emits variable definitions for a
@@ -3295,14 +3198,10 @@ find_excl (info, name, hash)
it. The SunPRO compiler emits variable definitions after the
N_LBRAC, so we can call debug_record_variable immediately. */
-static boolean
-stab_record_variable (dhandle, info, name, type, kind, val)
- PTR dhandle;
- struct stab_handle *info;
- const char *name;
- debug_type type;
- enum debug_var_kind kind;
- bfd_vma val;
+static bfd_boolean
+stab_record_variable (void *dhandle, struct stab_handle *info,
+ const char *name, debug_type type,
+ enum debug_var_kind kind, bfd_vma val)
{
struct stab_pending_var *v;
@@ -3321,16 +3220,14 @@ stab_record_variable (dhandle, info, name, type, kind, val)
v->val = val;
info->pending = v;
- return true;
+ return TRUE;
}
/* Emit pending variable definitions. This is called after we see the
N_LBRAC that starts the block. */
-static boolean
-stab_emit_pending_vars (dhandle, info)
- PTR dhandle;
- struct stab_handle *info;
+static bfd_boolean
+stab_emit_pending_vars (void *dhandle, struct stab_handle *info)
{
struct stab_pending_var *v;
@@ -3340,7 +3237,7 @@ stab_emit_pending_vars (dhandle, info)
struct stab_pending_var *next;
if (! debug_record_variable (dhandle, v->name, v->type, v->kind, v->val))
- return false;
+ return FALSE;
next = v->next;
free (v);
@@ -3349,15 +3246,13 @@ stab_emit_pending_vars (dhandle, info)
info->pending = NULL;
- return true;
+ return TRUE;
}
/* Find the slot for a type in the database. */
static debug_type *
-stab_find_slot (info, typenums)
- struct stab_handle *info;
- const int *typenums;
+stab_find_slot (struct stab_handle *info, const int *typenums)
{
int filenum;
int index;
@@ -3402,10 +3297,7 @@ stab_find_slot (info, typenums)
allocated yet, create an indirect type. */
static debug_type
-stab_find_type (dhandle, info, typenums)
- PTR dhandle;
- struct stab_handle *info;
- const int *typenums;
+stab_find_type (void *dhandle, struct stab_handle *info, const int *typenums)
{
debug_type *slot;
@@ -3427,33 +3319,28 @@ stab_find_type (dhandle, info, typenums)
/* Record that a given type number refers to a given type. */
-static boolean
-stab_record_type (dhandle, info, typenums, type)
- PTR dhandle ATTRIBUTE_UNUSED;
- struct stab_handle *info;
- const int *typenums;
- debug_type type;
+static bfd_boolean
+stab_record_type (void *dhandle ATTRIBUTE_UNUSED, struct stab_handle *info,
+ const int *typenums, debug_type type)
{
debug_type *slot;
slot = stab_find_slot (info, typenums);
if (slot == NULL)
- return false;
+ return FALSE;
/* gdb appears to ignore type redefinitions, so we do as well. */
*slot = type;
- return true;
+ return TRUE;
}
/* Return an XCOFF builtin type. */
static debug_type
-stab_xcoff_builtin_type (dhandle, info, typenum)
- PTR dhandle;
- struct stab_handle *info;
- int typenum;
+stab_xcoff_builtin_type (void *dhandle, struct stab_handle *info,
+ int typenum)
{
debug_type rettype;
const char *name;
@@ -3472,42 +3359,42 @@ stab_xcoff_builtin_type (dhandle, info, typenum)
/* The size of this and all the other types are fixed, defined
by the debugging format. */
name = "int";
- rettype = debug_make_int_type (dhandle, 4, false);
+ rettype = debug_make_int_type (dhandle, 4, FALSE);
break;
case 2:
name = "char";
- rettype = debug_make_int_type (dhandle, 1, false);
+ rettype = debug_make_int_type (dhandle, 1, FALSE);
break;
case 3:
name = "short";
- rettype = debug_make_int_type (dhandle, 2, false);
+ rettype = debug_make_int_type (dhandle, 2, FALSE);
break;
case 4:
name = "long";
- rettype = debug_make_int_type (dhandle, 4, false);
+ rettype = debug_make_int_type (dhandle, 4, FALSE);
break;
case 5:
name = "unsigned char";
- rettype = debug_make_int_type (dhandle, 1, true);
+ rettype = debug_make_int_type (dhandle, 1, TRUE);
break;
case 6:
name = "signed char";
- rettype = debug_make_int_type (dhandle, 1, false);
+ rettype = debug_make_int_type (dhandle, 1, FALSE);
break;
case 7:
name = "unsigned short";
- rettype = debug_make_int_type (dhandle, 2, true);
+ rettype = debug_make_int_type (dhandle, 2, TRUE);
break;
case 8:
name = "unsigned int";
- rettype = debug_make_int_type (dhandle, 4, true);
+ rettype = debug_make_int_type (dhandle, 4, TRUE);
break;
case 9:
name = "unsigned";
- rettype = debug_make_int_type (dhandle, 4, true);
+ rettype = debug_make_int_type (dhandle, 4, TRUE);
case 10:
name = "unsigned long";
- rettype = debug_make_int_type (dhandle, 4, true);
+ rettype = debug_make_int_type (dhandle, 4, TRUE);
break;
case 11:
name = "void";
@@ -3532,7 +3419,7 @@ stab_xcoff_builtin_type (dhandle, info, typenum)
break;
case 15:
name = "integer";
- rettype = debug_make_int_type (dhandle, 4, false);
+ rettype = debug_make_int_type (dhandle, 4, FALSE);
break;
case 16:
name = "boolean";
@@ -3554,7 +3441,7 @@ stab_xcoff_builtin_type (dhandle, info, typenum)
case 20:
/* FIXME */
name = "character";
- rettype = debug_make_int_type (dhandle, 1, true);
+ rettype = debug_make_int_type (dhandle, 1, TRUE);
break;
case 21:
name = "logical*1";
@@ -3584,28 +3471,28 @@ stab_xcoff_builtin_type (dhandle, info, typenum)
break;
case 27:
name = "integer*1";
- rettype = debug_make_int_type (dhandle, 1, false);
+ rettype = debug_make_int_type (dhandle, 1, FALSE);
break;
case 28:
name = "integer*2";
- rettype = debug_make_int_type (dhandle, 2, false);
+ rettype = debug_make_int_type (dhandle, 2, FALSE);
break;
case 29:
name = "integer*4";
- rettype = debug_make_int_type (dhandle, 4, false);
+ rettype = debug_make_int_type (dhandle, 4, FALSE);
break;
case 30:
/* FIXME */
name = "wchar";
- rettype = debug_make_int_type (dhandle, 2, false);
+ rettype = debug_make_int_type (dhandle, 2, FALSE);
break;
case 31:
name = "long long";
- rettype = debug_make_int_type (dhandle, 8, false);
+ rettype = debug_make_int_type (dhandle, 8, FALSE);
break;
case 32:
name = "unsigned long long";
- rettype = debug_make_int_type (dhandle, 8, true);
+ rettype = debug_make_int_type (dhandle, 8, TRUE);
break;
case 33:
name = "logical*8";
@@ -3613,7 +3500,7 @@ stab_xcoff_builtin_type (dhandle, info, typenum)
break;
case 34:
name = "integer*8";
- rettype = debug_make_int_type (dhandle, 8, false);
+ rettype = debug_make_int_type (dhandle, 8, FALSE);
break;
default:
abort ();
@@ -3629,12 +3516,8 @@ stab_xcoff_builtin_type (dhandle, info, typenum)
/* Find or create a tagged type. */
static debug_type
-stab_find_tagged_type (dhandle, info, p, len, kind)
- PTR dhandle;
- struct stab_handle *info;
- const char *p;
- int len;
- enum debug_type_kind kind;
+stab_find_tagged_type (void *dhandle, struct stab_handle *info,
+ const char *p, int len, enum debug_type_kind kind)
{
char *name;
debug_type dtype;
@@ -3709,13 +3592,13 @@ struct stab_demangle_typestring
struct stab_demangle_info
{
/* The debugging information handle. */
- PTR dhandle;
+ void *dhandle;
/* The stab information handle. */
struct stab_handle *info;
/* The array of arguments we are building. */
debug_type *args;
/* Whether the method takes a variable number of arguments. */
- boolean varargs;
+ bfd_boolean varargs;
/* The array of types we have remembered. */
struct stab_demangle_typestring *typestrings;
/* The number of typestrings. */
@@ -3724,40 +3607,37 @@ struct stab_demangle_info
unsigned int typestring_alloc;
};
-static void stab_bad_demangle PARAMS ((const char *));
-static unsigned int stab_demangle_count PARAMS ((const char **));
-static boolean stab_demangle_get_count
- PARAMS ((const char **, unsigned int *));
-static boolean stab_demangle_prefix
- PARAMS ((struct stab_demangle_info *, const char **));
-static boolean stab_demangle_function_name
- PARAMS ((struct stab_demangle_info *, const char **, const char *));
-static boolean stab_demangle_signature
- PARAMS ((struct stab_demangle_info *, const char **));
-static boolean stab_demangle_qualified
- PARAMS ((struct stab_demangle_info *, const char **, debug_type *));
-static boolean stab_demangle_template
- PARAMS ((struct stab_demangle_info *, const char **, char **));
-static boolean stab_demangle_class
- PARAMS ((struct stab_demangle_info *, const char **, const char **));
-static boolean stab_demangle_args
- PARAMS ((struct stab_demangle_info *, const char **, debug_type **,
- boolean *));
-static boolean stab_demangle_arg
- PARAMS ((struct stab_demangle_info *, const char **, debug_type **,
- unsigned int *, unsigned int *));
-static boolean stab_demangle_type
- PARAMS ((struct stab_demangle_info *, const char **, debug_type *));
-static boolean stab_demangle_fund_type
- PARAMS ((struct stab_demangle_info *, const char **, debug_type *));
-static boolean stab_demangle_remember_type
- PARAMS ((struct stab_demangle_info *, const char *, int));
+static void stab_bad_demangle (const char *);
+static unsigned int stab_demangle_count (const char **);
+static bfd_boolean stab_demangle_get_count (const char **, unsigned int *);
+static bfd_boolean stab_demangle_prefix
+ (struct stab_demangle_info *, const char **, unsigned int);
+static bfd_boolean stab_demangle_function_name
+ (struct stab_demangle_info *, const char **, const char *);
+static bfd_boolean stab_demangle_signature
+ (struct stab_demangle_info *, const char **);
+static bfd_boolean stab_demangle_qualified
+ (struct stab_demangle_info *, const char **, debug_type *);
+static bfd_boolean stab_demangle_template
+ (struct stab_demangle_info *, const char **, char **);
+static bfd_boolean stab_demangle_class
+ (struct stab_demangle_info *, const char **, const char **);
+static bfd_boolean stab_demangle_args
+ (struct stab_demangle_info *, const char **, debug_type **, bfd_boolean *);
+static bfd_boolean stab_demangle_arg
+ (struct stab_demangle_info *, const char **, debug_type **,
+ unsigned int *, unsigned int *);
+static bfd_boolean stab_demangle_type
+ (struct stab_demangle_info *, const char **, debug_type *);
+static bfd_boolean stab_demangle_fund_type
+ (struct stab_demangle_info *, const char **, debug_type *);
+static bfd_boolean stab_demangle_remember_type
+ (struct stab_demangle_info *, const char *, int);
/* Warn about a bad demangling. */
static void
-stab_bad_demangle (s)
- const char *s;
+stab_bad_demangle (const char *s)
{
fprintf (stderr, _("bad mangled name `%s'\n"), s);
}
@@ -3765,8 +3645,7 @@ stab_bad_demangle (s)
/* Get a count from a stab string. */
static unsigned int
-stab_demangle_count (pp)
- const char **pp;
+stab_demangle_count (const char **pp)
{
unsigned int count;
@@ -3783,13 +3662,11 @@ stab_demangle_count (pp)
/* Require a count in a string. The count may be multiple digits, in
which case it must end in an underscore. */
-static boolean
-stab_demangle_get_count (pp, pi)
- const char **pp;
- unsigned int *pi;
+static bfd_boolean
+stab_demangle_get_count (const char **pp, unsigned int *pi)
{
if (! ISDIGIT (**pp))
- return false;
+ return FALSE;
*pi = **pp - '0';
++*pp;
@@ -3814,25 +3691,27 @@ stab_demangle_get_count (pp, pi)
}
}
- return true;
+ return TRUE;
}
/* This function demangles a physical name, returning a NULL
terminated array of argument types. */
static debug_type *
-stab_demangle_argtypes (dhandle, info, physname, pvarargs)
- PTR dhandle;
- struct stab_handle *info;
- const char *physname;
- boolean *pvarargs;
+stab_demangle_argtypes (void *dhandle, struct stab_handle *info,
+ const char *physname, bfd_boolean *pvarargs,
+ unsigned int physname_len)
{
struct stab_demangle_info minfo;
+ /* Check for the g++ V3 ABI. */
+ if (physname[0] == '_' && physname[1] == 'Z')
+ return stab_demangle_v3_argtypes (dhandle, info, physname, pvarargs);
+
minfo.dhandle = dhandle;
minfo.info = info;
minfo.args = NULL;
- minfo.varargs = false;
+ minfo.varargs = FALSE;
minfo.typestring_alloc = 10;
minfo.typestrings = ((struct stab_demangle_typestring *)
xmalloc (minfo.typestring_alloc
@@ -3842,7 +3721,7 @@ stab_demangle_argtypes (dhandle, info, physname, pvarargs)
/* cplus_demangle checks for special GNU mangled forms, but we can't
see any of them in mangled method argument types. */
- if (! stab_demangle_prefix (&minfo, &physname))
+ if (! stab_demangle_prefix (&minfo, &physname, physname_len))
goto error_return;
if (*physname != '\0')
@@ -3868,10 +3747,9 @@ stab_demangle_argtypes (dhandle, info, physname, pvarargs)
/* Demangle the prefix of the mangled name. */
-static boolean
-stab_demangle_prefix (minfo, pp)
- struct stab_demangle_info *minfo;
- const char **pp;
+static bfd_boolean
+stab_demangle_prefix (struct stab_demangle_info *minfo, const char **pp,
+ unsigned int physname_len)
{
const char *scan;
unsigned int i;
@@ -3879,26 +3757,29 @@ stab_demangle_prefix (minfo, pp)
/* cplus_demangle checks for global constructors and destructors,
but we can't see them in mangled argument types. */
- /* Look for `__'. */
- scan = *pp;
- do
+ if (physname_len)
+ scan = *pp + physname_len;
+ else
{
- scan = strchr (scan, '_');
- }
- while (scan != NULL && *++scan != '_');
+ /* Look for `__'. */
+ scan = *pp;
+ do
+ scan = strchr (scan, '_');
+ while (scan != NULL && *++scan != '_');
- if (scan == NULL)
- {
- stab_bad_demangle (*pp);
- return false;
- }
+ if (scan == NULL)
+ {
+ stab_bad_demangle (*pp);
+ return FALSE;
+ }
- --scan;
+ --scan;
- /* We found `__'; move ahead to the last contiguous `__' pair. */
- i = strspn (scan, "_");
- if (i > 2)
- scan += i - 2;
+ /* We found `__'; move ahead to the last contiguous `__' pair. */
+ i = strspn (scan, "_");
+ if (i > 2)
+ scan += i - 2;
+ }
if (scan == *pp
&& (ISDIGIT (scan[2])
@@ -3907,7 +3788,7 @@ stab_demangle_prefix (minfo, pp)
{
/* This is a GNU style constructor name. */
*pp = scan + 2;
- return true;
+ return TRUE;
}
else if (scan == *pp
&& ! ISDIGIT (scan[2])
@@ -3921,7 +3802,7 @@ stab_demangle_prefix (minfo, pp)
if (scan == NULL || scan[2] == '\0')
{
stab_bad_demangle (*pp);
- return false;
+ return FALSE;
}
return stab_demangle_function_name (minfo, pp, scan);
@@ -3934,7 +3815,7 @@ stab_demangle_prefix (minfo, pp)
else
{
stab_bad_demangle (*pp);
- return false;
+ return FALSE;
}
/*NOTREACHED*/
}
@@ -3943,11 +3824,9 @@ stab_demangle_prefix (minfo, pp)
double underscore which separates the function name from the
signature. */
-static boolean
-stab_demangle_function_name (minfo, pp, scan)
- struct stab_demangle_info *minfo;
- const char **pp;
- const char *scan;
+static bfd_boolean
+stab_demangle_function_name (struct stab_demangle_info *minfo,
+ const char **pp, const char *scan)
{
const char *name;
@@ -3968,7 +3847,7 @@ stab_demangle_function_name (minfo, pp, scan)
/* This is a type conversion operator. */
tem = name + 5;
if (! stab_demangle_type (minfo, &tem, (debug_type *) NULL))
- return false;
+ return FALSE;
}
else if (name[0] == '_'
&& name[1] == '_'
@@ -3980,28 +3859,26 @@ stab_demangle_function_name (minfo, pp, scan)
/* This is a type conversion operator. */
tem = name + 4;
if (! stab_demangle_type (minfo, &tem, (debug_type *) NULL))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Demangle the signature. This is where the argument types are
found. */
-static boolean
-stab_demangle_signature (minfo, pp)
- struct stab_demangle_info *minfo;
- const char **pp;
+static bfd_boolean
+stab_demangle_signature (struct stab_demangle_info *minfo, const char **pp)
{
const char *orig;
- boolean expect_func, func_done;
+ bfd_boolean expect_func, func_done;
const char *hold;
orig = *pp;
- expect_func = false;
- func_done = false;
+ expect_func = FALSE;
+ func_done = FALSE;
hold = NULL;
while (**pp != '\0')
@@ -4012,8 +3889,8 @@ stab_demangle_signature (minfo, pp)
hold = *pp;
if (! stab_demangle_qualified (minfo, pp, (debug_type *) NULL)
|| ! stab_demangle_remember_type (minfo, hold, *pp - hold))
- return false;
- expect_func = true;
+ return FALSE;
+ expect_func = TRUE;
hold = NULL;
break;
@@ -4037,8 +3914,8 @@ stab_demangle_signature (minfo, pp)
hold = *pp;
if (! stab_demangle_class (minfo, pp, (const char **) NULL)
|| ! stab_demangle_remember_type (minfo, hold, *pp - hold))
- return false;
- expect_func = true;
+ return FALSE;
+ expect_func = TRUE;
hold = NULL;
break;
@@ -4046,10 +3923,10 @@ stab_demangle_signature (minfo, pp)
/* Function. I don't know if this actually happens with g++
output. */
hold = NULL;
- func_done = true;
+ func_done = TRUE;
++*pp;
if (! stab_demangle_args (minfo, pp, &minfo->args, &minfo->varargs))
- return false;
+ return FALSE;
break;
case 't':
@@ -4058,9 +3935,9 @@ stab_demangle_signature (minfo, pp)
hold = *pp;
if (! stab_demangle_template (minfo, pp, (char **) NULL)
|| ! stab_demangle_remember_type (minfo, hold, *pp - hold))
- return false;
+ return FALSE;
hold = NULL;
- expect_func = true;
+ expect_func = TRUE;
break;
case '_':
@@ -4070,22 +3947,22 @@ stab_demangle_signature (minfo, pp)
has been mangled by some algorithm we don't know how to
deal with. So just reject the entire demangling. */
stab_bad_demangle (orig);
- return false;
+ return FALSE;
default:
/* Assume we have stumbled onto the first outermost function
argument token, and start processing args. */
- func_done = true;
+ func_done = TRUE;
if (! stab_demangle_args (minfo, pp, &minfo->args, &minfo->varargs))
- return false;
+ return FALSE;
break;
}
if (expect_func)
{
- func_done = true;
+ func_done = TRUE;
if (! stab_demangle_args (minfo, pp, &minfo->args, &minfo->varargs))
- return false;
+ return FALSE;
}
}
@@ -4096,20 +3973,18 @@ stab_demangle_signature (minfo, pp)
first case, and need to ensure that the '(void)' gets added
to the current declp. */
if (! stab_demangle_args (minfo, pp, &minfo->args, &minfo->varargs))
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
/* Demangle a qualified name, such as "Q25Outer5Inner" which is the
mangled form of "Outer::Inner". */
-static boolean
-stab_demangle_qualified (minfo, pp, ptype)
- struct stab_demangle_info *minfo;
- const char **pp;
- debug_type *ptype;
+static bfd_boolean
+stab_demangle_qualified (struct stab_demangle_info *minfo, const char **pp,
+ debug_type *ptype)
{
const char *orig;
const char *p;
@@ -4128,7 +4003,7 @@ stab_demangle_qualified (minfo, pp, ptype)
if (! ISDIGIT (*p) || *p == '0')
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
qualifiers = atoi (p);
while (ISDIGIT (*p))
@@ -4136,7 +4011,7 @@ stab_demangle_qualified (minfo, pp, ptype)
if (*p != '_')
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
*pp = p + 1;
break;
@@ -4153,7 +4028,7 @@ stab_demangle_qualified (minfo, pp, ptype)
case '0':
default:
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
context = DEBUG_TYPE_NULL;
@@ -4169,7 +4044,7 @@ stab_demangle_qualified (minfo, pp, ptype)
if (! stab_demangle_template (minfo, pp,
ptype != NULL ? &name : NULL))
- return false;
+ return FALSE;
if (ptype != NULL)
{
@@ -4178,7 +4053,7 @@ stab_demangle_qualified (minfo, pp, ptype)
DEBUG_KIND_CLASS);
free (name);
if (context == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
}
}
else
@@ -4189,7 +4064,7 @@ stab_demangle_qualified (minfo, pp, ptype)
if (strlen (*pp) < len)
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
if (ptype != NULL)
@@ -4223,7 +4098,7 @@ stab_demangle_qualified (minfo, pp, ptype)
ft = debug_get_field_type (minfo->dhandle, *fields);
if (ft == NULL)
- return false;
+ return FALSE;
dn = debug_get_type_name (minfo->dhandle, ft);
if (dn != NULL && strcmp (dn, name) == 0)
{
@@ -4260,7 +4135,7 @@ stab_demangle_qualified (minfo, pp, ptype)
? DEBUG_KIND_ILLEGAL
: DEBUG_KIND_CLASS));
if (context == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
}
}
}
@@ -4272,17 +4147,15 @@ stab_demangle_qualified (minfo, pp, ptype)
if (ptype != NULL)
*ptype = context;
- return true;
+ return TRUE;
}
/* Demangle a template. If PNAME is not NULL, this sets *PNAME to a
string representation of the template. */
-static boolean
-stab_demangle_template (minfo, pp, pname)
- struct stab_demangle_info *minfo;
- const char **pp;
- char **pname;
+static bfd_boolean
+stab_demangle_template (struct stab_demangle_info *minfo, const char **pp,
+ char **pname)
{
const char *orig;
unsigned int r, i;
@@ -4296,7 +4169,7 @@ stab_demangle_template (minfo, pp, pname)
if (r == 0 || strlen (*pp) < r)
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
*pp += r;
@@ -4304,7 +4177,7 @@ stab_demangle_template (minfo, pp, pname)
if (stab_demangle_get_count (pp, &r) == 0)
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
for (i = 0; i < r; i++)
@@ -4314,26 +4187,26 @@ stab_demangle_template (minfo, pp, pname)
/* This is a type parameter. */
++*pp;
if (! stab_demangle_type (minfo, pp, (debug_type *) NULL))
- return false;
+ return FALSE;
}
else
{
const char *old_p;
- boolean pointerp, realp, integralp, charp, boolp;
- boolean done;
+ bfd_boolean pointerp, realp, integralp, charp, boolp;
+ bfd_boolean done;
old_p = *pp;
- pointerp = false;
- realp = false;
- integralp = false;
- charp = false;
- boolp = false;
- done = false;
+ pointerp = FALSE;
+ realp = FALSE;
+ integralp = FALSE;
+ charp = FALSE;
+ boolp = FALSE;
+ done = FALSE;
/* This is a value parameter. */
if (! stab_demangle_type (minfo, pp, (debug_type *) NULL))
- return false;
+ return FALSE;
while (*old_p != '\0' && ! done)
{
@@ -4342,8 +4215,8 @@ stab_demangle_template (minfo, pp, pname)
case 'P':
case 'p':
case 'R':
- pointerp = true;
- done = true;
+ pointerp = TRUE;
+ done = TRUE;
break;
case 'C': /* Const. */
case 'S': /* Signed. */
@@ -4355,8 +4228,8 @@ stab_demangle_template (minfo, pp, pname)
++old_p;
break;
case 'Q': /* Qualified name. */
- integralp = true;
- done = true;
+ integralp = TRUE;
+ done = TRUE;
break;
case 'T': /* Remembered type. */
abort ();
@@ -4367,27 +4240,27 @@ stab_demangle_template (minfo, pp, pname)
case 'i': /* Int. */
case 's': /* Short. */
case 'w': /* Wchar_t. */
- integralp = true;
- done = true;
+ integralp = TRUE;
+ done = TRUE;
break;
case 'b': /* Bool. */
- boolp = true;
- done = true;
+ boolp = TRUE;
+ done = TRUE;
break;
case 'c': /* Char. */
- charp = true;
- done = true;
+ charp = TRUE;
+ done = TRUE;
break;
case 'r': /* Long double. */
case 'd': /* Double. */
case 'f': /* Float. */
- realp = true;
- done = true;
+ realp = TRUE;
+ done = TRUE;
break;
default:
/* Assume it's a user defined integral type. */
- integralp = true;
- done = true;
+ integralp = TRUE;
+ done = TRUE;
break;
}
}
@@ -4409,7 +4282,7 @@ stab_demangle_template (minfo, pp, pname)
if (val == 0)
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
}
else if (boolp)
@@ -4420,7 +4293,7 @@ stab_demangle_template (minfo, pp, pname)
if (val != 0 && val != 1)
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
}
else if (realp)
@@ -4449,7 +4322,7 @@ stab_demangle_template (minfo, pp, pname)
if (! stab_demangle_get_count (pp, &len))
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
*pp += len;
}
@@ -4480,7 +4353,7 @@ stab_demangle_template (minfo, pp, pname)
stab_bad_demangle (orig);
if (s3 != NULL)
free (s3);
- return false;
+ return FALSE;
}
/* Eliminating all spaces, except those between > characters,
@@ -4496,16 +4369,14 @@ stab_demangle_template (minfo, pp, pname)
free (s3);
}
- return true;
+ return TRUE;
}
/* Demangle a class name. */
-static boolean
-stab_demangle_class (minfo, pp, pstart)
- struct stab_demangle_info *minfo ATTRIBUTE_UNUSED;
- const char **pp;
- const char **pstart;
+static bfd_boolean
+stab_demangle_class (struct stab_demangle_info *minfo ATTRIBUTE_UNUSED,
+ const char **pp, const char **pstart)
{
const char *orig;
unsigned int n;
@@ -4516,7 +4387,7 @@ stab_demangle_class (minfo, pp, pstart)
if (strlen (*pp) < n)
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
if (pstart != NULL)
@@ -4524,18 +4395,15 @@ stab_demangle_class (minfo, pp, pstart)
*pp += n;
- return true;
+ return TRUE;
}
/* Demangle function arguments. If the pargs argument is not NULL, it
is set to a NULL terminated array holding the arguments. */
-static boolean
-stab_demangle_args (minfo, pp, pargs, pvarargs)
- struct stab_demangle_info *minfo;
- const char **pp;
- debug_type **pargs;
- boolean *pvarargs;
+static bfd_boolean
+stab_demangle_args (struct stab_demangle_info *minfo, const char **pp,
+ debug_type **pargs, bfd_boolean *pvarargs)
{
const char *orig;
unsigned int alloc, count;
@@ -4546,7 +4414,7 @@ stab_demangle_args (minfo, pp, pargs, pvarargs)
if (pargs != NULL)
{
*pargs = (debug_type *) xmalloc (alloc * sizeof **pargs);
- *pvarargs = false;
+ *pvarargs = FALSE;
}
count = 0;
@@ -4567,20 +4435,20 @@ stab_demangle_args (minfo, pp, pargs, pvarargs)
if (! stab_demangle_get_count (pp, &r))
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
}
if (! stab_demangle_get_count (pp, &t))
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
if (t >= minfo->typestring_count)
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
while (r-- > 0)
{
@@ -4588,13 +4456,13 @@ stab_demangle_args (minfo, pp, pargs, pvarargs)
tem = minfo->typestrings[t].typestring;
if (! stab_demangle_arg (minfo, &tem, pargs, &count, &alloc))
- return false;
+ return FALSE;
}
}
else
{
if (! stab_demangle_arg (minfo, pp, pargs, &count, &alloc))
- return false;
+ return FALSE;
}
}
@@ -4604,22 +4472,19 @@ stab_demangle_args (minfo, pp, pargs, pvarargs)
if (**pp == 'e')
{
if (pargs != NULL)
- *pvarargs = true;
+ *pvarargs = TRUE;
++*pp;
}
- return true;
+ return TRUE;
}
/* Demangle a single argument. */
-static boolean
-stab_demangle_arg (minfo, pp, pargs, pcount, palloc)
- struct stab_demangle_info *minfo;
- const char **pp;
- debug_type **pargs;
- unsigned int *pcount;
- unsigned int *palloc;
+static bfd_boolean
+stab_demangle_arg (struct stab_demangle_info *minfo, const char **pp,
+ debug_type **pargs, unsigned int *pcount,
+ unsigned int *palloc)
{
const char *start;
debug_type type;
@@ -4628,12 +4493,12 @@ stab_demangle_arg (minfo, pp, pargs, pcount, palloc)
if (! stab_demangle_type (minfo, pp,
pargs == NULL ? (debug_type *) NULL : &type)
|| ! stab_demangle_remember_type (minfo, start, *pp - start))
- return false;
+ return FALSE;
if (pargs != NULL)
{
if (type == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
if (*pcount + 1 >= *palloc)
{
@@ -4645,17 +4510,15 @@ stab_demangle_arg (minfo, pp, pargs, pcount, palloc)
++*pcount;
}
- return true;
+ return TRUE;
}
/* Demangle a type. If the ptype argument is not NULL, *ptype is set
to the newly allocated type. */
-static boolean
-stab_demangle_type (minfo, pp, ptype)
- struct stab_demangle_info *minfo;
- const char **pp;
- debug_type *ptype;
+static bfd_boolean
+stab_demangle_type (struct stab_demangle_info *minfo, const char **pp,
+ debug_type *ptype)
{
const char *orig;
@@ -4668,7 +4531,7 @@ stab_demangle_type (minfo, pp, ptype)
/* A pointer type. */
++*pp;
if (! stab_demangle_type (minfo, pp, ptype))
- return false;
+ return FALSE;
if (ptype != NULL)
*ptype = debug_make_pointer_type (minfo->dhandle, *ptype);
break;
@@ -4677,7 +4540,7 @@ stab_demangle_type (minfo, pp, ptype)
/* A reference type. */
++*pp;
if (! stab_demangle_type (minfo, pp, ptype))
- return false;
+ return FALSE;
if (ptype != NULL)
*ptype = debug_make_reference_type (minfo->dhandle, *ptype);
break;
@@ -4694,7 +4557,7 @@ stab_demangle_type (minfo, pp, ptype)
if (! ISDIGIT (**pp))
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
high *= 10;
high += **pp - '0';
@@ -4703,21 +4566,21 @@ stab_demangle_type (minfo, pp, ptype)
if (**pp != '_')
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
++*pp;
if (! stab_demangle_type (minfo, pp, ptype))
- return false;
+ return FALSE;
if (ptype != NULL)
{
debug_type int_type;
int_type = debug_find_named_type (minfo->dhandle, "int");
if (int_type == NULL)
- int_type = debug_make_int_type (minfo->dhandle, 4, false);
+ int_type = debug_make_int_type (minfo->dhandle, 4, FALSE);
*ptype = debug_make_array_type (minfo->dhandle, *ptype, int_type,
- 0, high, false);
+ 0, high, FALSE);
}
}
break;
@@ -4732,16 +4595,16 @@ stab_demangle_type (minfo, pp, ptype)
if (! stab_demangle_get_count (pp, &i))
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
if (i >= minfo->typestring_count)
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
p = minfo->typestrings[i].typestring;
if (! stab_demangle_type (minfo, &p, ptype))
- return false;
+ return FALSE;
}
break;
@@ -4749,7 +4612,7 @@ stab_demangle_type (minfo, pp, ptype)
/* A function. */
{
debug_type *args;
- boolean varargs;
+ bfd_boolean varargs;
++*pp;
if (! stab_demangle_args (minfo, pp,
@@ -4757,20 +4620,20 @@ stab_demangle_type (minfo, pp, ptype)
? (debug_type **) NULL
: &args),
(ptype == NULL
- ? (boolean *) NULL
+ ? (bfd_boolean *) NULL
: &varargs)))
- return false;
+ return FALSE;
if (**pp != '_')
{
/* cplus_demangle will accept a function without a return
type, but I don't know when that will happen, or what
to do if it does. */
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
++*pp;
if (! stab_demangle_type (minfo, pp, ptype))
- return false;
+ return FALSE;
if (ptype != NULL)
*ptype = debug_make_function_type (minfo->dhandle, *ptype, args,
varargs);
@@ -4781,18 +4644,18 @@ stab_demangle_type (minfo, pp, ptype)
case 'M':
case 'O':
{
- boolean memberp, constp, volatilep;
+ bfd_boolean memberp, constp, volatilep;
debug_type class_type = DEBUG_TYPE_NULL;
debug_type *args;
- boolean varargs;
+ bfd_boolean varargs;
unsigned int n;
const char *name;
memberp = **pp == 'M';
- constp = false;
- volatilep = false;
+ constp = FALSE;
+ volatilep = FALSE;
args = NULL;
- varargs = false;
+ varargs = FALSE;
++*pp;
if (ISDIGIT (**pp))
@@ -4801,7 +4664,7 @@ stab_demangle_type (minfo, pp, ptype)
if (strlen (*pp) < n)
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
name = *pp;
*pp += n;
@@ -4813,7 +4676,7 @@ stab_demangle_type (minfo, pp, ptype)
name, (int) n,
DEBUG_KIND_CLASS);
if (class_type == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
}
}
else if (**pp == 'Q')
@@ -4822,30 +4685,30 @@ stab_demangle_type (minfo, pp, ptype)
(ptype == NULL
? (debug_type *) NULL
: &class_type)))
- return false;
+ return FALSE;
}
else
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
if (memberp)
{
if (**pp == 'C')
{
- constp = true;
+ constp = TRUE;
++*pp;
}
else if (**pp == 'V')
{
- volatilep = true;
+ volatilep = TRUE;
++*pp;
}
if (**pp != 'F')
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
++*pp;
if (! stab_demangle_args (minfo, pp,
@@ -4853,20 +4716,20 @@ stab_demangle_type (minfo, pp, ptype)
? (debug_type **) NULL
: &args),
(ptype == NULL
- ? (boolean *) NULL
+ ? (bfd_boolean *) NULL
: &varargs)))
- return false;
+ return FALSE;
}
if (**pp != '_')
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
++*pp;
if (! stab_demangle_type (minfo, pp, ptype))
- return false;
+ return FALSE;
if (ptype != NULL)
{
@@ -4887,13 +4750,13 @@ stab_demangle_type (minfo, pp, ptype)
case 'G':
++*pp;
if (! stab_demangle_type (minfo, pp, ptype))
- return false;
+ return FALSE;
break;
case 'C':
++*pp;
if (! stab_demangle_type (minfo, pp, ptype))
- return false;
+ return FALSE;
if (ptype != NULL)
*ptype = debug_make_const_type (minfo->dhandle, *ptype);
break;
@@ -4904,66 +4767,64 @@ stab_demangle_type (minfo, pp, ptype)
hold = *pp;
if (! stab_demangle_qualified (minfo, pp, ptype))
- return false;
+ return FALSE;
}
break;
default:
if (! stab_demangle_fund_type (minfo, pp, ptype))
- return false;
+ return FALSE;
break;
}
- return true;
+ return TRUE;
}
/* Demangle a fundamental type. If the ptype argument is not NULL,
*ptype is set to the newly allocated type. */
-static boolean
-stab_demangle_fund_type (minfo, pp, ptype)
- struct stab_demangle_info *minfo;
- const char **pp;
- debug_type *ptype;
+static bfd_boolean
+stab_demangle_fund_type (struct stab_demangle_info *minfo, const char **pp,
+ debug_type *ptype)
{
const char *orig;
- boolean constp, volatilep, unsignedp, signedp;
- boolean done;
+ bfd_boolean constp, volatilep, unsignedp, signedp;
+ bfd_boolean done;
orig = *pp;
- constp = false;
- volatilep = false;
- unsignedp = false;
- signedp = false;
+ constp = FALSE;
+ volatilep = FALSE;
+ unsignedp = FALSE;
+ signedp = FALSE;
- done = false;
+ done = FALSE;
while (! done)
{
switch (**pp)
{
case 'C':
- constp = true;
+ constp = TRUE;
++*pp;
break;
case 'U':
- unsignedp = true;
+ unsignedp = TRUE;
++*pp;
break;
case 'S':
- signedp = true;
+ signedp = TRUE;
++*pp;
break;
case 'V':
- volatilep = true;
+ volatilep = TRUE;
++*pp;
break;
default:
- done = true;
+ done = TRUE;
break;
}
}
@@ -5068,7 +4929,7 @@ stab_demangle_fund_type (minfo, pp, ptype)
{
*ptype = debug_find_named_type (minfo->dhandle, "__wchar_t");
if (*ptype == DEBUG_TYPE_NULL)
- *ptype = debug_make_int_type (minfo->dhandle, 2, true);
+ *ptype = debug_make_int_type (minfo->dhandle, 2, TRUE);
}
++*pp;
break;
@@ -5108,7 +4969,7 @@ stab_demangle_fund_type (minfo, pp, ptype)
if (! ISDIGIT (**pp))
{
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
/* Fall through. */
case '0': case '1': case '2': case '3': case '4':
@@ -5117,7 +4978,7 @@ stab_demangle_fund_type (minfo, pp, ptype)
const char *hold;
if (! stab_demangle_class (minfo, pp, &hold))
- return false;
+ return FALSE;
if (ptype != NULL)
{
char *name;
@@ -5133,7 +4994,7 @@ stab_demangle_fund_type (minfo, pp, ptype)
hold, *pp - hold,
DEBUG_KIND_ILLEGAL);
if (*ptype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
}
}
}
@@ -5145,7 +5006,7 @@ stab_demangle_fund_type (minfo, pp, ptype)
if (! stab_demangle_template (minfo, pp,
ptype != NULL ? &name : NULL))
- return false;
+ return FALSE;
if (ptype != NULL)
{
*ptype = stab_find_tagged_type (minfo->dhandle, minfo->info,
@@ -5153,14 +5014,14 @@ stab_demangle_fund_type (minfo, pp, ptype)
DEBUG_KIND_CLASS);
free (name);
if (*ptype == DEBUG_TYPE_NULL)
- return false;
+ return FALSE;
}
}
break;
default:
stab_bad_demangle (orig);
- return false;
+ return FALSE;
}
if (ptype != NULL)
@@ -5171,16 +5032,14 @@ stab_demangle_fund_type (minfo, pp, ptype)
*ptype = debug_make_volatile_type (minfo->dhandle, *ptype);
}
- return true;
+ return TRUE;
}
/* Remember a type string in a demangled string. */
-static boolean
-stab_demangle_remember_type (minfo, p, len)
- struct stab_demangle_info *minfo;
- const char *p;
- int len;
+static bfd_boolean
+stab_demangle_remember_type (struct stab_demangle_info *minfo,
+ const char *p, int len)
{
if (minfo->typestring_count >= minfo->typestring_alloc)
{
@@ -5195,5 +5054,296 @@ stab_demangle_remember_type (minfo, p, len)
minfo->typestrings[minfo->typestring_count].len = (unsigned int) len;
++minfo->typestring_count;
- return true;
+ return TRUE;
+}
+
+/* Demangle names encoded using the g++ V3 ABI. The newer versions of
+ g++ which use this ABI do not encode ordinary method argument types
+ in a mangled name; they simply output the argument types. However,
+ for a static method, g++ simply outputs the return type and the
+ physical name. So in that case we need to demangle the name here.
+ Here PHYSNAME is the physical name of the function, and we set the
+ variable pointed at by PVARARGS to indicate whether this function
+ is varargs. This returns NULL, or a NULL terminated array of
+ argument types. */
+
+static debug_type *
+stab_demangle_v3_argtypes (void *dhandle, struct stab_handle *info,
+ const char *physname, bfd_boolean *pvarargs)
+{
+ struct demangle_component *dc;
+ void *mem;
+ unsigned int alloc, count;
+ debug_type *pargs;
+
+ dc = cplus_demangle_v3_components (physname, DMGL_PARAMS | DMGL_ANSI, &mem);
+ if (dc == NULL)
+ {
+ stab_bad_demangle (physname);
+ return NULL;
+ }
+
+ /* We expect to see TYPED_NAME, and the right subtree describes the
+ function type. */
+ if (dc->type != DEMANGLE_COMPONENT_TYPED_NAME
+ || dc->u.s_binary.right->type != DEMANGLE_COMPONENT_FUNCTION_TYPE)
+ {
+ fprintf (stderr, _("Demangled name is not a function\n"));
+ free (mem);
+ return NULL;
+ }
+
+ alloc = 10;
+ pargs = (debug_type *) xmalloc (alloc * sizeof *pargs);
+ *pvarargs = FALSE;
+
+ count = 0;
+
+ for (dc = dc->u.s_binary.right->u.s_binary.right;
+ dc != NULL;
+ dc = dc->u.s_binary.right)
+ {
+ debug_type arg;
+ bfd_boolean varargs;
+
+ if (dc->type != DEMANGLE_COMPONENT_ARGLIST)
+ {
+ fprintf (stderr, _("Unexpected type in demangle tree\n"));
+ free (mem);
+ return NULL;
+ }
+
+ arg = stab_demangle_v3_arg (dhandle, info, dc->u.s_binary.left,
+ NULL, &varargs);
+ if (arg == NULL)
+ {
+ if (varargs)
+ {
+ *pvarargs = TRUE;
+ continue;
+ }
+ free (mem);
+ return NULL;
+ }
+
+ if (count + 1 >= alloc)
+ {
+ alloc += 10;
+ pargs = (debug_type *) xrealloc (pargs, alloc * sizeof *pargs);
+ }
+
+ pargs[count] = arg;
+ ++count;
+ }
+
+ pargs[count] = DEBUG_TYPE_NULL;
+
+ free (mem);
+
+ return pargs;
+}
+
+/* Convert a struct demangle_component tree describing an argument
+ type into a debug_type. */
+
+static debug_type
+stab_demangle_v3_arg (void *dhandle, struct stab_handle *info,
+ struct demangle_component *dc, debug_type context,
+ bfd_boolean *pvarargs)
+{
+ debug_type dt;
+
+ if (pvarargs != NULL)
+ *pvarargs = FALSE;
+
+ switch (dc->type)
+ {
+ /* FIXME: These are demangle component types which we probably
+ need to handle one way or another. */
+ case DEMANGLE_COMPONENT_LOCAL_NAME:
+ case DEMANGLE_COMPONENT_TYPED_NAME:
+ case DEMANGLE_COMPONENT_TEMPLATE_PARAM:
+ case DEMANGLE_COMPONENT_CTOR:
+ case DEMANGLE_COMPONENT_DTOR:
+ case DEMANGLE_COMPONENT_JAVA_CLASS:
+ case DEMANGLE_COMPONENT_RESTRICT_THIS:
+ case DEMANGLE_COMPONENT_VOLATILE_THIS:
+ case DEMANGLE_COMPONENT_CONST_THIS:
+ case DEMANGLE_COMPONENT_VENDOR_TYPE_QUAL:
+ case DEMANGLE_COMPONENT_COMPLEX:
+ case DEMANGLE_COMPONENT_IMAGINARY:
+ case DEMANGLE_COMPONENT_VENDOR_TYPE:
+ case DEMANGLE_COMPONENT_FUNCTION_TYPE:
+ case DEMANGLE_COMPONENT_ARRAY_TYPE:
+ case DEMANGLE_COMPONENT_PTRMEM_TYPE:
+ case DEMANGLE_COMPONENT_ARGLIST:
+ default:
+ fprintf (stderr, _("Unrecognized demangle component\n"));
+ return NULL;
+
+ case DEMANGLE_COMPONENT_NAME:
+ if (context != NULL)
+ {
+ const debug_field *fields;
+
+ fields = debug_get_fields (dhandle, context);
+ if (fields != NULL)
+ {
+ /* Try to find this type by looking through the context
+ class. */
+ for (; *fields != DEBUG_FIELD_NULL; fields++)
+ {
+ debug_type ft;
+ const char *dn;
+
+ ft = debug_get_field_type (dhandle, *fields);
+ if (ft == NULL)
+ return NULL;
+ dn = debug_get_type_name (dhandle, ft);
+ if (dn != NULL
+ && (int) strlen (dn) == dc->u.s_name.len
+ && strncmp (dn, dc->u.s_name.s, dc->u.s_name.len) == 0)
+ return ft;
+ }
+ }
+ }
+ return stab_find_tagged_type (dhandle, info, dc->u.s_name.s,
+ dc->u.s_name.len, DEBUG_KIND_ILLEGAL);
+
+ case DEMANGLE_COMPONENT_QUAL_NAME:
+ context = stab_demangle_v3_arg (dhandle, info, dc->u.s_binary.left,
+ context, NULL);
+ if (context == NULL)
+ return NULL;
+ return stab_demangle_v3_arg (dhandle, info, dc->u.s_binary.right,
+ context, NULL);
+
+ case DEMANGLE_COMPONENT_TEMPLATE:
+ {
+ char *p;
+ size_t alc;
+
+ /* We print this component to get a class name which we can
+ use. FIXME: This probably won't work if the template uses
+ template parameters which refer to an outer template. */
+ p = cplus_demangle_print (DMGL_PARAMS | DMGL_ANSI, dc, 20, &alc);
+ if (p == NULL)
+ {
+ fprintf (stderr, _("Failed to print demangled template\n"));
+ return NULL;
+ }
+ dt = stab_find_tagged_type (dhandle, info, p, strlen (p),
+ DEBUG_KIND_CLASS);
+ free (p);
+ return dt;
+ }
+
+ case DEMANGLE_COMPONENT_SUB_STD:
+ return stab_find_tagged_type (dhandle, info, dc->u.s_string.string,
+ dc->u.s_string.len, DEBUG_KIND_ILLEGAL);
+
+ case DEMANGLE_COMPONENT_RESTRICT:
+ case DEMANGLE_COMPONENT_VOLATILE:
+ case DEMANGLE_COMPONENT_CONST:
+ case DEMANGLE_COMPONENT_POINTER:
+ case DEMANGLE_COMPONENT_REFERENCE:
+ dt = stab_demangle_v3_arg (dhandle, info, dc->u.s_binary.left, NULL,
+ NULL);
+ if (dt == NULL)
+ return NULL;
+
+ switch (dc->type)
+ {
+ default:
+ abort ();
+ case DEMANGLE_COMPONENT_RESTRICT:
+ /* FIXME: We have no way to represent restrict. */
+ return dt;
+ case DEMANGLE_COMPONENT_VOLATILE:
+ return debug_make_volatile_type (dhandle, dt);
+ case DEMANGLE_COMPONENT_CONST:
+ return debug_make_const_type (dhandle, dt);
+ case DEMANGLE_COMPONENT_POINTER:
+ return debug_make_pointer_type (dhandle, dt);
+ case DEMANGLE_COMPONENT_REFERENCE:
+ return debug_make_reference_type (dhandle, dt);
+ }
+
+ case DEMANGLE_COMPONENT_BUILTIN_TYPE:
+ {
+ char *p;
+ size_t alc;
+ debug_type ret;
+
+ /* We print this component in order to find out the type name.
+ FIXME: Should we instead expose the
+ demangle_builtin_type_info structure? */
+ p = cplus_demangle_print (DMGL_PARAMS | DMGL_ANSI, dc, 20, &alc);
+ if (p == NULL)
+ {
+ fprintf (stderr, _("Couldn't get demangled builtin type\n"));
+ return NULL;
+ }
+
+ /* The mangling is based on the type, but does not itself
+ indicate what the sizes are. So we have to guess. */
+ if (strcmp (p, "signed char") == 0)
+ ret = debug_make_int_type (dhandle, 1, FALSE);
+ else if (strcmp (p, "bool") == 0)
+ ret = debug_make_bool_type (dhandle, 1);
+ else if (strcmp (p, "char") == 0)
+ ret = debug_make_int_type (dhandle, 1, FALSE);
+ else if (strcmp (p, "double") == 0)
+ ret = debug_make_float_type (dhandle, 8);
+ else if (strcmp (p, "long double") == 0)
+ ret = debug_make_float_type (dhandle, 8);
+ else if (strcmp (p, "float") == 0)
+ ret = debug_make_float_type (dhandle, 4);
+ else if (strcmp (p, "__float128") == 0)
+ ret = debug_make_float_type (dhandle, 16);
+ else if (strcmp (p, "unsigned char") == 0)
+ ret = debug_make_int_type (dhandle, 1, TRUE);
+ else if (strcmp (p, "int") == 0)
+ ret = debug_make_int_type (dhandle, 4, FALSE);
+ else if (strcmp (p, "unsigned int") == 0)
+ ret = debug_make_int_type (dhandle, 4, TRUE);
+ else if (strcmp (p, "long") == 0)
+ ret = debug_make_int_type (dhandle, 4, FALSE);
+ else if (strcmp (p, "unsigned long") == 0)
+ ret = debug_make_int_type (dhandle, 4, TRUE);
+ else if (strcmp (p, "__int128") == 0)
+ ret = debug_make_int_type (dhandle, 16, FALSE);
+ else if (strcmp (p, "unsigned __int128") == 0)
+ ret = debug_make_int_type (dhandle, 16, TRUE);
+ else if (strcmp (p, "short") == 0)
+ ret = debug_make_int_type (dhandle, 2, FALSE);
+ else if (strcmp (p, "unsigned short") == 0)
+ ret = debug_make_int_type (dhandle, 2, TRUE);
+ else if (strcmp (p, "void") == 0)
+ ret = debug_make_void_type (dhandle);
+ else if (strcmp (p, "wchar_t") == 0)
+ ret = debug_make_int_type (dhandle, 4, TRUE);
+ else if (strcmp (p, "long long") == 0)
+ ret = debug_make_int_type (dhandle, 8, FALSE);
+ else if (strcmp (p, "unsigned long long") == 0)
+ ret = debug_make_int_type (dhandle, 8, TRUE);
+ else if (strcmp (p, "...") == 0)
+ {
+ if (pvarargs == NULL)
+ fprintf (stderr, _("Unexpected demangled varargs\n"));
+ else
+ *pvarargs = TRUE;
+ ret = NULL;
+ }
+ else
+ {
+ fprintf (stderr, _("Unrecognized demangled builtin type\n"));
+ ret = NULL;
+ }
+
+ free (p);
+
+ return ret;
+ }
+ }
}
diff --git a/contrib/binutils/binutils/sysdump.c b/contrib/binutils/binutils/sysdump.c
index 2d0362b..a1df1e0 100644
--- a/contrib/binutils/binutils/sysdump.c
+++ b/contrib/binutils/binutils/sysdump.c
@@ -1,5 +1,5 @@
/* Sysroff object format dumper.
- Copyright 1994, 1995, 1998, 1999, 2000, 2001, 2002
+ Copyright 1994, 1995, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
This file is part of GNU Binutils.
@@ -40,35 +40,31 @@ static int code;
static int addrsize = 4;
static FILE *file;
-static void dh PARAMS ((unsigned char *, int));
-static void itheader PARAMS ((char *, int));
-static void p PARAMS ((void));
-static void tabout PARAMS ((void));
-static void pbarray PARAMS ((barray *));
-static int getone PARAMS ((int));
-static int opt PARAMS ((int));
-static void must PARAMS ((int));
-static void tab PARAMS ((int, char *));
-static void dump_symbol_info PARAMS ((void));
-static void derived_type PARAMS ((void));
-static void module PARAMS ((void));
-static void show_usage PARAMS ((FILE *, int));
-
-extern char *getCHARS PARAMS ((unsigned char *, int *, int, int));
-extern int fillup PARAMS ((char *));
-extern barray getBARRAY PARAMS ((unsigned char *, int *, int, int));
-extern int getINT PARAMS ((unsigned char *, int *, int, int));
-extern int getBITS PARAMS ((char *, int *, int, int));
-extern void sysroff_swap_tr_in PARAMS ((void));
-extern void sysroff_print_tr_out PARAMS ((void));
-extern int main PARAMS ((int, char **));
+static void dh (unsigned char *, int);
+static void itheader (char *, int);
+static void p (void);
+static void tabout (void);
+static void pbarray (barray *);
+static int getone (int);
+static int opt (int);
+static void must (int);
+static void tab (int, char *);
+static void dump_symbol_info (void);
+static void derived_type (void);
+static void module (void);
+static void show_usage (FILE *, int);
+
+extern char *getCHARS (unsigned char *, int *, int, int);
+extern int fillup (char *);
+extern barray getBARRAY (unsigned char *, int *, int, int);
+extern int getINT (unsigned char *, int *, int, int);
+extern int getBITS (char *, int *, int, int);
+extern void sysroff_swap_tr_in (void);
+extern void sysroff_print_tr_out (void);
+extern int main (int, char **);
char *
-getCHARS (ptr, idx, size, max)
- unsigned char *ptr;
- int *idx;
- int size;
- int max;
+getCHARS (unsigned char *ptr, int *idx, int size, int max)
{
int oc = *idx / 8;
char *r;
@@ -93,9 +89,7 @@ getCHARS (ptr, idx, size, max)
}
static void
-dh (ptr, size)
- unsigned char *ptr;
- int size;
+dh (unsigned char *ptr, int size)
{
int i;
int j;
@@ -127,8 +121,7 @@ dh (ptr, size)
}
int
-fillup (ptr)
- char *ptr;
+fillup (char *ptr)
{
int size;
int sum;
@@ -151,11 +144,8 @@ fillup (ptr)
}
barray
-getBARRAY (ptr, idx, dsize, max)
- unsigned char *ptr;
- int *idx;
- int dsize ATTRIBUTE_UNUSED;
- int max ATTRIBUTE_UNUSED;
+getBARRAY (unsigned char *ptr, int *idx, int dsize ATTRIBUTE_UNUSED,
+ int max ATTRIBUTE_UNUSED)
{
barray res;
int i;
@@ -172,11 +162,7 @@ getBARRAY (ptr, idx, dsize, max)
}
int
-getINT (ptr, idx, size, max)
- unsigned char *ptr;
- int *idx;
- int size;
- int max;
+getINT (unsigned char *ptr, int *idx, int size, int max)
{
int n = 0;
int byte = *idx / 8;
@@ -212,10 +198,7 @@ getINT (ptr, idx, size, max)
}
int
-getBITS (ptr, idx, size, max)
- char *ptr;
- int *idx;
- int size, max;
+getBITS (char *ptr, int *idx, int size, int max)
{
int byte = *idx / 8;
int bit = *idx % 8;
@@ -229,9 +212,7 @@ getBITS (ptr, idx, size, max)
}
static void
-itheader (name, code)
- char *name;
- int code;
+itheader (char *name, int code)
{
printf ("\n%s 0x%02x\n", name, code);
}
@@ -239,7 +220,7 @@ itheader (name, code)
static int indent;
static void
-p ()
+p (void)
{
int i;
@@ -250,14 +231,13 @@ p ()
}
static void
-tabout ()
+tabout (void)
{
p ();
}
static void
-pbarray (y)
- barray *y;
+pbarray (barray *y)
{
int x;
@@ -283,7 +263,7 @@ pbarray (y)
#define IT_tr_CODE 0x7f
void
-sysroff_swap_tr_in()
+sysroff_swap_tr_in (void)
{
char raw[255];
@@ -292,14 +272,13 @@ sysroff_swap_tr_in()
}
void
-sysroff_print_tr_out()
+sysroff_print_tr_out (void)
{
itheader ("tr", IT_tr_CODE);
}
static int
-getone (type)
- int type;
+getone (int type)
{
int c = getc (file);
@@ -531,8 +510,7 @@ getone (type)
}
static int
-opt (x)
- int x;
+opt (int x)
{
return getone (x);
}
@@ -542,7 +520,7 @@ opt (x)
/* This is no longer used. */
static void
-unit_info_list ()
+unit_info_list (void)
{
while (opt (IT_un_CODE))
{
@@ -566,7 +544,7 @@ unit_info_list ()
/* This is no longer used. */
static void
-object_body_list ()
+object_body_list (void)
{
while (getone (IT_sh_CODE))
{
@@ -580,17 +558,14 @@ object_body_list ()
#endif
static void
-must (x)
- int x;
+must (int x)
{
if (!getone (x))
printf ("WANTED %x!!\n", x);
}
static void
-tab (i, s)
- int i;
- char *s;
+tab (int i, char *s)
{
indent += i;
@@ -603,7 +578,7 @@ tab (i, s)
}
static void
-dump_symbol_info ()
+dump_symbol_info (void)
{
tab (1, "SYMBOL INFO");
@@ -621,7 +596,7 @@ dump_symbol_info ()
}
static void
-derived_type ()
+derived_type (void)
{
tab (1, "DERIVED TYPE");
@@ -679,7 +654,7 @@ derived_type ()
/* This is no longer used. */
static void
-program_structure ()
+program_structure (void)
{
tab (1, "PROGRAM STRUCTURE");
while (opt (IT_dps_CODE))
@@ -699,7 +674,7 @@ program_structure ()
/* This is no longer used. */
static void
-debug_list ()
+debug_list (void)
{
tab (1, "DEBUG LIST");
@@ -714,7 +689,7 @@ debug_list ()
#endif
static void
-module ()
+module (void)
{
int c = 0;
int l = 0;
@@ -760,9 +735,7 @@ module ()
char *program_name;
static void
-show_usage (file, status)
- FILE *file;
- int status;
+show_usage (FILE *file, int status)
{
fprintf (file, _("Usage: %s [option(s)] in-file\n"), program_name);
fprintf (file, _("Print a human readable interpretation of a SYSROFF object file\n"));
@@ -776,9 +749,7 @@ show_usage (file, status)
}
int
-main (ac, av)
- int ac;
- char **av;
+main (int ac, char **av)
{
char *input_file = NULL;
int opt;
diff --git a/contrib/binutils/binutils/unwind-ia64.c b/contrib/binutils/binutils/unwind-ia64.c
index 803a5fa..2e7e726 100644
--- a/contrib/binutils/binutils/unwind-ia64.c
+++ b/contrib/binutils/binutils/unwind-ia64.c
@@ -1,5 +1,5 @@
/* unwind-ia64.c -- utility routines to dump IA-64 unwind info for readelf.
- Copyright 2000, 2001 Free Software Foundation, Inc.
+ Copyright 2000, 2001, 2003 Free Software Foundation, Inc.
Contributed by David Mosberger-Tang <davidm@hpl.hp.com>
This file is part of GNU Binutils.
@@ -25,7 +25,7 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#if __GNUC__ >= 2
/* Define BFD64 here, even if our default architecture is 32 bit ELF
as this will allow us to read in and parse 64bit and 32bit ELF files.
- Only do this if we belive that the compiler can support a 64 bit
+ Only do this if we believe that the compiler can support a 64 bit
data type. For now we only rely on GCC being able to do this. */
#define BFD64
#endif
@@ -33,16 +33,14 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
static bfd_vma unw_rlen = 0;
-static void unw_print_brmask PARAMS ((char *, unsigned int));
-static void unw_print_grmask PARAMS ((char *, unsigned int));
-static void unw_print_frmask PARAMS ((char *, unsigned int));
-static void unw_print_abreg PARAMS ((char *, unsigned int));
-static void unw_print_xyreg PARAMS ((char *, unsigned int, unsigned int));
+static void unw_print_brmask (char *, unsigned int);
+static void unw_print_grmask (char *, unsigned int);
+static void unw_print_frmask (char *, unsigned int);
+static void unw_print_abreg (char *, unsigned int);
+static void unw_print_xyreg (char *, unsigned int, unsigned int);
static void
-unw_print_brmask (cp, mask)
- char * cp;
- unsigned int mask;
+unw_print_brmask (char *cp, unsigned int mask)
{
int sep = 0;
int i;
@@ -63,9 +61,7 @@ unw_print_brmask (cp, mask)
}
static void
-unw_print_grmask (cp, mask)
- char * cp;
- unsigned int mask;
+unw_print_grmask (char *cp, unsigned int mask)
{
int sep = 0;
int i;
@@ -86,9 +82,7 @@ unw_print_grmask (cp, mask)
}
static void
-unw_print_frmask (cp, mask)
- char * cp;
- unsigned int mask;
+unw_print_frmask (char *cp, unsigned int mask)
{
int sep = 0;
int i;
@@ -115,9 +109,7 @@ unw_print_frmask (cp, mask)
}
static void
-unw_print_abreg (cp, abreg)
- char * cp;
- unsigned int abreg;
+unw_print_abreg (char *cp, unsigned int abreg)
{
static const char *special_reg[16] =
{
@@ -147,10 +139,7 @@ unw_print_abreg (cp, abreg)
}
static void
-unw_print_xyreg (cp, x, ytreg)
- char * cp;
- unsigned int x;
- unsigned int ytreg;
+unw_print_xyreg (char *cp, unsigned int x, unsigned int ytreg)
{
switch ((x << 1) | ((ytreg >> 7) & 1))
{
@@ -252,13 +241,13 @@ typedef bfd_vma unw_word;
} \
while (0)
-#define UNW_DEC_FRGR_MEM(fmt, grmask, frmask, arg) \
+#define UNW_DEC_FRGR_MEM(fmt, grmask, frmask, arg) \
do \
- { \
+ { \
char frstr[200], grstr[20]; \
- \
- unw_print_grmask (grstr, grmask); \
- unw_print_frmask (frstr, frmask); \
+ \
+ unw_print_grmask (grstr, grmask); \
+ unw_print_frmask (frstr, frmask); \
printf ("\t%s:frgr_mem(grmask=[%s],frmask=[%s])\n", fmt, grstr, frstr); \
} \
while (0)
@@ -360,8 +349,8 @@ typedef bfd_vma unw_word;
#define UNW_DEC_SPILL_MASK(fmt, dp, arg) \
do \
{ \
- static const char * spill_type = "-frb"; \
- unsigned const char * imaskp = dp; \
+ static const char *spill_type = "-frb"; \
+ unsigned const char *imaskp = dp; \
unsigned char mask = 0; \
bfd_vma insn = 0; \
\
@@ -390,13 +379,13 @@ typedef bfd_vma unw_word;
} \
while (0)
-#define UNW_DEC_SPILL_PSPREL(fmt, t, abreg, pspoff, arg) \
+#define UNW_DEC_SPILL_PSPREL(fmt, t, abreg, pspoff, arg) \
do \
- { \
- char regname[10]; \
- \
- unw_print_abreg (regname, abreg); \
- printf ("\t%s:spill_psprel(reg=%s,t=%lu,pspoff=0x10-0x%lx)\n", \
+ { \
+ char regname[10]; \
+ \
+ unw_print_abreg (regname, abreg); \
+ printf ("\t%s:spill_psprel(reg=%s,t=%lu,pspoff=0x10-0x%lx)\n", \
fmt, regname, (unsigned long) t, 4*(unsigned long)pspoff); \
} \
while (0)
@@ -424,12 +413,12 @@ typedef bfd_vma unw_word;
} \
while (0)
-#define UNW_DEC_SPILL_SPREL_P(fmt, qp, t, abreg, spoff, arg) \
+#define UNW_DEC_SPILL_SPREL_P(fmt, qp, t, abreg, spoff, arg) \
do \
- { \
- char regname[20]; \
- \
- unw_print_abreg (regname, abreg); \
+ { \
+ char regname[20]; \
+ \
+ unw_print_abreg (regname, abreg); \
printf ("\t%s:spill_sprel_p(qp=p%u,t=%lu,reg=%s,spoff=0x%lx)\n", \
fmt, qp, (unsigned long) t, regname, 4 * (unsigned long)spoff); \
} \
@@ -541,39 +530,38 @@ typedef bfd_vma unw_word;
* UNW_DEC_SPILL_SPREL_P(fmt,qp,t,abreg,pspoff,arg)
*/
-static unw_word unw_decode_uleb128 PARAMS ((const unsigned char **));
-static const unsigned char *unw_decode_x1 PARAMS ((const unsigned char *,
- unsigned int, void *));
-static const unsigned char *unw_decode_x2 PARAMS ((const unsigned char *,
- unsigned int, void *));
-static const unsigned char *unw_decode_x3 PARAMS ((const unsigned char *,
- unsigned int, void *));
-static const unsigned char *unw_decode_x4 PARAMS ((const unsigned char *,
- unsigned int, void *));
-static const unsigned char *unw_decode_r1 PARAMS ((const unsigned char *,
- unsigned int, void *));
-static const unsigned char *unw_decode_r2 PARAMS ((const unsigned char *,
- unsigned int, void *));
-static const unsigned char *unw_decode_r3 PARAMS ((const unsigned char *,
- unsigned int, void *));
-static const unsigned char *unw_decode_p1 PARAMS ((const unsigned char *,
- unsigned int, void *));
-static const unsigned char *unw_decode_p2_p5 PARAMS ((const unsigned char *,
- unsigned int, void *));
-static const unsigned char *unw_decode_p6 PARAMS ((const unsigned char *,
- unsigned int, void *));
-static const unsigned char *unw_decode_p7_p10 PARAMS ((const unsigned char *,
- unsigned int, void *));
-static const unsigned char *unw_decode_b1 PARAMS ((const unsigned char *,
- unsigned int, void *));
-static const unsigned char *unw_decode_b2 PARAMS ((const unsigned char *,
- unsigned int, void *));
-static const unsigned char *unw_decode_b3_x4 PARAMS ((const unsigned char *,
- unsigned int, void *));
+static unw_word unw_decode_uleb128 (const unsigned char **);
+static const unsigned char *unw_decode_x1
+ (const unsigned char *, unsigned int, void *);
+static const unsigned char *unw_decode_x2
+ (const unsigned char *, unsigned int, void *);
+static const unsigned char *unw_decode_x3
+ (const unsigned char *, unsigned int, void *);
+static const unsigned char *unw_decode_x4
+ (const unsigned char *, unsigned int, void *);
+static const unsigned char *unw_decode_r1
+ (const unsigned char *, unsigned int, void *);
+static const unsigned char *unw_decode_r2
+ (const unsigned char *, unsigned int, void *);
+static const unsigned char *unw_decode_r3
+ (const unsigned char *, unsigned int, void *);
+static const unsigned char *unw_decode_p1
+ (const unsigned char *, unsigned int, void *);
+static const unsigned char *unw_decode_p2_p5
+ (const unsigned char *, unsigned int, void *);
+static const unsigned char *unw_decode_p6
+ (const unsigned char *, unsigned int, void *);
+static const unsigned char *unw_decode_p7_p10
+ (const unsigned char *, unsigned int, void *);
+static const unsigned char *unw_decode_b1
+ (const unsigned char *, unsigned int, void *);
+static const unsigned char *unw_decode_b2
+ (const unsigned char *, unsigned int, void *);
+static const unsigned char *unw_decode_b3_x4
+ (const unsigned char *, unsigned int, void *);
static unw_word
-unw_decode_uleb128 (dpp)
- const unsigned char **dpp;
+unw_decode_uleb128 (const unsigned char **dpp)
{
unsigned shift = 0;
unw_word byte, result = 0;
@@ -596,10 +584,8 @@ unw_decode_uleb128 (dpp)
}
static const unsigned char *
-unw_decode_x1 (dp, code, arg)
- const unsigned char * dp;
- unsigned int code ATTRIBUTE_UNUSED;
- void * arg ATTRIBUTE_UNUSED;
+unw_decode_x1 (const unsigned char *dp, unsigned int code ATTRIBUTE_UNUSED,
+ void *arg ATTRIBUTE_UNUSED)
{
unsigned char byte1, abreg;
unw_word t, off;
@@ -616,10 +602,8 @@ unw_decode_x1 (dp, code, arg)
}
static const unsigned char *
-unw_decode_x2 (dp, code, arg)
- const unsigned char * dp;
- unsigned int code ATTRIBUTE_UNUSED;
- void * arg ATTRIBUTE_UNUSED;
+unw_decode_x2 (const unsigned char *dp, unsigned int code ATTRIBUTE_UNUSED,
+ void *arg ATTRIBUTE_UNUSED)
{
unsigned char byte1, byte2, abreg, x, ytreg;
unw_word t;
@@ -638,10 +622,8 @@ unw_decode_x2 (dp, code, arg)
}
static const unsigned char *
-unw_decode_x3 (dp, code, arg)
- const unsigned char * dp;
- unsigned int code ATTRIBUTE_UNUSED;
- void * arg ATTRIBUTE_UNUSED;
+unw_decode_x3 (const unsigned char *dp, unsigned int code ATTRIBUTE_UNUSED,
+ void *arg ATTRIBUTE_UNUSED)
{
unsigned char byte1, byte2, abreg, qp;
unw_word t, off;
@@ -662,10 +644,8 @@ unw_decode_x3 (dp, code, arg)
}
static const unsigned char *
-unw_decode_x4 (dp, code, arg)
- const unsigned char * dp;
- unsigned int code ATTRIBUTE_UNUSED;
- void * arg ATTRIBUTE_UNUSED;
+unw_decode_x4 (const unsigned char *dp, unsigned int code ATTRIBUTE_UNUSED,
+ void *arg ATTRIBUTE_UNUSED)
{
unsigned char byte1, byte2, byte3, qp, abreg, x, ytreg;
unw_word t;
@@ -688,10 +668,7 @@ unw_decode_x4 (dp, code, arg)
}
static const unsigned char *
-unw_decode_r1 (dp, code, arg)
- const unsigned char *dp;
- unsigned int code;
- void *arg;
+unw_decode_r1 (const unsigned char *dp, unsigned int code, void *arg)
{
int body = (code & 0x20) != 0;
unw_word rlen;
@@ -702,10 +679,7 @@ unw_decode_r1 (dp, code, arg)
}
static const unsigned char *
-unw_decode_r2 (dp, code, arg)
- const unsigned char *dp;
- unsigned int code;
- void *arg;
+unw_decode_r2 (const unsigned char *dp, unsigned int code, void *arg)
{
unsigned char byte1, mask, grsave;
unw_word rlen;
@@ -720,10 +694,7 @@ unw_decode_r2 (dp, code, arg)
}
static const unsigned char *
-unw_decode_r3 (dp, code, arg)
- const unsigned char *dp;
- unsigned int code;
- void *arg;
+unw_decode_r3 (const unsigned char *dp, unsigned int code, void *arg)
{
unw_word rlen;
@@ -733,10 +704,8 @@ unw_decode_r3 (dp, code, arg)
}
static const unsigned char *
-unw_decode_p1 (dp, code, arg)
- const unsigned char * dp;
- unsigned int code;
- void * arg ATTRIBUTE_UNUSED;
+unw_decode_p1 (const unsigned char *dp, unsigned int code,
+ void *arg ATTRIBUTE_UNUSED)
{
unsigned char brmask = (code & 0x1f);
@@ -745,10 +714,8 @@ unw_decode_p1 (dp, code, arg)
}
static const unsigned char *
-unw_decode_p2_p5 (dp, code, arg)
- const unsigned char * dp;
- unsigned int code;
- void * arg ATTRIBUTE_UNUSED;
+unw_decode_p2_p5 (const unsigned char *dp, unsigned int code,
+ void *arg ATTRIBUTE_UNUSED)
{
if ((code & 0x10) == 0)
{
@@ -826,10 +793,8 @@ unw_decode_p2_p5 (dp, code, arg)
}
static const unsigned char *
-unw_decode_p6 (dp, code, arg)
- const unsigned char * dp;
- unsigned int code;
- void * arg ATTRIBUTE_UNUSED;
+unw_decode_p6 (const unsigned char *dp, unsigned int code,
+ void *arg ATTRIBUTE_UNUSED)
{
int gregs = (code & 0x10) != 0;
unsigned char mask = (code & 0x0f);
@@ -842,10 +807,7 @@ unw_decode_p6 (dp, code, arg)
}
static const unsigned char *
-unw_decode_p7_p10 (dp, code, arg)
- const unsigned char *dp;
- unsigned int code;
- void *arg;
+unw_decode_p7_p10 (const unsigned char *dp, unsigned int code, void *arg)
{
unsigned char r, byte1, byte2;
unw_word t, size;
@@ -1018,10 +980,8 @@ unw_decode_p7_p10 (dp, code, arg)
}
static const unsigned char *
-unw_decode_b1 (dp, code, arg)
- const unsigned char * dp;
- unsigned int code;
- void * arg ATTRIBUTE_UNUSED;
+unw_decode_b1 (const unsigned char *dp, unsigned int code,
+ void *arg ATTRIBUTE_UNUSED)
{
unw_word label = (code & 0x1f);
@@ -1033,10 +993,8 @@ unw_decode_b1 (dp, code, arg)
}
static const unsigned char *
-unw_decode_b2 (dp, code, arg)
- const unsigned char * dp;
- unsigned int code;
- void * arg ATTRIBUTE_UNUSED;
+unw_decode_b2 (const unsigned char *dp, unsigned int code,
+ void *arg ATTRIBUTE_UNUSED)
{
unw_word t;
@@ -1046,10 +1004,7 @@ unw_decode_b2 (dp, code, arg)
}
static const unsigned char *
-unw_decode_b3_x4 (dp, code, arg)
- const unsigned char *dp;
- unsigned int code;
- void *arg;
+unw_decode_b3_x4 (const unsigned char *dp, unsigned int code, void *arg)
{
unw_word t, ecount, label;
@@ -1086,7 +1041,7 @@ unw_decode_b3_x4 (dp, code, arg)
}
typedef const unsigned char *(*unw_decoder)
- PARAMS ((const unsigned char *, unsigned int, void *));
+ (const unsigned char *, unsigned int, void *);
static unw_decoder unw_decode_table[2][8] =
{
@@ -1115,10 +1070,8 @@ static unw_decoder unw_decode_table[2][8] =
/* Decode one descriptor and return address of next descriptor. */
const unsigned char *
-unw_decode (dp, inside_body, ptr_inside_body)
- const unsigned char * dp;
- int inside_body;
- void * ptr_inside_body;
+unw_decode (const unsigned char *dp, int inside_body,
+ void *ptr_inside_body)
{
unw_decoder decoder;
unsigned char code;
diff --git a/contrib/binutils/binutils/unwind-ia64.h b/contrib/binutils/binutils/unwind-ia64.h
index 7d5033d..3b6ab22 100644
--- a/contrib/binutils/binutils/unwind-ia64.h
+++ b/contrib/binutils/binutils/unwind-ia64.h
@@ -1,5 +1,5 @@
/* unwind-ia64.h -- dump IA-64 unwind info.
- Copyright 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
Contributed by David Mosberger-Tang <davidm@hpl.hp.com>
This file is part of GNU Binutils.
@@ -22,10 +22,10 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "ansidecl.h"
#define UNW_VER(x) ((x) >> 48)
-#define UNW_FLAG_MASK 0x0000ffff00000000
-#define UNW_FLAG_OSMASK 0x0000f00000000000
-#define UNW_FLAG_EHANDLER(x) ((x) & 0x0000000100000000L)
-#define UNW_FLAG_UHANDLER(x) ((x) & 0x0000000200000000L)
-#define UNW_LENGTH(x) ((x) & 0x00000000ffffffffL)
+#define UNW_FLAG_MASK 0x0000ffff00000000LL
+#define UNW_FLAG_OSMASK 0x0000f00000000000LL
+#define UNW_FLAG_EHANDLER(x) ((x) & 0x0000000100000000LL)
+#define UNW_FLAG_UHANDLER(x) ((x) & 0x0000000200000000LL)
+#define UNW_LENGTH(x) ((x) & 0x00000000ffffffffLL)
-extern const unsigned char * unw_decode PARAMS ((const unsigned char *, int, void *));
+extern const unsigned char *unw_decode (const unsigned char *, int, void *);
diff --git a/contrib/binutils/binutils/version.c b/contrib/binutils/binutils/version.c
index edaa065..f965619 100644
--- a/contrib/binutils/binutils/version.c
+++ b/contrib/binutils/binutils/version.c
@@ -1,38 +1,38 @@
/* version.c -- binutils version information
- Copyright 1991, 1996, 1997, 1998, 1999, 2000, 2001, 2002
+ Copyright 1991, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
-This file is part of GNU Binutils.
+ This file is part of GNU Binutils.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include <stdio.h>
#include "bfd.h"
+#include "bfdver.h"
#include "bucomm.h"
/* Print the version number and copyright information, and exit. This
implements the --version option for the various programs. */
void
-print_version (name)
- const char *name;
+print_version (const char *name)
{
/* This output is intended to follow the GNU standards document. */
/* xgettext:c-format */
printf ("GNU %s %s\n", name, BFD_VERSION_STRING);
- printf (_("Copyright 2002 Free Software Foundation, Inc.\n"));
+ printf (_("Copyright 2004 Free Software Foundation, Inc.\n"));
printf (_("\
This program is free software; you may redistribute it under the terms of\n\
the GNU General Public License. This program has absolutely no warranty.\n"));
diff --git a/contrib/binutils/binutils/wrstabs.c b/contrib/binutils/binutils/wrstabs.c
index 5d0dc3b..0d301f6 100644
--- a/contrib/binutils/binutils/wrstabs.c
+++ b/contrib/binutils/binutils/wrstabs.c
@@ -1,5 +1,6 @@
/* wrstabs.c -- Output stabs debugging information
- Copyright 1996, 1997, 1998, 2000, 2001 Free Software Foundation, Inc.
+ Copyright 1996, 1997, 1998, 2000, 2001, 2002, 2003
+ Free Software Foundation, Inc.
Written by Ian Lance Taylor <ian@cygnus.com>.
This file is part of GNU Binutils.
@@ -31,10 +32,6 @@
#include "safe-ctype.h"
#include "debug.h"
#include "budbg.h"
-
-/* Meaningless definition needs by aout64.h. FIXME. */
-#define BYTES_IN_WORD 4
-
#include "aout/aout64.h"
#include "aout/stab_gnu.h"
@@ -75,7 +72,7 @@ struct stab_type_stack
/* The size of the type. */
unsigned int size;
/* Whether type string defines a new type. */
- boolean definition;
+ bfd_boolean definition;
/* String defining struct fields. */
char *fields;
/* NULL terminated array of strings defining base classes for a
@@ -176,83 +173,80 @@ struct stab_write_handle
};
static struct bfd_hash_entry *string_hash_newfunc
- PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-static boolean stab_write_symbol
- PARAMS ((struct stab_write_handle *, int, int, bfd_vma, const char *));
-static boolean stab_push_string
- PARAMS ((struct stab_write_handle *, const char *, long, boolean,
- unsigned int));
-static boolean stab_push_defined_type
- PARAMS ((struct stab_write_handle *, long, unsigned int));
-static char *stab_pop_type PARAMS ((struct stab_write_handle *));
-static boolean stab_modify_type
- PARAMS ((struct stab_write_handle *, int, unsigned int, long **, size_t *));
+ (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
+static bfd_boolean stab_write_symbol
+ (struct stab_write_handle *, int, int, bfd_vma, const char *);
+static bfd_boolean stab_push_string
+ (struct stab_write_handle *, const char *, long, bfd_boolean, unsigned int);
+static bfd_boolean stab_push_defined_type
+ (struct stab_write_handle *, long, unsigned int);
+static char *stab_pop_type (struct stab_write_handle *);
+static bfd_boolean stab_modify_type
+ (struct stab_write_handle *, int, unsigned int, long **, size_t *);
static long stab_get_struct_index
- PARAMS ((struct stab_write_handle *, const char *, unsigned int,
- enum debug_type_kind, unsigned int *));
-static boolean stab_class_method_var
- PARAMS ((struct stab_write_handle *, const char *, enum debug_visibility,
- boolean, boolean, boolean, bfd_vma, boolean));
-
-static boolean stab_start_compilation_unit PARAMS ((PTR, const char *));
-static boolean stab_start_source PARAMS ((PTR, const char *));
-static boolean stab_empty_type PARAMS ((PTR));
-static boolean stab_void_type PARAMS ((PTR));
-static boolean stab_int_type PARAMS ((PTR, unsigned int, boolean));
-static boolean stab_float_type PARAMS ((PTR, unsigned int));
-static boolean stab_complex_type PARAMS ((PTR, unsigned int));
-static boolean stab_bool_type PARAMS ((PTR, unsigned int));
-static boolean stab_enum_type
- PARAMS ((PTR, const char *, const char **, bfd_signed_vma *));
-static boolean stab_pointer_type PARAMS ((PTR));
-static boolean stab_function_type PARAMS ((PTR, int, boolean));
-static boolean stab_reference_type PARAMS ((PTR));
-static boolean stab_range_type PARAMS ((PTR, bfd_signed_vma, bfd_signed_vma));
-static boolean stab_array_type
- PARAMS ((PTR, bfd_signed_vma, bfd_signed_vma, boolean));
-static boolean stab_set_type PARAMS ((PTR, boolean));
-static boolean stab_offset_type PARAMS ((PTR));
-static boolean stab_method_type PARAMS ((PTR, boolean, int, boolean));
-static boolean stab_const_type PARAMS ((PTR));
-static boolean stab_volatile_type PARAMS ((PTR));
-static boolean stab_start_struct_type
- PARAMS ((PTR, const char *, unsigned int, boolean, unsigned int));
-static boolean stab_struct_field
- PARAMS ((PTR, const char *, bfd_vma, bfd_vma, enum debug_visibility));
-static boolean stab_end_struct_type PARAMS ((PTR));
-static boolean stab_start_class_type
- PARAMS ((PTR, const char *, unsigned int, boolean, unsigned int, boolean,
- boolean));
-static boolean stab_class_static_member
- PARAMS ((PTR, const char *, const char *, enum debug_visibility));
-static boolean stab_class_baseclass
- PARAMS ((PTR, bfd_vma, boolean, enum debug_visibility));
-static boolean stab_class_start_method PARAMS ((PTR, const char *));
-static boolean stab_class_method_variant
- PARAMS ((PTR, const char *, enum debug_visibility, boolean, boolean,
- bfd_vma, boolean));
-static boolean stab_class_static_method_variant
- PARAMS ((PTR, const char *, enum debug_visibility, boolean, boolean));
-static boolean stab_class_end_method PARAMS ((PTR));
-static boolean stab_end_class_type PARAMS ((PTR));
-static boolean stab_typedef_type PARAMS ((PTR, const char *));
-static boolean stab_tag_type
- PARAMS ((PTR, const char *, unsigned int, enum debug_type_kind));
-static boolean stab_typdef PARAMS ((PTR, const char *));
-static boolean stab_tag PARAMS ((PTR, const char *));
-static boolean stab_int_constant PARAMS ((PTR, const char *, bfd_vma));
-static boolean stab_float_constant PARAMS ((PTR, const char *, double));
-static boolean stab_typed_constant PARAMS ((PTR, const char *, bfd_vma));
-static boolean stab_variable
- PARAMS ((PTR, const char *, enum debug_var_kind, bfd_vma));
-static boolean stab_start_function PARAMS ((PTR, const char *, boolean));
-static boolean stab_function_parameter
- PARAMS ((PTR, const char *, enum debug_parm_kind, bfd_vma));
-static boolean stab_start_block PARAMS ((PTR, bfd_vma));
-static boolean stab_end_block PARAMS ((PTR, bfd_vma));
-static boolean stab_end_function PARAMS ((PTR));
-static boolean stab_lineno
- PARAMS ((PTR, const char *, unsigned long, bfd_vma));
+ (struct stab_write_handle *, const char *, unsigned int,
+ enum debug_type_kind, unsigned int *);
+static bfd_boolean stab_class_method_var
+ (struct stab_write_handle *, const char *, enum debug_visibility,
+ bfd_boolean, bfd_boolean, bfd_boolean, bfd_vma, bfd_boolean);
+static bfd_boolean stab_start_compilation_unit (void *, const char *);
+static bfd_boolean stab_start_source (void *, const char *);
+static bfd_boolean stab_empty_type (void *);
+static bfd_boolean stab_void_type (void *);
+static bfd_boolean stab_int_type (void *, unsigned int, bfd_boolean);
+static bfd_boolean stab_float_type (void *, unsigned int);
+static bfd_boolean stab_complex_type (void *, unsigned int);
+static bfd_boolean stab_bool_type (void *, unsigned int);
+static bfd_boolean stab_enum_type
+ (void *, const char *, const char **, bfd_signed_vma *);
+static bfd_boolean stab_pointer_type (void *);
+static bfd_boolean stab_function_type (void *, int, bfd_boolean);
+static bfd_boolean stab_reference_type (void *);
+static bfd_boolean stab_range_type (void *, bfd_signed_vma, bfd_signed_vma);
+static bfd_boolean stab_array_type
+ (void *, bfd_signed_vma, bfd_signed_vma, bfd_boolean);
+static bfd_boolean stab_set_type (void *, bfd_boolean);
+static bfd_boolean stab_offset_type (void *);
+static bfd_boolean stab_method_type (void *, bfd_boolean, int, bfd_boolean);
+static bfd_boolean stab_const_type (void *);
+static bfd_boolean stab_volatile_type (void *);
+static bfd_boolean stab_start_struct_type
+ (void *, const char *, unsigned int, bfd_boolean, unsigned int);
+static bfd_boolean stab_struct_field
+ (void *, const char *, bfd_vma, bfd_vma, enum debug_visibility);
+static bfd_boolean stab_end_struct_type (void *);
+static bfd_boolean stab_start_class_type
+ (void *, const char *, unsigned int, bfd_boolean, unsigned int,
+ bfd_boolean, bfd_boolean);
+static bfd_boolean stab_class_static_member
+ (void *, const char *, const char *, enum debug_visibility);
+static bfd_boolean stab_class_baseclass
+ (void *, bfd_vma, bfd_boolean, enum debug_visibility);
+static bfd_boolean stab_class_start_method (void *, const char *);
+static bfd_boolean stab_class_method_variant
+ (void *, const char *, enum debug_visibility, bfd_boolean, bfd_boolean,
+ bfd_vma, bfd_boolean);
+static bfd_boolean stab_class_static_method_variant
+ (void *, const char *, enum debug_visibility, bfd_boolean, bfd_boolean);
+static bfd_boolean stab_class_end_method (void *);
+static bfd_boolean stab_end_class_type (void *);
+static bfd_boolean stab_typedef_type (void *, const char *);
+static bfd_boolean stab_tag_type
+ (void *, const char *, unsigned int, enum debug_type_kind);
+static bfd_boolean stab_typdef (void *, const char *);
+static bfd_boolean stab_tag (void *, const char *);
+static bfd_boolean stab_int_constant (void *, const char *, bfd_vma);
+static bfd_boolean stab_float_constant (void *, const char *, double);
+static bfd_boolean stab_typed_constant (void *, const char *, bfd_vma);
+static bfd_boolean stab_variable
+ (void *, const char *, enum debug_var_kind, bfd_vma);
+static bfd_boolean stab_start_function (void *, const char *, bfd_boolean);
+static bfd_boolean stab_function_parameter
+ (void *, const char *, enum debug_parm_kind, bfd_vma);
+static bfd_boolean stab_start_block (void *, bfd_vma);
+static bfd_boolean stab_end_block (void *, bfd_vma);
+static bfd_boolean stab_end_function (void *);
+static bfd_boolean stab_lineno (void *, const char *, unsigned long, bfd_vma);
static const struct debug_write_fns stab_fns =
{
@@ -305,10 +299,8 @@ static const struct debug_write_fns stab_fns =
/* Routine to create an entry in a string hash table. */
static struct bfd_hash_entry *
-string_hash_newfunc (entry, table, string)
- struct bfd_hash_entry *entry;
- struct bfd_hash_table *table;
- const char *string;
+string_hash_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table, const char *string)
{
struct string_hash_entry *ret = (struct string_hash_entry *) entry;
@@ -343,13 +335,9 @@ string_hash_newfunc (entry, table, string)
/* Add a symbol to the stabs debugging information we are building. */
-static boolean
-stab_write_symbol (info, type, desc, value, string)
- struct stab_write_handle *info;
- int type;
- int desc;
- bfd_vma value;
- const char *string;
+static bfd_boolean
+stab_write_symbol (struct stab_write_handle *info, int type, int desc,
+ bfd_vma value, const char *string)
{
bfd_size_type strx;
bfd_byte sym[STAB_SYMBOL_SIZE];
@@ -360,12 +348,12 @@ stab_write_symbol (info, type, desc, value, string)
{
struct string_hash_entry *h;
- h = string_hash_lookup (&info->strhash, string, true, true);
+ h = string_hash_lookup (&info->strhash, string, TRUE, TRUE);
if (h == NULL)
{
non_fatal (_("string_hash_lookup failed: %s"),
bfd_errmsg (bfd_get_error ()));
- return false;
+ return FALSE;
}
if (h->index != -1)
strx = h->index;
@@ -400,18 +388,14 @@ stab_write_symbol (info, type, desc, value, string)
info->symbols_size += STAB_SYMBOL_SIZE;
- return true;
+ return TRUE;
}
/* Push a string on to the type stack. */
-static boolean
-stab_push_string (info, string, index, definition, size)
- struct stab_write_handle *info;
- const char *string;
- long index;
- boolean definition;
- unsigned int size;
+static bfd_boolean
+stab_push_string (struct stab_write_handle *info, const char *string,
+ long index, bfd_boolean definition, unsigned int size)
{
struct stab_type_stack *s;
@@ -429,29 +413,26 @@ stab_push_string (info, string, index, definition, size)
s->next = info->type_stack;
info->type_stack = s;
- return true;
+ return TRUE;
}
/* Push a type index which has already been defined. */
-static boolean
-stab_push_defined_type (info, index, size)
- struct stab_write_handle *info;
- long index;
- unsigned int size;
+static bfd_boolean
+stab_push_defined_type (struct stab_write_handle *info, long index,
+ unsigned int size)
{
char buf[20];
sprintf (buf, "%ld", index);
- return stab_push_string (info, buf, index, false, size);
+ return stab_push_string (info, buf, index, FALSE, size);
}
/* Pop a type off the type stack. The caller is responsible for
freeing the string. */
static char *
-stab_pop_type (info)
- struct stab_write_handle *info;
+stab_pop_type (struct stab_write_handle *info)
{
struct stab_type_stack *s;
char *ret;
@@ -477,15 +458,12 @@ stab_pop_type (info)
the symbols, *PSYMSIZE the size of the symbols, *PSTRINGS to the
strings, and *PSTRINGSIZE to the size of the strings. */
-boolean
-write_stabs_in_sections_debugging_info (abfd, dhandle, psyms, psymsize,
- pstrings, pstringsize)
- bfd *abfd;
- PTR dhandle;
- bfd_byte **psyms;
- bfd_size_type *psymsize;
- bfd_byte **pstrings;
- bfd_size_type *pstringsize;
+bfd_boolean
+write_stabs_in_sections_debugging_info (bfd *abfd, void *dhandle,
+ bfd_byte **psyms,
+ bfd_size_type *psymsize,
+ bfd_byte **pstrings,
+ bfd_size_type *pstringsize)
{
struct stab_write_handle info;
struct string_hash_entry *h;
@@ -507,7 +485,7 @@ write_stabs_in_sections_debugging_info (abfd, dhandle, psyms, psymsize,
{
non_fatal ("bfd_hash_table_init_failed: %s",
bfd_errmsg (bfd_get_error ()));
- return false;
+ return FALSE;
}
info.type_stack = NULL;
@@ -522,22 +500,22 @@ write_stabs_in_sections_debugging_info (abfd, dhandle, psyms, psymsize,
/* The initial symbol holds the string size. */
if (! stab_write_symbol (&info, 0, 0, 0, (const char *) NULL))
- return false;
+ return FALSE;
/* Output an initial N_SO symbol. */
info.so_offset = info.symbols_size;
if (! stab_write_symbol (&info, N_SO, 0, 0, bfd_get_filename (abfd)))
- return false;
+ return FALSE;
- if (! debug_write (dhandle, &stab_fns, (PTR) &info))
- return false;
+ if (! debug_write (dhandle, &stab_fns, (void *) &info))
+ return FALSE;
assert (info.pending_lbrac == (bfd_vma) -1);
/* Output a trailing N_SO. */
if (! stab_write_symbol (&info, N_SO, 0, info.last_text_address,
(const char *) NULL))
- return false;
+ return FALSE;
/* Put the string size in the initial symbol. */
bfd_put_32 (abfd, info.strings_size, info.symbols + 8);
@@ -556,15 +534,13 @@ write_stabs_in_sections_debugging_info (abfd, dhandle, psyms, psymsize,
p += strlen ((char *) p) + 1;
}
- return true;
+ return TRUE;
}
/* Start writing out information for a compilation unit. */
-static boolean
-stab_start_compilation_unit (p, filename)
- PTR p;
- const char *filename;
+static bfd_boolean
+stab_start_compilation_unit (void *p, const char *filename)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
@@ -580,10 +556,8 @@ stab_start_compilation_unit (p, filename)
/* Start writing out information for a particular source file. */
-static boolean
-stab_start_source (p, filename)
- PTR p;
- const char *filename;
+static bfd_boolean
+stab_start_source (void *p, const char *filename)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
@@ -599,9 +573,8 @@ stab_start_source (p, filename)
/* Push an empty type. This shouldn't normally happen. We just use a
void type. */
-static boolean
-stab_empty_type (p)
- PTR p;
+static bfd_boolean
+stab_empty_type (void *p)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
@@ -620,15 +593,14 @@ stab_empty_type (p)
sprintf (buf, "%ld=%ld", index, index);
- return stab_push_string (info, buf, index, false, 0);
+ return stab_push_string (info, buf, index, FALSE, 0);
}
}
/* Push a void type. */
-static boolean
-stab_void_type (p)
- PTR p;
+static bfd_boolean
+stab_void_type (void *p)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
@@ -646,17 +618,14 @@ stab_void_type (p)
sprintf (buf, "%ld=%ld", index, index);
- return stab_push_string (info, buf, index, true, 0);
+ return stab_push_string (info, buf, index, TRUE, 0);
}
}
/* Push an integer type. */
-static boolean
-stab_int_type (p, size, unsignedp)
- PTR p;
- unsigned int size;
- boolean unsignedp;
+static bfd_boolean
+stab_int_type (void *p, unsigned int size, bfd_boolean unsignedp)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
long *cache;
@@ -664,7 +633,7 @@ stab_int_type (p, size, unsignedp)
if (size <= 0 || (size > sizeof (long) && size != 8))
{
non_fatal (_("stab_int_type: bad size %u"), size);
- return false;
+ return FALSE;
}
if (unsignedp)
@@ -709,16 +678,14 @@ stab_int_type (p, size, unsignedp)
abort ();
}
- return stab_push_string (info, buf, index, true, size);
+ return stab_push_string (info, buf, index, TRUE, size);
}
}
/* Push a floating point type. */
-static boolean
-stab_float_type (p, size)
- PTR p;
- unsigned int size;
+static bfd_boolean
+stab_float_type (void *p, unsigned int size)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
@@ -736,8 +703,8 @@ stab_float_type (p, size)
char buf[50];
/* Floats are defined as a subrange of int. */
- if (! stab_int_type (info, 4, false))
- return false;
+ if (! stab_int_type (info, 4, FALSE))
+ return FALSE;
int_type = stab_pop_type (info);
index = info->type_index;
@@ -752,16 +719,14 @@ stab_float_type (p, size)
free (int_type);
- return stab_push_string (info, buf, index, true, size);
+ return stab_push_string (info, buf, index, TRUE, size);
}
}
/* Push a complex type. */
-static boolean
-stab_complex_type (p, size)
- PTR p;
- unsigned int size;
+static bfd_boolean
+stab_complex_type (void *p, unsigned int size)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
char buf[50];
@@ -772,16 +737,14 @@ stab_complex_type (p, size)
sprintf (buf, "%ld=r%ld;%u;0;", index, index, size);
- return stab_push_string (info, buf, index, true, size * 2);
+ return stab_push_string (info, buf, index, TRUE, size * 2);
}
-/* Push a boolean type. We use an XCOFF predefined type, since gdb
+/* Push a bfd_boolean type. We use an XCOFF predefined type, since gdb
always recognizes them. */
-static boolean
-stab_bool_type (p, size)
- PTR p;
- unsigned int size;
+static bfd_boolean
+stab_bool_type (void *p, unsigned int size)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
long index;
@@ -811,12 +774,9 @@ stab_bool_type (p, size)
/* Push an enum type. */
-static boolean
-stab_enum_type (p, tag, names, vals)
- PTR p;
- const char *tag;
- const char **names;
- bfd_signed_vma *vals;
+static bfd_boolean
+stab_enum_type (void *p, const char *tag, const char **names,
+ bfd_signed_vma *vals)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
size_t len;
@@ -832,10 +792,10 @@ stab_enum_type (p, tag, names, vals)
buf = (char *) xmalloc (10 + strlen (tag));
sprintf (buf, "xe%s:", tag);
/* FIXME: The size is just a guess. */
- if (! stab_push_string (info, buf, 0, false, 4))
- return false;
+ if (! stab_push_string (info, buf, 0, FALSE, 4))
+ return FALSE;
free (buf);
- return true;
+ return TRUE;
}
len = 10;
@@ -862,32 +822,28 @@ stab_enum_type (p, tag, names, vals)
if (tag == NULL)
{
/* FIXME: The size is just a guess. */
- if (! stab_push_string (info, buf, 0, false, 4))
- return false;
+ if (! stab_push_string (info, buf, 0, FALSE, 4))
+ return FALSE;
}
else
{
/* FIXME: The size is just a guess. */
if (! stab_write_symbol (info, N_LSYM, 0, 0, buf)
|| ! stab_push_defined_type (info, index, 4))
- return false;
+ return FALSE;
}
free (buf);
- return true;
+ return TRUE;
}
/* Push a modification of the top type on the stack. Cache the
results in CACHE and CACHE_ALLOC. */
-static boolean
-stab_modify_type (info, mod, size, cache, cache_alloc)
- struct stab_write_handle *info;
- int mod;
- unsigned int size;
- long **cache;
- size_t *cache_alloc;
+static bfd_boolean
+stab_modify_type (struct stab_write_handle *info, int mod,
+ unsigned int size, long **cache, size_t *cache_alloc)
{
long targindex;
long index;
@@ -899,7 +855,7 @@ stab_modify_type (info, mod, size, cache, cache_alloc)
if (targindex <= 0
|| cache == NULL)
{
- boolean definition;
+ bfd_boolean definition;
/* Either the target type has no index, or we aren't caching
this modifier. Either way we have no way of recording the
@@ -910,7 +866,7 @@ stab_modify_type (info, mod, size, cache, cache_alloc)
sprintf (buf, "%c%s", mod, s);
free (s);
if (! stab_push_string (info, buf, 0, definition, size))
- return false;
+ return FALSE;
free (buf);
}
else
@@ -941,7 +897,7 @@ stab_modify_type (info, mod, size, cache, cache_alloc)
referenced). */
free (stab_pop_type (info));
if (! stab_push_defined_type (info, index, size))
- return false;
+ return FALSE;
}
else
{
@@ -955,21 +911,20 @@ stab_modify_type (info, mod, size, cache, cache_alloc)
(*cache)[targindex] = index;
- if (! stab_push_string (info, buf, index, true, size))
- return false;
+ if (! stab_push_string (info, buf, index, TRUE, size))
+ return FALSE;
free (buf);
}
}
- return true;
+ return TRUE;
}
/* Push a pointer type. */
-static boolean
-stab_pointer_type (p)
- PTR p;
+static bfd_boolean
+stab_pointer_type (void *p)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
@@ -980,11 +935,9 @@ stab_pointer_type (p)
/* Push a function type. */
-static boolean
-stab_function_type (p, argcount, varargs)
- PTR p;
- int argcount;
- boolean varargs ATTRIBUTE_UNUSED;
+static bfd_boolean
+stab_function_type (void *p, int argcount,
+ bfd_boolean varargs ATTRIBUTE_UNUSED)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
int i;
@@ -1007,7 +960,7 @@ stab_function_type (p, argcount, varargs)
free (s);
if (! stab_write_symbol (info, N_LSYM, 0, 0, buf))
- return false;
+ return FALSE;
free (buf);
}
@@ -1019,9 +972,8 @@ stab_function_type (p, argcount, varargs)
/* Push a reference type. */
-static boolean
-stab_reference_type (p)
- PTR p;
+static bfd_boolean
+stab_reference_type (void *p)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
@@ -1032,14 +984,11 @@ stab_reference_type (p)
/* Push a range type. */
-static boolean
-stab_range_type (p, low, high)
- PTR p;
- bfd_signed_vma low;
- bfd_signed_vma high;
+static bfd_boolean
+stab_range_type (void *p, bfd_signed_vma low, bfd_signed_vma high)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
- boolean definition;
+ bfd_boolean definition;
unsigned int size;
char *s, *buf;
@@ -1052,24 +1001,21 @@ stab_range_type (p, low, high)
free (s);
if (! stab_push_string (info, buf, 0, definition, size))
- return false;
+ return FALSE;
free (buf);
- return true;
+ return TRUE;
}
/* Push an array type. */
-static boolean
-stab_array_type (p, low, high, stringp)
- PTR p;
- bfd_signed_vma low;
- bfd_signed_vma high;
- boolean stringp;
+static bfd_boolean
+stab_array_type (void *p, bfd_signed_vma low, bfd_signed_vma high,
+ bfd_boolean stringp)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
- boolean definition;
+ bfd_boolean definition;
unsigned int element_size;
char *range, *element, *buf;
long index;
@@ -1095,7 +1041,7 @@ stab_array_type (p, low, high, stringp)
attribute. */
index = info->type_index;
++info->type_index;
- definition = true;
+ definition = TRUE;
sprintf (buf, "%ld=@S;", index);
}
@@ -1109,22 +1055,20 @@ stab_array_type (p, low, high, stringp)
else
size = element_size * ((high - low) + 1);
if (! stab_push_string (info, buf, index, definition, size))
- return false;
+ return FALSE;
free (buf);
- return true;
+ return TRUE;
}
/* Push a set type. */
-static boolean
-stab_set_type (p, bitstringp)
- PTR p;
- boolean bitstringp;
+static bfd_boolean
+stab_set_type (void *p, bfd_boolean bitstringp)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
- boolean definition;
+ bfd_boolean definition;
char *s, *buf;
long index;
@@ -1144,7 +1088,7 @@ stab_set_type (p, bitstringp)
attribute. */
index = info->type_index;
++info->type_index;
- definition = true;
+ definition = TRUE;
sprintf (buf, "%ld=@S;", index);
}
@@ -1152,21 +1096,20 @@ stab_set_type (p, bitstringp)
free (s);
if (! stab_push_string (info, buf, index, definition, 0))
- return false;
+ return FALSE;
free (buf);
- return true;
+ return TRUE;
}
/* Push an offset type. */
-static boolean
-stab_offset_type (p)
- PTR p;
+static bfd_boolean
+stab_offset_type (void *p)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
- boolean definition;
+ bfd_boolean definition;
char *target, *base, *buf;
definition = info->type_stack->definition;
@@ -1181,24 +1124,21 @@ stab_offset_type (p)
free (target);
if (! stab_push_string (info, buf, 0, definition, 0))
- return false;
+ return FALSE;
free (buf);
- return true;
+ return TRUE;
}
/* Push a method type. */
-static boolean
-stab_method_type (p, domainp, argcount, varargs)
- PTR p;
- boolean domainp;
- int argcount;
- boolean varargs;
+static bfd_boolean
+stab_method_type (void *p, bfd_boolean domainp, int argcount,
+ bfd_boolean varargs)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
- boolean definition;
+ bfd_boolean definition;
char *domain, *return_type, *buf;
char **args;
int i;
@@ -1213,7 +1153,7 @@ stab_method_type (p, domainp, argcount, varargs)
if (! domainp)
{
if (! stab_empty_type (p))
- return false;
+ return FALSE;
}
definition = info->type_stack->definition;
@@ -1235,7 +1175,7 @@ stab_method_type (p, domainp, argcount, varargs)
{
args = (char **) xmalloc (1 * sizeof (*args));
if (! stab_empty_type (p))
- return false;
+ return FALSE;
definition = definition || info->type_stack->definition;
args[0] = stab_pop_type (info);
argcount = 1;
@@ -1252,7 +1192,7 @@ stab_method_type (p, domainp, argcount, varargs)
if (! varargs)
{
if (! stab_empty_type (p))
- return false;
+ return FALSE;
definition = definition || info->type_stack->definition;
args[argcount] = stab_pop_type (info);
++argcount;
@@ -1283,18 +1223,17 @@ stab_method_type (p, domainp, argcount, varargs)
free (args);
if (! stab_push_string (info, buf, 0, definition, 0))
- return false;
+ return FALSE;
free (buf);
- return true;
+ return TRUE;
}
/* Push a const version of a type. */
-static boolean
-stab_const_type (p)
- PTR p;
+static bfd_boolean
+stab_const_type (void *p)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
@@ -1304,9 +1243,8 @@ stab_const_type (p)
/* Push a volatile version of a type. */
-static boolean
-stab_volatile_type (p)
- PTR p;
+static bfd_boolean
+stab_volatile_type (void *p)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
@@ -1318,12 +1256,9 @@ stab_volatile_type (p)
return -1 if it fails. */
static long
-stab_get_struct_index (info, tag, id, kind, psize)
- struct stab_write_handle *info;
- const char *tag;
- unsigned int id;
- enum debug_type_kind kind;
- unsigned int *psize;
+stab_get_struct_index (struct stab_write_handle *info, const char *tag,
+ unsigned int id, enum debug_type_kind kind,
+ unsigned int *psize)
{
if (id >= info->type_cache.struct_types_alloc)
{
@@ -1368,17 +1303,13 @@ stab_get_struct_index (info, tag, id, kind, psize)
/* Start outputting a struct. We ignore the tag, and handle it in
stab_tag. */
-static boolean
-stab_start_struct_type (p, tag, id, structp, size)
- PTR p;
- const char *tag;
- unsigned int id;
- boolean structp;
- unsigned int size;
+static bfd_boolean
+stab_start_struct_type (void *p, const char *tag, unsigned int id,
+ bfd_boolean structp, unsigned int size)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
long index;
- boolean definition;
+ bfd_boolean definition;
char *buf;
buf = (char *) xmalloc (40);
@@ -1387,16 +1318,16 @@ stab_start_struct_type (p, tag, id, structp, size)
{
index = 0;
*buf = '\0';
- definition = false;
+ definition = FALSE;
}
else
{
index = stab_get_struct_index (info, tag, id, DEBUG_KIND_ILLEGAL,
&size);
if (index < 0)
- return false;
+ return FALSE;
sprintf (buf, "%ld=", index);
- definition = true;
+ definition = TRUE;
}
sprintf (buf + strlen (buf), "%c%u",
@@ -1404,26 +1335,22 @@ stab_start_struct_type (p, tag, id, structp, size)
size);
if (! stab_push_string (info, buf, index, definition, size))
- return false;
+ return FALSE;
info->type_stack->fields = (char *) xmalloc (1);
info->type_stack->fields[0] = '\0';
- return true;
+ return TRUE;
}
/* Add a field to a struct. */
-static boolean
-stab_struct_field (p, name, bitpos, bitsize, visibility)
- PTR p;
- const char *name;
- bfd_vma bitpos;
- bfd_vma bitsize;
- enum debug_visibility visibility;
+static bfd_boolean
+stab_struct_field (void *p, const char *name, bfd_vma bitpos,
+ bfd_vma bitsize, enum debug_visibility visibility)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
- boolean definition;
+ bfd_boolean definition;
unsigned int size;
char *s, *n;
const char *vis;
@@ -1474,19 +1401,18 @@ stab_struct_field (p, name, bitpos, bitsize, visibility)
info->type_stack->fields = n;
if (definition)
- info->type_stack->definition = true;
+ info->type_stack->definition = TRUE;
- return true;
+ return TRUE;
}
/* Finish up a struct. */
-static boolean
-stab_end_struct_type (p)
- PTR p;
+static bfd_boolean
+stab_end_struct_type (void *p)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
- boolean definition;
+ bfd_boolean definition;
long index;
unsigned int size;
char *fields, *first, *buf;
@@ -1505,32 +1431,25 @@ stab_end_struct_type (p)
free (fields);
if (! stab_push_string (info, buf, index, definition, size))
- return false;
+ return FALSE;
free (buf);
- return true;
+ return TRUE;
}
/* Start outputting a class. */
-static boolean
-stab_start_class_type (p, tag, id, structp, size, vptr, ownvptr)
- PTR p;
- const char *tag;
- unsigned int id;
- boolean structp;
- unsigned int size;
- boolean vptr;
- boolean ownvptr;
+static bfd_boolean
+stab_start_class_type (void *p, const char *tag, unsigned int id, bfd_boolean structp, unsigned int size, bfd_boolean vptr, bfd_boolean ownvptr)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
- boolean definition;
+ bfd_boolean definition;
char *vstring;
if (! vptr || ownvptr)
{
- definition = false;
+ definition = FALSE;
vstring = NULL;
}
else
@@ -1540,7 +1459,7 @@ stab_start_class_type (p, tag, id, structp, size, vptr, ownvptr)
}
if (! stab_start_struct_type (p, tag, id, structp, size))
- return false;
+ return FALSE;
if (vptr)
{
@@ -1563,22 +1482,19 @@ stab_start_class_type (p, tag, id, structp, size, vptr, ownvptr)
}
if (definition)
- info->type_stack->definition = true;
+ info->type_stack->definition = TRUE;
- return true;
+ return TRUE;
}
/* Add a static member to the class on the type stack. */
-static boolean
-stab_class_static_member (p, name, physname, visibility)
- PTR p;
- const char *name;
- const char *physname;
- enum debug_visibility visibility;
+static bfd_boolean
+stab_class_static_member (void *p, const char *name, const char *physname,
+ enum debug_visibility visibility)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
- boolean definition;
+ bfd_boolean definition;
char *s, *n;
const char *vis;
@@ -1620,22 +1536,19 @@ stab_class_static_member (p, name, physname, visibility)
info->type_stack->fields = n;
if (definition)
- info->type_stack->definition = true;
+ info->type_stack->definition = TRUE;
- return true;
+ return TRUE;
}
/* Add a base class to the class on the type stack. */
-static boolean
-stab_class_baseclass (p, bitpos, virtual, visibility)
- PTR p;
- bfd_vma bitpos;
- boolean virtual;
- enum debug_visibility visibility;
+static bfd_boolean
+stab_class_baseclass (void *p, bfd_vma bitpos, bfd_boolean virtual,
+ enum debug_visibility visibility)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
- boolean definition;
+ bfd_boolean definition;
char *s;
char *buf;
unsigned int c;
@@ -1690,17 +1603,15 @@ stab_class_baseclass (p, bitpos, virtual, visibility)
info->type_stack->baseclasses = baseclasses;
if (definition)
- info->type_stack->definition = true;
+ info->type_stack->definition = TRUE;
- return true;
+ return TRUE;
}
/* Start adding a method to the class on the type stack. */
-static boolean
-stab_class_start_method (p, name)
- PTR p;
- const char *name;
+static bfd_boolean
+stab_class_start_method (void *p, const char *name)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
char *m;
@@ -1724,24 +1635,19 @@ stab_class_start_method (p, name)
info->type_stack->methods = m;
- return true;
+ return TRUE;
}
/* Add a variant, either static or not, to the current method. */
-static boolean
-stab_class_method_var (info, physname, visibility, staticp, constp, volatilep,
- voffset, contextp)
- struct stab_write_handle *info;
- const char *physname;
- enum debug_visibility visibility;
- boolean staticp;
- boolean constp;
- boolean volatilep;
- bfd_vma voffset;
- boolean contextp;
+static bfd_boolean
+stab_class_method_var (struct stab_write_handle *info, const char *physname,
+ enum debug_visibility visibility,
+ bfd_boolean staticp, bfd_boolean constp,
+ bfd_boolean volatilep, bfd_vma voffset,
+ bfd_boolean contextp)
{
- boolean definition;
+ bfd_boolean definition;
char *type;
char *context = NULL;
char visc, qualc, typec;
@@ -1817,51 +1723,42 @@ stab_class_method_var (info, physname, visibility, staticp, constp, volatilep,
}
if (definition)
- info->type_stack->definition = true;
+ info->type_stack->definition = TRUE;
- return true;
+ return TRUE;
}
/* Add a variant to the current method. */
-static boolean
-stab_class_method_variant (p, physname, visibility, constp, volatilep,
- voffset, contextp)
- PTR p;
- const char *physname;
- enum debug_visibility visibility;
- boolean constp;
- boolean volatilep;
- bfd_vma voffset;
- boolean contextp;
+static bfd_boolean
+stab_class_method_variant (void *p, const char *physname,
+ enum debug_visibility visibility,
+ bfd_boolean constp, bfd_boolean volatilep,
+ bfd_vma voffset, bfd_boolean contextp)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
- return stab_class_method_var (info, physname, visibility, false, constp,
+ return stab_class_method_var (info, physname, visibility, FALSE, constp,
volatilep, voffset, contextp);
}
/* Add a static variant to the current method. */
-static boolean
-stab_class_static_method_variant (p, physname, visibility, constp, volatilep)
- PTR p;
- const char *physname;
- enum debug_visibility visibility;
- boolean constp;
- boolean volatilep;
+static bfd_boolean
+stab_class_static_method_variant (void *p, const char *physname,
+ enum debug_visibility visibility,
+ bfd_boolean constp, bfd_boolean volatilep)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
- return stab_class_method_var (info, physname, visibility, true, constp,
- volatilep, 0, false);
+ return stab_class_method_var (info, physname, visibility, TRUE, constp,
+ volatilep, 0, FALSE);
}
/* Finish up a method. */
-static boolean
-stab_class_end_method (p)
- PTR p;
+static bfd_boolean
+stab_class_end_method (void *p)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
@@ -1871,14 +1768,13 @@ stab_class_end_method (p)
trailing semicolon. */
strcat (info->type_stack->methods, ";");
- return true;
+ return TRUE;
}
/* Finish up a class. */
-static boolean
-stab_end_class_type (p)
- PTR p;
+static bfd_boolean
+stab_end_class_type (void *p)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
size_t len;
@@ -1946,20 +1842,18 @@ stab_end_class_type (p)
free (info->type_stack->string);
info->type_stack->string = buf;
- return true;
+ return TRUE;
}
/* Push a typedef which was previously defined. */
-static boolean
-stab_typedef_type (p, name)
- PTR p;
- const char *name;
+static bfd_boolean
+stab_typedef_type (void *p, const char *name)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
struct string_hash_entry *h;
- h = string_hash_lookup (&info->typedef_hash, name, false, false);
+ h = string_hash_lookup (&info->typedef_hash, name, FALSE, FALSE);
assert (h != NULL && h->index > 0);
return stab_push_defined_type (info, h->index, h->size);
@@ -1967,12 +1861,9 @@ stab_typedef_type (p, name)
/* Push a struct, union or class tag. */
-static boolean
-stab_tag_type (p, name, id, kind)
- PTR p;
- const char *name;
- unsigned int id;
- enum debug_type_kind kind;
+static bfd_boolean
+stab_tag_type (void *p, const char *name, unsigned int id,
+ enum debug_type_kind kind)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
long index;
@@ -1980,17 +1871,15 @@ stab_tag_type (p, name, id, kind)
index = stab_get_struct_index (info, name, id, kind, &size);
if (index < 0)
- return false;
+ return FALSE;
return stab_push_defined_type (info, index, size);
}
/* Define a typedef. */
-static boolean
-stab_typdef (p, name)
- PTR p;
- const char *name;
+static bfd_boolean
+stab_typdef (void *p, const char *name)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
long index;
@@ -2016,16 +1905,16 @@ stab_typdef (p, name)
free (s);
if (! stab_write_symbol (info, N_LSYM, 0, 0, buf))
- return false;
+ return FALSE;
free (buf);
- h = string_hash_lookup (&info->typedef_hash, name, true, false);
+ h = string_hash_lookup (&info->typedef_hash, name, TRUE, FALSE);
if (h == NULL)
{
non_fatal (_("string_hash_lookup failed: %s"),
bfd_errmsg (bfd_get_error ()));
- return false;
+ return FALSE;
}
/* I don't think we care about redefinitions. */
@@ -2033,15 +1922,13 @@ stab_typdef (p, name)
h->index = index;
h->size = size;
- return true;
+ return TRUE;
}
/* Define a tag. */
-static boolean
-stab_tag (p, tag)
- PTR p;
- const char *tag;
+static bfd_boolean
+stab_tag (void *p, const char *tag)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
char *s, *buf;
@@ -2054,20 +1941,17 @@ stab_tag (p, tag)
free (s);
if (! stab_write_symbol (info, N_LSYM, 0, 0, buf))
- return false;
+ return FALSE;
free (buf);
- return true;
+ return TRUE;
}
/* Define an integer constant. */
-static boolean
-stab_int_constant (p, name, val)
- PTR p;
- const char *name;
- bfd_vma val;
+static bfd_boolean
+stab_int_constant (void *p, const char *name, bfd_vma val)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
char *buf;
@@ -2076,20 +1960,17 @@ stab_int_constant (p, name, val)
sprintf (buf, "%s:c=i%ld", name, (long) val);
if (! stab_write_symbol (info, N_LSYM, 0, 0, buf))
- return false;
+ return FALSE;
free (buf);
- return true;
+ return TRUE;
}
/* Define a floating point constant. */
-static boolean
-stab_float_constant (p, name, val)
- PTR p;
- const char *name;
- double val;
+static bfd_boolean
+stab_float_constant (void *p, const char *name, double val)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
char *buf;
@@ -2098,20 +1979,17 @@ stab_float_constant (p, name, val)
sprintf (buf, "%s:c=f%g", name, val);
if (! stab_write_symbol (info, N_LSYM, 0, 0, buf))
- return false;
+ return FALSE;
free (buf);
- return true;
+ return TRUE;
}
/* Define a typed constant. */
-static boolean
-stab_typed_constant (p, name, val)
- PTR p;
- const char *name;
- bfd_vma val;
+static bfd_boolean
+stab_typed_constant (void *p, const char *name, bfd_vma val)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
char *s, *buf;
@@ -2123,21 +2001,18 @@ stab_typed_constant (p, name, val)
free (s);
if (! stab_write_symbol (info, N_LSYM, 0, 0, buf))
- return false;
+ return FALSE;
free (buf);
- return true;
+ return TRUE;
}
/* Record a variable. */
-static boolean
-stab_variable (p, name, kind, val)
- PTR p;
- const char *name;
- enum debug_var_kind kind;
- bfd_vma val;
+static bfd_boolean
+stab_variable (void *p, const char *name, enum debug_var_kind kind,
+ bfd_vma val)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
char *s, *buf;
@@ -2196,20 +2071,17 @@ stab_variable (p, name, kind, val)
free (s);
if (! stab_write_symbol (info, stab_type, 0, val, buf))
- return false;
+ return FALSE;
free (buf);
- return true;
+ return TRUE;
}
/* Start outputting a function. */
-static boolean
-stab_start_function (p, name, globalp)
- PTR p;
- const char *name;
- boolean globalp;
+static bfd_boolean
+stab_start_function (void *p, const char *name, bfd_boolean globalp)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
char *rettype, *buf;
@@ -2227,21 +2099,17 @@ stab_start_function (p, name, globalp)
info->fun_offset = info->symbols_size;
if (! stab_write_symbol (info, N_FUN, 0, 0, buf))
- return false;
+ return FALSE;
free (buf);
- return true;
+ return TRUE;
}
/* Output a function parameter. */
-static boolean
-stab_function_parameter (p, name, kind, val)
- PTR p;
- const char *name;
- enum debug_parm_kind kind;
- bfd_vma val;
+static bfd_boolean
+stab_function_parameter (void *p, const char *name, enum debug_parm_kind kind, bfd_vma val)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
char *s, *buf;
@@ -2281,19 +2149,17 @@ stab_function_parameter (p, name, kind, val)
free (s);
if (! stab_write_symbol (info, stab_type, 0, val, buf))
- return false;
+ return FALSE;
free (buf);
- return true;
+ return TRUE;
}
/* Start a block. */
-static boolean
-stab_start_block (p, addr)
- PTR p;
- bfd_vma addr;
+static bfd_boolean
+stab_start_block (void *p, bfd_vma addr)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
@@ -2321,7 +2187,7 @@ stab_start_block (p, addr)
if (info->nesting == 1)
{
info->fnaddr = addr;
- return true;
+ return TRUE;
}
/* We have to output the LBRAC symbol after any variables which are
@@ -2333,22 +2199,20 @@ stab_start_block (p, addr)
{
if (! stab_write_symbol (info, N_LBRAC, 0, info->pending_lbrac,
(const char *) NULL))
- return false;
+ return FALSE;
}
/* Remember the address and output it later. */
info->pending_lbrac = addr - info->fnaddr;
- return true;
+ return TRUE;
}
/* End a block. */
-static boolean
-stab_end_block (p, addr)
- PTR p;
- bfd_vma addr;
+static bfd_boolean
+stab_end_block (void *p, bfd_vma addr)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
@@ -2360,7 +2224,7 @@ stab_end_block (p, addr)
{
if (! stab_write_symbol (info, N_LBRAC, 0, info->pending_lbrac,
(const char *) NULL))
- return false;
+ return FALSE;
info->pending_lbrac = (bfd_vma) -1;
}
@@ -2370,7 +2234,7 @@ stab_end_block (p, addr)
/* We ignore the outermost block. */
if (info->nesting == 0)
- return true;
+ return TRUE;
return stab_write_symbol (info, N_RBRAC, 0, addr - info->fnaddr,
(const char *) NULL);
@@ -2378,21 +2242,16 @@ stab_end_block (p, addr)
/* End a function. */
-static boolean
-stab_end_function (p)
- PTR p ATTRIBUTE_UNUSED;
+static bfd_boolean
+stab_end_function (void *p ATTRIBUTE_UNUSED)
{
- return true;
+ return TRUE;
}
/* Output a line number. */
-static boolean
-stab_lineno (p, file, lineno, addr)
- PTR p;
- const char *file;
- unsigned long lineno;
- bfd_vma addr;
+static bfd_boolean
+stab_lineno (void *p, const char *file, unsigned long lineno, bfd_vma addr)
{
struct stab_write_handle *info = (struct stab_write_handle *) p;
@@ -2404,7 +2263,7 @@ stab_lineno (p, file, lineno, addr)
if (strcmp (file, info->lineno_filename) != 0)
{
if (! stab_write_symbol (info, N_SOL, 0, addr, file))
- return false;
+ return FALSE;
info->lineno_filename = file;
}
diff --git a/contrib/binutils/config-ml.in b/contrib/binutils/config-ml.in
index aae3f87..b2e4ea9 100644
--- a/contrib/binutils/config-ml.in
+++ b/contrib/binutils/config-ml.in
@@ -1,6 +1,32 @@
# Configure fragment invoked in the post-target section for subdirs
# wanting multilib support.
#
+# Copyright (C) 1995, 1997, 1998, 1999, 2000, 2001, 2002, 2003
+# Free Software Foundation, Inc.
+#
+# This file is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330,
+# Boston, MA 02111-1307, USA.
+#
+# As a special exception to the GNU General Public License, if you
+# distribute this file as part of a program that contains a
+# configuration script generated by Autoconf, you may include it under
+# the same distribution terms that you use for the rest of that program.
+#
+# Please report bugs to <gcc-bugs@gnu.org>
+# and send patches to <gcc-patches@gnu.org>.
+
# It is advisable to support a few --enable/--disable options to let the
# user select which libraries s/he really wants.
#
@@ -17,8 +43,6 @@
# . ${srcdir}/../config-ml.in
# fi
#
-# See librx/configure.in in the libg++ distribution for an example of how
-# to handle autoconf'd libraries.
#
# Things are complicated because 6 separate cases must be handled:
# 2 (native, cross) x 3 (absolute-path, relative-not-dot, dot) = 6.
@@ -30,13 +54,10 @@
# The build tree is layed out as
#
# ./
-# libg++
# newlib
# m68020/
-# libg++
# newlib
# m68881/
-# libg++
# newlib
#
# The nice feature about this arrangement is that inter-library references
@@ -69,11 +90,6 @@
# newlib. It is up to each target to turn on multilib support for the other
# libraries as desired.
-# We have to handle being invoked by both Cygnus configure and Autoconf.
-#
-# Cygnus configure incoming variables:
-# srcdir, subdir, host, arguments
-#
# Autoconf incoming variables:
# srcdir, host, ac_configure_args
#
@@ -83,26 +99,14 @@
# Note that `host' in this case is GCC's `target'. Target libraries are
# configured for a particular host.
-if [ -n "${ac_configure_args}" ]; then
- Makefile=${ac_file-Makefile}
- ml_config_shell=${CONFIG_SHELL-/bin/sh}
- ml_arguments="${ac_configure_args}"
- ml_realsrcdir=${srcdir}
-else
- Makefile=${Makefile-Makefile}
- ml_config_shell=${config_shell-/bin/sh}
- ml_arguments="${arguments}"
- if [ -n "${subdir}" -a "${subdir}" != "." ] ; then
- ml_realsrcdir=${srcdir}/${subdir}
- else
- ml_realsrcdir=${srcdir}
- fi
-fi
+Makefile=${ac_file-Makefile}
+ml_config_shell=${CONFIG_SHELL-/bin/sh}
+ml_realsrcdir=${srcdir}
# Scan all the arguments and set all the ones we need.
ml_verbose=--verbose
-for option in ${ml_arguments}
+for option in ${ac_configure_args}
do
case $option in
--*) ;;
@@ -128,7 +132,7 @@ do
enableopt=`echo ${option} | sed 's:^--::;s:=.*$::;s:-:_:g'`
eval $enableopt="$optarg"
;;
- --norecursion | --no*)
+ --norecursion | --no-recursion)
ml_norecursion=yes
;;
--silent | --sil* | --quiet | --q*)
@@ -156,7 +160,7 @@ done
if [ "${enable_multilib}" = yes ]; then
# Compute whether this is the library's top level directory
-# (ie: not a multilib subdirectory, and not a subdirectory like libg++/src).
+# (ie: not a multilib subdirectory, and not a subdirectory like newlib/src).
# ${with_multisubdir} tells us we're in the right branch, but we could be
# in a subdir of that.
# ??? The previous version could void this test by separating the process into
@@ -397,6 +401,28 @@ mips*-*-*)
esac
;;
powerpc*-*-* | rs6000*-*-*)
+ if [ x$enable_aix64 = xno ]
+ then
+ old_multidirs="${multidirs}"
+ multidirs=""
+ for x in ${old_multidirs}; do
+ case "$x" in
+ *ppc64* ) : ;;
+ *) multidirs="${multidirs} ${x}" ;;
+ esac
+ done
+ fi
+ if [ x$enable_pthread = xno ]
+ then
+ old_multidirs="${multidirs}"
+ multidirs=""
+ for x in ${old_multidirs}; do
+ case "$x" in
+ *pthread* ) : ;;
+ *) multidirs="${multidirs} ${x}" ;;
+ esac
+ done
+ fi
if [ x$enable_softfloat = xno ]
then
old_multidirs="${multidirs}"
@@ -463,17 +489,6 @@ powerpc*-*-* | rs6000*-*-*)
esac
done
fi
- if [ x$enable_aix = xno ]
- then
- old_multidirs="${multidirs}"
- multidirs=""
- for x in ${old_multidirs}; do
- case "$x" in
- *mcall-aix* ) : ;;
- *) multidirs="${multidirs} ${x}" ;;
- esac
- done
- fi
;;
sparc*-*-*)
case " $multidirs " in
@@ -510,7 +525,7 @@ multidirs=`echo "$multidirs" | sed -e 's/^[ ][ ]*//' -e 's/[ ][ ]*$//' -e 's/[ ]
cat > Multi.tem <<\EOF
-PWD=$${PWDCMD-pwd}
+PWD_COMMAND=$${PWDCMD-pwd}
# FIXME: There should be an @-sign in front of the `if'.
# Leave out until this is tested a bit more.
@@ -518,8 +533,8 @@ multi-do:
if [ -z "$(MULTIDIRS)" ]; then \
true; \
else \
- rootpre=`${PWD}`/; export rootpre; \
- srcrootpre=`cd $(srcdir); ${PWD}`/; export srcrootpre; \
+ rootpre=`${PWD_COMMAND}`/; export rootpre; \
+ srcrootpre=`cd $(srcdir); ${PWD_COMMAND}`/; export srcrootpre; \
lib=`echo $${rootpre} | sed -e 's,^.*/\([^/][^/]*\)/$$,\1,'`; \
compiler="$(CC)"; \
for i in `$${compiler} --print-multi-lib 2>/dev/null`; do \
@@ -533,11 +548,17 @@ multi-do:
CFLAGS="$(CFLAGS) $${flags}" \
prefix="$(prefix)" \
exec_prefix="$(exec_prefix)" \
+ GCJFLAGS="$(GCJFLAGS) $${flags}" \
CXXFLAGS="$(CXXFLAGS) $${flags}" \
LIBCFLAGS="$(LIBCFLAGS) $${flags}" \
LIBCXXFLAGS="$(LIBCXXFLAGS) $${flags}" \
LDFLAGS="$(LDFLAGS) $${flags}" \
+ MULTIFLAGS="$${flags}" \
DESTDIR="$(DESTDIR)" \
+ INSTALL="$(INSTALL)" \
+ INSTALL_DATA="$(INSTALL_DATA)" \
+ INSTALL_PROGRAM="$(INSTALL_PROGRAM)" \
+ INSTALL_SCRIPT="$(INSTALL_SCRIPT)" \
$(DO)); then \
true; \
else \
@@ -555,7 +576,7 @@ multi-clean:
if [ -z "$(MULTIDIRS)" ]; then \
true; \
else \
- lib=`${PWD} | sed -e 's,^.*/\([^/][^/]*\)$$,\1,'`; \
+ lib=`${PWD_COMMAND} | sed -e 's,^.*/\([^/][^/]*\)$$,\1,'`; \
for dir in Makefile $(MULTIDIRS); do \
if [ -f ../$${dir}/$${lib}/Makefile ]; then \
if (cd ../$${dir}/$${lib}; $(MAKE) $(FLAGS_TO_PASS) $(DO)); \
@@ -723,7 +744,7 @@ if [ -n "${multidirs}" ] && [ -z "${ml_norecursion}" ]; then
;;
*)
case "${srcdir}" in
- /*) # absolute path
+ /* | [A-Za-z]:[\\/]* ) # absolute path
ml_newsrcdir=${srcdir}
;;
*) # otherwise relative
@@ -736,31 +757,32 @@ if [ -n "${multidirs}" ] && [ -z "${ml_norecursion}" ]; then
esac
case "${progname}" in
- /*) ml_recprog=${progname} ;;
+ /* | [A-Za-z]:[\\/]* ) ml_recprog=${progname} ;;
*) ml_recprog=${dotdot}${progname} ;;
esac
# FIXME: POPDIR=${PWD=`pwd`} doesn't work here.
- ML_POPDIR=`pwd`
+ ML_POPDIR=`${PWDCMD-pwd}`
cd ${ml_dir}/${ml_libdir}
if [ -f ${ml_newsrcdir}/configure ]; then
- ml_recprog="${ml_newsrcdir}/configure --cache-file=../config.cache"
+ ml_recprog="${ml_newsrcdir}/configure"
fi
# find compiler flag corresponding to ${ml_dir}
- for i in `${CC-gcc} --print-multi-lib 2>/dev/null`; do
+ for i in `${CC-gcc} --print-multi-lib 2>/dev/null`; do
dir=`echo $i | sed -e 's/;.*$//'`
if [ "${dir}" = "${ml_dir}" ]; then
flags=`echo $i | sed -e 's/^[^;]*;//' -e 's/@/ -/g'`
break
fi
done
- ml_config_env='CC="${CC_}$flags" CXX="${CXX_}$flags"'
+ ml_config_env='CC="${CC_}$flags" CXX="${CXX_}$flags" GCJ="${GCJ_}$flags"'
if [ "${with_target_subdir}" = "." ]; then
CC_=$CC' '
CXX_=$CXX' '
+ GCJ_=$GCJ' '
else
# Create a regular expression that matches any string as long
# as ML_POPDIR.
@@ -789,6 +811,18 @@ if [ -n "${multidirs}" ] && [ -z "${ml_norecursion}" ]; then
esac
done
+ GCJ_=
+ for arg in ${GCJ}; do
+ case $arg in
+ -[BIL]"${ML_POPDIR}"/*)
+ GCJ_="${GCJ_}"`echo "X${arg}" | sed -n "s/X\\(-[BIL]${popdir_rx}\\).*/\\1/p"`/${ml_dir}`echo "X${arg}" | sed -n "s/X-[BIL]${popdir_rx}\\(.*\\)/\\1/p"`' ' ;;
+ "${ML_POPDIR}"/*)
+ GCJ_="${GCJ_}"`echo "X${arg}" | sed -n "s/X\\(${popdir_rx}\\).*/\\1/p"`/${ml_dir}`echo "X${arg}" | sed -n "s/X${popdir_rx}\\(.*\\)/\\1/p"`' ' ;;
+ *)
+ GCJ_="${GCJ_}${arg} " ;;
+ esac
+ done
+
if test "x${LD_LIBRARY_PATH+set}" = xset; then
LD_LIBRARY_PATH_=
for arg in `echo "$LD_LIBRARY_PATH" | tr ':' ' '`; do
@@ -826,7 +860,7 @@ if [ -n "${multidirs}" ] && [ -z "${ml_norecursion}" ]; then
if eval ${ml_config_env} ${ml_config_shell} ${ml_recprog} \
--with-multisubdir=${ml_dir} --with-multisrctop=${multisrctop} \
- ${ml_arguments} ${ml_srcdiroption} ; then
+ ${ac_configure_args} ${ml_srcdiroption} ; then
true
else
exit 1
diff --git a/contrib/binutils/config.guess b/contrib/binutils/config.guess
index fbad77f..00ccf89 100755
--- a/contrib/binutils/config.guess
+++ b/contrib/binutils/config.guess
@@ -1,9 +1,9 @@
#! /bin/sh
# Attempt to guess a canonical system name.
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-# 2000, 2001, 2002 Free Software Foundation, Inc.
+# 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
-timestamp='2002-05-22'
+timestamp='2004-02-16'
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
@@ -88,30 +88,42 @@ if test $# != 0; then
exit 1
fi
+trap 'exit 1' 1 2 15
-dummy=dummy-$$
-trap 'rm -f $dummy.c $dummy.o $dummy.rel $dummy; exit 1' 1 2 15
+# CC_FOR_BUILD -- compiler used by this script. Note that the use of a
+# compiler to aid in system detection is discouraged as it requires
+# temporary files to be created and, as you can see below, it is a
+# headache to deal with in a portable fashion.
-# CC_FOR_BUILD -- compiler used by this script.
# Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still
# use `HOST_CC' if defined, but it is deprecated.
-set_cc_for_build='case $CC_FOR_BUILD,$HOST_CC,$CC in
- ,,) echo "int dummy(){}" > $dummy.c ;
+# Portable tmp directory creation inspired by the Autoconf team.
+
+set_cc_for_build='
+trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ;
+trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ;
+: ${TMPDIR=/tmp} ;
+ { tmp=`(umask 077 && mktemp -d -q "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
+ { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } ||
+ { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } ||
+ { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ;
+dummy=$tmp/dummy ;
+tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ;
+case $CC_FOR_BUILD,$HOST_CC,$CC in
+ ,,) echo "int x;" > $dummy.c ;
for c in cc gcc c89 c99 ; do
- ($c $dummy.c -c -o $dummy.o) >/dev/null 2>&1 ;
- if test $? = 0 ; then
+ if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then
CC_FOR_BUILD="$c"; break ;
fi ;
done ;
- rm -f $dummy.c $dummy.o $dummy.rel ;
if test x"$CC_FOR_BUILD" = x ; then
CC_FOR_BUILD=no_compiler_found ;
fi
;;
,,*) CC_FOR_BUILD=$CC ;;
,*,*) CC_FOR_BUILD=$HOST_CC ;;
-esac'
+esac ;'
# This is needed to find uname on a Pyramid OSx when run in the BSD universe.
# (ghazi@noc.rutgers.edu 1994-08-24)
@@ -168,18 +180,35 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
;;
esac
# The OS release
- release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'`
+ # Debian GNU/NetBSD machines have a different userland, and
+ # thus, need a distinct triplet. However, they do not need
+ # kernel version information, so it can be replaced with a
+ # suitable tag, in the style of linux-gnu.
+ case "${UNAME_VERSION}" in
+ Debian*)
+ release='-gnu'
+ ;;
+ *)
+ release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'`
+ ;;
+ esac
# Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM:
# contains redundant information, the shorter form:
# CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used.
echo "${machine}-${os}${release}"
exit 0 ;;
+ amd64:OpenBSD:*:*)
+ echo x86_64-unknown-openbsd${UNAME_RELEASE}
+ exit 0 ;;
amiga:OpenBSD:*:*)
echo m68k-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
arc:OpenBSD:*:*)
echo mipsel-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
+ cats:OpenBSD:*:*)
+ echo arm-unknown-openbsd${UNAME_RELEASE}
+ exit 0 ;;
hp300:OpenBSD:*:*)
echo m68k-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
@@ -198,6 +227,9 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
mvmeppc:OpenBSD:*:*)
echo powerpc-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
+ pegasos:OpenBSD:*:*)
+ echo powerpc-unknown-openbsd${UNAME_RELEASE}
+ exit 0 ;;
pmax:OpenBSD:*:*)
echo mipsel-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
@@ -213,69 +245,65 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
*:OpenBSD:*:*)
echo ${UNAME_MACHINE}-unknown-openbsd${UNAME_RELEASE}
exit 0 ;;
+ *:ekkoBSD:*:*)
+ echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE}
+ exit 0 ;;
+ macppc:MirBSD:*:*)
+ echo powerppc-unknown-mirbsd${UNAME_RELEASE}
+ exit 0 ;;
+ *:MirBSD:*:*)
+ echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE}
+ exit 0 ;;
alpha:OSF1:*:*)
if test $UNAME_RELEASE = "V4.0"; then
UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'`
fi
+ # According to Compaq, /usr/sbin/psrinfo has been available on
+ # OSF/1 and Tru64 systems produced since 1995. I hope that
+ # covers most systems running today. This code pipes the CPU
+ # types through head -n 1, so we only detect the type of CPU 0.
+ ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1`
+ case "$ALPHA_CPU_TYPE" in
+ "EV4 (21064)")
+ UNAME_MACHINE="alpha" ;;
+ "EV4.5 (21064)")
+ UNAME_MACHINE="alpha" ;;
+ "LCA4 (21066/21068)")
+ UNAME_MACHINE="alpha" ;;
+ "EV5 (21164)")
+ UNAME_MACHINE="alphaev5" ;;
+ "EV5.6 (21164A)")
+ UNAME_MACHINE="alphaev56" ;;
+ "EV5.6 (21164PC)")
+ UNAME_MACHINE="alphapca56" ;;
+ "EV5.7 (21164PC)")
+ UNAME_MACHINE="alphapca57" ;;
+ "EV6 (21264)")
+ UNAME_MACHINE="alphaev6" ;;
+ "EV6.7 (21264A)")
+ UNAME_MACHINE="alphaev67" ;;
+ "EV6.8CB (21264C)")
+ UNAME_MACHINE="alphaev68" ;;
+ "EV6.8AL (21264B)")
+ UNAME_MACHINE="alphaev68" ;;
+ "EV6.8CX (21264D)")
+ UNAME_MACHINE="alphaev68" ;;
+ "EV6.9A (21264/EV69A)")
+ UNAME_MACHINE="alphaev69" ;;
+ "EV7 (21364)")
+ UNAME_MACHINE="alphaev7" ;;
+ "EV7.9 (21364A)")
+ UNAME_MACHINE="alphaev79" ;;
+ esac
# A Vn.n version is a released version.
# A Tn.n version is a released field test version.
# A Xn.n version is an unreleased experimental baselevel.
# 1.2 uses "1.2" for uname -r.
- cat <<EOF >$dummy.s
- .data
-\$Lformat:
- .byte 37,100,45,37,120,10,0 # "%d-%x\n"
-
- .text
- .globl main
- .align 4
- .ent main
-main:
- .frame \$30,16,\$26,0
- ldgp \$29,0(\$27)
- .prologue 1
- .long 0x47e03d80 # implver \$0
- lda \$2,-1
- .long 0x47e20c21 # amask \$2,\$1
- lda \$16,\$Lformat
- mov \$0,\$17
- not \$1,\$18
- jsr \$26,printf
- ldgp \$29,0(\$26)
- mov 0,\$16
- jsr \$26,exit
- .end main
-EOF
- eval $set_cc_for_build
- $CC_FOR_BUILD $dummy.s -o $dummy 2>/dev/null
- if test "$?" = 0 ; then
- case `./$dummy` in
- 0-0)
- UNAME_MACHINE="alpha"
- ;;
- 1-0)
- UNAME_MACHINE="alphaev5"
- ;;
- 1-1)
- UNAME_MACHINE="alphaev56"
- ;;
- 1-101)
- UNAME_MACHINE="alphapca56"
- ;;
- 2-303)
- UNAME_MACHINE="alphaev6"
- ;;
- 2-307)
- UNAME_MACHINE="alphaev67"
- ;;
- 2-1307)
- UNAME_MACHINE="alphaev68"
- ;;
- esac
- fi
- rm -f $dummy.s $dummy
echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[VTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
exit 0 ;;
+ Alpha*:OpenVMS:*:*)
+ echo alpha-hp-vms
+ exit 0 ;;
Alpha\ *:Windows_NT*:*)
# How do we know it's Interix rather than the generic POSIX subsystem?
# Should we change UNAME_MACHINE based on the output of uname instead
@@ -297,6 +325,9 @@ EOF
*:OS/390:*:*)
echo i370-ibm-openedition
exit 0 ;;
+ *:OS400:*:*)
+ echo powerpc-ibm-os400
+ exit 0 ;;
arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
echo arm-acorn-riscix${UNAME_RELEASE}
exit 0;;
@@ -314,6 +345,13 @@ EOF
NILE*:*:*:dcosx)
echo pyramid-pyramid-svr4
exit 0 ;;
+ DRS?6000:unix:4.0:6*)
+ echo sparc-icl-nx6
+ exit 0 ;;
+ DRS?6000:UNIX_SV:4.2*:7*)
+ case `/usr/bin/uname -p` in
+ sparc) echo sparc-icl-nx7 && exit 0 ;;
+ esac ;;
sun4H:SunOS:5.*:*)
echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
exit 0 ;;
@@ -382,6 +420,9 @@ EOF
*:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*)
echo m68k-unknown-mint${UNAME_RELEASE}
exit 0 ;;
+ m68k:machten:*:*)
+ echo m68k-apple-machten${UNAME_RELEASE}
+ exit 0 ;;
powerpc:machten:*:*)
echo powerpc-apple-machten${UNAME_RELEASE}
exit 0 ;;
@@ -420,16 +461,18 @@ EOF
exit (-1);
}
EOF
- $CC_FOR_BUILD $dummy.c -o $dummy \
- && ./$dummy `echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` \
- && rm -f $dummy.c $dummy && exit 0
- rm -f $dummy.c $dummy
+ $CC_FOR_BUILD -o $dummy $dummy.c \
+ && $dummy `echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` \
+ && exit 0
echo mips-mips-riscos${UNAME_RELEASE}
exit 0 ;;
Motorola:PowerMAX_OS:*:*)
echo powerpc-motorola-powermax
exit 0 ;;
- Night_Hawk:*:*:PowerMAX_OS)
+ Motorola:*:4.3:PL8-*)
+ echo powerpc-harris-powermax
+ exit 0 ;;
+ Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*)
echo powerpc-harris-powermax
exit 0 ;;
Night_Hawk:Power_UNIX:*:*)
@@ -504,8 +547,7 @@ EOF
exit(0);
}
EOF
- $CC_FOR_BUILD $dummy.c -o $dummy && ./$dummy && rm -f $dummy.c $dummy && exit 0
- rm -f $dummy.c $dummy
+ $CC_FOR_BUILD -o $dummy $dummy.c && $dummy && exit 0
echo rs6000-ibm-aix3.2.5
elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then
echo rs6000-ibm-aix3.2.4
@@ -603,11 +645,21 @@ EOF
exit (0);
}
EOF
- (CCOPTS= $CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null) && HP_ARCH=`./$dummy`
- if test -z "$HP_ARCH"; then HP_ARCH=hppa; fi
- rm -f $dummy.c $dummy
+ (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy`
+ test -z "$HP_ARCH" && HP_ARCH=hppa
fi ;;
esac
+ if [ ${HP_ARCH} = "hppa2.0w" ]
+ then
+ # avoid double evaluation of $set_cc_for_build
+ test -n "$CC_FOR_BUILD" || eval $set_cc_for_build
+ if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E -) | grep __LP64__ >/dev/null
+ then
+ HP_ARCH="hppa2.0w"
+ else
+ HP_ARCH="hppa64"
+ fi
+ fi
echo ${HP_ARCH}-hp-hpux${HPUX_REV}
exit 0 ;;
ia64:HP-UX:*:*)
@@ -641,8 +693,7 @@ EOF
exit (0);
}
EOF
- $CC_FOR_BUILD $dummy.c -o $dummy && ./$dummy && rm -f $dummy.c $dummy && exit 0
- rm -f $dummy.c $dummy
+ $CC_FOR_BUILD -o $dummy $dummy.c && $dummy && exit 0
echo unknown-hitachi-hiuxwe2
exit 0 ;;
9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* )
@@ -700,21 +751,26 @@ EOF
CRAY*TS:*:*:*)
echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
exit 0 ;;
- CRAY*T3D:*:*:*)
- echo alpha-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
- exit 0 ;;
CRAY*T3E:*:*:*)
echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
exit 0 ;;
CRAY*SV1:*:*:*)
echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
exit 0 ;;
+ *:UNICOS/mp:*:*)
+ echo nv1-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/'
+ exit 0 ;;
F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*)
FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'`
echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
exit 0 ;;
+ 5000:UNIX_System_V:4.*:*)
+ FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'`
+ FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'`
+ echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}"
+ exit 0 ;;
i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*)
echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE}
exit 0 ;;
@@ -725,7 +781,21 @@ EOF
echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
exit 0 ;;
*:FreeBSD:*:*)
- echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
+ # Determine whether the default compiler uses glibc.
+ eval $set_cc_for_build
+ sed 's/^ //' << EOF >$dummy.c
+ #include <features.h>
+ #if __GLIBC__ >= 2
+ LIBC=gnu
+ #else
+ LIBC=
+ #endif
+EOF
+ eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=`
+ # GNU/KFreeBSD systems have a "k" prefix to indicate we are using
+ # FreeBSD's kernel, but not the complete OS.
+ case ${LIBC} in gnu) kernel_only='k' ;; esac
+ echo ${UNAME_MACHINE}-unknown-${kernel_only}freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`${LIBC:+-$LIBC}
exit 0 ;;
i*:CYGWIN*:*)
echo ${UNAME_MACHINE}-pc-cygwin
@@ -736,14 +806,17 @@ EOF
i*:PW*:*)
echo ${UNAME_MACHINE}-pc-pw32
exit 0 ;;
- x86:Interix*:3*)
- echo i386-pc-interix3
+ x86:Interix*:[34]*)
+ echo i586-pc-interix${UNAME_RELEASE}|sed -e 's/\..*//'
+ exit 0 ;;
+ [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
+ echo i${UNAME_MACHINE}-pc-mks
exit 0 ;;
i*:Windows_NT*:* | Pentium*:Windows_NT*:*)
# How do we know it's Interix rather than the generic POSIX subsystem?
# It also conflicts with pre-2.0 versions of AT&T UWIN. Should we
# UNAME_MACHINE based on the output of uname instead of i386?
- echo i386-pc-interix
+ echo i586-pc-interix
exit 0 ;;
i*:UWIN*:*)
echo ${UNAME_MACHINE}-pc-uwin
@@ -755,14 +828,22 @@ EOF
echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
exit 0 ;;
*:GNU:*:*)
+ # the GNU system
echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
exit 0 ;;
+ *:GNU/*:*:*)
+ # other systems with GNU libc and userland
+ echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu
+ exit 0 ;;
i*86:Minix:*:*)
echo ${UNAME_MACHINE}-pc-minix
exit 0 ;;
arm*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit 0 ;;
+ cris:Linux:*:*)
+ echo cris-axis-linux-gnu
+ exit 0 ;;
ia64:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit 0 ;;
@@ -786,8 +867,26 @@ EOF
#endif
EOF
eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=`
- rm -f $dummy.c
- test x"${CPU}" != x && echo "${CPU}-pc-linux-gnu" && exit 0
+ test x"${CPU}" != x && echo "${CPU}-unknown-linux-gnu" && exit 0
+ ;;
+ mips64:Linux:*:*)
+ eval $set_cc_for_build
+ sed 's/^ //' << EOF >$dummy.c
+ #undef CPU
+ #undef mips64
+ #undef mips64el
+ #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL)
+ CPU=mips64el
+ #else
+ #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB)
+ CPU=mips64
+ #else
+ CPU=
+ #endif
+ #endif
+EOF
+ eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=`
+ test x"${CPU}" != x && echo "${CPU}-unknown-linux-gnu" && exit 0
;;
ppc:Linux:*:*)
echo powerpc-unknown-linux-gnu
@@ -823,6 +922,9 @@ EOF
s390:Linux:*:* | s390x:Linux:*:*)
echo ${UNAME_MACHINE}-ibm-linux
exit 0 ;;
+ sh64*:Linux:*:*)
+ echo ${UNAME_MACHINE}-unknown-linux-gnu
+ exit 0 ;;
sh*:Linux:*:*)
echo ${UNAME_MACHINE}-unknown-linux-gnu
exit 0 ;;
@@ -849,7 +951,7 @@ EOF
;;
a.out-i386-linux)
echo "${UNAME_MACHINE}-pc-linux-gnuaout"
- exit 0 ;;
+ exit 0 ;;
coff-i386)
echo "${UNAME_MACHINE}-pc-linux-gnucoff"
exit 0 ;;
@@ -880,9 +982,11 @@ EOF
LIBC=gnuaout
#endif
#endif
+ #ifdef __dietlibc__
+ LIBC=dietlibc
+ #endif
EOF
eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=`
- rm -f $dummy.c
test x"${LIBC}" != x && echo "${UNAME_MACHINE}-pc-linux-${LIBC}" && exit 0
test x"${TENTATIVE}" != x && echo "${TENTATIVE}" && exit 0
;;
@@ -900,6 +1004,26 @@ EOF
# Use sysv4.2uw... so that sysv4* matches it.
echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION}
exit 0 ;;
+ i*86:OS/2:*:*)
+ # If we were able to find `uname', then EMX Unix compatibility
+ # is probably installed.
+ echo ${UNAME_MACHINE}-pc-os2-emx
+ exit 0 ;;
+ i*86:XTS-300:*:STOP)
+ echo ${UNAME_MACHINE}-unknown-stop
+ exit 0 ;;
+ i*86:atheos:*:*)
+ echo ${UNAME_MACHINE}-unknown-atheos
+ exit 0 ;;
+ i*86:syllable:*:*)
+ echo ${UNAME_MACHINE}-pc-syllable
+ exit 0 ;;
+ i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*)
+ echo i386-unknown-lynxos${UNAME_RELEASE}
+ exit 0 ;;
+ i*86:*DOS:*:*)
+ echo ${UNAME_MACHINE}-pc-msdosdjgpp
+ exit 0 ;;
i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*)
UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'`
if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then
@@ -921,22 +1045,19 @@ EOF
UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name`
echo ${UNAME_MACHINE}-pc-isc$UNAME_REL
elif /bin/uname -X 2>/dev/null >/dev/null ; then
- UNAME_REL=`(/bin/uname -X|egrep Release|sed -e 's/.*= //')`
- (/bin/uname -X|egrep i80486 >/dev/null) && UNAME_MACHINE=i486
- (/bin/uname -X|egrep '^Machine.*Pentium' >/dev/null) \
+ UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')`
+ (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486
+ (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \
&& UNAME_MACHINE=i586
- (/bin/uname -X|egrep '^Machine.*Pent ?II' >/dev/null) \
+ (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \
&& UNAME_MACHINE=i686
- (/bin/uname -X|egrep '^Machine.*Pentium Pro' >/dev/null) \
+ (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \
&& UNAME_MACHINE=i686
echo ${UNAME_MACHINE}-pc-sco$UNAME_REL
else
echo ${UNAME_MACHINE}-pc-sysv32
fi
exit 0 ;;
- i*86:*DOS:*:*)
- echo ${UNAME_MACHINE}-pc-msdosdjgpp
- exit 0 ;;
pc:*:*:*)
# Left here for compatibility:
# uname -m prints for DJGPP always 'pc', but it prints nothing about
@@ -960,9 +1081,15 @@ EOF
# "miniframe"
echo m68010-convergent-sysv
exit 0 ;;
+ mc68k:UNIX:SYSTEM5:3.51m)
+ echo m68k-convergent-sysv
+ exit 0 ;;
+ M680?0:D-NIX:5.3:*)
+ echo m68k-diab-dnix
+ exit 0 ;;
M68*:*:R3V[567]*:*)
test -r /sysV68 && echo 'm68k-motorola-sysv' && exit 0 ;;
- 3[34]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0)
+ 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0)
OS_REL=''
test -r /etc/.relid \
&& OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid`
@@ -979,9 +1106,6 @@ EOF
mc68030:UNIX_System_V:4.*:*)
echo m68k-atari-sysv4
exit 0 ;;
- i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.0*:*)
- echo i386-unknown-lynxos${UNAME_RELEASE}
- exit 0 ;;
TSUNAMI:LynxOS:2.*:*)
echo sparc-unknown-lynxos${UNAME_RELEASE}
exit 0 ;;
@@ -1053,6 +1177,9 @@ EOF
SX-5:SUPER-UX:*:*)
echo sx5-nec-superux${UNAME_RELEASE}
exit 0 ;;
+ SX-6:SUPER-UX:*:*)
+ echo sx6-nec-superux${UNAME_RELEASE}
+ exit 0 ;;
Power*:Rhapsody:*:*)
echo powerpc-apple-rhapsody${UNAME_RELEASE}
exit 0 ;;
@@ -1060,7 +1187,11 @@ EOF
echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE}
exit 0 ;;
*:Darwin:*:*)
- echo `uname -p`-apple-darwin${UNAME_RELEASE}
+ case `uname -p` in
+ *86) UNAME_PROCESSOR=i686 ;;
+ powerpc) UNAME_PROCESSOR=powerpc ;;
+ esac
+ echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
exit 0 ;;
*:procnto*:*:* | *:QNX:[0123456789]*:*)
UNAME_PROCESSOR=`uname -p`
@@ -1073,7 +1204,7 @@ EOF
*:QNX:*:4*)
echo i386-pc-qnx
exit 0 ;;
- NSR-[GKLNPTVW]:NONSTOP_KERNEL:*:*)
+ NSR-?:NONSTOP_KERNEL:*:*)
echo nsr-tandem-nsk${UNAME_RELEASE}
exit 0 ;;
*:NonStop-UX:*:*)
@@ -1096,11 +1227,6 @@ EOF
fi
echo ${UNAME_MACHINE}-unknown-plan9
exit 0 ;;
- i*86:OS/2:*:*)
- # If we were able to find `uname', then EMX Unix compatibility
- # is probably installed.
- echo ${UNAME_MACHINE}-pc-os2-emx
- exit 0 ;;
*:TOPS-10:*:*)
echo pdp10-unknown-tops10
exit 0 ;;
@@ -1119,11 +1245,11 @@ EOF
*:ITS:*:*)
echo pdp10-unknown-its
exit 0 ;;
- i*86:XTS-300:*:STOP)
- echo ${UNAME_MACHINE}-unknown-stop
+ SEI:*:*:SEIUX)
+ echo mips-sei-seiux${UNAME_RELEASE}
exit 0 ;;
- i*86:atheos:*:*)
- echo ${UNAME_MACHINE}-unknown-atheos
+ *:DragonFly:*:*)
+ echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
exit 0 ;;
esac
@@ -1245,8 +1371,7 @@ main ()
}
EOF
-$CC_FOR_BUILD $dummy.c -o $dummy 2>/dev/null && ./$dummy && rm -f $dummy.c $dummy && exit 0
-rm -f $dummy.c $dummy
+$CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && $dummy && exit 0
# Apollos put the system type in the environment.
diff --git a/contrib/binutils/config.if b/contrib/binutils/config.if
index 3958928..2655bc3 100644
--- a/contrib/binutils/config.if
+++ b/contrib/binutils/config.if
@@ -2,9 +2,7 @@
# Don't call it directly. This shell script fragment is called to
# determine:
#
-# 1. libstcxx_interface: the interface name for libstdc++.
-# 2. cxx_interface: the interface name for c++.
-# 3. libc_interface: the interface name for libc.
+# 1. libstcxx_incdir: the interface name for libstdc++.
#
# Get the top level src dir.
@@ -21,73 +19,19 @@ else
if_topsrcdir=${top_srcdir}
fi
-if [ "${enable_libstdcxx_v3}" = "yes" ] ; then
- libstdcxx_srcdir=${if_topsrcdir}/libstdc++-v3
-else
- libstdcxx_srcdir=${if_topsrcdir}/libstdc++
+# Set libstdcxx_incdir.
+# This is the same as gcc/configure.in and libstdc++-v3/acinclude.m4.
+if test -z "$gcc_version"; then
+ if test -z "${gcc_version_trigger}" \
+ && test -f ${if_topsrcdir}/gcc/version.c; then
+ gcc_version_trigger=${if_topsrcdir}/gcc/version.c
+ fi
+ if test -f "${gcc_version_trigger}"; then
+ gcc_version_full=`grep version_string "${gcc_version_trigger}" | sed -e 's/.*"\([^"]*\)".*/\1/'`
+ else
+ gcc_version_full=`$CC -v 2>&1 | sed -n 's/^gcc version //p'`
+ fi
+ gcc_version=`echo ${gcc_version_full} | sed -e 's/\([^ ]*\) .*/\1/'`
fi
+libstdcxx_incdir=c++/${gcc_version}
-if [ -f ${libstdcxx_srcdir}/Makefile.in ]; then
-# We check libstdc++ for libstdcxx_interface.
-libstdcxx_interface=`grep "^INTERFACE" ${libstdcxx_srcdir}/Makefile.in | sed 's/INTERFACE[ ]*=[ ]*\(.*\)/\1/'`
-else
-libstdcxx_interface=
-fi
-
-if [ -f ${if_topsrcdir}/gcc/cp/Makefile.in ]; then
-# We check gcc/cp for cxx_interface.
-cxx_interface=`grep "^INTERFACE" ${if_topsrcdir}/gcc/cp/Makefile.in | sed 's/INTERFACE[ ]*=[ ]*\(.*\)/\1/'`
-else
-cxx_interface=
-fi
-
-# The trickiest part is libc_interface.
-if [ -z "${libc_interface}" ]
-then
- case ${target_os} in
- *linux*libc1*|*linux*libc5*)
- case ${target_alias} in
- *alpha*|*powerpc*)
- libc_interface=-libc5.9-
- ;;
- *)
- libc_interface=-libc5-
- ;;
- esac
- ;;
- *linux*gnu*)
- # We have to work harder to figure it out.
- if [ ${target_alias} = ${build_alias} ]
- then
- dummy=if$$
- cat >$dummy.c <<EOF
-#include <features.h>
-main(argc, argv)
- int argc;
- char *argv[];
-{
- printf("%d\n", __GLIBC_MINOR__);
- return 0;
-}
-EOF
- ${CC-cc} $dummy.c -o $dummy 2>/dev/null
- if [ "$?" = 0 ]
- then
- libc_interface=-libc6.`./$dummy`-
- rm -f $dummy.c $dummy
- else
- # It should never happen.
- echo "Cannot find the GNU C library minor version number." >&2
- rm -f $dummy.c $dummy
- exit 1
- fi
- else
- # Cross compiling. Assume glibc 2.2.
- libc_interface=-libc6.2-
- fi
- ;;
- *)
- libc_interface=-
- ;;
- esac
-fi
diff --git a/contrib/binutils/config.sub b/contrib/binutils/config.sub
index 69f444e..d2e3557 100755
--- a/contrib/binutils/config.sub
+++ b/contrib/binutils/config.sub
@@ -1,9 +1,9 @@
#! /bin/sh
# Configuration validation subroutine script.
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-# 2000, 2001, 2002 Free Software Foundation, Inc.
+# 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
-timestamp='2002-05-22'
+timestamp='2004-02-16'
# This file is (in principle) common to ALL GNU software.
# The presence of a machine in this file suggests that SOME GNU software
@@ -118,7 +118,8 @@ esac
# Here we must recognize all the valid KERNEL-OS combinations.
maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
case $maybe_os in
- nto-qnx* | linux-gnu* | storm-chaos* | os2-emx* | windows32-* | rtmk-nova*)
+ nto-qnx* | linux-gnu* | linux-dietlibc | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | \
+ kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*)
os=-$maybe_os
basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
;;
@@ -228,28 +229,42 @@ case $basic_machine in
| a29k \
| alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
| alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
+ | am33_2.0 \
| arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr \
| c4x | clipper \
| d10v | d30v | dlx | dsp16xx \
| fr30 | frv \
| h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
| i370 | i860 | i960 | ia64 \
+ | ip2k | iq2000 \
| m32r | m68000 | m68k | m88k | mcore \
- | mips | mips16 | mips64 | mips64el | mips64orion | mips64orionel \
- | mips64vr4100 | mips64vr4100el | mips64vr4300 \
- | mips64vr4300el | mips64vr5000 | mips64vr5000el \
- | mipsbe | mipseb | mipsel | mipsle | mipstx39 | mipstx39el \
- | mipsisa32 | mipsisa64 \
+ | mips | mipsbe | mipseb | mipsel | mipsle \
+ | mips16 \
+ | mips64 | mips64el \
+ | mips64vr | mips64vrel \
+ | mips64orion | mips64orionel \
+ | mips64vr4100 | mips64vr4100el \
+ | mips64vr4300 | mips64vr4300el \
+ | mips64vr5000 | mips64vr5000el \
+ | mipsisa32 | mipsisa32el \
+ | mipsisa32r2 | mipsisa32r2el \
+ | mipsisa64 | mipsisa64el \
+ | mipsisa64r2 | mipsisa64r2el \
+ | mipsisa64sb1 | mipsisa64sb1el \
+ | mipsisa64sr71k | mipsisa64sr71kel \
+ | mipstx39 | mipstx39el \
| mn10200 | mn10300 \
+ | msp430 \
| ns16k | ns32k \
| openrisc | or32 \
| pdp10 | pdp11 | pj | pjl \
| powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \
| pyramid \
- | sh | sh[34] | sh[34]eb | shbe | shle | sh64 \
+ | sh | sh[1234] | sh[23]e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \
+ | sh64 | sh64le \
| sparc | sparc64 | sparc86x | sparclet | sparclite | sparcv9 | sparcv9b \
| strongarm \
- | tahoe | thumb | tic80 | tron \
+ | tahoe | thumb | tic4x | tic80 | tron \
| v850 | v850e \
| we32k \
| x86 | xscale | xstormy16 | xtensa \
@@ -284,7 +299,7 @@ case $basic_machine in
| arm-* | armbe-* | armle-* | armeb-* | armv*-* \
| avr-* \
| bs2000-* \
- | c[123]* | c30-* | [cjt]90-* | c54x-* \
+ | c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \
| clipper-* | cydra-* \
| d10v-* | d30v-* | dlx-* \
| elxsi-* \
@@ -292,23 +307,39 @@ case $basic_machine in
| h8300-* | h8500-* \
| hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
| i*86-* | i860-* | i960-* | ia64-* \
+ | ip2k-* | iq2000-* \
| m32r-* \
| m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
| m88110-* | m88k-* | mcore-* \
- | mips-* | mips16-* | mips64-* | mips64el-* | mips64orion-* \
- | mips64orionel-* | mips64vr4100-* | mips64vr4100el-* \
- | mips64vr4300-* | mips64vr4300el-* | mipsbe-* | mipseb-* \
- | mipsle-* | mipsel-* | mipstx39-* | mipstx39el-* \
- | none-* | np1-* | ns16k-* | ns32k-* \
+ | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
+ | mips16-* \
+ | mips64-* | mips64el-* \
+ | mips64vr-* | mips64vrel-* \
+ | mips64orion-* | mips64orionel-* \
+ | mips64vr4100-* | mips64vr4100el-* \
+ | mips64vr4300-* | mips64vr4300el-* \
+ | mips64vr5000-* | mips64vr5000el-* \
+ | mipsisa32-* | mipsisa32el-* \
+ | mipsisa32r2-* | mipsisa32r2el-* \
+ | mipsisa64-* | mipsisa64el-* \
+ | mipsisa64r2-* | mipsisa64r2el-* \
+ | mipsisa64sb1-* | mipsisa64sb1el-* \
+ | mipsisa64sr71k-* | mipsisa64sr71kel-* \
+ | mipstx39-* | mipstx39el-* \
+ | msp430-* \
+ | none-* | np1-* | nv1-* | ns16k-* | ns32k-* \
| orion-* \
| pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
| powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \
| pyramid-* \
| romp-* | rs6000-* \
- | sh-* | sh[34]-* | sh[34]eb-* | shbe-* | shle-* | sh64-* \
+ | sh-* | sh[1234]-* | sh[23]e-* | sh[34]eb-* | shbe-* \
+ | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
| sparc-* | sparc64-* | sparc86x-* | sparclet-* | sparclite-* \
| sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \
- | tahoe-* | thumb-* | tic30-* | tic54x-* | tic80-* | tron-* \
+ | tahoe-* | thumb-* \
+ | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \
+ | tron-* \
| v850-* | v850e-* | vax-* \
| we32k-* \
| x86-* | x86_64-* | xps100-* | xscale-* | xstormy16-* \
@@ -332,6 +363,9 @@ case $basic_machine in
basic_machine=a29k-amd
os=-udi
;;
+ abacus)
+ basic_machine=abacus-unknown
+ ;;
adobe68k)
basic_machine=m68010-adobe
os=-scout
@@ -346,6 +380,12 @@ case $basic_machine in
basic_machine=a29k-none
os=-bsd
;;
+ amd64)
+ basic_machine=x86_64-pc
+ ;;
+ amd64-*)
+ basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'`
+ ;;
amdahl)
basic_machine=580-amdahl
os=-sysv
@@ -405,6 +445,10 @@ case $basic_machine in
basic_machine=j90-cray
os=-unicos
;;
+ cr16c)
+ basic_machine=cr16c-unknown
+ os=-elf
+ ;;
crds | unos)
basic_machine=m68k-crds
;;
@@ -695,6 +739,10 @@ case $basic_machine in
np1)
basic_machine=np1-gould
;;
+ nv1)
+ basic_machine=nv1-cray
+ os=-unicosmp
+ ;;
nsr-tandem)
basic_machine=nsr-tandem
;;
@@ -706,6 +754,10 @@ case $basic_machine in
basic_machine=or32-unknown
os=-coff
;;
+ os400)
+ basic_machine=powerpc-ibm
+ os=-os400
+ ;;
OSE68000 | ose68000)
basic_machine=m68000-ericsson
os=-ose
@@ -728,49 +780,55 @@ case $basic_machine in
pbb)
basic_machine=m68k-tti
;;
- pc532 | pc532-*)
+ pc532 | pc532-*)
basic_machine=ns32k-pc532
;;
pentium | p5 | k5 | k6 | nexgen | viac3)
basic_machine=i586-pc
;;
- pentiumpro | p6 | 6x86 | athlon)
+ pentiumpro | p6 | 6x86 | athlon | athlon_*)
basic_machine=i686-pc
;;
- pentiumii | pentium2)
+ pentiumii | pentium2 | pentiumiii | pentium3)
basic_machine=i686-pc
;;
+ pentium4)
+ basic_machine=i786-pc
+ ;;
pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*)
basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'`
;;
pentiumpro-* | p6-* | 6x86-* | athlon-*)
basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
;;
- pentiumii-* | pentium2-*)
+ pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*)
basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'`
;;
+ pentium4-*)
+ basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'`
+ ;;
pn)
basic_machine=pn-gould
;;
power) basic_machine=power-ibm
;;
ppc) basic_machine=powerpc-unknown
- ;;
+ ;;
ppc-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'`
;;
ppcle | powerpclittle | ppc-le | powerpc-little)
basic_machine=powerpcle-unknown
- ;;
+ ;;
ppcle-* | powerpclittle-*)
basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'`
;;
ppc64) basic_machine=powerpc64-unknown
- ;;
+ ;;
ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'`
;;
ppc64le | powerpc64little | ppc64-le | powerpc64-little)
basic_machine=powerpc64le-unknown
- ;;
+ ;;
ppc64le-* | powerpc64little-*)
basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'`
;;
@@ -801,6 +859,16 @@ case $basic_machine in
basic_machine=a29k-amd
os=-udi
;;
+ sb1)
+ basic_machine=mipsisa64sb1-unknown
+ ;;
+ sb1el)
+ basic_machine=mipsisa64sb1el-unknown
+ ;;
+ sei)
+ basic_machine=mips-sei
+ os=-seiux
+ ;;
sequent)
basic_machine=i386-sequent
;;
@@ -808,6 +876,9 @@ case $basic_machine in
basic_machine=sh-hitachi
os=-hms
;;
+ sh64)
+ basic_machine=sh64-unknown
+ ;;
sparclite-wrs | simso-wrs)
basic_machine=sparclite-wrs
os=-vxworks
@@ -866,7 +937,7 @@ case $basic_machine in
sun386 | sun386i | roadrunner)
basic_machine=i386-sun
;;
- sv1)
+ sv1)
basic_machine=sv1-cray
os=-unicos
;;
@@ -874,10 +945,6 @@ case $basic_machine in
basic_machine=i386-sequent
os=-dynix
;;
- t3d)
- basic_machine=alpha-cray
- os=-unicos
- ;;
t3e)
basic_machine=alphaev5-cray
os=-unicos
@@ -890,6 +957,14 @@ case $basic_machine in
basic_machine=tic54x-unknown
os=-coff
;;
+ tic55x | c55x*)
+ basic_machine=tic55x-unknown
+ os=-coff
+ ;;
+ tic6x | c6x*)
+ basic_machine=tic6x-unknown
+ os=-coff
+ ;;
tx39)
basic_machine=mipstx39-unknown
;;
@@ -903,6 +978,10 @@ case $basic_machine in
tower | tower-32)
basic_machine=m68k-ncr
;;
+ tpf)
+ basic_machine=s390x-ibm
+ os=-tpf
+ ;;
udi29k)
basic_machine=a29k-amd
os=-udi
@@ -924,8 +1003,8 @@ case $basic_machine in
os=-vms
;;
vpp*|vx|vx-*)
- basic_machine=f301-fujitsu
- ;;
+ basic_machine=f301-fujitsu
+ ;;
vxworks960)
basic_machine=i960-wrs
os=-vxworks
@@ -946,11 +1025,7 @@ case $basic_machine in
basic_machine=hppa1.1-winbond
os=-proelf
;;
- windows32)
- basic_machine=i386-pc
- os=-windows32-msvcrt
- ;;
- xps | xps100)
+ xps | xps100)
basic_machine=xps100-honeywell
;;
ymp)
@@ -996,7 +1071,7 @@ case $basic_machine in
we32k)
basic_machine=we32k-att
;;
- sh3 | sh4 | sh3eb | sh4eb)
+ sh3 | sh4 | sh[34]eb | sh[1234]le | sh[23]ele)
basic_machine=sh-unknown
;;
sh64)
@@ -1005,7 +1080,7 @@ case $basic_machine in
sparc | sparcv9 | sparcv9b)
basic_machine=sparc-sun
;;
- cydra)
+ cydra)
basic_machine=cydra-cydrome
;;
orion)
@@ -1020,10 +1095,6 @@ case $basic_machine in
pmac | pmac-mpw)
basic_machine=powerpc-apple
;;
- c4x*)
- basic_machine=c4x-none
- os=-coff
- ;;
*-unknown)
# Make sure to match an already-canonicalized machine name.
;;
@@ -1079,18 +1150,20 @@ case $os in
| -aos* \
| -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
| -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
- | -hiux* | -386bsd* | -netbsd* | -openbsd* | -freebsd* | -riscix* \
- | -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
+ | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* | -openbsd* \
+ | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \
+ | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
| -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
| -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
| -chorusos* | -chorusrdb* \
| -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
- | -mingw32* | -linux-gnu* | -uxpv* | -beos* | -mpeix* | -udk* \
- | -interix* | -uwin* | -rhapsody* | -darwin* | -opened* \
+ | -mingw32* | -linux-gnu* | -linux-uclibc* | -uxpv* | -beos* | -mpeix* | -udk* \
+ | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
| -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
| -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \
| -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
- | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* | -powermax*)
+ | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \
+ | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly*)
# Remember, each alternative MUST END IN *, to match a version number.
;;
-qnx*)
@@ -1102,8 +1175,10 @@ case $os in
;;
esac
;;
+ -nto-qnx*)
+ ;;
-nto*)
- os=-nto-qnx
+ os=`echo $os | sed -e 's|nto|nto-qnx|'`
;;
-sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \
| -windows* | -osx | -abug | -netware* | -os9* | -beos* \
@@ -1112,6 +1187,9 @@ case $os in
-mac*)
os=`echo $os | sed -e 's|mac|macos|'`
;;
+ -linux-dietlibc)
+ os=-linux-dietlibc
+ ;;
-linux*)
os=`echo $os | sed -e 's|linux|linux-gnu|'`
;;
@@ -1124,6 +1202,9 @@ case $os in
-opened*)
os=-openedition
;;
+ -os400*)
+ os=-os400
+ ;;
-wince*)
os=-wince
;;
@@ -1145,6 +1226,9 @@ case $os in
-atheos*)
os=-atheos
;;
+ -syllable*)
+ os=-syllable
+ ;;
-386bsd)
os=-bsd
;;
@@ -1155,7 +1239,7 @@ case $os in
os=-rtmk-nova
;;
-ns2 )
- os=-nextstep2
+ os=-nextstep2
;;
-nsk*)
os=-nsk
@@ -1167,6 +1251,9 @@ case $os in
-sinix*)
os=-sysv4
;;
+ -tpf*)
+ os=-tpf
+ ;;
-triton*)
os=-sysv3
;;
@@ -1194,8 +1281,14 @@ case $os in
-xenix)
os=-xenix
;;
- -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*)
- os=-mint
+ -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*)
+ os=-mint
+ ;;
+ -aros*)
+ os=-aros
+ ;;
+ -kaos*)
+ os=-kaos
;;
-none)
;;
@@ -1228,11 +1321,14 @@ case $basic_machine in
arm*-semi)
os=-aout
;;
+ c4x-* | tic4x-*)
+ os=-coff
+ ;;
# This must come before the *-dec entry.
pdp10-*)
os=-tops20
;;
- pdp11-*)
+ pdp11-*)
os=-none
;;
*-dec | vax-*)
@@ -1325,19 +1421,19 @@ case $basic_machine in
*-next)
os=-nextstep3
;;
- *-gould)
+ *-gould)
os=-sysv
;;
- *-highlevel)
+ *-highlevel)
os=-bsd
;;
*-encore)
os=-bsd
;;
- *-sgi)
+ *-sgi)
os=-irix
;;
- *-siemens)
+ *-siemens)
os=-sysv4
;;
*-masscomp)
@@ -1406,9 +1502,15 @@ case $basic_machine in
-mvs* | -opened*)
vendor=ibm
;;
+ -os400*)
+ vendor=ibm
+ ;;
-ptx*)
vendor=sequent
;;
+ -tpf*)
+ vendor=ibm
+ ;;
-vxsim* | -vxworks* | -windiss*)
vendor=wrs
;;
diff --git a/contrib/binutils/configure b/contrib/binutils/configure
index 0d398f5..d11c49b1 100755
--- a/contrib/binutils/configure
+++ b/contrib/binutils/configure
@@ -1,96 +1,48 @@
-#!/bin/sh
+#! /bin/sh
-### WARNING: this file contains embedded tabs. Do not run untabify on this file.
-
-# Configuration script
-# Copyright (C) 1988, 90, 91, 92, 93, 94, 95, 96, 97, 98, 1999, 2000, 2001,
-# 2002 Free Software Foundation, Inc.
-
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation; either version 2 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write to the Free Software
-# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-
-# This file was originally written by K. Richard Pixley.
-
-#
-# Shell script to create proper links to machine-dependent files in
-# preparation for compilation.
-#
-# If configure succeeds, it leaves its status in config.status.
-# If configure fails after disturbing the status quo,
-# config.status is removed.
+# Guess values for system-dependent variables and create Makefiles.
+# Generated automatically using autoconf version 2.13
+# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
#
-
-export PATH || (echo "OOPS, this isn't sh. Desperation time. I will feed myself to sh."; sh $0 $argv; kill $$)
-
-remove=rm
-hard_link=ln
-symbolic_link='ln -s'
-
-#for Test
-#remove="echo rm"
-#hard_link="echo ln"
-#symbolic_link="echo ln -s"
-
-# clear some things potentially inherited from environment.
-
-Makefile=Makefile
-Makefile_in=Makefile.in
-arguments=
-build_alias=
-cache_file=config.cache
-cache_file_option=
-configdirs=
-extraconfigdirs=
-diroptions=
-enable_threads=no
-enable_shared=no
-enable_libstdcxx_v3=yes
-exec_prefix=
-exec_prefixoption=
-fatal=
-floating_point=default
-gas=default
-gcc_version=
-gcc_version_trigger=
-host_alias=NOHOST
-host_makefile_frag=
-moveifchange=
-norecursion=
-other_options=
-package_makefile_frag=
-package_makefile_rules_frag=
-prefix=/usr/local
-progname=
-program_prefix=
-program_prefixoption=
-program_suffix=
-program_suffixoption=
-program_transform_name=
-program_transform_nameoption=
-redirect=
-removing=
+# This configure script is free software; the Free Software Foundation
+# gives unlimited permission to copy, distribute and modify it.
+
+# Defaults:
+ac_help=
+ac_default_prefix=/usr/local
+# Any additions from configure.in:
+ac_help="$ac_help
+ --enable-libada Builds libada directory"
+ac_help="$ac_help
+ --enable-serial-[{host,target,build}-]configure
+ Force sequential configuration of
+ sub-packages for the host, target or build
+ machine, or all sub-packages"
+ac_help="$ac_help
+ --enable-maintainer-mode enable make rules and dependencies not useful
+ (and sometimes confusing) to the casual installer"
+
+# Initialize some variables set by options.
+# The variables have the same names as the options, with
+# dashes changed to underlines.
+build=NONE
+cache_file=./config.cache
+exec_prefix=NONE
+host=NONE
+no_create=
+nonopt=NONE
+no_recursion=
+prefix=NONE
+program_prefix=NONE
+program_suffix=NONE
+program_transform_name=s,x,x,
+silent=
site=
-site_makefile_frag=
-site_option=
srcdir=
-srctrigger=
-subdirs=
-target_alias=NOTARGET
-target_makefile_frag=
-undefs=NOUNDEFS
-version="$Revision: 1.17 $"
-x11=default
+target=NONE
+verbose=
+x_includes=NONE
+x_libraries=NONE
bindir='${exec_prefix}/bin'
sbindir='${exec_prefix}/sbin'
libexecdir='${exec_prefix}/libexec'
@@ -104,17 +56,730 @@ oldincludedir='/usr/include'
infodir='${prefix}/info'
mandir='${prefix}/man'
-### we might need to use some other shell than /bin/sh for running subshells
+# Initialize some other variables.
+subdirs=
+MFLAGS= MAKEFLAGS=
+SHELL=${CONFIG_SHELL-/bin/sh}
+# Maximum number of lines to put in a shell here document.
+ac_max_here_lines=12
+
+ac_prev=
+for ac_option
+do
+
+ # If the previous option needs an argument, assign it.
+ if test -n "$ac_prev"; then
+ eval "$ac_prev=\$ac_option"
+ ac_prev=
+ continue
+ fi
+
+ case "$ac_option" in
+ -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
+ *) ac_optarg= ;;
+ esac
+
+ # Accept the important Cygnus configure options, so we can diagnose typos.
+
+ case "$ac_option" in
+
+ -bindir | --bindir | --bindi | --bind | --bin | --bi)
+ ac_prev=bindir ;;
+ -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
+ bindir="$ac_optarg" ;;
+
+ -build | --build | --buil | --bui | --bu)
+ ac_prev=build ;;
+ -build=* | --build=* | --buil=* | --bui=* | --bu=*)
+ build="$ac_optarg" ;;
+
+ -cache-file | --cache-file | --cache-fil | --cache-fi \
+ | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
+ ac_prev=cache_file ;;
+ -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
+ | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
+ cache_file="$ac_optarg" ;;
+
+ -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
+ ac_prev=datadir ;;
+ -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
+ | --da=*)
+ datadir="$ac_optarg" ;;
+
+ -disable-* | --disable-*)
+ ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
+ # Reject names that are not valid shell variable names.
+ if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
+ { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
+ fi
+ ac_feature=`echo $ac_feature| sed 's/-/_/g'`
+ eval "enable_${ac_feature}=no" ;;
+
+ -enable-* | --enable-*)
+ ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
+ # Reject names that are not valid shell variable names.
+ if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
+ { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
+ fi
+ ac_feature=`echo $ac_feature| sed 's/-/_/g'`
+ case "$ac_option" in
+ *=*) ;;
+ *) ac_optarg=yes ;;
+ esac
+ eval "enable_${ac_feature}='$ac_optarg'" ;;
+
+ -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
+ | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
+ | --exec | --exe | --ex)
+ ac_prev=exec_prefix ;;
+ -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
+ | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
+ | --exec=* | --exe=* | --ex=*)
+ exec_prefix="$ac_optarg" ;;
+
+ -gas | --gas | --ga | --g)
+ # Obsolete; use --with-gas.
+ with_gas=yes ;;
+
+ -help | --help | --hel | --he)
+ # Omit some internal or obsolete options to make the list less imposing.
+ # This message is too long to be a string in the A/UX 3.1 sh.
+ cat << EOF
+Usage: configure [options] [host]
+Options: [defaults in brackets after descriptions]
+Configuration:
+ --cache-file=FILE cache test results in FILE
+ --help print this message
+ --no-create do not create output files
+ --quiet, --silent do not print \`checking...' messages
+ --version print the version of autoconf that created configure
+Directory and file names:
+ --prefix=PREFIX install architecture-independent files in PREFIX
+ [$ac_default_prefix]
+ --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
+ [same as prefix]
+ --bindir=DIR user executables in DIR [EPREFIX/bin]
+ --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
+ --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
+ --datadir=DIR read-only architecture-independent data in DIR
+ [PREFIX/share]
+ --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
+ --sharedstatedir=DIR modifiable architecture-independent data in DIR
+ [PREFIX/com]
+ --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
+ --libdir=DIR object code libraries in DIR [EPREFIX/lib]
+ --includedir=DIR C header files in DIR [PREFIX/include]
+ --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
+ --infodir=DIR info documentation in DIR [PREFIX/info]
+ --mandir=DIR man documentation in DIR [PREFIX/man]
+ --srcdir=DIR find the sources in DIR [configure dir or ..]
+ --program-prefix=PREFIX prepend PREFIX to installed program names
+ --program-suffix=SUFFIX append SUFFIX to installed program names
+ --program-transform-name=PROGRAM
+ run sed PROGRAM on installed program names
+EOF
+ cat << EOF
+Host type:
+ --build=BUILD configure for building on BUILD [BUILD=HOST]
+ --host=HOST configure for HOST [guessed]
+ --target=TARGET configure for TARGET [TARGET=HOST]
+Features and packages:
+ --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
+ --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
+ --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
+ --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
+ --x-includes=DIR X include files are in DIR
+ --x-libraries=DIR X library files are in DIR
+EOF
+ if test -n "$ac_help"; then
+ echo "--enable and --with options recognized:$ac_help"
+ fi
+ exit 0 ;;
+
+ -host | --host | --hos | --ho)
+ ac_prev=host ;;
+ -host=* | --host=* | --hos=* | --ho=*)
+ host="$ac_optarg" ;;
+
+ -includedir | --includedir | --includedi | --included | --include \
+ | --includ | --inclu | --incl | --inc)
+ ac_prev=includedir ;;
+ -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
+ | --includ=* | --inclu=* | --incl=* | --inc=*)
+ includedir="$ac_optarg" ;;
+
+ -infodir | --infodir | --infodi | --infod | --info | --inf)
+ ac_prev=infodir ;;
+ -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
+ infodir="$ac_optarg" ;;
+
+ -libdir | --libdir | --libdi | --libd)
+ ac_prev=libdir ;;
+ -libdir=* | --libdir=* | --libdi=* | --libd=*)
+ libdir="$ac_optarg" ;;
+
+ -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
+ | --libexe | --libex | --libe)
+ ac_prev=libexecdir ;;
+ -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
+ | --libexe=* | --libex=* | --libe=*)
+ libexecdir="$ac_optarg" ;;
+
+ -localstatedir | --localstatedir | --localstatedi | --localstated \
+ | --localstate | --localstat | --localsta | --localst \
+ | --locals | --local | --loca | --loc | --lo)
+ ac_prev=localstatedir ;;
+ -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
+ | --localstate=* | --localstat=* | --localsta=* | --localst=* \
+ | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
+ localstatedir="$ac_optarg" ;;
+
+ -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
+ ac_prev=mandir ;;
+ -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
+ mandir="$ac_optarg" ;;
+
+ -nfp | --nfp | --nf)
+ # Obsolete; use --without-fp.
+ with_fp=no ;;
+
+ -no-create | --no-create | --no-creat | --no-crea | --no-cre \
+ | --no-cr | --no-c)
+ no_create=yes ;;
+
+ -no-recursion | --no-recursion | --no-recursio | --no-recursi \
+ | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
+ no_recursion=yes ;;
+
+ -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
+ | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
+ | --oldin | --oldi | --old | --ol | --o)
+ ac_prev=oldincludedir ;;
+ -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
+ | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
+ | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
+ oldincludedir="$ac_optarg" ;;
+
+ -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
+ ac_prev=prefix ;;
+ -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
+ prefix="$ac_optarg" ;;
+
+ -program-prefix | --program-prefix | --program-prefi | --program-pref \
+ | --program-pre | --program-pr | --program-p)
+ ac_prev=program_prefix ;;
+ -program-prefix=* | --program-prefix=* | --program-prefi=* \
+ | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
+ program_prefix="$ac_optarg" ;;
+
+ -program-suffix | --program-suffix | --program-suffi | --program-suff \
+ | --program-suf | --program-su | --program-s)
+ ac_prev=program_suffix ;;
+ -program-suffix=* | --program-suffix=* | --program-suffi=* \
+ | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
+ program_suffix="$ac_optarg" ;;
+
+ -program-transform-name | --program-transform-name \
+ | --program-transform-nam | --program-transform-na \
+ | --program-transform-n | --program-transform- \
+ | --program-transform | --program-transfor \
+ | --program-transfo | --program-transf \
+ | --program-trans | --program-tran \
+ | --progr-tra | --program-tr | --program-t)
+ ac_prev=program_transform_name ;;
+ -program-transform-name=* | --program-transform-name=* \
+ | --program-transform-nam=* | --program-transform-na=* \
+ | --program-transform-n=* | --program-transform-=* \
+ | --program-transform=* | --program-transfor=* \
+ | --program-transfo=* | --program-transf=* \
+ | --program-trans=* | --program-tran=* \
+ | --progr-tra=* | --program-tr=* | --program-t=*)
+ program_transform_name="$ac_optarg" ;;
+
+ -q | -quiet | --quiet | --quie | --qui | --qu | --q \
+ | -silent | --silent | --silen | --sile | --sil)
+ silent=yes ;;
+
+ -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
+ ac_prev=sbindir ;;
+ -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
+ | --sbi=* | --sb=*)
+ sbindir="$ac_optarg" ;;
+
+ -sharedstatedir | --sharedstatedir | --sharedstatedi \
+ | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
+ | --sharedst | --shareds | --shared | --share | --shar \
+ | --sha | --sh)
+ ac_prev=sharedstatedir ;;
+ -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
+ | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
+ | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
+ | --sha=* | --sh=*)
+ sharedstatedir="$ac_optarg" ;;
+
+ -site | --site | --sit)
+ ac_prev=site ;;
+ -site=* | --site=* | --sit=*)
+ site="$ac_optarg" ;;
+
+ -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
+ ac_prev=srcdir ;;
+ -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
+ srcdir="$ac_optarg" ;;
+
+ -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
+ | --syscon | --sysco | --sysc | --sys | --sy)
+ ac_prev=sysconfdir ;;
+ -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
+ | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
+ sysconfdir="$ac_optarg" ;;
+
+ -target | --target | --targe | --targ | --tar | --ta | --t)
+ ac_prev=target ;;
+ -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
+ target="$ac_optarg" ;;
+
+ -v | -verbose | --verbose | --verbos | --verbo | --verb)
+ verbose=yes ;;
+
+ -version | --version | --versio | --versi | --vers)
+ echo "configure generated by autoconf version 2.13"
+ exit 0 ;;
+
+ -with-* | --with-*)
+ ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
+ # Reject names that are not valid shell variable names.
+ if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
+ { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
+ fi
+ ac_package=`echo $ac_package| sed 's/-/_/g'`
+ case "$ac_option" in
+ *=*) ;;
+ *) ac_optarg=yes ;;
+ esac
+ eval "with_${ac_package}='$ac_optarg'" ;;
+
+ -without-* | --without-*)
+ ac_package=`echo $ac_option|sed -e 's/-*without-//'`
+ # Reject names that are not valid shell variable names.
+ if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
+ { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
+ fi
+ ac_package=`echo $ac_package| sed 's/-/_/g'`
+ eval "with_${ac_package}=no" ;;
+
+ --x)
+ # Obsolete; use --with-x.
+ with_x=yes ;;
+
+ -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
+ | --x-incl | --x-inc | --x-in | --x-i)
+ ac_prev=x_includes ;;
+ -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
+ | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
+ x_includes="$ac_optarg" ;;
+
+ -x-libraries | --x-libraries | --x-librarie | --x-librari \
+ | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
+ ac_prev=x_libraries ;;
+ -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
+ | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
+ x_libraries="$ac_optarg" ;;
+
+ -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
+ ;;
+
+ *)
+ if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
+ echo "configure: warning: $ac_option: invalid host type" 1>&2
+ fi
+ if test "x$nonopt" != xNONE; then
+ { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
+ fi
+ nonopt="$ac_option"
+ ;;
+
+ esac
+done
+
+if test -n "$ac_prev"; then
+ { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
+fi
+
+trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
+
+# File descriptor usage:
+# 0 standard input
+# 1 file creation
+# 2 errors and warnings
+# 3 some systems may open it to /dev/tty
+# 4 used on the Kubota Titan
+# 6 checking for... messages and results
+# 5 compiler messages saved in config.log
+if test "$silent" = yes; then
+ exec 6>/dev/null
+else
+ exec 6>&1
+fi
+exec 5>./config.log
+
+echo "\
+This file contains any messages produced by compilers while
+running configure, to aid debugging if configure makes a mistake.
+" 1>&5
+
+# Strip out --no-create and --no-recursion so they do not pile up.
+# Also quote any args containing shell metacharacters.
+ac_configure_args=
+for ac_arg
+do
+ case "$ac_arg" in
+ -no-create | --no-create | --no-creat | --no-crea | --no-cre \
+ | --no-cr | --no-c) ;;
+ -no-recursion | --no-recursion | --no-recursio | --no-recursi \
+ | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
+ *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
+ ac_configure_args="$ac_configure_args '$ac_arg'" ;;
+ *) ac_configure_args="$ac_configure_args $ac_arg" ;;
+ esac
+done
+
+# NLS nuisances.
+# Only set these to C if already set. These must not be set unconditionally
+# because not all systems understand e.g. LANG=C (notably SCO).
+# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
+# Non-C LC_CTYPE values break the ctype check.
+if test "${LANG+set}" = set; then LANG=C; export LANG; fi
+if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
+if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
+if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
+
+# confdefs.h avoids OS command line length limits that DEFS can exceed.
+rm -rf conftest* confdefs.h
+# AIX cpp loses on an empty file, so make sure it contains at least a newline.
+echo > confdefs.h
+
+# A filename unique to this package, relative to the directory that
+# configure is in, which we can look for to find out if srcdir is correct.
+ac_unique_file=move-if-change
+
+# Find the source files, if location was not specified.
+if test -z "$srcdir"; then
+ ac_srcdir_defaulted=yes
+ # Try the directory containing this script, then its parent.
+ ac_prog=$0
+ ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
+ test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
+ srcdir=$ac_confdir
+ if test ! -r $srcdir/$ac_unique_file; then
+ srcdir=..
+ fi
+else
+ ac_srcdir_defaulted=no
+fi
+if test ! -r $srcdir/$ac_unique_file; then
+ if test "$ac_srcdir_defaulted" = yes; then
+ { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
+ else
+ { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
+ fi
+fi
+srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
+
+# Prefer explicitly selected file to automatically selected ones.
+if test -z "$CONFIG_SITE"; then
+ if test "x$prefix" != xNONE; then
+ CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
+ else
+ CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
+ fi
+fi
+for ac_site_file in $CONFIG_SITE; do
+ if test -r "$ac_site_file"; then
+ echo "loading site script $ac_site_file"
+ . "$ac_site_file"
+ fi
+done
+
+if test -r "$cache_file"; then
+ echo "loading cache $cache_file"
+ . $cache_file
+else
+ echo "creating cache $cache_file"
+ > $cache_file
+fi
+
+ac_ext=c
+# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
+ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
+cross_compiling=$ac_cv_prog_cc_cross
+
+ac_exeext=
+ac_objext=o
+if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
+ # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
+ if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
+ ac_n= ac_c='
+' ac_t=' '
+ else
+ ac_n=-n ac_c= ac_t=
+ fi
+else
+ ac_n= ac_c='\c' ac_t=
+fi
+
+
+
+ac_aux_dir=
+for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
+ if test -f $ac_dir/install-sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install-sh -c"
+ break
+ elif test -f $ac_dir/install.sh; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/install.sh -c"
+ break
+ fi
+done
+if test -z "$ac_aux_dir"; then
+ { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
+fi
+ac_config_guess=$ac_aux_dir/config.guess
+ac_config_sub=$ac_aux_dir/config.sub
+ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+
+
+# Do some error checking and defaulting for the host and target type.
+# The inputs are:
+# configure --host=HOST --target=TARGET --build=BUILD NONOPT
+#
+# The rules are:
+# 1. You are not allowed to specify --host, --target, and nonopt at the
+# same time.
+# 2. Host defaults to nonopt.
+# 3. If nonopt is not specified, then host defaults to the current host,
+# as determined by config.guess.
+# 4. Target and build default to nonopt.
+# 5. If nonopt is not specified, then target and build default to host.
+
+# The aliases save the names the user supplied, while $host etc.
+# will get canonicalized.
+case $host---$target---$nonopt in
+NONE---*---* | *---NONE---* | *---*---NONE) ;;
+*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
+esac
+
+
+# Make sure we can run config.sub.
+if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
+else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
+fi
+
+echo $ac_n "checking host system type""... $ac_c" 1>&6
+echo "configure:583: checking host system type" >&5
+
+host_alias=$host
+case "$host_alias" in
+NONE)
+ case $nonopt in
+ NONE)
+ if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
+ else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
+ fi ;;
+ *) host_alias=$nonopt ;;
+ esac ;;
+esac
+
+host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
+host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+echo "$ac_t""$host" 1>&6
+
+echo $ac_n "checking target system type""... $ac_c" 1>&6
+echo "configure:604: checking target system type" >&5
+
+target_alias=$target
+case "$target_alias" in
+NONE)
+ case $nonopt in
+ NONE) target_alias=$host_alias ;;
+ *) target_alias=$nonopt ;;
+ esac ;;
+esac
+
+target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
+target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+echo "$ac_t""$target" 1>&6
+
+echo $ac_n "checking build system type""... $ac_c" 1>&6
+echo "configure:622: checking build system type" >&5
+
+build_alias=$build
+case "$build_alias" in
+NONE)
+ case $nonopt in
+ NONE) build_alias=$host_alias ;;
+ *) build_alias=$nonopt ;;
+ esac ;;
+esac
+
+build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
+build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+echo "$ac_t""$build" 1>&6
+
+test "$host_alias" != "$target_alias" &&
+ test "$program_prefix$program_suffix$program_transform_name" = \
+ NONENONEs,x,x, &&
+ program_prefix=${target_alias}-
+
+if test "$program_transform_name" = s,x,x,; then
+ program_transform_name=
+else
+ # Double any \ or $. echo might interpret backslashes.
+ cat <<\EOF_SED > conftestsed
+s,\\,\\\\,g; s,\$,$$,g
+EOF_SED
+ program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
+ rm -f conftestsed
+fi
+test "$program_prefix" != NONE &&
+ program_transform_name="s,^,${program_prefix},; $program_transform_name"
+# Use a double $ so make ignores it.
+test "$program_suffix" != NONE &&
+ program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
+
+# sed with no file args requires a program.
+test "$program_transform_name" = "" && program_transform_name="s,x,x,"
+
+
+# Get 'install' or 'install-sh' and its variants.
+# Find a good install program. We prefer a C program (faster),
+# so one script is as good as another. But avoid the broken or
+# incompatible versions:
+# SysV /etc/install, /usr/sbin/install
+# SunOS /usr/etc/install
+# IRIX /sbin/install
+# AIX /bin/install
+# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
+# AFS /usr/afsws/bin/install, which mishandles nonexistent args
+# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
+# ./install, which can be erroneously created by make from ./install.sh.
+echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
+echo "configure:677: checking for a BSD compatible install" >&5
+if test -z "$INSTALL"; then
+if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
+ for ac_dir in $PATH; do
+ # Account for people who put trailing slashes in PATH elements.
+ case "$ac_dir/" in
+ /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
+ *)
+ # OSF1 and SCO ODT 3.0 have their own names for install.
+ # Don't use installbsd from OSF since it installs stuff as root
+ # by default.
+ for ac_prog in ginstall scoinst install; do
+ if test -f $ac_dir/$ac_prog; then
+ if test $ac_prog = install &&
+ grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
+ # AIX install. It has an incompatible calling convention.
+ :
+ else
+ ac_cv_path_install="$ac_dir/$ac_prog -c"
+ break 2
+ fi
+ fi
+ done
+ ;;
+ esac
+ done
+ IFS="$ac_save_IFS"
+
+fi
+ if test "${ac_cv_path_install+set}" = set; then
+ INSTALL="$ac_cv_path_install"
+ else
+ # As a last resort, use the slow shell script. We don't cache a
+ # path for INSTALL within a source directory, because that will
+ # break other packages using the cache if that directory is
+ # removed, or if the path is relative.
+ INSTALL="$ac_install_sh"
+ fi
+fi
+echo "$ac_t""$INSTALL" 1>&6
+
+# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
+# It thinks the first close brace ends the variable substitution.
+test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
+
+test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
+
+test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
+
+
+# Autoconf M4 include file defining utility macros for complex Canadian
+# cross builds.
+
+
+
+
+
+
+####
+# _NCN_TOOL_PREFIXES: Some stuff that oughtta be done in AC_CANONICAL_SYSTEM
+# or AC_INIT.
+# These demand that AC_CANONICAL_SYSTEM be called beforehand.
+
+####
+# NCN_CHECK_TARGET_TOOL(variable, prog-to-check-for,[value-if-not-found],[path])
+# Like AC_CHECK_TOOL, but tries a prefix of the target, not the host.
+# Code is pretty much lifted from autoconf2.53.
+
+
+####
+# NCN_STRICT_CHECK_TOOL(variable, prog-to-check-for,[value-if-not-found],[path])
+# Like AC_CHECK_TOOL, but requires the prefix if build!=host.
+
+
+
+####
+# NCN_STRICT_CHECK_TARGET_TOOL(variable, prog-to-check-for,[value-if-not-found],[path])
+# Like NCN_CHECK_TARGET_TOOL, but requires the prefix if build!=target.
+
+
+###
+# AC_PROG_CPP_WERROR
+# Used for autoconf 2.5x to force AC_PREPROC_IFELSE to reject code which
+# triggers warnings from the preprocessor. Will be in autoconf 2.58.
+# For now, using this also overrides header checks to use only the
+# preprocessor (matches 2.13 behavior; matching 2.58's behavior is a
+# bit harder from here).
+# Eventually autoconf will default to checking headers with the compiler
+# instead, and we'll have to do this differently.
+
+# AC_PROG_CPP_WERROR
+
+
+### we might need to use some other shell than /bin/sh for running subshells
### If we are on Windows, search for the shell. This will permit people
### to not have /bin/sh, but to be able to see /SOME/PATH/sh configure
### without also having to set CONFIG_SHELL. This code will work when
### using bash, which sets OSTYPE.
case "${OSTYPE}" in
*win32*)
- if [ x${CONFIG_SHELL} = x ]; then
- if [ ! -f /bin/sh ]; then
- if [ x${SHELL} != x ] && [ -f ${SHELL} ]; then
+ if test x${CONFIG_SHELL} = x ; then
+ if test ! -f /bin/sh ; then
+ if test x${SHELL} != x && test -f ${SHELL} ; then
CONFIG_SHELL=${SHELL}
export CONFIG_SHELL
else
@@ -139,721 +804,1268 @@ esac
config_shell=${CONFIG_SHELL-/bin/sh}
-NO_EDIT="This file was generated automatically by configure. Do not edit."
-
-## this is a little touchy and won't always work, but...
-##
-## if the argv[0] starts with a slash then it is an absolute name that can (and
-## must) be used as is.
-##
-## otherwise, if argv[0] has no slash in it, we can assume that it is on the
-## path. Since PATH might include "." we also add `pwd` to the end of PATH.
-##
-
progname=$0
# if PWD already has a value, it is probably wrong.
-if [ -n "$PWD" ]; then PWD=`${PWDCMD-pwd}`; fi
+if test -n "$PWD" ; then PWD=`${PWDCMD-pwd}`; fi
+
+# Export original configure arguments for use by sub-configures. These
+# will be expanded by make, so quote '$'.
+tmp="$progname $@"
+sed -e 's,\$,$$,g' <<EOF_SED > conftestsed.out
+$tmp
+EOF_SED
+TOPLEVEL_CONFIGURE_ARGUMENTS=`cat conftestsed.out`
+rm -f conftestsed.out
+
+
+moveifchange=${srcdir}/move-if-change
+
+# Set srcdir to "." if that's what it is.
+# This is important for multilib support.
+pwd=`${PWDCMD-pwd}`
+srcpwd=`cd ${srcdir} ; ${PWDCMD-pwd}`
+if test "${pwd}" = "${srcpwd}" ; then
+ srcdir=.
+fi
-case "${progname}" in
-/* | [A-Za-z]:[\\/]* ) ;;
-*/*) ;;
-*)
- PATH=$PATH:${PWD=`${PWDCMD-pwd}`} ; export PATH
+topsrcdir=$srcpwd
+
+extra_host_args=
+# Define the trigger file to make sure configure will re-run whenever
+# the gcc version number changes.
+if test "${with_gcc_version_trigger+set}" = set ; then
+ gcc_version_trigger="$with_gcc_version_trigger"
+ gcc_version=`grep version_string ${with_gcc_version_trigger} | sed -e 's/.*\"\([^ \"]*\)[ \"].*/\1/'`
+else
+ # If gcc's sources are available, define the trigger file.
+ if test -f ${topsrcdir}/gcc/version.c ; then
+ gcc_version_trigger=${topsrcdir}/gcc/version.c
+ gcc_version=`grep version_string ${gcc_version_trigger} | sed -e 's/.*\"\([^ \"]*\)[ \"].*/\1/'`
+ case "$ac_configure_args" in
+ *--with-gcc-version-trigger=$gcc_version_trigger* )
;;
-esac
+ * )
+ # Add to all subconfigure arguments: build, host, and target.
+ ac_configure_args="$ac_configure_args --with-gcc-version-trigger=$gcc_version_trigger"
+ ;;
+ esac
+ fi
+fi
-# Export original configure arguments for use by sub-configures.
-TOPLEVEL_CONFIGURE_ARGUMENTS="$progname $@"
-export TOPLEVEL_CONFIGURE_ARGUMENTS
+### To add a new directory to the tree, first choose whether it is a target
+### or a host dependent tool. Then put it into the appropriate list
+### (library or tools, host or target), doing a dependency sort.
-# Loop over all args
+# Subdirs will be configured in the order listed in build_configdirs,
+# configdirs, or target_configdirs; see the serialization section below.
-while :
-do
+# Dependency sorting is only needed when *configuration* must be done in
+# a particular order. In all cases a dependency should be specified in
+# the Makefile, whether or not it's implicitly specified here.
-# Break out if there are no more args
- case $# in
- 0)
- break
- ;;
- esac
+# Double entries in build_configdirs, configdirs, or target_configdirs may
+# cause circular dependencies and break everything horribly.
-# Get the first arg, and shuffle
- option=$1
- shift
+# these libraries are used by various programs built for the host environment
+#
+host_libs="intl mmalloc libiberty opcodes bfd readline tcl tk itcl tix libgui zlib"
+
+# these tools are built for the host environment
+# Note, the powerpc-eabi build depends on sim occurring before gdb in order to
+# know that we are building the simulator.
+# binutils, gas and ld appear in that order because it makes sense to run
+# "make check" in that particular order.
+host_tools="texinfo byacc flex bison binutils gas ld gcc sid sim gdb make patch prms send-pr gprof etc expect dejagnu ash bash bzip2 m4 autoconf automake libtool diff rcs fileutils shellutils time textutils wdiff find uudecode hello tar gzip indent recode release sed utils guile perl gawk findutils gettext zip fastjar"
+
+# libgcj represents the runtime libraries only used by gcj.
+libgcj="target-libffi \
+ target-boehm-gc \
+ target-zlib \
+ target-qthreads \
+ target-libjava"
+
+# these libraries are built for the target environment, and are built after
+# the host libraries and the host tools (which may be a cross compiler)
+#
+target_libraries="target-libiberty \
+ target-libgloss \
+ target-newlib \
+ target-libstdc++-v3 \
+ target-libf2c \
+ ${libgcj} \
+ target-libobjc \
+ target-libada"
+
+# these tools are built using the target libraries, and are intended to
+# run only in the target environment
+#
+# note: any program that *uses* libraries that are in the "target_libraries"
+# list belongs in this list. those programs are also very likely
+# candidates for the "native_only" list which follows
+#
+target_tools="target-examples target-groff target-gperf target-rda"
-# Make all options have two hyphens
- orig_option=$option # Save original for error messages
- case $option in
- --*) ;;
- -*) option=-$option ;;
- esac
-
-# Split out the argument for options that take them
- case $option in
- --*=*)
- optarg=`echo $option | sed -e 's/^[^=]*=//'`
- arguments="$arguments $option"
- ;;
-# These options have mandatory values. Since we didn't find an = sign,
-# the value must be in the next argument
- --bu* | --cache* | --ex* | --ho* | --pre* | --program-p* | --program-s* | --program-t* | --si* | --sr* | --ta* | --tm* | --x-* | --bi* | --sb* | --li* | --da* | --sy* | --sh* | --lo* | --in* | --ol* | --ma*)
- optarg=$1
- shift
- arguments="$arguments $option=$optarg"
- ;;
- --v)
- arguments="$arguments -v"
- ;;
- --*)
- arguments="$arguments $option"
- ;;
- esac
+################################################################################
-# Now, process the options
- case $option in
-
- --bi*)
- bindir=$optarg
- diroptions="$diroptions --bindir=$optarg"
- ;;
- --build* | --bu*)
- case "$build_alias" in
- "") build_alias=$optarg ;;
- *) echo '***' Can only configure for one build machine at a time. 1>&2
- fatal=yes
- ;;
- esac
- ;;
- --cache*)
- cache_file=$optarg
- ;;
- --da*)
- datadir=$optarg
- diroptions="$diroptions --datadir=$optarg"
- ;;
- --disable-*)
- enableopt=`echo ${option} | sed 's:^--disable-:enable_:;s:-:_:g'`
- eval $enableopt=no
- disableoptions="$disableoptions $option"
- ;;
- --enable-*)
- case "$option" in
- *=*) ;;
- *) optarg=yes ;;
- esac
-
- enableopt=`echo ${option} | sed 's:^--::;s:=.*$::;s:-:_:g'`
- eval "$enableopt=\$optarg"
- enableoptions="$enableoptions '$option'"
- ;;
- --exec-prefix* | --ex*)
- exec_prefix=$optarg
- exec_prefixoption="--exec-prefix=$optarg"
- ;;
- --gas | --g*)
- gas=yes
- ;;
- --help | --he*)
- fatal=yes
- ;;
- --host* | --ho*)
- case $host_alias in
- NOHOST) host_alias=$optarg ;;
- *) echo '***' Can only configure for one host at a time. 1>&2
- fatal=yes
- ;;
- esac
- ;;
- --inc*)
- includedir=$optarg
- diroptions="$diroptions --includedir=$optarg"
- ;;
- --inf*)
- infodir=$optarg
- diroptions="$diroptions --infodir=$optarg"
- ;;
- --libd*)
- libdir=$optarg
- diroptions="$diroptions --libdir=$optarg"
- ;;
- --libe*)
- libexecdir=$optarg
- diroptions="$diroptions --libexecdir=$optarg"
- ;;
- --lo*)
- localstatedir=$optarg
- diroptions="$diroptions --localstatedir=$optarg"
- ;;
- --ma*)
- mandir=$optarg
- diroptions="$diroptions --mandir=$optarg"
- ;;
- --nfp | --nf*)
- floating_point=no
- floating_pointoption="--nfp"
- ;;
- --norecursion | --no*)
- norecursion=yes
- ;;
- --ol*)
- oldincludedir=$optarg
- diroptions="$diroptions --oldincludedir=$optarg"
- ;;
- --prefix* | --pre*)
- prefix=$optarg
- prefixoption="--prefix=$optarg"
- ;;
- --program-prefix* | --program-p*)
- program_prefix=$optarg
- program_prefixoption="--program-prefix=$optarg"
- ;;
- --program-suffix* | --program-s*)
- program_suffix=$optarg
- program_suffixoption="--program-suffix=$optarg"
- ;;
- --program-transform-name* | --program-t*)
- # Double any backslashes or dollar signs in the argument
- program_transform_name="${program_transform_name} -e `echo ${optarg} | sed -e 's/\\\\/\\\\\\\\/g' -e 's/\\\$/$$/g'`"
- program_transform_nameoption="${program_transform_nameoption} --program-transform-name='$optarg'"
- ;;
- --rm)
- removing=--rm
- ;;
- --sb*)
- sbindir=$optarg
- diroptions="$diroptions --sbindir=$optarg"
- ;;
- --sh*)
- sharedstatedir=$optarg
- diroptions="$diroptions --sharedstatedir=$optarg"
- ;;
- --silent | --sil* | --quiet | --q*)
- redirect=">/dev/null"
- verbose=--silent
- ;;
- --site* | --sit*)
- site=$optarg
- site_option="--site=$optarg"
- ;;
- --srcdir*/ | --sr*/)
- # Remove trailing slashes. Otherwise, when the file name gets
- # bolted into an object file as debug info, it has two slashes
- # in it. Ordinarily this is ok, but emacs takes double slash
- # to mean "forget the first part".
- srcdir=`echo $optarg | sed -e 's:/$::'`
- ;;
- --srcdir* | --sr*)
- srcdir=$optarg
- ;;
- --sy*)
- sysconfdir=$optarg
- diroptions="$diroptions --sysconfdir=$optarg"
- ;;
- --target* | --ta*)
- case $target_alias in
- NOTARGET) target_alias=$optarg ;;
- *) echo '***' Can only configure for one target at a time. 1>&2
- fatal=yes
- ;;
- esac
- ;;
- --tmpdir* | --tm*)
- TMPDIR=$optarg
- tmpdiroption="--tmpdir=$optarg"
- ;;
- --verbose | --v | --verb*)
- redirect=
- verbose=--verbose
- ;;
- --version | --V | --vers*)
- echo "This is Cygnus Configure version" `echo ${version} | sed 's/[ $:]//g'`
- exit 0
- ;;
- --with-*)
- case "$option" in
- *=*) ;;
- *) optarg=yes ;;
- esac
-
- withopt=`echo ${option} | sed 's:^--::;s:=.*$::;s:-:_:g'`
- eval $withopt="\$optarg"
- withoptions="$withoptions $option"
- ;;
- --without-*)
- withopt=`echo ${option} | sed 's:^--::;s:out::;s:-:_:g'`
- eval $withopt=no
- withoutoptions="$withoutoptions $option"
- ;;
- --x) with_x=yes
- withoptions="$withoptions --with-x"
- ;;
- --x-i* | --x-l*) other_options="$other_options $orig_option"
- ;;
- --*)
- echo "configure: Unrecognized option: \"$orig_option\"; use --help for usage." >&2
- exit 1
- ;;
- *)
- case $undefs in
- NOUNDEFS) undefs=$option ;;
- *) echo '***' Can only configure for one host and one target at a time. 1>&2
- fatal=yes
- ;;
- esac
- ;;
- esac
-done
+## All tools belong in one of the four categories, and are assigned above
+## We assign ${configdirs} this way to remove all embedded newlines. This
+## is important because configure will choke if they ever get through.
+## ${configdirs} is directories we build using the host tools.
+## ${target_configdirs} is directories we build using the target tools.
+#
+configdirs=`echo ${host_libs} ${host_tools}`
+target_configdirs=`echo ${target_libraries} ${target_tools}`
+
+# Only make build modules if build != host.
+# This should be done more generally, but at the moment it doesn't matter.
+if test ${host_alias} != ${build_alias} ; then
+ # This is the only build module.
+ build_modules=libiberty
+else
+ build_modules=
+fi
-# process host and target
-# Do some error checking and defaulting for the host and target type.
-# The inputs are:
-# configure --host=HOST --target=TARGET UNDEFS
-#
-# The rules are:
-# 1. You aren't allowed to specify --host, --target, and undefs at the
-# same time.
-# 2. Host defaults to undefs.
-# 3. If undefs is not specified, then host defaults to the current host,
-# as determined by config.guess.
-# 4. Target defaults to undefs.
-# 5. If undefs is not specified, then target defaults to host.
-
-case "${fatal}" in
-"")
- # Make sure that host, target & undefs aren't all specified at the
- # same time.
- case $host_alias---$target_alias---$undefs in
- NOHOST---*---* | *---NOTARGET---* | *---*---NOUNDEFS)
- ;;
- *) echo '***' Can only configure for one host and one target at a time. 1>&2
- fatal=yes
- break 2
- ;;
- esac
+################################################################################
- # Now, do defaulting for host.
- case $host_alias in
- NOHOST)
- case $undefs in
- NOUNDEFS)
- # Neither --host option nor undefs were present.
- # Call config.guess.
- guesssys=`echo ${progname} | sed 's/configure$/config.guess/'`
- if host_alias=`${config_shell} ${guesssys}`
- then
- # If the string we are going to use for
- # the target is a prefix of the string
- # we just guessed for the host, then
- # assume we are running native, and force
- # the same string for both target and host.
- case $target_alias in
- NOTARGET) ;;
- *)
- if expr $host_alias : $target_alias >/dev/null
- then
- host_alias=$target_alias
- fi
- ;;
- esac
- echo "Configuring for a ${host_alias} host."
- arguments="--host=$host_alias $arguments"
- else
- echo 'Config.guess failed to determine the host type. You need to specify one.' 1>&2
- fatal=yes
- fi
- ;;
- *)
- host_alias=$undefs
- arguments="--host=$host_alias $arguments"
- undefs=NOUNDEFS
- ;;
- esac
- esac
+srcname="gnu development package"
- # Do defaulting for target. If --target option isn't present, default
- # to undefs. If undefs isn't present, default to host.
- case $target_alias in
- NOTARGET)
- case $undefs in
- NOUNDEFS)
- target_alias=$host_alias
- ;;
- *)
- target_alias=$undefs
- arguments="--target=$target_alias $arguments"
- ;;
- esac
- esac
- ;;
-*) ;;
-esac
+# This gets set non-empty for some net releases of packages.
+appdirs=""
-if [ -n "${fatal}" -o "${host_alias}" = "help" ] ; then
- exec 1>&2
- echo Usage: configure [OPTIONS] [HOST]
- echo
- echo Options: [defaults in brackets]
- echo ' --prefix=MYDIR install into MYDIR [/usr/local]'
- echo ' --exec-prefix=MYDIR install host-dependent files into MYDIR [/usr/local]'
- echo ' --help print this message [normal config]'
- echo ' --build=BUILD configure for building on BUILD [BUILD=HOST]'
- echo ' --host=HOST configure for HOST [determined via config.guess]'
- echo ' --norecursion configure this directory only [recurse]'
- echo ' --program-prefix=FOO prepend FOO to installed program names [""]'
- echo ' --program-suffix=FOO append FOO to installed program names [""]'
- echo ' --program-transform-name=P transform installed names by sed pattern P [""]'
- echo ' --site=SITE configure with site-specific makefile for SITE'
- echo ' --srcdir=DIR find the sources in DIR [. or ..]'
- echo ' --target=TARGET configure for TARGET [TARGET=HOST]'
- echo ' --tmpdir=TMPDIR create temporary files in TMPDIR [/tmp]'
- echo ' --nfp configure for software floating point [hard float]'
- echo ' --with-FOO, --with-FOO=BAR package FOO is available (parameter BAR)'
- echo ' --without-FOO package FOO is NOT available'
- echo ' --enable-FOO, --enable-FOO=BAR include feature FOO (parameter BAR)'
- echo ' --disable-FOO do not include feature FOO'
- echo
- echo 'Where HOST and TARGET are something like "sparc-sunos", "mips-sgi-irix5", etc.'
- echo
- if [ -r config.status ] ; then
- cat config.status
- fi
+# Define is_cross_compiler to save on calls to 'test'.
+is_cross_compiler=
+if test x"${host}" = x"${target}" ; then
+ is_cross_compiler=no
+else
+ is_cross_compiler=yes
+fi
- exit 1
-fi
+# Find the build and target subdir names.
+ case ${build_alias} in
+ "") build_noncanonical=${build} ;;
+ *) build_noncanonical=${build_alias} ;;
+esac
-configsub=`echo ${progname} | sed 's/configure$/config.sub/'`
-moveifchange=`echo ${progname} | sed 's/configure$/move-if-change/'`
-## the sed command below emulates the dirname command
-topsrcdir=`cd \`echo ${progname} | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'\`; ${PWDCMD-pwd}`
+ case ${host_alias} in
+ "") host_noncanonical=${build_noncanonical} ;;
+ *) host_noncanonical=${host_alias} ;;
+esac
+ case ${target_alias} in
+ "") target_noncanonical=${host_noncanonical} ;;
+ *) target_noncanonical=${target_alias} ;;
+esac
-# this is a hack. sun4 must always be a valid host alias or this will fail.
-if ${config_shell} ${configsub} sun4 >/dev/null 2>&1 ; then
- true
-else
- echo '***' cannot find config.sub. 1>&2
- exit 1
+ # Prefix 'build-' so this never conflicts with target_subdir.
+build_subdir="build-${build_noncanonical}"
+# Not really a subdirectory, but here for completeness.
+host_subdir=.
+# No prefix.
+target_subdir=${target_noncanonical}
+
+
+# Skipdirs are removed silently.
+skipdirs=
+# Noconfigdirs are removed loudly.
+noconfigdirs=""
+
+use_gnu_ld=
+# Make sure we don't let GNU ld be added if we didn't want it.
+if test x$with_gnu_ld = xno ; then
+ use_gnu_ld=no
+ noconfigdirs="$noconfigdirs ld"
fi
-touch config.junk
-if ${config_shell} ${moveifchange} config.junk config.trash ; then
- true
-else
- echo '***' cannot find move-if-change. 1>&2
- exit 1
+use_gnu_as=
+# Make sure we don't let GNU as be added if we didn't want it.
+if test x$with_gnu_as = xno ; then
+ use_gnu_as=no
+ noconfigdirs="$noconfigdirs gas"
fi
-rm -f config.junk config.trash
-case "${srcdir}" in
-"")
- if [ -r configure.in ] ; then
- srcdir=.
- else
- if [ -r ${progname}.in ] ; then
- srcdir=`echo ${progname} | sed 's:/configure$::'`
- else
- echo '***' "Can't find configure.in. Try using --srcdir=some_dir" 1>&2
- exit 1
- fi
- fi
- ;;
-*)
- # Set srcdir to "." if that's what it is.
- # This is important for multilib support.
- if [ ! -d ${srcdir} ] ; then
- echo "Invalid source directory ${srcdir}" >&2
- exit 1
- fi
- pwd=`${PWDCMD-pwd}`
- srcpwd=`cd ${srcdir} ; ${PWDCMD-pwd}`
- if [ "${pwd}" = "${srcpwd}" ] ; then
- srcdir=.
- fi
+# some tools are so dependent upon X11 that if we're not building with X,
+# it's not even worth trying to configure, much less build, that tool.
+
+case ${with_x} in
+ yes | "") ;; # the default value for this tree is that X11 is available
+ no)
+ skipdirs="${skipdirs} tk tix itcl libgui"
+ # We won't be able to build gdbtk without X.
+ enable_gdbtk=no
+ ;;
+ *) echo "*** bad value \"${with_x}\" for -with-x flag; ignored" 1>&2 ;;
esac
-### warn about some conflicting configurations.
+# Some tools are only suitable for building in a "native" situation.
+# Remove these if host!=target.
+native_only="autoconf automake libtool fileutils find gawk gettext gzip hello indent m4 rcs recode sed shellutils tar textutils uudecode wdiff gprof target-groff guile perl time ash bash bzip2 prms gnuserv target-gperf"
-case "${srcdir}" in
-".") ;;
-*)
- if [ -f ${srcdir}/config.status ] ; then
- echo '***' Cannot configure here in \"${PWD=`${PWDCMD-pwd}`}\" when \"${srcdir}\" is currently configured. 1>&2
- exit 1
- fi
-esac
+# Similarly, some are only suitable for cross toolchains.
+# Remove these if host=target.
+cross_only="target-libgloss target-newlib target-opcodes"
-# default exec_prefix
-case "${exec_prefixoption}" in
-"") exec_prefix="\$(prefix)" ;;
-*) ;;
+case $is_cross_compiler in
+ no) skipdirs="${skipdirs} ${cross_only}" ;;
+ yes) skipdirs="${skipdirs} ${native_only}" ;;
esac
-# Define the trigger file to make sure configure will re-run whenever
-# the gcc version number changes.
-if [ "${with_gcc_version_trigger+set}" = set ]; then
- gcc_version_trigger="$with_gcc_version_trigger"
- gcc_version=`grep version_string ${with_gcc_version_trigger} | sed -e 's/.*\"\([^ \"]*\)[ \"].*/\1/'`
-else
- # If gcc's sources are available, define the trigger file.
- if [ -f ${topsrcdir}/gcc/version.c ] ; then
- gcc_version_trigger=${topsrcdir}/gcc/version.c
- gcc_version=`grep version_string ${gcc_version_trigger} | sed -e 's/.*\"\([^ \"]*\)[ \"].*/\1/'`
- case "$arguments" in
- *--with-gcc-version-trigger=$gcc_version_trigger* )
- ;;
- * )
- # Make sure configure.in knows about this.
- arguments="--with-gcc-version-trigger=$gcc_version_trigger $arguments"
- ;;
- esac
- withoptions="--with-gcc-version-trigger=$gcc_version_trigger $withoptions"
- fi
+# If both --with-headers and --with-libs are specified, default to
+# --without-newlib.
+if test x"${with_headers}" != x && test x"${with_headers} != xno \
+ && test x"${with_libs}" != x && test x"${with_libs} != xno ; then
+ if test x"${with_newlib}" = x ; then
+ with_newlib=no
+ fi
fi
-### break up ${srcdir}/configure.in.
-case "`grep '^# per\-host:' ${srcdir}/configure.in`" in
-"")
- echo '***' ${srcdir}/configure.in has no \"per-host:\" line. 1>&2
- # Check for a directory that's been converted to use autoconf since
- # it was last configured.
- if grep AC_OUTPUT ${srcdir}/configure.in >/dev/null ; then
- echo '***' Hmm, looks like this directory has been autoconfiscated. 1>&2
- if [ -r ${srcdir}/configure ] ; then
- echo '***' Running the local configure script. 1>&2
- case "${cache_file}" in
- "") cache_file_option= ;;
- *) cache_file_option="--cache-file=${cache_file}" ;;
- esac
- srcdiroption="--srcdir=${srcdir}"
- case "${build_alias}" in
- "") buildopt= ;;
- *) buildopt="--build=${build_alias}" ;;
- esac
- eval exec ${config_shell} ${srcdir}/configure ${verbose} \
- ${buildopt} --host=${host_alias} --target=${target_alias} \
- ${prefixoption} ${tmpdiroption} ${exec_prefixoption} \
- ${srcdiroption} ${diroptions} \
- ${program_prefixoption} ${program_suffixoption} \
- ${program_transform_nameoption} ${site_option} \
- ${withoptions} ${withoutoptions} \
- ${enableoptions} ${disableoptions} ${floating_pointoption} \
- ${cache_file_option} ${removing} ${other_options} ${redirect}
- else
- echo '***' There is no configure script present though. 1>&2
- fi
- fi
- exit 1
- ;;
-*) ;;
+# Recognize --with-newlib/--without-newlib.
+case ${with_newlib} in
+ no) skipdirs="${skipdirs} target-newlib" ;;
+ yes) skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'` ;;
esac
-case "`grep '^# per\-target:' ${srcdir}/configure.in`" in
-"")
- echo '***' ${srcdir}/configure.in has no \"per-target:\" line. 1>&2
- exit 1
- ;;
-*) ;;
+# Configure extra directories which are host specific
+
+case "${host}" in
+ *-cygwin*)
+ configdirs="$configdirs libtermcap" ;;
esac
-case "${TMPDIR}" in
-"") TMPDIR=/tmp ; export TMPDIR ;;
-*) ;;
+# Remove more programs from consideration, based on the host or
+# target this usually means that a port of the program doesn't
+# exist yet.
+
+case "${host}" in
+ hppa*64*-*-*)
+ noconfigdirs="$noconfigdirs byacc"
+ ;;
+ i[3456789]86-*-vsta)
+ noconfigdirs="$noconfigdirs tcl expect dejagnu make texinfo bison patch flex byacc send-pr gprof uudecode dejagnu diff guile perl itcl tix gnuserv gettext"
+ ;;
+ i[3456789]86-*-go32* | i[3456789]86-*-msdosdjgpp*)
+ noconfigdirs="$noconfigdirs tcl tk expect dejagnu send-pr uudecode guile itcl tix gnuserv libffi"
+ ;;
+ i[3456789]86-*-mingw32*)
+ # noconfigdirs="tcl tk expect dejagnu make texinfo bison patch flex byacc send-pr uudecode dejagnu diff guile perl itcl tix gnuserv"
+ noconfigdirs="$noconfigdirs expect dejagnu autoconf automake send-pr rcs guile perl texinfo libtool"
+ ;;
+ i[3456789]86-*-beos*)
+ noconfigdirs="$noconfigdirs tk itcl tix libgui gdb"
+ ;;
+ *-*-cygwin*)
+ noconfigdirs="$noconfigdirs autoconf automake send-pr rcs guile perl"
+ ;;
+ *-*-netbsd*)
+ noconfigdirs="$noconfigdirs rcs"
+ ;;
+ ppc*-*-pe)
+ noconfigdirs="$noconfigdirs patch diff make tk tcl expect dejagnu autoconf automake texinfo bison send-pr gprof rcs guile perl itcl tix gnuserv"
+ ;;
+ powerpc-*-beos*)
+ noconfigdirs="$noconfigdirs tk itcl tix libgui gdb dejagnu readline"
+ ;;
+ *-*-darwin*)
+ noconfigdirs="$noconfigdirs tk itcl tix libgui"
+ ;;
esac
-# keep this filename short for &%*%$*# 14 char file names and 8+3 file names
-tmpdir=${TMPDIR}/cNf$$
-mkdir ${tmpdir} || exit 1
-tmpfile=${tmpdir}/cNf$$
-# Note that under many versions of sh a trap handler for 0 will *override* any
-# exit status you explicitly specify! At this point, the only non-error exit
-# is at the end of the script; these actions are duplicated there, minus
-# the "exit 1". Don't use "exit 0" anywhere after this without resetting the
-# trap handler, or you'll lose.
-trap "rm -rf Makefile.tem ${tmpdir}; exit 1" 0 1 2 15
-
-# split ${srcdir}/configure.in into common, per-host, per-target,
-# and post-target parts. Post-target is optional.
-sed -e '/^# per\-host:/,$d' ${srcdir}/configure.in > ${tmpfile}.com
-sed -e '1,/^# per\-host:/d' -e '/^# per\-target:/,$d' ${srcdir}/configure.in > ${tmpfile}.hst
-if grep '^# post-target:' ${srcdir}/configure.in >/dev/null ; then
- sed -e '1,/^# per\-target:/d' -e '/^# post\-target:/,$d' ${srcdir}/configure.in > ${tmpfile}.tgt
- sed -e '1,/^# post\-target:/d' ${srcdir}/configure.in > ${tmpfile}.pos
-else
- sed -e '1,/^# per\-target:/d' ${srcdir}/configure.in > ${tmpfile}.tgt
- echo >${tmpfile}.pos
-fi
-
-### do common part of configure.in
-
-# If the language specific compiler does not exist, but the "gcc" directory does,
-# we will skip this directory; in this case the sub-directory's common part
-# of configure.in will create a small shell script "skip-this-dir" containing
-# commands to completely clean up any temporary or created files.
-
-. ${tmpfile}.com
-
-if test -f skip-this-dir; then
- # Perform the same cleanup as the trap handler, minus the "exit 1" of course,
- # and reset the trap handler.
- trap 0
- rm -rf Makefile* ${tmpdir}
- # Execute the final clean-up actions
- ${config_shell} skip-this-dir
- # and stop configuring this directory.
- exit 0
-fi
-
-# some sanity checks on configure.in
-case "${srctrigger}" in
-"")
- echo '***' srctrigger not set in ${PWD=`${PWDCMD-pwd}`}/configure.in. 1>&2
- exit 1
- ;;
-*) ;;
+# Check whether --enable-libada or --disable-libada was given.
+if test "${enable_libada+set}" = set; then
+ enableval="$enable_libada"
+ ENABLE_LIBADA=$enableval
+else
+ ENABLE_LIBADA=yes
+fi
+
+if test "${ENABLE_LIBADA}" != "yes" ; then
+ noconfigdirs="$noconfigdirs target-libada"
+fi
+
+# Save it here so that, even in case of --enable-libgcj, if the Java
+# front-end isn't enabled, we still get libgcj disabled.
+libgcj_saved=$libgcj
+case $enable_libgcj in
+yes)
+ # If we reset it here, it won't get added to noconfigdirs in the
+ # target-specific build rules, so it will be forcibly enabled
+ # (unless the Java language itself isn't enabled).
+ libgcj=
+ ;;
+no)
+ # Make sure we get it printed in the list of not supported target libs.
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
esac
-case "${build_alias}" in
-"")
- if result=`${config_shell} ${configsub} ${host_alias}` ; then
- build_cpu=`echo $result | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
- build_vendor=`echo $result | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
- build_os=`echo $result | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
- build=${build_cpu}-${build_vendor}-${build_os}
- build_alias=${host_alias}
- fi
- ;;
-*)
- if result=`${config_shell} ${configsub} ${build_alias}` ; then
- buildopt="--build=${build_alias}"
- build_cpu=`echo $result | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
- build_vendor=`echo $result | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
- build_os=`echo $result | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
- build=${build_cpu}-${build_vendor}-${build_os}
- else
- echo "Unrecognized build system name ${build_alias}." 1>&2
- exit 1
- fi
+case "${target}" in
+ *-*-chorusos)
+ noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
+ ;;
+ powerpc-*-darwin*)
+ noconfigdirs="$noconfigdirs bfd binutils ld gas opcodes gdb gprof"
+ noconfigdirs="$noconfigdirs target-libobjc"
+ ;;
+ *-*-darwin*)
+ noconfigdirs="$noconfigdirs bfd binutils ld gas opcodes gdb gprof"
+ noconfigdirs="$noconfigdirs target-libobjc ${libgcj}"
+ ;;
+ *-*-freebsd[12] | *-*-freebsd[12].* | *-*-freebsd*aout*)
+ noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
+ ;;
+ *-*-kaos*)
+ # Remove unsupported stuff on all kaOS configurations.
+ skipdirs="target-libiberty ${libgcj} target-libstdc++-v3 target-libf2c target-librx"
+ skipdirs="$skipdirs target-libobjc target-examples target-groff target-gperf"
+ skipdirs="$skipdirs zlib fastjar target-libjava target-boehm-gc target-zlib"
+ noconfigdirs="$noconfigdirs target-libgloss"
+ ;;
+ *-*-netbsd*)
+ # Skip some stuff on all NetBSD configurations.
+ noconfigdirs="$noconfigdirs target-newlib target-libiberty target-libgloss"
+
+ # Skip some stuff that's unsupported on some NetBSD configurations.
+ case "${target}" in
+ i*86-*-netbsdelf*) ;;
+ arm*-*-netbsdelf*) ;;
+ *)
+ noconfigdirs="$noconfigdirs ${libgcj}"
;;
+ esac
+ ;;
+ *-*-netware)
+ noconfigdirs="$noconfigdirs target-libstdc++-v3 target-newlib target-libiberty target-libgloss ${libgcj}"
+ ;;
+ *-*-rtems*)
+ noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+ case ${target} in
+ h8300*-*-* | h8500-*-*)
+ noconfigdirs="$noconfigdirs target-libf2c"
+ ;;
+ *) ;;
+ esac
+ ;;
+ *-*-uclinux*)
+ noconfigdirs="$noconfigdirs target-newlib target-libgloss target-rda ${libgcj}"
+ ;;
+ *-*-vxworks*)
+ noconfigdirs="$noconfigdirs target-newlib target-libgloss target-libiberty ${libgcj}"
+ ;;
+ alpha*-dec-osf*)
+ # ld works, but does not support shared libraries.
+ # newlib is not 64 bit ready. I'm not sure about fileutils.
+ # gas doesn't generate exception information.
+ noconfigdirs="$noconfigdirs gas ld fileutils target-newlib target-libgloss"
+ ;;
+ alpha*-*-*vms*)
+ noconfigdirs="$noconfigdirs gdb ld target-newlib target-libgloss ${libgcj}"
+ ;;
+ alpha*-*-linux*)
+ # newlib is not 64 bit ready
+ noconfigdirs="$noconfigdirs target-newlib target-libgloss"
+ ;;
+ alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu)
+ noconfigdirs="$noconfigdirs target-newlib target-libgloss"
+ ;;
+ alpha*-*-*)
+ # newlib is not 64 bit ready
+ noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
+ ;;
+ am33_2.0-*-linux*)
+ noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss"
+ ;;
+ sh-*-linux*)
+ noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss"
+ ;;
+ sh*-*-pe|mips*-*-pe|*arm-wince-pe)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ noconfigdirs="$noconfigdirs target-examples"
+ noconfigdirs="$noconfigdirs target-libiberty texinfo send-pr"
+ noconfigdirs="$noconfigdirs tcl tix tk itcl libgui sim"
+ noconfigdirs="$noconfigdirs expect dejagnu"
+ # the C++ libraries don't build on top of CE's C libraries
+ noconfigdirs="$noconfigdirs target-libstdc++-v3"
+ noconfigdirs="$noconfigdirs target-newlib"
+ case "${host}" in
+ *-*-cygwin*) ;; # keep gdb and readline
+ *) noconfigdirs="$noconfigdirs gdb readline"
+ ;;
+ esac
+ ;;
+ arc-*-*)
+ noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+ ;;
+ arm-*-coff | strongarm-*-coff | xscale-*-coff)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
+ arm-*-elf* | strongarm-*-elf* | xscale-*-elf*)
+ noconfigdirs="$noconfigdirs target-libffi target-qthreads"
+ ;;
+ arm-*-pe*)
+ noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+ ;;
+ arm-*-oabi*)
+ noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+ ;;
+ thumb-*-coff)
+ noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+ ;;
+ thumb-*-elf)
+ noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+ ;;
+ thumb-*-oabi)
+ noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+ ;;
+ thumb-*-pe)
+ noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+ ;;
+ arm-*-riscix*)
+ noconfigdirs="$noconfigdirs ld target-libgloss ${libgcj}"
+ ;;
+ avr-*-*)
+ noconfigdirs="$noconfigdirs target-libiberty target-libstdc++-v3 ${libgcj}"
+ ;;
+ c4x-*-* | tic4x-*-*)
+ noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
+ ;;
+ c54x*-*-* | tic54x-*-*)
+ noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj} gcc gdb newlib"
+ ;;
+ cris-*-*)
+ noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss"
+ ;;
+ d10v-*-*)
+ noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
+ ;;
+ d30v-*-*)
+ noconfigdirs="$noconfigdirs ${libgcj} gdb"
+ ;;
+ fr30-*-elf*)
+ noconfigdirs="$noconfigdirs ${libgcj} gdb"
+ ;;
+ frv-*-*)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
+ h8300*-*-*)
+ noconfigdirs="$noconfigdirs target-libgloss ${libgcj} target-libf2c"
+ ;;
+ h8500-*-*)
+ noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj} target-libf2c"
+ ;;
+ hppa*64*-*-linux* | parisc*64*-*-linux*)
+ # In this case, it's because the hppa64-linux target is for
+ # the kernel only at this point and has no libc, and thus no
+ # headers, crt*.o, etc., all of which are needed by these.
+ noconfigdirs="$noconfigdirs target-zlib"
+ ;;
+ hppa*-*-*elf* | \
+ parisc*-*-linux* | hppa*-*-linux* | \
+ hppa*-*-lites* | \
+ hppa*-*-openbsd* | \
+ hppa*64*-*-*)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ # Do configure ld/binutils/gas for this case.
+ ;;
+ hppa*-*-*)
+ # According to Alexandre Oliva <aoliva@redhat.com>, libjava won't
+ # build on HP-UX 10.20.
+ noconfigdirs="$noconfigdirs ld shellutils ${libgcj}"
+ ;;
+ i960-*-*)
+ noconfigdirs="$noconfigdirs ${libgcj} gdb"
+ ;;
+ ia64*-*-elf*)
+ # No gdb support yet.
+ noconfigdirs="$noconfigdirs tix readline mmalloc libgui itcl gdb"
+ ;;
+ ia64*-**-hpux*)
+ # No gdb or ld support yet.
+ noconfigdirs="$noconfigdirs ${libgcj} tix readline mmalloc libgui itcl gdb ld"
+ ;;
+ i[3456789]86-*-coff | i[3456789]86-*-elf)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
+ i[3456789]86-*-freebsd* | i[3456789]86-*-kfreebsd*-gnu)
+ noconfigdirs="$noconfigdirs target-newlib target-libgloss"
+ ;;
+ i[3456789]86-*-linux*)
+ # The GCC port for glibc1 has no MD_FALLBACK_FRAME_STATE_FOR, so let's
+ # not build java stuff by default.
+ case "${target}" in
+ *-*-*libc1*)
+ noconfigdirs="$noconfigdirs ${libgcj}";;
+ esac
+
+ # This section makes it possible to build newlib natively on linux.
+ # If we are using a cross compiler then don't configure newlib.
+ if test x${is_cross_compiler} != xno ; then
+ noconfigdirs="$noconfigdirs target-newlib"
+ fi
+ noconfigdirs="$noconfigdirs target-libgloss"
+ # If we are not using a cross compiler, do configure newlib.
+ # Note however, that newlib will only be configured in this situation
+ # if the --with-newlib option has been given, because otherwise
+ # 'target-newlib' will appear in skipdirs.
+ ;;
+ i[3456789]86-*-mingw32*)
+ target_configdirs="$target_configdirs target-mingw"
+ noconfigdirs="$noconfigdirs expect target-libgloss ${libgcj}"
+
+ # Can't build gdb for mingw32 if not native.
+ case "${host}" in
+ i[3456789]86-*-mingw32) ;; # keep gdb tcl tk expect etc.
+ *) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl tix gnuserv"
+ ;;
+ esac
+ ;;
+ *-*-cygwin*)
+ target_configdirs="$target_configdirs target-libtermcap target-winsup"
+ noconfigdirs="$noconfigdirs target-gperf target-libgloss ${libgcj}"
+ # always build newlib.
+ skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
+
+ # Can't build gdb for Cygwin if not native.
+ case "${host}" in
+ *-*-cygwin*) ;; # keep gdb tcl tk expect etc.
+ *) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl tix libgui gnuserv"
+ ;;
+ esac
+ ;;
+ i[3456789]86-*-pe)
+ noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
+ ;;
+ i[3456789]86-*-sco3.2v5*)
+ # The linker does not yet know about weak symbols in COFF,
+ # and is not configured to handle mixed ELF and COFF.
+ noconfigdirs="$noconfigdirs ld target-libgloss ${libgcj}"
+ ;;
+ i[3456789]86-*-sco*)
+ noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
+ ;;
+ i[3456789]86-*-solaris2*)
+ noconfigdirs="$noconfigdirs target-libgloss"
+ ;;
+ i[3456789]86-*-sysv4*)
+ noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+ ;;
+ i[3456789]86-*-beos*)
+ noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
+ ;;
+ m32r-*-*)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
+ m68hc11-*-*|m6811-*-*|m68hc12-*-*|m6812-*-*)
+ noconfigdirs="$noconfigdirs target-libiberty target-libstdc++-v3 ${libgcj}"
+ ;;
+ m68k-*-elf*)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
+ m68k-*-coff*)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
+ mcore-*-pe*)
+ # The EPOC C++ environment does not support exceptions or rtti,
+ # and so building libstdc++-v3 tends not to always work.
+ noconfigdirs="$noconfigdirs target-libstdc++-v3"
+ ;;
+ mmix-*-*)
+ noconfigdirs="$noconfigdirs ${libgcj} gdb libgloss"
+ ;;
+ mn10200-*-*)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
+ mn10300-*-*)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
+ powerpc-*-aix*)
+ # copied from rs6000-*-* entry
+ noconfigdirs="$noconfigdirs gprof target-libada target-libgloss ${libgcj}"
+ ;;
+ powerpc*-*-winnt* | powerpc*-*-pe* | ppc*-*-pe)
+ target_configdirs="$target_configdirs target-winsup"
+ noconfigdirs="$noconfigdirs gdb tcl tk make expect target-libgloss itcl tix gnuserv ${libgcj}"
+ # always build newlib.
+ skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
+ ;;
+ # This is temporary until we can link against shared libraries
+ powerpcle-*-solaris*)
+ noconfigdirs="$noconfigdirs gdb sim make tcl tk expect itcl tix gnuserv ${libgcj}"
+ ;;
+ powerpc-*-beos*)
+ noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
+ ;;
+ powerpc-*-eabi)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
+ rs6000-*-lynxos*)
+ noconfigdirs="$noconfigdirs target-newlib gprof ${libgcj}"
+ ;;
+ rs6000-*-aix*)
+ noconfigdirs="$noconfigdirs gprof target-libada target-libgloss ${libgcj}"
+ ;;
+ rs6000-*-*)
+ noconfigdirs="$noconfigdirs gprof ${libgcj}"
+ ;;
+ m68k-apollo-*)
+ noconfigdirs="$noconfigdirs ld binutils gprof target-libgloss ${libgcj}"
+ ;;
+ mips*-*-irix5*)
+ noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
+ ;;
+ mips*-*-irix6*)
+ # Linking libjava exceeds command-line length limits on at least
+ # IRIX 6.2, but not on IRIX 6.5.
+ # Also, boehm-gc won't build on IRIX 6.5, according to Jeffrey Oldham
+ # <oldham@codesourcery.com>
+ noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
+ ;;
+ mips*-dec-bsd*)
+ noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
+ ;;
+ mips*-*-bsd*)
+ noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
+ ;;
+ mipstx39-*-*)
+ noconfigdirs="$noconfigdirs gprof ${libgcj}" # same as generic mips
+ ;;
+ mips*-*-linux*)
+ noconfigdirs="$noconfigdirs target-newlib target-libgloss"
+ ;;
+ mips*-*-*)
+ noconfigdirs="$noconfigdirs gprof ${libgcj}"
+ ;;
+ romp-*-*)
+ noconfigdirs="$noconfigdirs bfd binutils ld gas opcodes target-libgloss ${libgcj}"
+ ;;
+ sh-*-*)
+ case "${host}" in
+ i[3456789]86-*-vsta) ;; # don't add gprof back in
+ i[3456789]86-*-go32*) ;; # don't add gprof back in
+ i[3456789]86-*-msdosdjgpp*) ;; # don't add gprof back in
+ *) skipdirs=`echo " ${skipdirs} " | sed -e 's/ gprof / /'` ;;
+ esac
+ noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+ ;;
+ sh64-*-*)
+ noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+ ;;
+ sparc-*-elf*)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
+ sparc64-*-elf*)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
+ sparclite-*-*)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
+ sparc-*-sunos4*)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ if test x${is_cross_compiler} != xno ; then
+ noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss"
+ else
+ use_gnu_ld=no
+ fi
+ ;;
+ sparc-*-solaris* | sparc64-*-solaris* | sparcv9-*-solaris*)
+ ;;
+ v810-*-*)
+ noconfigdirs="$noconfigdirs bfd binutils gas gcc gdb ld target-libstdc++-v3 opcodes target-libgloss ${libgcj}"
+ ;;
+ v850-*-*)
+ noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+ ;;
+ v850e-*-*)
+ noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+ ;;
+ v850ea-*-*)
+ noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
+ ;;
+ vax-*-vms)
+ noconfigdirs="$noconfigdirs bfd binutils gdb ld target-newlib opcodes target-libgloss ${libgcj}"
+ ;;
+ vax-*-*)
+ noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
+ ;;
+ xtensa-*-*)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
+ ip2k-*-*)
+ noconfigdirs="$noconfigdirs target-libiberty target-libstdc++-v3 ${libgcj}"
+ ;;
+ *-*-linux*)
+ noconfigdirs="$noconfigdirs target-newlib target-libgloss"
+ ;;
+ *-*-lynxos*)
+ noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
+ ;;
+ *-*-*)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
esac
-if result=`${config_shell} ${configsub} ${host_alias}` ; then
- true
+# If we aren't building newlib, then don't build libgloss, since libgloss
+# depends upon some newlib header files.
+case "${noconfigdirs}" in
+ *target-libgloss*) ;;
+ *target-newlib*) noconfigdirs="$noconfigdirs target-libgloss" ;;
+esac
+
+# Figure out what language subdirectories are present.
+# Look if the user specified --enable-languages="..."; if not, use
+# the environment variable $LANGUAGES if defined. $LANGUAGES might
+# go away some day.
+# NB: embedded tabs in this IF block -- do not untabify
+if test x"${enable_languages+set}" != xset; then
+ if test x"${LANGUAGES+set}" = xset; then
+ enable_languages="${LANGUAGES}"
+ echo configure.in: warning: setting LANGUAGES is deprecated, use --enable-languages instead 1>&2
+ else
+ enable_languages=all
+ fi
else
- echo "Unrecognized host system name ${host_alias}." 1>&2
+ if test x"${enable_languages}" = x ||
+ test x"${enable_languages}" = xyes;
+ then
+ echo configure.in: --enable-languages needs at least one language argument 1>&2
exit 1
+ fi
fi
-host_cpu=`echo $result | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-host_vendor=`echo $result | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-host_os=`echo $result | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-host=${host_cpu}-${host_vendor}-${host_os}
+enable_languages=`echo "${enable_languages}" | sed -e 's/[ ,][ ,]*/,/g' -e 's/,$//'`
+
+# First scan to see if an enabled language requires some other language.
+# We assume that a given config-lang.in will list all the language
+# front ends it requires, even if some are required indirectly.
+for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
+ case ${lang_frag} in
+ ..) ;;
+ # The odd quoting in the next line works around
+ # an apparent bug in bash 1.12 on linux.
+ ${srcdir}/gcc/[*]/config-lang.in) ;;
+ *)
+ # From the config-lang.in, get $language, $lang_requires
+ language=
+ lang_requires=
+ . ${lang_frag}
+ for other in ${lang_requires} ; do
+ case ,${enable_languages}, in
+ *,$other,*) ;;
+ *,all,*) ;;
+ *,$language,*)
+ echo " \`$other' language required by \`$language'; enabling" 1>&2
+ enable_languages="${enable_languages},${other}"
+ ;;
+ esac
+ done
+ ;;
+ esac
+done
-. ${tmpfile}.hst
+for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
+ case ${lang_frag} in
+ ..) ;;
+ # The odd quoting in the next line works around
+ # an apparent bug in bash 1.12 on linux.
+ ${srcdir}/gcc/[*]/config-lang.in) ;;
+ *)
+ # From the config-lang.in, get $language, $target_libs,
+ # $lang_dirs, and $build_by_default
+ language=
+ target_libs=
+ lang_dirs=
+ build_by_default=
+ . ${lang_frag}
+ if test "x$language" = x ; then
+ echo "${lang_frag} doesn't set \$language." 1>&2
+ exit 1
+ fi
+ case ,${enable_languages}, in
+ *,${language},*)
+ # Language was explicitly selected; include it.
+ add_this_lang=yes
+ ;;
+ *,all,*)
+ # 'all' was selected; include 'default' languages.
+ case ${build_by_default} in
+ no) add_this_lang=no ;;
+ *) add_this_lang=yes ;;
+ esac
+ ;;
+ *) add_this_lang=no ;;
+ esac
+ case ${add_this_lang} in
+ no)
+ # Remove language-dependent dirs.
+ eval noconfigdirs='"$noconfigdirs "'\"$target_libs $lang_dirs\"
+ ;;
+ esac
+ ;;
+ esac
+done
-if result=`${config_shell} ${configsub} ${target_alias}` ; then
- true
-else
- echo "Unrecognized target system name ${target_alias}." 1>&2
- exit 1
+# Remove the entries in $skipdirs and $noconfigdirs from $configdirs and
+# $target_configdirs.
+# If we have the source for $noconfigdirs entries, add them to $notsupp.
+
+notsupp=""
+for dir in . $skipdirs $noconfigdirs ; do
+ dirname=`echo $dir | sed -e s/target-//g`
+ if test $dir != . && echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
+ configdirs=`echo " ${configdirs} " | sed -e "s/ ${dir} / /"`
+ if test -r $srcdir/$dirname/configure ; then
+ if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
+ true
+ else
+ notsupp="$notsupp $dir"
+ fi
+ fi
+ fi
+ if test $dir != . && echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
+ target_configdirs=`echo " ${target_configdirs} " | sed -e "s/ ${dir} / /"`
+ if test -r $srcdir/$dirname/configure ; then
+ if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
+ true
+ else
+ notsupp="$notsupp $dir"
+ fi
+ fi
+ fi
+done
+
+# Sometimes the tools are distributed with libiberty but with no other
+# libraries. In that case, we don't want to build target-libiberty.
+if test -n "${target_configdirs}" ; then
+ others=
+ for i in `echo ${target_configdirs} | sed -e s/target-//g` ; do
+ if test "$i" != "libiberty" ; then
+ if test -r $srcdir/$i/configure ; then
+ others=yes;
+ break;
+ fi
+ fi
+ done
+ if test -z "${others}" ; then
+ target_configdirs=
+ fi
fi
-target_cpu=`echo $result | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-target_vendor=`echo $result | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-target_os=`echo $result | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-target=${target_cpu}-${target_vendor}-${target_os}
-. ${tmpfile}.tgt
+# Quietly strip out all directories which aren't configurable in this tree.
+# This relies on all configurable subdirectories being autoconfiscated, which
+# is now the case.
+configdirs_all="$configdirs"
+configdirs=
+for i in ${configdirs_all} ; do
+ if test -f ${srcdir}/$i/configure ; then
+ configdirs="${configdirs} $i"
+ fi
+done
+target_configdirs_all="$target_configdirs"
+target_configdirs=
+for i in ${target_configdirs_all} ; do
+ j=`echo $i | sed -e s/target-//g`
+ if test -f ${srcdir}/$j/configure ; then
+ target_configdirs="${target_configdirs} $i"
+ fi
+done
-# Find the source files, if location was not specified.
-case "${srcdir}" in
-"")
- srcdirdefaulted=1
- srcdir=.
- if [ ! -r ${srctrigger} ] ; then
- srcdir=..
- fi
- ;;
-*) ;;
+# Produce a warning message for the subdirs we can't configure.
+# This isn't especially interesting in the Cygnus tree, but in the individual
+# FSF releases, it's important to let people know when their machine isn't
+# supported by the one or two programs in a package.
+
+if test -n "${notsupp}" && test -z "${norecursion}" ; then
+ # If $appdirs is non-empty, at least one of those directories must still
+ # be configured, or we error out. (E.g., if the gas release supports a
+ # specified target in some subdirs but not the gas subdir, we shouldn't
+ # pretend that all is well.)
+ if test -n "$appdirs" ; then
+ for dir in $appdirs ; do
+ if test -r $dir/Makefile.in ; then
+ if echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
+ appdirs=""
+ break
+ fi
+ if echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
+ appdirs=""
+ break
+ fi
+ fi
+ done
+ if test -n "$appdirs" ; then
+ echo "*** This configuration is not supported by this package." 1>&2
+ exit 1
+ fi
+ fi
+ # Okay, some application will build, or we don't care to check. Still
+ # notify of subdirs not getting built.
+ echo "*** This configuration is not supported in the following subdirectories:" 1>&2
+ echo " ${notsupp}" 1>&2
+ echo " (Any other directories should still work fine.)" 1>&2
+fi
+
+case "$host" in
+ *msdosdjgpp*)
+ enable_gdbtk=no ;;
esac
-if [ ! -r ${srcdir}/${srctrigger} ] ; then
- case "${srcdirdefaulted}" in
- "") echo '***' "${progname}: Can't find ${srcname} sources in ${PWD=`${PWDCMD-pwd}`}/${srcdir}" 1>&2 ;;
- *) echo '***' "${progname}: Can't find ${srcname} sources in ${PWD=`${PWDCMD-pwd}`}/. or ${PWD=`${PWDCMD-pwd}`}/.." 1>&2 ;;
- esac
+copy_dirs=
- echo '***' \(At least ${srctrigger} is missing.\) 1>&2
- exit 1
+# Handle --with-headers=XXX. If the value is not "yes", the contents of
+# the named directory are copied to $(tooldir)/sys-include.
+if test x"${with_headers}" != x && test x"${with_headers}" != xno ; then
+ if test x${is_cross_compiler} = xno ; then
+ echo 1>&2 '***' --with-headers is only supported when cross compiling
+ exit 1
+ fi
+ if test x"${with_headers}" != xyes ; then
+ case "${exec_prefixoption}" in
+ "") x=${prefix} ;;
+ *) x=${exec_prefix} ;;
+ esac
+ copy_dirs="${copy_dirs} ${with_headers} $x/${target_alias}/sys-include"
+ fi
fi
-# Some systems (e.g., one of the i386-aix systems the gas testers are
-# using) don't handle "\$" correctly, so don't use it here.
-tooldir='$(exec_prefix)'/${target_alias}
-
-if [ "${host_alias}" != "${target_alias}" ] ; then
- if [ "${program_prefixoption}" = "" ] ; then
- if [ "${program_suffixoption}" = "" ] ; then
- if [ "${program_transform_nameoption}" = "" ] ; then
- program_prefix=${target_alias}- ;
- fi
- fi
- fi
+# Handle --with-libs=XXX. If the value is not "yes", the contents of
+# the name directories are copied to $(tooldir)/lib. Multiple directories
+# are permitted.
+if test x"${with_libs}" != x && test x"${with_libs}" != xno ; then
+ if test x${is_cross_compiler} = xno ; then
+ echo 1>&2 '***' --with-libs is only supported when cross compiling
+ exit 1
+ fi
+ if test x"${with_libs}" != xyes ; then
+ # Copy the libraries in reverse order, so that files in the first named
+ # library override files in subsequent libraries.
+ case "${exec_prefixoption}" in
+ "") x=${prefix} ;;
+ *) x=${exec_prefix} ;;
+ esac
+ for l in ${with_libs}; do
+ copy_dirs="$l $x/${target_alias}/lib ${copy_dirs}"
+ done
+ fi
fi
-# Merge program_prefix and program_suffix onto program_transform_name.
-# (program_suffix used to use $, but it's hard to preserve $ through both
-# make and sh.)
-if [ "${program_suffix}" != "" ] ; then
- program_transform_name="-e s,\\\\(.*\\\\),\\\\1${program_suffix}, ${program_transform_name}"
+# Handle ${copy_dirs}
+set fnord ${copy_dirs}
+shift
+while test $# != 0 ; do
+ if test -f $2/COPIED && test x"`cat $2/COPIED`" = x"$1" ; then
+ :
+ else
+ echo Copying $1 to $2
+
+ # Use the install script to create the directory and all required
+ # parent directories.
+ if test -d $2 ; then
+ :
+ else
+ echo >config.temp
+ ${srcdir}/install-sh -c -m 644 config.temp $2/COPIED
+ fi
+
+ # Copy the directory, assuming we have tar.
+ # FIXME: Should we use B in the second tar? Not all systems support it.
+ (cd $1; tar -cf - .) | (cd $2; tar -xpf -)
+
+ # It is the responsibility of the user to correctly adjust all
+ # symlinks. If somebody can figure out how to handle them correctly
+ # here, feel free to add the code.
+
+ echo $1 > $2/COPIED
+ fi
+ shift; shift
+done
+
+# Work in distributions that contain no compiler tools, like Autoconf.
+tentative_cc=""
+host_makefile_frag=/dev/null
+if test -d ${srcdir}/config ; then
+case "${host}" in
+ m68k-hp-hpux*)
+ # Avoid "too much defining" errors from HPUX compiler.
+ tentative_cc="cc -Wp,-H256000"
+ # If "ar" in $PATH is GNU ar, the symbol table may need rebuilding.
+ # If it's HP/UX ar, this should be harmless.
+ RANLIB="ar ts"
+ ;;
+ m68k-apollo-sysv*)
+ tentative_cc="cc -A ansi -A runtype,any -A systype,any -U__STDC__ -DUSG"
+ ;;
+ m68k-apollo-bsd*)
+ #None of the Apollo compilers can compile gas or binutils. The preprocessor
+ # chokes on bfd, the compiler won't let you assign integers to enums, and
+ # other problems. Defining CC to gcc is a questionable way to say "don't use
+ # the apollo compiler" (the preferred version of GCC could be called cc,
+ # or whatever), but I'm not sure leaving CC as cc is any better...
+ #CC=cc -A ansi -A runtype,any -A systype,any -U__STDC__ -DNO_STDARG
+ # Used to have BISON=yacc.
+ tentative_cc=gcc
+ ;;
+ m88k-dg-dgux*)
+ tentative_cc="gcc -Wall -ansi -D__using_DGUX"
+ ;;
+ m88k-harris-cxux*)
+ # Under CX/UX, we want to tell the compiler to use ANSI mode.
+ tentative_cc="cc -Xa"
+ host_makefile_frag="config/mh-cxux"
+ ;;
+ m88k-motorola-sysv*)
+ ;;
+ mips*-dec-ultrix*)
+ tentative_cc="cc -Wf,-XNg1000"
+ host_makefile_frag="config/mh-decstation"
+ ;;
+ mips*-nec-sysv4*)
+ # The C compiler on NEC MIPS SVR4 needs bigger tables.
+ tentative_cc="cc -ZXNd=5000 -ZXNg=1000"
+ host_makefile_frag="config/mh-necv4"
+ ;;
+ mips*-sgi-irix4*)
+ # Tell compiler to use K&R C. We can't compile under the SGI Ansi
+ # environment. Also bump switch table size so that cp-parse will
+ # compile. Bump string length limit so linker builds.
+ tentative_cc="cc -cckr -Wf,-XNg1500 -Wf,-XNk1000 -Wf,-XNh2000 -Wf,-XNl8192"
+ ;;
+ mips*-*-sysv4*)
+ host_makefile_frag="config/mh-sysv4"
+ ;;
+ mips*-*-sysv*)
+ # This is for a MIPS running RISC/os 4.52C.
+
+ # This is needed for GDB, but needs to be in the top-level make because
+ # if a library is compiled with the bsd headers and gets linked with the
+ # sysv system libraries all hell can break loose (e.g. a jmp_buf might be
+ # a different size).
+ # ptrace(2) apparently has problems in the BSD environment. No workaround is
+ # known except to select the sysv environment. Could we use /proc instead?
+ # These "sysv environments" and "bsd environments" often end up being a pain.
+ #
+ # This is not part of CFLAGS because perhaps not all C compilers have this
+ # option.
+ tentative_cc="cc -systype sysv"
+ ;;
+ i370-ibm-opened*)
+ tentative_cc="c89"
+ ;;
+ i[3456789]86-*-sysv5*)
+ host_makefile_frag="config/mh-sysv5"
+ ;;
+ i[3456789]86-*-dgux*)
+ tentative_cc="gcc -Wall -ansi -D__using_DGUX"
+ host_makefile_frag="config/mh-dgux386"
+ ;;
+ i[3456789]86-ncr-sysv4.3*)
+ # The MetaWare compiler will generate a copyright message unless you
+ # turn it off by adding the -Hnocopyr flag.
+ tentative_cc="cc -Hnocopyr"
+ ;;
+ i[3456789]86-ncr-sysv4*)
+ # for an NCR 3000 (i486/SVR4) system.
+ # The NCR 3000 ships with a MetaWare compiler installed as /bin/cc.
+ # This compiler not only emits obnoxious copyright messages every time
+ # you run it, but it chokes and dies on a whole bunch of GNU source
+ # files. Default to using the AT&T compiler installed in /usr/ccs/ATT/cc.
+ tentative_cc="/usr/ccs/ATT/cc"
+ host_makefile_frag="config/mh-ncr3000"
+ ;;
+ i[3456789]86-*-sco3.2v5*)
+ ;;
+ i[3456789]86-*-sco*)
+ # The native C compiler botches some simple uses of const. Unfortunately,
+ # it doesn't defined anything like "__sco__" for us to test for in ansidecl.h.
+ tentative_cc="cc -Dconst="
+ host_makefile_frag="config/mh-sco"
+ ;;
+ i[3456789]86-*-udk*)
+ host_makefile_frag="config/mh-sysv5"
+ ;;
+ i[3456789]86-*-solaris2*)
+ host_makefile_frag="config/mh-sysv4"
+ ;;
+ i[3456789]86-*-msdosdjgpp*)
+ host_makefile_frag="config/mh-djgpp"
+ ;;
+ *-cygwin*)
+ host_makefile_frag="config/mh-cygwin"
+ ;;
+ *-mingw32*)
+ host_makefile_frag="config/mh-mingw32"
+ ;;
+ *-interix*)
+ host_makefile_frag="config/mh-interix"
+ ;;
+ vax-*-ultrix2*)
+ # The old BSD pcc isn't up to compiling parts of gdb so use gcc
+ tentative_cc=gcc
+ ;;
+ *-*-solaris2*)
+ host_makefile_frag="config/mh-solaris"
+ ;;
+ m68k-sun-sunos*)
+ # Sun's C compiler needs the -J flag to be able to compile cp-parse.c
+ # without overflowing the jump tables (-J says to use a 32 bit table)
+ tentative_cc="cc -J"
+ ;;
+ *-hp-hpux*)
+ tentative_cc="cc -Wp,-H256000"
+ ;;
+ *-*-hiux*)
+ tentative_cc="cc -Wp,-H256000"
+ ;;
+ rs6000-*-lynxos*)
+ # /bin/cc is less than useful for our purposes. Always use GCC
+ tentative_cc="/usr/cygnus/progressive/bin/gcc"
+ host_makefile_frag="config/mh-lynxrs6k"
+ ;;
+ *-*-lynxos*)
+ # /bin/cc is less than useful for our purposes. Always use GCC
+ tentative_cc="/bin/gcc"
+ ;;
+ *-*-sysv4*)
+ host_makefile_frag="config/mh-sysv4"
+ ;;
+esac
fi
-if [ "${program_prefix}" != "" ] ; then
- program_transform_name="-e s,^,${program_prefix}, ${program_transform_name}"
+extra_arflags_for_target=
+extra_nmflags_for_target=
+extra_ranlibflags_for_target=
+target_makefile_frag=/dev/null
+case "${target}" in
+ i[3456789]86-*-netware*)
+ target_makefile_frag="config/mt-netware"
+ ;;
+ powerpc-*-netware*)
+ target_makefile_frag="config/mt-netware"
+ ;;
+ *-*-linux*)
+ target_makefile_frag="config/mt-linux"
+ ;;
+ *-*-aix4.[3456789]* | *-*-aix[56789].*)
+ # nm and ar from AIX 4.3 and above require -X32_64 flag to all ar and nm
+ # commands to handle both 32-bit and 64-bit objects. These flags are
+ # harmless if we're using GNU nm or ar.
+ extra_arflags_for_target=" -X32_64"
+ extra_nmflags_for_target=" -B -X32_64"
+ ;;
+ *-*-darwin*)
+ # ranlib from Darwin requires the -c flag to look at common symbols.
+ extra_ranlibflags_for_target=" -c"
+ ;;
+ mips*-*-pe | sh*-*-pe | *arm-wince-pe)
+ target_makefile_frag="config/mt-wince"
+ ;;
+esac
+
+alphaieee_frag=/dev/null
+case $target in
+ alpha*-*-*)
+ # This just makes sure to use the -mieee option to build target libs.
+ # This should probably be set individually by each library.
+ alphaieee_frag="config/mt-alphaieee"
+ ;;
+esac
+
+# If --enable-target-optspace always use -Os instead of -O2 to build
+# the target libraries, similarly if it is not specified, use -Os
+# on selected platforms.
+ospace_frag=/dev/null
+case "${enable_target_optspace}:${target}" in
+ yes:*)
+ ospace_frag="config/mt-ospace"
+ ;;
+ :d30v-*)
+ ospace_frag="config/mt-d30v"
+ ;;
+ :m32r-* | :d10v-* | :fr30-*)
+ ospace_frag="config/mt-ospace"
+ ;;
+ no:* | :*)
+ ;;
+ *)
+ echo "*** bad value \"${enable_target_optspace}\" for --enable-target-optspace flag; ignored" 1>&2
+ ;;
+esac
+
+# Set with_gnu_as and with_gnu_ld as appropriate.
+#
+# This is done by determining whether or not the appropriate directory
+# is available, and by checking whether or not specific configurations
+# have requested that this magic not happen.
+#
+# The command line options always override the explicit settings in
+# configure.in, and the settings in configure.in override this magic.
+#
+# If the default for a toolchain is to use GNU as and ld, and you don't
+# want to do that, then you should use the --without-gnu-as and
+# --without-gnu-ld options for the configure script.
+
+if test x${use_gnu_as} = x &&
+ echo " ${configdirs} " | grep " gas " > /dev/null 2>&1 ; then
+ with_gnu_as=yes
+ extra_host_args="$extra_host_args --with-gnu-as"
fi
-# If CC and CXX are not set in the environment, and the Makefile
-# exists, try to extract them from it. This is to handle running
-# ./config.status by hand.
-if [ -z "${CC}" ] && [ -r Makefile ]; then
- sed -n -e ':loop
-/\\$/ N
-s/\\\n//g
-t loop
-/^CC[ ]*=/ s/CC[ ]*=[ ]*\(.*\)/\1/p' < Makefile > Makefile.cc
- CC=`tail -1 Makefile.cc`
- rm -f Makefile.cc
+if test x${use_gnu_ld} = x &&
+ echo " ${configdirs} " | grep " ld " > /dev/null 2>&1 ; then
+ with_gnu_ld=yes
+ extra_host_args="$extra_host_args --with-gnu-ld"
fi
-if [ -z "${CFLAGS}" ] && [ -r Makefile ]; then
- sed -n -e ':loop
-/\\$/ N
-s/\\\n//g
-t loop
-/^CFLAGS[ ]*=/ s/CFLAGS[ ]*=[ ]*\(.*\)/\1/p' < Makefile > Makefile.cc
- CFLAGS=`tail -1 Makefile.cc`
- rm -f Makefile.cc
+# If using newlib, add --with-newlib to the extra_host_args so that gcc/configure
+# can detect this case.
+
+if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " target-newlib " > /dev/null 2>&1 ; then
+ with_newlib=yes
+ extra_host_args="$extra_host_args --with-newlib"
fi
-if [ -z "${CXX}" ] && [ -r Makefile ]; then
- sed -n -e ':loop
-/\\$/ N
-s/\\\n//g
-t loop
-/^CXX[ ]*=/ s/CXX[ ]*=[ ]*\(.*\)/\1/p' < Makefile > Makefile.cc
- CXX=`tail -1 Makefile.cc`
- rm -f Makefile.cc
+
+# Default to using --with-stabs for certain targets.
+if test x${with_stabs} = x ; then
+ case "${target}" in
+ mips*-*-irix[56]*)
+ ;;
+ mips*-*-* | alpha*-*-osf*)
+ with_stabs=yes;
+ extra_host_args="${extra_host_args} --with-stabs"
+ ;;
+ esac
fi
-if [ -z "${CXXFLAGS}" ] && [ -r Makefile ]; then
- sed -n -e ':loop
-/\\$/ N
-s/\\\n//g
-t loop
-/^CXXFLAGS[ ]*=/ s/CXXFLAGS[ ]*=[ ]*\(.*\)/\1/p' < Makefile > Makefile.cc
- CXXFLAGS=`tail -1 Makefile.cc`
- rm -f Makefile.cc
+# hpux11 in 64bit mode has libraries in a weird place. Arrange to find
+# them automatically.
+case "${host}" in
+ hppa*64*-*-hpux11*)
+ extra_host_args="$extra_host_args -x-libraries=/usr/lib/pa20_64 -x-includes=/usr/X11R6/include"
+ ;;
+esac
+
+# If we aren't going to be using gcc, see if we can extract a definition
+# of CC from the fragment.
+# Actually, use the 'pre-extracted' version above.
+if test -z "${CC}" && test "${build}" = "${host}" ; then
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
+ found=
+ for dir in $PATH; do
+ test -z "$dir" && dir=.
+ if test -f $dir/gcc; then
+ found=yes
+ break
+ fi
+ done
+ IFS="$save_ifs"
+ if test -z "${found}" && test -n "${tentative_cc}" ; then
+ CC=$tentative_cc
+ fi
fi
+# Some systems (e.g., one of the i386-aix systems the gas testers are
+# using) don't handle "\$" correctly, so don't use it here.
+tooldir='${exec_prefix}'/${target_alias}
+build_tooldir=${tooldir}
+
# Generate a default definition for YACC. This is used if the makefile can't
# locate bison or byacc in objdir.
@@ -911,38 +2123,10 @@ do
test -n "$DEFAULT_LEX" && break
done
-if [ "${build}" != "${host}" ]; then
+if test "${build}" != "${host}" ; then
# If we are doing a Canadian Cross, in which the host and build systems
# are not the same, we set reasonable default values for the tools.
- tools="AR AR_FOR_TARGET AS AS_FOR_TARGET BISON CC_FOR_BUILD"
- tools="${tools} CC_FOR_TARGET CXX_FOR_TARGET GCJ_FOR_TARGET"
- tools="${tools} DLLTOOL DLLTOOL_FOR_TARGET GCC_FOR_TARGET BUILD_PREFIX"
- tools="${tools} BUILD_PREFIX_1 LD LD_FOR_TARGET LEX MAKEINFO NM"
- tools="${tools} NM_FOR_TARGET RANLIB RANLIB_FOR_TARGET"
- tools="${tools} WINDRES WINDRES_FOR_TARGET YACC"
- tools="${tools} OBJCOPY OBJDUMP"
-
- for var in ${tools}; do
- if eval [ -z \"\$${var}\" ] && [ -r Makefile ]; then
- sed -n -e ':loop
-/\\$/ N
-s/\\\n//g
-t loop
-/^'"${var}"'[ ]*=/ s/'"${var}"'[ ]*=[ ]*\(.*\)/\1/p' \
- < Makefile > Makefile.v
- t=`tail -1 Makefile.v`
- if [ -n "${t}" ]; then
- eval "${var}=\${t}"
- fi
- rm -f Makefile.v
- fi
- done
-
- AR=${AR-${host_alias}-ar}
- AR_FOR_TARGET=${AR_FOR_TARGET-${target_alias}-ar}
- AS=${AS-${host_alias}-as}
- AS_FOR_TARGET=${AS_FOR_TARGET-${target_alias}-as}
BISON=${BISON-bison}
CC=${CC-${host_alias}-gcc}
CFLAGS=${CFLAGS-"-g -O2"}
@@ -952,24 +2136,12 @@ t loop
CC_FOR_TARGET=${CC_FOR_TARGET-${target_alias}-gcc}
CXX_FOR_TARGET=${CXX_FOR_TARGET-${target_alias}-c++}
GCJ_FOR_TARGET=${GCJ_FOR_TARGET-${target_alias}-gcj}
- DLLTOOL=${DLLTOOL-${host_alias}-dlltool}
- DLLTOOL_FOR_TARGET=${DLLTOOL_FOR_TARGET-${target_alias}-dlltool}
GCC_FOR_TARGET=${GCC_FOR_TARGET-${CC_FOR_TARGET-${target_alias}-gcc}}
BUILD_PREFIX=${build_alias}-
BUILD_PREFIX_1=${build_alias}-
- LD=${LD-${host_alias}-ld}
- LD_FOR_TARGET=${LD_FOR_TARGET-${target_alias}-ld}
MAKEINFO=${MAKEINFO-makeinfo}
- NM=${NM-${host_alias}-nm}
- NM_FOR_TARGET=${NM_FOR_TARGET-${target_alias}-nm}
- RANLIB=${RANLIB-${host_alias}-ranlib}
- RANLIB_FOR_TARGET=${RANLIB_FOR_TARGET-${target_alias}-ranlib}
- WINDRES=${WINDRES-${host_alias}-windres}
- WINDRES_FOR_TARGET=${WINDRES_FOR_TARGET-${target_alias}-windres}
- OBJCOPY=${OBJCOPY-${host_alias}-objcopy}
- OBJDUMP=${OBJDUMP-${host_alias}-objdump}
-
- if [ -z "${YACC}" ]; then
+
+ if test -z "${YACC}" ; then
IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
for dir in $PATH; do
test -z "$dir" && dir=.
@@ -987,12 +2159,12 @@ t loop
fi
done
IFS="$save_ifs"
- if [ -z "${YACC}" ]; then
+ if test -z "${YACC}" ; then
YACC="bison -y"
fi
fi
- if [ -z "${LEX}" ]; then
+ if test -z "${LEX}" ; then
IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
for dir in $PATH; do
test -z "$dir" && dir=.
@@ -1009,25 +2181,33 @@ t loop
LEX=${LEX-flex}
fi
- # Export variables which autoconf might try to set.
- export AS
- export AR
- export CC_FOR_BUILD
- export DLLTOOL
- export LD
- export NM
- export RANLIB
- export WINDRES
- export OBJCOPY
- export OBJDUMP
else
+ # Set reasonable default values for some tools even if not Canadian.
+ # Of course, these are different reasonable default values, originally
+ # specified directly in the Makefile.
+ # We don't export, so that autoconf can do its job.
+ # Note that all these settings are above the fragment inclusion point
+ # in Makefile.in, so can still be overridden by fragments.
+ # This is all going to change when we autoconfiscate...
+
+ BISON="\$(USUAL_BISON)"
+ CC_FOR_BUILD="\$(CC)"
+ GCC_FOR_TARGET="\$(USUAL_GCC_FOR_TARGET)"
+ BUILD_PREFIX=
+ BUILD_PREFIX_1=loser-
+ MAKEINFO="\$(USUAL_MAKEINFO)"
+ LEX="\$(USUAL_LEX)"
+ YACC="\$(USUAL_YACC)"
+
# If CC is still not set, try to get gcc.
- if [ -z "${CC}" ]; then
+ cc_prog_is_gcc=
+ if test -z "${CC}" ; then
IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
for dir in $PATH; do
test -z "$dir" && dir=.
if test -f $dir/gcc; then
CC="gcc"
+ cc_prog_is_gcc=yes
echo 'void f(){}' > conftest.c
if test -z "`${CC} -g -c conftest.c 2>&1`"; then
CFLAGS=${CFLAGS-"-g -O2"}
@@ -1043,11 +2223,20 @@ else
IFS="$save_ifs"
CC=${CC-cc}
else
+ # Determine if we are using gcc.
+ cat > conftest.c <<EOF
+#ifdef __GNUC__
+ yes;
+#endif
+EOF
+ if ${CC} -E conftest.c | grep yes >/dev/null 2>&1; then
+ cc_prog_is_gcc=yes
+ fi
+ rm -f conftest.c
if test -z "${CFLAGS}"; then
# Here CC is set but CFLAGS is not. Use a quick hack to use -O2 if CC
# is set to a version of gcc.
- case "${CC}" in
- *gcc)
+ if test "$cc_prog_is_gcc" = yes; then
echo 'void f(){}' > conftest.c
if test -z "`${CC} -g -c conftest.c 2>&1`"; then
CFLAGS=${CFLAGS-"-g -O2"}
@@ -1057,7 +2246,25 @@ else
CXXFLAGS=${CXXFLAGS-"-O2"}
fi
rm -f conftest*
- ;;
+ fi
+ fi
+ fi
+
+ # We must set the default linker to the linker used by gcc for the correct
+ # operation of libtool. If LD is not defined and we are using gcc, try to
+ # set the LD default to the ld used by gcc.
+ if test -z "$LD"; then
+ if test "$cc_prog_is_gcc" = yes; then
+ case $build in
+ *-*-mingw*)
+ gcc_prog_ld=`$CC -print-prog-name=ld 2>&1 | tr -d '\015'` ;;
+ *)
+ gcc_prog_ld=`$CC -print-prog-name=ld 2>&1` ;;
+ esac
+ case $gcc_prog_ld in
+ # Accept absolute paths.
+ [\\/]* | [A-Za-z]:[\\/]*)
+ LD="$gcc_prog_ld" ;;
esac
fi
fi
@@ -1067,546 +2274,2156 @@ else
CXXFLAGS=${CXXFLAGS-"-g -O2"}
fi
-export CC
-export CXX
-export CFLAGS
-export CXXFLAGS
+# FIXME Should this be done recursively ??? (Useful for e.g. gdbtest)
+# Set up the list of links to be made.
+# ${links} is the list of link names, and ${files} is the list of names to link to.
-all_build_modules=
-if test x"${build_alias}" != x"${host_alias}"
-then
- all_build_modules='$(ALL_BUILD_MODULES_LIST)'
-fi
-
-for subdir in . ${subdirs} ; do
-
- # ${subdir} is relative path from . to the directory we're currently
- # configuring.
- # ${invsubdir} is inverse of ${subdir), *with* trailing /, if needed.
- invsubdir=`echo ${subdir}/ | sed -e 's|\./||g' -e 's|[^/]*/|../|g'`
-
- ### figure out what to do with srcdir
- case "${srcdir}" in
- ".") # no -srcdir option. We're building in place.
- makesrcdir=. ;;
- /* | [A-Za-z]:[\\/]* ) # absolute path
- makesrcdir=`echo ${srcdir}/${subdir} | sed -e 's|/\.$||'`
- ;;
- *) # otherwise relative
- case "${subdir}" in
- .) makesrcdir=${srcdir} ;;
- *) makesrcdir=${invsubdir}${srcdir}/${subdir} ;;
- esac
- ;;
- esac
-
- if [ "${subdir}/" != "./" ] ; then
- Makefile=${subdir}/Makefile
+# Make the links.
+configlinks="${links}"
+if test -r ./config.status ; then
+ mv -f ./config.status ./config.back
+fi
+while test -n "${files}" ; do
+ # set file to car of files, files to cdr of files
+ set ${files}; file=$1; shift; files=$*
+ set ${links}; link=$1; shift; links=$*
+
+ if test ! -r ${srcdir}/${file} ; then
+ if test ! -r ${file} ; then
+ echo '***' "${progname}: cannot create a link \"${link}\"," 1>&2
+ echo '***' "since the file \"${srcdir}/${file}\" does not exist." 1>&2
+ exit 1
+ else
+ srcfile=${file}
fi
+ else
+ srcfile=${srcdir}/${file}
+ fi
- if [ ! -d ${subdir} ] ; then
- if mkdir ${subdir} ; then
- true
- else
- echo '***' "${progname}: could not make ${PWD=`${PWDCMD-pwd}`}/${subdir}" 1>&2
- exit 1
- fi
- fi
+ ${remove} -f ${link}
+ # Make a symlink if possible, otherwise try a hard link
+ if ${symbolic_link} ${srcfile} ${link} >/dev/null 2>&1 ; then
+ true
+ else
+ # We need to re-remove the file because Lynx leaves a
+ # very strange directory there when it fails an NFS symlink.
+ ${remove} -r -f ${link}
+ ${hard_link} ${srcfile} ${link}
+ fi
+ if test ! -r ${link} ; then
+ echo '***' "${progname}: unable to link \"${link}\" to \"${srcfile}\"." 1>&2
+ exit 1
+ fi
- case "${removing}" in
- "")
- case "${subdir}" in
- .) ;;
- *) eval echo Building in ${subdir} ${redirect} ;;
- esac
-
- # FIXME Should this be done recursively ??? (Useful for e.g. gdbtest)
- # Set up the list of links to be made.
- # ${links} is the list of link names, and ${files} is the list of names to link to.
-
- # Make the links.
- configlinks="${links}"
- if [ -r ${subdir}/config.status ] ; then
- mv -f ${subdir}/config.status ${subdir}/config.back
- fi
- while [ -n "${files}" ] ; do
- # set file to car of files, files to cdr of files
- set ${files}; file=$1; shift; files=$*
- set ${links}; link=$1; shift; links=$*
-
- if [ ! -r ${srcdir}/${file} ] ; then
- if [ ! -r ${file} ] ; then
-
- echo '***' "${progname}: cannot create a link \"${link}\"," 1>&2
- echo '***' "since the file \"${srcdir}/${file}\" does not exist." 1>&2
- exit 1
- else
- srcfile=${file}
- fi
- else
- srcfile=${srcdir}/${file}
- fi
-
- ${remove} -f ${link}
- # Make a symlink if possible, otherwise try a hard link
- if ${symbolic_link} ${srcfile} ${link} >/dev/null 2>&1 ; then
- true
- else
- # We need to re-remove the file because Lynx leaves a
- # very strange directory there when it fails an NFS symlink.
- ${remove} -r -f ${link}
- ${hard_link} ${srcfile} ${link}
- fi
- if [ ! -r ${link} ] ; then
- echo '***' "${progname}: unable to link \"${link}\" to \"${srcfile}\"." 1>&2
- exit 1
- fi
-
- echo "Linked \"${link}\" to \"${srcfile}\"."
- done
-
- # Create a .gdbinit file which runs the one in srcdir
- # and tells GDB to look there for source files.
-
- if [ -r ${srcdir}/${subdir}/.gdbinit ] ; then
- case ${srcdir} in
- .) ;;
- *) cat > ${subdir}/.gdbinit <<EOF
+ echo "Linked \"${link}\" to \"${srcfile}\"."
+done
+
+# Create a .gdbinit file which runs the one in srcdir
+# and tells GDB to look there for source files.
+
+if test -r ${srcdir}/.gdbinit ; then
+ case ${srcdir} in
+ .) ;;
+ *) cat > ./.gdbinit <<EOF
# ${NO_EDIT}
-dir ${makesrcdir}
+dir ${srcdir}
dir .
-source ${makesrcdir}/.gdbinit
+source ${srcdir}/.gdbinit
EOF
- ;;
- esac
+ ;;
+ esac
+fi
+
+# Make sure that the compiler is able to generate an executable. If it
+# can't, we are probably in trouble. We don't care whether we can run the
+# executable--we might be using a cross compiler--we only care whether it
+# can be created. At this point the main configure script has set CC.
+we_are_ok=no
+echo "int main () { return 0; }" > conftest.c
+${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c
+if test $? = 0 ; then
+ if test -s conftest || test -s conftest.exe ; then
+ we_are_ok=yes
+ fi
+fi
+case $we_are_ok in
+ no)
+ echo 1>&2 "*** The command '${CC} -o conftest ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} conftest.c' failed."
+ echo 1>&2 "*** You must set the environment variable CC to a working compiler."
+ rm -f conftest*
+ exit 1
+ ;;
+esac
+rm -f conftest*
+
+# The Solaris /usr/ucb/cc compiler does not appear to work.
+case "${host}" in
+ sparc-sun-solaris2*)
+ CCBASE="`echo ${CC-cc} | sed 's/ .*$//'`"
+ if test "`type $CCBASE | sed 's/^[^/]*//'`" = "/usr/ucb/cc" ; then
+ could_use=
+ test -d /opt/SUNWspro/bin && could_use="/opt/SUNWspro/bin"
+ if test -d /opt/cygnus/bin ; then
+ if test "$could_use" = "" ; then
+ could_use="/opt/cygnus/bin"
+ else
+ could_use="$could_use or /opt/cygnus/bin"
+ fi
+ fi
+ if test "$could_use" = "" ; then
+ echo "Warning: compilation may fail because you're using"
+ echo "/usr/ucb/cc. You should change your PATH or CC "
+ echo "variable and rerun configure."
+ else
+ echo "Warning: compilation may fail because you're using"
+ echo "/usr/ucb/cc, when you should use the C compiler from"
+ echo "$could_use. You should change your"
+ echo "PATH or CC variable and rerun configure."
fi
+ fi
+ ;;
+esac
- # Install a makefile, and make it set VPATH
- # if necessary so that the sources are found.
- # Also change its value of srcdir.
- # NOTE: Makefile generation constitutes the majority of the time in configure. Hence, this section has
- # been somewhat optimized and is perhaps a bit twisty.
-
- # code is order so as to try to sed the smallest input files we know.
- # so do these separately because I don't trust the order of sed -e expressions.
-
- # the five makefile fragments MUST end up in the resulting Makefile in this order:
- # package macros, target, host, site, and package rules.
-
- if [ -f ${srcdir}/${subdir}/${Makefile_in} ] ; then
-
- # Conditionalize the makefile for this package from "Makefile.in" (or whatever it's called) into Makefile.tem.
- rm -f ${subdir}/${Makefile}.tem
- case "${package_makefile_rules_frag}" in
- "") cp ${srcdir}/${subdir}/${Makefile_in} ${subdir}/Makefile.tem ;;
- *)
- if [ ! -f ${package_makefile_rules_frag} ] ; then
- package_makefile_rules_frag=${srcdir}/${package_makefile_rules_frag}
- fi
- if [ -f ${package_makefile_rules_frag} ] ; then
- sed -e "/^####/ r ${package_makefile_rules_frag}" ${srcdir}/${subdir}/${Makefile_in} > ${Makefile}.tem
- else
- echo '***' Expected package makefile rules fragment \"${package_makefile_rules_frag}\" 1>&2
- echo '***' is missing in ${PWD=`${PWDCMD-pwd}`}. 1>&2
- cp ${srcdir}/${subdir}/${Makefile_in} ${subdir}/Makefile.tem
- fi
- esac
- # working copy now in ${Makefile}.tem
-
- # Conditionalize for this site.
- rm -f ${Makefile}
- case "${site}" in
- "") mv ${subdir}/Makefile.tem ${Makefile} ;;
- *)
- site_makefile_frag=${srcdir}/config/ms-${site}
-
- if [ -f ${site_makefile_frag} ] ; then
- sed -e "/^####/ r ${site_makefile_frag}" ${subdir}/Makefile.tem \
- > ${Makefile}
- else
- mv ${subdir}/Makefile.tem ${Makefile}
- site_makefile_frag=
- fi
- ;;
- esac
- # working copy now in ${Makefile}
-
- # Conditionalize the makefile for this host.
- rm -f ${subdir}/Makefile.tem
- case "${host_makefile_frag}" in
- "") mv ${Makefile} ${subdir}/Makefile.tem ;;
- *)
- if [ ! -f ${host_makefile_frag} ] ; then
- host_makefile_frag=${srcdir}/${host_makefile_frag}
- fi
- if [ -f ${host_makefile_frag} ] ; then
- sed -e "/^####/ r ${host_makefile_frag}" ${Makefile} > ${subdir}/Makefile.tem
- else
- echo '***' Expected host makefile fragment \"${host_makefile_frag}\" 1>&2
- echo '***' is missing in ${PWD=`${PWDCMD-pwd}`}. 1>&2
- mv ${Makefile} ${subdir}/Makefile.tem
- fi
- esac
- # working copy now in ${subdir)/Makefile.tem
-
- # Conditionalize the makefile for this target.
- rm -f ${Makefile}
- case "${target_makefile_frag}" in
- "") mv ${subdir}/Makefile.tem ${Makefile} ;;
- *)
- if [ ! -f ${target_makefile_frag} ] ; then
- target_makefile_frag=${srcdir}/${target_makefile_frag}
- fi
- if [ -f ${target_makefile_frag} ] ; then
- sed -e "/^####/ r ${target_makefile_frag}" ${subdir}/Makefile.tem > ${Makefile}
- else
- mv ${subdir}/Makefile.tem ${Makefile}
- target_makefile_frag=
- fi
- ;;
- esac
- # working copy now in ${Makefile}
-
- # Emit the default values of this package's macros.
- rm -f ${subdir}/Makefile.tem
- case "${package_makefile_frag}" in
- "") mv ${Makefile} ${subdir}/Makefile.tem ;;
- *)
- if [ ! -f ${package_makefile_frag} ] ; then
- package_makefile_frag=${srcdir}/${package_makefile_frag}
- fi
- if [ -f ${package_makefile_frag} ] ; then
- sed -e "/^####/ r ${package_makefile_frag}" ${Makefile} > ${subdir}/Makefile.tem
- else
- echo '***' Expected package makefile fragment \"${package_makefile_rules_frag}\" 1>&2
- echo '***' is missing in ${PWD=`${PWDCMD-pwd}`}. 1>&2
- mv ${Makefile} ${subdir}/Makefile.tem
- fi
- esac
- # real copy now in ${subdir}/Makefile.tem
-
- # prepend warning about editing, and a bunch of variables.
- rm -f ${Makefile}
- cat > ${Makefile} <<EOF
-# ${NO_EDIT}
-VPATH = ${makesrcdir}
-links = ${configlinks}
-host_alias = ${host_alias}
-host_cpu = ${host_cpu}
-host_vendor = ${host_vendor}
-host_os = ${host_os}
-host_canonical = ${host_cpu}-${host_vendor}-${host_os}
-target_alias = ${target_alias}
-target_cpu = ${target_cpu}
-target_vendor = ${target_vendor}
-target_os = ${target_os}
-target_canonical = ${target_cpu}-${target_vendor}-${target_os}
-EOF
- case "${build}" in
- "") ;;
- *) cat >> ${Makefile} << EOF
-build_alias = ${build_alias}
-build_cpu = ${build_cpu}
-build_vendor = ${build_vendor}
-build_os = ${build_os}
-build_canonical = ${build_cpu}-${build_vendor}-${build_os}
-EOF
- esac
-
- case "${package_makefile_frag}" in
- "") ;;
- /* | [A-Za-z]:[\\/]* ) echo package_makefile_frag = ${package_makefile_frag} >>${Makefile} ;;
- *) echo package_makefile_frag = ${invsubdir}${package_makefile_frag} >>${Makefile} ;;
- esac
-
- case "${target_makefile_frag}" in
- "") ;;
- /* | [A-Za-z]:[\\/]* ) echo target_makefile_frag = ${target_makefile_frag} >>${Makefile} ;;
- *) echo target_makefile_frag = ${invsubdir}${target_makefile_frag} >>${Makefile} ;;
- esac
-
- case "${host_makefile_frag}" in
- "") ;;
- /* | [A-Za-z]:[\\/]* ) echo host_makefile_frag = ${host_makefile_frag} >>${Makefile} ;;
- *) echo host_makefile_frag = ${invsubdir}${host_makefile_frag} >>${Makefile} ;;
- esac
-
- if [ "${site_makefile_frag}" != "" ] ; then
- echo site_makefile_frag = ${invsubdir}${site_makefile_frag} >>${Makefile}
- fi
-
- echo enable_shared = ${enable_shared} >> ${Makefile}
- echo enable_threads = ${enable_threads} >> ${Makefile}
- # record if we want to rumtime library stuff installed in libsubdir.
- if test -z "${enable_version_specific_runtime_libs}"; then
- echo enable_version_specific_runtime_libs = no >> ${Makefile}
- else
- echo enable_version_specific_runtime_libs = ${enable_version_specific_runtime_libs} >> ${Makefile}
- fi
+# If --enable-shared was set, we must set LD_LIBRARY_PATH so that the
+# binutils tools will find libbfd.so.
+case "${enable_shared}" in
+ no | "") SET_LIB_PATH= ;;
+ *) SET_LIB_PATH="\$(REALLY_SET_LIB_PATH)" ;;
+esac
- # Emit a macro which describes the file containing gcc's
- # version number.
- echo gcc_version_trigger = ${gcc_version_trigger} >> ${Makefile}
- # And emit a macro defining gcc's version number.
- echo gcc_version = ${gcc_version} >> ${Makefile}
-
- # reset prefix, exec_prefix, srcdir, SUBDIRS, NONSUBDIRS,
- # remove any form feeds.
- if [ -z "${subdirs}" ]; then
- rm -f ${subdir}/Makefile.tm2
- sedtemp=sed.$$
- cat >$sedtemp <<EOF
-s:^SUBDIRS[ ]*=.*$:SUBDIRS = ${configdirs}:
-s:^NONSUBDIRS[ ]*=.*$:NONSUBDIRS = ${noconfigdirs}:
-EOF
- sed -f $sedtemp \
- ${subdir}/Makefile.tem > ${subdir}/Makefile.tm2
- rm -f $sedtemp
- rm -f ${subdir}/Makefile.tem
- mv ${subdir}/Makefile.tm2 ${subdir}/Makefile.tem
- fi
- sed -e "s|^prefix[ ]*=.*$|prefix = ${prefix}|" \
- -e "s|^exec_prefix[ ]*=.*$|exec_prefix = ${exec_prefix}|" \
- -e "s|^bindir[ ]*=.*$|bindir = ${bindir}|" \
- -e "s|^sbindir[ ]*=.*$|sbindir = ${sbindir}|" \
- -e "s|^libexecdir[ ]*=.*$|libexecdir = ${libexecdir}|" \
- -e "s|^datadir[ ]*=.*$|datadir = ${datadir}|" \
- -e "s|^sysconfdir[ ]*=.*$|sysconfdir = ${sysconfdir}|" \
- -e "s|^sharedstatedir[ ]*=.*$|sharedstatedir = ${sharedstatedir}|" \
- -e "s|^localstatedir[ ]*=.*$|localstatedir = ${localstatedir}|" \
- -e "s|^libdir[ ]*=.*$|libdir = ${libdir}|" \
- -e "s|^includedir[ ]*=.*$|includedir = ${includedir}|" \
- -e "s|^oldincludedir[ ]*=.*$|oldincludedir = ${oldincludedir}|" \
- -e "s|^infodir[ ]*=.*$|infodir = ${infodir}|" \
- -e "s|^mandir[ ]*=.*$|mandir = ${mandir}|" \
- -e "s|^ALL_BUILD_MODULES =.*|ALL_BUILD_MODULES =${all_build_modules}|" \
- -e "/^CC[ ]*=/{
- :loop1
- /\\\\$/ N
- s/\\\\\\n//g
- t loop1
- s%^CC[ ]*=.*$%CC = ${CC}%
- }" \
- -e "/^CXX[ ]*=/{
- :loop2
- /\\\\$/ N
- s/\\\\\\n//g
- t loop2
- s%^CXX[ ]*=.*$%CXX = ${CXX}%
- }" \
- -e "/^CFLAGS[ ]*=/{
- :loop3
- /\\\\$/ N
- s/\\\\\\n//g
- t loop3
- s%^CFLAGS[ ]*=.*$%CFLAGS = ${CFLAGS}%
- }" \
- -e "/^CXXFLAGS[ ]*=/{
- :loop4
- /\\\\$/ N
- s/\\\\\\n//g
- t loop4
- s%^CXXFLAGS[ ]*=.*$%CXXFLAGS = ${CXXFLAGS}%
- }" \
- -e "s|^SHELL[ ]*=.*$|SHELL = ${config_shell}|" \
- -e "s|^srcdir[ ]*=.*$|srcdir = ${makesrcdir}|" \
- -e "s/ //" \
- -e "s:^program_prefix[ ]*=.*$:program_prefix = ${program_prefix}:" \
- -e "s:^program_suffix[ ]*=.*$:program_suffix = ${program_suffix}:" \
- -e "s:^program_transform_name[ ]*=.*$:program_transform_name = ${program_transform_name}:" \
- -e "s|^tooldir[ ]*=.*$|tooldir = ${tooldir}|" \
- -e "s|^build_tooldir[ ]*=.*$|build_tooldir = ${tooldir}|" \
- -e "s:^DEFAULT_YACC[ ]*=.*$:DEFAULT_YACC = ${DEFAULT_YACC}:" \
- -e "s:^DEFAULT_LEX[ ]*=.*$:DEFAULT_LEX = ${DEFAULT_LEX}:" \
- -e "s:^DEFAULT_M4[ ]*=.*$:DEFAULT_M4 = ${DEFAULT_M4}:" \
- ${subdir}/Makefile.tem >> ${Makefile}
-
- sed -e "s:^GDB_TK[ ]*=.*$:GDB_TK = ${GDB_TK}:" ${Makefile} >${Makefile}.tem
- mv -f ${Makefile}.tem ${Makefile}
-
- # If this is a Canadian Cross, preset the values of many more
- # tools.
- if [ "${build}" != "${host}" ]; then
- for var in ${tools}; do
- eval val=\$${var}
- sed -e "/^${var}[ ]*=/{
- :loop1
- /\\\\$/ N
- /\\\\$/ b loop1
- s/\\\\\\n//g
- s%^${var}[ ]*=.*$%${var} = ${val}%
- }" ${Makefile} > ${Makefile}.tem
- mv -f ${Makefile}.tem ${Makefile}
- done
- fi
+case "${host}" in
+ *-*-hpux*) RPATH_ENVVAR=SHLIB_PATH ;;
+ *) RPATH_ENVVAR=LD_LIBRARY_PATH ;;
+esac
- # final copy now in ${Makefile}
+# Record target_configdirs and the configure arguments for target and
+# build configuration in Makefile.
+target_configdirs=`echo "${target_configdirs}" | sed -e 's/target-//g'`
- else
- echo "No Makefile.in found in ${srcdir}/${subdir}, unable to configure" 1>&2
- fi
+# This is the final value for target_configdirs. configdirs already
+# has its final value, as does build_modules. It's time to create some
+# lists of valid targets.
- rm -f ${subdir}/Makefile.tem
+all_build_modules=
+configure_build_modules=
+for module in ${build_modules} ; do
+ all_build_modules=all-build-${module}
+ configure_build_modules=configure-build-${module}
+done
- case "${host_makefile_frag}" in
- "") using= ;;
- *) using="and \"${host_makefile_frag}\"" ;;
- esac
+# Determine whether gdb needs tk/tcl or not.
+# Use 'maybe' since enable_gdbtk might be true even if tk isn't available
+# and in that case we want gdb to be built without tk. Ugh!
+# In fact I believe gdb is the *only* package directly dependent on tk,
+# so we should be able to put the 'maybe's in unconditionally and
+# leave out the maybe dependencies when enable_gdbtk is false. I'm not
+# 100% sure that that's safe though.
+
+gdb_tk="maybe-all-tcl maybe-all-tk maybe-all-itcl maybe-all-tix maybe-all-libgui"
+case "$enable_gdbtk" in
+ no)
+ GDB_TK="" ;;
+ yes)
+ GDB_TK="${gdb_tk}" ;;
+ *)
+ # Only add the dependency on gdbtk when GDBtk is part of the gdb
+ # distro. Eventually someone will fix this and move Insight, nee
+ # gdbtk to a separate directory.
+ if test -d ${srcdir}/gdb/gdbtk ; then
+ GDB_TK="${gdb_tk}"
+ else
+ GDB_TK=""
+ fi
+ ;;
+esac
- case "${target_makefile_frag}" in
- "") ;;
- *) using="${using} and \"${target_makefile_frag}\"" ;;
- esac
+# Create the 'maybe dependencies'. This uses a temporary file.
- case "${site_makefile_frag}" in
- "") ;;
- *) using="${using} and \"${site_makefile_frag}\"" ;;
- esac
+# While at that, we remove Makefiles if we were started for recursive
+# configuration, so that the top-level Makefile reconfigures them,
+# like we used to do when configure itself was recursive.
+rm -f maybedep.tmp
+echo '# maybedep.tmp' > maybedep.tmp
- newusing=`echo "${using}" | sed 's/and/using/'`
- using=${newusing}
- echo "Created \"${Makefile}\" in" ${PWD=`${PWDCMD-pwd}`} ${using}
+# Make-targets which may need maybe dependencies.
+mts="configure all install check clean distclean dvi info install-info"
+mts="${mts} installcheck mostlyclean maintainer-clean TAGS"
- . ${tmpfile}.pos
+# Loop over modules and make-targets.
+for module in ${build_modules} ; do
+ if test -z "${no_recursion}" \
+ && test -f ${build_subdir}/${module}/Makefile; then
+ echo 1>&2 "*** removing ${build_subdir}/${module}/Makefile to force reconfigure"
+ rm -f ${build_subdir}/${module}/Makefile
+ fi
+ for mt in ${mts} ; do
+ case ${mt} in
+ install) ;; # No installing build modules.
+ *) echo "maybe-${mt}-build-${module}: ${mt}-build-${module}" >> maybedep.tmp ;;
+ esac
+ done
+done
+for module in ${configdirs} ; do
+ if test -z "${no_recursion}" \
+ && test -f ${module}/Makefile; then
+ echo 1>&2 "*** removing ${module}/Makefile to force reconfigure"
+ rm -f ${module}/Makefile
+ fi
+ for mt in ${mts} ; do
+ echo "maybe-${mt}-${module}: ${mt}-${module}" >> maybedep.tmp
+ done
+done
+for module in ${target_configdirs} ; do
+ if test -z "${no_recursion}" \
+ && test -f ${target_subdir}/${module}/Makefile; then
+ echo 1>&2 "*** removing ${target_subdir}/${module}/Makefile to force reconfigure"
+ rm -f ${target_subdir}/${module}/Makefile
+ fi
+ for mt in ${mts} ; do
+ echo "maybe-${mt}-target-${module}: ${mt}-target-${module}" >> maybedep.tmp
+ done
+done
+maybe_dependencies=maybedep.tmp
- # describe the chosen configuration in config.status.
- # Make that file a shellscript which will reestablish
- # the same configuration. Used in Makefiles to rebuild
- # Makefiles.
- case "${norecursion}" in
- "") arguments="${arguments} --norecursion" ;;
- *) ;;
- esac
+# Create the serialization dependencies. This uses a temporary file.
- if [ ${subdir} = . ] ; then
- echo "#!/bin/sh
-# ${NO_EDIT}
-# This directory was configured as follows:
-${progname}" ${arguments} "
-# ${using}" > ${subdir}/config.new
- else
- echo "#!/bin/sh
-# ${NO_EDIT}
-# This directory was configured as follows:
-cd ${invsubdir}
-${progname}" ${arguments} "
-# ${using}" > ${subdir}/config.new
- fi
- chmod a+x ${subdir}/config.new
- if [ -r ${subdir}/config.back ] ; then
- mv -f ${subdir}/config.back ${subdir}/config.status
- fi
- ${config_shell} ${moveifchange} ${subdir}/config.new ${subdir}/config.status
- ;;
+# Check whether --enable-serial-configure or --disable-serial-configure was given.
+if test "${enable_serial_configure+set}" = set; then
+ enableval="$enable_serial_configure"
+ :
+fi
- *) rm -f ${Makefile} ${subdir}/config.status ${links} ;;
- esac
+
+case ${enable_serial_configure} in
+ yes)
+ enable_serial_build_configure=yes
+ enable_serial_host_configure=yes
+ enable_serial_target_configure=yes
+ ;;
+esac
+
+# These force 'configure's to be done one at a time, to avoid problems
+# with contention over a shared config.cache.
+rm -f serdep.tmp
+echo '# serdep.tmp' > serdep.tmp
+olditem=
+test "x${enable_serial_build_configure}" = xyes &&
+for item in ${build_configdirs} ; do
+ case ${olditem} in
+ "") ;;
+ *) echo "configure-build-${item}: configure-build-${olditem}" >> serdep.tmp ;;
+ esac
+ olditem=${item}
+done
+olditem=
+test "x${enable_serial_host_configure}" = xyes &&
+for item in ${configdirs} ; do
+ case ${olditem} in
+ "") ;;
+ *) echo "configure-${item}: configure-${olditem}" >> serdep.tmp ;;
+ esac
+ olditem=${item}
+done
+olditem=
+test "x${enable_serial_target_configure}" = xyes &&
+for item in ${target_configdirs} ; do
+ case ${olditem} in
+ "") ;;
+ *) echo "configure-target-${item}: configure-target-${olditem}" >> serdep.tmp ;;
+ esac
+ olditem=${item}
done
+serialization_dependencies=serdep.tmp
+
+
+# Base args. Strip norecursion, cache-file, srcdir, host, build,
+# target and nonopt. These are the ones we might not want to pass
+# down to subconfigures. Also strip program-prefix, program-suffix,
+# and program-transform-name, so that we can pass down a consistent
+# program-transform-name. If autoconf has put single quotes around
+# any of these arguments (because they contain shell metacharacters)
+# then this will fail; in practice this only happens for
+# --program-transform-name, so be sure to override --program-transform-name
+# at the end of the argument list.
+# These will be expanded by make, so quote '$'.
+cat <<\EOF_SED > conftestsed
+s/ --no[^ ]* / /
+s/ --c[a-z-]*[= ][^ ]* / /
+s/ --sr[a-z-]*[= ][^ ]* / /
+s/ --ho[a-z-]*[= ][^ ]* / /
+s/ --bu[a-z-]*[= ][^ ]* / /
+s/ --t[a-z-]*[= ][^ ]* / /
+s/ --program-[pst][a-z-]*[= ][^ ]* / /
+s/ -cache-file[= ][^ ]* / /
+s/ -srcdir[= ][^ ]* / /
+s/ -host[= ][^ ]* / /
+s/ -build[= ][^ ]* / /
+s/ -target[= ][^ ]* / /
+s/ -program-prefix[= ][^ ]* / /
+s/ -program-suffix[= ][^ ]* / /
+s/ -program-transform-name[= ][^ ]* / /
+s/ [^' -][^ ]* / /
+s/^ *//;s/ *$//
+s,\$,$$,g
+EOF_SED
+sed -f conftestsed <<EOF_SED > conftestsed.out
+ ${ac_configure_args}
+EOF_SED
+baseargs=`cat conftestsed.out`
+rm -f conftestsed conftestsed.out
+
+# Add in --program-transform-name, after --program-prefix and
+# --program-suffix have been applied to it. Autoconf has already
+# doubled dollar signs and backslashes in program_transform_name; we want
+# the backslashes un-doubled, and then the entire thing wrapped in single
+# quotes, because this will be expanded first by make and then by the shell.
+# Also, because we want to override the logic in subdir configure scripts to
+# choose program_transform_name, replace any s,x,x, with s,y,y,.
+sed -e "s,\\\\\\\\,\\\\,g; s,','\\\\'',g; s/s,x,x,/s,y,y,/" <<EOF_SED > conftestsed.out
+${program_transform_name}
+EOF_SED
+gcc_transform_name=`cat conftestsed.out`
+rm -f conftestsed.out
+baseargs="$baseargs --program-transform-name='${gcc_transform_name}'"
+
+# For the build-side libraries, we just need to pretend we're native,
+# and not use the same cache file. Multilibs are neither needed nor
+# desired.
+build_configargs="--cache-file=../config.cache --build=${build_alias} --host=${build_alias} ${baseargs}"
+
+# For host modules, accept cache file option, or specification as blank.
+case "${cache_file}" in
+"") # empty
+ cache_file_option="" ;;
+/* | [A-Za-z]:[\\/]* ) # absolute path
+ cache_file_option="--cache-file=${cache_file}" ;;
+*) # relative path
+ cache_file_option="--cache-file=../${cache_file}" ;;
+esac
-# If there are subdirectories, then recur.
-if [ -z "${norecursion}" ] && [ -n "${configdirs}" ] ; then
- for configdir in ${configdirs} ${extraconfigdirs} ; do
-
- # If configdir contains ',' it is
- # srcdir,builddir,target_alias
- # These come from extraconfigdirs.
- case ${configdir} in
- *,*)
- eval `echo ${configdir} | sed -e 's/\([^,]*\),\([^,]*\),\(.*\)/cfg_dir=\1 bld_dir=\2 tgt_alias=\3/'`
- ;;
- *)
- cfg_dir=${configdir}
- bld_dir=${configdir}
- tgt_alias=${target_alias}
- ;;
- esac
-
- if [ -d ${srcdir}/${cfg_dir} ] ; then
- eval echo Configuring ${configdir}... ${redirect}
- case "${srcdir}" in
- ".") ;;
- *)
- if [ ! -d ./${bld_dir} ] ; then
- if mkdir ./${bld_dir} ; then
- true
- else
- echo '***' "${progname}: could not make ${PWD=`${PWDCMD-pwd}`}/${bld_dir}" 1>&2
- exit 1
- fi
- fi
- ;;
- esac
-
- POPDIR=${PWD=`${PWDCMD-pwd}`}
- cd ${bld_dir}
-
-### figure out what to do with srcdir
- case "${srcdir}" in
- ".") newsrcdir=${srcdir} ;; # no -srcdir option. We're building in place.
- /* | [A-Za-z]:[\\/]* ) # absolute path
- newsrcdir=${srcdir}/${cfg_dir}
- srcdiroption="--srcdir=${newsrcdir}"
- ;;
- *) # otherwise relative
- newsrcdir=../${srcdir}/${cfg_dir}
- srcdiroption="--srcdir=${newsrcdir}"
- ;;
- esac
-
- # Handle --cache-file=../XXX
- case "${cache_file}" in
- "") # empty
- ;;
- /* | [A-Za-z]:[\\/]* ) # absolute path
- cache_file_option="--cache-file=${cache_file}"
- ;;
- *) # relative path
- cache_file_option="--cache-file=../${cache_file}"
- ;;
- esac
-
-### check for guested configure, otherwise fix possibly relative progname
- if [ -f ${newsrcdir}/configure ] ; then
- recprog=${newsrcdir}/configure
- elif [ -f ${newsrcdir}/configure.in ] ; then
- case "${progname}" in
- /* | [A-Za-z]:[\\/]* ) recprog=${progname} ;;
- *) recprog=../${progname} ;;
- esac
- else
- eval echo No configuration information in ${cfg_dir} ${redirect}
- recprog=
- fi
-
-### The recursion line is here.
- if [ ! -z "${recprog}" ] ; then
- if eval ${config_shell} ${recprog} ${verbose} ${buildopt} --host=${host_alias} --target=${tgt_alias} \
- ${prefixoption} ${tmpdiroption} ${exec_prefixoption} \
- ${srcdiroption} ${diroptions} ${program_prefixoption} ${program_suffixoption} ${program_transform_nameoption} ${site_option} ${withoptions} ${withoutoptions} ${enableoptions} ${disableoptions} ${floating_pointoption} ${cache_file_option} ${removing} ${other_options} ${redirect} ; then
- true
- else
- echo Configure in `${PWDCMD-pwd}` failed, exiting. 1>&2
- exit 1
- fi
- fi
-
- cd ${POPDIR}
- fi
- done
-fi
-
-# Perform the same cleanup as the trap handler, minus the "exit 1" of course,
-# and reset the trap handler.
-rm -rf ${tmpdir}
-trap 0
+# Host dirs don't like to share a cache file either, horribly enough.
+# This seems to be due to autoconf 2.5x stupidity.
+host_configargs="--cache-file=./config.cache --build=${build_alias} --host=${host_alias} --target=${target_alias} ${extra_host_args} ${baseargs}"
+
+target_configargs=${baseargs}
+
+# Passing a --with-cross-host argument lets the target libraries know
+# whether they are being built with a cross-compiler or being built
+# native. However, it would be better to use other mechanisms to make the
+# sorts of decisions they want to make on this basis. Please consider
+# this option to be deprecated. FIXME.
+if test x${is_cross_compiler} = xyes ; then
+ target_configargs="--with-cross-host=${host_alias} ${target_configargs}"
+fi
+
+# Default to --enable-multilib.
+if test x${enable_multilib} = x ; then
+ target_configargs="--enable-multilib ${target_configargs}"
+fi
+
+# Pass --with-newlib if appropriate. Note that target_configdirs has
+# changed from the earlier setting of with_newlib.
+if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " newlib " > /dev/null 2>&1 && test -d ${srcdir}/newlib ; then
+ target_configargs="--with-newlib ${target_configargs}"
+fi
+
+# Different target subdirs use different values of certain variables
+# (notably CXX). Worse, multilibs use *lots* of different values.
+# Worse yet, autoconf 2.5x makes some of these 'precious', meaning that
+# it doesn't automatically accept command-line overrides of them.
+# This means it's not safe for target subdirs to share a cache file,
+# which is disgusting, but there you have it. Hopefully this can be
+# fixed in future. It's still worthwhile to use a cache file for each
+# directory. I think.
+
+# Pass the appropriate --host, --build, and --cache-file arguments.
+target_configargs="--cache-file=./config.cache --host=${target_alias} --build=${build_alias} ${target_configargs}"
+
+# provide a proper gxx_include_dir.
+# Note, if you change the default, make sure to fix both here and in
+# the gcc and libstdc++-v3 subdirectories.
+# Check whether --with-gxx-include-dir or --without-gxx-include-dir was given.
+case "${with_gxx_include_dir}" in
+ yes)
+ { echo "configure: error: --with-gxx-include-dir=[dir] requires a directory" 1>&2; exit 1; }
+ ;;
+ no | "")
+ case "${enable_version_specific_runtime_libs}" in
+ yes) gxx_include_dir='${libsubdir}/include/c++' ;;
+ *)
+ . ${srcdir}/config.if
+ gxx_include_dir='${prefix}/include/'${libstdcxx_incdir} ;;
+ esac ;;
+ *) gxx_include_dir=${with_gxx_include_dir} ;;
+esac
+
+FLAGS_FOR_TARGET=
+case " $target_configdirs " in
+ *" newlib "*)
+ case " $target_configargs " in
+ *" --with-newlib "*)
+ case "$target" in
+ *-cygwin*)
+ FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup -L$$r/$(TARGET_SUBDIR)/winsup/cygwin -L$$r/$(TARGET_SUBDIR)/winsup/w32api/lib -isystem $$s/winsup/include -isystem $$s/winsup/cygwin/include -isystem $$s/winsup/w32api/include' ;;
+ esac
+
+ # If we're not building GCC, don't discard standard headers.
+ if test -d ${srcdir}/gcc; then
+ FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -nostdinc'
+
+ if test "${build}" != "${host}"; then
+ # On Canadian crosses, CC_FOR_TARGET will have already been set
+ # by `configure', so we won't have an opportunity to add -Bgcc/
+ # to it. This is right: we don't want to search that directory
+ # for binaries, but we want the header files in there, so add
+ # them explicitly.
+ FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -isystem $$r/gcc/include'
+
+ # Someone might think of using the pre-installed headers on
+ # Canadian crosses, in case the installed compiler is not fully
+ # compatible with the compiler being built. In this case, it
+ # would be better to flag an error than risking having
+ # incompatible object files being constructed. We can't
+ # guarantee that an error will be flagged, but let's hope the
+ # compiler will do it, when presented with incompatible header
+ # files.
+ fi
+ fi
+
+ case "${target}-${is_cross_compiler}" in
+ i[3456789]86-*-linux*-no)
+ # Here host == target, so we don't need to build gcc,
+ # so we don't want to discard standard headers.
+ FLAGS_FOR_TARGET=`echo " $FLAGS_FOR_TARGET " | sed -e 's/ -nostdinc / /'`
+ ;;
+ *)
+ # If we're building newlib, use its generic headers last, but search
+ # for any libc-related directories first (so make it the last -B
+ # switch).
+ FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$$r/$(TARGET_SUBDIR)/newlib/ -isystem $$r/$(TARGET_SUBDIR)/newlib/targ-include -isystem $$s/newlib/libc/include'
+ ;;
+ esac
+ ;;
+ esac
+ ;;
+esac
+
+# Allow the user to override the flags for
+# our build compiler if desired.
+CFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD-${CFLAGS}}
+
+# On Canadian crosses, we'll be searching the right directories for
+# the previously-installed cross compiler, so don't bother to add
+# flags for directories within the install tree of the compiler
+# being built; programs in there won't even run.
+if test "${build}" = "${host}" && test -d ${srcdir}/gcc; then
+ # Search for pre-installed headers if nothing else fits.
+ FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$(build_tooldir)/bin/ -B$(build_tooldir)/lib/ -isystem $(build_tooldir)/include -isystem $(build_tooldir)/sys-include'
+fi
+
+if test "x${use_gnu_ld}" = x &&
+ echo " ${configdirs} " | grep " ld " > /dev/null ; then
+ # Arrange for us to find uninstalled linker scripts.
+ FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/ld'
+fi
+
+if test "x${CC_FOR_TARGET+set}" = xset; then
+ :
+elif test -d ${srcdir}/gcc; then
+ CC_FOR_TARGET='$$r/gcc/xgcc -B$$r/gcc/'
+elif test "$host" = "$target"; then
+ CC_FOR_TARGET='$(CC)'
+else
+ CC_FOR_TARGET=`echo gcc | sed "${program_transform_name}"`
+fi
+CC_FOR_TARGET=$CC_FOR_TARGET' $(FLAGS_FOR_TARGET)'
+
+if test "x${GCJ_FOR_TARGET+set}" = xset; then
+ :
+elif test -d ${srcdir}/gcc; then
+ GCJ_FOR_TARGET='$$r/gcc/gcj -B$$r/gcc/'
+elif test "$host" = "$target"; then
+ GCJ_FOR_TARGET='gcj'
+else
+ GCJ_FOR_TARGET=`echo gcj | sed "${program_transform_name}"`
+fi
+GCJ_FOR_TARGET=$GCJ_FOR_TARGET' $(FLAGS_FOR_TARGET)'
+
+# Don't use libstdc++-v3's flags to configure/build itself.
+libstdcxx_flags='`test ! -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags || $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags --build-includes` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs'
+raw_libstdcxx_flags='-L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs'
+
+if test "x${CXX_FOR_TARGET+set}" = xset; then
+ if test "x${RAW_CXX_FOR_TARGET+set}" != xset; then
+ RAW_CXX_FOR_TARGET=${CXX_FOR_TARGET}
+ fi
+elif test -d ${srcdir}/gcc; then
+ # We add -shared-libgcc to CXX_FOR_TARGET whenever we use xgcc instead
+ # of g++ for linking C++ or Java, because g++ has -shared-libgcc by
+ # default whereas gcc does not.
+ # RAW_CXX_FOR_TARGET is for linking C++ or java; CXX_FOR_TARGET is for
+ # all other cases.
+ CXX_FOR_TARGET='$$r/gcc/g++ -B$$r/gcc/ -nostdinc++ '$libstdcxx_flags
+ RAW_CXX_FOR_TARGET='$$r/gcc/xgcc -shared-libgcc -B$$r/gcc/ -nostdinc++ '$raw_libstdcxx_flags
+elif test "$host" = "$target"; then
+ CXX_FOR_TARGET='$(CXX)'
+ RAW_CXX_FOR_TARGET=${CXX_FOR_TARGET}
+else
+ CXX_FOR_TARGET=`echo c++ | sed "${program_transform_name}"`
+ RAW_CXX_FOR_TARGET=${CXX_FOR_TARGET}
+fi
+CXX_FOR_TARGET=$CXX_FOR_TARGET' $(FLAGS_FOR_TARGET)'
+RAW_CXX_FOR_TARGET=$RAW_CXX_FOR_TARGET' $(FLAGS_FOR_TARGET)'
+
+qCXX_FOR_TARGET=`echo "$CXX_FOR_TARGET" | sed 's,[&%],\\\&,g'`
+qRAW_CXX_FOR_TARGET=`echo "$RAW_CXX_FOR_TARGET" | sed 's,[&%],\\\&,g'`
+
+# We want to defer the evaluation of `cmd`s and shell variables in
+# CXX_FOR_TARGET when recursing in the top-level Makefile, such as for
+# bootstrap. We'll enclose CXX_FOR_TARGET_FOR_RECURSIVE_MAKE in single
+# quotes, but we still have to duplicate `$'s so that shell variables
+# can be expanded by the nested make as shell variables, not as make
+# macros.
+qqCXX_FOR_TARGET=`echo "$qCXX_FOR_TARGET" | sed -e 's,[$][$],$$$$,g'`
+qqRAW_CXX_FOR_TARGET=`echo "$qRAW_CXX_FOR_TARGET" | sed -e 's,[$][$],$$$$,g'`
+
+# Wrap CC_FOR_TARGET and friends, for certain types of builds.
+CC_FOR_TARGET="\$(STAGE_CC_WRAPPER) ${CC_FOR_TARGET}"
+GCJ_FOR_TARGET="\$(STAGE_CC_WRAPPER) ${GCJ_FOR_TARGET}"
+CXX_FOR_TARGET="\$(STAGE_CC_WRAPPER) ${qCXX_FOR_TARGET}"
+RAW_CXX_FOR_TARGET="\$(STAGE_CC_WRAPPER) ${qRAW_CXX_FOR_TARGET}"
+CXX_FOR_TARGET_FOR_RECURSIVE_MAKE="\$(STAGE_CC_WRAPPER) ${qqCXX_FOR_TARGET}"
+RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE="\$(STAGE_CC_WRAPPER) ${qqRAW_CXX_FOR_TARGET}"
+
+# Makefile fragments.
+host_makefile_frag=${srcdir}/${host_makefile_frag}
+target_makefile_frag=${srcdir}/${target_makefile_frag}
+alphaieee_frag=${srcdir}/${alphaieee_frag}
+ospace_frag=${srcdir}/${ospace_frag}
+
+
+
+
+
+# Miscellanea: directories, flags, etc.
+
+
+
+
+
+
+
+
+
+
+
+
+
+# Build module lists & subconfigure args.
+
+
+
+
+# Host module lists & subconfigure args.
+
+
+
+# Target module lists & subconfigure args.
+
+
+
+# Build tools.
+
+
+
+
+
+
+
+# Host tools.
+ncn_tool_prefix=
+test -n "$host_alias" && ncn_tool_prefix=$host_alias-
+ncn_target_tool_prefix=
+test -n "$target_alias" && ncn_target_tool_prefix=$target_alias-
+
+ if test -n "$ncn_tool_prefix"; then
+ # Extract the first word of "${ncn_tool_prefix}ar", so it can be a program name with args.
+set dummy ${ncn_tool_prefix}ar; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:2855: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$AR"; then
+ ac_cv_prog_AR="$AR" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_AR="${ncn_tool_prefix}ar"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+AR="$ac_cv_prog_AR"
+if test -n "$AR"; then
+ echo "$ac_t""$AR" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+fi
+if test -z "$ac_cv_prog_AR" ; then
+ if test $build = $host ; then
+ ncn_cv_AR=$AR
+ # Extract the first word of "ar", so it can be a program name with args.
+set dummy ar; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:2888: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_AR'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$ncn_cv_AR"; then
+ ac_cv_prog_ncn_cv_AR="$ncn_cv_AR" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_ncn_cv_AR="ar"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+ test -z "$ac_cv_prog_ncn_cv_AR" && ac_cv_prog_ncn_cv_AR="ar"
+fi
+fi
+ncn_cv_AR="$ac_cv_prog_ncn_cv_AR"
+if test -n "$ncn_cv_AR"; then
+ echo "$ac_t""$ncn_cv_AR" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ AR=$ncn_cv_AR
+ else
+ AR="${ncn_tool_prefix}ar"
+ fi
+else
+ AR="$ac_cv_prog_AR"
+fi
+
+ if test -n "$ncn_tool_prefix"; then
+ # Extract the first word of "${ncn_tool_prefix}as", so it can be a program name with args.
+set dummy ${ncn_tool_prefix}as; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:2927: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_AS'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$AS"; then
+ ac_cv_prog_AS="$AS" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_AS="${ncn_tool_prefix}as"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+AS="$ac_cv_prog_AS"
+if test -n "$AS"; then
+ echo "$ac_t""$AS" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+fi
+if test -z "$ac_cv_prog_AS" ; then
+ if test $build = $host ; then
+ ncn_cv_AS=$AS
+ # Extract the first word of "as", so it can be a program name with args.
+set dummy as; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:2960: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_AS'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$ncn_cv_AS"; then
+ ac_cv_prog_ncn_cv_AS="$ncn_cv_AS" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_ncn_cv_AS="as"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+ test -z "$ac_cv_prog_ncn_cv_AS" && ac_cv_prog_ncn_cv_AS="as"
+fi
+fi
+ncn_cv_AS="$ac_cv_prog_ncn_cv_AS"
+if test -n "$ncn_cv_AS"; then
+ echo "$ac_t""$ncn_cv_AS" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ AS=$ncn_cv_AS
+ else
+ AS="${ncn_tool_prefix}as"
+ fi
+else
+ AS="$ac_cv_prog_AS"
+fi
+
+ if test -n "$ncn_tool_prefix"; then
+ # Extract the first word of "${ncn_tool_prefix}dlltool", so it can be a program name with args.
+set dummy ${ncn_tool_prefix}dlltool; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:2999: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$DLLTOOL"; then
+ ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_DLLTOOL="${ncn_tool_prefix}dlltool"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+DLLTOOL="$ac_cv_prog_DLLTOOL"
+if test -n "$DLLTOOL"; then
+ echo "$ac_t""$DLLTOOL" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+fi
+if test -z "$ac_cv_prog_DLLTOOL" ; then
+ if test $build = $host ; then
+ ncn_cv_DLLTOOL=$DLLTOOL
+ # Extract the first word of "dlltool", so it can be a program name with args.
+set dummy dlltool; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3032: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_DLLTOOL'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$ncn_cv_DLLTOOL"; then
+ ac_cv_prog_ncn_cv_DLLTOOL="$ncn_cv_DLLTOOL" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_ncn_cv_DLLTOOL="dlltool"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+ test -z "$ac_cv_prog_ncn_cv_DLLTOOL" && ac_cv_prog_ncn_cv_DLLTOOL="dlltool"
+fi
+fi
+ncn_cv_DLLTOOL="$ac_cv_prog_ncn_cv_DLLTOOL"
+if test -n "$ncn_cv_DLLTOOL"; then
+ echo "$ac_t""$ncn_cv_DLLTOOL" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ DLLTOOL=$ncn_cv_DLLTOOL
+ else
+ DLLTOOL="${ncn_tool_prefix}dlltool"
+ fi
+else
+ DLLTOOL="$ac_cv_prog_DLLTOOL"
+fi
+
+ if test -n "$ncn_tool_prefix"; then
+ # Extract the first word of "${ncn_tool_prefix}ld", so it can be a program name with args.
+set dummy ${ncn_tool_prefix}ld; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3071: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_LD'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$LD"; then
+ ac_cv_prog_LD="$LD" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_LD="${ncn_tool_prefix}ld"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+LD="$ac_cv_prog_LD"
+if test -n "$LD"; then
+ echo "$ac_t""$LD" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+fi
+if test -z "$ac_cv_prog_LD" ; then
+ if test $build = $host ; then
+ ncn_cv_LD=$LD
+ # Extract the first word of "ld", so it can be a program name with args.
+set dummy ld; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3104: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_LD'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$ncn_cv_LD"; then
+ ac_cv_prog_ncn_cv_LD="$ncn_cv_LD" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_ncn_cv_LD="ld"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+ test -z "$ac_cv_prog_ncn_cv_LD" && ac_cv_prog_ncn_cv_LD="ld"
+fi
+fi
+ncn_cv_LD="$ac_cv_prog_ncn_cv_LD"
+if test -n "$ncn_cv_LD"; then
+ echo "$ac_t""$ncn_cv_LD" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ LD=$ncn_cv_LD
+ else
+ LD="${ncn_tool_prefix}ld"
+ fi
+else
+ LD="$ac_cv_prog_LD"
+fi
+
+ if test -n "$ncn_tool_prefix"; then
+ # Extract the first word of "${ncn_tool_prefix}nm", so it can be a program name with args.
+set dummy ${ncn_tool_prefix}nm; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3143: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_NM'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$NM"; then
+ ac_cv_prog_NM="$NM" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_NM="${ncn_tool_prefix}nm"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+NM="$ac_cv_prog_NM"
+if test -n "$NM"; then
+ echo "$ac_t""$NM" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+fi
+if test -z "$ac_cv_prog_NM" ; then
+ if test $build = $host ; then
+ ncn_cv_NM=$NM
+ # Extract the first word of "nm", so it can be a program name with args.
+set dummy nm; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3176: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_NM'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$ncn_cv_NM"; then
+ ac_cv_prog_ncn_cv_NM="$ncn_cv_NM" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_ncn_cv_NM="nm"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+ test -z "$ac_cv_prog_ncn_cv_NM" && ac_cv_prog_ncn_cv_NM="nm"
+fi
+fi
+ncn_cv_NM="$ac_cv_prog_ncn_cv_NM"
+if test -n "$ncn_cv_NM"; then
+ echo "$ac_t""$ncn_cv_NM" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ NM=$ncn_cv_NM
+ else
+ NM="${ncn_tool_prefix}nm"
+ fi
+else
+ NM="$ac_cv_prog_NM"
+fi
+
+ if test -n "$ncn_tool_prefix"; then
+ # Extract the first word of "${ncn_tool_prefix}ranlib", so it can be a program name with args.
+set dummy ${ncn_tool_prefix}ranlib; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3215: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$RANLIB"; then
+ ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_RANLIB="${ncn_tool_prefix}ranlib"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+RANLIB="$ac_cv_prog_RANLIB"
+if test -n "$RANLIB"; then
+ echo "$ac_t""$RANLIB" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+fi
+if test -z "$ac_cv_prog_RANLIB" ; then
+ if test $build = $host ; then
+ ncn_cv_RANLIB=$RANLIB
+ # Extract the first word of "ranlib", so it can be a program name with args.
+set dummy ranlib; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3248: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_RANLIB'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$ncn_cv_RANLIB"; then
+ ac_cv_prog_ncn_cv_RANLIB="$ncn_cv_RANLIB" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_ncn_cv_RANLIB="ranlib"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+ test -z "$ac_cv_prog_ncn_cv_RANLIB" && ac_cv_prog_ncn_cv_RANLIB=":"
+fi
+fi
+ncn_cv_RANLIB="$ac_cv_prog_ncn_cv_RANLIB"
+if test -n "$ncn_cv_RANLIB"; then
+ echo "$ac_t""$ncn_cv_RANLIB" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ RANLIB=$ncn_cv_RANLIB
+ else
+ RANLIB=":"
+ fi
+else
+ RANLIB="$ac_cv_prog_RANLIB"
+fi
+
+ if test -n "$ncn_tool_prefix"; then
+ # Extract the first word of "${ncn_tool_prefix}windres", so it can be a program name with args.
+set dummy ${ncn_tool_prefix}windres; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3287: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_WINDRES'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$WINDRES"; then
+ ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_WINDRES="${ncn_tool_prefix}windres"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+WINDRES="$ac_cv_prog_WINDRES"
+if test -n "$WINDRES"; then
+ echo "$ac_t""$WINDRES" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+fi
+if test -z "$ac_cv_prog_WINDRES" ; then
+ if test $build = $host ; then
+ ncn_cv_WINDRES=$WINDRES
+ # Extract the first word of "windres", so it can be a program name with args.
+set dummy windres; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3320: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_WINDRES'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$ncn_cv_WINDRES"; then
+ ac_cv_prog_ncn_cv_WINDRES="$ncn_cv_WINDRES" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_ncn_cv_WINDRES="windres"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+ test -z "$ac_cv_prog_ncn_cv_WINDRES" && ac_cv_prog_ncn_cv_WINDRES="windres"
+fi
+fi
+ncn_cv_WINDRES="$ac_cv_prog_ncn_cv_WINDRES"
+if test -n "$ncn_cv_WINDRES"; then
+ echo "$ac_t""$ncn_cv_WINDRES" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ WINDRES=$ncn_cv_WINDRES
+ else
+ WINDRES="${ncn_tool_prefix}windres"
+ fi
+else
+ WINDRES="$ac_cv_prog_WINDRES"
+fi
+
+ if test -n "$ncn_tool_prefix"; then
+ # Extract the first word of "${ncn_tool_prefix}objcopy", so it can be a program name with args.
+set dummy ${ncn_tool_prefix}objcopy; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3359: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_OBJCOPY'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$OBJCOPY"; then
+ ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_OBJCOPY="${ncn_tool_prefix}objcopy"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+OBJCOPY="$ac_cv_prog_OBJCOPY"
+if test -n "$OBJCOPY"; then
+ echo "$ac_t""$OBJCOPY" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+fi
+if test -z "$ac_cv_prog_OBJCOPY" ; then
+ if test $build = $host ; then
+ ncn_cv_OBJCOPY=$OBJCOPY
+ # Extract the first word of "objcopy", so it can be a program name with args.
+set dummy objcopy; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3392: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_OBJCOPY'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$ncn_cv_OBJCOPY"; then
+ ac_cv_prog_ncn_cv_OBJCOPY="$ncn_cv_OBJCOPY" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_ncn_cv_OBJCOPY="objcopy"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+ test -z "$ac_cv_prog_ncn_cv_OBJCOPY" && ac_cv_prog_ncn_cv_OBJCOPY="objcopy"
+fi
+fi
+ncn_cv_OBJCOPY="$ac_cv_prog_ncn_cv_OBJCOPY"
+if test -n "$ncn_cv_OBJCOPY"; then
+ echo "$ac_t""$ncn_cv_OBJCOPY" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ OBJCOPY=$ncn_cv_OBJCOPY
+ else
+ OBJCOPY="${ncn_tool_prefix}objcopy"
+ fi
+else
+ OBJCOPY="$ac_cv_prog_OBJCOPY"
+fi
+
+ if test -n "$ncn_tool_prefix"; then
+ # Extract the first word of "${ncn_tool_prefix}objdump", so it can be a program name with args.
+set dummy ${ncn_tool_prefix}objdump; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3431: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_OBJDUMP'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$OBJDUMP"; then
+ ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_OBJDUMP="${ncn_tool_prefix}objdump"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+OBJDUMP="$ac_cv_prog_OBJDUMP"
+if test -n "$OBJDUMP"; then
+ echo "$ac_t""$OBJDUMP" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+fi
+if test -z "$ac_cv_prog_OBJDUMP" ; then
+ if test $build = $host ; then
+ ncn_cv_OBJDUMP=$OBJDUMP
+ # Extract the first word of "objdump", so it can be a program name with args.
+set dummy objdump; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3464: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_OBJDUMP'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$ncn_cv_OBJDUMP"; then
+ ac_cv_prog_ncn_cv_OBJDUMP="$ncn_cv_OBJDUMP" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_ncn_cv_OBJDUMP="objdump"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+ test -z "$ac_cv_prog_ncn_cv_OBJDUMP" && ac_cv_prog_ncn_cv_OBJDUMP="objdump"
+fi
+fi
+ncn_cv_OBJDUMP="$ac_cv_prog_ncn_cv_OBJDUMP"
+if test -n "$ncn_cv_OBJDUMP"; then
+ echo "$ac_t""$ncn_cv_OBJDUMP" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ OBJDUMP=$ncn_cv_OBJDUMP
+ else
+ OBJDUMP="${ncn_tool_prefix}objdump"
+ fi
+else
+ OBJDUMP="$ac_cv_prog_OBJDUMP"
+fi
-exit 0
+
+
+
+
+
+
+
+
+# Target tools.
+ if test -n "$ncn_target_tool_prefix"; then
+ # Extract the first word of "${ncn_target_tool_prefix}ar", so it can be a program name with args.
+set dummy ${ncn_target_tool_prefix}ar; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3513: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_AR_FOR_TARGET'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$AR_FOR_TARGET"; then
+ ac_cv_prog_AR_FOR_TARGET="$AR_FOR_TARGET" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_AR_FOR_TARGET="${ncn_target_tool_prefix}ar"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+AR_FOR_TARGET="$ac_cv_prog_AR_FOR_TARGET"
+if test -n "$AR_FOR_TARGET"; then
+ echo "$ac_t""$AR_FOR_TARGET" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+fi
+if test -z "$ac_cv_prog_AR_FOR_TARGET" ; then
+ if test $build = $target ; then
+ ncn_cv_AR_FOR_TARGET=$AR_FOR_TARGET
+ # Extract the first word of "ar", so it can be a program name with args.
+set dummy ar; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3546: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_AR_FOR_TARGET'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$ncn_cv_AR_FOR_TARGET"; then
+ ac_cv_prog_ncn_cv_AR_FOR_TARGET="$ncn_cv_AR_FOR_TARGET" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_ncn_cv_AR_FOR_TARGET="ar"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+ test -z "$ac_cv_prog_ncn_cv_AR_FOR_TARGET" && ac_cv_prog_ncn_cv_AR_FOR_TARGET="ar"
+fi
+fi
+ncn_cv_AR_FOR_TARGET="$ac_cv_prog_ncn_cv_AR_FOR_TARGET"
+if test -n "$ncn_cv_AR_FOR_TARGET"; then
+ echo "$ac_t""$ncn_cv_AR_FOR_TARGET" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ AR_FOR_TARGET=$ncn_cv_AR_FOR_TARGET
+ else
+ AR_FOR_TARGET="${ncn_target_tool_prefix}ar"
+ fi
+else
+ AR_FOR_TARGET="$ac_cv_prog_AR_FOR_TARGET"
+fi
+
+ if test -n "$ncn_target_tool_prefix"; then
+ # Extract the first word of "${ncn_target_tool_prefix}as", so it can be a program name with args.
+set dummy ${ncn_target_tool_prefix}as; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3585: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_AS_FOR_TARGET'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$AS_FOR_TARGET"; then
+ ac_cv_prog_AS_FOR_TARGET="$AS_FOR_TARGET" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_AS_FOR_TARGET="${ncn_target_tool_prefix}as"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+AS_FOR_TARGET="$ac_cv_prog_AS_FOR_TARGET"
+if test -n "$AS_FOR_TARGET"; then
+ echo "$ac_t""$AS_FOR_TARGET" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+fi
+if test -z "$ac_cv_prog_AS_FOR_TARGET" ; then
+ if test $build = $target ; then
+ ncn_cv_AS_FOR_TARGET=$AS_FOR_TARGET
+ # Extract the first word of "as", so it can be a program name with args.
+set dummy as; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3618: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_AS_FOR_TARGET'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$ncn_cv_AS_FOR_TARGET"; then
+ ac_cv_prog_ncn_cv_AS_FOR_TARGET="$ncn_cv_AS_FOR_TARGET" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_ncn_cv_AS_FOR_TARGET="as"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+ test -z "$ac_cv_prog_ncn_cv_AS_FOR_TARGET" && ac_cv_prog_ncn_cv_AS_FOR_TARGET="as"
+fi
+fi
+ncn_cv_AS_FOR_TARGET="$ac_cv_prog_ncn_cv_AS_FOR_TARGET"
+if test -n "$ncn_cv_AS_FOR_TARGET"; then
+ echo "$ac_t""$ncn_cv_AS_FOR_TARGET" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ AS_FOR_TARGET=$ncn_cv_AS_FOR_TARGET
+ else
+ AS_FOR_TARGET="${ncn_target_tool_prefix}as"
+ fi
+else
+ AS_FOR_TARGET="$ac_cv_prog_AS_FOR_TARGET"
+fi
+
+ if test -n "$ncn_target_tool_prefix"; then
+ # Extract the first word of "${ncn_target_tool_prefix}dlltool", so it can be a program name with args.
+set dummy ${ncn_target_tool_prefix}dlltool; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3657: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_DLLTOOL_FOR_TARGET'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$DLLTOOL_FOR_TARGET"; then
+ ac_cv_prog_DLLTOOL_FOR_TARGET="$DLLTOOL_FOR_TARGET" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_DLLTOOL_FOR_TARGET="${ncn_target_tool_prefix}dlltool"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+DLLTOOL_FOR_TARGET="$ac_cv_prog_DLLTOOL_FOR_TARGET"
+if test -n "$DLLTOOL_FOR_TARGET"; then
+ echo "$ac_t""$DLLTOOL_FOR_TARGET" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+fi
+if test -z "$ac_cv_prog_DLLTOOL_FOR_TARGET" ; then
+ if test $build = $target ; then
+ ncn_cv_DLLTOOL_FOR_TARGET=$DLLTOOL_FOR_TARGET
+ # Extract the first word of "dlltool", so it can be a program name with args.
+set dummy dlltool; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3690: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_DLLTOOL_FOR_TARGET'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$ncn_cv_DLLTOOL_FOR_TARGET"; then
+ ac_cv_prog_ncn_cv_DLLTOOL_FOR_TARGET="$ncn_cv_DLLTOOL_FOR_TARGET" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_ncn_cv_DLLTOOL_FOR_TARGET="dlltool"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+ test -z "$ac_cv_prog_ncn_cv_DLLTOOL_FOR_TARGET" && ac_cv_prog_ncn_cv_DLLTOOL_FOR_TARGET="dlltool"
+fi
+fi
+ncn_cv_DLLTOOL_FOR_TARGET="$ac_cv_prog_ncn_cv_DLLTOOL_FOR_TARGET"
+if test -n "$ncn_cv_DLLTOOL_FOR_TARGET"; then
+ echo "$ac_t""$ncn_cv_DLLTOOL_FOR_TARGET" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ DLLTOOL_FOR_TARGET=$ncn_cv_DLLTOOL_FOR_TARGET
+ else
+ DLLTOOL_FOR_TARGET="${ncn_target_tool_prefix}dlltool"
+ fi
+else
+ DLLTOOL_FOR_TARGET="$ac_cv_prog_DLLTOOL_FOR_TARGET"
+fi
+
+ if test -n "$ncn_target_tool_prefix"; then
+ # Extract the first word of "${ncn_target_tool_prefix}ld", so it can be a program name with args.
+set dummy ${ncn_target_tool_prefix}ld; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3729: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_LD_FOR_TARGET'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$LD_FOR_TARGET"; then
+ ac_cv_prog_LD_FOR_TARGET="$LD_FOR_TARGET" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_LD_FOR_TARGET="${ncn_target_tool_prefix}ld"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+LD_FOR_TARGET="$ac_cv_prog_LD_FOR_TARGET"
+if test -n "$LD_FOR_TARGET"; then
+ echo "$ac_t""$LD_FOR_TARGET" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+fi
+if test -z "$ac_cv_prog_LD_FOR_TARGET" ; then
+ if test $build = $target ; then
+ ncn_cv_LD_FOR_TARGET=$LD_FOR_TARGET
+ # Extract the first word of "ld", so it can be a program name with args.
+set dummy ld; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3762: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_LD_FOR_TARGET'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$ncn_cv_LD_FOR_TARGET"; then
+ ac_cv_prog_ncn_cv_LD_FOR_TARGET="$ncn_cv_LD_FOR_TARGET" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_ncn_cv_LD_FOR_TARGET="ld"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+ test -z "$ac_cv_prog_ncn_cv_LD_FOR_TARGET" && ac_cv_prog_ncn_cv_LD_FOR_TARGET="ld"
+fi
+fi
+ncn_cv_LD_FOR_TARGET="$ac_cv_prog_ncn_cv_LD_FOR_TARGET"
+if test -n "$ncn_cv_LD_FOR_TARGET"; then
+ echo "$ac_t""$ncn_cv_LD_FOR_TARGET" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ LD_FOR_TARGET=$ncn_cv_LD_FOR_TARGET
+ else
+ LD_FOR_TARGET="${ncn_target_tool_prefix}ld"
+ fi
+else
+ LD_FOR_TARGET="$ac_cv_prog_LD_FOR_TARGET"
+fi
+
+ if test -n "$ncn_target_tool_prefix"; then
+ # Extract the first word of "${ncn_target_tool_prefix}nm", so it can be a program name with args.
+set dummy ${ncn_target_tool_prefix}nm; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3801: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_NM_FOR_TARGET'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$NM_FOR_TARGET"; then
+ ac_cv_prog_NM_FOR_TARGET="$NM_FOR_TARGET" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_NM_FOR_TARGET="${ncn_target_tool_prefix}nm"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+NM_FOR_TARGET="$ac_cv_prog_NM_FOR_TARGET"
+if test -n "$NM_FOR_TARGET"; then
+ echo "$ac_t""$NM_FOR_TARGET" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+fi
+if test -z "$ac_cv_prog_NM_FOR_TARGET" ; then
+ if test $build = $target ; then
+ ncn_cv_NM_FOR_TARGET=$NM_FOR_TARGET
+ # Extract the first word of "nm", so it can be a program name with args.
+set dummy nm; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3834: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_NM_FOR_TARGET'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$ncn_cv_NM_FOR_TARGET"; then
+ ac_cv_prog_ncn_cv_NM_FOR_TARGET="$ncn_cv_NM_FOR_TARGET" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_ncn_cv_NM_FOR_TARGET="nm"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+ test -z "$ac_cv_prog_ncn_cv_NM_FOR_TARGET" && ac_cv_prog_ncn_cv_NM_FOR_TARGET="nm"
+fi
+fi
+ncn_cv_NM_FOR_TARGET="$ac_cv_prog_ncn_cv_NM_FOR_TARGET"
+if test -n "$ncn_cv_NM_FOR_TARGET"; then
+ echo "$ac_t""$ncn_cv_NM_FOR_TARGET" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ NM_FOR_TARGET=$ncn_cv_NM_FOR_TARGET
+ else
+ NM_FOR_TARGET="${ncn_target_tool_prefix}nm"
+ fi
+else
+ NM_FOR_TARGET="$ac_cv_prog_NM_FOR_TARGET"
+fi
+
+ if test -n "$ncn_target_tool_prefix"; then
+ # Extract the first word of "${ncn_target_tool_prefix}ranlib", so it can be a program name with args.
+set dummy ${ncn_target_tool_prefix}ranlib; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3873: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_RANLIB_FOR_TARGET'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$RANLIB_FOR_TARGET"; then
+ ac_cv_prog_RANLIB_FOR_TARGET="$RANLIB_FOR_TARGET" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_RANLIB_FOR_TARGET="${ncn_target_tool_prefix}ranlib"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+RANLIB_FOR_TARGET="$ac_cv_prog_RANLIB_FOR_TARGET"
+if test -n "$RANLIB_FOR_TARGET"; then
+ echo "$ac_t""$RANLIB_FOR_TARGET" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+fi
+if test -z "$ac_cv_prog_RANLIB_FOR_TARGET" ; then
+ if test $build = $target ; then
+ ncn_cv_RANLIB_FOR_TARGET=$RANLIB_FOR_TARGET
+ # Extract the first word of "ranlib", so it can be a program name with args.
+set dummy ranlib; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3906: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_RANLIB_FOR_TARGET'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$ncn_cv_RANLIB_FOR_TARGET"; then
+ ac_cv_prog_ncn_cv_RANLIB_FOR_TARGET="$ncn_cv_RANLIB_FOR_TARGET" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_ncn_cv_RANLIB_FOR_TARGET="ranlib"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+ test -z "$ac_cv_prog_ncn_cv_RANLIB_FOR_TARGET" && ac_cv_prog_ncn_cv_RANLIB_FOR_TARGET=":"
+fi
+fi
+ncn_cv_RANLIB_FOR_TARGET="$ac_cv_prog_ncn_cv_RANLIB_FOR_TARGET"
+if test -n "$ncn_cv_RANLIB_FOR_TARGET"; then
+ echo "$ac_t""$ncn_cv_RANLIB_FOR_TARGET" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ RANLIB_FOR_TARGET=$ncn_cv_RANLIB_FOR_TARGET
+ else
+ RANLIB_FOR_TARGET=":"
+ fi
+else
+ RANLIB_FOR_TARGET="$ac_cv_prog_RANLIB_FOR_TARGET"
+fi
+
+ if test -n "$ncn_target_tool_prefix"; then
+ # Extract the first word of "${ncn_target_tool_prefix}windres", so it can be a program name with args.
+set dummy ${ncn_target_tool_prefix}windres; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3945: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_WINDRES_FOR_TARGET'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$WINDRES_FOR_TARGET"; then
+ ac_cv_prog_WINDRES_FOR_TARGET="$WINDRES_FOR_TARGET" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_WINDRES_FOR_TARGET="${ncn_target_tool_prefix}windres"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+WINDRES_FOR_TARGET="$ac_cv_prog_WINDRES_FOR_TARGET"
+if test -n "$WINDRES_FOR_TARGET"; then
+ echo "$ac_t""$WINDRES_FOR_TARGET" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+fi
+if test -z "$ac_cv_prog_WINDRES_FOR_TARGET" ; then
+ if test $build = $target ; then
+ ncn_cv_WINDRES_FOR_TARGET=$WINDRES_FOR_TARGET
+ # Extract the first word of "windres", so it can be a program name with args.
+set dummy windres; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:3978: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_ncn_cv_WINDRES_FOR_TARGET'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$ncn_cv_WINDRES_FOR_TARGET"; then
+ ac_cv_prog_ncn_cv_WINDRES_FOR_TARGET="$ncn_cv_WINDRES_FOR_TARGET" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_ncn_cv_WINDRES_FOR_TARGET="windres"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+ test -z "$ac_cv_prog_ncn_cv_WINDRES_FOR_TARGET" && ac_cv_prog_ncn_cv_WINDRES_FOR_TARGET="windres"
+fi
+fi
+ncn_cv_WINDRES_FOR_TARGET="$ac_cv_prog_ncn_cv_WINDRES_FOR_TARGET"
+if test -n "$ncn_cv_WINDRES_FOR_TARGET"; then
+ echo "$ac_t""$ncn_cv_WINDRES_FOR_TARGET" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ WINDRES_FOR_TARGET=$ncn_cv_WINDRES_FOR_TARGET
+ else
+ WINDRES_FOR_TARGET="${ncn_target_tool_prefix}windres"
+ fi
+else
+ WINDRES_FOR_TARGET="$ac_cv_prog_WINDRES_FOR_TARGET"
+fi
+
+
+
+
+
+
+
+
+
+
+
+# Fix up target tools.
+if test "x${build}" = "x${host}" ; then
+ # In this case, the newly built tools can and should be used,
+ # so we override the results of the autoconf tests.
+ # This should really only happen when the tools are actually being built,
+ # but that's a further refinement. The new build scheme, where
+ # tools are built into a structure paralleling where they're installed,
+ # should also eliminate all of this cleanly.
+ AR_FOR_TARGET="\$(USUAL_AR_FOR_TARGET)"
+ AS_FOR_TARGET="\$(USUAL_AS_FOR_TARGET)"
+ DLLTOOL_FOR_TARGET="\$(USUAL_DLLTOOL_FOR_TARGET)"
+ LD_FOR_TARGET="\$(USUAL_LD_FOR_TARGET)"
+ NM_FOR_TARGET="\$(USUAL_NM_FOR_TARGET)"
+ RANLIB_FOR_TARGET="\$(USUAL_RANLIB_FOR_TARGET)"
+ WINDRES_FOR_TARGET="\$(USUAL_WINDRES_FOR_TARGET)"
+fi
+# Certain tools may need extra flags.
+AR_FOR_TARGET=${AR_FOR_TARGET}${extra_arflags_for_target}
+RANLIB_FOR_TARGET=${RANLIB_FOR_TARGET}${extra_ranlibflags_for_target}
+NM_FOR_TARGET=${NM_FOR_TARGET}${extra_nmflags_for_target}
+
+echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
+echo "configure:4045: checking whether to enable maintainer-specific portions of Makefiles" >&5
+# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
+if test "${enable_maintainer_mode+set}" = set; then
+ enableval="$enable_maintainer_mode"
+ USE_MAINTAINER_MODE=$enableval
+else
+ USE_MAINTAINER_MODE=no
+fi
+
+echo "$ac_t""$USE_MAINTAINER_MODE" 1>&6
+
+
+if test "$USE_MAINTAINER_MODE" = yes; then
+ MAINTAINER_MODE_TRUE=
+ MAINTAINER_MODE_FALSE='#'
+else
+ MAINTAINER_MODE_TRUE='#'
+ MAINTAINER_MODE_FALSE=
+fi
+MAINT=$MAINTAINER_MODE_TRUE
+
+trap '' 1 2 15
+cat > confcache <<\EOF
+# This file is a shell script that caches the results of configure
+# tests run on this system so they can be shared between configure
+# scripts and configure runs. It is not useful on other systems.
+# If it contains results you don't want to keep, you may remove or edit it.
#
-# Local Variables:
-# fill-column: 131
-# End:
+# By default, configure uses ./config.cache as the cache file,
+# creating it if it does not exist already. You can give configure
+# the --cache-file=FILE option to use a different cache file; that is
+# what configure does when it calls configure scripts in
+# subdirectories, so they share the cache.
+# Giving --cache-file=/dev/null disables caching, for debugging configure.
+# config.status only pays attention to the cache file if you give it the
+# --recheck option to rerun configure.
#
+EOF
+# The following way of writing the cache mishandles newlines in values,
+# but we know of no workaround that is simple, portable, and efficient.
+# So, don't put newlines in cache variables' values.
+# Ultrix sh set writes to stderr and can't be redirected directly,
+# and sets the high bit in the cache file unless we assign to the vars.
+(set) 2>&1 |
+ case `(ac_space=' '; set | grep ac_space) 2>&1` in
+ *ac_space=\ *)
+ # `set' does not quote correctly, so add quotes (double-quote substitution
+ # turns \\\\ into \\, and sed turns \\ into \).
+ sed -n \
+ -e "s/'/'\\\\''/g" \
+ -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
+ ;;
+ *)
+ # `set' quotes correctly as required by POSIX, so do not add quotes.
+ sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
+ ;;
+ esac >> confcache
+if cmp -s $cache_file confcache; then
+ :
+else
+ if test -w $cache_file; then
+ echo "updating cache $cache_file"
+ cat confcache > $cache_file
+ else
+ echo "not updating unwritable cache $cache_file"
+ fi
+fi
+rm -f confcache
+
+trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
+
+test "x$prefix" = xNONE && prefix=$ac_default_prefix
+# Let make expand exec_prefix.
+test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
+
+# Any assignment to VPATH causes Sun make to only execute
+# the first set of double-colon rules, so remove it if not needed.
+# If there is a colon in the path, we need to keep it.
+if test "x$srcdir" = x.; then
+ ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
+fi
+
+trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
+
+# Transform confdefs.h into DEFS.
+# Protect against shell expansion while executing Makefile rules.
+# Protect against Makefile macro expansion.
+cat > conftest.defs <<\EOF
+s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%-D\1=\2%g
+s%[ `~#$^&*(){}\\|;'"<>?]%\\&%g
+s%\[%\\&%g
+s%\]%\\&%g
+s%\$%$$%g
+EOF
+DEFS=`sed -f conftest.defs confdefs.h | tr '\012' ' '`
+rm -f conftest.defs
+
+
+# Without the "./", some shells look in PATH for config.status.
+: ${CONFIG_STATUS=./config.status}
+
+echo creating $CONFIG_STATUS
+rm -f $CONFIG_STATUS
+cat > $CONFIG_STATUS <<EOF
+#! /bin/sh
+# Generated automatically by configure.
+# Run this file to recreate the current configuration.
+# This directory was configured as follows,
+# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
+#
+# $0 $ac_configure_args
+#
+# Compiler output produced by configure, useful for debugging
+# configure, is in ./config.log if it exists.
+
+ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
+for ac_option
+do
+ case "\$ac_option" in
+ -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
+ echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
+ exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
+ -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
+ echo "$CONFIG_STATUS generated by autoconf version 2.13"
+ exit 0 ;;
+ -help | --help | --hel | --he | --h)
+ echo "\$ac_cs_usage"; exit 0 ;;
+ *) echo "\$ac_cs_usage"; exit 1 ;;
+ esac
+done
+
+ac_given_srcdir=$srcdir
+ac_given_INSTALL="$INSTALL"
+
+trap 'rm -fr `echo "Makefile" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
+EOF
+cat >> $CONFIG_STATUS <<EOF
+
+# Protect against being on the right side of a sed subst in config.status.
+sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
+ s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
+$ac_vpsub
+$extrasub
+s%@SHELL@%$SHELL%g
+s%@CFLAGS@%$CFLAGS%g
+s%@CPPFLAGS@%$CPPFLAGS%g
+s%@CXXFLAGS@%$CXXFLAGS%g
+s%@FFLAGS@%$FFLAGS%g
+s%@DEFS@%$DEFS%g
+s%@LDFLAGS@%$LDFLAGS%g
+s%@LIBS@%$LIBS%g
+s%@exec_prefix@%$exec_prefix%g
+s%@prefix@%$prefix%g
+s%@program_transform_name@%$program_transform_name%g
+s%@bindir@%$bindir%g
+s%@sbindir@%$sbindir%g
+s%@libexecdir@%$libexecdir%g
+s%@datadir@%$datadir%g
+s%@sysconfdir@%$sysconfdir%g
+s%@sharedstatedir@%$sharedstatedir%g
+s%@localstatedir@%$localstatedir%g
+s%@libdir@%$libdir%g
+s%@includedir@%$includedir%g
+s%@oldincludedir@%$oldincludedir%g
+s%@infodir@%$infodir%g
+s%@mandir@%$mandir%g
+s%@host@%$host%g
+s%@host_alias@%$host_alias%g
+s%@host_cpu@%$host_cpu%g
+s%@host_vendor@%$host_vendor%g
+s%@host_os@%$host_os%g
+s%@target@%$target%g
+s%@target_alias@%$target_alias%g
+s%@target_cpu@%$target_cpu%g
+s%@target_vendor@%$target_vendor%g
+s%@target_os@%$target_os%g
+s%@build@%$build%g
+s%@build_alias@%$build_alias%g
+s%@build_cpu@%$build_cpu%g
+s%@build_vendor@%$build_vendor%g
+s%@build_os@%$build_os%g
+s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
+s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
+s%@INSTALL_DATA@%$INSTALL_DATA%g
+s%@TOPLEVEL_CONFIGURE_ARGUMENTS@%$TOPLEVEL_CONFIGURE_ARGUMENTS%g
+s%@build_subdir@%$build_subdir%g
+s%@host_subdir@%$host_subdir%g
+s%@target_subdir@%$target_subdir%g
+/@maybe_dependencies@/r $maybe_dependencies
+s%@maybe_dependencies@%%g
+/@serialization_dependencies@/r $serialization_dependencies
+s%@serialization_dependencies@%%g
+/@host_makefile_frag@/r $host_makefile_frag
+s%@host_makefile_frag@%%g
+/@target_makefile_frag@/r $target_makefile_frag
+s%@target_makefile_frag@%%g
+/@alphaieee_frag@/r $alphaieee_frag
+s%@alphaieee_frag@%%g
+/@ospace_frag@/r $ospace_frag
+s%@ospace_frag@%%g
+s%@SET_LIB_PATH@%$SET_LIB_PATH%g
+s%@RPATH_ENVVAR@%$RPATH_ENVVAR%g
+s%@BUILD_PREFIX@%$BUILD_PREFIX%g
+s%@BUILD_PREFIX_1@%$BUILD_PREFIX_1%g
+s%@configlinks@%$configlinks%g
+s%@gcc_version_trigger@%$gcc_version_trigger%g
+s%@gcc_version@%$gcc_version%g
+s%@tooldir@%$tooldir%g
+s%@build_tooldir@%$build_tooldir%g
+s%@GDB_TK@%$GDB_TK%g
+s%@gxx_include_dir@%$gxx_include_dir%g
+s%@libstdcxx_incdir@%$libstdcxx_incdir%g
+s%@build_configargs@%$build_configargs%g
+s%@configure_build_modules@%$configure_build_modules%g
+s%@all_build_modules@%$all_build_modules%g
+s%@host_configargs@%$host_configargs%g
+s%@configdirs@%$configdirs%g
+s%@target_configargs@%$target_configargs%g
+s%@target_configdirs@%$target_configdirs%g
+s%@BISON@%$BISON%g
+s%@CC_FOR_BUILD@%$CC_FOR_BUILD%g
+s%@LEX@%$LEX%g
+s%@MAKEINFO@%$MAKEINFO%g
+s%@YACC@%$YACC%g
+s%@config_shell@%$config_shell%g
+s%@AR@%$AR%g
+s%@ncn_cv_AR@%$ncn_cv_AR%g
+s%@AS@%$AS%g
+s%@ncn_cv_AS@%$ncn_cv_AS%g
+s%@DLLTOOL@%$DLLTOOL%g
+s%@ncn_cv_DLLTOOL@%$ncn_cv_DLLTOOL%g
+s%@LD@%$LD%g
+s%@ncn_cv_LD@%$ncn_cv_LD%g
+s%@NM@%$NM%g
+s%@ncn_cv_NM@%$ncn_cv_NM%g
+s%@RANLIB@%$RANLIB%g
+s%@ncn_cv_RANLIB@%$ncn_cv_RANLIB%g
+s%@WINDRES@%$WINDRES%g
+s%@ncn_cv_WINDRES@%$ncn_cv_WINDRES%g
+s%@OBJCOPY@%$OBJCOPY%g
+s%@ncn_cv_OBJCOPY@%$ncn_cv_OBJCOPY%g
+s%@OBJDUMP@%$OBJDUMP%g
+s%@ncn_cv_OBJDUMP@%$ncn_cv_OBJDUMP%g
+s%@CC@%$CC%g
+s%@CXX@%$CXX%g
+s%@CFLAGS_FOR_BUILD@%$CFLAGS_FOR_BUILD%g
+s%@DEFAULT_YACC@%$DEFAULT_YACC%g
+s%@DEFAULT_LEX@%$DEFAULT_LEX%g
+s%@DEFAULT_M4@%$DEFAULT_M4%g
+s%@AR_FOR_TARGET@%$AR_FOR_TARGET%g
+s%@ncn_cv_AR_FOR_TARGET@%$ncn_cv_AR_FOR_TARGET%g
+s%@AS_FOR_TARGET@%$AS_FOR_TARGET%g
+s%@ncn_cv_AS_FOR_TARGET@%$ncn_cv_AS_FOR_TARGET%g
+s%@DLLTOOL_FOR_TARGET@%$DLLTOOL_FOR_TARGET%g
+s%@ncn_cv_DLLTOOL_FOR_TARGET@%$ncn_cv_DLLTOOL_FOR_TARGET%g
+s%@LD_FOR_TARGET@%$LD_FOR_TARGET%g
+s%@ncn_cv_LD_FOR_TARGET@%$ncn_cv_LD_FOR_TARGET%g
+s%@NM_FOR_TARGET@%$NM_FOR_TARGET%g
+s%@ncn_cv_NM_FOR_TARGET@%$ncn_cv_NM_FOR_TARGET%g
+s%@RANLIB_FOR_TARGET@%$RANLIB_FOR_TARGET%g
+s%@ncn_cv_RANLIB_FOR_TARGET@%$ncn_cv_RANLIB_FOR_TARGET%g
+s%@WINDRES_FOR_TARGET@%$WINDRES_FOR_TARGET%g
+s%@ncn_cv_WINDRES_FOR_TARGET@%$ncn_cv_WINDRES_FOR_TARGET%g
+s%@GCC_FOR_TARGET@%$GCC_FOR_TARGET%g
+s%@FLAGS_FOR_TARGET@%$FLAGS_FOR_TARGET%g
+s%@CC_FOR_TARGET@%$CC_FOR_TARGET%g
+s%@GCJ_FOR_TARGET@%$GCJ_FOR_TARGET%g
+s%@CXX_FOR_TARGET@%$CXX_FOR_TARGET%g
+s%@RAW_CXX_FOR_TARGET@%$RAW_CXX_FOR_TARGET%g
+s%@CXX_FOR_TARGET_FOR_RECURSIVE_MAKE@%$CXX_FOR_TARGET_FOR_RECURSIVE_MAKE%g
+s%@RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE@%$RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE%g
+s%@MAINTAINER_MODE_TRUE@%$MAINTAINER_MODE_TRUE%g
+s%@MAINTAINER_MODE_FALSE@%$MAINTAINER_MODE_FALSE%g
+s%@MAINT@%$MAINT%g
+
+CEOF
+EOF
+
+cat >> $CONFIG_STATUS <<\EOF
+
+# Split the substitutions into bite-sized pieces for seds with
+# small command number limits, like on Digital OSF/1 and HP-UX.
+ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
+ac_file=1 # Number of current file.
+ac_beg=1 # First line for current file.
+ac_end=$ac_max_sed_cmds # Line after last line for current file.
+ac_more_lines=:
+ac_sed_cmds=""
+while $ac_more_lines; do
+ if test $ac_beg -gt 1; then
+ sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
+ else
+ sed "${ac_end}q" conftest.subs > conftest.s$ac_file
+ fi
+ if test ! -s conftest.s$ac_file; then
+ ac_more_lines=false
+ rm -f conftest.s$ac_file
+ else
+ if test -z "$ac_sed_cmds"; then
+ ac_sed_cmds="sed -f conftest.s$ac_file"
+ else
+ ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
+ fi
+ ac_file=`expr $ac_file + 1`
+ ac_beg=$ac_end
+ ac_end=`expr $ac_end + $ac_max_sed_cmds`
+ fi
+done
+if test -z "$ac_sed_cmds"; then
+ ac_sed_cmds=cat
+fi
+EOF
+
+cat >> $CONFIG_STATUS <<EOF
+
+CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
+EOF
+cat >> $CONFIG_STATUS <<\EOF
+for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
+ # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
+ case "$ac_file" in
+ *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
+ ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
+ *) ac_file_in="${ac_file}.in" ;;
+ esac
+
+ # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
+
+ # Remove last slash and all that follows it. Not all systems have dirname.
+ ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
+ if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
+ # The file is in a subdirectory.
+ test ! -d "$ac_dir" && mkdir "$ac_dir"
+ ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
+ # A "../" for each directory in $ac_dir_suffix.
+ ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
+ else
+ ac_dir_suffix= ac_dots=
+ fi
+
+ case "$ac_given_srcdir" in
+ .) srcdir=.
+ if test -z "$ac_dots"; then top_srcdir=.
+ else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
+ /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
+ *) # Relative path.
+ srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
+ top_srcdir="$ac_dots$ac_given_srcdir" ;;
+ esac
+
+ case "$ac_given_INSTALL" in
+ [/$]*) INSTALL="$ac_given_INSTALL" ;;
+ *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
+ esac
+
+ echo creating "$ac_file"
+ rm -f "$ac_file"
+ configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
+ case "$ac_file" in
+ *Makefile*) ac_comsub="1i\\
+# $configure_input" ;;
+ *) ac_comsub= ;;
+ esac
+
+ ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
+ sed -e "$ac_comsub
+s%@configure_input@%$configure_input%g
+s%@srcdir@%$srcdir%g
+s%@top_srcdir@%$top_srcdir%g
+s%@INSTALL@%$INSTALL%g
+" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
+fi; done
+rm -f conftest.s*
+
+EOF
+cat >> $CONFIG_STATUS <<EOF
+
+EOF
+cat >> $CONFIG_STATUS <<\EOF
+
+exit 0
+EOF
+chmod +x $CONFIG_STATUS
+rm -fr confdefs* $ac_clean_files
+test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
-# end of configure
diff --git a/contrib/binutils/configure.in b/contrib/binutils/configure.in
index ed4f7a7..3355f0e 100644
--- a/contrib/binutils/configure.in
+++ b/contrib/binutils/configure.in
@@ -1,21 +1,5 @@
-#! /bin/bash
-##############################################################################
-
-## This file is a shell script fragment that supplies the information
-## necessary to tailor a template configure script into the configure
-## script appropriate for this directory. For more information, check
-## any existing configure script.
-
-## Be warned, there are two types of configure.in files. There are those
-## used by Autoconf, which are macros which are expanded into a configure
-## script by autoconf. The other sort, of which this is one, is executed
-## by Cygnus configure.
-
-## For more information on these two systems, check out the documentation
-## for 'Autoconf' (autoconf.texi) and 'Configure' (configure.texi).
-
# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998,
-# 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+# 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
#
# This file is free software; you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by
@@ -32,24 +16,124 @@
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
##############################################################################
+### WARNING: this file contains embedded tabs. Do not run untabify on this file.
+
+AC_INIT(move-if-change)
+AC_PREREQ(2.13)
+AC_CANONICAL_SYSTEM
+AC_ARG_PROGRAM
+
+# Get 'install' or 'install-sh' and its variants.
+AC_PROG_INSTALL
+
+sinclude(config/acx.m4)
+
+### we might need to use some other shell than /bin/sh for running subshells
+### If we are on Windows, search for the shell. This will permit people
+### to not have /bin/sh, but to be able to see /SOME/PATH/sh configure
+### without also having to set CONFIG_SHELL. This code will work when
+### using bash, which sets OSTYPE.
+case "${OSTYPE}" in
+*win32*)
+ if test x${CONFIG_SHELL} = x ; then
+ if test ! -f /bin/sh ; then
+ if test x${SHELL} != x && test -f ${SHELL} ; then
+ CONFIG_SHELL=${SHELL}
+ export CONFIG_SHELL
+ else
+ for prog in sh sh.exe bash bash.exe; do
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
+ for dir in $PATH; do
+ test -z "$dir" && dir=.
+ if test -f $dir/$prog; then
+ CONFIG_SHELL=$dir/$prog
+ export CONFIG_SHELL
+ break
+ fi
+ done
+ IFS="$save_ifs"
+ test -n "${CONFIG_SHELL}" && break
+ done
+ fi
+ fi
+ fi
+ ;;
+esac
+
+config_shell=${CONFIG_SHELL-/bin/sh}
+
+progname=$0
+# if PWD already has a value, it is probably wrong.
+if test -n "$PWD" ; then PWD=`${PWDCMD-pwd}`; fi
+
+# Export original configure arguments for use by sub-configures. These
+# will be expanded by make, so quote '$'.
+tmp="$progname $@"
+sed -e 's,\$,$$,g' <<EOF_SED > conftestsed.out
+$tmp
+EOF_SED
+TOPLEVEL_CONFIGURE_ARGUMENTS=`cat conftestsed.out`
+rm -f conftestsed.out
+AC_SUBST(TOPLEVEL_CONFIGURE_ARGUMENTS)
+
+moveifchange=${srcdir}/move-if-change
+
+# Set srcdir to "." if that's what it is.
+# This is important for multilib support.
+pwd=`${PWDCMD-pwd}`
+srcpwd=`cd ${srcdir} ; ${PWDCMD-pwd}`
+if test "${pwd}" = "${srcpwd}" ; then
+ srcdir=.
+fi
+
+topsrcdir=$srcpwd
+
+extra_host_args=
+# Define the trigger file to make sure configure will re-run whenever
+# the gcc version number changes.
+if test "${with_gcc_version_trigger+set}" = set ; then
+ gcc_version_trigger="$with_gcc_version_trigger"
+ gcc_version=`grep version_string ${with_gcc_version_trigger} | sed -e 's/.*\"\([[^ \"]]*\)[[ \"]].*/\1/'`
+else
+ # If gcc's sources are available, define the trigger file.
+ if test -f ${topsrcdir}/gcc/version.c ; then
+ gcc_version_trigger=${topsrcdir}/gcc/version.c
+ gcc_version=`grep version_string ${gcc_version_trigger} | sed -e 's/.*\"\([[^ \"]]*\)[[ \"]].*/\1/'`
+ case "$ac_configure_args" in
+ *--with-gcc-version-trigger=$gcc_version_trigger* )
+ ;;
+ * )
+ # Add to all subconfigure arguments: build, host, and target.
+ ac_configure_args="$ac_configure_args --with-gcc-version-trigger=$gcc_version_trigger"
+ ;;
+ esac
+ fi
+fi
### To add a new directory to the tree, first choose whether it is a target
### or a host dependent tool. Then put it into the appropriate list
-### (library or tools, host or target), doing a dependency sort. For
-### example, gdb requires that byacc (or bison) be built first, so it is in
-### the ${host_tools} list after byacc and bison.
+### (library or tools, host or target), doing a dependency sort.
+
+# Subdirs will be configured in the order listed in build_configdirs,
+# configdirs, or target_configdirs; see the serialization section below.
+
+# Dependency sorting is only needed when *configuration* must be done in
+# a particular order. In all cases a dependency should be specified in
+# the Makefile, whether or not it's implicitly specified here.
+# Double entries in build_configdirs, configdirs, or target_configdirs may
+# cause circular dependencies and break everything horribly.
# these libraries are used by various programs built for the host environment
#
-host_libs="intl mmalloc libiberty opcodes bfd readline db tcl tk tclX itcl tix libgui zlib"
-
-libstdcxx_version="target-libstdc++-v3"
+host_libs="intl mmalloc libiberty opcodes bfd readline tcl tk itcl tix libgui zlib"
# these tools are built for the host environment
# Note, the powerpc-eabi build depends on sim occurring before gdb in order to
# know that we are building the simulator.
-host_tools="texinfo byacc flex bison binutils ld gas gcc sid sim gdb make patch prms send-pr gprof etc expect dejagnu ash bash bzip2 m4 autoconf automake libtool grep diff rcs fileutils shellutils time textutils wdiff find uudecode hello tar gzip indent recode release sed utils guile perl gawk findutils snavigator libtool gettext zip fastjar"
+# binutils, gas and ld appear in that order because it makes sense to run
+# "make check" in that particular order.
+host_tools="texinfo byacc flex bison binutils gas ld gcc sid sim gdb make patch prms send-pr gprof etc expect dejagnu ash bash bzip2 m4 autoconf automake libtool diff rcs fileutils shellutils time textutils wdiff find uudecode hello tar gzip indent recode release sed utils guile perl gawk findutils gettext zip fastjar"
# libgcj represents the runtime libraries only used by gcj.
libgcj="target-libffi \
@@ -61,41 +145,26 @@ libgcj="target-libffi \
# these libraries are built for the target environment, and are built after
# the host libraries and the host tools (which may be a cross compiler)
#
-target_libs="target-libiberty \
+target_libraries="target-libiberty \
target-libgloss \
target-newlib \
- ${libstdcxx_version} \
+ target-libstdc++-v3 \
target-libf2c \
- ${libgcj}
- target-libobjc"
+ ${libgcj} \
+ target-libobjc \
+ target-libada"
-# these tools are built using the target libs, and are intended to run only
-# in the target environment
+# these tools are built using the target libraries, and are intended to
+# run only in the target environment
#
-# note: any program that *uses* libraries that are in the "target_libs"
+# note: any program that *uses* libraries that are in the "target_libraries"
# list belongs in this list. those programs are also very likely
# candidates for the "native_only" list which follows
#
-target_tools="target-examples target-groff target-gperf"
+target_tools="target-examples target-groff target-gperf target-rda"
################################################################################
-## These two lists are of directories that are to be removed from the
-## ${configdirs} list for either cross-compilations or for native-
-## compilations. For example, it doesn't make that much sense to
-## cross-compile Emacs, nor is it terribly useful to compile target-libiberty in
-## a native environment.
-
-# directories to be built in the native environment only
-#
-# This must be a single line because of the way it is searched by grep in
-# the code below.
-native_only="autoconf automake libtool fileutils find gawk gettext grep gzip hello indent m4 rcs recode sed shellutils tar textutils uudecode wdiff gprof target-groff guile perl time ash bash bzip2 prms snavigator gnuserv target-gperf"
-
-# directories to be built in a cross environment only
-#
-cross_only="target-libgloss target-newlib target-opcodes"
-
## All tools belong in one of the four categories, and are assigned above
## We assign ${configdirs} this way to remove all embedded newlines. This
## is important because configure will choke if they ever get through.
@@ -103,22 +172,25 @@ cross_only="target-libgloss target-newlib target-opcodes"
## ${target_configdirs} is directories we build using the target tools.
#
configdirs=`echo ${host_libs} ${host_tools}`
-target_configdirs=`echo ${target_libs} ${target_tools}`
+target_configdirs=`echo ${target_libraries} ${target_tools}`
+
+# Only make build modules if build != host.
+# This should be done more generally, but at the moment it doesn't matter.
+if test ${host_alias} != ${build_alias} ; then
+ # This is the only build module.
+ build_modules=libiberty
+else
+ build_modules=
+fi
+
################################################################################
-srctrigger=move-if-change
srcname="gnu development package"
# This gets set non-empty for some net releases of packages.
appdirs=""
-# per-host:
-
-# There is no longer anything interesting in the per-host section.
-
-# per-target:
-
# Define is_cross_compiler to save on calls to 'test'.
is_cross_compiler=
if test x"${host}" = x"${target}" ; then
@@ -127,29 +199,8 @@ else
is_cross_compiler=yes
fi
-# We always want to use the same name for this directory, so that dejagnu
-# can reliably find it.
-target_subdir=${target_alias}
-
-if test ! -d ${target_subdir} ; then
- if mkdir ${target_subdir} ; then true
- else
- echo "'*** could not make ${PWD=`${PWDCMD-pwd}`}/${target_subdir}" 1>&2
- exit 1
- fi
-fi
-
-build_subdir=${build_alias}
-
-if test x"${build_alias}" != x"${host}" ; then
- if test ! -d ${build_subdir} ; then
- if mkdir ${build_subdir} ; then true
- else
- echo "'*** could not make ${PWD=`${PWDCMD-pwd}`}/${build_subdir}" 1>&2
- exit 1
- fi
- fi
-fi
+# Find the build and target subdir names.
+GCC_TOPLEV_SUBDIRS
# Skipdirs are removed silently.
skipdirs=
@@ -184,8 +235,12 @@ case ${with_x} in
esac
# Some tools are only suitable for building in a "native" situation.
-# Remove these if host!=target. Similarly, some are only suitable
-# for cross toolchains; remove if host=target.
+# Remove these if host!=target.
+native_only="autoconf automake libtool fileutils find gawk gettext gzip hello indent m4 rcs recode sed shellutils tar textutils uudecode wdiff gprof target-groff guile perl time ash bash bzip2 prms gnuserv target-gperf"
+
+# Similarly, some are only suitable for cross toolchains.
+# Remove these if host=target.
+cross_only="target-libgloss target-newlib target-opcodes"
case $is_cross_compiler in
no) skipdirs="${skipdirs} ${cross_only}" ;;
@@ -194,7 +249,8 @@ esac
# If both --with-headers and --with-libs are specified, default to
# --without-newlib.
-if test x"${with_headers}" != x && test x"${with_libs}" != x ; then
+if test x"${with_headers}" != x && test x"${with_headers} != xno \
+ && test x"${with_libs}" != x && test x"${with_libs} != xno ; then
if test x"${with_newlib}" = x ; then
with_newlib=no
fi
@@ -209,12 +265,8 @@ esac
# Configure extra directories which are host specific
case "${host}" in
- i[3456]86-*-go32*)
- configdirs="$configdirs dosrel" ;;
- i[3456]86-*-mingw32*)
- configdirs="$configdirs dosrel" ;;
*-cygwin*)
- configdirs="$configdirs libtermcap dosrel" ;;
+ configdirs="$configdirs libtermcap" ;;
esac
# Remove more programs from consideration, based on the host or
@@ -225,33 +277,44 @@ case "${host}" in
hppa*64*-*-*)
noconfigdirs="$noconfigdirs byacc"
;;
- i[3456]86-*-vsta)
- noconfigdirs="tcl expect dejagnu make texinfo bison patch flex byacc send-pr gprof uudecode dejagnu diff guile perl itcl tix db snavigator gnuserv gettext"
+ i[[3456789]]86-*-vsta)
+ noconfigdirs="$noconfigdirs tcl expect dejagnu make texinfo bison patch flex byacc send-pr gprof uudecode dejagnu diff guile perl itcl tix gnuserv gettext"
+ ;;
+ i[[3456789]]86-*-go32* | i[[3456789]]86-*-msdosdjgpp*)
+ noconfigdirs="$noconfigdirs tcl tk expect dejagnu send-pr uudecode guile itcl tix gnuserv libffi"
+ ;;
+ i[[3456789]]86-*-mingw32*)
+ # noconfigdirs="tcl tk expect dejagnu make texinfo bison patch flex byacc send-pr uudecode dejagnu diff guile perl itcl tix gnuserv"
+ noconfigdirs="$noconfigdirs expect dejagnu autoconf automake send-pr rcs guile perl texinfo libtool"
+ ;;
+ i[[3456789]]86-*-beos*)
+ noconfigdirs="$noconfigdirs tk itcl tix libgui gdb"
;;
- i[3456]86-*-go32* | i[3456]86-*-msdosdjgpp*)
- noconfigdirs="tcl tk expect dejagnu send-pr uudecode guile itcl tix db snavigator gnuserv libffi"
- ;;
- i[3456]86-*-mingw32*)
- # noconfigdirs="tcl tk expect dejagnu make texinfo bison patch flex byacc send-pr uudecode dejagnu diff guile perl itcl tix db snavigator gnuserv"
- noconfigdirs="expect dejagnu autoconf automake send-pr rcs guile perl texinfo libtool"
- ;;
- i[3456]86-*-beos*)
- noconfigdirs="$noconfigdirs tk itcl tix libgui gdb"
- ;;
*-*-cygwin*)
- noconfigdirs="autoconf automake send-pr rcs guile perl"
+ noconfigdirs="$noconfigdirs autoconf automake send-pr rcs guile perl"
;;
*-*-netbsd*)
- noconfigdirs="rcs"
+ noconfigdirs="$noconfigdirs rcs"
;;
ppc*-*-pe)
- noconfigdirs="patch diff make tk tcl expect dejagnu autoconf automake texinfo bison send-pr gprof rcs guile perl itcl tix db snavigator gnuserv"
+ noconfigdirs="$noconfigdirs patch diff make tk tcl expect dejagnu autoconf automake texinfo bison send-pr gprof rcs guile perl itcl tix gnuserv"
;;
powerpc-*-beos*)
noconfigdirs="$noconfigdirs tk itcl tix libgui gdb dejagnu readline"
;;
+ *-*-darwin*)
+ noconfigdirs="$noconfigdirs tk itcl tix libgui"
+ ;;
esac
+AC_ARG_ENABLE(libada,
+[ --enable-libada Builds libada directory],
+ENABLE_LIBADA=$enableval,
+ENABLE_LIBADA=yes)
+if test "${ENABLE_LIBADA}" != "yes" ; then
+ noconfigdirs="$noconfigdirs target-libada"
+fi
+
# Save it here so that, even in case of --enable-libgcj, if the Java
# front-end isn't enabled, we still get libgcj disabled.
libgcj_saved=$libgcj
@@ -272,23 +335,39 @@ case "${target}" in
*-*-chorusos)
noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
;;
- *-*-freebsd[12] | *-*-freebsd[12].* | *-*-freebsd*aout*)
+ powerpc-*-darwin*)
+ noconfigdirs="$noconfigdirs bfd binutils ld gas opcodes gdb gprof"
+ noconfigdirs="$noconfigdirs target-libobjc"
+ ;;
+ *-*-darwin*)
+ noconfigdirs="$noconfigdirs bfd binutils ld gas opcodes gdb gprof"
+ noconfigdirs="$noconfigdirs target-libobjc ${libgcj}"
+ ;;
+ *-*-freebsd[[12]] | *-*-freebsd[[12]].* | *-*-freebsd*aout*)
noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
;;
+ *-*-kaos*)
+ # Remove unsupported stuff on all kaOS configurations.
+ skipdirs="target-libiberty ${libgcj} target-libstdc++-v3 target-libf2c target-librx"
+ skipdirs="$skipdirs target-libobjc target-examples target-groff target-gperf"
+ skipdirs="$skipdirs zlib fastjar target-libjava target-boehm-gc target-zlib"
+ noconfigdirs="$noconfigdirs target-libgloss"
+ ;;
*-*-netbsd*)
# Skip some stuff on all NetBSD configurations.
- skipdirs="$skipdirs target-newlib target-libiberty target-libgloss"
+ noconfigdirs="$noconfigdirs target-newlib target-libiberty target-libgloss"
# Skip some stuff that's unsupported on some NetBSD configurations.
case "${target}" in
i*86-*-netbsdelf*) ;;
+ arm*-*-netbsdelf*) ;;
*)
noconfigdirs="$noconfigdirs ${libgcj}"
;;
esac
;;
*-*-netware)
- noconfigdirs="$noconfigdirs ${libstdcxx_version} target-newlib target-libiberty target-libgloss ${libgcj}"
+ noconfigdirs="$noconfigdirs target-libstdc++-v3 target-newlib target-libiberty target-libgloss ${libgcj}"
;;
*-*-rtems*)
noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
@@ -299,8 +378,11 @@ case "${target}" in
*) ;;
esac
;;
+ *-*-uclinux*)
+ noconfigdirs="$noconfigdirs target-newlib target-libgloss target-rda ${libgcj}"
+ ;;
*-*-vxworks*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
+ noconfigdirs="$noconfigdirs target-newlib target-libgloss target-libiberty ${libgcj}"
;;
alpha*-dec-osf*)
# ld works, but does not support shared libraries.
@@ -315,13 +397,16 @@ case "${target}" in
# newlib is not 64 bit ready
noconfigdirs="$noconfigdirs target-newlib target-libgloss"
;;
- alpha*-*-freebsd*)
+ alpha*-*-freebsd* | alpha*-*-kfreebsd*-gnu)
noconfigdirs="$noconfigdirs target-newlib target-libgloss"
;;
alpha*-*-*)
# newlib is not 64 bit ready
noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
;;
+ am33_2.0-*-linux*)
+ noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss"
+ ;;
sh-*-linux*)
noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss"
;;
@@ -332,17 +417,23 @@ case "${target}" in
noconfigdirs="$noconfigdirs tcl tix tk itcl libgui sim"
noconfigdirs="$noconfigdirs expect dejagnu"
# the C++ libraries don't build on top of CE's C libraries
- noconfigdirs="$noconfigdirs ${libstdcxx_version}"
- skipdirs="$skipdirs target-newlib"
+ noconfigdirs="$noconfigdirs target-libstdc++-v3"
+ noconfigdirs="$noconfigdirs target-newlib"
case "${host}" in
*-*-cygwin*) ;; # keep gdb and readline
- *) noconfigdirs="$noconfigdirs gdb readline ${libstdcxx_version}"
+ *) noconfigdirs="$noconfigdirs gdb readline"
;;
esac
;;
arc-*-*)
noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
;;
+ arm-*-coff | strongarm-*-coff | xscale-*-coff)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
+ arm-*-elf* | strongarm-*-elf* | xscale-*-elf*)
+ noconfigdirs="$noconfigdirs target-libffi target-qthreads"
+ ;;
arm-*-pe*)
noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
;;
@@ -358,18 +449,6 @@ case "${target}" in
thumb-*-oabi)
noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
;;
- strongarm-*-elf)
- noconfigdirs="$noconfigdirs ${libgcj}"
- ;;
- strongarm-*-coff)
- noconfigdirs="$noconfigdirs ${libgcj}"
- ;;
- xscale-*-elf)
- noconfigdirs="$noconfigdirs target-libffi target-qthreads"
- ;;
- xscale-*-coff)
- noconfigdirs="$noconfigdirs ${libgcj}"
- ;;
thumb-*-pe)
noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
;;
@@ -377,34 +456,34 @@ case "${target}" in
noconfigdirs="$noconfigdirs ld target-libgloss ${libgcj}"
;;
avr-*-*)
- noconfigdirs="$noconfigdirs target-libiberty ${libstdcxx_version} ${libgcj}"
+ noconfigdirs="$noconfigdirs target-libiberty target-libstdc++-v3 ${libgcj}"
;;
- c4x-*-*)
- noconfigdirs="$noconfigdirs ${libstdcxx_version} target-libgloss ${libgcj}"
+ c4x-*-* | tic4x-*-*)
+ noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
;;
c54x*-*-* | tic54x-*-*)
- noconfigdirs="$noconfigdirs ${libstdcxx_version} target-libgloss ${libgcj} gcc gdb newlib"
+ noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj} gcc gdb newlib"
;;
cris-*-*)
- noconfigdirs="$noconfigdirs ${libgcj}"
+ noconfigdirs="$noconfigdirs ${libgcj} target-newlib target-libgloss"
;;
d10v-*-*)
- noconfigdirs="$noconfigdirs ${libstdcxx_version} target-libgloss ${libgcj}"
+ noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
;;
d30v-*-*)
- noconfigdirs="$noconfigdirs ${libgcj}"
+ noconfigdirs="$noconfigdirs ${libgcj} gdb"
;;
fr30-*-elf*)
- noconfigdirs="$noconfigdirs ${libgcj}"
+ noconfigdirs="$noconfigdirs ${libgcj} gdb"
;;
frv-*-*)
noconfigdirs="$noconfigdirs ${libgcj}"
;;
h8300*-*-*)
- noconfigdirs="$noconfigdirs target-libgloss"
+ noconfigdirs="$noconfigdirs target-libgloss ${libgcj} target-libf2c"
;;
h8500-*-*)
- noconfigdirs="$noconfigdirs ${libstdcxx_version} target-libgloss ${libgcj} target-libf2c"
+ noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj} target-libf2c"
;;
hppa*64*-*-linux* | parisc*64*-*-linux*)
# In this case, it's because the hppa64-linux target is for
@@ -415,6 +494,7 @@ case "${target}" in
hppa*-*-*elf* | \
parisc*-*-linux* | hppa*-*-linux* | \
hppa*-*-lites* | \
+ hppa*-*-openbsd* | \
hppa*64*-*-*)
noconfigdirs="$noconfigdirs ${libgcj}"
# Do configure ld/binutils/gas for this case.
@@ -424,29 +504,35 @@ case "${target}" in
# build on HP-UX 10.20.
noconfigdirs="$noconfigdirs ld shellutils ${libgcj}"
;;
+ i960-*-*)
+ noconfigdirs="$noconfigdirs ${libgcj} gdb"
+ ;;
ia64*-*-elf*)
# No gdb support yet.
noconfigdirs="$noconfigdirs tix readline mmalloc libgui itcl gdb"
;;
ia64*-**-hpux*)
# No gdb or ld support yet.
- noconfigdirs="$noconfigdirs tix readline mmalloc libgui itcl gdb ld"
+ noconfigdirs="$noconfigdirs ${libgcj} tix readline mmalloc libgui itcl gdb ld"
;;
- i[3456]86-*-coff | i[3456]86-*-elf)
+ i[[3456789]]86-*-coff | i[[3456789]]86-*-elf)
noconfigdirs="$noconfigdirs ${libgcj}"
;;
- i[34567]86-*-freebsd*)
+ i[[3456789]]86-*-freebsd* | i[[3456789]]86-*-kfreebsd*-gnu)
noconfigdirs="$noconfigdirs target-newlib target-libgloss"
;;
- s390*-*-linux*)
- # The libffi port is not yet in the GCC tree
- noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
- ;;
- i[3456]86-*-linux*)
+ i[[3456789]]86-*-linux*)
+ # The GCC port for glibc1 has no MD_FALLBACK_FRAME_STATE_FOR, so let's
+ # not build java stuff by default.
+ case "${target}" in
+ *-*-*libc1*)
+ noconfigdirs="$noconfigdirs ${libgcj}";;
+ esac
+
# This section makes it possible to build newlib natively on linux.
# If we are using a cross compiler then don't configure newlib.
if test x${is_cross_compiler} != xno ; then
- noconfigdirs="$noconfigdirs target-newlib"
+ noconfigdirs="$noconfigdirs target-newlib"
fi
noconfigdirs="$noconfigdirs target-libgloss"
# If we are not using a cross compiler, do configure newlib.
@@ -454,17 +540,14 @@ case "${target}" in
# if the --with-newlib option has been given, because otherwise
# 'target-newlib' will appear in skipdirs.
;;
- *-*-linux*)
- noconfigdirs="$noconfigdirs target-newlib target-libgloss"
- ;;
- i[3456]86-*-mingw32*)
+ i[[3456789]]86-*-mingw32*)
target_configdirs="$target_configdirs target-mingw"
noconfigdirs="$noconfigdirs expect target-libgloss ${libgcj}"
# Can't build gdb for mingw32 if not native.
case "${host}" in
- i[3456]86-*-mingw32) ;; # keep gdb tcl tk expect etc.
- *) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl tix db snavigator gnuserv"
+ i[[3456789]]86-*-mingw32) ;; # keep gdb tcl tk expect etc.
+ *) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl tix gnuserv"
;;
esac
;;
@@ -477,32 +560,35 @@ case "${target}" in
# Can't build gdb for Cygwin if not native.
case "${host}" in
*-*-cygwin*) ;; # keep gdb tcl tk expect etc.
- *) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl tix libgui db snavigator gnuserv"
+ *) noconfigdirs="$noconfigdirs gdb tcl tk expect itcl tix libgui gnuserv"
;;
esac
;;
- i[3456]86-*-pe)
- noconfigdirs="$noconfigdirs ${libstdcxx_version} target-libgloss ${libgcj}"
+ i[[3456789]]86-*-pe)
+ noconfigdirs="$noconfigdirs target-libstdc++-v3 target-libgloss ${libgcj}"
;;
- i[3456]86-*-sco3.2v5*)
+ i[[3456789]]86-*-sco3.2v5*)
# The linker does not yet know about weak symbols in COFF,
# and is not configured to handle mixed ELF and COFF.
noconfigdirs="$noconfigdirs ld target-libgloss ${libgcj}"
;;
- i[3456]86-*-sco*)
+ i[[3456789]]86-*-sco*)
noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
;;
- i[3456]86-*-solaris2*)
+ i[[3456789]]86-*-solaris2*)
noconfigdirs="$noconfigdirs target-libgloss"
;;
- i[3456]86-*-sysv4*)
+ i[[3456789]]86-*-sysv4*)
noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
;;
- i[3456]86-*-beos*)
- noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
- ;;
+ i[[3456789]]86-*-beos*)
+ noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
+ ;;
+ m32r-*-*)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
m68hc11-*-*|m6811-*-*|m68hc12-*-*|m6812-*-*)
- noconfigdirs="$noconfigdirs target-libiberty ${libstdcxx_version} ${libgcj}"
+ noconfigdirs="$noconfigdirs target-libiberty target-libstdc++-v3 ${libgcj}"
;;
m68k-*-elf*)
noconfigdirs="$noconfigdirs ${libgcj}"
@@ -516,7 +602,7 @@ case "${target}" in
noconfigdirs="$noconfigdirs target-libstdc++-v3"
;;
mmix-*-*)
- noconfigdirs="$noconfigdirs ${libgcj}"
+ noconfigdirs="$noconfigdirs ${libgcj} gdb libgloss"
;;
mn10200-*-*)
noconfigdirs="$noconfigdirs ${libgcj}"
@@ -526,17 +612,17 @@ case "${target}" in
;;
powerpc-*-aix*)
# copied from rs6000-*-* entry
- noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
+ noconfigdirs="$noconfigdirs gprof target-libada target-libgloss ${libgcj}"
;;
powerpc*-*-winnt* | powerpc*-*-pe* | ppc*-*-pe)
target_configdirs="$target_configdirs target-winsup"
- noconfigdirs="$noconfigdirs gdb tcl tk make expect target-libgloss itcl tix db snavigator gnuserv ${libgcj}"
+ noconfigdirs="$noconfigdirs gdb tcl tk make expect target-libgloss itcl tix gnuserv ${libgcj}"
# always build newlib.
skipdirs=`echo " ${skipdirs} " | sed -e 's/ target-newlib / /'`
;;
# This is temporary until we can link against shared libraries
powerpcle-*-solaris*)
- noconfigdirs="$noconfigdirs gdb sim make tcl tk expect itcl tix db snavigator gnuserv ${libgcj}"
+ noconfigdirs="$noconfigdirs gdb sim make tcl tk expect itcl tix gnuserv ${libgcj}"
;;
powerpc-*-beos*)
noconfigdirs="$noconfigdirs gdb target-newlib target-libgloss ${libgcj}"
@@ -548,7 +634,7 @@ case "${target}" in
noconfigdirs="$noconfigdirs target-newlib gprof ${libgcj}"
;;
rs6000-*-aix*)
- noconfigdirs="$noconfigdirs gprof ${libgcj}"
+ noconfigdirs="$noconfigdirs gprof target-libada target-libgloss ${libgcj}"
;;
rs6000-*-*)
noconfigdirs="$noconfigdirs gprof ${libgcj}"
@@ -557,16 +643,14 @@ case "${target}" in
noconfigdirs="$noconfigdirs ld binutils gprof target-libgloss ${libgcj}"
;;
mips*-*-irix5*)
- # The GNU linker does not support shared libraries.
- noconfigdirs="$noconfigdirs ld gprof target-libgloss ${libgcj}"
+ noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
;;
mips*-*-irix6*)
- # The GNU assembler does not support IRIX 6.
# Linking libjava exceeds command-line length limits on at least
# IRIX 6.2, but not on IRIX 6.5.
# Also, boehm-gc won't build on IRIX 6.5, according to Jeffrey Oldham
# <oldham@codesourcery.com>
- noconfigdirs="$noconfigdirs gas gprof target-libgloss ${libgcj}"
+ noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
;;
mips*-dec-bsd*)
noconfigdirs="$noconfigdirs gprof target-libgloss ${libgcj}"
@@ -576,9 +660,9 @@ case "${target}" in
;;
mipstx39-*-*)
noconfigdirs="$noconfigdirs gprof ${libgcj}" # same as generic mips
- ;;
+ ;;
mips*-*-linux*)
- noconfigdirs="$noconfigdirs target-libffi"
+ noconfigdirs="$noconfigdirs target-newlib target-libgloss"
;;
mips*-*-*)
noconfigdirs="$noconfigdirs gprof ${libgcj}"
@@ -588,9 +672,9 @@ case "${target}" in
;;
sh-*-*)
case "${host}" in
- i[3456]86-*-vsta) ;; # don't add gprof back in
- i[3456]86-*-go32*) ;; # don't add gprof back in
- i[3456]86-*-msdosdjgpp*) ;; # don't add gprof back in
+ i[[3456789]]86-*-vsta) ;; # don't add gprof back in
+ i[[3456789]]86-*-go32*) ;; # don't add gprof back in
+ i[[3456789]]86-*-msdosdjgpp*) ;; # don't add gprof back in
*) skipdirs=`echo " ${skipdirs} " | sed -e 's/ gprof / /'` ;;
esac
noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
@@ -618,7 +702,7 @@ case "${target}" in
sparc-*-solaris* | sparc64-*-solaris* | sparcv9-*-solaris*)
;;
v810-*-*)
- noconfigdirs="$noconfigdirs bfd binutils gas gcc gdb ld ${libstdcxx_version} opcodes target-libgloss ${libgcj}"
+ noconfigdirs="$noconfigdirs bfd binutils gas gcc gdb ld target-libstdc++-v3 opcodes target-libgloss ${libgcj}"
;;
v850-*-*)
noconfigdirs="$noconfigdirs target-libgloss ${libgcj}"
@@ -635,8 +719,14 @@ case "${target}" in
vax-*-*)
noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
;;
+ xtensa-*-*)
+ noconfigdirs="$noconfigdirs ${libgcj}"
+ ;;
ip2k-*-*)
- noconfigdirs="$noconfigdirs target-libiberty ${libstdcxx_version} ${libgcj}"
+ noconfigdirs="$noconfigdirs target-libiberty target-libstdc++-v3 ${libgcj}"
+ ;;
+ *-*-linux*)
+ noconfigdirs="$noconfigdirs target-newlib target-libgloss"
;;
*-*-lynxos*)
noconfigdirs="$noconfigdirs target-newlib target-libgloss ${libgcj}"
@@ -659,85 +749,90 @@ esac
# go away some day.
# NB: embedded tabs in this IF block -- do not untabify
if test x"${enable_languages+set}" != xset; then
- if test x"${LANGUAGES+set}" = xset; then
- enable_languages="${LANGUAGES}"
- echo configure.in: warning: setting LANGUAGES is deprecated, use --enable-languages instead 1>&2
- else
- enable_languages=all
- fi
+ if test x"${LANGUAGES+set}" = xset; then
+ enable_languages="${LANGUAGES}"
+ echo configure.in: warning: setting LANGUAGES is deprecated, use --enable-languages instead 1>&2
+ else
+ enable_languages=all
+ fi
else
- if test x"${enable_languages}" = x ||
- test x"${enable_languages}" = xyes;
- then
- echo configure.in: --enable-languages needs at least one language argument 1>&2
- exit 1
- fi
+ if test x"${enable_languages}" = x ||
+ test x"${enable_languages}" = xyes;
+ then
+ echo configure.in: --enable-languages needs at least one language argument 1>&2
+ exit 1
+ fi
fi
-enable_languages=`echo "${enable_languages}" | sed -e 's/[ ,][ ,]*/,/g' -e 's/,$//'`
+enable_languages=`echo "${enable_languages}" | sed -e 's/[[ ,]][[ ,]]*/,/g' -e 's/,$//'`
# First scan to see if an enabled language requires some other language.
# We assume that a given config-lang.in will list all the language
# front ends it requires, even if some are required indirectly.
-for lang in ${srcdir}/gcc/*/config-lang.in ..
-do
- case $lang in
- ..)
- ;;
+for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
+ case ${lang_frag} in
+ ..) ;;
# The odd quoting in the next line works around
# an apparent bug in bash 1.12 on linux.
- ${srcdir}/gcc/[*]/config-lang.in)
- ;;
+ ${srcdir}/gcc/[[*]]/config-lang.in) ;;
*)
- lang_alias=`sed -n -e 's,^language=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^language=\([^ ]*\).*$,\1,p' $lang`
- this_lang_requires=`sed -n -e 's,^lang_requires=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^lang_requires=\([^ ]*\).*$,\1,p' $lang`
- for other in $this_lang_requires
- do
- case ,${enable_languages}, in
- *,$other,*)
- ;;
- *,all,*)
- ;;
- *,$lang_alias,*)
- echo " \`$other' language required by \`$lang_alias'; enabling" 1>&2
- enable_languages="$enable_languages,$other"
- ;;
- esac
- done
- ;;
- esac
+ # From the config-lang.in, get $language, $lang_requires
+ language=
+ lang_requires=
+ . ${lang_frag}
+ for other in ${lang_requires} ; do
+ case ,${enable_languages}, in
+ *,$other,*) ;;
+ *,all,*) ;;
+ *,$language,*)
+ echo " \`$other' language required by \`$language'; enabling" 1>&2
+ enable_languages="${enable_languages},${other}"
+ ;;
+ esac
+ done
+ ;;
+ esac
done
-subdirs=
-for lang in ${srcdir}/gcc/*/config-lang.in ..
-do
- case $lang in
- ..) ;;
- # The odd quoting in the next line works around
- # an apparent bug in bash 1.12 on linux.
- ${srcdir}/gcc/[*]/config-lang.in) ;;
- *)
- lang_alias=`sed -n -e 's,^language=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^language=\([^ ]*\).*$,\1,p' $lang`
- this_lang_libs=`sed -n -e 's,^target_libs=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^target_libs=\([^ ]*\).*$,\1,p' $lang`
- this_lang_dirs=`sed -n -e 's,^lang_dirs=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^lang_dirs=\([^ ]*\).*$,\1,p' $lang`
- build_by_default=`sed -n -e 's,^build_by_default=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^build_by_default=\([^ ]*\).*$,\1,p' $lang`
- if test "x$lang_alias" = x
- then
- echo "$lang doesn't set \$language." 1>&2
- exit 1
- fi
- case ${build_by_default},${enable_languages}, in
- *,$lang_alias,*) add_this_lang=yes ;;
- no,*) add_this_lang=no ;;
- *,all,*) add_this_lang=yes ;;
- *) add_this_lang=no ;;
- esac
- if test x"${add_this_lang}" = xyes; then
- eval target_libs='"$target_libs "'\"$this_lang_libs\"
- else
- eval noconfigdirs='"$noconfigdirs "'\"$this_lang_libs $this_lang_dirs\"
- fi
- ;;
- esac
+for lang_frag in ${srcdir}/gcc/*/config-lang.in .. ; do
+ case ${lang_frag} in
+ ..) ;;
+ # The odd quoting in the next line works around
+ # an apparent bug in bash 1.12 on linux.
+ ${srcdir}/gcc/[[*]]/config-lang.in) ;;
+ *)
+ # From the config-lang.in, get $language, $target_libs,
+ # $lang_dirs, and $build_by_default
+ language=
+ target_libs=
+ lang_dirs=
+ build_by_default=
+ . ${lang_frag}
+ if test "x$language" = x ; then
+ echo "${lang_frag} doesn't set \$language." 1>&2
+ exit 1
+ fi
+ case ,${enable_languages}, in
+ *,${language},*)
+ # Language was explicitly selected; include it.
+ add_this_lang=yes
+ ;;
+ *,all,*)
+ # 'all' was selected; include 'default' languages.
+ case ${build_by_default} in
+ no) add_this_lang=no ;;
+ *) add_this_lang=yes ;;
+ esac
+ ;;
+ *) add_this_lang=no ;;
+ esac
+ case ${add_this_lang} in
+ no)
+ # Remove language-dependent dirs.
+ eval noconfigdirs='"$noconfigdirs "'\"$target_libs $lang_dirs\"
+ ;;
+ esac
+ ;;
+ esac
done
# Remove the entries in $skipdirs and $noconfigdirs from $configdirs and
@@ -749,8 +844,7 @@ for dir in . $skipdirs $noconfigdirs ; do
dirname=`echo $dir | sed -e s/target-//g`
if test $dir != . && echo " ${configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
configdirs=`echo " ${configdirs} " | sed -e "s/ ${dir} / /"`
- if test -r $srcdir/$dirname/configure \
- || test -r $srcdir/$dirname/configure.in ; then
+ if test -r $srcdir/$dirname/configure ; then
if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
true
else
@@ -760,8 +854,7 @@ for dir in . $skipdirs $noconfigdirs ; do
fi
if test $dir != . && echo " ${target_configdirs} " | grep " ${dir} " >/dev/null 2>&1; then
target_configdirs=`echo " ${target_configdirs} " | sed -e "s/ ${dir} / /"`
- if test -r $srcdir/$dirname/configure \
- || test -r $srcdir/$dirname/configure.in ; then
+ if test -r $srcdir/$dirname/configure ; then
if echo " ${skipdirs} " | grep " ${dir} " >/dev/null 2>&1; then
true
else
@@ -777,7 +870,7 @@ if test -n "${target_configdirs}" ; then
others=
for i in `echo ${target_configdirs} | sed -e s/target-//g` ; do
if test "$i" != "libiberty" ; then
- if test -r $srcdir/$i/configure || test -r $srcdir/$i/configure.in ; then
+ if test -r $srcdir/$i/configure ; then
others=yes;
break;
fi
@@ -788,20 +881,6 @@ if test -n "${target_configdirs}" ; then
fi
fi
-# Deconfigure all subdirectories, in case we are changing the
-# configuration from one where a subdirectory is supported to one where it
-# is not.
-if test -z "${norecursion}" && test -n "${configdirs}" ; then
- for i in `echo ${configdirs} | sed -e s/target-//g` ; do
- rm -f $i/Makefile
- done
-fi
-if test -z "${norecursion}" && test -n "${target_configdirs}" ; then
- for i in `echo ${target_configdirs} | sed -e s/target-//g` ; do
- rm -f ${target_subdir}/$i/Makefile
- done
-fi
-
# Quietly strip out all directories which aren't configurable in this tree.
# This relies on all configurable subdirectories being autoconfiscated, which
# is now the case.
@@ -860,46 +939,44 @@ case "$host" in
*msdosdjgpp*)
enable_gdbtk=no ;;
esac
-# Determine whether gdb needs tk/tcl or not.
-case "$enable_gdbtk" in
- no)
- GDB_TK="" ;;
- *)
- GDB_TK="all-tcl all-tk all-itcl all-tix all-libgui" ;;
-esac
copy_dirs=
-# Handle --with-headers=XXX. The contents of the named directory are
-# copied to $(tooldir)/sys-include.
-if test x"${with_headers}" != x ; then
+# Handle --with-headers=XXX. If the value is not "yes", the contents of
+# the named directory are copied to $(tooldir)/sys-include.
+if test x"${with_headers}" != x && test x"${with_headers}" != xno ; then
if test x${is_cross_compiler} = xno ; then
echo 1>&2 '***' --with-headers is only supported when cross compiling
exit 1
fi
- case "${exec_prefixoption}" in
- "") x=${prefix} ;;
- *) x=${exec_prefix} ;;
- esac
- copy_dirs="${copy_dirs} ${with_headers} $x/${target_alias}/sys-include"
+ if test x"${with_headers}" != xyes ; then
+ case "${exec_prefixoption}" in
+ "") x=${prefix} ;;
+ *) x=${exec_prefix} ;;
+ esac
+ copy_dirs="${copy_dirs} ${with_headers} $x/${target_alias}/sys-include"
+ fi
fi
-# Handle --with-libs=XXX. Multiple directories are permitted. The
-# contents are copied to $(tooldir)/lib.
-if test x"${with_libs}" != x ; then
+# Handle --with-libs=XXX. If the value is not "yes", the contents of
+# the name directories are copied to $(tooldir)/lib. Multiple directories
+# are permitted.
+if test x"${with_libs}" != x && test x"${with_libs}" != xno ; then
if test x${is_cross_compiler} = xno ; then
echo 1>&2 '***' --with-libs is only supported when cross compiling
exit 1
fi
- # Copy the libraries in reverse order, so that files in the first named
- # library override files in subsequent libraries.
- case "${exec_prefixoption}" in
- "") x=${prefix} ;;
- *) x=${exec_prefix} ;;
- esac
- for l in ${with_libs}; do
- copy_dirs="$l $x/${target_alias}/lib ${copy_dirs}"
- done
+ if test x"${with_libs}" != xyes ; then
+ # Copy the libraries in reverse order, so that files in the first named
+ # library override files in subsequent libraries.
+ case "${exec_prefixoption}" in
+ "") x=${prefix} ;;
+ *) x=${exec_prefix} ;;
+ esac
+ for l in ${with_libs}; do
+ copy_dirs="$l $x/${target_alias}/lib ${copy_dirs}"
+ done
+ fi
fi
# Handle ${copy_dirs}
@@ -935,16 +1012,18 @@ done
# Work in distributions that contain no compiler tools, like Autoconf.
tentative_cc=""
+host_makefile_frag=/dev/null
if test -d ${srcdir}/config ; then
case "${host}" in
m68k-hp-hpux*)
# Avoid "too much defining" errors from HPUX compiler.
tentative_cc="cc -Wp,-H256000"
- host_makefile_frag="config/mh-hp300"
+ # If "ar" in $PATH is GNU ar, the symbol table may need rebuilding.
+ # If it's HP/UX ar, this should be harmless.
+ RANLIB="ar ts"
;;
m68k-apollo-sysv*)
tentative_cc="cc -A ansi -A runtype,any -A systype,any -U__STDC__ -DUSG"
- host_makefile_frag="config/mh-apollo68"
;;
m68k-apollo-bsd*)
#None of the Apollo compilers can compile gas or binutils. The preprocessor
@@ -953,12 +1032,11 @@ case "${host}" in
# the apollo compiler" (the preferred version of GCC could be called cc,
# or whatever), but I'm not sure leaving CC as cc is any better...
#CC=cc -A ansi -A runtype,any -A systype,any -U__STDC__ -DNO_STDARG
+ # Used to have BISON=yacc.
tentative_cc=gcc
- host_makefile_frag="config/mh-a68bsd"
;;
m88k-dg-dgux*)
tentative_cc="gcc -Wall -ansi -D__using_DGUX"
- host_makefile_frag="config/mh-dgux"
;;
m88k-harris-cxux*)
# Under CX/UX, we want to tell the compiler to use ANSI mode.
@@ -966,7 +1044,6 @@ case "${host}" in
host_makefile_frag="config/mh-cxux"
;;
m88k-motorola-sysv*)
- host_makefile_frag="config/mh-delta88"
;;
mips*-dec-ultrix*)
tentative_cc="cc -Wf,-XNg1000"
@@ -977,21 +1054,12 @@ case "${host}" in
tentative_cc="cc -ZXNd=5000 -ZXNg=1000"
host_makefile_frag="config/mh-necv4"
;;
- mips*-sgi-irix6*)
- host_makefile_frag="config/mh-irix6"
- ;;
- mips*-sgi-irix5*)
- host_makefile_frag="config/mh-irix5"
- ;;
mips*-sgi-irix4*)
# Tell compiler to use K&R C. We can't compile under the SGI Ansi
# environment. Also bump switch table size so that cp-parse will
# compile. Bump string length limit so linker builds.
tentative_cc="cc -cckr -Wf,-XNg1500 -Wf,-XNk1000 -Wf,-XNh2000 -Wf,-XNl8192"
;;
- mips*-sgi-irix3*)
- host_makefile_frag="config/mh-sysv"
- ;;
mips*-*-sysv4*)
host_makefile_frag="config/mh-sysv4"
;;
@@ -1009,26 +1077,23 @@ case "${host}" in
# This is not part of CFLAGS because perhaps not all C compilers have this
# option.
tentative_cc="cc -systype sysv"
- host_makefile_frag="config/mh-riscos"
;;
i370-ibm-opened*)
tentative_cc="c89"
- host_makefile_frag="config/mh-openedition"
;;
- i[3456]86-*-sysv5*)
+ i[[3456789]]86-*-sysv5*)
host_makefile_frag="config/mh-sysv5"
;;
- i[3456]86-*-dgux*)
+ i[[3456789]]86-*-dgux*)
tentative_cc="gcc -Wall -ansi -D__using_DGUX"
host_makefile_frag="config/mh-dgux386"
;;
- i[3456]86-ncr-sysv4.3*)
+ i[[3456789]]86-ncr-sysv4.3*)
# The MetaWare compiler will generate a copyright message unless you
# turn it off by adding the -Hnocopyr flag.
tentative_cc="cc -Hnocopyr"
- host_makefile_frag="config/mh-ncrsvr43"
;;
- i[3456]86-ncr-sysv4*)
+ i[[3456789]]86-ncr-sysv4*)
# for an NCR 3000 (i486/SVR4) system.
# The NCR 3000 ships with a MetaWare compiler installed as /bin/cc.
# This compiler not only emits obnoxious copyright messages every time
@@ -1037,28 +1102,21 @@ case "${host}" in
tentative_cc="/usr/ccs/ATT/cc"
host_makefile_frag="config/mh-ncr3000"
;;
- i[3456]86-*-sco3.2v5*)
- host_makefile_frag="config/mh-sysv"
+ i[[3456789]]86-*-sco3.2v5*)
;;
- i[3456]86-*-sco*)
+ i[[3456789]]86-*-sco*)
# The native C compiler botches some simple uses of const. Unfortunately,
# it doesn't defined anything like "__sco__" for us to test for in ansidecl.h.
tentative_cc="cc -Dconst="
host_makefile_frag="config/mh-sco"
;;
- i[3456]86-*-udk*)
+ i[[3456789]]86-*-udk*)
host_makefile_frag="config/mh-sysv5"
;;
- i[3456]86-*-isc*)
- host_makefile_frag="config/mh-sysv"
- ;;
- i[3456]86-*-solaris2*)
+ i[[3456789]]86-*-solaris2*)
host_makefile_frag="config/mh-sysv4"
;;
- i[3456]86-*-aix*)
- host_makefile_frag="config/mh-aix386"
- ;;
- i[3456]86-*-msdosdjgpp*)
+ i[[3456789]]86-*-msdosdjgpp*)
host_makefile_frag="config/mh-djgpp"
;;
*-cygwin*)
@@ -1082,17 +1140,11 @@ case "${host}" in
# without overflowing the jump tables (-J says to use a 32 bit table)
tentative_cc="cc -J"
;;
- *-hp-hpux[78]*)
- tentative_cc="cc -Wp,-H256000"
- host_makefile_frag="config/mh-hpux8"
- ;;
*-hp-hpux*)
tentative_cc="cc -Wp,-H256000"
- host_makefile_frag="config/mh-hpux"
;;
*-*-hiux*)
tentative_cc="cc -Wp,-H256000"
- host_makefile_frag="config/mh-hpux"
;;
rs6000-*-lynxos*)
# /bin/cc is less than useful for our purposes. Always use GCC
@@ -1106,45 +1158,15 @@ case "${host}" in
*-*-sysv4*)
host_makefile_frag="config/mh-sysv4"
;;
- *-*-sysv*)
- host_makefile_frag="config/mh-sysv"
- ;;
esac
fi
-rm -f mh-frag
-if test -n "${host_makefile_frag}" ; then
- for f in ${host_makefile_frag}
- do
- cat ${srcdir}/$f >> mh-frag
- done
- host_makefile_frag=mh-frag
-fi
-
-# If we aren't going to be using gcc, see if we can extract a definition
-# of CC from the fragment.
-# Actually, use the 'pre-extracted' version above.
-if test -z "${CC}" && test "${build}" = "${host}" ; then
- IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
- found=
- for dir in $PATH; do
- test -z "$dir" && dir=.
- if test -f $dir/gcc; then
- found=yes
- break
- fi
- done
- IFS="$save_ifs"
- if test -z "${found}" && test -n "${tentative_cc}" ; then
- CC=$tentative_cc
- fi
-fi
-
+extra_arflags_for_target=
+extra_nmflags_for_target=
+extra_ranlibflags_for_target=
+target_makefile_frag=/dev/null
case "${target}" in
- v810*)
- target_makefile_frag="config/mt-v810"
- ;;
- i[3456]86-*-netware*)
+ i[[3456789]]86-*-netware*)
target_makefile_frag="config/mt-netware"
;;
powerpc-*-netware*)
@@ -1153,15 +1175,23 @@ case "${target}" in
*-*-linux*)
target_makefile_frag="config/mt-linux"
;;
- *-*-aix4.[3456789]* | *-*-aix[56789].*)
- target_makefile_frag="config/mt-aix43"
+ *-*-aix4.[[3456789]]* | *-*-aix[[56789]].*)
+ # nm and ar from AIX 4.3 and above require -X32_64 flag to all ar and nm
+ # commands to handle both 32-bit and 64-bit objects. These flags are
+ # harmless if we're using GNU nm or ar.
+ extra_arflags_for_target=" -X32_64"
+ extra_nmflags_for_target=" -B -X32_64"
+ ;;
+ *-*-darwin*)
+ # ranlib from Darwin requires the -c flag to look at common symbols.
+ extra_ranlibflags_for_target=" -c"
;;
mips*-*-pe | sh*-*-pe | *arm-wince-pe)
target_makefile_frag="config/mt-wince"
;;
esac
-alphaieee_frag=
+alphaieee_frag=/dev/null
case $target in
alpha*-*-*)
# This just makes sure to use the -mieee option to build target libs.
@@ -1173,7 +1203,7 @@ esac
# If --enable-target-optspace always use -Os instead of -O2 to build
# the target libraries, similarly if it is not specified, use -Os
# on selected platforms.
-ospace_frag=
+ospace_frag=/dev/null
case "${enable_target_optspace}:${target}" in
yes:*)
ospace_frag="config/mt-ospace"
@@ -1191,15 +1221,6 @@ case "${enable_target_optspace}:${target}" in
;;
esac
-rm -f mt-frag
-if test -n "${target_makefile_frag}${alphaieee_frag}${ospace_frag}" ; then
- for f in ${target_makefile_frag} ${alphaieee_frag} ${ospace_frag}
- do
- cat ${srcdir}/$f >> mt-frag
- done
- target_makefile_frag=mt-frag
-fi
-
# Set with_gnu_as and with_gnu_ld as appropriate.
#
# This is done by determining whether or not the appropriate directory
@@ -1216,54 +1237,32 @@ fi
if test x${use_gnu_as} = x &&
echo " ${configdirs} " | grep " gas " > /dev/null 2>&1 ; then
with_gnu_as=yes
- withoptions="$withoptions --with-gnu-as"
+ extra_host_args="$extra_host_args --with-gnu-as"
fi
if test x${use_gnu_ld} = x &&
echo " ${configdirs} " | grep " ld " > /dev/null 2>&1 ; then
with_gnu_ld=yes
- withoptions="$withoptions --with-gnu-ld"
+ extra_host_args="$extra_host_args --with-gnu-ld"
fi
-# If using newlib, add --with-newlib to the withoptions so that gcc/configure
+# If using newlib, add --with-newlib to the extra_host_args so that gcc/configure
# can detect this case.
if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " target-newlib " > /dev/null 2>&1 ; then
with_newlib=yes
- withoptions="$withoptions --with-newlib"
+ extra_host_args="$extra_host_args --with-newlib"
fi
-# We default to --with-shared on platforms where -fpic is meaningless.
-# Well, we don't yet, but we will.
-if false && test "${host}" = "${target}" && test x${enable_shared} = x ; then
- case "${target}" in
- alpha*-dec-osf*) enable_shared=yes ;;
- alpha*-*-linux*) enable_shared=yes ;;
- mips-sgi-irix5*) enable_shared=yes ;;
- *) enable_shared=no ;;
- esac
-fi
-
-case "${enable_shared}" in
- yes) shared=yes ;;
- no) shared=no ;;
- "") shared=no ;;
- *) shared=yes ;;
-esac
-
# Default to using --with-stabs for certain targets.
if test x${with_stabs} = x ; then
case "${target}" in
- mips*-*-irix6*o32)
- with_stabs=yes;
- withoptions="${withoptions} --with-stabs"
- ;;
- mips*-*-irix6*)
+ mips*-*-irix[[56]]*)
;;
mips*-*-* | alpha*-*-osf*)
with_stabs=yes;
- withoptions="${withoptions} --with-stabs"
+ extra_host_args="${extra_host_args} --with-stabs"
;;
esac
fi
@@ -1272,11 +1271,301 @@ fi
# them automatically.
case "${host}" in
hppa*64*-*-hpux11*)
- withoptions="$withoptions -x-libraries=/usr/lib/pa20_64 -x-includes=/usr/X11R6/include"
+ extra_host_args="$extra_host_args -x-libraries=/usr/lib/pa20_64 -x-includes=/usr/X11R6/include"
;;
esac
-# post-target:
+# If we aren't going to be using gcc, see if we can extract a definition
+# of CC from the fragment.
+# Actually, use the 'pre-extracted' version above.
+if test -z "${CC}" && test "${build}" = "${host}" ; then
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
+ found=
+ for dir in $PATH; do
+ test -z "$dir" && dir=.
+ if test -f $dir/gcc; then
+ found=yes
+ break
+ fi
+ done
+ IFS="$save_ifs"
+ if test -z "${found}" && test -n "${tentative_cc}" ; then
+ CC=$tentative_cc
+ fi
+fi
+
+# Some systems (e.g., one of the i386-aix systems the gas testers are
+# using) don't handle "\$" correctly, so don't use it here.
+tooldir='${exec_prefix}'/${target_alias}
+build_tooldir=${tooldir}
+
+# Generate a default definition for YACC. This is used if the makefile can't
+# locate bison or byacc in objdir.
+
+for prog in 'bison -y' byacc yacc
+do
+ set dummy $prog; tmp=$2
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
+ for dir in $PATH; do
+ test -z "$dir" && dir=.
+ if test -f $dir/$tmp; then
+ DEFAULT_YACC="$prog"
+ break
+ fi
+ done
+ IFS="$save_ifs"
+
+ test -n "$DEFAULT_YACC" && break
+done
+
+# Generate a default definition for M4. This is used if the makefile can't
+# locate m4 in objdir.
+
+for prog in gm4 gnum4 m4
+do
+ set dummy $prog; tmp=$2
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
+ for dir in $PATH; do
+ test -z "$dir" && dir=.
+ if test -f $dir/$tmp; then
+ DEFAULT_M4="$prog"
+ break
+ fi
+ done
+ IFS="$save_ifs"
+
+ test -n "$DEFAULT_M4" && break
+done
+
+# Generate a default definition for LEX. This is used if the makefile can't
+# locate flex in objdir.
+
+for prog in flex lex
+do
+ set dummy $prog; tmp=$2
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
+ for dir in $PATH; do
+ test -z "$dir" && dir=.
+ if test -f $dir/$tmp; then
+ DEFAULT_LEX="$prog"
+ break
+ fi
+ done
+ IFS="$save_ifs"
+
+ test -n "$DEFAULT_LEX" && break
+done
+
+if test "${build}" != "${host}" ; then
+ # If we are doing a Canadian Cross, in which the host and build systems
+ # are not the same, we set reasonable default values for the tools.
+
+ BISON=${BISON-bison}
+ CC=${CC-${host_alias}-gcc}
+ CFLAGS=${CFLAGS-"-g -O2"}
+ CXX=${CXX-${host_alias}-c++}
+ CXXFLAGS=${CXXFLAGS-"-g -O2"}
+ CC_FOR_BUILD=${CC_FOR_BUILD-gcc}
+ CC_FOR_TARGET=${CC_FOR_TARGET-${target_alias}-gcc}
+ CXX_FOR_TARGET=${CXX_FOR_TARGET-${target_alias}-c++}
+ GCJ_FOR_TARGET=${GCJ_FOR_TARGET-${target_alias}-gcj}
+ GCC_FOR_TARGET=${GCC_FOR_TARGET-${CC_FOR_TARGET-${target_alias}-gcc}}
+ BUILD_PREFIX=${build_alias}-
+ BUILD_PREFIX_1=${build_alias}-
+ MAKEINFO=${MAKEINFO-makeinfo}
+
+ if test -z "${YACC}" ; then
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
+ for dir in $PATH; do
+ test -z "$dir" && dir=.
+ if test -f $dir/bison; then
+ YACC="bison -y"
+ break
+ fi
+ if test -f $dir/byacc; then
+ YACC=byacc
+ break
+ fi
+ if test -f $dir/yacc; then
+ YACC=yacc
+ break
+ fi
+ done
+ IFS="$save_ifs"
+ if test -z "${YACC}" ; then
+ YACC="bison -y"
+ fi
+ fi
+
+ if test -z "${LEX}" ; then
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
+ for dir in $PATH; do
+ test -z "$dir" && dir=.
+ if test -f $dir/flex; then
+ LEX=flex
+ break
+ fi
+ if test -f $dir/lex; then
+ LEX=lex
+ break
+ fi
+ done
+ IFS="$save_ifs"
+ LEX=${LEX-flex}
+ fi
+
+else
+ # Set reasonable default values for some tools even if not Canadian.
+ # Of course, these are different reasonable default values, originally
+ # specified directly in the Makefile.
+ # We don't export, so that autoconf can do its job.
+ # Note that all these settings are above the fragment inclusion point
+ # in Makefile.in, so can still be overridden by fragments.
+ # This is all going to change when we autoconfiscate...
+
+ BISON="\$(USUAL_BISON)"
+ CC_FOR_BUILD="\$(CC)"
+ GCC_FOR_TARGET="\$(USUAL_GCC_FOR_TARGET)"
+ BUILD_PREFIX=
+ BUILD_PREFIX_1=loser-
+ MAKEINFO="\$(USUAL_MAKEINFO)"
+ LEX="\$(USUAL_LEX)"
+ YACC="\$(USUAL_YACC)"
+
+ # If CC is still not set, try to get gcc.
+ cc_prog_is_gcc=
+ if test -z "${CC}" ; then
+ IFS="${IFS= }"; save_ifs="$IFS"; IFS="${IFS}:"
+ for dir in $PATH; do
+ test -z "$dir" && dir=.
+ if test -f $dir/gcc; then
+ CC="gcc"
+ cc_prog_is_gcc=yes
+ echo 'void f(){}' > conftest.c
+ if test -z "`${CC} -g -c conftest.c 2>&1`"; then
+ CFLAGS=${CFLAGS-"-g -O2"}
+ CXXFLAGS=${CXXFLAGS-"-g -O2"}
+ else
+ CFLAGS=${CFLAGS-"-O2"}
+ CXXFLAGS=${CXXFLAGS-"-O2"}
+ fi
+ rm -f conftest*
+ break
+ fi
+ done
+ IFS="$save_ifs"
+ CC=${CC-cc}
+ else
+ # Determine if we are using gcc.
+ cat > conftest.c <<EOF
+#ifdef __GNUC__
+ yes;
+#endif
+EOF
+ if ${CC} -E conftest.c | grep yes >/dev/null 2>&1; then
+ cc_prog_is_gcc=yes
+ fi
+ rm -f conftest.c
+ if test -z "${CFLAGS}"; then
+ # Here CC is set but CFLAGS is not. Use a quick hack to use -O2 if CC
+ # is set to a version of gcc.
+ if test "$cc_prog_is_gcc" = yes; then
+ echo 'void f(){}' > conftest.c
+ if test -z "`${CC} -g -c conftest.c 2>&1`"; then
+ CFLAGS=${CFLAGS-"-g -O2"}
+ CXXFLAGS=${CXXFLAGS-"-g -O2"}
+ else
+ CFLAGS=${CFLAGS-"-O2"}
+ CXXFLAGS=${CXXFLAGS-"-O2"}
+ fi
+ rm -f conftest*
+ fi
+ fi
+ fi
+
+ # We must set the default linker to the linker used by gcc for the correct
+ # operation of libtool. If LD is not defined and we are using gcc, try to
+ # set the LD default to the ld used by gcc.
+ if test -z "$LD"; then
+ if test "$cc_prog_is_gcc" = yes; then
+ case $build in
+ *-*-mingw*)
+ gcc_prog_ld=`$CC -print-prog-name=ld 2>&1 | tr -d '\015'` ;;
+ *)
+ gcc_prog_ld=`$CC -print-prog-name=ld 2>&1` ;;
+ esac
+ case $gcc_prog_ld in
+ # Accept absolute paths.
+ [[\\/]* | [A-Za-z]:[\\/]*)]
+ LD="$gcc_prog_ld" ;;
+ esac
+ fi
+ fi
+
+ CXX=${CXX-"c++"}
+ CFLAGS=${CFLAGS-"-g"}
+ CXXFLAGS=${CXXFLAGS-"-g -O2"}
+fi
+
+# FIXME Should this be done recursively ??? (Useful for e.g. gdbtest)
+# Set up the list of links to be made.
+# ${links} is the list of link names, and ${files} is the list of names to link to.
+
+# Make the links.
+configlinks="${links}"
+if test -r ./config.status ; then
+ mv -f ./config.status ./config.back
+fi
+while test -n "${files}" ; do
+ # set file to car of files, files to cdr of files
+ set ${files}; file=$1; shift; files=$*
+ set ${links}; link=$1; shift; links=$*
+
+ if test ! -r ${srcdir}/${file} ; then
+ if test ! -r ${file} ; then
+ echo '***' "${progname}: cannot create a link \"${link}\"," 1>&2
+ echo '***' "since the file \"${srcdir}/${file}\" does not exist." 1>&2
+ exit 1
+ else
+ srcfile=${file}
+ fi
+ else
+ srcfile=${srcdir}/${file}
+ fi
+
+ ${remove} -f ${link}
+ # Make a symlink if possible, otherwise try a hard link
+ if ${symbolic_link} ${srcfile} ${link} >/dev/null 2>&1 ; then
+ true
+ else
+ # We need to re-remove the file because Lynx leaves a
+ # very strange directory there when it fails an NFS symlink.
+ ${remove} -r -f ${link}
+ ${hard_link} ${srcfile} ${link}
+ fi
+ if test ! -r ${link} ; then
+ echo '***' "${progname}: unable to link \"${link}\" to \"${srcfile}\"." 1>&2
+ exit 1
+ fi
+
+ echo "Linked \"${link}\" to \"${srcfile}\"."
+done
+
+# Create a .gdbinit file which runs the one in srcdir
+# and tells GDB to look there for source files.
+
+if test -r ${srcdir}/.gdbinit ; then
+ case ${srcdir} in
+ .) ;;
+ *) cat > ./.gdbinit <<EOF
+# ${NO_EDIT}
+dir ${srcdir}
+dir .
+source ${srcdir}/.gdbinit
+EOF
+ ;;
+ esac
+fi
# Make sure that the compiler is able to generate an executable. If it
# can't, we are probably in trouble. We don't care whether we can run the
@@ -1304,7 +1593,7 @@ rm -f conftest*
case "${host}" in
sparc-sun-solaris2*)
CCBASE="`echo ${CC-cc} | sed 's/ .*$//'`"
- if test "`type $CCBASE | sed 's/^[^/]*//'`" = "/usr/ucb/cc" ; then
+ if test "`type $CCBASE | sed 's/^[[^/]]*//'`" = "/usr/ucb/cc" ; then
could_use=
test -d /opt/SUNWspro/bin && could_use="/opt/SUNWspro/bin"
if test -d /opt/cygnus/bin ; then
@@ -1330,41 +1619,226 @@ esac
# If --enable-shared was set, we must set LD_LIBRARY_PATH so that the
# binutils tools will find libbfd.so.
-if test "${shared}" = "yes" ; then
- sed -e 's/^SET_LIB_PATH[ ]*=.*$/SET_LIB_PATH = $(REALLY_SET_LIB_PATH)/' \
- Makefile > Makefile.tem
- rm -f Makefile
- mv -f Makefile.tem Makefile
-
- case "${host}" in
- *-*-hpux*)
- sed -e 's/^RPATH_ENVVAR[ ]*=.*$/RPATH_ENVVAR = SHLIB_PATH/' \
- Makefile > Makefile.tem
- rm -f Makefile
- mv -f Makefile.tem Makefile
+case "${enable_shared}" in
+ no | "") SET_LIB_PATH= ;;
+ *) SET_LIB_PATH="\$(REALLY_SET_LIB_PATH)" ;;
+esac
+
+case "${host}" in
+ *-*-hpux*) RPATH_ENVVAR=SHLIB_PATH ;;
+ *) RPATH_ENVVAR=LD_LIBRARY_PATH ;;
+esac
+
+# Record target_configdirs and the configure arguments for target and
+# build configuration in Makefile.
+target_configdirs=`echo "${target_configdirs}" | sed -e 's/target-//g'`
+
+# This is the final value for target_configdirs. configdirs already
+# has its final value, as does build_modules. It's time to create some
+# lists of valid targets.
+
+all_build_modules=
+configure_build_modules=
+for module in ${build_modules} ; do
+ all_build_modules=all-build-${module}
+ configure_build_modules=configure-build-${module}
+done
+
+# Determine whether gdb needs tk/tcl or not.
+# Use 'maybe' since enable_gdbtk might be true even if tk isn't available
+# and in that case we want gdb to be built without tk. Ugh!
+# In fact I believe gdb is the *only* package directly dependent on tk,
+# so we should be able to put the 'maybe's in unconditionally and
+# leave out the maybe dependencies when enable_gdbtk is false. I'm not
+# 100% sure that that's safe though.
+
+gdb_tk="maybe-all-tcl maybe-all-tk maybe-all-itcl maybe-all-tix maybe-all-libgui"
+case "$enable_gdbtk" in
+ no)
+ GDB_TK="" ;;
+ yes)
+ GDB_TK="${gdb_tk}" ;;
+ *)
+ # Only add the dependency on gdbtk when GDBtk is part of the gdb
+ # distro. Eventually someone will fix this and move Insight, nee
+ # gdbtk to a separate directory.
+ if test -d ${srcdir}/gdb/gdbtk ; then
+ GDB_TK="${gdb_tk}"
+ else
+ GDB_TK=""
+ fi
;;
- esac
-fi
+esac
+
+# Create the 'maybe dependencies'. This uses a temporary file.
-# Base args. Strip norecursion, cache-file, srcdir, host, build, target.
-# These are the ones we might not want to pass down to subconfigures.
-baseargs=`echo "${arguments}" | \
- sed -e 's/--no[^ ]*//' \
- -e 's/--cache[a-z-]*=[^ ]*//' \
- -e 's/--sr[a-z-]*=[^ ]*//' \
- -e 's/--ho[a-z-]*=[^ ]*//' \
- -e 's/--bu[a-z-]*=[^ ]*//' \
- -e 's/--ta[a-z-]*=[^ ]*//'`
+# While at that, we remove Makefiles if we were started for recursive
+# configuration, so that the top-level Makefile reconfigures them,
+# like we used to do when configure itself was recursive.
+rm -f maybedep.tmp
+echo '# maybedep.tmp' > maybedep.tmp
+
+# Make-targets which may need maybe dependencies.
+mts="configure all install check clean distclean dvi info install-info"
+mts="${mts} installcheck mostlyclean maintainer-clean TAGS"
+
+# Loop over modules and make-targets.
+for module in ${build_modules} ; do
+ if test -z "${no_recursion}" \
+ && test -f ${build_subdir}/${module}/Makefile; then
+ echo 1>&2 "*** removing ${build_subdir}/${module}/Makefile to force reconfigure"
+ rm -f ${build_subdir}/${module}/Makefile
+ fi
+ for mt in ${mts} ; do
+ case ${mt} in
+ install) ;; # No installing build modules.
+ *) echo "maybe-${mt}-build-${module}: ${mt}-build-${module}" >> maybedep.tmp ;;
+ esac
+ done
+done
+for module in ${configdirs} ; do
+ if test -z "${no_recursion}" \
+ && test -f ${module}/Makefile; then
+ echo 1>&2 "*** removing ${module}/Makefile to force reconfigure"
+ rm -f ${module}/Makefile
+ fi
+ for mt in ${mts} ; do
+ echo "maybe-${mt}-${module}: ${mt}-${module}" >> maybedep.tmp
+ done
+done
+for module in ${target_configdirs} ; do
+ if test -z "${no_recursion}" \
+ && test -f ${target_subdir}/${module}/Makefile; then
+ echo 1>&2 "*** removing ${target_subdir}/${module}/Makefile to force reconfigure"
+ rm -f ${target_subdir}/${module}/Makefile
+ fi
+ for mt in ${mts} ; do
+ echo "maybe-${mt}-target-${module}: ${mt}-target-${module}" >> maybedep.tmp
+ done
+done
+maybe_dependencies=maybedep.tmp
+AC_SUBST_FILE(maybe_dependencies)
+
+# Create the serialization dependencies. This uses a temporary file.
+
+AC_ARG_ENABLE([serial-configure],
+[ --enable-serial-[{host,target,build}-]configure
+ Force sequential configuration of
+ sub-packages for the host, target or build
+ machine, or all sub-packages])
+
+case ${enable_serial_configure} in
+ yes)
+ enable_serial_build_configure=yes
+ enable_serial_host_configure=yes
+ enable_serial_target_configure=yes
+ ;;
+esac
+
+# These force 'configure's to be done one at a time, to avoid problems
+# with contention over a shared config.cache.
+rm -f serdep.tmp
+echo '# serdep.tmp' > serdep.tmp
+olditem=
+test "x${enable_serial_build_configure}" = xyes &&
+for item in ${build_configdirs} ; do
+ case ${olditem} in
+ "") ;;
+ *) echo "configure-build-${item}: configure-build-${olditem}" >> serdep.tmp ;;
+ esac
+ olditem=${item}
+done
+olditem=
+test "x${enable_serial_host_configure}" = xyes &&
+for item in ${configdirs} ; do
+ case ${olditem} in
+ "") ;;
+ *) echo "configure-${item}: configure-${olditem}" >> serdep.tmp ;;
+ esac
+ olditem=${item}
+done
+olditem=
+test "x${enable_serial_target_configure}" = xyes &&
+for item in ${target_configdirs} ; do
+ case ${olditem} in
+ "") ;;
+ *) echo "configure-target-${item}: configure-target-${olditem}" >> serdep.tmp ;;
+ esac
+ olditem=${item}
+done
+serialization_dependencies=serdep.tmp
+AC_SUBST_FILE(serialization_dependencies)
+
+# Base args. Strip norecursion, cache-file, srcdir, host, build,
+# target and nonopt. These are the ones we might not want to pass
+# down to subconfigures. Also strip program-prefix, program-suffix,
+# and program-transform-name, so that we can pass down a consistent
+# program-transform-name. If autoconf has put single quotes around
+# any of these arguments (because they contain shell metacharacters)
+# then this will fail; in practice this only happens for
+# --program-transform-name, so be sure to override --program-transform-name
+# at the end of the argument list.
+# These will be expanded by make, so quote '$'.
+cat <<\EOF_SED > conftestsed
+s/ --no[[^ ]]* / /
+s/ --c[[a-z-]]*[[= ]][[^ ]]* / /
+s/ --sr[[a-z-]]*[[= ]][[^ ]]* / /
+s/ --ho[[a-z-]]*[[= ]][[^ ]]* / /
+s/ --bu[[a-z-]]*[[= ]][[^ ]]* / /
+s/ --t[[a-z-]]*[[= ]][[^ ]]* / /
+s/ --program-[[pst]][[a-z-]]*[[= ]][[^ ]]* / /
+s/ -cache-file[[= ]][[^ ]]* / /
+s/ -srcdir[[= ]][[^ ]]* / /
+s/ -host[[= ]][[^ ]]* / /
+s/ -build[[= ]][[^ ]]* / /
+s/ -target[[= ]][[^ ]]* / /
+s/ -program-prefix[[= ]][[^ ]]* / /
+s/ -program-suffix[[= ]][[^ ]]* / /
+s/ -program-transform-name[[= ]][[^ ]]* / /
+s/ [[^' -][^ ]*] / /
+s/^ *//;s/ *$//
+s,\$,$$,g
+EOF_SED
+sed -f conftestsed <<EOF_SED > conftestsed.out
+ ${ac_configure_args}
+EOF_SED
+baseargs=`cat conftestsed.out`
+rm -f conftestsed conftestsed.out
+
+# Add in --program-transform-name, after --program-prefix and
+# --program-suffix have been applied to it. Autoconf has already
+# doubled dollar signs and backslashes in program_transform_name; we want
+# the backslashes un-doubled, and then the entire thing wrapped in single
+# quotes, because this will be expanded first by make and then by the shell.
+# Also, because we want to override the logic in subdir configure scripts to
+# choose program_transform_name, replace any s,x,x, with s,y,y,.
+sed -e "s,\\\\\\\\,\\\\,g; s,','\\\\'',g; s/s,x,x,/s,y,y,/" <<EOF_SED > conftestsed.out
+${program_transform_name}
+EOF_SED
+gcc_transform_name=`cat conftestsed.out`
+rm -f conftestsed.out
+baseargs="$baseargs --program-transform-name='${gcc_transform_name}'"
# For the build-side libraries, we just need to pretend we're native,
# and not use the same cache file. Multilibs are neither needed nor
# desired.
-buildargs="--cache-file=../config.cache --build=${build_alias} --host=${build_alias} ${baseargs}"
+build_configargs="--cache-file=../config.cache --build=${build_alias} --host=${build_alias} ${baseargs}"
+
+# For host modules, accept cache file option, or specification as blank.
+case "${cache_file}" in
+"") # empty
+ cache_file_option="" ;;
+/* | [[A-Za-z]]:[[\\/]]* ) # absolute path
+ cache_file_option="--cache-file=${cache_file}" ;;
+*) # relative path
+ cache_file_option="--cache-file=../${cache_file}" ;;
+esac
-# Record target_configdirs and the configure arguments for target and
-# build configuration in Makefile.
-target_configdirs=`echo "${target_configdirs}" | sed -e 's/target-//g'`
-targargs=${baseargs}
+# Host dirs don't like to share a cache file either, horribly enough.
+# This seems to be due to autoconf 2.5x stupidity.
+host_configargs="--cache-file=./config.cache --build=${build_alias} --host=${host_alias} --target=${target_alias} ${extra_host_args} ${baseargs}"
+
+target_configargs=${baseargs}
# Passing a --with-cross-host argument lets the target libraries know
# whether they are being built with a cross-compiler or being built
@@ -1372,60 +1846,58 @@ targargs=${baseargs}
# sorts of decisions they want to make on this basis. Please consider
# this option to be deprecated. FIXME.
if test x${is_cross_compiler} = xyes ; then
- targargs="--with-cross-host=${host_alias} ${targargs}"
+ target_configargs="--with-cross-host=${host_alias} ${target_configargs}"
fi
# Default to --enable-multilib.
if test x${enable_multilib} = x ; then
- targargs="--enable-multilib ${targargs}"
+ target_configargs="--enable-multilib ${target_configargs}"
fi
# Pass --with-newlib if appropriate. Note that target_configdirs has
# changed from the earlier setting of with_newlib.
if test x${with_newlib} != xno && echo " ${target_configdirs} " | grep " newlib " > /dev/null 2>&1 && test -d ${srcdir}/newlib ; then
- targargs="--with-newlib ${targargs}"
+ target_configargs="--with-newlib ${target_configargs}"
fi
+# Different target subdirs use different values of certain variables
+# (notably CXX). Worse, multilibs use *lots* of different values.
+# Worse yet, autoconf 2.5x makes some of these 'precious', meaning that
+# it doesn't automatically accept command-line overrides of them.
+# This means it's not safe for target subdirs to share a cache file,
+# which is disgusting, but there you have it. Hopefully this can be
+# fixed in future. It's still worthwhile to use a cache file for each
+# directory. I think.
+
# Pass the appropriate --host, --build, and --cache-file arguments.
-targargs="--cache-file=../config.cache --host=${target_alias} --build=${build_alias} ${targargs}"
+target_configargs="--cache-file=./config.cache --host=${target_alias} --build=${build_alias} ${target_configargs}"
# provide a proper gxx_include_dir.
# Note, if you change the default, make sure to fix both here and in
# the gcc and libstdc++-v3 subdirectories.
# Check whether --with-gxx-include-dir or --without-gxx-include-dir was given.
-gxx_include_dir=
-if test -n "${with_gxx_include_dir}"; then
- case "${with_gxx_include_dir}" in
- yes )
- echo "configure.in: error: bad value ${withval} given for g++ include directory" 1>&2
- exit 1
- ;;
- no )
- ;;
- * )
- gxx_include_dir=${with_gxx_include_dir}
- ;;
- esac
-fi
-if test x${gxx_include_dir} = x; then
- if test x${enable_version_specific_runtime_libs} = xyes; then
- gxx_include_dir='${libsubdir}/include/c++'
- else
- . ${srcdir}/config.if
- gxx_include_dir='${prefix}/include/${libstdcxx_incdir}'
- fi
-else
- gxx_include_dir=${gxx_include_dir}
-fi
+case "${with_gxx_include_dir}" in
+ yes)
+ AC_MSG_ERROR([--with-gxx-include-dir=[[dir]] requires a directory])
+ ;;
+ no | "")
+ case "${enable_version_specific_runtime_libs}" in
+ yes) gxx_include_dir='${libsubdir}/include/c++' ;;
+ *)
+ . ${srcdir}/config.if
+ gxx_include_dir='${prefix}/include/'${libstdcxx_incdir} ;;
+ esac ;;
+ *) gxx_include_dir=${with_gxx_include_dir} ;;
+esac
FLAGS_FOR_TARGET=
case " $target_configdirs " in
*" newlib "*)
- case " $targargs " in
+ case " $target_configargs " in
*" --with-newlib "*)
case "$target" in
*-cygwin*)
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup -L$$r/$(TARGET_SUBDIR)/winsup/cygwin -L$$r/$(TARGET_SUBDIR)/winsup/w32api/lib -isystem $$s/winsup/include -isystem $$s/winsup/cygwin/include -isystem $$s/winsup/w32api/include -isystem $$s/newlib/libc/sys/cygwin -isystem $$s/newlib/libc/sys/cygwin32' ;;
+ FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -L$$r/$(TARGET_SUBDIR)/winsup -L$$r/$(TARGET_SUBDIR)/winsup/cygwin -L$$r/$(TARGET_SUBDIR)/winsup/w32api/lib -isystem $$s/winsup/include -isystem $$s/winsup/cygwin/include -isystem $$s/winsup/w32api/include' ;;
esac
# If we're not building GCC, don't discard standard headers.
@@ -1452,7 +1924,7 @@ case " $target_configdirs " in
fi
case "${target}-${is_cross_compiler}" in
- i[3456]86-*-linux*-no)
+ i[[3456789]]86-*-linux*-no)
# Here host == target, so we don't need to build gcc,
# so we don't want to discard standard headers.
FLAGS_FOR_TARGET=`echo " $FLAGS_FOR_TARGET " | sed -e 's/ -nostdinc / /'`
@@ -1469,13 +1941,17 @@ case " $target_configdirs " in
;;
esac
+# Allow the user to override the flags for
+# our build compiler if desired.
+CFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD-${CFLAGS}}
+
# On Canadian crosses, we'll be searching the right directories for
# the previously-installed cross compiler, so don't bother to add
# flags for directories within the install tree of the compiler
# being built; programs in there won't even run.
if test "${build}" = "${host}" && test -d ${srcdir}/gcc; then
# Search for pre-installed headers if nothing else fits.
- FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$(build_tooldir)/bin/ -B$(build_tooldir)/lib/ -isystem $(build_tooldir)/include'
+ FLAGS_FOR_TARGET=$FLAGS_FOR_TARGET' -B$(build_tooldir)/bin/ -B$(build_tooldir)/lib/ -isystem $(build_tooldir)/include -isystem $(build_tooldir)/sys-include'
fi
if test "x${use_gnu_ld}" = x &&
@@ -1491,14 +1967,9 @@ elif test -d ${srcdir}/gcc; then
elif test "$host" = "$target"; then
CC_FOR_TARGET='$(CC)'
else
- CC_FOR_TARGET=`echo gcc | sed -e 's/x/x/' ${program_transform_name}`
+ CC_FOR_TARGET=`echo gcc | sed "${program_transform_name}"`
fi
-# On Canadian crosses, configure reads CC_FOR_TARGET from Makefile,
-# if Makefile exists. Prevent $(FLAGS_FOR_TARGET) from being duplicated.
-case $CC_FOR_TARGET in
-*' $(FLAGS_FOR_TARGET)') ;;
-*) CC_FOR_TARGET=$CC_FOR_TARGET' $(FLAGS_FOR_TARGET)' ;;
-esac
+CC_FOR_TARGET=$CC_FOR_TARGET' $(FLAGS_FOR_TARGET)'
if test "x${GCJ_FOR_TARGET+set}" = xset; then
:
@@ -1507,33 +1978,38 @@ elif test -d ${srcdir}/gcc; then
elif test "$host" = "$target"; then
GCJ_FOR_TARGET='gcj'
else
- GCJ_FOR_TARGET=`echo gcj | sed -e 's/x/x/' ${program_transform_name}`
+ GCJ_FOR_TARGET=`echo gcj | sed "${program_transform_name}"`
fi
-case $GCJ_FOR_TARGET in
-*' $(FLAGS_FOR_TARGET)') ;;
-*) GCJ_FOR_TARGET=$GCJ_FOR_TARGET' $(FLAGS_FOR_TARGET)' ;;
-esac
+GCJ_FOR_TARGET=$GCJ_FOR_TARGET' $(FLAGS_FOR_TARGET)'
# Don't use libstdc++-v3's flags to configure/build itself.
-libstdcxx_flags='`case $$dir in libstdc++-v3 | libjava) ;; *) test ! -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/testsuite_flags || $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/testsuite_flags --build-includes;; esac` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs'
+libstdcxx_flags='`test ! -f $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags || $(SHELL) $$r/$(TARGET_SUBDIR)/libstdc++-v3/scripts/testsuite_flags --build-includes` -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs'
+raw_libstdcxx_flags='-L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src -L$$r/$(TARGET_SUBDIR)/libstdc++-v3/src/.libs'
if test "x${CXX_FOR_TARGET+set}" = xset; then
- :
+ if test "x${RAW_CXX_FOR_TARGET+set}" != xset; then
+ RAW_CXX_FOR_TARGET=${CXX_FOR_TARGET}
+ fi
elif test -d ${srcdir}/gcc; then
# We add -shared-libgcc to CXX_FOR_TARGET whenever we use xgcc instead
# of g++ for linking C++ or Java, because g++ has -shared-libgcc by
# default whereas gcc does not.
- CXX_FOR_TARGET='$$r/gcc/`case $$dir in libstdc++-v3 | libjava) echo xgcc -shared-libgcc ;; *) echo g++ ;; esac` -B$$r/gcc/ -nostdinc++ '$libstdcxx_flags
+ # RAW_CXX_FOR_TARGET is for linking C++ or java; CXX_FOR_TARGET is for
+ # all other cases.
+ CXX_FOR_TARGET='$$r/gcc/g++ -B$$r/gcc/ -nostdinc++ '$libstdcxx_flags
+ RAW_CXX_FOR_TARGET='$$r/gcc/xgcc -shared-libgcc -B$$r/gcc/ -nostdinc++ '$raw_libstdcxx_flags
elif test "$host" = "$target"; then
CXX_FOR_TARGET='$(CXX)'
+ RAW_CXX_FOR_TARGET=${CXX_FOR_TARGET}
else
- CXX_FOR_TARGET=`echo c++ | sed -e 's/x/x/' ${program_transform_name}`
+ CXX_FOR_TARGET=`echo c++ | sed "${program_transform_name}"`
+ RAW_CXX_FOR_TARGET=${CXX_FOR_TARGET}
fi
-case $CXX_FOR_TARGET in
-*' $(FLAGS_FOR_TARGET)') ;;
-*) CXX_FOR_TARGET=$CXX_FOR_TARGET' $(FLAGS_FOR_TARGET)' ;;
-esac
-qCXX_FOR_TARGET=`echo "$CXX_FOR_TARGET" | sed 's,[&%],\\\&,g'`
+CXX_FOR_TARGET=$CXX_FOR_TARGET' $(FLAGS_FOR_TARGET)'
+RAW_CXX_FOR_TARGET=$RAW_CXX_FOR_TARGET' $(FLAGS_FOR_TARGET)'
+
+qCXX_FOR_TARGET=`echo "$CXX_FOR_TARGET" | sed 's,[[&%]],\\\&,g'`
+qRAW_CXX_FOR_TARGET=`echo "$RAW_CXX_FOR_TARGET" | sed 's,[[&%]],\\\&,g'`
# We want to defer the evaluation of `cmd`s and shell variables in
# CXX_FOR_TARGET when recursing in the top-level Makefile, such as for
@@ -1541,28 +2017,137 @@ qCXX_FOR_TARGET=`echo "$CXX_FOR_TARGET" | sed 's,[&%],\\\&,g'`
# quotes, but we still have to duplicate `$'s so that shell variables
# can be expanded by the nested make as shell variables, not as make
# macros.
-qqCXX_FOR_TARGET=`echo "$qCXX_FOR_TARGET" | sed -e 's,[$][$],$$$$,g'`
-
-sedtemp=sed.$$
-cat >$sedtemp <<EOF
-s:^TARGET_CONFIGDIRS[ ]*=.*$:TARGET_CONFIGDIRS = ${target_configdirs}:
-s%^TARGET_CONFIGARGS[ ]*=.*$%TARGET_CONFIGARGS = ${targargs}%
-s%^FLAGS_FOR_TARGET[ ]*=.*$%FLAGS_FOR_TARGET = ${FLAGS_FOR_TARGET}%
-s%^CC_FOR_TARGET[ ]*=.*$%CC_FOR_TARGET = ${CC_FOR_TARGET}%
-s%^GCJ_FOR_TARGET[ ]*=.*$%GCJ_FOR_TARGET = ${GCJ_FOR_TARGET}%
-s%^CXX_FOR_TARGET[ ]*=.*$%CXX_FOR_TARGET = ${qCXX_FOR_TARGET}%
-s%^CXX_FOR_TARGET_FOR_RECURSIVE_MAKE[ ]*=.*$%CXX_FOR_TARGET_FOR_RECURSIVE_MAKE = ${qqCXX_FOR_TARGET}%
-s%^TARGET_SUBDIR[ ]*=.*$%TARGET_SUBDIR = ${target_subdir}%
-s%^BUILD_SUBDIR[ ]*=.*$%BUILD_SUBDIR = ${build_subdir}%
-s%^BUILD_CONFIGARGS[ ]*=.*$%BUILD_CONFIGARGS = ${buildargs}%
-s%^gxx_include_dir[ ]*=.*$%gxx_include_dir=${gxx_include_dir}%
-EOF
-sed -f $sedtemp Makefile > Makefile.tem
-rm -f Makefile $sedtemp
-mv -f Makefile.tem Makefile
+qqCXX_FOR_TARGET=`echo "$qCXX_FOR_TARGET" | sed -e 's,[[$]][[$]],$$$$,g'`
+qqRAW_CXX_FOR_TARGET=`echo "$qRAW_CXX_FOR_TARGET" | sed -e 's,[[$]][[$]],$$$$,g'`
+
+# Wrap CC_FOR_TARGET and friends, for certain types of builds.
+CC_FOR_TARGET="\$(STAGE_CC_WRAPPER) ${CC_FOR_TARGET}"
+GCJ_FOR_TARGET="\$(STAGE_CC_WRAPPER) ${GCJ_FOR_TARGET}"
+CXX_FOR_TARGET="\$(STAGE_CC_WRAPPER) ${qCXX_FOR_TARGET}"
+RAW_CXX_FOR_TARGET="\$(STAGE_CC_WRAPPER) ${qRAW_CXX_FOR_TARGET}"
+CXX_FOR_TARGET_FOR_RECURSIVE_MAKE="\$(STAGE_CC_WRAPPER) ${qqCXX_FOR_TARGET}"
+RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE="\$(STAGE_CC_WRAPPER) ${qqRAW_CXX_FOR_TARGET}"
+
+# Makefile fragments.
+host_makefile_frag=${srcdir}/${host_makefile_frag}
+target_makefile_frag=${srcdir}/${target_makefile_frag}
+alphaieee_frag=${srcdir}/${alphaieee_frag}
+ospace_frag=${srcdir}/${ospace_frag}
+AC_SUBST_FILE(host_makefile_frag)
+AC_SUBST_FILE(target_makefile_frag)
+AC_SUBST_FILE(alphaieee_frag)
+AC_SUBST_FILE(ospace_frag)
+
+# Miscellanea: directories, flags, etc.
+AC_SUBST(SET_LIB_PATH)
+AC_SUBST(RPATH_ENVVAR)
+AC_SUBST(BUILD_PREFIX)
+AC_SUBST(BUILD_PREFIX_1)
+AC_SUBST(configlinks)
+AC_SUBST(gcc_version_trigger)
+AC_SUBST(gcc_version)
+AC_SUBST(tooldir)
+AC_SUBST(build_tooldir)
+AC_SUBST(GDB_TK)
+AC_SUBST(gxx_include_dir)
+AC_SUBST(libstdcxx_incdir)
+
+# Build module lists & subconfigure args.
+AC_SUBST(build_configargs)
+AC_SUBST(configure_build_modules)
+AC_SUBST(all_build_modules)
+
+# Host module lists & subconfigure args.
+AC_SUBST(host_configargs)
+AC_SUBST(configdirs)
+
+# Target module lists & subconfigure args.
+AC_SUBST(target_configargs)
+AC_SUBST(target_configdirs)
+
+# Build tools.
+AC_SUBST(BISON)
+AC_SUBST(CC_FOR_BUILD)
+AC_SUBST(LEX)
+AC_SUBST(MAKEINFO)
+AC_SUBST(YACC)
+AC_SUBST(config_shell)
+
+# Host tools.
+NCN_STRICT_CHECK_TOOL(AR, ar)
+NCN_STRICT_CHECK_TOOL(AS, as)
+NCN_STRICT_CHECK_TOOL(DLLTOOL, dlltool)
+NCN_STRICT_CHECK_TOOL(LD, ld)
+NCN_STRICT_CHECK_TOOL(NM, nm)
+NCN_STRICT_CHECK_TOOL(RANLIB, ranlib, :)
+NCN_STRICT_CHECK_TOOL(WINDRES, windres)
+NCN_STRICT_CHECK_TOOL(OBJCOPY, objcopy)
+NCN_STRICT_CHECK_TOOL(OBJDUMP, objdump)
+AC_SUBST(CC)
+AC_SUBST(CXX)
+AC_SUBST(CFLAGS)
+AC_SUBST(CFLAGS_FOR_BUILD)
+AC_SUBST(CXXFLAGS)
+AC_SUBST(DEFAULT_YACC)
+AC_SUBST(DEFAULT_LEX)
+AC_SUBST(DEFAULT_M4)
+
+# Target tools.
+NCN_STRICT_CHECK_TARGET_TOOL(AR_FOR_TARGET, ar)
+NCN_STRICT_CHECK_TARGET_TOOL(AS_FOR_TARGET, as)
+NCN_STRICT_CHECK_TARGET_TOOL(DLLTOOL_FOR_TARGET, dlltool)
+NCN_STRICT_CHECK_TARGET_TOOL(LD_FOR_TARGET, ld)
+NCN_STRICT_CHECK_TARGET_TOOL(NM_FOR_TARGET, nm)
+NCN_STRICT_CHECK_TARGET_TOOL(RANLIB_FOR_TARGET, ranlib, :)
+NCN_STRICT_CHECK_TARGET_TOOL(WINDRES_FOR_TARGET, windres)
+
+AC_SUBST(GCC_FOR_TARGET)
+AC_SUBST(FLAGS_FOR_TARGET)
+AC_SUBST(CC_FOR_TARGET)
+AC_SUBST(GCJ_FOR_TARGET)
+AC_SUBST(CXX_FOR_TARGET)
+AC_SUBST(RAW_CXX_FOR_TARGET)
+AC_SUBST(CXX_FOR_TARGET_FOR_RECURSIVE_MAKE)
+AC_SUBST(RAW_CXX_FOR_TARGET_FOR_RECURSIVE_MAKE)
+
+# Fix up target tools.
+if test "x${build}" = "x${host}" ; then
+ # In this case, the newly built tools can and should be used,
+ # so we override the results of the autoconf tests.
+ # This should really only happen when the tools are actually being built,
+ # but that's a further refinement. The new build scheme, where
+ # tools are built into a structure paralleling where they're installed,
+ # should also eliminate all of this cleanly.
+ AR_FOR_TARGET="\$(USUAL_AR_FOR_TARGET)"
+ AS_FOR_TARGET="\$(USUAL_AS_FOR_TARGET)"
+ DLLTOOL_FOR_TARGET="\$(USUAL_DLLTOOL_FOR_TARGET)"
+ LD_FOR_TARGET="\$(USUAL_LD_FOR_TARGET)"
+ NM_FOR_TARGET="\$(USUAL_NM_FOR_TARGET)"
+ RANLIB_FOR_TARGET="\$(USUAL_RANLIB_FOR_TARGET)"
+ WINDRES_FOR_TARGET="\$(USUAL_WINDRES_FOR_TARGET)"
+fi
+# Certain tools may need extra flags.
+AR_FOR_TARGET=${AR_FOR_TARGET}${extra_arflags_for_target}
+RANLIB_FOR_TARGET=${RANLIB_FOR_TARGET}${extra_ranlibflags_for_target}
+NM_FOR_TARGET=${NM_FOR_TARGET}${extra_nmflags_for_target}
+
+AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
+AC_ARG_ENABLE(maintainer-mode,
+[ --enable-maintainer-mode enable make rules and dependencies not useful
+ (and sometimes confusing) to the casual installer],
+ USE_MAINTAINER_MODE=$enableval,
+ USE_MAINTAINER_MODE=no)
+AC_MSG_RESULT($USE_MAINTAINER_MODE)
+AC_SUBST(MAINTAINER_MODE_TRUE)
+AC_SUBST(MAINTAINER_MODE_FALSE)
+if test "$USE_MAINTAINER_MODE" = yes; then
+ MAINTAINER_MODE_TRUE=
+ MAINTAINER_MODE_FALSE='#'
+else
+ MAINTAINER_MODE_TRUE='#'
+ MAINTAINER_MODE_FALSE=
+fi
+MAINT=$MAINTAINER_MODE_TRUE
+AC_SUBST(MAINT)dnl
-#
-# Local Variables:
-# fill-column: 131
-# End:
-#
+AC_OUTPUT(Makefile)
diff --git a/contrib/binutils/gas/CONTRIBUTORS b/contrib/binutils/gas/CONTRIBUTORS
index 68d11dc..d564ba8 100644
--- a/contrib/binutils/gas/CONTRIBUTORS
+++ b/contrib/binutils/gas/CONTRIBUTORS
@@ -30,9 +30,8 @@ sparc opcode file rewrite, decstation, rs6000, and hp300hpux host
ports, updated "know" assertions and made them work, much other
reorganization, cleanup, and lint.
-Ken Raeburn currently maintains gas, and wrote the high-level BFD
-interface code to replace most of the code in format-specific I/O
-modules.
+Ken Raeburn wrote the high-level BFD interface code to replace most of
+the code in format-specific I/O modules.
The original Vax-VMS support was contributed by David L. Kashtan.
Eric Youngdale and Pat Rankin have done much work with it since.
diff --git a/contrib/binutils/gas/ChangeLog b/contrib/binutils/gas/ChangeLog
index 94223d0..df93f2a 100644
--- a/contrib/binutils/gas/ChangeLog
+++ b/contrib/binutils/gas/ChangeLog
@@ -1,2642 +1,608 @@
-2002-11-20 Alan Modra <amodra@bigpond.net.au>
+2004-05-23 Alan Modra <amodra@bigpond.net.au>
- * write.c (adjust_reloc_syms): Don't reduce SEC_MERGE fixups with
- fx_subsy non-NULL.
+ * expr.c (operand, operator): Don't reject '++' and '--'.
-2002-11-19 Richard Henderson <rth@redhat.com>
+2004-05-13 Joel Sherrill <joel@oarcorp.com>
- * config/obj-elf.c (obj_elf_visibility): Overwrite only the
- visibility portion of st_other.
-
-2002-11-19 Luke Deller <luked@cse.unsw.edu.au>
-
- * config/tc-alpha.c (s_alpha_prologue): as_bad when sym is NULL.
-
-2002-11-13 Alan Modra <amodra@bigpond.net.au>
-
- Merge from mainline.
- 2002-09-04 Alan Modra <amodra@bigpond.net.au>
- * config/tc-ppc.c (PPC_HIGHER, PPC_HIGHEST): Fix warning.
- (md_parse_option): No -a64 without BFD64.
- (ppc_set_cpu): Select appropriate cpu when ppc_obj64.
- (ppc_arch): Use bfd_mach_rs6k for bfd_arch_rs6000.
-
-2002-11-06 Richard Henderson <rth@redhat.com>
-
- * config/tc-alpha.c (alpha_validate_fix): Move code ...
- (alpha_fix_adjustable): ... here.
- * config/tc-alpha.h (TC_VALIDATE_FIX): Remove.
-
-2002-11-05 H.J. Lu <hjl@gnu.org>
-
- * config/tc-mips.c (support_64bit_objects): Check *l before it
- is freed.
-
-2002-10-31 David O'Brien <obrien@FreeBSD.org>
-
- * config/tc-ia64.c: Cast dwarf2_directive_file to int.
- * config/tc-sparc.c: Likewise.
- * config/tc-alpha.c: Cast s_alpha_file to int.
- * config/tc-alpha.h (TC_INIT_FIX_DATA): info is of type struct
- alpha_reloc_tag.
-
-2002-10-30 Daniel Jacobowitz <drow@mvista.com>
-
- * configure.in: Update ARM CPU patterns.
- * configure: Regenerated.
-
-2002-10-30 Daniel Jacobowitz <drow@mvista.com>
-
- * po/gas.pot: Regenerated.
-
-2002-10-29 Daniel Jacobowitz <drow@mvista.com>
-
- * itbl-lex.l: Use #include <> for generated headers.
- * itbl-ops.c: Likewise.
-
-2002-08-24 Andreas Schwab <schwab@suse.de>
-
- * config/tc-m68k.c (tc_m68k_fix_adjustable): Don't adjust symbols
- in merge sections.
-
-2002-10-28 Daniel Jacobowitz <drow@mvista.com>
-
- * doc/gasp.texi: Fix typo in last typo fix.
-
-2002-10-28 Daniel Jacobowitz <drow@mvista.com>
-
- Merge from mainline:
- 2002-10-21 Richard Sandiford <rsandifo@redhat.com>
- * config/tc-mips.c (mips_need_elf_addend_fixup): Return true
- for relocs against symbols in a merged section.
-
- Thu Oct 10 14:31:30 2002 J"orn Rennecke <joern.rennecke@superh.com>
- * config/tc-sh.c (assemble_ppi): Initialize reg_x / reg_y / reg_n
- inside loop.
-
-2002-10-17 Johannes Stezenbach <js@convergence.de>
-
- * itbl-parse.y (entry): Provide empty action.
-
-2002-10-14 Momchil Velikov <velco@fadata.bg>
-
- * config/tc-v850.c (CHECK_): Remove token pasting operator.
-
-2002-10-11 David O'Brien <obrien@FreeBSD.org>
-
- * gas/gasp.texi: Fix typo in noting that gasp is now deprecated.
-
-2002-10-11 Michel Six <msix@ccr.jussieu.fr>
- Alan Modra <amodra@bigpond.net.au>
-
- * config/tc-i386.c (output_jump): Set fx_signed for loop/jcxz.
- (md_estimate_size_before_relax): Likewise for 8 bit branches.
-
-2002-09-24 Alan Modra <amodra@bigpond.net.au>
-
- * config/tc-i386.c (process_operands): Warn about "lea" segment
- overrides.
-
-2002-09-23 Daniel Jacobowitz <drow@mvista.com>
-
- Merge from mainline:
- 2002-09-22 Mark Elbrecht <snowball3@softhome.net>
- * write.c: Delete set_segment_vma and prototype. Update all callers.
-
- 2002-09-19 Jakub Jelinek <jakub@redhat.com>
- * config/tc-i386.c (tc_i386_fix_adjustable): Handle
- BFD_RELOC_386_TLS_IE and BFD_RELOC_386_TLS_GOTIE.
- (BFD_RELOC_386_TLS_IE, BFD_RELOC_386_TLS_GOTIE): Define to 0
- if not defined.
- (lex_got): Handle @GOTNTPOFF and @INDNTPOFF.
- (md_apply_fix3, tc_gen_reloc): Handle BFD_RELOC_386_TLS_IE and
- BFD_RELOC_386_TLS_GOTIE.
-
- 2002-09-16 Chris Demetriou <cgd@broadcom.com>
- * config/tc-mips.c (IS_SEXT_32BIT_NUM): Move closer to top of file.
- (IS_SEXT_16BIT_NUM): New macro.
- (macro_build_ldst_constoffset): New function, to build a set of
- instructions to do a load or store from a constant offset relative
- to a given register.
- (macro, s_cprestore): Use macro_build_ldst_constoffset to implement
- .cprestore pseudo-op.
-
- 2002-09-16 Elias Athanasopoulos <eathan@otenet.gr>
- * dwarf2dbg.c (out_debug_abbrev): Add support for the DW_AT_name field.
- (out_debug_info): Likewise.
-
- 2002-09-13 Nick Clifton <nickc@redhat.com>
- * config/tc-ppc.c (md_assemble): Do not count FAKE operands
- when deciding if any operands have been skipped.
-
- 2002-09-11 Jakub Jelinek <jakub@redhat.com>
- * config/tc-i386.c (md_apply_fix3): Allow addend for
- BFD_RELOC_386_TLS_LDO_32, BFD_RELOC_386_TLS_LE and
- BFD_RELOC_386_TLS_LE_32.
-
- 2002-09-11 Nick Clifton <nickc@redhat.com>
- * po/tr.po: Updated Turkish translation.
-
- 2002-09-04 Nick Clifton <nickc@redhat.com>
- * config/tc-ppc.c (md_begin): Do not insert non-BookE32
- instructions into the hash table if the target cpu is the BookE32.
-
- 2002-08-20 Richard Sandiford <rsandifo@redhat.com>
- * config/tc-mips.c (macro2): Implement rotates by zero using shifts
- by zero.
-
- 2002-08-15 Alexandre Oliva <aoliva@redhat.com>
- * config/tc-mips.c (macro_build_jalr): Make sure we generate
- the fix-up against on the right frag.
- (s_cpsetup): Likewise. Parse third argument as expression, to
- handle global symbols and forward/backward labels correctly.
-
- 2002-08-14 Nick Clifton <nickc@redhat.com>
- * read.c (stringer): Catch attempts to create strings in the abs
- section.
-
- 2002-08-12 Richard Sandiford <rsandifo@redhat.com>
- * config/tc-mips.c (mips_ip): Don't work out the value of
- constant %hi()s here.
-
- 2002-08-10 Alan Modra <amodra@bigpond.net.au>
- * config/tc-i386.c (tc_i386_fix_adjustable): Test OUTPUT_FLAVOR
- for ELF, and don't bother checking ELF relocs when non-ELF.
- (i386_immediate): Allow absolute_section expressions for aout.
- (i386_displacement): Likewise. Also test bfd_is_com_section.
- (md_estimate_size_before_relax): Test OUTPUT_FLAVOR for ELF.
- (md_apply_fix3): Hack for bfd_install_relocation when fx_pcrel,
- not when fx_addsy. Remove dead code.
-
- 2002-08-06 George France <france@handhelds.org>
- * config/tc-alpha.c (cpu_types): Enabled ev67, ev68, -m21264a
- and m21264b processor names and cpu types.
- * doc/c-alpha.texi: Documented new types.
-
- 2002-08-06 Alan Modra <amodra@bigpond.net.au>
- * config/tc-ppc.c (md_apply_fix3): Adjust 16 bit XCOFF reloc offset.
-
- 2002-08-03 Jakub Jelinek <jakub@redhat.com>
- * config/tc-i386.c (output_insn): Save frag_now and frag_now_fix ()
- at start of insn, pass it to output_disp and output_imm.
- (output_disp): Added arguments. If _GLOBAL_OFFSET_TABLE_ is seen
- in displacement for R_386_32 reloc, use R_386_GOTPC and compute
- properly addend.
- (output_imm): Added arguments. Compute properly addend for
- R_386_GOTPC.
- (md_apply_fix3): Remove R_386_GOTPC handling.
-
- 2002-07-31 Momchil Velikov <velco@fadata.bg>
- * config/tc-v850.c (md_assemble): Fix range check for immediate
- operand.
-
- 2002-07-04 Bruno Haible <bruno@clisp.org>
- * config/tc-i386.h (ELF_TARGET_FORMAT): New macro.
- (TARGET_FORMAT): Use ELF_TARGET_FORMAT instead of "elf32-i386".
- * config/tc-i386.c (i386_target_format): Likewise.
- * config/tc-alpha.h (ELF_TARGET_FORMAT): New macro.
- (TARGET_FORMAT): Use ELF_TARGET_FORMAT instead of "elf64-alpha".
-
-2002-08-26 Alan Modra <amodra@bigpond.net.au>
-
- * config/tc-w65.c (md_section_align): Fix typo.
- (md_parse_option): Return 0, not 1.
-
-2002-08-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
-
- * config/tc-mips.c (macro): Handle a register plus a 16-bit
- immediate offset in "dla" and "la" expansions.
-
-2002-08-01 Daniel Jacobowitz <drow@mvista.com>
-
- Merge from mainline:
- 2002-08-01 Richard Sandiford <rsandifo@redhat.com>
- * config/tc-mips.c (tc_gen_reloc): Extend GP-relative addend
- handling to BFD_RELOC_MIPS16_GPREL.
-
-2002-08-01 H.J. Lu <hjl@gnu.org>
- Daniel Jacobowitz <drow@mvista.com>
-
- * dwarf2dbg.c (dwarf2_finish): Don't emit unreferenced
- .debug_line section unless it has line information.
-
-2002-07-31 Daniel Jacobowitz <drow@mvista.com>
-
- Merge from mainline:
- 2002-07-30 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
- * tc-mips.c (load_address): Don't clobber $at when loading a
- 64-bit address in non-PIC code if noat is in effect.
- (macro): Likewise.
-
- 2002-07-30 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
- * config/tc-mips.c (macro): Use codes 6 and 7 in trap instructions
- used in division/multiply macro expansions similarly to how they
- are used in the variants with break instructions.
- (macro2): Likewise.
-
-2002-07-26 Alan Modra <amodra@bigpond.net.au>
-
- * config/tc-ppc.c (ppc_set_cpu): Use PPC_OPCODE_64 as the default
- rather than PPC_OPCODE_32 for powerpc64*.
-
-2002-07-25 Nick Clifton <nickc@redhat.com>
-
- * po/es.po: Updated Spanish translation.
- * po/fr.po: Updated French translation.
-
-2002-07-24 Nick Clifton <nickc@redhat.com>
-
- * po/sv.po: Updated Swedish translation.
- * po/es.po: Updated Spanish translation.
-
-2002-07-23 Daniel Jacobowitz <drow@mvista.com>
-
- * po/gas.pot: Regenerated.
-
-2002-07-23 Nick Clifton <nickc@redhat.com>
-
- * po/fr.po: Updated French translation.
-
-2002-07-16 Moritz Jodeit <moritz@jodeit.org>
-
- * config/tc-z8k.c (build_bytes): Correct order of memset args.
-
-2002-07-16 Nick Clifton <nickc@cambridge.redhat.com>
-
- * NEWS: Add 'Changes in 2.13'.
-
-2002-07-15 Matt Fredette <fredette@netbsd.org>
-
- * config/tc-hppa.h (LABELS_WITHOUT_COLONS): Define if TE_NetBSD.
-
-2002-07-12 Alan Modra <amodra@bigpond.net.au>
-
- * config/tc-i386.c (process_suffix): Merge CODE_64BIT JumpByte
- case with non CODE_64BIT case. Don't warn on "qword ptr" if
- not CODE_64BIT.
-
-2002-07-11 Alan Modra <amodra@bigpond.net.au>
-
- * config/tc-ppc.c (ppc_elf_frob_symbol): Delete.
- (ppc_frob_file_before_adjust): New function.
- * config/tc-ppc.h (tc_frob_symbol): Don't define.
- (ppc_elf_frob_symbol): Don't declare.
- (tc_frob_file_before_adjust): Define.
- (ppc_frob_file_before_adjust): Declare.
-
- * config/tc-ppc.c (md_pseudo_table): Warning fix.
- (ppc_cpu): Make it unsigned long to agree with struct powerpc_opcode
- flags.
- (ppc_size): Delete.
- (ppc_xcoff64): Rename to ppc_obj64.
- (md_parse_option <m>): Encode old ppc_size value in ppc_cpu.
- (ppc_set_cpu): Set PPC_OPCODE_32 too.
- (ppc_arch): Use ppc_obj64 instead of ppc_size to select bfd_mach_ppc64
- or bfd_mach_ppc.
- (ppc_target_format): Use ppc_obj64 to select format.
- (md_begin): Adjust for PPC_OPCODE_32/64 in ppc_cpu.
- (ppc_insert_operand): Use ppc_obj64 instead of ppc_size.
- (ppc_elf_suffix): Likewise. Don't depend on BFD_DEFAULT_TARGET_SIZE.
- (tc_frob_symbol): Likewise.
- (md_assemble): Use ppc_obj64 instead of ppc_size. Don't depend on
- BFD_DEFAULT_TARGET_SIZE.
- (ppc_tc): Likewise.
- (ppc_is_toc_sym): Likewise.
- (md_apply_fix3): Likewise.
- * config/tc-ppc.h (TC_FORCE_RELOCATION): Don't depend on
- BFD_DEFAULT_TARGET_SIZE.
- (ELF_TC_SPECIAL_SECTIONS): Likewise.
- (tc_frob_symbol): Likewise.
-
-2002-07-09 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (macro_build): Handle MIPS16 insns.
- (mips_ip): Likewise.
-
-2002-07-09 Alan Modra <amodra@bigpond.net.au>
-
- * config/tc-i386.c (md_pseudo_table <file>): Warning fix.
- (BFD_RELOC_8, BFD_RELOC_8_PCREL): Define for non-BFD.
- (md_apply_fix3): Formatting. Remove redundant test.
- (tc_gen_reloc): Remove redundant code.
- (tc_i386_force_relocation): Delete. Movy body of function to..
- * config/tc-i386.h (TC_FORCE_RELOCATION): .. here.
-
-2002-07-09 Federico G. Schwindt <fgsch@olimpo.com.br>
-
- * configure.in: Add hppa-*-openbsd* target, change
- alpha*-*-openbsd* format to elf, and use elf for sparc-*-openbsd*
- with sparc64 cpu.
+ * configure.in (or32-*-rtems*): Switch to elf.
* configure: Regenerate.
-2002-07-08 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
-
- * config/tc-mips.c (macro): Shift the 32-bit address range
- accessible with a lone "lui" down by 32768.
-
-2002-07-08 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
-
- * config/tc-mips.c (load_address): Use non-trapping "daddu"
- instead of "dadd" in address calculations.
- (macro): Likewise.
-
-2002-07-08 Alan Modra <amodra@bigpond.net.au>
-
- * config/tc-i386.c (process_suffix): Remove intel mode movsx and
- movzx fudges.
- (md_assemble): Instead, zap the suffix here.
-
-2002-07-03 Nick Clifton <nickc@cambridge.redhat.com>
-
- * NEWS: Remove next release number until the release is actually
- upon us.
-
-2002-07-03 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am (check-DEJAGNU): Revert 2002-06-25 change.
- Run "make dep-am".
- * Makefile.in: Regenerate.
-
-2002-07-02 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * config/tc-s390.c (tc_s390_fix_adjustable): Prevent any adjustment
- to symbols in merge sections, even non pc-relative ones.
-
-2002-06-29 Stephane Carrez <stcarrez@nerim.fr>
-
- * config/tc-m68hc11.h (m68hc11_listing_header): Fix warning.
+2004-05-13 Nick Clifton <nickc@redhat.com>
-2002-06-29 Stephane Carrez <stcarrez@nerim.fr>
-
- * config/tc-m68hc11.h (ELF_TC_SPECIAL_SECTIONS): New sections
- .softregs and .eeprom.
-
-2002-06-28 David O'Brien <obrien@FreeBSD.org>
-
- * NEWS: Note the next release is 2.13.
-
-2002-06-26 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/tr.po: New translation imported.
-
-2002-06-26 Elias Athanasopoulos <eathan@otenet.gr>
-
- * ecoff.c: (get_tag): Replace strcpy with xstrdup.
- (ecoff_directive_def): Likewise.
- (ecoff_directive_tag): Likewise.
- * listing.c (file_info): Likewise.
- * hash.c (what): Likewise.
-
-2002-06-25 H.J. Lu <hjl@gnu.org>
-
- * Makefile.am (check-DEJAGNU): Set LC_ALL=C and export it.
- * Makefile.in: Regenerated.
-
-2002-06-19 Dhananjay R. Deshpande <dhananjayd@kpit.com>
-
- * config/tc-sh.c (get_specific): Revert 2002-05-01 change.
- (assemble_ppi): Generate warning if the same register is used
- twice as destination in the same padd / pmuls instruction.
-
-2002-06-18 Dave Brolley <brolley@redhat.com>
-
- From Catherine Moore, Michael Meissner, Richard Sandiford, Dave Brolley
- * po/POTFILES.in: Add tc-frv.c, tc-frv.h.
- * configure.in: Support frv-*-*.
- * Makefile.am (CPU_TYPES): Add frv.
- (TARGET_CPU_CFILES): Add tc-frv.c.
- (TARGET_CPU_HFILES): Add tc-frv.h.
- (DEPTC_frv_coff): New variable.
- (DEPTC_frv_elf): New variable.
- (DEPOBJ_frv_coff): New variable.
- (DEPOBJ_frv_elf): New variable.
- (DEP_frv_coff): New variable.
- (DEP_frv_elf): New variable.
- * tc-frv.c: New file.
- * tc-frv.h: New file.
-
-2002-06-17 Catherine Moore <clm@redhat.com>
-
- * config/obj-elf.h (TARGET_SYMBOL_FIELDS): Conditionally define.
-
-2002-06-17 J"orn Rennecke <joern.rennecke@superh.com>
-
- * config/tc-sh.c (assemble_ppi): Initialize reg_n.
-
-2002-06-17 Tom Rix <trix@redhat.com>
-
- * config/tc-i370.h (tc_comment_chars): Define for i370-elf.
-
-2002-06-14 H.J. Lu <hjl@gnu.org>
- Daniel Jacobowitz <drow@mvista.com>
-
- * dwarf2dbg.h (dwarf2_directive_file): Return char *.
- * dwarf2dbg.c (dwarf2_directive_file): Return filename.
- * config/tc-mips.c (s_mips_file): Call s_app_file_string
- and new_logical_line for the first .file directive.
- * read.c (s_app_file_string): New function.
- (s_app_file): Call it.
- * read.h (s_app_file_string): Add declaration.
-
-2002-06-14 Daniel Jacobowitz <drow@mvista.com>
-
- * configure.in: Remove MIPS_STABS_ELF.
- * configure: Regenerated.
- * config.in: Regenerated.
- * config/obj-elf.h (ECOFF_DEBUGGING): Define to mips_flag_mdebug
- for MIPS targets.
- * config/tc-mips.c (mips_pseudo_table): Remove #ifdef around
- ".extern".
- (pdr_seg): Declare unconditionally.
- (md_begin): Always generate .pdr unless ECOFF_DEBUGGING or not ELF.
- (s_mips_end): Likewise. Generate stabs function markers.
- (s_mips_ent): Generate stabs function markers.
- (s_mips_frame): Always generate .pdr unless ECOFF_DEBUGGING or not
- ELF.
- (s_mips_mask): Likewise.
- (mips_flag_mdebug): New.
- (md_longopts): Add "mdebug" and "no-mdebug".
- (md_parse_options): Add OPTION_MDEBUG and OPTION_NO_MDEBUG.
- (mips_after_parse_args): Set mips_flag_mdebug.
- * doc/as.texinfo: Add "-mdebug" and "-no-mdebug" for MIPS.
-
-2002-06-13 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
-
- * config/tc-mips.c (md_apply_fix3): Don't subtract the symbol's
- value twice for RELA relocations.
-
-2002-06-12 Ben Elliston <bje@redhat.com>
-
- * symbols.c (resolve_symbol_value): Initialise final_val.
-
- * subsegs.c (subsegs_print_statistics): Cast frchp to void *.
-
-2002-06-11 Tom Rix <trix@redhat.com>
-
- * config/tc-ppc.c (ppc_subseg_align): Delete.
- (ppc_change_csect): Default csect align is 2.
- * config/tc-ppc.h (SUB_SEGMENT_ALIGN): Delete
-
-2002-06-09 Marek Michalkiewicz <marekm@amelek.gda.pl>
-
- * config/tc-avr.c (mcu_types): Update.
-
-2002-06-08 Matt Thomas <matt@3am-software.com>
-
- * configure.in (vax-*-netbsdelf*, vax-*-netbsdaout*)
- (vax-*-netbsd*): New targets.
- * configure: Regenerate.
- * config/aout_gnu.h (enum machine_type): Add M_VAX4K_NETBSD.
- * config/tc-vax.c: Add support for ELF and PIC.
- (flag_want_pic): New flag.
- (float_cons): Fix prototype.
- (md_apply_fix3): Adjust for BFD_ASSEMBLER.
- (md_assemble): Introduce a new is_absolute local, and use it
- rather than repeating the test. Make fatal errors actually
- fatal by using as_fatal as appropriate. Adjust for BFD_ASSEMBLER.
- Add support for ELF. Add support for PIC.
- (md_convert_frag): Adjust for BFD_ASSEMBLER.
- (tc_aout_fix_to_chars): Only include if OBJ_AOUT and not
- BFD_ASSEMBLER.
- (vax_reg_parse): Make the % register prefix mandatory for ELF,
- optional for a.out, and not allowed for VMS. Adjust all callers.
- (md_create_short_jump): Add ATTRIBUTE_UNUSED to unused arguments.
- (md_create_long_jump): Likewise.
- (md_undefined_symbol): Likewise.
- (md_section_align): Likewise.
- (md_shortopts): Allow -k and -K for ELF.
- (md_parse_option): Set flag_want_pic if -k or -K.
- (tc_headers_hook): New function if OBJ_AOUT and not BFD_ASSEMBLER.
- (tc_gen_reloc): New function if BFD_ASSEMBLER.
- * config/tc-vax.h (tc_headers_hook): Remove.
- (TARGET_FORMAT): Set according to object format and target
- environment.
- (BFD_ARCH, TARGET_ARCH): Define.
- (NO_RELOC): Adjust for BFD_ASSEMBLER.
- (TC_RELOC_RTSYM_LOC_FIXUP, TC_FIX_ADJUSTABLE)
- (tc_fix_adjustable): Define if BFD_ASSEMBLER.
- * config/vax-inst.h (VAX_JSB, VAX_CALLS, VAX_CALLG): Define.
-
-2002-06-08 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: Run "make dep-am".
- * Makefile.in: Regenerate.
-
- * as.c: Replace CONST with const.
- * write.c: Likewise.
- * config/obj-coff.c: Likewise.
- * config/tc-a29k.c: Likewise.
- * config/tc-arm.c: Likewise.
- * config/tc-dlx.c: Likewise.
- * config/tc-h8300.c: Likewise.
- * config/tc-h8500.c: Likewise.
- * config/tc-i370.c: Likewise.
- * config/tc-i860.c: Likewise.
- * config/tc-i960.c: Likewise.
- * config/tc-m68hc11.c: Likewise.
- * config/tc-m68k.c: Likewise.
- * config/tc-m88k.c: Likewise.
- * config/tc-mcore.c: Likewise.
- * config/tc-mips.c: Likewise.
- * config/tc-ns32k.c: Likewise.
- * config/tc-pdp11.c: Likewise.
- * config/tc-pj.c: Likewise.
- * config/tc-s390.c: Likewise.
- * config/tc-sh.c: Likewise.
- * config/tc-sparc.c: Likewise.
- * config/tc-tahoe.c: Likewise.
- * config/tc-tic80.c: Likewise.
- * config/tc-v850.c: Likewise.
- * config/tc-vax.c: Likewise.
- * config/tc-w65.c: Likewise.
- * config/tc-z8k.c: Likewise.
-
-2002-06-08 Daniel Jacobowitz <drow@mvista.com>
-
- Based on patch from Matt Green:
- * config/obj-elf.h (ECOFF_DEBUGGING): Make configurable.
- * config/tc-mips.c (s_mips_file): Renamed from s_file.
- (s_mips_loc): New function.
- (mips_nonecoff_pseudo_table): Call them.
- (append_insn): Call dwarf2_emit_insn.
-
-2002-06-08 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (mips_opts): Fix comment, all ASE fields are set
- to -1.
- (file_ase_mips16): New veriable.
- (mips_eabi64): Remove.
- (CPU_HAS_MIPS16): New define.
- (CPU_HAS_MDMX): Fix data type.
- (md_begin): Code cleanup. Use file_ase_mips16.
- (mips_elf_final_processing): Handle mips16 header flag.
- Handle EABI flag without intermediate variable.
-
-2002-06-08 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * doc/as.texinfo: Update MIPS documentation.
-
-2002-06-08 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c: Add define for $zero register.
- (md_begin): Add $zero as alias name for $0.
- (insn_uses_reg): Use ZERO define.
- (mips_ip): Add $zero as alias name for $0.
- (mips16_ip): Likewise.
- (s_cplocal): Demand empty rest of input line.
- (tc_get_register): Likewise. Add support for $kt0, kt1 register
- names. Use ZERO define. Fix input_line_pointer progress.
-
-2002-06-07 Alan Modra <amodra@bigpond.net.au>
-
- * symbols.c: Replace CONST by const throughout.
- (symbol_find_exact): Split out from..
- (symbol_find_base): ..here.
- * symbols.h: Replace CONST by const throughout.
- (symbol_find_exact): Declare.
- * config/obj-elf.c: #include "struc-symbol.h".
- (elf_frob_file): If group name matches an exported symbol, use that
- symbol for the signature and ".group" as the section name.
-
-2002-06-06 J"orn Rennecke <joern.rennecke@superh.com>
-
- * config/tc-sh.c (parse_at): @(symbol,pc) is A_DISP_PC again,
- but warn about it.
- * testsuite/gas/sh/pcrel.s: Also test @(symbol,pc).
- * testsuite/gas/sh/pcrel.d: Update.
- * testsuite/gas/sh/pcrel.l: New file.
-
-2002-06-06 Daniel Jacobowitz <drow@mvista.com>
-
- * tc-mips.c (mips_after_parse_args): Always set mips_opts.ase_mips3d
- and mips_opts.ase_mdmx if they are uninitialized.
-
-2002-06-06 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * gas/config/tc-hppa.c (pa_ip): Replace "L$0\001" with FAKE_LABEL_NAME.
- (hppa_force_relocation): Check if a stub just before the start symbol
- of the last call_info is reachable before forcing relocation. Fix
- typo.
-
-2002-06-04 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
-
- * config/tc-mips.c (mips_after_parse_args): New function.
- (md_begin): Move processing of defaults to mips_after_parse_args.
- config/tc-mips.h (md_after_parse_args): Define.
-
-2002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
-
- * configure.in (sh5*): Set cpu_type to sh64 and endian to big.
- (sh5le*, sh64le*): Set cpu_type to sh64 and endian to little.
- (sh5*-*-netbsd*, sh64*-*-netbsd*): New targets.
- * configure: Regenerate.
- * config/tc-sh64.c (sh64_target_format): Add support for NetBSD
- environment.
-
-2002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
-
- * config/tc-sh64.h (MD_PCREL_FROM_SECTION): Undef before redefining.
-
-2002-06-04 Alan Modra <amodra@bigpond.net.au>
-
- * config/obj-elf.c (obj_elf_change_section): Set and check elf
- linkonce flag. Print all warnings.
- (obj_elf_section): Parse ",comdat" for groups.
- (elf_frob_file): Set SEC_LINK_ONCE on COMDAT groups. Check
- consistency of comdat flag.
-
-2002-06-02 Richard Henderson <rth@redhat.com>
-
- * config/tc-alpha.c (alpha_adjust_symtab_relocs): Fix thinko
- with LITERALs without sequence numbers.
-
-2002-06-01 Richard Henderson <rth@redhat.com>
-
- * config/tc-alpha.c: Move LITUSE constants to "elf/alpha.h".
- Rename them LITUSE_ALPHA_*.
-
-2002-05-31 Shrinivas Atre <ShrinivasA@kpit.com>
-
- * config/tc-h8300.c (get_operand): Allow stm.l and ldm.l insns to
- accept parentheses enclosed register lists.
-
-2002-05-31 Alan Modra <amodra@bigpond.net.au>
+ * po/fr.po: Updated French translation.
- * Makefile.am: Run "make dep-am".
- * Makefile.in: Regenerate.
- * po/POTFILES.in: Regenerate.
+2004-05-07 Daniel Jacobowitz <dan@debian.org>
-2002-05-31 Graeme Peterson <gp@qnx.com>
+ * Makefile.am (DIST_SUBDIRS): Define.
+ * aclocal.m4: Regenerate with automake 1.8.4.
+ * Makefile.in: Likewise.
+ * doc/Makefile.in: Likewise.
- * configure.in: Add i386-*-nto-qnx*.
- * configure: Regenerate.
+2004-05-07 Daniel Jacobowitz <dan@debian.org>
-2002-05-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (mips_ip): Use unsigned long values for
- warning output.
-
-2002-05-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (s_cpsetup): Fix initialization of
- mips_cpreturn_register and mips_cpreturn_offset.
-
-2002-05-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (s_cpsetup): Fix comment.
-
-2002-05-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (md_begin): Add $ra as alias name for $31.
- (mips_ip): Likewise.
- (mips16_ip): Likewise.
- (tc_get_register): Likewise.
-
-2002-05-30 Chris G. Demetriou <cgd@broadcom.com>
- Ed Satterthwaite <ehs@broadcom.com>
-
- * config/tc-mips.c (mips_set_options): New "ase_mdmx" member.
- (mips_opts): Initialize "ase_mdmx" member.
- (file_ase_mdmx): New variable.
- (CPU_HAS_MDMX): New macro.
- (md_begin): Initialize mips_opts.ase_mdmx and file_ase_mdmx
- based on command line options and configuration defaults.
- (macro_build): Note in comment that use of MDMX in macros is
- not currently allowed.
- (validate_mips_insn): Add support for the "O", "Q", "X", "Y", and
- "Z" MDMX operand types.
- (mips_ip): Accept MDMX instructions if mips_opts.ase_mdmx is set,
- and add support for the "O", "Q", "X", "Y", and "Z" MDMX operand
- types.
- (OPTION_MDMX, OPTION_NO_MDMX, md_longopts, md_parse_option):
- Add support for "-mdmx" and "-no-mdmx" options.
- (OPTION_ELF_BASE): Move to accomodate new options.
- (s_mipsset): Support ".set mdmx" and ".set nomdmx".
- (mips_elf_final_processing): Set MDMX ASE ELF header flag if
- file_ase_mdmx was set.
- * doc/as.texinfo: Document -mdmx and -no-mdmx options.
- * doc/c-mips.texi: Likewise, and document ".set mdmx" and ".set
- nomdmx" directives.
-
-2002-05-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (OPTION_NO_M7000_HILO_FIX): Rename to
- OPTION_MNO_7000_HILO_FIX. Add alternate "mno-fix7000"
- command line switch conforming to gcc conventions.
- * doc/c-mips.texi: Document -mno-fix7000 instead of no-mfix-7000.
-
-2002-05-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (macro_build_jalr): New Function.
- (md_begin): NewABI uses big GOTs.
- (macro_build): Recognize BFD_RELOC_MIPS_GOT_DISP,
- BFD_RELOC_MIPS_GOT_PAGE, BFD_RELOC_MIPS_GOT_OFST as valid.
- (load_address): Add some NewABI PIC support.
- (macro): Likewise.
- (md_apply_fix): Special handling for BFD_RELOC_MIPS_JALR.
- (tc_gen_reloc): Don't encode NewABI vtables in REL relocations.
-
-2002-05-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (load_address): Use mips_gp_register instead
- of hardcoded value. Remove dbl parameter, use HAVE_32BIT_ADDRESSES
- instead.
- (macro): Use mips_gp_register instead of hardcoded value.
-
-2002-05-30 Richard Henderson <rth@redhat.com>
-
- * expr.h (operatorT): Add O_md17..O_md32.
- * config/tc-alpha.c (O_lituse_tlsgd, O_lituse_tlsldm, O_tlsgd,
- O_tlsldm, O_gotdtprel, O_dtprelhi, O_dtprello, O_dtprel, O_gottprel,
- O_tprelhi, O_tprello, O_tprel): New.
- (USER_RELOC_P, alpha_reloc_op_tag, debug_exp): Include them.
- (DUMMY_RELOC_LITUSE_TLSGD, DUMMY_RELOC_LITUSE_TLSLDM): New.
- (LITUSE_TLSGD, LITUSE_TLSLDM): New.
- (struct alpha_reloc_tag): Add master, saw_tlsgd, saw_tlsld,
- saw_lu_tlsgd, saw_lu_tlsldm. Make multi_section_p a bit field.
- (md_apply_fix3): Handle TLS relocations.
- (alpha_force_relocation, alpha_fix_adjustable): Likewise.
- (alpha_adjust_symtab_relocs): Sort LITERAL relocs after the
- associated TLS reloc. Check lituse_tls relocs match up.
- (emit_insn): Handle TLS relocations.
- (ldX_op): Remove.
-
- * doc/c-alpha.texi: Add docs for tls relocations.
-
-2002-05-30 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (mips_gprel_offset): New variable.
- (s_gpvalue): Use it.
-
-2002-05-30 Diego Novillo <dnovillo@redhat.com>
-
- * gas/config/tc-d10v.c (check_resource_conflict): Only check
- write-write conflicts.
- (md_assemble): Reformat introductory comment.
- (parallel_ok): Prevent packing only if the first
- instruction cannot be packed.
-
-2002-05-30 Jason Eckhardt <jle@redhat.com>
- Tom Rix <trix@redhat.com>
-
- * config/tc-d10v.c (build_insn): Check for immediates.
-
-2002-05-28 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c: Replace GP in comments by $gp.
- (mips_big_got): Initialize.
- (mips_trap): Initialize.
- (load_address): Use mips_gp_register instead of hardcoded value.
- Remove dbl parameter, use HAVE_32BIT_ADDRESSES instead.
- (macro): Use mips_gp_register instead of hardcoded value.
- (macro2): Change load_address calls.
- (md_pcrel_from): Comment formatting.
- (s_cpload): Use mips_gp_register instead of hardcoded value.
- (s_cprestore): Likewise. Comment formatting.
- (s_gpword): Fix data type.
- (s_cpadd): Use mips_gp_register instead of hardcoded value.
- (nopic_need_relax): Replace GP in comments by $gp.
- (mips_elf_final_processing): Better comment.
-
-2002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
-
- * configure.in: Add DLX configuraton
- * Makefile.am: Add DLX configuraton
- * configure: Regenerate.
+ Merge from mainline:
+ 2004-05-05 Jakub Jelinek <jakub@redhat.com>
+ * tc-s390.h (md_do_align, HANDLE_ALIGN): Remove.
+ (NOP_OPCODE): Define.
+ (s390_align_code): Remove prototype.
+ * tc-s390.c (s390_align_code): Remove.
+
+ 2004-04-22 Bruno De Bus <bdebus@elis.ugent.be>
+ * config/tc-arm.h (enum mstate): Move here, add MAP_UNDEFINED
+ state.
+ (TC_SEGMENT_INFO_TYPE): Define to enum mstate.
+ * config/tc-arm.c (enum mstate): Delete from here.
+ (mapping_state): Remove the static mapstate variable and instead
+ store the state in the segment. This allows a per-section mapping
+ state. Handle and ignore MAP_UNDEFINED states.
+ (arm_elf_change_section): Get the current mapping state from the
+ new section.
+ (s_ltorg): Set the mapping state to MAP_DATA.
+ (arm_cleanup): Use arm_elf_change_section to get the mapping state
+ for each pool as it is emitted.
+
+ 2004-04-22 Nick Clifton <nickc@redhat.com>
+ * config/tc-arm.h: Formatting tidy ups.
+
+2004-05-07 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-frv.h (MAX_MEM_FOR_RS_ALIGN_CODE): New.
+ (HANDLE_ALIGN): New.
+
+2004-05-05 Alexandre Oliva <aoliva@redhat.com>
+
+ * configure.in: Set em=linux for frv-*-*linux*.
+ * configure: Rebuilt.
+ * config/tc-frv.h (TARGET_FORMAT): Use elf32-frvfdpic if...
+ (frv_md_fdpic_enabled): New.
+ * config/tc-frv.c (frv_md_fdpic_enabled): New.
+ (DEFAULT_FDPIC): New.
+ (frv_flags): Use DEFAULT_FDPIC.
+ (frv_pic_flag): Likewise.
+ (OPTION_NOPIC): New.
+ (md_longopts): Add -mnopic.
+ (md_parse_option): Handle it.
+ (md_show_usage): Add -mfdpic and -mnopic.
+
+2004-04-20 Chris Demetriou <cgd@broadcom.com>
+
+ * NEWS: Note that MIPS -membedded-pic option is deprecated.
+
+2004-04-19 Eric Christopher <echristo@redhat.com>
+
+ * config/tc-mips.c (mips_dwarf2_addr_size): Revert part
+ of previous patch for fix in gcc.
+
+2004-04-16 Alan Modra <amodra@bigpond.net.au>
+
+ * expr.c (operand): Correct checks for ++ and --.
+
+2004-04-14 Richard Sandiford <rsandifo@redhat.com>
+
+ * doc/c-mips.texi (-m{no-,}fix-vr4120): Renamed from
+ -{no-}mfix-vr4122-bugs.
+ * config/tc-mips.c (mips_fix_vr4120): Renamed from mips_fix_4122_bugs.
+ (append_insn, mips_emit_delays): Update accordingly.
+ (OPTION_FIX_VR4120, OPTION_NO_FIX_VR4120): Renamed from *VR4122.
+ (md_longopts): Change -{no-,}mfix-vr4122-bugs to -m{no-,}fix-vr4120.
+ (md_parse_option): Update after above changes.
+ (md_show_usage): Add -mfix-vr4120.
+
+2004-04-11 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * Makefile.am: Remove mips from aout targets.
* Makefile.in: Regenerate.
- * config/tc-dlx.c: New file.
- * config/tc-dlx.h: New files.
- * NEWS: Mention new support.
-
-2002-05-27 Nick Clifton <nickc@cambridge.redhat.com>
-
- * config/obj-coff.c (write_object_file): Add missing semicolon.
-
-2002-05-26 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (mips_emit_delays): Replace magic constant for RA
- by the define. Remove superfluous check of mips_opts.mips16.
- (append_insn): Likewise. Canonicalize variable increments.
- (macro_build): Canonicalize variable increments.
- (macro_build_lui): Likewise.
- (load_register): Likewise.
- (load_address): Move pointer initialization.
- (macro): Move pointer to a more local scope. Canonicalize variable
- increments. Better comments. Replace magic constant for RA by the
- define.
- (macro2): Replace magic constant for RA by the define. Canonicalize
- variable increments.
- (mips_ip): Canonicalize variable increments.
- (mips16_ip): Replace magic constant for RA by the define.
- (my_getSmallParser): Canonicalize variable increments/decrements.
- (my_getPercentOp): Likewise.
- (my_getSmallExpression): Likewise.
- (s_align): Likewise.
- (s_mipsset): Likewise.
- (s_cpsetup): Likewise.
- (s_insn): Remove superfluous check of mips_opts.mips16.
- (s_mips_stab): Likewise.
- (mips_handle_align): Canonicalize variable increments.
- (s_mips_ent): Likewise.
- (s_mips_end): Add comment.
-
-2002-05-26 Jason Thorpe <thorpej@wasabisystems.com>
-
- * configure.in: Use ns32k-*-netbsd* instead of ns32k-pc532-netbsd*.
+ * configure.in: Remove mips-dec-bsd* target.
* configure: Regenerate.
-2002-05-25 Alan Modra <amodra@bigpond.net.au>
+2004-04-09 Daniel Jacobowitz <drow@mvista.com>
- * Makefile.am (OBJS): Depend on ansidecl.h and fopen-same.h.
+ Merge from mainline:
+ 2004-04-07 Alan Modra <amodra@bigpond.net.au>
+ PR 96
+ * config/tc-ppc.c (ppc_elf_suffix): Add valid32 and valid64 fields
+ to struct map_bfd. Adjust MAP macro, and define MAP32, MAP64.
+ Update "mapping". Restrict some @ modifiers to 32 bit.
+
+ 2004-04-01 Asgari Jinia <asgarij@kpitcummins.com>
+ Dhananjay Deshpande <dhananjayd@kpitcummins.com>
+
+ * config/tc-sh.c (dont_adjust_reloc_32): New variable.
+ (sh_fix_adjustable): Avoid adjusting BFD_RELOC_32 when
+ dont_adjust_reloc_32 is set.
+ (md_longopts): Add option -renesas.
+ (md_parse_option, md_show_usage): Likewise.
+ * doc/c-sh.texi: Likewise.
+
+ 2004-04-01 Dave Korn <dk@artimi.com>
+ * config/tc-dlx.c (md_assemble): set fx_no_overflow flag for
+ hi16 and lo16 fixS structs.
+ (md_assemble): generate bit_fixS for RELOC_DLX_LO16 in
+ exactly the same way as for RELOC_DLX_REL16.
+ (machine_ip): properly respect LO flag in the_insn and
+ output RELOC_DLX_LO16 rather than RELOC_DLX_16.
+ (md_apply_fix3): apply RELOC_DLX_LO16.
+
+ 2004-03-19 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
+ * tc-hppa.c (cons_fix_new_hppa): Check for PC relative base type.
+ (pa_comm): Set BSF_OBJECT in symbol flags.
+
+ 2004-03-18 Nathan Sidwell <nathan@codesourcery.com>
+ * read.c (read_a_source_file): Use demand_empty_rest_of_line.
+ (demand_empty_rest_of_line): Issue an error here.
+ (ignore_rest_of_line): Silently skip to end.
+ (demand_copy_string): Issue an error, not warning.
+ (equals): Likewise.
+ * config/obj-elf.c (obj_elf_section_name): Likewise.
+ (obj_elf_section): Likewise.
+ * config/tc-arc.c (arc_extoper): Remove bogus NULL checks.
+ (arc_extinst): Likewise.
+ * config/tc-ia64.c (dot_saveb): Use demand_empty_rest_of_line.
+ (dot_spill): Likewise.
+ (dot_unwabi): Likewise.
+ (dot_prologue): Likewise.
+
+ 2004-03-18 Nathan Sidwell <nathan@codesourcery.com>
+ * expr.c (operand): Reject ++ and --.
+ (operator): Likewise.
+
+ 2004-03-12 Bob Wilson <bob.wilson@acm.org>
+ * read.c (s_leb128): Call md_flush_pending_output.
+
+ 2004-03-07 Andreas Schwab <schwab@suse.de>
+ * doc/c-hppa.texi (HPPA Directives): Fix typo.
+
+ 2004-03-07 Richard Henderson <rth@redhat.com>
+ * dw2gencfi.c (output_cie): Align length to 4 byte boundary.
+ (cfi_finish): Likewise for fde.
+
+ 2004-03-05 H.J. Lu <hongjiu.lu@intel.com>
+ * config/tc-ia64.c (md_assemble): Properly handle NULL
+ align_frag.
+ (ia64_handle_align): Don't abort if failed to add a stop bit.
+
+ 2004-03-04 H.J. Lu <hongjiu.lu@intel.com>
+ * Makefile.in: Regenerated.
+ * aclocal.m4: Likewise.
+ * configure: Likewise.
+ * doc/Makefile.in: Likewise.
+
+ 2004-03-03 H.J. Lu <hongjiu.lu@intel.com>
+ * config/tc-ia64.c (dot_align): New.
+ (ia64_do_align): Make it static.
+ (md_pseudo_table): Use "dot_align" for "align".
+ (ia64_md_do_align): Don't set align_frag here.
+ (ia64_handle_align): Add a stop bit to the previous bundle if
+ needed.
+
+ * config/tc-ia64.h (ia64_do_align): Removed.
+
+ 2004-03-02 H.J. Lu <hongjiu.lu@intel.com>
+ * config/tc-ia64.c (align_frag): New.
+ (md_assemble): Set the tc_frag_data field in align_frag for
+ IA64_OPCODE_FIRST instructions.
+ (ia64_md_do_align): Set align_frag.
+ (ia64_handle_align): Add a stop bit if needed.
+
+ * config/tc-ia64.h (TC_FRAG_TYPE): New.
+ (TC_FRAG_INIT): New.
+
+ 2004-02-27 Nick Clifton <nickc@redhat.com>
+ * config/tc-sh.c (get_operand): Revert previous delta.
+ (tc_gen_reloc): Check for an unknown reloc type before processing
+ the addend.
+
+ 2004-02-27 Hannes Reinecke <hare@suse.de>
+ * config/tc-s390.c (s390_insn): Correct range check for opcode in
+ .insn pseudo operation.
+
+ 2004-02-27 Anil Paranjpe <anilp1@kpitcummins.com>
+ * config/tc-sh.c (get_operand): In case of #Imm, check has been
+ added for wrong syntax.
+
+ 2004-02-26 Andrew Stubbs <andrew.stubbs@superh.com>
+ * config/tc-sh.c (build_Mytes): Add REG_N_D and REG_N_B01
+ nibble types to assembler.
+
+ 2004-02-25 Fred Fish <fnf@redhat.com>
+ * config/tc-iq2000.c: Add missing \n\ in multiline string literal.
+
+ 2004-02-20 James E Wilson <wilson@specifixinc.com>
+ * config/tc-ia64.c (slot_index): New arg before_relax. Use instead of
+ finalize_syms.
+ (fixup_unw_records): New arg before_relax. Pass to slot_index.
+ (ia64_estimate_size_before_relax): New.
+ (ia64_convert_frag): Pass 0 to fixup_unw_records. Add comment.
+ (generate_unwind_image): Pass 1 to fixup_unw_records.
+ * config/tc-ia64.h (ia64_estimate_size_before_relax): Declare.
+ (md_estimate_size_before_relax): Call ia64_estimate_size_before_relax.
+
+ 2004-02-19 Jakub Jelinek <jakub@redhat.com>
+ * stabs.c (generate_asm_file): Avoid warning about use of
+ uninitialized variable.
+
+ 2004-02-18 David Mosberger <davidm@hpl.hp.com>
+ * config/tc-ia64.c (ia64_flush_insns): In addition to prologue,
+ body, and endp, allow unwind records which do not have a "t"
+ (time/instruction) field.
+
+2004-03-22 Bob Wilson <bob.wilson@acm.org>
+
+ * config/tc-xtensa.c (xtensa_post_relax_hook): Create literal
+ tables even when use_literal_section flag is not set.
+
+2004-03-22 Hans-Peter Nilsson <hp@axis.com>
+
+ * doc/c-cris.texi (CRIS-Opts): Document --no-mul-bug-abort,
+ --mul-bug-abort and the default behavior.
+ * config/tc-cris.c (cris_insn_kind): New member CRIS_INSN_MUL.
+ (err_for_dangerous_mul_placement): New variable.
+ (STATE_MUL, OPTION_MULBUG_ABORT_ON, OPTION_MULBUG_ABORT_OFF): New
+ macros.
+ (md_cris_relax_table): Have placeholder for STATE_MUL.
+ (md_longopts): New options --mul-bug-abort and --no-mul-bug-abort.
+ (cris_relax_frag) <case ENCODE_RELAX (STATE_MUL, STATE_BYTE)>: New
+ case doing nothing.
+ (md_estimate_size_before_relax) <case ENCODE_RELAX (STATE_MUL,
+ STATE_BYTE)>: Ditto.
+ (md_convert_frag) <ENCODE_RELAX (STATE_MUL, STATE_BYTE)>: Check
+ alignment and position of this frag, emit error message if
+ suspicious.
+ (md_assemble): For a multiply insn and when checking it,
+ transform the current frag into a special frag for that purpose.
+ (md_parse_option) <case OPTION_MULBUG_ABORT_OFF, case
+ OPTION_MULBUG_ABORT_ON>: Handle new options.
+
+2004-03-19 Bob Wilson <bob.wilson@acm.org>
+
+ * config/tc-xtensa.c (mark_literal_frags): New function.
+ (xtensa_move_literals): Call mark_literal_frags for all literal
+ segments, including init and fini literal segments.
+ (xtensa_post_relax_hook): Swap use of xt_insn_sec and xt_literal_sec.
+
+2004-03-17 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * config/tc-sh.c: Include dw2gencfi.h.
+ (sh_cfi_frame_initial_instructions): New function.
+ (sh_regname_to_dw2regnum): Likewise.
+ * config/tc-sh.h (DWARF2_LINE_MIN_INSN_LENGTH): Move to the end of
+ file.
+ (TARGET_USE_CFIPOP): Define.
+ (tc_cfi_frame_initial_instructions): Likewise.
+ (tc_regname_to_dw2regnum): Likewise.
+ (DWARF2_DEFAULT_RETURN_COLUMN, DWARF2_CIE_DATA_ALIGNMENT): Likewise.
+ * Makefile.am: Update dependencies.
* Makefile.in: Regenerate.
- * dep-in.sed: Reorder to match OBJS in Makefile.am.
- * configure.in (ALL_OBJ_DEPS): Add symcat.h when need_bfd.
- * configure: Regenerate.
- * as.h: Use #include "" instead of <> for local header files.
- * flonum-konst.c: Likewise.
- * flonum-mult.c: Likewise.
- * gasp.c: Likewise.
- * listing.c: Likewise.
- * config/tc-ia64.h: Likewise.
- * config/tc-v850.h: Likewise.
-
-2002-05-24 TAMURA Kent <kent@netbsd.org>
-
- * configure.in: Add a target for i386-netbsdpe.
- * configure: Regenerate.
-
-2002-05-23 Jakub Jelinek <jakub@redhat.com>
-
- * config/obj-elf.c (elf_common): Renamed from obj_elf_common.
- (obj_elf_common): Call elf_common.
- (obj_elf_tls_common): New function.
- (elf_pseudo_tab): Support .tls_common.
- (special_sections): Add .tdata and .tbss.
- (obj_elf_change_section): Set SEC_THREAD_LOCAL for SHF_TLS
- sections.
- (obj_elf_parse_section_letters): Support T in section flags (SHF_TLS).
- (obj_elf_parse_section_letters): Include T in error message.
- * config/tc-ppc.c (ppc_section_letter): Likewise.
- * config/tc-alpha.c (alpha_elf_section_letter): Likewise.
- (tc_gen_reloc): Handle SEC_THREAD_LOCAL the same way as
- SEC_MERGE.
- * config/tc-sparc.c (md_apply_fix3): Likewise.
- * config/tc-i386.c (tc_i386_fix_adjustable): Add TLS relocs.
- Define them if not BFD_ASSEMBLER.
- (lex_got): Support @TLSGD, @TLSLDM, @GOTTPOFF, @TPOFF, @DTPOFF
- and @NTPOFF.
- (md_apply_fix3): Add TLS relocs.
- * config/tc-ia64.c (enum reloc_func): Add FUNC_DTP_MODULE,
- FUNC_DTP_RELATIVE, FUNC_TP_RELATIVE, FUNC_LT_DTP_MODULE,
- FUNC_LT_DTP_RELATIVE, FUNC_LT_TP_RELATIVE.
- (pseudo_func): Support @dtpmod(), @dtprel() and @tprel().
- (ia64_elf_section_letter): Include T in error message.
- (md_begin): Support TLS operators.
- (md_operand): Likewise.
- (ia64_gen_real_reloc_type): Support TLS relocs.
- * testsuite/gas/i386/tlspic.s: New file.
- * testsuite/gas/i386/tlsd.s: New file.
- * testsuite/gas/i386/tlsnopic.s: New file.
- * testsuite/gas/i386/tlsd.d: New file.
- * testsuite/gas/i386/tlsnopic.d: New file.
- * testsuite/gas/i386/tlspic.d: New file.
- * testsuite/gas/i386/i386.exp: Add tlsd, tlsnopic and tlspic tests.
- * testsuite/gas/ia64/tls.s: New file.
- * testsuite/gas/ia64/tls.d: New file.
- * testsuite/gas/ia64/ia64.exp: Add tls test.
- * write.c (adjust_reloc_syms): Don't change symbols in
- SEC_THREAD_LOCAL sections to STT_SECTION + addend.
-
-2002-05-23 Nick Clifton <nickc@cambridge.redhat.com>
-
- * config/tc-arm.c (md_apply_fix3): For the Thumb BLX reloc
- round the relocation up rather than down.
-
-2002-05-23 Nick Clifton <nickc@cambridge.redhat.com>
-
- * config/obj-coff.c (obj_coff_section): Silently ignore an 'a'
- flag.
- * doc/as.texinfo: Document that the COFF version of .section
- ignores the 'a' flag.
-
-2002-05-23 Alan Modra <amodra@bigpond.net.au>
-
- * config/tc-alpha.c (assemble_tokens): Protect use of
- ALPHA_RELOC_TABLE with #ifdef RELOC_OP_P.
-
- * write.c (size_seg): Check adjustment to last frag.
- (SUB_SEGMENT_ALIGN): If HANDLE_ALIGN defined, pad out last frag to
- section alignment.
- * config/obj-coff.c (SUB_SEGMENT_ALIGN): Likewise.
- * config/obj-ieee.c (SUB_SEGMENT_ALIGN): Likewise.
- (write_object_file): Invoke md_do_align if available, and use
- frag_align_code on text sections.
- * config/obj-vms.h (SUB_SEGMENT_ALIGN): Now two args.
- * config/tc-m88k.h (SUB_SEGMENT_ALIGN): Likewise.
- * config/tc-ppc.h (SUB_SEGMENT_ALIGN): Likewise.
- * config/tc-sh.h (SUB_SEGMENT_ALIGN): Likewise.
- * config/tc-i386.h (SUB_SEGMENT_ALIGN): Likewise. Define for
- BFD_ASSEMBLER too.
-
-2002-05-22 H.J. Lu <hjl@gnu.org>
-
- * dwarf2dbg.c (dwarf2_directive_loc): Call listing_source_file
- for source file.
-
-2002-05-22 Nick Clifton <nickc@cambridge.redhat.com>
-
- * config/tc-arm.c (arm_s_section): Enable for COFF builds as well
- as ELF builds.
-
-2002-05-22 H.J. Lu <hjl@gnu.org>
-
- * dwarf2dbg.c (dwarf2_emit_insn): Emit only one line symbol
- for one .loc for compiler.
-
-2002-05-22 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (macro): Relax warning, it's toot strict for
- embedded-PIC.
-
-2002-05-22 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (macro2): Add 64 bit drol, dror macros.
- Optimize the rotate by zero case.
-
-2002-05-21 Nick Clifton <nickc@cambridge.redhat.com>
-
- * configure.in: Remove accidental enabling of bfd_gas=yes for
- sh-coff targets.
- * configure: Regenerate.
-
-2002-05-18 Kazu Hirata <kazu@cs.umass.edu>
-
- * app.c: Fix formatting.
- * as.c: Likewise.
- * ehopt.c: Likewise.
- * expr.c: Likewise.
- * input-file.c: Likewise.
- * listing.c: Likewise.
- * macro.h: Likewise.
- * stabs.c: Likewise.
- * symbols.c: Likewise.
-
-2002-05-17 Alan Modra <amodra@bigpond.net.au>
-
- * config/obj-generic.c: Delete file.
- * config/obj-generic.h: Likewise.
-
-2002-05-16 Marek Michalkiewicz <marekm@amelek.gda.pl>
-
- * config/tc-avr.c (mcu_types): Update for new devices.
-
-2002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (macro): Warn about wrong la/dla use.
-
-2002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc_mips.c (s_cpsetup): Fix completely bogus code which had
- worked sometimes by accident. Fix copy&paste comment.
-
-2002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (md_begin): Fix .reginfo and .MIPS.option section
- alignment for NewABI. Let n32 use .reginfo. Remove useless casts.
- (mips_elf_final_processing): Let n32 use .reginfo.
-
-2002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (append_insn): Fix too small range of variable.
-
-2002-05-14 Nick Clifton <nickc@cambridge.redhat.com>
-
- * config/tc-arm.c (arm_cleanup): Remove redundant call to
- listing_prev_line().
-
-2002-05-13 Nick Clifton <nickc@cambridge.redhat.com>
-
- * config/tc-arm.c (md_assemble): Remove redundant call to
- listing_prev().
-
- * dwarf2dbg.c (dwarf2_emit_insn): Do not reset
- loc_directive_seen.
-
- * stabs.c (s_stab_generic): Fix grammatical error in warning
- message.
-
-2002-05-13 Alan Modra <amodra@bigpond.net.au>
-
- * write.c (subsegs_finish): Don't specially align last subseg.
-
-2002-05-11 Nick Clifton <nickc@cambridge.redhat.com>
- * stabs.c (s_stab_generic): Warn about a description field that is
- too big.
-
- * config/obj-coff.c: Fix compile time warnings when compiling
- without BFD_ASSEMBLER defined.
- Fix formatting.
-
- * config/tc-sh.c (md_pcrel_from): Define for use with sh-hms
- target.
- (md_pcrel_from_section): Use md_pcrel_from().
-
-2002-05-11 Bruno Haible <bruno@clisp.org>
-
- * dwarf2dbg.c (dwarf2_emit_insn): Use the 'current' struct filled
- by dwarf2_directive_loc, instead of calling dwarf2_where.
-
-2002-05-11 Kazu Hirata <kazu@cs.umass.edu>
-
- * config/obj-coff.h: Fix formatting.
- * config/tc-mcore.c: Likewise.
- * config/tc-mn10300.c: Likewise.
- * config/tc-openrisc.c: Likewise.
- * config/tc-or32.c: Likewise.
- * config/tc-pdp11.c: Likewise.
- * config/tc-ppc.c: Likewise.
- * config/tc-ppc.h: Likewise.
- * config/tc-sh64.c: Likewise.
- * config/tc-sh.c: Likewise.
- * config/tc-tic54x.c: Likewise.
- * config/tc-xstormy16.c: Likewise.
- * config/tc-xstormy16.h: Likewise.
-
-2002-05-09 Kazu Hirata <kazu@cs.umass.edu>
-
- * config/obj-coff.c: Fix formatting.
- * config/obj-elf.c: Likewise.
- * config/tc-alpha.c: Likewise.
- * config/tc-arm.c: Likewise.
- * config/tc-d10v.c: Likewise.
- * config/tc-d30v.c: Likewise.
- * config/tc-h8300.c: Likewise.
- * config/tc-hppa.c: Likewise.
-
-2002-05-09 Alan Modra <amodra@bigpond.net.au>
-
- * config/tc-i386.c (md_estimate_size_before_relax) Don't lose
- reloc when no_cond_jump_promotion.
-
-2002-05-08 Jim Wilson <wilson@redhat.com>
-
- * config/tc-i960.c (md_estimate_size_before_relax): Return size of
- current variable part of frag.
-
-2002-05-08 Kazu Hirata <kazu@cs.umass.edu>
-
- * config/tc-mmix.c: Fix formatting.
- * config/tc-mmix.h: Likewise.
-
-2002-05-08 Alan Modra <amodra@bigpond.net.au>
+2004-03-17 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
+ * configure.in: Switch sh-*-rtems* to ELF. Add sh-*-rtemscoff*.
* configure: Regenerate.
-2002-05-07 Kazu Hirata <kazu@cs.umass.edu>
-
- * config/tc-m68k.c: Fix formatting.
-
-2002-05-07 Federico G. Schwindt <fgsch@olimpo.com.br>
-
- * Makefile.am: Honour DESTDIR.
- * Makefile.in: Regenerate.
-
-2002-05-06 Kazu Hirata <kazu@cs.umass.edu>
-
- * config/tc-ia64.c: Fix formatting.
- * config/tc-ia64.h: Likewise.
-
-2002-05-04 Kazu Hirata <kazu@cs.umass.edu>
-
- * config/tc-mips.c: Fix formatting.
- * config/tc-s390.c: Likewise.
- * config/tc-s390.h: Likewise.
-
-2002-05-03 Alexandre Oliva <aoliva@redhat.com>
-
- * config/tc-s390.c (md_gather_operands): Emit dwarf2 line-number
- information for instructions.
-
-2002-05-02 Kazu Hirata <kazu@cs.umass.edu>
-
- * as.h: Fix formatting.
- * cgen.c: Likewise.
- * cgen.h: Likewise.
- * dwarf2dbg.c: Likewise.
- * frags.h: Likewise.
- * gasp.c: Likewise.
- * macro.c: Likewise.
- * read.c: Likewise.
- * stabs.c: Likewise.
- * symbols.c: Likewise.
-
-2002-05-02 Alan Modra <amodra@bigpond.net.au>
-
- * app.c (mri_pseudo): Only declare for TC_M68K.
-
- * config/tc-ppc.c (mapping): Map sectoff to BFD_RELOC_16_BASEREL.
- (ppc_elf_validate_fix): Replace BFD_RELOC_32_BASEREL with
- BFD_RELOC_16_BASEREL.
- (md_assemble): Likewise.
- (md_apply_fix3): Likewise.
-
-2002-05-02 Nick Clifton <nickc@cambridge.redhat.com>
-
- * config/tc-arm.c (thumb_add_sub): Do not convert a subtract of
- zero into an add of zero - it is not the same.
-
-2002-05-01 Arati Dikey <aratid@kpit.com>
-
- * tc-sh.c (get_specific): Generate warning if the same
- destination register is used in parallel instructions.
-
-2002-05-01 Andrew Macleod <amacleod@cygnus.com>
-
- * config/tc-i386.c (extra_symbol_chars): Add '[' to the list.
-
-2002-05-01 Alan Modra <amodra@bigpond.net.au>
-
- * write.c (cvt_frag_to_fill): Set fr_offset to zero on .org
- backwards to prevent cascading errors.
-
-2002-04-30 Mark Mitchell <mark@codesourcery.com>
-
- * configure.in: Add support for powerpc-*-windiss.
- * configure: Regenerated.
-
-2002-04-28 Alan Modra <amodra@bigpond.net.au>
-
- * config/tc-s390.c (md_parse_option): Formatting.
-
- * config/tc-i386.c: Formatting fixes, add missing space in error
- message.
-
-2002-04-24 Christian Groessler <chris@groessler.org>
+2004-03-12 Bob Wilson <bob.wilson@acm.org>
- * config/tc-z8k.c (build_bytes): Add support for new cases:
- CLASS_IGNORE and ARG_NIM4.
- (md_assemble): Prevent destruction of input_line_pointer if
- get_operands returns failure.
+ * read.c (s_leb128): Call md_flush_pending_output.
-2002-04-24 Chris G. Demetriou <cgd@broadcom.com>
+2004-03-12 Michal Ludvig <mludvig@suse.cz>
- * config/tc-mips.c (macro_build): Do _not_ allow MIPS-3D
- instructions to be generated by macros.
+ * config/tc-i386.c (output_insn): Handle PadLock instructions.
+ * config/tc-i386.h (CpuPadLock): New define.
+ (CpuUnknownFlags): Added CpuPadLock.
-2002-04-24 Andreas Schwab <schwab@suse.de>
+2004-02-26 Eric Christopher <echristo@redhat.com>
- * config/tc-i386.c (output_jump, output_disp)
- (md_estimate_size_before_relax): Don't set fx_pcrel_adjust any
- more.
- (md_apply_fix3): Remember addend value for rela relocations.
- (tc_gen_reloc): Correctly compute pc-relative relocation addend.
+ * config/tc-mips.c (mips_dwarf2_addr_size): New.
+ * config/tc-mips.h (DWARF2_ADDR_SIZE): Use.
-2002-04-22 Chris Demetriou <cgd@broadcom.com>
+2004-02-17 Petko Manolov <petkan@nucleusys.com>
- * config/tc-mips.c (macro_build): Add close-parenthesis missing
- from previous change.
+ * config/tc-arm.c (do_mav_dspsc_1): Correct offset of CRn.
+ (do_mav_dspsc_2): Likewise.
+ Fix accumulator registers move opcodes.
-2002-04-22 Eric Christopher <echristo@redhat.com>
+2004-02-13 Hannes Reinecke <hare@suse.de>
+ Jakub Jelinek <jakub@redhat.com>
- * config/tc-mips.c (macro_build): Add warning if macro instructions
- are expanded into a branch delay slot.
+ * dwarf2dbg.c (get_filenum): Do not read beyond allocated memory.
-2002-04-17 Geoffrey Keating <geoffk@redhat.com>
+2004-02-10 Steve Ellcey <sje@cup.hp.com>
- * dwarf2dbg.c (dwarf2_gen_line_info): Do emit duplicate line
- numbers, gdb relies on them to detect the start of the prologue.
+ * config/tc-ia64.h (ia64_frob_symbol): New declaration.
+ (tc_frob_symbol): New macro definition.
+ * config/tc-ia64.c (ia64_frob_symbol): New routine.
-2002-04-17 Martin Schwidefsky <schwidefsky@de.ibm.com>
+2004-02-09 Daniel Jacobowitz <drow@mvista.com>
- * config/tc-s390.c (tc_s390_fix_adjustable): Prevent adjustments to
- symbols in merge sections.
+ * config/tc-arm.c (md_begin): Mark .note.gnu.arm.ident as
+ read-only.
-2002-04-16 Alan Modra <amodra@bigpond.net.au>
+2004-02-09 Nathan Sidwell <nathan@codesourcery.com>
- * as.c (main): Don't reference _bfd_chunksize.
+ * read.h (IGNORE_OPCODE_CASE): Do not define. Replace with ...
+ (TC_CASE_SENSITIVE): ... this.
+ * read.c: Replace IGNORE_OPCODE_CASE with TC_CASE_SENSITIVE.
+ * doc/internals.texi (TC_CASE_SENSITIVE): Document.
-2002-04-15 Tom Rix <trix@redhat.com>
+2004-02-06 James E Wilson <wilson@specifixinc.com>
- * config/tc-d10v.c (d10v_fix_adjustable): Prevent adjustments to
- symbols in merge sections.
+ * config/tc-ia64.c (dot_endp): Delete call to output_endp.
+ (generate_unwind_image): Re-add it here.
-2002-04-11 Richard Sandiford <rsandifo@redhat.com>
+2004-02-06 Nathan Sidwell <nathan@codesourcery.com>
- * doc/invoke.texi (TC_LARGEST_EXPONENT_IS_NORMAL): Document.
- * config/atof-ieee.c (TC_LARGEST_EXPONENT_IS_NORMAL): Add an
- argument for the precision.
- (gen_to_words): Update accordingly.
+ * dwarf2dbg.c (DWARF2_ADDR_SIZE): Remove trailing ';'
+ * read.h (SKIP_WHITESPACE): Turn into an expression.
+ * read.c (read_a_source_file): A pseudo is removed by having a
+ NULL handler.
-2002-04-10 Alan Modra <amodra@bigpond.net.au>
+2004-02-05 James E Wilson <wilson@specifixinc.com>
- * as.c (parse_args <OPTION_VERSION>): Use VERSION is
- BFD_VERSION_STRING unavailable.
- * config/tc-i386.c (INLINE): Define (for non-BFD assembler).
+ * config/tc-ia64.c (output_endp): New.
+ (count_bits): Delete.
+ (ia64_flush_insns, process_one_record, optimize_unw_records): Handle
+ endp unwind records.
+ (fixup_unw_records): Handle endp unwind records. Delete code for
+ shortening prologue regions not followed by a body record.
+ (dot_endp): Call add_unwind_entry to emit endp unwind record.
+ * config/tc-ia64.h (unw_record_type): Add endp.
-2002-04-09 J"orn Rennecke <joern.rennecke@superh.com>
+2004-02-03 James E Wilson <wilson@specifixinc.com>
- * config/tc-sh.h (TC_FIX_ADJUSTABLE): Disable adjusting if
- symbol_used_in_reloc_p is true.
+ * config/tc-ia64.c (ia64_convert_frag): Call md_number_to_chars to
+ fill padding bytes with zeroes.
+ (emit_one_bundle): New locals last_ptr, end_ptr. Rewrite code that
+ sets unwind_record slot_number and slot_frag fields.
- * config/tc-sh.c (md_apply_fix3): Don't zero relocations on big
- endian hosts.
+2004-02-02 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
-2002-04-04 Alan Modra <amodra@bigpond.net.au>
+ * config/tc-mips.c (add_got_offset_hilo): New function.
+ (macro): Use load_register() and add_got_offset_hilo() to load
+ constants instead of hardcoding code sequences throughout.
- * dep-in.sed: Cope with absolute paths.
- * Makefile.am (dep.sed): Subst TOPDIR.
- Run "make dep-am".
- * Makefile.in: Regenerate.
-
-2002-04-04 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (mips16_macro_build): Cast type mismatch.
- (mips_ip): Remove unused variable.
- (md_apply_fix3): Cast signed/unsignes mismatches. Replace
- unsigned char with bfd_byte.
- (s_file): Remove unused variable.
- (s_mips_ent): Likewise.
-
-2002-04-03 Tom Rix <trix@redhat.com>
-
- * config/tc-d10v.c (d10v_insert_operand): Fix warning in as_bad_where.
- (build_insn): Same.
- (find_opcode): Fix warning in as_warn.
- * config/tc-d10v.h: Update Copyright.
-
-2002-04-03 Alan Matsuoka <alanm@redhat.com>
- Tom Rix <trix@redhat.com>
-
- From Jeff Knaggs <jknaggs@redhat.com>
- * config/tc-d10v.c (check_resource_conflict): New function to
- check for resource conflicts.
-
- From Jason Eckhardt <jle@redhat.com>
- * config/tc-d10v.c (build_insn): Check for unresolved imm4 or
- imm3 fields.
- * config/tc-d10v.c (find_opcode): Emit a warning if one of the
- reserved control registers is used.
- * config/tc-d10v.c (build_insn): Check for unresolved imm4 or
- imm3 fields.
-
- From 2001-03-28 Diego Novillo <dnovillo@redhat.com>
- * tc-d10v.c (parallel_ok): Prevent packing only if the first
- instruction cannot be packed.
-
- From 2001-03-30 Diego Novillo <dnovillo@redhat.com>
- * gas/config/tc-d10v.c (check_resource_conflict): Only check
- write-write conflicts.
- (md_assemble): Reformat introductory comment.
- * opcodes/d10v-opc.c (d10v_opcodes): `btsti' does not modify its
- arguments.
-
-2002-04-03 Alan Modra <amodra@bigpond.net.au>
+2004-01-28 H.J. Lu <hongjiu.lu@intel.com>
- * symbols.c (resolve_symbol_value <O_uminus, O_bit_not,
- O_logical_not>): Derive final_seg from add_symbol.
- <O_multiply..O_logical_or>: More final_seg twiddles.
+ * config/tc-ia64.c (emit_one_bundle): Add proper indentation.
-2002-04-01 Jessica Han <jessica@cup.hp.com>
+2004-01-26 Bernardo Innocenti <bernie@develer.com>
- * config/tc-ia64.c (ia64_cons_fix_new): Handle 8 byte iplt reloc
- in 32-bit mode.
+ * config/tc-m68k.h (EXTERN_FORCE_RELOC): Handle m68k-uclinux specially,
+ like m68k-elf.
+ * config/tc-m68k.c (RELAXABLE_SYMBOL): Use EXTERN_FORCE_RELOC instead
+ of hard-coded test for TARGET_OS=elf.
-2002-03-27 Andreas Schwab <schwab@suse.de>
+2004-01-24 Chris Demetriou <cgd@broadcom.com>
- * config/tc-i386.c (output_jump): Set fx_pcrel_adjust to size of
- field for pc-relative fixups.
- (output_disp): Likewise.
- (md_estimate_size_before_relax): Likewise.
- (tc_gen_reloc): Subtract fx_pcrel_adjust instead of fx_size for
- pc-relative fixups in 64bit mode.
+ * config/tc-mips.c (hilo_interlocks): Change definition
+ so that MIPS32, MIPS64 and later ISAs are included, along with
+ the already-included machines. Update comments.
-2002-03-22 Alan Modra <amodra@bigpond.net.au>
+2004-01-23 Daniel Jacobowitz <drow@mvista.com>
- * config/te-aix5.h: Typo fix.
+ * config/tc-arm.c (tc_gen_reloc): Improve error message for
+ undefined local labels.
-2002-03-21 Alan Modra <amodra@bigpond.net.au>
+2004-01-23 Richard Sandiford <rsandifo@redhat.com>
- * Makefile.am: Run "make dep-am".
- * Makefile.in: Regenerate.
- * doc/Makefile.in: Regenerate.
-
-2002-03-20 Albert Chin-A-Young <china@thewrittenword.com>
+ * config/tc-mips.c (load_address, macro): Update comments about
+ NewABI GP relaxation.
- * config/tc-arm.c (vfp_dp_reg_required_here): Fix typo
- (vfp_sp_reg_pos -> vfp_dp_reg_pos).
+2004-01-23 Richard Sandiford <rsandifo@redhat.com>
-2002-03-18 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-mips.c (macro_build): Remove place and counter arguments.
+ (mips_build_lui, macro_build_ldst_constoffset): Likewise.
+ (mips16_macro_build, macro_build_jalr): Remove counter argument.
+ (set_at, load_register, load_address, move_register): Likewise.
+ (load_got_offset, add_got_offset): Likewise.
+ Update all calls and tidy accordingly.
- * config/tc-mips.c (md_estimate_size_before_relax): Do not modify
- the EXTENDED bit here; report the estimate according to the
- current size.
-
-2002-03-18 Tom Rix <trix@redhat.com>
-
- * configure.in: Add AIX 5 support.
- * config/tc-ppc.c (ppc_target_format): Add AIX 5 64 bit target.
- * config/te-aix5.h: New file. AIX 5 support.
- * configure: Regenerate.
+2004-01-23 Richard Sandiford <rsandifo@redhat.com>
-2002-03-18 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/fr.po: Updated version.
-
-2002-03-16 Andreas Jaeger <aj@suse.de>
-
- * doc/c-mips.texi (Machine Dependencies): Add new node.
-
-2002-03-15 Chris G. Demetriou <cgd@broadcom.com>
-
- * config/tc-mips.c (mips_set_options): New "ase_mips3d" member.
- (mips_opts): Initialize "ase_mips3d" member.
- (file_ase_mips3d): New variable.
- (CPU_HAS_MIPS3D): New macro.
- (md_begin): Initialize mips_opts.ase_mips3d and file_ase_mips3d
- based on command line options and configuration defaults.
- (macro_build, mips_ip): Accept MIPS-3D instructions if
- mips_opts.ase_mips3d is set.
- (OPTION_MIPS3D, OPTION_NO_MIPS3D, md_longopts, md_parse_option):
- Add support for "-mips3d" and "-no-mips3d" options.
- (OPTION_ELF_BASE): Move to accomodate new options.
- (s_mipsset): Support ".set mips3d" and ".set nomips3d".
- (mips_elf_final_processing): Add a comment indicating that a
- MIPS-3D ASE ELF header flag should be set, when one exists.
- * doc/as.texinfo: Document -mips3d and -no-mips3d options.
- * doc/c-mips.texi: Likewise, and document ".set mips3d" and ".set
- nomips3d" directives.
-
-2002-03-14 Hans-Peter Nilsson <hp@bitrange.com>
-
- * config/tc-mmix.c (md_estimate_size_before_relax): Don't consider
- a weak symbol in same section to be within reach.
-
-2002-03-13 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/fr.po: Updated version.
-
-2002-03-12 Andreas Schwab <schwab@suse.de>
-
- * config/tc-ia64.c (fixup_unw_records): Clear region when seeing a
- body record so that an error is given for misplaced .save
- pseudo-ops.
-
-2002-03-09 Alan Modra <amodra@bigpond.net.au>
-
- * config/tc-i386.h (REX_OPCODE): Define.
- (REX_MODE64, REX_EXTX, REX_EXTY, REX_EXTZ): Define.
- (rex_byte): typedef to int.
- * config/tc-i386.c: Group prototypes and vars together.
- Formatting fixes. Remove occurrences of "register" keyword.
- (true): Delete.
- (false): Delete.
- (mode_from_disp_size): Add INLINE keyword to prototype.
- (fits_in_signed_byte): Likewise.
- (fits_in_unsigned_byte): Likewise.
- (fits_in_unsigned_word): Likewise.
- (fits_in_signed_word): Likewise.
- (fits_in_unsigned_long): Likewise.
- (fits_in_signed_long): Likewise.
- (type_names): Constify.
- (intel_float_operand): Constify param.
- (add_prefix): Use REX_OPCODE.
- (md_assemble): Likewise. Modify for changed rex_byte.
- (parse_insn): Split out of md_assemble.
- (parse_operands): Likewise.
- (swap_operands): Likewise.
- (optimize_imm): Likewise.
- (optimize_disp): Likewise.
- (match_template): Likewise.
- (check_string): Likewise.
- (process_suffix): Likewise.
- (check_byte_reg): Likewise.
- (check_long_reg): Likewise.
- (check_qword_reg): Likewise.
- (check_word_reg): Likewise.
- (finalize_imm): Likewise.
- (process_operands): Likewise.
- (build_modrm_byte): Likewise.
- (output_insn): Likewise.
- (output_branch): Likewise.
- (output_jump): Likewise.
- (output_interseg_jump): Likewise.
- (output_disp): Likewise.
- (output_imm): Likewise.
-
-2002-03-07 Daniel Jacobowitz <drow@mvista.com>
-
- * doc/as.texinfo: Wrap @menu in @ifnottex, not @ifinfo.
-
-2002-03-06 Alan Modra <amodra@bigpond.net.au>
-
- * config/tc-i386.c (tc_gen_reloc): Don't attempt to handle 8 byte
- relocs except when BFD64.
-
- * write.c (number_to_chars_bigendian): Don't abort when N is
- larger than sizeof (VAL).
- (number_to_chars_littleendian): Likewise.
-
-2002-03-05 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * config/tc-hppa.c (md_apply_fix3): Add cast.
- (hppa_fix_adjustable): Adjust list of selectors using e_lrsel and
- e_rrsel.
-
-2002-03-05 Paul Koning <pkoning@equallogic.com>
-
- * tc-pdp11.c: Use VAX float format support for PDP-11 target.
- (parse_ac5): New function for parsing float regs in float operand.
- (parse_expression): Remove attempt to make literals be octal.
- (parse_op_no_deferred): Support float literals.
- (parse_op): Reject attempts to refer to float regs.
- (parse_fop): New function, like parse_op but for float operand.
- (md_assemble): Add cases to parse float operands. Also fix
- IMM3, IMM6, IMM8 cases to pick up the operand from the right spot.
-
-2002-03-04 H.J. Lu <hjl@gnu.org>
-
- * config/obj-elf.c (special_section): Add .init_array,
- .fini_array and .preinit_array.
-
- * config/tc-ia64.h (ELF_TC_SPECIAL_SECTIONS): Remove
- .init_array and .fini_array.
-
-2002-03-01 Jakub Jelinek <jakub@redhat.com>
-
- * config/obj-elf.c (elf_copy_symbol_attributes): Don't copy
- visibility.
- (obj_frob_symbol): Copy visibility.
-
-2002-02-28 Jakub Jelinek <jakub@redhat.com>
-
- * config/tc-alpha.c (s_alpha_text): Use obj_elf_text for OBJ_ELF, not
- s_text.
- (s_alpha_data): Use obj_elf_data for OBJ_ELF, not s_data.
-
-2002-02-27 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/es.po: Updated.
-
-2002-02-26 Chris Demetriou <cgd@broadcom.com>
-
- * config/tc-mips.c (mips_need_elf_addend_fixup): For embedded-PIC
- only, undo the changes made on 2001-06-08, with the
- effect being that common or extern symbols are
- adjusted for embedded-PIC, but weak symbols are not.
- (md_estimate_size_before_relax: Likewise, with the effect
- that extern symbols are treated the same as weak symbols
- only if not embedded-PIC.
- (mips_fix_adjustable) Likewise, with the effect that
- weak or extern symbols are not adjusted for embedded-PIC.
- (md_apply_fix3): Tweak so that the case where value is zero
- is handled more correctly for embedded-PIC code.
-
-2002-02-26 Nick Clifton <nickc@cambridge.redhat.com>
-
- * doc/as.texinfo (Overview): Add missing @ifset IA64
-
- * configure.in (LINGUAS): Add es.po.
+ * config/tc-mips.c (RELAX_ENCODE): Remove WARN argument.
+ (RELAX_FIRST, RELAX_SECOND): Turn into 8-bit quantities.
+ (RELAX_USE_SECOND): Bump to 0x10000.
+ (RELAX_SECOND_LONGER, RELAX_NOMACRO, RELAX_DELAY_SLOT): New flags.
+ (mips_macro_warning): New variable.
+ (md_assemble): Wrap macro expansion in macro_start() and macro_end().
+ (s_cpload, s_cpsetup, s_cprestore, s_cpreturn): Likewise.
+ (relax_close_frag): Set mips_macro_warning.first_frag. Adjust use
+ of RELAX_ENCODE.
+ (append_insn): Update mips_macro_warning.sizes.
+ (macro_start, macro_warning, macro_end): New functions.
+ (macro_build): Don't emit warnings here.
+ (macro_build_lui, md_estimate_size_before_relax): ...or here.
+ (md_convert_frag): Check for cases where one macro alternative
+ needs a warning and the other doesn't. Emit a warning if the
+ longer sequence was chosen.
+
+2004-01-23 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-mips.h (tc_frag_data_type, TC_FRAG_TYPE): Remove.
+ * config/tc-mips.c (RELAX_ENCODE): Take three arguments: the size of
+ the first sequence, the size of the second sequence, and a flag
+ that says whether we should warn.
+ (RELAX_OLD, RELAX_NEW, RELAX_RELOC[123]): Delete.
+ (RELAX_FIRST, RELAX_SECOND): New.
+ (mips_relax): New variable.
+ (relax_close_frag, relax_start, relax_switch, relax_end): New fns.
+ (append_insn): Remove "place" argument. Use mips_relax.sequence
+ rather than "place" to check whether we're expanding the second
+ alternative of a relaxable macro. Remove redundant check for
+ branch relaxation. If generating a normal insn, and there
+ is not enough room in the current frag, call relax_close_frag()
+ to close it. Update mips_relax.sizes[]. Emit fixups for the
+ second version of a relaxable macro. Record the first relaxable
+ fixup in mips_relax. Remove tc_gen_reloc workaround.
+ (macro_build): Remove all uses of "place". Use mips_relax.sequence
+ in the same way as in append_insn.
+ (mips16_macro_build): Remove "place" argument.
+ (macro_build_lui): As for macro_build. Don't drop the add_symbol
+ when generating the second version of a relaxable macro.
+ (load_got_offset, add_got_offset): New functions.
+ (load_address, macro): Use new relaxation machinery. Remove
+ tc_gen_reloc workarounds.
+ (md_estimate_size_before_relax): Set RELAX_USE_SECOND if the second
+ version of a relaxable macro is needed. Return -RELAX_SECOND if the
+ first version is needed.
+ (tc_gen_reloc): Remove relaxation handling.
+ (md_convert_frag): Go through the fixups for a relaxable macro and
+ mark those that belong to the unneeded alternative as done. If the
+ second alternative is needed, adjust the fixup addresses to account
+ for the deleted first alternative.
+
+2004-01-23 Richard Sandiford <rsandifo@redhat.com>
+
+ * frags.h (frag_room): Declare.
+ * frags.c (frag_room): New function.
+ * doc/internals.texi: Document it.
+
+2004-01-22 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (append_insn): Don't do r3900 interlock
+ optimization for -mtune=r3900, as this will break on other CPUs.
+
+2004-01-11 Tom Rix <tcrix@worldnet.att.net>
+
+ * config/tc-m68hc11.c (build_indexed_byte): movb and movw cannot
+ be relaxed, use fixup.
+ (md_apply_fix3): Use 5 bit reloc from movb and movw fixup.
+
+2004-01-19 Jakub Jelinek <jakub@redhat.com>
+
+ * config/tc-sparc.c (sparc_ip): Disallow %f32-%f63 for single
+ precision operands.
+
+2004-01-14 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * config/tc-mips.c (append_insn): Properly detect variant frags
+ that preclude swapping of relaxed branches. Correctly swap
+ instructions between frags when dealing with relaxed branches.
+
+2004-01-14 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * acinclude.m4: Quote names of macros to be defined by AC_DEFUN
+ throughout.
+ * aclocal.m4: Regenerate.
* configure: Regenerate.
- * po/es.po: New file.
-
-2002-02-25 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (set_at): Fix handling of 64bit register loads.
- (macro): Likewise. Fix la/dla address expansions for EMBEDDED_PIC
- and NO_PIC cases. Code cleanup.
- (macro2): Fix handling of 64bit register loads.
-
-2002-02-25 David Mosberger <davidm@hpl.hp.com>
-
- * doc/as.texinfo: Add entry for IA64.
- * doc/c-ia64.texi: New file.
-2002-02-25 Alan Modra <amodra@bigpond.net.au>
-
- * config/tc-hppa.c: Update copyright date.
-
- * doc/c-ppc.texi (PowerPC-Opts): Add -mpower4, -maltivec and -m7400
- Remove references to chip manufacturers.
- * config/tc-ppc.c (md_parse_option): Handle -mpower4 option.
- Correct comments.
- (md_show_usage): Remove references to chip manufacturers. Mention
- -mpower4.
- (md_begin): Test power4 opcode flag bits.
-
-2002-02-22 David Mosberger <davidm@hpl.hp.com>
-
- * config/tc-ia64.c (dot_restore): Issue error message of epilogue
- count exceeds prologue count.
- (md_show_usage): Describe -mconstant-gp and -mauto-pic.
- (unwind.label_prologue_count): New member.
-
- Based on a patch by Hans Boehm <hboehm@hpl.hp.com>:
-
- (get_saved_prologue_count): New function.
- (save_prologue_count): New function.
- (free_saved_prologue_count): New function.
- (dot_label_state): Record state label by calling save_prologue_count().
- (dot_copy_state): Restore prologue count by calling
- get_saved_prologue_count().
- (generate_unwind_image): Free up list of saved prologue
- counts by calling free_saved_prologue_counts().
-
-2002-02-22 Nick Clifton <nickc@cambridge.redhat.com>
-
- * config/tc-tic54x.c: Add missing prototypes and remove ANSI style
- function declarations.
-
-2002-02-21 Nick Clifton <nickc@cambridge.redhat.com>
-
- * NEWS: Note that GASP is now deprecated.
- * Makefile.am: Do not build gasp-new by default.
+2004-01-12 Anil Paranjpe <anilp1@KPITCummins.com>
+
+ * config/tc-h8300.c (build_bytes): Apply relaxation to bit
+ manipulation insns.
+
+2004-01-12 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-mips.c (macro_build_jalr): When adding an R_MIPS_JALR
+ reloc, reserve space for the delay slot as well as the jalr itself.
+
+2004-01-09 Paul Brook <paul@codesourcery.com>
+
+ * config/tc-arm.c (do_vfp_reg2_from_sp2): Rename from do_vfp_sp_reg2.
+ (do_vfp_sp2_from_reg2): New function.
+ (insns): Use them.
+ (do_vfp_dp_from_reg2): Check return values properly.
+
+2004-01-08 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * config/tc-mips.c (warn_nops): Remove static variable.
+ (macro): Remove test of warn_nops.
+ (md_shortops): Remove 'n'.
+ (md_parse_option): Remove 'n' case.
+ (md_show_usage): Remove -n.
+ * doc/as.texinfo (Overview): Remove MIPS -n option.
+ * doc/c-mips.texi (MIPS Opts): Remove mention -n.
+ * NEWS: Mention removal of MIPS -n option.
+
+ * config/tc-mips.c (ISA_HAS_COPROC_DELAYS): Remove.
+ (cop_interlocks): Check ISA level.
+ (cop_mem_interlocks): Define.
+ (reg_needs_delay): Check cop_interlocks rather than
+ ISA_HAS_COPROC_DELAYS.
+ (append_insn): Likewise. Use cop_mem_interlocks rather than
+ directly checking mips_opts.isa.
+ (mips_emit_delays): Likewise.
+
+2004-01-07 H.J. Lu <hongjiu.lu@intel.com>
+
+ * config/tc-ia64.c (unwind): Move next_slot_number and
+ next_slot_frag to ...
+ (unw_rec_list): Here.
+ (free_list_records): Removed.
+ (output_unw_records): Likewise.
+ (generate_unwind_image): Make it void.
+ (alloc_record): Initialize next_slot_number and next_slot_frag.
+ (slot_index): Take .org, .space and .align into account.
+ (fixup_unw_records): Don't set slot_number to 0. Use
+ list->next_slot_number and list->next_slot_frag instead of
+ unwind.next_slot_number and unwind.next_slot_frag.
+ (ia64_convert_frag): New.
+ (generate_unwind_image): Generate a rs_machine_dependent frag
+ for unwind record.
+ (emit_one_bundle): Use list->next_slot_number and
+ list->next_slot_frag instead of unwind.next_slot_number and
+ unwind.next_slot_frag.
+
+ * config/tc-ia64.h (md_convert_frag): Defined as
+ ia64_convert_frag.
+ (md_estimate_size_before_relax): Defined as (f)->fr_var.
+
+2004-01-06 Alexandre Oliva <aoliva@redhat.com>
+
+ 2003-12-19 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-frv.h (md_apply_fix3): Don't define.
+ * config/tc-frv.c (md_apply_fix3): New. Shift/truncate %hi/%lo
+ operands.
+ * config/tc-frv.h (TC_FORCE_RELOCATION_SUB_LOCAL): Define.
+ 2003-10-07 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-frv.c (line_separator_chars): Add `!'.
+ 2003-09-19 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-frv.c (md_assemble): Clear insn upfront.
+ 2003-09-18 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-frv.c (OPTION_FDPIC): New macro.
+ (md_longopts): Add mfdpic.
+ (md_parse_option): Handle it.
+ 2003-08-04 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-frv.c (md_cgen_lookup_reloc) <FRV_OPERAND_D12,
+ FRV_OPERAND_S12>: Use reloc type encoded in fix-up.
+ (frv_pic_ptr): Parse funcdesc.
+
+2004-01-05 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * doc/as.texinfo: Let texi2pod parse asconfig.texi and
+ gasver.texi. Remove duplicate symbol definitions for texi2pod.
+
+2004-01-05 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * Makefile.am (Makefile): Move the dependency on
+ $(BFDDIR)/configure.in to...
+ (CONFIG_STATUS_DEPENDENCIES): ... here.
+ (AUTOMAKE_OPTIONS): Require automake 1.8.
* Makefile.in: Regenerate.
- * doc/Makefile.am: Do not install gasp.info.
+ * doc/Makefile.am (BASEDIR, BFDDIR): Define.
+ (CONFIG_STATUS_DEPENDENCIES): Add a dependency on
+ $(BFDDIR)/configure.in here as well.
* doc/Makefile.in: Regenerate.
- * gas/gasp.texi: Note that gasp is now deprecated.
-
-2002-02-20 Nick Clifton <nickc@cambridge.redhat.com>
-
- * NEWS: Mark 2.12 branch.
-
-2002-02-19 Tom Tromey <tromey@redhat.com>
-
- * config/tc-xstormy16.h (DWARF2_LINE_MIN_INSN_LENGTH): Define.
-
-2002-02-19 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * config/tc-mips.c (md_parse_option): Complain about invalid -mabi
- option input.
-
-2002-02-19 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * config/tc-s390.c (md_parse_option): Add switches -m31 and -m64.
- Make bit size independent of architecture switch.
- (md_begin): Add warning for -m64 with -Aesa.
- (s390_md_end): Use renamed architecture defines.
-
-2002-02-18 Daniel Jacobowitz <drow@mvista.com>
-
- * config/obj-coff.h: Check !target_big_endian, not shl, for coff-sh.
-
-2002-02-16 Nick Clifton <nickc@cambridge.redhat.com>
-
- * doc/as.texinfo (Machine Dependencies): Fix typo: MMIX used
- instead of CRIS.
-2002-02-15 Chris Demetriou <cgd@broadcom.com>
+2004-01-05 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
- * config/tc-mips.c (md_estimate_size_before_relax): Really
- make sure we treat weak like extern only for ELF. (Fixes
- patch from 2001-07-25.)
-
-2002-02-15 Ben Elliston <bje@redhat.com>
-
- * doc/as.texinfo: Add duplicate directory entry so that "info gas"
- works as expected.
-
-2002-02-15 Hans-Peter Nilsson <hp@bitrange.com>
-
- * NEWS: Mention support for MMIX.
-
-2002-02-13 Chris Demetriou <cgd@broadcom.com>
-
- * config/tc-mips.c (mips_need_elf_addend_fixup): Restructure into
- a sequence of indpendent 'if' statements for easier debugging
- and future modification.
-
-2002-02-13 Matt Fredette <fredette@netbsd.org>
-
- * config/tc-m68k.c (md_show_usage): No longer display a
- hard-coded "68020" for the default CPU, instead display the
- canonical name of the true, configured default CPU.
- (m68k_elf_final_processing): Mark objects for sub-68020
- CPUs with the new EF_M68000 flag.
-
-2002-02-13 Andreas Schwab <schwab@suse.de>
-
- * config/tc-i386.c (tc_i386_fix_adjustable): Don't adjust
- pc-relative relocations to merge sections in 64-bit mode.
-
-2002-02-13 Ben Elliston <bje@redhat.com>
-
- * NEWS: Document floating point number handling in gasp.
- * gasp.c: Include <assert.h> and "xregex.h".
- (is_flonum): New function.
- (chew_flownum): Likewise.
- (change_base): Consume flonums from the input, where possible.
- * doc/gasp.texi (Constants): Document floating point numbers.
-
-2002-02-12 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * config/tc-hppa.c (hppa_fix_adjustable): Don't adjust final types
- that implicitly use LR and RR selectors.
-
-2002-02-12 Alexandre Oliva <aoliva@redhat.com>
-
- * config/tc-mn10300.c (other_registers): Added `epsw'. Mark `pc'
- and `epsw' as available on AM33 and above only.
- (other_register_name): Add logic to handle machine type encoded in
- reg_number.
-
-2002-02-11 Tom Rix <trix@redhat.com>
-
- * config/tc-ppc.c (md_apply_fix3): Check for insert fop invalid for
- xcoff64.
-
-2002-06-11 Alexandre Oliva <aoliva@redhat.com>
-
- * config/tc-sparc.c (U0x80000000, U0xffffffff): New constants.
- Use all over.
-
-2002-02-11 Jan Hubicka <jh@suse.cz>
-
- * i386.c (md_assemble): Support 32bit address prefix.
- (i386_displacement): Likewise.
- (i386_index_check): Accept 32bit addressing in 64bit mode.
-
-2002-02-11 Alexandre Oliva <aoliva@redhat.com>
-
- * config/tc-sh.c (dot): Removed unused function.
-
-2002-02-11 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: "make dep-am".
+ * Makefile.am (install, install-info, RECURSIVE_TARGETS): Remove.
* Makefile.in: Regenerate.
* aclocal.m4: Regenerate.
- * config.in: Regenerate.
- * configure: Regenerate.
+ * doc/Makefile.am (install, install-info): Remove.
+ (install-data-local): A new hook for install-info.
+ (AUTOMAKE_OPTIONS): Require automake 1.8.
* doc/Makefile.in: Regenerate.
-2002-02-10 Richard Henderson <rth@redhat.com>
-
- * doc/c-alpha.texi: New file.
- * doc/Makefile.am (CPU_DOCS): Add it.
- * doc/all.texi, doc/as.texinfo: Add hooks for Alpha.
-
-2002-02-09 Richard Henderson <rth@redhat.com>
-
- * config/tc-alpha.c (O_samegp): New.
- (USER_RELOC_P): Include it.
- (alpha_reloc_op_tag, debug_exp, find_macro_match): Add it.
- (md_apply_fix3): Handle BFD_RELOC_ALPHA_BRSGP.
- (alpha_force_relocation, alpha_fix_adjustable): Likewise.
- (alpha_validate_fix): New.
- * config/tc-alpha.h (TC_VALIDATE_FIX): New.
-
-2002-02-09 Hans-Peter Nilsson <hp@axis.com>
-
- * doc/c-cris.texi: New.
- * doc/all.texi: @set CRIS.
- * doc/as.texinfo: Ditto. Add CRIS gas manpage option overview.
- Include c-cris.texi.
- * doc/Makefile.am (CPU_DOCS): Add c-cris.texi
- * doc/Makefile.in: Regenerate.
+2004-01-02 Nutan Singh <nutan@kpitcummins.com>
-2002-02-08 Chris Demetriou <cgd@broadcom.com>
-
- * config/tc-mips.c (IS_SEXT_32BIT_NUM): New macro to
- determine if a number is a sign-extended 32-bit number.
- (load_register): Use IS_SEXT_32BIT_NUM.
- (macro): Check if load/store macro handling is using a
- constant 32-bit address on 64-bit address systems, and if
- so optimize the generation of that address.
-
-2002-02-08 Richard Henderson <rth@redhat.com>
-
- * config/tc-alpha.c (alpha_force_relocation): Don't assert that
- we've eliminated all foreign relocation types yet.
- (alpha_fix_adjustable): Likewise.
-
-2002-02-08 Alexandre Oliva <aoliva@redhat.com>
-
- Contribute sh64-elf.
- 2002-02-08 Alexandre Oliva <aoliva@redhat.com>
- Stephen Clarke <Stephen.Clarke@st.com>
- * doc/c-sh64.texi: Fix citation of SH64 architecture manual.
- 2002-01-31 Alexandre Oliva <aoliva@redhat.com>
- * config/tc-sh.c (md_relax_table): Added default sizes for
- non-PC-relative UNDEF_MOVI, and relaxation sequences for
- MOVI_16, MOVI_32 and MOVI_48.
- * config/tc-sh64.c (shmedia_md_apply_fix3): Fix warning.
- (shmedia_md_convert_frag): Handle non-PC-relative UNDEF_MOVI
- and MOVI_16.
- (shmedia_md_estimate_size_before_relax): Remove redundant
- blocks. Set fragP->fr_var even if relaxation type unchanged.
- Retain UNDEF_MOVI until expression decays to number.
- 2002-01-24 Alexandre Oliva <aoliva@redhat.com>
- * config/tc-sh64.c (shmedia_init_reloc): Handle new SHmedia PIC
- relocation types. Take fixP->fx_addnumber into account too.
- (shmedia_md_apply_fix): Likewise.
- (shmedia_md_convert_frag): Likewise.
- (shmedia_build_Mytes): Likewise.
- (sh64_consume_datalabel): Complain about nested datalabel.
- Support PIC relocs. Call sh_parse_name.
- * config/tc-sh64.h (TC_RELOC_RTSYM_LOC_FIXUP): Extend definition
- in tc-sh.h to SHmedia reloc types.
- * config/tc-sh.c (SH64PCRELPLT, MOVI_PLT, MOVI_GOTOFF,
- MOVI_GOTPC): New relaxation constants.
- (md_relax_table): Introduce relaxation directives for PIC-related
- constants.
- (sh_PIC_related_p): Handle datalabel.
- (sh_check_fixup): Choose SH5 PIC relocations.
- (sh_cons_fix_new): Added BDF_RELOC_64.
- (md_apply_fix3, sh_parse_name): Handle GOTPLT.
- 2002-01-18 Alexandre Oliva <aoliva@redhat.com>
- * config/tc-sh64.c (sh64_max_mem_for_rs_align_code): If the
- current ISA is SHmedia, get 7 bytes.
- 2001-11-28 Nick Clifton <nickc@cambridge.redhat.com>
- * config/tc-sh.c (md_apply_fix3): Treat shmedia_md_apply_fix3 as a
- void function.
- * config/tc-sh64.c (shmedia_apply_fix): Rename to
- shmedia_apply_fix3 and make void.
- 2001-05-17 Alexandre Oliva <aoliva@redhat.com>
- * config/tc-sh64.c (s_sh64_abi): Remove unused arguments passed to
- as_bad.
- 2001-04-12 Alexandre Oliva <aoliva@redhat.com>
- * config/tc-sh64.h (md_parse_name): Take &c as argument.
- 2001-03-14 DJ Delorie <dj@redhat.com>
- * doc/Makefile.am (CPU_DOCS): Added c-sh64.texi
- * doc/Makefile.in(CPU_DOCS): Ditto.
- * doc/c-sh64.texi: New file.
- * doc/as.texinfo: Add SH64 support.
- 2001-03-13 DJ Delorie <dj@redhat.com>
- * config/tc-sh64.c (shmedia_get_operands): Rename A_RESV_Fx to
- A_REUSE_PREV so that its purpose is more obvious.
- (shmedia_build_Mytes): Ditto.
- 2001-03-07 DJ Delorie <dj@redhat.com>
- * config/tc-sh64.c (sh64_vtable_entry): New, strip datalabels
- before processing.
- (sh64_vtable_inherit): Ditto.
- (strip_datalabels): New, strip "datalabel" from given line.
- * config/tc-sh.c (md_pseudo_table): Add sh64-specific vtable
- pseudos.
- 2001-03-06 Hans-Peter Nilsson <hpn@cygnus.com>
- * config/tc-sh64.c (shmedia_md_assemble): Move dwarf2_emit_insn
- call ...
- (shmedia_build_Mytes): ... to here.
- 2001-03-06 DJ Delorie <dj@redhat.com>
- * config/tc-sh.c: Remove sh64-specific uaquad now that there
- is a generic one.
- 2001-01-21 Hans-Peter Nilsson <hpn@cygnus.com>
- * config/tc-sh64.h (DWARF2_LINE_MIN_INSN_LENGTH): Override.
- * config/tc-sh64.c (shmedia_md_assemble): Offset recorded insn
- address by one in call to dwarf2_emit_insn.
- 2001-01-13 Hans-Peter Nilsson <hpn@cygnus.com>
- Implement ".abi" pseudo and correct .cranges descriptors. Correct
- alignment handling broken by imported changes.
- * config/tc-sh64.h (HANDLE_ALIGN): Override definition in tc-sh.h.
- (sh64_handle_align): Declare.
- (MAX_MEM_FOR_RS_ALIGN_CODE): Override definition in tc-sh.h.
- (sh64_max_mem_for_rs_align_code): Declare.
- (enum sh64_isa_values): Moved here from tc-sh64.c.
- (md_do_align): Define.
- (sh64_do_align): Declare.
- (struct sh64_tc_frag_data): New.
- (TC_FRAG_TYPE): Change to struct sh64_tc_frag_data. Users
- changed.
- (TC_FRAG_INIT): Change to set new datatype.
- (struct sh64_segment_info_type): Rename member
- last_flushed_location to last_contents_mark. All users changed.
- (md_elf_section_change_hook, TC_CONS_FIX_NEW): Do not define.
- (shmedia_elf_new_section, sh64_tc_cons_fix_new): Do not prototype.
- * config/tc-sh.c (md_pseudo_table): Add ".abi".
- (sh_elf_cons) [HAVE_SH64]: Call sh64_update_contents_mark instead
- of unsetting seen_insn.
- (md_assemble) [HAVE_SH64] <before new SHcompact sequence>: Also
- call sh64_update_contents_mark.
- (sh_handle_align): Remove HAVE_SH64-conditioned code.
- * config/tc-sh64.c (sh64_isa_mode): Correct type from boolean to
- enum sh64_isa_values.
- (sh64_set_contents_type): Drop segT parameter. All callers changed.
- (emitting_crange): Boolean guard moved to file scope from function
- scope in sh64_set_contents_type.
- (s_sh64_abi): New.
- (sh64_update_contents_mark): New; most split out from
- sh64_flush_pending_output.
- (shmedia_md_end): Call sh64_update_contents_mark. Set
- sh64_isa_mode to sh64_isa_sh5_guard unless sh64_isa_unspecified.
- (sh64_do_align): New function.
- (sh64_max_mem_for_rs_align_code): New function.
- (sh64_handle_align): Rename from shmedia_do_align. Make
- non-static. Add head comment. Emit zero bytes for n bytes modulo
- four. Change return-type to void.
- (shmedia_elf_new_section): Remove.
- (shmedia_md_assemble): Call sh64_update_contents_mark.
- (s_sh64_mode): Ditto. Do not call md_flush_pending_output. Make
- new frag. Call sh64_update_contents_mark after making the new
- frag.
- (sh64_flush_pending_output): Just call sh64_update_contents_mark
- and sh_flush_pending_output.
- (sh64_flag_output): Also call md_flush_pending_output, but add
- condition on not emitting_crange.
- (sh64_tc_cons_fix_new): Remove.
- 2001-01-12 Nick Clifton <nickc@redhat.com>
- * config/tc-sh64.c (shmedia_do_align): Fix to work with new
- alignment handling scheme imported from sourceware.
- 2001-01-12 Hans-Peter Nilsson <hpn@cygnus.com>
- * config/tc-sh64.h (TARGET_FORMAT): Define.
- (sh64_target_format): Prototype.
- * config/tc-sh64.c (sh64_target_mach): New function.
- 2001-01-07 Hans-Peter Nilsson <hpn@cygnus.com>
- * config/tc-sh64.c (shmedia_md_end): When equating a symbol, use
- zero_address_frag instead of copying the frag of the symbol.
- (shmedia_frob_file_before_adjust): Ditto.
- (shmedia_md_apply_fix) <case BFD_RELOC_SH_IMM_MEDLOW16>: Cast mask
- to valueT to remove signedness.
- (shmedia_md_convert_frag): Add parameter final. Rename parameter
- headers to output_bfd. Do not evaluate symbols if final is false;
- do emit fixups.
- (shmedia_md_estimate_size_before_relax) <case C (MOVI_IMM_32,
- UNDEF_MOVI) et al>: If symbol cannot be modified to be PC-relative
- to the current frag, call shmedia_md_convert_frag to emit fixups
- and make frag_wane neutralize the frag. Update comments.
- * config/tc-sh.c (md_convert_frag): Change caller of
- shmedia_md_convert_frag.
- 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
- * config/tc-sh64.h: Tweak comments and correct formatting.
- * config/tc-sh64.c: Ditto.
- (shmedia_md_convert_frag) <PT/PTA/PTB 32, 48 and 64 bit
- expansion, MOVI pcrel expansion>: Fix thinko calculating offset
- for the no-relocation case.
- (shmedia_check_limits): Fix range check being off-by-one for PTA.
- * config/tc-sh.c: Ditto. Add proper comments to #ifdef/#ifndef
- wrappers.
- (SH64PCREL16_F): Increment for proper max-PTA handling. Update
- comment.
- (SH64PCREL16_M, MOVI_16_M): Correct range thinko.
- (SH64PCREL48_M, MOVI_48_M): Similar; don't count in length of
- expansion.
- (SH64PCREL32_M, MOVI_32_M): Ditto; handle overflowing expression.
- Correct comment.
- 2001-01-05 Hans-Peter Nilsson <hpn@cygnus.com>
- * config/tc-sh64.c (shmedia_md_apply_fix) <second switch, case
- BFD_RELOC_SH_PT_16>: Set lowest bit in field to be relocated to 1.
- (shmedia_md_convert_frag) <case C (SH64PCREL16_32, SH64PCREL16) et
- al>: Set lowest bit of field to relocate to 1 and rest to empty,
- if reloc is emitted.
- 2000-12-31 Hans-Peter Nilsson <hpn@cygnus.com>
- New options plus bugfixes.
- * config/tc-sh.c (md_longopts): New options "-no-expand" and
- "-expand-pt32".
- (md_parse_option): Handle new options.
- (md_show_usage): Add blurb for new options.
- * config/tc-sh64.c (SHMEDIA_BFD_RELOC_PT): New macro.
- (sh64_expand, sh64_pt32): New variables.
- (shmedia_init_reloc): Handle BFD_RELOC_SH_PT_16.
- (shmedia_md_apply_fix): Hold original fixP->fx_r_type in
- orig_fx_r_type. Change SHMEDIA_BFD_RELOC_PT into
- BFD_RELOC_SH_PT_16. Handle BFD_RELOC_SH_PT_16 as pc-relative.
- <resolved previously-pc-relative relocs>: Handle
- SHMEDIA_BFD_RELOC_PT and BFD_RELOC_SH_PT_16.
- (shmedia_md_convert_frag) <case C (SH64PCREL16PT_64, SH64PCREL16),
- case C (SH64PCREL16PT_32, SH64PCREL16)>: Modify to PTB if operand
- points to SHcompact code.
- <case C (SH64PCREL16_32, SH64PCREL16), case C (SH64PCREL16_64,
- SH64PCREL16)>: Check that ISA of what operand points at and
- PTA/PTB matches, or emit error.
- (shmedia_check_limits): Handle BFD_RELOC_SH_PT_16 and
- SHMEDIA_BFD_RELOC_PT.
- (shmedia_immediate_op): If pcrel, emit fixup also for constant
- operand.
- (shmedia_build_Mytes) <case A_IMMS16>: Also check sh64_expand in
- condition for MOVI expansion.
- <case A_PCIMMS16BY4>: Handle expansion to 32 bits only, if
- sh64_pt32. Emit only a BFD_RELOC_SH_PT_16 fixup if not
- sh64_expand.
- <case A_PCIMMS16BY4_PT>: Likewise, but emit a SHMEDIA_BFD_RELOC_PT
- fixup.
- (sh64_target_format): Error-check setting of sh64_pt32 and
- sh64_expand. Fix typo in check for sh64_shcompact_const_crange.
- (shmedia_md_pcrel_from_section): Handle BFD_RELOC_SH_PT_16 and
- SHMEDIA_BFD_RELOC_PT as coming from SHmedia code.
- 2000-12-31 Hans-Peter Nilsson <hpn@cygnus.com>
- * config/tc-sh64.c: Improve comments.
- (shmedia_md_convert_frag): Remove inactive is_pt_variant code. Do
- not say the linker will check correctness of PTA/PTB expansion.
- (shmedia_md_end): Make non-static.
- * config/tc-sh64.h (md_end): Define to shmedia_md_end. Add
- prototype.
- * config/tc-sh.c (sh_finalize): Remove.
- * config/tc-sh.h (md_end): Do not define.
- Remove prototype for sh_finalize.
- 2000-12-30 Hans-Peter Nilsson <hpn@cygnus.com>
- * config/tc-sh64.c (shmedia_frob_section_type): Use a struct
- sh64_section_data container when storing section type in tdata
- field in elf_section_data.
- * config/tc-sh.c (sh_elf_final_processing): Change from EF_SH64 to
- EF_SH5.
- * Makefile.am: Update dependencies.
- * Makefile.in: Regenerate.
- 2000-12-22 Hans-Peter Nilsson <hpn@cygnus.com>
- * config/tc-sh64.c (shmedia_md_assemble): Don't protect
- dwarf2_emit_insn call with test on debug_type.
- 2000-12-19 Hans-Peter Nilsson <hpn@cygnus.com>
- * config/tc-sh64.c (sh64_set_contents_type): Make contents-type
- CRT_SH5_ISA32 sticky for 64-bit.
- 2000-12-18 Hans-Peter Nilsson <hpn@cygnus.com>
- Generate .crange sections when switching ISA mode or emitting
- constants in same section as code.
- * config/tc-sh64.c: Reformat structure definitions.
- (sh64_end_of_assembly, sh64_mix, sh64_shcompact_const_crange): New
- variables.
- (sh64_set_contents_type): Rename from sh64_init_section. Rewrite
- to emit a .cranges descriptor when contents type changes. Only
- emit error if changing contents type and -no-mix is in effect.
- (sh64_emit_crange, sh64_flush_last_crange, sh64_flag_output,
- sh64_flush_pending_output, sh64_tc_cons_fix_new): New functions.
- (shmedia_md_end): Set sh64_end_of_assembly. Pass
- sh64_flush_last_crange over sections.
- When checking main symbol of datalabel symbol, check for
- STO_SH5_ISA32, not ISA type of section in definition.
- (shmedia_frob_file_before_adjust): Check main symbol for
- STO_SH5_ISA32; don't check ISA type of section in definition.
- (shmedia_frob_section_type): Adjust for .cranges; set section flag
- to SHF_SH5_ISA32_MIXED or SHF_SH5_ISA32 according to whether
- .cranges entries have been output.
- (shmedia_elf_new_section): Just call md_flush_pending_output.
- (shmedia_md_assemble): Do not emit a BFD_RELOC_SH_SHMEDIA_CODE
- fix. Do not set tc_segment_info_data.in_code for section. Call
- sh64_set_contents_type for SHmedia code.
- (s_sh64_mode): Do not call sh64_init_section or set seen_insn to
- false. Call md_flush_pending_output.
- (sh64_target_format): Check that -no-mix and
- -shcompact-const-crange are used in sane combination with other
- options.
- (shmedia_md_pcrel_from_section): Check type of fix for how to
- adjust pc-relative.
- (sh64_consume_datalabel): Check symbol for having STO_SH5_ISA32,
- not ISA type of section in definition.
- * config/tc-sh64.h (struct sh64_segment_info_type): Rewrite to
- hold contents-type state.
- (md_flush_pending_output): Redefine to sh64_flush_pending_output.
- (sh64_flush_pending_output): Declare.
- (TC_CONS_FIX_NEW): Define to sh64_tc_cons_fix_new.
- (sh64_tc_cons_fix_new): Declare.
- * config/tc-sh.c (sh_elf_cons) [HAVE_SH64]: Unset seen_insn and
- call sh64_flag_output.
- (md_assemble) [HAVE_SH64]: Do not emit BFD_RELOC_SH_CODE. Just
- call sh64_set_contents_type to mark SHcompact code and set
- seen_insn.
- (md_longopts): New options "-no-mix" and
- "-shcompact-const-crange".
- (md_parse_option): Handle new options.
- (md_show_usage): Add blurb for new options.
- (md_number_to_chars) [HAVE_SH64]: Call sh64_flag_output.
- 2000-12-15 Hans-Peter Nilsson <hpn@cygnus.com>
- * config/tc-sh64.c: Delete investigated and obsolete fixme:s.
- (sh64_last_insn_frag): New.
- (shmedia_md_convert_frag): Use tc_frag_data field of incoming frag
- to get frag for insn opcode for generating fixups; do not assume it
- is the same frag.
- (shmedia_build_Mytes): Set sh64_last_insn_frag after growing frag
- for new insn.
- * config/tc-sh64.h (ELF_TC_SPECIAL_SECTIONS): Define for .cranges
- section.
- (TC_FRAG_TYPE): Define as fragS *.
- (TC_FRAG_INIT): Define to set tc_frag_data to sh64_last_insn_frag.
- (sh64_last_insn_frag): Declare.
- (sh64_consume_datalabel): Fix typo; check for seginfo != NULL,
- not == NULL before dereferencing.
- 2000-12-12 Hans-Peter Nilsson <hpn@cygnus.com>
- Get rid of BFD section flag and EF_SH64_ABI64.
- * config/tc-sh64.c (shmedia_frob_section_type): Use
- elf_section_data (sec)->tdata, not a specific BFD section flag, to
- communicate the section as containing SHmedia code. Describe why.
- * config/tc-sh.c (sh_elf_final_processing): Tweak comment. Set
- EF_SH64 regardless of ABI.
- * config/tc-sh64.c (shmedia_md_apply_fix): Decapitalize "invalid"
- in error message. Handle resolved expressions for
- BFD_RELOC_SH_IMMS10, BFD_RELOC_SH_IMMS10BY2,
- BFD_RELOC_SH_IMMS10BY4 and BFD_RELOC_64.
- (shmedia_check_limits): Handle BFD_RELOC_64.
- (sh64_adjust_symtab): Do not decrement the GAS symbol value for
- a STO_SH5_ISA32 symbol, only the BFD value.
- 2000-12-11 Ben Elliston <bje@redhat.com>
- * config/tc-sh64.c: Call dwarf2_emit_insn, not the defunct
- dwarf2_generate_asm_lineno.
- 2000-12-11 Hans-Peter Nilsson <hpn@cygnus.com>
- Handle PC-relative MOVI expansions with assembler relaxation.
- Generate PC-relative relocs from 16-bit PC-relative expressions.
- * config/tc-sh64.c (SHMEDIA_MD_PCREL_FROM_FIX): Break out from...
- (shmedia_md_pcrel_from_section): ...here.
- (shmedia_md_apply_fix): Handle fixups for 16-bit operands that has
- turned completely resolved. Adjust relocation type for 16-bit
- immediate operands that has turned PC-relative. Adjust back for
- MD_PCREL_FROM_SECTION being applied twice.
- (shmedia_md_convert_frag): Always emit reloc for expression with
- global or weak symbol. Handle relaxation result for PC-relative
- expressions.
- (shmedia_md_estimate_size_before_relax): An expression with a weak
- or global symbol can not be relaxed. Break out tests for
- relaxable symbol into variable sym_relaxable.
- <cases C (MOVI_IMM_64, UNDEF_MOVI) and C (MOVI_IMM_32,
- UNDEF_MOVI)>: Break out any PC-relative expression and change
- relaxation type.
- (shmedia_build_Mytes): CSE &operands->operands[j] into variable
- opjp.
- <case A_IMMS16>: Fix typo for initial minor relaxation type of
- MOVI expansion. If X_op_symbol of the immediate expression is
- set, make an expression symbol for the argument to frag_var.
- * config/tc-sh.c (MOVI_IMM_32_PCREL, MOVI_IMM_64_PCREL): New
- relaxations.
- (END): Adjust for new relaxations.
- (md_relax_table): Add entries for new relaxations.
- 2000-12-07 Ben Elliston <bje@redhat.com>
- * config/tc-sh64.c (shmedia_parse_reg): Initialize variable len.
- 2000-12-07 Hans-Peter Nilsson <hpn@cygnus.com>
- * config/tc-sh64.c (shmedia_md_convert_frag): Correct all MOVI and
- SHORI operand offsets in PT/PTA/PTB expansions.
- 2000-12-05 Hans-Peter Nilsson <hpn@cygnus.com>
- Implement DataLabel semantics.
- * config/tc-sh.c (sh_frob_file) [HAVE_SH64]: Call
- shmedia_frob_file_before_adjust.
- * config/tc-sh64.c [! OBJ_ELF]: Emit #error.
- (DATALABEL_SUFFIX): Define.
- (shmedia_md_end) <before adjusting STO_SH5_ISA32 symbols>: Walk
- symbol list to update "datalabel" symbols to their main symbol
- counterparts.
- (shmedia_frob_file_before_adjust): New.
- (sh64_adjust_symtab): For remaining datalabel symbols, set to
- undefined and set STT_DATALABEL.
- (sh64_frob_label): Initialize TC symbol field.
- (sh64_consume_datalabel): Actually implement semantics. New
- parameter operandf, call it instead of expression.
- (sh64_exclude_symbol): New.
- * config/tc-sh64.h (md_parse_name): Pass on the function operand
- to sh64_consume_datalabel.
- (tc_symbol_new_hook): Define to tc_frob_symbol.
- (TC_SYMFIELD_TYPE): Define to symbolS *.
- (tc_frob_symbol): Define to call sh64_exclude_symbol.
- 2000-12-01 Hans-Peter Nilsson <hpn@cygnus.com>
- * config/tc-sh64.c (shmedia_init_reloc): Tweak comment for default
- case.
- (shmedia_md_assemble): Call dwarf2_generate_asm_lineno if
- generating dwarf2 debug information.
- 2000-11-30 Hans-Peter Nilsson <hpn@cygnus.com>
- * config/tc-sh64.c (sh64_target_format): Use elf64-sh64l and
- elf64-sh64 for the 64-bit ABI.
- * config/tc-sh.c (md_show_usage): Tweak usage output for -abi=*
- option.
- 2000-11-29 Hans-Peter Nilsson <hpn@cygnus.com>
- * config/tc-sh.c: Remove conditionalizing on HAVE_SH64 for
- case-insensitivity.
- 2000-11-27 Hans-Peter Nilsson <hpn@cygnus.com>
- * config/tc-sh64.c: Tweak comments, formatting and error messages.
- (enum sh64_abi_values): New type.
- (enum sh64_isa_values): New type.
- (sh64_isa_mode): Replace shmedia_mode. All referers changed.
- (seen_shcompact_mode, seen_shmedia_mode): Delete.
- (sh64_abi): Replace shmedia_64.
- (shmedia_md_convert_frag) <C (MOVI_IMM_64, MOVI_64),
- C (MOVI_IMM_32, MOVI_32)>: Correct register number handling.
- (s_sh64_mode): Check validity for this target.
- (sh64_target_format): Initialize defaults for ISA and ABI.
- Fallback to old object format if no SH64 ISA or ABI has been
- specified.
- * config/tc-sh.c (md_parse_option): Check combinations for errors.
- (sh_elf_final_processing): Change to have EF_SH64_ABI64 for 64-bit
- ABI and EF_SH64 for 32-bit ABI, if SH64 options are specified.
- * config/tc-sh64.h: Fix typo in comment.
- 2000-11-25 Hans-Peter Nilsson <hpn@cygnus.com>
- * config/tc-sh64.c (shmedia_md_estimate_size_before_relax)
- <PT fixups for absolute values>: Size will be longest, not
- shortest.
- (shmedia_md_convert_frag): Disable PTB-warning machinery. Correct
- all MOVI and SHORI operand offsets in PT/PTA/PTB expansions.
- * config/tc-sh.c (parse_reg) [HAVE_SH64]: Add local variables l0
- and l1 to hold lowercase of two first characters. Change all
- remaining TO_LOWER to tolower.
- * config/tc-sh64.c (TO_LOWER): Delete.
- (shmedia_find_cooked_opcode): Use tolower, not TO_LOWER.
- (md_parse_name): Define.
- (sh64_consume_datalabel): Declare.
- (DOLLAR_DOT): Define.
- * config/tc-sh64.c (shmedia_parse_exp): New.
- (sh64_consume_datalabel): New; just ignoring datalabel semantics.
- (shmedia_parse_reg): Remove const from src
- parameter.
- (shmedia_get_operands): Ditto for args parameter and ptr variable.
- (shmedia_md_assemble): Ditto for op_end variable.
- (shmedia_get_operand): Ditto for ptr parameter and src variable.
- Use shmedia_parse_exp, not parse_exp.
- * config/tc-sh64.c (shmedia_parse_reg): Add shmedia_arg_type
- parameter. All callers changed.
- (shmedia_get_operand): Add shmedia_arg_type parameter. All
- callers changed.
- (shmedia_parse_reg): Put first two character in local variables.
- Use tolower, not TO_LOWER. If no register is found and argtype
- indicates a control register, scan shmedia_creg_table
- case-insensitive.
- 2000-11-24 Hans-Peter Nilsson <hpn@cygnus.com>
- * Makefile.am (CPU_TYPES): Add sh64.
- (TARGET_CPU_CFILES): Add config/tc-sh64.c.
- (TARGET_CPU_HFILES): Add config/tc-sh64.h.
- Regenerate dependencies.
- * Makefile.in: Regenerate.
- * configure.in: Add support for sh64-*-elf*.
- * configure: Regenerate.
- * config/tc-sh64.h: New.
- * config/tc-sh64.c: New.
- * config/tc-sh.c (md_pseudo_table) [HAVE_SH64]: New pseudos
- .mode, .isa and .uaquad.
- [HAVE_SH64] (SH64PCREL16_32, SH64PCREL16_64, SH64PCREL16PT_32,
- SH64PCREL16PT_64, MOVI_IMM_32, MOVI_IMM_64): Define.
- [HAVE_SH64] (END): Define as 10.
- [HAVE_SH64] (UNDEF_SH64PCREL, SH64PCREL16, SH64PCREL32,
- SH64PCREL48, SH64PCREL64, UNDEF_MOVI, MOVI_16, MOVI_32, MOVI_48,
- MOVI_64): Define.
- [HAVE_SH64] (SH64PCREL16_F, SH64PCREL16_M, SH64PCREL16_LENGTH,
- SH64PCREL32_F, SH64PCREL32_M, SH64PCREL32_LENGTH, SH64PCREL48_F,
- SH64PCREL48_M, SH64PCREL48_LENGTH, SH64PCREL64_LENGTH,
- MOVI_16_LENGTH, MOVI_32_LENGTH, MOVI_48_LENGTH, MOVI_64_LENGTH):
- Define.
- (md_relax_table) [HAVE_SH64]: Provide relaxations for SHmedia.
- (md_begin) [HAVE_SH64]: Call shmedia_md_begin.
- (parse_reg) [HAVE_SH64]: Parse register names case-insensitive.
- (md_assemble) [HAVE_SH64]: Call shmedia_md_assemble if assembling
- SHmedia instructions. Handle state-change after switching to
- SHcompact.
- (md_longopts) [HAVE_SH64]: New options --isa=* and --abi=*.
- (md_parse_option) [HAVE_SH64]: Parse new options.
- (md_show_usage) [HAVE_SH64]: Show usage of new options.
- (md_convert_frag) [HAVE_SH64] <default>: Call
- shmedia_md_convert_frag instead of abort.
- (sh_force_relocation) [HAVE_SH64]: Also force relocation for
- BFD_RELOC_SH_SHMEDIA_CODE.
- (sh_elf_final_processing) [HAVE_SH64]: Set flags identifying
- SHcompact or SHmedia code.
- (md_apply_fix) [HAVE_SH64] <default>: Return result from calling
- shmedia_md_apply_fix instead of abort.
- (md_estimate_size_before_relax) [HAVE_SH64] <default>: Return
- result from calling shmedia_md_estimate_size_before_relax instead
- of calling abort.
- (sh_do_align) [HAVE_SH64]: If shmedia_mode, let shmedia_do_align
- do the work.
- (tc_gen_reloc) [HAVE_SH64]: For unrecognized relocs, call
- shmedia_init_reloc and do nothing more if it returns non-zero.
- (sh_finalize) [HAVE_SH64]: Call shmedia_md_end.
- * po/POTFILES.in: Regenerate.
- * po/gas.pot: Regenerate.
-
-2002-02-06 Alexandre Oliva <aoliva@redhat.com>
-
- * config/tc-sh.c (parse_at): Install the correct version of
- 2002-02-04's patch.
-
- * config/tc-sh.c (md_apply_fix3) <BFD_RELOC_32_PLT_PCREL>: Don't
- assume fixP->fx_subsy is non-NULL.
-
-2002-02-04 Alexandre Oliva <aoliva@redhat.com>
-
- * config/tc-sh.c (parse_at): Set arg type of @(expr,pc) to
- A_DISP_PC_ABS, and adjust it by -4.
- (get_specific): Accept A_DISP_PC_ABS where A_DISP_PC is
- expected.
- (build_Mytes): Mark PCRELIMM fix-ups as pc-relative only if
- the operand type is not A_DISP_PC_ABS.
-
-2002-02-04 Hans-Peter Nilsson <hp@bitrange.com>
-
- * config/tc-mmix.c (tc_gen_reloc): Don't try and take the value of
- common and weak symbols. Handle common and weak symbols as
- undefined symbols with regards to GREG handling and merging.
- (mmix_frob_file): Ditto.
-
-2002-02-02 Jason Thorpe <thorpej@wasabisystems.com>
-
- * configure.in (hppa-*-netbsd*): New target.
- * configure: Regenerate.
- * config/tc-hppa.h: Also define WARN_COMMENTS if TE_NetBSD.
-
-2002-02-02 Alan Modra <amodra@bigpond.net.au>
-
- * config/tc-v850.c: Add missing prototypes amd use old-style
- function definitions.
- (AREA_ZDA, AREA_SDA, AREA_TDA): Delete.
- (sdata_section tdata_section, zdata_section, sbss_section,
- tbss_section, zbss_section, rosdata_section, rozdata_section,
- scommon_section, tcommon_section, zcommon_section,
- call_table_data_section, call_table_text_section): Delete.
- (v850_sdata, v850_tdata, v850_zdata, v850_sbss, v850_tbss,
- v850_zbss, v850_bss, v850_rosdata, v850_rozdata,
- v850_call_table_data, v850_call_table_text): Delete.
- (struct v850_seg_entry): New.
- (v850_seg_table): New.
- (SDATA_SECTION TDATA_SECTION, ZDATA_SECTION, SBSS_SECTION,
- TBSS_SECTION, ZBSS_SECTION, BSS_SECTION, ROSDATA_SECTION,
- ROZDATA_SECTION, SCOMMON_SECTION, TCOMMON_SECTION, ZCOMMON_SECTION,
- CALL_TABLE_DATA_SECTION, CALL_TABLE_TEXT_SECTION): Define.
- (do_v850_seg): New.
- (v850_seg): New.
- (v850_comm): Use do_v850_seg and v850_seg_table. Simplify
- recording of alignment.
- (md_pseudo_table): Use v850_seg.
- (md_begin): Don't init .call_table_data and .call_table_text here.
- Set v850_seg_table bss entry.
-
-2002-02-01 Hans-Peter Nilsson <hp@bitrange.com>
-
- Support on-demand global register allocation by passing on
- base-plus-offset relocs to the linker.
- * config/tc-mmix.c: Tweak and fix typos in comments.
- (allocate_undefined_gregs_in_linker): New variable.
- (OPTION_LINKER_ALLOCATED_GREGS): New option macro.
- (md_longopts): Add --linker-allocated-gregs.
- (md_parse_option) <case 'x'>: Imply --linker-allocated-gregs.
- <case OPTION_LINKER_ALLOCATED_GREGS>: New.
- (md_show_usage): Update text for -x. Add text for
- --linker-allocated-gregs.
- (tc_gen_reloc): Derive default value for addend from val and
- baddsy. Use addsec and bfd_is_abs_section in more places. Don't
- emit error for BFD_RELOC_MMIX_BASE_PLUS_OFFSET without suitable
- GREG if allocate_undefined_gregs_in_linker.
- * doc/as.texinfo (Overview) <Target MMIX options>: Add
- --linker-allocated-gregs.
- * doc/c-mmix.texi (MMIX-Opts): Add blurb about
- --linker-allocated-gregs. Mention that it's implied by -x.
- (MMIX-Pseudos) <GREG>: Mention when and how a GREG can be omitted.
- (MMIX-mmixal): Clarify dated comparison and location of MMIXware.
-
- * config/tc-mmix.h (md_parse_name): Use ISUPPER, not isupper.
-
-2002-02-01 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: Run "make dep-am"
- * Makefile.in: Regenerate.
+ * doc/c-sh.texi: Update description about floating point behavior
+ of SH family.
-2002-01-31 Ivan Guzvinec <ivang@opencores.org>
+2004-01-02 Bernardo Innocenti <bernie@develer.com>
- * config/tc-or32.c: New file.
- * config/tc-or32.h: New file.
- * configure.in: Add support for or32 targets.
+ * configure.in: Add m68k-uClinux target.
* configure: Regenerate.
- * config/obj-coff.c: Add support for or32 targets.
- * config/obj-coff.h: Add support for or32 targets.
- * Makefile.am: Add support for or32 targets.
- * Makefile.in: Regenerate.
- * NEWS: Mention support for OpenRISC.
- * doc/Makefile.in: Regenerate.
- * po/POTFILES.in: Regenerate.
- * po/gas.pot: Regenerate.
-
-2002-01-30 Richard Sandiford <rsandifo@redhat.com>
-
- * config/tc-sh.c (parse_reg): Fix end-of-word check for is, ix, iy
- and mod.
-
-2002-01-29 Chris Demetriou <cgd@broadcom.com>
-
- * config/tc-mips.c (tc_gen_reloc): Arrange for
- BFD_RELOC_PCREL_HI16_S relocations to be output relative to
- their LO16 parts, even for ELF.
-
-2002-01-29 Daniel Jacobowitz <drow@mvista.com>
-
- * config/tc-i386.c: Protect definitions of true and false
- from redefinition.
-
-2002-01-28 Jakub Jelinek <jakub@redhat.com>
-
- * config/obj-elf.c (elf_frob_file_before_adjust): Remove symbols
- made because of .weak, if they are neither defined nor used in any
- way.
-
-2002-01-27 Daniel Jacobowitz <drow@mvista.com>
-
- * configure: Regenerated.
-
-2002-01-26 Hans-Peter Nilsson <hp@bitrange.com>
-
- * doc/Makefile.am (install): Depend on install-info.
- * doc/Makefile.in: Regenerate.
-
-2002-01-26 Nick Clifton <nick@redhat.com>
-
- * po/fr.po: Updated version
-
-2002-01-24 Kazu Hirata <kazu@hxi.com>
-
- * config/tc-h8300.c (check_operand): Don't print a warning
- when a valid 24-bit address is given to a 16-bit address
- operand.
-
-2002-01-24 Alexandre Oliva <aoliva@redhat.com>
-
- * config/tc-sh.c (sh_elf_suffix): Removed.
- (sh_PIC_related_p, sh_check_fixup, sh_cons_fix_new,
- sh_end_of_match, sh_parse_name): New functions.
- (sh_elf_cons): Simplify.
- (parse_exp): Reject misplaced PIC operands.
- (md_undefined_symbol): Simplify.
- (sh_fix_adjustable): Let @GOTOFF be adjusted.
- (md_apply_fix3): Write @PLT and @GOTOFF addends in place.
- (tc_gen_reloc): Move fixp subsy absolute value into addnumber.
- Complain if subsy remains at the end.
- * config/tc-sh.h (sh_parse_name, sh_cons_fix_new): Declare.
- (md_parse_name, TC_CONS_FIX_NEW, O_PIC_reloc): Define.
-
-2002-01-22 Alexandre Oliva <aoliva@redhat.com>
-
- * config/tc-mn10300.c (xr_registers): Move `pc'...
- (other_registers): ... here.
-
-2002-01-22 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: Run "make dep-am".
- * Makefile.in: Regenerate.
- * gas/po/POTFILES.in: Regenerate.
-
-2002-01-21 DJ Delorie <dj@redhat.com>
-
- * config/obj-coff.c (obj_coff_init_stab_section): Make the
- stabstr_name allocation permanent, as it will be referenced from
- the section hash.
-
-2002-01-21 Jason Thorpe <thorpej@wasabisystems.com>
-
- * configure.in (ia64-*-netbsd*): New target.
- * configure: Regenerate.
-
-2002-01-21 Hans-Peter Nilsson <hp@bitrange.com>
-
- * doc/as.texinfo (Overview) <Target ARM options>: Add missing {}
- to @dots call.
- <Detailed description, ARM options>: Ditto.
- * doc/c-arm.texi (ARM Options): Ditto.
-
-2002-01-18 Richard Earnshaw <rearnsha@arm.com>
-
- * tc-arm.c (do_xsc_mia, do_xsc_mar, do_xsc_mra): Renamed from
- do_mia, do_mar and do_mra respectively.
- (do_mav_*): Renamed from do_c_*.
- (mav_reg_required_here, mav_parse_offset): Renamed from
- cirrus_reg_required_here and cirrus_parse_offset respectively.
- (MAV_MODE?): Renamed from CIRRUS_MODE?.
-
-2002-01-18 Richard Earnshaw <rearnsha@arm.com>
- Keith Walker <keith.walker@arm.com>
-
- * tc-arm.c (ARM_EXT_V5J, ARM_ARCH_V5TEJ): Define.
- (insns): Add pattern for bxj instruction.
- (do_bxj): New function.
- (arm_cpus): Add arm926ej.
- (arm_archs): Add armv5tej.
-
-2002-01-18 Richard Earnshaw <rearnsha@arm.com>
-
- * doc/c-arm.texi: Add new fpe options to list of supported flags.
-
-2002-01-19 Keith Walker <keith.walker@arm.com>
-
- * tc-arm.c (arm_fpus): Add fpe2 and fpe3.
-
-2002-01-18 Richard Earnshaw <rearnsha@arm.com>
-
- * NEWS: Mention new ARM command-line options and VFP support.
-
- * config/tc-arm.c (ARM_CEXT_XSCALE): Replaces ARM_EXT_XSCALE. All
- uses changed.
- (ARM_CEXT_MAVERICK): Similarly.
- (ARM_ANY): Now means any core instruction.
- (CPU_DEFAULT): Default to ARM_ANY.
- (uses_apcs_26, atcps, support_interwork, uses_apcs_float)
- (pic_code): Declare for all object types. Make type int.
- (legacy_cpu, legacy_fpu, mcpu_cpu_opt, mcpu_fpu_opt, march_cpu_opt)
- (march_fpu_opt, mfpu_opt): Declare.
- (md_longopts): Tidy up conditional definitions.
- (arm_opts, arm_cpus, arm_archs, arm_fpus, arm_extensions)
- (arm_long_opts): New tables.
- (arm_parse_cpu, arm_parse_arch, arm_parse_fpu): New functions.
- (arm_parse_extension): New function.
- (md_parse_option): Rewrite using new table-driven system.
- (md_show_usage): Use new table-driven system.
- (md_begin): Calculate cpu_variant from command line option data.
- * doc/as.texinfo (ARM ISA options): Docuement new ARM-specific
- command-line options.
- * doc/c-arm.texi: Likewise.
-
-2002-01-18 Andreas Jaeger <aj@suse.de>
-
- * as.c (parse_args): Update year.
-
-2002-01-17 Timothy Wall <twall@alum.mit.edu>
-
- * config/tc-tic54x.c (encode_address): Add a more informative
- warning about incorrect syntax.
-
-2002-01-17 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/gas.pot: Regenerate.
-
-2002-01-17 Nick Clifton <nickc@cambridge.redhat.com>
-
- * macro.c (get_any_string): Add no-c-format comment to prevent
- confusion when translating string.
- * gasp.c (get_any_string): Add no-c-format comment to prevent
- confusion when translating string.
-
-2002-01-16 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
- Johannes Stezenbach <js@convergence.de>
- * config/tc-mips.c (percent_op): Ensure longer percent_op's are
- matched before the shorter ones.
- (my_getSmallParser): Fix handling of nested parentheses in
- percent_op's. Code cleanup.
- (my_getPercentOp): New function, code from my_getSmallParser.
- (my_getSmallExpression): Fix handling of closing parentheses.
- Code cleanup. Better comments.
-
-2002-01-16 Nick Clifton <nickc@redhat.com>
-
- po/tr.po: New file: Turkish translation.
- configure.in (LINGUAS): Add "tr".
- configure: Regenerate.
-
-2002-01-15 Richard Earnshaw <rearnsha@arm.com>
-
- Support for VFP instructions
- * tc-arm.c (CP_WB_OK, CP_NO_WB): New defines.
- (cp_address_required_here): New argument wb_ok. When false, do not
- accept write-back forms of addressing. Change all callers.
- (FPU_VFP_EXT_NONE, FPU_VFP_EXT_V1xD, FPU_VFP_VFP_V1)
- (FPU_VFP_EXT_V2): Define.
- (FPU_ARCH_VFP, FPU_ARCH_VFP_V1xD, FPU_ARCH_VFP_V1, FPU_ARCH_VFP_V2):
- Define in terms of above.
- (vfp_dp_reg_pos, vfp_sp_reg_pos, vfp_ldstm_type): New enums.
- (vfp_reg): New struct.
- (vfp_regs): New array of registers.
- (insns): Add VFP instructions.
- (sn_table): New array of VFP single-precision register names.
- (dn_table): New array of VFP double-precision register names.
- (all_reg_maps): Add the new register tables.
- (arm_reg_type): Add new values for above. Increase RET_TYPE_MAX.
- (vfp_sp_reg_required_here, vfp_dp_reg_required_here, do_vfp_sp_monadic)
- (do_vfp_dp_monadic, do_vfp_sp_dyadic, do_vfp_dp_dyadic)
- (do_vfp_reg_from_sp, do_vfp_sp_reg2, do_vfp_sp_from_reg)
- (do_vfp_reg_from_dp, do_vfp_reg2_from_dp, do_vfp_dp_from_reg)
- (do_vfp_dp_from_reg2, vfp_psr_parse, vfp_psr_required_here)
- (do_vfp_reg_from_ctrl, do_vfp_ctrl_from_reg, do_vfp_sp_ldst)
- (do_vfp_dp_ldst, vfp_sp_reg_list, vfp_dp_reg_list, vfp_sp_ldstm)
- (vfp_dp_ldstm, do_vfp_sp_ldstmia, do_vfp_sp_ldstmdb, do_vfp_ldstmia)
- (do_vfp_dp_ldstmdb, do_vfp_xp_ldstmia, do_vfp_xp_ldstmdb)
- (do_vfp_sp_compare_z, do_vfp_dp_compare_z, do_vfp_dp_sp_cvt)
- (do_vfp_sp_dp_cvt): New functions.
- (md_begin): Set soft-float flag for appropriate VFP work.
- (md_atof): Handle VFP-format doubles.
- (md_parse_option): Handle VFP command-line options.
- (md_show_usage): Display VFP command-line options.
-
-2002-01-15 Richard Earnshaw <rearnsha@arm.com>
-
- * tc-arm.c (md_parse_option): Tidy up setting of cpu_variant for
- various command line options.
-
-2002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
-
- * config/tc-xstormy16.c: (xstormy16_fix_adjustable): Do not fix
- vtinherit relocs.
- (xstormy16_md_apply_fix3): Do not return a value.
-
-2002-01-14 Richard Earnshaw <rearnsha@arm.com>
-
- * tc-arm.c (md_longopts): On targets that aren't bi-endian, support
- the -EL/-EB option that matches the target's endianness.
- (md_parse_option): Likewise.
-
-2002-01-14 Richard Earnshaw <rearnsha@arm.com>
-
- * tc-arm.c (md_longopts): Fix misplaced #endif -- the -oabi option
- is not dependent on ARM_BI_ENDIAN.
-
-2002-01-14 Richard Earnshaw <rearnsha@arm.com>
-
- * tc-arm.c (all error messages): Normalize capitalization of messages.
-
- * tc-arm.h (md_operand): Delete define.
- * tc-arm.c (in_my_get_expression): New static variable.
- (my_get_expression): Set and clear it.
- (md_operand): New function. If called from my_get_expression
- put the error in inst.error.
- (output_inst): Now takes argument of instruction being assembled.
- Print it out with any error message.
- (do_ldst, do_ldstv4, thumb_load_store): Fault attempt to use a store
- with '=' syntax.
- (end_of_line): Don't update inst.error if it is already set.
-
-2002-01-11 Richard Earnshaw <rearnsha@arm.com>
-
- * tc-arm.c ((do_ldst): Fix handling an immediate expression pseudo
- op that can be translated into a mvn instruction.
-
-2002-01-11 Steve Ellcey <sje@cup.hp.com>
-
- * gas/config/tc-ia64.h (MD_FLAGS_DEFAULT): New Macro for
- setting default md.flags.
- (SHT_INIT_ARRAY): New elf special section used by HP-UX.
- (SHT_FINI_ARRAY): New elf special section used by HP-UX.
- * gas/config/tc-ia64.c (setup_unwind_header): Add support
- for 32 bit unwind info blocks.
- (generate_unwind_image): Add support for different types
- of unwind images (32 bits and/or big-endian).
- (ia64_init): Use MD_FLAGS_DEFAULT to set md.flags.
- (ia64_target_format): Add support for hpux target formats.
- (ia64_gen_real_reloc_type): Add support for FUNC_IPLT_RELOC.
- (ia64_elf_section_type): Add support for SHT_INIT_ARRAY and
- SHT_FINI_ARRAY elf section types.
-
-2002-01-10 Richard Earnshaw <rearnsha@arm.com>
-
- * tc-arm.c (struct reg_entry): Move before prototypes.
- (int_register, cp_register, fp_register): Delete.
- (reg_table): Delete. Replaced with ...
- (rn_table, cp_table, cn_table, fn_table, mav_mvf_table)
- (mav_mvd_table, mav_mvfx_table, mav_mvdx_table, mav_mvax_table)
- (mav_dspsc_table): ... one table per register set.
- (arm_reg_hsh): Delete.
- (struct reg_map): New structure.
- (all_reg_maps): New array.
- (enum arm_reg_type): New enums.
- (build_reg_hsh): New function.
- (insert_reg_alias): Use hash table passed by caller. Adjust all
- callers.
- (create_register_alias): New function, split out from ...
- (md_assemble): ... here.
- (md_begin): Build new register hash tables.
- (arm_reg_parse): New argument for the hash table to search. Adjust all
- callers.
- (arm_reg_parse_any): New function.
- (co_proc_number): Look up the processor number in the processor hash
- table.
- (cirrus_regtype): Delete.
- (cirrus_register, cirrus_mvf_register, cirrus_mvd_register)
- (cirrus_mvfx_register, cirrus_mvdx_register, cirrus_mvax_register)
- (ARM_EXT_MAVERICKsc_register): Delete.
- (do_c_binops_1, do_c_binops_2, do_c_binops_3): Delete.
- (do_c_binops_1[a-o], do_c_binops_2[a-c], do_c_binops_3[a-d]): New
- functions.
- (do_c_triple_4, do_c_triple_5): Delete.
- (do_c_triple_4[ab], do_c_triple_5[a-h]): New functions.
- (do_c_quad_6): Delete.
- (do_c_quad_6[ab]): New functions.
- (do_c_binops, do_c_triple, do_c_quad, do_c_shift, do_c_ldst): Rework
- arguments to use new register parsing methods.
- (cirrus_reg_required_here): Likewise.
- (insns): Reclassify cirrus maverick worker functions.
- (cirrus_valid_reg): Delete.
-
-2002-01-07 Jason Thorpe <thorpej@wasabisystems.com>
-
- * configure.in (sh*le): Set cpu_type=sh and endian=little.
- (sh*-*-netbsdelf*): New target.
- * configure: Regenerate.
- * tc-sh.h: Update copyright years.
- (TARGET_FORMAT): Add version for TE_NetBSD.
-
-2002-01-07 Nick Clifton <nickc@cambridge.redhat.com>
-
- * read.c (emit_expr): Do not allow 'size' or 'nbytes' to go
- negative.
-
-2002-01-06 Alan Modra <amodra@bigpond.net.au>
-
- * config/tc-m68k.h (md_prepare_relax_scan): Rewrite.
- * config/tc-m68k.c (md_relax_table): Add md_prepare_relax_scan comment.
-
-2002-01-05 Daniel Jacobowitz <drow@mvista.com>
-
- * tc-mips.c (mips_cprestore_valid): New flag.
- (mips_frame_reg_valid): New flag.
- (macro) [M_JAL_2]: Check both flags.
- [M_JAL_A]: Likewise.
- (s_cprestore): Set mips_cprestore_valid.
- (tc_get_register): If setting mips_frame_reg, set
- mips_frame_reg_valid and clear mips_cprestore_valid.
- (s_mips_ent): Clear both flags.
- (s_mips_end): Clear both flags.
-
-2002-01-05 Alan Modra <amodra@bigpond.net.au>
-
- * write.c (write_object_file): Make use of bfd_section_list_remove.
- * config/obj-ecoff.c (ecoff_frob_file): Likewise.
- * config/tc-mmix.c (mmix_frob_file): Likewise.
-
-2002-01-04 Jason Thorpe <thorpej@wasabisystems.com>
-
- * configure.in (i386-*-netbsdelf*): Collapse target into...
- (i386-*-netbsd*): ...this. Add support for x86-64.
- * configure: Regenerated.
-
-2002-01-03 matthew green <mrg@redhat.com>
-
- * config/tc-ppc.c (md_parse_option): BookE is not Motorola specific.
-
-2002-01-02 Nick Clifton <nickc@cambridge.redhat.com>
-
- * config/tc-m68k.c (md_estimate_size_before_relax): Test for a
- NULL frag link.
-For older changes see ChangeLog-0001
+For older changes see ChangeLog-0203
Local Variables:
mode: change-log
diff --git a/contrib/binutils/gas/ChangeLog-0203 b/contrib/binutils/gas/ChangeLog-0203
new file mode 100644
index 0000000..e22a5d5
--- /dev/null
+++ b/contrib/binutils/gas/ChangeLog-0203
@@ -0,0 +1,7519 @@
+2003-12-29 Paul Brook <paul@codesourcery.com>
+
+ * gas/config/tc-arm.c (arm_cpus): Add 926ejs and 1026ejs.
+ * gas/doc/c-arm.texi: Document them.
+
+2003-23-12 Paul Brook <paul@codesourcery.com>
+
+ * config/tc-arm.c (arm_archs): Add armv6.
+ * doc/c-arm.texi: Document -march=armv6.
+
+2003-12-20 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-ppc.c (md_apply_fix3): Handle the case where a
+ .byte directive generates a pc-relative relocation.
+
+2003-12-19 Nick Clifton <nickc@redhat.com>
+ Andreas Schwab <schwab@suse.de>
+
+ * messages.c (as_perror): Save errno around library calls.
+ * input-file.c [BFD_ASSEMBLER]: Set the BFD error to
+ bfd_error_system_call before each call to as_perror.
+ (input_file_open): Simplify the error reporting code to just use
+ as_perror().
+ * output-file.c (output_file_create) [BFD_ASSEMBLER]: Set the BFD
+ error to bfd_error_system_call before calling as_perror.
+ (output_file_close) [BFD_ASSEMBLER]: Likewise.
+ (output_file_append) [BFD_ASSEMBLER]: Likewise.
+ * listing.c (listing_print) [BFD_ASSEMBLER]: Likewise.
+
+2003-12-19 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
+
+ Add m32r-linux and PIC support. Add new ABI that uses RELA.
+ * configure.in: Add m32r-linux targets.
+ * configure: Regenerate.
+ * config/tc-m32r.c (md_parse_option): Add -KPIC option.
+ (tc_gen_reloc): Added.
+ (debug_sym, md_estimate_size_before_relax, md_convert_frag,
+ md_pcrel_from_section, m32r_fix_adjustable): Changed for PIC.
+ * config/tc-m32r.h (tc_gen_reloc, EXTERN_FORCE_RELOC): Undefined.
+ (TC_HANDLES_FX_DONE, TC_FIX_ADJUSTABLE, TC_RELOC_RTSYM_LOC_FIXUP):
+ Defined.
+ * doc/c-m32r.texi: Document -KPIC option.
+ * NEWS: Mention the support m32r Linux and PIC.
+
+2003-12-18 Nick Clifton <nickc@redhat.com>
+
+ * input-file.c (input_file_open): Remove call to stat().
+ Add a check for getc() failing, and catch the case where the
+ failure is due to an attempt to read a directory.
+
+2003-12-18 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-mips.c (mips_need_elf_addend_fixup): Delete.
+ (md_apply_fix3): Remove bfd_install_relocation workarounds.
+ (tc_gen_reloc): Likewise. Factor handling of pc-relative relocations
+ and treat fx_addnumber as relative to the relocation address.
+
+2003-12-18 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-mips.c (s_change_section): When parsing the MIPS-specific
+ .section syntax, map SHT_MIPS_DWARF to SHT_PROGBITS.
+
+2003-12-17 Mark Mitchell <mark@codesourcery.com>
+
+ * config/tc-arm.c (arm_archs): Change "armv6" to "armv6j".
+ * doc/c-arm.texi (ARM Options): Likewise.
+
+2003-12-17 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-m32r.c (error_explicit_parallel_conflicts): Rename
+ to 'ignore_parallel_conflicts'.
+ (md_longopts): Change option names as well.
+ (md_parse_option): Separate the warn_explicit and ignore
+ parallel conflicts options.
+ (md_show_usage): Update descriptions of these options.
+ (first_writes_to_seconds_operands): Do not run this check if
+ ignoring parallel conflicts.
+ (assemble_two_insns): Remove code that checked
+ error_explicit_parallel_conflicts.
+ * doc/c-m32r.texi: Update descriptions of the options.
+
+2003-12-16 Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
+
+ * tc-arm.c (do_adr): Do not adjust pc by -8 if TE_WINCE is
+ defined.
+ (do_adrl): Likewise.
+
+2003-12-15 Christian Groessler <chris@groessler.org>
+
+ * config/tc-z8k.c (struct z8k_exp): Remove, not used anywhere.
+ (ctrl_table): Add "flags" keyword and some comments.
+ (flag_table): Convert to uppercase.
+ (get_flags_operand): Be case insensitive.
+ (get_interrupt_operand): Be case insensitive. Support notation
+ where the inperrupt arguments are separated by commas.
+ (get_operands): Check whether get_flags_operand consumed all
+ arguments. Return failure if get_ctrl_operand didn't recognize a
+ valid control register.
+ (get_specific): Add case CLASS_CTRL: Test for valid control
+ register for ldctlb opcode.
+ (build_bytes): Check for valid control registers.
+
+2003-12-15 Nick Clifton <nickc@redhat.com>
+
+ * config/obj-aout.c (obj_crawl_symbol_chain): Skip defined
+ symbols which resolve to symbolic values.
+
+2003-12-13 Alan Modra <amodra@bigpond.net.au>
+
+ * config/obj-elf.c: Convert to C90, remove unneeded prototypes and
+ casts. Formatting.
+ * config/obj-elf.h: Remove PARAMS.
+
+ * read.c (s_lcomm_internal): Make global.
+ * read.h (s_lcomm_internal): Declare.
+ * config/obj-elf.c (elf_pseudo_table): Handle lcomm.
+ (obj_elf_lcomm): New function.
+
+2003-12-13 Alan Modra <amodra@bigpond.net.au>
+
+ * read.c: Remove unneeded prototypes.
+ (s_comm): Split out code to..
+ (s_comm_internal): ..here. Tidy error returns. Rearrange so that
+ "name" from input line may be used in more places. Merge code
+ testing for valid size from elf_common. Merge code from
+ s_lcomm_internal. Call comm_parse_extra.
+ (bss_alloc): New function, split out of s_lcomm_internal and
+ elf_common.
+ (parse_align): Likewise.
+ (s_lcomm_internal): Rewrite.
+ (s_lcomm, s_lcomm_bytes): Use s_comm_internal.
+ * read.h (bss_alloc, parse_align, s_comm_internal): Declare.
+ * config/obj-elf.c (elf_common): Split out code to..
+ (elf_common_parse): ..here. Remove code common to s_comm_internal,
+ parse_align and bss_alloc. Rearrange and Tidy.
+ * config/tc-alpha.h (TC_IMPLICIT_LCOMM_ALIGNMENT): Define.
+
+2003-12-10 Zack Weinberg <zack@codesourcery.com>
+
+ * tc-ppc.c (md_assemble): Rewrite comment about optional operands
+ to indicate that 'all or none' is also handled. Pluralize a
+ word in another comment.
+
+2003-12-10 Paul Brook <paul@codesourcery.com>
+
+ * config/tc-arm.c (FPU_MAVERICK): Define.
+ (FPU_ARCH_MAVERICK): Define.
+ (arm_float_abi): Define.
+ (mfloat_abi_opt): New variable.
+ (md_begin): Use them.
+ (arm_opts): Add msoft-float and mhard-float.
+ (arm_cpus): Use FPU_ARCH_MAVERICK.
+ (arm_fpus): Add maverick.
+ (arm_float_abis): Add.
+ (arm_parse_float_abi): New function.
+ (arm_long_options): Add mfloat-abi.
+ * doc/as.texinfo: Document -mfloat-abi=.
+ * doc/c-arm.text: Ditto. Menution -fpu=maverick.
+
+2003-12-09 Paul Brook <paul@codesourcery.com>
+
+ * config/tc-arm.c (do_umaal): Fix typo.
+
+2003-12-06 Kazu Hirata <kazu@cs.umass.edu>
+
+ * dwarf2dbg.c: Convert to ISO-C.
+ * write.c: Likewise.
+ * write.h: Likewise.
+
+2003-12-06 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-mips.c (macro): Switch misordered call to frag_grow()
+ and setting of tc_fr_offset.
+
+2003-12-05 Ricardo Anguiano <anguiano@codesourcery.com>
+ Mark Mitchell <mark@codesourcery.com>
+ Richard Earnshaw <rearnsha@arm.com>
+
+ Add V6 support.
+ * config/tc-arm.c (ARM_EXT_V6): New macro.
+ (ARM_ARCH_V6): Likewise.
+ (SHIFT_IMMEDIATE): Likewise.
+ (SHIFT_LSL_OR_ASR_IMMEDIATE): Likewise.
+ (SHIFT_ASR_IMMEDIATE): Likewise.
+ (SHIFT_LSL_IMMMEDIATE): Likewise.
+ (do_cps): New function.
+ (do_cpsi): Likewise.
+ (do_ldrex): Likewise.
+ (do_pkhbt): Likewise.
+ (do_pkhtb): Likewise.
+ (do_qadd16): Likewise.
+ (do_rev): Likewise.
+ (do_rfe): Likewise.
+ (do_sxtah): Likewise.
+ (do_sxth): Likewise.
+ (do_setend): Likewise.
+ (do_smlad): Likewise.
+ (do_smlald): Likewise.
+ (do_smmul): Likewise.
+ (do_ssat): Likewise.
+ (do_usat): Likewise.
+ (do_srs): Likewise.
+ (do_ssat16): Likewise.
+ (do_usat16): Likewise.
+ (do_strex): Likewise.
+ (do_umaal): Likewise.
+ (do_cps_mode): Likewise.
+ (do_cps_flags): Likewise.
+ (do_endian_specifier): Likewise.
+ (do_pkh_core): Likewise.
+ (do_sat): Likewise.
+ (do_sat16): Likewise.
+ (insns): Add V6 instructions.
+ (do_t_cps): New function.
+ (do_t_cpy): Likewise.
+ (do_t_setend): Likewise.
+ (THUMB_CPY): New macro.
+ (tinsns): Add V6 instructions.
+ (decode_shift): Handle V6 restricted-shift options.
+ (thumb_mov_compare): Support CPY.
+ (arm_cores): Add arm1136js and arm1136jfs.
+ (arm_archs): Add armv6.
+ (arm_fpus): Add arm1136jfs.
+ * doc/c-arm.texi (ARM Options): Mention arm1136js, arm1136jfs, and
+ armv6 options.
+
+2003-12-06 Christian Groessler <chris@groessler.org>
+
+ * config/tc-z8k.c (parse_reg): Be case insensitive when checking
+ register names.
+ (get_ctrl_operand): Be case insensitive when checking ctrl names.
+
+2003-12-05 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-sh.c (md_show_usage): Fix compilation errors
+ introduced by the previous delta.
+
+2003-12-03 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-sh.c: Add support for sh4a and no-fpu variants.
+ * testsuite/gas/sh/basic.exp: Call tests for sh4a.
+ * testsuite/gas/sh/{err-sh4a-fp.s, err-sh4a.s,
+ err-sh4al-dsp.s, sh4a-dsp.d, sh4a-dsp.s, sh4a-fp.d,
+ sh4a-fp.s, sh4a.d, sh4a.s, sh4al-dsp.d, sh4al-dsp.s:
+ New files, tests for sh4a and related variants.
+
+2003-12-05 Michael Snyder <msnyder@redhat.com>
+
+ * config/tc-sh.c (md_show_usage): Mention new -isa options.
+ * doc/c-sh.texi: Document new -isa options.
+ * doc/c-sh64.texi: Ditto.
+ * NEWS: Mention new support for sh4a.
+
+2003-12-03 H.J. Lu <hongjiu.lu@intel.com>
+
+ * config/tc-alpha.c (s_alpha_end): Don't crash if there is no
+ matching .ent.
+
+2003-12-04 Alan Modra <amodra@bigpond.net.au>
+
+ * tc.h (md_pcrel_from): Don't declare if defined as a macro.
+
+2003-12-03 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
+
+ * config/tc-m32r.h : Add support for new machine m32r2.
+ * config/tc-m32r.c : Likewise.
+ Add new command line switches and directives to allow endian-ness
+ to be selected and some warnings to be turned into errors.
+ (line_separator_chars) : Use '!'.
+ * doc/c-m32r.texi: Document new switches and directives.
+ * NEWS: Mention new support.
+
+2003-12-03 Dave Airlie <airlied@linux.ie>
+
+ * configure.in: Likewise.
+ * configure: Regenerate.
+ * config/tc-vax.c (md_shortopts): Add 'Q'.
+ (md_parse_option): Ignore 'Q' for now.
+
+2003-12-02 Kazu Hirata <kazu@cs.umass.edu>
+
+ * messages.c: Convert to ISO-C.
+ * obj.h: Likewise.
+ * output-file.c: Likewise.
+ * output-file.h: Likewise.
+ * sb.c: Likewise.
+ * sb.h: Likewise.
+ * stabs.c: Likewise.
+ * subsegs.c: Likewise.
+ * subsegs.h: Likewise.
+ * tc.h: Likewise.
+
+2003-12-02 Kazu Hirata <kazu@cs.umass.edu>
+
+ * config/obj-elf.c: Remove ARGSUSED.
+
+2003-12-02 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2003-11-30 Kazu Hirata <kazu@cs.umass.edu>
+
+ * symbols.c: Convert to ISO-C.
+ * symbols.h: Likewise.
+
+2003-11-28 Christian Groessler <chris@groessler.org>
+
+ * config/tc-z8k.c: Convert to ISO-C.
+ * config/tc-z8k.h: Likewise.
+
+2003-11-27 Kazu Hirata <kazu@cs.umass.edu>
+
+ * read.c: Convert to ISO-C.
+ * read.h: Likewise.
+
+2003-11-27 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-sh.c (sh_elf_cons): If md_cons_align is defined
+ call it to make sure that the constants that are going to be
+ emitted are correctly aligned.
+
+2003-11-27 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-frv.c (md_pcrel_from_section): Don't adjust when
+ referencing symbol in a different section.
+
+2003-11-26 Christian Groessler <chris@groessler.org>
+
+ * config/tc-z8k.c (s_segm): Fix indentation.
+ (md_apply_fix3): Likewise.
+ (cc_names): Add alias names for the names generated by the
+ disassembler.
+ (get_cc_operand): Be case insensitive.
+ (get_operands): Improve error handling for cc operands.
+ (check_operand): Not used, remove.
+ (md_assemble): Remove unused variable prev_opcode. Skip
+ whitespace until end-of-line only. Restore *op_end after call to
+ hash_find.
+
+2003-11-26 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-h8300.c (get_operand): Allow er4-er7 for ldm/stm
+ instructions on the H8SX.
+
+2003-11-25 Kazu Hirata <kazu@cs.umass.edu>
+
+ * config/tc-h8300.c (h8_exp): Remove.
+
+2003-11-25 Asgari Jinia <asgarij@kpitcummins.com>
+
+ * config/tc-h8300.c (md_assemble): Check operands validity for
+ ldm/stm.
+ (get_operand): Check register pair's validity as per technical
+ note TN-H8*-193A/E from Renesas for H8s and for H8Sx manual.
+
+2003-11-24 Kazu Hirata <kazu@cs.umass.edu>
+
+ * listing.c: Convert to ISO-C.
+ * listing.h: Likewise.
+ * macro.c: Likewise.
+ * macro.h: Likewise.
+
+2003-11-24 Jakub Jelinek <jakub@redhat.com>
+
+ * app.c (do_scrub_chars): Add PUT (ch) and ch = GET ()
+ when transitioning from states 14 or 15 to 0 or 1.
+
+2003-11-23 Kazu Hirata <kazu@cs.umass.edu>
+
+ * hash.c: Convert to ISO-C.
+ * hash.h: Likewise.
+ * input-file.c: Likewise.
+ * input-file.h: Likewise.
+ * input-scrub.c: Likewise.
+ * itbl-ops.c: Likewise.
+ * itbl-ops.h: Likewise.
+
+2003-11-23 Kazu Hirata <kazu@cs.umass.edu>
+
+ * config/tc-h8300.c (Hmode): Make it global.
+ (Smode): Likewise.
+ (Nmode): Likewise.
+ (SXmode): Likewise.
+
+2003-11-22 Kazu Hirata <kazu@cs.umass.edu>
+
+ * ehopt.c: Convert to ISO-C.
+ * emul.h: Likewise.
+ * expr.c: Likewise.
+ * expr.h: Likewise.
+ * flonum-copy.c: Likewise.
+ * flonum-mult.c: Likewise.
+ * flonum.h: Likewise.
+ * frags.c: Likewise.
+ * frags.h: Likewise.
+
+2003-11-22 Alan Modra <amodra@bigpond.net.au>
+
+ * doc/c-ppc.texi (PowerPC-Pseudo): Add section.
+
+ * app.c (do_scrub_chars): Revert 2003-04-23 and 2003-04-22.
+
+2003-11-21 Kazu Hirata <kazu@cs.umass.edu>
+
+ * ecoff.c: Convert to ISO-C.
+ * ecoff.h: Likewise.
+
+2003-11-22 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ppc.c (parse_cpu): New function, broken out from..
+ (md_parse_option): ..here.
+ (ppc_setup_opcodes): New function, broken out from..
+ (md_begin): ..here.
+ (ppc_machine): Implement .machine pseudo op.
+
+2003-11-20 Kazu Hirata <kazu@cs.umass.edu>
+
+ * depend.c: Convert to ISO-C.
+ * dwarf2dbg.c: Likewise.
+ * dwarf2dbg.h: Likewise.
+
+2003-11-20 Kazu Hirata <kazu@cs.umass.edu>
+
+ * app.c: Convert to ISO-C.
+ * as.h: Likewise.
+ * atof-generic.c: Likewise.
+ * bignum-copy.c: Likewise.
+ * bignum.h: Likewise.
+ * cgen.c: Likewise.
+ * cgen.h: Likewise.
+ * cond.c: Likewise.
+
+2003-11-20 DJ Delorie <dj@redhat.com>
+
+ * config/tc-sh64.c (shmedia_frob_section): Only frob elf32
+ sections.
+
+2003-11-19 Kazu Hirata <kazu@cs.umass.edu>
+
+ * config/tc-h8300.c: Make some functions and global
+ variables static appropriately.
+
+2003-11-19 Kazu Hirata <kazu@cs.umass.edu>
+
+ * config/obj-ieee.c: Remove duplicate prototypes.
+ * config/tc-h8300.c: Likewise.
+
+2003-11-19 Kazu Hirata <kazu@cs.umass.edu>
+
+ * config/tc-h8300.c: Convert to ISO-C.
+ * config/tc-h8300.h: Likewise.
+
+2003-11-19 Kazu Hirata <kazu@cs.umass.edu>
+
+ * config/tc-mcore.h: Remove prototypes already in tc.h.
+ * config/tc-tic4x.c: Likewise.
+
+2003-11-19 Kazu Hirata <kazu@cs.umass.edu>
+
+ * config/tc-arc.c: Remove a local prototype of atof_ieee.
+ * config/tc-ip2k.c: Likewise.
+ * config/tc-iq2000.c: Likewise.
+ * config/tc-tic30.c: Remove a comment.
+
+2003-11-19 Bob Wilson <bob.wilson@acm.org>
+
+ * config/tc-xtensa.c (xg_emit_insn): Include "dwarf2dbg.h" and add
+ call to dwarf2_emit_insn.
+
+2003-11-18 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * config/tc-mips.c (macro): Handle new macros: "lca" and "dlca"
+ for loading addresses using CALL relocations.
+ Don't emit CALL relocations when a base register is used.
+
+2003-11-15 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * config/tc-mips.c: Formatting fixes.
+
+2003-11-14 Ben Elliston <bje@wasabisystems.com>
+
+ * config/tc-arm.c (arm_elf_change_section): Not static.
+
+2003-11-13 Nick Clifton <nickc@redhat.com>
+
+ * tc-arm.c (mapping_state): New function. Emit a mapping
+ symbol if necessary.
+ (arm_elf_change_section): New function. Intercept section
+ changes and generate mapping symbols.
+ (s_bss): Likewise.
+ (s_arm_elf_cons): Likewise.
+ (opcode_select): Choose the correct mapping state.
+ (md_assemble): Likewise.
+ * tc-arm.h (md_elf_section_change_hook): Define.
+ * doc/c-arm.texi (ARM Mapping Symbols): New node.
+ * NEWS: Mention new feature.
+
+2003-11-12 Daniel Jacobowitz <drow@mvista.com>
+
+ * Makefile.am (install, install-info, RECURSIVE_TARGETS): Define.
+ * doc/Makefile.am (install-info): Define.
+
+ * aclocal.m4: Regenerate.
+ * Makefile.in: Regenerate.
+ * doc/Makefile.in: Regenerate.
+
+2003-11-11 Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
+
+ * configure.in: Add support for arm-wince-pe target.
+ * configure: Regenerate.
+
+2003-11-11 Jan Hubicka <jh@suse.cz>
+
+ * config/tc-i386.c (tc_i386_fix_adjustable):
+
+2003-11-10 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ia64.c (ia64_handle_align): Remove bogus be_nop.
+
+2003-11-10 Alan Modra <amodra@bigpond.net.au>
+
+ * README: Update bug report address. Move bug reporting info to
+ binutils/README.
+
+2003-11-07 Christian Groessler <chris@groessler.org>
+
+ * doc/c-z8k.texi: Document command-line options. Fix byte
+ register names. Document '.z8001' and '.z8002' directives.
+ Extend addressing modes documentation.
+
+2003-11-07 Jonathan R. Grant <jg-binutils@jguk.org>
+
+ * input-file.c (input_file_open): Use "No such file" error
+ message.
+
+2003-11-06 Pete Gonzalez <pgonzalez@bluel.com>
+
+ * config/tc-arm.texi (struct reg_entry): Add new field 'builtin'.
+ (rn_table, iwmmxt_table, cp_table, cn_table, fn_table, sn_table,
+ dn_table, mav_mvf_table, mac_mvd_table, mav_mvfx_table,
+ mav_mvax_table, mav_dspc_table): Initialise new field.
+ (insert_reg_alias): Initialise new field.
+ (md_pseudo_table): Add "unreq" entry.
+ (s_unreq): New function: Undo the effects of a previous .req.
+ * doc/c-arm.texi: Document new pseudo op.
+ * NEWS: Mention new feature.
+
+2003-11-06 Bruno Rohee <bruno@rohee.com>
+
+ * config/obj-vms.c: Fix "the the" typo.
+ * doc/c-arm.texi: Likewise.
+
+2003-11-06 Nick Clifton <nickc@redhat.com>
+
+ * config/obj-vms.c: Convert to ISO-C.
+
+2003-11-05 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ppc.h (TC_FORCE_RELOCATION): Only define for ELF and XCOFF.
+
+2003-10-31 Christian Groessler <chris@groessler.org>
+
+ * config/tc-i860.c (md_pcrel_from): Fix typo in comment.
+
+2003-10-29 Phil Edwards <phil@codesourcery.com>
+
+ * configure.in (arm-*-vxworks, i386-*-vxworks, mips-*-vxworks,
+ ppc-*-vxworks, ppc-*-windiss): Remove separate outdated stanzas.
+ (*-*-vxworks, *-*-windiss): Use common stanzas, all ELF.
+ * configure: Regenerated.
+
+2003-10-27 Kazu Hirata <kazu@cs.umass.edu>
+
+ * ChangeLog: Fix typos.
+ * ChangeLog-9295: Likewise.
+ * as.c: Fix comment typos.
+ * as.h: Likewise.
+ * atof-generic.c: Likewise.
+ * bit_fix.h: Likewise.
+ * frags.h: Likewise.
+ * hash.c: Likewise.
+ * input-file.c: Likewise.
+ * input-scrub.c: Likewise.
+ * itbl-ops.c: Likewise.
+ * itbl-parse.y: Likewise.
+ * listing.c: Likewise.
+ * macro.h: Likewise.
+ * read.c: Likewise.
+ * sb.c: Likewise.
+ * sb.h: Likewise.
+ * symbols.c: Likewise.
+ * symbols.h: Likewise.
+
+2003-10-27 Stephane Carrez <stcarrez@nerim.fr>
+
+ * config/tc-m68hc11.c: Convert to ISO C90.
+ * config/tc-m68hc11.h: Likewise.
+
+2003-10-26 Kazu Hirata <kazu@cs.umass.edu>
+
+ * doc/c-sh64.texi: Fix a typo.
+
+2003-10-26 Kazu Hirata <kazu@cs.umass.edu>
+
+ * doc/c-alpha.texi: Fix typos.
+ * doc/c-ia64.texi: Likewise.
+ * doc/c-mmix.texi: Likewise.
+ * doc/c-sh64.texi: Likewise.
+ * doc/c-xtensa.texi: Likewise.
+ * doc/internals.texi: Likewise.
+
+2003-10-24 H.J. Lu <hongjiu.lu@intel.com>
+
+ * config/obj-elf.c (obj_elf_change_section): Allow SHF_ALLOC
+ for .interp, .strtab and .symtab. Use specified section
+ attributes.
+
+2003-10-22 Andreas Schwab <schwab@suse.de>
+ H.J. Lu <hongjiu.lu@intel.com>
+ Jim Wilson <wilson@specifixinc.com>
+
+ * config/tc-ia64.c (update_qp_mutex): New.
+ (note_register_values): Properly handle one of PRs in compare
+ is PR0. Don't add a mutex relation for .and.orcm/.or.andcm.
+ Clear mutex relation for .none/.unc. Don't clear mutex relation
+ on predicated compare.
+
+2003-10-21 Wouter van Heyst <wouter@vidicode.nl>
+
+ * config/tc-arm.c (all_reg_maps): Correct text describing Maverick
+ register requirements.
+ (md_begin): Remove F_SOFT_FLOAT if enabling MAVERICK FP.
+
+2003-10-21 Peter Barada <pbarada@mail.wm.sps.mot.com>
+ Bernardo Innocenti <bernie@develer.com>
+
+ * config/tc-m68k.c: Add MCF528x (MCFv4) support.
+ * config/m68k-parse.h: Likewise.
+ * NEWS: Mention the new support.
+ * doc/c-m68k.texi: Document new processor selection switch.
+
+2003-10-19 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (normalize_constant_expr): New function to fix sign
+ extensions broken by gas' expression evaluation of constants.
+ (check_absolute_expr): Use it.
+ (mips_ip): Likewise.
+
+2003-10-18 Hans-Peter Nilsson <hp@bitrange.com>
+
+ Generate BFD_RELOC_MMIX_PUSHJ_STUBBABLE for PUSHJ when possible.
+ * doc/c-mmix.texi (MMIX-Opts): Document --no-pushj-stubs and
+ --no-stubs.
+ * config/tc-mmix.c: Include limits.h. Expand on mmix_relax_table
+ comment.
+ (expand_op, mmix_next_semicolon_is_eoln): Fix head comment.
+ (pushj_stubs): New variable.
+ (OPTION_NOPUSHJSTUBS, STATE_PUSHJSTUB, PUSHJSTUB_MIN)
+ (PUSHJSTUB_MAX): New macros.
+ (md_longopts): New options "--no-pushj-stubs" and synonym
+ "--no-stubs".
+ (mmix_relax_table): Handle new entry for STATE_PUSHJSTUB.
+ (md_parse_option): Handle OPTION_NOPUSHJSTUBS.
+ (md_estimate_size_before_relax): Modify STATE_PUSHJ state for
+ PUSHJ stub relaxation.
+ (md_convert_frag): Handle STATE_PUSHJSTUB.
+ (md_apply_fix3): Handle BFD_RELOC_MMIX_PUSHJ_STUBBABLE.
+ (tc_gen_reloc): Ditto.
+ (mmix_md_relax_frag): Handle PUSHJ stub relaxation.
+ * config/tc-mmix.h (TC_SEGMENT_INFO_TYPE): Define.
+ (struct mmix_segment_info_type): New.
+
+2003-10-17 Paul Dale <pauli@snapgear.com>
+ Bernardo Innocenti <bernie@develer.com>
+
+ * config/tc-m68k.c (make_pcrel_absolute): Enforce
+ PC-relative jumps with --pcrel.
+ (md_convert_frag_1): Likewise.
+ (md_create_long_jump): Likewise.
+
+2003-10-17 Shrinivas Atre <shrinivasa@KPITCummins.com>
+
+ * config/tc-h8300.c (PSIZE): Correct for Normal mode.
+ (get_operand): Accept both 16 bit 32 bit registers as pointer
+ registers, when operating in Normal mode.
+ (fix_operand_size): Make default address size 16 for Normal mode.
+
+2003-10-17 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * config/tc-arm.c (do_iwmmxt_byte_addr): Reject control
+ registers.
+ (do_iwmmxt_word_addr): With a control register, reject conditional
+ execution and reject a non-word size.
+
+2003-10-16 Peter Bergner <bergner@vnet.ibm.com>
+
+ * configure.in: Set em=linux for ppc-*-linux-gnu* target.
+ * configure: Regenerate.
+
+2003-10-15 Alan Modra <amodra@bigpond.net.au>
+
+ * doc/as.texinfo (Align): Correct list of byte targets.
+
+2003-10-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (macro_build_ldst_constoffset,load_register,macro):
+ Fix indentation. Better error message.
+
+2003-10-14 Bob Wilson <bob.wilson@acm.org>
+
+ * config/tc-xtensa.c (xtensa_create_property_segments): Remove bfd
+ argument in call to xtensa_get_property_section_name. Formatting.
+
+2003-10-11 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * config/tc-sh.h (sh_coff_reloc_mangle): Delete an extra
+ parenthesis.
+
+2003-10-11 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * config/tc-sh.c: Convert to ISO C90. Remove unnecessary
+ prototypes and casts.
+ * config/tc-sh.h: Likewise.
+ * config/tc-sh64.c: Likewise.
+ * config/tc-sh64.h: Likewise.
+
+2003-10-08 Dave Brolley <brolley@redhat.com>
+
+ * config/tc-frv.c (fr550_check_insn_acc_range): New function.
+ (fr550_check_acc_range): New function.
+ (md_assemble): Call fr550_check_acc_range.
+
+2003-10-08 Dave Brolley <brolley@redhat.com>
+
+ * config/tc-frv.c: Handle DEFAULT_CPU_FR550.
+ (md_parse_option): Handle OPTION_CPU==fr550.
+ (md_show_usage): Document fr550.
+
+2003-10-08 Philippe De Muyter <phdm@macqel.be>
+
+ * as.c (use_gnu_debug_info_extensions) : New variable.
+ (parse_args) : Accept new --gstabs+ option, and set
+ `use_gnu_debug_info_extensions'.
+ (show_usage) : Document --gstabs+ option.
+ * as.h (use_gnu_debug_info_extensions) : New extern declaration.
+ * stabs.c (stabs_generate_asm_file) : If
+ `use_gnu_debug_info_extensions' is set, add the compilation
+ directory to the stabs debug info.
+ * doc/as.texinfo : Document --gstabs+ option.
+ * NEWS: Mention new feature.
+
+2003-10-06 Matt Thomas <matt@3am-software.com>
+
+ Switch NetBSD/hppa to use Linux PA-RISC ELF ABI and
+ assembler syntax.
+
+ * tc-hppa.c: Add "%farg[0-3]", "%fret", "%t[1-4]", "%tf[1-4]"
+ register names. Change all "defined (TE_LINUX)" to
+ "(defined (TE_LINUX) || defined (TE_NETBSD))".
+
+ * tc-hppa.h: Make NetBSD use "elfXX-hppa-linux" bfd target.
+ Remove NetBSD's use of LABELS_WITHOUT_COLONS.
+
+2003-10-06 Robert Millan <robertmh@gnu.org>
+
+ * configure.in: Match GNU/KNetBSD with new knetbsd*-gnu triplet.
+ * configure: Regenerate.
+
+2003-10-05 Nick Clifton <nickc@redhat.com>
+
+ * as.c (parse_args): Revert patch to change handling of -f
+ option. Its behaviour is mandated by the POSIX 2 spec.
+
+2003-10-04 Christian Groessler <chris@groessler.org>
+
+ * tc-z8k.c (newfix): Tell fix_new_exp about pc relativeness.
+ (md_apply_fix3): Fix R_JR, R_DISP7, and R_CALLR cases.
+ (md_pcrel_from): This function now gets called. Supply return
+ value.
+
+2003-10-04 Nick Clifton <nickc@redhat.com>
+
+ * as.c: Convert to ISO C90.
+
+2003-10-04 Nick Clifton <nickc@redhat.com>
+
+ * as.c (std_shortopts): Remove 'f'.
+ (std_longopts): Add 'f'. Doing this prevents -f<foo> being
+ acecpted as an alias for -f.
+
+2003-10-04 Danny Smith <danny_r_smith_2001@yahoo.co.nz>
+
+ * config/obj-coff.c (obj_coff_section [BEF_ASSEMBLER]):
+ Make 'r' mean readonly data.
+
+2003-10-01 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (macro_build_ldst_constoffset,load_register,macro):
+ Unbreak overflow checks.
+
+2003-10-01 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (s_cpreturn): Correct errors in comment.
+
+2003-10-01 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (macro_build_ldst_constoffset): Fix sign extension
+ tests.
+ (load_register): Likewise.
+ (macro): Likewise.
+
+2003-09-30 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (mips_ip): Capitalize first word of
+ existing condition code warning, and add condition code
+ warnings for .ps instructions, and for bc1any[24][tf].
+
+2003-09-30 Chris Demetriou <cgd@broadcom.com>
+
+ * NEWS: Mention support for MIPS64 Release 2.
+
+2003-09-30 Chris Demetriou <cgd@broadcom.com>
+
+ * NEWS: Add an indication of the cutoff for 2.14.
+
+2003-09-30 Chris Demetriou <cgd@broadcom.com>
+
+ * configure.in (mipsisa64r2, mipsisa64r2el, mipsisa64r2*): New CPUs.
+ * configure: Regenerate.
+ * config/tc-mips.c (imm2_expr): New variable.
+ (md_assemble, mips16_ip): Initialize imm2_expr.
+ (ISA_HAS_64BIT_REGS, ISA_HAS_DROR, ISA_HAS_ROR): Add ISA_MIPS64R2.
+ (macro_build): Handle +A, +B, +C, +E, +F, +G, and +H format operands.
+ (macro): Handle M_DEXT and M_DINS.
+ (validate_mips_insn): Handle +E, +F, +G, +H, and +I format operands.
+ (mips_ip): Likewise.
+ (OPTION_MIPS64R2): New define.
+ (md_longopts): New entry for -mips64r2 (OPTION_MIPS64R2).
+ OPTION_ASE_BASE): Increase to compensate for OPTION_MIPS64R2.
+ (md_parse_option): Handle OPTION_MIPS64R2.
+ (s_mipsset): Handle setting "mips64r2" ISA.
+ (mips_cpu_info_table): Add mips64r2.
+ (md_show_usage): Document -mips64r2 option.
+ * doc/as.texinfo: Docuemnt -mips64r2 option.
+ * doc/c-mips.texi: Likewise.
+
+2003-09-27 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
+
+ * config/tc-hppa.c (pa_ip): Check for invalid 64-bit conditions.
+
+2003-09-26 Matt Thomas <matt@3am-software.com>
+
+ * config/tc-vax.c (md_shortopts): Fix a typo. Remove 'K'.
+ (OPTION_PIC): Define.
+ (md_longopts): Add "pic" option.
+ (md_parse_option): Change 'K' to OPTION_PIC.
+
+2003-09-23 Alan Modra <alan@modra.org>
+
+ * config/obj-elf.c (obj_elf_change_section): Adjust for
+ _bfd_elf_get_sec_type_attr changes. Allow SHF_MERGE and SHF_STRINGS
+ to be set when defaults are not. Don't set attr from defaults if
+ old_sec.
+
+2003-09-18 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (macro_build_ldst_constoffset): Don't silently
+ truncate values which won't fit im 32 bits.
+ (load_register): Likewise.
+ (macro): Likewise.
+
+2003-09-17 Dmitry Diky <diwil@mail.ru>
+
+ * config/tc-msp430.c (MAX_OP_LEN): Set to 256.
+ (msp430_operands): Remove redundant l2[16] within switch-case.
+
+2003-09-16 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
+
+ * configure.in: Handle arm-*-rtems* and thumb-*rtems*.
+ * configure: Regenerate.
+
+2003-09-14 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (HAVE_64BIT_ADDRESS_CONSTANTS): Remove.
+ (macro_build_ldst_constoffset): Sign-extend 32-bit constants. Change
+ the function prototype.
+ (load_register): Likewise. Simplify the checks for sign-extended
+ constants.
+ (macro): Likewise. Fix code generation for 64-bit address constants
+ outside the 32-bit compatibility space. Adjust
+ macro_build_ldst_constoffset calls.
+ (s_cprestore): Adjust macro_build_ldst_constoffset call.
+
+2003-09-11 Bob Wilson <bob.wilson@acm.org>
+
+ * config/tc-xtensa.c (insn_labels, free_insn_labels, saved_insn_labels,
+ literal_syms): New global variables.
+ (xtensa_define_label, add_target_symbol, xtensa_find_label,
+ map_over_defined_symbols, is_loop_target_label,
+ xtensa_mark_target_fragments, xtensa_move_frag_symbol,
+ xtensa_move_frag_symbols, defined_symbols, branch_targets): Delete.
+ (xtensa_begin_directive): Call md_flush_pending_output. Move symbols
+ from insn_labels to saved_insn_labels when entering a literal region.
+ (xtensa_end_directive): Call md_flush_pending_output. Restore
+ insn_labels list when leaving a literal region.
+ (xtensa_literal_position): Call xtensa_clear_insn_labels.
+ (xtensa_literal_pseudo): Add check to disallow .literal inside a
+ literal region. Move insn_labels to saved_insn_labels and then restore
+ insn_labels on exit.
+ (xg_add_branch_and_loop_targets): Replace add_target_symbol calls with
+ code to set is_loop_target or is_branch_target flag on the symbol
+ (xtensa_create_literal_symbol): Call xtensa_add_literal_sym.
+ (xtensa_add_literal_sym, xtensa_add_insn_label,
+ xtensa_clear_insn_labels): New functions.
+ (xtensa_move_labels): Remove old_frag and old_offset arguments. Add
+ loops_ok argument. Rewrite to use insn_labels list instead of
+ calling xtensa_find_label and to check the is_loop_target flag on
+ symbols when loops_ok is false.
+ (xtensa_frob_label): Remove call to xtensa_define_label. Add call
+ to either xtensa_add_literal_sym or xtensa_add_insn_label. Adjust
+ call to xtensa_move_labels. Propagate is_branch_target and
+ is_loop_target flags from symbols to frags.
+ (xtensa_flush_pending_output): Call xtensa_clear_insn_labels.
+ (md_assemble): Use xtensa_move_labels with loops_ok = FALSE when
+ aligning a loop instruction. Adjust call to xtensa_move_labels for
+ aligning entry instructions. Add call to xtensa_clear_insn_labels.
+ (xtensa_end): Remove call to xtensa_mark_target_fragments.
+ (xtensa_move_literals): Replace xtensa_move_frag_symbols call with
+ code to use new literal_syms list.
+ * config/tc-xtensa.h (xtensa_symfield_type): Add is_loop_target and
+ is_branch_target flags.
+
+2003-09-09 Bob Wilson <bob.wilson@acm.org>
+
+ * config/tc-xtensa.c (xtensa_mark_literal_pool_location): Remove
+ "move_labels" argument and corresponding call to xtensa_move_labels.
+ (md_assemble): Add a separate call to xtensa_move_labels and remove
+ argument for call to xtensa_mark_literal_pool_location.
+ (xtensa_literal_position, xtensa_switch_to_literal_fragment): Fix
+ calls to xtensa_mark_literal_pool_location.
+ (xtensa_create_local_symbol): Delete and inline the code into...
+ (xtensa_create_literal_symbol): ...here.
+ (xtensa_frob_label): Combine conditionals.
+ (expression_maybe_register, xtensa_symbol_new_hook,
+ fix_new_exp_in_seg): Use symbol_get_tc.
+
+2003-09-09 Bob Wilson <bob.wilson@acm.org>
+
+ * config/tc-xtensa.c (xtensa_literal_pseudo): Remove code for
+ combining identical literals.
+ (expression_maybe_register): Remove call to find_lit_sym_translation.
+ (is_duplicate_expression, cache_literal, is_duplicate_literal,
+ add_lit_sym_translation, find_lit_sym_translation): Delete.
+
+2003-09-07 Nick Clifton <nickc@redhat.com>
+
+ * doc/as.texinfo (Comments): Comment character for PPC is #.
+
+2003-09-06 Stephane Carrez <stcarrez@nerim.fr>
+
+ PR savannah/4358:
+ * config/tc-m68hc11.c (s_m68hc11_relax): Use 2 for size to avoid
+ overflow complain.
+
+2003-09-05 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-frv.c (md_pcrel_from_section): Heed TC_FORCE_RELOCATION.
+
+2003-09-04 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-v850.c (set_machine): Accept v850e1 machine number.
+ (md_pseudo_table): Add .v850e1 pseudo op.
+ (md_show_usage): Document -mv850e1 switch.
+ (md_parse_option): Accept -mv850e1 switch.
+ (md_begin): Allow TARGET_CPU to be v850e1.
+ * doc/c-v850.texi: Document -mv850e1 switch and .v850e1 pseudo op.
+ * NEWS: Mention support for v850e1.
+
+2003-09-04 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ppc.c (md_parse_option): Add PPC_OPCODE_ANY to existing
+ ppc_cpu selection rather than replacing.
+ (ppc_set_cpu): Ignore and preserve PPC_OPCODE_ANY in ppc_cpu.
+ (md_begin): When PPC_OPCODE_ANY, insert all opcodes in ppc_hash.
+
+2003-09-03 Robert Millan <robertmh@gnu.org>
+
+ * configure.in: Match GNU/KFreeBSD with new kfreebsd*-gnu
+ triplet.
+ * configure: Regenerate.
+
+2003-09-02 Daniel Jacobowitz <drow@mvista.com>
+
+ * configure.in: Update AC_PREREQ to 2.57. Use AC_CONFIG_FILES
+ and AC_CONFIG_COMMANDS instead of the three-argument AC_OUTPUT.
+ Specify AC_CONFIG_AUX_DIR.
+ * aclocal.m4: Regenerated with aclocal-1.7.
+ * configure: Regenerated with autoconf 2.57.
+ * Makefile.in, doc/Makefile.in: Regenerated with automake-1.7.
+
+2003-08-29 Jakub Jelinek <jakub@redhat.com>
+
+ * dw2gencfi.c (cfi_pseudo_table): Add cfi_window_save.
+ (dot_cfi, output_cfi_insn): Handle DW_CFA_GNU_window_save.
+ (output_cie): Don't use DW_EH_PE_pcrel if neither DIFF_EXPR_OK
+ nor tc_cfi_emit_pcrel_expr are defined.
+ (output_fde): Use tc_cfi_emit_pcrel_expr if available and
+ DIFF_EXPR_OK is not defined.
+ * config/tc-sparc.h (TARGET_USE_CFIPOP): Define.
+ (tc_cfi_frame_initial_instructions, tc_regname_to_dw2regnum,
+ tc_cfi_emit_pcrel_expr): Define.
+ (sparc_cfi_frame_initial_instructions, sparc_regname_to_dw2regnum,
+ sparc_cfi_emit_pcrel_expr): New prototypes.
+ (sparc_cie_data_alignment): New decl.
+ (DWARF2_DEFAULT_RETURN_COLUMN, DWARF2_CIE_DATA_ALIGNMENT): Define.
+ * config/tc-sparc.c: Include dw2gencfi.h.
+ (sparc_cie_data_alignment): New variable.
+ (md_begin): Initialize it.
+ (sparc_cfi_frame_initial_instructions): New function.
+ (sparc_regname_to_dw2regnum): Likewise.
+ (sparc_cfi_emit_pcrel_expr): Likewise.
+ * doc/as.texinfo: Document .cfi_window_save.
+
+ * config/tc-sparc.c (s_common): Cast last argument to long and
+ change format string to shut up warning.
+
+2003-08-25 Jason Eckhardt <jle@rice.edu>
+
+ * doc/c-i860.texi: Update text about relocatable address expansions.
+
+2003-08-24 Jason Eckhardt <jle@rice.edu>
+
+ * config/tc-i860.c (md_assemble): Use isrc2 from the original
+ instruction when expanding E_ADDR.
+
+2003-08-21 Nick Clifton <nickc@redhat.com>
+
+ * po/tr.po: Updated Turkish translation.
+
+2003-08-20 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ppc.c (md_parse_option): Add PPC_OPCODE_ISEL and
+ PPC_OPCODE_RFMCI to -m440 selected ppc_cpu.
+
+2003-08-19 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-arm.c (cp_address_required_here): Add code to handle
+ unindexed addressing mode.
+
+2003-08-19 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ppc.c (md_parse_option): Handle -m440.
+ (md_show_usage): Add -m440.
+ (md_apply_fix3): Warning fix.
+ * doc/c-ppc.texi: Document -m440.
+
+2003-08-16 Benjamin Kalytta <bkausbk@web.de>
+
+ * read.c (s_print): Check for NULL.
+
+2003-08-16 Alan Modra <amodra@bigpond.net.au>
+
+ * write.c (fixup_segment): When handling an expression involving
+ the subtraction of two symbols in the same segment, don't clear
+ fx_pcrel except for TC_M68K.
+
+2003-08-14 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-i386.h: Remove BFD_ASSEMBLER tests and all !BFD_ASSEMBLER
+ code.
+ * config/tc-i386.c: Likewise.
+ (RELOC_ENUM): Don't define. Replace throughout with enum.
+
+ * dep-in.sed: Remove libintl.h. Ignore include/fopen-*.h
+ * Makefile.am (POTFILES.in): Unset LC_COLLATE.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2003-08-08 Andreas Schwab <schwab@suse.de>
+
+ * config/tc-m68k.h (TARGET_USE_CFIPOP)
+ (DWARF2_DEFAULT_RETURN_COLUMN, DWARF2_CIE_DATA_ALIGNMENT)
+ (tc_regname_to_dw2regnum, tc_cfi_frame_initial_instructions):
+ Define.
+ * config/tc-m68k.c: Include "dw2gencfi.h".
+ (tc_m68k_regname_to_dw2regnum)
+ (tc_m68k_frame_initial_instructions): New functions.
+
+2003-08-08 Dmitry Diky <diwil@mail.ru>
+
+ * config/tc-msp430.c: Add xW42 and xE42 parts. Sort MPU list
+ according to gcc order.
+
+2003-08-07 Jason Eckhardt <jle@rice.edu>
+
+ * config/tc-i860.c (i860_check_label): New function.
+ * config/tc-i860.h (i860_check_label): New prototype.
+ (tc_check_label): Define macro as i860_check_label.
+
+2003-08-06 Jason Eckhardt <jle@rice.edu>
+
+ * config/tc-i860.c (s_align_wrapper): New function and prototype.
+ (md_pseudo_table): Change s_align_bytes to s_align_wrapper, remove
+ surrounding OBJ_ELF ifdef, and re-format slightly.
+ * doc/c-i860.texi: Document the special .align syntax available
+ in Intel mode.
+
+2003-08-06 Jason Eckhardt <jle@rice.edu>
+
+ * config/tc-i860.c (i860_handle_align): New function.
+ * config/tc-i860.h (HANDLE_ALIGN): Define macro.
+ (MAX_MEM_FOR_RS_ALIGN_CODE): Define macro.
+
+2003-08-06 Jason Eckhardt <jle@rice.edu>
+
+ * config/tc-i860.c (i860_process_insn): Check that instructions
+ with their dual-bit set are 8-byte aligned.
+
+2003-08-06 Nick Clifton <nickc@redhat.com>
+
+ * po/fr.po: Updated French translation.
+
+2003-08-05 Jason Eckhardt <jle@rice.edu>
+
+ * config/tc-i860.c (i860_process_insn): Don't handle dual-bit
+ setting during flop argument parsing. Instead, do it after
+ instruction is fully parsed.
+
+2003-08-05 Jason Eckhardt <jle@rice.edu>
+
+ * doc/c-i860.texi: Mention that .dual, .enddual, and .atmp
+ directives are only available in Intel syntax mode.
+
+2003-08-05 Jason Eckhardt <jle@rice.edu>
+
+ * config/tc-i860.c (s_dual): Accept .dual directive only in
+ the Intel syntax mode.
+ (s_enddual): Likewise for .enddual.
+ (s_atmp): Likewise for .atmp.
+
+2003-08-04 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-i386.c (i386_intel_operand): Always call i386_index_check
+ for memory operands. Pass the full operand_string to i386_index_check.
+
+2003-08-01 Jason Eckhardt <jle@rice.edu>
+
+ * config/tc-i860.c: Remove SYNTAX_SVR4 macro and occurrences.
+ (target_intel_syntax): Declare variable.
+ (OPTION_INTEL_SYNTAX): Declare macro.
+ (md_longopts): Add option -mintel-syntax.
+ (md_parse_option): Set target_intel_syntax.
+ (md_show_usage): Add -mintel-syntax usage.
+ (md_begin): Set reg_prefix based on target_intel_syntax.
+ (i860_process_insn): Skip register prefix only if there is one.
+ Parse relocatable expressions in either Intel or AT&T syntax based
+ on target_intel_syntax instead of the SYNTAX_SVR4 macro.
+ * doc/c-i860.texi: Document -mintel-syntax option and give blurb
+ about the differences in syntax.
+
+2003-08-01 Dmitry Diky <diwil@mail.ru>
+
+ * config/tc-msp430.c (msp430_srcoperand): Extend 'push' bug workaround
+ to all arches.
+
+2003-07-30 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * config/tc-sh.c (md_assemble): For branches, check & update
+ valid_arch here.
+
+2003-07-30 Jason Eckhardt <jle@rice.edu>
+
+ * config/tc-i860.c: Convert to ISO C90.
+
+2003-07-30 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
+
+ * read.c (s_space): Revert 2003-07-28 change.
+
+2003-07-30 Alan Modra <amodra@bigpond.net.au>
+
+ * config/obj-elf.c (obj_elf_change_section): Allow "x" for .note*.
+
+2003-07-29 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-sh.c (tc_gen_reloc): Test for R_SH_IND12W only when ELF.
+
+2003-07-29 Jakub Jelinek <jakub@redhat.com>
+
+ * config/tc-ppc.c (md_apply_fix3): Fix check for lq insns.
+
+2003-07-28 H.J. Lu <hongjiu.lu@intel.com>
+
+ * config/obj-elf.c (obj_elf_section_type): Also accept "note".
+
+2003-07-28 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
+
+ * read.c (s_space): Don't warn about .space 0.
+
+2003-07-28 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
+
+ * config/tc-mips.c (mips_flag_pdr): Define.
+ (md_begin) [OBJ_ELF]: Use it to control .pdr creation.
+ (s_mips_end) [OBJ_ELF]: Likewise.
+ (md_longopts) [OBJ_ELF]: Define OPTION_PDR, OPTION_NO_PDR.
+ (md_parse_option) [OBJ_ELF]: Handle them.
+ (md_show_usage) [OBJ_ELF]: Document -mpdr, -mno-pdr.
+
+ * doc/c-mips.texi (MIPS Opts): Document -mpdr, -mno-pdr.
+ * doc/as.texinfo (Overview) [MIPS]: Likewise.
+
+2003-07-25 H.J. Lu <hongjiu.lu@intel.com>
+
+ * config/obj-elf.c (obj_elf_change_section): Update
+ elf_section_type and elf_section_flags only when they are
+ specified.
+
+2003-07-25 H.J. Lu <hongjiu.lu@intel.com>
+
+ * config/obj-elf.c (obj_elf_change_section): Always set section
+ type and flags.
+
+2003-07-25 H.J. Lu <hongjiu.lu@intel.com>
+
+ * config/obj-elf.c (special_sections): Removed.
+ (obj_elf_change_section): Call _bfd_elf_get_sec_type_attr. Set
+ elf_section_type and elf_section_flags.
+ (elf_frob_file): Set SHT_GROUP.
+
+ * config/obj-elf.h (obj_sec_set_private_data): New.
+
+ * config/tc-alpha.h (ELF_TC_SPECIAL_SECTIONS): Removed.
+ * config/tc-ia64.h: Likewise.
+ * config/tc-m32r.h: Likewise.
+ * config/tc-m68hc11.h: Likewise.
+ * config/tc-mcore.h: Likewise.
+ * config/tc-mips.h: Likewise.
+ * config/tc-ppc.h: Likewise.
+ * config/tc-sh64.h: Likewise.
+ * config/tc-v850.h: Likewise.
+ * config/tc-xtensa.h: Likewise.
+
+ * config/tc-v850.h (SHF_V850_GPREL): Removed.
+ (SHF_V850_EPREL): Likewise.
+ (SHF_V850_R0REL): Likewise.
+
+ * subsegs.c (subseg_get): Call obj_sec_set_private_data if it
+ is defined.
+
+2003-07-24 Stephane Carrez <stcarrez@nerim.fr>
+
+ * config/tc-m68hc11.h (DWARF2_ADDR_SIZE): Use 32-bit address for
+ debugging symbols so that we handle page memory correctly.
+
+2003-07-24 Nick Clifton <nickc@redhat.com>
+
+ * po/fr.po: Updated French translation.
+
+2003-07-23 Daniel Jacobowitz <drow@mvista.com>
+
+ * config/tc-arm.c (arm_archs): Add iwmmxt.
+
+2003-07-22 H.J. Lu <hongjiu.lu@intel.com>
+
+ * read.c (do_parse_cons_expression): Mark nbytes unused to
+ silence gcc.
+
+2003-07-22 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-h8300.c (get_specific): No PCREL8 encoding for bsr/bc
+ or bsr/bs.
+
+ * config/tc-h8300.c (md_assemble): Make sure characters after
+ slash and dot are lower-case.
+
+2003-07-17 Nick Clifton <nickc@redhat.com>
+
+ * po/es.po: New Spanish translation.
+ * po/tr.po: New Turkish translation.
+ * po/opcodes.pot: Regenerate.
+
+2003-07-16 Alan Modra <amodra@bigpond.net.au>
+
+ * dwarf2dbg.c (get_frag_fix): Revert 2001-11-15 change.
+ (generic_dwarf2_emit_offset): Don't define function when
+ TC__DWARF2_EMIT_OFFSET is defined.
+
+2003-07-15 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-mips.c (hilo_interlocks): True for CPU_RM7000.
+ (mips_cpu_info_table): Add rm7000 and rm9000 entries.
+ * doc/c-mips.texi: Document -march=rm9000.
+
+2003-07-15 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-v850.c (md_assemble): When no reloc, create pcrel fixups
+ only for V850_OPERAND_DISP operands.
+
+2003-07-15 Alan Modra <amodra@bigpond.net.au>
+
+ * frags.c (frag_more): Move segment checks to..
+ (frag_alloc_check): ..here. New function.
+ (frag_append_1_char): Call frag_alloc_check.
+
+2003-07-14 Nick Clifton <nickc@redhat.com>
+
+ * po/tr.po: Update with latest version.
+ * po/POTFILES.in: Regenerate.
+ * po/gas.pot: Regenerate.
+ * configure: Regenerate.
+
+2003-07-14 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-ip2k.c: Remove inclusion of <ctype.h>
+ * config/tc-tic4x.c: Replace inclusion of <ctype.h> with
+ "safe-ctype.h" and update use of macros.
+ * Makefile.am: Update dependencies.
+ * Makefile.in: Regenerate.
+
+2003-07-11 Alan Modra <amodra@bigpond.net.au>
+
+ * po/gas.pot: Regenerate.
+
+2003-07-10 Jakub Jelinek <jakub@redhat.com>
+
+ * config/tc-ppc.h (DWARF2_LINE_MIN_INSN_LENGTH): Define always.
+ (TARGET_USE_CFIPOP, tc_cfi_frame_initial_instructions,
+ tc_regname_to_dw2regnum, DWARF2_DEFAULT_RETURN_COLUMN,
+ DWARF2_CIE_DATA_ALIGNMENT): Define.
+ (ppc_cfi_frame_initial_instructions, tc_ppc_regname_to_dw2regnum): New
+ prototypes.
+ (ppc_cie_data_alignment): Declare.
+ * config/tc-ppc.c: Include dw2gencfi.h.
+ (ppc_cie_data_alignment): Define.
+ (md_begin): Initialize ppc_cie_data_alignment.
+ (ppc_cfi_frame_initial_instructions, tc_ppc_regname_to_dw2regnum): New
+ functions.
+ * config/tc-s390.h (DWARF2_LINE_MIN_INSN_LENGTH): Define always.
+ (TARGET_USE_CFIPOP, tc_cfi_frame_initial_instructions,
+ tc_regname_to_dw2regnum, DWARF2_DEFAULT_RETURN_COLUMN,
+ DWARF2_CIE_DATA_ALIGNMENT): Define.
+ (s390_cfi_frame_initial_instructions, tc_s390_regname_to_dw2regnum):
+ New prototypes.
+ (s390_cie_data_alignment): Declare.
+ * config/tc-s390.c: Include dw2gencfi.h.
+ (s390_cie_data_alignment): Define.
+ (md_begin): Initialize s390_cie_data_alignment.
+ (s390_cfi_frame_initial_instructions, tc_s390_regname_to_dw2regnum):
+ New functions.
+
+2003-07-10 Alexandre Oliva <aoliva@redhat.com>
+
+ 2002-12-12 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-mn10300.h (EXTERN_FORCE_RELOC): Don't define to zero.
+ 2001-05-09 Alexandre Oliva <aoliva@redhat.com>
+ * configure.in (am33_2.0, mn10300-*-linux*): Added.
+ * configure: Rebuilt.
+ * config/tc-mn10300.h (TARGET_FORMAT) [TE_LINUX]: Define to
+ elf32-am33lin.
+ * config/tc-mn10300.c (md_begin) [TE_LINUX]: Choose AM33/2.0
+ by default.
+
+2003-07-09 Alexandre Oliva <aoliva@redhat.com>
+
+ 2003-02-25 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-mn10300.c (mn10300_check_fixup): Set GOT_PCREL type
+ for subtracts from GLOBAL_OFFSET_TABLE that could not be
+ simplified.
+ 2002-07-18 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-mn10300.c (mn10300_check_fixup): Accept subtracts that
+ could not be simplified.
+ (tc_gen_reloc): Turn an absolute fx_subsy into part of fx_offset.
+ 2001-11-04 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-mn10300.h (TC_RELOC_RTSYM_LOC_FIXUP): Don't adjust
+ BDF_RELOC_MN10300_GOT32.
+ * config/tc-mn10300.c (mn10300_fix_adjustable): If
+ TC_RELOC_RTSYM_LOC_FIXUP doesn't hold, it's not adjustable.
+ 2001-05-09 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-mn10300.c (mn10300_parse_name): Don't return a
+ symbol if we know its value.
+ 2001-05-09 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-mn10300.h (GLOBAL_OFFSET_TABLE_NAME): Remove
+ duplicate underscore prefix.
+ 2001-05-09 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-mn10300.c (mn10300_parse_name): Store relocation
+ type in X_md, not X_add_number. Zero X_add_number.
+ (mn10300_check_fixup): Extract relocation type from X_md.
+ * config/tc-mn10300.h: Update comment.
+ 2001-04-14 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-mn10300.h (O_GOTOFF, O_PLT, O_GOT): Replace with...
+ (O_PIC_reloc): this.
+ * config/tc-mn10300.c (mn10300_PIC_related_p): Use it.
+ (mn10300_check_fixup): Likewise.
+ (mn10300_parse_name): Set X_add_number to relocation type.
+ * config/tc-mn10300.h (DIFF_EXPR_OK, GLOBAL_OFFSET_TABLE_NAME,
+ TC_RELOC_RTSYM_LOC_FIXUP, md_parse_name, TC_CONS_FIX_NEW,
+ O_GOTOFF, O_PLT, O_GOT): Define.
+ * config/tc-mn10300.c (mn10300_PIC_related_p): New fn.
+ (mn10300_check_fixup): New fn.
+ (md_assemble): Call it. Check for PIC-related relocs.
+ (mn10300_cons_fix_new): Likewise. New fn.
+ (mn10300_end_of_match): New fn.
+ (mn10300_md_parse_name_cont): New fn.
+
+2003-07-09 Alexandre Oliva <aoliva@redhat.com>
+
+ 2000-05-25 Alexandre Oliva <aoliva@cygnus.com>
+ * config/tc-mn10300.c (mn10300_insert_operand): Negate negative
+ accumulator's shift.
+ 2000-05-08 Alexandre Oliva <aoliva@cygnus.com>
+ * config/tc-mn10300.c (md_relax_table, md_convert_frag,
+ md_assemble, md_estimate_size_before_relax): Handle fbCC.
+ 2000-04-20 Alexandre Oliva <aoliva@cygnus.com>
+ * config/tc-mn10300.c (HAVE_AM33): Redefine in terms of
+ HAVE_AM33_2.
+ 2000-04-03 Alexandre Oliva <aoliva@cygnus.com>
+ * config/tc-mn10300.c (md_pseudo_table): Use AM33_2 constant.
+ (HAVE_AM33): Match AM33_2 too.
+ (HAVE_AM33_2): New macro.
+ (md_assemble): Use it. Match 2.0 registers only if HAVE_AM33_2.
+ 2000-04-01 Alexandre Oliva <aoliva@cygnus.com>
+ * config/tc-mn10300.c (md_pseudo_table): Added `am33_2'.
+ (float_registers, double_registers): New variables.
+ (float_register_name, double_register_name): New functions.
+ (md_assemble): Recognize FP registers. Implement FMT_D3.
+ (mn10300_insert_operand): Support FP registers.
+
+2003-07-08 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (mips_validate_fix): Do not warn about branch
+ target being a global symbol if not compiling SVR4 PIC code.
+
+2003-07-07 Nick Clifton <nickc@redhat.com>
+
+ * doc/c-m32r.texi (M32R-Directives): New node. Document the
+ .high, .shigh and .low directives.
+
+2003-07-07 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-h8300.c (h8300sxnmode): Add prototype.
+ (DSYMMODE): Remove.
+ (parse_exp): Replace expressionS argument with a h8_op. Parse the
+ operand size as well.
+ (skip_colonthing): Remove unused expression argument. Tighten checks
+ for 2-digit sizes.
+ (colonmod24): Remove.
+ (get_mova_operands): Combine calls to parse_exp and skip_colonthing.
+ (get_operand): Likewise. Use the standard code to read the size of
+ pc-relative operands.
+ (fix_operand_size): Include the size-guessing logic that used to be
+ in colonmod24 and get_operand. Don't apply dd:2 optimizations to
+ offsets with a symbolic component.
+
+2003-07-04 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-i386.c (tc_x86_regname_to_dw2regnum): Use ARRAY_SIZE
+ macro to compute size of selected register name array.
+
+2003-07-01 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * config/tc-s390.c (md_parse_option): Add cpu type z990.
+ (md_begin): Add minimal cpu type logic for instructions with different
+ binary format depending on the cpu.
+ (md_assemble): Remove check for minimal cpu.
+ (s390_insert_operand): Add support for long displacements.
+ (md_gather_operands): Likewise.
+ (tc_s390_fix_adjustable): Likewise.
+ (tc_s390_force_relocation): Likewise.
+ (md_apply_fix3): Likewise.
+
+2003-06-30 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (s_mipsset): Implement -march= handling
+ differently.
+
+2003-06-30 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c: Convert to ISO C90 prototypes. Remove unnecessary
+ prototypes and casts. Replace PTR with void *. Reformat.
+ * config/tc-mips.h: Likewise.
+
+2003-06-30 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ia64.c (note_register_values): Warning fix.
+ * config/tc-mips.c (append_insn): Likewise.
+
+2003-06-29 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (mips_set_options,mips_opts): Support for
+ .set arch=FOO.
+ (file_mips_arch): Rename mips_arch.
+ (mips_arch_info,mips_tune_info): Remove.
+ (hilo_interlocks,gpr_interlocks,cop_interlocks): Use mips_opts.arch.
+ (mips_cpu_info_from_arch): New function.
+ (md_begin): Use file_mips_arch.
+ (macro_build,macro,mips_ip): Use mips_opts.arch.
+ (mips_set_architecture): Init file_mips_arch and mips_opts.arch.
+ (mips_after_parse_args): Remove mips_arch_info and mips_tune_info.
+ Use file_mips_arch.
+ (s_mipsset): Support for .set arch=FOO.
+ (mips_cpu_info_table): Fix typo.
+
+2003-06-26 H.J. Lu <hongjiu.lu@intel.com>
+
+ * config/tc-i386.c (md_assemble): Declare "exp" before "if".
+
+2003-06-25 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-h8300.c (get_specific): Allow ':8' to be used for
+ unsigned 8-bit operands.
+
+2003-06-24 Nick Clifton <nickc@redhat.com>
+
+ * read.c (s_comm): Change error message to assume an unsigned size
+ has been passed to .comm.
+ * config/tc-sparc.c (s_common): Likewise.
+ * write.c (write_contents): Replace 'unsigned long' with
+ 'addressT' and 'long' with offsetT in order to allow computations
+ with very large values to work for 64-bit addressed targets.
+ (relax_and_size_all_segments): Likewise.
+ (relax_frag): Likewise.
+ (relax_segment): Likewise.
+
+2003-06-23 Mark Mitchell <mark@codesourcery.com>
+
+ * config/tc-ppc.c (ppc_cleanup): Use bytes to count APUinfo slots.
+
+2003-06-23 H.J. Lu <hongjiu.lu@intel.com>
+
+ * gas/config/tc-i386.c (md_assemble): Support Intel Precott New
+ Instructions.
+
+ * gas/config/tc-i386.h (CpuPNI): New.
+ (CpuUnknownFlags): Add CpuPNI.
+
+2003-06-23 <davidm@hpl.hp.com>
+
+ * config/tc-ia64.c (pseudo_func): Add ABI constants for linux,
+ freebsd, openvms, and nsk (non-stop kernel).
+
+2003-06-22 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * config/tc-ns32k.c (md_begin): Initialize inst_hash_table after
+ all locals have been declared.
+
+2003-06-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (ADDRESS_ADD_INSN,ADDRESS_ADDI_INSN): Remove
+ special handling for n32 ABI.
+ (macro): Likewise.
+
+2003-06-19 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (s_cpsetup,s_cprestore,s_cpreturn): Revert
+ 2003-06-11 change.
+
+2003-06-19 Christian Groessler <chris@groessler.org>
+
+ * config/tc-z8k.c (parse_reg): Invalid registers generate an error
+ now, not only a warning. Add some more checks to detect invalid
+ registers.
+ (get_operand): For CLASS_IR remember register size in mode struct.
+ (get_specific): Handle new CLASS_IRO type. Add register size
+ checks for CLASS_IR and CLASS_IRO.
+ (md_apply_fix3): Fix undefined usage of buf.
+
+2003-06-19 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ppc.c (ppc_csect): Pass alignment to ppc_change_csect.
+ (ppc_change_csect): Add align param. Align frag at start of csect.
+ (ppc_section, ppc_named_section): Adjust ppc_change_csect calls.
+ (ppc_frob_section): Align vma.
+
+2003-06-18 Jakub Jelinek <jakub@redhat.com>
+
+ * dw2gencfi.c (EH_FRAME_ALIGNMENT): Define if not defined.
+ (output_cie): Don't pad.
+ (output_fde): Add align argument. Pad to align if not 0.
+ (cfi_finish): Set .eh_frame alignment to EH_FRAME_ALIGNMENT.
+ Pad just last FDE to EH_FRAME_ALIGNMENT.
+
+2003-06-18 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * config/tc-s390.c (init_default_arch): Make current_mode_mask
+ dependent on s390_arch_size and current_cpu dependent on
+ current_mode_mask.
+
+2003-06-18 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * configure.in: Add c4x as an architecture variant to tic4x.
+ * configure: Regenerate.
+ * Makefile.in: Regenerate.
+ * doc/Makefile.in: Regenerate.
+
+2003-06-18 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ppc.c (ppc_elf_suffix): Don't remove symbols other than
+ ".TOC." from PPC64_TOC relocs.
+
+2003-06-17 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ppc.c (md_apply_fix3): Allow BRTAKEN, BRNTAKEN relocs.
+
+2003-06-16 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (ADDRESS_ADD_INSN,ADDRESS_ADDI_INSN,
+ ADDRESS_LOAD_INSN,ADDRESS_STORE_INSN): New macros.
+ (macro_build_ldst_constoffset,load_address,macro,s_cpsetup,
+ s_cprestore,s_cpadd): Use them.
+
+2003-06-16 Hans-Peter Nilsson <hp@axis.com>
+
+ * configure.in: Add specific case for cris-*-linux-gnu* with
+ em=linux.
+ * configure: Regenerate.
+ * config/tc-cris.c (DEFAULT_CRIS_AXIS_LINUX_GNU): New macro, TRUE
+ if TE_LINUX defined, else FALSE.
+ (bfd_boolean demand_register_prefix): Set default from
+ DEFAULT_CRIS_AXIS_LINUX_GNU.
+ (symbols_have_leading_underscore): Similar.
+ * config/tc-cris.h (LOCAL_LABELS_DOLLAR): Define to 1.
+
+2003-06-13 Richard Earnshaw <rearnsha@arm.com>
+
+ * tc-arm.c (FPU_DEFAULT, case TE_LINUX): Default to FPU_ARCH_FPA.
+ (FPU_DEFAULT, case TE_NetBSD): Default to FPU_ARCH_VFP for ELF,
+ FPU_ARCH_FPA for AOUT.
+ (md_begin): Don't try to guess the floating point architecture from
+ the CPU if the OS ABI (Linux, NetBSD) mandates a particular form.
+
+2003-06-13 Robert Millan <zeratul2@wanadoo.es>
+
+ * configure.in: Add i386-netbsd-gnu target.
+ * configure: Regenerate.
+
+2003-06-12 Tom Tromey <tromey@redhat.com>
+
+ * doc/as.texinfo (Comm): Added @node. Moved before CFI
+ directives node.
+
+2003-06-12 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-mips.c (append_insn): In a compound relocation, take the
+ field width from the final (outermost) operator.
+
+2003-06-11 Richard Henderson <rth@redhat.com>
+
+ * dw2gencfi.c (struct cfi_escape_data): New.
+ (cfi_add_CFA_nop): Remove.
+ (CFI_escape, dot_cfi_escape): New.
+ (dot_cfi): Remove nop.
+ (cfi_pseudo_table): Remove nop; add escape.
+ (output_cfi_insn): Likewise.
+ (select_cie_for_fde): Stop on escape.
+ * dw2gencfi.h (cfi_add_CFA_nop): Remove.
+ * read.c, read.h (do_parse_cons_expression): New.
+ * doc/as.texinfo (.cfi_escape): New.
+
+2003-06-11 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (s_cpsetup): Use mips_frame_reg instead of SP.
+ (s_cprestore): Likewise.
+ (s_cpreturn): Likewise.
+
+2003-06-11 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (tc_gen_reloc): Initialize retval amd reloc
+ with zeros.
+
+2003-06-11 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (md_pcrel_from): Return actual pcrel address.
+ (md_apply_fix3): Ignore non-special relocations. Remove superfluous
+ exceptions from size assert. Remove most of the addend fixup
+ specialcasing. Remove value, use valP directly. simplify fx_addnumber
+ handling. Remove zero addend specialcases.
+ (tc_gen_reloc): Use appropriate value for reloc2 addend. Remove
+ the addend fixup specialcase.
+ * config/tc-mips.h (MD_APPLY_SYM_VALUE): Define as 0.
+
+2003-06-11 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * write.c (write_relocs): Use xcalloc. Fix relocs initialization
+ in the RELOC_EXPANSION_POSSIBLE case.
+
+2003-06-11 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-i960.c (line_comment_chars): Add '#'.
+ * config/tc-mn10200.c (tc_gen_reloc): Don't ignore fx_subsy.
+
+2003-06-11 H.J. Lu <hongjiu.lu@intel.com>
+
+ * po/Make-in (DESTDIR): New.
+ (install-data-yes): Support $(DESTDIR).
+ (uninstall): Likewise.
+
+2003-06-11 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * po/POTFILES.in: Regenerate.
+
+2003-06-10 Doug Evans <dje@sebabeach.org>
+
+ * cgen.c (gas_cgen_finish_insn): CGEN_INSN_RELAX renamed to
+ CGEN_INSN_RELAXED.
+ * config/tc-fr30.c (md_estimate_size_before_relax): Ditto.
+ * config/tc-m32r.c (md_estimate_size_before_relax): Ditto.
+ * config/tc-openrisc.c (md_estimate_size_before_relax): Ditto.
+
+2003-06-10 Alan Modra <amodra@bigpond.net.au>
+ Gary Hade <garyhade@us.ibm.com>
+
+ * config/tc-ppc.c (md_assemble): Handle PPC_OPERAND_DQ.
+ (md_apply_fix3): Special case lq insn.
+
+2003-06-10 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-h8300.c (get_rtsl_operands): Accept unbracketed register
+ lists. Allow single-register ranges.
+
+2003-06-10 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-h8300.c (h8300sxnmode): New.
+ (md_pseudo_table): Add .h8300sxn entry.
+
+2003-06-09 H.J. Lu <hongjiu.lu@intel.com>
+
+ * NEWS: Updated for the new -n option for the i386 assembler.
+
+ * config/tc-i386.c (optimize_align_code): New.
+ (md_shortopts): Add 'n'.
+ (md_parse_option): Handle 'n'.
+ (md_show_usage): Add '-n'.
+
+ * config/tc-i386.h (optimize_align_code): Declared.
+ (md_do_align): Optimize code alignment only if optimize_align_code
+ is not 0.
+
+ * doc/as.texinfo: Add the new -n option.
+
+ * doc/c-i386.texi: Document the new -n option.
+
+2003-06-07 Richard Henderson <rth@redhat.com>
+
+ * doc/as.texinfo: Document .cfi_rel_offset.
+
+ * dw2gencfi.c (struct cfa_save_data, cfa_save_stack): New.
+ (cfi_add_CFA_offset): Detect invalid offsets.
+ (cfi_add_CFA_remember_state): Save cur_cfa_offset.
+ (cfi_add_CFA_restore_state): Restore it.
+ (CFI_rel_offset): New.
+ (cfi_pseudo_table): Add it.
+ (dot_cfi): Handle it.
+
+2003-06-07 H.J. Lu <hongjiu.lu@intel.com>
+
+ * app.c (do_scrub_chars): Add states 14 and 15 to handle
+ predicate for ia64.
+
+2003-06-05 Michael Snyder <msnyder@redhat.com>
+
+ * config/tc-h8sx.c (get_specific): Distinguish h8h from h8s ops.
+ (build_bytes): Ditto.
+
+2003-06-05 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-h8sx.c (DMODE): Remove.
+ (colonmod24): Don't choose a default if the operand is a 16-bit
+ constant integer.
+ (fix_operand_size): New function.
+ (md_assemble): Use it to choose between @(d:2, ERn) and @(d:16,ERn).
+ Adjust @(d:2,ERn) operands before choosing the specific opcodes.
+
+2003-06-05 Michal Ludvig <mludvig@suse.cz>
+
+ * dw2gencfi.c (cfi_add_CFA_insn, cfi_add_CFA_insn_reg)
+ (cfi_add_CFA_insn_reg_reg, cfi_add_CFA_insn_reg_offset): New.
+ (cfi_add_CFA_offset, cfi_add_CFA_def_cfa)
+ (cfi_add_CFA_register, cfi_add_CFA_def_cfa_register)
+ (cfi_add_CFA_def_cfa_offset): Use cfi_add_CFA_insn_*().
+ (cfi_add_CFA_restore, cfi_add_CFA_undefined)
+ (cfi_add_CFA_same_value, cfi_add_CFA_remember_state)
+ (cfi_add_CFA_restore_state, cfi_add_CFA_nop): New.
+ (cfi_pseudo_table): New directives .cfi_return_column,
+ .cfi_restore, .cfi_undefined, .cfi_same_value,
+ .cfi_remember_state, .cfi_restore_state, .cfi_nop.
+ (dot_cfi, output_cfi_insn): Handle new directives.
+ * dw2gencfi.h (cfi_add_CFA_restore, cfi_add_CFA_undefined)
+ (cfi_add_CFA_same_value, cfi_add_CFA_remember_state)
+ (cfi_add_CFA_restore_state, cfi_add_CFA_nop): New prototypes.
+
+2003-06-04 Richard Henderson <rth@redhat.com>
+
+ * dw2gencfi.c (output_cfi_insn): Fix typo for negative offsets.
+
+ * dw2gencfi.c (cfi_finish): Set .eh_frame read-only.
+
+2003-06-04 Richard Henderson <rth@redhat.com>
+
+ * config/tc-alpha.c (s_alpha_usepv): New.
+ (md_pseudo_table): Add it.
+ (alpha_cfi_frame_initial_instructions): New.
+ * config/tc-alpha.h (TARGET_USE_CFIPOP): New.
+ (tc_cfi_frame_initial_instructions): New.
+ * doc/c-alpha.texi: Document .usepv.
+
+2003-06-04 Jakub Jelinek <jakub@redhat.com>
+
+ * as.c (show_usage): Document --execstack and --noexecstack.
+ (parse_args): Add --execstack and --noexecstack.
+ (main): Create .note.GNU-stack section if --execstack or
+ --noexecstack was given on comand line, set its SHF_EXECINSTR bit.
+ * as.h (flag_execstack, flag_noexecstack): New.
+
+2003-06-03 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c: (OPTION_ARCH_BASE, OPTION_ASE_BASE)
+ (OPTION_COMPAT_ARCH_BASE, OPTION_FIX_BASE)
+ (OPTION_MISC_BASE): New defines.
+ (OPTION_BREAK, OPTION_CONSTRUCT_FLOATS, OPTION_EB, OPTION_EL)
+ (OPTION_ELF_BASE, OPTION_FIX_VR4122, OPTION_FP32, OPTION_FP64)
+ (OPTION_GP32, OPTION_GP64, OPTION_M3900, OPTION_M4010, OPTION_M4100)
+ (OPTION_M4650, OPTION_M7000_HILO_FIX, OPTION_MARCH, OPTION_MDMX)
+ (OPTION_MEMBEDDED_PIC, OPTION_MIPS1, OPTION_MIPS16, OPTION_MIPS2)
+ (OPTION_MIPS3, OPTION_MIPS32, OPTION_MIPS32R2, OPTION_MIPS3D)
+ (OPTION_MIPS4, OPTION_MIPS5, OPTION_MIPS64)
+ (OPTION_MNO_7000_HILO_FIX, OPTION_MTUNE, OPTION_NO_CONSTRUCT_FLOATS)
+ (OPTION_NO_FIX_VR4122, OPTION_NO_M3900, OPTION_NO_M4010)
+ (OPTION_NO_M4100, OPTION_NO_M4650, OPTION_NO_MDMX, OPTION_NO_MIPS16)
+ (OPTION_NO_MIPS3D, OPTION_NO_RELAX_BRANCH, OPTION_RELAX_BRANCH)
+ (OPTION_TRAP): Redefine in terms of new defines.
+ (md_longopts): Reorder entries.
+
+2003-05-14 Michael Snyder <msnyder@redhat.com>
+ From Bernd Schmidt <bernds@redhat.com>
+ and Michael Snyder <msnyder@redhat.com>
+ and Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-h8300.c: Add insns and addressing modes for h8300sx.
+ * config/tc-h8300.h: Ditto.
+
+2003-06-03 Nick Clifton <nickc@redhat.com>
+
+ * tc-v850.c (tc-gen_reloc): Translate BFD_RELOC_32 into
+ BFD_RELOC_32_PCREL if the reloc is pc-relative. Do this
+ before calling bfd_reloc_type_lookup.
+
+2003-06-02 Alan Modra <amodra@bigpond.net.au>
+
+ * read.c (emit_expr): Set dot_value.
+ * dw2gencfi.c (output_fde): Remove pcrel reloc hack.
+
+2003-06-02 Alan Modra <amodra@bigpond.net.au>
+
+ * macro.c (sub_actual): Don't lose string if it turns out that
+ &string wasn't an arg.
+
+2003-05-31 Richard Henderson <rth@redhat.com>
+
+ * dw2gencfi.c (output_fde): Use fix_new to emit pc-relative reloc.
+ (cfi_finish): Set flag_traditional_format around .eh_frame data.
+
+2003-05-29 Richard Henderson <rth@redhat.com>
+
+ * config/tc-alpha.c (alpha_cur_ent_sym): Remove.
+ (all_frame_data, plast_frame_data, cur_frame_data): New.
+ (s_alpha_ent): Record data for dwarf2 cfi.
+ (s_alpha_end, s_alpha_mask, s_alpha_frame, s_alpha_prologue): Likewise.
+ (alpha_elf_md_end): Emit dwarf2 cfi for ecoff unwind directives.
+ * config/tc-alpha.h (md_end): New.
+ (DWARF2_DEFAULT_RETURN_COLUMN): New.
+ (DWARF2_CIE_DATA_ALIGNMENT): New.
+
+2003-05-29 Nick Clifton <nickc@redhat.com>
+
+ * configure.in: Add i386-*-freebsd* entry.
+ * configure: Regenerate.
+
+2003-05-29 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
+
+ * config/tc-m32r.c: Amend comment to refer to Renesas
+
+2003-05-27 Richard Henderson <rth@redhat.com>
+
+ * expr.c (make_expr_symbol): Fold FAKE_LABEL_NAME use into the
+ symbol_create call.
+ (current_location): Use symbol_temp_new_now.
+ * stabs.c (s_stab_generic): Use symbol_temp_new.
+ * symbols.c (temp_label_name): Remove.
+ (symbol_temp_new, symbol_temp_make): Use FAKE_LABEL_NAME.
+
+2003-05-27 Richard Henderson <rth@redhat.com>
+
+ * dw2gencfi.c, dw2gencfi.h: Rewrite from scratch.
+ * as.c (main): Always call cfi_finish.
+ * config/tc-i386.c (x86_dwarf2_return_column): New.
+ (x86_cie_data_alignment): New.
+ (md_begin): Set them.
+ (tc_x86_cfi_init): Remove.
+ (tc_x86_regname_to_dw2regnum): Fix 32-bit register numbers;
+ return int, not unsigned long; don't as_bad here.
+ (tc_x86_frame_initial_instructions): Streamline; use
+ updated api.
+ * config/tc-i386.h (tc_cfi_init): Remove.
+ (DWARF2_DEFAULT_RETURN_COLUMN): New.
+ (DWARF2_CIE_DATA_ALIGNMENT): New.
+
+2003-05-27 Richard Henderson <rth@redhat.com>
+
+ * symbols.c (temp_label_name): New.
+ (symbol_temp_new, symbol_temp_new_now, symbol_temp_make): New.
+ (symbol_set_value_now): New.
+ * symbols.h: Prototype them.
+ * dwarf2dbg.c: Use them.
+ (fake_label_name, symbol_new_now, set_symbol_value_now): Remove.
+
+2003-05-23 Jason Eckhardt <jle@rice.edu>
+
+ * config/tc-i860.c (target_xp): Declare variable.
+ (OPTION_XP): Declare macro.
+ (md_longopts): Add option -mxp.
+ (md_parse_option): Set target_xp.
+ (md_show_usage): Add -mxp usage.
+ (i860_process_insn): Recognize XP registers bear, ccr, p0-p3.
+ (md_assemble): Don't try expansions if XP_ONLY is set.
+ * doc/c-i860.texi: Document -mxp option and i860XP support.
+
+2003-05-23 Eric Christopher <echristo@redhat.com>
+
+ * config/tc-mips.c (macro_build_jalr): Warning patrol.
+
+2003-05-22 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (append_insn): Use actual relocation size for new
+ fixp's. Don't relax overflow checking for partial_inplace relocations.
+ Use the actual relocation type in combined relocs, not just the type
+ of the first one.
+ (macro_build_jalr): Use actual relocation size for new fix.
+ (s_cpsetup, s_gpdword): Likewise.
+
+2003-05-22 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (macro): Don't use uninitialized tempreg.
+
+2003-05-22 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-xstormy16.c (md_pcrel_from_section): Do not produce
+ section relative offsets for relocs that will not be based on the
+ section symbol.
+ (xstormy16_md_apply_fix3): Remove previous patch to this
+ function.
+
+2003-05-07 Eric Christopher <echristo@redhat.com>
+
+ * config/tc-mips.c (mips_abicalls): New variable.
+ (md_parse_option): Use.
+ (s_option): Ditto.
+ (s_abicalls): Ditto.
+ (mips_elf_final_processing): Set EF_MIPS_PIC and
+ EF_MIPS_CPIC dependent on above.
+
+2003-05-21 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
+
+ * tc-hppa.c (hppa_symbol_chars): Remove `,' and `!'.
+
+2003-05-21 Nick Clifton <nickc@redhat.com>
+
+ * config/obj-elf.c: Include dwarf2dbg.h.
+ (elf_pseudo_tab): Add .file and .loc.
+ * config/tc-arc.c (md_pseudo_table): Remove .file and .loc.
+ * config/tc-arm.c: Likewise.
+ * config/tc-h8300.c: Likewise.
+ * config/tc-hppa.c: Likewise.
+ * config/tc-ia64.c: Likewise.
+ * config/tc-m68hc11.c: Likewise.
+ * config/tc-m68k.c: Likewise.
+ * config/tc-mmix.c: Likewise.
+ * config/tc-mn10300.c: Likewise.
+ * config/tc-ppc.c: Likewise.
+ * config/tc-sh.c: Likewise.
+ * config/tc-sparc.c: Likewise.
+ * config/tc-v850.c: Likewise.
+ * config/tc-frv.c: Likewise, and remove redundant inclusion of
+ dwarf2dbg.h.
+ * config/tc-ip2k.c: Likewise.
+ * config/tc-iq2000.c: Likewise.
+ * config/tc-xstormy16.c: Likewise.
+ * config/tc-xtensa.c: Likewise.
+ * Makefile.am: Regenerate dependencies.
+ * Makefile.in: Regenerate.
+ * aclocal.m4: Regenerate.
+ * config.in: Regenerate.
+ * configure: Regenerate.
+ * po/POTFILES.in: Regenerate.
+ * po/gas.pot: Regenerate.
+
+2003-05-21 Nick Clifton <nickc@redhat.com>
+
+ * dw2gencfi.c (cfi_get_label): Use symbol_make for non
+ BFD_ASSEMBLER targets.
+ (cfi_startproc): Change type of saved_seg and cfi_seg to segT.
+ (dot_cfi_endproc): Only call bfd_set_section_flags for targets
+ defining BFD_ASSEMBLER.
+
+2003-05-20 Michal Ludvig <mludvig@suse.cz>
+
+ * as.c (main): Remove tc_cfi_init().
+ * dw2gencfi.c (cfi_parse_arg): Allow regnames beginning
+ with '%'.
+ (cfi_pseudo_table): Add "cfi_register" entry.
+ (cfi_make_insn): Handle CFA_register.
+ (cfi_output_insn): Ditto.
+ (dot_cfi): Ditto.
+ (cfi_get_label): Add 'simple' modifier to .cfi_startproc.
+ (dot_cfi_endproc): Reuse already emitted CIEs.
+ * testsuite/gas/cfi/cfi-i386.d: New pattern.
+ * testsuite/gas/cfi/cfi-x86-64.d: Ditto.
+
+2003-05-20 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-xstormy16.c: Include dwarf2dbg.h.
+ (md_pseudo_table): Add entries for .loc and .line.
+
+2003-05-20 Alan Modra <amodra@bigpond.net.au>
+
+ * dw2gencfi.c (cfi_parse_arg): Only use tc_regname_to_dw2regnum if
+ defined.
+ (dot_cfi_endproc): Avoid C99 construct.
+
+2003-05-20 Michal Ludvig <mludvig@suse.cz>
+
+ * dw2gencfi.c, dw2gencfi.h: New files.
+ * config/tc-i386.c (tc_x86_cfi_init): New function.
+ * config/tc-i386.h (TARGET_USE_CFIPOP, tc_cfi_init): New defines.
+ * as.c (parse_args): Set verbose flag on --verbose.
+ (main): Call tc_cfi_init()/cfi_finish().
+ * as.h (verbose): New external variable.
+ * read.c (pobegin): Insert CFI pops to the list.
+ * symbols.c (local_symbol_make): Make symbol external.
+ * symbols.h (local_symbol_make): New prototype.
+ * Makefile.am: Add dw2gencfi.[ch] files. Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * doc/as.texinfo: Added node "CFI directives" with description of
+ all implemented .cfi_* directives.
+ * doc/Makefile.in: Regenerate.
+ * po/POTFILES.in: Regenerate.
+
+2003-05-19 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * config/tc-tic4x.c (md_assemble): Added support for one-line parallel
+ insns.
+ * config/tc-tic4x.h: Added DOUBLEBAR_PARALLEL definition
+
+2003-05-18 Jason Eckhardt <jle@rice.edu>
+
+ * config/tc-i860.c (i860_process_insn): Initialize fc after
+ each opcode mismatch.
+
+2003-05-16 Kelley Cook <kelleycook@wideopenwest.com>
+
+ * configure.in: Accept i[3-7]86 variants.
+ * configure: Regenerate.
+
+2003-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.h: Fix comment formatting.
+
+2003-05-13 Hans-Peter Nilsson <hp@axis.com>
+
+ * read.c (old_buffer, old_input, old_limit): Remove variables.
+ (read_a_source_file): Delete label contin.
+ <handling #APP/#NO_APP>: Use an "sb" to push #APP expansion into
+ input as with macros, instead of in separate old_* variables.
+ Zero-terminate string being scrubbed.
+
+2003-05-12 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-xstormy16.c (skipping_fptr): New local variable.
+ (md_assemble): Reset skipping_fptr.
+ (md_operand): If @fptr() is followed by a minus sign, set
+ skipping_fptr and ignore the fptr. If skipping_fptr is set and an
+ @fptr is detected, ignore it and reset skipping_fptr.
+
+2003-05-11 Jason Eckhardt <jle@rice.edu>
+
+ * config/tc-i860.c (MAX_FIXUPS): Define.
+ (struct i860_fi fi[]): New struct.
+ (struct i860_it the_insn): Add above as member and move fields
+ exp, reloc, pcrel and fup into i860_fi.
+ (md_assemble): Replace all instances of exp, reloc, pcrel
+ and fup with fi[].exp, fi[].reloc, fi[].pcrel, fi[].fup.
+ Add a loop to possibly emit multiple fix-ups for each insn.
+ (i860_process_insn): Likewise.
+ (i860_get_expression): Likewise.
+ (md_apply_fix3): Use a bitwise check for OP_IMM_U5, not equality.
+
+2003-05-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * config/tc-s390.c (s390_target_format): Always call init_default_arch.
+
+2003-05-07 H.J. Lu <hongjiu.lu@intel.com>
+
+ * config/tc-ia64.c (alias_hash): New.
+ (alias_name_hash): New.
+ (secalias_hash): New.
+ (secalias_name_hash): New.
+ (md_pseudo_table): Add "secalias".
+ (md_begin): Initialize alias_hash, alias_name_hash,
+ secalias_hash and secalias_name_hash.
+ (struct alias): New.
+ (dot_alias): Implement .alias and .secalias directives.
+ (do_alias): New.
+ (ia64_adjust_symtab): New.
+ (do_secalias): New.
+ (ia64_frob_file): New.
+
+ * config/tc-ia64.h (ia64_adjust_symtab): New.
+ (tc_adjust_symtab): Defined.
+ (ia64_frob_file): New.
+ (tc_frob_file): Defined.
+
+2003-05-07 Dmitry Diky <diwil@mail.ru>
+
+ * tc-msp430.c: Add missing lines to known cpus list.
+
+2003-05-06 Alexandre Oliva <aoliva@redhat.com>
+
+ * configure.in (MIPS_DEFAULT_ABI): AC_DEFINE.
+ * config/tc-mips.c (mips_after_parse_args): Set mips_abi to it.
+ * config.in, configure: Rebuilt.
+
+2003-05-05 H.J. Lu <hjl@gnu.org>
+
+ * config/tc-mips.c (tc_gen_reloc): Add addend just once if
+ howto->partial_inplace is false.
+
+2003-05-05 Daniel Jacobowitz <drow@mvista.com>
+
+ * config/tc-mips.c (mips_need_elf_addend_fixup): Remove
+ symbol_used_in_reloc_p check.
+ (md_apply_fix3): Remove check for howto->pcrel_offset.
+
+2003-05-03 H.J. Lu <hjl@gnu.org>
+
+ * config/obj-elf.c (obj_elf_parse_section_letters): Make it a
+ fatal error for unknown section attribute.
+
+ * config/tc-alpha.c (alpha_elf_section_letter): Return -1 for
+ unknown section attribute.
+ * config/tc-ia64.c (ia64_elf_section_letter): Likewise.
+ * config/tc-ppc.c (ppc_section_letter): Likewise.
+
+ * config/tc-ia64.c (ia64_elf_section_letter): Handle 'o'.
+ (ia64_elf_section_type): Accept "unwind".
+
+2003-05-02 H.J. Lu <hjl@gnu.org>
+
+ * read.h (demand_copy_string): New.
+
+ * config/tc-alpha.c (demand_copy_string): Removed.
+
+2003-05-02 Michael Snyder <msnyder@redhat.com>
+
+ * write.h (FAKE_LABEL_NAME): Allow override
+ (for targets that like eg. a leading dot in a local label).
+
+2003-05-02 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-xstormy16.c (xstormy16_md_apply_fix3): Do not bias the
+ addend with the symbol's value for pc-relative relocations against
+ a defined symbol - this will be done automatically.
+
+2003-05-01 H.J. Lu <hjl@gnu.org>
+
+ * config/obj-elf.c (obj_elf_type): Accept "notype" and
+ "STT_NOTYPE".
+
+2003-05-01 H.J. Lu <hjl@gnu.org>
+
+ * config/tc-ia64.h (tc_canonicalize_section_name): New.
+
+ * config/obj-elf.c (obj_elf_section_name): Call
+ tc_canonicalize_section_name if it is defined.
+
+2003-05-01 H.J. Lu <hjl@gnu.org>
+
+ * config/tc-ia64.c (ia64_check_label): New.
+ * config/tc-ia64.h (tc_check_label): New.
+
+ * read.c (read_a_source_file): Call tc_check_label after
+ creating a user-defined label if defined.
+
+2003-05-02 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ppc.c (md_show_usage): Mention -a32, -a64, -l, -le, -b,
+ -be and split strings to below 509 bytes in length.
+
+2003-05-01 Christian Groessler <chris@groessler.org>
+
+ * expr.h: Fix comments in operatorT typedef.
+ * config/tc-z8k.c: Add 2003 to copyright message.
+ Fold s_segm() and s_unseg() into one function s_segm(parm) which
+ decides by the parameter.
+ (md_begin): Don't set linkrelax. Only set Z8002 default if no
+ command line argument was given to select the intended
+ architecure.
+ (get_interrupt_operand): Warn if NOP type code is emitted.
+ (newfix): New parameter 'size', forward it to 'fix_new_exp'.
+ (apply_fix): Call newfix with additional 'size' parameter.
+ (build_bytes): Remove unused variable 'nib'. Detect overflow in
+ 4 bit immediate arguments.
+ (md_longopts): Add 'linkrelax' option.
+ (md_parse_option): Adapt to new s_segm function. Set 'linkrelax'
+ variable when 'linkrelax' command line option is specified.
+ (md_show_usage): Display 'linkrelax' option.
+ (md_apply_fix3): Fix cases R_IMM4L, R_JR, and R_IMM8. Add cases
+ R_CALLR and R_REL16.
+ * config/tc-z8k.h: Undef WARN_SIGNED_OVERFLOW_WORD.
+
+2003-04-30 H.J. Lu <hjl@gnu.org>
+
+ * config/tc-ia64.c (ia64_number_to_chars): New function pointer.
+ (ia64_float_to_chars): Likewise.
+ (dot_byteorder): Set target_big_endian, ia64_number_to_chars
+ and ia64_float_to_chars by tc_segment_info_data.endian from
+ the current segment if byteorder == -1.
+ (md_begin): Call dot_byteorder to set target_big_endian.
+ (md_atof): Call ia64_float_to_chars to convert floating point.
+ (ia64_float_to_chars_bigendian): New function.
+ (ia64_float_to_chars_littleendian): Likewise.
+ (ia64_elf_section_change_hook): Likewise.
+
+ * config/tc-ia64.h (ia64_number_to_chars): New.
+ (md_number_to_chars): Changed to (*ia64_number_to_chars)
+ (ia64_elf_section_change_hook): New.
+ (md_elf_section_change_hook): Defined.
+ (ia64_segment_info_type): New struct.
+ (TC_SEGMENT_INFO_TYPE): Defined.
+
+2003-04-30 H.J. Lu <hjl@gnu.org>
+
+ * config/tc-ia64.c (md_section_align): Deleted.
+
+ * config/tc-ia64.h (SUB_SEGMENT_ALIGN): New.
+ (md_section_align): New.
+
+2003-04-30 H.J. Lu <hjl@gnu.org>
+
+ * config/tc-ia64.c (stmt_float_cons): Fix alignment for real10
+ and add real16.
+ (md_pseudo_table): Add "xreal16", "xreal16.ua", "real16" and
+ "real16.ua".
+ (md_atof): Add 6 byte padding of zero for real16.
+
+2003-04-29 Nick Clifton <nickc@redhat.com>
+
+ * config/obj-elf.c (obj_elf_symver): Skip whitespace before the
+ start of a version name.
+
+2003-04-28 Chris Demetriou <cgd@broadcom.com>
+
+ * configure.in (mips-*-*n*bsd*): Replace with...
+ (mips-*-netbsd*, mips-*-openbsd*): These.
+ * configure: Regenerate.
+
+2003-04-28 H.J. Lu <hjl@gnu.org>
+
+ * config/tc-hppa.c (hppa_symbol_chars): New.
+ * config/tc-hppa.h (tc_symbol_chars): Likewise.
+
+2003-04-26 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.h (TC_FORCE_RELOCATION_SUB_SAME): Define again.
+
+2003-04-25 Chris Demetriou <cgd@broadcom.com>
+
+ * NEWS: Belatedly mention support for MIPS32 Release 2.
+
+2003-04-24 Eric Christopher <echristo@redhat.com>
+
+ * config/tc-mips.c (nopic_need_relax): Revert previous
+ change.
+
+2003-04-24 Dhananjay Deshpande <dhananjayd@kpitcummins.com>
+
+ * config/tc-h8300.h (DWARF2_LINE_MIN_INSN_LENGTH): New
+ * config/tc-h8300.c (dwarf2dbg.h): Include
+ (md_pseudo_table): Handle .loc and .file
+ (md_assemble): Call dwarf2_emit_insn if BFD_ASSEMBLER.
+ * Makefile.am: Add dependency on dwarf2dbg.h for h8300 targets.
+ * Makefile.in: Regenerate.
+
+2003-04-24 Dhananjay Deshpande <dhananjayd@kpitcummins.com>
+
+ * config/tc-h8300.c (Nmode, h8300hnmode, h8300snmode): New.
+ (md_pseudo_table): Add h8300hn, h8300sn.
+ * config/tc-h8300.h (COFF_MAGIC): Handle h8300hn, h8300sn.
+ * doc/c-h8300.texi : Add documentation for new machine directives.
+
+2003-04-24 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-ppc.c (ppc_symbol_chars): Define.
+ * config/tc-ppc.h (tc_symbol_chars): Define.
+
+2003-04-23 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * config/tc-sh.c: Amend comment to refer to SuperH.
+ * config/tc-sh.h: Likewise.
+ (LISTING_HEADER): Amend to refer to SuperH.
+ * config/tc-sh64.c: Change comment to refer to SuperH.
+ * config/tc-sh64.h (LISTING_HEADER): Change to refer to SuperH.
+ * doc/as.texinfo [SH, GENERIC]: Amend / Change to refer to SuperH.
+ * doc/c-sh.texi: Amend to refer to SuperH.
+ Add SuperH architecture documentation references.
+ * doc/c-sh64.texi: Change to refer to SuperH.
+
+2003-04-23 H.J. Lu <hjl@gnu.org>
+
+ * app.c (do_scrub_chars): More checks for valid labels.
+
+2003-04-22 H.J. Lu <hjl@gnu.org>
+
+ * app.c (do_scrub_chars): Check for valid label.
+
+2003-04-22 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
+
+ * doc/as.texinfo: Replace references to Mitsubishi M32R with
+ references to Renesas M32R.
+ * doc/c-m32r.texi: Likewise.
+
+2003-04-21 Richard Henderson <rth@redhat.com>
+
+ * dwarf2dbg.c (get_filenum): Skip as-yet unassigned file numbers.
+ (out_file_list): Assign non-null filename after generating error.
+
+2003-04-18 Jakub Jelinek <jakub@redhat.com>
+
+ * ehopt.c (check_eh_frame): For aug_size == 0
+ in state_seeing_aug_size state skip the state_skipping_aug
+ state.
+
+2003-04-15 Rohit Kumar Srivastava <rohits@kpitcummins.com>
+
+ * doc/c-h8300.texi: Replace occurrances of 'Hitachi' with
+ 'Renesas'.
+ * doc/c-h8500.texi: Likewise.
+ * doc/c-sh.texi: Likewise.
+ * doc/c-sh64.texi: Likewise.
+ * doc/h8.texi: Likewise.
+ * config/tc-h8300.c: Likewise.
+ * config/tc-h8300.h: Likewise.
+ * config/tc-h8500.c: Likewise.
+ * config/tc-h8500.h: Likewise.
+ * config/tc-sh.c: Likewise.
+ * config/tc-sh.h: Likewise.
+ * config/tc-sh64.c: Likewise.
+ * config/tc-sh64.h: Likewise.
+
+2003-04-10 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-mips.h (tc_frag_data_type, TC_FRAG_TYPE): New.
+ * config/tc-mips.c: Use signed add for n32 address arithmetic.
+ (append_insn): When filling delay slots with instructions
+ that have fixups that tc_gen_reloc might consider modifyable
+ in variant frags, start a new frag.
+ (load_address): Generate GOT_DISP with of without offset
+ depending on whether symbol is local. For -xgot, use
+ GOT_PAGE/GOT_OFST or GOT_HI16/GOT_LO16.
+ (macro) <M_DLA_AB, M_LA_AB>: Likewise.
+ <M_JAL_A>: In NewABI, use CALL16 or GOT_DISP for small got,
+ CALL_HI16/CALL_LO16 or GOT_PAGE/GOT_OFST for big got.
+ <ld_st>: In NewABI with small got, always use
+ GOT_PAGE/GOT_OFST, with the latter in the load/store
+ instruction. With big got, use GOT_HI16/GOT_LO16 or
+ GOT_PAGE/GOT_OFST.
+ (tc_gen_reloc): Adjust variant frags with GOT_DISP in NewABI.
+ Add tc_frag_data.tc_fr_offset to addends. Decay CALL16,
+ GOT_OFST and GOT_DISP to GOT_DISP in NewABI.
+ (md_convert_frag): Use memmove for safe copying of overlapping
+ regions.
+
+2003-04-09 Stephane Carrez <stcarrez@nerim.fr>
+
+ * doc/c-m68hc11.texi (M68HC11-Opts): Document -m68hcs12, -mshort,
+ -mlong, -mshort-double and -mlong-double options; use table @code.
+ (M68HC11-Syntax): Update to document 68HC12 operands.
+ (M68HC11-Modifiers): New section for operand modifiers.
+ (M68HC11-Directives): New section for specific assembler directives.
+ (M68HC11-Branch): Fix Overfull hbox error.
+
+2003-04-09 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-mips.c (macro): Add comments explaining the rationale
+ for Chris' change.
+
+2003-04-09 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (macro): Put back `+ 0x8000' in test for 64-bit
+ constant address that Alexandre took out by accident. Reject
+ 64-bit addresses that are not sign extensions of 32 bits only if
+ we don't support 64-bit address constants.
+
+2003-04-09 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ppc.c (md_apply_fix3): Generate ADDR16 relocs.
+
+2003-04-08 Nick Clifton <nickc@redhat.com>
+
+ * as.c (perform_an_assembly_pass): If using cgen, call
+ gas_cgen_begin.
+ * cgen.c (gas_cgen_begin): New function. If
+ flag_signed_overflow_ok is set call cgen_set_signed_overflow_ok
+ otherwise call cgen_clear_signed_overflow_ok.
+ * cgen.h: Prototype gas_cgen_begin.
+
+2003-04-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * write.c (write_relocs): Remove unused variable.
+
+2003-04-06 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (HAVE_64BIT_ADDRESS_CONSTANTS): New.
+ (macro): Use new macro to decide whether to emit constant address
+ as 32 or 64 bits if addresses are 32-bit wide but registers are
+ 64-bit wide.
+
+2003-04-05 Stephane Carrez <stcarrez@nerim.fr>
+
+ * config/tc-m68hc11.c (M6811_OP_CALL_ADDR): New internal define.
+ (M6811_OP_PAGE_ADDR): New internal define.
+ (get_operand): New modifier %page and %addr to obtain page and
+ address part of a far-function.
+ (fixup8): Use BFD_RELOC_M68HC11_PAGE for a %page modifier; don't
+ complain on overflow for the BFD_RELOC_M68HC11_PAGE and truncation
+ relocs.
+ (fixup16): Use BFD_RELOC_M68HC11_LO16 for a %addr modifier.
+ (find_opcode): Add comment.
+ (md_estimate_size_before_relax): Force relocation of
+ STATE_UNDEXED_OFFSET types when the symbol is not absolute.
+ (tc_m68hc11_fix_adjustable): Check for BFD_RELOC_M68HC11_LO16
+ instead of BFD_RELOC_LO16; temporarily make the BFD_RELOC_32
+ on the symbol itself so that DWARF2 strings are merged correctly.
+
+2003-04-04 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * config/obj-coff.h (TARGET_FORMAT): Namespace cleanup, changed
+ default tic4x target format to 'coff2-tic4x'.
+ * config/tc-tic4x.c: Namespace cleanup. Replace s/c4x/tic4x/ and
+ s/c3x/tic3x/
+ * config/tc-tic4x.h: Ditto
+
+2003-04-03 Nick Clifton <nickc@redhat.com>
+
+ * NEWS: Mention support for Xtensa architecture.
+
+2003-04-02 Philip Blundell <philb@gnu.org>
+
+ * config/tc-arm.c (arm_force_relocation): Return 0 for OFFSET_IMM.
+
+2003-04-02 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (macro2): Adjust implementation of
+ M_ULH, M_ULHU, M_ULW, and M_ULD so that they work properly
+ in the case where the source and destination registers
+ are the same.
+
+2003-04-01 Bob Wilson <bob.wilson@acm.org>
+
+ * Makefile.am (CPU_TYPES): Add xtensa.
+ (TARGET_CPU_CFILES): Add config/tc-xtensa.c.
+ (TARGET_CPU_HFILES): Add config/tc-xtensa.h.
+ (xtensa-relax.o): New target.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * configure.in: Handle xtensa-*-*. Add xtensa-relax.o to
+ extra_objects for xtensa targets.
+ * configure: Regenerate.
+ * write.c (write_object_file): Add new md_post_relax_hook.
+ * config/tc-xtensa.c: New file.
+ * config/tc-xtensa.h: Likewise.
+ * config/xtensa-istack.h: Likewise.
+ * config/xtensa-relax.c: Likewise.
+ * config/xtensa-relax.h: Likewise.
+ * doc/Makefile.am (CPU_DOCS): Add c-xtensa.texi.
+ * doc/Makefile.in: Regenerate.
+ * doc/all.texi: Set new XTENSA variable.
+ * doc/as.texinfo: Set new Xtensa variable. Describe
+ Xtensa-specific options. Define line comment character for
+ Xtensa. Add Xtensa processors to list of ELF targets where
+ alignment is specified in bytes. Add new Xtensa-Dependent node.
+ Add acknowledgements for those contributing to the Xtensa port.
+ * doc/internals.texi: Describe new md_post_relax_hook.
+ * doc/c-xtensa.texi: New file.
+
+2003-04-01 Nick Clifton <nickc@redhat.com>
+ Richard Earnshaw <rearnsha@arm.com>
+
+ * config/tc-arm.c: Remove presence of (r) and (tm) symbols.
+ (ARM_ARCH_IWMMXT): Simplify.
+ (insns): Place iwmmx instructions in correct place in table.
+ (arm_add_note): New function: Add a note entry to a .note section.
+ (md_begin): Make the default architecture be unknown.
+ Suppress the creation of an arm note section.
+
+2003-03-26 Eric Christopher <echristo@redhat.com>
+
+ * config/tc-mips.c (nopic_need_relax): Check for S_IS_EXTERN.
+
+2003-03-25 Stan Cox <scox@redhat.com>
+ Nick Clifton <nickc@redhat.com>
+
+ Contribute support for Intel's iWMMXt chip - an ARM variant:
+
+ * config/tc-arm.c: (ARM_CEXT_IWMMXT, ARM_ARCH_IWMMXT, WR_PREFIX,
+ WC_PREFIX, REG_TYPE_IWMMXT): New constants.
+ (enum wreg_type, enum iwmmxt_insn_type): New types.
+ (wr_register, wc_register, wcg_register): New macros.
+ (iwmmxt_table): New variable.
+ (wreg_required_here, do_iwmmxt_byte_addr, do_iwmmxt_tandc,
+ do_iwmmxt_tbcst, do_iwmmxt_textrc, do_iwmmxt_textrm,
+ do_iwmmxt_tinsr, do_iwmmxt_tmcr, do_iwmmxt_tmcrr, do_iwmmxt_tmia,
+ do_iwmmxt_tmovmsk, do_iwmmxt_tmrc, do_iwmmxt_tmrrc,
+ do_iwmmxt_torc, do_iwmmxt_waligni, do_iwmmxt_wmov,
+ do_iwmmxt_word_addr, do_iwmmxt_wrwr, do_iwmmxt_wrwrwcg,
+ do_iwmmxt_wrwrwr, do_iwmmxt_wshufh, do_iwmmxt_wzero,
+ cp_byte_address_offset, cp_byte_address_required_here,
+ check_iwmmxt_insn): New functions.
+ (asm_opcode_insns): Add iWMMXt instructions.
+ (md_begin): Set the mach value for iWMMXt targets. Create a note
+ section to identify iwmmxt binaries.
+ (md_apply_fix3): Handle BFD_RELOC_ARM_CP_OFF_IMM_S2.
+ * doc/c-arm.texi: Document the support for the iWMMXt.
+ * NEWS: Mention new support.
+
+2003-03-24 Daniel Néri <dne@mayonnaise.net>
+
+ * doc/as.texinfo: Rename the all occurances of C54X to TIC54X.
+ * doc/all.texi: Likewise.
+ * doc/c-tic54x.texi: Likewise.
+
+2003-03-21 Andreas Schwab <schwab@suse.de>
+
+ * config/tc-ia64.c (generate_unwind_image): Fix type of unw_rec to
+ avoid aliasing issue.
+
+2003-03-21 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * config/tc-s390.c (s390_arch_size): Initialize to zero.
+ (current_arch_mask): Rename to current_mode_mask.
+ (current_arch_requested): Remove variable.
+ (current_cpu): New variable.
+ (init_default_arch): Set defaults values for s390_arch_size,
+ current_mode_mask and current_cpu.
+ (md_parse_option): New options -mesa, -mzarch and -march={g5,g6,z900}.
+ (md_begin): Replace current_arch_mask by current_cpu.
+ (md_assemble): Adapt check and error message to current_mode_mask and
+ current_cpu.
+
+2003-03-09 James E Wilson <wilson@tuliptree.org>
+
+ * macro.c (buffer_and_nest): Store more to sb instead of '\n'.
+ * read.c (get_line_sb): Return end of line character or '\n' if
+ it is zero or non-existent.
+
+2003-03-12 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-mips.c (mips_validate_fix): New function.
+ * config/tc-mips.h (TC_VALIDATE_FIX): Define.
+ (mips_validate_fix): Declare.
+
+2003-03-12 Alexandre Oliva <aoliva@redhat.com>
+
+ * Reverted 2003-03-02's patch.
+
+2003-03-11 Steve Ellcey <sje@cup.hp.com>
+
+ * dwarf2dbg.c (generic_dwarf2_emit_offset): New.
+ (TC_DWARF2_EMIT_OFFSET): Provide default.
+ (out_debug_aranges, out_debug_info): Use it.
+ * config/tc-ia64.c (ia64_dwarf2_emit_offset): New.
+ (ia64_cons_fix_new): Move FUNC_DTP_RELATIVE handling ...
+ (ia64_gen_real_reloc_type): ... here.
+ * config/tc-ia64.h (TC_DWARF2_EMIT_OFFSET): New.
+
+2003-03-09 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (s_mips_end): Remove !BFD_ASSEMBLER case.
+ (s_mips_ent): Likewise.
+
+2003-03-04 Dmitry Diky <diwil@mail.ru>
+
+ * config/tc-msp430.c (mcu_types): Add recently announced x1122
+ and x1123 devices, add missed x437.
+ (md_show_usage): Sort device list.
+
+2003-03-03 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * config/tc-sh.c (sh_dsp): Replace with preset_target_arch.
+ (md_begin): Use preset_target_arch.
+ (md_longopts): Make isa option unconditional.
+ (md_parse_option): Make OPTION_DSP and OPTION_ISA sh4 / any
+ set preset_target_arch.
+ (md_apply_fix3): If BFD_ASSEMBLER, adjust SWITCH_TABLE fixups
+ by -S_GET_VALUE (fixP->fx_subsy).
+ (tc_gen_reloc): For SWITCH_TABLE fixups, the symbol is fixp->fx_subsy,
+ and the addend is 0.
+ Adjust addend of R_SH_IND12W relocations by fixp->fx_offset - 4.
+ * config/tc-sh.h (TC_FORCE_RELOCATION_SUB_LOCAL): Define.
+
+2003-03-02 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (append_insn): Add handling of
+ BFD_RELOC_MIPSEMB_16_PCREL_S2. Avoid emitting unneeded
+ BFD_RELOC_16_PCREL_S2 relocs and add earlier warnings about
+ misaligned address and reange overflow.
+ (macro_build): Add handling of BFD_RELOC_MIPSEMB_16_PCREL_S2. Add
+ earlier warnings about misaligned address and reange overflow.
+ (mips_ip): Add handling of BFD_RELOC_MIPSEMB_16_PCREL_S2.
+ (md_apply_fix): Likewise. Fix warning output.
+ (tc_gen_reloc): Add handling of BFD_RELOC_MIPSEMB_16_PCREL_S2.
+ Allow BFD_RELOC_16_PCREL_S2 for all ABIs.
+ (md_convert_frag): Add handling of BFD_RELOC_MIPSEMB_16_PCREL_S2.
+
+2003-02-21 Nick Clifton <nickc@redhat.com>
+
+ * NEWS: Mention availability of test generator program.
+
+2003-02-21 Miles Bader <miles@gnu.org>
+
+ * config/tc-v850.c (system_registers): Add v850e debug registers.
+ (system_register_name): Accept up to 27 (the last v850e sys register).
+
+2003-02-21 Bob Wilson <bob.wilson@acm.org>
+
+ * doc/as.texinfo: Define new COFF-ELF variable to conditionalize text
+ relevant to both COFF and ELF. Fix obvious typos and texinfo bugs.
+ Capitalize section headings consistently. Format index entries more
+ consistently. Unconditionalize text about whether text and data
+ sections are alterable. Use @ifnottex for alternatives to @tex output
+ so that HTML works. Clean up COFF vs. ELF descriptions of .section,
+ .size and .type directives. Be more polite about bad bug reports.
+ Move FDL into a separate file.
+ * doc/fdl.texi: New file.
+
+2003-02-21 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-mips.c (prev_reloc_op_frag): New variable.
+ (macro): Check it to decide whether a new frag is needed.
+ (my_getSmallExpression): Set it.
+
+2003-02-20 jmc <jmc@prioris.mini.pw.edu.pl>
+
+ * cgen.c: Fix typo: intial -> initial.
+
+2003-02-19 Jie Zhang <zhangjie@magima.com.cn>
+
+ * app.c (do_scrub_chars): Handle '||' in two states.
+
+2003-02-13 Alan Modra <amodra@bigpond.net.au>
+
+ * write.c (TC_FORCE_RELOCATION_SUB_SAME): Revert last change.
+ * config/tc-s390.h (TC_FORCE_RELOCATION_SUB_SAME): Define.
+
+2003-02-11 Uwe Stieber <uwe@wwws.de>
+
+ * configure.in: Add support for kaOS as cross build target system.
+ * configure: Regenerated.
+
+2003-02-10 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-arm.c (md_begin): If the Maverick co-processor is
+ selected, set the EF_ARM_MAVERICK_FLOAT flag and
+ bfd_mach_arm_ep9312 machine number.
+
+2003-02-08 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-mips.c (reloc_needs_lo_p): New function.
+ (fixup_has_matching_lo_p): New function.
+ (append_insn): Use reloc_needs_lo_p to check whether a relocation
+ might need a matching %lo(). Reuse the head of mips_hi_fixup_list
+ if that fixup already has a matching %lo(). Don't call frag_wane here.
+ (macro): Call frag_wane here if the last unmatched hi was in the
+ current frag.
+ (pic_need_relax): New function, split out from...
+ (md_estimate_size_before_relax): ...here.
+ (mips_frob_file): Use reloc_needs_lo_p. Use pic_need_relax to test
+ whether BFD_RELOC_MIPS_GOT16 fixups refer to global symbols.
+
+2003-02-07 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-mips.c (my_getSmallExpression): Rework bracket handling.
+
+2003-02-06 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ppc.c (ppc_elf_suffix): Undo part of last change so that
+ x@toc+off works.
+
+2003-02-05 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ppc.c (mapping): Handle new TLS reloc specs.
+ (ppc_elf_suffix): Don't warn for x+off@got when ppc64 and don't
+ accept x@got+off etc.
+ (md_assemble): Handle TLS relocs.
+ (ppc_force_relocation): Force for all TLS relocs.
+ (ppc_fix_adjustable): Likewise.
+ (md_apply_fix3): Handle TLS relocs.
+
+2003-02-04 Alan Modra <amodra@bigpond.net.au>
+
+ * config/obj-elf.c (obj_elf_change_section): Set SEC_LINK_ONCE and
+ SEC_LINK_DUPLICATES_DISCARD directly rather than using elf_linkonce_p.
+
+2003-02-02 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-mips.c (enum small_ex_type): Remove.
+ (imm_unmatched_hi): Remove.
+ (md_assemble): Remove use of imm_unmatched_hi. Remove the last
+ argument from calls to append_insn.
+ (append_insn): Remove unmatched_hi parameter; check reloc_type[0]
+ instead.
+ (macro_build): Update append_insn calls.
+ (mips16_macro_build, macro_build_lui): Likewise.
+ (mips_ip): Rework handling of small expressions. Move explicit
+ relocation handling into my_getSmallExpression. Assume that the
+ value of 'o' operands is zero if there is only one bracketed
+ expression left.
+ (percent_op): Make constant. Record the BFD relocation code
+ associated with each operator.
+ (my_getSmallParser, my_getPercentOp): Remove.
+ (parse_relocation): New function.
+ (my_getSamllExpression): Rework. Fill in relocations here
+ rather than in mips_ip.
+
+2003-01-29 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-i386.c (line_comment_chars): Add '#'. This makes the
+ assembler's handling of # <linenum> "<filename>" directives work.
+
+2003-01-28 Jakub Jelinek <jakub@redhat.com>
+
+ * dwarf2dbg.c: Include filenames.h.
+ (struct file_entry): Make filename const char *.
+ (dirs, dirs_in_use, dirs_allocated): New variables.
+ (get_filenum): Add NUM argument. Build directory table.
+ (dwarf2_where): Adjust caller.
+ (dwarf2_directive_file): Use get_filenum to allocate
+ slot in file and directory tables.
+ (dwarf2_directive_loc): Recreate full filename from
+ directory and filename part if needed for listing.
+ (out_file_list): Output directory table.
+ Output main source file dirname before its filename.
+
+2003-01-28 Dmitry Diky <diwil@mail.ru>
+
+ * config/tc-msp430.c: Replace occurences of 'tolower' with
+ 'TOLOWER'.
+
+2003-01-27 David Mosberger <davidm@hpl.hp.com>
+
+ * config/tc-ia64.c (dot_vframesp): Correct error message.
+ (dot_vframepsp): Ditto.
+
+2003-01-27 Alexandre Oliva <aoliva@redhat.com>
+
+ * configure.in (em): Set to irix on all Irix systems.
+ * configure: Rebuilt.
+ * config/te-irix.h: New file.
+ * config/tc-mips.c (mips_dwarf2_format): Use TE_IRIX to decide
+ whether to use Irix-specific 64-bit format.
+
+2003-01-27 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * config/tc-s390.c (s390_elf_cons): Avoid designated initializers.
+
+2003-01-25 Jakub Jelinek <jakub@redhat.com>
+
+ * config/tc-sparc.c (sparc_ip): Handle TLS % operators.
+ (tc_gen_reloc): Handle TLS relocs.
+ (sparc_cons, cons_fix_new_sparc): Handle %r_tls_dtpoff.
+ * config/tc-sparc.h (tc_fix_adjustable): Don't adjust TLS
+ relocs.
+ * config/obj-elf.c (obj_elf_section_word): Handle tls.
+ (obj_elf_type): Handle tls_object.
+
+2003-01-24 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * config/tc-s390.c (s390_tls_suffix): New function.
+ (elf_suffix_type): Add suffix enums for TLS relocations.
+ (s390_elf_suffix): Add suffix strings for TLS relocations.
+ (s390_elf_cons): Map new lenght/elf suffix combinations for TLS to
+ bfd relocations.
+ (md_gather_operands): Map new instruction operand/elf suffix
+ combinations for TLS to bfd relocations.
+ (tc_s390_fix_adjustable): Add new TLS relocations.
+ (tc_s390_force_relocation): Likewise.
+ (md_apply_fix3): Likewise.
+
+2003-01-24 Alan Modra <amodra@bigpond.net.au>
+
+ * as.h: Update copyright date.
+ * symbols.c: Likewise.
+ * config/tc-d10v.h: Likewise.
+ * config/tc-fr30.h: Likewise.
+ * config/tc-i960.h: Likewise.
+ * config/tc-mips.h: Likewise.
+
+ * config/tc-hppa.h (DIFF_EXPR_OK): Define.
+ (MD_APPLY_SYM_VALUE): Move.
+
+2003-01-23 Nick Clifton <nickc@redhat.com>
+
+ * NEWS: Announce sh2e support.
+
+ Add sh2e support:
+ 2002-04-02 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-sh.c (md_show_usage): Added sh2e next to sh3e.
+ (sh_elf_final_processing): Handle arch_sh2e.
+
+2003-01-23 Alan Modra <amodra@bigpond.net.au>
+
+ * symbols.c (S_FORCE_RELOC): Add "strict" param.
+ * symbols.h (S_FORCE_RELOC): Likewise.
+ * config/obj-aout.h (S_FORCE_RELOC): Likewise.
+ * config/obj-bout.h (S_FORCE_RELOC): Likewise.
+ * config/obj-coff.h (S_FORCE_RELOC): Likewise.
+ * config/obj-ieee.h (S_FORCE_RELOC): Likewise.
+ * config/obj-vms.h (S_FORCE_RELOC): Likewise.
+ * write.c (generic_force_reloc): New function.
+ (TC_FORCE_RELOCATION): Use it here instead of S_FORCE_RELOC.
+ (TC_FORCE_RELOCATION_SUB_SAME): Test TC_FORCE_RELOCATION too.
+ (adjust_reloc_syms): Adjust S_FORCE_RELOC call.
+ * as.h (generic_force_reloc): Declare.
+ * doc/internals.texi (S_FORCE_RELOC): Update.
+ (TC_FORCE_RELOCATION_SUB_SAME): Update.
+
+ * config/tc-alpha.c (alpha_force_relocation): Adjust to use
+ generic_force_reloc.
+ (alpha_fix_adjustable): Likewise.
+ * config/tc-arm.c (arm_force_relocation): Likewise.
+ * config/tc-cris.c (md_cris_force_relocation): Likewise.
+ * config/tc-frv.c (frv_force_relocation): Likewise.
+ * config/tc-i386.c (md_apply_fix3): Likewise.
+ * config/tc-ia64.c (ia64_force_relocation): Likewise.
+ * config/tc-ip2k.c (ip2k_force_relocation): Likewise.
+ * config/tc-m32r.c (m32r_force_relocation): Likewise.
+ * config/tc-m68hc11.c (tc_m68hc11_force_relocation): Likewise.
+ * config/tc-mcore.c (mcore_force_relocation): Likewise.
+ * config/tc-mips.c (mips_force_relocation): Likewise.
+ * config/tc-mmix.c (mmix_force_relocation): Likewise.
+ * config/tc-ppc.c (ppc_force_relocation): Likewise.
+ * config/tc-s390.c (tc_s390_force_relocation): Likewise.
+ * config/tc-sh.c (sh_force_relocation): Likewise.
+ (md_pcrel_from_section): Likewise.
+ * config/tc-sparc.c (tc_gen_reloc): Likewise.
+ * config/tc-v850.c (v850_force_relocation): Likewise.
+ * config/tc-xstormy16.c (xstormy16_force_relocation): Likewise.
+ * config/tc-i386.h (TC_FORCE_RELOCATION): Likewise.
+ * config/tc-mcore.h (TC_FORCE_RELOCATION): Likewise.
+ * config/tc-sparc.h (tc_fix_adjustable): Likewise.
+
+ * config/tc-d10v.c (d10v_force_relocation): Delete.
+ * config/tc-d10v.h (TC_FORCE_RELOCATION): Don't define.
+ * config/tc-dlx.c (md_dlx_force_relocation): Delete.
+ * config/tc-dlx.h (TC_FORCE_RELOCATION): Don't define.
+ * config/tc-fr30.c (fr30_force_relocation): Delete.
+ * config/tc-fr30.h (TC_FORCE_RELOCATION): Don't define.
+ * config/tc-mn10300.c (mn10300_force_relocation): Delete.
+ * config/tc-mn10300.h (TC_FORCE_RELOCATION): Don't define.
+ (TC_FORCE_RELOCATION_SUB_SAME): Test TC_FORCE_RELOCATION too.
+ * config/tc-i960.h (TC_FORCE_RELOCATION_SUB_SAME): Likewise.
+ * config/tc-hppa.c (hppa_force_relocation): Adjust S_FORCE_RELOC call.
+ * config/tc-mips.c (RELAX_BRANCH_TOOFAR): Warning fix.
+ * config/tc-mips.h (TC_FORCE_RELOCATION_SUB_SAME): Don't define.
+ * config/tc-openrisc.c (openrisc_force_relocation): Delete.
+ * config/tc-openrisc.h (TC_FORCE_RELOCATION): Don't define.
+ * config/tc-sparc.c (elf32_sparc_force_relocation): Delete.
+ * config/tc-sparc.h (TC_FORCE_RELOCATION): Don't define for ELF.
+ * config/tc-i386.c (i386_force_relocation): Delete.
+ * config/tc-i386.h (TC_FORCE_RELOCATION): Don't define for
+ BFD_ASSEMBLER.
+ (EXTERN_FORCE_RELOC): Fix TE_PE and STRICT_PE_FORMAT nesting.
+ * config/tc-m68k.h (TC_FORCE_RELOCATION): Don't define.
+ * config/tc-pj.h (TC_FORCE_RELOCATION): Don't define.
+ * config/tc-sh.h (TC_FORCE_RELOCATION_SUB_ABS): Don't call
+ S_FORCE_RELOC.
+ (TC_FORCE_RELOCATION_SUB_SAME): Test TC_FORCE_RELOCATION too.
+ * config/tc-sh64.h (TC_FORCE_RELOCATION_SUB_SAME): Likewise.
+
+2003-01-23 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-sh64.c (shmedia_frob_section_type): Adjust for changed
+ sh64_elf_section_data.
+ * config/tc-sh64.h: Include elf32-sh64.h.
+ * config/tc-m68hc11.c: Don't include stdio.h.
+ (md_show_usage): Fix missing continuation.
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2003-01-22 Nick Clifton <nickc@redhat.com>
+
+ * as.h: Include fopen-bin.h not fopen-same.h for mingw32 hosts.
+
+2003-01-21 Fabio Alemagna <falemagn@aros.org>
+
+ * configure.in: Handle *-*-aros*.
+ * configure: Regenerated from configure.in.
+
+2003-01-20 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * config/tc-s390.c (elf_suffix_type): Add suffix enums for gotoff,
+ gotplt and pltoff relocations.
+ (s390_elf_suffix): Add suffix strings for gotoff, gotplt and pltoff.
+ (s390_elf_cons): Map new lenght/elf suffix combinations for gotoff,
+ gotplt and pltoff to bfd relocations.
+ (md_gather_operands): Map new instruction operand/elf suffix
+ combinations to bfd relocations.
+ (tc_s390_fix_adjustable): Add new gotoff, gotplt and pltoff relocations
+ to the list of unadjustable relocations.
+ (tc_s390_force_relocation): Always emit relocations for gotoff, gotplt
+ and pltoff relocations.
+ (md_apply_fix3): Add the new relocations.
+
+2003-01-20 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * config/tc-s390.c (md_apply_fix3): Emit error message for relocations
+ with a subsy symbol.
+
+2003-01-17 Stephane Carrez <stcarrez@nerim.fr>
+
+ * config/tc-m68hc11.c (tc_m68hc11_fix_adjustable): Prevent adjustment
+ of relocs for memory bank addressing.
+
+2003-01-17 Stephane Carrez <stcarrez@nerim.fr>
+
+ * config/tc-m68hc11.c (md_show_usage): Update usage.
+ (md_parse_option): Recognize -m68hcs12.
+ (m68hc11_elf_final_processing): Set EF_M68HCS12_MACH flag to identify
+ HCS12.
+ * doc/as.texinfo (Overview): Document new option -m68hcs12.
+
+2003-01-16 Jakub Jelinek <jakub@redhat.com>
+
+ * config/tc-ia64.c (ia64_cons_fix_new): Handle @dtprel() in data.
+
+2003-01-16 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * po/POTFILES.in: Regenerate.
+
+2003-01-11 Alan Modra <amodra@bigpond.net.au>
+
+ * read.c (get_absolute_expr): New, split out from..
+ (get_absolute_expression): ..here.
+ * read.h (get_absolute_expr): Declare.
+ * config/obj-elf.c (elf_common): Use offsetT for "temp" and "size".
+ Trim size to arch bits_per_address, and test for negative input
+ via get_absolute_expr.
+
+2003-01-07 DJ Delorie <dj@redhat.com>
+
+ * config/tc-xstormy16.c (md_cgen_lookup_reloc): Adjust value based
+ on operand type.
+ (xstormy16_md_apply_fix3): Use adjustment.
+
+2003-01-02 Ben Elliston <bje@redhat.com>
+
+ * configure.in: Add iq2000-elf target.
+ * configure: Regenerate.
+ * config/tc-iq2000.c: New file.
+ * config/tc-iq2000.h: Likewise.
+ * po/gas.pot: Regenerate.
+
+2003-01-02 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c: Update copyright years to include 2003.
+ (mips_ip): Fix indentation of "+A", "+B", and "+C" handling.
+ Additionally, clean up their code slightly and clean up their
+ comments some more.
+
+ * doc/c-mips.texi: Add MIPS32r2 to ".set mipsN" documentation.
+
+2003-01-01 Daniel Jacobowitz <drow@mvista.com>
+
+ * doc/Makefile.am (as.1): Depend on "asconfig.texi gasver.texi
+ $(CPU_DOCS)".
+ * doc/Makefile.in: Regenerate.
+
+2003-01-01 John David Anglin <dave.anglin@nrc.ca>
+
+ * config/obj-elf.c (special_sections): Work around HP's incorrect usage
+ of .init and .fini sections for array initializers and finalizers.
+
+2002-12-31 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (validate_mips_insn, mips_ip): Recognize
+ the "+D" operand, which will be used only by the disassembler.
+
+2002-12-30 Chris Demetriou <cgd@broadcom.com>
+
+ * configure.in: Recognize mipsisa32r2, mipsisa32r2el, and
+ CPU variants.
+ * configure: Regenerate.
+ * config/tc-mips.c (ISA_HAS_DROR, ISA_HAS_ROR): New defines.
+ (macro_build): Handle "K" operand.
+ (macro2): Use ISA_HAS_DROR and ISA_HAS_ROR in the places where
+ CPU_HAS_DROR and CPU_HAS_ROR are currently used.
+ (mips_ip): New variable "lastpos", and implement "+A", "+B",
+ and "+C" operands for MIPS32 Release 2 ins/ext instructions.
+ Implement "K" operand for MIPS32 Release 2 rdhwr instruction.
+ (validate_mips_insn): Implement "+" as a way to extend the
+ allowed operands, and implement "K", "+A", "+B", and "+C"
+ operands.
+ (OPTION_MIPS32R2): New define.
+ (md_longopts): Add entry for OPTION_MIPS32R2.
+ (OPTION_ELF_BASE): Adjust to accommodate OPTIONS_MIPS32R2.
+ (md_parse_option): Handle OPTION_MIPS32R2.
+ (s_mipsset): Reimplement handling of ".set mipsN" options
+ and add support for ".set mips32r2".
+ (mips_cpu_info_table): Add entry for "mips32r2" (MIPS32 Release 2).
+ (md_show_usage): Document "-mips32r2" option.
+ * doc/as.texinfo: Document "-mips32r2" option.
+ * doc/c-mips.texi: Likewise.
+
+2002-12-30 Dmitry Diky <diwil@mail.ru>
+
+ * configure.in: Add msp430 target.
+ * configure: Regenerate.
+ * Makefile.am: Add msp430 target.
+ * Makefile.in: Regenerate.
+ * config/tc-msp430.c: New file: msp430 assembler.
+ * config/tc-msp430.h: New file: target macros for msp430.
+ * doc/Makefile.am: Add msp430 target.
+ * doc/Makefile.in: Regenerate.
+ * doc/as.texinfo: Include msp430 documenation.
+ * doc/all.texi: Enable msp430 documentation.
+ * doc/c-msp430.texi: New file: document msp430 specific features
+ of the assembler.
+
+2002-12-25 Alexandre Oliva <aoliva@redhat.com>
+
+ * dwarf2dbg.c (DWARF2_ADDR_SIZE): New macro.
+ (dwarf2_finish): Use it.
+ * doc/internals.texi (DWARF2_ADDR_SIZE): Document it.
+ * config/tc-mips.h (DWARF2_ADDR_SIZE): Override.
+
+2002-12-20 DJ Delorie <dj@redhat.com>
+
+ * config/tc-xstormy16.c (md_cgen_lookup_reloc): Support
+ BFD_RELOC_XSTORMY16_12.
+
+2002-12-19 Alan Modra <amodra@bigpond.net.au>
+
+ * doc/as.texinfo (Invoking): Typo fix.
+ * config/tc-tic54x.c (encode_operand): Comment typo fix.
+
+2002-12-18 Kazu Hirata <kazu@cs.umass.edu>
+
+ * doc/c-alpha.texi: Fix typos.
+ * doc/c-arm.texi: Likewise.
+ * doc/c-d10v.texi: Likewise.
+ * doc/c-i370.texi: Likewise.
+ * doc/c-i960.texi: Likewise.
+ * doc/c-ia64.texi: Likewise.
+ * doc/c-mmix.texi: Likewise.
+ * doc/c-ns32k.texi: Likewise.
+ * doc/c-pdp11.texi: Likewise.
+ * doc/c-pj.texi: Likewise.
+ * doc/c-sh64.texi: Likewise.
+ * doc/c-sparc.texi: Likewise.
+ * doc/c-tic54x.texi: Likewise.
+ * doc/c-v850.texi: Likewise.
+ * doc/c-vax.texi: Likewise.
+ * doc/internals.texi: Likewise.
+
+2002-12-18 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (macro): In M_DROL, M_DROR, M_ROL, and M_ROR,
+ use hardware rotate ops as appropriate. In M_DROL_I, M_DROR_I,
+ M_ROL_I, and M_ROR_I, simplify code, clean up warnings, and
+ arrange not to issue warnings about use of AT when AT is not
+ actually used.
+
+2002-12-17 Nick Clifton <nickc@redhat.com>
+
+ * as.c (std_longopts): Duplicate --keep-locals entry in order to
+ prevent it being confused with -k.
+
+2002-12-16 Andrew MacLeod <amacleod@redhat.com>
+
+ * config/tc-xstormy16.c (md_cgen_lookup_reloc): If a relocation
+ has already been set up, use it.
+
+2002-12-16 Kazu Hirata <kazu@cs.umass.edu>
+
+ * ChangeLog-9295: Fix a typo.
+ * README: Likewise.
+ * config/tc-d10v.c: Fix a comment typo.
+ * config/tc-dlx.c: Likewise.
+ * config/tc-h8300.h: Likewise.
+ * config/tc-h8500.h: Likewise.
+ * config/tc-mips.c: Likewise.
+ * config/tc-s390.c: Likewise.
+ * config/tc-sh.h: Likewise.
+ * config/tc-tic80.h: Likewise.
+ * config/tc-w65.h: Likewise.
+ * config/tc-z8k.c: Likewise.
+ * config/tc-z8k.h: Likewise.
+ * testsuite/gas/h8300/cmpsi2.s: Likewise.
+
+2002-12-16 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-d30v.c (check_range): Warning fixes, formatting.
+ Simplify sign extension. Remove redundant unsigned < 0 test.
+ * config/tc-i960.c (md_ri_to_chars): Prototype.
+ * config/tc-mcore.c (md_pseudo_table): Fix typo.
+ (dump_literals): Init brarsym, and test later instead of isforce.
+
+ * config/tc-ns32k.c (encode_operand): Constify operandsP and suffixP.
+ (parse): Constify line and lineptr.
+ (md_begin): Calculate endop here.
+
+2002-12-13 Alan Modra <amodra@bigpond.net.au>
+
+ * config/obj-vms.c: Formatting. Include fnctl.h.
+ (Create_VMS_Object_File): Fix creat call for sane unix systems.
+ (Object_Record_Offset): Make it a size_t.
+ (Flush_VMS_Object_Record_Buffer): Fix signed/unsigned warning.
+ (VMS_TBT_Routine_End <Size>): Make var unsigned long.
+ (VMS_Fix_Indirect_Reference <Offset>): Make arg addressT.
+ (synthesize_data_segment <data_size>): Remove ATTRIBUTE_UNUSED.
+ (vms_fixup_data_section <data_size>): Add here instead.
+ * config/e-criself.c: Fix typo in last change.
+
+2002-12-13 Alan Modra <amodra@bigpond.net.au>
+
+ * write.c (write_object_file): Fix signed/unsigned warning.
+ * config/e-crisaout.c (crisaout_bfd_name): Prototype.
+ * config/e-criself.c (criself_bfd_name): Prototype.
+ * config/obj-aout.c (s_sect): Remove unused function.
+ * config/obj-bout.c (obj_bout_line <ignore>): Add ATTRIBUTE_UNUSED.
+ * config/obj-coff.c (coff_last_bf): Don't declare for OBJ_XCOFF.
+ (fixup_mdeps <h>): Add ATTRIBUTE_UNUSED.
+ * config/obj-ecoff.c (ecoff_frob_file <addr>): Likewise.
+ * config/obj-vms.c (setup_basic_type <spnt>): Likewise.
+ (VMS_RSYM_Parse <Current_Routine>): Likewise.
+ (vms_fixup_text_section <text_siz>): Likewise.
+ (synthesize_data_segment <data_size>): Likewise.
+ (vms_fixup_xtors_section <sect_no>): Likewise.
+ (structure_count): Don't use implicit int type.
+ * config/tc-a29k.c (insert_sreg): Prototype.
+ (define_some_regs): Prototype, make static.
+ (parse_operand): Likewise.
+ (md_parse_option <c,arg>): Add ATTRIBUTE_UNUSED.
+ (md_show_usage <stream>): Likewise.
+ (md_section_align <segment>): Likewise.
+ (md_convert_frag <all args>): Likewise.
+ (md_estimate_size_before_relax <all args>): Likewise.
+ (md_apply_fix3): Don't cast valP pointer type. Fix bogus >>='s.
+ * config/tc-arm.c (arm_validate_fix): Only for OBJ_COFF or OBJ_ELF.
+ * config/tc-d30v.c (md_parse_option <arg>): Add ATTRIBUTE_UNUSED.
+ (md_undefined_symbol <name>): Likewise.
+ (md_convert_frag <all args>): Likewise.
+ (write_long <opcode>): Likewise.
+ (tc_gen_reloc <seg>): Likewise.
+ (md_estimate_size_before_relax <all args>): Likewise.
+ (md_apply_fix3 <seg>): Likewise.
+ (s_d30v_align <ignore>): Likewise.
+ (build_insn): Correct format string.
+ (md_apply_fix3): Likewise.
+ * config/tc-fr30.c (md_parse_option <c,arg>): Add ATTRIBUTE_UNUSED.
+ (md_undefined_symbol <name>): Likewise.
+ (md_convert_frag <all args>): Likewise.
+ (md_cgen_lookup_reloc <insn>): Likewise.
+ (md_begin): Delete unused vars.
+ (md_assemble): Likewise.
+ (md_estimate_size_before_relax): Likewise.
+ (fr30_relax_frag): #if 0 out, seems unused.
+ (md_atof): Remove declaration of atof_ieee.
+ (restore_colon): Prototype.
+ * config/tc-frv.c (frv_insert_vliw_insn): Prototype.
+ (frv_find_in_vliw): Likewise.
+ (frv_debug_tomcat): Likewise.
+ (frv_adjust_vliw_count): Likewise.
+ (frv_tomcat_shuffle): Likewise.
+ (frv_tomcat_analyze_vliw_chains): Likewise. Correct args to
+ frv_find_in_vliw call.
+ (md_atof): Remove declaration of atof_ieee.
+ * config/tc-h8500.c (cons): Delete declaration.
+ (md_begin <opcode>): Constify.
+ (displacement_size, immediate_size, absolute_size): Remove.
+ (build_relaxable_instruction <operand>): Add ATTRIBUTE_UNUSED.
+ (tc_crawl_symbol_chain <headers>): Likewise.
+ (md_undefined_symbol <name>): Likewise.
+ (tc_headers_hook <headers>): Likewise.
+ (md_parse_option <c,arg>): Likewise.
+ (md_show_usage <stream>): Likewise.
+ (md_convert_frag <headers, seg>): Likewise.
+ (tc_coff_symbol_emit_hook <ignore>): Likewise.
+ (md_atof): Remove declaration of atof_ieee.
+ (tc_aout_fix_to_chars): Remove unused function.
+ (parse_reg): Prototype.
+ (parse_exp): Prototype.
+ (skip_colonthing): Prototype. Use &&, not & in logical expressions.
+ (parse_reglist): Prototype.
+ (get_operand): Prototype.
+ (get_operands): Prototype.
+ (get_specific): Prototype. Make "this_index" signed.
+ (check): Prototype, make static.
+ (insert): Prototype
+ (build_relaxable_instruction): Prototype, make static.
+ (build_bytes): Prototype.
+ (wordify_scb): Prototype.
+ * config/tc-h8500.h (start_label): Declare.
+ (tc_coff_sizemachdep): Declare.
+ * config/tc-i370.c (i370_ebcdic <unused>): Add ATTRIBUTE_UNUSED.
+ (i370_rmode <unused>): Likewise.
+ (i370_csect <unused>): Likewise.
+ (i370_dc <unused>): Likewise.
+ (i370_ds <unused>): Likewise.
+ (i370_elf_lcomm <unused>): Likewise.
+ (i370_ltorg <ignore>): Likewise.
+ (i370_using <ignore>): Likewise.
+ (i370_drop <ignore>): Likewise.
+ (i370_byte <ignore>): Likewise.
+ (i370_tc <ignore>): Likewise.
+ (md_estimate_size_before_relax <fragp, seg>): Likewise.
+ (md_convert_frag <all args>): Likewise.
+ (md_undefined_symbol <name>): Likewise.
+ (md_pcrel_from_section <sec>): Likewise.
+ (tc_gen_reloc <seg>): Likewise.
+ (i370_section_letter): #if 0 unused functions.
+ (i370_section_word, i370_section_type, i370_section_flags): Likewise.
+ (symbol_locate): Prototype.
+ * config/tc-i860.c (md_atof): Remove declaration of atof_ieee.
+ (md_number_to_disp, md_number_to_field): Remove.
+ (md_apply_fix3): Correct format string and cast "fup".
+ * config/tc-i960.c (md_convert_frag): Add ATTRIBUTE_UNUSED to args.
+ (s_endian <ignore>): Likewise.
+ (md_undefined_symbol <name>): Likewise.
+ (tc_crawl_symbol_chain <headers>): Likewise.
+ (tc_set_bal_of_call): Likewise.
+ (tc_coff_symbol_emit_hook <symbolP>): Likewise.
+ (i960_handle_align <fragp>): Likewise.
+ (i960_validate_fix <this_segment_type>): Likewise
+ (tc_gen_reloc <section>): Likewise.
+ (tc_coff_symbol_emit_hook): Only define for OBJ_COFF.
+ (struct memS, struct regop): Forward declare.
+ (brcnt_emit, brlab_next, cobr_fmt, ctrl_fmt, emit, get_args,
+ get_cdisp, get_ispec, get_regnum, i_scan, mem_fmt, mema_to_memb,
+ parse_expr, parse_ldconst, parse_memop, parse_po, parse_regop,
+ reg_fmt, relax_cobr, s_leafproc, s_sysproc, shift_ok, syntax,
+ targ_has_sfr, targ_has_iclass, tc_bfd_fix2rtype): Prototype.
+ (md_chars_to_number, md_number_to_imm): Make static, prototype.
+ (md_number_to_field): Likewise.
+ (md_number_to_disp): Remove unused function.
+ (md_atof): Remove declaration of atof_ieee.
+ (md_apply_fix3): Correct md_number_to_imm call.
+ * config/tc-ip2k.c (md_assemble): Warning fix.
+ * config/tc-m32r.c (md_parse_option <arg>): Add ATTRIBUTE_UNUSED.
+ (fill_insn <ignore>): Likewise.
+ (debug_sym <ignore>): Likewise.
+ (md_undefined_symbol <name>): Likewise.
+ (m32r_scomm <ignore>): Likewise.
+ (md_convert_frag <abfd>): Likewise.
+ (md_cgen_lookup_reloc <insn>): Likewise.
+ (m32r_record_hi16 <seg>): Likewise.
+ (md_estimate_size_before_relax): #if 0 old_fr_fix.
+ (allow_m32rx): Prototype.
+ (first_writes_to_seconds_operands): Prototype.
+ (writes_to_pc): Prototype.
+ (can_make_parallel): Prototype.
+ (make_parallel): Prototype.
+ (target_make_parallel): Prototype.
+ (assemble_two_insns): Prototype.
+ (m32r_record_hi16): Prototype.
+ (md_atof): Remove declaration of atof_ieee.
+ * config/tc-m32r.h (m32r_fix_adjustable): Declare.
+ (m32r_force_relocation): Prototype.
+ (m32r_elf_section_change_hook): Prototype.
+ * config/tc-m68k.c (tc_gen_reloc <section>): Add ATTRIBUTE_UNUSED.
+ (md_show_usage): Fix signed/unsigned warning.
+ * config/tc-m88k.c (get_reg): Make reg_prefix param unsigned.
+ (calcop): Ditto for reg_prefix var.
+ (hexval): Add cast to fix signed/unsigned warning.
+ (md_number_to_disp): Delete unused function.
+ (md_number_to_field): Likewise.
+ (float_cons, cons, s_globl, s_space, s_set, s_lcomm): Remove decl.
+ (match_name): Prototype.
+ (get_bf2): Prototype.
+ (get_bf_offset_expression): Prototype.
+ * config/tc-mcore.c (mcore_s_literals <ignore>): Add ATTRIBUTE_UNUSED.
+ (md_undefined_symbol <ignore>): Likewise.
+ (md_create_short_jump <all args>): Likewise.
+ (md_create_long_jump <all args>): Likewise.
+ (md_convert_frag <abfd, sec>): Likewise.
+ (md_apply_fix3 <segment>): Likewise.
+ (md_section_align <segment>): Likewise.
+ (md_pcrel_from_section <sec>): Likewise.
+ (tc_gen_reloc <section>): Likewise.
+ (reg_m, reg_n, immediate): Delete unused vars.
+ (dump_literals): Fix signed/unsigned warning.
+ (enter_literal): Likewise.
+ (parse_imm): Likewise. Also fix format string.
+ (parse_mem): Remove unused var.
+ (md_assemble <LS>): Abort on unexpected inst.
+ (md_atof): Remove declaration of atof_ieee.
+ (md_parse_option): Remove unused vars.
+ (md_apply_fix3): Fix format strings, cast args.
+ (tc_gen_reloc): Delete unused var.
+ * config/tc-mcore.h (tc_coff_sizemachdep): Declare.
+ * config/tc-mn10200.c (md_parse_option <c, arg>): Add ATTRIBUTE_UNUSED.
+ (md_undefined_symbol <name>): Likewise.
+ (md_convert_frag <abfd>): Likewise.
+ (tc_gen_reloc <seg>): Likewise.
+ (check_operand <insn>): Likewise.
+ (md_convert_frag): Fix format strings.
+ (tc_gen_reloc): Delete fx_addsy - fx_subsy code.
+ * config/tc-openrisc.c (ignore_pseudo): Prototype.
+ (md_atof): Remove declaration of atof_ieee.
+ * config/tc-or32.c (parse_operand): Prototype non-BFD too.
+ (md_apply_fix3): Fix bogus >>='s.
+ (md_undefined_symbol): Delete unused var.
+ * config/tc-pj.c (little, big, parse_exp_save_ilp): Prototype.
+ (c_to_r, ipush_code, fake_opcode, alias): Likewise.
+ (fake_opcode): Adjust for pj_opc_int_t change.
+ (md_begin): Likewise.
+ (md_assemble): Likewise.
+ (ipush_code): Correct parse_exp_save_ilp call. Test pending_reloc
+ instead of non-existent third arg of parse_exp_save_ilp.
+ (md_parse_option): Correct "little" and "big" calls.
+ * config/tc-sparc.c (s_register): Only declare #ifdef OBJ_ELF.
+ (md_apply_fix3 <segment>): Add ATTRIBUTE_UNUSED.
+ (tc_gen_reloc <section>): Likewise.
+ * config/tc-tic30.c: #include stdarg.h or varargs.h.
+ (debug): Rewrite using VA_* macros.
+ (md_estimate_size_before_relax): Add ATTRIBUTE_UNUSED to args.
+ (md_convert_frag): Likewise.
+ (md_parse_option): Likewise.
+ (md_show_usage): Likewise.
+ (md_undefined_symbol): Likewise.
+ (tc_gen_reloc): Likewise.
+ (md_operand): Likewise.
+ (tc_aout_pre_write_hook): Delete.
+ (struct tic30_insn): Make "operands" unsigned.
+ (struct tic30_par_insn): Likewise.
+ (md_assemble): Likewise for "count", "i" and "numops".
+ (tic30_parallel_insn): Likewise for vars here.
+ (tic30_operand): Likewise. Remove useless unsigned >= 0 comparison.
+ * config/tc-tic30.h (tc_aout_pre_write_hook): Define as empty.
+ * config/tc-tic80.c (obj_coff_section): Delete declaration.
+ (md_estimate_size_before_relax): Add ATTRIBUTE_UNUSED on args.
+ (md_undefined_symbol): Likewise.
+ (md_parse_option): Likewise.
+ (md_convert_frag): Likewise.
+ (tc_coff_symbol_emit_hook): Likewise.
+ (md_atof): Remove declaration of atof_ieee.
+ (const_overflow): Warning fixes, tidy.
+ (get_operands): Delete unused vars.
+ (internal_error_a): Adjust format string to expect a long for arg.
+ (find_opcode): Warning fixes, simplify.
+ (build_insn): Cast internal_error_a arg.
+ (md_begin): Likewise.
+ (md_apply_fix3): Likewise.
+ (md_assemble): Delete unused var.
+ * config/tc-tic80.h (tc_coff_fix2rtype): Prototype.
+ * config/tc-z8k.c (cons, obj_coff_section): Delete declarations.
+ (whatreg, parse_reg, parse_exp): Make static, prototype.
+ (checkfor, regword, regaddr, get_ctrl_operand): Prototype.
+ (get_flags_operand, get_interrupt_operand, get_cc_operand): Likewise.
+ (get_operand, get_operands, get_specific, newfix): Likewise.
+ (apply_fix, build_bytes): Likewise.
+ (md_atof): Remove declaration of atof_ieee.
+ (tc_aout_fix_to_chars): Delete.
+ (md_begin): Constify "opcode". Don't try to init opcode->idx.
+ Fix s_unseg call.
+ (md_parse_option): Fix s_segm and s_unseg calls.
+
+2002-12-12 Alexandre Oliva <aoliva@redhat.com>
+
+ * tc-mips.c (RELAX_BRANCH_ENCODE): Remove reloc_s2 argument.
+ Adjust callers.
+ (RELAX_BRANCH_RELOC_S2): Delete.
+ (append_insn): Use only BFD_RELOC_16_PCREL_S2 for branches.
+ Do not handle BFD_RELOC_16_PCREL.
+ (macro_build, mips_ip): Likewise.
+ (md_pcrel_from): Return 4 for undefined symbols regardless of
+ mips_pic.
+ (md_apply_fix3): Use only BFD_RELOC_16_PCREL_S2 for branches.
+ Don't dereference howto if no such relocation is available.
+ Do not apply hack for in-place zero addend in NEWABI.
+ (md_convert_frag): Use only BFD_RELOC_16_PCREL_S2 for branches.
+
+2002-12-12 Alexandre Oliva <aoliva@redhat.com>,
+ Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-mn10300.h (TC_VALIDATE_FIX_SUB): Define.
+ (TC_LINKRELAX_FIXUP): Add comments.
+
+2002-12-12 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-mn10300.c (set_arch_mach): Change argument type to
+ avoid warnings.
+ (r_register_name, xr_register_name): Add prototype declarations.
+
+2002-12-08 H.J. Lu <hjl@gnu.org>
+
+ * config/tc-ia64.c (md_apply_fix3): Remove the PCREL hack
+ copied from tc-i386.c.
+
+2002-12-08 Stephane Carrez <stcarrez@nerim.fr>
+
+ Fix Bug savannah/1825:
+ * config/tc-m68hc11.c (STATE_INDEXED_PCREL): New relax code.
+ (md_relax_table): Define specific relax for PC-rel offsets.
+ (build_indexed_byte): Use a STATE_INDEXED_PCREL relax code.
+ (m68hc11_relax_frag): Handle the new relax code.
+ (md_convert_frag): Likewise.
+ (md_estimate_size_before_relax): Likewise.
+
+2002-12-08 Alan Modra <amodra@bigpond.net.au>
+
+ * subsegs.c (section_symbol): Use the symbol, not the section, name.
+
+2002-12-05 Richard Henderson <rth@redhat.com>
+
+ * config/ia64.c (enum reloc_func): Add FUNC_LT_RELATIVE_X.
+ (ia64_gen_real_reloc_type): Handle it.
+ (pseudo_func): Add @ltoffx.
+ (md_begin): Build .<ltoffx>.
+ (ia64_force_relocation): True for LTOFF22X and LDXMOV.
+
+2002-12-05 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-arm.c (arm_force_relocation): Move out of #if OBJ_ELF.
+ Move OBJ_COFF TC_FORCE_RELOCATION code here so that COFF handles
+ ARM_IMMEDIATE and ARM_ADRL_IMMEDIATE relocs as for ELF.
+ * config/tc-arm.h (TC_FORCE_RELOCATION): Define for both ELF and
+ COFF to call arm_force_relocation.
+
+2002-12-04 David Mosberger <davidm@hpl.hp.com>
+
+ * config/tc-ia64.c (pseudo_func): Add "@pause" constant for "hint"
+ instruction.
+ (emit_one_bundle): Handle "hint" instruction.
+ (operand_match): Match IA64_OPND_AR_CSD.
+
+2002-12-04 Alan Modra <amodra@bigpond.net.au>
+
+ * dwarf2dbg.c (scale_addr_delta): Correct parameter. Move prototype
+ inside #if.
+
+2002-12-03 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-ppc.c (ppc_cleanup): Do not set SEC_MERGE flag on
+ .PPC.EMB.apuinfo sections.
+
+2002-12-03 Richard Henderson <rth@redhat.com>
+
+ * config/tc-ia64.c (operand_match): Add IA64_OPND_LDXMOV case.
+
+2002-12-03 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-w65.c (s_longa): Prototype. Make static, specify int arg.
+ (cons, s_align_bytes): Delete declaration.
+ (relax): Delete.
+ (md_begin): Constify "struct opinfo *" var. Don't try to make "name"
+ strings common.
+ (dot): Delete unused function.
+ (w65_expression): Remove unused arg.
+ (parse_exp): Prototype. Remove unused arg. Adjust w65_expression
+ call.
+ (get_operands): Prototype. Constify "struct opinfo *" arg. Fix
+ parse_exp call.
+ (get_specific): Prototype. Constify "struct opinfo *" arg and return
+ value.
+ (check): Remove unused function.
+ (build_Mytes): Prototype. Constify "struct opinfo *" arg. Abort
+ on unhandled switch case.
+ (md_assemble): Remove unused op_start, op_end, nlen, p vars. Constify
+ "opcode".
+ (tc_crawl_symbol_chain): Delete unused function.
+ (tc_headers_hook): Likewise.
+ (tc_Nout_fix_to_chars): Likewise.
+ (md_undefined_symbol): Add ATTRIBUTE_UNUSED.
+ (md_parse_option): Likewise.
+ (md_convert_frag): Likewise.
+ (tc_coff_symbol_emit_hook): Likewise.
+ (md_show_usage): Likewise.
+ * config/tc-w65.h (tc_coff_sizemachdep): Declare.
+ (TC_PARSE_CONS_EXPRESSION): w65_expression takes one arg.
+ (w65_expression): Declare.
+
+ * po/POTFILES.in: Regenerate.
+
+ * config/tc-arm.c (arm_force_relocation): Return 0 for ARM_IMMEDIATE
+ and ARM_ADRL_IMMEDIATE.
+
+2002-12-02 Nick Clifton <nickc@redhat.com>
+
+ * gasp.c: Delete. It has been deprecated.
+ * NEWS: Mention that gasp has been removed.
+ * Makefile.am: Remove references to gasp.
+ * makefile.vms: Likewise.
+ * mpw-make.sed: Likewise.
+ * Makeile.in: Regenerate.
+ * doc/gasp.texi: Delete.
+ * doc/Makefile.am: Remove references to gasp.texi.
+ * doc/Makefile.in: Regenerate.
+ * macro.c: Delete references to gasp.
+ Remove use of comment_char function parameter as it is no longer
+ needed.
+ * macro.h: Update prototypes to remove comment_char parameter.
+ Fix formatting.
+ * read.c (read_a_source_file, s_irp): Remove comment_char
+ parameter from invocation of functions in macro.c
+
+2002-12-02 Hans-Peter Nilsson <hp@axis.com>
+
+ * read.c (emit_expr) [!WORKING_DOT_WORD]: Initialize x->use_jump.
+
+2002-12-01 Stephane Carrez <stcarrez@nerim.fr>
+
+ * config/tc-m68hc11.c (md_begin): Fix qsort warning.
+ (tc_gen_reloc): Mark section param as not used.
+
+2002-12-01 Stephane Carrez <stcarrez@nerim.fr>
+
+ Fix Bug savannah/1825:
+ * config/tc-m68hc11.h (md_relax_frag): Define to support relaxations
+ that are not pc-relative.
+ (m68hc11_relax_frag): Declare.
+
+ * config/tc-m68hc11.c (build_indexed_byte): Use a frag_var to handle
+ the offsetable indexed addressing modes (n,r).
+ (build_insn): Cleanup some locals.
+ (m68hc11_relax_frag): New function imported from tc-cris.c to handle
+ relaxation of difference between two symbols of same section.
+ (md_convert_frag): For INDEXED_OFFSET relaxs, use the displacement
+ only when this is a PC-relative operand and the offset is not absolute.
+ (md_estimate_size_before_relax): Convert the INDEXED_OFFSET,UNDEF frag
+ to INDEXED_OFFSET,STATE_BITS5 when the symbol is absolute; this will
+ be handled by m68hc11_relax_frag.
+
+2002-12-01 Stephane Carrez <stcarrez@nerim.fr>
+
+ * config/tc-m68hc11.c (elf_flags): Set default ABI to gcc default
+ (32-bit int, 64-bit double).
+ (md_longopts): New options -mshort, -mlong, -mshort-double and
+ -mlong-double to control the ABI.
+ (md_show_usage): Update.
+ (md_parse_option): Handle new options.
+ * doc/as.texinfo (Overview): Document new options for HC11/HC12.
+
+2002-12-01 Nathan Sidwell <nathan@codesourcery.com>
+
+ * symbols.c (report_op_error): New function, broken out of ...
+ (resolve_symbol_value): ... here. Use for both monadic and dyadic
+ operators.
+
+2002-11-30 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * config/tc-sh.c (md_apply_fix3): Take account of fx_offset
+ for BFD_RELOC_32_PLT_PCREL.
+
+2002-11-30 Alan Modra <amodra@bigpond.net.au>
+
+ * dwarf2dbg.c, write.c, config/obj-aout.c, config/obj-coff.c,
+ config/obj-ecoff.c, config/obj-elf.c, config/obj-som.c,
+ config/tc-arm.c, config/tc-arm.h, config/tc-avr.c, config/tc-cris.c,
+ config/tc-d10v.c, config/tc-d10v.h, config/tc-d30v.c, config/tc-d30v.h,
+ config/tc-dlx.c, config/tc-dlx.h, config/tc-fr30.c, config/tc-fr30.h,
+ config/tc-frv.c, config/tc-frv.h, config/tc-hppa.c, config/tc-i370.c,
+ config/tc-i386.c, config/tc-i386.h, config/tc-m32r.c,
+ config/tc-m68hc11.c, config/tc-mcore.c, config/tc-mcore.h,
+ config/tc-mips.c, config/tc-mips.h, config/tc-mn10200.c,
+ config/tc-mn10300.c, config/tc-mn10300.h, config/tc-openrisc.c,
+ config/tc-openrisc.h, config/tc-ppc.c, config/tc-s390.c,
+ config/tc-sh.c, config/tc-sh.h, config/tc-sh64.c, config/tc-tic54x.c,
+ config/tc-v850.c, config/tc-v850.h, config/tc-xstormy16.c,
+ config/tc-xstormy16.h: Replace boolean with bfd_boolean, true with
+ TRUE, false with FALSE. Simplify comparisons of bfd_boolean vars with
+ TRUE/FALSE. Formatting.
+
+2002-11-29 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-arm.c (do_t_bkpt): If no operand is specified,
+ assume a value of zero.
+ (do_bkpt): Likewise.
+
+2002-11-29 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * config/tc-sh.c (md_apply_fix3): Call S_SET_THREAD_LOCAL
+ for TLS relocations.
+
+2002-11-29 Jakub Jelinek <jakub@redhat.com>
+
+ * config/tc-ia64.c (md_apply_fix3): Add default case.
+
+2002-11-28 Jakub Jelinek <jakub@redhat.com>
+
+ * symbols.c (S_SET_THREAD_LOCAL): New function.
+ * symbols.h (S_SET_THREAD_LOCAL): New prototype.
+ * config/tc-i386.c (md_apply_fix3): Call S_SET_THREAD_LOCAL
+ for TLS relocations.
+ * config/tc-ia64.c (md_apply_fix3): Likewise.
+ * config/tc-alpha.c (md_apply_fix3): Likewise.
+
+2002-11-28 Jakub Jelinek <jakub@redhat.com>
+
+ * write.c (subsegs_finish): For SEC_MERGE sections pad last fragment
+ to entsize.
+
+2002-11-26 DJ Delorie <dj@redhat.com.
+
+ * dwarf2dbg.c (scale_addr_delta): New.
+ (size_inc_line_addr): Use it.
+ (emit_inc_line_addr): Use it.
+
+2002-11-26 Hans-Peter Nilsson <hp@axis.com>
+
+ * config/tc-cris.c (cris_relax_frag): Fix typo in comment.
+ (md_assemble): Don't pass on branches to constants as relaxable.
+ Tweak comment.
+
+2002-11-25 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * config/tc-tic4x.c (c4x_operands_match): Bugfix in direct mode
+
+2002-11-21 Randolph Chung <randolph@tausq.org>
+
+ * config/tc-hppa.h (tc_frob_symbol): Frob undefined unused symbols
+ only if they have default visibility.
+
+2002-11-21 Richard Henderson <rth@redhat.com>
+
+ * config/tc-alpha.c (alpha_fix_adjustable): Remove redundant
+ S_IS_DEFINED test.
+
+2002-11-21 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-mcore.c (mcore_pool_count): New function.
+ (mcore_cons, mcore_float_cons, mcore_stringer, mcore_fill): Use it.
+
+2002-11-20 Klee Dienes <kdienes@apple.com>
+
+ * config/tc-mcore.c (md_begin): Use a const iterator. Don't
+ coalesce the name fields to use the same pointer.
+
+ * config/tc-sh.c (md_begin): Use a const iterator. Don't coalesce
+ the name fields to use the same pointer.
+ (get_specific): Check for opcodes with the same name using strcmp
+ as well as comparing the pointer.
+
+2002-11-20 Alan Modra <amodra@bigpond.net.au>
+
+ * write.c (adjust_reloc_syms): Don't reduce SEC_MERGE fixups with
+ fx_subsy non-NULL.
+
+2002-11-19 Richard Henderson <rth@redhat.com>
+
+ * config/obj-elf.c (obj_elf_visibility): Overwrite only the
+ visibility portion of st_other.
+
+2002-11-19 Klee Dienes <kdienes@apple.com>
+
+ * config/tc-h8300.c (struct h8_instruction): New type, used to
+ wrap h8_opcodes with length, noperands, idx, and size fields
+ (computed at run-time).
+ (h8_instructions): New variable.
+ (md_begin): Allocate the storage for h8_instructions. Fill
+ h8_instructions with pointers to the appropriate opcode and the
+ correct value for the additional fields.
+ (clever_message): Update to use h8_instructions instead of
+ h8_opcodes.
+ (build_bytes): Ditto.
+ (get_specific): Ditto.
+ (md_assemble): Ditto.
+
+2002-11-19 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * config/tc-s390.c (tc_s390_fix_adjustable): Re-add patch to prevent
+ adjustments to symbols in merge sections.
+
+2002-11-19 Luke Deller <luked@cse.unsw.edu.au>
+
+ * config/tc-alpha.c (s_alpha_prologue): as_bad when sym is NULL.
+
+2002-11-18 Kevin Buettner <kevinb@redhat.com>
+
+ * dwarf2dbg.h (dwarf2_format): New enum.
+ * dwarf2dbg.c (DWARF2_FORMAT): Provide default definition.
+ (out_debug_line, out_debug_info): Add code for handling 64-bit
+ DWARF 2 formats.
+ * config/tc-mips.h (mips_dwarf2_format): Declare.
+ * config/tc-mips.c (mips_dwarf2_format): New function.
+ * doc/internals.texi (DWARF2_FORMAT): Document.
+
+2002-11-18 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-mips.c (s_change_section): Make sure input buffer
+ is not accessed past the end. Don't hand
+ obj_elf_change_section a pointer into the input buffer.
+
+2002-11-18 Alexandre Oliva <aoliva@redhat.com>, Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (tc_gen_reloc): Fix typo in handling of
+ GOT_LO16 on NEWABI.
+
+2002-11-18 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * config/tc-tic4x.c: Fixed proper commandline
+ parameters. Added support for new opcode-list format. General
+ error message fixups.
+ (c4x_inst_add): Reject insn not for our CPU
+ (md_begin): Added matrix for setting the proper opcode-level &
+ device-flags according to cpu type and revision. Rewrite the
+ opcode hasher.
+ (c4x_operand_parse): Fix opcode bug
+ (c4x_operands_match): New function argument. Added dry-run
+ mechanism, that is optional error generation. Added constraint 'i'
+ and 'j'.
+ (c4x_insn_check): Added new function for post-verification of the
+ generated insn.
+ (md_assemble): Check all opcodes before croaking because of an
+ argument mismatch. Need this to be able to fully support
+ ortogonally arguments.
+ (md_parse_options): Revised commandprompt swicthes and added new
+ ones.
+ (md_show_usage): Complete rewrite of printout.
+
+2002-11-16 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * config/tc-tic4x.c: Remove c4x_pseudo_ignore function.
+ (c4x_operands_match): Added check for 8-bits LDF insn. Give
+ warning when using constant direct bigger than 2^16. Add the new
+ arguments.
+
+2002-11-11 Christopher Faylor <cgf@redhat.com>
+
+ * configure.in: Use .gdbinit under Cygwin.
+ * configure: Regenerate.
+
+2002-11-11 Christopher Faylor <cgf@redhat.com>
+
+ * config/tc-i386.h (EXTERN_FORCE_RELOC): Define only if
+ STRICT_PE_FORMAT.
+
+2002-11-11 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * config/tc-tic4x.c: Declare as many functions as possible as
+ static. Maintenance on the general indenting. Removed unnecessary
+ pseudo-ops and added new ones. Removed obsoleted c4x_pseudo_ignore
+ function. Add support for new DSP, TMS320VC33. Fix bug for
+ converting flonum constants.
+ (c4x_do_align): Add proper align handling. Setup align to insert
+ NOP's.
+ (c4x_gen_to_words): Support for extended TI type floats.
+ (md_atof): Proper dumping of multiple-word littlenums.
+ (c4x_atof): Added support for extended TI type floats.
+ (c4x_stringer): Added new function to handle compact strings.
+ (c4x_emit_char): Added new function argument to handle custom
+ length inserts, like single-byte strings.
+ * config/tc-tic4x.h: Add proper align handling with NOP's.
+ * Makefile.am: Added tic4x dependecy
+ * Makefile.in: Regenerate
+
+2002-11-11 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * macro.c (get_any_string): Correct logic for not going beyond end
+ of in->ptr[].
+
+2002-11-10 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * config/tc-mmix.c (get_putget_operands): Mark both possible
+ operands as invalid at beginning.
+
+ * config/tc-mmix.c (md_convert_frag) <case STATE_GREG_DEF>:
+ Initialize target of fixup to zero.
+
+2002-11-07 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-mips.c (macro_build_lui): _gp_disp is not special on
+ NEWABI, but we should still emit HI16_S for non-PIC n32.
+
+2002-11-06 Richard Henderson <rth@redhat.com>
+
+ * config/tc-alpha.c (alpha_validate_fix): Move code ...
+ (alpha_fix_adjustable): ... here.
+ * config/tc-alpha.h (TC_VALIDATE_FIX): Remove.
+
+2002-11-07 Eric Kohl <ekohl@rz-online.de>
+
+ * config/te-pe.h (LEX_AT): Accept at-sign (@) as first character
+ of a label.
+
+2002-11-05 H.J. Lu <hjl@gnu.org>
+
+ * config/tc-mips.c (support_64bit_objects): Check *l before it
+ is freed.
+
+2002-11-04 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * config/obj-coff.c (obj-coff-section): Set SEC_DATA and
+ SEC_LOAD flags for sections marked as 's'.
+
+2002-11-01 Alan Modra <amodra@bigpond.net.au>
+
+ * write.c (TC_FORCE_RELOCATION_SUB_ABS): Default to zero.
+ (TC_FORCE_RELOCATION_SUB_LOCAL): Likewise when DIFF_EXPR_OK.
+ * doc/internals.texi (TC_FORCE_RELOCATION_SUB_ABS): Document changed
+ default.
+
+ * dep-in.sed: Fix typo.
+
+2002-10-30 Daniel Jacobowitz <drow@mvista.com>
+
+ * configure.in: Update ARM CPU patterns.
+ * configure: Regenerated.
+
+2002-10-29 Daniel Jacobowitz <drow@mvista.com>
+
+ * itbl-lex.l: Use #include <> for generated headers.
+ * itbl-ops.c: Likewise.
+
+2002-10-28 Daniel Jacobowitz <drow@mvista.com>
+
+ * doc/gasp.texi: Fix typo in deprecation note.
+
+2002-10-23 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-arm.c (tc_gen_reloc): Allow an absolute reference to
+ _GLOBAL_TABLE_OFFSET_ to be converted into a GOT reloc.
+
+2002-10-23 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * config/tc-mmix.h (mmix_frob_file_before_adjust): Don't declare.
+ (tc_frob_file_before_adjust): Don't define.
+ * config/tc-mmix.c (mmix_frob_local_reloc): Remove unused
+ function.
+ (mmix_frob_file_before_adjust): Remove ineffective function.
+
+2002-10-23 Hans-Peter Nilsson <hp@axis.com>
+
+ * config/tc-cris.c (SIMPLE_EXPR): New macro.
+ (cris_relax_frag): New function.
+ (md_estimate_size_before_relax) <case ENCODE_RELAX
+ (STATE_BASE_PLUS_DISP_PREFIX, STATE_UNDF)>: Pass on unresolved
+ expressions that will become absolute expressions to relaxation.
+ (md_convert_frag) <case ENCODE_RELAX (STATE_BASE_PLUS_DISP_PREFIX,
+ STATE_WORD)>: Expect only absolute expressions. Use the symbol
+ value, not distance to symbol.
+ <case ENCODE_RELAX (STATE_BASE_PLUS_DISP_PREFIX, STATE_BYTE)>:
+ Ditto. Correct placement of fixup.
+ (md_assemble): Use SIMPLE_EXPR when dissecting expressions.
+ (gen_bdap): Ditto.
+ * config/tc-cris.h (cris_relax_frag): Declare.
+ (md_relax_frag): Define.
+
+2002-10-22 Alan Modra <amodra@bigpond.net.au>
+
+ * config/obj-elf.c (special_sections): Use correct types for init
+ array sections.
+ (obj_elf_change_section): Don't mess with init array section type.
+
+2002-10-21 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-mips.c (mips_need_elf_addend_fixup): Return true
+ for relocs against symbols in a merged section.
+
+2002-10-18 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-mips.c (md_begin): Add $fcc registers to the symbol
+ table as register names.
+
+2002-10-18 Ulrich Weigand <uweigand@de.ibm.com>
+
+ * config/tc-s390.c (md_parse_option): Set s390_arch_size to 32
+ for option -m31.
+
+2002-10-18 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * expr.c (operand): Add support for n.nn flonums.
+
+2002-10-17 Johannes Stezenbach <js@convergence.de>
+
+ * itbl-parse.y (entry): Provide empty action.
+
+2002-10-16 Alan Modra <amodra@bigpond.net.au>
+
+ * configure.in (BFDVER_H): Set and subst.
+ * dep-in.sed: Replace bfdver.h with $(BFDVER_H).
+ * Makefile.am: Run "make dep-am".
+ (BFDVER_H): Define.
+ * configure: Regenerate.
+ * Makefile.in: Regenerate.
+ * doc/Makefile.in: Regenerate.
+
+2002-10-15 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-i386.h (EXTERN_FORCE_RELOC): Define.
+ (MD_APPLY_SYM_VALUE): Define for PE too.
+
+2002-10-14 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ (CPU_OBJ_VALID): sh64 coff is invalid.
+ * as.c: #include "bfdver.h".
+ * Makefile.in: Regenerate.
+ * config.in: Regenerate.
+
+2002-10-14 Momchil Velikov <velco@fadata.bg>
+
+ * config/tc-v850.c (CHECK_): Remove token pasting operator.
+
+2002-10-14 Richard Sandiford <rsandifo@redhat.com>
+
+ * configure.in (mips64vr-elf, mips64vrel-elf): New config.
+ * configure: Regenerate.
+
+2002-10-13 Eric Christopher <echristo@redhat.com>
+ Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-mips.c (s_gpdword): New function.
+ (mips_pseudo_table): Add .gpdword.
+ (mips_need_elf_addend_fixup): never for NEWABI.
+ (md_apply_fix3): Don't mark BFD_RELOC64 after GPREL16 or
+ GPREL32 as done.
+ (s_cpadd): Generate .cpadd on NEWABI.
+
+2002-10-12 Elias Athanasopoulos <eathan@otenet.gr>
+
+ * config/tc-ppc.c (ppc_cleanup): Make 'i' unsigned int.
+
+2002-10-12 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-mips.h (mips_relax_frag): Take segment as argument.
+ (md_relax_frag): Adjust macro.
+ * config/tc-mips.c (mips_relax_branch): New variable.
+ (RELAX_BRANCH_ENCODE, RELAX_BRANCH_P, RELAX_BRANCH_LIKELY,
+ RELAX_BRANCH_LINK, RELAX_BRANCH_TOOBAR): New.
+ (RELAX_MIPS16_P): Adjust.
+ (append_insn): Emit branch to non-constant in a frag_var if
+ branch-relaxation is desirable and possible.
+ (OPTION_RELAX_BRANCH, OPTION_NO_RELAX_BRANCH): New options.
+ (OPTION_ELF_BASE): Adjust.
+ (md_parse_option): Handle new options.
+ (md_apply_fix3): Update comment on EMBEDDED_PIC conditional
+ branch relaxation.
+ (relaxed_branch_length): New function.
+ (md_estimate_size_before_relax): Handle branch frags.
+ (mips_relax_frag): Likewise.
+ (md_convert_frag): Handle branch frags. Warn if branch is
+ relaxed.
+
+2002-10-11 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * config/tc-sh.c (sh_force_relocation): Make sure TLS relocs get
+ emitted.
+ (md_apply_fix3): Add TLS relocs.
+ (sh_parse_name): Support @TLSGD, @TLSLDM, @GOTTPOFF, @TPOFF and
+ @DTPOFF.
+
+2002-10-11 Michel Six <msix@ccr.jussieu.fr>
+ Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-i386.c (output_jump): Set fx_signed for loop/jcxz.
+ (md_estimate_size_before_relax): Likewise for 8 bit branches.
+
+Thu Oct 10 14:31:30 2002 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * config/tc-sh.c (assemble_ppi): Initialize reg_x / reg_y / reg_n
+ inside loop.
+
+2002-10-09 Richard Shann <richard.shann@superh.com>
+ Stephen Clarke <stephen.clarke@superh.com>
+
+ * config/tc-sh64.c (sh64_target_format): Add support for sh64
+ Linux environment.
+
+2002-10-03 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * contig/tc-sh.c (sh_local_pcrel): New.
+ (sh_force_relocation): Use sh_local_pcrel.
+ (md_pcrel_from_section): Check the relocation type whether it
+ should be resolved locally. Use S_FORCE_RELOC.
+
+2002-10-01 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-mips.h (TC_FORCE_RELOCATION_SUB_SAME): Define.
+ (TC_FORCE_RELOCATION): Tidy arg.
+
+2002-09-30 Gavin Romig-Koch <gavin@redhat.com>
+ Ken Raeburn <raeburn@cygnus.com>
+ Aldy Hernandez <aldyh@redhat.com>
+ DJ Delorie <dj@redhat.com>
+ Michael Meissner <meissner@redhat.com>
+ Eric Christopher <echristo@redhat.com>
+ Richard Sandiford <rsandifo@redhat.com>
+
+ * doc/c-mips.texi: Add entries for -march=vr4120,vr4130,vr4181,
+ vr5400 and vr5500. Add entry for -mfix-vr4122-bugs.
+ * config/tc-mips.c (CPU_HAS_DROR, CPU_HAS_ROR): New macros.
+ (hilo_interlocks): True for CPU_VR5500.
+ (gpr_interlocks, cop_interlocks): True for CPU_VR5400 and CPU_VR5500.
+ (mips_fix_vr4122_bugs): New.
+ (append_insn): Work around 4122 errors if mips_fix_vr4122_bugs.
+ (mips_emit_delays): Likewise.
+ (macro2) [M_DROLI]: Use dror or dror32 if CPU_HAS_DROR.
+ [M_ROLI]: Likewise ror if CPU_HAS_ROR.
+ (validate_mips_insn, mips_ip): Handle '[', ']', 'e' and '%'.
+ (OPTION_FIX_VR4122, OPTION_NO_FIX_VR4122): New options.
+ (md_longopts): Add -mfix-vr4122-bugs and -no-mfix-vr4122-bugs.
+ (OPTION_ELF_BASE): Bump.
+ (md_parse_option): Handle the new options.
+ (mips_cpu_info_table): Add entries for vr4120, vr4130, vr4181,
+ vr5400 and vr5500.
+
+2002-09-29 H.J. Lu <hjl@gnu.org>
+
+ * config/tc-mips.c (md_apply_fix3): Subtract the symbol value
+ twice if howto->pcrel_offset is true.
+
+2002-09-28 Matt Thomas <matt@3am-software.com>
+ Jason Thorpe <thorpej@wasabisystems.com>
+
+ * config/tc-vax.c (md_estimate_size_before_relax): Only try to
+ convert undefined references to GOT32/PLT32 if PIC code is
+ requested. Fix comment.
+
+2002-09-27 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * config/tc-sh.c (sh_force_relocation): Return 0 for
+ some PC relative relocations when not relaxing.
+
+2002-09-26 Jakub Jelinek <jakub@redhat.com>
+
+ * config/tc-i386.c (tc_i386_fix_adjustable): Add x86-64 TLS relocs.
+ Define them if not BFD_ASSEMBLER.
+ (lex_got): Handle @tlsgd, @dtpoff and @tpoff in 64-bit mode, add
+ @tlsld.
+ (md_apply_fix3): No addend for BFD_RELOC_X86_64_TLSGD,
+ BFD_RELOC_X86_64_TLSLD and BFD_RELOC_X86_64_GOTTPOFF.
+ (tc_gen_reloc): Handle x86-64 TLS relocs.
+
+2002-09-27 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-avr.c (md_apply_fix3): Reinstate code handling pcrel
+ fixups to current or absolute section.
+
+2002-09-26 Jim Wilson <wilson@redhat.com>
+
+ * config/tc-v850.c (v850_offset): Use frag_var instead of frag_now_fix
+ and frag_more.
+
+2002-09-26 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (CPU_HAS_MIPS16): Add mips-lsi-elf as MIPS16
+ capable configuration.
+ (macro_build): Check for MIPS16 capability, not for actual MIPS16 code
+ generation.
+ (mips_ip): Likewise.
+
+2002-09-26 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (append_insn): Fix jump overflow check.
+
+2002-09-24 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-i386.c (process_operands): Warn about "lea" segment
+ overrides.
+
+2002-09-22 Mark Elbrecht <snowball3@softhome.net>
+
+ * write.c: Delete set_segment_vma and prototype. Update all callers.
+
+2002-09-21 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-i386.c (md_apply_fix3): Replace S_IS_EXTERNAL,
+ S_IS_WEAK etc. with S_FORCE_RELOC call. Correct comment.
+ Rename "fseg" to "sym_seg".
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * doc/Makefile.in: Regenerate.
+
+2002-09-20 Nick Clifton <nickc@redhat.com>
+
+ * symbols.c (colon): Do not allow symbols to be created in the
+ absolute section if WORKING_DOT_WORD is not defined and
+ new_broken_words would require a new frag to be created.
+
+2002-09-20 Alan Modra <amodra@bigpond.net.au>
+
+ * expr.c (expr): Simplify foo-foo here.
+ (clean_up_expression): Remove O_subtract code.
+
+ * write.h (struct fix): Add fx_dot_value.
+ (dot_value): Declare.
+ * write.c (dot_value): New var.
+ (fix_new_internal): Save dot_value as fx_dot_value.
+ (fixup_segment): Adjust fx_offset using fx_dot_value.
+ * expr.c (expr): Update dot_value.
+
+2002-09-19 Jakub Jelinek <jakub@redhat.com>
+
+ * config/tc-i386.c (tc_i386_fix_adjustable): Handle
+ BFD_RELOC_386_TLS_IE and BFD_RELOC_386_TLS_GOTIE.
+ (BFD_RELOC_386_TLS_IE, BFD_RELOC_386_TLS_GOTIE): Define to 0
+ if not defined.
+ (lex_got): Handle @GOTNTPOFF and @INDNTPOFF.
+ (md_apply_fix3, tc_gen_reloc): Handle BFD_RELOC_386_TLS_IE and
+ BFD_RELOC_386_TLS_GOTIE.
+
+2002-09-19 Richard Henderson <rth@redhat.com>
+
+ * config/tc-alpha.c (md_pcrel_from): Only adjust special for
+ branch type relocs.
+ (alpha_force_relocation): Don't special-case branch type relocs.
+
+2002-09-19 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-m68k.c (select_control_regs): Handle situation where
+ architecture has not yet been selected.
+
+2002-09-18 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (IS_SEXT_32BIT_NUM): Move closer to top of file.
+ (IS_SEXT_16BIT_NUM): New macro.
+ (macro_build_ldst_constoffset): New function, to build a set of
+ instructions to do a load or store from a constant offset relative
+ to a given register.
+ (macro, s_cprestore): Use macro_build_ldst_constoffset to implement
+ .cprestore pseudo-op.
+
+2002-09-18 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (md_apply_fix3): Just return for BFD_RELOC_8.
+
+2002-09-18 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (s_change_section): Fix parsing. Code cleanup.
+
+2002-09-17 Stan Cox <scox@redhat.com>
+
+ * tc-mips.c (load_address): Use BFD_RELOC_MIPS_GOT_DISP for newabi.
+ (macro): Likewise for la. Likewise for ld.
+ (mips_after_parse_args): Make -xgot optional, not the default.
+ (md_apply_fix3): Allow composite relocation to set up gp.
+ (tc_gen_reloc): Allow relaxing for newabi.
+ Relax R_MIPS_CALL16 to R_MIPS_GOT_PAGE/R_MIPS_GOT_OFST if local.
+ Relax R_MIPS_GOT16/R_MIPS_LO16 to R_MIPS_GOT_DISP if local.
+
+2002-09-17 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-arm.c (md_apply_fix3): Note that an implemented
+ BFD_RELOC_ARM_IMMEDIATE has been done.
+ (tc_gen_reloc): Do not issue reloc number of unimplemented
+ BFD_RELOC_ARM_IMMEDIATE and BFD_RELOC_ARM_OFFSET_IMM relocs -
+ their name is already in the error message - plus remove them
+ from the default case.
+
+ * config/tc-arm.c (do_ldmstm): Warn about unpredictable
+ behavior of instructions.
+
+2002-09-17 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * config/tc-tic4x.c: Add function declarations and ATTRIBUTE_UNUSED.
+ Convert functions to K&R format.
+
+2002-09-17 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (pdr_seg): Define only for ELF.
+ (s_change_section): Remove unused variable. Don't use for nonELF.
+
+2002-09-17 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/obj-elf.c (obj_elf_change_section): Move prototype to
+ obj-elf.h
+ * config/obj-elf.h (obj_elf_change_section): Likewise.
+
+2002-09-16 Elias Athanasopoulos <eathan@otenet.gr>
+
+ * dwarf2dbg.c (out_debug_abbrev): Add support for the DW_AT_name field.
+ (out_debug_info): Likewise.
+
+2002-09-16 Bruno Haible <bruno@clisp.org>
+
+ * config/tc-i386.h (ELF_TARGET_FORMAT): New macro.
+ (TARGET_FORMAT): Use ELF_TARGET_FORMAT instead of "elf32-i386".
+ * config/tc-i386.c (i386_target_format): Likewise.
+ * config/tc-alpha.h (ELF_TARGET_FORMAT): New macro.
+ (TARGET_FORMAT): Use ELF_TARGET_FORMAT instead of "elf64-alpha".
+
+2002-09-13 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-ppc.c (md_assemble): Do not count FAKE operands
+ when deciding if any operands have been skipped.
+
+2002-09-11 Nick Clifton <nickc@redhat.com>
+
+ * NEWS: New TI port supports both C4x and C3x series of DSPs.
+
+ * po/tr.po: Updated Turkish translation.
+
+2002-09-11 Jakub Jelinek <jakub@redhat.com>
+
+ * config/tc-i386.c (md_apply_fix3): Allow addend for
+ BFD_RELOC_386_TLS_LDO_32, BFD_RELOC_386_TLS_LE and
+ BFD_RELOC_386_TLS_LE_32.
+
+2002-09-05 Jeff Law <law@redhat.com>
+
+ * config/tc-hppa.c (md_apply_fix3): Don't set fx_done for
+ marker relocations such as ENTRY/EXIT.
+ * config/tc-hppa.h (MD_APPLY_SYM_VALUE): Definition applies
+ to both OBJ_ELF and OBJ_SOM.
+
+2002-09-05 Alan Modra <amodra@bigpond.net.au>
+
+ * doc/internals.texi (md_apply_fix3): Expand.
+ (TC_VALIDATE_FIX, TC_FORCE_RELOCATION, TC_FORCE_RELOCATION_ABS,
+ TC_FORCE_RELOCATION_LOCAL, TC_FORCE_RELOCATION_SUB_SAME,
+ TC_FORCE_RELOCATION_SUB_ABS, TC_FORCE_RELOCATION_SUB_LOCAL,
+ TC_VALIDATE_FIX_SUB, MD_APPLY_SYM_VALUE, S_FORCE_RELOC,
+ EXTERN_FORCE_RELOC): Document.
+ (TC_HANDLES_FX_DONE, obj_fix_adjustable): Remove.
+ * as.h: Don't include struc-symbol.h for arc.
+ (IS_ELF): Define.
+ * cgen.c (gas_cgen_md_apply_fix3): Remove *valP fudges and code to
+ subtract absolute symbol.
+ * obj.h (struct format_ops): Add frob_file_before_fix.
+ * subsegs.c (section_symbol): Set BSF_SECTION_SYM flag.
+ * symbols.c (S_FORCE_RELOC): New function.
+ * symbols.h (S_FORCE_RELOC): Declare.
+ * write.c (TC_FORCE_RELOCATION): Change default.
+ (TC_FORCE_RELOCATION_ABS): Define.
+ (TC_RELOC_RTSYM_LOC_FIXUP): Don't define.
+ (TC_FORCE_RELOCATION_LOCAL): Define this instead.
+ (TC_FORCE_RELOCATION_SECTION): Don't define.
+ (TC_FORCE_RELOCATION_SUB_SAME): Define this instead.
+ (TC_FORCE_RELOCATION_SUB_ABS): Define.
+ (TC_FORCE_RELOCATION_SUB_LOCAL): Define.
+ (TC_VALIDATE_FIX_SUB): Define.
+ (TC_FIX_ADJUSTABLE): Don't define.
+ (MD_APPLY_SYM_VALUE): Define this instead.
+ (abs_section_sym): New variable.
+ (adjust_reloc_syms): Use S_FORCE_RELOC. Remove obj_fix_adjustable
+ call. Don't symbol_mark_used_in_reloc here. Simplify link_once tests.
+ Don't put the absolute section sym on fixups here.
+ (fix_segment): New function.
+ (write_relocs): Don't call fixup_segment from here.
+ (write_object_file): Instead call tc_frob_file_before_fix,
+ obj_frob_file_before_fix, and fix_segment prior to symbol table code.
+ Don't output the absolute section symbol.
+ (fixup_segment): Rewrite.
+ * write.h (abs_section_sym): Declare.
+ * config/obj-aout.c (obj_aout_frob_file_before_fix): Rename from
+ obj_aout_frob_file.
+ (aout_format_ops): Adjust to suit.
+ * config/obj-aout.h (obj_frob_file): Don't define.
+ (obj_frob_file_before_fix): Define.
+ (obj_aout_frob_file_before_fix): Rename from obj_aout_frob_file.
+ (S_FORCE_RELOC): Define.
+ * config/obj-bout.h (S_FORCE_RELOC): Define.
+ * config/obj-coff.c (coff_format_ops): Init new field.
+ * config/obj-coff.h: Formatting fixes.
+ (obj_sec_sym_ok_for_reloc): Define.
+ (S_FORCE_RELOC): Define.
+ * config/obj-ecoff.c (ecoff_frob_file_before_fix): Split out ..
+ (ecoff_frob_file): .. from here.
+ (ecoff_format_ops): Add new function.
+ * config/obj-ecoff.h (ecoff_frob_file_before_fix): Declare.
+ (obj_frob_file_before_fix): Define.
+ * config/obj-elf.c (elf_format_ops): Init new field.
+ * config/obj-elf.h (obj_sec_sym_ok_for_reloc): Expand comment.
+ * config/obj-ieee.h: Formatting fixes.
+ (S_FORCE_RELOC): Define.
+ * config/obj-multi.h (obj_frob_file_before_fix): Define.
+ * config/obj-vms.h (S_FORCE_RELOC): Define.
+ * config/tc-alpha.c (md_apply_fix3): Correct GPDISP comment.
+ (alpha_force_relocation): Use S_FORCE_RELOC, and don't return 0
+ for BFD_RELOC_32 and BFD_RELOC_64.
+ (alpha_fix_adjustable): Remove extern and weak tests.
+ (alpha_before_fix): Rename from alpha_adjust_symtab.
+ (alpha_adjust_relocs): Rename from alpha_adjust_symtab_relocs.
+ * config/tc-alpha.h (struct fix, struct alpha_reloc_tag): Declare.
+ (TC_VALIDATE_FIX): Tweak param name.
+ (TC_FORCE_RELOCATION, tc_fix_adjustable): Likewise.
+ (TC_RELOC_RTSYM_LOC_FIXUP): Don't define.
+ (TC_FORCE_RELOCATION_LOCAL): Define this instead.
+ (MD_APPLY_SYM_VALUE): Define.
+ (tc_adjust_symtab): Don't define.
+ (alpha_adjust_symtab): Don't declare.
+ (tc_frob_file_before_fix): Define.
+ (alpha_before_fix): Declare.
+ (TC_INIT_FIX_DATA): Tweak param names.
+ * config/tc-arc.c: Include "struc-symbol.h".
+ (md_pcrel_from): Remove undefined sym fudge.
+ (md_apply_fix3): Remove *valP fudges and code to subtract abs sym.
+ Don't set fx_addnumber.
+ (tc_gen_reloc): Remove spurious fx_addnumber comment.
+ * config/tc-arc.h (MD_APPLY_SYM_VALUE): Define.
+ (EXTERN_FORCE_RELOC): Define.
+ * config/tc-arm.c (md_apply_fix3 <case BFD_RELOC_ARM_GOTPC>): Remove.
+ (tc_gen_reloc): Fudge ARM_GOTPC addend.
+ (arm_validate_fix): Return void.
+ (arm_fix_adjustable <elf version>): Remove extern and weak tests.
+ Add plt and got reloc tests.
+ (arm_force_relocation): Call S_FORCE_RELOC.
+ * config/tc-arm.h (struct fix): Forward declare.
+ (TC_VALIDATE_FIX): No longer set add_symbolP.
+ (arm_validate_fix): Adjust declaration.
+ (TC_FORCE_RELOCATION <pe version): Call S_FORCE_RELOC.
+ (TC_FORCE_RELOCATION): Tweak param name.
+ (TC_INIT_FIX_DATA): Likewise.
+ (obj_fix_adjustable): Don't define.
+ (tc_fix_adjustable): Call arm_fix_adjustable.
+ (TC_FIX_ADJUSTABLE): Don't define.
+ (MD_APPLY_SYM_VALUE): Define.
+ (EXTERN_FORCE_RELOC): Define.
+ (TC_RELOC_RTSYM_LOC_FIXUP): Don't define.
+ (TC_FORCE_RELOCATION_LOCAL): Define this instead.
+ * config/tc-avr.c (md_apply_fix3): Don't cast valP pointer type.
+ Remove *valP fudges and code to subtract abs sym. Don't set
+ fx_addnumber.
+ * config/tc-avr.h: Formatting.
+ (EXTERN_FORCE_RELOC): Define.
+ (MD_APPLY_SYM_VALUE): Define.
+ * config/tc-cris.c (tc_gen_reloc): Don't use fx_addnumber.
+ (md_apply_fix3): Remove code to subtract abs sym.
+ (md_cris_force_relocation): Update comment. Call S_FORCE_RELOC.
+ * config/tc-cris.h (TC_FORCE_RELOCATION): Tweak param name.
+ (IS_CRIS_PIC_RELOC, tc_fix_adjustable): Likewise.
+ (TC_RELOC_RTSYM_LOC_FIXUP): Don't define.
+ (TC_FORCE_RELOCATION_LOCAL): Define this instead.
+ (tc_fix_adjustable): Remove extern, weak tests.
+ * config/tc-d10v.c (tc_gen_reloc): Don't fiddle address of
+ BFD_RELOC_VTABLE_INHERIT relocs. Don't use fx_addnumber.
+ (md_apply_fix3): Don't cast valP pointer type. Remove *valP fudges
+ and code to subtract abs sym.
+ (d10v_fix_adjustable): Remove extern, weak, SEC_MERGE tests.
+ (d10v_force_relocation): Call S_FORCE_RELOC.
+ * config/tc-d10v.h: Don't include write.h.
+ (struct fix): Instead, forward declare.
+ (MD_PCREL_FROM_SECTION): Tweak param names.
+ (md_pcrel_from_section): Use "struct fix" instead of "fixS".
+ (d10v_fix_adjustable): Likewise.
+ (obj_fix_adjustable): Don't define.
+ (tc_fix_adjustable): Define.
+ (TC_FORCE_RELOCATION): Tweak param name.
+ (MD_APPLY_SYM_VALUE): Define.
+ (EXTERN_FORCE_RELOC): Define.
+ * config/tc-d30v.c (tc_gen_reloc): Don't use fx_addnumber.
+ (md_apply_fix3): Don't cast valP pointer type. Remove *valP fudges
+ and code to subtract abs sym.
+ * config/tc-d30v.h: Don't include write.h.
+ (struct fix): Instead, forward declare.
+ (MD_PCREL_FROM_SECTION): Tweak param names.
+ (md_pcrel_from_section): Use "struct fix" instead of "fixS".
+ (MD_APPLY_SYM_VALUE): Define.
+ (EXTERN_FORCE_RELOC): Define.
+ * config/tc-dlx.c (md_dlx_force_relocation): Call S_FORCE_RELOC.
+ (md_dlx_fix_adjustable): Don't test for NULL fx_addsy.
+ (md_apply_fix3): No need to test fx_pcrel before setting fx_done.
+ (tc_gen_reloc): Don't fiddle with BFD_RELOC_VTABLE_INHERIT relocs.
+ Adjust the address for BFD_RELOC_VTABLE_ENTRY, not the addend.
+ Don't use fx_addnumber.
+ * config/tc-dlx.h: Don't include write.h.
+ (md_convert_frag): We're not alpha twice over.
+ (EXTERN_FORCE_RELOC): Define.
+ (obj_fix_adjustable): Don't define.
+ (tc_fix_adjustable): Define.
+ (TC_FIX_ADJUSTABLE): Don't define.
+ (MD_APPLY_SYM_VALUE): Define.
+ (LOCAL_LABELS_DOLLAR): Undef always.
+ * config/tc-fr30.c (fr30_force_relocation): Call S_FORCE_RELOC.
+ (fr30_fix_adjustable): Remove extern, weak tests.
+ * config/tc-fr30.h (MD_APPLY_SYM_VALUE): Define.
+ (obj_fix_adjustable): Don't define.
+ (tc_fix_adjustable): Define.
+ (struct fix): Forward declare.
+ (MD_PCREL_FROM_SECTION): Tweak param name. Remove duplicate.
+ * config/tc-frv.c (frv_force_relocation): Call S_FORCE_RELOC.
+ (frv_fix_adjustable): Don't do extern, weak tests.
+ * config/tc-frv.h (MD_APPLY_SYM_VALUE): Define.
+ (TC_FIX_ADJUSTABLE): Don't define.
+ (obj_fix_adjustable): Don't define.
+ (tc_fix_adjustable): Define.
+ (struct fix): Forward declare.
+ (MD_PCREL_FROM_SECTION): Tweak param name. Remove duplicate.\
+ * config/tc-h8300.c (md_apply_fix3): Don't cast valP pointer type.
+ * config/tc-h8300.h (struct fix): Forward declare.
+ (EXTERN_FORCE_RELOC): Define.
+ * config/tc-hppa.c (md_apply_fix3): Remove subtraction of sym value.
+ (hppa_fix_adjustable): Don't test extern or weak. Don't
+ symbol_mark_used_in_reloc.
+ (hppa_force_relocation): Use S_FORCE_RELOC instead of S_IS_EXTERNAL
+ and S_IS_WEAK.
+ * config/tc-hppa.h (EXTERN_FORCE_RELOC): Define
+ (TC_FORCE_RELOCATION, TC_INIT_FIX_DATA): Tweak param name.
+ (TC_FORCE_RELOCATION_SECTION): Don't define.
+ (MD_APPLY_SYM_VALUE): Define.
+ * config/tc-i370.c (md_apply_fix3): Remove *valP fudges and code
+ to subtract abs sym.
+ * config/tc-i370.h: Remove ifdef OBJ_ELF tests.
+ (MD_APPLY_SYM_VALUE): Define.
+ (MD_PCREL_FROM_SECTION): Tweak param name.
+ * config/tc-i386.c (tc_i386_fix_adjustable): Remove weak, extern tests.
+ (md_apply_fix3): Test fx_addsy, not fx_pcrel.
+ (i386_force_relocation): New function.
+ * config/tc-i386.h (TC_COFF_FIX2RTYPE): Tweak param name.
+ (TC_VALIDATE_FIX): Likewise.
+ (TC_FIX_ADJUSTABLE): Don't define.
+ (MD_APPLY_SYM_VALUE): Define.
+ (TC_FORCE_RELOCATION <elf version>): Call i386_force_relocation.
+ (i386_force_relocation): Declare.
+ (TC_RELOC_RTSYM_LOC_FIXUP): Don't define.
+ (TC_FORCE_RELOCATION_LOCAL): Define this instead.
+ (TC_FORCE_RELOCATION <coff version>): Call S_FORCE_RELOC.
+ * config/tc-i860.c (md_apply_fix3): Don't cast valP pointer type.
+ * config/tc-i860.h (MD_APPLY_SYM_VALUE): Define.
+ (EXTERN_FORCE_RELOC): Define.
+ * config/tc-i960.c (reloc_callj): Remove declaration. Return false.
+ (md_apply_fix3): Don't cast valP pointer type. Move code here from
+ old fixup_segment. No need to test fx_pcrel before setting fx_done.
+ (i960_validate_fix): Remove add_symbolPP arg and add_symbolP macro.
+ Use fx_addsy instead of add_symbolP, as_bad_where instead of as_bad.
+ Remove #if 0 code. Invert return boolean.
+ * config/tc-i960.h (TC_COUNT_RELOC): Tweak param name.
+ (TC_COFF_FIX2RTYPE, TC_ADJUST_RELOC_COUNT, TC_VALIDATE_FIX): Likewise.
+ (tc_headers_hook, tc_coff_fix2rtype): Remove declaration.
+ (tc_coff_sizemachdep): Prototype.
+ (i960_handle_align): Likewise.
+ (i960_validate_fix): Adjust declaration.
+ (reloc_callj): Likewise.
+ (EXTERN_FORCE_RELOC): Define.
+ (TC_FORCE_RELOCATION_SUB_SAME): Define.
+ (TC_FORCE_RELOCATION_ABS): Define.
+ (TC_RELOC_RTSYM_LOC_FIXUP): Don't define.
+ (TC_FORCE_RELOCATION_LOCAL): Define this instead.
+ (TC_FIX_ADJUSTABLE): Don't define.
+ (MD_APPLY_SYM_VALUE): Define.
+ * config/tc-ia64.c (ia64_force_relocation): Call S_FORCE_RELOC.
+ * config/tc-ia64.h (MD_APPLY_SYM_VALUE): Define.
+ (TC_RELOC_RTSYM_LOC_FIXUP): Don't define.
+ (TC_FORCE_RELOCATION_LOCAL): Define this instead.
+ * config/tc-ip2k.c (ip2k_force_relocation): Call S_FORCE_RELOC.
+ * config/tc-ip2k.h (MD_APPLY_FIX3): Don't define.
+ (MD_APPLY_SYM_VALUE): Define.
+ (EXTERN_FORCE_RELOC): Define.
+ (TC_FORCE_RELOCATION): Tweak param name.
+ * config/tc-m32r.c (m32r_force_relocation): Call S_FORCE_RELOC.
+ (m32r_fix_adjustable): Don't test extern, weak.
+ * config/tc-m32r.h (MD_PCREL_FROM_SECTION): Tweak param name.
+ (MD_APPLY_SYM_VALUE): Define.
+ (obj_fix_adjustable): Don't define.
+ (tc_fix_adjustable): Define.
+ (tc_frob_file): Don't define.
+ (tc_frob_file_before_fix): Define.
+ (EXTERN_FORCE_RELOC): Define.
+ * config/tc-m68hc11.c (tc_gen_reloc): Set addend to zero. Adjust
+ BFD_RELOC_VTABLE_ENTRY address.
+ (tc_m68hc11_force_relocation): Call S_FORCE_RELOC.
+ (tc_m68hc11_fix_adjustable): Don't test relaxable_symbol.
+ (md_apply_fix3): Remove *valP fudges and code to subtract abs sym.
+ Remove duplicated fx_done code.
+ * config/tc-m68hc11.h (MD_APPLY_SYM_VALUE): Define.
+ (EXTERN_FORCE_RELOC): Define.
+ * config/tc-m68k.c (tc_m68k_fix_adjustable): Don't test
+ relaxable_symbol.
+ * config/tc-m68k.h (TC_COFF_FIX2RTYPE): Tweak param name.
+ (TC_RELOC_RTSYM_LOC_FIXUP): Don't define.
+ (TC_FIX_ADJUSTABLE): Don't define.
+ (EXTERN_FORCE_RELOC): Define.
+ (MD_APPLY_SYM_VALUE): Define.
+ (TC_FORCE_RELOCATION): Call S_FORCE_RELOC.
+ * config/tc-mcore.c (md_apply_fix3): Don't cast valP pointer type.
+ Remove fx_addsy tests.
+ (mcore_force_relocation): Call S_FORCE_RELOC.
+ (mcore_fix_adjustable): Don't test fx_addsy.
+ * config/tc-mcore.h (MD_PCREL_FROM_SECTION): Tweak param name.
+ (EXTERN_FORCE_RELOC): Define.
+ (obj_fix_adjustable): Don't define.
+ (tc_fix_adjustable): Define.
+ (MD_APPLY_SYM_VALUE): Define.
+ * config/tc-mips.c (enum mips_pic_level): Move to tc-mips.h.
+ (mips_pic): No longer static.
+ (mips_force_relocation): Call S_FORCE_RELOC.
+ (mips_fix_adjustable): Remove extern, weak tests.
+ * config/tc-mips.h (enum mips_pic_level): Declare.
+ (mips_pic): Declare.
+ (tc_frob_file): Don't define.
+ (tc_frob_file_before_fix): Define this instead.
+ (EXTERN_FORCE_RELOC): Define.
+ * config/tc-mmix.c (md_apply_fix3): Replace real_reg_section tests
+ with reg_section tests. Set fx_done instead of calling
+ symbol_clear_used_in_reloc on bad relocs.
+ (tc_gen_reloc): Zero fx_addsy on bad relocs.
+ (mmix_force_relocation): Remove weak sym test. Call S_FORCE_RELOC.
+ (mmix_adjust_symtab): Simplify list handling. Abort on any
+ nonsense.
+ * config/tc-mmix.h (tc_fix_adjustable): Remove weak tests. Check
+ BFD_RELOC_MMIX_LOCAL.
+ (tc_frob_symbol): Keep user defined syms in reg_section. Don't punt.
+ (EXTERN_FORCE_RELOC): Define.
+ (MD_PCREL_FROM_SECTION): Tweak param name.
+ (tc_frob_file): Don't define.
+ (tc_frob_file_before_fix): Define this instead.
+ * config/tc-mn10300.c (mn10300_force_relocation): Call S_FORCE_RELOC.
+ Remove SEC_CODE checks.
+ (mn10300_fix_adjustable): Remove extern and weak tests.
+ * config/tc-mn10300.h (EXTERN_FORCE_RELOC): Define.
+ (TC_FORCE_RELOCATION): Tweak param name.
+ (obj_fix_adjustable): Don't define.
+ (TC_FORCE_RELOCATION_SUB_SAME): Define to handle SEC_CODE.
+ * config/tc-ns32k.h (TC_FIX_DATA_PRINT): Tweak param name.
+ * config/tc-openrisc.c (openrisc_force_relocation): Call S_FORCE_RELOC.
+ (openrisc_fix_adjustable): Don't test fx_addsy.
+ * config/tc-openrisc.h (MD_APPLY_SYM_VALUE): Define.
+ (obj_fix_adjustable): Don't define.
+ (tc_fix_adjustable): Define this instead.
+ (MD_PCREL_FROM_SECTION): Remove duplicate. Tweak param name.
+ * config/tc-or32.c (md_apply_fix3): Don't cast valP pointer type.
+ (tc_gen_reloc): Don't fiddle with BFD_RELOC_VTABLE_INHERIT relocs.
+ Adjust the address for BFD_RELOC_VTABLE_ENTRY, not the addend.
+ * config/tc-or32.h (EXTERN_FORCE_RELOC): Define.
+ (MD_APPLY_SYM_VALUE): Define.
+ * config/tc-pj.c (md_apply_fix3): Don't cast valP pointer type.
+ Don't subtract symbol value.
+ * config/tc-pj.h (md_pcrel_from): Tweak param name.
+ (EXTERN_FORCE_RELOC): Define.
+ (TC_FORCE_RELOCATION): Call S_FORCE_RELOC.
+ (MD_APPLY_SYM_VALUE): Define.
+ (obj_fix_adjustable): Don't define.
+ (tc_fix_adjustable): Define this instead.
+ * config/tc-ppc.c (ppc_frob_symbol <coff version>): Ignore absolute
+ section sym.
+ (ppc_force_relocation <coff version>): Call S_FORCE_RELOC.
+ (ppc_force_relocation <elf version>): New.
+ (ppc_fix_adjustable <elf version>): Remove extern and weak tests.
+ (md_apply_fix3): Don't subtract symbol values for ELF. Update
+ comments. Don't subtract fx_subsy as that is already done.
+ * config/tc-ppc.h (tc_fix_adjustable): Tweak param name.
+ (MD_PCREL_FROM_SECTION): Likewise.
+ (TC_FORCE_RELOCATION): Define for both ELF and XCOFF as calling
+ ppc_force_relocation.
+ (TC_FORCE_RELOCATION_SECTION): Delete.
+ (TC_RELOC_RTSYM_LOC_FIXUP): Don't define.
+ (TC_FORCE_RELOCATION_LOCAL): Define this instead.
+ (MD_APPLY_SYM_VALUE): Define.
+ * config/tc-s390.c: #include "dwarf2dbg.h".
+ (s390_insn): Remove excess parens.
+ (tc_s390_fix_adjustable): Remove extern, weak, SEC_MERGE tests.
+ (tc_s390_force_relocation): Call S_FORCE_RELOC.
+ (md_apply_fix3): Add ATTRIBUTE_UNUSED on "seg". Abort when fx_subsy
+ non-NULL. Don't subtract off fx_addsy value.
+ * config/tc-s390.h (TC_RELOC_RTSYM_LOC_FIXUP): Don't define.
+ (TC_FORCE_RELOCATION, MD_PCREL_FROM_SECTION): Tweak param name.
+ (TC_FIX_ADJUSTABLE): Don't define.
+ (MD_APPLY_SYM_VALUE): Define.
+ * config/tc-sh.c (SWITCH_TABLE_CONS): Move to tc-sh.h.
+ (SWITCH_TABLE): Likewise.
+ (sh_force_relocation): Call S_FORCE_RELOC.
+ (sh_fix_adjustable): Remove "return 1" cases handled by the default.
+ Replace TC_RELOC_RTSYM_LOC_FIXUP with reloc type tests.
+ (md_apply_fix3 <case BFD_RELOC_32_PLT_PCREL>): Simplify,
+ fx_addnumber is zero on entry. Save val in fx_addnumber.
+ (tc_gen_reloc): Don't subtract fx_subsy.
+ * config/tc-sh.h (struct fix): Move.
+ (obj_fix_adjustable): Don't define.
+ (tc_fix_adjustable): Define this instead.
+ (TC_FIX_ADJUSTABLE): Don't define.
+ (MD_APPLY_SYM_VALUE): Define.
+ (SWITCH_TABLE_CONS): Define.
+ (SWITCH_TABLE): Define.
+ (TC_FORCE_RELOCATION_SUB_SAME): Define.
+ (TC_VALIDATE_FIX_SUB): Define.
+ (MD_PCREL_FROM_SECTION): Tweak param name.
+ (TC_RELOC_RTSYM_LOC_FIXUP): Don't define.
+ (TC_FORCE_RELOCATION_LOCAL): Define this instead.
+ (TC_FORCE_RELOCATION_SUB_ABS): Define.
+ * config/tc-sh64.h (TC_RELOC_RTSYM_LOC_FIXUP): Don't define.
+ (TC_FORCE_RELOCATION_LOCAL): Define this instead.
+ (TC_FORCE_RELOCATION_SUB_SAME): Define.
+ (TC_VALIDATE_FIX_SUB): Define.
+ (MD_PCREL_FROM_SECTION): Tweak param name.
+ * config/tc-sparc.c (md_apply_fix3): Don't subtract off symbol value.
+ (tc_gen_reloc): Use S_FORCE_RELOC.
+ (elf32_sparc_force_relocation): Call S_FORCE_RELOC.
+ * config/tc-sparc.h (TC_FORCE_RELOCATION <coff version>): Remove.
+ (TC_FORCE_RELOCATION_ABS): Define this instead.
+ (TC_RELOC_RTSYM_LOC_FIXUP): Don't define.
+ (TC_FORCE_RELOCATION_LOCAL): Define this instead.
+ (tc_fix_adjustable): Remove extern and weak tests. Use S_FORCE_RELOC.
+ (MD_APPLY_SYM_VALUE): Define.
+ (TC_FIX_DATA_PRINT): Tweak param name.
+ * config/tc-tic30.c (USE_STDOUT): Don't define.
+ (md_parse_option): Remove stupid debug code.
+ (tc_gen_reloc): Don't use fx_addnumber.
+ * config/tc-v850.c (v850_fix_adjustable): Remove extern and weak tests.
+ (v850_force_relocation): Remove weak test. Call S_FORCE_RELOC.
+ * config/tc-v850.h (obj_fix_adjustable): Don't define.
+ (tc_fix_adjustable): Define this instead.
+ (TC_FIX_ADJUSTABLE): Don't define.
+ (MD_APPLY_SYM_VALUE): Define this instead.
+ (TC_FORCE_RELOCATION, MD_PCREL_FROM_SECTION): Tweak param name.
+ * config/tc-vax.h (TC_RELOC_RTSYM_LOC_FIXUP): Don't define.
+ (TC_FIX_ADJUSTABLE): Don't define.
+ (MD_APPLY_SYM_VALUE): Define this instead.
+ (tc_fix_adjustable): Remove extern and weak tests.
+ * config/tc-w65.h (struct fix): Forward declare.
+ * config/tc-xstormy16.c (xstormy16_force_relocation): Call
+ S_FORCE_RELOC.
+ (xstormy16_fix_adjustable): Remove extern and weak tests. Don't
+ call xstormy16_force_relocation; Instead test for FPTR16 reloc.
+ (xstormy16_md_apply_fix3): Remove *valP fudges and code to subtract
+ absolute symbol.
+ * config/tc-xstormy16.h (MD_APPLY_FIX3): Don't define.
+ (MD_APPLY_SYM_VALUE): Define.
+ (obj_fix_adjustable): Don't define.
+ (tc_fix_adjustable): Define this instead.
+ (MD_PCREL_FROM_SECTION): Remove duplicate. Tweak param name.
+
+2002-09-04 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ppc.c (ppc_frob_symbol): Formatting, warning fix.
+ (ppc_fix_adjustable <coff version>): Cleanup.
+
+ * config/tc-ppc.c (PPC_HIGHER, PPC_HIGHEST): Fix warning.
+ (md_parse_option): No -a64 without BFD64.
+ (ppc_set_cpu): Select appropriate cpu when ppc_obj64.
+ (ppc_arch): Use bfd_mach_rs6k for bfd_arch_rs6000.
+
+2002-09-04 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-ppc.c (md_begin): Do not insert non-BookE32
+ instructions into the hash table if the target cpu is the BookE32.
+
+2002-08-31 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * read.c (do_align): Use ATTRIBUTE_UNUSED_LABEL for label, not
+ ATTRIBUTE_UNUSED.
+
+2000-08-28 Catherine Moore <clm@redhat.com>
+
+ * tc-v850.c (v850_relax): Declare.
+ (v850_longcode): New routine.
+ (v850_handle_align): New routine.
+ (md_pseudo_table): Add longcall and longjump.
+ (md_parse_option): Check for relax option.
+ (tc_gen_reloc): Handle BFD_RELOC_V850_LONGCALL,
+ BFD_RELOC_V850_LONGJUMP, and BFD_RELOC_V850_ALIGN.
+ (md_apply_fix3): Likewise.
+ (v850_force_relocation): Likewise.
+ (v850_comm): Change the current section.
+ (md_assemble): Ensure that the correct value is put in the
+ fixup.
+ (v850_sdata, v850_tdata, v850_zdata, v850_sbss, v850_tbss,
+ v850_zbss, v850_rosdata, v850_rozdata): Fix section book keeping.
+ Remove redundant v850ea support.
+ * tc-v850.h (HANDLE_ALIGN): Define.
+ (v850_handle_align): Declare.
+ * doc/c-v850.c: Document -mrelax, .longcall and .longjump.
+
+2002-08-28 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * configure.in: Add tic4x-coff* and c4x-coff*-coff-coff targets.
+ * configure: Regenerate.
+ * NEWS: Mention new port.
+
+2002-08-28 Michael Hayes <m.hayes@elec.canterbury.ac.nz>
+
+ * config/obj-coff.c: Add sdef definition.
+ * config/obj-coff.h: Add tic4x include file and set
+ target format.
+ * config/tc-tic4x.c: New file.
+ * config/tc-tic4x.h: New file.
+
+2002-08-28 Alan Modra <amodra@bigpond.net.au>
+
+ * write.c (BFD_FAST_SECTION_FILL): Remove unused macro.
+ (TC_ADJUST_RELOC_COUNT): Tweak param name.
+ (TC_FORCE_RELOCATION, TC_FORCE_RELOCATION_SECTION): Likewise.
+ (TC_FIX_ADJUSTABLE, MD_PCREL_FROM_SECTION): Likewise.
+ (RELOC_ENUM): Define.
+ (fix_new_internal): Use RELOC_ENUM.
+ (fix_new, fix_new_exp): Likewise.
+ (adjust_reloc_syms): Comment. Remove unnecessary tests on sym != NULL.
+ Replace gotos with continue.
+ (write_relocs): Formatting. Avoid symbol loops in
+ RELOC_EXPANSION_POSSIBLE case too. Report bfd_reloc_outofrange
+ errors, and error number in other cases.
+ (fixup_segment): Remove param names from prototype. Rename
+ "this_segment_type" to "this_segment". Update linkrelax comment.
+ Remove "size, "place" and "where" local vars. Formatting. Update
+ "no symbol" comment. Remove #if 0 and #if 1.
+
+ * app.c (do_scrub_chars): Don't test IGNORE_NONSTANDARD_ESCAPES. Tidy.
+
+2002-08-27 Alan Modra <amodra@bigpond.net.au>
+
+ * dwarf2dbg.c: Always include dwarf2dbg.h.
+ (dwarf2_directive_file): Adjust dummy version args.
+ * ecoff.c (ecoff_directive_weakext): Add ATTRIBUTE_UNUSED.
+ * expr.c (clean_up_expression <O_subtract>): Allow subtraction
+ when symbol values differ.
+ * read.c (do_align): Add ATTRIBUTE_UNUSED to label.
+ (pseudo_set <O_subtract>): Remove unnecessary segment test.
+ * config/obj-bout.c (obj_pseudo_table): Warning fix.
+
+2002-08-26 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-w65.c (md_section_align): Fix typo.
+ (md_parse_option): Return 0, not 1.
+
+2002-08-22 Nick Clifton <nickc@redhat.com>
+
+ * doc/as.texinfo (Section): Note that if '@' is a comment
+ character then another symbol is used to prefix the section's
+ type.
+
+2002-08-22 Christian Groessler <chris@groessler.org>
+
+ * config/tc-z8k.c (get_operands): Adjust ptr variable also in
+ "case 0" case.
+
+2002-08-12 Graeme Peterson <gp@qnx.com>
+
+ * configure.in: Add support for sh-**-nto* target.
+ * configure: Regenerate.
+
+2002-08-21 Nitin Gupta <niting@noida.hcltech.com>
+
+ * config/tc-h8300.h (TC_LINKRELAX_FIXUP): Define.
+
+2002-08-21 Elena Zannoni <ezannoni@redhat.com>
+
+ * config/tc-ppc.c (ppc_cleanup): Do something only if format
+ is ELF.
+ (ppc_apuinfo_section_add): Define only if format is ELF.
+ (md_assemble): Emit APUinfo section only if format is ELF.
+ Fix formatting.
+
+2002-08-21 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-arc.c (md_pseudo_table <dwarf2_directive_file>): Cast.
+ * config/tc-frv.c: Likewise.
+ * config/tc-hppa.c: Likewise.
+ * config/tc-ia64.c: Likewise.
+ * config/tc-ip2k.c: Likewise.
+ * config/tc-m68hc11.c: Likewise.
+ * config/tc-m68k.c: Likewise.
+ * config/tc-mmix.c: Likewise.
+ * config/tc-mn10300.c: Likewise.
+ * config/tc-sh.c: Likewise.
+ * config/tc-sparc.c: Likewise.
+ * config/tc-v850.c: Likewise.
+
+2002-08-20 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-mips.c (macro2): Implement rotates by zero using shifts
+ by zero.
+
+2002-08-19 Elena Zannoni <ezannoni@redhat.com>
+
+ From matthew green <mrg@redhat.com>
+
+ * config/tc-ppc.c (PPC_OPCODE_CLASSIC): Enable this everywhere
+ PPC_OPCODE_PPC is, except for BookE architectures.
+ (md_parse_option): Add support for -mspe.
+ (md_show_usage): Add -mspe.
+ (md_parse_option): Add support for -me500 and
+ -me500x2 to generate code for Motorola e500 core complex.
+ (md_show_usage): Add -me500 and -me500x2.
+
+ (PPC_APUINFO_ISEL, PPC_APUINFO_PMR, PPC_APUINFO_RFMCI,
+ PPC_APUINFO_CACHELCK, PPC_APUINFO_SPE, PPC_APUINFO_EFS,
+ PPC_APUINFO_BRLOCK): New macros.
+
+ (ppc_cleanup): New function.
+ (ppc_apuinfo_section_add): New function.
+ (APUID): New macro.
+ (md_assemble): Collect info and write the APUinfo section.
+
+ * config/tc-ppc.h (md_cleanup): Define.
+ (ppc_cleanup): Export.
+ (ELF_TC_SPECIAL_SECTIONS): Add .PPC.EMB.apuinfo section.
+
+2002-08-17 Stan Cox <scox@redhat.com>
+
+ * config/obj-elf.c (obj_elf_change_section): Make non-static.
+ config/tc-mips.c (s_change_section): New function to support
+ IRIX .section pseudo-op.
+
+2002-08-16 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-v850.c (md_assemble): Fix assembling of "callt 0x3f".
+
+2002-08-15 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-mips.c (macro_build_jalr): Make sure we generate
+ the fix-up against on the right frag.
+ (s_cpsetup): Likewise. Parse third argument as expression, to
+ handle global symbols and forward/backward labels correctly.
+
+2002-08-14 Nick Clifton <nickc@redhat.com>
+
+ * read.c (stringer): Catch attempts to create strings in the abs
+ section.
+
+ * config/tc-alpha.c: Fix compiling for COFF targets.
+ Some minor formatting tidyups.
+
+2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
+
+ * config/tc-m68hc11.h (MD_PCREL_FROM_SECTION): Remove.
+ (TC_HANDLES_FX_DONE): Define to let md_apply_fix3 set fx_done flag
+ according to the reloc.
+ (tc_fix_adjustable, tc_m68hc11_fix_adjustable): Define.
+ (TC_FORCE_RELOCATION): Define.
+ (tc_m68hc11_force_relocation): Declare.
+
+ * config/tc-m68hc11.c (md_pseudo_table): Add relax command.
+ (s_m68hc11_relax): New function for relax group.
+ (build_insn, build_jump_insn): Emit a M68HC11_RL_JUMP reloc at
+ beginning of jump instruction.
+ (md_pcrel_from): Rename from md_pcrel_from_section and fix
+ address computation.
+ (tc-gen_reloc): Update.
+ (md_estimate_size_before_relax): Create the BFD_RELOC_16_PCREL as
+ PC-relative fixup.
+ (tc_m68hc11_force_relocation): New function, handle new relocs.
+ (tc_m68hc11_fix_adjustable): New to make sure there are enough
+ reloc for the linker relax pass.
+ (md_apply_fix3): Handle M68HC11_RL_JUMP, M68HC11_RL_GROUP
+ and VTABLE relocs.
+
+2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
+
+ * config/tc-m68hc11.c (m68hc11_elf_final_processing): New function.
+ (md_pseudo_table): Add .mode, .far and .interrupt pseudo op.
+ (s_m68hc11_mode): New function for .mode pseudo op.
+ (s_m68hc11_mark_symbol): New function for .far and .interrupt
+ pseudo op.
+ * config/tc-m68hc11.h (elf_tc_final_processing): Define.
+ (m68hc11_elf_final_processing): Declare.
+
+2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
+
+ * config/tc-m68hc11.c (md_begin): Take into account additional
+ page operand for call instruction.
+ (print_opcode_format): Likewise.
+ (check_range): Likewise for page range checking.
+ (get_operand): Don't skip a possible comma in operands.
+ (fixup8): Generate BFD_RELOC_M68HC11_PAGE reloc.
+ (fixup16): Likwise with BFD_RELOC_M68HC11_LO16.
+ (fixup24): New to handle call reloc.
+ (build_insn): Handle missing page operand for call instruction.
+ (find): Likewise.
+ (md_apply_fix3): Take into account new relocs.
+ (get_operand): Fix the mode for indexed indirect addressing.
+ (build_indexed_byte): Fix post index byte for indexed indirect mode.
+
+2002-08-12 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-mips.c (mips_ip): Don't work out the value of
+ constant %hi()s here.
+
+2002-08-10 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-i386.c (tc_i386_fix_adjustable): Test OUTPUT_FLAVOR
+ for ELF, and don't bother checking ELF relocs when non-ELF.
+ (i386_immediate): Allow absolute_section expressions for aout.
+ (i386_displacement): Likewise. Also test bfd_is_com_section.
+ (md_estimate_size_before_relax): Test OUTPUT_FLAVOR for ELF.
+ (md_apply_fix3): Hack for bfd_install_relocation when fx_pcrel,
+ not when fx_addsy. Remove dead code.
+
+2002-08-09 Graeme Peterson <gp@qnx.com>
+
+ * configure.in: Add support for ppc-*-nto* target.
+ * configure: Regenerate.
+
+2002-08-09 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-i386.h: Reorganize.
+
+2002-08-09 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * config/tc-mips.c (macro): Handle a register plus a 16-bit
+ immediate offset in "dla" and "la" expansions.
+
+2002-08-09 Alan Modra <amodra@bigpond.net.au>
+
+ * configure.in: bfd_gas=yes for all i386 targets. Formatting.
+ Remove "bfd_gas=yes" from target table when covered later.
+ Consolidate some entries.
+ * configure: Regenerate
+
+2002-08-09 Jakub Jelinek <jakub@redhat.com>
+
+ * config/tc-i386.c (output_insn): Save frag_now and frag_now_fix ()
+ at start of insn, pass it to output_disp and output_imm.
+ (output_disp): Added arguments. If _GLOBAL_OFFSET_TABLE_ is seen
+ in displacement for R_386_32 reloc, use R_386_GOTPC and compute
+ properly addend.
+ (output_imm): Added arguments. Compute properly addend for
+ R_386_GOTPC.
+ (md_apply_fix3): Remove R_386_GOTPC handling.
+
+2002-08-06 George France <france@handhelds.org>
+
+ * config/tc-alpha.c (cpu_types): Enabled ev67, ev68, -m21264a
+ and m21264b processor names and cpu types.
+ * doc/c-alpha.texi: Documented new types.
+
+2002-08-06 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ppc.c (md_apply_fix3): Adjust 16 bit XCOFF reloc offset.
+
+2002-08-01 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-mips.c (tc_gen_reloc): Extend GP-relative addend
+ handling to BFD_RELOC_MIPS16_GPREL.
+
+2002-08-01 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-arm.c (add_to_lit_pool): Ensure that offset to literal
+ pool is computed using signed arithmetic so that proper sign
+ extension is performed if X_add_number is a 64-bit integer.
+
+2002-08-01 H.J. Lu <hjl@gnu.org>
+ Daniel Jacobowitz <drow@mvista.com>
+
+ * dwarf2dbg.c (dwarf2_finish): Don't emit unreferenced
+ .debug_line section unless it has line information.
+
+2002-07-31 Ian Dall <ian@sibyl.beware.dropbear.id.au>
+
+ * config/tc-ns32k.h (md_pcrel_adjust): Supply prototype.
+ * config/tc-ns32k.c (convert_iif, md_parse_option, md_show_usage):
+ Allow default displacement size to be an option "--disp-size-default".
+ (md_number_to_disp): Make error messages include value. Use %d to
+ print integers, not %s.
+ (fix_new_ns32k): Conditionally set fx_no_overflow so we don't
+ get duplicate messages sometimes.
+ (convert_iif): Grow frag to max possible instruction size. Avoid
+ creating unnecessary fixes.
+ (md_number_to_field) Add prototype.
+ (encode_operand, parse, convert_iif, md_fix_pcrel_adjust): Add
+ prototypes and make static.
+ (struct addr_mode): Make mode and scaled_mode explicitly signed.
+ (evaluate_expr): Use resultP argument instead of exprP global.
+ (get_addr_mode): Quiten compiler warnings.
+ (encode_operand): eliminate unused variables. Quiten compiler
+ warnings. Eliminate nul character in format strings.
+ (parse): argc is unsigned.
+ (reloc): Type cast index to quieten compiler.
+ (md_pcrel_adjust, md_apply_fix3): Remove unused variable.
+ (md_convert_frag): Note unused parameters. Remove unused
+ variables.
+ (md_create_long_jump, md_create_short_jump,
+ md_undefined_symbol_name, md_section_align, tc_gen_reloc): Note
+ unused parameters.
+
+2002-07-31 Nick Clifton <nickc@redhat.com>
+
+ * NEWS: Retroactively add entry for Lars Brinkhoff's contribution
+ of the PDP-11 and 2.11BSD a.out support.
+
+2002-07-31 Momchil Velikov <velco@fadata.bg>
+
+ * config/tc-v850.c (md_assemble): Fix range check for immediate
+ operand.
+
+2002-07-30 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (mips_cpu_info_table): Clean up entries related
+ to Broadcom SB-1 core support.
+
+2002-07-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (mips_target_format): Fix formatting.
+ Add recognition of n32 ABI formats.
+
+2002-07-30 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * tc-mips.c (load_address): Don't clobber $at when loading a
+ 64-bit address in non-PIC code if noat is in effect.
+ (macro): Likewise.
+
+2002-07-30 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * config/tc-mips.c (macro): Use codes 6 and 7 in trap instructions
+ used in division/multiply macro expansions similarly to how they
+ are used in the variants with break instructions.
+ (macro2): Likewise.
+
+2002-07-30 Graeme Peterson <gp@qnx.com>
+
+ * configure.in: Add support for arm-*-nto target.
+ * configure: Regenerate.
+
+2002-07-30 Nick Clifton <nickc@redhat.com>
+
+ * config/tc-arm.c (struct literal_pool): Add fields to allow
+ multiple literal pools to be maintained.
+ (find_literal_pool): New function.
+ (find_or_make_literal_pool): New function.
+ (add_to_literal_pool): Use find_or_make_literal_pool.
+ (arm_s_text, arm_s_data, arm_s_section): Remove - no longer
+ needed.
+ (s_ltorg): Use find_literal_pool.
+ (arm_cleanup): Dump all literal pools.
+ * doc/c-arm.texi: Document new behaviour of only dumping literal
+ pools upon request.
+
+2002-07-26 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ppc.c (ppc_set_cpu): Use PPC_OPCODE_64 as the default
+ rather than PPC_OPCODE_32 for powerpc64*.
+
+2002-07-25 Nick Clifton <nickc@redhat.com>
+
+ * po/es.po: Updated Spanish translation.
+ * po/fr.po: Updated French translation.
+
+2002-07-25 Richard Sandiford <rsandifo@redhat.com>
+
+ * doc/c-mips.texi: Remove -mcpu. Document -mabi.
+ * configure.in (MIPS_CPU_STRING_DEFAULT): New configuration macro.
+ (USE_E_MIPS_ABI_O32, MIPS_DEFAULT_64BIT): New configuration macros.
+ * configure, config.in: Regenerate.
+ * config/tc-mips.c (file_mips_abi): Rename to mips_abi.
+ (mips_set_options): Remove "abi" field.
+ (mips_opts): Update accordingly. Replace all uses of mips_opts.abi
+ with mips_abi.
+ (mips_cpu): Remove.
+ (mips_arch_string, mips_arch_info): New vars.
+ (mips_tune_string, mips_tune_info): New vars.
+ (ABI_NEEDS_32BIT_REGS, ABI_NEEDS_64BIT_REGS): New macros.
+ (HAVE_32BIT_GPRS, HAVE_32BIT_FPRS): Don't check the ABI.
+ (mips_isa_to_str, mips_cpu_to_str): Remove.
+ (mips_ip): If the selected architecture is a generic ISA rather
+ than a processor, only mention the ISA level in error messages.
+ (OPTION_MCPU): Remove.
+ (OPTION_FP64): New.
+ (md_longopts): Add -mfp64, remove -mcpu.
+ (mips_set_option_string): New fn.
+ (md_parse_option): Make -mipsN update file_mips_isa rather than
+ mips_opts.isa. Use mips_set_option_string to set -march or -mtune.
+ Don't let -mgp32 and -mfp32 change the ABI.
+ (show): Move to end of file. Constify string argument.
+ (md_show_usage): Move to the end of the file. Read available
+ architectures from mips_cpu_info_table.
+ (mips_set_architecture): New fn.
+ (mips_after_parse_args): Rework. Remove -mcpu handling. -mipsN
+ is an alias for -march=mipsN. Don't change the ABI based on other
+ flags. Infer the register size from the ABI as well as the
+ architecture. Complain about more conflicting arguments.
+ Unify logic with GCC.
+ (s_mipsset): Don't change the ABI.
+ (mips_elf_final_processing): Check USE_E_MIPS_ABI_O32.
+ (mips_cpu_info_table): Remove Generic-MIPS* entries, keeping just
+ "mipsN"-type entries. Remove entries that vary only in the
+ manufacturer's prefix, or that have "000" replaced by "k".
+ Remove TARGET_CPU entries. Make r2000 entry use CPU_R3000.
+ (mips_strict_matching_cpu_name_p, mips_matching_cpu_name_p): New fns.
+ (mips_parse_cpu): New fn.
+ (mips_cpu_info_from_name, mips_cpu_info_from_cpu): Remove.
+ (mips_cpu_info_from_isa): Minor formatting tweak.
+
+2002-07-24 Nick Clifton <nickc@redhat.com>
+
+ * po/sv.po: Updated Swedish translation.
+ * po/es.po: Updated Spanish translation.
+
+2002-07-23 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * doc/Makefile.in: Regenerate.
+ * config.in: Regenerate.
+ * po/POTFILES.in: Regenerate.
+
+2002-07-23 Nick Clifton <nickc@redhat.com>
+
+ * po/fr.po: Updated French translation.
+
+2002-07-23 Nick Clifton <nickc@redhat.com>
+
+ * CONTRIBUTORS: Ken Raeburn is no longer the maintainer for
+ GAS.
+
+2002-07-19 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (mips_need_elf_addend_fixup): Use S_IS_EXTERNAL
+ instead of S_IS_EXTERN.
+ (md_estimate_size_before_relax): Likewise.
+ (mips_fix_adjustable): Likewise.
+
+2002-07-19 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (mips_pic_level): Remove IRIX4_PIC.
+
+2002-07-19 Miroslav Tichy <tichm9am@ss1000.ms.mff.cuni.cz>
+ Nick Clifton <nickc@redhat.com>
+
+ * cond.c (s_ifdef): Treat a referenced but not yet defined
+ symbol as if it were undefined, in exactly the same way as
+ .equiv.
+
+ * doc/as.texinfo: Document that .ifdef, .ifndef and .equiv
+ consider referenced bug not yet defined symbols to be
+ undefined.
+
+2002-07-18 Denis Chertykov <denisc@overta.ru>
+ Frank Ch. Eigler <fche@redhat.com>
+ Alan Lehotsky <alehotsky@cygnus.com>
+ John Healy <jhealy@redhat.com>
+ Jeff Johnston <jjohnstn@redhat.com>
+
+ * configure.in: Add ip2k configuraton.
+ * configure: Regenerate.
+ * Makefile.am: Add ip2k configuraton.
+ * Makefile.in: Regenerate.
+ * configure: Regenerate.
+ * Makefile.in: Regenerate.
+ * config/tc-ip2k.c: New file.
+ * config/tc-ip2k.h: New files.
+ * NEWS: Mention new support.
+ * doc/Makefile.am (CPU_DOCS): Add c-ip2k.texi.
+ * doc/Makefile.in: Regenerate.
+ * doc/all.texi: Set IP2K
+ * doc/as.texinfo: Add IP2K description.
+ * doc/c-ip2k.texi: New file.
+
+2002-07-19 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * NEWS: Reformat to match style of other NEWS files.
+
+2002-07-17 Jan Hubicka <jh@suse.cz>
+
+ * tc-i386.c (i386_align_code): Implement x86_64 neutral code fillers.
+
+2002-07-16 Moritz Jodeit <moritz@jodeit.org>
+
+ * config/tc-z8k.c (build_bytes): Correct order of memset args.
+
+2002-07-16 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * NEWS: Add 'Changes in 2.13'.
+
+2002-07-15 Matt Fredette <fredette@netbsd.org>
+
+ * config/tc-hppa.h (LABELS_WITHOUT_COLONS): Define if TE_NetBSD.
+
+2002-07-12 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-i386.c (process_suffix): Merge CODE_64BIT JumpByte
+ case with non CODE_64BIT case. Don't warn on "qword ptr" if
+ not CODE_64BIT.
+
+2002-07-11 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-ppc.c (ppc_elf_frob_symbol): Delete.
+ (ppc_frob_file_before_adjust): New function.
+ * config/tc-ppc.h (tc_frob_symbol): Don't define.
+ (ppc_elf_frob_symbol): Don't declare.
+ (tc_frob_file_before_adjust): Define.
+ (ppc_frob_file_before_adjust): Declare.
+
+ * config/tc-ppc.c (md_pseudo_table): Warning fix.
+ (ppc_cpu): Make it unsigned long to agree with struct powerpc_opcode
+ flags.
+ (ppc_size): Delete.
+ (ppc_xcoff64): Rename to ppc_obj64.
+ (md_parse_option <m>): Encode old ppc_size value in ppc_cpu.
+ (ppc_set_cpu): Set PPC_OPCODE_32 too.
+ (ppc_arch): Use ppc_obj64 instead of ppc_size to select bfd_mach_ppc64
+ or bfd_mach_ppc.
+ (ppc_target_format): Use ppc_obj64 to select format.
+ (md_begin): Adjust for PPC_OPCODE_32/64 in ppc_cpu.
+ (ppc_insert_operand): Use ppc_obj64 instead of ppc_size.
+ (ppc_elf_suffix): Likewise. Don't depend on BFD_DEFAULT_TARGET_SIZE.
+ (tc_frob_symbol): Likewise.
+ (md_assemble): Use ppc_obj64 instead of ppc_size. Don't depend on
+ BFD_DEFAULT_TARGET_SIZE.
+ (ppc_tc): Likewise.
+ (ppc_is_toc_sym): Likewise.
+ (md_apply_fix3): Likewise.
+ * config/tc-ppc.h (TC_FORCE_RELOCATION): Don't depend on
+ BFD_DEFAULT_TARGET_SIZE.
+ (ELF_TC_SPECIAL_SECTIONS): Likewise.
+ (tc_frob_symbol): Likewise.
+
+2002-07-09 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (macro_build): Handle MIPS16 insns.
+ (mips_ip): Likewise.
+
+2002-07-09 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-i386.c (md_pseudo_table <file>): Warning fix.
+ (BFD_RELOC_8, BFD_RELOC_8_PCREL): Define for non-BFD.
+ (md_apply_fix3): Formatting. Remove redundant test.
+ (tc_gen_reloc): Remove redundant code.
+ (tc_i386_force_relocation): Delete. Movy body of function to..
+ * config/tc-i386.h (TC_FORCE_RELOCATION): .. here.
+
+2002-07-09 Federico G. Schwindt <fgsch@olimpo.com.br>
+
+ * configure.in: Add hppa-*-openbsd* target, change
+ alpha*-*-openbsd* format to elf, and use elf for sparc-*-openbsd*
+ with sparc64 cpu.
+ * configure: Regenerate.
+
+2002-07-08 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * config/tc-mips.c (macro): Shift the 32-bit address range
+ accessible with a lone "lui" down by 32768.
+
+2002-07-08 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * config/tc-mips.c (load_address): Use non-trapping "daddu"
+ instead of "dadd" in address calculations.
+ (macro): Likewise.
+
+2002-07-08 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-i386.c (process_suffix): Remove intel mode movsx and
+ movzx fudges.
+ (md_assemble): Instead, zap the suffix here.
+
+2002-07-03 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * NEWS: Remove next release number until the release is actually
+ upon us.
+
+2002-07-03 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (check-DEJAGNU): Revert 2002-06-25 change.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2002-07-02 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * config/tc-s390.c (tc_s390_fix_adjustable): Prevent any adjustment
+ to symbols in merge sections, even non pc-relative ones.
+
+2002-06-29 Stephane Carrez <stcarrez@nerim.fr>
+
+ * config/tc-m68hc11.h (m68hc11_listing_header): Fix warning.
+
+2002-06-29 Stephane Carrez <stcarrez@nerim.fr>
+
+ * config/tc-m68hc11.h (ELF_TC_SPECIAL_SECTIONS): New sections
+ .softregs and .eeprom.
+
+2002-06-28 David O'Brien <obrien@FreeBSD.org>
+
+ * NEWS: Note the next release is 2.13.
+
+2002-06-26 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/tr.po: New translation imported.
+
+2002-06-26 Elias Athanasopoulos <eathan@otenet.gr>
+
+ * ecoff.c: (get_tag): Replace strcpy with xstrdup.
+ (ecoff_directive_def): Likewise.
+ (ecoff_directive_tag): Likewise.
+ * listing.c (file_info): Likewise.
+ * hash.c (what): Likewise.
+
+2002-06-25 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.am (check-DEJAGNU): Set LC_ALL=C and export it.
+ * Makefile.in: Regenerated.
+
+2002-06-19 Dhananjay R. Deshpande <dhananjayd@kpit.com>
+
+ * config/tc-sh.c (get_specific): Revert 2002-05-01 change.
+ (assemble_ppi): Generate warning if the same register is used
+ twice as destination in the same padd / pmuls instruction.
+
+2002-06-18 Dave Brolley <brolley@redhat.com>
+
+ From Catherine Moore, Michael Meissner, Richard Sandiford, Dave Brolley
+ * po/POTFILES.in: Add tc-frv.c, tc-frv.h.
+ * configure.in: Support frv-*-*.
+ * Makefile.am (CPU_TYPES): Add frv.
+ (TARGET_CPU_CFILES): Add tc-frv.c.
+ (TARGET_CPU_HFILES): Add tc-frv.h.
+ (DEPTC_frv_coff): New variable.
+ (DEPTC_frv_elf): New variable.
+ (DEPOBJ_frv_coff): New variable.
+ (DEPOBJ_frv_elf): New variable.
+ (DEP_frv_coff): New variable.
+ (DEP_frv_elf): New variable.
+ * tc-frv.c: New file.
+ * tc-frv.h: New file.
+
+2002-06-17 Catherine Moore <clm@redhat.com>
+
+ * config/obj-elf.h (TARGET_SYMBOL_FIELDS): Conditionally define.
+
+2002-06-17 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * config/tc-sh.c (assemble_ppi): Initialize reg_n.
+
+2002-06-17 Tom Rix <trix@redhat.com>
+
+ * config/tc-i370.h (tc_comment_chars): Define for i370-elf.
+
+2002-06-14 H.J. Lu <hjl@gnu.org>
+ Daniel Jacobowitz <drow@mvista.com>
+
+ * dwarf2dbg.h (dwarf2_directive_file): Return char *.
+ * dwarf2dbg.c (dwarf2_directive_file): Return filename.
+ * config/tc-mips.c (s_mips_file): Call s_app_file_string
+ and new_logical_line for the first .file directive.
+ * read.c (s_app_file_string): New function.
+ (s_app_file): Call it.
+ * read.h (s_app_file_string): Add declaration.
+
+2002-06-14 Daniel Jacobowitz <drow@mvista.com>
+
+ * configure.in: Remove MIPS_STABS_ELF.
+ * configure: Regenerated.
+ * config.in: Regenerated.
+ * config/obj-elf.h (ECOFF_DEBUGGING): Define to mips_flag_mdebug
+ for MIPS targets.
+ * config/tc-mips.c (mips_pseudo_table): Remove #ifdef around
+ ".extern".
+ (pdr_seg): Declare unconditionally.
+ (md_begin): Always generate .pdr unless ECOFF_DEBUGGING or not ELF.
+ (s_mips_end): Likewise. Generate stabs function markers.
+ (s_mips_ent): Generate stabs function markers.
+ (s_mips_frame): Always generate .pdr unless ECOFF_DEBUGGING or not
+ ELF.
+ (s_mips_mask): Likewise.
+ (mips_flag_mdebug): New.
+ (md_longopts): Add "mdebug" and "no-mdebug".
+ (md_parse_options): Add OPTION_MDEBUG and OPTION_NO_MDEBUG.
+ (mips_after_parse_args): Set mips_flag_mdebug.
+ * doc/as.texinfo: Add "-mdebug" and "-no-mdebug" for MIPS.
+
+2002-06-13 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * config/tc-mips.c (md_apply_fix3): Don't subtract the symbol's
+ value twice for RELA relocations.
+
+2002-06-12 Ben Elliston <bje@redhat.com>
+
+ * symbols.c (resolve_symbol_value): Initialise final_val.
+
+ * subsegs.c (subsegs_print_statistics): Cast frchp to void *.
+
+2002-06-11 Tom Rix <trix@redhat.com>
+
+ * config/tc-ppc.c (ppc_subseg_align): Delete.
+ (ppc_change_csect): Default csect align is 2.
+ * config/tc-ppc.h (SUB_SEGMENT_ALIGN): Delete
+
+2002-06-09 Marek Michalkiewicz <marekm@amelek.gda.pl>
+
+ * config/tc-avr.c (mcu_types): Update.
+
+2002-06-08 Matt Thomas <matt@3am-software.com>
+
+ * configure.in (vax-*-netbsdelf*, vax-*-netbsdaout*)
+ (vax-*-netbsd*): New targets.
+ * configure: Regenerate.
+ * config/aout_gnu.h (enum machine_type): Add M_VAX4K_NETBSD.
+ * config/tc-vax.c: Add support for ELF and PIC.
+ (flag_want_pic): New flag.
+ (float_cons): Fix prototype.
+ (md_apply_fix3): Adjust for BFD_ASSEMBLER.
+ (md_assemble): Introduce a new is_absolute local, and use it
+ rather than repeating the test. Make fatal errors actually
+ fatal by using as_fatal as appropriate. Adjust for BFD_ASSEMBLER.
+ Add support for ELF. Add support for PIC.
+ (md_convert_frag): Adjust for BFD_ASSEMBLER.
+ (tc_aout_fix_to_chars): Only include if OBJ_AOUT and not
+ BFD_ASSEMBLER.
+ (vax_reg_parse): Make the % register prefix mandatory for ELF,
+ optional for a.out, and not allowed for VMS. Adjust all callers.
+ (md_create_short_jump): Add ATTRIBUTE_UNUSED to unused arguments.
+ (md_create_long_jump): Likewise.
+ (md_undefined_symbol): Likewise.
+ (md_section_align): Likewise.
+ (md_shortopts): Allow -k and -K for ELF.
+ (md_parse_option): Set flag_want_pic if -k or -K.
+ (tc_headers_hook): New function if OBJ_AOUT and not BFD_ASSEMBLER.
+ (tc_gen_reloc): New function if BFD_ASSEMBLER.
+ * config/tc-vax.h (tc_headers_hook): Remove.
+ (TARGET_FORMAT): Set according to object format and target
+ environment.
+ (BFD_ARCH, TARGET_ARCH): Define.
+ (NO_RELOC): Adjust for BFD_ASSEMBLER.
+ (TC_RELOC_RTSYM_LOC_FIXUP, TC_FIX_ADJUSTABLE)
+ (tc_fix_adjustable): Define if BFD_ASSEMBLER.
+ * config/vax-inst.h (VAX_JSB, VAX_CALLS, VAX_CALLG): Define.
+
+2002-06-08 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+ * as.c: Replace CONST with const.
+ * write.c: Likewise.
+ * config/obj-coff.c: Likewise.
+ * config/tc-a29k.c: Likewise.
+ * config/tc-arm.c: Likewise.
+ * config/tc-dlx.c: Likewise.
+ * config/tc-h8300.c: Likewise.
+ * config/tc-h8500.c: Likewise.
+ * config/tc-i370.c: Likewise.
+ * config/tc-i860.c: Likewise.
+ * config/tc-i960.c: Likewise.
+ * config/tc-m68hc11.c: Likewise.
+ * config/tc-m68k.c: Likewise.
+ * config/tc-m88k.c: Likewise.
+ * config/tc-mcore.c: Likewise.
+ * config/tc-mips.c: Likewise.
+ * config/tc-ns32k.c: Likewise.
+ * config/tc-pdp11.c: Likewise.
+ * config/tc-pj.c: Likewise.
+ * config/tc-s390.c: Likewise.
+ * config/tc-sh.c: Likewise.
+ * config/tc-sparc.c: Likewise.
+ * config/tc-tahoe.c: Likewise.
+ * config/tc-tic80.c: Likewise.
+ * config/tc-v850.c: Likewise.
+ * config/tc-vax.c: Likewise.
+ * config/tc-w65.c: Likewise.
+ * config/tc-z8k.c: Likewise.
+
+2002-06-08 Daniel Jacobowitz <drow@mvista.com>
+
+ Based on patch from Matt Green:
+ * config/obj-elf.h (ECOFF_DEBUGGING): Make configurable.
+ * config/tc-mips.c (s_mips_file): Renamed from s_file.
+ (s_mips_loc): New function.
+ (mips_nonecoff_pseudo_table): Call them.
+ (append_insn): Call dwarf2_emit_insn.
+
+2002-06-08 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (mips_opts): Fix comment, all ASE fields are set
+ to -1.
+ (file_ase_mips16): New veriable.
+ (mips_eabi64): Remove.
+ (CPU_HAS_MIPS16): New define.
+ (CPU_HAS_MDMX): Fix data type.
+ (md_begin): Code cleanup. Use file_ase_mips16.
+ (mips_elf_final_processing): Handle mips16 header flag.
+ Handle EABI flag without intermediate variable.
+
+2002-06-08 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * doc/as.texinfo: Update MIPS documentation.
+
+2002-06-08 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c: Add define for $zero register.
+ (md_begin): Add $zero as alias name for $0.
+ (insn_uses_reg): Use ZERO define.
+ (mips_ip): Add $zero as alias name for $0.
+ (mips16_ip): Likewise.
+ (s_cplocal): Demand empty rest of input line.
+ (tc_get_register): Likewise. Add support for $kt0, kt1 register
+ names. Use ZERO define. Fix input_line_pointer progress.
+
+2002-06-07 Alan Modra <amodra@bigpond.net.au>
+
+ * symbols.c: Replace CONST by const throughout.
+ (symbol_find_exact): Split out from..
+ (symbol_find_base): ..here.
+ * symbols.h: Replace CONST by const throughout.
+ (symbol_find_exact): Declare.
+ * config/obj-elf.c: #include "struc-symbol.h".
+ (elf_frob_file): If group name matches an exported symbol, use that
+ symbol for the signature and ".group" as the section name.
+
+2002-06-06 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * config/tc-sh.c (parse_at): @(symbol,pc) is A_DISP_PC again,
+ but warn about it.
+
+2002-06-06 Daniel Jacobowitz <drow@mvista.com>
+
+ * tc-mips.c (mips_after_parse_args): Always set mips_opts.ase_mips3d
+ and mips_opts.ase_mdmx if they are uninitialized.
+
+2002-06-06 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * gas/config/tc-hppa.c (pa_ip): Replace "L$0\001" with FAKE_LABEL_NAME.
+ (hppa_force_relocation): Check if a stub just before the start symbol
+ of the last call_info is reachable before forcing relocation. Fix
+ typo.
+
+2002-06-04 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * config/tc-mips.c (mips_after_parse_args): New function.
+ (md_begin): Move processing of defaults to mips_after_parse_args.
+ config/tc-mips.h (md_after_parse_args): Define.
+
+2002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * configure.in (sh5*): Set cpu_type to sh64 and endian to big.
+ (sh5le*, sh64le*): Set cpu_type to sh64 and endian to little.
+ (sh5*-*-netbsd*, sh64*-*-netbsd*): New targets.
+ * configure: Regenerate.
+ * config/tc-sh64.c (sh64_target_format): Add support for NetBSD
+ environment.
+
+2002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * config/tc-sh64.h (MD_PCREL_FROM_SECTION): Undef before redefining.
+
+2002-06-04 Alan Modra <amodra@bigpond.net.au>
+
+ * config/obj-elf.c (obj_elf_change_section): Set and check elf
+ linkonce flag. Print all warnings.
+ (obj_elf_section): Parse ",comdat" for groups.
+ (elf_frob_file): Set SEC_LINK_ONCE on COMDAT groups. Check
+ consistency of comdat flag.
+
+2002-06-02 Richard Henderson <rth@redhat.com>
+
+ * config/tc-alpha.c (alpha_adjust_symtab_relocs): Fix thinko
+ with LITERALs without sequence numbers.
+
+2002-06-01 Richard Henderson <rth@redhat.com>
+
+ * config/tc-alpha.c: Move LITUSE constants to "elf/alpha.h".
+ Rename them LITUSE_ALPHA_*.
+
+2002-05-31 Shrinivas Atre <ShrinivasA@kpit.com>
+
+ * config/tc-h8300.c (get_operand): Allow stm.l and ldm.l insns to
+ accept parentheses enclosed register lists.
+
+2002-05-31 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * po/POTFILES.in: Regenerate.
+
+2002-05-31 Graeme Peterson <gp@qnx.com>
+
+ * configure.in: Add i386-*-nto-qnx*.
+ * configure: Regenerate.
+
+2002-05-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (mips_ip): Use unsigned long values for
+ warning output.
+
+2002-05-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (s_cpsetup): Fix initialization of
+ mips_cpreturn_register and mips_cpreturn_offset.
+
+2002-05-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (s_cpsetup): Fix comment.
+
+2002-05-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (md_begin): Add $ra as alias name for $31.
+ (mips_ip): Likewise.
+ (mips16_ip): Likewise.
+ (tc_get_register): Likewise.
+
+2002-05-30 Chris G. Demetriou <cgd@broadcom.com>
+ Ed Satterthwaite <ehs@broadcom.com>
+
+ * config/tc-mips.c (mips_set_options): New "ase_mdmx" member.
+ (mips_opts): Initialize "ase_mdmx" member.
+ (file_ase_mdmx): New variable.
+ (CPU_HAS_MDMX): New macro.
+ (md_begin): Initialize mips_opts.ase_mdmx and file_ase_mdmx
+ based on command line options and configuration defaults.
+ (macro_build): Note in comment that use of MDMX in macros is
+ not currently allowed.
+ (validate_mips_insn): Add support for the "O", "Q", "X", "Y", and
+ "Z" MDMX operand types.
+ (mips_ip): Accept MDMX instructions if mips_opts.ase_mdmx is set,
+ and add support for the "O", "Q", "X", "Y", and "Z" MDMX operand
+ types.
+ (OPTION_MDMX, OPTION_NO_MDMX, md_longopts, md_parse_option):
+ Add support for "-mdmx" and "-no-mdmx" options.
+ (OPTION_ELF_BASE): Move to accommodate new options.
+ (s_mipsset): Support ".set mdmx" and ".set nomdmx".
+ (mips_elf_final_processing): Set MDMX ASE ELF header flag if
+ file_ase_mdmx was set.
+ * doc/as.texinfo: Document -mdmx and -no-mdmx options.
+ * doc/c-mips.texi: Likewise, and document ".set mdmx" and ".set
+ nomdmx" directives.
+
+2002-05-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (OPTION_NO_M7000_HILO_FIX): Rename to
+ OPTION_MNO_7000_HILO_FIX. Add alternate "mno-fix7000"
+ command line switch conforming to gcc conventions.
+ * doc/c-mips.texi: Document -mno-fix7000 instead of no-mfix-7000.
+
+2002-05-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (macro_build_jalr): New Function.
+ (md_begin): NewABI uses big GOTs.
+ (macro_build): Recognize BFD_RELOC_MIPS_GOT_DISP,
+ BFD_RELOC_MIPS_GOT_PAGE, BFD_RELOC_MIPS_GOT_OFST as valid.
+ (load_address): Add some NewABI PIC support.
+ (macro): Likewise.
+ (md_apply_fix): Special handling for BFD_RELOC_MIPS_JALR.
+ (tc_gen_reloc): Don't encode NewABI vtables in REL relocations.
+
+2002-05-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (load_address): Use mips_gp_register instead
+ of hardcoded value. Remove dbl parameter, use HAVE_32BIT_ADDRESSES
+ instead.
+ (macro): Use mips_gp_register instead of hardcoded value.
+
+2002-05-30 Richard Henderson <rth@redhat.com>
+
+ * expr.h (operatorT): Add O_md17..O_md32.
+ * config/tc-alpha.c (O_lituse_tlsgd, O_lituse_tlsldm, O_tlsgd,
+ O_tlsldm, O_gotdtprel, O_dtprelhi, O_dtprello, O_dtprel, O_gottprel,
+ O_tprelhi, O_tprello, O_tprel): New.
+ (USER_RELOC_P, alpha_reloc_op_tag, debug_exp): Include them.
+ (DUMMY_RELOC_LITUSE_TLSGD, DUMMY_RELOC_LITUSE_TLSLDM): New.
+ (LITUSE_TLSGD, LITUSE_TLSLDM): New.
+ (struct alpha_reloc_tag): Add master, saw_tlsgd, saw_tlsld,
+ saw_lu_tlsgd, saw_lu_tlsldm. Make multi_section_p a bit field.
+ (md_apply_fix3): Handle TLS relocations.
+ (alpha_force_relocation, alpha_fix_adjustable): Likewise.
+ (alpha_adjust_symtab_relocs): Sort LITERAL relocs after the
+ associated TLS reloc. Check lituse_tls relocs match up.
+ (emit_insn): Handle TLS relocations.
+ (ldX_op): Remove.
+
+ * doc/c-alpha.texi: Add docs for tls relocations.
+
+2002-05-30 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (mips_gprel_offset): New variable.
+ (s_gpvalue): Use it.
+
+2002-05-30 Diego Novillo <dnovillo@redhat.com>
+
+ * gas/config/tc-d10v.c (check_resource_conflict): Only check
+ write-write conflicts.
+ (md_assemble): Reformat introductory comment.
+ (parallel_ok): Prevent packing only if the first
+ instruction cannot be packed.
+
+2002-05-30 Jason Eckhardt <jle@redhat.com>
+ Tom Rix <trix@redhat.com>
+
+ * config/tc-d10v.c (build_insn): Check for immediates.
+
+2002-05-28 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c: Replace GP in comments by $gp.
+ (mips_big_got): Initialize.
+ (mips_trap): Initialize.
+ (load_address): Use mips_gp_register instead of hardcoded value.
+ Remove dbl parameter, use HAVE_32BIT_ADDRESSES instead.
+ (macro): Use mips_gp_register instead of hardcoded value.
+ (macro2): Change load_address calls.
+ (md_pcrel_from): Comment formatting.
+ (s_cpload): Use mips_gp_register instead of hardcoded value.
+ (s_cprestore): Likewise. Comment formatting.
+ (s_gpword): Fix data type.
+ (s_cpadd): Use mips_gp_register instead of hardcoded value.
+ (nopic_need_relax): Replace GP in comments by $gp.
+ (mips_elf_final_processing): Better comment.
+
+2002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
+
+ * configure.in: Add DLX configuraton
+ * Makefile.am: Add DLX configuraton
+ * configure: Regenerate.
+ * Makefile.in: Regenerate.
+ * config/tc-dlx.c: New file.
+ * config/tc-dlx.h: New files.
+ * NEWS: Mention new support.
+
+2002-05-27 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * config/obj-coff.c (write_object_file): Add missing semicolon.
+
+2002-05-26 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (mips_emit_delays): Replace magic constant for RA
+ by the define. Remove superfluous check of mips_opts.mips16.
+ (append_insn): Likewise. Canonicalize variable increments.
+ (macro_build): Canonicalize variable increments.
+ (macro_build_lui): Likewise.
+ (load_register): Likewise.
+ (load_address): Move pointer initialization.
+ (macro): Move pointer to a more local scope. Canonicalize variable
+ increments. Better comments. Replace magic constant for RA by the
+ define.
+ (macro2): Replace magic constant for RA by the define. Canonicalize
+ variable increments.
+ (mips_ip): Canonicalize variable increments.
+ (mips16_ip): Replace magic constant for RA by the define.
+ (my_getSmallParser): Canonicalize variable increments/decrements.
+ (my_getPercentOp): Likewise.
+ (my_getSmallExpression): Likewise.
+ (s_align): Likewise.
+ (s_mipsset): Likewise.
+ (s_cpsetup): Likewise.
+ (s_insn): Remove superfluous check of mips_opts.mips16.
+ (s_mips_stab): Likewise.
+ (mips_handle_align): Canonicalize variable increments.
+ (s_mips_ent): Likewise.
+ (s_mips_end): Add comment.
+
+2002-05-26 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * configure.in: Use ns32k-*-netbsd* instead of ns32k-pc532-netbsd*.
+ * configure: Regenerate.
+
+2002-05-25 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (OBJS): Depend on ansidecl.h and fopen-same.h.
+ * Makefile.in: Regenerate.
+ * dep-in.sed: Reorder to match OBJS in Makefile.am.
+ * configure.in (ALL_OBJ_DEPS): Add symcat.h when need_bfd.
+ * configure: Regenerate.
+ * as.h: Use #include "" instead of <> for local header files.
+ * flonum-konst.c: Likewise.
+ * flonum-mult.c: Likewise.
+ * gasp.c: Likewise.
+ * listing.c: Likewise.
+ * config/tc-ia64.h: Likewise.
+ * config/tc-v850.h: Likewise.
+
+2002-05-24 TAMURA Kent <kent@netbsd.org>
+
+ * configure.in: Add a target for i386-netbsdpe.
+ * configure: Regenerate.
+
+2002-05-23 Jakub Jelinek <jakub@redhat.com>
+
+ * config/obj-elf.c (elf_common): Renamed from obj_elf_common.
+ (obj_elf_common): Call elf_common.
+ (obj_elf_tls_common): New function.
+ (elf_pseudo_tab): Support .tls_common.
+ (special_sections): Add .tdata and .tbss.
+ (obj_elf_change_section): Set SEC_THREAD_LOCAL for SHF_TLS
+ sections.
+ (obj_elf_parse_section_letters): Support T in section flags (SHF_TLS).
+ (obj_elf_parse_section_letters): Include T in error message.
+ * config/tc-ppc.c (ppc_section_letter): Likewise.
+ * config/tc-alpha.c (alpha_elf_section_letter): Likewise.
+ (tc_gen_reloc): Handle SEC_THREAD_LOCAL the same way as
+ SEC_MERGE.
+ * config/tc-sparc.c (md_apply_fix3): Likewise.
+ * config/tc-i386.c (tc_i386_fix_adjustable): Add TLS relocs.
+ Define them if not BFD_ASSEMBLER.
+ (lex_got): Support @TLSGD, @TLSLDM, @GOTTPOFF, @TPOFF, @DTPOFF
+ and @NTPOFF.
+ (md_apply_fix3): Add TLS relocs.
+ * config/tc-ia64.c (enum reloc_func): Add FUNC_DTP_MODULE,
+ FUNC_DTP_RELATIVE, FUNC_TP_RELATIVE, FUNC_LT_DTP_MODULE,
+ FUNC_LT_DTP_RELATIVE, FUNC_LT_TP_RELATIVE.
+ (pseudo_func): Support @dtpmod(), @dtprel() and @tprel().
+ (ia64_elf_section_letter): Include T in error message.
+ (md_begin): Support TLS operators.
+ (md_operand): Likewise.
+ (ia64_gen_real_reloc_type): Support TLS relocs.
+ * write.c (adjust_reloc_syms): Don't change symbols in
+ SEC_THREAD_LOCAL sections to STT_SECTION + addend.
+
+2002-05-23 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * config/tc-arm.c (md_apply_fix3): For the Thumb BLX reloc
+ round the relocation up rather than down.
+
+2002-05-23 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * config/obj-coff.c (obj_coff_section): Silently ignore an 'a'
+ flag.
+ * doc/as.texinfo: Document that the COFF version of .section
+ ignores the 'a' flag.
+
+2002-05-23 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-alpha.c (assemble_tokens): Protect use of
+ ALPHA_RELOC_TABLE with #ifdef RELOC_OP_P.
+
+ * write.c (size_seg): Check adjustment to last frag.
+ (SUB_SEGMENT_ALIGN): If HANDLE_ALIGN defined, pad out last frag to
+ section alignment.
+ * config/obj-coff.c (SUB_SEGMENT_ALIGN): Likewise.
+ * config/obj-ieee.c (SUB_SEGMENT_ALIGN): Likewise.
+ (write_object_file): Invoke md_do_align if available, and use
+ frag_align_code on text sections.
+ * config/obj-vms.h (SUB_SEGMENT_ALIGN): Now two args.
+ * config/tc-m88k.h (SUB_SEGMENT_ALIGN): Likewise.
+ * config/tc-ppc.h (SUB_SEGMENT_ALIGN): Likewise.
+ * config/tc-sh.h (SUB_SEGMENT_ALIGN): Likewise.
+ * config/tc-i386.h (SUB_SEGMENT_ALIGN): Likewise. Define for
+ BFD_ASSEMBLER too.
+
+2002-05-22 H.J. Lu <hjl@gnu.org>
+
+ * dwarf2dbg.c (dwarf2_directive_loc): Call listing_source_file
+ for source file.
+
+2002-05-22 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * config/tc-arm.c (arm_s_section): Enable for COFF builds as well
+ as ELF builds.
+
+2002-05-22 H.J. Lu <hjl@gnu.org>
+
+ * dwarf2dbg.c (dwarf2_emit_insn): Emit only one line symbol
+ for one .loc for compiler.
+
+2002-05-22 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (macro): Relax warning, it's toot strict for
+ embedded-PIC.
+
+2002-05-22 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (macro2): Add 64 bit drol, dror macros.
+ Optimize the rotate by zero case.
+
+2002-05-21 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * configure.in: Remove accidental enabling of bfd_gas=yes for
+ sh-coff targets.
+ * configure: Regenerate.
+
+2002-05-18 Kazu Hirata <kazu@cs.umass.edu>
+
+ * app.c: Fix formatting.
+ * as.c: Likewise.
+ * ehopt.c: Likewise.
+ * expr.c: Likewise.
+ * input-file.c: Likewise.
+ * listing.c: Likewise.
+ * macro.h: Likewise.
+ * stabs.c: Likewise.
+ * symbols.c: Likewise.
+
+2002-05-17 Alan Modra <amodra@bigpond.net.au>
+
+ * config/obj-generic.c: Delete file.
+ * config/obj-generic.h: Likewise.
+
+2002-05-16 Marek Michalkiewicz <marekm@amelek.gda.pl>
+
+ * config/tc-avr.c (mcu_types): Update for new devices.
+
+2002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (macro): Warn about wrong la/dla use.
+
+2002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc_mips.c (s_cpsetup): Fix completely bogus code which had
+ worked sometimes by accident. Fix copy&paste comment.
+
+2002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (md_begin): Fix .reginfo and .MIPS.option section
+ alignment for NewABI. Let n32 use .reginfo. Remove useless casts.
+ (mips_elf_final_processing): Let n32 use .reginfo.
+
+2002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (append_insn): Fix too small range of variable.
+
+2002-05-14 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * config/tc-arm.c (arm_cleanup): Remove redundant call to
+ listing_prev_line().
+
+2002-05-13 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * config/tc-arm.c (md_assemble): Remove redundant call to
+ listing_prev().
+
+ * dwarf2dbg.c (dwarf2_emit_insn): Do not reset
+ loc_directive_seen.
+
+ * stabs.c (s_stab_generic): Fix grammatical error in warning
+ message.
+
+2002-05-13 Alan Modra <amodra@bigpond.net.au>
+
+ * write.c (subsegs_finish): Don't specially align last subseg.
+
+2002-05-11 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * stabs.c (s_stab_generic): Warn about a description field that is
+ too big.
+
+ * config/obj-coff.c: Fix compile time warnings when compiling
+ without BFD_ASSEMBLER defined.
+ Fix formatting.
+
+ * config/tc-sh.c (md_pcrel_from): Define for use with sh-hms
+ target.
+ (md_pcrel_from_section): Use md_pcrel_from().
+
+2002-05-11 Bruno Haible <bruno@clisp.org>
+
+ * dwarf2dbg.c (dwarf2_emit_insn): Use the 'current' struct filled
+ by dwarf2_directive_loc, instead of calling dwarf2_where.
+
+2002-05-11 Kazu Hirata <kazu@cs.umass.edu>
+
+ * config/obj-coff.h: Fix formatting.
+ * config/tc-mcore.c: Likewise.
+ * config/tc-mn10300.c: Likewise.
+ * config/tc-openrisc.c: Likewise.
+ * config/tc-or32.c: Likewise.
+ * config/tc-pdp11.c: Likewise.
+ * config/tc-ppc.c: Likewise.
+ * config/tc-ppc.h: Likewise.
+ * config/tc-sh64.c: Likewise.
+ * config/tc-sh.c: Likewise.
+ * config/tc-tic54x.c: Likewise.
+ * config/tc-xstormy16.c: Likewise.
+ * config/tc-xstormy16.h: Likewise.
+
+2002-05-09 Kazu Hirata <kazu@cs.umass.edu>
+
+ * config/obj-coff.c: Fix formatting.
+ * config/obj-elf.c: Likewise.
+ * config/tc-alpha.c: Likewise.
+ * config/tc-arm.c: Likewise.
+ * config/tc-d10v.c: Likewise.
+ * config/tc-d30v.c: Likewise.
+ * config/tc-h8300.c: Likewise.
+ * config/tc-hppa.c: Likewise.
+
+2002-05-09 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-i386.c (md_estimate_size_before_relax) Don't lose
+ reloc when no_cond_jump_promotion.
+
+2002-05-08 Jim Wilson <wilson@redhat.com>
+
+ * config/tc-i960.c (md_estimate_size_before_relax): Return size of
+ current variable part of frag.
+
+2002-05-08 Kazu Hirata <kazu@cs.umass.edu>
+
+ * config/tc-mmix.c: Fix formatting.
+ * config/tc-mmix.h: Likewise.
+
+2002-05-08 Alan Modra <amodra@bigpond.net.au>
+
+ * configure: Regenerate.
+
+2002-05-07 Kazu Hirata <kazu@cs.umass.edu>
+
+ * config/tc-m68k.c: Fix formatting.
+
+2002-05-07 Federico G. Schwindt <fgsch@olimpo.com.br>
+
+ * Makefile.am: Honour DESTDIR.
+ * Makefile.in: Regenerate.
+
+2002-05-06 Kazu Hirata <kazu@cs.umass.edu>
+
+ * config/tc-ia64.c: Fix formatting.
+ * config/tc-ia64.h: Likewise.
+
+2002-05-04 Kazu Hirata <kazu@cs.umass.edu>
+
+ * config/tc-mips.c: Fix formatting.
+ * config/tc-s390.c: Likewise.
+ * config/tc-s390.h: Likewise.
+
+2002-05-03 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-s390.c (md_gather_operands): Emit dwarf2 line-number
+ information for instructions.
+
+2002-05-02 Kazu Hirata <kazu@cs.umass.edu>
+
+ * as.h: Fix formatting.
+ * cgen.c: Likewise.
+ * cgen.h: Likewise.
+ * dwarf2dbg.c: Likewise.
+ * frags.h: Likewise.
+ * gasp.c: Likewise.
+ * macro.c: Likewise.
+ * read.c: Likewise.
+ * stabs.c: Likewise.
+ * symbols.c: Likewise.
+
+2002-05-02 Alan Modra <amodra@bigpond.net.au>
+
+ * app.c (mri_pseudo): Only declare for TC_M68K.
+
+ * config/tc-ppc.c (mapping): Map sectoff to BFD_RELOC_16_BASEREL.
+ (ppc_elf_validate_fix): Replace BFD_RELOC_32_BASEREL with
+ BFD_RELOC_16_BASEREL.
+ (md_assemble): Likewise.
+ (md_apply_fix3): Likewise.
+
+2002-05-02 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * config/tc-arm.c (thumb_add_sub): Do not convert a subtract of
+ zero into an add of zero - it is not the same.
+
+2002-05-01 Arati Dikey <aratid@kpit.com>
+
+ * tc-sh.c (get_specific): Generate warning if the same
+ destination register is used in parallel instructions.
+
+2002-05-01 Andrew Macleod <amacleod@cygnus.com>
+
+ * config/tc-i386.c (extra_symbol_chars): Add '[' to the list.
+
+2002-05-01 Alan Modra <amodra@bigpond.net.au>
+
+ * write.c (cvt_frag_to_fill): Set fr_offset to zero on .org
+ backwards to prevent cascading errors.
+
+2002-04-30 Mark Mitchell <mark@codesourcery.com>
+
+ * configure.in: Add support for powerpc-*-windiss.
+ * configure: Regenerated.
+
+2002-04-28 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-s390.c (md_parse_option): Formatting.
+
+ * config/tc-i386.c: Formatting fixes, add missing space in error
+ message.
+
+2002-04-24 Christian Groessler <chris@groessler.org>
+
+ * config/tc-z8k.c (build_bytes): Add support for new cases:
+ CLASS_IGNORE and ARG_NIM4.
+ (md_assemble): Prevent destruction of input_line_pointer if
+ get_operands returns failure.
+
+2002-04-24 Chris G. Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (macro_build): Do _not_ allow MIPS-3D
+ instructions to be generated by macros.
+
+2002-04-24 Andreas Schwab <schwab@suse.de>
+
+ * config/tc-i386.c (output_jump, output_disp)
+ (md_estimate_size_before_relax): Don't set fx_pcrel_adjust any
+ more.
+ (md_apply_fix3): Remember addend value for rela relocations.
+ (tc_gen_reloc): Correctly compute pc-relative relocation addend.
+
+2002-04-22 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (macro_build): Add close-parenthesis missing
+ from previous change.
+
+2002-04-22 Eric Christopher <echristo@redhat.com>
+
+ * config/tc-mips.c (macro_build): Add warning if macro instructions
+ are expanded into a branch delay slot.
+
+2002-04-17 Geoffrey Keating <geoffk@redhat.com>
+
+ * dwarf2dbg.c (dwarf2_gen_line_info): Do emit duplicate line
+ numbers, gdb relies on them to detect the start of the prologue.
+
+2002-04-17 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * config/tc-s390.c (tc_s390_fix_adjustable): Prevent adjustments to
+ symbols in merge sections.
+
+2002-04-16 Alan Modra <amodra@bigpond.net.au>
+
+ * as.c (main): Don't reference _bfd_chunksize.
+
+2002-04-15 Tom Rix <trix@redhat.com>
+
+ * config/tc-d10v.c (d10v_fix_adjustable): Prevent adjustments to
+ symbols in merge sections.
+
+2002-04-11 Richard Sandiford <rsandifo@redhat.com>
+
+ * doc/invoke.texi (TC_LARGEST_EXPONENT_IS_NORMAL): Document.
+ * config/atof-ieee.c (TC_LARGEST_EXPONENT_IS_NORMAL): Add an
+ argument for the precision.
+ (gen_to_words): Update accordingly.
+
+2002-04-10 Alan Modra <amodra@bigpond.net.au>
+
+ * as.c (parse_args <OPTION_VERSION>): Use VERSION is
+ BFD_VERSION_STRING unavailable.
+ * config/tc-i386.c (INLINE): Define (for non-BFD assembler).
+
+2002-04-09 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * config/tc-sh.h (TC_FIX_ADJUSTABLE): Disable adjusting if
+ symbol_used_in_reloc_p is true.
+
+ * config/tc-sh.c (md_apply_fix3): Don't zero relocations on big
+ endian hosts.
+
+2002-04-04 Alan Modra <amodra@bigpond.net.au>
+
+ * dep-in.sed: Cope with absolute paths.
+ * Makefile.am (dep.sed): Subst TOPDIR.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2002-04-04 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (mips16_macro_build): Cast type mismatch.
+ (mips_ip): Remove unused variable.
+ (md_apply_fix3): Cast signed/unsignes mismatches. Replace
+ unsigned char with bfd_byte.
+ (s_file): Remove unused variable.
+ (s_mips_ent): Likewise.
+
+2002-04-03 Tom Rix <trix@redhat.com>
+
+ * config/tc-d10v.c (d10v_insert_operand): Fix warning in as_bad_where.
+ (build_insn): Same.
+ (find_opcode): Fix warning in as_warn.
+ * config/tc-d10v.h: Update Copyright.
+
+2002-04-03 Alan Matsuoka <alanm@redhat.com>
+ Tom Rix <trix@redhat.com>
+
+ From Jeff Knaggs <jknaggs@redhat.com>
+ * config/tc-d10v.c (check_resource_conflict): New function to
+ check for resource conflicts.
+
+ From Jason Eckhardt <jle@redhat.com>
+ * config/tc-d10v.c (build_insn): Check for unresolved imm4 or
+ imm3 fields.
+ * config/tc-d10v.c (find_opcode): Emit a warning if one of the
+ reserved control registers is used.
+ * config/tc-d10v.c (build_insn): Check for unresolved imm4 or
+ imm3 fields.
+
+ From 2001-03-28 Diego Novillo <dnovillo@redhat.com>
+ * tc-d10v.c (parallel_ok): Prevent packing only if the first
+ instruction cannot be packed.
+
+ From 2001-03-30 Diego Novillo <dnovillo@redhat.com>
+ * gas/config/tc-d10v.c (check_resource_conflict): Only check
+ write-write conflicts.
+ (md_assemble): Reformat introductory comment.
+ * opcodes/d10v-opc.c (d10v_opcodes): `btsti' does not modify its
+ arguments.
+
+2002-04-03 Alan Modra <amodra@bigpond.net.au>
+
+ * symbols.c (resolve_symbol_value <O_uminus, O_bit_not,
+ O_logical_not>): Derive final_seg from add_symbol.
+ <O_multiply..O_logical_or>: More final_seg twiddles.
+
+2002-04-01 Jessica Han <jessica@cup.hp.com>
+
+ * config/tc-ia64.c (ia64_cons_fix_new): Handle 8 byte iplt reloc
+ in 32-bit mode.
+
+2002-03-27 Andreas Schwab <schwab@suse.de>
+
+ * config/tc-i386.c (output_jump): Set fx_pcrel_adjust to size of
+ field for pc-relative fixups.
+ (output_disp): Likewise.
+ (md_estimate_size_before_relax): Likewise.
+ (tc_gen_reloc): Subtract fx_pcrel_adjust instead of fx_size for
+ pc-relative fixups in 64bit mode.
+
+2002-03-22 Alan Modra <amodra@bigpond.net.au>
+
+ * config/te-aix5.h: Typo fix.
+
+2002-03-21 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * doc/Makefile.in: Regenerate.
+
+2002-03-20 Albert Chin-A-Young <china@thewrittenword.com>
+
+ * config/tc-arm.c (vfp_dp_reg_required_here): Fix typo
+ (vfp_sp_reg_pos -> vfp_dp_reg_pos).
+
+2002-03-18 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-mips.c (md_estimate_size_before_relax): Do not modify
+ the EXTENDED bit here; report the estimate according to the
+ current size.
+
+2002-03-18 Tom Rix <trix@redhat.com>
+
+ * configure.in: Add AIX 5 support.
+ * config/tc-ppc.c (ppc_target_format): Add AIX 5 64 bit target.
+ * config/te-aix5.h: New file. AIX 5 support.
+ * configure: Regenerate.
+
+2002-03-18 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/fr.po: Updated version.
+
+2002-03-16 Andreas Jaeger <aj@suse.de>
+
+ * doc/c-mips.texi (Machine Dependencies): Add new node.
+
+2002-03-15 Chris G. Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (mips_set_options): New "ase_mips3d" member.
+ (mips_opts): Initialize "ase_mips3d" member.
+ (file_ase_mips3d): New variable.
+ (CPU_HAS_MIPS3D): New macro.
+ (md_begin): Initialize mips_opts.ase_mips3d and file_ase_mips3d
+ based on command line options and configuration defaults.
+ (macro_build, mips_ip): Accept MIPS-3D instructions if
+ mips_opts.ase_mips3d is set.
+ (OPTION_MIPS3D, OPTION_NO_MIPS3D, md_longopts, md_parse_option):
+ Add support for "-mips3d" and "-no-mips3d" options.
+ (OPTION_ELF_BASE): Move to accommodate new options.
+ (s_mipsset): Support ".set mips3d" and ".set nomips3d".
+ (mips_elf_final_processing): Add a comment indicating that a
+ MIPS-3D ASE ELF header flag should be set, when one exists.
+ * doc/as.texinfo: Document -mips3d and -no-mips3d options.
+ * doc/c-mips.texi: Likewise, and document ".set mips3d" and ".set
+ nomips3d" directives.
+
+2002-03-14 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * config/tc-mmix.c (md_estimate_size_before_relax): Don't consider
+ a weak symbol in same section to be within reach.
+
+2002-03-13 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/fr.po: Updated version.
+
+2002-03-12 Andreas Schwab <schwab@suse.de>
+
+ * config/tc-ia64.c (fixup_unw_records): Clear region when seeing a
+ body record so that an error is given for misplaced .save
+ pseudo-ops.
+
+2002-03-09 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-i386.h (REX_OPCODE): Define.
+ (REX_MODE64, REX_EXTX, REX_EXTY, REX_EXTZ): Define.
+ (rex_byte): typedef to int.
+ * config/tc-i386.c: Group prototypes and vars together.
+ Formatting fixes. Remove occurrences of "register" keyword.
+ (true): Delete.
+ (false): Delete.
+ (mode_from_disp_size): Add INLINE keyword to prototype.
+ (fits_in_signed_byte): Likewise.
+ (fits_in_unsigned_byte): Likewise.
+ (fits_in_unsigned_word): Likewise.
+ (fits_in_signed_word): Likewise.
+ (fits_in_unsigned_long): Likewise.
+ (fits_in_signed_long): Likewise.
+ (type_names): Constify.
+ (intel_float_operand): Constify param.
+ (add_prefix): Use REX_OPCODE.
+ (md_assemble): Likewise. Modify for changed rex_byte.
+ (parse_insn): Split out of md_assemble.
+ (parse_operands): Likewise.
+ (swap_operands): Likewise.
+ (optimize_imm): Likewise.
+ (optimize_disp): Likewise.
+ (match_template): Likewise.
+ (check_string): Likewise.
+ (process_suffix): Likewise.
+ (check_byte_reg): Likewise.
+ (check_long_reg): Likewise.
+ (check_qword_reg): Likewise.
+ (check_word_reg): Likewise.
+ (finalize_imm): Likewise.
+ (process_operands): Likewise.
+ (build_modrm_byte): Likewise.
+ (output_insn): Likewise.
+ (output_branch): Likewise.
+ (output_jump): Likewise.
+ (output_interseg_jump): Likewise.
+ (output_disp): Likewise.
+ (output_imm): Likewise.
+
+2002-03-07 Daniel Jacobowitz <drow@mvista.com>
+
+ * doc/as.texinfo: Wrap @menu in @ifnottex, not @ifinfo.
+
+2002-03-06 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-i386.c (tc_gen_reloc): Don't attempt to handle 8 byte
+ relocs except when BFD64.
+
+ * write.c (number_to_chars_bigendian): Don't abort when N is
+ larger than sizeof (VAL).
+ (number_to_chars_littleendian): Likewise.
+
+2002-03-05 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * config/tc-hppa.c (md_apply_fix3): Add cast.
+ (hppa_fix_adjustable): Adjust list of selectors using e_lrsel and
+ e_rrsel.
+
+2002-03-05 Paul Koning <pkoning@equallogic.com>
+
+ * tc-pdp11.c: Use VAX float format support for PDP-11 target.
+ (parse_ac5): New function for parsing float regs in float operand.
+ (parse_expression): Remove attempt to make literals be octal.
+ (parse_op_no_deferred): Support float literals.
+ (parse_op): Reject attempts to refer to float regs.
+ (parse_fop): New function, like parse_op but for float operand.
+ (md_assemble): Add cases to parse float operands. Also fix
+ IMM3, IMM6, IMM8 cases to pick up the operand from the right spot.
+
+2002-03-04 H.J. Lu <hjl@gnu.org>
+
+ * config/obj-elf.c (special_section): Add .init_array,
+ .fini_array and .preinit_array.
+
+ * config/tc-ia64.h (ELF_TC_SPECIAL_SECTIONS): Remove
+ .init_array and .fini_array.
+
+2002-03-01 Jakub Jelinek <jakub@redhat.com>
+
+ * config/obj-elf.c (elf_copy_symbol_attributes): Don't copy
+ visibility.
+ (obj_frob_symbol): Copy visibility.
+
+2002-02-28 Jakub Jelinek <jakub@redhat.com>
+
+ * config/tc-alpha.c (s_alpha_text): Use obj_elf_text for OBJ_ELF, not
+ s_text.
+ (s_alpha_data): Use obj_elf_data for OBJ_ELF, not s_data.
+
+2002-02-27 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/es.po: Updated.
+
+2002-02-26 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (mips_need_elf_addend_fixup): For embedded-PIC
+ only, undo the changes made on 2001-06-08, with the
+ effect being that common or extern symbols are
+ adjusted for embedded-PIC, but weak symbols are not.
+ (md_estimate_size_before_relax: Likewise, with the effect
+ that extern symbols are treated the same as weak symbols
+ only if not embedded-PIC.
+ (mips_fix_adjustable) Likewise, with the effect that
+ weak or extern symbols are not adjusted for embedded-PIC.
+ (md_apply_fix3): Tweak so that the case where value is zero
+ is handled more correctly for embedded-PIC code.
+
+2002-02-26 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * doc/as.texinfo (Overview): Add missing @ifset IA64
+
+ * configure.in (LINGUAS): Add es.po.
+ * configure: Regenerate.
+ * po/es.po: New file.
+
+2002-02-25 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (set_at): Fix handling of 64bit register loads.
+ (macro): Likewise. Fix la/dla address expansions for EMBEDDED_PIC
+ and NO_PIC cases. Code cleanup.
+ (macro2): Fix handling of 64bit register loads.
+
+2002-02-25 David Mosberger <davidm@hpl.hp.com>
+
+ * doc/as.texinfo: Add entry for IA64.
+ * doc/c-ia64.texi: New file.
+
+2002-02-25 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-hppa.c: Update copyright date.
+
+ * doc/c-ppc.texi (PowerPC-Opts): Add -mpower4, -maltivec and -m7400
+ Remove references to chip manufacturers.
+ * config/tc-ppc.c (md_parse_option): Handle -mpower4 option.
+ Correct comments.
+ (md_show_usage): Remove references to chip manufacturers. Mention
+ -mpower4.
+ (md_begin): Test power4 opcode flag bits.
+
+2002-02-22 David Mosberger <davidm@hpl.hp.com>
+
+ * config/tc-ia64.c (dot_restore): Issue error message of epilogue
+ count exceeds prologue count.
+ (md_show_usage): Describe -mconstant-gp and -mauto-pic.
+ (unwind.label_prologue_count): New member.
+
+ Based on a patch by Hans Boehm <hboehm@hpl.hp.com>:
+
+ (get_saved_prologue_count): New function.
+ (save_prologue_count): New function.
+ (free_saved_prologue_count): New function.
+ (dot_label_state): Record state label by calling save_prologue_count().
+ (dot_copy_state): Restore prologue count by calling
+ get_saved_prologue_count().
+ (generate_unwind_image): Free up list of saved prologue
+ counts by calling free_saved_prologue_counts().
+
+2002-02-22 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * config/tc-tic54x.c: Add missing prototypes and remove ANSI style
+ function declarations.
+
+2002-02-21 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * NEWS: Note that GASP is now deprecated.
+ * Makefile.am: Do not build gasp-new by default.
+ * Makefile.in: Regenerate.
+ * doc/Makefile.am: Do not install gasp.info.
+ * doc/Makefile.in: Regenerate.
+ * gas/gasp.texi: Note that gasp is now deprecated.
+
+2002-02-20 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * NEWS: Mark 2.12 branch.
+
+2002-02-19 Tom Tromey <tromey@redhat.com>
+
+ * config/tc-xstormy16.h (DWARF2_LINE_MIN_INSN_LENGTH): Define.
+
+2002-02-19 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * config/tc-mips.c (md_parse_option): Complain about invalid -mabi
+ option input.
+
+2002-02-19 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * config/tc-s390.c (md_parse_option): Add switches -m31 and -m64.
+ Make bit size independent of architecture switch.
+ (md_begin): Add warning for -m64 with -Aesa.
+ (s390_md_end): Use renamed architecture defines.
+
+2002-02-18 Daniel Jacobowitz <drow@mvista.com>
+
+ * config/obj-coff.h: Check !target_big_endian, not shl, for coff-sh.
+
+2002-02-16 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * doc/as.texinfo (Machine Dependencies): Fix typo: MMIX used
+ instead of CRIS.
+
+2002-02-15 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (md_estimate_size_before_relax): Really
+ make sure we treat weak like extern only for ELF. (Fixes
+ patch from 2001-07-25.)
+
+2002-02-15 Ben Elliston <bje@redhat.com>
+
+ * doc/as.texinfo: Add duplicate directory entry so that "info gas"
+ works as expected.
+
+2002-02-15 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * NEWS: Mention support for MMIX.
+
+2002-02-13 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (mips_need_elf_addend_fixup): Restructure into
+ a sequence of indpendent 'if' statements for easier debugging
+ and future modification.
+
+2002-02-13 Matt Fredette <fredette@netbsd.org>
+
+ * config/tc-m68k.c (md_show_usage): No longer display a
+ hard-coded "68020" for the default CPU, instead display the
+ canonical name of the true, configured default CPU.
+ (m68k_elf_final_processing): Mark objects for sub-68020
+ CPUs with the new EF_M68000 flag.
+
+2002-02-13 Andreas Schwab <schwab@suse.de>
+
+ * config/tc-i386.c (tc_i386_fix_adjustable): Don't adjust
+ pc-relative relocations to merge sections in 64-bit mode.
+
+2002-02-13 Ben Elliston <bje@redhat.com>
+
+ * NEWS: Document floating point number handling in gasp.
+ * gasp.c: Include <assert.h> and "xregex.h".
+ (is_flonum): New function.
+ (chew_flownum): Likewise.
+ (change_base): Consume flonums from the input, where possible.
+ * doc/gasp.texi (Constants): Document floating point numbers.
+
+2002-02-12 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * config/tc-hppa.c (hppa_fix_adjustable): Don't adjust final types
+ that implicitly use LR and RR selectors.
+
+2002-02-12 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-mn10300.c (other_registers): Added `epsw'. Mark `pc'
+ and `epsw' as available on AM33 and above only.
+ (other_register_name): Add logic to handle machine type encoded in
+ reg_number.
+
+2002-02-11 Tom Rix <trix@redhat.com>
+
+ * config/tc-ppc.c (md_apply_fix3): Check for insert fop invalid for
+ xcoff64.
+
+2002-06-11 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-sparc.c (U0x80000000, U0xffffffff): New constants.
+ Use all over.
+
+2002-02-11 Jan Hubicka <jh@suse.cz>
+
+ * i386.c (md_assemble): Support 32bit address prefix.
+ (i386_displacement): Likewise.
+ (i386_index_check): Accept 32bit addressing in 64bit mode.
+
+2002-02-11 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-sh.c (dot): Removed unused function.
+
+2002-02-11 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: "make dep-am".
+ * Makefile.in: Regenerate.
+ * aclocal.m4: Regenerate.
+ * config.in: Regenerate.
+ * configure: Regenerate.
+ * doc/Makefile.in: Regenerate.
+
+2002-02-10 Richard Henderson <rth@redhat.com>
+
+ * doc/c-alpha.texi: New file.
+ * doc/Makefile.am (CPU_DOCS): Add it.
+ * doc/all.texi, doc/as.texinfo: Add hooks for Alpha.
+
+2002-02-09 Richard Henderson <rth@redhat.com>
+
+ * config/tc-alpha.c (O_samegp): New.
+ (USER_RELOC_P): Include it.
+ (alpha_reloc_op_tag, debug_exp, find_macro_match): Add it.
+ (md_apply_fix3): Handle BFD_RELOC_ALPHA_BRSGP.
+ (alpha_force_relocation, alpha_fix_adjustable): Likewise.
+ (alpha_validate_fix): New.
+ * config/tc-alpha.h (TC_VALIDATE_FIX): New.
+
+2002-02-09 Hans-Peter Nilsson <hp@axis.com>
+
+ * doc/c-cris.texi: New.
+ * doc/all.texi: @set CRIS.
+ * doc/as.texinfo: Ditto. Add CRIS gas manpage option overview.
+ Include c-cris.texi.
+ * doc/Makefile.am (CPU_DOCS): Add c-cris.texi
+ * doc/Makefile.in: Regenerate.
+
+2002-02-08 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (IS_SEXT_32BIT_NUM): New macro to
+ determine if a number is a sign-extended 32-bit number.
+ (load_register): Use IS_SEXT_32BIT_NUM.
+ (macro): Check if load/store macro handling is using a
+ constant 32-bit address on 64-bit address systems, and if
+ so optimize the generation of that address.
+
+2002-02-08 Richard Henderson <rth@redhat.com>
+
+ * config/tc-alpha.c (alpha_force_relocation): Don't assert that
+ we've eliminated all foreign relocation types yet.
+ (alpha_fix_adjustable): Likewise.
+
+2002-02-08 Alexandre Oliva <aoliva@redhat.com>
+
+ Contribute sh64-elf.
+ 2002-02-08 Alexandre Oliva <aoliva@redhat.com>
+ Stephen Clarke <Stephen.Clarke@st.com>
+ * doc/c-sh64.texi: Fix citation of SH64 architecture manual.
+ 2002-01-31 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-sh.c (md_relax_table): Added default sizes for
+ non-PC-relative UNDEF_MOVI, and relaxation sequences for
+ MOVI_16, MOVI_32 and MOVI_48.
+ * config/tc-sh64.c (shmedia_md_apply_fix3): Fix warning.
+ (shmedia_md_convert_frag): Handle non-PC-relative UNDEF_MOVI
+ and MOVI_16.
+ (shmedia_md_estimate_size_before_relax): Remove redundant
+ blocks. Set fragP->fr_var even if relaxation type unchanged.
+ Retain UNDEF_MOVI until expression decays to number.
+ 2002-01-24 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-sh64.c (shmedia_init_reloc): Handle new SHmedia PIC
+ relocation types. Take fixP->fx_addnumber into account too.
+ (shmedia_md_apply_fix): Likewise.
+ (shmedia_md_convert_frag): Likewise.
+ (shmedia_build_Mytes): Likewise.
+ (sh64_consume_datalabel): Complain about nested datalabel.
+ Support PIC relocs. Call sh_parse_name.
+ * config/tc-sh64.h (TC_RELOC_RTSYM_LOC_FIXUP): Extend definition
+ in tc-sh.h to SHmedia reloc types.
+ * config/tc-sh.c (SH64PCRELPLT, MOVI_PLT, MOVI_GOTOFF,
+ MOVI_GOTPC): New relaxation constants.
+ (md_relax_table): Introduce relaxation directives for PIC-related
+ constants.
+ (sh_PIC_related_p): Handle datalabel.
+ (sh_check_fixup): Choose SH5 PIC relocations.
+ (sh_cons_fix_new): Added BDF_RELOC_64.
+ (md_apply_fix3, sh_parse_name): Handle GOTPLT.
+ 2002-01-18 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-sh64.c (sh64_max_mem_for_rs_align_code): If the
+ current ISA is SHmedia, get 7 bytes.
+ 2001-11-28 Nick Clifton <nickc@cambridge.redhat.com>
+ * config/tc-sh.c (md_apply_fix3): Treat shmedia_md_apply_fix3 as a
+ void function.
+ * config/tc-sh64.c (shmedia_apply_fix): Rename to
+ shmedia_apply_fix3 and make void.
+ 2001-05-17 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-sh64.c (s_sh64_abi): Remove unused arguments passed to
+ as_bad.
+ 2001-04-12 Alexandre Oliva <aoliva@redhat.com>
+ * config/tc-sh64.h (md_parse_name): Take &c as argument.
+ 2001-03-14 DJ Delorie <dj@redhat.com>
+ * doc/Makefile.am (CPU_DOCS): Added c-sh64.texi
+ * doc/Makefile.in(CPU_DOCS): Ditto.
+ * doc/c-sh64.texi: New file.
+ * doc/as.texinfo: Add SH64 support.
+ 2001-03-13 DJ Delorie <dj@redhat.com>
+ * config/tc-sh64.c (shmedia_get_operands): Rename A_RESV_Fx to
+ A_REUSE_PREV so that its purpose is more obvious.
+ (shmedia_build_Mytes): Ditto.
+ 2001-03-07 DJ Delorie <dj@redhat.com>
+ * config/tc-sh64.c (sh64_vtable_entry): New, strip datalabels
+ before processing.
+ (sh64_vtable_inherit): Ditto.
+ (strip_datalabels): New, strip "datalabel" from given line.
+ * config/tc-sh.c (md_pseudo_table): Add sh64-specific vtable
+ pseudos.
+ 2001-03-06 Hans-Peter Nilsson <hpn@cygnus.com>
+ * config/tc-sh64.c (shmedia_md_assemble): Move dwarf2_emit_insn
+ call ...
+ (shmedia_build_Mytes): ... to here.
+ 2001-03-06 DJ Delorie <dj@redhat.com>
+ * config/tc-sh.c: Remove sh64-specific uaquad now that there
+ is a generic one.
+ 2001-01-21 Hans-Peter Nilsson <hpn@cygnus.com>
+ * config/tc-sh64.h (DWARF2_LINE_MIN_INSN_LENGTH): Override.
+ * config/tc-sh64.c (shmedia_md_assemble): Offset recorded insn
+ address by one in call to dwarf2_emit_insn.
+ 2001-01-13 Hans-Peter Nilsson <hpn@cygnus.com>
+ Implement ".abi" pseudo and correct .cranges descriptors. Correct
+ alignment handling broken by imported changes.
+ * config/tc-sh64.h (HANDLE_ALIGN): Override definition in tc-sh.h.
+ (sh64_handle_align): Declare.
+ (MAX_MEM_FOR_RS_ALIGN_CODE): Override definition in tc-sh.h.
+ (sh64_max_mem_for_rs_align_code): Declare.
+ (enum sh64_isa_values): Moved here from tc-sh64.c.
+ (md_do_align): Define.
+ (sh64_do_align): Declare.
+ (struct sh64_tc_frag_data): New.
+ (TC_FRAG_TYPE): Change to struct sh64_tc_frag_data. Users
+ changed.
+ (TC_FRAG_INIT): Change to set new datatype.
+ (struct sh64_segment_info_type): Rename member
+ last_flushed_location to last_contents_mark. All users changed.
+ (md_elf_section_change_hook, TC_CONS_FIX_NEW): Do not define.
+ (shmedia_elf_new_section, sh64_tc_cons_fix_new): Do not prototype.
+ * config/tc-sh.c (md_pseudo_table): Add ".abi".
+ (sh_elf_cons) [HAVE_SH64]: Call sh64_update_contents_mark instead
+ of unsetting seen_insn.
+ (md_assemble) [HAVE_SH64] <before new SHcompact sequence>: Also
+ call sh64_update_contents_mark.
+ (sh_handle_align): Remove HAVE_SH64-conditioned code.
+ * config/tc-sh64.c (sh64_isa_mode): Correct type from boolean to
+ enum sh64_isa_values.
+ (sh64_set_contents_type): Drop segT parameter. All callers changed.
+ (emitting_crange): Boolean guard moved to file scope from function
+ scope in sh64_set_contents_type.
+ (s_sh64_abi): New.
+ (sh64_update_contents_mark): New; most split out from
+ sh64_flush_pending_output.
+ (shmedia_md_end): Call sh64_update_contents_mark. Set
+ sh64_isa_mode to sh64_isa_sh5_guard unless sh64_isa_unspecified.
+ (sh64_do_align): New function.
+ (sh64_max_mem_for_rs_align_code): New function.
+ (sh64_handle_align): Rename from shmedia_do_align. Make
+ non-static. Add head comment. Emit zero bytes for n bytes modulo
+ four. Change return-type to void.
+ (shmedia_elf_new_section): Remove.
+ (shmedia_md_assemble): Call sh64_update_contents_mark.
+ (s_sh64_mode): Ditto. Do not call md_flush_pending_output. Make
+ new frag. Call sh64_update_contents_mark after making the new
+ frag.
+ (sh64_flush_pending_output): Just call sh64_update_contents_mark
+ and sh_flush_pending_output.
+ (sh64_flag_output): Also call md_flush_pending_output, but add
+ condition on not emitting_crange.
+ (sh64_tc_cons_fix_new): Remove.
+ 2001-01-12 Nick Clifton <nickc@redhat.com>
+ * config/tc-sh64.c (shmedia_do_align): Fix to work with new
+ alignment handling scheme imported from sourceware.
+ 2001-01-12 Hans-Peter Nilsson <hpn@cygnus.com>
+ * config/tc-sh64.h (TARGET_FORMAT): Define.
+ (sh64_target_format): Prototype.
+ * config/tc-sh64.c (sh64_target_mach): New function.
+ 2001-01-07 Hans-Peter Nilsson <hpn@cygnus.com>
+ * config/tc-sh64.c (shmedia_md_end): When equating a symbol, use
+ zero_address_frag instead of copying the frag of the symbol.
+ (shmedia_frob_file_before_adjust): Ditto.
+ (shmedia_md_apply_fix) <case BFD_RELOC_SH_IMM_MEDLOW16>: Cast mask
+ to valueT to remove signedness.
+ (shmedia_md_convert_frag): Add parameter final. Rename parameter
+ headers to output_bfd. Do not evaluate symbols if final is false;
+ do emit fixups.
+ (shmedia_md_estimate_size_before_relax) <case C (MOVI_IMM_32,
+ UNDEF_MOVI) et al>: If symbol cannot be modified to be PC-relative
+ to the current frag, call shmedia_md_convert_frag to emit fixups
+ and make frag_wane neutralize the frag. Update comments.
+ * config/tc-sh.c (md_convert_frag): Change caller of
+ shmedia_md_convert_frag.
+ 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
+ * config/tc-sh64.h: Tweak comments and correct formatting.
+ * config/tc-sh64.c: Ditto.
+ (shmedia_md_convert_frag) <PT/PTA/PTB 32, 48 and 64 bit
+ expansion, MOVI pcrel expansion>: Fix thinko calculating offset
+ for the no-relocation case.
+ (shmedia_check_limits): Fix range check being off-by-one for PTA.
+ * config/tc-sh.c: Ditto. Add proper comments to #ifdef/#ifndef
+ wrappers.
+ (SH64PCREL16_F): Increment for proper max-PTA handling. Update
+ comment.
+ (SH64PCREL16_M, MOVI_16_M): Correct range thinko.
+ (SH64PCREL48_M, MOVI_48_M): Similar; don't count in length of
+ expansion.
+ (SH64PCREL32_M, MOVI_32_M): Ditto; handle overflowing expression.
+ Correct comment.
+ 2001-01-05 Hans-Peter Nilsson <hpn@cygnus.com>
+ * config/tc-sh64.c (shmedia_md_apply_fix) <second switch, case
+ BFD_RELOC_SH_PT_16>: Set lowest bit in field to be relocated to 1.
+ (shmedia_md_convert_frag) <case C (SH64PCREL16_32, SH64PCREL16) et
+ al>: Set lowest bit of field to relocate to 1 and rest to empty,
+ if reloc is emitted.
+ 2000-12-31 Hans-Peter Nilsson <hpn@cygnus.com>
+ New options plus bugfixes.
+ * config/tc-sh.c (md_longopts): New options "-no-expand" and
+ "-expand-pt32".
+ (md_parse_option): Handle new options.
+ (md_show_usage): Add blurb for new options.
+ * config/tc-sh64.c (SHMEDIA_BFD_RELOC_PT): New macro.
+ (sh64_expand, sh64_pt32): New variables.
+ (shmedia_init_reloc): Handle BFD_RELOC_SH_PT_16.
+ (shmedia_md_apply_fix): Hold original fixP->fx_r_type in
+ orig_fx_r_type. Change SHMEDIA_BFD_RELOC_PT into
+ BFD_RELOC_SH_PT_16. Handle BFD_RELOC_SH_PT_16 as pc-relative.
+ <resolved previously-pc-relative relocs>: Handle
+ SHMEDIA_BFD_RELOC_PT and BFD_RELOC_SH_PT_16.
+ (shmedia_md_convert_frag) <case C (SH64PCREL16PT_64, SH64PCREL16),
+ case C (SH64PCREL16PT_32, SH64PCREL16)>: Modify to PTB if operand
+ points to SHcompact code.
+ <case C (SH64PCREL16_32, SH64PCREL16), case C (SH64PCREL16_64,
+ SH64PCREL16)>: Check that ISA of what operand points at and
+ PTA/PTB matches, or emit error.
+ (shmedia_check_limits): Handle BFD_RELOC_SH_PT_16 and
+ SHMEDIA_BFD_RELOC_PT.
+ (shmedia_immediate_op): If pcrel, emit fixup also for constant
+ operand.
+ (shmedia_build_Mytes) <case A_IMMS16>: Also check sh64_expand in
+ condition for MOVI expansion.
+ <case A_PCIMMS16BY4>: Handle expansion to 32 bits only, if
+ sh64_pt32. Emit only a BFD_RELOC_SH_PT_16 fixup if not
+ sh64_expand.
+ <case A_PCIMMS16BY4_PT>: Likewise, but emit a SHMEDIA_BFD_RELOC_PT
+ fixup.
+ (sh64_target_format): Error-check setting of sh64_pt32 and
+ sh64_expand. Fix typo in check for sh64_shcompact_const_crange.
+ (shmedia_md_pcrel_from_section): Handle BFD_RELOC_SH_PT_16 and
+ SHMEDIA_BFD_RELOC_PT as coming from SHmedia code.
+ 2000-12-31 Hans-Peter Nilsson <hpn@cygnus.com>
+ * config/tc-sh64.c: Improve comments.
+ (shmedia_md_convert_frag): Remove inactive is_pt_variant code. Do
+ not say the linker will check correctness of PTA/PTB expansion.
+ (shmedia_md_end): Make non-static.
+ * config/tc-sh64.h (md_end): Define to shmedia_md_end. Add
+ prototype.
+ * config/tc-sh.c (sh_finalize): Remove.
+ * config/tc-sh.h (md_end): Do not define.
+ Remove prototype for sh_finalize.
+ 2000-12-30 Hans-Peter Nilsson <hpn@cygnus.com>
+ * config/tc-sh64.c (shmedia_frob_section_type): Use a struct
+ sh64_section_data container when storing section type in tdata
+ field in elf_section_data.
+ * config/tc-sh.c (sh_elf_final_processing): Change from EF_SH64 to
+ EF_SH5.
+ * Makefile.am: Update dependencies.
+ * Makefile.in: Regenerate.
+ 2000-12-22 Hans-Peter Nilsson <hpn@cygnus.com>
+ * config/tc-sh64.c (shmedia_md_assemble): Don't protect
+ dwarf2_emit_insn call with test on debug_type.
+ 2000-12-19 Hans-Peter Nilsson <hpn@cygnus.com>
+ * config/tc-sh64.c (sh64_set_contents_type): Make contents-type
+ CRT_SH5_ISA32 sticky for 64-bit.
+ 2000-12-18 Hans-Peter Nilsson <hpn@cygnus.com>
+ Generate .crange sections when switching ISA mode or emitting
+ constants in same section as code.
+ * config/tc-sh64.c: Reformat structure definitions.
+ (sh64_end_of_assembly, sh64_mix, sh64_shcompact_const_crange): New
+ variables.
+ (sh64_set_contents_type): Rename from sh64_init_section. Rewrite
+ to emit a .cranges descriptor when contents type changes. Only
+ emit error if changing contents type and -no-mix is in effect.
+ (sh64_emit_crange, sh64_flush_last_crange, sh64_flag_output,
+ sh64_flush_pending_output, sh64_tc_cons_fix_new): New functions.
+ (shmedia_md_end): Set sh64_end_of_assembly. Pass
+ sh64_flush_last_crange over sections.
+ When checking main symbol of datalabel symbol, check for
+ STO_SH5_ISA32, not ISA type of section in definition.
+ (shmedia_frob_file_before_adjust): Check main symbol for
+ STO_SH5_ISA32; don't check ISA type of section in definition.
+ (shmedia_frob_section_type): Adjust for .cranges; set section flag
+ to SHF_SH5_ISA32_MIXED or SHF_SH5_ISA32 according to whether
+ .cranges entries have been output.
+ (shmedia_elf_new_section): Just call md_flush_pending_output.
+ (shmedia_md_assemble): Do not emit a BFD_RELOC_SH_SHMEDIA_CODE
+ fix. Do not set tc_segment_info_data.in_code for section. Call
+ sh64_set_contents_type for SHmedia code.
+ (s_sh64_mode): Do not call sh64_init_section or set seen_insn to
+ false. Call md_flush_pending_output.
+ (sh64_target_format): Check that -no-mix and
+ -shcompact-const-crange are used in sane combination with other
+ options.
+ (shmedia_md_pcrel_from_section): Check type of fix for how to
+ adjust pc-relative.
+ (sh64_consume_datalabel): Check symbol for having STO_SH5_ISA32,
+ not ISA type of section in definition.
+ * config/tc-sh64.h (struct sh64_segment_info_type): Rewrite to
+ hold contents-type state.
+ (md_flush_pending_output): Redefine to sh64_flush_pending_output.
+ (sh64_flush_pending_output): Declare.
+ (TC_CONS_FIX_NEW): Define to sh64_tc_cons_fix_new.
+ (sh64_tc_cons_fix_new): Declare.
+ * config/tc-sh.c (sh_elf_cons) [HAVE_SH64]: Unset seen_insn and
+ call sh64_flag_output.
+ (md_assemble) [HAVE_SH64]: Do not emit BFD_RELOC_SH_CODE. Just
+ call sh64_set_contents_type to mark SHcompact code and set
+ seen_insn.
+ (md_longopts): New options "-no-mix" and
+ "-shcompact-const-crange".
+ (md_parse_option): Handle new options.
+ (md_show_usage): Add blurb for new options.
+ (md_number_to_chars) [HAVE_SH64]: Call sh64_flag_output.
+ 2000-12-15 Hans-Peter Nilsson <hpn@cygnus.com>
+ * config/tc-sh64.c: Delete investigated and obsolete fixme:s.
+ (sh64_last_insn_frag): New.
+ (shmedia_md_convert_frag): Use tc_frag_data field of incoming frag
+ to get frag for insn opcode for generating fixups; do not assume it
+ is the same frag.
+ (shmedia_build_Mytes): Set sh64_last_insn_frag after growing frag
+ for new insn.
+ * config/tc-sh64.h (ELF_TC_SPECIAL_SECTIONS): Define for .cranges
+ section.
+ (TC_FRAG_TYPE): Define as fragS *.
+ (TC_FRAG_INIT): Define to set tc_frag_data to sh64_last_insn_frag.
+ (sh64_last_insn_frag): Declare.
+ (sh64_consume_datalabel): Fix typo; check for seginfo != NULL,
+ not == NULL before dereferencing.
+ 2000-12-12 Hans-Peter Nilsson <hpn@cygnus.com>
+ Get rid of BFD section flag and EF_SH64_ABI64.
+ * config/tc-sh64.c (shmedia_frob_section_type): Use
+ elf_section_data (sec)->tdata, not a specific BFD section flag, to
+ communicate the section as containing SHmedia code. Describe why.
+ * config/tc-sh.c (sh_elf_final_processing): Tweak comment. Set
+ EF_SH64 regardless of ABI.
+ * config/tc-sh64.c (shmedia_md_apply_fix): Decapitalize "invalid"
+ in error message. Handle resolved expressions for
+ BFD_RELOC_SH_IMMS10, BFD_RELOC_SH_IMMS10BY2,
+ BFD_RELOC_SH_IMMS10BY4 and BFD_RELOC_64.
+ (shmedia_check_limits): Handle BFD_RELOC_64.
+ (sh64_adjust_symtab): Do not decrement the GAS symbol value for
+ a STO_SH5_ISA32 symbol, only the BFD value.
+ 2000-12-11 Ben Elliston <bje@redhat.com>
+ * config/tc-sh64.c: Call dwarf2_emit_insn, not the defunct
+ dwarf2_generate_asm_lineno.
+ 2000-12-11 Hans-Peter Nilsson <hpn@cygnus.com>
+ Handle PC-relative MOVI expansions with assembler relaxation.
+ Generate PC-relative relocs from 16-bit PC-relative expressions.
+ * config/tc-sh64.c (SHMEDIA_MD_PCREL_FROM_FIX): Break out from...
+ (shmedia_md_pcrel_from_section): ...here.
+ (shmedia_md_apply_fix): Handle fixups for 16-bit operands that has
+ turned completely resolved. Adjust relocation type for 16-bit
+ immediate operands that has turned PC-relative. Adjust back for
+ MD_PCREL_FROM_SECTION being applied twice.
+ (shmedia_md_convert_frag): Always emit reloc for expression with
+ global or weak symbol. Handle relaxation result for PC-relative
+ expressions.
+ (shmedia_md_estimate_size_before_relax): An expression with a weak
+ or global symbol can not be relaxed. Break out tests for
+ relaxable symbol into variable sym_relaxable.
+ <cases C (MOVI_IMM_64, UNDEF_MOVI) and C (MOVI_IMM_32,
+ UNDEF_MOVI)>: Break out any PC-relative expression and change
+ relaxation type.
+ (shmedia_build_Mytes): CSE &operands->operands[j] into variable
+ opjp.
+ <case A_IMMS16>: Fix typo for initial minor relaxation type of
+ MOVI expansion. If X_op_symbol of the immediate expression is
+ set, make an expression symbol for the argument to frag_var.
+ * config/tc-sh.c (MOVI_IMM_32_PCREL, MOVI_IMM_64_PCREL): New
+ relaxations.
+ (END): Adjust for new relaxations.
+ (md_relax_table): Add entries for new relaxations.
+ 2000-12-07 Ben Elliston <bje@redhat.com>
+ * config/tc-sh64.c (shmedia_parse_reg): Initialize variable len.
+ 2000-12-07 Hans-Peter Nilsson <hpn@cygnus.com>
+ * config/tc-sh64.c (shmedia_md_convert_frag): Correct all MOVI and
+ SHORI operand offsets in PT/PTA/PTB expansions.
+ 2000-12-05 Hans-Peter Nilsson <hpn@cygnus.com>
+ Implement DataLabel semantics.
+ * config/tc-sh.c (sh_frob_file) [HAVE_SH64]: Call
+ shmedia_frob_file_before_adjust.
+ * config/tc-sh64.c [! OBJ_ELF]: Emit #error.
+ (DATALABEL_SUFFIX): Define.
+ (shmedia_md_end) <before adjusting STO_SH5_ISA32 symbols>: Walk
+ symbol list to update "datalabel" symbols to their main symbol
+ counterparts.
+ (shmedia_frob_file_before_adjust): New.
+ (sh64_adjust_symtab): For remaining datalabel symbols, set to
+ undefined and set STT_DATALABEL.
+ (sh64_frob_label): Initialize TC symbol field.
+ (sh64_consume_datalabel): Actually implement semantics. New
+ parameter operandf, call it instead of expression.
+ (sh64_exclude_symbol): New.
+ * config/tc-sh64.h (md_parse_name): Pass on the function operand
+ to sh64_consume_datalabel.
+ (tc_symbol_new_hook): Define to tc_frob_symbol.
+ (TC_SYMFIELD_TYPE): Define to symbolS *.
+ (tc_frob_symbol): Define to call sh64_exclude_symbol.
+ 2000-12-01 Hans-Peter Nilsson <hpn@cygnus.com>
+ * config/tc-sh64.c (shmedia_init_reloc): Tweak comment for default
+ case.
+ (shmedia_md_assemble): Call dwarf2_generate_asm_lineno if
+ generating dwarf2 debug information.
+ 2000-11-30 Hans-Peter Nilsson <hpn@cygnus.com>
+ * config/tc-sh64.c (sh64_target_format): Use elf64-sh64l and
+ elf64-sh64 for the 64-bit ABI.
+ * config/tc-sh.c (md_show_usage): Tweak usage output for -abi=*
+ option.
+ 2000-11-29 Hans-Peter Nilsson <hpn@cygnus.com>
+ * config/tc-sh.c: Remove conditionalizing on HAVE_SH64 for
+ case-insensitivity.
+ 2000-11-27 Hans-Peter Nilsson <hpn@cygnus.com>
+ * config/tc-sh64.c: Tweak comments, formatting and error messages.
+ (enum sh64_abi_values): New type.
+ (enum sh64_isa_values): New type.
+ (sh64_isa_mode): Replace shmedia_mode. All referers changed.
+ (seen_shcompact_mode, seen_shmedia_mode): Delete.
+ (sh64_abi): Replace shmedia_64.
+ (shmedia_md_convert_frag) <C (MOVI_IMM_64, MOVI_64),
+ C (MOVI_IMM_32, MOVI_32)>: Correct register number handling.
+ (s_sh64_mode): Check validity for this target.
+ (sh64_target_format): Initialize defaults for ISA and ABI.
+ Fallback to old object format if no SH64 ISA or ABI has been
+ specified.
+ * config/tc-sh.c (md_parse_option): Check combinations for errors.
+ (sh_elf_final_processing): Change to have EF_SH64_ABI64 for 64-bit
+ ABI and EF_SH64 for 32-bit ABI, if SH64 options are specified.
+ * config/tc-sh64.h: Fix typo in comment.
+ 2000-11-25 Hans-Peter Nilsson <hpn@cygnus.com>
+ * config/tc-sh64.c (shmedia_md_estimate_size_before_relax)
+ <PT fixups for absolute values>: Size will be longest, not
+ shortest.
+ (shmedia_md_convert_frag): Disable PTB-warning machinery. Correct
+ all MOVI and SHORI operand offsets in PT/PTA/PTB expansions.
+ * config/tc-sh.c (parse_reg) [HAVE_SH64]: Add local variables l0
+ and l1 to hold lowercase of two first characters. Change all
+ remaining TO_LOWER to tolower.
+ * config/tc-sh64.c (TO_LOWER): Delete.
+ (shmedia_find_cooked_opcode): Use tolower, not TO_LOWER.
+ (md_parse_name): Define.
+ (sh64_consume_datalabel): Declare.
+ (DOLLAR_DOT): Define.
+ * config/tc-sh64.c (shmedia_parse_exp): New.
+ (sh64_consume_datalabel): New; just ignoring datalabel semantics.
+ (shmedia_parse_reg): Remove const from src
+ parameter.
+ (shmedia_get_operands): Ditto for args parameter and ptr variable.
+ (shmedia_md_assemble): Ditto for op_end variable.
+ (shmedia_get_operand): Ditto for ptr parameter and src variable.
+ Use shmedia_parse_exp, not parse_exp.
+ * config/tc-sh64.c (shmedia_parse_reg): Add shmedia_arg_type
+ parameter. All callers changed.
+ (shmedia_get_operand): Add shmedia_arg_type parameter. All
+ callers changed.
+ (shmedia_parse_reg): Put first two character in local variables.
+ Use tolower, not TO_LOWER. If no register is found and argtype
+ indicates a control register, scan shmedia_creg_table
+ case-insensitive.
+ 2000-11-24 Hans-Peter Nilsson <hpn@cygnus.com>
+ * Makefile.am (CPU_TYPES): Add sh64.
+ (TARGET_CPU_CFILES): Add config/tc-sh64.c.
+ (TARGET_CPU_HFILES): Add config/tc-sh64.h.
+ Regenerate dependencies.
+ * Makefile.in: Regenerate.
+ * configure.in: Add support for sh64-*-elf*.
+ * configure: Regenerate.
+ * config/tc-sh64.h: New.
+ * config/tc-sh64.c: New.
+ * config/tc-sh.c (md_pseudo_table) [HAVE_SH64]: New pseudos
+ .mode, .isa and .uaquad.
+ [HAVE_SH64] (SH64PCREL16_32, SH64PCREL16_64, SH64PCREL16PT_32,
+ SH64PCREL16PT_64, MOVI_IMM_32, MOVI_IMM_64): Define.
+ [HAVE_SH64] (END): Define as 10.
+ [HAVE_SH64] (UNDEF_SH64PCREL, SH64PCREL16, SH64PCREL32,
+ SH64PCREL48, SH64PCREL64, UNDEF_MOVI, MOVI_16, MOVI_32, MOVI_48,
+ MOVI_64): Define.
+ [HAVE_SH64] (SH64PCREL16_F, SH64PCREL16_M, SH64PCREL16_LENGTH,
+ SH64PCREL32_F, SH64PCREL32_M, SH64PCREL32_LENGTH, SH64PCREL48_F,
+ SH64PCREL48_M, SH64PCREL48_LENGTH, SH64PCREL64_LENGTH,
+ MOVI_16_LENGTH, MOVI_32_LENGTH, MOVI_48_LENGTH, MOVI_64_LENGTH):
+ Define.
+ (md_relax_table) [HAVE_SH64]: Provide relaxations for SHmedia.
+ (md_begin) [HAVE_SH64]: Call shmedia_md_begin.
+ (parse_reg) [HAVE_SH64]: Parse register names case-insensitive.
+ (md_assemble) [HAVE_SH64]: Call shmedia_md_assemble if assembling
+ SHmedia instructions. Handle state-change after switching to
+ SHcompact.
+ (md_longopts) [HAVE_SH64]: New options --isa=* and --abi=*.
+ (md_parse_option) [HAVE_SH64]: Parse new options.
+ (md_show_usage) [HAVE_SH64]: Show usage of new options.
+ (md_convert_frag) [HAVE_SH64] <default>: Call
+ shmedia_md_convert_frag instead of abort.
+ (sh_force_relocation) [HAVE_SH64]: Also force relocation for
+ BFD_RELOC_SH_SHMEDIA_CODE.
+ (sh_elf_final_processing) [HAVE_SH64]: Set flags identifying
+ SHcompact or SHmedia code.
+ (md_apply_fix) [HAVE_SH64] <default>: Return result from calling
+ shmedia_md_apply_fix instead of abort.
+ (md_estimate_size_before_relax) [HAVE_SH64] <default>: Return
+ result from calling shmedia_md_estimate_size_before_relax instead
+ of calling abort.
+ (sh_do_align) [HAVE_SH64]: If shmedia_mode, let shmedia_do_align
+ do the work.
+ (tc_gen_reloc) [HAVE_SH64]: For unrecognized relocs, call
+ shmedia_init_reloc and do nothing more if it returns non-zero.
+ (sh_finalize) [HAVE_SH64]: Call shmedia_md_end.
+ * po/POTFILES.in: Regenerate.
+ * po/gas.pot: Regenerate.
+
+2002-02-06 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-sh.c (parse_at): Install the correct version of
+ 2002-02-04's patch.
+
+ * config/tc-sh.c (md_apply_fix3) <BFD_RELOC_32_PLT_PCREL>: Don't
+ assume fixP->fx_subsy is non-NULL.
+
+2002-02-04 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-sh.c (parse_at): Set arg type of @(expr,pc) to
+ A_DISP_PC_ABS, and adjust it by -4.
+ (get_specific): Accept A_DISP_PC_ABS where A_DISP_PC is
+ expected.
+ (build_Mytes): Mark PCRELIMM fix-ups as pc-relative only if
+ the operand type is not A_DISP_PC_ABS.
+
+2002-02-04 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * config/tc-mmix.c (tc_gen_reloc): Don't try and take the value of
+ common and weak symbols. Handle common and weak symbols as
+ undefined symbols with regards to GREG handling and merging.
+ (mmix_frob_file): Ditto.
+
+2002-02-02 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * configure.in (hppa-*-netbsd*): New target.
+ * configure: Regenerate.
+ * config/tc-hppa.h: Also define WARN_COMMENTS if TE_NetBSD.
+
+2002-02-02 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-v850.c: Add missing prototypes amd use old-style
+ function definitions.
+ (AREA_ZDA, AREA_SDA, AREA_TDA): Delete.
+ (sdata_section tdata_section, zdata_section, sbss_section,
+ tbss_section, zbss_section, rosdata_section, rozdata_section,
+ scommon_section, tcommon_section, zcommon_section,
+ call_table_data_section, call_table_text_section): Delete.
+ (v850_sdata, v850_tdata, v850_zdata, v850_sbss, v850_tbss,
+ v850_zbss, v850_bss, v850_rosdata, v850_rozdata,
+ v850_call_table_data, v850_call_table_text): Delete.
+ (struct v850_seg_entry): New.
+ (v850_seg_table): New.
+ (SDATA_SECTION TDATA_SECTION, ZDATA_SECTION, SBSS_SECTION,
+ TBSS_SECTION, ZBSS_SECTION, BSS_SECTION, ROSDATA_SECTION,
+ ROZDATA_SECTION, SCOMMON_SECTION, TCOMMON_SECTION, ZCOMMON_SECTION,
+ CALL_TABLE_DATA_SECTION, CALL_TABLE_TEXT_SECTION): Define.
+ (do_v850_seg): New.
+ (v850_seg): New.
+ (v850_comm): Use do_v850_seg and v850_seg_table. Simplify
+ recording of alignment.
+ (md_pseudo_table): Use v850_seg.
+ (md_begin): Don't init .call_table_data and .call_table_text here.
+ Set v850_seg_table bss entry.
+
+2002-02-01 Hans-Peter Nilsson <hp@bitrange.com>
+
+ Support on-demand global register allocation by passing on
+ base-plus-offset relocs to the linker.
+ * config/tc-mmix.c: Tweak and fix typos in comments.
+ (allocate_undefined_gregs_in_linker): New variable.
+ (OPTION_LINKER_ALLOCATED_GREGS): New option macro.
+ (md_longopts): Add --linker-allocated-gregs.
+ (md_parse_option) <case 'x'>: Imply --linker-allocated-gregs.
+ <case OPTION_LINKER_ALLOCATED_GREGS>: New.
+ (md_show_usage): Update text for -x. Add text for
+ --linker-allocated-gregs.
+ (tc_gen_reloc): Derive default value for addend from val and
+ baddsy. Use addsec and bfd_is_abs_section in more places. Don't
+ emit error for BFD_RELOC_MMIX_BASE_PLUS_OFFSET without suitable
+ GREG if allocate_undefined_gregs_in_linker.
+ * doc/as.texinfo (Overview) <Target MMIX options>: Add
+ --linker-allocated-gregs.
+ * doc/c-mmix.texi (MMIX-Opts): Add blurb about
+ --linker-allocated-gregs. Mention that it's implied by -x.
+ (MMIX-Pseudos) <GREG>: Mention when and how a GREG can be omitted.
+ (MMIX-mmixal): Clarify dated comparison and location of MMIXware.
+
+ * config/tc-mmix.h (md_parse_name): Use ISUPPER, not isupper.
+
+2002-02-01 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am"
+ * Makefile.in: Regenerate.
+
+2002-01-31 Ivan Guzvinec <ivang@opencores.org>
+
+ * config/tc-or32.c: New file.
+ * config/tc-or32.h: New file.
+ * configure.in: Add support for or32 targets.
+ * configure: Regenerate.
+ * config/obj-coff.c: Add support for or32 targets.
+ * config/obj-coff.h: Add support for or32 targets.
+ * Makefile.am: Add support for or32 targets.
+ * Makefile.in: Regenerate.
+ * NEWS: Mention support for OpenRISC.
+ * doc/Makefile.in: Regenerate.
+ * po/POTFILES.in: Regenerate.
+ * po/gas.pot: Regenerate.
+
+2002-01-30 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/tc-sh.c (parse_reg): Fix end-of-word check for is, ix, iy
+ and mod.
+
+2002-01-29 Chris Demetriou <cgd@broadcom.com>
+
+ * config/tc-mips.c (tc_gen_reloc): Arrange for
+ BFD_RELOC_PCREL_HI16_S relocations to be output relative to
+ their LO16 parts, even for ELF.
+
+2002-01-29 Daniel Jacobowitz <drow@mvista.com>
+
+ * config/tc-i386.c: Protect definitions of true and false
+ from redefinition.
+
+2002-01-28 Jakub Jelinek <jakub@redhat.com>
+
+ * config/obj-elf.c (elf_frob_file_before_adjust): Remove symbols
+ made because of .weak, if they are neither defined nor used in any
+ way.
+
+2002-01-27 Daniel Jacobowitz <drow@mvista.com>
+
+ * configure: Regenerated.
+
+2002-01-26 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * doc/Makefile.am (install): Depend on install-info.
+ * doc/Makefile.in: Regenerate.
+
+2002-01-26 Nick Clifton <nick@redhat.com>
+
+ * po/fr.po: Updated version
+
+2002-01-24 Kazu Hirata <kazu@hxi.com>
+
+ * config/tc-h8300.c (check_operand): Don't print a warning
+ when a valid 24-bit address is given to a 16-bit address
+ operand.
+
+2002-01-24 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-sh.c (sh_elf_suffix): Removed.
+ (sh_PIC_related_p, sh_check_fixup, sh_cons_fix_new,
+ sh_end_of_match, sh_parse_name): New functions.
+ (sh_elf_cons): Simplify.
+ (parse_exp): Reject misplaced PIC operands.
+ (md_undefined_symbol): Simplify.
+ (sh_fix_adjustable): Let @GOTOFF be adjusted.
+ (md_apply_fix3): Write @PLT and @GOTOFF addends in place.
+ (tc_gen_reloc): Move fixp subsy absolute value into addnumber.
+ Complain if subsy remains at the end.
+ * config/tc-sh.h (sh_parse_name, sh_cons_fix_new): Declare.
+ (md_parse_name, TC_CONS_FIX_NEW, O_PIC_reloc): Define.
+
+2002-01-22 Alexandre Oliva <aoliva@redhat.com>
+
+ * config/tc-mn10300.c (xr_registers): Move `pc'...
+ (other_registers): ... here.
+
+2002-01-22 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * gas/po/POTFILES.in: Regenerate.
+
+2002-01-21 DJ Delorie <dj@redhat.com>
+
+ * config/obj-coff.c (obj_coff_init_stab_section): Make the
+ stabstr_name allocation permanent, as it will be referenced from
+ the section hash.
+
+2002-01-21 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * configure.in (ia64-*-netbsd*): New target.
+ * configure: Regenerate.
+
+2002-01-21 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * doc/as.texinfo (Overview) <Target ARM options>: Add missing {}
+ to @dots call.
+ <Detailed description, ARM options>: Ditto.
+ * doc/c-arm.texi (ARM Options): Ditto.
+
+2002-01-18 Richard Earnshaw <rearnsha@arm.com>
+
+ * tc-arm.c (do_xsc_mia, do_xsc_mar, do_xsc_mra): Renamed from
+ do_mia, do_mar and do_mra respectively.
+ (do_mav_*): Renamed from do_c_*.
+ (mav_reg_required_here, mav_parse_offset): Renamed from
+ cirrus_reg_required_here and cirrus_parse_offset respectively.
+ (MAV_MODE?): Renamed from CIRRUS_MODE?.
+
+2002-01-18 Richard Earnshaw <rearnsha@arm.com>
+ Keith Walker <keith.walker@arm.com>
+
+ * tc-arm.c (ARM_EXT_V5J, ARM_ARCH_V5TEJ): Define.
+ (insns): Add pattern for bxj instruction.
+ (do_bxj): New function.
+ (arm_cpus): Add arm926ej.
+ (arm_archs): Add armv5tej.
+
+2002-01-18 Richard Earnshaw <rearnsha@arm.com>
+
+ * doc/c-arm.texi: Add new fpe options to list of supported flags.
+
+2002-01-19 Keith Walker <keith.walker@arm.com>
+
+ * tc-arm.c (arm_fpus): Add fpe2 and fpe3.
+
+2002-01-18 Richard Earnshaw <rearnsha@arm.com>
+
+ * NEWS: Mention new ARM command-line options and VFP support.
+
+ * config/tc-arm.c (ARM_CEXT_XSCALE): Replaces ARM_EXT_XSCALE. All
+ uses changed.
+ (ARM_CEXT_MAVERICK): Similarly.
+ (ARM_ANY): Now means any core instruction.
+ (CPU_DEFAULT): Default to ARM_ANY.
+ (uses_apcs_26, atcps, support_interwork, uses_apcs_float)
+ (pic_code): Declare for all object types. Make type int.
+ (legacy_cpu, legacy_fpu, mcpu_cpu_opt, mcpu_fpu_opt, march_cpu_opt)
+ (march_fpu_opt, mfpu_opt): Declare.
+ (md_longopts): Tidy up conditional definitions.
+ (arm_opts, arm_cpus, arm_archs, arm_fpus, arm_extensions)
+ (arm_long_opts): New tables.
+ (arm_parse_cpu, arm_parse_arch, arm_parse_fpu): New functions.
+ (arm_parse_extension): New function.
+ (md_parse_option): Rewrite using new table-driven system.
+ (md_show_usage): Use new table-driven system.
+ (md_begin): Calculate cpu_variant from command line option data.
+ * doc/as.texinfo (ARM ISA options): Docuement new ARM-specific
+ command-line options.
+ * doc/c-arm.texi: Likewise.
+
+2002-01-18 Andreas Jaeger <aj@suse.de>
+
+ * as.c (parse_args): Update year.
+
+2002-01-17 Timothy Wall <twall@alum.mit.edu>
+
+ * config/tc-tic54x.c (encode_address): Add a more informative
+ warning about incorrect syntax.
+
+2002-01-17 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/gas.pot: Regenerate.
+
+2002-01-17 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * macro.c (get_any_string): Add no-c-format comment to prevent
+ confusion when translating string.
+ * gasp.c (get_any_string): Add no-c-format comment to prevent
+ confusion when translating string.
+
+2002-01-16 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+ Johannes Stezenbach <js@convergence.de>
+ * config/tc-mips.c (percent_op): Ensure longer percent_op's are
+ matched before the shorter ones.
+ (my_getSmallParser): Fix handling of nested parentheses in
+ percent_op's. Code cleanup.
+ (my_getPercentOp): New function, code from my_getSmallParser.
+ (my_getSmallExpression): Fix handling of closing parentheses.
+ Code cleanup. Better comments.
+
+2002-01-16 Nick Clifton <nickc@redhat.com>
+
+ po/tr.po: New file: Turkish translation.
+ configure.in (LINGUAS): Add "tr".
+ configure: Regenerate.
+
+2002-01-15 Richard Earnshaw <rearnsha@arm.com>
+
+ Support for VFP instructions
+ * tc-arm.c (CP_WB_OK, CP_NO_WB): New defines.
+ (cp_address_required_here): New argument wb_ok. When false, do not
+ accept write-back forms of addressing. Change all callers.
+ (FPU_VFP_EXT_NONE, FPU_VFP_EXT_V1xD, FPU_VFP_VFP_V1)
+ (FPU_VFP_EXT_V2): Define.
+ (FPU_ARCH_VFP, FPU_ARCH_VFP_V1xD, FPU_ARCH_VFP_V1, FPU_ARCH_VFP_V2):
+ Define in terms of above.
+ (vfp_dp_reg_pos, vfp_sp_reg_pos, vfp_ldstm_type): New enums.
+ (vfp_reg): New struct.
+ (vfp_regs): New array of registers.
+ (insns): Add VFP instructions.
+ (sn_table): New array of VFP single-precision register names.
+ (dn_table): New array of VFP double-precision register names.
+ (all_reg_maps): Add the new register tables.
+ (arm_reg_type): Add new values for above. Increase RET_TYPE_MAX.
+ (vfp_sp_reg_required_here, vfp_dp_reg_required_here, do_vfp_sp_monadic)
+ (do_vfp_dp_monadic, do_vfp_sp_dyadic, do_vfp_dp_dyadic)
+ (do_vfp_reg_from_sp, do_vfp_sp_reg2, do_vfp_sp_from_reg)
+ (do_vfp_reg_from_dp, do_vfp_reg2_from_dp, do_vfp_dp_from_reg)
+ (do_vfp_dp_from_reg2, vfp_psr_parse, vfp_psr_required_here)
+ (do_vfp_reg_from_ctrl, do_vfp_ctrl_from_reg, do_vfp_sp_ldst)
+ (do_vfp_dp_ldst, vfp_sp_reg_list, vfp_dp_reg_list, vfp_sp_ldstm)
+ (vfp_dp_ldstm, do_vfp_sp_ldstmia, do_vfp_sp_ldstmdb, do_vfp_ldstmia)
+ (do_vfp_dp_ldstmdb, do_vfp_xp_ldstmia, do_vfp_xp_ldstmdb)
+ (do_vfp_sp_compare_z, do_vfp_dp_compare_z, do_vfp_dp_sp_cvt)
+ (do_vfp_sp_dp_cvt): New functions.
+ (md_begin): Set soft-float flag for appropriate VFP work.
+ (md_atof): Handle VFP-format doubles.
+ (md_parse_option): Handle VFP command-line options.
+ (md_show_usage): Display VFP command-line options.
+
+2002-01-15 Richard Earnshaw <rearnsha@arm.com>
+
+ * tc-arm.c (md_parse_option): Tidy up setting of cpu_variant for
+ various command line options.
+
+2002-01-15 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * config/tc-xstormy16.c: (xstormy16_fix_adjustable): Do not fix
+ vtinherit relocs.
+ (xstormy16_md_apply_fix3): Do not return a value.
+
+2002-01-14 Richard Earnshaw <rearnsha@arm.com>
+
+ * tc-arm.c (md_longopts): On targets that aren't bi-endian, support
+ the -EL/-EB option that matches the target's endianness.
+ (md_parse_option): Likewise.
+
+2002-01-14 Richard Earnshaw <rearnsha@arm.com>
+
+ * tc-arm.c (md_longopts): Fix misplaced #endif -- the -oabi option
+ is not dependent on ARM_BI_ENDIAN.
+
+2002-01-14 Richard Earnshaw <rearnsha@arm.com>
+
+ * tc-arm.c (all error messages): Normalize capitalization of messages.
+
+ * tc-arm.h (md_operand): Delete define.
+ * tc-arm.c (in_my_get_expression): New static variable.
+ (my_get_expression): Set and clear it.
+ (md_operand): New function. If called from my_get_expression
+ put the error in inst.error.
+ (output_inst): Now takes argument of instruction being assembled.
+ Print it out with any error message.
+ (do_ldst, do_ldstv4, thumb_load_store): Fault attempt to use a store
+ with '=' syntax.
+ (end_of_line): Don't update inst.error if it is already set.
+
+2002-01-11 Richard Earnshaw <rearnsha@arm.com>
+
+ * tc-arm.c (do_ldst): Fix handling an immediate expression pseudo
+ op that can be translated into a mvn instruction.
+
+2002-01-11 Steve Ellcey <sje@cup.hp.com>
+
+ * gas/config/tc-ia64.h (MD_FLAGS_DEFAULT): New Macro for
+ setting default md.flags.
+ (SHT_INIT_ARRAY): New elf special section used by HP-UX.
+ (SHT_FINI_ARRAY): New elf special section used by HP-UX.
+ * gas/config/tc-ia64.c (setup_unwind_header): Add support
+ for 32 bit unwind info blocks.
+ (generate_unwind_image): Add support for different types
+ of unwind images (32 bits and/or big-endian).
+ (ia64_init): Use MD_FLAGS_DEFAULT to set md.flags.
+ (ia64_target_format): Add support for hpux target formats.
+ (ia64_gen_real_reloc_type): Add support for FUNC_IPLT_RELOC.
+ (ia64_elf_section_type): Add support for SHT_INIT_ARRAY and
+ SHT_FINI_ARRAY elf section types.
+
+2002-01-10 Richard Earnshaw <rearnsha@arm.com>
+
+ * tc-arm.c (struct reg_entry): Move before prototypes.
+ (int_register, cp_register, fp_register): Delete.
+ (reg_table): Delete. Replaced with ...
+ (rn_table, cp_table, cn_table, fn_table, mav_mvf_table)
+ (mav_mvd_table, mav_mvfx_table, mav_mvdx_table, mav_mvax_table)
+ (mav_dspsc_table): ... one table per register set.
+ (arm_reg_hsh): Delete.
+ (struct reg_map): New structure.
+ (all_reg_maps): New array.
+ (enum arm_reg_type): New enums.
+ (build_reg_hsh): New function.
+ (insert_reg_alias): Use hash table passed by caller. Adjust all
+ callers.
+ (create_register_alias): New function, split out from ...
+ (md_assemble): ... here.
+ (md_begin): Build new register hash tables.
+ (arm_reg_parse): New argument for the hash table to search. Adjust all
+ callers.
+ (arm_reg_parse_any): New function.
+ (co_proc_number): Look up the processor number in the processor hash
+ table.
+ (cirrus_regtype): Delete.
+ (cirrus_register, cirrus_mvf_register, cirrus_mvd_register)
+ (cirrus_mvfx_register, cirrus_mvdx_register, cirrus_mvax_register)
+ (ARM_EXT_MAVERICKsc_register): Delete.
+ (do_c_binops_1, do_c_binops_2, do_c_binops_3): Delete.
+ (do_c_binops_1[a-o], do_c_binops_2[a-c], do_c_binops_3[a-d]): New
+ functions.
+ (do_c_triple_4, do_c_triple_5): Delete.
+ (do_c_triple_4[ab], do_c_triple_5[a-h]): New functions.
+ (do_c_quad_6): Delete.
+ (do_c_quad_6[ab]): New functions.
+ (do_c_binops, do_c_triple, do_c_quad, do_c_shift, do_c_ldst): Rework
+ arguments to use new register parsing methods.
+ (cirrus_reg_required_here): Likewise.
+ (insns): Reclassify cirrus maverick worker functions.
+ (cirrus_valid_reg): Delete.
+
+2002-01-07 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * configure.in (sh*le): Set cpu_type=sh and endian=little.
+ (sh*-*-netbsdelf*): New target.
+ * configure: Regenerate.
+ * tc-sh.h: Update copyright years.
+ (TARGET_FORMAT): Add version for TE_NetBSD.
+
+2002-01-07 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * read.c (emit_expr): Do not allow 'size' or 'nbytes' to go
+ negative.
+
+2002-01-06 Alan Modra <amodra@bigpond.net.au>
+
+ * config/tc-m68k.h (md_prepare_relax_scan): Rewrite.
+ * config/tc-m68k.c (md_relax_table): Add md_prepare_relax_scan comment.
+
+2002-01-05 Daniel Jacobowitz <drow@mvista.com>
+
+ * tc-mips.c (mips_cprestore_valid): New flag.
+ (mips_frame_reg_valid): New flag.
+ (macro) [M_JAL_2]: Check both flags.
+ [M_JAL_A]: Likewise.
+ (s_cprestore): Set mips_cprestore_valid.
+ (tc_get_register): If setting mips_frame_reg, set
+ mips_frame_reg_valid and clear mips_cprestore_valid.
+ (s_mips_ent): Clear both flags.
+ (s_mips_end): Clear both flags.
+
+2002-01-05 Alan Modra <amodra@bigpond.net.au>
+
+ * write.c (write_object_file): Make use of bfd_section_list_remove.
+ * config/obj-ecoff.c (ecoff_frob_file): Likewise.
+ * config/tc-mmix.c (mmix_frob_file): Likewise.
+
+2002-01-04 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * configure.in (i386-*-netbsdelf*): Collapse target into...
+ (i386-*-netbsd*): ...this. Add support for x86-64.
+ * configure: Regenerated.
+
+2002-01-03 matthew green <mrg@redhat.com>
+
+ * config/tc-ppc.c (md_parse_option): BookE is not Motorola specific.
+
+2002-01-02 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * config/tc-m68k.c (md_estimate_size_before_relax): Test for a
+ NULL frag link.
+
+For older changes see ChangeLog-0001
+
+Local Variables:
+mode: change-log
+left-margin: 8
+fill-column: 74
+version-control: never
+End:
diff --git a/contrib/binutils/gas/ChangeLog-9295 b/contrib/binutils/gas/ChangeLog-9295
index a761ea1..7135733 100644
--- a/contrib/binutils/gas/ChangeLog-9295
+++ b/contrib/binutils/gas/ChangeLog-9295
@@ -9003,7 +9003,7 @@ Thu Oct 14 16:51:00 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
* app.c (do_scrub_next_char): Always accept 'x' and 'X' as escape
characters in state 6.
* read.c (next_char_of_string): Accept \Xh* and \xh* where h* are
- hexidecimal digits.
+ hexadecimal digits.
* config/tc-i386.c (md_apply_fix_1): Make cross segment calls work
for ELF by hacking around bizarre bfd_perform_relocation behaviour
@@ -10401,7 +10401,7 @@ Thu Jul 8 14:15:05 1993 Ken Raeburn (raeburn@cambridge.cygnus.com)
Thu Jul 8 07:25:25 1993 Doug Evans (dje@canuck.cygnus.com)
- * config/tc-h8300.h (TC_CONS_RELOC): Use R_RELLONG if h8/300h.
+ * config/tc-h8300.h (TC_CONS_RELOC): Use R_RELLONG if H8/300H.
Wed Jul 7 18:11:07 1993 david d `zoo' zuhn (zoo at rtl.cygnus.com)
@@ -13007,7 +13007,7 @@ Sat Feb 22 12:26:28 1992 Steve Chamberlain (sac at rtl.cygnus.com)
* app.c: MRI compatibility - allow single quote to start a string.
* as.c: fix typo recently introduced.
* as.h : Don't include aout/reloc.h - it's not right for COFF!
- * expr.c: Much rewriting, to accomodate MRI syntax for
+ * expr.c: Much rewriting, to accommodate MRI syntax for
expressions. Also easier to read now.
* listing.c: Put back defuns
* read.c: modified to accept MRI syntax, put back listing pseudo
diff --git a/contrib/binutils/gas/Makefile.am b/contrib/binutils/gas/Makefile.am
index e8d060f..7728434 100644
--- a/contrib/binutils/gas/Makefile.am
+++ b/contrib/binutils/gas/Makefile.am
@@ -3,9 +3,12 @@
## Work around apparent automake bug.
INTLLIBS = @INTLLIBS@
-AUTOMAKE_OPTIONS = cygnus dejagnu
+AUTOMAKE_OPTIONS = 1.8 cygnus dejagnu
SUBDIRS = doc po
+# Automake should figure this out on its own. It doesn't, because
+# of the "cygnus" option. But distclean still wants it.
+DIST_SUBDIRS = $(SUBDIRS)
tooldir = $(exec_prefix)/$(target_alias)
@@ -56,6 +59,7 @@ CPU_TYPES = \
i386 \
i860 \
i960 \
+ ip2k \
m32r \
m68hc11 \
m68k \
@@ -65,6 +69,7 @@ CPU_TYPES = \
mmix \
mn10200 \
mn10300 \
+ msp430 \
ns32k \
openrisc \
or32 \
@@ -77,12 +82,14 @@ CPU_TYPES = \
sparc \
tahoe \
tic30 \
+ tic4x \
tic54x \
tic80 \
vax \
w65 \
v850 \
xstormy16 \
+ xtensa \
z8k
# Object format types. This is only used for dependency information.
@@ -109,7 +116,7 @@ CPU_OBJ_VALID = \
case $$o in \
aout) \
case $$c in \
- a29k | arm | cris | i386 | m68k | mips | ns32k | pdp11 | sparc | tahoe | tic30 | vax) \
+ a29k | arm | cris | i386 | m68k | ns32k | pdp11 | sparc | tahoe | tic30 | vax) \
valid=yes ;; \
esac ;; \
bout) \
@@ -118,7 +125,7 @@ CPU_OBJ_VALID = \
esac ;; \
coff) valid=yes; \
case $$c in \
- cris | i860 | mmix) \
+ cris | i860 | mmix | sh64) \
valid= ;; \
esac ;; \
ecoff) \
@@ -172,6 +179,7 @@ GAS_CFILES = \
cond.c \
depend.c \
dwarf2dbg.c \
+ dw2gencfi.c \
ecoff.c \
ehopt.c \
expr.c \
@@ -194,7 +202,7 @@ GAS_CFILES = \
symbols.c \
write.c
-CFILES = $(GAS_CFILES) gasp.c itbl-ops.c
+CFILES = $(GAS_CFILES) itbl-ops.c
HFILES = \
as.h \
@@ -203,6 +211,7 @@ HFILES = \
bit_fix.h \
cgen.h \
dwarf2dbg.h \
+ dw2gencfi.h \
ecoff.h \
emul-target.h \
emul.h \
@@ -246,6 +255,7 @@ TARGET_CPU_CFILES = \
config/tc-i386.c \
config/tc-i860.c \
config/tc-i960.c \
+ config/tc-ip2k.c \
config/tc-m32r.c \
config/tc-m68hc11.c \
config/tc-m68k.c \
@@ -255,6 +265,7 @@ TARGET_CPU_CFILES = \
config/tc-mmix.c \
config/tc-mn10200.c \
config/tc-mn10300.c \
+ config/tc-msp430.c \
config/tc-ns32k.c \
config/tc-openrisc.c \
config/tc-or32.c \
@@ -273,6 +284,7 @@ TARGET_CPU_CFILES = \
config/tc-w65.c \
config/tc-v850.c \
config/tc-xstormy16.c \
+ config/tc-xtensa.c \
config/tc-z8k.c
TARGET_CPU_HFILES = \
@@ -295,6 +307,7 @@ TARGET_CPU_HFILES = \
config/tc-i386.h \
config/tc-i860.h \
config/tc-i960.h \
+ config/tc-ip2k.h \
config/tc-m32r.h \
config/tc-m68hc11.h \
config/tc-m68k.h \
@@ -304,6 +317,7 @@ TARGET_CPU_HFILES = \
config/tc-mmix.h \
config/tc-mn10200.h \
config/tc-mn10300.h \
+ config/tc-msp430.h \
config/tc-ns32k.h \
config/tc-openrisc.h \
config/tc-or32.h \
@@ -322,6 +336,7 @@ TARGET_CPU_HFILES = \
config/tc-w65.h \
config/tc-v850.h \
config/tc-xstormy16.h \
+ config/tc-xtensa.h \
config/tc-z8k.h
# OBJ files in config
@@ -412,6 +427,7 @@ GENERIC_OBJS = \
cond.o \
depend.o \
dwarf2dbg.o \
+ dw2gencfi.o \
ehopt.o \
expr.o \
flonum-konst.o \
@@ -440,11 +456,11 @@ POTFILES = $(MULTI_CFILES) $(TARGET_ENV_HFILES) $(OBJ_FORMAT_HFILES) \
$(OBJ_FORMAT_CFILES) $(TARGET_CPU_HFILES) $(TARGET_CPU_CFILES) \
$(HFILES) $(CFILES) $(GAS_CFILES)
po/POTFILES.in: @MAINT@ Makefile
- for file in $(POTFILES); do echo $$file; done | sort > tmp \
+ for f in $(POTFILES); do echo $$f; done | LC_COLLATE= sort > tmp \
&& mv tmp $(srcdir)/po/POTFILES.in
-# Note: GASP is now deprecated and will be removed at some point in the future.
-# Anything that GASP could do can now be done by GAS.
+# Note: GASP is now deprecated and has been removed. It is still
+# available in the CVS archive or older binutils releases if it is needed.
noinst_PROGRAMS = as-new
noinst_SCRIPTS = $(GDBINIT)
EXTRA_SCRIPTS = .gdbinit
@@ -490,6 +506,8 @@ GASLIBS = @OPCODES_LIB@ @BFDLIB@ ../libiberty/libiberty.a
# Files to be copied away after each stage in building.
STAGESTUFF = *.o $(noinst_PROGRAMS)
+BFDVER_H = @BFDVER_H@
+
$(OBJS): @ALL_OBJ_DEPS@
as_new_SOURCES = $(GAS_CFILES)
@@ -506,10 +524,6 @@ $(OBJS): $(INCDIR)/bin-bugs.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
as.h asintl.h bignum.h bit_fix.h config.h emul.h expr.h flonum.h \
frags.h hash.h listing.h obj.h read.h symbols.h tc.h write.h
-gasp_new_SOURCES = gasp.c macro.c sb.c hash.c
-gasp_new_LDADD = ../libiberty/libiberty.a $(INTLLIBS)
-gasp_new_DEPENDENCIES = ../libiberty/libiberty.a $(INTLDEPS)
-
EXPECT = `if [ -f $${rootme}/../expect/expect ] ; then \
echo $${rootme}/../expect/expect ; \
else echo expect ; fi`
@@ -596,6 +610,9 @@ e-crisaout.o: $(srcdir)/config/e-crisaout.c
e-criself.o: $(srcdir)/config/e-criself.c
$(COMPILE) -c $(srcdir)/config/e-criself.c
+xtensa-relax.o: $(srcdir)/config/xtensa-relax.c
+ $(COMPILE) -c $(srcdir)/config/xtensa-relax.c
+
# The m68k operand parser.
EXTRA_as_new_SOURCES = config/m68k-parse.y
@@ -642,7 +659,7 @@ itbl-parse.c itbl-parse.h: $(srcdir)/itbl-parse.y
# stand-alone itbl assembler & disassembler
-EXTRA_PROGRAMS = gasp-new itbl-test
+EXTRA_PROGRAMS = itbl-test
itbl_test_SOURCES = itbl-parse.y itbl-lex.l
itbl_test_LDADD = itbl-tops.o itbl-test.o $(GASLIBS) @LEXLIB@
@@ -774,7 +791,7 @@ de-stage3:
DEP_FILE_DEPS = $(CFILES) $(HFILES) $(TARGET_CPU_CFILES) \
$(TARGET_CPU_HFILES) $(OBJ_FORMAT_CFILES) $(OBJ_FORMAT_HFILES)
-Makefile: $(BFDDIR)/configure.in
+CONFIG_STATUS_DEPENDENCIES = $(BFDDIR)/configure.in
# Automatic dependency computation. This is a real pain, because the
# dependencies change based on target_cpu_type and obj_format.
@@ -983,7 +1000,8 @@ DEPTC_alpha_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
subsegs.h $(INCDIR)/obstack.h struc-symbol.h ecoff.h \
$(INCDIR)/coff/sym.h $(INCDIR)/coff/ecoff.h $(INCDIR)/opcode/alpha.h \
$(INCDIR)/elf/alpha.h $(INCDIR)/elf/reloc-macros.h \
- dwarf2dbg.h $(INCDIR)/safe-ctype.h $(srcdir)/config/atof-vax.c
+ dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h $(INCDIR)/safe-ctype.h \
+ $(srcdir)/config/atof-vax.c
DEPTC_alpha_evax = $(INCDIR)/symcat.h $(srcdir)/config/obj-evax.h \
$(srcdir)/config/tc-alpha.h subsegs.h $(INCDIR)/obstack.h \
struc-symbol.h ecoff.h $(INCDIR)/opcode/alpha.h $(INCDIR)/safe-ctype.h \
@@ -1072,26 +1090,25 @@ DEPTC_fr30_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(srcdir)/../opcodes/fr30-opc.h cgen.h
DEPTC_frv_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-frv.h $(INCDIR)/coff/internal.h \
- $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h dwarf2dbg.h \
- subsegs.h $(INCDIR)/obstack.h $(srcdir)/../opcodes/frv-desc.h \
- $(INCDIR)/opcode/cgen.h $(srcdir)/../opcodes/frv-opc.h \
- cgen.h $(BFDDIR)/libbfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/frv.h \
- $(INCDIR)/elf/reloc-macros.h
+ $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h subsegs.h $(INCDIR)/obstack.h \
+ $(srcdir)/../opcodes/frv-desc.h $(INCDIR)/opcode/cgen.h \
+ $(srcdir)/../opcodes/frv-opc.h cgen.h $(BFDDIR)/libbfd.h \
+ $(INCDIR)/elf/common.h $(INCDIR)/elf/frv.h $(INCDIR)/elf/reloc-macros.h
DEPTC_frv_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-frv.h \
- dwarf2dbg.h subsegs.h $(INCDIR)/obstack.h $(srcdir)/../opcodes/frv-desc.h \
+ subsegs.h $(INCDIR)/obstack.h $(srcdir)/../opcodes/frv-desc.h \
$(INCDIR)/opcode/cgen.h $(srcdir)/../opcodes/frv-opc.h \
cgen.h $(BFDDIR)/libbfd.h $(INCDIR)/elf/frv.h $(INCDIR)/elf/reloc-macros.h
DEPTC_h8300_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-h8300.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/h8300.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
- $(INCDIR)/bfdlink.h subsegs.h $(INCDIR)/obstack.h $(INCDIR)/opcode/h8300.h \
- $(INCDIR)/safe-ctype.h
+ $(INCDIR)/bfdlink.h subsegs.h $(INCDIR)/obstack.h dwarf2dbg.h \
+ $(INCDIR)/opcode/h8300.h $(INCDIR)/safe-ctype.h
DEPTC_h8300_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-h8300.h \
- subsegs.h $(INCDIR)/obstack.h $(INCDIR)/opcode/h8300.h \
+ subsegs.h $(INCDIR)/obstack.h dwarf2dbg.h $(INCDIR)/opcode/h8300.h \
$(INCDIR)/safe-ctype.h $(INCDIR)/elf/h8.h $(INCDIR)/elf/reloc-macros.h
DEPTC_h8500_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-h8500.h $(INCDIR)/coff/internal.h \
@@ -1132,21 +1149,23 @@ DEPTC_i370_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-i370.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/opcode/i370.h $(INCDIR)/elf/i370.h
+ struc-symbol.h $(INCDIR)/opcode/i370.h $(INCDIR)/elf/i370.h \
+ $(INCDIR)/elf/reloc-macros.h
DEPTC_i386_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-i386.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- dwarf2dbg.h $(INCDIR)/opcode/i386.h
+ dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h $(INCDIR)/opcode/i386.h
DEPTC_i386_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-i386.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/i386.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
$(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h subsegs.h \
- $(INCDIR)/obstack.h dwarf2dbg.h $(INCDIR)/opcode/i386.h
+ $(INCDIR)/obstack.h dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h \
+ $(INCDIR)/opcode/i386.h
DEPTC_i386_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-i386.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- dwarf2dbg.h $(INCDIR)/opcode/i386.h
+ dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h $(INCDIR)/opcode/i386.h
DEPTC_i860_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-i860.h \
@@ -1163,6 +1182,19 @@ DEPTC_i960_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-i960.h \
$(INCDIR)/safe-ctype.h $(INCDIR)/obstack.h $(INCDIR)/opcode/i960.h
+DEPTC_ip2k_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
+ $(srcdir)/config/tc-ip2k.h $(INCDIR)/coff/internal.h \
+ $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h subsegs.h $(INCDIR)/obstack.h \
+ $(srcdir)/../opcodes/ip2k-desc.h $(INCDIR)/opcode/cgen.h \
+ $(srcdir)/../opcodes/ip2k-opc.h cgen.h $(INCDIR)/elf/common.h \
+ $(INCDIR)/elf/ip2k.h $(INCDIR)/elf/reloc-macros.h $(BFDDIR)/libbfd.h
+DEPTC_ip2k_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-ip2k.h \
+ subsegs.h $(INCDIR)/obstack.h $(srcdir)/../opcodes/ip2k-desc.h \
+ $(INCDIR)/opcode/cgen.h $(srcdir)/../opcodes/ip2k-opc.h \
+ cgen.h $(INCDIR)/elf/ip2k.h $(INCDIR)/elf/reloc-macros.h \
+ $(BFDDIR)/libbfd.h
DEPTC_m32r_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-m32r.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h \
@@ -1179,32 +1211,37 @@ DEPTC_m68hc11_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-m68hc11.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/m68k.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
$(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h subsegs.h \
- $(INCDIR)/obstack.h $(INCDIR)/opcode/m68hc11.h dwarf2dbg.h
+ $(INCDIR)/obstack.h $(INCDIR)/opcode/m68hc11.h dwarf2dbg.h \
+ $(INCDIR)/elf/m68hc11.h $(INCDIR)/elf/reloc-macros.h
DEPTC_m68hc11_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-m68hc11.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- $(INCDIR)/opcode/m68hc11.h dwarf2dbg.h
+ $(INCDIR)/opcode/m68hc11.h dwarf2dbg.h $(INCDIR)/elf/m68hc11.h \
+ $(INCDIR)/elf/reloc-macros.h
DEPTC_m68k_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-m68k.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/safe-ctype.h $(INCDIR)/obstack.h subsegs.h \
- dwarf2dbg.h $(INCDIR)/opcode/m68k.h $(srcdir)/config/m68k-parse.h
+ dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h $(INCDIR)/opcode/m68k.h \
+ $(srcdir)/config/m68k-parse.h
DEPTC_m68k_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-m68k.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/m68k.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
$(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h $(INCDIR)/obstack.h \
- subsegs.h dwarf2dbg.h $(INCDIR)/opcode/m68k.h $(srcdir)/config/m68k-parse.h
+ subsegs.h dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h \
+ $(INCDIR)/opcode/m68k.h $(srcdir)/config/m68k-parse.h
DEPTC_m68k_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-m68k.h \
$(INCDIR)/safe-ctype.h $(INCDIR)/obstack.h subsegs.h \
- dwarf2dbg.h $(INCDIR)/opcode/m68k.h $(srcdir)/config/m68k-parse.h \
- $(INCDIR)/elf/m68k.h $(INCDIR)/elf/reloc-macros.h
+ dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h $(INCDIR)/opcode/m68k.h \
+ $(srcdir)/config/m68k-parse.h $(INCDIR)/elf/m68k.h \
+ $(INCDIR)/elf/reloc-macros.h
DEPTC_m68k_hp300 = $(INCDIR)/symcat.h $(srcdir)/config/obj-hp300.h \
$(srcdir)/config/obj-aout.h $(srcdir)/config/tc-m68k.h \
$(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h \
- $(INCDIR)/obstack.h subsegs.h dwarf2dbg.h $(INCDIR)/opcode/m68k.h \
- $(srcdir)/config/m68k-parse.h
+ $(INCDIR)/obstack.h subsegs.h dwarf2dbg.h dw2gencfi.h \
+ $(INCDIR)/elf/dwarf2.h $(INCDIR)/opcode/m68k.h $(srcdir)/config/m68k-parse.h
DEPTC_m88k_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-m88k.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/m88k.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
@@ -1279,6 +1316,15 @@ DEPTC_mn10300_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mn10300.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
$(INCDIR)/opcode/mn10300.h dwarf2dbg.h
+DEPTC_msp430_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
+ $(srcdir)/config/tc-msp430.h $(INCDIR)/coff/internal.h \
+ $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h subsegs.h $(INCDIR)/obstack.h \
+ $(INCDIR)/opcode/msp430.h $(INCDIR)/safe-ctype.h
+DEPTC_msp430_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-msp430.h \
+ subsegs.h $(INCDIR)/obstack.h $(INCDIR)/opcode/msp430.h \
+ $(INCDIR)/safe-ctype.h
DEPTC_ns32k_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-ns32k.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/opcode/ns32k.h $(INCDIR)/obstack.h
@@ -1334,56 +1380,59 @@ DEPTC_ppc_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-ppc.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/rs6000.h $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- $(INCDIR)/opcode/ppc.h
+ dw2gencfi.h $(INCDIR)/elf/dwarf2.h $(INCDIR)/opcode/ppc.h
DEPTC_ppc_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-ppc.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- $(INCDIR)/opcode/ppc.h $(INCDIR)/elf/ppc.h $(INCDIR)/elf/reloc-macros.h \
- dwarf2dbg.h
+ dw2gencfi.h $(INCDIR)/elf/dwarf2.h $(INCDIR)/opcode/ppc.h \
+ $(INCDIR)/elf/ppc.h $(INCDIR)/elf/reloc-macros.h dwarf2dbg.h
DEPTC_s390_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-s390.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h \
- subsegs.h $(INCDIR)/obstack.h struc-symbol.h $(INCDIR)/opcode/s390.h \
+ subsegs.h $(INCDIR)/obstack.h struc-symbol.h dwarf2dbg.h \
+ dw2gencfi.h $(INCDIR)/elf/dwarf2.h $(INCDIR)/opcode/s390.h \
$(INCDIR)/elf/s390.h $(INCDIR)/elf/reloc-macros.h
DEPTC_s390_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-s390.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/opcode/s390.h $(INCDIR)/elf/s390.h \
- $(INCDIR)/elf/reloc-macros.h
+ struc-symbol.h dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h \
+ $(INCDIR)/opcode/s390.h $(INCDIR)/elf/s390.h $(INCDIR)/elf/reloc-macros.h
DEPTC_sh_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-sh.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/sh.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
$(INCDIR)/bfdlink.h subsegs.h $(INCDIR)/obstack.h $(srcdir)/../opcodes/sh-opc.h \
- $(INCDIR)/safe-ctype.h struc-symbol.h dwarf2dbg.h
+ $(INCDIR)/safe-ctype.h struc-symbol.h dwarf2dbg.h dw2gencfi.h
DEPTC_sh_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-sh.h \
subsegs.h $(INCDIR)/obstack.h $(srcdir)/../opcodes/sh-opc.h \
$(INCDIR)/safe-ctype.h struc-symbol.h $(INCDIR)/elf/sh.h \
- $(INCDIR)/elf/reloc-macros.h dwarf2dbg.h
+ $(INCDIR)/elf/reloc-macros.h dwarf2dbg.h dw2gencfi.h
DEPTC_sh64_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-sh64.h \
$(srcdir)/config/tc-sh.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
- $(INCDIR)/safe-ctype.h $(srcdir)/../opcodes/sh64-opc.h \
+ $(BFDDIR)/elf32-sh64.h $(INCDIR)/safe-ctype.h $(srcdir)/../opcodes/sh64-opc.h \
$(srcdir)/config/tc-sh.c subsegs.h $(INCDIR)/obstack.h \
- $(srcdir)/../opcodes/sh-opc.h struc-symbol.h dwarf2dbg.h
+ $(srcdir)/../opcodes/sh-opc.h struc-symbol.h dwarf2dbg.h dw2gencfi.h
DEPTC_sparc_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-sparc.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- $(INCDIR)/opcode/sparc.h
+ $(INCDIR)/opcode/sparc.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h
DEPTC_sparc_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-sparc.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/sparc.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
$(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h subsegs.h \
- $(INCDIR)/obstack.h $(INCDIR)/opcode/sparc.h
+ $(INCDIR)/obstack.h $(INCDIR)/opcode/sparc.h dw2gencfi.h \
+ $(INCDIR)/elf/dwarf2.h
DEPTC_sparc_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-sparc.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- $(INCDIR)/opcode/sparc.h $(INCDIR)/elf/sparc.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/opcode/sparc.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h \
+ $(INCDIR)/elf/sparc.h $(INCDIR)/elf/reloc-macros.h \
dwarf2dbg.h
DEPTC_tahoe_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-tahoe.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
@@ -1407,6 +1456,16 @@ DEPTC_tic30_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-tic30.h \
$(INCDIR)/safe-ctype.h $(INCDIR)/opcode/tic30.h
+DEPTC_tic4x_coff = $(INCDIR)/safe-ctype.h $(INCDIR)/symcat.h \
+ $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-tic4x.h \
+ $(INCDIR)/coff/internal.h $(INCDIR)/coff/tic4x.h $(INCDIR)/coff/ti.h \
+ $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/opcode/tic4x.h \
+ subsegs.h $(INCDIR)/obstack.h
+DEPTC_tic4x_elf = $(INCDIR)/safe-ctype.h $(INCDIR)/symcat.h \
+ $(srcdir)/config/obj-elf.h $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h \
+ $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h \
+ $(srcdir)/config/tc-tic4x.h $(INCDIR)/opcode/tic4x.h \
+ subsegs.h $(INCDIR)/obstack.h
DEPTC_tic54x_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-tic54x.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/tic54x.h $(INCDIR)/coff/ti.h $(BFDDIR)/libcoff.h \
@@ -1477,6 +1536,13 @@ DEPTC_xstormy16_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
subsegs.h $(INCDIR)/obstack.h $(srcdir)/../opcodes/xstormy16-desc.h \
$(INCDIR)/opcode/cgen.h $(srcdir)/../opcodes/xstormy16-opc.h \
cgen.h
+DEPTC_xtensa_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-xtensa.h \
+ $(INCDIR)/xtensa-config.h sb.h $(INCDIR)/safe-ctype.h \
+ subsegs.h $(INCDIR)/obstack.h $(srcdir)/config/xtensa-relax.h \
+ $(INCDIR)/xtensa-isa.h $(srcdir)/config/xtensa-istack.h \
+ dwarf2dbg.h struc-symbol.h
DEPTC_z8k_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-z8k.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/z8k.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
@@ -1504,7 +1570,7 @@ DEPOBJ_a29k_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-a29k.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_alpha_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-alpha.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
@@ -1517,20 +1583,20 @@ DEPOBJ_alpha_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-alpha.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h ecoff.h $(INCDIR)/coff/sym.h $(INCDIR)/coff/ecoff.h \
- $(INCDIR)/elf/alpha.h $(INCDIR)/elf/reloc-macros.h \
+ struc-symbol.h dwarf2dbg.h ecoff.h $(INCDIR)/coff/sym.h \
+ $(INCDIR)/coff/ecoff.h $(INCDIR)/elf/alpha.h $(INCDIR)/elf/reloc-macros.h \
$(INCDIR)/aout/aout64.h
DEPOBJ_alpha_evax = $(INCDIR)/symcat.h $(srcdir)/config/obj-evax.h \
$(srcdir)/config/tc-alpha.h
DEPOBJ_arc_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-arc.h $(INCDIR)/coff/internal.h \
- $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h struc-symbol.h \
- $(INCDIR)/obstack.h subsegs.h
+ $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
+ subsegs.h
DEPOBJ_arc_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-arc.h \
- struc-symbol.h $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- $(INCDIR)/aout/aout64.h
+ $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_arm_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-arm.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/aout/aout64.h $(INCDIR)/obstack.h
@@ -1542,7 +1608,7 @@ DEPOBJ_arm_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-arm.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_avr_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-avr.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
@@ -1551,7 +1617,7 @@ DEPOBJ_avr_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-avr.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_cris_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-cris.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/aout/aout64.h $(INCDIR)/obstack.h
@@ -1559,7 +1625,7 @@ DEPOBJ_cris_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-cris.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_d10v_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-d10v.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
@@ -1568,7 +1634,7 @@ DEPOBJ_d10v_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-d10v.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_d30v_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-d30v.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
@@ -1577,7 +1643,7 @@ DEPOBJ_d30v_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-d30v.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_dlx_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-dlx.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
@@ -1586,7 +1652,7 @@ DEPOBJ_dlx_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-dlx.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_fr30_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-fr30.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
@@ -1595,7 +1661,7 @@ DEPOBJ_fr30_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-fr30.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_frv_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-frv.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
@@ -1604,7 +1670,7 @@ DEPOBJ_frv_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-frv.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_h8300_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-h8300.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/h8300.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
@@ -1613,7 +1679,7 @@ DEPOBJ_h8300_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-h8300.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_h8500_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-h8500.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/h8500.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
@@ -1622,7 +1688,7 @@ DEPOBJ_h8500_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-h8500.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_hppa_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-hppa.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
@@ -1632,7 +1698,8 @@ DEPOBJ_hppa_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-hppa.h \
$(BFDDIR)/elf32-hppa.h $(BFDDIR)/libhppa.h $(INCDIR)/elf/hppa.h \
$(INCDIR)/elf/reloc-macros.h $(INCDIR)/safe-ctype.h \
- subsegs.h $(INCDIR)/obstack.h struc-symbol.h $(INCDIR)/aout/aout64.h
+ subsegs.h $(INCDIR)/obstack.h struc-symbol.h dwarf2dbg.h \
+ $(INCDIR)/aout/aout64.h
DEPOBJ_ia64_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-ia64.h $(INCDIR)/opcode/ia64.h \
$(INCDIR)/elf/ia64.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/internal.h \
@@ -1643,7 +1710,7 @@ DEPOBJ_ia64_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-ia64.h \
$(INCDIR)/opcode/ia64.h $(INCDIR)/elf/ia64.h $(INCDIR)/elf/reloc-macros.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_i370_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-i370.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
@@ -1652,7 +1719,8 @@ DEPOBJ_i370_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-i370.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/elf/i370.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/elf/i370.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/aout/aout64.h
DEPOBJ_i386_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-i386.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/aout/aout64.h $(INCDIR)/obstack.h
@@ -1664,12 +1732,12 @@ DEPOBJ_i386_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-i386.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_i860_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-i860.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_i960_bout = $(INCDIR)/symcat.h $(srcdir)/config/obj-bout.h \
$(srcdir)/config/tc-i960.h $(INCDIR)/obstack.h
DEPOBJ_i960_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
@@ -1680,7 +1748,16 @@ DEPOBJ_i960_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-i960.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
+DEPOBJ_ip2k_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
+ $(srcdir)/config/tc-ip2k.h $(INCDIR)/coff/internal.h \
+ $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
+ subsegs.h
+DEPOBJ_ip2k_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-ip2k.h \
+ $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_m32r_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-m32r.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
@@ -1689,7 +1766,7 @@ DEPOBJ_m32r_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-m32r.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_m68hc11_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-m68hc11.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/m68k.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
@@ -1698,7 +1775,7 @@ DEPOBJ_m68hc11_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-m68hc11.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_m68k_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-m68k.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/aout/aout64.h $(INCDIR)/obstack.h
@@ -1710,7 +1787,7 @@ DEPOBJ_m68k_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-m68k.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_m68k_hp300 = $(srcdir)/config/obj-aout.c $(INCDIR)/symcat.h \
$(srcdir)/config/obj-aout.h $(srcdir)/config/tc-m68k.h \
$(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h $(INCDIR)/aout/aout64.h \
@@ -1723,7 +1800,7 @@ DEPOBJ_m88k_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-m88k.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_mcore_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-mcore.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/mcore.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
@@ -1732,7 +1809,7 @@ DEPOBJ_mcore_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mcore.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_mips_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-mips.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/aout/aout64.h $(INCDIR)/obstack.h
@@ -1748,13 +1825,14 @@ DEPOBJ_mips_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mips.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h ecoff.h $(INCDIR)/coff/sym.h $(INCDIR)/coff/ecoff.h \
- $(INCDIR)/elf/mips.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h ecoff.h $(INCDIR)/coff/sym.h \
+ $(INCDIR)/coff/ecoff.h $(INCDIR)/elf/mips.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/aout/aout64.h
DEPOBJ_mmix_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mmix.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_mn10200_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-mn10200.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
@@ -1763,7 +1841,7 @@ DEPOBJ_mn10200_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mn10200.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_mn10300_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-mn10300.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
@@ -1772,7 +1850,16 @@ DEPOBJ_mn10300_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mn10300.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
+DEPOBJ_msp430_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
+ $(srcdir)/config/tc-msp430.h $(INCDIR)/coff/internal.h \
+ $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
+ subsegs.h
+DEPOBJ_msp430_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-msp430.h \
+ $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_ns32k_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-ns32k.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/aout/aout64.h $(INCDIR)/obstack.h
@@ -1784,7 +1871,7 @@ DEPOBJ_ns32k_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-ns32k.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_openrisc_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-openrisc.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
@@ -1793,7 +1880,7 @@ DEPOBJ_openrisc_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-openrisc.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_or32_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-or32.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/or32.h $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h \
@@ -1802,7 +1889,7 @@ DEPOBJ_or32_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-or32.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_pdp11_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-pdp11.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/aout/aout64.h $(INCDIR)/obstack.h
@@ -1814,7 +1901,7 @@ DEPOBJ_pdp11_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-pdp11.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_pj_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-pj.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
@@ -1823,7 +1910,7 @@ DEPOBJ_pj_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-pj.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_ppc_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-ppc.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/rs6000.h $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h \
@@ -1832,7 +1919,7 @@ DEPOBJ_ppc_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-ppc.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/elf/ppc.h $(INCDIR)/elf/reloc-macros.h \
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/elf/ppc.h $(INCDIR)/elf/reloc-macros.h \
$(INCDIR)/aout/aout64.h
DEPOBJ_s390_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-s390.h $(INCDIR)/coff/internal.h \
@@ -1842,7 +1929,7 @@ DEPOBJ_s390_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-s390.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_sh_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-sh.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/sh.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
@@ -1851,18 +1938,13 @@ DEPOBJ_sh_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-sh.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
-DEPOBJ_sh64_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
- $(srcdir)/config/tc-sh64.h $(srcdir)/config/tc-sh.h \
- $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/internal.h \
- $(INCDIR)/coff/sh.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
- $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h subsegs.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_sh64_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-sh64.h \
$(srcdir)/config/tc-sh.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
- $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ $(BFDDIR)/elf32-sh64.h $(INCDIR)/safe-ctype.h subsegs.h \
+ $(INCDIR)/obstack.h struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_sparc_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-sparc.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/aout/aout64.h $(INCDIR)/obstack.h
@@ -1874,7 +1956,7 @@ DEPOBJ_sparc_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-sparc.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_tahoe_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-tahoe.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/aout/aout64.h $(INCDIR)/obstack.h
@@ -1886,7 +1968,7 @@ DEPOBJ_tahoe_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-tahoe.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_tic30_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-tic30.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/aout/aout64.h $(INCDIR)/obstack.h
@@ -1898,7 +1980,16 @@ DEPOBJ_tic30_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-tic30.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
+DEPOBJ_tic4x_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
+ $(srcdir)/config/tc-tic4x.h $(INCDIR)/coff/internal.h \
+ $(INCDIR)/coff/tic4x.h $(INCDIR)/coff/ti.h $(BFDDIR)/libcoff.h \
+ $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h subsegs.h
+DEPOBJ_tic4x_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-tic4x.h \
+ $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_tic54x_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-tic54x.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/tic54x.h $(INCDIR)/coff/ti.h $(BFDDIR)/libcoff.h \
@@ -1907,7 +1998,7 @@ DEPOBJ_tic54x_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-tic54x.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_tic80_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-tic80.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/tic80.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
@@ -1916,7 +2007,7 @@ DEPOBJ_tic80_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-tic80.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_vax_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-vax.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/aout/aout64.h $(INCDIR)/obstack.h
@@ -1928,7 +2019,7 @@ DEPOBJ_vax_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-vax.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_vax_vms = $(INCDIR)/symcat.h $(srcdir)/config/obj-vms.h \
$(srcdir)/config/tc-vax.h $(INCDIR)/aout/stab_gnu.h \
$(INCDIR)/aout/stab.def $(INCDIR)/safe-ctype.h subsegs.h \
@@ -1941,7 +2032,7 @@ DEPOBJ_w65_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-w65.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_v850_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-v850.h $(INCDIR)/elf/v850.h $(INCDIR)/elf/reloc-macros.h \
$(INCDIR)/coff/internal.h $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h \
@@ -1950,7 +2041,8 @@ DEPOBJ_v850_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-v850.h \
$(INCDIR)/elf/v850.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/safe-ctype.h \
- subsegs.h $(INCDIR)/obstack.h struc-symbol.h $(INCDIR)/aout/aout64.h
+ subsegs.h $(INCDIR)/obstack.h struc-symbol.h dwarf2dbg.h \
+ $(INCDIR)/aout/aout64.h
DEPOBJ_xstormy16_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-xstormy16.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
@@ -1959,7 +2051,12 @@ DEPOBJ_xstormy16_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-xstormy16.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
+DEPOBJ_xtensa_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-xtensa.h \
+ $(INCDIR)/xtensa-config.h $(INCDIR)/safe-ctype.h subsegs.h \
+ $(INCDIR)/obstack.h struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_z8k_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-z8k.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/z8k.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
@@ -1968,7 +2065,7 @@ DEPOBJ_z8k_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-z8k.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_hppa_som = $(srcdir)/config/obj-som.h subsegs.h \
$(INCDIR)/obstack.h $(BFDDIR)/libhppa.h $(BFDDIR)/som.h \
$(INCDIR)/aout/stab_gnu.h $(INCDIR)/aout/stab.def
@@ -2101,6 +2198,12 @@ DEP_i960_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-i960.h \
DEP_i960_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-i960.h
+DEP_ip2k_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-ip2k.h \
+ $(INCDIR)/symcat.h $(INCDIR)/coff/internal.h $(BFDDIR)/libcoff.h \
+ $(INCDIR)/bfdlink.h
+DEP_ip2k_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-ip2k.h
DEP_m32r_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-m32r.h \
$(INCDIR)/symcat.h $(INCDIR)/coff/internal.h $(BFDDIR)/libcoff.h \
$(INCDIR)/bfdlink.h
@@ -2160,6 +2263,12 @@ DEP_mn10300_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-mn10300.h \
DEP_mn10300_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mn10300.h
+DEP_msp430_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-msp430.h \
+ $(INCDIR)/symcat.h $(INCDIR)/coff/internal.h $(BFDDIR)/libcoff.h \
+ $(INCDIR)/bfdlink.h
+DEP_msp430_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-msp430.h
DEP_ns32k_aout = $(srcdir)/config/obj-aout.h $(srcdir)/config/tc-ns32k.h \
$(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h
DEP_ns32k_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-ns32k.h \
@@ -2212,14 +2321,11 @@ DEP_sh_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-sh.h \
DEP_sh_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-sh.h
-DEP_sh64_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-sh64.h \
- $(srcdir)/config/tc-sh.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
- $(INCDIR)/symcat.h $(INCDIR)/coff/internal.h $(INCDIR)/coff/sh.h \
- $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h
DEP_sh64_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-sh64.h \
- $(srcdir)/config/tc-sh.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h
+ $(srcdir)/config/tc-sh.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
+ $(BFDDIR)/elf32-sh64.h
DEP_sparc_aout = $(srcdir)/config/obj-aout.h $(srcdir)/config/tc-sparc.h \
$(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h
DEP_sparc_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-sparc.h \
@@ -2244,6 +2350,12 @@ DEP_tic30_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-tic30.h \
DEP_tic30_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-tic30.h
+DEP_tic4x_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-tic4x.h \
+ $(INCDIR)/symcat.h $(INCDIR)/coff/internal.h $(INCDIR)/coff/tic4x.h \
+ $(INCDIR)/coff/ti.h $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h
+DEP_tic4x_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-tic4x.h
DEP_tic54x_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-tic54x.h \
$(INCDIR)/symcat.h $(INCDIR)/coff/internal.h $(INCDIR)/coff/tic54x.h \
$(INCDIR)/coff/ti.h $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h
@@ -2285,6 +2397,10 @@ DEP_xstormy16_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-xstormy16.h
DEP_xstormy16_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-xstormy16.h
+DEP_xtensa_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-xtensa.h \
+ $(INCDIR)/xtensa-config.h
DEP_z8k_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-z8k.h \
$(INCDIR)/symcat.h $(INCDIR)/coff/internal.h $(INCDIR)/coff/z8k.h \
$(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h
@@ -2301,13 +2417,17 @@ BMKDEP = #DO NOT PUT ANYTHING BETWEEN THIS LINE AND THE MATCHING WARNING ABOVE.
#MKDEP DO NOT PUT ANYTHING BETWEEN THIS LINE AND THE MATCHING WARNING BELOW.
app.o: app.c $(INCDIR)/symcat.h
as.o: as.c $(INCDIR)/symcat.h subsegs.h $(INCDIR)/obstack.h \
- output-file.h sb.h macro.h dwarf2dbg.h
+ output-file.h sb.h macro.h dwarf2dbg.h dw2gencfi.h \
+ $(INCDIR)/elf/dwarf2.h $(BFDVER_H)
atof-generic.o: atof-generic.c $(INCDIR)/symcat.h $(INCDIR)/safe-ctype.h
bignum-copy.o: bignum-copy.c $(INCDIR)/symcat.h
cond.o: cond.c $(INCDIR)/symcat.h macro.h sb.h $(INCDIR)/obstack.h
depend.o: depend.c $(INCDIR)/symcat.h
dwarf2dbg.o: dwarf2dbg.c $(INCDIR)/symcat.h dwarf2dbg.h \
- subsegs.h $(INCDIR)/obstack.h $(INCDIR)/elf/dwarf2.h
+ $(INCDIR)/filenames.h subsegs.h $(INCDIR)/obstack.h \
+ $(INCDIR)/elf/dwarf2.h
+dw2gencfi.o: dw2gencfi.c $(INCDIR)/symcat.h dw2gencfi.h \
+ $(INCDIR)/elf/dwarf2.h
ecoff.o: ecoff.c $(INCDIR)/symcat.h ecoff.h
ehopt.o: ehopt.c $(INCDIR)/symcat.h subsegs.h $(INCDIR)/obstack.h \
$(INCDIR)/elf/dwarf2.h
@@ -2330,7 +2450,8 @@ macro.o: macro.c $(INCDIR)/safe-ctype.h sb.h macro.h
messages.o: messages.c $(INCDIR)/symcat.h
output-file.o: output-file.c $(INCDIR)/symcat.h output-file.h
read.o: read.c $(INCDIR)/symcat.h $(INCDIR)/safe-ctype.h \
- subsegs.h $(INCDIR)/obstack.h sb.h macro.h ecoff.h
+ subsegs.h $(INCDIR)/obstack.h sb.h macro.h ecoff.h \
+ dw2gencfi.h $(INCDIR)/elf/dwarf2.h
sb.o: sb.c sb.h
stabs.o: stabs.c $(INCDIR)/symcat.h $(INCDIR)/obstack.h \
subsegs.h ecoff.h $(INCDIR)/aout/stab_gnu.h $(INCDIR)/aout/stab.def
@@ -2339,8 +2460,6 @@ symbols.o: symbols.c $(INCDIR)/symcat.h $(INCDIR)/safe-ctype.h \
$(INCDIR)/obstack.h subsegs.h struc-symbol.h
write.o: write.c $(INCDIR)/symcat.h subsegs.h $(INCDIR)/obstack.h \
output-file.h dwarf2dbg.h
-gasp.o: gasp.c $(INCDIR)/getopt.h $(INCDIR)/safe-ctype.h \
- sb.h macro.h $(INCDIR)/xregex.h $(INCDIR)/xregex2.h
itbl-ops.o: itbl-ops.c itbl-ops.h $(INCDIR)/symcat.h
e-crisaout.o: $(srcdir)/config/e-crisaout.c $(INCDIR)/symcat.h \
emul-target.h
diff --git a/contrib/binutils/gas/Makefile.in b/contrib/binutils/gas/Makefile.in
index c411820..67ed432 100644
--- a/contrib/binutils/gas/Makefile.in
+++ b/contrib/binutils/gas/Makefile.in
@@ -1,6 +1,8 @@
-# Makefile.in generated automatically by automake 1.4-p5 from Makefile.am
+# Makefile.in generated by automake 1.8.4 from Makefile.am.
+# @configure_input@
-# Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc.
+# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+# 2003, 2004 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
@@ -10,124 +12,244 @@
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
# PARTICULAR PURPOSE.
+@SET_MAKE@
-SHELL = @SHELL@
+
+SOURCES = $(as_new_SOURCES) $(EXTRA_as_new_SOURCES) $(itbl_test_SOURCES)
srcdir = @srcdir@
top_srcdir = @top_srcdir@
VPATH = @srcdir@
-prefix = @prefix@
-exec_prefix = @exec_prefix@
-
-bindir = @bindir@
-sbindir = @sbindir@
-libexecdir = @libexecdir@
-datadir = @datadir@
-sysconfdir = @sysconfdir@
-sharedstatedir = @sharedstatedir@
-localstatedir = @localstatedir@
-libdir = @libdir@
-infodir = @infodir@
-mandir = @mandir@
-includedir = @includedir@
-oldincludedir = /usr/include
-
-DESTDIR =
-
pkgdatadir = $(datadir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
pkgincludedir = $(includedir)/@PACKAGE@
-
top_builddir = .
-
-ACLOCAL = @ACLOCAL@
-AUTOCONF = @AUTOCONF@
-AUTOMAKE = @AUTOMAKE@
-AUTOHEADER = @AUTOHEADER@
-
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
INSTALL = @INSTALL@
-INSTALL_PROGRAM = @INSTALL_PROGRAM@ $(AM_INSTALL_PROGRAM_FLAGS)
-INSTALL_DATA = @INSTALL_DATA@
-INSTALL_SCRIPT = @INSTALL_SCRIPT@
-transform = @program_transform_name@
-
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
-build_alias = @build_alias@
build_triplet = @build@
-host_alias = @host_alias@
host_triplet = @host@
-target_alias = @target_alias@
target_triplet = @target@
+noinst_PROGRAMS = as-new$(EXEEXT)
+EXTRA_PROGRAMS = itbl-test$(EXEEXT)
+DIST_COMMON = $(srcdir)/../config.guess $(srcdir)/../config.sub NEWS \
+ README ChangeLog $(srcdir)/Makefile.in $(srcdir)/Makefile.am \
+ $(top_srcdir)/configure $(am__configure_deps) \
+ $(srcdir)/config.in $(srcdir)/../mkinstalldirs \
+ $(srcdir)/gdbinit.in $(srcdir)/gdbinit.in \
+ $(top_srcdir)/po/Make-in m68k-parse.c itbl-parse.c itbl-lex.c \
+ $(srcdir)/../ylwrap $(srcdir)/../ltmain.sh \
+ $(srcdir)/../config.guess $(srcdir)/../config.sub
+subdir = .
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/acinclude.m4 \
+ $(top_srcdir)/../libtool.m4 $(top_srcdir)/../gettext.m4 \
+ $(top_srcdir)/configure.in
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \
+ configure.lineno configure.status.lineno
+mkinstalldirs = $(SHELL) $(top_srcdir)/../mkinstalldirs
+CONFIG_HEADER = config.h
+CONFIG_CLEAN_FILES = gdb.ini .gdbinit po/Makefile.in
+PROGRAMS = $(noinst_PROGRAMS)
+am__objects_1 = app.$(OBJEXT) as.$(OBJEXT) atof-generic.$(OBJEXT) \
+ bignum-copy.$(OBJEXT) cond.$(OBJEXT) depend.$(OBJEXT) \
+ dwarf2dbg.$(OBJEXT) dw2gencfi.$(OBJEXT) ecoff.$(OBJEXT) \
+ ehopt.$(OBJEXT) expr.$(OBJEXT) flonum-copy.$(OBJEXT) \
+ flonum-konst.$(OBJEXT) flonum-mult.$(OBJEXT) frags.$(OBJEXT) \
+ hash.$(OBJEXT) input-file.$(OBJEXT) input-scrub.$(OBJEXT) \
+ listing.$(OBJEXT) literal.$(OBJEXT) macro.$(OBJEXT) \
+ messages.$(OBJEXT) output-file.$(OBJEXT) read.$(OBJEXT) \
+ sb.$(OBJEXT) stabs.$(OBJEXT) subsegs.$(OBJEXT) \
+ symbols.$(OBJEXT) write.$(OBJEXT)
+am_as_new_OBJECTS = $(am__objects_1)
+as_new_OBJECTS = $(am_as_new_OBJECTS)
+am__DEPENDENCIES_1 = tc-@target_cpu_type@.o
+am__DEPENDENCIES_2 = obj-@obj_format@.o
+am__DEPENDENCIES_3 = atof-@atof@.o
+am__DEPENDENCIES_4 =
+am__DEPENDENCIES_5 = ../libiberty/libiberty.a
+am_itbl_test_OBJECTS = itbl-parse.$(OBJEXT) itbl-lex.$(OBJEXT)
+itbl_test_OBJECTS = $(am_itbl_test_OBJECTS)
+itbl_test_DEPENDENCIES = itbl-tops.o itbl-test.o $(am__DEPENDENCIES_5)
+SCRIPTS = $(noinst_SCRIPTS)
+DEFAULT_INCLUDES = -I. -I$(srcdir) -I.
+depcomp =
+am__depfiles_maybe =
+COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
+ $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) \
+ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+ $(AM_CFLAGS) $(CFLAGS)
+CCLD = $(CC)
+LINK = $(LIBTOOL) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+ $(AM_LDFLAGS) $(LDFLAGS) -o $@
+LEXCOMPILE = $(LEX) $(LFLAGS) $(AM_LFLAGS)
+LTLEXCOMPILE = $(LIBTOOL) --mode=compile $(LEX) $(LFLAGS) $(AM_LFLAGS)
+YACCCOMPILE = $(YACC) $(YFLAGS) $(AM_YFLAGS)
+LTYACCCOMPILE = $(LIBTOOL) --mode=compile $(YACC) $(YFLAGS) \
+ $(AM_YFLAGS)
+YLWRAP = $(top_srcdir)/../ylwrap
+SOURCES = $(as_new_SOURCES) $(EXTRA_as_new_SOURCES) \
+ $(itbl_test_SOURCES)
+DIST_SOURCES = $(as_new_SOURCES) $(EXTRA_as_new_SOURCES) \
+ $(itbl_test_SOURCES)
+RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
+ html-recursive info-recursive install-data-recursive \
+ install-exec-recursive install-info-recursive \
+ install-recursive installcheck-recursive installdirs-recursive \
+ pdf-recursive ps-recursive uninstall-info-recursive \
+ uninstall-recursive
+ETAGS = etags
+CTAGS = ctags
+DEJATOOL = $(PACKAGE)
+RUNTESTDEFAULTFLAGS = --tool $$tool --srcdir $$srcdir
+ACLOCAL = @ACLOCAL@
+ALLOCA = @ALLOCA@
ALL_OBJ_DEPS = @ALL_OBJ_DEPS@
-AS = @AS@
+AMDEP_FALSE = @AMDEP_FALSE@
+AMDEP_TRUE = @AMDEP_TRUE@
+AMTAR = @AMTAR@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
BFDLIB = @BFDLIB@
+BFDVER_H = @BFDVER_H@
CATALOGS = @CATALOGS@
CATOBJEXT = @CATOBJEXT@
CC = @CC@
-CXX = @CXX@
-CXXCPP = @CXXCPP@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CYGPATH_W = @CYGPATH_W@
DATADIRNAME = @DATADIRNAME@
-DLLTOOL = @DLLTOOL@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
EXEEXT = @EXEEXT@
-GCJ = @GCJ@
-GCJFLAGS = @GCJFLAGS@
GDBINIT = @GDBINIT@
GMOFILES = @GMOFILES@
GMSGFMT = @GMSGFMT@
GT_NO = @GT_NO@
GT_YES = @GT_YES@
INCLUDE_LOCALE_H = @INCLUDE_LOCALE_H@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
INSTOBJEXT = @INSTOBJEXT@
INTLDEPS = @INTLDEPS@
+INTLLIBS = @INTLLIBS@
INTLOBJS = @INTLOBJS@
+LDFLAGS = @LDFLAGS@
+LEX = `if [ -f ../flex/flex ] ; then echo ../flex/flex ; else echo @LEX@ ; fi`
+LEXLIB = @LEXLIB@
+LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
LIBM = @LIBM@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
MAINT = @MAINT@
+MAINTAINER_MODE_FALSE = @MAINTAINER_MODE_FALSE@
+MAINTAINER_MODE_TRUE = @MAINTAINER_MODE_TRUE@
MAKEINFO = @MAKEINFO@
MKINSTALLDIRS = @MKINSTALLDIRS@
MSGFMT = @MSGFMT@
-OBJDUMP = @OBJDUMP@
OBJEXT = @OBJEXT@
OPCODES_LIB = @OPCODES_LIB@
PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
POFILES = @POFILES@
POSUB = @POSUB@
RANLIB = @RANLIB@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
STRIP = @STRIP@
USE_INCLUDED_LIBINTL = @USE_INCLUDED_LIBINTL@
USE_NLS = @USE_NLS@
VERSION = @VERSION@
+WARN_CFLAGS = @WARN_CFLAGS@
+XGETTEXT = @XGETTEXT@
+YACC = `if [ -f ../bison/bison ] ; then echo ../bison/bison -y -L../bison/bison ; else echo @YACC@ ; fi`
+ac_ct_CC = @ac_ct_CC@
+ac_ct_RANLIB = @ac_ct_RANLIB@
+ac_ct_STRIP = @ac_ct_STRIP@
+am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
+am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
atof = @atof@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
cgen_cpu_prefix = @cgen_cpu_prefix@
+datadir = @datadir@
+exec_prefix = @exec_prefix@
extra_objects = @extra_objects@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
install_tooldir = @install_tooldir@
l = @l@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localstatedir = @localstatedir@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
obj_format = @obj_format@
+oldincludedir = @oldincludedir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+sysconfdir = @sysconfdir@
+target = @target@
+target_alias = @target_alias@
+target_cpu = @target_cpu@
target_cpu_type = @target_cpu_type@
+target_os = @target_os@
+target_vendor = @target_vendor@
te_file = @te_file@
-
-INTLLIBS = @INTLLIBS@
-
-AUTOMAKE_OPTIONS = cygnus dejagnu
-
+AUTOMAKE_OPTIONS = 1.8 cygnus dejagnu
SUBDIRS = doc po
-
+# Automake should figure this out on its own. It doesn't, because
+# of the "cygnus" option. But distclean still wants it.
+DIST_SUBDIRS = $(SUBDIRS)
tooldir = $(exec_prefix)/$(target_alias)
-
-YACC = `if [ -f ../bison/bison ] ; then echo ../bison/bison -y -L../bison/bison ; else echo @YACC@ ; fi`
-LEX = `if [ -f ../flex/flex ] ; then echo ../flex/flex ; else echo @LEX@ ; fi`
-
-WARN_CFLAGS = @WARN_CFLAGS@
AM_CFLAGS = $(WARN_CFLAGS)
-
MKDEP = gcc -MM
-
TARG_CPU = @target_cpu_type@
TARG_CPU_C = $(srcdir)/config/tc-@target_cpu_type@.c
TARG_CPU_O = tc-@target_cpu_type@.o
@@ -146,7 +268,6 @@ IT_DEPS = $(srcdir)/itbl-parse.y $(srcdir)/itbl-lex.l $(srcdir)/config/itbl-@tar
IT_OBJS = itbl-parse.o itbl-lex.o itbl-ops.o
# CPU types. This is only used for dependency information.
-
CPU_TYPES = \
a29k \
alpha \
@@ -167,6 +288,7 @@ CPU_TYPES = \
i386 \
i860 \
i960 \
+ ip2k \
m32r \
m68hc11 \
m68k \
@@ -176,6 +298,7 @@ CPU_TYPES = \
mmix \
mn10200 \
mn10300 \
+ msp430 \
ns32k \
openrisc \
or32 \
@@ -188,18 +311,19 @@ CPU_TYPES = \
sparc \
tahoe \
tic30 \
+ tic4x \
tic54x \
tic80 \
vax \
w65 \
v850 \
xstormy16 \
+ xtensa \
z8k
# Object format types. This is only used for dependency information.
# We deliberately omit SOM, since it does not work as a cross assembler.
-
OBJ_FORMATS = \
aout \
bout \
@@ -216,13 +340,12 @@ OBJ_FORMATS = \
# type in the shell variable c and the OS type in the shell variable o
# are supported. This helps cuts down on the amount of dependency
# information.
-
CPU_OBJ_VALID = \
valid= ; \
case $$o in \
aout) \
case $$c in \
- a29k | arm | cris | i386 | m68k | mips | ns32k | pdp11 | sparc | tahoe | tic30 | vax) \
+ a29k | arm | cris | i386 | m68k | ns32k | pdp11 | sparc | tahoe | tic30 | vax) \
valid=yes ;; \
esac ;; \
bout) \
@@ -231,7 +354,7 @@ CPU_OBJ_VALID = \
esac ;; \
coff) valid=yes; \
case $$c in \
- cris | i860 | mmix) \
+ cris | i860 | mmix | sh64) \
valid= ;; \
esac ;; \
ecoff) \
@@ -255,9 +378,7 @@ CPU_OBJ_VALID = \
# These are like CPU_TYPES and CPU_OBJ_VALID, for the obj=multi case.
-
MULTI_CPU_TYPES = i386 mips cris
-
MULTI_CPU_OBJ_VALID = \
valid= ; \
case $$o in \
@@ -278,7 +399,6 @@ MULTI_CPU_OBJ_VALID = \
# Regular source files.
-
GAS_CFILES = \
app.c \
as.c \
@@ -287,6 +407,7 @@ GAS_CFILES = \
cond.c \
depend.c \
dwarf2dbg.c \
+ dw2gencfi.c \
ecoff.c \
ehopt.c \
expr.c \
@@ -309,9 +430,7 @@ GAS_CFILES = \
symbols.c \
write.c
-
-CFILES = $(GAS_CFILES) gasp.c itbl-ops.c
-
+CFILES = $(GAS_CFILES) itbl-ops.c
HFILES = \
as.h \
asintl.h \
@@ -319,6 +438,7 @@ HFILES = \
bit_fix.h \
cgen.h \
dwarf2dbg.h \
+ dw2gencfi.h \
ecoff.h \
emul-target.h \
emul.h \
@@ -342,7 +462,6 @@ HFILES = \
# CPU files in config.
-
TARGET_CPU_CFILES = \
config/tc-a29k.c \
config/tc-alpha.c \
@@ -363,6 +482,7 @@ TARGET_CPU_CFILES = \
config/tc-i386.c \
config/tc-i860.c \
config/tc-i960.c \
+ config/tc-ip2k.c \
config/tc-m32r.c \
config/tc-m68hc11.c \
config/tc-m68k.c \
@@ -372,6 +492,7 @@ TARGET_CPU_CFILES = \
config/tc-mmix.c \
config/tc-mn10200.c \
config/tc-mn10300.c \
+ config/tc-msp430.c \
config/tc-ns32k.c \
config/tc-openrisc.c \
config/tc-or32.c \
@@ -390,9 +511,9 @@ TARGET_CPU_CFILES = \
config/tc-w65.c \
config/tc-v850.c \
config/tc-xstormy16.c \
+ config/tc-xtensa.c \
config/tc-z8k.c
-
TARGET_CPU_HFILES = \
config/tc-a29k.h \
config/tc-alpha.h \
@@ -413,6 +534,7 @@ TARGET_CPU_HFILES = \
config/tc-i386.h \
config/tc-i860.h \
config/tc-i960.h \
+ config/tc-ip2k.h \
config/tc-m32r.h \
config/tc-m68hc11.h \
config/tc-m68k.h \
@@ -422,6 +544,7 @@ TARGET_CPU_HFILES = \
config/tc-mmix.h \
config/tc-mn10200.h \
config/tc-mn10300.h \
+ config/tc-msp430.h \
config/tc-ns32k.h \
config/tc-openrisc.h \
config/tc-or32.h \
@@ -440,11 +563,11 @@ TARGET_CPU_HFILES = \
config/tc-w65.h \
config/tc-v850.h \
config/tc-xstormy16.h \
+ config/tc-xtensa.h \
config/tc-z8k.h
# OBJ files in config
-
OBJ_FORMAT_CFILES = \
config/obj-aout.c \
config/obj-bout.c \
@@ -457,7 +580,6 @@ OBJ_FORMAT_CFILES = \
config/obj-som.c \
config/obj-vms.c
-
OBJ_FORMAT_HFILES = \
config/obj-aout.h \
config/obj-bout.h \
@@ -472,7 +594,6 @@ OBJ_FORMAT_HFILES = \
# Emulation header files in config
-
TARG_ENV_HFILES = \
config/te-386bsd.h \
config/te-aux.h \
@@ -510,7 +631,6 @@ TARG_ENV_HFILES = \
# Multi files in config
-
MULTI_CFILES = \
config/e-crisaout.c \
config/e-criself.c \
@@ -520,14 +640,12 @@ MULTI_CFILES = \
config/e-mipsecoff.c \
config/e-mipself.c
-
CONFIG_OBJS = \
$(TARG_CPU_O) \
$(OBJ_FORMAT_O) \
$(ATOF_TARG_O) \
$(extra_objects)
-
GENERIC_OBJS = \
app.o \
as.o \
@@ -536,6 +654,7 @@ GENERIC_OBJS = \
cond.o \
depend.o \
dwarf2dbg.o \
+ dw2gencfi.o \
ehopt.o \
expr.o \
flonum-konst.o \
@@ -558,26 +677,17 @@ GENERIC_OBJS = \
sb.o \
macro.o
-
OBJS = $(CONFIG_OBJS) $(GENERIC_OBJS)
-
POTFILES = $(MULTI_CFILES) $(TARGET_ENV_HFILES) $(OBJ_FORMAT_HFILES) \
$(OBJ_FORMAT_CFILES) $(TARGET_CPU_HFILES) $(TARGET_CPU_CFILES) \
$(HFILES) $(CFILES) $(GAS_CFILES)
-
-# Note: GASP is now deprecated and will be removed at some point in the future.
-# Anything that GASP could do can now be done by GAS.
-noinst_PROGRAMS = as-new
noinst_SCRIPTS = $(GDBINIT)
EXTRA_SCRIPTS = .gdbinit
-
EXTRA_DIST = make-gas.com m68k-parse.c itbl-parse.c itbl-parse.h itbl-lex.c
-
DISTCLEANFILES = targ-cpu.h obj-format.h targ-env.h itbl-cpu.h cgen-desc.h
# Now figure out from those variables how to compile and link.
-
BASEDIR = $(srcdir)/..
BFDDIR = $(BASEDIR)/bfd
INCDIR = $(BASEDIR)/include
@@ -594,19 +704,16 @@ INCLUDES = -D_GNU_SOURCE -I. -I$(srcdir) -I../bfd -I$(srcdir)/config -I$(INCDIR)
# when building dependencies, because the dependency building is done
# in a subdirectory.
DEP_INCLUDES = -D_GNU_SOURCE -I.. -I$${srcdir} -I../../bfd -I$${srcdir}/config -I$${srcdir}/../include -I$${srcdir}/.. -I$${srcdir}/../bfd -I$${srcdir}/../intl -I../../intl -DLOCALEDIR="\"$(prefix)/share/locale\""
-
DEP_FLAGS = -DBFD_ASSEMBLER -DOBJ_MAYBE_ELF \
-I. -I.. -I$${srcdir} -I../../bfd $(DEP_INCLUDES)
# How to link with both our special library facilities
# and the system's installed libraries.
-
GASLIBS = @OPCODES_LIB@ @BFDLIB@ ../libiberty/libiberty.a
# Files to be copied away after each stage in building.
STAGESTUFF = *.o $(noinst_PROGRAMS)
-
as_new_SOURCES = $(GAS_CFILES)
as_new_LDADD = $(TARG_CPU_O) $(OBJ_FORMAT_O) $(ATOF_TARG_O) \
$(extra_objects) $(GASLIBS) $(INTLLIBS) $(LIBM)
@@ -614,16 +721,10 @@ as_new_LDADD = $(TARG_CPU_O) $(OBJ_FORMAT_O) $(ATOF_TARG_O) \
as_new_DEPENDENCIES = $(TARG_CPU_O) $(OBJ_FORMAT_O) $(ATOF_TARG_O) \
$(extra_objects) $(GASLIBS) $(INTLDEPS)
-
-gasp_new_SOURCES = gasp.c macro.c sb.c hash.c
-gasp_new_LDADD = ../libiberty/libiberty.a $(INTLLIBS)
-gasp_new_DEPENDENCIES = ../libiberty/libiberty.a $(INTLDEPS)
-
EXPECT = `if [ -f $${rootme}/../expect/expect ] ; then \
echo $${rootme}/../expect/expect ; \
else echo expect ; fi`
-
RUNTEST = `if [ -f $${srcdir}/../dejagnu/runtest ] ; then \
echo $${srcdir}/../dejagnu/runtest ; else echo runtest; \
fi`
@@ -631,34 +732,24 @@ RUNTEST = `if [ -f $${srcdir}/../dejagnu/runtest ] ; then \
RUNTESTFLAGS =
# The m68k operand parser.
-
EXTRA_as_new_SOURCES = config/m68k-parse.y
-
-# stand-alone itbl assembler & disassembler
-
-EXTRA_PROGRAMS = gasp-new itbl-test
itbl_test_SOURCES = itbl-parse.y itbl-lex.l
itbl_test_LDADD = itbl-tops.o itbl-test.o $(GASLIBS) @LEXLIB@
# CGEN interface.
-
CGEN_CPU_PREFIX = @cgen_cpu_prefix@
# Remake the info files.
-
MOSTLYCLEANFILES = $(STAGESTUFF) core stamp-mk.com \
testsuite/*.o testsuite/*.out testsuite/gas.log testsuite/gas.sum \
testsuite/site.exp site.bak site.exp stage stage1 stage2
-
CLEANFILES = dep.sed DEPTC DEPTCA DEPOBJ DEPOBJA DEP2 DEP2A DEP1 DEPA DEP DEPDIR
-
against = stage2
-
DEP_FILE_DEPS = $(CFILES) $(HFILES) $(TARGET_CPU_CFILES) \
$(TARGET_CPU_HFILES) $(OBJ_FORMAT_CFILES) $(OBJ_FORMAT_HFILES)
-
+CONFIG_STATUS_DEPENDENCIES = $(BFDDIR)/configure.in
AMKDEP = #DO NOT PUT ANYTHING BETWEEN THIS LINE AND THE MATCHING WARNING BELOW.
DEPTC_a29k_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-a29k.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
@@ -692,7 +783,8 @@ DEPTC_alpha_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
subsegs.h $(INCDIR)/obstack.h struc-symbol.h ecoff.h \
$(INCDIR)/coff/sym.h $(INCDIR)/coff/ecoff.h $(INCDIR)/opcode/alpha.h \
$(INCDIR)/elf/alpha.h $(INCDIR)/elf/reloc-macros.h \
- dwarf2dbg.h $(INCDIR)/safe-ctype.h $(srcdir)/config/atof-vax.c
+ dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h $(INCDIR)/safe-ctype.h \
+ $(srcdir)/config/atof-vax.c
DEPTC_alpha_evax = $(INCDIR)/symcat.h $(srcdir)/config/obj-evax.h \
$(srcdir)/config/tc-alpha.h subsegs.h $(INCDIR)/obstack.h \
@@ -800,29 +892,28 @@ DEPTC_fr30_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
DEPTC_frv_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-frv.h $(INCDIR)/coff/internal.h \
- $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h dwarf2dbg.h \
- subsegs.h $(INCDIR)/obstack.h $(srcdir)/../opcodes/frv-desc.h \
- $(INCDIR)/opcode/cgen.h $(srcdir)/../opcodes/frv-opc.h \
- cgen.h $(BFDDIR)/libbfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/frv.h \
- $(INCDIR)/elf/reloc-macros.h
+ $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h subsegs.h $(INCDIR)/obstack.h \
+ $(srcdir)/../opcodes/frv-desc.h $(INCDIR)/opcode/cgen.h \
+ $(srcdir)/../opcodes/frv-opc.h cgen.h $(BFDDIR)/libbfd.h \
+ $(INCDIR)/elf/common.h $(INCDIR)/elf/frv.h $(INCDIR)/elf/reloc-macros.h
DEPTC_frv_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-frv.h \
- dwarf2dbg.h subsegs.h $(INCDIR)/obstack.h $(srcdir)/../opcodes/frv-desc.h \
+ subsegs.h $(INCDIR)/obstack.h $(srcdir)/../opcodes/frv-desc.h \
$(INCDIR)/opcode/cgen.h $(srcdir)/../opcodes/frv-opc.h \
cgen.h $(BFDDIR)/libbfd.h $(INCDIR)/elf/frv.h $(INCDIR)/elf/reloc-macros.h
DEPTC_h8300_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-h8300.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/h8300.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
- $(INCDIR)/bfdlink.h subsegs.h $(INCDIR)/obstack.h $(INCDIR)/opcode/h8300.h \
- $(INCDIR)/safe-ctype.h
+ $(INCDIR)/bfdlink.h subsegs.h $(INCDIR)/obstack.h dwarf2dbg.h \
+ $(INCDIR)/opcode/h8300.h $(INCDIR)/safe-ctype.h
DEPTC_h8300_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-h8300.h \
- subsegs.h $(INCDIR)/obstack.h $(INCDIR)/opcode/h8300.h \
+ subsegs.h $(INCDIR)/obstack.h dwarf2dbg.h $(INCDIR)/opcode/h8300.h \
$(INCDIR)/safe-ctype.h $(INCDIR)/elf/h8.h $(INCDIR)/elf/reloc-macros.h
DEPTC_h8500_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
@@ -871,24 +962,26 @@ DEPTC_i370_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-i370.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/opcode/i370.h $(INCDIR)/elf/i370.h
+ struc-symbol.h $(INCDIR)/opcode/i370.h $(INCDIR)/elf/i370.h \
+ $(INCDIR)/elf/reloc-macros.h
DEPTC_i386_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-i386.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- dwarf2dbg.h $(INCDIR)/opcode/i386.h
+ dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h $(INCDIR)/opcode/i386.h
DEPTC_i386_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-i386.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/i386.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
$(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h subsegs.h \
- $(INCDIR)/obstack.h dwarf2dbg.h $(INCDIR)/opcode/i386.h
+ $(INCDIR)/obstack.h dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h \
+ $(INCDIR)/opcode/i386.h
DEPTC_i386_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-i386.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- dwarf2dbg.h $(INCDIR)/opcode/i386.h
+ dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h $(INCDIR)/opcode/i386.h
DEPTC_i860_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
@@ -910,6 +1003,21 @@ DEPTC_i960_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-i960.h \
$(INCDIR)/safe-ctype.h $(INCDIR)/obstack.h $(INCDIR)/opcode/i960.h
+DEPTC_ip2k_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
+ $(srcdir)/config/tc-ip2k.h $(INCDIR)/coff/internal.h \
+ $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h subsegs.h $(INCDIR)/obstack.h \
+ $(srcdir)/../opcodes/ip2k-desc.h $(INCDIR)/opcode/cgen.h \
+ $(srcdir)/../opcodes/ip2k-opc.h cgen.h $(INCDIR)/elf/common.h \
+ $(INCDIR)/elf/ip2k.h $(INCDIR)/elf/reloc-macros.h $(BFDDIR)/libbfd.h
+
+DEPTC_ip2k_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-ip2k.h \
+ subsegs.h $(INCDIR)/obstack.h $(srcdir)/../opcodes/ip2k-desc.h \
+ $(INCDIR)/opcode/cgen.h $(srcdir)/../opcodes/ip2k-opc.h \
+ cgen.h $(INCDIR)/elf/ip2k.h $(INCDIR)/elf/reloc-macros.h \
+ $(BFDDIR)/libbfd.h
+
DEPTC_m32r_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-m32r.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h \
@@ -928,37 +1036,42 @@ DEPTC_m68hc11_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-m68hc11.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/m68k.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
$(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h subsegs.h \
- $(INCDIR)/obstack.h $(INCDIR)/opcode/m68hc11.h dwarf2dbg.h
+ $(INCDIR)/obstack.h $(INCDIR)/opcode/m68hc11.h dwarf2dbg.h \
+ $(INCDIR)/elf/m68hc11.h $(INCDIR)/elf/reloc-macros.h
DEPTC_m68hc11_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-m68hc11.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- $(INCDIR)/opcode/m68hc11.h dwarf2dbg.h
+ $(INCDIR)/opcode/m68hc11.h dwarf2dbg.h $(INCDIR)/elf/m68hc11.h \
+ $(INCDIR)/elf/reloc-macros.h
DEPTC_m68k_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-m68k.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/safe-ctype.h $(INCDIR)/obstack.h subsegs.h \
- dwarf2dbg.h $(INCDIR)/opcode/m68k.h $(srcdir)/config/m68k-parse.h
+ dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h $(INCDIR)/opcode/m68k.h \
+ $(srcdir)/config/m68k-parse.h
DEPTC_m68k_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-m68k.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/m68k.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
$(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h $(INCDIR)/obstack.h \
- subsegs.h dwarf2dbg.h $(INCDIR)/opcode/m68k.h $(srcdir)/config/m68k-parse.h
+ subsegs.h dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h \
+ $(INCDIR)/opcode/m68k.h $(srcdir)/config/m68k-parse.h
DEPTC_m68k_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-m68k.h \
$(INCDIR)/safe-ctype.h $(INCDIR)/obstack.h subsegs.h \
- dwarf2dbg.h $(INCDIR)/opcode/m68k.h $(srcdir)/config/m68k-parse.h \
- $(INCDIR)/elf/m68k.h $(INCDIR)/elf/reloc-macros.h
+ dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h $(INCDIR)/opcode/m68k.h \
+ $(srcdir)/config/m68k-parse.h $(INCDIR)/elf/m68k.h \
+ $(INCDIR)/elf/reloc-macros.h
DEPTC_m68k_hp300 = $(INCDIR)/symcat.h $(srcdir)/config/obj-hp300.h \
$(srcdir)/config/obj-aout.h $(srcdir)/config/tc-m68k.h \
$(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h \
- $(INCDIR)/obstack.h subsegs.h dwarf2dbg.h $(INCDIR)/opcode/m68k.h \
- $(srcdir)/config/m68k-parse.h
+ $(INCDIR)/obstack.h subsegs.h dwarf2dbg.h dw2gencfi.h \
+ $(INCDIR)/elf/dwarf2.h $(INCDIR)/opcode/m68k.h $(srcdir)/config/m68k-parse.h
DEPTC_m88k_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-m88k.h $(INCDIR)/coff/internal.h \
@@ -1047,6 +1160,17 @@ DEPTC_mn10300_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
$(INCDIR)/opcode/mn10300.h dwarf2dbg.h
+DEPTC_msp430_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
+ $(srcdir)/config/tc-msp430.h $(INCDIR)/coff/internal.h \
+ $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h subsegs.h $(INCDIR)/obstack.h \
+ $(INCDIR)/opcode/msp430.h $(INCDIR)/safe-ctype.h
+
+DEPTC_msp430_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-msp430.h \
+ subsegs.h $(INCDIR)/obstack.h $(INCDIR)/opcode/msp430.h \
+ $(INCDIR)/safe-ctype.h
+
DEPTC_ns32k_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-ns32k.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/opcode/ns32k.h $(INCDIR)/obstack.h
@@ -1114,65 +1238,68 @@ DEPTC_ppc_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-ppc.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/rs6000.h $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- $(INCDIR)/opcode/ppc.h
+ dw2gencfi.h $(INCDIR)/elf/dwarf2.h $(INCDIR)/opcode/ppc.h
DEPTC_ppc_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-ppc.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- $(INCDIR)/opcode/ppc.h $(INCDIR)/elf/ppc.h $(INCDIR)/elf/reloc-macros.h \
- dwarf2dbg.h
+ dw2gencfi.h $(INCDIR)/elf/dwarf2.h $(INCDIR)/opcode/ppc.h \
+ $(INCDIR)/elf/ppc.h $(INCDIR)/elf/reloc-macros.h dwarf2dbg.h
DEPTC_s390_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-s390.h $(INCDIR)/coff/internal.h \
$(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h \
- subsegs.h $(INCDIR)/obstack.h struc-symbol.h $(INCDIR)/opcode/s390.h \
+ subsegs.h $(INCDIR)/obstack.h struc-symbol.h dwarf2dbg.h \
+ dw2gencfi.h $(INCDIR)/elf/dwarf2.h $(INCDIR)/opcode/s390.h \
$(INCDIR)/elf/s390.h $(INCDIR)/elf/reloc-macros.h
DEPTC_s390_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-s390.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/opcode/s390.h $(INCDIR)/elf/s390.h \
- $(INCDIR)/elf/reloc-macros.h
+ struc-symbol.h dwarf2dbg.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h \
+ $(INCDIR)/opcode/s390.h $(INCDIR)/elf/s390.h $(INCDIR)/elf/reloc-macros.h
DEPTC_sh_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-sh.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/sh.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
$(INCDIR)/bfdlink.h subsegs.h $(INCDIR)/obstack.h $(srcdir)/../opcodes/sh-opc.h \
- $(INCDIR)/safe-ctype.h struc-symbol.h dwarf2dbg.h
+ $(INCDIR)/safe-ctype.h struc-symbol.h dwarf2dbg.h dw2gencfi.h
DEPTC_sh_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-sh.h \
subsegs.h $(INCDIR)/obstack.h $(srcdir)/../opcodes/sh-opc.h \
$(INCDIR)/safe-ctype.h struc-symbol.h $(INCDIR)/elf/sh.h \
- $(INCDIR)/elf/reloc-macros.h dwarf2dbg.h
+ $(INCDIR)/elf/reloc-macros.h dwarf2dbg.h dw2gencfi.h
DEPTC_sh64_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-sh64.h \
$(srcdir)/config/tc-sh.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
- $(INCDIR)/safe-ctype.h $(srcdir)/../opcodes/sh64-opc.h \
+ $(BFDDIR)/elf32-sh64.h $(INCDIR)/safe-ctype.h $(srcdir)/../opcodes/sh64-opc.h \
$(srcdir)/config/tc-sh.c subsegs.h $(INCDIR)/obstack.h \
- $(srcdir)/../opcodes/sh-opc.h struc-symbol.h dwarf2dbg.h
+ $(srcdir)/../opcodes/sh-opc.h struc-symbol.h dwarf2dbg.h dw2gencfi.h
DEPTC_sparc_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-sparc.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- $(INCDIR)/opcode/sparc.h
+ $(INCDIR)/opcode/sparc.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h
DEPTC_sparc_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-sparc.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/sparc.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
$(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h subsegs.h \
- $(INCDIR)/obstack.h $(INCDIR)/opcode/sparc.h
+ $(INCDIR)/obstack.h $(INCDIR)/opcode/sparc.h dw2gencfi.h \
+ $(INCDIR)/elf/dwarf2.h
DEPTC_sparc_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-sparc.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- $(INCDIR)/opcode/sparc.h $(INCDIR)/elf/sparc.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/opcode/sparc.h dw2gencfi.h $(INCDIR)/elf/dwarf2.h \
+ $(INCDIR)/elf/sparc.h $(INCDIR)/elf/reloc-macros.h \
dwarf2dbg.h
DEPTC_tahoe_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
@@ -1203,6 +1330,18 @@ DEPTC_tic30_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-tic30.h \
$(INCDIR)/safe-ctype.h $(INCDIR)/opcode/tic30.h
+DEPTC_tic4x_coff = $(INCDIR)/safe-ctype.h $(INCDIR)/symcat.h \
+ $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-tic4x.h \
+ $(INCDIR)/coff/internal.h $(INCDIR)/coff/tic4x.h $(INCDIR)/coff/ti.h \
+ $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/opcode/tic4x.h \
+ subsegs.h $(INCDIR)/obstack.h
+
+DEPTC_tic4x_elf = $(INCDIR)/safe-ctype.h $(INCDIR)/symcat.h \
+ $(srcdir)/config/obj-elf.h $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h \
+ $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h \
+ $(srcdir)/config/tc-tic4x.h $(INCDIR)/opcode/tic4x.h \
+ subsegs.h $(INCDIR)/obstack.h
+
DEPTC_tic54x_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-tic54x.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/tic54x.h $(INCDIR)/coff/ti.h $(BFDDIR)/libcoff.h \
@@ -1287,6 +1426,14 @@ DEPTC_xstormy16_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(INCDIR)/opcode/cgen.h $(srcdir)/../opcodes/xstormy16-opc.h \
cgen.h
+DEPTC_xtensa_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-xtensa.h \
+ $(INCDIR)/xtensa-config.h sb.h $(INCDIR)/safe-ctype.h \
+ subsegs.h $(INCDIR)/obstack.h $(srcdir)/config/xtensa-relax.h \
+ $(INCDIR)/xtensa-isa.h $(srcdir)/config/xtensa-istack.h \
+ dwarf2dbg.h struc-symbol.h
+
DEPTC_z8k_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-z8k.h $(INCDIR)/coff/internal.h \
$(INCDIR)/coff/z8k.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
@@ -1321,7 +1468,7 @@ DEPOBJ_a29k_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-a29k.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_alpha_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-alpha.h $(INCDIR)/coff/internal.h \
@@ -1337,8 +1484,8 @@ DEPOBJ_alpha_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-alpha.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h ecoff.h $(INCDIR)/coff/sym.h $(INCDIR)/coff/ecoff.h \
- $(INCDIR)/elf/alpha.h $(INCDIR)/elf/reloc-macros.h \
+ struc-symbol.h dwarf2dbg.h ecoff.h $(INCDIR)/coff/sym.h \
+ $(INCDIR)/coff/ecoff.h $(INCDIR)/elf/alpha.h $(INCDIR)/elf/reloc-macros.h \
$(INCDIR)/aout/aout64.h
DEPOBJ_alpha_evax = $(INCDIR)/symcat.h $(srcdir)/config/obj-evax.h \
@@ -1346,14 +1493,14 @@ DEPOBJ_alpha_evax = $(INCDIR)/symcat.h $(srcdir)/config/obj-evax.h \
DEPOBJ_arc_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-arc.h $(INCDIR)/coff/internal.h \
- $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h struc-symbol.h \
- $(INCDIR)/obstack.h subsegs.h
+ $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
+ subsegs.h
DEPOBJ_arc_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-arc.h \
- struc-symbol.h $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- $(INCDIR)/aout/aout64.h
+ $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_arm_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-arm.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
@@ -1368,7 +1515,7 @@ DEPOBJ_arm_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-arm.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_avr_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-avr.h $(INCDIR)/coff/internal.h \
@@ -1379,7 +1526,7 @@ DEPOBJ_avr_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-avr.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_cris_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-cris.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
@@ -1389,7 +1536,7 @@ DEPOBJ_cris_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-cris.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_d10v_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-d10v.h $(INCDIR)/coff/internal.h \
@@ -1400,7 +1547,7 @@ DEPOBJ_d10v_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-d10v.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_d30v_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-d30v.h $(INCDIR)/coff/internal.h \
@@ -1411,7 +1558,7 @@ DEPOBJ_d30v_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-d30v.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_dlx_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-dlx.h $(INCDIR)/coff/internal.h \
@@ -1422,7 +1569,7 @@ DEPOBJ_dlx_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-dlx.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_fr30_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-fr30.h $(INCDIR)/coff/internal.h \
@@ -1433,7 +1580,7 @@ DEPOBJ_fr30_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-fr30.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_frv_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-frv.h $(INCDIR)/coff/internal.h \
@@ -1444,7 +1591,7 @@ DEPOBJ_frv_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-frv.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_h8300_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-h8300.h $(INCDIR)/coff/internal.h \
@@ -1455,7 +1602,7 @@ DEPOBJ_h8300_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-h8300.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_h8500_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-h8500.h $(INCDIR)/coff/internal.h \
@@ -1466,7 +1613,7 @@ DEPOBJ_h8500_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-h8500.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_hppa_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-hppa.h $(INCDIR)/coff/internal.h \
@@ -1478,7 +1625,8 @@ DEPOBJ_hppa_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-hppa.h \
$(BFDDIR)/elf32-hppa.h $(BFDDIR)/libhppa.h $(INCDIR)/elf/hppa.h \
$(INCDIR)/elf/reloc-macros.h $(INCDIR)/safe-ctype.h \
- subsegs.h $(INCDIR)/obstack.h struc-symbol.h $(INCDIR)/aout/aout64.h
+ subsegs.h $(INCDIR)/obstack.h struc-symbol.h dwarf2dbg.h \
+ $(INCDIR)/aout/aout64.h
DEPOBJ_ia64_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-ia64.h $(INCDIR)/opcode/ia64.h \
@@ -1491,7 +1639,7 @@ DEPOBJ_ia64_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-ia64.h \
$(INCDIR)/opcode/ia64.h $(INCDIR)/elf/ia64.h $(INCDIR)/elf/reloc-macros.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_i370_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-i370.h $(INCDIR)/coff/internal.h \
@@ -1502,7 +1650,8 @@ DEPOBJ_i370_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-i370.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/elf/i370.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/elf/i370.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/aout/aout64.h
DEPOBJ_i386_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-i386.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
@@ -1517,13 +1666,13 @@ DEPOBJ_i386_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-i386.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_i860_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-i860.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_i960_bout = $(INCDIR)/symcat.h $(srcdir)/config/obj-bout.h \
$(srcdir)/config/tc-i960.h $(INCDIR)/obstack.h
@@ -1537,7 +1686,18 @@ DEPOBJ_i960_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-i960.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
+
+DEPOBJ_ip2k_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
+ $(srcdir)/config/tc-ip2k.h $(INCDIR)/coff/internal.h \
+ $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
+ subsegs.h
+
+DEPOBJ_ip2k_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-ip2k.h \
+ $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_m32r_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-m32r.h $(INCDIR)/coff/internal.h \
@@ -1548,7 +1708,7 @@ DEPOBJ_m32r_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-m32r.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_m68hc11_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-m68hc11.h $(INCDIR)/coff/internal.h \
@@ -1559,7 +1719,7 @@ DEPOBJ_m68hc11_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-m68hc11.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_m68k_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-m68k.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
@@ -1574,7 +1734,7 @@ DEPOBJ_m68k_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-m68k.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_m68k_hp300 = $(srcdir)/config/obj-aout.c $(INCDIR)/symcat.h \
$(srcdir)/config/obj-aout.h $(srcdir)/config/tc-m68k.h \
@@ -1590,7 +1750,7 @@ DEPOBJ_m88k_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-m88k.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_mcore_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-mcore.h $(INCDIR)/coff/internal.h \
@@ -1601,7 +1761,7 @@ DEPOBJ_mcore_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mcore.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_mips_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-mips.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
@@ -1621,14 +1781,15 @@ DEPOBJ_mips_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mips.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h ecoff.h $(INCDIR)/coff/sym.h $(INCDIR)/coff/ecoff.h \
- $(INCDIR)/elf/mips.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h ecoff.h $(INCDIR)/coff/sym.h \
+ $(INCDIR)/coff/ecoff.h $(INCDIR)/elf/mips.h $(INCDIR)/elf/reloc-macros.h \
+ $(INCDIR)/aout/aout64.h
DEPOBJ_mmix_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mmix.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_mn10200_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-mn10200.h $(INCDIR)/coff/internal.h \
@@ -1639,7 +1800,7 @@ DEPOBJ_mn10200_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mn10200.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_mn10300_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-mn10300.h $(INCDIR)/coff/internal.h \
@@ -1650,7 +1811,18 @@ DEPOBJ_mn10300_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mn10300.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
+
+DEPOBJ_msp430_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
+ $(srcdir)/config/tc-msp430.h $(INCDIR)/coff/internal.h \
+ $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h \
+ subsegs.h
+
+DEPOBJ_msp430_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-msp430.h \
+ $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_ns32k_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-ns32k.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
@@ -1665,7 +1837,7 @@ DEPOBJ_ns32k_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-ns32k.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_openrisc_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-openrisc.h $(INCDIR)/coff/internal.h \
@@ -1676,7 +1848,7 @@ DEPOBJ_openrisc_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-openrisc.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_or32_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-or32.h $(INCDIR)/coff/internal.h \
@@ -1687,7 +1859,7 @@ DEPOBJ_or32_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-or32.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_pdp11_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-pdp11.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
@@ -1702,7 +1874,7 @@ DEPOBJ_pdp11_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-pdp11.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_pj_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-pj.h $(INCDIR)/coff/internal.h \
@@ -1713,7 +1885,7 @@ DEPOBJ_pj_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-pj.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_ppc_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-ppc.h $(INCDIR)/coff/internal.h \
@@ -1724,7 +1896,7 @@ DEPOBJ_ppc_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-ppc.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/elf/ppc.h $(INCDIR)/elf/reloc-macros.h \
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/elf/ppc.h $(INCDIR)/elf/reloc-macros.h \
$(INCDIR)/aout/aout64.h
DEPOBJ_s390_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
@@ -1736,7 +1908,7 @@ DEPOBJ_s390_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-s390.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_sh_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-sh.h $(INCDIR)/coff/internal.h \
@@ -1747,20 +1919,14 @@ DEPOBJ_sh_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-sh.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
-
-DEPOBJ_sh64_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
- $(srcdir)/config/tc-sh64.h $(srcdir)/config/tc-sh.h \
- $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/coff/internal.h \
- $(INCDIR)/coff/sh.h $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h \
- $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h subsegs.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_sh64_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-sh64.h \
$(srcdir)/config/tc-sh.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
- $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ $(BFDDIR)/elf32-sh64.h $(INCDIR)/safe-ctype.h subsegs.h \
+ $(INCDIR)/obstack.h struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_sparc_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-sparc.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
@@ -1775,7 +1941,7 @@ DEPOBJ_sparc_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-sparc.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_tahoe_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-tahoe.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
@@ -1790,7 +1956,7 @@ DEPOBJ_tahoe_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-tahoe.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_tic30_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-tic30.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
@@ -1805,7 +1971,18 @@ DEPOBJ_tic30_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-tic30.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
+
+DEPOBJ_tic4x_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
+ $(srcdir)/config/tc-tic4x.h $(INCDIR)/coff/internal.h \
+ $(INCDIR)/coff/tic4x.h $(INCDIR)/coff/ti.h $(BFDDIR)/libcoff.h \
+ $(INCDIR)/bfdlink.h $(INCDIR)/obstack.h subsegs.h
+
+DEPOBJ_tic4x_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-tic4x.h \
+ $(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_tic54x_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-tic54x.h $(INCDIR)/coff/internal.h \
@@ -1816,7 +1993,7 @@ DEPOBJ_tic54x_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-tic54x.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_tic80_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-tic80.h $(INCDIR)/coff/internal.h \
@@ -1827,7 +2004,7 @@ DEPOBJ_tic80_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-tic80.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_vax_aout = $(INCDIR)/symcat.h $(srcdir)/config/obj-aout.h \
$(srcdir)/config/tc-vax.h $(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h \
@@ -1842,7 +2019,7 @@ DEPOBJ_vax_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-vax.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_vax_vms = $(INCDIR)/symcat.h $(srcdir)/config/obj-vms.h \
$(srcdir)/config/tc-vax.h $(INCDIR)/aout/stab_gnu.h \
@@ -1858,7 +2035,7 @@ DEPOBJ_w65_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-w65.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_v850_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-v850.h $(INCDIR)/elf/v850.h $(INCDIR)/elf/reloc-macros.h \
@@ -1869,7 +2046,8 @@ DEPOBJ_v850_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-v850.h \
$(INCDIR)/elf/v850.h $(INCDIR)/elf/reloc-macros.h $(INCDIR)/safe-ctype.h \
- subsegs.h $(INCDIR)/obstack.h struc-symbol.h $(INCDIR)/aout/aout64.h
+ subsegs.h $(INCDIR)/obstack.h struc-symbol.h dwarf2dbg.h \
+ $(INCDIR)/aout/aout64.h
DEPOBJ_xstormy16_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-xstormy16.h $(INCDIR)/coff/internal.h \
@@ -1880,7 +2058,13 @@ DEPOBJ_xstormy16_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-xstormy16.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
+
+DEPOBJ_xtensa_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-xtensa.h \
+ $(INCDIR)/xtensa-config.h $(INCDIR)/safe-ctype.h subsegs.h \
+ $(INCDIR)/obstack.h struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_z8k_coff = $(INCDIR)/symcat.h $(srcdir)/config/obj-coff.h \
$(srcdir)/config/tc-z8k.h $(INCDIR)/coff/internal.h \
@@ -1891,7 +2075,7 @@ DEPOBJ_z8k_elf = $(INCDIR)/symcat.h $(srcdir)/config/obj-elf.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-z8k.h \
$(INCDIR)/safe-ctype.h subsegs.h $(INCDIR)/obstack.h \
- struc-symbol.h $(INCDIR)/aout/aout64.h
+ struc-symbol.h dwarf2dbg.h $(INCDIR)/aout/aout64.h
DEPOBJ_hppa_som = $(srcdir)/config/obj-som.h subsegs.h \
$(INCDIR)/obstack.h $(BFDDIR)/libhppa.h $(BFDDIR)/som.h \
@@ -2069,6 +2253,14 @@ DEP_i960_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-i960.h
+DEP_ip2k_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-ip2k.h \
+ $(INCDIR)/symcat.h $(INCDIR)/coff/internal.h $(BFDDIR)/libcoff.h \
+ $(INCDIR)/bfdlink.h
+
+DEP_ip2k_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-ip2k.h
+
DEP_m32r_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-m32r.h \
$(INCDIR)/symcat.h $(INCDIR)/coff/internal.h $(BFDDIR)/libcoff.h \
$(INCDIR)/bfdlink.h
@@ -2149,6 +2341,14 @@ DEP_mn10300_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-mn10300.h
+DEP_msp430_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-msp430.h \
+ $(INCDIR)/symcat.h $(INCDIR)/coff/internal.h $(BFDDIR)/libcoff.h \
+ $(INCDIR)/bfdlink.h
+
+DEP_msp430_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-msp430.h
+
DEP_ns32k_aout = $(srcdir)/config/obj-aout.h $(srcdir)/config/tc-ns32k.h \
$(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h
@@ -2219,15 +2419,11 @@ DEP_sh_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-sh.h
-DEP_sh64_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-sh64.h \
- $(srcdir)/config/tc-sh.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
- $(INCDIR)/symcat.h $(INCDIR)/coff/internal.h $(INCDIR)/coff/sh.h \
- $(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h
-
DEP_sh64_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-sh64.h \
- $(srcdir)/config/tc-sh.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h
+ $(srcdir)/config/tc-sh.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
+ $(BFDDIR)/elf32-sh64.h
DEP_sparc_aout = $(srcdir)/config/obj-aout.h $(srcdir)/config/tc-sparc.h \
$(BFDDIR)/libaout.h $(INCDIR)/bfdlink.h
@@ -2262,6 +2458,14 @@ DEP_tic30_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-tic30.h
+DEP_tic4x_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-tic4x.h \
+ $(INCDIR)/symcat.h $(INCDIR)/coff/internal.h $(INCDIR)/coff/tic4x.h \
+ $(INCDIR)/coff/ti.h $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h
+
+DEP_tic4x_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-tic4x.h
+
DEP_tic54x_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-tic54x.h \
$(INCDIR)/symcat.h $(INCDIR)/coff/internal.h $(INCDIR)/coff/tic54x.h \
$(INCDIR)/coff/ti.h $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h
@@ -2317,6 +2521,11 @@ DEP_xstormy16_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
$(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-xstormy16.h
+DEP_xtensa_elf = $(srcdir)/config/obj-elf.h $(INCDIR)/symcat.h \
+ $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h \
+ $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(srcdir)/config/tc-xtensa.h \
+ $(INCDIR)/xtensa-config.h
+
DEP_z8k_coff = $(srcdir)/config/obj-coff.h $(srcdir)/config/tc-z8k.h \
$(INCDIR)/symcat.h $(INCDIR)/coff/internal.h $(INCDIR)/coff/z8k.h \
$(INCDIR)/coff/external.h $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h
@@ -2334,147 +2543,103 @@ DEP_mips_multi = $(DEP_mips_coff) $(DEP_mips_ecoff) \
DEP_cris_multi = $(DEP_cris_aout) $(DEP_cris_elf)
BMKDEP = #DO NOT PUT ANYTHING BETWEEN THIS LINE AND THE MATCHING WARNING ABOVE.
-ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
-mkinstalldirs = $(SHELL) $(top_srcdir)/../mkinstalldirs
-CONFIG_HEADER = config.h
-CONFIG_CLEAN_FILES = ${GDBINIT}
-noinst_PROGRAMS = as-new$(EXEEXT)
-PROGRAMS = $(noinst_PROGRAMS)
-
-
-DEFS = @DEFS@ -I. -I$(srcdir) -I.
-CPPFLAGS = @CPPFLAGS@
-LDFLAGS = @LDFLAGS@
-LIBS = @LIBS@
-gasp_new_OBJECTS = gasp.$(OBJEXT) macro.$(OBJEXT) sb.$(OBJEXT) \
-hash.$(OBJEXT)
-gasp_new_LDFLAGS =
-itbl_test_OBJECTS = itbl-parse.$(OBJEXT) itbl-lex.$(OBJEXT)
-itbl_test_DEPENDENCIES = itbl-tops.o itbl-test.o \
-../libiberty/libiberty.a
-itbl_test_LDFLAGS =
-as_new_OBJECTS = app.$(OBJEXT) as.$(OBJEXT) atof-generic.$(OBJEXT) \
-bignum-copy.$(OBJEXT) cond.$(OBJEXT) depend.$(OBJEXT) \
-dwarf2dbg.$(OBJEXT) ecoff.$(OBJEXT) ehopt.$(OBJEXT) expr.$(OBJEXT) \
-flonum-copy.$(OBJEXT) flonum-konst.$(OBJEXT) flonum-mult.$(OBJEXT) \
-frags.$(OBJEXT) hash.$(OBJEXT) input-file.$(OBJEXT) \
-input-scrub.$(OBJEXT) listing.$(OBJEXT) literal.$(OBJEXT) \
-macro.$(OBJEXT) messages.$(OBJEXT) output-file.$(OBJEXT) read.$(OBJEXT) \
-sb.$(OBJEXT) stabs.$(OBJEXT) subsegs.$(OBJEXT) symbols.$(OBJEXT) \
-write.$(OBJEXT)
-as_new_LDFLAGS =
-SCRIPTS = $(noinst_SCRIPTS)
-
-LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
-LEXLIB = @LEXLIB@
-YLWRAP = $(top_srcdir)/../ylwrap
-CFLAGS = @CFLAGS@
-COMPILE = $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-CCLD = $(CC)
-LINK = $(LIBTOOL) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(LDFLAGS) -o $@
-DIST_COMMON = README ./stamp-h.in COPYING ChangeLog Makefile.am \
-Makefile.in NEWS acinclude.m4 aclocal.m4 config.in config/m68k-parse.c \
-configure configure.in gdbinit.in itbl-lex.c itbl-parse.c
-
-
-DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
-
-TAR = tar
-GZIP_ENV = --best
-SOURCES = $(gasp_new_SOURCES) $(itbl_test_SOURCES) $(as_new_SOURCES) $(EXTRA_as_new_SOURCES)
-OBJECTS = $(gasp_new_OBJECTS) $(itbl_test_OBJECTS) $(as_new_OBJECTS)
+all: config.h
+ $(MAKE) $(AM_MAKEFLAGS) all-recursive
-all: all-redirect
.SUFFIXES:
-.SUFFIXES: .S .c .l .lo .o .obj .s .y
-$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4)
- cd $(top_srcdir) && $(AUTOMAKE) --cygnus Makefile
-
-Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
- cd $(top_builddir) \
- && CONFIG_FILES=$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ configure.in acinclude.m4
- cd $(srcdir) && $(ACLOCAL)
+.SUFFIXES: .c .l .lo .o .obj .y
+am--refresh:
+ @:
+$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ echo ' cd $(srcdir) && $(AUTOMAKE) --foreign '; \
+ cd $(srcdir) && $(AUTOMAKE) --foreign \
+ && exit 0; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \
+ cd $(top_srcdir) && \
+ $(AUTOMAKE) --foreign Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ echo ' $(SHELL) ./config.status'; \
+ $(SHELL) ./config.status;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \
+ esac;
-config.status: $(srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
$(SHELL) ./config.status --recheck
-$(srcdir)/configure: @MAINTAINER_MODE_TRUE@$(srcdir)/configure.in $(ACLOCAL_M4) $(CONFIGURE_DEPENDENCIES)
+
+$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
cd $(srcdir) && $(AUTOCONF)
+$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
+ cd $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS)
-config.h: stamp-h
+config.h: stamp-h1
@if test ! -f $@; then \
- rm -f stamp-h; \
- $(MAKE) stamp-h; \
+ rm -f stamp-h1; \
+ $(MAKE) stamp-h1; \
else :; fi
-stamp-h: $(srcdir)/config.in $(top_builddir)/config.status
- cd $(top_builddir) \
- && CONFIG_FILES= CONFIG_HEADERS=config.h:config.in \
- $(SHELL) ./config.status
- @echo timestamp > stamp-h 2> /dev/null
-$(srcdir)/config.in: @MAINTAINER_MODE_TRUE@$(srcdir)/stamp-h.in
- @if test ! -f $@; then \
- rm -f $(srcdir)/stamp-h.in; \
- $(MAKE) $(srcdir)/stamp-h.in; \
- else :; fi
-$(srcdir)/stamp-h.in: $(top_srcdir)/configure.in $(ACLOCAL_M4)
- cd $(top_srcdir) && $(AUTOHEADER)
- @echo timestamp > $(srcdir)/stamp-h.in 2> /dev/null
-mostlyclean-hdr:
-
-clean-hdr:
+stamp-h1: $(srcdir)/config.in $(top_builddir)/config.status
+ @rm -f stamp-h1
+ cd $(top_builddir) && $(SHELL) ./config.status config.h
+$(srcdir)/config.in: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
+ cd $(top_srcdir) && $(AUTOHEADER)
+ rm -f stamp-h1
+ touch $@
distclean-hdr:
- -rm -f config.h
-
-maintainer-clean-hdr:
-${GDBINIT}: $(top_builddir)/config.status gdbinit.in
- cd $(top_builddir) && CONFIG_FILES=$@:gdbinit.in CONFIG_HEADERS= $(SHELL) ./config.status
-
-mostlyclean-noinstPROGRAMS:
+ -rm -f config.h stamp-h1
+gdb.ini: $(top_builddir)/config.status $(srcdir)/gdbinit.in
+ cd $(top_builddir) && $(SHELL) ./config.status $@
+.gdbinit: $(top_builddir)/config.status $(srcdir)/gdbinit.in
+ cd $(top_builddir) && $(SHELL) ./config.status $@
+po/Makefile.in: $(top_builddir)/config.status $(top_srcdir)/po/Make-in
+ cd $(top_builddir) && $(SHELL) ./config.status $@
clean-noinstPROGRAMS:
- -test -z "$(noinst_PROGRAMS)" || rm -f $(noinst_PROGRAMS)
-
-distclean-noinstPROGRAMS:
-
-maintainer-clean-noinstPROGRAMS:
-
-.c.o:
- $(COMPILE) -c $<
-
-# FIXME: We should only use cygpath when building on Windows,
-# and only if it is available.
-.c.obj:
- $(COMPILE) -c `cygpath -w $<`
-
-.s.o:
- $(COMPILE) -c $<
-
-.S.o:
- $(COMPILE) -c $<
+ @list='$(noinst_PROGRAMS)'; for p in $$list; do \
+ f=`echo $$p|sed 's/$(EXEEXT)$$//'`; \
+ echo " rm -f $$p $$f"; \
+ rm -f $$p $$f ; \
+ done
+as-new$(EXEEXT): $(as_new_OBJECTS) $(as_new_DEPENDENCIES)
+ @rm -f as-new$(EXEEXT)
+ $(LINK) $(as_new_LDFLAGS) $(as_new_OBJECTS) $(as_new_LDADD) $(LIBS)
+itbl-test$(EXEEXT): $(itbl_test_OBJECTS) $(itbl_test_DEPENDENCIES)
+ @rm -f itbl-test$(EXEEXT)
+ $(LINK) $(itbl_test_LDFLAGS) $(itbl_test_OBJECTS) $(itbl_test_LDADD) $(LIBS)
mostlyclean-compile:
- -rm -f *.o core *.core
-rm -f *.$(OBJEXT)
-clean-compile:
-
distclean-compile:
-rm -f *.tab.c
-maintainer-clean-compile:
+.c.o:
+ $(COMPILE) -c $<
+
+.c.obj:
+ $(COMPILE) -c `$(CYGPATH_W) '$<'`
.c.lo:
- $(LIBTOOL) --mode=compile $(COMPILE) -c $<
+ $(LTCOMPILE) -c -o $@ $<
-.s.lo:
- $(LIBTOOL) --mode=compile $(COMPILE) -c $<
+.l.c:
+ $(LEXCOMPILE) $<
+ sed '/^#/ s|$(LEX_OUTPUT_ROOT)\.c|$@|' $(LEX_OUTPUT_ROOT).c >$@
+ rm -f $(LEX_OUTPUT_ROOT).c
-.S.lo:
- $(LIBTOOL) --mode=compile $(COMPILE) -c $<
+.y.c:
+ $(SHELL) $(YLWRAP) $< y.tab.c $@ y.tab.h $*.h y.output $*.output -- $(YACCCOMPILE)
mostlyclean-libtool:
-rm -f *.lo
@@ -2483,27 +2648,8 @@ clean-libtool:
-rm -rf .libs _libs
distclean-libtool:
-
-maintainer-clean-libtool:
-
-gasp-new$(EXEEXT): $(gasp_new_OBJECTS) $(gasp_new_DEPENDENCIES)
- @rm -f gasp-new$(EXEEXT)
- $(LINK) $(gasp_new_LDFLAGS) $(gasp_new_OBJECTS) $(gasp_new_LDADD) $(LIBS)
-
-itbl-test$(EXEEXT): $(itbl_test_OBJECTS) $(itbl_test_DEPENDENCIES)
- @rm -f itbl-test$(EXEEXT)
- $(LINK) $(itbl_test_LDFLAGS) $(itbl_test_OBJECTS) $(itbl_test_LDADD) $(LIBS)
-
-as-new$(EXEEXT): $(as_new_OBJECTS) $(as_new_DEPENDENCIES)
- @rm -f as-new$(EXEEXT)
- $(LINK) $(as_new_LDFLAGS) $(as_new_OBJECTS) $(as_new_LDADD) $(LIBS)
-.l.c:
- $(LEX) $(AM_LFLAGS) $(LFLAGS) $< && mv $(LEX_OUTPUT_ROOT).c $@
-.y.c:
- $(SHELL) $(YLWRAP) "$(YACC)" $< y.tab.c $*.c y.tab.h $*.h -- $(AM_YFLAGS) $(YFLAGS)
-config/m68k-parse.h: config/m68k-parse.c
-itbl-parse.h: itbl-parse.c
-
+ -rm -f libtool
+uninstall-info-am:
# This directory's subdirectories are mostly independent; you can cd
# into them and run `make' without going through this Makefile.
@@ -2511,13 +2657,8 @@ itbl-parse.h: itbl-parse.c
# (1) if the variable is set in `config.status', edit `config.status'
# (which will cause the Makefiles to be regenerated when you run `make');
# (2) otherwise, pass the desired values on the `make' command line.
-
-@SET_MAKE@
-
-all-recursive install-data-recursive install-exec-recursive \
-installdirs-recursive install-recursive uninstall-recursive install-info-recursive \
-check-recursive installcheck-recursive info-recursive dvi-recursive:
- @set fnord $(MAKEFLAGS); amf=$$2; \
+$(RECURSIVE_TARGETS):
+ @set fnord $$MAKEFLAGS; amf=$$2; \
dot_seen=no; \
target=`echo $@ | sed s/-recursive//`; \
list='$(SUBDIRS)'; for subdir in $$list; do \
@@ -2537,13 +2678,18 @@ check-recursive installcheck-recursive info-recursive dvi-recursive:
mostlyclean-recursive clean-recursive distclean-recursive \
maintainer-clean-recursive:
- @set fnord $(MAKEFLAGS); amf=$$2; \
+ @set fnord $$MAKEFLAGS; amf=$$2; \
dot_seen=no; \
- rev=''; list='$(SUBDIRS)'; for subdir in $$list; do \
- rev="$$subdir $$rev"; \
- test "$$subdir" != "." || dot_seen=yes; \
+ case "$@" in \
+ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
+ *) list='$(SUBDIRS)' ;; \
+ esac; \
+ rev=''; for subdir in $$list; do \
+ if test "$$subdir" = "."; then :; else \
+ rev="$$subdir $$rev"; \
+ fi; \
done; \
- test "$$dot_seen" = "no" && rev=". $$rev"; \
+ rev="$$rev ."; \
target=`echo $@ | sed s/-recursive//`; \
for subdir in $$rev; do \
echo "Making $$target in $$subdir"; \
@@ -2559,155 +2705,116 @@ tags-recursive:
list='$(SUBDIRS)'; for subdir in $$list; do \
test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
done
+ctags-recursive:
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ test "$$subdir" = . || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
+ done
-tags: TAGS
-
-ID: $(HEADERS) $(SOURCES) $(LISP)
- list='$(SOURCES) $(HEADERS)'; \
- unique=`for i in $$list; do echo $$i; done | \
- awk ' { files[$$0] = 1; } \
+ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) ' { files[$$0] = 1; } \
END { for (i in files) print i; }'`; \
- here=`pwd` && cd $(srcdir) \
- && mkid -f$$here/ID $$unique $(LISP)
+ mkid -fID $$unique
+tags: TAGS
-TAGS: tags-recursive $(HEADERS) $(SOURCES) config.in $(TAGS_DEPENDENCIES) $(LISP)
+TAGS: tags-recursive $(HEADERS) $(SOURCES) config.in $(TAGS_DEPENDENCIES) \
+ $(TAGS_FILES) $(LISP)
tags=; \
here=`pwd`; \
+ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
+ include_option=--etags-include; \
+ empty_fix=.; \
+ else \
+ include_option=--include; \
+ empty_fix=; \
+ fi; \
list='$(SUBDIRS)'; for subdir in $$list; do \
- if test "$$subdir" = .; then :; else \
- test -f $$subdir/TAGS && tags="$$tags -i $$here/$$subdir/TAGS"; \
- fi; \
+ if test "$$subdir" = .; then :; else \
+ test -f $$subdir/TAGS && \
+ tags="$$tags $$include_option=$$here/$$subdir/TAGS"; \
+ fi; \
done; \
- list='$(SOURCES) $(HEADERS)'; \
- unique=`for i in $$list; do echo $$i; done | \
- awk ' { files[$$0] = 1; } \
+ list='$(SOURCES) $(HEADERS) config.in $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) ' { files[$$0] = 1; } \
END { for (i in files) print i; }'`; \
- test -z "$(ETAGS_ARGS)config.in$$unique$(LISP)$$tags" \
- || (cd $(srcdir) && etags $(ETAGS_ARGS) $$tags config.in $$unique $(LISP) -o $$here/TAGS)
-
-mostlyclean-tags:
+ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
+ test -z "$$unique" && unique=$$empty_fix; \
+ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+ $$tags $$unique; \
+ fi
+ctags: CTAGS
+CTAGS: ctags-recursive $(HEADERS) $(SOURCES) config.in $(TAGS_DEPENDENCIES) \
+ $(TAGS_FILES) $(LISP)
+ tags=; \
+ here=`pwd`; \
+ list='$(SOURCES) $(HEADERS) config.in $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) ' { files[$$0] = 1; } \
+ END { for (i in files) print i; }'`; \
+ test -z "$(CTAGS_ARGS)$$tags$$unique" \
+ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
+ $$tags $$unique
-clean-tags:
+GTAGS:
+ here=`$(am__cd) $(top_builddir) && pwd` \
+ && cd $(top_srcdir) \
+ && gtags -i $(GTAGS_ARGS) $$here
distclean-tags:
- -rm -f TAGS ID
-
-maintainer-clean-tags:
-
-distdir = $(PACKAGE)-$(VERSION)
-top_distdir = $(distdir)
-
-# This target untars the dist file and tries a VPATH configuration. Then
-# it guarantees that the distribution is self-contained by making another
-# tarfile.
-distcheck: dist
- -rm -rf $(distdir)
- GZIP=$(GZIP_ENV) $(TAR) zxf $(distdir).tar.gz
- mkdir $(distdir)/=build
- mkdir $(distdir)/=inst
- dc_install_base=`cd $(distdir)/=inst && pwd`; \
- cd $(distdir)/=build \
- && ../configure --srcdir=.. --prefix=$$dc_install_base \
- && $(MAKE) $(AM_MAKEFLAGS) \
- && $(MAKE) $(AM_MAKEFLAGS) dvi \
- && $(MAKE) $(AM_MAKEFLAGS) check \
- && $(MAKE) $(AM_MAKEFLAGS) install \
- && $(MAKE) $(AM_MAKEFLAGS) installcheck \
- && $(MAKE) $(AM_MAKEFLAGS) dist
- -rm -rf $(distdir)
- @banner="$(distdir).tar.gz is ready for distribution"; \
- dashes=`echo "$$banner" | sed s/./=/g`; \
- echo "$$dashes"; \
- echo "$$banner"; \
- echo "$$dashes"
-dist: distdir
- -chmod -R a+r $(distdir)
- GZIP=$(GZIP_ENV) $(TAR) chozf $(distdir).tar.gz $(distdir)
- -rm -rf $(distdir)
-dist-all: distdir
- -chmod -R a+r $(distdir)
- GZIP=$(GZIP_ENV) $(TAR) chozf $(distdir).tar.gz $(distdir)
- -rm -rf $(distdir)
-distdir: $(DISTFILES)
- -rm -rf $(distdir)
- mkdir $(distdir)
- -chmod 777 $(distdir)
- @for file in $(DISTFILES); do \
- if test -f $$file; then d=.; else d=$(srcdir); fi; \
- if test -d $$d/$$file; then \
- cp -pr $$d/$$file $(distdir)/$$file; \
- else \
- test -f $(distdir)/$$file \
- || ln $$d/$$file $(distdir)/$$file 2> /dev/null \
- || cp -p $$d/$$file $(distdir)/$$file || :; \
- fi; \
- done
- for subdir in $(SUBDIRS); do \
- if test "$$subdir" = .; then :; else \
- test -d $(distdir)/$$subdir \
- || mkdir $(distdir)/$$subdir \
- || exit 1; \
- chmod 777 $(distdir)/$$subdir; \
- (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir=../$(distdir) distdir=../$(distdir)/$$subdir distdir) \
- || exit 1; \
- fi; \
- done
-
-DEJATOOL = $(PACKAGE)
-
-RUNTESTDEFAULTFLAGS = --tool $(DEJATOOL) --srcdir $$srcdir
+ -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
site.exp: Makefile
@echo 'Making a new site.exp file...'
- @test ! -f site.bak || rm -f site.bak
- @echo '## these variables are automatically generated by make ##' > $@-t
- @echo '# Do not edit here. If you wish to override these values' >> $@-t
- @echo '# edit the last section' >> $@-t
- @echo 'set tool $(DEJATOOL)' >> $@-t
- @echo 'set srcdir $(srcdir)' >> $@-t
- @echo 'set objdir' `pwd` >> $@-t
- @echo 'set host_alias $(host_alias)' >> $@-t
- @echo 'set host_triplet $(host_triplet)' >> $@-t
- @echo 'set target_alias $(target_alias)' >> $@-t
- @echo 'set target_triplet $(target_triplet)' >> $@-t
- @echo 'set build_alias $(build_alias)' >> $@-t
- @echo 'set build_triplet $(build_triplet)' >> $@-t
- @echo '## All variables above are generated by configure. Do Not Edit ##' >> $@-t
- @test ! -f site.exp || sed '1,/^## All variables above are.*##/ d' site.exp >> $@-t
+ @echo '## these variables are automatically generated by make ##' >site.tmp
+ @echo '# Do not edit here. If you wish to override these values' >>site.tmp
+ @echo '# edit the last section' >>site.tmp
+ @echo 'set srcdir $(srcdir)' >>site.tmp
+ @echo "set objdir `pwd`" >>site.tmp
+ @echo 'set build_alias "$(build_alias)"' >>site.tmp
+ @echo 'set build_triplet $(build_triplet)' >>site.tmp
+ @echo 'set host_alias "$(host_alias)"' >>site.tmp
+ @echo 'set host_triplet $(host_triplet)' >>site.tmp
+ @echo 'set target_alias "$(target_alias)"' >>site.tmp
+ @echo 'set target_triplet $(target_triplet)' >>site.tmp
+ @echo '## All variables above are generated by configure. Do Not Edit ##' >>site.tmp
+ @test ! -f site.exp || \
+ sed '1,/^## All variables above are.*##/ d' site.exp >> site.tmp
+ @-rm -f site.bak
@test ! -f site.exp || mv site.exp site.bak
- @mv $@-t site.exp
-info-am:
-info: info-recursive
-dvi-am:
-dvi: dvi-recursive
+ @mv site.tmp site.exp
+
+distclean-DEJAGNU:
+ -rm -f site.exp site.bak
+ -l='$(DEJATOOL)'; for tool in $$l; do \
+ rm -f $$tool.sum $$tool.log; \
+ done
check-am:
$(MAKE) $(AM_MAKEFLAGS) check-DEJAGNU
check: check-recursive
-installcheck-am:
-installcheck: installcheck-recursive
-install-info-am:
-install-info: install-info-recursive
-all-recursive-am: config.h
- $(MAKE) $(AM_MAKEFLAGS) all-recursive
-
-install-exec-am: install-exec-local
+all-am: Makefile $(PROGRAMS) $(SCRIPTS) config.h
+installdirs: installdirs-recursive
+installdirs-am:
+install: install-recursive
install-exec: install-exec-recursive
-
-install-data-am:
install-data: install-data-recursive
+uninstall: uninstall-recursive
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
-install: install-recursive
-uninstall-am:
-uninstall: uninstall-recursive
-all-am: Makefile $(PROGRAMS) $(SCRIPTS) config.h
-all-redirect: all-recursive-am
-install-strip:
- $(MAKE) $(AM_MAKEFLAGS) AM_INSTALL_PROGRAM_FLAGS=-s install
-installdirs: installdirs-recursive
-installdirs-am:
-
+installcheck: installcheck-recursive
+install-strip:
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ `test -z '$(STRIP)' || \
+ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
mostlyclean-generic:
-test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES)
@@ -2715,63 +2822,87 @@ clean-generic:
-test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
distclean-generic:
- -rm -f Makefile $(CONFIG_CLEAN_FILES)
- -rm -f config.cache config.log stamp-h stamp-h[0-9]*
+ -rm -f $(CONFIG_CLEAN_FILES)
-test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES)
maintainer-clean-generic:
- -test -z "itbl-lexlconfig/m68k-parsehconfig/m68k-parsecitbl-parsehitbl-parsec" || rm -f itbl-lexl config/m68k-parseh config/m68k-parsec itbl-parseh itbl-parsec
-mostlyclean-am: mostlyclean-hdr mostlyclean-noinstPROGRAMS \
- mostlyclean-compile mostlyclean-libtool \
- mostlyclean-tags mostlyclean-generic
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+ -rm -f m68k-parse.c
+ -rm -f itbl-lex.c
+ -rm -f itbl-parse.c
+clean: clean-recursive
-mostlyclean: mostlyclean-recursive
+clean-am: clean-generic clean-libtool clean-noinstPROGRAMS \
+ mostlyclean-am
-clean-am: clean-hdr clean-noinstPROGRAMS clean-compile clean-libtool \
- clean-tags clean-generic mostlyclean-am
+distclean: distclean-recursive
+ -rm -f $(am__CONFIG_DISTCLEAN_FILES)
+ -rm -f Makefile
+distclean-am: clean-am distclean-DEJAGNU distclean-compile \
+ distclean-generic distclean-hdr distclean-libtool \
+ distclean-tags
-clean: clean-recursive
+dvi: dvi-recursive
-distclean-am: distclean-hdr distclean-noinstPROGRAMS distclean-compile \
- distclean-libtool distclean-tags distclean-generic \
- clean-am
- -rm -f libtool
+dvi-am:
-distclean: distclean-recursive
- -rm -f config.status
-
-maintainer-clean-am: maintainer-clean-hdr \
- maintainer-clean-noinstPROGRAMS \
- maintainer-clean-compile maintainer-clean-libtool \
- maintainer-clean-tags maintainer-clean-generic \
- distclean-am
- @echo "This command is intended for maintainers to use;"
- @echo "it deletes files that may require special tools to rebuild."
+html: html-recursive
+
+info: info-recursive
+
+info-am:
+
+install-data-am:
+
+install-exec-am: install-exec-local
+
+install-info: install-info-recursive
+
+install-man:
+
+installcheck-am:
maintainer-clean: maintainer-clean-recursive
- -rm -f config.status
-
-.PHONY: mostlyclean-hdr distclean-hdr clean-hdr maintainer-clean-hdr \
-mostlyclean-noinstPROGRAMS distclean-noinstPROGRAMS \
-clean-noinstPROGRAMS maintainer-clean-noinstPROGRAMS \
-mostlyclean-compile distclean-compile clean-compile \
-maintainer-clean-compile mostlyclean-libtool distclean-libtool \
-clean-libtool maintainer-clean-libtool install-data-recursive \
-uninstall-data-recursive install-exec-recursive \
-uninstall-exec-recursive installdirs-recursive uninstalldirs-recursive \
-all-recursive check-recursive installcheck-recursive info-recursive \
-dvi-recursive mostlyclean-recursive distclean-recursive clean-recursive \
-maintainer-clean-recursive tags tags-recursive mostlyclean-tags \
-distclean-tags clean-tags maintainer-clean-tags distdir check-DEJAGNU \
-info-am info dvi-am dvi check check-am installcheck-am installcheck \
-install-info-am install-info all-recursive-am install-exec-local \
-install-exec-am install-exec install-data-am install-data install-am \
-install uninstall-am uninstall all-redirect all-am all installdirs-am \
-installdirs mostlyclean-generic distclean-generic clean-generic \
-maintainer-clean-generic clean mostlyclean distclean maintainer-clean
+ -rm -f $(am__CONFIG_DISTCLEAN_FILES)
+ -rm -rf $(top_srcdir)/autom4te.cache
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-recursive
+
+mostlyclean-am: mostlyclean-compile mostlyclean-generic \
+ mostlyclean-libtool
+
+pdf: pdf-recursive
+
+pdf-am:
+
+ps: ps-recursive
+
+ps-am:
+
+uninstall-am:
+
+uninstall-info: uninstall-info-recursive
+
+.PHONY: $(RECURSIVE_TARGETS) CTAGS GTAGS all all-am am--refresh check \
+ check-DEJAGNU check-am clean clean-generic clean-libtool \
+ clean-noinstPROGRAMS clean-recursive ctags ctags-recursive \
+ distclean distclean-DEJAGNU distclean-compile \
+ distclean-generic distclean-hdr distclean-libtool \
+ distclean-recursive distclean-tags dvi dvi-am html html-am \
+ info info-am install install-am install-data install-data-am \
+ install-exec install-exec-am install-exec-local install-info \
+ install-info-am install-man install-strip installcheck \
+ installcheck-am installdirs installdirs-am maintainer-clean \
+ maintainer-clean-generic maintainer-clean-recursive \
+ mostlyclean mostlyclean-compile mostlyclean-generic \
+ mostlyclean-libtool mostlyclean-recursive pdf pdf-am ps ps-am \
+ tags tags-recursive uninstall uninstall-am uninstall-info-am
po/POTFILES.in: @MAINT@ Makefile
- for file in $(POTFILES); do echo $$file; done | sort > tmp \
+ for f in $(POTFILES); do echo $$f; done | LC_COLLATE= sort > tmp \
&& mv tmp $(srcdir)/po/POTFILES.in
$(srcdir)/make-gas.com: stamp-mk.com
@@ -2868,6 +2999,9 @@ e-crisaout.o: $(srcdir)/config/e-crisaout.c
e-criself.o: $(srcdir)/config/e-criself.c
$(COMPILE) -c $(srcdir)/config/e-criself.c
+xtensa-relax.o: $(srcdir)/config/xtensa-relax.c
+ $(COMPILE) -c $(srcdir)/config/xtensa-relax.c
+
# If m68k-parse.y is in a different directory, then ylwrap will use an
# absolute path when it invokes yacc, which will cause yacc to put the
# absolute path into the generated file. That's a pain when it comes
@@ -3019,8 +3153,6 @@ de-stage3:
- (cd stage3 ; rm -f as$(EXEEXT) ; mv -f * ..)
- rmdir stage3
-Makefile: $(BFDDIR)/configure.in
-
# Automatic dependency computation. This is a real pain, because the
# dependencies change based on target_cpu_type and obj_format.
# Just to make things even more complicated, automake separates the
@@ -3202,13 +3334,17 @@ dep-am: DEP
#MKDEP DO NOT PUT ANYTHING BETWEEN THIS LINE AND THE MATCHING WARNING BELOW.
app.o: app.c $(INCDIR)/symcat.h
as.o: as.c $(INCDIR)/symcat.h subsegs.h $(INCDIR)/obstack.h \
- output-file.h sb.h macro.h dwarf2dbg.h
+ output-file.h sb.h macro.h dwarf2dbg.h dw2gencfi.h \
+ $(INCDIR)/elf/dwarf2.h $(BFDVER_H)
atof-generic.o: atof-generic.c $(INCDIR)/symcat.h $(INCDIR)/safe-ctype.h
bignum-copy.o: bignum-copy.c $(INCDIR)/symcat.h
cond.o: cond.c $(INCDIR)/symcat.h macro.h sb.h $(INCDIR)/obstack.h
depend.o: depend.c $(INCDIR)/symcat.h
dwarf2dbg.o: dwarf2dbg.c $(INCDIR)/symcat.h dwarf2dbg.h \
- subsegs.h $(INCDIR)/obstack.h $(INCDIR)/elf/dwarf2.h
+ $(INCDIR)/filenames.h subsegs.h $(INCDIR)/obstack.h \
+ $(INCDIR)/elf/dwarf2.h
+dw2gencfi.o: dw2gencfi.c $(INCDIR)/symcat.h dw2gencfi.h \
+ $(INCDIR)/elf/dwarf2.h
ecoff.o: ecoff.c $(INCDIR)/symcat.h ecoff.h
ehopt.o: ehopt.c $(INCDIR)/symcat.h subsegs.h $(INCDIR)/obstack.h \
$(INCDIR)/elf/dwarf2.h
@@ -3231,7 +3367,8 @@ macro.o: macro.c $(INCDIR)/safe-ctype.h sb.h macro.h
messages.o: messages.c $(INCDIR)/symcat.h
output-file.o: output-file.c $(INCDIR)/symcat.h output-file.h
read.o: read.c $(INCDIR)/symcat.h $(INCDIR)/safe-ctype.h \
- subsegs.h $(INCDIR)/obstack.h sb.h macro.h ecoff.h
+ subsegs.h $(INCDIR)/obstack.h sb.h macro.h ecoff.h \
+ dw2gencfi.h $(INCDIR)/elf/dwarf2.h
sb.o: sb.c sb.h
stabs.o: stabs.c $(INCDIR)/symcat.h $(INCDIR)/obstack.h \
subsegs.h ecoff.h $(INCDIR)/aout/stab_gnu.h $(INCDIR)/aout/stab.def
@@ -3240,8 +3377,6 @@ symbols.o: symbols.c $(INCDIR)/symcat.h $(INCDIR)/safe-ctype.h \
$(INCDIR)/obstack.h subsegs.h struc-symbol.h
write.o: write.c $(INCDIR)/symcat.h subsegs.h $(INCDIR)/obstack.h \
output-file.h dwarf2dbg.h
-gasp.o: gasp.c $(INCDIR)/getopt.h $(INCDIR)/safe-ctype.h \
- sb.h macro.h $(INCDIR)/xregex.h $(INCDIR)/xregex2.h
itbl-ops.o: itbl-ops.c itbl-ops.h $(INCDIR)/symcat.h
e-crisaout.o: $(srcdir)/config/e-crisaout.c $(INCDIR)/symcat.h \
emul-target.h
@@ -3261,7 +3396,6 @@ $(OBJS): $(DEP_@target_cpu_type@_@obj_format@)
$(TARG_CPU_O): $(DEPTC_@target_cpu_type@_@obj_format@)
$(OBJ_FORMAT_O): $(DEPOBJ_@target_cpu_type@_@obj_format@)
#MKDEP DO NOT PUT ANYTHING BETWEEN THIS LINE AND THE MATCHING WARNING ABOVE.
-
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:
diff --git a/contrib/binutils/gas/NEWS b/contrib/binutils/gas/NEWS
index 18482a9..1a31e79 100644
--- a/contrib/binutils/gas/NEWS
+++ b/contrib/binutils/gas/NEWS
@@ -1,370 +1,420 @@
-*- text -*-
+* The MIPS -membedded-pic option (Embedded-PIC code generation) is
+ deprecated and will be removed in a future release.
+
+* Added PIC m32r Linux (ELF) and support to M32R assembler.
+
+* Added support for ARM V6.
+
+* Added support for sh4a and variants.
+
+* Support for Renesas M32R2 added.
+
+* Limited support for Mapping Symbols as specified in the ARM ELF
+ specification has been added to the arm assembler.
+
+* On ARM architectures, added a new gas directive ".unreq" that undoes
+ definitions created by ".req".
+
+* Support for Motorola ColdFire MCF528x added.
+
+* Added --gstabs+ switch to enable the generation of STABS debug format
+ information with GNU extensions.
+
+* Added support for MIPS64 Release 2.
+
+* Added support for v850e1.
+
+* Added -n switch for x86 assembler. By default, x86 GAS replaces
+ multiple nop instructions used for alignment within code sections
+ with multi-byte nop instructions such as leal 0(%esi,1),%esi. This
+ switch disables the optimization.
+
+* Removed -n option from MIPS assembler. It was not useful, and confused the
+ existing -non_shared option.
+
+Changes in 2.14:
+
+* Added support for MIPS32 Release 2.
+
+* Added support for Xtensa architecture.
+
+* Support for Intel's iWMMXt processor (an ARM variant) added.
+
+* An assembler test generator has been contributed and an example file that
+ uses it (gas/testsuite/gas/all/test-gen.c and test-exmaple.c).
+
+* Support for SH2E added.
+
+* GASP has now been removed.
+
+* Support for Texas Instruments TMS320C4x and TMS320C3x series of
+ DSP's contributed by Michael Hayes and Svein E. Seldal.
+
+* Support for the Ubicom IP2xxx microcontroller added.
+
Changes in 2.13:
-Support for the Fujitsu FRV architecture added by Red Hat. Models for FR400 and
-FR500 included.
+* Support for the Fujitsu FRV architecture added by Red Hat. Models for FR400
+ and FR500 included.
-Support for DLX processor added.
+* Support for DLX processor added.
-GASP has now been deprecated and will be removed in a future release. Use the
-macro facilities in GAS instead.
+* GASP has now been deprecated and will be removed in a future release. Use
+ the macro facilities in GAS instead.
-GASP now correctly parses floating point numbers. Unless the base is explicitly
-specified, they are interpreted as decimal numbers regardless of the currently
-specified base.
+* GASP now correctly parses floating point numbers. Unless the base is
+ explicitly specified, they are interpreted as decimal numbers regardless of
+ the currently specified base.
Changes in 2.12:
-Support for Don Knuth's MMIX, by Hans-Peter Nilsson.
+* Support for Don Knuth's MMIX, by Hans-Peter Nilsson.
-Support for the OpenRISC 32-bit embedded processor by OpenCores.
+* Support for the OpenRISC 32-bit embedded processor by OpenCores.
-The ARM assembler now accepts -march=..., -mcpu=... and -mfpu=... for
-specifying the target instruction set. The old method of specifying the
-target processor has been deprecated, but is still accepted for
-compatibility.
+* The ARM assembler now accepts -march=..., -mcpu=... and -mfpu=... for
+ specifying the target instruction set. The old method of specifying the
+ target processor has been deprecated, but is still accepted for
+ compatibility.
-Support for the VFP floating-point instruction set has been added to
-the ARM assembler.
+* Support for the VFP floating-point instruction set has been added to
+ the ARM assembler.
-New psuedo op: .incbin to include a set of binary data at a given point
-in the assembly. Contributed by Anders Norlander.
+* New psuedo op: .incbin to include a set of binary data at a given point
+ in the assembly. Contributed by Anders Norlander.
-The MIPS assembler now accepts -march/-mtune. -mcpu has been deprecated
-but still works for compatability.
+* The MIPS assembler now accepts -march/-mtune. -mcpu has been deprecated
+ but still works for compatability.
-The MIPS assembler no longer issues a warning by default when it
-generates a nop instruction from a macro. The new command line option
--n will turn on the warning.
+* The MIPS assembler no longer issues a warning by default when it
+ generates a nop instruction from a macro. The new command line option
+ -n will turn on the warning.
Changes in 2.11:
-x86 gas now supports the full Pentium4 instruction set.
+* Support for PDP-11 and 2.11BSD a.out format, by Lars Brinkhoff.
-Support for AMD x86-64 architecture, by Jan Hubicka, SuSE Labs.
+* x86 gas now supports the full Pentium4 instruction set.
-Support for Motorola 68HC11 and 68HC12.
+* Support for AMD x86-64 architecture, by Jan Hubicka, SuSE Labs.
-Support for Texas Instruments TMS320C54x (tic54x).
+* Support for Motorola 68HC11 and 68HC12.
-Support for IA-64.
+* Support for Texas Instruments TMS320C54x (tic54x).
-Support for i860, by Jason Eckhardt.
+* Support for IA-64.
-Support for CRIS (Axis Communications ETRAX series).
+* Support for i860, by Jason Eckhardt.
-x86 gas has a new .arch pseudo op to specify the target CPU architecture.
+* Support for CRIS (Axis Communications ETRAX series).
-x86 gas -q command line option quietens warnings about register size changes
-due to suffix, indirect jmp/call without `*', stand-alone prefixes, and
-translating various deprecated floating point instructions.
+* x86 gas has a new .arch pseudo op to specify the target CPU architecture.
+
+* x86 gas -q command line option quietens warnings about register size changes
+ due to suffix, indirect jmp/call without `*', stand-alone prefixes, and
+ translating various deprecated floating point instructions.
Changes in 2.10:
-Support for the ARM msr instruction was changed to only allow an immediate
-operand when altering the flags field.
+* Support for the ARM msr instruction was changed to only allow an immediate
+ operand when altering the flags field.
-Support for ATMEL AVR.
+* Support for ATMEL AVR.
-Support for IBM 370 ELF. Somewhat experimental.
+* Support for IBM 370 ELF. Somewhat experimental.
-Support for numbers with suffixes.
+* Support for numbers with suffixes.
-Added support for breaking to the end of repeat loops.
+* Added support for breaking to the end of repeat loops.
-Added support for parallel instruction syntax (DOUBLEBAR_PARALLEL).
+* Added support for parallel instruction syntax (DOUBLEBAR_PARALLEL).
-New .elseif pseudo-op added.
+* New .elseif pseudo-op added.
-New --fatal-warnings option.
+* New --fatal-warnings option.
-picoJava architecture support added.
+* picoJava architecture support added.
-Motorola MCore 210 processor support added.
+* Motorola MCore 210 processor support added.
-A new pseudo-op .intel_syntax has been implemented to allow gas to parse i386
-assembly programs with intel syntax.
+* A new pseudo-op .intel_syntax has been implemented to allow gas to parse i386
+ assembly programs with intel syntax.
-New pseudo-ops .func,.endfunc to aid in debugging user-written assembler code.
+* New pseudo-ops .func,.endfunc to aid in debugging user-written assembler code.
-Added -gdwarf2 option to generate DWARF 2 debugging information.
+* Added -gdwarf2 option to generate DWARF 2 debugging information.
-Full 16-bit mode support for i386.
+* Full 16-bit mode support for i386.
-Greatly improved instruction operand checking for i386. This change will
-produce errors or warnings on incorrect assembly code that previous versions of
-gas accepted. If you get unexpected messages from code that worked with older
-versions of gas, please double check the code before reporting a bug.
+* Greatly improved instruction operand checking for i386. This change will
+ produce errors or warnings on incorrect assembly code that previous versions
+ of gas accepted. If you get unexpected messages from code that worked with
+ older versions of gas, please double check the code before reporting a bug.
-Weak symbol support added for COFF targets.
+* Weak symbol support added for COFF targets.
-Mitsubishi D30V support added.
+* Mitsubishi D30V support added.
-Texas Instruments c80 (tms320c80) support added.
+* Texas Instruments c80 (tms320c80) support added.
-i960 ELF support added.
+* i960 ELF support added.
-ARM ELF support added.
+* ARM ELF support added.
Changes in 2.9:
-Texas Instruments c30 (tms320c30) support added.
+* Texas Instruments c30 (tms320c30) support added.
-The assembler now optimizes the exception frame information generated by egcs
-and gcc 2.8. The new --traditional-format option disables this optimization.
+* The assembler now optimizes the exception frame information generated by egcs
+ and gcc 2.8. The new --traditional-format option disables this optimization.
-Added --gstabs option to generate stabs debugging information.
+* Added --gstabs option to generate stabs debugging information.
-The -a option takes a new suboption, m (e.g., -alm) to expand macros in a
-listing.
+* The -a option takes a new suboption, m (e.g., -alm) to expand macros in a
+ listing.
-Added -MD option to print dependencies.
+* Added -MD option to print dependencies.
Changes in 2.8:
-BeOS support added.
+* BeOS support added.
-MIPS16 support added.
+* MIPS16 support added.
-Motorola ColdFire 5200 support added (configure for m68k and use -m5200).
+* Motorola ColdFire 5200 support added (configure for m68k and use -m5200).
-Alpha/VMS support added.
+* Alpha/VMS support added.
-m68k options --base-size-default-16, --base-size-default-32,
---disp-size-default-16, and --disp-size-default-32 added.
+* m68k options --base-size-default-16, --base-size-default-32,
+ --disp-size-default-16, and --disp-size-default-32 added.
-The alignment directives now take an optional third argument, which is the
-maximum number of bytes to skip. If doing the alignment would require skipping
-more than the given number of bytes, the alignment is not done at all.
+* The alignment directives now take an optional third argument, which is the
+ maximum number of bytes to skip. If doing the alignment would require
+ skipping more than the given number of bytes, the alignment is not done at
+ all.
-The ELF assembler has a new pseudo-op, .symver, used for symbol versioning.
+* The ELF assembler has a new pseudo-op, .symver, used for symbol versioning.
-The -a option takes a new suboption, c (e.g., -alc), to skip false conditionals
-in listings.
+* The -a option takes a new suboption, c (e.g., -alc), to skip false
+ conditionals in listings.
-Added new pseudo-op, .equiv; it's like .equ, except that it is an error if the
-symbol is already defined.
+* Added new pseudo-op, .equiv; it's like .equ, except that it is an error if
+ the symbol is already defined.
Changes in 2.7:
-The PowerPC assembler now allows the use of symbolic register names (r0, etc.)
-if -mregnames is used. Symbolic names preceded by a '%' (%r0, etc.) can be
-used any time. PowerPC 860 move to/from SPR instructions have been added.
+* The PowerPC assembler now allows the use of symbolic register names (r0,
+ etc.) if -mregnames is used. Symbolic names preceded by a '%' (%r0, etc.)
+ can be used any time. PowerPC 860 move to/from SPR instructions have been
+ added.
-Alpha Linux (ELF) support added.
+* Alpha Linux (ELF) support added.
-PowerPC ELF support added.
+* PowerPC ELF support added.
-m68k Linux (ELF) support added.
+* m68k Linux (ELF) support added.
-i960 Hx/Jx support added.
+* i960 Hx/Jx support added.
-i386/PowerPC gnu-win32 support added.
+* i386/PowerPC gnu-win32 support added.
-SCO ELF support added. For OpenServer 5 targets (i386-unknown-sco3.2v5) the
-default is to build COFF-only support. To get a set of tools that generate ELF
-(they'll understand both COFF and ELF), you must configure with
-target=i386-unknown-sco3.2v5elf.
+* SCO ELF support added. For OpenServer 5 targets (i386-unknown-sco3.2v5) the
+ default is to build COFF-only support. To get a set of tools that generate
+ ELF (they'll understand both COFF and ELF), you must configure with
+ target=i386-unknown-sco3.2v5elf.
-m88k-motorola-sysv3* support added.
+* m88k-motorola-sysv3* support added.
Changes in 2.6:
-Gas now directly supports macros, without requiring GASP.
+* Gas now directly supports macros, without requiring GASP.
-Gas now has an MRI assembler compatibility mode. Use -M or --mri to select MRI
-mode. The pseudo-op ``.mri 1'' will switch into the MRI mode until the ``.mri
-0'' is seen; this can be convenient for inline assembler code.
+* Gas now has an MRI assembler compatibility mode. Use -M or --mri to select
+ MRI mode. The pseudo-op ``.mri 1'' will switch into the MRI mode until the
+ ``.mri 0'' is seen; this can be convenient for inline assembler code.
-Added --defsym SYM=VALUE option.
+* Added --defsym SYM=VALUE option.
-Added -mips4 support to MIPS assembler.
+* Added -mips4 support to MIPS assembler.
-Added PIC support to Solaris and SPARC SunOS 4 assembler.
+* Added PIC support to Solaris and SPARC SunOS 4 assembler.
Changes in 2.4:
-Converted this directory to use an autoconf-generated configure script.
+* Converted this directory to use an autoconf-generated configure script.
-ARM support, from Richard Earnshaw.
+* ARM support, from Richard Earnshaw.
-Updated VMS support, from Pat Rankin, including considerably improved debugging
-support.
+* Updated VMS support, from Pat Rankin, including considerably improved
+ debugging support.
-Support for the control registers in the 68060.
+* Support for the control registers in the 68060.
-Handles (ignores) a new directive ".this_GCC_requires_the_GNU_assembler", to
-provide for possible future gcc changes, for targets where gas provides some
-features not available in the native assembler. If the native assembler is
-used, it should become obvious pretty quickly what the problem is.
+* Handles (ignores) a new directive ".this_GCC_requires_the_GNU_assembler", to
+ provide for possible future gcc changes, for targets where gas provides some
+ features not available in the native assembler. If the native assembler is
+ used, it should become obvious pretty quickly what the problem is.
-Usage message is available with "--help".
+* Usage message is available with "--help".
-The GNU Assembler Preprocessor (gasp) is included. (Actually, it was in 2.3
-also, but didn't get into the NEWS file.)
+* The GNU Assembler Preprocessor (gasp) is included. (Actually, it was in 2.3
+ also, but didn't get into the NEWS file.)
-Weak symbol support for a.out.
+* Weak symbol support for a.out.
-A bug in the listing code which could cause an infinite loop has been fixed.
-Bugs in listings when generating a COFF object file have also been fixed.
+* A bug in the listing code which could cause an infinite loop has been fixed.
+ Bugs in listings when generating a COFF object file have also been fixed.
-Initial i386-svr4 PIC implementation from Eric Youngdale, based on code by Paul
-Kranenburg.
+* Initial i386-svr4 PIC implementation from Eric Youngdale, based on code by
+ Paul Kranenburg.
-Improved Alpha support. Immediate constants can have a much larger range now.
-Support for the 21164 has been contributed by Digital.
+* Improved Alpha support. Immediate constants can have a much larger range
+ now. Support for the 21164 has been contributed by Digital.
-Updated ns32k (pc532-mach, netbsd532) support from Ian Dall.
+* Updated ns32k (pc532-mach, netbsd532) support from Ian Dall.
Changes in 2.3:
-Mach i386 support, by David Mackenzie and Ken Raeburn.
-
-RS/6000 and PowerPC support by Ian Taylor.
+* Mach i386 support, by David Mackenzie and Ken Raeburn.
-VMS command scripts (make-gas.com, config-gas.com) have been worked on a bit,
-based on mail received from various people. The `-h#' option should work again
-too.
+* RS/6000 and PowerPC support by Ian Taylor.
-HP-PA work, by Jeff Law. Note, for the PA, gas-2.3 has been designed to work
-with gdb-4.12 and gcc-2.6. As gcc-2.6 has not been released yet, a special
-version of gcc-2.5.8 has been patched to work with gas-2.3. You can retrieve
-this special version of gcc-2.5.8 via anonymous ftp from jaguar.cs.utah.edu
-in the "dist" directory.
+* VMS command scripts (make-gas.com, config-gas.com) have been worked on a bit,
+ based on mail received from various people. The `-h#' option should work
+ again too.
-Vax support in gas fixed for BSD, so it builds and seems to run a couple simple
-tests okay. I haven't put it through extensive testing. (GNU make is
-currently required for BSD 4.3 builds.)
+* HP-PA work, by Jeff Law. Note, for the PA, gas-2.3 has been designed to work
+ with gdb-4.12 and gcc-2.6. As gcc-2.6 has not been released yet, a special
+ version of gcc-2.5.8 has been patched to work with gas-2.3. You can retrieve
+ this special version of gcc-2.5.8 via anonymous ftp from jaguar.cs.utah.edu
+ in the "dist" directory.
-Support for the DEC Alpha, running OSF/1 (ECOFF format). The gas support is
-based on code donated by CMU, which used an a.out-based format. I'm afraid the
-alpha-a.out support is pretty badly mangled, and much of it removed; making it
-work will require rewriting it as BFD support for the format anyways.
+* Vax support in gas fixed for BSD, so it builds and seems to run a couple
+ simple tests okay. I haven't put it through extensive testing. (GNU make is
+ currently required for BSD 4.3 builds.)
-Irix 5 support.
+* Support for the DEC Alpha, running OSF/1 (ECOFF format). The gas support is
+ based on code donated by CMU, which used an a.out-based format. I'm afraid
+ the alpha-a.out support is pretty badly mangled, and much of it removed;
+ making it work will require rewriting it as BFD support for the format anyways.
-The test suites have been fixed up a bit, so that they should work with a
-couple different versions of expect and dejagnu.
+* Irix 5 support.
-Symbols' values are now handled internally as expressions, permitting more
-flexibility in evaluating them in some cases. Some details of relocation
-handling have also changed, and simple constant pool management has been added,
-to make the Alpha port easier.
+* The test suites have been fixed up a bit, so that they should work with a
+ couple different versions of expect and dejagnu.
-New option "--statistics" for printing out program run times. This is intended
-to be used with the gcc "-Q" option, which prints out times spent in various
-phases of compilation. (You should be able to get all of them printed out with
-"gcc -Q -Wa,--statistics", I think.)
+* Symbols' values are now handled internally as expressions, permitting more
+ flexibility in evaluating them in some cases. Some details of relocation
+ handling have also changed, and simple constant pool management has been
+ added, to make the Alpha port easier.
-----------------------------------------------------------------
+* New option "--statistics" for printing out program run times. This is
+ intended to be used with the gcc "-Q" option, which prints out times spent in
+ various phases of compilation. (You should be able to get all of them
+ printed out with "gcc -Q -Wa,--statistics", I think.)
Changes in 2.2:
-RS/6000 AIX and MIPS SGI Irix 5 support has been added.
-
-Configurations that are still in development (and therefore are convenient to
-have listed in configure.in) still get rejected without a minor change to
-gas/Makefile.in, so people not doing development work shouldn't get the
-impression that support for such configurations is actually believed to be
-reliable.
+* RS/6000 AIX and MIPS SGI Irix 5 support has been added.
-The program name (usually "as") is printed when a fatal error message is
-displayed. This should prevent some confusion about the source of occasional
-messages about "internal errors".
+* Configurations that are still in development (and therefore are convenient to
+ have listed in configure.in) still get rejected without a minor change to
+ gas/Makefile.in, so people not doing development work shouldn't get the
+ impression that support for such configurations is actually believed to be
+ reliable.
-ELF support is falling into place. Support for the 386 should be working.
-Support for SPARC Solaris is in. HPPA support from Utah is being integrated.
+* The program name (usually "as") is printed when a fatal error message is
+ displayed. This should prevent some confusion about the source of occasional
+ messages about "internal errors".
-Symbol values are maintained as expressions instead of being immediately boiled
-down to add-symbol, sub-symbol, and constant. This permits slightly more
-complex calculations involving symbols whose values are not alreadey known.
+* ELF support is falling into place. Support for the 386 should be working.
+ Support for SPARC Solaris is in. HPPA support from Utah is being integrated.
-DBX-style debugging info ("stabs") is now supported for COFF formats.
-If any stabs directives are seen in the source, GAS will create two new
-sections: a ".stab" and a ".stabstr" section. The format of the .stab
-section is nearly identical to the a.out symbol format, and .stabstr is
-its string table. For this to be useful, you must have configured GCC
-to generate stabs (by defining DBX_DEBUGGING_INFO), and must have a GDB
-that can use the stab sections (4.11 or later).
+* Symbol values are maintained as expressions instead of being immediately
+ boiled down to add-symbol, sub-symbol, and constant. This permits slightly
+ more complex calculations involving symbols whose values are not alreadey
+ known.
-LynxOS, on i386 and m68k platforms, is now supported. SPARC LynxOS
-support is in progress.
+* DBX-style debugging info ("stabs") is now supported for COFF formats.
+ If any stabs directives are seen in the source, GAS will create two new
+ sections: a ".stab" and a ".stabstr" section. The format of the .stab
+ section is nearly identical to the a.out symbol format, and .stabstr is
+ its string table. For this to be useful, you must have configured GCC
+ to generate stabs (by defining DBX_DEBUGGING_INFO), and must have a GDB
+ that can use the stab sections (4.11 or later).
-----------------------------------------------------------------
+* LynxOS, on i386 and m68k platforms, is now supported. SPARC LynxOS
+ support is in progress.
Changes in 2.1:
-Several small fixes for i386-aix (PS/2) support from Minh Tran-Le have been
-incorporated, but not well tested yet.
+* Several small fixes for i386-aix (PS/2) support from Minh Tran-Le have been
+ incorporated, but not well tested yet.
-Altered the opcode table split for m68k; it should require less VM to compile
-with gcc now.
+* Altered the opcode table split for m68k; it should require less VM to compile
+ with gcc now.
-Some minor adjustments to add (Convergent Technologies') Miniframe support,
-suggested by Ronald Cole.
+* Some minor adjustments to add (Convergent Technologies') Miniframe support,
+ suggested by Ronald Cole.
-HPPA support (running OSF only, not HPUX) has been contributed by Utah. This
-includes improved ELF support, which I've started adapting for SPARC Solaris
-2.x. Integration isn't completely, so it probably won't work.
+* HPPA support (running OSF only, not HPUX) has been contributed by Utah. This
+ includes improved ELF support, which I've started adapting for SPARC Solaris
+ 2.x. Integration isn't completely, so it probably won't work.
-HP9000/300 support, donated by HP, has been merged in.
+* HP9000/300 support, donated by HP, has been merged in.
-Ian Taylor has finished the MIPS ECOFF (Ultrix, Irix) support.
+* Ian Taylor has finished the MIPS ECOFF (Ultrix, Irix) support.
-Better error messages for unsupported configurations (e.g., hppa-hpux).
+* Better error messages for unsupported configurations (e.g., hppa-hpux).
-Test suite framework is starting to become reasonable.
-
-----------------------------------------------------------------
+* Test suite framework is starting to become reasonable.
Changes in 2.0:
-Mostly bug fixes.
-
-Some more merging of BFD and ELF code, but ELF still doesn't work.
+* Mostly bug fixes.
-----------------------------------------------------------------
+* Some more merging of BFD and ELF code, but ELF still doesn't work.
Changes in 1.94:
-BFD merge is partly done. Adventurous souls may try giving configure the
-"--with-bfd-assembler" option. Currently, ELF format requires it, a.out format
-accepts it; SPARC CPU accepts it. It's the default only for OS "elf" or
-"solaris". (ELF isn't really supported yet. It needs work. I've got some
-code from Utah for HP-PA ELF, and from DG for m88k ELF, but they're not fully
-merged yet.)
-
-The 68K opcode table has been split in half. It should now compile under gcc
-without consuming ridiculous amounts of memory.
+* BFD merge is partly done. Adventurous souls may try giving configure the
+ "--with-bfd-assembler" option. Currently, ELF format requires it, a.out
+ format accepts it; SPARC CPU accepts it. It's the default only for OS "elf"
+ or "solaris". (ELF isn't really supported yet. It needs work. I've got
+ some code from Utah for HP-PA ELF, and from DG for m88k ELF, but they're not
+ fully merged yet.)
-A couple data structures have been reduced in size. This should result in
-saving a little bit of space at runtime.
+* The 68K opcode table has been split in half. It should now compile under gcc
+ without consuming ridiculous amounts of memory.
-Support for MIPS, from OSF and Ralph Campbell, has been merged in. The OSF
-code provided ROSE format support, which I haven't merged in yet. (I can make
-it available, if anyone wants to try it out.) Ralph's code, for BSD 4.4,
-supports a.out format. We don't have ECOFF support in just yet; it's coming.
+* A couple data structures have been reduced in size. This should result in
+ saving a little bit of space at runtime.
-Support for the Hitachi H8/500 has been added.
+* Support for MIPS, from OSF and Ralph Campbell, has been merged in. The OSF
+ code provided ROSE format support, which I haven't merged in yet. (I can
+ make it available, if anyone wants to try it out.) Ralph's code, for BSD
+ 4.4, supports a.out format. We don't have ECOFF support in just yet; it's
+ coming.
-VMS host and target support should be working now, thanks chiefly to Eric
-Youngdale.
+* Support for the Hitachi H8/500 has been added.
-----------------------------------------------------------------
+* VMS host and target support should be working now, thanks chiefly to Eric
+ Youngdale.
Changes in 1.93.01:
-For m68k, support for more processors has been added: 68040, CPU32, 68851.
+* For m68k, support for more processors has been added: 68040, CPU32, 68851.
-For i386, .align is now power-of-two; was number-of-bytes.
+* For i386, .align is now power-of-two; was number-of-bytes.
-For m68k, "%" is now accepted before register names. For COFF format, which
-doesn't use underscore prefixes for C labels, it is required, so variable "a0"
-can be distinguished from the register.
+* For m68k, "%" is now accepted before register names. For COFF format, which
+ doesn't use underscore prefixes for C labels, it is required, so variable "a0"
+ can be distinguished from the register.
-Last public release was 1.38. Lots of configuration changes since then, lots
-of new CPUs and formats, lots of bugs fixed.
+* Last public release was 1.38. Lots of configuration changes since then, lots
+ of new CPUs and formats, lots of bugs fixed.
Local variables:
diff --git a/contrib/binutils/gas/README b/contrib/binutils/gas/README
index ef12d3f..7905395 100644
--- a/contrib/binutils/gas/README
+++ b/contrib/binutils/gas/README
@@ -180,7 +180,7 @@ most of the above hosts, plus
decstation-bsd (a.out format, to be used in BSD 4.4)
ebmon29k
go32 (DOS on i386, with DJGPP -- old a.out version)
- h8/300, h8/500 (Hitachi)
+ H8/300, H8/500 (Hitachi)
i386-aix (ps/2)
i960-coff
mips ecoff (decstation-ultrix, iris, mips magnum, mips-idt-ecoff)
@@ -232,47 +232,10 @@ REPORTING BUGS IN GAS
Bugs in gas should be reported to:
- bug-gnu-utils@gnu.org.
+ bug-binutils@gnu.org.
They may be cross-posted to gcc-bugs@gnu.org if they affect the use of
gas with gcc. They should not be reported just to gcc-bugs, since not
all of the maintainers read that list.
-If you report a bug in GAS, please remember to include:
-
-A description of exactly what went wrong, and exactly what should have
-happened instead.
-
-The type of machine (VAX, 68020, etc) and operating system (BSD, SunOS, DYNIX,
-VMS, etc) GAS was running on.
-
-The configuration name(s) given to the "configure" script. The
-"config.status" file should have this information.
-
-The options given to GAS at run time.
-
-The actual input file that caused the problem.
-
-It is silly to report a bug in GAS without including an input file for GAS.
-Don't ask us to generate the file just because you made it from files you
-think we have access to.
-
-1. You might be mistaken.
-2. It might take us a lot of time to install things to regenerate that file.
-3. We might get a different file from the one you got, and might not see any
- bug.
-
-To save us these delays and uncertainties, always send the input file for the
-program that failed. A smaller test case that demonstrates the problem is of
-course preferable, but be sure it is a complete input file, and that it really
-does demonstrate the problem; but if paring it down would cause large delays
-in filing the bug report, don't bother.
-
-If the input file is very large, and you are on the internet, you may want to
-make it available for anonymous FTP instead of mailing it. If you do, include
-instructions for FTP'ing it in your bug report.
-
-If you expect to be contributing a large number of test cases, it would be
-helpful if you would look at the test suite included in the release (based on
-the Deja Gnu testing framework, available from the usual ftp sites) and write
-test cases to fit into that framework. This is certainly not required.
+See ../binutils/README for what we need in a bug report.
diff --git a/contrib/binutils/gas/acinclude.m4 b/contrib/binutils/gas/acinclude.m4
index f16eefc..4a3ccf3 100644
--- a/contrib/binutils/gas/acinclude.m4
+++ b/contrib/binutils/gas/acinclude.m4
@@ -1,5 +1,5 @@
dnl GAS_CHECK_DECL_NEEDED(name, typedefname, typedef, headers)
-AC_DEFUN(GAS_CHECK_DECL_NEEDED,[
+AC_DEFUN([GAS_CHECK_DECL_NEEDED],[
AC_MSG_CHECKING(whether declaration is required for $1)
AC_CACHE_VAL(gas_cv_decl_needed_$1,
AC_TRY_LINK([$4],
@@ -19,7 +19,7 @@ dnl Some non-ANSI preprocessors botch requoting inside strings. That's bad
dnl enough, but on some of those systems, the assert macro relies on requoting
dnl working properly!
dnl GAS_WORKING_ASSERT
-AC_DEFUN(GAS_WORKING_ASSERT,
+AC_DEFUN([GAS_WORKING_ASSERT],
[AC_MSG_CHECKING([for working assert macro])
AC_CACHE_VAL(gas_cv_assert_ok,
AC_TRY_LINK([#include <assert.h>
@@ -39,7 +39,7 @@ dnl
dnl Since many Bourne shell implementations lack subroutines, use this
dnl hack to simplify the code in configure.in.
dnl GAS_UNIQ(listvar)
-AC_DEFUN(GAS_UNIQ,
+AC_DEFUN([GAS_UNIQ],
[_gas_uniq_list="[$]$1"
_gas_uniq_newlist=""
dnl Protect against empty input list.
diff --git a/contrib/binutils/gas/aclocal.m4 b/contrib/binutils/gas/aclocal.m4
index c936be4..c5ef088 100644
--- a/contrib/binutils/gas/aclocal.m4
+++ b/contrib/binutils/gas/aclocal.m4
@@ -1,143 +1,949 @@
-dnl aclocal.m4 generated automatically by aclocal 1.4-p5
-
-dnl Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc.
-dnl This file is free software; the Free Software Foundation
-dnl gives unlimited permission to copy and/or distribute it,
-dnl with or without modifications, as long as this notice is preserved.
-
-dnl This program is distributed in the hope that it will be useful,
-dnl but WITHOUT ANY WARRANTY, to the extent permitted by law; without
-dnl even the implied warranty of MERCHANTABILITY or FITNESS FOR A
-dnl PARTICULAR PURPOSE.
-
-dnl GAS_CHECK_DECL_NEEDED(name, typedefname, typedef, headers)
-AC_DEFUN(GAS_CHECK_DECL_NEEDED,[
-AC_MSG_CHECKING(whether declaration is required for $1)
-AC_CACHE_VAL(gas_cv_decl_needed_$1,
-AC_TRY_LINK([$4],
-[
-typedef $3;
-$2 x;
-x = ($2) $1;
-], gas_cv_decl_needed_$1=no, gas_cv_decl_needed_$1=yes))dnl
-AC_MSG_RESULT($gas_cv_decl_needed_$1)
-if test $gas_cv_decl_needed_$1 = yes; then
- AC_DEFINE([NEED_DECLARATION_]translit($1, [a-z], [A-Z]), 1,
- [Define if $1 is not declared in system header files.])
+# generated automatically by aclocal 1.8.4 -*- Autoconf -*-
+
+# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
+# Free Software Foundation, Inc.
+# This file is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+# -*- Autoconf -*-
+# Copyright (C) 2002, 2003 Free Software Foundation, Inc.
+# Generated from amversion.in; do not edit by hand.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+
+# AM_AUTOMAKE_VERSION(VERSION)
+# ----------------------------
+# Automake X.Y traces this macro to ensure aclocal.m4 has been
+# generated from the m4 files accompanying Automake X.Y.
+AC_DEFUN([AM_AUTOMAKE_VERSION], [am__api_version="1.8"])
+
+# AM_SET_CURRENT_AUTOMAKE_VERSION
+# -------------------------------
+# Call AM_AUTOMAKE_VERSION so it can be traced.
+# This function is AC_REQUIREd by AC_INIT_AUTOMAKE.
+AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
+ [AM_AUTOMAKE_VERSION([1.8.4])])
+
+# AM_AUX_DIR_EXPAND
+
+# Copyright (C) 2001, 2003 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+
+# For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets
+# $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to
+# `$srcdir', `$srcdir/..', or `$srcdir/../..'.
+#
+# Of course, Automake must honor this variable whenever it calls a
+# tool from the auxiliary directory. The problem is that $srcdir (and
+# therefore $ac_aux_dir as well) can be either absolute or relative,
+# depending on how configure is run. This is pretty annoying, since
+# it makes $ac_aux_dir quite unusable in subdirectories: in the top
+# source directory, any form will work fine, but in subdirectories a
+# relative path needs to be adjusted first.
+#
+# $ac_aux_dir/missing
+# fails when called from a subdirectory if $ac_aux_dir is relative
+# $top_srcdir/$ac_aux_dir/missing
+# fails if $ac_aux_dir is absolute,
+# fails when called from a subdirectory in a VPATH build with
+# a relative $ac_aux_dir
+#
+# The reason of the latter failure is that $top_srcdir and $ac_aux_dir
+# are both prefixed by $srcdir. In an in-source build this is usually
+# harmless because $srcdir is `.', but things will broke when you
+# start a VPATH build or use an absolute $srcdir.
+#
+# So we could use something similar to $top_srcdir/$ac_aux_dir/missing,
+# iff we strip the leading $srcdir from $ac_aux_dir. That would be:
+# am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"`
+# and then we would define $MISSING as
+# MISSING="\${SHELL} $am_aux_dir/missing"
+# This will work as long as MISSING is not called from configure, because
+# unfortunately $(top_srcdir) has no meaning in configure.
+# However there are other variables, like CC, which are often used in
+# configure, and could therefore not use this "fixed" $ac_aux_dir.
+#
+# Another solution, used here, is to always expand $ac_aux_dir to an
+# absolute PATH. The drawback is that using absolute paths prevent a
+# configured tree to be moved without reconfiguration.
+
+AC_DEFUN([AM_AUX_DIR_EXPAND],
+[dnl Rely on autoconf to set up CDPATH properly.
+AC_PREREQ([2.50])dnl
+# expand $ac_aux_dir to an absolute path
+am_aux_dir=`cd $ac_aux_dir && pwd`
+])
+
+# AM_CONDITIONAL -*- Autoconf -*-
+
+# Copyright (C) 1997, 2000, 2001, 2003 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+
+# serial 6
+
+# AM_CONDITIONAL(NAME, SHELL-CONDITION)
+# -------------------------------------
+# Define a conditional.
+AC_DEFUN([AM_CONDITIONAL],
+[AC_PREREQ(2.52)dnl
+ ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])],
+ [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl
+AC_SUBST([$1_TRUE])
+AC_SUBST([$1_FALSE])
+if $2; then
+ $1_TRUE=
+ $1_FALSE='#'
+else
+ $1_TRUE='#'
+ $1_FALSE=
fi
-])dnl
-dnl
-dnl Some non-ANSI preprocessors botch requoting inside strings. That's bad
-dnl enough, but on some of those systems, the assert macro relies on requoting
-dnl working properly!
-dnl GAS_WORKING_ASSERT
-AC_DEFUN(GAS_WORKING_ASSERT,
-[AC_MSG_CHECKING([for working assert macro])
-AC_CACHE_VAL(gas_cv_assert_ok,
-AC_TRY_LINK([#include <assert.h>
-#include <stdio.h>], [
-/* check for requoting problems */
-static int a, b, c, d;
-static char *s;
-assert (!strcmp(s, "foo bar baz quux"));
-/* check for newline handling */
-assert (a == b
- || c == d);
-], gas_cv_assert_ok=yes, gas_cv_assert_ok=no))dnl
-AC_MSG_RESULT($gas_cv_assert_ok)
-test $gas_cv_assert_ok = yes || AC_DEFINE(BROKEN_ASSERT, 1, [assert broken?])
-])dnl
-dnl
-dnl Since many Bourne shell implementations lack subroutines, use this
-dnl hack to simplify the code in configure.in.
-dnl GAS_UNIQ(listvar)
-AC_DEFUN(GAS_UNIQ,
-[_gas_uniq_list="[$]$1"
-_gas_uniq_newlist=""
-dnl Protect against empty input list.
-for _gas_uniq_i in _gas_uniq_dummy [$]_gas_uniq_list ; do
- case [$]_gas_uniq_i in
- _gas_uniq_dummy) ;;
- *) case " [$]_gas_uniq_newlist " in
- *" [$]_gas_uniq_i "*) ;;
- *) _gas_uniq_newlist="[$]_gas_uniq_newlist [$]_gas_uniq_i" ;;
- esac ;;
- esac
-done
-$1=[$]_gas_uniq_newlist
-])dnl
-
-sinclude(../libtool.m4)
-dnl The lines below arrange for aclocal not to bring libtool.m4
-dnl AM_PROG_LIBTOOL into aclocal.m4, while still arranging for automake
-dnl to add a definition of LIBTOOL to Makefile.in.
-ifelse(yes,no,[
-AC_DEFUN([AM_PROG_LIBTOOL],)
-AC_DEFUN([AC_CHECK_LIBM],)
-AC_SUBST(LIBTOOL)
+AC_CONFIG_COMMANDS_PRE(
+[if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then
+ AC_MSG_ERROR([conditional "$1" was never defined.
+Usually this means the macro was only invoked conditionally.])
+fi])])
+
+# serial 7 -*- Autoconf -*-
+
+# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004
+# Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+
+
+# There are a few dirty hacks below to avoid letting `AC_PROG_CC' be
+# written in clear, in which case automake, when reading aclocal.m4,
+# will think it sees a *use*, and therefore will trigger all it's
+# C support machinery. Also note that it means that autoscan, seeing
+# CC etc. in the Makefile, will ask for an AC_PROG_CC use...
+
+
+
+# _AM_DEPENDENCIES(NAME)
+# ----------------------
+# See how the compiler implements dependency checking.
+# NAME is "CC", "CXX", "GCJ", or "OBJC".
+# We try a few techniques and use that to set a single cache variable.
+#
+# We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was
+# modified to invoke _AM_DEPENDENCIES(CC); we would have a circular
+# dependency, and given that the user is not expected to run this macro,
+# just rely on AC_PROG_CC.
+AC_DEFUN([_AM_DEPENDENCIES],
+[AC_REQUIRE([AM_SET_DEPDIR])dnl
+AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl
+AC_REQUIRE([AM_MAKE_INCLUDE])dnl
+AC_REQUIRE([AM_DEP_TRACK])dnl
+
+ifelse([$1], CC, [depcc="$CC" am_compiler_list=],
+ [$1], CXX, [depcc="$CXX" am_compiler_list=],
+ [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'],
+ [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'],
+ [depcc="$$1" am_compiler_list=])
+
+AC_CACHE_CHECK([dependency style of $depcc],
+ [am_cv_$1_dependencies_compiler_type],
+[if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
+ # We make a subdir and do the tests there. Otherwise we can end up
+ # making bogus files that we don't know about and never remove. For
+ # instance it was reported that on HP-UX the gcc test will end up
+ # making a dummy file named `D' -- because `-MD' means `put the output
+ # in D'.
+ mkdir conftest.dir
+ # Copy depcomp to subdir because otherwise we won't find it if we're
+ # using a relative directory.
+ cp "$am_depcomp" conftest.dir
+ cd conftest.dir
+ # We will build objects and dependencies in a subdirectory because
+ # it helps to detect inapplicable dependency modes. For instance
+ # both Tru64's cc and ICC support -MD to output dependencies as a
+ # side effect of compilation, but ICC will put the dependencies in
+ # the current directory while Tru64 will put them in the object
+ # directory.
+ mkdir sub
+
+ am_cv_$1_dependencies_compiler_type=none
+ if test "$am_compiler_list" = ""; then
+ am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp`
+ fi
+ for depmode in $am_compiler_list; do
+ # Setup a source with many dependencies, because some compilers
+ # like to wrap large dependency lists on column 80 (with \), and
+ # we should not choose a depcomp mode which is confused by this.
+ #
+ # We need to recreate these files for each test, as the compiler may
+ # overwrite some of them when testing with obscure command lines.
+ # This happens at least with the AIX C compiler.
+ : > sub/conftest.c
+ for i in 1 2 3 4 5 6; do
+ echo '#include "conftst'$i'.h"' >> sub/conftest.c
+ # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
+ # Solaris 8's {/usr,}/bin/sh.
+ touch sub/conftst$i.h
+ done
+ echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
+
+ case $depmode in
+ nosideeffect)
+ # after this tag, mechanisms are not by side-effect, so they'll
+ # only be used when explicitly requested
+ if test "x$enable_dependency_tracking" = xyes; then
+ continue
+ else
+ break
+ fi
+ ;;
+ none) break ;;
+ esac
+ # We check with `-c' and `-o' for the sake of the "dashmstdout"
+ # mode. It turns out that the SunPro C++ compiler does not properly
+ # handle `-M -o', and we need to detect this.
+ if depmode=$depmode \
+ source=sub/conftest.c object=sub/conftest.${OBJEXT-o} \
+ depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
+ $SHELL ./depcomp $depcc -c -o sub/conftest.${OBJEXT-o} sub/conftest.c \
+ >/dev/null 2>conftest.err &&
+ grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
+ grep sub/conftest.${OBJEXT-o} sub/conftest.Po > /dev/null 2>&1 &&
+ ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
+ # icc doesn't choke on unknown options, it will just issue warnings
+ # or remarks (even with -Werror). So we grep stderr for any message
+ # that says an option was ignored or not supported.
+ # When given -MP, icc 7.0 and 7.1 complain thusly:
+ # icc: Command line warning: ignoring option '-M'; no argument required
+ # The diagnosis changed in icc 8.0:
+ # icc: Command line remark: option '-MP' not supported
+ if (grep 'ignoring option' conftest.err ||
+ grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
+ am_cv_$1_dependencies_compiler_type=$depmode
+ break
+ fi
+ fi
+ done
+
+ cd ..
+ rm -rf conftest.dir
+else
+ am_cv_$1_dependencies_compiler_type=none
+fi
+])
+AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type])
+AM_CONDITIONAL([am__fastdep$1], [
+ test "x$enable_dependency_tracking" != xno \
+ && test "$am_cv_$1_dependencies_compiler_type" = gcc3])
])
-sinclude(../gettext.m4)
-ifelse(yes,no,[
-AC_DEFUN([CY_WITH_NLS],)
-AC_SUBST(INTLLIBS)
+
+# AM_SET_DEPDIR
+# -------------
+# Choose a directory name for dependency files.
+# This macro is AC_REQUIREd in _AM_DEPENDENCIES
+AC_DEFUN([AM_SET_DEPDIR],
+[AC_REQUIRE([AM_SET_LEADING_DOT])dnl
+AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl
])
-# Do all the work for Automake. This macro actually does too much --
-# some checks are only needed if your package does certain things.
-# But this isn't really a big deal.
-# serial 1
+# AM_DEP_TRACK
+# ------------
+AC_DEFUN([AM_DEP_TRACK],
+[AC_ARG_ENABLE(dependency-tracking,
+[ --disable-dependency-tracking speeds up one-time build
+ --enable-dependency-tracking do not reject slow dependency extractors])
+if test "x$enable_dependency_tracking" != xno; then
+ am_depcomp="$ac_aux_dir/depcomp"
+ AMDEPBACKSLASH='\'
+fi
+AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno])
+AC_SUBST([AMDEPBACKSLASH])
+])
+
+# Generate code to set up dependency tracking. -*- Autoconf -*-
+
+# Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+
+#serial 2
+
+# _AM_OUTPUT_DEPENDENCY_COMMANDS
+# ------------------------------
+AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
+[for mf in $CONFIG_FILES; do
+ # Strip MF so we end up with the name of the file.
+ mf=`echo "$mf" | sed -e 's/:.*$//'`
+ # Check whether this is an Automake generated Makefile or not.
+ # We used to match only the files named `Makefile.in', but
+ # some people rename them; so instead we look at the file content.
+ # Grep'ing the first line is not enough: some people post-process
+ # each Makefile.in and add a new line on top of each file to say so.
+ # So let's grep whole file.
+ if grep '^#.*generated by automake' $mf > /dev/null 2>&1; then
+ dirpart=`AS_DIRNAME("$mf")`
+ else
+ continue
+ fi
+ grep '^DEP_FILES *= *[[^ @%:@]]' < "$mf" > /dev/null || continue
+ # Extract the definition of DEP_FILES from the Makefile without
+ # running `make'.
+ DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
+ test -z "$DEPDIR" && continue
+ # When using ansi2knr, U may be empty or an underscore; expand it
+ U=`sed -n 's/^U = //p' < "$mf"`
+ test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR"
+ # We invoke sed twice because it is the simplest approach to
+ # changing $(DEPDIR) to its actual value in the expansion.
+ for file in `sed -n '
+ /^DEP_FILES = .*\\\\$/ {
+ s/^DEP_FILES = //
+ :loop
+ s/\\\\$//
+ p
+ n
+ /\\\\$/ b loop
+ p
+ }
+ /^DEP_FILES = / s/^DEP_FILES = //p' < "$mf" | \
+ sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
+ # Make sure the directory exists.
+ test -f "$dirpart/$file" && continue
+ fdir=`AS_DIRNAME(["$file"])`
+ AS_MKDIR_P([$dirpart/$fdir])
+ # echo "creating $dirpart/$file"
+ echo '# dummy' > "$dirpart/$file"
+ done
+done
+])# _AM_OUTPUT_DEPENDENCY_COMMANDS
+
+
+# AM_OUTPUT_DEPENDENCY_COMMANDS
+# -----------------------------
+# This macro should only be invoked once -- use via AC_REQUIRE.
+#
+# This code is only required when automatic dependency tracking
+# is enabled. FIXME. This creates each `.P' file that we will
+# need in order to bootstrap the dependency handling code.
+AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
+[AC_CONFIG_COMMANDS([depfiles],
+ [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS],
+ [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"])
+])
+
+# Like AC_CONFIG_HEADER, but automatically create stamp file. -*- Autoconf -*-
+
+# Copyright (C) 1996, 1997, 2000, 2001, 2003 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+
+# serial 7
+
+# AM_CONFIG_HEADER is obsolete. It has been replaced by AC_CONFIG_HEADERS.
+AU_DEFUN([AM_CONFIG_HEADER], [AC_CONFIG_HEADERS($@)])
+
+# Do all the work for Automake. -*- Autoconf -*-
+
+# This macro actually does too much some checks are only needed if
+# your package does certain things. But this isn't really a big deal.
+
+# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
+# Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
-dnl Usage:
-dnl AM_INIT_AUTOMAKE(package,version, [no-define])
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+# serial 11
+
+# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
+# AM_INIT_AUTOMAKE([OPTIONS])
+# -----------------------------------------------
+# The call with PACKAGE and VERSION arguments is the old style
+# call (pre autoconf-2.50), which is being phased out. PACKAGE
+# and VERSION should now be passed to AC_INIT and removed from
+# the call to AM_INIT_AUTOMAKE.
+# We support both call styles for the transition. After
+# the next Automake release, Autoconf can make the AC_INIT
+# arguments mandatory, and then we can depend on a new Autoconf
+# release and drop the old call support.
AC_DEFUN([AM_INIT_AUTOMAKE],
-[AC_REQUIRE([AC_PROG_INSTALL])
-PACKAGE=[$1]
-AC_SUBST(PACKAGE)
-VERSION=[$2]
-AC_SUBST(VERSION)
-dnl test to see if srcdir already configured
-if test "`cd $srcdir && pwd`" != "`pwd`" && test -f $srcdir/config.status; then
+[AC_PREREQ([2.58])dnl
+dnl Autoconf wants to disallow AM_ names. We explicitly allow
+dnl the ones we care about.
+m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
+AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl
+AC_REQUIRE([AC_PROG_INSTALL])dnl
+# test to see if srcdir already configured
+if test "`cd $srcdir && pwd`" != "`pwd`" &&
+ test -f $srcdir/config.status; then
AC_MSG_ERROR([source directory already configured; run "make distclean" there first])
fi
-ifelse([$3],,
-AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
-AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package]))
-AC_REQUIRE([AM_SANITY_CHECK])
-AC_REQUIRE([AC_ARG_PROGRAM])
-dnl FIXME This is truly gross.
-missing_dir=`cd $ac_aux_dir && pwd`
-AM_MISSING_PROG(ACLOCAL, aclocal, $missing_dir)
-AM_MISSING_PROG(AUTOCONF, autoconf, $missing_dir)
-AM_MISSING_PROG(AUTOMAKE, automake, $missing_dir)
-AM_MISSING_PROG(AUTOHEADER, autoheader, $missing_dir)
-AM_MISSING_PROG(MAKEINFO, makeinfo, $missing_dir)
-AC_REQUIRE([AC_PROG_MAKE_SET])])
+
+# test whether we have cygpath
+if test -z "$CYGPATH_W"; then
+ if (cygpath --version) >/dev/null 2>/dev/null; then
+ CYGPATH_W='cygpath -w'
+ else
+ CYGPATH_W=echo
+ fi
+fi
+AC_SUBST([CYGPATH_W])
+
+# Define the identity of the package.
+dnl Distinguish between old-style and new-style calls.
+m4_ifval([$2],
+[m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
+ AC_SUBST([PACKAGE], [$1])dnl
+ AC_SUBST([VERSION], [$2])],
+[_AM_SET_OPTIONS([$1])dnl
+ AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl
+ AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl
+
+_AM_IF_OPTION([no-define],,
+[AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package])
+ AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl
+
+# Some tools Automake needs.
+AC_REQUIRE([AM_SANITY_CHECK])dnl
+AC_REQUIRE([AC_ARG_PROGRAM])dnl
+AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version})
+AM_MISSING_PROG(AUTOCONF, autoconf)
+AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version})
+AM_MISSING_PROG(AUTOHEADER, autoheader)
+AM_MISSING_PROG(MAKEINFO, makeinfo)
+AM_MISSING_PROG(AMTAR, tar)
+AM_PROG_INSTALL_SH
+AM_PROG_INSTALL_STRIP
+AC_REQUIRE([AM_PROG_MKDIR_P])dnl
+# We need awk for the "check" target. The system "awk" is bad on
+# some platforms.
+AC_REQUIRE([AC_PROG_AWK])dnl
+AC_REQUIRE([AC_PROG_MAKE_SET])dnl
+AC_REQUIRE([AM_SET_LEADING_DOT])dnl
+
+_AM_IF_OPTION([no-dependencies],,
+[AC_PROVIDE_IFELSE([AC_PROG_CC],
+ [_AM_DEPENDENCIES(CC)],
+ [define([AC_PROG_CC],
+ defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl
+AC_PROVIDE_IFELSE([AC_PROG_CXX],
+ [_AM_DEPENDENCIES(CXX)],
+ [define([AC_PROG_CXX],
+ defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl
+])
+])
+
+
+# When config.status generates a header, we must update the stamp-h file.
+# This file resides in the same directory as the config header
+# that is generated. The stamp files are numbered to have different names.
+
+# Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the
+# loop where config.status creates the headers, so we can generate
+# our stamp files there.
+AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK],
+[# Compute $1's index in $config_headers.
+_am_stamp_count=1
+for _am_header in $config_headers :; do
+ case $_am_header in
+ $1 | $1:* )
+ break ;;
+ * )
+ _am_stamp_count=`expr $_am_stamp_count + 1` ;;
+ esac
+done
+echo "timestamp for $1" >`AS_DIRNAME([$1])`/stamp-h[]$_am_stamp_count])
+
+# AM_PROG_INSTALL_SH
+# ------------------
+# Define $install_sh.
+
+# Copyright (C) 2001, 2003 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+
+AC_DEFUN([AM_PROG_INSTALL_SH],
+[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
+install_sh=${install_sh-"$am_aux_dir/install-sh"}
+AC_SUBST(install_sh)])
+
+# -*- Autoconf -*-
+# Copyright (C) 2003 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+
+# serial 1
+
+# Check whether the underlying file-system supports filenames
+# with a leading dot. For instance MS-DOS doesn't.
+AC_DEFUN([AM_SET_LEADING_DOT],
+[rm -rf .tst 2>/dev/null
+mkdir .tst 2>/dev/null
+if test -d .tst; then
+ am__leading_dot=.
+else
+ am__leading_dot=_
+fi
+rmdir .tst 2>/dev/null
+AC_SUBST([am__leading_dot])])
+
+
+# Copyright (C) 1998, 1999, 2000, 2001, 2002, 2003
+# Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+
+# serial 4
+
+# AM_PROG_LEX
+# -----------
+# Autoconf leaves LEX=: if lex or flex can't be found. Change that to a
+# "missing" invocation, for better error output.
+AC_DEFUN([AM_PROG_LEX],
+[AC_PREREQ(2.50)dnl
+AC_REQUIRE([AM_MISSING_HAS_RUN])dnl
+AC_REQUIRE([AC_PROG_LEX])dnl
+if test "$LEX" = :; then
+ LEX=${am_missing_run}flex
+fi])
+
+# Add --enable-maintainer-mode option to configure.
+# From Jim Meyering
+
+# Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004
+# Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+
+# serial 3
+
+AC_DEFUN([AM_MAINTAINER_MODE],
+[AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
+ dnl maintainer-mode is disabled by default
+ AC_ARG_ENABLE(maintainer-mode,
+[ --enable-maintainer-mode enable make rules and dependencies not useful
+ (and sometimes confusing) to the casual installer],
+ USE_MAINTAINER_MODE=$enableval,
+ USE_MAINTAINER_MODE=no)
+ AC_MSG_RESULT([$USE_MAINTAINER_MODE])
+ AM_CONDITIONAL(MAINTAINER_MODE, [test $USE_MAINTAINER_MODE = yes])
+ MAINT=$MAINTAINER_MODE_TRUE
+ AC_SUBST(MAINT)dnl
+]
+)
+
+AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE])
+
+# Check to see how 'make' treats includes. -*- Autoconf -*-
+
+# Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+
+# serial 2
+
+# AM_MAKE_INCLUDE()
+# -----------------
+# Check to see how make treats includes.
+AC_DEFUN([AM_MAKE_INCLUDE],
+[am_make=${MAKE-make}
+cat > confinc << 'END'
+am__doit:
+ @echo done
+.PHONY: am__doit
+END
+# If we don't find an include directive, just comment out the code.
+AC_MSG_CHECKING([for style of include used by $am_make])
+am__include="#"
+am__quote=
+_am_result=none
+# First try GNU make style include.
+echo "include confinc" > confmf
+# We grep out `Entering directory' and `Leaving directory'
+# messages which can occur if `w' ends up in MAKEFLAGS.
+# In particular we don't look at `^make:' because GNU make might
+# be invoked under some other name (usually "gmake"), in which
+# case it prints its new name instead of `make'.
+if test "`$am_make -s -f confmf 2> /dev/null | grep -v 'ing directory'`" = "done"; then
+ am__include=include
+ am__quote=
+ _am_result=GNU
+fi
+# Now try BSD make style include.
+if test "$am__include" = "#"; then
+ echo '.include "confinc"' > confmf
+ if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
+ am__include=.include
+ am__quote="\""
+ _am_result=BSD
+ fi
+fi
+AC_SUBST([am__include])
+AC_SUBST([am__quote])
+AC_MSG_RESULT([$_am_result])
+rm -f confinc confmf
+])
+
+# -*- Autoconf -*-
+
+
+# Copyright (C) 1997, 1999, 2000, 2001, 2003 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+
+# serial 3
+
+# AM_MISSING_PROG(NAME, PROGRAM)
+# ------------------------------
+AC_DEFUN([AM_MISSING_PROG],
+[AC_REQUIRE([AM_MISSING_HAS_RUN])
+$1=${$1-"${am_missing_run}$2"}
+AC_SUBST($1)])
+
+
+# AM_MISSING_HAS_RUN
+# ------------------
+# Define MISSING if not defined so far and test if it supports --run.
+# If it does, set am_missing_run to use it, otherwise, to nothing.
+AC_DEFUN([AM_MISSING_HAS_RUN],
+[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
+test x"${MISSING+set}" = xset || MISSING="\${SHELL} $am_aux_dir/missing"
+# Use eval to expand $SHELL
+if eval "$MISSING --run true"; then
+ am_missing_run="$MISSING --run "
+else
+ am_missing_run=
+ AC_MSG_WARN([`missing' script is too old or missing])
+fi
+])
+
+# AM_PROG_MKDIR_P
+# ---------------
+# Check whether `mkdir -p' is supported, fallback to mkinstalldirs otherwise.
+
+# Copyright (C) 2003, 2004 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+
+# Automake 1.8 used `mkdir -m 0755 -p --' to ensure that directories
+# created by `make install' are always world readable, even if the
+# installer happens to have an overly restrictive umask (e.g. 077).
+# This was a mistake. There are at least two reasons why we must not
+# use `-m 0755':
+# - it causes special bits like SGID to be ignored,
+# - it may be too restrictive (some setups expect 775 directories).
+#
+# Do not use -m 0755 and let people choose whatever they expect by
+# setting umask.
+#
+# We cannot accept any implementation of `mkdir' that recognizes `-p'.
+# Some implementations (such as Solaris 8's) are not thread-safe: if a
+# parallel make tries to run `mkdir -p a/b' and `mkdir -p a/c'
+# concurrently, both version can detect that a/ is missing, but only
+# one can create it and the other will error out. Consequently we
+# restrict ourselves to GNU make (using the --version option ensures
+# this.)
+AC_DEFUN([AM_PROG_MKDIR_P],
+[if mkdir -p --version . >/dev/null 2>&1 && test ! -d ./--version; then
+ # Keeping the `.' argument allows $(mkdir_p) to be used without
+ # argument. Indeed, we sometimes output rules like
+ # $(mkdir_p) $(somedir)
+ # where $(somedir) is conditionally defined.
+ # (`test -n '$(somedir)' && $(mkdir_p) $(somedir)' is a more
+ # expensive solution, as it forces Make to start a sub-shell.)
+ mkdir_p='mkdir -p -- .'
+else
+ # On NextStep and OpenStep, the `mkdir' command does not
+ # recognize any option. It will interpret all options as
+ # directories to create, and then abort because `.' already
+ # exists.
+ for d in ./-p ./--version;
+ do
+ test -d $d && rmdir $d
+ done
+ # $(mkinstalldirs) is defined by Automake if mkinstalldirs exists.
+ if test -f "$ac_aux_dir/mkinstalldirs"; then
+ mkdir_p='$(mkinstalldirs)'
+ else
+ mkdir_p='$(install_sh) -d'
+ fi
+fi
+AC_SUBST([mkdir_p])])
+
+# Helper functions for option handling. -*- Autoconf -*-
+
+# Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+
+# serial 2
+
+# _AM_MANGLE_OPTION(NAME)
+# -----------------------
+AC_DEFUN([_AM_MANGLE_OPTION],
+[[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])])
+
+# _AM_SET_OPTION(NAME)
+# ------------------------------
+# Set option NAME. Presently that only means defining a flag for this option.
+AC_DEFUN([_AM_SET_OPTION],
+[m4_define(_AM_MANGLE_OPTION([$1]), 1)])
+
+# _AM_SET_OPTIONS(OPTIONS)
+# ----------------------------------
+# OPTIONS is a space-separated list of Automake options.
+AC_DEFUN([_AM_SET_OPTIONS],
+[AC_FOREACH([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])])
+
+# _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET])
+# -------------------------------------------
+# Execute IF-SET if OPTION is set, IF-NOT-SET otherwise.
+AC_DEFUN([_AM_IF_OPTION],
+[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
#
# Check to make sure that the build environment is sane.
#
+# Copyright (C) 1996, 1997, 2000, 2001, 2003 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
+
+# serial 3
+
+# AM_SANITY_CHECK
+# ---------------
AC_DEFUN([AM_SANITY_CHECK],
[AC_MSG_CHECKING([whether build environment is sane])
# Just in case
sleep 1
-echo timestamp > conftestfile
+echo timestamp > conftest.file
# Do `set' in a subshell so we don't clobber the current shell's
# arguments. Must try -L first in case configure is actually a
# symlink; some systems play weird games with the mod time of symlinks
# (eg FreeBSD returns the mod time of the symlink's containing
# directory).
if (
- set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
- if test "[$]*" = "X"; then
+ set X `ls -Lt $srcdir/configure conftest.file 2> /dev/null`
+ if test "$[*]" = "X"; then
# -L didn't work.
- set X `ls -t $srcdir/configure conftestfile`
+ set X `ls -t $srcdir/configure conftest.file`
fi
- if test "[$]*" != "X $srcdir/configure conftestfile" \
- && test "[$]*" != "X conftestfile $srcdir/configure"; then
+ rm -f conftest.file
+ if test "$[*]" != "X $srcdir/configure conftest.file" \
+ && test "$[*]" != "X conftest.file $srcdir/configure"; then
# If neither matched, then we have a broken ls. This can happen
# if, for instance, CONFIG_SHELL is bash and it inherits a
@@ -147,7 +953,7 @@ if (
alias in your environment])
fi
- test "[$]2" = conftestfile
+ test "$[2]" = conftest.file
)
then
# Ok.
@@ -156,87 +962,45 @@ else
AC_MSG_ERROR([newly created file is older than distributed files!
Check your system clock])
fi
-rm -f conftest*
AC_MSG_RESULT(yes)])
-dnl AM_MISSING_PROG(NAME, PROGRAM, DIRECTORY)
-dnl The program must properly implement --version.
-AC_DEFUN([AM_MISSING_PROG],
-[AC_MSG_CHECKING(for working $2)
-# Run test in a subshell; some versions of sh will print an error if
-# an executable is not found, even if stderr is redirected.
-# Redirect stdin to placate older versions of autoconf. Sigh.
-if ($2 --version) < /dev/null > /dev/null 2>&1; then
- $1=$2
- AC_MSG_RESULT(found)
-else
- $1="$3/missing $2"
- AC_MSG_RESULT(missing)
-fi
-AC_SUBST($1)])
-
-# Like AC_CONFIG_HEADER, but automatically create stamp file.
-
-AC_DEFUN([AM_CONFIG_HEADER],
-[AC_PREREQ([2.12])
-AC_CONFIG_HEADER([$1])
-dnl When config.status generates a header, we must update the stamp-h file.
-dnl This file resides in the same directory as the config header
-dnl that is generated. We must strip everything past the first ":",
-dnl and everything past the last "/".
-AC_OUTPUT_COMMANDS(changequote(<<,>>)dnl
-ifelse(patsubst(<<$1>>, <<[^ ]>>, <<>>), <<>>,
-<<test -z "<<$>>CONFIG_HEADERS" || echo timestamp > patsubst(<<$1>>, <<^\([^:]*/\)?.*>>, <<\1>>)stamp-h<<>>dnl>>,
-<<am_indx=1
-for am_file in <<$1>>; do
- case " <<$>>CONFIG_HEADERS " in
- *" <<$>>am_file "*<<)>>
- echo timestamp > `echo <<$>>am_file | sed -e 's%:.*%%' -e 's%[^/]*$%%'`stamp-h$am_indx
- ;;
- esac
- am_indx=`expr "<<$>>am_indx" + 1`
-done<<>>dnl>>)
-changequote([,]))])
-
+# AM_PROG_INSTALL_STRIP
-dnl AM_PROG_LEX
-dnl Look for flex, lex or missing, then run AC_PROG_LEX and AC_DECL_YYTEXT
-AC_DEFUN([AM_PROG_LEX],
-[missing_dir=ifelse([$1],,`cd $ac_aux_dir && pwd`,$1)
-AC_CHECK_PROGS(LEX, flex lex, $missing_dir/missing flex)
-AC_PROG_LEX
-AC_DECL_YYTEXT])
-
-# Add --enable-maintainer-mode option to configure.
-# From Jim Meyering
+# Copyright (C) 2001, 2003 Free Software Foundation, Inc.
-# serial 1
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
-AC_DEFUN([AM_MAINTAINER_MODE],
-[AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
- dnl maintainer-mode is disabled by default
- AC_ARG_ENABLE(maintainer-mode,
-[ --enable-maintainer-mode enable make rules and dependencies not useful
- (and sometimes confusing) to the casual installer],
- USE_MAINTAINER_MODE=$enableval,
- USE_MAINTAINER_MODE=no)
- AC_MSG_RESULT($USE_MAINTAINER_MODE)
- AM_CONDITIONAL(MAINTAINER_MODE, test $USE_MAINTAINER_MODE = yes)
- MAINT=$MAINTAINER_MODE_TRUE
- AC_SUBST(MAINT)dnl
-]
-)
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
-# Define a conditional.
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+# 02111-1307, USA.
-AC_DEFUN([AM_CONDITIONAL],
-[AC_SUBST($1_TRUE)
-AC_SUBST($1_FALSE)
-if $2; then
- $1_TRUE=
- $1_FALSE='#'
-else
- $1_TRUE='#'
- $1_FALSE=
-fi])
+# One issue with vendor `install' (even GNU) is that you can't
+# specify the program used to strip binaries. This is especially
+# annoying in cross-compiling environments, where the build's strip
+# is unlikely to handle the host's binaries.
+# Fortunately install-sh will honor a STRIPPROG variable, so we
+# always use install-sh in `make install-strip', and initialize
+# STRIPPROG with the value of the STRIP variable (set by the user).
+AC_DEFUN([AM_PROG_INSTALL_STRIP],
+[AC_REQUIRE([AM_PROG_INSTALL_SH])dnl
+# Installed binaries are usually stripped using `strip' when the user
+# run `make install-strip'. However `strip' might not be the right
+# tool to use in cross-compilation environments, therefore Automake
+# will honor the `STRIP' environment variable to overrule this program.
+dnl Don't test for $cross_compiling = yes, because it might be `maybe'.
+if test "$cross_compiling" != no; then
+ AC_CHECK_TOOL([STRIP], [strip], :)
+fi
+INSTALL_STRIP_PROGRAM="\${SHELL} \$(install_sh) -c -s"
+AC_SUBST([INSTALL_STRIP_PROGRAM])])
+m4_include([acinclude.m4])
diff --git a/contrib/binutils/gas/app.c b/contrib/binutils/gas/app.c
index f9c5c7d..1dbc49a 100644
--- a/contrib/binutils/gas/app.c
+++ b/contrib/binutils/gas/app.c
@@ -1,6 +1,6 @@
/* This is the Assembler Pre-Processor
Copyright 1987, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
- 1999, 2000
+ 1999, 2000, 2002, 2003
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -20,14 +20,14 @@
Software Foundation, 59 Temple Place - Suite 330, Boston, MA
02111-1307, USA. */
-/* Modified by Allen Wirfs-Brock, Instantiations Inc 2/90 */
+/* Modified by Allen Wirfs-Brock, Instantiations Inc 2/90. */
/* App, the assembler pre-processor. This pre-processor strips out excess
spaces, turns single-quoted characters into a decimal constant, and turns
# <number> <filename> <garbage> into a .line <number>\n.file <filename>
pair. This needs better error-handling. */
#include <stdio.h>
-#include "as.h" /* For BAD_CASE() only */
+#include "as.h" /* For BAD_CASE() only. */
#if (__STDC__ != 1)
#ifndef const
@@ -87,15 +87,14 @@ static const char symbol_chars[] =
#define IS_LINE_COMMENT(c) (lex[c] == LEX_IS_LINE_COMMENT_START)
#define IS_NEWLINE(c) (lex[c] == LEX_IS_NEWLINE)
-static int process_escape PARAMS ((int));
+static int process_escape (int);
/* FIXME-soon: The entire lexer/parser thingy should be
built statically at compile time rather than dynamically
each and every time the assembler is run. xoxorich. */
void
-do_scrub_begin (m68k_mri)
- int m68k_mri ATTRIBUTE_UNUSED;
+do_scrub_begin (int m68k_mri ATTRIBUTE_UNUSED)
{
const char *p;
int c;
@@ -115,7 +114,7 @@ do_scrub_begin (m68k_mri)
lex['"'] = LEX_IS_STRINGQUOTE;
#if ! defined (TC_HPPA) && ! defined (TC_I370)
- /* I370 uses single-quotes to delimit integer, float constants */
+ /* I370 uses single-quotes to delimit integer, float constants. */
lex['\''] = LEX_IS_ONECHAR_QUOTE;
#endif
@@ -130,9 +129,7 @@ do_scrub_begin (m68k_mri)
/* Note that these override the previous defaults, e.g. if ';' is a
comment char, then it isn't a line separator. */
for (p = symbol_chars; *p; ++p)
- {
- lex[(unsigned char) *p] = LEX_IS_SYMBOL_COMPONENT;
- } /* declare symbol characters */
+ lex[(unsigned char) *p] = LEX_IS_SYMBOL_COMPONENT;
for (c = 128; c < 256; ++c)
lex[c] = LEX_IS_SYMBOL_COMPONENT;
@@ -152,35 +149,25 @@ do_scrub_begin (m68k_mri)
#define tc_comment_chars comment_chars
#endif
for (p = tc_comment_chars; *p; p++)
- {
- lex[(unsigned char) *p] = LEX_IS_COMMENT_START;
- } /* declare comment chars */
+ lex[(unsigned char) *p] = LEX_IS_COMMENT_START;
for (p = line_comment_chars; *p; p++)
- {
- lex[(unsigned char) *p] = LEX_IS_LINE_COMMENT_START;
- } /* declare line comment chars */
+ lex[(unsigned char) *p] = LEX_IS_LINE_COMMENT_START;
for (p = line_separator_chars; *p; p++)
- {
- lex[(unsigned char) *p] = LEX_IS_LINE_SEPARATOR;
- } /* declare line separators */
+ lex[(unsigned char) *p] = LEX_IS_LINE_SEPARATOR;
#ifdef tc_parallel_separator_chars
/* This macro permits the processor to specify all characters which
separate parallel insns on the same line. */
for (p = tc_parallel_separator_chars; *p; p++)
- {
- lex[(unsigned char) *p] = LEX_IS_PARALLEL_SEPARATOR;
- } /* declare parallel separators */
+ lex[(unsigned char) *p] = LEX_IS_PARALLEL_SEPARATOR;
#endif
/* Only allow slash-star comments if slash is not in use.
FIXME: This isn't right. We should always permit them. */
if (lex['/'] == 0)
- {
- lex['/'] = LEX_IS_TWOCHAR_COMMENT_1ST;
- }
+ lex['/'] = LEX_IS_TWOCHAR_COMMENT_1ST;
#ifdef TC_M68K
if (m68k_mri)
@@ -189,7 +176,7 @@ do_scrub_begin (m68k_mri)
lex[';'] = LEX_IS_COMMENT_START;
lex['*'] = LEX_IS_LINE_COMMENT_START;
/* The MRI documentation says '!' is LEX_IS_COMMENT_START, but
- then it can't be used in an expression. */
+ then it can't be used in an expression. */
lex['!'] = LEX_IS_LINE_COMMENT_START;
}
#endif
@@ -201,12 +188,12 @@ do_scrub_begin (m68k_mri)
lex['|'] = LEX_IS_DOUBLEBAR_1ST;
#endif
#ifdef TC_D30V
- /* must do this is we want VLIW instruction with "->" or "<-" */
+ /* Must do this is we want VLIW instruction with "->" or "<-". */
lex['-'] = LEX_IS_SYMBOL_COMPONENT;
#endif
-} /* do_scrub_begin() */
+}
-/* Saved state of the scrubber */
+/* Saved state of the scrubber. */
static int state;
static int old_state;
static char *out_string;
@@ -223,7 +210,8 @@ static char mri_last_ch;
state at the time .include is interpreted is completely unrelated.
That's why we have to save it all. */
-struct app_save {
+struct app_save
+{
int state;
int old_state;
char * out_string;
@@ -242,7 +230,7 @@ struct app_save {
};
char *
-app_push ()
+app_push (void)
{
register struct app_save *saved;
@@ -278,8 +266,7 @@ app_push ()
}
void
-app_pop (arg)
- char *arg;
+app_pop (char *arg)
{
register struct app_save *saved = (struct app_save *) arg;
@@ -309,13 +296,13 @@ app_pop (arg)
#endif
free (arg);
-} /* app_pop() */
+}
/* @@ This assumes that \n &c are the same on host and target. This is not
necessarily true. */
+
static int
-process_escape (ch)
- int ch;
+process_escape (int ch)
{
switch (ch)
{
@@ -350,10 +337,7 @@ process_escape (ch)
This is the way the old code used to work. */
int
-do_scrub_chars (get, tostart, tolen)
- int (*get) PARAMS ((char *, int));
- char *tostart;
- int tolen;
+do_scrub_chars (int (*get) (char *, int), char *tostart, int tolen)
{
char *to = tostart;
char *toend = tostart + tolen;
@@ -377,10 +361,18 @@ do_scrub_chars (get, tostart, tolen)
-1: output string in out_string and go to the state in old_state
-2: flush text until a '*' '/' is seen, then go to state old_state
#ifdef TC_V850
- 12: After seeing a dash, looking for a second dash as a start of comment.
+ 12: After seeing a dash, looking for a second dash as a start
+ of comment.
#endif
#ifdef DOUBLEBAR_PARALLEL
- 13: After seeing a vertical bar, looking for a second vertical bar as a parallel expression seperator.
+ 13: After seeing a vertical bar, looking for a second
+ vertical bar as a parallel expression separator.
+#endif
+#ifdef TC_IA64
+ 14: After seeing a `(' at state 0, looking for a `)' as
+ predicate.
+ 15: After seeing a `(' at state 1, looking for a `)' as
+ predicate.
#endif
*/
@@ -450,8 +442,8 @@ do_scrub_chars (get, tostart, tolen)
while (1)
{
/* The cases in this switch end with continue, in order to
- branch back to the top of this while loop and generate the
- next output character in the appropriate state. */
+ branch back to the top of this while loop and generate the
+ next output character in the appropriate state. */
switch (state)
{
case -1:
@@ -534,9 +526,9 @@ do_scrub_chars (get, tostart, tolen)
case 5:
/* We are going to copy everything up to a quote character,
- with special handling for a backslash. We try to
- optimize the copying in the simple case without using the
- GET and PUT macros. */
+ with special handling for a backslash. We try to
+ optimize the copying in the simple case without using the
+ GET and PUT macros. */
{
char *s;
int len;
@@ -545,7 +537,7 @@ do_scrub_chars (get, tostart, tolen)
{
ch = *s;
/* This condition must be changed if the type of any
- other character can be LEX_IS_STRINGQUOTE. */
+ other character can be LEX_IS_STRINGQUOTE. */
if (ch == '\\'
|| ch == '"'
|| ch == '\''
@@ -586,8 +578,7 @@ do_scrub_chars (get, tostart, tolen)
else if (scrub_m68k_mri && ch == '\n')
{
/* Just quietly terminate the string. This permits lines like
- bne label loop if we haven't reach end yet
- */
+ bne label loop if we haven't reach end yet. */
state = old_state;
UNGET (ch);
PUT ('\'');
@@ -611,6 +602,11 @@ do_scrub_chars (get, tostart, tolen)
PUT ('\\');
continue;
+ case EOF:
+ as_warn (_("end of file in string; '\"' inserted"));
+ PUT ('"');
+ continue;
+
case '"':
case '\\':
case 'b':
@@ -630,20 +626,12 @@ do_scrub_chars (get, tostart, tolen)
case '6':
case '7':
break;
-#if defined(IGNORE_NONSTANDARD_ESCAPES) | defined(ONLY_STANDARD_ESCAPES)
+
default:
+#ifdef ONLY_STANDARD_ESCAPES
as_warn (_("unknown escape '\\%c' in string; ignored"), ch);
+#endif
break;
-#else /* ONLY_STANDARD_ESCAPES */
- default:
- /* Accept \x as x for any x */
- break;
-#endif /* ONLY_STANDARD_ESCAPES */
-
- case EOF:
- as_warn (_("end of file in string; '\"' inserted"));
- PUT ('"');
- continue;
}
PUT (ch);
continue;
@@ -666,13 +654,49 @@ do_scrub_chars (get, tostart, tolen)
state = 0;
PUT (ch);
continue;
+
+#ifdef DOUBLEBAR_PARALLEL
+ case 13:
+ ch = GET ();
+ if (ch != '|')
+ abort ();
+
+ /* Reset back to state 1 and pretend that we are parsing a
+ line from just after the first white space. */
+ state = 1;
+ PUT ('|');
+ continue;
+#endif
}
- /* OK, we are somewhere in states 0 through 4 or 9 through 11 */
+ /* OK, we are somewhere in states 0 through 4 or 9 through 11. */
/* flushchar: */
ch = GET ();
+#ifdef TC_IA64
+ if (ch == '(' && (state == 0 || state == 1))
+ {
+ state += 14;
+ PUT (ch);
+ continue;
+ }
+ else if (state == 14 || state == 15)
+ {
+ if (ch == ')')
+ {
+ state -= 14;
+ PUT (ch);
+ ch = GET ();
+ }
+ else
+ {
+ PUT (ch);
+ continue;
+ }
+ }
+#endif
+
recycle:
#if defined TC_ARM && defined OBJ_ELF
@@ -706,9 +730,9 @@ do_scrub_chars (get, tostart, tolen)
#ifdef TC_M68K
/* We want to have pseudo-ops which control whether we are in
- MRI mode or not. Unfortunately, since m68k MRI mode affects
- the scrubber, that means that we need a special purpose
- recognizer here. */
+ MRI mode or not. Unfortunately, since m68k MRI mode affects
+ the scrubber, that means that we need a special purpose
+ recognizer here. */
if (mri_state == NULL)
{
if ((state == 0 || state == 1)
@@ -745,14 +769,14 @@ do_scrub_chars (get, tostart, tolen)
else
{
/* We've read the entire pseudo-op. mips_last_ch is
- either '0' or '1' indicating whether to enter or
- leave MRI mode. */
+ either '0' or '1' indicating whether to enter or
+ leave MRI mode. */
do_scrub_begin (mri_last_ch == '1');
mri_state = NULL;
/* We continue handling the character as usual. The
- main gas reader must also handle the .mri pseudo-op
- to control expression parsing and the like. */
+ main gas reader must also handle the .mri pseudo-op
+ to control expression parsing and the like. */
}
}
#endif
@@ -793,7 +817,7 @@ do_scrub_chars (get, tostart, tolen)
if (lex[ch] == LEX_IS_COLON)
{
/* Only keep this white if there's no white *after* the
- colon. */
+ colon. */
ch2 = GET ();
UNGET (ch2);
if (!IS_WHITESPACE (ch2))
@@ -881,9 +905,9 @@ do_scrub_chars (get, tostart, tolen)
else
{
/* We know that ch is not ':', since we tested that
- case above. Therefore this is not a label, so it
- must be the opcode, and we've just seen the
- whitespace after it. */
+ case above. Therefore this is not a label, so it
+ must be the opcode, and we've just seen the
+ whitespace after it. */
state = 3;
}
UNGET (ch);
@@ -915,7 +939,7 @@ do_scrub_chars (get, tostart, tolen)
break;
/* This UNGET will ensure that we count newlines
- correctly. */
+ correctly. */
UNGET (ch2);
}
@@ -953,13 +977,13 @@ do_scrub_chars (get, tostart, tolen)
case LEX_IS_STRINGQUOTE:
if (state == 10)
{
- /* Preserve the whitespace in foo "bar" */
+ /* Preserve the whitespace in foo "bar". */
UNGET (ch);
state = 3;
PUT (' ');
/* PUT didn't jump out. We could just break, but we
- know what will happen, so optimize a bit. */
+ know what will happen, so optimize a bit. */
ch = GET ();
old_state = 3;
}
@@ -975,7 +999,7 @@ do_scrub_chars (get, tostart, tolen)
case LEX_IS_ONECHAR_QUOTE:
if (state == 10)
{
- /* Preserve the whitespace in foo 'b' */
+ /* Preserve the whitespace in foo 'b'. */
UNGET (ch);
state = 3;
PUT (' ');
@@ -1070,10 +1094,10 @@ do_scrub_chars (get, tostart, tolen)
ch = GET ();
}
while (ch != EOF && ch != '\n');
+
if (ch == EOF)
- {
- as_warn (_("end of file in comment; newline inserted"));
- }
+ as_warn (_("end of file in comment; newline inserted"));
+
state = 0;
PUT ('\n');
break;
@@ -1081,15 +1105,14 @@ do_scrub_chars (get, tostart, tolen)
#ifdef DOUBLEBAR_PARALLEL
case LEX_IS_DOUBLEBAR_1ST:
ch2 = GET ();
+ UNGET (ch2);
if (ch2 != '|')
- {
- UNGET (ch2);
- goto de_fault;
- }
- /* Reset back to state 1 and pretend that we are parsing a line from
- just after the first white space. */
- state = 1;
- PUT ('|');
+ goto de_fault;
+
+ /* Handle '||' in two states as invoking PUT twice might
+ result in the first one jumping out of this loop. We'd
+ then lose track of the state and one '|' char. */
+ state = 13;
PUT ('|');
break;
#endif
@@ -1111,7 +1134,7 @@ do_scrub_chars (get, tostart, tolen)
{
UNGET (ch2);
}
- } /* bad hack */
+ }
if (state == 0 || state == 1) /* Only comment at start of line. */
{
@@ -1124,12 +1147,14 @@ do_scrub_chars (get, tostart, tolen)
ch = GET ();
}
while (ch != EOF && IS_WHITESPACE (ch));
+
if (ch == EOF)
{
as_warn (_("end of file in comment; newline inserted"));
PUT ('\n');
break;
}
+
if (ch < '0' || ch > '9' || state != 0 || startch != '#')
{
/* Not a cpp line. */
@@ -1222,7 +1247,7 @@ do_scrub_chars (get, tostart, tolen)
state = 9;
/* This is a common case. Quickly copy CH and all the
- following symbol component or normal characters. */
+ following symbol component or normal characters. */
if (to + 1 < toend
&& mri_state == NULL
#if defined TC_ARM && defined OBJ_ELF
@@ -1243,15 +1268,17 @@ do_scrub_chars (get, tostart, tolen)
&& type != LEX_IS_SYMBOL_COMPONENT)
break;
}
+
if (s > from)
- {
- /* Handle the last character normally, for
- simplicity. */
- --s;
- }
+ /* Handle the last character normally, for
+ simplicity. */
+ --s;
+
len = s - from;
+
if (len > (toend - to) - 1)
len = (toend - to) - 1;
+
if (len > 0)
{
PUT (ch);
@@ -1285,15 +1312,15 @@ do_scrub_chars (get, tostart, tolen)
/* Some relatively `normal' character. */
if (state == 0)
{
- state = 11; /* Now seeing label definition */
+ state = 11; /* Now seeing label definition. */
}
else if (state == 1)
{
- state = 2; /* Ditto */
+ state = 2; /* Ditto. */
}
else if (state == 9)
{
- if (lex[ch] != LEX_IS_SYMBOL_COMPONENT)
+ if (!IS_SYMBOL_COMPONENT (ch))
state = 3;
}
else if (state == 10)
@@ -1342,4 +1369,3 @@ do_scrub_chars (get, tostart, tolen)
return to - tostart;
}
-/* end of app.c */
diff --git a/contrib/binutils/gas/as.c b/contrib/binutils/gas/as.c
index 346ecc8..0911aa1 100644
--- a/contrib/binutils/gas/as.c
+++ b/contrib/binutils/gas/as.c
@@ -21,16 +21,15 @@
02111-1307, USA. */
/* Main program for AS; a 32-bit assembler of GNU.
- * Understands command arguments.
- * Has a few routines that don't fit in other modules because they
- * are shared.
- *
- * bugs
- *
- * : initialisers
- * Since no-one else says they will support them in future: I
- * don't support them now.
- */
+ Understands command arguments.
+ Has a few routines that don't fit in other modules because they
+ are shared.
+
+ bugs
+
+ : initialisers
+ Since no-one else says they will support them in future: I
+ don't support them now. */
#include "ansidecl.h"
@@ -42,6 +41,11 @@
#include "sb.h"
#include "macro.h"
#include "dwarf2dbg.h"
+#include "dw2gencfi.h"
+
+#ifdef BFD_ASSEMBLER
+#include "bfdver.h"
+#endif
#ifdef HAVE_ITBL_CPU
#include "itbl-ops.h"
@@ -56,31 +60,40 @@ extern PTR sbrk ();
#endif
#endif
-static void show_usage PARAMS ((FILE *));
-static void parse_args PARAMS ((int *, char ***));
-static void dump_statistics PARAMS ((void));
-static void perform_an_assembly_pass PARAMS ((int argc, char **argv));
-static int macro_expr PARAMS ((const char *, int, sb *, int *));
+#ifdef USING_CGEN
+/* Perform any cgen specific initialisation for gas. */
+extern void gas_cgen_begin (void);
+#endif
+
+/* Keep a record of the itbl files we read in. */
+struct itbl_file_list
+{
+ struct itbl_file_list *next;
+ char *name;
+};
+
+/* We build a list of defsyms as we read the options, and then define
+ them after we have initialized everything. */
+struct defsym_list
+{
+ struct defsym_list *next;
+ char *name;
+ valueT value;
+};
+
/* True if a listing is wanted. */
int listing;
-/* Name of listing file. */
-static char *listing_filename = NULL;
-
/* Type of debugging to generate. */
-
enum debug_info_type debug_type = DEBUG_UNSPECIFIED;
+int use_gnu_debug_info_extensions = 0;
/* Maximum level of macro nesting. */
int max_macro_nest = 100;
/* argv[0] */
-char *myname;
-#ifdef BFD_ASSEMBLER
-segT reg_section, expr_section;
-segT text_section, data_section, bss_section;
-#endif
+char * myname;
/* The default obstack chunk size. If we set this to zero, the
obstack code will use whatever will fit in a 4096 byte block. */
@@ -90,25 +103,26 @@ int chunksize = 0;
Then the chunk sizes for gas and bfd will be reduced. */
int debug_memory = 0;
-/* We build a list of defsyms as we read the options, and then define
- them after we have initialized everything. */
+/* Enable verbose mode. */
+int verbose = 0;
-struct defsym_list {
- struct defsym_list *next;
- char *name;
- valueT value;
-};
+#ifdef BFD_ASSEMBLER
+segT reg_section;
+segT expr_section;
+segT text_section;
+segT data_section;
+segT bss_section;
+#endif
+
+/* Name of listing file. */
+static char *listing_filename = NULL;
static struct defsym_list *defsyms;
-/* Keep a record of the itbl files we read in. */
+static struct itbl_file_list *itbl_files;
-struct itbl_file_list {
- struct itbl_file_list *next;
- char *name;
-};
+static long start_time;
-static struct itbl_file_list *itbl_files;
#ifdef USE_EMULATIONS
#define EMULATION_ENVIRON "AS_EMULATION"
@@ -121,12 +135,8 @@ extern struct emulation crisaout, criself;
static struct emulation *const emulations[] = { EMULATIONS };
static const int n_emulations = sizeof (emulations) / sizeof (emulations[0]);
-static void select_emulation_mode PARAMS ((int, char **));
-
static void
-select_emulation_mode (argc, argv)
- int argc;
- char **argv;
+select_emulation_mode (int argc, char **argv)
{
int i;
char *p, *em = 0;
@@ -170,14 +180,14 @@ select_emulation_mode (argc, argv)
}
const char *
-default_emul_bfd_name ()
+default_emul_bfd_name (void)
{
abort ();
return NULL;
}
void
-common_emul_init ()
+common_emul_init (void)
{
this_format = this_emulation->format;
@@ -199,9 +209,10 @@ common_emul_init ()
#endif
void
-print_version_id ()
+print_version_id (void)
{
static int printed;
+
if (printed)
return;
printed = 1;
@@ -216,8 +227,7 @@ print_version_id ()
}
static void
-show_usage (stream)
- FILE *stream;
+show_usage (FILE * stream)
{
fprintf (stream, _("Usage: %s [option...] [asmfile...]\n"), myname);
@@ -256,11 +266,19 @@ Options:\n\
emulate output (default %s)\n"), def_em);
}
#endif
+#if defined BFD_ASSEMBLER && (defined OBJ_ELF || defined OBJ_MAYBE_ELF)
+ fprintf (stream, _("\
+ --execstack require executable stack for this object\n"));
+ fprintf (stream, _("\
+ --noexecstack don't require executable stack for this object\n"));
+#endif
fprintf (stream, _("\
-f skip whitespace and comment preprocessing\n"));
fprintf (stream, _("\
--gstabs generate stabs debugging information\n"));
fprintf (stream, _("\
+ --gstabs+ generate stabs debug info with GNU extensions\n"));
+ fprintf (stream, _("\
--gdwarf2 generate DWARF2 debugging information\n"));
fprintf (stream, _("\
--help show this message and exit\n"));
@@ -337,60 +355,84 @@ Options:\n\
md_parse_option definitions in config/tc-*.c. */
static void
-parse_args (pargc, pargv)
- int *pargc;
- char ***pargv;
+parse_args (int * pargc, char *** pargv)
{
- int old_argc, new_argc;
- char **old_argv, **new_argv;
-
+ int old_argc;
+ int new_argc;
+ char ** old_argv;
+ char ** new_argv;
/* Starting the short option string with '-' is for programs that
expect options and other ARGV-elements in any order and that care about
the ordering of the two. We describe each non-option ARGV-element
as if it were the argument of an option with character code 1. */
-
char *shortopts;
extern const char *md_shortopts;
- static const char std_shortopts[] = {
+ static const char std_shortopts[] =
+ {
'-', 'J',
#ifndef WORKING_DOT_WORD
/* -K is not meaningful if .word is not being hacked. */
'K',
#endif
- 'L', 'M', 'R', 'W', 'Z', 'f', 'a', ':', ':', 'D', 'I', ':', 'o', ':',
+ 'L', 'M', 'R', 'W', 'Z', 'a', ':', ':', 'D', 'f', 'I', ':', 'o', ':',
#ifndef VMS
/* -v takes an argument on VMS, so we don't make it a generic
option. */
'v',
#endif
'w', 'X',
- /* New option for extending instruction set (see also --itbl below) */
+ /* New option for extending instruction set (see also --itbl below). */
't', ':',
'\0'
};
struct option *longopts;
extern struct option md_longopts[];
extern size_t md_longopts_size;
- static const struct option std_longopts[] = {
-#define OPTION_HELP (OPTION_STD_BASE)
+ /* Codes used for the long options with no short synonyms. */
+ enum option_values
+ {
+ OPTION_HELP = OPTION_STD_BASE,
+ OPTION_NOCPP,
+ OPTION_STATISTICS,
+ OPTION_VERSION,
+ OPTION_DUMPCONFIG,
+ OPTION_VERBOSE,
+ OPTION_EMULATION,
+ OPTION_DEFSYM,
+ OPTION_INSTTBL,
+ OPTION_LISTING_LHS_WIDTH,
+ OPTION_LISTING_LHS_WIDTH2,
+ OPTION_LISTING_RHS_WIDTH,
+ OPTION_LISTING_CONT_LINES,
+ OPTION_DEPFILE,
+ OPTION_GSTABS,
+ OPTION_GSTABS_PLUS,
+ OPTION_STRIP_LOCAL_ABSOLUTE,
+ OPTION_TRADITIONAL_FORMAT,
+ OPTION_GDWARF2,
+ OPTION_WARN,
+ OPTION_TARGET_HELP,
+ OPTION_EXECSTACK,
+ OPTION_NOEXECSTACK,
+ OPTION_WARN_FATAL
+ };
+
+ static const struct option std_longopts[] =
+ {
{"help", no_argument, NULL, OPTION_HELP},
+ /* getopt allows abbreviations, so we do this to stop it from
+ treating -k as an abbreviation for --keep-locals. Some
+ ports use -k to enable PIC assembly. */
+ {"keep-locals", no_argument, NULL, 'L'},
{"keep-locals", no_argument, NULL, 'L'},
{"mri", no_argument, NULL, 'M'},
-#define OPTION_NOCPP (OPTION_STD_BASE + 1)
{"nocpp", no_argument, NULL, OPTION_NOCPP},
-#define OPTION_STATISTICS (OPTION_STD_BASE + 2)
{"statistics", no_argument, NULL, OPTION_STATISTICS},
-#define OPTION_VERSION (OPTION_STD_BASE + 3)
{"version", no_argument, NULL, OPTION_VERSION},
-#define OPTION_DUMPCONFIG (OPTION_STD_BASE + 4)
{"dump-config", no_argument, NULL, OPTION_DUMPCONFIG},
-#define OPTION_VERBOSE (OPTION_STD_BASE + 5)
{"verbose", no_argument, NULL, OPTION_VERBOSE},
-#define OPTION_EMULATION (OPTION_STD_BASE + 6)
{"emulation", required_argument, NULL, OPTION_EMULATION},
-#define OPTION_DEFSYM (OPTION_STD_BASE + 7)
{"defsym", required_argument, NULL, OPTION_DEFSYM},
-#define OPTION_INSTTBL (OPTION_STD_BASE + 8)
/* New option for extending instruction set (see also -t above).
The "-t file" or "--itbl file" option extends the basic set of
valid instructions by reading "file", a text file containing a
@@ -398,30 +440,23 @@ parse_args (pargc, pargv)
formats are added to the built-in set of instructions, and
mnemonics for new registers may also be defined. */
{"itbl", required_argument, NULL, OPTION_INSTTBL},
-#define OPTION_LISTING_LHS_WIDTH (OPTION_STD_BASE + 9)
{"listing-lhs-width", required_argument, NULL, OPTION_LISTING_LHS_WIDTH},
-#define OPTION_LISTING_LHS_WIDTH2 (OPTION_STD_BASE + 10)
{"listing-lhs-width2", required_argument, NULL, OPTION_LISTING_LHS_WIDTH2},
-#define OPTION_LISTING_RHS_WIDTH (OPTION_STD_BASE + 11)
{"listing-rhs-width", required_argument, NULL, OPTION_LISTING_RHS_WIDTH},
-#define OPTION_LISTING_CONT_LINES (OPTION_STD_BASE + 12)
{"listing-cont-lines", required_argument, NULL, OPTION_LISTING_CONT_LINES},
-#define OPTION_DEPFILE (OPTION_STD_BASE + 13)
{"MD", required_argument, NULL, OPTION_DEPFILE},
-#define OPTION_GSTABS (OPTION_STD_BASE + 14)
{"gstabs", no_argument, NULL, OPTION_GSTABS},
-#define OPTION_STRIP_LOCAL_ABSOLUTE (OPTION_STD_BASE + 15)
+ {"gstabs+", no_argument, NULL, OPTION_GSTABS_PLUS},
{"strip-local-absolute", no_argument, NULL, OPTION_STRIP_LOCAL_ABSOLUTE},
-#define OPTION_TRADITIONAL_FORMAT (OPTION_STD_BASE + 16)
{"traditional-format", no_argument, NULL, OPTION_TRADITIONAL_FORMAT},
-#define OPTION_GDWARF2 (OPTION_STD_BASE + 17)
{"gdwarf2", no_argument, NULL, OPTION_GDWARF2},
{"no-warn", no_argument, NULL, 'W'},
-#define OPTION_WARN (OPTION_STD_BASE + 18)
{"warn", no_argument, NULL, OPTION_WARN},
-#define OPTION_TARGET_HELP (OPTION_STD_BASE + 19)
{"target-help", no_argument, NULL, OPTION_TARGET_HELP},
-#define OPTION_WARN_FATAL (OPTION_STD_BASE + 20)
+#if defined BFD_ASSEMBLER && (defined OBJ_ELF || defined OBJ_MAYBE_ELF)
+ {"execstack", no_argument, NULL, OPTION_EXECSTACK},
+ {"noexecstack", no_argument, NULL, OPTION_NOEXECSTACK},
+#endif
{"fatal-warnings", no_argument, NULL, OPTION_WARN_FATAL}
/* When you add options here, check that they do not collide with
OPTION_MD_BASE. See as.h. */
@@ -431,13 +466,10 @@ parse_args (pargc, pargv)
dependent list. Include space for an extra NULL option and
always NULL terminate. */
shortopts = concat (std_shortopts, md_shortopts, (char *) NULL);
- longopts = (struct option *) xmalloc (sizeof (std_longopts)
- + md_longopts_size
- + sizeof (struct option));
+ longopts = xmalloc (sizeof (std_longopts) + md_longopts_size + sizeof (struct option));
memcpy (longopts, std_longopts, sizeof (std_longopts));
- memcpy ((char *) longopts + sizeof (std_longopts),
- md_longopts, md_longopts_size);
- memset ((char *) longopts + sizeof (std_longopts) + md_longopts_size,
+ memcpy (((char *) longopts) + sizeof (std_longopts), md_longopts, md_longopts_size);
+ memset (((char *) longopts) + sizeof (std_longopts) + md_longopts_size,
0, sizeof (struct option));
/* Make a local copy of the old argv. */
@@ -445,7 +477,7 @@ parse_args (pargc, pargv)
old_argv = *pargv;
/* Initialize a new argv that contains no options. */
- new_argv = (char **) xmalloc (sizeof (char *) * (old_argc + 1));
+ new_argv = xmalloc (sizeof (char *) * (old_argc + 1));
new_argv[0] = old_argv[0];
new_argc = 1;
new_argv[new_argc] = NULL;
@@ -469,7 +501,7 @@ parse_args (pargc, pargv)
if (md_parse_option (optc, optarg) != 0)
break;
/* `-v' isn't included in the general short_opts list, so check for
- it explicity here before deciding we've gotten a bad argument. */
+ it explicitly here before deciding we've gotten a bad argument. */
if (optc == 'v')
{
#ifdef VMS
@@ -485,6 +517,7 @@ parse_args (pargc, pargv)
#endif
case OPTION_VERBOSE:
print_version_id ();
+ verbose = 1;
break;
}
/* Fall through. */
@@ -574,7 +607,7 @@ the GNU General Public License. This program has absolutely no warranty.\n"));
#else
i = strtol (s, (char **) NULL, 0);
#endif
- n = (struct defsym_list *) xmalloc (sizeof *n);
+ n = xmalloc (sizeof *n);
n->next = defsyms;
n->name = optarg;
n->value = i;
@@ -595,7 +628,7 @@ the GNU General Public License. This program has absolutely no warranty.\n"));
break;
}
- n = (struct itbl_file_list *) xmalloc (sizeof *n);
+ n = xmalloc (sizeof * n);
n->next = itbl_files;
n->name = optarg;
itbl_files = n;
@@ -615,6 +648,9 @@ the GNU General Public License. This program has absolutely no warranty.\n"));
start_dependencies (optarg);
break;
+ case OPTION_GSTABS_PLUS:
+ use_gnu_debug_info_extensions = 1;
+ /* Fall through. */
case OPTION_GSTABS:
debug_type = DEBUG_STABS;
break;
@@ -632,7 +668,6 @@ the GNU General Public License. This program has absolutely no warranty.\n"));
flag_warn_displacement = 1;
break;
#endif
-
case 'L':
flag_keep_locals = 1;
break;
@@ -681,6 +716,17 @@ the GNU General Public License. This program has absolutely no warranty.\n"));
flag_fatal_warnings = 1;
break;
+#if defined BFD_ASSEMBLER && (defined OBJ_ELF || defined OBJ_MAYBE_ELF)
+ case OPTION_EXECSTACK:
+ flag_execstack = 1;
+ flag_noexecstack = 0;
+ break;
+
+ case OPTION_NOEXECSTACK:
+ flag_noexecstack = 1;
+ flag_execstack = 0;
+ break;
+#endif
case 'Z':
flag_always_generate_output = 1;
break;
@@ -772,14 +818,168 @@ the GNU General Public License. This program has absolutely no warranty.\n"));
#endif
}
-static long start_time;
+static void
+dump_statistics (void)
+{
+#ifdef HAVE_SBRK
+ char *lim = (char *) sbrk (0);
+#endif
+ long run_time = get_run_time () - start_time;
+
+ fprintf (stderr, _("%s: total time in assembly: %ld.%06ld\n"),
+ myname, run_time / 1000000, run_time % 1000000);
+#ifdef HAVE_SBRK
+ fprintf (stderr, _("%s: data size %ld\n"),
+ myname, (long) (lim - (char *) &environ));
+#endif
+
+ subsegs_print_statistics (stderr);
+ write_print_statistics (stderr);
+ symbol_print_statistics (stderr);
+ read_print_statistics (stderr);
+
+#ifdef tc_print_statistics
+ tc_print_statistics (stderr);
+#endif
+
+#ifdef obj_print_statistics
+ obj_print_statistics (stderr);
+#endif
+}
+
+/* The interface between the macro code and gas expression handling. */
+
+static int
+macro_expr (const char *emsg, int idx, sb *in, int *val)
+{
+ char *hold;
+ expressionS ex;
+
+ sb_terminate (in);
+
+ hold = input_line_pointer;
+ input_line_pointer = in->ptr + idx;
+ expression (&ex);
+ idx = input_line_pointer - in->ptr;
+ input_line_pointer = hold;
+
+ if (ex.X_op != O_constant)
+ as_bad ("%s", emsg);
+
+ *val = (int) ex.X_add_number;
+
+ return idx;
+}
+
+/* Here to attempt 1 pass over each input file.
+ We scan argv[*] looking for filenames or exactly "" which is
+ shorthand for stdin. Any argv that is NULL is not a file-name.
+ We set need_pass_2 TRUE if, after this, we still have unresolved
+ expressions of the form (unknown value)+-(unknown value).
+
+ Note the un*x semantics: there is only 1 logical input file, but it
+ may be a catenation of many 'physical' input files. */
+
+static void
+perform_an_assembly_pass (int argc, char ** argv)
+{
+ int saw_a_file = 0;
+#ifdef BFD_ASSEMBLER
+ flagword applicable;
+#endif
+
+ need_pass_2 = 0;
+
+#ifndef BFD_ASSEMBLER
+#ifdef MANY_SEGMENTS
+ {
+ unsigned int i;
+ for (i = SEG_E0; i < SEG_UNKNOWN; i++)
+ segment_info[i].fix_root = 0;
+ }
+ /* Create the three fixed ones. */
+ {
+ segT seg;
+
+#ifdef TE_APOLLO
+ seg = subseg_new (".wtext", 0);
+#else
+ seg = subseg_new (".text", 0);
+#endif
+ assert (seg == SEG_E0);
+ seg = subseg_new (".data", 0);
+ assert (seg == SEG_E1);
+ seg = subseg_new (".bss", 0);
+ assert (seg == SEG_E2);
+#ifdef TE_APOLLO
+ create_target_segments ();
+#endif
+ }
+
+#else /* not MANY_SEGMENTS. */
+ text_fix_root = NULL;
+ data_fix_root = NULL;
+ bss_fix_root = NULL;
+#endif /* not MANY_SEGMENTS. */
+#else /* BFD_ASSEMBLER. */
+ /* Create the standard sections, and those the assembler uses
+ internally. */
+ text_section = subseg_new (TEXT_SECTION_NAME, 0);
+ data_section = subseg_new (DATA_SECTION_NAME, 0);
+ bss_section = subseg_new (BSS_SECTION_NAME, 0);
+ /* @@ FIXME -- we're setting the RELOC flag so that sections are assumed
+ to have relocs, otherwise we don't find out in time. */
+ applicable = bfd_applicable_section_flags (stdoutput);
+ bfd_set_section_flags (stdoutput, text_section,
+ applicable & (SEC_ALLOC | SEC_LOAD | SEC_RELOC
+ | SEC_CODE | SEC_READONLY));
+ bfd_set_section_flags (stdoutput, data_section,
+ applicable & (SEC_ALLOC | SEC_LOAD | SEC_RELOC
+ | SEC_DATA));
+ bfd_set_section_flags (stdoutput, bss_section, applicable & SEC_ALLOC);
+ seg_info (bss_section)->bss = 1;
+ subseg_new (BFD_ABS_SECTION_NAME, 0);
+ subseg_new (BFD_UND_SECTION_NAME, 0);
+ reg_section = subseg_new ("*GAS `reg' section*", 0);
+ expr_section = subseg_new ("*GAS `expr' section*", 0);
-int main PARAMS ((int, char **));
+#endif /* BFD_ASSEMBLER. */
+
+ subseg_set (text_section, 0);
+
+ /* This may add symbol table entries, which requires having an open BFD,
+ and sections already created, in BFD_ASSEMBLER mode. */
+ md_begin ();
+
+#ifdef USING_CGEN
+ gas_cgen_begin ();
+#endif
+#ifdef obj_begin
+ obj_begin ();
+#endif
+
+ /* Skip argv[0]. */
+ argv++;
+ argc--;
+
+ while (argc--)
+ {
+ if (*argv)
+ { /* Is it a file-name argument? */
+ PROGRESS (1);
+ saw_a_file++;
+ /* argv->"" if stdin desired, else->filename. */
+ read_a_source_file (*argv);
+ }
+ argv++; /* Completed that argv. */
+ }
+ if (!saw_a_file)
+ read_a_source_file ("");
+}
+
int
-main (argc, argv)
- int argc;
- char **argv;
+main (int argc, char ** argv)
{
int macro_alternate;
int macro_strip_at;
@@ -890,10 +1090,27 @@ main (argc, argv)
md_end ();
#endif
+#if defined BFD_ASSEMBLER && (defined OBJ_ELF || defined OBJ_MAYBE_ELF)
+ if ((flag_execstack || flag_noexecstack)
+ && OUTPUT_FLAVOR == bfd_target_elf_flavour)
+ {
+ segT gnustack;
+
+ gnustack = subseg_new (".note.GNU-stack", 0);
+ bfd_set_section_flags (stdoutput, gnustack,
+ SEC_READONLY | (flag_execstack ? SEC_CODE : 0));
+
+ }
+#endif
+
/* If we've been collecting dwarf2 .debug_line info, either for
assembly debugging or on behalf of the compiler, emit it now. */
dwarf2_finish ();
+ /* If we constructed dwarf2 .eh_frame info, either via .cfi
+ directives from the user or by the backend, emit it now. */
+ cfi_finish ();
+
if (seen_at_least_1_file ()
&& (flag_always_generate_output || had_errors () == 0))
keep_it = 1;
@@ -915,7 +1132,7 @@ main (argc, argv)
listing_print (listing_filename);
#endif
-#ifndef OBJ_VMS /* does its own file handling */
+#ifndef OBJ_VMS /* Does its own file handling. */
#ifndef BFD_ASSEMBLER
if (keep_it)
#endif
@@ -946,163 +1163,3 @@ main (argc, argv)
xexit (EXIT_SUCCESS);
}
-static void
-dump_statistics ()
-{
-#ifdef HAVE_SBRK
- char *lim = (char *) sbrk (0);
-#endif
- long run_time = get_run_time () - start_time;
-
- fprintf (stderr, _("%s: total time in assembly: %ld.%06ld\n"),
- myname, run_time / 1000000, run_time % 1000000);
-#ifdef HAVE_SBRK
- fprintf (stderr, _("%s: data size %ld\n"),
- myname, (long) (lim - (char *) &environ));
-#endif
-
- subsegs_print_statistics (stderr);
- write_print_statistics (stderr);
- symbol_print_statistics (stderr);
- read_print_statistics (stderr);
-
-#ifdef tc_print_statistics
- tc_print_statistics (stderr);
-#endif
-#ifdef obj_print_statistics
- obj_print_statistics (stderr);
-#endif
-}
-
-/* Here to attempt 1 pass over each input file.
- We scan argv[*] looking for filenames or exactly "" which is
- shorthand for stdin. Any argv that is NULL is not a file-name.
- We set need_pass_2 TRUE if, after this, we still have unresolved
- expressions of the form (unknown value)+-(unknown value).
-
- Note the un*x semantics: there is only 1 logical input file, but it
- may be a catenation of many 'physical' input files. */
-
-static void
-perform_an_assembly_pass (argc, argv)
- int argc;
- char **argv;
-{
- int saw_a_file = 0;
-#ifdef BFD_ASSEMBLER
- flagword applicable;
-#endif
-
- need_pass_2 = 0;
-
-#ifndef BFD_ASSEMBLER
-#ifdef MANY_SEGMENTS
- {
- unsigned int i;
- for (i = SEG_E0; i < SEG_UNKNOWN; i++)
- segment_info[i].fix_root = 0;
- }
- /* Create the three fixed ones. */
- {
- segT seg;
-
-#ifdef TE_APOLLO
- seg = subseg_new (".wtext", 0);
-#else
- seg = subseg_new (".text", 0);
-#endif
- assert (seg == SEG_E0);
- seg = subseg_new (".data", 0);
- assert (seg == SEG_E1);
- seg = subseg_new (".bss", 0);
- assert (seg == SEG_E2);
-#ifdef TE_APOLLO
- create_target_segments ();
-#endif
- }
-
-#else /* not MANY_SEGMENTS */
- text_fix_root = NULL;
- data_fix_root = NULL;
- bss_fix_root = NULL;
-#endif /* not MANY_SEGMENTS */
-#else /* BFD_ASSEMBLER */
- /* Create the standard sections, and those the assembler uses
- internally. */
- text_section = subseg_new (TEXT_SECTION_NAME, 0);
- data_section = subseg_new (DATA_SECTION_NAME, 0);
- bss_section = subseg_new (BSS_SECTION_NAME, 0);
- /* @@ FIXME -- we're setting the RELOC flag so that sections are assumed
- to have relocs, otherwise we don't find out in time. */
- applicable = bfd_applicable_section_flags (stdoutput);
- bfd_set_section_flags (stdoutput, text_section,
- applicable & (SEC_ALLOC | SEC_LOAD | SEC_RELOC
- | SEC_CODE | SEC_READONLY));
- bfd_set_section_flags (stdoutput, data_section,
- applicable & (SEC_ALLOC | SEC_LOAD | SEC_RELOC
- | SEC_DATA));
- bfd_set_section_flags (stdoutput, bss_section, applicable & SEC_ALLOC);
- seg_info (bss_section)->bss = 1;
- subseg_new (BFD_ABS_SECTION_NAME, 0);
- subseg_new (BFD_UND_SECTION_NAME, 0);
- reg_section = subseg_new ("*GAS `reg' section*", 0);
- expr_section = subseg_new ("*GAS `expr' section*", 0);
-
-#endif /* BFD_ASSEMBLER */
-
- subseg_set (text_section, 0);
-
- /* This may add symbol table entries, which requires having an open BFD,
- and sections already created, in BFD_ASSEMBLER mode. */
- md_begin ();
-
-#ifdef obj_begin
- obj_begin ();
-#endif
-
- /* Skip argv[0]. */
- argv++;
- argc--;
-
- while (argc--)
- {
- if (*argv)
- { /* Is it a file-name argument? */
- PROGRESS (1);
- saw_a_file++;
- /* argv->"" if stdin desired, else->filename */
- read_a_source_file (*argv);
- }
- argv++; /* completed that argv */
- }
- if (!saw_a_file)
- read_a_source_file ("");
-}
-
-/* The interface between the macro code and gas expression handling. */
-
-static int
-macro_expr (emsg, idx, in, val)
- const char *emsg;
- int idx;
- sb *in;
- int *val;
-{
- char *hold;
- expressionS ex;
-
- sb_terminate (in);
-
- hold = input_line_pointer;
- input_line_pointer = in->ptr + idx;
- expression (&ex);
- idx = input_line_pointer - in->ptr;
- input_line_pointer = hold;
-
- if (ex.X_op != O_constant)
- as_bad ("%s", emsg);
-
- *val = (int) ex.X_add_number;
-
- return idx;
-}
diff --git a/contrib/binutils/gas/as.h b/contrib/binutils/gas/as.h
index ff434cb..890ecd8 100644
--- a/contrib/binutils/gas/as.h
+++ b/contrib/binutils/gas/as.h
@@ -1,6 +1,6 @@
/* as.h - global header file
Copyright 1987, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
- 1999, 2000, 2001, 2002
+ 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -188,7 +188,7 @@ extern char **environ;
#endif /* __FILE__ */
#ifndef FOPEN_WB
-#ifdef GO32
+#if defined GO32 || defined __MINGW32__
#include "fopen-bin.h"
#else
#include "fopen-same.h"
@@ -237,7 +237,7 @@ typedef addressT valueT;
#ifdef TEST
#define COMMON /* declare our COMMONs storage here. */
#else
-#define COMMON extern /* our commons live elswhere */
+#define COMMON extern /* our commons live elsewhere */
#endif
#endif
/* COMMON now defined */
@@ -301,7 +301,7 @@ typedef asection *segT;
#endif
typedef int subsegT;
-/* What subseg we are accreting now? */
+/* What subseg we are accessing now? */
COMMON subsegT now_subseg;
/* Segment our instructions emit to. */
@@ -436,6 +436,12 @@ COMMON int flag_strip_local_absolute;
/* True if we should generate a traditional format object file. */
COMMON int flag_traditional_format;
+/* TRUE if .note.GNU-stack section with SEC_CODE should be created */
+COMMON int flag_execstack;
+
+/* TRUE if .note.GNU-stack section with SEC_CODE should be created */
+COMMON int flag_noexecstack;
+
/* name of emitted object file */
COMMON char *out_file_name;
@@ -470,10 +476,14 @@ enum debug_info_type {
};
extern enum debug_info_type debug_type;
+extern int use_gnu_debug_info_extensions;
/* Maximum level of macro nesting. */
extern int max_macro_nest;
+/* Verbosity level. */
+extern int verbose;
+
/* Obstack chunk size. Keep large for efficient space use, make small to
increase malloc calls for monitoring memory allocation. */
extern int chunksize;
@@ -482,7 +492,7 @@ struct _pseudo_type {
/* assembler mnemonic, lower case, no '.' */
const char *poc_name;
/* Do the work */
- void (*poc_handler) PARAMS ((int));
+ void (*poc_handler) (int);
/* Value to pass to handler */
int poc_val;
};
@@ -522,10 +532,10 @@ typedef struct _pseudo_type pseudo_typeS;
#else /* __GNUC__ < 2 || defined(VMS) */
-#define PRINTF_LIKE(FCN) void FCN PARAMS ((const char *format, ...))
-#define PRINTF_WHERE_LIKE(FCN) void FCN PARAMS ((char *file, \
- unsigned int line, \
- const char *format, ...))
+#define PRINTF_LIKE(FCN) void FCN (const char *format, ...)
+#define PRINTF_WHERE_LIKE(FCN) void FCN (char *file, \
+ unsigned int line, \
+ const char *format, ...)
#endif /* __GNUC__ < 2 || defined(VMS) */
@@ -543,54 +553,54 @@ PRINTF_LIKE (as_warn);
PRINTF_WHERE_LIKE (as_bad_where);
PRINTF_WHERE_LIKE (as_warn_where);
-void as_assert PARAMS ((const char *, int, const char *));
-void as_abort PARAMS ((const char *, int, const char *)) ATTRIBUTE_NORETURN;
-
-void fprint_value PARAMS ((FILE *file, addressT value));
-void sprint_value PARAMS ((char *buf, addressT value));
-
-int had_errors PARAMS ((void));
-int had_warnings PARAMS ((void));
-
-void print_version_id PARAMS ((void));
-char *app_push PARAMS ((void));
-char *atof_ieee PARAMS ((char *str, int what_kind, LITTLENUM_TYPE * words));
-char *input_scrub_include_file PARAMS ((char *filename, char *position));
-extern void input_scrub_insert_line PARAMS((const char *line));
-extern void input_scrub_insert_file PARAMS((char *path));
-char *input_scrub_new_file PARAMS ((char *filename));
-char *input_scrub_next_buffer PARAMS ((char **bufp));
-int do_scrub_chars PARAMS ((int (*get) (char *, int), char *to, int tolen));
-int gen_to_words PARAMS ((LITTLENUM_TYPE * words, int precision,
- long exponent_bits));
-int had_err PARAMS ((void));
-int ignore_input PARAMS ((void));
-void cond_finish_check PARAMS ((int));
-void cond_exit_macro PARAMS ((int));
-int seen_at_least_1_file PARAMS ((void));
-void app_pop PARAMS ((char *arg));
-void as_howmuch PARAMS ((FILE * stream));
-void as_perror PARAMS ((const char *gripe, const char *filename));
-void as_where PARAMS ((char **namep, unsigned int *linep));
-void bump_line_counters PARAMS ((void));
-void do_scrub_begin PARAMS ((int));
-void input_scrub_begin PARAMS ((void));
-void input_scrub_close PARAMS ((void));
-void input_scrub_end PARAMS ((void));
-int new_logical_line PARAMS ((char *fname, int line_number));
-void subsegs_begin PARAMS ((void));
-void subseg_change PARAMS ((segT seg, int subseg));
-segT subseg_new PARAMS ((const char *name, subsegT subseg));
-segT subseg_force_new PARAMS ((const char *name, subsegT subseg));
-void subseg_set PARAMS ((segT seg, subsegT subseg));
+void as_assert (const char *, int, const char *);
+void as_abort (const char *, int, const char *) ATTRIBUTE_NORETURN;
+
+void fprint_value (FILE *file, addressT value);
+void sprint_value (char *buf, addressT value);
+
+int had_errors (void);
+int had_warnings (void);
+
+void print_version_id (void);
+char *app_push (void);
+char *atof_ieee (char *str, int what_kind, LITTLENUM_TYPE * words);
+char *input_scrub_include_file (char *filename, char *position);
+extern void input_scrub_insert_line (const char *line);
+extern void input_scrub_insert_file (char *path);
+char *input_scrub_new_file (char *filename);
+char *input_scrub_next_buffer (char **bufp);
+int do_scrub_chars (int (*get) (char *, int), char *to, int tolen);
+int gen_to_words (LITTLENUM_TYPE * words, int precision,
+ long exponent_bits);
+int had_err (void);
+int ignore_input (void);
+void cond_finish_check (int);
+void cond_exit_macro (int);
+int seen_at_least_1_file (void);
+void app_pop (char *arg);
+void as_howmuch (FILE * stream);
+void as_perror (const char *gripe, const char *filename);
+void as_where (char **namep, unsigned int *linep);
+void bump_line_counters (void);
+void do_scrub_begin (int);
+void input_scrub_begin (void);
+void input_scrub_close (void);
+void input_scrub_end (void);
+int new_logical_line (char *fname, int line_number);
+void subsegs_begin (void);
+void subseg_change (segT seg, int subseg);
+segT subseg_new (const char *name, subsegT subseg);
+segT subseg_force_new (const char *name, subsegT subseg);
+void subseg_set (segT seg, subsegT subseg);
#ifdef BFD_ASSEMBLER
-segT subseg_get PARAMS ((const char *, int));
+segT subseg_get (const char *, int);
#endif
-int subseg_text_p PARAMS ((segT));
+int subseg_text_p (segT);
-void start_dependencies PARAMS ((char *));
-void register_dependency PARAMS ((char *));
-void print_dependencies PARAMS ((void));
+void start_dependencies (char *);
+void register_dependency (char *);
+void print_dependencies (void);
struct expressionS;
struct fix;
@@ -600,21 +610,29 @@ typedef struct frag fragS;
#ifdef BFD_ASSEMBLER
/* literal.c */
-valueT add_to_literal_pool PARAMS ((symbolS *, valueT, segT, int));
+valueT add_to_literal_pool (symbolS *, valueT, segT, int);
#endif
-int check_eh_frame PARAMS ((struct expressionS *, unsigned int *));
-int eh_frame_estimate_size_before_relax PARAMS ((fragS *));
-int eh_frame_relax_frag PARAMS ((fragS *));
-void eh_frame_convert_frag PARAMS ((fragS *));
+int check_eh_frame (struct expressionS *, unsigned int *);
+int eh_frame_estimate_size_before_relax (fragS *);
+int eh_frame_relax_frag (fragS *);
+void eh_frame_convert_frag (fragS *);
+
+int generic_force_reloc (struct fix *);
#include "expr.h" /* Before targ-*.h */
/* this one starts the chain of target dependant headers */
#include "targ-env.h"
-#ifdef TC_ARC
-#include "struc-symbol.h"
+#ifdef OBJ_MAYBE_ELF
+#define IS_ELF (OUTPUT_FLAVOR == bfd_target_elf_flavour)
+#else
+#ifdef OBJ_ELF
+#define IS_ELF 1
+#else
+#define IS_ELF 0
+#endif
#endif
#include "write.h"
diff --git a/contrib/binutils/gas/atof-generic.c b/contrib/binutils/gas/atof-generic.c
index c5d10d4..8c599b5 100644
--- a/contrib/binutils/gas/atof-generic.c
+++ b/contrib/binutils/gas/atof-generic.c
@@ -32,7 +32,7 @@
#endif
#ifdef TRACE
-static void flonum_print PARAMS ((const FLONUM_TYPE *));
+static void flonum_print (const FLONUM_TYPE *);
#endif
#define ASSUME_DECIMAL_MARK_IS_DOT
@@ -75,16 +75,12 @@ static void flonum_print PARAMS ((const FLONUM_TYPE *));
*/
int
-atof_generic (address_of_string_pointer,
- string_of_decimal_marks,
- string_of_decimal_exponent_marks,
- address_of_generic_floating_point_number)
- /* return pointer to just AFTER number we read. */
- char **address_of_string_pointer;
- /* At most one per number. */
- const char *string_of_decimal_marks;
- const char *string_of_decimal_exponent_marks;
- FLONUM_TYPE *address_of_generic_floating_point_number;
+atof_generic (/* return pointer to just AFTER number we read. */
+ char **address_of_string_pointer,
+ /* At most one per number. */
+ const char *string_of_decimal_marks,
+ const char *string_of_decimal_exponent_marks,
+ FLONUM_TYPE *address_of_generic_floating_point_number)
{
int return_value; /* 0 means OK. */
char *first_digit;
@@ -472,7 +468,7 @@ atof_generic (address_of_string_pointer,
{
/*
* Compute the mantssa (& exponent) of the power of 10.
- * If sucessful, then multiply the power of 10 by the digits
+ * If successful, then multiply the power of 10 by the digits
* giving return_binary_mantissa and return_binary_exponent.
*/
diff --git a/contrib/binutils/gas/bignum-copy.c b/contrib/binutils/gas/bignum-copy.c
index b4ed7d1..5697472 100644
--- a/contrib/binutils/gas/bignum-copy.c
+++ b/contrib/binutils/gas/bignum-copy.c
@@ -33,11 +33,10 @@
/* void */
int
-bignum_copy (in, in_length, out, out_length)
- register LITTLENUM_TYPE *in;
- register int in_length; /* in sizeof(littlenum)s */
- register LITTLENUM_TYPE *out;
- register int out_length; /* in sizeof(littlenum)s */
+bignum_copy (register LITTLENUM_TYPE *in,
+ register int in_length, /* in sizeof(littlenum)s */
+ register LITTLENUM_TYPE *out,
+ register int out_length /* in sizeof(littlenum)s */)
{
int significant_littlenums_dropped;
diff --git a/contrib/binutils/gas/bignum.h b/contrib/binutils/gas/bignum.h
index 42954cf..fbb77ff 100644
--- a/contrib/binutils/gas/bignum.h
+++ b/contrib/binutils/gas/bignum.h
@@ -46,7 +46,7 @@ typedef unsigned short LITTLENUM_TYPE;
/* lengths are in sizeof(littlenum)s */
-int bignum_copy PARAMS ((LITTLENUM_TYPE * in, int in_length,
- LITTLENUM_TYPE * out, int out_length));
+int bignum_copy (LITTLENUM_TYPE * in, int in_length,
+ LITTLENUM_TYPE * out, int out_length);
/* end of bignum.h */
diff --git a/contrib/binutils/gas/bit_fix.h b/contrib/binutils/gas/bit_fix.h
index 80c0022..1676d2c 100644
--- a/contrib/binutils/gas/bit_fix.h
+++ b/contrib/binutils/gas/bit_fix.h
@@ -20,7 +20,7 @@
/* The bit_fix was implemented to support machines that need variables
to be inserted in bitfields other than 1, 2 and 4 bytes.
- Furthermore it gives us a possibillity to mask in bits in the symbol
+ Furthermore it gives us a possibility to mask in bits in the symbol
when it's fixed in the objectcode and check the symbols limits.
The or-mask is used to set the huffman bits in displacements for the
diff --git a/contrib/binutils/gas/cgen.c b/contrib/binutils/gas/cgen.c
index 67b9b16..5ce7f4c 100644
--- a/contrib/binutils/gas/cgen.c
+++ b/contrib/binutils/gas/cgen.c
@@ -1,22 +1,22 @@
/* GAS interface for targets using CGEN: Cpu tools GENerator.
- Copyright 1996, 1997, 1998, 1999, 2000, 2001
+ Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
-This file is part of GAS, the GNU Assembler.
+ This file is part of GAS, the GNU Assembler.
-GAS is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
+ GAS is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
-GAS is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ GAS is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with GAS; see the file COPYING. If not, write to the Free Software
-Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with GAS; see the file COPYING. If not, write to the Free Software
+ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include <setjmp.h>
#include "ansidecl.h"
@@ -29,7 +29,7 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "cgen.h"
#include "dwarf2dbg.h"
-static void queue_fixup PARAMS ((int, int, expressionS *));
+static void queue_fixup (int, int, expressionS *);
/* Opcode table descriptor, must be set by md_begin. */
@@ -61,7 +61,8 @@ cgen_asm_record_register (name, number)
OPINDEX is the index in the operand table.
OPINFO is something the caller chooses to help in reloc determination. */
-struct fixup {
+struct fixup
+{
int opindex;
int opinfo;
expressionS exp;
@@ -112,7 +113,7 @@ queue_fixup (opindex, opinfo, expP)
gas_cgen_initialize_saved_fixups_array():
Sets num_fixups_in_chain to 0 for each element. Call this from
md_begin() if you plan to use these functions and you want the
- fixup count in each element to be set to 0 intially. This is
+ fixup count in each element to be set to 0 initially. This is
not necessary, but it's included just in case. It performs
the same function for each element in the array of fixup chains
that gas_init_parse() performs for the current fixups.
@@ -130,7 +131,8 @@ queue_fixup (opindex, opinfo, expP)
element - swap the current fixups with those in this element number.
*/
-struct saved_fixups {
+struct saved_fixups
+{
struct fixup fixup_chain[GAS_CGEN_MAX_FIXUPS];
int num_fixups_in_chain;
};
@@ -240,7 +242,6 @@ gas_cgen_record_fixup (frag, where, insn, length, operand, opinfo, symbol, offse
/* It may seem strange to use operand->attrs and not insn->attrs here,
but it is the operand that has a pc relative relocation. */
-
fixP = fix_new (frag, where, length / 8, symbol, offset,
CGEN_OPERAND_ATTR_VALUE (operand, CGEN_OPERAND_PCREL_ADDR),
(bfd_reloc_code_real_type)
@@ -279,7 +280,6 @@ gas_cgen_record_fixup_exp (frag, where, insn, length, operand, opinfo, exp)
/* It may seem strange to use operand->attrs and not insn->attrs here,
but it is the operand that has a pc relative relocation. */
-
fixP = fix_new_exp (frag, where, length / 8, exp,
CGEN_OPERAND_ATTR_VALUE (operand, CGEN_OPERAND_PCREL_ADDR),
(bfd_reloc_code_real_type)
@@ -431,7 +431,7 @@ gas_cgen_finish_insn (insn, buf, length, relax_p, result)
Relaxable instructions: We need to ensure we allocate enough
space for the largest insn. */
- if (CGEN_INSN_ATTR_VALUE (insn, CGEN_INSN_RELAX))
+ if (CGEN_INSN_ATTR_VALUE (insn, CGEN_INSN_RELAXED))
/* These currently shouldn't get here. */
abort ();
@@ -531,7 +531,7 @@ gas_cgen_finish_insn (insn, buf, length, relax_p, result)
cgen_operand_lookup_by_num (gas_cgen_cpu_desc, fixups[i].opindex);
/* Don't create fixups for these. That's done during relaxation.
- We don't need to test for CGEN_INSN_RELAX as they can't get here
+ We don't need to test for CGEN_INSN_RELAXED as they can't get here
(see above). */
if (relax_p
&& CGEN_INSN_ATTR_VALUE (insn, CGEN_INSN_RELAXABLE)
@@ -580,39 +580,12 @@ gas_cgen_md_apply_fix3 (fixP, valP, seg)
/* Canonical name, since used a lot. */
CGEN_CPU_DESC cd = gas_cgen_cpu_desc;
- /* FIXME FIXME FIXME: The value we are passed in *valuep includes
- the symbol values. Since we are using BFD_ASSEMBLER, if we are
- doing this relocation the code in write.c is going to call
- bfd_install_relocation, which is also going to use the symbol
- value. That means that if the reloc is fully resolved we want to
- use *valuep since bfd_install_relocation is not being used.
- However, if the reloc is not fully resolved we do not want to use
- *valuep, and must use fx_offset instead. However, if the reloc
- is PC relative, we do want to use *valuep since it includes the
- result of md_pcrel_from. This is confusing. */
-
if (fixP->fx_addsy == (symbolS *) NULL)
fixP->fx_done = 1;
- else if (fixP->fx_pcrel)
- ;
-
- else
- {
- value = fixP->fx_offset;
-
- if (fixP->fx_subsy != (symbolS *) NULL)
- {
- if (S_GET_SEGMENT (fixP->fx_subsy) == absolute_section)
- value -= S_GET_VALUE (fixP->fx_subsy);
- else
- {
- /* We don't actually support subtracting a symbol. */
- as_bad_where (fixP->fx_file, fixP->fx_line,
- _("expression too complex"));
- }
- }
- }
+ /* We don't actually support subtracting a symbol. */
+ if (fixP->fx_subsy != (symbolS *) NULL)
+ as_bad_where (fixP->fx_file, fixP->fx_line, _("expression too complex"));
if ((int) fixP->fx_r_type >= (int) BFD_RELOC_UNUSED)
{
@@ -743,3 +716,15 @@ gas_cgen_tc_gen_reloc (section, fixP)
reloc->address = fixP->fx_frag->fr_address + fixP->fx_where;
return reloc;
}
+
+/* Perform any cgen specific initialisation.
+ Called after gas_cgen_cpu_desc has been created. */
+
+void
+gas_cgen_begin ()
+{
+ if (flag_signed_overflow_ok)
+ cgen_set_signed_overflow_ok (gas_cgen_cpu_desc);
+ else
+ cgen_clear_signed_overflow_ok (gas_cgen_cpu_desc);
+}
diff --git a/contrib/binutils/gas/cgen.h b/contrib/binutils/gas/cgen.h
index 9d814b7..8cf72af 100644
--- a/contrib/binutils/gas/cgen.h
+++ b/contrib/binutils/gas/cgen.h
@@ -46,56 +46,57 @@ typedef struct {
The result is an error message or NULL for success.
The parsed value is stored in the bfd_vma *. */
extern const char * gas_cgen_parse_operand
- PARAMS ((CGEN_CPU_DESC, enum cgen_parse_operand_type,
- const char **, int, int, enum cgen_parse_operand_result *,
- bfd_vma *));
+ (CGEN_CPU_DESC, enum cgen_parse_operand_type,
+ const char **, int, int, enum cgen_parse_operand_result *,
+ bfd_vma *);
/* Call this from md_assemble to initialize the assembler callback. */
-extern void gas_cgen_init_parse PARAMS ((void));
+extern void gas_cgen_init_parse (void);
/* Routines and macros for saving fixup chains. */
-extern void gas_cgen_save_fixups PARAMS ((int));
-extern void gas_cgen_restore_fixups PARAMS ((int));
-extern void gas_cgen_swap_fixups PARAMS ((int));
-extern void gas_cgen_initialize_saved_fixups_array PARAMS ((void));
+extern void gas_cgen_save_fixups (int);
+extern void gas_cgen_restore_fixups (int);
+extern void gas_cgen_swap_fixups (int);
+extern void gas_cgen_initialize_saved_fixups_array (void);
#define MAX_SAVED_FIXUP_CHAINS 50
/* Add a register to the assembler's hash table.
This makes lets GAS parse registers for us.
??? This isn't currently used, but it could be in the future. */
-extern void cgen_asm_record_register PARAMS ((char *, int));
+extern void cgen_asm_record_register (char *, int);
/* After CGEN_SYM (assemble_insn) is done, this is called to
output the insn and record any fixups. */
-extern void gas_cgen_finish_insn PARAMS ((const CGEN_INSN *,
- CGEN_INSN_BYTES_PTR, unsigned int,
- int, finished_insnS *));
+extern void gas_cgen_finish_insn (const CGEN_INSN *,
+ CGEN_INSN_BYTES_PTR, unsigned int,
+ int, finished_insnS *);
/* Record a fixup. */
-extern fixS * gas_cgen_record_fixup PARAMS ((fragS *, int, const CGEN_INSN *,
- int, const CGEN_OPERAND *, int,
- symbolS *, offsetT));
-extern fixS * gas_cgen_record_fixup_exp PARAMS ((fragS *, int, const CGEN_INSN *,
- int, const CGEN_OPERAND *, int,
- expressionS *));
+extern fixS * gas_cgen_record_fixup (fragS *, int, const CGEN_INSN *,
+ int, const CGEN_OPERAND *, int,
+ symbolS *, offsetT);
+extern fixS * gas_cgen_record_fixup_exp (fragS *, int, const CGEN_INSN *,
+ int, const CGEN_OPERAND *, int,
+ expressionS *);
/* md_apply_fix3 handler */
-extern void gas_cgen_md_apply_fix3 PARAMS ((fixS *, valueT *, segT));
+extern void gas_cgen_md_apply_fix3 (fixS *, valueT *, segT);
/* tc_gen_reloc handler */
-extern arelent *gas_cgen_tc_gen_reloc PARAMS ((asection *, fixS *));
+extern arelent *gas_cgen_tc_gen_reloc (asection *, fixS *);
/* Target supplied routine to lookup a reloc. */
extern bfd_reloc_code_real_type
-md_cgen_lookup_reloc PARAMS ((const CGEN_INSN *, const CGEN_OPERAND *,
- fixS *));
+md_cgen_lookup_reloc (const CGEN_INSN *, const CGEN_OPERAND *, fixS *);
/* Optional target supplied routine to record a fixup for an expression. */
extern fixS *
-md_cgen_record_fixup_exp PARAMS ((fragS *, int, const CGEN_INSN *, int,
- const CGEN_OPERAND *, int,
- expressionS *));
+md_cgen_record_fixup_exp (fragS *, int, const CGEN_INSN *, int,
+ const CGEN_OPERAND *, int, expressionS *);
-extern void gas_cgen_md_operand PARAMS ((expressionS *));
+extern void gas_cgen_md_operand (expressionS *);
+
+/* Perform any cgen specific initialisation for gas. */
+extern void gas_cgen_begin (void);
#endif /* GAS_CGEN_H */
diff --git a/contrib/binutils/gas/cond.c b/contrib/binutils/gas/cond.c
index 73304cb..870a7d5 100644
--- a/contrib/binutils/gas/cond.c
+++ b/contrib/binutils/gas/cond.c
@@ -55,20 +55,23 @@ struct conditional_frame {
int macro_nest;
};
-static void initialize_cframe PARAMS ((struct conditional_frame *cframe));
-static char *get_mri_string PARAMS ((int, int *));
+static void initialize_cframe (struct conditional_frame *cframe);
+static char *get_mri_string (int, int *);
static struct conditional_frame *current_cframe = NULL;
+/* Performs the .ifdef (test_defined == 1) and
+ the .ifndef (test_defined == 0) pseudo op. */
+
void
-s_ifdef (arg)
- int arg;
+s_ifdef (int test_defined)
{
/* Points to name of symbol. */
- register char *name;
+ char *name;
/* Points to symbol. */
- register symbolS *symbolP;
+ symbolS *symbolP;
struct conditional_frame cframe;
+ char c;
/* Leading whitespace is part of operand. */
SKIP_WHITESPACE ();
@@ -79,34 +82,47 @@ s_ifdef (arg)
as_bad (_("invalid identifier for \".ifdef\""));
obstack_1grow (&cond_obstack, 0);
ignore_rest_of_line ();
+ return;
}
+
+ c = get_symbol_end ();
+ symbolP = symbol_find (name);
+ *input_line_pointer = c;
+
+ initialize_cframe (&cframe);
+
+ if (cframe.dead_tree)
+ cframe.ignoring = 1;
else
{
- char c;
+ int is_defined;
- c = get_symbol_end ();
- symbolP = symbol_find (name);
- *input_line_pointer = c;
+ /* Use the same definition of 'defined' as .equiv so that a symbol
+ which has been referenced but not yet given a value/address is
+ considered to be undefined. */
+ is_defined =
+ symbolP != NULL
+ && S_IS_DEFINED (symbolP)
+ && S_GET_SEGMENT (symbolP) != reg_section;
- initialize_cframe (&cframe);
- cframe.ignoring = cframe.dead_tree || !((symbolP != 0) ^ arg);
- current_cframe = ((struct conditional_frame *)
- obstack_copy (&cond_obstack, &cframe,
- sizeof (cframe)));
+ cframe.ignoring = ! (test_defined ^ is_defined);
+ }
- if (LISTING_SKIP_COND ()
- && cframe.ignoring
- && (cframe.previous_cframe == NULL
- || ! cframe.previous_cframe->ignoring))
- listing_list (2);
+ current_cframe = ((struct conditional_frame *)
+ obstack_copy (&cond_obstack, &cframe,
+ sizeof (cframe)));
+
+ if (LISTING_SKIP_COND ()
+ && cframe.ignoring
+ && (cframe.previous_cframe == NULL
+ || ! cframe.previous_cframe->ignoring))
+ listing_list (2);
- demand_empty_rest_of_line ();
- } /* if a valid identifyer name */
+ demand_empty_rest_of_line ();
}
void
-s_if (arg)
- int arg;
+s_if (int arg)
{
expressionS operand;
struct conditional_frame cframe;
@@ -168,9 +184,7 @@ s_if (arg)
/* Get a string for the MRI IFC or IFNC pseudo-ops. */
static char *
-get_mri_string (terminator, len)
- int terminator;
- int *len;
+get_mri_string (int terminator, int *len)
{
char *ret;
char *s;
@@ -210,8 +224,7 @@ get_mri_string (terminator, len)
/* The MRI IFC and IFNC pseudo-ops. */
void
-s_ifc (arg)
- int arg;
+s_ifc (int arg)
{
char *stop = NULL;
char stopc;
@@ -252,8 +265,7 @@ s_ifc (arg)
}
void
-s_elseif (arg)
- int arg;
+s_elseif (int arg)
{
if (current_cframe == NULL)
{
@@ -328,8 +340,7 @@ s_elseif (arg)
}
void
-s_endif (arg)
- int arg ATTRIBUTE_UNUSED;
+s_endif (int arg ATTRIBUTE_UNUSED)
{
struct conditional_frame *hold;
@@ -360,8 +371,7 @@ s_endif (arg)
}
void
-s_else (arg)
- int arg ATTRIBUTE_UNUSED;
+s_else (int arg ATTRIBUTE_UNUSED)
{
if (current_cframe == NULL)
{
@@ -408,8 +418,7 @@ s_else (arg)
}
void
-s_ifeqs (arg)
- int arg;
+s_ifeqs (int arg)
{
char *s1, *s2;
int len1, len2;
@@ -447,7 +456,7 @@ s_ifeqs (arg)
}
int
-ignore_input ()
+ignore_input (void)
{
char *s;
@@ -481,8 +490,7 @@ ignore_input ()
}
static void
-initialize_cframe (cframe)
- struct conditional_frame *cframe;
+initialize_cframe (struct conditional_frame *cframe)
{
memset (cframe, 0, sizeof (*cframe));
as_where (&cframe->if_file_line.file,
@@ -498,8 +506,7 @@ initialize_cframe (cframe)
negative, we are being called at the of the input files. */
void
-cond_finish_check (nest)
- int nest;
+cond_finish_check (int nest)
{
if (current_cframe != NULL && current_cframe->macro_nest >= nest)
{
@@ -522,8 +529,7 @@ cond_finish_check (nest)
nested, and just pop them off the stack. */
void
-cond_exit_macro (nest)
- int nest;
+cond_exit_macro (int nest)
{
while (current_cframe != NULL && current_cframe->macro_nest >= nest)
{
diff --git a/contrib/binutils/gas/config.in b/contrib/binutils/gas/config.in
index 8b8c8b2..fe2bc3f 100644
--- a/contrib/binutils/gas/config.in
+++ b/contrib/binutils/gas/config.in
@@ -25,9 +25,6 @@
/* Define to `long' if <sys/types.h> doesn't define. */
#undef off_t
-/* Define if you need to in order for stat and other things to work. */
-#undef _POSIX_SOURCE
-
/* Define to `unsigned' if <sys/types.h> doesn't define. */
#undef size_t
@@ -160,6 +157,18 @@
/* Define as 1 if big endian. */
#undef TARGET_BYTES_BIG_ENDIAN
+/* Default CPU for MIPS targets. */
+#undef MIPS_CPU_STRING_DEFAULT
+
+/* Allow use of E_MIPS_ABI_O32 on MIPS targets. */
+#undef USE_E_MIPS_ABI_O32
+
+/* Generate 64-bit code by default on MIPS targets. */
+#undef MIPS_DEFAULT_64BIT
+
+/* Choose a default ABI for MIPS targets. */
+#undef MIPS_DEFAULT_ABI
+
/* Default architecture. */
#undef DEFAULT_ARCH
diff --git a/contrib/binutils/gas/config/obj-aout.c b/contrib/binutils/gas/config/obj-aout.c
index a394306..6e5fd29 100644
--- a/contrib/binutils/gas/config/obj-aout.c
+++ b/contrib/binutils/gas/config/obj-aout.c
@@ -1,6 +1,6 @@
/* a.out object file format
- Copyright 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1999, 2000, 2001
- Free Software Foundation, Inc.
+ Copyright 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1999, 2000,
+ 2001, 2002 Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -200,13 +200,13 @@ obj_aout_frob_symbol (sym, punt)
}
void
-obj_aout_frob_file ()
+obj_aout_frob_file_before_fix ()
{
/* Relocation processing may require knowing the VMAs of the sections.
Since writing to a section will cause the BFD back end to compute the
VMAs, fake it out here.... */
bfd_byte b = 0;
- boolean x = true;
+ bfd_boolean x = TRUE;
if (bfd_section_size (stdoutput, text_section) != 0)
{
x = bfd_set_section_contents (stdoutput, text_section, &b, (file_ptr) 0,
@@ -217,7 +217,7 @@ obj_aout_frob_file ()
x = bfd_set_section_contents (stdoutput, data_section, &b, (file_ptr) 0,
(bfd_size_type) 1);
}
- assert (x == true);
+ assert (x);
}
#else /* ! BFD_ASSEMBLER */
@@ -464,14 +464,18 @@ obj_crawl_symbol_chain (headers)
if (flag_readonly_data_in_text && (S_GET_SEGMENT (symbolP) == SEG_DATA))
{
S_SET_SEGMENT (symbolP, SEG_TEXT);
- } /* if pusing data into text */
+ } /* if pushing data into text */
resolve_symbol_value (symbolP);
/* Skip symbols which were equated to undefined or common
- symbols. */
+ symbols. Also skip defined uncommon symbols which can
+ be resolved since in this case they should have been
+ resolved to a non-symbolic constant. */
if (symbolP->sy_value.X_op == O_symbol
- && (! S_IS_DEFINED (symbolP) || S_IS_COMMON (symbolP)))
+ && (! S_IS_DEFINED (symbolP)
+ || S_IS_COMMON (symbolP)
+ || symbol_resolved_p (symbolP)))
{
*symbolPP = symbol_next (symbolP);
continue;
@@ -572,62 +576,6 @@ obj_pre_write_hook (headers)
tc_aout_pre_write_hook (headers);
}
-void
-s_sect ()
-{
- /* Strip out the section name */
- char *section_name;
- char *section_name_end;
- char c;
-
- unsigned int len;
- unsigned int exp;
- char *save;
-
- section_name = input_line_pointer;
- c = get_symbol_end ();
- section_name_end = input_line_pointer;
-
- len = section_name_end - section_name;
- input_line_pointer++;
- save = input_line_pointer;
-
- SKIP_WHITESPACE ();
- if (c == ',')
- {
- exp = get_absolute_expression ();
- }
- else if (*input_line_pointer == ',')
- {
- input_line_pointer++;
- exp = get_absolute_expression ();
- }
- else
- {
- input_line_pointer = save;
- exp = 0;
- }
- if (exp >= 1000)
- {
- as_bad (_("subsegment index too high"));
- }
-
- if (strcmp (section_name, ".text") == 0)
- {
- subseg_set (SEG_TEXT, (subsegT) exp);
- }
-
- if (strcmp (section_name, ".data") == 0)
- {
- if (flag_readonly_data_in_text)
- subseg_set (SEG_TEXT, (subsegT) exp + 1000);
- else
- subseg_set (SEG_DATA, (subsegT) exp);
- }
-
- *section_name_end = c;
-}
-
#endif /* ! BFD_ASSEMBLER */
#ifdef BFD_ASSEMBLER
@@ -731,8 +679,9 @@ const struct format_ops aout_format_ops =
0, /* begin */
0, /* app_file */
obj_aout_frob_symbol,
- obj_aout_frob_file,
+ 0, /* frob_file */
0, /* frob_file_before_adjust */
+ obj_aout_frob_file_before_fix,
0, /* frob_file_after_relocs */
0, /* s_get_size */
0, /* s_set_size */
diff --git a/contrib/binutils/gas/config/obj-aout.h b/contrib/binutils/gas/config/obj-aout.h
index 54168d1..23a2907 100644
--- a/contrib/binutils/gas/config/obj-aout.h
+++ b/contrib/binutils/gas/config/obj-aout.h
@@ -1,6 +1,6 @@
/* obj-aout.h, a.out object file format for gas, the assembler.
- Copyright 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1998, 2000
- Free Software Foundation, Inc.
+ Copyright 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1998, 2000,
+ 2002, 2003 Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -82,9 +82,9 @@ typedef struct nlist obj_symbol_type; /* Symbol table entry */
asection *text_section, *data_section, *bss_section;
#define obj_frob_symbol(S,PUNT) obj_aout_frob_symbol (S, &PUNT)
-#define obj_frob_file() obj_aout_frob_file ()
+#define obj_frob_file_before_fix() obj_aout_frob_file_before_fix ()
extern void obj_aout_frob_symbol PARAMS ((symbolS *, int *));
-extern void obj_aout_frob_file PARAMS ((void));
+extern void obj_aout_frob_file_before_fix PARAMS ((void));
#define obj_sec_sym_ok_for_reloc(SEC) (1)
@@ -95,7 +95,7 @@ extern void obj_aout_frob_file PARAMS ((void));
/*
* Macros to extract information from a symbol table entry.
- * This syntaxic indirection allows independence regarding a.out or coff.
+ * This syntactic indirection allows independence regarding a.out or coff.
* The argument (s) of all these macros is a pointer to a symbol table entry.
*/
@@ -109,6 +109,12 @@ extern void obj_aout_frob_file PARAMS ((void));
#define S_IS_COMMON(s) \
(S_GET_TYPE (s) == N_UNDF && S_GET_VALUE (s) != 0)
+/* Return true for symbols that should not be reduced to section
+ symbols or eliminated from expressions, because they may be
+ overridden by the linker. */
+#define S_FORCE_RELOC(s, strict) \
+ (!SEG_NORMAL (S_GET_SEGMENT (s)))
+
#define S_IS_REGISTER(s) ((s)->sy_symbol.n_type == N_REGISTER)
/* True if a debug special symbol entry */
diff --git a/contrib/binutils/gas/config/obj-coff.c b/contrib/binutils/gas/config/obj-coff.c
index eb592aa..bd08c2b 100644
--- a/contrib/binutils/gas/config/obj-coff.c
+++ b/contrib/binutils/gas/config/obj-coff.c
@@ -143,7 +143,7 @@ stack_pop (st)
}
/*
- * Maintain a list of the tagnames of the structres.
+ * Maintain a list of the tagnames of the structures.
*/
static struct hash_control *tag_hash;
@@ -1147,7 +1147,9 @@ coff_obj_read_begin_hook ()
}
symbolS *coff_last_function;
+#ifndef OBJ_XCOFF
static symbolS *coff_last_bf;
+#endif
void
coff_frob_symbol (symp, punt)
@@ -1465,12 +1467,14 @@ obj_coff_section (ignore)
{
case 'b': flags |= SEC_ALLOC; flags &=~ SEC_LOAD; break;
case 'n': flags &=~ SEC_LOAD; flags |= SEC_NEVER_LOAD; break;
+
+ case 's': flags |= SEC_SHARED; /* fall through */
case 'd': flags |= SEC_DATA | SEC_LOAD; /* fall through */
case 'w': flags &=~ SEC_READONLY; break;
- case 'a': break; /* For compatability with ELF. */
+
+ case 'a': break; /* For compatibility with ELF. */
case 'x': flags |= SEC_CODE | SEC_LOAD; break;
- case 'r': flags |= SEC_READONLY; break;
- case 's': flags |= SEC_SHARED; break;
+ case 'r': flags |= SEC_DATA | SEC_LOAD | SEC_READONLY; break;
case 'i': /* STYP_INFO */
case 'l': /* STYP_LIB */
@@ -2034,7 +2038,7 @@ do_relocs_for (abfd, h, file_cursor)
ext_ptr++;
#if defined(TC_A29K)
/* The 29k has a special kludge for the high 16 bit
- reloc. Two relocations are emited, R_IHIHALF,
+ reloc. Two relocations are emitted, R_IHIHALF,
and R_IHCONST. The second one doesn't contain a
symbol, but uses the value for offset. */
if (intr.r_type == R_IHIHALF)
@@ -2048,7 +2052,7 @@ do_relocs_for (abfd, h, file_cursor)
#endif
#if defined(TC_OR32)
/* The or32 has a special kludge for the high 16 bit
- reloc. Two relocations are emited, R_IHIHALF,
+ reloc. Two relocations are emitted, R_IHIHALF,
and R_IHCONST. The second one doesn't contain a
symbol, but uses the value for offset. */
if (intr.r_type == R_IHIHALF)
@@ -2092,7 +2096,7 @@ do_relocs_for (abfd, h, file_cursor)
}
/* Run through a frag chain and write out the data to go with it, fill
- in the scnhdrs with the info on the file postions. */
+ in the scnhdrs with the info on the file positions. */
static void
fill_section (abfd, h, file_cursor)
@@ -2960,7 +2964,7 @@ yank_symbols ()
/* FIXME-SOON: where do dups come from?
Maybe tag references before definitions? xoxorich. */
/* Move the debug data from the debug symbol to the
- real symbol. Do NOT do the oposite (i.e. move from
+ real symbol. Do NOT do the opposite (i.e. move from
real symbol to debug symbol and remove real symbol from the
list.) Because some pointers refer to the real symbol
whereas no pointers refer to the debug symbol. */
@@ -3424,7 +3428,7 @@ int coff_flags;
#ifndef SUB_SEGMENT_ALIGN
#ifdef HANDLE_ALIGN
-/* The last subsegment gets an aligment corresponding to the alignment
+/* The last subsegment gets an alignment corresponding to the alignment
of the section. This allows proper nop-filling at the end of
code-bearing sections. */
#define SUB_SEGMENT_ALIGN(SEG, FRCHAIN) \
@@ -3627,7 +3631,7 @@ write_object_file ()
#if 0
/* Recent changes to write need this, but where it should
go is up to Ken.. */
- if (bfd_close_all_done (abfd) == false)
+ if (!bfd_close_all_done (abfd))
as_fatal (_("Can't close %s: %s"), out_file_name,
bfd_errmsg (bfd_get_error ()));
#else
@@ -4098,8 +4102,8 @@ obj_coff_lcomm (ignore)
static void
fixup_mdeps (frags, h, this_segment)
- fragS * frags;
- object_headers * h;
+ fragS *frags;
+ object_headers *h ATTRIBUTE_UNUSED;
segT this_segment;
{
subseg_change (this_segment, 0);
@@ -4623,8 +4627,8 @@ const pseudo_typeS coff_pseudo_table[] =
#endif
{"version", s_ignore, 0},
{"ABORT", s_abort, 0},
-#ifdef TC_M88K
- /* The m88k uses sdef instead of def. */
+#if defined( TC_M88K ) || defined ( TC_TIC4X )
+ /* The m88k and tic4x uses sdef instead of def. */
{"sdef", obj_coff_def, 0},
#endif
{NULL, NULL, 0} /* end sentinel */
@@ -4659,6 +4663,7 @@ const struct format_ops coff_format_ops =
coff_frob_symbol,
0, /* frob_file */
0, /* frob_file_before_adjust */
+ 0, /* frob_file_before_fix */
coff_frob_file_after_relocs,
0, /* s_get_size */
0, /* s_set_size */
diff --git a/contrib/binutils/gas/config/obj-coff.h b/contrib/binutils/gas/config/obj-coff.h
index 56389c9..5200552 100644
--- a/contrib/binutils/gas/config/obj-coff.h
+++ b/contrib/binutils/gas/config/obj-coff.h
@@ -1,6 +1,6 @@
/* coff object file format
Copyright 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
- 1999, 2000, 2002
+ 1999, 2000, 2002, 2003
Free Software Foundation, Inc.
This file is part of GAS.
@@ -157,6 +157,11 @@
#define TARGET_FORMAT "coff-tic30"
#endif
+#ifdef TC_TIC4X
+#include "coff/tic4x.h"
+#define TARGET_FORMAT "coff2-tic4x"
+#endif
+
#ifdef TC_TIC54X
#include "coff/tic54x.h"
#define TARGET_FORMAT "coff1-c54x"
@@ -244,6 +249,12 @@ extern void coff_obj_read_begin_hook PARAMS ((void));
#define OBJ_SYMFIELD_TYPE unsigned long
#define sy_obj sy_flags
+/* We can't use the predefined section symbols in bfd/section.c, as
+ COFF symbols have extra fields. See bfd/libcoff.h:coff_symbol_type. */
+#ifndef obj_sec_sym_ok_for_reloc
+#define obj_sec_sym_ok_for_reloc(SEC) ((SEC)->owner != 0)
+#endif
+
#define SYM_AUXENT(S) \
(&coffsymbol (symbol_get_bfdsym (S))->native[1].u.auxent)
#define SYM_AUXINFO(S) \
@@ -458,7 +469,7 @@ typedef struct
#endif
/* Symbol table macros and constants. */
-/* Possible and usefull section number in symbol table
+/* Possible and useful section number in symbol table
The values of TEXT, DATA and BSS may not be portable. */
#define C_ABS_SECTION N_ABS
@@ -469,12 +480,14 @@ typedef struct
#define C_REGISTER_SECTION 50
/* Macros to extract information from a symbol table entry.
- This syntaxic indirection allows independence regarding a.out or coff.
+ This syntactic indirection allows independence regarding a.out or coff.
The argument (s) of all these macros is a pointer to a symbol table entry. */
/* Predicates. */
/* True if the symbol is external. */
-#define S_IS_EXTERNAL(s) ((s)->sy_symbol.ost_entry.n_scnum == C_UNDEF_SECTION)
+#define S_IS_EXTERNAL(s) \
+ ((s)->sy_symbol.ost_entry.n_scnum == C_UNDEF_SECTION)
+
/* True if symbol has been defined, ie :
section > 0 (DATA, TEXT or BSS)
section == 0 and value > 0 (external bss symbol). */
@@ -483,8 +496,17 @@ typedef struct
|| ((s)->sy_symbol.ost_entry.n_scnum == C_UNDEF_SECTION \
&& S_GET_VALUE (s) > 0) \
|| ((s)->sy_symbol.ost_entry.n_scnum == C_ABS_SECTION))
+
+/* Return true for symbols that should not be reduced to section
+ symbols or eliminated from expressions, because they may be
+ overridden by the linker. */
+#define S_FORCE_RELOC(s, strict) \
+ (!SEG_NORMAL (S_GET_SEGMENT (s)) || (strict && S_IS_WEAK (s)))
+
/* True if a debug special symbol entry. */
-#define S_IS_DEBUG(s) ((s)->sy_symbol.ost_entry.n_scnum == C_DEBUG_SECTION)
+#define S_IS_DEBUG(s) \
+ ((s)->sy_symbol.ost_entry.n_scnum == C_DEBUG_SECTION)
+
/* True if a symbol is local symbol name. */
/* A symbol name whose name includes ^A is a gas internal pseudo symbol. */
#define S_IS_LOCAL(s) \
@@ -495,13 +517,16 @@ typedef struct
|| (flag_strip_local_absolute \
&& !S_IS_EXTERNAL(s) \
&& (s)->sy_symbol.ost_entry.n_scnum == C_ABS_SECTION))
+
/* True if a symbol is not defined in this file. */
#define S_IS_EXTERN(s) ((s)->sy_symbol.ost_entry.n_scnum == 0 \
&& S_GET_VALUE (s) == 0)
+
/* True if a symbol can be multiply defined (bss symbols have this def
though it is bad practice). */
#define S_IS_COMMON(s) ((s)->sy_symbol.ost_entry.n_scnum == 0 \
&& S_GET_VALUE (s) != 0)
+
/* True if a symbol name is in the string table, i.e. its length is > 8. */
#define S_IS_STRING(s) (strlen(S_GET_NAME(s)) > 8 ? 1 : 0)
@@ -518,34 +543,51 @@ typedef struct
/* Accessors. */
/* The name of the symbol. */
#define S_GET_NAME(s) ((char*) (s)->sy_symbol.ost_entry.n_offset)
+
/* The pointer to the string table. */
#define S_GET_OFFSET(s) ((s)->sy_symbol.ost_entry.n_offset)
+
/* The numeric value of the segment. */
#define S_GET_SEGMENT(s) s_get_segment(s)
+
/* The data type. */
#define S_GET_DATA_TYPE(s) ((s)->sy_symbol.ost_entry.n_type)
+
/* The storage class. */
#define S_GET_STORAGE_CLASS(s) ((s)->sy_symbol.ost_entry.n_sclass)
+
/* The number of auxiliary entries. */
#define S_GET_NUMBER_AUXILIARY(s) ((s)->sy_symbol.ost_entry.n_numaux)
/* Modifiers. */
/* Set the name of the symbol. */
-#define S_SET_NAME(s,v) ((s)->sy_symbol.ost_entry.n_offset = (unsigned long) (v))
+#define S_SET_NAME(s,v) \
+ ((s)->sy_symbol.ost_entry.n_offset = (unsigned long) (v))
+
/* Set the offset of the symbol. */
-#define S_SET_OFFSET(s,v) ((s)->sy_symbol.ost_entry.n_offset = (v))
+#define S_SET_OFFSET(s,v) \
+ ((s)->sy_symbol.ost_entry.n_offset = (v))
+
/* The numeric value of the segment. */
-#define S_SET_SEGMENT(s,v) ((s)->sy_symbol.ost_entry.n_scnum = SEGMENT_TO_SYMBOL_TYPE(v))
+#define S_SET_SEGMENT(s,v) \
+ ((s)->sy_symbol.ost_entry.n_scnum = SEGMENT_TO_SYMBOL_TYPE(v))
+
/* The data type. */
-#define S_SET_DATA_TYPE(s,v) ((s)->sy_symbol.ost_entry.n_type = (v))
+#define S_SET_DATA_TYPE(s,v) \
+ ((s)->sy_symbol.ost_entry.n_type = (v))
+
/* The storage class. */
-#define S_SET_STORAGE_CLASS(s,v) ((s)->sy_symbol.ost_entry.n_sclass = (v))
+#define S_SET_STORAGE_CLASS(s,v) \
+ ((s)->sy_symbol.ost_entry.n_sclass = (v))
+
/* The number of auxiliary entries. */
-#define S_SET_NUMBER_AUXILIARY(s,v) ((s)->sy_symbol.ost_entry.n_numaux = (v))
+#define S_SET_NUMBER_AUXILIARY(s,v) \
+ ((s)->sy_symbol.ost_entry.n_numaux = (v))
/* Additional modifiers. */
/* The symbol is external (does not mean undefined). */
-#define S_SET_EXTERNAL(s) { S_SET_STORAGE_CLASS(s, C_EXT) ; SF_CLEAR_LOCAL(s); }
+#define S_SET_EXTERNAL(s) \
+ { S_SET_STORAGE_CLASS(s, C_EXT) ; SF_CLEAR_LOCAL(s); }
/* Auxiliary entry macros. SA_ stands for symbol auxiliary. */
/* Omit the tv related fields. */
@@ -753,7 +795,7 @@ typedef struct
#define H_SET_SYMBOL_TABLE_SIZE(h,v) ((h)->filehdr.f_nsyms = (v))
#define H_SET_SIZEOF_OPTIONAL_HEADER(h,v) ((h)->filehdr.f_opthdr = (v))
#define H_SET_FLAGS(h,v) ((h)->filehdr.f_flags = (v))
-/* Extra fields to achieve bsd a.out compatibility and for convinience. */
+/* Extra fields to achieve bsd a.out compatibility and for convenience. */
#define H_SET_RELOCATION_SIZE(h,t,d) ((h)->relocation_size = (t)+(d))
#define H_SET_STRING_SIZE(h,v) ((h)->string_table_size = (v))
#define H_SET_LINENO_SIZE(h,v) ((h)->lineno_size = (v))
diff --git a/contrib/binutils/gas/config/obj-ecoff.c b/contrib/binutils/gas/config/obj-ecoff.c
index 4d055cb..69f8d9a 100644
--- a/contrib/binutils/gas/config/obj-ecoff.c
+++ b/contrib/binutils/gas/config/obj-ecoff.c
@@ -1,5 +1,5 @@
/* ECOFF object file format.
- Copyright 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
+ Copyright 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
Free Software Foundation, Inc.
Contributed by Cygnus Support.
This file was put together by Ian Lance Taylor <ian@cygnus.com>.
@@ -98,18 +98,13 @@ const pseudo_typeS obj_pseudo_table[] =
{ NULL, s_ignore, 0 }
};
-/* Swap out the symbols and debugging information for BFD. */
+/* Set section VMAs and GP values before reloc processing. */
void
-ecoff_frob_file ()
+ecoff_frob_file_before_fix ()
{
- const struct ecoff_debug_swap * const debug_swap
- = &ecoff_backend (stdoutput)->debug_swap;
bfd_vma addr;
asection **sec;
- HDRR *hdr;
- char *buf;
- char *set;
/* Set the section VMA values. We force the .sdata and .sbss
sections to the end to ensure that their VMA addresses are close
@@ -177,6 +172,46 @@ ecoff_frob_file ()
if (secs[i])
bfd_section_list_insert (stdoutput, &stdoutput->sections, secs[i]);
+ /* Fill in the register masks. */
+ {
+ unsigned long gprmask = 0;
+ unsigned long fprmask = 0;
+ unsigned long *cprmask = NULL;
+
+#ifdef TC_MIPS
+ /* Fill in the MIPS register masks. It's probably not worth
+ setting up a generic interface for this. */
+ gprmask = mips_gprmask;
+ cprmask = mips_cprmask;
+#endif
+
+#ifdef TC_ALPHA
+ alpha_frob_ecoff_data ();
+
+ if (! bfd_ecoff_set_gp_value (stdoutput, alpha_gp_value))
+ as_fatal (_("Can't set GP value"));
+
+ gprmask = alpha_gprmask;
+ fprmask = alpha_fprmask;
+#endif
+
+ if (! bfd_ecoff_set_regmasks (stdoutput, gprmask, fprmask, cprmask))
+ as_fatal (_("Can't set register masks"));
+ }
+}
+
+/* Swap out the symbols and debugging information for BFD. */
+
+void
+ecoff_frob_file ()
+{
+ const struct ecoff_debug_swap * const debug_swap
+ = &ecoff_backend (stdoutput)->debug_swap;
+ bfd_vma addr ATTRIBUTE_UNUSED;
+ HDRR *hdr;
+ char *buf;
+ char *set;
+
/* Build the ECOFF debugging information. */
assert (ecoff_data (stdoutput) != 0);
hdr = &ecoff_data (stdoutput)->debug_info.symbolic_header;
@@ -204,35 +239,7 @@ ecoff_frob_file ()
SET (external_rfd, crfd, PTR, debug_swap->external_rfd_size);
SET (external_fdr, ifdMax, PTR, debug_swap->external_fdr_size);
SET (external_ext, iextMax, PTR, debug_swap->external_ext_size);
-
#undef SET
-
- /* Fill in the register masks. */
- {
- unsigned long gprmask = 0;
- unsigned long fprmask = 0;
- unsigned long *cprmask = NULL;
-
-#ifdef TC_MIPS
- /* Fill in the MIPS register masks. It's probably not worth
- setting up a generic interface for this. */
- gprmask = mips_gprmask;
- cprmask = mips_cprmask;
-#endif
-
-#ifdef TC_ALPHA
- alpha_frob_ecoff_data ();
-
- if (! bfd_ecoff_set_gp_value (stdoutput, alpha_gp_value))
- as_fatal (_("Can't set GP value"));
-
- gprmask = alpha_gprmask;
- fprmask = alpha_fprmask;
-#endif
-
- if (! bfd_ecoff_set_regmasks (stdoutput, gprmask, fprmask, cprmask))
- as_fatal (_("Can't set register masks"));
- }
}
/* This is called by the ECOFF code to set the external information
@@ -251,7 +258,7 @@ obj_ecoff_set_ext (sym, ext)
know (bfd_asymbol_flavour (symbol_get_bfdsym (sym))
== bfd_target_ecoff_flavour);
esym = ecoffsymbol (symbol_get_bfdsym (sym));
- esym->local = false;
+ esym->local = FALSE;
esym->native = xmalloc (debug_swap->external_ext_size);
(*debug_swap->swap_ext_out) (stdoutput, ext, esym->native);
}
@@ -296,6 +303,7 @@ const struct format_ops ecoff_format_ops =
obj_ecoff_frob_symbol,
ecoff_frob_file,
0, /* frob_file_before_adjust */
+ ecoff_frob_file_before_fix,
0, /* frob_file_after_relocs */
0, /* s_get_size */
0, /* s_set_size */
diff --git a/contrib/binutils/gas/config/obj-ecoff.h b/contrib/binutils/gas/config/obj-ecoff.h
index 01a67d7..54ee043 100644
--- a/contrib/binutils/gas/config/obj-ecoff.h
+++ b/contrib/binutils/gas/config/obj-ecoff.h
@@ -1,5 +1,5 @@
/* ECOFF object file format header file.
- Copyright 1993, 1994, 1995, 1996, 1997, 1999
+ Copyright 1993, 1994, 1995, 1996, 1997, 1999, 2002
Free Software Foundation, Inc.
Contributed by Cygnus Support.
Written by Ian Lance Taylor <ian@cygnus.com>.
@@ -49,6 +49,10 @@ struct ecoff_sy_obj
/* Modify the ECOFF symbol. */
#define obj_frob_symbol(symp, punt) ecoff_frob_symbol (symp)
+/* Set section VMAs and GP. */
+extern void ecoff_frob_file_before_fix PARAMS ((void));
+#define obj_frob_file_before_fix() ecoff_frob_file_before_fix ()
+
/* This is used to write the symbolic data in the format that BFD
expects it. */
extern void ecoff_frob_file PARAMS ((void));
diff --git a/contrib/binutils/gas/config/obj-elf.c b/contrib/binutils/gas/config/obj-elf.c
index bbfbf40..14d48f2 100644
--- a/contrib/binutils/gas/config/obj-elf.c
+++ b/contrib/binutils/gas/config/obj-elf.c
@@ -1,6 +1,6 @@
/* ELF object file format
Copyright 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
- 2001, 2002 Free Software Foundation, Inc.
+ 2001, 2002, 2003 Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -25,6 +25,7 @@
#include "subsegs.h"
#include "obstack.h"
#include "struc-symbol.h"
+#include "dwarf2dbg.h"
#ifndef ECOFF_DEBUGGING
#define ECOFF_DEBUGGING 0
@@ -52,47 +53,25 @@
#include "elf/i370.h"
#endif
-static bfd_vma elf_s_get_size PARAMS ((symbolS *));
-static void elf_s_set_size PARAMS ((symbolS *, bfd_vma));
-static bfd_vma elf_s_get_align PARAMS ((symbolS *));
-static void elf_s_set_align PARAMS ((symbolS *, bfd_vma));
-static void elf_s_set_other PARAMS ((symbolS *, int));
-static int elf_sec_sym_ok_for_reloc PARAMS ((asection *));
-static void adjust_stab_sections PARAMS ((bfd *, asection *, PTR));
-static void build_group_lists PARAMS ((bfd *, asection *, PTR));
-static int elf_separate_stab_sections PARAMS ((void));
-static void elf_init_stab_section PARAMS ((segT));
-static symbolS *elf_common PARAMS ((int));
-
-#ifdef NEED_ECOFF_DEBUG
-static boolean elf_get_extr PARAMS ((asymbol *, EXTR *));
-static void elf_set_index PARAMS ((asymbol *, bfd_size_type));
-#endif
-
-static void obj_elf_line PARAMS ((int));
-void obj_elf_version PARAMS ((int));
-static void obj_elf_size PARAMS ((int));
-static void obj_elf_type PARAMS ((int));
-static void obj_elf_ident PARAMS ((int));
-static void obj_elf_weak PARAMS ((int));
-static void obj_elf_local PARAMS ((int));
-static void obj_elf_visibility PARAMS ((int));
-static void obj_elf_change_section
- PARAMS ((const char *, int, int, int, const char *, int, int));
-static int obj_elf_parse_section_letters PARAMS ((char *, size_t));
-static int obj_elf_section_word PARAMS ((char *, size_t));
-static char *obj_elf_section_name PARAMS ((void));
-static int obj_elf_section_type PARAMS ((char *, size_t));
-static void obj_elf_symver PARAMS ((int));
-static void obj_elf_subsection PARAMS ((int));
-static void obj_elf_popsection PARAMS ((int));
-static void obj_elf_tls_common PARAMS ((int));
+static void obj_elf_line (int);
+static void obj_elf_size (int);
+static void obj_elf_type (int);
+static void obj_elf_ident (int);
+static void obj_elf_weak (int);
+static void obj_elf_local (int);
+static void obj_elf_visibility (int);
+static void obj_elf_symver (int);
+static void obj_elf_subsection (int);
+static void obj_elf_popsection (int);
+static void obj_elf_tls_common (int);
+static void obj_elf_lcomm (int);
static const pseudo_typeS elf_pseudo_table[] =
{
{"comm", obj_elf_common, 0},
{"common", obj_elf_common, 1},
{"ident", obj_elf_ident, 0},
+ {"lcomm", obj_elf_lcomm, 0},
{"local", obj_elf_local, 0},
{"previous", obj_elf_previous, 0},
{"section", obj_elf_section, 0},
@@ -121,13 +100,16 @@ static const pseudo_typeS elf_pseudo_table[] =
{"subsection", obj_elf_subsection, 0},
/* These are GNU extensions to aid in garbage collecting C++ vtables. */
- {"vtable_inherit", (void (*) PARAMS ((int))) &obj_elf_vtable_inherit, 0},
- {"vtable_entry", (void (*) PARAMS ((int))) &obj_elf_vtable_entry, 0},
+ {"vtable_inherit", (void (*) (int)) &obj_elf_vtable_inherit, 0},
+ {"vtable_entry", (void (*) (int)) &obj_elf_vtable_entry, 0},
/* These are used for dwarf. */
{"2byte", cons, 2},
{"4byte", cons, 4},
{"8byte", cons, 8},
+ /* These are used for dwarf2. */
+ { "file", (void (*) (int)) dwarf2_directive_file, 0 },
+ { "loc", dwarf2_directive_loc, 0 },
/* We need to trap the section changing calls to handle .previous. */
{"data", obj_elf_data, 0},
@@ -190,19 +172,21 @@ static const pseudo_typeS ecoff_debug_pseudo_table[] =
/* This is called when the assembler starts. */
void
-elf_begin ()
+elf_begin (void)
{
+ asection *s;
+
/* Add symbols for the known sections to the symbol table. */
- symbol_table_insert (section_symbol (bfd_get_section_by_name (stdoutput,
- TEXT_SECTION_NAME)));
- symbol_table_insert (section_symbol (bfd_get_section_by_name (stdoutput,
- DATA_SECTION_NAME)));
- symbol_table_insert (section_symbol (bfd_get_section_by_name (stdoutput,
- BSS_SECTION_NAME)));
+ s = bfd_get_section_by_name (stdoutput, TEXT_SECTION_NAME);
+ symbol_table_insert (section_symbol (s));
+ s = bfd_get_section_by_name (stdoutput, DATA_SECTION_NAME);
+ symbol_table_insert (section_symbol (s));
+ s = bfd_get_section_by_name (stdoutput, BSS_SECTION_NAME);
+ symbol_table_insert (section_symbol (s));
}
void
-elf_pop_insert ()
+elf_pop_insert (void)
{
pop_insert (elf_pseudo_table);
if (ECOFF_DEBUGGING)
@@ -210,64 +194,53 @@ elf_pop_insert ()
}
static bfd_vma
-elf_s_get_size (sym)
- symbolS *sym;
+elf_s_get_size (symbolS *sym)
{
return S_GET_SIZE (sym);
}
static void
-elf_s_set_size (sym, sz)
- symbolS *sym;
- bfd_vma sz;
+elf_s_set_size (symbolS *sym, bfd_vma sz)
{
S_SET_SIZE (sym, sz);
}
static bfd_vma
-elf_s_get_align (sym)
- symbolS *sym;
+elf_s_get_align (symbolS *sym)
{
return S_GET_ALIGN (sym);
}
static void
-elf_s_set_align (sym, align)
- symbolS *sym;
- bfd_vma align;
+elf_s_set_align (symbolS *sym, bfd_vma align)
{
S_SET_ALIGN (sym, align);
}
int
-elf_s_get_other (sym)
- symbolS *sym;
+elf_s_get_other (symbolS *sym)
{
return elf_symbol (symbol_get_bfdsym (sym))->internal_elf_sym.st_other;
}
static void
-elf_s_set_other (sym, other)
- symbolS *sym;
- int other;
+elf_s_set_other (symbolS *sym, int other)
{
S_SET_OTHER (sym, other);
}
static int
-elf_sec_sym_ok_for_reloc (sec)
- asection *sec;
+elf_sec_sym_ok_for_reloc (asection *sec)
{
return obj_sec_sym_ok_for_reloc (sec);
}
void
-elf_file_symbol (s)
- const char *s;
+elf_file_symbol (const char *s)
{
symbolS *sym;
- sym = symbol_new (s, absolute_section, (valueT) 0, (struct frag *) 0);
+ sym = symbol_new (s, absolute_section, 0, NULL);
symbol_set_frag (sym, &zero_address_frag);
symbol_get_bfdsym (sym)->flags |= BSF_FILE;
@@ -285,189 +258,110 @@ elf_file_symbol (s)
#endif
}
+/* Called from read.c:s_comm after we've parsed .comm symbol, size.
+ Parse a possible alignment value. */
+
static symbolS *
-elf_common (is_common)
- int is_common;
+elf_common_parse (int ignore ATTRIBUTE_UNUSED, symbolS *symbolP, addressT size)
{
- char *name;
- char c;
- char *p;
- int temp, size;
- symbolS *symbolP;
- int have_align;
+ addressT align = 0;
+ int is_local = symbol_get_obj (symbolP)->local;
- if (flag_mri && is_common)
+ if (*input_line_pointer == ',')
{
- s_mri_common (0);
- return NULL;
- }
+ char *save = input_line_pointer;
- name = input_line_pointer;
- c = get_symbol_end ();
- /* just after name is now '\0' */
- p = input_line_pointer;
- *p = c;
- SKIP_WHITESPACE ();
- if (*input_line_pointer != ',')
- {
- as_bad (_("expected comma after symbol-name"));
- ignore_rest_of_line ();
- return NULL;
- }
- input_line_pointer++; /* skip ',' */
- if ((temp = get_absolute_expression ()) < 0)
- {
- as_bad (_(".COMMon length (%d.) <0! Ignored."), temp);
- ignore_rest_of_line ();
- return NULL;
- }
- size = temp;
- *p = 0;
- symbolP = symbol_find_or_make (name);
- *p = c;
- if (S_IS_DEFINED (symbolP) && ! S_IS_COMMON (symbolP))
- {
- as_bad (_("symbol `%s' is already defined"), S_GET_NAME (symbolP));
- ignore_rest_of_line ();
- return NULL;
- }
- if (S_GET_VALUE (symbolP) != 0)
- {
- if (S_GET_VALUE (symbolP) != (valueT) size)
- {
- as_warn (_("length of .comm \"%s\" is already %ld; not changed to %d"),
- S_GET_NAME (symbolP), (long) S_GET_VALUE (symbolP), size);
- }
- }
- know (symbolP->sy_frag == &zero_address_frag);
- if (*input_line_pointer != ',')
- have_align = 0;
- else
- {
- have_align = 1;
input_line_pointer++;
SKIP_WHITESPACE ();
- }
- if (! have_align || *input_line_pointer != '"')
- {
- if (! have_align)
- temp = 0;
- else
- {
- temp = get_absolute_expression ();
- if (temp < 0)
- {
- temp = 0;
- as_warn (_("common alignment negative; 0 assumed"));
- }
- }
- if (symbol_get_obj (symbolP)->local)
+
+ if (*input_line_pointer == '"')
{
- segT old_sec;
- int old_subsec;
- char *pfrag;
- int align;
-
- /* allocate_bss: */
- old_sec = now_seg;
- old_subsec = now_subseg;
- if (temp)
+ /* For sparc. Accept .common symbol, length, "bss" */
+ input_line_pointer++;
+ /* Some use the dot, some don't. */
+ if (*input_line_pointer == '.')
+ input_line_pointer++;
+ /* Some say data, some say bss. */
+ if (strncmp (input_line_pointer, "bss\"", 4) == 0)
+ input_line_pointer += 4;
+ else if (strncmp (input_line_pointer, "data\"", 5) == 0)
+ input_line_pointer += 5;
+ else
{
- /* convert to a power of 2 alignment */
- for (align = 0; (temp & 1) == 0; temp >>= 1, ++align);
- if (temp != 1)
- {
- as_bad (_("common alignment not a power of 2"));
- ignore_rest_of_line ();
- return NULL;
- }
+ char *p = input_line_pointer;
+ char c;
+
+ while (*--p != '"')
+ ;
+ while (!is_end_of_line[(unsigned char) *input_line_pointer])
+ if (*input_line_pointer++ == '"')
+ break;
+ c = *input_line_pointer;
+ *input_line_pointer = '\0';
+ as_bad (_("bad .common segment %s"), p);
+ *input_line_pointer = c;
+ ignore_rest_of_line ();
+ return NULL;
}
- else
- align = 0;
- record_alignment (bss_section, align);
- subseg_set (bss_section, 0);
- if (align)
- frag_align (align, 0, 0);
- if (S_GET_SEGMENT (symbolP) == bss_section)
- symbol_get_frag (symbolP)->fr_symbol = 0;
- symbol_set_frag (symbolP, frag_now);
- pfrag = frag_var (rs_org, 1, 1, (relax_substateT) 0, symbolP,
- (offsetT) size, (char *) 0);
- *pfrag = 0;
- S_SET_SIZE (symbolP, size);
- S_SET_SEGMENT (symbolP, bss_section);
- S_CLEAR_EXTERNAL (symbolP);
- subseg_set (old_sec, old_subsec);
+ /* ??? Don't ask me why these are always global. */
+ is_local = 0;
}
else
{
- allocate_common:
- S_SET_VALUE (symbolP, (valueT) size);
- S_SET_ALIGN (symbolP, temp);
- S_SET_EXTERNAL (symbolP);
- S_SET_SEGMENT (symbolP, bfd_com_section_ptr);
+ input_line_pointer = save;
+ align = parse_align (is_local);
+ if (align == (addressT) -1)
+ return NULL;
}
}
+
+ if (is_local)
+ {
+ bss_alloc (symbolP, size, align);
+ S_CLEAR_EXTERNAL (symbolP);
+ }
else
{
- input_line_pointer++;
- /* @@ Some use the dot, some don't. Can we get some consistency?? */
- if (*input_line_pointer == '.')
- input_line_pointer++;
- /* @@ Some say data, some say bss. */
- if (strncmp (input_line_pointer, "bss\"", 4)
- && strncmp (input_line_pointer, "data\"", 5))
- {
- while (*--input_line_pointer != '"')
- ;
- input_line_pointer--;
- goto bad_common_segment;
- }
- while (*input_line_pointer++ != '"')
- ;
- goto allocate_common;
+ S_SET_VALUE (symbolP, size);
+ S_SET_ALIGN (symbolP, align);
+ S_SET_EXTERNAL (symbolP);
+ S_SET_SEGMENT (symbolP, bfd_com_section_ptr);
}
symbol_get_bfdsym (symbolP)->flags |= BSF_OBJECT;
- demand_empty_rest_of_line ();
return symbolP;
-
- {
- bad_common_segment:
- p = input_line_pointer;
- while (*p && *p != '\n')
- p++;
- c = *p;
- *p = '\0';
- as_bad (_("bad .common segment %s"), input_line_pointer + 1);
- *p = c;
- input_line_pointer = p;
- ignore_rest_of_line ();
- return NULL;
- }
}
void
-obj_elf_common (is_common)
- int is_common;
+obj_elf_common (int is_common)
{
- elf_common (is_common);
+ if (flag_mri && is_common)
+ s_mri_common (0);
+ else
+ s_comm_internal (0, elf_common_parse);
}
static void
-obj_elf_tls_common (ignore)
- int ignore ATTRIBUTE_UNUSED;
+obj_elf_tls_common (int ignore ATTRIBUTE_UNUSED)
{
- symbolS *symbolP = elf_common (0);
+ symbolS *symbolP = s_comm_internal (0, elf_common_parse);
if (symbolP)
symbol_get_bfdsym (symbolP)->flags |= BSF_THREAD_LOCAL;
}
static void
-obj_elf_local (ignore)
- int ignore ATTRIBUTE_UNUSED;
+obj_elf_lcomm (int ignore ATTRIBUTE_UNUSED)
+{
+ symbolS *symbolP = s_comm_internal (0, s_lcomm_internal);
+
+ if (symbolP)
+ symbol_get_bfdsym (symbolP)->flags |= BSF_OBJECT;
+}
+
+static void
+obj_elf_local (int ignore ATTRIBUTE_UNUSED)
{
char *name;
int c;
@@ -495,8 +389,7 @@ obj_elf_local (ignore)
}
static void
-obj_elf_weak (ignore)
- int ignore ATTRIBUTE_UNUSED;
+obj_elf_weak (int ignore ATTRIBUTE_UNUSED)
{
char *name;
int c;
@@ -524,8 +417,7 @@ obj_elf_weak (ignore)
}
static void
-obj_elf_visibility (visibility)
- int visibility;
+obj_elf_visibility (int visibility)
{
char *name;
int c;
@@ -595,90 +487,19 @@ static struct section_stack *section_stack;
other possibilities, but I don't know what they are. In any case,
BFD doesn't really let us set the section type. */
-/* Certain named sections have particular defined types, listed on p.
- 4-19 of the ABI. */
-struct special_section
-{
- const char *name;
- int type;
- int attributes;
-};
-
-static struct special_section const special_sections[] =
-{
- { ".bss", SHT_NOBITS, SHF_ALLOC + SHF_WRITE },
- { ".comment", SHT_PROGBITS, 0 },
- { ".data", SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
- { ".data1", SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
- { ".debug", SHT_PROGBITS, 0 },
- { ".fini", SHT_PROGBITS, SHF_ALLOC + SHF_EXECINSTR },
- { ".init", SHT_PROGBITS, SHF_ALLOC + SHF_EXECINSTR },
- { ".line", SHT_PROGBITS, 0 },
- { ".note", SHT_NOTE, 0 },
- { ".rodata", SHT_PROGBITS, SHF_ALLOC },
- { ".rodata1", SHT_PROGBITS, SHF_ALLOC },
- { ".tbss", SHT_NOBITS, SHF_ALLOC + SHF_WRITE + SHF_TLS },
- { ".tdata", SHT_PROGBITS, SHF_ALLOC + SHF_WRITE + SHF_TLS },
- { ".text", SHT_PROGBITS, SHF_ALLOC + SHF_EXECINSTR },
-#if 0
- /* FIXME: The current gcc, as of 2002-03-03, will emit
-
- .section .init_array,"aw",@progbits
-
- for __attribute__ ((section (".init_array"))). "@progbits" marks
- the incorrect section type. For now, we make them with
- SHT_PROGBITS. BFD will fix the section type. Gcc should be changed
- to emit
-
- .section .init_array
-
- */
- { ".init_array",SHT_INIT_ARRAY, SHF_ALLOC + SHF_WRITE },
- { ".fini_array",SHT_FINI_ARRAY, SHF_ALLOC + SHF_WRITE },
- { ".preinit_array",SHT_PREINIT_ARRAY, SHF_ALLOC + SHF_WRITE },
-#else
- { ".init_array",SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
- { ".fini_array",SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
- { ".preinit_array",SHT_PROGBITS, SHF_ALLOC + SHF_WRITE },
-#endif
-
-#ifdef ELF_TC_SPECIAL_SECTIONS
- ELF_TC_SPECIAL_SECTIONS
-#endif
-
-#if 0
- /* The following section names are special, but they can not
- reasonably appear in assembler code. Some of the attributes are
- processor dependent. */
- { ".dynamic", SHT_DYNAMIC, SHF_ALLOC /* + SHF_WRITE */ },
- { ".dynstr", SHT_STRTAB, SHF_ALLOC },
- { ".dynsym", SHT_DYNSYM, SHF_ALLOC },
- { ".got", SHT_PROGBITS, 0 },
- { ".hash", SHT_HASH, SHF_ALLOC },
- { ".interp", SHT_PROGBITS, /* SHF_ALLOC */ },
- { ".plt", SHT_PROGBITS, 0 },
- { ".shstrtab",SHT_STRTAB, 0 },
- { ".strtab", SHT_STRTAB, /* SHF_ALLOC */ },
- { ".symtab", SHT_SYMTAB, /* SHF_ALLOC */ },
-#endif
-
- { NULL, 0, 0 }
-};
-
-static void
-obj_elf_change_section (name, type, attr, entsize, group_name, linkonce, push)
- const char *name;
- int type;
- int attr;
- int entsize;
- const char *group_name;
- int linkonce;
- int push;
+void
+obj_elf_change_section (const char *name,
+ int type,
+ int attr,
+ int entsize,
+ const char *group_name,
+ int linkonce,
+ int push)
{
asection *old_sec;
segT sec;
flagword flags;
- int i;
+ const struct bfd_elf_special_section *ssect;
#ifdef md_flush_pending_output
md_flush_pending_output ();
@@ -701,40 +522,79 @@ obj_elf_change_section (name, type, attr, entsize, group_name, linkonce, push)
old_sec = bfd_get_section_by_name (stdoutput, name);
sec = subseg_new (name, 0);
+ ssect = _bfd_elf_get_sec_type_attr (stdoutput, name);
- /* See if this is one of the special sections. */
- for (i = 0; special_sections[i].name != NULL; i++)
- if (strcmp (name, special_sections[i].name) == 0)
- {
- if (type == SHT_NULL)
- type = special_sections[i].type;
- else if (type != special_sections[i].type)
- {
- if (old_sec == NULL)
- {
- as_warn (_("setting incorrect section type for %s"), name);
- }
- else
- {
- as_warn (_("ignoring incorrect section type for %s"), name);
- type = special_sections[i].type;
- }
- }
- if ((attr &~ special_sections[i].attributes) != 0
- && old_sec == NULL)
- {
- /* As a GNU extension, we permit a .note section to be
- allocatable. If the linker sees an allocateable .note
- section, it will create a PT_NOTE segment in the output
- file. */
- if (strcmp (name, ".note") != 0
- || attr != SHF_ALLOC)
+ if (ssect != NULL)
+ {
+ bfd_boolean override = FALSE;
+
+ if (type == SHT_NULL)
+ type = ssect->type;
+ else if (type != ssect->type)
+ {
+ if (old_sec == NULL
+ /* FIXME: gcc, as of 2002-10-22, will emit
+
+ .section .init_array,"aw",@progbits
+
+ for __attribute__ ((section (".init_array"))).
+ "@progbits" is incorrect. */
+ && ssect->type != SHT_INIT_ARRAY
+ && ssect->type != SHT_FINI_ARRAY
+ && ssect->type != SHT_PREINIT_ARRAY)
+ {
+ /* We allow to specify any type for a .note section. */
+ if (ssect->type != SHT_NOTE)
+ as_warn (_("setting incorrect section type for %s"),
+ name);
+ }
+ else
+ {
+ as_warn (_("ignoring incorrect section type for %s"),
+ name);
+ type = ssect->type;
+ }
+ }
+
+ if (old_sec == NULL && (attr & ~ssect->attr) != 0)
+ {
+ /* As a GNU extension, we permit a .note section to be
+ allocatable. If the linker sees an allocatable .note
+ section, it will create a PT_NOTE segment in the output
+ file. We also allow "x" for .note.GNU-stack. */
+ if (ssect->type == SHT_NOTE
+ && (attr == SHF_ALLOC || attr == SHF_EXECINSTR))
+ ;
+ /* Allow different SHF_MERGE and SHF_STRINGS if we have
+ something like .rodata.str. */
+ else if (ssect->suffix_length == -2
+ && name[ssect->prefix_length] == '.'
+ && (attr
+ & ~ssect->attr
+ & ~SHF_MERGE
+ & ~SHF_STRINGS) == 0)
+ ;
+ /* .interp, .strtab and .symtab can have SHF_ALLOC. */
+ else if (attr == SHF_ALLOC
+ && (strcmp (name, ".interp") == 0
+ || strcmp (name, ".strtab") == 0
+ || strcmp (name, ".symtab") == 0))
+ override = TRUE;
+ else
+ {
as_warn (_("setting incorrect section attributes for %s"),
name);
- }
- attr |= special_sections[i].attributes;
- break;
- }
+ override = TRUE;
+ }
+ }
+ if (!override && old_sec == NULL)
+ attr |= ssect->attr;
+ }
+
+ if (type != SHT_NULL)
+ elf_section_type (sec) = type;
+ if (attr != 0)
+ elf_section_flags (sec) = attr;
/* Convert ELF type and flags to BFD flags. */
flags = (SEC_RELOC
@@ -755,20 +615,21 @@ obj_elf_change_section (name, type, attr, entsize, group_name, linkonce, push)
/* Prevent SEC_HAS_CONTENTS from being inadvertently set. */
if (type == SHT_NOBITS)
- seg_info (sec)->bss = 1;
+ seg_info (sec)->bss = 1;
+ if (linkonce)
+ flags |= SEC_LINK_ONCE | SEC_LINK_DUPLICATES_DISCARD;
bfd_set_section_flags (stdoutput, sec, flags);
if (flags & SEC_MERGE)
sec->entsize = entsize;
elf_group_name (sec) = group_name;
- elf_linkonce_p (sec) = linkonce;
/* Add a symbol for this section to the symbol table. */
secsym = symbol_find (name);
if (secsym != NULL)
symbol_set_bfdsym (secsym, sec->symbol);
else
- symbol_table_insert (section_symbol (sec));
+ symbol_table_insert (section_symbol (sec));
}
else if (attr != 0)
{
@@ -778,8 +639,8 @@ obj_elf_change_section (name, type, attr, entsize, group_name, linkonce, push)
if (((old_sec->flags ^ flags)
& (SEC_ALLOC | SEC_LOAD | SEC_READONLY | SEC_CODE
| SEC_EXCLUDE | SEC_SORT_ENTRIES | SEC_MERGE | SEC_STRINGS
- | SEC_THREAD_LOCAL))
- || linkonce != elf_linkonce_p (sec))
+ | SEC_LINK_ONCE | SEC_LINK_DUPLICATES_DISCARD
+ | SEC_THREAD_LOCAL)))
as_warn (_("ignoring changed section attributes for %s"), name);
if ((flags & SEC_MERGE) && old_sec->entsize != (unsigned) entsize)
as_warn (_("ignoring changed section entity size for %s"), name);
@@ -794,9 +655,7 @@ obj_elf_change_section (name, type, attr, entsize, group_name, linkonce, push)
}
static int
-obj_elf_parse_section_letters (str, len)
- char *str;
- size_t len;
+obj_elf_parse_section_letters (char *str, size_t len)
{
int attr = 0;
@@ -846,10 +705,7 @@ obj_elf_parse_section_letters (str, len)
attr |= md_attr;
else
#endif
- {
- as_warn ("%s", bad_msg);
- attr = -1;
- }
+ as_fatal ("%s", bad_msg);
}
break;
}
@@ -860,9 +716,7 @@ obj_elf_parse_section_letters (str, len)
}
static int
-obj_elf_section_word (str, len)
- char *str;
- size_t len;
+obj_elf_section_word (char *str, size_t len)
{
if (len == 5 && strncmp (str, "write", 5) == 0)
return SHF_WRITE;
@@ -870,6 +724,8 @@ obj_elf_section_word (str, len)
return SHF_ALLOC;
if (len == 9 && strncmp (str, "execinstr", 9) == 0)
return SHF_EXECINSTR;
+ if (len == 3 && strncmp (str, "tls", 3) == 0)
+ return SHF_TLS;
#ifdef md_elf_section_word
{
@@ -884,14 +740,14 @@ obj_elf_section_word (str, len)
}
static int
-obj_elf_section_type (str, len)
- char *str;
- size_t len;
+obj_elf_section_type (char *str, size_t len)
{
if (len == 8 && strncmp (str, "progbits", 8) == 0)
return SHT_PROGBITS;
if (len == 6 && strncmp (str, "nobits", 6) == 0)
return SHT_NOBITS;
+ if (len == 4 && strncmp (str, "note", 4) == 0)
+ return SHT_NOTE;
#ifdef md_elf_section_type
{
@@ -907,7 +763,7 @@ obj_elf_section_type (str, len)
/* Get name of section. */
static char *
-obj_elf_section_name ()
+obj_elf_section_name (void)
{
char *name;
@@ -931,7 +787,7 @@ obj_elf_section_name ()
end++;
if (end == input_line_pointer)
{
- as_warn (_("missing name"));
+ as_bad (_("missing name"));
ignore_rest_of_line ();
return NULL;
}
@@ -939,6 +795,9 @@ obj_elf_section_name ()
name = xmalloc (end - input_line_pointer + 1);
memcpy (name, input_line_pointer, end - input_line_pointer);
name[end - input_line_pointer] = '\0';
+#ifdef tc_canonicalize_section_name
+ name = tc_canonicalize_section_name (name);
+#endif
input_line_pointer = end;
}
SKIP_WHITESPACE ();
@@ -946,8 +805,7 @@ obj_elf_section_name ()
}
void
-obj_elf_section (push)
- int push;
+obj_elf_section (int push)
{
char *name, *group_name, *beg;
int type, attr, dummy;
@@ -1080,7 +938,7 @@ obj_elf_section (push)
SKIP_WHITESPACE ();
if (*input_line_pointer != '#')
{
- as_warn (_("character following name is not '#'"));
+ as_bad (_("character following name is not '#'"));
ignore_rest_of_line ();
return;
}
@@ -1105,8 +963,7 @@ obj_elf_section (push)
/* Change to the .data section. */
void
-obj_elf_data (i)
- int i;
+obj_elf_data (int i)
{
#ifdef md_flush_pending_output
md_flush_pending_output ();
@@ -1124,8 +981,7 @@ obj_elf_data (i)
/* Change to the .text section. */
void
-obj_elf_text (i)
- int i;
+obj_elf_text (int i)
{
#ifdef md_flush_pending_output
md_flush_pending_output ();
@@ -1141,8 +997,7 @@ obj_elf_text (i)
}
static void
-obj_elf_subsection (ignore)
- int ignore ATTRIBUTE_UNUSED;
+obj_elf_subsection (int ignore ATTRIBUTE_UNUSED)
{
register int temp;
@@ -1166,15 +1021,14 @@ obj_elf_subsection (ignore)
sections. */
void
-obj_elf_section_change_hook ()
+obj_elf_section_change_hook (void)
{
previous_section = now_seg;
previous_subsection = now_subseg;
}
void
-obj_elf_previous (ignore)
- int ignore ATTRIBUTE_UNUSED;
+obj_elf_previous (int ignore ATTRIBUTE_UNUSED)
{
segT new_section;
int new_subsection;
@@ -1201,8 +1055,7 @@ obj_elf_previous (ignore)
}
static void
-obj_elf_popsection (xxx)
- int xxx ATTRIBUTE_UNUSED;
+obj_elf_popsection (int xxx ATTRIBUTE_UNUSED)
{
struct section_stack *top = section_stack;
@@ -1228,12 +1081,11 @@ obj_elf_popsection (xxx)
}
static void
-obj_elf_line (ignore)
- int ignore ATTRIBUTE_UNUSED;
+obj_elf_line (int ignore ATTRIBUTE_UNUSED)
{
/* Assume delimiter is part of expression. BSD4.2 as fails with
delightful bug, so we are not being incompatible here. */
- new_logical_line ((char *) NULL, (int) (get_absolute_expression ()));
+ new_logical_line (NULL, get_absolute_expression ());
demand_empty_rest_of_line ();
}
@@ -1244,8 +1096,7 @@ obj_elf_line (ignore)
with the same value as the symbol NAME. */
static void
-obj_elf_symver (ignore)
- int ignore ATTRIBUTE_UNUSED;
+obj_elf_symver (int ignore ATTRIBUTE_UNUSED)
{
char *name;
char c;
@@ -1268,6 +1119,7 @@ obj_elf_symver (ignore)
}
++input_line_pointer;
+ SKIP_WHITESPACE ();
name = input_line_pointer;
/* Temporarily include '@' in symbol names. */
@@ -1314,8 +1166,7 @@ obj_elf_symver (ignore)
syntax is ".vtable_inherit CHILDNAME, PARENTNAME". */
struct fix *
-obj_elf_vtable_inherit (ignore)
- int ignore ATTRIBUTE_UNUSED;
+obj_elf_vtable_inherit (int ignore ATTRIBUTE_UNUSED)
{
char *cname, *pname;
symbolS *csym, *psym;
@@ -1386,8 +1237,7 @@ obj_elf_vtable_inherit (ignore)
".vtable_entry tablename, offset". */
struct fix *
-obj_elf_vtable_entry (ignore)
- int ignore ATTRIBUTE_UNUSED;
+obj_elf_vtable_entry (int ignore ATTRIBUTE_UNUSED)
{
char *name;
symbolS *sym;
@@ -1423,7 +1273,7 @@ obj_elf_vtable_entry (ignore)
}
void
-elf_obj_read_begin_hook ()
+elf_obj_read_begin_hook (void)
{
#ifdef NEED_ECOFF_DEBUG
if (ECOFF_DEBUGGING)
@@ -1432,8 +1282,7 @@ elf_obj_read_begin_hook ()
}
void
-elf_obj_symbol_new_hook (symbolP)
- symbolS *symbolP;
+elf_obj_symbol_new_hook (symbolS *symbolP)
{
struct elf_obj_sy *sy_obj;
@@ -1452,16 +1301,14 @@ elf_obj_symbol_new_hook (symbolP)
context. */
void
-elf_copy_symbol_attributes (dest, src)
- symbolS *dest, *src;
+elf_copy_symbol_attributes (symbolS *dest, symbolS *src)
{
struct elf_obj_sy *srcelf = symbol_get_obj (src);
struct elf_obj_sy *destelf = symbol_get_obj (dest);
if (srcelf->size)
{
if (destelf->size == NULL)
- destelf->size =
- (expressionS *) xmalloc (sizeof (expressionS));
+ destelf->size = xmalloc (sizeof (expressionS));
*destelf->size = *srcelf->size;
}
else
@@ -1477,8 +1324,7 @@ elf_copy_symbol_attributes (dest, src)
}
void
-obj_elf_version (ignore)
- int ignore ATTRIBUTE_UNUSED;
+obj_elf_version (int ignore ATTRIBUTE_UNUSED)
{
char *name;
unsigned int c;
@@ -1487,7 +1333,7 @@ obj_elf_version (ignore)
subsegT subseg = now_subseg;
Elf_Internal_Note i_note;
Elf_External_Note e_note;
- asection *note_secp = (asection *) NULL;
+ asection *note_secp = NULL;
int len;
SKIP_WHITESPACE ();
@@ -1518,11 +1364,11 @@ obj_elf_version (ignore)
i_note.descsz = 0; /* no description */
i_note.type = NT_VERSION;
p = frag_more (sizeof (e_note.namesz));
- md_number_to_chars (p, (valueT) i_note.namesz, sizeof (e_note.namesz));
+ md_number_to_chars (p, i_note.namesz, sizeof (e_note.namesz));
p = frag_more (sizeof (e_note.descsz));
- md_number_to_chars (p, (valueT) i_note.descsz, sizeof (e_note.descsz));
+ md_number_to_chars (p, i_note.descsz, sizeof (e_note.descsz));
p = frag_more (sizeof (e_note.type));
- md_number_to_chars (p, (valueT) i_note.type, sizeof (e_note.type));
+ md_number_to_chars (p, i_note.type, sizeof (e_note.type));
p = frag_more (len + 1);
strcpy (p, name);
@@ -1538,8 +1384,7 @@ obj_elf_version (ignore)
}
static void
-obj_elf_size (ignore)
- int ignore ATTRIBUTE_UNUSED;
+obj_elf_size (int ignore ATTRIBUTE_UNUSED)
{
char *name = input_line_pointer;
char c = get_symbol_end ();
@@ -1580,8 +1425,7 @@ obj_elf_size (ignore)
}
else
{
- symbol_get_obj (sym)->size =
- (expressionS *) xmalloc (sizeof (expressionS));
+ symbol_get_obj (sym)->size = xmalloc (sizeof (expressionS));
*symbol_get_obj (sym)->size = exp;
}
demand_empty_rest_of_line ();
@@ -1603,8 +1447,7 @@ obj_elf_size (ignore)
*/
static void
-obj_elf_type (ignore)
- int ignore ATTRIBUTE_UNUSED;
+obj_elf_type (int ignore ATTRIBUTE_UNUSED)
{
char *name;
char c;
@@ -1640,6 +1483,12 @@ obj_elf_type (ignore)
else if (strcmp (typename, "object") == 0
|| strcmp (typename, "STT_OBJECT") == 0)
type = BSF_OBJECT;
+ else if (strcmp (typename, "tls_object") == 0
+ || strcmp (typename, "STT_TLS") == 0)
+ type = BSF_OBJECT | BSF_THREAD_LOCAL;
+ else if (strcmp (typename, "notype") == 0
+ || strcmp (typename, "STT_NOTYPE") == 0)
+ ;
#ifdef md_elf_symbol_type
else if ((type = md_elf_symbol_type (typename, sym, elfsym)) != -1)
;
@@ -1658,8 +1507,7 @@ obj_elf_type (ignore)
}
static void
-obj_elf_ident (ignore)
- int ignore ATTRIBUTE_UNUSED;
+obj_elf_ident (int ignore ATTRIBUTE_UNUSED)
{
static segT comment_section;
segT old_section = now_seg;
@@ -1689,8 +1537,7 @@ obj_elf_ident (ignore)
/* The first entry in a .stabs section is special. */
void
-obj_elf_init_stab_section (seg)
- segT seg;
+obj_elf_init_stab_section (segT seg)
{
char *file;
char *p;
@@ -1705,8 +1552,8 @@ obj_elf_init_stab_section (seg)
p = frag_more (12);
/* Zero it out. */
memset (p, 0, 12);
- as_where (&file, (unsigned int *) NULL);
- stabstr_name = (char *) xmalloc (strlen (segment_name (seg)) + 4);
+ as_where (&file, NULL);
+ stabstr_name = xmalloc (strlen (segment_name (seg)) + 4);
strcpy (stabstr_name, segment_name (seg));
strcat (stabstr_name, "str");
stroff = get_stab_string_offset (file, stabstr_name);
@@ -1720,10 +1567,7 @@ obj_elf_init_stab_section (seg)
/* Fill in the counts in the first entry in a .stabs section. */
static void
-adjust_stab_sections (abfd, sec, xxx)
- bfd *abfd;
- asection *sec;
- PTR xxx ATTRIBUTE_UNUSED;
+adjust_stab_sections (bfd *abfd, asection *sec, void *xxx ATTRIBUTE_UNUSED)
{
char *name;
asection *strsec;
@@ -1735,7 +1579,7 @@ adjust_stab_sections (abfd, sec, xxx)
if (!strcmp ("str", sec->name + strlen (sec->name) - 3))
return;
- name = (char *) alloca (strlen (sec->name) + 4);
+ name = alloca (strlen (sec->name) + 4);
strcpy (name, sec->name);
strcat (name, "str");
strsec = bfd_get_section_by_name (abfd, name);
@@ -1748,8 +1592,8 @@ adjust_stab_sections (abfd, sec, xxx)
p = seg_info (sec)->stabu.p;
assert (p != 0);
- bfd_h_put_16 (abfd, (bfd_vma) nsyms, (bfd_byte *) p + 6);
- bfd_h_put_32 (abfd, (bfd_vma) strsz, (bfd_byte *) p + 8);
+ bfd_h_put_16 (abfd, nsyms, p + 6);
+ bfd_h_put_32 (abfd, strsz, p + 8);
}
#ifdef NEED_ECOFF_DEBUG
@@ -1761,45 +1605,37 @@ adjust_stab_sections (abfd, sec, xxx)
in the symbol. */
void
-elf_ecoff_set_ext (sym, ext)
- symbolS *sym;
- struct ecoff_extr *ext;
+elf_ecoff_set_ext (symbolS *sym, struct ecoff_extr *ext)
{
- symbol_get_bfdsym (sym)->udata.p = (PTR) ext;
+ symbol_get_bfdsym (sym)->udata.p = ext;
}
/* This function is called by bfd_ecoff_debug_externals. It is
supposed to *EXT to the external symbol information, and return
whether the symbol should be used at all. */
-static boolean
-elf_get_extr (sym, ext)
- asymbol *sym;
- EXTR *ext;
+static bfd_boolean
+elf_get_extr (asymbol *sym, EXTR *ext)
{
if (sym->udata.p == NULL)
- return false;
+ return FALSE;
*ext = *(EXTR *) sym->udata.p;
- return true;
+ return TRUE;
}
/* This function is called by bfd_ecoff_debug_externals. It has
nothing to do for ELF. */
-/*ARGSUSED*/
static void
-elf_set_index (sym, indx)
- asymbol *sym ATTRIBUTE_UNUSED;
- bfd_size_type indx ATTRIBUTE_UNUSED;
+elf_set_index (asymbol *sym ATTRIBUTE_UNUSED,
+ bfd_size_type indx ATTRIBUTE_UNUSED)
{
}
#endif /* NEED_ECOFF_DEBUG */
void
-elf_frob_symbol (symp, puntp)
- symbolS *symp;
- int *puntp;
+elf_frob_symbol (symbolS *symp, int *puntp)
{
struct elf_obj_sy *sy_obj;
@@ -1842,9 +1678,9 @@ elf_frob_symbol (symp, puntp)
/* This symbol was given a new name with the .symver directive.
- If this is an external reference, just rename the symbol to
- include the version string. This will make the relocs be
- against the correct versioned symbol.
+ If this is an external reference, just rename the symbol to
+ include the version string. This will make the relocs be
+ against the correct versioned symbol.
If this is a definition, add an alias. FIXME: Using an alias
will permit the debugging information to refer to the right
@@ -1854,26 +1690,26 @@ elf_frob_symbol (symp, puntp)
if (! S_IS_DEFINED (symp))
{
/* Verify that the name isn't using the @@ syntax--this is
- reserved for definitions of the default version to link
- against. */
+ reserved for definitions of the default version to link
+ against. */
if (p[1] == ELF_VER_CHR)
{
as_bad (_("invalid attempt to declare external version name as default in symbol `%s'"),
sy_obj->versioned_name);
- *puntp = true;
+ *puntp = TRUE;
}
S_SET_NAME (symp, sy_obj->versioned_name);
}
else
{
- if (p [1] == ELF_VER_CHR && p [2] == ELF_VER_CHR)
+ if (p[1] == ELF_VER_CHR && p[2] == ELF_VER_CHR)
{
size_t l;
/* The @@@ syntax is a special case. It renames the
symbol name to versioned_name with one `@' removed. */
l = strlen (&p[3]) + 1;
- memmove (&p [2], &p[3], l);
+ memmove (&p[2], &p[3], l);
S_SET_NAME (symp, sy_obj->versioned_name);
}
else
@@ -1965,12 +1801,9 @@ struct group_list
each list. */
static void
-build_group_lists (abfd, sec, inf)
- bfd *abfd ATTRIBUTE_UNUSED;
- asection *sec;
- PTR inf;
+build_group_lists (bfd *abfd ATTRIBUTE_UNUSED, asection *sec, void *inf)
{
- struct group_list *list = (struct group_list *) inf;
+ struct group_list *list = inf;
const char *group_name = elf_group_name (sec);
unsigned int i;
@@ -2006,18 +1839,18 @@ build_group_lists (abfd, sec, inf)
}
void
-elf_frob_file ()
+elf_frob_file (void)
{
struct group_list list;
unsigned int i;
- bfd_map_over_sections (stdoutput, adjust_stab_sections, (PTR) 0);
+ bfd_map_over_sections (stdoutput, adjust_stab_sections, NULL);
/* Go find section groups. */
list.num_group = 0;
list.head = NULL;
list.elt_count = NULL;
- bfd_map_over_sections (stdoutput, build_group_lists, (PTR) &list);
+ bfd_map_over_sections (stdoutput, build_group_lists, &list);
/* Make the SHT_GROUP sections that describe each section group. We
can't set up the section contents here yet, because elf section
@@ -2034,7 +1867,7 @@ elf_frob_file ()
flags = SEC_READONLY | SEC_HAS_CONTENTS | SEC_IN_MEMORY | SEC_GROUP;
for (s = list.head[i]; s != NULL; s = elf_next_in_group (s))
- if (elf_linkonce_p (s) != ((flags & SEC_LINK_ONCE) != 0))
+ if ((s->flags ^ flags) & SEC_LINK_ONCE)
{
flags |= SEC_LINK_ONCE | SEC_LINK_DUPLICATES_DISCARD;
if (s != list.head[i])
@@ -2064,6 +1897,7 @@ elf_frob_file ()
as_fatal (_("can't create group: %s"),
bfd_errmsg (bfd_get_error ()));
}
+ elf_section_type (s) = SHT_GROUP;
/* Pass a pointer to the first section in this group. */
elf_next_in_group (s) = list.head[i];
@@ -2083,7 +1917,7 @@ elf_frob_file ()
/* It removes any unneeded versioned symbols from the symbol table. */
void
-elf_frob_file_before_adjust ()
+elf_frob_file_before_adjust (void)
{
if (symbol_rootP)
{
@@ -2103,10 +1937,10 @@ elf_frob_file_before_adjust ()
p = strchr (symbol_get_obj (symp)->versioned_name,
ELF_VER_CHR);
know (p != NULL);
- if (p [1] == ELF_VER_CHR && p [2] == ELF_VER_CHR)
+ if (p[1] == ELF_VER_CHR && p[2] == ELF_VER_CHR)
{
size_t l = strlen (&p[3]) + 1;
- memmove (&p [1], &p[3], l);
+ memmove (&p[1], &p[3], l);
}
if (symbol_used_p (symp) == 0
&& symbol_used_in_reloc_p (symp) == 0)
@@ -2130,7 +1964,7 @@ elf_frob_file_before_adjust ()
have generated the relocation section. */
void
-elf_frob_file_after_relocs ()
+elf_frob_file_after_relocs (void)
{
#ifdef NEED_ECOFF_DEBUG
if (ECOFF_DEBUGGING)
@@ -2143,7 +1977,7 @@ elf_frob_file_after_relocs ()
debug_swap
= get_elf_backend_data (stdoutput)->elf_backend_ecoff_debug_swap;
- know (debug_swap != (const struct ecoff_debug_swap *) NULL);
+ know (debug_swap != NULL);
ecoff_build_debug (&debug.symbolic_header, &buf, debug_swap);
/* Set up the pointers in debug. */
@@ -2151,14 +1985,14 @@ elf_frob_file_after_relocs ()
debug.ptr = (type) (buf + debug.symbolic_header.offset)
SET (line, cbLineOffset, unsigned char *);
- SET (external_dnr, cbDnOffset, PTR);
- SET (external_pdr, cbPdOffset, PTR);
- SET (external_sym, cbSymOffset, PTR);
- SET (external_opt, cbOptOffset, PTR);
+ SET (external_dnr, cbDnOffset, void *);
+ SET (external_pdr, cbPdOffset, void *);
+ SET (external_sym, cbSymOffset, void *);
+ SET (external_opt, cbOptOffset, void *);
SET (external_aux, cbAuxOffset, union aux_ext *);
SET (ss, cbSsOffset, char *);
- SET (external_fdr, cbFdOffset, PTR);
- SET (external_rfd, cbRfdOffset, PTR);
+ SET (external_fdr, cbFdOffset, void *);
+ SET (external_rfd, cbRfdOffset, void *);
/* ssext and external_ext are set up just below. */
#undef SET
@@ -2166,7 +2000,7 @@ elf_frob_file_after_relocs ()
/* Set up the external symbols. */
debug.ssext = debug.ssext_end = NULL;
debug.external_ext = debug.external_ext_end = NULL;
- if (! bfd_ecoff_debug_externals (stdoutput, &debug, debug_swap, true,
+ if (! bfd_ecoff_debug_externals (stdoutput, &debug, debug_swap, TRUE,
elf_get_extr, elf_set_index))
as_fatal (_("failed to set up debugging information: %s"),
bfd_errmsg (bfd_get_error ()));
@@ -2174,7 +2008,7 @@ elf_frob_file_after_relocs ()
sec = bfd_get_section_by_name (stdoutput, ".mdebug");
assert (sec != NULL);
- know (stdoutput->output_has_begun == false);
+ know (!stdoutput->output_has_begun);
/* We set the size of the section, call bfd_set_section_contents
to force the ELF backend to allocate a file position, and then
@@ -2183,15 +2017,14 @@ elf_frob_file_after_relocs ()
sec->_raw_size = bfd_ecoff_debug_size (stdoutput, &debug, debug_swap);
/* Pass BUF to bfd_set_section_contents because this will
- eventually become a call to fwrite, and ISO C prohibits
- passing a NULL pointer to a stdio function even if the
- pointer will not be used. */
- if (! bfd_set_section_contents (stdoutput, sec, (PTR) buf,
- (file_ptr) 0, (bfd_size_type) 0))
+ eventually become a call to fwrite, and ISO C prohibits
+ passing a NULL pointer to a stdio function even if the
+ pointer will not be used. */
+ if (! bfd_set_section_contents (stdoutput, sec, buf, 0, 0))
as_fatal (_("can't start writing .mdebug section: %s"),
bfd_errmsg (bfd_get_error ()));
- know (stdoutput->output_has_begun == true);
+ know (stdoutput->output_has_begun);
know (sec->filepos != 0);
if (! bfd_ecoff_write_debug (stdoutput, &debug, debug_swap,
@@ -2204,7 +2037,7 @@ elf_frob_file_after_relocs ()
#ifdef SCO_ELF
-/* Heavily plagarized from obj_elf_version. The idea is to emit the
+/* Heavily plagiarized from obj_elf_version. The idea is to emit the
SCO specific identifier in the .notes section to satisfy the SCO
linker.
@@ -2224,7 +2057,7 @@ elf_frob_file_after_relocs ()
int_32 version = (major ver # << 16) | version of tools ;
int_32 source = (tool_id << 16 ) | 1 ;
int_32 info = 0 ; These are set by the SCO tools, but we
- don't know enough about the source
+ don't know enough about the source
environment to set them. SCO ld currently
ignores them, and recommends we set them
to zero. */
@@ -2233,7 +2066,7 @@ elf_frob_file_after_relocs ()
#define SCO_MINOR_VERSION 0x1
void
-sco_id ()
+sco_id (void)
{
char *name;
@@ -2244,7 +2077,7 @@ sco_id ()
subsegT subseg = now_subseg;
Elf_Internal_Note i_note;
Elf_External_Note e_note;
- asection *note_secp = (asection *) NULL;
+ asection *note_secp = NULL;
int i, len;
/* create the .note section */
@@ -2261,13 +2094,13 @@ sco_id ()
i_note.type = NT_VERSION; /* Contains a version string */
p = frag_more (sizeof (i_note.namesz));
- md_number_to_chars (p, (valueT) i_note.namesz, 4);
+ md_number_to_chars (p, i_note.namesz, 4);
p = frag_more (sizeof (i_note.descsz));
- md_number_to_chars (p, (valueT) i_note.descsz, 4);
+ md_number_to_chars (p, i_note.descsz, 4);
p = frag_more (sizeof (i_note.type));
- md_number_to_chars (p, (valueT) i_note.type, 4);
+ md_number_to_chars (p, i_note.type, 4);
p = frag_more (4);
strcpy (p, "SCO");
@@ -2300,7 +2133,7 @@ sco_id ()
#endif /* SCO_ELF */
static int
-elf_separate_stab_sections ()
+elf_separate_stab_sections (void)
{
#ifdef NEED_ECOFF_DEBUG
return (!ECOFF_DEBUGGING);
@@ -2310,8 +2143,7 @@ elf_separate_stab_sections ()
}
static void
-elf_init_stab_section (seg)
- segT seg;
+elf_init_stab_section (segT seg)
{
#ifdef NEED_ECOFF_DEBUG
if (!ECOFF_DEBUGGING)
@@ -2329,6 +2161,7 @@ const struct format_ops elf_format_ops =
elf_frob_symbol,
elf_frob_file,
elf_frob_file_before_adjust,
+ 0, /* obj_frob_file_before_fix */
elf_frob_file_after_relocs,
elf_s_get_size, elf_s_set_size,
elf_s_get_align, elf_s_set_align,
diff --git a/contrib/binutils/gas/config/obj-elf.h b/contrib/binutils/gas/config/obj-elf.h
index 6197bf1..e713797 100644
--- a/contrib/binutils/gas/config/obj-elf.h
+++ b/contrib/binutils/gas/config/obj-elf.h
@@ -1,6 +1,6 @@
/* ELF object file format.
- Copyright 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
- Free Software Foundation, Inc.
+ Copyright 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
+ 2002, 2003 Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -100,7 +100,7 @@ struct elf_obj_sy
#ifndef obj_begin
#define obj_begin() elf_begin ()
#endif
-extern void elf_begin PARAMS ((void));
+extern void elf_begin (void);
/* should be conditional on address size! */
#define elf_symbol(asymbol) ((elf_symbol_type *) (&(asymbol)->the_bfd))
@@ -123,7 +123,7 @@ extern void elf_begin PARAMS ((void));
(elf_symbol (symbol_get_bfdsym (S))->internal_elf_sym.st_value = (V))
#endif
-int elf_s_get_other PARAMS ((symbolS *));
+int elf_s_get_other (symbolS *);
#ifndef S_GET_OTHER
#define S_GET_OTHER(S) (elf_s_get_other (S))
#endif
@@ -134,54 +134,63 @@ int elf_s_get_other PARAMS ((symbolS *));
extern asection *gdb_section;
+#ifndef obj_sec_set_private_data
+#define obj_sec_set_private_data(B, S) \
+ if (! BFD_SEND ((B), _new_section_hook, ((B), (S)))) \
+ as_fatal (_("can't allocate ELF private section data: %s"), \
+ bfd_errmsg (bfd_get_error ()))
+#endif
+
#ifndef obj_frob_file
#define obj_frob_file elf_frob_file
#endif
-extern void elf_frob_file PARAMS ((void));
+extern void elf_frob_file (void);
#ifndef obj_frob_file_before_adjust
#define obj_frob_file_before_adjust elf_frob_file_before_adjust
#endif
-extern void elf_frob_file_before_adjust PARAMS ((void));
+extern void elf_frob_file_before_adjust (void);
#ifndef obj_frob_file_after_relocs
#define obj_frob_file_after_relocs elf_frob_file_after_relocs
#endif
-extern void elf_frob_file_after_relocs PARAMS ((void));
+extern void elf_frob_file_after_relocs (void);
#ifndef obj_app_file
#define obj_app_file elf_file_symbol
#endif
-extern void elf_file_symbol PARAMS ((const char *));
+extern void elf_file_symbol (const char *);
-extern void obj_elf_section_change_hook PARAMS ((void));
+extern void obj_elf_section_change_hook (void);
-extern void obj_elf_section PARAMS ((int));
-extern void obj_elf_previous PARAMS ((int));
-extern void obj_elf_version PARAMS ((int));
-extern void obj_elf_common PARAMS ((int));
-extern void obj_elf_data PARAMS ((int));
-extern void obj_elf_text PARAMS ((int));
-extern struct fix *obj_elf_vtable_inherit PARAMS ((int));
-extern struct fix *obj_elf_vtable_entry PARAMS ((int));
+extern void obj_elf_section (int);
+extern void obj_elf_previous (int);
+extern void obj_elf_version (int);
+extern void obj_elf_common (int);
+extern void obj_elf_data (int);
+extern void obj_elf_text (int);
+extern void obj_elf_change_section
+ (const char *, int, int, int, const char *, int, int);
+extern struct fix *obj_elf_vtable_inherit (int);
+extern struct fix *obj_elf_vtable_entry (int);
/* BFD wants to write the udata field, which is a no-no for the
- globally defined sections. */
+ predefined section symbols in bfd/section.c. They are read-only. */
#ifndef obj_sec_sym_ok_for_reloc
#define obj_sec_sym_ok_for_reloc(SEC) ((SEC)->owner != 0)
#endif
-void elf_obj_read_begin_hook PARAMS ((void));
+void elf_obj_read_begin_hook (void);
#ifndef obj_read_begin_hook
#define obj_read_begin_hook elf_obj_read_begin_hook
#endif
-void elf_obj_symbol_new_hook PARAMS ((symbolS *));
+void elf_obj_symbol_new_hook (symbolS *);
#ifndef obj_symbol_new_hook
#define obj_symbol_new_hook elf_obj_symbol_new_hook
#endif
-void elf_copy_symbol_attributes PARAMS ((symbolS *, symbolS *));
+void elf_copy_symbol_attributes (symbolS *, symbolS *);
#ifndef OBJ_COPY_SYMBOL_ATTRIBUTES
#define OBJ_COPY_SYMBOL_ATTRIBUTES(DEST, SRC) \
(elf_copy_symbol_attributes (DEST, SRC))
@@ -198,7 +207,7 @@ void elf_copy_symbol_attributes PARAMS ((symbolS *, symbolS *));
/* We need 12 bytes at the start of the section to hold some initial
information. */
-extern void obj_elf_init_stab_section PARAMS ((segT));
+extern void obj_elf_init_stab_section (segT);
#define INIT_STAB_SECTION(seg) obj_elf_init_stab_section (seg)
#ifdef ECOFF_DEBUGGING
@@ -220,12 +229,12 @@ extern void obj_elf_init_stab_section PARAMS ((segT));
#endif /* SEPARATE_STAB_SECTIONS not defined. */
-extern void elf_frob_symbol PARAMS ((symbolS *, int *));
+extern void elf_frob_symbol (symbolS *, int *);
#ifndef obj_frob_symbol
#define obj_frob_symbol(symp, punt) elf_frob_symbol (symp, &punt)
#endif
-extern void elf_pop_insert PARAMS ((void));
+extern void elf_pop_insert (void);
#ifndef obj_pop_insert
#define obj_pop_insert() elf_pop_insert()
#endif
@@ -235,7 +244,7 @@ extern void elf_pop_insert PARAMS ((void));
#ifdef ANSI_PROTOTYPES
struct ecoff_extr;
#endif
-extern void elf_ecoff_set_ext PARAMS ((symbolS *, struct ecoff_extr *));
+extern void elf_ecoff_set_ext (symbolS *, struct ecoff_extr *);
#endif
#endif /* _OBJ_ELF_H */
diff --git a/contrib/binutils/gas/config/obj-ieee.c b/contrib/binutils/gas/config/obj-ieee.c
index 1846a92..02f4339 100644
--- a/contrib/binutils/gas/config/obj-ieee.c
+++ b/contrib/binutils/gas/config/obj-ieee.c
@@ -264,7 +264,7 @@ do_relocs_for (idx)
from = from->fx_next;
}
- /* Attatch to the section. */
+ /* Attach to the section. */
section->orelocation = reloc_ptr_vector;
section->reloc_count = nrelocs;
section->flags |= SEC_LOAD;
@@ -467,10 +467,6 @@ ok:
input_line_pointer = p;
}
-void cons ();
-void s_ignore ();
-
-void s_globl ();
const pseudo_typeS obj_pseudo_table[] =
{
{"section", obj_ieee_section, 0},
@@ -496,7 +492,7 @@ obj_symbol_new_hook (symbolP)
#ifndef SUB_SEGMENT_ALIGN
#ifdef HANDLE_ALIGN
-/* The last subsegment gets an aligment corresponding to the alignment
+/* The last subsegment gets an alignment corresponding to the alignment
of the section. This allows proper nop-filling at the end of
code-bearing sections. */
#define SUB_SEGMENT_ALIGN(SEG, FRCHAIN) \
diff --git a/contrib/binutils/gas/config/obj-ieee.h b/contrib/binutils/gas/config/obj-ieee.h
index 2652bc2..c0bd628 100644
--- a/contrib/binutils/gas/config/obj-ieee.h
+++ b/contrib/binutils/gas/config/obj-ieee.h
@@ -1,5 +1,5 @@
/* This file is obj-ieee.h
- Copyright 1987, 1988, 1989, 1990, 1991, 1992, 2000
+ Copyright 1987, 1988, 1989, 1990, 1991, 1992, 2000, 2002, 2003
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -28,16 +28,19 @@ typedef struct
asymbol sy;
int seg;
}
-
obj_symbol_type;
#define S_GET_NAME(s) (((s)->sy_symbol.sy.name))
+/* Return true for symbols that should not be reduced to section
+ symbols or eliminated from expressions, because they may be
+ overridden by the linker. */
+#define S_FORCE_RELOC(s, strict) (!SEG_NORMAL (x->sy_symbol.seg))
+
typedef struct
{
int x;
}
-
object_headers;
#define DEFAULT_MAGIC_NUMBER_FOR_OBJECT_FILE 1
diff --git a/contrib/binutils/gas/config/obj-multi.h b/contrib/binutils/gas/config/obj-multi.h
index 225de2c..37d9fe8 100644
--- a/contrib/binutils/gas/config/obj-multi.h
+++ b/contrib/binutils/gas/config/obj-multi.h
@@ -1,5 +1,5 @@
/* Multiple object format emulation.
- Copyright 1995, 1996, 1997, 1999, 2000
+ Copyright 1995, 1996, 1997, 1999, 2000, 2002
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -55,6 +55,11 @@
? (*this_format->frob_file_before_adjust) () \
: (void) 0)
+#define obj_frob_file_before_fix() \
+ (this_format->frob_file_before_fix \
+ ? (*this_format->frob_file_before_fix) () \
+ : (void) 0)
+
#define obj_frob_file_after_relocs() \
(this_format->frob_file_after_relocs \
? (*this_format->frob_file_after_relocs) () \
diff --git a/contrib/binutils/gas/config/tc-alpha.c b/contrib/binutils/gas/config/tc-alpha.c
index b9faadf..9360047 100644
--- a/contrib/binutils/gas/config/tc-alpha.c
+++ b/contrib/binutils/gas/config/tc-alpha.c
@@ -1,6 +1,6 @@
/* tc-alpha.c - Processor-specific code for the DEC Alpha AXP CPU.
Copyright 1989, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
- 2001, 2002 Free Software Foundation, Inc.
+ 2001, 2002, 2003 Free Software Foundation, Inc.
Contributed by Carnegie Mellon University, 1993.
Written by Alessandro Forin, based on earlier gas-1.38 target CPU files.
Modified by Ken Raeburn for gas-2.x and ECOFF support.
@@ -60,11 +60,12 @@
#ifdef OBJ_ELF
#include "elf/alpha.h"
#include "dwarf2dbg.h"
+#include "dw2gencfi.h"
#endif
#include "safe-ctype.h"
-/* Local types */
+/* Local types. */
#define TOKENIZE_ERROR -1
#define TOKENIZE_ERROR_REPORT -2
@@ -72,29 +73,33 @@
#define MAX_INSN_FIXUPS 2
#define MAX_INSN_ARGS 5
-struct alpha_fixup {
+struct alpha_fixup
+{
expressionS exp;
bfd_reloc_code_real_type reloc;
};
-struct alpha_insn {
+struct alpha_insn
+{
unsigned insn;
int nfixups;
struct alpha_fixup fixups[MAX_INSN_FIXUPS];
long sequence;
};
-enum alpha_macro_arg {
- MACRO_EOA = 1,
- MACRO_IR,
- MACRO_PIR,
- MACRO_OPIR,
- MACRO_CPIR,
- MACRO_FPR,
- MACRO_EXP,
-};
+enum alpha_macro_arg
+ {
+ MACRO_EOA = 1,
+ MACRO_IR,
+ MACRO_PIR,
+ MACRO_OPIR,
+ MACRO_CPIR,
+ MACRO_FPR,
+ MACRO_EXP,
+ };
-struct alpha_macro {
+struct alpha_macro
+{
const char *name;
void (*emit) PARAMS ((const expressionS *, int, const PTR));
const PTR arg;
@@ -139,13 +144,13 @@ struct alpha_macro {
#define USER_RELOC_P(R) ((R) >= O_literal && (R) <= O_tprel)
-/* Macros for extracting the type and number of encoded register tokens */
+/* Macros for extracting the type and number of encoded register tokens. */
#define is_ir_num(x) (((x) & 32) == 0)
#define is_fpr_num(x) (((x) & 32) != 0)
#define regno(x) ((x) & 31)
-/* Something odd inherited from the old assembler */
+/* Something odd inherited from the old assembler. */
#define note_gpreg(R) (alpha_gprmask |= (1 << (R)))
#define note_fpreg(R) (alpha_fprmask |= (1 << (R)))
@@ -179,7 +184,7 @@ struct alpha_macro {
^ 0x80000000) - 0x80000000)
#endif
-/* Macros to build tokens */
+/* Macros to build tokens. */
#define set_tok_reg(t, r) (memset (&(t), 0, sizeof (t)), \
(t).X_op = O_register, \
@@ -201,10 +206,10 @@ struct alpha_macro {
(t).X_op = O_constant, \
(t).X_add_number = (n))
-/* Prototypes for all local functions */
+/* Prototypes for all local functions. */
static struct alpha_reloc_tag *get_alpha_reloc_tag PARAMS ((long));
-static void alpha_adjust_symtab_relocs PARAMS ((bfd *, asection *, PTR));
+static void alpha_adjust_relocs PARAMS ((bfd *, asection *, PTR));
static int tokenize_arguments PARAMS ((char *, expressionS *, int));
static const struct alpha_opcode *find_opcode_match
@@ -262,6 +267,7 @@ static void s_alpha_file PARAMS ((int));
static void s_alpha_loc PARAMS ((int));
static void s_alpha_stab PARAMS ((int));
static void s_alpha_coff_wrapper PARAMS ((int));
+static void s_alpha_usepv PARAMS ((int));
#endif
#ifdef OBJ_EVAX
static void s_alpha_section PARAMS ((int));
@@ -315,19 +321,20 @@ const char *md_shortopts = "Fm:g+1h:HG:";
const char *md_shortopts = "Fm:gG:";
#endif
-struct option md_longopts[] = {
+struct option md_longopts[] =
+ {
#define OPTION_32ADDR (OPTION_MD_BASE)
- { "32addr", no_argument, NULL, OPTION_32ADDR },
+ { "32addr", no_argument, NULL, OPTION_32ADDR },
#define OPTION_RELAX (OPTION_32ADDR + 1)
- { "relax", no_argument, NULL, OPTION_RELAX },
+ { "relax", no_argument, NULL, OPTION_RELAX },
#ifdef OBJ_ELF
#define OPTION_MDEBUG (OPTION_RELAX + 1)
#define OPTION_NO_MDEBUG (OPTION_MDEBUG + 1)
- { "mdebug", no_argument, NULL, OPTION_MDEBUG },
- { "no-mdebug", no_argument, NULL, OPTION_NO_MDEBUG },
+ { "mdebug", no_argument, NULL, OPTION_MDEBUG },
+ { "no-mdebug", no_argument, NULL, OPTION_NO_MDEBUG },
#endif
- { NULL, no_argument, NULL, 0 }
-};
+ { NULL, no_argument, NULL, 0 }
+ };
size_t md_longopts_size = sizeof (md_longopts);
@@ -351,34 +358,33 @@ size_t md_longopts_size = sizeof (md_longopts);
#define AXP_REG_GP AXP_REG_PV
#endif /* OBJ_EVAX */
-/* The cpu for which we are generating code */
+/* The cpu for which we are generating code. */
static unsigned alpha_target = AXP_OPCODE_BASE;
static const char *alpha_target_name = "<all>";
-/* The hash table of instruction opcodes */
+/* The hash table of instruction opcodes. */
static struct hash_control *alpha_opcode_hash;
-/* The hash table of macro opcodes */
+/* The hash table of macro opcodes. */
static struct hash_control *alpha_macro_hash;
#ifdef OBJ_ECOFF
-/* The $gp relocation symbol */
+/* The $gp relocation symbol. */
static symbolS *alpha_gp_symbol;
/* XXX: what is this, and why is it exported? */
valueT alpha_gp_value;
#endif
-/* The current $gp register */
+/* The current $gp register. */
static int alpha_gp_register = AXP_REG_GP;
-/* A table of the register symbols */
+/* A table of the register symbols. */
static symbolS *alpha_register_table[64];
-/* Constant sections, or sections of constants */
+/* Constant sections, or sections of constants. */
#ifdef OBJ_ECOFF
static segT alpha_lita_section;
-static segT alpha_lit4_section;
#endif
#ifdef OBJ_EVAX
static segT alpha_link_section;
@@ -390,7 +396,6 @@ static segT alpha_lit8_section;
/* Symbols referring to said sections. */
#ifdef OBJ_ECOFF
static symbolS *alpha_lita_symbol;
-static symbolS *alpha_lit4_symbol;
#endif
#ifdef OBJ_EVAX
static symbolS *alpha_link_symbol;
@@ -399,27 +404,21 @@ static symbolS *alpha_dtors_symbol;
#endif
static symbolS *alpha_lit8_symbol;
-/* Literal for .litX+0x8000 within .lita */
+/* Literal for .litX+0x8000 within .lita. */
#ifdef OBJ_ECOFF
-static offsetT alpha_lit4_literal;
static offsetT alpha_lit8_literal;
#endif
-#ifdef OBJ_ELF
-/* The active .ent symbol. */
-static symbolS *alpha_cur_ent_sym;
-#endif
-
-/* Is the assembler not allowed to use $at? */
+/* Is the assembler not allowed to use $at? */
static int alpha_noat_on = 0;
-/* Are macros enabled? */
+/* Are macros enabled? */
static int alpha_macros_on = 1;
-/* Are floats disabled? */
+/* Are floats disabled? */
static int alpha_nofloats_on = 0;
-/* Are addresses 32 bit? */
+/* Are addresses 32 bit? */
static int alpha_addr32_on = 0;
/* Symbol labelling the current insn. When the Alpha gas sees
@@ -473,8 +472,7 @@ static int alpha_flag_hash_long_names = 0; /* -+ */
static int alpha_flag_show_after_trunc = 0; /* -H */
/* If the -+ switch is given, then a hash is appended to any name that is
- * longer than 64 characters, else longer symbol names are truncated.
- */
+ longer than 64 characters, else longer symbol names are truncated. */
#endif
@@ -491,14 +489,17 @@ static int alpha_flag_show_after_trunc = 0; /* -H */
#define DEF(NAME, RELOC, REQ, ALLOW) \
{ #NAME, sizeof(#NAME)-1, O_##NAME, RELOC, REQ, ALLOW}
-static const struct alpha_reloc_op_tag {
+static const struct alpha_reloc_op_tag
+{
const char *name; /* string to lookup */
size_t length; /* size of the string */
operatorT op; /* which operator to use */
bfd_reloc_code_real_type reloc; /* relocation before frob */
unsigned int require_seq : 1; /* require a sequence number */
unsigned int allow_seq : 1; /* allow a sequence number */
-} alpha_reloc_op[] = {
+}
+alpha_reloc_op[] =
+{
DEF(literal, BFD_RELOC_ALPHA_ELF_LITERAL, 0, 1),
DEF(lituse_addr, DUMMY_RELOC_LITUSE_ADDR, 1, 1),
DEF(lituse_base, DUMMY_RELOC_LITUSE_BASE, 1, 1),
@@ -532,7 +533,7 @@ static const int alpha_num_reloc_op
/* Maximum # digits needed to hold the largest sequence # */
#define ALPHA_RELOC_DIGITS 25
-/* Structure to hold explict sequence information. */
+/* Structure to hold explicit sequence information. */
struct alpha_reloc_tag
{
fixS *master; /* the literal reloc */
@@ -557,10 +558,13 @@ static long next_sequence_num = -1;
/* A table of CPU names and opcode sets. */
-static const struct cpu_type {
+static const struct cpu_type
+{
const char *name;
unsigned flags;
-} cpu_types[] = {
+}
+cpu_types[] =
+{
/* Ad hoc convention: cpu number gets palcode, process code doesn't.
This supports usage under DU 4.0b that does ".arch ev4", and
usage in MILO that does -m21064. Probably something more
@@ -597,7 +601,8 @@ static const struct cpu_type {
/* The macro table */
-static const struct alpha_macro alpha_macros[] = {
+static const struct alpha_macro alpha_macros[] =
+{
/* Load/Store macros */
{ "lda", emit_lda, NULL,
{ MACRO_IR, MACRO_EXP, MACRO_OPIR, MACRO_EOA } },
@@ -809,8 +814,7 @@ md_begin ()
assert (e.X_op == O_max);
}
- /* Create the opcode hash table */
-
+ /* Create the opcode hash table. */
alpha_opcode_hash = hash_new ();
for (i = 0; i < alpha_num_opcodes;)
{
@@ -844,8 +848,7 @@ md_begin ()
continue;
}
- /* Create the macro hash table */
-
+ /* Create the macro hash table. */
alpha_macro_hash = hash_new ();
for (i = 0; i < alpha_num_macros;)
{
@@ -863,11 +866,11 @@ md_begin ()
continue;
}
- /* Construct symbols for each of the registers */
-
+ /* Construct symbols for each of the registers. */
for (i = 0; i < 32; ++i)
{
char name[4];
+
sprintf (name, "$%d", i);
alpha_register_table[i] = symbol_create (name, reg_section, i,
&zero_address_frag);
@@ -875,12 +878,13 @@ md_begin ()
for (; i < 64; ++i)
{
char name[5];
+
sprintf (name, "$f%d", i - 32);
alpha_register_table[i] = symbol_create (name, reg_section, i,
&zero_address_frag);
}
- /* Create the special symbols and sections we'll be using */
+ /* Create the special symbols and sections we'll be using. */
/* So .sbss will get used for tiny objects. */
bfd_set_gp_size (stdoutput, g_switch_value);
@@ -919,12 +923,12 @@ void
md_assemble (str)
char *str;
{
- char opname[32]; /* current maximum is 13 */
+ char opname[32]; /* Current maximum is 13. */
expressionS tok[MAX_INSN_ARGS];
int ntok, trunclen;
size_t opnamelen;
- /* split off the opcode */
+ /* Split off the opcode. */
opnamelen = strspn (str, "abcdefghijklmnopqrstuvwxyz_/46819");
trunclen = (opnamelen < sizeof (opname) - 1
? opnamelen
@@ -932,7 +936,7 @@ md_assemble (str)
memcpy (opname, str, trunclen);
opname[trunclen] = '\0';
- /* tokenize the rest of the line */
+ /* Tokenize the rest of the line. */
if ((ntok = tokenize_arguments (str + opnamelen, tok, MAX_INSN_ARGS)) < 0)
{
if (ntok != TOKENIZE_ERROR_REPORT)
@@ -941,7 +945,7 @@ md_assemble (str)
return;
}
- /* finish it off */
+ /* Finish it off. */
assemble_tokens (opname, tok, ntok, alpha_macros_on);
}
@@ -963,7 +967,7 @@ md_section_align (seg, size)
of LITTLENUMS emitted is stored in *SIZEP. An error message is
returned, or NULL on OK. */
-/* Equal to MAX_PRECISION in atof-ieee.c */
+/* Equal to MAX_PRECISION in atof-ieee.c. */
#define MAX_LITTLENUMS 6
extern char *vax_md_atof PARAMS ((int, char *, int *));
@@ -1132,12 +1136,12 @@ md_pcrel_from (fixP)
valueT addr = fixP->fx_where + fixP->fx_frag->fr_address;
switch (fixP->fx_r_type)
{
- case BFD_RELOC_ALPHA_GPDISP:
- case BFD_RELOC_ALPHA_GPDISP_HI16:
- case BFD_RELOC_ALPHA_GPDISP_LO16:
- return addr;
+ case BFD_RELOC_23_PCREL_S2:
+ case BFD_RELOC_ALPHA_HINT:
+ case BFD_RELOC_ALPHA_BRSGP:
+ return addr + 4;
default:
- return fixP->fx_size + addr;
+ return addr;
}
}
@@ -1164,9 +1168,9 @@ md_apply_fix3 (fixP, valP, seg)
switch (fixP->fx_r_type)
{
/* The GPDISP relocations are processed internally with a symbol
- referring to the current function; we need to drop in a value
- which, when added to the address of the start of the function,
- gives the desired GP. */
+ referring to the current function's section; we need to drop
+ in a value which, when added to the address of the start of
+ the function, gives the desired GP. */
case BFD_RELOC_ALPHA_GPDISP_HI16:
{
fixS *next = fixP->fx_next;
@@ -1254,6 +1258,8 @@ md_apply_fix3 (fixP, valP, seg)
#ifdef OBJ_ELF
case BFD_RELOC_ALPHA_BRSGP:
+ return;
+
case BFD_RELOC_ALPHA_TLSGD:
case BFD_RELOC_ALPHA_TLSLDM:
case BFD_RELOC_ALPHA_GOTDTPREL16:
@@ -1264,6 +1270,8 @@ md_apply_fix3 (fixP, valP, seg)
case BFD_RELOC_ALPHA_TPREL_HI16:
case BFD_RELOC_ALPHA_TPREL_LO16:
case BFD_RELOC_ALPHA_TPREL16:
+ if (fixP->fx_addsy)
+ S_SET_THREAD_LOCAL (fixP->fx_addsy);
return;
#endif
@@ -1437,8 +1445,6 @@ alpha_force_relocation (f)
case BFD_RELOC_ALPHA_LINKAGE:
case BFD_RELOC_ALPHA_CODEADDR:
case BFD_RELOC_ALPHA_BRSGP:
- case BFD_RELOC_VTABLE_INHERIT:
- case BFD_RELOC_VTABLE_ENTRY:
case BFD_RELOC_ALPHA_TLSGD:
case BFD_RELOC_ALPHA_TLSLDM:
case BFD_RELOC_ALPHA_GOTDTPREL16:
@@ -1451,15 +1457,11 @@ alpha_force_relocation (f)
case BFD_RELOC_ALPHA_TPREL16:
return 1;
- case BFD_RELOC_23_PCREL_S2:
- case BFD_RELOC_32:
- case BFD_RELOC_64:
- case BFD_RELOC_ALPHA_HINT:
- return 0;
-
default:
- return 0;
+ break;
}
+
+ return generic_force_reloc (f);
}
/* Return true if we can partially resolve a relocation now. */
@@ -1468,12 +1470,6 @@ int
alpha_fix_adjustable (f)
fixS *f;
{
-#ifdef OBJ_ELF
- /* Prevent all adjustments to global symbols */
- if (S_IS_EXTERN (f->fx_addsy) || S_IS_WEAK (f->fx_addsy))
- return 0;
-#endif
-
/* Are there any relocation types for which we must generate a reloc
but we can adjust the values contained within it? */
switch (f->fx_r_type)
@@ -1518,6 +1514,7 @@ alpha_fix_adjustable (f)
we're preventing this in the other assemblers. Follow for now. */
return 0;
+#ifdef OBJ_ELF
case BFD_RELOC_ALPHA_BRSGP:
/* If we have a BRSGP reloc to a local symbol, adjust it to BRADDR and
let it get resolved at assembly time. */
@@ -1526,7 +1523,7 @@ alpha_fix_adjustable (f)
const char *name;
int offset = 0;
- if (! S_IS_DEFINED (sym))
+ if (generic_force_reloc (f))
return 0;
switch (S_GET_OTHER (sym) & STO_ALPHA_STD_GPLOAD)
@@ -1550,6 +1547,7 @@ alpha_fix_adjustable (f)
f->fx_offset += offset;
return 1;
}
+#endif
default:
return 1;
@@ -1595,7 +1593,7 @@ tc_gen_reloc (sec, fixp)
#ifdef OBJ_ECOFF
if (fixp->fx_r_type == BFD_RELOC_ALPHA_LITERAL)
{
- /* fake out bfd_perform_relocation. sigh */
+ /* Fake out bfd_perform_relocation. sigh. */
reloc->addend = -alpha_gp_value;
}
else
@@ -1603,12 +1601,10 @@ tc_gen_reloc (sec, fixp)
{
reloc->addend = fixp->fx_offset;
#ifdef OBJ_ELF
- /*
- * Ohhh, this is ugly. The problem is that if this is a local global
- * symbol, the relocation will entirely be performed at link time, not
- * at assembly time. bfd_perform_reloc doesn't know about this sort
- * of thing, and as a result we need to fake it out here.
- */
+ /* Ohhh, this is ugly. The problem is that if this is a local global
+ symbol, the relocation will entirely be performed at link time, not
+ at assembly time. bfd_perform_reloc doesn't know about this sort
+ of thing, and as a result we need to fake it out here. */
if ((S_IS_EXTERN (fixp->fx_addsy) || S_IS_WEAK (fixp->fx_addsy)
|| (S_GET_SEGMENT (fixp->fx_addsy)->flags & SEC_MERGE)
|| (S_GET_SEGMENT (fixp->fx_addsy)->flags & SEC_THREAD_LOCAL))
@@ -1703,14 +1699,14 @@ get_alpha_reloc_tag (sequence)
relocations, and similarly for !gpdisp relocations. */
void
-alpha_adjust_symtab ()
+alpha_before_fix ()
{
if (alpha_literal_hash)
- bfd_map_over_sections (stdoutput, alpha_adjust_symtab_relocs, NULL);
+ bfd_map_over_sections (stdoutput, alpha_adjust_relocs, NULL);
}
static void
-alpha_adjust_symtab_relocs (abfd, sec, ptr)
+alpha_adjust_relocs (abfd, sec, ptr)
bfd *abfd ATTRIBUTE_UNUSED;
asection *sec;
PTR ptr ATTRIBUTE_UNUSED;
@@ -1731,7 +1727,7 @@ alpha_adjust_symtab_relocs (abfd, sec, ptr)
if (! seginfo->fix_root)
return;
- /* First rebuild the fixup chain without the expicit lituse and
+ /* First rebuild the fixup chain without the explicit lituse and
gpdisp_lo16 relocs. */
prevP = &seginfo->fix_root;
for (fixp = seginfo->fix_root; fixp; fixp = next)
@@ -1746,6 +1742,7 @@ alpha_adjust_symtab_relocs (abfd, sec, ptr)
as_bad_where (fixp->fx_file, fixp->fx_line,
_("No !literal!%ld was found"),
fixp->tc_fix_data.info->sequence);
+#ifdef RELOC_OP_P
if (fixp->fx_offset == LITUSE_ALPHA_TLSGD)
{
if (! fixp->tc_fix_data.info->saw_tlsgd)
@@ -1760,6 +1757,7 @@ alpha_adjust_symtab_relocs (abfd, sec, ptr)
_("No !tlsldm!%ld was found"),
fixp->tc_fix_data.info->sequence);
}
+#endif
break;
case BFD_RELOC_ALPHA_GPDISP_LO16:
@@ -1874,6 +1872,7 @@ debug_exp (tok, ntok)
{
expressionS *t = &tok[i];
const char *name;
+
switch (t->X_op)
{
default: name = "unknown"; break;
@@ -1957,15 +1956,17 @@ tokenize_arguments (str, tok, ntok)
#ifdef DEBUG_ALPHA
expressionS *orig_tok = tok;
#endif
+#ifdef RELOC_OP_P
char *p;
const struct alpha_reloc_op_tag *r;
int c, i;
size_t len;
int reloc_found_p = 0;
+#endif
memset (tok, 0, sizeof (*tok) * ntok);
- /* Save and restore input_line_pointer around this function */
+ /* Save and restore input_line_pointer around this function. */
old_input_line_pointer = input_line_pointer;
input_line_pointer = str;
@@ -1988,7 +1989,8 @@ tokenize_arguments (str, tok, ntok)
assembly language statement, and has the following form:
!relocation_type!sequence_number. */
if (reloc_found_p)
- { /* only support one relocation op per insn */
+ {
+ /* Only support one relocation op per insn. */
as_bad (_("More than one relocation op per insn"));
goto err_report;
}
@@ -2001,7 +2003,7 @@ tokenize_arguments (str, tok, ntok)
p = input_line_pointer;
c = get_symbol_end ();
- /* Parse !relocation_type */
+ /* Parse !relocation_type. */
len = input_line_pointer - p;
if (len == 0)
{
@@ -2041,7 +2043,7 @@ tokenize_arguments (str, tok, ntok)
input_line_pointer++;
- /* Parse !sequence_number */
+ /* Parse !sequence_number. */
expression (tok);
if (tok->X_op != O_constant || tok->X_add_number <= 0)
{
@@ -2080,7 +2082,7 @@ tokenize_arguments (str, tok, ntok)
break;
}
- /* ... then fall through to plain expression */
+ /* ... then fall through to plain expression. */
input_line_pointer = hold;
}
@@ -2120,8 +2122,8 @@ err:
input_line_pointer = old_input_line_pointer;
return TOKENIZE_ERROR;
-err_report:
#ifdef RELOC_OP_P
+err_report:
is_end_of_line[(unsigned char) '!'] = 0;
#endif
input_line_pointer = old_input_line_pointer;
@@ -2147,7 +2149,7 @@ find_opcode_match (first_opcode, tok, pntok, pcpumatch)
const unsigned char *opidx;
int tokidx = 0;
- /* Don't match opcodes that don't exist on this architecture */
+ /* Don't match opcodes that don't exist on this architecture. */
if (!(opcode->flags & alpha_target))
goto match_failed;
@@ -2157,11 +2159,11 @@ find_opcode_match (first_opcode, tok, pntok, pcpumatch)
{
const struct alpha_operand *operand = &alpha_operands[*opidx];
- /* only take input from real operands */
+ /* Only take input from real operands. */
if (operand->flags & AXP_OPERAND_FAKE)
continue;
- /* when we expect input, make sure we have it */
+ /* When we expect input, make sure we have it. */
if (tokidx >= ntok)
{
if ((operand->flags & AXP_OPERAND_OPTIONAL_MASK) == 0)
@@ -2169,7 +2171,7 @@ find_opcode_match (first_opcode, tok, pntok, pcpumatch)
continue;
}
- /* match operand type with expression type */
+ /* Match operand type with expression type. */
switch (operand->flags & AXP_OPERAND_TYPECHECK_MASK)
{
case AXP_OPERAND_IR:
@@ -2211,13 +2213,13 @@ find_opcode_match (first_opcode, tok, pntok, pcpumatch)
break;
default:
- /* everything else should have been fake */
+ /* Everything else should have been fake. */
abort ();
}
++tokidx;
}
- /* possible match -- did we use all of our input? */
+ /* Possible match -- did we use all of our input? */
if (tokidx == ntok)
{
*pntok = ntok;
@@ -2226,7 +2228,7 @@ find_opcode_match (first_opcode, tok, pntok, pcpumatch)
match_failed:;
}
- while (++opcode - alpha_opcodes < alpha_num_opcodes
+ while (++opcode - alpha_opcodes < (int) alpha_num_opcodes
&& !strcmp (opcode->name, first_opcode->name));
if (*pcpumatch)
@@ -2263,7 +2265,7 @@ find_macro_match (first_macro, tok, pntok)
tokidx = 0;
break;
- /* index register */
+ /* Index register. */
case MACRO_IR:
if (tokidx >= ntok || tok[tokidx].X_op != O_register
|| !is_ir_num (tok[tokidx].X_add_number))
@@ -2271,7 +2273,7 @@ find_macro_match (first_macro, tok, pntok)
++tokidx;
break;
- /* parenthesized index register */
+ /* Parenthesized index register. */
case MACRO_PIR:
if (tokidx >= ntok || tok[tokidx].X_op != O_pregister
|| !is_ir_num (tok[tokidx].X_add_number))
@@ -2279,14 +2281,14 @@ find_macro_match (first_macro, tok, pntok)
++tokidx;
break;
- /* optional parenthesized index register */
+ /* Optional parenthesized index register. */
case MACRO_OPIR:
if (tokidx < ntok && tok[tokidx].X_op == O_pregister
&& is_ir_num (tok[tokidx].X_add_number))
++tokidx;
break;
- /* leading comma with a parenthesized index register */
+ /* Leading comma with a parenthesized index register. */
case MACRO_CPIR:
if (tokidx >= ntok || tok[tokidx].X_op != O_cpregister
|| !is_ir_num (tok[tokidx].X_add_number))
@@ -2294,7 +2296,7 @@ find_macro_match (first_macro, tok, pntok)
++tokidx;
break;
- /* floating point register */
+ /* Floating point register. */
case MACRO_FPR:
if (tokidx >= ntok || tok[tokidx].X_op != O_register
|| !is_fpr_num (tok[tokidx].X_add_number))
@@ -2302,7 +2304,7 @@ find_macro_match (first_macro, tok, pntok)
++tokidx;
break;
- /* normal expression */
+ /* Normal expression. */
case MACRO_EXP:
if (tokidx >= ntok)
goto match_failed;
@@ -2339,7 +2341,7 @@ find_macro_match (first_macro, tok, pntok)
++arg;
}
}
- while (++macro - alpha_macros < alpha_num_macros
+ while (++macro - alpha_macros < (int) alpha_num_macros
&& !strcmp (macro->name, first_macro->name));
return NULL;
@@ -2398,10 +2400,8 @@ insert_operand (insn, operand, val, file, line)
return insn;
}
-/*
- * Turn an opcode description and a set of arguments into
- * an instruction and a fixup.
- */
+/* Turn an opcode description and a set of arguments into
+ an instruction and a fixup. */
static void
assemble_insn (opcode, tok, ntok, insn, reloc)
@@ -2550,9 +2550,7 @@ assemble_insn (opcode, tok, ntok, insn, reloc)
insn->insn = image;
}
-/*
- * Actually output an instruction with its fixup.
- */
+/* Actually output an instruction with its fixup. */
static void
emit_insn (insn)
@@ -2576,7 +2574,7 @@ emit_insn (insn)
dwarf2_emit_insn (4);
#endif
- /* Apply the fixups in order */
+ /* Apply the fixups in order. */
for (i = 0; i < insn->nfixups; ++i)
{
const struct alpha_operand *operand = (const struct alpha_operand *) 0;
@@ -2585,7 +2583,7 @@ emit_insn (insn)
int size, pcrel;
fixS *fixP;
- /* Some fixups are only used internally and so have no howto */
+ /* Some fixups are only used internally and so have no howto. */
if ((int) fixup->reloc < 0)
{
operand = &alpha_operands[-(int) fixup->reloc];
@@ -2675,6 +2673,7 @@ emit_insn (insn)
fixP->tc_fix_data.info = info;
break;
+#ifdef RELOC_OP_P
case DUMMY_RELOC_LITUSE_ADDR:
fixP->fx_offset = LITUSE_ALPHA_ADDR;
goto do_lituse;
@@ -2749,7 +2748,7 @@ emit_insn (insn)
info->saw_tlsldm = 1;
fixP->tc_fix_data.info = info;
break;
-
+#endif
default:
if ((int) fixup->reloc < 0)
{
@@ -2838,7 +2837,7 @@ assemble_tokens (opname, tok, ntok, local_macros_on)
}
}
- /* search opcodes */
+ /* Search opcodes. */
opcode = (const struct alpha_opcode *) hash_find (alpha_opcode_hash, opname);
if (opcode)
{
@@ -2870,7 +2869,7 @@ assemble_tokens (opname, tok, ntok, local_macros_on)
as_bad (_("unknown opcode `%s'"), opname);
}
-/* Some instruction sets indexed by lg(size) */
+/* Some instruction sets indexed by lg(size). */
static const char * const sextX_op[] = { "sextb", "sextw", "sextl", NULL };
static const char * const insXl_op[] = { "insbl", "inswl", "insll", "insql" };
static const char * const insXh_op[] = { NULL, "inswh", "inslh", "insqh" };
@@ -3015,7 +3014,7 @@ add_to_link_pool (basesym, sym, addend)
but this is what OSF/1 does.
If explicit relocations of the form !literal!<number> are allowed,
- and used, then explict_reloc with be an expression pointer.
+ and used, then explicit_reloc with be an expression pointer.
Finally, the return value is nonzero if the calling macro may emit
a LITUSE reloc if otherwise appropriate; the return value is the
@@ -3041,7 +3040,7 @@ load_expression (targreg, exp, pbasereg, poffset)
#ifdef OBJ_ECOFF
offsetT lit;
- /* attempt to reduce .lit load by splitting the offset from
+ /* Attempt to reduce .lit load by splitting the offset from
its symbol when possible, but don't create a situation in
which we'd fail. */
if (!range_signed_32 (addend) &&
@@ -3366,7 +3365,7 @@ load_expression (targreg, exp, pbasereg, poffset)
}
/* The lda macro differs from the lda instruction in that it handles
- most simple expressions, particualrly symbol address loads and
+ most simple expressions, particularly symbol address loads and
large constants. */
static void
@@ -3893,19 +3892,18 @@ emit_division (tok, ntok, symname)
const PTR symname;
{
/* DIVISION and MODULUS. Yech.
- *
- * Convert
- * OP x,y,result
- * to
- * mov x,R16 # if x != R16
- * mov y,R17 # if y != R17
- * lda AT,__OP
- * jsr AT,(AT),0
- * mov R0,result
- *
- * with appropriate optimizations if R0,R16,R17 are the registers
- * specified by the compiler.
- */
+
+ Convert
+ OP x,y,result
+ to
+ mov x,R16 # if x != R16
+ mov y,R17 # if y != R17
+ lda AT,__OP
+ jsr AT,(AT),0
+ mov R0,result
+
+ with appropriate optimizations if R0,R16,R17 are the registers
+ specified by the compiler. */
int xr, yr, rr;
symbolS *sym;
@@ -3919,10 +3917,10 @@ emit_division (tok, ntok, symname)
else
rr = regno (tok[2].X_add_number);
- /* Move the operands into the right place */
+ /* Move the operands into the right place. */
if (yr == AXP_REG_R16 && xr == AXP_REG_R17)
{
- /* They are in exactly the wrong order -- swap through AT */
+ /* They are in exactly the wrong order -- swap through AT. */
if (alpha_noat_on)
as_bad (_("macro requires $at register while noat in effect"));
@@ -3969,13 +3967,13 @@ emit_division (tok, ntok, symname)
set_tok_sym (newtok[1], sym, 0);
assemble_tokens ("lda", newtok, 2, 1);
- /* Call the division routine */
+ /* Call the division routine. */
set_tok_reg (newtok[0], AXP_REG_AT);
set_tok_cpreg (newtok[1], AXP_REG_AT);
set_tok_const (newtok[2], 0);
assemble_tokens ("jsr", newtok, 3, 1);
- /* Move the result to the right place */
+ /* Move the result to the right place. */
if (rr != AXP_REG_R0)
{
set_tok_reg (newtok[0], AXP_REG_R0);
@@ -3993,18 +3991,17 @@ emit_division (tok, ntok, symname)
const PTR symname;
{
/* DIVISION and MODULUS. Yech.
- * Convert
- * OP x,y,result
- * to
- * lda pv,__OP
- * mov x,t10
- * mov y,t11
- * jsr t9,(pv),__OP
- * mov t12,result
- *
- * with appropriate optimizations if t10,t11,t12 are the registers
- * specified by the compiler.
- */
+ Convert
+ OP x,y,result
+ to
+ lda pv,__OP
+ mov x,t10
+ mov y,t11
+ jsr t9,(pv),__OP
+ mov t12,result
+
+ with appropriate optimizations if t10,t11,t12 are the registers
+ specified by the compiler. */
int xr, yr, rr;
symbolS *sym;
@@ -4020,11 +4017,10 @@ emit_division (tok, ntok, symname)
sym = symbol_find_or_make ((const char *) symname);
- /* Move the operands into the right place */
+ /* Move the operands into the right place. */
if (yr == AXP_REG_T10 && xr == AXP_REG_T11)
{
- /* They are in exactly the wrong order -- swap through AT */
-
+ /* They are in exactly the wrong order -- swap through AT. */
if (alpha_noat_on)
as_bad (_("macro requires $at register while noat in effect"));
@@ -4064,12 +4060,12 @@ emit_division (tok, ntok, symname)
}
}
- /* Call the division routine */
+ /* Call the division routine. */
set_tok_reg (newtok[0], AXP_REG_T9);
set_tok_sym (newtok[1], sym, 0);
assemble_tokens ("jsr", newtok, 2, 1);
- /* Reload the GP register */
+ /* Reload the GP register. */
#ifdef OBJ_AOUT
FIXME
#endif
@@ -4080,7 +4076,7 @@ FIXME
assemble_tokens ("ldgp", newtok, 3, 1);
#endif
- /* Move the result to the right place */
+ /* Move the result to the right place. */
if (rr != AXP_REG_T12)
{
set_tok_reg (newtok[0], AXP_REG_T12);
@@ -4188,7 +4184,7 @@ emit_retjcr (tok, ntok, vopname)
assemble_tokens (opname, newtok, 3, 0);
}
-/* Assembler directives */
+/* Assembler directives. */
/* Handle the .text pseudo-op. This is like the usual one, but it
clears alpha_insn_label and restores auto alignment. */
@@ -4232,7 +4228,7 @@ s_alpha_data (i)
static void
s_alpha_comm (ignore)
- int ignore;
+ int ignore ATTRIBUTE_UNUSED;
{
register char *name;
register char c;
@@ -4348,7 +4344,7 @@ s_alpha_comm (ignore)
static void
s_alpha_rdata (ignore)
- int ignore;
+ int ignore ATTRIBUTE_UNUSED;
{
int temp;
@@ -4369,7 +4365,7 @@ s_alpha_rdata (ignore)
static void
s_alpha_sdata (ignore)
- int ignore;
+ int ignore ATTRIBUTE_UNUSED;
{
int temp;
@@ -4383,13 +4379,32 @@ s_alpha_sdata (ignore)
#endif
#ifdef OBJ_ELF
+struct alpha_elf_frame_data
+{
+ symbolS *func_sym;
+ symbolS *func_end_sym;
+ symbolS *prologue_sym;
+ unsigned int mask;
+ unsigned int fmask;
+ int fp_regno;
+ int ra_regno;
+ offsetT frame_size;
+ offsetT mask_offset;
+ offsetT fmask_offset;
+
+ struct alpha_elf_frame_data *next;
+};
+
+static struct alpha_elf_frame_data *all_frame_data;
+static struct alpha_elf_frame_data **plast_frame_data = &all_frame_data;
+static struct alpha_elf_frame_data *cur_frame_data;
/* Handle the .section pseudo-op. This is like the usual one, but it
clears alpha_insn_label and restores auto alignment. */
static void
s_alpha_section (ignore)
- int ignore;
+ int ignore ATTRIBUTE_UNUSED;
{
obj_elf_section (ignore);
@@ -4419,12 +4434,21 @@ s_alpha_ent (dummy)
{
symbolS *sym;
- if (alpha_cur_ent_sym)
+ if (cur_frame_data)
as_warn (_("nested .ent directives"));
sym = symbol_find_or_make (name);
symbol_get_bfdsym (sym)->flags |= BSF_FUNCTION;
- alpha_cur_ent_sym = sym;
+
+ cur_frame_data = calloc (1, sizeof (*cur_frame_data));
+ cur_frame_data->func_sym = sym;
+
+ /* Provide sensible defaults. */
+ cur_frame_data->fp_regno = 30; /* sp */
+ cur_frame_data->ra_regno = 26; /* ra */
+
+ *plast_frame_data = cur_frame_data;
+ plast_frame_data = &cur_frame_data->next;
/* The .ent directive is sometimes followed by a number. Not sure
what it really means, but ignore it. */
@@ -4464,22 +4488,27 @@ s_alpha_end (dummy)
symbolS *sym;
sym = symbol_find (name);
- if (sym != alpha_cur_ent_sym)
+ if (!cur_frame_data)
+ as_warn (_(".end directive without matching .ent"));
+ else if (sym != cur_frame_data->func_sym)
as_warn (_(".end directive names different symbol than .ent"));
/* Create an expression to calculate the size of the function. */
- if (sym)
+ if (sym && cur_frame_data)
{
- symbol_get_obj (sym)->size =
- (expressionS *) xmalloc (sizeof (expressionS));
- symbol_get_obj (sym)->size->X_op = O_subtract;
- symbol_get_obj (sym)->size->X_add_symbol
- = symbol_new ("L0\001", now_seg, frag_now_fix (), frag_now);
- symbol_get_obj (sym)->size->X_op_symbol = sym;
- symbol_get_obj (sym)->size->X_add_number = 0;
+ OBJ_SYMFIELD_TYPE *obj = symbol_get_obj (sym);
+ expressionS *exp = xmalloc (sizeof (expressionS));
+
+ obj->size = exp;
+ exp->X_op = O_subtract;
+ exp->X_add_symbol = symbol_temp_new_now ();
+ exp->X_op_symbol = sym;
+ exp->X_add_number = 0;
+
+ cur_frame_data->func_end_sym = exp->X_add_symbol;
}
- alpha_cur_ent_sym = NULL;
+ cur_frame_data = NULL;
*input_line_pointer = name_end;
}
@@ -4499,7 +4528,45 @@ s_alpha_mask (fp)
ecoff_directive_mask (0);
}
else
- discard_rest_of_line ();
+ {
+ long val;
+ offsetT offset;
+
+ if (!cur_frame_data)
+ {
+ if (fp)
+ as_warn (_(".fmask outside of .ent"));
+ else
+ as_warn (_(".mask outside of .ent"));
+ discard_rest_of_line ();
+ return;
+ }
+
+ if (get_absolute_expression_and_terminator (&val) != ',')
+ {
+ if (fp)
+ as_warn (_("bad .fmask directive"));
+ else
+ as_warn (_("bad .mask directive"));
+ --input_line_pointer;
+ discard_rest_of_line ();
+ return;
+ }
+
+ offset = get_absolute_expression ();
+ demand_empty_rest_of_line ();
+
+ if (fp)
+ {
+ cur_frame_data->fmask = val;
+ cur_frame_data->fmask_offset = offset;
+ }
+ else
+ {
+ cur_frame_data->mask = val;
+ cur_frame_data->mask_offset = offset;
+ }
+ }
}
static void
@@ -4509,7 +4576,36 @@ s_alpha_frame (dummy)
if (ECOFF_DEBUGGING)
ecoff_directive_frame (0);
else
- discard_rest_of_line ();
+ {
+ long val;
+
+ if (!cur_frame_data)
+ {
+ as_warn (_(".frame outside of .ent"));
+ discard_rest_of_line ();
+ return;
+ }
+
+ cur_frame_data->fp_regno = tc_get_register (1);
+
+ SKIP_WHITESPACE ();
+ if (*input_line_pointer++ != ','
+ || get_absolute_expression_and_terminator (&val) != ',')
+ {
+ as_warn (_("bad .frame directive"));
+ --input_line_pointer;
+ discard_rest_of_line ();
+ return;
+ }
+ cur_frame_data->frame_size = val;
+
+ cur_frame_data->ra_regno = tc_get_register (0);
+
+ /* Next comes the "offset of saved $a0 from $sp". In gcc terms
+ this is current_function_pretend_args_size. There's no place
+ to put this value, so ignore it. */
+ s_ignore (42);
+ }
}
static void
@@ -4525,7 +4621,7 @@ s_alpha_prologue (ignore)
if (ECOFF_DEBUGGING)
sym = ecoff_get_cur_proc_sym ();
else
- sym = alpha_cur_ent_sym;
+ sym = cur_frame_data ? cur_frame_data->func_sym : NULL;
if (sym == NULL)
{
@@ -4550,6 +4646,9 @@ s_alpha_prologue (ignore)
as_bad (_("Invalid argument %d to .prologue."), arg);
break;
}
+
+ if (cur_frame_data)
+ cur_frame_data->prologue_sym = symbol_temp_new_now ();
}
static char *first_file_directive;
@@ -4643,8 +4742,146 @@ s_alpha_coff_wrapper (which)
ignore_rest_of_line ();
}
}
+
+/* Called at the end of assembly. Here we emit unwind info for frames
+ unless the compiler has done it for us. */
+
+void
+alpha_elf_md_end (void)
+{
+ struct alpha_elf_frame_data *p;
+
+ if (cur_frame_data)
+ as_warn (_(".ent directive without matching .end"));
+
+ /* If someone has generated the unwind info themselves, great. */
+ if (bfd_get_section_by_name (stdoutput, ".eh_frame") != NULL)
+ return;
+
+ /* Generate .eh_frame data for the unwind directives specified. */
+ for (p = all_frame_data; p ; p = p->next)
+ if (p->prologue_sym)
+ {
+ /* Create a temporary symbol at the same location as our
+ function symbol. This prevents problems with globals. */
+ cfi_new_fde (symbol_temp_new (S_GET_SEGMENT (p->func_sym),
+ S_GET_VALUE (p->func_sym),
+ symbol_get_frag (p->func_sym)));
+
+ cfi_set_return_column (p->ra_regno);
+ cfi_add_CFA_def_cfa_register (30);
+ if (p->fp_regno != 30 || p->mask || p->fmask || p->frame_size)
+ {
+ unsigned int mask;
+ offsetT offset;
+
+ cfi_add_advance_loc (p->prologue_sym);
+
+ if (p->fp_regno != 30)
+ if (p->frame_size != 0)
+ cfi_add_CFA_def_cfa (p->fp_regno, p->frame_size);
+ else
+ cfi_add_CFA_def_cfa_register (p->fp_regno);
+ else if (p->frame_size != 0)
+ cfi_add_CFA_def_cfa_offset (p->frame_size);
+
+ mask = p->mask;
+ offset = p->mask_offset;
+
+ /* Recall that $26 is special-cased and stored first. */
+ if ((mask >> 26) & 1)
+ {
+ cfi_add_CFA_offset (26, offset);
+ offset += 8;
+ mask &= ~(1 << 26);
+ }
+ while (mask)
+ {
+ unsigned int i;
+ i = mask & -mask;
+ mask ^= i;
+ i = ffs (i) - 1;
+
+ cfi_add_CFA_offset (i, offset);
+ offset += 8;
+ }
+
+ mask = p->fmask;
+ offset = p->fmask_offset;
+ while (mask)
+ {
+ unsigned int i;
+ i = mask & -mask;
+ mask ^= i;
+ i = ffs (i) - 1;
+
+ cfi_add_CFA_offset (i + 32, offset);
+ offset += 8;
+ }
+ }
+
+ cfi_end_fde (p->func_end_sym);
+ }
+}
+
+static void
+s_alpha_usepv (int unused ATTRIBUTE_UNUSED)
+{
+ char *name, name_end;
+ char *which, which_end;
+ symbolS *sym;
+ int other;
+
+ name = input_line_pointer;
+ name_end = get_symbol_end ();
+
+ if (! is_name_beginner (*name))
+ {
+ as_bad (_(".usepv directive has no name"));
+ *input_line_pointer = name_end;
+ ignore_rest_of_line ();
+ return;
+ }
+
+ sym = symbol_find_or_make (name);
+ *input_line_pointer++ = name_end;
+
+ if (name_end != ',')
+ {
+ as_bad (_(".usepv directive has no type"));
+ ignore_rest_of_line ();
+ return;
+ }
+
+ SKIP_WHITESPACE ();
+ which = input_line_pointer;
+ which_end = get_symbol_end ();
+
+ if (strcmp (which, "no") == 0)
+ other = STO_ALPHA_NOPV;
+ else if (strcmp (which, "std") == 0)
+ other = STO_ALPHA_STD_GPLOAD;
+ else
+ {
+ as_bad (_("unknown argument for .usepv"));
+ other = 0;
+ }
+
+ *input_line_pointer = which_end;
+ demand_empty_rest_of_line ();
+
+ S_SET_OTHER (sym, other | (S_GET_OTHER (sym) & ~STO_ALPHA_STD_GPLOAD));
+}
#endif /* OBJ_ELF */
+/* Standard calling conventions leaves the CFA at $30 on entry. */
+
+void
+alpha_cfi_frame_initial_instructions ()
+{
+ cfi_add_CFA_def_cfa_register (30);
+}
+
#ifdef OBJ_EVAX
/* Handle the section specific pseudo-op. */
@@ -4676,7 +4913,7 @@ s_alpha_section (secid)
static void
s_alpha_ent (ignore)
- int ignore;
+ int ignore ATTRIBUTE_UNUSED;
{
symbolS *symbol;
expressionS symexpr;
@@ -4706,14 +4943,13 @@ s_alpha_ent (ignore)
alpha_evax_proc.symbol = symbol;
demand_empty_rest_of_line ();
- return;
}
/* Parse .frame <framreg>,<framesize>,RA,<rsa_offset> directives. */
static void
s_alpha_frame (ignore)
- int ignore;
+ int ignore ATTRIBUTE_UNUSED;
{
long val;
@@ -4741,13 +4977,11 @@ s_alpha_frame (ignore)
return;
}
alpha_evax_proc.rsa_offset = get_absolute_expression ();
-
- return;
}
static void
s_alpha_pdesc (ignore)
- int ignore;
+ int ignore ATTRIBUTE_UNUSED;
{
char *name;
char name_end;
@@ -4892,15 +5126,13 @@ s_alpha_pdesc (ignore)
md_number_to_chars (p, alpha_evax_proc.imask, 4);
md_number_to_chars (p + 4, alpha_evax_proc.fmask, 4);
-
- return;
}
/* Support for crash debug on vms. */
static void
s_alpha_name (ignore)
- int ignore;
+ int ignore ATTRIBUTE_UNUSED;
{
register char *p;
expressionS exp;
@@ -4932,13 +5164,11 @@ s_alpha_name (ignore)
seginfo->literal_pool_size += 8;
fix_new_exp (frag_now, p - frag_now->fr_literal, 8, &exp, 0, BFD_RELOC_64);
-
- return;
}
static void
s_alpha_linkage (ignore)
- int ignore;
+ int ignore ATTRIBUTE_UNUSED;
{
expressionS exp;
char *p;
@@ -4960,13 +5190,11 @@ s_alpha_linkage (ignore)
BFD_RELOC_ALPHA_LINKAGE);
}
demand_empty_rest_of_line ();
-
- return;
}
static void
s_alpha_code_address (ignore)
- int ignore;
+ int ignore ATTRIBUTE_UNUSED;
{
expressionS exp;
char *p;
@@ -4988,24 +5216,21 @@ s_alpha_code_address (ignore)
BFD_RELOC_ALPHA_CODEADDR);
}
demand_empty_rest_of_line ();
-
- return;
}
static void
s_alpha_fp_save (ignore)
- int ignore;
+ int ignore ATTRIBUTE_UNUSED;
{
alpha_evax_proc.fp_save = tc_get_register (1);
demand_empty_rest_of_line ();
- return;
}
static void
s_alpha_mask (ignore)
- int ignore;
+ int ignore ATTRIBUTE_UNUSED;
{
long val;
@@ -5020,13 +5245,11 @@ s_alpha_mask (ignore)
(void) get_absolute_expression ();
}
demand_empty_rest_of_line ();
-
- return;
}
static void
s_alpha_fmask (ignore)
- int ignore;
+ int ignore ATTRIBUTE_UNUSED;
{
long val;
@@ -5041,13 +5264,11 @@ s_alpha_fmask (ignore)
(void) get_absolute_expression ();
}
demand_empty_rest_of_line ();
-
- return;
}
static void
s_alpha_end (ignore)
- int ignore;
+ int ignore ATTRIBUTE_UNUSED;
{
char c;
@@ -5055,20 +5276,16 @@ s_alpha_end (ignore)
*input_line_pointer = c;
demand_empty_rest_of_line ();
alpha_evax_proc.symbol = 0;
-
- return;
}
static void
s_alpha_file (ignore)
- int ignore;
+ int ignore ATTRIBUTE_UNUSED;
{
symbolS *s;
int length;
static char case_hack[32];
- extern char *demand_copy_string PARAMS ((int *lenP));
-
sprintf (case_hack, "<CASE:%01d%01d>",
alpha_flag_hash_long_names, alpha_flag_show_after_trunc);
@@ -5079,8 +5296,6 @@ s_alpha_file (ignore)
s = symbol_find_or_make (demand_copy_string (&length));
symbol_get_bfdsym (s)->flags |= BSF_FILE;
demand_empty_rest_of_line ();
-
- return;
}
#endif /* OBJ_EVAX */
@@ -5440,7 +5655,6 @@ alpha_print_token (f, exp)
print_expr (f, exp);
break;
}
- return;
}
#endif
@@ -5488,10 +5702,11 @@ const pseudo_typeS md_pseudo_table[] = {
{"fmask", s_alpha_mask, 1},
{"frame", s_alpha_frame, 0},
{"prologue", s_alpha_prologue, 0},
- {"file", (void (*) PARAMS ((int))) s_alpha_file, 5},
+ {"file", s_alpha_file, 5},
{"loc", s_alpha_loc, 9},
{"stabs", s_alpha_stab, 's'},
{"stabn", s_alpha_stab, 'n'},
+ {"usepv", s_alpha_usepv, 0},
/* COFF debugging related pseudos. */
{"begin", s_alpha_coff_wrapper, 0},
{"bend", s_alpha_coff_wrapper, 1},
@@ -5581,6 +5796,7 @@ create_literal_section (name, secp, symp)
/* @@@ GP selection voodoo. All of this seems overly complicated and
unnecessary; which is the primary reason it's for ECOFF only. */
+static inline void maybe_set_gp PARAMS ((asection *));
static inline void
maybe_set_gp (sec)
@@ -5637,7 +5853,7 @@ alpha_elf_section_letter (letter, ptr_msg)
return SHF_ALPHA_GPREL;
*ptr_msg = _("Bad .section directive: want a,s,w,x,M,S,G,T in string");
- return 0;
+ return -1;
}
/* Map SHF_ALPHA_GPREL to SEC_SMALL_DATA. */
diff --git a/contrib/binutils/gas/config/tc-alpha.h b/contrib/binutils/gas/config/tc-alpha.h
index 12146b7..939a14f 100644
--- a/contrib/binutils/gas/config/tc-alpha.h
+++ b/contrib/binutils/gas/config/tc-alpha.h
@@ -1,5 +1,5 @@
/* This file is tc-alpha.h
- Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
+ Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
Free Software Foundation, Inc.
Written by Ken Raeburn <raeburn@cygnus.com>.
@@ -46,27 +46,21 @@
#define NEED_LITERAL_POOL
#define REPEAT_CONS_EXPRESSIONS
+struct fix;
+struct alpha_reloc_tag;
+
extern int alpha_force_relocation PARAMS ((struct fix *));
extern int alpha_fix_adjustable PARAMS ((struct fix *));
extern unsigned long alpha_gprmask, alpha_fprmask;
extern valueT alpha_gp_value;
-#define TC_FORCE_RELOCATION(FIXP) alpha_force_relocation (FIXP)
-#define tc_fix_adjustable(FIXP) alpha_fix_adjustable (FIXP)
+#define TC_FORCE_RELOCATION(FIX) alpha_force_relocation (FIX)
+#define tc_fix_adjustable(FIX) alpha_fix_adjustable (FIX)
#define RELOC_REQUIRES_SYMBOL
-/* This expression evaluates to false if the relocation is for a local
- object for which we still want to do the relocation at runtime.
- True if we are willing to perform this relocation while building
- the .o file. This is only used for pcrel relocations. */
-
-#define TC_RELOC_RTSYM_LOC_FIXUP(FIX) \
- ((FIX)->fx_addsy == NULL \
- || (! S_IS_EXTERNAL ((FIX)->fx_addsy) \
- && ! S_IS_WEAK ((FIX)->fx_addsy) \
- && S_IS_DEFINED ((FIX)->fx_addsy) \
- && ! S_IS_COMMON ((FIX)->fx_addsy)))
+/* Values passed to md_apply_fix3 don't include the symbol value. */
+#define MD_APPLY_SYM_VALUE(FIX) 0
#define md_convert_frag(b,s,f) as_fatal ("alpha convert_frag\n")
#define md_estimate_size_before_relax(f,s) \
@@ -86,6 +80,21 @@ extern valueT alpha_gp_value;
: BFD_RELOC_ALPHA_LINKAGE);
#endif
+#ifndef VMS
+#define TC_IMPLICIT_LCOMM_ALIGNMENT(size, align) \
+ do \
+ { \
+ align = 0; \
+ if (size > 1) \
+ { \
+ addressT temp = 1; \
+ while ((size & temp) == 0) \
+ ++align, temp <<= 1; \
+ } \
+ } \
+ while (0)
+#endif
+
#define md_number_to_chars number_to_chars_littleendian
extern int tc_get_register PARAMS ((int frame));
@@ -110,17 +119,13 @@ extern void alpha_frob_file_before_adjust PARAMS ((void));
#define DIFF_EXPR_OK /* foo-. gets turned into PC relative relocs */
#ifdef OBJ_ELF
-#define ELF_TC_SPECIAL_SECTIONS \
- { ".sdata", SHT_PROGBITS, SHF_ALLOC + SHF_WRITE + SHF_ALPHA_GPREL }, \
- { ".sbss", SHT_NOBITS, SHF_ALLOC + SHF_WRITE + SHF_ALPHA_GPREL },
-
#define md_elf_section_letter alpha_elf_section_letter
extern int alpha_elf_section_letter PARAMS ((int, char **));
#define md_elf_section_flags alpha_elf_section_flags
extern flagword alpha_elf_section_flags PARAMS ((flagword, int, int));
#endif
-/* Whether to add support for explict !relocation_op!sequence_number. At the
+/* Whether to add support for explicit !relocation_op!sequence_number. At the
moment, only do this for ELF, though ECOFF could use it as well. */
#ifdef OBJ_ELF
@@ -131,8 +136,13 @@ extern flagword alpha_elf_section_flags PARAMS ((flagword, int, int));
supplied !lituse relocations follow the appropriate !literal
relocations. Also convert the gas-internal relocations to the
appropriate linker relocations. */
-#define tc_adjust_symtab() alpha_adjust_symtab ()
-extern void alpha_adjust_symtab PARAMS ((void));
+#define tc_frob_file_before_fix() alpha_before_fix ()
+extern void alpha_before_fix PARAMS ((void));
+
+#ifdef OBJ_ELF
+#define md_end alpha_elf_md_end
+extern void alpha_elf_md_end PARAMS ((void));
+#endif
/* New fields for supporting explicit relocations (such as !literal to mark
where a pointer is loaded from the global table, and !lituse_base to track
@@ -147,19 +157,26 @@ struct alpha_fix_tag
};
/* Initialize the TC_FIX_TYPE field. */
-#define TC_INIT_FIX_DATA(fixP) \
+#define TC_INIT_FIX_DATA(FIX) \
do { \
- fixP->tc_fix_data.next_reloc = (struct fix *)0; \
- fixP->tc_fix_data.info = (struct alpha_reloc_tag *)0; \
+ FIX->tc_fix_data.next_reloc = (struct fix *) 0; \
+ FIX->tc_fix_data.info = (struct alpha_reloc_tag *) 0; \
} while (0)
/* Work with DEBUG5 to print fields in tc_fix_type. */
-#define TC_FIX_DATA_PRINT(stream,fixP) \
+#define TC_FIX_DATA_PRINT(STREAM, FIX) \
do { \
- if (fixP->tc_fix_data.info) \
- fprintf (stderr, "\tinfo = 0x%lx, next_reloc = 0x%lx\n", \
- (long)fixP->tc_fix_data.info, \
- (long)fixP->tc_fix_data.next_reloc); \
+ if (FIX->tc_fix_data.info) \
+ fprintf (STREAM, "\tinfo = 0x%lx, next_reloc = 0x%lx\n", \
+ (long) FIX->tc_fix_data.info, \
+ (long) FIX->tc_fix_data.next_reloc); \
} while (0)
-#define DWARF2_LINE_MIN_INSN_LENGTH 4
+#define TARGET_USE_CFIPOP 1
+
+#define tc_cfi_frame_initial_instructions alpha_cfi_frame_initial_instructions
+extern void alpha_cfi_frame_initial_instructions(void);
+
+#define DWARF2_LINE_MIN_INSN_LENGTH 4
+#define DWARF2_DEFAULT_RETURN_COLUMN 26
+#define DWARF2_CIE_DATA_ALIGNMENT -8
diff --git a/contrib/binutils/gas/config/tc-arc.c b/contrib/binutils/gas/config/tc-arc.c
index 3e829fa..60cfa34 100644
--- a/contrib/binutils/gas/config/tc-arc.c
+++ b/contrib/binutils/gas/config/tc-arc.c
@@ -1,5 +1,5 @@
/* tc-arc.c -- Assembler for the ARC
- Copyright 1994, 1995, 1997, 1999, 2000, 2001
+ Copyright 1994, 1995, 1997, 1999, 2000, 2001, 2002
Free Software Foundation, Inc.
Contributed by Doug Evans (dje@cygnus.com).
@@ -23,6 +23,7 @@
#include <stdio.h>
#include "libiberty.h"
#include "as.h"
+#include "struc-symbol.h"
#include "safe-ctype.h"
#include "subsegs.h"
#include "opcode/arc.h"
@@ -93,8 +94,6 @@ const pseudo_typeS md_pseudo_table[] = {
{ "option", arc_option, 0 },
{ "cpu", arc_option, 0 },
{ "block", s_space, 0 },
- { "file", dwarf2_directive_file, 0 },
- { "loc", dwarf2_directive_loc, 0 },
{ "extcondcode", arc_extoper, 0 },
{ "extcoreregister", arc_extoper, 1 },
{ "extauxregister", arc_extoper, 2 },
@@ -906,11 +905,6 @@ arc_extoper (opertype)
name = input_line_pointer;
c = get_symbol_end ();
name = xstrdup (name);
- if (NULL == name)
- {
- ignore_rest_of_line ();
- return;
- }
p = name;
while (*p)
@@ -1154,11 +1148,6 @@ arc_extinst (ignore)
name = input_line_pointer;
c = get_symbol_end ();
name = xstrdup (name);
- if (NULL == name)
- {
- ignore_rest_of_line ();
- return;
- }
strcpy (syntax, name);
name_len = strlen (name);
@@ -1306,18 +1295,7 @@ arc_extinst (ignore)
strcat (syntax, "%S%L");
ext_op = (struct arc_opcode *) xmalloc (sizeof (struct arc_opcode));
- if (NULL == ext_op)
- {
- ignore_rest_of_line ();
- return;
- }
-
ext_op->syntax = xstrdup (syntax);
- if (NULL == ext_op->syntax)
- {
- ignore_rest_of_line ();
- return;
- }
ext_op->mask = I (-1) | ((0x3 == opcode) ? C (-1) : 0);
ext_op->value = I (opcode) | ((0x3 == opcode) ? C (subopcode) : 0);
@@ -1476,7 +1454,6 @@ arc_common (localScope)
symbolP->bsym->flags |= BSF_OBJECT;
demand_empty_rest_of_line ();
- return;
}
/* Select the cpu we're assembling for. */
@@ -1547,7 +1524,6 @@ md_atof (type, litP, sizeP)
LITTLENUM_TYPE words[MAX_LITTLENUMS];
LITTLENUM_TYPE *wordP;
char *t;
- char * atof_ieee PARAMS ((char *, int, LITTLENUM_TYPE *));
switch (type)
{
@@ -1801,13 +1777,6 @@ long
md_pcrel_from (fixP)
fixS *fixP;
{
- if (fixP->fx_addsy != (symbolS *) NULL
- && ! S_IS_DEFINED (fixP->fx_addsy))
- {
- /* The symbol is undefined. Let the linker figure it out. */
- return 0;
- }
-
/* Return the address of the delay slot. */
return fixP->fx_frag->fr_address + fixP->fx_where + fixP->fx_size;
}
@@ -1841,7 +1810,7 @@ get_arc_exp_reloc_type (data_p, default_type, exp, expnew)
expressionS *expnew;
{
/* If the expression is "symbol >> 2" we must change it to just "symbol",
- as fix_new_exp can't handle it. Similarily for (symbol - symbol) >> 2.
+ as fix_new_exp can't handle it. Similarly for (symbol - symbol) >> 2.
That's ok though. What's really going on here is that we're using
">> 2" as a special syntax for specifying BFD_RELOC_ARC_B26. */
@@ -1891,45 +1860,19 @@ md_apply_fix3 (fixP, valP, seg)
#endif
valueT value = * valP;
- /* FIXME FIXME FIXME: The value we are passed in *valueP includes
- the symbol values. Since we are using BFD_ASSEMBLER, if we are
- doing this relocation the code in write.c is going to call
- bfd_perform_relocation, which is also going to use the symbol
- value. That means that if the reloc is fully resolved we want to
- use *valueP since bfd_perform_relocation is not being used.
- However, if the reloc is not fully resolved we do not want to use
- *valueP, and must use fx_offset instead. However, if the reloc
- is PC relative, we do want to use *valueP since it includes the
- result of md_pcrel_from. This is confusing. */
-
if (fixP->fx_addsy == (symbolS *) NULL)
fixP->fx_done = 1;
else if (fixP->fx_pcrel)
{
- /* ELF relocations are against symbols.
- If this symbol is in a different section then we need to leave it for
- the linker to deal with. Unfortunately, md_pcrel_from can't tell,
- so we have to undo it's effects here. */
- if (S_IS_DEFINED (fixP->fx_addsy)
- && S_GET_SEGMENT (fixP->fx_addsy) != seg)
+ /* Hack around bfd_install_relocation brain damage. */
+ if (S_GET_SEGMENT (fixP->fx_addsy) != seg)
value += md_pcrel_from (fixP);
}
- else
- {
- value = fixP->fx_offset;
- if (fixP->fx_subsy != (symbolS *) NULL)
- {
- if (S_GET_SEGMENT (fixP->fx_subsy) == absolute_section)
- value -= S_GET_VALUE (fixP->fx_subsy);
- else
- {
- /* We can't actually support subtracting a symbol. */
- as_bad_where (fixP->fx_file, fixP->fx_line,
- "expression too complex");
- }
- }
- }
+
+ /* We can't actually support subtracting a symbol. */
+ if (fixP->fx_subsy != NULL)
+ as_bad_where (fixP->fx_file, fixP->fx_line, _("expression too complex"));
if ((int) fixP->fx_r_type >= (int) BFD_RELOC_UNUSED)
{
@@ -2032,8 +1975,6 @@ md_apply_fix3 (fixP, valP, seg)
abort ();
}
}
-
- fixP->fx_addnumber = value;
}
/* Translate internal representation of relocation info to BFD target
@@ -2063,8 +2004,7 @@ tc_gen_reloc (section, fixP)
assert (!fixP->fx_pcrel == !reloc->howto->pc_relative);
/* Set addend to account for PC being advanced one insn before the
- target address is computed, drop fx_addnumber as it is handled
- elsewhere mlm */
+ target address is computed. */
reloc->addend = (fixP->fx_pcrel ? -4 : 0);
diff --git a/contrib/binutils/gas/config/tc-arc.h b/contrib/binutils/gas/config/tc-arc.h
index f144271..884d375 100644
--- a/contrib/binutils/gas/config/tc-arc.h
+++ b/contrib/binutils/gas/config/tc-arc.h
@@ -1,5 +1,6 @@
/* tc-arc.h - Macros and type defines for the ARC.
- Copyright 1994, 1995, 1997, 2000, 2001 Free Software Foundation, Inc.
+ Copyright 1994, 1995, 1997, 2000, 2001, 2002
+ Free Software Foundation, Inc.
Contributed by Doug Evans (dje@cygnus.com).
This file is part of GAS, the GNU Assembler.
@@ -64,3 +65,10 @@ extern void arc_cons_fix_new PARAMS ((struct frag *, int, int, struct expression
arc_cons_fix_new (FRAG, WHERE, NBYTES, EXP)
#define DWARF2_LINE_MIN_INSN_LENGTH 4
+
+/* Values passed to md_apply_fix3 don't include the symbol value. */
+#define MD_APPLY_SYM_VALUE(FIX) 0
+
+/* No shared lib support, so we don't need to ensure externally
+ visible symbols can be overridden. */
+#define EXTERN_FORCE_RELOC 0
diff --git a/contrib/binutils/gas/config/tc-arm.c b/contrib/binutils/gas/config/tc-arm.c
index a6bbba1..2ed5196 100644
--- a/contrib/binutils/gas/config/tc-arm.c
+++ b/contrib/binutils/gas/config/tc-arm.c
@@ -1,9 +1,11 @@
/* tc-arm.c -- Assemble for the ARM
- Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
+ Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
Contributed by Richard Earnshaw (rwe@pegasus.esprit.ec.org)
Modified by David Taylor (dtaylor@armltd.co.uk)
Cirrus coprocessor mods by Aldy Hernandez (aldyh@redhat.com)
+ Cirrus coprocessor fixes by Petko Manolov (petkan@nucleusys.com)
+ Cirrus coprocessor fixes by Vladimir Ivanov (vladitx@nucleusys.com)
This file is part of GAS, the GNU Assembler.
@@ -55,10 +57,12 @@
#define ARM_EXT_V5ExP 0x00000200 /* DSP core set. */
#define ARM_EXT_V5E 0x00000400 /* DSP Double transfers. */
#define ARM_EXT_V5J 0x00000800 /* Jazelle extension. */
+#define ARM_EXT_V6 0x00001000 /* ARM V6. */
/* Co-processor space extensions. */
#define ARM_CEXT_XSCALE 0x00800000 /* Allow MIA etc. */
#define ARM_CEXT_MAVERICK 0x00400000 /* Use Cirrus/DSP coprocessor. */
+#define ARM_CEXT_IWMMXT 0x00200000 /* Intel Wireless MMX technology coprocessor. */
/* Architectures are the sum of the base and extensions. The ARM ARM (rev E)
defines the following: ARMv3, ARMv3M, ARMv4xM, ARMv4, ARMv4TxM, ARMv4T,
@@ -81,9 +85,11 @@
#define ARM_ARCH_V5TExP (ARM_ARCH_V5T | ARM_EXT_V5ExP)
#define ARM_ARCH_V5TE (ARM_ARCH_V5TExP | ARM_EXT_V5E)
#define ARM_ARCH_V5TEJ (ARM_ARCH_V5TE | ARM_EXT_V5J)
+#define ARM_ARCH_V6 (ARM_ARCH_V5TEJ | ARM_EXT_V6)
/* Processors with specific extensions in the co-processor space. */
#define ARM_ARCH_XSCALE (ARM_ARCH_V5TE | ARM_CEXT_XSCALE)
+#define ARM_ARCH_IWMMXT (ARM_ARCH_XSCALE | ARM_CEXT_IWMMXT)
/* Some useful combinations: */
#define ARM_ANY 0x0000ffff /* Any basic core. */
@@ -98,6 +104,7 @@
#define FPU_VFP_EXT_V1xD 0x10000000 /* Base VFP instruction set. */
#define FPU_VFP_EXT_V1 0x08000000 /* Double-precision insns. */
#define FPU_VFP_EXT_V2 0x04000000 /* ARM10E VFPr1. */
+#define FPU_MAVERICK 0x02000000 /* Cirrus Maverick. */
#define FPU_NONE 0
#define FPU_ARCH_FPE FPU_FPA_EXT_V1
@@ -108,6 +115,15 @@
#define FPU_ARCH_VFP_V1 (FPU_ARCH_VFP_V1xD | FPU_VFP_EXT_V1)
#define FPU_ARCH_VFP_V2 (FPU_ARCH_VFP_V1 | FPU_VFP_EXT_V2)
+#define FPU_ARCH_MAVERICK FPU_MAVERICK
+
+enum arm_float_abi
+{
+ ARM_FLOAT_ABI_HARD,
+ ARM_FLOAT_ABI_SOFTFP,
+ ARM_FLOAT_ABI_SOFT
+};
+
/* Types of processor to assemble for. */
#define ARM_1 ARM_ARCH_V1
#define ARM_2 ARM_ARCH_V2
@@ -132,6 +148,19 @@
#endif
#endif
+#ifdef TE_LINUX
+#define FPU_DEFAULT FPU_ARCH_FPA
+#endif
+
+#ifdef TE_NetBSD
+#ifdef OBJ_ELF
+#define FPU_DEFAULT FPU_ARCH_VFP /* Soft-float, but VFP order. */
+#else
+/* Legacy a.out format. */
+#define FPU_DEFAULT FPU_ARCH_FPA /* Soft-float, but FPA order. */
+#endif
+#endif
+
/* For backwards compatibility we default to the FPA. */
#ifndef FPU_DEFAULT
#define FPU_DEFAULT FPU_ARCH_FPA
@@ -144,11 +173,11 @@ static unsigned long cpu_variant;
static int target_oabi = 0;
/* Flags stored in private area of BFD structure. */
-static int uses_apcs_26 = false;
-static int atpcs = false;
-static int support_interwork = false;
-static int uses_apcs_float = false;
-static int pic_code = false;
+static int uses_apcs_26 = FALSE;
+static int atpcs = FALSE;
+static int support_interwork = FALSE;
+static int uses_apcs_float = FALSE;
+static int pic_code = FALSE;
/* Variables that we set while parsing command-line options. Once all
options have been read we re-process these values to set the real
@@ -161,6 +190,7 @@ static int mcpu_fpu_opt = -1;
static int march_cpu_opt = -1;
static int march_fpu_opt = -1;
static int mfpu_opt = -1;
+static int mfloat_abi_opt = -1;
/* This array holds the chars that always start a comment. If the
pre-processor is disabled, these aren't very useful. */
@@ -273,8 +303,16 @@ static const struct asm_shift_name shift_names [] =
{ "RRX", shift_properties + SHIFT_RRX }
};
+/* Any kind of shift is accepted. */
#define NO_SHIFT_RESTRICT 1
-#define SHIFT_RESTRICT 0
+/* The shift operand must be an immediate value, not a register. */
+#define SHIFT_IMMEDIATE 0
+/* The shift must be LSL or ASR and the operand must be an immediate. */
+#define SHIFT_LSL_OR_ASR_IMMEDIATE 2
+/* The shift must be ASR and the operand must be an immediate. */
+#define SHIFT_ASR_IMMEDIATE 3
+/* The shift must be LSL and the operand must be an immediate. */
+#define SHIFT_LSL_IMMEDIATE 4
#define NUM_FLOAT_VALS 8
@@ -342,12 +380,12 @@ static const struct asm_cond conds[] =
struct asm_psr
{
- const char * template;
- boolean cpsr;
+ const char *template;
+ bfd_boolean cpsr;
unsigned long field;
};
-/* The bit that distnguishes CPSR and SPSR. */
+/* The bit that distinguishes CPSR and SPSR. */
#define SPSR_BIT (1 << 22)
/* How many bits to shift the PSR_xxx bits up by. */
@@ -360,143 +398,172 @@ struct asm_psr
static const struct asm_psr psrs[] =
{
- {"CPSR", true, PSR_c | PSR_f},
- {"CPSR_all", true, PSR_c | PSR_f},
- {"SPSR", false, PSR_c | PSR_f},
- {"SPSR_all", false, PSR_c | PSR_f},
- {"CPSR_flg", true, PSR_f},
- {"CPSR_f", true, PSR_f},
- {"SPSR_flg", false, PSR_f},
- {"SPSR_f", false, PSR_f},
- {"CPSR_c", true, PSR_c},
- {"CPSR_ctl", true, PSR_c},
- {"SPSR_c", false, PSR_c},
- {"SPSR_ctl", false, PSR_c},
- {"CPSR_x", true, PSR_x},
- {"CPSR_s", true, PSR_s},
- {"SPSR_x", false, PSR_x},
- {"SPSR_s", false, PSR_s},
+ {"CPSR", TRUE, PSR_c | PSR_f},
+ {"CPSR_all", TRUE, PSR_c | PSR_f},
+ {"SPSR", FALSE, PSR_c | PSR_f},
+ {"SPSR_all", FALSE, PSR_c | PSR_f},
+ {"CPSR_flg", TRUE, PSR_f},
+ {"CPSR_f", TRUE, PSR_f},
+ {"SPSR_flg", FALSE, PSR_f},
+ {"SPSR_f", FALSE, PSR_f},
+ {"CPSR_c", TRUE, PSR_c},
+ {"CPSR_ctl", TRUE, PSR_c},
+ {"SPSR_c", FALSE, PSR_c},
+ {"SPSR_ctl", FALSE, PSR_c},
+ {"CPSR_x", TRUE, PSR_x},
+ {"CPSR_s", TRUE, PSR_s},
+ {"SPSR_x", FALSE, PSR_x},
+ {"SPSR_s", FALSE, PSR_s},
/* Combinations of flags. */
- {"CPSR_fs", true, PSR_f | PSR_s},
- {"CPSR_fx", true, PSR_f | PSR_x},
- {"CPSR_fc", true, PSR_f | PSR_c},
- {"CPSR_sf", true, PSR_s | PSR_f},
- {"CPSR_sx", true, PSR_s | PSR_x},
- {"CPSR_sc", true, PSR_s | PSR_c},
- {"CPSR_xf", true, PSR_x | PSR_f},
- {"CPSR_xs", true, PSR_x | PSR_s},
- {"CPSR_xc", true, PSR_x | PSR_c},
- {"CPSR_cf", true, PSR_c | PSR_f},
- {"CPSR_cs", true, PSR_c | PSR_s},
- {"CPSR_cx", true, PSR_c | PSR_x},
- {"CPSR_fsx", true, PSR_f | PSR_s | PSR_x},
- {"CPSR_fsc", true, PSR_f | PSR_s | PSR_c},
- {"CPSR_fxs", true, PSR_f | PSR_x | PSR_s},
- {"CPSR_fxc", true, PSR_f | PSR_x | PSR_c},
- {"CPSR_fcs", true, PSR_f | PSR_c | PSR_s},
- {"CPSR_fcx", true, PSR_f | PSR_c | PSR_x},
- {"CPSR_sfx", true, PSR_s | PSR_f | PSR_x},
- {"CPSR_sfc", true, PSR_s | PSR_f | PSR_c},
- {"CPSR_sxf", true, PSR_s | PSR_x | PSR_f},
- {"CPSR_sxc", true, PSR_s | PSR_x | PSR_c},
- {"CPSR_scf", true, PSR_s | PSR_c | PSR_f},
- {"CPSR_scx", true, PSR_s | PSR_c | PSR_x},
- {"CPSR_xfs", true, PSR_x | PSR_f | PSR_s},
- {"CPSR_xfc", true, PSR_x | PSR_f | PSR_c},
- {"CPSR_xsf", true, PSR_x | PSR_s | PSR_f},
- {"CPSR_xsc", true, PSR_x | PSR_s | PSR_c},
- {"CPSR_xcf", true, PSR_x | PSR_c | PSR_f},
- {"CPSR_xcs", true, PSR_x | PSR_c | PSR_s},
- {"CPSR_cfs", true, PSR_c | PSR_f | PSR_s},
- {"CPSR_cfx", true, PSR_c | PSR_f | PSR_x},
- {"CPSR_csf", true, PSR_c | PSR_s | PSR_f},
- {"CPSR_csx", true, PSR_c | PSR_s | PSR_x},
- {"CPSR_cxf", true, PSR_c | PSR_x | PSR_f},
- {"CPSR_cxs", true, PSR_c | PSR_x | PSR_s},
- {"CPSR_fsxc", true, PSR_f | PSR_s | PSR_x | PSR_c},
- {"CPSR_fscx", true, PSR_f | PSR_s | PSR_c | PSR_x},
- {"CPSR_fxsc", true, PSR_f | PSR_x | PSR_s | PSR_c},
- {"CPSR_fxcs", true, PSR_f | PSR_x | PSR_c | PSR_s},
- {"CPSR_fcsx", true, PSR_f | PSR_c | PSR_s | PSR_x},
- {"CPSR_fcxs", true, PSR_f | PSR_c | PSR_x | PSR_s},
- {"CPSR_sfxc", true, PSR_s | PSR_f | PSR_x | PSR_c},
- {"CPSR_sfcx", true, PSR_s | PSR_f | PSR_c | PSR_x},
- {"CPSR_sxfc", true, PSR_s | PSR_x | PSR_f | PSR_c},
- {"CPSR_sxcf", true, PSR_s | PSR_x | PSR_c | PSR_f},
- {"CPSR_scfx", true, PSR_s | PSR_c | PSR_f | PSR_x},
- {"CPSR_scxf", true, PSR_s | PSR_c | PSR_x | PSR_f},
- {"CPSR_xfsc", true, PSR_x | PSR_f | PSR_s | PSR_c},
- {"CPSR_xfcs", true, PSR_x | PSR_f | PSR_c | PSR_s},
- {"CPSR_xsfc", true, PSR_x | PSR_s | PSR_f | PSR_c},
- {"CPSR_xscf", true, PSR_x | PSR_s | PSR_c | PSR_f},
- {"CPSR_xcfs", true, PSR_x | PSR_c | PSR_f | PSR_s},
- {"CPSR_xcsf", true, PSR_x | PSR_c | PSR_s | PSR_f},
- {"CPSR_cfsx", true, PSR_c | PSR_f | PSR_s | PSR_x},
- {"CPSR_cfxs", true, PSR_c | PSR_f | PSR_x | PSR_s},
- {"CPSR_csfx", true, PSR_c | PSR_s | PSR_f | PSR_x},
- {"CPSR_csxf", true, PSR_c | PSR_s | PSR_x | PSR_f},
- {"CPSR_cxfs", true, PSR_c | PSR_x | PSR_f | PSR_s},
- {"CPSR_cxsf", true, PSR_c | PSR_x | PSR_s | PSR_f},
- {"SPSR_fs", false, PSR_f | PSR_s},
- {"SPSR_fx", false, PSR_f | PSR_x},
- {"SPSR_fc", false, PSR_f | PSR_c},
- {"SPSR_sf", false, PSR_s | PSR_f},
- {"SPSR_sx", false, PSR_s | PSR_x},
- {"SPSR_sc", false, PSR_s | PSR_c},
- {"SPSR_xf", false, PSR_x | PSR_f},
- {"SPSR_xs", false, PSR_x | PSR_s},
- {"SPSR_xc", false, PSR_x | PSR_c},
- {"SPSR_cf", false, PSR_c | PSR_f},
- {"SPSR_cs", false, PSR_c | PSR_s},
- {"SPSR_cx", false, PSR_c | PSR_x},
- {"SPSR_fsx", false, PSR_f | PSR_s | PSR_x},
- {"SPSR_fsc", false, PSR_f | PSR_s | PSR_c},
- {"SPSR_fxs", false, PSR_f | PSR_x | PSR_s},
- {"SPSR_fxc", false, PSR_f | PSR_x | PSR_c},
- {"SPSR_fcs", false, PSR_f | PSR_c | PSR_s},
- {"SPSR_fcx", false, PSR_f | PSR_c | PSR_x},
- {"SPSR_sfx", false, PSR_s | PSR_f | PSR_x},
- {"SPSR_sfc", false, PSR_s | PSR_f | PSR_c},
- {"SPSR_sxf", false, PSR_s | PSR_x | PSR_f},
- {"SPSR_sxc", false, PSR_s | PSR_x | PSR_c},
- {"SPSR_scf", false, PSR_s | PSR_c | PSR_f},
- {"SPSR_scx", false, PSR_s | PSR_c | PSR_x},
- {"SPSR_xfs", false, PSR_x | PSR_f | PSR_s},
- {"SPSR_xfc", false, PSR_x | PSR_f | PSR_c},
- {"SPSR_xsf", false, PSR_x | PSR_s | PSR_f},
- {"SPSR_xsc", false, PSR_x | PSR_s | PSR_c},
- {"SPSR_xcf", false, PSR_x | PSR_c | PSR_f},
- {"SPSR_xcs", false, PSR_x | PSR_c | PSR_s},
- {"SPSR_cfs", false, PSR_c | PSR_f | PSR_s},
- {"SPSR_cfx", false, PSR_c | PSR_f | PSR_x},
- {"SPSR_csf", false, PSR_c | PSR_s | PSR_f},
- {"SPSR_csx", false, PSR_c | PSR_s | PSR_x},
- {"SPSR_cxf", false, PSR_c | PSR_x | PSR_f},
- {"SPSR_cxs", false, PSR_c | PSR_x | PSR_s},
- {"SPSR_fsxc", false, PSR_f | PSR_s | PSR_x | PSR_c},
- {"SPSR_fscx", false, PSR_f | PSR_s | PSR_c | PSR_x},
- {"SPSR_fxsc", false, PSR_f | PSR_x | PSR_s | PSR_c},
- {"SPSR_fxcs", false, PSR_f | PSR_x | PSR_c | PSR_s},
- {"SPSR_fcsx", false, PSR_f | PSR_c | PSR_s | PSR_x},
- {"SPSR_fcxs", false, PSR_f | PSR_c | PSR_x | PSR_s},
- {"SPSR_sfxc", false, PSR_s | PSR_f | PSR_x | PSR_c},
- {"SPSR_sfcx", false, PSR_s | PSR_f | PSR_c | PSR_x},
- {"SPSR_sxfc", false, PSR_s | PSR_x | PSR_f | PSR_c},
- {"SPSR_sxcf", false, PSR_s | PSR_x | PSR_c | PSR_f},
- {"SPSR_scfx", false, PSR_s | PSR_c | PSR_f | PSR_x},
- {"SPSR_scxf", false, PSR_s | PSR_c | PSR_x | PSR_f},
- {"SPSR_xfsc", false, PSR_x | PSR_f | PSR_s | PSR_c},
- {"SPSR_xfcs", false, PSR_x | PSR_f | PSR_c | PSR_s},
- {"SPSR_xsfc", false, PSR_x | PSR_s | PSR_f | PSR_c},
- {"SPSR_xscf", false, PSR_x | PSR_s | PSR_c | PSR_f},
- {"SPSR_xcfs", false, PSR_x | PSR_c | PSR_f | PSR_s},
- {"SPSR_xcsf", false, PSR_x | PSR_c | PSR_s | PSR_f},
- {"SPSR_cfsx", false, PSR_c | PSR_f | PSR_s | PSR_x},
- {"SPSR_cfxs", false, PSR_c | PSR_f | PSR_x | PSR_s},
- {"SPSR_csfx", false, PSR_c | PSR_s | PSR_f | PSR_x},
- {"SPSR_csxf", false, PSR_c | PSR_s | PSR_x | PSR_f},
- {"SPSR_cxfs", false, PSR_c | PSR_x | PSR_f | PSR_s},
- {"SPSR_cxsf", false, PSR_c | PSR_x | PSR_s | PSR_f},
+ {"CPSR_fs", TRUE, PSR_f | PSR_s},
+ {"CPSR_fx", TRUE, PSR_f | PSR_x},
+ {"CPSR_fc", TRUE, PSR_f | PSR_c},
+ {"CPSR_sf", TRUE, PSR_s | PSR_f},
+ {"CPSR_sx", TRUE, PSR_s | PSR_x},
+ {"CPSR_sc", TRUE, PSR_s | PSR_c},
+ {"CPSR_xf", TRUE, PSR_x | PSR_f},
+ {"CPSR_xs", TRUE, PSR_x | PSR_s},
+ {"CPSR_xc", TRUE, PSR_x | PSR_c},
+ {"CPSR_cf", TRUE, PSR_c | PSR_f},
+ {"CPSR_cs", TRUE, PSR_c | PSR_s},
+ {"CPSR_cx", TRUE, PSR_c | PSR_x},
+ {"CPSR_fsx", TRUE, PSR_f | PSR_s | PSR_x},
+ {"CPSR_fsc", TRUE, PSR_f | PSR_s | PSR_c},
+ {"CPSR_fxs", TRUE, PSR_f | PSR_x | PSR_s},
+ {"CPSR_fxc", TRUE, PSR_f | PSR_x | PSR_c},
+ {"CPSR_fcs", TRUE, PSR_f | PSR_c | PSR_s},
+ {"CPSR_fcx", TRUE, PSR_f | PSR_c | PSR_x},
+ {"CPSR_sfx", TRUE, PSR_s | PSR_f | PSR_x},
+ {"CPSR_sfc", TRUE, PSR_s | PSR_f | PSR_c},
+ {"CPSR_sxf", TRUE, PSR_s | PSR_x | PSR_f},
+ {"CPSR_sxc", TRUE, PSR_s | PSR_x | PSR_c},
+ {"CPSR_scf", TRUE, PSR_s | PSR_c | PSR_f},
+ {"CPSR_scx", TRUE, PSR_s | PSR_c | PSR_x},
+ {"CPSR_xfs", TRUE, PSR_x | PSR_f | PSR_s},
+ {"CPSR_xfc", TRUE, PSR_x | PSR_f | PSR_c},
+ {"CPSR_xsf", TRUE, PSR_x | PSR_s | PSR_f},
+ {"CPSR_xsc", TRUE, PSR_x | PSR_s | PSR_c},
+ {"CPSR_xcf", TRUE, PSR_x | PSR_c | PSR_f},
+ {"CPSR_xcs", TRUE, PSR_x | PSR_c | PSR_s},
+ {"CPSR_cfs", TRUE, PSR_c | PSR_f | PSR_s},
+ {"CPSR_cfx", TRUE, PSR_c | PSR_f | PSR_x},
+ {"CPSR_csf", TRUE, PSR_c | PSR_s | PSR_f},
+ {"CPSR_csx", TRUE, PSR_c | PSR_s | PSR_x},
+ {"CPSR_cxf", TRUE, PSR_c | PSR_x | PSR_f},
+ {"CPSR_cxs", TRUE, PSR_c | PSR_x | PSR_s},
+ {"CPSR_fsxc", TRUE, PSR_f | PSR_s | PSR_x | PSR_c},
+ {"CPSR_fscx", TRUE, PSR_f | PSR_s | PSR_c | PSR_x},
+ {"CPSR_fxsc", TRUE, PSR_f | PSR_x | PSR_s | PSR_c},
+ {"CPSR_fxcs", TRUE, PSR_f | PSR_x | PSR_c | PSR_s},
+ {"CPSR_fcsx", TRUE, PSR_f | PSR_c | PSR_s | PSR_x},
+ {"CPSR_fcxs", TRUE, PSR_f | PSR_c | PSR_x | PSR_s},
+ {"CPSR_sfxc", TRUE, PSR_s | PSR_f | PSR_x | PSR_c},
+ {"CPSR_sfcx", TRUE, PSR_s | PSR_f | PSR_c | PSR_x},
+ {"CPSR_sxfc", TRUE, PSR_s | PSR_x | PSR_f | PSR_c},
+ {"CPSR_sxcf", TRUE, PSR_s | PSR_x | PSR_c | PSR_f},
+ {"CPSR_scfx", TRUE, PSR_s | PSR_c | PSR_f | PSR_x},
+ {"CPSR_scxf", TRUE, PSR_s | PSR_c | PSR_x | PSR_f},
+ {"CPSR_xfsc", TRUE, PSR_x | PSR_f | PSR_s | PSR_c},
+ {"CPSR_xfcs", TRUE, PSR_x | PSR_f | PSR_c | PSR_s},
+ {"CPSR_xsfc", TRUE, PSR_x | PSR_s | PSR_f | PSR_c},
+ {"CPSR_xscf", TRUE, PSR_x | PSR_s | PSR_c | PSR_f},
+ {"CPSR_xcfs", TRUE, PSR_x | PSR_c | PSR_f | PSR_s},
+ {"CPSR_xcsf", TRUE, PSR_x | PSR_c | PSR_s | PSR_f},
+ {"CPSR_cfsx", TRUE, PSR_c | PSR_f | PSR_s | PSR_x},
+ {"CPSR_cfxs", TRUE, PSR_c | PSR_f | PSR_x | PSR_s},
+ {"CPSR_csfx", TRUE, PSR_c | PSR_s | PSR_f | PSR_x},
+ {"CPSR_csxf", TRUE, PSR_c | PSR_s | PSR_x | PSR_f},
+ {"CPSR_cxfs", TRUE, PSR_c | PSR_x | PSR_f | PSR_s},
+ {"CPSR_cxsf", TRUE, PSR_c | PSR_x | PSR_s | PSR_f},
+ {"SPSR_fs", FALSE, PSR_f | PSR_s},
+ {"SPSR_fx", FALSE, PSR_f | PSR_x},
+ {"SPSR_fc", FALSE, PSR_f | PSR_c},
+ {"SPSR_sf", FALSE, PSR_s | PSR_f},
+ {"SPSR_sx", FALSE, PSR_s | PSR_x},
+ {"SPSR_sc", FALSE, PSR_s | PSR_c},
+ {"SPSR_xf", FALSE, PSR_x | PSR_f},
+ {"SPSR_xs", FALSE, PSR_x | PSR_s},
+ {"SPSR_xc", FALSE, PSR_x | PSR_c},
+ {"SPSR_cf", FALSE, PSR_c | PSR_f},
+ {"SPSR_cs", FALSE, PSR_c | PSR_s},
+ {"SPSR_cx", FALSE, PSR_c | PSR_x},
+ {"SPSR_fsx", FALSE, PSR_f | PSR_s | PSR_x},
+ {"SPSR_fsc", FALSE, PSR_f | PSR_s | PSR_c},
+ {"SPSR_fxs", FALSE, PSR_f | PSR_x | PSR_s},
+ {"SPSR_fxc", FALSE, PSR_f | PSR_x | PSR_c},
+ {"SPSR_fcs", FALSE, PSR_f | PSR_c | PSR_s},
+ {"SPSR_fcx", FALSE, PSR_f | PSR_c | PSR_x},
+ {"SPSR_sfx", FALSE, PSR_s | PSR_f | PSR_x},
+ {"SPSR_sfc", FALSE, PSR_s | PSR_f | PSR_c},
+ {"SPSR_sxf", FALSE, PSR_s | PSR_x | PSR_f},
+ {"SPSR_sxc", FALSE, PSR_s | PSR_x | PSR_c},
+ {"SPSR_scf", FALSE, PSR_s | PSR_c | PSR_f},
+ {"SPSR_scx", FALSE, PSR_s | PSR_c | PSR_x},
+ {"SPSR_xfs", FALSE, PSR_x | PSR_f | PSR_s},
+ {"SPSR_xfc", FALSE, PSR_x | PSR_f | PSR_c},
+ {"SPSR_xsf", FALSE, PSR_x | PSR_s | PSR_f},
+ {"SPSR_xsc", FALSE, PSR_x | PSR_s | PSR_c},
+ {"SPSR_xcf", FALSE, PSR_x | PSR_c | PSR_f},
+ {"SPSR_xcs", FALSE, PSR_x | PSR_c | PSR_s},
+ {"SPSR_cfs", FALSE, PSR_c | PSR_f | PSR_s},
+ {"SPSR_cfx", FALSE, PSR_c | PSR_f | PSR_x},
+ {"SPSR_csf", FALSE, PSR_c | PSR_s | PSR_f},
+ {"SPSR_csx", FALSE, PSR_c | PSR_s | PSR_x},
+ {"SPSR_cxf", FALSE, PSR_c | PSR_x | PSR_f},
+ {"SPSR_cxs", FALSE, PSR_c | PSR_x | PSR_s},
+ {"SPSR_fsxc", FALSE, PSR_f | PSR_s | PSR_x | PSR_c},
+ {"SPSR_fscx", FALSE, PSR_f | PSR_s | PSR_c | PSR_x},
+ {"SPSR_fxsc", FALSE, PSR_f | PSR_x | PSR_s | PSR_c},
+ {"SPSR_fxcs", FALSE, PSR_f | PSR_x | PSR_c | PSR_s},
+ {"SPSR_fcsx", FALSE, PSR_f | PSR_c | PSR_s | PSR_x},
+ {"SPSR_fcxs", FALSE, PSR_f | PSR_c | PSR_x | PSR_s},
+ {"SPSR_sfxc", FALSE, PSR_s | PSR_f | PSR_x | PSR_c},
+ {"SPSR_sfcx", FALSE, PSR_s | PSR_f | PSR_c | PSR_x},
+ {"SPSR_sxfc", FALSE, PSR_s | PSR_x | PSR_f | PSR_c},
+ {"SPSR_sxcf", FALSE, PSR_s | PSR_x | PSR_c | PSR_f},
+ {"SPSR_scfx", FALSE, PSR_s | PSR_c | PSR_f | PSR_x},
+ {"SPSR_scxf", FALSE, PSR_s | PSR_c | PSR_x | PSR_f},
+ {"SPSR_xfsc", FALSE, PSR_x | PSR_f | PSR_s | PSR_c},
+ {"SPSR_xfcs", FALSE, PSR_x | PSR_f | PSR_c | PSR_s},
+ {"SPSR_xsfc", FALSE, PSR_x | PSR_s | PSR_f | PSR_c},
+ {"SPSR_xscf", FALSE, PSR_x | PSR_s | PSR_c | PSR_f},
+ {"SPSR_xcfs", FALSE, PSR_x | PSR_c | PSR_f | PSR_s},
+ {"SPSR_xcsf", FALSE, PSR_x | PSR_c | PSR_s | PSR_f},
+ {"SPSR_cfsx", FALSE, PSR_c | PSR_f | PSR_s | PSR_x},
+ {"SPSR_cfxs", FALSE, PSR_c | PSR_f | PSR_x | PSR_s},
+ {"SPSR_csfx", FALSE, PSR_c | PSR_s | PSR_f | PSR_x},
+ {"SPSR_csxf", FALSE, PSR_c | PSR_s | PSR_x | PSR_f},
+ {"SPSR_cxfs", FALSE, PSR_c | PSR_x | PSR_f | PSR_s},
+ {"SPSR_cxsf", FALSE, PSR_c | PSR_x | PSR_s | PSR_f},
+};
+
+enum wreg_type
+ {
+ IWMMXT_REG_WR = 0,
+ IWMMXT_REG_WC = 1,
+ IWMMXT_REG_WR_OR_WC = 2,
+ IWMMXT_REG_WCG
+ };
+
+enum iwmmxt_insn_type
+{
+ check_rd,
+ check_wr,
+ check_wrwr,
+ check_wrwrwr,
+ check_wrwrwcg,
+ check_tbcst,
+ check_tmovmsk,
+ check_tmia,
+ check_tmcrr,
+ check_tmrrc,
+ check_tmcr,
+ check_tmrc,
+ check_tinsr,
+ check_textrc,
+ check_waligni,
+ check_textrm,
+ check_wshufh
};
enum vfp_dp_reg_pos
@@ -536,6 +603,7 @@ struct reg_entry
{
const char * name;
int number;
+ bfd_boolean builtin;
};
/* Some well known registers that we refer to directly elsewhere. */
@@ -543,129 +611,168 @@ struct reg_entry
#define REG_LR 14
#define REG_PC 15
-/* These are the standard names. Users can add aliases with .req. */
+#define wr_register(reg) ((reg ^ WR_PREFIX) >= 0 && (reg ^ WR_PREFIX) <= 15)
+#define wc_register(reg) ((reg ^ WC_PREFIX) >= 0 && (reg ^ WC_PREFIX) <= 15)
+#define wcg_register(reg) ((reg ^ WC_PREFIX) >= 8 && (reg ^ WC_PREFIX) <= 11)
+
+/* These are the standard names. Users can add aliases with .req.
+ and delete them with .unreq. */
+
/* Integer Register Numbers. */
static const struct reg_entry rn_table[] =
{
- {"r0", 0}, {"r1", 1}, {"r2", 2}, {"r3", 3},
- {"r4", 4}, {"r5", 5}, {"r6", 6}, {"r7", 7},
- {"r8", 8}, {"r9", 9}, {"r10", 10}, {"r11", 11},
- {"r12", 12}, {"r13", REG_SP}, {"r14", REG_LR}, {"r15", REG_PC},
+ {"r0", 0, TRUE}, {"r1", 1, TRUE}, {"r2", 2, TRUE}, {"r3", 3, TRUE},
+ {"r4", 4, TRUE}, {"r5", 5, TRUE}, {"r6", 6, TRUE}, {"r7", 7, TRUE},
+ {"r8", 8, TRUE}, {"r9", 9, TRUE}, {"r10", 10, TRUE}, {"r11", 11, TRUE},
+ {"r12", 12, TRUE}, {"r13", REG_SP, TRUE}, {"r14", REG_LR, TRUE}, {"r15", REG_PC, TRUE},
/* ATPCS Synonyms. */
- {"a1", 0}, {"a2", 1}, {"a3", 2}, {"a4", 3},
- {"v1", 4}, {"v2", 5}, {"v3", 6}, {"v4", 7},
- {"v5", 8}, {"v6", 9}, {"v7", 10}, {"v8", 11},
+ {"a1", 0, TRUE}, {"a2", 1, TRUE}, {"a3", 2, TRUE}, {"a4", 3, TRUE},
+ {"v1", 4, TRUE}, {"v2", 5, TRUE}, {"v3", 6, TRUE}, {"v4", 7, TRUE},
+ {"v5", 8, TRUE}, {"v6", 9, TRUE}, {"v7", 10, TRUE}, {"v8", 11, TRUE},
/* Well-known aliases. */
- {"wr", 7},
- {"sb", 9}, {"sl", 10}, {"fp", 11},
- {"ip", 12}, {"sp", REG_SP}, {"lr", REG_LR}, {"pc", REG_PC},
- {NULL, 0}
+ {"wr", 7, TRUE}, {"sb", 9, TRUE}, {"sl", 10, TRUE}, {"fp", 11, TRUE},
+ {"ip", 12, TRUE}, {"sp", REG_SP, TRUE}, {"lr", REG_LR, TRUE}, {"pc", REG_PC, TRUE},
+ {NULL, 0, TRUE}
+};
+
+#define WR_PREFIX 0x200
+#define WC_PREFIX 0x400
+
+static const struct reg_entry iwmmxt_table[] =
+{
+ /* Intel Wireless MMX technology register names. */
+ { "wr0", 0x0 | WR_PREFIX, TRUE}, {"wr1", 0x1 | WR_PREFIX, TRUE},
+ { "wr2", 0x2 | WR_PREFIX, TRUE}, {"wr3", 0x3 | WR_PREFIX, TRUE},
+ { "wr4", 0x4 | WR_PREFIX, TRUE}, {"wr5", 0x5 | WR_PREFIX, TRUE},
+ { "wr6", 0x6 | WR_PREFIX, TRUE}, {"wr7", 0x7 | WR_PREFIX, TRUE},
+ { "wr8", 0x8 | WR_PREFIX, TRUE}, {"wr9", 0x9 | WR_PREFIX, TRUE},
+ { "wr10", 0xa | WR_PREFIX, TRUE}, {"wr11", 0xb | WR_PREFIX, TRUE},
+ { "wr12", 0xc | WR_PREFIX, TRUE}, {"wr13", 0xd | WR_PREFIX, TRUE},
+ { "wr14", 0xe | WR_PREFIX, TRUE}, {"wr15", 0xf | WR_PREFIX, TRUE},
+ { "wcid", 0x0 | WC_PREFIX, TRUE}, {"wcon", 0x1 | WC_PREFIX, TRUE},
+ {"wcssf", 0x2 | WC_PREFIX, TRUE}, {"wcasf", 0x3 | WC_PREFIX, TRUE},
+ {"wcgr0", 0x8 | WC_PREFIX, TRUE}, {"wcgr1", 0x9 | WC_PREFIX, TRUE},
+ {"wcgr2", 0xa | WC_PREFIX, TRUE}, {"wcgr3", 0xb | WC_PREFIX, TRUE},
+
+ { "wR0", 0x0 | WR_PREFIX, TRUE}, {"wR1", 0x1 | WR_PREFIX, TRUE},
+ { "wR2", 0x2 | WR_PREFIX, TRUE}, {"wR3", 0x3 | WR_PREFIX, TRUE},
+ { "wR4", 0x4 | WR_PREFIX, TRUE}, {"wR5", 0x5 | WR_PREFIX, TRUE},
+ { "wR6", 0x6 | WR_PREFIX, TRUE}, {"wR7", 0x7 | WR_PREFIX, TRUE},
+ { "wR8", 0x8 | WR_PREFIX, TRUE}, {"wR9", 0x9 | WR_PREFIX, TRUE},
+ { "wR10", 0xa | WR_PREFIX, TRUE}, {"wR11", 0xb | WR_PREFIX, TRUE},
+ { "wR12", 0xc | WR_PREFIX, TRUE}, {"wR13", 0xd | WR_PREFIX, TRUE},
+ { "wR14", 0xe | WR_PREFIX, TRUE}, {"wR15", 0xf | WR_PREFIX, TRUE},
+ { "wCID", 0x0 | WC_PREFIX, TRUE}, {"wCon", 0x1 | WC_PREFIX, TRUE},
+ {"wCSSF", 0x2 | WC_PREFIX, TRUE}, {"wCASF", 0x3 | WC_PREFIX, TRUE},
+ {"wCGR0", 0x8 | WC_PREFIX, TRUE}, {"wCGR1", 0x9 | WC_PREFIX, TRUE},
+ {"wCGR2", 0xa | WC_PREFIX, TRUE}, {"wCGR3", 0xb | WC_PREFIX, TRUE},
+ {NULL, 0, TRUE}
};
/* Co-processor Numbers. */
static const struct reg_entry cp_table[] =
{
- {"p0", 0}, {"p1", 1}, {"p2", 2}, {"p3", 3},
- {"p4", 4}, {"p5", 5}, {"p6", 6}, {"p7", 7},
- {"p8", 8}, {"p9", 9}, {"p10", 10}, {"p11", 11},
- {"p12", 12}, {"p13", 13}, {"p14", 14}, {"p15", 15},
- {NULL, 0}
+ {"p0", 0, TRUE}, {"p1", 1, TRUE}, {"p2", 2, TRUE}, {"p3", 3, TRUE},
+ {"p4", 4, TRUE}, {"p5", 5, TRUE}, {"p6", 6, TRUE}, {"p7", 7, TRUE},
+ {"p8", 8, TRUE}, {"p9", 9, TRUE}, {"p10", 10, TRUE}, {"p11", 11, TRUE},
+ {"p12", 12, TRUE}, {"p13", 13, TRUE}, {"p14", 14, TRUE}, {"p15", 15, TRUE},
+ {NULL, 0, TRUE}
};
/* Co-processor Register Numbers. */
static const struct reg_entry cn_table[] =
{
- {"c0", 0}, {"c1", 1}, {"c2", 2}, {"c3", 3},
- {"c4", 4}, {"c5", 5}, {"c6", 6}, {"c7", 7},
- {"c8", 8}, {"c9", 9}, {"c10", 10}, {"c11", 11},
- {"c12", 12}, {"c13", 13}, {"c14", 14}, {"c15", 15},
+ {"c0", 0, TRUE}, {"c1", 1, TRUE}, {"c2", 2, TRUE}, {"c3", 3, TRUE},
+ {"c4", 4, TRUE}, {"c5", 5, TRUE}, {"c6", 6, TRUE}, {"c7", 7, TRUE},
+ {"c8", 8, TRUE}, {"c9", 9, TRUE}, {"c10", 10, TRUE}, {"c11", 11, TRUE},
+ {"c12", 12, TRUE}, {"c13", 13, TRUE}, {"c14", 14, TRUE}, {"c15", 15, TRUE},
/* Not really valid, but kept for back-wards compatibility. */
- {"cr0", 0}, {"cr1", 1}, {"cr2", 2}, {"cr3", 3},
- {"cr4", 4}, {"cr5", 5}, {"cr6", 6}, {"cr7", 7},
- {"cr8", 8}, {"cr9", 9}, {"cr10", 10}, {"cr11", 11},
- {"cr12", 12}, {"cr13", 13}, {"cr14", 14}, {"cr15", 15},
- {NULL, 0}
+ {"cr0", 0, TRUE}, {"cr1", 1, TRUE}, {"cr2", 2, TRUE}, {"cr3", 3, TRUE},
+ {"cr4", 4, TRUE}, {"cr5", 5, TRUE}, {"cr6", 6, TRUE}, {"cr7", 7, TRUE},
+ {"cr8", 8, TRUE}, {"cr9", 9, TRUE}, {"cr10", 10, TRUE}, {"cr11", 11, TRUE},
+ {"cr12", 12, TRUE}, {"cr13", 13, TRUE}, {"cr14", 14, TRUE}, {"cr15", 15, TRUE},
+ {NULL, 0, TRUE}
};
/* FPA Registers. */
static const struct reg_entry fn_table[] =
{
- {"f0", 0}, {"f1", 1}, {"f2", 2}, {"f3", 3},
- {"f4", 4}, {"f5", 5}, {"f6", 6}, {"f7", 7},
- {NULL, 0}
+ {"f0", 0, TRUE}, {"f1", 1, TRUE}, {"f2", 2, TRUE}, {"f3", 3, TRUE},
+ {"f4", 4, TRUE}, {"f5", 5, TRUE}, {"f6", 6, TRUE}, {"f7", 7, TRUE},
+ {NULL, 0, TRUE}
};
/* VFP SP Registers. */
static const struct reg_entry sn_table[] =
{
- {"s0", 0}, {"s1", 1}, {"s2", 2}, {"s3", 3},
- {"s4", 4}, {"s5", 5}, {"s6", 6}, {"s7", 7},
- {"s8", 8}, {"s9", 9}, {"s10", 10}, {"s11", 11},
- {"s12", 12}, {"s13", 13}, {"s14", 14}, {"s15", 15},
- {"s16", 16}, {"s17", 17}, {"s18", 18}, {"s19", 19},
- {"s20", 20}, {"s21", 21}, {"s22", 22}, {"s23", 23},
- {"s24", 24}, {"s25", 25}, {"s26", 26}, {"s27", 27},
- {"s28", 28}, {"s29", 29}, {"s30", 30}, {"s31", 31},
- {NULL, 0}
+ {"s0", 0, TRUE}, {"s1", 1, TRUE}, {"s2", 2, TRUE}, {"s3", 3, TRUE},
+ {"s4", 4, TRUE}, {"s5", 5, TRUE}, {"s6", 6, TRUE}, {"s7", 7, TRUE},
+ {"s8", 8, TRUE}, {"s9", 9, TRUE}, {"s10", 10, TRUE}, {"s11", 11, TRUE},
+ {"s12", 12, TRUE}, {"s13", 13, TRUE}, {"s14", 14, TRUE}, {"s15", 15, TRUE},
+ {"s16", 16, TRUE}, {"s17", 17, TRUE}, {"s18", 18, TRUE}, {"s19", 19, TRUE},
+ {"s20", 20, TRUE}, {"s21", 21, TRUE}, {"s22", 22, TRUE}, {"s23", 23, TRUE},
+ {"s24", 24, TRUE}, {"s25", 25, TRUE}, {"s26", 26, TRUE}, {"s27", 27, TRUE},
+ {"s28", 28, TRUE}, {"s29", 29, TRUE}, {"s30", 30, TRUE}, {"s31", 31, TRUE},
+ {NULL, 0, TRUE}
};
/* VFP DP Registers. */
static const struct reg_entry dn_table[] =
{
- {"d0", 0}, {"d1", 1}, {"d2", 2}, {"d3", 3},
- {"d4", 4}, {"d5", 5}, {"d6", 6}, {"d7", 7},
- {"d8", 8}, {"d9", 9}, {"d10", 10}, {"d11", 11},
- {"d12", 12}, {"d13", 13}, {"d14", 14}, {"d15", 15},
- {NULL, 0}
+ {"d0", 0, TRUE}, {"d1", 1, TRUE}, {"d2", 2, TRUE}, {"d3", 3, TRUE},
+ {"d4", 4, TRUE}, {"d5", 5, TRUE}, {"d6", 6, TRUE}, {"d7", 7, TRUE},
+ {"d8", 8, TRUE}, {"d9", 9, TRUE}, {"d10", 10, TRUE}, {"d11", 11, TRUE},
+ {"d12", 12, TRUE}, {"d13", 13, TRUE}, {"d14", 14, TRUE}, {"d15", 15, TRUE},
+ {NULL, 0, TRUE}
};
/* Maverick DSP coprocessor registers. */
static const struct reg_entry mav_mvf_table[] =
{
- {"mvf0", 0}, {"mvf1", 1}, {"mvf2", 2}, {"mvf3", 3},
- {"mvf4", 4}, {"mvf5", 5}, {"mvf6", 6}, {"mvf7", 7},
- {"mvf8", 8}, {"mvf9", 9}, {"mvf10", 10}, {"mvf11", 11},
- {"mvf12", 12}, {"mvf13", 13}, {"mvf14", 14}, {"mvf15", 15},
- {NULL, 0}
+ {"mvf0", 0, TRUE}, {"mvf1", 1, TRUE}, {"mvf2", 2, TRUE}, {"mvf3", 3, TRUE},
+ {"mvf4", 4, TRUE}, {"mvf5", 5, TRUE}, {"mvf6", 6, TRUE}, {"mvf7", 7, TRUE},
+ {"mvf8", 8, TRUE}, {"mvf9", 9, TRUE}, {"mvf10", 10, TRUE}, {"mvf11", 11, TRUE},
+ {"mvf12", 12, TRUE}, {"mvf13", 13, TRUE}, {"mvf14", 14, TRUE}, {"mvf15", 15, TRUE},
+ {NULL, 0, TRUE}
};
static const struct reg_entry mav_mvd_table[] =
{
- {"mvd0", 0}, {"mvd1", 1}, {"mvd2", 2}, {"mvd3", 3},
- {"mvd4", 4}, {"mvd5", 5}, {"mvd6", 6}, {"mvd7", 7},
- {"mvd8", 8}, {"mvd9", 9}, {"mvd10", 10}, {"mvd11", 11},
- {"mvd12", 12}, {"mvd13", 13}, {"mvd14", 14}, {"mvd15", 15},
- {NULL, 0}
+ {"mvd0", 0, TRUE}, {"mvd1", 1, TRUE}, {"mvd2", 2, TRUE}, {"mvd3", 3, TRUE},
+ {"mvd4", 4, TRUE}, {"mvd5", 5, TRUE}, {"mvd6", 6, TRUE}, {"mvd7", 7, TRUE},
+ {"mvd8", 8, TRUE}, {"mvd9", 9, TRUE}, {"mvd10", 10, TRUE}, {"mvd11", 11, TRUE},
+ {"mvd12", 12, TRUE}, {"mvd13", 13, TRUE}, {"mvd14", 14, TRUE}, {"mvd15", 15, TRUE},
+ {NULL, 0, TRUE}
};
static const struct reg_entry mav_mvfx_table[] =
{
- {"mvfx0", 0}, {"mvfx1", 1}, {"mvfx2", 2}, {"mvfx3", 3},
- {"mvfx4", 4}, {"mvfx5", 5}, {"mvfx6", 6}, {"mvfx7", 7},
- {"mvfx8", 8}, {"mvfx9", 9}, {"mvfx10", 10}, {"mvfx11", 11},
- {"mvfx12", 12}, {"mvfx13", 13}, {"mvfx14", 14}, {"mvfx15", 15},
- {NULL, 0}
+ {"mvfx0", 0, TRUE}, {"mvfx1", 1, TRUE}, {"mvfx2", 2, TRUE}, {"mvfx3", 3, TRUE},
+ {"mvfx4", 4, TRUE}, {"mvfx5", 5, TRUE}, {"mvfx6", 6, TRUE}, {"mvfx7", 7, TRUE},
+ {"mvfx8", 8, TRUE}, {"mvfx9", 9, TRUE}, {"mvfx10", 10, TRUE}, {"mvfx11", 11, TRUE},
+ {"mvfx12", 12, TRUE}, {"mvfx13", 13, TRUE}, {"mvfx14", 14, TRUE}, {"mvfx15", 15, TRUE},
+ {NULL, 0, TRUE}
};
static const struct reg_entry mav_mvdx_table[] =
{
- {"mvdx0", 0}, {"mvdx1", 1}, {"mvdx2", 2}, {"mvdx3", 3},
- {"mvdx4", 4}, {"mvdx5", 5}, {"mvdx6", 6}, {"mvdx7", 7},
- {"mvdx8", 8}, {"mvdx9", 9}, {"mvdx10", 10}, {"mvdx11", 11},
- {"mvdx12", 12}, {"mvdx13", 13}, {"mvdx14", 14}, {"mvdx15", 15},
- {NULL, 0}
+ {"mvdx0", 0, TRUE}, {"mvdx1", 1, TRUE}, {"mvdx2", 2, TRUE}, {"mvdx3", 3, TRUE},
+ {"mvdx4", 4, TRUE}, {"mvdx5", 5, TRUE}, {"mvdx6", 6, TRUE}, {"mvdx7", 7, TRUE},
+ {"mvdx8", 8, TRUE}, {"mvdx9", 9, TRUE}, {"mvdx10", 10, TRUE}, {"mvdx11", 11, TRUE},
+ {"mvdx12", 12, TRUE}, {"mvdx13", 13, TRUE}, {"mvdx14", 14, TRUE}, {"mvdx15", 15, TRUE},
+ {NULL, 0, TRUE}
};
static const struct reg_entry mav_mvax_table[] =
{
- {"mvax0", 0}, {"mvax1", 1}, {"mvax2", 2}, {"mvax3", 3},
- {NULL, 0}
+ {"mvax0", 0, TRUE}, {"mvax1", 1, TRUE}, {"mvax2", 2, TRUE}, {"mvax3", 3, TRUE},
+ {NULL, 0, TRUE}
};
static const struct reg_entry mav_dspsc_table[] =
{
- {"dspsc", 0},
- {NULL, 0}
+ {"dspsc", 0, TRUE},
+ {NULL, 0, TRUE}
};
struct reg_map
@@ -687,9 +794,10 @@ struct reg_map all_reg_maps[] =
{mav_mvf_table, 15, NULL, N_("Maverick MVF register expected")},
{mav_mvd_table, 15, NULL, N_("Maverick MVD register expected")},
{mav_mvfx_table, 15, NULL, N_("Maverick MVFX register expected")},
- {mav_mvdx_table, 15, NULL, N_("Maverick MVFX register expected")},
+ {mav_mvdx_table, 15, NULL, N_("Maverick MVDX register expected")},
{mav_mvax_table, 3, NULL, N_("Maverick MVAX register expected")},
{mav_dspsc_table, 0, NULL, N_("Maverick DSPSC register expected")},
+ {iwmmxt_table, 23, NULL, N_("Intel Wireless MMX technology register expected")},
};
/* Enumeration matching entries in table above. */
@@ -708,8 +816,9 @@ enum arm_reg_type
REG_TYPE_MVDX = 9,
REG_TYPE_MVAX = 10,
REG_TYPE_DSPSC = 11,
+ REG_TYPE_IWMMXT = 12,
- REG_TYPE_MAX = 12
+ REG_TYPE_MAX = 13
};
/* Functions called by parser. */
@@ -770,6 +879,36 @@ static void do_co_reg2c PARAMS ((char *));
/* ARM v5TEJ. */
static void do_bxj PARAMS ((char *));
+/* ARM V6. */
+static void do_cps PARAMS ((char *));
+static void do_cpsi PARAMS ((char *));
+static void do_ldrex PARAMS ((char *));
+static void do_pkhbt PARAMS ((char *));
+static void do_pkhtb PARAMS ((char *));
+static void do_qadd16 PARAMS ((char *));
+static void do_rev PARAMS ((char *));
+static void do_rfe PARAMS ((char *));
+static void do_sxtah PARAMS ((char *));
+static void do_sxth PARAMS ((char *));
+static void do_setend PARAMS ((char *));
+static void do_smlad PARAMS ((char *));
+static void do_smlald PARAMS ((char *));
+static void do_smmul PARAMS ((char *));
+static void do_ssat PARAMS ((char *));
+static void do_usat PARAMS ((char *));
+static void do_srs PARAMS ((char *));
+static void do_ssat16 PARAMS ((char *));
+static void do_usat16 PARAMS ((char *));
+static void do_strex PARAMS ((char *));
+static void do_umaal PARAMS ((char *));
+
+static void do_cps_mode PARAMS ((char **));
+static void do_cps_flags PARAMS ((char **, int));
+static int do_endian_specifier PARAMS ((char *));
+static void do_pkh_core PARAMS ((char *, int));
+static void do_sat PARAMS ((char **, int));
+static void do_sat16 PARAMS ((char **, int));
+
/* Coprocessor Instructions. */
static void do_cdp PARAMS ((char *));
static void do_lstc PARAMS ((char *));
@@ -792,7 +931,8 @@ static void do_vfp_sp_dyadic PARAMS ((char *));
static void do_vfp_dp_dyadic PARAMS ((char *));
static void do_vfp_reg_from_sp PARAMS ((char *));
static void do_vfp_sp_from_reg PARAMS ((char *));
-static void do_vfp_sp_reg2 PARAMS ((char *));
+static void do_vfp_reg2_from_sp2 PARAMS ((char *));
+static void do_vfp_sp2_from_reg2 PARAMS ((char *));
static void do_vfp_reg_from_dp PARAMS ((char *));
static void do_vfp_reg2_from_dp PARAMS ((char *));
static void do_vfp_dp_from_reg PARAMS ((char *));
@@ -938,6 +1078,31 @@ static symbolS * find_real_start PARAMS ((symbolS *));
static bfd_reloc_code_real_type arm_parse_reloc PARAMS ((void));
#endif
+static int wreg_required_here PARAMS ((char **, int, enum wreg_type));
+static void do_iwmmxt_byte_addr PARAMS ((char *));
+static void do_iwmmxt_tandc PARAMS ((char *));
+static void do_iwmmxt_tbcst PARAMS ((char *));
+static void do_iwmmxt_textrc PARAMS ((char *));
+static void do_iwmmxt_textrm PARAMS ((char *));
+static void do_iwmmxt_tinsr PARAMS ((char *));
+static void do_iwmmxt_tmcr PARAMS ((char *));
+static void do_iwmmxt_tmcrr PARAMS ((char *));
+static void do_iwmmxt_tmia PARAMS ((char *));
+static void do_iwmmxt_tmovmsk PARAMS ((char *));
+static void do_iwmmxt_tmrc PARAMS ((char *));
+static void do_iwmmxt_tmrrc PARAMS ((char *));
+static void do_iwmmxt_torc PARAMS ((char *));
+static void do_iwmmxt_waligni PARAMS ((char *));
+static void do_iwmmxt_wmov PARAMS ((char *));
+static void do_iwmmxt_word_addr PARAMS ((char *));
+static void do_iwmmxt_wrwr PARAMS ((char *));
+static void do_iwmmxt_wrwrwcg PARAMS ((char *));
+static void do_iwmmxt_wrwrwr PARAMS ((char *));
+static void do_iwmmxt_wshufh PARAMS ((char *));
+static void do_iwmmxt_wzero PARAMS ((char *));
+static int cp_byte_address_offset PARAMS ((char **));
+static int cp_byte_address_required_here PARAMS ((char **));
+
/* ARM instructions take 4bytes in the object file, Thumb instructions
take 2: */
#define INSN_SIZE 4
@@ -948,8 +1113,8 @@ static bfd_reloc_code_real_type arm_parse_reloc PARAMS ((void));
/* "INSN<cond> X,Y" where X:bit16, Y:bit12. */
#define MAV_MODE2 0x0c10
-/* "INSN<cond> X,Y" where X:0, Y:bit16. */
-#define MAV_MODE3 0x1000
+/* "INSN<cond> X,Y" where X:bit12, Y:bit16. */
+#define MAV_MODE3 0x100c
/* "INSN<cond> X,Y,Z" where X:16, Y:0, Z:12. */
#define MAV_MODE4 0x0c0010
@@ -1069,7 +1234,7 @@ static const struct asm_opcode insns[] =
{"mla", 0xe0200090, 3, ARM_EXT_V2, do_mla},
{"mlas", 0xe0300090, 3, ARM_EXT_V2, do_mla},
- /* Generic copressor instructions. */
+ /* Generic coprocessor instructions. */
{"cdp", 0xee000000, 3, ARM_EXT_V2, do_cdp},
{"ldc", 0xec100000, 3, ARM_EXT_V2, do_lstc},
{"ldcl", 0xec500000, 3, ARM_EXT_V2, do_lstc},
@@ -1162,6 +1327,107 @@ static const struct asm_opcode insns[] =
/* ARM Architecture 5TEJ. */
{"bxj", 0xe12fff20, 3, ARM_EXT_V5J, do_bxj},
+ /* ARM V6. */
+ { "cps", 0xf1020000, 0, ARM_EXT_V6, do_cps},
+ { "cpsie", 0xf1080000, 0, ARM_EXT_V6, do_cpsi},
+ { "cpsid", 0xf10C0000, 0, ARM_EXT_V6, do_cpsi},
+ { "ldrex", 0xe1900f9f, 5, ARM_EXT_V6, do_ldrex},
+ { "mcrr2", 0xfc400000, 0, ARM_EXT_V6, do_co_reg2c},
+ { "mrrc2", 0xfc500000, 0, ARM_EXT_V6, do_co_reg2c},
+ { "pkhbt", 0xe6800010, 5, ARM_EXT_V6, do_pkhbt},
+ { "pkhtb", 0xe6800050, 5, ARM_EXT_V6, do_pkhtb},
+ { "qadd16", 0xe6200f10, 6, ARM_EXT_V6, do_qadd16},
+ { "qadd8", 0xe6200f90, 5, ARM_EXT_V6, do_qadd16},
+ { "qaddsubx", 0xe6200f30, 8, ARM_EXT_V6, do_qadd16},
+ { "qsub16", 0xe6200f70, 6, ARM_EXT_V6, do_qadd16},
+ { "qsub8", 0xe6200ff0, 5, ARM_EXT_V6, do_qadd16},
+ { "qsubaddx", 0xe6200f50, 8, ARM_EXT_V6, do_qadd16},
+ { "sadd16", 0xe6100f10, 6, ARM_EXT_V6, do_qadd16},
+ { "sadd8", 0xe6100f90, 5, ARM_EXT_V6, do_qadd16},
+ { "saddsubx", 0xe6100f30, 8, ARM_EXT_V6, do_qadd16},
+ { "shadd16", 0xe6300f10, 7, ARM_EXT_V6, do_qadd16},
+ { "shadd8", 0xe6300f90, 6, ARM_EXT_V6, do_qadd16},
+ { "shaddsubx", 0xe6300f30, 9, ARM_EXT_V6, do_qadd16},
+ { "shsub16", 0xe6300f70, 7, ARM_EXT_V6, do_qadd16},
+ { "shsub8", 0xe6300ff0, 6, ARM_EXT_V6, do_qadd16},
+ { "shsubaddx", 0xe6300f50, 9, ARM_EXT_V6, do_qadd16},
+ { "ssub16", 0xe6100f70, 6, ARM_EXT_V6, do_qadd16},
+ { "ssub8", 0xe6100ff0, 5, ARM_EXT_V6, do_qadd16},
+ { "ssubaddx", 0xe6100f50, 8, ARM_EXT_V6, do_qadd16},
+ { "uadd16", 0xe6500f10, 6, ARM_EXT_V6, do_qadd16},
+ { "uadd8", 0xe6500f90, 5, ARM_EXT_V6, do_qadd16},
+ { "uaddsubx", 0xe6500f30, 8, ARM_EXT_V6, do_qadd16},
+ { "uhadd16", 0xe6700f10, 7, ARM_EXT_V6, do_qadd16},
+ { "uhadd8", 0xe6700f90, 6, ARM_EXT_V6, do_qadd16},
+ { "uhaddsubx", 0xe6700f30, 9, ARM_EXT_V6, do_qadd16},
+ { "uhsub16", 0xe6700f70, 7, ARM_EXT_V6, do_qadd16},
+ { "uhsub8", 0xe6700ff0, 6, ARM_EXT_V6, do_qadd16},
+ { "uhsubaddx", 0xe6700f50, 9, ARM_EXT_V6, do_qadd16},
+ { "uqadd16", 0xe6600f10, 7, ARM_EXT_V6, do_qadd16},
+ { "uqadd8", 0xe6600f90, 6, ARM_EXT_V6, do_qadd16},
+ { "uqaddsubx", 0xe6600f30, 9, ARM_EXT_V6, do_qadd16},
+ { "uqsub16", 0xe6600f70, 7, ARM_EXT_V6, do_qadd16},
+ { "uqsub8", 0xe6600ff0, 6, ARM_EXT_V6, do_qadd16},
+ { "uqsubaddx", 0xe6600f50, 9, ARM_EXT_V6, do_qadd16},
+ { "usub16", 0xe6500f70, 6, ARM_EXT_V6, do_qadd16},
+ { "usub8", 0xe6500ff0, 5, ARM_EXT_V6, do_qadd16},
+ { "usubaddx", 0xe6500f50, 8, ARM_EXT_V6, do_qadd16},
+ { "rev", 0xe6bf0f30, 3, ARM_EXT_V6, do_rev},
+ { "rev16", 0xe6bf0fb0, 5, ARM_EXT_V6, do_rev},
+ { "revsh", 0xe6ff0fb0, 5, ARM_EXT_V6, do_rev},
+ { "rfeia", 0xf8900a00, 0, ARM_EXT_V6, do_rfe},
+ { "rfeib", 0xf9900a00, 0, ARM_EXT_V6, do_rfe},
+ { "rfeda", 0xf8100a00, 0, ARM_EXT_V6, do_rfe},
+ { "rfedb", 0xf9100a00, 0, ARM_EXT_V6, do_rfe},
+ { "rfefd", 0xf8900a00, 0, ARM_EXT_V6, do_rfe},
+ { "rfefa", 0xf9900a00, 0, ARM_EXT_V6, do_rfe},
+ { "rfeea", 0xf8100a00, 0, ARM_EXT_V6, do_rfe},
+ { "rfeed", 0xf9100a00, 0, ARM_EXT_V6, do_rfe},
+ { "sxtah", 0xe6b00070, 5, ARM_EXT_V6, do_sxtah},
+ { "sxtab16", 0xe6800070, 7, ARM_EXT_V6, do_sxtah},
+ { "sxtab", 0xe6a00070, 5, ARM_EXT_V6, do_sxtah},
+ { "sxth", 0xe6bf0070, 4, ARM_EXT_V6, do_sxth},
+ { "sxtb16", 0xe68f0070, 6, ARM_EXT_V6, do_sxth},
+ { "sxtb", 0xe6af0070, 4, ARM_EXT_V6, do_sxth},
+ { "uxtah", 0xe6f00070, 5, ARM_EXT_V6, do_sxtah},
+ { "uxtab16", 0xe6c00070, 7, ARM_EXT_V6, do_sxtah},
+ { "uxtab", 0xe6e00070, 5, ARM_EXT_V6, do_sxtah},
+ { "uxth", 0xe6ff0070, 4, ARM_EXT_V6, do_sxth},
+ { "uxtb16", 0xe6cf0070, 6, ARM_EXT_V6, do_sxth},
+ { "uxtb", 0xe6ef0070, 4, ARM_EXT_V6, do_sxth},
+ { "sel", 0xe68000b0, 3, ARM_EXT_V6, do_qadd16},
+ { "setend", 0xf1010000, 0, ARM_EXT_V6, do_setend},
+ { "smlad", 0xe7000010, 5, ARM_EXT_V6, do_smlad},
+ { "smladx", 0xe7000030, 6, ARM_EXT_V6, do_smlad},
+ { "smlald", 0xe7400010, 6, ARM_EXT_V6, do_smlald},
+ { "smlaldx", 0xe7400030, 7, ARM_EXT_V6, do_smlald},
+ { "smlsd", 0xe7000050, 5, ARM_EXT_V6, do_smlad},
+ { "smlsdx", 0xe7000070, 6, ARM_EXT_V6, do_smlad},
+ { "smlsld", 0xe7400050, 6, ARM_EXT_V6, do_smlald},
+ { "smlsldx", 0xe7400070, 7, ARM_EXT_V6, do_smlald},
+ { "smmla", 0xe7500010, 5, ARM_EXT_V6, do_smlad},
+ { "smmlar", 0xe7500030, 6, ARM_EXT_V6, do_smlad},
+ { "smmls", 0xe75000d0, 5, ARM_EXT_V6, do_smlad},
+ { "smmlsr", 0xe75000f0, 6, ARM_EXT_V6, do_smlad},
+ { "smmul", 0xe750f010, 5, ARM_EXT_V6, do_smmul},
+ { "smmulr", 0xe750f030, 6, ARM_EXT_V6, do_smmul},
+ { "smuad", 0xe700f010, 5, ARM_EXT_V6, do_smmul},
+ { "smuadx", 0xe700f030, 6, ARM_EXT_V6, do_smmul},
+ { "smusd", 0xe700f050, 5, ARM_EXT_V6, do_smmul},
+ { "smusdx", 0xe700f070, 6, ARM_EXT_V6, do_smmul},
+ { "srsia", 0xf8cd0500, 0, ARM_EXT_V6, do_srs},
+ { "srsib", 0xf9cd0500, 0, ARM_EXT_V6, do_srs},
+ { "srsda", 0xf84d0500, 0, ARM_EXT_V6, do_srs},
+ { "srsdb", 0xf94d0500, 0, ARM_EXT_V6, do_srs},
+ { "ssat", 0xe6a00010, 4, ARM_EXT_V6, do_ssat},
+ { "ssat16", 0xe6a00f30, 6, ARM_EXT_V6, do_ssat16},
+ { "strex", 0xe1800f90, 5, ARM_EXT_V6, do_strex},
+ { "umaal", 0xe0400090, 5, ARM_EXT_V6, do_umaal},
+ { "usad8", 0xe780f010, 5, ARM_EXT_V6, do_smmul},
+ { "usada8", 0xe7800010, 6, ARM_EXT_V6, do_smlad},
+ { "usat", 0xe6e00010, 4, ARM_EXT_V6, do_usat},
+ { "usat16", 0xe6e00f30, 6, ARM_EXT_V6, do_usat16},
+
/* Core FPA instruction set (V1). */
{"wfs", 0xee200110, 3, FPU_FPA_EXT_V1, do_fpa_ctrl},
{"rfs", 0xee300110, 3, FPU_FPA_EXT_V1, do_fpa_ctrl},
@@ -1713,8 +1979,8 @@ static const struct asm_opcode insns[] =
{"fcmpezd", 0xeeb50bc0, 7, FPU_VFP_EXT_V1, do_vfp_dp_compare_z},
/* VFP V2. */
- {"fmsrr", 0xec400a10, 5, FPU_VFP_EXT_V2, do_vfp_sp_reg2},
- {"fmrrs", 0xec500a10, 5, FPU_VFP_EXT_V2, do_vfp_sp_reg2},
+ {"fmsrr", 0xec400a10, 5, FPU_VFP_EXT_V2, do_vfp_sp2_from_reg2},
+ {"fmrrs", 0xec500a10, 5, FPU_VFP_EXT_V2, do_vfp_reg2_from_sp2},
{"fmdrr", 0xec400b10, 5, FPU_VFP_EXT_V2, do_vfp_dp_from_reg2},
{"fmrrd", 0xec500b10, 5, FPU_VFP_EXT_V2, do_vfp_reg2_from_dp},
@@ -1728,6 +1994,170 @@ static const struct asm_opcode insns[] =
{"mar", 0xec400000, 3, ARM_CEXT_XSCALE, do_xsc_mar},
{"mra", 0xec500000, 3, ARM_CEXT_XSCALE, do_xsc_mra},
+ /* Intel Wireless MMX technology instructions. */
+ {"tandcb", 0xee130130, 6, ARM_CEXT_IWMMXT, do_iwmmxt_tandc},
+ {"tandch", 0xee530130, 6, ARM_CEXT_IWMMXT, do_iwmmxt_tandc},
+ {"tandcw", 0xee930130, 6, ARM_CEXT_IWMMXT, do_iwmmxt_tandc},
+ {"tbcstb", 0xee400010, 6, ARM_CEXT_IWMMXT, do_iwmmxt_tbcst},
+ {"tbcsth", 0xee400050, 6, ARM_CEXT_IWMMXT, do_iwmmxt_tbcst},
+ {"tbcstw", 0xee400090, 6, ARM_CEXT_IWMMXT, do_iwmmxt_tbcst},
+ {"textrcb", 0xee130170, 7, ARM_CEXT_IWMMXT, do_iwmmxt_textrc},
+ {"textrch", 0xee530170, 7, ARM_CEXT_IWMMXT, do_iwmmxt_textrc},
+ {"textrcw", 0xee930170, 7, ARM_CEXT_IWMMXT, do_iwmmxt_textrc},
+ {"textrmub", 0xee100070, 8, ARM_CEXT_IWMMXT, do_iwmmxt_textrm},
+ {"textrmuh", 0xee500070, 8, ARM_CEXT_IWMMXT, do_iwmmxt_textrm},
+ {"textrmuw", 0xee900070, 8, ARM_CEXT_IWMMXT, do_iwmmxt_textrm},
+ {"textrmsb", 0xee100078, 8, ARM_CEXT_IWMMXT, do_iwmmxt_textrm},
+ {"textrmsh", 0xee500078, 8, ARM_CEXT_IWMMXT, do_iwmmxt_textrm},
+ {"textrmsw", 0xee900078, 8, ARM_CEXT_IWMMXT, do_iwmmxt_textrm},
+ {"tinsrb", 0xee600010, 6, ARM_CEXT_IWMMXT, do_iwmmxt_tinsr},
+ {"tinsrh", 0xee600050, 6, ARM_CEXT_IWMMXT, do_iwmmxt_tinsr},
+ {"tinsrw", 0xee600090, 6, ARM_CEXT_IWMMXT, do_iwmmxt_tinsr},
+ {"tmcr", 0xee000110, 4, ARM_CEXT_IWMMXT, do_iwmmxt_tmcr},
+ {"tmcrr", 0xec400000, 5, ARM_CEXT_IWMMXT, do_iwmmxt_tmcrr},
+ {"tmia", 0xee200010, 4, ARM_CEXT_IWMMXT, do_iwmmxt_tmia},
+ {"tmiaph", 0xee280010, 6, ARM_CEXT_IWMMXT, do_iwmmxt_tmia},
+ {"tmiabb", 0xee2c0010, 6, ARM_CEXT_IWMMXT, do_iwmmxt_tmia},
+ {"tmiabt", 0xee2d0010, 6, ARM_CEXT_IWMMXT, do_iwmmxt_tmia},
+ {"tmiatb", 0xee2e0010, 6, ARM_CEXT_IWMMXT, do_iwmmxt_tmia},
+ {"tmiatt", 0xee2f0010, 6, ARM_CEXT_IWMMXT, do_iwmmxt_tmia},
+ {"tmovmskb", 0xee100030, 8, ARM_CEXT_IWMMXT, do_iwmmxt_tmovmsk},
+ {"tmovmskh", 0xee500030, 8, ARM_CEXT_IWMMXT, do_iwmmxt_tmovmsk},
+ {"tmovmskw", 0xee900030, 8, ARM_CEXT_IWMMXT, do_iwmmxt_tmovmsk},
+ {"tmrc", 0xee100110, 4, ARM_CEXT_IWMMXT, do_iwmmxt_tmrc},
+ {"tmrrc", 0xec500000, 5, ARM_CEXT_IWMMXT, do_iwmmxt_tmrrc},
+ {"torcb", 0xee130150, 5, ARM_CEXT_IWMMXT, do_iwmmxt_torc},
+ {"torch", 0xee530150, 5, ARM_CEXT_IWMMXT, do_iwmmxt_torc},
+ {"torcw", 0xee930150, 5, ARM_CEXT_IWMMXT, do_iwmmxt_torc},
+ {"waccb", 0xee0001c0, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwr},
+ {"wacch", 0xee4001c0, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwr},
+ {"waccw", 0xee8001c0, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwr},
+ {"waddbss", 0xee300180, 7, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"waddb", 0xee000180, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"waddbus", 0xee100180, 7, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"waddhss", 0xee700180, 7, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"waddh", 0xee400180, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"waddhus", 0xee500180, 7, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"waddwss", 0xeeb00180, 7, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"waddw", 0xee800180, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"waddwus", 0xee900180, 7, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"waligni", 0xee000020, 7, ARM_CEXT_IWMMXT, do_iwmmxt_waligni},
+ {"walignr0", 0xee800020, 8, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"walignr1", 0xee900020, 8, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"walignr2", 0xeea00020, 8, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"walignr3", 0xeeb00020, 8, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wand", 0xee200000, 4, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wandn", 0xee300000, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wavg2b", 0xee800000, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wavg2br", 0xee900000, 7, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wavg2h", 0xeec00000, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wavg2hr", 0xeed00000, 7, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wcmpeqb", 0xee000060, 7, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wcmpeqh", 0xee400060, 7, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wcmpeqw", 0xee800060, 7, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wcmpgtub", 0xee100060, 8, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wcmpgtuh", 0xee500060, 8, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wcmpgtuw", 0xee900060, 8, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wcmpgtsb", 0xee300060, 8, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wcmpgtsh", 0xee700060, 8, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wcmpgtsw", 0xeeb00060, 8, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wldrb", 0xec100000, 5, ARM_CEXT_IWMMXT, do_iwmmxt_byte_addr},
+ {"wldrh", 0xec100100, 5, ARM_CEXT_IWMMXT, do_iwmmxt_byte_addr},
+ {"wldrw", 0xec100200, 5, ARM_CEXT_IWMMXT, do_iwmmxt_word_addr},
+ {"wldrd", 0xec100300, 5, ARM_CEXT_IWMMXT, do_iwmmxt_word_addr},
+ {"wmacs", 0xee600100, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wmacsz", 0xee700100, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wmacu", 0xee400100, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wmacuz", 0xee500100, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wmadds", 0xeea00100, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wmaddu", 0xee800100, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wmaxsb", 0xee200160, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wmaxsh", 0xee600160, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wmaxsw", 0xeea00160, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wmaxub", 0xee000160, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wmaxuh", 0xee400160, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wmaxuw", 0xee800160, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wminsb", 0xee300160, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wminsh", 0xee700160, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wminsw", 0xeeb00160, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wminub", 0xee100160, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wminuh", 0xee500160, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wminuw", 0xee900160, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wmov", 0xee000000, 4, ARM_CEXT_IWMMXT, do_iwmmxt_wmov},
+ {"wmulsm", 0xee300100, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wmulsl", 0xee200100, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wmulum", 0xee100100, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wmulul", 0xee000100, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wor", 0xee000000, 3, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wpackhss", 0xee700080, 8, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wpackhus", 0xee500080, 8, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wpackwss", 0xeeb00080, 8, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wpackwus", 0xee900080, 8, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wpackdss", 0xeef00080, 8, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wpackdus", 0xeed00080, 8, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wrorh", 0xee700040, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wrorhg", 0xee700148, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwcg},
+ {"wrorw", 0xeeb00040, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wrorwg", 0xeeb00148, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwcg},
+ {"wrord", 0xeef00040, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wrordg", 0xeef00148, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwcg},
+ {"wsadb", 0xee000120, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsadbz", 0xee100120, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsadh", 0xee400120, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsadhz", 0xee500120, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wshufh", 0xee0001e0, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wshufh},
+ {"wsllh", 0xee500040, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsllhg", 0xee500148, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwcg},
+ {"wsllw", 0xee900040, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsllwg", 0xee900148, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwcg},
+ {"wslld", 0xeed00040, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wslldg", 0xeed00148, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwcg},
+ {"wsrah", 0xee400040, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsrahg", 0xee400148, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwcg},
+ {"wsraw", 0xee800040, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsrawg", 0xee800148, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwcg},
+ {"wsrad", 0xeec00040, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsradg", 0xeec00148, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwcg},
+ {"wsrlh", 0xee600040, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsrlhg", 0xee600148, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwcg},
+ {"wsrlw", 0xeea00040, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsrlwg", 0xeea00148, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwcg},
+ {"wsrld", 0xeee00040, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsrldg", 0xeee00148, 6, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwcg},
+ {"wstrb", 0xec000000, 5, ARM_CEXT_IWMMXT, do_iwmmxt_byte_addr},
+ {"wstrh", 0xec000100, 5, ARM_CEXT_IWMMXT, do_iwmmxt_byte_addr},
+ {"wstrw", 0xec000200, 5, ARM_CEXT_IWMMXT, do_iwmmxt_word_addr},
+ {"wstrd", 0xec000300, 5, ARM_CEXT_IWMMXT, do_iwmmxt_word_addr},
+ {"wsubbss", 0xee3001a0, 7, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsubb", 0xee0001a0, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsubbus", 0xee1001a0, 7, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsubhss", 0xee7001a0, 7, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsubh", 0xee4001a0, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsubhus", 0xee5001a0, 7, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsubwss", 0xeeb001a0, 7, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsubw", 0xee8001a0, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wsubwus", 0xee9001a0, 7, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wunpckehub", 0xee0000c0, 10, ARM_CEXT_IWMMXT, do_iwmmxt_wrwr},
+ {"wunpckehuh", 0xee4000c0, 10, ARM_CEXT_IWMMXT, do_iwmmxt_wrwr},
+ {"wunpckehuw", 0xee8000c0, 10, ARM_CEXT_IWMMXT, do_iwmmxt_wrwr},
+ {"wunpckehsb", 0xee2000c0, 10, ARM_CEXT_IWMMXT, do_iwmmxt_wrwr},
+ {"wunpckehsh", 0xee6000c0, 10, ARM_CEXT_IWMMXT, do_iwmmxt_wrwr},
+ {"wunpckehsw", 0xeea000c0, 10, ARM_CEXT_IWMMXT, do_iwmmxt_wrwr},
+ {"wunpckihb", 0xee1000c0, 9, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wunpckihh", 0xee5000c0, 9, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wunpckihw", 0xee9000c0, 9, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wunpckelub", 0xee0000e0, 10, ARM_CEXT_IWMMXT, do_iwmmxt_wrwr},
+ {"wunpckeluh", 0xee4000e0, 10, ARM_CEXT_IWMMXT, do_iwmmxt_wrwr},
+ {"wunpckeluw", 0xee8000e0, 10, ARM_CEXT_IWMMXT, do_iwmmxt_wrwr},
+ {"wunpckelsb", 0xee2000e0, 10, ARM_CEXT_IWMMXT, do_iwmmxt_wrwr},
+ {"wunpckelsh", 0xee6000e0, 10, ARM_CEXT_IWMMXT, do_iwmmxt_wrwr},
+ {"wunpckelsw", 0xeea000e0, 10, ARM_CEXT_IWMMXT, do_iwmmxt_wrwr},
+ {"wunpckilb", 0xee1000e0, 9, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wunpckilh", 0xee5000e0, 9, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wunpckilw", 0xee9000e0, 9, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wxor", 0xee100000, 4, ARM_CEXT_IWMMXT, do_iwmmxt_wrwrwr},
+ {"wzero", 0xee300000, 5, ARM_CEXT_IWMMXT, do_iwmmxt_wzero},
+
/* Cirrus Maverick instructions. */
{"cfldrs", 0xec100400, 6, ARM_CEXT_MAVERICK, do_mav_ldst_1},
{"cfldrd", 0xec500400, 6, ARM_CEXT_MAVERICK, do_mav_ldst_2},
@@ -1747,18 +2177,18 @@ static const struct asm_opcode insns[] =
{"cfmvr64l", 0xee100510, 8, ARM_CEXT_MAVERICK, do_mav_binops_1c},
{"cfmv64hr", 0xee000530, 8, ARM_CEXT_MAVERICK, do_mav_binops_2c},
{"cfmvr64h", 0xee100530, 8, ARM_CEXT_MAVERICK, do_mav_binops_1c},
- {"cfmval32", 0xee100610, 8, ARM_CEXT_MAVERICK, do_mav_binops_3a},
- {"cfmv32al", 0xee000610, 8, ARM_CEXT_MAVERICK, do_mav_binops_3b},
- {"cfmvam32", 0xee100630, 8, ARM_CEXT_MAVERICK, do_mav_binops_3a},
- {"cfmv32am", 0xee000630, 8, ARM_CEXT_MAVERICK, do_mav_binops_3b},
- {"cfmvah32", 0xee100650, 8, ARM_CEXT_MAVERICK, do_mav_binops_3a},
- {"cfmv32ah", 0xee000650, 8, ARM_CEXT_MAVERICK, do_mav_binops_3b},
- {"cfmva32", 0xee100670, 7, ARM_CEXT_MAVERICK, do_mav_binops_3a},
- {"cfmv32a", 0xee000670, 7, ARM_CEXT_MAVERICK, do_mav_binops_3b},
- {"cfmva64", 0xee100690, 7, ARM_CEXT_MAVERICK, do_mav_binops_3c},
- {"cfmv64a", 0xee000690, 7, ARM_CEXT_MAVERICK, do_mav_binops_3d},
- {"cfmvsc32", 0xee1006b0, 8, ARM_CEXT_MAVERICK, do_mav_dspsc_1},
- {"cfmv32sc", 0xee0006b0, 8, ARM_CEXT_MAVERICK, do_mav_dspsc_2},
+ {"cfmval32", 0xee200440, 8, ARM_CEXT_MAVERICK, do_mav_binops_3a},
+ {"cfmv32al", 0xee100440, 8, ARM_CEXT_MAVERICK, do_mav_binops_3b},
+ {"cfmvam32", 0xee200460, 8, ARM_CEXT_MAVERICK, do_mav_binops_3a},
+ {"cfmv32am", 0xee100460, 8, ARM_CEXT_MAVERICK, do_mav_binops_3b},
+ {"cfmvah32", 0xee200480, 8, ARM_CEXT_MAVERICK, do_mav_binops_3a},
+ {"cfmv32ah", 0xee100480, 8, ARM_CEXT_MAVERICK, do_mav_binops_3b},
+ {"cfmva32", 0xee2004a0, 7, ARM_CEXT_MAVERICK, do_mav_binops_3a},
+ {"cfmv32a", 0xee1004a0, 7, ARM_CEXT_MAVERICK, do_mav_binops_3b},
+ {"cfmva64", 0xee2004c0, 7, ARM_CEXT_MAVERICK, do_mav_binops_3c},
+ {"cfmv64a", 0xee1004c0, 7, ARM_CEXT_MAVERICK, do_mav_binops_3d},
+ {"cfmvsc32", 0xee2004e0, 8, ARM_CEXT_MAVERICK, do_mav_dspsc_1},
+ {"cfmv32sc", 0xee1004e0, 8, ARM_CEXT_MAVERICK, do_mav_dspsc_2},
{"cfcpys", 0xee000400, 6, ARM_CEXT_MAVERICK, do_mav_binops_1d},
{"cfcpyd", 0xee000420, 6, ARM_CEXT_MAVERICK, do_mav_binops_1e},
{"cfcvtsd", 0xee000460, 7, ARM_CEXT_MAVERICK, do_mav_binops_1f},
@@ -1871,6 +2301,11 @@ static void do_t_adr PARAMS ((char *));
static void do_t_blx PARAMS ((char *));
static void do_t_bkpt PARAMS ((char *));
+/* ARM V6. */
+static void do_t_cps PARAMS ((char *));
+static void do_t_cpy PARAMS ((char *));
+static void do_t_setend PARAMS ((char *));;
+
#define T_OPCODE_MUL 0x4340
#define T_OPCODE_TST 0x4200
#define T_OPCODE_CMN 0x42c0
@@ -1939,6 +2374,7 @@ static int thumb_reg PARAMS ((char ** str, int hi_lo));
#define THUMB_MOVE 0
#define THUMB_COMPARE 1
+#define THUMB_CPY 2
#define THUMB_LOAD 0
#define THUMB_STORE 1
@@ -2031,6 +2467,19 @@ static const struct thumb_opcode tinsns[] =
/* Thumb v2 (ARMv5T). */
{"blx", 0, 0, ARM_EXT_V5T, do_t_blx},
{"bkpt", 0xbe00, 2, ARM_EXT_V5T, do_t_bkpt},
+
+ /* ARM V6. */
+ {"cpsie", 0xb660, 2, ARM_EXT_V6, do_t_cps},
+ {"cpsid", 0xb670, 2, ARM_EXT_V6, do_t_cps},
+ {"cpy", 0x4600, 2, ARM_EXT_V6, do_t_cpy},
+ {"rev", 0xba00, 2, ARM_EXT_V6, do_t_arit},
+ {"rev16", 0xba40, 2, ARM_EXT_V6, do_t_arit},
+ {"revsh", 0xbac0, 2, ARM_EXT_V6, do_t_arit},
+ {"setend", 0xb650, 2, ARM_EXT_V6, do_t_setend},
+ {"sxth", 0xb200, 2, ARM_EXT_V6, do_t_arit},
+ {"sxtb", 0xb240, 2, ARM_EXT_V6, do_t_arit},
+ {"uxth", 0xb280, 2, ARM_EXT_V6, do_t_arit},
+ {"uxtb", 0xb2c0, 2, ARM_EXT_V6, do_t_arit},
};
#define BAD_ARGS _("bad arguments to instruction")
@@ -2051,6 +2500,7 @@ static struct hash_control * arm_psr_hsh = NULL;
Integer arg to pass to the function. */
static void s_req PARAMS ((int));
+static void s_unreq PARAMS ((int));
static void s_align PARAMS ((int));
static void s_bss PARAMS ((int));
static void s_even PARAMS ((int));
@@ -2061,9 +2511,6 @@ static void s_code PARAMS ((int));
static void s_force_thumb PARAMS ((int));
static void s_thumb_func PARAMS ((int));
static void s_thumb_set PARAMS ((int));
-static void arm_s_text PARAMS ((int));
-static void arm_s_data PARAMS ((int));
-static void arm_s_section PARAMS ((int));
#ifdef OBJ_ELF
static void s_arm_elf_cons PARAMS ((int));
#endif
@@ -2072,8 +2519,9 @@ static int my_get_expression PARAMS ((expressionS *, char **));
const pseudo_typeS md_pseudo_table[] =
{
- /* Never called becasue '.req' does not start line. */
+ /* Never called because '.req' does not start a line. */
{ "req", s_req, 0 },
+ { "unreq", s_unreq, 0 },
{ "bss", s_bss, 0 },
{ "align", s_align, 0 },
{ "arm", s_arm, 0 },
@@ -2085,18 +2533,9 @@ const pseudo_typeS md_pseudo_table[] =
{ "even", s_even, 0 },
{ "ltorg", s_ltorg, 0 },
{ "pool", s_ltorg, 0 },
- /* Allow for the effect of section changes. */
- { "text", arm_s_text, 0 },
- { "data", arm_s_data, 0 },
- { "section", arm_s_section, 0 },
- { "section.s", arm_s_section, 0 },
- { "sect", arm_s_section, 0 },
- { "sect.s", arm_s_section, 0 },
#ifdef OBJ_ELF
{ "word", s_arm_elf_cons, 4 },
{ "long", s_arm_elf_cons, 4 },
- { "file", dwarf2_directive_file, 0 },
- { "loc", dwarf2_directive_loc, 0 },
#else
{ "word", cons, 4},
#endif
@@ -2111,6 +2550,12 @@ static int arm_parse_extension PARAMS ((char *, int *));
static int arm_parse_cpu PARAMS ((char *));
static int arm_parse_arch PARAMS ((char *));
static int arm_parse_fpu PARAMS ((char *));
+static int arm_parse_float_abi PARAMS ((char *));
+#if 0 /* Suppressed - for now. */
+#if defined OBJ_COFF || defined OBJ_ELF
+static void arm_add_note PARAMS ((const char *, const char *, unsigned int));
+#endif
+#endif
/* Stuff needed to resolve the label ambiguity
As:
@@ -2123,75 +2568,132 @@ static int arm_parse_fpu PARAMS ((char *));
*/
symbolS * last_label_seen;
-static int label_is_thumb_function_name = false;
+static int label_is_thumb_function_name = FALSE;
-/* Literal stuff. */
+/* Literal Pool stuff. */
#define MAX_LITERAL_POOL_SIZE 1024
-typedef struct literalS
+/* Literal pool structure. Held on a per-section
+ and per-sub-section basis. */
+typedef struct literal_pool
+{
+ expressionS literals [MAX_LITERAL_POOL_SIZE];
+ unsigned int next_free_entry;
+ unsigned int id;
+ symbolS * symbol;
+ segT section;
+ subsegT sub_section;
+ struct literal_pool * next;
+} literal_pool;
+
+/* Pointer to a linked list of literal pools. */
+literal_pool * list_of_pools = NULL;
+
+static literal_pool * find_literal_pool PARAMS ((void));
+static literal_pool * find_or_make_literal_pool PARAMS ((void));
+
+static literal_pool *
+find_literal_pool ()
+{
+ literal_pool * pool;
+
+ for (pool = list_of_pools; pool != NULL; pool = pool->next)
+ {
+ if (pool->section == now_seg
+ && pool->sub_section == now_subseg)
+ break;
+ }
+
+ return pool;
+}
+
+static literal_pool *
+find_or_make_literal_pool ()
{
- struct expressionS exp;
- struct arm_it * inst;
-} literalT;
+ /* Next literal pool ID number. */
+ static unsigned int latest_pool_num = 1;
+ literal_pool * pool;
-literalT literals[MAX_LITERAL_POOL_SIZE];
+ pool = find_literal_pool ();
-/* Next free entry in the pool. */
-int next_literal_pool_place = 0;
+ if (pool == NULL)
+ {
+ /* Create a new pool. */
+ pool = (literal_pool *) xmalloc (sizeof (* pool));
+ if (! pool)
+ return NULL;
-/* Next literal pool number. */
-int lit_pool_num = 1;
+ pool->next_free_entry = 0;
+ pool->section = now_seg;
+ pool->sub_section = now_subseg;
+ pool->next = list_of_pools;
+ pool->symbol = NULL;
-symbolS * current_poolP = NULL;
+ /* Add it to the list. */
+ list_of_pools = pool;
+ }
+ /* New pools, and emptied pools, will have a NULL symbol. */
+ if (pool->symbol == NULL)
+ {
+ pool->symbol = symbol_create (FAKE_LABEL_NAME, undefined_section,
+ (valueT) 0, &zero_address_frag);
+ pool->id = latest_pool_num ++;
+ }
+
+ /* Done. */
+ return pool;
+}
+
+/* Add the literal in the global 'inst'
+ structure to the relevent literal pool. */
static int
add_to_lit_pool ()
{
- int lit_count = 0;
+ literal_pool * pool;
+ unsigned int entry;
- if (current_poolP == NULL)
- current_poolP = symbol_create (FAKE_LABEL_NAME, undefined_section,
- (valueT) 0, &zero_address_frag);
+ pool = find_or_make_literal_pool ();
- /* Check if this literal value is already in the pool: */
- while (lit_count < next_literal_pool_place)
+ /* Check if this literal value is already in the pool. */
+ for (entry = 0; entry < pool->next_free_entry; entry ++)
{
- if (literals[lit_count].exp.X_op == inst.reloc.exp.X_op
- && inst.reloc.exp.X_op == O_constant
- && (literals[lit_count].exp.X_add_number
+ if ((pool->literals[entry].X_op == inst.reloc.exp.X_op)
+ && (inst.reloc.exp.X_op == O_constant)
+ && (pool->literals[entry].X_add_number
== inst.reloc.exp.X_add_number)
- && literals[lit_count].exp.X_unsigned == inst.reloc.exp.X_unsigned)
+ && (pool->literals[entry].X_unsigned
+ == inst.reloc.exp.X_unsigned))
break;
- if (literals[lit_count].exp.X_op == inst.reloc.exp.X_op
- && inst.reloc.exp.X_op == O_symbol
- && (literals[lit_count].exp.X_add_number
+ if ((pool->literals[entry].X_op == inst.reloc.exp.X_op)
+ && (inst.reloc.exp.X_op == O_symbol)
+ && (pool->literals[entry].X_add_number
== inst.reloc.exp.X_add_number)
- && (literals[lit_count].exp.X_add_symbol
+ && (pool->literals[entry].X_add_symbol
== inst.reloc.exp.X_add_symbol)
- && (literals[lit_count].exp.X_op_symbol
+ && (pool->literals[entry].X_op_symbol
== inst.reloc.exp.X_op_symbol))
- break;
-
- lit_count++;
+ break;
}
- if (lit_count == next_literal_pool_place) /* New entry. */
+ /* Do we need to create a new entry? */
+ if (entry == pool->next_free_entry)
{
- if (next_literal_pool_place >= MAX_LITERAL_POOL_SIZE)
+ if (entry >= MAX_LITERAL_POOL_SIZE)
{
inst.error = _("literal pool overflow");
return FAIL;
}
- literals[next_literal_pool_place].exp = inst.reloc.exp;
- lit_count = next_literal_pool_place++;
+ pool->literals[entry] = inst.reloc.exp;
+ pool->next_free_entry += 1;
}
- inst.reloc.exp.X_op = O_symbol;
- inst.reloc.exp.X_add_number = (lit_count) * 4 - 8;
- inst.reloc.exp.X_add_symbol = current_poolP;
+ inst.reloc.exp.X_op = O_symbol;
+ inst.reloc.exp.X_add_number = ((int) entry) * 4 - 8;
+ inst.reloc.exp.X_add_symbol = pool->symbol;
return SUCCESS;
}
@@ -2270,7 +2772,7 @@ validate_immediate (val)
return FAIL;
}
-/* Check to see if an immediate can be computed as two seperate immediate
+/* Check to see if an immediate can be computed as two separate immediate
values, added together. We already know that this value cannot be
computed by just one ARM instruction. */
@@ -2319,6 +2821,167 @@ validate_offset_imm (val, hwse)
return val;
}
+
+#ifdef OBJ_ELF
+/* This code is to handle mapping symbols as defined in the ARM ELF spec.
+ (This text is taken from version B-02 of the spec):
+
+ 4.4.7 Mapping and tagging symbols
+
+ A section of an ARM ELF file can contain a mixture of ARM code,
+ Thumb code, and data. There are inline transitions between code
+ and data at literal pool boundaries. There can also be inline
+ transitions between ARM code and Thumb code, for example in
+ ARM-Thumb inter-working veneers. Linkers, machine-level
+ debuggers, profiling tools, and disassembly tools need to map
+ images accurately. For example, setting an ARM breakpoint on a
+ Thumb location, or in a literal pool, can crash the program
+ being debugged, ruining the debugging session.
+
+ ARM ELF entities are mapped (see section 4.4.7.1 below) and
+ tagged (see section 4.4.7.2 below) using local symbols (with
+ binding STB_LOCAL). To assist consumers, mapping and tagging
+ symbols should be collated first in the symbol table, before
+ other symbols with binding STB_LOCAL.
+
+ To allow properly collated mapping and tagging symbols to be
+ skipped by consumers that have no interest in them, the first
+ such symbol should have the name $m and its st_value field equal
+ to the total number of mapping and tagging symbols (including
+ the $m) in the symbol table.
+
+ 4.4.7.1 Mapping symbols
+
+ $a Labels the first byte of a sequence of ARM instructions.
+ Its type is STT_FUNC.
+
+ $d Labels the first byte of a sequence of data items.
+ Its type is STT_OBJECT.
+
+ $t Labels the first byte of a sequence of Thumb instructions.
+ Its type is STT_FUNC.
+
+ This list of mapping symbols may be extended in the future.
+
+ Section-relative mapping symbols
+
+ Mapping symbols defined in a section define a sequence of
+ half-open address intervals that cover the address range of the
+ section. Each interval starts at the address defined by a
+ mapping symbol, and continues up to, but not including, the
+ address defined by the next (in address order) mapping symbol or
+ the end of the section. A corollary is that there must be a
+ mapping symbol defined at the beginning of each section.
+ Consumers can ignore the size of a section-relative mapping
+ symbol. Producers can set it to 0.
+
+ Absolute mapping symbols
+
+ Because of the need to crystallize a Thumb address with the
+ Thumb-bit set, absolute symbol of type STT_FUNC (symbols of type
+ STT_FUNC defined in section SHN_ABS) need to be mapped with $a
+ or $t.
+
+ The extent of a mapping symbol defined in SHN_ABS is [st_value,
+ st_value + st_size), or [st_value, st_value + 1) if st_size = 0,
+ where [x, y) denotes the half-open address range from x,
+ inclusive, to y, exclusive.
+
+ In the absence of a mapping symbol, a consumer can interpret a
+ function symbol with an odd value as the Thumb code address
+ obtained by clearing the least significant bit of the
+ value. This interpretation is deprecated, and it may not work in
+ the future.
+
+ Note - the Tagging symbols ($b, $f, $p $m) have been dropped from
+ the EABI (which is still under development), so they are not
+ implemented here. */
+
+static enum mstate mapstate = MAP_UNDEFINED;
+
+static void
+mapping_state (enum mstate state)
+{
+ symbolS * symbolP;
+ const char * symname;
+ int type;
+
+ if (mapstate == state)
+ /* The mapping symbol has already been emitted.
+ There is nothing else to do. */
+ return;
+
+ mapstate = state;
+
+ switch (state)
+ {
+ case MAP_DATA:
+ symname = "$d";
+ type = BSF_OBJECT;
+ break;
+ case MAP_ARM:
+ symname = "$a";
+ type = BSF_FUNCTION;
+ break;
+ case MAP_THUMB:
+ symname = "$t";
+ type = BSF_FUNCTION;
+ break;
+ case MAP_UNDEFINED:
+ return;
+ default:
+ abort ();
+ }
+
+ seg_info (now_seg)->tc_segment_info_data = state;
+
+ symbolP = symbol_new (symname, now_seg, (valueT) frag_now_fix (), frag_now);
+ symbol_table_insert (symbolP);
+ symbol_get_bfdsym (symbolP)->flags |= type | BSF_LOCAL;
+
+ switch (state)
+ {
+ case MAP_ARM:
+ THUMB_SET_FUNC (symbolP, 0);
+ ARM_SET_THUMB (symbolP, 0);
+ ARM_SET_INTERWORK (symbolP, support_interwork);
+ break;
+
+ case MAP_THUMB:
+ THUMB_SET_FUNC (symbolP, 1);
+ ARM_SET_THUMB (symbolP, 1);
+ ARM_SET_INTERWORK (symbolP, support_interwork);
+ break;
+
+ case MAP_DATA:
+ default:
+ return;
+ }
+}
+
+/* When we change sections we need to issue a new mapping symbol. */
+
+void
+arm_elf_change_section (void)
+{
+ flagword flags;
+
+ if (!SEG_NORMAL (now_seg))
+ return;
+
+ flags = bfd_get_section_flags (stdoutput, now_seg);
+
+ /* We can ignore sections that only contain debug info. */
+ if ((flags & SEC_ALLOC) == 0)
+ return;
+
+ mapstate = seg_info (now_seg)->tc_segment_info_data;
+}
+#else
+#define mapping_state(a)
+#endif /* OBJ_ELF */
+
+
static void
s_req (a)
int a ATTRIBUTE_UNUSED;
@@ -2326,6 +2989,77 @@ s_req (a)
as_bad (_("invalid syntax for .req directive"));
}
+/* The .unreq directive deletes an alias which was previously defined
+ by .req. For example:
+
+ my_alias .req r11
+ .unreq my_alias */
+
+static void
+s_unreq (int a ATTRIBUTE_UNUSED)
+{
+ char *name;
+ char saved_char;
+
+ skip_whitespace (input_line_pointer);
+ name = input_line_pointer;
+
+ while (*input_line_pointer != 0
+ && *input_line_pointer != ' '
+ && *input_line_pointer != '\n')
+ ++input_line_pointer;
+
+ saved_char = *input_line_pointer;
+ *input_line_pointer = 0;
+
+ if (*name)
+ {
+ enum arm_reg_type req_type = arm_reg_parse_any (name);
+
+ if (req_type != REG_TYPE_MAX)
+ {
+ char *temp_name = name;
+ int req_no = arm_reg_parse (&temp_name, all_reg_maps[req_type].htab);
+
+ if (req_no != FAIL)
+ {
+ struct reg_entry *req_entry;
+
+ /* Check to see if this alias is a builtin one. */
+ req_entry = hash_delete (all_reg_maps[req_type].htab, name);
+
+ if (!req_entry)
+ as_bad (_("unreq: missing hash entry for \"%s\""), name);
+ else if (req_entry->builtin)
+ /* FIXME: We are deleting a built in register alias which
+ points to a const data structure, so we only need to
+ free up the memory used by the key in the hash table.
+ Unfortunately we have not recorded this value, so this
+ is a memory leak. */
+ /* FIXME: Should we issue a warning message ? */
+ ;
+ else
+ {
+ /* Deleting a user defined alias. We need to free the
+ key and the value, but fortunately the key is the same
+ as the value->name field. */
+ free ((char *) req_entry->name);
+ free (req_entry);
+ }
+ }
+ else
+ as_bad (_(".unreq: unrecognized symbol \"%s\""), name);
+ }
+ else
+ as_bad (_(".unreq: unrecognized symbol \"%s\""), name);
+ }
+ else
+ as_bad (_("invalid syntax for .unreq directive"));
+
+ *input_line_pointer = saved_char;
+ demand_empty_rest_of_line ();
+}
+
static void
s_bss (ignore)
int ignore ATTRIBUTE_UNUSED;
@@ -2334,6 +3068,7 @@ s_bss (ignore)
marking in_bss, then looking at s_skip for clues. */
subseg_set (bss_section, 0);
demand_empty_rest_of_line ();
+ mapping_state (MAP_DATA);
}
static void
@@ -2353,12 +3088,18 @@ static void
s_ltorg (ignored)
int ignored ATTRIBUTE_UNUSED;
{
- int lit_count = 0;
+ unsigned int entry;
+ literal_pool * pool;
char sym_name[20];
- if (current_poolP == NULL)
+ pool = find_literal_pool ();
+ if (pool == NULL
+ || pool->symbol == NULL
+ || pool->next_free_entry == 0)
return;
+ mapping_state (MAP_DATA);
+
/* Align pool as you have word accesses.
Only make a frag if we have to. */
if (!need_pass_2)
@@ -2366,24 +3107,25 @@ s_ltorg (ignored)
record_alignment (now_seg, 2);
- sprintf (sym_name, "$$lit_\002%x", lit_pool_num++);
+ sprintf (sym_name, "$$lit_\002%x", pool->id);
- symbol_locate (current_poolP, sym_name, now_seg,
+ symbol_locate (pool->symbol, sym_name, now_seg,
(valueT) frag_now_fix (), frag_now);
- symbol_table_insert (current_poolP);
+ symbol_table_insert (pool->symbol);
- ARM_SET_THUMB (current_poolP, thumb_mode);
+ ARM_SET_THUMB (pool->symbol, thumb_mode);
#if defined OBJ_COFF || defined OBJ_ELF
- ARM_SET_INTERWORK (current_poolP, support_interwork);
+ ARM_SET_INTERWORK (pool->symbol, support_interwork);
#endif
- while (lit_count < next_literal_pool_place)
+ for (entry = 0; entry < pool->next_free_entry; entry ++)
/* First output the expression in the instruction to the pool. */
- emit_expr (&(literals[lit_count++].exp), 4); /* .word */
+ emit_expr (&(pool->literals[entry]), 4); /* .word */
- next_literal_pool_place = 0;
- current_poolP = NULL;
+ /* Mark the pool as empty. */
+ pool->next_free_entry = 0;
+ pool->symbol = NULL;
}
/* Same as s_align_ptwo but align 0 => align 2. */
@@ -2452,7 +3194,7 @@ s_thumb_func (ignore)
/* The following label is the name/address of the start of a Thumb function.
We need to know this for the interworking support. */
- label_is_thumb_function_name = true;
+ label_is_thumb_function_name = TRUE;
demand_empty_rest_of_line ();
}
@@ -2550,55 +3292,6 @@ s_thumb_set (equiv)
#endif
}
-/* If we change section we must dump the literal pool first. */
-
-static void
-arm_s_text (ignore)
- int ignore;
-{
- if (now_seg != text_section)
- s_ltorg (0);
-
-#ifdef OBJ_ELF
- obj_elf_text (ignore);
-#else
- s_text (ignore);
-#endif
-}
-
-static void
-arm_s_data (ignore)
- int ignore;
-{
- if (flag_readonly_data_in_text)
- {
- if (now_seg != text_section)
- s_ltorg (0);
- }
- else if (now_seg != data_section)
- s_ltorg (0);
-
-#ifdef OBJ_ELF
- obj_elf_data (ignore);
-#else
- s_data (ignore);
-#endif
-}
-
-static void
-arm_s_section (ignore)
- int ignore;
-{
- s_ltorg (0);
-
-#ifdef OBJ_ELF
- obj_elf_section (ignore);
-#endif
-#ifdef OBJ_COFF
- obj_coff_section (ignore);
-#endif
-}
-
static void
opcode_select (width)
int width;
@@ -2616,6 +3309,7 @@ opcode_select (width)
coming from ARM mode, which is word-aligned. */
record_alignment (now_seg, 1);
}
+ mapping_state (MAP_THUMB);
break;
case 32:
@@ -2631,6 +3325,7 @@ opcode_select (width)
record_alignment (now_seg, 1);
}
+ mapping_state (MAP_ARM);
break;
default:
@@ -2736,6 +3431,57 @@ reg_required_here (str, shift)
return FAIL;
}
+/* A Intel Wireless MMX technology register
+ must be given at this point.
+ Shift is the place to put it in inst.instruction.
+ Restores input start point on err.
+ Returns the reg#, or FAIL. */
+
+static int
+wreg_required_here (str, shift, reg_type)
+ char ** str;
+ int shift;
+ enum wreg_type reg_type;
+{
+ static char buff [128];
+ int reg;
+ char * start = *str;
+
+ if ((reg = arm_reg_parse (str, all_reg_maps[REG_TYPE_IWMMXT].htab)) != FAIL)
+ {
+ if (wr_register (reg)
+ && (reg_type == IWMMXT_REG_WR || reg_type == IWMMXT_REG_WR_OR_WC))
+ {
+ if (shift >= 0)
+ inst.instruction |= (reg ^ WR_PREFIX) << shift;
+ return reg;
+ }
+ else if (wc_register (reg)
+ && (reg_type == IWMMXT_REG_WC || reg_type == IWMMXT_REG_WR_OR_WC))
+ {
+ if (shift >= 0)
+ inst.instruction |= (reg ^ WC_PREFIX) << shift;
+ return reg;
+ }
+ else if ((wcg_register (reg) && reg_type == IWMMXT_REG_WCG))
+ {
+ if (shift >= 0)
+ inst.instruction |= ((reg ^ WC_PREFIX) - 8) << shift;
+ return reg;
+ }
+ }
+
+ /* Restore the start point, we may have got a reg of the wrong class. */
+ *str = start;
+
+ /* In the few cases where we might be able to accept
+ something else this error can be overridden. */
+ sprintf (buff, _("Intel Wireless MMX technology register expected, not '%.100s'"), start);
+ inst.error = buff;
+
+ return FAIL;
+}
+
static const struct asm_psr *
arm_psr_parse (ccp)
register char ** ccp;
@@ -3001,22 +3747,96 @@ cp_address_required_here (str, wb_ok)
{
p++;
- if (wb_ok && skip_past_comma (& p) == SUCCESS)
+ skip_whitespace (p);
+
+ if (*p == '\0')
{
- /* [Rn], #expr */
- write_back = WRITE_BACK;
+ /* As an extension to the official ARM syntax we allow:
+
+ [Rn]
+
+ as a short hand for:
+
+ [Rn,#0] */
+ inst.instruction |= PRE_INDEX | INDEX_UP;
+ *str = p;
+ return SUCCESS;
+ }
+
+ if (skip_past_comma (& p) == FAIL)
+ {
+ inst.error = _("comma expected after closing square bracket");
+ return FAIL;
+ }
- if (reg == REG_PC)
+ skip_whitespace (p);
+
+ if (*p == '#')
+ {
+ if (wb_ok)
{
- inst.error = _("pc may not be used in post-increment");
- return FAIL;
+ /* [Rn], #expr */
+ write_back = WRITE_BACK;
+
+ if (reg == REG_PC)
+ {
+ inst.error = _("pc may not be used in post-increment");
+ return FAIL;
+ }
+
+ if (cp_address_offset (& p) == FAIL)
+ return FAIL;
}
+ else
+ pre_inc = PRE_INDEX | INDEX_UP;
+ }
+ else if (*p == '{')
+ {
+ int option;
+
+ /* [Rn], {<expr>} */
+ p++;
- if (cp_address_offset (& p) == FAIL)
+ skip_whitespace (p);
+
+ if (my_get_expression (& inst.reloc.exp, & p))
return FAIL;
+
+ if (inst.reloc.exp.X_op == O_constant)
+ {
+ option = inst.reloc.exp.X_add_number;
+
+ if (option > 255 || option < 0)
+ {
+ inst.error = _("'option' field too large");
+ return FAIL;
+ }
+
+ skip_whitespace (p);
+
+ if (*p != '}')
+ {
+ inst.error = _("'}' expected at end of 'option' field");
+ return FAIL;
+ }
+ else
+ {
+ p++;
+ inst.instruction |= option;
+ inst.instruction |= INDEX_UP;
+ }
+ }
+ else
+ {
+ inst.error = _("non-constant expressions for 'option' field not supported");
+ return FAIL;
+ }
}
else
- pre_inc = PRE_INDEX | INDEX_UP;
+ {
+ inst.error = _("# or { expected after comma");
+ return FAIL;
+ }
}
else
{
@@ -3073,13 +3893,150 @@ cp_address_required_here (str, wb_ok)
return SUCCESS;
}
+static int
+cp_byte_address_offset (str)
+ char ** str;
+{
+ int offset;
+
+ skip_whitespace (* str);
+
+ if (! is_immediate_prefix (**str))
+ {
+ inst.error = _("immediate expression expected");
+ return FAIL;
+ }
+
+ (*str)++;
+
+ if (my_get_expression (& inst.reloc.exp, str))
+ return FAIL;
+
+ if (inst.reloc.exp.X_op == O_constant)
+ {
+ offset = inst.reloc.exp.X_add_number;
+
+ if (offset > 255 || offset < -255)
+ {
+ inst.error = _("offset too large");
+ return FAIL;
+ }
+
+ if (offset >= 0)
+ inst.instruction |= INDEX_UP;
+ else
+ offset = -offset;
+
+ inst.instruction |= offset;
+ }
+ else
+ inst.reloc.type = BFD_RELOC_ARM_CP_OFF_IMM_S2;
+
+ return SUCCESS;
+}
+
+static int
+cp_byte_address_required_here (str)
+ char ** str;
+{
+ char * p = * str;
+ int pre_inc = 0;
+ int write_back = 0;
+
+ if (*p == '[')
+ {
+ int reg;
+
+ p++;
+ skip_whitespace (p);
+
+ if ((reg = reg_required_here (& p, 16)) == FAIL)
+ return FAIL;
+
+ skip_whitespace (p);
+
+ if (*p == ']')
+ {
+ p++;
+
+ if (skip_past_comma (& p) == SUCCESS)
+ {
+ /* [Rn], #expr */
+ write_back = WRITE_BACK;
+
+ if (reg == REG_PC)
+ {
+ inst.error = _("pc may not be used in post-increment");
+ return FAIL;
+ }
+
+ if (cp_byte_address_offset (& p) == FAIL)
+ return FAIL;
+ }
+ else
+ pre_inc = PRE_INDEX | INDEX_UP;
+ }
+ else
+ {
+ /* '['Rn, #expr']'[!] */
+
+ if (skip_past_comma (& p) == FAIL)
+ {
+ inst.error = _("pre-indexed expression expected");
+ return FAIL;
+ }
+
+ pre_inc = PRE_INDEX;
+
+ if (cp_byte_address_offset (& p) == FAIL)
+ return FAIL;
+
+ skip_whitespace (p);
+
+ if (*p++ != ']')
+ {
+ inst.error = _("missing ]");
+ return FAIL;
+ }
+
+ skip_whitespace (p);
+
+ if (*p == '!')
+ {
+ if (reg == REG_PC)
+ {
+ inst.error = _("pc may not be used with write-back");
+ return FAIL;
+ }
+
+ p++;
+ write_back = WRITE_BACK;
+ }
+ }
+ }
+ else
+ {
+ if (my_get_expression (&inst.reloc.exp, &p))
+ return FAIL;
+
+ inst.reloc.type = BFD_RELOC_ARM_CP_OFF_IMM_S2;
+ inst.reloc.exp.X_add_number -= 8; /* PC rel adjust. */
+ inst.reloc.pc_rel = 1;
+ inst.instruction |= (REG_PC << 16);
+ pre_inc = PRE_INDEX;
+ }
+
+ inst.instruction |= write_back | pre_inc;
+ *str = p;
+ return SUCCESS;
+}
+
static void
do_empty (str)
char * str;
{
/* Do nothing really. */
end_of_line (str);
- return;
}
static void
@@ -3107,12 +4064,12 @@ do_mrs (str)
if ( strcmp (str, "CPSR") == 0
|| strcmp (str, "SPSR") == 0
- /* Lower case versions for backwards compatability. */
+ /* Lower case versions for backwards compatibility. */
|| strcmp (str, "cpsr") == 0
|| strcmp (str, "spsr") == 0)
skip = 4;
- /* This is for backwards compatability with older toolchains. */
+ /* This is for backwards compatibility with older toolchains. */
else if ( strcmp (str, "cpsr_all") == 0
|| strcmp (str, "spsr_all") == 0)
skip = 8;
@@ -3263,7 +4220,6 @@ do_mull (str)
}
end_of_line (str);
- return;
}
static void
@@ -3317,7 +4273,6 @@ do_mul (str)
}
end_of_line (str);
- return;
}
static void
@@ -3373,7 +4328,6 @@ do_mla (str)
}
end_of_line (str);
- return;
}
/* Expects *str -> the characters "acc0", possibly with leading blanks.
@@ -3730,7 +4684,7 @@ do_clz (str)
/* ARM V5 (argument parse)
LDC2{L} <coproc>, <CRd>, <addressing mode>
STC2{L} <coproc>, <CRd>, <addressing mode>
- Instruction is not conditional, and has 0xf in the codition field.
+ Instruction is not conditional, and has 0xf in the condition field.
Otherwise, it's the same as LDC/STC. */
static void
@@ -3909,6 +4863,950 @@ do_bxj (str)
end_of_line (str);
}
+/* ARM V6 umaal (argument parse). */
+
+static void
+do_umaal (str)
+ char *str;
+{
+
+ int rdlo, rdhi, rm, rs;
+
+ skip_whitespace (str);
+ if ((rdlo = reg_required_here (& str, 12)) == FAIL
+ || skip_past_comma (& str) == FAIL
+ || (rdhi = reg_required_here (& str, 16)) == FAIL
+ || skip_past_comma (& str) == FAIL
+ || (rm = reg_required_here (& str, 0)) == FAIL
+ || skip_past_comma (& str) == FAIL
+ || (rs = reg_required_here (& str, 8)) == FAIL)
+ {
+ inst.error = BAD_ARGS;
+ return;
+ }
+
+ if (rdlo == REG_PC || rdhi == REG_PC || rm == REG_PC || rs == REG_PC)
+ {
+ inst.error = BAD_PC;
+ return;
+ }
+
+ end_of_line (str);
+}
+
+/* ARM V6 strex (argument parse). */
+
+static void
+do_strex (str)
+ char *str;
+{
+ int rd, rm, rn;
+
+ /* Parse Rd, Rm,. */
+ skip_whitespace (str);
+ if ((rd = reg_required_here (& str, 12)) == FAIL
+ || skip_past_comma (& str) == FAIL
+ || (rm = reg_required_here (& str, 0)) == FAIL
+ || skip_past_comma (& str) == FAIL)
+ {
+ inst.error = BAD_ARGS;
+ return;
+ }
+ if (rd == REG_PC || rm == REG_PC)
+ {
+ inst.error = BAD_PC;
+ return;
+ }
+ if (rd == rm)
+ {
+ inst.error = _("Rd equal to Rm or Rn yields unpredictable results");
+ return;
+ }
+
+ /* Skip past '['. */
+ if ((strlen (str) >= 1)
+ && strncmp (str, "[", 1) == 0)
+ str+=1;
+ skip_whitespace (str);
+
+ /* Parse Rn. */
+ if ((rn = reg_required_here (& str, 16)) == FAIL)
+ {
+ inst.error = BAD_ARGS;
+ return;
+ }
+ else if (rn == REG_PC)
+ {
+ inst.error = BAD_PC;
+ return;
+ }
+ if (rd == rn)
+ {
+ inst.error = _("Rd equal to Rm or Rn yields unpredictable results");
+ return;
+ }
+ skip_whitespace (str);
+
+ /* Skip past ']'. */
+ if ((strlen (str) >= 1)
+ && strncmp (str, "]", 1) == 0)
+ str+=1;
+
+ end_of_line (str);
+}
+
+/* ARM V6 ssat (argument parse). */
+
+static void
+do_ssat (str)
+ char* str;
+{
+ do_sat (&str, /*bias=*/-1);
+ end_of_line (str);
+}
+
+/* ARM V6 usat (argument parse). */
+
+static void
+do_usat (str)
+ char* str;
+{
+ do_sat (&str, /*bias=*/0);
+ end_of_line (str);
+}
+
+static void
+do_sat (str, bias)
+ char **str;
+ int bias;
+{
+ int rd, rm;
+ expressionS expr;
+
+ skip_whitespace (*str);
+
+ /* Parse <Rd>, field. */
+ if ((rd = reg_required_here (str, 12)) == FAIL
+ || skip_past_comma (str) == FAIL)
+ {
+ inst.error = BAD_ARGS;
+ return;
+ }
+ if (rd == REG_PC)
+ {
+ inst.error = BAD_PC;
+ return;
+ }
+
+ /* Parse #<immed>, field. */
+ if (is_immediate_prefix (**str))
+ (*str)++;
+ else
+ {
+ inst.error = _("immediate expression expected");
+ return;
+ }
+ if (my_get_expression (&expr, str))
+ {
+ inst.error = _("bad expression");
+ return;
+ }
+ if (expr.X_op != O_constant)
+ {
+ inst.error = _("constant expression expected");
+ return;
+ }
+ if (expr.X_add_number + bias < 0
+ || expr.X_add_number + bias > 31)
+ {
+ inst.error = _("immediate value out of range");
+ return;
+ }
+ inst.instruction |= (expr.X_add_number + bias) << 16;
+ if (skip_past_comma (str) == FAIL)
+ {
+ inst.error = BAD_ARGS;
+ return;
+ }
+
+ /* Parse <Rm> field. */
+ if ((rm = reg_required_here (str, 0)) == FAIL)
+ {
+ inst.error = BAD_ARGS;
+ return;
+ }
+ if (rm == REG_PC)
+ {
+ inst.error = BAD_PC;
+ return;
+ }
+
+ if (skip_past_comma (str) == SUCCESS)
+ decode_shift (str, SHIFT_LSL_OR_ASR_IMMEDIATE);
+}
+
+/* ARM V6 ssat16 (argument parse). */
+
+static void
+do_ssat16 (str)
+ char *str;
+{
+ do_sat16 (&str, /*bias=*/-1);
+ end_of_line (str);
+}
+
+static void
+do_usat16 (str)
+ char *str;
+{
+ do_sat16 (&str, /*bias=*/0);
+ end_of_line (str);
+}
+
+static void
+do_sat16 (str, bias)
+ char **str;
+ int bias;
+{
+ int rd, rm;
+ expressionS expr;
+
+ skip_whitespace (*str);
+
+ /* Parse the <Rd> field. */
+ if ((rd = reg_required_here (str, 12)) == FAIL
+ || skip_past_comma (str) == FAIL)
+ {
+ inst.error = BAD_ARGS;
+ return;
+ }
+ if (rd == REG_PC)
+ {
+ inst.error = BAD_PC;
+ return;
+ }
+
+ /* Parse #<immed>, field. */
+ if (is_immediate_prefix (**str))
+ (*str)++;
+ else
+ {
+ inst.error = _("immediate expression expected");
+ return;
+ }
+ if (my_get_expression (&expr, str))
+ {
+ inst.error = _("bad expression");
+ return;
+ }
+ if (expr.X_op != O_constant)
+ {
+ inst.error = _("constant expression expected");
+ return;
+ }
+ if (expr.X_add_number + bias < 0
+ || expr.X_add_number + bias > 15)
+ {
+ inst.error = _("immediate value out of range");
+ return;
+ }
+ inst.instruction |= (expr.X_add_number + bias) << 16;
+ if (skip_past_comma (str) == FAIL)
+ {
+ inst.error = BAD_ARGS;
+ return;
+ }
+
+ /* Parse <Rm> field. */
+ if ((rm = reg_required_here (str, 0)) == FAIL)
+ {
+ inst.error = BAD_ARGS;
+ return;
+ }
+ if (rm == REG_PC)
+ {
+ inst.error = BAD_PC;
+ return;
+ }
+}
+
+/* ARM V6 srs (argument parse). */
+
+static void
+do_srs (str)
+ char* str;
+{
+ char *exclam;
+ skip_whitespace (str);
+ exclam = strchr (str, '!');
+ if (exclam)
+ *exclam = '\0';
+ do_cps_mode (&str);
+ if (exclam)
+ *exclam = '!';
+ if (*str == '!')
+ {
+ inst.instruction |= WRITE_BACK;
+ str++;
+ }
+ end_of_line (str);
+}
+
+/* ARM V6 SMMUL (argument parse). */
+
+static void
+do_smmul (str)
+ char* str;
+{
+ int rd, rm, rs;
+
+ skip_whitespace (str);
+ if ((rd = reg_required_here (&str, 16)) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || (rm = reg_required_here (&str, 0)) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || (rs = reg_required_here (&str, 8)) == FAIL)
+ {
+ inst.error = BAD_ARGS;
+ return;
+ }
+
+ if (rd == REG_PC
+ || rm == REG_PC
+ || rs == REG_PC)
+ {
+ inst.error = BAD_PC;
+ return;
+ }
+
+ end_of_line (str);
+
+}
+
+/* ARM V6 SMLALD (argument parse). */
+
+static void
+do_smlald (str)
+ char* str;
+{
+ int rdlo, rdhi, rm, rs;
+ skip_whitespace (str);
+ if ((rdlo = reg_required_here (&str, 12)) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || (rdhi = reg_required_here (&str, 16)) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || (rm = reg_required_here (&str, 0)) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || (rs = reg_required_here (&str, 8)) == FAIL)
+ {
+ inst.error = BAD_ARGS;
+ return;
+ }
+
+ if (rdlo == REG_PC
+ || rdhi == REG_PC
+ || rm == REG_PC
+ || rs == REG_PC)
+ {
+ inst.error = BAD_PC;
+ return;
+ }
+
+ end_of_line (str);
+}
+
+/* ARM V6 SMLAD (argument parse). Signed multiply accumulate dual.
+ smlad{x}{<cond>} Rd, Rm, Rs, Rn */
+
+static void
+do_smlad (str)
+ char *str;
+{
+ int rd, rm, rs, rn;
+
+ skip_whitespace (str);
+ if ((rd = reg_required_here (&str, 16)) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || (rm = reg_required_here (&str, 0)) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || (rs = reg_required_here (&str, 8)) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || (rn = reg_required_here (&str, 12)) == FAIL)
+ {
+ inst.error = BAD_ARGS;
+ return;
+ }
+
+ if (rd == REG_PC
+ || rn == REG_PC
+ || rs == REG_PC
+ || rm == REG_PC)
+ {
+ inst.error = BAD_PC;
+ return;
+ }
+
+ end_of_line (str);
+}
+
+/* ARM V6 SETEND (argument parse). Sets the E bit in the CPSR while
+ preserving the other bits.
+
+ setend <endian_specifier>, where <endian_specifier> is either
+ BE or LE. */
+
+static void
+do_setend (str)
+ char *str;
+{
+ if (do_endian_specifier (str))
+ inst.instruction |= 0x200;
+}
+
+/* Returns true if the endian-specifier indicates big-endianness. */
+
+static int
+do_endian_specifier (str)
+ char *str;
+{
+ int big_endian = 0;
+
+ skip_whitespace (str);
+ if (strlen (str) < 2)
+ inst.error = _("missing endian specifier");
+ else if (strncasecmp (str, "BE", 2) == 0)
+ {
+ str += 2;
+ big_endian = 1;
+ }
+ else if (strncasecmp (str, "LE", 2) == 0)
+ str += 2;
+ else
+ inst.error = _("valid endian specifiers are be or le");
+
+ end_of_line (str);
+
+ return big_endian;
+}
+
+/* ARM V6 SXTH.
+
+ SXTH {<cond>} <Rd>, <Rm>{, <rotation>}
+ Condition defaults to COND_ALWAYS.
+ Error if any register uses R15. */
+
+static void
+do_sxth (str)
+ char *str;
+{
+ int rd, rm;
+ expressionS expr;
+ int rotation_clear_mask = 0xfffff3ff;
+ int rotation_eight_mask = 0x00000400;
+ int rotation_sixteen_mask = 0x00000800;
+ int rotation_twenty_four_mask = 0x00000c00;
+
+ skip_whitespace (str);
+ if ((rd = reg_required_here (&str, 12)) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || (rm = reg_required_here (&str, 0)) == FAIL)
+ {
+ inst.error = BAD_ARGS;
+ return;
+ }
+
+ else if (rd == REG_PC || rm == REG_PC)
+ {
+ inst.error = BAD_PC;
+ return;
+ }
+
+ /* Zero out the rotation field. */
+ inst.instruction &= rotation_clear_mask;
+
+ /* Check for lack of optional rotation field. */
+ if (skip_past_comma (&str) == FAIL)
+ {
+ end_of_line (str);
+ return;
+ }
+
+ /* Move past 'ROR'. */
+ skip_whitespace (str);
+ if (strncasecmp (str, "ROR", 3) == 0)
+ str+=3;
+ else
+ {
+ inst.error = _("missing rotation field after comma");
+ return;
+ }
+
+ /* Get the immediate constant. */
+ skip_whitespace (str);
+ if (is_immediate_prefix (* str))
+ str++;
+ else
+ {
+ inst.error = _("immediate expression expected");
+ return;
+ }
+
+ if (my_get_expression (&expr, &str))
+ {
+ inst.error = _("bad expression");
+ return;
+ }
+
+ if (expr.X_op != O_constant)
+ {
+ inst.error = _("constant expression expected");
+ return;
+ }
+
+ switch (expr.X_add_number)
+ {
+ case 0:
+ /* Rotation field has already been zeroed. */
+ break;
+ case 8:
+ inst.instruction |= rotation_eight_mask;
+ break;
+
+ case 16:
+ inst.instruction |= rotation_sixteen_mask;
+ break;
+
+ case 24:
+ inst.instruction |= rotation_twenty_four_mask;
+ break;
+
+ default:
+ inst.error = _("rotation can be 8, 16, 24 or 0 when field is ommited");
+ break;
+ }
+
+ end_of_line (str);
+
+}
+
+/* ARM V6 SXTAH extracts a 16-bit value from a register, sign
+ extends it to 32-bits, and adds the result to a value in another
+ register. You can specify a rotation by 0, 8, 16, or 24 bits
+ before extracting the 16-bit value.
+ SXTAH{<cond>} <Rd>, <Rn>, <Rm>{, <rotation>}
+ Condition defaults to COND_ALWAYS.
+ Error if any register uses R15. */
+
+static void
+do_sxtah (str)
+ char *str;
+{
+ int rd, rn, rm;
+ expressionS expr;
+ int rotation_clear_mask = 0xfffff3ff;
+ int rotation_eight_mask = 0x00000400;
+ int rotation_sixteen_mask = 0x00000800;
+ int rotation_twenty_four_mask = 0x00000c00;
+
+ skip_whitespace (str);
+ if ((rd = reg_required_here (&str, 12)) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || (rn = reg_required_here (&str, 16)) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || (rm = reg_required_here (&str, 0)) == FAIL)
+ {
+ inst.error = BAD_ARGS;
+ return;
+ }
+
+ else if (rd == REG_PC || rn == REG_PC || rm == REG_PC)
+ {
+ inst.error = BAD_PC;
+ return;
+ }
+
+ /* Zero out the rotation field. */
+ inst.instruction &= rotation_clear_mask;
+
+ /* Check for lack of optional rotation field. */
+ if (skip_past_comma (&str) == FAIL)
+ {
+ end_of_line (str);
+ return;
+ }
+
+ /* Move past 'ROR'. */
+ skip_whitespace (str);
+ if (strncasecmp (str, "ROR", 3) == 0)
+ str+=3;
+ else
+ {
+ inst.error = _("missing rotation field after comma");
+ return;
+ }
+
+ /* Get the immediate constant. */
+ skip_whitespace (str);
+ if (is_immediate_prefix (* str))
+ str++;
+ else
+ {
+ inst.error = _("immediate expression expected");
+ return;
+ }
+
+ if (my_get_expression (&expr, &str))
+ {
+ inst.error = _("bad expression");
+ return;
+ }
+
+ if (expr.X_op != O_constant)
+ {
+ inst.error = _("constant expression expected");
+ return;
+ }
+
+ switch (expr.X_add_number)
+ {
+ case 0:
+ /* Rotation field has already been zeroed. */
+ break;
+
+ case 8:
+ inst.instruction |= rotation_eight_mask;
+ break;
+
+ case 16:
+ inst.instruction |= rotation_sixteen_mask;
+ break;
+
+ case 24:
+ inst.instruction |= rotation_twenty_four_mask;
+ break;
+
+ default:
+ inst.error = _("rotation can be 8, 16, 24 or 0 when field is ommited");
+ break;
+ }
+
+ end_of_line (str);
+
+}
+
+
+/* ARM V6 RFE (Return from Exception) loads the PC and CPSR from the
+ word at the specified address and the following word
+ respectively.
+ Unconditionally executed.
+ Error if Rn is R15.
+*/
+
+static void
+do_rfe (str)
+ char *str;
+{
+ int rn;
+
+ skip_whitespace (str);
+
+ if ((rn = reg_required_here (&str, 16)) == FAIL)
+ return;
+
+ if (rn == REG_PC)
+ {
+ inst.error = BAD_PC;
+ return;
+ }
+
+ skip_whitespace (str);
+
+ if (*str == '!')
+ {
+ inst.instruction |= WRITE_BACK;
+ str++;
+ }
+ end_of_line (str);
+}
+
+/* ARM V6 REV (Byte Reverse Word) reverses the byte order in a 32-bit
+ register (argument parse).
+ REV{<cond>} Rd, Rm.
+ Condition defaults to COND_ALWAYS.
+ Error if Rd or Rm are R15. */
+
+static void
+do_rev (str)
+ char* str;
+{
+ int rd, rm;
+
+ skip_whitespace (str);
+
+ if ((rd = reg_required_here (&str, 12)) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || (rm = reg_required_here (&str, 0)) == FAIL)
+ inst.error = BAD_ARGS;
+
+ else if (rd == REG_PC || rm == REG_PC)
+ inst.error = BAD_PC;
+
+ else
+ end_of_line (str);
+}
+
+/* ARM V6 Perform Two Sixteen Bit Integer Additions. (argument parse).
+ QADD16{<cond>} <Rd>, <Rn>, <Rm>
+ Condition defaults to COND_ALWAYS.
+ Error if Rd, Rn or Rm are R15. */
+
+static void
+do_qadd16 (str)
+ char* str;
+{
+ int rd, rm, rn;
+
+ skip_whitespace (str);
+
+ if ((rd = reg_required_here (&str, 12)) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || (rn = reg_required_here (&str, 16)) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || (rm = reg_required_here (&str, 0)) == FAIL)
+ inst.error = BAD_ARGS;
+
+ else if (rd == REG_PC || rm == REG_PC || rn == REG_PC)
+ inst.error = BAD_PC;
+
+ else
+ end_of_line (str);
+}
+
+/* ARM V6 Pack Halfword Bottom Top instruction (argument parse).
+ PKHBT {<cond>} <Rd>, <Rn>, <Rm> {, LSL #<shift_imm>}
+ Condition defaults to COND_ALWAYS.
+ Error if Rd, Rn or Rm are R15. */
+
+static void
+do_pkhbt (str)
+ char* str;
+{
+ do_pkh_core (str, SHIFT_LSL_IMMEDIATE);
+}
+
+/* ARM V6 PKHTB (Argument Parse). */
+
+static void
+do_pkhtb (str)
+ char* str;
+{
+ do_pkh_core (str, SHIFT_ASR_IMMEDIATE);
+}
+
+static void
+do_pkh_core (str, shift)
+ char* str;
+ int shift;
+{
+ int rd, rn, rm;
+
+ skip_whitespace (str);
+ if (((rd = reg_required_here (&str, 12)) == FAIL)
+ || (skip_past_comma (&str) == FAIL)
+ || ((rn = reg_required_here (&str, 16)) == FAIL)
+ || (skip_past_comma (&str) == FAIL)
+ || ((rm = reg_required_here (&str, 0)) == FAIL))
+ {
+ inst.error = BAD_ARGS;
+ return;
+ }
+
+ else if (rd == REG_PC || rn == REG_PC || rm == REG_PC)
+ {
+ inst.error = BAD_PC;
+ return;
+ }
+
+ /* Check for optional shift immediate constant. */
+ if (skip_past_comma (&str) == FAIL)
+ {
+ if (shift == SHIFT_ASR_IMMEDIATE)
+ {
+ /* If the shift specifier is ommited, turn the instruction
+ into pkhbt rd, rm, rn. First, switch the instruction
+ code, and clear the rn and rm fields. */
+ inst.instruction &= 0xfff0f010;
+ /* Now, re-encode the registers. */
+ inst.instruction |= (rm << 16) | rn;
+ }
+ return;
+ }
+
+ decode_shift (&str, shift);
+}
+
+/* ARM V6 Load Register Exclusive instruction (argument parse).
+ LDREX{<cond>} <Rd, [<Rn>]
+ Condition defaults to COND_ALWAYS.
+ Error if Rd or Rn are R15.
+ See ARMARMv6 A4.1.27: LDREX. */
+
+
+static void
+do_ldrex (str)
+ char * str;
+{
+ int rd, rn;
+
+ skip_whitespace (str);
+
+ /* Parse Rd. */
+ if (((rd = reg_required_here (&str, 12)) == FAIL)
+ || (skip_past_comma (&str) == FAIL))
+ {
+ inst.error = BAD_ARGS;
+ return;
+ }
+ else if (rd == REG_PC)
+ {
+ inst.error = BAD_PC;
+ return;
+ }
+ skip_whitespace (str);
+
+ /* Skip past '['. */
+ if ((strlen (str) >= 1)
+ &&strncmp (str, "[", 1) == 0)
+ str+=1;
+ skip_whitespace (str);
+
+ /* Parse Rn. */
+ if ((rn = reg_required_here (&str, 16)) == FAIL)
+ {
+ inst.error = BAD_ARGS;
+ return;
+ }
+ else if (rn == REG_PC)
+ {
+ inst.error = BAD_PC;
+ return;
+ }
+ skip_whitespace (str);
+
+ /* Skip past ']'. */
+ if ((strlen (str) >= 1)
+ && strncmp (str, "]", 1) == 0)
+ str+=1;
+
+ end_of_line (str);
+}
+
+/* ARM V6 change processor state instruction (argument parse)
+ CPS, CPSIE, CSPID . */
+
+static void
+do_cps (str)
+ char * str;
+{
+ do_cps_mode (&str);
+ end_of_line (str);
+}
+
+static void
+do_cpsi (str)
+ char * str;
+{
+ do_cps_flags (&str, /*thumb_p=*/0);
+
+ if (skip_past_comma (&str) == SUCCESS)
+ {
+ skip_whitespace (str);
+ do_cps_mode (&str);
+ }
+ end_of_line (str);
+}
+
+static void
+do_cps_mode (str)
+ char **str;
+{
+ expressionS expr;
+
+ skip_whitespace (*str);
+
+ if (! is_immediate_prefix (**str))
+ {
+ inst.error = _("immediate expression expected");
+ return;
+ }
+
+ (*str)++; /* Strip off the immediate signifier. */
+ if (my_get_expression (&expr, str))
+ {
+ inst.error = _("bad expression");
+ return;
+ }
+
+ if (expr.X_op != O_constant)
+ {
+ inst.error = _("constant expression expected");
+ return;
+ }
+
+ /* The mode is a 5 bit field. Valid values are 0-31. */
+ if (((unsigned) expr.X_add_number) > 31
+ || (inst.reloc.exp.X_add_number) < 0)
+ {
+ inst.error = _("invalid constant");
+ return;
+ }
+
+ inst.instruction |= expr.X_add_number;
+}
+
+static void
+do_cps_flags (str, thumb_p)
+ char **str;
+ int thumb_p;
+{
+ struct cps_flag {
+ char character;
+ unsigned long arm_value;
+ unsigned long thumb_value;
+ };
+ static struct cps_flag flag_table[] = {
+ {'a', 0x100, 0x4 },
+ {'i', 0x080, 0x2 },
+ {'f', 0x040, 0x1 }
+ };
+
+ int saw_a_flag = 0;
+
+ skip_whitespace (*str);
+
+ /* Get the a, f and i flags. */
+ while (**str && **str != ',')
+ {
+ struct cps_flag *p;
+ struct cps_flag *q = flag_table + sizeof (flag_table)/sizeof (*p);
+ for (p = flag_table; p < q; ++p)
+ if (strncasecmp (*str, &p->character, 1) == 0)
+ {
+ inst.instruction |= (thumb_p ? p->thumb_value : p->arm_value);
+ saw_a_flag = 1;
+ break;
+ }
+ if (p == q)
+ {
+ inst.error = _("unrecognized flag");
+ return;
+ }
+ (*str)++;
+ }
+ if (!saw_a_flag)
+ inst.error = _("no 'a', 'i', or 'f' flags for 'cps'");
+}
+
/* THUMB V5 breakpoint instruction (argument parse)
BKPT <immed_8>. */
@@ -3926,9 +5824,12 @@ do_t_bkpt (str)
str ++;
memset (& expr, '\0', sizeof (expr));
- if (my_get_expression (& expr, & str) || (expr.X_op != O_constant))
+ if (my_get_expression (& expr, & str)
+ || (expr.X_op != O_constant
+ /* As a convenience we allow 'bkpt' without an operand. */
+ && expr.X_op != O_absent))
{
- inst.error = _("bad or missing expression");
+ inst.error = _("bad expression");
return;
}
@@ -4108,9 +6009,12 @@ do_bkpt (str)
memset (& expr, '\0', sizeof (expr));
- if (my_get_expression (& expr, & str) || (expr.X_op != O_constant))
+ if (my_get_expression (& expr, & str)
+ || (expr.X_op != O_constant
+ /* As a convenience we allow 'bkpt' without an operand. */
+ && expr.X_op != O_absent))
{
- inst.error = _("bad or missing expression");
+ inst.error = _("bad expression");
return;
}
@@ -4132,6 +6036,455 @@ do_bkpt (str)
end_of_line (str);
}
+/* THUMB CPS instruction (argument parse). */
+
+static void
+do_t_cps (str)
+ char *str;
+{
+ do_cps_flags (&str, /*thumb_p=*/1);
+ end_of_line (str);
+}
+
+/* THUMB CPY instruction (argument parse). */
+
+static void
+do_t_cpy (str)
+ char *str;
+{
+ thumb_mov_compare (str, THUMB_CPY);
+}
+
+/* THUMB SETEND instruction (argument parse). */
+
+static void
+do_t_setend (str)
+ char *str;
+{
+ if (do_endian_specifier (str))
+ inst.instruction |= 0x8;
+}
+
+static unsigned long check_iwmmxt_insn PARAMS ((char *, enum iwmmxt_insn_type, int));
+
+/* Parse INSN_TYPE insn STR having a possible IMMEDIATE_SIZE immediate. */
+
+static unsigned long
+check_iwmmxt_insn (str, insn_type, immediate_size)
+ char * str;
+ enum iwmmxt_insn_type insn_type;
+ int immediate_size;
+{
+ int reg = 0;
+ const char * inst_error;
+ expressionS expr;
+ unsigned long number;
+
+ inst_error = inst.error;
+ if (!inst.error)
+ inst.error = BAD_ARGS;
+ skip_whitespace (str);
+
+ switch (insn_type)
+ {
+ case check_rd:
+ if ((reg = reg_required_here (&str, 12)) == FAIL)
+ return FAIL;
+ break;
+
+ case check_wr:
+ if ((wreg_required_here (&str, 0, IWMMXT_REG_WR)) == FAIL)
+ return FAIL;
+ break;
+
+ case check_wrwr:
+ if ((wreg_required_here (&str, 12, IWMMXT_REG_WR) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || wreg_required_here (&str, 16, IWMMXT_REG_WR) == FAIL))
+ return FAIL;
+ break;
+
+ case check_wrwrwr:
+ if ((wreg_required_here (&str, 12, IWMMXT_REG_WR) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || wreg_required_here (&str, 16, IWMMXT_REG_WR) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || wreg_required_here (&str, 0, IWMMXT_REG_WR) == FAIL))
+ return FAIL;
+ break;
+
+ case check_wrwrwcg:
+ if ((wreg_required_here (&str, 12, IWMMXT_REG_WR) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || wreg_required_here (&str, 16, IWMMXT_REG_WR) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || wreg_required_here (&str, 0, IWMMXT_REG_WCG) == FAIL))
+ return FAIL;
+ break;
+
+ case check_tbcst:
+ if ((wreg_required_here (&str, 16, IWMMXT_REG_WR) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || reg_required_here (&str, 12) == FAIL))
+ return FAIL;
+ break;
+
+ case check_tmovmsk:
+ if ((reg_required_here (&str, 12) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || wreg_required_here (&str, 16, IWMMXT_REG_WR) == FAIL))
+ return FAIL;
+ break;
+
+ case check_tmia:
+ if ((wreg_required_here (&str, 5, IWMMXT_REG_WR) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || reg_required_here (&str, 0) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || reg_required_here (&str, 12) == FAIL))
+ return FAIL;
+ break;
+
+ case check_tmcrr:
+ if ((wreg_required_here (&str, 0, IWMMXT_REG_WR) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || reg_required_here (&str, 12) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || reg_required_here (&str, 16) == FAIL))
+ return FAIL;
+ break;
+
+ case check_tmrrc:
+ if ((reg_required_here (&str, 12) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || reg_required_here (&str, 16) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || wreg_required_here (&str, 0, IWMMXT_REG_WR) == FAIL))
+ return FAIL;
+ break;
+
+ case check_tmcr:
+ if ((wreg_required_here (&str, 16, IWMMXT_REG_WC) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || reg_required_here (&str, 12) == FAIL))
+ return FAIL;
+ break;
+
+ case check_tmrc:
+ if ((reg_required_here (&str, 12) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || wreg_required_here (&str, 16, IWMMXT_REG_WC) == FAIL))
+ return FAIL;
+ break;
+
+ case check_tinsr:
+ if ((wreg_required_here (&str, 16, IWMMXT_REG_WR) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || reg_required_here (&str, 12) == FAIL
+ || skip_past_comma (&str) == FAIL))
+ return FAIL;
+ break;
+
+ case check_textrc:
+ if ((reg_required_here (&str, 12) == FAIL
+ || skip_past_comma (&str) == FAIL))
+ return FAIL;
+ break;
+
+ case check_waligni:
+ if ((wreg_required_here (&str, 12, IWMMXT_REG_WR) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || wreg_required_here (&str, 16, IWMMXT_REG_WR) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || wreg_required_here (&str, 0, IWMMXT_REG_WR) == FAIL
+ || skip_past_comma (&str) == FAIL))
+ return FAIL;
+ break;
+
+ case check_textrm:
+ if ((reg_required_here (&str, 12) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || wreg_required_here (&str, 16, IWMMXT_REG_WR) == FAIL
+ || skip_past_comma (&str) == FAIL))
+ return FAIL;
+ break;
+
+ case check_wshufh:
+ if ((wreg_required_here (&str, 12, IWMMXT_REG_WR) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || wreg_required_here (&str, 16, IWMMXT_REG_WR) == FAIL
+ || skip_past_comma (&str) == FAIL))
+ return FAIL;
+ break;
+ }
+
+ if (immediate_size == 0)
+ {
+ end_of_line (str);
+ inst.error = inst_error;
+ return reg;
+ }
+ else
+ {
+ skip_whitespace (str);
+
+ /* Allow optional leading '#'. */
+ if (is_immediate_prefix (* str))
+ str++;
+
+ memset (& expr, '\0', sizeof (expr));
+
+ if (my_get_expression (& expr, & str) || (expr.X_op != O_constant))
+ {
+ inst.error = _("bad or missing expression");
+ return FAIL;
+ }
+
+ number = expr.X_add_number;
+
+ if (number != (number & immediate_size))
+ {
+ inst.error = _("immediate value out of range");
+ return FAIL;
+ }
+ end_of_line (str);
+ inst.error = inst_error;
+ return number;
+ }
+}
+
+static void
+do_iwmmxt_byte_addr (str)
+ char * str;
+{
+ int op = (inst.instruction & 0x300) >> 8;
+ int reg;
+
+ inst.instruction &= ~0x300;
+ inst.instruction |= (op & 1) << 22 | (op & 2) << 7;
+
+ skip_whitespace (str);
+
+ if ((reg = wreg_required_here (&str, 12, IWMMXT_REG_WR_OR_WC)) == FAIL
+ || skip_past_comma (& str) == FAIL
+ || cp_byte_address_required_here (&str) == FAIL)
+ {
+ if (! inst.error)
+ inst.error = BAD_ARGS;
+ }
+ else
+ end_of_line (str);
+
+ if (wc_register (reg))
+ {
+ as_bad (_("non-word size not supported with control register"));
+ inst.instruction |= 0xf0000100;
+ inst.instruction &= ~0x00400000;
+ }
+}
+
+static void
+do_iwmmxt_tandc (str)
+ char * str;
+{
+ int reg;
+
+ reg = check_iwmmxt_insn (str, check_rd, 0);
+
+ if (reg != REG_PC && !inst.error)
+ inst.error = _("only r15 allowed here");
+}
+
+static void
+do_iwmmxt_tbcst (str)
+ char * str;
+{
+ check_iwmmxt_insn (str, check_tbcst, 0);
+}
+
+static void
+do_iwmmxt_textrc (str)
+ char * str;
+{
+ unsigned long number;
+
+ if ((number = check_iwmmxt_insn (str, check_textrc, 7)) == (unsigned long) FAIL)
+ return;
+
+ inst.instruction |= number & 0x7;
+}
+
+static void
+do_iwmmxt_textrm (str)
+ char * str;
+{
+ unsigned long number;
+
+ if ((number = check_iwmmxt_insn (str, check_textrm, 7)) == (unsigned long) FAIL)
+ return;
+
+ inst.instruction |= number & 0x7;
+}
+
+static void
+do_iwmmxt_tinsr (str)
+ char * str;
+{
+ unsigned long number;
+
+ if ((number = check_iwmmxt_insn (str, check_tinsr, 7)) == (unsigned long) FAIL)
+ return;
+
+ inst.instruction |= number & 0x7;
+}
+
+static void
+do_iwmmxt_tmcr (str)
+ char * str;
+{
+ check_iwmmxt_insn (str, check_tmcr, 0);
+}
+
+static void
+do_iwmmxt_tmcrr (str)
+ char * str;
+{
+ check_iwmmxt_insn (str, check_tmcrr, 0);
+}
+
+static void
+do_iwmmxt_tmia (str)
+ char * str;
+{
+ check_iwmmxt_insn (str, check_tmia, 0);
+}
+
+static void
+do_iwmmxt_tmovmsk (str)
+ char * str;
+{
+ check_iwmmxt_insn (str, check_tmovmsk, 0);
+}
+
+static void
+do_iwmmxt_tmrc (str)
+ char * str;
+{
+ check_iwmmxt_insn (str, check_tmrc, 0);
+}
+
+static void
+do_iwmmxt_tmrrc (str)
+ char * str;
+{
+ check_iwmmxt_insn (str, check_tmrrc, 0);
+}
+
+static void
+do_iwmmxt_torc (str)
+ char * str;
+{
+ check_iwmmxt_insn (str, check_rd, 0);
+}
+
+static void
+do_iwmmxt_waligni (str)
+ char * str;
+{
+ unsigned long number;
+
+ if ((number = check_iwmmxt_insn (str, check_waligni, 7)) == (unsigned long) FAIL)
+ return;
+
+ inst.instruction |= ((number & 0x7) << 20);
+}
+
+static void
+do_iwmmxt_wmov (str)
+ char * str;
+{
+ if (check_iwmmxt_insn (str, check_wrwr, 0) == (unsigned long) FAIL)
+ return;
+
+ inst.instruction |= ((inst.instruction >> 16) & 0xf);
+}
+
+static void
+do_iwmmxt_word_addr (str)
+ char * str;
+{
+ int op = (inst.instruction & 0x300) >> 8;
+ int reg;
+
+ inst.instruction &= ~0x300;
+ inst.instruction |= (op & 1) << 22 | (op & 2) << 7;
+
+ skip_whitespace (str);
+
+ if ((reg = wreg_required_here (&str, 12, IWMMXT_REG_WR_OR_WC)) == FAIL
+ || skip_past_comma (& str) == FAIL
+ || cp_address_required_here (& str, CP_WB_OK) == FAIL)
+ {
+ if (! inst.error)
+ inst.error = BAD_ARGS;
+ }
+ else
+ end_of_line (str);
+
+ if (wc_register (reg))
+ {
+ if ((inst.instruction & COND_MASK) != COND_ALWAYS)
+ as_bad (_("conditional execution not supported with control register"));
+ if (op != 2)
+ as_bad (_("non-word size not supported with control register"));
+ inst.instruction |= 0xf0000100;
+ inst.instruction &= ~0x00400000;
+ }
+}
+
+static void
+do_iwmmxt_wrwr (str)
+ char * str;
+{
+ check_iwmmxt_insn (str, check_wrwr, 0);
+}
+
+static void
+do_iwmmxt_wrwrwcg (str)
+ char * str;
+{
+ check_iwmmxt_insn (str, check_wrwrwcg, 0);
+}
+
+static void
+do_iwmmxt_wrwrwr (str)
+ char * str;
+{
+ check_iwmmxt_insn (str, check_wrwrwr, 0);
+}
+
+static void
+do_iwmmxt_wshufh (str)
+ char * str;
+{
+ unsigned long number;
+
+ if ((number = check_iwmmxt_insn (str, check_wshufh, 0xff)) == (unsigned long) FAIL)
+ return;
+
+ inst.instruction |= ((number & 0xf0) << 16) | (number & 0xf);
+}
+
+static void
+do_iwmmxt_wzero (str)
+ char * str;
+{
+ if (check_iwmmxt_insn (str, check_wr, 0) == (unsigned long) FAIL)
+ return;
+
+ inst.instruction |= ((inst.instruction & 0xf) << 12) | ((inst.instruction & 0xf) << 16);
+}
+
/* Xscale multiply-accumulate (argument parse)
MIAcc acc0,Rm,Rs
MIAPHcc acc0,Rm,Rs
@@ -4440,7 +6793,7 @@ my_get_float_expression (str)
return -1;
}
-/* Return true if anything in the expression is a bignum. */
+/* Return TRUE if anything in the expression is a bignum. */
static int
walk_no_bignums (sp)
@@ -4531,13 +6884,12 @@ md_operand (expr)
}
}
-/* UNRESTRICT should be one if <shift> <register> is permitted for this
- instruction. */
+/* KIND indicates what kind of shifts are accepted. */
static int
-decode_shift (str, unrestrict)
+decode_shift (str, kind)
char ** str;
- int unrestrict;
+ int kind;
{
const struct asm_shift_name * shift;
char * p;
@@ -4567,6 +6919,26 @@ decode_shift (str, unrestrict)
assert (shift->properties->index == shift_properties[shift->properties->index].index);
+ if (kind == SHIFT_LSL_OR_ASR_IMMEDIATE
+ && shift->properties->index != SHIFT_LSL
+ && shift->properties->index != SHIFT_ASR)
+ {
+ inst.error = _("'LSL' or 'ASR' required");
+ return FAIL;
+ }
+ else if (kind == SHIFT_LSL_IMMEDIATE
+ && shift->properties->index != SHIFT_LSL)
+ {
+ inst.error = _("'LSL' required");
+ return FAIL;
+ }
+ else if (kind == SHIFT_ASR_IMMEDIATE
+ && shift->properties->index != SHIFT_ASR)
+ {
+ inst.error = _("'ASR' required");
+ return FAIL;
+ }
+
if (shift->properties->index == SHIFT_RRX)
{
* str = p;
@@ -4576,7 +6948,7 @@ decode_shift (str, unrestrict)
skip_whitespace (p);
- if (unrestrict && reg_required_here (& p, 8) != FAIL)
+ if (kind == NO_SHIFT_RESTRICT && reg_required_here (& p, 8) != FAIL)
{
inst.instruction |= shift->properties->bit_field | SHIFT_BY_REG;
* str = p;
@@ -4584,7 +6956,7 @@ decode_shift (str, unrestrict)
}
else if (! is_immediate_prefix (* p))
{
- inst.error = (unrestrict
+ inst.error = (NO_SHIFT_RESTRICT
? _("shift requires register or #expression")
: _("shift requires #expression"));
* str = p;
@@ -4646,7 +7018,7 @@ decode_shift (str, unrestrict)
}
/* Do those data_ops which can take a negative immediate constant
- by altering the instuction. A bit of a hack really.
+ by altering the instruction. A bit of a hack really.
MOV <-> MVN
AND <-> BIC
ADC <-> SBC
@@ -4899,7 +7271,6 @@ do_arit (str)
}
end_of_line (str);
- return;
}
static void
@@ -4922,7 +7293,9 @@ do_adr (str)
/* Frag hacking will turn this into a sub instruction if the offset turns
out to be negative. */
inst.reloc.type = BFD_RELOC_ARM_IMMEDIATE;
+#ifndef TE_WINCE
inst.reloc.exp.X_add_number -= 8; /* PC relative adjust. */
+#endif
inst.reloc.pc_rel = 1;
end_of_line (str);
@@ -4953,11 +7326,11 @@ do_adrl (str)
/* Frag hacking will turn this into a sub instruction if the offset turns
out to be negative. */
inst.reloc.type = BFD_RELOC_ARM_ADRL_IMMEDIATE;
+#ifndef TE_WINCE
inst.reloc.exp.X_add_number -= 8; /* PC relative adjust */
+#endif
inst.reloc.pc_rel = 1;
inst.size = INSN_SIZE * 2;
-
- return;
}
static void
@@ -4982,7 +7355,6 @@ do_cmp (str)
}
end_of_line (str);
- return;
}
static void
@@ -5007,7 +7379,6 @@ do_mov (str)
}
end_of_line (str);
- return;
}
static int
@@ -5063,7 +7434,7 @@ ldst_extend (str)
inst.instruction |= add | OFFSET_REG;
if (skip_past_comma (str) == SUCCESS)
- return decode_shift (str, SHIFT_RESTRICT);
+ return decode_shift (str, SHIFT_IMMEDIATE);
return SUCCESS;
}
@@ -5258,7 +7629,6 @@ do_ldst (str)
inst.instruction |= (pre_inc ? PRE_INDEX : 0);
end_of_line (str);
- return;
}
static void
@@ -5337,7 +7707,6 @@ do_ldstt (str)
}
end_of_line (str);
- return;
}
static int
@@ -5593,7 +7962,6 @@ do_ldstv4 (str)
inst.instruction |= (pre_inc ? PRE_INDEX : 0);
end_of_line (str);
- return;
}
static long
@@ -5763,9 +8131,33 @@ do_ldmstm (str)
inst.instruction |= LDM_TYPE_2_OR_3;
}
+ if (inst.instruction & WRITE_BACK)
+ {
+ /* Check for unpredictable uses of writeback. */
+ if (inst.instruction & LOAD_BIT)
+ {
+ /* Not allowed in LDM type 2. */
+ if ((inst.instruction & LDM_TYPE_2_OR_3)
+ && ((range & (1 << REG_PC)) == 0))
+ as_warn (_("writeback of base register is UNPREDICTABLE"));
+ /* Only allowed if base reg not in list for other types. */
+ else if (range & (1 << base_reg))
+ as_warn (_("writeback of base register when in register list is UNPREDICTABLE"));
+ }
+ else /* STM. */
+ {
+ /* Not allowed for type 2. */
+ if (inst.instruction & LDM_TYPE_2_OR_3)
+ as_warn (_("writeback of base register is UNPREDICTABLE"));
+ /* Only allowed if base reg not in list, or first in list. */
+ else if ((range & (1 << base_reg))
+ && (range & ((1 << base_reg) - 1)))
+ as_warn (_("if writeback register is in list, it must be the lowest reg in the list"));
+ }
+ }
+
inst.instruction |= range;
end_of_line (str);
- return;
}
static void
@@ -5784,8 +8176,6 @@ do_swi (str)
inst.reloc.type = BFD_RELOC_ARM_SWI;
inst.reloc.pc_rel = 0;
end_of_line (str);
-
- return;
}
static void
@@ -5846,7 +8236,6 @@ do_swap (str)
}
end_of_line (str);
- return;
}
static void
@@ -5891,7 +8280,6 @@ do_branch (str)
#endif /* OBJ_ELF */
end_of_line (str);
- return;
}
static void
@@ -5973,7 +8361,6 @@ do_cdp (str)
}
end_of_line (str);
- return;
}
static void
@@ -6009,7 +8396,6 @@ do_lstc (str)
}
end_of_line (str);
- return;
}
static void
@@ -6071,7 +8457,6 @@ do_co_reg (str)
}
end_of_line (str);
- return;
}
static void
@@ -6091,7 +8476,6 @@ do_fpa_ctrl (str)
}
end_of_line (str);
- return;
}
static void
@@ -6287,7 +8671,6 @@ do_fpa_dyadic (str)
}
end_of_line (str);
- return;
}
static void
@@ -6312,7 +8695,6 @@ do_fpa_monadic (str)
}
end_of_line (str);
- return;
}
static void
@@ -6337,7 +8719,6 @@ do_fpa_cmp (str)
}
end_of_line (str);
- return;
}
static void
@@ -6362,7 +8743,6 @@ do_fpa_from_reg (str)
}
end_of_line (str);
- return;
}
static void
@@ -6383,7 +8763,6 @@ do_fpa_to_reg (str)
}
end_of_line (str);
- return;
}
static int
@@ -6482,7 +8861,6 @@ do_vfp_sp_monadic (str)
}
end_of_line (str);
- return;
}
static void
@@ -6503,7 +8881,6 @@ do_vfp_dp_monadic (str)
}
end_of_line (str);
- return;
}
static void
@@ -6526,7 +8903,6 @@ do_vfp_sp_dyadic (str)
}
end_of_line (str);
- return;
}
static void
@@ -6549,7 +8925,6 @@ do_vfp_dp_dyadic (str)
}
end_of_line (str);
- return;
}
static void
@@ -6570,19 +8945,16 @@ do_vfp_reg_from_sp (str)
}
end_of_line (str);
- return;
}
static void
-do_vfp_sp_reg2 (str)
+do_vfp_reg2_from_sp2 (str)
char *str;
{
skip_whitespace (str);
- if (reg_required_here (&str, 12) == FAIL)
- return;
-
- if (skip_past_comma (&str) == FAIL
+ if (reg_required_here (&str, 12) == FAIL
+ || skip_past_comma (&str) == FAIL
|| reg_required_here (&str, 16) == FAIL
|| skip_past_comma (&str) == FAIL)
{
@@ -6599,7 +8971,6 @@ do_vfp_sp_reg2 (str)
}
end_of_line (str);
- return;
}
static void
@@ -6620,7 +8991,32 @@ do_vfp_sp_from_reg (str)
}
end_of_line (str);
- return;
+}
+
+static void
+do_vfp_sp2_from_reg2 (str)
+ char *str;
+{
+ skip_whitespace (str);
+
+ /* We require exactly two consecutive SP registers. */
+ if (vfp_sp_reg_list (&str, VFP_REG_Sm) != 2)
+ {
+ if (! inst.error)
+ inst.error = _("only two consecutive VFP SP registers allowed here");
+ }
+
+ if (skip_past_comma (&str) == FAIL
+ || reg_required_here (&str, 12) == FAIL
+ || skip_past_comma (&str) == FAIL
+ || reg_required_here (&str, 16) == FAIL)
+ {
+ if (! inst.error)
+ inst.error = BAD_ARGS;
+ return;
+ }
+
+ end_of_line (str);
}
static void
@@ -6641,7 +9037,6 @@ do_vfp_reg_from_dp (str)
}
end_of_line (str);
- return;
}
static void
@@ -6664,7 +9059,6 @@ do_vfp_reg2_from_dp (str)
}
end_of_line (str);
- return;
}
static void
@@ -6685,7 +9079,6 @@ do_vfp_dp_from_reg (str)
}
end_of_line (str);
- return;
}
static void
@@ -6700,7 +9093,7 @@ do_vfp_dp_from_reg2 (str)
if (skip_past_comma (&str) == FAIL
|| reg_required_here (&str, 12) == FAIL
|| skip_past_comma (&str) == FAIL
- || reg_required_here (&str, 16))
+ || reg_required_here (&str, 16) == FAIL)
{
if (! inst.error)
inst.error = BAD_ARGS;
@@ -6708,7 +9101,6 @@ do_vfp_dp_from_reg2 (str)
}
end_of_line (str);
- return;
}
static const struct vfp_reg *
@@ -6787,7 +9179,6 @@ do_vfp_reg_from_ctrl (str)
}
end_of_line (str);
- return;
}
static void
@@ -6808,7 +9199,6 @@ do_vfp_ctrl_from_reg (str)
}
end_of_line (str);
- return;
}
static void
@@ -6833,7 +9223,6 @@ do_vfp_sp_ldst (str)
}
end_of_line (str);
- return;
}
static void
@@ -6858,7 +9247,6 @@ do_vfp_dp_ldst (str)
}
end_of_line (str);
- return;
}
/* Parse and encode a VFP SP register list, storing the initial
@@ -7225,7 +9613,6 @@ do_vfp_sp_compare_z (str)
}
end_of_line (str);
- return;
}
static void
@@ -7242,7 +9629,6 @@ do_vfp_dp_compare_z (str)
}
end_of_line (str);
- return;
}
static void
@@ -7263,7 +9649,6 @@ do_vfp_dp_sp_cvt (str)
}
end_of_line (str);
- return;
}
static void
@@ -7284,7 +9669,6 @@ do_vfp_sp_dp_cvt (str)
}
end_of_line (str);
- return;
}
/* Thumb specific routines. */
@@ -7629,7 +10013,7 @@ thumb_mov_compare (str, move)
return;
}
- if (is_immediate_prefix (*str))
+ if (move != THUMB_CPY && is_immediate_prefix (*str))
{
str++;
if (my_get_expression (&inst.reloc.exp, &str))
@@ -7640,7 +10024,7 @@ thumb_mov_compare (str, move)
if (Rs != FAIL)
{
- if (Rs < 8 && Rd < 8)
+ if (move != THUMB_CPY && Rs < 8 && Rd < 8)
{
if (move == THUMB_MOVE)
/* A move of two lowregs is encoded as ADD Rd, Rs, #0
@@ -7654,7 +10038,7 @@ thumb_mov_compare (str, move)
{
if (move == THUMB_MOVE)
inst.instruction = T_OPCODE_MOV_HR;
- else
+ else if (move != THUMB_CPY)
inst.instruction = T_OPCODE_CMP_HR;
if (Rd > 7)
@@ -8184,7 +10568,7 @@ do_mav_quad_6b (str)
REG_TYPE_MVFX);
}
-/* cfmvsc32<cond> DSPSC,MVFX[15:0]. */
+/* cfmvsc32<cond> DSPSC,MVDX[15:0]. */
static void
do_mav_dspsc_1 (str)
char * str;
@@ -8194,7 +10578,7 @@ do_mav_dspsc_1 (str)
/* cfmvsc32. */
if (mav_reg_required_here (&str, -1, REG_TYPE_DSPSC) == FAIL
|| skip_past_comma (&str) == FAIL
- || mav_reg_required_here (&str, 16, REG_TYPE_MVFX) == FAIL)
+ || mav_reg_required_here (&str, 12, REG_TYPE_MVDX) == FAIL)
{
if (!inst.error)
inst.error = BAD_ARGS;
@@ -8205,7 +10589,7 @@ do_mav_dspsc_1 (str)
end_of_line (str);
}
-/* cfmv32sc<cond> MVFX[15:0],DSPSC. */
+/* cfmv32sc<cond> MVDX[15:0],DSPSC. */
static void
do_mav_dspsc_2 (str)
char * str;
@@ -8213,7 +10597,7 @@ do_mav_dspsc_2 (str)
skip_whitespace (str);
/* cfmv32sc. */
- if (mav_reg_required_here (&str, 0, REG_TYPE_MVFX) == FAIL
+ if (mav_reg_required_here (&str, 12, REG_TYPE_MVDX) == FAIL
|| skip_past_comma (&str) == FAIL
|| mav_reg_required_here (&str, -1, REG_TYPE_DSPSC) == FAIL)
{
@@ -8534,7 +10918,7 @@ do_mav_ldst (str, reg0)
if (negative)
offset = -offset;
else
- inst.instruction |= CP_T_UD; /* Postive, so set bit U. */
+ inst.instruction |= CP_T_UD; /* Positive, so set bit U. */
inst.instruction |= offset >> 2;
end_of_line (str);
@@ -8543,7 +10927,6 @@ do_mav_ldst (str, reg0)
fail_ldst:
if (!inst.error)
inst.error = BAD_ARGS;
- return;
}
static void
@@ -8552,7 +10935,6 @@ do_t_nop (str)
{
/* Do nothing. */
end_of_line (str);
- return;
}
/* Handle the Format 4 instructions that do not have equivalents in other
@@ -8654,7 +11036,7 @@ find_real_start (symbolP)
const char * name = S_GET_NAME (symbolP);
symbolS * new_target;
- /* This definiton must agree with the one in gcc/config/arm/thumb.c. */
+ /* This definition must agree with the one in gcc/config/arm/thumb.c. */
#define STUB_NAME ".real_start_of"
if (name == NULL)
@@ -8926,7 +11308,6 @@ do_t_swi (str)
inst.reloc.type = BFD_RELOC_ARM_SWI;
end_of_line (str);
- return;
}
static void
@@ -9002,20 +11383,29 @@ insert_reg_alias (str, regnum, htab)
int regnum;
struct hash_control *htab;
{
- struct reg_entry *new =
- (struct reg_entry *) xmalloc (sizeof (struct reg_entry));
- char *name = xmalloc (strlen (str) + 1);
- strcpy (name, str);
-
+ const char *error;
+ struct reg_entry *new = xmalloc (sizeof (struct reg_entry));
+ const char *name = xmalloc (strlen (str) + 1);
+
+ strcpy ((char *) name, str);
+
new->name = name;
new->number = regnum;
+ new->builtin = FALSE;
- hash_insert (htab, name, (PTR) new);
+ error = hash_insert (htab, name, (PTR) new);
+ if (error)
+ {
+ as_bad (_("failed to create an alias for %s, reason: %s"),
+ str, error);
+ free ((char *) name);
+ free (new);
+ }
}
/* Look for the .req directive. This is of the form:
- newname .req existing_name
+ new_register_name .req existing_register_name
If we find one, or if it looks sufficiently like one that we want to
handle any error here, return non-zero. Otherwise return zero. */
@@ -9095,6 +11485,7 @@ create_register_alias (newname, p)
*p = c;
return 1;
}
+
*p = c;
return 0;
}
@@ -9157,6 +11548,56 @@ build_arm_ops_hsh ()
}
}
+#if 0 /* Suppressed - for now. */
+#if defined OBJ_ELF || defined OBJ_COFF
+
+#ifdef OBJ_ELF
+#define arm_Note Elf_External_Note
+#else
+typedef struct
+{
+ unsigned char namesz[4]; /* Size of entry's owner string. */
+ unsigned char descsz[4]; /* Size of the note descriptor. */
+ unsigned char type[4]; /* Interpretation of the descriptor. */
+ char name[1]; /* Start of the name+desc data. */
+} arm_Note;
+#endif
+
+/* The description is kept to a fix sized in order to make updating
+ it and merging it easier. */
+#define ARM_NOTE_DESCRIPTION_LENGTH 8
+
+static void
+arm_add_note (name, description, type)
+ const char * name;
+ const char * description;
+ unsigned int type;
+{
+ arm_Note note ATTRIBUTE_UNUSED;
+ char * p;
+ unsigned int name_len;
+
+ name_len = (strlen (name) + 1 + 3) & ~3;
+
+ p = frag_more (sizeof (note.namesz));
+ md_number_to_chars (p, (valueT) name_len, sizeof (note.namesz));
+
+ p = frag_more (sizeof (note.descsz));
+ md_number_to_chars (p, (valueT) ARM_NOTE_DESCRIPTION_LENGTH, sizeof (note.descsz));
+
+ p = frag_more (sizeof (note.type));
+ md_number_to_chars (p, (valueT) type, sizeof (note.type));
+
+ p = frag_more (name_len);
+ strcpy (p, name);
+
+ p = frag_more (ARM_NOTE_DESCRIPTION_LENGTH);
+ strncpy (p, description, ARM_NOTE_DESCRIPTION_LENGTH);
+ frag_align (2, 0, 0);
+}
+#endif
+#endif
+
void
md_begin ()
{
@@ -9208,10 +11649,16 @@ md_begin ()
}
else if (mfpu_opt == -1)
{
+#if !(defined (TE_LINUX) || defined (TE_NetBSD))
+ /* Some environments specify a default FPU. If they don't, infer it
+ from the processor. */
if (mcpu_fpu_opt != -1)
mfpu_opt = mcpu_fpu_opt;
else
mfpu_opt = march_fpu_opt;
+#else
+ mfpu_opt = FPU_DEFAULT;
+#endif
}
if (mfpu_opt == -1)
@@ -9239,11 +11686,29 @@ md_begin ()
if (uses_apcs_float) flags |= F_APCS_FLOAT;
if (pic_code) flags |= F_PIC;
if ((cpu_variant & FPU_ANY) == FPU_NONE
- || (cpu_variant & FPU_ANY) == FPU_ARCH_VFP) /* VFP layout only. */
- flags |= F_SOFT_FLOAT;
+ || (cpu_variant & FPU_ANY) == FPU_ARCH_VFP) /* VFP layout only. */
+ {
+ flags |= F_SOFT_FLOAT;
+ }
+ switch (mfloat_abi_opt)
+ {
+ case ARM_FLOAT_ABI_SOFT:
+ case ARM_FLOAT_ABI_SOFTFP:
+ flags |= F_SOFT_FLOAT;
+ break;
+
+ case ARM_FLOAT_ABI_HARD:
+ if (flags & F_SOFT_FLOAT)
+ as_bad (_("hard-float conflicts with specified fpu"));
+ break;
+ }
/* Using VFP conventions (even if soft-float). */
if (cpu_variant & FPU_VFP_EXT_NONE) flags |= F_VFP_FLOAT;
+#if defined OBJ_ELF
+ if (cpu_variant & FPU_ARCH_MAVERICK)
+ flags |= EF_ARM_MAVERICK_FLOAT;
+#endif
bfd_set_private_flags (stdoutput, flags);
@@ -9283,13 +11748,17 @@ md_begin ()
break;
default:
- mach = bfd_mach_arm_4;
+ mach = bfd_mach_arm_unknown;
break;
}
/* Catch special cases. */
- if (cpu_variant & ARM_CEXT_XSCALE)
+ if (cpu_variant & ARM_CEXT_IWMMXT)
+ mach = bfd_mach_arm_iWMMXt;
+ else if (cpu_variant & ARM_CEXT_XSCALE)
mach = bfd_mach_arm_XScale;
+ else if (cpu_variant & ARM_CEXT_MAVERICK)
+ mach = bfd_mach_arm_ep9312;
else if (cpu_variant & ARM_EXT_V5E)
mach = bfd_mach_arm_5TE;
else if (cpu_variant & ARM_EXT_V5)
@@ -9309,6 +11778,62 @@ md_begin ()
else if (cpu_variant & ARM_EXT_V3M)
mach = bfd_mach_arm_3M;
+#if 0 /* Suppressed - for now. */
+#if defined (OBJ_ELF) || defined (OBJ_COFF)
+
+ /* Create a .note section to fully identify this arm binary. */
+
+#define NOTE_ARCH_STRING "arch: "
+
+#if defined OBJ_COFF && ! defined NT_VERSION
+#define NT_VERSION 1
+#define NT_ARCH 2
+#endif
+
+ {
+ segT current_seg = now_seg;
+ subsegT current_subseg = now_subseg;
+ asection * arm_arch;
+ const char * arch_string;
+
+ arm_arch = bfd_make_section_old_way (stdoutput, ARM_NOTE_SECTION);
+
+#ifdef OBJ_COFF
+ bfd_set_section_flags (stdoutput, arm_arch,
+ SEC_DATA | SEC_ALLOC | SEC_LOAD | SEC_LINK_ONCE \
+ | SEC_HAS_CONTENTS);
+#else
+ bfd_set_section_flags (stdoutput, arm_arch,
+ SEC_READONLY | SEC_HAS_CONTENTS);
+#endif
+ arm_arch->output_section = arm_arch;
+ subseg_set (arm_arch, 0);
+
+ switch (mach)
+ {
+ default:
+ case bfd_mach_arm_unknown: arch_string = "unknown"; break;
+ case bfd_mach_arm_2: arch_string = "armv2"; break;
+ case bfd_mach_arm_2a: arch_string = "armv2a"; break;
+ case bfd_mach_arm_3: arch_string = "armv3"; break;
+ case bfd_mach_arm_3M: arch_string = "armv3M"; break;
+ case bfd_mach_arm_4: arch_string = "armv4"; break;
+ case bfd_mach_arm_4T: arch_string = "armv4t"; break;
+ case bfd_mach_arm_5: arch_string = "armv5"; break;
+ case bfd_mach_arm_5T: arch_string = "armv5t"; break;
+ case bfd_mach_arm_5TE: arch_string = "armv5te"; break;
+ case bfd_mach_arm_XScale: arch_string = "XScale"; break;
+ case bfd_mach_arm_ep9312: arch_string = "ep9312"; break;
+ case bfd_mach_arm_iWMMXt: arch_string = "iWMMXt"; break;
+ }
+
+ arm_add_note (NOTE_ARCH_STRING, arch_string, NT_ARCH);
+
+ subseg_set (current_seg, current_subseg);
+ }
+#endif
+#endif /* Suppressed code. */
+
bfd_set_arch_mach (stdoutput, TARGET_ARCH, mach);
}
@@ -9471,8 +11996,8 @@ md_pcrel_from (fixP)
}
#ifdef TE_WINCE
- /* The pattern was adjusted to accomodate CE's off-by-one fixups,
- so we un-adjust here to compensate for the accomodation. */
+ /* The pattern was adjusted to accommodate CE's off-by-one fixups,
+ so we un-adjust here to compensate for the accommodation. */
return fixP->fx_where + fixP->fx_frag->fr_address + 8;
#else
return fixP->fx_where + fixP->fx_frag->fr_address;
@@ -9649,12 +12174,14 @@ md_apply_fix3 (fixP, valP, seg)
newimm |= (temp & 0xfffff000);
md_number_to_chars (buf, (valueT) newimm, INSN_SIZE);
+ fixP->fx_done = 1;
break;
case BFD_RELOC_ARM_ADRL_IMMEDIATE:
{
unsigned int highpart = 0;
unsigned int newinsn = 0xe1a00000; /* nop. */
+
newimm = validate_immediate (value);
temp = md_chars_to_number (buf, INSN_SIZE);
@@ -9679,7 +12206,7 @@ md_apply_fix3 (fixP, valP, seg)
{
as_bad_where (fixP->fx_file, fixP->fx_line,
_("unable to compute ADRL instructions for PC offset of 0x%lx"),
- value);
+ (long) value);
break;
}
@@ -9835,7 +12362,7 @@ md_apply_fix3 (fixP, valP, seg)
the absolute address that is the destination of the branch in the
24 bits of the branch instruction. If however, we happen to know
that the destination of the branch is in the same section as the
- branch instruciton itself, then we can compute the relocation for
+ branch instruction itself, then we can compute the relocation for
ourselves and not have to bother the linker with it.
FIXME: The tests for OBJ_ELF and ! target_oabi are only here
@@ -10007,10 +12534,6 @@ md_apply_fix3 (fixP, valP, seg)
break;
#endif
- case BFD_RELOC_ARM_GOTPC:
- md_number_to_chars (buf, value, 4);
- break;
-
case BFD_RELOC_ARM_CP_OFF_IMM:
sign = value >= 0;
if (value < -1023 || value > 1023 || (value & 3))
@@ -10023,6 +12546,18 @@ md_apply_fix3 (fixP, valP, seg)
md_number_to_chars (buf, newval, INSN_SIZE);
break;
+ case BFD_RELOC_ARM_CP_OFF_IMM_S2:
+ sign = value >= 0;
+ if (value < -255 || value > 255)
+ as_bad_where (fixP->fx_file, fixP->fx_line,
+ _("Illegal value for co-processor offset"));
+ if (value < 0)
+ value = -value;
+ newval = md_chars_to_number (buf, INSN_SIZE) & 0xff7fff00;
+ newval |= value | (sign ? INDEX_UP : 0);
+ md_number_to_chars (buf, newval , INSN_SIZE);
+ break;
+
case BFD_RELOC_ARM_THUMB_OFFSET:
newval = md_chars_to_number (buf, THUMB_SIZE);
/* Exactly what ranges, and where the offset is inserted depends
@@ -10045,7 +12580,8 @@ md_apply_fix3 (fixP, valP, seg)
if ((value + 2) & ~0x3fe)
as_bad_where (fixP->fx_file, fixP->fx_line,
- _("invalid offset, value too big (0x%08lX)"), value);
+ _("invalid offset, value too big (0x%08lX)"),
+ (long) value);
/* Round up, since pc will be rounded down. */
newval |= (value + 2) >> 2;
@@ -10054,28 +12590,32 @@ md_apply_fix3 (fixP, valP, seg)
case 9: /* SP load/store. */
if (value & ~0x3fc)
as_bad_where (fixP->fx_file, fixP->fx_line,
- _("invalid offset, value too big (0x%08lX)"), value);
+ _("invalid offset, value too big (0x%08lX)"),
+ (long) value);
newval |= value >> 2;
break;
case 6: /* Word load/store. */
if (value & ~0x7c)
as_bad_where (fixP->fx_file, fixP->fx_line,
- _("invalid offset, value too big (0x%08lX)"), value);
+ _("invalid offset, value too big (0x%08lX)"),
+ (long) value);
newval |= value << 4; /* 6 - 2. */
break;
case 7: /* Byte load/store. */
if (value & ~0x1f)
as_bad_where (fixP->fx_file, fixP->fx_line,
- _("invalid offset, value too big (0x%08lX)"), value);
+ _("invalid offset, value too big (0x%08lX)"),
+ (long) value);
newval |= value << 6;
break;
case 8: /* Halfword load/store. */
if (value & ~0x3e)
as_bad_where (fixP->fx_file, fixP->fx_line,
- _("invalid offset, value too big (0x%08lX)"), value);
+ _("invalid offset, value too big (0x%08lX)"),
+ (long) value);
newval |= value << 5; /* 6 - 1. */
break;
@@ -10254,10 +12794,10 @@ tc_gen_reloc (section, fixp)
case BFD_RELOC_ARM_LITERAL:
case BFD_RELOC_ARM_HWLITERAL:
- /* If this is called then the a literal has been referenced across
- a section boundary - possibly due to an implicit dump. */
+ /* If this is called then the a literal has
+ been referenced across a section boundary. */
as_bad_where (fixp->fx_file, fixp->fx_line,
- _("literal referenced across section boundary (Implicit dump?)"));
+ _("literal referenced across section boundary"));
return NULL;
#ifdef OBJ_ELF
@@ -10270,8 +12810,7 @@ tc_gen_reloc (section, fixp)
case BFD_RELOC_ARM_IMMEDIATE:
as_bad_where (fixp->fx_file, fixp->fx_line,
- _("internal relocation (type %d) not fixed up (IMMEDIATE)"),
- fixp->fx_r_type);
+ _("internal relocation (type: IMMEDIATE) not fixed up"));
return NULL;
case BFD_RELOC_ARM_ADRL_IMMEDIATE:
@@ -10280,9 +12819,18 @@ tc_gen_reloc (section, fixp)
return NULL;
case BFD_RELOC_ARM_OFFSET_IMM:
+ if (fixp->fx_addsy != NULL
+ && !S_IS_DEFINED (fixp->fx_addsy)
+ && S_IS_LOCAL (fixp->fx_addsy))
+ {
+ as_bad_where (fixp->fx_file, fixp->fx_line,
+ _("undefined local label `%s'"),
+ S_GET_NAME (fixp->fx_addsy));
+ return NULL;
+ }
+
as_bad_where (fixp->fx_file, fixp->fx_line,
- _("internal_relocation (type %d) not fixed up (OFFSET_IMM)"),
- fixp->fx_r_type);
+ _("internal_relocation (type: OFFSET_IMM) not fixed up"));
return NULL;
default:
@@ -10291,8 +12839,6 @@ tc_gen_reloc (section, fixp)
switch (fixp->fx_r_type)
{
- case BFD_RELOC_ARM_IMMEDIATE: type = "IMMEDIATE"; break;
- case BFD_RELOC_ARM_OFFSET_IMM: type = "OFFSET_IMM"; break;
case BFD_RELOC_ARM_OFFSET_IMM8: type = "OFFSET_IMM8"; break;
case BFD_RELOC_ARM_SHIFT_IMM: type = "SHIFT_IMM"; break;
case BFD_RELOC_ARM_SWI: type = "SWI"; break;
@@ -10312,7 +12858,7 @@ tc_gen_reloc (section, fixp)
}
#ifdef OBJ_ELF
- if (code == BFD_RELOC_32_PCREL
+ if ((code == BFD_RELOC_32_PCREL || code == BFD_RELOC_32)
&& GOT_symbol
&& fixp->fx_addsy == GOT_symbol)
{
@@ -10444,6 +12990,7 @@ md_assemble (str)
return;
}
+ mapping_state (MAP_THUMB);
inst.instruction = opcode->value;
inst.size = opcode->size;
(*opcode->parms) (p);
@@ -10469,6 +13016,7 @@ md_assemble (str)
return;
}
+ mapping_state (MAP_ARM);
inst.instruction = opcode->value;
inst.size = INSN_SIZE;
(*opcode->parms) (p);
@@ -10505,7 +13053,7 @@ md_assemble (str)
-mthumb Start in Thumb mode
-mthumb-interwork Code supports ARM/Thumb interworking
- For now we will also provide support for
+ For now we will also provide support for:
-mapcs-32 32-bit Program counter
-mapcs-26 26-bit Program counter
@@ -10680,6 +13228,7 @@ struct arm_option_table arm_opts[] =
{"mstrongarm1110", NULL, &legacy_cpu, ARM_ARCH_V4,
N_("use -mcpu=strongarm1110")},
{"mxscale", NULL, &legacy_cpu, ARM_ARCH_XSCALE, N_("use -mcpu=xscale")},
+ {"miwmmxt", NULL, &legacy_cpu, ARM_ARCH_IWMMXT, N_("use -mcpu=iwmmxt")},
{"mall", NULL, &legacy_cpu, ARM_ANY, N_("use -mcpu=all")},
/* Architecture variants -- don't add any more to this list either. */
@@ -10773,6 +13322,7 @@ static struct arm_cpu_option_table arm_cpus[] =
{"arm9e-r0", ARM_ARCH_V5TExP, FPU_ARCH_VFP_V2},
{"arm9e", ARM_ARCH_V5TE, FPU_ARCH_VFP_V2},
{"arm926ej", ARM_ARCH_V5TEJ, FPU_ARCH_VFP_V2},
+ {"arm926ejs", ARM_ARCH_V5TEJ, FPU_ARCH_VFP_V2},
{"arm946e-r0", ARM_ARCH_V5TExP, FPU_ARCH_VFP_V2},
{"arm946e", ARM_ARCH_V5TE, FPU_ARCH_VFP_V2},
{"arm966e-r0", ARM_ARCH_V5TExP, FPU_ARCH_VFP_V2},
@@ -10782,11 +13332,16 @@ static struct arm_cpu_option_table arm_cpus[] =
{"arm1020", ARM_ARCH_V5TE, FPU_ARCH_VFP_V2},
{"arm1020t", ARM_ARCH_V5T, FPU_ARCH_VFP_V1},
{"arm1020e", ARM_ARCH_V5TE, FPU_ARCH_VFP_V2},
+ {"arm1026ejs", ARM_ARCH_V5TE, FPU_ARCH_VFP_V2},
+ {"arm1136js", ARM_ARCH_V6, FPU_NONE},
+ {"arm1136jfs", ARM_ARCH_V6, FPU_ARCH_VFP_V2},
/* ??? XSCALE is really an architecture. */
{"xscale", ARM_ARCH_XSCALE, FPU_ARCH_VFP_V2},
+ /* ??? iwmmxt is not a processor. */
+ {"iwmmxt", ARM_ARCH_IWMMXT, FPU_ARCH_VFP_V2},
{"i80200", ARM_ARCH_XSCALE, FPU_ARCH_VFP_V2},
/* Maverick */
- {"ep9312", ARM_ARCH_V4T | ARM_CEXT_MAVERICK, FPU_NONE},
+ {"ep9312", ARM_ARCH_V4T | ARM_CEXT_MAVERICK, FPU_ARCH_MAVERICK},
{NULL, 0, 0}
};
@@ -10818,7 +13373,10 @@ static struct arm_arch_option_table arm_archs[] =
{"armv5te", ARM_ARCH_V5TE, FPU_ARCH_VFP},
{"armv5texp", ARM_ARCH_V5TExP, FPU_ARCH_VFP},
{"armv5tej", ARM_ARCH_V5TEJ, FPU_ARCH_VFP},
+ {"armv6", ARM_ARCH_V6, FPU_ARCH_VFP},
+ {"armv6j", ARM_ARCH_V6, FPU_ARCH_VFP},
{"xscale", ARM_ARCH_XSCALE, FPU_ARCH_VFP},
+ {"iwmmxt", ARM_ARCH_IWMMXT, FPU_ARCH_VFP},
{NULL, 0, 0}
};
@@ -10833,6 +13391,7 @@ static struct arm_arch_extension_table arm_extensions[] =
{
{"maverick", ARM_CEXT_MAVERICK},
{"xscale", ARM_CEXT_XSCALE},
+ {"iwmmxt", ARM_CEXT_IWMMXT},
{NULL, 0}
};
@@ -10863,6 +13422,22 @@ static struct arm_fpu_option_table arm_fpus[] =
{"vfpxd", FPU_ARCH_VFP_V1xD},
{"arm1020t", FPU_ARCH_VFP_V1},
{"arm1020e", FPU_ARCH_VFP_V2},
+ {"arm1136jfs", FPU_ARCH_VFP_V2},
+ {"maverick", FPU_ARCH_MAVERICK},
+ {NULL, 0}
+};
+
+struct arm_float_abi_option_table
+{
+ char *name;
+ int value;
+};
+
+static struct arm_float_abi_option_table arm_float_abis[] =
+{
+ {"hard", ARM_FLOAT_ABI_HARD},
+ {"softfp", ARM_FLOAT_ABI_SOFTFP},
+ {"soft", ARM_FLOAT_ABI_SOFT},
{NULL, 0}
};
@@ -11012,6 +13587,23 @@ arm_parse_fpu (str)
return 0;
}
+static int
+arm_parse_float_abi (str)
+ char * str;
+{
+ struct arm_float_abi_option_table *opt;
+
+ for (opt = arm_float_abis; opt->name != NULL; opt++)
+ if (strcmp (opt->name, str) == 0)
+ {
+ mfloat_abi_opt = opt->value;
+ return 1;
+ }
+
+ as_bad (_("unknown floating point abi `%s'\n"), str);
+ return 0;
+}
+
struct arm_long_option_table arm_long_opts[] =
{
{"mcpu=", N_("<cpu name>\t assemble for CPU <cpu name>"),
@@ -11020,6 +13612,8 @@ struct arm_long_option_table arm_long_opts[] =
arm_parse_arch, NULL},
{"mfpu=", N_("<fpu name>\t assemble for FPU architecture <fpu name>"),
arm_parse_fpu, NULL},
+ {"mfloat-abi=", N_("<abi>\t assemble for floating point ABI <abi>"),
+ arm_parse_float_abi, NULL},
{NULL, NULL, 0, NULL}
};
@@ -11165,8 +13759,6 @@ fix_new_arm (frag, where, size, exp, pc_rel, reloc)
arm_data = (arm_fix_data *) obstack_alloc (& notes, sizeof (arm_fix_data));
new_fix->tc_fix_data = (PTR) arm_data;
arm_data->thumb_mode = thumb_mode;
-
- return;
}
/* This fix_new is called by cons via TC_CONS_FIX_NEW. */
@@ -11210,12 +13802,17 @@ cons_fix_new_arm (frag, where, size, exp)
void
arm_cleanup ()
{
- if (current_poolP == NULL)
- return;
+ literal_pool * pool;
- /* Put it at the end of text section. */
- subseg_set (text_section, 0);
- s_ltorg (0);
+ for (pool = list_of_pools; pool; pool = pool->next)
+ {
+ /* Put it at the end of the relevent section. */
+ subseg_set (pool->section, pool->sub_section);
+#ifdef OBJ_ELF
+ arm_elf_change_section ();
+#endif
+ s_ltorg (0);
+ }
}
void
@@ -11276,7 +13873,7 @@ arm_frob_label (sym)
THUMB_SET_FUNC (sym, 1);
- label_is_thumb_function_name = false;
+ label_is_thumb_function_name = FALSE;
}
}
@@ -11380,7 +13977,8 @@ arm_canonicalize_symbol_name (name)
return name;
}
-boolean
+#if defined OBJ_COFF || defined OBJ_ELF
+void
arm_validate_fix (fixP)
fixS * fixP;
{
@@ -11394,10 +13992,33 @@ arm_validate_fix (fixP)
&& ! THUMB_IS_FUNC (fixP->fx_addsy))
{
fixP->fx_addsy = find_real_start (fixP->fx_addsy);
- return true;
}
+}
+#endif
+
+int
+arm_force_relocation (fixp)
+ struct fix * fixp;
+{
+#if defined (OBJ_COFF) && defined (TE_PE)
+ if (fixp->fx_r_type == BFD_RELOC_RVA)
+ return 1;
+#endif
+#ifdef OBJ_ELF
+ if (fixp->fx_r_type == BFD_RELOC_ARM_PCREL_BRANCH
+ || fixp->fx_r_type == BFD_RELOC_ARM_PCREL_BLX
+ || fixp->fx_r_type == BFD_RELOC_THUMB_PCREL_BLX
+ || fixp->fx_r_type == BFD_RELOC_THUMB_PCREL_BRANCH23)
+ return 1;
+#endif
- return false;
+ /* Resolve these relocations even if the symbol is extern or weak. */
+ if (fixp->fx_r_type == BFD_RELOC_ARM_IMMEDIATE
+ || fixp->fx_r_type == BFD_RELOC_ARM_OFFSET_IMM
+ || fixp->fx_r_type == BFD_RELOC_ARM_ADRL_IMMEDIATE)
+ return 0;
+
+ return generic_force_reloc (fixp);
}
#ifdef OBJ_COFF
@@ -11407,7 +14028,7 @@ arm_validate_fix (fixP)
be resolved before the binbary is emitted, so it is safe to say that
it is adjustable. */
-boolean
+bfd_boolean
arm_fix_adjustable (fixP)
fixS * fixP;
{
@@ -11416,6 +14037,7 @@ arm_fix_adjustable (fixP)
return 0;
}
#endif
+
#ifdef OBJ_ELF
/* Relocations against Thumb function names must be left unadjusted,
so that the linker can use this information to correctly set the
@@ -11430,20 +14052,13 @@ arm_fix_adjustable (fixP)
addresses also ought to have their bottom bit set (assuming that
they reside in Thumb code), but at the moment they will not. */
-boolean
+bfd_boolean
arm_fix_adjustable (fixP)
fixS * fixP;
{
if (fixP->fx_addsy == NULL)
return 1;
- /* Prevent all adjustments to global symbols. */
- if (S_IS_EXTERN (fixP->fx_addsy))
- return 0;
-
- if (S_IS_WEAK (fixP->fx_addsy))
- return 0;
-
if (THUMB_IS_FUNC (fixP->fx_addsy)
&& fixP->fx_subsy == NULL)
return 0;
@@ -11453,6 +14068,12 @@ arm_fix_adjustable (fixP)
|| fixP->fx_r_type == BFD_RELOC_VTABLE_ENTRY)
return 0;
+ /* Don't allow symbols to be discarded on GOT related relocs. */
+ if (fixP->fx_r_type == BFD_RELOC_ARM_PLT32
+ || fixP->fx_r_type == BFD_RELOC_ARM_GOT32
+ || fixP->fx_r_type == BFD_RELOC_ARM_GOTOFF)
+ return 0;
+
return 1;
}
@@ -11483,21 +14104,6 @@ armelf_frob_symbol (symp, puntp)
elf_frob_symbol (symp, puntp);
}
-int
-arm_force_relocation (fixp)
- struct fix * fixp;
-{
- if ( fixp->fx_r_type == BFD_RELOC_VTABLE_INHERIT
- || fixp->fx_r_type == BFD_RELOC_VTABLE_ENTRY
- || fixp->fx_r_type == BFD_RELOC_ARM_PCREL_BRANCH
- || fixp->fx_r_type == BFD_RELOC_ARM_PCREL_BLX
- || fixp->fx_r_type == BFD_RELOC_THUMB_PCREL_BLX
- || fixp->fx_r_type == BFD_RELOC_THUMB_PCREL_BRANCH23)
- return 1;
-
- return 0;
-}
-
static bfd_reloc_code_real_type
arm_parse_reloc ()
{
@@ -11556,6 +14162,7 @@ s_arm_elf_cons (nbytes)
md_cons_align (nbytes);
#endif
+ mapping_state (MAP_DATA);
do
{
bfd_reloc_code_real_type reloc;
@@ -11666,7 +14273,7 @@ arm_frag_align_code (n, max)
{
char * p;
- /* We assume that there will never be a requirment
+ /* We assume that there will never be a requirement
to support alignments greater than 32 bytes. */
if (max > MAX_MEM_FOR_RS_ALIGN_CODE)
as_fatal (_("alignments greater than 32 bytes not supported in .text sections."));
diff --git a/contrib/binutils/gas/config/tc-arm.h b/contrib/binutils/gas/config/tc-arm.h
index 2de9674..4e791a0 100644
--- a/contrib/binutils/gas/config/tc-arm.h
+++ b/contrib/binutils/gas/config/tc-arm.h
@@ -1,5 +1,5 @@
/* This file is tc-arm.h
- Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
+ Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2004
Free Software Foundation, Inc.
Contributed by Richard Earnshaw (rwe@pegasus.esprit.ec.org)
Modified by David Taylor (dtaylor@armltd.co.uk)
@@ -47,64 +47,47 @@
#define LITTLE_ENDIAN 1234
#define BIG_ENDIAN 4321
-#if defined OBJ_AOUT
-#if defined TE_RISCIX
-# define TARGET_FORMAT "a.out-riscix"
-#elif defined TE_LINUX
-# define ARM_BI_ENDIAN
-# define TARGET_FORMAT "a.out-arm-linux"
-#elif defined TE_NetBSD
-# define TARGET_FORMAT "a.out-arm-netbsd"
-#else
-# define ARM_BI_ENDIAN
-# define TARGET_FORMAT \
- (target_big_endian ? "a.out-arm-big" : "a.out-arm-little")
-#endif
-#endif /* OBJ_AOUT */
-
-#ifdef OBJ_AIF
-#define TARGET_FORMAT "aif"
-#endif
+struct fix;
-#if defined OBJ_COFF || defined OBJ_ELF
+#if defined OBJ_AOUT
+# if defined TE_RISCIX
+# define TARGET_FORMAT "a.out-riscix"
+# elif defined TE_LINUX
+# define ARM_BI_ENDIAN
+# define TARGET_FORMAT "a.out-arm-linux"
+# elif defined TE_NetBSD
+# define TARGET_FORMAT "a.out-arm-netbsd"
+# else
+# define ARM_BI_ENDIAN
+# define TARGET_FORMAT (target_big_endian ? "a.out-arm-big" : "a.out-arm-little")
+# endif
+#elif defined OBJ_AIF
+# define TARGET_FORMAT "aif"
+#elif defined OBJ_COFF
# define ARM_BI_ENDIAN
-
-# define TC_VALIDATE_FIX(fixP, segType, Label) \
- if (arm_validate_fix (fixP)) add_symbolP = fixP->fx_addsy
- extern boolean arm_validate_fix PARAMS ((struct fix *));
-#endif
-
-#ifdef OBJ_COFF
# if defined TE_PE
-# define TC_FORCE_RELOCATION(x) ((x)->fx_r_type == BFD_RELOC_RVA)
-# ifdef TE_EPOC
-# define TARGET_FORMAT (target_big_endian ? "epoc-pe-arm-big" : "epoc-pe-arm-little")
-# else
-# define TARGET_FORMAT (target_big_endian ? "pe-arm-big" : "pe-arm-little")
-# endif
+# if defined TE_EPOC
+# define TARGET_FORMAT (target_big_endian ? "epoc-pe-arm-big" : "epoc-pe-arm-little")
+# else
+# define TARGET_FORMAT (target_big_endian ? "pe-arm-big" : "pe-arm-little")
+# endif
# else
# define TARGET_FORMAT (target_big_endian ? "coff-arm-big" : "coff-arm-little")
# endif
+#elif defined OBJ_ELF
+# define ARM_BI_ENDIAN
+# define TARGET_FORMAT elf32_arm_target_format ()
#endif
-#ifdef OBJ_ELF
-# define TARGET_FORMAT elf32_arm_target_format()
- extern const char * elf32_arm_target_format PARAMS ((void));
-
-# define TC_FORCE_RELOCATION(fixp) arm_force_relocation (fixp)
- extern int arm_force_relocation PARAMS ((struct fix *));
-#endif
+#define TC_FORCE_RELOCATION(FIX) arm_force_relocation (FIX)
-#define md_convert_frag(b, s, f) {as_fatal (_("arm convert_frag\n"));}
+#define md_convert_frag(b, s, f) { as_fatal (_("arm convert_frag\n")); }
#define md_cleanup() arm_cleanup ()
- extern void arm_cleanup PARAMS ((void));
#define md_start_line_hook() arm_start_line_hook ()
- extern void arm_start_line_hook PARAMS ((void));
#define tc_frob_label(S) arm_frob_label (S)
- extern void arm_frob_label PARAMS ((symbolS *));
/* We also need to mark assembler created symbols: */
#define tc_frob_fake_label(S) arm_frob_label (S)
@@ -114,29 +97,17 @@
symbols as Thumb. */
#define TC_FIX_TYPE PTR
-#define TC_INIT_FIX_DATA(FIXP) ((FIXP)->tc_fix_data = NULL)
-
-#if defined OBJ_ELF || defined OBJ_COFF
-#include "write.h" /* For definition of fixS */
-#define obj_fix_adjustable(fixP) arm_fix_adjustable (fixP)
-boolean arm_fix_adjustable PARAMS ((fixS *));
-
-/* This arranges for gas/write.c to not apply a relocation if
- obj_fix_adjustable() says it is not adjustable. */
-#define TC_FIX_ADJUSTABLE(fixP) obj_fix_adjustable (fixP)
-#else
-#define obj_fix_adjustable(fixP) 0
-#endif
+#define TC_INIT_FIX_DATA(FIX) ((FIX)->tc_fix_data = NULL)
/* We need to keep some local information on symbols. */
-#define TC_SYMFIELD_TYPE unsigned int
+#define TC_SYMFIELD_TYPE unsigned int
#define ARM_GET_FLAG(s) (*symbol_get_tc (s))
#define ARM_SET_FLAG(s,v) (*symbol_get_tc (s) |= (v))
#define ARM_RESET_FLAG(s,v) (*symbol_get_tc (s) &= ~(v))
#define ARM_FLAG_THUMB (1 << 0) /* The symbol is a Thumb symbol rather than an Arm symbol. */
-#define ARM_FLAG_INTERWORK (1 << 1) /* The symbol is attached to code that suppports interworking. */
+#define ARM_FLAG_INTERWORK (1 << 1) /* The symbol is attached to code that supports interworking. */
#define THUMB_FLAG_FUNC (1 << 2) /* The symbol is attached to the start of a Thumb function. */
#define ARM_IS_THUMB(s) (ARM_GET_FLAG (s) & ARM_FLAG_THUMB)
@@ -147,23 +118,10 @@ boolean arm_fix_adjustable PARAMS ((fixS *));
#define ARM_SET_INTERWORK(s,t) ((t) ? ARM_SET_FLAG (s, ARM_FLAG_INTERWORK) : ARM_RESET_FLAG (s, ARM_FLAG_INTERWORK))
#define THUMB_SET_FUNC(s,t) ((t) ? ARM_SET_FLAG (s, THUMB_FLAG_FUNC) : ARM_RESET_FLAG (s, THUMB_FLAG_FUNC))
-#define TC_START_LABEL(C,STR) \
- (c == ':' || (c == '/' && arm_data_in_code ()))
-int arm_data_in_code PARAMS ((void));
-
-#define tc_canonicalize_symbol_name(str) \
- arm_canonicalize_symbol_name (str);
-char * arm_canonicalize_symbol_name PARAMS ((char *));
-
-#define obj_adjust_symtab() arm_adjust_symtab ()
- extern void arm_adjust_symtab PARAMS ((void));
-
-#ifdef OBJ_ELF
-#define obj_frob_symbol(sym, punt) armelf_frob_symbol ((sym), & (punt))
-void armelf_frob_symbol PARAMS ((symbolS *, int *));
-#endif
-
-#define tc_aout_pre_write_hook(x) {;} /* not used */
+#define TC_START_LABEL(C,STR) (c == ':' || (c == '/' && arm_data_in_code ()))
+#define tc_canonicalize_symbol_name(str) arm_canonicalize_symbol_name (str);
+#define obj_adjust_symtab() arm_adjust_symtab ()
+#define tc_aout_pre_write_hook(x) {;} /* not used */
#define LISTING_HEADER "ARM GAS "
@@ -171,55 +129,32 @@ void armelf_frob_symbol PARAMS ((symbolS *, int *));
#define LOCAL_LABEL(name) (name[0] == '.' && (name[1] == 'L'))
#define LOCAL_LABELS_FB 1
-#ifdef OBJ_ELF
-#define LOCAL_LABEL_PREFIX '.'
-#endif
-/* This expression evaluates to false if the relocation is for a local object
- for which we still want to do the relocation at runtime. True if we
- are willing to perform this relocation while building the .o file.
- This is only used for pcrel relocations, so GOTOFF does not need to be
- checked here. I am not sure if some of the others are ever used with
+/* This expression evaluates to true if the relocation is for a local
+ object for which we still want to do the relocation at runtime.
+ False if we are willing to perform this relocation while building
+ the .o file. GOTOFF does not need to be checked here because it is
+ not pcrel. I am not sure if some of the others are ever used with
pcrel, but it is easier to be safe than sorry. */
-#define TC_RELOC_RTSYM_LOC_FIXUP(FIX) \
- ( (FIX)->fx_r_type != BFD_RELOC_ARM_GOT12 \
- && (FIX)->fx_r_type != BFD_RELOC_ARM_GOT32 \
- && (FIX)->fx_r_type != BFD_RELOC_32)
+#define TC_FORCE_RELOCATION_LOCAL(FIX) \
+ (!(FIX)->fx_pcrel \
+ || (FIX)->fx_plt \
+ || (FIX)->fx_r_type == BFD_RELOC_ARM_GOT12 \
+ || (FIX)->fx_r_type == BFD_RELOC_ARM_GOT32 \
+ || (FIX)->fx_r_type == BFD_RELOC_32 \
+ || TC_FORCE_RELOCATION (FIX))
#define TC_CONS_FIX_NEW cons_fix_new_arm
- extern void cons_fix_new_arm PARAMS ((fragS *, int, int, expressionS *));
-
-/* Don't allow symbols to be discarded on GOT related relocs,
- nor on globals. */
-#define tc_fix_adjustable(x) (\
- ((x)->fx_r_type == BFD_RELOC_ARM_PLT32 \
- || (x)->fx_r_type == BFD_RELOC_ARM_GOT32 \
- || (x)->fx_r_type == BFD_RELOC_ARM_GOTOFF \
- || S_IS_EXTERN ((x)->fx_addsy) \
- || S_IS_WEAK ((x)->fx_addsy)) ? 0 : 1)
-
-#ifdef OBJ_ELF
-#define GLOBAL_OFFSET_TABLE_NAME "_GLOBAL_OFFSET_TABLE_"
-#else
-#define GLOBAL_OFFSET_TABLE_NAME "__GLOBAL_OFFSET_TABLE_"
-#endif
-
-#ifdef OBJ_ELF
-#define DWARF2_LINE_MIN_INSN_LENGTH 2
-#endif
#define MAX_MEM_FOR_RS_ALIGN_CODE 31
/* For frags in code sections we need to record whether they contain
ARM code or THUMB code. This is that if they have to be aligned,
they can contain the correct type of no-op instruction. */
-#define TC_FRAG_TYPE int
+#define TC_FRAG_TYPE int
#define TC_FRAG_INIT(fragp) arm_init_frag (fragp)
-extern void arm_init_frag PARAMS ((struct frag *));
-
-#define HANDLE_ALIGN(fragp) arm_handle_align (fragp)
-extern void arm_handle_align PARAMS ((struct frag *));
+#define HANDLE_ALIGN(fragp) arm_handle_align (fragp)
#define md_do_align(N, FILL, LEN, MAX, LABEL) \
if (FILL == NULL && (N) != 0 && ! need_pass_2 && subseg_text_p (now_seg)) \
@@ -227,4 +162,50 @@ extern void arm_handle_align PARAMS ((struct frag *));
arm_frag_align_code (N, MAX); \
goto LABEL; \
}
-extern void arm_frag_align_code PARAMS ((int, int));
+
+#ifdef OBJ_ELF
+# define DWARF2_LINE_MIN_INSN_LENGTH 2
+# define obj_frob_symbol(sym, punt) armelf_frob_symbol ((sym), & (punt))
+# define md_elf_section_change_hook() arm_elf_change_section ()
+# define GLOBAL_OFFSET_TABLE_NAME "_GLOBAL_OFFSET_TABLE_"
+# define LOCAL_LABEL_PREFIX '.'
+# define TC_SEGMENT_INFO_TYPE enum mstate
+
+enum mstate
+{
+ MAP_UNDEFINED = 0, /* Must be zero, for seginfo in new sections. */
+ MAP_DATA,
+ MAP_ARM,
+ MAP_THUMB
+};
+
+#else /* Not OBJ_ELF. */
+#define GLOBAL_OFFSET_TABLE_NAME "__GLOBAL_OFFSET_TABLE_"
+#endif
+
+#if defined OBJ_ELF || defined OBJ_COFF
+
+# define EXTERN_FORCE_RELOC 1
+# define tc_fix_adjustable(FIX) arm_fix_adjustable (FIX)
+/* Values passed to md_apply_fix3 don't include the symbol value. */
+# define MD_APPLY_SYM_VALUE(FIX) 0
+# define TC_VALIDATE_FIX(FIX, SEGTYPE, LABEL) arm_validate_fix (FIX)
+
+#endif
+
+extern void arm_frag_align_code (int, int);
+extern void arm_validate_fix (struct fix *);
+extern const char * elf32_arm_target_format (void);
+extern void arm_elf_change_section (void);
+extern int arm_force_relocation (struct fix *);
+extern void arm_cleanup (void);
+extern void arm_start_line_hook (void);
+extern void arm_frob_label (symbolS *);
+extern int arm_data_in_code (void);
+extern char * arm_canonicalize_symbol_name (char *);
+extern void arm_adjust_symtab (void);
+extern void armelf_frob_symbol (symbolS *, int *);
+extern void cons_fix_new_arm (fragS *, int, int, expressionS *);
+extern void arm_init_frag (struct frag *);
+extern void arm_handle_align (struct frag *);
+extern bfd_boolean arm_fix_adjustable (struct fix *);
diff --git a/contrib/binutils/gas/config/tc-ia64.c b/contrib/binutils/gas/config/tc-ia64.c
index a634d80..f5526c9 100644
--- a/contrib/binutils/gas/config/tc-ia64.c
+++ b/contrib/binutils/gas/config/tc-ia64.c
@@ -1,5 +1,5 @@
/* tc-ia64.c -- Assembler for the HP/Intel IA-64 architecture.
- Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
Contributed by David Mosberger-Tang <davidm@hpl.hp.com>
This file is part of GAS, the GNU Assembler.
@@ -24,7 +24,6 @@
- optional operands
- directives:
- .alias
.eb
.estate
.lb
@@ -82,6 +81,7 @@ enum reloc_func
FUNC_FPTR_RELATIVE,
FUNC_GP_RELATIVE,
FUNC_LT_RELATIVE,
+ FUNC_LT_RELATIVE_X,
FUNC_PC_RELATIVE,
FUNC_PLT_RELATIVE,
FUNC_SEC_RELATIVE,
@@ -155,6 +155,20 @@ struct label_fix
extern int target_big_endian;
+void (*ia64_number_to_chars) PARAMS ((char *, valueT, int));
+
+static void ia64_float_to_chars_bigendian
+ PARAMS ((char *, LITTLENUM_TYPE *, int));
+static void ia64_float_to_chars_littleendian
+ PARAMS ((char *, LITTLENUM_TYPE *, int));
+static void (*ia64_float_to_chars)
+ PARAMS ((char *, LITTLENUM_TYPE *, int));
+
+static struct hash_control *alias_hash;
+static struct hash_control *alias_name_hash;
+static struct hash_control *secalias_hash;
+static struct hash_control *secalias_name_hash;
+
/* Characters which always start a comment. */
const char comment_chars[] = "";
@@ -487,6 +501,7 @@ pseudo_func[] =
{ "fptr", PSEUDO_FUNC_RELOC, { 0 } },
{ "gprel", PSEUDO_FUNC_RELOC, { 0 } },
{ "ltoff", PSEUDO_FUNC_RELOC, { 0 } },
+ { "ltoffx", PSEUDO_FUNC_RELOC, { 0 } },
{ "pcrel", PSEUDO_FUNC_RELOC, { 0 } },
{ "pltoff", PSEUDO_FUNC_RELOC, { 0 } },
{ "secrel", PSEUDO_FUNC_RELOC, { 0 } },
@@ -519,10 +534,17 @@ pseudo_func[] =
{ "natval", PSEUDO_FUNC_CONST, { 0x100 } }, /* old usage */
+ /* hint constants: */
+ { "pause", PSEUDO_FUNC_CONST, { 0x0 } },
+
/* unwind-related constants: */
- { "svr4", PSEUDO_FUNC_CONST, { 0 } },
- { "hpux", PSEUDO_FUNC_CONST, { 1 } },
- { "nt", PSEUDO_FUNC_CONST, { 2 } },
+ { "svr4", PSEUDO_FUNC_CONST, { ELFOSABI_NONE } },
+ { "hpux", PSEUDO_FUNC_CONST, { ELFOSABI_HPUX } },
+ { "nt", PSEUDO_FUNC_CONST, { 2 } }, /* conflicts w/ELFOSABI_NETBSD */
+ { "linux", PSEUDO_FUNC_CONST, { ELFOSABI_LINUX } },
+ { "freebsd", PSEUDO_FUNC_CONST, { ELFOSABI_FREEBSD } },
+ { "openvms", PSEUDO_FUNC_CONST, { ELFOSABI_OPENVMS } },
+ { "nsk", PSEUDO_FUNC_CONST, { ELFOSABI_NSK } },
/* unwind-related registers: */
{ "priunat",PSEUDO_FUNC_REG, { REG_PRIUNAT } }
@@ -614,6 +636,9 @@ static struct gr {
valueT value;
} gr_values[128] = {{ 1, 0, 0 }};
+/* Remember the alignment frag. */
+static fragS *align_frag;
+
/* These are the routines required to output the various types of
unwind records. */
@@ -630,6 +655,8 @@ typedef struct unw_rec_list {
unwind_record r;
unsigned long slot_number;
fragS *slot_frag;
+ unsigned long next_slot_number;
+ fragS *next_slot_frag;
struct unw_rec_list *next;
} unw_rec_list;
@@ -646,9 +673,6 @@ typedef struct label_prologue_count
static struct
{
- unsigned long next_slot_number;
- fragS *next_slot_frag;
-
/* Maintain a list of unwind entries for the current function. */
unw_rec_list *list;
unw_rec_list *tail;
@@ -676,11 +700,12 @@ static struct
typedef void (*vbyte_func) PARAMS ((int, char *, char *));
-/* Forward delarations: */
+/* Forward declarations: */
static int ar_is_in_integer_unit PARAMS ((int regnum));
static void set_section PARAMS ((char *name));
static unsigned int set_regstack PARAMS ((unsigned int, unsigned int,
unsigned int, unsigned int));
+static void dot_align (int);
static void dot_radix PARAMS ((int));
static void dot_special_section PARAMS ((int));
static void dot_proc PARAMS ((int));
@@ -801,7 +826,7 @@ static void output_X2_format PARAMS ((vbyte_func, int, int, int, int, int, unsig
static void output_X3_format PARAMS ((vbyte_func, unw_record_type, int, int, int, unsigned long,
unsigned long));
static void output_X4_format PARAMS ((vbyte_func, int, int, int, int, int, int, unsigned long));
-static void free_list_records PARAMS ((unw_rec_list *));
+static unw_rec_list *output_endp PARAMS ((void));
static unw_rec_list *output_prologue PARAMS ((void));
static unw_rec_list *output_prologue_gr PARAMS ((unsigned int, unsigned int));
static unw_rec_list *output_body PARAMS ((void));
@@ -876,15 +901,14 @@ static void process_one_record PARAMS ((unw_rec_list *, vbyte_func));
static void process_unw_records PARAMS ((unw_rec_list *, vbyte_func));
static int calc_record_size PARAMS ((unw_rec_list *));
static void set_imask PARAMS ((unw_rec_list *, unsigned long, unsigned long, unsigned int));
-static int count_bits PARAMS ((unsigned long));
static unsigned long slot_index PARAMS ((unsigned long, fragS *,
- unsigned long, fragS *));
+ unsigned long, fragS *,
+ int));
static unw_rec_list *optimize_unw_records PARAMS ((unw_rec_list *));
-static void fixup_unw_records PARAMS ((unw_rec_list *));
-static int output_unw_records PARAMS ((unw_rec_list *, void **));
+static void fixup_unw_records PARAMS ((unw_rec_list *, int));
static int convert_expr_to_ab_reg PARAMS ((expressionS *, unsigned int *, unsigned int *));
static int convert_expr_to_xy_reg PARAMS ((expressionS *, unsigned int *, unsigned int *));
-static int generate_unwind_image PARAMS ((const char *));
+static void generate_unwind_image PARAMS ((const char *));
static unsigned int get_saved_prologue_count PARAMS ((unsigned long));
static void save_prologue_count PARAMS ((unsigned long, unsigned int));
static void free_saved_prologue_counts PARAMS ((void));
@@ -954,9 +978,11 @@ ia64_elf_section_letter (letter, ptr_msg)
{
if (letter == 's')
return SHF_IA_64_SHORT;
+ else if (letter == 'o')
+ return SHF_LINK_ORDER;
- *ptr_msg = _("Bad .section directive: want a,s,w,x,M,S,G,T in string");
- return 0;
+ *ptr_msg = _("Bad .section directive: want a,o,s,w,x,M,S,G,T in string");
+ return -1;
}
/* Map SHF_IA_64_SHORT to SEC_SMALL_DATA. */
@@ -990,6 +1016,9 @@ ia64_elf_section_type (str, len)
if (STREQ (ELF_STRING_ia64_unwind_once))
return SHT_IA_64_UNWIND;
+ if (STREQ ("unwind"))
+ return SHT_IA_64_UNWIND;
+
if (STREQ ("init_array"))
return SHT_INIT_ARRAY;
@@ -1064,18 +1093,40 @@ ia64_flush_insns ()
CURR_SLOT.tag_fixups = 0;
/* In case there are unwind directives following the last instruction,
- resolve those now. We only handle body and prologue directives here.
- Give an error for others. */
+ resolve those now. We only handle prologue, body, and endp directives
+ here. Give an error for others. */
for (ptr = unwind.current_entry; ptr; ptr = ptr->next)
{
- if (ptr->r.type == prologue || ptr->r.type == prologue_gr
- || ptr->r.type == body)
+ switch (ptr->r.type)
{
+ case prologue:
+ case prologue_gr:
+ case body:
+ case endp:
ptr->slot_number = (unsigned long) frag_more (0);
ptr->slot_frag = frag_now;
+ break;
+
+ /* Allow any record which doesn't have a "t" field (i.e.,
+ doesn't relate to a particular instruction). */
+ case unwabi:
+ case br_gr:
+ case copy_state:
+ case fr_mem:
+ case frgr_mem:
+ case gr_gr:
+ case gr_mem:
+ case label_state:
+ case rp_br:
+ case spill_base:
+ case spill_mask:
+ /* nothing */
+ break;
+
+ default:
+ as_bad (_("Unwind directive not followed by an instruction."));
+ break;
}
- else
- as_bad (_("Unwind directive not followed by an instruction."));
}
unwind.current_entry = NULL;
@@ -1085,9 +1136,8 @@ ia64_flush_insns ()
as_bad ("qualifying predicate not followed by instruction");
}
-void
-ia64_do_align (nbytes)
- int nbytes;
+static void
+ia64_do_align (int nbytes)
{
char *saved_input_line_pointer = input_line_pointer;
@@ -1683,26 +1733,19 @@ alloc_record (unw_record_type t)
ptr->next = NULL;
ptr->slot_number = SLOT_NUM_NOT_SET;
ptr->r.type = t;
+ ptr->next_slot_number = 0;
+ ptr->next_slot_frag = 0;
return ptr;
}
-/* This function frees an entire list of record structures. */
+/* Dummy unwind record used for calculating the length of the last prologue or
+ body region. */
-void
-free_list_records (unw_rec_list *first)
+static unw_rec_list *
+output_endp ()
{
- unw_rec_list *ptr;
- for (ptr = first; ptr != NULL;)
- {
- unw_rec_list *tmp = ptr;
-
- if ((tmp->r.type == prologue || tmp->r.type == prologue_gr)
- && tmp->r.record.r.mask.i)
- free (tmp->r.record.r.mask.i);
-
- ptr = ptr->next;
- free (tmp);
- }
+ unw_rec_list *ptr = alloc_record (endp);
+ return ptr;
}
static unw_rec_list *
@@ -2325,6 +2368,10 @@ process_one_record (ptr, f)
switch (ptr->r.type)
{
+ /* This is a dummy record that takes up no space in the output. */
+ case endp:
+ break;
+
case gr_mem:
case fr_mem:
case br_mem:
@@ -2567,29 +2614,18 @@ set_imask (region, regmask, t, type)
}
}
-static int
-count_bits (unsigned long mask)
-{
- int n = 0;
-
- while (mask)
- {
- mask &= mask - 1;
- ++n;
- }
- return n;
-}
-
/* Return the number of instruction slots from FIRST_ADDR to SLOT_ADDR.
SLOT_FRAG is the frag containing SLOT_ADDR, and FIRST_FRAG is the frag
- containing FIRST_ADDR. */
+ containing FIRST_ADDR. If BEFORE_RELAX, then we use worst-case estimates
+ for frag sizes. */
unsigned long
-slot_index (slot_addr, slot_frag, first_addr, first_frag)
+slot_index (slot_addr, slot_frag, first_addr, first_frag, before_relax)
unsigned long slot_addr;
fragS *slot_frag;
unsigned long first_addr;
fragS *first_frag;
+ int before_relax;
{
unsigned long index = 0;
@@ -2604,6 +2640,46 @@ slot_index (slot_addr, slot_frag, first_addr, first_frag)
{
unsigned long start_addr = (unsigned long) &first_frag->fr_literal;
+ if (! before_relax)
+ {
+ /* We can get the final addresses only during and after
+ relaxation. */
+ if (first_frag->fr_next && first_frag->fr_next->fr_address)
+ index += 3 * ((first_frag->fr_next->fr_address
+ - first_frag->fr_address
+ - first_frag->fr_fix) >> 4);
+ }
+ else
+ /* We don't know what the final addresses will be. We try our
+ best to estimate. */
+ switch (first_frag->fr_type)
+ {
+ default:
+ break;
+
+ case rs_space:
+ as_fatal ("only constant space allocation is supported");
+ break;
+
+ case rs_align:
+ case rs_align_code:
+ case rs_align_test:
+ /* Take alignment into account. Assume the worst case
+ before relaxation. */
+ index += 3 * ((1 << first_frag->fr_offset) >> 4);
+ break;
+
+ case rs_org:
+ if (first_frag->fr_symbol)
+ {
+ as_fatal ("only constant offsets are supported");
+ break;
+ }
+ case rs_fill:
+ index += 3 * (first_frag->fr_offset >> 4);
+ break;
+ }
+
/* Add in the full size of the frag converted to instruction slots. */
index += 3 * (first_frag->fr_fix >> 4);
/* Subtract away the initial part before first_addr. */
@@ -2633,8 +2709,8 @@ optimize_unw_records (list)
/* If the only unwind record is ".prologue" or ".prologue" followed
by ".body", then we can optimize the unwind directives away. */
if (list->r.type == prologue
- && (list->next == NULL
- || (list->next->r.type == body && list->next->next == NULL)))
+ && (list->next->r.type == endp
+ || (list->next->r.type == body && list->next->next->r.type == endp)))
return NULL;
return list;
@@ -2642,12 +2718,13 @@ optimize_unw_records (list)
/* Given a complete record list, process any records which have
unresolved fields, (ie length counts for a prologue). After
- this has been run, all neccessary information should be available
+ this has been run, all necessary information should be available
within each record to generate an image. */
static void
-fixup_unw_records (list)
+fixup_unw_records (list, before_relax)
unw_rec_list *list;
+ int before_relax;
{
unw_rec_list *ptr, *region = 0;
unsigned long first_addr = 0, rlen = 0, t;
@@ -2658,7 +2735,7 @@ fixup_unw_records (list)
if (ptr->slot_number == SLOT_NUM_NOT_SET)
as_bad (" Insn slot not set in unwind record.");
t = slot_index (ptr->slot_number, ptr->slot_frag,
- first_addr, first_frag);
+ first_addr, first_frag, before_relax);
switch (ptr->r.type)
{
case prologue:
@@ -2666,60 +2743,24 @@ fixup_unw_records (list)
case body:
{
unw_rec_list *last;
- int size, dir_len = 0;
- unsigned long last_addr;
- fragS *last_frag;
+ int size;
+ unsigned long last_addr = 0;
+ fragS *last_frag = NULL;
first_addr = ptr->slot_number;
first_frag = ptr->slot_frag;
- ptr->slot_number = 0;
/* Find either the next body/prologue start, or the end of
- the list, and determine the size of the region. */
- last_addr = unwind.next_slot_number;
- last_frag = unwind.next_slot_frag;
+ the function, and determine the size of the region. */
for (last = ptr->next; last != NULL; last = last->next)
if (last->r.type == prologue || last->r.type == prologue_gr
- || last->r.type == body)
+ || last->r.type == body || last->r.type == endp)
{
last_addr = last->slot_number;
last_frag = last->slot_frag;
break;
}
- else if (!last->next)
- {
- /* In the absence of an explicit .body directive,
- the prologue ends after the last instruction
- covered by an unwind directive. */
- if (ptr->r.type != body)
- {
- last_addr = last->slot_number;
- last_frag = last->slot_frag;
- switch (last->r.type)
- {
- case frgr_mem:
- dir_len = (count_bits (last->r.record.p.frmask)
- + count_bits (last->r.record.p.grmask));
- break;
- case fr_mem:
- case gr_mem:
- dir_len += count_bits (last->r.record.p.rmask);
- break;
- case br_mem:
- case br_gr:
- dir_len += count_bits (last->r.record.p.brmask);
- break;
- case gr_gr:
- dir_len += count_bits (last->r.record.p.grmask);
- break;
- default:
- dir_len = 1;
- break;
- }
- }
- break;
- }
- size = (slot_index (last_addr, last_frag, first_addr, first_frag)
- + dir_len);
+ size = slot_index (last_addr, last_frag, first_addr, first_frag,
+ before_relax);
rlen = ptr->r.record.r.rlen = size;
if (ptr->r.type == body)
/* End of region. */
@@ -2819,29 +2860,63 @@ fixup_unw_records (list)
}
}
-/* Helper routine for output_unw_records. Emits the header for the unwind
- info. */
+/* Estimate the size of a frag before relaxing. We only have one type of frag
+ to handle here, which is the unwind info frag. */
-static int
-setup_unwind_header (int size, unsigned char **mem)
+int
+ia64_estimate_size_before_relax (fragS *frag,
+ asection *segtype ATTRIBUTE_UNUSED)
+{
+ unw_rec_list *list;
+ int len, size, pad;
+
+ /* ??? This code is identical to the first part of ia64_convert_frag. */
+ list = (unw_rec_list *) frag->fr_opcode;
+ fixup_unw_records (list, 0);
+
+ len = calc_record_size (list);
+ /* pad to pointer-size boundary. */
+ pad = len % md.pointer_size;
+ if (pad != 0)
+ len += md.pointer_size - pad;
+ /* Add 8 for the header + a pointer for the personality offset. */
+ size = len + 8 + md.pointer_size;
+
+ /* fr_var carries the max_chars that we created the fragment with.
+ We must, of course, have allocated enough memory earlier. */
+ assert (frag->fr_var >= size);
+
+ return frag->fr_fix + size;
+}
+
+/* This function converts a rs_machine_dependent variant frag into a
+ normal fill frag with the unwind image from the the record list. */
+void
+ia64_convert_frag (fragS *frag)
{
- int x, extra = 0;
+ unw_rec_list *list;
+ int len, size, pad;
valueT flag_value;
- /* pad to pointer-size boundry. */
- x = size % md.pointer_size;
- if (x != 0)
- extra = md.pointer_size - x;
+ /* ??? This code is identical to ia64_estimate_size_before_relax. */
+ list = (unw_rec_list *) frag->fr_opcode;
+ fixup_unw_records (list, 0);
- /* Add 8 for the header + a pointer for the
- personality offset. */
- *mem = xmalloc (size + extra + 8 + md.pointer_size);
+ len = calc_record_size (list);
+ /* pad to pointer-size boundary. */
+ pad = len % md.pointer_size;
+ if (pad != 0)
+ len += md.pointer_size - pad;
+ /* Add 8 for the header + a pointer for the personality offset. */
+ size = len + 8 + md.pointer_size;
- /* Clear the padding area and personality. */
- memset (*mem + 8 + size, 0, extra + md.pointer_size);
+ /* fr_var carries the max_chars that we created the fragment with.
+ We must, of course, have allocated enough memory earlier. */
+ assert (frag->fr_var >= size);
- /* Initialize the header area. */
- if (unwind.personality_routine)
+ /* Initialize the header area. fr_offset is initialized with
+ unwind.personality_routine. */
+ if (frag->fr_offset)
{
if (md.flags & EF_IA_64_ABI64)
flag_value = (bfd_vma) 3 << 32;
@@ -2852,44 +2927,25 @@ setup_unwind_header (int size, unsigned char **mem)
else
flag_value = 0;
- md_number_to_chars (*mem, (((bfd_vma) 1 << 48) /* Version. */
- | flag_value /* U & E handler flags. */
- | ((size + extra) / md.pointer_size)), /* Length. */
- 8);
-
- return extra;
-}
-
-/* Generate an unwind image from a record list. Returns the number of
- bytes in the resulting image. The memory image itselof is returned
- in the 'ptr' parameter. */
-static int
-output_unw_records (list, ptr)
- unw_rec_list *list;
- void **ptr;
-{
- int size, extra;
- unsigned char *mem;
-
- *ptr = NULL;
-
- list = optimize_unw_records (list);
- fixup_unw_records (list);
- size = calc_record_size (list);
-
- if (size > 0 || unwind.force_unwind_entry)
- {
- unwind.force_unwind_entry = 0;
- extra = setup_unwind_header (size, &mem);
+ md_number_to_chars (frag->fr_literal,
+ (((bfd_vma) 1 << 48) /* Version. */
+ | flag_value /* U & E handler flags. */
+ | (len / md.pointer_size)), /* Length. */
+ 8);
- vbyte_mem_ptr = mem + 8;
- process_unw_records (list, output_vbyte_mem);
+ /* Skip the header. */
+ vbyte_mem_ptr = frag->fr_literal + 8;
+ process_unw_records (list, output_vbyte_mem);
- *ptr = mem;
+ /* Fill the padding bytes with zeros. */
+ if (pad != 0)
+ md_number_to_chars (frag->fr_literal + len + 8 - md.pointer_size + pad, 0,
+ md.pointer_size - pad);
- size += extra + 8 + md.pointer_size;
- }
- return size;
+ frag->fr_fix += size;
+ frag->fr_type = rs_fill;
+ frag->fr_var = 0;
+ frag->fr_offset = 0;
}
static int
@@ -2978,6 +3034,14 @@ convert_expr_to_xy_reg (e, xy, regp)
}
static void
+dot_align (int arg)
+{
+ /* The current frag is an alignment frag. */
+ align_frag = frag_now;
+ s_align_bytes (arg);
+}
+
+static void
dot_radix (dummy)
int dummy ATTRIBUTE_UNUSED;
{
@@ -3063,7 +3127,7 @@ dot_vframesp (dummy)
add_unwind_entry (output_psp_sprel (e.X_add_number));
}
else
- as_bad ("First operand to .vframesp must be a general register");
+ as_bad ("Operand to .vframesp must be a constant (sp-relative offset)");
}
static void
@@ -3079,7 +3143,7 @@ dot_vframepsp (dummy)
add_unwind_entry (output_psp_sprel (e.X_add_number));
}
else
- as_bad ("First operand to .vframepsp must be a general register");
+ as_bad ("Operand to .vframepsp must be a constant (psp-relative offset)");
}
static void
@@ -3251,26 +3315,41 @@ dot_restorereg_p (dummy)
add_unwind_entry (output_spill_reg_p (ab, reg, 0, 0, qp));
}
-static int
+static void
generate_unwind_image (text_name)
const char *text_name;
{
- int size;
- unsigned char *unw_rec;
+ int size, pad;
+ unw_rec_list *list;
+
+ /* Mark the end of the unwind info, so that we can compute the size of the
+ last unwind region. */
+ add_unwind_entry (output_endp ());
/* Force out pending instructions, to make sure all unwind records have
a valid slot_number field. */
ia64_flush_insns ();
/* Generate the unwind record. */
- size = output_unw_records (unwind.list, (void **) &unw_rec);
- if (size % md.pointer_size != 0)
- as_bad ("Unwind record is not a multiple of %d bytes.", md.pointer_size);
+ list = optimize_unw_records (unwind.list);
+ fixup_unw_records (list, 1);
+ size = calc_record_size (list);
+
+ if (size > 0 || unwind.force_unwind_entry)
+ {
+ unwind.force_unwind_entry = 0;
+ /* pad to pointer-size boundary. */
+ pad = size % md.pointer_size;
+ if (pad != 0)
+ size += md.pointer_size - pad;
+ /* Add 8 for the header + a pointer for the personality
+ offset. */
+ size += 8 + md.pointer_size;
+ }
/* If there are unwind records, switch sections, and output the info. */
if (size != 0)
{
- unsigned char *where;
char *sec_name;
expressionS exp;
bfd_reloc_code_real_type reloc;
@@ -3287,15 +3366,9 @@ generate_unwind_image (text_name)
/* Set expression which points to start of unwind descriptor area. */
unwind.info = expr_build_dot ();
-
- where = (unsigned char *) frag_more (size);
-
- /* Issue a label for this address, and keep track of it to put it
- in the unwind section. */
-
- /* Copy the information from the unwind record into this section. The
- data is already in the correct byte order. */
- memcpy (where, unw_rec, size);
+
+ frag_var (rs_machine_dependent, size, size, 0, 0,
+ (offsetT) unwind.personality_routine, (char *) list);
/* Add the personality address to the image. */
if (unwind.personality_routine != 0)
@@ -3325,11 +3398,8 @@ generate_unwind_image (text_name)
}
}
- free_list_records (unwind.list);
free_saved_prologue_counts ();
unwind.list = unwind.tail = unwind.current_entry = NULL;
-
- return size;
}
static void
@@ -3547,7 +3617,7 @@ dot_saveb (dummy)
add_unwind_entry (output_br_mem (brmask));
if (!is_end_of_line[sep] && !is_it_end_of_statement ())
- ignore_rest_of_line ();
+ demand_empty_rest_of_line ();
}
static void
@@ -3579,7 +3649,7 @@ dot_spill (dummy)
sep = parse_operand (&e);
if (!is_end_of_line[sep] && !is_it_end_of_statement ())
- ignore_rest_of_line ();
+ demand_empty_rest_of_line ();
if (e.X_op != O_constant)
as_bad ("Operand to .spill must be a constant");
@@ -3855,7 +3925,7 @@ dot_unwabi (dummy)
}
sep = parse_operand (&e2);
if (!is_end_of_line[sep] && !is_it_end_of_statement ())
- ignore_rest_of_line ();
+ demand_empty_rest_of_line ();
if (e1.X_op != O_constant)
{
@@ -3950,7 +4020,7 @@ dot_prologue (dummy)
as_bad ("No second operand to .prologue");
sep = parse_operand (&e2);
if (!is_end_of_line[sep] && !is_it_end_of_statement ())
- ignore_rest_of_line ();
+ demand_empty_rest_of_line ();
if (e1.X_op == O_constant)
{
@@ -4303,7 +4373,32 @@ static void
dot_byteorder (byteorder)
int byteorder;
{
- target_big_endian = byteorder;
+ segment_info_type *seginfo = seg_info (now_seg);
+
+ if (byteorder == -1)
+ {
+ if (seginfo->tc_segment_info_data.endian == 0)
+ seginfo->tc_segment_info_data.endian
+ = TARGET_BYTES_BIG_ENDIAN ? 1 : 2;
+ byteorder = seginfo->tc_segment_info_data.endian == 1;
+ }
+ else
+ seginfo->tc_segment_info_data.endian = byteorder ? 1 : 2;
+
+ if (target_big_endian != byteorder)
+ {
+ target_big_endian = byteorder;
+ if (target_big_endian)
+ {
+ ia64_number_to_chars = number_to_chars_bigendian;
+ ia64_float_to_chars = ia64_float_to_chars_bigendian;
+ }
+ else
+ {
+ ia64_number_to_chars = number_to_chars_littleendian;
+ ia64_float_to_chars = ia64_float_to_chars_littleendian;
+ }
+ }
}
static void
@@ -4340,13 +4435,6 @@ dot_psr (dummy)
}
static void
-dot_alias (dummy)
- int dummy ATTRIBUTE_UNUSED;
-{
- as_bad (".alias not implemented yet");
-}
-
-static void
dot_ln (dummy)
int dummy ATTRIBUTE_UNUSED;
{
@@ -4405,19 +4493,25 @@ static void
stmt_float_cons (kind)
int kind;
{
- size_t size;
+ size_t alignment;
switch (kind)
{
- case 'd': size = 8; break;
- case 'x': size = 10; break;
+ case 'd':
+ alignment = 8;
+ break;
+
+ case 'x':
+ case 'X':
+ alignment = 16;
+ break;
case 'f':
default:
- size = 4;
+ alignment = 4;
break;
}
- ia64_do_align (size);
+ ia64_do_align (alignment);
float_cons (kind);
}
@@ -4827,8 +4921,6 @@ const pseudo_typeS md_pseudo_table[] =
{ "body", dot_body, 0 },
{ "prologue", dot_prologue, 0 },
{ "endp", dot_endp, 0 },
- { "file", (void (*) PARAMS ((int))) dwarf2_directive_file, 0 },
- { "loc", dwarf2_directive_loc, 0 },
{ "fframe", dot_fframe, 0 },
{ "vframe", dot_vframe, 0 },
@@ -4876,7 +4968,7 @@ const pseudo_typeS md_pseudo_table[] =
{ "lb", dot_scope, 0 },
{ "le", dot_scope, 1 },
#endif
- { "align", s_align_bytes, 0 },
+ { "align", dot_align, 0 },
{ "regstk", dot_regstk, 0 },
{ "rotr", dot_rot, DYNREG_GR },
{ "rotf", dot_rot, DYNREG_FR },
@@ -4885,6 +4977,7 @@ const pseudo_typeS md_pseudo_table[] =
{ "msb", dot_byteorder, 1 },
{ "psr", dot_psr, 0 },
{ "alias", dot_alias, 0 },
+ { "secalias", dot_alias, 1 },
{ "ln", dot_ln, 0 }, /* source line info (for debugging) */
{ "xdata1", dot_xdata, 1 },
@@ -4894,6 +4987,7 @@ const pseudo_typeS md_pseudo_table[] =
{ "xreal4", dot_xfloat_cons, 'f' },
{ "xreal8", dot_xfloat_cons, 'd' },
{ "xreal10", dot_xfloat_cons, 'x' },
+ { "xreal16", dot_xfloat_cons, 'X' },
{ "xstring", dot_xstringer, 0 },
{ "xstringz", dot_xstringer, 1 },
@@ -4904,6 +4998,7 @@ const pseudo_typeS md_pseudo_table[] =
{ "xreal4.ua", dot_xfloat_cons_ua, 'f' },
{ "xreal8.ua", dot_xfloat_cons_ua, 'd' },
{ "xreal10.ua", dot_xfloat_cons_ua, 'x' },
+ { "xreal16.ua", dot_xfloat_cons_ua, 'X' },
/* annotations/DV checking support */
{ "entry", dot_entry, 0 },
@@ -4947,6 +5042,7 @@ pseudo_opcode[] =
{ "real4", stmt_float_cons, 'f' },
{ "real8", stmt_float_cons, 'd' },
{ "real10", stmt_float_cons, 'x' },
+ { "real16", stmt_float_cons, 'X' },
{ "string", stringer, 0 },
{ "stringz", stringer, 1 },
@@ -4958,6 +5054,7 @@ pseudo_opcode[] =
{ "real4.ua", float_cons, 'f' },
{ "real8.ua", float_cons, 'd' },
{ "real10.ua", float_cons, 'x' },
+ { "real16.ua", float_cons, 'X' },
};
/* Declare a register by creating a symbol for it and entering it in
@@ -5032,6 +5129,11 @@ operand_match (idesc, index, e)
return OPERAND_MATCH;
break;
+ case IA64_OPND_AR_CSD:
+ if (e->X_op == O_register && e->X_add_number == REG_AR + 25)
+ return OPERAND_MATCH;
+ break;
+
case IA64_OPND_AR_PFS:
if (e->X_op == O_register && e->X_add_number == REG_AR + 64)
return OPERAND_MATCH;
@@ -5523,6 +5625,15 @@ operand_match (idesc, index, e)
}
break;
+ case IA64_OPND_LDXMOV:
+ fix = CURR_SLOT.fixup + CURR_SLOT.num_fixups;
+ fix->code = BFD_RELOC_IA64_LDXMOV;
+ fix->opnd = idesc->operands[index];
+ fix->expr = *e;
+ fix->is_pcrel = 0;
+ ++CURR_SLOT.num_fixups;
+ return OPERAND_MATCH;
+
default:
break;
}
@@ -5964,7 +6075,7 @@ emit_one_bundle ()
struct ia64_opcode *idesc;
int end_of_insn_group = 0, user_template = -1;
int n, i, j, first, curr;
- unw_rec_list *ptr;
+ unw_rec_list *ptr, *last_ptr, *end_ptr;
bfd_vma t0 = 0, t1 = 0;
struct label_fix *lfix;
struct insn_fix *ifix;
@@ -6008,18 +6119,39 @@ emit_one_bundle ()
end_of_insn_group = 0;
for (i = 0; i < 3 && md.num_slots_in_use > 0; ++i)
{
- /* Set the slot number for prologue/body records now as those
- refer to the current point, not the point after the
- instruction has been issued: */
- /* Don't try to delete prologue/body records here, as that will cause
- them to also be deleted from the master list of unwind records. */
- for (ptr = md.slot[curr].unwind_record; ptr; ptr = ptr->next)
- if (ptr->r.type == prologue || ptr->r.type == prologue_gr
- || ptr->r.type == body)
- {
- ptr->slot_number = (unsigned long) f + i;
- ptr->slot_frag = frag_now;
- }
+ /* If we have unwind records, we may need to update some now. */
+ ptr = md.slot[curr].unwind_record;
+ if (ptr)
+ {
+ /* Find the last prologue/body record in the list for the current
+ insn, and set the slot number for all records up to that point.
+ This needs to be done now, because prologue/body records refer to
+ the current point, not the point after the instruction has been
+ issued. This matters because there may have been nops emitted
+ meanwhile. Any non-prologue non-body record followed by a
+ prologue/body record must also refer to the current point. */
+ last_ptr = NULL;
+ end_ptr = md.slot[(curr + 1) % NUM_SLOTS].unwind_record;
+ for (; ptr != end_ptr; ptr = ptr->next)
+ if (ptr->r.type == prologue || ptr->r.type == prologue_gr
+ || ptr->r.type == body)
+ last_ptr = ptr;
+ if (last_ptr)
+ {
+ /* Make last_ptr point one after the last prologue/body
+ record. */
+ last_ptr = last_ptr->next;
+ for (ptr = md.slot[curr].unwind_record; ptr != last_ptr;
+ ptr = ptr->next)
+ {
+ ptr->slot_number = (unsigned long) f + i;
+ ptr->slot_frag = frag_now;
+ }
+ /* Remove the initialized records, so that we won't accidentally
+ update them again if we insert a nop and continue. */
+ md.slot[curr].unwind_record = last_ptr;
+ }
+ }
if (idesc->flags & IA64_OPCODE_SLOT2)
{
@@ -6147,10 +6279,11 @@ emit_one_bundle ()
}
required_unit = ia64_templ_desc[template].exec_unit[i];
- /* resolve dynamic opcodes such as "break" and "nop": */
+ /* resolve dynamic opcodes such as "break", "hint", and "nop": */
if (idesc->type == IA64_TYPE_DYN)
{
if ((strcmp (idesc->name, "nop") == 0)
+ || (strcmp (idesc->name, "hint") == 0)
|| (strcmp (idesc->name, "break") == 0))
insn_unit = required_unit;
else if (strcmp (idesc->name, "chk.s") == 0)
@@ -6223,15 +6356,20 @@ emit_one_bundle ()
build_insn (md.slot + curr, insn + i);
- /* Set slot counts for non prologue/body unwind records. */
- for (ptr = md.slot[curr].unwind_record; ptr; ptr = ptr->next)
- if (ptr->r.type != prologue && ptr->r.type != prologue_gr
- && ptr->r.type != body)
- {
- ptr->slot_number = (unsigned long) f + i;
- ptr->slot_frag = frag_now;
- }
- md.slot[curr].unwind_record = NULL;
+ ptr = md.slot[curr].unwind_record;
+ if (ptr)
+ {
+ /* Set slot numbers for all remaining unwind records belonging to the
+ current insn. There can not be any prologue/body unwind records
+ here. */
+ end_ptr = md.slot[(curr + 1) % NUM_SLOTS].unwind_record;
+ for (; ptr != end_ptr; ptr = ptr->next)
+ {
+ ptr->slot_number = (unsigned long) f + i;
+ ptr->slot_frag = frag_now;
+ }
+ md.slot[curr].unwind_record = NULL;
+ }
if (required_unit == IA64_UNIT_L)
{
@@ -6304,8 +6442,11 @@ emit_one_bundle ()
number_to_chars_littleendian (f + 0, t0, 8);
number_to_chars_littleendian (f + 8, t1, 8);
- unwind.next_slot_number = (unsigned long) f + 16;
- unwind.next_slot_frag = frag_now;
+ if (unwind.list)
+ {
+ unwind.list->next_slot_number = (unsigned long) f + 16;
+ unwind.list->next_slot_frag = frag_now;
+ }
}
int
@@ -6505,7 +6646,15 @@ md_begin ()
bfd_set_section_alignment (stdoutput, text_section, 4);
- target_big_endian = TARGET_BYTES_BIG_ENDIAN;
+ /* Make sure function pointers get initialized. */
+ target_big_endian = -1;
+ dot_byteorder (TARGET_BYTES_BIG_ENDIAN);
+
+ alias_hash = hash_new ();
+ alias_name_hash = hash_new ();
+ secalias_hash = hash_new ();
+ secalias_name_hash = hash_new ();
+
pseudo_func[FUNC_DTP_MODULE].u.sym =
symbol_new (".<dtpmod>", undefined_section, FUNC_DTP_MODULE,
&zero_address_frag);
@@ -6526,6 +6675,10 @@ md_begin ()
symbol_new (".<ltoff>", undefined_section, FUNC_LT_RELATIVE,
&zero_address_frag);
+ pseudo_func[FUNC_LT_RELATIVE_X].u.sym =
+ symbol_new (".<ltoffx>", undefined_section, FUNC_LT_RELATIVE_X,
+ &zero_address_frag);
+
pseudo_func[FUNC_PC_RELATIVE].u.sym =
symbol_new (".<pcrel>", undefined_section, FUNC_PC_RELATIVE,
&zero_address_frag);
@@ -7034,6 +7187,23 @@ ia64_frob_label (sym)
}
}
+#ifdef TE_HPUX
+/* The HP-UX linker will give unresolved symbol errors for symbols
+ that are declared but unused. This routine removes declared,
+ unused symbols from an object. */
+int
+ia64_frob_symbol (sym)
+ struct symbol *sym;
+{
+ if ((S_GET_SEGMENT (sym) == &bfd_und_section && ! symbol_used_p (sym) &&
+ ELF_ST_VISIBILITY (S_GET_OTHER (sym)) == STV_DEFAULT)
+ || (S_GET_SEGMENT (sym) == &bfd_abs_section
+ && ! S_IS_EXTERNAL (sym)))
+ return 1;
+ return 0;
+}
+#endif
+
void
ia64_flush_pending_output ()
{
@@ -8645,6 +8815,77 @@ clear_qp_branch_flag (mask)
}
}
+/* MASK contains 2 and only 2 PRs which are mutually exclusive. Remove
+ any mutexes which contain one of the PRs and create new ones when
+ needed. */
+
+static int
+update_qp_mutex (valueT mask)
+{
+ int i;
+ int add = 0;
+
+ i = 0;
+ while (i < qp_mutexeslen)
+ {
+ if ((qp_mutexes[i].prmask & mask) != 0)
+ {
+ /* If it destroys and creates the same mutex, do nothing. */
+ if (qp_mutexes[i].prmask == mask
+ && qp_mutexes[i].path == md.path)
+ {
+ i++;
+ add = -1;
+ }
+ else
+ {
+ int keep = 0;
+
+ if (md.debug_dv)
+ {
+ fprintf (stderr, " Clearing mutex relation");
+ print_prmask (qp_mutexes[i].prmask);
+ fprintf (stderr, "\n");
+ }
+
+ /* Deal with the old mutex with more than 3+ PRs only if
+ the new mutex on the same execution path with it.
+
+ FIXME: The 3+ mutex support is incomplete.
+ dot_pred_rel () may be a better place to fix it. */
+ if (qp_mutexes[i].path == md.path)
+ {
+ /* If it is a proper subset of the mutex, create a
+ new mutex. */
+ if (add == 0
+ && (qp_mutexes[i].prmask & mask) == mask)
+ add = 1;
+
+ qp_mutexes[i].prmask &= ~mask;
+ if (qp_mutexes[i].prmask & (qp_mutexes[i].prmask - 1))
+ {
+ /* Modify the mutex if there are more than one
+ PR left. */
+ keep = 1;
+ i++;
+ }
+ }
+
+ if (keep == 0)
+ /* Remove the mutex. */
+ qp_mutexes[i] = qp_mutexes[--qp_mutexeslen];
+ }
+ }
+ else
+ ++i;
+ }
+
+ if (add == 1)
+ add_qp_mutex (mask);
+
+ return add;
+}
+
/* Remove any mutexes which contain any of the PRs indicated in the mask.
Any changes to a PR clears the mutex relations which include that PR. */
@@ -8859,7 +9100,7 @@ note_register_values (idesc)
else if (idesc->operands[i] == IA64_OPND_PR_ROT)
{
if (idesc->operands[1] & ((valueT) 1 << 43))
- qp_changemask = ~(valueT) 0xFFFFFFFFFFF | idesc->operands[1];
+ qp_changemask = -((valueT) 1 << 44) | idesc->operands[1];
else
qp_changemask = idesc->operands[1];
qp_changemask &= ~(valueT) 0xFFFF;
@@ -8909,11 +9150,11 @@ note_register_values (idesc)
{
int p1 = CURR_SLOT.opnd[0].X_add_number - REG_P;
int p2 = CURR_SLOT.opnd[1].X_add_number - REG_P;
- valueT p1mask = (valueT) 1 << p1;
- valueT p2mask = (valueT) 1 << p2;
+ valueT p1mask = (p1 != 0) ? (valueT) 1 << p1 : 0;
+ valueT p2mask = (p2 != 0) ? (valueT) 1 << p2 : 0;
- /* If one of the PRs is PR0, we can't really do anything. */
- if (p1 == 0 || p2 == 0)
+ /* If both PRs are PR0, we can't really do anything. */
+ if (p1 == 0 && p2 == 0)
{
if (md.debug_dv)
fprintf (stderr, " Ignoring PRs due to inclusion of p0\n");
@@ -8923,7 +9164,6 @@ note_register_values (idesc)
else if (has_suffix_p (idesc->name, ".or.andcm")
|| has_suffix_p (idesc->name, ".and.orcm"))
{
- add_qp_mutex (p1mask | p2mask);
clear_qp_implies (p2mask, p1mask);
}
else if (has_suffix_p (idesc->name, ".andcm")
@@ -8939,26 +9179,29 @@ note_register_values (idesc)
}
else
{
+ int added = 0;
+
clear_qp_implies (p1mask | p2mask, p1mask | p2mask);
- if (has_suffix_p (idesc->name, ".unc"))
+
+ /* If one of the PRs is PR0, we call clear_qp_mutex. */
+ if (p1 == 0 || p2 == 0)
+ clear_qp_mutex (p1mask | p2mask);
+ else
+ added = update_qp_mutex (p1mask | p2mask);
+
+ if (CURR_SLOT.qp_regno == 0
+ || has_suffix_p (idesc->name, ".unc"))
{
- add_qp_mutex (p1mask | p2mask);
+ if (added == 0 && p1 && p2)
+ add_qp_mutex (p1mask | p2mask);
if (CURR_SLOT.qp_regno != 0)
{
- add_qp_imply (CURR_SLOT.opnd[0].X_add_number - REG_P,
- CURR_SLOT.qp_regno);
- add_qp_imply (CURR_SLOT.opnd[1].X_add_number - REG_P,
- CURR_SLOT.qp_regno);
+ if (p1)
+ add_qp_imply (p1, CURR_SLOT.qp_regno);
+ if (p2)
+ add_qp_imply (p2, CURR_SLOT.qp_regno);
}
}
- else if (CURR_SLOT.qp_regno == 0)
- {
- add_qp_mutex (p1mask | p2mask);
- }
- else
- {
- clear_qp_mutex (p1mask | p2mask);
- }
}
}
/* Look for mov imm insns into GRs. */
@@ -9758,7 +10001,27 @@ md_assemble (str)
flags = idesc->flags;
if ((flags & IA64_OPCODE_FIRST) != 0)
- insn_group_break (1, 0, 0);
+ {
+ /* The alignment frag has to end with a stop bit only if the
+ next instruction after the alignment directive has to be
+ the first instruction in an instruction group. */
+ if (align_frag)
+ {
+ while (align_frag->fr_type != rs_align_code)
+ {
+ align_frag = align_frag->fr_next;
+ if (!align_frag)
+ break;
+ }
+ /* align_frag can be NULL if there are directives in
+ between. */
+ if (align_frag && align_frag->fr_next == frag_now)
+ align_frag->tc_frag_data = 1;
+ }
+
+ insn_group_break (1, 0, 0);
+ }
+ align_frag = NULL;
if ((flags & IA64_OPCODE_NO_PRED) != 0 && qp_regno != 0)
{
@@ -9982,12 +10245,16 @@ ia64_force_relocation (fix)
case BFD_RELOC_IA64_PLTOFF64I:
case BFD_RELOC_IA64_PLTOFF64MSB:
case BFD_RELOC_IA64_PLTOFF64LSB:
+
+ case BFD_RELOC_IA64_LTOFF22X:
+ case BFD_RELOC_IA64_LDXMOV:
return 1;
default:
- return 0;
+ break;
}
- return 0;
+
+ return generic_force_reloc (fix);
}
/* Decide from what point a pc-relative relocation is relative to,
@@ -10005,6 +10272,20 @@ ia64_pcrel_from_section (fix, sec)
return off;
}
+
+/* Used to emit section-relative relocs for the dwarf2 debug data. */
+void
+ia64_dwarf2_emit_offset (symbolS *symbol, unsigned int size)
+{
+ expressionS expr;
+
+ expr.X_op = O_pseudo_fixup;
+ expr.X_op_symbol = pseudo_func[FUNC_SEC_RELATIVE].u.sym;
+ expr.X_add_number = 0;
+ expr.X_add_symbol = symbol;
+ emit_expr (&expr, size);
+}
+
/* This is called whenever some data item (not an instruction) needs a
fixup. We pick the right reloc code depending on the byteorder
currently in effect. */
@@ -10064,7 +10345,6 @@ ia64_cons_fix_new (f, where, nbytes, exp)
code = BFD_RELOC_IA64_IPLTMSB;
else
code = BFD_RELOC_IA64_IPLTLSB;
-
exp->X_op = O_symbol;
break;
}
@@ -10075,11 +10355,12 @@ ia64_cons_fix_new (f, where, nbytes, exp)
ignore_rest_of_line ();
return;
}
+
if (exp->X_op == O_pseudo_fixup)
{
- /* ??? */
exp->X_op = O_symbol;
code = ia64_gen_real_reloc_type (exp->X_op_symbol, code);
+ /* ??? If code unchanged, unsupported. */
}
fix = fix_new_exp (f, where, nbytes, exp, 0, code);
@@ -10141,6 +10422,14 @@ ia64_gen_real_reloc_type (sym, r_type)
}
break;
+ case FUNC_LT_RELATIVE_X:
+ switch (r_type)
+ {
+ case BFD_RELOC_IA64_IMM22: new = BFD_RELOC_IA64_LTOFF22X; break;
+ default: break;
+ }
+ break;
+
case FUNC_PC_RELATIVE:
switch (r_type)
{
@@ -10247,6 +10536,10 @@ ia64_gen_real_reloc_type (sym, r_type)
case FUNC_DTP_RELATIVE:
switch (r_type)
{
+ case BFD_RELOC_IA64_DIR64MSB:
+ new = BFD_RELOC_IA64_DTPREL64MSB; break;
+ case BFD_RELOC_IA64_DIR64LSB:
+ new = BFD_RELOC_IA64_DTPREL64LSB; break;
case BFD_RELOC_IA64_IMM14:
new = BFD_RELOC_IA64_DTPREL14; break;
case BFD_RELOC_IA64_IMM22:
@@ -10274,6 +10567,7 @@ ia64_gen_real_reloc_type (sym, r_type)
default:
abort ();
}
+
/* Hmmmm. Should this ever occur? */
if (new)
return new;
@@ -10301,8 +10595,6 @@ ia64_validate_fix (fix)
default:
break;
}
-
- return;
}
static void
@@ -10378,7 +10670,6 @@ md_apply_fix3 (fix, valP, seg)
{
char *fixpos;
valueT value = *valP;
- int adjust = 0;
fixpos = fix->fx_frag->fr_literal + fix->fx_where;
@@ -10388,22 +10679,18 @@ md_apply_fix3 (fix, valP, seg)
{
case BFD_RELOC_IA64_DIR32MSB:
fix->fx_r_type = BFD_RELOC_IA64_PCREL32MSB;
- adjust = 1;
break;
case BFD_RELOC_IA64_DIR32LSB:
fix->fx_r_type = BFD_RELOC_IA64_PCREL32LSB;
- adjust = 1;
break;
case BFD_RELOC_IA64_DIR64MSB:
fix->fx_r_type = BFD_RELOC_IA64_PCREL64MSB;
- adjust = 1;
break;
case BFD_RELOC_IA64_DIR64LSB:
fix->fx_r_type = BFD_RELOC_IA64_PCREL64LSB;
- adjust = 1;
break;
default:
@@ -10412,8 +10699,9 @@ md_apply_fix3 (fix, valP, seg)
}
if (fix->fx_addsy)
{
- if (fix->fx_r_type == (int) BFD_RELOC_UNUSED)
+ switch (fix->fx_r_type)
{
+ case BFD_RELOC_UNUSED:
/* This must be a TAG13 or TAG13b operand. There are no external
relocs defined for them, so we must give an error. */
as_bad_where (fix->fx_file, fix->fx_line,
@@ -10421,12 +10709,22 @@ md_apply_fix3 (fix, valP, seg)
elf64_ia64_operands[fix->tc_fix_data.opnd].desc);
fix->fx_done = 1;
return;
- }
- /* ??? This is a hack copied from tc-i386.c to make PCREL relocs
- work. There should be a better way to handle this. */
- if (adjust)
- fix->fx_offset += fix->fx_where + fix->fx_frag->fr_address;
+ case BFD_RELOC_IA64_TPREL14:
+ case BFD_RELOC_IA64_TPREL22:
+ case BFD_RELOC_IA64_TPREL64I:
+ case BFD_RELOC_IA64_LTOFF_TPREL22:
+ case BFD_RELOC_IA64_LTOFF_DTPMOD22:
+ case BFD_RELOC_IA64_DTPREL14:
+ case BFD_RELOC_IA64_DTPREL22:
+ case BFD_RELOC_IA64_DTPREL64I:
+ case BFD_RELOC_IA64_LTOFF_DTPREL22:
+ S_SET_THREAD_LOCAL (fix->fx_addsy);
+ break;
+
+ default:
+ break;
+ }
}
else if (fix->tc_fix_data.opnd == IA64_OPND_NIL)
{
@@ -10483,7 +10781,6 @@ md_atof (type, lit, size)
int *size;
{
LITTLENUM_TYPE words[MAX_LITTLENUMS];
- LITTLENUM_TYPE *word;
char *t;
int prec;
@@ -10518,26 +10815,19 @@ md_atof (type, lit, size)
t = atof_ieee (input_line_pointer, type, words);
if (t)
input_line_pointer = t;
- *size = prec * sizeof (LITTLENUM_TYPE);
- for (word = words + prec - 1; prec--;)
+ (*ia64_float_to_chars) (lit, words, prec);
+
+ if (type == 'X')
{
- md_number_to_chars (lit, (long) (*word--), sizeof (LITTLENUM_TYPE));
- lit += sizeof (LITTLENUM_TYPE);
+ /* It is 10 byte floating point with 6 byte padding. */
+ memset (&lit [10], 0, 6);
+ *size = 8 * sizeof (LITTLENUM_TYPE);
}
- return 0;
-}
-
-/* Round up a section's size to the appropriate boundary. */
-valueT
-md_section_align (seg, size)
- segT seg;
- valueT size;
-{
- int align = bfd_get_section_alignment (stdoutput, seg);
- valueT mask = ((valueT) 1 << align) - 1;
+ else
+ *size = prec * sizeof (LITTLENUM_TYPE);
- return (size + mask) & ~mask;
+ return 0;
}
/* Handle ia64 specific semantics of the align directive. */
@@ -10561,22 +10851,46 @@ ia64_handle_align (fragp)
fragS *fragp;
{
/* Use mfi bundle of nops with no stop bits. */
- static const unsigned char be_nop[]
- = { 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00,
- 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x0c};
static const unsigned char le_nop[]
= { 0x0c, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00};
+ static const unsigned char le_nop_stop[]
+ = { 0x0d, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
+ 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00};
int bytes;
char *p;
+ const unsigned char *nop;
if (fragp->fr_type != rs_align_code)
return;
+ /* Check if this frag has to end with a stop bit. */
+ nop = fragp->tc_frag_data ? le_nop_stop : le_nop;
+
bytes = fragp->fr_next->fr_address - fragp->fr_address - fragp->fr_fix;
p = fragp->fr_literal + fragp->fr_fix;
+ /* If no paddings are needed, we check if we need a stop bit. */
+ if (!bytes && fragp->tc_frag_data)
+ {
+ if (fragp->fr_fix < 16)
+#if 1
+ /* FIXME: It won't work with
+ .align 16
+ alloc r32=ar.pfs,1,2,4,0
+ */
+ ;
+#else
+ as_bad_where (fragp->fr_file, fragp->fr_line,
+ _("Can't add stop bit to mark end of instruction group"));
+#endif
+ else
+ /* Bundles are always in little-endian byte order. Make sure
+ the previous bundle has the stop bit. */
+ *(p - 16) |= 1;
+ }
+
/* Make sure we are on a 16-byte boundary, in case someone has been
putting data into a text section. */
if (bytes & 15)
@@ -10588,6 +10902,214 @@ ia64_handle_align (fragp)
fragp->fr_fix += fix;
}
- memcpy (p, (target_big_endian ? be_nop : le_nop), 16);
+ /* Instruction bundles are always little-endian. */
+ memcpy (p, nop, 16);
fragp->fr_var = 16;
}
+
+static void
+ia64_float_to_chars_bigendian (char *lit, LITTLENUM_TYPE *words,
+ int prec)
+{
+ while (prec--)
+ {
+ number_to_chars_bigendian (lit, (long) (*words++),
+ sizeof (LITTLENUM_TYPE));
+ lit += sizeof (LITTLENUM_TYPE);
+ }
+}
+
+static void
+ia64_float_to_chars_littleendian (char *lit, LITTLENUM_TYPE *words,
+ int prec)
+{
+ while (prec--)
+ {
+ number_to_chars_littleendian (lit, (long) (words[prec]),
+ sizeof (LITTLENUM_TYPE));
+ lit += sizeof (LITTLENUM_TYPE);
+ }
+}
+
+void
+ia64_elf_section_change_hook (void)
+{
+ dot_byteorder (-1);
+}
+
+/* Check if a label should be made global. */
+void
+ia64_check_label (symbolS *label)
+{
+ if (*input_line_pointer == ':')
+ {
+ S_SET_EXTERNAL (label);
+ input_line_pointer++;
+ }
+}
+
+/* Used to remember where .alias and .secalias directives are seen. We
+ will rename symbol and section names when we are about to output
+ the relocatable file. */
+struct alias
+{
+ char *file; /* The file where the directive is seen. */
+ unsigned int line; /* The line number the directive is at. */
+ const char *name; /* The orignale name of the symbol. */
+};
+
+/* Called for .alias and .secalias directives. If SECTION is 1, it is
+ .secalias. Otherwise, it is .alias. */
+static void
+dot_alias (int section)
+{
+ char *name, *alias;
+ char delim;
+ char *end_name;
+ int len;
+ const char *error_string;
+ struct alias *h;
+ const char *a;
+ struct hash_control *ahash, *nhash;
+ const char *kind;
+
+ name = input_line_pointer;
+ delim = get_symbol_end ();
+ end_name = input_line_pointer;
+ *end_name = delim;
+
+ if (name == end_name)
+ {
+ as_bad (_("expected symbol name"));
+ discard_rest_of_line ();
+ return;
+ }
+
+ SKIP_WHITESPACE ();
+
+ if (*input_line_pointer != ',')
+ {
+ *end_name = 0;
+ as_bad (_("expected comma after \"%s\""), name);
+ *end_name = delim;
+ ignore_rest_of_line ();
+ return;
+ }
+
+ input_line_pointer++;
+ *end_name = 0;
+
+ /* We call demand_copy_C_string to check if alias string is valid.
+ There should be a closing `"' and no `\0' in the string. */
+ alias = demand_copy_C_string (&len);
+ if (alias == NULL)
+ {
+ ignore_rest_of_line ();
+ return;
+ }
+
+ /* Make a copy of name string. */
+ len = strlen (name) + 1;
+ obstack_grow (&notes, name, len);
+ name = obstack_finish (&notes);
+
+ if (section)
+ {
+ kind = "section";
+ ahash = secalias_hash;
+ nhash = secalias_name_hash;
+ }
+ else
+ {
+ kind = "symbol";
+ ahash = alias_hash;
+ nhash = alias_name_hash;
+ }
+
+ /* Check if alias has been used before. */
+ h = (struct alias *) hash_find (ahash, alias);
+ if (h)
+ {
+ if (strcmp (h->name, name))
+ as_bad (_("`%s' is already the alias of %s `%s'"),
+ alias, kind, h->name);
+ goto out;
+ }
+
+ /* Check if name already has an alias. */
+ a = (const char *) hash_find (nhash, name);
+ if (a)
+ {
+ if (strcmp (a, alias))
+ as_bad (_("%s `%s' already has an alias `%s'"), kind, name, a);
+ goto out;
+ }
+
+ h = (struct alias *) xmalloc (sizeof (struct alias));
+ as_where (&h->file, &h->line);
+ h->name = name;
+
+ error_string = hash_jam (ahash, alias, (PTR) h);
+ if (error_string)
+ {
+ as_fatal (_("inserting \"%s\" into %s alias hash table failed: %s"),
+ alias, kind, error_string);
+ goto out;
+ }
+
+ error_string = hash_jam (nhash, name, (PTR) alias);
+ if (error_string)
+ {
+ as_fatal (_("inserting \"%s\" into %s name hash table failed: %s"),
+ alias, kind, error_string);
+out:
+ obstack_free (&notes, name);
+ obstack_free (&notes, alias);
+ }
+
+ demand_empty_rest_of_line ();
+}
+
+/* It renames the original symbol name to its alias. */
+static void
+do_alias (const char *alias, PTR value)
+{
+ struct alias *h = (struct alias *) value;
+ symbolS *sym = symbol_find (h->name);
+
+ if (sym == NULL)
+ as_warn_where (h->file, h->line,
+ _("symbol `%s' aliased to `%s' is not used"),
+ h->name, alias);
+ else
+ S_SET_NAME (sym, (char *) alias);
+}
+
+/* Called from write_object_file. */
+void
+ia64_adjust_symtab (void)
+{
+ hash_traverse (alias_hash, do_alias);
+}
+
+/* It renames the original section name to its alias. */
+static void
+do_secalias (const char *alias, PTR value)
+{
+ struct alias *h = (struct alias *) value;
+ segT sec = bfd_get_section_by_name (stdoutput, h->name);
+
+ if (sec == NULL)
+ as_warn_where (h->file, h->line,
+ _("section `%s' aliased to `%s' is not used"),
+ h->name, alias);
+ else
+ sec->name = alias;
+}
+
+/* Called from write_object_file. */
+void
+ia64_frob_file (void)
+{
+ hash_traverse (secalias_hash, do_secalias);
+}
diff --git a/contrib/binutils/gas/config/tc-ia64.h b/contrib/binutils/gas/config/tc-ia64.h
index 2da3285..dcc2c29 100644
--- a/contrib/binutils/gas/config/tc-ia64.h
+++ b/contrib/binutils/gas/config/tc-ia64.h
@@ -26,15 +26,34 @@
/* Linux is little endian by default. HPUX is big endian by default. */
#ifdef TE_HPUX
-#define md_number_to_chars number_to_chars_bigendian
#define TARGET_BYTES_BIG_ENDIAN 1
#define MD_FLAGS_DEFAULT EF_IA_64_BE
#else
-#define md_number_to_chars number_to_chars_littleendian
#define TARGET_BYTES_BIG_ENDIAN 0
#define MD_FLAGS_DEFAULT EF_IA_64_ABI64
#endif /* TE_HPUX */
+extern void (*ia64_number_to_chars) PARAMS ((char *, valueT, int));
+#define md_number_to_chars (*ia64_number_to_chars)
+
+extern void ia64_elf_section_change_hook PARAMS ((void));
+#define md_elf_section_change_hook ia64_elf_section_change_hook
+
+/* We record the endian for this section. 0 means default, 1 means
+ big endian and 2 means little endian. */
+struct ia64_segment_info_type
+{
+ unsigned int endian : 2;
+};
+
+#define TC_SEGMENT_INFO_TYPE struct ia64_segment_info_type
+
+extern void ia64_adjust_symtab PARAMS ((void));
+#define tc_adjust_symtab() ia64_adjust_symtab ()
+
+extern void ia64_frob_file PARAMS ((void));
+#define tc_frob_file() ia64_frob_file ()
+
/* We need to set the default object file format in ia64_init and not in
md_begin. This is because parse_args is called before md_begin, and we
do not want md_begin to wipe out the flag settings set by options parsed in
@@ -59,17 +78,21 @@ extern const char *ia64_target_format PARAMS ((void));
#define LEX_QM LEX_NAME /* allow `?' inside name */
#define LEX_HASH LEX_END_NAME /* allow `#' ending a name */
+#define SUB_SEGMENT_ALIGN(SEG, FRCHAIN) 0
+
struct ia64_fix
{
int bigendian; /* byte order at fix location */
enum ia64_opnd opnd;
};
-extern void ia64_do_align PARAMS((int n));
extern void ia64_end_of_source PARAMS((void));
extern void ia64_start_line PARAMS((void));
extern int ia64_unrecognized_line PARAMS((int ch));
extern void ia64_frob_label PARAMS((struct symbol *sym));
+#ifdef TE_HPUX
+extern int ia64_frob_symbol PARAMS((struct symbol *sym));
+#endif
extern void ia64_flush_pending_output PARAMS((void));
extern int ia64_parse_name (char *name, expressionS *e);
extern int ia64_optimize_expr PARAMS((expressionS *l, operatorT op,
@@ -89,24 +112,33 @@ extern long ia64_pcrel_from_section PARAMS ((struct fix *fix, segT sec));
extern void ia64_md_do_align PARAMS ((int, const char *, int, int));
extern void ia64_handle_align PARAMS ((fragS *f));
extern void ia64_after_parse_args PARAMS ((void));
+extern void ia64_dwarf2_emit_offset PARAMS ((symbolS *, unsigned int));
+extern void ia64_check_label PARAMS ((symbolS *));
+extern int ia64_estimate_size_before_relax (fragS *, asection *);
+extern void ia64_convert_frag (fragS *);
#define md_end() ia64_end_of_source ()
#define md_start_line_hook() ia64_start_line ()
#define tc_unrecognized_line(ch) ia64_unrecognized_line (ch)
#define tc_frob_label(s) ia64_frob_label (s)
+#ifdef TE_HPUX
+#define tc_frob_symbol(s,p) p |= ia64_frob_symbol (s)
+#endif /* TE_HPUX */
#define md_flush_pending_output() ia64_flush_pending_output ()
#define md_parse_name(s,e,c) ia64_parse_name (s, e)
#define tc_canonicalize_symbol_name(s) ia64_canonicalize_symbol_name (s)
+#define tc_canonicalize_section_name(s) ia64_canonicalize_symbol_name (s)
#define md_optimize_expr(l,o,r) ia64_optimize_expr (l, o, r)
#define md_cons_align(n) ia64_cons_align (n)
#define TC_FORCE_RELOCATION(f) ia64_force_relocation (f)
#define tc_fix_adjustable(f) ia64_fix_adjustable (f)
-#define md_convert_frag(b,s,f) as_fatal ("ia64_convert_frag")
+#define MD_APPLY_SYM_VALUE(FIX) 0
+#define md_convert_frag(b,s,f) ia64_convert_frag (f)
#define md_create_long_jump(p,f,t,fr,s) as_fatal ("ia64_create_long_jump")
#define md_create_short_jump(p,f,t,fr,s) \
as_fatal ("ia64_create_short_jump")
#define md_estimate_size_before_relax(f,s) \
- (as_fatal ("ia64_estimate_size_before_relax"), 1)
+ ia64_estimate_size_before_relax(f,s)
#define md_elf_section_letter ia64_elf_section_letter
#define md_elf_section_flags ia64_elf_section_flags
#define TC_FIX_TYPE struct ia64_fix
@@ -114,19 +146,22 @@ extern void ia64_after_parse_args PARAMS ((void));
#define TC_CONS_FIX_NEW(f,o,l,e) ia64_cons_fix_new (f, o, l, e)
#define TC_VALIDATE_FIX(fix,seg,skip) ia64_validate_fix (fix)
#define MD_PCREL_FROM_SECTION(fix,sec) ia64_pcrel_from_section (fix, sec)
+#define md_section_align(seg,size) (size)
#define md_do_align(n,f,l,m,j) ia64_md_do_align (n,f,l,m)
#define HANDLE_ALIGN(f) ia64_handle_align (f)
#define md_elf_section_type(str,len) ia64_elf_section_type (str, len)
#define md_after_parse_args() ia64_after_parse_args ()
+#define TC_DWARF2_EMIT_OFFSET ia64_dwarf2_emit_offset
+#define tc_check_label(l) ia64_check_label (l)
+
+/* Record if an alignment frag should end with a stop bit. */
+#define TC_FRAG_TYPE int
+#define TC_FRAG_INIT(FRAGP) do {(FRAGP)->tc_frag_data = 0;}while (0)
#define MAX_MEM_FOR_RS_ALIGN_CODE (15 + 16)
#define WORKING_DOT_WORD /* don't do broken word processing for now */
-#define ELF_TC_SPECIAL_SECTIONS \
-{ ".sbss", SHT_NOBITS, SHF_ALLOC + SHF_WRITE + SHF_IA_64_SHORT }, \
-{ ".sdata", SHT_PROGBITS, SHF_ALLOC + SHF_WRITE + SHF_IA_64_SHORT },
-
#define DWARF2_LINE_MIN_INSN_LENGTH 1 /* so slot-multipliers can be 1 */
/* This is the information required for unwind records in an ia64
@@ -177,7 +212,7 @@ typedef enum
bspstore_gr, bspstore_psprel, bspstore_sprel, rnat_when, rnat_gr,
rnat_psprel, rnat_sprel, epilogue, label_state, copy_state,
spill_psprel, spill_sprel, spill_reg, spill_psprel_p, spill_sprel_p,
- spill_reg_p, unwabi
+ spill_reg_p, unwabi, endp
} unw_record_type;
/* These structures declare the fields that can be used in each of the
@@ -249,18 +284,16 @@ typedef struct unwind_record
} record;
} unwind_record;
-/* This expression evaluates to false if the relocation is for a local
+/* This expression evaluates to true if the relocation is for a local
object for which we still want to do the relocation at runtime.
- True if we are willing to perform this relocation while building
- the .o file. This is only used for pcrel relocations. */
+ False if we are willing to perform this relocation while building
+ the .o file. */
/* If the reloc type is BFD_RELOC_UNUSED, then this is for a TAG13/TAG13b field
which has no external reloc, so we must resolve the value now. */
-#define TC_RELOC_RTSYM_LOC_FIXUP(FIX) \
- ((FIX)->fx_addsy == NULL \
- || (FIX)->fx_r_type == BFD_RELOC_UNUSED \
- || (! S_IS_EXTERNAL ((FIX)->fx_addsy) \
- && ! S_IS_WEAK ((FIX)->fx_addsy) \
- && S_IS_DEFINED ((FIX)->fx_addsy) \
- && ! S_IS_COMMON ((FIX)->fx_addsy)))
+#define TC_FORCE_RELOCATION_LOCAL(FIX) \
+ ((FIX)->fx_r_type != BFD_RELOC_UNUSED \
+ && (!(FIX)->fx_pcrel \
+ || (FIX)->fx_plt \
+ || TC_FORCE_RELOCATION (FIX)))
diff --git a/contrib/binutils/gas/config/tc-ppc.c b/contrib/binutils/gas/config/tc-ppc.c
index d7e8e69..66366a5 100644
--- a/contrib/binutils/gas/config/tc-ppc.c
+++ b/contrib/binutils/gas/config/tc-ppc.c
@@ -1,6 +1,6 @@
/* tc-ppc.c -- Assemble for the PowerPC or POWER (RS/6000)
- Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
- Free Software Foundation, Inc.
+ Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
+ 2004 Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support.
This file is part of GAS, the GNU Assembler.
@@ -24,7 +24,7 @@
#include "as.h"
#include "safe-ctype.h"
#include "subsegs.h"
-
+#include "dw2gencfi.h"
#include "opcode/ppc.h"
#ifdef OBJ_ELF
@@ -47,9 +47,9 @@ static int set_target_endian = 0;
/* Whether to use user friendly register names. */
#ifndef TARGET_REG_NAMES_P
#ifdef TE_PE
-#define TARGET_REG_NAMES_P true
+#define TARGET_REG_NAMES_P TRUE
#else
-#define TARGET_REG_NAMES_P false
+#define TARGET_REG_NAMES_P FALSE
#endif
#endif
@@ -83,9 +83,9 @@ static int set_target_endian = 0;
#define SEX16(val) ((((val) & 0xffff) ^ 0x8000) - 0x8000)
-static boolean reg_names_p = TARGET_REG_NAMES_P;
+static bfd_boolean reg_names_p = TARGET_REG_NAMES_P;
-static boolean register_name PARAMS ((expressionS *));
+static bfd_boolean register_name PARAMS ((expressionS *));
static void ppc_set_cpu PARAMS ((void));
static unsigned long ppc_insert_operand
PARAMS ((unsigned long insn, const struct powerpc_operand *operand,
@@ -111,7 +111,7 @@ static void ppc_ec PARAMS ((int));
static void ppc_ef PARAMS ((int));
static void ppc_es PARAMS ((int));
static void ppc_csect PARAMS ((int));
-static void ppc_change_csect PARAMS ((symbolS *));
+static void ppc_change_csect PARAMS ((symbolS *, offsetT));
static void ppc_function PARAMS ((int));
static void ppc_extern PARAMS ((int));
static void ppc_lglobl PARAMS ((int));
@@ -130,6 +130,7 @@ static void ppc_elf_cons PARAMS ((int));
static void ppc_elf_rdata PARAMS ((int));
static void ppc_elf_lcomm PARAMS ((int));
static void ppc_elf_validate_fix PARAMS ((fixS *, segT));
+static void ppc_apuinfo_section_add PARAMS ((unsigned int apu, unsigned int version));
#endif
#ifdef TE_PE
@@ -181,6 +182,13 @@ const char EXP_CHARS[] = "eE";
/* Characters which mean that a number is a floating point constant,
as in 0d1.0. */
const char FLT_CHARS[] = "dD";
+
+/* '+' and '-' can be used as postfix predicate predictors for conditional
+ branches. So they need to be accepted as symbol characters. */
+const char ppc_symbol_chars[] = "+-";
+
+/* The dwarf2 data alignment, adjusted for 32 or 64 bit. */
+int ppc_cie_data_alignment;
/* The target specific pseudo-ops which we support. */
@@ -232,8 +240,6 @@ const pseudo_typeS md_pseudo_table[] =
{ "rdata", ppc_elf_rdata, 0 },
{ "rodata", ppc_elf_rdata, 0 },
{ "lcomm", ppc_elf_lcomm, 0 },
- { "file", (void (*) PARAMS ((int))) dwarf2_directive_file, 0 },
- { "loc", dwarf2_directive_loc, 0 },
#endif
#ifdef TE_PE
@@ -602,7 +608,7 @@ reg_name_search (regs, regcount, name)
* original state.
*/
-static boolean
+static bfd_boolean
register_name (expressionP)
expressionS *expressionP;
{
@@ -617,7 +623,7 @@ register_name (expressionP)
name = ++input_line_pointer;
else if (!reg_names_p || !ISALPHA (name[0]))
- return false;
+ return FALSE;
c = get_symbol_end ();
reg_number = reg_name_search (pre_defined_registers, REG_NAME_CNT, name);
@@ -634,12 +640,12 @@ register_name (expressionP)
/* Make the rest nice. */
expressionP->X_add_symbol = NULL;
expressionP->X_op_symbol = NULL;
- return true;
+ return TRUE;
}
/* Reset the line as if we had not done anything. */
input_line_pointer = start;
- return false;
+ return FALSE;
}
/* This function is called for each symbol seen in an expression. It
@@ -647,7 +653,7 @@ register_name (expressionP)
to use for condition codes. */
/* Whether to do the special parsing. */
-static boolean cr_operand;
+static bfd_boolean cr_operand;
/* Names to recognize in a condition code. This table is sorted. */
static const struct pd_reg cr_names[] =
@@ -715,12 +721,12 @@ static flagword ppc_flags = 0;
/* Whether this is Solaris or not. */
#ifdef TARGET_SOLARIS_COMMENT
-#define SOLARIS_P true
+#define SOLARIS_P TRUE
#else
-#define SOLARIS_P false
+#define SOLARIS_P FALSE
#endif
-static boolean msolaris = SOLARIS_P;
+static bfd_boolean msolaris = SOLARIS_P;
#endif
#ifdef OBJ_XCOFF
@@ -787,6 +793,20 @@ static segT ppc_current_section;
#ifdef OBJ_ELF
symbolS *GOT_symbol; /* Pre-defined "_GLOBAL_OFFSET_TABLE" */
+#define PPC_APUINFO_ISEL 0x40
+#define PPC_APUINFO_PMR 0x41
+#define PPC_APUINFO_RFMCI 0x42
+#define PPC_APUINFO_CACHELCK 0x43
+#define PPC_APUINFO_SPE 0x100
+#define PPC_APUINFO_EFS 0x101
+#define PPC_APUINFO_BRLOCK 0x102
+
+/*
+ * We keep a list of APUinfo
+ */
+unsigned long *ppc_apuinfo_list;
+unsigned int ppc_apuinfo_num;
+unsigned int ppc_apuinfo_num_alloc;
#endif /* OBJ_ELF */
#ifdef OBJ_ELF
@@ -799,6 +819,107 @@ const struct option md_longopts[] = {
};
const size_t md_longopts_size = sizeof (md_longopts);
+
+/* Handle -m options that set cpu type, and .machine arg. */
+
+static int
+parse_cpu (const char *arg)
+{
+ /* -mpwrx and -mpwr2 mean to assemble for the IBM POWER/2
+ (RIOS2). */
+ if (strcmp (arg, "pwrx") == 0 || strcmp (arg, "pwr2") == 0)
+ ppc_cpu = PPC_OPCODE_POWER | PPC_OPCODE_POWER2 | PPC_OPCODE_32;
+ /* -mpwr means to assemble for the IBM POWER (RIOS1). */
+ else if (strcmp (arg, "pwr") == 0)
+ ppc_cpu = PPC_OPCODE_POWER | PPC_OPCODE_32;
+ /* -m601 means to assemble for the PowerPC 601, which includes
+ instructions that are holdovers from the Power. */
+ else if (strcmp (arg, "601") == 0)
+ ppc_cpu = (PPC_OPCODE_PPC | PPC_OPCODE_CLASSIC
+ | PPC_OPCODE_601 | PPC_OPCODE_32);
+ /* -mppc, -mppc32, -m603, and -m604 mean to assemble for the
+ PowerPC 603/604. */
+ else if (strcmp (arg, "ppc") == 0
+ || strcmp (arg, "ppc32") == 0
+ || strcmp (arg, "603") == 0
+ || strcmp (arg, "604") == 0)
+ ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_CLASSIC | PPC_OPCODE_32;
+ /* -m403 and -m405 mean to assemble for the PowerPC 403/405. */
+ else if (strcmp (arg, "403") == 0
+ || strcmp (arg, "405") == 0)
+ ppc_cpu = (PPC_OPCODE_PPC | PPC_OPCODE_CLASSIC
+ | PPC_OPCODE_403 | PPC_OPCODE_32);
+ else if (strcmp (arg, "440") == 0)
+ ppc_cpu = (PPC_OPCODE_PPC | PPC_OPCODE_BOOKE | PPC_OPCODE_32
+ | PPC_OPCODE_440 | PPC_OPCODE_ISEL | PPC_OPCODE_RFMCI);
+ else if (strcmp (arg, "7400") == 0
+ || strcmp (arg, "7410") == 0
+ || strcmp (arg, "7450") == 0
+ || strcmp (arg, "7455") == 0)
+ ppc_cpu = (PPC_OPCODE_PPC | PPC_OPCODE_CLASSIC
+ | PPC_OPCODE_ALTIVEC | PPC_OPCODE_32);
+ else if (strcmp (arg, "altivec") == 0)
+ {
+ if (ppc_cpu == 0)
+ ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_CLASSIC | PPC_OPCODE_ALTIVEC;
+ else
+ ppc_cpu |= PPC_OPCODE_ALTIVEC;
+ }
+ else if (strcmp (arg, "e500") == 0 || strcmp (arg, "e500x2") == 0)
+ {
+ ppc_cpu = (PPC_OPCODE_PPC | PPC_OPCODE_BOOKE | PPC_OPCODE_SPE
+ | PPC_OPCODE_ISEL | PPC_OPCODE_EFS | PPC_OPCODE_BRLOCK
+ | PPC_OPCODE_PMR | PPC_OPCODE_CACHELCK
+ | PPC_OPCODE_RFMCI);
+ }
+ else if (strcmp (arg, "spe") == 0)
+ {
+ if (ppc_cpu == 0)
+ ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_SPE | PPC_OPCODE_EFS;
+ else
+ ppc_cpu |= PPC_OPCODE_SPE;
+ }
+ /* -mppc64 and -m620 mean to assemble for the 64-bit PowerPC
+ 620. */
+ else if (strcmp (arg, "ppc64") == 0 || strcmp (arg, "620") == 0)
+ {
+ ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_CLASSIC | PPC_OPCODE_64;
+ }
+ else if (strcmp (arg, "ppc64bridge") == 0)
+ {
+ ppc_cpu = (PPC_OPCODE_PPC | PPC_OPCODE_CLASSIC
+ | PPC_OPCODE_64_BRIDGE | PPC_OPCODE_64);
+ }
+ /* -mbooke/-mbooke32 mean enable 32-bit BookE support. */
+ else if (strcmp (arg, "booke") == 0 || strcmp (arg, "booke32") == 0)
+ {
+ ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_BOOKE | PPC_OPCODE_32;
+ }
+ /* -mbooke64 means enable 64-bit BookE support. */
+ else if (strcmp (arg, "booke64") == 0)
+ {
+ ppc_cpu = (PPC_OPCODE_PPC | PPC_OPCODE_BOOKE
+ | PPC_OPCODE_BOOKE64 | PPC_OPCODE_64);
+ }
+ else if (strcmp (arg, "power4") == 0)
+ {
+ ppc_cpu = (PPC_OPCODE_PPC | PPC_OPCODE_CLASSIC
+ | PPC_OPCODE_64 | PPC_OPCODE_POWER4);
+ }
+ /* -mcom means assemble for the common intersection between Power
+ and PowerPC. At present, we just allow the union, rather
+ than the intersection. */
+ else if (strcmp (arg, "com") == 0)
+ ppc_cpu = PPC_OPCODE_COMMON | PPC_OPCODE_32;
+ /* -many means to assemble for any architecture (PWR/PWRX/PPC). */
+ else if (strcmp (arg, "any") == 0)
+ ppc_cpu |= PPC_OPCODE_ANY;
+ else
+ return 0;
+
+ return 1;
+}
+
int
md_parse_option (c, arg)
int c;
@@ -866,77 +987,14 @@ md_parse_option (c, arg)
break;
case 'm':
- /* -mpwrx and -mpwr2 mean to assemble for the IBM POWER/2
- (RIOS2). */
- if (strcmp (arg, "pwrx") == 0 || strcmp (arg, "pwr2") == 0)
- ppc_cpu = PPC_OPCODE_POWER | PPC_OPCODE_POWER2 | PPC_OPCODE_32;
- /* -mpwr means to assemble for the IBM POWER (RIOS1). */
- else if (strcmp (arg, "pwr") == 0)
- ppc_cpu = PPC_OPCODE_POWER | PPC_OPCODE_32;
- /* -m601 means to assemble for the PowerPC 601, which includes
- instructions that are holdovers from the Power. */
- else if (strcmp (arg, "601") == 0)
- ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_601 | PPC_OPCODE_32;
- /* -mppc, -mppc32, -m603, and -m604 mean to assemble for the
- PowerPC 603/604. */
- else if (strcmp (arg, "ppc") == 0
- || strcmp (arg, "ppc32") == 0
- || strcmp (arg, "603") == 0
- || strcmp (arg, "604") == 0)
- ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_32;
- /* -m403 and -m405 mean to assemble for the PowerPC 403/405. */
- else if (strcmp (arg, "403") == 0
- || strcmp (arg, "405") == 0)
- ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_403 | PPC_OPCODE_32;
- else if (strcmp (arg, "7400") == 0
- || strcmp (arg, "7410") == 0
- || strcmp (arg, "7450") == 0
- || strcmp (arg, "7455") == 0)
- ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_ALTIVEC | PPC_OPCODE_32;
- else if (strcmp (arg, "altivec") == 0)
- {
- if (ppc_cpu == 0)
- ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_ALTIVEC;
- else
- ppc_cpu |= PPC_OPCODE_ALTIVEC;
- }
- /* -mppc64 and -m620 mean to assemble for the 64-bit PowerPC
- 620. */
- else if (strcmp (arg, "ppc64") == 0 || strcmp (arg, "620") == 0)
- {
- ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_64;
- }
- else if (strcmp (arg, "ppc64bridge") == 0)
- {
- ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_64_BRIDGE | PPC_OPCODE_64;
- }
- /* -mbooke/-mbooke32 mean enable 32-bit BookE support. */
- else if (strcmp (arg, "booke") == 0 || strcmp (arg, "booke32") == 0)
- ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_BOOKE | PPC_OPCODE_32;
- /* -mbooke64 means enable 64-bit BookE support. */
- else if (strcmp (arg, "booke64") == 0)
- {
- ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_BOOKE |
- PPC_OPCODE_BOOKE64 | PPC_OPCODE_64;
- }
- else if (strcmp (arg, "power4") == 0)
- {
- ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_64 | PPC_OPCODE_POWER4;
- }
- /* -mcom means assemble for the common intersection between Power
- and PowerPC. At present, we just allow the union, rather
- than the intersection. */
- else if (strcmp (arg, "com") == 0)
- ppc_cpu = PPC_OPCODE_COMMON | PPC_OPCODE_32;
- /* -many means to assemble for any architecture (PWR/PWRX/PPC). */
- else if (strcmp (arg, "any") == 0)
- ppc_cpu = PPC_OPCODE_ANY | PPC_OPCODE_32;
+ if (parse_cpu (arg))
+ ;
else if (strcmp (arg, "regnames") == 0)
- reg_names_p = true;
+ reg_names_p = TRUE;
else if (strcmp (arg, "no-regnames") == 0)
- reg_names_p = false;
+ reg_names_p = FALSE;
#ifdef OBJ_ELF
/* -mrelocatable/-mrelocatable-lib -- warn about initializations
@@ -973,13 +1031,13 @@ md_parse_option (c, arg)
else if (strcmp (arg, "solaris") == 0)
{
- msolaris = true;
+ msolaris = TRUE;
ppc_comment_chars = ppc_solaris_comment_chars;
}
else if (strcmp (arg, "no-solaris") == 0)
{
- msolaris = false;
+ msolaris = FALSE;
ppc_comment_chars = ppc_eabi_comment_chars;
}
#endif
@@ -1024,23 +1082,30 @@ md_show_usage (stream)
{
fprintf (stream, _("\
PowerPC options:\n\
+-a32 generate ELF32/XCOFF32\n\
+-a64 generate ELF64/XCOFF64\n\
-u ignored\n\
-mpwrx, -mpwr2 generate code for POWER/2 (RIOS2)\n\
-mpwr generate code for POWER (RIOS1)\n\
-m601 generate code for PowerPC 601\n\
-mppc, -mppc32, -m603, -m604\n\
generate code for PowerPC 603/604\n\
--m403, -m405 generate code for PowerPC 403/405\n\
+-m403, -m405 generate code for PowerPC 403/405\n\
+-m440 generate code for PowerPC 440\n\
-m7400, -m7410, -m7450, -m7455\n\
- generate code For PowerPC 7400/7410/7450/7455\n\
+ generate code For PowerPC 7400/7410/7450/7455\n"));
+ fprintf (stream, _("\
-mppc64, -m620 generate code for PowerPC 620/625/630\n\
-mppc64bridge generate code for PowerPC 64, including bridge insns\n\
-mbooke64 generate code for 64-bit PowerPC BookE\n\
-mbooke, mbooke32 generate code for 32-bit PowerPC BookE\n\
-mpower4 generate code for Power4 architecture\n\
--maltivec generate code for AltiVec\n\
-mcom generate code Power/PowerPC common instructions\n\
--many generate code for any architecture (PWR/PWRX/PPC)\n\
+-many generate code for any architecture (PWR/PWRX/PPC)\n"));
+ fprintf (stream, _("\
+-maltivec generate code for AltiVec\n\
+-me500, -me500x2 generate code for Motorola e500 core complex\n\
+-mspe generate code for Motorola SPE instructions\n\
-mregnames Allow symbolic names for registers\n\
-mno-regnames Do not allow symbolic names for registers\n"));
#ifdef OBJ_ELF
@@ -1048,9 +1113,10 @@ PowerPC options:\n\
-mrelocatable support for GCC's -mrelocatble option\n\
-mrelocatable-lib support for GCC's -mrelocatble-lib option\n\
-memb set PPC_EMB bit in ELF flags\n\
--mlittle, -mlittle-endian\n\
+-mlittle, -mlittle-endian, -l, -le\n\
generate code for a little endian machine\n\
--mbig, -mbig-endian generate code for a big endian machine\n\
+-mbig, -mbig-endian, -b, -be\n\
+ generate code for a big endian machine\n\
-msolaris generate code for Solaris\n\
-mno-solaris do not generate code for Solaris\n\
-V print assembler version number\n\
@@ -1066,23 +1132,23 @@ ppc_set_cpu ()
const char *default_os = TARGET_OS;
const char *default_cpu = TARGET_CPU;
- if (ppc_cpu == 0)
+ if ((ppc_cpu & ~PPC_OPCODE_ANY) == 0)
{
if (ppc_obj64)
- ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_64;
+ ppc_cpu |= PPC_OPCODE_PPC | PPC_OPCODE_CLASSIC | PPC_OPCODE_64;
else if (strncmp (default_os, "aix", 3) == 0
&& default_os[3] >= '4' && default_os[3] <= '9')
- ppc_cpu = PPC_OPCODE_COMMON | PPC_OPCODE_32;
+ ppc_cpu |= PPC_OPCODE_COMMON | PPC_OPCODE_32;
else if (strncmp (default_os, "aix3", 4) == 0)
- ppc_cpu = PPC_OPCODE_POWER | PPC_OPCODE_32;
+ ppc_cpu |= PPC_OPCODE_POWER | PPC_OPCODE_32;
else if (strcmp (default_cpu, "rs6000") == 0)
- ppc_cpu = PPC_OPCODE_POWER | PPC_OPCODE_32;
+ ppc_cpu |= PPC_OPCODE_POWER | PPC_OPCODE_32;
else if (strncmp (default_cpu, "powerpc", 7) == 0)
{
if (default_cpu[7] == '6' && default_cpu[8] == '4')
- ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_64;
+ ppc_cpu |= PPC_OPCODE_PPC | PPC_OPCODE_CLASSIC | PPC_OPCODE_64;
else
- ppc_cpu = PPC_OPCODE_PPC | PPC_OPCODE_32;
+ ppc_cpu |= PPC_OPCODE_PPC | PPC_OPCODE_CLASSIC | PPC_OPCODE_32;
}
else
as_fatal (_("Unknown default cpu = %s, os = %s"),
@@ -1148,26 +1214,22 @@ ppc_target_format ()
#endif
}
-/* This function is called when the assembler starts up. It is called
- after the options have been parsed and the output file has been
- opened. */
+/* Insert opcodes and macros into hash tables. Called at startup and
+ for .cpu pseudo. */
-void
-md_begin ()
+static void
+ppc_setup_opcodes (void)
{
register const struct powerpc_opcode *op;
const struct powerpc_opcode *op_end;
const struct powerpc_macro *macro;
const struct powerpc_macro *macro_end;
- boolean dup_insn = false;
+ bfd_boolean dup_insn = FALSE;
- ppc_set_cpu ();
-
-#ifdef OBJ_ELF
- /* Set the ELF flags if desired. */
- if (ppc_flags && !msolaris)
- bfd_set_private_flags (stdoutput, ppc_flags);
-#endif
+ if (ppc_hash != NULL)
+ hash_die (ppc_hash);
+ if (ppc_macro_hash != NULL)
+ hash_die (ppc_macro_hash);
/* Insert the opcodes into a hash table. */
ppc_hash = hash_new ();
@@ -1197,7 +1259,7 @@ md_begin ()
const char *retval;
retval = hash_insert (ppc_hash, op->name, (PTR) op);
- if (retval != (const char *) NULL)
+ if (retval != NULL)
{
/* Ignore Power duplicates for -m601. */
if ((ppc_cpu & PPC_OPCODE_601) != 0
@@ -1206,11 +1268,15 @@ md_begin ()
as_bad (_("Internal assembler error for instruction %s"),
op->name);
- dup_insn = true;
+ dup_insn = TRUE;
}
}
}
+ if ((ppc_cpu & PPC_OPCODE_ANY) != 0)
+ for (op = powerpc_opcodes; op < op_end; op++)
+ hash_insert (ppc_hash, op->name, (PTR) op);
+
/* Insert the macros into a hash table. */
ppc_macro_hash = hash_new ();
@@ -1225,15 +1291,35 @@ md_begin ()
if (retval != (const char *) NULL)
{
as_bad (_("Internal assembler error for macro %s"), macro->name);
- dup_insn = true;
+ dup_insn = TRUE;
}
}
}
if (dup_insn)
abort ();
+}
+
+/* This function is called when the assembler starts up. It is called
+ after the options have been parsed and the output file has been
+ opened. */
+
+void
+md_begin ()
+{
+ ppc_set_cpu ();
+
+ ppc_cie_data_alignment = ppc_obj64 ? -8 : -4;
+
+#ifdef OBJ_ELF
+ /* Set the ELF flags if desired. */
+ if (ppc_flags && !msolaris)
+ bfd_set_private_flags (stdoutput, ppc_flags);
+#endif
- /* Tell the main code what the endianness is if it is not overidden
+ ppc_setup_opcodes ();
+
+ /* Tell the main code what the endianness is if it is not overridden
by the user. */
if (!set_target_endian)
{
@@ -1261,6 +1347,66 @@ md_begin ()
#endif
}
+void
+ppc_cleanup ()
+{
+#ifdef OBJ_ELF
+ if (ppc_apuinfo_list == NULL)
+ return;
+
+ /* Ok, so write the section info out. We have this layout:
+
+ byte data what
+ ---- ---- ----
+ 0 8 length of "APUinfo\0"
+ 4 (n*4) number of APU's (4 bytes each)
+ 8 2 note type 2
+ 12 "APUinfo\0" name
+ 20 APU#1 first APU's info
+ 24 APU#2 second APU's info
+ ... ...
+ */
+ {
+ char *p;
+ asection *seg = now_seg;
+ subsegT subseg = now_subseg;
+ asection *apuinfo_secp = (asection *) NULL;
+ unsigned int i;
+
+ /* Create the .PPC.EMB.apuinfo section. */
+ apuinfo_secp = subseg_new (".PPC.EMB.apuinfo", 0);
+ bfd_set_section_flags (stdoutput,
+ apuinfo_secp,
+ SEC_HAS_CONTENTS | SEC_READONLY);
+
+ p = frag_more (4);
+ md_number_to_chars (p, (valueT) 8, 4);
+
+ p = frag_more (4);
+ md_number_to_chars (p, (valueT) ppc_apuinfo_num * 4, 4);
+
+ p = frag_more (4);
+ md_number_to_chars (p, (valueT) 2, 4);
+
+ p = frag_more (8);
+ strcpy (p, "APUinfo");
+
+ for (i = 0; i < ppc_apuinfo_num; i++)
+ {
+ p = frag_more (4);
+ md_number_to_chars (p, (valueT) ppc_apuinfo_list[i], 4);
+ }
+
+ frag_align (2, 0, 0);
+
+ /* We probably can't restore the current segment, for there likely
+ isn't one yet... */
+ if (seg && subseg)
+ subseg_set (seg, subseg);
+ }
+#endif
+}
+
/* Insert an operand value into an instruction. */
static unsigned long
@@ -1347,8 +1493,10 @@ ppc_elf_suffix (str_p, exp_p)
{
struct map_bfd {
char *string;
- int length;
- int reloc;
+ unsigned int length : 8;
+ unsigned int valid32 : 1;
+ unsigned int valid64 : 1;
+ unsigned int reloc;
};
char ident[20];
@@ -1358,63 +1506,97 @@ ppc_elf_suffix (str_p, exp_p)
int len;
const struct map_bfd *ptr;
-#define MAP(str,reloc) { str, sizeof (str)-1, reloc }
+#define MAP(str, reloc) { str, sizeof (str) - 1, 1, 1, reloc }
+#define MAP32(str, reloc) { str, sizeof (str) - 1, 1, 0, reloc }
+#define MAP64(str, reloc) { str, sizeof (str) - 1, 0, 1, reloc }
static const struct map_bfd mapping[] = {
- MAP ("l", (int) BFD_RELOC_LO16),
- MAP ("h", (int) BFD_RELOC_HI16),
- MAP ("ha", (int) BFD_RELOC_HI16_S),
- MAP ("brtaken", (int) BFD_RELOC_PPC_B16_BRTAKEN),
- MAP ("brntaken", (int) BFD_RELOC_PPC_B16_BRNTAKEN),
- MAP ("got", (int) BFD_RELOC_16_GOTOFF),
- MAP ("got@l", (int) BFD_RELOC_LO16_GOTOFF),
- MAP ("got@h", (int) BFD_RELOC_HI16_GOTOFF),
- MAP ("got@ha", (int) BFD_RELOC_HI16_S_GOTOFF),
- MAP ("fixup", (int) BFD_RELOC_CTOR), /* warning with -mrelocatable */
- MAP ("plt", (int) BFD_RELOC_24_PLT_PCREL),
- MAP ("pltrel24", (int) BFD_RELOC_24_PLT_PCREL),
- MAP ("copy", (int) BFD_RELOC_PPC_COPY),
- MAP ("globdat", (int) BFD_RELOC_PPC_GLOB_DAT),
- MAP ("local24pc", (int) BFD_RELOC_PPC_LOCAL24PC),
- MAP ("local", (int) BFD_RELOC_PPC_LOCAL24PC),
- MAP ("pltrel", (int) BFD_RELOC_32_PLT_PCREL),
- MAP ("plt@l", (int) BFD_RELOC_LO16_PLTOFF),
- MAP ("plt@h", (int) BFD_RELOC_HI16_PLTOFF),
- MAP ("plt@ha", (int) BFD_RELOC_HI16_S_PLTOFF),
- MAP ("sdarel", (int) BFD_RELOC_GPREL16),
- MAP ("sectoff", (int) BFD_RELOC_16_BASEREL),
- MAP ("sectoff@l", (int) BFD_RELOC_LO16_BASEREL),
- MAP ("sectoff@h", (int) BFD_RELOC_HI16_BASEREL),
- MAP ("sectoff@ha", (int) BFD_RELOC_HI16_S_BASEREL),
- MAP ("naddr", (int) BFD_RELOC_PPC_EMB_NADDR32),
- MAP ("naddr16", (int) BFD_RELOC_PPC_EMB_NADDR16),
- MAP ("naddr@l", (int) BFD_RELOC_PPC_EMB_NADDR16_LO),
- MAP ("naddr@h", (int) BFD_RELOC_PPC_EMB_NADDR16_HI),
- MAP ("naddr@ha", (int) BFD_RELOC_PPC_EMB_NADDR16_HA),
- MAP ("sdai16", (int) BFD_RELOC_PPC_EMB_SDAI16),
- MAP ("sda2rel", (int) BFD_RELOC_PPC_EMB_SDA2REL),
- MAP ("sda2i16", (int) BFD_RELOC_PPC_EMB_SDA2I16),
- MAP ("sda21", (int) BFD_RELOC_PPC_EMB_SDA21),
- MAP ("mrkref", (int) BFD_RELOC_PPC_EMB_MRKREF),
- MAP ("relsect", (int) BFD_RELOC_PPC_EMB_RELSEC16),
- MAP ("relsect@l", (int) BFD_RELOC_PPC_EMB_RELST_LO),
- MAP ("relsect@h", (int) BFD_RELOC_PPC_EMB_RELST_HI),
- MAP ("relsect@ha", (int) BFD_RELOC_PPC_EMB_RELST_HA),
- MAP ("bitfld", (int) BFD_RELOC_PPC_EMB_BIT_FLD),
- MAP ("relsda", (int) BFD_RELOC_PPC_EMB_RELSDA),
- MAP ("xgot", (int) BFD_RELOC_PPC_TOC16),
- /* The following are only valid for ppc64. Negative values are
- used instead of a flag. */
- MAP ("higher", - (int) BFD_RELOC_PPC64_HIGHER),
- MAP ("highera", - (int) BFD_RELOC_PPC64_HIGHER_S),
- MAP ("highest", - (int) BFD_RELOC_PPC64_HIGHEST),
- MAP ("highesta", - (int) BFD_RELOC_PPC64_HIGHEST_S),
- MAP ("tocbase", - (int) BFD_RELOC_PPC64_TOC),
- MAP ("toc", - (int) BFD_RELOC_PPC_TOC16),
- MAP ("toc@l", - (int) BFD_RELOC_PPC64_TOC16_LO),
- MAP ("toc@h", - (int) BFD_RELOC_PPC64_TOC16_HI),
- MAP ("toc@ha", - (int) BFD_RELOC_PPC64_TOC16_HA),
- { (char *) 0, 0, (int) BFD_RELOC_UNUSED }
+ MAP ("l", BFD_RELOC_LO16),
+ MAP ("h", BFD_RELOC_HI16),
+ MAP ("ha", BFD_RELOC_HI16_S),
+ MAP ("brtaken", BFD_RELOC_PPC_B16_BRTAKEN),
+ MAP ("brntaken", BFD_RELOC_PPC_B16_BRNTAKEN),
+ MAP ("got", BFD_RELOC_16_GOTOFF),
+ MAP ("got@l", BFD_RELOC_LO16_GOTOFF),
+ MAP ("got@h", BFD_RELOC_HI16_GOTOFF),
+ MAP ("got@ha", BFD_RELOC_HI16_S_GOTOFF),
+ MAP ("plt@l", BFD_RELOC_LO16_PLTOFF),
+ MAP ("plt@h", BFD_RELOC_HI16_PLTOFF),
+ MAP ("plt@ha", BFD_RELOC_HI16_S_PLTOFF),
+ MAP ("copy", BFD_RELOC_PPC_COPY),
+ MAP ("globdat", BFD_RELOC_PPC_GLOB_DAT),
+ MAP ("sectoff", BFD_RELOC_16_BASEREL),
+ MAP ("sectoff@l", BFD_RELOC_LO16_BASEREL),
+ MAP ("sectoff@h", BFD_RELOC_HI16_BASEREL),
+ MAP ("sectoff@ha", BFD_RELOC_HI16_S_BASEREL),
+ MAP ("tls", BFD_RELOC_PPC_TLS),
+ MAP ("dtpmod", BFD_RELOC_PPC_DTPMOD),
+ MAP ("dtprel", BFD_RELOC_PPC_DTPREL),
+ MAP ("dtprel@l", BFD_RELOC_PPC_DTPREL16_LO),
+ MAP ("dtprel@h", BFD_RELOC_PPC_DTPREL16_HI),
+ MAP ("dtprel@ha", BFD_RELOC_PPC_DTPREL16_HA),
+ MAP ("tprel", BFD_RELOC_PPC_TPREL),
+ MAP ("tprel@l", BFD_RELOC_PPC_TPREL16_LO),
+ MAP ("tprel@h", BFD_RELOC_PPC_TPREL16_HI),
+ MAP ("tprel@ha", BFD_RELOC_PPC_TPREL16_HA),
+ MAP ("got@tlsgd", BFD_RELOC_PPC_GOT_TLSGD16),
+ MAP ("got@tlsgd@l", BFD_RELOC_PPC_GOT_TLSGD16_LO),
+ MAP ("got@tlsgd@h", BFD_RELOC_PPC_GOT_TLSGD16_HI),
+ MAP ("got@tlsgd@ha", BFD_RELOC_PPC_GOT_TLSGD16_HA),
+ MAP ("got@tlsld", BFD_RELOC_PPC_GOT_TLSLD16),
+ MAP ("got@tlsld@l", BFD_RELOC_PPC_GOT_TLSLD16_LO),
+ MAP ("got@tlsld@h", BFD_RELOC_PPC_GOT_TLSLD16_HI),
+ MAP ("got@tlsld@ha", BFD_RELOC_PPC_GOT_TLSLD16_HA),
+ MAP ("got@dtprel", BFD_RELOC_PPC_GOT_DTPREL16),
+ MAP ("got@dtprel@l", BFD_RELOC_PPC_GOT_DTPREL16_LO),
+ MAP ("got@dtprel@h", BFD_RELOC_PPC_GOT_DTPREL16_HI),
+ MAP ("got@dtprel@ha", BFD_RELOC_PPC_GOT_DTPREL16_HA),
+ MAP ("got@tprel", BFD_RELOC_PPC_GOT_TPREL16),
+ MAP ("got@tprel@l", BFD_RELOC_PPC_GOT_TPREL16_LO),
+ MAP ("got@tprel@h", BFD_RELOC_PPC_GOT_TPREL16_HI),
+ MAP ("got@tprel@ha", BFD_RELOC_PPC_GOT_TPREL16_HA),
+ MAP32 ("fixup", BFD_RELOC_CTOR),
+ MAP32 ("plt", BFD_RELOC_24_PLT_PCREL),
+ MAP32 ("pltrel24", BFD_RELOC_24_PLT_PCREL),
+ MAP32 ("local24pc", BFD_RELOC_PPC_LOCAL24PC),
+ MAP32 ("local", BFD_RELOC_PPC_LOCAL24PC),
+ MAP32 ("pltrel", BFD_RELOC_32_PLT_PCREL),
+ MAP32 ("sdarel", BFD_RELOC_GPREL16),
+ MAP32 ("naddr", BFD_RELOC_PPC_EMB_NADDR32),
+ MAP32 ("naddr16", BFD_RELOC_PPC_EMB_NADDR16),
+ MAP32 ("naddr@l", BFD_RELOC_PPC_EMB_NADDR16_LO),
+ MAP32 ("naddr@h", BFD_RELOC_PPC_EMB_NADDR16_HI),
+ MAP32 ("naddr@ha", BFD_RELOC_PPC_EMB_NADDR16_HA),
+ MAP32 ("sdai16", BFD_RELOC_PPC_EMB_SDAI16),
+ MAP32 ("sda2rel", BFD_RELOC_PPC_EMB_SDA2REL),
+ MAP32 ("sda2i16", BFD_RELOC_PPC_EMB_SDA2I16),
+ MAP32 ("sda21", BFD_RELOC_PPC_EMB_SDA21),
+ MAP32 ("mrkref", BFD_RELOC_PPC_EMB_MRKREF),
+ MAP32 ("relsect", BFD_RELOC_PPC_EMB_RELSEC16),
+ MAP32 ("relsect@l", BFD_RELOC_PPC_EMB_RELST_LO),
+ MAP32 ("relsect@h", BFD_RELOC_PPC_EMB_RELST_HI),
+ MAP32 ("relsect@ha", BFD_RELOC_PPC_EMB_RELST_HA),
+ MAP32 ("bitfld", BFD_RELOC_PPC_EMB_BIT_FLD),
+ MAP32 ("relsda", BFD_RELOC_PPC_EMB_RELSDA),
+ MAP32 ("xgot", BFD_RELOC_PPC_TOC16),
+ MAP64 ("higher", BFD_RELOC_PPC64_HIGHER),
+ MAP64 ("highera", BFD_RELOC_PPC64_HIGHER_S),
+ MAP64 ("highest", BFD_RELOC_PPC64_HIGHEST),
+ MAP64 ("highesta", BFD_RELOC_PPC64_HIGHEST_S),
+ MAP64 ("tocbase", BFD_RELOC_PPC64_TOC),
+ MAP64 ("toc", BFD_RELOC_PPC_TOC16),
+ MAP64 ("toc@l", BFD_RELOC_PPC64_TOC16_LO),
+ MAP64 ("toc@h", BFD_RELOC_PPC64_TOC16_HI),
+ MAP64 ("toc@ha", BFD_RELOC_PPC64_TOC16_HA),
+ MAP64 ("dtprel@higher", BFD_RELOC_PPC64_DTPREL16_HIGHER),
+ MAP64 ("dtprel@highera", BFD_RELOC_PPC64_DTPREL16_HIGHERA),
+ MAP64 ("dtprel@highest", BFD_RELOC_PPC64_DTPREL16_HIGHEST),
+ MAP64 ("dtprel@highesta", BFD_RELOC_PPC64_DTPREL16_HIGHESTA),
+ MAP64 ("tprel@higher", BFD_RELOC_PPC64_TPREL16_HIGHER),
+ MAP64 ("tprel@highera", BFD_RELOC_PPC64_TPREL16_HIGHERA),
+ MAP64 ("tprel@highest", BFD_RELOC_PPC64_TPREL16_HIGHEST),
+ MAP64 ("tprel@highesta", BFD_RELOC_PPC64_TPREL16_HIGHESTA),
+ { (char *) 0, 0, 0, 0, BFD_RELOC_UNUSED }
};
if (*str++ != '@')
@@ -1435,23 +1617,18 @@ ppc_elf_suffix (str_p, exp_p)
for (ptr = &mapping[0]; ptr->length > 0; ptr++)
if (ch == ptr->string[0]
&& len == ptr->length
- && memcmp (ident, ptr->string, ptr->length) == 0)
+ && memcmp (ident, ptr->string, ptr->length) == 0
+ && (ppc_obj64 ? ptr->valid64 : ptr->valid32))
{
int reloc = ptr->reloc;
- if (reloc < 0)
- {
- if (!ppc_obj64)
- return BFD_RELOC_UNUSED;
- reloc = -reloc;
- }
-
- if (exp_p->X_add_number != 0
- && (reloc == (int) BFD_RELOC_16_GOTOFF
- || reloc == (int) BFD_RELOC_LO16_GOTOFF
- || reloc == (int) BFD_RELOC_HI16_GOTOFF
- || reloc == (int) BFD_RELOC_HI16_S_GOTOFF))
- as_warn (_("identifier+constant@got means identifier@got+constant"));
+ if (!ppc_obj64)
+ if (exp_p->X_add_number != 0
+ && (reloc == (int) BFD_RELOC_16_GOTOFF
+ || reloc == (int) BFD_RELOC_LO16_GOTOFF
+ || reloc == (int) BFD_RELOC_HI16_GOTOFF
+ || reloc == (int) BFD_RELOC_HI16_S_GOTOFF))
+ as_warn (_("identifier+constant@got means identifier@got+constant"));
/* Now check for identifier@suffix+constant. */
if (*str == '-' || *str == '+')
@@ -1473,11 +1650,11 @@ ppc_elf_suffix (str_p, exp_p)
*str_p = str;
if (reloc == (int) BFD_RELOC_PPC64_TOC
- && exp_p->X_op == O_symbol)
+ && exp_p->X_op == O_symbol
+ && strcmp (S_GET_NAME (exp_p->X_add_symbol), ".TOC.") == 0)
{
- /* This reloc type ignores the symbol. Change the symbol
- so that the dummy .TOC. symbol can be omitted from the
- object file. */
+ /* Change the symbol so that the dummy .TOC. symbol can be
+ omitted from the object file. */
exp_p->X_add_symbol = &abs_symbol;
}
@@ -1858,6 +2035,40 @@ parse_toc_entry (toc_kind)
#endif
+#ifdef OBJ_ELF
+#define APUID(a,v) ((((a) & 0xffff) << 16) | ((v) & 0xffff))
+static void
+ppc_apuinfo_section_add (apu, version)
+ unsigned int apu, version;
+{
+ unsigned int i;
+
+ /* Check we don't already exist. */
+ for (i = 0; i < ppc_apuinfo_num; i++)
+ if (ppc_apuinfo_list[i] == APUID (apu, version))
+ return;
+
+ if (ppc_apuinfo_num == ppc_apuinfo_num_alloc)
+ {
+ if (ppc_apuinfo_num_alloc == 0)
+ {
+ ppc_apuinfo_num_alloc = 4;
+ ppc_apuinfo_list = (unsigned long *)
+ xmalloc (sizeof (unsigned long) * ppc_apuinfo_num_alloc);
+ }
+ else
+ {
+ ppc_apuinfo_num_alloc += 4;
+ ppc_apuinfo_list = (unsigned long *) xrealloc (ppc_apuinfo_list,
+ sizeof (unsigned long) * ppc_apuinfo_num_alloc);
+ }
+ }
+ ppc_apuinfo_list[ppc_apuinfo_num++] = APUID (apu, version);
+}
+#undef APUID
+#endif
+
+
/* We need to keep a list of fixups. We can't simply generate them as
we go, because that would require us to first create the frag, and
that would screw up references to ``.''. */
@@ -1921,13 +2132,14 @@ md_assemble (str)
/* PowerPC operands are just expressions. The only real issue is
that a few operand types are optional. All cases which might use
- an optional operand separate the operands only with commas (in
- some cases parentheses are used, as in ``lwz 1,0(1)'' but such
- cases never have optional operands). There is never more than
- one optional operand for an instruction. So, before we start
- seriously parsing the operands, we check to see if we have an
- optional operand, and, if we do, we count the number of commas to
- see whether the operand should be omitted. */
+ an optional operand separate the operands only with commas (in some
+ cases parentheses are used, as in ``lwz 1,0(1)'' but such cases never
+ have optional operands). Most instructions with optional operands
+ have only one. Those that have more than one optional operand can
+ take either all their operands or none. So, before we start seriously
+ parsing the operands, we check to see if we have optional operands,
+ and if we do, we count the number of commas to see which operands
+ have been omitted. */
skip_optional = 0;
for (opindex_ptr = opcode->operands; *opindex_ptr != 0; opindex_ptr++)
{
@@ -1963,7 +2175,7 @@ md_assemble (str)
/* If there are fewer operands in the line then are called
for by the instruction, we want to skip the optional
- operand. */
+ operands. */
if (opcount < num_operands_expected)
skip_optional = 1;
@@ -1990,7 +2202,6 @@ md_assemble (str)
operand = &powerpc_operands[next_opindex];
next_opindex = 0;
}
-
errmsg = NULL;
/* If this is a fake operand, then we do not expect anything
@@ -2141,9 +2352,9 @@ md_assemble (str)
if (! register_name (&ex))
{
if ((operand->flags & PPC_OPERAND_CR) != 0)
- cr_operand = true;
+ cr_operand = TRUE;
expression (&ex);
- cr_operand = false;
+ cr_operand = FALSE;
}
}
@@ -2231,6 +2442,25 @@ md_assemble (str)
#ifdef OBJ_ELF
else if ((reloc = ppc_elf_suffix (&str, &ex)) != BFD_RELOC_UNUSED)
{
+ /* Some TLS tweaks. */
+ switch (reloc)
+ {
+ default:
+ break;
+ case BFD_RELOC_PPC_TLS:
+ insn = ppc_insert_operand (insn, operand, ppc_obj64 ? 13 : 2,
+ (char *) NULL, 0);
+ break;
+ /* We'll only use the 32 (or 64) bit form of these relocations
+ in constants. Instructions get the 16 bit form. */
+ case BFD_RELOC_PPC_DTPREL:
+ reloc = BFD_RELOC_PPC_DTPREL16;
+ break;
+ case BFD_RELOC_PPC_TPREL:
+ reloc = BFD_RELOC_PPC_TPREL16;
+ break;
+ }
+
/* For the absolute forms of branches, convert the PC
relative form back into the absolute. */
if ((operand->flags & PPC_OPERAND_ABSOLUTE) != 0)
@@ -2255,7 +2485,7 @@ md_assemble (str)
}
if (ppc_obj64
- && (operand->flags & PPC_OPERAND_DS) != 0)
+ && (operand->flags & (PPC_OPERAND_DS | PPC_OPERAND_DQ)) != 0)
{
switch (reloc)
{
@@ -2292,6 +2522,23 @@ md_assemble (str)
case BFD_RELOC_PPC64_PLTGOT16_LO:
reloc = BFD_RELOC_PPC64_PLTGOT16_LO_DS;
break;
+ case BFD_RELOC_PPC_DTPREL16:
+ reloc = BFD_RELOC_PPC64_DTPREL16_DS;
+ break;
+ case BFD_RELOC_PPC_DTPREL16_LO:
+ reloc = BFD_RELOC_PPC64_DTPREL16_LO_DS;
+ break;
+ case BFD_RELOC_PPC_TPREL16:
+ reloc = BFD_RELOC_PPC64_TPREL16_DS;
+ break;
+ case BFD_RELOC_PPC_TPREL16_LO:
+ reloc = BFD_RELOC_PPC64_TPREL16_LO_DS;
+ break;
+ case BFD_RELOC_PPC_GOT_DTPREL16:
+ case BFD_RELOC_PPC_GOT_DTPREL16_LO:
+ case BFD_RELOC_PPC_GOT_TPREL16:
+ case BFD_RELOC_PPC_GOT_TPREL16_LO:
+ break;
default:
as_bad (_("unsupported relocation for DS offset field"));
break;
@@ -2351,6 +2598,31 @@ md_assemble (str)
if (*str != '\0')
as_bad (_("junk at end of line: `%s'"), str);
+#ifdef OBJ_ELF
+ /* Do we need/want a APUinfo section? */
+ if (ppc_cpu & (PPC_OPCODE_SPE
+ | PPC_OPCODE_ISEL | PPC_OPCODE_EFS
+ | PPC_OPCODE_BRLOCK | PPC_OPCODE_PMR | PPC_OPCODE_CACHELCK
+ | PPC_OPCODE_RFMCI))
+ {
+ /* These are all version "1". */
+ if (opcode->flags & PPC_OPCODE_SPE)
+ ppc_apuinfo_section_add (PPC_APUINFO_SPE, 1);
+ if (opcode->flags & PPC_OPCODE_ISEL)
+ ppc_apuinfo_section_add (PPC_APUINFO_ISEL, 1);
+ if (opcode->flags & PPC_OPCODE_EFS)
+ ppc_apuinfo_section_add (PPC_APUINFO_EFS, 1);
+ if (opcode->flags & PPC_OPCODE_BRLOCK)
+ ppc_apuinfo_section_add (PPC_APUINFO_BRLOCK, 1);
+ if (opcode->flags & PPC_OPCODE_PMR)
+ ppc_apuinfo_section_add (PPC_APUINFO_PMR, 1);
+ if (opcode->flags & PPC_OPCODE_CACHELCK)
+ ppc_apuinfo_section_add (PPC_APUINFO_CACHELCK, 1);
+ if (opcode->flags & PPC_OPCODE_RFMCI)
+ ppc_apuinfo_section_add (PPC_APUINFO_RFMCI, 1);
+ }
+#endif
+
/* Write out the instruction. */
f = frag_more (4);
md_number_to_chars (f, insn, 4);
@@ -2518,7 +2790,7 @@ ppc_section_letter (letter, ptr_msg)
return SHF_EXCLUDE;
*ptr_msg = _("Bad .section directive: want a,e,w,x,M,S,G,T in string");
- return 0;
+ return -1;
}
int
@@ -2603,11 +2875,11 @@ ppc_byte (ignore)
/* This is set if we are creating a .stabx symbol, since we don't want
to handle symbol suffixes for such symbols. */
-static boolean ppc_stab_symbol;
+static bfd_boolean ppc_stab_symbol;
/* The .comm and .lcomm pseudo-ops for XCOFF. XCOFF puts common
symbols in the .bss segment as though they were local common
- symbols, and uses a different smclas. The native Aix 4.3.3 assember
+ symbols, and uses a different smclas. The native Aix 4.3.3 assembler
aligns .comm and .lcomm to 4 bytes. */
static void
@@ -2772,6 +3044,7 @@ ppc_csect (ignore)
char *name;
char endc;
symbolS *sym;
+ offsetT align;
name = input_line_pointer;
endc = get_symbol_end ();
@@ -2786,22 +3059,24 @@ ppc_csect (ignore)
symbol_get_tc (sym)->class = XMC_PR;
}
- ppc_change_csect (sym);
-
+ align = 2;
if (*input_line_pointer == ',')
{
++input_line_pointer;
- symbol_get_tc (sym)->align = get_absolute_expression ();
+ align = get_absolute_expression ();
}
+ ppc_change_csect (sym, align);
+
demand_empty_rest_of_line ();
}
/* Change to a different csect. */
static void
-ppc_change_csect (sym)
+ppc_change_csect (sym, align)
symbolS *sym;
+ offsetT align;
{
if (S_IS_DEFINED (sym))
subseg_set (S_GET_SEGMENT (sym), symbol_get_tc (sym)->subseg);
@@ -2811,11 +3086,14 @@ ppc_change_csect (sym)
int after_toc;
int hold_chunksize;
symbolS *list;
+ int is_code;
+ segT sec;
/* This is a new csect. We need to look at the symbol class to
figure out whether it should go in the text section or the
data section. */
after_toc = 0;
+ is_code = 0;
switch (symbol_get_tc (sym)->class)
{
case XMC_PR:
@@ -2830,6 +3108,7 @@ ppc_change_csect (sym)
symbol_get_tc (sym)->subseg = ppc_text_subsegment;
++ppc_text_subsegment;
list_ptr = &ppc_text_csects;
+ is_code = 1;
break;
case XMC_RW:
case XMC_TC0:
@@ -2857,18 +3136,24 @@ ppc_change_csect (sym)
hold_chunksize = chunksize;
chunksize = 64;
- subseg_new (segment_name (S_GET_SEGMENT (sym)),
- symbol_get_tc (sym)->subseg);
+ sec = subseg_new (segment_name (S_GET_SEGMENT (sym)),
+ symbol_get_tc (sym)->subseg);
chunksize = hold_chunksize;
if (after_toc)
ppc_after_toc_frag = frag_now;
+ record_alignment (sec, align);
+ if (is_code)
+ frag_align_code (align, 0);
+ else
+ frag_align (align, 0, 0);
+
symbol_set_frag (sym, frag_now);
S_SET_VALUE (sym, (valueT) frag_now_fix ());
- symbol_get_tc (sym)->align = 2;
+ symbol_get_tc (sym)->align = align;
symbol_get_tc (sym)->output = 1;
symbol_get_tc (sym)->within = sym;
@@ -2906,7 +3191,7 @@ ppc_section (type)
sym = symbol_find_or_make (name);
- ppc_change_csect (sym);
+ ppc_change_csect (sym, 2);
demand_empty_rest_of_line ();
}
@@ -2943,7 +3228,7 @@ ppc_named_section (ignore)
sym = symbol_find_or_make (real_name);
- ppc_change_csect (sym);
+ ppc_change_csect (sym, 2);
demand_empty_rest_of_line ();
}
@@ -3046,9 +3331,9 @@ ppc_stabx (ignore)
}
++input_line_pointer;
- ppc_stab_symbol = true;
+ ppc_stab_symbol = TRUE;
sym = symbol_make (name);
- ppc_stab_symbol = false;
+ ppc_stab_symbol = FALSE;
symbol_get_tc (sym)->real_name = name;
@@ -3149,7 +3434,7 @@ ppc_stabx (ignore)
/* The .function pseudo-op. This takes several arguments. The first
argument seems to be the external name of the symbol. The second
- argment seems to be the label for the start of the function. gcc
+ argument seems to be the label for the start of the function. gcc
uses the same name for both. I have no idea what the third and
fourth arguments are meant to be. The optional fifth argument is
an expression for the size of the function. In COFF this symbol
@@ -3614,7 +3899,7 @@ ppc_vbyte (dummy)
give to this location in the toc; this will be a symbol with class
TC. The rest of the arguments are N-byte values to actually put at
this location in the TOC; often there is just one more argument, a
- relocateable symbol reference. The size of the value to store
+ relocatable symbol reference. The size of the value to store
depends on target word size. A 32-bit target uses 4-byte values, a
64-bit target uses 8-byte values.
@@ -3707,18 +3992,67 @@ ppc_tc (ignore)
}
/* Pseudo-op .machine. */
-/* FIXME: `.machine' is a nop for the moment. It would be nice to
- accept this directive on the first line of input and set ppc_obj64
- and the target format accordingly. Unfortunately, the target
- format is selected in output-file.c:output_file_create before we
- even get to md_begin, so it's not possible without changing
- as.c:main. */
static void
ppc_machine (ignore)
int ignore ATTRIBUTE_UNUSED;
{
- discard_rest_of_line ();
+ char *cpu_string;
+#define MAX_HISTORY 100
+ static unsigned long *cpu_history;
+ static int curr_hist;
+
+ SKIP_WHITESPACE ();
+
+ if (*input_line_pointer == '"')
+ {
+ int len;
+ cpu_string = demand_copy_C_string (&len);
+ }
+ else
+ {
+ char c;
+ cpu_string = input_line_pointer;
+ c = get_symbol_end ();
+ cpu_string = xstrdup (cpu_string);
+ *input_line_pointer = c;
+ }
+
+ if (cpu_string != NULL)
+ {
+ unsigned long old_cpu = ppc_cpu;
+ char *p;
+
+ for (p = cpu_string; *p != 0; p++)
+ *p = TOLOWER (*p);
+
+ if (strcmp (cpu_string, "push") == 0)
+ {
+ if (cpu_history == NULL)
+ cpu_history = xmalloc (MAX_HISTORY * sizeof (*cpu_history));
+
+ if (curr_hist >= MAX_HISTORY)
+ as_bad (_(".machine stack overflow"));
+ else
+ cpu_history[curr_hist++] = ppc_cpu;
+ }
+ else if (strcmp (cpu_string, "pop") == 0)
+ {
+ if (curr_hist <= 0)
+ as_bad (_(".machine stack underflow"));
+ else
+ ppc_cpu = cpu_history[--curr_hist];
+ }
+ else if (parse_cpu (cpu_string))
+ ;
+ else
+ as_bad (_("invalid machine `%s'"), cpu_string);
+
+ if (ppc_cpu != old_cpu)
+ ppc_setup_opcodes ();
+ }
+
+ demand_empty_rest_of_line ();
}
/* See whether a symbol is in the TOC section. */
@@ -3777,11 +4111,11 @@ ppc_previous (ignore)
/* pseudo-op: .pdata
behaviour: predefined read only data section
- double word aligned
+ double word aligned
errors: None
warnings: None
initial: .section .pdata "adr3"
- a - don't know -- maybe a misprint
+ a - don't know -- maybe a misprint
d - initialized data
r - readable
3 - double word aligned (that would be 4 byte boundary)
@@ -3813,11 +4147,11 @@ ppc_pdata (ignore)
/* pseudo-op: .ydata
behaviour: predefined read only data section
- double word aligned
+ double word aligned
errors: None
warnings: None
initial: .section .ydata "drw3"
- a - don't know -- maybe a misprint
+ a - don't know -- maybe a misprint
d - initialized data
r - readable
3 - double word aligned (that would be 4 byte boundary)
@@ -3847,7 +4181,7 @@ ppc_ydata (ignore)
/* pseudo-op: .reldata
behaviour: predefined read write data section
- double word aligned (4-byte)
+ double word aligned (4-byte)
FIXME: relocation is applied to it
FIXME: what's the difference between this and .data?
errors: None
@@ -3885,7 +4219,7 @@ ppc_reldata (ignore)
/* pseudo-op: .rdata
behaviour: predefined read only data section
- double word aligned
+ double word aligned
errors: None
warnings: None
initial: .section .rdata "dr3"
@@ -3915,7 +4249,7 @@ ppc_rdata (ignore)
/* pseudo-op: .ualong
behaviour: much like .int, with the exception that no alignment is
- performed.
+ performed.
FIXME: test the alignment statement
errors: None
warnings: None */
@@ -3930,7 +4264,7 @@ ppc_ualong (ignore)
/* pseudo-op: .znop <symbol name>
behaviour: Issue a nop instruction
- Issue a IMAGE_REL_PPC_IFGLUE relocation against it, using
+ Issue a IMAGE_REL_PPC_IFGLUE relocation against it, using
the supplied symbol name.
errors: None
warnings: Missing symbol name */
@@ -4492,7 +4826,7 @@ ppc_frob_label (sym)
seen. It tells ppc_adjust_symtab whether it needs to look through
the symbols. */
-static boolean ppc_saw_abs;
+static bfd_boolean ppc_saw_abs;
/* Change the name of a symbol just before writing it out. Set the
real name if the .rename pseudo-op was used. Otherwise, remove any
@@ -4515,6 +4849,10 @@ ppc_frob_symbol (sym)
&& S_GET_STORAGE_CLASS (sym) != C_FILE)))
return 1;
+ /* This one will disappear anyway. Don't make a csect sym for it. */
+ if (sym == abs_section_sym)
+ return 1;
+
if (symbol_get_tc (sym)->real_name != (char *) NULL)
S_SET_NAME (sym, symbol_get_tc (sym)->real_name);
else
@@ -4631,7 +4969,7 @@ ppc_frob_symbol (sym)
{
/* This is an absolute symbol. The csect will be created by
ppc_adjust_symtab. */
- ppc_saw_abs = true;
+ ppc_saw_abs = TRUE;
a->x_csect.x_smtyp = XTY_LD;
if (symbol_get_tc (sym)->class == -1)
symbol_get_tc (sym)->class = XMC_XO;
@@ -4727,10 +5065,10 @@ ppc_frob_symbol (sym)
/* We want the value to be the symbol index of the referenced
csect symbol. BFD will do that for us if we set the right
flags. */
- S_SET_VALUE (sym,
- ((valueT)
- coffsymbol (symbol_get_bfdsym
- (symbol_get_tc (sym)->within))->native));
+ asymbol *bsym = symbol_get_bfdsym (symbol_get_tc (sym)->within);
+ combined_entry_type *c = coffsymbol (bsym)->native;
+
+ S_SET_VALUE (sym, (valueT) (size_t) c);
coffsymbol (symbol_get_bfdsym (sym))->native->fix_value = 1;
}
else if (S_GET_STORAGE_CLASS (sym) == C_STSYM)
@@ -4799,7 +5137,7 @@ ppc_adjust_symtab ()
coffsymbol (symbol_get_bfdsym (sym))->native[i].fix_scnlen = 1;
}
- ppc_saw_abs = false;
+ ppc_saw_abs = FALSE;
}
/* Set the VMA for a section. This is called on all the sections in
@@ -4809,8 +5147,9 @@ void
ppc_frob_section (sec)
asection *sec;
{
- static bfd_size_type vma = 0;
+ static bfd_vma vma = 0;
+ vma = md_section_align (sec, vma);
bfd_set_section_vma (stdoutput, sec, vma);
vma += bfd_section_size (stdoutput, sec);
}
@@ -4956,14 +5295,16 @@ int
ppc_fix_adjustable (fix)
fixS *fix;
{
- valueT val;
+ valueT val = resolve_symbol_value (fix->fx_addsy);
+ segT symseg = S_GET_SEGMENT (fix->fx_addsy);
+ TC_SYMFIELD_TYPE *tc;
+
+ if (symseg == absolute_section)
+ return 0;
- resolve_symbol_value (fix->fx_addsy);
- val = S_GET_VALUE (fix->fx_addsy);
if (ppc_toc_csect != (symbolS *) NULL
- && fix->fx_addsy != (symbolS *) NULL
&& fix->fx_addsy != ppc_toc_csect
- && S_GET_SEGMENT (fix->fx_addsy) == data_section
+ && symseg == data_section
&& val >= ppc_toc_frag->fr_address
&& (ppc_after_toc_frag == (fragS *) NULL
|| val < ppc_after_toc_frag->fr_address))
@@ -4974,12 +5315,13 @@ ppc_fix_adjustable (fix)
sy != (symbolS *) NULL;
sy = symbol_next (sy))
{
- if (symbol_get_tc (sy)->class == XMC_TC0)
+ TC_SYMFIELD_TYPE *sy_tc = symbol_get_tc (sy);
+
+ if (sy_tc->class == XMC_TC0)
continue;
- if (symbol_get_tc (sy)->class != XMC_TC)
+ if (sy_tc->class != XMC_TC)
break;
- resolve_symbol_value (sy);
- if (val == S_GET_VALUE (sy))
+ if (val == resolve_symbol_value (sy))
{
fix->fx_addsy = sy;
fix->fx_addnumber = val - ppc_toc_frag->fr_address;
@@ -4992,23 +5334,24 @@ ppc_fix_adjustable (fix)
}
/* Possibly adjust the reloc to be against the csect. */
- if (fix->fx_addsy != (symbolS *) NULL
- && symbol_get_tc (fix->fx_addsy)->subseg == 0
- && symbol_get_tc (fix->fx_addsy)->class != XMC_TC0
- && symbol_get_tc (fix->fx_addsy)->class != XMC_TC
- && S_GET_SEGMENT (fix->fx_addsy) != bss_section
+ tc = symbol_get_tc (fix->fx_addsy);
+ if (tc->subseg == 0
+ && tc->class != XMC_TC0
+ && tc->class != XMC_TC
+ && symseg != bss_section
/* Don't adjust if this is a reloc in the toc section. */
- && (S_GET_SEGMENT (fix->fx_addsy) != data_section
+ && (symseg != data_section
|| ppc_toc_csect == NULL
|| val < ppc_toc_frag->fr_address
|| (ppc_after_toc_frag != NULL
&& val >= ppc_after_toc_frag->fr_address)))
{
symbolS *csect;
+ symbolS *next_csect;
- if (S_GET_SEGMENT (fix->fx_addsy) == text_section)
+ if (symseg == text_section)
csect = ppc_text_csects;
- else if (S_GET_SEGMENT (fix->fx_addsy) == data_section)
+ else if (symseg == data_section)
csect = ppc_data_csects;
else
abort ();
@@ -5018,16 +5361,15 @@ ppc_fix_adjustable (fix)
if (csect != (symbolS *) NULL)
{
- while (symbol_get_tc (csect)->next != (symbolS *) NULL
- && (symbol_get_frag (symbol_get_tc (csect)->next)->fr_address
- <= val))
+ while ((next_csect = symbol_get_tc (csect)->next) != (symbolS *) NULL
+ && (symbol_get_frag (next_csect)->fr_address <= val))
{
/* If the csect address equals the symbol value, then we
have to look through the full symbol table to see
whether this is the csect we want. Note that we will
only get here if the csect has zero length. */
- if ((symbol_get_frag (csect)->fr_address == val)
- && S_GET_VALUE (csect) == S_GET_VALUE (fix->fx_addsy))
+ if (symbol_get_frag (csect)->fr_address == val
+ && S_GET_VALUE (csect) == val)
{
symbolS *scan;
@@ -5047,26 +5389,24 @@ ppc_fix_adjustable (fix)
break;
}
- csect = symbol_get_tc (csect)->next;
+ csect = next_csect;
}
- fix->fx_offset += (S_GET_VALUE (fix->fx_addsy)
- - symbol_get_frag (csect)->fr_address);
+ fix->fx_offset += val - symbol_get_frag (csect)->fr_address;
fix->fx_addsy = csect;
}
+ return 0;
}
/* Adjust a reloc against a .lcomm symbol to be against the base
.lcomm. */
- if (fix->fx_addsy != (symbolS *) NULL
- && S_GET_SEGMENT (fix->fx_addsy) == bss_section
+ if (symseg == bss_section
&& ! S_IS_EXTERNAL (fix->fx_addsy))
{
- resolve_symbol_value (symbol_get_frag (fix->fx_addsy)->fr_symbol);
- fix->fx_offset +=
- (S_GET_VALUE (fix->fx_addsy)
- - S_GET_VALUE (symbol_get_frag (fix->fx_addsy)->fr_symbol));
- fix->fx_addsy = symbol_get_frag (fix->fx_addsy)->fr_symbol;
+ symbolS *sy = symbol_get_frag (fix->fx_addsy)->fr_symbol;
+
+ fix->fx_offset += val - resolve_symbol_value (sy);
+ fix->fx_addsy = sy;
}
return 0;
@@ -5094,12 +5434,40 @@ ppc_force_relocation (fix)
<= fix->fx_frag->fr_address))))
return 1;
- return 0;
+ return generic_force_reloc (fix);
}
#endif /* OBJ_XCOFF */
#ifdef OBJ_ELF
+/* If this function returns non-zero, it guarantees that a relocation
+ will be emitted for a fixup. */
+
+int
+ppc_force_relocation (fix)
+ fixS *fix;
+{
+ /* Branch prediction relocations must force a relocation, as must
+ the vtable description relocs. */
+ switch (fix->fx_r_type)
+ {
+ case BFD_RELOC_PPC_B16_BRTAKEN:
+ case BFD_RELOC_PPC_B16_BRNTAKEN:
+ case BFD_RELOC_PPC_BA16_BRTAKEN:
+ case BFD_RELOC_PPC_BA16_BRNTAKEN:
+ case BFD_RELOC_PPC64_TOC:
+ return 1;
+ default:
+ break;
+ }
+
+ if (fix->fx_r_type >= BFD_RELOC_PPC_TLS
+ && fix->fx_r_type <= BFD_RELOC_PPC64_DTPREL16_HIGHESTA)
+ return 1;
+
+ return generic_force_reloc (fix);
+}
+
int
ppc_fix_adjustable (fix)
fixS *fix;
@@ -5111,8 +5479,8 @@ ppc_fix_adjustable (fix)
&& fix->fx_r_type != BFD_RELOC_GPREL16
&& fix->fx_r_type != BFD_RELOC_VTABLE_INHERIT
&& fix->fx_r_type != BFD_RELOC_VTABLE_ENTRY
- && ! S_IS_EXTERNAL (fix->fx_addsy)
- && ! S_IS_WEAK (fix->fx_addsy)
+ && !(fix->fx_r_type >= BFD_RELOC_PPC_TLS
+ && fix->fx_r_type <= BFD_RELOC_PPC64_DTPREL16_HIGHESTA)
&& (fix->fx_pcrel
|| (fix->fx_subsy != NULL
&& (S_GET_SEGMENT (fix->fx_subsy)
@@ -5141,32 +5509,22 @@ md_apply_fix3 (fixP, valP, seg)
#ifdef OBJ_ELF
if (fixP->fx_addsy != NULL)
{
- /* `*valuep' may contain the value of the symbol on which the reloc
- will be based; we have to remove it. */
- if (symbol_used_in_reloc_p (fixP->fx_addsy)
- && S_GET_SEGMENT (fixP->fx_addsy) != absolute_section
- && S_GET_SEGMENT (fixP->fx_addsy) != undefined_section
- && ! bfd_is_com_section (S_GET_SEGMENT (fixP->fx_addsy)))
- value -= S_GET_VALUE (fixP->fx_addsy);
-
- /* FIXME: Why '+'? Better yet, what exactly is '*valuep'
- supposed to be? I think this is related to various similar
- FIXMEs in tc-i386.c and tc-sparc.c. */
+ /* Hack around bfd_install_relocation brain damage. */
if (fixP->fx_pcrel)
value += fixP->fx_frag->fr_address + fixP->fx_where;
}
else
fixP->fx_done = 1;
#else
- /* FIXME FIXME FIXME: The value we are passed in *valuep includes
+ /* FIXME FIXME FIXME: The value we are passed in *valP includes
the symbol values. Since we are using BFD_ASSEMBLER, if we are
doing this relocation the code in write.c is going to call
bfd_install_relocation, which is also going to use the symbol
value. That means that if the reloc is fully resolved we want to
- use *valuep since bfd_install_relocation is not being used.
+ use *valP since bfd_install_relocation is not being used.
However, if the reloc is not fully resolved we do not want to use
- *valuep, and must use fx_offset instead. However, if the reloc
- is PC relative, we do want to use *valuep since it includes the
+ *valP, and must use fx_offset instead. However, if the reloc
+ is PC relative, we do want to use *valP since it includes the
result of md_pcrel_from. This is confusing. */
if (fixP->fx_addsy == (symbolS *) NULL)
fixP->fx_done = 1;
@@ -5175,21 +5533,14 @@ md_apply_fix3 (fixP, valP, seg)
;
else
+ value = fixP->fx_offset;
+#endif
+
+ if (fixP->fx_subsy != (symbolS *) NULL)
{
- value = fixP->fx_offset;
- if (fixP->fx_subsy != (symbolS *) NULL)
- {
- if (S_GET_SEGMENT (fixP->fx_subsy) == absolute_section)
- value -= S_GET_VALUE (fixP->fx_subsy);
- else
- {
- /* We can't actually support subtracting a symbol. */
- as_bad_where (fixP->fx_file, fixP->fx_line,
- _("expression too complex"));
- }
- }
+ /* We can't actually support subtracting a symbol. */
+ as_bad_where (fixP->fx_file, fixP->fx_line, _("expression too complex"));
}
-#endif
if ((int) fixP->fx_r_type >= (int) BFD_RELOC_UNUSED)
{
@@ -5278,15 +5629,26 @@ md_apply_fix3 (fixP, valP, seg)
#if defined (OBJ_XCOFF) || defined (OBJ_ELF)
else if ((operand->flags & PPC_OPERAND_PARENS) != 0
&& operand->bits == 16
- && operand->shift == 0
- && ppc_is_toc_sym (fixP->fx_addsy))
+ && operand->shift == 0)
{
- fixP->fx_r_type = BFD_RELOC_PPC_TOC16;
+ if (ppc_is_toc_sym (fixP->fx_addsy))
+ {
+ fixP->fx_r_type = BFD_RELOC_PPC_TOC16;
#ifdef OBJ_ELF
- if (ppc_obj64
- && (operand->flags & PPC_OPERAND_DS) != 0)
- fixP->fx_r_type = BFD_RELOC_PPC64_TOC16_DS;
+ if (ppc_obj64
+ && (operand->flags & PPC_OPERAND_DS) != 0)
+ fixP->fx_r_type = BFD_RELOC_PPC64_TOC16_DS;
+#endif
+ }
+ else
+ {
+ fixP->fx_r_type = BFD_RELOC_16;
+#ifdef OBJ_ELF
+ if (ppc_obj64
+ && (operand->flags & PPC_OPERAND_DS) != 0)
+ fixP->fx_r_type = BFD_RELOC_PPC64_ADDR16_DS;
#endif
+ }
fixP->fx_size = 2;
if (target_big_endian)
fixP->fx_where += 2;
@@ -5453,19 +5815,72 @@ md_apply_fix3 (fixP, valP, seg)
abort ();
{
unsigned char *where = fixP->fx_frag->fr_literal + fixP->fx_where;
- unsigned long val;
+ unsigned long val, mask;
if (target_big_endian)
- val = bfd_getb16 (where);
+ val = bfd_getb32 (where - 2);
else
- val = bfd_getl16 (where);
- val |= (value & 0xfffc);
+ val = bfd_getl32 (where);
+ mask = 0xfffc;
+ /* lq insns reserve the four lsbs. */
+ if ((ppc_cpu & PPC_OPCODE_POWER4) != 0
+ && (val & (0x3f << 26)) == (56u << 26))
+ mask = 0xfff0;
+ val |= value & mask;
if (target_big_endian)
bfd_putb16 ((bfd_vma) val, where);
else
bfd_putl16 ((bfd_vma) val, where);
}
break;
+
+ case BFD_RELOC_PPC_B16_BRTAKEN:
+ case BFD_RELOC_PPC_B16_BRNTAKEN:
+ case BFD_RELOC_PPC_BA16_BRTAKEN:
+ case BFD_RELOC_PPC_BA16_BRNTAKEN:
+ break;
+
+ case BFD_RELOC_PPC_TLS:
+ case BFD_RELOC_PPC_DTPMOD:
+ case BFD_RELOC_PPC_TPREL16:
+ case BFD_RELOC_PPC_TPREL16_LO:
+ case BFD_RELOC_PPC_TPREL16_HI:
+ case BFD_RELOC_PPC_TPREL16_HA:
+ case BFD_RELOC_PPC_TPREL:
+ case BFD_RELOC_PPC_DTPREL16:
+ case BFD_RELOC_PPC_DTPREL16_LO:
+ case BFD_RELOC_PPC_DTPREL16_HI:
+ case BFD_RELOC_PPC_DTPREL16_HA:
+ case BFD_RELOC_PPC_DTPREL:
+ case BFD_RELOC_PPC_GOT_TLSGD16:
+ case BFD_RELOC_PPC_GOT_TLSGD16_LO:
+ case BFD_RELOC_PPC_GOT_TLSGD16_HI:
+ case BFD_RELOC_PPC_GOT_TLSGD16_HA:
+ case BFD_RELOC_PPC_GOT_TLSLD16:
+ case BFD_RELOC_PPC_GOT_TLSLD16_LO:
+ case BFD_RELOC_PPC_GOT_TLSLD16_HI:
+ case BFD_RELOC_PPC_GOT_TLSLD16_HA:
+ case BFD_RELOC_PPC_GOT_TPREL16:
+ case BFD_RELOC_PPC_GOT_TPREL16_LO:
+ case BFD_RELOC_PPC_GOT_TPREL16_HI:
+ case BFD_RELOC_PPC_GOT_TPREL16_HA:
+ case BFD_RELOC_PPC_GOT_DTPREL16:
+ case BFD_RELOC_PPC_GOT_DTPREL16_LO:
+ case BFD_RELOC_PPC_GOT_DTPREL16_HI:
+ case BFD_RELOC_PPC_GOT_DTPREL16_HA:
+ case BFD_RELOC_PPC64_TPREL16_DS:
+ case BFD_RELOC_PPC64_TPREL16_LO_DS:
+ case BFD_RELOC_PPC64_TPREL16_HIGHER:
+ case BFD_RELOC_PPC64_TPREL16_HIGHERA:
+ case BFD_RELOC_PPC64_TPREL16_HIGHEST:
+ case BFD_RELOC_PPC64_TPREL16_HIGHESTA:
+ case BFD_RELOC_PPC64_DTPREL16_DS:
+ case BFD_RELOC_PPC64_DTPREL16_LO_DS:
+ case BFD_RELOC_PPC64_DTPREL16_HIGHER:
+ case BFD_RELOC_PPC64_DTPREL16_HIGHERA:
+ case BFD_RELOC_PPC64_DTPREL16_HIGHEST:
+ case BFD_RELOC_PPC64_DTPREL16_HIGHESTA:
+ break;
#endif
/* Because SDA21 modifies the register field, the size is set to 4
bytes, rather than 2, so offset it here appropriately. */
@@ -5480,10 +5895,19 @@ md_apply_fix3 (fixP, valP, seg)
case BFD_RELOC_8:
if (fixP->fx_pcrel)
- abort ();
-
- md_number_to_chars (fixP->fx_frag->fr_literal + fixP->fx_where,
- value, 1);
+ {
+ /* This can occur if there is a bug in the input assembler, eg:
+ ".byte <undefined_symbol> - ." */
+ if (fixP->fx_addsy)
+ as_bad (_("Unable to handle reference to symbol %s"),
+ S_GET_NAME (fixP->fx_addsy));
+ else
+ as_bad (_("Unable to resolve expression"));
+ fixP->fx_done = 1;
+ }
+ else
+ md_number_to_chars (fixP->fx_frag->fr_literal + fixP->fx_where,
+ value, 1);
break;
case BFD_RELOC_24_PLT_PCREL:
@@ -5591,3 +6015,49 @@ tc_gen_reloc (seg, fixp)
return reloc;
}
+
+void
+ppc_cfi_frame_initial_instructions ()
+{
+ cfi_add_CFA_def_cfa (1, 0);
+}
+
+int
+tc_ppc_regname_to_dw2regnum (const char *regname)
+{
+ unsigned int regnum = -1;
+ unsigned int i;
+ const char *p;
+ char *q;
+ static struct { char *name; int dw2regnum; } regnames[] =
+ {
+ { "sp", 1 }, { "r.sp", 1 }, { "rtoc", 2 }, { "r.toc", 2 },
+ { "mq", 64 }, { "lr", 65 }, { "ctr", 66 }, { "ap", 67 },
+ { "cc", 68 }, { "xer", 76 }, { "vrsave", 109 }, { "vscr", 110 },
+ { "spe_acc", 111 }, { "spefscr", 112 }
+ };
+
+ for (i = 0; i < ARRAY_SIZE (regnames); ++i)
+ if (strcmp (regnames[i].name, regname) == 0)
+ return regnames[i].dw2regnum;
+
+ if (regname[0] == 'r' || regname[0] == 'f' || regname[0] == 'v')
+ {
+ p = regname + 1 + (regname[1] == '.');
+ regnum = strtoul (p, &q, 10);
+ if (p == q || *q || regnum >= 32)
+ return -1;
+ if (regname[0] == 'f')
+ regnum += 32;
+ else if (regname[0] == 'v')
+ regnum += 77;
+ }
+ else if (regname[0] == 'c' && regname[1] == 'r')
+ {
+ p = regname + 2 + (regname[2] == '.');
+ if (p[0] < '0' || p[0] > '7' || p[1])
+ return -1;
+ regnum = p[0] - '0' + 68;
+ }
+ return regnum;
+}
diff --git a/contrib/binutils/gas/config/tc-ppc.h b/contrib/binutils/gas/config/tc-ppc.h
index b6dd640..0844f84 100644
--- a/contrib/binutils/gas/config/tc-ppc.h
+++ b/contrib/binutils/gas/config/tc-ppc.h
@@ -1,5 +1,5 @@
/* tc-ppc.h -- Header file for tc-ppc.c.
- Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
+ Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support.
@@ -117,7 +117,7 @@ extern char *ppc_target_format PARAMS ((void));
#define LEX_QM 1
/* Don't adjust TOC relocs. */
-#define tc_fix_adjustable(fixp) ppc_pe_fix_adjustable (fixp)
+#define tc_fix_adjustable(FIX) ppc_pe_fix_adjustable (FIX)
extern int ppc_pe_fix_adjustable PARAMS ((struct fix *));
#endif
@@ -177,13 +177,9 @@ extern void ppc_symbol_new_hook PARAMS ((symbolS *));
extern void ppc_frob_label PARAMS ((symbolS *));
/* TOC relocs requires special handling. */
-#define tc_fix_adjustable(fixp) ppc_fix_adjustable (fixp)
+#define tc_fix_adjustable(FIX) ppc_fix_adjustable (FIX)
extern int ppc_fix_adjustable PARAMS ((struct fix *));
-/* A relocation from one csect to another must be kept. */
-#define TC_FORCE_RELOCATION(FIXP) ppc_force_relocation (FIXP)
-extern int ppc_force_relocation PARAMS ((struct fix *));
-
/* We need to set the section VMA. */
#define tc_frob_section(sec) ppc_frob_section (sec)
extern void ppc_frob_section PARAMS ((asection *));
@@ -210,23 +206,10 @@ do { \
#endif /* OBJ_XCOFF */
-#ifdef OBJ_ELF
+extern const char ppc_symbol_chars[];
+#define tc_symbol_chars ppc_symbol_chars
-/* Branch prediction relocations must force relocation, as must
- the vtable description relocs. */
-#define TC_FORCE_RELOCATION(FIXP) \
-((FIXP)->fx_r_type == BFD_RELOC_PPC_B16_BRTAKEN \
- || (FIXP)->fx_r_type == BFD_RELOC_PPC_B16_BRNTAKEN \
- || (FIXP)->fx_r_type == BFD_RELOC_PPC_BA16_BRTAKEN \
- || (FIXP)->fx_r_type == BFD_RELOC_PPC_BA16_BRNTAKEN \
- || (FIXP)->fx_r_type == BFD_RELOC_PPC64_TOC \
- || (FIXP)->fx_r_type == BFD_RELOC_VTABLE_INHERIT \
- || (FIXP)->fx_r_type == BFD_RELOC_VTABLE_ENTRY)
-
-#define TC_FORCE_RELOCATION_SECTION(FIXP,SEC) \
-(TC_FORCE_RELOCATION (FIXP) \
- || ((FIXP)->fx_addsy && !(FIXP)->fx_subsy \
- && S_GET_SEGMENT ((FIXP)->fx_addsy) != SEC))
+#ifdef OBJ_ELF
/* Support for SHF_EXCLUDE and SHT_ORDERED */
extern int ppc_section_letter PARAMS ((int, char **));
@@ -239,49 +222,48 @@ extern int ppc_section_flags PARAMS ((int, int, int));
#define md_elf_section_word(STR, LEN) ppc_section_word (STR, LEN)
#define md_elf_section_flags(FLAGS, ATTR, TYPE) ppc_section_flags (FLAGS, ATTR, TYPE)
-/* Add extra PPC sections -- Note, for now, make .sbss2 and .PPC.EMB.sbss0 a
- normal section, and not a bss section so that the linker doesn't crater
- when trying to make more than 2 sections. */
-#define ELF_TC_SPECIAL_SECTIONS \
- { ".tags", SHT_ORDERED, SHF_ALLOC }, \
- { ".sdata", SHT_PROGBITS, SHF_ALLOC + SHF_WRITE }, \
- { ".sbss", SHT_NOBITS, SHF_ALLOC + SHF_WRITE }, \
- { ".sdata2", SHT_PROGBITS, SHF_ALLOC }, \
- { ".sbss2", SHT_PROGBITS, SHF_ALLOC }, \
- { ".PPC.EMB.sdata0", SHT_PROGBITS, SHF_ALLOC }, \
- { ".PPC.EMB.sbss0", SHT_PROGBITS, SHF_ALLOC }, \
- /* Extra sections for 64-bit ELF PPC. */ \
- { ".toc", SHT_PROGBITS, SHF_ALLOC + SHF_WRITE}, \
- { ".tocbss", SHT_NOBITS, SHF_ALLOC + SHF_WRITE},
-
#define tc_comment_chars ppc_comment_chars
extern const char *ppc_comment_chars;
/* Keep relocations relative to the GOT, or non-PC relative. */
-#define tc_fix_adjustable(fixp) ppc_fix_adjustable (fixp)
+#define tc_fix_adjustable(FIX) ppc_fix_adjustable (FIX)
extern int ppc_fix_adjustable PARAMS ((struct fix *));
-/* We must never ever try to resolve references to externally visible
- symbols in the assembler, because the .o file might go into a shared
- library, and some other shared library might override that symbol. */
-#define TC_RELOC_RTSYM_LOC_FIXUP(FIX) \
- ((FIX)->fx_addsy == NULL \
- || (! S_IS_EXTERNAL ((FIX)->fx_addsy) \
- && ! S_IS_WEAK ((FIX)->fx_addsy) \
- && S_IS_DEFINED ((FIX)->fx_addsy) \
- && ! S_IS_COMMON ((FIX)->fx_addsy)))
+/* Values passed to md_apply_fix3 don't include symbol values. */
+#define MD_APPLY_SYM_VALUE(FIX) 0
#define tc_frob_file_before_adjust ppc_frob_file_before_adjust
extern void ppc_frob_file_before_adjust PARAMS ((void));
-#define DWARF2_LINE_MIN_INSN_LENGTH 4
#endif /* OBJ_ELF */
+#if defined (OBJ_ELF) || defined (OBJ_XCOFF)
+#define TC_FORCE_RELOCATION(FIX) ppc_force_relocation (FIX)
+extern int ppc_force_relocation PARAMS ((struct fix *));
+#endif
+
/* call md_pcrel_from_section, not md_pcrel_from */
-#define MD_PCREL_FROM_SECTION(FIXP, SEC) md_pcrel_from_section(FIXP, SEC)
+#define MD_PCREL_FROM_SECTION(FIX, SEC) md_pcrel_from_section(FIX, SEC)
extern long md_pcrel_from_section PARAMS ((struct fix *, segT));
#define md_parse_name(name, exp, c) ppc_parse_name (name, exp)
extern int ppc_parse_name PARAMS ((const char *, struct expressionS *));
#define md_operand(x)
+
+#define md_cleanup() ppc_cleanup ()
+ extern void ppc_cleanup PARAMS ((void));
+
+#define TARGET_USE_CFIPOP 1
+
+#define tc_cfi_frame_initial_instructions ppc_cfi_frame_initial_instructions
+extern void ppc_cfi_frame_initial_instructions PARAMS ((void));
+
+#define tc_regname_to_dw2regnum tc_ppc_regname_to_dw2regnum
+extern int tc_ppc_regname_to_dw2regnum PARAMS ((const char *regname));
+
+extern int ppc_cie_data_alignment;
+
+#define DWARF2_LINE_MIN_INSN_LENGTH 4
+#define DWARF2_DEFAULT_RETURN_COLUMN 0x41
+#define DWARF2_CIE_DATA_ALIGNMENT ppc_cie_data_alignment
diff --git a/contrib/binutils/gas/config/tc-s390.c b/contrib/binutils/gas/config/tc-s390.c
index bce0604..4fafbec 100644
--- a/contrib/binutils/gas/config/tc-s390.c
+++ b/contrib/binutils/gas/config/tc-s390.c
@@ -1,5 +1,5 @@
/* tc-s390.c -- Assemble for the S390
- Copyright 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
Contributed by Martin Schwidefsky (schwidefsky@de.ibm.com).
This file is part of GAS, the GNU Assembler.
@@ -24,6 +24,8 @@
#include "safe-ctype.h"
#include "subsegs.h"
#include "struc-symbol.h"
+#include "dwarf2dbg.h"
+#include "dw2gencfi.h"
#include "opcode/s390.h"
#include "elf/s390.h"
@@ -34,21 +36,20 @@
#endif
static char *default_arch = DEFAULT_ARCH;
/* Either 32 or 64, selects file format. */
-static int s390_arch_size;
-/* Current architecture. Start with the smallest instruction set. */
-static enum s390_opcode_arch_val current_architecture = S390_OPCODE_ESA;
-static int current_arch_mask = 1 << S390_OPCODE_ESA;
-static int current_arch_requested = 0;
+static int s390_arch_size = 0;
-/* Whether to use user friendly register names. Default is true. */
+static unsigned int current_mode_mask = 0;
+static unsigned int current_cpu = -1U;
+
+/* Whether to use user friendly register names. Default is TRUE. */
#ifndef TARGET_REG_NAMES_P
-#define TARGET_REG_NAMES_P true
+#define TARGET_REG_NAMES_P TRUE
#endif
-static boolean reg_names_p = TARGET_REG_NAMES_P;
+static bfd_boolean reg_names_p = TARGET_REG_NAMES_P;
/* Set to TRUE if we want to warn about zero base/index registers. */
-static boolean warn_areg_zero = FALSE;
+static bfd_boolean warn_areg_zero = FALSE;
/* Generic assembler global variables which must be defined by all
targets. */
@@ -70,6 +71,9 @@ const char EXP_CHARS[] = "eE";
as in 0d1.0. */
const char FLT_CHARS[] = "dD";
+/* The dwarf2 data alignment, adjusted for 32 or 64 bit. */
+int s390_cie_data_alignment;
+
/* The target specific pseudo-ops which we support. */
/* Define the prototypes for the pseudo-ops */
@@ -203,7 +207,7 @@ static const struct pd_reg pre_defined_registers[] =
static int reg_name_search
PARAMS ((const struct pd_reg *, int, const char *));
-static boolean register_name PARAMS ((expressionS *));
+static bfd_boolean register_name PARAMS ((expressionS *));
static void init_default_arch PARAMS ((void));
static void s390_insert_operand
PARAMS ((unsigned char *, const struct s390_operand *, offsetT, char *,
@@ -255,7 +259,7 @@ reg_name_search (regs, regcount, name)
* original state.
*/
-static boolean
+static bfd_boolean
register_name (expressionP)
expressionS *expressionP;
{
@@ -269,7 +273,7 @@ register_name (expressionP)
if (name[0] == '%' && ISALPHA (name[1]))
name = ++input_line_pointer;
else
- return false;
+ return FALSE;
c = get_symbol_end ();
reg_number = reg_name_search (pre_defined_registers, REG_NAME_CNT, name);
@@ -286,12 +290,12 @@ register_name (expressionP)
/* Make the rest nice. */
expressionP->X_add_symbol = NULL;
expressionP->X_op_symbol = NULL;
- return true;
+ return TRUE;
}
/* Reset the line as if we had not done anything. */
input_line_pointer = start;
- return false;
+ return FALSE;
}
/* Local variables. */
@@ -319,26 +323,37 @@ struct option md_longopts[] = {
size_t md_longopts_size = sizeof (md_longopts);
/* Initialize the default opcode arch and word size from the default
- architecture name. */
+ architecture name if not specified by an option. */
static void
init_default_arch ()
{
- if (current_arch_requested)
- return;
-
if (strcmp (default_arch, "s390") == 0)
{
- s390_arch_size = 32;
- current_architecture = S390_OPCODE_ESA;
+ if (s390_arch_size == 0)
+ s390_arch_size = 32;
}
else if (strcmp (default_arch, "s390x") == 0)
{
- s390_arch_size = 64;
- current_architecture = S390_OPCODE_ESAME;
+ if (s390_arch_size == 0)
+ s390_arch_size = 64;
}
else
as_fatal ("Invalid default architecture, broken assembler.");
- current_arch_mask = 1 << current_architecture;
+
+ if (current_mode_mask == 0)
+ {
+ if (s390_arch_size == 32)
+ current_mode_mask = 1 << S390_OPCODE_ESA;
+ else
+ current_mode_mask = 1 << S390_OPCODE_ZARCH;
+ }
+ if (current_cpu == -1U)
+ {
+ if (current_mode_mask == (1 << S390_OPCODE_ESA))
+ current_cpu = S390_OPCODE_G5;
+ else
+ current_cpu = S390_OPCODE_Z900;
+ }
}
/* Called by TARGET_FORMAT. */
@@ -347,8 +362,7 @@ s390_target_format ()
{
/* We don't get a chance to initialize anything before we're called,
so handle that now. */
- if (! s390_arch_size)
- init_default_arch ();
+ init_default_arch ();
return s390_arch_size == 64 ? "elf64-s390" : "elf32-s390";
}
@@ -365,20 +379,43 @@ md_parse_option (c, arg)
break;
case 'm':
if (arg != NULL && strcmp (arg, "regnames") == 0)
- reg_names_p = true;
+ reg_names_p = TRUE;
else if (arg != NULL && strcmp (arg, "no-regnames") == 0)
- reg_names_p = false;
+ reg_names_p = FALSE;
else if (arg != NULL && strcmp (arg, "warn-areg-zero") == 0)
warn_areg_zero = TRUE;
else if (arg != NULL && strcmp (arg, "31") == 0)
- s390_arch_size = 31;
+ s390_arch_size = 32;
else if (arg != NULL && strcmp (arg, "64") == 0)
s390_arch_size = 64;
+ else if (arg != NULL && strcmp (arg, "esa") == 0)
+ current_mode_mask = 1 << S390_OPCODE_ESA;
+
+ else if (arg != NULL && strcmp (arg, "zarch") == 0)
+ current_mode_mask = 1 << S390_OPCODE_ZARCH;
+
+ else if (arg != NULL && strncmp (arg, "arch=", 5) == 0)
+ {
+ if (strcmp (arg + 5, "g5") == 0)
+ current_cpu = S390_OPCODE_G5;
+ else if (strcmp (arg + 5, "g6") == 0)
+ current_cpu = S390_OPCODE_G6;
+ else if (strcmp (arg + 5, "z900") == 0)
+ current_cpu = S390_OPCODE_Z900;
+ else if (strcmp (arg + 5, "z990") == 0)
+ current_cpu = S390_OPCODE_Z990;
+ else
+ {
+ as_bad (_("invalid switch -m%s"), arg);
+ return 0;
+ }
+ }
+
else
{
as_bad (_("invalid switch -m%s"), arg);
@@ -387,14 +424,13 @@ md_parse_option (c, arg)
break;
case 'A':
+ /* Option -A is deprecated. Still available for compatibility. */
if (arg != NULL && strcmp (arg, "esa") == 0)
- current_architecture = S390_OPCODE_ESA;
+ current_cpu = S390_OPCODE_G5;
else if (arg != NULL && strcmp (arg, "esame") == 0)
- current_architecture = S390_OPCODE_ESAME;
+ current_cpu = S390_OPCODE_Z900;
else
as_bad ("invalid architecture -A%s", arg);
- current_arch_mask = 1 << current_architecture;
- current_arch_requested = 1;
break;
/* -V: SVR4 argument to print version ID. */
@@ -439,13 +475,15 @@ md_begin ()
{
register const struct s390_opcode *op;
const struct s390_opcode *op_end;
- boolean dup_insn = false;
+ bfd_boolean dup_insn = FALSE;
const char *retval;
/* Give a warning if the combination -m64-bit and -Aesa is used. */
- if (s390_arch_size == 64 && current_arch_mask == (1 << S390_OPCODE_ESA))
+ if (s390_arch_size == 64 && current_cpu < S390_OPCODE_Z900)
as_warn ("The 64 bit file format is used without esame instructions.");
+ s390_cie_data_alignment = -s390_arch_size / 8;
+
/* Set the ELF flags if desired. */
if (s390_flags)
bfd_set_private_flags (stdoutput, s390_flags);
@@ -461,7 +499,7 @@ md_begin ()
{
as_bad (_("Internal assembler error for instruction format %s"),
op->name);
- dup_insn = true;
+ dup_insn = TRUE;
}
}
@@ -470,14 +508,18 @@ md_begin ()
op_end = s390_opcodes + s390_num_opcodes;
for (op = s390_opcodes; op < op_end; op++)
- {
- retval = hash_insert (s390_opcode_hash, op->name, (PTR) op);
- if (retval != (const char *) NULL)
- {
- as_bad (_("Internal assembler error for instruction %s"), op->name);
- dup_insn = true;
- }
- }
+ if (op->min_cpu <= current_cpu)
+ {
+ retval = hash_insert (s390_opcode_hash, op->name, (PTR) op);
+ if (retval != (const char *) NULL)
+ {
+ as_bad (_("Internal assembler error for instruction %s"),
+ op->name);
+ dup_insn = TRUE;
+ }
+ while (op < op_end - 1 && strcmp (op->name, op[1].name) == 0)
+ op++;
+ }
if (dup_insn)
abort ();
@@ -498,19 +540,6 @@ s390_md_end ()
bfd_set_arch_mach (stdoutput, bfd_arch_s390, bfd_mach_s390_31);
}
-void
-s390_align_code (fragP, count)
- fragS *fragP;
- int count;
-{
- /* We use nop pattern 0x0707. */
- if (count > 0)
- {
- memset (fragP->fr_literal + fragP->fr_fix, 0x07, count);
- fragP->fr_var = count;
- }
-}
-
/* Insert an operand value into an instruction. */
static void
@@ -555,6 +584,9 @@ s390_insert_operand (insn, operand, val, file, line)
}
/* val is ok, now restrict it to operand->bits bits. */
uval = (addressT) val & ((((addressT) 1 << (operand->bits-1)) << 1) - 1);
+ /* val is restrict, now check for special case. */
+ if (operand->bits == 20 && operand->shift == 20)
+ uval = (uval >> 12) | ((uval & 0xfff) << 8);
}
else
{
@@ -599,13 +631,83 @@ s390_insert_operand (insn, operand, val, file, line)
}
}
+struct map_tls
+ {
+ char *string;
+ int length;
+ bfd_reloc_code_real_type reloc;
+ };
+
+static bfd_reloc_code_real_type s390_tls_suffix
+ PARAMS ((char **, expressionS *));
+
+/* Parse tls marker and return the desired relocation. */
+static bfd_reloc_code_real_type
+s390_tls_suffix (str_p, exp_p)
+ char **str_p;
+ expressionS *exp_p;
+{
+ static struct map_tls mapping[] =
+ {
+ { "tls_load", 8, BFD_RELOC_390_TLS_LOAD },
+ { "tls_gdcall", 10, BFD_RELOC_390_TLS_GDCALL },
+ { "tls_ldcall", 10, BFD_RELOC_390_TLS_LDCALL },
+ { NULL, 0, BFD_RELOC_UNUSED }
+ };
+ struct map_tls *ptr;
+ char *orig_line;
+ char *str;
+ char *ident;
+ int len;
+
+ str = *str_p;
+ if (*str++ != ':')
+ return BFD_RELOC_UNUSED;
+
+ ident = str;
+ while (ISIDNUM (*str))
+ str++;
+ len = str - ident;
+ if (*str++ != ':')
+ return BFD_RELOC_UNUSED;
+
+ orig_line = input_line_pointer;
+ input_line_pointer = str;
+ expression (exp_p);
+ str = input_line_pointer;
+ if (&input_line_pointer != str_p)
+ input_line_pointer = orig_line;
+
+ if (exp_p->X_op != O_symbol)
+ return BFD_RELOC_UNUSED;
+
+ for (ptr = &mapping[0]; ptr->length > 0; ptr++)
+ if (len == ptr->length
+ && strncasecmp (ident, ptr->string, ptr->length) == 0)
+ {
+ /* Found a matching tls suffix. */
+ *str_p = str;
+ return ptr->reloc;
+ }
+ return BFD_RELOC_UNUSED;
+}
+
/* Structure used to hold suffixes. */
typedef enum
{
ELF_SUFFIX_NONE = 0,
ELF_SUFFIX_GOT,
ELF_SUFFIX_PLT,
- ELF_SUFFIX_GOTENT
+ ELF_SUFFIX_GOTENT,
+ ELF_SUFFIX_GOTOFF,
+ ELF_SUFFIX_GOTPLT,
+ ELF_SUFFIX_PLTOFF,
+ ELF_SUFFIX_TLS_GD,
+ ELF_SUFFIX_TLS_GOTIE,
+ ELF_SUFFIX_TLS_IE,
+ ELF_SUFFIX_TLS_LDM,
+ ELF_SUFFIX_TLS_LDO,
+ ELF_SUFFIX_TLS_LE
}
elf_suffix_type;
@@ -634,6 +736,15 @@ s390_elf_suffix (str_p, exp_p)
{ "got12", 5, ELF_SUFFIX_GOT },
{ "plt", 3, ELF_SUFFIX_PLT },
{ "gotent", 6, ELF_SUFFIX_GOTENT },
+ { "gotoff", 6, ELF_SUFFIX_GOTOFF },
+ { "gotplt", 6, ELF_SUFFIX_GOTPLT },
+ { "pltoff", 6, ELF_SUFFIX_PLTOFF },
+ { "tlsgd", 5, ELF_SUFFIX_TLS_GD },
+ { "gotntpoff", 9, ELF_SUFFIX_TLS_GOTIE },
+ { "indntpoff", 9, ELF_SUFFIX_TLS_IE },
+ { "tlsldm", 6, ELF_SUFFIX_TLS_LDM },
+ { "dtpoff", 6, ELF_SUFFIX_TLS_LDO },
+ { "ntpoff", 6, ELF_SUFFIX_TLS_LE },
{ NULL, 0, ELF_SUFFIX_NONE }
};
@@ -949,22 +1060,72 @@ s390_elf_cons (nbytes)
int size;
char *where;
- if (nbytes == 2 && suffix == ELF_SUFFIX_GOT)
- reloc = BFD_RELOC_390_GOT16;
- else if (nbytes == 4 && suffix == ELF_SUFFIX_GOT)
- reloc = BFD_RELOC_32_GOT_PCREL;
- else if (nbytes == 8 && suffix == ELF_SUFFIX_GOT)
- reloc = BFD_RELOC_390_GOT64;
- else if (nbytes == 4 && suffix == ELF_SUFFIX_PLT)
- reloc = BFD_RELOC_390_PLT32;
- else if (nbytes == 8 && suffix == ELF_SUFFIX_PLT)
- reloc = BFD_RELOC_390_PLT64;
+ if (nbytes == 2)
+ {
+ static bfd_reloc_code_real_type tab2[] =
+ {
+ BFD_RELOC_UNUSED, /* ELF_SUFFIX_NONE */
+ BFD_RELOC_390_GOT16, /* ELF_SUFFIX_GOT */
+ BFD_RELOC_UNUSED, /* ELF_SUFFIX_PLT */
+ BFD_RELOC_UNUSED, /* ELF_SUFFIX_GOTENT */
+ BFD_RELOC_16_GOTOFF, /* ELF_SUFFIX_GOTOFF */
+ BFD_RELOC_UNUSED, /* ELF_SUFFIX_GOTPLT */
+ BFD_RELOC_390_PLTOFF16, /* ELF_SUFFIX_PLTOFF */
+ BFD_RELOC_UNUSED, /* ELF_SUFFIX_TLS_GD */
+ BFD_RELOC_UNUSED, /* ELF_SUFFIX_TLS_GOTIE */
+ BFD_RELOC_UNUSED, /* ELF_SUFFIX_TLS_IE */
+ BFD_RELOC_UNUSED, /* ELF_SUFFIX_TLS_LDM */
+ BFD_RELOC_UNUSED, /* ELF_SUFFIX_TLS_LDO */
+ BFD_RELOC_UNUSED /* ELF_SUFFIX_TLS_LE */
+ };
+ reloc = tab2[suffix];
+ }
+ else if (nbytes == 4)
+ {
+ static bfd_reloc_code_real_type tab4[] =
+ {
+ BFD_RELOC_UNUSED, /* ELF_SUFFIX_NONE */
+ BFD_RELOC_32_GOT_PCREL, /* ELF_SUFFIX_GOT */
+ BFD_RELOC_390_PLT32, /* ELF_SUFFIX_PLT */
+ BFD_RELOC_UNUSED, /* ELF_SUFFIX_GOTENT */
+ BFD_RELOC_32_GOTOFF, /* ELF_SUFFIX_GOTOFF */
+ BFD_RELOC_390_GOTPLT32, /* ELF_SUFFIX_GOTPLT */
+ BFD_RELOC_390_PLTOFF32, /* ELF_SUFFIX_PLTOFF */
+ BFD_RELOC_390_TLS_GD32, /* ELF_SUFFIX_TLS_GD */
+ BFD_RELOC_390_TLS_GOTIE32, /* ELF_SUFFIX_TLS_GOTIE */
+ BFD_RELOC_390_TLS_IE32, /* ELF_SUFFIX_TLS_IE */
+ BFD_RELOC_390_TLS_LDM32, /* ELF_SUFFIX_TLS_LDM */
+ BFD_RELOC_390_TLS_LDO32, /* ELF_SUFFIX_TLS_LDO */
+ BFD_RELOC_390_TLS_LE32 /* ELF_SUFFIX_TLS_LE */
+ };
+ reloc = tab4[suffix];
+ }
+ else if (nbytes == 8)
+ {
+ static bfd_reloc_code_real_type tab8[] =
+ {
+ BFD_RELOC_UNUSED, /* ELF_SUFFIX_NONE */
+ BFD_RELOC_390_GOT64, /* ELF_SUFFIX_GOT */
+ BFD_RELOC_390_PLT64, /* ELF_SUFFIX_PLT */
+ BFD_RELOC_UNUSED, /* ELF_SUFFIX_GOTENT */
+ BFD_RELOC_390_GOTOFF64, /* ELF_SUFFIX_GOTOFF */
+ BFD_RELOC_390_GOTPLT64, /* ELF_SUFFIX_GOTPLT */
+ BFD_RELOC_390_PLTOFF64, /* ELF_SUFFIX_PLTOFF */
+ BFD_RELOC_390_TLS_GD64, /* ELF_SUFFIX_TLS_GD */
+ BFD_RELOC_390_TLS_GOTIE64, /* ELF_SUFFIX_TLS_GOTIE */
+ BFD_RELOC_390_TLS_IE64, /* ELF_SUFFIX_TLS_IE */
+ BFD_RELOC_390_TLS_LDM64, /* ELF_SUFFIX_TLS_LDM */
+ BFD_RELOC_390_TLS_LDO64, /* ELF_SUFFIX_TLS_LDO */
+ BFD_RELOC_390_TLS_LE64 /* ELF_SUFFIX_TLS_LE */
+ };
+ reloc = tab8[suffix];
+ }
else
reloc = BFD_RELOC_UNUSED;
- if (reloc != BFD_RELOC_UNUSED)
+ if (reloc != BFD_RELOC_UNUSED
+ && (reloc_howto = bfd_reloc_type_lookup (stdoutput, reloc)))
{
- reloc_howto = bfd_reloc_type_lookup (stdoutput, reloc);
size = bfd_get_reloc_size (reloc_howto);
if (size > nbytes)
as_bad (_("%s relocations do not fit in %d bytes"),
@@ -972,9 +1133,9 @@ s390_elf_cons (nbytes)
where = frag_more (nbytes);
md_number_to_chars (where, 0, size);
/* To make fixup_segment do the pc relative conversion the
- pcrel parameter on the fix_new_exp call needs to be false. */
+ pcrel parameter on the fix_new_exp call needs to be FALSE. */
fix_new_exp (frag_now, where - frag_now->fr_literal,
- size, &exp, false, reloc);
+ size, &exp, FALSE, reloc);
}
else
as_bad (_("relocation not applicable"));
@@ -1012,6 +1173,7 @@ md_gather_operands (str, insn, opcode)
struct s390_fixup fixups[MAX_INSN_FIXUPS];
const struct s390_operand *operand;
const unsigned char *opindex_ptr;
+ expressionS ex;
elf_suffix_type suffix;
bfd_reloc_code_real_type reloc;
int skip_optional;
@@ -1029,7 +1191,6 @@ md_gather_operands (str, insn, opcode)
fc = 0;
for (opindex_ptr = opcode->operands; *opindex_ptr != 0; opindex_ptr++)
{
- expressionS ex;
char *hold;
operand = s390_operands + *opindex_ptr;
@@ -1079,11 +1240,11 @@ md_gather_operands (str, insn, opcode)
{
if ((operand->flags & S390_OPERAND_INDEX)
&& ex.X_add_number == 0
- && warn_areg_zero == TRUE)
+ && warn_areg_zero)
as_warn ("index register specified but zero");
if ((operand->flags & S390_OPERAND_BASE)
&& ex.X_add_number == 0
- && warn_areg_zero == TRUE)
+ && warn_areg_zero)
as_warn ("base register specified but zero");
s390_insert_operand (insn, operand, ex.X_add_number, NULL, 0);
}
@@ -1096,8 +1257,12 @@ md_gather_operands (str, insn, opcode)
if (suffix == ELF_SUFFIX_GOT)
{
- if (operand->flags & S390_OPERAND_DISP)
+ if ((operand->flags & S390_OPERAND_DISP) &&
+ (operand->bits == 12))
reloc = BFD_RELOC_390_GOT12;
+ else if ((operand->flags & S390_OPERAND_DISP) &&
+ (operand->bits == 20))
+ reloc = BFD_RELOC_390_GOT20;
else if ((operand->flags & S390_OPERAND_SIGNED)
&& (operand->bits == 16))
reloc = BFD_RELOC_390_GOT16;
@@ -1120,6 +1285,45 @@ md_gather_operands (str, insn, opcode)
&& (operand->bits == 32))
reloc = BFD_RELOC_390_GOTENT;
}
+ else if (suffix == ELF_SUFFIX_GOTOFF)
+ {
+ if ((operand->flags & S390_OPERAND_SIGNED)
+ && (operand->bits == 16))
+ reloc = BFD_RELOC_16_GOTOFF;
+ }
+ else if (suffix == ELF_SUFFIX_PLTOFF)
+ {
+ if ((operand->flags & S390_OPERAND_SIGNED)
+ && (operand->bits == 16))
+ reloc = BFD_RELOC_390_PLTOFF16;
+ }
+ else if (suffix == ELF_SUFFIX_GOTPLT)
+ {
+ if ((operand->flags & S390_OPERAND_DISP)
+ && (operand->bits == 12))
+ reloc = BFD_RELOC_390_GOTPLT12;
+ else if ((operand->flags & S390_OPERAND_SIGNED)
+ && (operand->bits == 16))
+ reloc = BFD_RELOC_390_GOTPLT16;
+ else if ((operand->flags & S390_OPERAND_PCREL)
+ && (operand->bits == 32))
+ reloc = BFD_RELOC_390_GOTPLTENT;
+ }
+ else if (suffix == ELF_SUFFIX_TLS_GOTIE)
+ {
+ if ((operand->flags & S390_OPERAND_DISP)
+ && (operand->bits == 12))
+ reloc = BFD_RELOC_390_TLS_GOTIE12;
+ else if ((operand->flags & S390_OPERAND_DISP)
+ && (operand->bits == 20))
+ reloc = BFD_RELOC_390_TLS_GOTIE20;
+ }
+ else if (suffix == ELF_SUFFIX_TLS_IE)
+ {
+ if ((operand->flags & S390_OPERAND_PCREL)
+ && (operand->bits == 32))
+ reloc = BFD_RELOC_390_TLS_IEENT;
+ }
if (suffix != ELF_SUFFIX_NONE && reloc == BFD_RELOC_UNUSED)
as_bad (_("invalid operand suffix"));
@@ -1140,7 +1344,7 @@ md_gather_operands (str, insn, opcode)
/* After a displacement a block in parentheses can start. */
if (*str != '(')
{
- /* Check if parethesed block can be skipped. If the next
+ /* Check if parenthesized block can be skipped. If the next
operand is neiter an optional operand nor a base register
then we have a syntax error. */
operand = s390_operands + *(++opindex_ptr);
@@ -1151,7 +1355,7 @@ md_gather_operands (str, insn, opcode)
while (!(operand->flags & S390_OPERAND_BASE))
operand = s390_operands + *(++opindex_ptr);
- /* If there is a next operand it must be seperated by a comma. */
+ /* If there is a next operand it must be separated by a comma. */
if (opindex_ptr[1] != '\0')
{
if (*str++ != ',')
@@ -1184,7 +1388,7 @@ md_gather_operands (str, insn, opcode)
if (*str++ != ')')
as_bad (_("syntax error; missing ')' after base register"));
skip_optional = 0;
- /* If there is a next operand it must be seperated by a comma. */
+ /* If there is a next operand it must be separated by a comma. */
if (opindex_ptr[1] != '\0')
{
if (*str++ != ',')
@@ -1203,7 +1407,7 @@ md_gather_operands (str, insn, opcode)
as_bad (_("syntax error; ')' not allowed here"));
str++;
}
- /* If there is a next operand it must be seperated by a comma. */
+ /* If there is a next operand it must be separated by a comma. */
if (opindex_ptr[1] != '\0')
{
if (*str++ != ',')
@@ -1215,6 +1419,20 @@ md_gather_operands (str, insn, opcode)
while (ISSPACE (*str))
++str;
+ /* Check for tls instruction marker. */
+ reloc = s390_tls_suffix (&str, &ex);
+ if (reloc != BFD_RELOC_UNUSED)
+ {
+ /* We need to generate a fixup of type 'reloc' for this
+ instruction. */
+ if (fc >= MAX_INSN_FIXUPS)
+ as_fatal (_("too many fixups"));
+ fixups[fc].exp = ex;
+ fixups[fc].opindex = -1;
+ fixups[fc].reloc = reloc;
+ ++fc;
+ }
+
if (*str != '\0')
{
char *linefeed;
@@ -1239,6 +1457,15 @@ md_gather_operands (str, insn, opcode)
md_apply_fix3. */
for (i = 0; i < fc; i++)
{
+
+ if (fixups[i].opindex < 0)
+ {
+ /* Create tls instruction marker relocation. */
+ fix_new_exp (frag_now, f - frag_now->fr_literal, opcode->oplen,
+ &fixups[i].exp, 0, fixups[i].reloc);
+ continue;
+ }
+
operand = s390_operands + fixups[i].opindex;
if (fixups[i].reloc != BFD_RELOC_UNUSED)
@@ -1264,6 +1491,7 @@ md_gather_operands (str, insn, opcode)
because fixup_segment will signal an overflow for large 4 byte
quantities for GOT12 relocations. */
if ( fixups[i].reloc == BFD_RELOC_390_GOT12
+ || fixups[i].reloc == BFD_RELOC_390_GOT20
|| fixups[i].reloc == BFD_RELOC_390_GOT16)
fixP->fx_no_overflow = 1;
}
@@ -1299,12 +1527,11 @@ md_assemble (str)
as_bad (_("Unrecognized opcode: `%s'"), str);
return;
}
- else if (!(opcode->architecture & current_arch_mask))
+ else if (!(opcode->modes & current_mode_mask))
{
- as_bad ("Opcode %s not available in this architecture", str);
+ as_bad ("Opcode %s not available in this mode", str);
return;
}
-
memcpy (insn, opcode->opcode, sizeof (insn));
md_gather_operands (s, insn, opcode);
}
@@ -1374,9 +1601,15 @@ s390_insn (ignore)
expression (&exp);
if (exp.X_op == O_constant)
{
- if ( ((opformat->oplen == 6) && (exp.X_op > 0) && (exp.X_op < (1ULL << 48)))
- || ((opformat->oplen == 4) && (exp.X_op > 0) && (exp.X_op < (1ULL << 32)))
- || ((opformat->oplen == 2) && (exp.X_op > 0) && (exp.X_op < (1ULL << 16))))
+ if ( ( opformat->oplen == 6
+ && exp.X_add_number >= 0
+ && (addressT) exp.X_add_number < (1ULL << 48))
+ || ( opformat->oplen == 4
+ && exp.X_add_number >= 0
+ && (addressT) exp.X_add_number < (1ULL << 32))
+ || ( opformat->oplen == 2
+ && exp.X_add_number >= 0
+ && (addressT) exp.X_add_number < (1ULL << 16)))
md_number_to_chars (insn, exp.X_add_number, opformat->oplen);
else
as_bad (_("Invalid .insn format\n"));
@@ -1628,25 +1861,53 @@ int
tc_s390_fix_adjustable (fixP)
fixS *fixP;
{
- /* Prevent all adjustments to global symbols. */
- if (S_IS_EXTERN (fixP->fx_addsy))
- return 0;
- if (S_IS_WEAK (fixP->fx_addsy))
- return 0;
/* Don't adjust references to merge sections. */
if ((S_GET_SEGMENT (fixP->fx_addsy)->flags & SEC_MERGE) != 0)
return 0;
/* adjust_reloc_syms doesn't know about the GOT. */
- if ( fixP->fx_r_type == BFD_RELOC_32_GOTOFF
+ if ( fixP->fx_r_type == BFD_RELOC_16_GOTOFF
+ || fixP->fx_r_type == BFD_RELOC_32_GOTOFF
+ || fixP->fx_r_type == BFD_RELOC_390_GOTOFF64
+ || fixP->fx_r_type == BFD_RELOC_390_PLTOFF16
+ || fixP->fx_r_type == BFD_RELOC_390_PLTOFF32
+ || fixP->fx_r_type == BFD_RELOC_390_PLTOFF64
|| fixP->fx_r_type == BFD_RELOC_390_PLT16DBL
|| fixP->fx_r_type == BFD_RELOC_390_PLT32
|| fixP->fx_r_type == BFD_RELOC_390_PLT32DBL
|| fixP->fx_r_type == BFD_RELOC_390_PLT64
|| fixP->fx_r_type == BFD_RELOC_390_GOT12
+ || fixP->fx_r_type == BFD_RELOC_390_GOT20
|| fixP->fx_r_type == BFD_RELOC_390_GOT16
|| fixP->fx_r_type == BFD_RELOC_32_GOT_PCREL
|| fixP->fx_r_type == BFD_RELOC_390_GOT64
|| fixP->fx_r_type == BFD_RELOC_390_GOTENT
+ || fixP->fx_r_type == BFD_RELOC_390_GOTPLT12
+ || fixP->fx_r_type == BFD_RELOC_390_GOTPLT16
+ || fixP->fx_r_type == BFD_RELOC_390_GOTPLT20
+ || fixP->fx_r_type == BFD_RELOC_390_GOTPLT32
+ || fixP->fx_r_type == BFD_RELOC_390_GOTPLT64
+ || fixP->fx_r_type == BFD_RELOC_390_GOTPLTENT
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_LOAD
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_GDCALL
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_LDCALL
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_GD32
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_GD64
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_GOTIE12
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_GOTIE20
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_GOTIE32
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_GOTIE64
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_LDM32
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_LDM64
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_IE32
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_IE64
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_IEENT
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_LE32
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_LE64
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_LDO32
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_LDO64
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_DTPMOD
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_DTPOFF
+ || fixP->fx_r_type == BFD_RELOC_390_TLS_TPOFF
|| fixP->fx_r_type == BFD_RELOC_VTABLE_INHERIT
|| fixP->fx_r_type == BFD_RELOC_VTABLE_ENTRY)
return 0;
@@ -1654,7 +1915,7 @@ tc_s390_fix_adjustable (fixP)
}
/* Return true if we must always emit a reloc for a type and false if
- there is some hope of resolving it a assembly time. */
+ there is some hope of resolving it at assembly time. */
int
tc_s390_force_relocation (fixp)
struct fix *fixp;
@@ -1664,8 +1925,13 @@ tc_s390_force_relocation (fixp)
switch (fixp->fx_r_type)
{
case BFD_RELOC_390_GOT12:
+ case BFD_RELOC_390_GOT20:
case BFD_RELOC_32_GOT_PCREL:
case BFD_RELOC_32_GOTOFF:
+ case BFD_RELOC_390_GOTOFF64:
+ case BFD_RELOC_390_PLTOFF16:
+ case BFD_RELOC_390_PLTOFF32:
+ case BFD_RELOC_390_PLTOFF64:
case BFD_RELOC_390_GOTPC:
case BFD_RELOC_390_GOT16:
case BFD_RELOC_390_GOTPCDBL:
@@ -1675,12 +1941,18 @@ tc_s390_force_relocation (fixp)
case BFD_RELOC_390_PLT16DBL:
case BFD_RELOC_390_PLT32DBL:
case BFD_RELOC_390_PLT64:
- case BFD_RELOC_VTABLE_INHERIT:
- case BFD_RELOC_VTABLE_ENTRY:
+ case BFD_RELOC_390_GOTPLT12:
+ case BFD_RELOC_390_GOTPLT16:
+ case BFD_RELOC_390_GOTPLT20:
+ case BFD_RELOC_390_GOTPLT32:
+ case BFD_RELOC_390_GOTPLT64:
+ case BFD_RELOC_390_GOTPLTENT:
return 1;
default:
- return 0;
+ break;;
}
+
+ return generic_force_reloc (fixp);
}
/* Apply a fixup to the object code. This is called for all the
@@ -1696,7 +1968,7 @@ void
md_apply_fix3 (fixP, valP, seg)
fixS *fixP;
valueT *valP;
- segT seg;
+ segT seg ATTRIBUTE_UNUSED;
{
char *where;
valueT value = *valP;
@@ -1704,35 +1976,13 @@ md_apply_fix3 (fixP, valP, seg)
where = fixP->fx_frag->fr_literal + fixP->fx_where;
if (fixP->fx_subsy != NULL)
- {
- if ((fixP->fx_addsy != NULL
- && S_GET_SEGMENT (fixP->fx_addsy) == S_GET_SEGMENT (fixP->fx_subsy)
- && SEG_NORMAL (S_GET_SEGMENT (fixP->fx_addsy)))
- || (S_GET_SEGMENT (fixP->fx_subsy) == absolute_section))
- value += S_GET_VALUE (fixP->fx_subsy);
- if (!S_IS_DEFINED (fixP->fx_subsy))
- as_bad_where (fixP->fx_file, fixP->fx_line,
- _("unresolved fx_subsy symbol that must be resolved"));
- value -= S_GET_VALUE (fixP->fx_subsy);
-
- if (S_GET_SEGMENT (fixP->fx_subsy) == seg && ! fixP->fx_pcrel)
- value += MD_PCREL_FROM_SECTION (fixP, seg);
- }
+ as_bad_where (fixP->fx_file, fixP->fx_line,
+ "cannot emit relocation %s against subsy symbol %s",
+ bfd_get_reloc_code_name (fixP->fx_r_type),
+ S_GET_NAME (fixP->fx_subsy));
if (fixP->fx_addsy != NULL)
{
- if ((fixP->fx_subsy != NULL
- && S_GET_SEGMENT (fixP->fx_addsy) == S_GET_SEGMENT (fixP->fx_subsy)
- && SEG_NORMAL (S_GET_SEGMENT (fixP->fx_addsy)))
- || (S_GET_SEGMENT (fixP->fx_addsy) == seg
- && fixP->fx_pcrel && TC_RELOC_RTSYM_LOC_FIXUP (fixP))
- || (!fixP->fx_pcrel
- && S_GET_SEGMENT (fixP->fx_addsy) == absolute_section)
- || (S_GET_SEGMENT (fixP->fx_addsy) != undefined_section
- && !bfd_is_com_section (S_GET_SEGMENT (fixP->fx_addsy))
- && TC_FIX_ADJUSTABLE (fixP)))
- value -= S_GET_VALUE (fixP->fx_addsy);
-
if (fixP->fx_pcrel)
value += fixP->fx_frag->fr_address + fixP->fx_where;
}
@@ -1771,6 +2021,12 @@ md_apply_fix3 (fixP, valP, seg)
fixP->fx_where += 4;
fixP->fx_r_type = BFD_RELOC_390_12;
}
+ else if (operand->bits == 20 && operand->shift == 20)
+ {
+ fixP->fx_size = 2;
+ fixP->fx_where += 2;
+ fixP->fx_r_type = BFD_RELOC_390_20;
+ }
else if (operand->bits == 8 && operand->shift == 8)
{
fixP->fx_size = 1;
@@ -1826,6 +2082,7 @@ md_apply_fix3 (fixP, valP, seg)
break;
case BFD_RELOC_390_12:
case BFD_RELOC_390_GOT12:
+ case BFD_RELOC_390_GOTPLT12:
if (fixP->fx_done)
{
unsigned short mop;
@@ -1836,6 +2093,19 @@ md_apply_fix3 (fixP, valP, seg)
}
break;
+ case BFD_RELOC_390_20:
+ case BFD_RELOC_390_GOT20:
+ case BFD_RELOC_390_GOTPLT20:
+ if (fixP->fx_done)
+ {
+ unsigned int mop;
+ mop = bfd_getb32 ((unsigned char *) where);
+ mop |= (unsigned int) ((value & 0xfff) << 8 |
+ (value & 0xff000) >> 12);
+ bfd_putb32 ((bfd_vma) mop, (unsigned char *) where);
+ }
+ break;
+
case BFD_RELOC_16:
case BFD_RELOC_GPREL16:
case BFD_RELOC_16_GOT_PCREL:
@@ -1852,6 +2122,8 @@ md_apply_fix3 (fixP, valP, seg)
md_number_to_chars (where, value, 2);
break;
case BFD_RELOC_390_GOT16:
+ case BFD_RELOC_390_PLTOFF16:
+ case BFD_RELOC_390_GOTPLT16:
if (fixP->fx_done)
md_number_to_chars (where, value, 2);
break;
@@ -1877,7 +2149,9 @@ md_apply_fix3 (fixP, valP, seg)
md_number_to_chars (where, value, 4);
break;
case BFD_RELOC_32_GOT_PCREL:
+ case BFD_RELOC_390_PLTOFF32:
case BFD_RELOC_390_PLT32:
+ case BFD_RELOC_390_GOTPLT32:
if (fixP->fx_done)
md_number_to_chars (where, value, 4);
break;
@@ -1885,6 +2159,7 @@ md_apply_fix3 (fixP, valP, seg)
case BFD_RELOC_390_PLT32DBL:
case BFD_RELOC_390_GOTPCDBL:
case BFD_RELOC_390_GOTENT:
+ case BFD_RELOC_390_GOTPLTENT:
value += 2;
if (fixP->fx_done)
md_number_to_chars (where, (offsetT) value >> 1, 4);
@@ -1895,8 +2170,15 @@ md_apply_fix3 (fixP, valP, seg)
md_number_to_chars (where, value, sizeof (int));
break;
+ case BFD_RELOC_390_GOTOFF64:
+ if (fixP->fx_done)
+ md_number_to_chars (where, value, 8);
+ break;
+
case BFD_RELOC_390_GOT64:
+ case BFD_RELOC_390_PLTOFF64:
case BFD_RELOC_390_PLT64:
+ case BFD_RELOC_390_GOTPLT64:
if (fixP->fx_done)
md_number_to_chars (where, value, 8);
break;
@@ -1921,6 +2203,33 @@ md_apply_fix3 (fixP, valP, seg)
fixP->fx_done = 0;
return;
+ case BFD_RELOC_390_TLS_LOAD:
+ case BFD_RELOC_390_TLS_GDCALL:
+ case BFD_RELOC_390_TLS_LDCALL:
+ case BFD_RELOC_390_TLS_GD32:
+ case BFD_RELOC_390_TLS_GD64:
+ case BFD_RELOC_390_TLS_GOTIE12:
+ case BFD_RELOC_390_TLS_GOTIE20:
+ case BFD_RELOC_390_TLS_GOTIE32:
+ case BFD_RELOC_390_TLS_GOTIE64:
+ case BFD_RELOC_390_TLS_LDM32:
+ case BFD_RELOC_390_TLS_LDM64:
+ case BFD_RELOC_390_TLS_IE32:
+ case BFD_RELOC_390_TLS_IE64:
+ case BFD_RELOC_390_TLS_LE32:
+ case BFD_RELOC_390_TLS_LE64:
+ case BFD_RELOC_390_TLS_LDO32:
+ case BFD_RELOC_390_TLS_LDO64:
+ case BFD_RELOC_390_TLS_DTPMOD:
+ case BFD_RELOC_390_TLS_DTPOFF:
+ case BFD_RELOC_390_TLS_TPOFF:
+ /* Fully resolved at link time. */
+ break;
+ case BFD_RELOC_390_TLS_IEENT:
+ /* Fully resolved at link time. */
+ value += 2;
+ break;
+
default:
{
const char *reloc_name = bfd_get_reloc_code_name (fixP->fx_r_type);
@@ -1976,3 +2285,27 @@ tc_gen_reloc (seg, fixp)
return reloc;
}
+
+void
+s390_cfi_frame_initial_instructions ()
+{
+ cfi_add_CFA_def_cfa (15, s390_arch_size == 64 ? 160 : 96);
+}
+
+int
+tc_s390_regname_to_dw2regnum (const char *regname)
+{
+ int regnum = -1;
+
+ if (regname[0] != 'c' && regname[0] != 'a')
+ {
+ regnum = reg_name_search (pre_defined_registers, REG_NAME_CNT, regname);
+ if (regname[0] == 'f' && regnum != -1)
+ regnum += 16;
+ }
+ else if (strcmp (regname, "ap") == 0)
+ regnum = 32;
+ else if (strcmp (regname, "cc") == 0)
+ regnum = 33;
+ return regnum;
+}
diff --git a/contrib/binutils/gas/config/tc-s390.h b/contrib/binutils/gas/config/tc-s390.h
index 48dbeda..fe55e15 100644
--- a/contrib/binutils/gas/config/tc-s390.h
+++ b/contrib/binutils/gas/config/tc-s390.h
@@ -1,5 +1,5 @@
/* tc-s390.h -- Header file for tc-s390.c.
- Copyright 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 2000, 2001, 2002, 2004 Free Software Foundation, Inc.
Written by Martin Schwidefsky (schwidefsky@de.ibm.com).
This file is part of GAS, the GNU Assembler.
@@ -29,29 +29,18 @@ struct fix;
#error S390 support requires BFD_ASSEMBLER
#endif
-/* This expression evaluates to false if the relocation is for a local object
- for which we still want to do the relocation at runtime. True if we
- are willing to perform this relocation while building the .o file.
- This is only used for pcrel relocations, so GOTOFF does not need to be
- checked here. I am not sure if some of the others are ever used with
- pcrel, but it is easier to be safe than sorry. */
-
-#define TC_RELOC_RTSYM_LOC_FIXUP(FIX) \
- ((FIX)->fx_r_type != BFD_RELOC_390_GOTENT \
- && ((FIX)->fx_addsy == NULL \
- || (! S_IS_EXTERNAL ((FIX)->fx_addsy) \
- && ! S_IS_WEAK ((FIX)->fx_addsy) \
- && S_IS_DEFINED ((FIX)->fx_addsy) \
- && ! S_IS_COMMON ((FIX)->fx_addsy))))
-
-#define TC_FORCE_RELOCATION(FIXP) tc_s390_force_relocation(FIXP)
+#define TC_FORCE_RELOCATION(FIX) tc_s390_force_relocation(FIX)
extern int tc_s390_force_relocation PARAMS ((struct fix *));
+/* Don't resolve foo@PLT-bar to offset@PLT. */
+#define TC_FORCE_RELOCATION_SUB_SAME(FIX, SEG) \
+ (! SEG_NORMAL (SEG) || TC_FORCE_RELOCATION (FIX))
+
#define tc_fix_adjustable(X) tc_s390_fix_adjustable(X)
extern int tc_s390_fix_adjustable PARAMS ((struct fix *));
-#define TC_FIX_ADJUSTABLE(fixP) \
- (! symbol_used_in_reloc_p ((fixP)->fx_addsy) && tc_fix_adjustable (fixP))
+/* Values passed to md_apply_fix3 don't include symbol values. */
+#define MD_APPLY_SYM_VALUE(FIX) 0
/* The target BFD architecture. */
#define TARGET_ARCH bfd_arch_s390
@@ -87,29 +76,27 @@ extern int target_big_endian;
#define md_number_to_chars number_to_chars_bigendian
-#define md_do_align(n, fill, len, max, around) \
-if ((n) && !need_pass_2 && (fill == 0) && \
- (bfd_get_section_flags (stdoutput, now_seg) & SEC_CODE) != 0) { \
- char *p; \
- p = frag_var (rs_align_code, 15, 1, (relax_substateT) max, \
- (symbolS *) 0, (offsetT) (n), (char *) 0); \
- *p = 0x07; \
- goto around; \
-}
-
-extern void s390_align_code PARAMS ((fragS *, int));
-
-#define HANDLE_ALIGN(fragP) \
-if (fragP->fr_type == rs_align_code) \
- s390_align_code (fragP, (fragP->fr_next->fr_address \
- - fragP->fr_address \
- - fragP->fr_fix));
+#define NOP_OPCODE 0x07
/* call md_pcrel_from_section, not md_pcrel_from */
-#define MD_PCREL_FROM_SECTION(FIXP, SEC) md_pcrel_from_section(FIXP, SEC)
+#define MD_PCREL_FROM_SECTION(FIX, SEC) md_pcrel_from_section(FIX, SEC)
extern long md_pcrel_from_section PARAMS ((struct fix *, segT));
#define md_operand(x)
extern void s390_md_end PARAMS ((void));
#define md_end() s390_md_end ()
+
+#define TARGET_USE_CFIPOP 1
+
+#define tc_cfi_frame_initial_instructions s390_cfi_frame_initial_instructions
+extern void s390_cfi_frame_initial_instructions PARAMS ((void));
+
+#define tc_regname_to_dw2regnum tc_s390_regname_to_dw2regnum
+extern int tc_s390_regname_to_dw2regnum PARAMS ((const char *regname));
+
+extern int s390_cie_data_alignment;
+
+#define DWARF2_LINE_MIN_INSN_LENGTH 1
+#define DWARF2_DEFAULT_RETURN_COLUMN 14
+#define DWARF2_CIE_DATA_ALIGNMENT s390_cie_data_alignment
diff --git a/contrib/binutils/gas/config/tc-sparc.c b/contrib/binutils/gas/config/tc-sparc.c
index 5fa4fe9..ba6b4ed 100644
--- a/contrib/binutils/gas/config/tc-sparc.c
+++ b/contrib/binutils/gas/config/tc-sparc.c
@@ -1,6 +1,6 @@
/* tc-sparc.c -- Assemble for the SPARC
Copyright 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
- 1999, 2000, 2001, 2002
+ 1999, 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -26,6 +26,7 @@
#include "subsegs.h"
#include "opcode/sparc.h"
+#include "dw2gencfi.h"
#ifdef OBJ_ELF
#include "elf/sparc.h"
@@ -116,6 +117,9 @@ static int target_little_endian_data;
/* Symbols for global registers on v9. */
static symbolS *globals[8];
+/* The dwarf2 data alignment, adjusted for 32 or 64 bit. */
+int sparc_cie_data_alignment;
+
/* V9 and 86x have big and little endian data, but instructions are always big
endian. The sparclet has bi-endian support but both data and insns have
the same endianness. Global `target_big_endian' is used for data.
@@ -138,7 +142,9 @@ static void s_common PARAMS ((int));
static void s_empty PARAMS ((int));
static void s_uacons PARAMS ((int));
static void s_ncons PARAMS ((int));
+#ifdef OBJ_ELF
static void s_register PARAMS ((int));
+#endif
const pseudo_typeS md_pseudo_table[] =
{
@@ -159,8 +165,6 @@ const pseudo_typeS md_pseudo_table[] =
{"uaword", s_uacons, 4},
{"uaxword", s_uacons, 8},
#ifdef OBJ_ELF
- {"file", (void (*) PARAMS ((int))) dwarf2_directive_file, 0},
- {"loc", dwarf2_directive_loc, 0},
/* These are specific to sparc/svr4. */
{"2byte", s_uacons, 2},
{"4byte", s_uacons, 4},
@@ -723,7 +727,7 @@ struct
{NULL, NULL, NULL},
};
-/* sparc64 priviledged registers. */
+/* sparc64 privileged registers. */
struct priv_reg_entry
{
@@ -798,6 +802,7 @@ md_begin ()
if (! default_init_p)
init_default_arch ();
+ sparc_cie_data_alignment = sparc_arch_size == 64 ? -8 : -4;
op_hash = hash_new ();
while (i < (unsigned int) sparc_num_opcodes)
@@ -1804,10 +1809,88 @@ sparc_ip (str, pinsn)
break;
case '\0': /* End of args. */
- if (*s == '\0')
+ if (s[0] == ',' && s[1] == '%')
{
- match = 1;
+ static const struct tls_ops {
+ /* The name as it appears in assembler. */
+ char *name;
+ /* strlen (name), precomputed for speed */
+ int len;
+ /* The reloc this pseudo-op translates to. */
+ int reloc;
+ /* 1 if call. */
+ int call;
+ } tls_ops[] = {
+ { "tgd_add", 7, BFD_RELOC_SPARC_TLS_GD_ADD, 0 },
+ { "tgd_call", 8, BFD_RELOC_SPARC_TLS_GD_CALL, 1 },
+ { "tldm_add", 8, BFD_RELOC_SPARC_TLS_LDM_ADD, 0 },
+ { "tldm_call", 9, BFD_RELOC_SPARC_TLS_LDM_CALL, 1 },
+ { "tldo_add", 8, BFD_RELOC_SPARC_TLS_LDO_ADD, 0 },
+ { "tie_ldx", 7, BFD_RELOC_SPARC_TLS_IE_LDX, 0 },
+ { "tie_ld", 6, BFD_RELOC_SPARC_TLS_IE_LD, 0 },
+ { "tie_add", 7, BFD_RELOC_SPARC_TLS_IE_ADD, 0 }
+ };
+ const struct tls_ops *o;
+ char *s1;
+ int npar = 0;
+
+ for (o = tls_ops; o->name; o++)
+ if (strncmp (s + 2, o->name, o->len) == 0)
+ break;
+ if (o->name == NULL)
+ break;
+
+ if (s[o->len + 2] != '(')
+ {
+ as_bad (_("Illegal operands: %%%s requires arguments in ()"), o->name);
+ return special_case;
+ }
+
+ if (! o->call && the_insn.reloc != BFD_RELOC_NONE)
+ {
+ as_bad (_("Illegal operands: %%%s cannot be used together with other relocs in the insn ()"),
+ o->name);
+ return special_case;
+ }
+
+ if (o->call
+ && (the_insn.reloc != BFD_RELOC_32_PCREL_S2
+ || the_insn.exp.X_add_number != 0
+ || the_insn.exp.X_add_symbol
+ != symbol_find_or_make ("__tls_get_addr")))
+ {
+ as_bad (_("Illegal operands: %%%s can be only used with call __tls_get_addr"),
+ o->name);
+ return special_case;
+ }
+
+ the_insn.reloc = o->reloc;
+ memset (&the_insn.exp, 0, sizeof (the_insn.exp));
+ s += o->len + 3;
+
+ for (s1 = s; *s1 && *s1 != ',' && *s1 != ']'; s1++)
+ if (*s1 == '(')
+ npar++;
+ else if (*s1 == ')')
+ {
+ if (!npar)
+ break;
+ npar--;
+ }
+
+ if (*s1 != ')')
+ {
+ as_bad (_("Illegal operands: %%%s requires arguments in ()"), o->name);
+ return special_case;
+ }
+
+ *s1 = '\0';
+ (void) get_expression (s);
+ *s1 = ')';
+ s = s1 + 1;
}
+ if (*s == '\0')
+ match = 1;
break;
case '+':
@@ -2063,6 +2146,12 @@ sparc_ip (str, pinsn)
{
if (SPARC_OPCODE_ARCH_V9_P (max_architecture))
{
+ if (*args == 'e' || *args == 'f' || *args == 'g')
+ {
+ error_message
+ = _(": There are only 32 single precision f registers; [0-31]");
+ goto error;
+ }
v9_arg_p = 1;
mask -= 31; /* wrap high bit */
}
@@ -2174,6 +2263,18 @@ sparc_ip (str, pinsn)
{ "l44", 3, BFD_RELOC_SPARC_L44, 1, 0 },
{ "uhi", 3, BFD_RELOC_SPARC_HH22, 1, 0 },
{ "ulo", 3, BFD_RELOC_SPARC_HM10, 1, 0 },
+ { "tgd_hi22", 8, BFD_RELOC_SPARC_TLS_GD_HI22, 0, 0 },
+ { "tgd_lo10", 8, BFD_RELOC_SPARC_TLS_GD_LO10, 0, 0 },
+ { "tldm_hi22", 9, BFD_RELOC_SPARC_TLS_LDM_HI22, 0, 0 },
+ { "tldm_lo10", 9, BFD_RELOC_SPARC_TLS_LDM_LO10, 0, 0 },
+ { "tldo_hix22", 10, BFD_RELOC_SPARC_TLS_LDO_HIX22, 0,
+ 0 },
+ { "tldo_lox10", 10, BFD_RELOC_SPARC_TLS_LDO_LOX10, 0,
+ 0 },
+ { "tie_hi22", 8, BFD_RELOC_SPARC_TLS_IE_HI22, 0, 0 },
+ { "tie_lo10", 8, BFD_RELOC_SPARC_TLS_IE_LO10, 0, 0 },
+ { "tle_hix22", 9, BFD_RELOC_SPARC_TLS_LE_HIX22, 0, 0 },
+ { "tle_lox10", 9, BFD_RELOC_SPARC_TLS_LE_LOX10, 0, 0 },
{ NULL, 0, 0, 0, 0 }
};
const struct ops *o;
@@ -2376,6 +2477,13 @@ sparc_ip (str, pinsn)
goto error;
}
+ if (the_insn.reloc >= BFD_RELOC_SPARC_TLS_GD_HI22
+ && the_insn.reloc <= BFD_RELOC_SPARC_TLS_TPOFF64)
+ {
+ error_message = _(": TLS operand can't be a constant");
+ goto error;
+ }
+
/* Constants that won't fit are checked in md_apply_fix3
and bfd_install_relocation.
??? It would be preferable to install the constants
@@ -2891,7 +2999,7 @@ void
md_apply_fix3 (fixP, valP, segment)
fixS *fixP;
valueT *valP;
- segT segment;
+ segT segment ATTRIBUTE_UNUSED;
{
char *buf = fixP->fx_where + fixP->fx_frag->fr_literal;
offsetT val = * (offsetT *) valP;
@@ -2902,34 +3010,9 @@ md_apply_fix3 (fixP, valP, segment)
fixP->fx_addnumber = val; /* Remember value for emit_reloc. */
#ifdef OBJ_ELF
- /* FIXME: SPARC ELF relocations don't use an addend in the data
- field itself. This whole approach should be somehow combined
- with the calls to bfd_install_relocation. Also, the value passed
- in by fixup_segment includes the value of a defined symbol. We
- don't want to include the value of an externally visible symbol. */
+ /* SPARC ELF relocations don't use an addend in the data field. */
if (fixP->fx_addsy != NULL)
- {
- symbolS * sym = fixP->fx_addsy;
- segT seg = S_GET_SEGMENT (sym);
-
- if (symbol_used_in_reloc_p (sym)
- && (S_IS_EXTERNAL (sym)
- || S_IS_WEAK (sym)
- || (seg->flags & SEC_MERGE)
- || (seg->flags & SEC_THREAD_LOCAL)
- || (sparc_pic_code && ! fixP->fx_pcrel)
- || (seg != segment
- && (((bfd_get_section_flags (stdoutput, seg) & SEC_LINK_ONCE) != 0)
- || (strncmp (segment_name (seg),
- ".gnu.linkonce",
- sizeof ".gnu.linkonce" - 1) == 0))))
- && seg != absolute_section
- && seg != undefined_section
- && ! bfd_is_com_section (seg))
- fixP->fx_addnumber -= S_GET_VALUE (sym);
-
- return;
- }
+ return;
#endif
/* This is a hack. There should be a better way to
@@ -3271,7 +3354,7 @@ md_apply_fix3 (fixP, valP, segment)
arelent **
tc_gen_reloc (section, fixp)
- asection *section;
+ asection *section ATTRIBUTE_UNUSED;
fixS *fixp;
{
static arelent *relocs[3];
@@ -3328,6 +3411,26 @@ tc_gen_reloc (section, fixp)
case BFD_RELOC_SPARC_PLT64:
case BFD_RELOC_VTABLE_ENTRY:
case BFD_RELOC_VTABLE_INHERIT:
+ case BFD_RELOC_SPARC_TLS_GD_HI22:
+ case BFD_RELOC_SPARC_TLS_GD_LO10:
+ case BFD_RELOC_SPARC_TLS_GD_ADD:
+ case BFD_RELOC_SPARC_TLS_GD_CALL:
+ case BFD_RELOC_SPARC_TLS_LDM_HI22:
+ case BFD_RELOC_SPARC_TLS_LDM_LO10:
+ case BFD_RELOC_SPARC_TLS_LDM_ADD:
+ case BFD_RELOC_SPARC_TLS_LDM_CALL:
+ case BFD_RELOC_SPARC_TLS_LDO_HIX22:
+ case BFD_RELOC_SPARC_TLS_LDO_LOX10:
+ case BFD_RELOC_SPARC_TLS_LDO_ADD:
+ case BFD_RELOC_SPARC_TLS_IE_HI22:
+ case BFD_RELOC_SPARC_TLS_IE_LO10:
+ case BFD_RELOC_SPARC_TLS_IE_LD:
+ case BFD_RELOC_SPARC_TLS_IE_LDX:
+ case BFD_RELOC_SPARC_TLS_IE_ADD:
+ case BFD_RELOC_SPARC_TLS_LE_HIX22:
+ case BFD_RELOC_SPARC_TLS_LE_LOX10:
+ case BFD_RELOC_SPARC_TLS_DTPOFF32:
+ case BFD_RELOC_SPARC_TLS_DTPOFF64:
code = fixp->fx_r_type;
break;
default:
@@ -3352,10 +3455,7 @@ tc_gen_reloc (section, fixp)
switch (code)
{
case BFD_RELOC_32_PCREL_S2:
- if (! S_IS_DEFINED (fixp->fx_addsy)
- || S_IS_COMMON (fixp->fx_addsy)
- || S_IS_EXTERNAL (fixp->fx_addsy)
- || S_IS_WEAK (fixp->fx_addsy))
+ if (generic_force_reloc (fixp))
code = BFD_RELOC_SPARC_WPLT30;
break;
case BFD_RELOC_HI22:
@@ -3419,7 +3519,9 @@ tc_gen_reloc (section, fixp)
&& code != BFD_RELOC_SPARC_WDISP22
&& code != BFD_RELOC_SPARC_WDISP16
&& code != BFD_RELOC_SPARC_WDISP19
- && code != BFD_RELOC_SPARC_WPLT30)
+ && code != BFD_RELOC_SPARC_WPLT30
+ && code != BFD_RELOC_SPARC_TLS_GD_CALL
+ && code != BFD_RELOC_SPARC_TLS_LDM_CALL)
reloc->addend = fixp->fx_addnumber;
else if (symbol_section_p (fixp->fx_addsy))
reloc->addend = (section->vma
@@ -3673,7 +3775,7 @@ s_common (ignore)
char *name;
char c;
char *p;
- int temp, size;
+ offsetT temp, size;
symbolS *symbolP;
name = input_line_pointer;
@@ -3694,7 +3796,8 @@ s_common (ignore)
if ((temp = get_absolute_expression ()) < 0)
{
- as_bad (_(".COMMon length (%d.) <0! Ignored."), temp);
+ as_bad (_(".COMMon length (%lu) out of range ignored"),
+ (unsigned long) temp);
ignore_rest_of_line ();
return;
}
@@ -3712,8 +3815,8 @@ s_common (ignore)
{
if (S_GET_VALUE (symbolP) != (valueT) size)
{
- as_warn (_("Length of .comm \"%s\" is already %ld. Not changed to %d."),
- S_GET_NAME (symbolP), (long) S_GET_VALUE (symbolP), size);
+ as_warn (_("Length of .comm \"%s\" is already %ld. Not changed to %ld."),
+ S_GET_NAME (symbolP), (long) S_GET_VALUE (symbolP), (long) size);
}
}
else
@@ -3844,7 +3947,7 @@ s_common (ignore)
}
}
-/* Handle the .empty pseudo-op. This supresses the warnings about
+/* Handle the .empty pseudo-op. This suppresses the warnings about
invalid delay slot usage. */
static void
@@ -3911,7 +4014,7 @@ s_proc (ignore)
}
/* This static variable is set by s_uacons to tell sparc_cons_align
- that the expession does not need to be aligned. */
+ that the expression does not need to be aligned. */
static int sparc_no_align_cons = 0;
@@ -4222,6 +4325,16 @@ sparc_cons (exp, size)
sparc_cons_special_reloc = "plt";
}
}
+ else if (strncmp (input_line_pointer + 3, "tls_dtpoff", 10) == 0)
+ {
+ if (size != 4 && size != 8)
+ as_bad (_("Illegal operands: %%r_tls_dtpoff in %d-byte data field"), size);
+ else
+ {
+ input_line_pointer += 13;
+ sparc_cons_special_reloc = "tls_dtpoff";
+ }
+ }
if (sparc_cons_special_reloc)
{
int bad = 0;
@@ -4355,12 +4468,18 @@ cons_fix_new_sparc (frag, where, nbytes, exp)
case 8: r = BFD_RELOC_64_PCREL; break;
default: abort ();
}
- else
+ else if (*sparc_cons_special_reloc == 'p')
switch (nbytes)
{
case 4: r = BFD_RELOC_SPARC_PLT32; break;
case 8: r = BFD_RELOC_SPARC_PLT64; break;
}
+ else
+ switch (nbytes)
+ {
+ case 4: r = BFD_RELOC_SPARC_TLS_DTPOFF32; break;
+ case 8: r = BFD_RELOC_SPARC_TLS_DTPOFF64; break;
+ }
}
else if (sparc_no_align_cons)
{
@@ -4374,17 +4493,63 @@ cons_fix_new_sparc (frag, where, nbytes, exp)
}
fix_new_exp (frag, where, (int) nbytes, exp, 0, r);
+ sparc_cons_special_reloc = NULL;
+}
+
+void
+sparc_cfi_frame_initial_instructions ()
+{
+ cfi_add_CFA_def_cfa (14, sparc_arch_size == 64 ? 0x7ff : 0);
}
-#ifdef OBJ_ELF
int
-elf32_sparc_force_relocation (fixp)
- struct fix *fixp;
+sparc_regname_to_dw2regnum (const char *regname)
{
- if (fixp->fx_r_type == BFD_RELOC_VTABLE_INHERIT
- || fixp->fx_r_type == BFD_RELOC_VTABLE_ENTRY)
- return 1;
+ char *p, *q;
- return 0;
+ if (!regname[0])
+ return -1;
+
+ q = "goli";
+ p = strchr (q, regname[0]);
+ if (p)
+ {
+ if (regname[1] < '0' || regname[1] > '8' || regname[2])
+ return -1;
+ return (p - q) * 8 + regname[1] - '0';
+ }
+ if (regname[0] == 's' && regname[1] == 'p' && !regname[2])
+ return 14;
+ if (regname[0] == 'f' && regname[1] == 'p' && !regname[2])
+ return 30;
+ if (regname[0] == 'f' || regname[0] == 'r')
+ {
+ unsigned int regnum;
+
+ regnum = strtoul (regname + 1, &q, 10);
+ if (p == q || *q)
+ return -1;
+ if (regnum >= ((regname[0] == 'f'
+ && SPARC_OPCODE_ARCH_V9_P (max_architecture))
+ ? 64 : 32))
+ return -1;
+ if (regname[0] == 'f')
+ {
+ regnum += 32;
+ if (regnum >= 64 && (regnum & 1))
+ return -1;
+ }
+ return regnum;
+ }
+ return -1;
+}
+
+void
+sparc_cfi_emit_pcrel_expr (expressionS *exp, unsigned int nbytes)
+{
+ sparc_cons_special_reloc = "disp";
+ sparc_no_align_cons = 1;
+ emit_expr (exp, nbytes);
+ sparc_no_align_cons = 0;
+ sparc_cons_special_reloc = NULL;
}
-#endif
diff --git a/contrib/binutils/gas/config/tc-sparc.h b/contrib/binutils/gas/config/tc-sparc.h
index 5d545de..e99222b 100644
--- a/contrib/binutils/gas/config/tc-sparc.h
+++ b/contrib/binutils/gas/config/tc-sparc.h
@@ -1,6 +1,6 @@
/* tc-sparc.h - Macros and type defines for the sparc.
Copyright 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
- 1999, 2000, 2001 Free Software Foundation, Inc.
+ 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -69,74 +69,56 @@ extern void sparc_handle_align PARAMS ((struct frag *));
#define MAX_MEM_FOR_RS_ALIGN_CODE (3 + 4 + 4)
-#if defined (OBJ_ELF) || defined (OBJ_AOUT)
-
-/* This expression evaluates to false if the relocation is for a local
- object for which we still want to do the relocation at runtime.
- True if we are willing to perform this relocation while building
- the .o file.
-
- If the reloc is against an externally visible symbol, then the
- a.out assembler should not do the relocation if generating PIC, and
- the ELF assembler should never do the relocation. */
-
-#ifdef OBJ_ELF
-#define obj_relocate_extern 0
-#else
-#define obj_relocate_extern (! sparc_pic_code)
-#endif
-
-#define TC_RELOC_RTSYM_LOC_FIXUP(FIX) \
- (obj_relocate_extern \
- || (FIX)->fx_addsy == NULL \
- || (! S_IS_EXTERNAL ((FIX)->fx_addsy) \
- && ! S_IS_WEAK ((FIX)->fx_addsy) \
- && S_IS_DEFINED ((FIX)->fx_addsy) \
- && ! S_IS_COMMON ((FIX)->fx_addsy)))
-#endif
-
/* I know that "call 0" fails in sparc-coff if this doesn't return 1. I
don't know about other relocation types, or other formats, yet. */
#ifdef OBJ_COFF
-#define TC_FORCE_RELOCATION(FIXP) \
- ((FIXP)->fx_r_type == BFD_RELOC_32_PCREL_S2 \
- && ((FIXP)->fx_addsy == 0 \
- || S_GET_SEGMENT ((FIXP)->fx_addsy) == absolute_section))
+#define TC_FORCE_RELOCATION_ABS(FIX) \
+ ((FIX)->fx_r_type == BFD_RELOC_32_PCREL_S2 \
+ || TC_FORCE_RELOCATION (FIX))
+
#define RELOC_REQUIRES_SYMBOL
#endif
-#ifdef OBJ_ELF
-#define TC_FORCE_RELOCATION(fixp) elf32_sparc_force_relocation(fixp)
-extern int elf32_sparc_force_relocation PARAMS ((struct fix *));
+#ifdef OBJ_AOUT
+/* This expression evaluates to true if the relocation is for a local
+ object for which we still want to do the relocation at runtime.
+ False if we are willing to perform this relocation while building
+ the .o file. */
+
+#define TC_FORCE_RELOCATION_LOCAL(FIX) \
+ (!(FIX)->fx_pcrel \
+ || (FIX)->fx_plt \
+ || (sparc_pic_code \
+ && S_IS_EXTERNAL ((FIX)->fx_addsy)) \
+ || TC_FORCE_RELOCATION (FIX))
#endif
#ifdef OBJ_ELF
-/* Keep relocations against global symbols. Don't turn them into
- relocations against sections. This is required for the dynamic
- linker to operate properly. When generating PIC, we need to keep
- any non PC relative reloc. The PIC part of this test must be
- parallel to the code in tc_gen_reloc which converts relocations to
- GOT relocations. */
+/* Don't turn certain relocs into relocations against sections. This
+ is required for the dynamic linker to operate properly. When
+ generating PIC, we need to keep any non PC relative reloc. The PIC
+ part of this test must be parallel to the code in tc_gen_reloc which
+ converts relocations to GOT relocations. */
#define tc_fix_adjustable(FIX) \
- (! S_IS_EXTERNAL ((FIX)->fx_addsy) \
- && ! S_IS_WEAK ((FIX)->fx_addsy) \
- && (FIX)->fx_r_type != BFD_RELOC_VTABLE_INHERIT \
+ ((FIX)->fx_r_type != BFD_RELOC_VTABLE_INHERIT \
&& (FIX)->fx_r_type != BFD_RELOC_VTABLE_ENTRY \
+ && ((FIX)->fx_r_type < BFD_RELOC_SPARC_TLS_GD_HI22 \
+ || (FIX)->fx_r_type > BFD_RELOC_SPARC_TLS_TPOFF64) \
&& (! sparc_pic_code \
|| ((FIX)->fx_r_type != BFD_RELOC_HI22 \
&& (FIX)->fx_r_type != BFD_RELOC_LO10 \
&& (FIX)->fx_r_type != BFD_RELOC_SPARC13 \
&& ((FIX)->fx_r_type != BFD_RELOC_32_PCREL_S2 \
- || (S_IS_DEFINED ((FIX)->fx_addsy) \
- && ! S_IS_COMMON ((FIX)->fx_addsy) \
- && ! S_IS_EXTERNAL ((FIX)->fx_addsy) \
- && ! S_IS_WEAK ((FIX)->fx_addsy))) \
+ || !generic_force_reloc (FIX)) \
&& ((FIX)->fx_pcrel \
|| ((FIX)->fx_subsy != NULL \
&& (S_GET_SEGMENT ((FIX)->fx_subsy) \
== S_GET_SEGMENT ((FIX)->fx_addsy))) \
|| S_IS_LOCAL ((FIX)->fx_addsy)))))
+/* Values passed to md_apply_fix3 don't include the symbol value. */
+#define MD_APPLY_SYM_VALUE(FIX) 0
+
/* Finish up the entire symtab. */
#define tc_adjust_symtab() sparc_adjust_symtab ()
extern void sparc_adjust_symtab PARAMS ((void));
@@ -184,14 +166,29 @@ extern void cons_fix_new_sparc
} \
while (0)
-#define TC_FIX_DATA_PRINT(FILE, FIXP) \
+#define TC_FIX_DATA_PRINT(FILE, FIX) \
do \
{ \
fprintf ((FILE), "addend2=%ld\n", \
- (unsigned long) (FIXP)->tc_fix_data); \
+ (unsigned long) (FIX)->tc_fix_data); \
} \
while (0)
-#define DWARF2_LINE_MIN_INSN_LENGTH 4
+#define TARGET_USE_CFIPOP 1
+
+#define tc_cfi_frame_initial_instructions sparc_cfi_frame_initial_instructions
+extern void sparc_cfi_frame_initial_instructions PARAMS ((void));
+
+#define tc_regname_to_dw2regnum sparc_regname_to_dw2regnum
+extern int sparc_regname_to_dw2regnum PARAMS ((const char *regname));
+
+#define tc_cfi_emit_pcrel_expr sparc_cfi_emit_pcrel_expr
+extern void sparc_cfi_emit_pcrel_expr PARAMS ((expressionS *, unsigned int));
+
+extern int sparc_cie_data_alignment;
+
+#define DWARF2_LINE_MIN_INSN_LENGTH 4
+#define DWARF2_DEFAULT_RETURN_COLUMN 15
+#define DWARF2_CIE_DATA_ALIGNMENT sparc_cie_data_alignment
/* end of tc-sparc.h */
diff --git a/contrib/binutils/gas/config/te-generic.h b/contrib/binutils/gas/config/te-generic.h
index b8eda45..400a576 100644
--- a/contrib/binutils/gas/config/te-generic.h
+++ b/contrib/binutils/gas/config/te-generic.h
@@ -6,7 +6,7 @@
* compile, and copying as an aid for testing and porting. xoxorich.
*/
-/* Added these, because if we don't know what we're targetting we may
+/* Added these, because if we don't know what we're targeting we may
need an assembler version of libgcc, and that will use local
labels. */
#define LOCAL_LABELS_DOLLAR 1
diff --git a/contrib/binutils/gas/config/te-pe.h b/contrib/binutils/gas/config/te-pe.h
index 1c1f0b2..b3e0764 100644
--- a/contrib/binutils/gas/config/te-pe.h
+++ b/contrib/binutils/gas/config/te-pe.h
@@ -1,5 +1,5 @@
#define TE_PE
-#define LEX_AT 1 /* can have @'s inside labels */
+#define LEX_AT (LEX_BEGIN_NAME | LEX_NAME) /* Can have @'s inside labels. */
/* The PE format supports long section names. */
#define COFF_LONG_SECTION_NAMES
diff --git a/contrib/binutils/gas/config/te-ppcnw.h b/contrib/binutils/gas/config/te-ppcnw.h
index fcd3a972..1337591 100644
--- a/contrib/binutils/gas/config/te-ppcnw.h
+++ b/contrib/binutils/gas/config/te-ppcnw.h
@@ -18,7 +18,7 @@
the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
02111-1307, USA. */
-/* Added these, because if we don't know what we're targetting we may
+/* Added these, because if we don't know what we're targeting we may
need an assembler version of libgcc, and that will use local
labels. */
#define LOCAL_LABELS_DOLLAR 1
diff --git a/contrib/binutils/gas/dep-in.sed b/contrib/binutils/gas/dep-in.sed
index 4894cea..2e2717c 100644
--- a/contrib/binutils/gas/dep-in.sed
+++ b/contrib/binutils/gas/dep-in.sed
@@ -11,16 +11,18 @@ s!@SRCDIR@/config!$(srcdir)/config!g
s!@SRCDIR@/\.\./opcodes!$(srcdir)/../opcodes!g
s!@TOPDIR@/opcodes!$(srcdir)/../opcodes!g
s!@SRCDIR@/!!g
+s!\.\./bfd/bfdver\.h!$(BFDVER_H)!g
s! \$(srcdir)/config/te-generic\.h!!g
s! \.\./bfd/bfd\.h!!g
s! itbl-cpu\.h!!g
s! itbl-parse\.h!!g
+s! \.\./intl/libintl\.h!!g
s! \$(INCDIR)/bin-bugs\.h!!g
s! \$(INCDIR)/ansidecl\.h!!g
s! \$(INCDIR)/libiberty\.h!!g
s! \$(INCDIR)/progress\.h!!g
-s! \$(INCDIR)/fopen-same\.h!!g
+s! \$(INCDIR)/fopen-[^ ]*\.h!!g
s! obj-format\.h!!g
s! targ-cpu\.h!!g
s! targ-env\.h!!g
diff --git a/contrib/binutils/gas/depend.c b/contrib/binutils/gas/depend.c
index 3c6049d..127c819 100644
--- a/contrib/binutils/gas/depend.c
+++ b/contrib/binutils/gas/depend.c
@@ -35,8 +35,8 @@ static struct dependency * dep_chain = NULL;
/* Current column in output file. */
static int column = 0;
-static int quote_string_for_make PARAMS ((FILE *, char *));
-static void wrap_output PARAMS ((FILE *, char *, int));
+static int quote_string_for_make (FILE *, char *);
+static void wrap_output (FILE *, char *, int);
/* Number of columns allowable. */
#define MAX_COLUMNS 72
@@ -45,8 +45,7 @@ static void wrap_output PARAMS ((FILE *, char *, int));
never called, then dependency tracking is simply skipped. */
void
-start_dependencies (filename)
- char *filename;
+start_dependencies (char *filename)
{
dep_file = filename;
}
@@ -54,8 +53,7 @@ start_dependencies (filename)
/* Noticed a new filename, so try to register it. */
void
-register_dependency (filename)
- char *filename;
+register_dependency (char *filename)
{
struct dependency *dep;
@@ -81,9 +79,7 @@ register_dependency (filename)
This code is taken from gcc with only minor changes. */
static int
-quote_string_for_make (file, src)
- FILE *file;
- char *src;
+quote_string_for_make (FILE *file, char *src)
{
char *p = src;
int i = 0;
@@ -145,10 +141,7 @@ quote_string_for_make (file, src)
wrapping as necessary. */
static void
-wrap_output (f, string, spacer)
- FILE *f;
- char *string;
- int spacer;
+wrap_output (FILE *f, char *string, int spacer)
{
int len = quote_string_for_make (NULL, string);
@@ -186,7 +179,7 @@ wrap_output (f, string, spacer)
/* Print dependency file. */
void
-print_dependencies ()
+print_dependencies (void)
{
FILE *f;
struct dependency *dep;
diff --git a/contrib/binutils/gas/doc/Makefile.am b/contrib/binutils/gas/doc/Makefile.am
index cfb8f89..7f0f805 100644
--- a/contrib/binutils/gas/doc/Makefile.am
+++ b/contrib/binutils/gas/doc/Makefile.am
@@ -1,6 +1,6 @@
## Process this file with automake to generate Makefile.in
-AUTOMAKE_OPTIONS = cygnus
+AUTOMAKE_OPTIONS = 1.8 cygnus
# What version of the manual you want; "all" includes everything
CONFIG=all
@@ -15,8 +15,6 @@ POD2MAN = pod2man --center="GNU Development Tools" \
man_MANS = as.1
-# The gasp.texi file is now deprecated, as GASP has been deprecated.
-# It will disappear in a future release.
info_TEXINFOS = as.texinfo
asconfig.texi: $(CONFIG).texi
@@ -39,12 +37,14 @@ CPU_DOCS = \
c-i386.texi \
c-i860.texi \
c-i960.texi \
+ c-ip2k.texi \
c-m32r.texi \
c-m68hc11.texi \
c-m68k.texi \
c-m88k.texi \
c-mips.texi \
c-mmix.texi \
+ c-msp430.texi \
c-ns32k.texi \
c-pdp11.texi \
c-pj.texi \
@@ -55,6 +55,7 @@ CPU_DOCS = \
c-tic54x.texi \
c-vax.texi \
c-v850.texi \
+ c-xtensa.texi \
c-z8k.texi
gasver.texi: Makefile
@@ -66,16 +67,21 @@ as.dvi: $(srcdir)/as.texinfo asconfig.texi gasver.texi $(CPU_DOCS)
# We want install to imply install-info as per GNU standards, despite the
# cygnus option.
-install: install-info
+install-data-local: install-info
# This one isn't ready for prime time yet. Not even a little bit.
-noinst_TEXINFOS = internals.texi gasp.texi
+noinst_TEXINFOS = internals.texi
DISTCLEANFILES = asconfig.texi
MAINTAINERCLEANFILES = gasver.texi
+BASEDIR = $(srcdir)/../..
+BFDDIR = $(BASEDIR)/bfd
+
+CONFIG_STATUS_DEPENDENCIES = $(BFDDIR)/configure.in
+
# Maintenance
# We need it for the taz target in ../../Makefile.in.
@@ -84,7 +90,7 @@ info: $(MANS)
# Build the man page from the texinfo file
# The sed command removes the no-adjust Nroff command so that
# the man output looks standard.
-as.1: $(srcdir)/as.texinfo
+as.1: $(srcdir)/as.texinfo asconfig.texi gasver.texi $(CPU_DOCS)
touch $@
-$(TEXI2POD) $(MANCONF) < $(srcdir)/as.texinfo > as.pod
-($(POD2MAN) as.pod | \
diff --git a/contrib/binutils/gas/doc/Makefile.in b/contrib/binutils/gas/doc/Makefile.in
index 25daeaf..0c6a1b0 100644
--- a/contrib/binutils/gas/doc/Makefile.in
+++ b/contrib/binutils/gas/doc/Makefile.in
@@ -1,6 +1,8 @@
-# Makefile.in generated automatically by automake 1.4-p5 from Makefile.am
+# Makefile.in generated by automake 1.8.4 from Makefile.am.
+# @configure_input@
-# Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc.
+# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+# 2003, 2004 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
@@ -10,132 +12,206 @@
# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
# PARTICULAR PURPOSE.
-
-SHELL = @SHELL@
-
+@SET_MAKE@
srcdir = @srcdir@
top_srcdir = @top_srcdir@
VPATH = @srcdir@
-prefix = @prefix@
-exec_prefix = @exec_prefix@
-
-bindir = @bindir@
-sbindir = @sbindir@
-libexecdir = @libexecdir@
-datadir = @datadir@
-sysconfdir = @sysconfdir@
-sharedstatedir = @sharedstatedir@
-localstatedir = @localstatedir@
-libdir = @libdir@
-infodir = @infodir@
-mandir = @mandir@
-includedir = @includedir@
-oldincludedir = /usr/include
-
-DESTDIR =
-
pkgdatadir = $(datadir)/@PACKAGE@
pkglibdir = $(libdir)/@PACKAGE@
pkgincludedir = $(includedir)/@PACKAGE@
-
top_builddir = ..
-
-ACLOCAL = @ACLOCAL@
-AUTOCONF = @AUTOCONF@
-AUTOMAKE = @AUTOMAKE@
-AUTOHEADER = @AUTOHEADER@
-
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
INSTALL = @INSTALL@
-INSTALL_PROGRAM = @INSTALL_PROGRAM@ $(AM_INSTALL_PROGRAM_FLAGS)
-INSTALL_DATA = @INSTALL_DATA@
-INSTALL_SCRIPT = @INSTALL_SCRIPT@
-transform = @program_transform_name@
-
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
NORMAL_INSTALL = :
PRE_INSTALL = :
POST_INSTALL = :
NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
-build_alias = @build_alias@
build_triplet = @build@
-host_alias = @host_alias@
host_triplet = @host@
-target_alias = @target_alias@
target_triplet = @target@
+subdir = doc
+DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/acinclude.m4 \
+ $(top_srcdir)/../libtool.m4 $(top_srcdir)/../gettext.m4 \
+ $(top_srcdir)/configure.in
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+mkinstalldirs = $(SHELL) $(top_srcdir)/../mkinstalldirs
+CONFIG_HEADER = $(top_builddir)/config.h
+CONFIG_CLEAN_FILES =
+depcomp =
+am__depfiles_maybe =
+SOURCES =
+DIST_SOURCES =
+INFO_DEPS = $(srcdir)/as.info
+TEXINFO_TEX = $(top_srcdir)/../texinfo/texinfo.tex
+am__TEXINFO_TEX_DIR = $(top_srcdir)/../texinfo
+DVIS = as.dvi
+PDFS = as.pdf
+PSS = as.ps
+HTMLS = as.html
+TEXINFOS = as.texinfo
+TEXI2DVI = `if test -f $(top_srcdir)/../texinfo/util/texi2dvi; then \
+ echo $(top_srcdir)/../texinfo/util/texi2dvi; \
+ else \
+ echo texi2dvi; \
+ fi`
+TEXI2PDF = $(TEXI2DVI) --pdf --batch
+MAKEINFOHTML = $(MAKEINFO) --html
+AM_MAKEINFOHTMLFLAGS = $(AM_MAKEINFOFLAGS)
+DVIPS = dvips
+man1dir = $(mandir)/man1
+am__installdirs = "$(DESTDIR)$(man1dir)"
+NROFF = nroff
+MANS = $(man_MANS)
+ACLOCAL = @ACLOCAL@
+ALLOCA = @ALLOCA@
ALL_OBJ_DEPS = @ALL_OBJ_DEPS@
-AS = @AS@
+AMDEP_FALSE = @AMDEP_FALSE@
+AMDEP_TRUE = @AMDEP_TRUE@
+AMTAR = @AMTAR@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
BFDLIB = @BFDLIB@
+BFDVER_H = @BFDVER_H@
CATALOGS = @CATALOGS@
CATOBJEXT = @CATOBJEXT@
CC = @CC@
-CXX = @CXX@
-CXXCPP = @CXXCPP@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CYGPATH_W = @CYGPATH_W@
DATADIRNAME = @DATADIRNAME@
-DLLTOOL = @DLLTOOL@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
EXEEXT = @EXEEXT@
-GCJ = @GCJ@
-GCJFLAGS = @GCJFLAGS@
GDBINIT = @GDBINIT@
GMOFILES = @GMOFILES@
GMSGFMT = @GMSGFMT@
GT_NO = @GT_NO@
GT_YES = @GT_YES@
INCLUDE_LOCALE_H = @INCLUDE_LOCALE_H@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
INSTOBJEXT = @INSTOBJEXT@
INTLDEPS = @INTLDEPS@
INTLLIBS = @INTLLIBS@
INTLOBJS = @INTLOBJS@
+LDFLAGS = @LDFLAGS@
LEX = @LEX@
+LEXLIB = @LEXLIB@
+LEX_OUTPUT_ROOT = @LEX_OUTPUT_ROOT@
LIBM = @LIBM@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
LIBTOOL = @LIBTOOL@
LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
MAINT = @MAINT@
+MAINTAINER_MODE_FALSE = @MAINTAINER_MODE_FALSE@
+MAINTAINER_MODE_TRUE = @MAINTAINER_MODE_TRUE@
MAKEINFO = @MAKEINFO@
MKINSTALLDIRS = @MKINSTALLDIRS@
MSGFMT = @MSGFMT@
-OBJDUMP = @OBJDUMP@
OBJEXT = @OBJEXT@
OPCODES_LIB = @OPCODES_LIB@
PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
POFILES = @POFILES@
POSUB = @POSUB@
RANLIB = @RANLIB@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
STRIP = @STRIP@
USE_INCLUDED_LIBINTL = @USE_INCLUDED_LIBINTL@
USE_NLS = @USE_NLS@
VERSION = @VERSION@
WARN_CFLAGS = @WARN_CFLAGS@
+XGETTEXT = @XGETTEXT@
YACC = @YACC@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_RANLIB = @ac_ct_RANLIB@
+ac_ct_STRIP = @ac_ct_STRIP@
+am__fastdepCC_FALSE = @am__fastdepCC_FALSE@
+am__fastdepCC_TRUE = @am__fastdepCC_TRUE@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
atof = @atof@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
cgen_cpu_prefix = @cgen_cpu_prefix@
+datadir = @datadir@
+exec_prefix = @exec_prefix@
extra_objects = @extra_objects@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
install_tooldir = @install_tooldir@
l = @l@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localstatedir = @localstatedir@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
obj_format = @obj_format@
+oldincludedir = @oldincludedir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+sysconfdir = @sysconfdir@
+target = @target@
+target_alias = @target_alias@
+target_cpu = @target_cpu@
target_cpu_type = @target_cpu_type@
+target_os = @target_os@
+target_vendor = @target_vendor@
te_file = @te_file@
-
-AUTOMAKE_OPTIONS = cygnus
+AUTOMAKE_OPTIONS = 1.8 cygnus
# What version of the manual you want; "all" includes everything
CONFIG = all
# Options to extract the man page from as.texinfo
MANCONF = -Dman
-
TEXI2POD = perl $(top_srcdir)/../etc/texi2pod.pl
-
POD2MAN = pod2man --center="GNU Development Tools" \
--release="binutils-$(VERSION)" --section=1
-
man_MANS = as.1
-
-# The gasp.texi file is now deprecated, as GASP has been deprecated.
-# It will disappear in a future release.
info_TEXINFOS = as.texinfo
-
CPU_DOCS = \
c-a29k.texi \
c-alpha.texi \
@@ -150,12 +226,14 @@ CPU_DOCS = \
c-i386.texi \
c-i860.texi \
c-i960.texi \
+ c-ip2k.texi \
c-m32r.texi \
c-m68hc11.texi \
c-m68k.texi \
c-m88k.texi \
c-mips.texi \
c-mmix.texi \
+ c-msp430.texi \
c-ns32k.texi \
c-pdp11.texi \
c-pj.texi \
@@ -166,161 +244,161 @@ CPU_DOCS = \
c-tic54x.texi \
c-vax.texi \
c-v850.texi \
+ c-xtensa.texi \
c-z8k.texi
# This one isn't ready for prime time yet. Not even a little bit.
-
-noinst_TEXINFOS = internals.texi gasp.texi
-
+noinst_TEXINFOS = internals.texi
DISTCLEANFILES = asconfig.texi
-
MAINTAINERCLEANFILES = gasver.texi
-mkinstalldirs = $(SHELL) $(top_srcdir)/../mkinstalldirs
-CONFIG_HEADER = ../config.h
-CONFIG_CLEAN_FILES =
-TEXI2DVI = `if test -f $(top_srcdir)/../texinfo/util/texi2dvi; then echo $(top_srcdir)/../texinfo/util/texi2dvi; else echo texi2dvi; fi`
-TEXINFO_TEX = $(top_srcdir)/../texinfo/texinfo.tex
-INFO_DEPS = as.info
-DVIS = as.dvi
-TEXINFOS = as.texinfo
-man1dir = $(mandir)/man1
-MANS = $(man_MANS)
+BASEDIR = $(srcdir)/../..
+BFDDIR = $(BASEDIR)/bfd
+CONFIG_STATUS_DEPENDENCIES = $(BFDDIR)/configure.in
+all: all-am
-NROFF = nroff
-DIST_COMMON = Makefile.am Makefile.in
-
-
-DISTFILES = $(DIST_COMMON) $(SOURCES) $(HEADERS) $(TEXINFOS) $(EXTRA_DIST)
-
-TAR = gtar
-GZIP_ENV = --best
-all: all-redirect
.SUFFIXES:
-.SUFFIXES: .dvi .info .ps .texi .texinfo .txi
-$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ Makefile.am $(top_srcdir)/configure.in $(ACLOCAL_M4)
- cd $(top_srcdir) && $(AUTOMAKE) --cygnus doc/Makefile
-
-Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
- cd $(top_builddir) \
- && CONFIG_FILES=$(subdir)/$@ CONFIG_HEADERS= $(SHELL) ./config.status
-
-
-as.info: as.texinfo
-as.dvi: as.texinfo
-
-
-DVIPS = dvips
-
-.texi.info:
- @rm -f $@ $@-[0-9] $@-[0-9][0-9]
- $(MAKEINFO) -I $(srcdir) $<
-
-.texi.dvi:
- TEXINPUTS=$(top_srcdir)/../texinfo/texinfo.tex:$$TEXINPUTS \
- MAKEINFO='$(MAKEINFO) -I $(srcdir)' $(TEXI2DVI) $<
-
-.texi:
- @rm -f $@ $@-[0-9] $@-[0-9][0-9]
- $(MAKEINFO) -I $(srcdir) $<
+.SUFFIXES: .dvi .html .info .pdf .ps .texinfo
+$(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
+ && exit 0; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign doc/Makefile'; \
+ cd $(top_srcdir) && \
+ $(AUTOMAKE) --foreign doc/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+
+distclean-libtool:
+ -rm -f libtool
.texinfo.info:
- @rm -f $@ $@-[0-9] $@-[0-9][0-9]
- $(MAKEINFO) -I $(srcdir) $<
-
-.texinfo:
- @rm -f $@ $@-[0-9] $@-[0-9][0-9]
- $(MAKEINFO) -I $(srcdir) $<
+ restore=: && \
+ backupdir="$(am__leading_dot)am$$$$" && \
+ am__cwd=`pwd` && cd $(srcdir) && \
+ rm -rf $$backupdir && mkdir $$backupdir && \
+ for f in $@ $@-[0-9] $@-[0-9][0-9] $(@:.info=).i[0-9] $(@:.info=).i[0-9][0-9]; do \
+ if test -f $$f; then \
+ mv $$f $$backupdir; \
+ restore=mv; \
+ fi; \
+ done; \
+ cd "$$am__cwd"; \
+ if $(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) -I $(srcdir) \
+ -o $@ $<; \
+ then \
+ rc=0; \
+ cd $(srcdir); \
+ else \
+ rc=$$?; \
+ cd $(srcdir) && \
+ $$restore $$backupdir/* `echo "./$@" | sed 's|[^/]*$$||'`; \
+ fi; \
+ rm -rf $$backupdir; \
+ exit $$rc
.texinfo.dvi:
- TEXINPUTS=$(top_srcdir)/../texinfo/texinfo.tex:$$TEXINPUTS \
- MAKEINFO='$(MAKEINFO) -I $(srcdir)' $(TEXI2DVI) $<
-
-.txi.info:
- @rm -f $@ $@-[0-9] $@-[0-9][0-9]
- $(MAKEINFO) -I $(srcdir) $<
-
-.txi.dvi:
- TEXINPUTS=$(top_srcdir)/../texinfo/texinfo.tex:$$TEXINPUTS \
- MAKEINFO='$(MAKEINFO) -I $(srcdir)' $(TEXI2DVI) $<
-
-.txi:
- @rm -f $@ $@-[0-9] $@-[0-9][0-9]
- $(MAKEINFO) -I $(srcdir) $<
+ TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
+ MAKEINFO='$(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) -I $(srcdir)' \
+ $(TEXI2DVI) $<
+
+.texinfo.pdf:
+ TEXINPUTS="$(am__TEXINFO_TEX_DIR)$(PATH_SEPARATOR)$$TEXINPUTS" \
+ MAKEINFO='$(MAKEINFO) $(AM_MAKEINFOFLAGS) $(MAKEINFOFLAGS) -I $(srcdir)' \
+ $(TEXI2PDF) $<
+
+.texinfo.html:
+ $(MAKEINFOHTML) $(AM_MAKEINFOHTMLFLAGS) $(MAKEINFOFLAGS) -I $(srcdir) \
+ -o $@ $<
+ if test ! -d $@ && test -d $(@:.html=); then \
+ mv $(@:.html=) $@; else :; fi
+$(srcdir)/as.info: as.texinfo
+as.pdf: as.texinfo
+as.html: as.texinfo
.dvi.ps:
- $(DVIPS) $< -o $@
+ $(DVIPS) -o $@ $<
-install-info-am: $(INFO_DEPS)
- @$(NORMAL_INSTALL)
- $(mkinstalldirs) $(DESTDIR)$(infodir)
- @list='$(INFO_DEPS)'; \
- for file in $$list; do \
- if test -f $$file; then d=.; else d=$(srcdir); fi; \
- for ifile in `cd $$d && echo $$file $$file-[0-9] $$file-[0-9][0-9]`; do \
- if test -f $$d/$$ifile; then \
- echo " $(INSTALL_DATA) $$d/$$ifile $(DESTDIR)$(infodir)/$$ifile"; \
- $(INSTALL_DATA) $$d/$$ifile $(DESTDIR)$(infodir)/$$ifile; \
- else : ; fi; \
- done; \
- done
- @$(POST_INSTALL)
- @if $(SHELL) -c 'install-info --version | sed 1q | fgrep -s -v -i debian' >/dev/null 2>&1; then \
+uninstall-info-am:
+ $(PRE_UNINSTALL)
+ @if (install-info --version && \
+ install-info --version 2>&1 | sed 1q | grep -i -v debian) >/dev/null 2>&1; then \
list='$(INFO_DEPS)'; \
for file in $$list; do \
- echo " install-info --info-dir=$(DESTDIR)$(infodir) $(DESTDIR)$(infodir)/$$file";\
- install-info --info-dir=$(DESTDIR)$(infodir) $(DESTDIR)$(infodir)/$$file || :;\
+ relfile=`echo "$$file" | sed 's|^.*/||'`; \
+ echo " install-info --info-dir='$(DESTDIR)$(infodir)' --remove '$(DESTDIR)$(infodir)/$$relfile'"; \
+ install-info --info-dir="$(DESTDIR)$(infodir)" --remove "$(DESTDIR)$(infodir)/$$relfile"; \
done; \
- else : ; fi
-
-uninstall-info:
- $(PRE_UNINSTALL)
- @if $(SHELL) -c 'install-info --version | sed 1q | fgrep -s -v -i debian' >/dev/null 2>&1; then \
- ii=yes; \
- else ii=; fi; \
- list='$(INFO_DEPS)'; \
- for file in $$list; do \
- test -z "$$ii" \
- || install-info --info-dir=$(DESTDIR)$(infodir) --remove $$file; \
- done
+ else :; fi
@$(NORMAL_UNINSTALL)
- list='$(INFO_DEPS)'; \
+ @list='$(INFO_DEPS)'; \
for file in $$list; do \
- (cd $(DESTDIR)$(infodir) && rm -f $$file $$file-[0-9] $$file-[0-9][0-9]); \
+ relfile=`echo "$$file" | sed 's|^.*/||'`; \
+ relfile_i=`echo "$$relfile" | sed 's|\.info$$||;s|$$|.i|'`; \
+ (if cd "$(DESTDIR)$(infodir)"; then \
+ echo " rm -f $$relfile $$relfile-[0-9] $$relfile-[0-9][0-9] $$relfile_i[0-9] $$relfile_i[0-9][0-9])"; \
+ rm -f $$relfile $$relfile-[0-9] $$relfile-[0-9][0-9] $$relfile_i[0-9] $$relfile_i[0-9][0-9]; \
+ else :; fi); \
done
dist-info: $(INFO_DEPS)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
list='$(INFO_DEPS)'; \
for base in $$list; do \
+ case $$base in \
+ $(srcdir)/*) base=`echo "$$base" | sed "s|^$$srcdirstrip/||"`;; \
+ esac; \
if test -f $$base; then d=.; else d=$(srcdir); fi; \
- for file in `cd $$d && eval echo $$base*`; do \
- test -f $(distdir)/$$file \
- || ln $$d/$$file $(distdir)/$$file 2> /dev/null \
- || cp -p $$d/$$file $(distdir)/$$file; \
+ for file in $$d/$$base*; do \
+ relfile=`expr "$$file" : "$$d/\(.*\)"`; \
+ test -f $(distdir)/$$relfile || \
+ cp -p $$file $(distdir)/$$relfile; \
done; \
done
mostlyclean-aminfo:
- -rm -f as.aux as.cp as.cps as.dvi as.fn as.fns as.ky as.kys as.ps \
- as.log as.pg as.toc as.tp as.tps as.vr as.vrs as.op as.tr \
- as.cv as.cn
-
-clean-aminfo:
-
-distclean-aminfo:
+ -rm -rf as.aux as.cp as.cps as.fn as.fns as.ky as.log as.pg as.pgs as.tmp \
+ as.toc as.tp as.tps as.vr as.vrs as.dvi as.pdf as.ps as.html
maintainer-clean-aminfo:
- for i in $(INFO_DEPS); do \
- rm -f $$i; \
- if test "`echo $$i-[0-9]*`" != "$$i-[0-9]*"; then \
- rm -f $$i-[0-9]*; \
- fi; \
+ @list='$(INFO_DEPS)'; for i in $$list; do \
+ i_i=`echo "$$i" | sed 's|\.info$$||;s|$$|.i|'`; \
+ echo " rm -f $$i $$i-[0-9] $$i-[0-9][0-9] $$i_i[0-9] $$i_i[0-9][0-9]"; \
+ rm -f $$i $$i-[0-9] $$i-[0-9][0-9] $$i_i[0-9] $$i_i[0-9][0-9]; \
done
-clean-info: mostlyclean-aminfo
-install-man1:
- $(mkinstalldirs) $(DESTDIR)$(man1dir)
- @list='$(man1_MANS)'; \
- l2='$(man_MANS)'; for i in $$l2; do \
+clean-info: mostlyclean-aminfo
+install-man1: $(man1_MANS) $(man_MANS)
+ @$(NORMAL_INSTALL)
+ test -z "$(man1dir)" || $(mkdir_p) "$(DESTDIR)$(man1dir)"
+ @list='$(man1_MANS) $(dist_man1_MANS) $(nodist_man1_MANS)'; \
+ l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \
+ for i in $$l2; do \
case "$$i" in \
*.1*) list="$$list $$i" ;; \
esac; \
@@ -329,120 +407,167 @@ install-man1:
if test -f $(srcdir)/$$i; then file=$(srcdir)/$$i; \
else file=$$i; fi; \
ext=`echo $$i | sed -e 's/^.*\\.//'`; \
+ case "$$ext" in \
+ 1*) ;; \
+ *) ext='1' ;; \
+ esac; \
inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \
+ inst=`echo $$inst | sed -e 's/^.*\///'`; \
inst=`echo $$inst | sed '$(transform)'`.$$ext; \
- echo " $(INSTALL_DATA) $$file $(DESTDIR)$(man1dir)/$$inst"; \
- $(INSTALL_DATA) $$file $(DESTDIR)$(man1dir)/$$inst; \
+ echo " $(INSTALL_DATA) '$$file' '$(DESTDIR)$(man1dir)/$$inst'"; \
+ $(INSTALL_DATA) "$$file" "$(DESTDIR)$(man1dir)/$$inst"; \
done
-
uninstall-man1:
- @list='$(man1_MANS)'; \
- l2='$(man_MANS)'; for i in $$l2; do \
+ @$(NORMAL_UNINSTALL)
+ @list='$(man1_MANS) $(dist_man1_MANS) $(nodist_man1_MANS)'; \
+ l2='$(man_MANS) $(dist_man_MANS) $(nodist_man_MANS)'; \
+ for i in $$l2; do \
case "$$i" in \
*.1*) list="$$list $$i" ;; \
esac; \
done; \
for i in $$list; do \
ext=`echo $$i | sed -e 's/^.*\\.//'`; \
+ case "$$ext" in \
+ 1*) ;; \
+ *) ext='1' ;; \
+ esac; \
inst=`echo $$i | sed -e 's/\\.[0-9a-z]*$$//'`; \
+ inst=`echo $$inst | sed -e 's/^.*\///'`; \
inst=`echo $$inst | sed '$(transform)'`.$$ext; \
- echo " rm -f $(DESTDIR)$(man1dir)/$$inst"; \
- rm -f $(DESTDIR)$(man1dir)/$$inst; \
+ echo " rm -f '$(DESTDIR)$(man1dir)/$$inst'"; \
+ rm -f "$(DESTDIR)$(man1dir)/$$inst"; \
done
-install-man: $(MANS)
- @$(NORMAL_INSTALL)
- $(MAKE) $(AM_MAKEFLAGS) install-man1
-uninstall-man:
- @$(NORMAL_UNINSTALL)
- $(MAKE) $(AM_MAKEFLAGS) uninstall-man1
tags: TAGS
TAGS:
+ctags: CTAGS
+CTAGS:
-distdir = $(top_builddir)/$(PACKAGE)-$(VERSION)/$(subdir)
-
-subdir = doc
-
-distdir: $(DISTFILES)
- @for file in $(DISTFILES); do \
- if test -f $$file; then d=.; else d=$(srcdir); fi; \
- if test -d $$d/$$file; then \
- cp -pr $$d/$$file $(distdir)/$$file; \
- else \
- test -f $(distdir)/$$file \
- || ln $$d/$$file $(distdir)/$$file 2> /dev/null \
- || cp -p $$d/$$file $(distdir)/$$file || :; \
- fi; \
- done
- $(MAKE) $(AM_MAKEFLAGS) top_distdir="$(top_distdir)" distdir="$(distdir)" dist-info
-info-am: $(INFO_DEPS)
-info: info-am
-dvi-am: $(DVIS)
-dvi: dvi-am
check-am:
check: check-am
-installcheck-am:
-installcheck: installcheck-am
-install-info-am:
-install-info: install-info-am
-install-exec-am:
+all-am: Makefile $(MANS)
+installdirs:
+ for dir in "$(DESTDIR)$(man1dir)"; do \
+ test -z "$$dir" || $(mkdir_p) "$$dir"; \
+ done
+install: install-am
install-exec: install-exec-am
-
-install-data-am: install-man
install-data: install-data-am
+uninstall: uninstall-am
install-am: all-am
@$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
-install: install-am
-uninstall-am: uninstall-man
-uninstall: uninstall-am
-all-am: Makefile $(MANS)
-all-redirect: all-am
-install-strip:
- $(MAKE) $(AM_MAKEFLAGS) AM_INSTALL_PROGRAM_FLAGS=-s install
-installdirs:
- $(mkinstalldirs) $(DESTDIR)$(mandir)/man1
-
+installcheck: installcheck-am
+install-strip:
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ `test -z '$(STRIP)' || \
+ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
mostlyclean-generic:
clean-generic:
distclean-generic:
- -rm -f Makefile $(CONFIG_CLEAN_FILES)
- -rm -f config.cache config.log stamp-h stamp-h[0-9]*
+ -rm -f $(CONFIG_CLEAN_FILES)
-test -z "$(DISTCLEANFILES)" || rm -f $(DISTCLEANFILES)
maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
-test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES)
-mostlyclean-am: mostlyclean-aminfo mostlyclean-generic
+clean: clean-am
-mostlyclean: mostlyclean-am
+clean-am: clean-generic clean-libtool mostlyclean-am
-clean-am: clean-aminfo clean-generic mostlyclean-am
+distclean: distclean-am
+ -rm -f Makefile
+distclean-am: clean-am distclean-generic distclean-libtool
-clean: clean-am
+dvi: dvi-am
-distclean-am: distclean-aminfo distclean-generic clean-am
- -rm -f libtool
+dvi-am: $(DVIS)
-distclean: distclean-am
+html: html-am
-maintainer-clean-am: maintainer-clean-aminfo maintainer-clean-generic \
- distclean-am
- @echo "This command is intended for maintainers to use;"
- @echo "it deletes files that may require special tools to rebuild."
+html-am: $(HTMLS)
+
+info-am: $(INFO_DEPS)
+
+install-data-am: install-data-local install-man
+
+install-exec-am:
+
+install-info: install-info-am
+
+install-info-am: $(INFO_DEPS)
+ @$(NORMAL_INSTALL)
+ test -z "$(infodir)" || $(mkdir_p) "$(DESTDIR)$(infodir)"
+ @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
+ list='$(INFO_DEPS)'; \
+ for file in $$list; do \
+ case $$file in \
+ $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \
+ esac; \
+ if test -f $$file; then d=.; else d=$(srcdir); fi; \
+ file_i=`echo "$$file" | sed 's|\.info$$||;s|$$|.i|'`; \
+ for ifile in $$d/$$file $$d/$$file-[0-9] $$d/$$file-[0-9][0-9] \
+ $$d/$$file_i[0-9] $$d/$$file_i[0-9][0-9] ; do \
+ if test -f $$ifile; then \
+ relfile=`echo "$$ifile" | sed 's|^.*/||'`; \
+ echo " $(INSTALL_DATA) '$$ifile' '$(DESTDIR)$(infodir)/$$relfile'"; \
+ $(INSTALL_DATA) "$$ifile" "$(DESTDIR)$(infodir)/$$relfile"; \
+ else : ; fi; \
+ done; \
+ done
+ @$(POST_INSTALL)
+ @if (install-info --version && \
+ install-info --version 2>&1 | sed 1q | grep -i -v debian) >/dev/null 2>&1; then \
+ list='$(INFO_DEPS)'; \
+ for file in $$list; do \
+ relfile=`echo "$$file" | sed 's|^.*/||'`; \
+ echo " install-info --info-dir='$(DESTDIR)$(infodir)' '$(DESTDIR)$(infodir)/$$relfile'";\
+ install-info --info-dir="$(DESTDIR)$(infodir)" "$(DESTDIR)$(infodir)/$$relfile" || :;\
+ done; \
+ else : ; fi
+install-man: install-man1
+
+installcheck-am:
maintainer-clean: maintainer-clean-am
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-aminfo \
+ maintainer-clean-generic
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-aminfo mostlyclean-generic \
+ mostlyclean-libtool
+
+pdf: pdf-am
+
+pdf-am: $(PDFS)
-.PHONY: install-info-am uninstall-info mostlyclean-aminfo \
-distclean-aminfo clean-aminfo maintainer-clean-aminfo install-man1 \
-uninstall-man1 install-man uninstall-man tags distdir info-am info \
-dvi-am dvi check check-am installcheck-am installcheck install-info-am \
-install-info install-exec-am install-exec install-data-am install-data \
-install-am install uninstall-am uninstall all-redirect all-am all \
-installdirs mostlyclean-generic distclean-generic clean-generic \
-maintainer-clean-generic clean mostlyclean distclean maintainer-clean
+ps: ps-am
+
+ps-am: $(PSS)
+
+uninstall-am: uninstall-man
+
+uninstall-man: uninstall-man1
+
+.PHONY: all all-am check check-am clean clean-generic clean-info \
+ clean-libtool dist-info distclean distclean-generic \
+ distclean-libtool dvi dvi-am html html-am info info-am install \
+ install-am install-data install-data-am install-data-local \
+ install-exec install-exec-am install-info install-info-am \
+ install-man install-man1 install-strip installcheck \
+ installcheck-am installdirs maintainer-clean \
+ maintainer-clean-aminfo maintainer-clean-generic mostlyclean \
+ mostlyclean-aminfo mostlyclean-generic mostlyclean-libtool pdf \
+ pdf-am ps ps-am uninstall uninstall-am uninstall-info-am \
+ uninstall-man uninstall-man1
asconfig.texi: $(CONFIG).texi
@@ -460,7 +585,7 @@ as.dvi: $(srcdir)/as.texinfo asconfig.texi gasver.texi $(CPU_DOCS)
# We want install to imply install-info as per GNU standards, despite the
# cygnus option.
-install: install-info
+install-data-local: install-info
# Maintenance
@@ -470,7 +595,7 @@ info: $(MANS)
# Build the man page from the texinfo file
# The sed command removes the no-adjust Nroff command so that
# the man output looks standard.
-as.1: $(srcdir)/as.texinfo
+as.1: $(srcdir)/as.texinfo asconfig.texi gasver.texi $(CPU_DOCS)
touch $@
-$(TEXI2POD) $(MANCONF) < $(srcdir)/as.texinfo > as.pod
-($(POD2MAN) as.pod | \
@@ -478,7 +603,6 @@ as.1: $(srcdir)/as.texinfo
mv -f $@.T$$$$ $@) || \
(rm -f $@.T$$$$ && exit 1)
rm -f as.pod
-
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:
diff --git a/contrib/binutils/gas/doc/all.texi b/contrib/binutils/gas/doc/all.texi
index 0642dfd..4e302ce 100644
--- a/contrib/binutils/gas/doc/all.texi
+++ b/contrib/binutils/gas/doc/all.texi
@@ -40,6 +40,7 @@
@set I80386
@set I860
@set I960
+@set IP2K
@set M32R
@set M68HC11
@set M680X0
@@ -47,15 +48,17 @@
@set MCORE
@set MIPS
@set MMIX
+@set MSP430
@set PDP11
@set PJ
@set PPC
@set SH
@set SPARC
-@set C54X
+@set TIC54X
@set V850
@set VAX
@set VXWORKS
+@set XTENSA
@set Z8000
@c Does this version of the assembler use the difference-table kluge?
diff --git a/contrib/binutils/gas/doc/as.texinfo b/contrib/binutils/gas/doc/as.texinfo
index f3195a3..d9d23df 100644
--- a/contrib/binutils/gas/doc/as.texinfo
+++ b/contrib/binutils/gas/doc/as.texinfo
@@ -1,6 +1,6 @@
\input texinfo @c -*-Texinfo-*-
@c Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
-@c 2001, 2002
+@c 2001, 2002, 2003, 2004
@c Free Software Foundation, Inc.
@c UPDATE!! On future updates--
@c (1) check for new machine-dep cmdline options in
@@ -19,48 +19,20 @@
@c defaults, config file may override:
@set have-stabs
@c ---
+@c man begin NAME
+@c ---
@include asconfig.texi
@include gasver.texi
@c ---
-@c man begin NAME
-@ifset man
-@c Configure for the generation of man pages
-@set AS as
-@set TARGET TARGET
-@set GENERIC
-@set A29K
-@set ALPHA
-@set ARC
-@set ARM
-@set CRIS
-@set D10V
-@set D30V
-@set H8/300
-@set H8/500
-@set HPPA
-@set I370
-@set I80386
-@set I860
-@set I960
-@set IA-64
-@set M32R
-@set M68HC11
-@set M680X0
-@set M880X0
-@set MCORE
-@set MIPS
-@set MMIX
-@set PDP11
-@set PJ
-@set PPC
-@set SH
-@set SPARC
-@set C54X
-@set V850
-@set VAX
-@end ifset
@c man end
+@c ---
@c common OR combinations of conditions
+@ifset COFF
+@set COFF-ELF
+@end ifset
+@ifset ELF
+@set COFF-ELF
+@end ifset
@ifset AOUT
@set aout-bout
@end ifset
@@ -138,7 +110,7 @@ under the terms of the GNU Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
-section entitled "GNU Free Documentation License".
+section entitled ``GNU Free Documentation License''.
@c man end
@@ -191,7 +163,7 @@ Copyright @copyright{} 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001, 2002 Fr
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
- section entitled "GNU Free Documentation License".
+ section entitled ``GNU Free Documentation License''.
@end titlepage
@@ -208,7 +180,7 @@ code for @value{TARGET} architectures.
This document is distributed under the terms of the GNU Free
Documentation License. A copy of the license is included in the
-section entitled "GNU Free Documentation License".
+section entitled ``GNU Free Documentation License''.
@menu
* Overview:: Overview
@@ -240,7 +212,7 @@ code for @value{TARGET} architectures.
@cindex option summary
@cindex summary of options
Here is a brief summary of how to invoke @command{@value{AS}}. For details,
-@pxref{Invoking,,Comand-Line Options}.
+@pxref{Invoking,,Command-Line Options}.
@c man title AS the portable GNU assembler.
@@ -255,8 +227,8 @@ gcc(1), ld(1), and the Info entries for @file{binutils} and @file{ld}.
@smallexample
@c man begin SYNOPSIS
@value{AS} [@b{-a}[@b{cdhlns}][=@var{file}]] [@b{-D}] [@b{--defsym} @var{sym}=@var{val}]
- [@b{-f}] [@b{--gstabs}] [@b{--gdwarf2}] [@b{--help}] [@b{-I} @var{dir}]
- [@b{-J}] [@b{-K}] [@b{-L}]
+ [@b{-f}] [@b{--gstabs}] [@b{--gstabs+}] [@b{--gdwarf2}] [@b{--help}]
+ [@b{-I} @var{dir}] [@b{-J}] [@b{-K}] [@b{-L}]
[@b{--listing-lhs-width}=@var{NUM}] [@b{--listing-lhs-width2}=@var{NUM}]
[@b{--listing-rhs-width}=@var{NUM}] [@b{--listing-cont-lines}=@var{NUM}]
[@b{--keep-locals}] [@b{-o} @var{objfile}] [@b{-R}] [@b{--statistics}] [@b{-v}]
@@ -289,7 +261,8 @@ gcc(1), ld(1), and the Info entries for @file{binutils} and @file{ld}.
@c Don't document the deprecated options
[@b{-mcpu}=@var{processor}[+@var{extension}@dots{}]]
[@b{-march}=@var{architecture}[+@var{extension}@dots{}]]
- [@b{-mfpu}=@var{floating-point-fromat}]
+ [@b{-mfpu}=@var{floating-point-format}]
+ [@b{-mfloat-abi}=@var{abi}]
[@b{-mthumb}]
[@b{-EB}|@b{-EL}]
[@b{-mapcs-32}|@b{-mapcs-26}|@b{-mapcs-float}|
@@ -316,7 +289,7 @@ gcc(1), ld(1), and the Info entries for @file{binutils} and @file{ld}.
[@b{-O}|@b{-n}|@b{-N}]
@end ifset
@ifset H8
-@c Hitachi family chips have no machine-dependent assembler options
+@c Renesas family chips have no machine-dependent assembler options
@end ifset
@ifset HPPA
@c HPPA has no machine-dependent assembler options (yet).
@@ -324,7 +297,7 @@ gcc(1), ld(1), and the Info entries for @file{binutils} and @file{ld}.
@ifset I80386
@emph{Target i386 options:}
- [@b{--32}|@b{--64}]
+ [@b{--32}|@b{--64}] [@b{-n}]
@end ifset
@ifset I960
@@ -342,6 +315,11 @@ gcc(1), ld(1), and the Info entries for @file{binutils} and @file{ld}.
[@b{-mle}|@b{mbe}]
[@b{-x}|@b{-xexplicit}] [@b{-xauto}] [@b{-xdebug}]
@end ifset
+@ifset IP2K
+
+@emph{Target IP2K options:}
+ [@b{-mip2022}|@b{-mip2022ext}]
+@end ifset
@ifset M32R
@emph{Target M32R options:}
@@ -356,7 +334,9 @@ gcc(1), ld(1), and the Info entries for @file{binutils} and @file{ld}.
@ifset M68HC11
@emph{Target M68HC11 options:}
- [@b{-m68hc11}|@b{-m68hc12}]
+ [@b{-m68hc11}|@b{-m68hc12}|@b{-m68hcs12}]
+ [@b{-mshort}|@b{-mlong}]
+ [@b{-mshort-double}|@b{-mlong-double}]
[@b{--force-long-branchs}] [@b{--short-branchs}]
[@b{--strict-direct-mode}] [@b{--print-insn-syntax}]
[@b{--print-opcodes}] [@b{--generate-example}]
@@ -370,12 +350,13 @@ gcc(1), ld(1), and the Info entries for @file{binutils} and @file{ld}.
@ifset MIPS
@emph{Target MIPS options:}
- [@b{-nocpp}] [@b{-EL}] [@b{-EB}] [@b{-n}] [@b{-O}[@var{optimization level}]]
+ [@b{-nocpp}] [@b{-EL}] [@b{-EB}] [@b{-O}[@var{optimization level}]]
[@b{-g}[@var{debug level}]] [@b{-G} @var{num}] [@b{-KPIC}] [@b{-call_shared}]
[@b{-non_shared}] [@b{-xgot}] [@b{--membedded-pic}]
[@b{-mabi}=@var{ABI}] [@b{-32}] [@b{-n32}] [@b{-64}] [@b{-mfp32}] [@b{-mgp32}]
[@b{-march}=@var{CPU}] [@b{-mtune}=@var{CPU}] [@b{-mips1}] [@b{-mips2}]
- [@b{-mips3}] [@b{-mips4}] [@b{-mips5}] [@b{-mips32}] [@b{-mips64}]
+ [@b{-mips3}] [@b{-mips4}] [@b{-mips5}] [@b{-mips32}] [@b{-mips32r2}]
+ [@b{-mips64}] [@b{-mips64r2}]
[@b{-construct-floats}] [@b{-no-construct-floats}]
[@b{-trap}] [@b{-no-break}] [@b{-break}] [@b{-no-trap}]
[@b{-mfix7000}] [@b{-mno-fix7000}]
@@ -383,6 +364,7 @@ gcc(1), ld(1), and the Info entries for @file{binutils} and @file{ld}.
[@b{-mips3d}] [@b{-no-mips3d}]
[@b{-mdmx}] [@b{-no-mdmx}]
[@b{-mdebug}] [@b{-no-mdebug}]
+ [@b{-mpdr}] [@b{-mno-pdr}]
@end ifset
@ifset MMIX
@@ -434,6 +416,13 @@ gcc(1), ld(1), and the Info entries for @file{binutils} and @file{ld}.
@ifset Z8000
@c Z8000 has no machine-dependent assembler options
@end ifset
+@ifset XTENSA
+
+@emph{Target Xtensa options:}
+ [@b{--[no-]density}] [@b{--[no-]relax}] [@b{--[no-]generics}]
+ [@b{--[no-]text-section-literals}]
+ [@b{--[no-]target-align}] [@b{--[no-]longcalls}]
+@end ifset
@c man end
@end smallexample
@@ -490,9 +479,16 @@ compiler output).
Generate stabs debugging information for each assembler line. This
may help debugging assembler code, if the debugger can handle it.
+@item --gstabs+
+Generate stabs debugging information for each assembler line, with GNU
+extensions that probably only gdb can handle, and that could make other
+debuggers crash or refuse to read your program. This
+may help debugging assembler code. Currently the only GNU extension is
+the location of the current working directory at assembling time.
+
@item --gdwarf2
Generate DWARF2 debugging information for each assembler line. This
-may help debugging assembler code, if the debugger can handle it. Note - this
+may help debugging assembler code, if the debugger can handle it. Note---this
option is only supported by some targets, not all of them.
@item --help
@@ -604,6 +600,8 @@ Specify which ARM processor variant is the target.
Specify which ARM architecture variant is used by the target.
@item -mfpu=@var{floating-point-format}
Select which Floating Point architecture is the target.
+@item -mfloat-abi=@var{abi}
+Select which floating point ABI is in use.
@item -mthumb
Enable Thumb only instruction decoding.
@item -mapcs-32 | -mapcs-26 | -mapcs-float | -mapcs-reentrant | -moabi
@@ -670,9 +668,25 @@ error if necessary.
@end table
@end ifset
+@ifset IP2K
+The following options are available when @value{AS} is configured for the
+Ubicom IP2K series.
+
+@table @gcctabopt
+
+@item -mip2022ext
+Specifies that the extended IP2022 instructions are allowed.
+
+@item -mip2022
+Restores the default behaviour, which restricts the permitted instructions to
+just the basic IP2022 ones.
+
+@end table
+@end ifset
+
@ifset M32R
The following options are available when @value{AS} is configured for the
-Mitsubishi M32R series.
+Renesas M32R (formerly Mitsubishi M32R) series.
@table @gcctabopt
@@ -776,10 +790,22 @@ Motorola 68HC11 or 68HC12 series.
@table @gcctabopt
-@item -m68hc11 | -m68hc12
+@item -m68hc11 | -m68hc12 | -m68hcs12
Specify what processor is the target. The default is
defined by the configuration option when building the assembler.
+@item -mshort
+Specify to use the 16-bit integer ABI.
+
+@item -mlong
+Specify to use the 32-bit integer ABI.
+
+@item -mshort-double
+Specify to use the 32-bit double ABI.
+
+@item -mlong-double
+Specify to use the 64-bit double ABI.
+
@item --force-long-branchs
Relative branches are turned into absolute ones. This concerns
conditional branches, unconditional branches and branches to a
@@ -873,14 +899,19 @@ Generate ``little endian'' format output.
@itemx -mips4
@itemx -mips5
@itemx -mips32
+@itemx -mips32r2
@itemx -mips64
+@itemx -mips64r2
Generate code for a particular @sc{mips} Instruction Set Architecture level.
@samp{-mips1} is an alias for @samp{-march=r3000}, @samp{-mips2} is an
alias for @samp{-march=r6000}, @samp{-mips3} is an alias for
@samp{-march=r4000} and @samp{-mips4} is an alias for @samp{-march=r8000}.
-@samp{-mips5}, @samp{-mips32}, and @samp{-mips64} correspond to generic
-@samp{MIPS V}, @samp{MIPS32}, and @samp{MIPS64} ISA processors,
-respectively.
+@samp{-mips5}, @samp{-mips32}, @samp{-mips32r2}, @samp{-mips64}, and
+@samp{-mips64r2}
+correspond to generic
+@samp{MIPS V}, @samp{MIPS32}, @samp{MIPS32 Release 2}, @samp{MIPS64},
+and @samp{MIPS64 Release 2}
+ISA processors, respectively.
@item -march=@var{CPU}
Generate code for a particular @sc{mips} cpu.
@@ -898,6 +929,10 @@ of an mfhi or mflo instruction occurs in the following two instructions.
Cause stabs-style debugging output to go into an ECOFF-style .mdebug
section instead of the standard ELF .stabs sections.
+@item -mpdr
+@itemx -mno-pdr
+Control generation of @code{.pdr} sections.
+
@item -mgp32
@itemx -mfp32
The register sizes are normally inferred from the ISA and ABI, but these
@@ -1011,6 +1046,45 @@ Assemble for a little endian target.
See the info pages for documentation of the MMIX-specific options.
@end ifset
+@ifset XTENSA
+The following options are available when @value{AS} is configured for
+an Xtensa processor.
+
+@table @gcctabopt
+@item --density | --no-density
+Enable or disable use of instructions from the Xtensa code density
+option. This is enabled by default when the Xtensa processor supports
+the code density option.
+
+@item --relax | --no-relax
+Enable or disable instruction relaxation. This is enabled by default.
+Note: In the current implementation, these options also control whether
+assembler optimizations are performed, making these options equivalent
+to @option{--generics} and @option{--no-generics}.
+
+@item --generics | --no-generics
+Enable or disable all assembler transformations of Xtensa instructions.
+The default is @option{--generics};
+@option{--no-generics} should be used only in the rare cases when the
+instructions must be exactly as specified in the assembly source.
+
+@item --text-section-literals | --no-text-section-literals
+With @option{--text-@-section-@-literals}, literal pools are interspersed
+in the text section. The default is
+@option{--no-@-text-@-section-@-literals}, which places literals in a
+separate section in the output file.
+
+@item --target-align | --no-target-align
+Enable or disable automatic alignment to reduce branch penalties at the
+expense of some code density. The default is @option{--target-@-align}.
+
+@item --longcalls | --no-longcalls
+Enable or disable transformation of call instructions to allow calls
+across a greater range of addresses. The default is
+@option{--no-@-longcalls}.
+@end table
+@end ifset
+
@c man end
@menu
@@ -1055,16 +1129,18 @@ machine architecture manual for this information.
@ifclear GENERIC
@ifset H8/300
For information on the H8/300 machine instruction set, see @cite{H8/300
-Series Programming Manual} (Hitachi ADE--602--025). For the H8/300H,
-see @cite{H8/300H Series Programming Manual} (Hitachi).
+Series Programming Manual}. For the H8/300H, see @cite{H8/300H Series
+Programming Manual} (Renesas).
@end ifset
@ifset H8/500
For information on the H8/500 machine instruction set, see @cite{H8/500
-Series Programming Manual} (Hitachi M21T001).
+Series Programming Manual} (Renesas M21T001).
@end ifset
@ifset SH
-For information on the Hitachi SH machine instruction set, see
-@cite{SH-Microcomputer User's Manual} (Hitachi Micro Systems, Inc.).
+For information on the Renesas (formerly Hitachi) / SuperH SH machine instruction set,
+see @cite{SH-Microcomputer User's Manual} (Renesas) or
+@cite{SH-4 32-bit CPU Core Architecture} (SuperH) and
+@cite{SuperH (SH) 64-Bit RISC Series} (SuperH).
@end ifset
@ifset Z8000
For information on the Z8000 machine instruction set, see @cite{Z8000 CPU Technical Manual}
@@ -1145,7 +1221,7 @@ are typically different in different file formats. @xref{Symbol
Attributes,,Symbol Attributes}.
@ifclear GENERIC
@ifclear MULTI-OBJ
-On the @value{TARGET}, @command{@value{AS}} is configured to produce
+For the @value{TARGET} target, @command{@value{AS}} is configured to produce
@value{OBJ-NAME} format object files.
@end ifclear
@c The following should exhaust all configs that set MULTI-OBJ, ideally
@@ -1348,7 +1424,7 @@ because many of them aren't supposed to happen.
This chapter describes command-line options available in @emph{all}
versions of the @sc{gnu} assembler; @pxref{Machine Dependencies}, for options specific
@ifclear GENERIC
-to the @value{TARGET}.
+to the @value{TARGET} target.
@end ifclear
@ifset GENERIC
to particular machine architectures.
@@ -1356,7 +1432,7 @@ to particular machine architectures.
@c man begin DESCRIPTION
-If you are invoking @command{@value{AS}} via the @sc{gnu} C compiler (version 2),
+If you are invoking @command{@value{AS}} via the @sc{gnu} C compiler,
you can use the @samp{-Wa} option to pass arguments through to the assembler.
The assembler arguments must be separated from each other (and the @samp{-Wa})
by commas. For example:
@@ -1367,7 +1443,7 @@ gcc -c -g -O -Wa,-alh,-L file.c
@noindent
This passes two options to the assembler: @samp{-alh} (emit a listing to
-standard output with with high-level and assembly source) and @samp{-L} (retain
+standard output with high-level and assembly source) and @samp{-L} (retain
local symbols in the symbol table).
Usually you do not need to use this @samp{-Wa} mechanism, since many compiler
@@ -1479,7 +1555,7 @@ not work correctly.
@end quotation
@node I
-@section @code{.include} search path: @option{-I} @var{path}
+@section @code{.include} Search Path: @option{-I} @var{path}
@kindex -I @var{path}
@cindex paths for @code{.include}
@@ -1558,7 +1634,7 @@ dump appears on the left hand side of the listing output.
@kindex --listing-lhs-width2
@cindex Width of continuation lines of disassembly output
Sets the maximum width, in words, of any further lines of the hex byte dump for
-a given inut source line. If this value is not specified, it defaults to being
+a given input source line. If this value is not specified, it defaults to being
the same as the value specified for @samp{--listing-lhs-width}. If neither
switch is used the default is to one.
@@ -1708,7 +1784,7 @@ The i960 @code{.setreal} pseudo-op is not supported.
@end itemize
@node MD
-@section Dependency tracking: @option{--MD}
+@section Dependency Tracking: @option{--MD}
@kindex --MD
@cindex dependency tracking
@@ -1772,8 +1848,8 @@ address displacements (because we do not have to cross between text and
data section). We refrain from doing this simply for compatibility with
older versions of @command{@value{AS}}. In future, @option{-R} may work this way.
-@ifset COFF
-When @command{@value{AS}} is configured for COFF output,
+@ifset COFF-ELF
+When @command{@value{AS}} is configured for COFF or ELF output,
this option is only useful if you use sections named @samp{.text} and
@samp{.data}.
@end ifset
@@ -1796,7 +1872,7 @@ Use @samp{--statistics} to display two statistics about the resources used by
seconds).
@node traditional-format
-@section Compatible output: @option{--traditional-format}
+@section Compatible Output: @option{--traditional-format}
@kindex --traditional-format
For some targets, the output of @command{@value{AS}} is different in some ways
@@ -1825,8 +1901,8 @@ assembling compiler output. But programs written by people often
cause @command{@value{AS}} to give a warning that a particular assumption was
made. All such warnings are directed to the standard error file.
-@kindex @samp{-W}
-@kindex @samp{--no-warn}
+@kindex -W
+@kindex --no-warn
@cindex suppressing warnings
@cindex warnings, suppressing
If you use the @option{-W} and @option{--no-warn} options, no warnings are issued.
@@ -1834,13 +1910,13 @@ This only affects the warning messages: it does not change any particular of
how @command{@value{AS}} assembles your file. Errors, which stop the assembly,
are still reported.
-@kindex @samp{--fatal-warnings}
+@kindex --fatal-warnings
@cindex errors, caused by warnings
@cindex warnings, causing error
If you use the @option{--fatal-warnings} option, @command{@value{AS}} considers
files that generate warnings to be in error.
-@kindex @samp{--warn}
+@kindex --warn
@cindex warnings, switching on
You can switch these options off again by specifying @option{--warn}, which
causes warnings to be output as usual.
@@ -1906,7 +1982,7 @@ It does not do macro processing, include file handling, or
anything else you may get from your C compiler's preprocessor. You can
do include file processing with the @code{.include} directive
(@pxref{Include,,@code{.include}}). You can use the @sc{gnu} C compiler driver
-to get other ``CPP'' style preprocessing, by giving the input file a
+to get other ``CPP'' style preprocessing by giving the input file a
@samp{.S} suffix. @xref{Overall Options,, Options Controlling the Kind of
Output, gcc.info, Using GNU CC}.
@@ -1990,14 +2066,17 @@ is considered a comment and is ignored. The line comment character is
@samp{;} for picoJava;
@end ifset
@ifset PPC
-@samp{;} for Motorola PowerPC;
+@samp{#} for Motorola PowerPC;
@end ifset
@ifset SH
-@samp{!} for the Hitachi SH;
+@samp{!} for the Renesas / SuperH SH;
@end ifset
@ifset SPARC
@samp{!} on the SPARC;
@end ifset
+@ifset IP2K
+@samp{#} on the ip2k;
+@end ifset
@ifset M32R
@samp{#} on the m32r;
@end ifset
@@ -2019,6 +2098,9 @@ is considered a comment and is ignored. The line comment character is
@ifset V850
@samp{#} on the V850;
@end ifset
+@ifset XTENSA
+@samp{#} for Xtensa systems;
+@end ifset
see @ref{Machine Dependencies}. @refill
@c FIXME What about i860?
@@ -2114,7 +2196,7 @@ constants are an exception: they do not end statements.
@ifset H8
A @dfn{statement} ends at a newline character (@samp{\n}); or (for the
H8/300) a dollar sign (@samp{$}); or (for the
-Hitachi-SH or the
+Renesas-SH or the
H8/500) a semicolon
(@samp{;}). The newline or separator character is considered part of
the preceding statement. Newlines and separators within character
@@ -2339,8 +2421,7 @@ grave accent. A newline
@end ifset
@ifset H8
(or dollar sign @samp{$}, for the H8/300; or semicolon @samp{;} for the
-Hitachi SH or
-H8/500)
+Renesas SH or H8/500)
@end ifset
@end ifset
@end ifclear
@@ -2444,7 +2525,7 @@ A letter, to tell @command{@value{AS}} the rest of the number is a flonum.
@end ignore
On the H8/300, H8/500,
-Hitachi SH,
+Renesas / SuperH SH,
and AMD 29K architectures, the letter must be
one of the letters @samp{DFPRSX} (in upper or lower case).
@@ -2581,7 +2662,7 @@ the task of adjusting mentions of object-file addresses so they refer to
the proper run-time addresses.
@ifset H8
For the H8/300 and H8/500,
-and for the Hitachi SH,
+and for the Renesas / SuperH SH,
@command{@value{AS}} pads sections if needed to
ensure they end on a word (sixteen bit) boundary.
@end ifset
@@ -2591,9 +2672,9 @@ An object file written by @command{@value{AS}} has at least three sections, any
of which may be empty. These are named @dfn{text}, @dfn{data} and
@dfn{bss} sections.
-@ifset COFF
+@ifset COFF-ELF
@ifset GENERIC
-When it generates COFF output,
+When it generates COFF or ELF output,
@end ifset
@command{@value{AS}} can also generate whatever other named sections you specify
using the @samp{.section} directive (@pxref{Section,,@code{.section}}).
@@ -2699,7 +2780,7 @@ use of @command{@value{AS}} and have no meaning except during assembly.
@table @strong
-@ifset COFF
+@ifset COFF-ELF
@cindex named sections
@cindex sections, named
@item named sections
@@ -2712,15 +2793,15 @@ use of @command{@value{AS}} and have no meaning except during assembly.
@end ifset
These sections hold your program. @command{@value{AS}} and @code{@value{LD}} treat them as
separate but equal sections. Anything you can say of one section is
-true another.
-@ifset aout-bout
+true of another.
+@c @ifset aout-bout
When the program is running, however, it is
customary for the text section to be unalterable. The
text section is often shared among processes: it contains
instructions, constants and the like. The data section of a running
program is usually alterable: for example, C variables would be stored
in the data section.
-@end ifset
+@c @end ifset
@cindex bss section
@item bss section
@@ -2747,13 +2828,13 @@ the preceding sections.
@cindex relocation example
An idealized example of three relocatable sections follows.
-@ifset COFF
+@ifset COFF-ELF
The example uses the traditional section names @samp{.text} and @samp{.data}.
@end ifset
Memory addresses are on the horizontal axis.
@c TEXI2ROFF-KILL
-@ifinfo
+@ifnottex
@c END TEXI2ROFF-KILL
@smallexample
+-----+----+--+
@@ -2774,10 +2855,10 @@ linked program: | |TTT|ttttt| |dddd|DDD|00000|
addresses: 0 @dots{}
@end smallexample
@c TEXI2ROFF-KILL
-@end ifinfo
+@end ifnottex
@need 5000
@tex
-
+\bigskip
\line{\it Partial program \#1: \hfil}
\line{\ibox{2.5cm}{\tt text}\ibox{2cm}{\tt data}\ibox{1cm}{\tt bss}\hfil}
\line{\boxit{2.5cm}{\tt ttttt}\boxit{2cm}{\tt dddd}\boxit{1cm}{\tt 00}\hfil}
@@ -2835,7 +2916,7 @@ it in the expr section.
@cindex grouping data
@ifset aout-bout
Assembled bytes
-@ifset COFF
+@ifset COFF-ELF
conventionally
@end ifset
fall into two sections: text and data.
@@ -2875,7 +2956,7 @@ of @command{@value{AS}}.)
@ifset H8
On the H8/300 and H8/500 platforms, each subsection is zero-padded to a word
boundary (two bytes).
-The same is true on the Hitachi SH.
+The same is true on the Renesas SH.
@end ifset
@ifset I960
@c FIXME section padding (alignment)?
@@ -2901,9 +2982,9 @@ data subsections as a data section.
To specify which subsection you want subsequent statements assembled
into, use a numeric argument to specify it, in a @samp{.text
@var{expression}} or a @samp{.data @var{expression}} statement.
-@ifset COFF
+@ifset COFF-ELF
@ifset GENERIC
-When generating COFF output, you
+When generating COFF or ELF output, you
@end ifset
@ifclear GENERIC
You
@@ -3032,10 +3113,9 @@ body of a symbol name, though not at its beginning.
@ifset SPECIAL-SYMS
@ifset H8
Symbol names begin with a letter or with one of @samp{._}. On the
-Hitachi SH or the
-H8/500, you can also use @code{$} in symbol names. That character may
-be followed by any string of digits, letters, dollar signs (save on the
-H8/300), and underscores.
+Renesas SH or the H8/500, you can also use @code{$} in symbol names. That
+character may be followed by any string of digits, letters, dollar signs (save
+on the H8/300), and underscores.
@end ifset
@end ifset
@@ -3591,6 +3671,9 @@ Some machine configurations provide additional directives.
* Balign:: @code{.balign @var{abs-expr} , @var{abs-expr}}
* Byte:: @code{.byte @var{expressions}}
* Comm:: @code{.comm @var{symbol} , @var{length} }
+
+* CFI directives:: @code{.cfi_startproc}, @code{.cfi_endproc}, etc.
+
* Data:: @code{.data @var{subsection}}
@ifset COFF
* Def:: @code{.def @var{name}}
@@ -3684,13 +3767,18 @@ Some machine configurations provide additional directives.
* Sbttl:: @code{.sbttl "@var{subheading}"}
@ifset COFF
* Scl:: @code{.scl @var{class}}
-* Section:: @code{.section @var{name}, @var{subsection}}
+@end ifset
+@ifset COFF-ELF
+* Section:: @code{.section @var{name}}
@end ifset
* Set:: @code{.set @var{symbol}, @var{expression}}
* Short:: @code{.short @var{expressions}}
* Single:: @code{.single @var{flonums}}
+@ifset COFF-ELF
* Size:: @code{.size [@var{name} , @var{expression}]}
+@end ifset
+
* Skip:: @code{.skip @var{size} , @var{fill}}
* Sleb128:: @code{.sleb128 @var{expressions}}
* Space:: @code{.space @var{size} , @var{fill}}
@@ -3711,7 +3799,10 @@ Some machine configurations provide additional directives.
* Text:: @code{.text @var{subsection}}
* Title:: @code{.title "@var{heading}"}
+@ifset COFF-ELF
* Type:: @code{.type <@var{int} | @var{name} , @var{type description}>}
+@end ifset
+
* Uleb128:: @code{.uleb128 @var{expressions}}
@ifset COFF
* Val:: @code{.val @var{addr}}
@@ -3777,12 +3868,12 @@ required alignment; this can be useful if you want the alignment to be filled
with no-op instructions when appropriate.
The way the required alignment is specified varies from system to system.
-For the a29k, hppa, m68k, m88k, w65, sparc, and Hitachi SH, and i386 using ELF
-format,
-the first expression is the
+For the a29k, arc, hppa, i386 using ELF, i860, iq2000, m68k, m88k, or32,
+s390, sparc, tic4x, tic80 and xtensa, the first expression is the
alignment request in bytes. For example @samp{.align 8} advances
the location counter until it is a multiple of 8. If the location counter
-is already a multiple of 8, no change is needed.
+is already a multiple of 8, no change is needed. For the tic54x, the
+first expression is the alignment request in words.
For other systems, including the i386 using a.out format, and the arm and
strongarm, it is the
@@ -3890,6 +3981,59 @@ The syntax for @code{.comm} differs slightly on the HPPA. The syntax is
@samp{@var{symbol} .comm, @var{length}}; @var{symbol} is optional.
@end ifset
+@node CFI directives
+@section @code{.cfi_startproc}
+@cindex @code{cfi_startproc} directive
+@code{.cfi_startproc} is used at the beginning of each function that
+should have an entry in @code{.eh_frame}. It initializes some internal
+data structures and emits architecture dependent initial CFI instructions.
+Don't forget to close the function by
+@code{.cfi_endproc}.
+
+@section @code{.cfi_endproc}
+@cindex @code{cfi_endproc} directive
+@code{.cfi_endproc} is used at the end of a function where it closes its
+unwind entry previously opened by
+@code{.cfi_startproc}. and emits it to @code{.eh_frame}.
+
+@section @code{.cfi_def_cfa @var{register}, @var{offset}}
+@code{.cfi_def_cfa} defines a rule for computing CFA as: @i{take
+address from @var{register} and add @var{offset} to it}.
+
+@section @code{.cfi_def_cfa_register @var{register}}
+@code{.cfi_def_cfa_register} modifies a rule for computing CFA. From
+now on @var{register} will be used instead of the old one. Offset
+remains the same.
+
+@section @code{.cfi_def_cfa_offset @var{offset}}
+@code{.cfi_def_cfa_offset} modifies a rule for computing CFA. Register
+remains the same, but @var{offset} is new. Note that it is the
+absolute offset that will be added to a defined register to compute
+CFA address.
+
+@section @code{.cfi_adjust_cfa_offset @var{offset}}
+Same as @code{.cfi_def_cfa_offset} but @var{offset} is a relative
+value that is added/substracted from the previous offset.
+
+@section @code{.cfi_offset @var{register}, @var{offset}}
+Previous value of @var{register} is saved at offset @var{offset} from
+CFA.
+
+@section @code{.cfi_rel_offset @var{register}, @var{offset}}
+Previous value of @var{register} is saved at offset @var{offset} from
+the current CFA register. This is transformed to @code{.cfi_offset}
+using the known displacement of the CFA register from the CFA.
+This is often easier to use, because the number will match the
+code it's annotating.
+
+@section @code{.cfi_window_save}
+SPARC register window has been saved.
+
+@section @code{.cfi_escape} @var{expression}[, @dots{}]
+Allows the user to add arbitrary bytes to the unwind info. One
+might use this to add OS-specific CFI opcodes, or generic CFI
+opcodes that GAS does not yet support.
+
@node Data
@section @code{.data @var{subsection}}
@@ -4049,7 +4193,9 @@ The syntax for @code{equ} on the HPPA is
@section @code{.equiv @var{symbol}, @var{expression}}
@cindex @code{equiv} directive
The @code{.equiv} directive is like @code{.equ} and @code{.set}, except that
-the assembler will signal an error if @var{symbol} is already defined.
+the assembler will signal an error if @var{symbol} is already defined. Note a
+symbol which has been referenced but not actually defined is considered to be
+undefined.
Except for the contents of the error message, this is roughly equivalent to
@smallexample
@@ -4154,7 +4300,7 @@ in @sc{ieee} format.
@cindex @code{func} directive
@code{.func} emits debugging information to denote function @var{name}, and
is ignored unless the file is assembled with debugging enabled.
-Only @samp{--gstabs} is currently supported.
+Only @samp{--gstabs[+]} is currently supported.
@var{label} is the entry point of the function and if omitted @var{name}
prepended with the @samp{leading char} is used.
@samp{leading char} is usually @code{_} or nothing, depending on the target.
@@ -4185,8 +4331,8 @@ partial programs. You may need the HPPA-only @code{.EXPORT} directive as well.
@node Hidden
@section @code{.hidden @var{names}}
-@cindex @code{.hidden} directive
-@cindex Visibility
+@cindex @code{hidden} directive
+@cindex visibility
This one of the ELF visibility directives. The other two are
@code{.internal} (@pxref{Internal,,@code{.internal}}) and
@code{.protected} (@pxref{Protected,,@code{.protected}}).
@@ -4248,7 +4394,8 @@ The following variants of @code{.if} are also supported:
@cindex @code{ifdef} directive
@item .ifdef @var{symbol}
Assembles the following section of code if the specified @var{symbol}
-has been defined.
+has been defined. Note a symbol which has been referenced but not yet defined
+is considered to be undefined.
@cindex @code{ifc} directive
@item .ifc @var{string1},@var{string2}
@@ -4294,7 +4441,8 @@ following section of code if the two strings are not the same.
@item .ifndef @var{symbol}
@itemx .ifnotdef @var{symbol}
Assembles the following section of code if the specified @var{symbol}
-has not been defined. Both spelling variants are equivalent.
+has not been defined. Both spelling variants are equivalent. Note a symbol
+which has been referenced but not yet defined is considered to be undefined.
@cindex @code{ifne} directive
@item .ifne @var{absolute expression}
@@ -4350,7 +4498,7 @@ of target the assembly is for.
@ifclear GENERIC
@ifset H8
On the H8/500 and most forms of the H8/300, @code{.int} emits 16-bit
-integers. On the H8/300H and the Hitachi SH, however, @code{.int} emits
+integers. On the H8/300H and the Renesas SH, however, @code{.int} emits
32-bit integers.
@end ifset
@end ifclear
@@ -4359,8 +4507,8 @@ integers. On the H8/300H and the Hitachi SH, however, @code{.int} emits
@node Internal
@section @code{.internal @var{names}}
-@cindex @code{.internal} directive
-@cindex Visibility
+@cindex @code{internal} directive
+@cindex visibility
This one of the ELF visibility directives. The other two are
@code{.hidden} (@pxref{Hidden,,@code{.hidden}}) and
@code{.protected} (@pxref{Protected,,@code{.protected}}).
@@ -4368,7 +4516,7 @@ This one of the ELF visibility directives. The other two are
This directive overrides the named symbols default visibility (which is set by
their binding: local, global or weak). The directive sets the visibility to
@code{internal} which means that the symbols are considered to be @code{hidden}
-(ie not visible to other components), and that some extra, processor specific
+(i.e., not visible to other components), and that some extra, processor specific
processing must also be performed upon the symbols as well.
@end ifset
@@ -4803,7 +4951,7 @@ undefined.
@node Previous
@section @code{.previous}
-@cindex @code{.previous} directive
+@cindex @code{previous} directive
@cindex Section Stack
This is one of the ELF section stack manipulation directives. The others are
@code{.section} (@pxref{Section}), @code{.subsection} (@pxref{SubSection}),
@@ -4823,7 +4971,7 @@ the top section on the section stack.
@node PopSection
@section @code{.popsection}
-@cindex @code{.popsection} directive
+@cindex @code{popsection} directive
@cindex Section Stack
This is one of the ELF section stack manipulation directives. The others are
@code{.section} (@pxref{Section}), @code{.subsection} (@pxref{SubSection}),
@@ -4846,8 +4994,8 @@ assembly. You must put @var{string} in double quotes.
@node Protected
@section @code{.protected @var{names}}
-@cindex @code{.protected} directive
-@cindex Visibility
+@cindex @code{protected} directive
+@cindex visibility
This one of the ELF visibility directives. The other two are
@code{.hidden} (@pxref{Hidden}) and @code{.internal} (@pxref{Internal}).
@@ -4890,7 +5038,7 @@ expanded. @xref{Macro}.
@node PushSection
@section @code{.pushsection @var{name} , @var{subsection}}
-@cindex @code{.pushsection} directive
+@cindex @code{pushsection} directive
@cindex Section Stack
This is one of the ELF section stack manipulation directives. The others are
@code{.section} (@pxref{Section}), @code{.subsection} (@pxref{SubSection}),
@@ -4978,10 +5126,10 @@ accepts this directive but ignores it.
@end ifset
@end ifset
+@ifset COFF-ELF
@node Section
-@section @code{.section @var{name}} (COFF version)
+@section @code{.section @var{name}}
-@cindex @code{section} directive
@cindex named section
Use the @code{.section} directive to assemble the following code into a section
named @var{name}.
@@ -4990,6 +5138,13 @@ This directive is only supported for targets that actually support arbitrarily
named sections; on @code{a.out} targets, for example, it is not accepted, even
with a standard @code{a.out} section name.
+@ifset COFF
+@ifset ELF
+@c only print the extra heading if both COFF and ELF are set
+@subheading COFF Version
+@end ifset
+
+@cindex @code{section} directive (COFF version)
For COFF targets, the @code{.section} directive is used in one of the following
ways:
@@ -5027,20 +5182,21 @@ will be as if no flags had been specified at all.
If the optional argument to the @code{.section} directive is not quoted, it is
taken as a subsegment number (@pxref{Sub-Sections}).
+@end ifset
-
-@section @code{.section @var{name}} (ELF version)
-
-@cindex @code{section} directive
-@cindex named section
@ifset ELF
+@ifset COFF
+@c only print the extra heading if both COFF and ELF are set
+@subheading ELF Version
+@end ifset
+
@cindex Section Stack
This is one of the ELF section stack manipulation directives. The others are
@code{.subsection} (@pxref{SubSection}), @code{.pushsection}
(@pxref{PushSection}), @code{.popsection} (@pxref{PopSection}), and
@code{.previous} (@pxref{Previous}).
-@end ifset
+@cindex @code{section} directive (ELF version)
For ELF targets, the @code{.section} directive is used like this:
@smallexample
@@ -5070,6 +5226,10 @@ section contains data
section does not contain data (i.e., section only occupies space)
@end table
+Note on targets where the @code{@@} character is the start of a comment (eg
+ARM) then another character is used instead. For example the ARM port uses the
+@code{%} character.
+
If @var{flags} contains @code{M} flag, @var{type} argument must be specified
as well as @var{entsize} argument. Sections with @code{M} flag but not
@code{S} flag must contain fixed size constants, each @var{entsize} octets
@@ -5104,6 +5264,8 @@ This directive replaces the current section and subsection. The replaced
section and subsection are pushed onto the section stack. See the contents of
the gas testsuite directory @code{gas/testsuite/gas/elf} for some examples of
how this directive and the other section stack directives work.
+@end ifset
+@end ifset
@node Set
@section @code{.set @var{symbol}, @var{expression}}
@@ -5164,27 +5326,52 @@ numbers in @sc{ieee} format.
@end ifset
@end ifclear
+@ifset COFF-ELF
@node Size
-@section @code{.size} (COFF version)
+@section @code{.size}
-@cindex @code{size} directive
-This directive is generated by compilers to include auxiliary debugging
-information in the symbol table. It is only permitted inside
-@code{.def}/@code{.endef} pairs.
+This directive is used to set the size associated with a symbol.
+
+@ifset COFF
+@ifset ELF
+@c only print the extra heading if both COFF and ELF are set
+@subheading COFF Version
+@end ifset
+
+@cindex @code{size} directive (COFF version)
+For COFF targets, the @code{.size} directive is only permitted inside
+@code{.def}/@code{.endef} pairs. It is used like this:
+
+@smallexample
+.size @var{expression}
+@end smallexample
@ifset BOUT
@samp{.size} is only meaningful when generating COFF format output; when
@command{@value{AS}} is generating @code{b.out}, it accepts this directive but
ignores it.
@end ifset
+@end ifset
-@section @code{.size @var{name} , @var{expression}} (ELF version)
-@cindex @code{size} directive
+@ifset ELF
+@ifset COFF
+@c only print the extra heading if both COFF and ELF are set
+@subheading ELF Version
+@end ifset
+
+@cindex @code{size} directive (ELF version)
+For ELF targets, the @code{.size} directive is used like this:
-This directive is used to set the size associated with a symbol @var{name}.
+@smallexample
+.size @var{name} , @var{expression}
+@end smallexample
+
+This directive sets the size associated with a symbol @var{name}.
The size in bytes is computed from @var{expression} which can make use of label
arithmetic. This directive is typically used to set the size of function
symbols.
+@end ifset
+@end ifset
@node Sleb128
@section @code{.sleb128 @var{expressions}}
@@ -5342,7 +5529,7 @@ before further assembly.
@node SubSection
@section @code{.subsection @var{name}}
-@cindex @code{.subsection} directive
+@cindex @code{subsection} directive
@cindex Section Stack
This is one of the ELF section stack manipulation directives. The others are
@code{.section} (@pxref{Section}), @code{.pushsection} (@pxref{PushSection}),
@@ -5449,27 +5636,54 @@ source file name and pagenumber) when generating assembly listings.
This directive affects subsequent pages, as well as the current page if
it appears within ten lines of the top of a page.
+@ifset COFF-ELF
@node Type
-@section @code{.type @var{int}} (COFF version)
+@section @code{.type}
+
+This directive is used to set the type of a symbol.
+
+@ifset COFF
+@ifset ELF
+@c only print the extra heading if both COFF and ELF are set
+@subheading COFF Version
+@end ifset
@cindex COFF symbol type
@cindex symbol type, COFF
-@cindex @code{type} directive
-This directive, permitted only within @code{.def}/@code{.endef} pairs,
-records the integer @var{int} as the type attribute of a symbol table entry.
+@cindex @code{type} directive (COFF version)
+For COFF targets, this directive is permitted only within
+@code{.def}/@code{.endef} pairs. It is used like this:
+
+@smallexample
+.type @var{int}
+@end smallexample
+
+This records the integer @var{int} as the type attribute of a symbol table
+entry.
@ifset BOUT
@samp{.type} is associated only with COFF format output; when
@command{@value{AS}} is configured for @code{b.out} output, it accepts this
directive but ignores it.
@end ifset
+@end ifset
-@section @code{.type @var{name} , @var{type description}} (ELF version)
+@ifset ELF
+@ifset COFF
+@c only print the extra heading if both COFF and ELF are set
+@subheading ELF Version
+@end ifset
@cindex ELF symbol type
@cindex symbol type, ELF
-@cindex @code{type} directive
-This directive is used to set the type of symbol @var{name} to be either a
+@cindex @code{type} directive (ELF version)
+For ELF targets, the @code{.type} directive is used like this:
+
+@smallexample
+.type @var{name} , @var{type description}
+@end smallexample
+
+This sets the type of symbol @var{name} to be either a
function symbol or an object symbol. There are five different syntaxes
supported for the @var{type description} field, in order to provide
compatibility with various other assemblers. The syntaxes supported are:
@@ -5490,6 +5704,8 @@ compatibility with various other assemblers. The syntaxes supported are:
.type <name> STT_FUNCTION
.type <name> STT_OBJECT
@end smallexample
+@end ifset
+@end ifset
@node Uleb128
@section @code{.uleb128 @var{expressions}}
@@ -5520,7 +5736,7 @@ configured for @code{b.out}, it accepts this directive but ignores it.
@node Version
@section @code{.version "@var{string}"}
-@cindex @code{.version}
+@cindex @code{version} directive
This directive creates a @code{.note} section and places into it an ELF
formatted note of type NT_VERSION. The note's name is set to @code{string}.
@end ifset
@@ -5529,14 +5745,14 @@ formatted note of type NT_VERSION. The note's name is set to @code{string}.
@node VTableEntry
@section @code{.vtable_entry @var{table}, @var{offset}}
-@cindex @code{.vtable_entry}
+@cindex @code{vtable_entry}
This directive finds or creates a symbol @code{table} and creates a
@code{VTABLE_ENTRY} relocation for it with an addend of @code{offset}.
@node VTableInherit
@section @code{.vtable_inherit @var{child}, @var{parent}}
-@cindex @code{.vtable_inherit}
+@cindex @code{vtable_inherit}
This directive finds the symbol @code{child} and finds or creates the symbol
@code{parent} and then creates a @code{VTABLE_INHERIT} relocation for the
parent whose addend is the value of the child symbol. As a special case the
@@ -5547,7 +5763,7 @@ parent name of @code{0} is treated as refering the @code{*ABS*} section.
@node Weak
@section @code{.weak @var{names}}
-@cindex @code{.weak}
+@cindex @code{weak} directive
This directive sets the weak attribute on the comma separated list of symbol
@code{names}. If the symbols do not already exist, they will be created.
@end ifset
@@ -5670,10 +5886,10 @@ subject, see the hardware manufacturer's manual.
* D30V-Dependent:: D30V Dependent Features
@end ifset
@ifset H8/300
-* H8/300-Dependent:: Hitachi H8/300 Dependent Features
+* H8/300-Dependent:: Renesas H8/300 Dependent Features
@end ifset
@ifset H8/500
-* H8/500-Dependent:: Hitachi H8/500 Dependent Features
+* H8/500-Dependent:: Renesas H8/500 Dependent Features
@end ifset
@ifset HPPA
* HPPA-Dependent:: HPPA Dependent Features
@@ -5690,6 +5906,9 @@ subject, see the hardware manufacturer's manual.
@ifset I960
* i960-Dependent:: Intel 80960 Dependent Features
@end ifset
+@ifset IP2K
+* IP2K-Dependent:: IP2K Dependent Features
+@end ifset
@ifset M32R
* M32R-Dependent:: M32R Dependent Features
@end ifset
@@ -5708,9 +5927,12 @@ subject, see the hardware manufacturer's manual.
@ifset MMIX
* MMIX-Dependent:: MMIX Dependent Features
@end ifset
+@ifset MSP430
+* MSP430-Dependent:: MSP430 Dependent Features
+@end ifset
@ifset SH
-* SH-Dependent:: Hitachi SH Dependent Features
-* SH64-Dependent:: Hitachi SH64 Dependent Features
+* SH-Dependent:: Renesas / SuperH SH Dependent Features
+* SH64-Dependent:: SuperH SH64 Dependent Features
@end ifset
@ifset PDP11
* PDP-11-Dependent:: PDP-11 Dependent Features
@@ -5730,6 +5952,9 @@ subject, see the hardware manufacturer's manual.
@ifset V850
* V850-Dependent:: V850 Dependent Features
@end ifset
+@ifset XTENSA
+* Xtensa-Dependent:: Xtensa Dependent Features
+@end ifset
@ifset Z8000
* Z8000-Dependent:: Z8000 Dependent Features
@end ifset
@@ -5769,20 +5994,20 @@ subject, see the hardware manufacturer's manual.
@include c-cris.texi
@end ifset
-@ifset Hitachi-all
+@ifset Renesas-all
@ifclear GENERIC
@node Machine Dependencies
@chapter Machine Dependent Features
-The machine instruction sets are different on each Hitachi chip family,
+The machine instruction sets are different on each Renesas chip family,
and there are also some syntax differences among the families. This
chapter describes the specific @command{@value{AS}} features for each
family.
@menu
-* H8/300-Dependent:: Hitachi H8/300 Dependent Features
-* H8/500-Dependent:: Hitachi H8/500 Dependent Features
-* SH-Dependent:: Hitachi SH Dependent Features
+* H8/300-Dependent:: Renesas H8/300 Dependent Features
+* H8/500-Dependent:: Renesas H8/500 Dependent Features
+* SH-Dependent:: Renesas SH Dependent Features
@end menu
@lowersections
@end ifclear
@@ -5828,6 +6053,10 @@ family.
@include c-ia64.texi
@end ifset
+@ifset IP2K
+@include c-ip2k.texi
+@end ifset
+
@ifset M32R
@include c-m32r.texi
@end ifset
@@ -5852,6 +6081,10 @@ family.
@include c-mmix.texi
@end ifset
+@ifset MSP430
+@include c-msp430.texi
+@end ifset
+
@ifset NS32K
@include c-ns32k.texi
@end ifset
@@ -5893,6 +6126,10 @@ family.
@include c-v850.texi
@end ifset
+@ifset XTENSA
+@include c-xtensa.texi
+@end ifset
+
@ifset GENERIC
@c reverse effect of @down at top of generic Machine-Dep chapter
@raisesections
@@ -5919,7 +6156,7 @@ information that enables us to fix the bug.
@end menu
@node Bug Criteria
-@section Have you found a bug?
+@section Have You Found a Bug?
@cindex bug criteria
If you are not sure whether you have found a bug, here are some guidelines:
@@ -5948,7 +6185,7 @@ of @command{@value{AS}} are welcome in any case.
@end itemize
@node Bug Reporting
-@section How to report bugs
+@section How to Report Bugs
@cindex bug reports
@cindex assembler bugs, reporting
@@ -5982,9 +6219,9 @@ it is new to us. Therefore, always write your bug reports on the assumption
that the bug has not been reported previously.
Sometimes people give a few sketchy facts and ask, ``Does this ring a
-bell?'' Those bug reports are useless, and we urge everyone to
-@emph{refuse to respond to them} except to chide the sender to report
-bugs properly.
+bell?'' This cannot help us fix a bug, so it is basically useless. We
+respond by asking for enough details to enable us to investigate.
+You might as well expedite matters by sending them to begin with.
To enable us to fix the bug, you should include all these things:
@@ -6145,7 +6382,7 @@ Keith Knowles at the Open Software Foundation wrote the original MIPS back end
(which hasn't been merged in yet). Ralph Campbell worked with the MIPS code to
support a.out format.
-Support for the Zilog Z8k and Hitachi H8/300 and H8/500 processors (tc-z8k,
+Support for the Zilog Z8k and Renesas H8/300 and H8/500 processors (tc-z8k,
tc-h8300, tc-h8500), and IEEE 695 object file format (obj-ieee), was written by
Steve Chamberlain of Cygnus Support. Steve also modified the COFF back end to
use BFD for some low-level operations, for use with the H8/300 and AMD 29k
@@ -6154,7 +6391,7 @@ targets.
John Gilmore built the AMD 29000 support, added @code{.include} support, and
simplified the configuration of which versions accept which directives. He
updated the 68k machine description so that Motorola's opcodes always produced
-fixed-size instructions (e.g. @code{jsr}), while synthetic instructions
+fixed-size instructions (e.g., @code{jsr}), while synthetic instructions
remained shrinkable (@code{jbsr}). John fixed many bugs, including true tested
cross-compilation support, and one bug in relaxation that took a week and
required the proverbial one-bit fix.
@@ -6179,7 +6416,7 @@ Jeff Law at the University of Utah (HPPA mainly), Michael Meissner of the Open
Software Foundation (i386 mainly), and Ken Raeburn of Cygnus Support (sparc,
and some initial 64-bit support).
-Linas Vepstas added GAS support for the ESA/390 "IBM 370" architecture.
+Linas Vepstas added GAS support for the ESA/390 ``IBM 370'' architecture.
Richard Henderson rewrote the Alpha assembler. Klaus Kaempf wrote GAS and BFD
support for openVMS/Alpha.
@@ -6187,6 +6424,9 @@ support for openVMS/Alpha.
Timothy Wall, Michael Hayes, and Greg Smart contributed to the various tic*
flavors.
+David Heine, Sterling Augustine, Bob Wilson and John Ruttenberg from Tensilica,
+Inc. added support for Xtensa processors.
+
Several engineers at Cygnus Support have also provided many small bug fixes and
configuration enhancements.
@@ -6195,368 +6435,7 @@ you have contributed significant work and are not mentioned on this list, and
want to be, let us know. Some of the history has been lost; we are not
intentionally leaving anyone out.
-@node GNU Free Documentation License
-@chapter GNU Free Documentation License
-
- GNU Free Documentation License
-
- Version 1.1, March 2000
-
- Copyright (C) 2000 Free Software Foundation, Inc.
- 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-
- Everyone is permitted to copy and distribute verbatim copies
- of this license document, but changing it is not allowed.
-
-
-0. PREAMBLE
-
-The purpose of this License is to make a manual, textbook, or other
-written document "free" in the sense of freedom: to assure everyone
-the effective freedom to copy and redistribute it, with or without
-modifying it, either commercially or noncommercially. Secondarily,
-this License preserves for the author and publisher a way to get
-credit for their work, while not being considered responsible for
-modifications made by others.
-
-This License is a kind of "copyleft", which means that derivative
-works of the document must themselves be free in the same sense. It
-complements the GNU General Public License, which is a copyleft
-license designed for free software.
-
-We have designed this License in order to use it for manuals for free
-software, because free software needs free documentation: a free
-program should come with manuals providing the same freedoms that the
-software does. But this License is not limited to software manuals;
-it can be used for any textual work, regardless of subject matter or
-whether it is published as a printed book. We recommend this License
-principally for works whose purpose is instruction or reference.
-
-
-1. APPLICABILITY AND DEFINITIONS
-
-This License applies to any manual or other work that contains a
-notice placed by the copyright holder saying it can be distributed
-under the terms of this License. The "Document", below, refers to any
-such manual or work. Any member of the public is a licensee, and is
-addressed as "you".
-
-A "Modified Version" of the Document means any work containing the
-Document or a portion of it, either copied verbatim, or with
-modifications and/or translated into another language.
-
-A "Secondary Section" is a named appendix or a front-matter section of
-the Document that deals exclusively with the relationship of the
-publishers or authors of the Document to the Document's overall subject
-(or to related matters) and contains nothing that could fall directly
-within that overall subject. (For example, if the Document is in part a
-textbook of mathematics, a Secondary Section may not explain any
-mathematics.) The relationship could be a matter of historical
-connection with the subject or with related matters, or of legal,
-commercial, philosophical, ethical or political position regarding
-them.
-
-The "Invariant Sections" are certain Secondary Sections whose titles
-are designated, as being those of Invariant Sections, in the notice
-that says that the Document is released under this License.
-
-The "Cover Texts" are certain short passages of text that are listed,
-as Front-Cover Texts or Back-Cover Texts, in the notice that says that
-the Document is released under this License.
-
-A "Transparent" copy of the Document means a machine-readable copy,
-represented in a format whose specification is available to the
-general public, whose contents can be viewed and edited directly and
-straightforwardly with generic text editors or (for images composed of
-pixels) generic paint programs or (for drawings) some widely available
-drawing editor, and that is suitable for input to text formatters or
-for automatic translation to a variety of formats suitable for input
-to text formatters. A copy made in an otherwise Transparent file
-format whose markup has been designed to thwart or discourage
-subsequent modification by readers is not Transparent. A copy that is
-not "Transparent" is called "Opaque".
-
-Examples of suitable formats for Transparent copies include plain
-ASCII without markup, Texinfo input format, LaTeX input format, SGML
-or XML using a publicly available DTD, and standard-conforming simple
-HTML designed for human modification. Opaque formats include
-PostScript, PDF, proprietary formats that can be read and edited only
-by proprietary word processors, SGML or XML for which the DTD and/or
-processing tools are not generally available, and the
-machine-generated HTML produced by some word processors for output
-purposes only.
-
-The "Title Page" means, for a printed book, the title page itself,
-plus such following pages as are needed to hold, legibly, the material
-this License requires to appear in the title page. For works in
-formats which do not have any title page as such, "Title Page" means
-the text near the most prominent appearance of the work's title,
-preceding the beginning of the body of the text.
-
-
-2. VERBATIM COPYING
-
-You may copy and distribute the Document in any medium, either
-commercially or noncommercially, provided that this License, the
-copyright notices, and the license notice saying this License applies
-to the Document are reproduced in all copies, and that you add no other
-conditions whatsoever to those of this License. You may not use
-technical measures to obstruct or control the reading or further
-copying of the copies you make or distribute. However, you may accept
-compensation in exchange for copies. If you distribute a large enough
-number of copies you must also follow the conditions in section 3.
-
-You may also lend copies, under the same conditions stated above, and
-you may publicly display copies.
-
-
-3. COPYING IN QUANTITY
-
-If you publish printed copies of the Document numbering more than 100,
-and the Document's license notice requires Cover Texts, you must enclose
-the copies in covers that carry, clearly and legibly, all these Cover
-Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on
-the back cover. Both covers must also clearly and legibly identify
-you as the publisher of these copies. The front cover must present
-the full title with all words of the title equally prominent and
-visible. You may add other material on the covers in addition.
-Copying with changes limited to the covers, as long as they preserve
-the title of the Document and satisfy these conditions, can be treated
-as verbatim copying in other respects.
-
-If the required texts for either cover are too voluminous to fit
-legibly, you should put the first ones listed (as many as fit
-reasonably) on the actual cover, and continue the rest onto adjacent
-pages.
-
-If you publish or distribute Opaque copies of the Document numbering
-more than 100, you must either include a machine-readable Transparent
-copy along with each Opaque copy, or state in or with each Opaque copy
-a publicly-accessible computer-network location containing a complete
-Transparent copy of the Document, free of added material, which the
-general network-using public has access to download anonymously at no
-charge using public-standard network protocols. If you use the latter
-option, you must take reasonably prudent steps, when you begin
-distribution of Opaque copies in quantity, to ensure that this
-Transparent copy will remain thus accessible at the stated location
-until at least one year after the last time you distribute an Opaque
-copy (directly or through your agents or retailers) of that edition to
-the public.
-
-It is requested, but not required, that you contact the authors of the
-Document well before redistributing any large number of copies, to give
-them a chance to provide you with an updated version of the Document.
-
-
-4. MODIFICATIONS
-
-You may copy and distribute a Modified Version of the Document under
-the conditions of sections 2 and 3 above, provided that you release
-the Modified Version under precisely this License, with the Modified
-Version filling the role of the Document, thus licensing distribution
-and modification of the Modified Version to whoever possesses a copy
-of it. In addition, you must do these things in the Modified Version:
-
-A. Use in the Title Page (and on the covers, if any) a title distinct
- from that of the Document, and from those of previous versions
- (which should, if there were any, be listed in the History section
- of the Document). You may use the same title as a previous version
- if the original publisher of that version gives permission.
-B. List on the Title Page, as authors, one or more persons or entities
- responsible for authorship of the modifications in the Modified
- Version, together with at least five of the principal authors of the
- Document (all of its principal authors, if it has less than five).
-C. State on the Title page the name of the publisher of the
- Modified Version, as the publisher.
-D. Preserve all the copyright notices of the Document.
-E. Add an appropriate copyright notice for your modifications
- adjacent to the other copyright notices.
-F. Include, immediately after the copyright notices, a license notice
- giving the public permission to use the Modified Version under the
- terms of this License, in the form shown in the Addendum below.
-G. Preserve in that license notice the full lists of Invariant Sections
- and required Cover Texts given in the Document's license notice.
-H. Include an unaltered copy of this License.
-I. Preserve the section entitled "History", and its title, and add to
- it an item stating at least the title, year, new authors, and
- publisher of the Modified Version as given on the Title Page. If
- there is no section entitled "History" in the Document, create one
- stating the title, year, authors, and publisher of the Document as
- given on its Title Page, then add an item describing the Modified
- Version as stated in the previous sentence.
-J. Preserve the network location, if any, given in the Document for
- public access to a Transparent copy of the Document, and likewise
- the network locations given in the Document for previous versions
- it was based on. These may be placed in the "History" section.
- You may omit a network location for a work that was published at
- least four years before the Document itself, or if the original
- publisher of the version it refers to gives permission.
-K. In any section entitled "Acknowledgements" or "Dedications",
- preserve the section's title, and preserve in the section all the
- substance and tone of each of the contributor acknowledgements
- and/or dedications given therein.
-L. Preserve all the Invariant Sections of the Document,
- unaltered in their text and in their titles. Section numbers
- or the equivalent are not considered part of the section titles.
-M. Delete any section entitled "Endorsements". Such a section
- may not be included in the Modified Version.
-N. Do not retitle any existing section as "Endorsements"
- or to conflict in title with any Invariant Section.
-
-If the Modified Version includes new front-matter sections or
-appendices that qualify as Secondary Sections and contain no material
-copied from the Document, you may at your option designate some or all
-of these sections as invariant. To do this, add their titles to the
-list of Invariant Sections in the Modified Version's license notice.
-These titles must be distinct from any other section titles.
-
-You may add a section entitled "Endorsements", provided it contains
-nothing but endorsements of your Modified Version by various
-parties--for example, statements of peer review or that the text has
-been approved by an organization as the authoritative definition of a
-standard.
-
-You may add a passage of up to five words as a Front-Cover Text, and a
-passage of up to 25 words as a Back-Cover Text, to the end of the list
-of Cover Texts in the Modified Version. Only one passage of
-Front-Cover Text and one of Back-Cover Text may be added by (or
-through arrangements made by) any one entity. If the Document already
-includes a cover text for the same cover, previously added by you or
-by arrangement made by the same entity you are acting on behalf of,
-you may not add another; but you may replace the old one, on explicit
-permission from the previous publisher that added the old one.
-
-The author(s) and publisher(s) of the Document do not by this License
-give permission to use their names for publicity for or to assert or
-imply endorsement of any Modified Version.
-
-
-5. COMBINING DOCUMENTS
-
-You may combine the Document with other documents released under this
-License, under the terms defined in section 4 above for modified
-versions, provided that you include in the combination all of the
-Invariant Sections of all of the original documents, unmodified, and
-list them all as Invariant Sections of your combined work in its
-license notice.
-
-The combined work need only contain one copy of this License, and
-multiple identical Invariant Sections may be replaced with a single
-copy. If there are multiple Invariant Sections with the same name but
-different contents, make the title of each such section unique by
-adding at the end of it, in parentheses, the name of the original
-author or publisher of that section if known, or else a unique number.
-Make the same adjustment to the section titles in the list of
-Invariant Sections in the license notice of the combined work.
-
-In the combination, you must combine any sections entitled "History"
-in the various original documents, forming one section entitled
-"History"; likewise combine any sections entitled "Acknowledgements",
-and any sections entitled "Dedications". You must delete all sections
-entitled "Endorsements."
-
-
-6. COLLECTIONS OF DOCUMENTS
-
-You may make a collection consisting of the Document and other documents
-released under this License, and replace the individual copies of this
-License in the various documents with a single copy that is included in
-the collection, provided that you follow the rules of this License for
-verbatim copying of each of the documents in all other respects.
-
-You may extract a single document from such a collection, and distribute
-it individually under this License, provided you insert a copy of this
-License into the extracted document, and follow this License in all
-other respects regarding verbatim copying of that document.
-
-
-7. AGGREGATION WITH INDEPENDENT WORKS
-
-A compilation of the Document or its derivatives with other separate
-and independent documents or works, in or on a volume of a storage or
-distribution medium, does not as a whole count as a Modified Version
-of the Document, provided no compilation copyright is claimed for the
-compilation. Such a compilation is called an "aggregate", and this
-License does not apply to the other self-contained works thus compiled
-with the Document, on account of their being thus compiled, if they
-are not themselves derivative works of the Document.
-
-If the Cover Text requirement of section 3 is applicable to these
-copies of the Document, then if the Document is less than one quarter
-of the entire aggregate, the Document's Cover Texts may be placed on
-covers that surround only the Document within the aggregate.
-Otherwise they must appear on covers around the whole aggregate.
-
-
-8. TRANSLATION
-
-Translation is considered a kind of modification, so you may
-distribute translations of the Document under the terms of section 4.
-Replacing Invariant Sections with translations requires special
-permission from their copyright holders, but you may include
-translations of some or all Invariant Sections in addition to the
-original versions of these Invariant Sections. You may include a
-translation of this License provided that you also include the
-original English version of this License. In case of a disagreement
-between the translation and the original English version of this
-License, the original English version will prevail.
-
-
-9. TERMINATION
-
-You may not copy, modify, sublicense, or distribute the Document except
-as expressly provided for under this License. Any other attempt to
-copy, modify, sublicense or distribute the Document is void, and will
-automatically terminate your rights under this License. However,
-parties who have received copies, or rights, from you under this
-License will not have their licenses terminated so long as such
-parties remain in full compliance.
-
-
-10. FUTURE REVISIONS OF THIS LICENSE
-
-The Free Software Foundation may publish new, revised versions
-of the GNU Free Documentation License from time to time. Such new
-versions will be similar in spirit to the present version, but may
-differ in detail to address new problems or concerns. See
-http://www.gnu.org/copyleft/.
-
-Each version of the License is given a distinguishing version number.
-If the Document specifies that a particular numbered version of this
-License "or any later version" applies to it, you have the option of
-following the terms and conditions either of that specified version or
-of any later version that has been published (not as a draft) by the
-Free Software Foundation. If the Document does not specify a version
-number of this License, you may choose any version ever published (not
-as a draft) by the Free Software Foundation.
-
-
-ADDENDUM: How to use this License for your documents
-
-To use this License in a document you have written, include a copy of
-the License in the document and put the following copyright and
-license notices just after the title page:
-
-@smallexample
- Copyright (c) YEAR YOUR NAME.
- Permission is granted to copy, distribute and/or modify this document
- under the terms of the GNU Free Documentation License, Version 1.1
- or any later version published by the Free Software Foundation;
- with the Invariant Sections being LIST THEIR TITLES, with the
- Front-Cover Texts being LIST, and with the Back-Cover Texts being LIST.
- A copy of the license is included in the section entitled "GNU
- Free Documentation License".
-@end smallexample
-
-If you have no Invariant Sections, write "with no Invariant Sections"
-instead of saying which ones are invariant. If you have no
-Front-Cover Texts, write "no Front-Cover Texts" instead of
-"Front-Cover Texts being LIST"; likewise for Back-Cover Texts.
-
-If your document contains nontrivial examples of program code, we
-recommend releasing these examples in parallel under your choice of
-free software license, such as the GNU General Public License,
-to permit their use in free software.
+@include fdl.texi
@node Index
@unnumbered Index
diff --git a/contrib/binutils/gas/doc/c-alpha.texi b/contrib/binutils/gas/doc/c-alpha.texi
index 5b52c5a..0aee06b 100644
--- a/contrib/binutils/gas/doc/c-alpha.texi
+++ b/contrib/binutils/gas/doc/c-alpha.texi
@@ -139,12 +139,12 @@ OpenVMS syntax, with a few differences for ELF.
@cindex Alpha registers
@cindex register names, Alpha
-The 32 integer registers are refered to as @samp{$@var{n}} or
+The 32 integer registers are referred to as @samp{$@var{n}} or
@samp{$r@var{n}}. In addition, registers 15, 28, 29, and 30 may
-be refered to by the symbols @samp{$fp}, @samp{$at}, @samp{$gp},
+be referred to by the symbols @samp{$fp}, @samp{$at}, @samp{$gp},
and @samp{$sp} respectively.
-The 32 floating-point registers are refered to as @samp{$f@var{n}}.
+The 32 floating-point registers are referred to as @samp{$f@var{n}}.
@node Alpha-Relocs
@subsection Relocations
@@ -153,7 +153,7 @@ The 32 floating-point registers are refered to as @samp{$f@var{n}}.
Some of these relocations are available for ECOFF, but mostly
only for ELF. They are modeled after the relocation format
-introduced in Digial Unix 4.0, but there are additions.
+introduced in Digital Unix 4.0, but there are additions.
The format is @samp{!@var{tag}} or @samp{!@var{tag}!@var{number}}
where @var{tag} is the name of the relocation. In some cases
@@ -379,6 +379,18 @@ to perform a load of the GP register; 2 indicates that @code{$27} is
used in some non-standard way and so the linker cannot elide the load of
the procedure vector during relaxation.
+@item .usepv @var{function}, @var{which}
+Used to indicate the use of the @code{$27} register, similar to
+@code{.prologue}, but without the other semantics of needing to
+be inside an open @code{.ent}/@code{.end} block.
+
+The @var{which} argument should be either @code{no}, indicating that
+@code{$27} is not used, or @code{std}, indicating that the first two
+instructions of the function perform a GP load.
+
+One might use this directive instead of @code{.prologue} if you are
+also using dwarf2 CFI directives.
+
@item .gprel32 @var{expression}
Computes the difference between the address in @var{expression} and the
GP for the current object file, and stores it in 4 bytes. In addition
@@ -413,7 +425,7 @@ is in effect. When @code{at} is in effect, a warning will be generated
if @code{$at} is used by the programmer.
@item macro
-Enables the expasion of macro instructions. Note that variants of real
+Enables the expansion of macro instructions. Note that variants of real
instructions, such as @code{br label} vs @code{br $31,label} are
considered alternate forms and not macros.
diff --git a/contrib/binutils/gas/doc/c-arm.texi b/contrib/binutils/gas/doc/c-arm.texi
index 022faa0..23cd7bb 100644
--- a/contrib/binutils/gas/doc/c-arm.texi
+++ b/contrib/binutils/gas/doc/c-arm.texi
@@ -1,4 +1,4 @@
-@c Copyright 1996, 1997, 1998, 1999, 2000, 2001
+@c Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2003
@c Free Software Foundation, Inc.
@c This is part of the GAS manual.
@c For copying conditions, see the file as.texinfo.
@@ -22,6 +22,7 @@
* ARM Floating Point:: Floating Point
* ARM Directives:: ARM Machine Directives
* ARM Opcodes:: Opcodes
+* ARM Mapping Symbols:: Mapping Symbols
@end menu
@node ARM Options
@@ -80,6 +81,8 @@ recognized:
@code{arm940t},
@code{arm9tdmi},
@code{arm9e},
+@code{arm926e},
+@code{arm926ejs},
@code{arm946e-r0},
@code{arm946e},
@code{arm966e-r0},
@@ -88,9 +91,13 @@ recognized:
@code{arm10e},
@code{arm1020},
@code{arm1020t},
-@code{arm1020e},
+@code{arm1020e},
+@code{arm1026ejs},
+@code{arm1136js},
+@code{arm1136jfs},
@code{ep9312} (ARM920 with Cirrus Maverick coprocessor),
@code{i80200} (Intel XScale processor)
+@code{iwmmxt} (Intel(r) XScale processor with Wireless MMX(tm) technology coprocessor)
and
@code{xscale}.
The special name @code{all} may be used to allow the
@@ -102,6 +109,7 @@ co-processor instruction space. For example, @code{-mcpu=arm920+maverick}
is equivalent to specifying @code{-mcpu=ep9312}. The following extensions
are currently supported:
@code{+maverick}
+@code{+iwmmxt}
and
@code{+xscale}.
@@ -125,7 +133,10 @@ names are recognized:
@code{armv5t},
@code{armv5txm},
@code{armv5te},
-@code{armv5texp}
+@code{armv5texp},
+@code{armv6},
+@code{armv6j},
+@code{iwmmxt}
and
@code{xscale}.
If both @code{-mcpu} and
@@ -157,9 +168,11 @@ The following format options are recognized:
@code{vfp10-r0},
@code{vfp9},
@code{vfpxd},
-@code{arm1020t}
+@code{arm1020t},
+@code{arm1020e},
+@code{arm1136jfs}
and
-@code{arm1020e}.
+@code{maverick}.
In addition to determining which instructions are assembled, this option
also affects the way in which the @code{.double} assembler directive behaves
@@ -196,7 +209,7 @@ use this to determine the ABI being used by.
@cindex @code{-mapcs-float} command line option, ARM
@item -mapcs-float
-This indicates the the floating point variant of the APCS should be
+This indicates the floating point variant of the APCS should be
used. In this variant floating point arguments are passed in FP
registers rather than integer registers.
@@ -205,6 +218,16 @@ registers rather than integer registers.
This indicates that the reentrant variant of the APCS should be used.
This variant supports position independent code.
+@cindex @code{-mfloat-abi=} command line option, ARM
+@item -mfloat-abi=@var{abi}
+This option specifies that the output generated by the assembler should be
+marked as using specified floating point ABI.
+The following values are recognized:
+@code{soft},
+@code{softfp}
+and
+@code{hard}.
+
@cindex @code{-EB} command line option, ARM
@item -EB
This option specifies that the output generated by the assembler should
@@ -289,7 +312,7 @@ The ARM family uses @sc{ieee} floating-point numbers.
This is the generic @var{.align} directive. For the ARM however if the
first argument is zero (ie no alignment is needed) the assembler will
behave as if the argument had been 2 (ie pad to the next four byte
-boundary). This is for compatability with ARM's own assembler.
+boundary). This is for compatibility with ARM's own assembler.
@cindex @code{req} directive, ARM
@item @var{name} .req @var{register name}
@@ -300,6 +323,20 @@ example:
foo .req r0
@end smallexample
+@cindex @code{unreq} directive, ARM
+@item .unreq @var{alias-name}
+This undefines a register alias which was previously defined using the
+@code{req} directive. For example:
+
+@smallexample
+ foo .req r0
+ .unreq foo
+@end smallexample
+
+An error occurs if the name is undefined. Note - this pseudo op can
+be used to delete builtin in register name aliases (eg 'r0'). This
+should only be done if it is really necessary.
+
@cindex @code{code} directive, ARM
@item .code @code{[16|32]}
This directive selects the instruction set being generated. The value 16
@@ -340,6 +377,14 @@ way that the @code{.thumb_func} directive does.
This directive causes the current contents of the literal pool to be
dumped into the current section (which is assumed to be the .text
section) at the current location (aligned to a word boundary).
+@code{GAS} maintains a separate literal pool for each section and each
+sub-section. The @code{.ltorg} directive will only affect the literal
+pool of the current section and sub-section. At the end of assembly
+all remaining, un-empty literal pools will automatically be dumped.
+
+Note - older versions of @code{GAS} would dump the current literal
+pool any time a section change occurred. This is no longer done, since
+it prevents accurate control of the placement of literal pools.
@cindex @code{.pool} directive, ARM
@item .pool
@@ -414,3 +459,32 @@ For information on the ARM or Thumb instruction sets, see @cite{ARM
Software Development Toolkit Reference Manual}, Advanced RISC Machines
Ltd.
+@node ARM Mapping Symbols
+@section Mapping Symbols
+
+The ARM ELF specification requires that special symbols be inserted
+into object files to mark certain features:
+
+@table @code
+
+@cindex @code{$a}
+@item $a
+At the start of a region of code containing ARM instructions.
+
+@cindex @code{$t}
+@item $t
+At the start of a region of code containing THUMB instructions.
+
+@cindex @code{$d}
+@item $d
+At the start of a region of data.
+
+@end table
+
+The assembler will automatically insert these symbols for you - there
+is no need to code them yourself. Support for tagging symbols ($b,
+$f, $p and $m) which is also mentioned in the current ARM ELF
+specification is not implemented. This is because they have been
+dropped from the new EABI and so tools cannot rely upon their
+presence.
+
diff --git a/contrib/binutils/gas/doc/c-i386.texi b/contrib/binutils/gas/doc/c-i386.texi
index 1527c8d..f0047f9 100644
--- a/contrib/binutils/gas/doc/c-i386.texi
+++ b/contrib/binutils/gas/doc/c-i386.texi
@@ -61,6 +61,11 @@ These options are only available with the ELF object file format, and
require that the necessary BFD support has been included (on a 32-bit
platform you have to add --enable-64-bit-bfd to configure enable 64-bit
usage and use x86-64 as target platform).
+
+@item -n
+By default, x86 GAS replaces multiple nop instructions used for
+alignment within code sections with multi-byte nop instructions such
+as leal 0(%esi,1),%esi. This switch disables the optimization.
@end table
@node i386-Syntax
diff --git a/contrib/binutils/gas/doc/c-ia64.texi b/contrib/binutils/gas/doc/c-ia64.texi
index 0885f1b..b62c05e 100644
--- a/contrib/binutils/gas/doc/c-ia64.texi
+++ b/contrib/binutils/gas/doc/c-ia64.texi
@@ -44,7 +44,7 @@ flag in the ELF file header.
This option instructs the assembler to mark the resulting object file
as using the ``constant GP without function descriptor'' data model.
This model is like the ``constant GP'' model, except that it
-additionaly does away with function descriptors. What this means is
+additionally does away with function descriptors. What this means is
that the address of a function refers directly to the function's code
entry-point. Normally, such an address would refer to a function
descriptor, which contains both the code entry-point and the GP-value
@@ -110,12 +110,12 @@ Reference Guide.
@cindex IA-64 registers
@cindex register names, IA-64
-The 128 integer registers are refered to as @samp{r@var{n}}.
-The 128 floating-point registers are refered to as @samp{f@var{n}}.
-The 128 application registers are refered to as @samp{ar@var{n}}.
-The 128 control registers are refered to as @samp{cr@var{n}}.
-The 64 one-bit predicate registers are refered to as @samp{p@var{n}}.
-The 8 branch registers are refered to as @samp{b@var{n}}.
+The 128 integer registers are referred to as @samp{r@var{n}}.
+The 128 floating-point registers are referred to as @samp{f@var{n}}.
+The 128 application registers are referred to as @samp{ar@var{n}}.
+The 128 control registers are referred to as @samp{cr@var{n}}.
+The 64 one-bit predicate registers are referred to as @samp{p@var{n}}.
+The 8 branch registers are referred to as @samp{b@var{n}}.
In addition, the assembler defines a number of aliases:
@samp{gp} (@samp{r1}), @samp{sp} (@samp{r12}), @samp{rp} (@samp{b0}),
@samp{ret0} (@samp{r8}), @samp{ret1} (@samp{r9}), @samp{ret2} (@samp{r10}),
diff --git a/contrib/binutils/gas/doc/c-ppc.texi b/contrib/binutils/gas/doc/c-ppc.texi
index 7fae6ed..be90e33 100644
--- a/contrib/binutils/gas/doc/c-ppc.texi
+++ b/contrib/binutils/gas/doc/c-ppc.texi
@@ -15,6 +15,7 @@
@cindex PowerPC support
@menu
* PowerPC-Opts:: Options
+* PowerPC-Pseudo:: PowerPC Assembler Directives
@end menu
@node PowerPC-Opts
@@ -48,6 +49,9 @@ Generate code for PowerPC 603/604.
@item -m403, -m405
Generate code for PowerPC 403/405.
+@item -m440
+Generate code for PowerPC 440. BookE and some 405 instructions.
+
@item -m7400, -m7410, -m7450, -m7455
Generate code for PowerPC 7400/7410/7450/7455.
@@ -102,3 +106,21 @@ Generate code for Solaris.
@item -mno-solaris
Do not generate code for Solaris.
@end table
+
+
+@node PowerPC-Pseudo
+@section PowerPC Assembler Directives
+
+@cindex directives for PowerPC
+@cindex PowerPC directives
+A number of assembler directives are available for PowerPC. The
+following table is far from complete.
+
+@table @code
+@item .machine "string"
+This directive allows you to change the machine for which code is
+generated. @code{"string"} may be any of the -m cpu selection options
+(without the -m) enclosed in double quotes, @code{"push"}, or
+@code{"pop"}. @code{.machine "push"} saves the currently selected
+cpu, which may be restored with @code{.machine "pop"}.
+@end table
diff --git a/contrib/binutils/gas/doc/c-sh.texi b/contrib/binutils/gas/doc/c-sh.texi
index df31844..b08f325 100644
--- a/contrib/binutils/gas/doc/c-sh.texi
+++ b/contrib/binutils/gas/doc/c-sh.texi
@@ -1,10 +1,10 @@
-@c Copyright 1991, 1992, 1993, 1994, 1995, 1997, 2001
+@c Copyright 1991, 1992, 1993, 1994, 1995, 1997, 2001, 2004
@c Free Software Foundation, Inc.
@c This is part of the GAS manual.
@c For copying conditions, see the file as.texinfo.
@page
@node SH-Dependent
-@chapter Hitachi SH Dependent Features
+@chapter Renesas / SuperH SH Dependent Features
@cindex SH support
@menu
@@ -20,8 +20,8 @@
@cindex SH options
@cindex options, SH
-@code{@value{AS}} has following command-line options for the Hitachi
-SH family.
+@code{@value{AS}} has following command-line options for the Renesas
+(formerly Hitachi) / SuperH SH family.
@table @code
@kindex -little
@@ -29,6 +29,7 @@ SH family.
@kindex -relax
@kindex -small
@kindex -dsp
+@kindex -renesas
@item -little
Generate little endian code.
@@ -45,6 +46,19 @@ Align sections to 4 byte boundaries, not 16.
@item -dsp
Enable sh-dsp insns, and disable sh3e / sh4 insns.
+@item -renesas
+Disable optimization with section symbol for compatibility with
+Renesas assembler.
+
+@item -isa=sh4 | sh4a
+Specify the sh4 or sh4a instruction set.
+@item -isa=dsp
+Enable sh-dsp insns, and disable sh3e / sh4 insns.
+@item -isa=fp
+Enable sh2e, sh3e, sh4, and sh4a insn sets.
+@item -isa=all
+Enable sh1, sh2, sh2e, sh3, sh3e, sh4, sh4a, and sh-dsp insn sets.
+
@end table
@node SH Syntax
@@ -155,9 +169,23 @@ Immediate data
@cindex floating point, SH (@sc{ieee})
@cindex SH floating point (@sc{ieee})
-The SH family has no hardware floating point, but the @code{.float}
-directive generates @sc{ieee} floating-point numbers for compatibility
-with other development tools.
+SH2E, SH3E and SH4 groups have on-chip floating-point unit (FPU). Other
+SH groups can use @code{.float} directive to generate @sc{ieee}
+floating-point numbers.
+
+SH2E and SH3E support single-precision floating point calculations as
+well as entirely PCAPI compatible emulation of double-precision
+floating point calculations. SH2E and SH3E instructions are a subset of
+the floating point calculations conforming to the IEEE754 standard.
+
+In addition to single-precision and double-precision floating-point
+operation capability, the on-chip FPU of SH4 has a 128-bit graphic
+engine that enables 32-bit floating-point data to be processed 128
+bits at a time. It also supports 4 * 4 array operations and inner
+product operations. Also, a superscalar architecture is employed that
+enables simultaneous execution of two instructions (including FPU
+instructions), providing performance of up to twice that of
+conventional architectures at the same frequency.
@node SH Directives
@section SH Machine Directives
@@ -183,7 +211,9 @@ with other development tools.
@cindex mnemonics, SH
@cindex instruction summary, SH
For detailed information on the SH machine instruction set, see
-@cite{SH-Microcomputer User's Manual} (Hitachi Micro Systems, Inc.).
+@cite{SH-Microcomputer User's Manual} (Renesas) or
+@cite{SH-4 32-bit CPU Core Architecture} (SuperH) and
+@cite{SuperH (SH) 64-Bit RISC Series} (SuperH).
@code{@value{AS}} implements all the standard SH opcodes. No additional
pseudo-instructions are needed on this family. Note, however, that
@@ -289,7 +319,7 @@ stc SR,Rn
@end smallexample
@end ifset
-@ifset Hitachi-all
+@ifset Renesas-all
@ifclear GENERIC
@raisesections
@end ifclear
diff --git a/contrib/binutils/gas/doc/c-sparc.texi b/contrib/binutils/gas/doc/c-sparc.texi
index 624c21e3..c34950e 100644
--- a/contrib/binutils/gas/doc/c-sparc.texi
+++ b/contrib/binutils/gas/doc/c-sparc.texi
@@ -162,7 +162,7 @@ line is also ignored.
This directive declares use of a global application or system register.
It must be followed by a register name %g2, %g3, %g6 or %g7, comma and
the symbol name for that register. If symbol name is @code{#scratch},
-it is a scratch register, if it is @code{#ignore}, it just surpresses any
+it is a scratch register, if it is @code{#ignore}, it just suppresses any
errors about using undeclared global register, but does not emit any
information about it into the object file. This can be useful e.g. if you
save the register before use and restore it after.
diff --git a/contrib/binutils/gas/doc/gasver.texi b/contrib/binutils/gas/doc/gasver.texi
new file mode 100644
index 0000000..3610a96
--- /dev/null
+++ b/contrib/binutils/gas/doc/gasver.texi
@@ -0,0 +1 @@
+@set VERSION 2.15
diff --git a/contrib/binutils/gas/doc/h8.texi b/contrib/binutils/gas/doc/h8.texi
index 0df1714..6eb02f8 100644
--- a/contrib/binutils/gas/doc/h8.texi
+++ b/contrib/binutils/gas/doc/h8.texi
@@ -6,7 +6,7 @@
@clear BOUT
@set COFF
@clear ELF
-@set Hitachi-all
+@set Renesas-all
@set H8/300
@set H8/500
@set SH
@@ -19,7 +19,7 @@
@set GCC gcc
@set LD ld
@set TARGET H8/300 and H8/500
-@set TARGET H8/300, H8/500, and Hitachi SH
+@set TARGET H8/300, H8/500, and Renesas SH
@set OBJ-NAME COFF
@c
@clear have-stabs
diff --git a/contrib/binutils/gas/doc/internals.texi b/contrib/binutils/gas/doc/internals.texi
index 6bd3277..6719bbf 100644
--- a/contrib/binutils/gas/doc/internals.texi
+++ b/contrib/binutils/gas/doc/internals.texi
@@ -1,6 +1,6 @@
\input texinfo
@c Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
-@c 2001
+@c 2001, 2002, 2003
@c Free Software Foundation, Inc.
@setfilename internals.info
@node Top
@@ -704,9 +704,10 @@ processing. After this point, it is safe to operate on one chain per section.
The assembler always has a current frag, named @code{frag_now}. More space is
allocated for the current frag using the @code{frag_more} function; this
-returns a pointer to the amount of requested space. Relaxing is done using
-variant frags allocated by @code{frag_var} or @code{frag_variant}
-(@pxref{Relaxation}).
+returns a pointer to the amount of requested space. The function
+@code{frag_room} says by how much the current frag can be extended.
+Relaxing is done using variant frags allocated by @code{frag_var}
+or @code{frag_variant} (@pxref{Relaxation}).
@node GAS processing
@section What GAS does when it runs
@@ -1032,6 +1033,11 @@ arguments, the character before the @kbd{=} character, and the value of
If you define this macro, it should return nonzero if the current input line
pointer should be treated as the end of a line.
+@item TC_CASE_SENSITIVE
+@cindex TC_CASE_SENSITIVE
+Define this macro if instruction mnemonics and pseudos are case sensitive.
+The default is to have it undefined giving case insensitive names.
+
@item md_parse_name
@cindex md_parse_name
If this macro is defined, GAS will call it for any symbol found in an
@@ -1250,18 +1256,94 @@ information removed. Depending upon the processing performed by
@code{md_convert_frag} the frag information may or may not be necessary, as may
the resolved values of the symbols. The default value is 1.
-@item md_apply_fix3
-@cindex md_apply_fix3
-GAS will call this for each fixup. It should store the correct value in the
-object file. @code{fixup_segment} performs a generic overflow check on the
-@code{valueT *val} argument after @code{md_apply_fix3} returns. If the overflow
-check is relevant for the target machine, then @code{md_apply_fix3} should
-modify @code{valueT *val}, typically to the value stored in the object file.
+@item TC_VALIDATE_FIX (@var{fixP}, @var{seg}, @var{skip})
+@cindex TC_VALIDATE_FIX
+This macro is evaluated for each fixup (when @var{linkrelax} is not set).
+It may be used to change the fixup in @code{struct fix *@var{fixP}} before
+the generic code sees it, or to fully process the fixup. In the latter case,
+a @code{goto @var{skip}} will bypass the generic code.
-@item TC_HANDLES_FX_DONE
-@cindex TC_HANDLES_FX_DONE
-If this macro is defined, it means that @code{md_apply_fix3} correctly sets the
-@code{fx_done} field in the fixup.
+@item md_apply_fix3 (@var{fixP}, @var{valP}, @var{seg})
+@cindex md_apply_fix3
+GAS will call this for each fixup that passes the @code{TC_VALIDATE_FIX} test
+when @var{linkrelax} is not set. It should store the correct value in the
+object file. @code{struct fix *@var{fixP}} is the fixup @code{md_apply_fix3}
+is operating on. @code{valueT *@var{valP}} is the value to store into the
+object files, or at least is the generic code's best guess. Specifically,
+*@var{valP} is the value of the fixup symbol, perhaps modified by
+@code{MD_APPLY_SYM_VALUE}, plus @code{@var{fixP}->fx_offset} (symbol addend),
+less @code{MD_PCREL_FROM_SECTION} for pc-relative fixups.
+@code{segT @var{seg}} is the section the fix is in.
+@code{fixup_segment} performs a generic overflow check on *@var{valP} after
+@code{md_apply_fix3} returns. If the overflow check is relevant for the target
+machine, then @code{md_apply_fix3} should modify *@var{valP}, typically to the
+value stored in the object file.
+
+@item TC_FORCE_RELOCATION (@var{fix})
+@cindex TC_FORCE_RELOCATION
+If this macro returns non-zero, it guarantees that a relocation will be emitted
+even when the value can be resolved locally, as @code{fixup_segment} tries to
+reduce the number of relocations emitted. For example, a fixup expression
+against an absolute symbol will normally not require a reloc. If undefined,
+a default of @w{@code{(S_FORCE_RELOC ((@var{fix})->fx_addsy))}} is used.
+
+@item TC_FORCE_RELOCATION_ABS (@var{fix})
+@cindex TC_FORCE_RELOCATION_ABS
+Like @code{TC_FORCE_RELOCATION}, but used only for fixup expressions against an
+absolute symbol. If undefined, @code{TC_FORCE_RELOCATION} will be used.
+
+@item TC_FORCE_RELOCATION_LOCAL (@var{fix})
+@cindex TC_FORCE_RELOCATION_LOCAL
+Like @code{TC_FORCE_RELOCATION}, but used only for fixup expressions against a
+symbol in the current section. If undefined, fixups that are not
+@code{fx_pcrel} or @code{fx_plt} or for which @code{TC_FORCE_RELOCATION}
+returns non-zero, will emit relocs.
+
+@item TC_FORCE_RELOCATION_SUB_SAME (@var{fix}, @var{seg})
+@cindex TC_FORCE_RELOCATION_SUB_SAME
+This macro controls resolution of fixup expressions involving the
+difference of two symbols in the same section. If this macro returns zero,
+the subtrahend will be resolved and @code{fx_subsy} set to @code{NULL} for
+@code{md_apply_fix3}. If undefined, the default of
+@w{@code{! SEG_NORMAL (@var{seg}) || TC_FORCE_RELOCATION (@var{fix})}} will
+be used.
+
+@item TC_FORCE_RELOCATION_SUB_ABS (@var{fix})
+@cindex TC_FORCE_RELOCATION_SUB_ABS
+Like @code{TC_FORCE_RELOCATION_SUB_SAME}, but used when the subtrahend is an
+absolute symbol. If the macro is undefined a default of @code{0} is used.
+
+@item TC_FORCE_RELOCATION_SUB_LOCAL (@var{fix})
+@cindex TC_FORCE_RELOCATION_SUB_LOCAL
+Like @code{TC_FORCE_RELOCATION_SUB_ABS}, but the subtrahend is a symbol in the
+same section as the fixup.
+
+@item TC_VALIDATE_FIX_SUB (@var{fix})
+@cindex TC_VALIDATE_FIX_SUB
+This macro is evaluated for any fixup with a @code{fx_subsy} that
+@code{fixup_segment} cannot reduce to a number. If the macro returns
+@code{false} an error will be reported.
+
+@item MD_APPLY_SYM_VALUE (@var{fix})
+@cindex MD_APPLY_SYM_VALUE
+This macro controls whether the symbol value becomes part of the value passed
+to @code{md_apply_fix3}. If the macro is undefined, or returns non-zero, the
+symbol value will be included. For ELF, a suitable definition might simply be
+@code{0}, because ELF relocations don't include the symbol value in the addend.
+
+@item S_FORCE_RELOC (@var{sym}, @var{strict})
+@cindex S_FORCE_RELOC
+This macro (or function, for @code{BFD_ASSEMBLER} gas) returns true for symbols
+that should not be reduced to section symbols or eliminated from expressions,
+because they may be overridden by the linker. ie. for symbols that are
+undefined or common, and when @var{strict} is set, weak, or global (for ELF
+assemblers that support ELF shared library linking semantics).
+
+@item EXTERN_FORCE_RELOC
+@cindex EXTERN_FORCE_RELOC
+This macro controls whether @code{S_FORCE_RELOC} returns true for global
+symbols. If undefined, the default is @code{true} for ELF assemblers, and
+@code{false} for non-ELF.
@item tc_gen_reloc
@cindex tc_gen_reloc
@@ -1346,7 +1428,7 @@ colon, the adjoining tokens can be distinguished. This option affects the
preprocessor so that whitespace around colons is preserved. This is useful
when colons might be removed from the input after preprocessing but before
assembling, so that adjoining tokens can still be distinguished if there is
-whitespace, or concatentated if there is not.
+whitespace, or concatenated if there is not.
@item tc_frob_section
@cindex tc_frob_section
@@ -1362,7 +1444,7 @@ symbols.
@item tc_frob_symbol
@cindex tc_frob_symbol
If you define this macro, GAS will call it for each symbol. You can indicate
-that the symbol should not be included in the object file by definining this
+that the symbol should not be included in the object file by defining this
macro to set its second argument to a non-zero value.
@item tc_frob_file
@@ -1374,6 +1456,10 @@ completed, but before the relocations have been generated.
If you define this macro, GAS will call it after the relocs have been
generated.
+@item md_post_relax_hook
+If you define this macro, GAS will call it after relaxing and sizing the
+segments.
+
@item LISTING_HEADER
A string to use on the header line of a listing. The default value is simply
@code{"GAS LISTING"}.
@@ -1407,6 +1493,33 @@ The COFF @code{.section} directive will use the value of this macro to set
a new section's attributes when a directive has no valid flags or when the
flag is @code{w}. The default value of the macro is @code{SEC_LOAD | SEC_DATA}.
+@item DWARF2_FORMAT ()
+@cindex DWARF2_FORMAT
+If you define this, it should return one of @code{dwarf2_format_32bit},
+@code{dwarf2_format_64bit}, or @code{dwarf2_format_64bit_irix} to indicate
+the size of internal DWARF section offsets and the format of the DWARF initial
+length fields. When @code{dwarf2_format_32bit} is returned, the initial
+length field will be 4 bytes long and section offsets are 32 bits in size.
+For @code{dwarf2_format_64bit} and @code{dwarf2_format_64bit_irix}, section
+offsets are 64 bits in size, but the initial length field differs. An 8 byte
+initial length is indicated by @code{dwarf2_format_64bit_irix} and
+@code{dwarf2_format_64bit} indicates a 12 byte initial length field in
+which the first four bytes are 0xffffffff and the next 8 bytes are
+the section's length.
+
+If you don't define this, @code{dwarf2_format_32bit} will be used as
+the default.
+
+This define only affects @code{.debug_info} and @code{.debug_line}
+sections generated by the assembler. DWARF 2 sections generated by
+other tools will be unaffected by this setting.
+
+@item DWARF2_ADDR_SIZE (@var{bfd})
+@cindex DWARF2_ADDR_SIZE
+It should return the size of an address, as it should be represented in
+debugging info. If you don't define this macro, the default definition uses
+the number of bits per address, as defined in @var{bfd}, divided by 8.
+
@end table
@node Object format backend
@@ -1449,16 +1562,10 @@ You should define this macro to copy object format specific information from
one symbol to another. GAS will call it when one symbol is equated to
another.
-@item obj_fix_adjustable
-@cindex obj_fix_adjustable
-You may define this macro to indicate whether a fixup against a locally defined
-symbol should be adjusted to be against the section symbol. It should return a
-non-zero value if the adjustment is acceptable.
-
@item obj_sec_sym_ok_for_reloc
@cindex obj_sec_sym_ok_for_reloc
You may define this macro to indicate that it is OK to use a section symbol in
-a relocateion entry. If it is not, GAS will define a new symbol at the start
+a relocation entry. If it is not, GAS will define a new symbol at the start
of a section.
@item EMIT_SECTION_SYMBOLS
@@ -1500,7 +1607,7 @@ symbols.
@item obj_frob_symbol
@cindex obj_frob_symbol
If you define this macro, GAS will call it for each symbol. You can indicate
-that the symbol should not be included in the object file by definining this
+that the symbol should not be included in the object file by defining this
macro to set its second argument to a non-zero value.
@item obj_frob_file
@@ -1562,7 +1669,7 @@ case, don't describe the smaller-range, inferior mode.
The @code{fr_subtype} field of a frag is an index into a CPU-specific
relaxation table. That table entry indicates the range of values that can be
stored, the number of bytes that will have to be added to the frag to
-accomodate the addressing mode, and the index of the next entry to examine if
+accommodate the addressing mode, and the index of the next entry to examine if
the value to be stored is outside the range accessible by the current
addressing mode. The @code{fr_symbol} field of the frag indicates what symbol
is to be accessed; the @code{fr_offset} field is added in.
@@ -1639,7 +1746,7 @@ Usually, if the symbol is in the same section as the frag (given by the
@var{sec} argument), the narrowest likely relaxation mode is stored in
@code{fr_subtype}, and that's that.
-If the symbol is undefined, or in a different section (and therefore moveable
+If the symbol is undefined, or in a different section (and therefore movable
to an arbitrarily large distance), the largest available relaxation mode is
specified, @code{fix_new} is called to produce the relocation record,
@code{fr_fix} is increased to include the relocated field (remember, this
@@ -1650,7 +1757,7 @@ It can be accessed via @code{fr_opcode} or @code{fr_fix}.
If you generate frags separately for the basic insn opcode and any relaxable
operands, do not call @code{fix_new} thinking you can emit fixups for the
-opcode field from the relaxable frag. It is not garanteed to be the same frag.
+opcode field from the relaxable frag. It is not guaranteed to be the same frag.
If you need to emit fixups for the opcode field from inspection of the
relaxable frag, then you need to generate a common frag for both the basic
opcode and relaxable fields, or you need to provide the frag for the opcode to
diff --git a/contrib/binutils/gas/dw2gencfi.c b/contrib/binutils/gas/dw2gencfi.c
new file mode 100644
index 0000000..ff0aa35
--- /dev/null
+++ b/contrib/binutils/gas/dw2gencfi.c
@@ -0,0 +1,1042 @@
+/* dw2gencfi.c - Support for generating Dwarf2 CFI information.
+ Copyright 2003 Free Software Foundation, Inc.
+ Contributed by Michal Ludvig <mludvig@suse.cz>
+
+ This file is part of GAS, the GNU Assembler.
+
+ GAS is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
+
+ GAS is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with GAS; see the file COPYING. If not, write to the Free
+ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA. */
+
+#include "as.h"
+#include "dw2gencfi.h"
+
+
+/* We re-use DWARF2_LINE_MIN_INSN_LENGTH for the code alignment field
+ of the CIE. Default to 1 if not otherwise specified. */
+#ifndef DWARF2_LINE_MIN_INSN_LENGTH
+# define DWARF2_LINE_MIN_INSN_LENGTH 1
+#endif
+
+/* If TARGET_USE_CFIPOP is defined, it is required that the target
+ provide the following definitions. Otherwise provide them to
+ allow compilation to continue. */
+#ifndef TARGET_USE_CFIPOP
+# ifndef DWARF2_DEFAULT_RETURN_COLUMN
+# define DWARF2_DEFAULT_RETURN_COLUMN 0
+# endif
+# ifndef DWARF2_CIE_DATA_ALIGNMENT
+# define DWARF2_CIE_DATA_ALIGNMENT 1
+# endif
+#endif
+
+#ifndef EH_FRAME_ALIGNMENT
+# ifdef BFD_ASSEMBLER
+# define EH_FRAME_ALIGNMENT (bfd_get_arch_size (stdoutput) == 64 ? 3 : 2)
+# else
+# define EH_FRAME_ALIGNMENT 2
+# endif
+#endif
+
+#ifndef tc_cfi_frame_initial_instructions
+# define tc_cfi_frame_initial_instructions() ((void)0)
+#endif
+
+
+struct cfi_insn_data
+{
+ struct cfi_insn_data *next;
+ int insn;
+ union {
+ struct {
+ unsigned reg;
+ offsetT offset;
+ } ri;
+
+ struct {
+ unsigned reg1;
+ unsigned reg2;
+ } rr;
+
+ unsigned r;
+ offsetT i;
+
+ struct {
+ symbolS *lab1;
+ symbolS *lab2;
+ } ll;
+
+ struct cfi_escape_data {
+ struct cfi_escape_data *next;
+ expressionS exp;
+ } *esc;
+ } u;
+};
+
+struct fde_entry
+{
+ struct fde_entry *next;
+ symbolS *start_address;
+ symbolS *end_address;
+ struct cfi_insn_data *data;
+ struct cfi_insn_data **last;
+ unsigned int return_column;
+};
+
+struct cie_entry
+{
+ struct cie_entry *next;
+ symbolS *start_address;
+ unsigned int return_column;
+ struct cfi_insn_data *first, *last;
+};
+
+
+/* Current open FDE entry. */
+static struct fde_entry *cur_fde_data;
+static symbolS *last_address;
+static offsetT cur_cfa_offset;
+
+/* List of FDE entries. */
+static struct fde_entry *all_fde_data;
+static struct fde_entry **last_fde_data = &all_fde_data;
+
+/* List of CIEs so that they could be reused. */
+static struct cie_entry *cie_root;
+
+/* Stack of old CFI data, for save/restore. */
+struct cfa_save_data
+{
+ struct cfa_save_data *next;
+ offsetT cfa_offset;
+};
+
+static struct cfa_save_data *cfa_save_stack;
+
+/* Construct a new FDE structure and add it to the end of the fde list. */
+
+static struct fde_entry *
+alloc_fde_entry (void)
+{
+ struct fde_entry *fde = xcalloc (1, sizeof (struct fde_entry));
+
+ cur_fde_data = fde;
+ *last_fde_data = fde;
+ last_fde_data = &fde->next;
+
+ fde->last = &fde->data;
+ fde->return_column = DWARF2_DEFAULT_RETURN_COLUMN;
+
+ return fde;
+}
+
+/* The following functions are available for a backend to construct its
+ own unwind information, usually from legacy unwind directives. */
+
+/* Construct a new INSN structure and add it to the end of the insn list
+ for the currently active FDE. */
+
+static struct cfi_insn_data *
+alloc_cfi_insn_data (void)
+{
+ struct cfi_insn_data *insn = xcalloc (1, sizeof (struct cfi_insn_data));
+
+ *cur_fde_data->last = insn;
+ cur_fde_data->last = &insn->next;
+
+ return insn;
+}
+
+/* Construct a new FDE structure that begins at LABEL. */
+
+void
+cfi_new_fde (symbolS *label)
+{
+ struct fde_entry *fde = alloc_fde_entry ();
+ fde->start_address = label;
+ last_address = label;
+}
+
+/* End the currently open FDE. */
+
+void
+cfi_end_fde (symbolS *label)
+{
+ cur_fde_data->end_address = label;
+ cur_fde_data = NULL;
+}
+
+/* Set the return column for the current FDE. */
+
+void
+cfi_set_return_column (unsigned regno)
+{
+ cur_fde_data->return_column = regno;
+}
+
+/* Universal functions to store new instructions. */
+
+static void
+cfi_add_CFA_insn(int insn)
+{
+ struct cfi_insn_data *insn_ptr = alloc_cfi_insn_data ();
+
+ insn_ptr->insn = insn;
+}
+
+static void
+cfi_add_CFA_insn_reg (int insn, unsigned regno)
+{
+ struct cfi_insn_data *insn_ptr = alloc_cfi_insn_data ();
+
+ insn_ptr->insn = insn;
+ insn_ptr->u.r = regno;
+}
+
+static void
+cfi_add_CFA_insn_offset (int insn, offsetT offset)
+{
+ struct cfi_insn_data *insn_ptr = alloc_cfi_insn_data ();
+
+ insn_ptr->insn = insn;
+ insn_ptr->u.i = offset;
+}
+
+static void
+cfi_add_CFA_insn_reg_reg (int insn, unsigned reg1, unsigned reg2)
+{
+ struct cfi_insn_data *insn_ptr = alloc_cfi_insn_data ();
+
+ insn_ptr->insn = insn;
+ insn_ptr->u.rr.reg1 = reg1;
+ insn_ptr->u.rr.reg2 = reg2;
+}
+
+static void
+cfi_add_CFA_insn_reg_offset (int insn, unsigned regno, offsetT offset)
+{
+ struct cfi_insn_data *insn_ptr = alloc_cfi_insn_data ();
+
+ insn_ptr->insn = insn;
+ insn_ptr->u.ri.reg = regno;
+ insn_ptr->u.ri.offset = offset;
+}
+
+/* Add a CFI insn to advance the PC from the last address to LABEL. */
+
+void
+cfi_add_advance_loc (symbolS *label)
+{
+ struct cfi_insn_data *insn = alloc_cfi_insn_data ();
+
+ insn->insn = DW_CFA_advance_loc;
+ insn->u.ll.lab1 = last_address;
+ insn->u.ll.lab2 = label;
+
+ last_address = label;
+}
+
+/* Add a DW_CFA_offset record to the CFI data. */
+
+void
+cfi_add_CFA_offset (unsigned regno, offsetT offset)
+{
+ unsigned int abs_data_align;
+
+ cfi_add_CFA_insn_reg_offset (DW_CFA_offset, regno, offset);
+
+ abs_data_align = (DWARF2_CIE_DATA_ALIGNMENT < 0
+ ? -DWARF2_CIE_DATA_ALIGNMENT : DWARF2_CIE_DATA_ALIGNMENT);
+ if (offset % abs_data_align)
+ as_bad (_("register save offset not a multiple of %u"), abs_data_align);
+}
+
+/* Add a DW_CFA_def_cfa record to the CFI data. */
+
+void
+cfi_add_CFA_def_cfa (unsigned regno, offsetT offset)
+{
+ cfi_add_CFA_insn_reg_offset (DW_CFA_def_cfa, regno, offset);
+ cur_cfa_offset = offset;
+}
+
+/* Add a DW_CFA_register record to the CFI data. */
+
+void
+cfi_add_CFA_register (unsigned reg1, unsigned reg2)
+{
+ cfi_add_CFA_insn_reg_reg (DW_CFA_register, reg1, reg2);
+}
+
+/* Add a DW_CFA_def_cfa_register record to the CFI data. */
+
+void
+cfi_add_CFA_def_cfa_register (unsigned regno)
+{
+ cfi_add_CFA_insn_reg (DW_CFA_def_cfa_register, regno);
+}
+
+/* Add a DW_CFA_def_cfa_offset record to the CFI data. */
+
+void
+cfi_add_CFA_def_cfa_offset (offsetT offset)
+{
+ cfi_add_CFA_insn_offset (DW_CFA_def_cfa_offset, offset);
+ cur_cfa_offset = offset;
+}
+
+void
+cfi_add_CFA_restore (unsigned regno)
+{
+ cfi_add_CFA_insn_reg (DW_CFA_restore, regno);
+}
+
+void
+cfi_add_CFA_undefined (unsigned regno)
+{
+ cfi_add_CFA_insn_reg (DW_CFA_undefined, regno);
+}
+
+void
+cfi_add_CFA_same_value (unsigned regno)
+{
+ cfi_add_CFA_insn_reg (DW_CFA_same_value, regno);
+}
+
+void
+cfi_add_CFA_remember_state (void)
+{
+ struct cfa_save_data *p;
+
+ cfi_add_CFA_insn (DW_CFA_remember_state);
+
+ p = xmalloc (sizeof (*p));
+ p->cfa_offset = cur_cfa_offset;
+ p->next = cfa_save_stack;
+ cfa_save_stack = p;
+}
+
+void
+cfi_add_CFA_restore_state (void)
+{
+ struct cfa_save_data *p;
+
+ cfi_add_CFA_insn (DW_CFA_restore_state);
+
+ p = cfa_save_stack;
+ if (p)
+ {
+ cur_cfa_offset = p->cfa_offset;
+ cfa_save_stack = p->next;
+ free (p);
+ }
+}
+
+
+/* Parse CFI assembler directives. */
+
+static void dot_cfi (int);
+static void dot_cfi_escape (int);
+static void dot_cfi_startproc (int);
+static void dot_cfi_endproc (int);
+
+/* Fake CFI type; outside the byte range of any real CFI insn. */
+#define CFI_adjust_cfa_offset 0x100
+#define CFI_return_column 0x101
+#define CFI_rel_offset 0x102
+#define CFI_escape 0x103
+
+const pseudo_typeS cfi_pseudo_table[] =
+ {
+ { "cfi_startproc", dot_cfi_startproc, 0 },
+ { "cfi_endproc", dot_cfi_endproc, 0 },
+ { "cfi_def_cfa", dot_cfi, DW_CFA_def_cfa },
+ { "cfi_def_cfa_register", dot_cfi, DW_CFA_def_cfa_register },
+ { "cfi_def_cfa_offset", dot_cfi, DW_CFA_def_cfa_offset },
+ { "cfi_adjust_cfa_offset", dot_cfi, CFI_adjust_cfa_offset },
+ { "cfi_offset", dot_cfi, DW_CFA_offset },
+ { "cfi_rel_offset", dot_cfi, CFI_rel_offset },
+ { "cfi_register", dot_cfi, DW_CFA_register },
+ { "cfi_return_column", dot_cfi, CFI_return_column },
+ { "cfi_restore", dot_cfi, DW_CFA_restore },
+ { "cfi_undefined", dot_cfi, DW_CFA_undefined },
+ { "cfi_same_value", dot_cfi, DW_CFA_same_value },
+ { "cfi_remember_state", dot_cfi, DW_CFA_remember_state },
+ { "cfi_restore_state", dot_cfi, DW_CFA_restore_state },
+ { "cfi_window_save", dot_cfi, DW_CFA_GNU_window_save },
+ { "cfi_escape", dot_cfi_escape, 0 },
+ { NULL, NULL, 0 }
+ };
+
+static void
+cfi_parse_separator (void)
+{
+ SKIP_WHITESPACE ();
+ if (*input_line_pointer == ',')
+ input_line_pointer++;
+ else
+ as_bad (_("missing separator"));
+}
+
+static unsigned
+cfi_parse_reg (void)
+{
+ int regno;
+ expressionS exp;
+
+#ifdef tc_regname_to_dw2regnum
+ SKIP_WHITESPACE ();
+ if (is_name_beginner (*input_line_pointer)
+ || (*input_line_pointer == '%'
+ && is_name_beginner (*++input_line_pointer)))
+ {
+ char *name, c;
+
+ name = input_line_pointer;
+ c = get_symbol_end ();
+
+ if ((regno = tc_regname_to_dw2regnum (name)) < 0)
+ {
+ as_bad (_("bad register expression"));
+ regno = 0;
+ }
+
+ *input_line_pointer = c;
+ return regno;
+ }
+#endif
+
+ expression (&exp);
+ switch (exp.X_op)
+ {
+ case O_register:
+ case O_constant:
+ regno = exp.X_add_number;
+ break;
+
+ default:
+ as_bad (_("bad register expression"));
+ regno = 0;
+ break;
+ }
+
+ return regno;
+}
+
+static offsetT
+cfi_parse_const (void)
+{
+ return get_absolute_expression ();
+}
+
+static void
+dot_cfi (int arg)
+{
+ offsetT offset;
+ unsigned reg1, reg2;
+
+ if (!cur_fde_data)
+ {
+ as_bad (_("CFI instruction used without previous .cfi_startproc"));
+ return;
+ }
+
+ /* If the last address was not at the current PC, advance to current. */
+ if (symbol_get_frag (last_address) != frag_now
+ || S_GET_VALUE (last_address) != frag_now_fix ())
+ cfi_add_advance_loc (symbol_temp_new_now ());
+
+ switch (arg)
+ {
+ case DW_CFA_offset:
+ reg1 = cfi_parse_reg ();
+ cfi_parse_separator ();
+ offset = cfi_parse_const ();
+ cfi_add_CFA_offset (reg1, offset);
+ break;
+
+ case CFI_rel_offset:
+ reg1 = cfi_parse_reg ();
+ cfi_parse_separator ();
+ offset = cfi_parse_const ();
+ cfi_add_CFA_offset (reg1, offset - cur_cfa_offset);
+ break;
+
+ case DW_CFA_def_cfa:
+ reg1 = cfi_parse_reg ();
+ cfi_parse_separator ();
+ offset = cfi_parse_const ();
+ cfi_add_CFA_def_cfa (reg1, offset);
+ break;
+
+ case DW_CFA_register:
+ reg1 = cfi_parse_reg ();
+ cfi_parse_separator ();
+ reg2 = cfi_parse_reg ();
+ cfi_add_CFA_register (reg1, reg2);
+ break;
+
+ case DW_CFA_def_cfa_register:
+ reg1 = cfi_parse_reg ();
+ cfi_add_CFA_def_cfa_register (reg1);
+ break;
+
+ case DW_CFA_def_cfa_offset:
+ offset = cfi_parse_const ();
+ cfi_add_CFA_def_cfa_offset (offset);
+ break;
+
+ case CFI_adjust_cfa_offset:
+ offset = cfi_parse_const ();
+ cfi_add_CFA_def_cfa_offset (cur_cfa_offset + offset);
+ break;
+
+ case DW_CFA_restore:
+ reg1 = cfi_parse_reg ();
+ cfi_add_CFA_restore (reg1);
+ break;
+
+ case DW_CFA_undefined:
+ reg1 = cfi_parse_reg ();
+ cfi_add_CFA_undefined (reg1);
+ break;
+
+ case DW_CFA_same_value:
+ reg1 = cfi_parse_reg ();
+ cfi_add_CFA_same_value (reg1);
+ break;
+
+ case CFI_return_column:
+ reg1 = cfi_parse_reg ();
+ cfi_set_return_column (reg1);
+ break;
+
+ case DW_CFA_remember_state:
+ cfi_add_CFA_remember_state ();
+ break;
+
+ case DW_CFA_restore_state:
+ cfi_add_CFA_restore_state ();
+ break;
+
+ case DW_CFA_GNU_window_save:
+ cfi_add_CFA_insn (DW_CFA_GNU_window_save);
+ break;
+
+ default:
+ abort ();
+ }
+
+ demand_empty_rest_of_line ();
+}
+
+static void
+dot_cfi_escape (int ignored ATTRIBUTE_UNUSED)
+{
+ struct cfi_escape_data *head, **tail, *e;
+ struct cfi_insn_data *insn;
+
+ if (!cur_fde_data)
+ {
+ as_bad (_("CFI instruction used without previous .cfi_startproc"));
+ return;
+ }
+
+ /* If the last address was not at the current PC, advance to current. */
+ if (symbol_get_frag (last_address) != frag_now
+ || S_GET_VALUE (last_address) != frag_now_fix ())
+ cfi_add_advance_loc (symbol_temp_new_now ());
+
+ tail = &head;
+ do
+ {
+ e = xmalloc (sizeof (*e));
+ do_parse_cons_expression (&e->exp, 1);
+ *tail = e;
+ tail = &e->next;
+ }
+ while (*input_line_pointer++ == ',');
+ *tail = NULL;
+
+ insn = alloc_cfi_insn_data ();
+ insn->insn = CFI_escape;
+ insn->u.esc = head;
+}
+
+static void
+dot_cfi_startproc (int ignored ATTRIBUTE_UNUSED)
+{
+ int simple = 0;
+
+ if (cur_fde_data)
+ {
+ as_bad (_("previous CFI entry not closed (missing .cfi_endproc)"));
+ return;
+ }
+
+ cfi_new_fde (symbol_temp_new_now ());
+
+ SKIP_WHITESPACE ();
+ if (is_name_beginner (*input_line_pointer))
+ {
+ char *name, c;
+
+ name = input_line_pointer;
+ c = get_symbol_end ();
+
+ if (strcmp (name, "simple") == 0)
+ {
+ simple = 1;
+ *input_line_pointer = c;
+ }
+ else
+ input_line_pointer = name;
+ }
+ demand_empty_rest_of_line ();
+
+ if (!simple)
+ tc_cfi_frame_initial_instructions ();
+}
+
+static void
+dot_cfi_endproc (int ignored ATTRIBUTE_UNUSED)
+{
+ if (! cur_fde_data)
+ {
+ as_bad (_(".cfi_endproc without corresponding .cfi_startproc"));
+ return;
+ }
+
+ cfi_end_fde (symbol_temp_new_now ());
+}
+
+
+/* Emit a single byte into the current segment. */
+
+static inline void
+out_one (int byte)
+{
+ FRAG_APPEND_1_CHAR (byte);
+}
+
+/* Emit a two-byte word into the current segment. */
+
+static inline void
+out_two (int data)
+{
+ md_number_to_chars (frag_more (2), data, 2);
+}
+
+/* Emit a four byte word into the current segment. */
+
+static inline void
+out_four (int data)
+{
+ md_number_to_chars (frag_more (4), data, 4);
+}
+
+/* Emit an unsigned "little-endian base 128" number. */
+
+static void
+out_uleb128 (addressT value)
+{
+ output_leb128 (frag_more (sizeof_leb128 (value, 0)), value, 0);
+}
+
+/* Emit an unsigned "little-endian base 128" number. */
+
+static void
+out_sleb128 (offsetT value)
+{
+ output_leb128 (frag_more (sizeof_leb128 (value, 1)), value, 1);
+}
+
+static void
+output_cfi_insn (struct cfi_insn_data *insn)
+{
+ offsetT offset;
+ unsigned int regno;
+
+ switch (insn->insn)
+ {
+ case DW_CFA_advance_loc:
+ {
+ symbolS *from = insn->u.ll.lab1;
+ symbolS *to = insn->u.ll.lab2;
+
+ if (symbol_get_frag (to) == symbol_get_frag (from))
+ {
+ addressT delta = S_GET_VALUE (to) - S_GET_VALUE (from);
+ addressT scaled = delta / DWARF2_LINE_MIN_INSN_LENGTH;
+
+ if (scaled <= 0x3F)
+ out_one (DW_CFA_advance_loc + scaled);
+ else if (delta <= 0xFF)
+ {
+ out_one (DW_CFA_advance_loc1);
+ out_one (delta);
+ }
+ else if (delta <= 0xFFFF)
+ {
+ out_one (DW_CFA_advance_loc2);
+ out_two (delta);
+ }
+ else
+ {
+ out_one (DW_CFA_advance_loc4);
+ out_four (delta);
+ }
+ }
+ else
+ {
+ expressionS exp;
+
+ exp.X_op = O_subtract;
+ exp.X_add_symbol = to;
+ exp.X_op_symbol = from;
+ exp.X_add_number = 0;
+
+ /* The code in ehopt.c expects that one byte of the encoding
+ is already allocated to the frag. This comes from the way
+ that it scans the .eh_frame section looking first for the
+ .byte DW_CFA_advance_loc4. */
+ frag_more (1);
+
+ frag_var (rs_cfa, 4, 0, DWARF2_LINE_MIN_INSN_LENGTH << 3,
+ make_expr_symbol (&exp), frag_now_fix () - 1,
+ (char *) frag_now);
+ }
+ }
+ break;
+
+ case DW_CFA_def_cfa:
+ offset = insn->u.ri.offset;
+ if (offset < 0)
+ {
+ out_one (DW_CFA_def_cfa_sf);
+ out_uleb128 (insn->u.ri.reg);
+ out_uleb128 (offset);
+ }
+ else
+ {
+ out_one (DW_CFA_def_cfa);
+ out_uleb128 (insn->u.ri.reg);
+ out_uleb128 (offset);
+ }
+ break;
+
+ case DW_CFA_def_cfa_register:
+ case DW_CFA_undefined:
+ case DW_CFA_same_value:
+ out_one (insn->insn);
+ out_uleb128 (insn->u.r);
+ break;
+
+ case DW_CFA_def_cfa_offset:
+ offset = insn->u.i;
+ if (offset < 0)
+ {
+ out_one (DW_CFA_def_cfa_offset_sf);
+ out_sleb128 (offset);
+ }
+ else
+ {
+ out_one (DW_CFA_def_cfa_offset);
+ out_uleb128 (offset);
+ }
+ break;
+
+ case DW_CFA_restore:
+ regno = insn->u.r;
+ if (regno <= 0x3F)
+ {
+ out_one (DW_CFA_restore + regno);
+ }
+ else
+ {
+ out_one (DW_CFA_restore_extended);
+ out_uleb128 (regno);
+ }
+ break;
+
+ case DW_CFA_offset:
+ regno = insn->u.ri.reg;
+ offset = insn->u.ri.offset / DWARF2_CIE_DATA_ALIGNMENT;
+ if (offset < 0)
+ {
+ out_one (DW_CFA_offset_extended_sf);
+ out_uleb128 (regno);
+ out_sleb128 (offset);
+ }
+ else if (regno <= 0x3F)
+ {
+ out_one (DW_CFA_offset + regno);
+ out_uleb128 (offset);
+ }
+ else
+ {
+ out_one (DW_CFA_offset_extended);
+ out_uleb128 (regno);
+ out_uleb128 (offset);
+ }
+ break;
+
+ case DW_CFA_register:
+ out_one (DW_CFA_register);
+ out_uleb128 (insn->u.rr.reg1);
+ out_uleb128 (insn->u.rr.reg2);
+ break;
+
+ case DW_CFA_remember_state:
+ case DW_CFA_restore_state:
+ out_one (insn->insn);
+ break;
+
+ case DW_CFA_GNU_window_save:
+ out_one (DW_CFA_GNU_window_save);
+ break;
+
+ case CFI_escape:
+ {
+ struct cfi_escape_data *e;
+ for (e = insn->u.esc; e ; e = e->next)
+ emit_expr (&e->exp, 1);
+ break;
+ }
+
+ default:
+ abort ();
+ }
+}
+
+static void
+output_cie (struct cie_entry *cie)
+{
+ symbolS *after_size_address, *end_address;
+ expressionS exp;
+ struct cfi_insn_data *i;
+
+ cie->start_address = symbol_temp_new_now ();
+ after_size_address = symbol_temp_make ();
+ end_address = symbol_temp_make ();
+
+ exp.X_op = O_subtract;
+ exp.X_add_symbol = end_address;
+ exp.X_op_symbol = after_size_address;
+ exp.X_add_number = 0;
+
+ emit_expr (&exp, 4); /* Length */
+ symbol_set_value_now (after_size_address);
+ out_four (0); /* CIE id */
+ out_one (DW_CIE_VERSION); /* Version */
+ out_one ('z'); /* Augmentation */
+ out_one ('R');
+ out_one (0);
+ out_uleb128 (DWARF2_LINE_MIN_INSN_LENGTH); /* Code alignment */
+ out_sleb128 (DWARF2_CIE_DATA_ALIGNMENT); /* Data alignment */
+ out_one (cie->return_column); /* Return column */
+ out_uleb128 (1); /* Augmentation size */
+#if defined DIFF_EXPR_OK || defined tc_cfi_emit_pcrel_expr
+ out_one (DW_EH_PE_pcrel | DW_EH_PE_sdata4);
+#else
+ out_one (DW_EH_PE_sdata4);
+#endif
+
+ if (cie->first)
+ for (i = cie->first; i != cie->last; i = i->next)
+ output_cfi_insn (i);
+
+ frag_align (2, 0, 0);
+ symbol_set_value_now (end_address);
+}
+
+static void
+output_fde (struct fde_entry *fde, struct cie_entry *cie,
+ struct cfi_insn_data *first, int align)
+{
+ symbolS *after_size_address, *end_address;
+ expressionS exp;
+
+ after_size_address = symbol_temp_make ();
+ end_address = symbol_temp_make ();
+
+ exp.X_op = O_subtract;
+ exp.X_add_symbol = end_address;
+ exp.X_op_symbol = after_size_address;
+ exp.X_add_number = 0;
+ emit_expr (&exp, 4); /* Length */
+ symbol_set_value_now (after_size_address);
+
+ exp.X_add_symbol = after_size_address;
+ exp.X_op_symbol = cie->start_address;
+ emit_expr (&exp, 4); /* CIE offset */
+
+#ifdef DIFF_EXPR_OK
+ exp.X_add_symbol = fde->start_address;
+ exp.X_op_symbol = symbol_temp_new_now ();
+ emit_expr (&exp, 4); /* Code offset */
+#else
+ exp.X_op = O_symbol;
+ exp.X_add_symbol = fde->start_address;
+ exp.X_op_symbol = NULL;
+#ifdef tc_cfi_emit_pcrel_expr
+ tc_cfi_emit_pcrel_expr (&exp, 4); /* Code offset */
+#else
+ emit_expr (&exp, 4); /* Code offset */
+#endif
+ exp.X_op = O_subtract;
+#endif
+
+ exp.X_add_symbol = fde->end_address;
+ exp.X_op_symbol = fde->start_address; /* Code length */
+ emit_expr (&exp, 4);
+
+ out_uleb128 (0); /* Augmentation size */
+
+ for (; first; first = first->next)
+ output_cfi_insn (first);
+
+ frag_align (align, 0, 0);
+ symbol_set_value_now (end_address);
+}
+
+static struct cie_entry *
+select_cie_for_fde (struct fde_entry *fde, struct cfi_insn_data **pfirst)
+{
+ struct cfi_insn_data *i, *j;
+ struct cie_entry *cie;
+
+ for (cie = cie_root; cie; cie = cie->next)
+ {
+ if (cie->return_column != fde->return_column)
+ continue;
+ for (i = cie->first, j = fde->data;
+ i != cie->last && j != NULL;
+ i = i->next, j = j->next)
+ {
+ if (i->insn != j->insn)
+ goto fail;
+ switch (i->insn)
+ {
+ case DW_CFA_advance_loc:
+ /* We reached the first advance in the FDE, but did not
+ reach the end of the CIE list. */
+ goto fail;
+
+ case DW_CFA_offset:
+ case DW_CFA_def_cfa:
+ if (i->u.ri.reg != j->u.ri.reg)
+ goto fail;
+ if (i->u.ri.offset != j->u.ri.offset)
+ goto fail;
+ break;
+
+ case DW_CFA_register:
+ if (i->u.rr.reg1 != j->u.rr.reg1)
+ goto fail;
+ if (i->u.rr.reg2 != j->u.rr.reg2)
+ goto fail;
+ break;
+
+ case DW_CFA_def_cfa_register:
+ case DW_CFA_restore:
+ case DW_CFA_undefined:
+ case DW_CFA_same_value:
+ if (i->u.r != j->u.r)
+ goto fail;
+ break;
+
+ case DW_CFA_def_cfa_offset:
+ if (i->u.i != j->u.i)
+ goto fail;
+ break;
+
+ case CFI_escape:
+ /* Don't bother matching these for now. */
+ goto fail;
+
+ default:
+ abort ();
+ }
+ }
+
+ /* Success if we reached the end of the CIE list, and we've either
+ run out of FDE entries or we've encountered an advance. */
+ if (i == cie->last && (!j || j->insn == DW_CFA_advance_loc))
+ {
+ *pfirst = j;
+ return cie;
+ }
+
+ fail:;
+ }
+
+ cie = xmalloc (sizeof (struct cie_entry));
+ cie->next = cie_root;
+ cie_root = cie;
+ cie->return_column = fde->return_column;
+ cie->first = fde->data;
+
+ for (i = cie->first; i ; i = i->next)
+ if (i->insn == DW_CFA_advance_loc)
+ break;
+
+ cie->last = i;
+ *pfirst = i;
+
+ output_cie (cie);
+
+ return cie;
+}
+
+void
+cfi_finish (void)
+{
+ segT cfi_seg;
+ struct fde_entry *fde;
+ int save_flag_traditional_format;
+
+ if (cur_fde_data)
+ {
+ as_bad (_("open CFI at the end of file; missing .cfi_endproc directive"));
+ cur_fde_data->end_address = cur_fde_data->start_address;
+ }
+
+ if (all_fde_data == 0)
+ return;
+
+ /* Open .eh_frame section. */
+ cfi_seg = subseg_new (".eh_frame", 0);
+#ifdef BFD_ASSEMBLER
+ bfd_set_section_flags (stdoutput, cfi_seg,
+ SEC_ALLOC | SEC_LOAD | SEC_DATA | SEC_READONLY);
+#endif
+ subseg_set (cfi_seg, 0);
+ record_alignment (cfi_seg, EH_FRAME_ALIGNMENT);
+
+ /* Make sure check_eh_frame doesn't do anything with our output. */
+ save_flag_traditional_format = flag_traditional_format;
+ flag_traditional_format = 1;
+
+ for (fde = all_fde_data; fde ; fde = fde->next)
+ {
+ struct cfi_insn_data *first;
+ struct cie_entry *cie;
+
+ cie = select_cie_for_fde (fde, &first);
+ output_fde (fde, cie, first, fde->next == NULL ? EH_FRAME_ALIGNMENT : 2);
+ }
+
+ flag_traditional_format = save_flag_traditional_format;
+}
diff --git a/contrib/binutils/gas/dw2gencfi.h b/contrib/binutils/gas/dw2gencfi.h
new file mode 100644
index 0000000..75b6ec2
--- /dev/null
+++ b/contrib/binutils/gas/dw2gencfi.h
@@ -0,0 +1,52 @@
+/* dw2gencfi.h - Support for generating Dwarf2 CFI information.
+ Copyright 2003 Free Software Foundation, Inc.
+ Contributed by Michal Ludvig <mludvig@suse.cz>
+
+ This file is part of GAS, the GNU Assembler.
+
+ GAS is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
+
+ GAS is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with GAS; see the file COPYING. If not, write to the Free
+ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA. */
+
+#ifndef DW2GENCFI_H
+#define DW2GENCFI_H
+
+#include "elf/dwarf2.h"
+
+struct symbol;
+
+extern const pseudo_typeS cfi_pseudo_table[];
+
+/* cfi_finish() is called at the end of file. It will complain if
+ the last CFI wasn't properly closed by .cfi_endproc. */
+extern void cfi_finish (void);
+
+/* Entry points for backends to add unwind information. */
+extern void cfi_new_fde (struct symbol *);
+extern void cfi_end_fde (struct symbol *);
+extern void cfi_set_return_column (unsigned);
+extern void cfi_add_advance_loc (struct symbol *);
+
+extern void cfi_add_CFA_offset (unsigned, offsetT);
+extern void cfi_add_CFA_def_cfa (unsigned, offsetT);
+extern void cfi_add_CFA_register (unsigned, unsigned);
+extern void cfi_add_CFA_def_cfa_register (unsigned);
+extern void cfi_add_CFA_def_cfa_offset (offsetT);
+extern void cfi_add_CFA_restore (unsigned);
+extern void cfi_add_CFA_undefined (unsigned);
+extern void cfi_add_CFA_same_value (unsigned);
+extern void cfi_add_CFA_remember_state (void);
+extern void cfi_add_CFA_restore_state (void);
+
+#endif /* DW2GENCFI_H */
diff --git a/contrib/binutils/gas/dwarf2dbg.c b/contrib/binutils/gas/dwarf2dbg.c
index a5dffab..3336453 100644
--- a/contrib/binutils/gas/dwarf2dbg.c
+++ b/contrib/binutils/gas/dwarf2dbg.c
@@ -1,5 +1,5 @@
/* dwarf2dbg.c - DWARF2 debug support
- Copyright 1999, 2000, 2001 Free Software Foundation, Inc.
+ Copyright 1999, 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
Contributed by David Mosberger-Tang <davidm@hpl.hp.com>
This file is part of GAS, the GNU Assembler.
@@ -41,9 +41,19 @@
#endif
#endif
+#include "dwarf2dbg.h"
+#include <filenames.h>
+
+#ifndef DWARF2_FORMAT
+# define DWARF2_FORMAT() dwarf2_format_32bit
+#endif
+
+#ifndef DWARF2_ADDR_SIZE
+# define DWARF2_ADDR_SIZE(bfd) (bfd_arch_bits_per_address (bfd) / 8)
+#endif
+
#ifdef BFD_ASSEMBLER
-#include "dwarf2dbg.h"
#include "subsegs.h"
#include "elf/dwarf2.h"
@@ -122,7 +132,7 @@ struct line_seg {
static struct line_seg *all_segs;
struct file_entry {
- char *filename;
+ const char *filename;
unsigned int dir;
};
@@ -131,51 +141,67 @@ static struct file_entry *files;
static unsigned int files_in_use;
static unsigned int files_allocated;
-/* True when we've seen a .loc directive recently. Used to avoid
+/* Table of directories used by .debug_line. */
+static char **dirs;
+static unsigned int dirs_in_use;
+static unsigned int dirs_allocated;
+
+/* TRUE when we've seen a .loc directive recently. Used to avoid
doing work when there's nothing to do. */
-static boolean loc_directive_seen;
+static bfd_boolean loc_directive_seen;
/* Current location as indicated by the most recent .loc directive. */
static struct dwarf2_line_info current;
-/* Fake label name. */
-static char const fake_label_name[] = ".L0\001";
-
/* The size of an address on the target. */
static unsigned int sizeof_address;
-static struct line_subseg *get_line_subseg PARAMS ((segT, subsegT));
-static unsigned int get_filenum PARAMS ((const char *));
-static struct frag *first_frag_for_seg PARAMS ((segT));
-static struct frag *last_frag_for_seg PARAMS ((segT));
-static void out_byte PARAMS ((int));
-static void out_opcode PARAMS ((int));
-static void out_two PARAMS ((int));
-static void out_four PARAMS ((int));
-static void out_abbrev PARAMS ((int, int));
-static void out_uleb128 PARAMS ((addressT));
-static symbolS *symbol_new_now PARAMS ((void));
-static void set_symbol_value_now PARAMS ((symbolS *));
-static offsetT get_frag_fix PARAMS ((fragS *));
-static void out_set_addr PARAMS ((segT, fragS *, addressT));
-static int size_inc_line_addr PARAMS ((int, addressT));
-static void emit_inc_line_addr PARAMS ((int, addressT, char *, int));
-static void out_inc_line_addr PARAMS ((int, addressT));
-static void relax_inc_line_addr PARAMS ((int, segT, fragS *, addressT,
- fragS *, addressT));
-static void process_entries PARAMS ((segT, struct line_entry *));
-static void out_file_list PARAMS ((void));
-static void out_debug_line PARAMS ((segT));
-static void out_debug_aranges PARAMS ((segT, segT));
-static void out_debug_abbrev PARAMS ((segT));
-static void out_debug_info PARAMS ((segT, segT, segT));
+static struct line_subseg *get_line_subseg (segT, subsegT);
+static unsigned int get_filenum (const char *, unsigned int);
+static struct frag *first_frag_for_seg (segT);
+static struct frag *last_frag_for_seg (segT);
+static void out_byte (int);
+static void out_opcode (int);
+static void out_two (int);
+static void out_four (int);
+static void out_abbrev (int, int);
+static void out_uleb128 (addressT);
+static offsetT get_frag_fix (fragS *);
+static void out_set_addr (segT, fragS *, addressT);
+static int size_inc_line_addr (int, addressT);
+static void emit_inc_line_addr (int, addressT, char *, int);
+static void out_inc_line_addr (int, addressT);
+static void relax_inc_line_addr (int, segT, fragS *, addressT,
+ fragS *, addressT);
+static void process_entries (segT, struct line_entry *);
+static void out_file_list (void);
+static void out_debug_line (segT);
+static void out_debug_aranges (segT, segT);
+static void out_debug_abbrev (segT);
+static void out_debug_info (segT, segT, segT);
+#ifndef TC_DWARF2_EMIT_OFFSET
+# define TC_DWARF2_EMIT_OFFSET generic_dwarf2_emit_offset
+static void generic_dwarf2_emit_offset (symbolS *, unsigned int);
+
+/* Create an offset to .dwarf2_*. */
+
+static void
+generic_dwarf2_emit_offset (symbolS *symbol, unsigned int size)
+{
+ expressionS expr;
+
+ expr.X_op = O_symbol;
+ expr.X_add_symbol = symbol;
+ expr.X_add_number = 0;
+ emit_expr (&expr, size);
+}
+#endif
+
/* Find or create an entry for SEG+SUBSEG in ALL_SEGS. */
static struct line_subseg *
-get_line_subseg (seg, subseg)
- segT seg;
- subsegT subseg;
+get_line_subseg (segT seg, subsegT subseg)
{
static segT last_seg;
static subsegT last_subseg;
@@ -221,12 +247,10 @@ get_line_subseg (seg, subseg)
return ss;
}
-/* Record an entry for LOC ocurring at OFS within the current fragment. */
+/* Record an entry for LOC occurring at OFS within the current fragment. */
void
-dwarf2_gen_line_info (ofs, loc)
- addressT ofs;
- struct dwarf2_line_info *loc;
+dwarf2_gen_line_info (addressT ofs, struct dwarf2_line_info *loc)
{
struct line_subseg *ss;
struct line_entry *e;
@@ -260,14 +284,13 @@ dwarf2_gen_line_info (ofs, loc)
}
void
-dwarf2_where (line)
- struct dwarf2_line_info *line;
+dwarf2_where (struct dwarf2_line_info *line)
{
if (debug_type == DEBUG_DWARF2)
{
char *filename;
as_where (&filename, &line->line);
- line->filenum = get_filenum (filename);
+ line->filenum = get_filenum (filename, 0);
line->column = 0;
line->flags = DWARF2_FLAG_BEGIN_STMT;
}
@@ -281,8 +304,7 @@ dwarf2_where (line)
for, emit a line statement appropriately. */
void
-dwarf2_emit_insn (size)
- int size;
+dwarf2_emit_insn (int size)
{
struct dwarf2_line_info loc;
@@ -298,7 +320,7 @@ dwarf2_emit_insn (size)
/* Unless we generate DWARF2 debugging information for each
assembler line, we only emit one line symbol for one LOC. */
if (debug_type != DEBUG_DWARF2)
- loc_directive_seen = false;
+ loc_directive_seen = FALSE;
}
else if (debug_type != DEBUG_DWARF2)
return;
@@ -308,22 +330,82 @@ dwarf2_emit_insn (size)
dwarf2_gen_line_info (frag_now_fix () - size, &loc);
}
-/* Get a .debug_line file number for FILENAME. */
+/* Get a .debug_line file number for FILENAME. If NUM is nonzero,
+ allocate it on that file table slot, otherwise return the first
+ empty one. */
static unsigned int
-get_filenum (filename)
- const char *filename;
+get_filenum (const char *filename, unsigned int num)
{
- static unsigned int last_used;
- unsigned int i;
+ static unsigned int last_used, last_used_dir_len;
+ const char *file;
+ size_t dir_len;
+ unsigned int i, dir;
- if (last_used)
- if (strcmp (filename, files[last_used].filename) == 0)
- return last_used;
+ if (num == 0 && last_used)
+ {
+ if (! files[last_used].dir
+ && strcmp (filename, files[last_used].filename) == 0)
+ return last_used;
+ if (files[last_used].dir
+ && strncmp (filename, dirs[files[last_used].dir],
+ last_used_dir_len) == 0
+ && IS_DIR_SEPARATOR (filename [last_used_dir_len])
+ && strcmp (filename + last_used_dir_len + 1,
+ files[last_used].filename) == 0)
+ return last_used;
+ }
- for (i = 1; i < files_in_use; ++i)
- if (strcmp (filename, files[i].filename) == 0)
- return i;
+ file = lbasename (filename);
+ /* Don't make empty string from / or A: from A:/ . */
+#ifdef HAVE_DOS_BASED_FILE_SYSTEM
+ if (file <= filename + 3)
+ file = filename;
+#else
+ if (file == filename + 1)
+ file = filename;
+#endif
+ dir_len = file - filename;
+
+ dir = 0;
+ if (dir_len)
+ {
+ --dir_len;
+ for (dir = 1; dir < dirs_in_use; ++dir)
+ if (strncmp (filename, dirs[dir], dir_len) == 0
+ && dirs[dir][dir_len] == '\0')
+ break;
+
+ if (dir >= dirs_in_use)
+ {
+ if (dir >= dirs_allocated)
+ {
+ dirs_allocated = dir + 32;
+ dirs = (char **)
+ xrealloc (dirs, (dir + 32) * sizeof (const char *));
+ }
+
+ dirs[dir] = xmalloc (dir_len + 1);
+ memcpy (dirs[dir], filename, dir_len);
+ dirs[dir][dir_len] = '\0';
+ dirs_in_use = dir + 1;
+ }
+ }
+
+ if (num == 0)
+ {
+ for (i = 1; i < files_in_use; ++i)
+ if (files[i].dir == dir
+ && files[i].filename
+ && strcmp (file, files[i].filename) == 0)
+ {
+ last_used = i;
+ last_used_dir_len = dir_len;
+ return i;
+ }
+ }
+ else
+ i = num;
if (i >= files_allocated)
{
@@ -336,10 +418,11 @@ get_filenum (filename)
memset (files + old, 0, (i + 32 - old) * sizeof (struct file_entry));
}
- files[i].filename = xstrdup (filename);
- files[i].dir = 0;
+ files[i].filename = num ? file : xstrdup (file);
+ files[i].dir = dir;
files_in_use = i + 1;
last_used = i;
+ last_used_dir_len = dir_len;
return i;
}
@@ -351,8 +434,7 @@ get_filenum (filename)
If an entry is added to the file table, return a pointer to the filename. */
char *
-dwarf2_directive_file (dummy)
- int dummy ATTRIBUTE_UNUSED;
+dwarf2_directive_file (int dummy ATTRIBUTE_UNUSED)
{
offsetT num;
char *filename;
@@ -382,28 +464,13 @@ dwarf2_directive_file (dummy)
return NULL;
}
- if (num >= (int) files_allocated)
- {
- unsigned int old = files_allocated;
-
- files_allocated = num + 16;
- files = (struct file_entry *)
- xrealloc (files, (num + 16) * sizeof (struct file_entry));
-
- /* Zero the new memory. */
- memset (files + old, 0, (num + 16 - old) * sizeof (struct file_entry));
- }
-
- files[num].filename = filename;
- files[num].dir = 0;
- files_in_use = num + 1;
+ get_filenum (filename, num);
return filename;
}
void
-dwarf2_directive_loc (dummy)
- int dummy ATTRIBUTE_UNUSED;
+dwarf2_directive_loc (int dummy ATTRIBUTE_UNUSED)
{
offsetT filenum, line, column;
@@ -430,20 +497,32 @@ dwarf2_directive_loc (dummy)
current.column = column;
current.flags = DWARF2_FLAG_BEGIN_STMT;
- loc_directive_seen = true;
+ loc_directive_seen = TRUE;
#ifndef NO_LISTING
if (listing)
{
- listing_source_file (files[filenum].filename);
+ if (files[filenum].dir)
+ {
+ size_t dir_len = strlen (dirs[files[filenum].dir]);
+ size_t file_len = strlen (files[filenum].filename);
+ char *cp = (char *) alloca (dir_len + 1 + file_len + 1);
+
+ memcpy (cp, dirs[files[filenum].dir], dir_len);
+ cp[dir_len] = '/';
+ memcpy (cp + dir_len + 1, files[filenum].filename, file_len);
+ cp[dir_len + file_len + 1] = '\0';
+ listing_source_file (cp);
+ }
+ else
+ listing_source_file (files[filenum].filename);
listing_source_line (line);
}
#endif
}
static struct frag *
-first_frag_for_seg (seg)
- segT seg;
+first_frag_for_seg (segT seg)
{
frchainS *f, *first = NULL;
@@ -456,8 +535,7 @@ first_frag_for_seg (seg)
}
static struct frag *
-last_frag_for_seg (seg)
- segT seg;
+last_frag_for_seg (segT seg)
{
frchainS *f, *last = NULL;
@@ -472,8 +550,7 @@ last_frag_for_seg (seg)
/* Emit a single byte into the current segment. */
static inline void
-out_byte (byte)
- int byte;
+out_byte (int byte)
{
FRAG_APPEND_1_CHAR (byte);
}
@@ -481,8 +558,7 @@ out_byte (byte)
/* Emit a statement program opcode into the current segment. */
static inline void
-out_opcode (opc)
- int opc;
+out_opcode (int opc)
{
out_byte (opc);
}
@@ -490,8 +566,7 @@ out_opcode (opc)
/* Emit a two-byte word into the current segment. */
static inline void
-out_two (data)
- int data;
+out_two (int data)
{
md_number_to_chars (frag_more (2), data, 2);
}
@@ -499,8 +574,7 @@ out_two (data)
/* Emit a four byte word into the current segment. */
static inline void
-out_four (data)
- int data;
+out_four (int data)
{
md_number_to_chars (frag_more (4), data, 4);
}
@@ -508,8 +582,7 @@ out_four (data)
/* Emit an unsigned "little-endian base 128" number. */
static void
-out_uleb128 (value)
- addressT value;
+out_uleb128 (addressT value)
{
output_leb128 (frag_more (sizeof_leb128 (value, 0)), value, 0);
}
@@ -517,37 +590,16 @@ out_uleb128 (value)
/* Emit a tuple for .debug_abbrev. */
static inline void
-out_abbrev (name, form)
- int name, form;
+out_abbrev (int name, int form)
{
out_uleb128 (name);
out_uleb128 (form);
}
-/* Create a new fake symbol whose value is the current position. */
-
-static symbolS *
-symbol_new_now ()
-{
- return symbol_new (fake_label_name, now_seg, frag_now_fix (), frag_now);
-}
-
-/* Set the value of SYM to the current position in the current segment. */
-
-static void
-set_symbol_value_now (sym)
- symbolS *sym;
-{
- S_SET_SEGMENT (sym, now_seg);
- S_SET_VALUE (sym, frag_now_fix ());
- symbol_set_frag (sym, frag_now);
-}
-
/* Get the size of a fragment. */
static offsetT
-get_frag_fix (frag)
- fragS *frag;
+get_frag_fix (fragS *frag)
{
frchainS *fr;
@@ -559,11 +611,7 @@ get_frag_fix (frag)
on some subsegment chain. */
for (fr = frchain_root; fr; fr = fr->frch_next)
if (fr->frch_last == frag)
- {
- long align_mask = -1 << get_recorded_alignment (fr->frch_seg);
- return (((char *) obstack_next_free (&fr->frch_obstack)
- - frag->fr_literal) + ~align_mask) & align_mask;
- }
+ return (char *) obstack_next_free (&fr->frch_obstack) - frag->fr_literal;
abort ();
}
@@ -571,15 +619,12 @@ get_frag_fix (frag)
/* Set an absolute address (may result in a relocation entry). */
static void
-out_set_addr (seg, frag, ofs)
- segT seg;
- fragS *frag;
- addressT ofs;
+out_set_addr (segT seg, fragS *frag, addressT ofs)
{
expressionS expr;
symbolS *sym;
- sym = symbol_new (fake_label_name, seg, ofs, frag);
+ sym = symbol_temp_new (seg, ofs, frag);
out_opcode (DW_LNS_extended_op);
out_uleb128 (sizeof_address + 1);
@@ -591,6 +636,25 @@ out_set_addr (seg, frag, ofs)
emit_expr (&expr, sizeof_address);
}
+#if DWARF2_LINE_MIN_INSN_LENGTH > 1
+static void scale_addr_delta (addressT *);
+
+static void
+scale_addr_delta (addressT *addr_delta)
+{
+ static int printed_this = 0;
+ if (*addr_delta % DWARF2_LINE_MIN_INSN_LENGTH != 0)
+ {
+ if (!printed_this)
+ as_bad("unaligned opcodes detected in executable segment");
+ printed_this = 1;
+ }
+ *addr_delta /= DWARF2_LINE_MIN_INSN_LENGTH;
+}
+#else
+#define scale_addr_delta(A)
+#endif
+
/* Encode a pair of line and address skips as efficiently as possible.
Note that the line skip is signed, whereas the address skip is unsigned.
@@ -599,18 +663,13 @@ out_set_addr (seg, frag, ofs)
exactly the expected number of bytes. */
static int
-size_inc_line_addr (line_delta, addr_delta)
- int line_delta;
- addressT addr_delta;
+size_inc_line_addr (int line_delta, addressT addr_delta)
{
unsigned int tmp, opcode;
int len = 0;
/* Scale the address delta by the minimum instruction length. */
-#if DWARF2_LINE_MIN_INSN_LENGTH > 1
- assert (addr_delta % DWARF2_LINE_MIN_INSN_LENGTH == 0);
- addr_delta /= DWARF2_LINE_MIN_INSN_LENGTH;
-#endif
+ scale_addr_delta (&addr_delta);
/* INT_MAX is a signal that this is actually a DW_LNE_end_sequence.
We cannot use special opcodes here, since we want the end_sequence
@@ -663,21 +722,15 @@ size_inc_line_addr (line_delta, addr_delta)
}
static void
-emit_inc_line_addr (line_delta, addr_delta, p, len)
- int line_delta;
- addressT addr_delta;
- char *p;
- int len;
+emit_inc_line_addr (int line_delta, addressT addr_delta, char *p, int len)
{
unsigned int tmp, opcode;
int need_copy = 0;
char *end = p + len;
-#if DWARF2_LINE_MIN_INSN_LENGTH > 1
/* Scale the address delta by the minimum instruction length. */
- assert (addr_delta % DWARF2_LINE_MIN_INSN_LENGTH == 0);
- addr_delta /= DWARF2_LINE_MIN_INSN_LENGTH;
-#endif
+ scale_addr_delta (&addr_delta);
+
/* INT_MAX is a signal that this is actually a DW_LNE_end_sequence.
We cannot use special opcodes here, since we want the end_sequence
to emit the matrix entry. */
@@ -760,9 +813,7 @@ emit_inc_line_addr (line_delta, addr_delta, p, len)
/* Handy routine to combine calls to the above two routines. */
static void
-out_inc_line_addr (line_delta, addr_delta)
- int line_delta;
- addressT addr_delta;
+out_inc_line_addr (int line_delta, addressT addr_delta)
{
int len = size_inc_line_addr (line_delta, addr_delta);
emit_inc_line_addr (line_delta, addr_delta, frag_more (len), len);
@@ -772,18 +823,16 @@ out_inc_line_addr (line_delta, addr_delta)
increments between fragments of the target segment. */
static void
-relax_inc_line_addr (line_delta, seg, to_frag, to_ofs, from_frag, from_ofs)
- int line_delta;
- segT seg;
- fragS *to_frag, *from_frag;
- addressT to_ofs, from_ofs;
+relax_inc_line_addr (int line_delta, segT seg,
+ fragS *to_frag, addressT to_ofs,
+ fragS *from_frag, addressT from_ofs)
{
symbolS *to_sym, *from_sym;
expressionS expr;
int max_chars;
- to_sym = symbol_new (fake_label_name, seg, to_ofs, to_frag);
- from_sym = symbol_new (fake_label_name, seg, from_ofs, from_frag);
+ to_sym = symbol_temp_new (seg, to_ofs, to_frag);
+ from_sym = symbol_temp_new (seg, from_ofs, from_frag);
expr.X_op = O_subtract;
expr.X_add_symbol = to_sym;
@@ -803,8 +852,7 @@ relax_inc_line_addr (line_delta, seg, to_frag, to_ofs, from_frag, from_ofs)
the relaxation loop. We set fr_subtype to the expected length. */
int
-dwarf2dbg_estimate_size_before_relax (frag)
- fragS *frag;
+dwarf2dbg_estimate_size_before_relax (fragS *frag)
{
offsetT addr_delta;
int size;
@@ -822,8 +870,7 @@ dwarf2dbg_estimate_size_before_relax (frag)
of the frag. This returns the change in frag length. */
int
-dwarf2dbg_relax_frag (frag)
- fragS *frag;
+dwarf2dbg_relax_frag (fragS *frag)
{
int old_size, new_size;
@@ -838,8 +885,7 @@ dwarf2dbg_relax_frag (frag)
fr_subtype will be the desired length of the frag. */
void
-dwarf2dbg_convert_frag (frag)
- fragS *frag;
+dwarf2dbg_convert_frag (fragS *frag)
{
offsetT addr_diff;
@@ -863,9 +909,7 @@ dwarf2dbg_convert_frag (frag)
beginning at E, for segment SEG. */
static void
-process_entries (seg, e)
- segT seg;
- struct line_entry *e;
+process_entries (segT seg, struct line_entry *e)
{
unsigned filenum = 1;
unsigned line = 1;
@@ -957,13 +1001,20 @@ process_entries (seg, e)
/* Emit the directory and file tables for .debug_line. */
static void
-out_file_list ()
+out_file_list (void)
{
size_t size;
char *cp;
unsigned int i;
- /* Terminate directory list. */
+ /* Emit directory list. */
+ for (i = 1; i < dirs_in_use; ++i)
+ {
+ size = strlen (dirs[i]) + 1;
+ cp = frag_more (size);
+ memcpy (cp, dirs[i], size);
+ }
+ /* Terminate it. */
out_byte ('\0');
for (i = 1; i < files_in_use; ++i)
@@ -971,6 +1022,8 @@ out_file_list ()
if (files[i].filename == NULL)
{
as_bad (_("unassigned file number %ld"), (long) i);
+ /* Prevent a crash later, particularly for file 1. */
+ files[i].filename = "";
continue;
}
@@ -990,27 +1043,51 @@ out_file_list ()
/* Emit the collected .debug_line data. */
static void
-out_debug_line (line_seg)
- segT line_seg;
+out_debug_line (segT line_seg)
{
expressionS expr;
symbolS *line_start;
symbolS *prologue_end;
symbolS *line_end;
struct line_seg *s;
+ enum dwarf2_format d2f;
+ int sizeof_offset;
subseg_set (line_seg, 0);
- line_start = symbol_new_now ();
- prologue_end = symbol_make (fake_label_name);
- line_end = symbol_make (fake_label_name);
+ line_start = symbol_temp_new_now ();
+ prologue_end = symbol_temp_make ();
+ line_end = symbol_temp_make ();
/* Total length of the information for this compilation unit. */
expr.X_op = O_subtract;
expr.X_add_symbol = line_end;
expr.X_op_symbol = line_start;
- expr.X_add_number = -4;
- emit_expr (&expr, 4);
+
+ d2f = DWARF2_FORMAT ();
+ if (d2f == dwarf2_format_32bit)
+ {
+ expr.X_add_number = -4;
+ emit_expr (&expr, 4);
+ sizeof_offset = 4;
+ }
+ else if (d2f == dwarf2_format_64bit)
+ {
+ expr.X_add_number = -12;
+ out_four (-1);
+ emit_expr (&expr, 8);
+ sizeof_offset = 8;
+ }
+ else if (d2f == dwarf2_format_64bit_irix)
+ {
+ expr.X_add_number = -8;
+ emit_expr (&expr, 8);
+ sizeof_offset = 8;
+ }
+ else
+ {
+ as_fatal (_("internal error: unknown dwarf2 format"));
+ }
/* Version. */
out_two (2);
@@ -1020,7 +1097,7 @@ out_debug_line (line_seg)
expr.X_add_symbol = prologue_end;
expr.X_op_symbol = line_start;
expr.X_add_number = - (4 + 2 + 4);
- emit_expr (&expr, 4);
+ emit_expr (&expr, sizeof_offset);
/* Parameters of the state machine. */
out_byte (DWARF2_LINE_MIN_INSN_LENGTH);
@@ -1042,21 +1119,19 @@ out_debug_line (line_seg)
out_file_list ();
- set_symbol_value_now (prologue_end);
+ symbol_set_value_now (prologue_end);
/* For each section, emit a statement program. */
for (s = all_segs; s; s = s->next)
process_entries (s->seg, s->head->head);
- set_symbol_value_now (line_end);
+ symbol_set_value_now (line_end);
}
/* Emit data for .debug_aranges. */
static void
-out_debug_aranges (aranges_seg, info_seg)
- segT aranges_seg;
- segT info_seg;
+out_debug_aranges (segT aranges_seg, segT info_seg)
{
unsigned int addr_size = sizeof_address;
addressT size, skip;
@@ -1085,10 +1160,8 @@ out_debug_aranges (aranges_seg, info_seg)
out_two (2);
/* Offset to .debug_info. */
- expr.X_op = O_symbol;
- expr.X_add_symbol = section_symbol (info_seg);
- expr.X_add_number = 0;
- emit_expr (&expr, 4);
+ /* ??? sizeof_offset */
+ TC_DWARF2_EMIT_OFFSET (section_symbol (info_seg), 4);
/* Size of an address (offset portion). */
out_byte (addr_size);
@@ -1106,11 +1179,11 @@ out_debug_aranges (aranges_seg, info_seg)
symbolS *beg, *end;
frag = first_frag_for_seg (s->seg);
- beg = symbol_new (fake_label_name, s->seg, 0, frag);
+ beg = symbol_temp_new (s->seg, 0, frag);
s->text_start = beg;
frag = last_frag_for_seg (s->seg);
- end = symbol_new (fake_label_name, s->seg, get_frag_fix (frag), frag);
+ end = symbol_temp_new (s->seg, get_frag_fix (frag), frag);
s->text_end = end;
expr.X_op = O_symbol;
@@ -1134,8 +1207,7 @@ out_debug_aranges (aranges_seg, info_seg)
sync with out_debug_info below. */
static void
-out_debug_abbrev (abbrev_seg)
- segT abbrev_seg;
+out_debug_abbrev (segT abbrev_seg)
{
subseg_set (abbrev_seg, 0);
@@ -1161,10 +1233,7 @@ out_debug_abbrev (abbrev_seg)
/* Emit a description of this compilation unit for .debug_info. */
static void
-out_debug_info (info_seg, abbrev_seg, line_seg)
- segT info_seg;
- segT abbrev_seg;
- segT line_seg;
+out_debug_info (segT info_seg, segT abbrev_seg, segT line_seg)
{
char producer[128];
char *comp_dir;
@@ -1173,27 +1242,49 @@ out_debug_info (info_seg, abbrev_seg, line_seg)
symbolS *info_end;
char *p;
int len;
+ enum dwarf2_format d2f;
+ int sizeof_offset;
subseg_set (info_seg, 0);
- info_start = symbol_new_now ();
- info_end = symbol_make (fake_label_name);
+ info_start = symbol_temp_new_now ();
+ info_end = symbol_temp_make ();
/* Compilation Unit length. */
expr.X_op = O_subtract;
expr.X_add_symbol = info_end;
expr.X_op_symbol = info_start;
- expr.X_add_number = -4;
- emit_expr (&expr, 4);
+
+ d2f = DWARF2_FORMAT ();
+ if (d2f == dwarf2_format_32bit)
+ {
+ expr.X_add_number = -4;
+ emit_expr (&expr, 4);
+ sizeof_offset = 4;
+ }
+ else if (d2f == dwarf2_format_64bit)
+ {
+ expr.X_add_number = -12;
+ out_four (-1);
+ emit_expr (&expr, 8);
+ sizeof_offset = 8;
+ }
+ else if (d2f == dwarf2_format_64bit_irix)
+ {
+ expr.X_add_number = -8;
+ emit_expr (&expr, 8);
+ sizeof_offset = 8;
+ }
+ else
+ {
+ as_fatal (_("internal error: unknown dwarf2 format"));
+ }
/* DWARF version. */
out_two (2);
/* .debug_abbrev offset */
- expr.X_op = O_symbol;
- expr.X_add_symbol = section_symbol (abbrev_seg);
- expr.X_add_number = 0;
- emit_expr (&expr, 4);
+ TC_DWARF2_EMIT_OFFSET (section_symbol (abbrev_seg), sizeof_offset);
/* Target address size. */
out_byte (sizeof_address);
@@ -1202,10 +1293,8 @@ out_debug_info (info_seg, abbrev_seg, line_seg)
out_uleb128 (1);
/* DW_AT_stmt_list */
- expr.X_op = O_symbol;
- expr.X_add_symbol = section_symbol (line_seg);
- expr.X_add_number = 0;
- emit_expr (&expr, 4);
+ /* ??? sizeof_offset */
+ TC_DWARF2_EMIT_OFFSET (section_symbol (line_seg), 4);
/* These two attributes may only be emitted if all of the code is
contiguous. Multiple sections are not that. */
@@ -1230,6 +1319,13 @@ out_debug_info (info_seg, abbrev_seg, line_seg)
entry was emitted, so this should always be defined. */
if (!files || files_in_use < 1)
abort ();
+ if (files[1].dir)
+ {
+ len = strlen (dirs[files[1].dir]);
+ p = frag_more (len + 1);
+ memcpy (p, dirs[files[1].dir], len);
+ p[len] = '/';
+ }
len = strlen (files[1].filename) + 1;
p = frag_more (len);
memcpy (p, files[1].filename, len);
@@ -1250,11 +1346,11 @@ out_debug_info (info_seg, abbrev_seg, line_seg)
dwarf2 draft has no standard code for assembler. */
out_two (DW_LANG_Mips_Assembler);
- set_symbol_value_now (info_end);
+ symbol_set_value_now (info_end);
}
void
-dwarf2_finish ()
+dwarf2_finish (void)
{
segT line_seg;
struct line_seg *s;
@@ -1271,7 +1367,7 @@ dwarf2_finish ()
return;
/* Calculate the size of an address for the target machine. */
- sizeof_address = bfd_arch_bits_per_address (stdoutput) / 8;
+ sizeof_address = DWARF2_ADDR_SIZE (stdoutput);
/* Create and switch to the line number section. */
line_seg = subseg_new (".debug_line", 0);
@@ -1351,11 +1447,12 @@ dwarf2_emit_insn (size)
{
}
-void
+char *
dwarf2_directive_file (dummy)
int dummy ATTRIBUTE_UNUSED;
{
s_app_file (0);
+ return NULL;
}
void
diff --git a/contrib/binutils/gas/dwarf2dbg.h b/contrib/binutils/gas/dwarf2dbg.h
index 62fc020..fe8bf27 100644
--- a/contrib/binutils/gas/dwarf2dbg.h
+++ b/contrib/binutils/gas/dwarf2dbg.h
@@ -36,7 +36,7 @@ struct dwarf2_line_info {
/* Implements the .file FILENO "FILENAME" directive. FILENO can be 0
to indicate that no file number has been assigned. All real file
number must be >0. */
-extern char *dwarf2_directive_file PARAMS ((int dummy));
+extern char *dwarf2_directive_file (int dummy);
/* Implements the .loc FILENO LINENO [COLUMN] directive. FILENO is
the file number, LINENO the line number and the (optional) COLUMN
@@ -44,29 +44,41 @@ extern char *dwarf2_directive_file PARAMS ((int dummy));
corresponds to. FILENO can be 0 to indicate that the filename
specified by the textually most recent .file directive should be
used. */
-extern void dwarf2_directive_loc PARAMS ((int dummy));
+extern void dwarf2_directive_loc (int dummy);
/* Returns the current source information. If .file directives have
been encountered, the info for the corresponding source file is
returned. Otherwise, the info for the assembly source file is
returned. */
-extern void dwarf2_where PARAMS ((struct dwarf2_line_info *l));
+extern void dwarf2_where (struct dwarf2_line_info *l);
/* This function generates .debug_line info based on the address and
source information passed in the arguments. ADDR should be the
frag-relative offset of the instruction the information is for and
L is the source information that should be associated with that
address. */
-extern void dwarf2_gen_line_info PARAMS ((addressT addr,
- struct dwarf2_line_info *l));
+extern void dwarf2_gen_line_info (addressT addr, struct dwarf2_line_info *l);
/* Must be called for each generated instruction. */
-extern void dwarf2_emit_insn PARAMS ((int));
-
-extern void dwarf2_finish PARAMS ((void));
-
-extern int dwarf2dbg_estimate_size_before_relax PARAMS ((fragS *));
-extern int dwarf2dbg_relax_frag PARAMS ((fragS *));
-extern void dwarf2dbg_convert_frag PARAMS ((fragS *));
+extern void dwarf2_emit_insn (int);
+
+extern void dwarf2_finish (void);
+
+extern int dwarf2dbg_estimate_size_before_relax (fragS *);
+extern int dwarf2dbg_relax_frag (fragS *);
+extern void dwarf2dbg_convert_frag (fragS *);
+
+/* An enumeration which describes the sizes of offsets (to DWARF sections)
+ and the mechanism by which the size is indicated. */
+enum dwarf2_format {
+ /* 32-bit format: the initial length field is 4 bytes long. */
+ dwarf2_format_32bit,
+ /* DWARF3 64-bit format: the representation of the initial length
+ (of a DWARF section) is 0xffffffff (4 bytes) followed by eight
+ bytes indicating the actual length. */
+ dwarf2_format_64bit,
+ /* SGI extension to DWARF2: The initial length is eight bytes. */
+ dwarf2_format_64bit_irix
+};
#endif /* AS_DWARF2DBG_H */
diff --git a/contrib/binutils/gas/ecoff.c b/contrib/binutils/gas/ecoff.c
index 75e0479..1de823e 100644
--- a/contrib/binutils/gas/ecoff.c
+++ b/contrib/binutils/gas/ecoff.c
@@ -1408,76 +1408,74 @@ static char stabs_symbol[] = STABS_SYMBOL;
/* Prototypes for functions defined in this file. */
-static void add_varray_page PARAMS ((varray_t *vp));
-static symint_t add_string PARAMS ((varray_t *vp,
- struct hash_control *hash_tbl,
- const char *str,
- shash_t **ret_hash));
-static localsym_t *add_ecoff_symbol PARAMS ((const char *str, st_t type,
- sc_t storage, symbolS *sym,
- bfd_vma addend, symint_t value,
- symint_t indx));
-static symint_t add_aux_sym_symint PARAMS ((symint_t aux_word));
-static symint_t add_aux_sym_rndx PARAMS ((int file_index,
- symint_t sym_index));
-static symint_t add_aux_sym_tir PARAMS ((type_info_t *t,
- hash_state_t state,
- thash_t **hash_tbl));
-static tag_t *get_tag PARAMS ((const char *tag, localsym_t *sym,
- bt_t basic_type));
-static void add_unknown_tag PARAMS ((tag_t *ptag));
-static void add_procedure PARAMS ((char *func));
-static void add_file PARAMS ((const char *file_name, int indx, int fake));
+static void add_varray_page (varray_t *vp);
+static symint_t add_string (varray_t *vp,
+ struct hash_control *hash_tbl,
+ const char *str,
+ shash_t **ret_hash);
+static localsym_t *add_ecoff_symbol (const char *str, st_t type,
+ sc_t storage, symbolS *sym,
+ bfd_vma addend, symint_t value,
+ symint_t indx);
+static symint_t add_aux_sym_symint (symint_t aux_word);
+static symint_t add_aux_sym_rndx (int file_index, symint_t sym_index);
+static symint_t add_aux_sym_tir (type_info_t *t,
+ hash_state_t state,
+ thash_t **hash_tbl);
+static tag_t *get_tag (const char *tag, localsym_t *sym, bt_t basic_type);
+static void add_unknown_tag (tag_t *ptag);
+static void add_procedure (char *func);
+static void add_file (const char *file_name, int indx, int fake);
#ifdef ECOFF_DEBUG
-static char *sc_to_string PARAMS ((sc_t storage_class));
-static char *st_to_string PARAMS ((st_t symbol_type));
+static char *sc_to_string (sc_t storage_class);
+static char *st_to_string (st_t symbol_type);
#endif
-static void mark_stabs PARAMS ((int));
-static char *ecoff_add_bytes PARAMS ((char **buf, char **bufend,
- char *bufptr, unsigned long need));
+static void mark_stabs (int);
+static char *ecoff_add_bytes (char **buf, char **bufend,
+ char *bufptr, unsigned long need);
static unsigned long ecoff_padding_adjust
- PARAMS ((const struct ecoff_debug_swap *backend, char **buf, char **bufend,
- unsigned long offset, char **bufptrptr));
+ (const struct ecoff_debug_swap *backend, char **buf, char **bufend,
+ unsigned long offset, char **bufptrptr);
static unsigned long ecoff_build_lineno
- PARAMS ((const struct ecoff_debug_swap *backend, char **buf, char **bufend,
- unsigned long offset, long *linecntptr));
+ (const struct ecoff_debug_swap *backend, char **buf, char **bufend,
+ unsigned long offset, long *linecntptr);
static unsigned long ecoff_build_symbols
- PARAMS ((const struct ecoff_debug_swap *backend, char **buf, char **bufend,
- unsigned long offset));
+ (const struct ecoff_debug_swap *backend, char **buf, char **bufend,
+ unsigned long offset);
static unsigned long ecoff_build_procs
- PARAMS ((const struct ecoff_debug_swap *backend, char **buf, char **bufend,
- unsigned long offset));
+ (const struct ecoff_debug_swap *backend, char **buf, char **bufend,
+ unsigned long offset);
static unsigned long ecoff_build_aux
- PARAMS ((const struct ecoff_debug_swap *backend, char **buf, char **bufend,
- unsigned long offset));
-static unsigned long ecoff_build_strings PARAMS ((char **buf, char **bufend,
- unsigned long offset,
- varray_t *vp));
+ (const struct ecoff_debug_swap *backend, char **buf, char **bufend,
+ unsigned long offset);
+static unsigned long ecoff_build_strings (char **buf, char **bufend,
+ unsigned long offset,
+ varray_t *vp);
static unsigned long ecoff_build_ss
- PARAMS ((const struct ecoff_debug_swap *backend, char **buf, char **bufend,
- unsigned long offset));
+ (const struct ecoff_debug_swap *backend, char **buf, char **bufend,
+ unsigned long offset);
static unsigned long ecoff_build_fdr
- PARAMS ((const struct ecoff_debug_swap *backend, char **buf, char **bufend,
- unsigned long offset));
-static void ecoff_setup_ext PARAMS ((void));
-static page_type *allocate_cluster PARAMS ((unsigned long npages));
-static page_type *allocate_page PARAMS ((void));
-static scope_t *allocate_scope PARAMS ((void));
-static void free_scope PARAMS ((scope_t *ptr));
-static vlinks_t *allocate_vlinks PARAMS ((void));
-static shash_t *allocate_shash PARAMS ((void));
-static thash_t *allocate_thash PARAMS ((void));
-static tag_t *allocate_tag PARAMS ((void));
-static void free_tag PARAMS ((tag_t *ptr));
-static forward_t *allocate_forward PARAMS ((void));
-static thead_t *allocate_thead PARAMS ((void));
-static void free_thead PARAMS ((thead_t *ptr));
-static lineno_list_t *allocate_lineno_list PARAMS ((void));
+ (const struct ecoff_debug_swap *backend, char **buf, char **bufend,
+ unsigned long offset);
+static void ecoff_setup_ext (void);
+static page_type *allocate_cluster (unsigned long npages);
+static page_type *allocate_page (void);
+static scope_t *allocate_scope (void);
+static void free_scope (scope_t *ptr);
+static vlinks_t *allocate_vlinks (void);
+static shash_t *allocate_shash (void);
+static thash_t *allocate_thash (void);
+static tag_t *allocate_tag (void);
+static void free_tag (tag_t *ptr);
+static forward_t *allocate_forward (void);
+static thead_t *allocate_thead (void);
+static void free_thead (thead_t *ptr);
+static lineno_list_t *allocate_lineno_list (void);
/* This function should be called when the assembler starts up. */
void
-ecoff_read_begin_hook ()
+ecoff_read_begin_hook (void)
{
tag_hash = hash_new ();
top_tag_head = allocate_thead ();
@@ -1490,8 +1488,7 @@ ecoff_read_begin_hook ()
/* This function should be called when a symbol is created. */
void
-ecoff_symbol_new_hook (symbolP)
- symbolS *symbolP;
+ecoff_symbol_new_hook (symbolS *symbolP)
{
OBJ_SYMFIELD_TYPE *obj;
@@ -1512,8 +1509,7 @@ ecoff_symbol_new_hook (symbolP)
/* Add a page to a varray object. */
static void
-add_varray_page (vp)
- varray_t *vp; /* varray to add page to */
+add_varray_page (varray_t *vp /* varray to add page to */)
{
vlinks_t *new_links = allocate_vlinks ();
@@ -1543,11 +1539,10 @@ add_varray_page (vp)
/* Add a string (and null pad) to one of the string tables. */
static symint_t
-add_string (vp, hash_tbl, str, ret_hash)
- varray_t *vp; /* string obstack */
- struct hash_control *hash_tbl; /* ptr to hash table */
- const char *str; /* string */
- shash_t **ret_hash; /* return hash pointer */
+add_string (varray_t *vp, /* string obstack */
+ struct hash_control *hash_tbl, /* ptr to hash table */
+ const char *str, /* string */
+ shash_t **ret_hash /* return hash pointer */)
{
register unsigned long len = strlen (str);
register shash_t *hash_ptr;
@@ -1592,14 +1587,13 @@ add_string (vp, hash_tbl, str, ret_hash)
/* Add debugging information for a symbol. */
static localsym_t *
-add_ecoff_symbol (str, type, storage, sym_value, addend, value, indx)
- const char *str; /* symbol name */
- st_t type; /* symbol type */
- sc_t storage; /* storage class */
- symbolS *sym_value; /* associated symbol. */
- bfd_vma addend; /* addend to sym_value. */
- symint_t value; /* value of symbol */
- symint_t indx; /* index to local/aux. syms */
+add_ecoff_symbol (const char *str, /* symbol name */
+ st_t type, /* symbol type */
+ sc_t storage, /* storage class */
+ symbolS *sym_value, /* associated symbol. */
+ bfd_vma addend, /* addend to sym_value. */
+ symint_t value, /* value of symbol */
+ symint_t indx /* index to local/aux. syms */)
{
localsym_t *psym;
register scope_t *pscope;
@@ -1798,8 +1792,7 @@ add_ecoff_symbol (str, type, storage, sym_value, addend, value, indx)
for integral aux types, not just symints. */
static symint_t
-add_aux_sym_symint (aux_word)
- symint_t aux_word; /* auxiliary information word */
+add_aux_sym_symint (symint_t aux_word /* auxiliary information word */)
{
register varray_t *vp;
register aux_t *aux_ptr;
@@ -1822,9 +1815,7 @@ add_aux_sym_symint (aux_word)
/* Add an auxiliary symbol (passing a file/symbol index combo). */
static symint_t
-add_aux_sym_rndx (file_index, sym_index)
- int file_index;
- symint_t sym_index;
+add_aux_sym_rndx (int file_index, symint_t sym_index)
{
register varray_t *vp;
register aux_t *aux_ptr;
@@ -1849,10 +1840,9 @@ add_aux_sym_rndx (file_index, sym_index)
type qualifiers). */
static symint_t
-add_aux_sym_tir (t, state, hash_tbl)
- type_info_t *t; /* current type information */
- hash_state_t state; /* whether to hash type or not */
- thash_t **hash_tbl; /* pointer to hash table to use */
+add_aux_sym_tir (type_info_t *t, /* current type information */
+ hash_state_t state, /* whether to hash type or not */
+ thash_t **hash_tbl /* pointer to hash table to use */)
{
register varray_t *vp;
register aux_t *aux_ptr;
@@ -2006,10 +1996,9 @@ add_aux_sym_tir (t, state, hash_tbl)
/* Add a tag to the tag table (unless it already exists). */
static tag_t *
-get_tag (tag, sym, basic_type)
- const char *tag; /* tag name */
- localsym_t *sym; /* tag start block */
- bt_t basic_type; /* bt_Struct, bt_Union, or bt_Enum */
+get_tag (const char *tag, /* tag name */
+ localsym_t *sym, /* tag start block */
+ bt_t basic_type /* bt_Struct, bt_Union, or bt_Enum */)
{
shash_t *hash_ptr;
const char *err;
@@ -2066,8 +2055,7 @@ get_tag (tag, sym, basic_type)
/* Add an unknown {struct, union, enum} tag. */
static void
-add_unknown_tag (ptag)
- tag_t *ptag; /* pointer to tag information */
+add_unknown_tag (tag_t *ptag /* pointer to tag information */)
{
shash_t *hash_ptr = ptag->hash_ptr;
char *name = hash_ptr->string;
@@ -2116,8 +2104,7 @@ add_unknown_tag (ptag)
this is the current procedure. */
static void
-add_procedure (func)
- char *func; /* func name */
+add_procedure (char *func /* func name */)
{
register varray_t *vp;
register proc_t *new_proc_ptr;
@@ -2177,7 +2164,7 @@ add_procedure (func)
}
symbolS *
-ecoff_get_cur_proc_sym ()
+ecoff_get_cur_proc_sym (void)
{
return (cur_proc_ptr ? cur_proc_ptr->sym->as_sym : NULL);
}
@@ -2187,10 +2174,7 @@ ecoff_get_cur_proc_sym ()
where the current file structure lives. */
static void
-add_file (file_name, indx, fake)
- const char *file_name; /* file name */
- int indx ATTRIBUTE_UNUSED;
- int fake;
+add_file (const char *file_name, int indx ATTRIBUTE_UNUSED, int fake)
{
register int first_ch;
register efdr_t *fil_ptr;
@@ -2328,8 +2312,7 @@ add_file (file_name, indx, fake)
compiler output, only in hand coded assembler. */
void
-ecoff_new_file (name)
- const char *name;
+ecoff_new_file (const char *name)
{
if (cur_file_ptr != NULL && strcmp (cur_file_ptr->name, name) == 0)
return;
@@ -2424,8 +2407,7 @@ st_to_string (symbol_type)
which gives the location of the start of the block. */
void
-ecoff_directive_begin (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_begin (int ignore ATTRIBUTE_UNUSED)
{
char *name;
char name_end;
@@ -2462,8 +2444,7 @@ ecoff_directive_begin (ignore)
which gives the location of the end of the block. */
void
-ecoff_directive_bend (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_bend (int ignore ATTRIBUTE_UNUSED)
{
char *name;
char name_end;
@@ -2521,8 +2502,7 @@ static int coff_inside_enumeration;
/* Handle a .def directive: start defining a symbol. */
void
-ecoff_directive_def (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_def (int ignore ATTRIBUTE_UNUSED)
{
char *name;
char name_end;
@@ -2567,8 +2547,7 @@ ecoff_directive_def (ignore)
more than that anyhow, so I will also make that assumption. */
void
-ecoff_directive_dim (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_dim (int ignore ATTRIBUTE_UNUSED)
{
int dimens[N_TQ];
int i;
@@ -2617,8 +2596,7 @@ ecoff_directive_dim (ignore)
symbol. */
void
-ecoff_directive_scl (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_scl (int ignore ATTRIBUTE_UNUSED)
{
long val;
@@ -2642,8 +2620,7 @@ ecoff_directive_scl (ignore)
never generate more than one argument. */
void
-ecoff_directive_size (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_size (int ignore ATTRIBUTE_UNUSED)
{
int sizes[N_TQ];
int i;
@@ -2692,8 +2669,7 @@ ecoff_directive_size (ignore)
symbol. */
void
-ecoff_directive_type (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_type (int ignore ATTRIBUTE_UNUSED)
{
long val;
tq_t *tq_ptr;
@@ -2761,8 +2737,7 @@ ecoff_directive_type (ignore)
union or enum. */
void
-ecoff_directive_tag (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_tag (int ignore ATTRIBUTE_UNUSED)
{
char *name;
char name_end;
@@ -2788,8 +2763,7 @@ ecoff_directive_tag (ignore)
may be the name of a static or global symbol. */
void
-ecoff_directive_val (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_val (int ignore ATTRIBUTE_UNUSED)
{
expressionS exp;
@@ -2823,8 +2797,7 @@ ecoff_directive_val (ignore)
debugging information for a symbol. */
void
-ecoff_directive_endef (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_endef (int ignore ATTRIBUTE_UNUSED)
{
char *name;
symint_t indx;
@@ -2890,7 +2863,7 @@ ecoff_directive_endef (ignore)
else if (coff_symbol_typ == st_Member
&& coff_type.num_sizes - coff_type.extra_sizes == 1)
{
- /* Is this a bitfield? This is indicated by a structure memeber
+ /* Is this a bitfield? This is indicated by a structure member
having a size field that isn't an array. */
coff_type.bitfield = 1;
}
@@ -3003,8 +2976,7 @@ ecoff_directive_endef (ignore)
/* Parse .end directives. */
void
-ecoff_directive_end (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_end (int ignore ATTRIBUTE_UNUSED)
{
char *name;
char name_end;
@@ -3058,8 +3030,7 @@ ecoff_directive_end (ignore)
/* Parse .ent directives. */
void
-ecoff_directive_ent (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_ent (int ignore ATTRIBUTE_UNUSED)
{
char *name;
char name_end;
@@ -3109,8 +3080,7 @@ ecoff_directive_ent (ignore)
/* Parse .extern directives. */
void
-ecoff_directive_extern (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_extern (int ignore ATTRIBUTE_UNUSED)
{
char *name;
int c;
@@ -3134,8 +3104,7 @@ ecoff_directive_extern (ignore)
/* Parse .file directives. */
void
-ecoff_directive_file (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_file (int ignore ATTRIBUTE_UNUSED)
{
int indx;
char *name;
@@ -3161,8 +3130,7 @@ ecoff_directive_file (ignore)
/* Parse .fmask directives. */
void
-ecoff_directive_fmask (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_fmask (int ignore ATTRIBUTE_UNUSED)
{
long val;
@@ -3190,8 +3158,7 @@ ecoff_directive_fmask (ignore)
/* Parse .frame directives. */
void
-ecoff_directive_frame (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_frame (int ignore ATTRIBUTE_UNUSED)
{
long val;
@@ -3231,8 +3198,7 @@ ecoff_directive_frame (ignore)
/* Parse .mask directives. */
void
-ecoff_directive_mask (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_mask (int ignore ATTRIBUTE_UNUSED)
{
long val;
@@ -3260,8 +3226,7 @@ ecoff_directive_mask (ignore)
/* Parse .loc directives. */
void
-ecoff_directive_loc (ignore)
- int ignore ATTRIBUTE_UNUSED;
+ecoff_directive_loc (int ignore ATTRIBUTE_UNUSED)
{
lineno_list_t *list;
symint_t lineno;
@@ -3341,9 +3306,7 @@ ecoff_directive_loc (ignore)
information so that it points to the instruction after the nop. */
void
-ecoff_fix_loc (old_frag, old_frag_offset)
- fragS *old_frag;
- unsigned long old_frag_offset;
+ecoff_fix_loc (fragS *old_frag, unsigned long old_frag_offset)
{
if (last_lineno != NULL
&& last_lineno->frag == old_frag
@@ -3357,8 +3320,7 @@ ecoff_fix_loc (old_frag, old_frag_offset)
/* Make sure the @stabs symbol is emitted. */
static void
-mark_stabs (ignore)
- int ignore ATTRIBUTE_UNUSED;
+mark_stabs (int ignore ATTRIBUTE_UNUSED)
{
if (! stabs_seen)
{
@@ -3375,8 +3337,7 @@ mark_stabs (ignore)
#ifndef TC_MIPS
/* For TC_MIPS use the version in tc-mips.c. */
void
-ecoff_directive_weakext (ignore)
- int ignore;
+ecoff_directive_weakext (int ignore ATTRIBUTE_UNUSED)
{
char *name;
int c;
@@ -3454,13 +3415,12 @@ ecoff_directive_weakext (ignore)
value a numeric value or an address. */
void
-ecoff_stab (sec, what, string, type, other, desc)
- segT sec ATTRIBUTE_UNUSED;
- int what;
- const char *string;
- int type;
- int other;
- int desc;
+ecoff_stab (segT sec ATTRIBUTE_UNUSED,
+ int what,
+ const char *string,
+ int type,
+ int other,
+ int desc)
{
efdr_t *save_file_ptr = cur_file_ptr;
symbolS *sym;
@@ -3609,8 +3569,7 @@ ecoff_stab (sec, what, string, type, other, desc)
.scommon section rather than bfd_com_section. */
void
-ecoff_frob_symbol (sym)
- symbolS *sym;
+ecoff_frob_symbol (symbolS *sym)
{
if (S_IS_COMMON (sym)
&& S_GET_VALUE (sym) > 0
@@ -3647,11 +3606,10 @@ ecoff_frob_symbol (sym)
/* Add bytes to the symbolic information buffer. */
static char *
-ecoff_add_bytes (buf, bufend, bufptr, need)
- char **buf;
- char **bufend;
- char *bufptr;
- unsigned long need;
+ecoff_add_bytes (char **buf,
+ char **bufend,
+ char *bufptr,
+ unsigned long need)
{
unsigned long at;
unsigned long want;
@@ -3670,12 +3628,11 @@ ecoff_add_bytes (buf, bufend, bufptr, need)
for the ECOFF target debugging information. */
static unsigned long
-ecoff_padding_adjust (backend, buf, bufend, offset, bufptrptr)
- const struct ecoff_debug_swap *backend;
- char **buf;
- char **bufend;
- unsigned long offset;
- char **bufptrptr;
+ecoff_padding_adjust (const struct ecoff_debug_swap *backend,
+ char **buf,
+ char **bufend,
+ unsigned long offset,
+ char **bufptrptr)
{
bfd_size_type align;
@@ -3699,12 +3656,11 @@ ecoff_padding_adjust (backend, buf, bufend, offset, bufptrptr)
/* Build the line number information. */
static unsigned long
-ecoff_build_lineno (backend, buf, bufend, offset, linecntptr)
- const struct ecoff_debug_swap *backend;
- char **buf;
- char **bufend;
- unsigned long offset;
- long *linecntptr;
+ecoff_build_lineno (const struct ecoff_debug_swap *backend,
+ char **buf,
+ char **bufend,
+ unsigned long offset,
+ long *linecntptr)
{
char *bufptr;
register lineno_list_t *l;
@@ -3929,14 +3885,13 @@ ecoff_build_lineno (backend, buf, bufend, offset, linecntptr)
/* Build and swap out the symbols. */
static unsigned long
-ecoff_build_symbols (backend, buf, bufend, offset)
- const struct ecoff_debug_swap *backend;
- char **buf;
- char **bufend;
- unsigned long offset;
+ecoff_build_symbols (const struct ecoff_debug_swap *backend,
+ char **buf,
+ char **bufend,
+ unsigned long offset)
{
const bfd_size_type external_sym_size = backend->external_sym_size;
- void (* const swap_sym_out) PARAMS ((bfd *, const SYMR *, PTR))
+ void (* const swap_sym_out) (bfd *, const SYMR *, PTR)
= backend->swap_sym_out;
char *sym_out;
long isym;
@@ -4295,14 +4250,13 @@ ecoff_build_symbols (backend, buf, bufend, offset)
/* Swap out the procedure information. */
static unsigned long
-ecoff_build_procs (backend, buf, bufend, offset)
- const struct ecoff_debug_swap *backend;
- char **buf;
- char **bufend;
- unsigned long offset;
+ecoff_build_procs (const struct ecoff_debug_swap *backend,
+ char **buf,
+ char **bufend,
+ unsigned long offset)
{
const bfd_size_type external_pdr_size = backend->external_pdr_size;
- void (* const swap_pdr_out) PARAMS ((bfd *, const PDR *, PTR))
+ void (* const swap_pdr_out) (bfd *, const PDR *, PTR)
= backend->swap_pdr_out;
char *pdr_out;
long iproc;
@@ -4386,11 +4340,10 @@ ecoff_build_procs (backend, buf, bufend, offset)
/* Swap out the aux information. */
static unsigned long
-ecoff_build_aux (backend, buf, bufend, offset)
- const struct ecoff_debug_swap *backend;
- char **buf;
- char **bufend;
- unsigned long offset;
+ecoff_build_aux (const struct ecoff_debug_swap *backend,
+ char **buf,
+ char **bufend,
+ unsigned long offset)
{
int bigendian;
union aux_ext *aux_out;
@@ -4501,11 +4454,10 @@ ecoff_build_aux (backend, buf, bufend, offset)
bytes copied, rather than the new offset. */
static unsigned long
-ecoff_build_strings (buf, bufend, offset, vp)
- char **buf;
- char **bufend;
- unsigned long offset;
- varray_t *vp;
+ecoff_build_strings (char **buf,
+ char **bufend,
+ unsigned long offset,
+ varray_t *vp)
{
unsigned long istr;
char *str_out;
@@ -4540,11 +4492,10 @@ ecoff_build_strings (buf, bufend, offset, vp)
/* Dump out the local strings. */
static unsigned long
-ecoff_build_ss (backend, buf, bufend, offset)
- const struct ecoff_debug_swap *backend;
- char **buf;
- char **bufend;
- unsigned long offset;
+ecoff_build_ss (const struct ecoff_debug_swap *backend,
+ char **buf,
+ char **bufend,
+ unsigned long offset)
{
long iss;
vlinks_t *file_link;
@@ -4584,14 +4535,13 @@ ecoff_build_ss (backend, buf, bufend, offset)
/* Swap out the file descriptors. */
static unsigned long
-ecoff_build_fdr (backend, buf, bufend, offset)
- const struct ecoff_debug_swap *backend;
- char **buf;
- char **bufend;
- unsigned long offset;
+ecoff_build_fdr (const struct ecoff_debug_swap *backend,
+ char **buf,
+ char **bufend,
+ unsigned long offset)
{
const bfd_size_type external_fdr_size = backend->external_fdr_size;
- void (* const swap_fdr_out) PARAMS ((bfd *, const FDR *, PTR))
+ void (* const swap_fdr_out) (bfd *, const FDR *, PTR)
= backend->swap_fdr_out;
long ifile;
char *fdr_out;
@@ -4634,7 +4584,7 @@ ecoff_build_fdr (backend, buf, bufend, offset)
calls a backend function to deal with it. */
static void
-ecoff_setup_ext ()
+ecoff_setup_ext (void)
{
register symbolS *sym;
@@ -4664,10 +4614,9 @@ ecoff_setup_ext ()
/* Build the ECOFF debugging information. */
unsigned long
-ecoff_build_debug (hdr, bufp, backend)
- HDRR *hdr;
- char **bufp;
- const struct ecoff_debug_swap *backend;
+ecoff_build_debug (HDRR *hdr,
+ char **bufp,
+ const struct ecoff_debug_swap *backend)
{
const bfd_size_type external_pdr_size = backend->external_pdr_size;
tag_t *ptag;
@@ -4831,8 +4780,7 @@ ecoff_build_debug (hdr, bufp, backend)
#ifndef MALLOC_CHECK
static page_type *
-allocate_cluster (npages)
- unsigned long npages;
+allocate_cluster (unsigned long npages)
{
register page_type *value = (page_type *) xmalloc (npages * PAGE_USIZE);
@@ -4854,7 +4802,7 @@ static unsigned long pages_left = 0;
/* Allocate one page (which is initialized to 0). */
static page_type *
-allocate_page ()
+allocate_page (void)
{
#ifndef MALLOC_CHECK
@@ -4881,7 +4829,7 @@ allocate_page ()
/* Allocate scoping information. */
static scope_t *
-allocate_scope ()
+allocate_scope (void)
{
register scope_t *ptr;
static scope_t initial_scope;
@@ -4921,8 +4869,7 @@ allocate_scope ()
/* Free scoping information. */
static void
-free_scope (ptr)
- scope_t *ptr;
+free_scope (scope_t *ptr)
{
alloc_counts[(int) alloc_type_scope].total_free++;
@@ -4937,7 +4884,7 @@ free_scope (ptr)
/* Allocate links for pages in a virtual array. */
static vlinks_t *
-allocate_vlinks ()
+allocate_vlinks (void)
{
register vlinks_t *ptr;
static vlinks_t initial_vlinks;
@@ -4971,7 +4918,7 @@ allocate_vlinks ()
/* Allocate string hash buckets. */
static shash_t *
-allocate_shash ()
+allocate_shash (void)
{
register shash_t *ptr;
static shash_t initial_shash;
@@ -5005,7 +4952,7 @@ allocate_shash ()
/* Allocate type hash buckets. */
static thash_t *
-allocate_thash ()
+allocate_thash (void)
{
register thash_t *ptr;
static thash_t initial_thash;
@@ -5039,7 +4986,7 @@ allocate_thash ()
/* Allocate structure, union, or enum tag information. */
static tag_t *
-allocate_tag ()
+allocate_tag (void)
{
register tag_t *ptr;
static tag_t initial_tag;
@@ -5079,8 +5026,7 @@ allocate_tag ()
/* Free scoping information. */
static void
-free_tag (ptr)
- tag_t *ptr;
+free_tag (tag_t *ptr)
{
alloc_counts[(int) alloc_type_tag].total_free++;
@@ -5095,7 +5041,7 @@ free_tag (ptr)
/* Allocate forward reference to a yet unknown tag. */
static forward_t *
-allocate_forward ()
+allocate_forward (void)
{
register forward_t *ptr;
static forward_t initial_forward;
@@ -5129,7 +5075,7 @@ allocate_forward ()
/* Allocate head of type hash list. */
static thead_t *
-allocate_thead ()
+allocate_thead (void)
{
register thead_t *ptr;
static thead_t initial_thead;
@@ -5169,8 +5115,7 @@ allocate_thead ()
/* Free scoping information. */
static void
-free_thead (ptr)
- thead_t *ptr;
+free_thead (thead_t *ptr)
{
alloc_counts[(int) alloc_type_thead].total_free++;
@@ -5183,7 +5128,7 @@ free_thead (ptr)
}
static lineno_list_t *
-allocate_lineno_list ()
+allocate_lineno_list (void)
{
register lineno_list_t *ptr;
static lineno_list_t initial_lineno_list;
@@ -5215,8 +5160,7 @@ allocate_lineno_list ()
}
void
-ecoff_set_gp_prolog_size (sz)
- int sz;
+ecoff_set_gp_prolog_size (int sz)
{
if (cur_proc_ptr == 0)
return;
@@ -5232,13 +5176,13 @@ ecoff_set_gp_prolog_size (sz)
}
int
-ecoff_no_current_file ()
+ecoff_no_current_file (void)
{
return cur_file_ptr == (efdr_t *) NULL;
}
void
-ecoff_generate_asm_lineno ()
+ecoff_generate_asm_lineno (void)
{
unsigned int lineno;
char *filename;
@@ -5285,7 +5229,7 @@ ecoff_generate_asm_lineno ()
#else
void
-ecoff_generate_asm_lineno ()
+ecoff_generate_asm_lineno (void)
{
}
diff --git a/contrib/binutils/gas/ecoff.h b/contrib/binutils/gas/ecoff.h
index f6b96c6..2f09afc 100644
--- a/contrib/binutils/gas/ecoff.h
+++ b/contrib/binutils/gas/ecoff.h
@@ -34,18 +34,18 @@ extern int ecoff_debugging_seen;
/* This function should be called at the start of assembly, by
obj_read_begin_hook. */
-extern void ecoff_read_begin_hook PARAMS ((void));
+extern void ecoff_read_begin_hook (void);
/* This function should be called when the assembler switches to a new
file. */
-extern void ecoff_new_file PARAMS ((const char *));
+extern void ecoff_new_file (const char *);
/* This function should be called when a new symbol is created, by
obj_symbol_new_hook. */
-extern void ecoff_symbol_new_hook PARAMS ((symbolS *));
+extern void ecoff_symbol_new_hook (symbolS *);
/* This function should be called by the obj_frob_symbol hook. */
-extern void ecoff_frob_symbol PARAMS ((symbolS *));
+extern void ecoff_frob_symbol (symbolS *);
/* Build the ECOFF debugging information. This should be called by
obj_frob_file. This fills in the counts in *HDR; the offsets are
@@ -53,59 +53,59 @@ extern void ecoff_frob_symbol PARAMS ((symbolS *));
block of memory holding the debugging information. It returns the
length of *BUFP. */
extern unsigned long ecoff_build_debug
- PARAMS ((HDRR *hdr, char **bufp, const struct ecoff_debug_swap *));
+ (HDRR *hdr, char **bufp, const struct ecoff_debug_swap *);
/* Functions to handle the ECOFF debugging directives. */
-extern void ecoff_directive_begin PARAMS ((int));
-extern void ecoff_directive_bend PARAMS ((int));
-extern void ecoff_directive_end PARAMS ((int));
-extern void ecoff_directive_ent PARAMS ((int));
-extern void ecoff_directive_fmask PARAMS ((int));
-extern void ecoff_directive_frame PARAMS ((int));
-extern void ecoff_directive_loc PARAMS ((int));
-extern void ecoff_directive_mask PARAMS ((int));
+extern void ecoff_directive_begin (int);
+extern void ecoff_directive_bend (int);
+extern void ecoff_directive_end (int);
+extern void ecoff_directive_ent (int);
+extern void ecoff_directive_fmask (int);
+extern void ecoff_directive_frame (int);
+extern void ecoff_directive_loc (int);
+extern void ecoff_directive_mask (int);
/* Other ECOFF directives. */
-extern void ecoff_directive_extern PARAMS ((int));
-extern void ecoff_directive_weakext PARAMS ((int));
+extern void ecoff_directive_extern (int);
+extern void ecoff_directive_weakext (int);
/* Functions to handle the COFF debugging directives. */
-extern void ecoff_directive_def PARAMS ((int));
-extern void ecoff_directive_dim PARAMS ((int));
-extern void ecoff_directive_endef PARAMS ((int));
-extern void ecoff_directive_file PARAMS ((int));
-extern void ecoff_directive_scl PARAMS ((int));
-extern void ecoff_directive_size PARAMS ((int));
-extern void ecoff_directive_tag PARAMS ((int));
-extern void ecoff_directive_type PARAMS ((int));
-extern void ecoff_directive_val PARAMS ((int));
+extern void ecoff_directive_def (int);
+extern void ecoff_directive_dim (int);
+extern void ecoff_directive_endef (int);
+extern void ecoff_directive_file (int);
+extern void ecoff_directive_scl (int);
+extern void ecoff_directive_size (int);
+extern void ecoff_directive_tag (int);
+extern void ecoff_directive_type (int);
+extern void ecoff_directive_val (int);
/* Handle stabs. */
-extern void ecoff_stab PARAMS ((segT sec, int what, const char *string,
- int type, int other, int desc));
+extern void ecoff_stab (segT sec, int what, const char *string,
+ int type, int other, int desc);
/* Set the GP prologue size. */
-extern void ecoff_set_gp_prolog_size PARAMS ((int sz));
+extern void ecoff_set_gp_prolog_size (int sz);
/* This routine is called from the ECOFF code to set the external
information for a symbol. */
#ifndef obj_ecoff_set_ext
-extern void obj_ecoff_set_ext PARAMS ((symbolS *, EXTR *));
+extern void obj_ecoff_set_ext (symbolS *, EXTR *);
#endif
/* This routine is used to patch up a line number directive when
instructions are moved around. */
-extern void ecoff_fix_loc PARAMS ((fragS *, unsigned long));
+extern void ecoff_fix_loc (fragS *, unsigned long);
/* This function is called from read.c to peek at cur_file_ptr. */
-extern int ecoff_no_current_file PARAMS ((void));
+extern int ecoff_no_current_file (void);
/* This function returns the symbol associated with the current proc. */
-extern symbolS *ecoff_get_cur_proc_sym PARAMS ((void));
+extern symbolS *ecoff_get_cur_proc_sym (void);
#endif /* ECOFF_DEBUGGING */
/* This routine is called from read.c to generate line number for .s file. */
-extern void ecoff_generate_asm_lineno PARAMS ((void));
+extern void ecoff_generate_asm_lineno (void);
#endif /* ! GAS_ECOFF_H */
diff --git a/contrib/binutils/gas/ehopt.c b/contrib/binutils/gas/ehopt.c
index 4f5c9b2..451aaff 100644
--- a/contrib/binutils/gas/ehopt.c
+++ b/contrib/binutils/gas/ehopt.c
@@ -1,5 +1,5 @@
/* ehopt.c--optimize gcc exception frame information.
- Copyright 1998, 2000, 2001 Free Software Foundation, Inc.
+ Copyright 1998, 2000, 2001, 2003 Free Software Foundation, Inc.
Written by Ian Lance Taylor <ian@cygnus.com>.
This file is part of GAS, the GNU Assembler.
@@ -94,13 +94,12 @@ struct cie_info
int z_augmentation;
};
-static int get_cie_info PARAMS ((struct cie_info *));
+static int get_cie_info (struct cie_info *);
/* Extract information from the CIE. */
static int
-get_cie_info (info)
- struct cie_info *info;
+get_cie_info (struct cie_info *info)
{
fragS *f;
fixS *fix;
@@ -248,9 +247,7 @@ get_cie_info (info)
change *EXP and *PNBYTES. */
int
-check_eh_frame (exp, pnbytes)
- expressionS *exp;
- unsigned int *pnbytes;
+check_eh_frame (expressionS *exp, unsigned int *pnbytes)
{
struct frame_data
{
@@ -363,6 +360,8 @@ check_eh_frame (exp, pnbytes)
}
else
d->state = state_error;
+ if (d->state == state_skipping_aug && d->aug_size == 0)
+ d->state = state_wait_loc4;
break;
case state_skipping_aug:
@@ -455,8 +454,7 @@ check_eh_frame (exp, pnbytes)
relaxation loop. We set fr_subtype{0:2} to the expected length. */
int
-eh_frame_estimate_size_before_relax (frag)
- fragS *frag;
+eh_frame_estimate_size_before_relax (fragS *frag)
{
offsetT diff;
int ca = frag->fr_subtype >> 3;
@@ -483,8 +481,7 @@ eh_frame_estimate_size_before_relax (frag)
the frag. This returns the change in frag length. */
int
-eh_frame_relax_frag (frag)
- fragS *frag;
+eh_frame_relax_frag (fragS *frag)
{
int oldsize, newsize;
@@ -498,8 +495,7 @@ eh_frame_relax_frag (frag)
fr_subtype{0:2} will be the desired length of the frag. */
void
-eh_frame_convert_frag (frag)
- fragS *frag;
+eh_frame_convert_frag (fragS *frag)
{
offsetT diff;
fragS *loc4_frag;
diff --git a/contrib/binutils/gas/emul.h b/contrib/binutils/gas/emul.h
index b665260..e4afa68 100644
--- a/contrib/binutils/gas/emul.h
+++ b/contrib/binutils/gas/emul.h
@@ -23,10 +23,10 @@
struct emulation
{
- void (* match) PARAMS ((const char *));
+ void (* match) (const char *);
const char * name;
- void (* init) PARAMS ((void));
- const char *(* bfd_name) PARAMS ((void));
+ void (* init) (void);
+ const char *(* bfd_name) (void);
unsigned local_labels_fb : 1;
unsigned local_labels_dollar : 1;
unsigned leading_underscore : 2;
@@ -38,7 +38,7 @@ struct emulation
COMMON struct emulation * this_emulation;
-extern const char * default_emul_bfd_name PARAMS ((void));
-extern void common_emul_init PARAMS ((void));
+extern const char * default_emul_bfd_name (void);
+extern void common_emul_init (void);
#endif
diff --git a/contrib/binutils/gas/expr.c b/contrib/binutils/gas/expr.c
index 13c167a..d520a04 100644
--- a/contrib/binutils/gas/expr.c
+++ b/contrib/binutils/gas/expr.c
@@ -1,6 +1,6 @@
/* expr.c -operands, expressions-
Copyright 1987, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
- 1999, 2000, 2001
+ 1999, 2000, 2001, 2002
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -32,17 +32,17 @@
#include "safe-ctype.h"
#include "obstack.h"
-static void floating_constant PARAMS ((expressionS * expressionP));
-static valueT generic_bignum_to_int32 PARAMS ((void));
+static void floating_constant (expressionS * expressionP);
+static valueT generic_bignum_to_int32 (void);
#ifdef BFD64
-static valueT generic_bignum_to_int64 PARAMS ((void));
+static valueT generic_bignum_to_int64 (void);
#endif
-static void integer_constant PARAMS ((int radix, expressionS * expressionP));
-static void mri_char_constant PARAMS ((expressionS *));
-static void current_location PARAMS ((expressionS *));
-static void clean_up_expression PARAMS ((expressionS * expressionP));
-static segT operand PARAMS ((expressionS *));
-static operatorT operator PARAMS ((int *));
+static void integer_constant (int radix, expressionS * expressionP);
+static void mri_char_constant (expressionS *);
+static void current_location (expressionS *);
+static void clean_up_expression (expressionS * expressionP);
+static segT operand (expressionS *);
+static operatorT operator (int *);
extern const char EXP_CHARS[], FLT_CHARS[];
@@ -63,11 +63,9 @@ static struct expr_symbol_line *expr_symbol_lines;
into the fake section expr_section. */
symbolS *
-make_expr_symbol (expressionP)
- expressionS *expressionP;
+make_expr_symbol (expressionS *expressionP)
{
expressionS zero;
- const char *fake;
symbolS *symbolP;
struct expr_symbol_line *n;
@@ -78,8 +76,8 @@ make_expr_symbol (expressionP)
if (expressionP->X_op == O_big)
{
/* This won't work, because the actual value is stored in
- generic_floating_point_number or generic_bignum, and we are
- going to lose it if we haven't already. */
+ generic_floating_point_number or generic_bignum, and we are
+ going to lose it if we haven't already. */
if (expressionP->X_add_number > 0)
as_bad (_("bignum invalid"));
else
@@ -91,13 +89,11 @@ make_expr_symbol (expressionP)
expressionP = &zero;
}
- fake = FAKE_LABEL_NAME;
-
/* Putting constant symbols in absolute_section rather than
expr_section is convenient for the old a.out code, for which
S_GET_SEGMENT does not always retrieve the value put in by
S_SET_SEGMENT. */
- symbolP = symbol_create (fake,
+ symbolP = symbol_create (FAKE_LABEL_NAME,
(expressionP->X_op == O_constant
? absolute_section
: expr_section),
@@ -121,10 +117,7 @@ make_expr_symbol (expressionP)
the symbol. */
int
-expr_symbol_where (sym, pfile, pline)
- symbolS *sym;
- char **pfile;
- unsigned int *pline;
+expr_symbol_where (symbolS *sym, char **pfile, unsigned int *pline)
{
register struct expr_symbol_line *l;
@@ -154,8 +147,7 @@ expr_symbol_where (sym, pfile, pline)
but that seems more clumsy. */
symbolS *
-expr_build_uconstant (value)
- offsetT value;
+expr_build_uconstant (offsetT value)
{
expressionS e;
@@ -168,9 +160,7 @@ expr_build_uconstant (value)
/* Build an expression for OP s1. */
symbolS *
-expr_build_unary (op, s1)
- operatorT op;
- symbolS *s1;
+expr_build_unary (operatorT op, symbolS *s1)
{
expressionS e;
@@ -183,10 +173,7 @@ expr_build_unary (op, s1)
/* Build an expression for s1 OP s2. */
symbolS *
-expr_build_binary (op, s1, s2)
- operatorT op;
- symbolS *s1;
- symbolS *s2;
+expr_build_binary (operatorT op, symbolS *s1, symbolS *s2)
{
expressionS e;
@@ -200,7 +187,7 @@ expr_build_binary (op, s1, s2)
/* Build an expression for the current location ('.'). */
symbolS *
-expr_build_dot ()
+expr_build_dot (void)
{
expressionS e;
@@ -230,8 +217,7 @@ FLONUM_TYPE generic_floating_point_number = {
int generic_floating_point_magic;
static void
-floating_constant (expressionP)
- expressionS *expressionP;
+floating_constant (expressionS *expressionP)
{
/* input_line_pointer -> floating-point constant. */
int error_code;
@@ -258,7 +244,7 @@ floating_constant (expressionP)
}
static valueT
-generic_bignum_to_int32 ()
+generic_bignum_to_int32 (void)
{
valueT number =
((generic_bignum[1] & LITTLENUM_MASK) << LITTLENUM_NUMBER_OF_BITS)
@@ -269,7 +255,7 @@ generic_bignum_to_int32 ()
#ifdef BFD64
static valueT
-generic_bignum_to_int64 ()
+generic_bignum_to_int64 (void)
{
valueT number =
((((((((valueT) generic_bignum[3] & LITTLENUM_MASK)
@@ -284,9 +270,7 @@ generic_bignum_to_int64 ()
#endif
static void
-integer_constant (radix, expressionP)
- int radix;
- expressionS *expressionP;
+integer_constant (int radix, expressionS *expressionP)
{
char *start; /* Start of number. */
char *suffix = NULL;
@@ -329,8 +313,8 @@ integer_constant (radix, expressionP)
int flt = 0;
/* In MRI mode, the number may have a suffix indicating the
- radix. For that matter, it might actually be a floating
- point constant. */
+ radix. For that matter, it might actually be a floating
+ point constant. */
for (suffix = input_line_pointer; ISALNUM (*suffix); suffix++)
{
if (*suffix == 'e' || *suffix == 'E')
@@ -401,7 +385,7 @@ integer_constant (radix, expressionP)
if (radix == 16 && c == '_')
{
/* This is literal of the form 0x333_0_12345678_1.
- This example is equivalent to 0x00000333000000001234567800000001. */
+ This example is equivalent to 0x00000333000000001234567800000001. */
int num_little_digits = 0;
int i;
@@ -645,8 +629,7 @@ integer_constant (radix, expressionP)
/* Parse an MRI multi character constant. */
static void
-mri_char_constant (expressionP)
- expressionS *expressionP;
+mri_char_constant (expressionS *expressionP)
{
int i;
@@ -681,8 +664,8 @@ mri_char_constant (expressionP)
if (i < SIZE_OF_LARGE_NUMBER - 1)
{
/* If there is more than one littlenum, left justify the
- last one to make it match the earlier ones. If there is
- only one, we can just use the value directly. */
+ last one to make it match the earlier ones. If there is
+ only one, we can just use the value directly. */
for (; j < CHARS_PER_LITTLENUM; j++)
generic_bignum[i] <<= 8;
}
@@ -735,8 +718,7 @@ mri_char_constant (expressionP)
handles the magic symbol `.'. */
static void
-current_location (expressionp)
- expressionS *expressionp;
+current_location (expressionS *expressionp)
{
if (now_seg == absolute_section)
{
@@ -745,13 +727,8 @@ current_location (expressionp)
}
else
{
- symbolS *symbolp;
-
- symbolp = symbol_new (FAKE_LABEL_NAME, now_seg,
- (valueT) frag_now_fix (),
- frag_now);
expressionp->X_op = O_symbol;
- expressionp->X_add_symbol = symbolp;
+ expressionp->X_add_symbol = symbol_temp_new_now ();
expressionp->X_add_number = 0;
}
}
@@ -764,8 +741,7 @@ current_location (expressionp)
Input_line_pointer->(next non-blank) char after operand. */
static segT
-operand (expressionP)
- expressionS *expressionP;
+operand (expressionS *expressionP)
{
char c;
symbolS *symbolP; /* Points to symbol. */
@@ -828,10 +804,10 @@ operand (expressionP)
{
char *s;
- /* Check for a hex constant. */
+ /* Check for a hex or float constant. */
for (s = input_line_pointer; hex_p (*s); s++)
;
- if (*s == 'h' || *s == 'H')
+ if (*s == 'h' || *s == 'H' || *input_line_pointer == '.')
{
--input_line_pointer;
integer_constant (0, expressionP);
@@ -1045,6 +1021,10 @@ operand (expressionP)
break;
case '+':
+ /* Do not accept ++e as +(+e).
+ Disabled, since the preprocessor removes whitespace. */
+ if (0 && *input_line_pointer == '+')
+ goto target_op;
(void) operand (expressionP);
break;
@@ -1062,6 +1042,11 @@ operand (expressionP)
case '!':
case '-':
{
+ /* Do not accept --e as -(-e)
+ Disabled, since the preprocessor removes whitespace. */
+ if (0 && c == '-' && *input_line_pointer == '-')
+ goto target_op;
+
operand (expressionP);
if (expressionP->X_op == O_constant)
{
@@ -1079,6 +1064,18 @@ operand (expressionP)
else
expressionP->X_add_number = ! expressionP->X_add_number;
}
+ else if (expressionP->X_op == O_big
+ && expressionP->X_add_number <= 0
+ && c == '-'
+ && (generic_floating_point_number.sign == '+'
+ || generic_floating_point_number.sign == 'P'))
+ {
+ /* Negative flonum (eg, -1.000e0). */
+ if (generic_floating_point_number.sign == '+')
+ generic_floating_point_number.sign = '-';
+ else
+ generic_floating_point_number.sign = 'N';
+ }
else if (expressionP->X_op != O_illegal
&& expressionP->X_op != O_absent)
{
@@ -1100,7 +1097,7 @@ operand (expressionP)
#if defined (DOLLAR_DOT) || defined (TC_M68K)
case '$':
/* '$' is the program counter when in MRI mode, or when
- DOLLAR_DOT is defined. */
+ DOLLAR_DOT is defined. */
#ifndef DOLLAR_DOT
if (! flag_m68k_mri)
goto de_fault;
@@ -1108,7 +1105,7 @@ operand (expressionP)
if (flag_m68k_mri && hex_p (*input_line_pointer))
{
/* In MRI mode, '$' is also used as the prefix for a
- hexadecimal constant. */
+ hexadecimal constant. */
integer_constant (16, expressionP);
break;
}
@@ -1199,7 +1196,7 @@ operand (expressionP)
goto de_fault;
/* In MRI mode, this is a floating point constant represented
- using hexadecimal digits. */
+ using hexadecimal digits. */
++input_line_pointer;
integer_constant (16, expressionP);
@@ -1227,9 +1224,9 @@ operand (expressionP)
#ifdef md_parse_name
/* This is a hook for the backend to parse certain names
- specially in certain contexts. If a name always has a
- specific value, it can often be handled by simply
- entering it in the symbol table. */
+ specially in certain contexts. If a name always has a
+ specific value, it can often be handled by simply
+ entering it in the symbol table. */
if (md_parse_name (name, expressionP, &c))
{
*input_line_pointer = c;
@@ -1301,6 +1298,7 @@ operand (expressionP)
}
else
{
+ target_op:
/* Let the target try to parse it. Success is indicated by changing
the X_op field to something other than O_absent and pointing
input_line_pointer past the expression. If it can't parse the
@@ -1347,13 +1345,10 @@ operand (expressionP)
Elsewise we waste time special-case testing. Sigh. Ditto SEG_ABSENT.
Out: expressionS may have been modified:
- 'foo-foo' symbol references cancelled to 0, which changes X_op
- from O_subtract to O_constant.
Unused fields zeroed to help expr (). */
static void
-clean_up_expression (expressionP)
- expressionS *expressionP;
+clean_up_expression (expressionS *expressionP)
{
switch (expressionP->X_op)
{
@@ -1371,23 +1366,6 @@ clean_up_expression (expressionP)
case O_bit_not:
expressionP->X_op_symbol = NULL;
break;
- case O_subtract:
- if (expressionP->X_op_symbol == expressionP->X_add_symbol
- || ((symbol_get_frag (expressionP->X_op_symbol)
- == symbol_get_frag (expressionP->X_add_symbol))
- && SEG_NORMAL (S_GET_SEGMENT (expressionP->X_add_symbol))
- && (S_GET_VALUE (expressionP->X_op_symbol)
- == S_GET_VALUE (expressionP->X_add_symbol))))
- {
- addressT diff = (S_GET_VALUE (expressionP->X_add_symbol)
- - S_GET_VALUE (expressionP->X_op_symbol));
-
- expressionP->X_op = O_constant;
- expressionP->X_add_symbol = NULL;
- expressionP->X_op_symbol = NULL;
- expressionP->X_add_number += diff;
- }
- break;
default:
break;
}
@@ -1521,7 +1499,7 @@ static operator_rankT op_rank[] = {
#define MRI_MUL_PRECEDENCE 6
void
-expr_set_precedence ()
+expr_set_precedence (void)
{
if (flag_m68k_mri)
{
@@ -1540,7 +1518,7 @@ expr_set_precedence ()
/* Initialize the expression parser. */
void
-expr_begin ()
+expr_begin (void)
{
expr_set_precedence ();
@@ -1557,8 +1535,7 @@ expr_begin ()
Does not advance INPUT_LINE_POINTER. */
static inline operatorT
-operator (num_chars)
- int *num_chars;
+operator (int *num_chars)
{
int c;
operatorT ret;
@@ -1574,6 +1551,14 @@ operator (num_chars)
default:
return op_encoding[c];
+ case '+':
+ case '-':
+ /* Do not allow a++b and a--b to be a + (+b) and a - (-b)
+ Disabled, since the preprocessor removes whitespace. */
+ if (1 || input_line_pointer[1] != c)
+ return op_encoding[c];
+ return O_illegal;
+
case '<':
switch (input_line_pointer[1])
{
@@ -1646,9 +1631,8 @@ operator (num_chars)
/* Parse an expression. */
segT
-expr (rankarg, resultP)
- int rankarg; /* Larger # is higher rank. */
- expressionS *resultP; /* Deliver result here. */
+expr (int rankarg, /* Larger # is higher rank. */
+ expressionS *resultP /* Deliver result here. */)
{
operator_rankT rank = (operator_rankT) rankarg;
segT retval;
@@ -1659,6 +1643,10 @@ expr (rankarg, resultP)
know (rank >= 0);
+ /* Save the value of dot for the fixup code. */
+ if (rank == 0)
+ dot_value = frag_now_fix ();
+
retval = operand (resultP);
/* operand () gobbles spaces. */
@@ -1749,7 +1737,8 @@ expr (rankarg, resultP)
&& resultP->X_op == O_symbol
&& (symbol_get_frag (right.X_add_symbol)
== symbol_get_frag (resultP->X_add_symbol))
- && SEG_NORMAL (rightseg))
+ && (SEG_NORMAL (rightseg)
+ || right.X_add_symbol == resultP->X_add_symbol))
{
resultP->X_add_number -= right.X_add_number;
resultP->X_add_number += (S_GET_VALUE (resultP->X_add_symbol)
@@ -1789,7 +1778,7 @@ expr (rankarg, resultP)
case O_left_shift: resultP->X_add_number <<= v; break;
case O_right_shift:
/* We always use unsigned shifts, to avoid relying on
- characteristics of the compiler used to compile gas. */
+ characteristics of the compiler used to compile gas. */
resultP->X_add_number =
(offsetT) ((valueT) resultP->X_add_number >> (valueT) v);
break;
@@ -1901,7 +1890,7 @@ expr (rankarg, resultP)
lines end in end-of-line. */
char
-get_symbol_end ()
+get_symbol_end (void)
{
char c;
@@ -1920,7 +1909,7 @@ get_symbol_end ()
}
unsigned int
-get_single_number ()
+get_single_number (void)
{
expressionS exp;
operand (&exp);
diff --git a/contrib/binutils/gas/expr.h b/contrib/binutils/gas/expr.h
index 3a4c931..382dda9 100644
--- a/contrib/binutils/gas/expr.h
+++ b/contrib/binutils/gas/expr.h
@@ -68,23 +68,23 @@ typedef enum {
O_multiply,
/* (X_add_symbol / X_op_symbol) + X_add_number. */
O_divide,
- /* X_add_symbol % X_op_symbol) + X_add_number. */
+ /* (X_add_symbol % X_op_symbol) + X_add_number. */
O_modulus,
- /* X_add_symbol << X_op_symbol) + X_add_number. */
+ /* (X_add_symbol << X_op_symbol) + X_add_number. */
O_left_shift,
- /* X_add_symbol >> X_op_symbol) + X_add_number. */
+ /* (X_add_symbol >> X_op_symbol) + X_add_number. */
O_right_shift,
- /* X_add_symbol | X_op_symbol) + X_add_number. */
+ /* (X_add_symbol | X_op_symbol) + X_add_number. */
O_bit_inclusive_or,
- /* X_add_symbol |~ X_op_symbol) + X_add_number. */
+ /* (X_add_symbol |~ X_op_symbol) + X_add_number. */
O_bit_or_not,
- /* X_add_symbol ^ X_op_symbol) + X_add_number. */
+ /* (X_add_symbol ^ X_op_symbol) + X_add_number. */
O_bit_exclusive_or,
- /* X_add_symbol & X_op_symbol) + X_add_number. */
+ /* (X_add_symbol & X_op_symbol) + X_add_number. */
O_bit_and,
- /* X_add_symbol + X_op_symbol) + X_add_number. */
+ /* (X_add_symbol + X_op_symbol) + X_add_number. */
O_add,
- /* X_add_symbol - X_op_symbol) + X_add_number. */
+ /* (X_add_symbol - X_op_symbol) + X_add_number. */
O_subtract,
/* (X_add_symbol == X_op_symbol) + X_add_number. */
O_eq,
@@ -157,16 +157,15 @@ extern LITTLENUM_TYPE generic_bignum[];
typedef char operator_rankT;
-extern char get_symbol_end PARAMS ((void));
-extern void expr_begin PARAMS ((void));
-extern void expr_set_precedence PARAMS ((void));
-extern segT expr PARAMS ((int rank, expressionS * resultP));
-extern unsigned int get_single_number PARAMS ((void));
-extern symbolS *make_expr_symbol PARAMS ((expressionS * expressionP));
-extern int expr_symbol_where
- PARAMS ((symbolS *, char **, unsigned int *));
-
-extern symbolS *expr_build_uconstant PARAMS ((offsetT));
-extern symbolS *expr_build_unary PARAMS ((operatorT, symbolS *));
-extern symbolS *expr_build_binary PARAMS ((operatorT, symbolS *, symbolS *));
-extern symbolS *expr_build_dot PARAMS ((void));
+extern char get_symbol_end (void);
+extern void expr_begin (void);
+extern void expr_set_precedence (void);
+extern segT expr (int rank, expressionS * resultP);
+extern unsigned int get_single_number (void);
+extern symbolS *make_expr_symbol (expressionS * expressionP);
+extern int expr_symbol_where (symbolS *, char **, unsigned int *);
+
+extern symbolS *expr_build_uconstant (offsetT);
+extern symbolS *expr_build_unary (operatorT, symbolS *);
+extern symbolS *expr_build_binary (operatorT, symbolS *, symbolS *);
+extern symbolS *expr_build_dot (void);
diff --git a/contrib/binutils/gas/flonum-copy.c b/contrib/binutils/gas/flonum-copy.c
index 1e6b40b..e3aba2c 100644
--- a/contrib/binutils/gas/flonum-copy.c
+++ b/contrib/binutils/gas/flonum-copy.c
@@ -22,9 +22,7 @@
#include "as.h"
void
-flonum_copy (in, out)
- FLONUM_TYPE *in;
- FLONUM_TYPE *out;
+flonum_copy (FLONUM_TYPE *in, FLONUM_TYPE *out)
{
unsigned int in_length; /* 0 origin */
unsigned int out_length; /* 0 origin */
diff --git a/contrib/binutils/gas/flonum-mult.c b/contrib/binutils/gas/flonum-mult.c
index e23579a..6d17f0a 100644
--- a/contrib/binutils/gas/flonum-mult.c
+++ b/contrib/binutils/gas/flonum-mult.c
@@ -71,10 +71,8 @@
(C style also gives deeper insight [to me] ... oh well ...) */
void
-flonum_multip (a, b, product)
- const FLONUM_TYPE *a;
- const FLONUM_TYPE *b;
- FLONUM_TYPE *product;
+flonum_multip (const FLONUM_TYPE *a, const FLONUM_TYPE *b,
+ FLONUM_TYPE *product)
{
int size_of_a; /* 0 origin */
int size_of_b; /* 0 origin */
diff --git a/contrib/binutils/gas/flonum.h b/contrib/binutils/gas/flonum.h
index e50d9bf..22aa755 100644
--- a/contrib/binutils/gas/flonum.h
+++ b/contrib/binutils/gas/flonum.h
@@ -84,14 +84,14 @@ extern const int table_size_of_flonum_powers_of_ten;
* *
\***********************************************************************/
-int atof_generic PARAMS ((char **address_of_string_pointer,
- const char *string_of_decimal_marks,
- const char *string_of_decimal_exponent_marks,
- FLONUM_TYPE * address_of_generic_floating_point_number));
-
-void flonum_copy PARAMS ((FLONUM_TYPE * in, FLONUM_TYPE * out));
-void flonum_multip PARAMS ((const FLONUM_TYPE * a, const FLONUM_TYPE * b,
- FLONUM_TYPE * product));
+int atof_generic (char **address_of_string_pointer,
+ const char *string_of_decimal_marks,
+ const char *string_of_decimal_exponent_marks,
+ FLONUM_TYPE * address_of_generic_floating_point_number);
+
+void flonum_copy (FLONUM_TYPE * in, FLONUM_TYPE * out);
+void flonum_multip (const FLONUM_TYPE * a, const FLONUM_TYPE * b,
+ FLONUM_TYPE * product);
/***********************************************************************\
* *
diff --git a/contrib/binutils/gas/frags.c b/contrib/binutils/gas/frags.c
index 8d7ed2f..83625d7 100644
--- a/contrib/binutils/gas/frags.c
+++ b/contrib/binutils/gas/frags.c
@@ -1,6 +1,6 @@
/* frags.c - manage frags -
Copyright 1987, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
- 1999, 2000
+ 1999, 2000, 2001, 2003
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -30,19 +30,38 @@ extern fragS bss_address_frag;
/* Initialization for frag routines. */
void
-frag_init ()
+frag_init (void)
{
zero_address_frag.fr_type = rs_fill;
bss_address_frag.fr_type = rs_fill;
}
+/* Check that we're not trying to assemble into a section that can't
+ allocate frags (currently, this is only possible in the absolute
+ section), or into an mri common. */
+
+static void
+frag_alloc_check (const struct obstack *ob)
+{
+ if (ob->chunk_size == 0)
+ {
+ as_bad (_("attempt to allocate data in absolute section"));
+ subseg_set (text_section, 0);
+ }
+
+ if (mri_common_symbol != NULL)
+ {
+ as_bad (_("attempt to allocate data in common section"));
+ mri_common_symbol = NULL;
+ }
+}
+
/* Allocate a frag on the specified obstack.
Call this routine from everywhere else, so that all the weird alignment
hackery can be done in just one place. */
fragS *
-frag_alloc (ob)
- struct obstack *ob;
+frag_alloc (struct obstack *ob)
{
fragS *ptr;
int oalign;
@@ -62,8 +81,7 @@ frag_alloc (ob)
do not return. Do not set up any fields of *now_frag. */
void
-frag_grow (nchars)
- unsigned int nchars;
+frag_grow (unsigned int nchars)
{
if (obstack_room (&frchain_now->frch_obstack) < nchars)
{
@@ -105,10 +123,9 @@ frag_grow (nchars)
of frchain_now. */
void
-frag_new (old_frags_var_max_size)
- /* Number of chars (already allocated on obstack frags) in
- variable_length part of frag. */
- int old_frags_var_max_size;
+frag_new (int old_frags_var_max_size
+ /* Number of chars (already allocated on obstack frags) in
+ variable_length part of frag. */)
{
fragS *former_last_fragP;
frchainS *frchP;
@@ -158,23 +175,11 @@ frag_new (old_frags_var_max_size)
frag_now_growth past the new chars. */
char *
-frag_more (nchars)
- int nchars;
+frag_more (int nchars)
{
register char *retval;
- if (now_seg == absolute_section)
- {
- as_bad (_("attempt to allocate data in absolute section"));
- subseg_set (text_section, 0);
- }
-
- if (mri_common_symbol != NULL)
- {
- as_bad (_("attempt to allocate data in common section"));
- mri_common_symbol = NULL;
- }
-
+ frag_alloc_check (&frchain_now->frch_obstack);
frag_grow (nchars);
retval = obstack_next_free (&frchain_now->frch_obstack);
obstack_blank_fast (&frchain_now->frch_obstack, nchars);
@@ -189,14 +194,8 @@ frag_more (nchars)
to write into. */
char *
-frag_var (type, max_chars, var, subtype, symbol, offset, opcode)
- relax_stateT type;
- int max_chars;
- int var;
- relax_substateT subtype;
- symbolS *symbol;
- offsetT offset;
- char *opcode;
+frag_var (relax_stateT type, int max_chars, int var, relax_substateT subtype,
+ symbolS *symbol, offsetT offset, char *opcode)
{
register char *retval;
@@ -227,14 +226,9 @@ frag_var (type, max_chars, var, subtype, symbol, offset, opcode)
No call to frag_grow is done. */
char *
-frag_variant (type, max_chars, var, subtype, symbol, offset, opcode)
- relax_stateT type;
- int max_chars;
- int var;
- relax_substateT subtype;
- symbolS *symbol;
- offsetT offset;
- char *opcode;
+frag_variant (relax_stateT type, int max_chars, int var,
+ relax_substateT subtype, symbolS *symbol, offsetT offset,
+ char *opcode)
{
register char *retval;
@@ -261,14 +255,21 @@ frag_variant (type, max_chars, var, subtype, symbol, offset, opcode)
/* Reduce the variable end of a frag to a harmless state. */
void
-frag_wane (fragP)
- register fragS *fragP;
+frag_wane (register fragS *fragP)
{
fragP->fr_type = rs_fill;
fragP->fr_offset = 0;
fragP->fr_var = 0;
}
+/* Return the number of bytes by which the current frag can be grown. */
+
+int
+frag_room (void)
+{
+ return obstack_room (&frchain_now->frch_obstack);
+}
+
/* Make an alignment frag. The size of this frag will be adjusted to
force the next frag to have the appropriate alignment. ALIGNMENT
is the power of two to which to align. FILL_CHARACTER is the
@@ -277,10 +278,7 @@ frag_wane (fragP)
or 0 if there is no maximum. */
void
-frag_align (alignment, fill_character, max)
- int alignment;
- int fill_character;
- int max;
+frag_align (int alignment, int fill_character, int max)
{
if (now_seg == absolute_section)
{
@@ -310,11 +308,8 @@ frag_align (alignment, fill_character, max)
doing the alignment, or 0 if there is no maximum. */
void
-frag_align_pattern (alignment, fill_pattern, n_fill, max)
- int alignment;
- const char *fill_pattern;
- int n_fill;
- int max;
+frag_align_pattern (int alignment, const char *fill_pattern,
+ int n_fill, int max)
{
char *p;
@@ -344,9 +339,7 @@ frag_align_pattern (alignment, fill_pattern, n_fill, max)
#endif
void
-frag_align_code (alignment, max)
- int alignment;
- int max;
+frag_align_code (int alignment, int max)
{
char *p;
@@ -357,7 +350,7 @@ frag_align_code (alignment, max)
}
addressT
-frag_now_fix_octets ()
+frag_now_fix_octets (void)
{
if (now_seg == absolute_section)
return abs_section_offset;
@@ -367,15 +360,15 @@ frag_now_fix_octets ()
}
addressT
-frag_now_fix ()
+frag_now_fix (void)
{
return frag_now_fix_octets () / OCTETS_PER_BYTE;
}
void
-frag_append_1_char (datum)
- int datum;
+frag_append_1_char (int datum)
{
+ frag_alloc_check (&frchain_now->frch_obstack);
if (obstack_room (&frchain_now->frch_obstack) <= 1)
{
frag_wane (frag_now);
diff --git a/contrib/binutils/gas/frags.h b/contrib/binutils/gas/frags.h
index 9d52ae8..52a6cfe 100644
--- a/contrib/binutils/gas/frags.h
+++ b/contrib/binutils/gas/frags.h
@@ -106,8 +106,8 @@ struct frag {
however, included in frchain_now. The fr_fix field is bogus;
instead, use frag_now_fix (). */
COMMON fragS *frag_now;
-extern addressT frag_now_fix PARAMS ((void));
-extern addressT frag_now_fix_octets PARAMS ((void));
+extern addressT frag_now_fix (void);
+extern addressT frag_now_fix_octets (void);
/* For foreign-segment symbol fixups. */
COMMON fragS zero_address_frag;
@@ -116,7 +116,7 @@ COMMON fragS bss_address_frag;
#if 0
/* A macro to speed up appending exactly 1 char to current frag. */
-/* JF changed < 1 to <= 1 to avoid a race conditon. */
+/* JF changed < 1 to <= 1 to avoid a race condition. */
#define FRAG_APPEND_1_CHAR(datum) \
{ \
if (obstack_room (&frags) <= 1) \
@@ -127,37 +127,36 @@ COMMON fragS bss_address_frag;
obstack_1grow (&frags, datum); \
}
#else
-extern void frag_append_1_char PARAMS ((int));
+extern void frag_append_1_char (int);
#define FRAG_APPEND_1_CHAR(X) frag_append_1_char (X)
#endif
-void frag_init PARAMS ((void));
-fragS *frag_alloc PARAMS ((struct obstack *));
-void frag_grow PARAMS ((unsigned int nchars));
-char *frag_more PARAMS ((int nchars));
-void frag_align PARAMS ((int alignment, int fill_character, int max));
-void frag_align_pattern PARAMS ((int alignment,
- const char *fill_pattern,
- int n_fill,
- int max));
-void frag_align_code PARAMS ((int alignment, int max));
-void frag_new PARAMS ((int old_frags_var_max_size));
-void frag_wane PARAMS ((fragS * fragP));
-
-char *frag_variant PARAMS ((relax_stateT type,
- int max_chars,
- int var,
- relax_substateT subtype,
- symbolS * symbol,
- offsetT offset,
- char *opcode));
-
-char *frag_var PARAMS ((relax_stateT type,
- int max_chars,
- int var,
- relax_substateT subtype,
- symbolS * symbol,
- offsetT offset,
- char *opcode));
+void frag_init (void);
+fragS *frag_alloc (struct obstack *);
+void frag_grow (unsigned int nchars);
+char *frag_more (int nchars);
+void frag_align (int alignment, int fill_character, int max);
+void frag_align_pattern (int alignment, const char *fill_pattern,
+ int n_fill, int max);
+void frag_align_code (int alignment, int max);
+void frag_new (int old_frags_var_max_size);
+void frag_wane (fragS * fragP);
+int frag_room (void);
+
+char *frag_variant (relax_stateT type,
+ int max_chars,
+ int var,
+ relax_substateT subtype,
+ symbolS * symbol,
+ offsetT offset,
+ char *opcode);
+
+char *frag_var (relax_stateT type,
+ int max_chars,
+ int var,
+ relax_substateT subtype,
+ symbolS * symbol,
+ offsetT offset,
+ char *opcode);
#endif /* FRAGS_H */
diff --git a/contrib/binutils/gas/hash.c b/contrib/binutils/gas/hash.c
index df9101d..a7b8298 100644
--- a/contrib/binutils/gas/hash.c
+++ b/contrib/binutils/gas/hash.c
@@ -23,7 +23,7 @@
/* This version of the hash table code is a wholescale replacement of
the old hash table code, which was fairly bad. This is based on
the hash table code in BFD, but optimized slightly for the
- asssembler. The assembler does not need to derive structures that
+ assembler. The assembler does not need to derive structures that
are stored in the hash table. Instead, it always stores a pointer.
The assembler uses the hash table mostly to store symbols, and we
don't need to confuse the symbol structure with a hash table
@@ -75,7 +75,7 @@ struct hash_control {
/* Create a hash table. This return a control block. */
struct hash_control *
-hash_new ()
+hash_new (void)
{
unsigned int size;
struct hash_control *ret;
@@ -105,8 +105,7 @@ hash_new ()
/* Delete a hash table, freeing all allocated memory. */
void
-hash_die (table)
- struct hash_control *table;
+hash_die (struct hash_control *table)
{
obstack_free (&table->memory, 0);
free (table);
@@ -121,17 +120,14 @@ hash_die (table)
Each time we look up a string, we move it to the start of the list
for its hash code, to take advantage of referential locality. */
-static struct hash_entry *hash_lookup PARAMS ((struct hash_control *,
- const char *,
- struct hash_entry ***,
- unsigned long *));
+static struct hash_entry *hash_lookup (struct hash_control *,
+ const char *,
+ struct hash_entry ***,
+ unsigned long *);
static struct hash_entry *
-hash_lookup (table, key, plist, phash)
- struct hash_control *table;
- const char *key;
- struct hash_entry ***plist;
- unsigned long *phash;
+hash_lookup (struct hash_control *table, const char *key,
+ struct hash_entry ***plist, unsigned long *phash)
{
register unsigned long hash;
unsigned int len;
@@ -205,10 +201,7 @@ hash_lookup (table, key, plist, phash)
hash table. */
const char *
-hash_insert (table, key, value)
- struct hash_control *table;
- const char *key;
- PTR value;
+hash_insert (struct hash_control *table, const char *key, PTR value)
{
struct hash_entry *p;
struct hash_entry **list;
@@ -238,10 +231,7 @@ hash_insert (table, key, value)
error. If an entry already exists, its value is replaced. */
const char *
-hash_jam (table, key, value)
- struct hash_control *table;
- const char *key;
- PTR value;
+hash_jam (struct hash_control *table, const char *key, PTR value)
{
struct hash_entry *p;
struct hash_entry **list;
@@ -279,10 +269,7 @@ hash_jam (table, key, value)
table, this does nothing and returns NULL. */
PTR
-hash_replace (table, key, value)
- struct hash_control *table;
- const char *key;
- PTR value;
+hash_replace (struct hash_control *table, const char *key, PTR value)
{
struct hash_entry *p;
PTR ret;
@@ -306,9 +293,7 @@ hash_replace (table, key, value)
if the entry is not found. */
PTR
-hash_find (table, key)
- struct hash_control *table;
- const char *key;
+hash_find (struct hash_control *table, const char *key)
{
struct hash_entry *p;
@@ -323,9 +308,7 @@ hash_find (table, key)
for that entry, or NULL if there is no such entry. */
PTR
-hash_delete (table, key)
- struct hash_control *table;
- const char *key;
+hash_delete (struct hash_control *table, const char *key)
{
struct hash_entry *p;
struct hash_entry **list;
@@ -354,9 +337,8 @@ hash_delete (table, key)
hash table. */
void
-hash_traverse (table, pfn)
- struct hash_control *table;
- void (*pfn) PARAMS ((const char *key, PTR value));
+hash_traverse (struct hash_control *table,
+ void (*pfn) (const char *key, PTR value))
{
unsigned int i;
@@ -373,10 +355,9 @@ hash_traverse (table, pfn)
name of the hash table, used for printing a header. */
void
-hash_print_statistics (f, name, table)
- FILE *f ATTRIBUTE_UNUSED;
- const char *name ATTRIBUTE_UNUSED;
- struct hash_control *table ATTRIBUTE_UNUSED;
+hash_print_statistics (FILE *f ATTRIBUTE_UNUSED,
+ const char *name ATTRIBUTE_UNUSED,
+ struct hash_control *table ATTRIBUTE_UNUSED)
{
#ifdef HASH_STATISTICS
unsigned int i;
@@ -430,7 +411,7 @@ char answer[100];
/* We test many hash tables at once. */
char *hashtable[TABLES];
-/* Points to curent hash_control. */
+/* Points to current hash_control. */
char *h;
char **pp;
char *p;
diff --git a/contrib/binutils/gas/hash.h b/contrib/binutils/gas/hash.h
index ecab0fa..08f41e6 100644
--- a/contrib/binutils/gas/hash.h
+++ b/contrib/binutils/gas/hash.h
@@ -25,54 +25,54 @@ struct hash_control;
/* Create a hash table. This return a control block. */
-extern struct hash_control *hash_new PARAMS ((void));
+extern struct hash_control *hash_new (void);
/* Delete a hash table, freeing all allocated memory. */
-extern void hash_die PARAMS ((struct hash_control *));
+extern void hash_die (struct hash_control *);
/* Insert an entry into a hash table. This returns NULL on success.
On error, it returns a printable string indicating the error. It
is considered to be an error if the entry already exists in the
hash table. */
-extern const char *hash_insert PARAMS ((struct hash_control *,
- const char *key, PTR value));
+extern const char *hash_insert (struct hash_control *,
+ const char *key, PTR value);
/* Insert or replace an entry in a hash table. This returns NULL on
success. On error, it returns a printable string indicating the
error. If an entry already exists, its value is replaced. */
-extern const char *hash_jam PARAMS ((struct hash_control *,
- const char *key, PTR value));
+extern const char *hash_jam (struct hash_control *,
+ const char *key, PTR value);
/* Replace an existing entry in a hash table. This returns the old
value stored for the entry. If the entry is not found in the hash
table, this does nothing and returns NULL. */
-extern PTR hash_replace PARAMS ((struct hash_control *, const char *key,
- PTR value));
+extern PTR hash_replace (struct hash_control *, const char *key,
+ PTR value);
/* Find an entry in a hash table, returning its value. Returns NULL
if the entry is not found. */
-extern PTR hash_find PARAMS ((struct hash_control *, const char *key));
+extern PTR hash_find (struct hash_control *, const char *key);
/* Delete an entry from a hash table. This returns the value stored
for that entry, or NULL if there is no such entry. */
-extern PTR hash_delete PARAMS ((struct hash_control *, const char *key));
+extern PTR hash_delete (struct hash_control *, const char *key);
/* Traverse a hash table. Call the function on every entry in the
hash table. */
-extern void hash_traverse PARAMS ((struct hash_control *,
- void (*pfn) (const char *key, PTR value)));
+extern void hash_traverse (struct hash_control *,
+ void (*pfn) (const char *key, PTR value));
/* Print hash table statistics on the specified file. NAME is the
name of the hash table, used for printing a header. */
-extern void hash_print_statistics PARAMS ((FILE *, const char *name,
- struct hash_control *));
+extern void hash_print_statistics (FILE *, const char *name,
+ struct hash_control *);
#endif /* HASH_H */
diff --git a/contrib/binutils/gas/input-file.c b/contrib/binutils/gas/input-file.c
index 5c23f31..01cc669 100644
--- a/contrib/binutils/gas/input-file.c
+++ b/contrib/binutils/gas/input-file.c
@@ -1,5 +1,5 @@
/* input_file.c - Deal with Input Files -
- Copyright 1987, 1990, 1991, 1992, 1993, 1994, 1995, 1999, 2000, 2001
+ Copyright 1987, 1990, 1991, 1992, 1993, 1994, 1995, 1999, 2000, 2001, 2003
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -26,11 +26,12 @@
#include <stdio.h>
#include <string.h>
+#include <errno.h>
#include "as.h"
#include "input-file.h"
#include "safe-ctype.h"
-static int input_file_get PARAMS ((char *, int));
+static int input_file_get (char *, int);
/* This variable is non-zero if the file currently being read should be
preprocessed by app. It is zero if the file can be read straight in. */
@@ -58,28 +59,28 @@ struct saved_file
char * app_save;
};
-/* These hooks accomodate most operating systems. */
+/* These hooks accommodate most operating systems. */
void
-input_file_begin ()
+input_file_begin (void)
{
f_in = (FILE *) 0;
}
void
-input_file_end ()
+input_file_end (void)
{
}
/* Return BUFFER_SIZE. */
unsigned int
-input_file_buffer_size ()
+input_file_buffer_size (void)
{
return (BUFFER_SIZE);
}
int
-input_file_is_open ()
+input_file_is_open (void)
{
return f_in != (FILE *) 0;
}
@@ -88,7 +89,7 @@ input_file_is_open ()
can be restored with input_file_pop (). */
char *
-input_file_push ()
+input_file_push (void)
{
register struct saved_file *saved;
@@ -107,8 +108,7 @@ input_file_push ()
}
void
-input_file_pop (arg)
- char *arg;
+input_file_pop (char *arg)
{
register struct saved_file *saved = (struct saved_file *) arg;
@@ -124,9 +124,8 @@ input_file_pop (arg)
}
void
-input_file_open (filename, pre)
- char *filename; /* "" means use stdin. Must not be 0. */
- int pre;
+input_file_open (char *filename, /* "" means use stdin. Must not be 0. */
+ int pre)
{
int c;
char buf[80];
@@ -135,23 +134,36 @@ input_file_open (filename, pre)
assert (filename != 0); /* Filename may not be NULL. */
if (filename[0])
- { /* We have a file name. Suck it and see. */
+ {
f_in = fopen (filename, FOPEN_RT);
file_name = filename;
}
else
- { /* use stdin for the input file. */
+ {
+ /* Use stdin for the input file. */
f_in = stdin;
- file_name = _("{standard input}"); /* For error messages. */
+ /* For error messages. */
+ file_name = _("{standard input}");
}
- if (f_in == (FILE *) 0)
+
+ if (f_in)
+ c = getc (f_in);
+
+ if (f_in == NULL || ferror (f_in))
{
- as_bad (_("can't open %s for reading"), file_name);
- as_perror ("%s", file_name);
+#ifdef BFD_ASSEMBLER
+ bfd_set_error (bfd_error_system_call);
+#endif
+ as_perror (_("Can't open %s for reading"), file_name);
+
+ if (f_in)
+ {
+ fclose (f_in);
+ f_in = NULL;
+ }
return;
}
- c = getc (f_in);
if (c == '#')
{
/* Begins with comment, may not want to preprocess. */
@@ -188,7 +200,7 @@ input_file_open (filename, pre)
/* Close input file. */
void
-input_file_close ()
+input_file_close (void)
{
/* Don't close a null file pointer. */
if (f_in != NULL)
@@ -200,15 +212,16 @@ input_file_close ()
/* This function is passed to do_scrub_chars. */
static int
-input_file_get (buf, buflen)
- char *buf;
- int buflen;
+input_file_get (char *buf, int buflen)
{
int size;
size = fread (buf, sizeof (char), buflen, f_in);
if (size < 0)
{
+#ifdef BFD_ASSEMBLER
+ bfd_set_error (bfd_error_system_call);
+#endif
as_perror (_("Can't read from %s"), file_name);
size = 0;
}
@@ -218,8 +231,7 @@ input_file_get (buf, buflen)
/* Read a buffer from the input file. */
char *
-input_file_give_next_buffer (where)
- char *where; /* Where to place 1st character of new buffer. */
+input_file_give_next_buffer (char *where /* Where to place 1st character of new buffer. */)
{
char *return_value; /* -> Last char of what we read, + 1. */
register int size;
@@ -236,6 +248,9 @@ input_file_give_next_buffer (where)
size = fread (where, sizeof (char), BUFFER_SIZE, f_in);
if (size < 0)
{
+#ifdef BFD_ASSEMBLER
+ bfd_set_error (bfd_error_system_call);
+#endif
as_perror (_("Can't read from %s"), file_name);
size = 0;
}
@@ -244,7 +259,12 @@ input_file_give_next_buffer (where)
else
{
if (fclose (f_in))
- as_perror (_("Can't close %s"), file_name);
+ {
+#ifdef BFD_ASSEMBLER
+ bfd_set_error (bfd_error_system_call);
+#endif
+ as_perror (_("Can't close %s"), file_name);
+ }
f_in = (FILE *) 0;
return_value = 0;
}
diff --git a/contrib/binutils/gas/input-file.h b/contrib/binutils/gas/input-file.h
index 9934869..b686a0d 100644
--- a/contrib/binutils/gas/input-file.h
+++ b/contrib/binutils/gas/input-file.h
@@ -55,12 +55,12 @@
* about I/O errors. No I/O errors are fatal: an end-of-file may be faked.
*/
-char *input_file_give_next_buffer PARAMS ((char *where));
-char *input_file_push PARAMS ((void));
-unsigned int input_file_buffer_size PARAMS ((void));
-int input_file_is_open PARAMS ((void));
-void input_file_begin PARAMS ((void));
-void input_file_close PARAMS ((void));
-void input_file_end PARAMS ((void));
-void input_file_open PARAMS ((char *filename, int pre));
-void input_file_pop PARAMS ((char *arg));
+char *input_file_give_next_buffer (char *where);
+char *input_file_push (void);
+unsigned int input_file_buffer_size (void);
+int input_file_is_open (void);
+void input_file_begin (void);
+void input_file_close (void);
+void input_file_end (void);
+void input_file_open (char *filename, int pre);
+void input_file_pop (char *arg);
diff --git a/contrib/binutils/gas/input-scrub.c b/contrib/binutils/gas/input-scrub.c
index d343711..7a03965 100644
--- a/contrib/binutils/gas/input-scrub.c
+++ b/contrib/binutils/gas/input-scrub.c
@@ -33,7 +33,7 @@
* were broken across buffers, and return a buffer of full lines to
* the caller.
* The last partial line begins the next buffer we build and return to caller.
- * The buffer returned to caller is preceeded by BEFORE_STRING and followed
+ * The buffer returned to caller is preceded by BEFORE_STRING and followed
* by AFTER_STRING, as sentinels. The last character before AFTER_STRING
* is a newline.
* Also looks after line numbers, for e.g. error messages.
@@ -121,9 +121,9 @@ struct input_save {
char * saved_position; /* Caller's saved position in buf. */
};
-static struct input_save *input_scrub_push PARAMS ((char *saved_position));
-static char *input_scrub_pop PARAMS ((struct input_save *arg));
-static void as_1_char PARAMS ((unsigned int c, FILE * stream));
+static struct input_save *input_scrub_push (char *saved_position);
+static char *input_scrub_pop (struct input_save *arg);
+static void as_1_char (unsigned int c, FILE * stream);
/* Saved information about the file that .include'd this one. When we hit EOF,
we automatically pop to that file. */
@@ -135,8 +135,7 @@ static struct input_save *next_saved_file;
area, which can be restored by passing it to input_scrub_pop(). */
static struct input_save *
-input_scrub_push (saved_position)
- char *saved_position;
+input_scrub_push (char *saved_position)
{
register struct input_save *saved;
@@ -171,8 +170,7 @@ input_scrub_push (saved_position)
}
static char *
-input_scrub_pop (saved)
- struct input_save *saved;
+input_scrub_pop (struct input_save *saved)
{
char *saved_position;
@@ -199,7 +197,7 @@ input_scrub_pop (saved)
}
void
-input_scrub_begin ()
+input_scrub_begin (void)
{
know (strlen (BEFORE_STRING) == BEFORE_SIZE);
know (strlen (AFTER_STRING) == AFTER_SIZE
@@ -221,7 +219,7 @@ input_scrub_begin ()
}
void
-input_scrub_end ()
+input_scrub_end (void)
{
if (buffer_start)
{
@@ -235,8 +233,7 @@ input_scrub_end ()
Return start of caller's part of buffer. */
char *
-input_scrub_new_file (filename)
- char *filename;
+input_scrub_new_file (char *filename)
{
input_file_open (filename, !flag_no_comments);
physical_input_file = filename[0] ? filename : _("{standard input}");
@@ -251,9 +248,7 @@ input_scrub_new_file (filename)
input_scrub_new_file. */
char *
-input_scrub_include_file (filename, position)
- char *filename;
- char *position;
+input_scrub_include_file (char *filename, char *position)
{
next_saved_file = input_scrub_push (position);
return input_scrub_new_file (filename);
@@ -263,10 +258,7 @@ input_scrub_include_file (filename, position)
expanding a macro. */
void
-input_scrub_include_sb (from, position, is_expansion)
- sb *from;
- char *position;
- int is_expansion;
+input_scrub_include_sb (sb *from, char *position, int is_expansion)
{
if (macro_nest > max_macro_nest)
as_fatal (_("macros nested too deeply"));
@@ -298,14 +290,13 @@ input_scrub_include_sb (from, position, is_expansion)
}
void
-input_scrub_close ()
+input_scrub_close (void)
{
input_file_close ();
}
char *
-input_scrub_next_buffer (bufp)
- char **bufp;
+input_scrub_next_buffer (char **bufp)
{
register char *limit; /*->just after last char of buffer. */
@@ -414,13 +405,13 @@ input_scrub_next_buffer (bufp)
messages and so on. Return TRUE if we opened any file. */
int
-seen_at_least_1_file ()
+seen_at_least_1_file (void)
{
return (physical_input_file != NULL);
}
void
-bump_line_counters ()
+bump_line_counters (void)
{
if (sb_index < 0)
{
@@ -439,9 +430,8 @@ bump_line_counters ()
Returns nonzero if the filename actually changes. */
int
-new_logical_line (fname, line_number)
- char *fname; /* DON'T destroy it! We point to it! */
- int line_number;
+new_logical_line (char *fname, /* DON'T destroy it! We point to it! */
+ int line_number)
{
if (line_number >= 0)
logical_input_line = line_number;
@@ -464,9 +454,7 @@ new_logical_line (fname, line_number)
up declarations like that, and it's easier to avoid it. */
void
-as_where (namep, linep)
- char **namep;
- unsigned int *linep;
+as_where (char **namep, unsigned int *linep)
{
if (logical_input_file != NULL
&& (linep == NULL || logical_input_line >= 0))
@@ -494,8 +482,7 @@ as_where (namep, linep)
No free '\n' at end of line. */
void
-as_howmuch (stream)
- FILE *stream; /* Opened for write please. */
+as_howmuch (FILE *stream /* Opened for write please. */)
{
register char *p; /* Scan input line. */
@@ -511,9 +498,7 @@ as_howmuch (stream)
}
static void
-as_1_char (c, stream)
- unsigned int c;
- FILE *stream;
+as_1_char (unsigned int c, FILE *stream)
{
if (c > 127)
{
diff --git a/contrib/binutils/gas/itbl-ops.c b/contrib/binutils/gas/itbl-ops.c
index 09db9f7..089bff4 100644
--- a/contrib/binutils/gas/itbl-ops.c
+++ b/contrib/binutils/gas/itbl-ops.c
@@ -154,23 +154,21 @@ static struct itbl_entry *entries[e_nprocs][e_ntypes] = {
};
/* local prototypes */
-static unsigned long build_opcode PARAMS ((struct itbl_entry *e));
-static e_type get_type PARAMS ((int yytype));
-static e_processor get_processor PARAMS ((int yyproc));
-static struct itbl_entry **get_entries PARAMS ((e_processor processor,
- e_type type));
-static struct itbl_entry *find_entry_byname PARAMS ((e_processor processor,
- e_type type, char *name));
-static struct itbl_entry *find_entry_byval PARAMS ((e_processor processor,
- e_type type, unsigned long val, struct itbl_range *r));
-static struct itbl_entry *alloc_entry PARAMS ((e_processor processor,
- e_type type, char *name, unsigned long value));
-static unsigned long apply_range PARAMS ((unsigned long value,
- struct itbl_range r));
-static unsigned long extract_range PARAMS ((unsigned long value,
- struct itbl_range r));
-static struct itbl_field *alloc_field PARAMS ((e_type type, int sbit,
- int ebit, unsigned long flags));
+static unsigned long build_opcode (struct itbl_entry *e);
+static e_type get_type (int yytype);
+static e_processor get_processor (int yyproc);
+static struct itbl_entry **get_entries (e_processor processor,
+ e_type type);
+static struct itbl_entry *find_entry_byname (e_processor processor,
+ e_type type, char *name);
+static struct itbl_entry *find_entry_byval (e_processor processor,
+ e_type type, unsigned long val, struct itbl_range *r);
+static struct itbl_entry *alloc_entry (e_processor processor,
+ e_type type, char *name, unsigned long value);
+static unsigned long apply_range (unsigned long value, struct itbl_range r);
+static unsigned long extract_range (unsigned long value, struct itbl_range r);
+static struct itbl_field *alloc_field (e_type type, int sbit,
+ int ebit, unsigned long flags);
/*======================================================================*/
/* Interfaces to the parser */
@@ -351,7 +349,7 @@ append_insns_as_macros (void)
printf (_("Unable to allocate memory for new instructions\n"));
return;
}
- if (size) /* copy prexisting opcodes table */
+ if (size) /* copy preexisting opcodes table */
memcpy (new_opcodes, ITBL_OPCODES, size);
/* FIXME! some NUMOPCODES are calculated expressions.
@@ -372,13 +370,13 @@ append_insns_as_macros (void)
o->name = e->name;
o->args = strdup (form_args (e));
o->mask = apply_range (e->value, e->range);
- /* FIXME how to catch durring assembly? */
+ /* FIXME how to catch during assembly? */
/* mask to identify this insn */
o->match = apply_range (e->value, e->range);
o->pinfo = 0;
#ifdef USE_MACROS
- o->mask = id++; /* FIXME how to catch durring assembly? */
+ o->mask = id++; /* FIXME how to catch during assembly? */
o->match = 0; /* for macros, the insn_isa number */
o->pinfo = INSN_MACRO;
#endif
@@ -616,7 +614,7 @@ itbl_disassemble (char *s, unsigned long insn)
struct itbl_entry *r;
unsigned long value;
- if (f == e->fields) /* First operand is preceeded by tab. */
+ if (f == e->fields) /* First operand is preceded by tab. */
strcat (s, "\t");
else /* ','s separate following operands. */
strcat (s, ",");
diff --git a/contrib/binutils/gas/itbl-ops.h b/contrib/binutils/gas/itbl-ops.h
index bcd68fe..4c98d72 100644
--- a/contrib/binutils/gas/itbl-ops.h
+++ b/contrib/binutils/gas/itbl-ops.h
@@ -86,24 +86,23 @@ extern int itbl_have_entries;
/* These routines are visible to the main part of the assembler */
-int itbl_parse PARAMS ((char *insntbl));
-void itbl_init PARAMS ((void));
-char *itbl_get_field PARAMS ((char **s));
-unsigned long itbl_assemble PARAMS ((char *name, char *operands));
-int itbl_disassemble PARAMS ((char *str, unsigned long insn));
-int itbl_parse PARAMS ((char *tbl)); /* parses insn tbl */
-int itbl_get_reg_val PARAMS ((char *name, unsigned long *pval));
-int itbl_get_val PARAMS ((e_processor processor, e_type type, char *name,
- unsigned long *pval));
-char *itbl_get_name PARAMS ((e_processor processor, e_type type,
- unsigned long val));
+int itbl_parse (char *insntbl);
+void itbl_init (void);
+char *itbl_get_field (char **s);
+unsigned long itbl_assemble (char *name, char *operands);
+int itbl_disassemble (char *str, unsigned long insn);
+int itbl_parse (char *tbl); /* parses insn tbl */
+int itbl_get_reg_val (char *name, unsigned long *pval);
+int itbl_get_val (e_processor processor, e_type type, char *name,
+ unsigned long *pval);
+char *itbl_get_name (e_processor processor, e_type type, unsigned long val);
/* These routines are called by the table parser used to build the
dynamic list of new processor instructions and registers. */
-struct itbl_entry *itbl_add_reg PARAMS ((int yyproc, int yytype,
- char *regname, int regnum));
-struct itbl_entry *itbl_add_insn PARAMS ((int yyproc, char *name,
- unsigned long value, int sbit, int ebit, unsigned long flags));
-struct itbl_field *itbl_add_operand PARAMS ((struct itbl_entry * e, int yytype,
- int sbit, int ebit, unsigned long flags));
+struct itbl_entry *itbl_add_reg (int yyproc, int yytype,
+ char *regname, int regnum);
+struct itbl_entry *itbl_add_insn (int yyproc, char *name,
+ unsigned long value, int sbit, int ebit, unsigned long flags);
+struct itbl_field *itbl_add_operand (struct itbl_entry * e, int yytype,
+ int sbit, int ebit, unsigned long flags);
diff --git a/contrib/binutils/gas/listing.c b/contrib/binutils/gas/listing.c
index 7510d85..aa22c5e 100644
--- a/contrib/binutils/gas/listing.c
+++ b/contrib/binutils/gas/listing.c
@@ -1,27 +1,26 @@
-/* listing.c - mainting assembly listings
+/* listing.c - maintain assembly listings
Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
- 2001, 2002
+ 2001, 2002, 2003
Free Software Foundation, Inc.
-This file is part of GAS, the GNU Assembler.
+ This file is part of GAS, the GNU Assembler.
-GAS is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
+ GAS is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
-GAS is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ GAS is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with GAS; see the file COPYING. If not, write to the Free
-Software Foundation, 59 Temple Place - Suite 330, Boston, MA
-02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with GAS; see the file COPYING. If not, write to the Free
+ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA. */
-/*
- Contributed by Steve Chamberlain <sac@cygnus.com>
+/* Contributed by Steve Chamberlain <sac@cygnus.com>
A listing page looks like:
@@ -65,7 +64,7 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
The function listing_newline remembers the frag associated with the
newline, and creates a new frag - note that this is wasteful, but not
a big deal, since listing slows things down a lot anyway. The
- function also rememebers when the filename changes.
+ function also remembers when the filename changes.
When all the input has finished, and gas has had a chance to settle
down, the listing is output. This is done by running down the list of
@@ -86,10 +85,9 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
LISTING_LHS_WIDTH_SECOND Number of words for the data on the lhs
for the second line
- LISTING_LHS_CONT_LINES Max number of lines to use up for a continutation
+ LISTING_LHS_CONT_LINES Max number of lines to use up for a continuation
LISTING_RHS_WIDTH Number of chars from the input file to print
- on a line
-*/
+ on a line. */
#include "as.h"
#include "obstack.h"
@@ -119,7 +117,8 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
#endif
/* This structure remembers which .s were used. */
-typedef struct file_info_struct {
+typedef struct file_info_struct
+{
struct file_info_struct * next;
char * filename;
long pos;
@@ -127,14 +126,16 @@ typedef struct file_info_struct {
int at_end;
} file_info_type;
-/* This structure rememebrs which line from which file goes into which
+/* This structure remembers which line from which file goes into which
frag. */
-struct list_info_struct {
+struct list_info_struct
+{
/* Frag which this line of source is nearest to. */
fragS *frag;
/* The actual line in the source file. */
unsigned int line;
+
/* Pointer to the file info struct for the file which this line
belongs to. */
file_info_type *file;
@@ -148,21 +149,23 @@ struct list_info_struct {
/* Pointer to the file info struct for the high level language
source line that belongs here. */
file_info_type *hll_file;
+
/* High level language source line. */
unsigned int hll_line;
/* Pointer to any error message associated with this line. */
char *message;
- enum {
- EDICT_NONE,
- EDICT_SBTTL,
- EDICT_TITLE,
- EDICT_NOLIST,
- EDICT_LIST,
- EDICT_NOLIST_NEXT,
- EDICT_EJECT
- } edict;
+ enum
+ {
+ EDICT_NONE,
+ EDICT_SBTTL,
+ EDICT_TITLE,
+ EDICT_NOLIST,
+ EDICT_LIST,
+ EDICT_NOLIST_NEXT,
+ EDICT_EJECT
+ } edict;
char *edict_arg;
/* Nonzero if this line is to be omitted because it contains
@@ -204,27 +207,20 @@ static FILE *list_file;
static char *data_buffer;
/* Prototypes. */
-static void listing_message PARAMS ((const char *name, const char *message));
-static file_info_type *file_info PARAMS ((const char *file_name));
-static void new_frag PARAMS ((void));
-static char *buffer_line PARAMS ((file_info_type *file,
- char *line, unsigned int size));
-static void listing_page PARAMS ((list_info_type *list));
-static unsigned int calc_hex PARAMS ((list_info_type *list));
-static void print_lines PARAMS ((list_info_type *, unsigned int,
- char *, unsigned int));
-static void list_symbol_table PARAMS ((void));
-static void print_source PARAMS ((file_info_type *current_file,
- list_info_type *list,
- char *buffer,
- unsigned int width));
-static int debugging_pseudo PARAMS ((list_info_type *, const char *));
-static void listing_listing PARAMS ((char *name));
+static void listing_message (const char *, const char *);
+static file_info_type *file_info (const char *);
+static void new_frag (void);
+static char *buffer_line (file_info_type *, char *, unsigned int);
+static void listing_page (list_info_type *);
+static unsigned int calc_hex (list_info_type *);
+static void print_lines (list_info_type *, unsigned int, char *, unsigned int);
+static void list_symbol_table (void);
+static void print_source (file_info_type *, list_info_type *, char *, unsigned int);
+static int debugging_pseudo (list_info_type *, const char *);
+static void listing_listing (char *);
static void
-listing_message (name, message)
- const char *name;
- const char *message;
+listing_message (const char *name, const char *message)
{
if (listing_tail != (list_info_type *) NULL)
{
@@ -237,22 +233,19 @@ listing_message (name, message)
}
void
-listing_warning (message)
- const char *message;
+listing_warning (const char *message)
{
listing_message (_("Warning:"), message);
}
void
-listing_error (message)
- const char *message;
+listing_error (const char *message)
{
listing_message (_("Error:"), message);
}
static file_info_type *
-file_info (file_name)
- const char *file_name;
+file_info (const char *file_name)
{
/* Find an entry with this file name. */
file_info_type *p = file_info_head;
@@ -265,8 +258,7 @@ file_info (file_name)
}
/* Make new entry. */
-
- p = (file_info_type *) xmalloc (sizeof (file_info_type));
+ p = xmalloc (sizeof (file_info_type));
p->next = file_info_head;
file_info_head = p;
p->filename = xstrdup (file_name);
@@ -278,17 +270,14 @@ file_info (file_name)
}
static void
-new_frag ()
+new_frag (void)
{
-
frag_wane (frag_now);
frag_new (0);
-
}
void
-listing_newline (ps)
- char *ps;
+listing_newline (char *ps)
{
char *file;
unsigned int line;
@@ -382,7 +371,7 @@ listing_newline (ps)
}
else
{
- new = (list_info_type *) xmalloc (sizeof (list_info_type));
+ new = xmalloc (sizeof (list_info_type));
new->line_contents = ps;
}
@@ -432,7 +421,7 @@ listing_newline (ps)
with the new instruction. */
void
-listing_prev_line ()
+listing_prev_line (void)
{
list_info_type *l;
fragS *f;
@@ -459,10 +448,7 @@ listing_prev_line ()
file to make. */
static char *
-buffer_line (file, line, size)
- file_info_type *file;
- char *line;
- unsigned int size;
+buffer_line (file_info_type *file, char *line, unsigned int size)
{
unsigned int count = 0;
int c;
@@ -533,8 +519,7 @@ static char *subtitle; /* Current subtitle */
static unsigned int on_page; /* Number of lines printed on current page */
static void
-listing_page (list)
- list_info_type *list;
+listing_page (list_info_type *list)
{
/* Grope around, see if we can see a title or subtitle edict coming up
soon. (we look down 10 lines of the page and see if it's there) */
@@ -577,8 +562,7 @@ listing_page (list)
}
static unsigned int
-calc_hex (list)
- list_info_type *list;
+calc_hex (list_info_type *list)
{
int data_buffer_size;
list_info_type *first = list;
@@ -605,9 +589,7 @@ calc_hex (list)
&& data_buffer_size < MAX_BYTES - 3)
{
if (address == ~(unsigned int) 0)
- {
- address = frag_ptr->fr_address / OCTETS_PER_BYTE;
- }
+ address = frag_ptr->fr_address / OCTETS_PER_BYTE;
sprintf (data_buffer + data_buffer_size,
"%02X",
@@ -626,9 +608,8 @@ calc_hex (list)
&& data_buffer_size < MAX_BYTES - 3)
{
if (address == ~(unsigned int) 0)
- {
- address = frag_ptr->fr_address / OCTETS_PER_BYTE;
- }
+ address = frag_ptr->fr_address / OCTETS_PER_BYTE;
+
sprintf (data_buffer + data_buffer_size,
"%02X",
(frag_ptr->fr_literal[var_rep_idx]) & 0xff);
@@ -653,11 +634,8 @@ calc_hex (list)
}
static void
-print_lines (list, lineno, string, address)
- list_info_type *list;
- unsigned int lineno;
- char *string;
- unsigned int address;
+print_lines (list_info_type *list, unsigned int lineno,
+ char *string, unsigned int address)
{
unsigned int idx;
unsigned int nchars;
@@ -761,7 +739,7 @@ print_lines (list, lineno, string, address)
}
static void
-list_symbol_table ()
+list_symbol_table (void)
{
extern symbolS *symbol_rootP;
int got_some = 0;
@@ -869,11 +847,8 @@ list_symbol_table ()
}
static void
-print_source (current_file, list, buffer, width)
- file_info_type *current_file;
- list_info_type *list;
- char *buffer;
- unsigned int width;
+print_source (file_info_type *current_file, list_info_type *list,
+ char *buffer, unsigned int width)
{
if (!current_file->at_end)
{
@@ -881,6 +856,7 @@ print_source (current_file, list, buffer, width)
&& !current_file->at_end)
{
char *p = buffer_line (current_file, buffer, width);
+
fprintf (list_file, "%4u:%-13s **** %s\n", current_file->linenum,
current_file->filename, p);
on_page++;
@@ -893,9 +869,7 @@ print_source (current_file, list, buffer, width)
records inserted by the compiler, see if the line is suspicious. */
static int
-debugging_pseudo (list, line)
- list_info_type *list;
- const char *line;
+debugging_pseudo (list_info_type *list, const char *line)
{
static int in_debug;
int was_debug;
@@ -955,7 +929,6 @@ debugging_pseudo (list, line)
return 1;
if (strncmp (line, "tag", 3) == 0)
return 1;
-
if (strncmp (line, "stabs", 5) == 0)
return 1;
if (strncmp (line, "stabn", 5) == 0)
@@ -965,8 +938,7 @@ debugging_pseudo (list, line)
}
static void
-listing_listing (name)
- char *name ATTRIBUTE_UNUSED;
+listing_listing (char *name ATTRIBUTE_UNUSED)
{
list_info_type *list = head;
file_info_type *current_hll_file = (file_info_type *) NULL;
@@ -986,7 +958,6 @@ listing_listing (name)
if (list->next)
list->frag = list->next->frag;
list = list->next;
-
}
list = head->next;
@@ -1048,24 +1019,19 @@ listing_listing (name)
message = 0;
if (list->hll_file)
- {
- current_hll_file = list->hll_file;
- }
+ current_hll_file = list->hll_file;
if (current_hll_file && list->hll_line && (listing & LISTING_HLL))
- {
- print_source (current_hll_file, list, buffer, width);
- }
+ print_source (current_hll_file, list, buffer, width);
if (list->line_contents)
{
if (!((listing & LISTING_NODEBUG)
&& debugging_pseudo (list, list->line_contents)))
- {
- print_lines (list,
- list->file->linenum == 0 ? list->line : list->file->linenum,
- list->line_contents, calc_hex (list));
- }
+ print_lines (list,
+ list->file->linenum == 0 ? list->line : list->file->linenum,
+ list->line_contents, calc_hex (list));
+
free (list->line_contents);
list->line_contents = NULL;
}
@@ -1090,9 +1056,7 @@ listing_listing (name)
}
if (list->edict == EDICT_EJECT)
- {
- eject = 1;
- }
+ eject = 1;
}
if (list->edict == EDICT_NOLIST_NEXT && show_listing == 1)
@@ -1107,8 +1071,7 @@ listing_listing (name)
}
void
-listing_print (name)
- char *name;
+listing_print (char *name)
{
int using_stdout;
@@ -1127,6 +1090,9 @@ listing_print (name)
using_stdout = 0;
else
{
+#ifdef BFD_ASSEMBLER
+ bfd_set_error (bfd_error_system_call);
+#endif
as_perror (_("can't open list file: %s"), name);
list_file = stdout;
using_stdout = 1;
@@ -1134,50 +1100,44 @@ listing_print (name)
}
if (listing & LISTING_NOFORM)
- {
- paper_height = 0;
- }
+ paper_height = 0;
if (listing & LISTING_LISTING)
- {
- listing_listing (name);
- }
+ listing_listing (name);
if (listing & LISTING_SYMBOLS)
- {
- list_symbol_table ();
- }
+ list_symbol_table ();
if (! using_stdout)
{
if (fclose (list_file) == EOF)
- as_perror (_("error closing list file: %s"), name);
+ {
+#ifdef BFD_ASSEMBLER
+ bfd_set_error (bfd_error_system_call);
+#endif
+ as_perror (_("error closing list file: %s"), name);
+ }
}
if (last_open_file)
- {
- fclose (last_open_file);
- }
+ fclose (last_open_file);
}
void
-listing_file (name)
- const char *name;
+listing_file (const char *name)
{
fn = name;
}
void
-listing_eject (ignore)
- int ignore ATTRIBUTE_UNUSED;
+listing_eject (int ignore ATTRIBUTE_UNUSED)
{
if (listing)
listing_tail->edict = EDICT_EJECT;
}
void
-listing_flags (ignore)
- int ignore ATTRIBUTE_UNUSED;
+listing_flags (int ignore ATTRIBUTE_UNUSED)
{
while ((*input_line_pointer++) && (*input_line_pointer != '\n'))
input_line_pointer++;
@@ -1190,8 +1150,7 @@ listing_flags (ignore)
the current line should be listed, but the next line should not. */
void
-listing_list (on)
- int on;
+listing_list (int on)
{
if (listing)
{
@@ -1220,8 +1179,7 @@ listing_list (on)
}
void
-listing_psize (width_only)
- int width_only;
+listing_psize (int width_only)
{
if (! width_only)
{
@@ -1248,15 +1206,13 @@ listing_psize (width_only)
}
void
-listing_nopage (ignore)
- int ignore ATTRIBUTE_UNUSED;
+listing_nopage (int ignore ATTRIBUTE_UNUSED)
{
paper_height = 0;
}
void
-listing_title (depth)
- int depth;
+listing_title (int depth)
{
int quoted;
char *start;
@@ -1308,8 +1264,7 @@ listing_title (depth)
}
void
-listing_source_line (line)
- unsigned int line;
+listing_source_line (unsigned int line)
{
if (listing)
{
@@ -1320,8 +1275,7 @@ listing_source_line (line)
}
void
-listing_source_file (file)
- const char *file;
+listing_source_file (const char *file)
{
if (listing)
listing_tail->hll_file = file_info (file);
@@ -1332,73 +1286,59 @@ listing_source_file (file)
/* Dummy functions for when compiled without listing enabled. */
void
-listing_flags (ignore)
- int ignore;
+listing_flags (int ignore)
{
s_ignore (0);
}
void
-listing_list (on)
- int on;
+listing_list (int on)
{
s_ignore (0);
}
void
-listing_eject (ignore)
- int ignore;
+listing_eject (int ignore)
{
s_ignore (0);
}
void
-listing_psize (ignore)
- int ignore;
+listing_psize (int ignore)
{
s_ignore (0);
}
void
-listing_nopage (ignore)
- int ignore;
+listing_nopage (int ignore)
{
s_ignore (0);
}
void
-listing_title (depth)
- int depth;
+listing_title (int depth)
{
s_ignore (0);
}
void
-listing_file (name)
- const char *name;
+listing_file (const char *name)
{
-
}
void
-listing_newline (name)
- char *name;
+listing_newline (char *name)
{
-
}
void
-listing_source_line (n)
- unsigned int n;
+listing_source_line (unsigned int n)
{
-
}
void
-listing_source_file (n)
- const char *n;
+listing_source_file (const char *n)
{
-
}
#endif
diff --git a/contrib/binutils/gas/listing.h b/contrib/binutils/gas/listing.h
index 3301735..424b664 100644
--- a/contrib/binutils/gas/listing.h
+++ b/contrib/binutils/gas/listing.h
@@ -41,21 +41,21 @@
#define LISTING_SKIP_COND() ((listing & LISTING_NOCOND) != 0)
-void listing_eject PARAMS ((int));
-void listing_error PARAMS ((const char *message));
-void listing_file PARAMS ((const char *name));
-void listing_flags PARAMS ((int));
-void listing_list PARAMS ((int on));
-void listing_newline PARAMS ((char *ps));
-void listing_prev_line PARAMS ((void));
-void listing_print PARAMS ((char *name));
-void listing_psize PARAMS ((int));
-void listing_nopage PARAMS ((int));
-void listing_source_file PARAMS ((const char *));
-void listing_source_line PARAMS ((unsigned int));
-void listing_title PARAMS ((int depth));
-void listing_warning PARAMS ((const char *message));
-void listing_width PARAMS ((unsigned int x));
+void listing_eject (int);
+void listing_error (const char *message);
+void listing_file (const char *name);
+void listing_flags (int);
+void listing_list (int on);
+void listing_newline (char *ps);
+void listing_prev_line (void);
+void listing_print (char *name);
+void listing_psize (int);
+void listing_nopage (int);
+void listing_source_file (const char *);
+void listing_source_line (unsigned int);
+void listing_title (int depth);
+void listing_warning (const char *message);
+void listing_width (unsigned int x);
extern int listing_lhs_width;
extern int listing_lhs_width_second;
diff --git a/contrib/binutils/gas/macro.c b/contrib/binutils/gas/macro.c
index 0842431..0991744 100644
--- a/contrib/binutils/gas/macro.c
+++ b/contrib/binutils/gas/macro.c
@@ -1,5 +1,5 @@
-/* macro.c - macro support for gas and gasp
- Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
+/* macro.c - macro support for gas
+ Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Steve and Judy Chamberlain of Cygnus Support,
@@ -63,20 +63,19 @@ extern void *alloca ();
#include "asintl.h"
/* The routines in this file handle macro definition and expansion.
- They are called by both gasp and gas. */
+ They are called by gas. */
/* Internal functions. */
-static int get_token PARAMS ((int, sb *, sb *));
-static int getstring PARAMS ((int, sb *, sb *));
-static int get_any_string PARAMS ((int, sb *, sb *, int, int));
-static int do_formals PARAMS ((macro_entry *, int, sb *));
-static int get_apost_token PARAMS ((int, sb *, sb *, int));
-static int sub_actual
- PARAMS ((int, sb *, sb *, struct hash_control *, int, sb *, int));
+static int get_token (int, sb *, sb *);
+static int getstring (int, sb *, sb *);
+static int get_any_string (int, sb *, sb *, int, int);
+static int do_formals (macro_entry *, int, sb *);
+static int get_apost_token (int, sb *, sb *, int);
+static int sub_actual (int, sb *, sb *, struct hash_control *, int, sb *, int);
static const char *macro_expand_body
- PARAMS ((sb *, sb *, formal_entry *, struct hash_control *, int, int));
-static const char *macro_expand PARAMS ((int, sb *, macro_entry *, sb *, int));
+ (sb *, sb *, formal_entry *, struct hash_control *, int);
+static const char *macro_expand (int, sb *, macro_entry *, sb *);
#define ISWHITE(x) ((x) == ' ' || (x) == '\t')
@@ -93,13 +92,13 @@ static const char *macro_expand PARAMS ((int, sb *, macro_entry *, sb *, int));
/* The macro hash table. */
-static struct hash_control *macro_hash;
+struct hash_control *macro_hash;
/* Whether any macros have been defined. */
int macro_defined;
-/* Whether we are in GASP alternate mode. */
+/* Whether we are in alternate syntax mode. */
static int macro_alternate;
@@ -113,7 +112,7 @@ static int macro_strip_at;
/* Function to use to parse an expression. */
-static int (*macro_expr) PARAMS ((const char *, int, sb *, int *));
+static int (*macro_expr) (const char *, int, sb *, int *);
/* Number of macro expansions that have been done. */
@@ -122,11 +121,8 @@ static int macro_number;
/* Initialize macro processing. */
void
-macro_init (alternate, mri, strip_at, expr)
- int alternate;
- int mri;
- int strip_at;
- int (*expr) PARAMS ((const char *, int, sb *, int *));
+macro_init (int alternate, int mri, int strip_at,
+ int (*expr) (const char *, int, sb *, int *))
{
macro_hash = hash_new ();
macro_defined = 0;
@@ -139,8 +135,7 @@ macro_init (alternate, mri, strip_at, expr)
/* Switch in and out of MRI mode on the fly. */
void
-macro_mri_mode (mri)
- int mri;
+macro_mri_mode (int mri)
{
macro_mri = mri;
}
@@ -152,11 +147,8 @@ macro_mri_mode (mri)
Return 1 on success, 0 on unexpected EOF. */
int
-buffer_and_nest (from, to, ptr, get_line)
- const char *from;
- const char *to;
- sb *ptr;
- int (*get_line) PARAMS ((sb *));
+buffer_and_nest (const char *from, const char *to, sb *ptr,
+ int (*get_line) (sb *))
{
int from_len = strlen (from);
int to_len = strlen (to);
@@ -222,8 +214,8 @@ buffer_and_nest (from, to, ptr, get_line)
}
}
- /* Add a CR to the end and keep running. */
- sb_add_char (ptr, '\n');
+ /* Add the original end-of-line char to the end and keep running. */
+ sb_add_char (ptr, more);
line_start = ptr->len;
more = get_line (ptr);
}
@@ -235,10 +227,7 @@ buffer_and_nest (from, to, ptr, get_line)
/* Pick up a token. */
static int
-get_token (idx, in, name)
- int idx;
- sb *in;
- sb *name;
+get_token (int idx, sb *in, sb *name)
{
if (idx < in->len
&& (ISALPHA (in->ptr[idx])
@@ -263,10 +252,7 @@ get_token (idx, in, name)
/* Pick up a string. */
static int
-getstring (idx, in, acc)
- int idx;
- sb *in;
- sb *acc;
+getstring (int idx, sb *in, sb *acc)
{
idx = sb_skip_white (idx, in);
@@ -354,19 +340,14 @@ getstring (idx, in, acc)
*/
static int
-get_any_string (idx, in, out, expand, pretend_quoted)
- int idx;
- sb *in;
- sb *out;
- int expand;
- int pretend_quoted;
+get_any_string (int idx, sb *in, sb *out, int expand, int pretend_quoted)
{
sb_reset (out);
idx = sb_skip_white (idx, in);
if (idx < in->len)
{
- if (in->len > 2 && in->ptr[idx + 1] == '\'' && ISBASE (in->ptr[idx]))
+ if (in->len > idx + 2 && in->ptr[idx + 1] == '\'' && ISBASE (in->ptr[idx]))
{
while (!ISSEP (in->ptr[idx]))
sb_add_char (out, in->ptr[idx++]);
@@ -439,10 +420,7 @@ get_any_string (idx, in, out, expand, pretend_quoted)
/* Pick up the formal parameters of a macro definition. */
static int
-do_formals (macro, idx, in)
- macro_entry *macro;
- int idx;
- sb *in;
+do_formals (macro_entry *macro, int idx, sb *in)
{
formal_entry **p = &macro->formals;
@@ -522,12 +500,8 @@ do_formals (macro, idx, in)
the macro which was defined. */
const char *
-define_macro (idx, in, label, get_line, namep)
- int idx;
- sb *in;
- sb *label;
- int (*get_line) PARAMS ((sb *));
- const char **namep;
+define_macro (int idx, sb *in, sb *label,
+ int (*get_line) (sb *), const char **namep)
{
macro_entry *macro;
sb name;
@@ -583,11 +557,7 @@ define_macro (idx, in, label, get_line, namep)
/* Scan a token, and then skip KIND. */
static int
-get_apost_token (idx, in, name, kind)
- int idx;
- sb *in;
- sb *name;
- int kind;
+get_apost_token (int idx, sb *in, sb *name, int kind)
{
idx = get_token (idx, in, name);
if (idx < in->len
@@ -601,14 +571,8 @@ get_apost_token (idx, in, name, kind)
/* Substitute the actual value for a formal parameter. */
static int
-sub_actual (start, in, t, formal_hash, kind, out, copyifnotthere)
- int start;
- sb *in;
- sb *t;
- struct hash_control *formal_hash;
- int kind;
- sb *out;
- int copyifnotthere;
+sub_actual (int start, sb *in, sb *t, struct hash_control *formal_hash,
+ int kind, sb *out, int copyifnotthere)
{
int src;
formal_entry *ptr;
@@ -637,6 +601,7 @@ sub_actual (start, in, t, formal_hash, kind, out, copyifnotthere)
{
/* Doing this permits people to use & in macro bodies. */
sb_add_char (out, '&');
+ sb_add_sb (out, t);
}
else if (copyifnotthere)
{
@@ -653,13 +618,8 @@ sub_actual (start, in, t, formal_hash, kind, out, copyifnotthere)
/* Expand the body of a macro. */
static const char *
-macro_expand_body (in, out, formals, formal_hash, comment_char, locals)
- sb *in;
- sb *out;
- formal_entry *formals;
- struct hash_control *formal_hash;
- int comment_char;
- int locals;
+macro_expand_body (sb *in, sb *out, formal_entry *formals,
+ struct hash_control *formal_hash, int locals)
{
sb t;
int src = 0;
@@ -689,14 +649,7 @@ macro_expand_body (in, out, formals, formal_hash, comment_char, locals)
else if (in->ptr[src] == '\\')
{
src++;
- if (in->ptr[src] == comment_char && comment_char != '\0')
- {
- /* This is a comment, just drop the rest of the line. */
- while (src < in->len
- && in->ptr[src] != '\n')
- src++;
- }
- else if (in->ptr[src] == '(')
+ if (in->ptr[src] == '(')
{
/* Sub in till the next ')' literally. */
src++;
@@ -779,7 +732,7 @@ macro_expand_body (in, out, formals, formal_hash, comment_char, locals)
formal_entry *f;
src = sb_skip_white (src + 5, in);
- while (in->ptr[src] != '\n' && in->ptr[src] != comment_char)
+ while (in->ptr[src] != '\n')
{
static int loccnt;
char buf[20];
@@ -806,17 +759,6 @@ macro_expand_body (in, out, formals, formal_hash, comment_char, locals)
}
}
}
- else if (comment_char != '\0'
- && in->ptr[src] == comment_char
- && src + 1 < in->len
- && in->ptr[src + 1] == comment_char
- && !inquote)
- {
- /* Two comment chars in a row cause the rest of the line to
- be dropped. */
- while (src < in->len && in->ptr[src] != '\n')
- src++;
- }
else if (in->ptr[src] == '"'
|| (macro_mri && in->ptr[src] == '\''))
{
@@ -899,12 +841,7 @@ macro_expand_body (in, out, formals, formal_hash, comment_char, locals)
body. */
static const char *
-macro_expand (idx, in, m, out, comment_char)
- int idx;
- sb *in;
- macro_entry *m;
- sb *out;
- int comment_char;
+macro_expand (int idx, sb *in, macro_entry *m, sb *out)
{
sb t;
formal_entry *ptr;
@@ -954,7 +891,7 @@ macro_expand (idx, in, m, out, comment_char)
/* Peel off the actuals and store them away in the hash tables' actuals. */
idx = sb_skip_white (idx, in);
- while (idx < in->len && in->ptr[idx] != comment_char)
+ while (idx < in->len)
{
int scan;
@@ -1056,8 +993,7 @@ macro_expand (idx, in, m, out, comment_char)
sb_add_string (&ptr->actual, buffer);
}
- err = macro_expand_body (&m->sub, out, m->formals, m->formal_hash,
- comment_char, 1);
+ err = macro_expand_body (&m->sub, out, m->formals, m->formal_hash, 1);
if (err != NULL)
return err;
@@ -1090,16 +1026,11 @@ macro_expand (idx, in, m, out, comment_char)
}
/* Check for a macro. If one is found, put the expansion into
- *EXPAND. COMMENT_CHAR is the comment character--this is used by
- gasp. Return 1 if a macro is found, 0 otherwise. */
+ *EXPAND. Return 1 if a macro is found, 0 otherwise. */
int
-check_macro (line, expand, comment_char, error, info)
- const char *line;
- sb *expand;
- int comment_char;
- const char **error;
- macro_entry **info;
+check_macro (const char *line, sb *expand,
+ const char **error, macro_entry **info)
{
const char *s;
char *copy, *cs;
@@ -1135,7 +1066,7 @@ check_macro (line, expand, comment_char, error, info)
sb_add_char (&line_sb, *s++);
sb_new (expand);
- *error = macro_expand (0, &line_sb, macro, expand, comment_char);
+ *error = macro_expand (0, &line_sb, macro, expand);
sb_kill (&line_sb);
@@ -1149,8 +1080,7 @@ check_macro (line, expand, comment_char, error, info)
/* Delete a macro. */
void
-delete_macro (name)
- const char *name;
+delete_macro (const char *name)
{
hash_delete (macro_hash, name);
}
@@ -1160,13 +1090,7 @@ delete_macro (name)
success, or an error message otherwise. */
const char *
-expand_irp (irpc, idx, in, out, get_line, comment_char)
- int irpc;
- int idx;
- sb *in;
- sb *out;
- int (*get_line) PARAMS ((sb *));
- int comment_char;
+expand_irp (int irpc, int idx, sb *in, sb *out, int (*get_line) (sb *))
{
const char *mn;
sb sub;
@@ -1204,10 +1128,10 @@ expand_irp (irpc, idx, in, out, get_line, comment_char)
sb_reset (out);
idx = sb_skip_comma (idx, in);
- if (idx >= in->len || in->ptr[idx] == comment_char)
+ if (idx >= in->len)
{
/* Expand once with a null string. */
- err = macro_expand_body (&sub, out, &f, h, comment_char, 0);
+ err = macro_expand_body (&sub, out, &f, h, 0);
if (err != NULL)
return err;
}
@@ -1215,7 +1139,7 @@ expand_irp (irpc, idx, in, out, get_line, comment_char)
{
if (irpc && in->ptr[idx] == '"')
++idx;
- while (idx < in->len && in->ptr[idx] != comment_char)
+ while (idx < in->len)
{
if (!irpc)
idx = get_any_string (idx, in, &f.actual, 1, 0);
@@ -1226,7 +1150,7 @@ expand_irp (irpc, idx, in, out, get_line, comment_char)
int nxt;
nxt = sb_skip_white (idx + 1, in);
- if (nxt >= in->len || in->ptr[nxt] == comment_char)
+ if (nxt >= in->len)
{
idx = nxt;
break;
@@ -1236,7 +1160,7 @@ expand_irp (irpc, idx, in, out, get_line, comment_char)
sb_add_char (&f.actual, in->ptr[idx]);
++idx;
}
- err = macro_expand_body (&sub, out, &f, h, comment_char, 0);
+ err = macro_expand_body (&sub, out, &f, h, 0);
if (err != NULL)
return err;
if (!irpc)
diff --git a/contrib/binutils/gas/macro.h b/contrib/binutils/gas/macro.h
index b9dc2d0..a8bffaa 100644
--- a/contrib/binutils/gas/macro.h
+++ b/contrib/binutils/gas/macro.h
@@ -1,5 +1,5 @@
-/* macro.h - header file for macro support for gas and gasp
- Copyright 1994, 1995, 1996, 1997, 1998, 2000
+/* macro.h - header file for macro support for gas
+ Copyright 1994, 1995, 1996, 1997, 1998, 2000, 2002
Free Software Foundation, Inc.
Written by Steve and Judy Chamberlain of Cygnus Support,
@@ -35,16 +35,16 @@
list of formal arguments, and also keeps a hash table which points
into the list to speed up formal search. Each formal knows its
name and its default value. Each time the macro is expanded, the
- formals get the actual values attatched to them. */
+ formals get the actual values attached to them. */
-/* describe the formal arguments to a macro */
+/* Describe the formal arguments to a macro. */
typedef struct formal_struct {
- struct formal_struct *next; /* next formal in list */
- sb name; /* name of the formal */
- sb def; /* the default value */
- sb actual; /* the actual argument (changed on each expansion) */
- int index; /* the index of the formal 0..formal_count-1 */
+ struct formal_struct *next; /* Next formal in list. */
+ sb name; /* Name of the formal. */
+ sb def; /* The default value. */
+ sb actual; /* The actual argument (changed on each expansion). */
+ int index; /* The index of the formal 0..formal_count - 1. */
} formal_entry;
/* Other values found in the index field of a formal_entry. */
@@ -52,13 +52,14 @@ typedef struct formal_struct {
#define NARG_INDEX (-2)
#define LOCAL_INDEX (-3)
-/* describe the macro. */
+/* Describe the macro. */
-typedef struct macro_struct {
- sb sub; /* substitution text. */
- int formal_count; /* number of formal args. */
- formal_entry *formals; /* pointer to list of formal_structs */
- struct hash_control *formal_hash; /* hash table of formals. */
+typedef struct macro_struct
+{
+ sb sub; /* Substitution text. */
+ int formal_count; /* Number of formal args. */
+ formal_entry *formals; /* Pointer to list of formal_structs. */
+ struct hash_control *formal_hash; /* Hash table of formals. */
} macro_entry;
/* Whether any macros have been defined. */
@@ -69,19 +70,14 @@ extern int macro_defined;
extern int macro_nest;
-extern int buffer_and_nest
- PARAMS ((const char *, const char *, sb *, int (*) PARAMS ((sb *))));
+extern int buffer_and_nest (const char *, const char *, sb *, int (*) (sb *));
extern void macro_init
- PARAMS ((int alternate, int mri, int strip_at,
- int (*) PARAMS ((const char *, int, sb *, int *))));
-extern void macro_mri_mode PARAMS ((int));
+ (int, int, int, int (*) (const char *, int, sb *, int *));
+extern void macro_mri_mode (int);
extern const char *define_macro
- PARAMS ((int idx, sb *in, sb *label, int (*get_line) PARAMS ((sb *)),
- const char **namep));
-extern int check_macro PARAMS ((const char *, sb *, int, const char **,
- macro_entry **));
-extern void delete_macro PARAMS ((const char *));
-extern const char *expand_irp
- PARAMS ((int, int, sb *, sb *, int (*) PARAMS ((sb *)), int));
+ (int, sb *, sb *, int (*) (sb *), const char **);
+extern int check_macro (const char *, sb *, const char **, macro_entry **);
+extern void delete_macro (const char *);
+extern const char *expand_irp (int, int, sb *, sb *, int (*) (sb *));
#endif
diff --git a/contrib/binutils/gas/messages.c b/contrib/binutils/gas/messages.c
index e85deec..005cd22 100644
--- a/contrib/binutils/gas/messages.c
+++ b/contrib/binutils/gas/messages.c
@@ -1,5 +1,5 @@
/* messages.c - error reporter -
- Copyright 1987, 1991, 1992, 1993, 1994, 1995, 1996, 1998, 2000, 2001
+ Copyright 1987, 1991, 1992, 1993, 1994, 1995, 1996, 1998, 2000, 2001, 2003
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -42,53 +42,52 @@ typedef int * va_list;
#define va_end(ARGS)
#endif
-static void identify PARAMS ((char *));
-static void as_show_where PARAMS ((void));
-static void as_warn_internal PARAMS ((char *, unsigned int, char *));
-static void as_bad_internal PARAMS ((char *, unsigned int, char *));
+static void identify (char *);
+static void as_show_where (void);
+static void as_warn_internal (char *, unsigned int, char *);
+static void as_bad_internal (char *, unsigned int, char *);
/* Despite the rest of the comments in this file, (FIXME-SOON),
- * here is the current scheme for error messages etc:
- *
- * as_fatal() is used when gas is quite confused and
- * continuing the assembly is pointless. In this case we
- * exit immediately with error status.
- *
- * as_bad() is used to mark errors that result in what we
- * presume to be a useless object file. Say, we ignored
- * something that might have been vital. If we see any of
- * these, assembly will continue to the end of the source,
- * no object file will be produced, and we will terminate
- * with error status. The new option, -Z, tells us to
- * produce an object file anyway but we still exit with
- * error status. The assumption here is that you don't want
- * this object file but we could be wrong.
- *
- * as_warn() is used when we have an error from which we
- * have a plausible error recovery. eg, masking the top
- * bits of a constant that is longer than will fit in the
- * destination. In this case we will continue to assemble
- * the source, although we may have made a bad assumption,
- * and we will produce an object file and return normal exit
- * status (ie, no error). The new option -X tells us to
- * treat all as_warn() errors as as_bad() errors. That is,
- * no object file will be produced and we will exit with
- * error status. The idea here is that we don't kill an
- * entire make because of an error that we knew how to
- * correct. On the other hand, sometimes you might want to
- * stop the make at these points.
- *
- * as_tsktsk() is used when we see a minor error for which
- * our error recovery action is almost certainly correct.
- * In this case, we print a message and then assembly
- * continues as though no error occurred.
- */
+ here is the current scheme for error messages etc:
+
+ as_fatal() is used when gas is quite confused and
+ continuing the assembly is pointless. In this case we
+ exit immediately with error status.
+
+ as_bad() is used to mark errors that result in what we
+ presume to be a useless object file. Say, we ignored
+ something that might have been vital. If we see any of
+ these, assembly will continue to the end of the source,
+ no object file will be produced, and we will terminate
+ with error status. The new option, -Z, tells us to
+ produce an object file anyway but we still exit with
+ error status. The assumption here is that you don't want
+ this object file but we could be wrong.
+
+ as_warn() is used when we have an error from which we
+ have a plausible error recovery. eg, masking the top
+ bits of a constant that is longer than will fit in the
+ destination. In this case we will continue to assemble
+ the source, although we may have made a bad assumption,
+ and we will produce an object file and return normal exit
+ status (ie, no error). The new option -X tells us to
+ treat all as_warn() errors as as_bad() errors. That is,
+ no object file will be produced and we will exit with
+ error status. The idea here is that we don't kill an
+ entire make because of an error that we knew how to
+ correct. On the other hand, sometimes you might want to
+ stop the make at these points.
+
+ as_tsktsk() is used when we see a minor error for which
+ our error recovery action is almost certainly correct.
+ In this case, we print a message and then assembly
+ continues as though no error occurred. */
static void
-identify (file)
- char *file;
+identify (char *file)
{
static int identified;
+
if (identified)
return;
identified++;
@@ -108,9 +107,9 @@ identify (file)
static int warning_count;
int
-had_warnings ()
+had_warnings (void)
{
- return (warning_count);
+ return warning_count;
}
/* Nonzero if we've hit a 'bad error', and should not write an obj file,
@@ -119,15 +118,15 @@ had_warnings ()
static int error_count;
int
-had_errors ()
+had_errors (void)
{
- return (error_count);
+ return error_count;
}
/* Print the current location to stderr. */
static void
-as_show_where ()
+as_show_where (void)
{
char *file;
unsigned int line;
@@ -141,14 +140,15 @@ as_show_where ()
/* Like perror(3), but with more info. */
void
-as_perror (gripe, filename)
- const char *gripe; /* Unpunctuated error theme. */
- const char *filename;
+as_perror (const char *gripe, /* Unpunctuated error theme. */
+ const char *filename)
{
const char *errtxt;
+ int saved_errno = errno;
as_show_where ();
fprintf (stderr, gripe, filename);
+ errno = saved_errno;
#ifdef BFD_ASSEMBLER
errtxt = bfd_errmsg (bfd_get_error ());
#else
@@ -198,10 +198,7 @@ as_tsktsk (format, va_alist)
/* The common portion of as_warn and as_warn_where. */
static void
-as_warn_internal (file, line, buffer)
- char *file;
- unsigned int line;
- char *buffer;
+as_warn_internal (char *file, unsigned int line, char *buffer)
{
++warning_count;
@@ -302,10 +299,7 @@ as_warn_where (file, line, format, va_alist)
/* The common portion of as_bad and as_bad_where. */
static void
-as_bad_internal (file, line, buffer)
- char *file;
- unsigned int line;
- char *buffer;
+as_bad_internal (char *file, unsigned int line, char *buffer)
{
++error_count;
@@ -442,9 +436,7 @@ as_fatal (format, va_alist)
Arguments: Filename, line number, optional function name. */
void
-as_assert (file, line, fn)
- const char *file, *fn;
- int line;
+as_assert (const char *file, int line, const char *fn)
{
as_show_where ();
fprintf (stderr, _("Internal error!\n"));
@@ -461,9 +453,7 @@ as_assert (file, line, fn)
and exit without producing a core file. */
void
-as_abort (file, line, fn)
- const char *file, *fn;
- int line;
+as_abort (const char *file, int line, const char *fn)
{
as_show_where ();
if (fn)
@@ -479,9 +469,7 @@ as_abort (file, line, fn)
/* Support routines. */
void
-fprint_value (file, val)
- FILE *file;
- valueT val;
+fprint_value (FILE *file, valueT val)
{
if (sizeof (val) <= sizeof (long))
{
@@ -499,9 +487,7 @@ fprint_value (file, val)
}
void
-sprint_value (buf, val)
- char *buf;
- valueT val;
+sprint_value (char *buf, valueT val)
{
if (sizeof (val) <= sizeof (long))
{
diff --git a/contrib/binutils/gas/obj.h b/contrib/binutils/gas/obj.h
index 846627a..497524a 100644
--- a/contrib/binutils/gas/obj.h
+++ b/contrib/binutils/gas/obj.h
@@ -1,7 +1,7 @@
/* obj.h - defines the object dependent hooks for all object
format backends.
- Copyright 1987, 1990, 1991, 1992, 1993, 1995, 1996, 1997, 1999, 2000
+ Copyright 1987, 1990, 1991, 1992, 1993, 1995, 1996, 1997, 1999, 2000, 2002
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -21,27 +21,27 @@
Software Foundation, 59 Temple Place - Suite 330, Boston, MA
02111-1307, USA. */
-char *obj_default_output_file_name PARAMS ((void));
-void obj_emit_relocations PARAMS ((char **where, fixS * fixP,
- relax_addressT segment_address_in_file));
-void obj_emit_strings PARAMS ((char **where));
-void obj_emit_symbols PARAMS ((char **where, symbolS * symbols));
+char *obj_default_output_file_name (void);
+void obj_emit_relocations (char **where, fixS * fixP,
+ relax_addressT segment_address_in_file);
+void obj_emit_strings (char **where);
+void obj_emit_symbols (char **where, symbolS * symbols);
#ifndef obj_read_begin_hook
-void obj_read_begin_hook PARAMS ((void));
+void obj_read_begin_hook (void);
#endif
#ifndef BFD_ASSEMBLER
-void obj_crawl_symbol_chain PARAMS ((object_headers * headers));
-void obj_header_append PARAMS ((char **where, object_headers * headers));
+void obj_crawl_symbol_chain (object_headers * headers);
+void obj_header_append (char **where, object_headers * headers);
#ifndef obj_pre_write_hook
-void obj_pre_write_hook PARAMS ((object_headers * headers));
+void obj_pre_write_hook (object_headers * headers);
#endif
#endif
#ifndef obj_symbol_new_hook
-void obj_symbol_new_hook PARAMS ((symbolS * symbolP));
+void obj_symbol_new_hook (symbolS * symbolP);
#endif
-void obj_symbol_to_chars PARAMS ((char **where, symbolS * symbolP));
+void obj_symbol_to_chars (char **where, symbolS * symbolP);
extern const pseudo_typeS obj_pseudo_table[];
@@ -50,34 +50,35 @@ struct format_ops {
int flavor;
unsigned dfl_leading_underscore : 1;
unsigned emit_section_symbols : 1;
- void (*begin) PARAMS ((void));
- void (*app_file) PARAMS ((const char *));
- void (*frob_symbol) PARAMS ((symbolS *, int *));
- void (*frob_file) PARAMS ((void));
- void (*frob_file_before_adjust) PARAMS ((void));
- void (*frob_file_after_relocs) PARAMS ((void));
- bfd_vma (*s_get_size) PARAMS ((symbolS *));
- void (*s_set_size) PARAMS ((symbolS *, bfd_vma));
- bfd_vma (*s_get_align) PARAMS ((symbolS *));
- void (*s_set_align) PARAMS ((symbolS *, bfd_vma));
- int (*s_get_other) PARAMS ((symbolS *));
- void (*s_set_other) PARAMS ((symbolS *, int));
- int (*s_get_desc) PARAMS ((symbolS *));
- void (*s_set_desc) PARAMS ((symbolS *, int));
- int (*s_get_type) PARAMS ((symbolS *));
- void (*s_set_type) PARAMS ((symbolS *, int));
- void (*copy_symbol_attributes) PARAMS ((symbolS *, symbolS *));
- void (*generate_asm_lineno) PARAMS ((void));
- void (*process_stab) PARAMS ((segT, int, const char *, int, int, int));
- int (*separate_stab_sections) PARAMS ((void));
- void (*init_stab_section) PARAMS ((segT));
- int (*sec_sym_ok_for_reloc) PARAMS ((asection *));
- void (*pop_insert) PARAMS ((void));
+ void (*begin) (void);
+ void (*app_file) (const char *);
+ void (*frob_symbol) (symbolS *, int *);
+ void (*frob_file) (void);
+ void (*frob_file_before_adjust) (void);
+ void (*frob_file_before_fix) (void);
+ void (*frob_file_after_relocs) (void);
+ bfd_vma (*s_get_size) (symbolS *);
+ void (*s_set_size) (symbolS *, bfd_vma);
+ bfd_vma (*s_get_align) (symbolS *);
+ void (*s_set_align) (symbolS *, bfd_vma);
+ int (*s_get_other) (symbolS *);
+ void (*s_set_other) (symbolS *, int);
+ int (*s_get_desc) (symbolS *);
+ void (*s_set_desc) (symbolS *, int);
+ int (*s_get_type) (symbolS *);
+ void (*s_set_type) (symbolS *, int);
+ void (*copy_symbol_attributes) (symbolS *, symbolS *);
+ void (*generate_asm_lineno) (void);
+ void (*process_stab) (segT, int, const char *, int, int, int);
+ int (*separate_stab_sections) (void);
+ void (*init_stab_section) (segT);
+ int (*sec_sym_ok_for_reloc) (asection *);
+ void (*pop_insert) (void);
/* For configurations using ECOFF_DEBUGGING, this callback is used. */
- void (*ecoff_set_ext) PARAMS ((symbolS *, struct ecoff_extr *));
+ void (*ecoff_set_ext) (symbolS *, struct ecoff_extr *);
- void (*read_begin_hook) PARAMS ((void));
- void (*symbol_new_hook) PARAMS ((symbolS *));
+ void (*read_begin_hook) (void);
+ void (*symbol_new_hook) (symbolS *);
};
extern const struct format_ops elf_format_ops;
diff --git a/contrib/binutils/gas/output-file.c b/contrib/binutils/gas/output-file.c
index 531e35f..4c376b4 100644
--- a/contrib/binutils/gas/output-file.c
+++ b/contrib/binutils/gas/output-file.c
@@ -1,5 +1,5 @@
/* output-file.c - Deal with the output file
- Copyright 1987, 1990, 1991, 1992, 1993, 1994, 1996, 1998, 1999, 2001
+ Copyright 1987, 1990, 1991, 1992, 1993, 1994, 1996, 1998, 1999, 2001, 2003
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -41,8 +41,7 @@
bfd *stdoutput;
void
-output_file_create (name)
- char *name;
+output_file_create (char *name)
{
if (name[0] == '-' && name[1] == '\0')
as_fatal (_("can't open a bfd on stdout %s"), name);
@@ -62,8 +61,7 @@ output_file_create (name)
}
void
-output_file_close (filename)
- char *filename;
+output_file_close (char *filename)
{
#ifdef BFD_ASSEMBLER
/* Close the bfd. */
@@ -86,10 +84,9 @@ output_file_close (filename)
#ifndef BFD_ASSEMBLER
void
-output_file_append (where, length, filename)
- char *where ATTRIBUTE_UNUSED;
- long length ATTRIBUTE_UNUSED;
- char *filename ATTRIBUTE_UNUSED;
+output_file_append (char *where ATTRIBUTE_UNUSED,
+ long length ATTRIBUTE_UNUSED,
+ char *filename ATTRIBUTE_UNUSED)
{
abort ();
}
@@ -100,8 +97,7 @@ output_file_append (where, length, filename)
static FILE *stdoutput;
void
-output_file_create (name)
- char *name;
+output_file_create (char *name)
{
if (name[0] == '-' && name[1] == '\0')
{
@@ -112,17 +108,22 @@ output_file_create (name)
stdoutput = fopen (name, FOPEN_WB);
if (stdoutput == NULL)
{
+#ifdef BFD_ASSEMBLER
+ bfd_set_error (bfd_error_system_call);
+#endif
as_perror (_("FATAL: can't create %s"), name);
exit (EXIT_FAILURE);
}
}
void
-output_file_close (filename)
- char *filename;
+output_file_close (char *filename)
{
if (EOF == fclose (stdoutput))
{
+#ifdef BFD_ASSEMBLER
+ bfd_set_error (bfd_error_system_call);
+#endif
as_perror (_("FATAL: can't close %s"), filename);
exit (EXIT_FAILURE);
}
@@ -132,18 +133,17 @@ output_file_close (filename)
}
void
-output_file_append (where, length, filename)
- char * where;
- long length;
- char * filename;
+output_file_append (char * where, long length, char * filename)
{
for (; length; length--, where++)
{
(void) putc (*where, stdoutput);
if (ferror (stdoutput))
- /* if ( EOF == (putc( *where, stdoutput )) ) */
{
+#ifdef BFD_ASSEMBLER
+ bfd_set_error (bfd_error_system_call);
+#endif
as_perror (_("Failed to emit an object byte"), filename);
as_fatal (_("can't continue"));
}
diff --git a/contrib/binutils/gas/output-file.h b/contrib/binutils/gas/output-file.h
index 48b7a6a..6779e4b 100644
--- a/contrib/binutils/gas/output-file.h
+++ b/contrib/binutils/gas/output-file.h
@@ -19,8 +19,8 @@
along with GAS; see the file COPYING. If not, write to
the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-void output_file_append PARAMS ((char *where, long length, char *filename));
-void output_file_close PARAMS ((char *filename));
-void output_file_create PARAMS ((char *name));
+void output_file_append (char *where, long length, char *filename);
+void output_file_close (char *filename);
+void output_file_create (char *name);
/* end of output-file.h */
diff --git a/contrib/binutils/gas/po/Make-in b/contrib/binutils/gas/po/Make-in
index 0552db1..6176dbf 100644
--- a/contrib/binutils/gas/po/Make-in
+++ b/contrib/binutils/gas/po/Make-in
@@ -24,6 +24,8 @@ gnulocaledir = $(prefix)/share/locale
gettextsrcdir = $(prefix)/share/gettext/po
subdir = po
+DESTDIR =
+
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
MKINSTALLDIRS = @MKINSTALLDIRS@
@@ -111,9 +113,9 @@ install-data: install-data-@USE_NLS@
install-data-no: all
install-data-yes: all
if test -r $(MKINSTALLDIRS); then \
- $(MKINSTALLDIRS) $(datadir); \
+ $(MKINSTALLDIRS) $(DESTDIR)$(datadir); \
else \
- $(top_srcdir)/mkinstalldirs $(datadir); \
+ $(top_srcdir)/mkinstalldirs $(DESTDIR)$(datadir); \
fi
@catalogs='$(CATALOGS)'; \
for cat in $$catalogs; do \
@@ -123,7 +125,7 @@ install-data-yes: all
*) destdir=$(localedir);; \
esac; \
lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
- dir=$$destdir/$$lang/LC_MESSAGES; \
+ dir=$(DESTDIR)$$destdir/$$lang/LC_MESSAGES; \
if test -r $(MKINSTALLDIRS); then \
$(MKINSTALLDIRS) $$dir; \
else \
@@ -153,12 +155,12 @@ install-data-yes: all
done
if test "$(PACKAGE)" = "gettext"; then \
if test -r $(MKINSTALLDIRS); then \
- $(MKINSTALLDIRS) $(gettextsrcdir); \
+ $(MKINSTALLDIRS) $(DESTDIR)$(gettextsrcdir); \
else \
- $(top_srcdir)/mkinstalldirs $(gettextsrcdir); \
+ $(top_srcdir)/mkinstalldirs $(DESTDIR)$(gettextsrcdir); \
fi; \
$(INSTALL_DATA) $(srcdir)/Makefile.in.in \
- $(gettextsrcdir)/Makefile.in.in; \
+ $(DESTDIR)$(gettextsrcdir)/Makefile.in.in; \
else \
: ; \
fi
@@ -171,12 +173,12 @@ uninstall:
for cat in $$catalogs; do \
cat=`basename $$cat`; \
lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
- rm -f $(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
- rm -f $(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
- rm -f $(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
- rm -f $(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
+ rm -f $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
+ rm -f $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
+ rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
+ rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
done
- rm -f $(gettextsrcdir)/po-Makefile.in.in
+ rm -f $(DESTDIR)$(gettextsrcdir)/po-Makefile.in.in
check: all
diff --git a/contrib/binutils/gas/po/POTFILES.in b/contrib/binutils/gas/po/POTFILES.in
index 6f67bf4..e4e3e4e 100644
--- a/contrib/binutils/gas/po/POTFILES.in
+++ b/contrib/binutils/gas/po/POTFILES.in
@@ -78,6 +78,8 @@ config/tc-i960.c
config/tc-i960.h
config/tc-ia64.c
config/tc-ia64.h
+config/tc-ip2k.c
+config/tc-ip2k.h
config/tc-m32r.c
config/tc-m32r.h
config/tc-m68hc11.c
@@ -96,6 +98,8 @@ config/tc-mn10200.c
config/tc-mn10200.h
config/tc-mn10300.c
config/tc-mn10300.h
+config/tc-msp430.c
+config/tc-msp430.h
config/tc-ns32k.c
config/tc-ns32k.h
config/tc-openrisc.c
@@ -110,10 +114,10 @@ config/tc-ppc.c
config/tc-ppc.h
config/tc-s390.c
config/tc-s390.h
-config/tc-sh.c
-config/tc-sh.h
config/tc-sh64.c
config/tc-sh64.h
+config/tc-sh.c
+config/tc-sh.h
config/tc-sparc.c
config/tc-sparc.h
config/tc-tahoe.c
@@ -132,10 +136,15 @@ config/tc-w65.c
config/tc-w65.h
config/tc-xstormy16.c
config/tc-xstormy16.h
+config/tc-xtensa.c
+config/tc-xtensa.h
config/tc-z8k.c
config/tc-z8k.h
depend.c
depend.c
+dw2gencfi.c
+dw2gencfi.c
+dw2gencfi.h
dwarf2dbg.c
dwarf2dbg.c
dwarf2dbg.h
@@ -144,22 +153,21 @@ ecoff.c
ecoff.h
ehopt.c
ehopt.c
-emul-target.h
emul.h
+emul-target.h
expr.c
expr.c
expr.h
flonum-copy.c
flonum-copy.c
+flonum.h
flonum-konst.c
flonum-konst.c
flonum-mult.c
flonum-mult.c
-flonum.h
frags.c
frags.c
frags.h
-gasp.c
hash.c
hash.c
hash.h
diff --git a/contrib/binutils/gas/po/gas.pot b/contrib/binutils/gas/po/gas.pot
index 45a2485..ae3cbab 100644
--- a/contrib/binutils/gas/po/gas.pot
+++ b/contrib/binutils/gas/po/gas.pot
@@ -1,13 +1,12 @@
# SOME DESCRIPTIVE TITLE.
-# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
-# This file is distributed under the same license as the PACKAGE package.
+# Copyright (C) YEAR Free Software Foundation, Inc.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
-"POT-Creation-Date: 2002-10-30 10:07-0500\n"
+"POT-Creation-Date: 2003-07-17 14:56+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -15,72 +14,72 @@ msgstr ""
"Content-Type: text/plain; charset=CHARSET\n"
"Content-Transfer-Encoding: 8bit\n"
-#: app.c:476 app.c:490
+#: app.c:474 app.c:488
msgid "end of file in comment"
msgstr ""
-#: app.c:569
+#: app.c:567
msgid "end of file in string; inserted '\"'"
msgstr ""
-#: app.c:635
-#, c-format
-msgid "unknown escape '\\%c' in string; ignored"
+#: app.c:612
+msgid "end of file in string; '\"' inserted"
msgstr ""
-#: app.c:644
-msgid "end of file in string; '\"' inserted"
+#: app.c:638
+#, c-format
+msgid "unknown escape '\\%c' in string; ignored"
msgstr ""
-#: app.c:764
+#: app.c:790
msgid "end of file not at end of a line; newline inserted"
msgstr ""
-#: app.c:923
+#: app.c:949
msgid "end of file in multiline comment"
msgstr ""
-#: app.c:987
+#: app.c:1013
msgid "end of file after a one-character quote; \\0 inserted"
msgstr ""
-#: app.c:995
+#: app.c:1021
msgid "end of file in escape character"
msgstr ""
-#: app.c:1007
+#: app.c:1033
msgid "missing close quote; (assumed)"
msgstr ""
-#: app.c:1075 app.c:1129 app.c:1139 app.c:1204
+#: app.c:1101 app.c:1155 app.c:1166 app.c:1231
msgid "end of file in comment; newline inserted"
msgstr ""
-#: as.c:148
+#: as.c:160
msgid "missing emulation mode name"
msgstr ""
-#: as.c:163
+#: as.c:175
#, c-format
msgid "unrecognized emulation name `%s'"
msgstr ""
-#: as.c:210
+#: as.c:222
#, c-format
msgid "GNU assembler version %s (%s) using BFD version %s"
msgstr ""
-#: as.c:213
+#: as.c:225
#, c-format
msgid "GNU assembler version %s (%s)"
msgstr ""
-#: as.c:222
+#: as.c:234
#, c-format
msgid "Usage: %s [option...] [asmfile...]\n"
msgstr ""
-#: as.c:224
+#: as.c:236
msgid ""
"Options:\n"
" -a[sub-option...]\t turn on listings\n"
@@ -95,139 +94,148 @@ msgid ""
" \t =FILE list to FILE (must be last sub-option)\n"
msgstr ""
-#: as.c:237
+#: as.c:249
msgid " -D produce assembler debugging messages\n"
msgstr ""
-#: as.c:239
+#: as.c:251
msgid " --defsym SYM=VAL define symbol SYM to given value\n"
msgstr ""
-#: as.c:255
+#: as.c:267
#, c-format
msgid " emulate output (default %s)\n"
msgstr ""
-#: as.c:259
+#: as.c:272
+msgid " --execstack require executable stack for this object\n"
+msgstr ""
+
+#: as.c:274
+msgid ""
+" --noexecstack don't require executable stack for this object\n"
+msgstr ""
+
+#: as.c:277
msgid " -f skip whitespace and comment preprocessing\n"
msgstr ""
-#: as.c:261
+#: as.c:279
msgid " --gstabs generate stabs debugging information\n"
msgstr ""
-#: as.c:263
+#: as.c:281
msgid " --gdwarf2 generate DWARF2 debugging information\n"
msgstr ""
-#: as.c:265
+#: as.c:283
msgid " --help show this message and exit\n"
msgstr ""
-#: as.c:267
+#: as.c:285
msgid " --target-help show target specific options\n"
msgstr ""
-#: as.c:269
+#: as.c:287
msgid ""
" -I DIR add DIR to search list for .include directives\n"
msgstr ""
-#: as.c:271
+#: as.c:289
msgid " -J don't warn about signed overflow\n"
msgstr ""
-#: as.c:273
+#: as.c:291
msgid ""
" -K warn when differences altered for long "
"displacements\n"
msgstr ""
-#: as.c:275
+#: as.c:293
msgid " -L,--keep-locals keep local symbols (e.g. starting with `L')\n"
msgstr ""
-#: as.c:277
+#: as.c:295
msgid " -M,--mri assemble in MRI compatibility mode\n"
msgstr ""
-#: as.c:279
+#: as.c:297
msgid ""
" --MD FILE write dependency information in FILE (default "
"none)\n"
msgstr ""
-#: as.c:281
+#: as.c:299
msgid " -nocpp ignored\n"
msgstr ""
-#: as.c:283
+#: as.c:301
msgid ""
" -o OBJFILE name the object-file output OBJFILE (default a."
"out)\n"
msgstr ""
-#: as.c:285
+#: as.c:303
msgid " -R fold data section into text section\n"
msgstr ""
-#: as.c:287
+#: as.c:305
msgid ""
" --statistics print various measured statistics from execution\n"
msgstr ""
-#: as.c:289
+#: as.c:307
msgid " --strip-local-absolute strip local absolute symbols\n"
msgstr ""
-#: as.c:291
+#: as.c:309
msgid ""
" --traditional-format Use same format as native assembler when possible\n"
msgstr ""
-#: as.c:293
+#: as.c:311
msgid " --version print assembler version number and exit\n"
msgstr ""
-#: as.c:295
+#: as.c:313
msgid " -W --no-warn suppress warnings\n"
msgstr ""
-#: as.c:297
+#: as.c:315
msgid " --warn don't suppress warnings\n"
msgstr ""
-#: as.c:299
+#: as.c:317
msgid " --fatal-warnings treat warnings as errors\n"
msgstr ""
-#: as.c:301
+#: as.c:319
msgid ""
" --itbl INSTTBL extend instruction set to include instructions\n"
" matching the specifications defined in file "
"INSTTBL\n"
msgstr ""
-#: as.c:304
+#: as.c:322
msgid " -w ignored\n"
msgstr ""
-#: as.c:306
+#: as.c:324
msgid " -X ignored\n"
msgstr ""
-#: as.c:308
+#: as.c:326
msgid " -Z generate object file even after errors\n"
msgstr ""
-#: as.c:310
+#: as.c:328
msgid ""
" --listing-lhs-width set the width in words of the output data column "
"of\n"
" the listing\n"
msgstr ""
-#: as.c:313
+#: as.c:331
msgid ""
" --listing-lhs-width2 set the width in words of the continuation lines\n"
" of the output data column; ignored if smaller "
@@ -235,105 +243,105 @@ msgid ""
" the width of the first line\n"
msgstr ""
-#: as.c:317
+#: as.c:335
msgid ""
" --listing-rhs-width set the max width in characters of the lines from\n"
" the source file\n"
msgstr ""
-#: as.c:320
+#: as.c:338
msgid ""
" --listing-cont-lines set the maximum number of continuation lines used\n"
" for the output data column of the listing\n"
msgstr ""
-#: as.c:327 gasp.c:3592
+#: as.c:345
#, c-format
msgid "Report bugs to %s\n"
msgstr ""
-#: as.c:528 as.c:530
+#: as.c:557 as.c:559
#, c-format
msgid "GNU assembler %s\n"
msgstr ""
-#: as.c:532
+#: as.c:561
msgid "Copyright 2002 Free Software Foundation, Inc.\n"
msgstr ""
-#: as.c:533 gasp.c:3691
+#: as.c:562
msgid ""
"This program is free software; you may redistribute it under the terms of\n"
"the GNU General Public License. This program has absolutely no warranty.\n"
msgstr ""
-#: as.c:536
+#: as.c:565
#, c-format
msgid "This assembler was configured for a target of `%s'.\n"
msgstr ""
-#: as.c:543
+#: as.c:572
msgid "multiple emulation names specified"
msgstr ""
-#: as.c:545
+#: as.c:574
msgid "emulations not handled in this configuration"
msgstr ""
-#: as.c:550
+#: as.c:579
#, c-format
msgid "alias = %s\n"
msgstr ""
-#: as.c:551
+#: as.c:580
#, c-format
msgid "canonical = %s\n"
msgstr ""
-#: as.c:552
+#: as.c:581
#, c-format
msgid "cpu-type = %s\n"
msgstr ""
-#: as.c:554
+#: as.c:583
#, c-format
msgid "format = %s\n"
msgstr ""
-#: as.c:557
+#: as.c:586
#, c-format
msgid "bfd-target = %s\n"
msgstr ""
-#: as.c:570
+#: as.c:599
msgid "bad defsym; format is --defsym name=value"
msgstr ""
-#: as.c:594
+#: as.c:623
msgid "no file name following -t option"
msgstr ""
-#: as.c:609
+#: as.c:638
#, c-format
msgid "failed to read instruction table %s\n"
msgstr ""
-#: as.c:724
+#: as.c:765
#, c-format
msgid "invalid listing option `%c'"
msgstr ""
-#: as.c:926
+#: as.c:984
#, c-format
msgid "%d warnings, treating warnings as errors"
msgstr ""
-#: as.c:957
+#: as.c:1015
#, c-format
msgid "%s: total time in assembly: %ld.%06ld\n"
msgstr ""
-#: as.c:960
+#: as.c:1018
#, c-format
msgid "%s: data size %ld\n"
msgstr ""
@@ -347,71 +355,71 @@ msgstr ""
#. * We have a GROSS internal error.
#. * This should never happen.
#.
-#: atof-generic.c:437 config/tc-m68k.c:2883
+#: atof-generic.c:437 config/tc-m68k.c:2869
msgid "failed sanity check"
msgstr ""
-#: cond.c:79
+#: cond.c:83
msgid "invalid identifier for \".ifdef\""
msgstr ""
-#: cond.c:133
+#: cond.c:151
msgid "non-constant expression in \".if\" statement"
msgstr ""
-#: cond.c:229
+#: cond.c:247
msgid "bad format for ifc or ifnc"
msgstr ""
-#: cond.c:260
+#: cond.c:278
msgid "\".elseif\" without matching \".if\""
msgstr ""
-#: cond.c:264
+#: cond.c:282
msgid "\".elseif\" after \".else\""
msgstr ""
-#: cond.c:267 cond.c:375
+#: cond.c:285 cond.c:393
msgid "here is the previous \"else\""
msgstr ""
-#: cond.c:270 cond.c:378
+#: cond.c:288 cond.c:396
msgid "here is the previous \"if\""
msgstr ""
-#: cond.c:299
+#: cond.c:317
msgid "non-constant expression in \".elseif\" statement"
msgstr ""
-#: cond.c:338
+#: cond.c:356
msgid "\".endif\" without \".if\""
msgstr ""
-#: cond.c:368
+#: cond.c:386
msgid "\".else\" without matching \".if\""
msgstr ""
-#: cond.c:372
+#: cond.c:390
msgid "duplicate \"else\""
msgstr ""
-#: cond.c:424
+#: cond.c:442
msgid ".ifeqs syntax error"
msgstr ""
-#: cond.c:507
+#: cond.c:525
msgid "end of macro inside conditional"
msgstr ""
-#: cond.c:509
+#: cond.c:527
msgid "end of file inside conditional"
msgstr ""
-#: cond.c:512
+#: cond.c:530
msgid "here is the start of the unterminated conditional"
msgstr ""
-#: cond.c:516
+#: cond.c:534
msgid "here is the \"else\" of the unterminated conditional"
msgstr ""
@@ -425,16 +433,16 @@ msgstr ""
msgid "Attempt to put an undefined symbol into set %s"
msgstr ""
-#: config/obj-aout.c:197 config/obj-coff.c:1274
+#: config/obj-aout.c:197 config/obj-coff.c:1276
#, c-format
msgid "Symbol `%s' can not be both weak and common"
msgstr ""
-#: config/obj-aout.c:255 config/obj-coff.c:2018
+#: config/obj-aout.c:255 config/obj-coff.c:2022
msgid "unresolved relocation"
msgstr ""
-#: config/obj-aout.c:257 config/obj-coff.c:2020
+#: config/obj-aout.c:257 config/obj-coff.c:2024
#, c-format
msgid "bad relocation: symbol `%s' not in symbol table"
msgstr ""
@@ -444,7 +452,7 @@ msgstr ""
msgid "%s: bad type for weak symbol"
msgstr ""
-#: config/obj-aout.c:458 config/obj-coff.c:2941 write.c:1927
+#: config/obj-aout.c:458 config/obj-coff.c:2945 write.c:1931
#, c-format
msgid "%s: global symbols not supported in common sections"
msgstr ""
@@ -454,11 +462,7 @@ msgstr ""
msgid "Local symbol %s never defined."
msgstr ""
-#: config/obj-aout.c:612
-msgid "subsegment index too high"
-msgstr ""
-
-#: config/obj-bout.c:319 config/obj-vms.c:562
+#: config/obj-bout.c:319 config/obj-vms.c:629
#, c-format
msgid "Local symbol %s never defined"
msgstr ""
@@ -474,7 +478,7 @@ msgid "Line numbers must be positive integers\n"
msgstr ""
#. Wrong context.
-#: config/obj-coff.c:503 config/obj-coff.c:2363
+#: config/obj-coff.c:503 config/obj-coff.c:2367
msgid ".ln pseudo-op inside .def/.endef: ignored."
msgstr ""
@@ -486,11 +490,11 @@ msgstr ""
msgid ".loc pseudo-op inside .def/.endef: ignored."
msgstr ""
-#: config/obj-coff.c:641 config/obj-coff.c:2415
+#: config/obj-coff.c:641 config/obj-coff.c:2419
msgid ".def pseudo-op used inside of .def/.endef: ignored."
msgstr ""
-#: config/obj-coff.c:687 config/obj-coff.c:2467
+#: config/obj-coff.c:687 config/obj-coff.c:2471
msgid ".endef pseudo-op used outside of .def/.endef: ignored."
msgstr ""
@@ -499,341 +503,338 @@ msgstr ""
msgid "`%s' symbol without preceding function"
msgstr ""
-#: config/obj-coff.c:812 config/obj-coff.c:2547
+#: config/obj-coff.c:812 config/obj-coff.c:2551
#, c-format
msgid "unexpected storage class %d"
msgstr ""
-#: config/obj-coff.c:925 config/obj-coff.c:2654
+#: config/obj-coff.c:925 config/obj-coff.c:2658
msgid ".dim pseudo-op used outside of .def/.endef: ignored."
msgstr ""
-#: config/obj-coff.c:945 config/obj-coff.c:2674
+#: config/obj-coff.c:945 config/obj-coff.c:2678
msgid "badly formed .dim directive ignored"
msgstr ""
-#: config/obj-coff.c:996 config/obj-coff.c:2734
+#: config/obj-coff.c:996 config/obj-coff.c:2738
msgid ".size pseudo-op used outside of .def/.endef ignored."
msgstr ""
-#: config/obj-coff.c:1012 config/obj-coff.c:2750
+#: config/obj-coff.c:1012 config/obj-coff.c:2754
msgid ".scl pseudo-op used outside of .def/.endef ignored."
msgstr ""
-#: config/obj-coff.c:1030 config/obj-coff.c:2768
+#: config/obj-coff.c:1030 config/obj-coff.c:2772
msgid ".tag pseudo-op used outside of .def/.endef ignored."
msgstr ""
-#: config/obj-coff.c:1049 config/obj-coff.c:2785
+#: config/obj-coff.c:1049 config/obj-coff.c:2789
#, c-format
msgid "tag not found for .tag %s"
msgstr ""
-#: config/obj-coff.c:1064 config/obj-coff.c:2799
+#: config/obj-coff.c:1064 config/obj-coff.c:2803
msgid ".type pseudo-op used outside of .def/.endef ignored."
msgstr ""
-#: config/obj-coff.c:1086 config/obj-coff.c:2819
+#: config/obj-coff.c:1086 config/obj-coff.c:2823
msgid ".val pseudo-op used outside of .def/.endef ignored."
msgstr ""
-#: config/obj-coff.c:1231 config/obj-coff.c:3012
+#: config/obj-coff.c:1233 config/obj-coff.c:3016
msgid "mismatched .eb"
msgstr ""
-#: config/obj-coff.c:1252 config/obj-coff.c:3050
+#: config/obj-coff.c:1254 config/obj-coff.c:3054
msgid "C_EFCN symbol out of scope"
msgstr ""
#. STYP_INFO
#. STYP_LIB
#. STYP_OVER
-#: config/obj-coff.c:1478
+#: config/obj-coff.c:1482
#, c-format
msgid "unsupported section attribute '%c'"
msgstr ""
-#: config/obj-coff.c:1483 config/obj-coff.c:3755 config/tc-ppc.c:4243
+#: config/obj-coff.c:1487 config/obj-coff.c:3759 config/tc-ppc.c:4508
#, c-format
msgid "unknown section attribute '%c'"
msgstr ""
-#: config/obj-coff.c:1513 config/tc-ppc.c:4261 config/tc-tic54x.c:4339
-#: read.c:2560
+#: config/obj-coff.c:1517 config/tc-ppc.c:4526 config/tc-tic54x.c:4339
+#: read.c:2562
#, c-format
msgid "error setting flags for \"%s\": %s"
msgstr ""
-#: config/obj-coff.c:1524
+#: config/obj-coff.c:1528
#, c-format
msgid "Ignoring changed section attributes for %s"
msgstr ""
-#: config/obj-coff.c:1660
+#: config/obj-coff.c:1664
#, c-format
msgid "0x%lx: \"%s\" type = %ld, class = %d, segment = %d\n"
msgstr ""
-#: config/obj-coff.c:1845 config/obj-ieee.c:69
+#: config/obj-coff.c:1849 config/obj-ieee.c:69
msgid "Out of step\n"
msgstr ""
-#: config/obj-coff.c:2282
+#: config/obj-coff.c:2286
msgid "bfd_coff_swap_scnhdr_out failed"
msgstr ""
-#: config/obj-coff.c:2503
+#: config/obj-coff.c:2507
msgid "`.bf' symbol without preceding function\n"
msgstr ""
-#: config/obj-coff.c:3453 config/obj-ieee.c:521
+#: config/obj-coff.c:3457 config/obj-ieee.c:521
#, c-format
msgid "FATAL: Can't create %s"
msgstr ""
-#: config/obj-coff.c:3631
+#: config/obj-coff.c:3635
#, c-format
msgid "Can't close %s: %s"
msgstr ""
-#: config/obj-coff.c:3665
+#: config/obj-coff.c:3669
#, c-format
msgid "Too many new sections; can't add \"%s\""
msgstr ""
-#: config/obj-coff.c:4053 config/tc-sparc.c:3544
+#: config/obj-coff.c:4057 config/tc-sparc.c:3635
msgid "Expected comma after name"
msgstr ""
-#: config/obj-coff.c:4059
+#: config/obj-coff.c:4063
msgid "Missing size expression"
msgstr ""
-#: config/obj-coff.c:4065
+#: config/obj-coff.c:4069
#, c-format
msgid "lcomm length (%d.) <0! Ignored."
msgstr ""
-#: config/obj-coff.c:4093
+#: config/obj-coff.c:4097
#, c-format
msgid "Symbol %s already defined"
msgstr ""
-#: config/obj-coff.c:4189 config/tc-i960.c:3207
+#: config/obj-coff.c:4193 config/tc-i960.c:3221
#, c-format
msgid "No 'bal' entry point for leafproc %s"
msgstr ""
-#: config/obj-coff.c:4266
+#: config/obj-coff.c:4270
#, c-format
msgid "Negative of non-absolute symbol %s"
msgstr ""
-#: config/obj-coff.c:4286
+#: config/obj-coff.c:4290
msgid "callj to difference of 2 symbols"
msgstr ""
-#: config/obj-coff.c:4330
+#: config/obj-coff.c:4334
#, c-format
msgid "Can't emit reloc {- %s-seg symbol \"%s\"} @ file address %ld."
msgstr ""
-#. This is a COBR instruction. They have only a 13-bit
-#. displacement and are only to be used for local branches:
-#. flag as error, don't generate relocation.
-#: config/obj-coff.c:4416 config/tc-i960.c:3227 write.c:2820
+#: config/obj-coff.c:4420 config/tc-i960.c:2844
msgid "can't use COBR format with external label"
msgstr ""
-#: config/obj-coff.c:4489
+#: config/obj-coff.c:4493
#, c-format
msgid "Value of %ld too large for field of %d bytes at 0x%lx"
msgstr ""
-#: config/obj-coff.c:4503
+#: config/obj-coff.c:4507
#, c-format
msgid "Signed .word overflow; switch may be too large; %ld at 0x%lx"
msgstr ""
-#: config/obj-ecoff.c:227
+#: config/obj-ecoff.c:192
msgid "Can't set GP value"
msgstr ""
-#: config/obj-ecoff.c:234
+#: config/obj-ecoff.c:199
msgid "Can't set register masks"
msgstr ""
-#: config/obj-elf.c:313
+#: config/obj-elf.c:316
msgid "expected comma after symbol-name"
msgstr ""
-#: config/obj-elf.c:320 config/tc-sparc.c:3697
+#: config/obj-elf.c:326
#, c-format
-msgid ".COMMon length (%d.) <0! Ignored."
+msgid ".COMMon length (%ld) out of range, ignored."
msgstr ""
-#: config/obj-elf.c:330 ecoff.c:3397 read.c:1403 read.c:1504 read.c:2142
-#: read.c:2231 read.c:2861 read.c:4951 symbols.c:361 symbols.c:460
+#: config/obj-elf.c:335 ecoff.c:3397 read.c:1406 read.c:1507 read.c:2145
+#: read.c:2234 read.c:2863 read.c:4968 symbols.c:367 symbols.c:466
#, c-format
msgid "symbol `%s' is already defined"
msgstr ""
-#: config/obj-elf.c:338
+#: config/obj-elf.c:343
#, c-format
-msgid "length of .comm \"%s\" is already %ld; not changed to %d"
+msgid "length of .comm \"%s\" is already %ld; not changed to %ld"
msgstr ""
-#: config/obj-elf.c:361
+#: config/obj-elf.c:367
msgid "common alignment negative; 0 assumed"
msgstr ""
-#: config/obj-elf.c:380
+#: config/obj-elf.c:386
msgid "common alignment not a power of 2"
msgstr ""
-#: config/obj-elf.c:443 config/tc-sparc.c:3839 config/tc-v850.c:450
+#: config/obj-elf.c:449 config/tc-sparc.c:3931 config/tc-v850.c:461
#, c-format
msgid "bad .common segment %s"
msgstr ""
-#: config/obj-elf.c:714
+#: config/obj-elf.c:717
#, c-format
msgid "setting incorrect section type for %s"
msgstr ""
-#: config/obj-elf.c:718
+#: config/obj-elf.c:721
#, c-format
msgid "ignoring incorrect section type for %s"
msgstr ""
-#: config/obj-elf.c:731
+#: config/obj-elf.c:734
#, c-format
msgid "setting incorrect section attributes for %s"
msgstr ""
-#: config/obj-elf.c:782
+#: config/obj-elf.c:786
#, c-format
msgid "ignoring changed section attributes for %s"
msgstr ""
-#: config/obj-elf.c:784
+#: config/obj-elf.c:788
#, c-format
msgid "ignoring changed section entity size for %s"
msgstr ""
-#: config/obj-elf.c:787
+#: config/obj-elf.c:791
#, c-format
msgid "ignoring new section group for %s"
msgstr ""
-#: config/obj-elf.c:841
+#: config/obj-elf.c:845
msgid "unrecognized .section attribute: want a,w,x,M,S,G,T"
msgstr ""
-#: config/obj-elf.c:881
+#: config/obj-elf.c:884
msgid "unrecognized section attribute"
msgstr ""
-#: config/obj-elf.c:903 read.c:2543
+#: config/obj-elf.c:906 read.c:2545
msgid "unrecognized section type"
msgstr ""
-#: config/obj-elf.c:933
+#: config/obj-elf.c:936
msgid "missing name"
msgstr ""
-#: config/obj-elf.c:1042
+#: config/obj-elf.c:1048
msgid "invalid merge entity size"
msgstr ""
-#: config/obj-elf.c:1049
+#: config/obj-elf.c:1055
msgid "entity size for SHF_MERGE not specified"
msgstr ""
-#: config/obj-elf.c:1069
+#: config/obj-elf.c:1075
msgid "group name for SHF_GROUP not specified"
msgstr ""
-#: config/obj-elf.c:1082
+#: config/obj-elf.c:1088
msgid "character following name is not '#'"
msgstr ""
-#: config/obj-elf.c:1183
+#: config/obj-elf.c:1189
msgid ".previous without corresponding .section; ignored"
msgstr ""
-#: config/obj-elf.c:1210
+#: config/obj-elf.c:1216
msgid ".popsection without corresponding .pushsection; ignored"
msgstr ""
-#: config/obj-elf.c:1264
+#: config/obj-elf.c:1270
msgid "expected comma after name in .symver"
msgstr ""
-#: config/obj-elf.c:1287
+#: config/obj-elf.c:1294
#, c-format
msgid "missing version name in `%s' for symbol `%s'"
msgstr ""
-#: config/obj-elf.c:1298
+#: config/obj-elf.c:1305
#, c-format
msgid "multiple versions [`%s'|`%s'] for symbol `%s'"
msgstr ""
-#: config/obj-elf.c:1534
+#: config/obj-elf.c:1541
msgid "expected quoted string"
msgstr ""
-#: config/obj-elf.c:1555
+#: config/obj-elf.c:1562
#, c-format
msgid "expected comma after name `%s' in .size directive"
msgstr ""
-#: config/obj-elf.c:1564
+#: config/obj-elf.c:1571
msgid "missing expression in .size directive"
msgstr ""
-#: config/obj-elf.c:1647
+#: config/obj-elf.c:1660
#, c-format
msgid "unrecognized symbol type \"%s\""
msgstr ""
-#: config/obj-elf.c:1828
+#: config/obj-elf.c:1841
msgid ".size expression too complicated to fix up"
msgstr ""
-#: config/obj-elf.c:1860
+#: config/obj-elf.c:1873
#, c-format
msgid ""
"invalid attempt to declare external version name as default in symbol `%s'"
msgstr ""
-#: config/obj-elf.c:1921 ecoff.c:3642
+#: config/obj-elf.c:1934 ecoff.c:3642
#, c-format
msgid "symbol `%s' can not be both weak and common"
msgstr ""
-#: config/obj-elf.c:2041
+#: config/obj-elf.c:2054
#, c-format
msgid "assuming all members of group `%s' are COMDAT"
msgstr ""
-#: config/obj-elf.c:2063
+#: config/obj-elf.c:2076
#, c-format
msgid "can't create group: %s"
msgstr ""
-#: config/obj-elf.c:2170
+#: config/obj-elf.c:2183
#, c-format
msgid "failed to set up debugging information: %s"
msgstr ""
-#: config/obj-elf.c:2190
+#: config/obj-elf.c:2203
#, c-format
msgid "can't start writing .mdebug section: %s"
msgstr ""
-#: config/obj-elf.c:2198
+#: config/obj-elf.c:2211
#, c-format
msgid "could not write .mdebug section: %s"
msgstr ""
@@ -864,45 +865,45 @@ msgstr ""
msgid "FATAL: Attaching copyright header %s"
msgstr ""
-#: config/obj-vms.c:463
+#: config/obj-vms.c:530
#, c-format
msgid "compiler emitted zero-size common symbol `%s' already defined"
msgstr ""
-#: config/obj-vms.c:473
+#: config/obj-vms.c:540
#, c-format
msgid "compiler redefined zero-size common symbol `%s'"
msgstr ""
-#: config/obj-vms.c:592
+#: config/obj-vms.c:663
#, c-format
msgid "Couldn't create VMS object file \"%s\""
msgstr ""
-#: config/obj-vms.c:617
+#: config/obj-vms.c:688
msgid "I/O error writing VMS object file (length prefix)"
msgstr ""
-#: config/obj-vms.c:631
+#: config/obj-vms.c:702
msgid "I/O error writing VMS object file"
msgstr ""
-#: config/obj-vms.c:1221
+#: config/obj-vms.c:1292
#, c-format
msgid "Couldn't find source file \"%s\", status=%%X%x"
msgstr ""
-#: config/obj-vms.c:1719 config/obj-vms.c:2895
+#: config/obj-vms.c:1790 config/obj-vms.c:2967
#, c-format
msgid "debugger forward reference error, dbx type %d"
msgstr ""
-#: config/obj-vms.c:1794
+#: config/obj-vms.c:1865
#, c-format
msgid "Variable descriptor %d too complicated. Defined as `void *'."
msgstr ""
-#: config/obj-vms.c:2108
+#: config/obj-vms.c:2179
msgid ""
"***Warning - the assembly code generated by the compiler has placed \n"
" global constant(s) in the text psect. These will not be available to \n"
@@ -913,92 +914,92 @@ msgid ""
" I didn't warn you! \n"
msgstr ""
-#: config/obj-vms.c:2422
+#: config/obj-vms.c:2494
#, c-format
msgid "debugginer output: %d is an unknown untyped variable."
msgstr ""
-#: config/obj-vms.c:2640
+#: config/obj-vms.c:2712
#, c-format
msgid "debugger output: structure element `%s' has undefined type"
msgstr ""
-#: config/obj-vms.c:2751
+#: config/obj-vms.c:2823
#, c-format
msgid "debugger output: %d is an unknown type of variable."
msgstr ""
-#: config/obj-vms.c:2884
+#: config/obj-vms.c:2956
#, c-format
msgid "debugger output: Unable to resolve %d circular references."
msgstr ""
-#: config/obj-vms.c:3086
+#: config/obj-vms.c:3158
#, c-format
msgid "Module name truncated: %s\n"
msgstr ""
-#: config/obj-vms.c:3364
+#: config/obj-vms.c:3436
#, c-format
msgid "Symbol %s replaced by %s\n"
msgstr ""
#. impossible
-#: config/obj-vms.c:3647
+#: config/obj-vms.c:3719
#, c-format
msgid "Unknown VMS psect type (%ld)"
msgstr ""
-#: config/obj-vms.c:3688
+#: config/obj-vms.c:3760
#, c-format
msgid "Globalsymbol attribute for symbol %s was unexpected."
msgstr ""
-#: config/obj-vms.c:3837
+#: config/obj-vms.c:3909
msgid "Invalid data type for globalvalue"
msgstr ""
-#: config/obj-vms.c:3849
+#: config/obj-vms.c:3921
#, c-format
msgid "Invalid globalvalue of %s"
msgstr ""
-#: config/obj-vms.c:4199
+#: config/obj-vms.c:4271
msgid "Couldn't find fixup fragment when checking for indirect reference"
msgstr ""
-#: config/obj-vms.c:4542 config/obj-vms.c:4683
+#: config/obj-vms.c:4614 config/obj-vms.c:4757
msgid "Fixup data addsy and subsy don't have the same type"
msgstr ""
-#: config/obj-vms.c:4546 config/obj-vms.c:4687
+#: config/obj-vms.c:4618 config/obj-vms.c:4761
msgid "Fixup data addsy and subsy don't have an appropriate type"
msgstr ""
-#: config/obj-vms.c:4549 config/obj-vms.c:4690
+#: config/obj-vms.c:4621 config/obj-vms.c:4764
msgid "Fixup data is erroneously \"pcrel\""
msgstr ""
-#: config/obj-vms.c:4565 config/obj-vms.c:4709
+#: config/obj-vms.c:4637 config/obj-vms.c:4783
msgid "Fixup datum is not a longword"
msgstr ""
-#: config/obj-vms.c:4569 config/obj-vms.c:4713
+#: config/obj-vms.c:4641 config/obj-vms.c:4787
msgid "Fixup datum is not \"fixP->fx_addsy\""
msgstr ""
-#: config/obj-vms.c:4784
+#: config/obj-vms.c:4858
#, c-format
msgid ""
"g++ wrote an extern reference to `%s' as a routine.\n"
"I will fix it, but I hope that it was note really a routine."
msgstr ""
-#: config/obj-vms.c:4916
+#: config/obj-vms.c:4990
msgid "Can't handle global xtors symbols yet."
msgstr ""
-#: config/obj-vms.c:4919
+#: config/obj-vms.c:4993
#, c-format
msgid "Unknown %s"
msgstr ""
@@ -1006,118 +1007,120 @@ msgstr ""
#.
#. * Error otherwise.
#.
-#: config/obj-vms.c:5004
+#: config/obj-vms.c:5078
#, c-format
msgid "unhandled stab type %d"
msgstr ""
-#: config/tc-a29k.c:160 config/tc-sparc.c:3891
+#: config/tc-a29k.c:163 config/tc-sparc.c:3983
msgid "Unknown segment type"
msgstr ""
#. Probably a memory allocation problem? Give up now.
-#: config/tc-a29k.c:330 config/tc-dlx.c:369 config/tc-hppa.c:1464
-#: config/tc-mips.c:1077 config/tc-mips.c:1119 config/tc-or32.c:230
+#: config/tc-a29k.c:333 config/tc-dlx.c:369 config/tc-hppa.c:1463
+#: config/tc-mips.c:1108 config/tc-mips.c:1150 config/tc-or32.c:228
#: config/tc-sparc.c:853
msgid "Broken assembler. No assembly attempted."
msgstr ""
-#: config/tc-a29k.c:375 config/tc-avr.c:1137 config/tc-d10v.c:545
-#: config/tc-d30v.c:552 config/tc-h8300.c:333 config/tc-h8500.c:284
-#: config/tc-mcore.c:655 config/tc-mmix.c:475 config/tc-mn10200.c:940
-#: config/tc-mn10300.c:1318 config/tc-or32.c:336 config/tc-or32.c:392
-#: config/tc-ppc.c:2143 config/tc-s390.c:1062 config/tc-sh.c:1272
-#: config/tc-sh64.c:2228 config/tc-tic80.c:283 config/tc-v850.c:1984
-#: config/tc-w65.c:241 config/tc-z8k.c:343
+#: config/tc-a29k.c:378 config/tc-avr.c:1121 config/tc-d10v.c:545
+#: config/tc-d30v.c:551 config/tc-h8300.c:492 config/tc-h8500.c:283
+#: config/tc-mcore.c:607 config/tc-mmix.c:470 config/tc-mn10200.c:940
+#: config/tc-mn10300.c:1815 config/tc-msp430.c:1544 config/tc-or32.c:334
+#: config/tc-or32.c:390 config/tc-ppc.c:2334 config/tc-s390.c:1236
+#: config/tc-sh.c:1264 config/tc-sh64.c:2254 config/tc-tic80.c:279
+#: config/tc-v850.c:2024 config/tc-w65.c:218 config/tc-z8k.c:376
msgid "missing operand"
msgstr ""
-#: config/tc-a29k.c:414 config/tc-cris.c:950 config/tc-cris.c:958
-#: config/tc-dlx.c:834 config/tc-hppa.c:1600 config/tc-i860.c:431
-#: config/tc-i860.c:448 config/tc-sparc.c:1415 config/tc-sparc.c:1421
+#: config/tc-a29k.c:417 config/tc-cris.c:1075 config/tc-cris.c:1083
+#: config/tc-dlx.c:834 config/tc-hppa.c:1599 config/tc-i860.c:453
+#: config/tc-i860.c:470 config/tc-i860.c:930 config/tc-sparc.c:1415
+#: config/tc-sparc.c:1421
#, c-format
msgid "Unknown opcode: `%s'"
msgstr ""
-#: config/tc-a29k.c:419 config/tc-dlx.c:852
+#: config/tc-a29k.c:422 config/tc-dlx.c:852
#, c-format
msgid "Unknown opcode `%s'."
msgstr ""
-#: config/tc-a29k.c:451 config/tc-dlx.c:913
+#: config/tc-a29k.c:454 config/tc-dlx.c:913
#, c-format
msgid "Too many operands: %s"
msgstr ""
-#: config/tc-a29k.c:473 config/tc-a29k.c:504
+#: config/tc-a29k.c:476 config/tc-a29k.c:507
#, c-format
msgid "Immediate value of %ld is too large"
msgstr ""
-#: config/tc-a29k.c:543 config/tc-i860.c:340 config/tc-i860.c:832
-#: config/tc-m68k.c:3185 config/tc-m68k.c:3214 config/tc-sparc.c:2550
+#: config/tc-a29k.c:546 config/tc-i860.c:355 config/tc-i860.c:902
+#: config/tc-m68k.c:3171 config/tc-m68k.c:3200 config/tc-sparc.c:2647
msgid "failed sanity check."
msgstr ""
-#: config/tc-a29k.c:889 config/tc-or32.c:1046 config/tc-or32.c:1180
+#: config/tc-a29k.c:892 config/tc-or32.c:1044 config/tc-or32.c:1178
#, c-format
msgid "bad relocation type: 0x%02x"
msgstr ""
-#: config/tc-a29k.c:916
+#: config/tc-a29k.c:919
#, c-format
msgid "need %o3\n"
msgstr ""
-#: config/tc-a29k.c:932
+#: config/tc-a29k.c:935
msgid "a29k_convert_frag\n"
msgstr ""
-#: config/tc-a29k.c:941
+#: config/tc-a29k.c:944
msgid "a29k_estimate_size_before_relax\n"
msgstr ""
-#: config/tc-a29k.c:1092 config/tc-dlx.c:1295 config/tc-or32.c:1375
+#: config/tc-a29k.c:1095 config/tc-dlx.c:1283 config/tc-or32.c:1373
#, c-format
msgid "label \"$%d\" redefined"
msgstr ""
-#: config/tc-a29k.c:1165 config/tc-dlx.c:511 config/tc-or32.c:1470
+#: config/tc-a29k.c:1168 config/tc-dlx.c:511 config/tc-or32.c:1466
#, c-format
msgid "Invalid expression after %%%%\n"
msgstr ""
-#: config/tc-a29k.c:1176
+#: config/tc-a29k.c:1179
msgid "Invalid register in & expression"
msgstr ""
-#: config/tc-alpha.c:822
+#: config/tc-alpha.c:826
#, c-format
msgid "internal error: can't hash opcode `%s': %s"
msgstr ""
-#: config/tc-alpha.c:857
+#: config/tc-alpha.c:860
#, c-format
msgid "internal error: can't hash macro `%s': %s"
msgstr ""
-#: config/tc-alpha.c:939 config/tc-i960.c:2702
+#: config/tc-alpha.c:943 config/tc-i960.c:2707 config/tc-xtensa.c:4954
+#: config/tc-xtensa.c:5015
msgid "syntax error"
msgstr ""
-#: config/tc-alpha.c:1013 config/tc-h8300.c:1426 config/tc-h8500.c:1187
-#: config/tc-hppa.c:4019 config/tc-i860.c:931 config/tc-m68hc11.c:500
-#: config/tc-m68k.c:4205 config/tc-m88k.c:1011 config/tc-ns32k.c:1663
-#: config/tc-or32.c:912 config/tc-sparc.c:2837 config/tc-z8k.c:1328
+#: config/tc-alpha.c:1017 config/tc-h8300.c:2099 config/tc-h8500.c:1204
+#: config/tc-hppa.c:4018 config/tc-i860.c:1004 config/tc-m68hc11.c:568
+#: config/tc-m68k.c:4196 config/tc-m88k.c:991 config/tc-ns32k.c:1689
+#: config/tc-or32.c:910 config/tc-sparc.c:2934 config/tc-z8k.c:1371
msgid "Bad call to MD_ATOF()"
msgstr ""
-#: config/tc-alpha.c:1063
+#: config/tc-alpha.c:1067
#, c-format
msgid "Unknown CPU identifier `%s'"
msgstr ""
-#: config/tc-alpha.c:1107
+#: config/tc-alpha.c:1111
msgid ""
"Alpha options:\n"
"-32addr\t\t\ttreat addresses as 32-bit values\n"
@@ -1129,1430 +1132,1516 @@ msgid ""
"\t\t\tthese variants include PALcode opcodes\n"
msgstr ""
-#: config/tc-alpha.c:1117
+#: config/tc-alpha.c:1121
msgid ""
"VMS options:\n"
"-+\t\t\thash encode (don't truncate) names longer than 64 characters\n"
"-H\t\t\tshow new symbol after hash truncation\n"
msgstr ""
-#: config/tc-alpha.c:1290
+#: config/tc-alpha.c:1298
#, c-format
msgid "unhandled relocation type %s"
msgstr ""
-#: config/tc-alpha.c:1303
+#: config/tc-alpha.c:1311
msgid "non-absolute expression in constant field"
msgstr ""
-#: config/tc-alpha.c:1317
+#: config/tc-alpha.c:1325
#, c-format
msgid "type %d reloc done?\n"
msgstr ""
-#: config/tc-alpha.c:1365 config/tc-alpha.c:1372 config/tc-mips.c:8156
+#: config/tc-alpha.c:1373 config/tc-alpha.c:1380 config/tc-mips.c:8603
msgid "Used $at without \".set noat\""
msgstr ""
-#: config/tc-alpha.c:1445
+#: config/tc-alpha.c:1542
#, c-format
msgid "!samegp reloc against symbol without .prologue: %s"
msgstr ""
-#: config/tc-alpha.c:1594
+#: config/tc-alpha.c:1581 config/tc-xtensa.c:5451
#, c-format
msgid "cannot represent `%s' relocation in object file"
msgstr ""
-#: config/tc-alpha.c:1601
+#: config/tc-alpha.c:1588 config/tc-xtensa.c:5458
#, c-format
msgid "internal error? cannot generate `%s' relocation"
msgstr ""
-#: config/tc-alpha.c:1657
+#: config/tc-alpha.c:1642
#, c-format
msgid "frame reg expected, using $%d."
msgstr ""
-#: config/tc-alpha.c:1758
+#: config/tc-alpha.c:1743
#, c-format
msgid "No !literal!%ld was found"
msgstr ""
-#: config/tc-alpha.c:1764
+#: config/tc-alpha.c:1750
#, c-format
msgid "No !tlsgd!%ld was found"
msgstr ""
-#: config/tc-alpha.c:1771
+#: config/tc-alpha.c:1757
#, c-format
msgid "No !tlsldm!%ld was found"
msgstr ""
-#: config/tc-alpha.c:1779
+#: config/tc-alpha.c:1766
#, c-format
msgid "No ldah !gpdisp!%ld was found"
msgstr ""
-#: config/tc-alpha.c:1829
+#: config/tc-alpha.c:1816
#, c-format
msgid "too many !literal!%ld for %s"
msgstr ""
-#: config/tc-alpha.c:1859
+#: config/tc-alpha.c:1846
#, c-format
msgid "No lda !gpdisp!%ld was found"
msgstr ""
-#. only support one relocation op per insn
-#: config/tc-alpha.c:2003
+#. Only support one relocation op per insn.
+#: config/tc-alpha.c:1994
msgid "More than one relocation op per insn"
msgstr ""
-#: config/tc-alpha.c:2019
+#: config/tc-alpha.c:2010
msgid "No relocation operand"
msgstr ""
-#: config/tc-alpha.c:2029
+#: config/tc-alpha.c:2020
#, c-format
msgid "Unknown relocation operand: !%s"
msgstr ""
-#: config/tc-alpha.c:2039
+#: config/tc-alpha.c:2030
#, c-format
msgid "no sequence number after !%s"
msgstr ""
-#: config/tc-alpha.c:2049
+#: config/tc-alpha.c:2040
#, c-format
msgid "!%s does not use a sequence number"
msgstr ""
-#: config/tc-alpha.c:2059
+#: config/tc-alpha.c:2050
#, c-format
msgid "Bad sequence number: !%s!%s"
msgstr ""
-#: config/tc-alpha.c:2387
+#: config/tc-alpha.c:2378
#, c-format
msgid "operand out of range (%s not between %d and %d)"
msgstr ""
-#: config/tc-alpha.c:2501 config/tc-alpha.c:2525 config/tc-d10v.c:634
-#: config/tc-d30v.c:640 config/tc-mn10200.c:995 config/tc-mn10300.c:1389
-#: config/tc-ppc.c:2109 config/tc-ppc.c:2290 config/tc-ppc.c:2302
-#: config/tc-s390.c:1072 config/tc-s390.c:1129 config/tc-v850.c:1764
-#: config/tc-v850.c:1787 config/tc-v850.c:2007
+#: config/tc-alpha.c:2490 config/tc-alpha.c:2514 config/tc-d10v.c:634
+#: config/tc-d30v.c:639 config/tc-mn10200.c:995 config/tc-mn10300.c:1888
+#: config/tc-ppc.c:2300 config/tc-ppc.c:2517 config/tc-ppc.c:2529
+#: config/tc-s390.c:1246 config/tc-s390.c:1346 config/tc-s390.c:1442
+#: config/tc-v850.c:1804 config/tc-v850.c:1827 config/tc-v850.c:2047
msgid "too many fixups"
msgstr ""
-#: config/tc-alpha.c:2537
+#: config/tc-alpha.c:2526
msgid "invalid relocation for instruction"
msgstr ""
-#: config/tc-alpha.c:2548
+#: config/tc-alpha.c:2537
msgid "invalid relocation for field"
msgstr ""
-#: config/tc-alpha.c:2655
+#: config/tc-alpha.c:2642
#, c-format
msgid "too many ldah insns for !gpdisp!%ld"
msgstr ""
-#: config/tc-alpha.c:2657 config/tc-alpha.c:2669
+#: config/tc-alpha.c:2644 config/tc-alpha.c:2656
#, c-format
msgid "both insns for !gpdisp!%ld must be in the same section"
msgstr ""
-#: config/tc-alpha.c:2667
+#: config/tc-alpha.c:2654
#, c-format
msgid "too many lda insns for !gpdisp!%ld"
msgstr ""
-#: config/tc-alpha.c:2719
+#: config/tc-alpha.c:2707
#, c-format
msgid "too many lituse insns for !lituse_tlsgd!%ld"
msgstr ""
-#: config/tc-alpha.c:2722
+#: config/tc-alpha.c:2710
#, c-format
msgid "too many lituse insns for !lituse_tlsldm!%ld"
msgstr ""
-#: config/tc-alpha.c:2739
+#: config/tc-alpha.c:2727
#, c-format
msgid "duplicate !tlsgd!%ld"
msgstr ""
-#: config/tc-alpha.c:2741
+#: config/tc-alpha.c:2729
#, c-format
msgid "sequence number in use for !tlsldm!%ld"
msgstr ""
-#: config/tc-alpha.c:2755
+#: config/tc-alpha.c:2743
#, c-format
msgid "duplicate !tlsldm!%ld"
msgstr ""
-#: config/tc-alpha.c:2757
+#: config/tc-alpha.c:2745
#, c-format
msgid "sequence number in use for !tlsgd!%ld"
msgstr ""
-#: config/tc-alpha.c:2802 config/tc-alpha.c:2875
+#: config/tc-alpha.c:2790 config/tc-alpha.c:2863
#, c-format
msgid "inappropriate arguments for opcode `%s'"
msgstr ""
-#: config/tc-alpha.c:2804 config/tc-alpha.c:2877
+#: config/tc-alpha.c:2792 config/tc-alpha.c:2865
#, c-format
msgid "opcode `%s' not supported for target %s"
msgstr ""
-#: config/tc-alpha.c:2808 config/tc-alpha.c:2881 config/tc-avr.c:1103
+#: config/tc-alpha.c:2796 config/tc-alpha.c:2869 config/tc-avr.c:1087
+#: config/tc-msp430.c:446
#, c-format
msgid "unknown opcode `%s'"
msgstr ""
-#: config/tc-alpha.c:2928
+#: config/tc-alpha.c:2916
msgid "can not resolve expression"
msgstr ""
-#: config/tc-alpha.c:3072 config/tc-alpha.c:3251
+#: config/tc-alpha.c:3060 config/tc-alpha.c:3239
msgid "overflow in literal (.lita) table"
msgstr ""
-#: config/tc-alpha.c:3079 config/tc-alpha.c:3102 config/tc-alpha.c:3264
-#: config/tc-alpha.c:3479 config/tc-alpha.c:3524 config/tc-alpha.c:3598
-#: config/tc-alpha.c:3690 config/tc-alpha.c:3939 config/tc-alpha.c:4040
+#: config/tc-alpha.c:3067 config/tc-alpha.c:3090 config/tc-alpha.c:3252
+#: config/tc-alpha.c:3467 config/tc-alpha.c:3512 config/tc-alpha.c:3586
+#: config/tc-alpha.c:3678 config/tc-alpha.c:3926 config/tc-alpha.c:4025
msgid "macro requires $at register while noat in effect"
msgstr ""
-#: config/tc-alpha.c:3081 config/tc-alpha.c:3104 config/tc-alpha.c:3266
+#: config/tc-alpha.c:3069 config/tc-alpha.c:3092 config/tc-alpha.c:3254
msgid "macro requires $at while $at in use"
msgstr ""
-#: config/tc-alpha.c:3212
+#: config/tc-alpha.c:3200
msgid "bignum invalid; zero assumed"
msgstr ""
-#: config/tc-alpha.c:3214
+#: config/tc-alpha.c:3202
msgid "floating point number invalid; zero assumed"
msgstr ""
-#: config/tc-alpha.c:3219
+#: config/tc-alpha.c:3207
msgid "can't handle expression"
msgstr ""
-#: config/tc-alpha.c:3257
+#: config/tc-alpha.c:3245
msgid "overflow in literal (.lit8) table"
msgstr ""
-#: config/tc-alpha.c:4277 config/tc-ppc.c:1582 config/tc-ppc.c:4006
+#: config/tc-alpha.c:4262 config/tc-ppc.c:1740 config/tc-ppc.c:4271
#, c-format
msgid ".COMMon length (%ld.) <0! Ignored."
msgstr ""
-#: config/tc-alpha.c:4306 config/tc-sparc.c:3707 config/tc-v850.c:254
+#: config/tc-alpha.c:4291 config/tc-sparc.c:3799 config/tc-v850.c:256
msgid "Ignoring attempt to re-define symbol"
msgstr ""
-#: config/tc-alpha.c:4315 config/tc-alpha.c:4324 config/tc-ppc.c:4043
+#: config/tc-alpha.c:4300 config/tc-alpha.c:4309 config/tc-ppc.c:4308
#, c-format
msgid "Length of .comm \"%s\" is already %ld. Not changed to %ld."
msgstr ""
-#: config/tc-alpha.c:4426 ecoff.c:3082
+#: config/tc-alpha.c:4430 ecoff.c:3082
msgid ".ent directive has no name"
msgstr ""
-#: config/tc-alpha.c:4434
+#: config/tc-alpha.c:4438
msgid "nested .ent directives"
msgstr ""
-#: config/tc-alpha.c:4470 ecoff.c:3032
+#: config/tc-alpha.c:4483 ecoff.c:3032
msgid ".end directive has no name"
msgstr ""
-#: config/tc-alpha.c:4479
+#: config/tc-alpha.c:4492
+msgid ".end directive without matching .ent"
+msgstr ""
+
+#: config/tc-alpha.c:4494
msgid ".end directive names different symbol than .ent"
msgstr ""
-#: config/tc-alpha.c:4556
+#: config/tc-alpha.c:4538 ecoff.c:3171
+msgid ".fmask outside of .ent"
+msgstr ""
+
+#: config/tc-alpha.c:4540 ecoff.c:3241
+msgid ".mask outside of .ent"
+msgstr ""
+
+#: config/tc-alpha.c:4548 ecoff.c:3178
+msgid "bad .fmask directive"
+msgstr ""
+
+#: config/tc-alpha.c:4550 ecoff.c:3248
+msgid "bad .mask directive"
+msgstr ""
+
+#: config/tc-alpha.c:4584 config/tc-mips.c:14143 ecoff.c:3200
+msgid ".frame outside of .ent"
+msgstr ""
+
+#: config/tc-alpha.c:4595 ecoff.c:3211
+msgid "bad .frame directive"
+msgstr ""
+
+#: config/tc-alpha.c:4628
+msgid ".prologue directive without a preceding .ent directive"
+msgstr ""
+
+#: config/tc-alpha.c:4646
#, c-format
msgid "Invalid argument %d to .prologue."
msgstr ""
-#: config/tc-alpha.c:4648
+#: config/tc-alpha.c:4741
msgid "ECOFF debugging is disabled."
msgstr ""
-#: config/tc-alpha.c:4669
+#: config/tc-alpha.c:4755
+msgid ".ent directive without matching .end"
+msgstr ""
+
+#: config/tc-alpha.c:4840
+msgid ".usepv directive has no name"
+msgstr ""
+
+#: config/tc-alpha.c:4851
+msgid ".usepv directive has no type"
+msgstr ""
+
+#: config/tc-alpha.c:4866
+msgid "unknown argument for .usepv"
+msgstr ""
+
+#: config/tc-alpha.c:4900
msgid "Unknown section directive"
msgstr ""
-#: config/tc-alpha.c:4705
+#: config/tc-alpha.c:4936
msgid ".ent directive has no symbol"
msgstr ""
-#: config/tc-alpha.c:4732
+#: config/tc-alpha.c:4963
msgid "Bad .frame directive 1./2. param"
msgstr ""
-#: config/tc-alpha.c:4744
+#: config/tc-alpha.c:4975
msgid "Bad .frame directive 3./4. param"
msgstr ""
-#: config/tc-alpha.c:4769
+#: config/tc-alpha.c:5000
msgid ".pdesc directive not in link (.link) section"
msgstr ""
-#: config/tc-alpha.c:4777
+#: config/tc-alpha.c:5008
msgid ".pdesc has no matching .ent"
msgstr ""
-#: config/tc-alpha.c:4788
+#: config/tc-alpha.c:5019
msgid ".pdesc directive has no entry symbol"
msgstr ""
-#: config/tc-alpha.c:4801
+#: config/tc-alpha.c:5032
msgid "No comma after .pdesc <entryname>"
msgstr ""
-#: config/tc-alpha.c:4824
+#: config/tc-alpha.c:5055
msgid "unknown procedure kind"
msgstr ""
-#: config/tc-alpha.c:4917
+#: config/tc-alpha.c:5148
msgid ".name directive not in link (.link) section"
msgstr ""
-#: config/tc-alpha.c:4925
+#: config/tc-alpha.c:5156
msgid ".name directive has no symbol"
msgstr ""
-#: config/tc-alpha.c:4959
+#: config/tc-alpha.c:5190
msgid "No symbol after .linkage"
msgstr ""
-#: config/tc-alpha.c:4987
+#: config/tc-alpha.c:5218
msgid "No symbol after .code_address"
msgstr ""
-#: config/tc-alpha.c:5020
+#: config/tc-alpha.c:5251
msgid "Bad .mask directive"
msgstr ""
-#: config/tc-alpha.c:5041
+#: config/tc-alpha.c:5272
msgid "Bad .fmask directive"
msgstr ""
-#: config/tc-alpha.c:5211
+#: config/tc-alpha.c:5440
#, c-format
msgid "Expected comma after name \"%s\""
msgstr ""
#. *symbol_get_obj (symbolP) = (signed char) temp;
-#: config/tc-alpha.c:5222
+#: config/tc-alpha.c:5451
#, c-format
msgid "unhandled: .proc %s,%d"
msgstr ""
-#: config/tc-alpha.c:5257
+#: config/tc-alpha.c:5486
#, c-format
msgid "Tried to .set unrecognized mode `%s'"
msgstr ""
#. not fatal, but it might not work in the end
-#: config/tc-alpha.c:5274
+#: config/tc-alpha.c:5503
msgid "File overrides no-base-register option."
msgstr ""
-#: config/tc-alpha.c:5291
+#: config/tc-alpha.c:5520
#, c-format
msgid "Bad base register, using $%d."
msgstr ""
-#: config/tc-alpha.c:5313
+#: config/tc-alpha.c:5542
#, c-format
msgid "Alignment too large: %d. assumed"
msgstr ""
-#: config/tc-alpha.c:5317 config/tc-d30v.c:2214
+#: config/tc-alpha.c:5546 config/tc-d30v.c:2200
msgid "Alignment negative: 0 assumed"
msgstr ""
-#: config/tc-alpha.c:5629
+#: config/tc-alpha.c:5860
#, c-format
msgid "Chose GP value of %lx\n"
msgstr ""
-#: config/tc-alpha.c:5645 config/tc-ia64.c:958
+#: config/tc-alpha.c:5876
msgid "Bad .section directive: want a,s,w,x,M,S,G,T in string"
msgstr ""
-#: config/tc-arc.c:1616 config/tc-arm.c:10347
+#: config/tc-arc.c:1615 config/tc-arm.c:11416 config/tc-ip2k.c:219
msgid "md_estimate_size_before_relax\n"
msgstr ""
-#: config/tc-arc.c:1628
+#: config/tc-arc.c:1627
msgid "md_convert_frag\n"
msgstr ""
-#: config/tc-arm.c:681
+#. We can't actually support subtracting a symbol.
+#: config/tc-arc.c:1898 config/tc-arm.c:6617 config/tc-arm.c:9705
+#: config/tc-arm.c:9805 config/tc-avr.c:854 config/tc-cris.c:3123
+#: config/tc-d10v.c:1710 config/tc-d30v.c:1851 config/tc-mips.c:3630
+#: config/tc-mips.c:4695 config/tc-mips.c:5828 config/tc-mips.c:6517
+#: config/tc-msp430.c:1403 config/tc-ppc.c:5460 config/tc-v850.c:2356
+#: config/tc-xstormy16.c:483
+msgid "expression too complex"
+msgstr ""
+
+#: config/tc-arm.c:763
msgid "ARM register expected"
msgstr ""
-#: config/tc-arm.c:682 config/tc-arm.c:2846
+#: config/tc-arm.c:764 config/tc-arm.c:3174
msgid "bad or missing co-processor number"
msgstr ""
#. In the few cases where we might be able to accept something else
#. this error can be overridden.
-#: config/tc-arm.c:683 config/tc-arm.c:2901
+#: config/tc-arm.c:765 config/tc-arm.c:3229
msgid "co-processor register expected"
msgstr ""
-#: config/tc-arm.c:684
+#: config/tc-arm.c:766
msgid "FPA register expected"
msgstr ""
-#: config/tc-arm.c:685
+#: config/tc-arm.c:767
msgid "VFP single precision register expected"
msgstr ""
-#: config/tc-arm.c:686
+#: config/tc-arm.c:768
msgid "VFP double precision register expected"
msgstr ""
-#: config/tc-arm.c:687
+#: config/tc-arm.c:769
msgid "Maverick MVF register expected"
msgstr ""
-#: config/tc-arm.c:688
+#: config/tc-arm.c:770
msgid "Maverick MVD register expected"
msgstr ""
-#: config/tc-arm.c:689 config/tc-arm.c:690
+#: config/tc-arm.c:771 config/tc-arm.c:772
msgid "Maverick MVFX register expected"
msgstr ""
-#: config/tc-arm.c:691
+#: config/tc-arm.c:773
msgid "Maverick MVAX register expected"
msgstr ""
-#: config/tc-arm.c:692
+#: config/tc-arm.c:774
msgid "Maverick DSPSC register expected"
msgstr ""
-#: config/tc-arm.c:2036
+#: config/tc-arm.c:775
+msgid "Intel Wireless MMX technology register expected"
+msgstr ""
+
+#: config/tc-arm.c:2309
msgid "bad arguments to instruction"
msgstr ""
-#: config/tc-arm.c:2037
+#: config/tc-arm.c:2310
msgid "r15 not allowed here"
msgstr ""
-#: config/tc-arm.c:2038
+#: config/tc-arm.c:2311
msgid "instruction is not conditional"
msgstr ""
-#: config/tc-arm.c:2039
+#: config/tc-arm.c:2312
msgid "acc0 expected"
msgstr ""
-#: config/tc-arm.c:2184
+#: config/tc-arm.c:2505
msgid "literal pool overflow"
msgstr ""
-#: config/tc-arm.c:2326
+#: config/tc-arm.c:2647
msgid "invalid syntax for .req directive"
msgstr ""
-#: config/tc-arm.c:2401
+#: config/tc-arm.c:2727
#, c-format
msgid "alignment too large: %d assumed"
msgstr ""
-#: config/tc-arm.c:2404
+#: config/tc-arm.c:2730
msgid "alignment negative. 0 assumed."
msgstr ""
-#: config/tc-arm.c:2488
+#: config/tc-arm.c:2814
#, c-format
msgid "expected comma after name \"%s\""
msgstr ""
-#: config/tc-arm.c:2538 config/tc-m32r.c:418
+#: config/tc-arm.c:2864 config/tc-m32r.c:420
#, c-format
msgid "symbol `%s' already defined"
msgstr ""
-#: config/tc-arm.c:2612
+#: config/tc-arm.c:2889
msgid "selected processor does not support THUMB opcodes"
msgstr ""
-#: config/tc-arm.c:2625
+#: config/tc-arm.c:2902
msgid "selected processor does not support ARM opcodes"
msgstr ""
-#: config/tc-arm.c:2637
+#: config/tc-arm.c:2914
#, c-format
msgid "invalid instruction size selected (%d)"
msgstr ""
-#: config/tc-arm.c:2672
+#: config/tc-arm.c:2949
#, c-format
msgid "invalid operand to .code directive (%d) (expecting 16 or 32)"
msgstr ""
-#: config/tc-arm.c:2683
+#: config/tc-arm.c:2960
msgid "garbage following instruction"
msgstr ""
#. In the few cases where we might be able to accept something else
#. this error can be overridden.
-#: config/tc-arm.c:2733
+#: config/tc-arm.c:3010
#, c-format
msgid "register expected, not '%.100s'"
msgstr ""
#. In the few cases where we might be able to accept
#. something else this error can be overridden.
-#: config/tc-arm.c:2805
+#: config/tc-arm.c:3061
+#, c-format
+msgid "Intel Wireless MMX technology register expected, not '%.100s'"
+msgstr ""
+
+#. In the few cases where we might be able to accept
+#. something else this error can be overridden.
+#: config/tc-arm.c:3133
msgid "flag for {c}psr instruction expected"
msgstr ""
-#: config/tc-arm.c:2839
+#: config/tc-arm.c:3167
msgid "illegal co-processor number"
msgstr ""
-#: config/tc-arm.c:2871 config/tc-arm.c:3931 config/tc-arm.c:4113
+#: config/tc-arm.c:3199 config/tc-arm.c:4778
msgid "bad or missing expression"
msgstr ""
-#: config/tc-arm.c:2877
+#: config/tc-arm.c:3205
msgid "immediate co-processor expression too large"
msgstr ""
#. In the few cases where we might be able to accept something else
#. this error can be overridden.
-#: config/tc-arm.c:2924
+#: config/tc-arm.c:3252
msgid "floating point register expected"
msgstr ""
-#: config/tc-arm.c:2941
+#: config/tc-arm.c:3269 config/tc-arm.c:3414
msgid "immediate expression expected"
msgstr ""
-#: config/tc-arm.c:2956
+#: config/tc-arm.c:3284
msgid "co-processor address must be word aligned"
msgstr ""
-#: config/tc-arm.c:2962
+#: config/tc-arm.c:3290 config/tc-arm.c:3429
msgid "offset too large"
msgstr ""
-#: config/tc-arm.c:3011
+#: config/tc-arm.c:3339 config/tc-arm.c:3477
msgid "pc may not be used in post-increment"
msgstr ""
-#: config/tc-arm.c:3027 config/tc-arm.c:3472 config/tc-arm.c:4282
-#: config/tc-arm.c:5149 config/tc-arm.c:5483
+#: config/tc-arm.c:3355 config/tc-arm.c:3493 config/tc-arm.c:3938
+#: config/tc-arm.c:5197 config/tc-arm.c:6064 config/tc-arm.c:6398
msgid "pre-indexed expression expected"
msgstr ""
-#: config/tc-arm.c:3040 config/tc-arm.c:3485 config/tc-arm.c:4293
-#: config/tc-arm.c:5161 config/tc-arm.c:5495 config/tc-arm.c:5844
-#: config/tc-arm.c:8508 config/tc-arm.c:8523
+#: config/tc-arm.c:3368 config/tc-arm.c:3506 config/tc-arm.c:3951
+#: config/tc-arm.c:5208 config/tc-arm.c:6076 config/tc-arm.c:6410
+#: config/tc-arm.c:6784 config/tc-arm.c:9448 config/tc-arm.c:9463
msgid "missing ]"
msgstr ""
-#: config/tc-arm.c:3050
+#: config/tc-arm.c:3378 config/tc-arm.c:3516
msgid "pc may not be used with write-back"
msgstr ""
-#: config/tc-arm.c:3102
+#: config/tc-arm.c:3568
msgid "comma expected after register name"
msgstr ""
-#: config/tc-arm.c:3121
+#: config/tc-arm.c:3587
msgid "CPSR or SPSR expected"
msgstr ""
-#: config/tc-arm.c:3147
+#: config/tc-arm.c:3613
msgid "comma missing after psr flags"
msgstr ""
-#: config/tc-arm.c:3163 config/tc-arm.c:3173
+#: config/tc-arm.c:3629 config/tc-arm.c:3639
msgid "only a register or immediate value can follow a psr flag"
msgstr ""
-#: config/tc-arm.c:3184
+#: config/tc-arm.c:3650
msgid "immediate value cannot be used to set this field"
msgstr ""
-#: config/tc-arm.c:3202 config/tc-arm.c:4509 config/tc-arm.c:4789
-#: config/tc-arm.c:4809 config/tc-i960.c:1925
+#: config/tc-arm.c:3668 config/tc-arm.c:5424 config/tc-arm.c:5704
+#: config/tc-arm.c:5724 config/tc-i960.c:1935
msgid "invalid constant"
msgstr ""
-#: config/tc-arm.c:3250
+#: config/tc-arm.c:3716
msgid "rdhi, rdlo and rm must all be different"
msgstr ""
-#: config/tc-arm.c:3304
+#: config/tc-arm.c:3770
msgid "rd and rm should be different in mul"
msgstr ""
-#: config/tc-arm.c:3358
+#: config/tc-arm.c:3824
msgid "rd and rm should be different in mla"
msgstr ""
-#: config/tc-arm.c:3406
+#: config/tc-arm.c:3872
#, c-format
msgid "acc0 expected, not '%.100s'"
msgstr ""
-#: config/tc-arm.c:3584
+#: config/tc-arm.c:4050
msgid "rdhi and rdlo must be different"
msgstr ""
-#: config/tc-arm.c:3692
+#: config/tc-arm.c:4158
msgid "Warning: instruction unpredictable when using r15"
msgstr ""
-#: config/tc-arm.c:3907
+#: config/tc-arm.c:4373
msgid "use of r15 in bxj is not really useful"
msgstr ""
-#: config/tc-arm.c:3940 config/tc-arm.c:4122 config/tc-arm.c:7449
-#: config/tc-arm.c:7484 config/tc-arm.c:7494
+#: config/tc-arm.c:4400 config/tc-arm.c:4585 config/tc-arm.c:5445 expr.c:1318
+#: read.c:2206
+msgid "bad expression"
+msgstr ""
+
+#: config/tc-arm.c:4409 config/tc-arm.c:4594 config/tc-arm.c:4786
+#: config/tc-arm.c:8389 config/tc-arm.c:8424 config/tc-arm.c:8434
+#: config/tc-z8k.c:1161 config/tc-z8k.c:1173
msgid "immediate value out of range"
msgstr ""
-#: config/tc-arm.c:4245
+#: config/tc-arm.c:4833
+msgid "only r15 allowed here"
+msgstr ""
+
+#: config/tc-arm.c:5160
msgid "'[' expected after PLD mnemonic"
msgstr ""
-#: config/tc-arm.c:4267
+#: config/tc-arm.c:5182
msgid "post-indexed expression used in preload instruction"
msgstr ""
-#: config/tc-arm.c:4272 config/tc-arm.c:4302
+#: config/tc-arm.c:5187 config/tc-arm.c:5217
msgid "writeback used in preload instruction"
msgstr ""
-#: config/tc-arm.c:4344
+#: config/tc-arm.c:5259
msgid "destination register must be even"
msgstr ""
-#: config/tc-arm.c:4350
+#: config/tc-arm.c:5265
msgid "r14 not allowed here"
msgstr ""
-#: config/tc-arm.c:4357
+#: config/tc-arm.c:5272
msgid "pre/post-indexing used when modified address register is destination"
msgstr ""
-#: config/tc-arm.c:4367
+#: config/tc-arm.c:5282
msgid "ldrd destination registers must not overlap index register"
msgstr ""
-#: config/tc-arm.c:4493
+#: config/tc-arm.c:5408
msgid "bad_segment"
msgstr ""
-#: config/tc-arm.c:4530 expr.c:1314 read.c:2203
-msgid "bad expression"
-msgstr ""
-
-#: config/tc-arm.c:4553 config/tc-arm.c:4564
+#: config/tc-arm.c:5468 config/tc-arm.c:5479
msgid "shift expression expected"
msgstr ""
-#: config/tc-arm.c:4588
+#: config/tc-arm.c:5503
msgid "shift requires register or #expression"
msgstr ""
-#: config/tc-arm.c:4589
+#: config/tc-arm.c:5504
msgid "shift requires #expression"
msgstr ""
-#: config/tc-arm.c:4619
+#: config/tc-arm.c:5534
msgid "shift of 0 ignored."
msgstr ""
-#: config/tc-arm.c:4625
+#: config/tc-arm.c:5540
msgid "invalid immediate shift"
msgstr ""
-#: config/tc-arm.c:4780 config/tc-arm.c:5197 config/tc-arm.c:5532
-#: config/tc-arm.c:6141 config/tc-v850.c:1867 config/tc-v850.c:1888
+#: config/tc-arm.c:5695 config/tc-arm.c:6112 config/tc-arm.c:6447
+#: config/tc-arm.c:7081 config/tc-v850.c:1907 config/tc-v850.c:1928
msgid "constant expression expected"
msgstr ""
-#: config/tc-arm.c:4822
+#: config/tc-arm.c:5737
msgid "register or shift expression expected"
msgstr ""
-#: config/tc-arm.c:4875
+#: config/tc-arm.c:5790
msgid "invalid floating point immediate expression"
msgstr ""
-#: config/tc-arm.c:4879
+#: config/tc-arm.c:5794
msgid "floating point register or immediate expression expected"
msgstr ""
-#: config/tc-arm.c:5033 config/tc-arm.c:5363
+#: config/tc-arm.c:5948 config/tc-arm.c:6278
msgid "address offset too large"
msgstr ""
-#: config/tc-arm.c:5091 config/tc-arm.c:5281 config/tc-arm.c:5423
+#: config/tc-arm.c:6006 config/tc-arm.c:6196 config/tc-arm.c:6338
msgid "address expected"
msgstr ""
-#: config/tc-arm.c:5121 config/tc-arm.c:5133 config/tc-arm.c:5170
-#: config/tc-arm.c:5299 config/tc-arm.c:5453 config/tc-arm.c:5467
-#: config/tc-arm.c:5504
+#: config/tc-arm.c:6036 config/tc-arm.c:6048 config/tc-arm.c:6085
+#: config/tc-arm.c:6214 config/tc-arm.c:6368 config/tc-arm.c:6382
+#: config/tc-arm.c:6419
#, c-format
msgid "%s register same as write-back base"
msgstr ""
-#: config/tc-arm.c:5123 config/tc-arm.c:5135 config/tc-arm.c:5172
-#: config/tc-arm.c:5301 config/tc-arm.c:5455 config/tc-arm.c:5469
-#: config/tc-arm.c:5506
+#: config/tc-arm.c:6038 config/tc-arm.c:6050 config/tc-arm.c:6087
+#: config/tc-arm.c:6216 config/tc-arm.c:6370 config/tc-arm.c:6384
+#: config/tc-arm.c:6421
msgid "destination"
msgstr ""
-#: config/tc-arm.c:5123 config/tc-arm.c:5135 config/tc-arm.c:5172
-#: config/tc-arm.c:5301 config/tc-arm.c:5455 config/tc-arm.c:5469
-#: config/tc-arm.c:5506
+#: config/tc-arm.c:6038 config/tc-arm.c:6050 config/tc-arm.c:6087
+#: config/tc-arm.c:6216 config/tc-arm.c:6370 config/tc-arm.c:6384
+#: config/tc-arm.c:6421
msgid "source"
msgstr ""
-#: config/tc-arm.c:5182 config/tc-arm.c:5516 config/tc-arm.c:7755
+#: config/tc-arm.c:6097 config/tc-arm.c:6431 config/tc-arm.c:8695
msgid "invalid pseudo operation"
msgstr ""
-#: config/tc-arm.c:5234 config/tc-arm.c:5567
+#: config/tc-arm.c:6149 config/tc-arm.c:6482
msgid "literal pool insertion failed"
msgstr ""
-#: config/tc-arm.c:5329 config/tc-arm.c:5335
+#: config/tc-arm.c:6244 config/tc-arm.c:6250
msgid "post-indexed expression expected"
msgstr ""
-#: config/tc-arm.c:5633
+#: config/tc-arm.c:6548
msgid "bad range in register list"
msgstr ""
-#: config/tc-arm.c:5641 config/tc-arm.c:5650 config/tc-arm.c:5692
+#: config/tc-arm.c:6556 config/tc-arm.c:6565 config/tc-arm.c:6607
#, c-format
msgid "Warning: duplicated register (r%d) in register list"
msgstr ""
-#: config/tc-arm.c:5653
+#: config/tc-arm.c:6568
msgid "Warning: register range not in ascending order"
msgstr ""
-#: config/tc-arm.c:5665
+#: config/tc-arm.c:6580
msgid "missing `}'"
msgstr ""
-#: config/tc-arm.c:5681
+#: config/tc-arm.c:6596
msgid "invalid register mask"
msgstr ""
-#: config/tc-arm.c:5702 config/tc-arm.c:8765 config/tc-arm.c:8865
-#: config/tc-avr.c:866 config/tc-cris.c:3006 config/tc-d10v.c:1724
-#: config/tc-d30v.c:1863 config/tc-mips.c:3570 config/tc-mips.c:4594
-#: config/tc-mips.c:5505 config/tc-mips.c:6159 config/tc-ppc.c:5175
-#: config/tc-v850.c:2287 config/tc-xstormy16.c:479
-msgid "expression too complex"
+#: config/tc-arm.c:6655
+msgid "r15 not allowed as base register"
msgstr ""
-#: config/tc-arm.c:5740
-msgid "r15 not allowed as base register"
+#: config/tc-arm.c:6689 config/tc-arm.c:6698
+msgid "writeback of base register is UNPREDICTABLE"
+msgstr ""
+
+#: config/tc-arm.c:6692
+msgid "writeback of base register when in register list is UNPREDICTABLE"
msgstr ""
-#: config/tc-arm.c:5804 config/tc-arm.c:5818
+#: config/tc-arm.c:6702
+msgid "if writeback register is in list, it must be the lowest reg in the list"
+msgstr ""
+
+#: config/tc-arm.c:6744 config/tc-arm.c:6758
msgid "r15 not allowed in swap"
msgstr ""
-#: config/tc-arm.c:5913
+#: config/tc-arm.c:6853
msgid "use of r15 in bx in ARM mode is not really useful"
msgstr ""
-#: config/tc-arm.c:6147
+#: config/tc-arm.c:7087
msgid "constant value required for number of registers"
msgstr ""
-#: config/tc-arm.c:6155
+#: config/tc-arm.c:7095
msgid "number of registers must be in the range [1:4]"
msgstr ""
-#: config/tc-arm.c:6216
+#: config/tc-arm.c:7156
msgid "r15 not allowed as base register with write-back"
msgstr ""
-#: config/tc-arm.c:6598
+#: config/tc-arm.c:7538
msgid "only two consecutive VFP SP registers allowed here"
msgstr ""
-#: config/tc-arm.c:6766
+#: config/tc-arm.c:7706
msgid "VFP system register expected"
msgstr ""
-#: config/tc-arm.c:6904 config/tc-arm.c:6943 config/tc-arm.c:6956
-#: config/tc-arm.c:7017 config/tc-arm.c:7056 config/tc-arm.c:7069
-#: config/tc-mips.c:9336 config/tc-mips.c:9366
+#: config/tc-arm.c:7844 config/tc-arm.c:7883 config/tc-arm.c:7896
+#: config/tc-arm.c:7957 config/tc-arm.c:7996 config/tc-arm.c:8009
+#: config/tc-h8300.c:1035 config/tc-mips.c:9723 config/tc-mips.c:9753
msgid "invalid register list"
msgstr ""
-#: config/tc-arm.c:6910 config/tc-arm.c:7023
+#: config/tc-arm.c:7850 config/tc-arm.c:7963
msgid "register list not in ascending order"
msgstr ""
-#: config/tc-arm.c:6935 config/tc-arm.c:7048
+#: config/tc-arm.c:7875 config/tc-arm.c:7988
msgid "register range not in ascending order"
msgstr ""
-#: config/tc-arm.c:6973 config/tc-arm.c:7086
+#: config/tc-arm.c:7913 config/tc-arm.c:8026
msgid "non-contiguous register range"
msgstr ""
-#: config/tc-arm.c:7116 config/tc-arm.c:7153
+#: config/tc-arm.c:8056 config/tc-arm.c:8093
msgid "this addressing mode requires base-register writeback"
msgstr ""
-#: config/tc-arm.c:7313
+#: config/tc-arm.c:8253
msgid "lo register required"
msgstr ""
-#: config/tc-arm.c:7321
+#: config/tc-arm.c:8261
msgid "hi register required"
msgstr ""
-#: config/tc-arm.c:7391 config/tc-arm.c:8597
+#: config/tc-arm.c:8331 config/tc-arm.c:9537
msgid "dest and source1 must be the same register"
msgstr ""
-#: config/tc-arm.c:7398
+#: config/tc-arm.c:8338
msgid "subtract valid only on lo regs"
msgstr ""
-#: config/tc-arm.c:7422
+#: config/tc-arm.c:8362
msgid "invalid Hi register with immediate"
msgstr ""
-#: config/tc-arm.c:7462
+#: config/tc-arm.c:8402
msgid "invalid immediate value for stack adjust"
msgstr ""
-#: config/tc-arm.c:7473
+#: config/tc-arm.c:8413
msgid "invalid immediate for address calculation"
msgstr ""
-#: config/tc-arm.c:7560
+#: config/tc-arm.c:8500
msgid "source1 and dest must be same register"
msgstr ""
-#: config/tc-arm.c:7594
+#: config/tc-arm.c:8534
msgid "invalid immediate for shift"
msgstr ""
-#: config/tc-arm.c:7673
+#: config/tc-arm.c:8613
msgid "only lo regs allowed with immediate"
msgstr ""
-#: config/tc-arm.c:7692
+#: config/tc-arm.c:8632
msgid "invalid immediate"
msgstr ""
-#: config/tc-arm.c:7746
+#: config/tc-arm.c:8686
msgid "expected ']'"
msgstr ""
-#: config/tc-arm.c:7819
+#: config/tc-arm.c:8759
msgid "byte or halfword not valid for base register"
msgstr ""
-#: config/tc-arm.c:7824
+#: config/tc-arm.c:8764
msgid "r15 based store not allowed"
msgstr ""
-#: config/tc-arm.c:7829
+#: config/tc-arm.c:8769
msgid "invalid base register for register offset"
msgstr ""
-#: config/tc-arm.c:7847 config/tc-arm.c:7882
+#: config/tc-arm.c:8787 config/tc-arm.c:8822
msgid "invalid offset"
msgstr ""
-#: config/tc-arm.c:7858
+#: config/tc-arm.c:8798
msgid "invalid base register in load/store"
msgstr ""
-#: config/tc-arm.c:8401
+#: config/tc-arm.c:9341
msgid "expecting immediate, 7bit operand"
msgstr ""
-#: config/tc-arm.c:8416
+#: config/tc-arm.c:9356
msgid "immediate out of range"
msgstr ""
-#: config/tc-arm.c:8459
+#: config/tc-arm.c:9399
msgid "offset expected"
msgstr ""
-#: config/tc-arm.c:8468 config/tc-pj.c:528 config/tc-sh.c:3591
+#: config/tc-arm.c:9408 config/tc-pj.c:537 config/tc-sh.c:3593
msgid "offset out of range"
msgstr ""
-#: config/tc-arm.c:8605
+#: config/tc-arm.c:9545
msgid "Rs and Rd must be different in MUL"
msgstr ""
-#: config/tc-arm.c:8749
+#: config/tc-arm.c:9689
msgid ""
"inserted missing '!': load/store multiple always writes back base register"
msgstr ""
-#: config/tc-arm.c:8771
+#: config/tc-arm.c:9711
msgid "only lo-regs valid in load/store multiple"
msgstr ""
-#: config/tc-arm.c:8817
+#: config/tc-arm.c:9757
msgid "syntax: ldrs[b] Rd, [Rb, Ro]"
msgstr ""
-#: config/tc-arm.c:8881
+#: config/tc-arm.c:9821
msgid "invalid register list to push/pop instruction"
msgstr ""
-#: config/tc-arm.c:8993 config/tc-arm.c:9171
+#: config/tc-arm.c:9933 config/tc-arm.c:10159
msgid "virtual memory exhausted"
msgstr ""
-#: config/tc-arm.c:9074
+#: config/tc-arm.c:10014
#, c-format
msgid "register '%s' does not exist\n"
msgstr ""
-#: config/tc-arm.c:9078
+#: config/tc-arm.c:10018
#, c-format
msgid ""
"ignoring redefinition of register alias '%s' to non-existant register '%s'"
msgstr ""
-#: config/tc-arm.c:9087
+#: config/tc-arm.c:10027
#, c-format
msgid "ignoring redefinition of register alias '%s'"
msgstr ""
-#: config/tc-arm.c:9093
+#: config/tc-arm.c:10033
msgid "ignoring incomplete .req pseuso op"
msgstr ""
-#: config/tc-arm.c:9195
+#: config/tc-arm.c:10183
msgid "use of old and new-style options to set CPU type"
msgstr ""
-#: config/tc-arm.c:9205
+#: config/tc-arm.c:10193
msgid "use of old and new-style options to set FPU type"
msgstr ""
-#: config/tc-arm.c:9415
+#: config/tc-arm.c:10473
msgid "bad call to MD_ATOF()"
msgstr ""
-#: config/tc-arm.c:9645
+#: config/tc-arm.c:10703
#, c-format
msgid "invalid constant (%lx) after fixup"
msgstr ""
-#: config/tc-arm.c:9681
+#: config/tc-arm.c:10741
#, c-format
msgid "unable to compute ADRL instructions for PC offset of 0x%lx"
msgstr ""
-#: config/tc-arm.c:9711
+#: config/tc-arm.c:10771
#, c-format
msgid "bad immediate value for offset (%ld)"
msgstr ""
-#: config/tc-arm.c:9733 config/tc-arm.c:9755
+#: config/tc-arm.c:10793 config/tc-arm.c:10815
msgid "invalid literal constant: pool needs to be closer"
msgstr ""
-#: config/tc-arm.c:9735
+#: config/tc-arm.c:10795
#, c-format
msgid "bad immediate value for half-word offset (%ld)"
msgstr ""
-#: config/tc-arm.c:9772
+#: config/tc-arm.c:10832
msgid "shift expression is too large"
msgstr ""
-#: config/tc-arm.c:9791 config/tc-arm.c:9800
+#: config/tc-arm.c:10851 config/tc-arm.c:10860
msgid "invalid swi expression"
msgstr ""
-#: config/tc-arm.c:9810
+#: config/tc-arm.c:10870
msgid "invalid expression in load/store multiple"
msgstr ""
-#: config/tc-arm.c:9863
+#: config/tc-arm.c:10923
msgid "GAS can't handle same-section branch dest >= 0x04000000"
msgstr ""
-#: config/tc-arm.c:9872
+#: config/tc-arm.c:10932
msgid "out of range branch"
msgstr ""
-#: config/tc-arm.c:9905 config/tc-arm.c:9921
+#: config/tc-arm.c:10965 config/tc-arm.c:10981
msgid "branch out of range"
msgstr ""
-#: config/tc-arm.c:9945
+#: config/tc-arm.c:11005
msgid "branch with link out of range"
msgstr ""
-#: config/tc-arm.c:10018
+#: config/tc-arm.c:11074
msgid "illegal value for co-processor offset"
msgstr ""
-#: config/tc-arm.c:10042
+#: config/tc-arm.c:11086
+msgid "Illegal value for co-processor offset"
+msgstr ""
+
+#: config/tc-arm.c:11110
#, c-format
msgid "invalid offset, target not word aligned (0x%08X)"
msgstr ""
-#: config/tc-arm.c:10048 config/tc-arm.c:10057 config/tc-arm.c:10064
-#: config/tc-arm.c:10071 config/tc-arm.c:10078
+#: config/tc-arm.c:11116 config/tc-arm.c:11126 config/tc-arm.c:11134
+#: config/tc-arm.c:11142 config/tc-arm.c:11150
#, c-format
msgid "invalid offset, value too big (0x%08lX)"
msgstr ""
-#: config/tc-arm.c:10117
+#: config/tc-arm.c:11190
msgid "invalid immediate for stack address calculation"
msgstr ""
-#: config/tc-arm.c:10126
+#: config/tc-arm.c:11199
#, c-format
msgid "invalid immediate for address calculation (value = 0x%08lX)"
msgstr ""
-#: config/tc-arm.c:10136
+#: config/tc-arm.c:11209
msgid "invalid 8bit immediate"
msgstr ""
-#: config/tc-arm.c:10144
+#: config/tc-arm.c:11217
msgid "invalid 3bit immediate"
msgstr ""
-#: config/tc-arm.c:10160
+#: config/tc-arm.c:11233
#, c-format
msgid "invalid immediate: %ld is too large"
msgstr ""
-#: config/tc-arm.c:10175
+#: config/tc-arm.c:11248
#, c-format
msgid "illegal Thumb shift value: %ld"
msgstr ""
-#: config/tc-arm.c:10189
+#: config/tc-arm.c:11262
#, c-format
msgid "bad relocation fixup type (%d)"
msgstr ""
-#: config/tc-arm.c:10260
-msgid "literal referenced across section boundary (Implicit dump?)"
+#: config/tc-arm.c:11333
+msgid "literal referenced across section boundary"
msgstr ""
-#: config/tc-arm.c:10273
-#, c-format
-msgid "internal relocation (type %d) not fixed up (IMMEDIATE)"
+#: config/tc-arm.c:11346
+msgid "internal relocation (type: IMMEDIATE) not fixed up"
msgstr ""
-#: config/tc-arm.c:10279
+#: config/tc-arm.c:11351
msgid "ADRL used for a symbol not defined in the same file"
msgstr ""
-#: config/tc-arm.c:10284
-#, c-format
-msgid "internal_relocation (type %d) not fixed up (OFFSET_IMM)"
+#: config/tc-arm.c:11356
+msgid "internal_relocation (type: OFFSET_IMM) not fixed up"
msgstr ""
-#: config/tc-arm.c:10305 config/tc-cris.c:2940 config/tc-mcore.c:2104
-#: config/tc-mmix.c:2869 config/tc-ns32k.c:2350
+#: config/tc-arm.c:11374 config/tc-cris.c:3063 config/tc-mcore.c:2052
+#: config/tc-mmix.c:2867 config/tc-ns32k.c:2396
msgid "<unknown>"
msgstr ""
-#: config/tc-arm.c:10308 config/tc-arm.c:10329
+#: config/tc-arm.c:11377 config/tc-arm.c:11398
#, c-format
msgid "cannot represent %s relocation in this object file format"
msgstr ""
-#: config/tc-arm.c:10425
+#: config/tc-arm.c:11494
#, c-format
msgid "no operator -- statement `%s'\n"
msgstr ""
-#: config/tc-arm.c:10443 config/tc-arm.c:10468
+#: config/tc-arm.c:11512 config/tc-arm.c:11537
#, c-format
msgid "selected processor does not support `%s'"
msgstr ""
-#: config/tc-arm.c:10485
+#: config/tc-arm.c:11554
#, c-format
msgid "bad instruction `%s'"
msgstr ""
-#: config/tc-arm.c:10586
+#: config/tc-arm.c:11655
msgid "generate PIC code"
msgstr ""
-#: config/tc-arm.c:10587
+#: config/tc-arm.c:11656
msgid "assemble Thumb code"
msgstr ""
-#: config/tc-arm.c:10588
+#: config/tc-arm.c:11657
msgid "support ARM/Thumb interworking"
msgstr ""
-#: config/tc-arm.c:10590
+#: config/tc-arm.c:11659
msgid "use old ABI (ELF only)"
msgstr ""
-#: config/tc-arm.c:10591
+#: config/tc-arm.c:11660
msgid "code uses 32-bit program counter"
msgstr ""
-#: config/tc-arm.c:10592
+#: config/tc-arm.c:11661
msgid "code uses 26-bit program counter"
msgstr ""
-#: config/tc-arm.c:10593
+#: config/tc-arm.c:11662
msgid "floating point args are in fp regs"
msgstr ""
-#: config/tc-arm.c:10595
+#: config/tc-arm.c:11664
msgid "re-entrant code"
msgstr ""
-#: config/tc-arm.c:10596
+#: config/tc-arm.c:11665
msgid "code is ATPCS conformant"
msgstr ""
-#: config/tc-arm.c:10597
+#: config/tc-arm.c:11666
msgid "assemble for big-endian"
msgstr ""
-#: config/tc-arm.c:10598
+#: config/tc-arm.c:11667
msgid "assemble for little-endian"
msgstr ""
#. These are recognized by the assembler, but have no affect on code.
-#: config/tc-arm.c:10602
+#: config/tc-arm.c:11671
msgid "use frame pointer"
msgstr ""
-#: config/tc-arm.c:10603
+#: config/tc-arm.c:11672
msgid "use stack size checking"
msgstr ""
#. DON'T add any new processors to this list -- we want the whole list
#. to go away... Add them to the processors table instead.
-#: config/tc-arm.c:10607 config/tc-arm.c:10608
+#: config/tc-arm.c:11676 config/tc-arm.c:11677
msgid "use -mcpu=arm1"
msgstr ""
-#: config/tc-arm.c:10609 config/tc-arm.c:10610
+#: config/tc-arm.c:11678 config/tc-arm.c:11679
msgid "use -mcpu=arm2"
msgstr ""
-#: config/tc-arm.c:10611 config/tc-arm.c:10612
+#: config/tc-arm.c:11680 config/tc-arm.c:11681
msgid "use -mcpu=arm250"
msgstr ""
-#: config/tc-arm.c:10613 config/tc-arm.c:10614
+#: config/tc-arm.c:11682 config/tc-arm.c:11683
msgid "use -mcpu=arm3"
msgstr ""
-#: config/tc-arm.c:10615 config/tc-arm.c:10616
+#: config/tc-arm.c:11684 config/tc-arm.c:11685
msgid "use -mcpu=arm6"
msgstr ""
-#: config/tc-arm.c:10617 config/tc-arm.c:10618
+#: config/tc-arm.c:11686 config/tc-arm.c:11687
msgid "use -mcpu=arm600"
msgstr ""
-#: config/tc-arm.c:10619 config/tc-arm.c:10620
+#: config/tc-arm.c:11688 config/tc-arm.c:11689
msgid "use -mcpu=arm610"
msgstr ""
-#: config/tc-arm.c:10621 config/tc-arm.c:10622
+#: config/tc-arm.c:11690 config/tc-arm.c:11691
msgid "use -mcpu=arm620"
msgstr ""
-#: config/tc-arm.c:10623 config/tc-arm.c:10624
+#: config/tc-arm.c:11692 config/tc-arm.c:11693
msgid "use -mcpu=arm7"
msgstr ""
-#: config/tc-arm.c:10625 config/tc-arm.c:10626
+#: config/tc-arm.c:11694 config/tc-arm.c:11695
msgid "use -mcpu=arm70"
msgstr ""
-#: config/tc-arm.c:10627 config/tc-arm.c:10628
+#: config/tc-arm.c:11696 config/tc-arm.c:11697
msgid "use -mcpu=arm700"
msgstr ""
-#: config/tc-arm.c:10629 config/tc-arm.c:10630
+#: config/tc-arm.c:11698 config/tc-arm.c:11699
msgid "use -mcpu=arm700i"
msgstr ""
-#: config/tc-arm.c:10631 config/tc-arm.c:10632
+#: config/tc-arm.c:11700 config/tc-arm.c:11701
msgid "use -mcpu=arm710"
msgstr ""
-#: config/tc-arm.c:10633 config/tc-arm.c:10634
+#: config/tc-arm.c:11702 config/tc-arm.c:11703
msgid "use -mcpu=arm710c"
msgstr ""
-#: config/tc-arm.c:10635 config/tc-arm.c:10636
+#: config/tc-arm.c:11704 config/tc-arm.c:11705
msgid "use -mcpu=arm720"
msgstr ""
-#: config/tc-arm.c:10637 config/tc-arm.c:10638
+#: config/tc-arm.c:11706 config/tc-arm.c:11707
msgid "use -mcpu=arm7d"
msgstr ""
-#: config/tc-arm.c:10639 config/tc-arm.c:10640
+#: config/tc-arm.c:11708 config/tc-arm.c:11709
msgid "use -mcpu=arm7di"
msgstr ""
-#: config/tc-arm.c:10641 config/tc-arm.c:10642
+#: config/tc-arm.c:11710 config/tc-arm.c:11711
msgid "use -mcpu=arm7m"
msgstr ""
-#: config/tc-arm.c:10643 config/tc-arm.c:10644
+#: config/tc-arm.c:11712 config/tc-arm.c:11713
msgid "use -mcpu=arm7dm"
msgstr ""
-#: config/tc-arm.c:10645 config/tc-arm.c:10646
+#: config/tc-arm.c:11714 config/tc-arm.c:11715
msgid "use -mcpu=arm7dmi"
msgstr ""
-#: config/tc-arm.c:10647 config/tc-arm.c:10648
+#: config/tc-arm.c:11716 config/tc-arm.c:11717
msgid "use -mcpu=arm7100"
msgstr ""
-#: config/tc-arm.c:10649 config/tc-arm.c:10650
+#: config/tc-arm.c:11718 config/tc-arm.c:11719
msgid "use -mcpu=arm7500"
msgstr ""
-#: config/tc-arm.c:10651 config/tc-arm.c:10652
+#: config/tc-arm.c:11720 config/tc-arm.c:11721
msgid "use -mcpu=arm7500fe"
msgstr ""
-#: config/tc-arm.c:10653 config/tc-arm.c:10654 config/tc-arm.c:10655
-#: config/tc-arm.c:10656
+#: config/tc-arm.c:11722 config/tc-arm.c:11723 config/tc-arm.c:11724
+#: config/tc-arm.c:11725
msgid "use -mcpu=arm7tdmi"
msgstr ""
-#: config/tc-arm.c:10657 config/tc-arm.c:10658
+#: config/tc-arm.c:11726 config/tc-arm.c:11727
msgid "use -mcpu=arm710t"
msgstr ""
-#: config/tc-arm.c:10659 config/tc-arm.c:10660
+#: config/tc-arm.c:11728 config/tc-arm.c:11729
msgid "use -mcpu=arm720t"
msgstr ""
-#: config/tc-arm.c:10661 config/tc-arm.c:10662
+#: config/tc-arm.c:11730 config/tc-arm.c:11731
msgid "use -mcpu=arm740t"
msgstr ""
-#: config/tc-arm.c:10663 config/tc-arm.c:10664
+#: config/tc-arm.c:11732 config/tc-arm.c:11733
msgid "use -mcpu=arm8"
msgstr ""
-#: config/tc-arm.c:10665 config/tc-arm.c:10666
+#: config/tc-arm.c:11734 config/tc-arm.c:11735
msgid "use -mcpu=arm810"
msgstr ""
-#: config/tc-arm.c:10667 config/tc-arm.c:10668
+#: config/tc-arm.c:11736 config/tc-arm.c:11737
msgid "use -mcpu=arm9"
msgstr ""
-#: config/tc-arm.c:10669 config/tc-arm.c:10670
+#: config/tc-arm.c:11738 config/tc-arm.c:11739
msgid "use -mcpu=arm9tdmi"
msgstr ""
-#: config/tc-arm.c:10671 config/tc-arm.c:10672
+#: config/tc-arm.c:11740 config/tc-arm.c:11741
msgid "use -mcpu=arm920"
msgstr ""
-#: config/tc-arm.c:10673 config/tc-arm.c:10674
+#: config/tc-arm.c:11742 config/tc-arm.c:11743
msgid "use -mcpu=arm940"
msgstr ""
-#: config/tc-arm.c:10675
+#: config/tc-arm.c:11744
msgid "use -mcpu=strongarm"
msgstr ""
-#: config/tc-arm.c:10677
+#: config/tc-arm.c:11746
msgid "use -mcpu=strongarm110"
msgstr ""
-#: config/tc-arm.c:10679
+#: config/tc-arm.c:11748
msgid "use -mcpu=strongarm1100"
msgstr ""
-#: config/tc-arm.c:10681
+#: config/tc-arm.c:11750
msgid "use -mcpu=strongarm1110"
msgstr ""
-#: config/tc-arm.c:10682
+#: config/tc-arm.c:11751
msgid "use -mcpu=xscale"
msgstr ""
-#: config/tc-arm.c:10683
+#: config/tc-arm.c:11752
+msgid "use -mcpu=iwmmxt"
+msgstr ""
+
+#: config/tc-arm.c:11753
msgid "use -mcpu=all"
msgstr ""
#. Architecture variants -- don't add any more to this list either.
-#: config/tc-arm.c:10686 config/tc-arm.c:10687
+#: config/tc-arm.c:11756 config/tc-arm.c:11757
msgid "use -march=armv2"
msgstr ""
-#: config/tc-arm.c:10688 config/tc-arm.c:10689
+#: config/tc-arm.c:11758 config/tc-arm.c:11759
msgid "use -march=armv2a"
msgstr ""
-#: config/tc-arm.c:10690 config/tc-arm.c:10691
+#: config/tc-arm.c:11760 config/tc-arm.c:11761
msgid "use -march=armv3"
msgstr ""
-#: config/tc-arm.c:10692 config/tc-arm.c:10693
+#: config/tc-arm.c:11762 config/tc-arm.c:11763
msgid "use -march=armv3m"
msgstr ""
-#: config/tc-arm.c:10694 config/tc-arm.c:10695
+#: config/tc-arm.c:11764 config/tc-arm.c:11765
msgid "use -march=armv4"
msgstr ""
-#: config/tc-arm.c:10696 config/tc-arm.c:10697
+#: config/tc-arm.c:11766 config/tc-arm.c:11767
msgid "use -march=armv4t"
msgstr ""
-#: config/tc-arm.c:10698 config/tc-arm.c:10699
+#: config/tc-arm.c:11768 config/tc-arm.c:11769
msgid "use -march=armv5"
msgstr ""
-#: config/tc-arm.c:10700 config/tc-arm.c:10701
+#: config/tc-arm.c:11770 config/tc-arm.c:11771
msgid "use -march=armv5t"
msgstr ""
-#: config/tc-arm.c:10702 config/tc-arm.c:10703
+#: config/tc-arm.c:11772 config/tc-arm.c:11773
msgid "use -march=armv5te"
msgstr ""
#. Floating point variants -- don't add any more to this list either.
-#: config/tc-arm.c:10706
+#: config/tc-arm.c:11776
msgid "use -mfpu=fpe"
msgstr ""
-#: config/tc-arm.c:10707
+#: config/tc-arm.c:11777
msgid "use -mfpu=fpa10"
msgstr ""
-#: config/tc-arm.c:10708
+#: config/tc-arm.c:11778
msgid "use -mfpu=fpa11"
msgstr ""
-#: config/tc-arm.c:10710
+#: config/tc-arm.c:11780
msgid "use either -mfpu=softfpa or -mfpu=softvfp"
msgstr ""
-#: config/tc-arm.c:10890
+#: config/tc-arm.c:11963
msgid "invalid architectural extension"
msgstr ""
-#: config/tc-arm.c:10904
+#: config/tc-arm.c:11977
msgid "missing architectural extension"
msgstr ""
-#: config/tc-arm.c:10917
+#: config/tc-arm.c:11990
#, c-format
msgid "unknown architectural extnsion `%s'"
msgstr ""
-#: config/tc-arm.c:10942
+#: config/tc-arm.c:12015
#, c-format
msgid "missing cpu name `%s'"
msgstr ""
-#: config/tc-arm.c:10958
+#: config/tc-arm.c:12031
#, c-format
msgid "unknown cpu `%s'"
msgstr ""
-#: config/tc-arm.c:10977
+#: config/tc-arm.c:12050
#, c-format
msgid "missing architecture name `%s'"
msgstr ""
-#: config/tc-arm.c:10994
+#: config/tc-arm.c:12067
#, c-format
msgid "unknown architecture `%s'\n"
msgstr ""
-#: config/tc-arm.c:11011
+#: config/tc-arm.c:12084
#, c-format
msgid "unknown floating point format `%s'\n"
msgstr ""
-#: config/tc-arm.c:11017
+#: config/tc-arm.c:12090
msgid "<cpu name>\t assemble for CPU <cpu name>"
msgstr ""
-#: config/tc-arm.c:11019
+#: config/tc-arm.c:12092
msgid "<arch name>\t assemble for architecture <arch name>"
msgstr ""
-#: config/tc-arm.c:11021
+#: config/tc-arm.c:12094
msgid "<fpu name>\t assemble for FPU architecture <fpu name>"
msgstr ""
-#: config/tc-arm.c:11063 config/tc-arm.c:11085
+#: config/tc-arm.c:12136 config/tc-arm.c:12158
#, c-format
msgid "option `-%c%s' is deprecated: %s"
msgstr ""
-#: config/tc-arm.c:11094
+#: config/tc-arm.c:12167
#, c-format
msgid "unrecognized option `-%c%s'"
msgstr ""
-#: config/tc-arm.c:11108
+#: config/tc-arm.c:12181
msgid " ARM-specific assembler options:\n"
msgstr ""
-#: config/tc-arm.c:11119
+#: config/tc-arm.c:12192
msgid " -EB assemble code for a big-endian cpu\n"
msgstr ""
-#: config/tc-arm.c:11124
+#: config/tc-arm.c:12197
msgid " -EL assemble code for a little-endian cpu\n"
msgstr ""
-#: config/tc-arm.c:11306
+#: config/tc-arm.c:12381
#, c-format
msgid "%s: unexpected function type: %d"
msgstr ""
-#: config/tc-arm.c:11672
+#: config/tc-arm.c:12756
msgid "alignments greater than 32 bytes not supported in .text sections."
msgstr ""
@@ -2586,7 +2675,7 @@ msgid ""
" (default for avr3, avr5)\n"
msgstr ""
-#: config/tc-avr.c:330
+#: config/tc-avr.c:330 config/tc-msp430.c:257
#, c-format
msgid "unknown MCU: %s\n"
msgstr ""
@@ -2596,10 +2685,10 @@ msgstr ""
msgid "redefinition of mcu type `%s' to `%s'"
msgstr ""
-#: config/tc-avr.c:390 config/tc-d10v.c:319 config/tc-d30v.c:366
-#: config/tc-mips.c:9862 config/tc-mmix.c:2250 config/tc-mn10200.c:361
-#: config/tc-pj.c:357 config/tc-ppc.c:4835 config/tc-sh.c:2536
-#: config/tc-v850.c:1194
+#: config/tc-avr.c:390 config/tc-d10v.c:319 config/tc-d30v.c:365
+#: config/tc-mips.c:10137 config/tc-mmix.c:2246 config/tc-mn10200.c:361
+#: config/tc-msp430.c:378 config/tc-pj.c:374 config/tc-ppc.c:5105
+#: config/tc-sh.c:2528 config/tc-v850.c:1244
msgid "bad call to md_atof"
msgstr ""
@@ -2673,268 +2762,298 @@ msgstr ""
msgid "unknown constraint `%c'"
msgstr ""
-#: config/tc-avr.c:896 config/tc-avr.c:912 config/tc-avr.c:1013
+#: config/tc-avr.c:881 config/tc-avr.c:897 config/tc-avr.c:998
+#: config/tc-msp430.c:1431 config/tc-msp430.c:1448
#, c-format
msgid "odd address operand: %ld"
msgstr ""
-#: config/tc-avr.c:904 config/tc-avr.c:923 config/tc-d10v.c:586
+#: config/tc-avr.c:889 config/tc-avr.c:908 config/tc-d10v.c:586
+#: config/tc-d30v.c:655 config/tc-msp430.c:1439 config/tc-msp430.c:1453
+#: config/tc-msp430.c:1463
#, c-format
msgid "operand out of range: %ld"
msgstr ""
-#: config/tc-avr.c:1022 config/tc-d10v.c:1810 config/tc-d30v.c:1987
+#: config/tc-avr.c:1007 config/tc-d10v.c:1793 config/tc-d30v.c:1973
+#: config/tc-msp430.c:1481
#, c-format
msgid "line %d: unknown relocation type: 0x%x"
msgstr ""
-#: config/tc-avr.c:1036
+#: config/tc-avr.c:1021
msgid "only constant expression allowed"
msgstr ""
-#: config/tc-avr.c:1073 config/tc-d10v.c:1659 config/tc-d30v.c:1807
-#: config/tc-mn10200.c:1240 config/tc-mn10300.c:1781 config/tc-or32.c:1622
-#: config/tc-ppc.c:5573 config/tc-v850.c:2207
+#: config/tc-avr.c:1057 config/tc-d10v.c:1659 config/tc-d30v.c:1806
+#: config/tc-mn10200.c:1255 config/tc-mn10300.c:2303 config/tc-msp430.c:1520
+#: config/tc-or32.c:1618 config/tc-ppc.c:5919 config/tc-v850.c:2263
#, c-format
msgid "reloc %d not supported by object file format"
msgstr ""
-#: config/tc-avr.c:1097 config/tc-d10v.c:1248 config/tc-d10v.c:1262
-#: config/tc-h8300.c:1289 config/tc-h8500.c:1088 config/tc-mcore.c:988
-#: config/tc-pj.c:266 config/tc-sh.c:2104 config/tc-z8k.c:1196
+#: config/tc-avr.c:1081 config/tc-d10v.c:1248 config/tc-d10v.c:1262
+#: config/tc-h8300.c:1915 config/tc-h8500.c:1106 config/tc-mcore.c:938
+#: config/tc-msp430.c:438 config/tc-pj.c:283 config/tc-sh.c:2096
+#: config/tc-z8k.c:1238
msgid "can't find opcode "
msgstr ""
-#: config/tc-avr.c:1114
+#: config/tc-avr.c:1098
#, c-format
msgid "illegal opcode %s for mcu %s"
msgstr ""
-#: config/tc-avr.c:1122
+#: config/tc-avr.c:1106
msgid "garbage at end of line"
msgstr ""
-#: config/tc-avr.c:1186 read.c:3224
+#: config/tc-avr.c:1170 read.c:3226
msgid "illegal expression"
msgstr ""
-#: config/tc-avr.c:1212 config/tc-avr.c:1278
+#: config/tc-avr.c:1196 config/tc-avr.c:1262
msgid "`)' required"
msgstr ""
-#: config/tc-avr.c:1232
+#: config/tc-avr.c:1216
#, c-format
msgid "constant out of 8-bit range: %d"
msgstr ""
-#: config/tc-avr.c:1235
+#: config/tc-avr.c:1219
msgid "expression possibly out of 8-bit range"
msgstr ""
-#: config/tc-avr.c:1306 config/tc-avr.c:1313
+#: config/tc-avr.c:1290 config/tc-avr.c:1297
#, c-format
msgid "illegal %srelocation size: %d"
msgstr ""
-#: config/tc-cris.c:681
+#: config/tc-cris.c:386 config/tc-m68hc11.c:2831
+#, c-format
+msgid "internal inconsistency problem in %s: fr_symbol %lx"
+msgstr ""
+
+#: config/tc-cris.c:390 config/tc-m68hc11.c:2835
+#, c-format
+msgid "internal inconsistency problem in %s: resolved symbol"
+msgstr ""
+
+#: config/tc-cris.c:396 config/tc-m68hc11.c:2841
+#, c-format
+msgid "internal inconsistency problem in %s: fr_subtype %d"
+msgstr ""
+
+#: config/tc-cris.c:650
+#, c-format
+msgid "internal inconsistency in %s: bdapq no symbol"
+msgstr ""
+
+#: config/tc-cris.c:663
+#, c-format
+msgid "internal inconsistency in %s: bdap.w with no symbol"
+msgstr ""
+
+#: config/tc-cris.c:807
msgid "Virtual memory exhausted"
msgstr ""
-#: config/tc-cris.c:689
+#: config/tc-cris.c:815
#, c-format
msgid "Can't hash `%s': %s\n"
msgstr ""
-#: config/tc-cris.c:690
+#: config/tc-cris.c:816
msgid "(unknown reason)"
msgstr ""
-#: config/tc-cris.c:694
+#: config/tc-cris.c:820
#, c-format
msgid "Buggy opcode: `%s' \"%s\"\n"
msgstr ""
-#: config/tc-cris.c:1039
+#: config/tc-cris.c:1164
#, c-format
msgid "Immediate value not in 5 bit unsigned range: %ld"
msgstr ""
-#: config/tc-cris.c:1055
+#: config/tc-cris.c:1180
#, c-format
msgid "Immediate value not in 4 bit unsigned range: %ld"
msgstr ""
-#: config/tc-cris.c:1094
+#: config/tc-cris.c:1219
#, c-format
msgid "Immediate value not in 6 bit range: %ld"
msgstr ""
-#: config/tc-cris.c:1109
+#: config/tc-cris.c:1234
#, c-format
msgid "Immediate value not in 6 bit unsigned range: %ld"
msgstr ""
#. Others have a generic warning.
-#: config/tc-cris.c:1199
+#: config/tc-cris.c:1324
#, c-format
msgid "Unimplemented register `%s' specified"
msgstr ""
#. We've come to the end of instructions with this
#. opcode, so it must be an error.
-#: config/tc-cris.c:1358
+#: config/tc-cris.c:1483
msgid "Illegal operands"
msgstr ""
-#: config/tc-cris.c:1389 config/tc-cris.c:1420
+#: config/tc-cris.c:1514 config/tc-cris.c:1545
#, c-format
msgid "Immediate value not in 8 bit range: %ld"
msgstr ""
-#: config/tc-cris.c:1399 config/tc-cris.c:1427
+#: config/tc-cris.c:1524 config/tc-cris.c:1552
#, c-format
msgid "Immediate value not in 16 bit range: %ld"
msgstr ""
-#: config/tc-cris.c:1448
+#: config/tc-cris.c:1573
msgid "PIC relocation size does not match operand size"
msgstr ""
-#: config/tc-cris.c:2447
+#: config/tc-cris.c:2572
msgid "32-bit conditional branch generated"
msgstr ""
-#: config/tc-cris.c:2501
+#: config/tc-cris.c:2626
msgid "Complex expression not supported"
msgstr ""
#. FIXME: Is this function mentioned in the internals.texi manual? If
#. not, add it.
-#: config/tc-cris.c:2622
+#: config/tc-cris.c:2747
msgid "Bad call to md_atof () - floating point formats are not supported"
msgstr ""
-#: config/tc-cris.c:2669
+#: config/tc-cris.c:2794
msgid "PC-relative relocation must be trivially resolved"
msgstr ""
-#: config/tc-cris.c:2712
+#: config/tc-cris.c:2837
#, c-format
msgid "Value not in 16 bit range: %ld"
msgstr ""
-#: config/tc-cris.c:2723
+#: config/tc-cris.c:2848
#, c-format
msgid "Value not in 8 bit range: %ld"
msgstr ""
-#: config/tc-cris.c:2730
+#: config/tc-cris.c:2855
#, c-format
msgid "Value not in 4 bit unsigned range: %ld"
msgstr ""
-#: config/tc-cris.c:2737
+#: config/tc-cris.c:2862
#, c-format
msgid "Value not in 5 bit unsigned range: %ld"
msgstr ""
-#: config/tc-cris.c:2744
+#: config/tc-cris.c:2869
#, c-format
msgid "Value not in 6 bit range: %ld"
msgstr ""
-#: config/tc-cris.c:2751
+#: config/tc-cris.c:2876
#, c-format
msgid "Value not in 6 bit unsigned range: %ld"
msgstr ""
-#: config/tc-cris.c:2799
+#: config/tc-cris.c:2924
msgid "Please use --help to see usage and options for this assembler.\n"
msgstr ""
-#: config/tc-cris.c:2811
+#: config/tc-cris.c:2936
msgid "--no-underscore is invalid with a.out format"
msgstr ""
-#: config/tc-cris.c:2887
+#: config/tc-cris.c:3012
msgid ""
"Semantics error. This type of operand can not be relocated, it must be an "
"assembly-time constant"
msgstr ""
-#: config/tc-cris.c:2941
+#: config/tc-cris.c:3064
#, c-format
msgid "Cannot generate relocation type for symbol %s, code %s"
msgstr ""
#. The messages are formatted to line up with the generic options.
-#: config/tc-cris.c:2955
+#: config/tc-cris.c:3078
msgid "CRIS-specific options:\n"
msgstr ""
-#: config/tc-cris.c:2957
+#: config/tc-cris.c:3080
msgid ""
" -h, -H Don't execute, print this help text. Deprecated.\n"
msgstr ""
-#: config/tc-cris.c:2959
+#: config/tc-cris.c:3082
msgid " -N Warn when branches are expanded to jumps.\n"
msgstr ""
-#: config/tc-cris.c:2961
+#: config/tc-cris.c:3084
msgid ""
" --underscore User symbols are normally prepended with "
"underscore.\n"
msgstr ""
-#: config/tc-cris.c:2963
+#: config/tc-cris.c:3086
msgid " Registers will not need any prefix.\n"
msgstr ""
-#: config/tc-cris.c:2965
+#: config/tc-cris.c:3088
msgid " --no-underscore User symbols do not have any prefix.\n"
msgstr ""
-#: config/tc-cris.c:2967
+#: config/tc-cris.c:3090
msgid " Registers will require a `$'-prefix.\n"
msgstr ""
-#: config/tc-cris.c:2969
+#: config/tc-cris.c:3092
msgid " --pic\t\t\tEnable generation of position-independent code.\n"
msgstr ""
-#: config/tc-cris.c:2992
+#: config/tc-cris.c:3115
msgid "Invalid relocation"
msgstr ""
-#: config/tc-cris.c:3033
+#: config/tc-cris.c:3149
msgid "Invalid pc-relative relocation"
msgstr ""
-#: config/tc-cris.c:3084
+#: config/tc-cris.c:3198
#, c-format
msgid "Adjusted signed .word (%ld) overflows: `switch'-statement too large."
msgstr ""
-#: config/tc-cris.c:3111
+#: config/tc-cris.c:3225
#, c-format
msgid ".syntax %s requires command-line option `--underscore'"
msgstr ""
-#: config/tc-cris.c:3120
+#: config/tc-cris.c:3234
#, c-format
msgid ".syntax %s requires command-line option `--no-underscore'"
msgstr ""
-#: config/tc-cris.c:3158
+#: config/tc-cris.c:3272
msgid "Unknown .syntax operand"
msgstr ""
-#: config/tc-cris.c:3169
+#: config/tc-cris.c:3283
msgid "Pseudodirective .file is only valid when generating ELF"
msgstr ""
-#: config/tc-cris.c:3182
+#: config/tc-cris.c:3296
msgid "Pseudodirective .loc is only valid when generating ELF"
msgstr ""
@@ -2948,9 +3067,9 @@ msgid ""
" instructions together.\n"
msgstr ""
-#: config/tc-d10v.c:543 config/tc-d30v.c:550 config/tc-mn10200.c:937
-#: config/tc-mn10300.c:1315 config/tc-ppc.c:2141 config/tc-s390.c:1060
-#: config/tc-tic80.c:279 config/tc-v850.c:1981
+#: config/tc-d10v.c:543 config/tc-d30v.c:549 config/tc-mn10200.c:937
+#: config/tc-mn10300.c:1812 config/tc-ppc.c:2332 config/tc-s390.c:1234
+#: config/tc-tic80.c:275 config/tc-v850.c:2021
msgid "illegal operand"
msgstr ""
@@ -2979,20 +3098,20 @@ msgstr ""
msgid "One of these instructions may not be executed in parallel."
msgstr ""
-#: config/tc-d10v.c:832 config/tc-d30v.c:877
+#: config/tc-d10v.c:832 config/tc-d30v.c:876
msgid "Two IU instructions may not be executed in parallel"
msgstr ""
#: config/tc-d10v.c:834 config/tc-d10v.c:842 config/tc-d10v.c:856
-#: config/tc-d10v.c:871 config/tc-d30v.c:878 config/tc-d30v.c:887
+#: config/tc-d10v.c:871 config/tc-d30v.c:877 config/tc-d30v.c:886
msgid "Swapping instruction order"
msgstr ""
-#: config/tc-d10v.c:840 config/tc-d30v.c:884
+#: config/tc-d10v.c:840 config/tc-d30v.c:883
msgid "Two MU instructions may not be executed in parallel"
msgstr ""
-#: config/tc-d10v.c:860 config/tc-d30v.c:904
+#: config/tc-d10v.c:860 config/tc-d30v.c:903
msgid "IU instruction may not be in the left container"
msgstr ""
@@ -3002,11 +3121,11 @@ msgid ""
"container."
msgstr ""
-#: config/tc-d10v.c:875 config/tc-d30v.c:915
+#: config/tc-d10v.c:875 config/tc-d30v.c:914
msgid "MU instruction may not be in the right container"
msgstr ""
-#: config/tc-d10v.c:881 config/tc-d30v.c:927
+#: config/tc-d10v.c:881 config/tc-d30v.c:926
msgid "unknown execution type passed to write_2_short()"
msgstr ""
@@ -3037,20 +3156,20 @@ msgstr ""
msgid "resource conflict (F flag)"
msgstr ""
-#: config/tc-d10v.c:1276 config/tc-d10v.c:1298 config/tc-d30v.c:1411
+#: config/tc-d10v.c:1276 config/tc-d10v.c:1298 config/tc-d30v.c:1410
msgid "Unable to mix instructions as specified"
msgstr ""
-#: config/tc-d10v.c:1345 config/tc-d30v.c:1548
+#: config/tc-d10v.c:1345 config/tc-d30v.c:1547
#, c-format
msgid "unknown opcode: %s"
msgstr ""
-#: config/tc-d10v.c:1428 config/tc-d10v.c:1603 config/tc-tic80.c:536
+#: config/tc-d10v.c:1428 config/tc-d10v.c:1603 config/tc-tic80.c:532
msgid "bad opcode or operands"
msgstr ""
-#: config/tc-d10v.c:1503 config/tc-m68k.c:4314
+#: config/tc-d10v.c:1503 config/tc-m68k.c:4305
msgid "value out of range"
msgstr ""
@@ -3058,7 +3177,7 @@ msgstr ""
msgid "illegal operand - register name found where none expected"
msgstr ""
-#: config/tc-d10v.c:1614 config/tc-tic80.c:547
+#: config/tc-d10v.c:1614 config/tc-tic80.c:543
msgid "Register number must be EVEN"
msgstr ""
@@ -3071,7 +3190,7 @@ msgstr ""
msgid "cr%ld is a reserved control register"
msgstr ""
-#: config/tc-d10v.c:1790
+#: config/tc-d10v.c:1773
#, c-format
msgid "line %d: rep or repi must include at least 4 instructions"
msgstr ""
@@ -3081,7 +3200,7 @@ msgstr ""
msgid "Register name %s conflicts with symbol of the same name"
msgstr ""
-#: config/tc-d30v.c:288
+#: config/tc-d30v.c:287
msgid ""
"\n"
"D30V options:\n"
@@ -3094,131 +3213,126 @@ msgid ""
"-C Opposite of -C. -c is the default.\n"
msgstr ""
-#: config/tc-d30v.c:462
+#: config/tc-d30v.c:461
msgid "unexpected 12-bit reloc type"
msgstr ""
-#: config/tc-d30v.c:469
+#: config/tc-d30v.c:468
msgid "unexpected 18-bit reloc type"
msgstr ""
-#: config/tc-d30v.c:656
-#, c-format
-msgid "operand out of range: %d"
-msgstr ""
-
-#: config/tc-d30v.c:720
+#: config/tc-d30v.c:719
#, c-format
msgid "%s NOP inserted"
msgstr ""
-#: config/tc-d30v.c:721
+#: config/tc-d30v.c:720
msgid "sequential"
msgstr ""
-#: config/tc-d30v.c:721
+#: config/tc-d30v.c:720
msgid "parallel"
msgstr ""
-#: config/tc-d30v.c:873
+#: config/tc-d30v.c:872
msgid "Instructions may not be executed in parallel"
msgstr ""
-#: config/tc-d30v.c:886
+#: config/tc-d30v.c:885
#, c-format
msgid "Executing %s in IU may not work"
msgstr ""
-#: config/tc-d30v.c:893
+#: config/tc-d30v.c:892
#, c-format
msgid "Executing %s in IU may not work in parallel execution"
msgstr ""
-#: config/tc-d30v.c:906
+#: config/tc-d30v.c:905
#, c-format
msgid "special left instruction `%s' kills instruction `%s' in right container"
msgstr ""
-#: config/tc-d30v.c:917
+#: config/tc-d30v.c:916
#, c-format
msgid "Executing %s in reverse serial with %s may not work"
msgstr ""
-#: config/tc-d30v.c:920
+#: config/tc-d30v.c:919
#, c-format
msgid "Executing %s in IU in reverse serial may not work"
msgstr ""
-#: config/tc-d30v.c:1290 config/tc-d30v.c:1307
+#: config/tc-d30v.c:1289 config/tc-d30v.c:1306
msgid "Cannot assemble instruction"
msgstr ""
-#: config/tc-d30v.c:1292
+#: config/tc-d30v.c:1291
msgid "First opcode is long. Unable to mix instructions as specified."
msgstr ""
-#: config/tc-d30v.c:1361
+#: config/tc-d30v.c:1360
msgid "word of NOPs added between word multiply and load"
msgstr ""
-#: config/tc-d30v.c:1363
+#: config/tc-d30v.c:1362
msgid "word of NOPs added between word multiply and 16-bit multiply"
msgstr ""
-#: config/tc-d30v.c:1395
+#: config/tc-d30v.c:1394
msgid "Instruction uses long version, so it cannot be mixed as specified"
msgstr ""
-#: config/tc-d30v.c:1478 config/tc-d30v.c:1516
+#: config/tc-d30v.c:1477 config/tc-d30v.c:1515
#, c-format
msgid "unknown condition code: %s"
msgstr ""
-#: config/tc-d30v.c:1509
+#: config/tc-d30v.c:1508
#, c-format
msgid "cmpu doesn't support condition code %s"
msgstr ""
-#: config/tc-d30v.c:1559
+#: config/tc-d30v.c:1558
#, c-format
msgid "operands for opcode `%s' do not match any valid format"
msgstr ""
-#: config/tc-d30v.c:1777
+#: config/tc-d30v.c:1776
msgid "Odd numbered register used as target of multi-register instruction"
msgstr ""
-#: config/tc-d30v.c:1876
+#: config/tc-d30v.c:1862
#, c-format
msgid "line %d: unable to place address of symbol '%s' into a byte"
msgstr ""
-#: config/tc-d30v.c:1879
+#: config/tc-d30v.c:1865
#, c-format
-msgid "line %d: unable to place value %x into a byte"
+msgid "line %d: unable to place value %lx into a byte"
msgstr ""
-#: config/tc-d30v.c:1887
+#: config/tc-d30v.c:1873
#, c-format
msgid "line %d: unable to place address of symbol '%s' into a short"
msgstr ""
-#: config/tc-d30v.c:1890
+#: config/tc-d30v.c:1876
#, c-format
-msgid "line %d: unable to place value %x into a short"
+msgid "line %d: unable to place value %lx into a short"
msgstr ""
-#: config/tc-d30v.c:1898
+#: config/tc-d30v.c:1884
#, c-format
msgid "line %d: unable to place address of symbol '%s' into a quad"
msgstr ""
-#: config/tc-d30v.c:2067
+#: config/tc-d30v.c:2053
#, c-format
msgid "value too large to fit in %d bits"
msgstr ""
-#: config/tc-d30v.c:2210
+#: config/tc-d30v.c:2196
#, c-format
msgid "Alignment too large: %d assumed"
msgstr ""
@@ -3268,870 +3382,928 @@ msgstr ""
msgid "failed general register sanity check."
msgstr ""
-#: config/tc-dlx.c:1336
+#: config/tc-dlx.c:1324
msgid "Invalid expression after # number\n"
msgstr ""
-#: config/tc-fr30.c:84
+#: config/tc-fr30.c:85
msgid " FR30 specific command line options:\n"
msgstr ""
-#: config/tc-fr30.c:143 config/tc-openrisc.c:150
+#: config/tc-fr30.c:139 config/tc-openrisc.c:152
#, c-format
msgid "Instruction %s not allowed in a delay slot."
msgstr ""
-#: config/tc-fr30.c:383 config/tc-m32r.c:1559
+#: config/tc-fr30.c:383 config/tc-m32r.c:1576
msgid "Addend to unresolved symbol not on word boundary."
msgstr ""
-#: config/tc-fr30.c:540 config/tc-frv.c:1283 config/tc-i960.c:773
-#: config/tc-m32r.c:1867 config/tc-openrisc.c:468 config/tc-xstormy16.c:635
+#: config/tc-fr30.c:524 config/tc-frv.c:1289 config/tc-i960.c:798
+#: config/tc-ip2k.c:351 config/tc-m32r.c:1884 config/tc-openrisc.c:452
+#: config/tc-xstormy16.c:636
msgid "Bad call to md_atof()"
msgstr ""
-#: config/tc-frv.c:416
+#: config/tc-frv.c:413
msgid "FRV specific command line options:\n"
msgstr ""
-#: config/tc-frv.c:417
+#: config/tc-frv.c:414
msgid "-G n Data >= n bytes is in small data area\n"
msgstr ""
-#: config/tc-frv.c:418
+#: config/tc-frv.c:415
msgid "-mgpr-32 Note 32 gprs are used\n"
msgstr ""
-#: config/tc-frv.c:419
+#: config/tc-frv.c:416
msgid "-mgpr-64 Note 64 gprs are used\n"
msgstr ""
-#: config/tc-frv.c:420
+#: config/tc-frv.c:417
msgid "-mfpr-32 Note 32 fprs are used\n"
msgstr ""
-#: config/tc-frv.c:421
+#: config/tc-frv.c:418
msgid "-mfpr-64 Note 64 fprs are used\n"
msgstr ""
-#: config/tc-frv.c:422
+#: config/tc-frv.c:419
msgid "-msoft-float Note software fp is used\n"
msgstr ""
-#: config/tc-frv.c:423
+#: config/tc-frv.c:420
msgid "-mdword Note stack is aligned to a 8 byte boundary\n"
msgstr ""
-#: config/tc-frv.c:424
+#: config/tc-frv.c:421
msgid "-mno-dword Note stack is aligned to a 4 byte boundary\n"
msgstr ""
-#: config/tc-frv.c:425
+#: config/tc-frv.c:422
msgid "-mdouble Note fp double insns are used\n"
msgstr ""
-#: config/tc-frv.c:426
+#: config/tc-frv.c:423
msgid "-mmedia Note media insns are used\n"
msgstr ""
-#: config/tc-frv.c:427
+#: config/tc-frv.c:424
msgid "-mmuladd Note multiply add/subtract insns are used\n"
msgstr ""
-#: config/tc-frv.c:428
+#: config/tc-frv.c:425
msgid "-mpack Note instructions are packed\n"
msgstr ""
-#: config/tc-frv.c:429
+#: config/tc-frv.c:426
msgid "-mno-pack Do not allow instructions to be packed\n"
msgstr ""
-#: config/tc-frv.c:430
+#: config/tc-frv.c:427
msgid "-mpic Note small position independent code\n"
msgstr ""
-#: config/tc-frv.c:431
+#: config/tc-frv.c:428
msgid "-mPIC Note large position independent code\n"
msgstr ""
-#: config/tc-frv.c:432
+#: config/tc-frv.c:429
msgid "-mlibrary-pic Compile library for large position indepedent code\n"
msgstr ""
-#: config/tc-frv.c:433
+#: config/tc-frv.c:430
msgid "-mcpu={fr500|fr400|fr300|frv|simple|tomcat}\n"
msgstr ""
-#: config/tc-frv.c:434
+#: config/tc-frv.c:431
msgid " Record the cpu type\n"
msgstr ""
-#: config/tc-frv.c:435
+#: config/tc-frv.c:432
msgid "-mtomcat-stats Print out stats for tomcat workarounds\n"
msgstr ""
-#: config/tc-frv.c:436
+#: config/tc-frv.c:433
msgid "-mtomcat-debug Debug tomcat workarounds\n"
msgstr ""
-#: config/tc-frv.c:1003
+#: config/tc-frv.c:1012
msgid "VLIW packing used for -mno-pack"
msgstr ""
-#: config/tc-frv.c:1016
+#: config/tc-frv.c:1025
msgid "VLIW packing constraint violation"
msgstr ""
-#: config/tc-frv.c:1544
+#: config/tc-frv.c:1540
#, c-format
msgid "Relocation %s is not safe for %s"
msgstr ""
-#: config/tc-h8300.c:64 config/tc-h8300.c:76 config/tc-h8300.c:143
-#: config/tc-hppa.c:1424 config/tc-hppa.c:6917 config/tc-hppa.c:6923
-#: config/tc-hppa.c:6929 config/tc-hppa.c:6935 config/tc-mn10300.c:907
-#: config/tc-mn10300.c:2171
+#: config/tc-h8300.c:84 config/tc-h8300.c:96 config/tc-h8300.c:109
+#: config/tc-h8300.c:122 config/tc-h8300.c:135 config/tc-h8300.c:149
+#: config/tc-h8300.c:222 config/tc-hppa.c:1423 config/tc-hppa.c:6909
+#: config/tc-hppa.c:6915 config/tc-hppa.c:6921 config/tc-hppa.c:6927
+#: config/tc-mn10300.c:1218 config/tc-mn10300.c:1223 config/tc-mn10300.c:2722
msgid "could not set architecture and machine"
msgstr ""
-#: config/tc-h8300.c:282 config/tc-h8300.c:290
+#: config/tc-h8300.c:436 config/tc-h8300.c:444
msgid "Reg not valid for H8/300"
msgstr ""
-#: config/tc-h8300.c:451 config/tc-h8300.c:454 config/tc-h8300.c:457
-#: config/tc-h8300.c:461
+#: config/tc-h8300.c:529
+msgid "invalid operand size requested"
+msgstr ""
+
+#: config/tc-h8300.c:626 config/tc-h8300.c:629
msgid "Invalid register list for ldm/stm\n"
msgstr ""
-#: config/tc-h8300.c:516 config/tc-h8300.c:578 config/tc-h8300.c:585
+#: config/tc-h8300.c:632
+msgid "Invalid register list for ldm/stm)\n"
+msgstr ""
+
+#: config/tc-h8300.c:658 config/tc-h8300.c:663 config/tc-h8300.c:670
+msgid "mismatch between register and suffix"
+msgstr ""
+
+#: config/tc-h8300.c:697
+msgid "address too high for vector table jmp/jsr"
+msgstr ""
+
+#: config/tc-h8300.c:722 config/tc-h8300.c:832 config/tc-h8300.c:840
msgid "Wrong size pointer register for architecture."
msgstr ""
-#: config/tc-h8300.c:543 config/tc-h8300.c:552 config/tc-h8300.c:562
+#: config/tc-h8300.c:781 config/tc-h8300.c:789 config/tc-h8300.c:818
msgid "expected @(exp, reg16)"
msgstr ""
-#: config/tc-h8300.c:640
-msgid "expect :8 or :16 here"
+#: config/tc-h8300.c:807
+msgid "expected .L, .W or .B for register in indexed addressing mode"
+msgstr ""
+
+#: config/tc-h8300.c:1000
+msgid "expected valid addressing mode for mova: \"@(disp, ea.sz),ERn\""
+msgstr ""
+
+#: config/tc-h8300.c:1018 config/tc-h8300.c:1027
+msgid "expected register"
+msgstr ""
+
+#: config/tc-h8300.c:1043
+msgid "expected closing paren"
+msgstr ""
+
+#: config/tc-h8300.c:1104
+#, c-format
+msgid "can't use high part of register in operand %d"
+msgstr ""
+
+#: config/tc-h8300.c:1268
+#, c-format
+msgid "Opcode `%s' with these operand types not available in %s mode"
+msgstr ""
+
+#: config/tc-h8300.c:1277
+msgid "mismatch between opcode size and operand size"
msgstr ""
-#: config/tc-h8300.c:847
+#: config/tc-h8300.c:1316
#, c-format
msgid "operand %s0x%lx out of range."
msgstr ""
-#: config/tc-h8300.c:935
+#: config/tc-h8300.c:1415
msgid "Can't work out size of operand.\n"
msgstr ""
-#: config/tc-h8300.c:983
+#: config/tc-h8300.c:1466
#, c-format
msgid "Opcode `%s' with these operand types not available in H8/300 mode"
msgstr ""
-#: config/tc-h8300.c:1029 config/tc-h8300.c:1049
+#: config/tc-h8300.c:1471
+#, c-format
+msgid "Opcode `%s' with these operand types not available in H8/300H mode"
+msgstr ""
+
+#: config/tc-h8300.c:1477
+#, c-format
+msgid "Opcode `%s' with these operand types not available in H8/300S mode"
+msgstr ""
+
+#: config/tc-h8300.c:1538 config/tc-h8300.c:1558
msgid "Need #1 or #2 here"
msgstr ""
-#: config/tc-h8300.c:1044
+#: config/tc-h8300.c:1553
msgid "#4 not valid on H8/300."
msgstr ""
-#: config/tc-h8300.c:1122 config/tc-h8300.c:1169
+#: config/tc-h8300.c:1645 config/tc-h8300.c:1727
#, c-format
msgid "branch operand has odd offset (%lx)\n"
msgstr ""
-#: config/tc-h8300.c:1208
+#: config/tc-h8300.c:1766
msgid "destination operand must be 16 bit register"
msgstr ""
-#: config/tc-h8300.c:1217
+#: config/tc-h8300.c:1775
msgid "source operand must be 8 bit register"
msgstr ""
-#: config/tc-h8300.c:1225
+#: config/tc-h8300.c:1783
msgid "destination operand must be 16bit absolute address"
msgstr ""
-#: config/tc-h8300.c:1232
+#: config/tc-h8300.c:1790
msgid "destination operand must be 8 bit register"
msgstr ""
-#: config/tc-h8300.c:1240
+#: config/tc-h8300.c:1798
msgid "source operand must be 16bit absolute address"
msgstr ""
#. This seems more sane than saying "too many operands". We'll
#. get here only if the trailing trash starts with a comma.
-#: config/tc-h8300.c:1248 config/tc-mmix.c:459 config/tc-mmix.c:471
-#: config/tc-mmix.c:2502 config/tc-mmix.c:2526 config/tc-mmix.c:2803
-#: config/tc-or32.c:642 config/tc-or32.c:856
+#: config/tc-h8300.c:1806 config/tc-mmix.c:454 config/tc-mmix.c:466
+#: config/tc-mmix.c:2502 config/tc-mmix.c:2526 config/tc-mmix.c:2802
+#: config/tc-or32.c:640 config/tc-or32.c:854
msgid "invalid operands"
msgstr ""
-#: config/tc-h8300.c:1300 config/tc-h8500.c:1094 config/tc-mips.c:8915
-#: config/tc-sh.c:2371 config/tc-sh64.c:2811 config/tc-w65.c:733
-#: config/tc-z8k.c:1206
-msgid "unknown opcode"
+#: config/tc-h8300.c:1839
+msgid "operand/size mis-match"
msgstr ""
-#: config/tc-h8300.c:1346
-msgid "mismatch between opcode size and operand size"
+#: config/tc-h8300.c:1926 config/tc-h8500.c:1112 config/tc-mips.c:9302
+#: config/tc-sh.c:2363 config/tc-sh64.c:2837 config/tc-w65.c:691
+#: config/tc-z8k.c:1248
+msgid "unknown opcode"
msgstr ""
-#: config/tc-h8300.c:1358 config/tc-h8500.c:1121 config/tc-sh.c:2491
-#: config/tc-w65.c:763 config/tc-z8k.c:1262
+#: config/tc-h8300.c:2031 config/tc-h8500.c:1139 config/tc-sh.c:2483
+#: config/tc-z8k.c:1304
msgid "call to tc_crawl_symbol_chain \n"
msgstr ""
-#: config/tc-h8300.c:1374 config/tc-h8500.c:1135 config/tc-sh.c:2498
-#: config/tc-w65.c:777 config/tc-z8k.c:1276
+#: config/tc-h8300.c:2047 config/tc-h8500.c:1153 config/tc-sh.c:2490
+#: config/tc-z8k.c:1320
msgid "call to tc_headers_hook \n"
msgstr ""
-#: config/tc-h8300.c:1467 config/tc-h8500.c:1225 config/tc-z8k.c:1391
+#: config/tc-h8300.c:2140
msgid "call to tc_aout_fix_to_chars \n"
msgstr ""
-#: config/tc-h8300.c:1481 config/tc-z8k.c:1401
+#: config/tc-h8300.c:2154
msgid "call to md_convert_frag \n"
msgstr ""
-#: config/tc-h8300.c:1543 config/tc-z8k.c:1486
+#: config/tc-h8300.c:2216
msgid "call tomd_estimate_size_before_relax \n"
msgstr ""
-#: config/tc-h8300.c:1664 config/tc-mcore.c:2413 config/tc-pj.c:572
-#: config/tc-sh.c:3959
+#: config/tc-h8300.c:2337 config/tc-mcore.c:2355 config/tc-pj.c:581
+#: config/tc-sh.c:3956
#, c-format
msgid "Cannot represent relocation type %s"
msgstr ""
-#: config/tc-h8500.c:323
+#: config/tc-h8500.c:325
msgid ":24 not valid for this opcode"
msgstr ""
-#: config/tc-h8500.c:330
+#: config/tc-h8500.c:332
msgid "expect :8,:16 or :24"
msgstr ""
-#: config/tc-h8500.c:387
+#: config/tc-h8500.c:391
msgid "syntax error in reg list"
msgstr ""
-#: config/tc-h8500.c:405
+#: config/tc-h8500.c:409
msgid "missing final register in range"
msgstr ""
-#: config/tc-h8500.c:492 config/tc-h8500.c:499 config/tc-h8500.c:505
+#: config/tc-h8500.c:498 config/tc-h8500.c:505 config/tc-h8500.c:511
msgid "expected @(exp, Rn)"
msgstr ""
-#: config/tc-h8500.c:521
+#: config/tc-h8500.c:527
msgid "@Rn+ needs word register"
msgstr ""
-#: config/tc-h8500.c:531
+#: config/tc-h8500.c:537
msgid "@Rn needs word register"
msgstr ""
-#: config/tc-h8500.c:828 config/tc-sh.c:1835
+#: config/tc-h8500.c:838 config/tc-sh.c:1827
#, c-format
msgid "unhandled %d\n"
msgstr ""
-#: config/tc-h8500.c:856
+#: config/tc-h8500.c:868
#, c-format
msgid "operand must be absolute in range %d..%d"
msgstr ""
-#: config/tc-h8500.c:945 config/tc-sh.c:2044
+#: config/tc-h8500.c:963 config/tc-sh.c:2036
#, c-format
msgid "failed for %d\n"
msgstr ""
-#: config/tc-h8500.c:1110 config/tc-sh.c:2146 config/tc-sh.c:2420
-#: config/tc-w65.c:752
+#: config/tc-h8500.c:1128 config/tc-sh.c:2138 config/tc-sh.c:2412
+#: config/tc-w65.c:710
msgid "invalid operands for opcode"
msgstr ""
#. Simple range checking for FIELD againt HIGH and LOW bounds.
#. IGNORE is used to suppress the error message.
-#: config/tc-hppa.c:1157 config/tc-hppa.c:1171
+#: config/tc-hppa.c:1156 config/tc-hppa.c:1170
#, c-format
msgid "Field out of range [%d..%d] (%d)."
msgstr ""
#. Simple alignment checking for FIELD againt ALIGN (a power of two).
#. IGNORE is used to suppress the error message.
-#: config/tc-hppa.c:1185
+#: config/tc-hppa.c:1184
#, c-format
msgid "Field not properly aligned [%d] (%d)."
msgstr ""
-#: config/tc-hppa.c:1214
+#: config/tc-hppa.c:1213
msgid "Missing .exit\n"
msgstr ""
-#: config/tc-hppa.c:1217
+#: config/tc-hppa.c:1216
msgid "Missing .procend\n"
msgstr ""
-#: config/tc-hppa.c:1397
+#: config/tc-hppa.c:1396
#, c-format
msgid "Invalid field selector. Assuming F%%."
msgstr ""
-#: config/tc-hppa.c:1430
+#: config/tc-hppa.c:1429
msgid "-R option not supported on this target."
msgstr ""
-#: config/tc-hppa.c:1446 config/tc-sparc.c:809 config/tc-sparc.c:845
+#: config/tc-hppa.c:1445 config/tc-sparc.c:809 config/tc-sparc.c:845
#, c-format
msgid "Internal error: can't hash `%s': %s\n"
msgstr ""
-#: config/tc-hppa.c:1454 config/tc-i860.c:190
+#: config/tc-hppa.c:1453 config/tc-i860.c:201
#, c-format
msgid "internal error: losing opcode: `%s' \"%s\"\n"
msgstr ""
-#: config/tc-hppa.c:1525 config/tc-hppa.c:7056 config/tc-hppa.c:7113
+#: config/tc-hppa.c:1524 config/tc-hppa.c:7048 config/tc-hppa.c:7105
msgid "Missing function name for .PROC (corrupted label chain)"
msgstr ""
-#: config/tc-hppa.c:1528 config/tc-hppa.c:7116
+#: config/tc-hppa.c:1527 config/tc-hppa.c:7108
msgid "Missing function name for .PROC"
msgstr ""
-#: config/tc-hppa.c:1635 config/tc-hppa.c:4913
+#: config/tc-hppa.c:1634 config/tc-hppa.c:4905
msgid "could not update architecture and machine"
msgstr ""
-#: config/tc-hppa.c:1843
+#: config/tc-hppa.c:1842
msgid "Invalid Indexed Load Completer."
msgstr ""
-#: config/tc-hppa.c:1848
+#: config/tc-hppa.c:1847
msgid "Invalid Indexed Load Completer Syntax."
msgstr ""
-#: config/tc-hppa.c:1885
+#: config/tc-hppa.c:1884
msgid "Invalid Short Load/Store Completer."
msgstr ""
-#: config/tc-hppa.c:1945 config/tc-hppa.c:1950
+#: config/tc-hppa.c:1944 config/tc-hppa.c:1949
msgid "Invalid Store Bytes Short Completer"
msgstr ""
-#: config/tc-hppa.c:2261 config/tc-hppa.c:2267
+#: config/tc-hppa.c:2260 config/tc-hppa.c:2266
msgid "Invalid left/right combination completer"
msgstr ""
-#: config/tc-hppa.c:2316 config/tc-hppa.c:2323
+#: config/tc-hppa.c:2315 config/tc-hppa.c:2322
msgid "Invalid permutation completer"
msgstr ""
-#: config/tc-hppa.c:2424
+#: config/tc-hppa.c:2423
#, c-format
msgid "Invalid Add Condition: %s"
msgstr ""
-#: config/tc-hppa.c:2435 config/tc-hppa.c:2445
+#: config/tc-hppa.c:2434 config/tc-hppa.c:2444
msgid "Invalid Add and Branch Condition"
msgstr ""
-#: config/tc-hppa.c:2466 config/tc-hppa.c:2604
+#: config/tc-hppa.c:2465 config/tc-hppa.c:2603
msgid "Invalid Compare/Subtract Condition"
msgstr ""
-#: config/tc-hppa.c:2506
+#: config/tc-hppa.c:2505
#, c-format
msgid "Invalid Bit Branch Condition: %c"
msgstr ""
-#: config/tc-hppa.c:2592
+#: config/tc-hppa.c:2591
#, c-format
msgid "Invalid Compare/Subtract Condition: %s"
msgstr ""
-#: config/tc-hppa.c:2619
+#: config/tc-hppa.c:2618
msgid "Invalid Compare and Branch Condition"
msgstr ""
-#: config/tc-hppa.c:2715
+#: config/tc-hppa.c:2714
msgid "Invalid Logical Instruction Condition."
msgstr ""
-#: config/tc-hppa.c:2770
+#: config/tc-hppa.c:2769
msgid "Invalid Shift/Extract/Deposit Condition."
msgstr ""
-#: config/tc-hppa.c:2882
+#: config/tc-hppa.c:2881
msgid "Invalid Unit Instruction Condition."
msgstr ""
-#: config/tc-hppa.c:3259 config/tc-hppa.c:3291 config/tc-hppa.c:3322
-#: config/tc-hppa.c:3352
+#: config/tc-hppa.c:3258 config/tc-hppa.c:3290 config/tc-hppa.c:3321
+#: config/tc-hppa.c:3351
msgid "Branch to unaligned address"
msgstr ""
-#: config/tc-hppa.c:3530
+#: config/tc-hppa.c:3529
msgid "Invalid SFU identifier"
msgstr ""
-#: config/tc-hppa.c:3580
+#: config/tc-hppa.c:3579
msgid "Invalid COPR identifier"
msgstr ""
-#: config/tc-hppa.c:3709
+#: config/tc-hppa.c:3708
msgid "Invalid Floating Point Operand Format."
msgstr ""
-#: config/tc-hppa.c:3826 config/tc-hppa.c:3846 config/tc-hppa.c:3866
-#: config/tc-hppa.c:3886 config/tc-hppa.c:3906
+#: config/tc-hppa.c:3825 config/tc-hppa.c:3845 config/tc-hppa.c:3865
+#: config/tc-hppa.c:3885 config/tc-hppa.c:3905
msgid "Invalid register for single precision fmpyadd or fmpysub"
msgstr ""
-#: config/tc-hppa.c:3963
+#: config/tc-hppa.c:3962
#, c-format
msgid "Invalid operands %s"
msgstr ""
-#: config/tc-hppa.c:4081
+#: config/tc-hppa.c:4080
msgid "Cannot handle fixup"
msgstr ""
-#: config/tc-hppa.c:4382
+#: config/tc-hppa.c:4381
msgid " -Q ignored\n"
msgstr ""
-#: config/tc-hppa.c:4386
+#: config/tc-hppa.c:4385
msgid " -c print a warning if a comment is found\n"
msgstr ""
-#: config/tc-hppa.c:4457
+#: config/tc-hppa.c:4456
#, c-format
msgid "no hppa_fixup entry for fixup type 0x%x"
msgstr ""
-#: config/tc-hppa.c:4635
+#: config/tc-hppa.c:4627
msgid "Unknown relocation encountered in md_apply_fix."
msgstr ""
-#: config/tc-hppa.c:4777 config/tc-hppa.c:4802
+#: config/tc-hppa.c:4769 config/tc-hppa.c:4794
#, c-format
msgid "Undefined register: '%s'."
msgstr ""
-#: config/tc-hppa.c:4836
+#: config/tc-hppa.c:4828
#, c-format
msgid "Non-absolute symbol: '%s'."
msgstr ""
-#: config/tc-hppa.c:4851
+#: config/tc-hppa.c:4843
#, c-format
msgid "Undefined absolute constant: '%s'."
msgstr ""
-#: config/tc-hppa.c:4952
+#: config/tc-hppa.c:4944
#, c-format
msgid "Invalid FP Compare Condition: %s"
msgstr ""
-#: config/tc-hppa.c:5008
+#: config/tc-hppa.c:5000
#, c-format
msgid "Invalid FTEST completer: %s"
msgstr ""
-#: config/tc-hppa.c:5075 config/tc-hppa.c:5113
+#: config/tc-hppa.c:5067 config/tc-hppa.c:5105
#, c-format
msgid "Invalid FP Operand Format: %3s"
msgstr ""
-#: config/tc-hppa.c:5192
+#: config/tc-hppa.c:5184
msgid "Bad segment in expression."
msgstr ""
-#: config/tc-hppa.c:5251
+#: config/tc-hppa.c:5243
msgid "Bad segment (should be absolute)."
msgstr ""
-#: config/tc-hppa.c:5294
+#: config/tc-hppa.c:5286
#, c-format
msgid "Invalid argument location: %s\n"
msgstr ""
-#: config/tc-hppa.c:5325
+#: config/tc-hppa.c:5317
#, c-format
msgid "Invalid argument description: %d"
msgstr ""
-#: config/tc-hppa.c:5348
+#: config/tc-hppa.c:5340
#, c-format
msgid "Invalid Nullification: (%c)"
msgstr ""
-#: config/tc-hppa.c:6068
+#: config/tc-hppa.c:6060
#, c-format
msgid "Invalid .CALL argument: %s"
msgstr ""
-#: config/tc-hppa.c:6190
+#: config/tc-hppa.c:6182
msgid ".callinfo is not within a procedure definition"
msgstr ""
-#: config/tc-hppa.c:6210
+#: config/tc-hppa.c:6202
#, c-format
msgid "FRAME parameter must be a multiple of 8: %d\n"
msgstr ""
-#: config/tc-hppa.c:6229
+#: config/tc-hppa.c:6221
msgid "Value for ENTRY_GR must be in the range 3..18\n"
msgstr ""
-#: config/tc-hppa.c:6241
+#: config/tc-hppa.c:6233
msgid "Value for ENTRY_FR must be in the range 12..21\n"
msgstr ""
-#: config/tc-hppa.c:6251
+#: config/tc-hppa.c:6243
msgid "Value for ENTRY_SR must be 3\n"
msgstr ""
-#: config/tc-hppa.c:6307
+#: config/tc-hppa.c:6299
#, c-format
msgid "Invalid .CALLINFO argument: %s"
msgstr ""
-#: config/tc-hppa.c:6418
+#: config/tc-hppa.c:6410
msgid "The .ENTER pseudo-op is not supported"
msgstr ""
-#: config/tc-hppa.c:6434
+#: config/tc-hppa.c:6426
msgid "Misplaced .entry. Ignored."
msgstr ""
-#: config/tc-hppa.c:6438
+#: config/tc-hppa.c:6430
msgid "Missing .callinfo."
msgstr ""
-#: config/tc-hppa.c:6504
+#: config/tc-hppa.c:6496
msgid ".REG expression must be a register"
msgstr ""
-#: config/tc-hppa.c:6520
+#: config/tc-hppa.c:6512
msgid "bad or irreducible absolute expression; zero assumed"
msgstr ""
-#: config/tc-hppa.c:6531
+#: config/tc-hppa.c:6523
msgid ".REG must use a label"
msgstr ""
-#: config/tc-hppa.c:6533
+#: config/tc-hppa.c:6525
msgid ".EQU must use a label"
msgstr ""
-#: config/tc-hppa.c:6586
+#: config/tc-hppa.c:6578
msgid ".EXIT must appear within a procedure"
msgstr ""
-#: config/tc-hppa.c:6590
+#: config/tc-hppa.c:6582
msgid "Missing .callinfo"
msgstr ""
-#: config/tc-hppa.c:6594
+#: config/tc-hppa.c:6586
msgid "No .ENTRY for this .EXIT"
msgstr ""
-#: config/tc-hppa.c:6621
+#: config/tc-hppa.c:6613
#, c-format
msgid "Cannot define export symbol: %s\n"
msgstr ""
-#: config/tc-hppa.c:6679
+#: config/tc-hppa.c:6671
#, c-format
msgid "Using ENTRY rather than CODE in export directive for %s"
msgstr ""
-#: config/tc-hppa.c:6796
+#: config/tc-hppa.c:6788
#, c-format
msgid "Undefined .EXPORT/.IMPORT argument (ignored): %s"
msgstr ""
-#: config/tc-hppa.c:6878
+#: config/tc-hppa.c:6870
msgid "Missing label name on .LABEL"
msgstr ""
-#: config/tc-hppa.c:6883
+#: config/tc-hppa.c:6875
msgid "extra .LABEL arguments ignored."
msgstr ""
-#: config/tc-hppa.c:6900
+#: config/tc-hppa.c:6892
msgid "The .LEAVE pseudo-op is not supported"
msgstr ""
-#: config/tc-hppa.c:6939
+#: config/tc-hppa.c:6931
msgid "Unrecognized .LEVEL argument\n"
msgstr ""
-#: config/tc-hppa.c:6975
+#: config/tc-hppa.c:6967
#, c-format
msgid "Cannot define static symbol: %s\n"
msgstr ""
-#: config/tc-hppa.c:7010
+#: config/tc-hppa.c:7002
msgid "Nested procedures"
msgstr ""
-#: config/tc-hppa.c:7020
+#: config/tc-hppa.c:7012
msgid "Cannot allocate unwind descriptor\n"
msgstr ""
-#: config/tc-hppa.c:7120
+#: config/tc-hppa.c:7112
msgid "misplaced .procend"
msgstr ""
-#: config/tc-hppa.c:7123
+#: config/tc-hppa.c:7115
msgid "Missing .callinfo for this procedure"
msgstr ""
-#: config/tc-hppa.c:7126
+#: config/tc-hppa.c:7118
msgid "Missing .EXIT for a .ENTRY"
msgstr ""
-#: config/tc-hppa.c:7164
+#: config/tc-hppa.c:7156
msgid "Not in a space.\n"
msgstr ""
-#: config/tc-hppa.c:7167
+#: config/tc-hppa.c:7159
msgid "Not in a subspace.\n"
msgstr ""
-#: config/tc-hppa.c:7258
+#: config/tc-hppa.c:7250
msgid "Invalid .SPACE argument"
msgstr ""
-#: config/tc-hppa.c:7305
+#: config/tc-hppa.c:7297
msgid "Can't change spaces within a procedure definition. Ignored"
msgstr ""
-#: config/tc-hppa.c:7434
+#: config/tc-hppa.c:7426
#, c-format
msgid "Undefined space: '%s' Assuming space number = 0."
msgstr ""
-#: config/tc-hppa.c:7458
+#: config/tc-hppa.c:7450
msgid "Must be in a space before changing or declaring subspaces.\n"
msgstr ""
-#: config/tc-hppa.c:7462
+#: config/tc-hppa.c:7454
msgid "Can't change subspaces within a procedure definition. Ignored"
msgstr ""
-#: config/tc-hppa.c:7497
+#: config/tc-hppa.c:7489
msgid "Parameters of an existing subspace can't be modified"
msgstr ""
-#: config/tc-hppa.c:7548
+#: config/tc-hppa.c:7540
msgid "Alignment must be a power of 2"
msgstr ""
-#: config/tc-hppa.c:7590
+#: config/tc-hppa.c:7582
msgid "FIRST not supported as a .SUBSPACE argument"
msgstr ""
-#: config/tc-hppa.c:7592
+#: config/tc-hppa.c:7584
msgid "Invalid .SUBSPACE argument"
msgstr ""
-#: config/tc-hppa.c:7772
+#: config/tc-hppa.c:7764
#, c-format
msgid "Internal error: Unable to find containing space for %s."
msgstr ""
-#: config/tc-hppa.c:7811
+#: config/tc-hppa.c:7803
#, c-format
msgid "Out of memory: could not allocate new space chain entry: %s\n"
msgstr ""
-#: config/tc-hppa.c:7897
+#: config/tc-hppa.c:7889
#, c-format
msgid "Out of memory: could not allocate new subspace chain entry: %s\n"
msgstr ""
-#: config/tc-hppa.c:8638
+#: config/tc-hppa.c:8622
#, c-format
msgid "Symbol '%s' could not be created."
msgstr ""
-#: config/tc-hppa.c:8642
+#: config/tc-hppa.c:8626
msgid "No memory for symbol name."
msgstr ""
-#: config/tc-i386.c:660
+#: config/tc-i386.c:689
#, c-format
msgid "%s shortened to %s"
msgstr ""
-#: config/tc-i386.c:716
+#: config/tc-i386.c:745
msgid "same type of prefix used twice"
msgstr ""
-#: config/tc-i386.c:734
+#: config/tc-i386.c:763
msgid "64bit mode not supported on this CPU."
msgstr ""
-#: config/tc-i386.c:738
+#: config/tc-i386.c:767
msgid "32bit mode not supported on this CPU."
msgstr ""
-#: config/tc-i386.c:771
+#: config/tc-i386.c:800
msgid "bad argument to syntax directive."
msgstr ""
-#: config/tc-i386.c:815
+#: config/tc-i386.c:844
#, c-format
msgid "no such architecture: `%s'"
msgstr ""
-#: config/tc-i386.c:820
+#: config/tc-i386.c:849
msgid "missing cpu architecture"
msgstr ""
-#: config/tc-i386.c:834
+#: config/tc-i386.c:863
#, c-format
msgid "no such architecture modifier: `%s'"
msgstr ""
-#: config/tc-i386.c:851 config/tc-i386.c:4944
+#: config/tc-i386.c:880 config/tc-i386.c:5022
msgid "Unknown architecture"
msgstr ""
-#: config/tc-i386.c:886 config/tc-i386.c:909 config/tc-m68k.c:3830
+#: config/tc-i386.c:915 config/tc-i386.c:938 config/tc-m68k.c:3816
#, c-format
msgid "Internal Error: Can't hash %s: %s"
msgstr ""
-#: config/tc-i386.c:1152
+#: config/tc-i386.c:1192
msgid "There are no unsigned pc-relative relocations"
msgstr ""
-#: config/tc-i386.c:1159 config/tc-i386.c:5151
+#: config/tc-i386.c:1199 config/tc-i386.c:5234
#, c-format
msgid "can not do %d byte pc-relative relocation"
msgstr ""
-#: config/tc-i386.c:1176
+#: config/tc-i386.c:1216
#, c-format
msgid "can not do %s %d byte relocation"
msgstr ""
+#: config/tc-i386.c:1428
+#, c-format
+msgid "can't use register '%%%s' as operand %d in '%s'."
+msgstr ""
+
#. UnixWare fsub no args is alias for fsubp, fadd -> faddp, etc.
-#: config/tc-i386.c:1396
+#: config/tc-i386.c:1457
#, c-format
msgid "translating to `%sp'"
msgstr ""
-#: config/tc-i386.c:1441
+#: config/tc-i386.c:1502
#, c-format
msgid "can't encode register '%%%s' in an instruction requiring REX prefix.\n"
msgstr ""
-#: config/tc-i386.c:1480 config/tc-i386.c:1575
+#: config/tc-i386.c:1541 config/tc-i386.c:1636
#, c-format
msgid "no such instruction: `%s'"
msgstr ""
-#: config/tc-i386.c:1490 config/tc-i386.c:1607
+#: config/tc-i386.c:1551 config/tc-i386.c:1668
#, c-format
msgid "invalid character %s in mnemonic"
msgstr ""
-#: config/tc-i386.c:1497
+#: config/tc-i386.c:1558
msgid "expecting prefix; got nothing"
msgstr ""
-#: config/tc-i386.c:1499
+#: config/tc-i386.c:1560
msgid "expecting mnemonic; got nothing"
msgstr ""
-#: config/tc-i386.c:1518
+#: config/tc-i386.c:1579
#, c-format
msgid "redundant %s prefix"
msgstr ""
-#: config/tc-i386.c:1616
+#: config/tc-i386.c:1677
#, c-format
msgid "`%s' is not supported on `%s'"
msgstr ""
-#: config/tc-i386.c:1621
+#: config/tc-i386.c:1682
msgid "use .code16 to ensure correct addressing mode"
msgstr ""
-#: config/tc-i386.c:1628
+#: config/tc-i386.c:1689
#, c-format
msgid "expecting string instruction after `%s'"
msgstr ""
-#: config/tc-i386.c:1656
+#: config/tc-i386.c:1717
#, c-format
msgid "invalid character %s before operand %d"
msgstr ""
-#: config/tc-i386.c:1670
+#: config/tc-i386.c:1731
#, c-format
msgid "unbalanced parenthesis in operand %d."
msgstr ""
-#: config/tc-i386.c:1673
+#: config/tc-i386.c:1734
#, c-format
msgid "unbalanced brackets in operand %d."
msgstr ""
-#: config/tc-i386.c:1682
+#: config/tc-i386.c:1743
#, c-format
msgid "invalid character %s in operand %d"
msgstr ""
-#: config/tc-i386.c:1709
+#: config/tc-i386.c:1770
#, c-format
msgid "spurious operands; (%d operands/instruction max)"
msgstr ""
-#: config/tc-i386.c:1732
+#: config/tc-i386.c:1793
msgid "expecting operand after ','; got nothing"
msgstr ""
-#: config/tc-i386.c:1737
+#: config/tc-i386.c:1798
msgid "expecting operand before ','; got nothing"
msgstr ""
#. We found no match.
-#: config/tc-i386.c:2079
+#: config/tc-i386.c:2140
#, c-format
msgid "suffix or operands invalid for `%s'"
msgstr ""
-#: config/tc-i386.c:2090
+#: config/tc-i386.c:2151
#, c-format
msgid "indirect %s without `*'"
msgstr ""
#. Warn them that a data or address size prefix doesn't
#. affect assembly of the next line of code.
-#: config/tc-i386.c:2098
+#: config/tc-i386.c:2159
#, c-format
msgid "stand-alone `%s' prefix"
msgstr ""
-#: config/tc-i386.c:2127 config/tc-i386.c:2142
+#: config/tc-i386.c:2188 config/tc-i386.c:2203
#, c-format
msgid "`%s' operand %d must use `%%es' segment"
msgstr ""
-#: config/tc-i386.c:2222
+#: config/tc-i386.c:2283
msgid ""
"no instruction mnemonic suffix given and no register operands; can't size "
"instruction"
@@ -4139,404 +4311,400 @@ msgstr ""
#. Prohibit these changes in the 64bit mode, since the
#. lowering is more complicated.
-#: config/tc-i386.c:2306 config/tc-i386.c:2365 config/tc-i386.c:2382
-#: config/tc-i386.c:2414 config/tc-i386.c:2447
+#: config/tc-i386.c:2367 config/tc-i386.c:2426 config/tc-i386.c:2443
+#: config/tc-i386.c:2475 config/tc-i386.c:2508
#, c-format
msgid "Incorrect register `%%%s' used with `%c' suffix"
msgstr ""
-#: config/tc-i386.c:2314 config/tc-i386.c:2372 config/tc-i386.c:2454
+#: config/tc-i386.c:2375 config/tc-i386.c:2433 config/tc-i386.c:2515
#, c-format
msgid "using `%%%s' instead of `%%%s' due to `%c' suffix"
msgstr ""
-#: config/tc-i386.c:2329 config/tc-i386.c:2350 config/tc-i386.c:2401
-#: config/tc-i386.c:2432
+#: config/tc-i386.c:2390 config/tc-i386.c:2411 config/tc-i386.c:2462
+#: config/tc-i386.c:2493
#, c-format
msgid "`%%%s' not allowed with `%s%c'"
msgstr ""
-#: config/tc-i386.c:2495
+#: config/tc-i386.c:2556
msgid "no instruction mnemonic suffix given; can't determine immediate size"
msgstr ""
-#: config/tc-i386.c:2528
+#: config/tc-i386.c:2589
#, c-format
msgid ""
"no instruction mnemonic suffix given; can't determine immediate size %x %c"
msgstr ""
#. Reversed arguments on faddp, fsubp, etc.
-#: config/tc-i386.c:2577
+#: config/tc-i386.c:2638
#, c-format
msgid "translating to `%s %%%s,%%%s'"
msgstr ""
#. Extraneous `l' suffix on fp insn.
-#: config/tc-i386.c:2584
+#: config/tc-i386.c:2645
#, c-format
msgid "translating to `%s %%%s'"
msgstr ""
-#: config/tc-i386.c:2602
+#: config/tc-i386.c:2663
#, c-format
msgid "you can't `pop %%cs'"
msgstr ""
#. lea
-#: config/tc-i386.c:2621
+#: config/tc-i386.c:2682
msgid "segment override on `lea' is ineffectual"
msgstr ""
-#: config/tc-i386.c:2930 config/tc-i386.c:3024 config/tc-i386.c:3069
+#: config/tc-i386.c:2991 config/tc-i386.c:3085 config/tc-i386.c:3130
msgid "skipping prefixes on this instruction"
msgstr ""
-#: config/tc-i386.c:3089
+#: config/tc-i386.c:3150
msgid "16-bit jump out of range"
msgstr ""
-#: config/tc-i386.c:3098
+#: config/tc-i386.c:3159
#, c-format
msgid "can't handle non absolute segment in `%s'"
msgstr ""
-#: config/tc-i386.c:3539
+#: config/tc-i386.c:3601
#, c-format
msgid "@%s reloc is not supported in %s bit mode"
msgstr ""
-#: config/tc-i386.c:3615
+#: config/tc-i386.c:3677
msgid "only 1 or 2 immediate operands are allowed"
msgstr ""
-#: config/tc-i386.c:3638 config/tc-i386.c:3830
+#: config/tc-i386.c:3700 config/tc-i386.c:3892
#, c-format
msgid "junk `%s' after expression"
msgstr ""
#. Missing or bad expr becomes absolute 0.
-#: config/tc-i386.c:3649
+#: config/tc-i386.c:3711
#, c-format
msgid "missing or invalid immediate expression `%s' taken as 0"
msgstr ""
-#: config/tc-i386.c:3681 config/tc-i386.c:3896
+#: config/tc-i386.c:3743 config/tc-i386.c:3958
#, c-format
msgid "unimplemented segment %s in operand"
msgstr ""
-#: config/tc-i386.c:3683 config/tc-i386.c:3898
+#: config/tc-i386.c:3745 config/tc-i386.c:3960
#, c-format
msgid "unimplemented segment type %d in operand"
msgstr ""
-#: config/tc-i386.c:3727 config/tc-i386.c:5925
+#: config/tc-i386.c:3789 config/tc-i386.c:6011
#, c-format
msgid "expecting scale factor of 1, 2, 4, or 8: got `%s'"
msgstr ""
-#: config/tc-i386.c:3734
+#: config/tc-i386.c:3796
#, c-format
msgid "scale factor of %d without an index register"
msgstr ""
-#: config/tc-i386.c:3850
+#: config/tc-i386.c:3912
#, c-format
msgid "bad expression used with @%s"
msgstr ""
#. Missing or bad expr becomes absolute 0.
-#: config/tc-i386.c:3872
+#: config/tc-i386.c:3934
#, c-format
msgid "missing or invalid displacement expression `%s' taken as 0"
msgstr ""
-#: config/tc-i386.c:3996
+#: config/tc-i386.c:4058
#, c-format
msgid "`%s' is not a valid base/index expression"
msgstr ""
-#: config/tc-i386.c:4000
+#: config/tc-i386.c:4062
#, c-format
msgid "`%s' is not a valid %s bit base/index expression"
msgstr ""
-#: config/tc-i386.c:4075
+#: config/tc-i386.c:4137
#, c-format
msgid "bad memory operand `%s'"
msgstr ""
-#: config/tc-i386.c:4090
+#: config/tc-i386.c:4152
#, c-format
msgid "junk `%s' after register"
msgstr ""
-#: config/tc-i386.c:4099 config/tc-i386.c:4214 config/tc-i386.c:4252
+#: config/tc-i386.c:4161 config/tc-i386.c:4276 config/tc-i386.c:4314
#, c-format
msgid "bad register name `%s'"
msgstr ""
-#: config/tc-i386.c:4107
+#: config/tc-i386.c:4169
msgid "immediate operand illegal with absolute jump"
msgstr ""
-#: config/tc-i386.c:4129
+#: config/tc-i386.c:4191
#, c-format
msgid "too many memory references for `%s'"
msgstr ""
-#: config/tc-i386.c:4207
+#: config/tc-i386.c:4269
#, c-format
msgid "expecting `,' or `)' after index register in `%s'"
msgstr ""
-#: config/tc-i386.c:4231
+#: config/tc-i386.c:4293
#, c-format
msgid "expecting `)' after scale factor in `%s'"
msgstr ""
-#: config/tc-i386.c:4238
+#: config/tc-i386.c:4300
#, c-format
msgid "expecting index register or scale factor after `,'; got '%c'"
msgstr ""
-#: config/tc-i386.c:4245
+#: config/tc-i386.c:4307
#, c-format
msgid "expecting `,' or `)' after base register in `%s'"
msgstr ""
#. It's not a memory operand; argh!
-#: config/tc-i386.c:4286
+#: config/tc-i386.c:4348
#, c-format
msgid "invalid char %s beginning operand %d `%s'"
msgstr ""
-#: config/tc-i386.c:4469
+#: config/tc-i386.c:4531
msgid "long jump required"
msgstr ""
-#: config/tc-i386.c:4733
+#: config/tc-i386.c:4805
msgid "Bad call to md_atof ()"
msgstr ""
-#: config/tc-i386.c:4897
+#: config/tc-i386.c:4973
msgid "No compiled in support for x86_64"
msgstr ""
-#: config/tc-i386.c:4918
+#: config/tc-i386.c:4994
msgid ""
" -Q ignored\n"
" -V print assembler version number\n"
" -k ignored\n"
+" -n Do not optimize code alignment\n"
" -q quieten some warnings\n"
" -s ignored\n"
msgstr ""
-#: config/tc-i386.c:4925
-msgid " -q quieten some warnings\n"
+#: config/tc-i386.c:5002
+msgid ""
+" -n Do not optimize code alignment\n"
+" -q quieten some warnings\n"
msgstr ""
-#: config/tc-i386.c:5026 config/tc-s390.c:1601
+#: config/tc-i386.c:5104 config/tc-s390.c:1841
msgid "GOT already in symbol table"
msgstr ""
-#: config/tc-i386.c:5166
+#: config/tc-i386.c:5249
#, c-format
msgid "can not do %d byte relocation"
msgstr ""
-#: config/tc-i386.c:5231 config/tc-s390.c:1969
+#: config/tc-i386.c:5317 config/tc-s390.c:2285
#, c-format
msgid "cannot represent relocation type %s"
msgstr ""
-#: config/tc-i386.c:5527
+#: config/tc-i386.c:5613
#, c-format
msgid "too many memory references for '%s'"
msgstr ""
-#: config/tc-i386.c:5690
+#: config/tc-i386.c:5776
#, c-format
msgid "Unknown operand modifier `%s'\n"
msgstr ""
-#: config/tc-i386.c:5897
+#: config/tc-i386.c:5983
#, c-format
msgid "`%s' is not a valid segment register"
msgstr ""
-#: config/tc-i386.c:5907 config/tc-i386.c:6028
+#: config/tc-i386.c:5993 config/tc-i386.c:6114
msgid "Register scaling only allowed in memory operands."
msgstr ""
-#: config/tc-i386.c:5938
+#: config/tc-i386.c:6024
msgid "Too many register references in memory operand.\n"
msgstr ""
-#: config/tc-i386.c:6007
+#: config/tc-i386.c:6093
#, c-format
msgid "Syntax error. Expecting a constant. Got `%s'.\n"
msgstr ""
-#: config/tc-i386.c:6077
+#: config/tc-i386.c:6163
#, c-format
msgid "Unrecognized token '%s'"
msgstr ""
-#: config/tc-i386.c:6094
+#: config/tc-i386.c:6180
#, c-format
msgid "Unexpected token `%s'\n"
msgstr ""
-#: config/tc-i386.c:6238
+#: config/tc-i386.c:6324
#, c-format
msgid "Unrecognized token `%s'\n"
msgstr ""
-#: config/tc-i860.c:154 config/tc-i860.c:158
+#: config/tc-i860.c:165 config/tc-i860.c:169
msgid "Unknown temporary pseudo register"
msgstr ""
-#: config/tc-i860.c:181 config/tc-mips.c:1074
+#: config/tc-i860.c:192 config/tc-mips.c:1105
#, c-format
msgid "internal error: can't hash `%s': %s\n"
msgstr ""
-#: config/tc-i860.c:201
+#: config/tc-i860.c:212
msgid "Defective assembler. No assembly attempted."
msgstr ""
-#: config/tc-i860.c:347
+#: config/tc-i860.c:362
#, c-format
msgid "Expanded opcode after delayed branch: `%s'"
msgstr ""
-#: config/tc-i860.c:351
+#: config/tc-i860.c:366
#, c-format
msgid "Expanded opcode in dual mode: `%s'"
msgstr ""
-#: config/tc-i860.c:355
+#: config/tc-i860.c:370
#, c-format
msgid "An instruction was expanded (%s)"
msgstr ""
-#: config/tc-i860.c:613
+#: config/tc-i860.c:643
msgid "Pipelined instruction: fsrc1 = fdest"
msgstr ""
-#: config/tc-i860.c:776 config/tc-i860.c:783 config/tc-i860.c:790
+#: config/tc-i860.c:844 config/tc-i860.c:851 config/tc-i860.c:858
msgid "Assembler does not yet support PIC"
msgstr ""
-#: config/tc-i860.c:849
+#: config/tc-i860.c:919
#, c-format
msgid "Illegal operands for %s"
msgstr ""
-#: config/tc-i860.c:873 config/tc-sparc.c:2737
+#: config/tc-i860.c:947 config/tc-sparc.c:2834
msgid "bad segment"
msgstr ""
-#: config/tc-i860.c:965
-msgid "md_number_to_disp\n"
-msgstr ""
-
-#: config/tc-i860.c:975
-msgid "i860_number_to_field\n"
-msgstr ""
-
-#: config/tc-i860.c:984
+#: config/tc-i860.c:1037
msgid "i860_estimate_size_before_relax\n"
msgstr ""
-#: config/tc-i860.c:1075
+#: config/tc-i860.c:1134
msgid ""
" -EL\t\t\t generate code for little endian mode (default)\n"
" -EB\t\t\t generate code for big endian mode\n"
" -mwarn-expand\t\t warn if pseudo operations are expanded\n"
+" -mxp\t\t\t enable i860XP support (disabled by default)\n"
msgstr ""
#. SVR4 compatibility flags.
-#: config/tc-i860.c:1081
+#: config/tc-i860.c:1141
msgid ""
" -V\t\t\t print assembler version number\n"
" -Qy, -Qn\t\t ignored\n"
msgstr ""
-#: config/tc-i860.c:1150
+#: config/tc-i860.c:1210
msgid "This immediate requires 0 MOD 2 alignment"
msgstr ""
-#: config/tc-i860.c:1153
+#: config/tc-i860.c:1213
msgid "This immediate requires 0 MOD 4 alignment"
msgstr ""
-#: config/tc-i860.c:1156
+#: config/tc-i860.c:1216
msgid "This immediate requires 0 MOD 8 alignment"
msgstr ""
-#: config/tc-i860.c:1159
+#: config/tc-i860.c:1219
msgid "This immediate requires 0 MOD 16 alignment"
msgstr ""
-#: config/tc-i860.c:1257
+#: config/tc-i860.c:1317
msgid "5-bit immediate too large"
msgstr ""
-#: config/tc-i860.c:1260
+#: config/tc-i860.c:1320
msgid "5-bit field must be absolute"
msgstr ""
-#: config/tc-i860.c:1305 config/tc-i860.c:1328
+#: config/tc-i860.c:1365 config/tc-i860.c:1388
msgid "A branch offset requires 0 MOD 4 alignment"
msgstr ""
-#: config/tc-i860.c:1349
+#: config/tc-i860.c:1409
#, c-format
-msgid "Unrecognized fix-up (0x%08x)"
+msgid "Unrecognized fix-up (0x%08lx)"
msgstr ""
#: config/tc-i860.h:80
msgid "i860_convert_frag\n"
msgstr ""
-#: config/tc-i960.c:550
+#: config/tc-i960.c:574
#, c-format
msgid "Hashing returned \"%s\"."
msgstr ""
#. Offset of last character in opcode mnemonic
-#: config/tc-i960.c:584
+#: config/tc-i960.c:608
msgid "branch prediction invalid on this opcode"
msgstr ""
-#: config/tc-i960.c:624
+#: config/tc-i960.c:648
#, c-format
msgid "invalid opcode, \"%s\"."
msgstr ""
-#: config/tc-i960.c:629
+#: config/tc-i960.c:653
#, c-format
msgid "improper number of operands. expecting %d, got %d"
msgstr ""
-#: config/tc-i960.c:861
+#: config/tc-i960.c:877
#, c-format
msgid "Fixup of %ld too large for field width of %d"
msgstr ""
-#: config/tc-i960.c:978
+#: config/tc-i960.c:994
#, c-format
msgid "invalid architecture %s"
msgstr ""
-#: config/tc-i960.c:998
+#: config/tc-i960.c:1014
msgid "I960 options:\n"
msgstr ""
-#: config/tc-i960.c:1001
+#: config/tc-i960.c:1017
msgid ""
"\n"
"\t\t\tspecify variant of 960 architecture\n"
@@ -4547,208 +4715,208 @@ msgid ""
"\t\t\tlong displacements\n"
msgstr ""
-#: config/tc-i960.c:1405
+#: config/tc-i960.c:1419 config/tc-xtensa.c:8604
msgid "too many operands"
msgstr ""
-#: config/tc-i960.c:1464 config/tc-i960.c:1691
+#: config/tc-i960.c:1477 config/tc-i960.c:1702
msgid "expression syntax error"
msgstr ""
-#: config/tc-i960.c:1502
+#: config/tc-i960.c:1515
msgid "attempt to branch into different segment"
msgstr ""
-#: config/tc-i960.c:1506
+#: config/tc-i960.c:1519
#, c-format
msgid "target of %s instruction must be a label"
msgstr ""
-#: config/tc-i960.c:1545
+#: config/tc-i960.c:1557
msgid "unmatched '['"
msgstr ""
-#: config/tc-i960.c:1556
+#: config/tc-i960.c:1568
msgid "garbage after index spec ignored"
msgstr ""
#. We never moved: there was no opcode either!
-#: config/tc-i960.c:1622
+#: config/tc-i960.c:1633
msgid "missing opcode"
msgstr ""
-#: config/tc-i960.c:2037
+#: config/tc-i960.c:2046
msgid "invalid index register"
msgstr ""
-#: config/tc-i960.c:2060
+#: config/tc-i960.c:2069
msgid "invalid scale factor"
msgstr ""
-#: config/tc-i960.c:2243
+#: config/tc-i960.c:2250
msgid "unaligned register"
msgstr ""
-#: config/tc-i960.c:2266
+#: config/tc-i960.c:2273
msgid "no such sfr in this architecture"
msgstr ""
-#: config/tc-i960.c:2304
+#: config/tc-i960.c:2311
msgid "illegal literal"
msgstr ""
#. Should not happen: see block comment above
-#: config/tc-i960.c:2534
+#: config/tc-i960.c:2539
#, c-format
msgid "Trying to 'bal' to %s"
msgstr ""
-#: config/tc-i960.c:2545
+#: config/tc-i960.c:2550
msgid "Looks like a proc, but can't tell what kind.\n"
msgstr ""
-#: config/tc-i960.c:2576
+#: config/tc-i960.c:2582
msgid "should have 1 or 2 operands"
msgstr ""
-#: config/tc-i960.c:2585 config/tc-i960.c:2604
+#: config/tc-i960.c:2591 config/tc-i960.c:2610
#, c-format
msgid "Redefining leafproc %s"
msgstr ""
-#: config/tc-i960.c:2635
+#: config/tc-i960.c:2641
msgid "should have two operands"
msgstr ""
-#: config/tc-i960.c:2645
+#: config/tc-i960.c:2651
msgid "'entry_num' must be absolute number in [0,31]"
msgstr ""
-#: config/tc-i960.c:2654
+#: config/tc-i960.c:2660
#, c-format
msgid "Redefining entrynum for sysproc %s"
msgstr ""
-#: config/tc-i960.c:2761
+#: config/tc-i960.c:2764
msgid "architecture of opcode conflicts with that of earlier instruction(s)"
msgstr ""
-#: config/tc-i960.c:2782
+#: config/tc-i960.c:2785
msgid "big endian mode is not supported"
msgstr ""
-#: config/tc-i960.c:2784
+#: config/tc-i960.c:2787
#, c-format
msgid "ignoring unrecognized .endian type `%s'"
msgstr ""
-#: config/tc-i960.c:3056
+#: config/tc-i960.c:3071
#, c-format
msgid "leafproc symbol '%s' undefined"
msgstr ""
-#: config/tc-i960.c:3066
+#: config/tc-i960.c:3081
#, c-format
msgid "Warning: making leafproc entries %s and %s both global\n"
msgstr ""
-#: config/tc-i960.c:3175
+#: config/tc-i960.c:3190
msgid "option --link-relax is only supported in b.out format"
msgstr ""
-#: config/tc-i960.c:3218 write.c:2664
-msgid "callj to difference of two symbols"
+#: config/tc-ia64.c:982
+msgid "Bad .section directive: want a,o,s,w,x,M,S,G,T in string"
msgstr ""
-#: config/tc-ia64.c:1078
+#: config/tc-ia64.c:1105
msgid "Unwind directive not followed by an instruction."
msgstr ""
-#: config/tc-ia64.c:4512
+#: config/tc-ia64.c:4563
msgid "Register name expected"
msgstr ""
-#: config/tc-ia64.c:4517 config/tc-ia64.c:4803
+#: config/tc-ia64.c:4568 config/tc-ia64.c:4854
msgid "Comma expected"
msgstr ""
-#: config/tc-ia64.c:4525
+#: config/tc-ia64.c:4576
msgid "Register value annotation ignored"
msgstr ""
-#: config/tc-ia64.c:4549
+#: config/tc-ia64.c:4600
msgid "Directive invalid within a bundle"
msgstr ""
-#: config/tc-ia64.c:4616
+#: config/tc-ia64.c:4667
msgid "Missing predicate relation type"
msgstr ""
-#: config/tc-ia64.c:4632
+#: config/tc-ia64.c:4683
msgid "Unrecognized predicate relation type"
msgstr ""
-#: config/tc-ia64.c:4652 config/tc-ia64.c:4677
+#: config/tc-ia64.c:4703 config/tc-ia64.c:4728
msgid "Predicate register expected"
msgstr ""
-#: config/tc-ia64.c:4664
+#: config/tc-ia64.c:4715
msgid "Duplicate predicate register ignored"
msgstr ""
-#: config/tc-ia64.c:4686
+#: config/tc-ia64.c:4737
msgid "Bad register range"
msgstr ""
-#: config/tc-ia64.c:4714
+#: config/tc-ia64.c:4765
msgid "Predicate source and target required"
msgstr ""
-#: config/tc-ia64.c:4716 config/tc-ia64.c:4728
+#: config/tc-ia64.c:4767 config/tc-ia64.c:4779
msgid "Use of p0 is not valid in this context"
msgstr ""
-#: config/tc-ia64.c:4723
+#: config/tc-ia64.c:4774
msgid "At least two PR arguments expected"
msgstr ""
-#: config/tc-ia64.c:4737
+#: config/tc-ia64.c:4788
msgid "At least one PR argument expected"
msgstr ""
-#: config/tc-ia64.c:4773
+#: config/tc-ia64.c:4824
#, c-format
msgid "Inserting \"%s\" into entry hint table failed: %s"
msgstr ""
#. FIXME -- need 62-bit relocation type
-#: config/tc-ia64.c:5243
+#: config/tc-ia64.c:5302
msgid "62-bit relocation not yet implemented"
msgstr ""
#. XXX technically, this is wrong: we should not be issuing warning
#. messages until we're sure this instruction pattern is going to
#. be used!
-#: config/tc-ia64.c:5316
+#: config/tc-ia64.c:5375
msgid "lower 16 bits of mask ignored"
msgstr ""
-#: config/tc-ia64.c:5871
+#: config/tc-ia64.c:5939
msgid "Value truncated to 62 bits"
msgstr ""
-#: config/tc-ia64.c:6222
+#: config/tc-ia64.c:6291
msgid ""
"Additional NOP may be necessary to workaround Itanium processor A/B step "
"errata"
msgstr ""
-#: config/tc-ia64.c:6405
+#: config/tc-ia64.c:6474
#, c-format
msgid "Unrecognized option '-x%s'"
msgstr ""
-#: config/tc-ia64.c:6433
+#: config/tc-ia64.c:6502
msgid ""
"IA-64 options:\n"
" --mconstant-gp\t mark output file as using the constant-GP model\n"
@@ -4763,208 +4931,268 @@ msgid ""
" -xdebug\t\t debug dependency violation checker\n"
msgstr ""
-#: config/tc-ia64.c:6452
+#: config/tc-ia64.c:6521
msgid "--gstabs is not supported for ia64"
msgstr ""
-#: config/tc-ia64.c:6743 config/tc-mips.c:1063
+#: config/tc-ia64.c:6824 config/tc-mips.c:1094
msgid "Could not set architecture and machine"
msgstr ""
-#: config/tc-ia64.c:6850
+#: config/tc-ia64.c:6931
msgid "Explicit stops are ignored in auto mode"
msgstr ""
-#: config/tc-ia64.c:6900
+#: config/tc-ia64.c:6981
msgid "Found '{' after explicit switch to automatic mode"
msgstr ""
-#: config/tc-ia64.c:7347
+#: config/tc-ia64.c:7428
#, c-format
msgid "Unhandled dependency %s for %s (%s), note %d"
msgstr ""
-#: config/tc-ia64.c:8623
+#: config/tc-ia64.c:8704
#, c-format
msgid "Unrecognized dependency specifier %d\n"
msgstr ""
-#: config/tc-ia64.c:9425
+#: config/tc-ia64.c:9506
msgid "Only the first path encountering the conflict is reported"
msgstr ""
-#: config/tc-ia64.c:9428
+#: config/tc-ia64.c:9509
msgid "This is the location of the conflicting usage"
msgstr ""
+#: config/tc-ia64.c:10778 read.c:1370 read.c:1976 read.c:2184 read.c:2795
+msgid "expected symbol name"
+msgstr ""
+
+#: config/tc-ia64.c:10788 read.c:1380 read.c:2194 read.c:2805 stabs.c:478
+#, c-format
+msgid "expected comma after \"%s\""
+msgstr ""
+
+#: config/tc-ia64.c:10829
+#, c-format
+msgid "`%s' is already the alias of %s `%s'"
+msgstr ""
+
+#: config/tc-ia64.c:10839
+#, c-format
+msgid "%s `%s' already has an alias `%s'"
+msgstr ""
+
+#: config/tc-ia64.c:10850
+#, c-format
+msgid "inserting \"%s\" into %s alias hash table failed: %s"
+msgstr ""
+
+#: config/tc-ia64.c:10858
+#, c-format
+msgid "inserting \"%s\" into %s name hash table failed: %s"
+msgstr ""
+
+#: config/tc-ia64.c:10877
+#, c-format
+msgid "symbol `%s' aliased to `%s' is not used"
+msgstr ""
+
+#: config/tc-ia64.c:10899
+#, c-format
+msgid "section `%s' aliased to `%s' is not used"
+msgstr ""
+
+#: config/tc-ip2k.c:123
+msgid "IP2K specific command line options:\n"
+msgstr ""
+
+#: config/tc-ip2k.c:124
+msgid " -mip2022 restrict to IP2022 insns \n"
+msgstr ""
+
+#: config/tc-ip2k.c:125
+msgid " -mip2022ext permit extended IP2022 insn\n"
+msgstr ""
+
+#: config/tc-ip2k.c:246
+msgid "md_pcrel_from\n"
+msgstr ""
+
#. Pretend that we do not recognise this option.
-#: config/tc-m32r.c:231
+#: config/tc-m32r.c:233
msgid "Unrecognised option: -hidden"
msgstr ""
-#: config/tc-m32r.c:265
+#: config/tc-m32r.c:267
msgid " M32R specific command line options:\n"
msgstr ""
-#: config/tc-m32r.c:267
+#: config/tc-m32r.c:269
msgid ""
" -m32r disable support for the m32rx instruction set\n"
msgstr ""
-#: config/tc-m32r.c:269
+#: config/tc-m32r.c:271
msgid " -m32rx support the extended m32rx instruction set\n"
msgstr ""
-#: config/tc-m32r.c:271
+#: config/tc-m32r.c:273
msgid " -O try to combine instructions in parallel\n"
msgstr ""
-#: config/tc-m32r.c:274
+#: config/tc-m32r.c:276
msgid ""
" -warn-explicit-parallel-conflicts warn when parallel instructions\n"
msgstr ""
-#: config/tc-m32r.c:276
+#: config/tc-m32r.c:278
msgid " violate contraints\n"
msgstr ""
-#: config/tc-m32r.c:278
+#: config/tc-m32r.c:280
msgid " -no-warn-explicit-parallel-conflicts do not warn when parallel\n"
msgstr ""
-#: config/tc-m32r.c:280
+#: config/tc-m32r.c:282
msgid ""
" instructions violate contraints\n"
msgstr ""
-#: config/tc-m32r.c:282
+#: config/tc-m32r.c:284
msgid ""
" -Wp synonym for -warn-explicit-parallel-conflicts\n"
msgstr ""
-#: config/tc-m32r.c:284
+#: config/tc-m32r.c:286
msgid ""
" -Wnp synonym for -no-warn-explicit-parallel-conflicts\n"
msgstr ""
-#: config/tc-m32r.c:287
+#: config/tc-m32r.c:289
msgid ""
" -warn-unmatched-high warn when an (s)high reloc has no matching low "
"reloc\n"
msgstr ""
-#: config/tc-m32r.c:289
+#: config/tc-m32r.c:291
msgid " -no-warn-unmatched-high do not warn about missing low relocs\n"
msgstr ""
-#: config/tc-m32r.c:291
+#: config/tc-m32r.c:293
msgid " -Wuh synonym for -warn-unmatched-high\n"
msgstr ""
-#: config/tc-m32r.c:293
+#: config/tc-m32r.c:295
msgid " -Wnuh synonym for -no-warn-unmatched-high\n"
msgstr ""
-#: config/tc-m32r.c:297
+#: config/tc-m32r.c:299
msgid " -relax create linker relaxable code\n"
msgstr ""
-#: config/tc-m32r.c:299
+#: config/tc-m32r.c:301
msgid " -cpu-desc provide runtime cpu description file\n"
msgstr ""
-#: config/tc-m32r.c:691
+#: config/tc-m32r.c:700
msgid "Instructions write to the same destination register."
msgstr ""
-#: config/tc-m32r.c:699
+#: config/tc-m32r.c:708
msgid "Instructions do not use parallel execution pipelines."
msgstr ""
-#: config/tc-m32r.c:706
+#: config/tc-m32r.c:715
msgid "Instructions share the same execution pipeline"
msgstr ""
-#: config/tc-m32r.c:776 config/tc-m32r.c:872
+#: config/tc-m32r.c:791 config/tc-m32r.c:887
#, c-format
msgid "not a 16 bit instruction '%s'"
msgstr ""
-#: config/tc-m32r.c:783 config/tc-m32r.c:879 config/tc-m32r.c:1035
+#: config/tc-m32r.c:798 config/tc-m32r.c:894 config/tc-m32r.c:1050
#, c-format
msgid "unknown instruction '%s'"
msgstr ""
-#: config/tc-m32r.c:792 config/tc-m32r.c:886 config/tc-m32r.c:1042
+#: config/tc-m32r.c:807 config/tc-m32r.c:901 config/tc-m32r.c:1057
#, c-format
msgid "instruction '%s' is for the M32RX only"
msgstr ""
-#: config/tc-m32r.c:801 config/tc-m32r.c:895
+#: config/tc-m32r.c:816 config/tc-m32r.c:910
#, c-format
msgid "instruction '%s' cannot be executed in parallel."
msgstr ""
-#: config/tc-m32r.c:856 config/tc-m32r.c:920 config/tc-m32r.c:1092
+#: config/tc-m32r.c:871 config/tc-m32r.c:935 config/tc-m32r.c:1107
msgid "internal error: lookup/get operands failed"
msgstr ""
-#: config/tc-m32r.c:905
+#: config/tc-m32r.c:920
#, c-format
msgid "'%s': only the NOP instruction can be issued in parallel on the m32r"
msgstr ""
-#: config/tc-m32r.c:934
+#: config/tc-m32r.c:949
#, c-format
msgid ""
"%s: output of 1st instruction is the same as an input to 2nd instruction - "
"is this intentional ?"
msgstr ""
-#: config/tc-m32r.c:938
+#: config/tc-m32r.c:953
#, c-format
msgid ""
"%s: output of 2nd instruction is the same as an input to 1st instruction - "
"is this intentional ?"
msgstr ""
-#: config/tc-m32r.c:1252 config/tc-ppc.c:1574 config/tc-ppc.c:3998
+#: config/tc-m32r.c:1267 config/tc-ppc.c:1732 config/tc-ppc.c:4263
msgid "Expected comma after symbol-name: rest of line ignored."
msgstr ""
-#: config/tc-m32r.c:1262
+#: config/tc-m32r.c:1277
#, c-format
msgid ".SCOMMon length (%ld.) <0! Ignored."
msgstr ""
-#: config/tc-m32r.c:1276 config/tc-ppc.c:1596 config/tc-ppc.c:2647
-#: config/tc-ppc.c:4022
+#: config/tc-m32r.c:1291 config/tc-ppc.c:1754 config/tc-ppc.c:2899
+#: config/tc-ppc.c:4287
msgid "ignoring bad alignment"
msgstr ""
-#: config/tc-m32r.c:1288 config/tc-ppc.c:1633 config/tc-v850.c:333
+#: config/tc-m32r.c:1303 config/tc-ppc.c:1791 config/tc-v850.c:335
msgid "Common alignment not a power of 2"
msgstr ""
-#: config/tc-m32r.c:1303 config/tc-ppc.c:1607 config/tc-ppc.c:4034
+#: config/tc-m32r.c:1318 config/tc-ppc.c:1765 config/tc-ppc.c:4299
#, c-format
msgid "Ignoring attempt to re-define symbol `%s'."
msgstr ""
-#: config/tc-m32r.c:1312
+#: config/tc-m32r.c:1327
#, c-format
msgid "Length of .scomm \"%s\" is already %ld. Not changed to %ld."
msgstr ""
-#: config/tc-m32r.c:1789
+#: config/tc-m32r.c:1808
msgid "Unmatched high/shigh reloc"
msgstr ""
-#: config/tc-m68hc11.c:327
+#: config/tc-m68hc11.c:372
#, c-format
msgid ""
-"Motorola 68HC11/68HC12 options:\n"
-" -m68hc11 | -m68hc12 specify the processor [default %s]\n"
+"Motorola 68HC11/68HC12/68HCS12 options:\n"
+" -m68hc11 | -m68hc12 |\n"
+" -m68hcs12 specify the processor [default %s]\n"
+" -mshort use 16-bit int ABI (default)\n"
+" -mlong use 32-bit int ABI\n"
+" -mshort-double use 32-bit double ABI\n"
+" -mlong-double use 64-bit double ABI (default)\n"
" --force-long-branchs always turn relative branchs into absolute ones\n"
" -S,--short-branchs do not turn relative branchs into absolute ones\n"
" when the offset is out of range\n"
@@ -4976,55 +5204,55 @@ msgid ""
" (used for testing)\n"
msgstr ""
-#: config/tc-m68hc11.c:368
+#: config/tc-m68hc11.c:418
#, c-format
msgid "Default target `%s' is not supported."
msgstr ""
#. Dump the opcode statistics table.
-#: config/tc-m68hc11.c:387
+#: config/tc-m68hc11.c:437
msgid "Name # Modes Min ops Max ops Modes mask # Used\n"
msgstr ""
-#: config/tc-m68hc11.c:437
+#: config/tc-m68hc11.c:505
#, c-format
msgid "Option `%s' is not recognized."
msgstr ""
-#: config/tc-m68hc11.c:658
+#: config/tc-m68hc11.c:737
msgid "#<imm8>"
msgstr ""
-#: config/tc-m68hc11.c:667
+#: config/tc-m68hc11.c:746
msgid "#<imm16>"
msgstr ""
-#: config/tc-m68hc11.c:676 config/tc-m68hc11.c:685
+#: config/tc-m68hc11.c:755 config/tc-m68hc11.c:764
msgid "<imm8>,X"
msgstr ""
-#: config/tc-m68hc11.c:703
+#: config/tc-m68hc11.c:791
msgid "*<abs8>"
msgstr ""
-#: config/tc-m68hc11.c:715
+#: config/tc-m68hc11.c:803
msgid "#<mask>"
msgstr ""
-#: config/tc-m68hc11.c:725
+#: config/tc-m68hc11.c:813
#, c-format
msgid "symbol%d"
msgstr ""
-#: config/tc-m68hc11.c:727
+#: config/tc-m68hc11.c:815
msgid "<abs>"
msgstr ""
-#: config/tc-m68hc11.c:746
+#: config/tc-m68hc11.c:834
msgid "<label>"
msgstr ""
-#: config/tc-m68hc11.c:762
+#: config/tc-m68hc11.c:850
#, c-format
msgid ""
"# Example of `%s' instructions\n"
@@ -5032,591 +5260,604 @@ msgid ""
"_start:\n"
msgstr ""
-#: config/tc-m68hc11.c:810
+#: config/tc-m68hc11.c:898
#, c-format
msgid "Instruction `%s' is not recognized."
msgstr ""
-#: config/tc-m68hc11.c:815
+#: config/tc-m68hc11.c:903
#, c-format
msgid "Instruction formats for `%s':"
msgstr ""
-#: config/tc-m68hc11.c:948
+#: config/tc-m68hc11.c:1038
#, c-format
msgid "Immediate operand is not allowed for operand %d."
msgstr ""
-#: config/tc-m68hc11.c:974
+#: config/tc-m68hc11.c:1082
msgid "Indirect indexed addressing is not valid for 68HC11."
msgstr ""
-#: config/tc-m68hc11.c:994
+#: config/tc-m68hc11.c:1102
msgid "Spurious `,' or bad indirect register addressing mode."
msgstr ""
-#: config/tc-m68hc11.c:1010
+#: config/tc-m68hc11.c:1124
msgid "Missing second register or offset for indexed-indirect mode."
msgstr ""
-#: config/tc-m68hc11.c:1020
+#: config/tc-m68hc11.c:1134
msgid "Missing second register for indexed-indirect mode."
msgstr ""
-#: config/tc-m68hc11.c:1036
+#: config/tc-m68hc11.c:1150
msgid "Missing `]' to close indexed-indirect mode."
msgstr ""
-#: config/tc-m68hc11.c:1080
+#: config/tc-m68hc11.c:1195
msgid "Illegal operand."
msgstr ""
-#: config/tc-m68hc11.c:1085
+#: config/tc-m68hc11.c:1200
msgid "Missing operand."
msgstr ""
-#: config/tc-m68hc11.c:1137
+#: config/tc-m68hc11.c:1253
msgid "Pre-increment mode is not valid for 68HC11"
msgstr ""
-#: config/tc-m68hc11.c:1150
+#: config/tc-m68hc11.c:1266
msgid "Wrong register in register indirect mode."
msgstr ""
-#: config/tc-m68hc11.c:1158
+#: config/tc-m68hc11.c:1274
msgid "Missing `]' to close register indirect operand."
msgstr ""
-#: config/tc-m68hc11.c:1175
+#: config/tc-m68hc11.c:1294
msgid "Post-decrement mode is not valid for 68HC11."
msgstr ""
-#: config/tc-m68hc11.c:1183
+#: config/tc-m68hc11.c:1302
msgid "Post-increment mode is not valid for 68HC11."
msgstr ""
-#: config/tc-m68hc11.c:1200
+#: config/tc-m68hc11.c:1320
msgid "Invalid indexed indirect mode."
msgstr ""
-#: config/tc-m68hc11.c:1294
+#: config/tc-m68hc11.c:1417
#, c-format
msgid "Trap id `%ld' is out of range."
msgstr ""
-#: config/tc-m68hc11.c:1298
+#: config/tc-m68hc11.c:1421
msgid "Trap id must be within [0x30..0x39] or [0x40..0xff]."
msgstr ""
-#: config/tc-m68hc11.c:1305
+#: config/tc-m68hc11.c:1428
#, c-format
msgid "Operand out of 8-bit range: `%ld'."
msgstr ""
-#: config/tc-m68hc11.c:1312
+#: config/tc-m68hc11.c:1435
msgid "The trap id must be a constant."
msgstr ""
-#: config/tc-m68hc11.c:1337
+#: config/tc-m68hc11.c:1470
#, c-format
msgid "Operand `%x' not recognized in fixup8."
msgstr ""
-#: config/tc-m68hc11.c:1357
+#: config/tc-m68hc11.c:1490 config/tc-m68hc11.c:1542
#, c-format
msgid "Operand out of 16-bit range: `%ld'."
msgstr ""
-#: config/tc-m68hc11.c:1378
+#: config/tc-m68hc11.c:1522 config/tc-m68hc11.c:1558
#, c-format
msgid "Operand `%x' not recognized in fixup16."
msgstr ""
-#: config/tc-m68hc11.c:1396
+#: config/tc-m68hc11.c:1576
#, c-format
msgid "Unexpected branch conversion with `%x'"
msgstr ""
-#: config/tc-m68hc11.c:1483 config/tc-m68hc11.c:1612
+#: config/tc-m68hc11.c:1671 config/tc-m68hc11.c:1812
#, c-format
msgid "Operand out of range for a relative branch: `%ld'"
msgstr ""
-#: config/tc-m68hc11.c:1580
+#: config/tc-m68hc11.c:1780
msgid "Invalid register for dbcc/tbcc instruction."
msgstr ""
-#: config/tc-m68hc11.c:1671
+#: config/tc-m68hc11.c:1871
#, c-format
msgid "Increment/decrement value is out of range: `%ld'."
msgstr ""
-#: config/tc-m68hc11.c:1682
+#: config/tc-m68hc11.c:1882
msgid "Expecting a register."
msgstr ""
-#: config/tc-m68hc11.c:1697
+#: config/tc-m68hc11.c:1897
msgid "Invalid register for post/pre increment."
msgstr ""
-#: config/tc-m68hc11.c:1727
+#: config/tc-m68hc11.c:1927
msgid "Invalid register."
msgstr ""
-#: config/tc-m68hc11.c:1734
+#: config/tc-m68hc11.c:1934
#, c-format
msgid "Offset out of 16-bit range: %ld."
msgstr ""
-#: config/tc-m68hc11.c:1739
+#: config/tc-m68hc11.c:1939
#, c-format
msgid "Offset out of 5-bit range for movw/movb insn: %ld."
msgstr ""
-#: config/tc-m68hc11.c:1805
+#: config/tc-m68hc11.c:2020
msgid "Expecting register D for indexed indirect mode."
msgstr ""
-#: config/tc-m68hc11.c:1807
+#: config/tc-m68hc11.c:2022
msgid "Indexed indirect mode is not allowed for movb/movw."
msgstr ""
-#: config/tc-m68hc11.c:1824
+#: config/tc-m68hc11.c:2039
msgid "Invalid accumulator register."
msgstr ""
-#: config/tc-m68hc11.c:1849
+#: config/tc-m68hc11.c:2064
msgid "Invalid indexed register."
msgstr ""
-#: config/tc-m68hc11.c:1857
+#: config/tc-m68hc11.c:2072
msgid "Addressing mode not implemented yet."
msgstr ""
-#: config/tc-m68hc11.c:1872
+#: config/tc-m68hc11.c:2087
msgid "Invalid source register for this instruction, use 'tfr'."
msgstr ""
-#: config/tc-m68hc11.c:1874
+#: config/tc-m68hc11.c:2089
msgid "Invalid source register."
msgstr ""
-#: config/tc-m68hc11.c:1879
+#: config/tc-m68hc11.c:2094
msgid "Invalid destination register for this instruction, use 'tfr'."
msgstr ""
-#: config/tc-m68hc11.c:1881
+#: config/tc-m68hc11.c:2096
msgid "Invalid destination register."
msgstr ""
-#: config/tc-m68hc11.c:1966
+#: config/tc-m68hc11.c:2194
msgid "Invalid indexed register, expecting register X."
msgstr ""
-#: config/tc-m68hc11.c:1968
+#: config/tc-m68hc11.c:2196
msgid "Invalid indexed register, expecting register Y."
msgstr ""
-#: config/tc-m68hc11.c:2260
+#: config/tc-m68hc11.c:2508
msgid "No instruction or missing opcode."
msgstr ""
-#: config/tc-m68hc11.c:2325
+#: config/tc-m68hc11.c:2573
#, c-format
msgid "Opcode `%s' is not recognized."
msgstr ""
-#: config/tc-m68hc11.c:2347
+#: config/tc-m68hc11.c:2595
#, c-format
msgid "Garbage at end of instruction: `%s'."
msgstr ""
-#: config/tc-m68hc11.c:2370
+#: config/tc-m68hc11.c:2618
#, c-format
msgid "Invalid operand for `%s'"
msgstr ""
-#: config/tc-m68hc11.c:2427
+#: config/tc-m68hc11.c:2670
+#, c-format
+msgid "Invalid mode: %s\n"
+msgstr ""
+
+#: config/tc-m68hc11.c:2732
+msgid "bad .relax format"
+msgstr ""
+
+#: config/tc-m68hc11.c:2779
#, c-format
msgid "Relocation %d is not supported by object file format."
msgstr ""
-#: config/tc-m68hc11.c:2606
+#: config/tc-m68hc11.c:3065
msgid "bra or bsr with undefined symbol."
msgstr ""
-#: config/tc-m68hc11.c:2676 config/tc-m68hc11.c:2726
+#: config/tc-m68hc11.c:3168 config/tc-m68hc11.c:3225
#, c-format
msgid "Subtype %d is not recognized."
msgstr ""
-#: config/tc-m68hc11.c:2759
+#: config/tc-m68hc11.c:3289
msgid "Expression too complex."
msgstr ""
-#: config/tc-m68hc11.c:2787
+#: config/tc-m68hc11.c:3322
msgid "Value out of 16-bit range."
msgstr ""
-#: config/tc-m68hc11.c:2810
+#: config/tc-m68hc11.c:3346
#, c-format
msgid "Value %ld too large for 8-bit PC-relative branch."
msgstr ""
-#: config/tc-m68hc11.c:2817
+#: config/tc-m68hc11.c:3353
#, c-format
msgid "Auto increment/decrement offset '%ld' is out of range."
msgstr ""
-#: config/tc-m68hc11.c:2828
+#: config/tc-m68hc11.c:3371
#, c-format
msgid "Line %d: unknown relocation type: 0x%x."
msgstr ""
-#: config/tc-m68k.c:684
+#: config/tc-m68k.c:678
msgid "Unknown PC relative instruction"
msgstr ""
-#: config/tc-m68k.c:823
+#: config/tc-m68k.c:817
#, c-format
msgid "Can not do %d byte pc-relative relocation"
msgstr ""
-#: config/tc-m68k.c:825
+#: config/tc-m68k.c:819
#, c-format
msgid "Can not do %d byte pc-relative pic relocation"
msgstr ""
-#: config/tc-m68k.c:830
+#: config/tc-m68k.c:824
#, c-format
msgid "Can not do %d byte relocation"
msgstr ""
-#: config/tc-m68k.c:832
+#: config/tc-m68k.c:826
#, c-format
msgid "Can not do %d byte pic relocation"
msgstr ""
-#: config/tc-m68k.c:908
+#: config/tc-m68k.c:894
#, c-format
msgid "Unable to produce reloc against symbol '%s'"
msgstr ""
-#: config/tc-m68k.c:952 config/tc-mips.c:13040 config/tc-vax.c:3442
+#: config/tc-m68k.c:938 config/tc-mips.c:13322 config/tc-vax.c:3441
#, c-format
msgid "Cannot make %s relocation PC relative"
msgstr ""
-#: config/tc-m68k.c:1045 config/tc-tahoe.c:1495 config/tc-vax.c:1890
+#: config/tc-m68k.c:1031 config/tc-tahoe.c:1495 config/tc-vax.c:1889
msgid "No operator"
msgstr ""
-#: config/tc-m68k.c:1075 config/tc-tahoe.c:1512 config/tc-vax.c:1907
+#: config/tc-m68k.c:1061 config/tc-tahoe.c:1512 config/tc-vax.c:1906
msgid "Unknown operator"
msgstr ""
-#: config/tc-m68k.c:1850
+#: config/tc-m68k.c:1836
msgid "invalid instruction for this architecture; needs "
msgstr ""
-#: config/tc-m68k.c:1855
+#: config/tc-m68k.c:1841
msgid "fpu (68040, 68060 or 68881/68882)"
msgstr ""
-#: config/tc-m68k.c:1858
+#: config/tc-m68k.c:1844
msgid "mmu (68030 or 68851)"
msgstr ""
-#: config/tc-m68k.c:1861
+#: config/tc-m68k.c:1847
msgid "68020 or higher"
msgstr ""
-#: config/tc-m68k.c:1864
+#: config/tc-m68k.c:1850
msgid "68000 or higher"
msgstr ""
-#: config/tc-m68k.c:1867
+#: config/tc-m68k.c:1853
msgid "68010 or higher"
msgstr ""
-#: config/tc-m68k.c:1896
+#: config/tc-m68k.c:1882
msgid "operands mismatch"
msgstr ""
-#: config/tc-m68k.c:1953 config/tc-m68k.c:1959 config/tc-m68k.c:1965
-#: config/tc-mmix.c:2465 config/tc-mmix.c:2489
+#: config/tc-m68k.c:1939 config/tc-m68k.c:1945 config/tc-m68k.c:1951
+#: config/tc-mmix.c:2464 config/tc-mmix.c:2488
msgid "operand out of range"
msgstr ""
-#: config/tc-m68k.c:2022
+#: config/tc-m68k.c:2008
#, c-format
msgid "Bignum too big for %c format; truncated"
msgstr ""
-#: config/tc-m68k.c:2090
+#: config/tc-m68k.c:2076
msgid "displacement too large for this architecture; needs 68020 or higher"
msgstr ""
-#: config/tc-m68k.c:2200
+#: config/tc-m68k.c:2186
msgid ""
"scale factor invalid on this architecture; needs cpu32 or 68020 or higher"
msgstr ""
-#: config/tc-m68k.c:2205
+#: config/tc-m68k.c:2191
msgid "invalid index size for coldfire"
msgstr ""
-#: config/tc-m68k.c:2258
+#: config/tc-m68k.c:2244
msgid "Forcing byte displacement"
msgstr ""
-#: config/tc-m68k.c:2260
+#: config/tc-m68k.c:2246
msgid "byte displacement out of range"
msgstr ""
-#: config/tc-m68k.c:2307 config/tc-m68k.c:2345
+#: config/tc-m68k.c:2293 config/tc-m68k.c:2331
msgid "invalid operand mode for this architecture; needs 68020 or higher"
msgstr ""
-#: config/tc-m68k.c:2331 config/tc-m68k.c:2365
+#: config/tc-m68k.c:2317 config/tc-m68k.c:2351
msgid ":b not permitted; defaulting to :w"
msgstr ""
-#: config/tc-m68k.c:2442
+#: config/tc-m68k.c:2428
msgid "unsupported byte value; use a different suffix"
msgstr ""
-#: config/tc-m68k.c:2456
+#: config/tc-m68k.c:2442
msgid "unknown/incorrect operand"
msgstr ""
-#: config/tc-m68k.c:2489 config/tc-m68k.c:2497 config/tc-m68k.c:2504
-#: config/tc-m68k.c:2511
+#: config/tc-m68k.c:2475 config/tc-m68k.c:2483 config/tc-m68k.c:2490
+#: config/tc-m68k.c:2497
msgid "out of range"
msgstr ""
-#: config/tc-m68k.c:2557
+#: config/tc-m68k.c:2543
msgid "Can't use long branches on 68000/68010/5200"
msgstr ""
-#: config/tc-m68k.c:2667
+#: config/tc-m68k.c:2653
msgid "Expression out of range, using 0"
msgstr ""
-#: config/tc-m68k.c:2779 config/tc-m68k.c:2795
+#: config/tc-m68k.c:2765 config/tc-m68k.c:2781
msgid "Floating point register in register list"
msgstr ""
-#: config/tc-m68k.c:2785
+#: config/tc-m68k.c:2771
msgid "Wrong register in floating-point reglist"
msgstr ""
-#: config/tc-m68k.c:2801
+#: config/tc-m68k.c:2787
msgid "incorrect register in reglist"
msgstr ""
-#: config/tc-m68k.c:2807
+#: config/tc-m68k.c:2793
msgid "wrong register in floating-point reglist"
msgstr ""
#. ERROR
-#: config/tc-m68k.c:3248
+#: config/tc-m68k.c:3234
msgid "Extra )"
msgstr ""
#. ERROR
-#: config/tc-m68k.c:3259
+#: config/tc-m68k.c:3245
msgid "Missing )"
msgstr ""
-#: config/tc-m68k.c:3276
+#: config/tc-m68k.c:3262
msgid "Missing operand"
msgstr ""
-#: config/tc-m68k.c:3608
+#: config/tc-m68k.c:3594
#, c-format
msgid "%s -- statement `%s' ignored"
msgstr ""
-#: config/tc-m68k.c:3657
+#: config/tc-m68k.c:3643
#, c-format
msgid "Don't know how to figure width of %c in md_assemble()"
msgstr ""
-#: config/tc-m68k.c:3839 config/tc-m68k.c:3877
+#: config/tc-m68k.c:3825 config/tc-m68k.c:3863
#, c-format
msgid "Internal Error: Can't find %s in hash table"
msgstr ""
-#: config/tc-m68k.c:3842 config/tc-m68k.c:3880
+#: config/tc-m68k.c:3828 config/tc-m68k.c:3866
#, c-format
msgid "Internal Error: Can't hash %s: %s"
msgstr ""
-#: config/tc-m68k.c:4006
+#: config/tc-m68k.c:3948
+msgid "architecture not yet selected: defaulting to 68020"
+msgstr ""
+
+#: config/tc-m68k.c:3997
#, c-format
msgid "unrecognized default cpu `%s' ???"
msgstr ""
-#: config/tc-m68k.c:4018
+#: config/tc-m68k.c:4009
msgid "68040 and 68851 specified; mmu instructions may assemble incorrectly"
msgstr ""
-#: config/tc-m68k.c:4038
+#: config/tc-m68k.c:4029
msgid "options for 68881 and no-68881 both given"
msgstr ""
-#: config/tc-m68k.c:4040
+#: config/tc-m68k.c:4031
msgid "options for 68851 and no-68851 both given"
msgstr ""
-#: config/tc-m68k.c:4111
+#: config/tc-m68k.c:4102
#, c-format
msgid "text label `%s' aligned to odd boundary"
msgstr ""
-#: config/tc-m68k.c:4330
+#: config/tc-m68k.c:4321
msgid "invalid byte branch offset"
msgstr ""
-#: config/tc-m68k.c:4367
+#: config/tc-m68k.c:4358
msgid "short branch with zero offset: use :w"
msgstr ""
-#: config/tc-m68k.c:4836 config/tc-m68k.c:4847
+#: config/tc-m68k.c:4827 config/tc-m68k.c:4838
msgid "expression out of range: defaulting to 1"
msgstr ""
-#: config/tc-m68k.c:4879
+#: config/tc-m68k.c:4870
msgid "expression out of range: defaulting to 0"
msgstr ""
-#: config/tc-m68k.c:4912 config/tc-m68k.c:4924
+#: config/tc-m68k.c:4903 config/tc-m68k.c:4915
#, c-format
msgid "Can't deal with expression; defaulting to %ld"
msgstr ""
-#: config/tc-m68k.c:4938
+#: config/tc-m68k.c:4929
msgid "expression doesn't fit in BYTE"
msgstr ""
-#: config/tc-m68k.c:4942
+#: config/tc-m68k.c:4933
msgid "expression doesn't fit in WORD"
msgstr ""
-#: config/tc-m68k.c:5035
+#: config/tc-m68k.c:5026
#, c-format
msgid "%s: unrecognized processor name"
msgstr ""
-#: config/tc-m68k.c:5100
+#: config/tc-m68k.c:5091
msgid "bad coprocessor id"
msgstr ""
-#: config/tc-m68k.c:5106
+#: config/tc-m68k.c:5097
msgid "unrecognized fopt option"
msgstr ""
-#: config/tc-m68k.c:5240
+#: config/tc-m68k.c:5231
#, c-format
msgid "option `%s' may not be negated"
msgstr ""
-#: config/tc-m68k.c:5251
+#: config/tc-m68k.c:5242
#, c-format
msgid "option `%s' not recognized"
msgstr ""
-#: config/tc-m68k.c:5284
+#: config/tc-m68k.c:5275
msgid "bad format of OPT NEST=depth"
msgstr ""
-#: config/tc-m68k.c:5347
+#: config/tc-m68k.c:5338
msgid "missing label"
msgstr ""
-#: config/tc-m68k.c:5371 config/tc-m68k.c:5400
+#: config/tc-m68k.c:5362 config/tc-m68k.c:5391
msgid "bad register list"
msgstr ""
-#: config/tc-m68k.c:5373
+#: config/tc-m68k.c:5364
#, c-format
msgid "bad register list: %s"
msgstr ""
-#: config/tc-m68k.c:5471
+#: config/tc-m68k.c:5462
msgid "restore without save"
msgstr ""
-#: config/tc-m68k.c:5645 config/tc-m68k.c:6032
+#: config/tc-m68k.c:5636 config/tc-m68k.c:6023
msgid "syntax error in structured control directive"
msgstr ""
-#: config/tc-m68k.c:5694
+#: config/tc-m68k.c:5685
msgid "missing condition code in structured control directive"
msgstr ""
-#: config/tc-m68k.c:5766
+#: config/tc-m68k.c:5757
#, c-format
msgid ""
"Condition <%c%c> in structured control directive can not be encoded correctly"
msgstr ""
-#: config/tc-m68k.c:6075
+#: config/tc-m68k.c:6066
msgid "missing then"
msgstr ""
-#: config/tc-m68k.c:6157
+#: config/tc-m68k.c:6148
msgid "else without matching if"
msgstr ""
-#: config/tc-m68k.c:6191
+#: config/tc-m68k.c:6182
msgid "endi without matching if"
msgstr ""
-#: config/tc-m68k.c:6232
+#: config/tc-m68k.c:6223
msgid "break outside of structured loop"
msgstr ""
-#: config/tc-m68k.c:6271
+#: config/tc-m68k.c:6262
msgid "next outside of structured loop"
msgstr ""
-#: config/tc-m68k.c:6323
+#: config/tc-m68k.c:6314
msgid "missing ="
msgstr ""
-#: config/tc-m68k.c:6361
+#: config/tc-m68k.c:6352
msgid "missing to or downto"
msgstr ""
-#: config/tc-m68k.c:6397 config/tc-m68k.c:6431 config/tc-m68k.c:6650
+#: config/tc-m68k.c:6388 config/tc-m68k.c:6422 config/tc-m68k.c:6641
msgid "missing do"
msgstr ""
-#: config/tc-m68k.c:6534
+#: config/tc-m68k.c:6525
msgid "endf without for"
msgstr ""
-#: config/tc-m68k.c:6590
+#: config/tc-m68k.c:6581
msgid "until without repeat"
msgstr ""
-#: config/tc-m68k.c:6686
+#: config/tc-m68k.c:6677
msgid "endw without while"
msgstr ""
-#: config/tc-m68k.c:6810
+#: config/tc-m68k.c:6801
#, c-format
msgid "unrecognized option `%s'"
msgstr ""
-#: config/tc-m68k.c:6855
+#: config/tc-m68k.c:6846
#, c-format
msgid "unrecognized architecture specification `%s'"
msgstr ""
-#: config/tc-m68k.c:6948
+#: config/tc-m68k.c:6940
#, c-format
msgid ""
"680X0 options:\n"
@@ -5630,7 +5871,7 @@ msgid ""
"\t\t\t[default yes for 68020, 68030, and cpu32]\n"
msgstr ""
-#: config/tc-m68k.c:6959
+#: config/tc-m68k.c:6951
msgid ""
"-m68851 | -mno-68851\n"
"\t\t\ttarget has/lacks memory-management unit coprocessor\n"
@@ -5643,7 +5884,7 @@ msgid ""
"--bitwise-or\t\tdo not treat `|' as a comment character\n"
msgstr ""
-#: config/tc-m68k.c:6969
+#: config/tc-m68k.c:6961
msgid ""
"--base-size-default-16\tbase reg without size is 16 bits\n"
"--base-size-default-32\tbase reg without size is 32 bits (default)\n"
@@ -5651,12 +5892,12 @@ msgid ""
"--disp-size-default-32\tdisplacement with unknown size is 32 bits (default)\n"
msgstr ""
-#: config/tc-m68k.c:7004
+#: config/tc-m68k.c:6996
#, c-format
msgid "Error %s in %s\n"
msgstr ""
-#: config/tc-m68k.c:7008
+#: config/tc-m68k.c:7000
#, c-format
msgid "Opcode(%d.%s): "
msgstr ""
@@ -5701,15 +5942,7 @@ msgstr ""
msgid "Removed lower 2 bits of expression"
msgstr ""
-#: config/tc-m88k.c:952
-msgid "md_number_to_disp not defined"
-msgstr ""
-
-#: config/tc-m88k.c:962
-msgid "md_number_to_field not defined"
-msgstr ""
-
-#: config/tc-m88k.c:1077
+#: config/tc-m88k.c:1057
msgid "Relaxation should never occur"
msgstr ""
@@ -5717,164 +5950,164 @@ msgstr ""
msgid "m88k convert_frag\n"
msgstr ""
-#: config/tc-mcore.c:508
+#: config/tc-mcore.c:460
#, c-format
msgid "register expected, but saw '%.6s'"
msgstr ""
-#: config/tc-mcore.c:592
+#: config/tc-mcore.c:544
#, c-format
msgid "control register expected, but saw '%.6s'"
msgstr ""
-#: config/tc-mcore.c:630
+#: config/tc-mcore.c:582
msgid "bad/missing psr specifier"
msgstr ""
-#: config/tc-mcore.c:791
+#: config/tc-mcore.c:743
msgid "more than 65K literal pools"
msgstr ""
-#: config/tc-mcore.c:845
+#: config/tc-mcore.c:797
msgid "missing ']'"
msgstr ""
-#: config/tc-mcore.c:885
+#: config/tc-mcore.c:837
msgid "operand must be a constant"
msgstr ""
-#: config/tc-mcore.c:887
+#: config/tc-mcore.c:839
#, c-format
-msgid "operand must be absolute in range %d..%d, not %d"
+msgid "operand must be absolute in range %u..%u, not %ld"
msgstr ""
-#: config/tc-mcore.c:925
+#: config/tc-mcore.c:875
msgid "operand must be a multiple of 4"
msgstr ""
-#: config/tc-mcore.c:932
+#: config/tc-mcore.c:882
msgid "operand must be a multiple of 2"
msgstr ""
-#: config/tc-mcore.c:946 config/tc-mcore.c:1458 config/tc-mcore.c:1512
+#: config/tc-mcore.c:896 config/tc-mcore.c:1410 config/tc-mcore.c:1464
msgid "base register expected"
msgstr ""
-#: config/tc-mcore.c:995
+#: config/tc-mcore.c:945
#, c-format
msgid "unknown opcode \"%s\""
msgstr ""
-#: config/tc-mcore.c:1038
+#: config/tc-mcore.c:988
msgid "invalid register: r15 illegal"
msgstr ""
-#: config/tc-mcore.c:1086 config/tc-mcore.c:1662
+#: config/tc-mcore.c:1036 config/tc-mcore.c:1614
msgid "M340 specific opcode used when assembling for M210"
msgstr ""
-#: config/tc-mcore.c:1104 config/tc-mcore.c:1143 config/tc-mcore.c:1162
-#: config/tc-mcore.c:1181 config/tc-mcore.c:1208 config/tc-mcore.c:1237
-#: config/tc-mcore.c:1274 config/tc-mcore.c:1309 config/tc-mcore.c:1328
-#: config/tc-mcore.c:1347 config/tc-mcore.c:1379 config/tc-mcore.c:1404
-#: config/tc-mcore.c:1461 config/tc-mcore.c:1515 config/tc-mcore.c:1551
-#: config/tc-mcore.c:1609 config/tc-mcore.c:1631 config/tc-mcore.c:1654
+#: config/tc-mcore.c:1054 config/tc-mcore.c:1093 config/tc-mcore.c:1112
+#: config/tc-mcore.c:1131 config/tc-mcore.c:1158 config/tc-mcore.c:1187
+#: config/tc-mcore.c:1224 config/tc-mcore.c:1259 config/tc-mcore.c:1278
+#: config/tc-mcore.c:1297 config/tc-mcore.c:1331 config/tc-mcore.c:1356
+#: config/tc-mcore.c:1413 config/tc-mcore.c:1467 config/tc-mcore.c:1503
+#: config/tc-mcore.c:1561 config/tc-mcore.c:1583 config/tc-mcore.c:1606
msgid "second operand missing"
msgstr ""
-#: config/tc-mcore.c:1119
+#: config/tc-mcore.c:1069
msgid "destination register must be r1"
msgstr ""
-#: config/tc-mcore.c:1140
+#: config/tc-mcore.c:1090
msgid "source register must be r1"
msgstr ""
-#: config/tc-mcore.c:1203 config/tc-mcore.c:1260
+#: config/tc-mcore.c:1153 config/tc-mcore.c:1210
msgid "immediate is not a power of two"
msgstr ""
-#: config/tc-mcore.c:1231
+#: config/tc-mcore.c:1181
msgid "translating bgeni to movi"
msgstr ""
-#: config/tc-mcore.c:1268
+#: config/tc-mcore.c:1218
msgid "translating mgeni to movi"
msgstr ""
-#: config/tc-mcore.c:1300
+#: config/tc-mcore.c:1250
msgid "translating bmaski to movi"
msgstr ""
-#: config/tc-mcore.c:1374
+#: config/tc-mcore.c:1326
#, c-format
msgid "displacement too large (%d)"
msgstr ""
-#: config/tc-mcore.c:1388
+#: config/tc-mcore.c:1340
msgid "Invalid register: r0 and r15 illegal"
msgstr ""
-#: config/tc-mcore.c:1419
+#: config/tc-mcore.c:1371
msgid "bad starting register: r0 and r15 invalid"
msgstr ""
-#: config/tc-mcore.c:1432
+#: config/tc-mcore.c:1384
msgid "ending register must be r15"
msgstr ""
-#: config/tc-mcore.c:1452
+#: config/tc-mcore.c:1404
msgid "bad base register: must be r0"
msgstr ""
-#: config/tc-mcore.c:1470
+#: config/tc-mcore.c:1422
msgid "first register must be r4"
msgstr ""
-#: config/tc-mcore.c:1481
+#: config/tc-mcore.c:1433
msgid "last register must be r7"
msgstr ""
-#: config/tc-mcore.c:1518
+#: config/tc-mcore.c:1470
msgid "reg-reg expected"
msgstr ""
-#: config/tc-mcore.c:1628
+#: config/tc-mcore.c:1580
msgid "second operand must be 1"
msgstr ""
-#: config/tc-mcore.c:1649
+#: config/tc-mcore.c:1601
msgid "zero used as immediate value"
msgstr ""
-#: config/tc-mcore.c:1676
+#: config/tc-mcore.c:1628
msgid "duplicated psr bit specifier"
msgstr ""
-#: config/tc-mcore.c:1682
+#: config/tc-mcore.c:1634
msgid "`af' must appear alone"
msgstr ""
-#: config/tc-mcore.c:1689
+#: config/tc-mcore.c:1641
#, c-format
msgid "unimplemented opcode \"%s\""
msgstr ""
-#: config/tc-mcore.c:1698
+#: config/tc-mcore.c:1650
#, c-format
msgid "ignoring operands: %s "
msgstr ""
-#: config/tc-mcore.c:1767 config/tc-w65.c:829
+#: config/tc-mcore.c:1718 config/tc-w65.c:772
msgid "Bad call to MD_NTOF()"
msgstr ""
-#: config/tc-mcore.c:1840
+#: config/tc-mcore.c:1788
#, c-format
msgid "unrecognised cpu type '%s'"
msgstr ""
-#: config/tc-mcore.c:1859
+#: config/tc-mcore.c:1807
msgid ""
"MCORE specific options:\n"
" -{no-}jsri2bsr\t {dis}able jsri to bsr transformation (def: dis)\n"
@@ -5884,794 +6117,787 @@ msgid ""
" -EL assemble for a little endian system\n"
msgstr ""
-#: config/tc-mcore.c:1878
+#: config/tc-mcore.c:1826
msgid "failed sanity check: short_jump"
msgstr ""
-#: config/tc-mcore.c:1889
+#: config/tc-mcore.c:1837
msgid "failed sanity check: long_jump"
msgstr ""
-#: config/tc-mcore.c:1915
+#: config/tc-mcore.c:1863
#, c-format
msgid "odd displacement at %x"
msgstr ""
-#: config/tc-mcore.c:2099
+#: config/tc-mcore.c:2047
msgid "unknown"
msgstr ""
-#: config/tc-mcore.c:2130
+#: config/tc-mcore.c:2073
#, c-format
-msgid "odd distance branch (0x%x bytes)"
+msgid "odd distance branch (0x%lx bytes)"
msgstr ""
-#: config/tc-mcore.c:2134
+#: config/tc-mcore.c:2077
#, c-format
-msgid "pcrel for branch to %s too far (0x%x)"
+msgid "pcrel for branch to %s too far (0x%lx)"
msgstr ""
-#: config/tc-mcore.c:2153
+#: config/tc-mcore.c:2096
#, c-format
-msgid "pcrel for lrw/jmpi/jsri to %s too far (0x%x)"
+msgid "pcrel for lrw/jmpi/jsri to %s too far (0x%lx)"
msgstr ""
-#: config/tc-mcore.c:2164
+#: config/tc-mcore.c:2107
#, c-format
-msgid "pcrel for loopt too far (0x%x)"
+msgid "pcrel for loopt too far (0x%lx)"
msgstr ""
-#: config/tc-mcore.c:2394
+#: config/tc-mcore.c:2336
#, c-format
msgid "Can not do %d byte %srelocation"
msgstr ""
-#: config/tc-mcore.c:2396
+#: config/tc-mcore.c:2338
msgid "pc-relative"
msgstr ""
-#: config/tc-mips.c:701
+#. Prototypes for static functions.
+#: config/tc-mips.c:818
#, c-format
msgid "internal Error, line %d, %s"
msgstr ""
-#: config/tc-mips.c:703
-msgid "MIPS internal Error"
-msgstr ""
-
-#: config/tc-mips.c:1100
+#: config/tc-mips.c:1131
#, c-format
msgid "internal: can't hash `%s': %s"
msgstr ""
-#: config/tc-mips.c:1108
+#: config/tc-mips.c:1139
#, c-format
msgid "internal error: bad mips16 opcode: %s %s\n"
msgstr ""
-#: config/tc-mips.c:1289
+#: config/tc-mips.c:1332
#, c-format
msgid "returned from mips_ip(%s) insn_opcode = 0x%x\n"
msgstr ""
-#: config/tc-mips.c:1844 config/tc-mips.c:13185
+#: config/tc-mips.c:1976 config/tc-mips.c:13666
msgid "extended instruction in delay slot"
msgstr ""
-#: config/tc-mips.c:1888 config/tc-mips.c:1899
+#: config/tc-mips.c:2022 config/tc-mips.c:2032
#, c-format
msgid "jump to misaligned address (0x%lx)"
msgstr ""
-#: config/tc-mips.c:1892 config/tc-mips.c:1903
+#: config/tc-mips.c:2025 config/tc-mips.c:2035
#, c-format
msgid "jump address range overflow (0x%lx)"
msgstr ""
-#: config/tc-mips.c:2707 config/tc-mips.c:3108
+#: config/tc-mips.c:2805 config/tc-mips.c:3194
msgid "Macro instruction expanded into multiple instructions"
msgstr ""
-#: config/tc-mips.c:2719
+#: config/tc-mips.c:2817
msgid ""
"Macro instruction expanded into multiple instructions in a branch delay slot"
msgstr ""
-#: config/tc-mips.c:3143 config/tc-mips.c:7198 config/tc-mips.c:7227
-#: config/tc-mips.c:7297 config/tc-mips.c:7323
+#: config/tc-mips.c:3225 config/tc-mips.c:7549 config/tc-mips.c:7575
+#: config/tc-mips.c:7653 config/tc-mips.c:7678
msgid "operand overflow"
msgstr ""
-#: config/tc-mips.c:3170 config/tc-mips.c:6562 config/tc-mips.c:7404
+#: config/tc-mips.c:3251 config/tc-mips.c:6902 config/tc-mips.c:7754
msgid "Macro used $at after \".set noat\""
msgstr ""
-#: config/tc-mips.c:3207
+#: config/tc-mips.c:3281
msgid "unsupported large constant"
msgstr ""
-#: config/tc-mips.c:3209
+#: config/tc-mips.c:3283
#, c-format
msgid "Instruction %s requires absolute expression"
msgstr ""
-#: config/tc-mips.c:3353
+#: config/tc-mips.c:3422
#, c-format
msgid "Number (0x%lx) larger than 32 bits"
msgstr ""
-#: config/tc-mips.c:3375
+#: config/tc-mips.c:3444
msgid "Number larger than 64 bits"
msgstr ""
-#: config/tc-mips.c:3692 config/tc-mips.c:3770 config/tc-mips.c:5706
-#: config/tc-mips.c:5757 config/tc-mips.c:6305 config/tc-mips.c:6364
+#: config/tc-mips.c:3747 config/tc-mips.c:3787 config/tc-mips.c:3829
+#: config/tc-mips.c:3886 config/tc-mips.c:6069 config/tc-mips.c:6111
+#: config/tc-mips.c:6163 config/tc-mips.c:6661 config/tc-mips.c:6716
msgid "PIC code offset overflow (max 16 signed bits)"
msgstr ""
-#: config/tc-mips.c:4018
+#: config/tc-mips.c:4146
#, c-format
msgid "Branch %s is always false (nop)"
msgstr ""
-#: config/tc-mips.c:4026
+#: config/tc-mips.c:4153
#, c-format
msgid "Branch likely %s is always false"
msgstr ""
-#: config/tc-mips.c:4034 config/tc-mips.c:4103 config/tc-mips.c:4198
-#: config/tc-mips.c:4248 config/tc-mips.c:7513 config/tc-mips.c:7521
-#: config/tc-mips.c:7529 config/tc-mips.c:7638
+#: config/tc-mips.c:4160 config/tc-mips.c:4228 config/tc-mips.c:4320
+#: config/tc-mips.c:4369 config/tc-mips.c:7857 config/tc-mips.c:7865
+#: config/tc-mips.c:7872 config/tc-mips.c:7979
msgid "Unsupported large constant"
msgstr ""
#. result is always true
-#: config/tc-mips.c:4068
+#: config/tc-mips.c:4194
#, c-format
msgid "Branch %s is always true"
msgstr ""
-#: config/tc-mips.c:4320 config/tc-mips.c:4432
+#: config/tc-mips.c:4437 config/tc-mips.c:4540
msgid "Divide by zero."
msgstr ""
-#: config/tc-mips.c:4521
+#: config/tc-mips.c:4622
msgid "dla used to load 32-bit register"
msgstr ""
-#: config/tc-mips.c:4524
+#: config/tc-mips.c:4625
msgid "la used to load 64-bit address"
msgstr ""
-#: config/tc-mips.c:5115
+#: config/tc-mips.c:5000 config/tc-mips.c:5353
+msgid "PIC code offset overflow (max 32 signed bits)"
+msgstr ""
+
+#: config/tc-mips.c:5419
msgid "MIPS PIC call to register other than $25"
msgstr ""
-#: config/tc-mips.c:5122 config/tc-mips.c:5133 config/tc-mips.c:5251
-#: config/tc-mips.c:5262
+#: config/tc-mips.c:5425 config/tc-mips.c:5436 config/tc-mips.c:5574
+#: config/tc-mips.c:5585
msgid "No .cprestore pseudo-op used in PIC code"
msgstr ""
-#: config/tc-mips.c:5127 config/tc-mips.c:5256
+#: config/tc-mips.c:5430 config/tc-mips.c:5579
msgid "No .frame pseudo-op used in PIC code"
msgstr ""
-#: config/tc-mips.c:5334 config/tc-mips.c:5423 config/tc-mips.c:6054
-#: config/tc-mips.c:6095 config/tc-mips.c:6113 config/tc-mips.c:6846
+#: config/tc-mips.c:5657 config/tc-mips.c:5746 config/tc-mips.c:6414
+#: config/tc-mips.c:6453 config/tc-mips.c:6471 config/tc-mips.c:7221
msgid "opcode not supported on this processor"
msgstr ""
-#: config/tc-mips.c:6728 config/tc-mips.c:6755 config/tc-mips.c:6799
-#: config/tc-mips.c:6826
-msgid "rotate count too large"
+#: config/tc-mips.c:5970
+msgid "load/store address overflow (max 32 bits)"
+msgstr ""
+
+#: config/tc-mips.c:7084 config/tc-mips.c:7117 config/tc-mips.c:7167
+#: config/tc-mips.c:7199
+msgid "Improper rotate count"
msgstr ""
-#: config/tc-mips.c:6886
+#: config/tc-mips.c:7260
#, c-format
msgid "Instruction %s: result is always false"
msgstr ""
-#: config/tc-mips.c:7059
+#: config/tc-mips.c:7418
#, c-format
msgid "Instruction %s: result is always true"
msgstr ""
#. FIXME: Check if this is one of the itbl macros, since they
#. are added dynamically.
-#: config/tc-mips.c:7400
+#: config/tc-mips.c:7750
#, c-format
msgid "Macro %s not implemented yet"
msgstr ""
-#: config/tc-mips.c:7671
+#: config/tc-mips.c:8010
#, c-format
msgid "internal: bad mips opcode (mask error): %s %s"
msgstr ""
-#: config/tc-mips.c:7733
+#: config/tc-mips.c:8030 config/tc-mips.c:8361
+#, c-format
+msgid "internal: bad mips opcode (unknown extension operand type `+%c'): %s %s"
+msgstr ""
+
+#: config/tc-mips.c:8091
#, c-format
msgid "internal: bad mips opcode (unknown operand type `%c'): %s %s"
msgstr ""
-#: config/tc-mips.c:7740
+#: config/tc-mips.c:8098
#, c-format
msgid "internal: bad mips opcode (bits 0x%lx undefined): %s %s"
msgstr ""
-#: config/tc-mips.c:7854
+#: config/tc-mips.c:8212
#, c-format
msgid "opcode not supported on this processor: %s (%s)"
msgstr ""
-#: config/tc-mips.c:7934
+#: config/tc-mips.c:8293
+#, c-format
+msgid "Improper position (%lu)"
+msgstr ""
+
+#: config/tc-mips.c:8319
+#, c-format
+msgid "Improper insert size (%lu, position %lu)"
+msgstr ""
+
+#: config/tc-mips.c:8345
+#, c-format
+msgid "Improper extract size (%lu, position %lu)"
+msgstr ""
+
+#: config/tc-mips.c:8379
#, c-format
msgid "Improper shift amount (%lu)"
msgstr ""
-#: config/tc-mips.c:7960 config/tc-mips.c:9268 config/tc-mips.c:9383
+#: config/tc-mips.c:8405 config/tc-mips.c:9655 config/tc-mips.c:9770
#, c-format
msgid "Invalid value for `%s' (%lu)"
msgstr ""
-#: config/tc-mips.c:7978
+#: config/tc-mips.c:8423
#, c-format
msgid "Illegal break code (%lu)"
msgstr ""
-#: config/tc-mips.c:7992
+#: config/tc-mips.c:8437
#, c-format
msgid "Illegal lower break code (%lu)"
msgstr ""
-#: config/tc-mips.c:8005
+#: config/tc-mips.c:8450
#, c-format
msgid "Illegal 20-bit code (%lu)"
msgstr ""
-#: config/tc-mips.c:8017
+#: config/tc-mips.c:8462
#, c-format
msgid "Coproccesor code > 25 bits (%lu)"
msgstr ""
-#: config/tc-mips.c:8030
+#: config/tc-mips.c:8475
#, c-format
msgid "Illegal 19-bit code (%lu)"
msgstr ""
-#: config/tc-mips.c:8042
+#: config/tc-mips.c:8487
#, c-format
msgid "Invalid performance register (%lu)"
msgstr ""
-#: config/tc-mips.c:8079
+#: config/tc-mips.c:8525
#, c-format
msgid "Invalid register number (%d)"
msgstr ""
-#: config/tc-mips.c:8255
+#: config/tc-mips.c:8703
#, c-format
msgid "Invalid MDMX Immediate (%ld)"
msgstr ""
-#: config/tc-mips.c:8298
+#: config/tc-mips.c:8746
#, c-format
msgid "Invalid float register number (%d)"
msgstr ""
-#: config/tc-mips.c:8308
+#: config/tc-mips.c:8756
#, c-format
msgid "Float register should be even, was %d"
msgstr ""
-#: config/tc-mips.c:8347
+#: config/tc-mips.c:8795
#, c-format
msgid "Bad element selector %ld"
msgstr ""
-#: config/tc-mips.c:8354
+#: config/tc-mips.c:8802
#, c-format
msgid "Expecting ']' found '%s'"
msgstr ""
-#: config/tc-mips.c:8396
+#: config/tc-mips.c:8844
msgid "absolute expression required"
msgstr ""
-#: config/tc-mips.c:8464
+#: config/tc-mips.c:8912
#, c-format
msgid "Bad floating point constant: %s"
msgstr ""
-#: config/tc-mips.c:8592
+#: config/tc-mips.c:9040
msgid "Can't use floating point insn in this section"
msgstr ""
-#: config/tc-mips.c:8635 config/tc-mips.c:8640 config/tc-mips.c:8763
-#: config/tc-mips.c:8768
-msgid "bad composition of relocations"
+#: config/tc-mips.c:9101
+msgid "expression out of range"
msgstr ""
-#: config/tc-mips.c:8668
-msgid "16 bit expression not in range 0..65535"
-msgstr ""
-
-#: config/tc-mips.c:8705
-msgid "16 bit expression not in range -32768..32767"
-msgstr ""
-
-#: config/tc-mips.c:8787
+#: config/tc-mips.c:9141
msgid "lui expression not in range 0..65535"
msgstr ""
-#: config/tc-mips.c:8811
+#: config/tc-mips.c:9165
#, c-format
msgid "invalid condition code register $fcc%d"
msgstr ""
-#: config/tc-mips.c:8836
+#: config/tc-mips.c:9190
msgid "invalid coprocessor sub-selection value (0-7)"
msgstr ""
-#: config/tc-mips.c:8841
+#: config/tc-mips.c:9202 config/tc-mips.c:9219
+#, c-format
+msgid "bad byte vector index (%ld)"
+msgstr ""
+
+#: config/tc-mips.c:9230
#, c-format
msgid "bad char = '%c'\n"
msgstr ""
-#: config/tc-mips.c:8852 config/tc-mips.c:8857 config/tc-mips.c:9408
+#: config/tc-mips.c:9241 config/tc-mips.c:9246 config/tc-mips.c:9795
msgid "illegal operands"
msgstr ""
-#: config/tc-mips.c:8924
+#: config/tc-mips.c:9311
msgid "unrecognized opcode"
msgstr ""
-#: config/tc-mips.c:9036
+#: config/tc-mips.c:9423
#, c-format
msgid "invalid register number (%d)"
msgstr ""
-#: config/tc-mips.c:9127
+#: config/tc-mips.c:9514
msgid "used $at without \".set noat\""
msgstr ""
-#: config/tc-mips.c:9302
+#: config/tc-mips.c:9689
msgid "can't parse register list"
msgstr ""
-#: config/tc-mips.c:9534
+#: config/tc-mips.c:9913
msgid "extended operand requested but not required"
msgstr ""
-#: config/tc-mips.c:9536
+#: config/tc-mips.c:9915
msgid "invalid unextended operand value"
msgstr ""
-#: config/tc-mips.c:9564
+#: config/tc-mips.c:9943
msgid "operand value out of range for instruction"
msgstr ""
-#: config/tc-mips.c:9796
-msgid "internal error"
-msgstr ""
-
-#: config/tc-mips.c:10129
-#, c-format
-msgid "invalid architecture -mtune=%s"
-msgstr ""
-
-#: config/tc-mips.c:10132
-#, c-format
-msgid "invalid architecture -march=%s"
-msgstr ""
-
-#: config/tc-mips.c:10135
-#, c-format
-msgid "invalid architecture -mcpu=%s"
-msgstr ""
-
-#: config/tc-mips.c:10147
-#, c-format
-msgid "A different -mtune= was already specified, is now -mtune=%s"
-msgstr ""
-
-#: config/tc-mips.c:10153
+#: config/tc-mips.c:10341
#, c-format
-msgid "A different -march= was already specified, is now -march=%s"
-msgstr ""
-
-#: config/tc-mips.c:10159
-#, c-format
-msgid "A different -mcpu= was already specified, is now -mcpu=%s"
-msgstr ""
-
-#: config/tc-mips.c:10169
-msgid "A different -march= or -mtune= was already specified, is now -m4650"
-msgstr ""
-
-#: config/tc-mips.c:10181
-msgid "A different -march= or -mtune= was already specified, is now -m4010"
-msgstr ""
-
-#: config/tc-mips.c:10193
-msgid "A different -march= or -mtune= was already specified, is now -m4100"
+msgid "A different %s was already specified, is now %s"
msgstr ""
-#: config/tc-mips.c:10205
-msgid "A different -march= or -mtune= was already specified, is now -m3900"
-msgstr ""
-
-#: config/tc-mips.c:10244
+#: config/tc-mips.c:10502
msgid "-G may not be used with embedded PIC code"
msgstr ""
-#: config/tc-mips.c:10257
+#: config/tc-mips.c:10531
msgid "-call_shared is supported only for ELF format"
msgstr ""
-#: config/tc-mips.c:10263 config/tc-mips.c:11708 config/tc-mips.c:11918
+#: config/tc-mips.c:10538 config/tc-mips.c:11849 config/tc-mips.c:12087
msgid "-G may not be used with SVR4 PIC code"
msgstr ""
-#: config/tc-mips.c:10272
+#: config/tc-mips.c:10547
msgid "-non_shared is supported only for ELF format"
msgstr ""
-#: config/tc-mips.c:10289
+#: config/tc-mips.c:10565
msgid "-G is not supported for this configuration"
msgstr ""
-#: config/tc-mips.c:10294
+#: config/tc-mips.c:10570
msgid "-G may not be used with SVR4 or embedded PIC code"
msgstr ""
-#: config/tc-mips.c:10308
+#: config/tc-mips.c:10584
msgid "-32 is supported for ELF format only"
msgstr ""
-#: config/tc-mips.c:10317
+#: config/tc-mips.c:10593
msgid "-n32 is supported for ELF format only"
msgstr ""
-#: config/tc-mips.c:10326
+#: config/tc-mips.c:10602
msgid "-64 is supported for ELF format only"
msgstr ""
-#: config/tc-mips.c:10331 config/tc-mips.c:10370
+#: config/tc-mips.c:10607 config/tc-mips.c:10644
msgid "No compiled in support for 64 bit object file format"
msgstr ""
-#: config/tc-mips.c:10357
+#: config/tc-mips.c:10631
msgid "-mabi is supported for ELF format only"
msgstr ""
-#: config/tc-mips.c:10377
+#: config/tc-mips.c:10651
#, c-format
msgid "invalid abi -mabi=%s"
msgstr ""
-#: config/tc-mips.c:10444
-msgid ""
-"MIPS options:\n"
-"-membedded-pic\t\tgenerate embedded position independent code\n"
-"-EB\t\t\tgenerate big endian output\n"
-"-EL\t\t\tgenerate little endian output\n"
-"-g, -g2\t\t\tdo not remove unneeded NOPs or swap branches\n"
-"-G NUM\t\t\tallow referencing objects up to NUM bytes\n"
-"\t\t\timplicitly with the gp register [default 8]\n"
-msgstr ""
-
-#: config/tc-mips.c:10452
-msgid ""
-"-mips1\t\t\tgenerate MIPS ISA I instructions\n"
-"-mips2\t\t\tgenerate MIPS ISA II instructions\n"
-"-mips3\t\t\tgenerate MIPS ISA III instructions\n"
-"-mips4\t\t\tgenerate MIPS ISA IV instructions\n"
-"-mips5 generate MIPS ISA V instructions\n"
-"-mips32 generate MIPS32 ISA instructions\n"
-"-mips64 generate MIPS64 ISA instructions\n"
-"-march=CPU/-mtune=CPU\tgenerate code/schedule for CPU, where CPU is one of:\n"
-msgstr ""
-
-#: config/tc-mips.c:10488
-msgid ""
-"-mCPU\t\t\tequivalent to -march=CPU -mtune=CPU. Deprecated.\n"
-"-no-mCPU\t\tdon't generate code specific to CPU.\n"
-"\t\t\tFor -mCPU and -no-mCPU, CPU must be one of:\n"
-msgstr ""
-
-#: config/tc-mips.c:10501
-msgid ""
-"-mips16\t\t\tgenerate mips16 instructions\n"
-"-no-mips16\t\tdo not generate mips16 instructions\n"
+#: config/tc-mips.c:10718
+msgid "-G not supported in this configuration."
msgstr ""
-#: config/tc-mips.c:10504
-msgid ""
-"-mgp32\t\t\tuse 32-bit GPRs, regardless of the chosen ISA\n"
-"-mfp32\t\t\tuse 32-bit FPRs, regardless of the chosen ISA\n"
-"-O0\t\t\tremove unneeded NOPs, do not swap branches\n"
-"-O\t\t\tremove unneeded NOPs and swap branches\n"
-"-n\t\t\twarn about NOPs generated from macros\n"
-"--[no-]construct-floats [dis]allow floating point values to be constructed\n"
-"--trap, --no-break\ttrap exception on div by 0 and mult overflow\n"
-"--break, --no-trap\tbreak exception on div by 0 and mult overflow\n"
+#: config/tc-mips.c:10744
+#, c-format
+msgid "-%s conflicts with the other architecture options, which imply -%s"
msgstr ""
-#: config/tc-mips.c:10514
-msgid ""
-"-KPIC, -call_shared\tgenerate SVR4 position independent code\n"
-"-non_shared\t\tdo not generate position independent code\n"
-"-xgot\t\t\tassume a 32 bit GOT\n"
-"-mabi=ABI\t\tcreate ABI conformant object file for:\n"
+#: config/tc-mips.c:10775
+msgid "-mgp64 used with a 32-bit processor"
msgstr ""
-#: config/tc-mips.c:10530
-msgid ""
-"-32\t\t\tcreate o32 ABI object file (default)\n"
-"-n32\t\t\tcreate n32 ABI object file\n"
-"-64\t\t\tcreate 64 ABI object file\n"
+#: config/tc-mips.c:10777
+msgid "-mgp32 used with a 64-bit ABI"
msgstr ""
-#: config/tc-mips.c:10550
-msgid "-G not supported in this configuration."
-msgstr ""
-
-#: config/tc-mips.c:10569
-msgid ""
-"The -mcpu option can't be used together with -march. Use -mtune instead of -"
-"mcpu."
+#: config/tc-mips.c:10779
+msgid "-mgp64 used with a 32-bit ABI"
msgstr ""
-#: config/tc-mips.c:10577
-msgid ""
-"The -mcpu option can't be used together with -mtune. Use -march instead of -"
-"mcpu."
+#: config/tc-mips.c:10809
+msgid "trap exception not supported at ISA 1"
msgstr ""
-#: config/tc-mips.c:10626 config/tc-mips.c:10651
-msgid "The -mcpu option is deprecated. Please use -march and -mtune instead."
+#: config/tc-mips.c:10957
+#, c-format
+msgid "Unmatched %%hi reloc"
msgstr ""
-#. This really should be an error instead of a warning, but old
-#. compilers only have -mcpu which sets both arch and tune. For
-#. now, we discard arch and preserve tune.
-#: config/tc-mips.c:10671
-msgid "The -march option is incompatible to -mipsN and therefore ignored."
+#: config/tc-mips.c:11049
+msgid "Cannot branch to undefined symbol."
msgstr ""
-#: config/tc-mips.c:10723
-msgid "trap exception not supported at ISA 1"
+#: config/tc-mips.c:11056
+msgid "Cannot branch to symbol in another section."
msgstr ""
-#: config/tc-mips.c:10891
-#, c-format
-msgid "Unmatched %%hi reloc"
+#: config/tc-mips.c:11065
+msgid "Pretending global symbol used as branch target is local."
msgstr ""
-#: config/tc-mips.c:11111
+#: config/tc-mips.c:11230
msgid "Invalid PC relative reloc"
msgstr ""
-#: config/tc-mips.c:11219 config/tc-sparc.c:3113 config/tc-sparc.c:3120
-#: config/tc-sparc.c:3127 config/tc-sparc.c:3134 config/tc-sparc.c:3141
-#: config/tc-sparc.c:3150 config/tc-sparc.c:3161 config/tc-sparc.c:3183
-#: config/tc-sparc.c:3207 write.c:1038 write.c:1101
+#: config/tc-mips.c:11325 config/tc-sparc.c:3185 config/tc-sparc.c:3192
+#: config/tc-sparc.c:3199 config/tc-sparc.c:3206 config/tc-sparc.c:3213
+#: config/tc-sparc.c:3222 config/tc-sparc.c:3233 config/tc-sparc.c:3255
+#: config/tc-sparc.c:3279 write.c:998 write.c:1070
msgid "relocation overflow"
msgstr ""
-#: config/tc-mips.c:11230
+#: config/tc-mips.c:11335
#, c-format
msgid "Branch to odd address (%lx)"
msgstr ""
-#: config/tc-mips.c:11295
+#: config/tc-mips.c:11384
msgid "Branch out of range"
msgstr ""
-#: config/tc-mips.c:11403
+#: config/tc-mips.c:11491
#, c-format
msgid "%08lx UNDEFINED\n"
msgstr ""
-#: config/tc-mips.c:11466
+#: config/tc-mips.c:11550
#, c-format
msgid "Alignment too large: %d. assumed."
msgstr ""
-#: config/tc-mips.c:11469
+#: config/tc-mips.c:11553
msgid "Alignment negative: 0 assumed."
msgstr ""
-#: config/tc-mips.c:11557
+#: config/tc-mips.c:11640
msgid "No read only data section in this object file format"
msgstr ""
-#: config/tc-mips.c:11580
+#: config/tc-mips.c:11663
msgid "Global pointers not supported; recompile -G 0"
msgstr ""
-#: config/tc-mips.c:11666
+#: config/tc-mips.c:11805
#, c-format
msgid "%s: no such section"
msgstr ""
-#: config/tc-mips.c:11703
+#: config/tc-mips.c:11844
#, c-format
msgid ".option pic%d not supported"
msgstr ""
-#: config/tc-mips.c:11714
+#: config/tc-mips.c:11855
#, c-format
msgid "Unrecognized option \"%s\""
msgstr ""
-#: config/tc-mips.c:11777
+#: config/tc-mips.c:11917
msgid "`noreorder' must be set before `nomacro'"
msgstr ""
-#: config/tc-mips.c:11841 config/tc-mips.c:11855
+#: config/tc-mips.c:11989
+#, c-format
+msgid "unknown architecture %s"
+msgstr ""
+
+#: config/tc-mips.c:11997 config/tc-mips.c:12018
#, c-format
msgid "unknown ISA level %s"
msgstr ""
-#: config/tc-mips.c:11877
+#: config/tc-mips.c:12046
msgid ".set pop with no .set push"
msgstr ""
-#: config/tc-mips.c:11901
+#: config/tc-mips.c:12070
#, c-format
msgid "Tried to set unrecognized symbol: %s\n"
msgstr ""
-#: config/tc-mips.c:11952
+#: config/tc-mips.c:12120
msgid ".cpload not in noreorder section"
msgstr ""
-#: config/tc-mips.c:12009 config/tc-mips.c:12028
+#: config/tc-mips.c:12176 config/tc-mips.c:12195
msgid "missing argument separator ',' for .cpsetup"
msgstr ""
-#: config/tc-mips.c:12213
+#: config/tc-mips.c:12373
msgid "Unsupported use of .gpword"
msgstr ""
-#: config/tc-mips.c:12348
+#: config/tc-mips.c:12409
+msgid "Unsupported use of .gpdword"
+msgstr ""
+
+#: config/tc-mips.c:12544
msgid "expected `$'"
msgstr ""
-#: config/tc-mips.c:12356
+#: config/tc-mips.c:12552
msgid "Bad register number"
msgstr ""
-#: config/tc-mips.c:12404
+#: config/tc-mips.c:12600
msgid "Unrecognized register name"
msgstr ""
-#: config/tc-mips.c:12590
+#: config/tc-mips.c:12835
msgid "unsupported PC relative reference to different section"
msgstr ""
-#: config/tc-mips.c:12703
+#: config/tc-mips.c:12948
msgid "unsupported relocation"
msgstr ""
-#: config/tc-mips.c:12799
+#: config/tc-mips.c:13063
msgid "AT used after \".set noat\" or macro used after \".set nomacro\""
msgstr ""
-#: config/tc-mips.c:12869
+#: config/tc-mips.c:13126
msgid "Double check fx_r_type in tc-mips.c:tc_gen_reloc"
msgstr ""
-#: config/tc-mips.c:13072 config/tc-sh.c:3799
+#: config/tc-mips.c:13341 config/tc-sh.c:3800
#, c-format
msgid "Can not represent %s relocation in this object file format"
msgstr ""
-#: config/tc-mips.c:13423
+#: config/tc-mips.c:13430
+msgid "relaxed out-of-range branch into a jump"
+msgstr ""
+
+#: config/tc-mips.c:13903
msgid "missing .end at end of assembly"
msgstr ""
-#: config/tc-mips.c:13438
+#: config/tc-mips.c:13918
msgid "expected simple number"
msgstr ""
-#: config/tc-mips.c:13464
+#: config/tc-mips.c:13944
#, c-format
msgid " *input_line_pointer == '%c' 0x%02x\n"
msgstr ""
-#: config/tc-mips.c:13466
+#: config/tc-mips.c:13946
msgid "invalid number"
msgstr ""
-#: config/tc-mips.c:13555
+#: config/tc-mips.c:14019
msgid ".end not in text section"
msgstr ""
-#: config/tc-mips.c:13559
+#: config/tc-mips.c:14023
msgid ".end directive without a preceding .ent directive."
msgstr ""
-#: config/tc-mips.c:13568
+#: config/tc-mips.c:14032
msgid ".end symbol does not match .ent symbol."
msgstr ""
-#: config/tc-mips.c:13575
+#: config/tc-mips.c:14039
msgid ".end directive missing or unknown symbol"
msgstr ""
-#: config/tc-mips.c:13649
+#: config/tc-mips.c:14099
msgid ".ent or .aent not in text section."
msgstr ""
-#: config/tc-mips.c:13652
+#: config/tc-mips.c:14102
msgid "missing .end"
msgstr ""
-#: config/tc-mips.c:13694 ecoff.c:3200
-msgid ".frame outside of .ent"
-msgstr ""
-
-#: config/tc-mips.c:13705
+#: config/tc-mips.c:14154
msgid "Bad .frame directive"
msgstr ""
-#: config/tc-mips.c:13738
+#: config/tc-mips.c:14186
msgid ".mask/.fmask outside of .ent"
msgstr ""
-#: config/tc-mips.c:13745
+#: config/tc-mips.c:14193
msgid "Bad .mask/.fmask directive"
msgstr ""
-#: config/tc-mmix.c:681
+#: config/tc-mips.c:14472
+msgid ""
+"MIPS options:\n"
+"-membedded-pic\t\tgenerate embedded position independent code\n"
+"-EB\t\t\tgenerate big endian output\n"
+"-EL\t\t\tgenerate little endian output\n"
+"-g, -g2\t\t\tdo not remove unneeded NOPs or swap branches\n"
+"-G NUM\t\t\tallow referencing objects up to NUM bytes\n"
+"\t\t\timplicitly with the gp register [default 8]\n"
+msgstr ""
+
+#: config/tc-mips.c:14480
+msgid ""
+"-mips1\t\t\tgenerate MIPS ISA I instructions\n"
+"-mips2\t\t\tgenerate MIPS ISA II instructions\n"
+"-mips3\t\t\tgenerate MIPS ISA III instructions\n"
+"-mips4\t\t\tgenerate MIPS ISA IV instructions\n"
+"-mips5 generate MIPS ISA V instructions\n"
+"-mips32 generate MIPS32 ISA instructions\n"
+"-mips32r2 generate MIPS32 release 2 ISA instructions\n"
+"-mips64 generate MIPS64 ISA instructions\n"
+"-march=CPU/-mtune=CPU\tgenerate code/schedule for CPU, where CPU is one of:\n"
+msgstr ""
+
+#: config/tc-mips.c:14498
+msgid ""
+"-mCPU\t\t\tequivalent to -march=CPU -mtune=CPU. Deprecated.\n"
+"-no-mCPU\t\tdon't generate code specific to CPU.\n"
+"\t\t\tFor -mCPU and -no-mCPU, CPU must be one of:\n"
+msgstr ""
+
+#: config/tc-mips.c:14511
+msgid ""
+"-mips16\t\t\tgenerate mips16 instructions\n"
+"-no-mips16\t\tdo not generate mips16 instructions\n"
+msgstr ""
+
+#: config/tc-mips.c:14514
+msgid ""
+"-mgp32\t\t\tuse 32-bit GPRs, regardless of the chosen ISA\n"
+"-mfp32\t\t\tuse 32-bit FPRs, regardless of the chosen ISA\n"
+"-O0\t\t\tremove unneeded NOPs, do not swap branches\n"
+"-O\t\t\tremove unneeded NOPs and swap branches\n"
+"-n\t\t\twarn about NOPs generated from macros\n"
+"--[no-]construct-floats [dis]allow floating point values to be constructed\n"
+"--trap, --no-break\ttrap exception on div by 0 and mult overflow\n"
+"--break, --no-trap\tbreak exception on div by 0 and mult overflow\n"
+msgstr ""
+
+#: config/tc-mips.c:14524
+msgid ""
+"-KPIC, -call_shared\tgenerate SVR4 position independent code\n"
+"-non_shared\t\tdo not generate position independent code\n"
+"-xgot\t\t\tassume a 32 bit GOT\n"
+"-mabi=ABI\t\tcreate ABI conformant object file for:\n"
+msgstr ""
+
+#: config/tc-mips.c:14540
+msgid ""
+"-32\t\t\tcreate o32 ABI object file (default)\n"
+"-n32\t\t\tcreate n32 ABI object file\n"
+"-64\t\t\tcreate 64 ABI object file\n"
+msgstr ""
+
+#: config/tc-mmix.c:677
msgid " MMIX-specific command line options:\n"
msgstr ""
-#: config/tc-mmix.c:682
+#: config/tc-mmix.c:678
msgid ""
" -fixed-special-register-names\n"
" Allow only the original special register names.\n"
msgstr ""
-#: config/tc-mmix.c:685
+#: config/tc-mmix.c:681
msgid " -globalize-symbols Make all symbols global.\n"
msgstr ""
-#: config/tc-mmix.c:687
+#: config/tc-mmix.c:683
msgid " -gnu-syntax Turn off mmixal syntax compatibility.\n"
msgstr ""
-#: config/tc-mmix.c:689
+#: config/tc-mmix.c:685
msgid " -relax Create linker relaxable code.\n"
msgstr ""
-#: config/tc-mmix.c:691
+#: config/tc-mmix.c:687
msgid ""
" -no-predefined-syms Do not provide mmixal built-in constants.\n"
" Implies -fixed-special-register-names.\n"
msgstr ""
-#: config/tc-mmix.c:694
+#: config/tc-mmix.c:690
msgid ""
" -no-expand Do not expand GETA, branches, PUSHJ or JUMP\n"
" into multiple instructions.\n"
msgstr ""
-#: config/tc-mmix.c:697
+#: config/tc-mmix.c:693
msgid ""
" -no-merge-gregs Do not merge GREG definitions with nearby values.\n"
msgstr ""
-#: config/tc-mmix.c:699
+#: config/tc-mmix.c:695
msgid ""
" -linker-allocated-gregs If there's no suitable GREG definition for "
"the operands of an instruction, let the linker "
"resolve.\n"
msgstr ""
-#: config/tc-mmix.c:702
+#: config/tc-mmix.c:698
msgid ""
" -x Do not warn when an operand to GETA, a branch,\n"
" PUSHJ or JUMP is not known to be within range.\n"
@@ -6679,75 +6905,75 @@ msgid ""
" -linker-allocated-gregs."
msgstr ""
-#: config/tc-mmix.c:829
+#: config/tc-mmix.c:825
#, c-format
msgid "unknown opcode: `%s'"
msgstr ""
-#: config/tc-mmix.c:951 config/tc-mmix.c:966
+#: config/tc-mmix.c:947 config/tc-mmix.c:962
msgid "specified location wasn't TETRA-aligned"
msgstr ""
-#: config/tc-mmix.c:953 config/tc-mmix.c:968 config/tc-mmix.c:4086
-#: config/tc-mmix.c:4102
+#: config/tc-mmix.c:949 config/tc-mmix.c:964 config/tc-mmix.c:4015
+#: config/tc-mmix.c:4031
msgid "unaligned data at an absolute location is not supported"
msgstr ""
-#: config/tc-mmix.c:1078
+#: config/tc-mmix.c:1074
#, c-format
msgid "invalid operand to opcode %s: `%s'"
msgstr ""
-#: config/tc-mmix.c:1100 config/tc-mmix.c:1127 config/tc-mmix.c:1160
-#: config/tc-mmix.c:1168 config/tc-mmix.c:1185 config/tc-mmix.c:1213
-#: config/tc-mmix.c:1234 config/tc-mmix.c:1259 config/tc-mmix.c:1307
-#: config/tc-mmix.c:1405 config/tc-mmix.c:1430 config/tc-mmix.c:1462
-#: config/tc-mmix.c:1494 config/tc-mmix.c:1524 config/tc-mmix.c:1577
-#: config/tc-mmix.c:1594 config/tc-mmix.c:1621 config/tc-mmix.c:1649
-#: config/tc-mmix.c:1676 config/tc-mmix.c:1702 config/tc-mmix.c:1718
-#: config/tc-mmix.c:1744 config/tc-mmix.c:1760 config/tc-mmix.c:1776
-#: config/tc-mmix.c:1839 config/tc-mmix.c:1855
+#: config/tc-mmix.c:1096 config/tc-mmix.c:1123 config/tc-mmix.c:1156
+#: config/tc-mmix.c:1164 config/tc-mmix.c:1181 config/tc-mmix.c:1209
+#: config/tc-mmix.c:1230 config/tc-mmix.c:1255 config/tc-mmix.c:1303
+#: config/tc-mmix.c:1401 config/tc-mmix.c:1426 config/tc-mmix.c:1458
+#: config/tc-mmix.c:1490 config/tc-mmix.c:1520 config/tc-mmix.c:1573
+#: config/tc-mmix.c:1590 config/tc-mmix.c:1617 config/tc-mmix.c:1645
+#: config/tc-mmix.c:1672 config/tc-mmix.c:1698 config/tc-mmix.c:1714
+#: config/tc-mmix.c:1740 config/tc-mmix.c:1756 config/tc-mmix.c:1772
+#: config/tc-mmix.c:1835 config/tc-mmix.c:1851
#, c-format
msgid "invalid operands to opcode %s: `%s'"
msgstr ""
-#: config/tc-mmix.c:1832
+#: config/tc-mmix.c:1828
#, c-format
msgid "unsupported operands to %s: `%s'"
msgstr ""
-#: config/tc-mmix.c:1960
+#: config/tc-mmix.c:1956
msgid "internal: mmix_prefix_name but empty prefix"
msgstr ""
-#: config/tc-mmix.c:2005
+#: config/tc-mmix.c:2001
#, c-format
msgid "too many GREG registers allocated (max %d)"
msgstr ""
-#: config/tc-mmix.c:2065
+#: config/tc-mmix.c:2061
msgid "BSPEC already active. Nesting is not supported."
msgstr ""
-#: config/tc-mmix.c:2074
+#: config/tc-mmix.c:2070
msgid "invalid BSPEC expression"
msgstr ""
-#: config/tc-mmix.c:2090
+#: config/tc-mmix.c:2086
#, c-format
msgid "can't create section %s"
msgstr ""
-#: config/tc-mmix.c:2095
+#: config/tc-mmix.c:2091
#, c-format
msgid "can't set section flags for section %s"
msgstr ""
-#: config/tc-mmix.c:2117
+#: config/tc-mmix.c:2113
msgid "ESPEC without preceding BSPEC"
msgstr ""
-#: config/tc-mmix.c:2147
+#: config/tc-mmix.c:2143
msgid "missing local expression"
msgstr ""
@@ -6757,107 +6983,107 @@ msgstr ""
#. The BFD_RELOC_MMIX_LOCAL-specific message is supposed to be
#. user-friendly, though a little bit non-substantial.
-#: config/tc-mmix.c:2621
+#: config/tc-mmix.c:2620
msgid "directive LOCAL must be placed in code or data"
msgstr ""
-#: config/tc-mmix.c:2622
+#: config/tc-mmix.c:2621
msgid "internal confusion: relocation in a section without contents"
msgstr ""
-#: config/tc-mmix.c:2735
+#: config/tc-mmix.c:2734
msgid "internal: BFD_RELOC_MMIX_BASE_PLUS_OFFSET not resolved to section"
msgstr ""
-#: config/tc-mmix.c:2783
+#: config/tc-mmix.c:2782
msgid "no suitable GREG definition for operands"
msgstr ""
-#: config/tc-mmix.c:2842
+#: config/tc-mmix.c:2841
msgid "operands were not reducible at assembly-time"
msgstr ""
-#: config/tc-mmix.c:2870
+#: config/tc-mmix.c:2868
#, c-format
msgid "cannot generate relocation type for symbol %s, code %s"
msgstr ""
-#: config/tc-mmix.c:2890
+#: config/tc-mmix.c:2888
#, c-format
msgid "internal: unhandled label %s"
msgstr ""
-#: config/tc-mmix.c:2944
+#: config/tc-mmix.c:2942
msgid "[0-9]H labels may not appear alone on a line"
msgstr ""
-#: config/tc-mmix.c:2953
+#: config/tc-mmix.c:2951
msgid "[0-9]H labels do not mix with dot-pseudos"
msgstr ""
-#: config/tc-mmix.c:3017
+#: config/tc-mmix.c:3015
msgid "invalid characters in input"
msgstr ""
-#: config/tc-mmix.c:3121
+#: config/tc-mmix.c:3119
msgid "empty label field for IS"
msgstr ""
-#: config/tc-mmix.c:3371
+#: config/tc-mmix.c:3344
#, c-format
msgid "internal: unexpected relax type %d:%d"
msgstr ""
-#: config/tc-mmix.c:3393
+#: config/tc-mmix.c:3366
msgid "BSPEC without ESPEC."
msgstr ""
-#: config/tc-mmix.c:3595
+#: config/tc-mmix.c:3568
msgid "GREG expression too complicated"
msgstr ""
-#: config/tc-mmix.c:3610
+#: config/tc-mmix.c:3583
msgid "internal: GREG expression not resolved to section"
msgstr ""
-#: config/tc-mmix.c:3661
+#: config/tc-mmix.c:3634
msgid "register section has contents\n"
msgstr ""
-#: config/tc-mmix.c:3839
+#: config/tc-mmix.c:3768
msgid "section change from within a BSPEC/ESPEC pair is not supported"
msgstr ""
-#: config/tc-mmix.c:3861
+#: config/tc-mmix.c:3790
msgid "directive LOC from within a BSPEC/ESPEC pair is not supported"
msgstr ""
-#: config/tc-mmix.c:3872
+#: config/tc-mmix.c:3801
msgid "invalid LOC expression"
msgstr ""
-#: config/tc-mmix.c:3897 config/tc-mmix.c:3923
+#: config/tc-mmix.c:3826 config/tc-mmix.c:3852
msgid "LOC expression stepping backwards is not supported"
msgstr ""
#. We will only get here in rare cases involving #NO_APP,
#. where the unterminated string is not recognized by the
#. preformatting pass.
-#: config/tc-mmix.c:4007 config/tc-mmix.c:4168
+#: config/tc-mmix.c:3936 config/tc-mmix.c:4097
msgid "unterminated string"
msgstr ""
-#: config/tc-mmix.c:4024
+#: config/tc-mmix.c:3953
msgid "BYTE expression not a pure number"
msgstr ""
#. Note that mmixal does not allow negative numbers in
#. BYTE sequences, so neither should we.
-#: config/tc-mmix.c:4033
+#: config/tc-mmix.c:3962
msgid "BYTE expression not in the range 0..255"
msgstr ""
-#: config/tc-mmix.c:4084 config/tc-mmix.c:4100
+#: config/tc-mmix.c:4013 config/tc-mmix.c:4029
msgid "data item with alignment larger than location"
msgstr ""
@@ -6873,248 +7099,414 @@ msgid ""
"none yet\n"
msgstr ""
-#: config/tc-mn10200.c:793 config/tc-mn10300.c:936 config/tc-ppc.c:1896
-#: config/tc-s390.c:1299 config/tc-v850.c:1636
+#: config/tc-mn10200.c:793 config/tc-mn10300.c:1387 config/tc-ppc.c:2088
+#: config/tc-s390.c:1540 config/tc-v850.c:1677
#, c-format
msgid "Unrecognized opcode: `%s'"
msgstr ""
-#: config/tc-mn10200.c:1036 config/tc-mn10300.c:1459 config/tc-ppc.c:2339
-#: config/tc-s390.c:1224 config/tc-v850.c:2060
+#: config/tc-mn10200.c:1036 config/tc-mn10300.c:1960 config/tc-ppc.c:2566
+#: config/tc-s390.c:1455 config/tc-v850.c:2100
#, c-format
msgid "junk at end of line: `%s'"
msgstr ""
-#: config/tc-mn10200.c:1349 config/tc-mn10300.c:2083 config/tc-ppc.c:1303
-#: config/tc-v850.c:1565
+#: config/tc-mn10200.c:1242 write.c:2691
+#, c-format
+msgid "can't resolve `%s' {%s section} - `%s' {%s section}"
+msgstr ""
+
+#: config/tc-mn10200.c:1347 config/tc-mn10300.c:2589 config/tc-ppc.c:1426
+#: config/tc-v850.c:1606
#, c-format
msgid "operand out of range (%s not between %ld and %ld)"
msgstr ""
-#: config/tc-mn10300.c:525
+#: config/tc-mn10300.c:690
msgid ""
"MN10300 options:\n"
"none yet\n"
msgstr ""
-#: config/tc-mn10300.c:953
+#: config/tc-mn10300.c:1356 config/tc-sh.c:805 config/tc-xtensa.c:5177
+#: read.c:3764
+#, c-format
+msgid "unsupported BFD relocation size %u"
+msgstr ""
+
+#: config/tc-mn10300.c:1404
msgid "Invalid opcode/operands"
msgstr ""
-#: config/tc-mn10300.c:1430
+#: config/tc-mn10300.c:1931
msgid "Invalid register specification."
msgstr ""
-#: config/tc-mn10300.c:1983
+#: config/tc-mn10300.c:2514
#, c-format
msgid "Bad relocation fixup type (%d)"
msgstr ""
-#: config/tc-ns32k.c:446
+#: config/tc-msp430.c:170
+msgid "Known MCU names:\n"
+msgstr ""
+
+#: config/tc-msp430.c:173
+#, c-format
+msgid "\t %s\n"
+msgstr ""
+
+#: config/tc-msp430.c:183
+msgid ""
+"MSP430 options:\n"
+" -mmcu=[msp430-name] select microcontroller type\n"
+" msp430x110 msp430x112\n"
+" msp430x1101 msp430x1111\n"
+" msp430x1121 msp430x1122 msp430x1132\n"
+" msp430x122 msp430x123\n"
+" msp430x1222 msp430x1232\n"
+" msp430x133 msp430x135\n"
+" msp430x1331 msp430x1351\n"
+" msp430x147 msp430x148 msp430x149\n"
+" msp430x155 msp430x156 msp430x157\n"
+" msp430x167 msp430x168 msp430x169\n"
+" msp430x311 msp430x312 msp430x313 msp430x314 "
+"msp430x315\n"
+" msp430x323 msp430x325\n"
+" msp430x336 msp430x337\n"
+" msp430x412 msp430x413\n"
+" msp430x435 msp430x436 msp430x437\n"
+" msp430x447 msp430x448 msp430x449\n"
+msgstr ""
+
+#: config/tc-msp430.c:263
+#, c-format
+msgid "redefinition of mcu type %s' to %s'"
+msgstr ""
+
+#: config/tc-msp430.c:496
+#, c-format
+msgid "instruction %s requires %d operand(s)"
+msgstr ""
+
+#: config/tc-msp430.c:743
+#, c-format
+msgid "Even number required. Rounded to %d"
+msgstr ""
+
+#: config/tc-msp430.c:754
+#, c-format
+msgid "Wrong displacement %d"
+msgstr ""
+
+#: config/tc-msp430.c:771
+msgid "instruction requires label sans '$'"
+msgstr ""
+
+#: config/tc-msp430.c:777
+msgid "instruction requires label or value in range -511:512"
+msgstr ""
+
+#: config/tc-msp430.c:783
+msgid "instruction requires label"
+msgstr ""
+
+#: config/tc-msp430.c:789
+msgid "Ilegal instruction or not implmented opcode."
+msgstr ""
+
+#: config/tc-msp430.c:817
+#, c-format
+msgid "Internal bug. Try to use 0(r%d) instead of @r%d"
+msgstr ""
+
+#: config/tc-msp430.c:827
+msgid "this addressing mode is not applicable for destination operand"
+msgstr ""
+
+#: config/tc-msp430.c:944
+#, c-format
+msgid "value %ld out of range. Use #lo() or #hi()"
+msgstr ""
+
+#: config/tc-msp430.c:1040
+#, c-format
+msgid "unknown expression in operand %s. use #llo() #lhi() #hlo() #hhi() "
+msgstr ""
+
+#: config/tc-msp430.c:1090 config/tc-msp430.c:1304
+#, c-format
+msgid "unknown operand %s"
+msgstr ""
+
+#: config/tc-msp430.c:1111 config/tc-msp430.c:1242
+#, c-format
+msgid "value out of range: %d"
+msgstr ""
+
+#: config/tc-msp430.c:1120 config/tc-msp430.c:1259
+#, c-format
+msgid "unknown expression in operand %s"
+msgstr ""
+
+#: config/tc-msp430.c:1134 config/tc-msp430.c:1141
+#, c-format
+msgid "unknown addressing mode %s"
+msgstr ""
+
+#: config/tc-msp430.c:1149
+#, c-format
+msgid "Bad register name r%s"
+msgstr ""
+
+#: config/tc-msp430.c:1161
+#, c-format
+msgid "MSP430 does not have %d registers"
+msgstr ""
+
+#: config/tc-msp430.c:1181
+msgid "')' required"
+msgstr ""
+
+#: config/tc-msp430.c:1194
+#, c-format
+msgid "unknown operator %s. Did you mean X(Rn) or #[hl][hl][oi](CONST) ?"
+msgstr ""
+
+#: config/tc-msp430.c:1203
+#, c-format
+msgid "unknown operator (r%s substituded as a register name"
+msgstr ""
+
+#: config/tc-msp430.c:1215 config/tc-msp430.c:1226
+#, c-format
+msgid "unknown operator %s"
+msgstr ""
+
+#: config/tc-msp430.c:1220
+msgid "r2 should not be used in indexed addressing mode"
+msgstr ""
+
+#. Unreachable.
+#: config/tc-msp430.c:1321
+#, c-format
+msgid "unknown addressing mode for operand %s"
+msgstr ""
+
+#: config/tc-ns32k.c:449
msgid "Invalid syntax in PC-relative addressing mode"
msgstr ""
-#: config/tc-ns32k.c:470
+#: config/tc-ns32k.c:473
msgid "Invalid syntax in External addressing mode"
msgstr ""
-#: config/tc-ns32k.c:550
+#: config/tc-ns32k.c:554
msgid "Invalid syntax in Memory Relative addressing mode"
msgstr ""
-#: config/tc-ns32k.c:617
+#: config/tc-ns32k.c:621
msgid "Invalid scaled-indexed mode, use (b,w,d,q)"
msgstr ""
-#: config/tc-ns32k.c:622
+#: config/tc-ns32k.c:626
msgid "Syntax in scaled-indexed mode, use [Rn:m] where n=[0..7] m={b,w,d,q}"
msgstr ""
-#: config/tc-ns32k.c:627
+#: config/tc-ns32k.c:631
msgid "Scaled-indexed addressing mode combined with scaled-index"
msgstr ""
-#: config/tc-ns32k.c:638
+#: config/tc-ns32k.c:642
msgid "Invalid or illegal addressing mode combined with scaled-index"
msgstr ""
-#: config/tc-ns32k.c:750
+#: config/tc-ns32k.c:757
msgid "Premature end of suffix -- Defaulting to d"
msgstr ""
-#: config/tc-ns32k.c:763
+#: config/tc-ns32k.c:770
msgid "Bad suffix after ':' use {b|w|d} Defaulting to d"
msgstr ""
-#: config/tc-ns32k.c:809
+#: config/tc-ns32k.c:817
msgid "Very short instr to option, ie you can't do it on a NULLstr"
msgstr ""
-#: config/tc-ns32k.c:860
+#: config/tc-ns32k.c:870
msgid "No such entry in list. (cpu/mmu register)"
msgstr ""
-#: config/tc-ns32k.c:901
+#: config/tc-ns32k.c:915
msgid "Internal consistency error. check ns32k-opcode.h"
msgstr ""
-#: config/tc-ns32k.c:925
+#: config/tc-ns32k.c:939
msgid "Address of immediate operand"
msgstr ""
-#: config/tc-ns32k.c:926
+#: config/tc-ns32k.c:940
msgid "Invalid immediate write operand."
msgstr ""
-#: config/tc-ns32k.c:1056
+#: config/tc-ns32k.c:1070
msgid "Bad opcode-table-option, check in file ns32k-opcode.h"
msgstr ""
-#: config/tc-ns32k.c:1089
+#: config/tc-ns32k.c:1107
msgid "No such opcode"
msgstr ""
-#: config/tc-ns32k.c:1166
+#: config/tc-ns32k.c:1184
msgid "Bad suffix, defaulting to d"
msgstr ""
-#: config/tc-ns32k.c:1194
+#: config/tc-ns32k.c:1212
msgid "Too many operands passed to instruction"
msgstr ""
#. Check error in default.
-#: config/tc-ns32k.c:1207
+#: config/tc-ns32k.c:1225
msgid "Wrong numbers of operands in default, check ns32k-opcodes.h"
msgstr ""
-#: config/tc-ns32k.c:1211
+#: config/tc-ns32k.c:1229
msgid "Wrong number of operands"
msgstr ""
-#: config/tc-ns32k.c:1332
+#: config/tc-ns32k.c:1355
msgid "iif convert internal pcrel/binary"
msgstr ""
-#: config/tc-ns32k.c:1349
+#: config/tc-ns32k.c:1372
msgid "Bignum too big for long"
msgstr ""
-#: config/tc-ns32k.c:1427
+#: config/tc-ns32k.c:1451
msgid "iif convert internal pcrel/pointer"
msgstr ""
-#: config/tc-ns32k.c:1432
+#: config/tc-ns32k.c:1456
msgid "Internal logic error in iif.iifP[n].type"
msgstr ""
#. We cant relax this case.
-#: config/tc-ns32k.c:1470
+#: config/tc-ns32k.c:1493
msgid "Can't relax difference"
msgstr ""
-#: config/tc-ns32k.c:1518
+#: config/tc-ns32k.c:1541
msgid "Displacement to large for :d"
msgstr ""
-#: config/tc-ns32k.c:1531
+#: config/tc-ns32k.c:1554
msgid "Internal logic error in iif.iifP[].type"
msgstr ""
-#: config/tc-ns32k.c:1591
+#: config/tc-ns32k.c:1614
#, c-format
msgid "Can not do %d byte pc-relative relocation for storage type %d"
msgstr ""
-#: config/tc-ns32k.c:1594
+#: config/tc-ns32k.c:1617
#, c-format
msgid "Can not do %d byte relocation for storage type %d"
msgstr ""
#. Fatal.
-#: config/tc-ns32k.c:1626
+#: config/tc-ns32k.c:1652
#, c-format
msgid "Can't hash %s: %s"
msgstr ""
-#: config/tc-ns32k.c:1714
-msgid "Byte displacement out of range. line number not valid"
+#: config/tc-ns32k.c:1740
+#, c-format
+msgid "value of %ld out of byte displacement range."
msgstr ""
-#: config/tc-ns32k.c:1723
-msgid "Word displacement out of range. line number not valid"
+#: config/tc-ns32k.c:1749
+#, c-format
+msgid "value of %ld out of word displacement range."
msgstr ""
-#: config/tc-ns32k.c:1737
-msgid "Double word displacement out of range"
+#: config/tc-ns32k.c:1763
+#, c-format
+msgid "value of %ld out of double word displacement range."
msgstr ""
-#: config/tc-ns32k.c:1757
+#: config/tc-ns32k.c:1783
#, c-format
-msgid "Internal logic error. line %s, file \"%s\""
+msgid "Internal logic error. line %d, file \"%s\""
msgstr ""
-#: config/tc-ns32k.c:1805
+#: config/tc-ns32k.c:1831
#, c-format
-msgid "Internal logic error. line %s, file \"%s\""
+msgid "Internal logic error. line %d, file \"%s\""
msgstr ""
-#: config/tc-ns32k.c:1909
+#: config/tc-ns32k.c:1936
msgid "Bit field out of range"
msgstr ""
-#: config/tc-ns32k.c:2157
+#: config/tc-ns32k.c:2183
#, c-format
-msgid "invalid architecture option -m%s"
+msgid "invalid architecture option -m%s, ignored"
msgstr ""
-#: config/tc-ns32k.c:2173
+#: config/tc-ns32k.c:2196
+#, c-format
+msgid "invalid default displacement size \"%s\". Defaulting to %d."
+msgstr ""
+
+#: config/tc-ns32k.c:2213
msgid ""
"NS32K options:\n"
"-m32032 | -m32532\tselect variant of NS32K architecture\n"
+"--disp-size-default=<1|2|4>\n"
msgstr ""
-#: config/tc-ns32k.c:2351
+#: config/tc-ns32k.c:2397
#, c-format
msgid "Cannot find relocation type for symbol %s, code %d"
msgstr ""
-#: config/tc-or32.c:467 config/tc-or32.c:682
+#: config/tc-or32.c:465 config/tc-or32.c:680
#, c-format
msgid "unknown opcode1: `%s'"
msgstr ""
-#: config/tc-or32.c:473 config/tc-or32.c:688
+#: config/tc-or32.c:471 config/tc-or32.c:686
#, c-format
msgid "unknown opcode2 `%s'."
msgstr ""
-#: config/tc-or32.c:512 config/tc-or32.c:727
+#: config/tc-or32.c:510 config/tc-or32.c:725
#, c-format
msgid "instruction not allowed: %s"
msgstr ""
-#: config/tc-or32.c:515 config/tc-or32.c:730
+#: config/tc-or32.c:513 config/tc-or32.c:728
#, c-format
msgid "too many operands: %s"
msgstr ""
-#: config/tc-or32.c:605 config/tc-or32.c:821
+#: config/tc-or32.c:603 config/tc-or32.c:819
msgid "call/jmp target out of range (1)"
msgstr ""
-#: config/tc-or32.c:1018 config/tc-or32.c:1135
+#: config/tc-or32.c:1016 config/tc-or32.c:1133
msgid "the linker will not handle this relocation correctly (1)"
msgstr ""
-#: config/tc-or32.c:1027 config/tc-or32.c:1144
+#: config/tc-or32.c:1025 config/tc-or32.c:1142
msgid "call/jmp target out of range (2)"
msgstr ""
-#: config/tc-or32.c:1437
+#: config/tc-or32.c:1433
msgid "register out of range"
msgstr ""
-#: config/tc-or32.c:1482
+#: config/tc-or32.c:1478
msgid "invalid register in & expression"
msgstr ""
@@ -7127,28 +7519,28 @@ msgstr ""
msgid "Unknown instruction '%s'"
msgstr ""
-#: config/tc-pj.c:67 config/tc-pj.c:75
+#: config/tc-pj.c:82 config/tc-pj.c:90
msgid "confusing relocation expressions"
msgstr ""
-#: config/tc-pj.c:166
+#: config/tc-pj.c:181
msgid "can't have relocation for ipush"
msgstr ""
-#: config/tc-pj.c:273
+#: config/tc-pj.c:290 config/tc-xtensa.c:4976
#, c-format
msgid "unknown opcode %s"
msgstr ""
-#: config/tc-pj.c:422
+#: config/tc-pj.c:439
msgid ""
"PJ options:\n"
"-little\t\t\tgenerate little endian code\n"
"-big\t\t\tgenerate big endian code\n"
msgstr ""
-#: config/tc-pj.c:460 config/tc-sh.c:3472 config/tc-sh.c:3479
-#: config/tc-sh.c:3486 config/tc-sh.c:3493
+#: config/tc-pj.c:469 config/tc-sh.c:3464 config/tc-sh.c:3471
+#: config/tc-sh.c:3478 config/tc-sh.c:3485
msgid "pcrel too far"
msgstr ""
@@ -7160,264 +7552,282 @@ msgstr ""
msgid "estimate size\n"
msgstr ""
-#: config/tc-ppc.c:982 config/tc-s390.c:384
+#: config/tc-ppc.c:879
+#, c-format
+msgid "%s unsupported"
+msgstr ""
+
+#: config/tc-ppc.c:1029 config/tc-s390.c:414 config/tc-s390.c:421
#, c-format
msgid "invalid switch -m%s"
msgstr ""
-#: config/tc-ppc.c:1019
+#: config/tc-ppc.c:1066
msgid ""
"PowerPC options:\n"
+"-a32\t\t\tgenerate ELF32/XCOFF32\n"
+"-a64\t\t\tgenerate ELF64/XCOFF64\n"
"-u\t\t\tignored\n"
"-mpwrx, -mpwr2\t\tgenerate code for POWER/2 (RIOS2)\n"
"-mpwr\t\t\tgenerate code for POWER (RIOS1)\n"
"-m601\t\t\tgenerate code for PowerPC 601\n"
"-mppc, -mppc32, -m603, -m604\n"
"\t\t\tgenerate code for PowerPC 603/604\n"
-"-m403, -m405 generate code for PowerPC 403/405\n"
+"-m403, -m405\t\tgenerate code for PowerPC 403/405\n"
"-m7400, -m7410, -m7450, -m7455\n"
"\t\t\tgenerate code For PowerPC 7400/7410/7450/7455\n"
+msgstr ""
+
+#: config/tc-ppc.c:1079
+msgid ""
"-mppc64, -m620\t\tgenerate code for PowerPC 620/625/630\n"
"-mppc64bridge\t\tgenerate code for PowerPC 64, including bridge insns\n"
"-mbooke64\t\tgenerate code for 64-bit PowerPC BookE\n"
"-mbooke, mbooke32\tgenerate code for 32-bit PowerPC BookE\n"
"-mpower4\t\tgenerate code for Power4 architecture\n"
-"-maltivec\t\tgenerate code for AltiVec\n"
"-mcom\t\t\tgenerate code Power/PowerPC common instructions\n"
"-many\t\t\tgenerate code for any architecture (PWR/PWRX/PPC)\n"
+msgstr ""
+
+#: config/tc-ppc.c:1087
+msgid ""
+"-maltivec\t\tgenerate code for AltiVec\n"
+"-me500, -me500x2\tgenerate code for Motorola e500 core complex\n"
+"-mspe\t\t\tgenerate code for Motorola SPE instructions\n"
"-mregnames\t\tAllow symbolic names for registers\n"
"-mno-regnames\t\tDo not allow symbolic names for registers\n"
msgstr ""
-#: config/tc-ppc.c:1041
+#: config/tc-ppc.c:1094
msgid ""
"-mrelocatable\t\tsupport for GCC's -mrelocatble option\n"
"-mrelocatable-lib\tsupport for GCC's -mrelocatble-lib option\n"
"-memb\t\t\tset PPC_EMB bit in ELF flags\n"
-"-mlittle, -mlittle-endian\n"
+"-mlittle, -mlittle-endian, -l, -le\n"
"\t\t\tgenerate code for a little endian machine\n"
-"-mbig, -mbig-endian\tgenerate code for a big endian machine\n"
+"-mbig, -mbig-endian, -b, -be\n"
+"\t\t\tgenerate code for a big endian machine\n"
"-msolaris\t\tgenerate code for Solaris\n"
"-mno-solaris\t\tdo not generate code for Solaris\n"
"-V\t\t\tprint assembler version number\n"
"-Qy, -Qn\t\tignored\n"
msgstr ""
-#: config/tc-ppc.c:1080
+#: config/tc-ppc.c:1136
#, c-format
msgid "Unknown default cpu = %s, os = %s"
msgstr ""
-#: config/tc-ppc.c:1105
+#: config/tc-ppc.c:1161
msgid "Neither Power nor PowerPC opcodes were selected."
msgstr ""
-#: config/tc-ppc.c:1194 config/tc-s390.c:477
+#: config/tc-ppc.c:1257 config/tc-s390.c:516
#, c-format
msgid "Internal assembler error for instruction %s"
msgstr ""
-#: config/tc-ppc.c:1214
+#: config/tc-ppc.c:1277
#, c-format
msgid "Internal assembler error for macro %s"
msgstr ""
-#: config/tc-ppc.c:1441
+#: config/tc-ppc.c:1599
msgid "identifier+constant@got means identifier@got+constant"
msgstr ""
-#: config/tc-ppc.c:1508
+#: config/tc-ppc.c:1666
#, c-format
msgid "%s relocations do not fit in %d bytes\n"
msgstr ""
-#: config/tc-ppc.c:1615
+#: config/tc-ppc.c:1773
#, c-format
msgid "Length of .lcomm \"%s\" is already %ld. Not changed to %ld."
msgstr ""
-#: config/tc-ppc.c:1697
+#: config/tc-ppc.c:1855
msgid "Relocation cannot be done when using -mrelocatable"
msgstr ""
-#: config/tc-ppc.c:1823
+#: config/tc-ppc.c:1981
#, c-format
msgid "syntax error: invalid toc specifier `%s'"
msgstr ""
-#: config/tc-ppc.c:1837
+#: config/tc-ppc.c:1995
#, c-format
msgid "syntax error: expected `]', found `%c'"
msgstr ""
-#: config/tc-ppc.c:2081
+#: config/tc-ppc.c:2272
msgid "[tocv] symbol is not a toc symbol"
msgstr ""
-#: config/tc-ppc.c:2092
+#: config/tc-ppc.c:2283
msgid "Unimplemented toc32 expression modifier"
msgstr ""
-#: config/tc-ppc.c:2097
+#: config/tc-ppc.c:2288
msgid "Unimplemented toc64 expression modifier"
msgstr ""
-#: config/tc-ppc.c:2101
+#: config/tc-ppc.c:2292
#, c-format
msgid "Unexpected return value [%d] from parse_toc_entry!\n"
msgstr ""
-#: config/tc-ppc.c:2283
+#: config/tc-ppc.c:2510
msgid "unsupported relocation for DS offset field"
msgstr ""
-#: config/tc-ppc.c:2327
+#: config/tc-ppc.c:2554
#, c-format
msgid "syntax error; found `%c' but expected `%c'"
msgstr ""
-#: config/tc-ppc.c:2451
+#: config/tc-ppc.c:2703
msgid "wrong number of operands"
msgstr ""
-#: config/tc-ppc.c:2507
+#: config/tc-ppc.c:2759
msgid "Bad .section directive: want a,e,w,x,M,S,G,T in string"
msgstr ""
-#: config/tc-ppc.c:2622
+#: config/tc-ppc.c:2874
msgid "missing size"
msgstr ""
-#: config/tc-ppc.c:2631
+#: config/tc-ppc.c:2883
msgid "negative size"
msgstr ""
-#: config/tc-ppc.c:2668
+#: config/tc-ppc.c:2920
msgid "missing real symbol name"
msgstr ""
-#: config/tc-ppc.c:2689
+#: config/tc-ppc.c:2941
msgid "attempt to redefine symbol"
msgstr ""
-#: config/tc-ppc.c:2923
+#: config/tc-ppc.c:3188
msgid "The XCOFF file format does not support arbitrary sections"
msgstr ""
-#: config/tc-ppc.c:3000
+#: config/tc-ppc.c:3265
msgid "missing rename string"
msgstr ""
-#: config/tc-ppc.c:3031 config/tc-ppc.c:3586 read.c:3058
+#: config/tc-ppc.c:3296 config/tc-ppc.c:3851 read.c:3060
msgid "missing value"
msgstr ""
-#: config/tc-ppc.c:3049
+#: config/tc-ppc.c:3314
msgid "illegal .stabx expression; zero assumed"
msgstr ""
-#: config/tc-ppc.c:3081
+#: config/tc-ppc.c:3346
msgid "missing class"
msgstr ""
-#: config/tc-ppc.c:3090
+#: config/tc-ppc.c:3355
msgid "missing type"
msgstr ""
-#: config/tc-ppc.c:3171
+#: config/tc-ppc.c:3436
msgid "missing symbol name"
msgstr ""
-#: config/tc-ppc.c:3365
+#: config/tc-ppc.c:3630
msgid "nested .bs blocks"
msgstr ""
-#: config/tc-ppc.c:3398
+#: config/tc-ppc.c:3663
msgid ".es without preceding .bs"
msgstr ""
-#: config/tc-ppc.c:3578
+#: config/tc-ppc.c:3843
msgid "non-constant byte count"
msgstr ""
-#: config/tc-ppc.c:3626
+#: config/tc-ppc.c:3891
msgid ".tc not in .toc section"
msgstr ""
-#: config/tc-ppc.c:3645
+#: config/tc-ppc.c:3910
msgid ".tc with no label"
msgstr ""
-#: config/tc-ppc.c:3756
+#: config/tc-ppc.c:4021
msgid "No previous section to return to. Directive ignored."
msgstr ""
#. Section Contents
#. unknown
-#: config/tc-ppc.c:4173
+#: config/tc-ppc.c:4438
msgid "Unsupported section attribute -- 'a'"
msgstr ""
-#: config/tc-ppc.c:4362
+#: config/tc-ppc.c:4627
msgid "bad symbol suffix"
msgstr ""
-#: config/tc-ppc.c:4455
+#: config/tc-ppc.c:4720
msgid "Unrecognized symbol suffix"
msgstr ""
-#: config/tc-ppc.c:4537
+#: config/tc-ppc.c:4806
msgid "two .function pseudo-ops with no intervening .ef"
msgstr ""
-#: config/tc-ppc.c:4550
+#: config/tc-ppc.c:4819
msgid ".ef with no preceding .function"
msgstr ""
-#: config/tc-ppc.c:4678
+#: config/tc-ppc.c:4947
#, c-format
msgid "warning: symbol %s has no csect"
msgstr ""
-#: config/tc-ppc.c:4978
+#: config/tc-ppc.c:5251
msgid "symbol in .toc does not match any .tc"
msgstr ""
-#: config/tc-ppc.c:5291 config/tc-s390.c:1809 config/tc-v850.c:2331
-#: config/tc-xstormy16.c:536
+#: config/tc-ppc.c:5584 config/tc-s390.c:2072 config/tc-v850.c:2401
+#: config/tc-xstormy16.c:537
msgid "unresolved expression that must be resolved"
msgstr ""
-#: config/tc-ppc.c:5294
+#: config/tc-ppc.c:5587
#, c-format
msgid "unsupported relocation against %s"
msgstr ""
-#: config/tc-ppc.c:5369
+#: config/tc-ppc.c:5662
#, c-format
msgid "cannot emit PC relative %s relocation against %s"
msgstr ""
-#: config/tc-ppc.c:5374
+#: config/tc-ppc.c:5667
#, c-format
msgid "cannot emit PC relative %s relocation"
msgstr ""
-#: config/tc-ppc.c:5495
+#: config/tc-ppc.c:5841
msgid "must branch to an address a multiple of 4"
msgstr ""
-#: config/tc-ppc.c:5499
+#: config/tc-ppc.c:5845
#, c-format
msgid "@local or @plt branch destination is too far away, %ld bytes"
msgstr ""
-#: config/tc-ppc.c:5530
+#: config/tc-ppc.c:5876
#, c-format
msgid "Gas failure, reloc value %d\n"
msgstr ""
-#: config/tc-s390.c:421
+#: config/tc-s390.c:457
msgid ""
" S390 options:\n"
" -mregnames Allow symbolic names for registers\n"
@@ -7427,504 +7837,495 @@ msgid ""
" -m64 Set file format to 64 bit format\n"
msgstr ""
-#: config/tc-s390.c:428
+#: config/tc-s390.c:464
msgid ""
" -V print assembler version number\n"
" -Qy, -Qn ignored\n"
msgstr ""
-#: config/tc-s390.c:462
+#: config/tc-s390.c:500
#, c-format
msgid "Internal assembler error for instruction format %s"
msgstr ""
-#: config/tc-s390.c:658
+#: config/tc-s390.c:782
#, c-format
msgid "identifier+constant@%s means identifier@%s+constant"
msgstr ""
-#: config/tc-s390.c:741
+#: config/tc-s390.c:865
msgid "Can't handle O_big in s390_exp_compare"
msgstr ""
-#: config/tc-s390.c:825
+#: config/tc-s390.c:949
msgid "Invalid suffix for literal pool entry"
msgstr ""
-#: config/tc-s390.c:882
+#: config/tc-s390.c:1006
msgid "Big number is too big"
msgstr ""
-#: config/tc-s390.c:970 config/tc-s390.c:1482
+#: config/tc-s390.c:1144 config/tc-s390.c:1722
#, c-format
msgid "%s relocations do not fit in %d bytes"
msgstr ""
-#: config/tc-s390.c:980
+#: config/tc-s390.c:1154
msgid "relocation not applicable"
msgstr ""
-#: config/tc-s390.c:1125
+#: config/tc-s390.c:1342
msgid "invalid operand suffix"
msgstr ""
-#: config/tc-s390.c:1148
+#: config/tc-s390.c:1365
msgid "syntax error; missing '(' after displacement"
msgstr ""
-#: config/tc-s390.c:1158 config/tc-s390.c:1191 config/tc-s390.c:1210
+#: config/tc-s390.c:1375 config/tc-s390.c:1408 config/tc-s390.c:1427
msgid "syntax error; expected ,"
msgstr ""
-#: config/tc-s390.c:1185
+#: config/tc-s390.c:1402
msgid "syntax error; missing ')' after base register"
msgstr ""
-#: config/tc-s390.c:1203
+#: config/tc-s390.c:1420
msgid "syntax error; ')' not allowed here"
msgstr ""
-#: config/tc-s390.c:1362 config/tc-s390.c:1382 config/tc-s390.c:1395
+#: config/tc-s390.c:1602 config/tc-s390.c:1622 config/tc-s390.c:1635
msgid "Invalid .insn format\n"
msgstr ""
-#: config/tc-s390.c:1370
+#: config/tc-s390.c:1610
#, c-format
msgid "Unrecognized opcode format: `%s'"
msgstr ""
-#: config/tc-s390.c:1398
+#: config/tc-s390.c:1638
msgid "second operand of .insn not a constant\n"
msgstr ""
-#: config/tc-s390.c:1401
+#: config/tc-s390.c:1641
msgid "missing comma after insn constant\n"
msgstr ""
-#: config/tc-s390.c:1715
-msgid "unresolved fx_subsy symbol that must be resolved"
+#: config/tc-s390.c:2075
+msgid "unsupported relocation type"
msgstr ""
-#: config/tc-s390.c:1812
-msgid "unsupported relocation type"
+#: config/tc-sh64.c:596
+msgid "This operand must be constant at assembly time"
msgstr ""
-#: config/tc-sh.c:90
-msgid "directive .big encountered when option -big required"
+#: config/tc-sh64.c:711
+msgid "Invalid operand expression"
msgstr ""
-#: config/tc-sh.c:101
-msgid "directive .little encountered when option -little required"
+#: config/tc-sh64.c:798 config/tc-sh64.c:904
+msgid "PTB operand is a SHmedia symbol"
msgstr ""
-#: config/tc-sh.c:779
-msgid "Invalid PIC expression."
+#: config/tc-sh64.c:801 config/tc-sh64.c:901
+msgid "PTA operand is a SHcompact symbol"
msgstr ""
-#: config/tc-sh.c:808 read.c:3754
-#, c-format
-msgid "unsupported BFD relocation size %u"
+#: config/tc-sh64.c:817
+msgid "invalid expression in operand"
msgstr ""
-#: config/tc-sh.c:1277
-msgid "misplaced PIC operand"
+#: config/tc-sh64.c:1514
+#, c-format
+msgid "invalid operand, not a 5-bit unsigned value: %d"
msgstr ""
-#: config/tc-sh.c:1318
-msgid "illegal register after @-"
+#: config/tc-sh64.c:1519
+#, c-format
+msgid "invalid operand, not a 6-bit signed value: %d"
msgstr ""
-#: config/tc-sh.c:1334
-msgid "must be @(r0,...)"
+#: config/tc-sh64.c:1524
+#, c-format
+msgid "invalid operand, not a 6-bit unsigned value: %d"
msgstr ""
-#: config/tc-sh.c:1358
-msgid "syntax error in @(r0,...)"
+#: config/tc-sh64.c:1529 config/tc-sh64.c:1541
+#, c-format
+msgid "invalid operand, not a 11-bit signed value: %d"
msgstr ""
-#: config/tc-sh.c:1363
-msgid "syntax error in @(r0...)"
+#: config/tc-sh64.c:1531
+#, c-format
+msgid "invalid operand, not a multiple of 32: %d"
msgstr ""
-#: config/tc-sh.c:1404
-msgid "Deprecated syntax."
+#: config/tc-sh64.c:1536
+#, c-format
+msgid "invalid operand, not a 10-bit signed value: %d"
msgstr ""
-#: config/tc-sh.c:1416 config/tc-sh.c:1421
-msgid "syntax error in @(disp,[Rn, gbr, pc])"
+#: config/tc-sh64.c:1543
+#, c-format
+msgid "invalid operand, not an even value: %d"
msgstr ""
-#: config/tc-sh.c:1426
-msgid "expecting )"
+#: config/tc-sh64.c:1548
+#, c-format
+msgid "invalid operand, not a 12-bit signed value: %d"
msgstr ""
-#: config/tc-sh.c:1434
-msgid "illegal register after @"
+#: config/tc-sh64.c:1550
+#, c-format
+msgid "invalid operand, not a multiple of 4: %d"
msgstr ""
-#: config/tc-sh.c:1985
+#: config/tc-sh64.c:1555
#, c-format
-msgid "Invalid register: 'r%d'"
+msgid "invalid operand, not a 13-bit signed value: %d"
msgstr ""
-#: config/tc-sh.c:2151
-msgid "insn can't be combined with parallel processing insn"
+#: config/tc-sh64.c:1557
+#, c-format
+msgid "invalid operand, not a multiple of 8: %d"
msgstr ""
-#: config/tc-sh.c:2158 config/tc-sh.c:2169
-msgid "multiple movx specifications"
+#: config/tc-sh64.c:1562
+#, c-format
+msgid "invalid operand, not a 16-bit signed value: %d"
msgstr ""
-#: config/tc-sh.c:2163 config/tc-sh.c:2190
-msgid "multiple movy specifications"
+#: config/tc-sh64.c:1567
+#, c-format
+msgid "invalid operand, not an 16-bit unsigned value: %d"
msgstr ""
-#: config/tc-sh.c:2171
-msgid "invalid movx address register"
+#: config/tc-sh64.c:1573
+msgid "operand out of range for PT, PTA and PTB"
msgstr ""
-#: config/tc-sh.c:2177 config/tc-sh.c:2182
-msgid "invalid movx dsp register"
+#: config/tc-sh64.c:1575
+#, c-format
+msgid "operand not a multiple of 4 for PT, PTA or PTB: %d"
msgstr ""
-#: config/tc-sh.c:2199 config/tc-sh.c:2204
-msgid "invalid movy dsp register"
+#: config/tc-sh64.c:2103
+#, c-format
+msgid "MOVI operand is not a 32-bit signed value: 0x%8x%08x"
msgstr ""
-#: config/tc-sh.c:2208
-msgid "invalid movy address register"
+#: config/tc-sh64.c:2466 config/tc-sh64.c:2631 config/tc-sh64.c:2646
+msgid "invalid PIC reference"
msgstr ""
-#: config/tc-sh.c:2214
-msgid "dsp immediate shift value not constant"
+#: config/tc-sh64.c:2524
+msgid "can't find opcode"
msgstr ""
-#: config/tc-sh.c:2221 config/tc-sh.c:2234
-msgid "multiple parallel processing specifications"
+#: config/tc-sh64.c:2854
+#, c-format
+msgid "invalid operands to %s"
msgstr ""
-#: config/tc-sh.c:2227
-msgid "multiple condition specifications"
+#: config/tc-sh64.c:2860
+#, c-format
+msgid "excess operands to %s"
msgstr ""
-#: config/tc-sh.c:2243
-msgid "insn cannot be combined with pmuls"
+#: config/tc-sh64.c:2906
+#, c-format
+msgid "The `.mode %s' directive is not valid with this architecture"
msgstr ""
-#: config/tc-sh.c:2260
-msgid "bad padd / psub pmuls output operand"
+#: config/tc-sh64.c:2914
+#, c-format
+msgid "Invalid argument to .mode: %s"
msgstr ""
-#: config/tc-sh.c:2270
-msgid "destination register is same for parallel insns"
+#: config/tc-sh64.c:2945
+#, c-format
+msgid "The `.abi %s' directive is not valid with this architecture"
msgstr ""
-#: config/tc-sh.c:2279
-msgid "condition not followed by conditionalizable insn"
+#: config/tc-sh64.c:2951
+msgid "`.abi 64' but command-line options do not specify 64-bit ABI"
msgstr ""
-#: config/tc-sh.c:2289
-msgid "unrecognized characters at end of parallel processing insn"
+#: config/tc-sh64.c:2956
+msgid "`.abi 32' but command-line options do not specify 32-bit ABI"
msgstr ""
-#: config/tc-sh.c:2425
+#: config/tc-sh64.c:2959
#, c-format
-msgid "excess operands: '%s'"
+msgid "Invalid argument to .abi: %s"
msgstr ""
-#: config/tc-sh.c:2577
-msgid ".uses pseudo-op seen when not relaxing"
+#: config/tc-sh64.c:3014
+msgid "-no-mix is invalid without specifying SHcompact or SHmedia"
msgstr ""
-#: config/tc-sh.c:2583
-msgid "bad .uses format"
+#: config/tc-sh64.c:3019
+msgid "-shcompact-const-crange is invalid without SHcompact"
msgstr ""
-#: config/tc-sh.c:2658
-msgid "Invalid combination: --isa=SHcompact with --isa=SHmedia"
+#: config/tc-sh64.c:3022
+msgid "-expand-pt32 only valid with -abi=64"
msgstr ""
-#: config/tc-sh.c:2664
-msgid "Invalid combination: --isa=SHmedia with --isa=SHcompact"
+#: config/tc-sh64.c:3025
+msgid "-no-expand only valid with SHcompact or SHmedia"
msgstr ""
-#: config/tc-sh.c:2666
-msgid "Invalid combination: --abi=64 with --isa=SHcompact"
+#: config/tc-sh64.c:3028
+msgid "-expand-pt32 invalid together with -no-expand"
msgstr ""
-#: config/tc-sh.c:2677
-msgid "Invalid combination: --abi=32 with --abi=64"
+#: config/tc-sh64.c:3250
+msgid ""
+"SHmedia code not allowed in same section as constants and SHcompact code"
msgstr ""
-#: config/tc-sh.c:2683
-msgid "Invalid combination: --abi=64 with --abi=32"
+#: config/tc-sh64.c:3268
+msgid "No segment info for current section"
msgstr ""
-#: config/tc-sh.c:2685
-msgid "Invalid combination: --isa=SHcompact with --abi=64"
+#: config/tc-sh64.c:3310
+msgid "duplicate datalabel operator ignored"
msgstr ""
-#: config/tc-sh.c:2720
-msgid ""
-"SH options:\n"
-"-little\t\t\tgenerate little endian code\n"
-"-big\t\t\tgenerate big endian code\n"
-"-relax\t\t\talter jump instructions for long displacements\n"
-"-small\t\t\talign sections to 4 byte boundaries, not 16\n"
-"-dsp\t\t\tenable sh-dsp insns, and disable sh3e / sh4 insns.\n"
+#: config/tc-sh64.c:3380
+msgid "Invalid DataLabel expression"
msgstr ""
-#: config/tc-sh.c:2728
-msgid ""
-"-isa=[shmedia\t\tset default instruction set for SH64\n"
-" | SHmedia\n"
-" | shcompact\n"
-" | SHcompact]\n"
-"-abi=[32|64]\t\tset size of expanded SHmedia operands and object\n"
-"\t\t\tfile type\n"
-"-shcompact-const-crange\temit code-range descriptors for constants in\n"
-"\t\t\tSHcompact code sections\n"
-"-no-mix\t\t\tdisallow SHmedia code in the same section as\n"
-"\t\t\tconstants and SHcompact code\n"
-"-no-expand\t\tdo not expand MOVI, PT, PTA or PTB instructions\n"
-"-expand-pt32\t\twith -abi=64, expand PT, PTA and PTB instructions\n"
-"\t\t\tto 32 bits only"
+#: config/tc-sh.c:91
+msgid "directive .big encountered when option -big required"
msgstr ""
-#: config/tc-sh.c:2825
-msgid ".uses does not refer to a local symbol in the same section"
+#: config/tc-sh.c:102
+msgid "directive .little encountered when option -little required"
msgstr ""
-#: config/tc-sh.c:2844
-msgid "can't find fixup pointed to by .uses"
+#: config/tc-sh.c:776
+msgid "Invalid PIC expression."
msgstr ""
-#: config/tc-sh.c:2867
-msgid ".uses target does not refer to a local symbol in the same section"
+#: config/tc-sh.c:1269
+msgid "misplaced PIC operand"
msgstr ""
-#: config/tc-sh.c:2969
-msgid "displacement overflows 12-bit field"
+#: config/tc-sh.c:1310
+msgid "illegal register after @-"
msgstr ""
-#: config/tc-sh.c:2972
-#, c-format
-msgid "displacement to defined symbol %s overflows 12-bit field"
+#: config/tc-sh.c:1326
+msgid "must be @(r0,...)"
msgstr ""
-#: config/tc-sh.c:2976
-#, c-format
-msgid "displacement to undefined symbol %s overflows 12-bit field"
+#: config/tc-sh.c:1350
+msgid "syntax error in @(r0,...)"
msgstr ""
-#: config/tc-sh.c:3054
-msgid "displacement overflows 8-bit field"
+#: config/tc-sh.c:1355
+msgid "syntax error in @(r0...)"
msgstr ""
-#: config/tc-sh.c:3057
-#, c-format
-msgid "displacement to defined symbol %s overflows 8-bit field"
+#: config/tc-sh.c:1396
+msgid "Deprecated syntax."
msgstr ""
-#: config/tc-sh.c:3061
-#, c-format
-msgid "displacement to undefined symbol %s overflows 8-bit field "
+#: config/tc-sh.c:1408 config/tc-sh.c:1413
+msgid "syntax error in @(disp,[Rn, gbr, pc])"
msgstr ""
-#: config/tc-sh.c:3078
-#, c-format
-msgid "overflow in branch to %s; converted into longer instruction sequence"
+#: config/tc-sh.c:1418
+msgid "expecting )"
msgstr ""
-#: config/tc-sh.c:3153 config/tc-sh.c:3201 config/tc-sparc.c:4100
-#: config/tc-sparc.c:4125
-msgid "misaligned data"
+#: config/tc-sh.c:1426
+msgid "illegal register after @"
msgstr ""
-#: config/tc-sh.c:3583
-msgid "misaligned offset"
+#: config/tc-sh.c:1977
+#, c-format
+msgid "Invalid register: 'r%d'"
msgstr ""
-#: config/tc-sh64.c:570
-msgid "This operand must be constant at assembly time"
+#: config/tc-sh.c:2143
+msgid "insn can't be combined with parallel processing insn"
msgstr ""
-#: config/tc-sh64.c:685
-msgid "Invalid operand expression"
+#: config/tc-sh.c:2150 config/tc-sh.c:2161
+msgid "multiple movx specifications"
msgstr ""
-#: config/tc-sh64.c:772 config/tc-sh64.c:878
-msgid "PTB operand is a SHmedia symbol"
+#: config/tc-sh.c:2155 config/tc-sh.c:2182
+msgid "multiple movy specifications"
msgstr ""
-#: config/tc-sh64.c:775 config/tc-sh64.c:875
-msgid "PTA operand is a SHcompact symbol"
+#: config/tc-sh.c:2163
+msgid "invalid movx address register"
msgstr ""
-#: config/tc-sh64.c:791
-msgid "invalid expression in operand"
+#: config/tc-sh.c:2169 config/tc-sh.c:2174
+msgid "invalid movx dsp register"
msgstr ""
-#: config/tc-sh64.c:1488
-#, c-format
-msgid "invalid operand, not a 5-bit unsigned value: %d"
+#: config/tc-sh.c:2191 config/tc-sh.c:2196
+msgid "invalid movy dsp register"
msgstr ""
-#: config/tc-sh64.c:1493
-#, c-format
-msgid "invalid operand, not a 6-bit signed value: %d"
+#: config/tc-sh.c:2200
+msgid "invalid movy address register"
msgstr ""
-#: config/tc-sh64.c:1498
-#, c-format
-msgid "invalid operand, not a 6-bit unsigned value: %d"
+#: config/tc-sh.c:2206
+msgid "dsp immediate shift value not constant"
msgstr ""
-#: config/tc-sh64.c:1503 config/tc-sh64.c:1515
-#, c-format
-msgid "invalid operand, not a 11-bit signed value: %d"
+#: config/tc-sh.c:2213 config/tc-sh.c:2226
+msgid "multiple parallel processing specifications"
msgstr ""
-#: config/tc-sh64.c:1505
-#, c-format
-msgid "invalid operand, not a multiple of 32: %d"
+#: config/tc-sh.c:2219
+msgid "multiple condition specifications"
msgstr ""
-#: config/tc-sh64.c:1510
-#, c-format
-msgid "invalid operand, not a 10-bit signed value: %d"
+#: config/tc-sh.c:2235
+msgid "insn cannot be combined with pmuls"
msgstr ""
-#: config/tc-sh64.c:1517
-#, c-format
-msgid "invalid operand, not an even value: %d"
+#: config/tc-sh.c:2252
+msgid "bad padd / psub pmuls output operand"
msgstr ""
-#: config/tc-sh64.c:1522
-#, c-format
-msgid "invalid operand, not a 12-bit signed value: %d"
+#: config/tc-sh.c:2262
+msgid "destination register is same for parallel insns"
msgstr ""
-#: config/tc-sh64.c:1524
-#, c-format
-msgid "invalid operand, not a multiple of 4: %d"
+#: config/tc-sh.c:2271
+msgid "condition not followed by conditionalizable insn"
msgstr ""
-#: config/tc-sh64.c:1529
-#, c-format
-msgid "invalid operand, not a 13-bit signed value: %d"
+#: config/tc-sh.c:2281
+msgid "unrecognized characters at end of parallel processing insn"
msgstr ""
-#: config/tc-sh64.c:1531
+#: config/tc-sh.c:2417
#, c-format
-msgid "invalid operand, not a multiple of 8: %d"
+msgid "excess operands: '%s'"
msgstr ""
-#: config/tc-sh64.c:1536
-#, c-format
-msgid "invalid operand, not a 16-bit signed value: %d"
+#: config/tc-sh.c:2569
+msgid ".uses pseudo-op seen when not relaxing"
msgstr ""
-#: config/tc-sh64.c:1541
-#, c-format
-msgid "invalid operand, not an 16-bit unsigned value: %d"
+#: config/tc-sh.c:2575
+msgid "bad .uses format"
msgstr ""
-#: config/tc-sh64.c:1547
-msgid "operand out of range for PT, PTA and PTB"
+#: config/tc-sh.c:2654
+msgid "Invalid combination: --isa=SHcompact with --isa=SHmedia"
msgstr ""
-#: config/tc-sh64.c:1549
-#, c-format
-msgid "operand not a multiple of 4 for PT, PTA or PTB: %d"
+#: config/tc-sh.c:2660
+msgid "Invalid combination: --isa=SHmedia with --isa=SHcompact"
msgstr ""
-#: config/tc-sh64.c:2077
-#, c-format
-msgid "MOVI operand is not a 32-bit signed value: 0x%8x%08x"
+#: config/tc-sh.c:2662
+msgid "Invalid combination: --abi=64 with --isa=SHcompact"
msgstr ""
-#: config/tc-sh64.c:2440 config/tc-sh64.c:2605 config/tc-sh64.c:2620
-msgid "invalid PIC reference"
+#: config/tc-sh.c:2675
+msgid "Invalid combination: --abi=32 with --abi=64"
msgstr ""
-#: config/tc-sh64.c:2498
-msgid "can't find opcode"
+#: config/tc-sh.c:2681
+msgid "Invalid combination: --abi=64 with --abi=32"
msgstr ""
-#: config/tc-sh64.c:2828
-#, c-format
-msgid "invalid operands to %s"
+#: config/tc-sh.c:2683
+msgid "Invalid combination: --isa=SHcompact with --abi=64"
msgstr ""
-#: config/tc-sh64.c:2834
-#, c-format
-msgid "excess operands to %s"
+#: config/tc-sh.c:2718
+msgid ""
+"SH options:\n"
+"-little\t\t\tgenerate little endian code\n"
+"-big\t\t\tgenerate big endian code\n"
+"-relax\t\t\talter jump instructions for long displacements\n"
+"-small\t\t\talign sections to 4 byte boundaries, not 16\n"
+"-dsp\t\t\tenable sh-dsp insns, and disable sh2e/sh3e/sh4 insns.\n"
msgstr ""
-#: config/tc-sh64.c:2880
-#, c-format
-msgid "The `.mode %s' directive is not valid with this architecture"
+#: config/tc-sh.c:2726
+msgid ""
+"-isa=[shmedia\t\tset default instruction set for SH64\n"
+" | SHmedia\n"
+" | shcompact\n"
+" | SHcompact]\n"
+"-abi=[32|64]\t\tset size of expanded SHmedia operands and object\n"
+"\t\t\tfile type\n"
+"-shcompact-const-crange\temit code-range descriptors for constants in\n"
+"\t\t\tSHcompact code sections\n"
+"-no-mix\t\t\tdisallow SHmedia code in the same section as\n"
+"\t\t\tconstants and SHcompact code\n"
+"-no-expand\t\tdo not expand MOVI, PT, PTA or PTB instructions\n"
+"-expand-pt32\t\twith -abi=64, expand PT, PTA and PTB instructions\n"
+"\t\t\tto 32 bits only"
msgstr ""
-#: config/tc-sh64.c:2888
-#, c-format
-msgid "Invalid argument to .mode: %s"
+#: config/tc-sh.c:2823
+msgid ".uses does not refer to a local symbol in the same section"
msgstr ""
-#: config/tc-sh64.c:2919
-#, c-format
-msgid "The `.abi %s' directive is not valid with this architecture"
+#: config/tc-sh.c:2842
+msgid "can't find fixup pointed to by .uses"
msgstr ""
-#: config/tc-sh64.c:2925
-msgid "`.abi 64' but command-line options do not specify 64-bit ABI"
+#: config/tc-sh.c:2865
+msgid ".uses target does not refer to a local symbol in the same section"
msgstr ""
-#: config/tc-sh64.c:2930
-msgid "`.abi 32' but command-line options do not specify 32-bit ABI"
+#: config/tc-sh.c:2967
+msgid "displacement overflows 12-bit field"
msgstr ""
-#: config/tc-sh64.c:2933
+#: config/tc-sh.c:2970
#, c-format
-msgid "Invalid argument to .abi: %s"
-msgstr ""
-
-#: config/tc-sh64.c:2984
-msgid "-no-mix is invalid without specifying SHcompact or SHmedia"
-msgstr ""
-
-#: config/tc-sh64.c:2989
-msgid "-shcompact-const-crange is invalid without SHcompact"
+msgid "displacement to defined symbol %s overflows 12-bit field"
msgstr ""
-#: config/tc-sh64.c:2992
-msgid "-expand-pt32 only valid with -abi=64"
+#: config/tc-sh.c:2974
+#, c-format
+msgid "displacement to undefined symbol %s overflows 12-bit field"
msgstr ""
-#: config/tc-sh64.c:2995
-msgid "-no-expand only valid with SHcompact or SHmedia"
+#: config/tc-sh.c:3052
+msgid "displacement overflows 8-bit field"
msgstr ""
-#: config/tc-sh64.c:2998
-msgid "-expand-pt32 invalid together with -no-expand"
+#: config/tc-sh.c:3055
+#, c-format
+msgid "displacement to defined symbol %s overflows 8-bit field"
msgstr ""
-#: config/tc-sh64.c:3215
-msgid ""
-"SHmedia code not allowed in same section as constants and SHcompact code"
+#: config/tc-sh.c:3059
+#, c-format
+msgid "displacement to undefined symbol %s overflows 8-bit field "
msgstr ""
-#: config/tc-sh64.c:3233
-msgid "No segment info for current section"
+#: config/tc-sh.c:3076
+#, c-format
+msgid "overflow in branch to %s; converted into longer instruction sequence"
msgstr ""
-#: config/tc-sh64.c:3275
-msgid "duplicate datalabel operator ignored"
+#: config/tc-sh.c:3151 config/tc-sh.c:3199 config/tc-sparc.c:4192
+#: config/tc-sparc.c:4217
+msgid "misaligned data"
msgstr ""
-#: config/tc-sh64.c:3345
-msgid "Invalid DataLabel expression"
+#: config/tc-sh.c:3585
+msgid "misaligned offset"
msgstr ""
#: config/tc-sparc.c:287
@@ -8121,172 +8522,198 @@ msgid ": asr number must be between 0 and 31"
msgstr ""
#: config/tc-sparc.c:1658
-#, c-format
msgid ": expecting %asrN"
msgstr ""
-#: config/tc-sparc.c:1986
+#: config/tc-sparc.c:1840 config/tc-sparc.c:1878 config/tc-sparc.c:2279
+#: config/tc-sparc.c:2315
+#, c-format
+msgid "Illegal operands: %%%s requires arguments in ()"
+msgstr ""
+
+#: config/tc-sparc.c:1846
+#, c-format
+msgid ""
+"Illegal operands: %%%s cannot be used together with other relocs in the insn "
+"()"
+msgstr ""
+
+#: config/tc-sparc.c:1857
+#, c-format
+msgid "Illegal operands: %%%s can be only used with call __tls_get_addr"
+msgstr ""
+
+#: config/tc-sparc.c:2064
msgid "detected global register use not covered by .register pseudo-op"
msgstr ""
-#: config/tc-sparc.c:2057
+#: config/tc-sparc.c:2135
msgid ": There are only 64 f registers; [0-63]"
msgstr ""
-#: config/tc-sparc.c:2059 config/tc-sparc.c:2071
+#: config/tc-sparc.c:2137 config/tc-sparc.c:2149
msgid ": There are only 32 f registers; [0-31]"
msgstr ""
-#: config/tc-sparc.c:2189 config/tc-sparc.c:2225
-#, c-format
-msgid "Illegal operands: %%%s requires arguments in ()"
-msgstr ""
-
-#: config/tc-sparc.c:2237
+#: config/tc-sparc.c:2327
#, c-format
msgid ""
"Illegal operands: Can't do arithmetics other than + and - involving %%%s()"
msgstr ""
-#: config/tc-sparc.c:2347
+#: config/tc-sparc.c:2437
#, c-format
msgid "Illegal operands: Can't add non-constant expression to %%%s()"
msgstr ""
-#: config/tc-sparc.c:2357
+#: config/tc-sparc.c:2447
#, c-format
msgid ""
"Illegal operands: Can't do arithmetics involving %%%s() of a relocatable "
"symbol"
msgstr ""
-#: config/tc-sparc.c:2375
+#: config/tc-sparc.c:2465
msgid ": PC-relative operand can't be a constant"
msgstr ""
-#: config/tc-sparc.c:2408
+#: config/tc-sparc.c:2472
+msgid ": TLS operand can't be a constant"
+msgstr ""
+
+#: config/tc-sparc.c:2505
msgid ": invalid ASI name"
msgstr ""
-#: config/tc-sparc.c:2416
+#: config/tc-sparc.c:2513
msgid ": invalid ASI expression"
msgstr ""
-#: config/tc-sparc.c:2421
+#: config/tc-sparc.c:2518
msgid ": invalid ASI number"
msgstr ""
-#: config/tc-sparc.c:2518
+#: config/tc-sparc.c:2615
msgid "OPF immediate operand out of range (0-0x1ff)"
msgstr ""
-#: config/tc-sparc.c:2523
+#: config/tc-sparc.c:2620
msgid "non-immediate OPF operand, ignored"
msgstr ""
-#: config/tc-sparc.c:2542
+#: config/tc-sparc.c:2639
msgid ": invalid cpreg name"
msgstr ""
-#: config/tc-sparc.c:2571
+#: config/tc-sparc.c:2668
#, c-format
msgid "Illegal operands%s"
msgstr ""
-#: config/tc-sparc.c:2605
+#: config/tc-sparc.c:2702
#, c-format
msgid "architecture bumped from \"%s\" to \"%s\" on \"%s\""
msgstr ""
-#: config/tc-sparc.c:2641
+#: config/tc-sparc.c:2738
#, c-format
msgid "Architecture mismatch on \"%s\"."
msgstr ""
-#: config/tc-sparc.c:2642
+#: config/tc-sparc.c:2739
#, c-format
msgid " (Requires %s; requested architecture is %s.)"
msgstr ""
-#: config/tc-sparc.c:3253
+#: config/tc-sparc.c:3325
#, c-format
msgid "bad or unhandled relocation type: 0x%02x"
msgstr ""
-#: config/tc-sparc.c:3391
+#: config/tc-sparc.c:3480
#, c-format
msgid "internal error: can't export reloc type %d (`%s')"
msgstr ""
-#: config/tc-sparc.c:3553
+#: config/tc-sparc.c:3644
#, c-format
msgid "BSS length (%d.) <0! Ignored."
msgstr ""
-#: config/tc-sparc.c:3565
+#: config/tc-sparc.c:3656
msgid "bad .reserve segment -- expected BSS segment"
msgstr ""
-#: config/tc-sparc.c:3582 read.c:2045
+#: config/tc-sparc.c:3673 read.c:2048
msgid "missing alignment"
msgstr ""
-#: config/tc-sparc.c:3593 config/tc-sparc.c:3743
+#: config/tc-sparc.c:3684 config/tc-sparc.c:3835
#, c-format
msgid "alignment too large; assuming %d"
msgstr ""
-#: config/tc-sparc.c:3599 config/tc-sparc.c:3749
+#: config/tc-sparc.c:3690 config/tc-sparc.c:3841
msgid "negative alignment"
msgstr ""
-#: config/tc-sparc.c:3609 config/tc-sparc.c:3772 read.c:1249 read.c:2061
+#: config/tc-sparc.c:3700 config/tc-sparc.c:3864 read.c:1251 read.c:2064
msgid "alignment not a power of 2"
msgstr ""
-#: config/tc-sparc.c:3687 config/tc-v850.c:231
+#: config/tc-sparc.c:3778 config/tc-v850.c:233
msgid "Expected comma after symbol-name"
msgstr ""
-#: config/tc-sparc.c:3715 config/tc-v850.c:264
+#: config/tc-sparc.c:3788 read.c:1392
+#, c-format
+msgid ".COMMon length (%lu) out of range ignored"
+msgstr ""
+
+#: config/tc-sparc.c:3807 config/tc-v850.c:266
#, c-format
msgid "Length of .comm \"%s\" is already %ld. Not changed to %d."
msgstr ""
-#: config/tc-sparc.c:3729
+#: config/tc-sparc.c:3821
msgid "Expected comma after common length"
msgstr ""
-#: config/tc-sparc.c:3970 config/tc-sparc.c:3980
+#: config/tc-sparc.c:4062 config/tc-sparc.c:4072
#, c-format
msgid "register syntax is .register %%g[2367],{#scratch|symbolname|#ignore}"
msgstr ""
-#: config/tc-sparc.c:3998
+#: config/tc-sparc.c:4090
msgid "redefinition of global register"
msgstr ""
-#: config/tc-sparc.c:4009
+#: config/tc-sparc.c:4101
#, c-format
msgid "Register symbol %s already defined."
msgstr ""
-#: config/tc-sparc.c:4218
+#: config/tc-sparc.c:4310
#, c-format
msgid "Illegal operands: %%r_plt in %d-byte data field"
msgstr ""
-#: config/tc-sparc.c:4255
+#: config/tc-sparc.c:4320
+#, c-format
+msgid "Illegal operands: %%r_tls_dtpoff in %d-byte data field"
+msgstr ""
+
+#: config/tc-sparc.c:4357
#, c-format
msgid "Illegal operands: Only %%r_%s%d allowed in %d-byte data fields"
msgstr ""
-#: config/tc-sparc.c:4263 config/tc-sparc.c:4294 config/tc-sparc.c:4303
+#: config/tc-sparc.c:4365 config/tc-sparc.c:4396 config/tc-sparc.c:4405
#, c-format
msgid "Illegal operands: %%r_%s%d requires arguments in ()"
msgstr ""
-#: config/tc-sparc.c:4312
+#: config/tc-sparc.c:4414
#, c-format
msgid "Illegal operands: garbage after %%r_%s%d()"
msgstr ""
@@ -8303,25 +8730,25 @@ msgstr ""
msgid "The -a option doesn't exist. (Despite what the man page says!"
msgstr ""
-#: config/tc-tahoe.c:407 config/tc-vax.c:3286
+#: config/tc-tahoe.c:407 config/tc-vax.c:3285
#, c-format
msgid "Displacement length %s ignored!"
msgstr ""
-#: config/tc-tahoe.c:411 config/tc-vax.c:3278
+#: config/tc-tahoe.c:411 config/tc-vax.c:3277
msgid "SYMBOL TABLE not implemented"
msgstr ""
-#: config/tc-tahoe.c:415 config/tc-vax.c:3282
+#: config/tc-tahoe.c:415 config/tc-vax.c:3281
msgid "TOKEN TRACE not implemented"
msgstr ""
-#: config/tc-tahoe.c:419 config/tc-vax.c:3290
+#: config/tc-tahoe.c:419 config/tc-vax.c:3289
#, c-format
msgid "I don't need or use temp. file \"%s\"."
msgstr ""
-#: config/tc-tahoe.c:423 config/tc-vax.c:3294
+#: config/tc-tahoe.c:423 config/tc-vax.c:3293
msgid "I don't use an interpass file! -V ignored"
msgstr ""
@@ -8489,11 +8916,11 @@ msgstr ""
msgid "Compiler bug: ODD number of bytes in arg structure %s."
msgstr ""
-#: config/tc-tahoe.c:1567 config/tc-vax.c:1963
+#: config/tc-tahoe.c:1567 config/tc-vax.c:1962
msgid "Not enough operands"
msgstr ""
-#: config/tc-tahoe.c:1577 config/tc-vax.c:1970
+#: config/tc-tahoe.c:1577 config/tc-vax.c:1969
msgid "Too many operands"
msgstr ""
@@ -8989,228 +9416,228 @@ msgstr ""
#: config/tc-tic80.c:29
#, c-format
-msgid "internal error:%s:%d: %s %d\n"
+msgid "internal error:%s:%d: %s %ld\n"
msgstr ""
-#: config/tc-tic80.c:91
+#: config/tc-tic80.c:89
msgid "Relaxation is a luxury we can't afford"
msgstr ""
-#: config/tc-tic80.c:141
+#: config/tc-tic80.c:138
msgid "bad call to md_atof ()"
msgstr ""
-#: config/tc-tic80.c:239
+#: config/tc-tic80.c:235
msgid "':' not followed by 'm' or 's'"
msgstr ""
-#: config/tc-tic80.c:252
+#: config/tc-tic80.c:248
msgid "paren nesting"
msgstr ""
-#: config/tc-tic80.c:266
+#: config/tc-tic80.c:262
msgid "mismatched parenthesis"
msgstr ""
-#: config/tc-tic80.c:468
+#: config/tc-tic80.c:464
msgid "unhandled expression type"
msgstr ""
-#: config/tc-tic80.c:682
+#: config/tc-tic80.c:678
msgid "symbol reloc that is not PC relative or 32 bits"
msgstr ""
-#: config/tc-tic80.c:711
+#: config/tc-tic80.c:707
msgid "unhandled operand modifier"
msgstr ""
-#: config/tc-tic80.c:753
+#: config/tc-tic80.c:749
msgid "unhandled expression"
msgstr ""
-#: config/tc-tic80.c:802
+#: config/tc-tic80.c:797
#, c-format
msgid "Invalid mnemonic: '%s'"
msgstr ""
-#: config/tc-tic80.c:815
+#: config/tc-tic80.c:810
#, c-format
msgid "Invalid operands: '%s'"
msgstr ""
-#: config/tc-tic80.c:893
+#: config/tc-tic80.c:888
msgid "unhandled predefined symbol bits"
msgstr ""
-#: config/tc-tic80.c:987
+#: config/tc-tic80.c:983
#, c-format
msgid "PC offset 0x%lx outside range 0x%lx-0x%lx"
msgstr ""
-#: config/tc-tic80.c:1002
+#: config/tc-tic80.c:998
msgid "unhandled relocation type in fixup"
msgstr ""
-#: config/tc-tic80.c:1041
+#: config/tc-tic80.c:1037
msgid "md_convert_frag() not implemented yet"
msgstr ""
-#: config/tc-v850.c:242
+#: config/tc-v850.c:244
#, c-format
msgid ".COMMon length (%d.) < 0! Ignored."
msgstr ""
-#: config/tc-v850.c:291
+#: config/tc-v850.c:293
msgid "Common alignment negative; 0 assumed"
msgstr ""
-#: config/tc-v850.c:916
+#: config/tc-v850.c:974
#, c-format
msgid "unknown operand shift: %x\n"
msgstr ""
-#: config/tc-v850.c:917
+#: config/tc-v850.c:975
msgid "internal failure in parse_register_list"
msgstr ""
-#: config/tc-v850.c:934
+#: config/tc-v850.c:991
msgid "constant expression or register list expected"
msgstr ""
-#: config/tc-v850.c:939 config/tc-v850.c:952 config/tc-v850.c:971
+#: config/tc-v850.c:996 config/tc-v850.c:1009 config/tc-v850.c:1028
msgid "high bits set in register list expression"
msgstr ""
-#: config/tc-v850.c:1011 config/tc-v850.c:1075
+#: config/tc-v850.c:1067 config/tc-v850.c:1130
msgid "illegal register included in list"
msgstr ""
-#: config/tc-v850.c:1018
+#: config/tc-v850.c:1073
msgid "system registers cannot be included in list"
msgstr ""
-#: config/tc-v850.c:1023
+#: config/tc-v850.c:1078
msgid "PSW cannot be included in list"
msgstr ""
-#: config/tc-v850.c:1030
+#: config/tc-v850.c:1085
msgid "High value system registers cannot be included in list"
msgstr ""
-#: config/tc-v850.c:1054
+#: config/tc-v850.c:1109
msgid "second register should follow dash in register list"
msgstr ""
-#: config/tc-v850.c:1101
+#: config/tc-v850.c:1154
msgid " V850 options:\n"
msgstr ""
-#: config/tc-v850.c:1102
+#: config/tc-v850.c:1155
msgid " -mwarn-signed-overflow Warn if signed immediate values overflow\n"
msgstr ""
-#: config/tc-v850.c:1103
+#: config/tc-v850.c:1156
msgid ""
" -mwarn-unsigned-overflow Warn if unsigned immediate values overflow\n"
msgstr ""
-#: config/tc-v850.c:1104
+#: config/tc-v850.c:1157
msgid " -mv850 The code is targeted at the v850\n"
msgstr ""
-#: config/tc-v850.c:1105
+#: config/tc-v850.c:1158
msgid " -mv850e The code is targeted at the v850e\n"
msgstr ""
-#: config/tc-v850.c:1106
-msgid " -mv850ea The code is targeted at the v850ea\n"
-msgstr ""
-
-#: config/tc-v850.c:1107
+#: config/tc-v850.c:1159
msgid ""
" -mv850any The code is generic, despite any processor "
"specific instructions\n"
msgstr ""
-#: config/tc-v850.c:1119 config/tc-v850.c:1157
+#: config/tc-v850.c:1160
+msgid " -mrelax Enable relaxation\n"
+msgstr ""
+
+#: config/tc-v850.c:1172 config/tc-v850.c:1207
#, c-format
msgid "unknown command line option: -%c%s\n"
msgstr ""
-#: config/tc-v850.c:1306
+#: config/tc-v850.c:1348
#, c-format
msgid "Unable to determine default target processor from string: %s"
msgstr ""
-#: config/tc-v850.c:1344
+#: config/tc-v850.c:1385
msgid "ctoff() relocation used on an instruction which does not support it"
msgstr ""
-#: config/tc-v850.c:1370
+#: config/tc-v850.c:1411
msgid "sdaoff() relocation used on an instruction which does not support it"
msgstr ""
-#: config/tc-v850.c:1396
+#: config/tc-v850.c:1437
msgid "zdaoff() relocation used on an instruction which does not support it"
msgstr ""
-#: config/tc-v850.c:1433
+#: config/tc-v850.c:1474
msgid "tdaoff() relocation used on an instruction which does not support it"
msgstr ""
-#: config/tc-v850.c:1657
+#: config/tc-v850.c:1698
msgid "Target processor does not support this instruction."
msgstr ""
-#: config/tc-v850.c:1747 config/tc-v850.c:1777 config/tc-v850.c:1965
+#: config/tc-v850.c:1788 config/tc-v850.c:1817 config/tc-v850.c:2005
msgid "immediate operand is too large"
msgstr ""
-#: config/tc-v850.c:1759
+#: config/tc-v850.c:1799
msgid "AAARG -> unhandled constant reloc"
msgstr ""
-#: config/tc-v850.c:1803
+#: config/tc-v850.c:1843
msgid "invalid register name"
msgstr ""
-#: config/tc-v850.c:1808
+#: config/tc-v850.c:1848
msgid "register r0 cannot be used here"
msgstr ""
-#: config/tc-v850.c:1820
+#: config/tc-v850.c:1860
msgid "invalid system register name"
msgstr ""
-#: config/tc-v850.c:1833
+#: config/tc-v850.c:1873
msgid "expected EP register"
msgstr ""
-#: config/tc-v850.c:1850
+#: config/tc-v850.c:1890
msgid "invalid condition code name"
msgstr ""
-#: config/tc-v850.c:1871 config/tc-v850.c:1875
+#: config/tc-v850.c:1911 config/tc-v850.c:1915
msgid "constant too big to fit into instruction"
msgstr ""
-#: config/tc-v850.c:1928
+#: config/tc-v850.c:1968
msgid "syntax error: value is missing before the register name"
msgstr ""
-#: config/tc-v850.c:1930
+#: config/tc-v850.c:1970
msgid "syntax error: register not expected"
msgstr ""
-#: config/tc-v850.c:1944
+#: config/tc-v850.c:1984
msgid "syntax error: system register not expected"
msgstr ""
-#: config/tc-v850.c:1949
+#: config/tc-v850.c:1989
msgid "syntax error: condition code not expected"
msgstr ""
-#: config/tc-v850.c:1990
+#: config/tc-v850.c:2030
msgid "invalid operand"
msgstr ""
@@ -9267,131 +9694,131 @@ msgstr ""
msgid "Symbol used as immediate operand in PIC mode."
msgstr ""
-#: config/tc-vax.c:1942
+#: config/tc-vax.c:1941
msgid "odd number of bytes in operand description"
msgstr ""
-#: config/tc-vax.c:1958
+#: config/tc-vax.c:1957
msgid "Bad operand"
msgstr ""
-#: config/tc-vax.c:2533
+#: config/tc-vax.c:2532
msgid "no '[' to match ']'"
msgstr ""
-#: config/tc-vax.c:2553
+#: config/tc-vax.c:2552
msgid "bad register in []"
msgstr ""
-#: config/tc-vax.c:2555
+#: config/tc-vax.c:2554
msgid "[PC] index banned"
msgstr ""
-#: config/tc-vax.c:2590
+#: config/tc-vax.c:2589
msgid "no '(' to match ')'"
msgstr ""
-#: config/tc-vax.c:2730
+#: config/tc-vax.c:2729
msgid "invalid branch operand"
msgstr ""
-#: config/tc-vax.c:2759
+#: config/tc-vax.c:2758
msgid "address prohibits @"
msgstr ""
-#: config/tc-vax.c:2761
+#: config/tc-vax.c:2760
msgid "address prohibits #"
msgstr ""
-#: config/tc-vax.c:2765
+#: config/tc-vax.c:2764
msgid "address prohibits -()"
msgstr ""
-#: config/tc-vax.c:2767
+#: config/tc-vax.c:2766
msgid "address prohibits ()+"
msgstr ""
-#: config/tc-vax.c:2770
+#: config/tc-vax.c:2769
msgid "address prohibits ()"
msgstr ""
-#: config/tc-vax.c:2772
+#: config/tc-vax.c:2771
msgid "address prohibits []"
msgstr ""
-#: config/tc-vax.c:2774
+#: config/tc-vax.c:2773
msgid "address prohibits register"
msgstr ""
-#: config/tc-vax.c:2776
+#: config/tc-vax.c:2775
msgid "address prohibits displacement length specifier"
msgstr ""
-#: config/tc-vax.c:2806
+#: config/tc-vax.c:2805
msgid "invalid operand of S^#"
msgstr ""
-#: config/tc-vax.c:2823
+#: config/tc-vax.c:2822
msgid "S^# needs expression"
msgstr ""
-#: config/tc-vax.c:2830
+#: config/tc-vax.c:2829
msgid "S^# may only read-access"
msgstr ""
-#: config/tc-vax.c:2855
+#: config/tc-vax.c:2854
msgid "invalid operand of -()"
msgstr ""
-#: config/tc-vax.c:2861
+#: config/tc-vax.c:2860
msgid "-(PC) unpredictable"
msgstr ""
-#: config/tc-vax.c:2863
+#: config/tc-vax.c:2862
msgid "[]index same as -()register: unpredictable"
msgstr ""
-#: config/tc-vax.c:2899
+#: config/tc-vax.c:2898
msgid "invalid operand of ()+"
msgstr ""
-#: config/tc-vax.c:2905
+#: config/tc-vax.c:2904
msgid "(PC)+ unpredictable"
msgstr ""
-#: config/tc-vax.c:2907
+#: config/tc-vax.c:2906
msgid "[]index same as ()+register: unpredictable"
msgstr ""
-#: config/tc-vax.c:2932
+#: config/tc-vax.c:2931
msgid "# conflicts length"
msgstr ""
-#: config/tc-vax.c:2934
+#: config/tc-vax.c:2933
msgid "# bars register"
msgstr ""
-#: config/tc-vax.c:2956
+#: config/tc-vax.c:2955
msgid "writing or modifying # is unpredictable"
msgstr ""
-#: config/tc-vax.c:2986
+#: config/tc-vax.c:2985
msgid "length not needed"
msgstr ""
-#: config/tc-vax.c:2993
+#: config/tc-vax.c:2992
msgid "can't []index a register, because it has no address"
msgstr ""
-#: config/tc-vax.c:2995
+#: config/tc-vax.c:2994
msgid "a register has no address"
msgstr ""
-#: config/tc-vax.c:3006
+#: config/tc-vax.c:3005
msgid "PC part of operand unpredictable"
msgstr ""
-#: config/tc-vax.c:3346
+#: config/tc-vax.c:3345
msgid ""
"VAX options:\n"
"-d LENGTH\t\tignored\n"
@@ -9402,7 +9829,7 @@ msgid ""
"-V\t\t\tignored\n"
msgstr ""
-#: config/tc-vax.c:3355
+#: config/tc-vax.c:3354
msgid ""
"VMS options:\n"
"-+\t\t\thash encode names longer than 31 characters\n"
@@ -9413,773 +9840,929 @@ msgid ""
"-v\"VERSION\"\t\tcode being assembled was produced by compiler \"VERSION\"\n"
msgstr ""
-#: config/tc-w65.c:144
+#: config/tc-w65.c:145
msgid "need on or off."
msgstr ""
-#: config/tc-w65.c:304 config/tc-w65.c:347
+#: config/tc-w65.c:281 config/tc-w65.c:324
msgid "syntax error after <exp"
msgstr ""
-#: config/tc-w65.c:855
-msgid "call to tc_Nout_fix_to_chars \n"
-msgstr ""
-
#: config/tc-xstormy16.c:80
msgid " XSTORMY16 specific command line options:\n"
msgstr ""
-#: config/tc-xstormy16.c:561
+#: config/tc-xstormy16.c:562
#, c-format
msgid "internal error: can't install fix for reloc type %d (`%s')"
msgstr ""
-#: config/tc-z8k.c:285
+#: config/tc-xtensa.c:929
+msgid "'--density' option not supported in this Xtensa configuration"
+msgstr ""
+
+#: config/tc-xtensa.c:1030
+msgid ""
+"'--literal-section-name' is deprecated; use '--rename-section ."
+"literal=NEWNAME'"
+msgstr ""
+
+#: config/tc-xtensa.c:1036
+msgid ""
+"'--text-section-name' is deprecated; use '--rename-section .text=NEWNAME'"
+msgstr ""
+
+#: config/tc-xtensa.c:1042
+msgid ""
+"'--data-section-name' is deprecated; use '--rename-section .data=NEWNAME'"
+msgstr ""
+
+#: config/tc-xtensa.c:1048
+msgid "'--bss-section-name' is deprecated; use '--rename-section .bss=NEWNAME'"
+msgstr ""
+
+#: config/tc-xtensa.c:1186
+msgid "unmatched end directive"
+msgstr ""
+
+#: config/tc-xtensa.c:1215
+msgid ".begin directive with no matching .end directive"
+msgstr ""
+
+#: config/tc-xtensa.c:1259
#, c-format
-msgid "register rr%d, out of range."
+msgid "directive %s can't be negated"
msgstr ""
-#: config/tc-z8k.c:295
+#: config/tc-xtensa.c:1265
+msgid "unknown directive"
+msgstr ""
+
+#: config/tc-xtensa.c:1300
+msgid "cannot set literal_prefix inside literal fragment"
+msgstr ""
+
+#: config/tc-xtensa.c:1337 config/tc-xtensa.c:1371
+msgid "Xtensa density option not supported; ignored"
+msgstr ""
+
+#: config/tc-xtensa.c:1383
#, c-format
-msgid "register rh%d, out of range."
+msgid "does not match begin %s%s at %s:%d"
msgstr ""
-#: config/tc-z8k.c:305
+#: config/tc-xtensa.c:1429
+msgid ".literal_position inside literal directive; ignoring"
+msgstr ""
+
+#: config/tc-xtensa.c:1480
+msgid "expected comma or colon after symbol name; rest of line ignored"
+msgstr ""
+
+#: config/tc-xtensa.c:1655 config/tc-xtensa.c:1672
#, c-format
-msgid "register rl%d, out of range."
+msgid "bad register name: %s"
msgstr ""
-#: config/tc-z8k.c:316
+#: config/tc-xtensa.c:1661
#, c-format
-msgid "register rq%d, out of range."
+msgid "bad register number: %s"
msgstr ""
-#: config/tc-z8k.c:326
+#: config/tc-xtensa.c:1724
+msgid "register number out of range"
+msgstr ""
+
+#: config/tc-xtensa.c:1836
+msgid "too many arguments"
+msgstr ""
+
+#: config/tc-xtensa.c:1922
#, c-format
-msgid "register r%d, out of range."
+msgid "not enough operands (%d) for '%s'; expected %d"
msgstr ""
-#: config/tc-z8k.c:371
+#: config/tc-xtensa.c:1929
#, c-format
-msgid "expected %c"
+msgid "too many operands (%d) for '%s'; expected %d"
msgstr ""
-#: config/tc-z8k.c:388
+#: config/tc-xtensa.c:1973
#, c-format
-msgid "register is wrong size for a word %s"
+msgid "register number for `%s' is not a constant"
msgstr ""
-#: config/tc-z8k.c:404
+#: config/tc-xtensa.c:1978
#, c-format
-msgid "register is wrong size for address %s"
+msgid "register number (%ld) for `%s' is out of range"
msgstr ""
-#: config/tc-z8k.c:665
-msgid "Missing ) in ra(rb)"
+#: config/tc-xtensa.c:2464
+#, c-format
+msgid "operand %d not properly aligned for '%s'"
msgstr ""
-#: config/tc-z8k.c:932
+#: config/tc-xtensa.c:2469
#, c-format
-msgid "operand %s0x%x out of range."
+msgid "operand %d not in immediate table for '%s'"
msgstr ""
-#: config/tc-z8k.c:1060
-msgid "immediate must be 1 or 2"
+#: config/tc-xtensa.c:2474
+#, c-format
+msgid "operand %d too large for '%s'"
msgstr ""
-#: config/tc-z8k.c:1063
-msgid "immediate 1 or 2 expected"
+#: config/tc-xtensa.c:2479
+#, c-format
+msgid "operand %d too small for '%s'"
msgstr ""
-#: config/tc-z8k.c:1090
-msgid "can't use R0 here"
+#: config/tc-xtensa.c:2484
+#, c-format
+msgid "operand %d is invalid for '%s'"
msgstr ""
-#: config/tc-z8k.c:1250
-msgid "Can't find opcode to match operands"
+#: config/tc-xtensa.c:3716
+msgid "INSTR_LABEL_DEF not supported yet"
msgstr ""
-#: config/tc-z8k.c:1366
-#, c-format
-msgid "invalid architecture -z%s"
+#: config/tc-xtensa.c:3745
+msgid "can't handle generation of literal/labels yet"
msgstr ""
-#: config/tc-z8k.c:1382
-msgid ""
-"Z8K options:\n"
-"-z8001\t\t\tgenerate segmented code\n"
-"-z8002\t\t\tgenerate unsegmented code\n"
+#: config/tc-xtensa.c:3749
+msgid "can't handle undefined OP TYPE"
msgstr ""
-#: config/tc-z8k.c:1530
+#: config/tc-xtensa.c:3810
#, c-format
-msgid "Can't subtract symbols in different sections %s %s"
+msgid "found %d operands for '%s': Expected %d"
msgstr ""
-#: depend.c:200
+#: config/tc-xtensa.c:3817
#, c-format
-msgid "can't open `%s' for writing"
+msgid "found too many (%d) operands for '%s': Expected %d"
msgstr ""
-#: depend.c:212
+#: config/tc-xtensa.c:4072
+msgid "instruction fragment may contain data"
+msgstr ""
+
+#: config/tc-xtensa.c:4105
#, c-format
-msgid "can't close `%s'"
+msgid "invalid operand %d on '%s'"
msgstr ""
-#: dwarf2dbg.c:375 dwarf2dbg.c:419
-msgid "file number less than one"
+#: config/tc-xtensa.c:4116
+#, c-format
+msgid "invalid expression for operand %d on '%s'"
msgstr ""
-#: dwarf2dbg.c:381
+#: config/tc-xtensa.c:4177
#, c-format
-msgid "file number %ld already allocated"
+msgid "invalid relocation operand %i on '%s'"
msgstr ""
-#: dwarf2dbg.c:424 dwarf2dbg.c:973
+#: config/tc-xtensa.c:4186
#, c-format
-msgid "unassigned file number %ld"
+msgid "undefined symbol for opcode \"%s\"."
msgstr ""
-#: dwarf2dbg.c:1329 dwarf2dbg.c:1337 dwarf2dbg.c:1345 dwarf2dbg.c:1365
-msgid "dwarf2 is not supported for this object file format"
+#: config/tc-xtensa.c:4280
+msgid "instruction with constant operands does not fit"
msgstr ""
-#: ecoff.c:1556
-#, c-format
-msgid "string too big (%lu bytes)"
+#: config/tc-xtensa.c:4289
+msgid "instruction with constant operands does not fit without widening"
msgstr ""
-#: ecoff.c:1582
-#, c-format
-msgid "inserting \"%s\" into string hash table: %s"
+#: config/tc-xtensa.c:4379
+msgid "instruction's constant operands do not fit"
msgstr ""
-#: ecoff.c:1614 ecoff.c:1808 ecoff.c:1833 ecoff.c:1865 ecoff.c:2019
-#: ecoff.c:2132
-msgid "no current file pointer"
+#: config/tc-xtensa.c:4718
+msgid "opcode 'NOP.N' unavailable in this configuration"
msgstr ""
-#: ecoff.c:1701
-msgid "too many st_End's"
+#: config/tc-xtensa.c:4727
+msgid "opcode 'OR' unavailable in this configuration"
msgstr ""
-#: ecoff.c:2044
+#: config/tc-xtensa.c:4737
#, c-format
-msgid "inserting \"%s\" into tag hash table: %s"
+msgid "invalid %d-byte NOP requested"
msgstr ""
-#: ecoff.c:2210
-msgid "fake .file after real one"
+#: config/tc-xtensa.c:4757
+msgid "get_expanded_loop_offset: undefined opcode"
msgstr ""
-#: ecoff.c:2300
-msgid "filename goes over one page boundary"
+#: config/tc-xtensa.c:4764
+msgid "get_expanded_loop_offset: invalid opcode"
msgstr ""
-#: ecoff.c:2435
-msgid ".begin directive without a preceding .file directive"
+#: config/tc-xtensa.c:4880
+msgid "invalid last instruction for a zero-overhead loop"
msgstr ""
-#: ecoff.c:2442
-msgid ".begin directive without a preceding .ent directive"
+#: config/tc-xtensa.c:4935
+#, c-format
+msgid "cannot assemble '%s' into a literal fragment"
msgstr ""
-#: ecoff.c:2474
-msgid ".bend directive without a preceding .file directive"
+#: config/tc-xtensa.c:4937
+msgid "..."
msgstr ""
-#: ecoff.c:2481
-msgid ".bend directive without a preceding .ent directive"
+#: config/tc-xtensa.c:5071
+msgid "entry instruction with stack decrement < 16"
msgstr ""
-#: ecoff.c:2494
-msgid ".bend directive names unknown symbol"
+#: config/tc-xtensa.c:5075
+msgid "entry instruction with non-constant decrement"
msgstr ""
-#: ecoff.c:2538
-msgid ".def pseudo-op used inside of .def/.endef; ignored"
+#: config/tc-xtensa.c:5152
+#, c-format
+msgid "undefined @ suffix '%s', expected '%s'"
msgstr ""
-#: ecoff.c:2540
-msgid "empty symbol name in .def; ignored"
+#: config/tc-xtensa.c:5242
+#, c-format
+msgid "invalid operand relocation for '%s' instruction"
msgstr ""
-#: ecoff.c:2578
-msgid ".dim pseudo-op used outside of .def/.endef; ignored"
+#: config/tc-xtensa.c:5245
+#, c-format
+msgid "invalid relocation for operand %d in '%s' instruction"
msgstr ""
-#: ecoff.c:2593
-msgid "badly formed .dim directive"
+#: config/tc-xtensa.c:5252
+#, c-format
+msgid "invalid relocation type %d for %s instruction"
msgstr ""
-#: ecoff.c:2606
-msgid "too many .dim entries"
+#: config/tc-xtensa.c:5261
+#, c-format
+msgid "invalid relocation for operand %d of '%s'"
msgstr ""
-#: ecoff.c:2627
-msgid ".scl pseudo-op used outside of .def/.endef; ignored"
+#: config/tc-xtensa.c:5269
+#, c-format
+msgid "non-PCREL relocation operand %d for '%s': %s"
msgstr ""
-#: ecoff.c:2653
-msgid ".size pseudo-op used outside of .def/.endef; ignored"
+#: config/tc-xtensa.c:5328 config/tc-xtensa.c:5366
+#, c-format
+msgid "unhandled local relocation fix %s"
msgstr ""
-#: ecoff.c:2668
-msgid "badly formed .size directive"
+#: config/tc-xtensa.c:5350
+msgid "undecodable FIX"
msgstr ""
-#: ecoff.c:2681
-msgid "too many .size entries"
+#: config/tc-xtensa.c:5478
+msgid "emitting simplification relocation"
msgstr ""
-#: ecoff.c:2704
-msgid ".type pseudo-op used outside of .def/.endef; ignored"
+#: config/tc-xtensa.c:5482
+msgid "emitting unknown relocation"
msgstr ""
-#. FIXME: We could handle this by setting the continued bit.
-#. There would still be a limit: the .type argument can not
-#. be infinite.
-#: ecoff.c:2722
+#: config/tc-xtensa.c:5814
#, c-format
-msgid "the type of %s is too complex; it will be simplified"
+msgid "fr_var %lu < length %d; ignoring"
msgstr ""
-#: ecoff.c:2733
-msgid "Unrecognized .type argument"
+#: config/tc-xtensa.c:6000 config/tc-xtensa.c:6044
+msgid "undecodable instruction in instruction frag"
msgstr ""
-#: ecoff.c:2772
-msgid ".tag pseudo-op used outside of .def/.endef; ignored"
+#: config/tc-xtensa.c:6092
+msgid "invalid empty loop"
msgstr ""
-#: ecoff.c:2798
-msgid ".val pseudo-op used outside of .def/.endef; ignored"
+#: config/tc-xtensa.c:6097
+msgid "loop target does not follow loop instruction in section"
msgstr ""
-#: ecoff.c:2806
-msgid ".val expression is too copmlex"
+#: config/tc-xtensa.c:6215
+msgid "get_text_align_power: argument too large"
msgstr ""
-#: ecoff.c:2837
-msgid ".endef pseudo-op used before .def; ignored"
+#: config/tc-xtensa.c:6420 config/tc-xtensa.c:6566
+msgid "invalid opcode for RELAX_ALIGN_NEXT_OPCODE"
msgstr ""
-#: ecoff.c:2863 ecoff.c:2944
-msgid "bad COFF debugging information"
+#: config/tc-xtensa.c:6421 config/tc-xtensa.c:6567
+msgid "cannot continue"
msgstr ""
-#: ecoff.c:2912
-#, c-format
-msgid "no tag specified for %s"
+#: config/tc-xtensa.c:6458
+msgid "expected loop opcode in relax align next target"
msgstr ""
-#: ecoff.c:3015
-msgid ".end directive without a preceding .file directive"
+#: config/tc-xtensa.c:6475
+msgid "expected align_code or RELAX_ALIGN_NEXT_OPCODE"
msgstr ""
-#: ecoff.c:3022
-msgid ".end directive without a preceding .ent directive"
+#: config/tc-xtensa.c:6549 config/tc-xtensa.c:6587 config/tc-xtensa.c:6591
+#: config/tc-xtensa.c:6595
+msgid "internal error aligning"
msgstr ""
-#: ecoff.c:3044
-msgid ".end directive names unknown symbol"
+#: config/tc-xtensa.c:6676
+msgid "bad relaxation state"
msgstr ""
-#: ecoff.c:3072
-msgid "second .ent directive found before .end directive"
+#: config/tc-xtensa.c:6752
+#, c-format
+msgid "fr_var (%ld) < length (%d); ignoring"
msgstr ""
-#: ecoff.c:3146
-msgid "no way to handle .file within .ent/.end section"
+#: config/tc-xtensa.c:6928
+msgid "internal error: relaxation failed"
msgstr ""
-#: ecoff.c:3171
-msgid ".fmask outside of .ent"
+#: config/tc-xtensa.c:6934
+msgid "internal error: relaxation requires too many steps"
msgstr ""
-#: ecoff.c:3178
-msgid "bad .fmask directive"
+#: config/tc-xtensa.c:7055
+msgid "invalid relaxation fragment result"
msgstr ""
-#: ecoff.c:3211
-msgid "bad .frame directive"
+#: config/tc-xtensa.c:7128
+msgid "unable to widen instruction"
msgstr ""
-#: ecoff.c:3241
-msgid ".mask outside of .ent"
+#: config/tc-xtensa.c:7215
+msgid "multiple literals in expansion"
msgstr ""
-#: ecoff.c:3248
-msgid "bad .mask directive"
+#: config/tc-xtensa.c:7219
+msgid "no registered fragment for literal"
msgstr ""
-#: ecoff.c:3271
-msgid ".loc before .file"
+#: config/tc-xtensa.c:7221
+msgid "number of literal tokens != 1"
msgstr ""
-#: ecoff.c:3410
-msgid "bad .weakext directive"
+#: config/tc-xtensa.c:7298 config/tc-xtensa.c:7304
+#, c-format
+msgid "unresolved loop target symbol: %s"
msgstr ""
-#: ecoff.c:3479
-#, c-format
-msgid ".stab%c is not supported"
+#: config/tc-xtensa.c:7401
+msgid "loop relaxation specification does not correspond"
msgstr ""
-#: ecoff.c:3489
+#: config/tc-xtensa.c:7428
+msgid "loop too long for LOOP instruction"
+msgstr ""
+
+#: config/tc-xtensa.c:7465
#, c-format
-msgid ".stab%c: ignoring non-zero other field"
+msgid "invalid expression evaluation type %d"
msgstr ""
-#: ecoff.c:3523
+#: config/tc-xtensa.c:7702
#, c-format
-msgid ""
-"line number (%d) for .stab%c directive cannot fit in index field (20 bits)"
+msgid "fixes not all moved from %s"
msgstr ""
-#: ecoff.c:3559
+#: config/tc-xtensa.c:7835
+msgid "inlining literal pool; specify location with .literal_position."
+msgstr ""
+
+#: config/tc-xtensa.c:8230
#, c-format
-msgid "illegal .stab%c directive, bad character"
+msgid "could not create section %s"
msgstr ""
-#: ecoff.c:4021 ecoff.c:4210 ecoff.c:4235
-msgid ".begin/.bend in different segments"
+#: config/tc-xtensa.c:8232
+#, c-format
+msgid "invalid flag combination on section %s"
msgstr ""
-#: ecoff.c:4737
-msgid "missing .end or .bend at end of file"
+#: config/tc-xtensa.c:8481
+#, c-format
+msgid "invalid symbolic operand %d on '%s'"
msgstr ""
-#: ecoff.c:5227
-msgid "GP prologue size exceeds field size, using 0 instead"
+#: config/tc-xtensa.c:8545
+msgid "operand number mismatch"
msgstr ""
-#: expr.c:84 read.c:3230
-msgid "bignum invalid"
+#: config/tc-xtensa.c:8592
+msgid "invalid opcode"
msgstr ""
-#: expr.c:86 read.c:3232 read.c:3565 read.c:4464
-msgid "floating point number invalid"
+#: config/tc-xtensa.c:8598
+msgid "too few operands"
msgstr ""
-#: expr.c:246
-msgid "bad floating-point constant: exponent overflow"
+#: config/tc-xtensa.c:8817
+msgid "ignoring extra '-rename-section' delimiter ':'"
msgstr ""
-#: expr.c:250
+#: config/tc-xtensa.c:8822
#, c-format
-msgid "bad floating-point constant: unknown error code=%d"
+msgid "ignoring invalid '-rename-section' specification: '%s'"
msgstr ""
-#: expr.c:428
-msgid ""
-"a bignum with underscores may not have more than 8 hex digits in any word"
+#: config/tc-xtensa.c:8845
+#, c-format
+msgid "section %s renamed multiple times"
msgstr ""
-#: expr.c:451
-msgid "a bignum with underscores must have exactly 4 words"
+#: config/tc-xtensa.c:8847
+#, c-format
+msgid "multiple sections remapped to output section %s"
msgstr ""
-#. Either not seen or not defined.
-#. @@ Should print out the original string instead of
-#. the parsed number.
-#: expr.c:574
+#: config/tc-z8k.c:314
#, c-format
-msgid "backward ref to unknown label \"%d:\""
+msgid "register rr%d out of range"
msgstr ""
-#: expr.c:697
-msgid "character constant too large"
+#: config/tc-z8k.c:316
+#, c-format
+msgid "register rr%d does not exist"
msgstr ""
-#: expr.c:950
+#: config/tc-z8k.c:326
#, c-format
-msgid "expr.c(operand): bad atof_generic return val %d"
+msgid "register rh%d out of range"
msgstr ""
-#: expr.c:1012
+#: config/tc-z8k.c:336
#, c-format
-msgid "missing '%c'"
+msgid "register rl%d out of range"
msgstr ""
-#: expr.c:1024 read.c:3935
-msgid "EBCDIC constants are not supported"
+#: config/tc-z8k.c:347
+#, c-format
+msgid "register rq%d out of range"
msgstr ""
-#: expr.c:1095
+#: config/tc-z8k.c:349
#, c-format
-msgid "Unary operator %c ignored because bad operand follows"
+msgid "register rq%d does not exist"
msgstr ""
-#: expr.c:1141 expr.c:1166
-msgid "syntax error in .startof. or .sizeof."
+#: config/tc-z8k.c:359
+#, c-format
+msgid "register r%d out of range"
msgstr ""
-#: expr.c:1677
-msgid "missing operand; zero assumed"
+#: config/tc-z8k.c:404
+#, c-format
+msgid "expected %c"
msgstr ""
-#: expr.c:1712
-msgid "left operand is a bignum; integer 0 assumed"
+#: config/tc-z8k.c:421
+#, c-format
+msgid "register is wrong size for a word %s"
msgstr ""
-#: expr.c:1714
-msgid "left operand is a float; integer 0 assumed"
+#: config/tc-z8k.c:437
+#, c-format
+msgid "register is wrong size for address %s"
msgstr ""
-#: expr.c:1723
-msgid "right operand is a bignum; integer 0 assumed"
+#. No interrupt type specified, opcode won't do anything.
+#: config/tc-z8k.c:585
+msgid "opcode has no effect"
msgstr ""
-#: expr.c:1725
-msgid "right operand is a float; integer 0 assumed"
+#: config/tc-z8k.c:697
+msgid "Missing ) in ra(rb)"
msgstr ""
-#: expr.c:1780 symbols.c:1136
-msgid "division by zero"
+#: config/tc-z8k.c:919 config/tc-z8k.c:925
+msgid "invalid indirect register size"
msgstr ""
-#: expr.c:1878
-msgid "operation combines symbols in different segments"
+#: config/tc-z8k.c:971
+#, c-format
+msgid "operand %s0x%x out of range"
msgstr ""
-#: frags.c:87
-#, c-format
-msgid "can't extend frag %u chars"
+#: config/tc-z8k.c:1099
+msgid "immediate must be 1 or 2"
msgstr ""
-#: frags.c:168
-msgid "attempt to allocate data in absolute section"
+#: config/tc-z8k.c:1102
+msgid "immediate 1 or 2 expected"
msgstr ""
-#: frags.c:174
-msgid "attempt to allocate data in common section"
+#: config/tc-z8k.c:1129
+msgid "can't use R0 here"
msgstr ""
-#: gasp.c:456
-msgid "redefinition not allowed\n"
+#: config/tc-z8k.c:1292
+msgid "Can't find opcode to match operands"
msgstr ""
-#: gasp.c:525
+#: config/tc-z8k.c:1411
#, c-format
-msgid "the %c operator cannot take non-absolute arguments.\n"
+msgid "invalid architecture -z%s"
msgstr ""
-#: gasp.c:656
-msgid "string where expression expected.\n"
+#: config/tc-z8k.c:1432
+msgid ""
+" Z8K options:\n"
+" -z8001 generate segmented code\n"
+" -z8002 generate unsegmented code\n"
+" -linkrelax create linker relaxable code\n"
msgstr ""
-#: gasp.c:662
-msgid "can't find primary in expression.\n"
+#: config/tc-z8k.c:1445
+msgid "call to md_convert_frag\n"
msgstr ""
-#: gasp.c:700
-msgid "misplaced closing parens.\n"
+#: config/tc-z8k.c:1476 config/tc-z8k.c:1487
+msgid "cannot branch to odd address"
msgstr ""
-#: gasp.c:737
-msgid "attempt to divide by zero.\n"
+#: config/tc-z8k.c:1479 config/tc-z8k.c:1490
+msgid "relative jump out of range"
msgstr ""
-#: gasp.c:768
-msgid "can't add two relocatable expressions\n"
+#: config/tc-z8k.c:1497
+msgid "relative call out of range"
msgstr ""
-#: gasp.c:976
-msgid "unreasonable nesting.\n"
+#: config/tc-z8k.c:1523
+msgid "relative address out of range"
msgstr ""
-#: gasp.c:1054
-msgid "End of file not at start of line.\n"
+#: config/tc-z8k.c:1543
+#, c-format
+msgid "md_apply_fix3: unknown r_type 0x%x\n"
msgstr ""
-#: gasp.c:1175
+#: config/tc-z8k.c:1556
+msgid "call to md_estimate_size_before_relax\n"
+msgstr ""
+
+#: config/tc-z8k.c:1600
#, c-format
-msgid "Illegal base character %c.\n"
+msgid "Can't subtract symbols in different sections %s %s"
msgstr ""
-#: gasp.c:1293
+#: depend.c:200
#, c-format
-msgid "radix is %c must be one of b, q, d or h"
+msgid "can't open `%s' for writing"
msgstr ""
-#: gasp.c:1328
+#: depend.c:212
#, c-format
-msgid "size must be one of b, w or l, is %c.\n"
+msgid "can't close `%s'"
msgstr ""
-#: gasp.c:1436
-msgid "datab repeat must be constant.\n"
+#: dw2gencfi.c:262
+#, c-format
+msgid "register save offset not a multiple of %u"
msgstr ""
-#: gasp.c:1438
-msgid "datab data must be absolute.\n"
+#: dw2gencfi.c:388
+msgid "missing separator"
msgstr ""
-#: gasp.c:1452
-msgid "align needs absolute expression.\n"
+#: dw2gencfi.c:410 dw2gencfi.c:428
+msgid "bad register expression"
msgstr ""
-#: gasp.c:1459
-msgid ".align needs absolute fill value.\n"
+#: dw2gencfi.c:450 dw2gencfi.c:547
+msgid "CFI instruction used without previous .cfi_startproc"
msgstr ""
-#: gasp.c:1487
-msgid "res needs absolute expression for fill count.\n"
+#: dw2gencfi.c:579
+msgid "previous CFI entry not closed (missing .cfi_endproc)"
msgstr ""
-#: gasp.c:1568
-msgid "form LIN= needs absolute expresssion.\n"
+#: dw2gencfi.c:612
+msgid ".cfi_endproc without corresponding .cfi_startproc"
msgstr ""
-#: gasp.c:1571
-msgid "COL="
+#: dw2gencfi.c:987
+msgid "open CFI at the end of file; missing .cfi_endproc directive"
msgstr ""
-#: gasp.c:1574
-msgid "form COL= needs absolute expresssion.\n"
+#: dwarf2dbg.c:468 dwarf2dbg.c:498
+msgid "file number less than one"
msgstr ""
-#. Turns the next expression into a string.
-#: gasp.c:1617 macro.c:382
-#, no-c-format
-msgid "% operator needs absolute expression"
+#: dwarf2dbg.c:474
+#, c-format
+msgid "file number %ld already allocated"
msgstr ""
-#: gasp.c:1679
-msgid "misplaced ( .\n"
+#: dwarf2dbg.c:503 dwarf2dbg.c:1064
+#, c-format
+msgid "unassigned file number %ld"
msgstr ""
-#: gasp.c:1694
-msgid "misplaced ).\n"
+#: dwarf2dbg.c:1130 dwarf2dbg.c:1327
+msgid "internal error: unknown dwarf2 format"
msgstr ""
-#: gasp.c:1746
-msgid ".instr needs absolute expresson.\n"
+#: dwarf2dbg.c:1472 dwarf2dbg.c:1480 dwarf2dbg.c:1488 dwarf2dbg.c:1509
+msgid "dwarf2 is not supported for this object file format"
msgstr ""
-#: gasp.c:1783
-msgid "need absolute position.\n"
+#: ecoff.c:1556
+#, c-format
+msgid "string too big (%lu bytes)"
msgstr ""
-#: gasp.c:1785
-msgid "need absolute length.\n"
+#: ecoff.c:1582
+#, c-format
+msgid "inserting \"%s\" into string hash table: %s"
msgstr ""
-#: gasp.c:2031
-msgid "END missing from end of file.\n"
+#: ecoff.c:1614 ecoff.c:1808 ecoff.c:1833 ecoff.c:1865 ecoff.c:2019
+#: ecoff.c:2132
+msgid "no current file pointer"
msgstr ""
-#: gasp.c:2057
-msgid ".ASSIGNA needs constant expression argument.\n"
+#: ecoff.c:1701
+msgid "too many st_End's"
msgstr ""
-#: gasp.c:2061
-msgid ".ASSIGNA without label.\n"
+#: ecoff.c:2044
+#, c-format
+msgid "inserting \"%s\" into tag hash table: %s"
msgstr ""
-#: gasp.c:2086
-msgid ".ASSIGNS without label.\n"
+#: ecoff.c:2210
+msgid "fake .file after real one"
msgstr ""
-#: gasp.c:2150
-#, c-format
-msgid "Can't find preprocessor variable %s.\n"
+#: ecoff.c:2300
+msgid "filename goes over one page boundary"
msgstr ""
-#: gasp.c:2215
-msgid "Comparison operator must be one of EQ, NE, LT, LE, GT or GE.\n"
+#: ecoff.c:2435
+msgid ".begin directive without a preceding .file directive"
msgstr ""
-#: gasp.c:2250
-msgid "Comparison operator for strings must be EQ or NE\n"
+#: ecoff.c:2442
+msgid ".begin directive without a preceding .ent directive"
msgstr ""
-#: gasp.c:2262 gasp.c:2272 gasp.c:2375
-msgid "Conditional operator must have absolute operands.\n"
+#: ecoff.c:2474
+msgid ".bend directive without a preceding .file directive"
msgstr ""
-#: gasp.c:2267
-msgid "String compared against expression.\n"
+#: ecoff.c:2481
+msgid ".bend directive without a preceding .ent directive"
msgstr ""
-#: gasp.c:2318
-msgid "AIF nesting unreasonable.\n"
+#: ecoff.c:2494
+msgid ".bend directive names unknown symbol"
msgstr ""
-#: gasp.c:2333
-msgid "Multiple AELSEs in AIF.\n"
+#: ecoff.c:2538
+msgid ".def pseudo-op used inside of .def/.endef; ignored"
msgstr ""
-#: gasp.c:2349
-msgid "AENDI without AIF.\n"
+#: ecoff.c:2540
+msgid "empty symbol name in .def; ignored"
msgstr ""
-#: gasp.c:2372 gasp.c:2454
-msgid "IF nesting unreasonable.\n"
+#: ecoff.c:2578
+msgid ".dim pseudo-op used outside of .def/.endef; ignored"
msgstr ""
-#: gasp.c:2464
-msgid "Bad format for IF or IFNC.\n"
+#: ecoff.c:2593
+msgid "badly formed .dim directive"
msgstr ""
-#: gasp.c:2485
-msgid "AENDR without a AREPEAT.\n"
+#: ecoff.c:2606
+msgid "too many .dim entries"
msgstr ""
-#: gasp.c:2487
-msgid "ENDR without a REPT.\n"
+#: ecoff.c:2627
+msgid ".scl pseudo-op used outside of .def/.endef; ignored"
msgstr ""
-#: gasp.c:2509
-#, c-format
-msgid "AWHILE without a AENDW at %d.\n"
+#: ecoff.c:2653
+msgid ".size pseudo-op used outside of .def/.endef; ignored"
msgstr ""
-#: gasp.c:2546
-msgid "AENDW without a AENDW.\n"
+#: ecoff.c:2668
+msgid "badly formed .size directive"
msgstr ""
-#: gasp.c:2590
-msgid "AREPEAT must have absolute operand.\n"
+#: ecoff.c:2681
+msgid "too many .size entries"
msgstr ""
-#: gasp.c:2596
+#: ecoff.c:2704
+msgid ".type pseudo-op used outside of .def/.endef; ignored"
+msgstr ""
+
+#. FIXME: We could handle this by setting the continued bit.
+#. There would still be a limit: the .type argument can not
+#. be infinite.
+#: ecoff.c:2722
#, c-format
-msgid "AREPEAT without a AENDR at %d.\n"
+msgid "the type of %s is too complex; it will be simplified"
msgstr ""
-#: gasp.c:2638
-msgid ".ENDM without a matching .MACRO.\n"
+#: ecoff.c:2733
+msgid "Unrecognized .type argument"
msgstr ""
-#: gasp.c:2672
-msgid "LOCAL outside of MACRO"
+#: ecoff.c:2772
+msgid ".tag pseudo-op used outside of .def/.endef; ignored"
msgstr ""
-#: gasp.c:2685
-#, c-format
-msgid "macro at line %d: %s\n"
+#: ecoff.c:2798
+msgid ".val pseudo-op used outside of .def/.endef; ignored"
msgstr ""
-#: gasp.c:2708
-msgid "macro expansion"
+#: ecoff.c:2806
+msgid ".val expression is too copmlex"
msgstr ""
-#: gasp.c:2762
-msgid "Character code in string must be absolute expression.\n"
+#: ecoff.c:2837
+msgid ".endef pseudo-op used before .def; ignored"
msgstr ""
-#: gasp.c:2767
-msgid "Missing > for character code.\n"
+#: ecoff.c:2863 ecoff.c:2944
+msgid "bad COFF debugging information"
msgstr ""
-#: gasp.c:2826
+#: ecoff.c:2912
#, c-format
-msgid "string for SDATAC longer than 255 characters (%d).\n"
+msgid "no tag specified for %s"
msgstr ""
-#: gasp.c:2855
-#, c-format
-msgid "illegal character in SDATA line (0x%x).\n"
+#: ecoff.c:3015
+msgid ".end directive without a preceding .file directive"
msgstr ""
-#: gasp.c:2877
-msgid "Must have absolute SDATAB repeat count.\n"
+#: ecoff.c:3022
+msgid ".end directive without a preceding .ent directive"
msgstr ""
-#: gasp.c:2880
-#, c-format
-msgid "Must have positive SDATAB repeat count (%d).\n"
+#: ecoff.c:3044
+msgid ".end directive names unknown symbol"
+msgstr ""
+
+#: ecoff.c:3072
+msgid "second .ent directive found before .end directive"
msgstr ""
-#: gasp.c:2908
+#: ecoff.c:3146
+msgid "no way to handle .file within .ent/.end section"
+msgstr ""
+
+#: ecoff.c:3271
+msgid ".loc before .file"
+msgstr ""
+
+#: ecoff.c:3410
+msgid "bad .weakext directive"
+msgstr ""
+
+#: ecoff.c:3479
#, c-format
-msgid "Unreasonable include depth (%ld).\n"
+msgid ".stab%c is not supported"
msgstr ""
-#: gasp.c:2962
+#: ecoff.c:3489
#, c-format
-msgid "Can't open include file `%s'.\n"
+msgid ".stab%c: ignoring non-zero other field"
msgstr ""
-#: gasp.c:3036
-msgid "Unreasonable expansion (-u turns off check).\n"
+#: ecoff.c:3523
+#, c-format
+msgid ""
+"line number (%d) for .stab%c directive cannot fit in index field (20 bits)"
msgstr ""
-#. This one causes lots of pain when trying to preprocess
-#. ordinary code.
-#: gasp.c:3250
+#: ecoff.c:3559
#, c-format
-msgid "Unrecognised pseudo op `%s'.\n"
+msgid "illegal .stab%c directive, bad character"
msgstr ""
-#: gasp.c:3319
-msgid "ORG command not allowed.\n"
+#: ecoff.c:4021 ecoff.c:4210 ecoff.c:4235
+msgid ".begin/.bend in different segments"
+msgstr ""
+
+#: ecoff.c:4737
+msgid "missing .end or .bend at end of file"
msgstr ""
-#: gasp.c:3532
-msgid "Invalid expression on command line.\n"
+#: ecoff.c:5227
+msgid "GP prologue size exceeds field size, using 0 instead"
+msgstr ""
+
+#: expr.c:83 read.c:3232
+msgid "bignum invalid"
msgstr ""
-#: gasp.c:3575
+#: expr.c:85 read.c:3234 read.c:3574 read.c:4474
+msgid "floating point number invalid"
+msgstr ""
+
+#: expr.c:243
+msgid "bad floating-point constant: exponent overflow"
+msgstr ""
+
+#: expr.c:247
#, c-format
-msgid ""
-"Usage: %s \n"
-" [-a] [--alternate] enter alternate macro mode\n"
-" [-c char] [--commentchar char] change the comment character from !\n"
-" [-d] [--debug] print some debugging info\n"
-" [-h] [--help] print this message\n"
-" [-M] [--mri] enter MRI compatibility mode\n"
-" [-o out] [--output out] set the output file\n"
-" [-p] [--print] print line numbers\n"
+msgid "bad floating-point constant: unknown error code=%d"
msgstr ""
-#: gasp.c:3584
+#: expr.c:425
msgid ""
-" [-s] [--copysource] copy source through as comments \n"
-" [-u] [--unreasonable] allow unreasonable nesting\n"
-" [-v] [--version] print the program version\n"
-" [-Dname=value] create preprocessor variable called name, "
-"with value\n"
-" [-Ipath] add to include path list\n"
-" [in-file]\n"
+"a bignum with underscores may not have more than 8 hex digits in any word"
msgstr ""
-#: gasp.c:3601
-#, c-format
-msgid "%s: Gnu Assembler Macro Preprocessor\n"
+#: expr.c:448
+msgid "a bignum with underscores must have exactly 4 words"
msgstr ""
-#. This output is intended to follow the GNU standards document.
-#: gasp.c:3689
+#. Either not seen or not defined.
+#. @@ Should print out the original string instead of
+#. the parsed number.
+#: expr.c:571
#, c-format
-msgid "GNU assembler pre-processor %s\n"
+msgid "backward ref to unknown label \"%d:\""
msgstr ""
-#: gasp.c:3690
-msgid "Copyright 1996 Free Software Foundation, Inc.\n"
+#: expr.c:694
+msgid "character constant too large"
msgstr ""
-#: gasp.c:3713
+#: expr.c:942
#, c-format
-msgid "%s: Can't open output file `%s'.\n"
+msgid "expr.c(operand): bad atof_generic return val %d"
msgstr ""
-#: gasp.c:3737
+#: expr.c:1004
#, c-format
-msgid "%s: Can't open input file `%s'.\n"
+msgid "missing '%c'"
+msgstr ""
+
+#: expr.c:1016 read.c:3945
+msgid "EBCDIC constants are not supported"
msgstr ""
-#: gasp.c:3756
+#: expr.c:1099
#, c-format
-msgid "Internal error, aborting at %s line %d"
+msgid "Unary operator %c ignored because bad operand follows"
msgstr ""
-#: gasp.c:3759
-msgid ""
-"\n"
-"Please report this bug.\n"
+#: expr.c:1145 expr.c:1170
+msgid "syntax error in .startof. or .sizeof."
+msgstr ""
+
+#: expr.c:1666
+msgid "missing operand; zero assumed"
+msgstr ""
+
+#: expr.c:1701
+msgid "left operand is a bignum; integer 0 assumed"
+msgstr ""
+
+#: expr.c:1703
+msgid "left operand is a float; integer 0 assumed"
+msgstr ""
+
+#: expr.c:1712
+msgid "right operand is a bignum; integer 0 assumed"
+msgstr ""
+
+#: expr.c:1714
+msgid "right operand is a float; integer 0 assumed"
+msgstr ""
+
+#: expr.c:1770 symbols.c:1191
+msgid "division by zero"
+msgstr ""
+
+#: expr.c:1868
+msgid "operation combines symbols in different segments"
+msgstr ""
+
+#: frags.c:48
+msgid "attempt to allocate data in absolute section"
+msgstr ""
+
+#: frags.c:54
+msgid "attempt to allocate data in common section"
+msgstr ""
+
+#: frags.c:107
+#, c-format
+msgid "can't extend frag %u chars"
msgstr ""
#. Detect if we are reading from stdin by examining the file
@@ -10250,6 +10833,12 @@ msgstr ""
msgid "new line in title"
msgstr ""
+#. Turns the next expression into a string.
+#: macro.c:382
+#, no-c-format
+msgid "% operator needs absolute expression"
+msgstr ""
+
#: macro.c:545
msgid "unexpected end of file in macro definition"
msgstr ""
@@ -10258,31 +10847,31 @@ msgstr ""
msgid "missing ) after formals"
msgstr ""
-#: macro.c:710
+#: macro.c:703
msgid "missplaced )"
msgstr ""
-#: macro.c:979
+#: macro.c:960
msgid "confusion in formal parameters"
msgstr ""
-#: macro.c:984
+#: macro.c:965
msgid "macro formal argument does not exist"
msgstr ""
-#: macro.c:999
+#: macro.c:980
msgid "can't mix positional and keyword arguments"
msgstr ""
-#: macro.c:1007
+#: macro.c:988
msgid "too many positional arguments"
msgstr ""
-#: macro.c:1186
+#: macro.c:1163
msgid "unexpected end of file in irp or irpc"
msgstr ""
-#: macro.c:1194
+#: macro.c:1171
msgid "missing model parameter"
msgstr ""
@@ -10358,347 +10947,333 @@ msgstr ""
msgid "can't continue"
msgstr ""
-#: read.c:445
+#: read.c:442
#, c-format
msgid "error constructing %s pseudo-op table: %s"
msgstr ""
-#: read.c:801
+#: read.c:809
#, c-format
msgid "unknown pseudo-op: `%s'"
msgstr ""
-#: read.c:932
+#: read.c:940
#, c-format
msgid "label \"%d$\" redefined"
msgstr ""
-#: read.c:1150
+#: read.c:1152
msgid ".abort detected. Abandoning ship."
msgstr ""
-#: read.c:1172 read.c:2411
+#: read.c:1174 read.c:2413
msgid "ignoring fill value in absolute section"
msgstr ""
-#: read.c:1258
+#: read.c:1260
#, c-format
msgid "alignment too large: %u assumed"
msgstr ""
-#: read.c:1290
+#: read.c:1292
msgid "expected fill pattern missing"
msgstr ""
-#: read.c:1368 read.c:1973 read.c:2181 read.c:2793
-msgid "expected symbol name"
-msgstr ""
-
-#: read.c:1378 read.c:2191 read.c:2803 stabs.c:480
-#, c-format
-msgid "expected comma after \"%s\""
-msgstr ""
-
-#: read.c:1390
-#, c-format
-msgid ".COMMon length (%ld) < 0 ignored"
-msgstr ""
-
-#: read.c:1414
+#: read.c:1417
#, c-format
msgid "length of .comm \"%s\" is already %ld; not changing to %ld"
msgstr ""
#. Some of the back ends can't deal with non-positive line numbers.
#. Besides, it's silly.
-#: read.c:1633
+#: read.c:1636
#, c-format
msgid "line numbers must be positive; line number %d rejected"
msgstr ""
-#: read.c:1661
+#: read.c:1664
msgid "start address not supported"
msgstr ""
-#: read.c:1671
+#: read.c:1674
msgid ".err encountered"
msgstr ""
-#: read.c:1690 read.c:1692
+#: read.c:1693 read.c:1695
#, c-format
msgid ".fail %ld encountered"
msgstr ""
-#: read.c:1729
+#: read.c:1732
#, c-format
msgid ".fill size clamped to %d"
msgstr ""
-#: read.c:1734
+#: read.c:1737
msgid "size negative; .fill ignored"
msgstr ""
-#: read.c:1740
+#: read.c:1743
msgid "repeat < 0; .fill ignored"
msgstr ""
-#: read.c:1900
+#: read.c:1903
#, c-format
msgid "unrecognized .linkonce type `%s'"
msgstr ""
-#: read.c:1913 read.c:1939
+#: read.c:1916 read.c:1942
msgid ".linkonce is not supported for this object file format"
msgstr ""
-#: read.c:1935
+#: read.c:1938
#, c-format
msgid "bfd_set_section_flags: %s"
msgstr ""
-#: read.c:1990
+#: read.c:1993
msgid "missing size expression"
msgstr ""
-#: read.c:1996
+#: read.c:1999
#, c-format
msgid "BSS length (%d) < 0 ignored"
msgstr ""
-#: read.c:2012
+#: read.c:2015
#, c-format
msgid "error setting flags for \".sbss\": %s"
msgstr ""
-#: read.c:2035
+#: read.c:2038
msgid "expected comma after size"
msgstr ""
-#: read.c:2069
+#: read.c:2072
#, c-format
msgid "alignment too large; %d assumed"
msgstr ""
-#: read.c:2074
+#: read.c:2077
msgid "alignment negative; 0 assumed"
msgstr ""
-#: read.c:2340
+#: read.c:2342
#, c-format
msgid "attempt to redefine pseudo-op `%s' ignored"
msgstr ""
-#: read.c:2406
+#: read.c:2408
#, c-format
msgid "invalid segment \"%s\""
msgstr ""
-#: read.c:2414
+#: read.c:2416
msgid "only constant offsets supported in absolute section"
msgstr ""
-#: read.c:2454
+#: read.c:2456
msgid "MRI style ORG pseudo-op not supported"
msgstr ""
-#: read.c:2611
+#: read.c:2613
#, c-format
msgid "unrecognized section type `%s'"
msgstr ""
-#: read.c:2625
+#: read.c:2627
msgid "absolute sections are not supported"
msgstr ""
-#: read.c:2640
+#: read.c:2642
#, c-format
msgid "unrecognized section command `%s'"
msgstr ""
-#: read.c:2706
+#: read.c:2708
msgid ".endr encountered without preceeding .rept, .irc, or .irp"
msgstr ""
-#: read.c:2738
+#: read.c:2740
#, c-format
msgid "%s without %s"
msgstr ""
-#: read.c:2947
+#: read.c:2949
msgid "unsupported variable size or fill value"
msgstr ""
-#: read.c:2972
+#: read.c:2974
msgid ".space repeat count is zero, ignored"
msgstr ""
-#: read.c:2974
+#: read.c:2976
msgid ".space repeat count is negative, ignored"
msgstr ""
-#: read.c:3003
+#: read.c:3005
msgid "space allocation too complex in absolute section"
msgstr ""
-#: read.c:3009
+#: read.c:3011
msgid "space allocation too complex in common section"
msgstr ""
-#: read.c:3097 read.c:4180
+#: read.c:3099 read.c:4190
#, c-format
msgid "bad floating literal: %s"
msgstr ""
-#: read.c:3170
+#: read.c:3172
#, c-format
msgid "rest of line ignored; first ignored character is `%c'"
msgstr ""
-#: read.c:3173
+#: read.c:3175
#, c-format
msgid "rest of line ignored; first ignored character valued 0x%x"
msgstr ""
-#: read.c:3226
+#: read.c:3228
msgid "missing expression"
msgstr ""
-#: read.c:3397
+#: read.c:3404
msgid "rva without symbol"
msgstr ""
-#: read.c:3521
+#: read.c:3530
msgid "attempt to store value in absolute section"
msgstr ""
-#: read.c:3559 read.c:4458
+#: read.c:3568 read.c:4468
msgid "zero assumed for missing expression"
msgstr ""
-#: read.c:3571 read.c:4470 write.c:290
+#: read.c:3580 read.c:4480 write.c:322
msgid "register value used as expression"
msgstr ""
#. Leading bits contain both 0s & 1s.
-#: read.c:3661
+#: read.c:3671
#, c-format
msgid "value 0x%lx truncated to 0x%lx"
msgstr ""
-#: read.c:3677
+#: read.c:3687
#, c-format
msgid "bignum truncated to %d bytes"
msgstr ""
-#: read.c:3844
+#: read.c:3854
msgid "using a bit field width of zero"
msgstr ""
-#: read.c:3852
+#: read.c:3862
#, c-format
msgid "field width \"%s\" too complex for a bitfield"
msgstr ""
-#: read.c:3860
+#: read.c:3870
#, c-format
msgid "field width %lu too big to fit in %d bytes: truncated to %d bits"
msgstr ""
-#: read.c:3882
+#: read.c:3892
#, c-format
msgid "field value \"%s\" too complex for a bitfield"
msgstr ""
-#: read.c:4008 read.c:4202
+#: read.c:4018 read.c:4212
msgid "unresolvable or nonpositive repeat count; using 1"
msgstr ""
-#: read.c:4059
+#: read.c:4069
#, c-format
msgid "unknown floating type type '%c'"
msgstr ""
-#: read.c:4081
+#: read.c:4091
msgid "floating point constant too large"
msgstr ""
-#: read.c:4571
+#: read.c:4581
msgid "strings must be placed into a section"
msgstr ""
-#: read.c:4621
+#: read.c:4631
msgid "expected <nn>"
msgstr ""
#. To be compatible with BSD 4.2 as: give the luser a linefeed!!
-#: read.c:4654 read.c:4740
+#: read.c:4664 read.c:4750
msgid "unterminated string; newline inserted"
msgstr ""
-#: read.c:4748
+#: read.c:4758
msgid "bad escaped character in string"
msgstr ""
-#: read.c:4774
+#: read.c:4784
msgid "expected address expression"
msgstr ""
-#: read.c:4794
+#: read.c:4804
#, c-format
msgid "symbol \"%s\" undefined; zero assumed"
msgstr ""
-#: read.c:4797
+#: read.c:4807
msgid "some symbol undefined; zero assumed"
msgstr ""
-#: read.c:4815
+#: read.c:4824
msgid "bad or irreducible absolute expression"
msgstr ""
-#: read.c:4850
+#: read.c:4867
msgid "this string may not contain '\\0'"
msgstr ""
-#: read.c:4887
+#: read.c:4904
msgid "missing string"
msgstr ""
-#: read.c:5010
+#: read.c:5027
#, c-format
msgid ".incbin count zero, ignoring `%s'"
msgstr ""
-#: read.c:5036
+#: read.c:5053
#, c-format
msgid "file not found: %s"
msgstr ""
-#: read.c:5050
+#: read.c:5067
#, c-format
msgid "seek to end of .incbin file failed `%s'"
msgstr ""
-#: read.c:5061
+#: read.c:5078
#, c-format
msgid "skip (%ld) + count (%ld) larger than file size (%ld)"
msgstr ""
-#: read.c:5068
+#: read.c:5085
#, c-format
msgid "could not skip to %ld in file `%s'"
msgstr ""
-#: read.c:5077
+#: read.c:5094
#, c-format
msgid "truncated file `%s', %ld of %ld bytes read"
msgstr ""
-#: read.c:5240
+#: read.c:5257
msgid "missing .func"
msgstr ""
-#: read.c:5257
+#: read.c:5274
msgid ".endfunc missing for previous .func"
msgstr ""
@@ -10715,7 +11290,7 @@ msgstr ""
msgid ".stab%c: description field '%x' too big, try a different debug format"
msgstr ""
-#: stabs.c:435
+#: stabs.c:433
msgid "comma missing in .xstabs"
msgstr ""
@@ -10724,160 +11299,169 @@ msgstr ""
msgid "attempt to switch to nonexistent segment \"%s\""
msgstr ""
-#: symbols.c:446
+#: symbols.c:318
+#, c-format
+msgid "cannot define symbol `%s' in absolute section"
+msgstr ""
+
+#: symbols.c:452
#, c-format
msgid "symbol `%s' is already defined as \"%s\"/%s%ld"
msgstr ""
-#: symbols.c:523 symbols.c:530
+#: symbols.c:529 symbols.c:536
#, c-format
msgid "inserting \"%s\" into symbol table failed: %s"
msgstr ""
-#: symbols.c:880
+#: symbols.c:874 symbols.c:878
#, c-format
-msgid "symbol definition loop encountered at `%s'"
+msgid "undefined symbol `%s' in operation"
msgstr ""
-#: symbols.c:1094 symbols.c:1098
+#: symbols.c:885
#, c-format
-msgid "undefined symbol `%s' in operation"
+msgid "invalid sections for operation on `%s' and `%s'"
msgstr ""
-#: symbols.c:1103
-msgid "invalid section for operation"
+#: symbols.c:889
+#, c-format
+msgid "invalid section for operation on `%s'"
msgstr ""
-#: symbols.c:1108 symbols.c:1112
+#: symbols.c:897 symbols.c:900
#, c-format
msgid "undefined symbol `%s' in operation setting `%s'"
msgstr ""
-#: symbols.c:1117
+#: symbols.c:907
#, c-format
-msgid "invalid section for operation setting `%s'"
+msgid "invalid sections for operation on `%s' and `%s' setting `%s'"
msgstr ""
-#: symbols.c:1138
+#: symbols.c:911
+#, c-format
+msgid "invalid section for operation on `%s' setting `%s'"
+msgstr ""
+
+#: symbols.c:964
+#, c-format
+msgid "symbol definition loop encountered at `%s'"
+msgstr ""
+
+#: symbols.c:1193
#, c-format
msgid "division by zero when setting `%s'"
msgstr ""
-#: symbols.c:1225 write.c:2003
+#: symbols.c:1280 write.c:2008
#, c-format
msgid "can't resolve value for symbol `%s'"
msgstr ""
-#: symbols.c:1619
+#: symbols.c:1674
#, c-format
msgid "\"%d\" (instance number %d of a %s label)"
msgstr ""
-#: symbols.c:1656
+#: symbols.c:1711
#, c-format
msgid "attempt to get value of unresolved symbol `%s'"
msgstr ""
-#: symbols.c:1892
+#: symbols.c:1971
msgid "section symbols are already global"
msgstr ""
-#: write.c:176
+#: symbols.c:2014
+#, c-format
+msgid "Accessing function `%s' as thread-local object"
+msgstr ""
+
+#: symbols.c:2018
+#, c-format
+msgid "Accessing `%s' as thread-local object"
+msgstr ""
+
+#: write.c:215
#, c-format
msgid "field fx_size too small to hold %d"
msgstr ""
-#: write.c:317
+#: write.c:349
msgid "rva not supported"
msgstr ""
-#: write.c:525
+#: write.c:570
#, c-format
msgid "attempt to .org/.space backwards? (%ld)"
msgstr ""
-#: write.c:1041
+#: write.c:1002 write.c:1074
msgid "relocation out of range"
msgstr ""
-#: write.c:1044
+#: write.c:1005 write.c:1077
#, c-format
msgid "%s:%u: bad return from bfd_install_relocation: %x"
msgstr ""
-#: write.c:1088
+#: write.c:1057
msgid "internal error: fixup not contained within frag"
msgstr ""
-#: write.c:1104
-#, c-format
-msgid "%s:%u: bad return from bfd_install_relocation"
-msgstr ""
-
-#: write.c:1191 write.c:1215
+#: write.c:1164 write.c:1188
#, c-format
msgid "FATAL: Can't write %s"
msgstr ""
-#: write.c:1247
+#: write.c:1220
msgid "cannot write to output file"
msgstr ""
-#: write.c:1486
+#: write.c:1477
#, c-format
msgid "%d error%s, %d warning%s, generating bad object file"
msgstr ""
-#: write.c:1493
+#: write.c:1484
#, c-format
msgid "%d error%s, %d warning%s, no object file generated"
msgstr ""
-#: write.c:1941
+#: write.c:1945
#, c-format
msgid "local label `%s' is not defined"
msgstr ""
-#: write.c:2239
+#: write.c:2244
#, c-format
msgid "alignment padding (%lu bytes) not a multiple of %ld"
msgstr ""
-#: write.c:2356
+#: write.c:2361
#, c-format
msgid ".word %s-%s+%s didn't fit"
msgstr ""
-#: write.c:2441
-msgid "attempt to .org backwards"
+#: write.c:2446
+msgid "attempt to move .org backwards"
msgstr ""
-#: write.c:2469
+#: write.c:2474
msgid ".space specifies non-absolute value"
msgstr ""
-#: write.c:2476
+#: write.c:2481
msgid ".space or .fill with negative value, ignored"
msgstr ""
-#: write.c:2650
-#, c-format
-msgid "negative of non-absolute symbol `%s'"
-msgstr ""
-
-#: write.c:2744
-#, c-format
-msgid ""
-"subtraction of two symbols in different sections `%s' {%s section} - `%s' {%"
-"s section} at file address %s"
-msgstr ""
-
-#: write.c:2880
+#: write.c:2773
#, c-format
msgid "value of %s too large for field of %d bytes at %s"
msgstr ""
-#: write.c:2892
+#: write.c:2785
#, c-format
msgid "signed .word overflow; switch may be too large; %ld at 0x%lx"
msgstr ""
diff --git a/contrib/binutils/gas/read.c b/contrib/binutils/gas/read.c
index 934d270..f97bd25 100644
--- a/contrib/binutils/gas/read.c
+++ b/contrib/binutils/gas/read.c
@@ -1,6 +1,6 @@
/* read.c - read a source file -
Copyright 1986, 1987, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997,
- 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+ 1998, 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -32,7 +32,7 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
grow when we do 4361 style flonums. */
#define MAXIMUM_NUMBER_OF_CHARS_FOR_FLOAT (16)
-/* Routines that read assembler source text to build spagetti in memory.
+/* Routines that read assembler source text to build spaghetti in memory.
Another group of these functions is in the expr.c module. */
#include "as.h"
@@ -43,6 +43,7 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
#include "obstack.h"
#include "listing.h"
#include "ecoff.h"
+#include "dw2gencfi.h"
#ifndef TC_START_LABEL
#define TC_START_LABEL(x,y) (x == ':')
@@ -50,17 +51,17 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
/* Set by the object-format or the target. */
#ifndef TC_IMPLICIT_LCOMM_ALIGNMENT
-#define TC_IMPLICIT_LCOMM_ALIGNMENT(SIZE, P2VAR) \
+#define TC_IMPLICIT_LCOMM_ALIGNMENT(SIZE, P2VAR) \
do \
- { \
- if ((SIZE) >= 8) \
- (P2VAR) = 3; \
- else if ((SIZE) >= 4) \
- (P2VAR) = 2; \
- else if ((SIZE) >= 2) \
- (P2VAR) = 1; \
- else \
- (P2VAR) = 0; \
+ { \
+ if ((SIZE) >= 8) \
+ (P2VAR) = 3; \
+ else if ((SIZE) >= 4) \
+ (P2VAR) = 2; \
+ else if ((SIZE) >= 2) \
+ (P2VAR) = 1; \
+ else \
+ (P2VAR) = 0; \
} \
while (0)
#endif
@@ -154,7 +155,7 @@ char is_end_of_line[256] = {
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 /* */
};
-#ifdef IGNORE_OPCODE_CASE
+#ifndef TC_CASE_SENSITIVE
char original_case_string[128];
#endif
@@ -168,10 +169,6 @@ static char *buffer_limit; /*->1 + last char in buffer. */
internals manual. */
int target_big_endian = TARGET_BYTES_BIG_ENDIAN;
-static char *old_buffer; /* JF a hack. */
-static char *old_input;
-static char *old_limit;
-
/* Variables for handling include file directory table. */
/* Table of pointers to directories to search for .include's. */
@@ -217,29 +214,16 @@ static int dwarf_file_string;
#endif
#endif
-static void cons_worker PARAMS ((int, int));
-static int scrub_from_string PARAMS ((char *, int));
-static void do_align PARAMS ((int, char *, int, int));
-static void s_align PARAMS ((int, int));
-static void s_lcomm_internal PARAMS ((int, int));
-static int hex_float PARAMS ((int, char *));
-static inline int sizeof_sleb128 PARAMS ((offsetT));
-static inline int sizeof_uleb128 PARAMS ((valueT));
-static inline int output_sleb128 PARAMS ((char *, offsetT));
-static inline int output_uleb128 PARAMS ((char *, valueT));
-static inline int output_big_sleb128 PARAMS ((char *, LITTLENUM_TYPE *, int));
-static inline int output_big_uleb128 PARAMS ((char *, LITTLENUM_TYPE *, int));
-static int output_big_leb128 PARAMS ((char *, LITTLENUM_TYPE *, int, int));
-static void do_org PARAMS ((segT, expressionS *, int));
-char *demand_copy_string PARAMS ((int *lenP));
-static segT get_segmented_expression PARAMS ((expressionS *expP));
-static segT get_known_segmented_expression PARAMS ((expressionS * expP));
-static void pobegin PARAMS ((void));
-static int get_line_sb PARAMS ((sb *));
-static void generate_file_debug PARAMS ((void));
+static void do_align (int, char *, int, int);
+static void s_align (int, int);
+static int hex_float (int, char *);
+static segT get_known_segmented_expression (expressionS * expP);
+static void pobegin (void);
+static int get_line_sb (sb *);
+static void generate_file_debug (void);
void
-read_begin ()
+read_begin (void)
{
const char *p;
@@ -433,8 +417,7 @@ static int pop_override_ok = 0;
static const char *pop_table_name;
void
-pop_insert (table)
- const pseudo_typeS *table;
+pop_insert (const pseudo_typeS *table)
{
const char *errtxt;
const pseudo_typeS *pop;
@@ -455,8 +438,12 @@ pop_insert (table)
#define obj_pop_insert() pop_insert(obj_pseudo_table)
#endif
+#ifndef cfi_pop_insert
+#define cfi_pop_insert() pop_insert(cfi_pseudo_table)
+#endif
+
static void
-pobegin ()
+pobegin (void)
{
po_hash = hash_new ();
@@ -472,6 +459,12 @@ pobegin ()
/* Now portable ones. Skip any that we've seen already. */
pop_table_name = "standard";
pop_insert (potable);
+
+#ifdef TARGET_USE_CFIPOP
+ pop_table_name = "cfi";
+ pop_override_ok = 1;
+ cfi_pop_insert ();
+#endif
}
#define HANDLE_CONDITIONAL_ASSEMBLY() \
@@ -490,9 +483,7 @@ static char *scrub_string;
static char *scrub_string_end;
static int
-scrub_from_string (buf, buflen)
- char *buf;
- int buflen;
+scrub_from_string (char *buf, int buflen)
{
int copy;
@@ -507,8 +498,7 @@ scrub_from_string (buf, buflen)
/* We read the file, putting things into a web that represents what we
have been reading. */
void
-read_a_source_file (name)
- char *name;
+read_a_source_file (char *name)
{
register char c;
register char *s; /* String of symbol, '\0' appended. */
@@ -533,9 +523,7 @@ read_a_source_file (name)
while ((buffer_limit = input_scrub_next_buffer (&input_line_pointer)) != 0)
{ /* We have another line to parse. */
know (buffer_limit[-1] == '\n'); /* Must have a sentinel. */
- contin: /* JF this goto is my fault I admit it.
- Someone brave please re-write the whole
- input section here? Pleeze??? */
+
while (input_line_pointer < buffer_limit)
{
/* We have more of this buffer to parse. */
@@ -596,8 +584,8 @@ read_a_source_file (name)
}
/* In MRI mode, we need to handle the MACRO
- pseudo-op specially: we don't want to put the
- symbol in the symbol table. */
+ pseudo-op specially: we don't want to put the
+ symbol in the symbol table. */
if (!mri_line_macro
#ifdef TC_START_LABEL_WITHOUT_COLON
&& TC_START_LABEL_WITHOUT_COLON(c,
@@ -618,7 +606,7 @@ read_a_source_file (name)
}
}
- /* We are at the begining of a line, or similar place.
+ /* We are at the beginning of a line, or similar place.
We expect a well-formed assembler statement.
A "symbol-name:" is a statement.
@@ -680,10 +668,10 @@ read_a_source_file (name)
c = get_symbol_end (); /* name's delimiter. */
/* C is character after symbol.
- That character's place in the input line is now '\0'.
- S points to the beginning of the symbol.
- [In case of pseudo-op, s->'.'.]
- Input_line_pointer->'\0' where c was. */
+ That character's place in the input line is now '\0'.
+ S points to the beginning of the symbol.
+ [In case of pseudo-op, s->'.'.]
+ Input_line_pointer->'\0' where c was. */
if (TC_START_LABEL (c, input_line_pointer))
{
if (flag_m68k_mri)
@@ -710,6 +698,9 @@ read_a_source_file (name)
line_label = colon (s); /* User-defined label. */
/* Put ':' back for error messages' sake. */
*input_line_pointer++ = ':';
+#ifdef tc_check_label
+ tc_check_label (line_label);
+#endif
/* Input_line_pointer->after ':'. */
SKIP_WHITESPACE ();
}
@@ -729,7 +720,7 @@ read_a_source_file (name)
/* Expect pseudo-op or machine instruction. */
pop = NULL;
-#ifdef IGNORE_OPCODE_CASE
+#ifndef TC_CASE_SENSITIVE
{
char *s2 = s;
@@ -746,7 +737,7 @@ read_a_source_file (name)
if (NO_PSEUDO_DOT || flag_m68k_mri)
{
/* The MRI assembler and the m88k use pseudo-ops
- without a period. */
+ without a period. */
pop = (pseudo_typeS *) hash_find (po_hash, s);
if (pop != NULL && pop->poc_handler == NULL)
pop = NULL;
@@ -757,16 +748,18 @@ read_a_source_file (name)
{
/* PSEUDO - OP.
- WARNING: c has next char, which may be end-of-line.
- We lookup the pseudo-op table with s+1 because we
- already know that the pseudo-op begins with a '.'. */
+ WARNING: c has next char, which may be end-of-line.
+ We lookup the pseudo-op table with s+1 because we
+ already know that the pseudo-op begins with a '.'. */
if (pop == NULL)
pop = (pseudo_typeS *) hash_find (po_hash, s + 1);
+ if (pop && !pop->poc_handler)
+ pop = NULL;
/* In MRI mode, we may need to insert an
- automatic alignment directive. What a hack
- this is. */
+ automatic alignment directive. What a hack
+ this is. */
if (mri_pending_align
&& (pop == NULL
|| !((pop->poc_handler == cons
@@ -813,8 +806,8 @@ read_a_source_file (name)
input_line_pointer++;
/* Input_line is restored.
- Input_line_pointer->1st non-blank char
- after pseudo-operation. */
+ Input_line_pointer->1st non-blank char
+ after pseudo-operation. */
(*pop->poc_handler) (pop->poc_val);
/* If that was .end, just get out now. */
@@ -862,7 +855,7 @@ read_a_source_file (name)
const char *err;
macro_entry *macro;
- if (check_macro (s, &out, '\0', &err, &macro))
+ if (check_macro (s, &out, &err, &macro))
{
if (err != NULL)
as_bad ("%s", err);
@@ -950,6 +943,7 @@ read_a_source_file (name)
if (c && strchr (line_comment_chars, c))
{ /* Its a comment. Better say APP or NO_APP. */
+ sb sbuf;
char *ends;
char *new_buf;
char *new_tmp;
@@ -962,6 +956,7 @@ read_a_source_file (name)
continue; /* We ignore it */
s += 4;
+ sb_new (&sbuf);
ends = strstr (s, "#NO_APP\n");
if (!ends)
@@ -972,7 +967,7 @@ read_a_source_file (name)
/* The end of the #APP wasn't in this buffer. We
keep reading in buffers until we find the #NO_APP
that goes with this #APP There is one. The specs
- guarentee it... */
+ guarantee it... */
tmp_len = buffer_limit - s;
tmp_buf = xmalloc (tmp_len + 1);
memcpy (tmp_buf, s, tmp_len);
@@ -1023,7 +1018,7 @@ read_a_source_file (name)
if (size < space)
{
- new_tmp += size;
+ new_tmp[size] = 0;
break;
}
@@ -1034,13 +1029,19 @@ read_a_source_file (name)
if (tmp_buf)
free (tmp_buf);
- old_buffer = buffer;
- old_input = input_line_pointer;
- old_limit = buffer_limit;
- buffer = new_buf;
- input_line_pointer = new_buf;
- buffer_limit = new_tmp;
+ /* We've "scrubbed" input to the preferred format. In the
+ process we may have consumed the whole of the remaining
+ file (and included files). We handle this formatted
+ input similar to that of macro expansion, letting
+ actual macro expansion (possibly nested) and other
+ input expansion work. Beware that in messages, line
+ numbers and possibly file names will be incorrect. */
+ sb_add_string (&sbuf, new_buf);
+ input_scrub_include_sb (&sbuf, input_line_pointer, 0);
+ sb_kill (&sbuf);
+ buffer_limit = input_scrub_next_buffer (&input_line_pointer);
+ free (new_buf);
continue;
}
@@ -1052,26 +1053,12 @@ read_a_source_file (name)
#endif
input_line_pointer--;
/* Report unknown char as ignored. */
- ignore_rest_of_line ();
+ demand_empty_rest_of_line ();
}
#ifdef md_after_pass_hook
md_after_pass_hook ();
#endif
-
- if (old_buffer)
- {
- free (buffer);
- bump_line_counters ();
- if (old_input != 0)
- {
- buffer = old_buffer;
- input_line_pointer = old_input;
- buffer_limit = old_limit;
- old_buffer = 0;
- goto contin;
- }
- }
}
quit:
@@ -1099,8 +1086,7 @@ read_a_source_file (name)
for the m68k MRI assembler. */
char *
-mri_comment_field (stopcp)
- char *stopcp;
+mri_comment_field (char *stopcp)
{
char *s;
#ifdef TC_M68K
@@ -1131,9 +1117,7 @@ mri_comment_field (stopcp)
/* Skip to the end of an MRI comment field. */
void
-mri_comment_end (stop, stopc)
- char *stop;
- int stopc;
+mri_comment_end (char *stop, int stopc)
{
know (flag_mri);
@@ -1144,8 +1128,7 @@ mri_comment_end (stop, stopc)
}
void
-s_abort (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_abort (int ignore ATTRIBUTE_UNUSED)
{
as_fatal (_(".abort detected. Abandoning ship."));
}
@@ -1157,11 +1140,7 @@ s_abort (ignore)
or 0 if there is no maximum. */
static void
-do_align (n, fill, len, max)
- int n;
- char *fill;
- int len;
- int max;
+do_align (int n, char *fill, int len, int max)
{
if (now_seg == absolute_section)
{
@@ -1197,7 +1176,7 @@ do_align (n, fill, len, max)
}
#ifdef md_do_align
- just_record_alignment:
+ just_record_alignment: ATTRIBUTE_UNUSED_LABEL
#endif
record_alignment (now_seg, n - OCTETS_PER_BYTE_POWER);
@@ -1209,9 +1188,7 @@ do_align (n, fill, len, max)
interpreted as the byte boundary, rather than the power of 2. */
static void
-s_align (arg, bytes_p)
- int arg;
- int bytes_p;
+s_align (int arg, int bytes_p)
{
register unsigned int align;
char *stop = NULL;
@@ -1326,8 +1303,7 @@ s_align (arg, bytes_p)
align to a 4 byte boundary. */
void
-s_align_bytes (arg)
- int arg;
+s_align_bytes (int arg)
{
s_align (arg, 1);
}
@@ -1336,23 +1312,23 @@ s_align_bytes (arg)
to a 2**4 boundary. */
void
-s_align_ptwo (arg)
- int arg;
+s_align_ptwo (int arg)
{
s_align (arg, 0);
}
-void
-s_comm (ignore)
- int ignore ATTRIBUTE_UNUSED;
+symbolS *
+s_comm_internal (int param,
+ symbolS *(*comm_parse_extra) (int, symbolS *, addressT))
{
- register char *name;
- register char c;
- register char *p;
- offsetT temp;
- register symbolS *symbolP;
+ char *name;
+ char c;
+ char *p;
+ offsetT temp, size;
+ symbolS *symbolP = NULL;
char *stop = NULL;
char stopc;
+ expressionS exp;
if (flag_mri)
stop = mri_comment_field (&stopc);
@@ -1367,82 +1343,90 @@ s_comm (ignore)
{
as_bad (_("expected symbol name"));
discard_rest_of_line ();
- return;
+ goto out;
}
SKIP_WHITESPACE ();
- if (*input_line_pointer != ',')
+ /* Accept an optional comma after the name. The comma used to be
+ required, but Irix 5 cc does not generate it for .lcomm. */
+ if (*input_line_pointer == ',')
+ input_line_pointer++;
+
+ *p = 0;
+ temp = get_absolute_expr (&exp);
+ size = temp;
+#ifdef BFD_ASSEMBLER
+ size &= ((offsetT) 2 << (stdoutput->arch_info->bits_per_address - 1)) - 1;
+#endif
+ if (exp.X_op == O_absent)
{
- *p = 0;
- as_bad (_("expected comma after \"%s\""), name);
+ as_bad (_("missing size expression"));
*p = c;
ignore_rest_of_line ();
- if (flag_mri)
- mri_comment_end (stop, stopc);
- return;
+ goto out;
}
-
- input_line_pointer++; /* skip ',' */
-
- if ((temp = get_absolute_expression ()) < 0)
+ else if (temp != size || !exp.X_unsigned)
{
- as_warn (_(".COMMon length (%ld) < 0 ignored"), (long) temp);
+ as_warn (_("size (%ld) out of range, ignored"), (long) temp);
+ *p = c;
ignore_rest_of_line ();
- if (flag_mri)
- mri_comment_end (stop, stopc);
- return;
+ goto out;
}
- *p = 0;
symbolP = symbol_find_or_make (name);
- *p = c;
-
if (S_IS_DEFINED (symbolP) && !S_IS_COMMON (symbolP))
{
- as_bad (_("symbol `%s' is already defined"),
- S_GET_NAME (symbolP));
+ symbolP = NULL;
+ as_bad (_("symbol `%s' is already defined"), name);
+ *p = c;
ignore_rest_of_line ();
- if (flag_mri)
- mri_comment_end (stop, stopc);
- return;
+ goto out;
}
- if (S_GET_VALUE (symbolP))
- {
- if (S_GET_VALUE (symbolP) != (valueT) temp)
- as_bad (_("length of .comm \"%s\" is already %ld; not changing to %ld"),
- S_GET_NAME (symbolP),
- (long) S_GET_VALUE (symbolP),
- (long) temp);
- }
+ size = S_GET_VALUE (symbolP);
+ if (size == 0)
+ size = temp;
+ else if (size != temp)
+ as_warn (_("size of \"%s\" is already %ld; not changing to %ld"),
+ name, (long) size, (long) temp);
+
+ *p = c;
+ if (comm_parse_extra != NULL)
+ symbolP = (*comm_parse_extra) (param, symbolP, size);
else
{
- S_SET_VALUE (symbolP, (valueT) temp);
+ S_SET_VALUE (symbolP, (valueT) size);
S_SET_EXTERNAL (symbolP);
- }
#ifdef OBJ_VMS
- {
- extern int flag_one;
- if (!temp || !flag_one)
- S_GET_OTHER(symbolP) = const_flag;
- }
-#endif /* not OBJ_VMS */
- know (symbolP->sy_frag == &zero_address_frag);
+ {
+ extern int flag_one;
+ if (size == 0 || !flag_one)
+ S_GET_OTHER (symbolP) = const_flag;
+ }
+#endif
+ }
+ know (symbolP == NULL || symbolP->sy_frag == &zero_address_frag);
demand_empty_rest_of_line ();
-
+ out:
if (flag_mri)
mri_comment_end (stop, stopc);
-} /* s_comm() */
+ return symbolP;
+}
+
+void
+s_comm (int ignore)
+{
+ s_comm_internal (ignore, NULL);
+}
/* The MRI COMMON pseudo-op. We handle this by creating a common
symbol with the appropriate name. We make s_space do the right
thing by increasing the size. */
void
-s_mri_common (small)
- int small ATTRIBUTE_UNUSED;
+s_mri_common (int small ATTRIBUTE_UNUSED)
{
char *name;
char c;
@@ -1541,8 +1525,7 @@ s_mri_common (small)
}
void
-s_data (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_data (int ignore ATTRIBUTE_UNUSED)
{
segT section;
register int temp;
@@ -1572,8 +1555,7 @@ s_data (ignore)
.file. */
void
-s_app_file_string (file)
- char *file;
+s_app_file_string (char *file)
{
#ifdef LISTING
if (listing)
@@ -1586,8 +1568,7 @@ s_app_file_string (file)
}
void
-s_app_file (appfile)
- int appfile;
+s_app_file (int appfile)
{
register char *s;
int length;
@@ -1602,7 +1583,7 @@ s_app_file (appfile)
= (!new_logical_line (s, appfile ? -2 : -1) && appfile);
/* In MRI mode, the preprocessor may have inserted an extraneous
- backquote. */
+ backquote. */
if (flag_m68k_mri
&& *input_line_pointer == '\''
&& is_end_of_line[(unsigned char) input_line_pointer[1]])
@@ -1620,8 +1601,7 @@ s_app_file (appfile)
pseudo-ops. */
void
-s_app_line (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_app_line (int ignore ATTRIBUTE_UNUSED)
{
int l;
@@ -1647,13 +1627,12 @@ s_app_line (ignore)
read_a_source_file. */
void
-s_end (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_end (int ignore ATTRIBUTE_UNUSED)
{
if (flag_mri)
{
/* The MRI assembler permits the start symbol to follow .end,
- but we don't support that. */
+ but we don't support that. */
SKIP_WHITESPACE ();
if (!is_end_of_line[(unsigned char) *input_line_pointer]
&& *input_line_pointer != '*'
@@ -1665,8 +1644,7 @@ s_end (ignore)
/* Handle the .err pseudo-op. */
void
-s_err (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_err (int ignore ATTRIBUTE_UNUSED)
{
as_bad (_(".err encountered"));
demand_empty_rest_of_line ();
@@ -1675,8 +1653,7 @@ s_err (ignore)
/* Handle the MRI fail pseudo-op. */
void
-s_fail (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_fail (int ignore ATTRIBUTE_UNUSED)
{
offsetT temp;
char *stop = NULL;
@@ -1698,8 +1675,7 @@ s_fail (ignore)
}
void
-s_fill (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_fill (int ignore ATTRIBUTE_UNUSED)
{
expressionS rep_exp;
long size = 1;
@@ -1779,26 +1755,25 @@ s_fill (ignore)
memset (p, 0, (unsigned int) size);
/* The magic number BSD_FILL_SIZE_CROCK_4 is from BSD 4.2 VAX
- flavoured AS. The following bizarre behaviour is to be
- compatible with above. I guess they tried to take up to 8
- bytes from a 4-byte expression and they forgot to sign
- extend. */
+ flavoured AS. The following bizarre behaviour is to be
+ compatible with above. I guess they tried to take up to 8
+ bytes from a 4-byte expression and they forgot to sign
+ extend. */
#define BSD_FILL_SIZE_CROCK_4 (4)
md_number_to_chars (p, (valueT) fill,
(size > BSD_FILL_SIZE_CROCK_4
? BSD_FILL_SIZE_CROCK_4
: (int) size));
/* Note: .fill (),0 emits no frag (since we are asked to .fill 0 bytes)
- but emits no error message because it seems a legal thing to do.
- It is a degenerate case of .fill but could be emitted by a
+ but emits no error message because it seems a legal thing to do.
+ It is a degenerate case of .fill but could be emitted by a
compiler. */
}
demand_empty_rest_of_line ();
}
void
-s_globl (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_globl (int ignore ATTRIBUTE_UNUSED)
{
char *name;
int c;
@@ -1838,8 +1813,7 @@ s_globl (ignore)
/* Handle the MRI IRP and IRPC pseudo-ops. */
void
-s_irp (irpc)
- int irpc;
+s_irp (int irpc)
{
char *file;
unsigned int line;
@@ -1855,7 +1829,7 @@ s_irp (irpc)
sb_new (&out);
- err = expand_irp (irpc, 0, &s, &out, get_line_sb, '\0');
+ err = expand_irp (irpc, 0, &s, &out, get_line_sb);
if (err != NULL)
as_bad_where (file, line, "%s", err);
@@ -1872,8 +1846,7 @@ s_irp (irpc)
which is what to do about duplicates. */
void
-s_linkonce (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_linkonce (int ignore ATTRIBUTE_UNUSED)
{
enum linkonce_type type;
@@ -1943,67 +1916,20 @@ s_linkonce (ignore)
demand_empty_rest_of_line ();
}
-static void
-s_lcomm_internal (needs_align, bytes_p)
- /* 1 if this was a ".bss" directive, which may require a 3rd argument
- (alignment); 0 if it was an ".lcomm" (2 args only). */
- int needs_align;
- /* 1 if the alignment value should be interpreted as the byte boundary,
- rather than the power of 2. */
- int bytes_p;
+void
+bss_alloc (symbolS *symbolP, addressT size, int align)
{
- register char *name;
- register char c;
- register char *p;
- register int temp;
- register symbolS *symbolP;
+ char *pfrag;
segT current_seg = now_seg;
subsegT current_subseg = now_subseg;
- const int max_alignment = 15;
- int align = 0;
segT bss_seg = bss_section;
- name = input_line_pointer;
- c = get_symbol_end ();
- p = input_line_pointer;
- *p = c;
-
- if (name == p)
- {
- as_bad (_("expected symbol name"));
- discard_rest_of_line ();
- return;
- }
-
- SKIP_WHITESPACE ();
-
- /* Accept an optional comma after the name. The comma used to be
- required, but Irix 5 cc does not generate it. */
- if (*input_line_pointer == ',')
- {
- ++input_line_pointer;
- SKIP_WHITESPACE ();
- }
-
- if (is_end_of_line[(unsigned char) *input_line_pointer])
- {
- as_bad (_("missing size expression"));
- return;
- }
-
- if ((temp = get_absolute_expression ()) < 0)
- {
- as_warn (_("BSS length (%d) < 0 ignored"), temp);
- ignore_rest_of_line ();
- return;
- }
-
#if defined (TC_MIPS) || defined (TC_ALPHA)
if (OUTPUT_FLAVOR == bfd_target_ecoff_flavour
|| OUTPUT_FLAVOR == bfd_target_elf_flavour)
{
/* For MIPS and Alpha ECOFF or ELF, small objects are put in .sbss. */
- if ((unsigned) temp <= bfd_get_gp_size (stdoutput))
+ if (size <= bfd_get_gp_size (stdoutput))
{
bss_seg = subseg_new (".sbss", 1);
seg_info (bss_seg)->bss = 1;
@@ -2015,154 +1941,122 @@ s_lcomm_internal (needs_align, bytes_p)
}
}
#endif
+ subseg_set (bss_seg, 1);
- if (!needs_align)
+ if (align)
{
- TC_IMPLICIT_LCOMM_ALIGNMENT (temp, align);
-
- /* Still zero unless TC_IMPLICIT_LCOMM_ALIGNMENT set it. */
- if (align)
- record_alignment (bss_seg, align);
+ record_alignment (bss_seg, align);
+ frag_align (align, 0, 0);
}
- if (needs_align)
- {
- align = 0;
- SKIP_WHITESPACE ();
+ /* Detach from old frag. */
+ if (S_GET_SEGMENT (symbolP) == bss_seg)
+ symbol_get_frag (symbolP)->fr_symbol = NULL;
- if (*input_line_pointer != ',')
- {
- as_bad (_("expected comma after size"));
- ignore_rest_of_line ();
- return;
- }
+ symbol_set_frag (symbolP, frag_now);
+ pfrag = frag_var (rs_org, 1, 1, 0, symbolP, size, NULL);
+ *pfrag = 0;
- input_line_pointer++;
- SKIP_WHITESPACE ();
+#ifdef S_SET_SIZE
+ S_SET_SIZE (symbolP, size);
+#endif
+ S_SET_SEGMENT (symbolP, bss_seg);
- if (is_end_of_line[(unsigned char) *input_line_pointer])
- {
- as_bad (_("missing alignment"));
- return;
- }
+#ifdef OBJ_COFF
+ /* The symbol may already have been created with a preceding
+ ".globl" directive -- be careful not to step on storage class
+ in that case. Otherwise, set it to static. */
+ if (S_GET_STORAGE_CLASS (symbolP) != C_EXT)
+ S_SET_STORAGE_CLASS (symbolP, C_STAT);
+#endif /* OBJ_COFF */
- align = get_absolute_expression ();
+ subseg_set (current_seg, current_subseg);
+}
- if (bytes_p)
- {
- /* Convert to a power of 2. */
- if (align != 0)
- {
- unsigned int i;
+offsetT
+parse_align (int align_bytes)
+{
+ expressionS exp;
+ addressT align;
- for (i = 0; (align & 1) == 0; align >>= 1, ++i)
- ;
- if (align != 1)
- as_bad (_("alignment not a power of 2"));
- align = i;
- }
- }
+ SKIP_WHITESPACE ();
+ if (*input_line_pointer != ',')
+ {
+ no_align:
+ as_bad (_("expected alignment after size"));
+ ignore_rest_of_line ();
+ return -1;
+ }
- if (align > max_alignment)
- {
- align = max_alignment;
- as_warn (_("alignment too large; %d assumed"), align);
- }
- else if (align < 0)
- {
- align = 0;
- as_warn (_("alignment negative; 0 assumed"));
- }
+ input_line_pointer++;
+ SKIP_WHITESPACE ();
- record_alignment (bss_seg, align);
+ align = get_absolute_expr (&exp);
+ if (exp.X_op == O_absent)
+ goto no_align;
+
+ if (!exp.X_unsigned)
+ {
+ as_warn (_("alignment negative; 0 assumed"));
+ align = 0;
}
- else
+
+ if (align_bytes && align != 0)
{
- /* Assume some objects may require alignment on some systems. */
-#if defined (TC_ALPHA) && ! defined (VMS)
- if (temp > 1)
+ /* convert to a power of 2 alignment */
+ unsigned int alignp2 = 0;
+ while ((align & 1) == 0)
+ align >>= 1, ++alignp2;
+ if (align != 1)
{
- align = ffs (temp) - 1;
- if (temp % (1 << align))
- abort ();
+ as_bad (_("alignment not a power of 2"));
+ ignore_rest_of_line ();
+ return -1;
}
-#endif
+ align = alignp2;
}
+ return align;
+}
- *p = 0;
- symbolP = symbol_find_or_make (name);
- *p = c;
-
- if (
-#if (defined (OBJ_AOUT) || defined (OBJ_MAYBE_AOUT) \
- || defined (OBJ_BOUT) || defined (OBJ_MAYBE_BOUT))
-#ifdef BFD_ASSEMBLER
- (OUTPUT_FLAVOR != bfd_target_aout_flavour
- || (S_GET_OTHER (symbolP) == 0 && S_GET_DESC (symbolP) == 0)) &&
-#else
- (S_GET_OTHER (symbolP) == 0 && S_GET_DESC (symbolP) == 0) &&
-#endif
-#endif
- (S_GET_SEGMENT (symbolP) == bss_seg
- || (!S_IS_DEFINED (symbolP) && S_GET_VALUE (symbolP) == 0)))
- {
- char *pfrag;
-
- subseg_set (bss_seg, 1);
-
- if (align)
- frag_align (align, 0, 0);
-
- /* Detach from old frag. */
- if (S_GET_SEGMENT (symbolP) == bss_seg)
- symbol_get_frag (symbolP)->fr_symbol = NULL;
-
- symbol_set_frag (symbolP, frag_now);
- pfrag = frag_var (rs_org, 1, 1, (relax_substateT) 0, symbolP,
- (offsetT) temp, (char *) 0);
- *pfrag = 0;
-
- S_SET_SEGMENT (symbolP, bss_seg);
+/* Called from s_comm_internal after symbol name and size have been
+ parsed. NEEDS_ALIGN is 0 if it was an ".lcomm" (2 args only),
+ 1 if this was a ".bss" directive which has a 3rd argument
+ (alignment as a power of 2), or 2 if this was a ".bss" directive
+ with alignment in bytes. */
-#ifdef OBJ_COFF
- /* The symbol may already have been created with a preceding
- ".globl" directive -- be careful not to step on storage class
- in that case. Otherwise, set it to static. */
- if (S_GET_STORAGE_CLASS (symbolP) != C_EXT)
- {
- S_SET_STORAGE_CLASS (symbolP, C_STAT);
- }
-#endif /* OBJ_COFF */
+symbolS *
+s_lcomm_internal (int needs_align, symbolS *symbolP, addressT size)
+{
+ addressT align = 0;
-#ifdef S_SET_SIZE
- S_SET_SIZE (symbolP, temp);
-#endif
+ if (needs_align)
+ {
+ align = parse_align (needs_align - 1);
+ if (align == (addressT) -1)
+ return NULL;
}
else
- as_bad (_("symbol `%s' is already defined"), S_GET_NAME (symbolP));
-
- subseg_set (current_seg, current_subseg);
+ /* Assume some objects may require alignment on some systems. */
+ TC_IMPLICIT_LCOMM_ALIGNMENT (size, align);
- demand_empty_rest_of_line ();
+ bss_alloc (symbolP, size, align);
+ return symbolP;
}
void
-s_lcomm (needs_align)
- int needs_align;
+s_lcomm (int needs_align)
{
- s_lcomm_internal (needs_align, 0);
+ s_comm_internal (needs_align, s_lcomm_internal);
}
void
-s_lcomm_bytes (needs_align)
- int needs_align;
+s_lcomm_bytes (int needs_align)
{
- s_lcomm_internal (needs_align, 1);
+ s_comm_internal (needs_align * 2, s_lcomm_internal);
}
void
-s_lsym (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_lsym (int ignore ATTRIBUTE_UNUSED)
{
register char *name;
register char c;
@@ -2235,13 +2129,14 @@ s_lsym (ignore)
demand_empty_rest_of_line ();
}
-/* Read a line into an sb. */
+/* Read a line into an sb. Returns the character that ended the line
+ or zero if there are no more lines. */
static int
-get_line_sb (line)
- sb *line;
+get_line_sb (sb *line)
{
char quote1, quote2, inquote;
+ unsigned char c;
if (input_line_pointer[-1] == '\n')
bump_line_counters ();
@@ -2269,39 +2164,35 @@ get_line_sb (line)
inquote = '\0';
- while (!is_end_of_line[(unsigned char) *input_line_pointer]
- || (inquote != '\0' && *input_line_pointer != '\n'))
+ while ((c = * input_line_pointer ++) != 0
+ && (!is_end_of_line[c]
+ || (inquote != '\0' && c != '\n')))
{
- if (inquote == *input_line_pointer)
+ if (inquote == c)
inquote = '\0';
else if (inquote == '\0')
{
- if (*input_line_pointer == quote1)
+ if (c == quote1)
inquote = quote1;
- else if (*input_line_pointer == quote2)
+ else if (c == quote2)
inquote = quote2;
}
- sb_add_char (line, *input_line_pointer++);
- }
-
- while (input_line_pointer < buffer_limit
- && is_end_of_line[(unsigned char) *input_line_pointer])
- {
- if (input_line_pointer[-1] == '\n')
- bump_line_counters ();
- ++input_line_pointer;
+ sb_add_char (line, c);
}
- return 1;
+ /* Don't skip multiple end-of-line characters, because that breaks support
+ for the IA-64 stop bit (;;) which looks like two consecutive end-of-line
+ characters but isn't. Instead just skip one end of line character and
+ return the character skipped so that the caller can re-insert it if
+ necessary. */
+ return c;
}
-/* Define a macro. This is an interface to macro.c, which is shared
- between gas and gasp. */
+/* Define a macro. This is an interface to macro.c. */
void
-s_macro (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_macro (int ignore ATTRIBUTE_UNUSED)
{
char *file;
unsigned int line;
@@ -2348,8 +2239,7 @@ s_macro (ignore)
expansion. */
void
-s_mexit (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_mexit (int ignore ATTRIBUTE_UNUSED)
{
cond_exit_macro (macro_nest);
buffer_limit = input_scrub_next_buffer (&input_line_pointer);
@@ -2358,8 +2248,7 @@ s_mexit (ignore)
/* Switch in and out of MRI mode. */
void
-s_mri (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_mri (int ignore ATTRIBUTE_UNUSED)
{
int on, old_flag;
@@ -2397,10 +2286,7 @@ s_mri (ignore)
/* Handle changing the location counter. */
static void
-do_org (segment, exp, fill)
- segT segment;
- expressionS *exp;
- int fill;
+do_org (segT segment, expressionS *exp, int fill)
{
if (segment != now_seg && segment != absolute_section)
as_bad (_("invalid segment \"%s\""), segment_name (segment));
@@ -2435,8 +2321,7 @@ do_org (segment, exp, fill)
}
void
-s_org (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_org (int ignore ATTRIBUTE_UNUSED)
{
register segT segment;
expressionS exp;
@@ -2491,8 +2376,7 @@ s_org (ignore)
flags will be set in the section. */
void
-s_mri_sect (type)
- char *type ATTRIBUTE_UNUSED;
+s_mri_sect (char *type ATTRIBUTE_UNUSED)
{
#ifdef TC_M68K
@@ -2656,22 +2540,21 @@ s_mri_sect (type)
/* Handle the .print pseudo-op. */
void
-s_print (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_print (int ignore ATTRIBUTE_UNUSED)
{
char *s;
int len;
s = demand_copy_C_string (&len);
- printf ("%s\n", s);
+ if (s != NULL)
+ printf ("%s\n", s);
demand_empty_rest_of_line ();
}
/* Handle the .purgem pseudo-op. */
void
-s_purgem (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_purgem (int ignore ATTRIBUTE_UNUSED)
{
if (is_it_end_of_statement ())
{
@@ -2700,8 +2583,7 @@ s_purgem (ignore)
/* Handle the .rept pseudo-op. */
void
-s_bad_endr (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_bad_endr (int ignore ATTRIBUTE_UNUSED)
{
as_warn (_(".endr encountered without preceeding .rept, .irc, or .irp"));
demand_empty_rest_of_line ();
@@ -2710,8 +2592,7 @@ s_bad_endr (ignore)
/* Handle the .rept pseudo-op. */
void
-s_rept (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_rept (int ignore ATTRIBUTE_UNUSED)
{
int count;
@@ -2724,10 +2605,7 @@ s_rept (ignore)
different directives to be used as the start/end keys. */
void
-do_repeat (count, start, end)
- int count;
- const char *start;
- const char *end;
+do_repeat (int count, const char *start, const char *end)
{
sb one;
sb many;
@@ -2759,8 +2637,7 @@ do_repeat (count, start, end)
such as line substitutions. */
void
-end_repeat (extra)
- int extra;
+end_repeat (int extra)
{
cond_exit_macro (macro_nest);
while (extra-- >= 0)
@@ -2772,8 +2649,7 @@ end_repeat (extra)
defined. */
void
-s_set (equiv)
- int equiv;
+s_set (int equiv)
{
register char *name;
register char delim;
@@ -2830,7 +2706,7 @@ s_set (equiv)
#ifndef NO_LISTING
/* When doing symbol listings, play games with dummy fragments living
outside the normal fragment chain to record the file and line info
- for this symbol. */
+ for this symbol. */
if (listing & LISTING_SYMBOLS)
{
extern struct list_info_struct *listing_tail;
@@ -2865,8 +2741,7 @@ s_set (equiv)
}
void
-s_space (mult)
- int mult;
+s_space (int mult)
{
expressionS exp;
expressionS val;
@@ -3038,8 +2913,7 @@ s_space (mult)
friends. */
void
-s_float_space (float_type)
- int float_type;
+s_float_space (int float_type)
{
offsetT count;
int flen;
@@ -3119,8 +2993,7 @@ s_float_space (float_type)
/* Handle the .struct pseudo-op, as found in MIPS assemblers. */
void
-s_struct (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_struct (int ignore ATTRIBUTE_UNUSED)
{
char *stop = NULL;
char stopc;
@@ -3135,8 +3008,7 @@ s_struct (ignore)
}
void
-s_text (ignore)
- int ignore ATTRIBUTE_UNUSED;
+s_text (int ignore ATTRIBUTE_UNUSED)
{
register int temp;
@@ -3148,35 +3020,40 @@ s_text (ignore)
#endif
}
+
+/* Verify that we are at the end of a line. If not, issue an error and
+ skip to EOL. */
+
void
-demand_empty_rest_of_line ()
+demand_empty_rest_of_line (void)
{
SKIP_WHITESPACE ();
if (is_end_of_line[(unsigned char) *input_line_pointer])
input_line_pointer++;
else
- ignore_rest_of_line ();
-
- /* Return having already swallowed end-of-line. */
-}
-
-void
-ignore_rest_of_line ()
-{
- /* For suspect lines: gives warning. */
- if (!is_end_of_line[(unsigned char) *input_line_pointer])
{
if (ISPRINT (*input_line_pointer))
- as_warn (_("rest of line ignored; first ignored character is `%c'"),
+ as_bad (_("junk at end of line, first unrecognized character is `%c'"),
*input_line_pointer);
else
- as_warn (_("rest of line ignored; first ignored character valued 0x%x"),
+ as_bad (_("junk at end of line, first unrecognized character valued 0x%x"),
*input_line_pointer);
-
- while (input_line_pointer < buffer_limit
- && !is_end_of_line[(unsigned char) *input_line_pointer])
- input_line_pointer++;
+ ignore_rest_of_line ();
}
+
+ /* Return pointing just after end-of-line. */
+ know (is_end_of_line[(unsigned char) input_line_pointer[-1]]);
+}
+
+/* Silently advance to the end of line. Use this after already having
+ issued an error about something bad. */
+
+void
+ignore_rest_of_line (void)
+{
+ while (input_line_pointer < buffer_limit
+ && !is_end_of_line[(unsigned char) *input_line_pointer])
+ input_line_pointer++;
input_line_pointer++;
@@ -3185,7 +3062,7 @@ ignore_rest_of_line ()
}
void
-discard_rest_of_line ()
+discard_rest_of_line (void)
{
while (input_line_pointer < buffer_limit
&& !is_end_of_line[(unsigned char) *input_line_pointer])
@@ -3198,15 +3075,14 @@ discard_rest_of_line ()
}
/* In: Pointer to a symbol.
- Input_line_pointer->expression.
+ Input_line_pointer->expression.
Out: Input_line_pointer->just after any whitespace after expression.
- Tried to set symbol to value of expression.
- Will change symbols type, value, and frag; */
+ Tried to set symbol to value of expression.
+ Will change symbols type, value, and frag; */
void
-pseudo_set (symbolP)
- symbolS *symbolP;
+pseudo_set (symbolS *symbolP)
{
expressionS exp;
#if (defined (OBJ_AOUT) || defined (OBJ_BOUT)) && ! defined (BFD_ASSEMBLER)
@@ -3232,8 +3108,6 @@ pseudo_set (symbolP)
as_bad (_("floating point number invalid"));
}
else if (exp.X_op == O_subtract
- && (S_GET_SEGMENT (exp.X_add_symbol)
- == S_GET_SEGMENT (exp.X_op_symbol))
&& SEG_NORMAL (S_GET_SEGMENT (exp.X_add_symbol))
&& (symbol_get_frag (exp.X_add_symbol)
== symbol_get_frag (exp.X_op_symbol)))
@@ -3301,7 +3175,7 @@ pseudo_set (symbolP)
}
}
-/* cons()
+/* cons()
CONStruct more frag of .bytes, or .words etc.
Should need_pass_2 be 1 then emit no frag(s).
@@ -3326,19 +3200,19 @@ pseudo_set (symbolP)
#ifdef TC_M68K
static void
-parse_mri_cons PARAMS ((expressionS *exp, unsigned int nbytes));
+parse_mri_cons (expressionS *exp, unsigned int nbytes);
#endif
#ifndef TC_PARSE_CONS_EXPRESSION
#ifdef BITFIELD_CONS_EXPRESSIONS
#define TC_PARSE_CONS_EXPRESSION(EXP, NBYTES) parse_bitfield_cons (EXP, NBYTES)
static void
-parse_bitfield_cons PARAMS ((expressionS *exp, unsigned int nbytes));
+parse_bitfield_cons (expressionS *exp, unsigned int nbytes);
#endif
#ifdef REPEAT_CONS_EXPRESSIONS
#define TC_PARSE_CONS_EXPRESSION(EXP, NBYTES) parse_repeat_cons (EXP, NBYTES)
static void
-parse_repeat_cons PARAMS ((expressionS *exp, unsigned int nbytes));
+parse_repeat_cons (expressionS *exp, unsigned int nbytes);
#endif
/* If we haven't gotten one yet, just call expression. */
@@ -3347,13 +3221,20 @@ parse_repeat_cons PARAMS ((expressionS *exp, unsigned int nbytes));
#endif
#endif
+void
+do_parse_cons_expression (expressionS *exp,
+ int nbytes ATTRIBUTE_UNUSED)
+{
+ TC_PARSE_CONS_EXPRESSION (exp, nbytes);
+}
+
+
/* Worker to do .byte etc statements.
Clobbers input_line_pointer and checks end-of-line. */
static void
-cons_worker (nbytes, rva)
- register int nbytes; /* 1=.byte, 2=.word, 4=.long. */
- int rva;
+cons_worker (register int nbytes, /* 1=.byte, 2=.word, 4=.long. */
+ int rva)
{
int c;
expressionS exp;
@@ -3416,15 +3297,13 @@ cons_worker (nbytes, rva)
}
void
-cons (size)
- int size;
+cons (int size)
{
cons_worker (size, 0);
}
void
-s_rva (size)
- int size;
+s_rva (int size)
{
cons_worker (size, 1);
}
@@ -3433,9 +3312,7 @@ s_rva (size)
NBYTES bytes. If need_pass_2 is 1, this does nothing. */
void
-emit_expr (exp, nbytes)
- expressionS *exp;
- unsigned int nbytes;
+emit_expr (expressionS *exp, unsigned int nbytes)
{
operatorT op;
register char *p;
@@ -3445,6 +3322,8 @@ emit_expr (exp, nbytes)
if (need_pass_2)
return;
+ dot_value = frag_now_fix ();
+
#ifndef NO_LISTING
#ifdef OBJ_ELF
/* When gcc emits DWARF 1 debugging pseudo-ops, a line number will
@@ -3593,6 +3472,7 @@ emit_expr (exp, nbytes)
x->sub = exp->X_op_symbol;
x->addnum = exp->X_add_number;
x->added = 0;
+ x->use_jump = 0;
new_broken_words++;
return;
}
@@ -3788,7 +3668,7 @@ emit_expr (exp, nbytes)
them in words, longs, etc. and we'll pack them in target byte order
for you.
- The rules are: pack least significat bit first, if a field doesn't
+ The rules are: pack least significant bit first, if a field doesn't
entirely fit, put it in the next unit. Overflowing the bitfield is
explicitly *not* even a warning. The bitwidth should be considered
a "mask".
@@ -4022,9 +3902,7 @@ parse_repeat_cons (exp, nbytes)
point number. */
static int
-hex_float (float_type, bytes)
- int float_type;
- char *bytes;
+hex_float (int float_type, char *bytes)
{
int length;
int i;
@@ -4108,7 +3986,7 @@ hex_float (float_type, bytes)
return length;
}
-/* float_cons()
+/* float_cons()
CONStruct some more frag chars of .floats .ffloats etc.
Makes 0 or more new frags.
@@ -4119,16 +3997,15 @@ hex_float (float_type, bytes)
by 0d 0f 0g or 0h. After observing the STRANGE way my BSD AS does its
reading, I decided to be incompatible. This always tries to give you
rounded bits to the precision of the pseudo-op. Former AS did premature
- truncatation, restored noisy bits instead of trailing 0s AND gave you
+ truncation, restored noisy bits instead of trailing 0s AND gave you
a choice of 2 flavours of noise according to which of 2 floating-point
scanners you directed AS to use.
In: input_line_pointer->whitespace before, or '0' of flonum. */
void
-float_cons (float_type)
- /* Clobbers input_line-pointer, checks end-of-line. */
- register int float_type; /* 'f':.ffloat ... 'F':.float ... */
+float_cons (/* Clobbers input_line-pointer, checks end-of-line. */
+ register int float_type /* 'f':.ffloat ... 'F':.float ... */)
{
register char *p;
int length; /* Number of chars in an object. */
@@ -4151,15 +4028,15 @@ float_cons (float_type)
SKIP_WHITESPACE ();
/* Skip any 0{letter} that may be present. Don't even check if the
- letter is legal. Someone may invent a "z" format and this routine
- has no use for such information. Lusers beware: you get
- diagnostics if your input is ill-conditioned. */
+ letter is legal. Someone may invent a "z" format and this routine
+ has no use for such information. Lusers beware: you get
+ diagnostics if your input is ill-conditioned. */
if (input_line_pointer[0] == '0'
&& ISALPHA (input_line_pointer[1]))
input_line_pointer += 2;
/* Accept :xxxx, where the x's are hex digits, for a floating
- point with the exact digits specified. */
+ point with the exact digits specified. */
if (input_line_pointer[0] == ':')
{
++input_line_pointer;
@@ -4223,8 +4100,7 @@ float_cons (float_type)
/* Return the size of a LEB128 value. */
static inline int
-sizeof_sleb128 (value)
- offsetT value;
+sizeof_sleb128 (offsetT value)
{
register int size = 0;
register unsigned byte;
@@ -4245,8 +4121,7 @@ sizeof_sleb128 (value)
}
static inline int
-sizeof_uleb128 (value)
- valueT value;
+sizeof_uleb128 (valueT value)
{
register int size = 0;
register unsigned byte;
@@ -4263,9 +4138,7 @@ sizeof_uleb128 (value)
}
int
-sizeof_leb128 (value, sign)
- valueT value;
- int sign;
+sizeof_leb128 (valueT value, int sign)
{
if (sign)
return sizeof_sleb128 ((offsetT) value);
@@ -4276,9 +4149,7 @@ sizeof_leb128 (value, sign)
/* Output a LEB128 value. */
static inline int
-output_sleb128 (p, value)
- char *p;
- offsetT value;
+output_sleb128 (char *p, offsetT value)
{
register char *orig = p;
register int more;
@@ -4305,9 +4176,7 @@ output_sleb128 (p, value)
}
static inline int
-output_uleb128 (p, value)
- char *p;
- valueT value;
+output_uleb128 (char *p, valueT value)
{
char *orig = p;
@@ -4327,10 +4196,7 @@ output_uleb128 (p, value)
}
int
-output_leb128 (p, value, sign)
- char *p;
- valueT value;
- int sign;
+output_leb128 (char *p, valueT value, int sign)
{
if (sign)
return output_sleb128 (p, (offsetT) value);
@@ -4343,10 +4209,7 @@ output_leb128 (p, value, sign)
for "normal" values that this be streamlined. */
static inline int
-output_big_sleb128 (p, bignum, size)
- char *p;
- LITTLENUM_TYPE *bignum;
- int size;
+output_big_sleb128 (char *p, LITTLENUM_TYPE *bignum, int size)
{
char *orig = p;
valueT val = 0;
@@ -4389,10 +4252,7 @@ output_big_sleb128 (p, bignum, size)
}
static inline int
-output_big_uleb128 (p, bignum, size)
- char *p;
- LITTLENUM_TYPE *bignum;
- int size;
+output_big_uleb128 (char *p, LITTLENUM_TYPE *bignum, int size)
{
char *orig = p;
valueT val = 0;
@@ -4431,10 +4291,7 @@ output_big_uleb128 (p, bignum, size)
}
static int
-output_big_leb128 (p, bignum, size, sign)
- char *p;
- LITTLENUM_TYPE *bignum;
- int size, sign;
+output_big_leb128 (char *p, LITTLENUM_TYPE *bignum, int size, int sign)
{
if (sign)
return output_big_sleb128 (p, bignum, size);
@@ -4446,9 +4303,7 @@ output_big_leb128 (p, bignum, size, sign)
leb128 value. */
void
-emit_leb128_expr (exp, sign)
- expressionS *exp;
- int sign;
+emit_leb128_expr (expressionS *exp, int sign)
{
operatorT op = exp->X_op;
int nbytes;
@@ -4518,11 +4373,18 @@ emit_leb128_expr (exp, sign)
/* Parse the .sleb128 and .uleb128 pseudos. */
void
-s_leb128 (sign)
- int sign;
+s_leb128 (int sign)
{
expressionS exp;
+#ifdef md_flush_pending_output
+ md_flush_pending_output ();
+#endif
+
+#ifdef md_flush_pending_output
+ md_flush_pending_output ();
+#endif
+
do
{
expression (&exp);
@@ -4539,9 +4401,9 @@ s_leb128 (sign)
check it. */
void
-stringer (append_zero) /* Worker to do .ascii etc statements. */
- /* Checks end-of-line. */
- register int append_zero; /* 0: don't append '\0', else 1. */
+stringer (/* Worker to do .ascii etc statements. */
+ /* Checks end-of-line. */
+ register int append_zero /* 0: don't append '\0', else 1. */)
{
register unsigned int c;
char *start;
@@ -4572,7 +4434,7 @@ stringer (append_zero) /* Worker to do .ascii etc statements. */
c = 0;
ignore_rest_of_line ();
}
-
+
while (c == ',' || c == '<' || c == '"')
{
SKIP_WHITESPACE ();
@@ -4594,11 +4456,11 @@ stringer (append_zero) /* Worker to do .ascii etc statements. */
#ifndef NO_LISTING
#ifdef OBJ_ELF
/* In ELF, when gcc is emitting DWARF 1 debugging output, it
- will emit .string with a filename in the .debug section
- after a sequence of constants. See the comment in
- emit_expr for the sequence. emit_expr will set
- dwarf_file_string to non-zero if this string might be a
- source file name. */
+ will emit .string with a filename in the .debug section
+ after a sequence of constants. See the comment in
+ emit_expr for the sequence. emit_expr will set
+ dwarf_file_string to non-zero if this string might be a
+ source file name. */
if (strcmp (segment_name (now_seg), ".debug") != 0)
dwarf_file_string = 0;
else if (dwarf_file_string)
@@ -4639,7 +4501,7 @@ stringer (append_zero) /* Worker to do .ascii etc statements. */
returning values bigger than 1 byte. xoxorich. */
unsigned int
-next_char_of_string ()
+next_char_of_string (void)
{
register unsigned int c;
@@ -4761,8 +4623,7 @@ next_char_of_string ()
}
static segT
-get_segmented_expression (expP)
- register expressionS *expP;
+get_segmented_expression (register expressionS *expP)
{
register segT retval;
@@ -4780,8 +4641,7 @@ get_segmented_expression (expP)
}
static segT
-get_known_segmented_expression (expP)
- register expressionS *expP;
+get_known_segmented_expression (register expressionS *expP)
{
register segT retval;
@@ -4804,23 +4664,28 @@ get_known_segmented_expression (expP)
}
offsetT
-get_absolute_expression ()
+get_absolute_expr (expressionS *exp)
{
- expressionS exp;
-
- expression (&exp);
- if (exp.X_op != O_constant)
+ expression (exp);
+ if (exp->X_op != O_constant)
{
- if (exp.X_op != O_absent)
+ if (exp->X_op != O_absent)
as_bad (_("bad or irreducible absolute expression"));
- exp.X_add_number = 0;
+ exp->X_add_number = 0;
}
- return exp.X_add_number;
+ return exp->X_add_number;
+}
+
+offsetT
+get_absolute_expression (void)
+{
+ expressionS exp;
+
+ return get_absolute_expr (&exp);
}
char /* Return terminator. */
-get_absolute_expression_and_terminator (val_pointer)
- long *val_pointer; /* Return value of expression. */
+get_absolute_expression_and_terminator (long *val_pointer /* Return value of expression. */)
{
/* FIXME: val_pointer should probably be offsetT *. */
*val_pointer = (long) get_absolute_expression ();
@@ -4831,8 +4696,7 @@ get_absolute_expression_and_terminator (val_pointer)
Give a warning if that happens. */
char *
-demand_copy_C_string (len_pointer)
- int *len_pointer;
+demand_copy_C_string (int *len_pointer)
{
register char *s;
@@ -4859,8 +4723,7 @@ demand_copy_C_string (len_pointer)
Return NULL if we can't read a string here. */
char *
-demand_copy_string (lenP)
- int *lenP;
+demand_copy_string (int *lenP)
{
register unsigned int c;
register int len;
@@ -4884,7 +4747,7 @@ demand_copy_string (lenP)
}
else
{
- as_warn (_("missing string"));
+ as_bad (_("missing string"));
retval = NULL;
ignore_rest_of_line ();
}
@@ -4899,16 +4762,14 @@ demand_copy_string (lenP)
Out: 1 if input_line_pointer->end-of-line. */
int
-is_it_end_of_statement ()
+is_it_end_of_statement (void)
{
SKIP_WHITESPACE ();
return (is_end_of_line[(unsigned char) *input_line_pointer]);
}
void
-equals (sym_name, reassign)
- char *sym_name;
- int reassign;
+equals (char *sym_name, int reassign)
{
register symbolS *symbolP; /* Symbol we are working with. */
char *stop = NULL;
@@ -4962,7 +4823,7 @@ equals (sym_name, reassign)
if (flag_mri)
{
/* Check garbage after the expression. */
- ignore_rest_of_line ();
+ demand_empty_rest_of_line ();
mri_comment_end (stop, stopc);
}
}
@@ -4970,8 +4831,7 @@ equals (sym_name, reassign)
/* .incbin -- include a file verbatim at the current location. */
void
-s_incbin (x)
- int x ATTRIBUTE_UNUSED;
+s_incbin (int x ATTRIBUTE_UNUSED)
{
FILE * binfile;
char * path;
@@ -5087,8 +4947,7 @@ done:
/* .include -- include a file at this point. */
void
-s_include (arg)
- int arg ATTRIBUTE_UNUSED;
+s_include (int arg ATTRIBUTE_UNUSED)
{
char *filename;
int i;
@@ -5101,7 +4960,7 @@ s_include (arg)
if (filename == NULL)
{
/* demand_copy_string has already printed an error and
- called ignore_rest_of_line. */
+ called ignore_rest_of_line. */
return;
}
}
@@ -5148,8 +5007,7 @@ gotit:
}
void
-add_include_dir (path)
- char *path;
+add_include_dir (char *path)
{
int i;
@@ -5177,7 +5035,7 @@ add_include_dir (path)
/* Output debugging information to denote the source file. */
static void
-generate_file_debug ()
+generate_file_debug (void)
{
if (debug_type == DEBUG_STABS)
stabs_generate_asm_file ();
@@ -5186,7 +5044,7 @@ generate_file_debug ()
/* Output line number debugging information for the current source line. */
void
-generate_lineno_debug ()
+generate_lineno_debug (void)
{
switch (debug_type)
{
@@ -5213,8 +5071,7 @@ generate_lineno_debug ()
END_P is zero for .func, and non-zero for .endfunc. */
void
-s_func (end_p)
- int end_p;
+s_func (int end_p)
{
do_s_func (end_p, NULL);
}
@@ -5223,9 +5080,7 @@ s_func (end_p)
If DEFAULT_PREFIX is NULL, use the target's "leading char". */
void
-do_s_func (end_p, default_prefix)
- int end_p;
- const char *default_prefix;
+do_s_func (int end_p, const char *default_prefix)
{
/* Record the current function so that we can issue an error message for
misplaced .func,.endfunc, and also so that .endfunc needs no
@@ -5303,8 +5158,7 @@ do_s_func (end_p, default_prefix)
}
void
-s_ignore (arg)
- int arg ATTRIBUTE_UNUSED;
+s_ignore (int arg ATTRIBUTE_UNUSED)
{
while (!is_end_of_line[(unsigned char) *input_line_pointer])
{
@@ -5314,8 +5168,7 @@ s_ignore (arg)
}
void
-read_print_statistics (file)
- FILE *file;
+read_print_statistics (FILE *file)
{
hash_print_statistics (file, "pseudo-op table", po_hash);
}
@@ -5325,13 +5178,12 @@ read_print_statistics (file)
This call avoids macro/conditionals nesting checking, since the contents of
the line are assumed to replace the contents of a line already scanned.
- An appropriate use of this function would be substition of input lines when
+ An appropriate use of this function would be substitution of input lines when
called by md_start_line_hook(). The given line is assumed to already be
properly scrubbed. */
void
-input_scrub_insert_line (line)
- const char *line;
+input_scrub_insert_line (const char *line)
{
sb newline;
sb_new (&newline);
@@ -5345,8 +5197,7 @@ input_scrub_insert_line (line)
file; no include path searching or dependency registering is performed. */
void
-input_scrub_insert_file (path)
- char *path;
+input_scrub_insert_file (char *path)
{
input_scrub_include_file (path, input_line_pointer);
buffer_limit = input_scrub_next_buffer (&input_line_pointer);
diff --git a/contrib/binutils/gas/read.h b/contrib/binutils/gas/read.h
index f57126d..b89ffcb 100644
--- a/contrib/binutils/gas/read.h
+++ b/contrib/binutils/gas/read.h
@@ -1,6 +1,6 @@
/* read.h - of read.c
Copyright 1986, 1990, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000
+ 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -30,10 +30,7 @@ extern char *input_line_pointer; /* -> char we are parsing now. */
#ifdef PERMIT_WHITESPACE
#define SKIP_WHITESPACE() \
- { \
- if (* input_line_pointer == ' ') \
- ++ input_line_pointer; \
- }
+ ((*input_line_pointer == ' ') ? ++input_line_pointer : 0)
#else
#define SKIP_WHITESPACE() know(*input_line_pointer != ' ' )
#endif
@@ -58,7 +55,7 @@ extern char *input_line_pointer; /* -> char we are parsing now. */
extern char lex_type[];
extern char is_end_of_line[];
-extern int is_it_end_of_statement PARAMS ((void));
+extern int is_it_end_of_statement (void);
extern int target_big_endian;
@@ -93,94 +90,99 @@ enum linkonce_type {
LINKONCE_SAME_CONTENTS
};
-#define IGNORE_OPCODE_CASE
-#ifdef IGNORE_OPCODE_CASE
+#ifndef TC_CASE_SENSITIVE
extern char original_case_string[];
#endif
-extern void pop_insert PARAMS ((const pseudo_typeS *));
+extern void pop_insert (const pseudo_typeS *);
extern unsigned int get_stab_string_offset
- PARAMS ((const char *string, const char *stabstr_secname));
-extern void aout_process_stab PARAMS ((int, const char *, int, int, int));
-extern char *demand_copy_C_string PARAMS ((int *len_pointer));
-extern char get_absolute_expression_and_terminator
- PARAMS ((long *val_pointer));
-extern offsetT get_absolute_expression PARAMS ((void));
-extern unsigned int next_char_of_string PARAMS ((void));
-extern void s_mri_sect PARAMS ((char *));
-extern char *mri_comment_field PARAMS ((char *));
-extern void mri_comment_end PARAMS ((char *, int));
-extern void add_include_dir PARAMS ((char *path));
-extern void cons PARAMS ((int nbytes));
-extern void demand_empty_rest_of_line PARAMS ((void));
-extern void emit_expr PARAMS ((expressionS *exp, unsigned int nbytes));
-extern void emit_leb128_expr PARAMS ((expressionS *, int));
-extern void equals PARAMS ((char *sym_name, int reassign));
-extern void float_cons PARAMS ((int float_type));
-extern void ignore_rest_of_line PARAMS ((void));
-extern void discard_rest_of_line PARAMS ((void));
-extern int output_leb128 PARAMS ((char *, valueT, int sign));
-extern void pseudo_set PARAMS ((symbolS * symbolP));
-extern void read_a_source_file PARAMS ((char *name));
-extern void read_begin PARAMS ((void));
-extern void read_print_statistics PARAMS ((FILE *));
-extern int sizeof_leb128 PARAMS ((valueT, int sign));
-extern void stabs_generate_asm_file PARAMS ((void));
-extern void stabs_generate_asm_lineno PARAMS ((void));
-extern void stabs_generate_asm_func PARAMS ((const char *, const char *));
-extern void stabs_generate_asm_endfunc PARAMS ((const char *, const char *));
-extern void do_repeat PARAMS((int,const char *,const char *));
-extern void end_repeat PARAMS((int));
-
-extern void generate_lineno_debug PARAMS ((void));
-
-extern void s_abort PARAMS ((int)) ATTRIBUTE_NORETURN;
-extern void s_align_bytes PARAMS ((int arg));
-extern void s_align_ptwo PARAMS ((int));
-extern void s_app_file_string PARAMS ((char *));
-extern void s_app_file PARAMS ((int));
-extern void s_app_line PARAMS ((int));
-extern void s_bad_endr PARAMS ((int));
-extern void s_comm PARAMS ((int));
-extern void s_data PARAMS ((int));
-extern void s_desc PARAMS ((int));
-extern void s_else PARAMS ((int arg));
-extern void s_elseif PARAMS ((int arg));
-extern void s_end PARAMS ((int arg));
-extern void s_endif PARAMS ((int arg));
-extern void s_err PARAMS ((int));
-extern void s_fail PARAMS ((int));
-extern void s_fill PARAMS ((int));
-extern void s_float_space PARAMS ((int mult));
-extern void s_func PARAMS ((int));
-extern void do_s_func PARAMS ((int, const char *));
-extern void s_globl PARAMS ((int arg));
-extern void s_if PARAMS ((int arg));
-extern void s_ifc PARAMS ((int arg));
-extern void s_ifdef PARAMS ((int arg));
-extern void s_ifeqs PARAMS ((int arg));
-extern void s_ignore PARAMS ((int arg));
-extern void s_include PARAMS ((int arg));
-extern void s_irp PARAMS ((int arg));
-extern void s_lcomm PARAMS ((int needs_align));
-extern void s_lcomm_bytes PARAMS ((int needs_align));
-extern void s_leb128 PARAMS ((int sign));
-extern void s_linkonce PARAMS ((int));
-extern void s_lsym PARAMS ((int));
-extern void s_macro PARAMS ((int));
-extern void s_mexit PARAMS ((int));
-extern void s_mri PARAMS ((int));
-extern void s_mri_common PARAMS ((int));
-extern void s_org PARAMS ((int));
-extern void s_print PARAMS ((int));
-extern void s_purgem PARAMS ((int));
-extern void s_rept PARAMS ((int));
-extern void s_set PARAMS ((int));
-extern void s_space PARAMS ((int mult));
-extern void s_stab PARAMS ((int what));
-extern void s_struct PARAMS ((int));
-extern void s_text PARAMS ((int));
-extern void stringer PARAMS ((int append_zero));
-extern void s_xstab PARAMS ((int what));
-extern void s_rva PARAMS ((int));
-extern void s_incbin PARAMS ((int));
+ (const char *string, const char *stabstr_secname);
+extern void aout_process_stab (int, const char *, int, int, int);
+extern char *demand_copy_string (int *lenP);
+extern char *demand_copy_C_string (int *len_pointer);
+extern char get_absolute_expression_and_terminator (long *val_pointer);
+extern offsetT get_absolute_expr (expressionS *);
+extern offsetT get_absolute_expression (void);
+extern unsigned int next_char_of_string (void);
+extern void s_mri_sect (char *);
+extern char *mri_comment_field (char *);
+extern void mri_comment_end (char *, int);
+extern void add_include_dir (char *path);
+extern void cons (int nbytes);
+extern void demand_empty_rest_of_line (void);
+extern void emit_expr (expressionS *exp, unsigned int nbytes);
+extern void emit_leb128_expr (expressionS *, int);
+extern void equals (char *sym_name, int reassign);
+extern void float_cons (int float_type);
+extern void ignore_rest_of_line (void);
+extern void discard_rest_of_line (void);
+extern int output_leb128 (char *, valueT, int sign);
+extern void pseudo_set (symbolS * symbolP);
+extern void read_a_source_file (char *name);
+extern void read_begin (void);
+extern void read_print_statistics (FILE *);
+extern int sizeof_leb128 (valueT, int sign);
+extern void stabs_generate_asm_file (void);
+extern void stabs_generate_asm_lineno (void);
+extern void stabs_generate_asm_func (const char *, const char *);
+extern void stabs_generate_asm_endfunc (const char *, const char *);
+extern void do_repeat (int,const char *,const char *);
+extern void end_repeat (int);
+extern void do_parse_cons_expression (expressionS *, int);
+
+extern void generate_lineno_debug (void);
+
+extern void s_abort (int) ATTRIBUTE_NORETURN;
+extern void s_align_bytes (int arg);
+extern void s_align_ptwo (int);
+extern void bss_alloc (symbolS *, addressT, int);
+extern offsetT parse_align (int);
+extern symbolS *s_comm_internal (int, symbolS *(*) (int, symbolS *, addressT));
+extern symbolS *s_lcomm_internal (int, symbolS *, addressT);
+extern void s_app_file_string (char *);
+extern void s_app_file (int);
+extern void s_app_line (int);
+extern void s_bad_endr (int);
+extern void s_comm (int);
+extern void s_data (int);
+extern void s_desc (int);
+extern void s_else (int arg);
+extern void s_elseif (int arg);
+extern void s_end (int arg);
+extern void s_endif (int arg);
+extern void s_err (int);
+extern void s_fail (int);
+extern void s_fill (int);
+extern void s_float_space (int mult);
+extern void s_func (int);
+extern void do_s_func (int, const char *);
+extern void s_globl (int arg);
+extern void s_if (int arg);
+extern void s_ifc (int arg);
+extern void s_ifdef (int arg);
+extern void s_ifeqs (int arg);
+extern void s_ignore (int arg);
+extern void s_include (int arg);
+extern void s_irp (int arg);
+extern void s_lcomm (int needs_align);
+extern void s_lcomm_bytes (int needs_align);
+extern void s_leb128 (int sign);
+extern void s_linkonce (int);
+extern void s_lsym (int);
+extern void s_macro (int);
+extern void s_mexit (int);
+extern void s_mri (int);
+extern void s_mri_common (int);
+extern void s_org (int);
+extern void s_print (int);
+extern void s_purgem (int);
+extern void s_rept (int);
+extern void s_set (int);
+extern void s_space (int mult);
+extern void s_stab (int what);
+extern void s_struct (int);
+extern void s_text (int);
+extern void stringer (int append_zero);
+extern void s_xstab (int what);
+extern void s_rva (int);
+extern void s_incbin (int);
diff --git a/contrib/binutils/gas/sb.c b/contrib/binutils/gas/sb.c
index 93d2fcf..27b29ee 100644
--- a/contrib/binutils/gas/sb.c
+++ b/contrib/binutils/gas/sb.c
@@ -52,7 +52,7 @@
#define dsize 5
-static void sb_check PARAMS ((sb *, int));
+static void sb_check (sb *, int);
/* Statistics of sb structures. */
@@ -65,9 +65,7 @@ static sb_list_vector free_list;
/* initializes an sb. */
void
-sb_build (ptr, size)
- sb *ptr;
- int size;
+sb_build (sb *ptr, int size)
{
/* see if we can find one to allocate */
sb_element *e;
@@ -98,8 +96,7 @@ sb_build (ptr, size)
}
void
-sb_new (ptr)
- sb *ptr;
+sb_new (sb *ptr)
{
sb_build (ptr, dsize);
}
@@ -107,8 +104,7 @@ sb_new (ptr)
/* deallocate the sb at ptr */
void
-sb_kill (ptr)
- sb *ptr;
+sb_kill (sb *ptr)
{
/* return item to free list */
ptr->item->next = free_list.size[ptr->pot];
@@ -118,9 +114,7 @@ sb_kill (ptr)
/* add the sb at s to the end of the sb at ptr */
void
-sb_add_sb (ptr, s)
- sb *ptr;
- sb *s;
+sb_add_sb (sb *ptr, sb *s)
{
sb_check (ptr, s->len);
memcpy (ptr->ptr + ptr->len, s->ptr, s->len);
@@ -131,9 +125,7 @@ sb_add_sb (ptr, s)
and grow it if it doesn't. */
static void
-sb_check (ptr, len)
- sb *ptr;
- int len;
+sb_check (sb *ptr, int len)
{
if (ptr->len + len >= 1 << ptr->pot)
{
@@ -151,8 +143,7 @@ sb_check (ptr, len)
/* make the sb at ptr point back to the beginning. */
void
-sb_reset (ptr)
- sb *ptr;
+sb_reset (sb *ptr)
{
ptr->len = 0;
}
@@ -160,9 +151,7 @@ sb_reset (ptr)
/* add character c to the end of the sb at ptr. */
void
-sb_add_char (ptr, c)
- sb *ptr;
- int c;
+sb_add_char (sb *ptr, int c)
{
sb_check (ptr, 1);
ptr->ptr[ptr->len++] = c;
@@ -171,9 +160,7 @@ sb_add_char (ptr, c)
/* add null terminated string s to the end of sb at ptr. */
void
-sb_add_string (ptr, s)
- sb *ptr;
- const char *s;
+sb_add_string (sb *ptr, const char *s)
{
int len = strlen (s);
sb_check (ptr, len);
@@ -184,10 +171,7 @@ sb_add_string (ptr, s)
/* add string at s of length len to sb at ptr */
void
-sb_add_buffer (ptr, s, len)
- sb *ptr;
- const char *s;
- int len;
+sb_add_buffer (sb *ptr, const char *s, int len)
{
sb_check (ptr, len);
memcpy (ptr->ptr + ptr->len, s, len);
@@ -197,9 +181,7 @@ sb_add_buffer (ptr, s, len)
/* print the sb at ptr to the output file */
void
-sb_print (outfile, ptr)
- FILE *outfile;
- sb *ptr;
+sb_print (FILE *outfile, sb *ptr)
{
int i;
int nc = 0;
@@ -216,10 +198,7 @@ sb_print (outfile, ptr)
}
void
-sb_print_at (outfile, idx, ptr)
- FILE *outfile;
- int idx;
- sb *ptr;
+sb_print_at (FILE *outfile, int idx, sb *ptr)
{
int i;
for (i = idx; i < ptr->len; i++)
@@ -230,8 +209,7 @@ sb_print_at (outfile, idx, ptr)
string, so that it can be used as an arg to printf %s. */
char *
-sb_name (in)
- sb *in;
+sb_name (sb *in)
{
/* stick a null on the end of the string */
sb_add_char (in, 0);
@@ -241,8 +219,7 @@ sb_name (in)
/* like sb_name, but don't include the null byte in the string. */
char *
-sb_terminate (in)
- sb *in;
+sb_terminate (sb *in)
{
sb_add_char (in, 0);
--in->len;
@@ -253,9 +230,7 @@ sb_terminate (in)
whitespace. return the index of the first non whitespace character */
int
-sb_skip_white (idx, ptr)
- int idx;
- sb *ptr;
+sb_skip_white (int idx, sb *ptr)
{
while (idx < ptr->len
&& (ptr->ptr[idx] == ' '
@@ -265,13 +240,11 @@ sb_skip_white (idx, ptr)
}
/* start at the index idx into the sb at ptr. skips whitespace,
- a comma and any following whitespace. returnes the index of the
+ a comma and any following whitespace. returns the index of the
next character. */
int
-sb_skip_comma (idx, ptr)
- int idx;
- sb *ptr;
+sb_skip_comma (int idx, sb *ptr)
{
while (idx < ptr->len
&& (ptr->ptr[idx] == ' '
diff --git a/contrib/binutils/gas/sb.h b/contrib/binutils/gas/sb.h
index dd01e0d..30e5bc3 100644
--- a/contrib/binutils/gas/sb.h
+++ b/contrib/binutils/gas/sb.h
@@ -44,7 +44,7 @@
Obstacks provide all the functionality needed, but are too
complicated, hence the sb.
- An sb is allocated by the caller, and is initialzed to point to an
+ An sb is allocated by the caller, and is initialized to point to an
sb_element. sb_elements are kept on a free lists, and used when
needed, replaced onto the free list when unused.
*/
@@ -78,22 +78,22 @@ typedef struct
extern int string_count[sb_max_power_two];
-extern void sb_build PARAMS ((sb *, int));
-extern void sb_new PARAMS ((sb *));
-extern void sb_kill PARAMS ((sb *));
-extern void sb_add_sb PARAMS ((sb *, sb *));
-extern void sb_reset PARAMS ((sb *));
-extern void sb_add_char PARAMS ((sb *, int));
-extern void sb_add_string PARAMS ((sb *, const char *));
-extern void sb_add_buffer PARAMS ((sb *, const char *, int));
-extern void sb_print PARAMS ((FILE *, sb *));
-extern void sb_print_at PARAMS ((FILE *, int, sb *));
-extern char *sb_name PARAMS ((sb *));
-extern char *sb_terminate PARAMS ((sb *));
-extern int sb_skip_white PARAMS ((int, sb *));
-extern int sb_skip_comma PARAMS ((int, sb *));
+extern void sb_build (sb *, int);
+extern void sb_new (sb *);
+extern void sb_kill (sb *);
+extern void sb_add_sb (sb *, sb *);
+extern void sb_reset (sb *);
+extern void sb_add_char (sb *, int);
+extern void sb_add_string (sb *, const char *);
+extern void sb_add_buffer (sb *, const char *, int);
+extern void sb_print (FILE *, sb *);
+extern void sb_print_at (FILE *, int, sb *);
+extern char *sb_name (sb *);
+extern char *sb_terminate (sb *);
+extern int sb_skip_white (int, sb *);
+extern int sb_skip_comma (int, sb *);
/* Actually in input-scrub.c. */
-extern void input_scrub_include_sb PARAMS ((sb *, char *, int));
+extern void input_scrub_include_sb (sb *, char *, int);
#endif /* SB_H */
diff --git a/contrib/binutils/gas/stabs.c b/contrib/binutils/gas/stabs.c
index 38bbc24..f8acdc8 100644
--- a/contrib/binutils/gas/stabs.c
+++ b/contrib/binutils/gas/stabs.c
@@ -34,8 +34,8 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
int outputting_stabs_line_debug = 0;
-static void s_stab_generic PARAMS ((int, char *, char *));
-static void generate_asm_file PARAMS ((int, char *));
+static void s_stab_generic (int, char *, char *);
+static void generate_asm_file (int, char *);
/* Allow backends to override the names used for the stab sections. */
#ifndef STAB_SECTION_NAME
@@ -80,9 +80,7 @@ static const char *current_function_label;
#endif
unsigned int
-get_stab_string_offset (string, stabstr_secname)
- const char *string;
- const char *stabstr_secname;
+get_stab_string_offset (const char *string, const char *stabstr_secname)
{
unsigned int length;
unsigned int retval;
@@ -179,10 +177,7 @@ aout_process_stab (what, string, type, other, desc)
kinds of stab sections. */
static void
-s_stab_generic (what, stab_secname, stabstr_secname)
- int what;
- char *stab_secname;
- char *stabstr_secname;
+s_stab_generic (int what, char *stab_secname, char *stabstr_secname)
{
long longint;
char *string, *saved_string_obstack_end;
@@ -371,13 +366,11 @@ s_stab_generic (what, stab_secname, stabstr_secname)
}
else
{
- const char *fake;
symbolS *symbol;
expressionS exp;
/* Arrange for a value representing the current location. */
- fake = FAKE_LABEL_NAME;
- symbol = symbol_new (fake, saved_seg, dot, saved_frag);
+ symbol = symbol_temp_new (saved_seg, dot, saved_frag);
exp.X_op = O_symbol;
exp.X_add_symbol = symbol;
@@ -407,8 +400,7 @@ s_stab_generic (what, stab_secname, stabstr_secname)
/* Regular stab directive. */
void
-s_stab (what)
- int what;
+s_stab (int what)
{
s_stab_generic (what, STAB_SECTION_NAME, STAB_STRING_SECTION_NAME);
}
@@ -416,8 +408,7 @@ s_stab (what)
/* "Extended stabs", used in Solaris only now. */
void
-s_xstab (what)
- int what;
+s_xstab (int what)
{
int length;
char *stab_secname, *stabstr_secname;
@@ -498,12 +489,21 @@ s_desc (ignore)
/* Generate stabs debugging information to denote the main source file. */
void
-stabs_generate_asm_file ()
+stabs_generate_asm_file (void)
{
char *file;
unsigned int lineno;
as_where (&file, &lineno);
+ if (use_gnu_debug_info_extensions)
+ {
+ char *dir, *dir2;
+
+ dir = getpwd ();
+ dir2 = alloca (strlen (dir) + 2);
+ sprintf (dir2, "%s%s", dir, "/");
+ generate_asm_file (N_SO, dir2);
+ }
generate_asm_file (N_SO, file);
}
@@ -511,9 +511,7 @@ stabs_generate_asm_file ()
TYPE is one of N_SO, N_SOL. */
static void
-generate_asm_file (type, file)
- int type;
- char *file;
+generate_asm_file (int type, char *file)
{
static char *last_file;
static int label_count;
@@ -522,7 +520,7 @@ generate_asm_file (type, file)
char *buf;
char *tmp = file;
char *endp = file + strlen (file);
- char *bufp = buf;
+ char *bufp;
if (last_file != NULL
&& strcmp (last_file, file) == 0)
@@ -580,7 +578,7 @@ generate_asm_file (type, file)
used to produce debugging information for an assembler file. */
void
-stabs_generate_asm_lineno ()
+stabs_generate_asm_lineno (void)
{
static int label_count;
char *hold;
@@ -657,9 +655,7 @@ stabs_generate_asm_lineno ()
All assembler functions are assumed to have return type `void'. */
void
-stabs_generate_asm_func (funcname, startlabname)
- const char *funcname;
- const char *startlabname;
+stabs_generate_asm_func (const char *funcname, const char *startlabname)
{
static int void_emitted_p;
char *hold = input_line_pointer;
@@ -689,9 +685,8 @@ stabs_generate_asm_func (funcname, startlabname)
/* Emit a stab to record the end of a function. */
void
-stabs_generate_asm_endfunc (funcname, startlabname)
- const char *funcname ATTRIBUTE_UNUSED;
- const char *startlabname;
+stabs_generate_asm_endfunc (const char *funcname ATTRIBUTE_UNUSED,
+ const char *startlabname)
{
static int label_count;
char *hold = input_line_pointer;
diff --git a/contrib/binutils/gas/subsegs.c b/contrib/binutils/gas/subsegs.c
index 99d2a8b..b2432e9 100644
--- a/contrib/binutils/gas/subsegs.c
+++ b/contrib/binutils/gas/subsegs.c
@@ -1,6 +1,6 @@
/* subsegs.c - subsegments -
Copyright 1987, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
- 1999, 2000
+ 1999, 2000, 2002
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -70,14 +70,14 @@ static segment_info_type *und_seg_info;
#endif /* BFD_ASSEMBLER */
-static void subseg_set_rest PARAMS ((segT, subsegT));
+static void subseg_set_rest (segT, subsegT);
static fragS dummy_frag;
static frchainS absolute_frchain;
void
-subsegs_begin ()
+subsegs_begin (void)
{
/* Check table(s) seg_name[], seg_N_TYPE[] is in correct order */
#if !defined (MANY_SEGMENTS) && !defined (BFD_ASSEMBLER)
@@ -146,9 +146,7 @@ subsegs_begin ()
* segment context correct.
*/
void
-subseg_change (seg, subseg)
- register segT seg;
- register int subseg;
+subseg_change (register segT seg, register int subseg)
{
now_seg = seg;
now_subseg = subseg;
@@ -203,9 +201,7 @@ subseg_change (seg, subseg)
}
static void
-subseg_set_rest (seg, subseg)
- segT seg;
- subsegT subseg;
+subseg_set_rest (segT seg, subsegT subseg)
{
register frchainS *frcP; /* crawl frchain chain */
register frchainS **lastPP; /* address of last pointer */
@@ -401,9 +397,7 @@ subseg_set (seg, subseg) /* begin assembly for a new sub-segment */
#else /* BFD_ASSEMBLER */
segT
-subseg_get (segname, force_new)
- const char *segname;
- int force_new;
+subseg_get (const char *segname, int force_new)
{
segT secptr;
segment_info_type *seginfo;
@@ -422,11 +416,15 @@ subseg_get (segname, force_new)
else
secptr = bfd_make_section_anyway (stdoutput, segname);
+#ifdef obj_sec_set_private_data
+ obj_sec_set_private_data (stdoutput, secptr);
+#endif
+
seginfo = seg_info (secptr);
if (! seginfo)
{
/* Check whether output_section is set first because secptr may
- be bfd_abs_section_ptr. */
+ be bfd_abs_section_ptr. */
if (secptr->output_section != secptr)
secptr->output_section = secptr;
seginfo = (segment_info_type *) xmalloc (sizeof (*seginfo));
@@ -449,9 +447,7 @@ subseg_get (segname, force_new)
}
segT
-subseg_new (segname, subseg)
- const char *segname;
- subsegT subseg;
+subseg_new (const char *segname, subsegT subseg)
{
segT secptr;
segment_info_type *seginfo;
@@ -467,9 +463,7 @@ subseg_new (segname, subseg)
/* Like subseg_new, except a new section is always created, even if
a section with that name already exists. */
segT
-subseg_force_new (segname, subseg)
- const char *segname;
- subsegT subseg;
+subseg_force_new (const char *segname, subsegT subseg)
{
segT secptr;
segment_info_type *seginfo;
@@ -483,9 +477,7 @@ subseg_force_new (segname, subseg)
}
void
-subseg_set (secptr, subseg)
- segT secptr;
- subsegT subseg;
+subseg_set (segT secptr, subsegT subseg)
{
if (! (secptr == now_seg && subseg == now_subseg))
subseg_set_rest (secptr, subseg);
@@ -499,8 +491,7 @@ subseg_set (secptr, subseg)
/* Get the gas information we are storing for a section. */
segment_info_type *
-seg_info (sec)
- segT sec;
+seg_info (segT sec)
{
if (sec == bfd_abs_section_ptr)
return abs_seg_info;
@@ -511,8 +502,7 @@ seg_info (sec)
}
symbolS *
-section_symbol (sec)
- segT sec;
+section_symbol (segT sec)
{
segment_info_type *seginfo = seg_info (sec);
symbolS *s;
@@ -526,20 +516,16 @@ section_symbol (sec)
#define EMIT_SECTION_SYMBOLS 1
#endif
- if (! EMIT_SECTION_SYMBOLS
-#ifdef BFD_ASSEMBLER
- || symbol_table_frozen
-#endif
- )
+ if (! EMIT_SECTION_SYMBOLS || symbol_table_frozen)
{
/* Here we know it won't be going into the symbol table. */
- s = symbol_create (sec->name, sec, 0, &zero_address_frag);
+ s = symbol_create (sec->symbol->name, sec, 0, &zero_address_frag);
}
else
{
- s = symbol_find_base (sec->name, 0);
+ s = symbol_find_base (sec->symbol->name, 0);
if (s == NULL)
- s = symbol_new (sec->name, sec, 0, &zero_address_frag);
+ s = symbol_new (sec->symbol->name, sec, 0, &zero_address_frag);
else
{
if (S_GET_SEGMENT (s) == undefined_section)
@@ -555,6 +541,8 @@ section_symbol (sec)
/* Use the BFD section symbol, if possible. */
if (obj_sec_sym_ok_for_reloc (sec))
symbol_set_bfdsym (s, sec->symbol);
+ else
+ symbol_get_bfdsym (s)->flags |= BSF_SECTION_SYM;
seginfo->sym = s;
return s;
@@ -579,8 +567,7 @@ const char * const nontext_section_names[] = {
#endif /* ! BFD_ASSEMBLER */
int
-subseg_text_p (sec)
- segT sec;
+subseg_text_p (segT sec)
{
#ifdef BFD_ASSEMBLER
return (bfd_get_section_flags (stdoutput, sec) & SEC_CODE) != 0;
@@ -607,8 +594,7 @@ subseg_text_p (sec)
}
void
-subsegs_print_statistics (file)
- FILE *file;
+subsegs_print_statistics (FILE *file)
{
frchainS *frchp;
fprintf (file, "frag chains:\n");
diff --git a/contrib/binutils/gas/subsegs.h b/contrib/binutils/gas/subsegs.h
index 9a5abb0..331c557 100644
--- a/contrib/binutils/gas/subsegs.h
+++ b/contrib/binutils/gas/subsegs.h
@@ -121,8 +121,8 @@ typedef struct segment_info_struct {
#ifdef BFD_ASSEMBLER
-extern segment_info_type *seg_info PARAMS ((segT));
-extern symbolS *section_symbol PARAMS ((segT));
+extern segment_info_type *seg_info (segT);
+extern symbolS *section_symbol (segT);
#else /* ! BFD_ASSEMBLER */
@@ -152,4 +152,4 @@ struct seg_info_trash {
#endif /* ! BFD_ASSEMBLER */
-extern void subsegs_print_statistics PARAMS ((FILE *));
+extern void subsegs_print_statistics (FILE *);
diff --git a/contrib/binutils/gas/symbols.c b/contrib/binutils/gas/symbols.c
index 63b4d47..761a020 100644
--- a/contrib/binutils/gas/symbols.c
+++ b/contrib/binutils/gas/symbols.c
@@ -1,6 +1,6 @@
/* symbols.c -symbol table-
Copyright 1987, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
- 1999, 2000, 2001, 2002
+ 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -60,12 +60,13 @@ symbolS abs_symbol;
struct obstack notes;
-static char *save_symbol_name PARAMS ((const char *));
-static void fb_label_init PARAMS ((void));
-static long dollar_label_instance PARAMS ((long));
-static long fb_label_instance PARAMS ((long));
+static char *save_symbol_name (const char *);
+static void fb_label_init (void);
+static long dollar_label_instance (long);
+static long fb_label_instance (long);
-static void print_binary PARAMS ((FILE *, const char *, expressionS *));
+static void print_binary (FILE *, const char *, expressionS *);
+static void report_op_error (symbolS *, symbolS *, symbolS *);
/* Return a pointer to a new symbol. Die if we can't make a new
symbol. Fill in the symbol's values. Add symbol to end of symbol
@@ -77,11 +78,7 @@ static void print_binary PARAMS ((FILE *, const char *, expressionS *));
output file, you can call symbol_create. */
symbolS *
-symbol_new (name, segment, valu, frag)
- const char *name;
- segT segment;
- valueT valu;
- fragS *frag;
+symbol_new (const char *name, segT segment, valueT valu, fragS *frag)
{
symbolS *symbolP = symbol_create (name, segment, valu, frag);
@@ -102,8 +99,7 @@ symbol_new (name, segment, valu, frag)
to the object file format. */
static char *
-save_symbol_name (name)
- const char *name;
+save_symbol_name (const char *name)
{
unsigned int name_length;
char *ret;
@@ -133,11 +129,10 @@ save_symbol_name (name)
}
symbolS *
-symbol_create (name, segment, valu, frag)
- const char *name; /* It is copied, the caller can destroy/modify. */
- segT segment; /* Segment identifier (SEG_<something>). */
- valueT valu; /* Symbol value. */
- fragS *frag; /* Associated fragment. */
+symbol_create (const char *name, /* It is copied, the caller can destroy/modify. */
+ segT segment, /* Segment identifier (SEG_<something>). */
+ valueT valu, /* Symbol value. */
+ fragS *frag /* Associated fragment. */)
{
char *preserved_copy_of_name;
symbolS *symbolP;
@@ -181,9 +176,7 @@ symbol_create (name, segment, valu, frag)
/* Local symbol support. If we can get away with it, we keep only a
small amount of information for local symbols. */
-static struct local_symbol *local_symbol_make PARAMS ((const char *, segT,
- valueT, fragS *));
-static symbolS *local_symbol_convert PARAMS ((struct local_symbol *));
+static symbolS *local_symbol_convert (struct local_symbol *);
/* Used for statistics. */
@@ -204,12 +197,8 @@ static unsigned long local_symbol_conversion_count;
/* Create a local symbol and insert it into the local hash table. */
-static struct local_symbol *
-local_symbol_make (name, section, value, frag)
- const char *name;
- segT section;
- valueT value;
- fragS *frag;
+struct local_symbol *
+local_symbol_make (const char *name, segT section, valueT value, fragS *frag)
{
char *name_copy;
struct local_symbol *ret;
@@ -234,8 +223,7 @@ local_symbol_make (name, section, value, frag)
reclaim the space used by the local symbol. */
static symbolS *
-local_symbol_convert (locsym)
- struct local_symbol *locsym;
+local_symbol_convert (struct local_symbol *locsym)
{
symbolS *ret;
@@ -281,9 +269,9 @@ local_symbol_convert (locsym)
Gripes if we are redefining a symbol incompatibly (and ignores it). */
symbolS *
-colon (sym_name) /* Just seen "x:" - rattle symbols & frags. */
- const char *sym_name; /* Symbol name, as a cannonical string. */
- /* We copy this string: OK to alter later. */
+colon (/* Just seen "x:" - rattle symbols & frags. */
+ const char *sym_name /* Symbol name, as a cannonical string. */
+ /* We copy this string: OK to alter later. */)
{
register symbolS *symbolP; /* Symbol we are working with. */
@@ -313,6 +301,13 @@ colon (sym_name) /* Just seen "x:" - rattle symbols & frags. */
extern const int md_short_jump_size;
extern const int md_long_jump_size;
+
+ if (now_seg == absolute_section)
+ {
+ as_bad (_("cannot define symbol `%s' in absolute section"), sym_name);
+ return NULL;
+ }
+
possible_bytes = (md_short_jump_size
+ new_broken_words * md_long_jump_size);
@@ -483,7 +478,7 @@ colon (sym_name) /* Just seen "x:" - rattle symbols & frags. */
if (mri_common_symbol != NULL)
{
/* This symbol is actually being defined within an MRI common
- section. This requires special handling. */
+ section. This requires special handling. */
if (LOCAL_SYMBOL_CHECK (symbolP))
symbolP = local_symbol_convert ((struct local_symbol *) symbolP);
symbolP->sy_value.X_op = O_symbol;
@@ -507,8 +502,7 @@ colon (sym_name) /* Just seen "x:" - rattle symbols & frags. */
/* Die if we can't insert the symbol. */
void
-symbol_table_insert (symbolP)
- symbolS *symbolP;
+symbol_table_insert (symbolS *symbolP)
{
register const char *error_string;
@@ -536,8 +530,7 @@ symbol_table_insert (symbolP)
it into the symbol table. Return a pointer to it. */
symbolS *
-symbol_find_or_make (name)
- const char *name;
+symbol_find_or_make (const char *name)
{
register symbolS *symbolP;
@@ -568,8 +561,7 @@ symbol_find_or_make (name)
}
symbolS *
-symbol_make (name)
- const char *name;
+symbol_make (const char *name)
{
symbolS *symbolP;
@@ -582,14 +574,31 @@ symbol_make (name)
return (symbolP);
}
+symbolS *
+symbol_temp_new (segT seg, valueT ofs, fragS *frag)
+{
+ return symbol_new (FAKE_LABEL_NAME, seg, ofs, frag);
+}
+
+symbolS *
+symbol_temp_new_now (void)
+{
+ return symbol_temp_new (now_seg, frag_now_fix (), frag_now);
+}
+
+symbolS *
+symbol_temp_make (void)
+{
+ return symbol_make (FAKE_LABEL_NAME);
+}
+
/* Implement symbol table lookup.
In: A symbol's name as a string: '\0' can't be part of a symbol name.
Out: NULL if the name was not in the symbol table, else the address
of a struct symbol associated with that name. */
symbolS *
-symbol_find (name)
- const char *name;
+symbol_find (const char *name)
{
#ifdef STRIP_UNDERSCORE
return (symbol_find_base (name, 1));
@@ -599,8 +608,7 @@ symbol_find (name)
}
symbolS *
-symbol_find_exact (name)
- const char *name;
+symbol_find_exact (const char *name)
{
#ifdef BFD_ASSEMBLER
{
@@ -616,9 +624,7 @@ symbol_find_exact (name)
}
symbolS *
-symbol_find_base (name, strip_underscore)
- const char *name;
- int strip_underscore;
+symbol_find_base (const char *name, int strip_underscore)
{
if (strip_underscore && *name == '_')
name++;
@@ -662,11 +668,8 @@ symbol_find_base (name, strip_underscore)
/* Link symbol ADDME after symbol TARGET in the chain. */
void
-symbol_append (addme, target, rootPP, lastPP)
- symbolS *addme;
- symbolS *target;
- symbolS **rootPP;
- symbolS **lastPP;
+symbol_append (symbolS *addme, symbolS *target,
+ symbolS **rootPP, symbolS **lastPP)
{
if (LOCAL_SYMBOL_CHECK (addme))
abort ();
@@ -711,8 +714,7 @@ symbol_append (addme, target, rootPP, lastPP)
/* Set the chain pointers of SYMBOL to null. */
void
-symbol_clear_list_pointers (symbolP)
- symbolS *symbolP;
+symbol_clear_list_pointers (symbolS *symbolP)
{
if (LOCAL_SYMBOL_CHECK (symbolP))
abort ();
@@ -726,10 +728,7 @@ symbol_clear_list_pointers (symbolP)
/* Remove SYMBOLP from the list. */
void
-symbol_remove (symbolP, rootPP, lastPP)
- symbolS *symbolP;
- symbolS **rootPP;
- symbolS **lastPP;
+symbol_remove (symbolS *symbolP, symbolS **rootPP, symbolS **lastPP)
{
if (LOCAL_SYMBOL_CHECK (symbolP))
abort ();
@@ -760,11 +759,8 @@ symbol_remove (symbolP, rootPP, lastPP)
/* Link symbol ADDME before symbol TARGET in the chain. */
void
-symbol_insert (addme, target, rootPP, lastPP)
- symbolS *addme;
- symbolS *target;
- symbolS **rootPP;
- symbolS **lastPP ATTRIBUTE_UNUSED;
+symbol_insert (symbolS *addme, symbolS *target,
+ symbolS **rootPP, symbolS **lastPP ATTRIBUTE_UNUSED)
{
if (LOCAL_SYMBOL_CHECK (addme))
abort ();
@@ -791,9 +787,7 @@ symbol_insert (addme, target, rootPP, lastPP)
#endif /* SYMBOLS_NEED_BACKPOINTERS */
void
-verify_symbol_chain (rootP, lastP)
- symbolS *rootP;
- symbolS *lastP;
+verify_symbol_chain (symbolS *rootP, symbolS *lastP)
{
symbolS *symbolP = rootP;
@@ -817,8 +811,7 @@ verify_symbol_chain (rootP, lastP)
}
void
-verify_symbol_chain_2 (sym)
- symbolS *sym;
+verify_symbol_chain_2 (symbolS *sym)
{
symbolS *p = sym, *n = sym;
#ifdef SYMBOLS_NEED_BACKPOINTERS
@@ -830,13 +823,67 @@ verify_symbol_chain_2 (sym)
verify_symbol_chain (p, n);
}
+static void
+report_op_error (symbolS *symp, symbolS *left, symbolS *right)
+{
+ char *file;
+ unsigned int line;
+ segT seg_left = S_GET_SEGMENT (left);
+ segT seg_right = right ? S_GET_SEGMENT (right) : 0;
+
+ if (expr_symbol_where (symp, &file, &line))
+ {
+ if (seg_left == undefined_section)
+ as_bad_where (file, line,
+ _("undefined symbol `%s' in operation"),
+ S_GET_NAME (left));
+ if (seg_right == undefined_section)
+ as_bad_where (file, line,
+ _("undefined symbol `%s' in operation"),
+ S_GET_NAME (right));
+ if (seg_left != undefined_section
+ && seg_right != undefined_section)
+ {
+ if (right)
+ as_bad_where (file, line,
+ _("invalid sections for operation on `%s' and `%s'"),
+ S_GET_NAME (left), S_GET_NAME (right));
+ else
+ as_bad_where (file, line,
+ _("invalid section for operation on `%s'"),
+ S_GET_NAME (left));
+ }
+
+ }
+ else
+ {
+ if (seg_left == undefined_section)
+ as_bad (_("undefined symbol `%s' in operation setting `%s'"),
+ S_GET_NAME (left), S_GET_NAME (symp));
+ if (seg_right == undefined_section)
+ as_bad (_("undefined symbol `%s' in operation setting `%s'"),
+ S_GET_NAME (right), S_GET_NAME (symp));
+ if (seg_left != undefined_section
+ && seg_right != undefined_section)
+ {
+ if (right)
+ as_bad_where (file, line,
+ _("invalid sections for operation on `%s' and `%s' setting `%s'"),
+ S_GET_NAME (left), S_GET_NAME (right), S_GET_NAME (symp));
+ else
+ as_bad_where (file, line,
+ _("invalid section for operation on `%s' setting `%s'"),
+ S_GET_NAME (left), S_GET_NAME (symp));
+ }
+ }
+}
+
/* Resolve the value of a symbol. This is called during the final
pass over the symbol table to resolve any symbols with complex
values. */
valueT
-resolve_symbol_value (symp)
- symbolS *symp;
+resolve_symbol_value (symbolS *symp)
{
int resolved;
valueT final_val = 0;
@@ -995,6 +1042,17 @@ resolve_symbol_value (symp)
left = resolve_symbol_value (add_symbol);
seg_left = S_GET_SEGMENT (add_symbol);
+ /* By reducing these to the relevant dyadic operator, we get
+ !S -> S == 0 permitted on anything,
+ -S -> 0 - S only permitted on absolute
+ ~S -> S ^ ~0 only permitted on absolute */
+ if (op != O_logical_not && seg_left != absolute_section
+ && finalize_syms)
+ report_op_error (symp, add_symbol, NULL);
+
+ if (final_seg == expr_section || final_seg == undefined_section)
+ final_seg = absolute_section;
+
if (op == O_uminus)
left = -left;
else if (op == O_logical_not)
@@ -1003,8 +1061,6 @@ resolve_symbol_value (symp)
left = ~left;
final_val += left + symp->sy_frag->fr_address;
- if (final_seg == expr_section || final_seg == undefined_section)
- final_seg = seg_left;
resolved = symbol_resolved_p (add_symbol);
break;
@@ -1070,57 +1126,19 @@ resolve_symbol_value (symp)
Don't emit messages unless we're finalizing the symbol value,
otherwise we may get the same message multiple times. */
- if ((op == O_eq || op == O_ne)
- || ((op == O_subtract
- || op == O_lt || op == O_le || op == O_ge || op == O_gt)
- && seg_left == seg_right
- && (seg_left != undefined_section
- || add_symbol == op_symbol))
- || (seg_left == absolute_section
- && seg_right == absolute_section))
- {
- if (final_seg == expr_section || final_seg == undefined_section)
- final_seg = absolute_section;
- }
- else if (finalize_syms)
- {
- char *file;
- unsigned int line;
+ if (finalize_syms
+ && !(seg_left == absolute_section
+ && seg_right == absolute_section)
+ && !(op == O_eq || op == O_ne)
+ && !((op == O_subtract
+ || op == O_lt || op == O_le || op == O_ge || op == O_gt)
+ && seg_left == seg_right
+ && (seg_left != undefined_section
+ || add_symbol == op_symbol)))
+ report_op_error (symp, add_symbol, op_symbol);
- if (expr_symbol_where (symp, &file, &line))
- {
- if (seg_left == undefined_section)
- as_bad_where (file, line,
- _("undefined symbol `%s' in operation"),
- S_GET_NAME (symp->sy_value.X_add_symbol));
- if (seg_right == undefined_section)
- as_bad_where (file, line,
- _("undefined symbol `%s' in operation"),
- S_GET_NAME (symp->sy_value.X_op_symbol));
- if (seg_left != undefined_section
- && seg_right != undefined_section)
- as_bad_where (file, line,
- _("invalid section for operation"));
- }
- else
- {
- if (seg_left == undefined_section)
- as_bad (_("undefined symbol `%s' in operation setting `%s'"),
- S_GET_NAME (symp->sy_value.X_add_symbol),
- S_GET_NAME (symp));
- if (seg_right == undefined_section)
- as_bad (_("undefined symbol `%s' in operation setting `%s'"),
- S_GET_NAME (symp->sy_value.X_op_symbol),
- S_GET_NAME (symp));
- if (seg_left != undefined_section
- && seg_right != undefined_section)
- as_bad (_("invalid section for operation setting `%s'"),
- S_GET_NAME (symp));
- }
- /* Prevent the error propagating. */
- if (final_seg == expr_section || final_seg == undefined_section)
- final_seg = absolute_section;
- }
+ if (final_seg == expr_section || final_seg == undefined_section)
+ final_seg = absolute_section;
/* Check for division by zero. */
if ((op == O_divide || op == O_modulus) && right == 0)
@@ -1233,14 +1251,12 @@ exit_dont_set_value:
#ifdef BFD_ASSEMBLER
-static void resolve_local_symbol PARAMS ((const char *, PTR));
+static void resolve_local_symbol (const char *, PTR);
/* A static function passed to hash_traverse. */
static void
-resolve_local_symbol (key, value)
- const char *key ATTRIBUTE_UNUSED;
- PTR value;
+resolve_local_symbol (const char *key ATTRIBUTE_UNUSED, PTR value)
{
if (value != NULL)
resolve_symbol_value (value);
@@ -1251,7 +1267,7 @@ resolve_local_symbol (key, value)
/* Resolve all local symbols. */
void
-resolve_local_symbol_values ()
+resolve_local_symbol_values (void)
{
#ifdef BFD_ASSEMBLER
hash_traverse (local_hash, resolve_local_symbol);
@@ -1272,8 +1288,7 @@ static unsigned long dollar_label_count;
static unsigned long dollar_label_max;
int
-dollar_label_defined (label)
- long label;
+dollar_label_defined (long label)
{
long *i;
@@ -1288,8 +1303,7 @@ dollar_label_defined (label)
}
static long
-dollar_label_instance (label)
- long label;
+dollar_label_instance (long label)
{
long *i;
@@ -1305,7 +1319,7 @@ dollar_label_instance (label)
}
void
-dollar_label_clear ()
+dollar_label_clear (void)
{
memset (dollar_label_defines, '\0', (unsigned int) dollar_label_count);
}
@@ -1313,8 +1327,7 @@ dollar_label_clear ()
#define DOLLAR_LABEL_BUMP_BY 10
void
-define_dollar_label (label)
- long label;
+define_dollar_label (long label)
{
long *i;
@@ -1364,9 +1377,8 @@ define_dollar_label (label)
of ^A. */
char * /* Return local label name. */
-dollar_label_name (n, augend)
- register long n; /* we just saw "n$:" : n a number. */
- register int augend; /* 0 for current instance, 1 for new instance. */
+dollar_label_name (register long n, /* we just saw "n$:" : n a number. */
+ register int augend /* 0 for current instance, 1 for new instance. */)
{
long i;
/* Returned to caller, then copied. Used for created names ("4f"). */
@@ -1409,7 +1421,7 @@ dollar_label_name (n, augend)
return symbol_name_build;
}
-/* Sombody else's idea of local labels. They are made by "n:" where n
+/* Somebody else's idea of local labels. They are made by "n:" where n
is any decimal digit. Refer to them with
"nb" for previous (backward) n:
or "nf" for next (forward) n:.
@@ -1438,7 +1450,7 @@ static long fb_label_max;
#define FB_LABEL_BUMP_BY (FB_LABEL_SPECIAL + 6)
static void
-fb_label_init ()
+fb_label_init (void)
{
memset ((void *) fb_low_counter, '\0', sizeof (fb_low_counter));
}
@@ -1446,8 +1458,7 @@ fb_label_init ()
/* Add one to the instance number of this fb label. */
void
-fb_label_instance_inc (label)
- long label;
+fb_label_instance_inc (long label)
{
long *i;
@@ -1495,8 +1506,7 @@ fb_label_instance_inc (label)
}
static long
-fb_label_instance (label)
- long label;
+fb_label_instance (long label)
{
long *i;
@@ -1534,9 +1544,8 @@ fb_label_instance (label)
place of ^B. */
char * /* Return local label name. */
-fb_label_name (n, augend)
- long n; /* We just saw "n:", "nf" or "nb" : n a number. */
- long augend; /* 0 for nb, 1 for n:, nf. */
+fb_label_name (long n, /* We just saw "n:", "nf" or "nb" : n a number. */
+ long augend /* 0 for nb, 1 for n:, nf. */)
{
long i;
/* Returned to caller, then copied. Used for created names ("4f"). */
@@ -1584,8 +1593,7 @@ fb_label_name (n, augend)
unaltered. This is used for error messages. */
char *
-decode_local_label_name (s)
- char *s;
+decode_local_label_name (char *s)
{
char *p;
char *symbol_decode;
@@ -1626,8 +1634,7 @@ decode_local_label_name (s)
/* Get the value of a symbol. */
valueT
-S_GET_VALUE (s)
- symbolS *s;
+S_GET_VALUE (symbolS *s)
{
#ifdef BFD_ASSEMBLER
if (LOCAL_SYMBOL_CHECK (s))
@@ -1645,8 +1652,8 @@ S_GET_VALUE (s)
static symbolS *recur;
/* FIXME: In non BFD assemblers, S_IS_DEFINED and S_IS_COMMON
- may call S_GET_VALUE. We use a static symbol to avoid the
- immediate recursion. */
+ may call S_GET_VALUE. We use a static symbol to avoid the
+ immediate recursion. */
if (recur == s)
return (valueT) s->sy_value.X_add_number;
recur = s;
@@ -1663,9 +1670,7 @@ S_GET_VALUE (s)
/* Set the value of a symbol. */
void
-S_SET_VALUE (s, val)
- symbolS *s;
- valueT val;
+S_SET_VALUE (symbolS *s, valueT val)
{
#ifdef BFD_ASSEMBLER
if (LOCAL_SYMBOL_CHECK (s))
@@ -1681,8 +1686,7 @@ S_SET_VALUE (s, val)
}
void
-copy_symbol_attributes (dest, src)
- symbolS *dest, *src;
+copy_symbol_attributes (symbolS *dest, symbolS *src)
{
if (LOCAL_SYMBOL_CHECK (dest))
dest = local_symbol_convert ((struct local_symbol *) dest);
@@ -1704,8 +1708,7 @@ copy_symbol_attributes (dest, src)
#ifdef BFD_ASSEMBLER
int
-S_IS_FUNCTION (s)
- symbolS *s;
+S_IS_FUNCTION (symbolS *s)
{
flagword flags;
@@ -1718,8 +1721,7 @@ S_IS_FUNCTION (s)
}
int
-S_IS_EXTERNAL (s)
- symbolS *s;
+S_IS_EXTERNAL (symbolS *s)
{
flagword flags;
@@ -1736,8 +1738,7 @@ S_IS_EXTERNAL (s)
}
int
-S_IS_WEAK (s)
- symbolS *s;
+S_IS_WEAK (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return 0;
@@ -1745,8 +1746,7 @@ S_IS_WEAK (s)
}
int
-S_IS_COMMON (s)
- symbolS *s;
+S_IS_COMMON (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return 0;
@@ -1754,17 +1754,37 @@ S_IS_COMMON (s)
}
int
-S_IS_DEFINED (s)
- symbolS *s;
+S_IS_DEFINED (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return ((struct local_symbol *) s)->lsy_section != undefined_section;
return s->bsym->section != undefined_section;
}
+
+#ifndef EXTERN_FORCE_RELOC
+#define EXTERN_FORCE_RELOC IS_ELF
+#endif
+
+/* Return true for symbols that should not be reduced to section
+ symbols or eliminated from expressions, because they may be
+ overridden by the linker. */
int
-S_IS_DEBUG (s)
- symbolS *s;
+S_FORCE_RELOC (symbolS *s, int strict)
+{
+ if (LOCAL_SYMBOL_CHECK (s))
+ return ((struct local_symbol *) s)->lsy_section == undefined_section;
+
+ return ((strict
+ && ((s->bsym->flags & BSF_WEAK) != 0
+ || (EXTERN_FORCE_RELOC
+ && (s->bsym->flags & BSF_GLOBAL) != 0)))
+ || s->bsym->section == undefined_section
+ || bfd_is_com_section (s->bsym->section));
+}
+
+int
+S_IS_DEBUG (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return 0;
@@ -1774,8 +1794,7 @@ S_IS_DEBUG (s)
}
int
-S_IS_LOCAL (s)
- symbolS *s;
+S_IS_LOCAL (symbolS *s)
{
flagword flags;
const char *name;
@@ -1810,22 +1829,19 @@ S_IS_LOCAL (s)
}
int
-S_IS_EXTERN (s)
- symbolS *s;
+S_IS_EXTERN (symbolS *s)
{
return S_IS_EXTERNAL (s);
}
int
-S_IS_STABD (s)
- symbolS *s;
+S_IS_STABD (symbolS *s)
{
return S_GET_NAME (s) == 0;
}
const char *
-S_GET_NAME (s)
- symbolS *s;
+S_GET_NAME (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return ((struct local_symbol *) s)->lsy_name;
@@ -1833,8 +1849,7 @@ S_GET_NAME (s)
}
segT
-S_GET_SEGMENT (s)
- symbolS *s;
+S_GET_SEGMENT (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return ((struct local_symbol *) s)->lsy_section;
@@ -1842,9 +1857,7 @@ S_GET_SEGMENT (s)
}
void
-S_SET_SEGMENT (s, seg)
- symbolS *s;
- segT seg;
+S_SET_SEGMENT (symbolS *s, segT seg)
{
/* Don't reassign section symbols. The direct reason is to prevent seg
faults assigning back to const global symbols such as *ABS*, but it
@@ -1871,8 +1884,7 @@ S_SET_SEGMENT (s, seg)
}
void
-S_SET_EXTERNAL (s)
- symbolS *s;
+S_SET_EXTERNAL (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
s = local_symbol_convert ((struct local_symbol *) s);
@@ -1897,8 +1909,7 @@ S_SET_EXTERNAL (s)
}
void
-S_CLEAR_EXTERNAL (s)
- symbolS *s;
+S_CLEAR_EXTERNAL (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return;
@@ -1912,8 +1923,7 @@ S_CLEAR_EXTERNAL (s)
}
void
-S_SET_WEAK (s)
- symbolS *s;
+S_SET_WEAK (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
s = local_symbol_convert ((struct local_symbol *) s);
@@ -1922,9 +1932,25 @@ S_SET_WEAK (s)
}
void
-S_SET_NAME (s, name)
- symbolS *s;
- char *name;
+S_SET_THREAD_LOCAL (symbolS *s)
+{
+ if (LOCAL_SYMBOL_CHECK (s))
+ s = local_symbol_convert ((struct local_symbol *) s);
+ if (bfd_is_com_section (s->bsym->section)
+ && (s->bsym->flags & BSF_THREAD_LOCAL) != 0)
+ return;
+ s->bsym->flags |= BSF_THREAD_LOCAL;
+ if ((s->bsym->flags & BSF_FUNCTION) != 0)
+ as_bad (_("Accessing function `%s' as thread-local object"),
+ S_GET_NAME (s));
+ else if (! bfd_is_und_section (s->bsym->section)
+ && (s->bsym->section->flags & SEC_THREAD_LOCAL) == 0)
+ as_bad (_("Accessing `%s' as thread-local object"),
+ S_GET_NAME (s));
+}
+
+void
+S_SET_NAME (symbolS *s, char *name)
{
if (LOCAL_SYMBOL_CHECK (s))
{
@@ -1940,8 +1966,7 @@ S_SET_NAME (s, name)
/* Return the previous symbol in a chain. */
symbolS *
-symbol_previous (s)
- symbolS *s;
+symbol_previous (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
abort ();
@@ -1953,8 +1978,7 @@ symbol_previous (s)
/* Return the next symbol in a chain. */
symbolS *
-symbol_next (s)
- symbolS *s;
+symbol_next (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
abort ();
@@ -1964,8 +1988,7 @@ symbol_next (s)
/* Return a pointer to the value of a symbol as an expression. */
expressionS *
-symbol_get_value_expression (s)
- symbolS *s;
+symbol_get_value_expression (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
s = local_symbol_convert ((struct local_symbol *) s);
@@ -1975,21 +1998,27 @@ symbol_get_value_expression (s)
/* Set the value of a symbol to an expression. */
void
-symbol_set_value_expression (s, exp)
- symbolS *s;
- const expressionS *exp;
+symbol_set_value_expression (symbolS *s, const expressionS *exp)
{
if (LOCAL_SYMBOL_CHECK (s))
s = local_symbol_convert ((struct local_symbol *) s);
s->sy_value = *exp;
}
+/* Set the value of SYM to the current position in the current segment. */
+
+void
+symbol_set_value_now (symbolS *sym)
+{
+ S_SET_SEGMENT (sym, now_seg);
+ S_SET_VALUE (sym, frag_now_fix ());
+ symbol_set_frag (sym, frag_now);
+}
+
/* Set the frag of a symbol. */
void
-symbol_set_frag (s, f)
- symbolS *s;
- fragS *f;
+symbol_set_frag (symbolS *s, fragS *f)
{
#ifdef BFD_ASSEMBLER
if (LOCAL_SYMBOL_CHECK (s))
@@ -2004,8 +2033,7 @@ symbol_set_frag (s, f)
/* Return the frag of a symbol. */
fragS *
-symbol_get_frag (s)
- symbolS *s;
+symbol_get_frag (symbolS *s)
{
#ifdef BFD_ASSEMBLER
if (LOCAL_SYMBOL_CHECK (s))
@@ -2017,8 +2045,7 @@ symbol_get_frag (s)
/* Mark a symbol as having been used. */
void
-symbol_mark_used (s)
- symbolS *s;
+symbol_mark_used (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return;
@@ -2028,8 +2055,7 @@ symbol_mark_used (s)
/* Clear the mark of whether a symbol has been used. */
void
-symbol_clear_used (s)
- symbolS *s;
+symbol_clear_used (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
s = local_symbol_convert ((struct local_symbol *) s);
@@ -2039,8 +2065,7 @@ symbol_clear_used (s)
/* Return whether a symbol has been used. */
int
-symbol_used_p (s)
- symbolS *s;
+symbol_used_p (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return 1;
@@ -2050,8 +2075,7 @@ symbol_used_p (s)
/* Mark a symbol as having been used in a reloc. */
void
-symbol_mark_used_in_reloc (s)
- symbolS *s;
+symbol_mark_used_in_reloc (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
s = local_symbol_convert ((struct local_symbol *) s);
@@ -2061,8 +2085,7 @@ symbol_mark_used_in_reloc (s)
/* Clear the mark of whether a symbol has been used in a reloc. */
void
-symbol_clear_used_in_reloc (s)
- symbolS *s;
+symbol_clear_used_in_reloc (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return;
@@ -2072,8 +2095,7 @@ symbol_clear_used_in_reloc (s)
/* Return whether a symbol has been used in a reloc. */
int
-symbol_used_in_reloc_p (s)
- symbolS *s;
+symbol_used_in_reloc_p (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return 0;
@@ -2083,8 +2105,7 @@ symbol_used_in_reloc_p (s)
/* Mark a symbol as an MRI common symbol. */
void
-symbol_mark_mri_common (s)
- symbolS *s;
+symbol_mark_mri_common (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
s = local_symbol_convert ((struct local_symbol *) s);
@@ -2094,8 +2115,7 @@ symbol_mark_mri_common (s)
/* Clear the mark of whether a symbol is an MRI common symbol. */
void
-symbol_clear_mri_common (s)
- symbolS *s;
+symbol_clear_mri_common (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return;
@@ -2105,8 +2125,7 @@ symbol_clear_mri_common (s)
/* Return whether a symbol is an MRI common symbol. */
int
-symbol_mri_common_p (s)
- symbolS *s;
+symbol_mri_common_p (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return 0;
@@ -2116,8 +2135,7 @@ symbol_mri_common_p (s)
/* Mark a symbol as having been written. */
void
-symbol_mark_written (s)
- symbolS *s;
+symbol_mark_written (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return;
@@ -2127,8 +2145,7 @@ symbol_mark_written (s)
/* Clear the mark of whether a symbol has been written. */
void
-symbol_clear_written (s)
- symbolS *s;
+symbol_clear_written (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return;
@@ -2138,8 +2155,7 @@ symbol_clear_written (s)
/* Return whether a symbol has been written. */
int
-symbol_written_p (s)
- symbolS *s;
+symbol_written_p (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return 0;
@@ -2149,8 +2165,7 @@ symbol_written_p (s)
/* Mark a symbol has having been resolved. */
void
-symbol_mark_resolved (s)
- symbolS *s;
+symbol_mark_resolved (symbolS *s)
{
#ifdef BFD_ASSEMBLER
if (LOCAL_SYMBOL_CHECK (s))
@@ -2165,8 +2180,7 @@ symbol_mark_resolved (s)
/* Return whether a symbol has been resolved. */
int
-symbol_resolved_p (s)
- symbolS *s;
+symbol_resolved_p (symbolS *s)
{
#ifdef BFD_ASSEMBLER
if (LOCAL_SYMBOL_CHECK (s))
@@ -2178,8 +2192,7 @@ symbol_resolved_p (s)
/* Return whether a symbol is a section symbol. */
int
-symbol_section_p (s)
- symbolS *s ATTRIBUTE_UNUSED;
+symbol_section_p (symbolS *s ATTRIBUTE_UNUSED)
{
if (LOCAL_SYMBOL_CHECK (s))
return 0;
@@ -2194,8 +2207,7 @@ symbol_section_p (s)
/* Return whether a symbol is equated to another symbol. */
int
-symbol_equated_p (s)
- symbolS *s;
+symbol_equated_p (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return 0;
@@ -2206,8 +2218,7 @@ symbol_equated_p (s)
treated specially when writing out relocs. */
int
-symbol_equated_reloc_p (s)
- symbolS *s;
+symbol_equated_reloc_p (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return 0;
@@ -2223,8 +2234,7 @@ symbol_equated_reloc_p (s)
/* Return whether a symbol has a constant value. */
int
-symbol_constant_p (s)
- symbolS *s;
+symbol_constant_p (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
return 1;
@@ -2236,8 +2246,7 @@ symbol_constant_p (s)
/* Return the BFD symbol for a symbol. */
asymbol *
-symbol_get_bfdsym (s)
- symbolS *s;
+symbol_get_bfdsym (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
s = local_symbol_convert ((struct local_symbol *) s);
@@ -2247,9 +2256,7 @@ symbol_get_bfdsym (s)
/* Set the BFD symbol for a symbol. */
void
-symbol_set_bfdsym (s, bsym)
- symbolS *s;
- asymbol *bsym;
+symbol_set_bfdsym (symbolS *s, asymbol *bsym)
{
if (LOCAL_SYMBOL_CHECK (s))
s = local_symbol_convert ((struct local_symbol *) s);
@@ -2263,8 +2270,7 @@ symbol_set_bfdsym (s, bsym)
/* Get a pointer to the object format information for a symbol. */
OBJ_SYMFIELD_TYPE *
-symbol_get_obj (s)
- symbolS *s;
+symbol_get_obj (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
s = local_symbol_convert ((struct local_symbol *) s);
@@ -2274,9 +2280,7 @@ symbol_get_obj (s)
/* Set the object format information for a symbol. */
void
-symbol_set_obj (s, o)
- symbolS *s;
- OBJ_SYMFIELD_TYPE *o;
+symbol_set_obj (symbolS *s, OBJ_SYMFIELD_TYPE *o)
{
if (LOCAL_SYMBOL_CHECK (s))
s = local_symbol_convert ((struct local_symbol *) s);
@@ -2290,8 +2294,7 @@ symbol_set_obj (s, o)
/* Get a pointer to the processor information for a symbol. */
TC_SYMFIELD_TYPE *
-symbol_get_tc (s)
- symbolS *s;
+symbol_get_tc (symbolS *s)
{
if (LOCAL_SYMBOL_CHECK (s))
s = local_symbol_convert ((struct local_symbol *) s);
@@ -2301,9 +2304,7 @@ symbol_get_tc (s)
/* Set the processor information for a symbol. */
void
-symbol_set_tc (s, o)
- symbolS *s;
- TC_SYMFIELD_TYPE *o;
+symbol_set_tc (symbolS *s, TC_SYMFIELD_TYPE *o)
{
if (LOCAL_SYMBOL_CHECK (s))
s = local_symbol_convert ((struct local_symbol *) s);
@@ -2313,7 +2314,7 @@ symbol_set_tc (s, o)
#endif /* TC_SYMFIELD_TYPE */
void
-symbol_begin ()
+symbol_begin (void)
{
symbol_lastP = NULL;
symbol_rootP = NULL; /* In case we have 0 symbols (!!) */
@@ -2347,7 +2348,7 @@ int max_indent_level = 8;
#if 0
static void
-indent ()
+indent (void)
{
printf ("%*s", indent_level * 4, "");
}
@@ -2355,9 +2356,7 @@ indent ()
#endif
void
-print_symbol_value_1 (file, sym)
- FILE *file;
- symbolS *sym;
+print_symbol_value_1 (FILE *file, symbolS *sym)
{
const char *name = S_GET_NAME (sym);
if (!name || !name[0])
@@ -2427,8 +2426,7 @@ print_symbol_value_1 (file, sym)
}
void
-print_symbol_value (sym)
- symbolS *sym;
+print_symbol_value (symbolS *sym)
{
indent_level = 0;
print_symbol_value_1 (stderr, sym);
@@ -2436,10 +2434,7 @@ print_symbol_value (sym)
}
static void
-print_binary (file, name, exp)
- FILE *file;
- const char *name;
- expressionS *exp;
+print_binary (FILE *file, const char *name, expressionS *exp)
{
indent_level++;
fprintf (file, "%s\n%*s<", name, indent_level * 4, "");
@@ -2451,9 +2446,7 @@ print_binary (file, name, exp)
}
void
-print_expr_1 (file, exp)
- FILE *file;
- expressionS *exp;
+print_expr_1 (FILE *file, expressionS *exp)
{
fprintf (file, "expr %lx ", (long) exp);
switch (exp->X_op)
@@ -2565,16 +2558,14 @@ print_expr_1 (file, exp)
}
void
-print_expr (exp)
- expressionS *exp;
+print_expr (expressionS *exp)
{
print_expr_1 (stderr, exp);
fprintf (stderr, "\n");
}
void
-symbol_print_statistics (file)
- FILE *file;
+symbol_print_statistics (FILE *file)
{
hash_print_statistics (file, "symbol table", sy_hash);
#ifdef BFD_ASSEMBLER
diff --git a/contrib/binutils/gas/symbols.h b/contrib/binutils/gas/symbols.h
index 2fb0439..15dc263 100644
--- a/contrib/binutils/gas/symbols.h
+++ b/contrib/binutils/gas/symbols.h
@@ -1,6 +1,6 @@
/* symbols.h -
Copyright 1987, 1990, 1992, 1993, 1994, 1995, 1997, 1999, 2000, 2001,
- 2002 Free Software Foundation, Inc.
+ 2002, 2003 Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -47,60 +47,68 @@ extern int symbol_table_frozen;
default. */
extern int symbols_case_sensitive;
-char *decode_local_label_name PARAMS ((char *s));
-symbolS *symbol_find PARAMS ((const char *name));
-symbolS *symbol_find_exact PARAMS ((const char *name));
-symbolS *symbol_find_base PARAMS ((const char *name, int strip_underscore));
-symbolS *symbol_find_or_make PARAMS ((const char *name));
-symbolS *symbol_make PARAMS ((const char *name));
-symbolS *symbol_new PARAMS ((const char *name, segT segment, valueT value,
- fragS * frag));
-symbolS *symbol_create PARAMS ((const char *name, segT segment, valueT value,
- fragS * frag));
-symbolS *colon PARAMS ((const char *sym_name));
-void local_colon PARAMS ((int n));
-void symbol_begin PARAMS ((void));
-void symbol_print_statistics PARAMS ((FILE *));
-void symbol_table_insert PARAMS ((symbolS * symbolP));
-valueT resolve_symbol_value PARAMS ((symbolS *));
-void resolve_local_symbol_values PARAMS ((void));
-
-void print_symbol_value PARAMS ((symbolS *));
-void print_expr PARAMS ((expressionS *));
-void print_expr_1 PARAMS ((FILE *, expressionS *));
-void print_symbol_value_1 PARAMS ((FILE *, symbolS *));
-
-int dollar_label_defined PARAMS ((long l));
-void dollar_label_clear PARAMS ((void));
-void define_dollar_label PARAMS ((long l));
-char *dollar_label_name PARAMS ((long l, int augend));
-
-void fb_label_instance_inc PARAMS ((long label));
-char *fb_label_name PARAMS ((long n, long augend));
-
-extern void copy_symbol_attributes PARAMS ((symbolS *, symbolS *));
+char *decode_local_label_name (char *s);
+symbolS *symbol_find (const char *name);
+symbolS *symbol_find_exact (const char *name);
+symbolS *symbol_find_base (const char *name, int strip_underscore);
+symbolS *symbol_find_or_make (const char *name);
+symbolS *symbol_make (const char *name);
+symbolS *symbol_new (const char *name, segT segment, valueT value,
+ fragS * frag);
+symbolS *symbol_create (const char *name, segT segment, valueT value,
+ fragS * frag);
+struct local_symbol *local_symbol_make (const char *name, segT section,
+ valueT value, fragS * frag);
+symbolS *symbol_temp_new (segT, valueT, fragS *);
+symbolS *symbol_temp_new_now (void);
+symbolS *symbol_temp_make (void);
+
+symbolS *colon (const char *sym_name);
+void local_colon (int n);
+void symbol_begin (void);
+void symbol_print_statistics (FILE *);
+void symbol_table_insert (symbolS * symbolP);
+valueT resolve_symbol_value (symbolS *);
+void resolve_local_symbol_values (void);
+
+void print_symbol_value (symbolS *);
+void print_expr (expressionS *);
+void print_expr_1 (FILE *, expressionS *);
+void print_symbol_value_1 (FILE *, symbolS *);
+
+int dollar_label_defined (long l);
+void dollar_label_clear (void);
+void define_dollar_label (long l);
+char *dollar_label_name (long l, int augend);
+
+void fb_label_instance_inc (long label);
+char *fb_label_name (long n, long augend);
+
+extern void copy_symbol_attributes (symbolS *, symbolS *);
/* Get and set the values of symbols. These used to be macros. */
-extern valueT S_GET_VALUE PARAMS ((symbolS *));
-extern void S_SET_VALUE PARAMS ((symbolS *, valueT));
+extern valueT S_GET_VALUE (symbolS *);
+extern void S_SET_VALUE (symbolS *, valueT);
#ifdef BFD_ASSEMBLER
-extern int S_IS_FUNCTION PARAMS ((symbolS *));
-extern int S_IS_EXTERNAL PARAMS ((symbolS *));
-extern int S_IS_WEAK PARAMS ((symbolS *));
-extern int S_IS_COMMON PARAMS ((symbolS *));
-extern int S_IS_DEFINED PARAMS ((symbolS *));
-extern int S_IS_DEBUG PARAMS ((symbolS *));
-extern int S_IS_LOCAL PARAMS ((symbolS *));
-extern int S_IS_EXTERN PARAMS ((symbolS *));
-extern int S_IS_STABD PARAMS ((symbolS *));
-extern const char *S_GET_NAME PARAMS ((symbolS *));
-extern segT S_GET_SEGMENT PARAMS ((symbolS *));
-extern void S_SET_SEGMENT PARAMS ((symbolS *, segT));
-extern void S_SET_EXTERNAL PARAMS ((symbolS *));
-extern void S_SET_NAME PARAMS ((symbolS *, char *));
-extern void S_CLEAR_EXTERNAL PARAMS ((symbolS *));
-extern void S_SET_WEAK PARAMS ((symbolS *));
+extern int S_IS_FUNCTION (symbolS *);
+extern int S_IS_EXTERNAL (symbolS *);
+extern int S_IS_WEAK (symbolS *);
+extern int S_IS_COMMON (symbolS *);
+extern int S_IS_DEFINED (symbolS *);
+extern int S_FORCE_RELOC (symbolS *, int);
+extern int S_IS_DEBUG (symbolS *);
+extern int S_IS_LOCAL (symbolS *);
+extern int S_IS_EXTERN (symbolS *);
+extern int S_IS_STABD (symbolS *);
+extern const char *S_GET_NAME (symbolS *);
+extern segT S_GET_SEGMENT (symbolS *);
+extern void S_SET_SEGMENT (symbolS *, segT);
+extern void S_SET_EXTERNAL (symbolS *);
+extern void S_SET_NAME (symbolS *, char *);
+extern void S_CLEAR_EXTERNAL (symbolS *);
+extern void S_SET_WEAK (symbolS *);
+extern void S_SET_THREAD_LOCAL (symbolS *);
#endif
#ifndef WORKING_DOT_WORD
@@ -123,7 +131,7 @@ struct broken_word
symbolS *sub;
offsetT addnum;
- int added; /* nasty thing happend yet? */
+ int added; /* nasty thing happened yet? */
/* 1: added and has a long-jump */
/* 2: added but uses someone elses long-jump */
@@ -144,62 +152,62 @@ extern const short seg_N_TYPE[];/* subseg.c */
#define N_REGISTER 30 /* Fake N_TYPE value for SEG_REGISTER */
-void symbol_clear_list_pointers PARAMS ((symbolS * symbolP));
+void symbol_clear_list_pointers (symbolS * symbolP);
#ifdef SYMBOLS_NEED_BACKPOINTERS
-void symbol_insert PARAMS ((symbolS * addme, symbolS * target,
- symbolS ** rootP, symbolS ** lastP));
-void symbol_remove PARAMS ((symbolS * symbolP, symbolS ** rootP,
- symbolS ** lastP));
+void symbol_insert (symbolS * addme, symbolS * target,
+ symbolS ** rootP, symbolS ** lastP);
+void symbol_remove (symbolS * symbolP, symbolS ** rootP,
+ symbolS ** lastP);
-extern symbolS *symbol_previous PARAMS ((symbolS *));
+extern symbolS *symbol_previous (symbolS *);
#endif /* SYMBOLS_NEED_BACKPOINTERS */
-void verify_symbol_chain PARAMS ((symbolS * rootP, symbolS * lastP));
-void verify_symbol_chain_2 PARAMS ((symbolS * symP));
-
-void symbol_append PARAMS ((symbolS * addme, symbolS * target,
- symbolS ** rootP, symbolS ** lastP));
-
-extern symbolS *symbol_next PARAMS ((symbolS *));
-
-extern expressionS *symbol_get_value_expression PARAMS ((symbolS *));
-extern void symbol_set_value_expression PARAMS ((symbolS *,
- const expressionS *));
-extern void symbol_set_frag PARAMS ((symbolS *, fragS *));
-extern fragS *symbol_get_frag PARAMS ((symbolS *));
-extern void symbol_mark_used PARAMS ((symbolS *));
-extern void symbol_clear_used PARAMS ((symbolS *));
-extern int symbol_used_p PARAMS ((symbolS *));
-extern void symbol_mark_used_in_reloc PARAMS ((symbolS *));
-extern void symbol_clear_used_in_reloc PARAMS ((symbolS *));
-extern int symbol_used_in_reloc_p PARAMS ((symbolS *));
-extern void symbol_mark_mri_common PARAMS ((symbolS *));
-extern void symbol_clear_mri_common PARAMS ((symbolS *));
-extern int symbol_mri_common_p PARAMS ((symbolS *));
-extern void symbol_mark_written PARAMS ((symbolS *));
-extern void symbol_clear_written PARAMS ((symbolS *));
-extern int symbol_written_p PARAMS ((symbolS *));
-extern void symbol_mark_resolved PARAMS ((symbolS *));
-extern int symbol_resolved_p PARAMS ((symbolS *));
-extern int symbol_section_p PARAMS ((symbolS *));
-extern int symbol_equated_p PARAMS ((symbolS *));
-extern int symbol_equated_reloc_p PARAMS ((symbolS *));
-extern int symbol_constant_p PARAMS ((symbolS *));
+void verify_symbol_chain (symbolS * rootP, symbolS * lastP);
+void verify_symbol_chain_2 (symbolS * symP);
+
+void symbol_append (symbolS * addme, symbolS * target,
+ symbolS ** rootP, symbolS ** lastP);
+
+extern symbolS *symbol_next (symbolS *);
+
+extern expressionS *symbol_get_value_expression (symbolS *);
+extern void symbol_set_value_expression (symbolS *, const expressionS *);
+extern void symbol_set_value_now (symbolS *);
+extern void symbol_set_frag (symbolS *, fragS *);
+extern fragS *symbol_get_frag (symbolS *);
+extern void symbol_mark_used (symbolS *);
+extern void symbol_clear_used (symbolS *);
+extern int symbol_used_p (symbolS *);
+extern void symbol_mark_used_in_reloc (symbolS *);
+extern void symbol_clear_used_in_reloc (symbolS *);
+extern int symbol_used_in_reloc_p (symbolS *);
+extern void symbol_mark_mri_common (symbolS *);
+extern void symbol_clear_mri_common (symbolS *);
+extern int symbol_mri_common_p (symbolS *);
+extern void symbol_mark_written (symbolS *);
+extern void symbol_clear_written (symbolS *);
+extern int symbol_written_p (symbolS *);
+extern void symbol_mark_resolved (symbolS *);
+extern int symbol_resolved_p (symbolS *);
+extern int symbol_section_p (symbolS *);
+extern int symbol_equated_p (symbolS *);
+extern int symbol_equated_reloc_p (symbolS *);
+extern int symbol_constant_p (symbolS *);
#ifdef BFD_ASSEMBLER
-extern asymbol *symbol_get_bfdsym PARAMS ((symbolS *));
-extern void symbol_set_bfdsym PARAMS ((symbolS *, asymbol *));
+extern asymbol *symbol_get_bfdsym (symbolS *);
+extern void symbol_set_bfdsym (symbolS *, asymbol *);
#endif
#ifdef OBJ_SYMFIELD_TYPE
-OBJ_SYMFIELD_TYPE *symbol_get_obj PARAMS ((symbolS *));
-void symbol_set_obj PARAMS ((symbolS *, OBJ_SYMFIELD_TYPE *));
+OBJ_SYMFIELD_TYPE *symbol_get_obj (symbolS *);
+void symbol_set_obj (symbolS *, OBJ_SYMFIELD_TYPE *);
#endif
#ifdef TC_SYMFIELD_TYPE
-TC_SYMFIELD_TYPE *symbol_get_tc PARAMS ((symbolS *));
-void symbol_set_tc PARAMS ((symbolS *, TC_SYMFIELD_TYPE *));
+TC_SYMFIELD_TYPE *symbol_get_tc (symbolS *);
+void symbol_set_tc (symbolS *, TC_SYMFIELD_TYPE *);
#endif
diff --git a/contrib/binutils/gas/tc.h b/contrib/binutils/gas/tc.h
index c8cb13c..f4a2826 100644
--- a/contrib/binutils/gas/tc.h
+++ b/contrib/binutils/gas/tc.h
@@ -1,6 +1,6 @@
/* tc.h - target cpu dependent
- Copyright 1987, 1990, 1991, 1992, 1993, 1994, 1995, 2000
+ Copyright 1987, 1990, 1991, 1992, 1993, 1994, 1995, 2000, 2001, 2003
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -45,66 +45,68 @@ typedef struct relax_type relax_typeS;
extern const int md_reloc_size; /* Size of a relocation record */
-char *md_atof PARAMS ((int what_statement_type, char *literalP, int *sizeP));
+char *md_atof (int what_statement_type, char *literalP, int *sizeP);
#ifndef md_estimate_size_before_relax
-int md_estimate_size_before_relax PARAMS ((fragS * fragP, segT segment));
+int md_estimate_size_before_relax (fragS * fragP, segT segment);
#endif
-int md_parse_option PARAMS ((int c, char *arg));
-void md_show_usage PARAMS ((FILE *));
-long md_pcrel_from PARAMS ((fixS * fixP));
-short tc_coff_fix2rtype PARAMS ((fixS * fixP));
-void md_assemble PARAMS ((char *str));
-void md_begin PARAMS ((void));
+int md_parse_option (int c, char *arg);
+void md_show_usage (FILE *);
+#ifndef md_pcrel_from
+long md_pcrel_from (fixS * fixP);
+#endif
+short tc_coff_fix2rtype (fixS * fixP);
+void md_assemble (char *str);
+void md_begin (void);
#ifndef md_create_long_jump
-void md_create_long_jump PARAMS ((char *ptr, addressT from_addr,
- addressT to_addr, fragS * frag,
- symbolS * to_symbol));
+void md_create_long_jump (char *ptr, addressT from_addr,
+ addressT to_addr, fragS * frag,
+ symbolS * to_symbol);
#endif
#ifndef md_create_short_jump
-void md_create_short_jump PARAMS ((char *ptr, addressT from_addr,
- addressT to_addr, fragS * frag,
- symbolS * to_symbol));
+void md_create_short_jump (char *ptr, addressT from_addr,
+ addressT to_addr, fragS * frag,
+ symbolS * to_symbol);
#endif
-void md_number_to_chars PARAMS ((char *buf, valueT val, int n));
+void md_number_to_chars (char *buf, valueT val, int n);
#ifndef md_operand
-void md_operand PARAMS ((expressionS * expressionP));
+void md_operand (expressionS * expressionP);
#endif
-void md_apply_fix3 PARAMS ((fixS *, valueT *, segT));
+void md_apply_fix3 (fixS *, valueT *, segT);
#ifdef BFD_ASSEMBLER
#ifndef md_convert_frag
-void md_convert_frag PARAMS ((bfd * headers, segT sec, fragS * fragP));
+void md_convert_frag (bfd * headers, segT sec, fragS * fragP);
#endif
#ifndef tc_headers_hook
-void tc_headers_hook PARAMS ((segT *, fixS *));
+void tc_headers_hook (segT *, fixS *);
#endif
#ifndef RELOC_EXPANSION_POSSIBLE
-extern arelent *tc_gen_reloc PARAMS ((asection *, fixS *));
+extern arelent *tc_gen_reloc (asection *, fixS *);
#else
-extern arelent **tc_gen_reloc PARAMS ((asection *, fixS *));
+extern arelent **tc_gen_reloc (asection *, fixS *);
#endif
#else /* not BFD_ASSEMBLER */
#ifndef md_convert_frag
-void md_convert_frag PARAMS ((object_headers * headers, segT, fragS * fragP));
+void md_convert_frag (object_headers * headers, segT, fragS * fragP);
#endif
#ifndef tc_crawl_symbol_chain
-void tc_crawl_symbol_chain PARAMS ((object_headers * headers));
+void tc_crawl_symbol_chain (object_headers * headers);
#endif /* tc_crawl_symbol_chain */
#ifndef tc_headers_hook
-void tc_headers_hook PARAMS ((object_headers * headers));
+void tc_headers_hook (object_headers * headers);
#endif /* tc_headers_hook */
#endif /* BFD_ASSEMBLER */
#ifndef md_section_align
-valueT md_section_align PARAMS ((segT seg, valueT size));
+valueT md_section_align (segT seg, valueT size);
#endif
#ifndef md_undefined_symbol
-symbolS *md_undefined_symbol PARAMS ((char *name));
+symbolS *md_undefined_symbol (char *name);
#endif
/* end of tc.h */
diff --git a/contrib/binutils/gas/write.c b/contrib/binutils/gas/write.c
index f8120cb..5acd607 100644
--- a/contrib/binutils/gas/write.c
+++ b/contrib/binutils/gas/write.c
@@ -1,6 +1,6 @@
/* write.c - emit .o file
Copyright 1986, 1987, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997,
- 1998, 1999, 2000, 2001, 2002
+ 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler.
@@ -28,28 +28,65 @@
#include "output-file.h"
#include "dwarf2dbg.h"
-/* This looks like a good idea. Let's try turning it on always, for now. */
-#undef BFD_FAST_SECTION_FILL
-#define BFD_FAST_SECTION_FILL
-
#ifndef TC_ADJUST_RELOC_COUNT
-#define TC_ADJUST_RELOC_COUNT(FIXP,COUNT)
+#define TC_ADJUST_RELOC_COUNT(FIX, COUNT)
#endif
#ifndef TC_FORCE_RELOCATION
-#define TC_FORCE_RELOCATION(FIXP) 0
+#define TC_FORCE_RELOCATION(FIX) \
+ (generic_force_reloc (FIX))
+#endif
+
+#ifndef TC_FORCE_RELOCATION_ABS
+#define TC_FORCE_RELOCATION_ABS(FIX) \
+ (TC_FORCE_RELOCATION (FIX))
+#endif
+
+#ifndef TC_FORCE_RELOCATION_LOCAL
+#define TC_FORCE_RELOCATION_LOCAL(FIX) \
+ (!(FIX)->fx_pcrel \
+ || (FIX)->fx_plt \
+ || TC_FORCE_RELOCATION (FIX))
+#endif
+
+#ifndef TC_FORCE_RELOCATION_SUB_SAME
+#define TC_FORCE_RELOCATION_SUB_SAME(FIX, SEG) \
+ (! SEG_NORMAL (SEG))
+#endif
+
+#ifndef TC_FORCE_RELOCATION_SUB_ABS
+#define TC_FORCE_RELOCATION_SUB_ABS(FIX) 0
+#endif
+
+#ifndef TC_FORCE_RELOCATION_SUB_LOCAL
+#ifdef DIFF_EXPR_OK
+#define TC_FORCE_RELOCATION_SUB_LOCAL(FIX) 0
+#else
+#define TC_FORCE_RELOCATION_SUB_LOCAL(FIX) 1
+#endif
#endif
-#ifndef TC_FORCE_RELOCATION_SECTION
-#define TC_FORCE_RELOCATION_SECTION(FIXP,SEG) TC_FORCE_RELOCATION(FIXP)
+#ifndef TC_VALIDATE_FIX_SUB
+#ifdef UNDEFINED_DIFFERENCE_OK
+/* The PA needs this for PIC code generation. */
+#define TC_VALIDATE_FIX_SUB(FIX) 1
+#else
+#ifdef BFD_ASSEMBLER
+#define TC_VALIDATE_FIX_SUB(FIX) \
+ ((FIX)->fx_r_type == BFD_RELOC_GPREL32 \
+ || (FIX)->fx_r_type == BFD_RELOC_GPREL16)
+#else
+#define TC_VALIDATE_FIX_SUB(FIX) 0
+#endif
+#endif
#endif
#ifndef TC_LINKRELAX_FIXUP
#define TC_LINKRELAX_FIXUP(SEG) 1
#endif
-#ifndef TC_FIX_ADJUSTABLE
-#define TC_FIX_ADJUSTABLE(fix) 1
+#ifndef MD_APPLY_SYM_VALUE
+#define MD_APPLY_SYM_VALUE(FIX) 1
#endif
#ifndef TC_FINALIZE_SYMS_BEFORE_SIZE_SEG
@@ -57,7 +94,7 @@
#endif
#ifndef MD_PCREL_FROM_SECTION
-#define MD_PCREL_FROM_SECTION(FIXP, SEC) md_pcrel_from(FIXP)
+#define MD_PCREL_FROM_SECTION(FIX, SEC) md_pcrel_from (FIX)
#endif
#ifndef WORKING_DOT_WORD
@@ -69,10 +106,16 @@ extern const int md_long_jump_size;
int finalize_syms = 0;
int symbol_table_frozen;
-void print_fixup PARAMS ((fixS *));
+
+symbolS *abs_section_sym;
+
+/* Remember the value of dot when parsing expressions. */
+addressT dot_value;
+
+void print_fixup (fixS *);
#ifdef BFD_ASSEMBLER
-static void renumber_sections PARAMS ((bfd *, asection *, PTR));
+static void renumber_sections (bfd *, asection *, PTR);
/* We generally attach relocs to frag chains. However, after we have
chained these all together into a segment, any relocs we add after
@@ -109,57 +152,51 @@ int magic_number_for_object_file = DEFAULT_MAGIC_NUMBER_FOR_OBJECT_FILE;
static int n_fixups;
#ifdef BFD_ASSEMBLER
-static fixS *fix_new_internal PARAMS ((fragS *, int where, int size,
- symbolS *add, symbolS *sub,
- offsetT offset, int pcrel,
- bfd_reloc_code_real_type r_type));
+#define RELOC_ENUM enum bfd_reloc_code_real
#else
-static fixS *fix_new_internal PARAMS ((fragS *, int where, int size,
- symbolS *add, symbolS *sub,
- offsetT offset, int pcrel,
- int r_type));
+#define RELOC_ENUM int
#endif
+
+static fixS *fix_new_internal (fragS *, int where, int size,
+ symbolS *add, symbolS *sub,
+ offsetT offset, int pcrel,
+ RELOC_ENUM r_type);
#if defined (BFD_ASSEMBLER) || (!defined (BFD) && !defined (OBJ_VMS))
-static long fixup_segment PARAMS ((fixS * fixP, segT this_segment_type));
+static long fixup_segment (fixS *, segT);
#endif
-static relax_addressT relax_align PARAMS ((relax_addressT addr, int align));
+static relax_addressT relax_align (relax_addressT addr, int align);
#if defined (BFD_ASSEMBLER) || ! defined (BFD)
-static fragS *chain_frchains_together_1 PARAMS ((segT, struct frchain *));
+static fragS *chain_frchains_together_1 (segT, struct frchain *);
#endif
#ifdef BFD_ASSEMBLER
-static void chain_frchains_together PARAMS ((bfd *, segT, PTR));
-static void cvt_frag_to_fill PARAMS ((segT, fragS *));
-static void adjust_reloc_syms PARAMS ((bfd *, asection *, PTR));
-static void write_relocs PARAMS ((bfd *, asection *, PTR));
-static void write_contents PARAMS ((bfd *, asection *, PTR));
-static void set_symtab PARAMS ((void));
+static void chain_frchains_together (bfd *, segT, PTR);
+static void cvt_frag_to_fill (segT, fragS *);
+static void adjust_reloc_syms (bfd *, asection *, PTR);
+static void fix_segment (bfd *, asection *, PTR);
+static void write_relocs (bfd *, asection *, PTR);
+static void write_contents (bfd *, asection *, PTR);
+static void set_symtab (void);
#endif
#if defined (BFD_ASSEMBLER) || (! defined (BFD) && ! defined (OBJ_AOUT))
-static void merge_data_into_text PARAMS ((void));
+static void merge_data_into_text (void);
#endif
#if ! defined (BFD_ASSEMBLER) && ! defined (BFD)
-static void cvt_frag_to_fill PARAMS ((object_headers *, segT, fragS *));
-static void remove_subsegs PARAMS ((frchainS *, int, fragS **, fragS **));
-static void relax_and_size_all_segments PARAMS ((void));
+static void cvt_frag_to_fill (object_headers *, segT, fragS *);
+static void remove_subsegs (frchainS *, int, fragS **, fragS **);
+static void relax_and_size_all_segments (void);
#endif
/* Create a fixS in obstack 'notes'. */
static fixS *
-fix_new_internal (frag, where, size, add_symbol, sub_symbol, offset, pcrel,
- r_type)
- fragS *frag; /* Which frag? */
- int where; /* Where in that frag? */
- int size; /* 1, 2, or 4 usually. */
- symbolS *add_symbol; /* X_add_symbol. */
- symbolS *sub_symbol; /* X_op_symbol. */
- offsetT offset; /* X_add_number. */
- int pcrel; /* TRUE if PC-relative relocation. */
-#ifdef BFD_ASSEMBLER
- bfd_reloc_code_real_type r_type; /* Relocation type. */
-#else
- int r_type; /* Relocation type. */
-#endif
+fix_new_internal (fragS *frag, /* Which frag? */
+ int where, /* Where in that frag? */
+ int size, /* 1, 2, or 4 usually. */
+ symbolS *add_symbol, /* X_add_symbol. */
+ symbolS *sub_symbol, /* X_op_symbol. */
+ offsetT offset, /* X_add_number. */
+ int pcrel, /* TRUE if PC-relative relocation. */
+ RELOC_ENUM r_type ATTRIBUTE_UNUSED /* Relocation type. */)
{
fixS *fixP;
@@ -179,6 +216,7 @@ fix_new_internal (frag, where, size, add_symbol, sub_symbol, offset, pcrel,
fixP->fx_addsy = add_symbol;
fixP->fx_subsy = sub_symbol;
fixP->fx_offset = offset;
+ fixP->fx_dot_value = dot_value;
fixP->fx_pcrel = pcrel;
fixP->fx_plt = 0;
#if defined(NEED_FX_R_TYPE) || defined (BFD_ASSEMBLER)
@@ -243,18 +281,13 @@ fix_new_internal (frag, where, size, add_symbol, sub_symbol, offset, pcrel,
/* Create a fixup relative to a symbol (plus a constant). */
fixS *
-fix_new (frag, where, size, add_symbol, offset, pcrel, r_type)
- fragS *frag; /* Which frag? */
- int where; /* Where in that frag? */
- int size; /* 1, 2, or 4 usually. */
- symbolS *add_symbol; /* X_add_symbol. */
- offsetT offset; /* X_add_number. */
- int pcrel; /* TRUE if PC-relative relocation. */
-#ifdef BFD_ASSEMBLER
- bfd_reloc_code_real_type r_type; /* Relocation type. */
-#else
- int r_type; /* Relocation type. */
-#endif
+fix_new (fragS *frag, /* Which frag? */
+ int where, /* Where in that frag? */
+ int size, /* 1, 2, or 4 usually. */
+ symbolS *add_symbol, /* X_add_symbol. */
+ offsetT offset, /* X_add_number. */
+ int pcrel, /* TRUE if PC-relative relocation. */
+ RELOC_ENUM r_type /* Relocation type. */)
{
return fix_new_internal (frag, where, size, add_symbol,
(symbolS *) NULL, offset, pcrel, r_type);
@@ -265,17 +298,12 @@ fix_new (frag, where, size, add_symbol, offset, pcrel, r_type)
file formats support anyhow. */
fixS *
-fix_new_exp (frag, where, size, exp, pcrel, r_type)
- fragS *frag; /* Which frag? */
- int where; /* Where in that frag? */
- int size; /* 1, 2, or 4 usually. */
- expressionS *exp; /* Expression. */
- int pcrel; /* TRUE if PC-relative relocation. */
-#ifdef BFD_ASSEMBLER
- bfd_reloc_code_real_type r_type; /* Relocation type. */
-#else
- int r_type; /* Relocation type. */
-#endif
+fix_new_exp (fragS *frag, /* Which frag? */
+ int where, /* Where in that frag? */
+ int size, /* 1, 2, or 4 usually. */
+ expressionS *exp, /* Expression. */
+ int pcrel, /* TRUE if PC-relative relocation. */
+ RELOC_ENUM r_type /* Relocation type. */)
{
symbolS *add = NULL;
symbolS *sub = NULL;
@@ -342,12 +370,21 @@ fix_new_exp (frag, where, size, exp, pcrel, r_type)
return fix_new_internal (frag, where, size, add, sub, off, pcrel, r_type);
}
+/* Generic function to determine whether a fixup requires a relocation. */
+int
+generic_force_reloc (fixS *fix)
+{
+#ifdef BFD_ASSEMBLER
+ if (fix->fx_r_type == BFD_RELOC_VTABLE_INHERIT
+ || fix->fx_r_type == BFD_RELOC_VTABLE_ENTRY)
+ return 1;
+#endif
+ return S_FORCE_RELOC (fix->fx_addsy, fix->fx_subsy == NULL);
+}
+
/* Append a string onto another string, bumping the pointer along. */
void
-append (charPP, fromP, length)
- char **charPP;
- char *fromP;
- unsigned long length;
+append (char **charPP, char *fromP, unsigned long length)
{
/* Don't trust memcpy() of 0 chars. */
if (length == 0)
@@ -367,12 +404,11 @@ int section_alignment[SEG_MAXIMUM_ORDINAL];
least one object format really uses this info. */
void
-record_alignment (seg, align)
- /* Segment to which alignment pertains. */
- segT seg;
- /* Alignment, as a power of 2 (e.g., 1 => 2-byte boundary, 2 => 4-byte
- boundary, etc.) */
- int align;
+record_alignment (/* Segment to which alignment pertains. */
+ segT seg,
+ /* Alignment, as a power of 2 (e.g., 1 => 2-byte
+ boundary, 2 => 4-byte boundary, etc.) */
+ int align)
{
if (seg == absolute_section)
return;
@@ -386,8 +422,7 @@ record_alignment (seg, align)
}
int
-get_recorded_alignment (seg)
- segT seg;
+get_recorded_alignment (segT seg)
{
if (seg == absolute_section)
return 0;
@@ -403,10 +438,7 @@ get_recorded_alignment (seg)
/* Reset the section indices after removing the gas created sections. */
static void
-renumber_sections (abfd, sec, countparg)
- bfd *abfd ATTRIBUTE_UNUSED;
- asection *sec;
- PTR countparg;
+renumber_sections (bfd *abfd ATTRIBUTE_UNUSED, asection *sec, PTR countparg)
{
int *countp = (int *) countparg;
@@ -419,9 +451,7 @@ renumber_sections (abfd, sec, countparg)
#if defined (BFD_ASSEMBLER) || ! defined (BFD)
static fragS *
-chain_frchains_together_1 (section, frchp)
- segT section;
- struct frchain *frchp;
+chain_frchains_together_1 (segT section, struct frchain *frchp)
{
fragS dummy, *prev_frag = &dummy;
#ifdef BFD_ASSEMBLER
@@ -454,10 +484,9 @@ chain_frchains_together_1 (section, frchp)
#ifdef BFD_ASSEMBLER
static void
-chain_frchains_together (abfd, section, xxx)
- bfd *abfd ATTRIBUTE_UNUSED;
- segT section;
- PTR xxx ATTRIBUTE_UNUSED;
+chain_frchains_together (bfd *abfd ATTRIBUTE_UNUSED,
+ segT section,
+ PTR xxx ATTRIBUTE_UNUSED)
{
segment_info_type *info;
@@ -478,11 +507,7 @@ chain_frchains_together (abfd, section, xxx)
#if !defined (BFD) && !defined (BFD_ASSEMBLER)
static void
-remove_subsegs (head, seg, root, last)
- frchainS *head;
- int seg;
- fragS **root;
- fragS **last;
+remove_subsegs (frchainS *head, int seg, fragS **root, fragS **last)
{
*root = head->frch_root;
*last = chain_frchains_together_1 (seg, head);
@@ -494,15 +519,10 @@ remove_subsegs (head, seg, root, last)
#ifdef BFD_ASSEMBLER
static void
-cvt_frag_to_fill (sec, fragP)
- segT sec ATTRIBUTE_UNUSED;
- fragS *fragP;
+cvt_frag_to_fill (segT sec ATTRIBUTE_UNUSED, fragS *fragP)
#else
static void
-cvt_frag_to_fill (headersP, sec, fragP)
- object_headers *headersP;
- segT sec;
- fragS *fragP;
+cvt_frag_to_fill (object_headers *headersP, segT sec, fragS *fragP)
#endif
{
switch (fragP->fr_type)
@@ -601,12 +621,10 @@ cvt_frag_to_fill (headersP, sec, fragP)
#endif /* defined (BFD_ASSEMBLER) || !defined (BFD) */
#ifdef BFD_ASSEMBLER
-static void relax_seg PARAMS ((bfd *, asection *, PTR));
+static void relax_seg (bfd *, asection *, PTR);
+
static void
-relax_seg (abfd, sec, xxx)
- bfd *abfd ATTRIBUTE_UNUSED;
- asection *sec;
- PTR xxx;
+relax_seg (bfd *abfd ATTRIBUTE_UNUSED, asection *sec, PTR xxx)
{
segment_info_type *seginfo = seg_info (sec);
@@ -618,12 +636,10 @@ relax_seg (abfd, sec, xxx)
}
}
-static void size_seg PARAMS ((bfd *, asection *, PTR));
+static void size_seg (bfd *, asection *, PTR);
+
static void
-size_seg (abfd, sec, xxx)
- bfd *abfd;
- asection *sec;
- PTR xxx ATTRIBUTE_UNUSED;
+size_seg (bfd *abfd, asection *sec, PTR xxx ATTRIBUTE_UNUSED)
{
flagword flags;
fragS *fragp;
@@ -659,11 +675,11 @@ size_seg (abfd, sec, xxx)
else
flags &= ~SEC_RELOC;
x = bfd_set_section_flags (abfd, sec, flags);
- assert (x == true);
+ assert (x);
newsize = md_section_align (sec, size);
x = bfd_set_section_size (abfd, sec, newsize);
- assert (x == true);
+ assert (x);
/* If the size had to be rounded up, add some padding in the last
non-empty frag. */
@@ -732,11 +748,13 @@ dump_section_relocs (abfd, sec, stream_)
#define EMIT_SECTION_SYMBOLS 1
#endif
+/* This pass over fixups decides whether symbols can be replaced with
+ section symbols. */
+
static void
-adjust_reloc_syms (abfd, sec, xxx)
- bfd *abfd ATTRIBUTE_UNUSED;
- asection *sec;
- PTR xxx ATTRIBUTE_UNUSED;
+adjust_reloc_syms (bfd *abfd ATTRIBUTE_UNUSED,
+ asection *sec,
+ PTR xxx ATTRIBUTE_UNUSED)
{
segment_info_type *seginfo = seg_info (sec);
fixS *fixp;
@@ -766,64 +784,53 @@ adjust_reloc_syms (abfd, sec, xxx)
point. It is possible to see unresolved expression
symbols, though, since they are not in the regular symbol
table. */
- if (sym != NULL)
- resolve_symbol_value (sym);
+ resolve_symbol_value (sym);
if (fixp->fx_subsy != NULL)
resolve_symbol_value (fixp->fx_subsy);
/* If this symbol is equated to an undefined symbol, convert
the fixup to being against that symbol. */
- if (sym != NULL && symbol_equated_reloc_p (sym))
+ if (symbol_equated_reloc_p (sym))
{
fixp->fx_offset += symbol_get_value_expression (sym)->X_add_number;
sym = symbol_get_value_expression (sym)->X_add_symbol;
fixp->fx_addsy = sym;
}
- if (sym != NULL && symbol_mri_common_p (sym))
+ if (symbol_mri_common_p (sym))
{
/* These symbols are handled specially in fixup_segment. */
- goto done;
+ continue;
}
- symsec = S_GET_SEGMENT (sym);
+ /* If the symbol is undefined, common, weak, or global (ELF
+ shared libs), we can't replace it with the section symbol. */
+ if (S_FORCE_RELOC (fixp->fx_addsy, 1))
+ continue;
+
+ /* Is there some other (target cpu dependent) reason we can't adjust
+ this one? (E.g. relocations involving function addresses on
+ the PA. */
+#ifdef tc_fix_adjustable
+ if (! tc_fix_adjustable (fixp))
+ continue;
+#endif
+ /* Since we're reducing to section symbols, don't attempt to reduce
+ anything that's already using one. */
+ if (symbol_section_p (sym))
+ continue;
+
+ symsec = S_GET_SEGMENT (sym);
if (symsec == NULL)
abort ();
if (bfd_is_abs_section (symsec))
{
- /* The fixup_segment routine will not use this symbol in a
- relocation unless TC_FORCE_RELOCATION returns 1. */
- if (TC_FORCE_RELOCATION (fixp))
- {
- symbol_mark_used_in_reloc (fixp->fx_addsy);
-#ifdef UNDEFINED_DIFFERENCE_OK
- if (fixp->fx_subsy != NULL)
- symbol_mark_used_in_reloc (fixp->fx_subsy);
-#endif
- }
- goto done;
- }
-
- /* If it's one of these sections, assume the symbol is
- definitely going to be output. The code in
- md_estimate_size_before_relax in tc-mips.c uses this test
- as well, so if you change this code you should look at that
- code. */
- if (bfd_is_und_section (symsec)
- || bfd_is_com_section (symsec))
- {
- symbol_mark_used_in_reloc (fixp->fx_addsy);
-#ifdef UNDEFINED_DIFFERENCE_OK
- /* We have the difference of an undefined symbol and some
- other symbol. Make sure to mark the other symbol as used
- in a relocation so that it will always be output. */
- if (fixp->fx_subsy)
- symbol_mark_used_in_reloc (fixp->fx_subsy);
-#endif
- goto done;
+ /* The fixup_segment routine normally will not use this
+ symbol in a relocation. */
+ continue;
}
/* Don't try to reduce relocs which refer to non-local symbols
@@ -832,132 +839,52 @@ adjust_reloc_syms (abfd, sec, xxx)
this will always be correct. */
if (symsec != sec && ! S_IS_LOCAL (sym))
{
- boolean linkonce;
-
- linkonce = false;
-#ifdef BFD_ASSEMBLER
- if ((bfd_get_section_flags (stdoutput, symsec) & SEC_LINK_ONCE)
- != 0)
- linkonce = true;
-#endif
-#ifdef OBJ_ELF
- /* The GNU toolchain uses an extension for ELF: a section
- beginning with the magic string .gnu.linkonce is a
- linkonce section. */
- if (strncmp (segment_name (symsec), ".gnu.linkonce",
- sizeof ".gnu.linkonce" - 1) == 0)
- linkonce = true;
-#endif
-
- if (linkonce)
- {
- symbol_mark_used_in_reloc (fixp->fx_addsy);
-#ifdef UNDEFINED_DIFFERENCE_OK
- if (fixp->fx_subsy != NULL)
- symbol_mark_used_in_reloc (fixp->fx_subsy);
-#endif
- goto done;
- }
- }
-
- /* Since we're reducing to section symbols, don't attempt to reduce
- anything that's already using one. */
- if (symbol_section_p (sym))
- {
- symbol_mark_used_in_reloc (fixp->fx_addsy);
- goto done;
- }
-
-#ifdef BFD_ASSEMBLER
- /* We can never adjust a reloc against a weak symbol. If we
- did, and the weak symbol was overridden by a real symbol
- somewhere else, then our relocation would be pointing at
- the wrong area of memory. */
- if (S_IS_WEAK (sym))
- {
- symbol_mark_used_in_reloc (fixp->fx_addsy);
- goto done;
+ if ((symsec->flags & SEC_LINK_ONCE) != 0
+ || (IS_ELF
+ /* The GNU toolchain uses an extension for ELF: a
+ section beginning with the magic string
+ .gnu.linkonce is a linkonce section. */
+ && strncmp (segment_name (symsec), ".gnu.linkonce",
+ sizeof ".gnu.linkonce" - 1) == 0))
+ continue;
}
/* Never adjust a reloc against local symbol in a merge section
with non-zero addend. */
if ((symsec->flags & SEC_MERGE) != 0
&& (fixp->fx_offset != 0 || fixp->fx_subsy != NULL))
- {
- symbol_mark_used_in_reloc (fixp->fx_addsy);
- goto done;
- }
+ continue;
/* Never adjust a reloc against TLS local symbol. */
- if (symsec->flags & SEC_THREAD_LOCAL)
- {
- symbol_mark_used_in_reloc (fixp->fx_addsy);
- goto done;
- }
-#endif
-
- /* Is there some other reason we can't adjust this one? (E.g.,
- call/bal links in i960-bout symbols.) */
-#ifdef obj_fix_adjustable
- if (! obj_fix_adjustable (fixp))
- {
- symbol_mark_used_in_reloc (fixp->fx_addsy);
- goto done;
- }
-#endif
-
- /* Is there some other (target cpu dependent) reason we can't adjust
- this one? (E.g. relocations involving function addresses on
- the PA. */
-#ifdef tc_fix_adjustable
- if (! tc_fix_adjustable (fixp))
- {
- symbol_mark_used_in_reloc (fixp->fx_addsy);
- goto done;
- }
-#endif
-
- /* If the section symbol isn't going to be output, the relocs
- at least should still work. If not, figure out what to do
- when we run into that case.
+ if ((symsec->flags & SEC_THREAD_LOCAL) != 0)
+ continue;
- We refetch the segment when calling section_symbol, rather
+ /* We refetch the segment when calling section_symbol, rather
than using symsec, because S_GET_VALUE may wind up changing
the section when it calls resolve_symbol_value. */
fixp->fx_offset += S_GET_VALUE (sym);
fixp->fx_addsy = section_symbol (S_GET_SEGMENT (sym));
- symbol_mark_used_in_reloc (fixp->fx_addsy);
#ifdef DEBUG5
fprintf (stderr, "\nadjusted fixup:\n");
print_fixup (fixp);
#endif
-
- done:
- ;
}
-#if 1 /* def RELOC_REQUIRES_SYMBOL */
- else
- {
- /* There was no symbol required by this relocation. However,
- BFD doesn't really handle relocations without symbols well.
- (At least, the COFF support doesn't.) So for now we fake up
- a local symbol in the absolute section. */
-
- fixp->fx_addsy = section_symbol (absolute_section);
-#if 0
- fixp->fx_addsy->sy_used_in_reloc = 1;
-#endif
- }
-#endif
dump_section_relocs (abfd, sec, stderr);
}
static void
-write_relocs (abfd, sec, xxx)
- bfd *abfd;
- asection *sec;
- PTR xxx ATTRIBUTE_UNUSED;
+fix_segment (bfd *abfd ATTRIBUTE_UNUSED,
+ asection *sec,
+ PTR xxx ATTRIBUTE_UNUSED)
+{
+ segment_info_type *seginfo = seg_info (sec);
+
+ fixup_segment (seginfo->fix_root, sec);
+}
+
+static void
+write_relocs (bfd *abfd, asection *sec, PTR xxx ATTRIBUTE_UNUSED)
{
segment_info_type *seginfo = seg_info (sec);
unsigned int i;
@@ -971,16 +898,13 @@ write_relocs (abfd, sec, xxx)
if (seginfo == NULL)
return;
- fixup_segment (seginfo->fix_root, sec);
-
n = 0;
for (fixp = seginfo->fix_root; fixp; fixp = fixp->fx_next)
n++;
#ifndef RELOC_EXPANSION_POSSIBLE
/* Set up reloc information as well. */
- relocs = (arelent **) xmalloc (n * sizeof (arelent *));
- memset ((char *) relocs, 0, n * sizeof (arelent *));
+ relocs = (arelent **) xcalloc (n, sizeof (arelent *));
i = 0;
for (fixp = seginfo->fix_root; fixp != (fixS *) NULL; fixp = fixp->fx_next)
@@ -1036,10 +960,12 @@ write_relocs (abfd, sec, xxx)
case bfd_reloc_ok:
break;
case bfd_reloc_overflow:
- as_bad_where (fixp->fx_file, fixp->fx_line, _("relocation overflow"));
+ as_bad_where (fixp->fx_file, fixp->fx_line,
+ _("relocation overflow"));
break;
case bfd_reloc_outofrange:
- as_bad_where (fixp->fx_file, fixp->fx_line, _("relocation out of range"));
+ as_bad_where (fixp->fx_file, fixp->fx_line,
+ _("relocation out of range"));
break;
default:
as_fatal (_("%s:%u: bad return from bfd_install_relocation: %x"),
@@ -1050,13 +976,12 @@ write_relocs (abfd, sec, xxx)
#else
n = n * MAX_RELOC_EXPANSION;
/* Set up reloc information as well. */
- relocs = (arelent **) xmalloc (n * sizeof (arelent *));
+ relocs = (arelent **) xcalloc (n, sizeof (arelent *));
i = 0;
for (fixp = seginfo->fix_root; fixp != (fixS *) NULL; fixp = fixp->fx_next)
{
arelent **reloc;
- char *data;
bfd_reloc_status_type s;
symbolS *sym;
int j;
@@ -1072,7 +997,17 @@ write_relocs (abfd, sec, xxx)
rather than the former. */
sym = fixp->fx_addsy;
while (symbol_equated_reloc_p (sym))
- sym = symbol_get_value_expression (sym)->X_add_symbol;
+ {
+ symbolS *n;
+
+ /* We must avoid looping, as that can occur with a badly
+ written program. */
+ n = symbol_get_value_expression (sym)->X_add_symbol;
+ if (n == sym)
+ break;
+ fixp->fx_offset += symbol_get_value_expression (sym)->X_add_number;
+ sym = n;
+ }
fixp->fx_addsy = sym;
reloc = tc_gen_reloc (sec, fixp);
@@ -1082,7 +1017,6 @@ write_relocs (abfd, sec, xxx)
relocs[i++] = reloc[j];
assert (i <= n);
}
- data = fixp->fx_frag->fr_literal + fixp->fx_where;
if (fixp->fx_where + fixp->fx_size
> fixp->fx_frag->fr_fix + fixp->fx_frag->fr_offset)
as_bad_where (fixp->fx_file, fixp->fx_line,
@@ -1101,9 +1035,13 @@ write_relocs (abfd, sec, xxx)
as_bad_where (fixp->fx_file, fixp->fx_line,
_("relocation overflow"));
break;
+ case bfd_reloc_outofrange:
+ as_bad_where (fixp->fx_file, fixp->fx_line,
+ _("relocation out of range"));
+ break;
default:
- as_fatal (_("%s:%u: bad return from bfd_install_relocation"),
- fixp->fx_file, fixp->fx_line);
+ as_fatal (_("%s:%u: bad return from bfd_install_relocation: %x"),
+ fixp->fx_file, fixp->fx_line, s);
}
}
}
@@ -1157,13 +1095,12 @@ write_relocs (abfd, sec, xxx)
}
static void
-write_contents (abfd, sec, xxx)
- bfd *abfd ATTRIBUTE_UNUSED;
- asection *sec;
- PTR xxx ATTRIBUTE_UNUSED;
+write_contents (bfd *abfd ATTRIBUTE_UNUSED,
+ asection *sec,
+ PTR xxx ATTRIBUTE_UNUSED)
{
segment_info_type *seginfo = seg_info (sec);
- unsigned long offset = 0;
+ addressT offset = 0;
fragS *f;
/* Write out the frags. */
@@ -1176,9 +1113,9 @@ write_contents (abfd, sec, xxx)
f = f->fr_next)
{
int x;
- unsigned long fill_size;
+ addressT fill_size;
char *fill_literal;
- long count;
+ offsetT count;
assert (f->fr_type == rs_fill);
if (f->fr_fix)
@@ -1186,7 +1123,7 @@ write_contents (abfd, sec, xxx)
x = bfd_set_section_contents (stdoutput, sec,
f->fr_literal, (file_ptr) offset,
(bfd_size_type) f->fr_fix);
- if (x == false)
+ if (!x)
{
bfd_perror (stdoutput->filename);
as_perror (_("FATAL: Can't write %s"), stdoutput->filename);
@@ -1210,7 +1147,7 @@ write_contents (abfd, sec, xxx)
fill_literal,
(file_ptr) offset,
(bfd_size_type) fill_size);
- if (x == false)
+ if (!x)
{
bfd_perror (stdoutput->filename);
as_perror (_("FATAL: Can't write %s"),
@@ -1244,7 +1181,7 @@ write_contents (abfd, sec, xxx)
x = bfd_set_section_contents
(stdoutput, sec, buf, (file_ptr) offset,
(bfd_size_type) n_per_buf * fill_size);
- if (x != true)
+ if (!x)
as_fatal (_("cannot write to output file"));
offset += n_per_buf * fill_size;
}
@@ -1256,7 +1193,7 @@ write_contents (abfd, sec, xxx)
#if defined(BFD_ASSEMBLER) || (!defined (BFD) && !defined(OBJ_AOUT))
static void
-merge_data_into_text ()
+merge_data_into_text (void)
{
#if defined(BFD_ASSEMBLER) || defined(MANY_SEGMENTS)
seg_info (text_section)->frchainP->frch_last->fr_next =
@@ -1338,7 +1275,7 @@ relax_and_size_all_segments ()
#ifdef OBJ_BOUT
/* See above comments on b.out data section address. */
{
- long bss_vma;
+ addressT bss_vma;
if (data_last_frag == 0)
bss_vma = H_GET_TEXT_SIZE (&headers);
else
@@ -1373,13 +1310,13 @@ relax_and_size_all_segments ()
#ifdef BFD_ASSEMBLER
static void
-set_symtab ()
+set_symtab (void)
{
int nsyms;
asymbol **asympp;
symbolS *symp;
- boolean result;
- extern PTR bfd_alloc PARAMS ((bfd *, bfd_size_type));
+ bfd_boolean result;
+ extern PTR bfd_alloc (bfd *, bfd_size_type);
/* Count symbols. We can't rely on a count made by the loop in
write_object_file, because *_frob_file may add a new symbol or
@@ -1404,7 +1341,7 @@ set_symtab ()
else
asympp = 0;
result = bfd_set_symtab (stdoutput, asympp, nsyms);
- assert (result == true);
+ assert (result);
symbol_table_frozen = 1;
}
#endif
@@ -1417,7 +1354,7 @@ set_symtab ()
#ifndef SUB_SEGMENT_ALIGN
#ifdef HANDLE_ALIGN
-/* The last subsegment gets an aligment corresponding to the alignment
+/* The last subsegment gets an alignment corresponding to the alignment
of the section. This allows proper nop-filling at the end of
code-bearing sections. */
#define SUB_SEGMENT_ALIGN(SEG, FRCHAIN) \
@@ -1433,7 +1370,7 @@ set_symtab ()
#endif
void
-subsegs_finish ()
+subsegs_finish (void)
{
struct frchain *frchainP;
@@ -1447,7 +1384,25 @@ subsegs_finish ()
any alignment is meaningless, and, moreover, will look weird
if we are generating a listing. */
if (!had_errors ())
- alignment = SUB_SEGMENT_ALIGN (now_seg, frchainP);
+ {
+ alignment = SUB_SEGMENT_ALIGN (now_seg, frchainP);
+#ifdef BFD_ASSEMBLER
+ if ((bfd_get_section_flags (now_seg->owner, now_seg) & SEC_MERGE)
+ && now_seg->entsize)
+ {
+ unsigned int entsize = now_seg->entsize;
+ int entalign = 0;
+
+ while ((entsize & 1) == 0)
+ {
+ ++entalign;
+ entsize >>= 1;
+ }
+ if (entalign > alignment)
+ alignment = entalign;
+ }
+#endif
+ }
if (subseg_text_p (now_seg))
frag_align_code (alignment, 0);
@@ -1468,7 +1423,7 @@ subsegs_finish ()
/* Write the object file. */
void
-write_object_file ()
+write_object_file (void)
{
#if ! defined (BFD_ASSEMBLER) || ! defined (WORKING_DOT_WORD)
fragS *fragP; /* Track along all frags. */
@@ -1593,6 +1548,10 @@ write_object_file ()
/* Relaxation has completed. Freeze all syms. */
finalize_syms = 1;
+#ifdef md_post_relax_hook
+ md_post_relax_hook;
+#endif
+
#ifndef BFD_ASSEMBLER
/* Crawl the symbol chain.
@@ -1644,7 +1603,7 @@ write_object_file ()
#ifdef OBJ_BOUT
|| fragP->fr_next == data_frag_root
#endif
- || ((fragP->fr_next->fr_address - fragP->fr_address)
+ || ((offsetT) (fragP->fr_next->fr_address - fragP->fr_address)
== (fragP->fr_fix + fragP->fr_offset * fragP->fr_var))))
abort ();
#endif
@@ -1912,6 +1871,15 @@ write_object_file ()
bfd_map_over_sections (stdoutput, adjust_reloc_syms, (char *) 0);
+#ifdef tc_frob_file_before_fix
+ tc_frob_file_before_fix ();
+#endif
+#ifdef obj_frob_file_before_fix
+ obj_frob_file_before_fix ();
+#endif
+
+ bfd_map_over_sections (stdoutput, fix_segment, (char *) 0);
+
/* Set up symbol table, and write it out. */
if (symbol_rootP)
{
@@ -1981,13 +1949,14 @@ write_object_file ()
want section symbols. Otherwise, we skip local symbols
and symbols that the frob_symbol macros told us to punt,
but we keep such symbols if they are used in relocs. */
- if ((! EMIT_SECTION_SYMBOLS
- && symbol_section_p (symp))
+ if (symp == abs_section_sym
+ || (! EMIT_SECTION_SYMBOLS
+ && symbol_section_p (symp))
/* Note that S_IS_EXTERN and S_IS_LOCAL are not always
opposites. Sometimes the former checks flags and the
latter examines the name... */
|| (!S_IS_EXTERN (symp)
- && (S_IS_LOCAL (symp) || punt)
+ && (punt || S_IS_LOCAL (symp))
&& ! symbol_used_in_reloc_p (symp)))
{
symbol_remove (symp, &symbol_rootP, &symbol_lastP);
@@ -2057,16 +2026,13 @@ write_object_file ()
/* Relax a fragment by scanning TC_GENERIC_RELAX_TABLE. */
long
-relax_frag (segment, fragP, stretch)
- segT segment;
- fragS *fragP;
- long stretch;
+relax_frag (segT segment, fragS *fragP, long stretch)
{
const relax_typeS *this_type;
const relax_typeS *start_type;
relax_substateT next_state;
relax_substateT this_state;
- long growth;
+ offsetT growth;
offsetT aim;
addressT target;
addressT address;
@@ -2095,7 +2061,7 @@ relax_frag (segment, fragP, stretch)
#endif
know (sym_frag != NULL);
#endif
- know (!(S_GET_SEGMENT (symbolP) == absolute_section)
+ know (S_GET_SEGMENT (symbolP) != absolute_section
|| sym_frag == &zero_address_frag);
target += S_GET_VALUE (symbolP);
@@ -2167,9 +2133,8 @@ relax_frag (segment, fragP, stretch)
/* Relax_align. Advance location counter to next address that has 'alignment'
lowest order bits all 0s, return size of adjustment made. */
static relax_addressT
-relax_align (address, alignment)
- register relax_addressT address; /* Address now. */
- register int alignment; /* Alignment (binary). */
+relax_align (register relax_addressT address, /* Address now. */
+ register int alignment /* Alignment (binary). */)
{
relax_addressT mask;
relax_addressT new_address;
@@ -2196,9 +2161,7 @@ relax_align (address, alignment)
addresses. */
int
-relax_segment (segment_frag_root, segment)
- struct frag *segment_frag_root;
- segT segment;
+relax_segment (struct frag *segment_frag_root, segT segment)
{
register struct frag *fragP;
register relax_addressT address;
@@ -2289,7 +2252,7 @@ relax_segment (segment_frag_root, segment)
/* Do relax(). */
{
- long stretch; /* May be any size, 0 or negative. */
+ offsetT stretch; /* May be any size, 0 or negative. */
/* Cumulative number of addresses we have relaxed this pass.
We may have relaxed more than one address. */
int stretched; /* Have we stretched on this pass? */
@@ -2304,7 +2267,7 @@ relax_segment (segment_frag_root, segment)
for (fragP = segment_frag_root; fragP; fragP = fragP->fr_next)
{
- long growth = 0;
+ offsetT growth = 0;
addressT was_address;
offsetT offset;
symbolS *symbolP;
@@ -2439,7 +2402,7 @@ relax_segment (segment_frag_root, segment)
cannot have fewer than 0 chars. That is, we can't
.org backwards. */
as_bad_where (fragP->fr_file, fragP->fr_line,
- _("attempt to .org backwards"));
+ _("attempt to move .org backwards"));
/* We've issued an error message. Change the
frag to avoid cascading errors. */
@@ -2498,7 +2461,7 @@ relax_segment (segment_frag_root, segment)
case rs_leb128:
{
valueT value;
- int size;
+ offsetT size;
value = resolve_symbol_value (fragP->fr_symbol);
size = sizeof_leb128 (value, fragP->fr_subtype);
@@ -2541,10 +2504,6 @@ relax_segment (segment_frag_root, segment)
#if defined (BFD_ASSEMBLER) || (!defined (BFD) && !defined (OBJ_VMS))
-#ifndef TC_RELOC_RTSYM_LOC_FIXUP
-#define TC_RELOC_RTSYM_LOC_FIXUP(X) (1)
-#endif
-
/* fixup_segment()
Go through all the fixS's in a segment and see which ones can be
@@ -2557,32 +2516,46 @@ relax_segment (segment_frag_root, segment)
These will be output later by emit_relocations(). */
static long
-fixup_segment (fixP, this_segment_type)
- register fixS *fixP;
- segT this_segment_type; /* N_TYPE bits for segment. */
+fixup_segment (fixS *fixP, segT this_segment)
{
long seg_reloc_count = 0;
- symbolS *add_symbolP;
- symbolS *sub_symbolP;
valueT add_number;
- int size;
- char *place;
- long where;
- int pcrel, plt;
fragS *fragP;
segT add_symbol_segment = absolute_section;
+ if (fixP != NULL && abs_section_sym == NULL)
+ {
+#ifndef BFD_ASSEMBLER
+ abs_section_sym = &abs_symbol;
+#else
+ abs_section_sym = section_symbol (absolute_section);
+#endif
+ }
+
/* If the linker is doing the relaxing, we must not do any fixups.
- Well, strictly speaking that's not true -- we could do any that are
- PC-relative and don't cross regions that could change size. And for the
- i960 (the only machine for which we've got a relaxing linker right now),
- we might be able to turn callx/callj into bal anyways in cases where we
- know the maximum displacement. */
- if (linkrelax && TC_LINKRELAX_FIXUP (this_segment_type))
+ Well, strictly speaking that's not true -- we could do any that
+ are PC-relative and don't cross regions that could change size.
+ And for the i960 we might be able to turn callx/callj into bal
+ anyways in cases where we know the maximum displacement. */
+ if (linkrelax && TC_LINKRELAX_FIXUP (this_segment))
{
for (; fixP; fixP = fixP->fx_next)
- seg_reloc_count++;
+ if (!fixP->fx_done)
+ {
+ if (fixP->fx_addsy == NULL)
+ {
+ /* There was no symbol required by this relocation.
+ However, BFD doesn't really handle relocations
+ without symbols well. So fake up a local symbol in
+ the absolute section. */
+ fixP->fx_addsy = abs_section_sym;
+ }
+ symbol_mark_used_in_reloc (fixP->fx_addsy);
+ if (fixP->fx_subsy != NULL)
+ symbol_mark_used_in_reloc (fixP->fx_subsy);
+ seg_reloc_count++;
+ }
TC_ADJUST_RELOC_COUNT (fixP, seg_reloc_count);
return seg_reloc_count;
}
@@ -2596,290 +2569,160 @@ fixup_segment (fixP, this_segment_type)
fragP = fixP->fx_frag;
know (fragP);
- where = fixP->fx_where;
- place = fragP->fr_literal + where;
- size = fixP->fx_size;
- add_symbolP = fixP->fx_addsy;
#ifdef TC_VALIDATE_FIX
- TC_VALIDATE_FIX (fixP, this_segment_type, skip);
+ TC_VALIDATE_FIX (fixP, this_segment, skip);
#endif
- sub_symbolP = fixP->fx_subsy;
add_number = fixP->fx_offset;
- pcrel = fixP->fx_pcrel;
- plt = fixP->fx_plt;
- if (add_symbolP != NULL
- && symbol_mri_common_p (add_symbolP))
+ if (fixP->fx_addsy != NULL
+ && symbol_mri_common_p (fixP->fx_addsy))
{
- know (add_symbolP->sy_value.X_op == O_symbol);
- add_number += S_GET_VALUE (add_symbolP);
+ know (fixP->fx_addsy->sy_value.X_op == O_symbol);
+ add_number += S_GET_VALUE (fixP->fx_addsy);
fixP->fx_offset = add_number;
- add_symbolP = fixP->fx_addsy =
- symbol_get_value_expression (add_symbolP)->X_add_symbol;
+ fixP->fx_addsy
+ = symbol_get_value_expression (fixP->fx_addsy)->X_add_symbol;
}
- if (add_symbolP)
- add_symbol_segment = S_GET_SEGMENT (add_symbolP);
+ if (fixP->fx_addsy != NULL)
+ add_symbol_segment = S_GET_SEGMENT (fixP->fx_addsy);
- if (sub_symbolP)
+ if (fixP->fx_subsy != NULL)
{
- resolve_symbol_value (sub_symbolP);
- if (add_symbolP == NULL || add_symbol_segment == absolute_section)
+ segT sub_symbol_segment;
+ resolve_symbol_value (fixP->fx_subsy);
+ sub_symbol_segment = S_GET_SEGMENT (fixP->fx_subsy);
+ if (fixP->fx_addsy != NULL
+ && sub_symbol_segment == add_symbol_segment
+ && !TC_FORCE_RELOCATION_SUB_SAME (fixP, add_symbol_segment))
{
- if (add_symbolP != NULL)
- {
- add_number += S_GET_VALUE (add_symbolP);
- add_symbolP = NULL;
- fixP->fx_addsy = NULL;
- }
-
- /* It's just -sym. */
- if (S_GET_SEGMENT (sub_symbolP) == absolute_section)
- {
- add_number -= S_GET_VALUE (sub_symbolP);
- fixP->fx_subsy = NULL;
- }
- else if (pcrel
- && S_GET_SEGMENT (sub_symbolP) == this_segment_type)
- {
- /* Should try converting to a constant. */
- goto bad_sub_reloc;
- }
- else
- bad_sub_reloc:
- as_bad_where (fixP->fx_file, fixP->fx_line,
- _("negative of non-absolute symbol `%s'"),
- S_GET_NAME (sub_symbolP));
- }
- else if (S_GET_SEGMENT (sub_symbolP) == add_symbol_segment
- && SEG_NORMAL (add_symbol_segment))
- {
- /* Difference of 2 symbols from same segment.
- Can't make difference of 2 undefineds: 'value' means
- something different for N_UNDF. */
-#ifdef TC_I960
- /* Makes no sense to use the difference of 2 arbitrary symbols
- as the target of a call instruction. */
- if (fixP->fx_tcbit)
- as_bad_where (fixP->fx_file, fixP->fx_line,
- _("callj to difference of two symbols"));
-#endif /* TC_I960 */
- add_number += (S_GET_VALUE (add_symbolP)
- - S_GET_VALUE (sub_symbolP));
- if (1
+ add_number += S_GET_VALUE (fixP->fx_addsy);
+ add_number -= S_GET_VALUE (fixP->fx_subsy);
+ fixP->fx_offset = add_number;
+ fixP->fx_addsy = NULL;
+ fixP->fx_subsy = NULL;
#ifdef TC_M68K
- /* See the comment below about 68k weirdness. */
- && 0
+ /* See the comment below about 68k weirdness. */
+ fixP->fx_pcrel = 0;
#endif
- && pcrel)
- add_number -= MD_PCREL_FROM_SECTION (fixP, this_segment_type);
-
- add_symbolP = NULL;
- pcrel = 0; /* No further pcrel processing. */
-
- /* Let the target machine make the final determination
- as to whether or not a relocation will be needed to
- handle this fixup. */
- if (!TC_FORCE_RELOCATION_SECTION (fixP, this_segment_type))
- {
- fixP->fx_pcrel = 0;
- fixP->fx_addsy = NULL;
- fixP->fx_subsy = NULL;
- }
}
- else
+ else if (sub_symbol_segment == absolute_section
+ && !TC_FORCE_RELOCATION_SUB_ABS (fixP))
{
- /* Different segments in subtraction. */
- know (!(S_IS_EXTERNAL (sub_symbolP)
- && (S_GET_SEGMENT (sub_symbolP) == absolute_section)));
-
- if ((S_GET_SEGMENT (sub_symbolP) == absolute_section))
- add_number -= S_GET_VALUE (sub_symbolP);
-
-#ifdef DIFF_EXPR_OK
- else if (S_GET_SEGMENT (sub_symbolP) == this_segment_type)
- {
- /* Make it pc-relative. */
- if (0
+ add_number -= S_GET_VALUE (fixP->fx_subsy);
+ fixP->fx_offset = add_number;
+ fixP->fx_subsy = NULL;
+ }
+ else if (sub_symbol_segment == this_segment
+ && !TC_FORCE_RELOCATION_SUB_LOCAL (fixP))
+ {
+ add_number -= S_GET_VALUE (fixP->fx_subsy);
+ fixP->fx_offset = (add_number + fixP->fx_dot_value
+ + fixP->fx_frag->fr_address);
+
+ /* Make it pc-relative. If the back-end code has not
+ selected a pc-relative reloc, cancel the adjustment
+ we do later on all pc-relative relocs. */
+ if (0
#ifdef TC_M68K
- /* Do this for m68k even if it's already described
- as pc-relative. On the m68k, an operand of
- "pc@(foo-.-2)" should address "foo" in a
- pc-relative mode. */
- || 1
-#endif
- || !pcrel)
- {
- add_number += MD_PCREL_FROM_SECTION (fixP,
- this_segment_type);
- pcrel = 1;
- fixP->fx_pcrel = 1;
- }
-
- add_number -= S_GET_VALUE (sub_symbolP);
- sub_symbolP = 0;
- fixP->fx_subsy = 0;
- }
-#endif
-#ifdef UNDEFINED_DIFFERENCE_OK
- /* The PA needs this for PIC code generation. We basically
- don't want to do anything if we have the difference of two
- symbols at this point. */
- else if (1)
- {
- /* Leave it alone. */
- }
-#endif
-#ifdef BFD_ASSEMBLER
- else if (fixP->fx_r_type == BFD_RELOC_GPREL32
- || fixP->fx_r_type == BFD_RELOC_GPREL16)
- {
- /* Leave it alone. */
- }
-#endif
- else
- {
- char buf[50];
- sprint_value (buf, fragP->fr_address + where);
- as_bad_where (fixP->fx_file, fixP->fx_line,
- _("subtraction of two symbols in different sections `%s' {%s section} - `%s' {%s section} at file address %s"),
- S_GET_NAME (add_symbolP),
- segment_name (S_GET_SEGMENT (add_symbolP)),
- S_GET_NAME (sub_symbolP),
- segment_name (S_GET_SEGMENT (sub_symbolP)),
- buf);
- }
+ /* Do this for m68k even if it's already described
+ as pc-relative. On the m68k, an operand of
+ "pc@(foo-.-2)" should address "foo" in a
+ pc-relative mode. */
+ || 1
+#endif
+ || !fixP->fx_pcrel)
+ add_number += MD_PCREL_FROM_SECTION (fixP, this_segment);
+ fixP->fx_subsy = NULL;
+ fixP->fx_pcrel = 1;
+ }
+ else if (!TC_VALIDATE_FIX_SUB (fixP))
+ {
+ as_bad_where (fixP->fx_file, fixP->fx_line,
+ _("can't resolve `%s' {%s section} - `%s' {%s section}"),
+ fixP->fx_addsy ? S_GET_NAME (fixP->fx_addsy) : "0",
+ segment_name (add_symbol_segment),
+ S_GET_NAME (fixP->fx_subsy),
+ segment_name (sub_symbol_segment));
}
}
- if (add_symbolP)
+ if (fixP->fx_addsy)
{
- if (add_symbol_segment == this_segment_type && pcrel && !plt
- && TC_RELOC_RTSYM_LOC_FIXUP (fixP))
+ if (add_symbol_segment == this_segment
+ && !TC_FORCE_RELOCATION_LOCAL (fixP))
{
/* This fixup was made when the symbol's segment was
SEG_UNKNOWN, but it is now in the local segment.
So we know how to do the address without relocation. */
-#ifdef TC_I960
- /* reloc_callj() may replace a 'call' with a 'calls' or a
- 'bal', in which cases it modifies *fixP as appropriate.
- In the case of a 'calls', no further work is required,
- and *fixP has been set up to make the rest of the code
- below a no-op. */
- reloc_callj (fixP);
-#endif /* TC_I960 */
-
- add_number += S_GET_VALUE (add_symbolP);
- add_number -= MD_PCREL_FROM_SECTION (fixP, this_segment_type);
- /* Lie. Don't want further pcrel processing. */
- pcrel = 0;
-
- /* Let the target machine make the final determination
- as to whether or not a relocation will be needed to
- handle this fixup. */
- if (!TC_FORCE_RELOCATION (fixP))
- {
- fixP->fx_pcrel = 0;
- fixP->fx_addsy = NULL;
- }
+ add_number += S_GET_VALUE (fixP->fx_addsy);
+ fixP->fx_offset = add_number;
+ if (fixP->fx_pcrel)
+ add_number -= MD_PCREL_FROM_SECTION (fixP, this_segment);
+ fixP->fx_addsy = NULL;
+ fixP->fx_pcrel = 0;
}
- else
+ else if (add_symbol_segment == absolute_section
+ && !TC_FORCE_RELOCATION_ABS (fixP))
{
- if (add_symbol_segment == absolute_section
- && ! pcrel)
- {
-#ifdef TC_I960
- /* See comment about reloc_callj() above. */
- reloc_callj (fixP);
-#endif /* TC_I960 */
- add_number += S_GET_VALUE (add_symbolP);
-
- /* Let the target machine make the final determination
- as to whether or not a relocation will be needed to
- handle this fixup. */
-
- if (!TC_FORCE_RELOCATION (fixP))
- {
- fixP->fx_addsy = NULL;
- add_symbolP = NULL;
- }
- }
- else if (add_symbol_segment == undefined_section
+ add_number += S_GET_VALUE (fixP->fx_addsy);
+ fixP->fx_offset = add_number;
+ fixP->fx_addsy = NULL;
+ }
+ else if (add_symbol_segment != undefined_section
#ifdef BFD_ASSEMBLER
- || bfd_is_com_section (add_symbol_segment)
+ && ! bfd_is_com_section (add_symbol_segment)
#endif
- )
- {
-#ifdef TC_I960
- if ((int) fixP->fx_bit_fixP == 13)
- {
- /* This is a COBR instruction. They have only a
- 13-bit displacement and are only to be used
- for local branches: flag as error, don't generate
- relocation. */
- as_bad_where (fixP->fx_file, fixP->fx_line,
- _("can't use COBR format with external label"));
- fixP->fx_addsy = NULL;
- fixP->fx_done = 1;
- continue;
- } /* COBR. */
-#endif /* TC_I960 */
-
-#ifdef OBJ_COFF
-#ifdef TE_I386AIX
- if (S_IS_COMMON (add_symbolP))
- add_number += S_GET_VALUE (add_symbolP);
-#endif /* TE_I386AIX */
-#endif /* OBJ_COFF */
- ++seg_reloc_count;
- }
- else
- {
- seg_reloc_count++;
- if (TC_FIX_ADJUSTABLE (fixP))
- add_number += S_GET_VALUE (add_symbolP);
- }
- }
+ && MD_APPLY_SYM_VALUE (fixP))
+ add_number += S_GET_VALUE (fixP->fx_addsy);
}
- if (pcrel)
+ if (fixP->fx_pcrel)
{
- add_number -= MD_PCREL_FROM_SECTION (fixP, this_segment_type);
- if (add_symbolP == 0)
+ add_number -= MD_PCREL_FROM_SECTION (fixP, this_segment);
+ if (!fixP->fx_done && fixP->fx_addsy == NULL)
{
-#ifndef BFD_ASSEMBLER
- fixP->fx_addsy = &abs_symbol;
-#else
- fixP->fx_addsy = section_symbol (absolute_section);
-#endif
- symbol_mark_used_in_reloc (fixP->fx_addsy);
- ++seg_reloc_count;
+ /* There was no symbol required by this relocation.
+ However, BFD doesn't really handle relocations
+ without symbols well. So fake up a local symbol in
+ the absolute section. */
+ fixP->fx_addsy = abs_section_sym;
}
}
if (!fixP->fx_done)
- md_apply_fix3 (fixP, & add_number, this_segment_type);
+ md_apply_fix3 (fixP, &add_number, this_segment);
+
+ if (!fixP->fx_done)
+ {
+ ++seg_reloc_count;
+ if (fixP->fx_addsy == NULL)
+ fixP->fx_addsy = abs_section_sym;
+ symbol_mark_used_in_reloc (fixP->fx_addsy);
+ if (fixP->fx_subsy != NULL)
+ symbol_mark_used_in_reloc (fixP->fx_subsy);
+ }
- if (!fixP->fx_bit_fixP && !fixP->fx_no_overflow && size > 0)
+ if (!fixP->fx_bit_fixP && !fixP->fx_no_overflow && fixP->fx_size != 0)
{
- if ((size_t) size < sizeof (valueT))
+ if (fixP->fx_size < sizeof (valueT))
{
valueT mask;
mask = 0;
mask--; /* Set all bits to one. */
- mask <<= size * 8 - (fixP->fx_signed ? 1 : 0);
+ mask <<= fixP->fx_size * 8 - (fixP->fx_signed ? 1 : 0);
if ((add_number & mask) != 0 && (add_number & mask) != mask)
{
char buf[50], buf2[50];
- sprint_value (buf, fragP->fr_address + where);
+ sprint_value (buf, fragP->fr_address + fixP->fx_where);
if (add_number > 1000)
sprint_value (buf2, add_number);
else
sprintf (buf2, "%ld", (long) add_number);
as_bad_where (fixP->fx_file, fixP->fx_line,
_("value of %s too large for field of %d bytes at %s"),
- buf2, size, buf);
+ buf2, fixP->fx_size, buf);
} /* Generic error checking. */
}
#ifdef WARN_SIGNED_OVERFLOW_WORD
@@ -2887,12 +2730,12 @@ fixup_segment (fixP, this_segment_type)
number. We already know it is not too negative. This is to
catch over-large switches generated by gcc on the 68k. */
if (!flag_signed_overflow_ok
- && size == 2
+ && fixP->fx_size == 2
&& add_number > 0x7fff)
as_bad_where (fixP->fx_file, fixP->fx_line,
_("signed .word overflow; switch may be too large; %ld at 0x%lx"),
(long) add_number,
- (unsigned long) (fragP->fr_address + where));
+ (long) (fragP->fr_address + fixP->fx_where));
#endif
} /* Not a bit fix. */
@@ -2913,10 +2756,7 @@ fixup_segment (fixP, this_segment_type)
#endif /* defined (BFD_ASSEMBLER) || (!defined (BFD) && !defined (OBJ_VMS)) */
void
-number_to_chars_bigendian (buf, val, n)
- char *buf;
- valueT val;
- int n;
+number_to_chars_bigendian (char *buf, valueT val, int n)
{
if (n <= 0)
abort ();
@@ -2928,10 +2768,7 @@ number_to_chars_bigendian (buf, val, n)
}
void
-number_to_chars_littleendian (buf, val, n)
- char *buf;
- valueT val;
- int n;
+number_to_chars_littleendian (char *buf, valueT val, int n)
{
if (n <= 0)
abort ();
@@ -2943,8 +2780,7 @@ number_to_chars_littleendian (buf, val, n)
}
void
-write_print_statistics (file)
- FILE *file;
+write_print_statistics (FILE *file)
{
fprintf (file, "fixups: %d\n", n_fixups);
}
@@ -2953,8 +2789,7 @@ write_print_statistics (file)
extern int indent_level;
void
-print_fixup (fixp)
- fixS *fixp;
+print_fixup (fixS *fixp)
{
indent_level = 1;
fprintf (stderr, "fix %lx %s:%d", (long) fixp, fixp->fx_file, fixp->fx_line);
diff --git a/contrib/binutils/gas/write.h b/contrib/binutils/gas/write.h
index 451215d..0e0f59f 100644
--- a/contrib/binutils/gas/write.h
+++ b/contrib/binutils/gas/write.h
@@ -40,7 +40,9 @@
/* This is the name of a fake symbol which will never appear in the
assembler output. S_IS_LOCAL detects it because of the \001. */
+#ifndef FAKE_LABEL_NAME
#define FAKE_LABEL_NAME "L0\001"
+#endif
#include "bit_fix.h"
@@ -105,6 +107,9 @@ struct fix
/* Absolute number we add in. */
valueT fx_offset;
+ /* The value of dot when the fixup expression was parsed. */
+ addressT fx_dot_value;
+
/* Next fixS in linked list, or NULL. */
struct fix *fx_next;
@@ -158,6 +163,8 @@ struct fix
typedef struct fix fixS;
extern int finalize_syms;
+extern symbolS *abs_section_sym;
+extern addressT dot_value;
#ifndef BFD_ASSEMBLER
extern char *next_object_file_charP;
@@ -176,36 +183,35 @@ extern long string_byte_count;
extern int section_alignment[];
extern bit_fixS *bit_fix_new
- PARAMS ((int size, int offset, long base_type, long base_adj, long min,
- long max, long add));
-extern void append PARAMS ((char **charPP, char *fromP, unsigned long length));
-extern void record_alignment PARAMS ((segT seg, int align));
-extern int get_recorded_alignment PARAMS ((segT seg));
-extern void subsegs_finish PARAMS ((void));
-extern void write_object_file PARAMS ((void));
-extern long relax_frag PARAMS ((segT, fragS *, long));
-extern int relax_segment
- PARAMS ((struct frag * seg_frag_root, segT seg_type));
-
-extern void number_to_chars_littleendian PARAMS ((char *, valueT, int));
-extern void number_to_chars_bigendian PARAMS ((char *, valueT, int));
+ (int size, int offset, long base_type, long base_adj, long min,
+ long max, long add);
+extern void append (char **charPP, char *fromP, unsigned long length);
+extern void record_alignment (segT seg, int align);
+extern int get_recorded_alignment (segT seg);
+extern void subsegs_finish (void);
+extern void write_object_file (void);
+extern long relax_frag (segT, fragS *, long);
+extern int relax_segment (struct frag * seg_frag_root, segT seg_type);
+
+extern void number_to_chars_littleendian (char *, valueT, int);
+extern void number_to_chars_bigendian (char *, valueT, int);
#ifdef BFD_ASSEMBLER
extern fixS *fix_new
- PARAMS ((fragS * frag, int where, int size, symbolS * add_symbol,
- offsetT offset, int pcrel, bfd_reloc_code_real_type r_type));
+ (fragS * frag, int where, int size, symbolS * add_symbol,
+ offsetT offset, int pcrel, bfd_reloc_code_real_type r_type);
extern fixS *fix_new_exp
- PARAMS ((fragS * frag, int where, int size, expressionS *exp, int pcrel,
- bfd_reloc_code_real_type r_type));
+ (fragS * frag, int where, int size, expressionS *exp, int pcrel,
+ bfd_reloc_code_real_type r_type);
#else
extern fixS *fix_new
- PARAMS ((fragS * frag, int where, int size, symbolS * add_symbol,
- offsetT offset, int pcrel, int r_type));
+ (fragS * frag, int where, int size, symbolS * add_symbol,
+ offsetT offset, int pcrel, int r_type);
extern fixS *fix_new_exp
- PARAMS ((fragS * frag, int where, int size, expressionS *exp, int pcrel,
- int r_type));
+ (fragS * frag, int where, int size, expressionS *exp, int pcrel,
+ int r_type);
#endif
-extern void write_print_statistics PARAMS ((FILE *));
+extern void write_print_statistics (FILE *);
#endif /* __write_h__ */
diff --git a/contrib/binutils/include/ChangeLog b/contrib/binutils/include/ChangeLog
index 2353d99..9ea1d2a 100644
--- a/contrib/binutils/include/ChangeLog
+++ b/contrib/binutils/include/ChangeLog
@@ -1,38 +1,191 @@
-2002-10-28 Daniel Jacobowitz <drow@mvista.com>
+2004-04-08 Alan Modra <amodra@bigpond.net.au>
- Merge from mainline:
- 2002-10-24 Nathan Tallent <eraxxon@alumni.rice.edu>
- * ansidecl.h (__STDC__): Add (__alpha && __cplusplus) to the
- list of platform compilers that may look, smell and act
- like __STDC__ but that may not define it.
+ Apply from mainline.
+ 2004-03-20 H.J. Lu <hongjiu.lu@intel.com>
+ * bfdlink.h (bfd_link_info): Correct comments for the
+ unresolved_syms_in_objects field.
+
+2004-03-23 Alan Modra <amodra@bigpond.net.au>
+
+ PR 51.
+ * bfdlink.h (struct bfd_link_info): Add wrap_char.
+
+2004-01-12 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * demangle.h: Instead of checking ANSI_PROTOTYPES, just include
+ "libiberty.h".
+
+ * demangle.h: If ANSI_PROTOTYPES is defined, include <stddef.h>.
+
+ * demangle.h (enum demangle_component_type): Define.
+ (struct demangle_operator_info): Declare.
+ (struct demangle_builtin_type_info): Declare.
+ (struct demangle_component): Define.
+ (cplus_demangle_fill_component): Declare.
+ (cplus_demangle_fill_name): Declare.
+ (cplus_demangle_fill_builtin_type): Declare.
+ (cplus_demangle_fill_operator): Declare.
+ (cplus_demangle_fill_extended_operator): Declare.
+ (cplus_demangle_fill_ctor, cplus_demangle_fill_dtor): Declare.
+ (cplus_demangle_v3_components): Declare.
+ (cplus_demangle_print): Declare.
+
+2003-12-19 Andreas Tobler <a.tobler@schweiz.ch>
+
+ * include/fibheap.h (fibnode): Use __extension__ for
+ bit-fields mark and degree if __GNUC__.
+
+2003-12-18 Kazu Hirata <kazu@cs.umass.edu>
+
+ * include/fibheap.h (fibnode): Use unsigned long int for
+ bit-fields if __GNUC__ is defined.
+
+2003-10-22 Joseph S. Myers <jsm@polyomino.org.uk>
+
+ * obstack.h: Merge the following change from gnulib:
+ 2003-10-21 Paul Eggert <eggert@twinsun.com>
+ * obstack.h (obstack_1grow_fast): Properly parenthesize arg.
+ (obstack_ptr_grow_fast, obstack_int_grow_fast):
+ Don't use lvalue casts, as GCC plans to remove support for them
+ in GCC 3.5. Reported by Joseph S. Myers. This bug
+ was also present in the non-GCC version, indicating that this
+ code had always been buggy and had never been widely used.
+ (obstack_1grow, obstack_ptr_grow, obstack_int_grow, obstack_blank):
+ Use the fast variant of each macro, rather than copying the
+ definiens of the fast variant; that way, we'll be more likely to
+ catch future bugs in the fast variants.
+
+2003-09-22 Andrew Cagney <cagney@redhat.com>
+
+ * floatformat.h (struct floatformat): Add field "is_valid".
+
+2003-09-15 Andrew Cagney <cagney@redhat.com>
+
+ * floatformat.h (floatformat_to_double): Make input buffer constant.
+ (floatformat_from_double, floatformat_is_valid): Ditto.
+
+2003-09-15 Andrew Cagney <cagney@redhat.com>
+
+ * floatformat.h (struct floatformat): Make "exp_bias" signed.
+
+2003-09-15 Daniel Jacobowitz <drow@mvista.com>
+
+ * floatformat.h (floatformat_is_valid): Add prototype.
+
+2003-07-09 Bob Wilson <bob.wilson@acm.org>
+
+ * xtensa-config.h: Undef all macros before defining them.
+
+2003-07-06 H.J. Lu <hongjiu.lu@intel.com>
+
+ * demangle.h: Support C++.
+
+2003-07-01 Zack Weinberg <zack@codesourcery.com>
+
+ * filenames.h: New file imported from binutils.
+
+2003-06-30 Bob Wilson <bob.wilson@acm.org>
+
+ * xtensa-config.h: New file imported from binutils.
-2002-09-23 Daniel Jacobowitz <drow@mvista.com>
+2003-06-22 Zack Weinberg <zack@codesourcery.com>
- Merge from mainline:
- 2002-09-19 Jakub Jelinek <jakub@redhat.com>
- * elf/i386.h (R_386_TLS_TPOFF, R_386_TLS_IE, R_386_TLS_GOTIE):
- Define.
+ * safe-ctype.h (HC_UNKNOWN, HC_ASCII, HC_EBCDIC): Rename to
+ HOST_CHARSET_UNKNOWN, HOST_CHARSET_ASCII, HOST_CHARSET_EBCDIC
+ respectively.
- 2002-09-19 Nathan Tallent <eraxxon@alumni.rice.edu>
- * dis-asm.h: Remove (errant) trailing semicolon (;) from the
- extern "C" { } declaration.
+2003-06-21 Zack Weinberg <zack@codesourcery.com>
- 2002-09-04 Nick Clifton <nickc@redhat.com>
- * dis-asm.h (print_ppc_disassembler_options): Prototype.
+ * safe-ctype.h (HC_UNKNOWN, HC_ASCII, HC_EBCDIC, HOST_CHARSET):
+ New #defines.
- 2002-08-06 H.J. Lu <hjl@gnu.org>
- * bfdlink.h (bfd_link_info): Add allow_undefined_version.
- (bfd_elf_version_expr): Add symver and script.
+2003-06-17 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * ansidecl.h: Delete HAVE_LONG_DOUBLE GCC bootstrap support.
+
+2003-05-15 Jim Blandy <jimb@redhat.com>
+
+ * libiberty.h (hex_value): Make the value an unsigned int, to
+ avoid unexpected sign-extension when cast to unsigned types larger
+ than int --- like bfd_vma, on some platforms.
+ (_hex_value): Update declaration.
+
+2003-05-07 Jason Merrill <jason@redhat.com>
+
+ * hashtab.h (iterative_hash): Prototype.
+ (iterative_hash_object): New macro.
+
+2003-03-17 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * ansidecl.h (ATTRIBUTE_NONNULL, ATTRIBUTE_NULL_PRINTF,
+ ATTRIBUTE_NULL_PRINTF_1, ATTRIBUTE_NULL_PRINTF_2,
+ ATTRIBUTE_NULL_PRINTF_3, ATTRIBUTE_NULL_PRINTF_4,
+ ATTRIBUTE_NULL_PRINTF_5): New.
+ (ATTRIBUTE_PRINTF): Add ATTRIBUTE_NONNULL.
+
+2003-03-17 Jan Hubicka <jh@suse.cz>
+
+ * hashtab.h (htab_traverse_noresize): Declare.
+
+2003-02-27 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * libiberty.h: Document return value of physmem routines.
+
+2003-02-20 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * libiberty.h (physmem_total, physmem_available): Prototype.
+
+2003-02-20 Daniel Jacobowitz <drow@mvista.com>
+
+ * libiberty.h (lrealpath): Add declaration.
+
+2003-01-26 Daniel Jacobowitz <drow@mvista.com>
+
+ * hashtab.h (htab_alloc_with_arg, htab_free_with_arg): Add new types.
+ (struct htab): Add alloc_arg, alloc_with_arg_f, free_with_arg_f.
+ (htab_create_alloc_ex): New prototype.
+ (htab_set_functions_ex): New prototype.
+
+2002-07-17 Geoffrey Keating <geoffk@redhat.com>
+
+ * splay-tree.h (GTY): Define if undefined.
+ (splay_tree_allocate_fn): Return PTR for compatibility, not void *.
+ (struct splay_tree_node_s): Support gengtype.
+ (struct splay_tree_s): Likewise. Make allocate_data a PTR,
+ not a void *.
+
+2002-11-23 Simon Burge <simonb@wasabisystems.com>
+
+ * libiberty.h (basename): Add NetBSD to the list.
+
+2002-11-22 Daniel Jacobowitz <drow@mvista.com>
+
+ * libiberty.h (make_relative_prefix): Add prototype.
+
+2002-10-26 Roger Sayle <roger@eyesopen.com>
+
+ * partition.h: Close the extern "C" scope when compiling with C++.
+
+2002-10-26 Roger Sayle <roger@eyesopen.com>
+ DJ Delorie <dj@redhat.com>
+
+ PR bootstrap/8351
+ * getopt.h: Avoid prototyping getopt with no arguments in C++.
+
+2002-10-24 Nathan Tallent <eraxxon@alumni.rice.edu>
+
+ * ansidecl.h (__STDC__): Add (__alpha && __cplusplus) to the
+ list of platform compilers that may look, smell and act
+ like __STDC__ but that may not define it.
-2002-07-10 Jakub Jelinek <jakub@redhat.com>
+2002-10-11 David O'Brien <obrien@FreeBSD.org>
- * elf/common.h (SHT_GNU_LIBLIST, DT_GNU_PRELINKED,
- DT_GNU_CONFLICT*, DT_GNU_LIBLIST*): Define.
+ * getopt.h: getopt is in unistd.h (based on SUSv2).
-2002-07-01 Alan Modra <amodra@bigpond.net.au>
+2002-09-19 Alexandre Oliva <aoliva@redhat.com>
- * bfdlink.h (struct bfd_sym_chain): Declare.
- (struct bfd_link_info): Add gc_sym_list. Formatting fixes.
+ * libiberty.h (asprintf, vasprintf): Don't declare them if the
+ corresponding HAVE_DECL_ macro is 1.
2002-06-25 Alan Modra <amodra@bigpond.net.au>
@@ -48,22 +201,6 @@
* libiberty.h (basename): Don't declare if HAVE_DECL_BASENAME.
* getopt.h (getopt): Don't declare if HAVE_DECL_GETOPT.
-2002-06-18 Dave Brolley <brolley@redhat.com>
-
- From Catherine Moore:
- * dis-asm.h (print_insn_frv): New prototype.
-
-2002-06-09 Andrew Cagney <cagney@redhat.com>
-
- * remote-sim.h: Move to directory gdb/.
- * callback.h: Move to directory gdb/.
-
-2002-06-07 Charles Wilson <cwilson@ece.gatech.edu>
-
- * bfdlink.h (struct bfd_link_info): Change type of
- pei386_auto_import field to int so that -1 can mean enabled by
- default and 1 can mean enabled by command line switch.
-
2002-06-06 DJ Delorie <dj@redhat.com>
* hashtab.h (htab): Rearrange new members for backward
@@ -91,33 +228,6 @@
(htab_create): Replace with #define.
(htab_try_create): Delete.
-2002-05-31 Michal Ludvig <mludvig@suse.cz>
-
- * elf/dwarf2.h (DW_CFA_low_user, DW_CFA_high_user): Renamed
- to DW_CFA_lo_user, DW_CFA_hi_user respectively.
-
-2002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
-
- * dis-asm.h: Prototype print_insn_dlx.
-
-2002-05-23 Andrew Cagney <ac131313@redhat.com>
-
- * sim-d10v.h: Delete file. Moved to include/gdb/.
-
-2002-05-23 Jakub Jelinek <jakub@redhat.com>
-
- * elf/common.h (PT_TLS, SHF_TLS, STT_TLS, DF_STATIC_TLS): Define.
- * elf/ia64.h (R_IA64_LTOFF_TPREL22): Renamed from R_IA64_LTOFF_TP22.
- * elf/i386.h: Add TLS relocs.
-
-2002-05-21 H.J. Lu (hjl@gnu.org)
-
- * bfdlink.h (bfd_link_info): Add allow_multiple_definition.
-
-2002-05-17 J"orn Rennecke <joern.rennecke@superh.com>
-
- * dis-asm.h (print_insn_shl, print_insn_sh64l): Remove prototype.
-
2002-04-16 David S. Miller <davem@redhat.com>
* xregex2.h (__restrict_arr): Define to __restrict on GCC
@@ -127,15 +237,11 @@
* dyn-string.h: Also allow IN_GLIBCPP_V3 to redefine names.
-2002-03-10 Daniel Jacobowitz <drow@mvista.com>
-
- * gdb: New directory.
-
2002-03-06 Andrew Cagney <ac131313@redhat.com>
* floatformat.h (floatformat_arm_ext): Delete declaration.
-2002-02-21 Jim Blandy <jimb@redhat.com>
+2002-02-22 Jim Blandy <jimb@redhat.com>
Allow the user to specify functions for allocating memory for
splay tree roots and nodes.
@@ -145,25 +251,6 @@
`allocate_data'.
(splay_tree_new_with_allocator): New function declaration.
-2002-02-15 Alan Modra <amodra@bigpond.net.au>
-
- Support arbitrary length fill patterns.
- * bfdlink.h (enum bfd_link_order_type): Remove bfd_fill_link_order.
- (struct bfd_link_order): Remove fill. Add data.size.
-
-2002-02-08 Alexandre Oliva <aoliva@redhat.com>
-
- Contribute sh64-elf.
- 2000-11-25 Hans-Peter Nilsson <hpn@cygnus.com>
- * dis-asm.h (print_insn_sh64): New prototype.
- (print_insn_sh64l): New prototype.
- (print_insn_sh64x_media): New prototype.
-
-2002-02-05 Frank Ch. Eigler <fche@redhat.com>
-
- * dis-asm.h (disassemble_info): New field `insn_sets'.
- (INIT_DISASSEMBLE_INFO): Clear it.
-
2002-02-05 Jason Merrill <jason@redhat.com>
* demangle.h (cplus_demangle_v3): Add "options" parm.
@@ -175,48 +262,15 @@
* demangle.h (cplus_demangle_v3_type): New prototype.
-2002-01-31 Ivan Guzvinec <ivang@opencores.org>
-
- * dis-asm.h : Add support for or32 targets
-
2002-01-28 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* libiberty.h (C_alloca): Add ATTRIBUTE_MALLOC.
-2002-01-27 David O'Brien <obrien@FreeBSD.org>
-
- * cgen.h (BFD_VERSION): Use BFD_VERSION_DATE instead.
-
-2001-12-14 Nick Clifton <nickc@cambridge.redhat.com>
-
- * dis-asm.h (INIT_DISASSEMBLE_INFO_NO_ARCH): Initialise the
- disassembler_options field (to NULL).
-
-2001-12-13 Jakub Jelinek <jakub@redhat.com>
-
- * bfdlink.h (struct bfd_link_info): Add eh_frame_hdr field.
-
-2001-12-07 Geoffrey Keating <geoffk@redhat.com>
-
- * dis-asm.h (print_insn_xstormy16): Declare.
-
2001-12-06 Richard Henderson <rth@redhat.com>
* demangle.h (no_demangling): New.
(NO_DEMANGLING_STYLE_STRING): New.
-2001-11-14 Alan Modra <amodra@bigpond.net.au>
-
- * dis-asm.h (print_insn_i386): Declare.
-
-2001-11-11 Timothy Wall <twall@alum.mit.edu>
-
- * dis-asm.h: Fix comment to refer to octets rather than bytes.
-
-2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
-
- * dis-asm.h (print_insn_mmix): Add prototype.
-
2001-10-24 Neil Booth <neil@daikokuya.demon.co.uk>
* safe-ctype.h (_sch_isbasic, IS_ISOBASIC): New.
@@ -228,19 +282,11 @@
* libiberty.h (_hex_value): Const-ify.
(hex_init): Delete.
-2001-10-16 Christopher Faylor <cgf@redhat.com>
-
- * filenames.h: Add cygwin to the list of dosish style path systems.
-
2001-10-07 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* demangle.h (demangler_engine): Const-ify.
* libiberty.h (buildargv): Likewise.
-2001-10-03 Vassili Karpov <malc@pulsesoft.com>
-
- * bfdlink.h (struct bfd_link_info): Add nocopyreloc field.
-
2001-09-24 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* libiberty.h (reconcat): New function.
@@ -270,24 +316,6 @@
* ansidecl.h (VA_OPEN, VA_CLOSE): Allow multiple uses.
-2001-08-25 Nick Clifton <nickc@cambridge.redhat.com>
-
- * bfdlink.h (struct bfd_link_info): Change 'spare_dynamic_tags' to
- unsigned to remove a compile time warning message.
-
-2001-08-24 H.J. Lu <hjl@gnu.org>
-
- * bfdlink.h (bfd_link_hash_table_type): New. The linker hash
- table type, bfd_link_generic_hash_table and
- bfd_link_elf_hash_table.
- (bfd_link_hash_table): Add a new field, type, for the linker
- hash table type.
-
-2001-08-23 Jakub Jelinek <jakub@redhat.com>
-
- * bfdlink.h (struct bfd_link_info): Add combreloc and
- spare_dynamic_tags fields.
-
2001-08-23 Lars Brinkhoff <lars@nocrew.org>
* dyn-string.h, fibheap.h, partition.h, sort.h, splay-tree.h:
@@ -298,10 +326,6 @@
* fibheap.h: Tidy formatting.
(fibnode_t): Limit degree to 31 bits to avoid warning.
-2001-08-20 Daniel Berlin <dan@cgsoftware.com>
-
- * fibheap.h: New file. Fibonacci heap.
-
2001-08-20 Andrew Cagney <ac131313@redhat.com>
* floatformat.h (floatformat_arm_ext): Document as deprecated.
@@ -310,6 +334,10 @@
(floatformat_ia64_spill_big, floatformat_ia64_quad_big)
(floatformat_m88110_harris_ext): Declare.
+2001-08-20 Daniel Berlin <dan@cgsoftware.com>
+
+ * fibheap.h: New file. Fibonacci heap.
+
2001-08-18 Zack Weinberg <zackw@panix.com>
* ansidecl.h: Reorganize for readability, remove documentation
@@ -332,11 +360,6 @@
(re_comp): Define to xre_comp.
(re_exec): Define to xre_exec.
-2001-08-02 Charles Wilson <cwilson@ece.gatech.edu>
-
- * bfdlink.h (struct bfd_link_info): add new boolean
- field pei386_auto_import.
-
2001-07-18 Andreas Jaeger <aj@suse.de>
* xregex2.h: Place under LGPL version 2.1.
@@ -346,10 +369,6 @@
* xregex.h: New file to support libiberty regex.
* xregex2.h: Ditto.
-2001-06-15 Hans-Peter Nilsson <hp@axis.com>
-
- * bfdlink.h (struct bfd_link_info): New member export_dynamic.
-
2001-05-16 Matt Kraai <kraai@alumni.carnegiemellon.edu>
* partition.h: Fix misspelling of `implementation'.
@@ -369,18 +388,10 @@
* splay-tree.h (splay_tree_max): New function.
(splay_tree_min): Likewise.
-2001-04-27 Johan Rydberg <jrydberg@opencores.org>
-
- * dis-asm.h (print_insn_openrisc): Add prototype.
-
2001-04-15 Daniel Berlin <dan@cgsoftware.com>
* ternary.h: New file - Ternary search tree header.
-2001-04-13 Jakub Jelinek <jakub@redhat.com>
-
- * bfdlink.h (bfd_link_discard): Add discard_sec_merge.
-
2001-04-03 Zack Weinberg <zackw@stanford.edu>
* ansidecl.h: All logic from gcc/gansidecl.h moved here.
@@ -422,46 +433,17 @@
* safe-ctype.h (_sch_test): Cast enum bit to unsigned short int for pcc
compatibility.
-2001-02-18 lars brinkhoff <lars@nocrew.org>
-
- * dis-asm.h: Add PDP-11 target.
-
-2001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * dis-asm.h: Add linux target for S/390.
-
-2001-01-11 Peter Targett <peter.targett@arccores.com>
-
- * dis-asm.h (arc_get_disassembler): Correct declaration.
-
-2001-01-09 Philip Blundell <philb@gnu.org>
-
- * bin-bugs.h (REPORT_BUGS_TO): Set to `bug-binutils@gnu.org'.
-
2000-12-18 Joseph S. Myers <jsm28@cam.ac.uk>
* COPYING: Update to current
ftp://ftp.gnu.org/pub/gnu/Licenses/COPYING-2.0 (fixes references
to 19yy as example year in copyright notice).
-2000-12-19 Hans-Peter Nilsson <hp@bitrange.com>
-
- * dis-asm.h (struct disassemble_info): New member "section".
- (INIT_DISASSEMBLE_INFO_NO_ARCH): Initialize private_data member.
- Initialize section member.
-
2000-12-16 Herman A.J. ten Brugge <Haj.Ten.Brugge@net.HCC.nl>
* safe-ctype.h: Make code work on all targets and not just on
targets where a char is 8 bits.
-2000-12-10 Fred Fish <fnf@be.com>
-
- * bfdlink.h (struct bfd_link_info): Add new allow_shlib_undefined
- member to struct for systems where it is normal to have undefined
- symbols in shared libraries at runtime and the runtime linker
- takes care of redirecting them.
-
2000-12-07 Zack Weinberg <zack@wolery.stanford.edu>
* safe-ctype.h: New file.
@@ -492,19 +474,10 @@
* hashtab.h: Change void * to PTR where necessary.
-2000-10-11 Mark Mitchell <mark@codesourcery.com>
+2000-09-10 Mark Mitchell <mark@codesourcery.com>
* splay-tree.h (splay_tree_predecessor): Declare.
-2000-09-29 Hans-Peter Nilsson <hp@axis.com>
-
- * dis-asm.h: Declare cris_get_disassembler, not print_insn_cris.
- Fix typo in comment.
-
-2000-09-28 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * alloca-conf.h: New file (copied from libiberty).
-
2000-09-05 John David Anglin <dave@hiauly1.hia.nrc.ca>
* md5.h (md5_uint32): Choose via INT_MAX instead of UINT_MAX.
@@ -522,31 +495,6 @@
* libiberty.h (ARRAY_SIZE): New macro.
-2000-07-29 Nick Clifton <nickc@cygnus.com>
-
- * os9k.h: Add copyright notice.
- Fix formatting.
-
-2000-07-22 Jason Eckhardt <jle@cygnus.com>
-
- * dis-asm.h (print_insn_i860): Add prototype.
-
-2000-07-20 H.J. Lu <hjl@gnu.org>
-
- * bfdlink.h (bfd_link_info): Add new_dtags.
-
-2000-07-20 Hans-Peter Nilsson <hp@axis.com>
-
- * dis-asm.h (print_insn_cris): Declare.
-
-2000-07-19 H.J. Lu (hjl@gnu.org)
-
- * bfdlink.h (bfd_link_info): Add flags and flags_1.
-
-2000-06-05 DJ Delorie <dj@redhat.com>
-
- * MAINTAINERS: new
-
2000-06-21 Alex Samuel <samuel@codesourcery.com>
* dyn-string.h (dyn_string_init, dyn_string_new,
@@ -562,16 +510,6 @@
dyn_string_append_char, dyn_string_substring): Change return type
to int.
-2000-06-18 Stephane Carrez <stcarrez@worldnet.fr>
-
- * dis-asm.h (print_insn_m68hc12): Define.
- (print_insn_m68hc11): Likewise.
-
-2000-06-18 Nick Clifton <nickc@redhat.com>
-
- * os9k.h: Change values of MODSYNC and CRCCON due to bug report
- from Russ Magee <rmagee@home.com>.
-
2000-06-07 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* demangle.h (demangling_styles): Remove trailing comma in enum.
@@ -594,31 +532,16 @@ Tue May 30 16:53:34 2000 Andrew Cagney <cagney@b1.cygnus.com>
* floatformat.h (struct floatformat): Add field name.
-2000-05-26 Eli Zaretskii <eliz@is.elta.co.il>
-
- * filenames.h: New file.
- (HAVE_DOS_BASED_FILE_SYSTEM, IS_DIR_SEPARATOR)
- (IS_ABSOLUTE_PATH, FILENAME_CMP): New macros.
-
2000-05-23 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* getopt.h (getopt): Also check HAVE_DECL_* when prototyping.
* libiberty.h (basename): Likewise.
-2000-05-17 S. Bharadwaj Yadavalli <sby@scrugs.lkg.dec.com>
- Rick Gorton <gorton@scrugs.lkg.dec.com>
-
- * bfdlink.h (struct bfd_link_info): Add emitrelocations flag.
-
-2000-05-08 Alan Modra <alan@linuxcare.com.au>
-
- * dis-asm.h (print_insn_tic54x): Declare.
-
2000-05-06 Zack Weinberg <zack@wolery.cumb.org>
- * ansidecl.h: #define __extension__ to nothing if
- GCC_VERSION < 2008.
+ * ansidecl.h: #define __extension__ to nothing if
+ GCC_VERSION < 2008.
2000-05-04 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
@@ -636,9 +559,9 @@ Thu May 4 17:15:26 2000 Philippe De Muyter <phdm@macqel.be>
2000-04-28 Kenneth Block <block@zk3.dec.com>
Jason Merrill <jason@casey.cygnus.com>
- * demangle.h (libiberty_demanglers): new table for different styles.
- (cplus_demangle_set_style): New function for setting style.
- (cplus_demangle_name_to_style): New function to translate name.
+ * demangle.h (libiberty_demanglers): new table for different styles.
+ (cplus_demangle_set_style): New function for setting style.
+ (cplus_demangle_name_to_style): New function to translate name.
2000-04-24 Mark Mitchell <mark@codesourcery.com>
@@ -649,11 +572,6 @@ Thu May 4 17:15:26 2000 Philippe De Muyter <phdm@macqel.be>
* sort.h: New file.
-Fri Apr 21 13:20:53 2000 Richard Henderson <rth@cygnus.com>
- David Mosberger <davidm@hpl.hp.com>
-
- * dis-asm.h (print_insn_ia64): Declare.
-
Tue Apr 18 16:22:30 2000 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
* hashtab.h (enum insert_option): New type.
@@ -668,24 +586,12 @@ Tue Apr 18 16:22:30 2000 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
* splay-tree.h (splay_tree_remove): Declare.
-2000-04-04 Alan Modra <alan@linuxcare.com.au>
-
- * bin-bugs.h (REPORT_BUGS_TO): Remove translated part.
-
-2000-04-03 Alan Modra <alan@linuxcare.com.au>
-
- * bin-bugs.h: New file.
-
2000-03-30 Mark Mitchell <mark@codesourcery.com>
* hashtab.h (hashval_t): New type.
(htab_find_with_hash): Use it as an argument.
(htab_find_slot_with_hash): Likewise.
-2000-03-27 Denis Chertykov <denisc@overta.ru>
-
- * dis-asm.h (print_insn_avr): Declare.
-
2000-03-14 Bernd Schmidt <bernds@cygnus.co.uk>
* hashtab.h (htab_trav): Modify type so that first arg is of type
@@ -713,66 +619,11 @@ Tue Apr 18 16:22:30 2000 Richard Kenner <kenner@vlsi1.ultra.nyu.edu>
(hash_table_entry_t): Discard; just use void * for element
type.
-2000-03-01 H.J. Lu <hjl@gnu.org>
-
- * bfdlink.h (bfd_link_callbacks): Add a boolean arg to
- the undefined_symbol callback.
-
-2000-02-23 Linas Vepstas <linas@linas.org>
-
- * dis-asm.h (print_insn_i370): Declare.
-
-Tue Feb 22 15:19:54 2000 Andrew Cagney <cagney@b1.cygnus.com>
-
- * remote-sim.h (sim_trace): Document return values.
- (sim_set_trace): Declare. Deprecate.
-
-2000-02-21 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * dis-asm.h (struct disassemble_info): Change `length' param of
- read_memory_func to unsigned. Change type of `buffer_length' and
- `octets_per_byte' to unsigned.
- (buffer_read_memory): Change `length' param to unsigned.
-
-2000-02-16 Nick Clifton <nickc@cygnus.com>
-
- * dis-asm.h: Add prototypes for ARM register name functions.
-
-Wed Feb 9 18:45:49 2000 Andrew Cagney <cagney@b1.cygnus.com>
-
- * wait.h: Delete. No longer used by GDB.
-
-Tue Feb 8 17:01:13 2000 Andrew Cagney <cagney@b1.cygnus.com>
-
- * remote-sim.h (sim_resume): Clarify use of SIGGNAL.
- (sim_stop_reason): Clarify meaning of sim_signalled.
-
-2000-02-03 Timothy Wall <twall@redhat.com>
-
- * dis-asm.h (struct disassemble_info): Added octets_per_byte
- field and initialize it to one (1).
-
-2000-01-27 Nick Clifton <nickc@redhat.com>
-
- * dis-asm.h: Add prototype for disassembler_usage().
- Add prototype for arm_disassembler_options().
- Remove prototype for arm_toggle_regnames().
- Add prototype for parse_arm_disassembler_option().
-
Sat Jan 1 19:06:52 2000 Hans-Peter Nilsson <hp@bitrange.com>
* symcat.h (STRINGX) [!__STDC__ || ALMOST_STDC]: Change "?" to "s"
to stringify argument s.
-Wed Dec 15 11:22:56 1999 Jeffrey A Law (law@cygnus.com)
-
- * hp-symtab.h (HP_LANGUAGE_FORTRAN): New enumeration constant.
- (HP_LANGUAGE_F77): Define using HP_LANGUAGE_FORTRAN.
-
-1999-12-15 Doug Evans <dje@transmeta.com>
-
- * dis-asm.h: Enclose in extern "C" ifdef __cplusplus.
-
1999-12-05 Mark Mitchell <mark@codesourcery.com>
* splay-tree.h (struct splay_tree_node): Rename to ...
@@ -799,26 +650,12 @@ Wed Nov 10 12:43:21 1999 Philippe De Muyter <phdm@macqel.be>
* ansidecl.h: Define and test `GCC_VERSION', not `HAVE_GCC_VERSION'.
-1999-11-04 Jimmy Guo <guo@cup.hp.com>
-
- * hp-symtab.h (dntt_type_fparam): Add doc_ranges, misc_kind
- fields, change location type to CORE_ADDR from int.
- (dntt_type_const): Name the 5th field location_type.
-
-Sun Oct 24 19:11:32 1999 Andrew Cagney <cagney@b1.cygnus.com>
-
- * sim-d10v.h (SIM_D10V_TS2_DMAP_REGNUM): Define.
-
1999-10-23 08:51 -0700 Zack Weinberg <zack@bitmover.com>
* hashtab.h: Give hash_table_t a struct tag. Add prototypes
for clear_hash_table_slot and traverse_hash_table. Correct
prototype of all_hash_table_collisions.
-Sat Oct 23 19:00:13 1999 Andrew Cagney <cagney@b1.cygnus.com>
-
- * sim-d10v.h: New file.
-
Fri Oct 15 01:47:51 1999 Vladimir Makarov <vmakarov@loony.cygnus.com>
* hashtab.h: New file.
@@ -843,10 +680,6 @@ Tue Sep 14 00:35:02 1999 Marc Espie <espie@cvs.openbsd.org>
* libiberty.h (xmemdup): Add prototype for new function.
-1999-09-04 Steve Chamberlain <sac@pobox.com>
-
- * dis-asm.h (print_insn_pj): Declare.
-
1999-09-01 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* obstack.h (obstack_grow, obstack_grow0): Move (char*) casts
@@ -867,37 +700,6 @@ Tue Sep 14 00:35:02 1999 Marc Espie <espie@cvs.openbsd.org>
* ansidecl.h: Copy attribute support macros from egcs.
-1999-06-22 Mark Mitchell <mark@codesourcery.com>
-
- * bfdlink.h (struct bfd_link_hash_entry): Add init_function and
- fini_function.
-
-1999-06-20 Mark Mitchell <mark@codesourcery.com>
-
- * mips.h (Elf32_Internal_Msym): New structure.
- (Elf32_External_Msym): Likewise.
- (ELF32_MS_REL_INDEX): New macro.
- (ELF32_MS_FLAGS): Likewise.
- (ELF32_MS_INFO): Likewise.
-
-1999-06-14 Nick Clifton <nickc@cygnus.com>
-
- * dis-asm.h (arm_toggle_regnames): New prototype.
- (struct diassemble_info): New field: disassembler_options.
-
-1999-04-11 Richard Henderson <rth@cygnus.com>
-
- * bfdlink.h (bfd_elf_version_expr): Rename `match' to `pattern'.
- Add `match' callback function.
-
-1999-04-10 Richard Henderson <rth@cygnus.com>
-
- * bfdlink.h (bfd_link_info): Add no_undefined.
-
-1999-04-08 Nick Clifton <nickc@cygnus.com>
-
- * dis-asm.h: Add prototype for print_insn_mcore.
-
1999-04-02 Mark Mitchell <mark@codesourcery.com>
* splay-tree.h (splay_tree_compare_pointers): Declare.
@@ -910,24 +712,6 @@ Wed Mar 24 12:46:29 1999 Andrew Cagney <cagney@amy.cygnus.com>
* libiberty.h (basename): Cygwin{,32} should have the prototype.
-1999-02-22 Jim Lemke <jlemke@cygnus.com>
-
- * bfdlink.h (bfd_link_info): add field "mpc860c0".
-
-Mon Feb 1 21:05:46 1999 Catherine Moore <clm@cygnus.com>
-
- * dis-asm.h (print_insn_i386_att): Declare.
- (print_insn_i386_intel): Declare.
-
-1998-12-30 Michael Meissner <meissner@cygnus.com>
-
- * dis-asm.h (INIT_DISASSEMBLE_INFO_NO_ARCH): Cast STREAM and
- FPRINTF_FUNC to avoid compiler warnings.
-
-Wed Dec 30 16:07:14 1998 David Taylor <taylor@texas.cygnus.com>
-
- * dis-asm.h: change void * to PTR (two places).
-
Mon Dec 14 09:53:31 1998 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* demangle.h: Don't check IN_GCC anymore.
@@ -935,15 +719,6 @@ Mon Dec 14 09:53:31 1998 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
Tue Dec 8 00:30:31 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
- The following changes were made by Elena Zannoni
- <ezannoni@kwikemart.cygnus.com> and Edith Epstein
- <eepstein@sophia.cygnus.com> as part of a project to merge in
- changes made by HP; HP did not create ChangeLog entries.
-
- * dis-asm.h (struct disassemble_info): change the type of stream
- from FILE* to void*, for use with gdb's new type GDB_FILE.
- (fprintf_ftype): change FILE* parameter type to void*.
-
* demangle.h: (DMGL_EDG): new macro for Kuck and Associates
(DMGL_STYLE_MASK): modify to include Kuck and Assoc style
(demangling_styles): add new edg_demangling style
@@ -956,12 +731,6 @@ Tue Dec 8 00:30:31 1998 Elena Zannoni <ezannoni@kwikemart.cygnus.com>
(ARM_DEMANGLING): coerce to int.
(HP_DEMANGLING): new macro.
- * hp-symtab.h: rewritten, from HP.
- (quick_procedure): change type of language field to unsigned int
- (quick_module): change type of language field to unsigned int
- (struct dntt_type_svar): add field thread_specific.
- (hp_language): add languages modcal and dmpascal.
-
Fri Nov 20 13:14:00 1998 Andrew Cagney <cagney@b1.cygnus.com>
* libiberty.h (basename): Add prototype for FreeBSD.
@@ -977,19 +746,11 @@ Sun Nov 8 17:42:25 1998 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* demangle.h: Never define PARAMS().
* splay-tree.h: Likewise.
-Sat Nov 7 18:30:20 1998 Peter Schauer <peter.schauer@regent.e-technik.tu-muenchen.de>
-
- * dis-asm.h (print_insn_vax): Declare.
-
Sat Nov 7 16:04:03 1998 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* demangle.h: Don't include gansidecl.h.
* splay-tree.h: Likewise.
-1998-10-26 16:03 Ulrich Drepper <drepper@cygnus.com>
-
- * bfdlink.h (struct bfd_link_info): Add new field optimize.
-
Thu Oct 22 19:58:00 1998 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* splay-tree.h: Wrap function pointer parameter declarations in
@@ -1025,8 +786,8 @@ Tue Feb 24 13:05:02 1998 Doug Evans <devans@canuck.cygnus.com>
Tue Feb 17 12:32:18 1998 Andrew Cagney <cagney@b1.cygnus.com>
* remote-sim.h (sim_fetch_register, sim_store_register): Add
- register length parameter. Functions return actual length of
- register.
+ register length parameter. Functions return actual length of
+ register.
Thu Feb 12 16:29:01 1998 Ian Lance Taylor <ian@cygnus.com>
@@ -1054,6 +815,10 @@ Tue Dec 2 10:20:53 1997 Nick Clifton <nickc@cygnus.com>
* dis-asm.h (disasm_symaddr): New prototype.
+Mon Dec 1 20:24:18 1997 J"orn Rennecke <amylaar@cygnus.co.uk>
+
+ * coff/sh.h (R_SH_SWITCH8): New.
+
Mon Dec 1 11:29:35 1997 Doug Evans <devans@canuck.cygnus.com>
* callback.h (CB_SYSCALL): Comment out arg names in prototypes.
@@ -1080,7 +845,7 @@ Tue Nov 25 01:35:52 1997 Doug Evans <devans@seba.cygnus.com>
Sat Nov 22 23:34:15 1997 Andrew Cagney <cagney@b1.cygnus.com>
* remote-sim.h (sim_stop_reason): Clarify sim_signalled SIGRC
- argument.
+ argument.
Mon Nov 17 14:00:51 1997 Doug Evans <devans@seba.cygnus.com>
@@ -1151,7 +916,7 @@ Tue Jul 22 17:59:54 1997 Ian Lance Taylor <ian@cygnus.com>
Fri Jun 6 13:02:33 1997 Andrew Cagney <cagney@b1.cygnus.com>
- * remote-sim.h (sim_kill): Mark as depreciated.
+ * remote-sim.h (sim_kill): Mark as deprecated.
Fri May 23 13:43:41 1997 Fred Fish <fnf@cygnus.com>
@@ -1160,12 +925,12 @@ Fri May 23 13:43:41 1997 Fred Fish <fnf@cygnus.com>
Thu May 22 11:32:49 1997 Andrew Cagney <cagney@b1.cygnus.com>
* remote-sim.h: Review documentation. Clarify restrictions on
- when functions can be called.
+ when functions can be called.
Wed May 21 16:47:53 1997 Andrew Cagney <cagney@b1.cygnus.com>
* remote-sim.h (sim_set_profile_size): Add prototype, document as
- depreciated.
+ deprecated.
Tue May 20 09:32:22 1997 Andrew Cagney <cagney@b1.cygnus.com>
@@ -1182,6 +947,14 @@ Thu May 15 01:24:16 1997 Mark Alexander <marka@cygnus.com>
* obstack.h (obstack_specify_allocation_with_arg, obstack_chunkfun,
obstack_freefun): Eliminate compile warnings in gdb.
+Tue May 13 10:21:14 1997 Nick Clifton <nickc@cygnus.com>
+
+ * coff/arm.h (constants): Added new flag bits F_APCS_26 and
+ F_APCS_SET for the f_flags field of the filehdr structure. Added new
+ flags: F_APCS26, F_ARM_2, F_ARM_3, F_ARM_7, F_ARM_7T to store
+ information in the flags field of the internal_f structure used by BFD
+ routines.
+
Tue Apr 22 10:24:34 1997 Fred Fish <fnf@cygnus.com>
* floatformat.h (floatformat_byteorders): Add comments for previous
@@ -1191,16 +964,16 @@ Tue Apr 22 10:24:34 1997 Fred Fish <fnf@cygnus.com>
Fri Apr 18 13:04:49 1997 Andrew Cagney <cagney@b1.cygnus.com>
* remote-sim.h (sim_stop): New interface - asynchronous
- notification of a request to stop / suspend the running
- simulation.
+ notification of a request to stop / suspend the running
+ simulation.
* remote-sim.h (enum sim_stop): Add sim_running and sim_polling as
- states for use internal to simulators.
+ states for use internal to simulators.
* callback.h (struct host_callback_strut): Put a magic number at
- the end of the struct to allow basic checking.
+ the end of the struct to allow basic checking.
(struct host_callback_struct ): Add poll_quit - so
- that the console etc can be polled at regular intervals.
+ that the console etc can be polled at regular intervals.
Thu Apr 17 02:17:12 1997 Doug Evans <dje@canuck.cygnus.com>
@@ -1211,7 +984,7 @@ Thu Apr 17 02:17:12 1997 Doug Evans <dje@canuck.cygnus.com>
Wed Apr 2 17:09:12 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
* remote-sim.h (sim_trace, sim_size): Make these global. They
- will go away shortly.
+ will go away shortly.
Wed Apr 2 15:23:49 1997 Doug Evans <dje@canuck.cygnus.com>
@@ -1241,7 +1014,7 @@ Mon Mar 17 19:22:12 1997 Ian Lance Taylor <ian@cygnus.com>
Mon Mar 17 14:57:55 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
* remote-sim.h: New file, copied in from gdb/remote-sim.h. One
- day this will be placed in a directory of its own.
+ day this will be placed in a directory of its own.
Sat Mar 15 19:00:14 1997 Ian Lance Taylor <ian@cygnus.com>
@@ -1250,8 +1023,8 @@ Sat Mar 15 19:00:14 1997 Ian Lance Taylor <ian@cygnus.com>
Thu Mar 6 15:46:59 1997 Andrew Cagney <cagney@kremvax.cygnus.com>
* callback.h (struct host_callback_struct): Add callbacks -
- flush_stdout, write_stderr, flush_stderr, vprintf_filtered,
- evprintf_filtered. Delete redundant callbacks - printf_filtered.
+ flush_stdout, write_stderr, flush_stderr, vprintf_filtered,
+ evprintf_filtered. Delete redundant callbacks - printf_filtered.
Thu Feb 27 23:18:27 1997 Ian Lance Taylor <ian@cygnus.com>
@@ -1276,10 +1049,6 @@ Thu Feb 6 14:20:01 1997 Martin M. Hunt <hunt@pizza.cygnus.com>
bytes_per_chunk and display_endian to control the
display of raw instructions.
-Fri Dec 27 22:17:37 1996 Fred Fish <fnf@cygnus.com>
-
- * dis-asm.h (print_insn_tic80): Declare.
-
Sun Dec 8 17:11:12 1996 Doug Evans <dje@canuck.cygnus.com>
* callback.h (host_callback): New member `error'.
@@ -1367,7 +1136,7 @@ Tue Jul 23 17:37:58 1996 Fred Fish <fnf@cygnus.com>
can define PRIVATE_XMALLOC and then define xmalloc and
xrealloc anyway they want.
(basename): Document in source that we can't declare the
- parameter type because it is declared inconsistently across
+ parameter type because it is declared inconsistently across
different systems.
Mon Jul 22 13:16:13 1996 Richard Henderson <rth@tamu.edu>
@@ -1530,7 +1299,13 @@ Thu May 18 04:25:50 1995 Ken Raeburn <raeburn@kr-laptop.cygnus.com>
Sat May 13 10:14:08 1995 Steve Chamberlain <sac@slash.cygnus.com>
+ * coff/pe.h: New file.
* bfdlink.h (subsytem, stack_heap_parameters): New.
+ * coff/i386.h (NT_SECTION_ALIGNMENT, NT_FILE_ALIGNMENT,
+ NT_DEF_RESERVE, NT_DEF_COMMIT): New.
+ * coff/internal.h (internal_filehdr): New fields for PE.
+ (IMAGE_DATA_DIRECTORY): New.
+ (internal_aouthdr): New fields for PE.
Thu May 4 14:36:42 1995 Jason Merrill <jason@phydeaux.cygnus.com>
@@ -1605,6 +1380,8 @@ Tue Oct 25 11:38:02 1994 Ian Lance Taylor <ian@sanguine.cygnus.com>
Sun Sep 04 17:58:10 1994 Richard Earnshaw (rwe@pegasus.esprit.ec.org)
+ * aout/aout64.h: Only define QMAGIC if it isn't already defined.
+
* dis-asm.h: Add support for the ARM.
Wed Aug 10 12:51:41 1994 Doug Evans (dje@canuck.cygnus.com)
@@ -1750,6 +1527,10 @@ Fri Aug 6 17:05:47 1993 David J. Mackenzie (djm@thepub.cygnus.com)
* getopt.h, obstack.h: Update to latest FSF version.
+Mon Aug 2 16:37:14 1993 Stu Grossman (grossman at cygnus.com)
+
+ * coff/i386.h: Add Lynx magic number.
+
Mon Aug 2 14:45:29 1993 John Gilmore (gnu@cygnus.com)
* dis-asm.h: Move enum outside of struct defn to avoid warnings.
@@ -1779,6 +1560,10 @@ Thu Jul 15 12:41:15 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
* dis-asm.h: Added declaration of print_insn_m88k.
+Thu Jul 8 09:05:26 1993 Doug Evans (dje@canuck.cygnus.com)
+
+ * opcode/h8300.h: Lots of little fixes for the h8/300h.
+
Fri Jul 2 10:31:59 1993 Ian Lance Taylor (ian@cygnus.com)
* ansidecl.h: Use ANSI macros if __mips and _SYSTYPE_SVR4 are
@@ -1803,6 +1588,9 @@ Tue Jun 8 12:16:03 1993 Steve Chamberlain (sac@phydeaux.cygnus.com)
Support for H8/300-H
* dis-asm.h (print_insn_h8300, print_insn_h8300h): Declare it.
+ * coff/h8300.h: New magic number.
+ * coff/internal.h: New relocations.
+ * opcode/h8300.h: Lots of new opcodes.
Tue Jun 1 07:35:03 1993 Ken Raeburn (raeburn@kr-pc.cygnus.com)
@@ -2081,7 +1869,7 @@ Mon Jan 27 22:01:13 1992 Steve Chamberlain (sac at cygnus.com)
Wed Dec 18 17:19:44 1991 Stu Grossman (grossman at cygnus.com)
- * bfd.h, ieee.h: ANSIfy enums.
+ * bfd.h, ieee.h, opcode/m68k.h, opcode/sparc.h: ANSIfy enums.
Thu Dec 12 20:59:56 1991 John Gilmore (gnu at cygnus.com)
@@ -2143,8 +1931,8 @@ Sat Nov 30 20:46:43 1991 Steve Chamberlain (sac at rtl.cygnus.com)
Wed Nov 27 10:38:31 1991 Steve Chamberlain (sac at rtl.cygnus.com)
* internalcoff.h: (internal_scnhdr) took out #def dependency, now
- s_nreloc and s_nlnno are always long. (internal_reloc): allways
- has an offset field now.
+ s_nreloc and s_nlnno are always long.
+ (internal_reloc): Always has an offset field now.
Fri Nov 22 08:12:58 1991 John Gilmore (gnu at cygnus.com)
@@ -2224,7 +2012,7 @@ Fri Oct 25 03:18:20 1991 John Gilmore (gnu at cygnus.com)
Thu Oct 24 22:11:11 1991 John Gilmore (gnu at cygnus.com)
- RS/6000 support, by Metin G. Ozisik, Mimi Phûông-Thåo Võ, and
+ RS/6000 support, by Metin G. Ozisik, Mimi Phûông-Thåo Võ, and
John Gilmore.
* a.out.gnu.h: Update slightly.
diff --git a/contrib/binutils/include/ansidecl.h b/contrib/binutils/include/ansidecl.h
index d169b4f..d2c8776 100644
--- a/contrib/binutils/include/ansidecl.h
+++ b/contrib/binutils/include/ansidecl.h
@@ -268,8 +268,21 @@ So instead we use the macro below and test it against specific values. */
#define ATTRIBUTE_NORETURN __attribute__ ((__noreturn__))
#endif /* ATTRIBUTE_NORETURN */
+/* Attribute `nonnull' was valid as of gcc 3.3. */
+#ifndef ATTRIBUTE_NONNULL
+# if (GCC_VERSION >= 3003)
+# define ATTRIBUTE_NONNULL(m) __attribute__ ((__nonnull__ (m)))
+# else
+# define ATTRIBUTE_NONNULL(m)
+# endif /* GNUC >= 3.3 */
+#endif /* ATTRIBUTE_NONNULL */
+
+/* Use ATTRIBUTE_PRINTF when the format specifier must not be NULL.
+ This was the case for the `printf' format attribute by itself
+ before GCC 3.3, but as of 3.3 we need to add the `nonnull'
+ attribute to retain this behavior. */
#ifndef ATTRIBUTE_PRINTF
-#define ATTRIBUTE_PRINTF(m, n) __attribute__ ((__format__ (__printf__, m, n)))
+#define ATTRIBUTE_PRINTF(m, n) __attribute__ ((__format__ (__printf__, m, n))) ATTRIBUTE_NONNULL(m)
#define ATTRIBUTE_PRINTF_1 ATTRIBUTE_PRINTF(1, 2)
#define ATTRIBUTE_PRINTF_2 ATTRIBUTE_PRINTF(2, 3)
#define ATTRIBUTE_PRINTF_3 ATTRIBUTE_PRINTF(3, 4)
@@ -277,6 +290,21 @@ So instead we use the macro below and test it against specific values. */
#define ATTRIBUTE_PRINTF_5 ATTRIBUTE_PRINTF(5, 6)
#endif /* ATTRIBUTE_PRINTF */
+/* Use ATTRIBUTE_NULL_PRINTF when the format specifier may be NULL. A
+ NULL format specifier was allowed as of gcc 3.3. */
+#ifndef ATTRIBUTE_NULL_PRINTF
+# if (GCC_VERSION >= 3003)
+# define ATTRIBUTE_NULL_PRINTF(m, n) __attribute__ ((__format__ (__printf__, m, n)))
+# else
+# define ATTRIBUTE_NULL_PRINTF(m, n)
+# endif /* GNUC >= 3.3 */
+# define ATTRIBUTE_NULL_PRINTF_1 ATTRIBUTE_NULL_PRINTF(1, 2)
+# define ATTRIBUTE_NULL_PRINTF_2 ATTRIBUTE_NULL_PRINTF(2, 3)
+# define ATTRIBUTE_NULL_PRINTF_3 ATTRIBUTE_NULL_PRINTF(3, 4)
+# define ATTRIBUTE_NULL_PRINTF_4 ATTRIBUTE_NULL_PRINTF(4, 5)
+# define ATTRIBUTE_NULL_PRINTF_5 ATTRIBUTE_NULL_PRINTF(5, 6)
+#endif /* ATTRIBUTE_NULL_PRINTF */
+
/* We use __extension__ in some places to suppress -pedantic warnings
about GCC extensions. This feature didn't work properly before
gcc 2.8. */
@@ -284,15 +312,4 @@ So instead we use the macro below and test it against specific values. */
#define __extension__
#endif
-/* Bootstrap support: Adjust certain macros defined by Autoconf,
- which are only valid for the stage1 compiler. If we detect
- a modern version of GCC, we are probably in stage2 or beyond,
- so unconditionally reset the values. Note that const, inline,
- etc. have been dealt with above. */
-#if (GCC_VERSION >= 2007)
-# ifndef HAVE_LONG_DOUBLE
-# define HAVE_LONG_DOUBLE 1
-# endif
-#endif /* GCC >= 2.7 */
-
#endif /* ansidecl.h */
diff --git a/contrib/binutils/include/aout/ChangeLog b/contrib/binutils/include/aout/ChangeLog
index d215c59..148a020 100644
--- a/contrib/binutils/include/aout/ChangeLog
+++ b/contrib/binutils/include/aout/ChangeLog
@@ -1,3 +1,11 @@
+2004-01-06 Mark Kettenis <kettenis@gnu.org>
+
+ * stab.def: Add N_PATCH to DO definition.
+
+2003-03-06 Elias Athanasopoulos <elathan@phys.uoa.gr>
+
+ * aout64.h (BYTES_IN_WORD): Define if necessary.
+
2001-09-18 Alan Modra <amodra@bigpond.net.au>
* aout64.h: Formatting fixes.
@@ -6,7 +14,7 @@
* hp300hpux.h: Formatting fixes.
(N_DATADDR): Avoid negative unsigned warning.
-Mon Apr 3 13:29:08 2000 Hans-Peter Nilsson <hp@axis.com>
+2000-04-03 Hans-Peter Nilsson <hp@axis.com>
* aout64.h (RELOC_EXT_BITS_EXTERN_BIG): Wrap definition in #ifndef.
(RELOC_EXT_BITS_EXTERN_LITTLE): Ditto.
@@ -20,97 +28,97 @@ Mon Apr 3 13:29:08 2000 Hans-Peter Nilsson <hp@axis.com>
* aout64.h (N_SHARED_LIB): Define as 0 if TEXT_START_ADDR is
defined as 0.
-Sun Jun 28 11:33:48 1998 Peter Schauer <pes@regent.e-technik.tu-muenchen.de>
+1998-06-28 Peter Schauer <pes@regent.e-technik.tu-muenchen.de>
* stab.def: Add N_ALIAS from SunPro F77.
-Mon Mar 11 12:15:52 1996 Ian Lance Taylor <ian@cygnus.com>
+1996-03-11 Ian Lance Taylor <ian@cygnus.com>
* stab.def: Use __define_stab_duplicate rather than __define_stab
for duplicate entries N_BROWS and N_MOD2.
* stab_gnu.h (__define_stab_duplicate): Define before including
stab.def.
-Fri Oct 27 17:47:16 1995 Niklas Hallqvist <niklas@appli.se>
+1995-10-27 Niklas Hallqvist <niklas@appli.se>
* aout64.h, host.h, hp300hpux.h, sun4.h: Changed PAGE_SIZE to
TARGET_PAGE_SIZE.
-Tue Sep 12 12:07:02 1995 Ian Lance Taylor <ian@cygnus.com>
+1995-09-12 Ian Lance Taylor <ian@cygnus.com>
* sun4.h (struct internal_sun4_dynamic_link): Change all fields
from long to unsigned long.
-Wed Jul 12 00:15:13 1995 Ken Raeburn <raeburn@kr-pc.cygnus.com>
+1995-07-12 Ken Raeburn <raeburn@kr-pc.cygnus.com>
* sun4.h (PAGE_SIZE): Undefine before defining.
-Sun Sep 04 17:58:10 1994 Richard Earnshaw (rwe@pegasus.esprit.ec.org)
+1994-09-04 Richard Earnshaw (rwe@pegasus.esprit.ec.org)
* aout64.h: Only define QMAGIC if it isn't already defined.
-Thu Jun 16 14:22:55 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+1994-06-16 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
* aout64.h (BMAGIC): Define.
-Sat Jun 11 16:16:09 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+1994-06-11 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
Add weak symbols as an extension to a.out.
* aout64.h (N_WEAKU, N_WEAKA, N_WEAKT, N_WEAKD, N_WEAKB): Define.
* stab.def: Update symbol value table.
-Thu Jun 2 17:13:38 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+1994-06-02 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
* sun4.h (EXTERNAL_SUN4_DYNAMIC_DEBUGGER_SIZE): Correct from 28 to
24. Fix up ld_got comment.
-Wed Mar 30 00:31:49 1994 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
+1994-03-30 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
* dynix3.h: Cleanup, adapt to current bfd version.
-Sat Feb 26 10:25:53 1994 Ian Lance Taylor (ian@cygnus.com)
+1994-02-26 Ian Lance Taylor (ian@cygnus.com)
* aout64.h: Add casts to avoid warnings from SVR4 cc.
-Fri Feb 11 12:56:04 1994 Stan Shebs (shebs@andros.cygnus.com)
+1994-02-11 Stan Shebs (shebs@andros.cygnus.com)
* ar.h (ARMAG, ARMAGB, ARFMAG): Change '\n' to '\012', for greater
portability.
-Fri Jan 21 00:59:06 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+1994-01-21 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
* sun4.h: Added information about SunOS shared libraries.
-Fri Jan 7 08:20:13 1994 Jim Kingdon (kingdon@deneb.cygnus.com)
+1994-01-07 Jim Kingdon (kingdon@deneb.cygnus.com)
* aout64.h (N_TXTADDR): Add comment regarding OMAGIC and NMAGIC.
-Sat Dec 25 14:55:41 1993 Jim Kingdon (kingdon@lioth.cygnus.com)
+1993-12-25 Jim Kingdon (kingdon@lioth.cygnus.com)
* aout64.h (N_DATOFF): Don't pad (revert change of 8 Jul 1993).
-Tue Nov 16 15:43:46 1993 Jim Kingdon (kingdon@lioth.cygnus.com)
+1993-11-16 Jim Kingdon (kingdon@lioth.cygnus.com)
* aout64.h: New macros ZMAGIC_DISK_BLOCK_SIZE and N_DISK_BLOCK_SIZE
for Linux ZMAGIC.
(N_TXTOFF, N_DATOFF): Use them.
-Thu Nov 4 00:33:48 1993 Ken Raeburn (raeburn@kr-pc.cygnus.com)
+1993-11-04 Ken Raeburn (raeburn@kr-pc.cygnus.com)
* aout64.h (RELOC_STD_BITS_RELATIVE_LITTLE): Fixed value to match
sun3 system; used to overlap other fields.
(RELOC_STD_BITS_JMPTABLE_LITTLE): Likewise.
-Wed Nov 3 13:48:27 1993 David J. Mackenzie (djm@thepub.cygnus.com)
+1993-11-03 David J. Mackenzie (djm@thepub.cygnus.com)
* aout64.h (RELOC_STD_BITS_BASEREL_LITTLE): Make it 0x10 (Ken's
suggestion) to avoid conflict with RELOC_STD_BITS_EXTERN_LITTLE.
-Fri Oct 29 15:09:52 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+1993-10-29 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
* hp300hpux.h (N_SHARED_LIB): Define to be 0.
-Mon Sep 13 21:00:56 1993 John Gilmore (gnu@cygnus.com)
+1993-09-13 John Gilmore (gnu@cygnus.com)
* ar.h (ARMAP_TIME_OFFSET): Add and describe.
@@ -118,30 +126,30 @@ Mon Aug 23 Sean Fagan (sef@cygnus.com)
* aout64.h [ARCH_SIZE != 64]: Allow N_BADMAG to be overridden.
-Mon Aug 16 14:30:14 1993 Jim Kingdon (kingdon@lioth.cygnus.com)
+1993-08-16 Jim Kingdon (kingdon@lioth.cygnus.com)
* stab_gnu.h: Include aout/stab.def not just stab.def.
-Sun Jul 18 21:41:47 1993 Jim Kingdon (kingdon@rtl.cygnus.com)
+1993-07-18 Jim Kingdon (kingdon@rtl.cygnus.com)
* dynix3.h: New, for symmetry running dynix.
-Thu Jul 8 12:52:22 1993 Jim Kingdon (kingdon@lioth.cygnus.com)
+1993-07-08 Jim Kingdon (kingdon@lioth.cygnus.com)
* aout64.h (N_BADMAG): Recognize QMAGIC.
N_TXTOFF, N_TXTADDR, N_TXTSIZE: Special code for QMAGIC.
N_DATOFF: Pad text size if we need to.
-Fri Jun 18 19:19:38 1993 Jim Kingdon (kingdon@lioth.cygnus.com)
+1993-06-18 Jim Kingdon (kingdon@lioth.cygnus.com)
* stab.def (N_ECOML): Fix comment.
-Mon May 31 09:21:30 1993 Jim Kingdon (kingdon@cygnus.com)
+1993-05-31 Jim Kingdon (kingdon@cygnus.com)
* stab.def: Remove Solaris information on N_FUN stabstring grammar;
I've transferred it to gdb/doc/stabs.texinfo, where it belongs.
-Mon May 10 05:48:43 1993 Ken Raeburn (raeburn@kr-pc.cygnus.com)
+1993-05-10 Ken Raeburn (raeburn@kr-pc.cygnus.com)
* hp300hpux.h: Patch from Glenn Engel for linker problem and
compatibility fix:
@@ -151,11 +159,11 @@ Mon May 10 05:48:43 1993 Ken Raeburn (raeburn@kr-pc.cygnus.com)
(_N_BADMAG): Adjusted.
(N_HEADER_IN_TEXT, N_DATADDR): New macros.
-Thu Apr 29 12:07:37 1993 Ken Raeburn (raeburn@deneb.cygnus.com)
+1993-04-29 Ken Raeburn (raeburn@deneb.cygnus.com)
* hp300hpux.h: New file from Glenn Engel, glenne@lsid.hp.com.
-Tue Apr 27 05:51:04 1993 Ken Raeburn (raeburn@kr-pc.cygnus.com)
+1993-04-27 Ken Raeburn (raeburn@kr-pc.cygnus.com)
* aout64.h (struct external_exec, *MAGIC, N_BADMAG): Don't define
if `external_exec' is already defined as a macro.
@@ -164,35 +172,35 @@ Tue Apr 27 05:51:04 1993 Ken Raeburn (raeburn@kr-pc.cygnus.com)
(struct external_nlist, EXTERNAL_NLIST_SIZE): Don't define if
`external_nlist' is already defined as a macro.
-Sat Aug 15 04:23:02 1992 John Gilmore (gnu@cygnus.com)
+1992-08-15 John Gilmore (gnu@cygnus.com)
* adobe.h: Add description of a.out.adobe format.
-Fri Jul 3 00:36:52 1992 John Gilmore (gnu at cygnus.com)
+1992-07-03 John Gilmore (gnu at cygnus.com)
* stab.def: Update more Solaris definitions.
* stab_gnu.h: Add N_SO language types, and Solaris basic float types.
-Sun Jun 14 10:53:53 1992 John Gilmore (gnu at cygnus.com)
+1992-06-14 John Gilmore (gnu at cygnus.com)
* stab.def: Update descriptions of Solaris-2 stabs; add N_UNDF.
-Thu Jun 11 01:12:07 1992 John Gilmore (gnu at cygnus.com)
+1992-06-11 John Gilmore (gnu at cygnus.com)
* stab.def: Add N_OBJ and N_OPT from Solaris-2.
-Thu Jan 30 18:12:44 1992 John Gilmore (gnu at cygnus.com)
+1992-01-30 John Gilmore (gnu at cygnus.com)
* aout64.h: N_TXTSIZE needs some more parentheses.
I don't trust C precedence.
-Wed Dec 18 14:32:01 1991 Per Bothner (bothner at cygnus.com)
+1991-12-18 Per Bothner (bothner at cygnus.com)
* aout64.h: Move common sunos-specific test
to recognize shared libraries into new macro N_SHARED_LIB.
Use it to simplify & reformat N_TXTADDR, N_TXTOFF, N_TXTSIZE.
-Sat Nov 30 20:34:52 1991 Steve Chamberlain (sac at rtl.cygnus.com)
+1991-11-30 Steve Chamberlain (sac at rtl.cygnus.com)
* aout64.h, ar.h, encap.h, host.h, hp.h, ranlib.h, reloc.h,
stab.def, stab_gnu.h, sun4.h: All moved from the devo/include
diff --git a/contrib/binutils/include/aout/aout64.h b/contrib/binutils/include/aout/aout64.h
index bc96d2a..4843410 100644
--- a/contrib/binutils/include/aout/aout64.h
+++ b/contrib/binutils/include/aout/aout64.h
@@ -1,6 +1,6 @@
/* `a.out' object-file definitions, including extensions to 64-bit fields
- Copyright 2001 Free Software Foundation, Inc.
+ Copyright 2001, 2003 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -19,27 +19,31 @@
#ifndef __A_OUT_64_H__
#define __A_OUT_64_H__
-/* This is the layout on disk of the 32-bit or 64-bit exec header. */
+#ifndef BYTES_IN_WORD
+#define BYTES_IN_WORD 4
+#endif
+
+/* This is the layout on disk of the 32-bit or 64-bit exec header. */
#ifndef external_exec
struct external_exec
{
- bfd_byte e_info[4]; /* magic number and stuff */
- bfd_byte e_text[BYTES_IN_WORD]; /* length of text section in bytes */
- bfd_byte e_data[BYTES_IN_WORD]; /* length of data section in bytes */
- bfd_byte e_bss[BYTES_IN_WORD]; /* length of bss area in bytes */
- bfd_byte e_syms[BYTES_IN_WORD]; /* length of symbol table in bytes */
- bfd_byte e_entry[BYTES_IN_WORD]; /* start address */
- bfd_byte e_trsize[BYTES_IN_WORD]; /* length of text relocation info */
- bfd_byte e_drsize[BYTES_IN_WORD]; /* length of data relocation info */
+ bfd_byte e_info[4]; /* Magic number and stuff. */
+ bfd_byte e_text[BYTES_IN_WORD]; /* Length of text section in bytes. */
+ bfd_byte e_data[BYTES_IN_WORD]; /* Length of data section in bytes. */
+ bfd_byte e_bss[BYTES_IN_WORD]; /* Length of bss area in bytes. */
+ bfd_byte e_syms[BYTES_IN_WORD]; /* Length of symbol table in bytes. */
+ bfd_byte e_entry[BYTES_IN_WORD]; /* Start address. */
+ bfd_byte e_trsize[BYTES_IN_WORD]; /* Length of text relocation info. */
+ bfd_byte e_drsize[BYTES_IN_WORD]; /* Length of data relocation info. */
};
#define EXEC_BYTES_SIZE (4 + BYTES_IN_WORD * 7)
-/* Magic numbers for a.out files */
+/* Magic numbers for a.out files. */
#if ARCH_SIZE==64
-#define OMAGIC 0x1001 /* Code indicating object file */
+#define OMAGIC 0x1001 /* Code indicating object file. */
#define ZMAGIC 0x1002 /* Code indicating demand-paged executable. */
#define NMAGIC 0x1003 /* Code indicating pure executable. */
@@ -49,7 +53,7 @@ struct external_exec
&& N_MAGIC(x) != NMAGIC \
&& N_MAGIC(x) != ZMAGIC)
#else
-#define OMAGIC 0407 /* ...object file or impure executable. */
+#define OMAGIC 0407 /* Object file or impure executable. */
#define NMAGIC 0410 /* Code indicating pure executable. */
#define ZMAGIC 0413 /* Code indicating demand-paged executable. */
#define BMAGIC 0415 /* Used by a b.out object. */
@@ -125,8 +129,7 @@ struct external_exec
* QMAGIC is always like a ZMAGIC for which N_HEADER_IN_TEXT is true,
and for which the starting address is TARGET_PAGE_SIZE (or should this be
- SEGMENT_SIZE?) (TEXT_START_ADDR only applies to ZMAGIC, not to QMAGIC).
- */
+ SEGMENT_SIZE?) (TEXT_START_ADDR only applies to ZMAGIC, not to QMAGIC). */
/* This macro is only relevant for ZMAGIC files; QMAGIC always has the header
in the text. */
@@ -152,12 +155,12 @@ struct external_exec
#ifndef N_TXTADDR
#define N_TXTADDR(x) \
- (/* The address of a QMAGIC file is always one page in, */ \
- /* with the header in the text. */ \
+ (/* The address of a QMAGIC file is always one page in, \
+ with the header in the text. */ \
N_IS_QMAGIC (x) \
? (bfd_vma) TARGET_PAGE_SIZE + EXEC_BYTES_SIZE \
: (N_MAGIC (x) != ZMAGIC \
- ? (bfd_vma) 0 /* object file or NMAGIC */ \
+ ? (bfd_vma) 0 /* Object file or NMAGIC. */ \
: (N_SHARED_LIB (x) \
? (bfd_vma) 0 \
: (N_HEADER_IN_TEXT (x) \
@@ -187,8 +190,8 @@ struct external_exec
: (N_SHARED_LIB (x) \
? 0 \
: (N_HEADER_IN_TEXT (x) \
- ? EXEC_BYTES_SIZE /* no padding */ \
- : ZMAGIC_DISK_BLOCK_SIZE /* a page of padding */)))
+ ? EXEC_BYTES_SIZE /* No padding. */ \
+ : ZMAGIC_DISK_BLOCK_SIZE /* A page of padding. */)))
#endif
/* Size of the text section. It's always as stated, except that we
offset it to `undo' the adjustment to N_TXTADDR and N_TXTOFF
@@ -203,12 +206,12 @@ struct external_exec
: ((N_MAGIC (x) != ZMAGIC || N_SHARED_LIB (x)) \
? (x).a_text \
: (N_HEADER_IN_TEXT (x) \
- ? (x).a_text - EXEC_BYTES_SIZE /* no padding */ \
- : (x).a_text /* a page of padding */ )))
+ ? (x).a_text - EXEC_BYTES_SIZE /* No padding. */ \
+ : (x).a_text /* A page of padding. */ )))
#endif
/* The address of the data segment in virtual memory.
It is the text segment address, plus text segment size, rounded
- up to a N_SEGSIZE boundary for pure or pageable files. */
+ up to a N_SEGSIZE boundary for pure or pageable files. */
#ifndef N_DATADDR
#define N_DATADDR(x) \
(N_MAGIC (x) == OMAGIC \
@@ -235,57 +238,59 @@ struct external_exec
for NMAGIC. */
#ifndef N_DATOFF
-#define N_DATOFF(x) ( N_TXTOFF (x) + N_TXTSIZE (x) )
+#define N_DATOFF(x) (N_TXTOFF (x) + N_TXTSIZE (x))
#endif
#ifndef N_TRELOFF
-#define N_TRELOFF(x) ( N_DATOFF (x) + (x).a_data )
+#define N_TRELOFF(x) (N_DATOFF (x) + (x).a_data)
#endif
#ifndef N_DRELOFF
-#define N_DRELOFF(x) ( N_TRELOFF (x) + (x).a_trsize )
+#define N_DRELOFF(x) (N_TRELOFF (x) + (x).a_trsize)
#endif
#ifndef N_SYMOFF
-#define N_SYMOFF(x) ( N_DRELOFF (x) + (x).a_drsize )
+#define N_SYMOFF(x) (N_DRELOFF (x) + (x).a_drsize)
#endif
#ifndef N_STROFF
-#define N_STROFF(x) ( N_SYMOFF (x) + (x).a_syms )
+#define N_STROFF(x) (N_SYMOFF (x) + (x).a_syms)
#endif
/* Symbols */
#ifndef external_nlist
-struct external_nlist {
- bfd_byte e_strx[BYTES_IN_WORD]; /* index into string table of name */
- bfd_byte e_type[1]; /* type of symbol */
- bfd_byte e_other[1]; /* misc info (usually empty) */
- bfd_byte e_desc[2]; /* description field */
- bfd_byte e_value[BYTES_IN_WORD]; /* value of symbol */
+struct external_nlist
+{
+ bfd_byte e_strx[BYTES_IN_WORD]; /* Index into string table of name. */
+ bfd_byte e_type[1]; /* Type of symbol. */
+ bfd_byte e_other[1]; /* Misc info (usually empty). */
+ bfd_byte e_desc[2]; /* Description field. */
+ bfd_byte e_value[BYTES_IN_WORD]; /* Value of symbol. */
};
#define EXTERNAL_NLIST_SIZE (BYTES_IN_WORD+4+BYTES_IN_WORD)
#endif
-struct internal_nlist {
- unsigned long n_strx; /* index into string table of name */
- unsigned char n_type; /* type of symbol */
- unsigned char n_other; /* misc info (usually empty) */
- unsigned short n_desc; /* description field */
- bfd_vma n_value; /* value of symbol */
+struct internal_nlist
+{
+ unsigned long n_strx; /* Index into string table of name. */
+ unsigned char n_type; /* Type of symbol. */
+ unsigned char n_other; /* Misc info (usually empty). */
+ unsigned short n_desc; /* Description field. */
+ bfd_vma n_value; /* Value of symbol. */
};
/* The n_type field is the symbol type, containing: */
-#define N_UNDF 0 /* Undefined symbol */
-#define N_ABS 2 /* Absolute symbol -- defined at particular addr */
-#define N_TEXT 4 /* Text sym -- defined at offset in text seg */
-#define N_DATA 6 /* Data sym -- defined at offset in data seg */
-#define N_BSS 8 /* BSS sym -- defined at offset in zero'd seg */
-#define N_COMM 0x12 /* Common symbol (visible after shared lib dynlink) */
-#define N_FN 0x1f /* File name of .o file */
-#define N_FN_SEQ 0x0C /* N_FN from Sequent compilers (sigh) */
+#define N_UNDF 0 /* Undefined symbol. */
+#define N_ABS 2 /* Absolute symbol -- defined at particular addr. */
+#define N_TEXT 4 /* Text sym -- defined at offset in text seg. */
+#define N_DATA 6 /* Data sym -- defined at offset in data seg. */
+#define N_BSS 8 /* BSS sym -- defined at offset in zero'd seg. */
+#define N_COMM 0x12 /* Common symbol (visible after shared lib dynlink). */
+#define N_FN 0x1f /* File name of .o file. */
+#define N_FN_SEQ 0x0C /* N_FN from Sequent compilers (sigh). */
/* Note: N_EXT can only be usefully OR-ed with N_UNDF, N_ABS, N_TEXT,
N_DATA, or N_BSS. When the low-order bit of other types is set,
(e.g. N_WARNING versus N_FN), they are two different types. */
-#define N_EXT 1 /* External symbol (as opposed to local-to-this-file) */
+#define N_EXT 1 /* External symbol (as opposed to local-to-this-file). */
#define N_TYPE 0x1e
-#define N_STAB 0xe0 /* If any of these bits are on, it's a debug symbol */
+#define N_STAB 0xe0 /* If any of these bits are on, it's a debug symbol. */
#define N_INDR 0x0a
@@ -301,10 +306,10 @@ struct internal_nlist {
in that it can satisfy undefined external references. */
/* These appear as input to LD, in a .o file. */
-#define N_SETA 0x14 /* Absolute set element symbol */
-#define N_SETT 0x16 /* Text set element symbol */
-#define N_SETD 0x18 /* Data set element symbol */
-#define N_SETB 0x1A /* Bss set element symbol */
+#define N_SETA 0x14 /* Absolute set element symbol. */
+#define N_SETT 0x16 /* Text set element symbol. */
+#define N_SETD 0x18 /* Data set element symbol. */
+#define N_SETB 0x1A /* Bss set element symbol. */
/* This is output from LD. */
#define N_SETV 0x1C /* Pointer to set vector in data area. */
@@ -335,18 +340,18 @@ struct internal_nlist {
instructions. Eg, on the 68k, each move instruction can reference
the target with a displacement of 16 or 32 bits. On the sparc, move
instructions use an offset of 14 bits, so the offset is stored in
- the reloc field, and the data in the section is ignored.
-*/
+ the reloc field, and the data in the section is ignored. */
/* This structure describes a single relocation to be performed.
The text-relocation section of the file is a vector of these structures,
all of which apply to the text section.
Likewise, the data-relocation section applies to the data section. */
-struct reloc_std_external {
- bfd_byte r_address[BYTES_IN_WORD]; /* offset of of data to relocate */
- bfd_byte r_index[3]; /* symbol table index of symbol */
- bfd_byte r_type[1]; /* relocation type */
+struct reloc_std_external
+{
+ bfd_byte r_address[BYTES_IN_WORD]; /* Offset of of data to relocate. */
+ bfd_byte r_index[3]; /* Symbol table index of symbol. */
+ bfd_byte r_type[1]; /* Relocation type. */
};
#define RELOC_STD_BITS_PCREL_BIG ((unsigned int) 0x80)
@@ -369,7 +374,7 @@ struct reloc_std_external {
#define RELOC_STD_BITS_RELATIVE_BIG ((unsigned int) 0x02)
#define RELOC_STD_BITS_RELATIVE_LITTLE ((unsigned int) 0x40)
-#define RELOC_STD_SIZE (BYTES_IN_WORD + 3 + 1) /* Bytes per relocation entry */
+#define RELOC_STD_SIZE (BYTES_IN_WORD + 3 + 1) /* Bytes per relocation entry. */
struct reloc_std_internal
{
@@ -392,21 +397,22 @@ struct reloc_std_internal
unsigned int r_extern:1;
/* The next three bits are for SunOS shared libraries, and seem to
be undocumented. */
- unsigned int r_baserel:1; /* Linkage table relative */
- unsigned int r_jmptable:1; /* pc-relative to jump table */
- unsigned int r_relative:1; /* "relative relocation" */
+ unsigned int r_baserel:1; /* Linkage table relative. */
+ unsigned int r_jmptable:1; /* pc-relative to jump table. */
+ unsigned int r_relative:1; /* "relative relocation". */
/* unused */
- unsigned int r_pad:1; /* Padding -- set to zero */
+ unsigned int r_pad:1; /* Padding -- set to zero. */
};
-/* EXTENDED RELOCS */
+/* EXTENDED RELOCS. */
-struct reloc_ext_external {
- bfd_byte r_address[BYTES_IN_WORD]; /* offset of of data to relocate */
- bfd_byte r_index[3]; /* symbol table index of symbol */
- bfd_byte r_type[1]; /* relocation type */
- bfd_byte r_addend[BYTES_IN_WORD]; /* datum addend */
+struct reloc_ext_external
+{
+ bfd_byte r_address[BYTES_IN_WORD]; /* Offset of of data to relocate. */
+ bfd_byte r_index[3]; /* Symbol table index of symbol. */
+ bfd_byte r_type[1]; /* Relocation type. */
+ bfd_byte r_addend[BYTES_IN_WORD]; /* Datum addend. */
};
#ifndef RELOC_EXT_BITS_EXTERN_BIG
@@ -433,20 +439,20 @@ struct reloc_ext_external {
#define RELOC_EXT_BITS_TYPE_SH_LITTLE 3
#endif
-/* Bytes per relocation entry */
+/* Bytes per relocation entry. */
#define RELOC_EXT_SIZE (BYTES_IN_WORD + 3 + 1 + BYTES_IN_WORD)
enum reloc_type
{
- /* simple relocations */
+ /* Simple relocations. */
RELOC_8, /* data[0:7] = addend + sv */
RELOC_16, /* data[0:15] = addend + sv */
RELOC_32, /* data[0:31] = addend + sv */
- /* pc-rel displacement */
+ /* PC-rel displacement. */
RELOC_DISP8, /* data[0:7] = addend - pc + sv */
RELOC_DISP16, /* data[0:15] = addend - pc + sv */
RELOC_DISP32, /* data[0:31] = addend - pc + sv */
- /* Special */
+ /* Special. */
RELOC_WDISP30, /* data[0:29] = (addend + sv - pc)>>2 */
RELOC_WDISP22, /* data[0:21] = (addend + sv - pc)>>2 */
RELOC_HI22, /* data[0:21] = (addend + sv)>>10 */
@@ -455,16 +461,16 @@ enum reloc_type
RELOC_LO10, /* data[0:9] = (addend + sv) */
RELOC_SFA_BASE,
RELOC_SFA_OFF13,
- /* P.I.C. (base-relative) */
+ /* P.I.C. (base-relative). */
RELOC_BASE10, /* Not sure - maybe we can do this the */
RELOC_BASE13, /* right way now */
RELOC_BASE22,
- /* for some sort of pc-rel P.I.C. (?) */
+ /* For some sort of pc-rel P.I.C. (?) */
RELOC_PC10,
RELOC_PC22,
- /* P.I.C. jump table */
+ /* P.I.C. jump table. */
RELOC_JMP_TBL,
- /* reputedly for shared libraries somehow */
+ /* Reputedly for shared libraries somehow. */
RELOC_SEGOFF16,
RELOC_GLOB_DAT,
RELOC_JMP_SLOT,
@@ -476,13 +482,12 @@ enum reloc_type
RELOC_HHI22, /* data[0:21] = (addend + sv) >> 42 */
RELOC_HLO10, /* data[0:9] = (addend + sv) >> 32 */
- /* 29K relocation types */
+ /* 29K relocation types. */
RELOC_JUMPTARG,
RELOC_CONST,
RELOC_CONSTH,
- /* All the new ones I can think of, for sparc v9 */
-
+ /* All the new ones I can think of, for sparc v9. */
RELOC_64, /* data[0:63] = addend + sv */
RELOC_DISP64, /* data[0:63] = addend - pc + sv */
RELOC_WDISP21, /* data[0:20] = (addend + sv - pc)>>2 */
@@ -492,25 +497,23 @@ enum reloc_type
What are the other ones,
Since this is a clean slate, can we throw away the ones we dont
understand ? Should we sort the values ? What about using a
- microcode format like the 68k ?
- */
+ microcode format like the 68k ? */
NO_RELOC
};
-struct reloc_internal {
- bfd_vma r_address; /* offset of of data to relocate */
- long r_index; /* symbol table index of symbol */
- enum reloc_type r_type; /* relocation type */
- bfd_vma r_addend; /* datum addend */
+struct reloc_internal
+{
+ bfd_vma r_address; /* Offset of of data to relocate. */
+ long r_index; /* Symbol table index of symbol. */
+ enum reloc_type r_type; /* Relocation type. */
+ bfd_vma r_addend; /* Datum addend. */
};
/* Q.
Should the length of the string table be 4 bytes or 8 bytes ?
Q.
- What about archive indexes ?
-
- */
+ What about archive indexes ? */
#endif /* __A_OUT_64_H__ */
diff --git a/contrib/binutils/include/aout/stab.def b/contrib/binutils/include/aout/stab.def
index 67bde35..8188b84 100644
--- a/contrib/binutils/include/aout/stab.def
+++ b/contrib/binutils/include/aout/stab.def
@@ -1,20 +1,20 @@
/* Table of DBX symbol codes for the GNU system.
- Copyright 1988, 1991, 1992, 1993, 1994, 1996, 1998
+ Copyright 1988, 1991, 1992, 1993, 1994, 1996, 1998, 2004
Free Software Foundation, Inc.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or
+ modify it under the terms of the GNU General Public License as
+ published by the Free Software Foundation; either version 2 of the
+ License, or (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* New stab from Solaris 2. This uses an n_type of 0, which in a.out files
overlaps the N_UNDF used for ordinary symbols. In ELF files, the
@@ -181,6 +181,9 @@ __define_stab (N_EXCL, 0xc2, "EXCL")
/* Modula-2 scope information. Can someone say what info it contains? */
__define_stab (N_SCOPE, 0xc4, "SCOPE")
+/* Solaris2: Patch Run Time Checker. */
+__define_stab (N_PATCH, 0xd0, "PATCH")
+
/* End of a lexical block. Desc matches the N_LBRAC's desc.
The value is the address of the end of the text for the block.
On Solaris2, the value is relative to the start of the current function. */
@@ -256,7 +259,7 @@ __define_stab (N_LENG, 0xfe, "LENG")
| B8 | BA | BC | BE |
| C0 LBRAC | C2 EXCL | C4 SCOPE | C6 |
| C8 | CA | CC | CE |
- | D0 | D2 | D4 | D6 |
+ | D0 PATCH | D2 | D4 | D6 |
| D8 | DA | DC | DE |
| E0 RBRAC | E2 BCOMM | E4 ECOMM | E6 |
| E8 ECOML | EA WITH | EC | EE |
diff --git a/contrib/binutils/include/bfdlink.h b/contrib/binutils/include/bfdlink.h
index d83ff94..cc2043e 100644
--- a/contrib/binutils/include/bfdlink.h
+++ b/contrib/binutils/include/bfdlink.h
@@ -1,6 +1,6 @@
/* bfdlink.h -- header file for BFD link routines
- Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2002
- Free Software Foundation, Inc.
+ Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2002, 2003,
+ 2004 Free Software Foundation, Inc.
Written by Steve Chamberlain and Ian Lance Taylor, Cygnus Support.
This file is part of BFD, the Binary File Descriptor library.
@@ -66,6 +66,14 @@ enum bfd_link_hash_type
bfd_link_hash_warning /* Like indirect, but warn if referenced. */
};
+enum bfd_link_common_skip_ar_aymbols
+{
+ bfd_link_common_skip_none,
+ bfd_link_common_skip_text,
+ bfd_link_common_skip_data,
+ bfd_link_common_skip_all
+};
+
/* The linking routines use a hash table which uses this structure for
its elements. */
@@ -73,6 +81,7 @@ struct bfd_link_hash_entry
{
/* Base hash table entry structure. */
struct bfd_hash_entry root;
+
/* Type of this entry. */
enum bfd_link_hash_type type;
@@ -94,7 +103,8 @@ struct bfd_link_hash_entry
symbol is undefined and becomes defined, this field will
automatically be non-NULL since the symbol will have been on the
undefined symbol list. */
- struct bfd_link_hash_entry *next;
+ struct bfd_link_hash_entry *und_next;
+
/* A union of information depending upon the type. */
union
{
@@ -120,14 +130,14 @@ struct bfd_link_hash_entry
struct
{
/* The linker needs to know three things about common
- symbols: the size, the alignment, and the section in
- which the symbol should be placed. We store the size
- here, and we allocate a small structure to hold the
- section and the alignment. The alignment is stored as a
- power of two. We don't store all the information
- directly because we don't want to increase the size of
- the union; this structure is a major space user in the
- linker. */
+ symbols: the size, the alignment, and the section in
+ which the symbol should be placed. We store the size
+ here, and we allocate a small structure to hold the
+ section and the alignment. The alignment is stored as a
+ power of two. We don't store all the information
+ directly because we don't want to increase the size of
+ the union; this structure is a major space user in the
+ linker. */
bfd_size_type size; /* Common symbol size. */
struct bfd_link_hash_common_entry
{
@@ -155,34 +165,34 @@ struct bfd_link_hash_table
struct bfd_link_hash_entry *undefs;
/* Entries are added to the tail of the undefs list. */
struct bfd_link_hash_entry *undefs_tail;
- /* The type of the ink hash table. */
+ /* The type of the link hash table. */
enum bfd_link_hash_table_type type;
};
-/* Look up an entry in a link hash table. If FOLLOW is true, this
+/* Look up an entry in a link hash table. If FOLLOW is TRUE, this
follows bfd_link_hash_indirect and bfd_link_hash_warning links to
the real symbol. */
extern struct bfd_link_hash_entry *bfd_link_hash_lookup
- PARAMS ((struct bfd_link_hash_table *, const char *, boolean create,
- boolean copy, boolean follow));
+ (struct bfd_link_hash_table *, const char *, bfd_boolean create,
+ bfd_boolean copy, bfd_boolean follow);
/* Look up an entry in the main linker hash table if the symbol might
be wrapped. This should only be used for references to an
undefined symbol, not for definitions of a symbol. */
extern struct bfd_link_hash_entry *bfd_wrapped_link_hash_lookup
- PARAMS ((bfd *, struct bfd_link_info *, const char *, boolean, boolean,
- boolean));
+ (bfd *, struct bfd_link_info *, const char *, bfd_boolean,
+ bfd_boolean, bfd_boolean);
/* Traverse a link hash table. */
extern void bfd_link_hash_traverse
- PARAMS ((struct bfd_link_hash_table *,
- boolean (*) (struct bfd_link_hash_entry *, PTR),
- PTR));
+ (struct bfd_link_hash_table *,
+ bfd_boolean (*) (struct bfd_link_hash_entry *, void *),
+ void *);
/* Add an entry to the undefs list. */
extern void bfd_link_add_undef
- PARAMS ((struct bfd_link_hash_table *, struct bfd_link_hash_entry *));
+ (struct bfd_link_hash_table *, struct bfd_link_hash_entry *);
struct bfd_sym_chain
{
@@ -190,72 +200,118 @@ struct bfd_sym_chain
const char *name;
};
+/* How to handle unresolved symbols.
+ There are four possibilities which are enumerated below: */
+enum report_method
+{
+ /* This is the initial value when then link_info structure is created.
+ It allows the various stages of the linker to determine whether they
+ allowed to set the value. */
+ RM_NOT_YET_SET = 0,
+ RM_IGNORE,
+ RM_GENERATE_WARNING,
+ RM_GENERATE_ERROR
+};
+
/* This structure holds all the information needed to communicate
between BFD and the linker when doing a link. */
struct bfd_link_info
{
- /* Function callbacks. */
- const struct bfd_link_callbacks *callbacks;
-
- /* true if BFD should generate a relocateable object file. */
- boolean relocateable;
+ /* TRUE if BFD should generate a relocatable object file. */
+ unsigned int relocatable: 1;
- /* true if BFD should generate relocation information in the final
+ /* TRUE if BFD should generate relocation information in the final
executable. */
- boolean emitrelocations;
+ unsigned int emitrelocations: 1;
- /* true if BFD should generate a "task linked" object file,
+ /* TRUE if BFD should generate a "task linked" object file,
similar to relocatable but also with globals converted to
statics. */
- boolean task_link;
+ unsigned int task_link: 1;
- /* true if BFD should generate a shared object. */
- boolean shared;
+ /* TRUE if BFD should generate a shared object. */
+ unsigned int shared: 1;
- /* true if BFD should pre-bind symbols in a shared object. */
- boolean symbolic;
+ /* TRUE if BFD should pre-bind symbols in a shared object. */
+ unsigned int symbolic: 1;
- /* true if BFD should export all symbols in the dynamic symbol table
+ /* TRUE if BFD should export all symbols in the dynamic symbol table
of an executable, rather than only those used. */
- boolean export_dynamic;
+ unsigned int export_dynamic: 1;
- /* true if shared objects should be linked directly, not shared. */
- boolean static_link;
+ /* TRUE if shared objects should be linked directly, not shared. */
+ unsigned int static_link: 1;
- /* true if the output file should be in a traditional format. This
+ /* TRUE if the output file should be in a traditional format. This
is equivalent to the setting of the BFD_TRADITIONAL_FORMAT flag
on the output file, but may be checked when reading the input
files. */
- boolean traditional_format;
+ unsigned int traditional_format: 1;
- /* true if we want to produced optimized output files. This might
+ /* TRUE if we want to produced optimized output files. This might
need much more time and therefore must be explicitly selected. */
- boolean optimize;
-
- /* true if BFD should generate errors for undefined symbols
- even if generating a shared object. */
- boolean no_undefined;
-
- /* true if BFD should allow undefined symbols in shared objects even
- when no_undefined is set to disallow undefined symbols. The net
- result will be that undefined symbols in regular objects will
- still trigger an error, but undefined symbols in shared objects
- will be ignored. The implementation of no_undefined makes the
- assumption that the runtime linker will choke on undefined
- symbols. However there is at least one system (BeOS) where
- undefined symbols in shared libraries is normal since the kernel
- patches them at load time to select which function is most
- appropriate for the current architecture. I.E. dynamically
- select an appropriate memset function. Apparently it is also
- normal for HPPA shared libraries to have undefined symbols. */
- boolean allow_shlib_undefined;
-
- /* true if ok to have multiple definition. */
- boolean allow_multiple_definition;
-
- /* true if ok to have version with no definition. */
- boolean allow_undefined_version;
+ unsigned int optimize: 1;
+
+ /* TRUE if ok to have multiple definition. */
+ unsigned int allow_multiple_definition: 1;
+
+ /* TRUE if ok to have version with no definition. */
+ unsigned int allow_undefined_version: 1;
+
+ /* TRUE if symbols should be retained in memory, FALSE if they
+ should be freed and reread. */
+ unsigned int keep_memory: 1;
+
+ /* TRUE if every symbol should be reported back via the notice
+ callback. */
+ unsigned int notice_all: 1;
+
+ /* TRUE if executable should not contain copy relocs.
+ Setting this true may result in a non-sharable text segment. */
+ unsigned int nocopyreloc: 1;
+
+ /* TRUE if the new ELF dynamic tags are enabled. */
+ unsigned int new_dtags: 1;
+
+ /* TRUE if non-PLT relocs should be merged into one reloc section
+ and sorted so that relocs against the same symbol come together. */
+ unsigned int combreloc: 1;
+
+ /* TRUE if .eh_frame_hdr section and PT_GNU_EH_FRAME ELF segment
+ should be created. */
+ unsigned int eh_frame_hdr: 1;
+
+ /* TRUE if global symbols in discarded sections should be stripped. */
+ unsigned int strip_discarded: 1;
+
+ /* TRUE if the final relax pass is needed. */
+ unsigned int need_relax_finalize: 1;
+
+ /* TRUE if generating a position independent executable. */
+ unsigned int pie: 1;
+
+ /* TRUE if generating an executable, position independent or not. */
+ unsigned int executable : 1;
+
+ /* TRUE if PT_GNU_STACK segment should be created with PF_R|PF_W|PF_X
+ flags. */
+ unsigned int execstack: 1;
+
+ /* TRUE if PT_GNU_STACK segment should be created with PF_R|PF_W
+ flags. */
+ unsigned int noexecstack: 1;
+
+ /* What to do with unresolved symbols in an object file.
+ When producing executables the default is GENERATE_ERROR.
+ When producing shared libraries the default is IGNORE. The
+ assumption with shared libraries is that the reference will be
+ resolved at load/execution time. */
+ enum report_method unresolved_syms_in_objects;
+
+ /* What to do with unresolved symbols in a shared library.
+ The same defaults apply. */
+ enum report_method unresolved_syms_in_shared_libs;
/* Which symbols to strip. */
enum bfd_link_strip strip;
@@ -263,24 +319,17 @@ struct bfd_link_info
/* Which local symbols to discard. */
enum bfd_link_discard discard;
- /* true if symbols should be retained in memory, false if they
- should be freed and reread. */
- boolean keep_memory;
-
- /* The list of input BFD's involved in the link. These are chained
- together via the link_next field. */
- bfd *input_bfds;
+ /* Criteria for skipping symbols when detemining
+ whether to include an object from an archive. */
+ enum bfd_link_common_skip_ar_aymbols common_skip_ar_aymbols;
- /* If a symbol should be created for each input BFD, this is section
- where those symbols should be placed. It must be a section in
- the output BFD. It may be NULL, in which case no such symbols
- will be created. This is to support CREATE_OBJECT_SYMBOLS in the
- linker command language. */
- asection *create_object_symbols_section;
+ /* Char that may appear as the first char of a symbol, but should be
+ skipped (like symbol_leading_char) when looking up symbols in
+ wrap_hash. Used by PowerPC Linux for 'dot' symbols. */
+ char wrap_char;
- /* List of global symbol names that are starting points for marking
- sections against garbage collection. */
- struct bfd_sym_chain *gc_sym_list;
+ /* Function callbacks. */
+ const struct bfd_link_callbacks *callbacks;
/* Hash table handled by BFD. */
struct bfd_link_hash_table *hash;
@@ -289,12 +338,8 @@ struct bfd_link_info
strip_some. */
struct bfd_hash_table *keep_hash;
- /* true if every symbol should be reported back via the notice
- callback. */
- boolean notice_all;
-
/* Hash table of symbols to report back via the notice callback. If
- this is NULL, and notice_all is false, then no symbols are
+ this is NULL, and notice_all is FALSE, then no symbols are
reported back. */
struct bfd_hash_table *notice_hash;
@@ -302,13 +347,23 @@ struct bfd_link_info
option). If this is NULL, no symbols are being wrapped. */
struct bfd_hash_table *wrap_hash;
- /* If a base output file is wanted, then this points to it */
- PTR base_file;
+ /* The list of input BFD's involved in the link. These are chained
+ together via the link_next field. */
+ bfd *input_bfds;
- /* If non-zero, specifies that branches which are problematic for the
- MPC860 C0 (or earlier) should be checked for and modified. It gives the
- number of bytes that should be checked at the end of each text page. */
- int mpc860c0;
+ /* If a symbol should be created for each input BFD, this is section
+ where those symbols should be placed. It must be a section in
+ the output BFD. It may be NULL, in which case no such symbols
+ will be created. This is to support CREATE_OBJECT_SYMBOLS in the
+ linker command language. */
+ asection *create_object_symbols_section;
+
+ /* List of global symbol names that are starting points for marking
+ sections against garbage collection. */
+ struct bfd_sym_chain *gc_sym_list;
+
+ /* If a base output file is wanted, then this points to it */
+ void *base_file;
/* The function to call when the executable or shared object is
loaded. */
@@ -318,40 +373,30 @@ struct bfd_link_info
unloaded. */
const char *fini_function;
- /* true if the new ELF dynamic tags are enabled. */
- boolean new_dtags;
-
- /* May be used to set DT_FLAGS for ELF. */
- bfd_vma flags;
-
- /* May be used to set DT_FLAGS_1 for ELF. */
- bfd_vma flags_1;
-
- /* Non-zero if auto-import thunks for DATA items in pei386 DLLs
+ /* Non-zero if auto-import thunks for DATA items in pei386 DLLs
should be generated/linked against. Set to 1 if this feature
is explicitly requested by the user, -1 if enabled by default. */
int pei386_auto_import;
- /* True if non-PLT relocs should be merged into one reloc section
- and sorted so that relocs against the same symbol come together. */
- boolean combreloc;
-
- /* True if executable should not contain copy relocs.
- Setting this true may result in a non-sharable text segment. */
- boolean nocopyreloc;
-
- /* True if .eh_frame_hdr section and PT_GNU_EH_FRAME ELF segment
- should be created. */
- boolean eh_frame_hdr;
+ /* Non-zero if runtime relocs for DATA items with non-zero addends
+ in pei386 DLLs should be generated. Set to 1 if this feature
+ is explicitly requested by the user, -1 if enabled by default. */
+ int pei386_runtime_pseudo_reloc;
/* How many spare .dynamic DT_NULL entries should be added? */
unsigned int spare_dynamic_tags;
+
+ /* May be used to set DT_FLAGS for ELF. */
+ bfd_vma flags;
+
+ /* May be used to set DT_FLAGS_1 for ELF. */
+ bfd_vma flags_1;
};
/* This structures holds a set of callback functions. These are
called by the BFD linker routines. The first argument to each
callback function is the bfd_link_info structure being used. Each
- function returns a boolean value. If the function returns false,
+ function returns a boolean value. If the function returns FALSE,
then the BFD function which called it will return with a failure
indication. */
@@ -361,23 +406,18 @@ struct bfd_link_callbacks
archive. ABFD is the archive element being added. NAME is the
name of the symbol which caused the archive element to be pulled
in. */
- boolean (*add_archive_element) PARAMS ((struct bfd_link_info *,
- bfd *abfd,
- const char *name));
+ bfd_boolean (*add_archive_element)
+ (struct bfd_link_info *, bfd *abfd, const char *name);
/* A function which is called when a symbol is found with multiple
definitions. NAME is the symbol which is defined multiple times.
OBFD is the old BFD, OSEC is the old section, OVAL is the old
value, NBFD is the new BFD, NSEC is the new section, and NVAL is
the new value. OBFD may be NULL. OSEC and NSEC may be
bfd_com_section or bfd_ind_section. */
- boolean (*multiple_definition) PARAMS ((struct bfd_link_info *,
- const char *name,
- bfd *obfd,
- asection *osec,
- bfd_vma oval,
- bfd *nbfd,
- asection *nsec,
- bfd_vma nval));
+ bfd_boolean (*multiple_definition)
+ (struct bfd_link_info *, const char *name,
+ bfd *obfd, asection *osec, bfd_vma oval,
+ bfd *nbfd, asection *nsec, bfd_vma nval);
/* A function which is called when a common symbol is defined
multiple times. NAME is the symbol appearing multiple times.
OBFD is the BFD of the existing symbol; it may be NULL if this is
@@ -389,34 +429,28 @@ struct bfd_link_callbacks
symbol, one of bfd_link_hash_defined, bfd_link_hash_common, or
bfd_link_hash_indirect. If NTYPE is bfd_link_hash_common, NSIZE
is the size of the new symbol. */
- boolean (*multiple_common) PARAMS ((struct bfd_link_info *,
- const char *name,
- bfd *obfd,
- enum bfd_link_hash_type otype,
- bfd_vma osize,
- bfd *nbfd,
- enum bfd_link_hash_type ntype,
- bfd_vma nsize));
+ bfd_boolean (*multiple_common)
+ (struct bfd_link_info *, const char *name,
+ bfd *obfd, enum bfd_link_hash_type otype, bfd_vma osize,
+ bfd *nbfd, enum bfd_link_hash_type ntype, bfd_vma nsize);
/* A function which is called to add a symbol to a set. ENTRY is
the link hash table entry for the set itself (e.g.,
__CTOR_LIST__). RELOC is the relocation to use for an entry in
- the set when generating a relocateable file, and is also used to
+ the set when generating a relocatable file, and is also used to
get the size of the entry when generating an executable file.
ABFD, SEC and VALUE identify the value to add to the set. */
- boolean (*add_to_set) PARAMS ((struct bfd_link_info *,
- struct bfd_link_hash_entry *entry,
- bfd_reloc_code_real_type reloc,
- bfd *abfd, asection *sec, bfd_vma value));
+ bfd_boolean (*add_to_set)
+ (struct bfd_link_info *, struct bfd_link_hash_entry *entry,
+ bfd_reloc_code_real_type reloc, bfd *abfd, asection *sec, bfd_vma value);
/* A function which is called when the name of a g++ constructor or
destructor is found. This is only called by some object file
- formats. CONSTRUCTOR is true for a constructor, false for a
+ formats. CONSTRUCTOR is TRUE for a constructor, FALSE for a
destructor. This will use BFD_RELOC_CTOR when generating a
- relocateable file. NAME is the name of the symbol found. ABFD,
+ relocatable file. NAME is the name of the symbol found. ABFD,
SECTION and VALUE are the value of the symbol. */
- boolean (*constructor) PARAMS ((struct bfd_link_info *,
- boolean constructor,
- const char *name, bfd *abfd, asection *sec,
- bfd_vma value));
+ bfd_boolean (*constructor)
+ (struct bfd_link_info *, bfd_boolean constructor, const char *name,
+ bfd *abfd, asection *sec, bfd_vma value);
/* A function which is called to issue a linker warning. For
example, this is called when there is a reference to a warning
symbol. WARNING is the warning to be issued. SYMBOL is the name
@@ -424,20 +458,17 @@ struct bfd_link_callbacks
there is none. ABFD, SECTION and ADDRESS identify the location
which trigerred the warning; either ABFD or SECTION or both may
be NULL if the location is not known. */
- boolean (*warning) PARAMS ((struct bfd_link_info *,
- const char *warning, const char *symbol,
- bfd *abfd, asection *section,
- bfd_vma address));
+ bfd_boolean (*warning)
+ (struct bfd_link_info *, const char *warning, const char *symbol,
+ bfd *abfd, asection *section, bfd_vma address);
/* A function which is called when a relocation is attempted against
an undefined symbol. NAME is the symbol which is undefined.
ABFD, SECTION and ADDRESS identify the location from which the
reference is made. FATAL indicates whether an undefined symbol is
a fatal error or not. In some cases SECTION may be NULL. */
- boolean (*undefined_symbol) PARAMS ((struct bfd_link_info *,
- const char *name, bfd *abfd,
- asection *section,
- bfd_vma address,
- boolean fatal));
+ bfd_boolean (*undefined_symbol)
+ (struct bfd_link_info *, const char *name, bfd *abfd,
+ asection *section, bfd_vma address, bfd_boolean fatal);
/* A function which is called when a reloc overflow occurs. NAME is
the name of the symbol or section the reloc is against,
RELOC_NAME is the name of the relocation, and ADDEND is any
@@ -445,11 +476,9 @@ struct bfd_link_callbacks
location at which the overflow occurs; if this is the result of a
bfd_section_reloc_link_order or bfd_symbol_reloc_link_order, then
ABFD will be NULL. */
- boolean (*reloc_overflow) PARAMS ((struct bfd_link_info *,
- const char *name,
- const char *reloc_name, bfd_vma addend,
- bfd *abfd, asection *section,
- bfd_vma address));
+ bfd_boolean (*reloc_overflow)
+ (struct bfd_link_info *, const char *name, const char *reloc_name,
+ bfd_vma addend, bfd *abfd, asection *section, bfd_vma address);
/* A function which is called when a dangerous reloc is performed.
The canonical example is an a29k IHCONST reloc which does not
follow an IHIHALF reloc. MESSAGE is an appropriate message.
@@ -457,26 +486,33 @@ struct bfd_link_callbacks
problem occurred; if this is the result of a
bfd_section_reloc_link_order or bfd_symbol_reloc_link_order, then
ABFD will be NULL. */
- boolean (*reloc_dangerous) PARAMS ((struct bfd_link_info *,
- const char *message,
- bfd *abfd, asection *section,
- bfd_vma address));
+ bfd_boolean (*reloc_dangerous)
+ (struct bfd_link_info *, const char *message,
+ bfd *abfd, asection *section, bfd_vma address);
/* A function which is called when a reloc is found to be attached
to a symbol which is not being written out. NAME is the name of
the symbol. ABFD, SECTION and ADDRESS identify the location of
the reloc; if this is the result of a
bfd_section_reloc_link_order or bfd_symbol_reloc_link_order, then
ABFD will be NULL. */
- boolean (*unattached_reloc) PARAMS ((struct bfd_link_info *,
- const char *name,
- bfd *abfd, asection *section,
- bfd_vma address));
+ bfd_boolean (*unattached_reloc)
+ (struct bfd_link_info *, const char *name,
+ bfd *abfd, asection *section, bfd_vma address);
/* A function which is called when a symbol in notice_hash is
defined or referenced. NAME is the symbol. ABFD, SECTION and
ADDRESS are the value of the symbol. If SECTION is
bfd_und_section, this is a reference. */
- boolean (*notice) PARAMS ((struct bfd_link_info *, const char *name,
- bfd *abfd, asection *section, bfd_vma address));
+ bfd_boolean (*notice)
+ (struct bfd_link_info *, const char *name,
+ bfd *abfd, asection *section, bfd_vma address);
+ /* A function which is called for reporting a linker error. ID is the
+ error identifier. The remaining input is the same as einfo () in
+ ld. */
+ bfd_boolean (*error_handler)
+ (int id, const char *fmt, ...);
+
+/* Identifiers of linker error messages used by error_handler. */
+#define LD_DEFINITION_IN_DISCARDED_SECTION 1
};
/* The linker builds link_order structures which tell the code how to
@@ -496,20 +532,20 @@ enum bfd_link_order_type
/* This is the link_order structure itself. These form a chain
attached to the section whose contents they are describing. */
-struct bfd_link_order
+struct bfd_link_order
{
/* Next link_order in chain. */
struct bfd_link_order *next;
/* Type of link_order. */
enum bfd_link_order_type type;
/* Offset within output section. */
- bfd_vma offset;
+ bfd_vma offset;
/* Size within output section. */
bfd_size_type size;
/* Type specific information. */
- union
+ union
{
- struct
+ struct
{
/* Section to include. If this is used, then
section->output_section must be the section the
@@ -576,27 +612,44 @@ struct bfd_link_order_reloc
};
/* Allocate a new link_order for a section. */
-extern struct bfd_link_order *bfd_new_link_order PARAMS ((bfd *, asection *));
+extern struct bfd_link_order *bfd_new_link_order (bfd *, asection *);
/* These structures are used to describe version information for the
ELF linker. These structures could be manipulated entirely inside
BFD, but it would be a pain. Instead, the regular linker sets up
these structures, and then passes them into BFD. */
-/* Regular expressions for a version. */
+/* Glob pattern for a version. */
struct bfd_elf_version_expr
{
- /* Next regular expression for this version. */
+ /* Next glob pattern for this version. */
struct bfd_elf_version_expr *next;
- /* Regular expression. */
+ /* Glob pattern. */
const char *pattern;
- /* Matching function. */
- int (*match) PARAMS((struct bfd_elf_version_expr *, const char *));
+ /* NULL for a glob pattern, otherwise a straight symbol. */
+ const char *symbol;
/* Defined by ".symver". */
- unsigned int symver: 1;
+ unsigned int symver : 1;
/* Defined by version script. */
unsigned int script : 1;
+ /* Pattern type. */
+#define BFD_ELF_VERSION_C_TYPE 1
+#define BFD_ELF_VERSION_CXX_TYPE 2
+#define BFD_ELF_VERSION_JAVA_TYPE 4
+ unsigned int mask : 3;
+};
+
+struct bfd_elf_version_expr_head
+{
+ /* List of all patterns, both wildcards and non-wildcards. */
+ struct bfd_elf_version_expr *list;
+ /* Hash table for non-wildcards. */
+ void *htab;
+ /* Remaining patterns. */
+ struct bfd_elf_version_expr *remaining;
+ /* What kind of pattern types are present in list (bitmask). */
+ unsigned int mask;
};
/* Version dependencies. */
@@ -620,15 +673,19 @@ struct bfd_elf_version_tree
/* Version number. */
unsigned int vernum;
/* Regular expressions for global symbols in this version. */
- struct bfd_elf_version_expr *globals;
+ struct bfd_elf_version_expr_head globals;
/* Regular expressions for local symbols in this version. */
- struct bfd_elf_version_expr *locals;
+ struct bfd_elf_version_expr_head locals;
/* List of versions which this version depends upon. */
struct bfd_elf_version_deps *deps;
/* Index of the version name. This is used within BFD. */
unsigned int name_indx;
/* Whether this version tree was used. This is used within BFD. */
int used;
+ /* Matching hook. */
+ struct bfd_elf_version_expr *(*match)
+ (struct bfd_elf_version_expr_head *head,
+ struct bfd_elf_version_expr *prev, const char *sym);
};
#endif
diff --git a/contrib/binutils/include/coff/ChangeLog b/contrib/binutils/include/coff/ChangeLog
index 23b0627..3316383 100644
--- a/contrib/binutils/include/coff/ChangeLog
+++ b/contrib/binutils/include/coff/ChangeLog
@@ -1,1090 +1,9 @@
-2002-03-18 Tom Rix <trix@redhat.com>
-
- * rs6k64.h: Add U64_TOCMAGIC, AIX 5 64 bit magic number.
-
-2002-02-01 Tom Rix <trix@redhat.com>
-
- * xcoff.h: Conditionally support <aiaff> for pre AIX 4.3.
-
-2002-01-31 Ivan Guzvinec <ivang@opencores.org>
-
- * or32.h: New file.
-
-2001-12-24 Tom Rix <trix@redhat.com>
-
- * xcoff.h (xcoff_big_format_p): Make <bigaf> the default archive
- format.
- (XCOFFARMAG_ELEMENT_SIZE, XCOFFARMAGBIG_ELEMENT_SIZE): Define for
- archive header ascii elements.
-
-2001-12-17 Tom Rix <trix@redhat.com>
-
- * xcoff.h : Add .except and .typchk section string and styp flags.
- Fix xcoff_big_format_p macro.
-
-2001-12-16 Tom Rix <trix@redhat.com>
-
- * xcoff.h : Clean up formatting.
-
-2002-01-15 Richard Earnshaw <rearnsha@arm.com>
-
- * arm.h (F_VFP_FLOAT): Define.
-
-2001-11-11 Timothy Wall <twall@alum.mit.edu>
-
- * ti.h: Move arch-specific stuff from here...
- (COFF_ADJUST_SYM_IN/OUT): Optionally put page flag into symbol
- value.
- * tic54x.h: ...to here.
-
-2001-10-26 Christian Groessler <cpg@aladdin.de>
-
- * external.h (GET_LINENO_LNNO): Fix usage of H_GET_32/16.
- (PUT_LINENO_LNNO): Likewise with H_PUT_32/16.
-
-2001-09-21 Nick Clifton <nickc@cambridge.redhat.com>
-
- * ti.h (GET_SCNHDR_PAGE): Fix compile time warning.
-
-2001-09-18 Alan Modra <amodra@bigpond.net.au>
-
- * external.h (GET_LINENO_LNNO): Use H_GET_32/16.
- (PUT_LINENO_LNNO): Use H_PUT_32/16.
- * m88k.h (GET_LNSZ_SIZE, GET_LNSZ_LNNO, GET_SCN_NRELOC,
- GET_SCN_NLINNO): Use H_GET_32.
- (PUT_LNSZ_LNNO, PUT_LNSZ_SIZE, PUT_SCN_NRELOC, PUT_SCN_NLINNO):
- Use H_PUT_32.
- * ti.h: Formatting fixes. Make use of H_GET_* and H_PUT_* throughout.
- * xcoff.h: White space changes.
-
-2001-09-05 Tom Rix <trix@redhat.com>
-
- * xcoff.h : Add XCOFF_SYSCALL32 and XCOFF_SYSCALL64 hash table flags.
-
-2001-08-27 Andreas Jaeger <aj@suse.de>
-
- * xcoff.h (struct __rtinit): Make proper prototype for rtl.
-
-Fri Aug 24 01:18:51 2001 J"orn Rennecke <amylaar@redhat.com>
-
- * internal.h (R_JMP2, R_JMPL2, R_MOVL2): Comment spelling fix.
-
-2001-04-05 Tom Rix <trix@redhat.com>
-
- * rs6000.h : move xcoff32 external structures from xcofflink.
- * rs6k64.h : move xcoff64 external structures from xcofflink.
- * internal.h : promote 32 bit structure elements to 64 bit
- for xcoff64 support
- * xcoff.h : New file.
-
-2001-03-23 Nick Clifton <nickc@redhat.com>
-
- * a29k.h: Fix compile time warning.
- * external.h: Fix compile time warning.
- * m88k.h: Fix compile time warning.
-
-2001-03-13 Nick Clifton <nickc@redhat.com>
-
- * external.h: New file. Common structure definitions found in
- other COFF header files.
-
- * a29k.h: Use external.h.
- * apollo.h: Use external.h.
- * arm.h: Use external.h.
- * h8300.h: Use external.h.
- * h8500.h: Use external.h.
- * i386.h: Use external.h.
- * i860.h: Use external.h.
- * ia64.h: Use external.h.
- * m68k.h: Use external.h.
- * m88k.h: Use external.h.
- * mcore.h: Use external.h.
- * mips.h: Use external.h.
- * mipspe.h: Use external.h.
- * powerpc.h: Use external.h.
- * rs6000.h: Use external.h.
- * rs6k64.h: Use external.h.
- * sh.h: Use external.h.
- * sparc.h: Use external.h.
- * tic30.h: Use external.h.
- * tic80.h: Use external.h.
- * w65.h: Use external.h.
- * we32k.h: Use external.h.
- * z8k.h: Use external.h.
-
-2001-02-09 David Mosberger <davidm@hpl.hp.com>
-
- * pe.h (PEPAOUTSZ): Rename from PEP64AOUTSZ.
- Rename from PEPAOUTHDR.
-
-2001-01-23 H.J. Lu <hjl@gnu.org>
-
- * pe.h (struct external_PEI_DOS_hdr): New.
- (struct external_PEI_IMAGE_hdr): New.
-
-2000-12-11 Alan Modra <alan@linuxcare.com.au>
-
- * ti.h (OCTETS_PER_BYTE_POWER): Change #warning to #error.
-
-2000-12-08 Alan Modra <alan@linuxcare.com.au>
-
- * ti.h (OCTETS_PER_BYTE_POWER): Change #warn to #warning.
-
-2000-06-30 DJ Delorie <dj@cygnus.com>
-
- * pe.h: Clarify a comment.
-
-2000-05-05 Clinton Popetz <cpopetz@cygnus.com>
-
- * rs6k64.h (U802TOC64MAGIC): Change to U803XTOCMAGIC.
-
-2000-04-24 Clinton Popetz <cpopetz@cygnus.com>
-
- * rs6k64.h: New file.
-
-2000-04-17 Timothy Wall <twall@cygnus.com>
-
- * ti.h: Load page cleanup.
- * intental.h: Add load page field.
-
-Mon Apr 17 16:44:01 2000 David Mosberger <davidm@hpl.hp.com>
-
- * pe.h (PEP64AOUTHDR): New header for PE+.
- (PEP64AOUTSZ): New macro.
- (IMAGE_SUBSYSTEM_UNKNOWN): New macro.
- (IMAGE_SUBSYSTEM_NATIVE): Ditto.
- (IMAGE_SUBSYSTEM_WINDOWS_GUI): Ditto.
- (IMAGE_SUBSYSTEM_WINDOWS_CUI): Ditto.
- (IMAGE_SUBSYSTEM_POSIX_CUI): Ditto.
- (IMAGE_SUBSYSTEM_WINDOWS_CE_GUI): Ditto.
- (IMAGE_SUBSYSTEM_EFI_APPLICATION): Ditto.
- (IMAGE_SUBSYSTEM_EFI_BOOT_SERVICE_DRIVER): Ditto.
- (IMAGE_SUBSYSTEM_EFI_RUNTIME_DRIVER): Ditto.
- * internal.h (PE_DEF_FILE_ALIGNMENT): Define only if not defined
- already.
- * ia64.h: New file.
-
-2000-04-13 Alan Modra <alan@linuxcare.com.au>
-
- * ti.h (ADDR_MASK): Don't use ul suffix on constants.
- (PG_MASK): Ditto.
-
-2000-04-11 Timothy Wall <twall@cygnus.com>
-
- * ti.h: Remove load page references until load pages are
- reimplemented.
- * tic54x.h: Ditto.
-
-2000-04-07 Timothy Wall <twall@cygnus.com>
-
- * internal.h: Fix some comments related to TI COFF (instead of tic80).
- * ti.h: New.
- * tic54x.h: New.
-
-Wed Apr 5 22:08:41 2000 J"orn Rennecke <amylaar@cygnus.co.uk>
-
- * sh.h (R_SH_LOOP_START, R_SH_LOOP_END): Define.
-
-2000-03-15 Kazu Hirata <kazu@hxi.com>
-
- * internal.h: Fix a typo in the comment for R_MOVL2.
-
-2000-02-28 Nick Clifton <nickc@cygnus.com>
-
- * mipspe.h (MIPS_PE_MAGIC): Define.
- * sh.h (SH_PE_MAGIC): Define.
-
-2000-02-22 Nick Clifton <nickc@cygnus.com> DJ Delorie <dj@cygnus.com>
-
- * sh.h: Add Windows CE definitions.
- * arm.h: Add Windows CE definitions.
- * mipspe.h: New file: Windows CE definitions for MIPS.
- * pe.h: Add constants for ILF support.
-
-2000-01-05 Nick Clifton <nickc@cygnus.com>
-
- * pe.h: Fix formatting of comments.
- (IMAGE_FILE_AGGRESSIVE_WS_TRIM): Define.
- (IMAGE_FILE_LARGE_ADDRESS_AWARE): Define.
- (IMAGE_FILE_16BIT_MACHINE): Define.
- (IMAGE_FILE_REMOVABLE_RUN_FROM_SWAP): Define.
- (IMAGE_FILE_UP_SYSTEM_ONLY): Define.
- (IMAGE_FILE_MACHINE_UNKNOWN): Define.
- (IMAGE_FILE_MACHINE_ALPHA): Define.
- (IMAGE_FILE_MACHINE_ALPHA64): Define.
- (IMAGE_FILE_MACHINE_I386): Define.
- (IMAGE_FILE_MACHINE_IA64): Define.
- (IMAGE_FILE_MACHINE_M68K): Define.
- (IMAGE_FILE_MACHINE_MIPS16): Define.
- (IMAGE_FILE_MACHINE_MIPSFPU): Define.
- (IMAGE_FILE_MACHINE_MIPSFPU16): Define.
- (IMAGE_FILE_MACHINE_POWERPC): Define.
- (IMAGE_FILE_MACHINE_R3000): Define.
- (IMAGE_FILE_MACHINE_R4000): Define.
- (IMAGE_FILE_MACHINE_R10000): Define.
- (IMAGE_FILE_MACHINE_SH3): Define.
- (IMAGE_FILE_MACHINE_SH4): Define.
- (IMAGE_FILE_MACHINE_THUMB): Define.
-
-1999-09-20 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * internal.h: Delete bogus R_PCLONG, duplicate R_RELBYTE and
- R_RELWORD, and rewrite some R_* as decimal.
-
-1999-09-06 Donn Terry <donn@interix.com>
-
- * internal.h (DTYPE): Define.
- * pe.h (struct external_PEI_filehdr): Rename from
- external_PE_filehdr. Define even if COFF_IMAGE_WITH_PE is not
- defined.
-
-1999-07-17 Nick Clifton <nickc@cygnus.com>
-
- * arm.h (F_SOFT_FLOAT): Rename from F_SOFTFLOAT.
-
-1999-06-21 Philip Blundell <pb@nexus.co.uk>
-
- * arm.h (F_SOFTFLOAT): Define.
-
-1999-07-05 Nick Clifton <nickc@cygnus.com>
-
- * arm.h (F_ARM_5): Define.
-
-Wed Jun 2 18:08:18 1999 Richard Henderson <rth@cygnus.com>
-
- * internal.h (BEOS_EXE_IMAGE_BASE, BEOS_DLL_IMAGE_BASE): New.
-
-Mon May 17 13:35:35 1999 Stan Cox <scox@cygnus.com>
-
- * arm.h (F_PIC, F_ARM_2, F_ARM_2a, F_ARM_3, F_ARM_3M,
- F_ARM_4, F_ARM_4T, F_APCS26): Changed values to distinguish
- F_ARM_2a, F_ARM_3M, F_ARM_4T.
-
-1999-05-15 Nick Clifton <nickc@cygnus.com>
-
- * mcore.h (IMAGE_REL_MCORE_RVA): Define.
-
-1999-04-21 Nick Clifton <nickc@cygnus.com>
-
- * mcore.h (GET_LINENO_LNNO): New macro.
- (PUT_LINENO_LNNO): New macro.
-
-1999-04-08 Nick Clifton <nickc@cygnus.com>
-
- * mcore.h: New header file. Defines for Motorola's MCore
- processor.
-
-Sun Dec 6 21:36:37 1998 Mark Elbrecht <snowball3@usa.net>
-
- * internal.h (C_WEAKEXT): Define.
-
-Wed Jan 27 13:35:35 1999 Stan Cox <scox@cygnus.com>
-
- * arm.h (F_PIC_INT, F_ARM_2, F_ARM_3, F_ARM_4, F_APCS26):
- Changed values to avoid clashing with IMAGE_FILE_* coff header
- flag values.
-
-Wed Apr 1 16:06:15 1998 Nick Clifton <nickc@cygnus.com>
-
- * internal.h: Document numbers associated with Thumb symbol
- types.
-
-Fri Mar 27 17:16:57 1998 Ian Lance Taylor <ian@cygnus.com>
-
- * internal.h (ISPTR, ISFCN, ISARY): Add casts to unsigned long.
-
-Mon Feb 2 17:10:38 1998 Steve Haworth <steve@pm.cse.rmit.EDU.AU>
-
- * tic30.h: New file.
-
-Fri Dec 12 11:49:07 1997 Fred Fish <fnf@cygnus.com>
-
- * tic80.h (R_MPPCR15W): New relocation type, for 15 bit PC relative
- offsets.
-
-Tue Dec 2 10:21:40 1997 Nick Clifton <nickc@cygnus.com>
-
- * arm.h (COFFARM): New define.
-
-Mon Dec 1 20:24:18 1997 J"orn Rennecke <amylaar@cygnus.co.uk>
-
- * sh.h (R_SH_SWITCH8): New.
-
-Sat Nov 22 15:10:14 1997 Nick Clifton <nickc@cygnus.com>
-
- * internal.h (C_THUMBEXTFUNC, C_THUMBSTATFUNC): Constants to
- define static and external functions.
-
- * arm.h: Add bits to support PIC and APCS-FLOAT type binaries,
- when implemented.
-
-Fri Oct 3 14:25:17 1997 Fred Fish <fnf@cygnus.com>
-
- * tic80.h (R_PPL16B): Make constant uppercase for consistency.
-
-Tue Jul 22 18:18:58 1997 Robert Hoehne <robert.hoehne@Mathematik.TU-Chemnitz.DE>
-
- * go32exe.h: New file.
-
-Tue Jul 8 12:23:55 1997 Fred Fish <fnf@cygnus.com>
-
- * tic80.h (TIC80_TARGET_ID): Add define.
- * internal.h (struct internal_filehdr): Add f_target_id field.
-
-Tue Jun 3 16:44:18 1997 Nick Clifton <nickc@cygnus.com>
-
- * internal.h: Add storage classes for Thumb symbols
-
-Mon May 26 14:07:55 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * tic80.h (R_PPL16B): Correct value.
-
-Tue May 13 10:21:14 1997 Nick Clifton <nickc@cygnus.com>
-
- * arm.h (constants): Added new flag bits F_APCS_26 and
- F_APCS_SET for the f_flags field of the filehdr structure. Added new
- flags: F_APCS26, F_ARM_2, F_ARM_3, F_ARM_7, F_ARM_7T to store
- information in the flags field of the internal_f structure used by BFD
- routines.
-
-Sat May 3 08:24:59 1997 Fred Fish <fnf@cygnus.com>
-
- * internal.h (C_UEXT, C_STATLAB, C_EXTLAB, C_SYSTEM):
- New storage classes for TIc80.
-
-Fri Apr 18 11:52:55 1997 Niklas Hallqvist <niklas@appli.se>
-
- * alpha.h (ALPHA_ECOFF_BADMAG): Recognize *BSD/alpha magic too.
- (ALPHA_R_LITERALSLEAZY): Define.
- * ecoff.h (ALPHA_MAGIC_BSD): Define.
-
-Wed Jan 29 11:31:51 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * i960.h (R_IPR13, R_ALIGN): Define.
-
-Mon Jan 27 13:34:30 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * internal.h (R_IPRMED, R_OPTCALL, R_OPTCALLX): Move definitions
- from here...
- * i960.h (R_IPRMED, R_OPTCALL, R_OPTCALLX): ...to here.
-
-Wed Jan 22 20:10:47 1997 Fred Fish <fnf@cygnus.com>
-
- * tic80.h (TIC80MAGIC): Renamed to TIC80_AOUTHDR_MAGIC.
-
-Fri Dec 27 22:05:45 1996 Fred Fish <fnf@cygnus.com>
-
- * tic80.h: New file for TIc80 support.
-
-Thu Dec 19 16:18:11 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * arm.h (_LIT): Define.
-
-Fri Jun 28 12:54:38 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * pe.h (FILHSZ): Define.
-
-Wed Jun 26 16:24:26 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * All files: Define FILHSZ, AOUTSZ, AOUTHDRSZ, SCNHSZ, SYMESZ,
- AUXESZ, LINESZ, RELSZ as numeric constants rather than uses of
- sizeof. Define AOUTHDRSZ in all files.
- * pe.h (AOUTSZ): Define by adding to AOUTHDRSZ.
-
-Fri Jun 21 11:17:46 1996 Richard Henderson <rth@tamu.edu>
-
- * alpha.h: Add declarations for relocation types added for Alpha
- OSF/1 3.0.
-
-Tue Jun 18 16:04:29 1996 Jeffrey A. Law <law@rtl.cygnus.com>
-
- * h8300.h (H8300SMAGIC): Define.
- (H8300SBADMAG): Define.
-
-Mon Jun 10 11:53:28 1996 Jeffrey A Law (law@cygnus.com)
-
- * internal.h (R_BCC_INV, R_JMP_DEL): New relocations for
- relaxing in the H8/300 series.
-
-Thu May 16 15:49:22 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * sh.h (R_SH_CODE, R_SH_DATA, R_SH_LABEL): Define.
-
-Tue May 7 00:36:39 1996 Jeffrey A Law (law@cygnus.com)
-
- * internal.h (R_JMPL2): Renamed from R_JMPL_B8 to be
- consistent with other similar relocs.
-
- * internal.h (H8/300 specific relocs): Add comments better
- explaining what each reloc is used for.
- (R_MOV16B1, R_MOV16B2): Renamed from R_MOVB1 and R_MOVB2.
- (R_MOV24B1, R_MOV24B2): Renamed from R_MOVLB1 and R_MOVLB2.
- (R_MOVL1, R_MOVL2): New relocs.
-
-Fri May 3 13:01:12 1996 Jeffrey A Law (law@cygnus.com)
-
- * internal.h (R_PCRWORD_B): Define for the h8300 relaxing
- linker.
-
-Wed May 1 19:21:03 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * internal.h (SCNNMLEN): Define.
- (struct internal_scnhdr): Use SCNNMLEN for s_name field.
-
-Fri Mar 29 13:41:25 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * pe.h: Define IMAGE_COMDAT codes.
-
-Wed Mar 27 17:29:42 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * arm.h (union external_auxent): Add x_checksum, x_associated, and
- x_comdat fields to x_scn struct.
- * i386.h (union external_auxent): Likewise.
- * powerpc.h (union external_auxent): Likewise.
- * internal.h (union internal_auxent): Likewise.
-
-Thu Mar 21 16:25:57 1996 David Mosberger-Tang <davidm@azstarnet.com>
-
- * ecoff.h (struct ecoff_find_line): Add caching fields.
-
-Thu Mar 14 15:22:44 1996 Jeffrey A Law (law@cygnus.com)
-
- * internal.h (R_MEM_INDIRECT): New reloc for the h8300.
-
-Fri Feb 9 10:44:11 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * aux-coff.h: Rename from aux.h, to avoid problems on hapless DOS
- systems which think that aux is a com port.
-
-Mon Feb 5 18:35:00 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * i960.h (F_I960HX): Define.
-
-Wed Jan 31 13:11:54 1996 Richard Henderson <rth@tamu.edu>
-
- * aux.h: New file.
- * internal.h, m68k.h: Protect against multiple inclusion.
-
-Wed Nov 22 13:48:39 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * ecoff.h (_RCONST, STYP_RCONST, RELOC_SECTION_RCONST): Define.
- (NUM_RELOC_SECTIONS): Update.
- * symconst.h (scRConst): Define.
-
-Tue Nov 14 18:54:29 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * internal.h (C_NT_WEAK): Define.
-
-Thu Nov 9 14:08:30 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * rs6000.h (STYP_OVRFLO): Define.
-
-Tue Nov 7 14:38:45 1995 Kim Knuttila <krk@cygnus.com>
-
- * powerpc.h (IMAGE_NT_OPTIONAL_HDR_MAGIC): Added define.
- * pe.h: Added defines for file level flags
-
-Mon Nov 6 17:28:01 1995 Harry Dolan <dolan@ssd.intel.com>
-
- * i860.h: New file, based on i386.h.
-
-Wed Nov 1 15:25:18 1995 Manfred Hollstein KS/EF4A 60/1F/110 #40283 <manfred@lts.sel.alcatel.de>
-
- * m68k.h (PAGEMAGICEXECSWAPPED): Define.
- (PAGEMAGICPEXECSWAPPED): Define.
- (PAGEMAGICPEXECTSHLIB): Define.
- (PAGEMAGICPEXECPAGED): Define.
- (_COMMENT): DEFINE.
- * m88k.h (_COMMENT): Define.
-
-Wed Oct 18 18:36:19 1995 Geoffrey Noer <noer@cygnus.com>
-
- * sym.h: #if 0'd out runtime_pdr struct because it chokes
- Visual C++ and there aren't any references to it elsewhere in gdb.
-
-Mon Oct 16 11:12:24 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * rs6000.h (SMALL_AOUTSZ): Define.
-
- * internal.h (XMC_TD): Define.
-
-Tue Oct 10 18:41:03 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * internal.h (struct internal_aouthdr): Add o_cputype field.
- * rs6000.h (AOUTHDR): Rename o_resv1 to o_cputype.
-
-Mon Oct 9 14:45:46 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * rs6000.h (AOUTHDR): Add o_maxdata field. Add comments.
- (_PAD, _LOADER): Define.
- (STYP_LOADER): Define.
- * internal.h (struct internal_aouthdr): Add o_maxdata field.
-
-Thu Oct 5 10:02:57 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * ecoff.h: Define section name macros and STYP macros for various
- Alpha sections: .got, .hash, .dynsym, .dynstr, .rel.dyn, .conflic,
- .comment, .liblist, .dynamic.
-
-Wed Oct 4 10:56:35 1995 Kim Knuttila <krk@cygnus.com>
-
- * pe.h: Moved DOSMAGIC and NT_SIGNATURE defines here
- * powerpc.h: removed DOSMAGIC, NT_SIGNATURE, and DEFAULT_* defines
- Also removed other unused defines (various MAGIC ones)
- * i386.h: removed DOSMAGIC, NT_SIGNATURE, and DEFAULT_* defines
- * arm.h: removed DOSMAGIC, NT_SIGNATURE, and DEFAULT_* defines
- * apollo.h: removed unused DEFAULT_* defines
- * alpha.h: removed unused DEFAULT_* defines
- * h8500.h: removed unused DEFAULT_* defines
- * h8300.h: removed unused DEFAULT_* defines
- * i960.h: removed unused DEFAULT_* defines
- * m88k.h: removed unused DEFAULT_* defines
- * we32k.h: removed unused DEFAULT_* defines
- * rs6000.h: removed unused DEFAULT_* defines
- * mips.h: removed unused DEFAULT_* defines
- * m68k.h: removed unused DEFAULT_* defines
- * z8k.h: removed unused DEFAULT_* defines
- * w65.h: removed unused DEFAULT_* defines
- * sparc.h: removed unused DEFAULT_* defines
- * sh.h: removed unused DEFAULT_* defines
-
-Fri Sep 29 08:40:08 1995 Kim Knuttila <krk@cygnus.com>
-
- * powerpc.h: Reformatted to GNU coding conventions.
-
-Wed Sep 27 06:50:50 1995 Kim Knuttila <krk@nellie>
-
- * pe.h: added defines for more section characteristics
- * powerpc.h (new file): base coff definitions for ppc PE
-
-Tue Sep 12 12:08:20 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * internal.h (struct internal_syment): Change n_numaux field from
- char to unsigned char.
-
-Fri Sep 1 15:39:36 1995 Kazumoto Kojima <kkojima@info.kanagawa-u.ac.jp>
-
- * mips.h (struct rpdr_ext): Define.
-
-Thu Aug 31 16:51:50 1995 steve chamberlain <sac@slash.cygnus.com>
-
- * internal.h (internal_aouthdr, internal_filehdr):
- don't indirect the pe stuff.
-
-Tue Aug 29 14:16:07 1995 steve chamberlain <sac@slash.cygnus.com>
-
- * i386.h (NT_DEF_RESERVE, NT_DEF_COMMIT): Make the same
- as 'the other' compiler.
- * internal.h (NT_IMAGE_BASE): Deleted.
- (NT_EXE_IMAGE_BASE, NT_DLL_IMAGE_BASE): New.
- (PE_DEF_SECTION_ALIGNMENT, PE_DEF_FILE_ALIGNMENT): New.
- (R_IMAGEBASE): New.
-
-Mon Aug 21 18:12:19 1995 steve chamberlain <sac@slash.cygnus.com>
-
- * internal.h: (internal_filehdr): Moved PE stuff into
- internal_extra_pe_filehdr.
- (internal_aouthdr): Moved PE stuff into
- interanl_extra_pe_aouthdr.
-
-Mon Jul 24 14:05:39 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * internal.h: Move R_SH_* relocs from here...
- * sh.h: ...to here.
- (R_SH_SWITCH16, R_SH_SWITCH32): Define.
- (R_SH_USES, R_SH_COUNT, R_SH_ALIGN): Define.
-
-Thu Jun 29 00:04:25 1995 Steve Chamberlain <sac@slash.cygnus.com>
-
- * internal.h (NT_DEF_RESERVE, NT_DEF_COMMIT): Increase a lot.
-
-Tue May 16 15:08:20 1995 Ken Raeburn <raeburn@cujo.cygnus.com>
-
- * internal.h (NT_subsystem, NT_stack_heap): Delete
-
-Tue May 16 15:08:20 1995 Ken Raeburn <raeburn@cujo.cygnus.com>
-
- * internal.h (NT_subsystem, NT_stack_heap): Now extern.
-
-Sat May 13 10:14:08 1995 Steve Chamberlain <sac@slash.cygnus.com>
-
- * pe.h: New file.
- * i386.h (NT_SECTION_ALIGNMENT, NT_FILE_ALIGNMENT,
- NT_DEF_RESERVE, NT_DEF_COMMIT): New.
- * internal.h (internal_filehdr): New fields for PE.
- (IMAGE_DATA_DIRECTORY): New.
- (internal_aouthdr): New fields for PE.
-
-Tue Feb 14 17:59:37 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * ecoff.h (struct ecoff_fdrtab_entry): Define.
- (struct ecoff_find_line): Define.
-
-Sat Feb 4 14:38:03 1995 David Mosberger-Tang <davidm@piston.cs.arizona.edu>
-
- * sym.h (struct pdr): field "prof" added.
-
- * alpha.h (PDR_BITS1_PROF_*): added, macros for PDR_BITS*_RESERVED_*
- updated accordingly.
-
-Sun Jan 15 18:38:33 1995 Steve Chamberlain <sac@splat>
-
- * w65.h: New file.
-
-Wed Nov 23 22:43:38 1994 Steve Chamberlain (sac@jonny.cygnus.com)
-
- * sh.h (SH_ARCH_MAGIC_BIG, SH_ARCH_MAGIC_LITTLE): New.
- (SHBADMAG): Changed to suit.
-
-Tue Jul 26 17:46:08 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
-
- * i960.h (F_I960JX): New macro.
-
-Wed Jul 6 00:48:57 1994 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
-
- * alpha.h: Add definitions for alpha file header flags, encoding
- the object type of the file.
-
-Mon Jun 20 13:47:01 1994 Ian Lance Taylor (ian@sanguine.cygnus.com)
-
- * ecoff.h (ecoff_swap_tir_in): Remove declaration.
- (ecoff_swap_tir_out): Likewise.
- (ecoff_swap_rndx_in, ecoff_swap_rndx_out): Likewise.
- (struct ecoff_debug_swap): Add new fields: swap_tir_in,
- swap_rndx_in, swap_tir_out, swap_rndx_out, read_debug_info.
-
-Sun Jun 12 03:51:52 1994 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
-
- * symconst.h: Pick up SGI define for stIndirect.
-
-Fri Apr 22 13:05:28 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * ecoff.h (REGINFO): Don't define.
- (struct ecoff_reginfo): Don't define.
-
- * sh.h (SH_ARCH_MAGIC): Rename from SHMAGIC. SHMAGIC is used by
- several targets to mean a shared library.
- (SHBADMAG): Corresponding change.
-
-Thu Apr 14 13:00:53 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * mips.h (RELOC_BITS3_TYPE_BIG): Changed from 0x1e to 0x3e.
- (RELOC_BITS3_TYPEHI_LITTLE): Define.
- (RELOC_BITS3_TYPEHI_SH_LITTLE): Define.
- (MIPS_R_PCREL16): Change value from 8 to 12 to match Irix 4.
- (MIPS_R_RELHI): Define.
- (MIPS_R_RELLO): Define.
- (MIPS_R_SWITCH): Change value from 9 to 22.
-
-Thu Apr 7 14:19:35 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * mips.h (MIPS_R_SWITCH): Define.
-
-Thu Mar 31 19:28:33 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
-
- * internal.h (internal_aouthdr): Added comments for Apollo fields.
-
-Thu Mar 31 16:28:02 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * ecoff.h (STYP_ECOFF_LIB): Define as used on Irix 4.
-
-Fri Mar 25 17:16:55 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * ecoff.h (struct ecoff_debug_info): Add adjust field.
- (struct ecoff_value_adjust): Define.
-
-Tue Mar 22 13:22:47 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * mips.h (MIPS_R_PCREL16): Define.
-
-Sat Feb 26 10:26:38 1994 Ian Lance Taylor (ian@cygnus.com)
-
- * ecoff.h: Add casts to avoid warnings from SVR4 cc.
-
-Mon Feb 21 09:48:46 1994 Ian Lance Taylor (ian@lisa.cygnus.com)
-
- * sym.h (struct runtime_pdr): Make field adr bfd_vma, not unsigned
- long.
- (SYMR): Make field value bfd_vma, not long.
-
-Fri Feb 4 23:35:53 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * rs6000.h (STYP_DEBUG): Define.
-
-Wed Feb 2 14:31:37 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * internal.h (union internal_auxent): Change x_csect.x_scnlen into
- a union of a long and a pointer to a symbol. XCOFF sometimes uses
- this field as a symbol index.
-
-Mon Jan 10 23:54:25 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * ecoff.h (ecoff_debug_info): Remove fields line_end,
- external_dnr_end, external_pdr_end, external_sym_end,
- external_opt_end, external_aux_end, ss_end, external_fdr_end.
- Replace ifdbase with ifdmap.
-
-Wed Jan 5 17:05:36 1994 Ken Raeburn (raeburn@deneb.cygnus.com)
-
- * ecoff.h (STYP_EXTENDESC, STYP_COMMENT, STYP_XDATA, STYP_PDATA):
- Define.
-
-Wed Jan 5 16:58:24 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * ecoff.h (NUM_RELOC_SECTIONS): Define.
-
-Tue Dec 21 09:24:56 1993 Ken Raeburn (raeburn@rtl.cygnus.com)
-
- * sparc.h (struct external_reloc): Rename field r_addend to
- r_offset.
-
-Sat Dec 11 16:12:32 1993 Steve Chamberlain (sac@thepub.cygnus.com)
-
- * internal.h (R_DISP7, R_SH_IMM16): New reloc types.
-
-Tue Nov 23 14:23:19 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * ecoff.h (struct ecoff_debug_swap): Added *_end fields for all
- the symbolic information pointers.
-
- * sym.h: Named the EXTR structure ecoff_extr.
-
-Fri Nov 19 08:21:18 1993 Ken Raeburn (raeburn@rover.cygnus.com)
-
- * sparc.h (RELSZ): Use correct size.
-
-Wed Nov 17 17:18:16 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * mips.h (struct ecoff_debug_info): Define.
-
-Tue Nov 2 17:56:57 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * ecoff.h (struct ecoff_debug_swap): Define.
-
-Thu Oct 28 17:07:50 1993 Stan Shebs (shebs@rtl.cygnus.com)
-
- * i386.h (I386LYNXMAGIC): Rename to LYNXCOFFMAGIC.
- * m68k.h (LYNXCOFFMAGIC): Define.
- * sparc.h: New file.
-
-Tue Oct 19 15:34:50 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * alpha.h (external_aouthdr): Split four byte padding field into
- two byte bldrev field and two byte padding field.
-
- * ecoff.h (_LITA, _PDATA, _XDATA, STYP_LITA): Defined.
-
-Wed Oct 13 15:52:34 1993 Ken Raeburn (raeburn@cygnus.com)
-
- Sun Oct 10 17:27:10 1993 Troy Rollo (troy@cbme.unsw.edu.au)
-
- * internal.h: Added o_sri, o_inlib and o_vid for Apollos as well
- as R_DIR16.
-
- * apollo.h: New file
-
-Mon Oct 11 17:16:48 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * ecoff.h (REGINFO, struct ecoff_reginfo): Define.
-
-Tue Oct 5 10:52:53 1993 Jim Kingdon (kingdon@lioth.cygnus.com)
-
- * rs6000.h: Change non-ASCII characters in comment to octal
- escapes.
-
-Tue Sep 28 03:27:04 1993 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
-
- * ecoff.h (_FINI, STYP_ECOFF_FINI): Add to support .fini section.
-
-Fri Sep 24 11:53:53 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * mips.h (BADMAG): Recognize MIPS_MAGIC_LITTLE3 and MIPS_MAGIC_BIG3.
- * ecoff.h: Define MIPS_MAGIC_LITTLE3 and MIPS_MAGIC_BIG3.
-
-Thu Sep 23 21:07:14 1993 Jim Kingdon (kingdon@lioth.cygnus.com)
-
- * mips.h (BADMAG): Recognize MIPS_MAGIC_LITTLE2 and MIPS_MAGIC_BIG2.
- * ecoff.h: Define MIPS_MAGIC_LITTLE2 and MIPS_MAGIC_BIG2.
-
-Thu Sep 16 20:27:21 1993 Jim Kingdon (kingdon@cirdan.cygnus.com)
-
- * sym.h, symconst.h: Add comment stating these files are not part
- of GDB, GAS, etc. In 1991, when we asked rms whether we could
- include these files in GDB (although they are copyrighted by
- someone besides the FSF), he said it was OK if they were not
- considered part of GDB.
-
-Fri Sep 10 17:40:35 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * ecoff.h (AUX_PUT_ANY): Cast val argument to bfd_vma.
-
- * alpha.c (external_aouthdr): Need four bytes of padding between
- vstamp and tsize.
-
-Tue Sep 7 14:20:43 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * ecoff.h (AUX_GET_ANY, AUX_PUT_ANY): Changed to reflect further
- change in bfd swapping routine names.
-
-Tue Sep 7 10:15:17 1993 Jim Kingdon (kingdon@lioth.cygnus.com)
-
- * ecoff.h (AUX_GET_ANY): Change name of _do_getb32 to reflect bfd
- changes.
-
-Fri Aug 13 14:30:32 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * ecoff.h (RELOC_SECTION_NONE): Define.
-
-Thu Aug 12 11:24:42 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * alpha.h (struct external_reloc): Add r_symndx field.
- (RELSZ): Correct.
- (RELOC_BITS*): Correct.
- (ALPHA_R_*): Define.
- * ecoff.h (RELOC_SECTION_{XDATA,PDATA,FINI,LITA,ABS}): Define.
- (r_extern): Undefine.
- * internal.h (struct internal_reloc): Make r_vaddr bfd_vma rather
- than long. Add r_extern field.
-
- * alpha.h (PDR_BITS*): Define.
- * sym.h (PDR): Give correct names to new fields.
-
- * ecoff.h: Moved MIPS reloc definitions from here...
- * mips.h: to here.
-
-Mon Aug 2 16:37:14 1993 Stu Grossman (grossman at cygnus.com)
-
- * i386.h: Add Lynx magic number.
-
-Tue Aug 3 11:17:53 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * alpha.h: Corrected external symbolic debugging structures to
- match actual usage.
- * internal.h (internal_filehdr, internal_aouthdr,
- internal_scnhdr): Changed type of some fields to bfd_vma so they
- can hold 64 bits.
- * sym.h (HDRR, FDR, PDR, EXTR): Likewise.
- (PDR): Added new fields found on Alpha.
- * symconst.h (magicSym2): Define; new value found on Alpha.
-
- * ecoff.h: New file.
- * alpha.h, mips.h: Moved common information into ecoff.h. Moved
- external structure definitions in from ecoff-ext.h.
- * ecoff-ext.h: Removed; information now in alpha.h and mips.h.
-
-Sun Jul 18 21:43:59 1993 Jim Kingdon (kingdon@rtl.cygnus.com)
-
- * i386.h: Recognize I386PTXMAGIC.
-
-Fri Jul 16 09:54:35 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * mips.h (MIPS_AOUT_{OZ}MAGIC): Renamed from {OZ}MAGIC.
-
-Thu Jul 15 12:23:55 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * m88k.h (union external_auxent): Move x_fcn back inside x_fcnary.
- ({GET,PUT}_FCN_{LNNOPTR,ENDNDX}): Adjust accordingly.
-
-Sun Jul 11 18:00:18 1993 Jim Kingdon (kingdon@lioth.cygnus.com)
-
- * m68k.h: Define MC68KBCSMAGIC.
-
-Thu Jun 10 11:46:28 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * mips.h (_INIT, STYP_MIPS_INIT): Define (used on Irix4).
- (STYP_OTHER_LOAD): Define as STYP_MIPS_INIT.
-
-Wed Jun 9 15:09:09 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * mips.h (OMAGIC): Define.
-
-Tue Jun 8 12:16:03 1993 Steve Chamberlain (sac@phydeaux.cygnus.com)
-
- Support for H8/300-H
- * h8300.h: New magic number.
- * internal.h: New relocations.
-
-Mon Apr 26 18:04:47 1993 Steve Chamberlain (sac@thepub.cygnus.com)
-
- * internal.h, sh.h: Support for SH.
-
-Sat Apr 24 21:34:59 1993 Jim Kingdon (kingdon@cygnus.com)
-
- * a29k.h: Define _LIT.
-
-Fri Apr 23 18:41:23 1993 Steve Chamberlain (sac@thepub.cygnus.com)
-
- * alpha.h: New file.
-
-Thu Apr 8 12:36:34 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * internal.h (C_SHADOW, C_VERSION): Copied in from m88k.h.
- * m88k.h, i386.h, we32k.h: Don't define all the storage classes;
- they're already in internal.h.
-
-Wed Apr 7 11:51:24 1993 Jim Kingdon (kingdon@cygnus.com)
-
- * internal.h: Change n_sclass to unsigned char.
- Change C_EFCN to 0xff, change RS/6000 dbx symbols
- to no longer be signed.
-
-Fri Mar 19 14:52:56 1993 Steve Chamberlain (sac@thepub.cygnus.com)
-
- * internal.h: Add H8/500 reloc types.
-
-Wed Mar 17 09:46:03 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * ecoff-ext.h (AUX_PUT_ANY): Don't use void values in branches of
- conditional expression.
-
-Thu Mar 4 14:12:06 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * ecoff-ext.h (AUX_GET_*): Rewrote to use new macro AUX_GET_ANY.
- (AUX_PUT_*): New macros corresponding to the AUX_GET macros.
- (ecoff_swap_tir_out): Added prototype.
-
- * mips.h (N_BTMASK, N_TMASK, N_BTSHFT, N_TSHIFT): Define; these
- are needed to interpret gcc debugging output.
-
-Tue Feb 9 07:43:27 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * we32k.h (BTYPE, ISPTR, ISFCN, ISARY, DECREF): Removed
- more definitions duplicated in internal.h.
-
-Wed Feb 3 09:18:24 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * mips.h (RELOC_BITS3_TYPE_*): Correct for big endian machines.
-
-Mon Jan 25 11:35:51 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * internal.h (internal_aouthdr): Added additional fields used only
- by MIPS ECOFF.
-
-Thu Jan 21 10:28:38 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * mips.h (AOUTHDR): Added additional fields used by ECOFF.
-
-Tue Jan 19 12:21:19 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * i386.h, we32k.h (N_*, T_*, DT_*): Removed still more definitions
- duplicated in internal.h.
-
- * mips.h (RELOC_SECTION_*, ECOFF_R_*): Defined constants for ECOFF
- relocs.
-
-Fri Jan 15 18:17:00 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * ecoff-ext.h: Added prototypes for new ECOFF swapping functions.
- (opt_ext): New structure.
- * mips.h (ZMAGIC): Defined to be 0413.
- (_LIB): Defined to be ".lib"
- (external_reloc): MIPS ECOFF relocs are only 8 bytes. Added
- macros to aid in swapping.
-
-Fri Jan 8 16:19:26 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * ecoff-ext.h: Added prototypes for ECOFF swapping functions.
- * internal.h (internal_scnhdr): Always provide s_align field, not
- just on i960.
- (internal_reloc): Always provide r_size field, not just on
- RS/6000.
- * mips.h (_RDATA, _SDATA, _SBSS, _LIT4, _LIT8, STYP_RDATA,
- STYP_SDATA, STYP_SBSS, STYP_LIT4, STYP_LIT8): Defined.
- (CODE_MASK, MIPS_IS_STAB, MIPS_MARK_STAB, MIPS_UNMARK_STAB,
- STABS_SYMBOL): Moved in from gdb/mipsread.c.
-
-Wed Jan 6 14:01:46 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * i386.h, we32k.h: removed STYP_* defines, since they duplicated
- those in internal.h.
-
-Tue Dec 29 15:40:07 1992 Ian Lance Taylor (ian@cygnus.com)
-
- * i386.h: define I386AIXMAGIC for Danbury AIX PS/2 compiler.
-
-Sat Dec 12 16:07:57 1992 Ian Lance Taylor (ian@cygnus.com)
-
- * i386.h: don't define BTYPE, ISPTR, ISFCN, ISARY, DECREF: they
- are defined in internal.h.
-
-Thu Nov 12 09:52:01 1992 Steve Chamberlain (sac@thepub.cygnus.com)
-
- * internal.h: (internal_reloc): r_offset is now a long.
- * z8k.h: slight comment enhancement
-
-Wed Sep 30 07:46:08 1992 Steve Chamberlain (sac@thepub.cygnus.com)
-
- * internal.h: changed z8k reloc types
-
-Fri Aug 28 10:16:31 1992 Brendan Kehoe (brendan@cygnus.com)
-
- * we32k.h: new file
-
-Thu Aug 27 13:00:01 1992 Brendan Kehoe (brendan@cygnus.com)
-
- * symconst.h: comment out cruft at the end of #endif
-
-Tue Aug 25 15:06:49 1992 Steve Chamberlain (sac@thepub.cygnus.com)
-
- * internal.h: added #define for STYP_LIT, removed from a29k and
- h8300.
-
- * z8k.h: added z8000 support
-
-Thu Jul 16 16:32:00 1992 Steve Chamberlain (sac@thepub.cygnus.com)
-
- * internal.h: added R_RELLONG_NEG reloc type
-
-Fri Jun 12 20:11:04 1992 John Gilmore (gnu at cygnus.com)
-
- * symconst.h: Fix unterminated comment.
-
-Wed Jun 10 07:57:49 1992 Steve Chamberlain (sac@thepub.cygnus.com)
-
- * i386.h: a.out magic numbers from
- mohring@informatik.tu-muenchen.de
-
-Mon Jun 8 20:13:33 1992 John Gilmore (gnu at cygnus.com)
-
- * ecoff-ext.h, mips.h: Use unsigned chars everywhere.
- (Suggested by Antti Miettinen.)
-
-Tue Apr 14 15:18:44 1992 John Gilmore (gnu at cygnus.com)
-
- * sym.h: Add comments.
- * symconst.h: Merge with Fred's changes.
-
-Tue Apr 14 14:30:05 1992 Fred Fish (fnf@cygnus.com)
-
- * symconst.h: Pick up SGI defines for stStruct, stUnion, stEnum,
- langCplusplus, and langCplusplusV2.
-
-Thu Apr 2 19:47:43 1992 John Gilmore (gnu at cygnus.com)
-
- * sym.h, symconst.h: MIPS has provided redistributable versions
- of these files. Thanks!
- * ecoff-ext.h: Add weakext bit to match new sym.h.
-
-Fri Mar 6 00:10:46 1992 John Gilmore (gnu at cygnus.com)
-
- * ecoff-ext.h: Add relative file descriptors.
-
-Thu Feb 27 11:53:04 1992 John Gilmore (gnu at cygnus.com)
-
- * ecoff-ext.h: New file for external (in-file) form of ecoff
- symbol structures.
-
-Thu Feb 6 11:33:32 1992 Steve Chamberlain (sac at rtl.cygnus.com)
-
- * h8300.h: made the external_lineno l_lnno field 4 bytes wide.
- andded GET/PUT_LINENO_LNNO macros
-
-Sat Nov 30 20:38:35 1991 Steve Chamberlain (sac at rtl.cygnus.com)
-
- * a29k.h, h8300.h, i386.h, i960.h, internal.h, m68k.h, m88k.h,
- mips.h, rs6000.h: Move from above coff-<foo>.h.
+For older changes see ChangeLog-9103
Local Variables:
+mode: change-log
+left-margin: 8
+fill-column: 74
version-control: never
End:
diff --git a/contrib/binutils/include/coff/arm.h b/contrib/binutils/include/coff/arm.h
index bcfdcbe..8b90228 100644
--- a/contrib/binutils/include/coff/arm.h
+++ b/contrib/binutils/include/coff/arm.h
@@ -124,3 +124,5 @@ struct external_reloc
#define RELOC struct external_reloc
#define RELSZ 14
#endif
+
+#define ARM_NOTE_SECTION ".note"
diff --git a/contrib/binutils/include/coff/ecoff.h b/contrib/binutils/include/coff/ecoff.h
index 076fdf5..3a7aa4f 100644
--- a/contrib/binutils/include/coff/ecoff.h
+++ b/contrib/binutils/include/coff/ecoff.h
@@ -2,22 +2,22 @@
This does not include symbol information, found in sym.h and
symconst.h.
- Copyright 2001 Free Software Foundation, Inc.
+ Copyright 2001, 2002, 2003 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
-
+
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
-
+
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-
+
#ifndef ECOFF_H
#define ECOFF_H
@@ -296,21 +296,21 @@ struct ecoff_debug_info
fields are also used by the assembler to output ECOFF debugging
information. */
unsigned char *line;
- PTR external_dnr; /* struct dnr_ext */
- PTR external_pdr; /* struct pdr_ext */
- PTR external_sym; /* struct sym_ext */
- PTR external_opt; /* struct opt_ext */
+ void *external_dnr; /* struct dnr_ext */
+ void *external_pdr; /* struct pdr_ext */
+ void *external_sym; /* struct sym_ext */
+ void *external_opt; /* struct opt_ext */
union aux_ext *external_aux;
char *ss;
char *ssext;
- PTR external_fdr; /* struct fdr_ext */
- PTR external_rfd; /* struct rfd_ext */
- PTR external_ext; /* struct ext_ext */
+ void *external_fdr; /* struct fdr_ext */
+ void *external_rfd; /* struct rfd_ext */
+ void *external_ext; /* struct ext_ext */
/* These fields are used when linking. They may disappear at some
point. */
char *ssext_end;
- PTR external_ext_end;
+ void *external_ext_end;
/* When linking, this field holds a mapping from the input FDR
numbers to the output numbers, and is used when writing out the
@@ -406,32 +406,31 @@ struct ecoff_debug_swap
bfd_size_type external_rfd_size;
bfd_size_type external_ext_size;
/* Functions to swap in external symbolic data. */
- void (*swap_hdr_in) PARAMS ((bfd *, PTR, HDRR *));
- void (*swap_dnr_in) PARAMS ((bfd *, PTR, DNR *));
- void (*swap_pdr_in) PARAMS ((bfd *, PTR, PDR *));
- void (*swap_sym_in) PARAMS ((bfd *, PTR, SYMR *));
- void (*swap_opt_in) PARAMS ((bfd *, PTR, OPTR *));
- void (*swap_fdr_in) PARAMS ((bfd *, PTR, FDR *));
- void (*swap_rfd_in) PARAMS ((bfd *, PTR, RFDT *));
- void (*swap_ext_in) PARAMS ((bfd *, PTR, EXTR *));
- void (*swap_tir_in) PARAMS ((int, const struct tir_ext *, TIR *));
- void (*swap_rndx_in) PARAMS ((int, const struct rndx_ext *, RNDXR *));
+ void (*swap_hdr_in) (bfd *, void *, HDRR *);
+ void (*swap_dnr_in) (bfd *, void *, DNR *);
+ void (*swap_pdr_in) (bfd *, void *, PDR *);
+ void (*swap_sym_in) (bfd *, void *, SYMR *);
+ void (*swap_opt_in) (bfd *, void *, OPTR *);
+ void (*swap_fdr_in) (bfd *, void *, FDR *);
+ void (*swap_rfd_in) (bfd *, void *, RFDT *);
+ void (*swap_ext_in) (bfd *, void *, EXTR *);
+ void (*swap_tir_in) (int, const struct tir_ext *, TIR *);
+ void (*swap_rndx_in) (int, const struct rndx_ext *, RNDXR *);
/* Functions to swap out external symbolic data. */
- void (*swap_hdr_out) PARAMS ((bfd *, const HDRR *, PTR));
- void (*swap_dnr_out) PARAMS ((bfd *, const DNR *, PTR));
- void (*swap_pdr_out) PARAMS ((bfd *, const PDR *, PTR));
- void (*swap_sym_out) PARAMS ((bfd *, const SYMR *, PTR));
- void (*swap_opt_out) PARAMS ((bfd *, const OPTR *, PTR));
- void (*swap_fdr_out) PARAMS ((bfd *, const FDR *, PTR));
- void (*swap_rfd_out) PARAMS ((bfd *, const RFDT *, PTR));
- void (*swap_ext_out) PARAMS ((bfd *, const EXTR *, PTR));
- void (*swap_tir_out) PARAMS ((int, const TIR *, struct tir_ext *));
- void (*swap_rndx_out) PARAMS ((int, const RNDXR *, struct rndx_ext *));
+ void (*swap_hdr_out) (bfd *, const HDRR *, void *);
+ void (*swap_dnr_out) (bfd *, const DNR *, void *);
+ void (*swap_pdr_out) (bfd *, const PDR *, void *);
+ void (*swap_sym_out) (bfd *, const SYMR *, void *);
+ void (*swap_opt_out) (bfd *, const OPTR *, void *);
+ void (*swap_fdr_out) (bfd *, const FDR *, void *);
+ void (*swap_rfd_out) (bfd *, const RFDT *, void *);
+ void (*swap_ext_out) (bfd *, const EXTR *, void *);
+ void (*swap_tir_out) (int, const TIR *, struct tir_ext *);
+ void (*swap_rndx_out) (int, const RNDXR *, struct rndx_ext *);
/* Function to read symbol data and set up pointers in
ecoff_debug_info structure. The section argument is used for
ELF, not straight ECOFF. */
- boolean (*read_debug_info) PARAMS ((bfd *, asection *,
- struct ecoff_debug_info *));
+ bfd_boolean (*read_debug_info) (bfd *, asection *, struct ecoff_debug_info *);
};
#endif /* ! defined (ECOFF_H) */
diff --git a/contrib/binutils/include/coff/internal.h b/contrib/binutils/include/coff/internal.h
index 4babbd4..2d41bf9 100644
--- a/contrib/binutils/include/coff/internal.h
+++ b/contrib/binutils/include/coff/internal.h
@@ -235,7 +235,11 @@ struct internal_aouthdr
#define C_ALIAS 105 /* duplicate tag */
#define C_HIDDEN 106 /* ext symbol in dmert public lib */
-#define C_WEAKEXT 127 /* weak symbol -- GNU extension */
+#if defined _AIX52 || defined AIX_WEAK_SUPPORT
+#define C_WEAKEXT 111 /* weak symbol -- AIX standard. */
+#else
+#define C_WEAKEXT 127 /* weak symbol -- GNU extension. */
+#endif
/* New storage classes for TI COFF */
#define C_UEXT 19 /* Tentative external definition */
@@ -600,6 +604,7 @@ struct internal_reloc
};
#define R_DIR16 1
+#define R_REL24 5
#define R_DIR32 6
#define R_IMAGEBASE 7
#define R_RELBYTE 15
@@ -608,12 +613,15 @@ struct internal_reloc
#define R_PCRBYTE 18
#define R_PCRWORD 19
#define R_PCRLONG 20
+#define R_PCR24 21
#define R_IPRSHORT 24
#define R_IPRLONG 26
#define R_GETSEG 29
#define R_GETPA 30
#define R_TAGWORD 31
#define R_JUMPTARG 32 /* strange 29k 00xx00xx reloc */
+#define R_PARTLS16 32
+#define R_PARTMS8 33
#define R_PCR16L 128
#define R_PCR26L 129
diff --git a/contrib/binutils/include/coff/pe.h b/contrib/binutils/include/coff/pe.h
index ff37875..363d307 100644
--- a/contrib/binutils/include/coff/pe.h
+++ b/contrib/binutils/include/coff/pe.h
@@ -1,6 +1,6 @@
/* pe.h - PE COFF header information
- Copyright 2000, 2001 Free Software Foundation, Inc.
+ Copyright 2000, 2001, 2003 Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -32,6 +32,7 @@
#define IMAGE_FILE_32BIT_MACHINE 0x0100
#define IMAGE_FILE_DEBUG_STRIPPED 0x0200
#define IMAGE_FILE_REMOVABLE_RUN_FROM_SWAP 0x0400
+#define IMAGE_FILE_NET_RUN_FROM_SWAP 0x0800
#define IMAGE_FILE_SYSTEM 0x1000
#define IMAGE_FILE_DLL 0x2000
#define IMAGE_FILE_UP_SYSTEM_ONLY 0x4000
@@ -88,24 +89,37 @@
/* Machine numbers. */
-#define IMAGE_FILE_MACHINE_UNKNOWN 0x0
-#define IMAGE_FILE_MACHINE_ALPHA 0x184
-#define IMAGE_FILE_MACHINE_ARM 0x1c0
-#define IMAGE_FILE_MACHINE_ALPHA64 0x284
-#define IMAGE_FILE_MACHINE_I386 0x14c
-#define IMAGE_FILE_MACHINE_IA64 0x200
-#define IMAGE_FILE_MACHINE_M68K 0x268
-#define IMAGE_FILE_MACHINE_MIPS16 0x266
-#define IMAGE_FILE_MACHINE_MIPSFPU 0x366
-#define IMAGE_FILE_MACHINE_MIPSFPU16 0x466
-#define IMAGE_FILE_MACHINE_POWERPC 0x1f0
-#define IMAGE_FILE_MACHINE_R3000 0x162
-#define IMAGE_FILE_MACHINE_R4000 0x166
-#define IMAGE_FILE_MACHINE_R10000 0x168
-#define IMAGE_FILE_MACHINE_SH3 0x1a2
-#define IMAGE_FILE_MACHINE_SH4 0x1a6
-#define IMAGE_FILE_MACHINE_THUMB 0x1c2
-
+#define IMAGE_FILE_MACHINE_UNKNOWN 0x0000
+#define IMAGE_FILE_MACHINE_ALPHA 0x0184
+#define IMAGE_FILE_MACHINE_ALPHA64 0x0284
+#define IMAGE_FILE_MACHINE_AM33 0x01d3
+#define IMAGE_FILE_MACHINE_AMD64 0x8664
+#define IMAGE_FILE_MACHINE_ARM 0x01c0
+#define IMAGE_FILE_MACHINE_AXP64 IMAGE_FILE_MACHINE_ALPHA64
+#define IMAGE_FILE_MACHINE_CEE 0xc0ee
+#define IMAGE_FILE_MACHINE_CEF 0x0cef
+#define IMAGE_FILE_MACHINE_EBC 0x0ebc
+#define IMAGE_FILE_MACHINE_I386 0x014c
+#define IMAGE_FILE_MACHINE_IA64 0x0200
+#define IMAGE_FILE_MACHINE_M32R 0x9041
+#define IMAGE_FILE_MACHINE_M68K 0x0268
+#define IMAGE_FILE_MACHINE_MIPS16 0x0266
+#define IMAGE_FILE_MACHINE_MIPSFPU 0x0366
+#define IMAGE_FILE_MACHINE_MIPSFPU16 0x0466
+#define IMAGE_FILE_MACHINE_POWERPC 0x01f0
+#define IMAGE_FILE_MACHINE_POWERPCFP 0x01f1
+#define IMAGE_FILE_MACHINE_R10000 0x0168
+#define IMAGE_FILE_MACHINE_R3000 0x0162
+#define IMAGE_FILE_MACHINE_R4000 0x0166
+#define IMAGE_FILE_MACHINE_SH3 0x01a2
+#define IMAGE_FILE_MACHINE_SH3DSP 0x01a3
+#define IMAGE_FILE_MACHINE_SH3E 0x01a4
+#define IMAGE_FILE_MACHINE_SH4 0x01a6
+#define IMAGE_FILE_MACHINE_SH5 0x01a8
+#define IMAGE_FILE_MACHINE_THUMB 0x01c2
+#define IMAGE_FILE_MACHINE_TRICORE 0x0520
+#define IMAGE_FILE_MACHINE_WCEMIPSV2 0x0169
+
#define IMAGE_SUBSYSTEM_UNKNOWN 0
#define IMAGE_SUBSYSTEM_NATIVE 1
#define IMAGE_SUBSYSTEM_WINDOWS_GUI 2
diff --git a/contrib/binutils/include/coff/sh.h b/contrib/binutils/include/coff/sh.h
index c77316e..d20834c 100644
--- a/contrib/binutils/include/coff/sh.h
+++ b/contrib/binutils/include/coff/sh.h
@@ -1,6 +1,6 @@
-/* coff information for Hitachi SH
+/* coff information for Renesas SH
- Copyright 2001 Free Software Foundation, Inc.
+ Copyright 2001, 2003 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
diff --git a/contrib/binutils/include/coff/ti.h b/contrib/binutils/include/coff/ti.h
index d98fc89..a15fe71 100644
--- a/contrib/binutils/include/coff/ti.h
+++ b/contrib/binutils/include/coff/ti.h
@@ -2,7 +2,7 @@
customized in a target-specific file, and then this file included (see
tic54x.h for an example).
- Copyright 2001 Free Software Foundation, Inc.
+ Copyright 2001, 2003 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -57,6 +57,14 @@ struct external_filehdr
#error "TICOFF_TARGET_ARCH needs to be defined for your CPU"
#endif
+#ifndef TICOFF_TARGET_MACHINE_GET
+#define TICOFF_TARGET_MACHINE_GET(FLAGS) 0
+#endif
+
+#ifndef TICOFF_TARGET_MACHINE_SET
+#define TICOFF_TARGET_MACHINE_SET(FLAGSP, MACHINE)
+#endif
+
/* Default to COFF2 for file output */
#ifndef TICOFF_DEFAULT_MAGIC
#define TICOFF_DEFAULT_MAGIC TICOFF2MAGIC
@@ -118,6 +126,7 @@ struct external_filehdr
#define F_RELFLG (0x0001)
#define F_EXEC (0x0002)
#define F_LNNO (0x0004)
+#define F_VERS (0x0010) /* TMS320C4x code */
/* F_LSYMS needs to be redefined in your source file */
#define F_LSYMS_TICOFF (0x0010) /* normal COFF is 0x8 */
@@ -206,25 +215,25 @@ struct external_scnhdr {
Assume we're dealing with the COFF2 scnhdr structure, and adjust
accordingly
*/
-#define GET_SCNHDR_NRELOC(ABFD, PTR) \
- (COFF2_P (ABFD) ? H_GET_32 (ABFD, PTR) : H_GET_16 (ABFD, PTR))
-#define PUT_SCNHDR_NRELOC(ABFD, VAL, PTR) \
- (COFF2_P (ABFD) ? H_PUT_32 (ABFD, VAL, PTR) : H_PUT_16 (ABFD, VAL, PTR))
-#define GET_SCNHDR_NLNNO(ABFD, PTR) \
- (COFF2_P (ABFD) ? H_GET_32 (ABFD, PTR) : H_GET_16 (ABFD, (PTR) -2))
-#define PUT_SCNHDR_NLNNO(ABFD, VAL, PTR) \
- (COFF2_P (ABFD) ? H_PUT_32 (ABFD, VAL, PTR) : H_PUT_16 (ABFD, VAL, (PTR) -2))
-#define GET_SCNHDR_FLAGS(ABFD, PTR) \
- (COFF2_P (ABFD) ? H_GET_32 (ABFD, PTR) : H_GET_16 (ABFD, (PTR) -4))
-#define PUT_SCNHDR_FLAGS(ABFD, VAL, PTR) \
- (COFF2_P (ABFD) ? H_PUT_32 (ABFD, VAL, PTR) : H_PUT_16 (ABFD, VAL, (PTR) -4))
-#define GET_SCNHDR_PAGE(ABFD, PTR) \
- (COFF2_P (ABFD) ? H_GET_16 (ABFD, PTR) : (unsigned) H_GET_8 (ABFD, (PTR) -7))
+#define GET_SCNHDR_NRELOC(ABFD, LOC) \
+ (COFF2_P (ABFD) ? H_GET_32 (ABFD, LOC) : H_GET_16 (ABFD, LOC))
+#define PUT_SCNHDR_NRELOC(ABFD, VAL, LOC) \
+ (COFF2_P (ABFD) ? H_PUT_32 (ABFD, VAL, LOC) : H_PUT_16 (ABFD, VAL, LOC))
+#define GET_SCNHDR_NLNNO(ABFD, LOC) \
+ (COFF2_P (ABFD) ? H_GET_32 (ABFD, LOC) : H_GET_16 (ABFD, (LOC) - 2))
+#define PUT_SCNHDR_NLNNO(ABFD, VAL, LOC) \
+ (COFF2_P (ABFD) ? H_PUT_32 (ABFD, VAL, LOC) : H_PUT_16 (ABFD, VAL, (LOC) - 2))
+#define GET_SCNHDR_FLAGS(ABFD, LOC) \
+ (COFF2_P (ABFD) ? H_GET_32 (ABFD, LOC) : H_GET_16 (ABFD, (LOC) - 4))
+#define PUT_SCNHDR_FLAGS(ABFD, VAL, LOC) \
+ (COFF2_P (ABFD) ? H_PUT_32 (ABFD, VAL, LOC) : H_PUT_16 (ABFD, VAL, (LOC) - 4))
+#define GET_SCNHDR_PAGE(ABFD, LOC) \
+ (COFF2_P (ABFD) ? H_GET_16 (ABFD, LOC) : (unsigned) H_GET_8 (ABFD, (LOC) - 7))
/* on output, make sure that the "reserved" field is zero */
-#define PUT_SCNHDR_PAGE(ABFD, VAL, PTR) \
+#define PUT_SCNHDR_PAGE(ABFD, VAL, LOC) \
(COFF2_P (ABFD) \
- ? H_PUT_16 (ABFD, VAL, PTR) \
- : H_PUT_8 (ABFD, VAL, (PTR) -7), H_PUT_8 (ABFD, 0, (PTR) -8))
+ ? H_PUT_16 (ABFD, VAL, LOC) \
+ : H_PUT_8 (ABFD, VAL, (LOC) - 7), H_PUT_8 (ABFD, 0, (LOC) - 8))
/* TI COFF stores section size as number of bytes (address units, not octets),
so adjust to be number of octets, which is what BFD expects */
diff --git a/contrib/binutils/include/demangle.h b/contrib/binutils/include/demangle.h
index 21e9dd3..6e995e4 100644
--- a/contrib/binutils/include/demangle.h
+++ b/contrib/binutils/include/demangle.h
@@ -1,6 +1,6 @@
/* Defs for interface to demanglers.
- Copyright 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000, 2001, 2002
- Free Software Foundation, Inc.
+ Copyright 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000, 2001, 2002,
+ 2003, 2004 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -21,7 +21,11 @@
#if !defined (DEMANGLE_H)
#define DEMANGLE_H
-#include "ansidecl.h"
+#include "libiberty.h"
+
+#ifdef __cplusplus
+extern "C" {
+#endif /* __cplusplus */
/* Options passed to cplus_demangle (in 2nd parameter). */
@@ -160,4 +164,370 @@ enum gnu_v3_dtor_kinds {
extern enum gnu_v3_dtor_kinds
is_gnu_v3_mangled_dtor PARAMS ((const char *name));
+/* The V3 demangler works in two passes. The first pass builds a tree
+ representation of the mangled name, and the second pass turns the
+ tree representation into a demangled string. Here we define an
+ interface to permit a caller to build their own tree
+ representation, which they can pass to the demangler to get a
+ demangled string. This can be used to canonicalize user input into
+ something which the demangler might output. It could also be used
+ by other demanglers in the future. */
+
+/* These are the component types which may be found in the tree. Many
+ component types have one or two subtrees, referred to as left and
+ right (a component type with only one subtree puts it in the left
+ subtree). */
+
+enum demangle_component_type
+{
+ /* A name, with a length and a pointer to a string. */
+ DEMANGLE_COMPONENT_NAME,
+ /* A qualified name. The left subtree is a class or namespace or
+ some such thing, and the right subtree is a name qualified by
+ that class. */
+ DEMANGLE_COMPONENT_QUAL_NAME,
+ /* A local name. The left subtree describes a function, and the
+ right subtree is a name which is local to that function. */
+ DEMANGLE_COMPONENT_LOCAL_NAME,
+ /* A typed name. The left subtree is a name, and the right subtree
+ describes that name as a function. */
+ DEMANGLE_COMPONENT_TYPED_NAME,
+ /* A template. The left subtree is a template name, and the right
+ subtree is a template argument list. */
+ DEMANGLE_COMPONENT_TEMPLATE,
+ /* A template parameter. This holds a number, which is the template
+ parameter index. */
+ DEMANGLE_COMPONENT_TEMPLATE_PARAM,
+ /* A constructor. This holds a name and the kind of
+ constructor. */
+ DEMANGLE_COMPONENT_CTOR,
+ /* A destructor. This holds a name and the kind of destructor. */
+ DEMANGLE_COMPONENT_DTOR,
+ /* A vtable. This has one subtree, the type for which this is a
+ vtable. */
+ DEMANGLE_COMPONENT_VTABLE,
+ /* A VTT structure. This has one subtree, the type for which this
+ is a VTT. */
+ DEMANGLE_COMPONENT_VTT,
+ /* A construction vtable. The left subtree is the type for which
+ this is a vtable, and the right subtree is the derived type for
+ which this vtable is built. */
+ DEMANGLE_COMPONENT_CONSTRUCTION_VTABLE,
+ /* A typeinfo structure. This has one subtree, the type for which
+ this is the tpeinfo structure. */
+ DEMANGLE_COMPONENT_TYPEINFO,
+ /* A typeinfo name. This has one subtree, the type for which this
+ is the typeinfo name. */
+ DEMANGLE_COMPONENT_TYPEINFO_NAME,
+ /* A typeinfo function. This has one subtree, the type for which
+ this is the tpyeinfo function. */
+ DEMANGLE_COMPONENT_TYPEINFO_FN,
+ /* A thunk. This has one subtree, the name for which this is a
+ thunk. */
+ DEMANGLE_COMPONENT_THUNK,
+ /* A virtual thunk. This has one subtree, the name for which this
+ is a virtual thunk. */
+ DEMANGLE_COMPONENT_VIRTUAL_THUNK,
+ /* A covariant thunk. This has one subtree, the name for which this
+ is a covariant thunk. */
+ DEMANGLE_COMPONENT_COVARIANT_THUNK,
+ /* A Java class. This has one subtree, the type. */
+ DEMANGLE_COMPONENT_JAVA_CLASS,
+ /* A guard variable. This has one subtree, the name for which this
+ is a guard variable. */
+ DEMANGLE_COMPONENT_GUARD,
+ /* A reference temporary. This has one subtree, the name for which
+ this is a temporary. */
+ DEMANGLE_COMPONENT_REFTEMP,
+ /* A standard substitution. This holds the name of the
+ substitution. */
+ DEMANGLE_COMPONENT_SUB_STD,
+ /* The restrict qualifier. The one subtree is the type which is
+ being qualified. */
+ DEMANGLE_COMPONENT_RESTRICT,
+ /* The volatile qualifier. The one subtree is the type which is
+ being qualified. */
+ DEMANGLE_COMPONENT_VOLATILE,
+ /* The const qualifier. The one subtree is the type which is being
+ qualified. */
+ DEMANGLE_COMPONENT_CONST,
+ /* The restrict qualifier modifying a member function. The one
+ subtree is the type which is being qualified. */
+ DEMANGLE_COMPONENT_RESTRICT_THIS,
+ /* The volatile qualifier modifying a member function. The one
+ subtree is the type which is being qualified. */
+ DEMANGLE_COMPONENT_VOLATILE_THIS,
+ /* The const qualifier modifying a member function. The one subtree
+ is the type which is being qualified. */
+ DEMANGLE_COMPONENT_CONST_THIS,
+ /* A vendor qualifier. The left subtree is the type which is being
+ qualified, and the right subtree is the name of the
+ qualifier. */
+ DEMANGLE_COMPONENT_VENDOR_TYPE_QUAL,
+ /* A pointer. The one subtree is the type which is being pointed
+ to. */
+ DEMANGLE_COMPONENT_POINTER,
+ /* A reference. The one subtree is the type which is being
+ referenced. */
+ DEMANGLE_COMPONENT_REFERENCE,
+ /* A complex type. The one subtree is the base type. */
+ DEMANGLE_COMPONENT_COMPLEX,
+ /* An imaginary type. The one subtree is the base type. */
+ DEMANGLE_COMPONENT_IMAGINARY,
+ /* A builtin type. This holds the builtin type information. */
+ DEMANGLE_COMPONENT_BUILTIN_TYPE,
+ /* A vendor's builtin type. This holds the name of the type. */
+ DEMANGLE_COMPONENT_VENDOR_TYPE,
+ /* A function type. The left subtree is the return type. The right
+ subtree is a list of ARGLIST nodes. Either or both may be
+ NULL. */
+ DEMANGLE_COMPONENT_FUNCTION_TYPE,
+ /* An array type. The left subtree is the dimension, which may be
+ NULL, or a string (represented as DEMANGLE_COMPONENT_NAME), or an
+ expression. The right subtree is the element type. */
+ DEMANGLE_COMPONENT_ARRAY_TYPE,
+ /* A pointer to member type. The left subtree is the class type,
+ and the right subtree is the member type. CV-qualifiers appear
+ on the latter. */
+ DEMANGLE_COMPONENT_PTRMEM_TYPE,
+ /* An argument list. The left subtree is the current argument, and
+ the right subtree is either NULL or another ARGLIST node. */
+ DEMANGLE_COMPONENT_ARGLIST,
+ /* A template argument list. The left subtree is the current
+ template argument, and the right subtree is either NULL or
+ another TEMPLATE_ARGLIST node. */
+ DEMANGLE_COMPONENT_TEMPLATE_ARGLIST,
+ /* An operator. This holds information about a standard
+ operator. */
+ DEMANGLE_COMPONENT_OPERATOR,
+ /* An extended operator. This holds the number of arguments, and
+ the name of the extended operator. */
+ DEMANGLE_COMPONENT_EXTENDED_OPERATOR,
+ /* A typecast, represented as a unary operator. The one subtree is
+ the type to which the argument should be cast. */
+ DEMANGLE_COMPONENT_CAST,
+ /* A unary expression. The left subtree is the operator, and the
+ right subtree is the single argument. */
+ DEMANGLE_COMPONENT_UNARY,
+ /* A binary expression. The left subtree is the operator, and the
+ right subtree is a BINARY_ARGS. */
+ DEMANGLE_COMPONENT_BINARY,
+ /* Arguments to a binary expression. The left subtree is the first
+ argument, and the right subtree is the second argument. */
+ DEMANGLE_COMPONENT_BINARY_ARGS,
+ /* A trinary expression. The left subtree is the operator, and the
+ right subtree is a TRINARY_ARG1. */
+ DEMANGLE_COMPONENT_TRINARY,
+ /* Arguments to a trinary expression. The left subtree is the first
+ argument, and the right subtree is a TRINARY_ARG2. */
+ DEMANGLE_COMPONENT_TRINARY_ARG1,
+ /* More arguments to a trinary expression. The left subtree is the
+ second argument, and the right subtree is the third argument. */
+ DEMANGLE_COMPONENT_TRINARY_ARG2,
+ /* A literal. The left subtree is the type, and the right subtree
+ is the value, represented as a DEMANGLE_COMPONENT_NAME. */
+ DEMANGLE_COMPONENT_LITERAL,
+ /* A negative literal. Like LITERAL, but the value is negated.
+ This is a minor hack: the NAME used for LITERAL points directly
+ to the mangled string, but since negative numbers are mangled
+ using 'n' instead of '-', we want a way to indicate a negative
+ number which involves neither modifying the mangled string nor
+ allocating a new copy of the literal in memory. */
+ DEMANGLE_COMPONENT_LITERAL_NEG
+};
+
+/* Types which are only used internally. */
+
+struct demangle_operator_info;
+struct demangle_builtin_type_info;
+
+/* A node in the tree representation is an instance of a struct
+ demangle_component. Note that the field names of the struct are
+ not well protected against macros defined by the file including
+ this one. We can fix this if it ever becomes a problem. */
+
+struct demangle_component
+{
+ /* The type of this component. */
+ enum demangle_component_type type;
+
+ union
+ {
+ /* For DEMANGLE_COMPONENT_NAME. */
+ struct
+ {
+ /* A pointer to the name (which need not NULL terminated) and
+ its length. */
+ const char *s;
+ int len;
+ } s_name;
+
+ /* For DEMANGLE_COMPONENT_OPERATOR. */
+ struct
+ {
+ /* Operator. */
+ const struct demangle_operator_info *op;
+ } s_operator;
+
+ /* For DEMANGLE_COMPONENT_EXTENDED_OPERATOR. */
+ struct
+ {
+ /* Number of arguments. */
+ int args;
+ /* Name. */
+ struct demangle_component *name;
+ } s_extended_operator;
+
+ /* For DEMANGLE_COMPONENT_CTOR. */
+ struct
+ {
+ /* Kind of constructor. */
+ enum gnu_v3_ctor_kinds kind;
+ /* Name. */
+ struct demangle_component *name;
+ } s_ctor;
+
+ /* For DEMANGLE_COMPONENT_DTOR. */
+ struct
+ {
+ /* Kind of destructor. */
+ enum gnu_v3_dtor_kinds kind;
+ /* Name. */
+ struct demangle_component *name;
+ } s_dtor;
+
+ /* For DEMANGLE_COMPONENT_BUILTIN_TYPE. */
+ struct
+ {
+ /* Builtin type. */
+ const struct demangle_builtin_type_info *type;
+ } s_builtin;
+
+ /* For DEMANGLE_COMPONENT_SUB_STD. */
+ struct
+ {
+ /* Standard substitution string. */
+ const char* string;
+ /* Length of string. */
+ int len;
+ } s_string;
+
+ /* For DEMANGLE_COMPONENT_TEMPLATE_PARAM. */
+ struct
+ {
+ /* Template parameter index. */
+ long number;
+ } s_number;
+
+ /* For other types. */
+ struct
+ {
+ /* Left (or only) subtree. */
+ struct demangle_component *left;
+ /* Right subtree. */
+ struct demangle_component *right;
+ } s_binary;
+
+ } u;
+};
+
+/* People building mangled trees are expected to allocate instances of
+ struct demangle_component themselves. They can then call one of
+ the following functions to fill them in. */
+
+/* Fill in most component types with a left subtree and a right
+ subtree. Returns non-zero on success, zero on failure, such as an
+ unrecognized or inappropriate component type. */
+
+extern int
+cplus_demangle_fill_component PARAMS ((struct demangle_component *fill,
+ enum demangle_component_type,
+ struct demangle_component *left,
+ struct demangle_component *right));
+
+/* Fill in a DEMANGLE_COMPONENT_NAME. Returns non-zero on success,
+ zero for bad arguments. */
+
+extern int
+cplus_demangle_fill_name PARAMS ((struct demangle_component *fill,
+ const char *, int));
+
+/* Fill in a DEMANGLE_COMPONENT_BUILTIN_TYPE, using the name of the
+ builtin type (e.g., "int", etc.). Returns non-zero on success,
+ zero if the type is not recognized. */
+
+extern int
+cplus_demangle_fill_builtin_type PARAMS ((struct demangle_component *fill,
+ const char *typename));
+
+/* Fill in a DEMANGLE_COMPONENT_OPERATOR, using the name of the
+ operator and the number of arguments which it takes (the latter is
+ used to disambiguate operators which can be both binary and unary,
+ such as '-'). Returns non-zero on success, zero if the operator is
+ not recognized. */
+
+extern int
+cplus_demangle_fill_operator PARAMS ((struct demangle_component *fill,
+ const char *opname, int args));
+
+/* Fill in a DEMANGLE_COMPONENT_EXTENDED_OPERATOR, providing the
+ number of arguments and the name. Returns non-zero on success,
+ zero for bad arguments. */
+
+extern int
+cplus_demangle_fill_extended_operator PARAMS ((struct demangle_component *fill,
+ int numargs,
+ struct demangle_component *nm));
+
+/* Fill in a DEMANGLE_COMPONENT_CTOR. Returns non-zero on success,
+ zero for bad arguments. */
+
+extern int
+cplus_demangle_fill_ctor PARAMS ((struct demangle_component *fill,
+ enum gnu_v3_ctor_kinds kind,
+ struct demangle_component *name));
+
+/* Fill in a DEMANGLE_COMPONENT_DTOR. Returns non-zero on success,
+ zero for bad arguments. */
+
+extern int
+cplus_demangle_fill_dtor PARAMS ((struct demangle_component *fill,
+ enum gnu_v3_dtor_kinds kind,
+ struct demangle_component *name));
+
+/* This function translates a mangled name into a struct
+ demangle_component tree. The first argument is the mangled name.
+ The second argument is DMGL_* options. This returns a pointer to a
+ tree on success, or NULL on failure. On success, the third
+ argument is set to a block of memory allocated by malloc. This
+ block should be passed to free when the tree is no longer
+ needed. */
+
+extern struct demangle_component *
+cplus_demangle_v3_components PARAMS ((const char *mangled,
+ int options,
+ void **mem));
+
+/* This function takes a struct demangle_component tree and returns
+ the corresponding demangled string. The first argument is DMGL_*
+ options. The second is the tree to demangle. The third is a guess
+ at the length of the demangled string, used to initially allocate
+ the return buffer. The fourth is a pointer to a size_t. On
+ success, this function returns a buffer allocated by malloc(), and
+ sets the size_t pointed to by the fourth argument to the size of
+ the allocated buffer (not the length of the returned string). On
+ failure, this function returns NULL, and sets the size_t pointed to
+ by the fourth argument to 0 for an invalid tree, or to 1 for a
+ memory allocation error. */
+
+extern char *
+cplus_demangle_print PARAMS ((int options,
+ const struct demangle_component *tree,
+ int estimated_length,
+ size_t *p_allocated_size));
+
+#ifdef __cplusplus
+}
+#endif /* __cplusplus */
+
#endif /* DEMANGLE_H */
diff --git a/contrib/binutils/include/dis-asm.h b/contrib/binutils/include/dis-asm.h
index fa72608..3670c51 100644
--- a/contrib/binutils/include/dis-asm.h
+++ b/contrib/binutils/include/dis-asm.h
@@ -1,6 +1,6 @@
/* Interface between the opcode library and its callers.
- Copyright 2001, 2002 Free Software Foundation, Inc.
+ Copyright 2001, 2002, 2003 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -34,7 +34,7 @@ extern "C" {
#include <stdio.h>
#include "bfd.h"
-typedef int (*fprintf_ftype) PARAMS((PTR, const char*, ...));
+typedef int (*fprintf_ftype) (void *, const char*, ...);
enum dis_insn_type {
dis_noninsn, /* Not a valid instruction */
@@ -59,8 +59,8 @@ enum dis_insn_type {
typedef struct disassemble_info {
fprintf_ftype fprintf_func;
- PTR stream;
- PTR application_data;
+ void *stream;
+ void *application_data;
/* Target description. We could replace this with a pointer to the bfd,
but that would require one. There currently isn't any such requirement
@@ -98,7 +98,7 @@ typedef struct disassemble_info {
The bottom 16 bits are for the internal use of the disassembler. */
unsigned long flags;
#define INSN_HAS_RELOC 0x80000000
- PTR private_data;
+ void *private_data;
/* Function used to get bytes to disassemble. MEMADDR is the
address of the stuff to be disassembled, MYADDR is the address to
@@ -106,19 +106,19 @@ typedef struct disassemble_info {
INFO is a pointer to this struct.
Returns an errno value or 0 for success. */
int (*read_memory_func)
- PARAMS ((bfd_vma memaddr, bfd_byte *myaddr, unsigned int length,
- struct disassemble_info *info));
+ (bfd_vma memaddr, bfd_byte *myaddr, unsigned int length,
+ struct disassemble_info *info);
/* Function which should be called if we get an error that we can't
recover from. STATUS is the errno value from read_memory_func and
MEMADDR is the address that we were trying to read. INFO is a
pointer to this struct. */
void (*memory_error_func)
- PARAMS ((int status, bfd_vma memaddr, struct disassemble_info *info));
+ (int status, bfd_vma memaddr, struct disassemble_info *info);
/* Function called to print ADDR. */
void (*print_address_func)
- PARAMS ((bfd_vma addr, struct disassemble_info *info));
+ (bfd_vma addr, struct disassemble_info *info);
/* Function called to determine if there is a symbol at the given ADDR.
If there is, the function returns 1, otherwise it returns 0.
@@ -128,8 +128,14 @@ typedef struct disassemble_info {
address, (normally because there is a symbol associated with
that address), but sometimes we want to mask out the overlay bits. */
int (* symbol_at_address_func)
- PARAMS ((bfd_vma addr, struct disassemble_info * info));
-
+ (bfd_vma addr, struct disassemble_info * info);
+
+ /* Function called to check if a SYMBOL is can be displayed to the user.
+ This is used by some ports that want to hide special symbols when
+ displaying debugging outout. */
+ bfd_boolean (* symbol_is_valid)
+ (asymbol *, struct disassemble_info * info);
+
/* These are for buffer_read_memory. */
bfd_byte *buffer;
bfd_vma buffer_vma;
@@ -141,7 +147,7 @@ typedef struct disassemble_info {
the same value in order to get reasonable looking output. */
int bytes_per_line;
- /* the next two variables control the way objdump displays the raw data */
+ /* The next two variables control the way objdump displays the raw data. */
/* For example, if bytes_per_line is 8 and bytes_per_chunk is 4, the */
/* output will look like this:
00: 00000000 00000000
@@ -177,82 +183,92 @@ typedef struct disassemble_info {
/* Standard disassemblers. Disassemble one instruction at the given
target address. Return number of octets processed. */
-typedef int (*disassembler_ftype)
- PARAMS((bfd_vma, disassemble_info *));
-
-extern int print_insn_big_mips PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_little_mips PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_i386 PARAMS ((bfd_vma, disassemble_info *));
-extern int print_insn_i386_att PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_i386_intel PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_ia64 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_i370 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_m68hc11 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_m68hc12 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_m68k PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_z8001 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_z8002 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_h8300 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_h8300h PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_h8300s PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_h8500 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_alpha PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_big_arm PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_little_arm PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_sparc PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_big_a29k PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_little_a29k PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_avr PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_d10v PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_d30v PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_dlx PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_fr30 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_hppa PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_i860 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_i960 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_m32r PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_m88k PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_mcore PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_mmix PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_mn10200 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_mn10300 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_ns32k PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_openrisc PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_big_or32 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_little_or32 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_pdp11 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_pj PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_big_powerpc PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_little_powerpc PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_rs6000 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_s390 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_sh PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_tic30 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_tic54x PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_tic80 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_v850 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_vax PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_w65 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_xstormy16 PARAMS ((bfd_vma, disassemble_info*));
-extern int print_insn_sh64 PARAMS ((bfd_vma, disassemble_info *));
-extern int print_insn_sh64x_media PARAMS ((bfd_vma, disassemble_info *));
-extern int print_insn_frv PARAMS ((bfd_vma, disassemble_info *));
-
-extern disassembler_ftype arc_get_disassembler PARAMS ((void *));
-extern disassembler_ftype cris_get_disassembler PARAMS ((bfd *));
-
-extern void print_ppc_disassembler_options PARAMS ((FILE *));
-extern void print_arm_disassembler_options PARAMS ((FILE *));
-extern void parse_arm_disassembler_option PARAMS ((char *));
-extern int get_arm_regname_num_options PARAMS ((void));
-extern int set_arm_regname_option PARAMS ((int));
-extern int get_arm_regnames PARAMS ((int, const char **, const char **, const char ***));
+typedef int (*disassembler_ftype) (bfd_vma, disassemble_info *);
+
+extern int print_insn_big_mips (bfd_vma, disassemble_info *);
+extern int print_insn_little_mips (bfd_vma, disassemble_info *);
+extern int print_insn_i386 (bfd_vma, disassemble_info *);
+extern int print_insn_i386_att (bfd_vma, disassemble_info *);
+extern int print_insn_i386_intel (bfd_vma, disassemble_info *);
+extern int print_insn_ia64 (bfd_vma, disassemble_info *);
+extern int print_insn_i370 (bfd_vma, disassemble_info *);
+extern int print_insn_m68hc11 (bfd_vma, disassemble_info *);
+extern int print_insn_m68hc12 (bfd_vma, disassemble_info *);
+extern int print_insn_m68k (bfd_vma, disassemble_info *);
+extern int print_insn_z8001 (bfd_vma, disassemble_info *);
+extern int print_insn_z8002 (bfd_vma, disassemble_info *);
+extern int print_insn_h8300 (bfd_vma, disassemble_info *);
+extern int print_insn_h8300h (bfd_vma, disassemble_info *);
+extern int print_insn_h8300s (bfd_vma, disassemble_info *);
+extern int print_insn_h8500 (bfd_vma, disassemble_info *);
+extern int print_insn_alpha (bfd_vma, disassemble_info *);
+extern int print_insn_big_arm (bfd_vma, disassemble_info *);
+extern int print_insn_little_arm (bfd_vma, disassemble_info *);
+extern int print_insn_sparc (bfd_vma, disassemble_info *);
+extern int print_insn_big_a29k (bfd_vma, disassemble_info *);
+extern int print_insn_little_a29k (bfd_vma, disassemble_info *);
+extern int print_insn_avr (bfd_vma, disassemble_info *);
+extern int print_insn_d10v (bfd_vma, disassemble_info *);
+extern int print_insn_d30v (bfd_vma, disassemble_info *);
+extern int print_insn_dlx (bfd_vma, disassemble_info *);
+extern int print_insn_fr30 (bfd_vma, disassemble_info *);
+extern int print_insn_hppa (bfd_vma, disassemble_info *);
+extern int print_insn_i860 (bfd_vma, disassemble_info *);
+extern int print_insn_i960 (bfd_vma, disassemble_info *);
+extern int print_insn_ip2k (bfd_vma, disassemble_info *);
+extern int print_insn_m32r (bfd_vma, disassemble_info *);
+extern int print_insn_m88k (bfd_vma, disassemble_info *);
+extern int print_insn_mcore (bfd_vma, disassemble_info *);
+extern int print_insn_mmix (bfd_vma, disassemble_info *);
+extern int print_insn_mn10200 (bfd_vma, disassemble_info *);
+extern int print_insn_mn10300 (bfd_vma, disassemble_info *);
+extern int print_insn_msp430 (bfd_vma, disassemble_info *);
+extern int print_insn_ns32k (bfd_vma, disassemble_info *);
+extern int print_insn_openrisc (bfd_vma, disassemble_info *);
+extern int print_insn_big_or32 (bfd_vma, disassemble_info *);
+extern int print_insn_little_or32 (bfd_vma, disassemble_info *);
+extern int print_insn_pdp11 (bfd_vma, disassemble_info *);
+extern int print_insn_pj (bfd_vma, disassemble_info *);
+extern int print_insn_big_powerpc (bfd_vma, disassemble_info *);
+extern int print_insn_little_powerpc (bfd_vma, disassemble_info *);
+extern int print_insn_rs6000 (bfd_vma, disassemble_info *);
+extern int print_insn_s390 (bfd_vma, disassemble_info *);
+extern int print_insn_sh (bfd_vma, disassemble_info *);
+extern int print_insn_tic30 (bfd_vma, disassemble_info *);
+extern int print_insn_tic4x (bfd_vma, disassemble_info *);
+extern int print_insn_tic54x (bfd_vma, disassemble_info *);
+extern int print_insn_tic80 (bfd_vma, disassemble_info *);
+extern int print_insn_v850 (bfd_vma, disassemble_info *);
+extern int print_insn_vax (bfd_vma, disassemble_info *);
+extern int print_insn_w65 (bfd_vma, disassemble_info *);
+extern int print_insn_xstormy16 (bfd_vma, disassemble_info *);
+extern int print_insn_xtensa (bfd_vma, disassemble_info *);
+extern int print_insn_sh64 (bfd_vma, disassemble_info *);
+extern int print_insn_sh64x_media (bfd_vma, disassemble_info *);
+extern int print_insn_frv (bfd_vma, disassemble_info *);
+extern int print_insn_iq2000 (bfd_vma, disassemble_info *);
+
+extern disassembler_ftype arc_get_disassembler (void *);
+extern disassembler_ftype cris_get_disassembler (bfd *);
+
+extern void print_mips_disassembler_options (FILE *);
+extern void print_ppc_disassembler_options (FILE *);
+extern void print_arm_disassembler_options (FILE *);
+extern void parse_arm_disassembler_option (char *);
+extern int get_arm_regname_num_options (void);
+extern int set_arm_regname_option (int);
+extern int get_arm_regnames (int, const char **, const char **, const char ***);
+extern bfd_boolean arm_symbol_is_valid (asymbol *, struct disassemble_info *);
/* Fetch the disassembler for a given BFD, if that support is available. */
-extern disassembler_ftype disassembler PARAMS ((bfd *));
+extern disassembler_ftype disassembler (bfd *);
+
+/* Amend the disassemble_info structure as necessary for the target architecture.
+ Should only be called after initialising the info->arch field. */
+extern void disassemble_init_for_target (struct disassemble_info * info);
/* Document any target specific options available from the disassembler. */
-extern void disassembler_usage PARAMS ((FILE *));
+extern void disassembler_usage (FILE *);
/* This block of definitions is for particular callers who read instructions
@@ -261,59 +277,38 @@ extern void disassembler_usage PARAMS ((FILE *));
/* Here is a function which callers may wish to use for read_memory_func.
It gets bytes from a buffer. */
extern int buffer_read_memory
- PARAMS ((bfd_vma, bfd_byte *, unsigned int, struct disassemble_info *));
+ (bfd_vma, bfd_byte *, unsigned int, struct disassemble_info *);
/* This function goes with buffer_read_memory.
It prints a message using info->fprintf_func and info->stream. */
-extern void perror_memory PARAMS ((int, bfd_vma, struct disassemble_info *));
+extern void perror_memory (int, bfd_vma, struct disassemble_info *);
/* Just print the address in hex. This is included for completeness even
though both GDB and objdump provide their own (to print symbolic
addresses). */
extern void generic_print_address
- PARAMS ((bfd_vma, struct disassemble_info *));
+ (bfd_vma, struct disassemble_info *);
/* Always true. */
extern int generic_symbol_at_address
- PARAMS ((bfd_vma, struct disassemble_info *));
-
-/* Macro to initialize a disassemble_info struct. This should be called
- by all applications creating such a struct. */
+ (bfd_vma, struct disassemble_info *);
+
+/* Also always true. */
+extern bfd_boolean generic_symbol_is_valid
+ (asymbol *, struct disassemble_info *);
+
+/* Method to initialize a disassemble_info struct. This should be
+ called by all applications creating such a struct. */
+extern void init_disassemble_info (struct disassemble_info *info, void *stream,
+ fprintf_ftype fprintf_func);
+
+/* For compatibility with existing code. */
#define INIT_DISASSEMBLE_INFO(INFO, STREAM, FPRINTF_FUNC) \
- (INFO).flavour = bfd_target_unknown_flavour, \
- (INFO).arch = bfd_arch_unknown, \
- (INFO).mach = 0, \
- (INFO).insn_sets = 0, \
- (INFO).endian = BFD_ENDIAN_UNKNOWN, \
- (INFO).octets_per_byte = 1, \
- INIT_DISASSEMBLE_INFO_NO_ARCH(INFO, STREAM, FPRINTF_FUNC)
-
-/* Call this macro to initialize only the internal variables for the
- disassembler. Architecture dependent things such as byte order, or machine
- variant are not touched by this macro. This makes things much easier for
- GDB which must initialize these things separately. */
-
+ init_disassemble_info (&(INFO), (STREAM), (fprintf_ftype) (FPRINTF_FUNC))
#define INIT_DISASSEMBLE_INFO_NO_ARCH(INFO, STREAM, FPRINTF_FUNC) \
- (INFO).fprintf_func = (fprintf_ftype)(FPRINTF_FUNC), \
- (INFO).stream = (PTR)(STREAM), \
- (INFO).section = NULL, \
- (INFO).symbols = NULL, \
- (INFO).num_symbols = 0, \
- (INFO).private_data = NULL, \
- (INFO).buffer = NULL, \
- (INFO).buffer_vma = 0, \
- (INFO).buffer_length = 0, \
- (INFO).read_memory_func = buffer_read_memory, \
- (INFO).memory_error_func = perror_memory, \
- (INFO).print_address_func = generic_print_address, \
- (INFO).symbol_at_address_func = generic_symbol_at_address, \
- (INFO).flags = 0, \
- (INFO).bytes_per_line = 0, \
- (INFO).bytes_per_chunk = 0, \
- (INFO).display_endian = BFD_ENDIAN_UNKNOWN, \
- (INFO).disassembler_options = NULL, \
- (INFO).insn_info_valid = 0
+ init_disassemble_info (&(INFO), (STREAM), (fprintf_ftype) (FPRINTF_FUNC))
+
#ifdef __cplusplus
}
diff --git a/contrib/binutils/include/elf/ChangeLog b/contrib/binutils/include/elf/ChangeLog
index 3e64a32..ea008d6 100644
--- a/contrib/binutils/include/elf/ChangeLog
+++ b/contrib/binutils/include/elf/ChangeLog
@@ -1,1544 +1,39 @@
-2002-07-01 Matt Thomas <matt@3am-software.com>
+2004-01-28 Roland McGrath <roland@redhat.com>
- * vax.h: Rename EF_* to EF_VAX_*.
+ * common.h (AT_SECURE): New macro.
-2002-06-18 Dave Brolley <brolley@redhat.com>
+2004-01-21 Roland McGrath <roland@redhat.com>
- From Catherine Moore, Michael Meissner, Dave Brolley:
- * common.h (EM_CYGNUS_FRV): New macro.
- * frv.h: New file.
+ * common.h (AT_SUN_UID, AT_SUN_RUID, AT_SUN_GID): New macros.
+ (AT_SUN_RGID, AT_SUN_LDELF, AT_SUN_LDSHDR, AT_SUN_LDNAME,
+ AT_SUN_LPAGESZ, AT_SUN_PLATFORM, AT_SUN_HWCAP, AT_SUN_IFLUSH,
+ AT_SUN_CPU, AT_SUN_EMUL_ENTRY, AT_SUN_EMUL_EXECFD,
+ AT_SUN_EXECNAME) AT_SUN_MMU, AT_SUN_LDDATA): Likewise.
-2002-06-06 Lars Brinkhoff <lars@nocrew.org>
+2004-01-17 Mark Kettenis <kettenis@gnu.org>
- * common.h: Change registry@sco.com to registry@caldera.com.
- (EM_PDP10, EM_PDP11): Define.
+ * common.h (NT_OPENBSD_IDENT): Define.
-2002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
+2004-01-06 Alexandre Oliva <aoliva@redhat.com>
- * sh.h (_bfd_sh64_crange_qsort_cmpb, _bfd_sh64_crange_qsort_cmpl)
- (_bfd_sh64_crange_bsearch_cmpb, _bfd_sh64_crange_bsearch_cmpl): New
- prototypes.
+ 2003-09-18 Alexandre Oliva <aoliva@redhat.com>
+ * frv.h (EF_FRV_FDPIC): New macro.
+ (EF_FRV_PIC_FLAGS): Adjust.
+ 2003-08-08 Alexandre Oliva <aoliva@redhat.com>
+ * frv.h (R_FRV_FUNCDESC_VALUE, R_FRV_FUNCDESC_GOTOFF12,
+ R_FRV_FUNCDESC_GOTOFFLO, R_FRV_FUNCDESC_GOTOFFHI, R_FRV_GOTOFF12,
+ R_FRV_GOTOFFLO, R_FRV_GOTOFFHI): New.
+ 2003-08-04 Alexandre Oliva <aoliva@redhat.com>
+ * frv.h (R_FRV_GOT12, R_FRV_GOTHI, R_FRV_GOTLO, R_FRV_FUNCDESC,
+ R_FRV_FUNCDESC_GOT12, R_FRV_FUNCDESC_GOTHI, R_FRV_FUNCDESC_GOTLO):
+ New.
-2002-06-01 Richard Henderson <rth@redhat.com>
-
- * alpha.h (LITUSE_ALPHA_ADDR, LITUSE_ALPHA_BASE, LITUSE_ALPHA_BYTOFF,
- LITUSE_ALPHA_JSR, LITUSE_ALPHA_TLSGD, LITUSE_ALPHA_TLSLDM): New.
-
-2002-05-30 Richard Henderson <rth@redhat.com>
-
- * alpha.h (R_ALPHA_TLSGD, R_ALPHA_TLSLDM, R_ALPHA_DTPMOD64,
- R_ALPHA_GOTDTPREL, R_ALPHA_DTPREL64, R_ALPHA_DTPRELHI,
- R_ALPHA_DTPRELLO, R_ALPHA_DTPREL16, R_ALPHA_GOTTPREL, R_ALPHA_TPREL64,
- R_ALPHA_TPRELHI, R_ALPHA_TPRELLO, R_ALPHA_TPREL16): New.
-
-2002-05-29 Matt Thomas <matt@3am-software.com>
-
- * vax.h: New file
-
-2002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
-
- * common.h (EM_DLX): Define.
- * dlx.h: New file.
-
-2002-05-08 Jason Thorpe <thorpej@wasabisystems.com>
-
- * common.h (NT_GNU_ABI_TAG): Define.
- (GNU_ABI_TAG_LINUX): Define.
- (GNU_ABI_TAG_HURD): Define.
- (GNU_ABI_TAG_SOLARIS): Define.
- (NT_NETBSD_IDENT): Define.
- (NT_FREEBSD_ABI_TAG): Define.
-
-2002-04-24 Elena Zannoni <ezannoni@redhat.com>
-
- * dwarf2.h: Add DW_AT_GNU_vector.
-
-2002-02-13 Matt Fredette <fredette@netbsd.org>
-
- * m68k.h (EF_M68000): Define.
-
-2002-02-12 Alan Modra <amodra@bigpond.net.au>
-
- * ppc.h (DT_PPC64_OPD, DT_PPC64_OPDSZ): Define.
-
-2002-02-09 Richard Henderson <rth@redhat.com>
-
- * alpha.h (R_ALPHA_BRSGP): New.
-
-2002-02-08 Alexandre Oliva <aoliva@redhat.com>
-
- Contribute sh64-elf.
- 2002-01-23 Alexandre Oliva <aoliva@redhat.com>
- * sh.h (R_SH_GOTPLT32, R_SH_GOT_LOW16, R_SH_GOT_MEDLOW16,
- R_SH_GOT_MEDHI16, R_SH_GOT_HI16, R_SH_GOTPLT_LOW16,
- R_SH_GOTPLT_MEDLOW16, R_SH_GOTPLT_MEDHI16, R_SH_GOTPLT_HI16,
- R_SH_PLT_LOW16, R_SH_PLT_MEDLOW16, R_SH_PLT_MEDHI16,
- R_SH_PLT_HI16, R_SH_GOTOFF_LOW16, R_SH_GOTOFF_MEDLOW16,
- R_SH_GOTOFF_MEDHI16, R_SH_GOTOFF_HI16, R_SH_GOTPC_LOW16,
- R_SH_GOTPC_MEDLOW16, R_SH_GOTPC_MEDHI16, R_SH_GOTPC_HI16,
- R_SH_GOT10BY4, R_SH_GOTPLT10BY4, R_SH_GOT10BY8,
- R_SH_GOTPLT10BY8, R_SH_COPY64, R_SH_GLOB_DAT64, R_SH_JMP_SLOT64,
- R_SH_RELATIVE64): New relocs.
- (R_SH_FIRST_INVALID_RELOC_4): Adjust.
- 2001-05-16 Alexandre Oliva <aoliva@redhat.com>
- * sh.h: Renumbered and renamed some SH5 relocations to match
- official numbers and names; moved unmaching ones to the range
- 0xf2-0xff.
- 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
- * sh.h (sh64_get_contents_type): Declare.
- (sh64_address_is_shmedia): Likewise.
- 2000-12-30 Hans-Peter Nilsson <hpn@cygnus.com>
- * sh.h (sh64_elf_crange): New type.
- (struct sh64_section_data): New.
- (sh64_elf_section_data): New macro.
- (EF_SH5): Rename back from EF_SH64.
- 2000-12-18 Hans-Peter Nilsson <hpn@cygnus.com>
- * sh.h (SHF_SH5_ISA32_MIXED, SHT_SH5_CR_SORTED,
- SH64_CRANGES_SECTION_NAME, SH64_CRANGE_SIZE,
- SH64_CRANGE_CR_ADDR_OFFSET, SH64_CRANGE_CR_SIZE_OFFSET,
- SH64_CRANGE_CR_TYPE_OFFSET): New macros.
- 2000-12-12 Hans-Peter Nilsson <hpn@cygnus.com>
- * sh.h (EF_SH64): Don't define EF_SH64_ABI64.
- 2000-11-27 Hans-Peter Nilsson <hpn@cygnus.com>
- * sh.h (EF_SH64_32BIT_ABI, EF_SH64_64BIT_ABI): Delete.
- (EF_SH64_ABI64): New.
- 2000-11-23 Hans-Peter Nilsson <hpn@cygnus.com>
- * sh.h (EF_SH64): Rename from EF_SH5.
- (EF_SH64_32BIT_ABI): New.
- (EF_SH64_64BIT_ABI): New.
- (R_SH_PT_16, R_SH_SHMEDIA_CODE
- R_SH_IMMU5, R_SH_IMMS6, R_SH_IMMU6, R_SH_IMMS10, R_SH_IMMS10BY2,
- R_SH_IMMS10BY4, R_SH_IMMS10BY8, R_SH_IMMS16, R_SH_IMMU16,
- R_SH_IMM_LOW16, R_SH_IMM_LOW16_PCREL, R_SH_IMM_MEDLOW16,
- R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16, R_SH_IMM_MEDHI16_PCREL,
- R_SH_IMM_HI16, R_SH_IMM_HI16_PCREL, R_SH_64, R_SH_64_PCREL): New
- relocs.
- 2000-09-01 Ben Elliston <bje@redhat.com>
- * sh.h (EF_SH5): Define.
-
-2002-02-01 Hans-Peter Nilsson <hp@bitrange.com>
-
- * mmix.h: Tweak comments.
- (MMIX_LD_ALLOCATED_REG_CONTENTS_SECTION_NAME): New.
- [BFD_ARCH_SIZE] (_bfd_mmix_prepare_linker_allocated_gregs,
- _bfd_mmix_finalize_linker_allocated_gregs,
- _bfd_mmix_check_all_relocs): Provide prototypes.
-
-2002-01-31 Ivan Guzvinec <ivang@opencores.org>
-
- * or32.h: New file.
- * common.h: Add support for or32 targets.
-
-2002-01-28 Jason Merrill <jason@redhat.com>
-
- * dwarf2.h: Sync with gcc version.
-
-2002-01-16 Alan Modra <amodra@bigpond.net.au>
-
- * ppc.h (DT_PPC64_GLINK): Define.
-
-2002-01-15 Richard Earnshaw <rearnsha@arm.com>
-
- * arm.h (F_VFP_FLOAT, EF_ARM_VFP_FLOAT): Define.
-
-2002-01-09 Jason Thorpe <thorpej@wasabisystems.com>
-
- * common.h: Update copyright years.
- (NT_NETBSDCORE_PROCINFO): Define.
- (NT_NETBSDCORE_FIRSTMACH): Define.
-
-2002-01-06 Steve Ellcey <sje@cup.hp.com>
-
- * ia64.h (ELF_STRING_ia64_unwind_hdr): New Macro for HP-UX.
- (SHT_IA_64_HP_OPT_ANOT): Ditto
- (PT_IA_64_HP_OPT_ANOT): Ditto
- (PT_IA_64_HP_HSL_ANOT): Ditto
- (PT_IA_64_HP_STACK): Ditto
- (SHN_IA_64_ANSI_COMMON): Ditto
-
-2001-12-17 Alan Modra <amodra@bigpond.net.au>
-
- * external.h (Elf_External_Sym_Shndx): Declare.
- * internal.h (struct elf_internal_sym <st_shndx>): Make it an
- unsigned int.
- * common.h (SHN_BAD): Define.
-
-2001-12-13 Jakub Jelinek <jakub@redhat.com>
-
- * elf/common.h (PT_GNU_EH_FRAME): Define.
-
-2001-12-11 Alan Modra <amodra@bigpond.net.au>
-
- * common.h (SHN_XINDEX): Comment typo fix.
- * internal.h (Elf_Internal_Ehdr): Change existing "unsigned short"
- size, count and index fields to "unsigned int".
-
-2001-12-07 Geoffrey Keating <geoffk@redhat.com>
- Richard Henderson <rth@redhat.com>
-
- * common.h (EM_XSTORMY16): Define.
- * xstormy16.h: New file.
-
-2001-11-15 Alan Modra <amodra@bigpond.net.au>
-
- * common.h (NT_ARCH): Define. Remove incorrect comment.
-
-2001-11-11 Geoffrey Keating <geoffk@redhat.com>
-
- * dwarf2.h (dwarf_line_number_ops): Add DWARF 3 opcodes.
-
-2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
-
- * mmix.h: New file.
-
-2001-10-23 Alan Modra <amodra@bigpond.net.au>
-
- * internal.h: White space changes to keep lines under 80 chars.
-
-2001-10-16 Jeff Holcomb <jeffh@redhat.com>
-
- * internal.h (elf_internal_shdr): Make contents a unsigned char *.
-
-2001-09-18 Alan Modra <amodra@bigpond.net.au>
-
- * internal.h (elf_internal_rela): Make r_addend a bfd_vma.
-
-2001-09-13 Alexandre Oliva <aoliva@redhat.com>
-
- * common.h (EM_OPENRISC_OLD): Renamed the old EM_OPENRISC entry.
-
-2001-09-12 Alexandre Oliva <aoliva@redhat.com>
-
- * common.h (EM_AVR_OLD): Renamed from...
- (EM_AVR): this, redefined as in the current ELF standard.
- (EM_PJ_OLD): Renamed from...
- (EM_PJ): this, redefined as in the current ELF standard.
- (EM_R30, EM_D10V, EM_D30V, EM_V850, EM_M32R, EM_MN10300,
- EM_MN10200, EM_OPENRISC, EM_ARC_A5, EM_XTENSA): Defined as in
- the current ELF standard.
- (EM_CYGNUS_ARC): Removed, unused for a long time.
-
-2001-09-04 Richard Henderson <rth@redhat.com>
-
- * alpha.h (R_ALPHA_OP*, R_ALPHA_IMMED*, R_ALPHA_GPVALUE): Remove.
- (R_ALPHA_GPREL16): Rename from R_ALPHA_IMMED_GP_16.
-
-2001-08-30 Eric Christopher <echristo@redhat.com>
-
- * mips.h: Remove E_MIPS_MACH_MIPS32_4K.
-
-2001-08-29 Jeff Law <law@redhat.com>
-
- * h8.h (EF_H8_MACH): New mask for encoded machine type.
- (E_H8_MACH_H8300, E_H8_MACH_H8300H, E_H8_MACH_H8300S): New
- machine types.
-
-2001-08-26 J"orn Rennecke <amylaar@redhat.com>
-
- * h8.h: New file.
-
-2001-08-27 Staffan Ulfberg <staffanu@swox.se>
-
- * ppc.h: Add relocs from the 64-bit PowerPC ELF ABI revision 1.2.
-
-2001-06-30 Daniel Berlin <dan@cgsoftware.com>
-
- * dwarf2.h: Remerge with gcc version,
- including all new DWARF 2.1 extensions.
-
-2001-06-29 James Cownie <jcownie@etnus.com>
-
- * dwarf2.h: Add DWARF 2.1 attribues.
-
-2001-06-15 Per Bothner <per@bothner.com>
-
- * dwarf2.h: Partial merge with gcc version.
- (enum dwarf_descrim_list): Fix typo -> dwarf_discrim_list.
- (DW_LANG_Java): Use value from dwarf 2.1 draft (also used in gcc).
-
-2001-05-15 Ralf Baechle <ralf@gnu.org>
-
- * common.h: Remove definition of EM_MIPS_RS4_BE. The constant was
- never in active use and is used otherwise by the ABI.
-
-2001-05-11 Jakub Jelinek <jakub@redhat.com>
-
- * ia64.h (ELF_STRING_ia64_unwind_once): Define.
- (ELF_STRING_ia64_unwind_info_once): Define.
-
-2001-05-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * external.h: Fix typo.
- * mips.h: Add/Extend many comments with reference to the MIPS ELF64
- spec v. 2.4, available at e.g.
- ftp://oss.sgi.com/pub/linux/mips/doc/ABI/ELF64.ps.
- (EF_MIPS_UCODE): Define.
- (EF_MIPS_OPTIONS_FIRST): Define.
- (EF_MIPS_ARCH_ASE): Define.
- (EF_MIPS_ARCH_ASE_MDMX): Define.
- (EF_MIPS_ARCH_ASE_M16): Define.
- (SHF_MIPS_ADDR): Renamed SHF_MIPS_ADDR32.
- (SHF_MIPS_STRING): Renamed SHF_MIPS_ADDR64.
- (SHF_MIPS_NODUPES): Define.
- (ELF64_MIPS_R_SSYM): New MIPS ELF 64 relocation info access macro.
- (ELF64_MIPS_R_TYPE3): Likewise.
- (ELF64_MIPS_R_TYPE2): Likewise.
- (ELF64_MIPS_R_TYPE): Likewise.
- (OHW_R10KLDL): Define.
-
-2001-04-24 Todd Fries <todd@fries.net>
-
- * sparc.h: Fix typo.
-
-2001-04-20 Johan Rydberg <jrydberg@opencores.org>
-
- * openrisc.h: New file.
- * common.h (EM_OPENRISC): New constant.
-
-2001-04-23 Bo Thorsen <bo@suse.de>
-
- * x86-64.h: Add vtable support.
-
-2001-03-23 Nick Clifton <nickc@redhat.com>
-
- * mips.h: Remove extraneous whitespace.
-
-2001-03-22 Hans-Peter Nilsson <hp@axis.com>
-
- * cris.h: Add leading comment about PC-relative location.
- (R_CRIS_COPY, R_CRIS_GLOB_DAT, R_CRIS_JUMP_SLOT, R_CRIS_RELATIVE,
- R_CRIS_16_GOT, R_CRIS_32_GOT, R_CRIS_16_GOTPLT, R_CRIS_32_GOTPLT,
- R_CRIS_32_GOTREL, R_CRIS_32_PLT_GOTREL, R_CRIS_32_PLT_PCREL):
- New relocs.
-
-2001-02-27 Philip Blundell <pb@futuretv.com>
-
- * arm.h: Add new definitions from ARM document SWS ESPC 0003 B-01.
- (EF_PIC, et al.): Rename to EF_ARM_xx.
-
-2001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * common.h: Add linux target for S/390.
- * s390.h: New file.
-
-2001-01-11 Peter Targett <peter.targett@arccores.com>
-
- * arc.h (E_ARC_MACH_ARC5, E_ARC_MACH_ARC6, E_ARC_MACH_ARC7,
- E_ARC_MACH_ARC8): New definitions for cpu types.
-
- * common.h (EM_ARC): Change comment.
-
-2000-12-12 Nick Clifton <nickc@redhat.com>
-
- * mips.h: Fix formatting.
-
-2000-12-11 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h (DT_HP_*): Define relative to OLD_DT_LOOS for hpux
- compatibility.
-
-2000-10-16 Chris Demetriou <cgd@sibyte.com>
-
- * mips.h (E_MIPS_ARCH_32): New constant.
- (E_MIPS_MACH_MIPS32, E_MIPS_MACH_MIPS32_4K): Replace the
- former with the latter.
-
- * mips.h (E_MIPS_ARCH_5, E_MIPS_ARCH_64): New definitions.
-
- * mips.h (E_MIPS_MACH_SB1): New constant.
-
-2000-11-30 Jan Hubicka <jh@suse.cz>
-
- * common.h (EM_X86_64): New macro.
- * x86-64.h: New file.
-
-2000-11-27 Hans-Peter Nilsson <hp@axis.com>
-
- * common.h (e_machine numbers): Clarify comments to describe how
- EM_* constants are assigned. Move EM_PJ from official section to
- ad-hoc section.
- (EM_CRIS): Correct comment to match official description.
- (EM_MMIX): Ditto.
-
-2000-11-22 Nick Clifton <nickc@redhat.com>
-
- * common.h (EM_JAVELIN): New machine number.
- (EM_FIREPATH): New machine number.
- (EM_ZSP): New machine number.
- (EM_MMIX): New machine number.
- (EM_HUANY): New machine number.
- (EM_PRISM): New machine number.
- (SHT_GROUP): New section type.
- (SHT_SYMTAB_SHNDX): New section type.
- (SHF_GROUP): New section flag.
- (SHN_XINDEX): New section index.
- (GRP_COMDAT): New section group flag.
-
-2000-11-20 H.J. Lu <hjl@gnu.org>
-
- * common.h (ELFOSABI_MONTEREY): Renamed to ...
- (ELFOSABI_AIX): This.
-
-2000-11-16 Richard Henderson <rth@redhat.com>
-
- Update relocations per August psABI docs.
- * ia64.h (R_IA64_SEGBASE): Remove.
- (R_IA64_LTV*): Renumber to 0x74 to 0x77.
- (R_IA64_EPLTMSB, R_IA64_EPLTLSB): Remove.
- (R_IA64_TPREL14, R_IA64_TPREL64I): New.
- (R_IA64_DTPMOD*): New.
- (R_IA64_DTPREL*): New.
-
-2000-09-29 Hans-Peter Nilsson <hp@axis.com>
-
- * cris.h (EF_CRIS_UNDERSCORE): New.
-
-2000-09-27 Alan Modra <alan@linuxcare.com.au>
-
- * hppa.h (R_PARISC_DIR14F): Add.
-
-2000-09-14 Alexandre Oliva <aoliva@redhat.com>
-
- * sh.h (R_SH_GOT32, R_SH_PLT32, R_SH_COPY, R_SH_GLOB_DAT,
- R_SH_JMP_SLOT, R_SH_RELATIVE, R_SH_GOTOFF, R_SH_GOTPC): Change
- numbers to the range from 160 to 167.
- (R_SH_FIRST_INVALID_RELOC): Adjust.
- (R_SH_FIRST_INVALID_RELOC_2, R_SH_LAST_INVALID_RELOC_2):
- New relocs to fill in the gap.
-
-2000-09-13 Anders Norlander <anorland@acc.umu.se>
-
- * mips.h (E_MIPS_MACH_4K): New define.
-
-2000-09-05 Alan Modra <alan@linuxcare.com.au>
-
- * hppa.h: Fix a comment.
- (R_PARISC_PCREL12F): Define.
- (R_PARISC_GNU_VTENTRY): Define.
- (R_PARISC_GNU_VTINHERIT): Define.
-
-2000-09-01 Alexandre Oliva <aoliva@redhat.com>
-
- * sh.h (R_SH_GOT32, R_SH_PLT32, R_SH_COPY, R_SH_GLOB_DAT,
- R_SH_JMP_SLOT, R_SH_RELATIVE, R_SH_GOTOFF, R_SH_GOTPC): New relocs.
- (R_SH_FIRST_INVALID_RELOC): Adjust.
-
-2000-08-14 Jim Wilson <wilson@cygnus.com>
-
- * ia64.h (EF_IA_64_REDUCEDFP, EF_IA_64_CONS_GP,
- EF_IA_64_NOFUNCDESC_CONS_GP, EF_IA_64_ABSOLUTE): Define.
-
-2000-08-07 Nick Clifton <nickc@cygnus.com>
-
- * ppc.h: Remove spurious CYGNUS LOCAL comments.
- * v850.h: Likewise.
-
-2000-07-22 Jason Eckhardt <jle@cygnus.com>
-
- * i860.h: New file.
- (elf_i860_reloc_type): Defined ELF32 i860 relocations.
-
-2000-07-20 Hans-Peter Nilsson <hp@axis.com>
-
- common.h (EM_CRIS): New machine number.
- cris.h: New file.
-
-2000-07-19 H.J. Lu <hjl@gnu.org>
-
- * common.h (DF_1_NODEFLIB): Renamed from DF_1_NODEPLIB.
-
-2000-07-19 H.J. Lu <hjl@gnu.org>
-
- * common.h (DT_CHECKSUM): Set to 0x6ffffdf8.
- (DTF_1_CONFEXP): It is 0x00000002 as suspected.
-
-2000-07-19 H.J. Lu <hjl@gnu.org>
-
- * common.h (DT_FEATURE): Renamed from DT_FEATURE_1.
- (DT_CONFIG): New. From Solaris 8.
- (DT_DEPAUDIT): Likewise.
- (DT_AUDIT): Likewise.
- (DT_PLTPAD): Likewise.
- (DT_MOVETAB): Likewise.
- (DF_1_NODEPLIB): Likewise.
- (DF_1_NODUMP): Likewise.
- (DF_1_CONLFAT): Likewise.
- (DT_CHECKSUM): Likewise. FIXME. Check the value on Solaris 8.
- (DTF_1_CONFEXP): Likewise.
-
-2000-07-18 H.J. Lu <hjl@gnu.org>
-
- * common.h (DT_FLAGS_1): Renamed from DT_1_FLAGS.
-
-2000-07-12 Alan Modra <alan@linuxcare.com.au>
-
- * internal.h (struct elf_internal_sym): Update comment for st_other.
-
-2000-07-10 Alan Modra <alan@linuxcare.com.au>
-
- * hppa.h: Add comments to all the relocs.
-
-2000-06-26 Marek Michalkiewicz <marekm@linux.org.pl>
-
- * avr.h (E_AVR_MACH_AVR5): Define.
-
-2000-06-18 Stephane Carrez <stcarrez@worldnet.fr>
-
- * m68hc11.h: New file, definitions for the Motorola 68hc11.
-
-2000-06-06 Alan Modra <alan@linuxcare.com.au>
-
- * reloc-macros.h (START_RELOC_NUMBERS): Don't define initial dummy
- -1 valued enum.
- (RELOC_NUMBER, FAKE_RELOC, EMPTY_RELOC): Append rather than
- prepend comma.
- (END_RELOC_NUMBERS): Give macro an arg to define as last enum.
-
- * alpha.h (R_ALPHA_max): Define via END_RELOC_NUMBERS rather than
- with EMPTY_RELOC.
- * arc.h (R_ARC_max): Likewise.
- * avr.h (R_AVR_max): Likewise.
- * fr30.h (R_FR30_max): Likewise.
- * hppa.h (R_PARISC_UNIMPLEMENTED): Likewise.
- * i960.h (R_960_max): Likewise.
- * m32r.h (R_M32R_max): Likewise.
- * m68k.h (R_68K_max): Likewise.
- * mcore.h (R_MCORE_max): Likewise.
- * mn10300.h (R_MN10300_MAX): Likewise.
- * pj.h (R_PJ_max): Likewise.
- * ppc.h (R_PPC_max): Likewise.
- * sh.h (R_SH_max): Likewise.
- * sparc.h (R_SPARC_max): Likewise.
- * v850.h (R_V850_max): Likewise.
-
- * arm.h (R_ARM_max): Define via END_RELOC_NUMBERS.
- * d10v.h (R_D10V_max): Likewise.
- * d30v.h (R_D30V_max): Likewise.
- * ia64.h (R_IA64_max): Likewise.
- * mips.h (R_MIPS_maxext): Likewise.
- * mn10200.h (R_MN10200_max): Likewise.
-
- * i386.h (R_386_max): Remove old RELOC_NUMBER definition, and
- define via END_RELOC_NUMBERS.
-
-2000-06-03 Alan Modra <alan@linuxcare.com.au>
-
- * reloc-macros.h (START_RELOC_NUMBERS): Fix name clash for
- !__STDC__ case.
- (RELOC_NUMBER): Use ansi stringify if ALMOST_STDC defined.
-
-2000-05-22 Richard Henderson <rth@cygnus.com>
-
- * ia64.h (R_IA64_PCREL60B, R_IA64_PCREL21BI): New.
- (R_IA64_PCREL22, R_IA64_PCREL64I): New.
-
-2000-05-02 H.J. Lu <hjl@gnu.org>
-
- * common.h (ELFOSABI_NONE): Renamed from ELFOSABI_SYSV.
- (ELFOSABI_MODESTO): Defined.
- (ELFOSABI_OPENBSD): Likewise.
-
-2000-04-21 Richard Henderson <rth@cygnus.com>
- David Mosberger <davidm@hpl.hp.com>
-
- * ia64.h: New file.
-
-2000-04-14 H.J. Lu <hjl@gnu.org>
-
- * common.h (ELFOSABI_TRUE64): Renamed to ELFOSABI_TRU64.
-
-2000-04-14 H.J. Lu <hjl@gnu.org>
-
- * common.h (ELFOSABI_NETBSD): Defined.
- (ELFOSABI_HURD): Likewise.
- (ELFOSABI_SOLARIS): Likewise.
- (ELFOSABI_MONTEREY): Likewise.
- (ELFOSABI_IRIX): Likewise.
- (ELFOSABI_FREEBSD): Likewise.
- (ELFOSABI_TRUE64): Likewise.
-
-2000-04-07 Nick Clifton <nickc@cygnus.com>
-
- * arm-oabi.h: Delete.
- * arm.h: Merge in definitions of old reloc numbers from
- arm-oabi.h.
-
-2000-04-06 Nick Clifton <nickc@cygnus.com>
-
- * arm.h (EF_ARM_SYMSARESORTED): Define.
- (EF_ARM_EABIMASK): Define.
- (EF_ARM_EABI_VERSION): Define.
- (EF_ARM_EABI_UNKNOWN): Define.
- (EF_ARM_EABI_VER1): Define.
- (PF_ARM_PI): Define.
- (PF_ARM_ABS): Define.
-
-2000-04-05 J"orn Rennecke <amylaar@cygnus.co.uk>
-
- * sh.h (R_SH_LOOP_START, R_SH_LOOP_END): New RELOC_NUMBERs.
-
-2000-03-27 Denis Chertykov <denisc@overta.ru>
-
- * avr.h: New file. AVR ELF support for BFD.
- * common.h: Add AVR magic number.
-
-2000-03-10 Geoffrey Keating <geoffk@cygnus.com>
-
- * mips.h: Add R_MIPS_GNU_REL_HI16, R_MIPS_GNU_REL_LO16,
- R_MIPS_GNU_REL16_S2, R_MIPS_PC64 and R_MIPS_PC32 relocation
- numbers.
-
-2000-02-23 Linas Vepstas <linas@linas.org>
-
- * i370.h: New file.
-
-2000-02-22 Nick Clifton <nickc@cygnus.com>
-
- * common.h (ELF_ST_OTHER): Remove definition.
- (ELF32_ST_OTHER): Remove definition.
- (ELF64_ST_OTHER): Remove definition.
-
-2000-02-22 H.J. Lu <hjl@gnu.org>
-
- * common.h (ELFOSABI_LINUX): Define.
-
-2000-02-17 J"orn Rennecke <amylaar@cygnus.co.uk>
-
- * sh.h: (EF_SH_MACH_MASK, EF_SH_UNKNOWN, EF_SH1, EF_SH2): New macros.
- (EF_SH3, EF_SH_HAS_DSP, EF_SH_DSP, EF_SH3_DSP): Likewise.
- (EF_SH_HAS_FP, EF_SH3E, EF_SH4, EF_SH_MERGE_MACH): Likewise.
-
-2000-02-03 H.J. Lu <hjl@gnu.org>
-
- * arm-oabi.h: Duplicate changes made to arm.h on Jan. 27,
- 2000 by Thomas de Lellis <tdel@windriver.com>.
-
-2000-01-27 Thomas de Lellis <tdel@windriver.com>
-
- * arm.h (STT_ARM_TFUNC): Define in terms of STT_LOPROC.
- (STT_ARM_16BIT): New flag. Denotes a label that was defined in
- Thumb block but was does not identify a function.
-
-2000-01-20 Nick Clifton <nickc@cygnus.com>
-
- * common.h (EM_MCORE): Fix spelling of Motorola.
- * mcore.h (EM_MCORE): Fix spelling of Motorola.
-
-2000-01-13 Nick Clifton <nickc@cygnus.com>
-
- * common.h (EM_S370): Change comment - this is now the IBM
- System/370.
- (EM_IA_64): Change comment - this is now the IA-64.
-
-2000-01-11 Nick Clifton <nickc@cygnus.com>
-
- * common.h (DT_ENCODING): Fix definition of this value.
- (DT_LOOS): Fix definition of this value.
- (DT_HIOS): Fix definition of this value.
- (OLD_DT_LOOS): Value of DT_LOOS before Oct 4, 1999 draft
- of ELF spec changed it.
- (OLD_DT_HIOS): Value of DT_HIOS before Oct 4, 1999 draft
- of ELF spec changed it.
-
-2000-01-10 Egor Duda <deo@logos-m.ru>
-
- * common.h (NT_WIN32PSTATUS): Define. (cygwin elf core dumps).
-
-1999-12-28 Nick Clifton <nickc@cygnus.com>
-
- * mips.h (STO_*): Redefine in terms of STV_* values now in
- common.h.
-
-1999-12-27 Nick Clifton <nickc@cygnus.com>
-
- * common.h: Upgrade to match Oct4, 1999 Draft ELF ABI Spec.
- (EM_MIPS_RS3_LE): New machine number.
- (EM_RCE): New machine number.
- (EM_MMA): New machine number.
- (EM_PCP): New machine number.
- (EM_NCPU): New machine number.
- (EM_NDR1): New machine number.
- (EM_STARCORE): New machine number.
- (EM_ME16): New machine number.
- (EM_ST100): New machine number.
- (EM_TINYJ): New machine number.
- (EM_FX66): New machine number.
- (EM_ST9PLUS): New machine number.
- (EM_ST7): New machine number.
- (EM_68HC16): New machine number.
- (EM_68HC11): New machine number.
- (EM_68HC08): New machine number.
- (EM_68HC05): New machine number.
- (EM_SVX): New machine number.
- (EM_VAX): New machine number.
- (PF_MASKOS): Change value.
- (SHT_INIT_ARRAY): New value for sh_type field.
- (SHT_FINI_ARRAY): New value for sh_type field.
- (SHT_PREINIT_ARRAY): New value for sh_type field.
- (SHT_HIUSER): Change value.
- (SHF_MERGE): New valye for sh_flags field.
- (SHF_STRINGS): New valye for sh_flags field.
- (SHF_INFO_LINK): New valye for sh_flags field.
- (SHF_OS_NONCONFORMING): New valye for sh_flags field.
- (SHF_MASKOS): Change value.
- (ELF_ST_VISIBILITY): New macro.
- (ELF_ST_OTHER): New macro.
- (STT_COMMON): New symbol type.
- (STV_DEFAULT): Value for symbol visibility.
- (STV_INTERNAL): Value for symbol visibility.
- (STV_HIDDEN): Value for symbol visibility.
- (STV_PROTECTED): Value for symbol visibility.
- (DT_RUNPATH): New dynamic section tag.
- (DT_FLAGS): New dynamic section tag.
- (DT_ENCODING): New dynamic section tag.
- (DT_PREINIT_ARRAY): New dynamic section tag.
- (DT_PREINIT_ARRAYSZ): New dynamic section tag.
- (DT_LOPROC): New dynamic section tag index.
- (DT_HIPROC): New dynamic section tag index.
- (DF_ORIGIN): Value for dynamic section flag.
- (DF_SYMBOLIC): Value for dynamic section flag.
- (DF_TEXTREL): Value for dynamic section flag.
- (DF_BIND_NOW): Value for dynamic section flag.
-
-1999-12-09 Fred Fish <fnf@cygnus.com>
-
- * i960.h (reloc-macros.h): Include using relative dir elf/.
- * i386.h (reloc-macros.h): Include using relative dir elf/.
- * hppa.h (reloc-macros.h): Include using relative dir elf/.
-
-1999-12-07 Jim Blandy <jimb@cygnus.com>
-
- * common.h (NT_PRXFPREG): New definition.
-
-Wed Dec 1 03:02:15 1999 Jeffrey A Law (law@cygnus.com)
-
- * mn10300.h (E_MN10300_MACH_AM33): Define.
-
-Mon Oct 11 22:42:37 1999 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h (PF_HP_PAGE_SIZE): Define.
- (PF_HP_FAR_SHARED, PF_HP_NEAR_SHARED, PF_HP_CODE): Likewise.
- (PF_HP_MODIFY, PF_HP_LAZYSWAP, PF_HP_SBP): Likewise.
-
-Mon Oct 4 17:42:38 1999 Doug Evans <devans@canuck.cygnus.com>
-
- * m32r.h (E_M32RX_ARCH): Define.
-
-1999-09-15 Ulrich Drepper <drepper@cygnus.com>
-
- * hppa.h: Add DT_HP_GST_SIZE, DT_HP_GST_VERSION, and DT_HP_GST_HASHVAL.
-
-1999-09-04 Steve Chamberlain <sac@pobox.com>
-
- * pj.h: New file.
- * common.h (EM_PJ): Define.
-
-1999-09-02 Ulrich Drepper <drepper@cygnus.com>
-
- * hppa.h: Add HPUX specific symbol type definitions.
-
- * hppa.h: Add HPUX specific dynamic and program header table
- specific definitions.
-
-1999-08-31 Scott Bambrough <scottb@netwinder.org>
-
- * common.h (NT_TASKSTRUCT): Define.
-
-1999-07-16 Jakub Jelinek <jj@ultra.linux.cz>
-
- * sparc.h (EF_SPARC_SUN_US3): Define in Cheetah extensions
- flag (as per SCD2.4.1).
-
-1999-07-16 Jakub Jelinek <jj@ultra.linux.cz>
-
- * sparc.h (ELF64_R_TYPE_DATA): Only use ELF64_R_TYPE bits, not
- ELF64_R_SYM bits.
-
-1999-06-21 Philip Blundell <pb@nexus.co.uk>
-
- * arm.h (EF_SOFT_FLOAT, F_SOFT_FLOAT): Define.
-
-1999-07-13 Andreas Schwab <schwab@suse.de>
-
- * m68k.h (EF_CPU32): Move definition inside multiple inclusion
- guard.
-
-1999-07-08 Richard Henderson <rth@cygnus.com>
-
- * sparc.h (ELF64_R_TYPE_DATA): Sign extend the value.
- (ELF64_R_TYPE_INFO): Mask out all but low 24 bits of data.
- (DT_SPARC_PLTFMT): Delete.
- Based on a patch from Jakub Jelinek.
-
-Mon Jun 21 16:36:02 1999 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h (elf_hppa_reloc_type): Renamed from elf32_hppa_reloc_type.
-
-1999-06-10 Jakub Jelinek <jj@ultra.linux.cz>
-
- * sparc.h (R_SPARC_max_std): Define.
-
-Wed Jun 9 15:16:34 1999 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h: Update with various changes from newest PA ELF
- specifications.
-
-1999-06-03 Ian Lance Taylor <ian@zembu.com>
-
- * common.h (EM_PPC64): Define.
-
-1999-06-02 Stu Grossman <grossman@babylon-5.cygnus.com>
-
- * dwarf.h: Add LANG_JAVA.
- * dwarf2.h: Add DW_LANG_Java.
-
-1999-05-29 Nick Clifton <nickc@cygnus.com>
-
- * common.h (ELFOSABI_ARM): Define.
-
-1999-05-28 Nick Clifton <nickc@cygnus.com>
-
- * reloc-macros.h: Update comment.
-
-1999-05-28 Ian Lance Taylor <ian@zembu.com>
-
- * i960.h: New file.
-
-1999-05-16 Nick Clifton <nickc@cygnus.com>
-
- * mcore.h (R_MCORE_COPY): Define.
- (R_MCORE_GLOB_DAT): Define.
- (R_MCORE_JUMP_SLOT): Define.
-
-1999-05-15 Nick Clifton <nickc@cygnus.com>
-
- * mcore.h (R_MCORE_RELATIVE): Define.
-
-1999-05-05 Catherine Moore <clm@cygnus.com>
-
- * m68k.h (EF_CPU32): Define.
-
-1999-04-21 Nick Clifton <nickc@cygnus.com>
-
- * reloc-macros.h (START_RELOC_NUMBERS): Prepend an underscore to
- fake reloc entry name (if possible), in order to avoid conflicts
- with typedefs of the same name.
-
-1999-04-16 Gavin Romig-Koch <gavin@cygnus.com>
-
- * mips.h (EF_MIPS_32BITMODE): New.
-
-1999-04-08 Nick Clifton <nickc@cygnus.com>
-
- * mcore.h: New header file. Defines for Motorola's MCore
- processor.
-
-1999-04-08 Nick Clifton <nickc@cygnus.com>
-
- * common.h: Add new constants defined in: "System V Application
- Binary Interface - DRAFT - April 29, 1998" found at the web site:
- http://www.sco.com/developer/gabi/contents.html
-
- (EM_MMA): Removed. Replaced with EM_MCORE as Motorolla own this
- value.
-
-1999-03-31 Nick Clifton <nickc@cygnus.com>
-
- * reloc-macros.h: Fixed to not generate an enum with a trailing
- comma.
-
-1999-03-16 Gavin Romig-Koch <gavin@cygnus.com>
-
- * mips.h (E_MIPS_MACH_5000): New.
-
-1999-03-10 Ulrich Drepper <drepper@cygnus.com>
-
- * common.h: Add definitions for a few more Solaris ELF extensions.
-
-Thu Feb 18 18:58:26 1999 Ian Lance Taylor <ian@cygnus.com>
-
- * external.h: Only use attribute if __GNUC__ is defined.
-
-1999-02-17 Nick Clifton <nickc@cygnus.com>
-
- Patch submitted by: Scott Bambrough <scottb@corelcomputer.com>
-
- * external.h: struct Elf_External_Versym must be packed on
- ARM. Code uses sizeof(Elf_External_Versym) and assumes it is
- equal to sizeof(char[2]). Reported by Jim Pick <jim@jimpick.com>
-
-1999-02-02 Nick Clifton <nickc@cygnus.com>
-
- * dwarf2.h (DWARF2_External_ARange): New structure.
- (DWARF2_Internal_ARange): New structure.
-
-Mon Feb 1 11:33:56 1999 Catherine Moore <clm@cygnus.com>
-
- * arm.h: Renumber relocs to conform to standard.
- (EF_NEW_ABI): Define.
- (EF_OLD_ABI): Define.
- * arm-oabi.h: New file.
-
-1999-01-28 Nick Clifton <nickc@cygnus.com>
-
- * fr30.h: Add R_FR30_GNU_VT{INHERIT,ENTRY} relocs.
-
-1999-01-27 Nick Clifton <nickc@cygnus.com>
-
- * dwarf2.h: Add typedefs for structures found in dwarf2 sections.
-
-1998-12-16 Gavin Romig-Koch <gavin@cygnus.com>
-
- * mips.h (E_MIPS_MACH_4111): New.
-
-1998-12-15 Gavin Romig-Koch <gavin@cygnus.com>
-
- * mips.h (EF_MIPS_ABI,E_MIPS_ABI_O32,E_MIPS_ABI_O64,
- E_MIPS_ABI_EABI32,E_MIPS_ABI_EABI64):
-
-1998-12-03 Nick Clifton <nickc@cygnus.com>
-
- * fr30.h: Add R_FR30_48 reloc.
-
-1998-12-02 Ulrich Drepper <drepper@cygnus.com>
-
- * mips.h: Add external data type for conflict section.
-
- * mips.h: Add more LL_* options from Irix 6.5.
-
- * mips.h: Add R_MIPS_JALR and adjust R_MIPS_max appropriately.
-
-Mon Nov 30 15:25:58 1998 J"orn Rennecke <amylaar@cygnus.co.uk>
-
- * sh.h (elf_sh_reloc_type): Add R_SH_FIRST_INVALID_RELOC,
- R_SH_LAST_INVALID_RELOC, R_SH_SWITCH8 and R_SH_max.
-
-Tue Nov 10 15:12:28 1998 Nick Clifton <nickc@cygnus.com>
-
- * common.h (EM_CYGNUS_FR30): Reduce to a 16 bit value.
-
-Tue Nov 10 15:17:28 1998 Catherine Moore <clm@cygnus.com>
-
- * d10v.h: Add vtable relocs.
-
-Wed Nov 4 15:56:50 1998 Nick Clifton <nickc@cygnus.com>
-
- * common.h (EM_CYGNUS_FR30): New machine number.
-
- * fr30.h: New file: Definitions for the FR30.
-
-Fri Oct 30 11:54:15 1998 Catherine Moore <clm@cygnus.com>
-
- From Philip Blundell <pb@nexus.co.uk>:
- * arm.h (R_ARM_COPY, et al.): New relocs, used by Linux for PIC.
- (EF_ALIGN8): New flag.
-
-Tue Oct 20 11:19:50 1998 Ian Lance Taylor <ian@cygnus.com>
-
- * common.h (NT_LWPSTATUS): Close comment accidentally left open.
-
-Mon Oct 19 20:24:11 1998 Catherine Moore <clm@cygnus.com>
-
- * sh.h: Add vtable relocs.
-
-Mon Oct 19 01:44:42 1998 Felix Lee <flee@cygnus.com>
-
- * common.h (NT_PSTATUS, NT_FPREGS, NT_PSINFO,
- NT_LWPSTATUS,NT_LWPSINFO): added.
- * internal.h (Elf_Internal_Note): new structure members.
-
-Fri Oct 16 14:11:25 1998 Catherine Moore <clm@cygnus.com>
-
- * m32r.h: Add vtable relocs.
-
-Tue Oct 6 09:22:22 1998 Catherine Moore <clm@cygnus.com>
-
- * sparc.h: Add vtable relocs.
-
-Mon Oct 5 09:39:22 1998 Catherine Moore <clm@cygnus.com>
-
- * v850.h: Add vtable relocs.
-
-Sun Oct 4 21:17:51 1998 Ian Lance Taylor <ian@cygnus.com>
-
- * i386.h (R_386_max): Change from 252 to 24.
-
-Mon Sep 21 12:24:44 1998 Catherine Moore <clm@cygnus.com>
-
- * i386.h: Change vtable reloc numbers.
-
-Sun Sep 20 00:54:22 1998 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
-
- * m68k.h: Add vtable relocs and R_68K_max.
-
-Tue Sep 15 09:56:49 CDT 1998 Catherine Moore <clm@cygnus.com>
-
- * arm.h: Add vtable relocs.
-
-Mon Aug 31 11:25:27 1998 Catherine Moore <clm@cygnus.com>
-
- * arm.h: Define STT_ARM_TFUNC. Remove ST_THUMB_xxxx
- definitions.
-
-Sat Aug 29 22:25:51 1998 Richard Henderson <rth@cygnus.com>
-
- * i386.h: Add vtable relocs.
-
-1998-08-25 16:42 Ulrich Drepper <drepper@cygnus.com>
-
- * common.h: Add SYMINFO_* macros to access Elf*_Syminfo information.
-
- * external.h: Add Elf_External_Syminfo definition.
-
- * internal.h: Add Elf_Internal_Syminfo, Elf32_Internal_Syminfo,
- and Elf64_Syminfo definitions.
-
-Sun Aug 9 20:26:49 CDT 1998 Catherine Moore <clm@cygnus.com>
-
- * arm.h: Add ST_THUMB definitions.
-
-Wed Aug 5 15:52:35 1998 Nick Clifton <nickc@cygnus.com>
-
- * arm.h: Add ELF header flags to specify compile time optins:
- EF_INTERWORK: New flag.
- EF_APCS_26: New flag.
- EF_APCS_FLOAT: New flag.
- EF_PIC: New flag.
-
-1998-07-31 21:28 Ulrich Drepper <drepper@cygnus.com>
-
- * mips.h: Add missing RHF_* constants.
-
-Fri Jul 31 10:01:40 1998 Catherine Moore <clm@cygnus.com>
-
- * arm.h: Add R_ARM_THM_PC9 relocation.
-
-1998-07-30 16:25 Ulrich Drepper <drepper@cygnus.com>
-
- * common.h: Add new DT_* entries and there flag macros from Solaris.
-
-Tue Jul 28 18:14:07 1998 Stan Cox <scox@equinox.cygnus.com>
-
- * sparc.h: (R_SPARC_REV32): Added for little endian data e.g. sparc 86x.
-
-Fri Jul 24 11:22:06 1998 Jeffrey A Law (law@cygnus.com)
-
- * mn10300.h: Add R_MN10300_24 relocation.
-
-1998-07-24 Ulrich Drepper <drepper@cygnus.com>
-
- * mips.h: Add MIPS64 relocation names and values.
-
-Wed Jul 22 19:29:00 Catherine Moore <clm@cygnus.com>
-
- * arm.h: Rename relocations.
-
-1998-07-22 Ulrich Drepper <drepper@cygnus.com>
-
- * ppc.h: Define enum as elf_ppc_reloc_type.
-
-Wed Jul 22 16:22:11 1998 Nick Clifton <nickc@cygnus.com>
-
- * reloc-macros.h: New file. Provides relocation macros:
- START_RELOC_NUMBERS, RELOC_NUMBER, FAKE_RELOC, EMPTY_RELOC and
- END_RELOC_NUMBERS used by other elf header files.
-
- * alpha.h: Use reloc-macros.h.
- * arc.h: Use reloc-macros.h.
- * arm.h: Use reloc-macros.h.
- * d10v.h: Use reloc-macros.h.
- * d30v.h: Use reloc-macros.h.
- * hppa.h: Use reloc-macros.h.
- * i386.h: Use reloc-macros.h.
- * m32r.h: Use reloc-macros.h.
- * m68k.h: Use reloc-macros.h.
- * mips.h: Use reloc-macros.h.
- * mn10200.h: Use reloc-macros.h.
- * mn10300.h: Use reloc-macros.h.
- * ppc.h: Use reloc-macros.h.
- * sh.h: Use reloc-macros.h.
- * sparc.h: Use reloc-macros.h.
- * v850.h: Use reloc-macros.h.
-
-1998-07-22 13:07 Ulrich Drepper <drepper@cygnus.com>
-
- * mn10300.h: Rewrite relocation definition using macros.
- * mips.h: Likewise.
- * ppc.h: Likewise.
- * alpha.h: Likewise.
- * arm.h: Likewise.
- * d10v.h: Likewise.
- * d30v.h: Likewise.
- * m32r.h: Likewise.
- * m68k.h: Likewise.
- * mn10200.h: Likewise.
- * sh.h: Likewise.
- * sparc.h: Likewise.
-
-1998-07-21 13:07 Ulrich Drepper <drepper@cygnus.com>
-
- * arm.h: New file.
- * d10v.h: New file.
- * d30v.h: New file.
- * i386.h: New file.
- * m68k.h: New file.
- * mn10200.h: New file.
- * sh.h: New file.
-
- * mips.h: Add R_MIPS_* and SHT_MIPS_* entries.
-
- * mn10300.h: Add R_MN10300_* entries.
-
- * ppc.h: Add R_PPC_* entries.
-
-1998-07-20 07:11 Ulrich Drepper <drepper@cygnus.com>
-
- * mips.h: Add ODK_*, OEX_*, OPAD_*, OHW_*, and OGP_* constants.
- Define Elf32_External_Lib.
-
-1998-07-19 15:24 Ulrich Drepper <drepper@cygnus.com>
-
- * mips.h (PT_MIPS_OPTIONS): New symbol.
- Add lots of DT_MIPS_* symbols.
-
-Fri Jun 26 10:46:35 1998 Jeffrey A Law (law@cygnus.com)
-
- * mn10300.h: New file.
-
-Thu Jun 18 19:27:56 1998 Nick Clifton <nickc@cygnus.com>
-
- * common.h (EM_960, EM_V800, EM_FR20, EM_RH32, EM_MMA,
- EM_OLD_ALPHA): Add these constants.
-
-Thu Jun 11 17:59:01 1998 Nick Clifton <nickc@cygnus.com>
-
- * common.h (EM_486, EM_S370): Add these constants.
-
-Tue Jun 9 09:35:29 1998 Nick Clifton <nickc@cygnus.com>
-
- * common.h (EM_ARM): Add this constant.
-
-Wed May 6 09:45:30 1998 Gavin Koch <gavin@cygnus.com>
-
- * mips.h (EF_MIPS_MACH,E_MIPS_MACH_*): Added.
-
-Sat Apr 25 18:35:06 1998 Richard Henderson <rth@cygnus.com>
-
- * alpha.h (STO_ALPHA_NOPV, STO_ALPHA_STD_GPLOAD): New.
-
-Wed Apr 15 15:42:45 1998 Richard Henderson <rth@cygnus.com>
-
- * common.h (EM_SPARC64): Move and rename to EM_OLD_SPARCV9.
- (EM_SPARCV9): New. This is the official ABI name and number.
-
-Sat Feb 28 17:04:41 1998 Richard Henderson <rth@cygnus.com>
-
- * alpha.h (EF_ALPHA_32BIT, EF_ALPHA_CANRELAX): New.
-
-Mon Dec 15 15:07:49 1997 Nick Clifton <nickc@cygnus.com>
-
- * m32r.h (EF_M32R_ARCH, E_M32R_ARCH): New flags to
- specify machine architecture.
-
-Fri Dec 5 11:20:08 1997 Nick Clifton <nickc@cygnus.com>
-
- * v850.h: New constants: SHN_V850_SCOMMON, SHN_V850_TCOMMON,
- SHN_V850_ZCOMMON, SHT_V850_SCOMMON, SHT_V850_TCOMMON,
- SHT_V850_ZCOMMON to handle v850 common sections.
- enum reloc_type renamed to v850_reloc_type to avoid name
- conflict.
-
-Thu Oct 23 13:55:24 1997 Richard Henderson <rth@cygnus.com>
-
- * sparc.h (enum elf_sparc_reloc_type): Add UA64 & UA16.
-
-Thu Oct 23 00:42:04 1997 Richard Henderson <rth@dot.cygnus.com>
-
- * sparc.h (DT_SPARC_REGISTER): New macro.
- (DT_SPARC_PLTFMT): In support of old sparc64-linux .plts; will
- go away soon.
-
-Tue Sep 30 13:26:58 1997 Doug Evans <dje@canuck.cygnus.com>
-
- * sparc.h (EF_SPARC_HAL_R1, EF_SPARC_EXT_MASK): New macros.
- (EF_SPARCV9_{MM,TSO,PSO,RMO}): New macros.
- (SHN_BEFORE,SHN_AFTER): New macros.
- (SHF_EXCLUDE,SHF_ORDERED): New macros.
- (STT_REGISTER): New macro.
- (R_SPARC_GLOB_JMP): Deleted, but slot reserved.
- (R_SPARC_{DISP64,PLT64,HIX22,LOX10}): New relocations.
- (R_SPARC_{H44,M44,L44,REGISTER}): New relocations.
- (ELF64_R_TYPE_{DATA,ID,INFO}): New macros.
-
-Wed Sep 17 16:41:42 1997 Nick Clifton <nickc@cygnus.com>
-
- * v850.h: Add R_V850_CALLT_6_7_OFFSET and R_V850_CALLT_16_16_OFFSET.
-
-Tue Sep 16 14:16:17 1997 Nick Clifton <nickc@cygnus.com>
-
- * v850.h (reloc_type): Add R_V850_TDA_16_16_OFFSET.
-
-Wed Sep 3 15:11:14 1997 Richard Henderson <rth@cygnus.com>
-
- * mips.h: Correct typo in comment.
-
-Wed Sep 3 11:25:57 1997 Nick Clifton <nickc@cygnus.com>
-
- * v850.h (reloc_type): Remove R_V850_16_PCREL.
-
-Tue Sep 2 17:41:05 1997 Nick Clifton <nickc@cygnus.com>
-
- * common.h: Remove magic number for V850E.
- * common.h: Remove magic number for V850EA.
- * v850.h: Add new flags for e_flags field in elf header.
-
-Mon Aug 25 16:06:47 1997 Nick Clifton <nickc@cygnus.com>
-
- * common.h (EM_CYGNUS_V850E): backend magic number for v850e.
- * common.h (EM_CYGNUS_V850EA): backend magic number for v850ea.
-
-Mon Aug 18 11:05:23 1997 Nick Clifton <nickc@cygnus.com>
-
- * v850.h (reloc_type): Add 16 bit PC relative relocation.
-
-Fri Aug 15 05:10:09 1997 Doug Evans <dje@canuck.cygnus.com>
-
- * arc.h (enum reloc): Move here from elf32-arc.c.
-
-Fri Aug 8 17:05:29 1997 Doug Evans <dje@canuck.cygnus.com>
-
- * arc.h: New file.
- * common.h (EM_CYGNUS_ARC): Define.
-
-Mon Jun 16 14:46:12 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * internal.h (Elf_Internal_Ehdr): Change e_phoff and e_shoff from
- bfd_signed_vma to bfd_size_type, as they are not signed.
-
-Wed Mar 5 15:35:26 1997 Doug Evans <dje@seba.cygnus.com>
-
- * m32r.h (SHF_M32R_CAN_RELAX): Define.
-
-Mon Feb 24 17:49:01 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * external.h: Dump the 32/64 bit specific forms of the version
- structures, and just define them as size independent.
-
- * common.h (VERSYM_HIDDEN, VERSYM_VERSION): Define.
-
-Fri Feb 21 13:00:34 1997 Doug Evans <dje@canuck.cygnus.com>
-
- * m32r.h (enum reloc_type): Add R_M32R_SDA16.
- (SHN_M32R_SCOMMON): Define.
-
-Wed Feb 19 15:35:31 1997 Ian Lance Taylor <ian@cygnus.com>
-
- From Eric Youngdale <eric@andante.jic.com>:
- * external.h, internal.h, common.h: Added new structures and
- definitions for ELF versions.
-
-Tue Feb 18 17:40:36 1997 Martin M. Hunt <hunt@pizza.cygnus.com>
-
- * common.h (EM_CYGNUS_D30V): Define.
-
-Mon Jan 27 11:54:44 1997 Doug Evans <dje@seba.cygnus.com>
-
- * m32r.h (enum reloc_type): Add R_M32R_HI16_[SU]LO,R_M32R_LO16.
-
-Fri Jan 3 11:32:51 1997 Michael Meissner <meissner@tiktok.cygnus.com>
-
- * v850.h (V850_OTHER_{TDA_BYTE,ERROR}): New bits for the st_other
- field.
- (SHN_V850_*): Remove v850 specific section indexes, which are not
- needed.
- (enum reloc_type): Move the v850 relocations here from
- elf32-v850.c
-
-Thu Jan 2 19:30:23 1997 Michael Meissner <meissner@tiktok.cygnus.com>
-
- * v850.h: New file, provide V850 specific definitions.
-
-Tue Dec 31 14:44:32 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * common.h (DT_AUXILIARY): Define.
- (DT_FILTER): Define.
-
-Wed Dec 4 05:03:37 1996 Jason Merrill <jason@yorick.cygnus.com>
-
- * dwarf2.h: Update.
-
-Tue Nov 26 10:44:47 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * mips.h (STO_MIPS16): Define.
-
-Tue Nov 12 15:45:42 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
-
- * d10v.h: Remove empty file.
-
-Tue Oct 8 11:31:24 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * mips.h (EF_MIPS_ABI2): Define.
-
-Thu Oct 3 10:01:40 1996 Jeffrey A Law (law@cygnus.com)
-
- * common.h: Break mn10x00 support into mn10200 and mn10300.
-
-Wed Oct 2 21:26:43 1996 Jeffrey A Law (law@cygnus.com)
-
- * common.h (EM_CYGNUS_MN10x00): Define.
-
-Mon Sep 23 09:18:04 1996 Doug Evans <dje@seba.cygnus.com>
-
- * m32r.h: New file.
-
-Fri Aug 30 17:06:21 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * common.h (EM_SH): Define.
-
-Tue Aug 20 14:47:54 1996 J.T. Conklin <jtc@hippo.cygnus.com>
-
- * common.h (EM_CYGNUS_V850): Define.
-
-Mon Aug 19 10:59:10 1996 Doug Evans <dje@canuck.cygnus.com>
-
- * common.h (EM_CYGNUS_M32R): Define.
-
-Mon Jul 22 18:59:55 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * mips.h (SHT_MIPS_IFACE, SHT_MIPS_CONTENT): Define.
- (SHT_MIPS_SYMBOL_LIB): Define.
- (SHF_MIPS_MERGE, SHF_MIPS_ADDR32, SHF_MIPS_ADDR64): Define.
- (SHF_MIPS_NOSTRIP, SHF_MIPS_LOCAL, SHF_MIPS_NAMES): Define.
-
-Thu Jul 18 19:12:15 1996 Stan Shebs <shebs@andros.cygnus.com>
-
- * dwarf2.h: New file.
-
-Jul 18 13:20:39 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
-
- * common.h (EM_CYGNUS_D10V): Define.
- * d10v.h: New file.
-
-Fri Jun 21 12:33:24 1996 Richard Henderson <rth@tamu.edu>
-
- * alpha.h: New file.
- * common.h (EM_ALPHA): Define.
-
-Fri May 31 17:28:05 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * mips.h (Elf_External_Options, Elf_Internal_Options): Define.
- (bfd_mips_elf_swap_options_in): Declare.
- (bfd_mips_elf_swap_options_out): Declare.
- (ODK_*): Define.
- (Elf64_External_RegInfo, Elf64_Internal_RegInfo): Define.
- (bfd_mips_elf64_swap_reginfo_in): Declare.
- (bfd_mips_elf64_swap_reginfo_out): Declare.
-
-Thu May 30 12:35:57 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * mips.h (E_MIPS_ARCH_4): Define.
-
-Wed May 29 15:35:33 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * mips.h (Elf64_Mips_External_Rel): Define.
- (Elf64_Mips_Internal_Rel): Define.
- (Elf64_Mips_External_Rela, Elf64_Mips_Internal_Rela): Define.
- (RSS_*): Define.
-
-Mon Apr 22 18:26:30 1996 Doug Evans <dje@canuck.cygnus.com>
-
- * sparc.h (R_SPARC_[56]): Always define.
-
-Mon Feb 19 01:55:56 1996 Doug Evans <dje@charmed.cygnus.com>
-
- * sparc.h (R_SPARC_{PLT32,HIPLT22,LOPLT10,PCPLT32,PCPLT22,
- PCPLT10,5,6}): Don't define ifdef SPARC64_OLD_RELOCS.
-
-Tue Feb 6 11:33:58 1996 Doug Evans <dje@charmed.cygnus.com>
-
- * sparc.h (enum sparc_elf_reloc_type): Define.
-
-Wed Jan 17 09:09:16 1996 Doug Evans <dje@canuck.cygnus.com>
-
- * common.h: Define EM_SPARC32PLUS.
- * sparc.h: New file.
-
-Thu Jan 11 16:27:34 1996 Michael Meissner <meissner@tiktok.cygnus.com>
-
- * ppc.h (SHF_EXCLUDE, SHT_ORDERED): New fields from the abi.
-
-Thu Nov 30 16:47:18 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * internal.h (struct elf_segment_map): Add includes_filehdr and
- includes_phdrs fields.
-
-Tue Nov 28 16:58:10 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * internal.h (struct elf_segment_map): Define.
-
-Tue Oct 31 15:19:36 1995 Fred Fish <fnf@cygnus.com>
-
- * common.h, dwarf.h, external.h, hppa.h, internal.h,
- mips.h, ppc.h: Protect against multiple inclusions.
-
-Thu Sep 21 13:51:58 1995 Michael Meissner <meissner@tiktok.cygnus.com>
-
- * ppc.h (EF_PPC_RELOCATABLE_LIB): Add new flag bit.
-
-Fri Sep 1 15:32:17 1995 Kazumoto Kojima <kkojima@info.kanagawa-u.ac.jp>
-
- * mips.h: Add some definitions used on Irix 5.
-
-Tue Jun 20 10:18:28 1995 Jeff Law (law@snake.cs.utah.edu)
-
- * hppa.h (CPU_PA_RISC1_0): Protect from redefinitions.
- (CPU_PA_RISC1_1): Likewise.
-
-Wed Mar 8 18:14:37 1995 Michael Meissner <meissner@tiktok.cygnus.com>
-
- * ppc.h: New file for PowerPC support.
-
-Tue Feb 14 13:59:13 1995 Michael Meissner <meissner@tiktok.cygnus.com>
-
- * common.h (EM_PPC): Use offical value of 20, not 17.
- (EM_PPC_OLD): Define this to be the old value of EM_PPC.
-
-Tue Jan 24 09:40:59 1995 Michael Meissner <meissner@tiktok.cygnus.com>
-
- * common.h (EM_PPC): New macro, PowerPC machine id.
-
-Tue Jan 17 10:51:38 1995 Ian Lance Taylor <ian@sanguine.cygnus.com>
-
- * mips.h (SHT_MIPS_MSYM, SHT_MIPS_DWARF, SHT_MIPS_EVENTS): Define.
-
-Mon Oct 17 13:43:59 1994 Ian Lance Taylor <ian@sanguine.cygnus.com>
-
- * internal.h (Elf_Internal_Shdr): Remove rawdata and size fields.
- Add bfd_section field.
-
-Tue May 24 16:11:50 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * mips.h (Elf32_External_gptab): Define.
-
-Mon May 16 13:22:04 1994 Jeff Law (law@snake.cs.utah.edu)
-
- * common.h (EM_HPPA): Delete.
- (EM_PARISC): Add.
- * hppa.h: New file.
-
-Mon May 9 13:27:03 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * common.h (SHN_LORESERVE): Rename from SHN_LORESERV.
- (ELF32_R_TYPE, ELF32_R_INFO): Don't rely on size of unsigned char.
- (ELF64_R_TYPE): Don't rely on size of unsigned long.
-
-Mon Apr 25 15:53:09 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * internal.h (Elf_Internal_Shdr): Use PTR, not void *.
-
-Fri Mar 11 00:34:59 1994 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
-
- * mips.h (SHN_MIPS_TEXT, SHN_MIPS_DATA): Define.
-
-Sat Mar 5 14:08:54 1994 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
-
- * internal.h: Remove Elf32_*, Elf64_* typedefs. These names
- cause conflicts with system headers, e.g. link.h in gdb/solib.c.
- Combine 32- and 64-bit versions of *_Internal_Dyn.
- * common.h: Replace uses of Elf64_Word, Elf64_Xword typedefs
- by their expansion.
- * mips.h: Replace uses of Elf32_Word, Elf32_Sword, Elf32_Addr
- typedefs by their expansion. Add DT_MIPS_RLD_MAP definition.
-
-Fri Feb 18 10:39:54 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * common.h (EM_CYGNUS_POWERPC): Define. This may be temporary,
- depending upon how quickly I can find a real PowerPC ABI.
-
-Mon Feb 7 08:27:13 1994 Jim Kingdon (kingdon@lioth.cygnus.com)
-
- * internal.h: Change HOST_64_BIT to BFD_HOST_64_BIT.
-
-Wed Feb 2 14:12:18 1994 Jim Kingdon (kingdon@lioth.cygnus.com)
-
- * common.h: Add comments regarding value of EM_HPPA and how to
- pick an unofficial value.
-
-Wed Nov 17 17:14:26 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * mips.h (SHT_MIPS_OPTIONS): Define.
-
-Mon Nov 8 17:57:00 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * mips.h: Added some more MIPS ABI macro definitions.
-
-Wed Nov 3 22:07:17 1993 Ken Raeburn (raeburn@rtl.cygnus.com)
-
- * common.h (EM_MIPS_RS4_BE): New macro.
-
-Tue Oct 12 07:28:18 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * mips.h: New file. MIPS ABI specific information.
-
-Mon Jun 21 13:13:43 1993 Ken Raeburn (raeburn@poseidon.cygnus.com)
-
- * internal.h: Combined 32- and 64-bit versions of all structures
- except *_Internal_Dyn. This will simply the assembler interface,
- and some bfd code.
-
-Tue May 25 02:00:16 1993 Ken Raeburn (raeburn@cambridge.cygnus.com)
-
- * external.h, internal.h, common.h: Added 64-bit versions of some
- structures and macros. Renamed old versions to put "32" in the
- name. Some are unchanged.
-
-Thu Apr 29 12:12:20 1993 Ken Raeburn (raeburn@deneb.cygnus.com)
-
- * common.h (EM_HPPA, NT_VERSION, STN_UNDEF, DT_*): New macros.
- * external.h (Elf_External_Dyn): New type.
-
- * internal.h (Elf_Intenral_Shdr): New field `size'.
- (Elf_Internal_Dyn): New type.
-
-Tue Apr 20 16:03:45 1993 Fred Fish (fnf@cygnus.com)
-
- * dwarf.h (LANG_CHILL): Change value to one randomly picked in
- the user defined range, to reduce probability of collisions.
-
-Sun Nov 15 09:34:02 1992 Fred Fish (fnf@cygnus.com)
-
- * dwarf.h (AT_src_coords): Whitespace change only.
- * dwarf.h (AT_body_begin, AT_body_end, LANG_MODULA2):
- Add from latest gcc.
- * dwarf.h (LANG_CHILL): Add as GNU extension.
-
-Sat Aug 1 13:46:53 1992 Fred Fish (fnf@cygnus.com)
-
- * dwarf.h: Replace with current version from gcc distribution.
-
-Fri Jun 19 19:05:09 1992 John Gilmore (gnu at cygnus.com)
-
- * internal.h: Add real struct tags to all the Type_Defs, so they
- can be used in prototypes where the Type_Defs are not known.
-
-Fri Apr 3 20:58:58 1992 Mark Eichin (eichin at cygnus.com)
-
- * common.h: added ELF_R_{SYM,TYPE,INFO} for handling relocation
- info
- added EM_MIPS, and corrected value of EM_860 based on System V ABI
- manual.
-
- * external.h: added Elf_External_{Rel,Rela}.
-
- * internal.h: added Elf_Internal_{Rel,Rela}.
- added rawdata to Elf_Internal_Shdr.
-
-Sat Nov 30 20:43:59 1991 Steve Chamberlain (sac at rtl.cygnus.com)
-
- * common.h, dwarf.h, external.h, internal.h, ChangeLog; moved from
- ../elf-<foo>
+For older changes see ChangeLog-9103
Local Variables:
+mode: change-log
+left-margin: 8
+fill-column: 74
version-control: never
End:
diff --git a/contrib/binutils/include/elf/ChangeLog-9103 b/contrib/binutils/include/elf/ChangeLog-9103
new file mode 100644
index 0000000..713d80d
--- /dev/null
+++ b/contrib/binutils/include/elf/ChangeLog-9103
@@ -0,0 +1,1914 @@
+2003-12-19 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
+
+ * elf/m32r.h : Added m32r-linux and PIC support. Add new ABI that
+ uses RELA.
+ (R_M32R_16_RELA, R_M32R_32_RELA, R_M32R_24_RELA,
+ R_M32R_10_PCREL_RELA, R_M32R_18_PCREL_RELA,
+ R_M32R_26_PCREL_RELA, R_M32R_HI16_ULO_RELA,
+ R_M32R_HI16_SLO_RELA, R_M32R_LO16_RELA,
+ R_M32R_SDA16_RELA, R_M32R_RELA_GNU_VTINHERIT,
+ R_M32R_RELA_GNU_VTENTRY, R_M32R_GOT24,
+ R_M32R_26_PLTREL, R_M32R_COPY, R_M32R_GLOB_DAT,
+ R_M32R_JMP_SLOT, R_M32R_RELATIVE, R_M32R_GOTOFF,
+ R_M32R_GOTPC24, R_M32R_GOT16_HI_ULO,
+ R_M32R_GOT16_HI_SLO, R_M32R_GOT16_LO,
+ R_M32R_GOTPC_HI_ULO, R_M32R_GOTPC_HI_SLO,
+ R_M32R_GOTPC_LO): New relocs.
+
+2003-12-06 Alan Modra <amodra@bigpond.net.au>
+
+ From Jan Beulich <JBeulich@novell.com>
+ * common.h (DT_HIOS): Correct value.
+
+2003-12-03 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
+
+ * elf/m32r.h: Add new machine type m32r2 and instruction modes.
+
+2003-11-06 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc.h (R_PPC_RELAX32PC): Define.
+
+2003-10-22 Alexandre Oliva <aoliva@redhat.com>,
+ Michael Snyder <msnyder@redhat.com>
+
+ * sh.h (EF_SH4A, EF_SH4AL_DSP, EF_SH4_NOFPU, EF_SH4A_NOFPU): New.
+ (EF_SH_MERGE_MACH): Combine them.
+
+2003-10-18 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * mmix.h (R_MMIX_PUSHJ_STUBBABLE): New reloc number.
+ (_bfd_mmix_before_linker_allocation): Rename from
+ _bfd_mmix_prepare_linker_allocated_gregs.
+ (_bfd_mmix_after_linker_allocation): Rename from
+ _bfd_mmix_finalize_linker_allocated_gregs.
+
+2003-10-06 Dave Brolley <brolley@redhat.com>
+
+ * frv.h (EF_FRV_CPU_FR550): New macro.
+
+2003-09-30 Chris Demetriou <cgd@broadcom.com>
+
+ * mips.h (E_MIPS_ARCH_64R2): New define.
+
+2003-09-23 DJ Delorie <dj@redhat.com>
+
+ * sh.h (R_SH_SWITCH8, R_SH_GNU_VTINHERIT, R_SH_GNU_VTENTRY,
+ R_SH_LOOP_START,R_SH_LOOP_END): Move to "reserved" spaces.
+ (R_SH_DIR16, R_SH_DIR8, R_SH_DIR8UL, R_SH_DIR8UW, R_SH_DIR8U,
+ R_SH_DIR8SW, R_SH_DIR8S, R_SH_DIR4UL, R_SH_DIR4UW, R_SH_DIR4U,
+ R_SH_PSHA, R_SH_PSHL): New.
+
+2003-09-11 James Cownie <jcownie@etnus.com>
+
+ * dwarf2.h: Add HP dwarf extensions from their hacked gdb
+ header files (ftp://ftp.hp.com/pub/lang/tools/WDB/wdb-4.0.tar.gz).
+
+2003-09-04 Nick Clifton <nickc@redhat.com>
+
+ * v850.h (E_V850E1_ARCH): Define.
+
+2003-08-21 James Cownie <jcownie@etnus.com>
+
+ * dwarf2.h: Add PGI dwarf extensions.
+
+2003-08-08 Dmitry Diky <diwil@mail.ru>
+
+ * msp430.h: Add xW42 and xE42 parts. Sort MPU list according to
+ gcc order.
+
+2003-08-07 Alan Modra <amodra@bigpond.net.au>
+
+ * reloc-macros.h (START_RELOC_NUMBERS) : Remove PARAMS macro. Use
+ C90 function definition. Formatting.
+ (RELOC_NUMBER): Remove !__STDC__ code.
+
+2003-07-28 Eric Christopher <echristo@redhat.com>
+
+ * ppc.h (R_PPC_RELAX32): New. Fake relocation.
+
+2003-07-25 H.J. Lu <hongjiu.lu@intel.com>
+
+ * v850.h (SHF_V850_GPREL): New.
+ (SHF_V850_EPREL): Likewise.
+ (SHF_V850_R0REL): Likewise.
+
+2003-07-09 Alexandre Oliva <aoliva@redhat.com>
+
+ 2001-05-16 Alexandre Oliva <aoliva@redhat.com>
+ * mn10300.h: Introduce GOTPC16, GOTOFF24, GOTOFF16 and
+ PLT16, and rename GOTPC to GOTPC32 and GOTOFF to GOTOFF32.
+ Renumbered all relocs.
+ 2001-04-12 Alexandre Oliva <aoliva@redhat.com>
+ * mn10300.h (R_MN10300_GOTPC, R_MN10300_GOTOFF,
+ R_MN10300_PLT32, R_MN10300_GOT32, R_MN10300_GOT24,
+ R_MN10300_GOT16, R_MN10300_COPY, R_MN10300_GLOB_DAT,
+ R_MN10300_JMP_SLOT, R_MN10300_RELATIVE): New relocs.
+
+2003-07-09 Alexandre Oliva <aoliva@redhat.com>
+
+ 2000-04-01 Alexandre Oliva <aoliva@cygnus.com>
+ * mn10300.h (E_MN10300_MACH_AM33_2): Renamed from
+ E_MN10300_MACH_AM332.
+ 2000-03-31 Alexandre Oliva <aoliva@cygnus.com>
+ * mn10300.h (E_MN10300_MACH_AM332): Defined.
+
+2003-07-01 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * s390.h (elf_s390_reloc_type): Add long displacement relocations
+ R_390_20, R_390_GOT20, R_390_GOTPLT20 and R_390_TLS_GOTIE20.
+
+2003-06-29 Andreas Jaeger <aj@suse.de>
+
+ * mmix.h: Convert to ISO C90 prototypes.
+ * mips.h: Likewise.
+
+2003-06-13 Robert Millan <zeratul2@wanadoo.es>
+
+ * common.h (GNU_ABI_TAG_NETBSD): New tag.
+ (GNU_ABI_TAG_FREEBSD): New tag.
+
+2003-06-10 Richard Sandiford <rsandifo@redhat.com>
+
+ * h8.h (E_H8_MACH_H8300SXN): New flag.
+
+2003-06-03 Nick Clifton <nickc@redhat.com>
+
+ * v850.h (R_V850_32): Rename to R_V850_ABS32.
+ Add R_V850_REL32.
+
+2003-05-15 Roland McGrath <roland@redhat.com>
+
+ * common.h (NT_AUXV, AT_*): New macros.
+ * external.h (Elf32_External_Auxv, Elf64_External_Auxv): New types.
+ * internal.h (Elf_Internal_Auxv): New type.
+
+2003-05-14 Michael Snyder <msnyder@redhat.com>
+ From Bernd Schmidt <bernds@redhat.com>
+ * h8.h (E_H8_MACH_H8300SX): New.
+
+2003-04-24 Dhananjay Deshpande <dhananjayd@kpitcummins.com>
+
+ * elf/h8.h (E_H8_MACH_H8300HN, E_H8_MACH_H8300SN): New
+
+2003-04-23 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * common.h (EM_SH): Amend comment to refer to SuperH.
+
+2003-04-22 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
+
+ * common.h: Replace references to Mitsubishi M32R with
+ references to Renesas M32R.
+
+2003-04-15 Rohit Kumar Srivastava <rohits@kpitcummins.com>
+
+ * common.h: Replace occurrances of 'Hitachi' with 'Renesas'.
+
+2003-04-01 Bob Wilson <bob.wilson@acm.org>
+
+ * elf/common.h (EM_XTENSA_OLD): Define.
+ * elf/xtensa.h: New file.
+
+2003-04-01 Nick Clifton <nickc@redhat.com>
+
+ * arm.h (ARM_NOTE_SECTION): Include .gnu in the string.
+
+2003-03-25 Stan Cox <scox@redhat.com>
+ Nick Clifton <nickc@redhat.com>
+
+ Contribute support for Intel's iWMMXt chip - an ARM variant:
+
+ * arm.h (ARM_NOTE_SECTION): Define.
+
+2003-03-03 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * sh.h (EF_SH_MERGE_MACH): Make sure SH2E & SH3/SH3E merge to SH3E,
+ and SH2E & SH4 merge to SH4, not SH2E.
+
+2003-02-21 Ian Wienand <ianw@gelato.unsw.edu.au>
+
+ * ia64.h (SHT_IA_64_LOPSREG, SHT_IA_64_HIPSREG,
+ SHT_IA_64_PRIORITY_INIT): Define.
+
+2003-02-18 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc64.h (IS_PPC64_TLS_RELOC): Rename from IS_TLS_RELOC.
+
+ * ppc.h: Replace DTPMOD64, TPREL64, DTPREL64 with DTPMOD32 etc.
+ (IS_PPC_TLS_RELOC): Define.
+
+2003-02-10 Nick Clifton <nickc@redhat.com>
+
+ * arm.h (EF_ARM_MAVERICK_FLOAT): Define.
+
+2003-02-05 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc.h: Add TLS relocs. Format.
+ * ppc64.h: Likewise.
+
+2003-01-27 Alexandre Oliva <aoliva@redhat.com>
+
+ * mips.h (EF_MIPS_XGOT): Define.
+
+2003-01-24 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * s390.h: Add s390 TLS relocations.
+
+2003-01-23 Nick Clifton <nickc@redhat.com>
+
+ * Add sh2e support:
+
+ 2002-04-02 Alexandre Oliva <aoliva@redhat.com>
+
+ * sh.h (EF_SH_MERGE_MACH): Handle SH2E.
+
+ 2002-04-02 Elena Zannoni <ezannoni@redhat.com>
+
+ * sh.h (EF_SH2E): New.
+
+2003-01-23 Alan Modra <amodra@bigpond.net.au>
+
+ * sh.h: Split out various bits to bfd/elf32-sh64.h.
+
+2003-01-20 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * s390.h: Rename R_390_GOTOFF to R_390_GOTOFF32. Add new gotoff,
+ gotplt and pltoff relocations.
+
+2003-01-17 Alan Modra <amodra@bigpond.net.au>
+
+ * common.h: Formatting, typo fixes.
+ (DT_ENCODING): Correct value.
+
+2003-01-17 Fabio Alemagna <falemagn@aros.org>
+
+ * common.h (ELFOSABI_AROS): Define.
+ (ELFOSABI_OPENVMS): Likewise.
+ (ELFOSABI_NSK): Likewise.
+
+2003-01-16 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc.h: Split out ppc64 definitions to..
+ * pcc64.h: ..here. New file.
+ (R_PPC64_REL30): Rename from R_PPC64_ADDR30.
+
+2003-01-13 Dmitry Diky <diwil@mail.ru>
+
+ * elf/common.h (EM_MSP430): Change e_machine value to officially
+ assigned.
+
+2003-01-02 Ben Elliston <bje@redhat.com>
+
+ * common.h (EM_IQ2000): Define.
+ * iq2000.h: New file.
+
+2002-12-30 Chris Demetriou <cgd@broadcom.com>
+
+ * mips.h (E_MIPS_ARCH_32R2): New define.
+
+2002-12-24 Dmitry Diky <diwil@mail.ru>
+
+ * common.h: Define msp430 machine numbers.
+ * msp430.h: New file. Define msp430 relocs.
+
+2002-12-20 DJ Delorie <dj@redhat.com>
+
+ * xstormy16.h: Add XSTORMY16_12.
+
+2002-12-16 Andrew MacLeod <amacleod@redhat.com>
+
+ * xstormy16.h (START_RELOC_NUMBERS) Add relocation numbers
+ for R_XSTORMY16_LO16 and R_XSTORMY16_HI16.
+
+2002-12-10 James Cownie <jcownie@etnus.com>
+
+ * dwarf2.h (DW_TAG_upc_shared_type, DW_TAG_upc_strict_type,
+ DW_TAG_upc_relaxed_type, DW_AT_upc_threads_scaled, DW_LANG_Upc):
+ Define.
+
+2002-12-01 Stephane Carrez <stcarrez@nerim.fr>
+
+ * m68hc11.h (EF_M68HC12_MACH, EF_M68HCS12_MACH): Define.
+ (EF_M68HC11_MACH_MASK, EF_M68HC11_MACH): Define.
+ (EF_M68HC11_MERGE_MACH, EF_M68HC11_CAN_MERGE_MACH): Define.
+
+2002-11-30 Alan Modra <amodra@bigpond.net.au>
+
+ * mmix.h: Replace boolean with bfd_boolean.
+ * sh.h: Likewise.
+
+2002-11-28 Alan Modra <amodra@bigpond.net.au>
+
+ * internal.h (elf32_internal_ehdr, Elf32_Internal_Ehdr,
+ elf64_internal_ehdr, Elf64_Internal_Ehdr, elf32_internal_phdr,
+ Elf32_Internal_Phdr, elf64_internal_phdr, Elf64_Internal_Phdr,
+ elf32_internal_shdr, Elf32_Internal_Shdr, elf64_internal_shdr,
+ Elf64_Internal_Shdr, elf32_internal_sym, elf64_internal_sym,
+ Elf32_Internal_Sym, Elf64_Internal_Sym, Elf32_Internal_Note,
+ elf32_internal_note, elf32_internal_rel, Elf32_Internal_Rel,
+ elf64_internal_rel, Elf64_Internal_Rel, elf32_internal_rela,
+ elf64_internal_rela, Elf32_Internal_Rela, Elf64_Internal_Rela,
+ elf32_internal_dyn, elf64_internal_dyn, Elf32_Internal_Dyn,
+ Elf64_Internal_Dyn, elf32_internal_verdef, elf64_internal_verdef,
+ elf32_internal_verdaux, elf64_internal_verdaux, elf32_internal_verneed,
+ elf64_internal_verneed, elf32_internal_vernaux, elf64_internal_vernaux,
+ elf32_internal_versym, elf64_internal_versym, Elf32_Internal_Verdef,
+ Elf64_Internal_Verdef, Elf32_Internal_Verdaux, Elf64_Internal_Verdaux,
+ Elf32_Internal_Verneed, Elf64_Internal_Verneed, Elf32_Internal_Vernaux,
+ Elf64_Internal_Vernaux, Elf32_Internal_Versym, Elf64_Internal_Versym,
+ Elf32_Internal_Syminfo, Elf64_Internal_Syminfo): Delete.
+ (Elf_Internal_Rel): Delete.
+
+2002-10-11 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * sh.h: Add SH TLS relocs.
+
+2002-09-30 Gavin Romig-Koch <gavin@redhat.com>
+ Ken Raeburn <raeburn@cygnus.com>
+ Aldy Hernandez <aldyh@redhat.com>
+ Eric Christopher <echristo@redhat.com>
+ Richard Sandiford <rsandifo@redhat.com>
+
+ * mips.h (E_MIPS_MACH_4120, E_MIPS_MACH_5400, E_MIPS_MACH_5500): New.
+
+2002-09-12 Roland McGrath <roland@redhat.com>
+
+ * dwarf2.h: Updates from GCC version of thie file:
+ (enum dwarf_location_atom): DW_OP_calli -> DW_OP_call_ref.
+ Add DW_OP_GNU_push_tls_address.
+ (DW_OP_lo_user): Change to 0xe0.
+
+2002-08-28 Catherine Moore <clm@redhat.com>
+
+ * elf/v850.h (R_V850_LONGCALL, R_V850_ALIGN,
+ R_V850_LONGJUMP): New relocations.
+
+2002-08-15 Alan Modra <amodra@bigpond.net.au>
+
+ * i370.h: Define relocs using reloc-macros.h.
+
+2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
+
+ * m68hc11.h (E_M68HC12_BANKS, E_M68HC11_I32, E_M68HC11_F64,
+ EF_M68HC11_ABI): Define for ABI specification.
+ (STO_M68HC12_FAR, STO_M68HC12_INTERRUPT): Symbol flags for
+ linker and debugger.
+ (R_M68HC11_24, R_M68HC11_LO16, R_M68HC11_PAGE): New relocs.
+ (R_M68HC11_RL_JUMP, R_M68HC11_RL_GROUP): New reloc for linker
+ relaxation.
+
+2002-07-15 Denis Chertykov <denisc@overta.ru>
+ Frank Ch. Eigler <fche@redhat.com>
+ Ben Elliston <bje@redhat.com>
+ Alan Lehotsky <alehotsky@cygnus.com>
+ John Healy <jhealy@redhat.com>
+ Graham Stott <grahams@redhat.com>
+ Jeff Johnston <jjohnstn@redhat.com>
+
+ * common.h (EM_IP2K): New macro.
+ (EM_IP2K_OLD): New macro.
+ * ip2k.h: New file.
+
+2002-07-01 Matt Thomas <matt@3am-software.com>
+
+ * vax.h: Rename EF_* to EF_VAX_*.
+
+2002-06-18 Dave Brolley <brolley@redhat.com>
+
+ From Catherine Moore, Michael Meissner, Dave Brolley:
+ * common.h (EM_CYGNUS_FRV): New macro.
+ * frv.h: New file.
+
+2002-06-06 Lars Brinkhoff <lars@nocrew.org>
+
+ * common.h: Change registry@sco.com to registry@caldera.com.
+ (EM_PDP10, EM_PDP11): Define.
+
+2002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * sh.h (_bfd_sh64_crange_qsort_cmpb, _bfd_sh64_crange_qsort_cmpl)
+ (_bfd_sh64_crange_bsearch_cmpb, _bfd_sh64_crange_bsearch_cmpl): New
+ prototypes.
+
+2002-06-01 Richard Henderson <rth@redhat.com>
+
+ * alpha.h (LITUSE_ALPHA_ADDR, LITUSE_ALPHA_BASE, LITUSE_ALPHA_BYTOFF,
+ LITUSE_ALPHA_JSR, LITUSE_ALPHA_TLSGD, LITUSE_ALPHA_TLSLDM): New.
+
+2002-05-30 Richard Henderson <rth@redhat.com>
+
+ * alpha.h (R_ALPHA_TLSGD, R_ALPHA_TLSLDM, R_ALPHA_DTPMOD64,
+ R_ALPHA_GOTDTPREL, R_ALPHA_DTPREL64, R_ALPHA_DTPRELHI,
+ R_ALPHA_DTPRELLO, R_ALPHA_DTPREL16, R_ALPHA_GOTTPREL, R_ALPHA_TPREL64,
+ R_ALPHA_TPRELHI, R_ALPHA_TPRELLO, R_ALPHA_TPREL16): New.
+
+2002-05-29 Matt Thomas <matt@3am-software.com>
+
+ * vax.h: New file
+
+2002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
+
+ * common.h (EM_DLX): Define.
+ * dlx.h: New file.
+
+2002-05-08 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * common.h (NT_GNU_ABI_TAG): Define.
+ (GNU_ABI_TAG_LINUX): Define.
+ (GNU_ABI_TAG_HURD): Define.
+ (GNU_ABI_TAG_SOLARIS): Define.
+ (NT_NETBSD_IDENT): Define.
+ (NT_FREEBSD_ABI_TAG): Define.
+
+2002-04-24 Elena Zannoni <ezannoni@redhat.com>
+
+ * dwarf2.h: Add DW_AT_GNU_vector.
+
+2002-02-13 Matt Fredette <fredette@netbsd.org>
+
+ * m68k.h (EF_M68000): Define.
+
+2002-02-12 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc.h (DT_PPC64_OPD, DT_PPC64_OPDSZ): Define.
+
+2002-02-09 Richard Henderson <rth@redhat.com>
+
+ * alpha.h (R_ALPHA_BRSGP): New.
+
+2002-02-08 Alexandre Oliva <aoliva@redhat.com>
+
+ Contribute sh64-elf.
+ 2002-01-23 Alexandre Oliva <aoliva@redhat.com>
+ * sh.h (R_SH_GOTPLT32, R_SH_GOT_LOW16, R_SH_GOT_MEDLOW16,
+ R_SH_GOT_MEDHI16, R_SH_GOT_HI16, R_SH_GOTPLT_LOW16,
+ R_SH_GOTPLT_MEDLOW16, R_SH_GOTPLT_MEDHI16, R_SH_GOTPLT_HI16,
+ R_SH_PLT_LOW16, R_SH_PLT_MEDLOW16, R_SH_PLT_MEDHI16,
+ R_SH_PLT_HI16, R_SH_GOTOFF_LOW16, R_SH_GOTOFF_MEDLOW16,
+ R_SH_GOTOFF_MEDHI16, R_SH_GOTOFF_HI16, R_SH_GOTPC_LOW16,
+ R_SH_GOTPC_MEDLOW16, R_SH_GOTPC_MEDHI16, R_SH_GOTPC_HI16,
+ R_SH_GOT10BY4, R_SH_GOTPLT10BY4, R_SH_GOT10BY8,
+ R_SH_GOTPLT10BY8, R_SH_COPY64, R_SH_GLOB_DAT64, R_SH_JMP_SLOT64,
+ R_SH_RELATIVE64): New relocs.
+ (R_SH_FIRST_INVALID_RELOC_4): Adjust.
+ 2001-05-16 Alexandre Oliva <aoliva@redhat.com>
+ * sh.h: Renumbered and renamed some SH5 relocations to match
+ official numbers and names; moved unmaching ones to the range
+ 0xf2-0xff.
+ 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
+ * sh.h (sh64_get_contents_type): Declare.
+ (sh64_address_is_shmedia): Likewise.
+ 2000-12-30 Hans-Peter Nilsson <hpn@cygnus.com>
+ * sh.h (sh64_elf_crange): New type.
+ (struct sh64_section_data): New.
+ (sh64_elf_section_data): New macro.
+ (EF_SH5): Rename back from EF_SH64.
+ 2000-12-18 Hans-Peter Nilsson <hpn@cygnus.com>
+ * sh.h (SHF_SH5_ISA32_MIXED, SHT_SH5_CR_SORTED,
+ SH64_CRANGES_SECTION_NAME, SH64_CRANGE_SIZE,
+ SH64_CRANGE_CR_ADDR_OFFSET, SH64_CRANGE_CR_SIZE_OFFSET,
+ SH64_CRANGE_CR_TYPE_OFFSET): New macros.
+ 2000-12-12 Hans-Peter Nilsson <hpn@cygnus.com>
+ * sh.h (EF_SH64): Don't define EF_SH64_ABI64.
+ 2000-11-27 Hans-Peter Nilsson <hpn@cygnus.com>
+ * sh.h (EF_SH64_32BIT_ABI, EF_SH64_64BIT_ABI): Delete.
+ (EF_SH64_ABI64): New.
+ 2000-11-23 Hans-Peter Nilsson <hpn@cygnus.com>
+ * sh.h (EF_SH64): Rename from EF_SH5.
+ (EF_SH64_32BIT_ABI): New.
+ (EF_SH64_64BIT_ABI): New.
+ (R_SH_PT_16, R_SH_SHMEDIA_CODE
+ R_SH_IMMU5, R_SH_IMMS6, R_SH_IMMU6, R_SH_IMMS10, R_SH_IMMS10BY2,
+ R_SH_IMMS10BY4, R_SH_IMMS10BY8, R_SH_IMMS16, R_SH_IMMU16,
+ R_SH_IMM_LOW16, R_SH_IMM_LOW16_PCREL, R_SH_IMM_MEDLOW16,
+ R_SH_IMM_MEDLOW16_PCREL, R_SH_IMM_MEDHI16, R_SH_IMM_MEDHI16_PCREL,
+ R_SH_IMM_HI16, R_SH_IMM_HI16_PCREL, R_SH_64, R_SH_64_PCREL): New
+ relocs.
+ 2000-09-01 Ben Elliston <bje@redhat.com>
+ * sh.h (EF_SH5): Define.
+
+2002-02-01 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * mmix.h: Tweak comments.
+ (MMIX_LD_ALLOCATED_REG_CONTENTS_SECTION_NAME): New.
+ [BFD_ARCH_SIZE] (_bfd_mmix_prepare_linker_allocated_gregs,
+ _bfd_mmix_finalize_linker_allocated_gregs,
+ _bfd_mmix_check_all_relocs): Provide prototypes.
+
+2002-01-31 Ivan Guzvinec <ivang@opencores.org>
+
+ * or32.h: New file.
+ * common.h: Add support for or32 targets.
+
+2002-01-28 Jason Merrill <jason@redhat.com>
+
+ * dwarf2.h: Sync with gcc version.
+
+2002-01-16 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc.h (DT_PPC64_GLINK): Define.
+
+2002-01-15 Richard Earnshaw <rearnsha@arm.com>
+
+ * arm.h (F_VFP_FLOAT, EF_ARM_VFP_FLOAT): Define.
+
+2002-01-09 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * common.h: Update copyright years.
+ (NT_NETBSDCORE_PROCINFO): Define.
+ (NT_NETBSDCORE_FIRSTMACH): Define.
+
+2002-01-06 Steve Ellcey <sje@cup.hp.com>
+
+ * ia64.h (ELF_STRING_ia64_unwind_hdr): New Macro for HP-UX.
+ (SHT_IA_64_HP_OPT_ANOT): Ditto
+ (PT_IA_64_HP_OPT_ANOT): Ditto
+ (PT_IA_64_HP_HSL_ANOT): Ditto
+ (PT_IA_64_HP_STACK): Ditto
+ (SHN_IA_64_ANSI_COMMON): Ditto
+
+2001-12-17 Alan Modra <amodra@bigpond.net.au>
+
+ * external.h (Elf_External_Sym_Shndx): Declare.
+ * internal.h (struct elf_internal_sym <st_shndx>): Make it an
+ unsigned int.
+ * common.h (SHN_BAD): Define.
+
+2001-12-13 Jakub Jelinek <jakub@redhat.com>
+
+ * elf/common.h (PT_GNU_EH_FRAME): Define.
+
+2001-12-11 Alan Modra <amodra@bigpond.net.au>
+
+ * common.h (SHN_XINDEX): Comment typo fix.
+ * internal.h (Elf_Internal_Ehdr): Change existing "unsigned short"
+ size, count and index fields to "unsigned int".
+
+2001-12-07 Geoffrey Keating <geoffk@redhat.com>
+ Richard Henderson <rth@redhat.com>
+
+ * common.h (EM_XSTORMY16): Define.
+ * xstormy16.h: New file.
+
+2001-11-15 Alan Modra <amodra@bigpond.net.au>
+
+ * common.h (NT_ARCH): Define. Remove incorrect comment.
+
+2001-11-11 Geoffrey Keating <geoffk@redhat.com>
+
+ * dwarf2.h (dwarf_line_number_ops): Add DWARF 3 opcodes.
+
+2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * mmix.h: New file.
+
+2001-10-23 Alan Modra <amodra@bigpond.net.au>
+
+ * internal.h: White space changes to keep lines under 80 chars.
+
+2001-10-16 Jeff Holcomb <jeffh@redhat.com>
+
+ * internal.h (elf_internal_shdr): Make contents a unsigned char *.
+
+2001-09-18 Alan Modra <amodra@bigpond.net.au>
+
+ * internal.h (elf_internal_rela): Make r_addend a bfd_vma.
+
+2001-09-13 Alexandre Oliva <aoliva@redhat.com>
+
+ * common.h (EM_OPENRISC_OLD): Renamed the old EM_OPENRISC entry.
+
+2001-09-12 Alexandre Oliva <aoliva@redhat.com>
+
+ * common.h (EM_AVR_OLD): Renamed from...
+ (EM_AVR): this, redefined as in the current ELF standard.
+ (EM_PJ_OLD): Renamed from...
+ (EM_PJ): this, redefined as in the current ELF standard.
+ (EM_R30, EM_D10V, EM_D30V, EM_V850, EM_M32R, EM_MN10300,
+ EM_MN10200, EM_OPENRISC, EM_ARC_A5, EM_XTENSA): Defined as in
+ the current ELF standard.
+ (EM_CYGNUS_ARC): Removed, unused for a long time.
+
+2001-09-04 Richard Henderson <rth@redhat.com>
+
+ * alpha.h (R_ALPHA_OP*, R_ALPHA_IMMED*, R_ALPHA_GPVALUE): Remove.
+ (R_ALPHA_GPREL16): Rename from R_ALPHA_IMMED_GP_16.
+
+2001-08-30 Eric Christopher <echristo@redhat.com>
+
+ * mips.h: Remove E_MIPS_MACH_MIPS32_4K.
+
+2001-08-29 Jeff Law <law@redhat.com>
+
+ * h8.h (EF_H8_MACH): New mask for encoded machine type.
+ (E_H8_MACH_H8300, E_H8_MACH_H8300H, E_H8_MACH_H8300S): New
+ machine types.
+
+2001-08-26 J"orn Rennecke <amylaar@redhat.com>
+
+ * h8.h: New file.
+
+2001-08-27 Staffan Ulfberg <staffanu@swox.se>
+
+ * ppc.h: Add relocs from the 64-bit PowerPC ELF ABI revision 1.2.
+
+2001-06-30 Daniel Berlin <dan@cgsoftware.com>
+
+ * dwarf2.h: Remerge with gcc version,
+ including all new DWARF 2.1 extensions.
+
+2001-06-29 James Cownie <jcownie@etnus.com>
+
+ * dwarf2.h: Add DWARF 2.1 attribues.
+
+2001-06-15 Per Bothner <per@bothner.com>
+
+ * dwarf2.h: Partial merge with gcc version.
+ (enum dwarf_descrim_list): Fix typo -> dwarf_discrim_list.
+ (DW_LANG_Java): Use value from dwarf 2.1 draft (also used in gcc).
+
+2001-05-15 Ralf Baechle <ralf@gnu.org>
+
+ * common.h: Remove definition of EM_MIPS_RS4_BE. The constant was
+ never in active use and is used otherwise by the ABI.
+
+2001-05-11 Jakub Jelinek <jakub@redhat.com>
+
+ * ia64.h (ELF_STRING_ia64_unwind_once): Define.
+ (ELF_STRING_ia64_unwind_info_once): Define.
+
+2001-05-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * external.h: Fix typo.
+ * mips.h: Add/Extend many comments with reference to the MIPS ELF64
+ spec v. 2.4, available at e.g.
+ ftp://oss.sgi.com/pub/linux/mips/doc/ABI/ELF64.ps.
+ (EF_MIPS_UCODE): Define.
+ (EF_MIPS_OPTIONS_FIRST): Define.
+ (EF_MIPS_ARCH_ASE): Define.
+ (EF_MIPS_ARCH_ASE_MDMX): Define.
+ (EF_MIPS_ARCH_ASE_M16): Define.
+ (SHF_MIPS_ADDR): Renamed SHF_MIPS_ADDR32.
+ (SHF_MIPS_STRING): Renamed SHF_MIPS_ADDR64.
+ (SHF_MIPS_NODUPES): Define.
+ (ELF64_MIPS_R_SSYM): New MIPS ELF 64 relocation info access macro.
+ (ELF64_MIPS_R_TYPE3): Likewise.
+ (ELF64_MIPS_R_TYPE2): Likewise.
+ (ELF64_MIPS_R_TYPE): Likewise.
+ (OHW_R10KLDL): Define.
+
+2001-04-24 Todd Fries <todd@fries.net>
+
+ * sparc.h: Fix typo.
+
+2001-04-20 Johan Rydberg <jrydberg@opencores.org>
+
+ * openrisc.h: New file.
+ * common.h (EM_OPENRISC): New constant.
+
+2001-04-23 Bo Thorsen <bo@suse.de>
+
+ * x86-64.h: Add vtable support.
+
+2001-03-23 Nick Clifton <nickc@redhat.com>
+
+ * mips.h: Remove extraneous whitespace.
+
+2001-03-22 Hans-Peter Nilsson <hp@axis.com>
+
+ * cris.h: Add leading comment about PC-relative location.
+ (R_CRIS_COPY, R_CRIS_GLOB_DAT, R_CRIS_JUMP_SLOT, R_CRIS_RELATIVE,
+ R_CRIS_16_GOT, R_CRIS_32_GOT, R_CRIS_16_GOTPLT, R_CRIS_32_GOTPLT,
+ R_CRIS_32_GOTREL, R_CRIS_32_PLT_GOTREL, R_CRIS_32_PLT_PCREL):
+ New relocs.
+
+2001-02-27 Philip Blundell <pb@futuretv.com>
+
+ * arm.h: Add new definitions from ARM document SWS ESPC 0003 B-01.
+ (EF_PIC, et al.): Rename to EF_ARM_xx.
+
+2001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * common.h: Add linux target for S/390.
+ * s390.h: New file.
+
+2001-01-11 Peter Targett <peter.targett@arccores.com>
+
+ * arc.h (E_ARC_MACH_ARC5, E_ARC_MACH_ARC6, E_ARC_MACH_ARC7,
+ E_ARC_MACH_ARC8): New definitions for cpu types.
+
+ * common.h (EM_ARC): Change comment.
+
+2000-12-12 Nick Clifton <nickc@redhat.com>
+
+ * mips.h: Fix formatting.
+
+2000-12-11 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h (DT_HP_*): Define relative to OLD_DT_LOOS for hpux
+ compatibility.
+
+2000-10-16 Chris Demetriou <cgd@sibyte.com>
+
+ * mips.h (E_MIPS_ARCH_32): New constant.
+ (E_MIPS_MACH_MIPS32, E_MIPS_MACH_MIPS32_4K): Replace the
+ former with the latter.
+
+ * mips.h (E_MIPS_ARCH_5, E_MIPS_ARCH_64): New definitions.
+
+ * mips.h (E_MIPS_MACH_SB1): New constant.
+
+2000-11-30 Jan Hubicka <jh@suse.cz>
+
+ * common.h (EM_X86_64): New macro.
+ * x86-64.h: New file.
+
+2000-11-27 Hans-Peter Nilsson <hp@axis.com>
+
+ * common.h (e_machine numbers): Clarify comments to describe how
+ EM_* constants are assigned. Move EM_PJ from official section to
+ ad-hoc section.
+ (EM_CRIS): Correct comment to match official description.
+ (EM_MMIX): Ditto.
+
+2000-11-22 Nick Clifton <nickc@redhat.com>
+
+ * common.h (EM_JAVELIN): New machine number.
+ (EM_FIREPATH): New machine number.
+ (EM_ZSP): New machine number.
+ (EM_MMIX): New machine number.
+ (EM_HUANY): New machine number.
+ (EM_PRISM): New machine number.
+ (SHT_GROUP): New section type.
+ (SHT_SYMTAB_SHNDX): New section type.
+ (SHF_GROUP): New section flag.
+ (SHN_XINDEX): New section index.
+ (GRP_COMDAT): New section group flag.
+
+2000-11-20 H.J. Lu <hjl@gnu.org>
+
+ * common.h (ELFOSABI_MONTEREY): Renamed to ...
+ (ELFOSABI_AIX): This.
+
+2000-11-16 Richard Henderson <rth@redhat.com>
+
+ Update relocations per August psABI docs.
+ * ia64.h (R_IA64_SEGBASE): Remove.
+ (R_IA64_LTV*): Renumber to 0x74 to 0x77.
+ (R_IA64_EPLTMSB, R_IA64_EPLTLSB): Remove.
+ (R_IA64_TPREL14, R_IA64_TPREL64I): New.
+ (R_IA64_DTPMOD*): New.
+ (R_IA64_DTPREL*): New.
+
+2000-09-29 Hans-Peter Nilsson <hp@axis.com>
+
+ * cris.h (EF_CRIS_UNDERSCORE): New.
+
+2000-09-27 Alan Modra <alan@linuxcare.com.au>
+
+ * hppa.h (R_PARISC_DIR14F): Add.
+
+2000-09-14 Alexandre Oliva <aoliva@redhat.com>
+
+ * sh.h (R_SH_GOT32, R_SH_PLT32, R_SH_COPY, R_SH_GLOB_DAT,
+ R_SH_JMP_SLOT, R_SH_RELATIVE, R_SH_GOTOFF, R_SH_GOTPC): Change
+ numbers to the range from 160 to 167.
+ (R_SH_FIRST_INVALID_RELOC): Adjust.
+ (R_SH_FIRST_INVALID_RELOC_2, R_SH_LAST_INVALID_RELOC_2):
+ New relocs to fill in the gap.
+
+2000-09-13 Anders Norlander <anorland@acc.umu.se>
+
+ * mips.h (E_MIPS_MACH_4K): New define.
+
+2000-09-05 Alan Modra <alan@linuxcare.com.au>
+
+ * hppa.h: Fix a comment.
+ (R_PARISC_PCREL12F): Define.
+ (R_PARISC_GNU_VTENTRY): Define.
+ (R_PARISC_GNU_VTINHERIT): Define.
+
+2000-09-01 Alexandre Oliva <aoliva@redhat.com>
+
+ * sh.h (R_SH_GOT32, R_SH_PLT32, R_SH_COPY, R_SH_GLOB_DAT,
+ R_SH_JMP_SLOT, R_SH_RELATIVE, R_SH_GOTOFF, R_SH_GOTPC): New relocs.
+ (R_SH_FIRST_INVALID_RELOC): Adjust.
+
+2000-08-14 Jim Wilson <wilson@cygnus.com>
+
+ * ia64.h (EF_IA_64_REDUCEDFP, EF_IA_64_CONS_GP,
+ EF_IA_64_NOFUNCDESC_CONS_GP, EF_IA_64_ABSOLUTE): Define.
+
+2000-08-07 Nick Clifton <nickc@cygnus.com>
+
+ * ppc.h: Remove spurious CYGNUS LOCAL comments.
+ * v850.h: Likewise.
+
+2000-07-22 Jason Eckhardt <jle@cygnus.com>
+
+ * i860.h: New file.
+ (elf_i860_reloc_type): Defined ELF32 i860 relocations.
+
+2000-07-20 Hans-Peter Nilsson <hp@axis.com>
+
+ common.h (EM_CRIS): New machine number.
+ cris.h: New file.
+
+2000-07-19 H.J. Lu <hjl@gnu.org>
+
+ * common.h (DF_1_NODEFLIB): Renamed from DF_1_NODEPLIB.
+
+2000-07-19 H.J. Lu <hjl@gnu.org>
+
+ * common.h (DT_CHECKSUM): Set to 0x6ffffdf8.
+ (DTF_1_CONFEXP): It is 0x00000002 as suspected.
+
+2000-07-19 H.J. Lu <hjl@gnu.org>
+
+ * common.h (DT_FEATURE): Renamed from DT_FEATURE_1.
+ (DT_CONFIG): New. From Solaris 8.
+ (DT_DEPAUDIT): Likewise.
+ (DT_AUDIT): Likewise.
+ (DT_PLTPAD): Likewise.
+ (DT_MOVETAB): Likewise.
+ (DF_1_NODEPLIB): Likewise.
+ (DF_1_NODUMP): Likewise.
+ (DF_1_CONLFAT): Likewise.
+ (DT_CHECKSUM): Likewise. FIXME. Check the value on Solaris 8.
+ (DTF_1_CONFEXP): Likewise.
+
+2000-07-18 H.J. Lu <hjl@gnu.org>
+
+ * common.h (DT_FLAGS_1): Renamed from DT_1_FLAGS.
+
+2000-07-12 Alan Modra <alan@linuxcare.com.au>
+
+ * internal.h (struct elf_internal_sym): Update comment for st_other.
+
+2000-07-10 Alan Modra <alan@linuxcare.com.au>
+
+ * hppa.h: Add comments to all the relocs.
+
+2000-06-26 Marek Michalkiewicz <marekm@linux.org.pl>
+
+ * avr.h (E_AVR_MACH_AVR5): Define.
+
+2000-06-18 Stephane Carrez <stcarrez@worldnet.fr>
+
+ * m68hc11.h: New file, definitions for the Motorola 68hc11.
+
+2000-06-06 Alan Modra <alan@linuxcare.com.au>
+
+ * reloc-macros.h (START_RELOC_NUMBERS): Don't define initial dummy
+ -1 valued enum.
+ (RELOC_NUMBER, FAKE_RELOC, EMPTY_RELOC): Append rather than
+ prepend comma.
+ (END_RELOC_NUMBERS): Give macro an arg to define as last enum.
+
+ * alpha.h (R_ALPHA_max): Define via END_RELOC_NUMBERS rather than
+ with EMPTY_RELOC.
+ * arc.h (R_ARC_max): Likewise.
+ * avr.h (R_AVR_max): Likewise.
+ * fr30.h (R_FR30_max): Likewise.
+ * hppa.h (R_PARISC_UNIMPLEMENTED): Likewise.
+ * i960.h (R_960_max): Likewise.
+ * m32r.h (R_M32R_max): Likewise.
+ * m68k.h (R_68K_max): Likewise.
+ * mcore.h (R_MCORE_max): Likewise.
+ * mn10300.h (R_MN10300_MAX): Likewise.
+ * pj.h (R_PJ_max): Likewise.
+ * ppc.h (R_PPC_max): Likewise.
+ * sh.h (R_SH_max): Likewise.
+ * sparc.h (R_SPARC_max): Likewise.
+ * v850.h (R_V850_max): Likewise.
+
+ * arm.h (R_ARM_max): Define via END_RELOC_NUMBERS.
+ * d10v.h (R_D10V_max): Likewise.
+ * d30v.h (R_D30V_max): Likewise.
+ * ia64.h (R_IA64_max): Likewise.
+ * mips.h (R_MIPS_maxext): Likewise.
+ * mn10200.h (R_MN10200_max): Likewise.
+
+ * i386.h (R_386_max): Remove old RELOC_NUMBER definition, and
+ define via END_RELOC_NUMBERS.
+
+2000-06-03 Alan Modra <alan@linuxcare.com.au>
+
+ * reloc-macros.h (START_RELOC_NUMBERS): Fix name clash for
+ !__STDC__ case.
+ (RELOC_NUMBER): Use ansi stringify if ALMOST_STDC defined.
+
+2000-05-22 Richard Henderson <rth@cygnus.com>
+
+ * ia64.h (R_IA64_PCREL60B, R_IA64_PCREL21BI): New.
+ (R_IA64_PCREL22, R_IA64_PCREL64I): New.
+
+2000-05-02 H.J. Lu <hjl@gnu.org>
+
+ * common.h (ELFOSABI_NONE): Renamed from ELFOSABI_SYSV.
+ (ELFOSABI_MODESTO): Defined.
+ (ELFOSABI_OPENBSD): Likewise.
+
+2000-04-21 Richard Henderson <rth@cygnus.com>
+ David Mosberger <davidm@hpl.hp.com>
+
+ * ia64.h: New file.
+
+2000-04-14 H.J. Lu <hjl@gnu.org>
+
+ * common.h (ELFOSABI_TRUE64): Renamed to ELFOSABI_TRU64.
+
+2000-04-14 H.J. Lu <hjl@gnu.org>
+
+ * common.h (ELFOSABI_NETBSD): Defined.
+ (ELFOSABI_HURD): Likewise.
+ (ELFOSABI_SOLARIS): Likewise.
+ (ELFOSABI_MONTEREY): Likewise.
+ (ELFOSABI_IRIX): Likewise.
+ (ELFOSABI_FREEBSD): Likewise.
+ (ELFOSABI_TRUE64): Likewise.
+
+2000-04-07 Nick Clifton <nickc@cygnus.com>
+
+ * arm-oabi.h: Delete.
+ * arm.h: Merge in definitions of old reloc numbers from
+ arm-oabi.h.
+
+2000-04-06 Nick Clifton <nickc@cygnus.com>
+
+ * arm.h (EF_ARM_SYMSARESORTED): Define.
+ (EF_ARM_EABIMASK): Define.
+ (EF_ARM_EABI_VERSION): Define.
+ (EF_ARM_EABI_UNKNOWN): Define.
+ (EF_ARM_EABI_VER1): Define.
+ (PF_ARM_PI): Define.
+ (PF_ARM_ABS): Define.
+
+2000-04-05 J"orn Rennecke <amylaar@cygnus.co.uk>
+
+ * sh.h (R_SH_LOOP_START, R_SH_LOOP_END): New RELOC_NUMBERs.
+
+2000-03-27 Denis Chertykov <denisc@overta.ru>
+
+ * avr.h: New file. AVR ELF support for BFD.
+ * common.h: Add AVR magic number.
+
+2000-03-10 Geoffrey Keating <geoffk@cygnus.com>
+
+ * mips.h: Add R_MIPS_GNU_REL_HI16, R_MIPS_GNU_REL_LO16,
+ R_MIPS_GNU_REL16_S2, R_MIPS_PC64 and R_MIPS_PC32 relocation
+ numbers.
+
+2000-02-23 Linas Vepstas <linas@linas.org>
+
+ * i370.h: New file.
+
+2000-02-22 Nick Clifton <nickc@cygnus.com>
+
+ * common.h (ELF_ST_OTHER): Remove definition.
+ (ELF32_ST_OTHER): Remove definition.
+ (ELF64_ST_OTHER): Remove definition.
+
+2000-02-22 H.J. Lu <hjl@gnu.org>
+
+ * common.h (ELFOSABI_LINUX): Define.
+
+2000-02-17 J"orn Rennecke <amylaar@cygnus.co.uk>
+
+ * sh.h: (EF_SH_MACH_MASK, EF_SH_UNKNOWN, EF_SH1, EF_SH2): New macros.
+ (EF_SH3, EF_SH_HAS_DSP, EF_SH_DSP, EF_SH3_DSP): Likewise.
+ (EF_SH_HAS_FP, EF_SH3E, EF_SH4, EF_SH_MERGE_MACH): Likewise.
+
+2000-02-03 H.J. Lu <hjl@gnu.org>
+
+ * arm-oabi.h: Duplicate changes made to arm.h on Jan. 27,
+ 2000 by Thomas de Lellis <tdel@windriver.com>.
+
+2000-01-27 Thomas de Lellis <tdel@windriver.com>
+
+ * arm.h (STT_ARM_TFUNC): Define in terms of STT_LOPROC.
+ (STT_ARM_16BIT): New flag. Denotes a label that was defined in
+ Thumb block but was does not identify a function.
+
+2000-01-20 Nick Clifton <nickc@cygnus.com>
+
+ * common.h (EM_MCORE): Fix spelling of Motorola.
+ * mcore.h (EM_MCORE): Fix spelling of Motorola.
+
+2000-01-13 Nick Clifton <nickc@cygnus.com>
+
+ * common.h (EM_S370): Change comment - this is now the IBM
+ System/370.
+ (EM_IA_64): Change comment - this is now the IA-64.
+
+2000-01-11 Nick Clifton <nickc@cygnus.com>
+
+ * common.h (DT_ENCODING): Fix definition of this value.
+ (DT_LOOS): Fix definition of this value.
+ (DT_HIOS): Fix definition of this value.
+ (OLD_DT_LOOS): Value of DT_LOOS before Oct 4, 1999 draft
+ of ELF spec changed it.
+ (OLD_DT_HIOS): Value of DT_HIOS before Oct 4, 1999 draft
+ of ELF spec changed it.
+
+2000-01-10 Egor Duda <deo@logos-m.ru>
+
+ * common.h (NT_WIN32PSTATUS): Define. (cygwin elf core dumps).
+
+1999-12-28 Nick Clifton <nickc@cygnus.com>
+
+ * mips.h (STO_*): Redefine in terms of STV_* values now in
+ common.h.
+
+1999-12-27 Nick Clifton <nickc@cygnus.com>
+
+ * common.h: Upgrade to match Oct4, 1999 Draft ELF ABI Spec.
+ (EM_MIPS_RS3_LE): New machine number.
+ (EM_RCE): New machine number.
+ (EM_MMA): New machine number.
+ (EM_PCP): New machine number.
+ (EM_NCPU): New machine number.
+ (EM_NDR1): New machine number.
+ (EM_STARCORE): New machine number.
+ (EM_ME16): New machine number.
+ (EM_ST100): New machine number.
+ (EM_TINYJ): New machine number.
+ (EM_FX66): New machine number.
+ (EM_ST9PLUS): New machine number.
+ (EM_ST7): New machine number.
+ (EM_68HC16): New machine number.
+ (EM_68HC11): New machine number.
+ (EM_68HC08): New machine number.
+ (EM_68HC05): New machine number.
+ (EM_SVX): New machine number.
+ (EM_VAX): New machine number.
+ (PF_MASKOS): Change value.
+ (SHT_INIT_ARRAY): New value for sh_type field.
+ (SHT_FINI_ARRAY): New value for sh_type field.
+ (SHT_PREINIT_ARRAY): New value for sh_type field.
+ (SHT_HIUSER): Change value.
+ (SHF_MERGE): New valye for sh_flags field.
+ (SHF_STRINGS): New valye for sh_flags field.
+ (SHF_INFO_LINK): New valye for sh_flags field.
+ (SHF_OS_NONCONFORMING): New valye for sh_flags field.
+ (SHF_MASKOS): Change value.
+ (ELF_ST_VISIBILITY): New macro.
+ (ELF_ST_OTHER): New macro.
+ (STT_COMMON): New symbol type.
+ (STV_DEFAULT): Value for symbol visibility.
+ (STV_INTERNAL): Value for symbol visibility.
+ (STV_HIDDEN): Value for symbol visibility.
+ (STV_PROTECTED): Value for symbol visibility.
+ (DT_RUNPATH): New dynamic section tag.
+ (DT_FLAGS): New dynamic section tag.
+ (DT_ENCODING): New dynamic section tag.
+ (DT_PREINIT_ARRAY): New dynamic section tag.
+ (DT_PREINIT_ARRAYSZ): New dynamic section tag.
+ (DT_LOPROC): New dynamic section tag index.
+ (DT_HIPROC): New dynamic section tag index.
+ (DF_ORIGIN): Value for dynamic section flag.
+ (DF_SYMBOLIC): Value for dynamic section flag.
+ (DF_TEXTREL): Value for dynamic section flag.
+ (DF_BIND_NOW): Value for dynamic section flag.
+
+1999-12-09 Fred Fish <fnf@cygnus.com>
+
+ * i960.h (reloc-macros.h): Include using relative dir elf/.
+ * i386.h (reloc-macros.h): Include using relative dir elf/.
+ * hppa.h (reloc-macros.h): Include using relative dir elf/.
+
+1999-12-07 Jim Blandy <jimb@cygnus.com>
+
+ * common.h (NT_PRXFPREG): New definition.
+
+Wed Dec 1 03:02:15 1999 Jeffrey A Law (law@cygnus.com)
+
+ * mn10300.h (E_MN10300_MACH_AM33): Define.
+
+Mon Oct 11 22:42:37 1999 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h (PF_HP_PAGE_SIZE): Define.
+ (PF_HP_FAR_SHARED, PF_HP_NEAR_SHARED, PF_HP_CODE): Likewise.
+ (PF_HP_MODIFY, PF_HP_LAZYSWAP, PF_HP_SBP): Likewise.
+
+Mon Oct 4 17:42:38 1999 Doug Evans <devans@canuck.cygnus.com>
+
+ * m32r.h (E_M32RX_ARCH): Define.
+
+1999-09-15 Ulrich Drepper <drepper@cygnus.com>
+
+ * hppa.h: Add DT_HP_GST_SIZE, DT_HP_GST_VERSION, and DT_HP_GST_HASHVAL.
+
+1999-09-04 Steve Chamberlain <sac@pobox.com>
+
+ * pj.h: New file.
+ * common.h (EM_PJ): Define.
+
+1999-09-02 Ulrich Drepper <drepper@cygnus.com>
+
+ * hppa.h: Add HPUX specific symbol type definitions.
+
+ * hppa.h: Add HPUX specific dynamic and program header table
+ specific definitions.
+
+1999-08-31 Scott Bambrough <scottb@netwinder.org>
+
+ * common.h (NT_TASKSTRUCT): Define.
+
+1999-07-16 Jakub Jelinek <jj@ultra.linux.cz>
+
+ * sparc.h (EF_SPARC_SUN_US3): Define in Cheetah extensions
+ flag (as per SCD2.4.1).
+
+1999-07-16 Jakub Jelinek <jj@ultra.linux.cz>
+
+ * sparc.h (ELF64_R_TYPE_DATA): Only use ELF64_R_TYPE bits, not
+ ELF64_R_SYM bits.
+
+1999-06-21 Philip Blundell <pb@nexus.co.uk>
+
+ * arm.h (EF_SOFT_FLOAT, F_SOFT_FLOAT): Define.
+
+1999-07-13 Andreas Schwab <schwab@suse.de>
+
+ * m68k.h (EF_CPU32): Move definition inside multiple inclusion
+ guard.
+
+1999-07-08 Richard Henderson <rth@cygnus.com>
+
+ * sparc.h (ELF64_R_TYPE_DATA): Sign extend the value.
+ (ELF64_R_TYPE_INFO): Mask out all but low 24 bits of data.
+ (DT_SPARC_PLTFMT): Delete.
+ Based on a patch from Jakub Jelinek.
+
+Mon Jun 21 16:36:02 1999 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h (elf_hppa_reloc_type): Renamed from elf32_hppa_reloc_type.
+
+1999-06-10 Jakub Jelinek <jj@ultra.linux.cz>
+
+ * sparc.h (R_SPARC_max_std): Define.
+
+Wed Jun 9 15:16:34 1999 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h: Update with various changes from newest PA ELF
+ specifications.
+
+1999-06-03 Ian Lance Taylor <ian@zembu.com>
+
+ * common.h (EM_PPC64): Define.
+
+1999-06-02 Stu Grossman <grossman@babylon-5.cygnus.com>
+
+ * dwarf.h: Add LANG_JAVA.
+ * dwarf2.h: Add DW_LANG_Java.
+
+1999-05-29 Nick Clifton <nickc@cygnus.com>
+
+ * common.h (ELFOSABI_ARM): Define.
+
+1999-05-28 Nick Clifton <nickc@cygnus.com>
+
+ * reloc-macros.h: Update comment.
+
+1999-05-28 Ian Lance Taylor <ian@zembu.com>
+
+ * i960.h: New file.
+
+1999-05-16 Nick Clifton <nickc@cygnus.com>
+
+ * mcore.h (R_MCORE_COPY): Define.
+ (R_MCORE_GLOB_DAT): Define.
+ (R_MCORE_JUMP_SLOT): Define.
+
+1999-05-15 Nick Clifton <nickc@cygnus.com>
+
+ * mcore.h (R_MCORE_RELATIVE): Define.
+
+1999-05-05 Catherine Moore <clm@cygnus.com>
+
+ * m68k.h (EF_CPU32): Define.
+
+1999-04-21 Nick Clifton <nickc@cygnus.com>
+
+ * reloc-macros.h (START_RELOC_NUMBERS): Prepend an underscore to
+ fake reloc entry name (if possible), in order to avoid conflicts
+ with typedefs of the same name.
+
+1999-04-16 Gavin Romig-Koch <gavin@cygnus.com>
+
+ * mips.h (EF_MIPS_32BITMODE): New.
+
+1999-04-08 Nick Clifton <nickc@cygnus.com>
+
+ * mcore.h: New header file. Defines for Motorola's MCore
+ processor.
+
+1999-04-08 Nick Clifton <nickc@cygnus.com>
+
+ * common.h: Add new constants defined in: "System V Application
+ Binary Interface - DRAFT - April 29, 1998" found at the web site:
+ http://www.sco.com/developer/gabi/contents.html
+
+ (EM_MMA): Removed. Replaced with EM_MCORE as Motorolla own this
+ value.
+
+1999-03-31 Nick Clifton <nickc@cygnus.com>
+
+ * reloc-macros.h: Fixed to not generate an enum with a trailing
+ comma.
+
+1999-03-16 Gavin Romig-Koch <gavin@cygnus.com>
+
+ * mips.h (E_MIPS_MACH_5000): New.
+
+1999-03-10 Ulrich Drepper <drepper@cygnus.com>
+
+ * common.h: Add definitions for a few more Solaris ELF extensions.
+
+Thu Feb 18 18:58:26 1999 Ian Lance Taylor <ian@cygnus.com>
+
+ * external.h: Only use attribute if __GNUC__ is defined.
+
+1999-02-17 Nick Clifton <nickc@cygnus.com>
+
+ Patch submitted by: Scott Bambrough <scottb@corelcomputer.com>
+
+ * external.h: struct Elf_External_Versym must be packed on
+ ARM. Code uses sizeof(Elf_External_Versym) and assumes it is
+ equal to sizeof(char[2]). Reported by Jim Pick <jim@jimpick.com>
+
+1999-02-02 Nick Clifton <nickc@cygnus.com>
+
+ * dwarf2.h (DWARF2_External_ARange): New structure.
+ (DWARF2_Internal_ARange): New structure.
+
+Mon Feb 1 11:33:56 1999 Catherine Moore <clm@cygnus.com>
+
+ * arm.h: Renumber relocs to conform to standard.
+ (EF_NEW_ABI): Define.
+ (EF_OLD_ABI): Define.
+ * arm-oabi.h: New file.
+
+1999-01-28 Nick Clifton <nickc@cygnus.com>
+
+ * fr30.h: Add R_FR30_GNU_VT{INHERIT,ENTRY} relocs.
+
+1999-01-27 Nick Clifton <nickc@cygnus.com>
+
+ * dwarf2.h: Add typedefs for structures found in dwarf2 sections.
+
+1998-12-16 Gavin Romig-Koch <gavin@cygnus.com>
+
+ * mips.h (E_MIPS_MACH_4111): New.
+
+1998-12-15 Gavin Romig-Koch <gavin@cygnus.com>
+
+ * mips.h (EF_MIPS_ABI,E_MIPS_ABI_O32,E_MIPS_ABI_O64,
+ E_MIPS_ABI_EABI32,E_MIPS_ABI_EABI64):
+
+1998-12-03 Nick Clifton <nickc@cygnus.com>
+
+ * fr30.h: Add R_FR30_48 reloc.
+
+1998-12-02 Ulrich Drepper <drepper@cygnus.com>
+
+ * mips.h: Add external data type for conflict section.
+
+ * mips.h: Add more LL_* options from Irix 6.5.
+
+ * mips.h: Add R_MIPS_JALR and adjust R_MIPS_max appropriately.
+
+Mon Nov 30 15:25:58 1998 J"orn Rennecke <amylaar@cygnus.co.uk>
+
+ * sh.h (elf_sh_reloc_type): Add R_SH_FIRST_INVALID_RELOC,
+ R_SH_LAST_INVALID_RELOC, R_SH_SWITCH8 and R_SH_max.
+
+Tue Nov 10 15:12:28 1998 Nick Clifton <nickc@cygnus.com>
+
+ * common.h (EM_CYGNUS_FR30): Reduce to a 16 bit value.
+
+Tue Nov 10 15:17:28 1998 Catherine Moore <clm@cygnus.com>
+
+ * d10v.h: Add vtable relocs.
+
+Wed Nov 4 15:56:50 1998 Nick Clifton <nickc@cygnus.com>
+
+ * common.h (EM_CYGNUS_FR30): New machine number.
+
+ * fr30.h: New file: Definitions for the FR30.
+
+Fri Oct 30 11:54:15 1998 Catherine Moore <clm@cygnus.com>
+
+ From Philip Blundell <pb@nexus.co.uk>:
+ * arm.h (R_ARM_COPY, et al.): New relocs, used by Linux for PIC.
+ (EF_ALIGN8): New flag.
+
+Tue Oct 20 11:19:50 1998 Ian Lance Taylor <ian@cygnus.com>
+
+ * common.h (NT_LWPSTATUS): Close comment accidentally left open.
+
+Mon Oct 19 20:24:11 1998 Catherine Moore <clm@cygnus.com>
+
+ * sh.h: Add vtable relocs.
+
+Mon Oct 19 01:44:42 1998 Felix Lee <flee@cygnus.com>
+
+ * common.h (NT_PSTATUS, NT_FPREGS, NT_PSINFO,
+ NT_LWPSTATUS,NT_LWPSINFO): added.
+ * internal.h (Elf_Internal_Note): new structure members.
+
+Fri Oct 16 14:11:25 1998 Catherine Moore <clm@cygnus.com>
+
+ * m32r.h: Add vtable relocs.
+
+Tue Oct 6 09:22:22 1998 Catherine Moore <clm@cygnus.com>
+
+ * sparc.h: Add vtable relocs.
+
+Mon Oct 5 09:39:22 1998 Catherine Moore <clm@cygnus.com>
+
+ * v850.h: Add vtable relocs.
+
+Sun Oct 4 21:17:51 1998 Ian Lance Taylor <ian@cygnus.com>
+
+ * i386.h (R_386_max): Change from 252 to 24.
+
+Mon Sep 21 12:24:44 1998 Catherine Moore <clm@cygnus.com>
+
+ * i386.h: Change vtable reloc numbers.
+
+Sun Sep 20 00:54:22 1998 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
+
+ * m68k.h: Add vtable relocs and R_68K_max.
+
+Tue Sep 15 09:56:49 CDT 1998 Catherine Moore <clm@cygnus.com>
+
+ * arm.h: Add vtable relocs.
+
+Mon Aug 31 11:25:27 1998 Catherine Moore <clm@cygnus.com>
+
+ * arm.h: Define STT_ARM_TFUNC. Remove ST_THUMB_xxxx
+ definitions.
+
+Sat Aug 29 22:25:51 1998 Richard Henderson <rth@cygnus.com>
+
+ * i386.h: Add vtable relocs.
+
+1998-08-25 16:42 Ulrich Drepper <drepper@cygnus.com>
+
+ * common.h: Add SYMINFO_* macros to access Elf*_Syminfo information.
+
+ * external.h: Add Elf_External_Syminfo definition.
+
+ * internal.h: Add Elf_Internal_Syminfo, Elf32_Internal_Syminfo,
+ and Elf64_Syminfo definitions.
+
+Sun Aug 9 20:26:49 CDT 1998 Catherine Moore <clm@cygnus.com>
+
+ * arm.h: Add ST_THUMB definitions.
+
+Wed Aug 5 15:52:35 1998 Nick Clifton <nickc@cygnus.com>
+
+ * arm.h: Add ELF header flags to specify compile time optins:
+ EF_INTERWORK: New flag.
+ EF_APCS_26: New flag.
+ EF_APCS_FLOAT: New flag.
+ EF_PIC: New flag.
+
+1998-07-31 21:28 Ulrich Drepper <drepper@cygnus.com>
+
+ * mips.h: Add missing RHF_* constants.
+
+Fri Jul 31 10:01:40 1998 Catherine Moore <clm@cygnus.com>
+
+ * arm.h: Add R_ARM_THM_PC9 relocation.
+
+1998-07-30 16:25 Ulrich Drepper <drepper@cygnus.com>
+
+ * common.h: Add new DT_* entries and there flag macros from Solaris.
+
+Tue Jul 28 18:14:07 1998 Stan Cox <scox@equinox.cygnus.com>
+
+ * sparc.h: (R_SPARC_REV32): Added for little endian data e.g. sparc 86x.
+
+Fri Jul 24 11:22:06 1998 Jeffrey A Law (law@cygnus.com)
+
+ * mn10300.h: Add R_MN10300_24 relocation.
+
+1998-07-24 Ulrich Drepper <drepper@cygnus.com>
+
+ * mips.h: Add MIPS64 relocation names and values.
+
+Wed Jul 22 19:29:00 Catherine Moore <clm@cygnus.com>
+
+ * arm.h: Rename relocations.
+
+1998-07-22 Ulrich Drepper <drepper@cygnus.com>
+
+ * ppc.h: Define enum as elf_ppc_reloc_type.
+
+Wed Jul 22 16:22:11 1998 Nick Clifton <nickc@cygnus.com>
+
+ * reloc-macros.h: New file. Provides relocation macros:
+ START_RELOC_NUMBERS, RELOC_NUMBER, FAKE_RELOC, EMPTY_RELOC and
+ END_RELOC_NUMBERS used by other elf header files.
+
+ * alpha.h: Use reloc-macros.h.
+ * arc.h: Use reloc-macros.h.
+ * arm.h: Use reloc-macros.h.
+ * d10v.h: Use reloc-macros.h.
+ * d30v.h: Use reloc-macros.h.
+ * hppa.h: Use reloc-macros.h.
+ * i386.h: Use reloc-macros.h.
+ * m32r.h: Use reloc-macros.h.
+ * m68k.h: Use reloc-macros.h.
+ * mips.h: Use reloc-macros.h.
+ * mn10200.h: Use reloc-macros.h.
+ * mn10300.h: Use reloc-macros.h.
+ * ppc.h: Use reloc-macros.h.
+ * sh.h: Use reloc-macros.h.
+ * sparc.h: Use reloc-macros.h.
+ * v850.h: Use reloc-macros.h.
+
+1998-07-22 13:07 Ulrich Drepper <drepper@cygnus.com>
+
+ * mn10300.h: Rewrite relocation definition using macros.
+ * mips.h: Likewise.
+ * ppc.h: Likewise.
+ * alpha.h: Likewise.
+ * arm.h: Likewise.
+ * d10v.h: Likewise.
+ * d30v.h: Likewise.
+ * m32r.h: Likewise.
+ * m68k.h: Likewise.
+ * mn10200.h: Likewise.
+ * sh.h: Likewise.
+ * sparc.h: Likewise.
+
+1998-07-21 13:07 Ulrich Drepper <drepper@cygnus.com>
+
+ * arm.h: New file.
+ * d10v.h: New file.
+ * d30v.h: New file.
+ * i386.h: New file.
+ * m68k.h: New file.
+ * mn10200.h: New file.
+ * sh.h: New file.
+
+ * mips.h: Add R_MIPS_* and SHT_MIPS_* entries.
+
+ * mn10300.h: Add R_MN10300_* entries.
+
+ * ppc.h: Add R_PPC_* entries.
+
+1998-07-20 07:11 Ulrich Drepper <drepper@cygnus.com>
+
+ * mips.h: Add ODK_*, OEX_*, OPAD_*, OHW_*, and OGP_* constants.
+ Define Elf32_External_Lib.
+
+1998-07-19 15:24 Ulrich Drepper <drepper@cygnus.com>
+
+ * mips.h (PT_MIPS_OPTIONS): New symbol.
+ Add lots of DT_MIPS_* symbols.
+
+Fri Jun 26 10:46:35 1998 Jeffrey A Law (law@cygnus.com)
+
+ * mn10300.h: New file.
+
+Thu Jun 18 19:27:56 1998 Nick Clifton <nickc@cygnus.com>
+
+ * common.h (EM_960, EM_V800, EM_FR20, EM_RH32, EM_MMA,
+ EM_OLD_ALPHA): Add these constants.
+
+Thu Jun 11 17:59:01 1998 Nick Clifton <nickc@cygnus.com>
+
+ * common.h (EM_486, EM_S370): Add these constants.
+
+Tue Jun 9 09:35:29 1998 Nick Clifton <nickc@cygnus.com>
+
+ * common.h (EM_ARM): Add this constant.
+
+Wed May 6 09:45:30 1998 Gavin Koch <gavin@cygnus.com>
+
+ * mips.h (EF_MIPS_MACH,E_MIPS_MACH_*): Added.
+
+Sat Apr 25 18:35:06 1998 Richard Henderson <rth@cygnus.com>
+
+ * alpha.h (STO_ALPHA_NOPV, STO_ALPHA_STD_GPLOAD): New.
+
+Wed Apr 15 15:42:45 1998 Richard Henderson <rth@cygnus.com>
+
+ * common.h (EM_SPARC64): Move and rename to EM_OLD_SPARCV9.
+ (EM_SPARCV9): New. This is the official ABI name and number.
+
+Sat Feb 28 17:04:41 1998 Richard Henderson <rth@cygnus.com>
+
+ * alpha.h (EF_ALPHA_32BIT, EF_ALPHA_CANRELAX): New.
+
+Mon Dec 15 15:07:49 1997 Nick Clifton <nickc@cygnus.com>
+
+ * m32r.h (EF_M32R_ARCH, E_M32R_ARCH): New flags to
+ specify machine architecture.
+
+Fri Dec 5 11:20:08 1997 Nick Clifton <nickc@cygnus.com>
+
+ * v850.h: New constants: SHN_V850_SCOMMON, SHN_V850_TCOMMON,
+ SHN_V850_ZCOMMON, SHT_V850_SCOMMON, SHT_V850_TCOMMON,
+ SHT_V850_ZCOMMON to handle v850 common sections.
+ enum reloc_type renamed to v850_reloc_type to avoid name
+ conflict.
+
+Thu Oct 23 13:55:24 1997 Richard Henderson <rth@cygnus.com>
+
+ * sparc.h (enum elf_sparc_reloc_type): Add UA64 & UA16.
+
+Thu Oct 23 00:42:04 1997 Richard Henderson <rth@dot.cygnus.com>
+
+ * sparc.h (DT_SPARC_REGISTER): New macro.
+ (DT_SPARC_PLTFMT): In support of old sparc64-linux .plts; will
+ go away soon.
+
+Tue Sep 30 13:26:58 1997 Doug Evans <dje@canuck.cygnus.com>
+
+ * sparc.h (EF_SPARC_HAL_R1, EF_SPARC_EXT_MASK): New macros.
+ (EF_SPARCV9_{MM,TSO,PSO,RMO}): New macros.
+ (SHN_BEFORE,SHN_AFTER): New macros.
+ (SHF_EXCLUDE,SHF_ORDERED): New macros.
+ (STT_REGISTER): New macro.
+ (R_SPARC_GLOB_JMP): Deleted, but slot reserved.
+ (R_SPARC_{DISP64,PLT64,HIX22,LOX10}): New relocations.
+ (R_SPARC_{H44,M44,L44,REGISTER}): New relocations.
+ (ELF64_R_TYPE_{DATA,ID,INFO}): New macros.
+
+Wed Sep 17 16:41:42 1997 Nick Clifton <nickc@cygnus.com>
+
+ * v850.h: Add R_V850_CALLT_6_7_OFFSET and R_V850_CALLT_16_16_OFFSET.
+
+Tue Sep 16 14:16:17 1997 Nick Clifton <nickc@cygnus.com>
+
+ * v850.h (reloc_type): Add R_V850_TDA_16_16_OFFSET.
+
+Wed Sep 3 15:11:14 1997 Richard Henderson <rth@cygnus.com>
+
+ * mips.h: Correct typo in comment.
+
+Wed Sep 3 11:25:57 1997 Nick Clifton <nickc@cygnus.com>
+
+ * v850.h (reloc_type): Remove R_V850_16_PCREL.
+
+Tue Sep 2 17:41:05 1997 Nick Clifton <nickc@cygnus.com>
+
+ * common.h: Remove magic number for V850E.
+ * common.h: Remove magic number for V850EA.
+ * v850.h: Add new flags for e_flags field in elf header.
+
+Mon Aug 25 16:06:47 1997 Nick Clifton <nickc@cygnus.com>
+
+ * common.h (EM_CYGNUS_V850E): backend magic number for v850e.
+ * common.h (EM_CYGNUS_V850EA): backend magic number for v850ea.
+
+Mon Aug 18 11:05:23 1997 Nick Clifton <nickc@cygnus.com>
+
+ * v850.h (reloc_type): Add 16 bit PC relative relocation.
+
+Fri Aug 15 05:10:09 1997 Doug Evans <dje@canuck.cygnus.com>
+
+ * arc.h (enum reloc): Move here from elf32-arc.c.
+
+Fri Aug 8 17:05:29 1997 Doug Evans <dje@canuck.cygnus.com>
+
+ * arc.h: New file.
+ * common.h (EM_CYGNUS_ARC): Define.
+
+Mon Jun 16 14:46:12 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * internal.h (Elf_Internal_Ehdr): Change e_phoff and e_shoff from
+ bfd_signed_vma to bfd_size_type, as they are not signed.
+
+Wed Mar 5 15:35:26 1997 Doug Evans <dje@seba.cygnus.com>
+
+ * m32r.h (SHF_M32R_CAN_RELAX): Define.
+
+Mon Feb 24 17:49:01 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * external.h: Dump the 32/64 bit specific forms of the version
+ structures, and just define them as size independent.
+
+ * common.h (VERSYM_HIDDEN, VERSYM_VERSION): Define.
+
+Fri Feb 21 13:00:34 1997 Doug Evans <dje@canuck.cygnus.com>
+
+ * m32r.h (enum reloc_type): Add R_M32R_SDA16.
+ (SHN_M32R_SCOMMON): Define.
+
+Wed Feb 19 15:35:31 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ From Eric Youngdale <eric@andante.jic.com>:
+ * external.h, internal.h, common.h: Added new structures and
+ definitions for ELF versions.
+
+Tue Feb 18 17:40:36 1997 Martin M. Hunt <hunt@pizza.cygnus.com>
+
+ * common.h (EM_CYGNUS_D30V): Define.
+
+Mon Jan 27 11:54:44 1997 Doug Evans <dje@seba.cygnus.com>
+
+ * m32r.h (enum reloc_type): Add R_M32R_HI16_[SU]LO,R_M32R_LO16.
+
+Fri Jan 3 11:32:51 1997 Michael Meissner <meissner@tiktok.cygnus.com>
+
+ * v850.h (V850_OTHER_{TDA_BYTE,ERROR}): New bits for the st_other
+ field.
+ (SHN_V850_*): Remove v850 specific section indexes, which are not
+ needed.
+ (enum reloc_type): Move the v850 relocations here from
+ elf32-v850.c
+
+Thu Jan 2 19:30:23 1997 Michael Meissner <meissner@tiktok.cygnus.com>
+
+ * v850.h: New file, provide V850 specific definitions.
+
+Tue Dec 31 14:44:32 1996 Ian Lance Taylor <ian@cygnus.com>
+
+ * common.h (DT_AUXILIARY): Define.
+ (DT_FILTER): Define.
+
+Wed Dec 4 05:03:37 1996 Jason Merrill <jason@yorick.cygnus.com>
+
+ * dwarf2.h: Update.
+
+Tue Nov 26 10:44:47 1996 Ian Lance Taylor <ian@cygnus.com>
+
+ * mips.h (STO_MIPS16): Define.
+
+Tue Nov 12 15:45:42 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
+
+ * d10v.h: Remove empty file.
+
+Tue Oct 8 11:31:24 1996 Ian Lance Taylor <ian@cygnus.com>
+
+ * mips.h (EF_MIPS_ABI2): Define.
+
+Thu Oct 3 10:01:40 1996 Jeffrey A Law (law@cygnus.com)
+
+ * common.h: Break mn10x00 support into mn10200 and mn10300.
+
+Wed Oct 2 21:26:43 1996 Jeffrey A Law (law@cygnus.com)
+
+ * common.h (EM_CYGNUS_MN10x00): Define.
+
+Mon Sep 23 09:18:04 1996 Doug Evans <dje@seba.cygnus.com>
+
+ * m32r.h: New file.
+
+Fri Aug 30 17:06:21 1996 Ian Lance Taylor <ian@cygnus.com>
+
+ * common.h (EM_SH): Define.
+
+Tue Aug 20 14:47:54 1996 J.T. Conklin <jtc@hippo.cygnus.com>
+
+ * common.h (EM_CYGNUS_V850): Define.
+
+Mon Aug 19 10:59:10 1996 Doug Evans <dje@canuck.cygnus.com>
+
+ * common.h (EM_CYGNUS_M32R): Define.
+
+Mon Jul 22 18:59:55 1996 Ian Lance Taylor <ian@cygnus.com>
+
+ * mips.h (SHT_MIPS_IFACE, SHT_MIPS_CONTENT): Define.
+ (SHT_MIPS_SYMBOL_LIB): Define.
+ (SHF_MIPS_MERGE, SHF_MIPS_ADDR32, SHF_MIPS_ADDR64): Define.
+ (SHF_MIPS_NOSTRIP, SHF_MIPS_LOCAL, SHF_MIPS_NAMES): Define.
+
+Thu Jul 18 19:12:15 1996 Stan Shebs <shebs@andros.cygnus.com>
+
+ * dwarf2.h: New file.
+
+Jul 18 13:20:39 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
+
+ * common.h (EM_CYGNUS_D10V): Define.
+ * d10v.h: New file.
+
+Fri Jun 21 12:33:24 1996 Richard Henderson <rth@tamu.edu>
+
+ * alpha.h: New file.
+ * common.h (EM_ALPHA): Define.
+
+Fri May 31 17:28:05 1996 Ian Lance Taylor <ian@cygnus.com>
+
+ * mips.h (Elf_External_Options, Elf_Internal_Options): Define.
+ (bfd_mips_elf_swap_options_in): Declare.
+ (bfd_mips_elf_swap_options_out): Declare.
+ (ODK_*): Define.
+ (Elf64_External_RegInfo, Elf64_Internal_RegInfo): Define.
+ (bfd_mips_elf64_swap_reginfo_in): Declare.
+ (bfd_mips_elf64_swap_reginfo_out): Declare.
+
+Thu May 30 12:35:57 1996 Ian Lance Taylor <ian@cygnus.com>
+
+ * mips.h (E_MIPS_ARCH_4): Define.
+
+Wed May 29 15:35:33 1996 Ian Lance Taylor <ian@cygnus.com>
+
+ * mips.h (Elf64_Mips_External_Rel): Define.
+ (Elf64_Mips_Internal_Rel): Define.
+ (Elf64_Mips_External_Rela, Elf64_Mips_Internal_Rela): Define.
+ (RSS_*): Define.
+
+Mon Apr 22 18:26:30 1996 Doug Evans <dje@canuck.cygnus.com>
+
+ * sparc.h (R_SPARC_[56]): Always define.
+
+Mon Feb 19 01:55:56 1996 Doug Evans <dje@charmed.cygnus.com>
+
+ * sparc.h (R_SPARC_{PLT32,HIPLT22,LOPLT10,PCPLT32,PCPLT22,
+ PCPLT10,5,6}): Don't define ifdef SPARC64_OLD_RELOCS.
+
+Tue Feb 6 11:33:58 1996 Doug Evans <dje@charmed.cygnus.com>
+
+ * sparc.h (enum sparc_elf_reloc_type): Define.
+
+Wed Jan 17 09:09:16 1996 Doug Evans <dje@canuck.cygnus.com>
+
+ * common.h: Define EM_SPARC32PLUS.
+ * sparc.h: New file.
+
+Thu Jan 11 16:27:34 1996 Michael Meissner <meissner@tiktok.cygnus.com>
+
+ * ppc.h (SHF_EXCLUDE, SHT_ORDERED): New fields from the abi.
+
+Thu Nov 30 16:47:18 1995 Ian Lance Taylor <ian@cygnus.com>
+
+ * internal.h (struct elf_segment_map): Add includes_filehdr and
+ includes_phdrs fields.
+
+Tue Nov 28 16:58:10 1995 Ian Lance Taylor <ian@cygnus.com>
+
+ * internal.h (struct elf_segment_map): Define.
+
+Tue Oct 31 15:19:36 1995 Fred Fish <fnf@cygnus.com>
+
+ * common.h, dwarf.h, external.h, hppa.h, internal.h,
+ mips.h, ppc.h: Protect against multiple inclusions.
+
+Thu Sep 21 13:51:58 1995 Michael Meissner <meissner@tiktok.cygnus.com>
+
+ * ppc.h (EF_PPC_RELOCATABLE_LIB): Add new flag bit.
+
+Fri Sep 1 15:32:17 1995 Kazumoto Kojima <kkojima@info.kanagawa-u.ac.jp>
+
+ * mips.h: Add some definitions used on Irix 5.
+
+Tue Jun 20 10:18:28 1995 Jeff Law (law@snake.cs.utah.edu)
+
+ * hppa.h (CPU_PA_RISC1_0): Protect from redefinitions.
+ (CPU_PA_RISC1_1): Likewise.
+
+Wed Mar 8 18:14:37 1995 Michael Meissner <meissner@tiktok.cygnus.com>
+
+ * ppc.h: New file for PowerPC support.
+
+Tue Feb 14 13:59:13 1995 Michael Meissner <meissner@tiktok.cygnus.com>
+
+ * common.h (EM_PPC): Use offical value of 20, not 17.
+ (EM_PPC_OLD): Define this to be the old value of EM_PPC.
+
+Tue Jan 24 09:40:59 1995 Michael Meissner <meissner@tiktok.cygnus.com>
+
+ * common.h (EM_PPC): New macro, PowerPC machine id.
+
+Tue Jan 17 10:51:38 1995 Ian Lance Taylor <ian@sanguine.cygnus.com>
+
+ * mips.h (SHT_MIPS_MSYM, SHT_MIPS_DWARF, SHT_MIPS_EVENTS): Define.
+
+Mon Oct 17 13:43:59 1994 Ian Lance Taylor <ian@sanguine.cygnus.com>
+
+ * internal.h (Elf_Internal_Shdr): Remove rawdata and size fields.
+ Add bfd_section field.
+
+Tue May 24 16:11:50 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * mips.h (Elf32_External_gptab): Define.
+
+Mon May 16 13:22:04 1994 Jeff Law (law@snake.cs.utah.edu)
+
+ * common.h (EM_HPPA): Delete.
+ (EM_PARISC): Add.
+ * hppa.h: New file.
+
+Mon May 9 13:27:03 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * common.h (SHN_LORESERVE): Rename from SHN_LORESERV.
+ (ELF32_R_TYPE, ELF32_R_INFO): Don't rely on size of unsigned char.
+ (ELF64_R_TYPE): Don't rely on size of unsigned long.
+
+Mon Apr 25 15:53:09 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * internal.h (Elf_Internal_Shdr): Use PTR, not void *.
+
+Fri Mar 11 00:34:59 1994 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
+
+ * mips.h (SHN_MIPS_TEXT, SHN_MIPS_DATA): Define.
+
+Sat Mar 5 14:08:54 1994 Peter Schauer (pes@regent.e-technik.tu-muenchen.de)
+
+ * internal.h: Remove Elf32_*, Elf64_* typedefs. These names
+ cause conflicts with system headers, e.g. link.h in gdb/solib.c.
+ Combine 32- and 64-bit versions of *_Internal_Dyn.
+ * common.h: Replace uses of Elf64_Word, Elf64_Xword typedefs
+ by their expansion.
+ * mips.h: Replace uses of Elf32_Word, Elf32_Sword, Elf32_Addr
+ typedefs by their expansion. Add DT_MIPS_RLD_MAP definition.
+
+Fri Feb 18 10:39:54 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * common.h (EM_CYGNUS_POWERPC): Define. This may be temporary,
+ depending upon how quickly I can find a real PowerPC ABI.
+
+Mon Feb 7 08:27:13 1994 Jim Kingdon (kingdon@lioth.cygnus.com)
+
+ * internal.h: Change HOST_64_BIT to BFD_HOST_64_BIT.
+
+Wed Feb 2 14:12:18 1994 Jim Kingdon (kingdon@lioth.cygnus.com)
+
+ * common.h: Add comments regarding value of EM_HPPA and how to
+ pick an unofficial value.
+
+Wed Nov 17 17:14:26 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * mips.h (SHT_MIPS_OPTIONS): Define.
+
+Mon Nov 8 17:57:00 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * mips.h: Added some more MIPS ABI macro definitions.
+
+Wed Nov 3 22:07:17 1993 Ken Raeburn (raeburn@rtl.cygnus.com)
+
+ * common.h (EM_MIPS_RS4_BE): New macro.
+
+Tue Oct 12 07:28:18 1993 Ian Lance Taylor (ian@cygnus.com)
+
+ * mips.h: New file. MIPS ABI specific information.
+
+Mon Jun 21 13:13:43 1993 Ken Raeburn (raeburn@poseidon.cygnus.com)
+
+ * internal.h: Combined 32- and 64-bit versions of all structures
+ except *_Internal_Dyn. This will simply the assembler interface,
+ and some bfd code.
+
+Tue May 25 02:00:16 1993 Ken Raeburn (raeburn@cambridge.cygnus.com)
+
+ * external.h, internal.h, common.h: Added 64-bit versions of some
+ structures and macros. Renamed old versions to put "32" in the
+ name. Some are unchanged.
+
+Thu Apr 29 12:12:20 1993 Ken Raeburn (raeburn@deneb.cygnus.com)
+
+ * common.h (EM_HPPA, NT_VERSION, STN_UNDEF, DT_*): New macros.
+ * external.h (Elf_External_Dyn): New type.
+
+ * internal.h (Elf_Intenral_Shdr): New field `size'.
+ (Elf_Internal_Dyn): New type.
+
+Tue Apr 20 16:03:45 1993 Fred Fish (fnf@cygnus.com)
+
+ * dwarf.h (LANG_CHILL): Change value to one randomly picked in
+ the user defined range, to reduce probability of collisions.
+
+Sun Nov 15 09:34:02 1992 Fred Fish (fnf@cygnus.com)
+
+ * dwarf.h (AT_src_coords): Whitespace change only.
+ * dwarf.h (AT_body_begin, AT_body_end, LANG_MODULA2):
+ Add from latest gcc.
+ * dwarf.h (LANG_CHILL): Add as GNU extension.
+
+Sat Aug 1 13:46:53 1992 Fred Fish (fnf@cygnus.com)
+
+ * dwarf.h: Replace with current version from gcc distribution.
+
+Fri Jun 19 19:05:09 1992 John Gilmore (gnu at cygnus.com)
+
+ * internal.h: Add real struct tags to all the Type_Defs, so they
+ can be used in prototypes where the Type_Defs are not known.
+
+Fri Apr 3 20:58:58 1992 Mark Eichin (eichin at cygnus.com)
+
+ * common.h: added ELF_R_{SYM,TYPE,INFO} for handling relocation
+ info
+ added EM_MIPS, and corrected value of EM_860 based on System V ABI
+ manual.
+
+ * external.h: added Elf_External_{Rel,Rela}.
+
+ * internal.h: added Elf_Internal_{Rel,Rela}.
+ added rawdata to Elf_Internal_Shdr.
+
+Sat Nov 30 20:43:59 1991 Steve Chamberlain (sac at rtl.cygnus.com)
+
+ * common.h, dwarf.h, external.h, internal.h, ChangeLog; moved from
+ ../elf-<foo>
+
+
+Local Variables:
+version-control: never
+End:
diff --git a/contrib/binutils/include/elf/arm.h b/contrib/binutils/include/elf/arm.h
index 269a225..181a9f0 100644
--- a/contrib/binutils/include/elf/arm.h
+++ b/contrib/binutils/include/elf/arm.h
@@ -34,6 +34,7 @@
#define EF_ARM_OLD_ABI 0x100
#define EF_ARM_SOFT_FLOAT 0x200
#define EF_ARM_VFP_FLOAT 0x400
+#define EF_ARM_MAVERICK_FLOAT 0x800
/* Other constants defined in the ARM ELF spec. version B-01. */
#define EF_ARM_SYMSARESORTED 0x04 /* NB conflicts with EF_INTERWORK */
@@ -139,4 +140,7 @@ START_RELOC_NUMBERS (elf_arm_reloc_type)
RELOC_NUMBER (R_ARM_RBASE, 255)
END_RELOC_NUMBERS (R_ARM_max)
+/* The name of the note section used to identify arm variants. */
+#define ARM_NOTE_SECTION ".note.gnu.arm.ident"
+
#endif /* _ELF_ARM_H */
diff --git a/contrib/binutils/include/elf/common.h b/contrib/binutils/include/elf/common.h
index 4e1b502..bf233f6 100644
--- a/contrib/binutils/include/elf/common.h
+++ b/contrib/binutils/include/elf/common.h
@@ -1,80 +1,83 @@
/* ELF support for BFD.
Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
- 2001, 2002
+ 2001, 2002, 2003
Free Software Foundation, Inc.
Written by Fred Fish @ Cygnus Support, from information published
in "UNIX System V Release 4, Programmers Guide: ANSI C and
Programming Support Tools".
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* This file is part of ELF support for BFD, and contains the portions
that are common to both the internal and external representations.
For example, ELFMAG0 is the byte 0x7F in both the internal (in-memory)
- and external (in-file) representations. */
+ and external (in-file) representations. */
#ifndef _ELF_COMMON_H
#define _ELF_COMMON_H
-/* Fields in e_ident[] */
+/* Fields in e_ident[]. */
#define EI_MAG0 0 /* File identification byte 0 index */
-#define ELFMAG0 0x7F /* Magic number byte 0 */
+#define ELFMAG0 0x7F /* Magic number byte 0 */
#define EI_MAG1 1 /* File identification byte 1 index */
-#define ELFMAG1 'E' /* Magic number byte 1 */
+#define ELFMAG1 'E' /* Magic number byte 1 */
#define EI_MAG2 2 /* File identification byte 2 index */
-#define ELFMAG2 'L' /* Magic number byte 2 */
+#define ELFMAG2 'L' /* Magic number byte 2 */
#define EI_MAG3 3 /* File identification byte 3 index */
-#define ELFMAG3 'F' /* Magic number byte 3 */
+#define ELFMAG3 'F' /* Magic number byte 3 */
#define EI_CLASS 4 /* File class */
-#define ELFCLASSNONE 0 /* Invalid class */
-#define ELFCLASS32 1 /* 32-bit objects */
-#define ELFCLASS64 2 /* 64-bit objects */
+#define ELFCLASSNONE 0 /* Invalid class */
+#define ELFCLASS32 1 /* 32-bit objects */
+#define ELFCLASS64 2 /* 64-bit objects */
#define EI_DATA 5 /* Data encoding */
-#define ELFDATANONE 0 /* Invalid data encoding */
-#define ELFDATA2LSB 1 /* 2's complement, little endian */
-#define ELFDATA2MSB 2 /* 2's complement, big endian */
+#define ELFDATANONE 0 /* Invalid data encoding */
+#define ELFDATA2LSB 1 /* 2's complement, little endian */
+#define ELFDATA2MSB 2 /* 2's complement, big endian */
#define EI_VERSION 6 /* File version */
-#define EI_OSABI 7 /* Operating System/ABI indication */
-#define ELFOSABI_NONE 0 /* UNIX System V ABI */
-#define ELFOSABI_HPUX 1 /* HP-UX operating system */
-#define ELFOSABI_NETBSD 2 /* NetBSD */
-#define ELFOSABI_LINUX 3 /* GNU/Linux */
-#define ELFOSABI_HURD 4 /* GNU/Hurd */
-#define ELFOSABI_SOLARIS 6 /* Solaris */
-#define ELFOSABI_AIX 7 /* AIX */
-#define ELFOSABI_IRIX 8 /* IRIX */
-#define ELFOSABI_FREEBSD 9 /* FreeBSD */
-#define ELFOSABI_TRU64 10 /* TRU64 UNIX */
-#define ELFOSABI_MODESTO 11 /* Novell Modesto */
-#define ELFOSABI_OPENBSD 12 /* OpenBSD */
-#define ELFOSABI_STANDALONE 255 /* Standalone (embedded) application */
-#define ELFOSABI_ARM 97 /* ARM */
-
-#define EI_ABIVERSION 8 /* ABI version */
+#define EI_OSABI 7 /* Operating System/ABI indication */
+#define ELFOSABI_NONE 0 /* UNIX System V ABI */
+#define ELFOSABI_HPUX 1 /* HP-UX operating system */
+#define ELFOSABI_NETBSD 2 /* NetBSD */
+#define ELFOSABI_LINUX 3 /* GNU/Linux */
+#define ELFOSABI_HURD 4 /* GNU/Hurd */
+#define ELFOSABI_SOLARIS 6 /* Solaris */
+#define ELFOSABI_AIX 7 /* AIX */
+#define ELFOSABI_IRIX 8 /* IRIX */
+#define ELFOSABI_FREEBSD 9 /* FreeBSD */
+#define ELFOSABI_TRU64 10 /* TRU64 UNIX */
+#define ELFOSABI_MODESTO 11 /* Novell Modesto */
+#define ELFOSABI_OPENBSD 12 /* OpenBSD */
+#define ELFOSABI_OPENVMS 13 /* OpenVMS */
+#define ELFOSABI_NSK 14 /* Hewlett-Packard Non-Stop Kernel */
+#define ELFOSABI_AROS 15 /* Amiga Research OS */
+#define ELFOSABI_ARM 97 /* ARM */
+#define ELFOSABI_STANDALONE 255 /* Standalone (embedded) application */
+
+#define EI_ABIVERSION 8 /* ABI version */
#define EI_PAD 9 /* Start of padding bytes */
@@ -86,8 +89,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define ET_EXEC 2 /* Executable file */
#define ET_DYN 3 /* Shared object file */
#define ET_CORE 4 /* Core file */
-#define ET_LOOS 0xFE00 /* Operating system-specific */
-#define ET_HIOS 0xFEFF /* Operating system-specific */
+#define ET_LOOS 0xFE00 /* Operating system-specific */
+#define ET_HIOS 0xFEFF /* Operating system-specific */
#define ET_LOPROC 0xFF00 /* Processor-specific */
#define ET_HIPROC 0xFFFF /* Processor-specific */
@@ -95,87 +98,89 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
are officially assigned by registry@caldera.com. See below for a list of
ad-hoc numbers used during initial development. */
-#define EM_NONE 0 /* No machine */
-#define EM_M32 1 /* AT&T WE 32100 */
-#define EM_SPARC 2 /* SUN SPARC */
-#define EM_386 3 /* Intel 80386 */
-#define EM_68K 4 /* Motorola m68k family */
-#define EM_88K 5 /* Motorola m88k family */
-#define EM_486 6 /* Intel 80486 *//* Reserved for future use */
-#define EM_860 7 /* Intel 80860 */
-#define EM_MIPS 8 /* MIPS R3000 (officially, big-endian only) */
-#define EM_S370 9 /* IBM System/370 */
-#define EM_MIPS_RS3_LE 10 /* MIPS R3000 little-endian (Oct 4 1999 Draft)*/ /* Depreciated */
-
-#define EM_PARISC 15 /* HPPA */
-
-#define EM_VPP550 17 /* Fujitsu VPP500 */
-#define EM_SPARC32PLUS 18 /* Sun's "v8plus" */
-#define EM_960 19 /* Intel 80960 */
-#define EM_PPC 20 /* PowerPC */
-#define EM_PPC64 21 /* 64-bit PowerPC */
-#define EM_S390 22 /* IBM S/390 */
-
-#define EM_V800 36 /* NEC V800 series */
-#define EM_FR20 37 /* Fujitsu FR20 */
-#define EM_RH32 38 /* TRW RH32 */
-#define EM_MCORE 39 /* Motorola M*Core */ /* May also be taken by Fujitsu MMA */
-#define EM_RCE 39 /* Old name for MCore */
-#define EM_ARM 40 /* ARM */
-#define EM_OLD_ALPHA 41 /* Digital Alpha */
-#define EM_SH 42 /* Hitachi SH */
-#define EM_SPARCV9 43 /* SPARC v9 64-bit */
-#define EM_TRICORE 44 /* Siemens Tricore embedded processor */
-#define EM_ARC 45 /* ARC Cores */
-#define EM_H8_300 46 /* Hitachi H8/300 */
-#define EM_H8_300H 47 /* Hitachi H8/300H */
-#define EM_H8S 48 /* Hitachi H8S */
-#define EM_H8_500 49 /* Hitachi H8/500 */
-#define EM_IA_64 50 /* Intel IA-64 Processor */
-#define EM_MIPS_X 51 /* Stanford MIPS-X */
-#define EM_COLDFIRE 52 /* Motorola Coldfire */
-#define EM_68HC12 53 /* Motorola M68HC12 */
-#define EM_MMA 54 /* Fujitsu Multimedia Accelerator */
-#define EM_PCP 55 /* Siemens PCP */
-#define EM_NCPU 56 /* Sony nCPU embedded RISC processor */
-#define EM_NDR1 57 /* Denso NDR1 microprocesspr */
-#define EM_STARCORE 58 /* Motorola Star*Core processor */
-#define EM_ME16 59 /* Toyota ME16 processor */
-#define EM_ST100 60 /* STMicroelectronics ST100 processor */
-#define EM_TINYJ 61 /* Advanced Logic Corp. TinyJ embedded processor */
-#define EM_X86_64 62 /* Advanced Micro Devices X86-64 processor */
-
-#define EM_PDP10 64 /* Digital Equipment Corp. PDP-10 */
-#define EM_PDP11 65 /* Digital Equipment Corp. PDP-11 */
-#define EM_FX66 66 /* Siemens FX66 microcontroller */
-#define EM_ST9PLUS 67 /* STMicroelectronics ST9+ 8/16 bit microcontroller */
-#define EM_ST7 68 /* STMicroelectronics ST7 8-bit microcontroller */
-#define EM_68HC16 69 /* Motorola MC68HC16 Microcontroller */
-#define EM_68HC11 70 /* Motorola MC68HC11 Microcontroller */
-#define EM_68HC08 71 /* Motorola MC68HC08 Microcontroller */
-#define EM_68HC05 72 /* Motorola MC68HC05 Microcontroller */
-#define EM_SVX 73 /* Silicon Graphics SVx */
-#define EM_ST19 74 /* STMicroelectronics ST19 8-bit cpu */
-#define EM_VAX 75 /* Digital VAX */
-#define EM_CRIS 76 /* Axis Communications 32-bit embedded processor */
-#define EM_JAVELIN 77 /* Infineon Technologies 32-bit embedded cpu */
-#define EM_FIREPATH 78 /* Element 14 64-bit DSP processor */
-#define EM_ZSP 79 /* LSI Logic's 16-bit DSP processor */
-#define EM_MMIX 80 /* Donald Knuth's educational 64-bit processor */
-#define EM_HUANY 81 /* Harvard's machine-independent format */
-#define EM_PRISM 82 /* SiTera Prism */
-#define EM_AVR 83 /* Atmel AVR 8-bit microcontroller */
-#define EM_FR30 84 /* Fujitsu FR30 */
-#define EM_D10V 85 /* Mitsubishi D10V */
-#define EM_D30V 86 /* Mitsubishi D30V */
-#define EM_V850 87 /* NEC v850 */
-#define EM_M32R 88 /* Mitsubishi M32R */
-#define EM_MN10300 89 /* Matsushita MN10300 */
-#define EM_MN10200 90 /* Matsushita MN10200 */
-#define EM_PJ 91 /* picoJava */
-#define EM_OPENRISC 92 /* OpenRISC 32-bit embedded processor */
-#define EM_ARC_A5 93 /* ARC Cores Tangent-A5 */
-#define EM_XTENSA 94 /* Tensilica Xtensa Architecture */
+#define EM_NONE 0 /* No machine */
+#define EM_M32 1 /* AT&T WE 32100 */
+#define EM_SPARC 2 /* SUN SPARC */
+#define EM_386 3 /* Intel 80386 */
+#define EM_68K 4 /* Motorola m68k family */
+#define EM_88K 5 /* Motorola m88k family */
+#define EM_486 6 /* Intel 80486 *//* Reserved for future use */
+#define EM_860 7 /* Intel 80860 */
+#define EM_MIPS 8 /* MIPS R3000 (officially, big-endian only) */
+#define EM_S370 9 /* IBM System/370 */
+#define EM_MIPS_RS3_LE 10 /* MIPS R3000 little-endian (Oct 4 1999 Draft) Deprecated */
+
+#define EM_PARISC 15 /* HPPA */
+
+#define EM_VPP550 17 /* Fujitsu VPP500 */
+#define EM_SPARC32PLUS 18 /* Sun's "v8plus" */
+#define EM_960 19 /* Intel 80960 */
+#define EM_PPC 20 /* PowerPC */
+#define EM_PPC64 21 /* 64-bit PowerPC */
+#define EM_S390 22 /* IBM S/390 */
+
+#define EM_V800 36 /* NEC V800 series */
+#define EM_FR20 37 /* Fujitsu FR20 */
+#define EM_RH32 38 /* TRW RH32 */
+#define EM_MCORE 39 /* Motorola M*Core */ /* May also be taken by Fujitsu MMA */
+#define EM_RCE 39 /* Old name for MCore */
+#define EM_ARM 40 /* ARM */
+#define EM_OLD_ALPHA 41 /* Digital Alpha */
+#define EM_SH 42 /* Renesas (formerly Hitachi) / SuperH SH */
+#define EM_SPARCV9 43 /* SPARC v9 64-bit */
+#define EM_TRICORE 44 /* Siemens Tricore embedded processor */
+#define EM_ARC 45 /* ARC Cores */
+#define EM_H8_300 46 /* Renesas (formerly Hitachi) H8/300 */
+#define EM_H8_300H 47 /* Renesas (formerly Hitachi) H8/300H */
+#define EM_H8S 48 /* Renesas (formerly Hitachi) H8S */
+#define EM_H8_500 49 /* Renesas (formerly Hitachi) H8/500 */
+#define EM_IA_64 50 /* Intel IA-64 Processor */
+#define EM_MIPS_X 51 /* Stanford MIPS-X */
+#define EM_COLDFIRE 52 /* Motorola Coldfire */
+#define EM_68HC12 53 /* Motorola M68HC12 */
+#define EM_MMA 54 /* Fujitsu Multimedia Accelerator */
+#define EM_PCP 55 /* Siemens PCP */
+#define EM_NCPU 56 /* Sony nCPU embedded RISC processor */
+#define EM_NDR1 57 /* Denso NDR1 microprocesspr */
+#define EM_STARCORE 58 /* Motorola Star*Core processor */
+#define EM_ME16 59 /* Toyota ME16 processor */
+#define EM_ST100 60 /* STMicroelectronics ST100 processor */
+#define EM_TINYJ 61 /* Advanced Logic Corp. TinyJ embedded processor */
+#define EM_X86_64 62 /* Advanced Micro Devices X86-64 processor */
+
+#define EM_PDP10 64 /* Digital Equipment Corp. PDP-10 */
+#define EM_PDP11 65 /* Digital Equipment Corp. PDP-11 */
+#define EM_FX66 66 /* Siemens FX66 microcontroller */
+#define EM_ST9PLUS 67 /* STMicroelectronics ST9+ 8/16 bit microcontroller */
+#define EM_ST7 68 /* STMicroelectronics ST7 8-bit microcontroller */
+#define EM_68HC16 69 /* Motorola MC68HC16 Microcontroller */
+#define EM_68HC11 70 /* Motorola MC68HC11 Microcontroller */
+#define EM_68HC08 71 /* Motorola MC68HC08 Microcontroller */
+#define EM_68HC05 72 /* Motorola MC68HC05 Microcontroller */
+#define EM_SVX 73 /* Silicon Graphics SVx */
+#define EM_ST19 74 /* STMicroelectronics ST19 8-bit cpu */
+#define EM_VAX 75 /* Digital VAX */
+#define EM_CRIS 76 /* Axis Communications 32-bit embedded processor */
+#define EM_JAVELIN 77 /* Infineon Technologies 32-bit embedded cpu */
+#define EM_FIREPATH 78 /* Element 14 64-bit DSP processor */
+#define EM_ZSP 79 /* LSI Logic's 16-bit DSP processor */
+#define EM_MMIX 80 /* Donald Knuth's educational 64-bit processor */
+#define EM_HUANY 81 /* Harvard's machine-independent format */
+#define EM_PRISM 82 /* SiTera Prism */
+#define EM_AVR 83 /* Atmel AVR 8-bit microcontroller */
+#define EM_FR30 84 /* Fujitsu FR30 */
+#define EM_D10V 85 /* Mitsubishi D10V */
+#define EM_D30V 86 /* Mitsubishi D30V */
+#define EM_V850 87 /* NEC v850 */
+#define EM_M32R 88 /* Renesas M32R (formerly Mitsubishi M32R) */
+#define EM_MN10300 89 /* Matsushita MN10300 */
+#define EM_MN10200 90 /* Matsushita MN10200 */
+#define EM_PJ 91 /* picoJava */
+#define EM_OPENRISC 92 /* OpenRISC 32-bit embedded processor */
+#define EM_ARC_A5 93 /* ARC Cores Tangent-A5 */
+#define EM_XTENSA 94 /* Tensilica Xtensa Architecture */
+#define EM_IP2K 101 /* Ubicom IP2022 micro controller */
+#define EM_MSP430 105 /* TI msp430 micro controller */
/* If it is necessary to assign new unofficial EM_* values, please pick large
random numbers (0x8523, 0xa7f2, etc.) to minimize the chances of collision
@@ -187,9 +192,9 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
Normally, each entity or maintainer responsible for a machine with an
unofficial e_machine number should eventually ask registry@caldera.com for
- an officially blessed number to be added to the list above. */
+ an officially blessed number to be added to the list above. */
-#define EM_PJ_OLD 99 /* picoJava */
+#define EM_PJ_OLD 99 /* picoJava */
/* Cygnus PowerPC ELF backend. Written in the absence of an ABI. */
#define EM_CYGNUS_POWERPC 0x9025
@@ -201,11 +206,11 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* Old version of PowerPC, this should be removed shortly. */
#define EM_PPC_OLD 17
-/* (Depreciated) Temporary number for the OpenRISC processor. */
-#define EM_OR32 0x8472
+/* (Deprecated) Temporary number for the OpenRISC processor. */
+#define EM_OR32 0x8472
/* Cygnus M32R ELF backend. Written in the absence of an ABI. */
-#define EM_CYGNUS_M32R 0x9041
+#define EM_CYGNUS_M32R 0x9041
/* Alpha backend magic number. Written in the absence of an ABI. */
#define EM_ALPHA 0x9026
@@ -242,10 +247,24 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
Written in the absense of an ABI. */
#define EM_DLX 0x5aa5
-#define EM_XSTORMY16 0xad45
+#define EM_XSTORMY16 0xad45
/* FRV magic number - no EABI available??. */
#define EM_CYGNUS_FRV 0x5441
+
+/* Ubicom IP2xxx; no ABI */
+#define EM_IP2K_OLD 0x8217
+
+/* MSP430 magic number
+ Written in the absense everything. */
+#define EM_MSP430_OLD 0x1059
+
+/* Vitesse IQ2000. */
+#define EM_IQ2000 0xFEBA
+
+/* Old, unofficial value for Xtensa. */
+#define EM_XTENSA_OLD 0xabc7
+
/* See the above comment before you add a new EM_* value here. */
/* Values for e_version. */
@@ -255,7 +274,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* Values for program header, p_type field. */
-#define PT_NULL 0 /* Program header table entry unused */
+#define PT_NULL 0 /* Program header table entry unused */
#define PT_LOAD 1 /* Loadable program segment */
#define PT_DYNAMIC 2 /* Dynamic linking information */
#define PT_INTERP 3 /* Program interpreter */
@@ -263,12 +282,13 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define PT_SHLIB 5 /* Reserved, unspecified semantics */
#define PT_PHDR 6 /* Entry for header table itself */
#define PT_TLS 7 /* Thread local storage segment */
-#define PT_LOOS 0x60000000 /* OS-specific */
-#define PT_HIOS 0x6fffffff /* OS-specific */
+#define PT_LOOS 0x60000000 /* OS-specific */
+#define PT_HIOS 0x6fffffff /* OS-specific */
#define PT_LOPROC 0x70000000 /* Processor-specific */
#define PT_HIPROC 0x7FFFFFFF /* Processor-specific */
#define PT_GNU_EH_FRAME (PT_LOOS + 0x474e550)
+#define PT_GNU_STACK (PT_LOOS + 0x474e551)
/* Program segment permissions, in program header p_flags field. */
@@ -294,14 +314,14 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define SHT_SHLIB 10 /* Reserved, unspecified semantics */
#define SHT_DYNSYM 11 /* Dynamic linking symbol table */
-#define SHT_INIT_ARRAY 14 /* Array of ptrs to init functions */
-#define SHT_FINI_ARRAY 15 /* Array of ptrs to finish functions */
+#define SHT_INIT_ARRAY 14 /* Array of ptrs to init functions */
+#define SHT_FINI_ARRAY 15 /* Array of ptrs to finish functions */
#define SHT_PREINIT_ARRAY 16 /* Array of ptrs to pre-init funcs */
-#define SHT_GROUP 17 /* Section contains a section group */
+#define SHT_GROUP 17 /* Section contains a section group */
#define SHT_SYMTAB_SHNDX 18 /* Indicies for SHN_XINDEX entries */
-#define SHT_LOOS 0x60000000 /* First of OS specific semantics */
-#define SHT_HIOS 0x6fffffff /* Last of OS specific semantics */
+#define SHT_LOOS 0x60000000 /* First of OS specific semantics */
+#define SHT_HIOS 0x6fffffff /* Last of OS specific semantics */
#define SHT_GNU_LIBLIST 0x6ffffff7 /* List of prelink dependencies */
@@ -330,7 +350,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define SHF_MERGE (1 << 4) /* Data in this section can be merged */
#define SHF_STRINGS (1 << 5) /* Contains null terminated character strings */
#define SHF_INFO_LINK (1 << 6) /* sh_info holds section header table index */
-#define SHF_LINK_ORDER (1 << 7) /* Preserve section ordering when linking */
+#define SHF_LINK_ORDER (1 << 7) /* Preserve section ordering when linking */
#define SHF_OS_NONCONFORMING (1 << 8) /* OS specific processing required */
#define SHF_GROUP (1 << 9) /* Member of a section group */
#define SHF_TLS (1 << 10) /* Thread local storage section */
@@ -345,7 +365,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define NT_FPREGSET 2 /* Contains copy of fpregset struct */
#define NT_PRPSINFO 3 /* Contains copy of prpsinfo struct */
#define NT_TASKSTRUCT 4 /* Contains copy of task struct */
-#define NT_PRXFPREG 0x46e62b7f /* Contains a user_xfpregs_struct; */
+#define NT_AUXV 6 /* Contains copy of Elfxx_auxv_t */
+#define NT_PRXFPREG 0x46e62b7f /* Contains a user_xfpregs_struct; */
/* note name must be "LINUX". */
/* Note segments for core files on dir-style procfs systems. */
@@ -376,11 +397,17 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define GNU_ABI_TAG_LINUX 0
#define GNU_ABI_TAG_HURD 1
#define GNU_ABI_TAG_SOLARIS 2
+#define GNU_ABI_TAG_FREEBSD 3
+#define GNU_ABI_TAG_NETBSD 4
/* Values for NetBSD .note.netbsd.ident notes. Note name is "NetBSD". */
#define NT_NETBSD_IDENT 1
+/* Values for OpenBSD .note.openbsd.ident notes. Note name is "OpenBSD". */
+
+#define NT_OPENBSD_IDENT 1
+
/* Values for FreeBSD .note.ABI-tag notes. Note name is "FreeBSD". */
#define NT_FREEBSD_ABI_TAG 1
@@ -418,8 +445,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define STB_LOCAL 0 /* Symbol not visible outside obj */
#define STB_GLOBAL 1 /* Symbol visible outside obj */
#define STB_WEAK 2 /* Like globals, lower precedence */
-#define STB_LOOS 10 /* OS-specific semantics */
-#define STB_HIOS 12 /* OS-specific semantics */
+#define STB_LOOS 10 /* OS-specific semantics */
+#define STB_HIOS 12 /* OS-specific semantics */
#define STB_LOPROC 13 /* Application-specific semantics */
#define STB_HIPROC 15 /* Application-specific semantics */
@@ -430,8 +457,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define STT_FILE 4 /* Symbol gives a file name */
#define STT_COMMON 5 /* An uninitialised common block */
#define STT_TLS 6 /* Thread local data object */
-#define STT_LOOS 10 /* OS-specific semantics */
-#define STT_HIOS 12 /* OS-specific semantics */
+#define STT_LOOS 10 /* OS-specific semantics */
+#define STT_HIOS 12 /* OS-specific semantics */
#define STT_LOPROC 13 /* Application-specific semantics */
#define STT_HIPROC 15 /* Application-specific semantics */
@@ -442,17 +469,17 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define SHN_LORESERVE 0xFF00 /* Begin range of reserved indices */
#define SHN_LOPROC 0xFF00 /* Begin range of appl-specific */
#define SHN_HIPROC 0xFF1F /* End range of appl-specific */
-#define SHN_LOOS 0xFF20 /* OS specific semantics, lo */
-#define SHN_HIOS 0xFF3F /* OS specific semantics, hi */
-#define SHN_ABS 0xFFF1 /* Associated symbol is absolute */
-#define SHN_COMMON 0xFFF2 /* Associated symbol is in common */
-#define SHN_XINDEX 0xFFFF /* Section index is held elsewhere */
-#define SHN_HIRESERVE 0xFFFF /* End range of reserved indices */
+#define SHN_LOOS 0xFF20 /* OS specific semantics, lo */
+#define SHN_HIOS 0xFF3F /* OS specific semantics, hi */
+#define SHN_ABS 0xFFF1 /* Associated symbol is absolute */
+#define SHN_COMMON 0xFFF2 /* Associated symbol is in common */
+#define SHN_XINDEX 0xFFFF /* Section index is held elsewhere */
+#define SHN_HIRESERVE 0xFFFF /* End range of reserved indices */
#define SHN_BAD ((unsigned) -1) /* Used internally by bfd */
/* The following constants control how a symbol may be accessed once it has
become part of an executable or shared library. */
-
+
#define STV_DEFAULT 0 /* Visibility is specified by binding type */
#define STV_INTERNAL 1 /* OS specific version of STV_HIDDEN */
#define STV_HIDDEN 2 /* Can only be seen inside currect component */
@@ -494,32 +521,31 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define DT_DEBUG 21
#define DT_TEXTREL 22
#define DT_JMPREL 23
-#define DT_BIND_NOW 24
-#define DT_INIT_ARRAY 25
-#define DT_FINI_ARRAY 26
+#define DT_BIND_NOW 24
+#define DT_INIT_ARRAY 25
+#define DT_FINI_ARRAY 26
#define DT_INIT_ARRAYSZ 27
#define DT_FINI_ARRAYSZ 28
-#define DT_RUNPATH 29
-#define DT_FLAGS 30
-
-#define DT_ENCODING 32
+#define DT_RUNPATH 29
+#define DT_FLAGS 30
+#define DT_ENCODING 31
#define DT_PREINIT_ARRAY 32
#define DT_PREINIT_ARRAYSZ 33
/* Note, the Oct 4, 1999 draft of the ELF ABI changed the values
for DT_LOOS and DT_HIOS. Some implementations however, use
- values outside of the new range (see below). */
+ values outside of the new range (see below). */
#define OLD_DT_LOOS 0x60000000
-#define DT_LOOS 0x6000000d
-#define DT_HIOS 0x6fff0000
-#define OLD_DT_HIOS 0x6fffffff
+#define DT_LOOS 0x6000000d
+#define DT_HIOS 0x6ffff000
+#define OLD_DT_HIOS 0x6fffffff
-#define DT_LOPROC 0x70000000
-#define DT_HIPROC 0x7fffffff
+#define DT_LOPROC 0x70000000
+#define DT_HIPROC 0x7fffffff
/* The next four dynamic tags are used on Solaris. We support them
- everywhere. Note these values lie outside of the (new) range for
- OS specific values. This is a deliberate special case and we
+ everywhere. Note these values lie outside of the (new) range for
+ OS specific values. This is a deliberate special case and we
maintain it for backwards compatability. */
#define DT_VALRNGLO 0x6ffffd00
#define DT_GNU_PRELINKED 0x6ffffdf5
@@ -578,7 +604,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
defined here is the same as the one in <sys/link.h> on Solaris 8. */
#define DTF_1_CONFEXP 0x00000002
-/* Flag values used in the DT_POSFLAG_1 .dynamic entry. */
+/* Flag values used in the DT_POSFLAG_1 .dynamic entry. */
#define DF_P1_LAZYLOAD 0x00000001
#define DF_P1_GROUPPERM 0x00000002
@@ -598,7 +624,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define DF_1_NODUMP 0x00001000
#define DF_1_CONLFAT 0x00002000
-/* Flag values for the DT_FLAGS entry. */
+/* Flag values for the DT_FLAGS entry. */
#define DF_ORIGIN (1 << 0)
#define DF_SYMBOLIC (1 << 1)
#define DF_TEXTREL (1 << 2)
@@ -665,8 +691,60 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define SYMINFO_CURRENT 1
#define SYMINFO_NUM 2
-/* Section Group Flags. */
+/* Section Group Flags. */
#define GRP_COMDAT 0x1 /* A COMDAT group */
+/* Auxv a_type values. */
+
+#define AT_NULL 0 /* End of vector */
+#define AT_IGNORE 1 /* Entry should be ignored */
+#define AT_EXECFD 2 /* File descriptor of program */
+#define AT_PHDR 3 /* Program headers for program */
+#define AT_PHENT 4 /* Size of program header entry */
+#define AT_PHNUM 5 /* Number of program headers */
+#define AT_PAGESZ 6 /* System page size */
+#define AT_BASE 7 /* Base address of interpreter */
+#define AT_FLAGS 8 /* Flags */
+#define AT_ENTRY 9 /* Entry point of program */
+#define AT_NOTELF 10 /* Program is not ELF */
+#define AT_UID 11 /* Real uid */
+#define AT_EUID 12 /* Effective uid */
+#define AT_GID 13 /* Real gid */
+#define AT_EGID 14 /* Effective gid */
+#define AT_CLKTCK 17 /* Frequency of times() */
+#define AT_PLATFORM 15 /* String identifying platform. */
+#define AT_HWCAP 16 /* Machine dependent hints about
+ processor capabilities. */
+#define AT_FPUCW 18 /* Used FPU control word. */
+#define AT_DCACHEBSIZE 19 /* Data cache block size. */
+#define AT_ICACHEBSIZE 20 /* Instruction cache block size. */
+#define AT_UCACHEBSIZE 21 /* Unified cache block size. */
+#define AT_IGNOREPPC 22 /* Entry should be ignored */
+#define AT_SECURE 23 /* Boolean, was exec setuid-like? */
+/* Pointer to the global system page used for system calls and other
+ nice things. */
+#define AT_SYSINFO 32
+#define AT_SYSINFO_EHDR 33 /* Pointer to ELF header of system-supplied DSO. */
+
+#define AT_SUN_UID 2000 /* Effective user ID. */
+#define AT_SUN_RUID 2001 /* Real user ID. */
+#define AT_SUN_GID 2002 /* Effective group ID. */
+#define AT_SUN_RGID 2003 /* Real group ID. */
+#define AT_SUN_LDELF 2004 /* Dynamic linker's ELF header. */
+#define AT_SUN_LDSHDR 2005 /* Dynamic linker's section headers. */
+#define AT_SUN_LDNAME 2006 /* String giving name of dynamic linker. */
+#define AT_SUN_LPAGESZ 2007 /* Large pagesize. */
+#define AT_SUN_PLATFORM 2008 /* Platform name string. */
+#define AT_SUN_HWCAP 2009 /* Machine dependent hints about
+ processor capabilities. */
+#define AT_SUN_IFLUSH 2010 /* Should flush icache? */
+#define AT_SUN_CPU 2011 /* CPU name string. */
+#define AT_SUN_EMUL_ENTRY 2012 /* COFF entry point address. */
+#define AT_SUN_EMUL_EXECFD 2013 /* COFF executable file descriptor. */
+#define AT_SUN_EXECNAME 2014 /* Canonicalized file name given to execve. */
+#define AT_SUN_MMU 2015 /* String for name of MMU module. */
+#define AT_SUN_LDDATA 2016 /* Dynamic linker's data segment address. */
+
+
#endif /* _ELF_COMMON_H */
diff --git a/contrib/binutils/include/elf/dwarf2.h b/contrib/binutils/include/elf/dwarf2.h
index 0e78310..bede7e2 100644
--- a/contrib/binutils/include/elf/dwarf2.h
+++ b/contrib/binutils/include/elf/dwarf2.h
@@ -1,7 +1,7 @@
/* Declarations and definitions of codes relating to the DWARF2 symbolic
debugging information format.
- Copyright (C) 1992, 1993, 1995, 1996, 1997, 1999, 2000, 2001, 2002
- Free Software Foundation, Inc.
+ Copyright (C) 1992, 1993, 1995, 1996, 1997, 1999, 2000, 2001, 2002,
+ 2003 Free Software Foundation, Inc.
Written by Gary Funck (gary@intrepid.com) The Ada Joint Program
Office (AJPO), Florida State Unviversity and Silicon Graphics Inc.
@@ -10,22 +10,22 @@
Derived from the DWARF 1 implementation written by Ron Guilmette
(rfg@netcom.com), November 1990.
-This file is part of GCC.
+ This file is part of GCC.
-GCC is free software; you can redistribute it and/or modify it under
-the terms of the GNU General Public License as published by the Free
-Software Foundation; either version 2, or (at your option) any later
-version.
+ GCC is free software; you can redistribute it and/or modify it under
+ the terms of the GNU General Public License as published by the Free
+ Software Foundation; either version 2, or (at your option) any later
+ version.
-GCC is distributed in the hope that it will be useful, but WITHOUT ANY
-WARRANTY; without even the implied warranty of MERCHANTABILITY or
-FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
-for more details.
+ GCC is distributed in the hope that it will be useful, but WITHOUT
+ ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+ or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
+ License for more details.
-You should have received a copy of the GNU General Public License
-along with GCC; see the file COPYING. If not, write to the Free
-Software Foundation, 59 Temple Place - Suite 330, Boston, MA
-02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with GCC; see the file COPYING. If not, write to the Free
+ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA. */
/* This file is derived from the DWARF specification (a public document)
Revision 2.0.0 (July 27, 1993) developed by the UNIX International
@@ -87,7 +87,7 @@ typedef struct
}
DWARF2_Internal_PubNames;
-/* Strcuture found in .debug_info section. */
+/* Structure found in .debug_info section. */
typedef struct
{
unsigned char cu_length [4];
@@ -189,12 +189,21 @@ enum dwarf_tag
DW_TAG_imported_unit = 0x3d,
/* SGI/MIPS Extensions. */
DW_TAG_MIPS_loop = 0x4081,
+ /* HP extensions. See: ftp://ftp.hp.com/pub/lang/tools/WDB/wdb-4.0.tar.gz . */
+ DW_TAG_HP_array_descriptor = 0x4090,
/* GNU extensions. */
DW_TAG_format_label = 0x4101, /* For FORTRAN 77 and Fortran 90. */
DW_TAG_function_template = 0x4102, /* For C++. */
DW_TAG_class_template = 0x4103, /* For C++. */
DW_TAG_GNU_BINCL = 0x4104,
- DW_TAG_GNU_EINCL = 0x4105
+ DW_TAG_GNU_EINCL = 0x4105,
+ /* Extensions for UPC. See: http://upc.gwu.edu/~upc. */
+ DW_TAG_upc_shared_type = 0x8765,
+ DW_TAG_upc_strict_type = 0x8766,
+ DW_TAG_upc_relaxed_type = 0x8767,
+ /* PGI (STMicroelectronics) extensions. No documentation available. */
+ DW_TAG_PGI_kanji_type = 0xA000,
+ DW_TAG_PGI_interface_block = 0xA020
};
#define DW_TAG_lo_user 0x4080
@@ -231,7 +240,6 @@ enum dwarf_form
};
/* Attribute names and codes. */
-
enum dwarf_attribute
{
DW_AT_sibling = 0x01,
@@ -309,7 +317,7 @@ enum dwarf_attribute
DW_AT_call_column = 0x57,
DW_AT_call_file = 0x58,
DW_AT_call_line = 0x59,
- /* SGI/MIPS Extensions. */
+ /* SGI/MIPS extensions. */
DW_AT_MIPS_fde = 0x2001,
DW_AT_MIPS_loop_begin = 0x2002,
DW_AT_MIPS_tail_loop_begin = 0x2003,
@@ -321,6 +329,21 @@ enum dwarf_attribute
DW_AT_MIPS_abstract_name = 0x2009,
DW_AT_MIPS_clone_origin = 0x200a,
DW_AT_MIPS_has_inlines = 0x200b,
+ /* HP extensions. */
+ DW_AT_HP_block_index = 0x2000,
+ DW_AT_HP_unmodifiable = 0x2001, /* Same as DW_AT_MIPS_fde. */
+ DW_AT_HP_actuals_stmt_list = 0x2010,
+ DW_AT_HP_proc_per_section = 0x2011,
+ DW_AT_HP_raw_data_ptr = 0x2012,
+ DW_AT_HP_pass_by_reference = 0x2013,
+ DW_AT_HP_opt_level = 0x2014,
+ DW_AT_HP_prof_version_id = 0x2015,
+ DW_AT_HP_opt_flags = 0x2016,
+ DW_AT_HP_cold_region_low_pc = 0x2017,
+ DW_AT_HP_cold_region_high_pc = 0x2018,
+ DW_AT_HP_all_variables_modifiable = 0x2019,
+ DW_AT_HP_linkage_name = 0x201a,
+ DW_AT_HP_prof_flags = 0x201b, /* In comp unit of procs_info for -g. */
/* GNU extensions. */
DW_AT_sf_names = 0x2101,
DW_AT_src_info = 0x2102,
@@ -329,8 +352,14 @@ enum dwarf_attribute
DW_AT_body_begin = 0x2105,
DW_AT_body_end = 0x2106,
DW_AT_GNU_vector = 0x2107,
- /* VMS Extensions. */
- DW_AT_VMS_rtnbeg_pd_address = 0x2201
+ /* VMS extensions. */
+ DW_AT_VMS_rtnbeg_pd_address = 0x2201,
+ /* UPC extension. */
+ DW_AT_upc_threads_scaled = 0x3210,
+ /* PGI (STMicroelectronics) extensions. */
+ DW_AT_PGI_lbase = 0x3a00,
+ DW_AT_PGI_soffset = 0x3a01,
+ DW_AT_PGI_lstride = 0x3a02
};
#define DW_AT_lo_user 0x2000 /* Implementation-defined range start. */
@@ -488,10 +517,20 @@ enum dwarf_location_atom
DW_OP_push_object_address = 0x97,
DW_OP_call2 = 0x98,
DW_OP_call4 = 0x99,
- DW_OP_calli = 0x9a
+ DW_OP_call_ref = 0x9a,
+ /* GNU extensions. */
+ DW_OP_GNU_push_tls_address = 0xe0,
+ /* HP extensions. */
+ DW_OP_HP_unknown = 0xe0, /* Ouch, the same as GNU_push_tls_address. */
+ DW_OP_HP_is_value = 0xe1,
+ DW_OP_HP_fltconst4 = 0xe2,
+ DW_OP_HP_fltconst8 = 0xe3,
+ DW_OP_HP_mod_range = 0xe4,
+ DW_OP_HP_unmod_range = 0xe5,
+ DW_OP_HP_tls = 0xe6
};
-#define DW_OP_lo_user 0x80 /* Implementation-defined range start. */
+#define DW_OP_lo_user 0xe0 /* Implementation-defined range start. */
#define DW_OP_hi_user 0xff /* Implementation-defined range end. */
/* Type encodings. */
@@ -507,7 +546,15 @@ enum dwarf_type
DW_ATE_unsigned = 0x7,
DW_ATE_unsigned_char = 0x8,
/* DWARF 3. */
- DW_ATE_imaginary_float = 0x9
+ DW_ATE_imaginary_float = 0x9,
+ /* HP extensions. */
+ DW_ATE_HP_float80 = 0x80, /* Floating-point (80 bit). */
+ DW_ATE_HP_complex_float80 = 0x81, /* Complex floating-point (80 bit). */
+ DW_ATE_HP_float128 = 0x82, /* Floating-point (128 bit). */
+ DW_ATE_HP_complex_float128 = 0x83, /* Complex floating-point (128 bit). */
+ DW_ATE_HP_floathpintel = 0x84, /* Floating-point (82 bit IA64). */
+ DW_ATE_HP_imaginary_float80 = 0x85,
+ DW_ATE_HP_imaginary_float128 = 0x86
};
#define DW_ATE_lo_user 0x80
@@ -604,7 +651,18 @@ enum dwarf_line_number_x_ops
{
DW_LNE_end_sequence = 1,
DW_LNE_set_address = 2,
- DW_LNE_define_file = 3
+ DW_LNE_define_file = 3,
+ /* HP extensions. */
+ DW_LNE_HP_negate_is_UV_update = 0x11,
+ DW_LNE_HP_push_context = 0x12,
+ DW_LNE_HP_pop_context = 0x13,
+ DW_LNE_HP_set_file_line_column = 0x14,
+ DW_LNE_HP_set_routine_name = 0x15,
+ DW_LNE_HP_set_sequence = 0x16,
+ DW_LNE_HP_negate_post_semantics = 0x17,
+ DW_LNE_HP_negate_function_exit = 0x18,
+ DW_LNE_HP_negate_front_end_logical = 0x19,
+ DW_LNE_HP_define_proc = 0x20
};
/* Call frame information. */
@@ -628,17 +686,14 @@ enum dwarf_call_frame_info
DW_CFA_def_cfa = 0x0c,
DW_CFA_def_cfa_register = 0x0d,
DW_CFA_def_cfa_offset = 0x0e,
-
/* DWARF 3. */
DW_CFA_def_cfa_expression = 0x0f,
DW_CFA_expression = 0x10,
DW_CFA_offset_extended_sf = 0x11,
DW_CFA_def_cfa_sf = 0x12,
DW_CFA_def_cfa_offset_sf = 0x13,
-
/* SGI/MIPS specific. */
DW_CFA_MIPS_advance_loc8 = 0x1d,
-
/* GNU extensions. */
DW_CFA_GNU_window_save = 0x2d,
DW_CFA_GNU_args_size = 0x2e,
@@ -676,10 +731,11 @@ enum dwarf_source_language
DW_LANG_Ada95 = 0x000d,
DW_LANG_Fortran95 = 0x000e,
/* MIPS. */
- DW_LANG_Mips_Assembler = 0x8001
+ DW_LANG_Mips_Assembler = 0x8001,
+ /* UPC. */
+ DW_LANG_Upc = 0x8765
};
-
#define DW_LANG_lo_user 0x8000 /* Implementation-defined range start. */
#define DW_LANG_hi_user 0xffff /* Implementation-defined range start. */
diff --git a/contrib/binutils/include/elf/external.h b/contrib/binutils/include/elf/external.h
index 403ee62..a171439 100644
--- a/contrib/binutils/include/elf/external.h
+++ b/contrib/binutils/include/elf/external.h
@@ -258,4 +258,19 @@ typedef struct
unsigned char si_flags[2];
} Elf_External_Syminfo;
+
+/* This structure appears on the stack and in NT_AUXV core file notes. */
+typedef struct
+{
+ unsigned char a_type[4];
+ unsigned char a_val[4];
+} Elf32_External_Auxv;
+
+typedef struct
+{
+ unsigned char a_type[8];
+ unsigned char a_val[8];
+} Elf64_External_Auxv;
+
+
#endif /* _ELF_EXTERNAL_H */
diff --git a/contrib/binutils/include/elf/frv.h b/contrib/binutils/include/elf/frv.h
index 65ce97d..8246a21 100644
--- a/contrib/binutils/include/elf/frv.h
+++ b/contrib/binutils/include/elf/frv.h
@@ -35,6 +35,20 @@ START_RELOC_NUMBERS (elf_frv_reloc_type)
RELOC_NUMBER (R_FRV_GPREL32, 8)
RELOC_NUMBER (R_FRV_GPRELHI, 9)
RELOC_NUMBER (R_FRV_GPRELLO, 10)
+ RELOC_NUMBER (R_FRV_GOT12, 11)
+ RELOC_NUMBER (R_FRV_GOTHI, 12)
+ RELOC_NUMBER (R_FRV_GOTLO, 13)
+ RELOC_NUMBER (R_FRV_FUNCDESC, 14)
+ RELOC_NUMBER (R_FRV_FUNCDESC_GOT12, 15)
+ RELOC_NUMBER (R_FRV_FUNCDESC_GOTHI, 16)
+ RELOC_NUMBER (R_FRV_FUNCDESC_GOTLO, 17)
+ RELOC_NUMBER (R_FRV_FUNCDESC_VALUE, 18)
+ RELOC_NUMBER (R_FRV_FUNCDESC_GOTOFF12, 19)
+ RELOC_NUMBER (R_FRV_FUNCDESC_GOTOFFHI, 20)
+ RELOC_NUMBER (R_FRV_FUNCDESC_GOTOFFLO, 21)
+ RELOC_NUMBER (R_FRV_GOTOFF12, 22)
+ RELOC_NUMBER (R_FRV_GOTOFFHI, 23)
+ RELOC_NUMBER (R_FRV_GOTOFFLO, 24)
RELOC_NUMBER (R_FRV_GNU_VTINHERIT, 200)
RELOC_NUMBER (R_FRV_GNU_VTENTRY, 201)
END_RELOC_NUMBERS(R_FRV_max)
@@ -67,6 +81,7 @@ END_RELOC_NUMBERS(R_FRV_max)
#define EF_FRV_LIBPIC 0x00001000 /* -mlibrary-pic */
#define EF_FRV_G0 0x00002000 /* -G 0, no small data ptr */
#define EF_FRV_NOPACK 0x00004000 /* -mnopack */
+#define EF_FRV_FDPIC 0x00008000 /* -mfdpic */
#define EF_FRV_CPU_MASK 0xff000000 /* specific cpu bits */
#define EF_FRV_CPU_GENERIC 0x00000000 /* generic FRV */
@@ -75,9 +90,11 @@ END_RELOC_NUMBERS(R_FRV_max)
#define EF_FRV_CPU_SIMPLE 0x03000000 /* SIMPLE */
#define EF_FRV_CPU_TOMCAT 0x04000000 /* Tomcat, FR500 prototype */
#define EF_FRV_CPU_FR400 0x05000000 /* FRV400 */
+#define EF_FRV_CPU_FR550 0x06000000 /* FRV550 */
/* Mask of PIC related bits */
-#define EF_FRV_PIC_FLAGS (EF_FRV_PIC | EF_FRV_LIBPIC | EF_FRV_BIGPIC)
+#define EF_FRV_PIC_FLAGS (EF_FRV_PIC | EF_FRV_LIBPIC | EF_FRV_BIGPIC \
+ | EF_FRV_FDPIC)
/* Mask of all flags */
#define EF_FRV_ALL_FLAGS (EF_FRV_GPR_MASK | \
diff --git a/contrib/binutils/include/elf/h8.h b/contrib/binutils/include/elf/h8.h
index ac9db56..1aad7a4 100644
--- a/contrib/binutils/include/elf/h8.h
+++ b/contrib/binutils/include/elf/h8.h
@@ -1,5 +1,5 @@
/* H8300/h8500 ELF support for BFD.
- Copyright 2001 Free Software Foundation, Inc.
+ Copyright 2001, 2003 Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -92,5 +92,9 @@ END_RELOC_NUMBERS (R_H8_max)
#define E_H8_MACH_H8300 0x00800000
#define E_H8_MACH_H8300H 0x00810000
#define E_H8_MACH_H8300S 0x00820000
+#define E_H8_MACH_H8300HN 0x00830000
+#define E_H8_MACH_H8300SN 0x00840000
+#define E_H8_MACH_H8300SX 0x00850000
+#define E_H8_MACH_H8300SXN 0x00860000
#endif
diff --git a/contrib/binutils/include/elf/i370.h b/contrib/binutils/include/elf/i370.h
index b6f4785..fd5ec47 100644
--- a/contrib/binutils/include/elf/i370.h
+++ b/contrib/binutils/include/elf/i370.h
@@ -1,5 +1,5 @@
/* i370 ELF support for BFD.
- Copyright 2000 Free Software Foundation, Inc.
+ Copyright 2000, 2002 Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -23,6 +23,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef _ELF_I370_H
#define _ELF_I370_H
+#include "elf/reloc-macros.h"
+
/* Processor specific section headers, sh_type field */
#define SHT_ORDERED SHT_HIPROC /* Link editor is to sort the \
@@ -41,6 +43,26 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
builds when those objects \
are not to be furhter \
relocated. */
-#endif /* _ELF_I370_H */
+/* i370 relocations
+ Note that there is really just one relocation that we currently
+ support (and only one that we seem to need, at the moment), and
+ that is the 31-bit address relocation. Note that the 370/390
+ only supports a 31-bit (2GB) address space. */
+START_RELOC_NUMBERS (i370_reloc_type)
+ RELOC_NUMBER (R_I370_NONE, 0)
+ RELOC_NUMBER (R_I370_ADDR31, 1)
+ RELOC_NUMBER (R_I370_ADDR32, 2)
+ RELOC_NUMBER (R_I370_ADDR16, 3)
+ RELOC_NUMBER (R_I370_REL31, 4)
+ RELOC_NUMBER (R_I370_REL32, 5)
+ RELOC_NUMBER (R_I370_ADDR12, 6)
+ RELOC_NUMBER (R_I370_REL12, 7)
+ RELOC_NUMBER (R_I370_ADDR8, 8)
+ RELOC_NUMBER (R_I370_REL8, 9)
+ RELOC_NUMBER (R_I370_COPY, 10)
+ RELOC_NUMBER (R_I370_RELATIVE, 11)
+END_RELOC_NUMBERS (R_I370_max)
+
+#endif /* _ELF_I370_H */
diff --git a/contrib/binutils/include/elf/ia64.h b/contrib/binutils/include/elf/ia64.h
index 310a7f7..06dfa60 100644
--- a/contrib/binutils/include/elf/ia64.h
+++ b/contrib/binutils/include/elf/ia64.h
@@ -1,45 +1,44 @@
/* IA-64 ELF support for BFD.
- Copyright 1998, 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2003 Free Software Foundation, Inc.
Contributed by David Mosberger-Tang <davidm@hpl.hp.com>
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef _ELF_IA64_H
#define _ELF_IA64_H
/* Bits in the e_flags field of the Elf64_Ehdr: */
-#define EF_IA_64_MASKOS 0x0000000f /* os-specific flags */
-#define EF_IA_64_ARCH 0xff000000 /* arch. version mask */
+#define EF_IA_64_MASKOS 0x0000000f /* OS-specific flags. */
+#define EF_IA_64_ARCH 0xff000000 /* Arch. version mask. */
/* ??? These four definitions are not part of the SVR4 ABI.
They were present in David's initial code drop, so it is probable
that they are used by HP/UX. */
-#define EF_IA_64_TRAPNIL (1 << 0) /* trap NIL pointer dereferences */
-#define EF_IA_64_EXT (1 << 2) /* program uses arch. extensions */
-#define EF_IA_64_BE (1 << 3) /* PSR BE bit set (big-endian) */
-#define EFA_IA_64_EAS2_3 0x23000000 /* ia64 EAS 2.3 */
+#define EF_IA_64_TRAPNIL (1 << 0) /* Trap NIL pointer dereferences. */
+#define EF_IA_64_EXT (1 << 2) /* Program uses arch. extensions. */
+#define EF_IA_64_BE (1 << 3) /* PSR BE bit set (big-endian). */
+#define EFA_IA_64_EAS2_3 0x23000000 /* IA64 EAS 2.3. */
-#define EF_IA_64_ABI64 (1 << 4) /* 64-bit ABI */
+#define EF_IA_64_ABI64 (1 << 4) /* 64-bit ABI. */
/* Not used yet. */
#define EF_IA_64_REDUCEDFP (1 << 5) /* Only FP6-FP11 used. */
-#define EF_IA_64_CONS_GP (1 << 6) /* gp as program wide constant. */
-#define EF_IA_64_NOFUNCDESC_CONS_GP (1 << 7) /* And no function descriptors. */
+#define EF_IA_64_CONS_GP (1 << 6) /* gp as program wide constant. */
+#define EF_IA_64_NOFUNCDESC_CONS_GP (1 << 7) /* And no function descriptors. */
/* Not used yet. */
#define EF_IA_64_ABSOLUTE (1 << 8) /* Load at absolute addresses. */
@@ -54,13 +53,17 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* Bits in the sh_flags field of Elf64_Shdr: */
-#define SHF_IA_64_SHORT 0x10000000 /* section near gp */
-#define SHF_IA_64_NORECOV 0x20000000 /* spec insns w/o recovery */
+#define SHF_IA_64_SHORT 0x10000000 /* Section near gp. */
+#define SHF_IA_64_NORECOV 0x20000000 /* Spec insns w/o recovery. */
/* Possible values for sh_type in Elf64_Shdr: */
-#define SHT_IA_64_EXT (SHT_LOPROC + 0) /* extension bits */
-#define SHT_IA_64_UNWIND (SHT_LOPROC + 1) /* unwind bits */
+#define SHT_IA_64_EXT (SHT_LOPROC + 0) /* Extension bits. */
+#define SHT_IA_64_UNWIND (SHT_LOPROC + 1) /* Unwind bits. */
+#define SHT_IA_64_LOPSREG (SHT_LOPROC + 0x8000000)
+/* ABI says (SHT_LOPROC + 0xfffffff) but I think it's a typo -- this makes sense. */
+#define SHT_IA_64_HIPSREG (SHT_LOPROC + 0x8ffffff)
+#define SHT_IA_64_PRIORITY_INIT (SHT_LOPROC + 0x9000000)
/* SHT_IA_64_HP_OPT_ANOT is only generated by HPUX compilers for its
optimization annotation section. GCC does not generate it but we
@@ -74,8 +77,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* Possible values for p_type in Elf64_Phdr: */
-#define PT_IA_64_ARCHEXT (PT_LOPROC + 0) /* arch extension bits */
-#define PT_IA_64_UNWIND (PT_LOPROC + 1) /* ia64 unwind bits */
+#define PT_IA_64_ARCHEXT (PT_LOPROC + 0) /* Arch extension bits, */
+#define PT_IA_64_UNWIND (PT_LOPROC + 1) /* IA64 unwind bits. */
/* HP-UX specific values for p_type in Elf64_Phdr.
These values are currently just used to make
@@ -92,10 +95,9 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* This section only used by HP-UX, The HP linker gives weak symbols
precedence over regular common symbols. We want common to override
weak. Using this common instead of SHN_COMMON does that. */
-
#define SHN_IA_64_ANSI_COMMON 0xFF00
-/* ia64-specific relocation types: */
+/* IA64-specific relocation types: */
/* Relocs apply to specific instructions within a bundle. The least
significant 2 bits of the address indicate which instruction in the
diff --git a/contrib/binutils/include/elf/internal.h b/contrib/binutils/include/elf/internal.h
index 5d39d3a..a7299d9 100644
--- a/contrib/binutils/include/elf/internal.h
+++ b/contrib/binutils/include/elf/internal.h
@@ -1,5 +1,5 @@
/* ELF support for BFD.
- Copyright 1991, 1992, 1993, 1994, 1995, 1997, 1998, 2000, 2001
+ Copyright 1991, 1992, 1993, 1994, 1995, 1997, 1998, 2000, 2001, 2002
Free Software Foundation, Inc.
Written by Fred Fish @ Cygnus Support, from information published
@@ -58,11 +58,6 @@ typedef struct elf_internal_ehdr {
unsigned int e_shstrndx; /* Section header string table index */
} Elf_Internal_Ehdr;
-#define elf32_internal_ehdr elf_internal_ehdr
-#define Elf32_Internal_Ehdr Elf_Internal_Ehdr
-#define elf64_internal_ehdr elf_internal_ehdr
-#define Elf64_Internal_Ehdr Elf_Internal_Ehdr
-
/* Program header */
struct elf_internal_phdr {
@@ -77,10 +72,6 @@ struct elf_internal_phdr {
};
typedef struct elf_internal_phdr Elf_Internal_Phdr;
-#define elf32_internal_phdr elf_internal_phdr
-#define Elf32_Internal_Phdr Elf_Internal_Phdr
-#define elf64_internal_phdr elf_internal_phdr
-#define Elf64_Internal_Phdr Elf_Internal_Phdr
/* Section header */
@@ -101,11 +92,6 @@ typedef struct elf_internal_shdr {
unsigned char *contents; /* Section contents. */
} Elf_Internal_Shdr;
-#define elf32_internal_shdr elf_internal_shdr
-#define Elf32_Internal_Shdr Elf_Internal_Shdr
-#define elf64_internal_shdr elf_internal_shdr
-#define Elf64_Internal_Shdr Elf_Internal_Shdr
-
/* Symbol table entry */
struct elf_internal_sym {
@@ -119,11 +105,6 @@ struct elf_internal_sym {
typedef struct elf_internal_sym Elf_Internal_Sym;
-#define elf32_internal_sym elf_internal_sym
-#define elf64_internal_sym elf_internal_sym
-#define Elf32_Internal_Sym Elf_Internal_Sym
-#define Elf64_Internal_Sym Elf_Internal_Sym
-
/* Note segments */
typedef struct elf_internal_note {
@@ -134,33 +115,15 @@ typedef struct elf_internal_note {
char * descdata; /* Start of the desc data */
bfd_vma descpos; /* File offset of the descdata */
} Elf_Internal_Note;
-#define Elf32_Internal_Note Elf_Internal_Note
-#define elf32_internal_note elf_internal_note
/* Relocation Entries */
-typedef struct elf_internal_rel {
- bfd_vma r_offset; /* Location at which to apply the action */
- /* This needs to support 64-bit values in elf64. */
- bfd_vma r_info; /* index and type of relocation */
-} Elf_Internal_Rel;
-
-#define elf32_internal_rel elf_internal_rel
-#define Elf32_Internal_Rel Elf_Internal_Rel
-#define elf64_internal_rel elf_internal_rel
-#define Elf64_Internal_Rel Elf_Internal_Rel
-
typedef struct elf_internal_rela {
bfd_vma r_offset; /* Location at which to apply the action */
bfd_vma r_info; /* Index and Type of relocation */
bfd_vma r_addend; /* Constant addend used to compute value */
} Elf_Internal_Rela;
-#define elf32_internal_rela elf_internal_rela
-#define elf64_internal_rela elf_internal_rela
-#define Elf32_Internal_Rela Elf_Internal_Rela
-#define Elf64_Internal_Rela Elf_Internal_Rela
-
/* dynamic section structure */
typedef struct elf_internal_dyn {
@@ -173,11 +136,6 @@ typedef struct elf_internal_dyn {
} d_un;
} Elf_Internal_Dyn;
-#define elf32_internal_dyn elf_internal_dyn
-#define elf64_internal_dyn elf_internal_dyn
-#define Elf32_Internal_Dyn Elf_Internal_Dyn
-#define Elf64_Internal_Dyn Elf_Internal_Dyn
-
/* This structure appears in a SHT_GNU_verdef section. */
typedef struct elf_internal_verdef {
@@ -256,30 +214,13 @@ typedef struct
unsigned short int si_flags;
} Elf_Internal_Syminfo;
+/* This structure appears on the stack and in NT_AUXV core file notes. */
+typedef struct
+{
+ bfd_vma a_type;
+ bfd_vma a_val;
+} Elf_Internal_Auxv;
-#define elf32_internal_verdef elf_internal_verdef
-#define elf64_internal_verdef elf_internal_verdef
-#define elf32_internal_verdaux elf_internal_verdaux
-#define elf64_internal_verdaux elf_internal_verdaux
-#define elf32_internal_verneed elf_internal_verneed
-#define elf64_internal_verneed elf_internal_verneed
-#define elf32_internal_vernaux elf_internal_vernaux
-#define elf64_internal_vernaux elf_internal_vernaux
-#define elf32_internal_versym elf_internal_versym
-#define elf64_internal_versym elf_internal_versym
-
-#define Elf32_Internal_Verdef Elf_Internal_Verdef
-#define Elf64_Internal_Verdef Elf_Internal_Verdef
-#define Elf32_Internal_Verdaux Elf_Internal_Verdaux
-#define Elf64_Internal_Verdaux Elf_Internal_Verdaux
-#define Elf32_Internal_Verneed Elf_Internal_Verneed
-#define Elf64_Internal_Verneed Elf_Internal_Verneed
-#define Elf32_Internal_Vernaux Elf_Internal_Vernaux
-#define Elf64_Internal_Vernaux Elf_Internal_Vernaux
-#define Elf32_Internal_Versym Elf_Internal_Versym
-#define Elf64_Internal_Versym Elf_Internal_Versym
-#define Elf32_Internal_Syminfo Elf_Internal_Syminfo
-#define Elf64_Internal_Syminfo Elf_Internal_Syminfo
/* This structure is used to describe how sections should be assigned
to program segments. */
diff --git a/contrib/binutils/include/elf/ip2k.h b/contrib/binutils/include/elf/ip2k.h
new file mode 100644
index 0000000..c331b72
--- /dev/null
+++ b/contrib/binutils/include/elf/ip2k.h
@@ -0,0 +1,62 @@
+/* IP2xxx ELF support for BFD.
+ Copyright (C) 2000, 2002 Free Software Foundation, Inc.
+
+ This file is part of BFD, the Binary File Descriptor library.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software Foundation, Inc.,
+ 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+#ifndef _ELF_IP2K_H
+#define _ELF_IP2K_H
+
+#include "elf/reloc-macros.h"
+
+/* Relocations. */
+START_RELOC_NUMBERS (elf_ip2k_reloc_type)
+ RELOC_NUMBER (R_IP2K_NONE, 0)
+ RELOC_NUMBER (R_IP2K_16, 1)
+ RELOC_NUMBER (R_IP2K_32, 2)
+ RELOC_NUMBER (R_IP2K_FR9, 3)
+ RELOC_NUMBER (R_IP2K_BANK, 4)
+ RELOC_NUMBER (R_IP2K_ADDR16CJP, 5)
+ RELOC_NUMBER (R_IP2K_PAGE3, 6)
+ RELOC_NUMBER (R_IP2K_LO8DATA, 7)
+ RELOC_NUMBER (R_IP2K_HI8DATA, 8)
+ RELOC_NUMBER (R_IP2K_LO8INSN, 9)
+ RELOC_NUMBER (R_IP2K_HI8INSN, 10)
+ RELOC_NUMBER (R_IP2K_PC_SKIP, 11)
+ RELOC_NUMBER (R_IP2K_TEXT, 12)
+ RELOC_NUMBER (R_IP2K_FR_OFFSET, 13)
+ RELOC_NUMBER (R_IP2K_EX8DATA, 14)
+END_RELOC_NUMBERS(R_IP2K_max)
+
+
+/* Define the data & instruction memory discriminator. In a linked
+ executable, an symbol should be deemed to point to an instruction
+ if ((address & IP2K_INSN_MASK) == IP2K_INSN_VALUE), and similarly
+ for the data space. See also `ld/emulparams/elf32ip2k.sh'. */
+/* ??? Consider extending the _MASK values to include all the
+ intermediate bits that must be zero due to the limited physical
+ memory size on the IP2K. */
+
+#define IP2K_DATA_MASK 0xff000000
+#define IP2K_DATA_VALUE 0x01000000
+#define IP2K_INSN_MASK 0xff000000
+#define IP2K_INSN_VALUE 0x02000000
+
+/* The location of the memory mapped hardware stack. */
+#define IP2K_STACK_VALUE 0x0f000000
+#define IP2K_STACK_SIZE 0x20
+
+#endif /* _ELF_IP2K_H */
diff --git a/contrib/binutils/include/elf/iq2000.h b/contrib/binutils/include/elf/iq2000.h
new file mode 100644
index 0000000..83c690c
--- /dev/null
+++ b/contrib/binutils/include/elf/iq2000.h
@@ -0,0 +1,58 @@
+/* IQ2000 ELF support for BFD.
+ Copyright (C) 2002 Free Software Foundation, Inc.
+
+This file is part of BFD, the Binary File Descriptor library.
+
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software Foundation, Inc.,
+59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+#ifndef _ELF_IQ2000_H
+#define _ELF_IQ2000_H
+
+#include "elf/reloc-macros.h"
+
+/* Relocations. */
+START_RELOC_NUMBERS (elf_iq2000_reloc_type)
+ RELOC_NUMBER (R_IQ2000_NONE, 0)
+ RELOC_NUMBER (R_IQ2000_16, 1)
+ RELOC_NUMBER (R_IQ2000_32, 2)
+ RELOC_NUMBER (R_IQ2000_26, 3)
+ RELOC_NUMBER (R_IQ2000_PC16, 4)
+ RELOC_NUMBER (R_IQ2000_HI16, 5)
+ RELOC_NUMBER (R_IQ2000_LO16, 6)
+ RELOC_NUMBER (R_IQ2000_OFFSET_16, 7)
+ RELOC_NUMBER (R_IQ2000_OFFSET_21, 8)
+ RELOC_NUMBER (R_IQ2000_UHI16, 9)
+ RELOC_NUMBER (R_IQ2000_32_DEBUG, 10)
+ RELOC_NUMBER (R_IQ2000_GNU_VTINHERIT, 200)
+ RELOC_NUMBER (R_IQ2000_GNU_VTENTRY, 201)
+END_RELOC_NUMBERS(R_IQ2000_max)
+
+#define EF_IQ2000_CPU_IQ2000 0x00000001 /* default */
+#define EF_IQ2000_CPU_IQ10 0x00000002 /* IQ10 */
+#define EF_IQ2000_CPU_MASK 0x00000003 /* specific cpu bits */
+#define EF_IQ2000_ALL_FLAGS (EF_IQ2000_CPU_MASK)
+
+/* Define the data & instruction memory discriminator. In a linked
+ executable, an symbol should be deemed to point to an instruction
+ if ((address & IQ2000_INSN_MASK) == IQ2000_INSN_VALUE), and similarly
+ for the data space. */
+
+#define IQ2000_DATA_MASK 0x80000000
+#define IQ2000_DATA_VALUE 0x00000000
+#define IQ2000_INSN_MASK 0x80000000
+#define IQ2000_INSN_VALUE 0x80000000
+
+
+#endif /* _ELF_IQ2000_H */
diff --git a/contrib/binutils/include/elf/m32r.h b/contrib/binutils/include/elf/m32r.h
index 2cb308d..709d792 100644
--- a/contrib/binutils/include/elf/m32r.h
+++ b/contrib/binutils/include/elf/m32r.h
@@ -1,21 +1,21 @@
/* M32R ELF support for BFD.
- Copyright 1996, 1997, 1998, 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1996, 1997, 1998, 1999, 2000, 2003 Free Software Foundation, Inc.
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software Foundation, Inc.,
-59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software Foundation, Inc.,
+ 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#ifndef _ELF_M32R_H
#define _ELF_M32R_H
@@ -25,18 +25,48 @@ along with this program; if not, write to the Free Software Foundation, Inc.,
/* Relocations. */
START_RELOC_NUMBERS (elf_m32r_reloc_type)
RELOC_NUMBER (R_M32R_NONE, 0)
- RELOC_NUMBER (R_M32R_16, 1)
- RELOC_NUMBER (R_M32R_32, 2)
- RELOC_NUMBER (R_M32R_24, 3)
- RELOC_NUMBER (R_M32R_10_PCREL, 4)
- RELOC_NUMBER (R_M32R_18_PCREL, 5)
- RELOC_NUMBER (R_M32R_26_PCREL, 6)
- RELOC_NUMBER (R_M32R_HI16_ULO, 7)
- RELOC_NUMBER (R_M32R_HI16_SLO, 8)
- RELOC_NUMBER (R_M32R_LO16, 9)
- RELOC_NUMBER (R_M32R_SDA16, 10)
- RELOC_NUMBER (R_M32R_GNU_VTINHERIT, 11)
- RELOC_NUMBER (R_M32R_GNU_VTENTRY, 12)
+ /* REL relocations */
+ RELOC_NUMBER (R_M32R_16, 1) /* For backwards compatibility. */
+ RELOC_NUMBER (R_M32R_32, 2) /* For backwards compatibility. */
+ RELOC_NUMBER (R_M32R_24, 3) /* For backwards compatibility. */
+ RELOC_NUMBER (R_M32R_10_PCREL, 4) /* For backwards compatibility. */
+ RELOC_NUMBER (R_M32R_18_PCREL, 5) /* For backwards compatibility. */
+ RELOC_NUMBER (R_M32R_26_PCREL, 6) /* For backwards compatibility. */
+ RELOC_NUMBER (R_M32R_HI16_ULO, 7) /* For backwards compatibility. */
+ RELOC_NUMBER (R_M32R_HI16_SLO, 8) /* For backwards compatibility. */
+ RELOC_NUMBER (R_M32R_LO16, 9) /* For backwards compatibility. */
+ RELOC_NUMBER (R_M32R_SDA16, 10) /* For backwards compatibility. */
+ RELOC_NUMBER (R_M32R_GNU_VTINHERIT, 11)/* For backwards compatibility. */
+ RELOC_NUMBER (R_M32R_GNU_VTENTRY, 12) /* For backwards compatibility. */
+
+ /* RELA relocations */
+ RELOC_NUMBER (R_M32R_16_RELA, 33)
+ RELOC_NUMBER (R_M32R_32_RELA, 34)
+ RELOC_NUMBER (R_M32R_24_RELA, 35)
+ RELOC_NUMBER (R_M32R_10_PCREL_RELA, 36)
+ RELOC_NUMBER (R_M32R_18_PCREL_RELA, 37)
+ RELOC_NUMBER (R_M32R_26_PCREL_RELA, 38)
+ RELOC_NUMBER (R_M32R_HI16_ULO_RELA, 39)
+ RELOC_NUMBER (R_M32R_HI16_SLO_RELA, 40)
+ RELOC_NUMBER (R_M32R_LO16_RELA, 41)
+ RELOC_NUMBER (R_M32R_SDA16_RELA, 42)
+ RELOC_NUMBER (R_M32R_RELA_GNU_VTINHERIT, 43)
+ RELOC_NUMBER (R_M32R_RELA_GNU_VTENTRY, 44)
+
+ RELOC_NUMBER (R_M32R_GOT24, 48)
+ RELOC_NUMBER (R_M32R_26_PLTREL, 49)
+ RELOC_NUMBER (R_M32R_COPY, 50)
+ RELOC_NUMBER (R_M32R_GLOB_DAT, 51)
+ RELOC_NUMBER (R_M32R_JMP_SLOT, 52)
+ RELOC_NUMBER (R_M32R_RELATIVE, 53)
+ RELOC_NUMBER (R_M32R_GOTOFF, 54)
+ RELOC_NUMBER (R_M32R_GOTPC24, 55)
+ RELOC_NUMBER (R_M32R_GOT16_HI_ULO, 56)
+ RELOC_NUMBER (R_M32R_GOT16_HI_SLO, 57)
+ RELOC_NUMBER (R_M32R_GOT16_LO, 58)
+ RELOC_NUMBER (R_M32R_GOTPC_HI_ULO, 59)
+ RELOC_NUMBER (R_M32R_GOTPC_HI_SLO, 60)
+ RELOC_NUMBER (R_M32R_GOTPC_LO, 61)
END_RELOC_NUMBERS (R_M32R_max)
/* Processor specific section indices. These sections do not actually
@@ -62,6 +92,25 @@ END_RELOC_NUMBERS (R_M32R_max)
/* m32r code. */
#define E_M32R_ARCH 0x00000000
/* m32rx code. */
-#define E_M32RX_ARCH 0x10000000
+#define E_M32RX_ARCH 0x10000000
+/* m32r2 code. */
+#define E_M32R2_ARCH 0x20000000
+
+/* 12 bit m32r new instructions field. */
+#define EF_M32R_INST 0x0FFF0000
+/* Parallel instructions. */
+#define E_M32R_HAS_PARALLEL 0x00010000
+/* Hidden instructions for m32rx:
+ jc, jnc, macwhi-a, macwlo-a, mulwhi-a, mulwlo-a, sth+, shb+, sat, pcmpbz,
+ sc, snc. */
+#define E_M32R_HAS_HIDDEN_INST 0x00020000
+/* New bit instructions:
+ clrpsw, setpsw, bset, bclr, btst. */
+#define E_M32R_HAS_BIT_INST 0x00040000
+/* Floating point instructions. */
+#define E_M32R_HAS_FLOAT_INST 0x00080000
+
+/* 4 bit m32r ignore to check field. */
+#define EF_M32R_IGNORE 0x0000000F
#endif
diff --git a/contrib/binutils/include/elf/m68hc11.h b/contrib/binutils/include/elf/m68hc11.h
index 0f9546d..1902f7f 100644
--- a/contrib/binutils/include/elf/m68hc11.h
+++ b/contrib/binutils/include/elf/m68hc11.h
@@ -1,5 +1,5 @@
/* m68hc11 & m68hc12 ELF support for BFD.
- Copyright 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -37,6 +37,59 @@ START_RELOC_NUMBERS (elf_m68hc11_reloc_type)
/* These are GNU extensions to enable C++ vtable garbage collection. */
RELOC_NUMBER (R_M68HC11_GNU_VTINHERIT, 9)
RELOC_NUMBER (R_M68HC11_GNU_VTENTRY, 10)
+
+ RELOC_NUMBER (R_M68HC11_24, 11)
+ RELOC_NUMBER (R_M68HC11_LO16, 12)
+ RELOC_NUMBER (R_M68HC11_PAGE, 13)
+
+ /* GNU extension for linker relaxation.
+ Mark beginning of a jump instruction (any form). */
+ RELOC_NUMBER (R_M68HC11_RL_JUMP, 20)
+
+ /* Mark beginning of Gcc relaxation group instruction. */
+ RELOC_NUMBER (R_M68HC11_RL_GROUP, 21)
END_RELOC_NUMBERS (R_M68HC11_max)
+/* Processor specific flags for the ELF header e_flags field. */
+
+/* ABI identification. */
+#define EF_M68HC11_ABI 0x00000000F
+
+/* Integers are 32-bit long. */
+#define E_M68HC11_I32 0x000000001
+
+/* Doubles are 64-bit long. */
+#define E_M68HC11_F64 0x000000002
+
+/* Uses 68HC12 memory banks. */
+#define E_M68HC12_BANKS 0x000000004
+
+#define EF_M68HC11_MACH_MASK 0xF0
+#define EF_M68HC11_GENERIC 0x00 /* Generic 68HC12/backward compatibility. */
+#define EF_M68HC12_MACH 0x10 /* 68HC12 microcontroller. */
+#define EF_M68HCS12_MACH 0x20 /* 68HCS12 microcontroller. */
+#define EF_M68HC11_MACH(mach) ((mach) & EF_M68HC11_MACH_MASK)
+
+/* True if we can merge machines. A generic HC12 can work on any proc
+ but once we have specific code, merge is not possible. */
+#define EF_M68HC11_CAN_MERGE_MACH(mach1, mach2) \
+ ((EF_M68HC11_MACH (mach1) == EF_M68HC11_MACH (mach2)) \
+ || (EF_M68HC11_MACH (mach1) == EF_M68HC11_GENERIC) \
+ || (EF_M68HC11_MACH (mach2) == EF_M68HC11_GENERIC))
+
+#define EF_M68HC11_MERGE_MACH(mach1, mach2) \
+ (((EF_M68HC11_MACH (mach1) == EF_M68HC11_MACH (mach2)) \
+ || (EF_M68HC11_MACH (mach1) == EF_M68HC11_GENERIC)) ? \
+ EF_M68HC11_MACH (mach2) : EF_M68HC11_MACH (mach1))
+
+
+/* Special values for the st_other field in the symbol table. These
+ are used for 68HC12 to identify far functions (must be called with
+ 'call' and returns with 'rtc'). */
+#define STO_M68HC12_FAR 0x80
+
+/* Identify interrupt handlers. This is used by the debugger to
+ correctly compute the stack frame. */
+#define STO_M68HC12_INTERRUPT 0x40
+
#endif
diff --git a/contrib/binutils/include/elf/mips.h b/contrib/binutils/include/elf/mips.h
index 3b6fe99..ce43158 100644
--- a/contrib/binutils/include/elf/mips.h
+++ b/contrib/binutils/include/elf/mips.h
@@ -1,5 +1,5 @@
/* MIPS ELF support for BFD.
- Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
+ Copyright 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003
Free Software Foundation, Inc.
By Ian Lance Taylor, Cygnus Support, <ian@cygnus.com>, from
@@ -99,6 +99,9 @@ END_RELOC_NUMBERS (R_MIPS_maxext)
position independent code. */
#define EF_MIPS_CPIC 0x00000004
+/* ??? Unknown flag, set in IRIX 6's BSDdup2.o in libbsd.a. */
+#define EF_MIPS_XGOT 0x00000008
+
/* Code in file uses UCODE (obsolete) */
#define EF_MIPS_UCODE 0x00000010
@@ -145,6 +148,12 @@ END_RELOC_NUMBERS (R_MIPS_maxext)
/* -mips64 code. */
#define E_MIPS_ARCH_64 0x60000000
+/* -mips32r2 code. */
+#define E_MIPS_ARCH_32R2 0x70000000
+
+/* -mips64r2 code. */
+#define E_MIPS_ARCH_64R2 0x80000000
+
/* The ABI of the file. Also see EF_MIPS_ABI2 above. */
#define EF_MIPS_ABI 0x0000F000
@@ -175,8 +184,11 @@ END_RELOC_NUMBERS (R_MIPS_maxext)
#define E_MIPS_MACH_4010 0x00820000
#define E_MIPS_MACH_4100 0x00830000
#define E_MIPS_MACH_4650 0x00850000
+#define E_MIPS_MACH_4120 0x00870000
#define E_MIPS_MACH_4111 0x00880000
#define E_MIPS_MACH_SB1 0x008a0000
+#define E_MIPS_MACH_5400 0x00910000
+#define E_MIPS_MACH_5500 0x00980000
/* Processor specific section indices. These sections do not actually
exist. Symbols with a st_shndx field corresponding to one of these
@@ -447,9 +459,9 @@ typedef struct
/* MIPS ELF .reginfo swapping routines. */
extern void bfd_mips_elf32_swap_reginfo_in
- PARAMS ((bfd *, const Elf32_External_RegInfo *, Elf32_RegInfo *));
+ (bfd *, const Elf32_External_RegInfo *, Elf32_RegInfo *);
extern void bfd_mips_elf32_swap_reginfo_out
- PARAMS ((bfd *, const Elf32_RegInfo *, Elf32_External_RegInfo *));
+ (bfd *, const Elf32_RegInfo *, Elf32_External_RegInfo *);
/* Processor specific section flags. */
@@ -813,9 +825,9 @@ typedef struct
/* MIPS ELF option header swapping routines. */
extern void bfd_mips_elf_swap_options_in
- PARAMS ((bfd *, const Elf_External_Options *, Elf_Internal_Options *));
+ (bfd *, const Elf_External_Options *, Elf_Internal_Options *);
extern void bfd_mips_elf_swap_options_out
- PARAMS ((bfd *, const Elf_Internal_Options *, Elf_External_Options *));
+ (bfd *, const Elf_Internal_Options *, Elf_External_Options *);
/* Values which may appear in the kind field of an Elf_Options
structure. */
@@ -917,9 +929,9 @@ typedef struct
/* MIPS ELF reginfo swapping routines. */
extern void bfd_mips_elf64_swap_reginfo_in
- PARAMS ((bfd *, const Elf64_External_RegInfo *, Elf64_Internal_RegInfo *));
+ (bfd *, const Elf64_External_RegInfo *, Elf64_Internal_RegInfo *);
extern void bfd_mips_elf64_swap_reginfo_out
- PARAMS ((bfd *, const Elf64_Internal_RegInfo *, Elf64_External_RegInfo *));
+ (bfd *, const Elf64_Internal_RegInfo *, Elf64_External_RegInfo *);
/* Masks for the info work of an ODK_EXCEPTIONS descriptor. */
#define OEX_FPU_MIN 0x1f /* FPEs which must be enabled. */
diff --git a/contrib/binutils/include/elf/mmix.h b/contrib/binutils/include/elf/mmix.h
index e3be26b..89778e4 100644
--- a/contrib/binutils/include/elf/mmix.h
+++ b/contrib/binutils/include/elf/mmix.h
@@ -1,5 +1,5 @@
/* MMIX support for BFD.
- Copyright (C) 2001, 2002 Free Software Foundation, Inc.
+ Copyright 2001, 2002, 2003 Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -23,7 +23,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "elf/reloc-macros.h"
-/* Relocations. */
+/* Relocations. See the reloc table in bfd/elf64-mmix.c for details. */
START_RELOC_NUMBERS (elf_mmix_reloc_type)
RELOC_NUMBER (R_MMIX_NONE, 0)
@@ -90,6 +90,9 @@ START_RELOC_NUMBERS (elf_mmix_reloc_type)
/* A LOCAL assertion. */
RELOC_NUMBER (R_MMIX_LOCAL, 35)
+
+ /* A PUSHJ instruction, generating a stub if it does not reach. */
+ RELOC_NUMBER (R_MMIX_PUSHJ_STUBBABLE, 36)
END_RELOC_NUMBERS (R_MMIX_max)
@@ -157,12 +160,12 @@ END_RELOC_NUMBERS (R_MMIX_max)
#define MMO_SEC_DEBUGGING 0x10000
#ifdef BFD_ARCH_SIZE
-extern boolean _bfd_mmix_prepare_linker_allocated_gregs
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean _bfd_mmix_finalize_linker_allocated_gregs
- PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean _bfd_mmix_check_all_relocs
- PARAMS ((bfd *, struct bfd_link_info *));
+extern bfd_boolean _bfd_mmix_before_linker_allocation
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean _bfd_mmix_after_linker_allocation
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean _bfd_mmix_check_all_relocs
+ (bfd *, struct bfd_link_info *);
#endif
#endif /* ELF_MMIX_H */
diff --git a/contrib/binutils/include/elf/mn10300.h b/contrib/binutils/include/elf/mn10300.h
index e10be90..e640096 100644
--- a/contrib/binutils/include/elf/mn10300.h
+++ b/contrib/binutils/include/elf/mn10300.h
@@ -1,5 +1,5 @@
/* MN10300 ELF support for BFD.
- Copyright 1998, 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -36,6 +36,20 @@ START_RELOC_NUMBERS (elf_mn10300_reloc_type)
RELOC_NUMBER (R_MN10300_GNU_VTINHERIT, 7)
RELOC_NUMBER (R_MN10300_GNU_VTENTRY, 8)
RELOC_NUMBER (R_MN10300_24, 9)
+ RELOC_NUMBER (R_MN10300_GOTPC32, 10)
+ RELOC_NUMBER (R_MN10300_GOTPC16, 11)
+ RELOC_NUMBER (R_MN10300_GOTOFF32, 12)
+ RELOC_NUMBER (R_MN10300_GOTOFF24, 13)
+ RELOC_NUMBER (R_MN10300_GOTOFF16, 14)
+ RELOC_NUMBER (R_MN10300_PLT32, 15)
+ RELOC_NUMBER (R_MN10300_PLT16, 16)
+ RELOC_NUMBER (R_MN10300_GOT32, 17)
+ RELOC_NUMBER (R_MN10300_GOT24, 18)
+ RELOC_NUMBER (R_MN10300_GOT16, 19)
+ RELOC_NUMBER (R_MN10300_COPY, 20)
+ RELOC_NUMBER (R_MN10300_GLOB_DAT, 21)
+ RELOC_NUMBER (R_MN10300_JMP_SLOT, 22)
+ RELOC_NUMBER (R_MN10300_RELATIVE, 23)
END_RELOC_NUMBERS (R_MN10300_MAX)
/* Machine variant if we know it. This field was invented at Cygnus,
@@ -50,4 +64,5 @@ END_RELOC_NUMBERS (R_MN10300_MAX)
#define E_MN10300_MACH_MN10300 0x00810000
#define E_MN10300_MACH_AM33 0x00820000
+#define E_MN10300_MACH_AM33_2 0x00830000
#endif /* _ELF_MN10300_H */
diff --git a/contrib/binutils/include/elf/msp430.h b/contrib/binutils/include/elf/msp430.h
new file mode 100644
index 0000000..912ded7
--- /dev/null
+++ b/contrib/binutils/include/elf/msp430.h
@@ -0,0 +1,56 @@
+/* MSP430 ELF support for BFD.
+ Copyright (C) 2002 Free Software Foundation, Inc.
+ Contributed by Dmitry Diky <diwil@mail.ru>
+
+ This file is part of BFD, the Binary File Descriptor library.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software Foundation, Inc.,
+ 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+#ifndef _ELF_MSP430_H
+#define _ELF_MSP430_H
+
+#include "elf/reloc-macros.h"
+
+/* Processor specific flags for the ELF header e_flags field. */
+#define EF_MSP430_MACH 0xff
+
+#define E_MSP430_MACH_MSP430x11 11
+#define E_MSP430_MACH_MSP430x11x1 110
+#define E_MSP430_MACH_MSP430x12 12
+#define E_MSP430_MACH_MSP430x13 13
+#define E_MSP430_MACH_MSP430x14 14
+#define E_MSP430_MACH_MSP430x15 15
+#define E_MSP430_MACH_MSP430x16 16
+#define E_MSP430_MACH_MSP430x31 31
+#define E_MSP430_MACH_MSP430x32 32
+#define E_MSP430_MACH_MSP430x33 33
+#define E_MSP430_MACH_MSP430x41 41
+#define E_MSP430_MACH_MSP430x42 42
+#define E_MSP430_MACH_MSP430x43 43
+#define E_MSP430_MACH_MSP430x44 44
+
+/* Relocations. */
+START_RELOC_NUMBERS (elf_msp430_reloc_type)
+ RELOC_NUMBER (R_MSP430_NONE, 0)
+ RELOC_NUMBER (R_MSP430_32, 1)
+ RELOC_NUMBER (R_MSP430_10_PCREL, 2)
+ RELOC_NUMBER (R_MSP430_16, 3)
+ RELOC_NUMBER (R_MSP430_16_PCREL, 4)
+ RELOC_NUMBER (R_MSP430_16_BYTE, 5)
+ RELOC_NUMBER (R_MSP430_16_PCREL_BYTE, 6)
+
+END_RELOC_NUMBERS (R_MSP430_max)
+
+#endif /* _ELF_MSP430_H */
diff --git a/contrib/binutils/include/elf/ppc.h b/contrib/binutils/include/elf/ppc.h
index dfb43f4..b510f44 100644
--- a/contrib/binutils/include/elf/ppc.h
+++ b/contrib/binutils/include/elf/ppc.h
@@ -1,5 +1,6 @@
/* PPC ELF support for BFD.
- Copyright 1995, 1996, 1998, 2000, 2001 Free Software Foundation, Inc.
+ Copyright 1995, 1996, 1998, 2000, 2001, 2002, 2003
+ Free Software Foundation, Inc.
By Michael Meissner, Cygnus Support, <meissner@cygnus.com>, from information
in the System V Application Binary Interface, PowerPC Processor Supplement
@@ -31,152 +32,111 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* Relocations. */
START_RELOC_NUMBERS (elf_ppc_reloc_type)
- RELOC_NUMBER (R_PPC_NONE, 0)
- RELOC_NUMBER (R_PPC_ADDR32, 1)
- RELOC_NUMBER (R_PPC_ADDR24, 2)
- RELOC_NUMBER (R_PPC_ADDR16, 3)
- RELOC_NUMBER (R_PPC_ADDR16_LO, 4)
- RELOC_NUMBER (R_PPC_ADDR16_HI, 5)
- RELOC_NUMBER (R_PPC_ADDR16_HA, 6)
- RELOC_NUMBER (R_PPC_ADDR14, 7)
- RELOC_NUMBER (R_PPC_ADDR14_BRTAKEN, 8)
- RELOC_NUMBER (R_PPC_ADDR14_BRNTAKEN, 9)
- RELOC_NUMBER (R_PPC_REL24, 10)
- RELOC_NUMBER (R_PPC_REL14, 11)
- RELOC_NUMBER (R_PPC_REL14_BRTAKEN, 12)
- RELOC_NUMBER (R_PPC_REL14_BRNTAKEN, 13)
- RELOC_NUMBER (R_PPC_GOT16, 14)
- RELOC_NUMBER (R_PPC_GOT16_LO, 15)
- RELOC_NUMBER (R_PPC_GOT16_HI, 16)
- RELOC_NUMBER (R_PPC_GOT16_HA, 17)
- RELOC_NUMBER (R_PPC_PLTREL24, 18)
- RELOC_NUMBER (R_PPC_COPY, 19)
- RELOC_NUMBER (R_PPC_GLOB_DAT, 20)
- RELOC_NUMBER (R_PPC_JMP_SLOT, 21)
- RELOC_NUMBER (R_PPC_RELATIVE, 22)
- RELOC_NUMBER (R_PPC_LOCAL24PC, 23)
- RELOC_NUMBER (R_PPC_UADDR32, 24)
- RELOC_NUMBER (R_PPC_UADDR16, 25)
- RELOC_NUMBER (R_PPC_REL32, 26)
- RELOC_NUMBER (R_PPC_PLT32, 27)
- RELOC_NUMBER (R_PPC_PLTREL32, 28)
- RELOC_NUMBER (R_PPC_PLT16_LO, 29)
- RELOC_NUMBER (R_PPC_PLT16_HI, 30)
- RELOC_NUMBER (R_PPC_PLT16_HA, 31)
- RELOC_NUMBER (R_PPC_SDAREL16, 32)
- RELOC_NUMBER (R_PPC_SECTOFF, 33)
- RELOC_NUMBER (R_PPC_SECTOFF_LO, 34)
- RELOC_NUMBER (R_PPC_SECTOFF_HI, 35)
- RELOC_NUMBER (R_PPC_SECTOFF_HA, 36)
- RELOC_NUMBER (R_PPC_ADDR30, 37)
-
-/* The following relocs are from the 64-bit PowerPC ELF ABI. */
- RELOC_NUMBER (R_PPC64_ADDR64, 38)
- RELOC_NUMBER (R_PPC64_ADDR16_HIGHER, 39)
- RELOC_NUMBER (R_PPC64_ADDR16_HIGHERA, 40)
- RELOC_NUMBER (R_PPC64_ADDR16_HIGHEST, 41)
- RELOC_NUMBER (R_PPC64_ADDR16_HIGHESTA, 42)
- RELOC_NUMBER (R_PPC64_UADDR64, 43)
- RELOC_NUMBER (R_PPC64_REL64, 44)
- RELOC_NUMBER (R_PPC64_PLT64, 45)
- RELOC_NUMBER (R_PPC64_PLTREL64, 46)
- RELOC_NUMBER (R_PPC64_TOC16, 47)
- RELOC_NUMBER (R_PPC64_TOC16_LO, 48)
- RELOC_NUMBER (R_PPC64_TOC16_HI, 49)
- RELOC_NUMBER (R_PPC64_TOC16_HA, 50)
- RELOC_NUMBER (R_PPC64_TOC, 51)
- RELOC_NUMBER (R_PPC64_PLTGOT16, 52)
- RELOC_NUMBER (R_PPC64_PLTGOT16_LO, 53)
- RELOC_NUMBER (R_PPC64_PLTGOT16_HI, 54)
- RELOC_NUMBER (R_PPC64_PLTGOT16_HA, 55)
-
-/* The following relocs were added in the 64-bit PowerPC ELF ABI revision 1.2. */
- RELOC_NUMBER (R_PPC64_ADDR16_DS, 56)
- RELOC_NUMBER (R_PPC64_ADDR16_LO_DS, 57)
- RELOC_NUMBER (R_PPC64_GOT16_DS, 58)
- RELOC_NUMBER (R_PPC64_GOT16_LO_DS, 59)
- RELOC_NUMBER (R_PPC64_PLT16_LO_DS, 60)
- RELOC_NUMBER (R_PPC64_SECTOFF_DS, 61)
- RELOC_NUMBER (R_PPC64_SECTOFF_LO_DS, 62)
- RELOC_NUMBER (R_PPC64_TOC16_DS, 63)
- RELOC_NUMBER (R_PPC64_TOC16_LO_DS, 64)
- RELOC_NUMBER (R_PPC64_PLTGOT16_DS, 65)
- RELOC_NUMBER (R_PPC64_PLTGOT16_LO_DS, 66)
+ RELOC_NUMBER (R_PPC_NONE, 0)
+ RELOC_NUMBER (R_PPC_ADDR32, 1)
+ RELOC_NUMBER (R_PPC_ADDR24, 2)
+ RELOC_NUMBER (R_PPC_ADDR16, 3)
+ RELOC_NUMBER (R_PPC_ADDR16_LO, 4)
+ RELOC_NUMBER (R_PPC_ADDR16_HI, 5)
+ RELOC_NUMBER (R_PPC_ADDR16_HA, 6)
+ RELOC_NUMBER (R_PPC_ADDR14, 7)
+ RELOC_NUMBER (R_PPC_ADDR14_BRTAKEN, 8)
+ RELOC_NUMBER (R_PPC_ADDR14_BRNTAKEN, 9)
+ RELOC_NUMBER (R_PPC_REL24, 10)
+ RELOC_NUMBER (R_PPC_REL14, 11)
+ RELOC_NUMBER (R_PPC_REL14_BRTAKEN, 12)
+ RELOC_NUMBER (R_PPC_REL14_BRNTAKEN, 13)
+ RELOC_NUMBER (R_PPC_GOT16, 14)
+ RELOC_NUMBER (R_PPC_GOT16_LO, 15)
+ RELOC_NUMBER (R_PPC_GOT16_HI, 16)
+ RELOC_NUMBER (R_PPC_GOT16_HA, 17)
+ RELOC_NUMBER (R_PPC_PLTREL24, 18)
+ RELOC_NUMBER (R_PPC_COPY, 19)
+ RELOC_NUMBER (R_PPC_GLOB_DAT, 20)
+ RELOC_NUMBER (R_PPC_JMP_SLOT, 21)
+ RELOC_NUMBER (R_PPC_RELATIVE, 22)
+ RELOC_NUMBER (R_PPC_LOCAL24PC, 23)
+ RELOC_NUMBER (R_PPC_UADDR32, 24)
+ RELOC_NUMBER (R_PPC_UADDR16, 25)
+ RELOC_NUMBER (R_PPC_REL32, 26)
+ RELOC_NUMBER (R_PPC_PLT32, 27)
+ RELOC_NUMBER (R_PPC_PLTREL32, 28)
+ RELOC_NUMBER (R_PPC_PLT16_LO, 29)
+ RELOC_NUMBER (R_PPC_PLT16_HI, 30)
+ RELOC_NUMBER (R_PPC_PLT16_HA, 31)
+ RELOC_NUMBER (R_PPC_SDAREL16, 32)
+ RELOC_NUMBER (R_PPC_SECTOFF, 33)
+ RELOC_NUMBER (R_PPC_SECTOFF_LO, 34)
+ RELOC_NUMBER (R_PPC_SECTOFF_HI, 35)
+ RELOC_NUMBER (R_PPC_SECTOFF_HA, 36)
+ RELOC_NUMBER (R_PPC_ADDR30, 37)
+
+ /* Relocs added to support TLS. */
+ RELOC_NUMBER (R_PPC_TLS, 67)
+ RELOC_NUMBER (R_PPC_DTPMOD32, 68)
+ RELOC_NUMBER (R_PPC_TPREL16, 69)
+ RELOC_NUMBER (R_PPC_TPREL16_LO, 70)
+ RELOC_NUMBER (R_PPC_TPREL16_HI, 71)
+ RELOC_NUMBER (R_PPC_TPREL16_HA, 72)
+ RELOC_NUMBER (R_PPC_TPREL32, 73)
+ RELOC_NUMBER (R_PPC_DTPREL16, 74)
+ RELOC_NUMBER (R_PPC_DTPREL16_LO, 75)
+ RELOC_NUMBER (R_PPC_DTPREL16_HI, 76)
+ RELOC_NUMBER (R_PPC_DTPREL16_HA, 77)
+ RELOC_NUMBER (R_PPC_DTPREL32, 78)
+ RELOC_NUMBER (R_PPC_GOT_TLSGD16, 79)
+ RELOC_NUMBER (R_PPC_GOT_TLSGD16_LO, 80)
+ RELOC_NUMBER (R_PPC_GOT_TLSGD16_HI, 81)
+ RELOC_NUMBER (R_PPC_GOT_TLSGD16_HA, 82)
+ RELOC_NUMBER (R_PPC_GOT_TLSLD16, 83)
+ RELOC_NUMBER (R_PPC_GOT_TLSLD16_LO, 84)
+ RELOC_NUMBER (R_PPC_GOT_TLSLD16_HI, 85)
+ RELOC_NUMBER (R_PPC_GOT_TLSLD16_HA, 86)
+ RELOC_NUMBER (R_PPC_GOT_TPREL16, 87)
+ RELOC_NUMBER (R_PPC_GOT_TPREL16_LO, 88)
+ RELOC_NUMBER (R_PPC_GOT_TPREL16_HI, 89)
+ RELOC_NUMBER (R_PPC_GOT_TPREL16_HA, 90)
+ RELOC_NUMBER (R_PPC_GOT_DTPREL16, 91)
+ RELOC_NUMBER (R_PPC_GOT_DTPREL16_LO, 92)
+ RELOC_NUMBER (R_PPC_GOT_DTPREL16_HI, 93)
+ RELOC_NUMBER (R_PPC_GOT_DTPREL16_HA, 94)
/* The remaining relocs are from the Embedded ELF ABI, and are not
in the SVR4 ELF ABI. */
- RELOC_NUMBER (R_PPC_EMB_NADDR32, 101)
- RELOC_NUMBER (R_PPC_EMB_NADDR16, 102)
- RELOC_NUMBER (R_PPC_EMB_NADDR16_LO, 103)
- RELOC_NUMBER (R_PPC_EMB_NADDR16_HI, 104)
- RELOC_NUMBER (R_PPC_EMB_NADDR16_HA, 105)
- RELOC_NUMBER (R_PPC_EMB_SDAI16, 106)
- RELOC_NUMBER (R_PPC_EMB_SDA2I16, 107)
- RELOC_NUMBER (R_PPC_EMB_SDA2REL, 108)
- RELOC_NUMBER (R_PPC_EMB_SDA21, 109)
- RELOC_NUMBER (R_PPC_EMB_MRKREF, 110)
- RELOC_NUMBER (R_PPC_EMB_RELSEC16, 111)
- RELOC_NUMBER (R_PPC_EMB_RELST_LO, 112)
- RELOC_NUMBER (R_PPC_EMB_RELST_HI, 113)
- RELOC_NUMBER (R_PPC_EMB_RELST_HA, 114)
- RELOC_NUMBER (R_PPC_EMB_BIT_FLD, 115)
- RELOC_NUMBER (R_PPC_EMB_RELSDA, 116)
-
- /* These are GNU extensions to enable C++ vtable garbage collection. */
- RELOC_NUMBER (R_PPC_GNU_VTINHERIT, 253)
- RELOC_NUMBER (R_PPC_GNU_VTENTRY, 254)
+ RELOC_NUMBER (R_PPC_EMB_NADDR32, 101)
+ RELOC_NUMBER (R_PPC_EMB_NADDR16, 102)
+ RELOC_NUMBER (R_PPC_EMB_NADDR16_LO, 103)
+ RELOC_NUMBER (R_PPC_EMB_NADDR16_HI, 104)
+ RELOC_NUMBER (R_PPC_EMB_NADDR16_HA, 105)
+ RELOC_NUMBER (R_PPC_EMB_SDAI16, 106)
+ RELOC_NUMBER (R_PPC_EMB_SDA2I16, 107)
+ RELOC_NUMBER (R_PPC_EMB_SDA2REL, 108)
+ RELOC_NUMBER (R_PPC_EMB_SDA21, 109)
+ RELOC_NUMBER (R_PPC_EMB_MRKREF, 110)
+ RELOC_NUMBER (R_PPC_EMB_RELSEC16, 111)
+ RELOC_NUMBER (R_PPC_EMB_RELST_LO, 112)
+ RELOC_NUMBER (R_PPC_EMB_RELST_HI, 113)
+ RELOC_NUMBER (R_PPC_EMB_RELST_HA, 114)
+ RELOC_NUMBER (R_PPC_EMB_BIT_FLD, 115)
+ RELOC_NUMBER (R_PPC_EMB_RELSDA, 116)
+
+/* Fake relocations for branch stubs. This will keep them
+ together. */
+#define R_PPC_RELAX32 251
+#define R_PPC_RELAX32PC 252
+
+/* These are GNU extensions to enable C++ vtable garbage collection. */
+ RELOC_NUMBER (R_PPC_GNU_VTINHERIT, 253)
+ RELOC_NUMBER (R_PPC_GNU_VTENTRY, 254)
/* This is a phony reloc to handle any old fashioned TOC16 references
that may still be in object files. */
- RELOC_NUMBER (R_PPC_TOC16, 255)
+ RELOC_NUMBER (R_PPC_TOC16, 255)
END_RELOC_NUMBERS (R_PPC_max)
-/* Aliases for R_PPC64-relocs. */
-#define R_PPC64_NONE R_PPC_NONE
-#define R_PPC64_ADDR32 R_PPC_ADDR32
-#define R_PPC64_ADDR24 R_PPC_ADDR24
-#define R_PPC64_ADDR16 R_PPC_ADDR16
-#define R_PPC64_ADDR16_LO R_PPC_ADDR16_LO
-#define R_PPC64_ADDR16_HI R_PPC_ADDR16_HI
-#define R_PPC64_ADDR16_HA R_PPC_ADDR16_HA
-#define R_PPC64_ADDR14 R_PPC_ADDR14
-#define R_PPC64_ADDR14_BRTAKEN R_PPC_ADDR14_BRTAKEN
-#define R_PPC64_ADDR14_BRNTAKEN R_PPC_ADDR14_BRNTAKEN
-#define R_PPC64_REL24 R_PPC_REL24
-#define R_PPC64_REL14 R_PPC_REL14
-#define R_PPC64_REL14_BRTAKEN R_PPC_REL14_BRTAKEN
-#define R_PPC64_REL14_BRNTAKEN R_PPC_REL14_BRNTAKEN
-#define R_PPC64_GOT16 R_PPC_GOT16
-#define R_PPC64_GOT16_LO R_PPC_GOT16_LO
-#define R_PPC64_GOT16_HI R_PPC_GOT16_HI
-#define R_PPC64_GOT16_HA R_PPC_GOT16_HA
-#define R_PPC64_COPY R_PPC_COPY
-#define R_PPC64_GLOB_DAT R_PPC_GLOB_DAT
-#define R_PPC64_JMP_SLOT R_PPC_JMP_SLOT
-#define R_PPC64_RELATIVE R_PPC_RELATIVE
-#define R_PPC64_UADDR32 R_PPC_UADDR32
-#define R_PPC64_UADDR16 R_PPC_UADDR16
-#define R_PPC64_REL32 R_PPC_REL32
-#define R_PPC64_PLT32 R_PPC_PLT32
-#define R_PPC64_PLTREL32 R_PPC_PLTREL32
-#define R_PPC64_PLT16_LO R_PPC_PLT16_LO
-#define R_PPC64_PLT16_HI R_PPC_PLT16_HI
-#define R_PPC64_PLT16_HA R_PPC_PLT16_HA
-#define R_PPC64_SECTOFF R_PPC_SECTOFF
-#define R_PPC64_SECTOFF_LO R_PPC_SECTOFF_LO
-#define R_PPC64_SECTOFF_HI R_PPC_SECTOFF_HI
-#define R_PPC64_SECTOFF_HA R_PPC_SECTOFF_HA
-#define R_PPC64_ADDR30 R_PPC_ADDR30
-#define R_PPC64_GNU_VTINHERIT R_PPC_GNU_VTINHERIT
-#define R_PPC64_GNU_VTENTRY R_PPC_GNU_VTENTRY
-
-/* Specify the start of the .glink section. */
-#define DT_PPC64_GLINK DT_LOPROC
-
-/* Specify the start and size of the .opd section. */
-#define DT_PPC64_OPD (DT_LOPROC + 1)
-#define DT_PPC64_OPDSZ (DT_LOPROC + 2)
+#define IS_PPC_TLS_RELOC(R) \
+ ((R) >= R_PPC_TLS && (R) <= R_PPC_GOT_DTPREL16_HA)
/* Processor specific flags for the ELF header e_flags field. */
diff --git a/contrib/binutils/include/elf/ppc64.h b/contrib/binutils/include/elf/ppc64.h
new file mode 100644
index 0000000..ee2b0ea
--- /dev/null
+++ b/contrib/binutils/include/elf/ppc64.h
@@ -0,0 +1,156 @@
+/* PPC64 ELF support for BFD.
+ Copyright 2003 Free Software Foundation, Inc.
+
+This file is part of BFD, the Binary File Descriptor library.
+
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+#ifndef _ELF_PPC64_H
+#define _ELF_PPC64_H
+
+#include "elf/reloc-macros.h"
+
+/* Relocations. */
+START_RELOC_NUMBERS (elf_ppc64_reloc_type)
+ RELOC_NUMBER (R_PPC64_NONE, 0)
+ RELOC_NUMBER (R_PPC64_ADDR32, 1)
+ RELOC_NUMBER (R_PPC64_ADDR24, 2)
+ RELOC_NUMBER (R_PPC64_ADDR16, 3)
+ RELOC_NUMBER (R_PPC64_ADDR16_LO, 4)
+ RELOC_NUMBER (R_PPC64_ADDR16_HI, 5)
+ RELOC_NUMBER (R_PPC64_ADDR16_HA, 6)
+ RELOC_NUMBER (R_PPC64_ADDR14, 7)
+ RELOC_NUMBER (R_PPC64_ADDR14_BRTAKEN, 8)
+ RELOC_NUMBER (R_PPC64_ADDR14_BRNTAKEN, 9)
+ RELOC_NUMBER (R_PPC64_REL24, 10)
+ RELOC_NUMBER (R_PPC64_REL14, 11)
+ RELOC_NUMBER (R_PPC64_REL14_BRTAKEN, 12)
+ RELOC_NUMBER (R_PPC64_REL14_BRNTAKEN, 13)
+ RELOC_NUMBER (R_PPC64_GOT16, 14)
+ RELOC_NUMBER (R_PPC64_GOT16_LO, 15)
+ RELOC_NUMBER (R_PPC64_GOT16_HI, 16)
+ RELOC_NUMBER (R_PPC64_GOT16_HA, 17)
+ /* 18 unused. 32-bit reloc is R_PPC_PLTREL24. */
+ RELOC_NUMBER (R_PPC64_COPY, 19)
+ RELOC_NUMBER (R_PPC64_GLOB_DAT, 20)
+ RELOC_NUMBER (R_PPC64_JMP_SLOT, 21)
+ RELOC_NUMBER (R_PPC64_RELATIVE, 22)
+ /* 23 unused. 32-bit reloc is R_PPC_LOCAL24PC. */
+ RELOC_NUMBER (R_PPC64_UADDR32, 24)
+ RELOC_NUMBER (R_PPC64_UADDR16, 25)
+ RELOC_NUMBER (R_PPC64_REL32, 26)
+ RELOC_NUMBER (R_PPC64_PLT32, 27)
+ RELOC_NUMBER (R_PPC64_PLTREL32, 28)
+ RELOC_NUMBER (R_PPC64_PLT16_LO, 29)
+ RELOC_NUMBER (R_PPC64_PLT16_HI, 30)
+ RELOC_NUMBER (R_PPC64_PLT16_HA, 31)
+ /* 32 unused. 32-bit reloc is R_PPC_SDAREL16. */
+ RELOC_NUMBER (R_PPC64_SECTOFF, 33)
+ RELOC_NUMBER (R_PPC64_SECTOFF_LO, 34)
+ RELOC_NUMBER (R_PPC64_SECTOFF_HI, 35)
+ RELOC_NUMBER (R_PPC64_SECTOFF_HA, 36)
+ RELOC_NUMBER (R_PPC64_REL30, 37)
+ RELOC_NUMBER (R_PPC64_ADDR64, 38)
+ RELOC_NUMBER (R_PPC64_ADDR16_HIGHER, 39)
+ RELOC_NUMBER (R_PPC64_ADDR16_HIGHERA, 40)
+ RELOC_NUMBER (R_PPC64_ADDR16_HIGHEST, 41)
+ RELOC_NUMBER (R_PPC64_ADDR16_HIGHESTA, 42)
+ RELOC_NUMBER (R_PPC64_UADDR64, 43)
+ RELOC_NUMBER (R_PPC64_REL64, 44)
+ RELOC_NUMBER (R_PPC64_PLT64, 45)
+ RELOC_NUMBER (R_PPC64_PLTREL64, 46)
+ RELOC_NUMBER (R_PPC64_TOC16, 47)
+ RELOC_NUMBER (R_PPC64_TOC16_LO, 48)
+ RELOC_NUMBER (R_PPC64_TOC16_HI, 49)
+ RELOC_NUMBER (R_PPC64_TOC16_HA, 50)
+ RELOC_NUMBER (R_PPC64_TOC, 51)
+ RELOC_NUMBER (R_PPC64_PLTGOT16, 52)
+ RELOC_NUMBER (R_PPC64_PLTGOT16_LO, 53)
+ RELOC_NUMBER (R_PPC64_PLTGOT16_HI, 54)
+ RELOC_NUMBER (R_PPC64_PLTGOT16_HA, 55)
+
+ /* The following relocs were added in the 64-bit PowerPC ELF ABI
+ revision 1.2. */
+ RELOC_NUMBER (R_PPC64_ADDR16_DS, 56)
+ RELOC_NUMBER (R_PPC64_ADDR16_LO_DS, 57)
+ RELOC_NUMBER (R_PPC64_GOT16_DS, 58)
+ RELOC_NUMBER (R_PPC64_GOT16_LO_DS, 59)
+ RELOC_NUMBER (R_PPC64_PLT16_LO_DS, 60)
+ RELOC_NUMBER (R_PPC64_SECTOFF_DS, 61)
+ RELOC_NUMBER (R_PPC64_SECTOFF_LO_DS, 62)
+ RELOC_NUMBER (R_PPC64_TOC16_DS, 63)
+ RELOC_NUMBER (R_PPC64_TOC16_LO_DS, 64)
+ RELOC_NUMBER (R_PPC64_PLTGOT16_DS, 65)
+ RELOC_NUMBER (R_PPC64_PLTGOT16_LO_DS, 66)
+
+ /* Relocs added to support TLS. PowerPC64 ELF ABI revision 1.5. */
+ RELOC_NUMBER (R_PPC64_TLS, 67)
+ RELOC_NUMBER (R_PPC64_DTPMOD64, 68)
+ RELOC_NUMBER (R_PPC64_TPREL16, 69)
+ RELOC_NUMBER (R_PPC64_TPREL16_LO, 70)
+ RELOC_NUMBER (R_PPC64_TPREL16_HI, 71)
+ RELOC_NUMBER (R_PPC64_TPREL16_HA, 72)
+ RELOC_NUMBER (R_PPC64_TPREL64, 73)
+ RELOC_NUMBER (R_PPC64_DTPREL16, 74)
+ RELOC_NUMBER (R_PPC64_DTPREL16_LO, 75)
+ RELOC_NUMBER (R_PPC64_DTPREL16_HI, 76)
+ RELOC_NUMBER (R_PPC64_DTPREL16_HA, 77)
+ RELOC_NUMBER (R_PPC64_DTPREL64, 78)
+ RELOC_NUMBER (R_PPC64_GOT_TLSGD16, 79)
+ RELOC_NUMBER (R_PPC64_GOT_TLSGD16_LO, 80)
+ RELOC_NUMBER (R_PPC64_GOT_TLSGD16_HI, 81)
+ RELOC_NUMBER (R_PPC64_GOT_TLSGD16_HA, 82)
+ RELOC_NUMBER (R_PPC64_GOT_TLSLD16, 83)
+ RELOC_NUMBER (R_PPC64_GOT_TLSLD16_LO, 84)
+ RELOC_NUMBER (R_PPC64_GOT_TLSLD16_HI, 85)
+ RELOC_NUMBER (R_PPC64_GOT_TLSLD16_HA, 86)
+ RELOC_NUMBER (R_PPC64_GOT_TPREL16_DS, 87)
+ RELOC_NUMBER (R_PPC64_GOT_TPREL16_LO_DS, 88)
+ RELOC_NUMBER (R_PPC64_GOT_TPREL16_HI, 89)
+ RELOC_NUMBER (R_PPC64_GOT_TPREL16_HA, 90)
+ RELOC_NUMBER (R_PPC64_GOT_DTPREL16_DS, 91)
+ RELOC_NUMBER (R_PPC64_GOT_DTPREL16_LO_DS, 92)
+ RELOC_NUMBER (R_PPC64_GOT_DTPREL16_HI, 93)
+ RELOC_NUMBER (R_PPC64_GOT_DTPREL16_HA, 94)
+ RELOC_NUMBER (R_PPC64_TPREL16_DS, 95)
+ RELOC_NUMBER (R_PPC64_TPREL16_LO_DS, 96)
+ RELOC_NUMBER (R_PPC64_TPREL16_HIGHER, 97)
+ RELOC_NUMBER (R_PPC64_TPREL16_HIGHERA, 98)
+ RELOC_NUMBER (R_PPC64_TPREL16_HIGHEST, 99)
+ RELOC_NUMBER (R_PPC64_TPREL16_HIGHESTA, 100)
+ RELOC_NUMBER (R_PPC64_DTPREL16_DS, 101)
+ RELOC_NUMBER (R_PPC64_DTPREL16_LO_DS, 102)
+ RELOC_NUMBER (R_PPC64_DTPREL16_HIGHER, 103)
+ RELOC_NUMBER (R_PPC64_DTPREL16_HIGHERA, 104)
+ RELOC_NUMBER (R_PPC64_DTPREL16_HIGHEST, 105)
+ RELOC_NUMBER (R_PPC64_DTPREL16_HIGHESTA, 106)
+
+ /* These are GNU extensions to enable C++ vtable garbage collection. */
+ RELOC_NUMBER (R_PPC64_GNU_VTINHERIT, 253)
+ RELOC_NUMBER (R_PPC64_GNU_VTENTRY, 254)
+
+END_RELOC_NUMBERS (R_PPC64_max)
+
+#define IS_PPC64_TLS_RELOC(R) \
+ ((R) >= R_PPC64_TLS && (R) <= R_PPC64_DTPREL16_HIGHESTA)
+
+/* Specify the start of the .glink section. */
+#define DT_PPC64_GLINK DT_LOPROC
+
+/* Specify the start and size of the .opd section. */
+#define DT_PPC64_OPD (DT_LOPROC + 1)
+#define DT_PPC64_OPDSZ (DT_LOPROC + 2)
+
+#endif /* _ELF_PPC64_H */
diff --git a/contrib/binutils/include/elf/reloc-macros.h b/contrib/binutils/include/elf/reloc-macros.h
index 9ad346c..4a3a60f 100644
--- a/contrib/binutils/include/elf/reloc-macros.h
+++ b/contrib/binutils/include/elf/reloc-macros.h
@@ -1,5 +1,5 @@
/* Generic relocation support for BFD.
- Copyright 1998, 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2003 Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -46,10 +46,9 @@
If RELOC_MACROS_GEN_FUNC *is* defined, then instead the
following function will be generated:
- static const char * foo PARAMS ((unsigned long rtype));
+ static const char *foo (unsigned long rtype);
static const char *
- foo (rtype)
- unsigned long rtype;
+ foo (unsigned long rtype)
{
switch (rtype)
{
@@ -70,26 +69,22 @@
the relocation is not recognised, NULL is returned. */
#define START_RELOC_NUMBERS(name) \
-static const char * name PARAMS ((unsigned long rtype)); \
+static const char *name (unsigned long rtype); \
static const char * \
-name (rtype) \
- unsigned long rtype; \
+name (unsigned long rtype) \
{ \
switch (rtype) \
- {
+ {
-#if defined (__STDC__) || defined (ALMOST_STDC)
-#define RELOC_NUMBER(name, number) case number : return #name ;
-#else
-#define RELOC_NUMBER(name, number) case number : return "name" ;
-#endif
+#define RELOC_NUMBER(name, number) \
+ case number: return #name;
#define FAKE_RELOC(name, number)
#define EMPTY_RELOC(name)
#define END_RELOC_NUMBERS(name) \
default: return NULL; \
- } \
+ } \
}
diff --git a/contrib/binutils/include/elf/s390.h b/contrib/binutils/include/elf/s390.h
index 8b67c96..3a1306f 100644
--- a/contrib/binutils/include/elf/s390.h
+++ b/contrib/binutils/include/elf/s390.h
@@ -49,7 +49,7 @@ START_RELOC_NUMBERS (elf_s390_reloc_type)
RELOC_NUMBER (R_390_GLOB_DAT, 10) /* Create GOT entry. */
RELOC_NUMBER (R_390_JMP_SLOT, 11) /* Create PLT entry. */
RELOC_NUMBER (R_390_RELATIVE, 12) /* Adjust by program base. */
- RELOC_NUMBER (R_390_GOTOFF, 13) /* 32 bit offset to GOT. */
+ RELOC_NUMBER (R_390_GOTOFF32, 13) /* 32 bit offset to GOT. */
RELOC_NUMBER (R_390_GOTPC, 14) /* 32 bit PC relative offset to GOT. */
RELOC_NUMBER (R_390_GOT16, 15) /* 16 bit GOT offset. */
RELOC_NUMBER (R_390_PC16, 16) /* PC relative 16 bit. */
@@ -63,6 +63,58 @@ START_RELOC_NUMBERS (elf_s390_reloc_type)
RELOC_NUMBER (R_390_GOT64, 24) /* 64 bit GOT offset. */
RELOC_NUMBER (R_390_PLT64, 25) /* 64 bit PC relative PLT address. */
RELOC_NUMBER (R_390_GOTENT, 26) /* 32 bit PC rel. to GOT entry >> 1. */
+ RELOC_NUMBER (R_390_GOTOFF16, 27) /* 16 bit offset to GOT. */
+ RELOC_NUMBER (R_390_GOTOFF64, 28) /* 64 bit offset to GOT. */
+ RELOC_NUMBER (R_390_GOTPLT12, 29) /* 12 bit offset to jump slot. */
+ RELOC_NUMBER (R_390_GOTPLT16, 30) /* 16 bit offset to jump slot. */
+ RELOC_NUMBER (R_390_GOTPLT32, 31) /* 32 bit offset to jump slot. */
+ RELOC_NUMBER (R_390_GOTPLT64, 32) /* 64 bit offset to jump slot. */
+ RELOC_NUMBER (R_390_GOTPLTENT, 33) /* 32 bit rel. offset to jump slot. */
+ RELOC_NUMBER (R_390_PLTOFF16, 34) /* 16 bit offset from GOT to PLT. */
+ RELOC_NUMBER (R_390_PLTOFF32, 35) /* 32 bit offset from GOT to PLT. */
+ RELOC_NUMBER (R_390_PLTOFF64, 36) /* 16 bit offset from GOT to PLT. */
+ RELOC_NUMBER (R_390_TLS_LOAD, 37) /* Tag for load insn in TLS code. */
+ RELOC_NUMBER (R_390_TLS_GDCALL, 38) /* Tag for function call in general
+ dynamic TLS code. */
+ RELOC_NUMBER (R_390_TLS_LDCALL, 39) /* Tag for function call in local
+ dynamic TLS code. */
+ RELOC_NUMBER (R_390_TLS_GD32, 40) /* Direct 32 bit for general dynamic
+ thread local data. */
+ RELOC_NUMBER (R_390_TLS_GD64, 41) /* Direct 64 bit for general dynamic
+ thread local data. */
+ RELOC_NUMBER (R_390_TLS_GOTIE12, 42)/* 12 bit GOT offset for static TLS
+ block offset. */
+ RELOC_NUMBER (R_390_TLS_GOTIE32, 43)/* 32 bit GOT offset for static TLS
+ block offset. */
+ RELOC_NUMBER (R_390_TLS_GOTIE64, 44)/* 64 bit GOT offset for static TLS
+ block offset. */
+ RELOC_NUMBER (R_390_TLS_LDM32, 45) /* Direct 32 bit for local dynamic
+ thread local data in LD code. */
+ RELOC_NUMBER (R_390_TLS_LDM64, 46) /* Direct 64 bit for local dynamic
+ thread local data in LD code. */
+ RELOC_NUMBER (R_390_TLS_IE32, 47) /* 32 bit address of GOT entry for
+ negated static TLS block offset. */
+ RELOC_NUMBER (R_390_TLS_IE64, 48) /* 64 bit address of GOT entry for
+ negated static TLS block offset. */
+ RELOC_NUMBER (R_390_TLS_IEENT, 49) /* 32 bit rel. offset to GOT entry for
+ negated static TLS block offset. */
+ RELOC_NUMBER (R_390_TLS_LE32, 50) /* 32 bit negated offset relative to
+ static TLS block. */
+ RELOC_NUMBER (R_390_TLS_LE64, 51) /* 64 bit negated offset relative to
+ static TLS block. */
+ RELOC_NUMBER (R_390_TLS_LDO32, 52) /* 32 bit offset relative to TLS
+ block. */
+ RELOC_NUMBER (R_390_TLS_LDO64, 53) /* 64 bit offset relative to TLS
+ block. */
+ RELOC_NUMBER (R_390_TLS_DTPMOD, 54) /* ID of module containing symbol. */
+ RELOC_NUMBER (R_390_TLS_DTPOFF, 55) /* Offset in TLS block. */
+ RELOC_NUMBER (R_390_TLS_TPOFF, 56) /* Negate offset in static TLS
+ block. */
+ RELOC_NUMBER (R_390_20, 57) /* Direct 20 bit. */
+ RELOC_NUMBER (R_390_GOT20, 58) /* 20 bit GOT offset. */
+ RELOC_NUMBER (R_390_GOTPLT20, 59) /* 20 bit offset to jump slot. */
+ RELOC_NUMBER (R_390_TLS_GOTIE20, 60)/* 20 bit GOT offset for statis TLS
+ block offset. */
/* These are GNU extensions to enable C++ vtable garbage collection. */
RELOC_NUMBER (R_390_GNU_VTINHERIT, 250)
RELOC_NUMBER (R_390_GNU_VTENTRY, 251)
diff --git a/contrib/binutils/include/elf/sh.h b/contrib/binutils/include/elf/sh.h
index af78c9b..15d460d 100644
--- a/contrib/binutils/include/elf/sh.h
+++ b/contrib/binutils/include/elf/sh.h
@@ -1,5 +1,5 @@
/* SH ELF support for BFD.
- Copyright 1998, 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 1998, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -27,12 +27,18 @@
#define EF_SH1 1
#define EF_SH2 2
#define EF_SH3 3
-#define EF_SH_HAS_DSP(flags) ((flags) & 4)
+#define EF_SH_HAS_DSP(flags) (((flags) & EF_SH_MACH_MASK & ~3) == 4)
#define EF_SH_DSP 4
#define EF_SH3_DSP 5
+#define EF_SH4AL_DSP 6
#define EF_SH_HAS_FP(flags) ((flags) & 8)
#define EF_SH3E 8
#define EF_SH4 9
+#define EF_SH2E 11
+#define EF_SH4A 12
+
+#define EF_SH4_NOFPU 0x10
+#define EF_SH4A_NOFPU 0x11
/* This one can only mix in objects from other EF_SH5 objects. */
#define EF_SH5 10
@@ -45,10 +51,32 @@
: (((mach1) < EF_SH3 && (mach2) == EF_SH_UNKNOWN) \
|| ((mach2) < EF_SH3 && (mach1) == EF_SH_UNKNOWN)) \
? EF_SH3 \
+ : ((mach1) == EF_SH2E && EF_SH_HAS_FP (mach2)) \
+ ? (mach2) \
+ : ((mach2) == EF_SH2E && EF_SH_HAS_FP (mach1)) \
+ ? (mach1) \
+ : (((mach1) == EF_SH2E && (mach2) == EF_SH_UNKNOWN) \
+ || ((mach2) == EF_SH2E && (mach1) == EF_SH_UNKNOWN)) \
+ ? EF_SH2E \
: (((mach1) == EF_SH3E && (mach2) == EF_SH_UNKNOWN) \
|| ((mach2) == EF_SH3E && (mach1) == EF_SH_UNKNOWN)) \
? EF_SH4 \
- : ((mach1) > (mach2) ? (mach1) : (mach2)))
+ /* ??? SH4? Why not SH3E? */ \
+ : ((((mach1) == EF_SH4_NOFPU || (mach1) == EF_SH4A_NOFPU) \
+ && EF_SH_HAS_DSP (mach2)) \
+ || (((mach2) == EF_SH4_NOFPU || (mach2) == EF_SH4A_NOFPU) \
+ && EF_SH_HAS_DSP (mach1))) \
+ ? EF_SH4AL_DSP \
+ : ((mach1) == EF_SH4_NOFPU && EF_SH_HAS_FP (mach2)) \
+ ? ((mach2) < EF_SH4A) ? EF_SH4 : (mach2) \
+ : ((mach2) == EF_SH4_NOFPU && EF_SH_HAS_FP (mach1)) \
+ ? ((mach1) < EF_SH4A) ? EF_SH4 : (mach1) \
+ : ((mach1) == EF_SH4A_NOFPU && EF_SH_HAS_FP (mach2)) \
+ ? ((mach2) <= EF_SH4A) ? EF_SH4A : (mach2) \
+ : ((mach2) == EF_SH4A_NOFPU && EF_SH_HAS_FP (mach1)) \
+ ? ((mach1) <= EF_SH4A) ? EF_SH4A : (mach1) \
+ : (((mach1) == EF_SH2E ? 7 : (mach1)) > ((mach2) == EF_SH2E ? 7 : (mach2)) \
+ ? (mach1) : (mach2)))
/* Flags for the st_other symbol field.
Keep away from the STV_ visibility flags (bit 0..1). */
@@ -71,66 +99,11 @@
symbols). */
#define STT_DATALABEL STT_LOPROC
-#define SH64_CRANGES_SECTION_NAME ".cranges"
-enum sh64_elf_cr_type {
- CRT_NONE = 0,
- CRT_DATA = 1,
- CRT_SH5_ISA16 = 2,
- CRT_SH5_ISA32 = 3
-};
-
-/* The official definition is this:
-
- typedef struct {
- Elf32_Addr cr_addr;
- Elf32_Word cr_size;
- Elf32_Half cr_type;
- } Elf32_CRange;
-
- but we have no use for that exact type. Instead we use this struct for
- the internal representation. */
-typedef struct {
- bfd_vma cr_addr;
- bfd_size_type cr_size;
- enum sh64_elf_cr_type cr_type;
-} sh64_elf_crange;
-
-#define SH64_CRANGE_SIZE (4 + 4 + 2)
-#define SH64_CRANGE_CR_ADDR_OFFSET 0
-#define SH64_CRANGE_CR_SIZE_OFFSET 4
-#define SH64_CRANGE_CR_TYPE_OFFSET (4 + 4)
-
-/* Get the contents type of an arbitrary address, or return CRT_NONE. */
-extern enum sh64_elf_cr_type sh64_get_contents_type
- PARAMS ((asection *, bfd_vma, sh64_elf_crange *));
-
-/* Simpler interface.
- FIXME: This seems redundant now that we export the interface above. */
-extern boolean sh64_address_is_shmedia PARAMS ((asection *, bfd_vma));
-
-extern int _bfd_sh64_crange_qsort_cmpb PARAMS ((const void *, const void *));
-extern int _bfd_sh64_crange_qsort_cmpl PARAMS ((const void *, const void *));
-extern int _bfd_sh64_crange_bsearch_cmpb PARAMS ((const void *, const void *));
-extern int _bfd_sh64_crange_bsearch_cmpl PARAMS ((const void *, const void *));
-
-/* We put this in elf_section_data (section)->tdata. */
-struct sh64_section_data
-{
- flagword contents_flags;
-
- /* Only used in the cranges section, but we don't have an official
- backend-specific bfd field. */
- bfd_size_type cranges_growth;
-};
-
-#define sh64_elf_section_data(sec) \
- ((struct sh64_section_data *) ((elf_section_data (sec))->tdata))
-
#include "elf/reloc-macros.h"
/* Relocations. */
-/* Relocations 25ff are GNU extensions.
- 25..33 are used for relaxation and use the same constants as COFF uses. */
+/* Relocations 10-32 and 128-255 are GNU extensions.
+ 25..32 and 10 are used for relaxation. */
START_RELOC_NUMBERS (elf_sh_reloc_type)
RELOC_NUMBER (R_SH_NONE, 0)
RELOC_NUMBER (R_SH_DIR32, 1)
@@ -142,8 +115,16 @@ START_RELOC_NUMBERS (elf_sh_reloc_type)
RELOC_NUMBER (R_SH_DIR8BP, 7)
RELOC_NUMBER (R_SH_DIR8W, 8)
RELOC_NUMBER (R_SH_DIR8L, 9)
- FAKE_RELOC (R_SH_FIRST_INVALID_RELOC, 10)
- FAKE_RELOC (R_SH_LAST_INVALID_RELOC, 24)
+
+ RELOC_NUMBER (R_SH_LOOP_START, 10)
+ RELOC_NUMBER (R_SH_LOOP_END, 11)
+
+ FAKE_RELOC (R_SH_FIRST_INVALID_RELOC, 12)
+ FAKE_RELOC (R_SH_LAST_INVALID_RELOC, 21)
+
+ RELOC_NUMBER (R_SH_GNU_VTINHERIT, 22)
+ RELOC_NUMBER (R_SH_GNU_VTENTRY, 23)
+ RELOC_NUMBER (R_SH_SWITCH8, 24)
RELOC_NUMBER (R_SH_SWITCH16, 25)
RELOC_NUMBER (R_SH_SWITCH32, 26)
RELOC_NUMBER (R_SH_USES, 27)
@@ -152,13 +133,19 @@ START_RELOC_NUMBERS (elf_sh_reloc_type)
RELOC_NUMBER (R_SH_CODE, 30)
RELOC_NUMBER (R_SH_DATA, 31)
RELOC_NUMBER (R_SH_LABEL, 32)
- RELOC_NUMBER (R_SH_SWITCH8, 33)
- RELOC_NUMBER (R_SH_GNU_VTINHERIT, 34)
- RELOC_NUMBER (R_SH_GNU_VTENTRY, 35)
- RELOC_NUMBER (R_SH_LOOP_START, 36)
- RELOC_NUMBER (R_SH_LOOP_END, 37)
- FAKE_RELOC (R_SH_FIRST_INVALID_RELOC_2, 38)
- FAKE_RELOC (R_SH_LAST_INVALID_RELOC_2, 44)
+
+ RELOC_NUMBER (R_SH_DIR16, 33)
+ RELOC_NUMBER (R_SH_DIR8, 34)
+ RELOC_NUMBER (R_SH_DIR8UL, 35)
+ RELOC_NUMBER (R_SH_DIR8UW, 36)
+ RELOC_NUMBER (R_SH_DIR8U, 37)
+ RELOC_NUMBER (R_SH_DIR8SW, 38)
+ RELOC_NUMBER (R_SH_DIR8S, 39)
+ RELOC_NUMBER (R_SH_DIR4UL, 40)
+ RELOC_NUMBER (R_SH_DIR4UW, 41)
+ RELOC_NUMBER (R_SH_DIR4U, 42)
+ RELOC_NUMBER (R_SH_PSHA, 43)
+ RELOC_NUMBER (R_SH_PSHL, 44)
RELOC_NUMBER (R_SH_DIR5U, 45)
RELOC_NUMBER (R_SH_DIR6U, 46)
RELOC_NUMBER (R_SH_DIR6S, 47)
@@ -166,8 +153,21 @@ START_RELOC_NUMBERS (elf_sh_reloc_type)
RELOC_NUMBER (R_SH_DIR10SW, 49)
RELOC_NUMBER (R_SH_DIR10SL, 50)
RELOC_NUMBER (R_SH_DIR10SQ, 51)
- FAKE_RELOC (R_SH_FIRST_INVALID_RELOC_3, 52)
- FAKE_RELOC (R_SH_LAST_INVALID_RELOC_3, 159)
+ FAKE_RELOC (R_SH_FIRST_INVALID_RELOC_2, 52)
+ FAKE_RELOC (R_SH_LAST_INVALID_RELOC_2, 52)
+ RELOC_NUMBER (R_SH_DIR16S, 53)
+ FAKE_RELOC (R_SH_FIRST_INVALID_RELOC_3, 54)
+ FAKE_RELOC (R_SH_LAST_INVALID_RELOC_3, 143)
+ RELOC_NUMBER (R_SH_TLS_GD_32, 144)
+ RELOC_NUMBER (R_SH_TLS_LD_32, 145)
+ RELOC_NUMBER (R_SH_TLS_LDO_32, 146)
+ RELOC_NUMBER (R_SH_TLS_IE_32, 147)
+ RELOC_NUMBER (R_SH_TLS_LE_32, 148)
+ RELOC_NUMBER (R_SH_TLS_DTPMOD32, 149)
+ RELOC_NUMBER (R_SH_TLS_DTPOFF32, 150)
+ RELOC_NUMBER (R_SH_TLS_TPOFF32, 151)
+ FAKE_RELOC (R_SH_FIRST_INVALID_RELOC_4, 152)
+ FAKE_RELOC (R_SH_LAST_INVALID_RELOC_4, 159)
RELOC_NUMBER (R_SH_GOT32, 160)
RELOC_NUMBER (R_SH_PLT32, 161)
RELOC_NUMBER (R_SH_COPY, 162)
@@ -205,8 +205,8 @@ START_RELOC_NUMBERS (elf_sh_reloc_type)
RELOC_NUMBER (R_SH_GLOB_DAT64, 194)
RELOC_NUMBER (R_SH_JMP_SLOT64, 195)
RELOC_NUMBER (R_SH_RELATIVE64, 196)
- FAKE_RELOC (R_SH_FIRST_INVALID_RELOC_4, 197)
- FAKE_RELOC (R_SH_LAST_INVALID_RELOC_4, 241)
+ FAKE_RELOC (R_SH_FIRST_INVALID_RELOC_5, 197)
+ FAKE_RELOC (R_SH_LAST_INVALID_RELOC_5, 241)
RELOC_NUMBER (R_SH_SHMEDIA_CODE, 242)
RELOC_NUMBER (R_SH_PT_16, 243)
RELOC_NUMBER (R_SH_IMMS16, 244)
diff --git a/contrib/binutils/include/elf/sparc.h b/contrib/binutils/include/elf/sparc.h
index 7c780f7..2d28d26 100644
--- a/contrib/binutils/include/elf/sparc.h
+++ b/contrib/binutils/include/elf/sparc.h
@@ -1,5 +1,5 @@
/* SPARC ELF support for BFD.
- Copyright 1996, 1997, 1998, 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1996, 1997, 1998, 1999, 2000, 2002 Free Software Foundation, Inc.
By Doug Evans, Cygnus Support, <dje@cygnus.com>.
This file is part of BFD, the Binary File Descriptor library.
@@ -126,13 +126,36 @@ START_RELOC_NUMBERS (elf_sparc_reloc_type)
RELOC_NUMBER (R_SPARC_UA64, 54)
RELOC_NUMBER (R_SPARC_UA16, 55)
- /* little endian data relocs */
- RELOC_NUMBER (R_SPARC_REV32, 56)
-
+ RELOC_NUMBER (R_SPARC_TLS_GD_HI22, 56)
+ RELOC_NUMBER (R_SPARC_TLS_GD_LO10, 57)
+ RELOC_NUMBER (R_SPARC_TLS_GD_ADD, 58)
+ RELOC_NUMBER (R_SPARC_TLS_GD_CALL, 59)
+ RELOC_NUMBER (R_SPARC_TLS_LDM_HI22, 60)
+ RELOC_NUMBER (R_SPARC_TLS_LDM_LO10, 61)
+ RELOC_NUMBER (R_SPARC_TLS_LDM_ADD, 62)
+ RELOC_NUMBER (R_SPARC_TLS_LDM_CALL, 63)
+ RELOC_NUMBER (R_SPARC_TLS_LDO_HIX22, 64)
+ RELOC_NUMBER (R_SPARC_TLS_LDO_LOX10, 65)
+ RELOC_NUMBER (R_SPARC_TLS_LDO_ADD, 66)
+ RELOC_NUMBER (R_SPARC_TLS_IE_HI22, 67)
+ RELOC_NUMBER (R_SPARC_TLS_IE_LO10, 68)
+ RELOC_NUMBER (R_SPARC_TLS_IE_LD, 69)
+ RELOC_NUMBER (R_SPARC_TLS_IE_LDX, 70)
+ RELOC_NUMBER (R_SPARC_TLS_IE_ADD, 71)
+ RELOC_NUMBER (R_SPARC_TLS_LE_HIX22, 72)
+ RELOC_NUMBER (R_SPARC_TLS_LE_LOX10, 73)
+ RELOC_NUMBER (R_SPARC_TLS_DTPMOD32, 74)
+ RELOC_NUMBER (R_SPARC_TLS_DTPMOD64, 75)
+ RELOC_NUMBER (R_SPARC_TLS_DTPOFF32, 76)
+ RELOC_NUMBER (R_SPARC_TLS_DTPOFF64, 77)
+ RELOC_NUMBER (R_SPARC_TLS_TPOFF32, 78)
+ RELOC_NUMBER (R_SPARC_TLS_TPOFF64, 79)
+
EMPTY_RELOC (R_SPARC_max_std)
RELOC_NUMBER (R_SPARC_GNU_VTINHERIT, 250)
RELOC_NUMBER (R_SPARC_GNU_VTENTRY, 251)
+ RELOC_NUMBER (R_SPARC_REV32, 252)
END_RELOC_NUMBERS (R_SPARC_max)
diff --git a/contrib/binutils/include/elf/v850.h b/contrib/binutils/include/elf/v850.h
index 62b9541..7d5110b 100644
--- a/contrib/binutils/include/elf/v850.h
+++ b/contrib/binutils/include/elf/v850.h
@@ -1,22 +1,22 @@
/* V850 ELF support for BFD.
- Copyright 1997, 1998, 2000 Free Software Foundation, Inc.
+ Copyright 1997, 1998, 2000, 2002, 2003 Free Software Foundation, Inc.
Created by Michael Meissner, Cygnus Support <meissner@cygnus.com>
-This file is part of BFD, the Binary File Descriptor library.
+ This file is part of BFD, the Binary File Descriptor library.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* This file holds definitions specific to the MIPS ELF ABI. Note
that most of this is not actually implemented by BFD. */
@@ -35,18 +35,18 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* v850e code. */
#define E_V850E_ARCH 0x10000000
-/* v850ea code. */
-#define E_V850EA_ARCH 0x20000000
+/* v850e1 code. */
+#define E_V850E1_ARCH 0x20000000
-/* Flags for the st_other field */
-#define V850_OTHER_SDA 0x01 /* symbol had SDA relocations */
-#define V850_OTHER_ZDA 0x02 /* symbol had ZDA relocations */
-#define V850_OTHER_TDA 0x04 /* symbol had TDA relocations */
-#define V850_OTHER_TDA_BYTE 0x08 /* symbol had TDA byte relocations */
-#define V850_OTHER_ERROR 0x80 /* symbol had an error reported */
+/* Flags for the st_other field. */
+#define V850_OTHER_SDA 0x01 /* Symbol had SDA relocations. */
+#define V850_OTHER_ZDA 0x02 /* Symbol had ZDA relocations. */
+#define V850_OTHER_TDA 0x04 /* Symbol had TDA relocations. */
+#define V850_OTHER_TDA_BYTE 0x08 /* Symbol had TDA byte relocations. */
+#define V850_OTHER_ERROR 0x80 /* Symbol had an error reported. */
-/* V850 relocations */
+/* V850 relocations. */
#include "elf/reloc-macros.h"
START_RELOC_NUMBERS (v850_reloc_type)
@@ -56,7 +56,7 @@ START_RELOC_NUMBERS (v850_reloc_type)
RELOC_NUMBER (R_V850_HI16_S, 3)
RELOC_NUMBER (R_V850_HI16, 4)
RELOC_NUMBER (R_V850_LO16, 5)
- RELOC_NUMBER (R_V850_32, 6)
+ RELOC_NUMBER (R_V850_ABS32, 6)
RELOC_NUMBER (R_V850_16, 7)
RELOC_NUMBER (R_V850_8, 8)
RELOC_NUMBER( R_V850_SDA_16_16_OFFSET, 9) /* For ld.b, st.b, set1, clr1, not1, tst1, movea, movhi */
@@ -75,6 +75,10 @@ START_RELOC_NUMBERS (v850_reloc_type)
RELOC_NUMBER( R_V850_CALLT_16_16_OFFSET, 22) /* For callt */
RELOC_NUMBER (R_V850_GNU_VTINHERIT, 23)
RELOC_NUMBER (R_V850_GNU_VTENTRY, 24)
+ RELOC_NUMBER (R_V850_LONGCALL, 25)
+ RELOC_NUMBER (R_V850_LONGJUMP, 26)
+ RELOC_NUMBER (R_V850_ALIGN, 27)
+ RELOC_NUMBER (R_V850_REL32, 28)
END_RELOC_NUMBERS (R_V850_max)
@@ -103,5 +107,15 @@ END_RELOC_NUMBERS (R_V850_max)
/* Section contains the .scommon data. */
#define SHT_V850_ZCOMMON 0x70000002
+/* Processor specific section flags. */
+
+/* This section must be in the small data area (pointed to by GP). */
+#define SHF_V850_GPREL 0x10000000
+
+/* This section must be in the tiny data area (pointed to by EP). */
+#define SHF_V850_EPREL 0x20000000
+
+/* This section must be in the zero data area (pointed to by R0). */
+#define SHF_V850_R0REL 0x40000000
#endif /* _ELF_V850_H */
diff --git a/contrib/binutils/include/elf/x86-64.h b/contrib/binutils/include/elf/x86-64.h
index 74febc2..7e9100d 100644
--- a/contrib/binutils/include/elf/x86-64.h
+++ b/contrib/binutils/include/elf/x86-64.h
@@ -1,5 +1,5 @@
/* x86_64 ELF support for BFD.
- Copyright (C) 2000 Free Software Foundation, Inc.
+ Copyright (C) 2000, 2002 Free Software Foundation, Inc.
Contributed by Jan Hubicka <jh@suse.cz>
This file is part of BFD, the Binary File Descriptor library.
@@ -25,22 +25,30 @@
START_RELOC_NUMBERS (elf_x86_64_reloc_type)
RELOC_NUMBER (R_X86_64_NONE, 0) /* No reloc */
- RELOC_NUMBER (R_X86_64_64, 1) /* Direct 64 bit */
+ RELOC_NUMBER (R_X86_64_64, 1) /* Direct 64 bit */
RELOC_NUMBER (R_X86_64_PC32, 2) /* PC relative 32 bit signed */
RELOC_NUMBER (R_X86_64_GOT32, 3) /* 32 bit GOT entry */
RELOC_NUMBER (R_X86_64_PLT32, 4) /* 32 bit PLT address */
RELOC_NUMBER (R_X86_64_COPY, 5) /* Copy symbol at runtime */
RELOC_NUMBER (R_X86_64_GLOB_DAT, 6) /* Create GOT entry */
- RELOC_NUMBER (R_X86_64_JUMP_SLOT, 7) /* Create PLT entry */
+ RELOC_NUMBER (R_X86_64_JUMP_SLOT,7) /* Create PLT entry */
RELOC_NUMBER (R_X86_64_RELATIVE, 8) /* Adjust by program base */
RELOC_NUMBER (R_X86_64_GOTPCREL, 9) /* 32 bit signed pc relative
offset to GOT */
- RELOC_NUMBER (R_X86_64_32, 10) /* Direct 32 bit zero extended */
- RELOC_NUMBER (R_X86_64_32S, 11) /* Direct 32 bit sign extended */
- RELOC_NUMBER (R_X86_64_16, 12) /* Direct 16 bit zero extended */
+ RELOC_NUMBER (R_X86_64_32, 10) /* Direct 32 bit zero extended */
+ RELOC_NUMBER (R_X86_64_32S, 11) /* Direct 32 bit sign extended */
+ RELOC_NUMBER (R_X86_64_16, 12) /* Direct 16 bit zero extended */
RELOC_NUMBER (R_X86_64_PC16, 13) /* 16 bit sign extended pc relative*/
- RELOC_NUMBER (R_X86_64_8, 14) /* Direct 8 bit sign extended */
- RELOC_NUMBER (R_X86_64_PC8, 15) /* 8 bit sign extended pc relative*/
+ RELOC_NUMBER (R_X86_64_8, 14) /* Direct 8 bit sign extended */
+ RELOC_NUMBER (R_X86_64_PC8, 15) /* 8 bit sign extended pc relative*/
+ RELOC_NUMBER (R_X86_64_DTPMOD64, 16) /* ID of module containing symbol */
+ RELOC_NUMBER (R_X86_64_DTPOFF64, 17) /* Offset in TLS block */
+ RELOC_NUMBER (R_X86_64_TPOFF64, 18) /* Offset in initial TLS block */
+ RELOC_NUMBER (R_X86_64_TLSGD, 19) /* PC relative offset to GD GOT block */
+ RELOC_NUMBER (R_X86_64_TLSLD, 20) /* PC relative offset to LD GOT block */
+ RELOC_NUMBER (R_X86_64_DTPOFF32, 21) /* Offset in TLS block */
+ RELOC_NUMBER (R_X86_64_GOTTPOFF, 22) /* PC relative offset to IE GOT entry */
+ RELOC_NUMBER (R_X86_64_TPOFF32, 23) /* Offset in initial TLS block */
RELOC_NUMBER (R_X86_64_GNU_VTINHERIT, 250) /* GNU C++ hack */
RELOC_NUMBER (R_X86_64_GNU_VTENTRY, 251) /* GNU C++ hack */
END_RELOC_NUMBERS (R_X86_64_max)
diff --git a/contrib/binutils/include/elf/xstormy16.h b/contrib/binutils/include/elf/xstormy16.h
index ee6c551..6b1e98f 100644
--- a/contrib/binutils/include/elf/xstormy16.h
+++ b/contrib/binutils/include/elf/xstormy16.h
@@ -1,5 +1,5 @@
/* XSTORMY16 ELF support for BFD.
- Copyright (C) 2001 Free Software Foundation, Inc.
+ Copyright (C) 2001, 2002 Free Software Foundation, Inc.
This file is part of BFD, the Binary File Descriptor library.
@@ -37,6 +37,10 @@ START_RELOC_NUMBERS (elf_xstormy16_reloc_type)
RELOC_NUMBER (R_XSTORMY16_24, 8)
RELOC_NUMBER (R_XSTORMY16_FPTR16, 9)
+ RELOC_NUMBER (R_XSTORMY16_LO16, 10)
+ RELOC_NUMBER (R_XSTORMY16_HI16, 11)
+ RELOC_NUMBER (R_XSTORMY16_12, 12)
+
RELOC_NUMBER (R_XSTORMY16_GNU_VTINHERIT, 128)
RELOC_NUMBER (R_XSTORMY16_GNU_VTENTRY, 129)
END_RELOC_NUMBERS (R_XSTORMY16_max)
diff --git a/contrib/binutils/include/elf/xtensa.h b/contrib/binutils/include/elf/xtensa.h
new file mode 100644
index 0000000..6c584c7
--- /dev/null
+++ b/contrib/binutils/include/elf/xtensa.h
@@ -0,0 +1,88 @@
+/* Xtensa ELF support for BFD.
+ Copyright 2003 Free Software Foundation, Inc.
+ Contributed by Bob Wilson (bwilson@tensilica.com) at Tensilica.
+
+ This file is part of BFD, the Binary File Descriptor library.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
+ USA. */
+
+/* This file holds definitions specific to the Xtensa ELF ABI. */
+
+#ifndef _ELF_XTENSA_H
+#define _ELF_XTENSA_H
+
+#include "elf/reloc-macros.h"
+
+/* Relocations. */
+START_RELOC_NUMBERS (elf_xtensa_reloc_type)
+ RELOC_NUMBER (R_XTENSA_NONE, 0)
+ RELOC_NUMBER (R_XTENSA_32, 1)
+ RELOC_NUMBER (R_XTENSA_RTLD, 2)
+ RELOC_NUMBER (R_XTENSA_GLOB_DAT, 3)
+ RELOC_NUMBER (R_XTENSA_JMP_SLOT, 4)
+ RELOC_NUMBER (R_XTENSA_RELATIVE, 5)
+ RELOC_NUMBER (R_XTENSA_PLT, 6)
+ RELOC_NUMBER (R_XTENSA_OP0, 8)
+ RELOC_NUMBER (R_XTENSA_OP1, 9)
+ RELOC_NUMBER (R_XTENSA_OP2, 10)
+ RELOC_NUMBER (R_XTENSA_ASM_EXPAND, 11)
+ RELOC_NUMBER (R_XTENSA_ASM_SIMPLIFY, 12)
+ RELOC_NUMBER (R_XTENSA_GNU_VTINHERIT, 15)
+ RELOC_NUMBER (R_XTENSA_GNU_VTENTRY, 16)
+END_RELOC_NUMBERS (R_XTENSA_max)
+
+/* Processor-specific flags for the ELF header e_flags field. */
+
+/* Four-bit Xtensa machine type field. */
+#define EF_XTENSA_MACH 0x0000000f
+
+/* Various CPU types. */
+#define E_XTENSA_MACH 0x00000000
+
+/* Leave bits 0xf0 alone in case we ever have more than 16 cpu types.
+ Highly unlikely, but what the heck. */
+
+#define EF_XTENSA_XT_INSN 0x00000100
+#define EF_XTENSA_XT_LIT 0x00000200
+
+
+/* Processor-specific dynamic array tags. */
+
+/* Offset of the table that records the GOT location(s). */
+#define DT_XTENSA_GOT_LOC_OFF 0x70000000
+
+/* Number of entries in the GOT location table. */
+#define DT_XTENSA_GOT_LOC_SZ 0x70000001
+
+
+/* Definitions for instruction and literal property tables. The
+ tables for ".gnu.linkonce.*" sections are placed in the following
+ sections:
+
+ instruction tables: .gnu.linkonce.x.*
+ literal tables: .gnu.linkonce.p.*
+*/
+
+#define XTENSA_INSN_SEC_NAME ".xt.insn"
+#define XTENSA_LIT_SEC_NAME ".xt.lit"
+
+typedef struct property_table_entry_t
+{
+ bfd_vma address;
+ bfd_vma size;
+} property_table_entry;
+
+#endif /* _ELF_XTENSA_H */
diff --git a/contrib/binutils/include/fibheap.h b/contrib/binutils/include/fibheap.h
index fc37f9e..4eebaf1 100644
--- a/contrib/binutils/include/fibheap.h
+++ b/contrib/binutils/include/fibheap.h
@@ -59,8 +59,13 @@ typedef struct fibnode
struct fibnode *right;
fibheapkey_t key;
void *data;
+#ifdef __GNUC__
+ __extension__ unsigned long int degree : 31;
+ __extension__ unsigned long int mark : 1;
+#else
unsigned int degree : 31;
unsigned int mark : 1;
+#endif
} *fibnode_t;
extern fibheap_t fibheap_new PARAMS ((void));
diff --git a/contrib/binutils/include/floatformat.h b/contrib/binutils/include/floatformat.h
index 53ead3e..a8244ad 100644
--- a/contrib/binutils/include/floatformat.h
+++ b/contrib/binutils/include/floatformat.h
@@ -1,5 +1,5 @@
/* IEEE floating point support declarations, for GDB, the GNU Debugger.
- Copyright 1991, 1994, 1995, 1997, 2000 Free Software Foundation, Inc.
+ Copyright 1991, 1994, 1995, 1997, 2000, 2003 Free Software Foundation, Inc.
This file is part of GDB.
@@ -61,8 +61,12 @@ struct floatformat
unsigned int exp_start;
unsigned int exp_len;
- /* Amount added to "true" exponent. 0x3fff for many IEEE extendeds. */
- unsigned int exp_bias;
+ /* Bias added to a "true" exponent to form the biased exponent. It
+ is intentionally signed as, otherwize, -exp_bias can turn into a
+ very large number (e.g., given the exp_bias of 0x3fff and a 64
+ bit long, the equation (long)(1 - exp_bias) evaluates to
+ 4294950914) instead of -16382). */
+ int exp_bias;
/* Exponent value which indicates NaN. This is the actual value stored in
the float, not adjusted by the exp_bias. This usually consists of all
one bits. */
@@ -76,6 +80,9 @@ struct floatformat
/* Internal name for debugging. */
const char *name;
+
+ /* Validator method. */
+ int (*is_valid) PARAMS ((const struct floatformat *fmt, const char *from));
};
/* floatformats for IEEE single and double, big and little endian. */
@@ -109,13 +116,18 @@ extern const struct floatformat floatformat_ia64_quad_little;
Store the double in *TO. */
extern void
-floatformat_to_double PARAMS ((const struct floatformat *, char *, double *));
+floatformat_to_double PARAMS ((const struct floatformat *, const char *, double *));
/* The converse: convert the double *FROM to FMT
and store where TO points. */
extern void
floatformat_from_double PARAMS ((const struct floatformat *,
- double *, char *));
+ const double *, char *));
+
+/* Return non-zero iff the data at FROM is a valid number in format FMT. */
+
+extern int
+floatformat_is_valid PARAMS ((const struct floatformat *fmt, const char *from));
#endif /* defined (FLOATFORMAT_H) */
diff --git a/contrib/binutils/include/getopt.h b/contrib/binutils/include/getopt.h
new file mode 100644
index 0000000..a99a229
--- /dev/null
+++ b/contrib/binutils/include/getopt.h
@@ -0,0 +1,144 @@
+/* Declarations for getopt.
+ Copyright 1989, 1990, 1991, 1992, 1993, 1994, 1996, 1997, 1998, 2000,
+ 2002 Free Software Foundation, Inc.
+
+ NOTE: The canonical source of this file is maintained with the GNU C Library.
+ Bugs can be reported to bug-glibc@gnu.org.
+
+ This program is free software; you can redistribute it and/or modify it
+ under the terms of the GNU General Public License as published by the
+ Free Software Foundation; either version 2, or (at your option) any
+ later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
+ USA. */
+
+#ifndef _GETOPT_H
+#define _GETOPT_H 1
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+/* For communication from `getopt' to the caller.
+ When `getopt' finds an option that takes an argument,
+ the argument value is returned here.
+ Also, when `ordering' is RETURN_IN_ORDER,
+ each non-option ARGV-element is returned here. */
+
+extern char *optarg;
+
+/* Index in ARGV of the next element to be scanned.
+ This is used for communication to and from the caller
+ and for communication between successive calls to `getopt'.
+
+ On entry to `getopt', zero means this is the first call; initialize.
+
+ When `getopt' returns -1, this is the index of the first of the
+ non-option elements that the caller should itself scan.
+
+ Otherwise, `optind' communicates from one call to the next
+ how much of ARGV has been scanned so far. */
+
+extern int optind;
+
+/* Callers store zero here to inhibit the error message `getopt' prints
+ for unrecognized options. */
+
+extern int opterr;
+
+/* Set to an option character which was unrecognized. */
+
+extern int optopt;
+
+/* Describe the long-named options requested by the application.
+ The LONG_OPTIONS argument to getopt_long or getopt_long_only is a vector
+ of `struct option' terminated by an element containing a name which is
+ zero.
+
+ The field `has_arg' is:
+ no_argument (or 0) if the option does not take an argument,
+ required_argument (or 1) if the option requires an argument,
+ optional_argument (or 2) if the option takes an optional argument.
+
+ If the field `flag' is not NULL, it points to a variable that is set
+ to the value given in the field `val' when the option is found, but
+ left unchanged if the option is not found.
+
+ To have a long-named option do something other than set an `int' to
+ a compiled-in constant, such as set a value from `optarg', set the
+ option's `flag' field to zero and its `val' field to a nonzero
+ value (the equivalent single-letter option character, if there is
+ one). For long options that have a zero `flag' field, `getopt'
+ returns the contents of the `val' field. */
+
+struct option
+{
+#if defined (__STDC__) && __STDC__
+ const char *name;
+#else
+ char *name;
+#endif
+ /* has_arg can't be an enum because some compilers complain about
+ type mismatches in all the code that assumes it is an int. */
+ int has_arg;
+ int *flag;
+ int val;
+};
+
+/* Names for the values of the `has_arg' field of `struct option'. */
+
+#define no_argument 0
+#define required_argument 1
+#define optional_argument 2
+
+#if defined (__STDC__) && __STDC__
+/* HAVE_DECL_* is a three-state macro: undefined, 0 or 1. If it is
+ undefined, we haven't run the autoconf check so provide the
+ declaration without arguments. If it is 0, we checked and failed
+ to find the declaration so provide a fully prototyped one. If it
+ is 1, we found it so don't provide any declaration at all. */
+#if !HAVE_DECL_GETOPT
+#if defined (__GNU_LIBRARY__) || defined (HAVE_DECL_GETOPT)
+/* Many other libraries have conflicting prototypes for getopt, with
+ differences in the consts, in unistd.h. To avoid compilation
+ errors, only prototype getopt for the GNU C library. */
+extern int getopt (int argc, char *const *argv, const char *shortopts);
+#else
+#ifndef __cplusplus
+extern int getopt ();
+#endif /* __cplusplus */
+#endif
+#endif /* !HAVE_DECL_GETOPT */
+
+extern int getopt_long (int argc, char *const *argv, const char *shortopts,
+ const struct option *longopts, int *longind);
+extern int getopt_long_only (int argc, char *const *argv,
+ const char *shortopts,
+ const struct option *longopts, int *longind);
+
+/* Internal only. Users should not call this directly. */
+extern int _getopt_internal (int argc, char *const *argv,
+ const char *shortopts,
+ const struct option *longopts, int *longind,
+ int long_only);
+#else /* not __STDC__ */
+extern int getopt ();
+extern int getopt_long ();
+extern int getopt_long_only ();
+
+extern int _getopt_internal ();
+#endif /* __STDC__ */
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* getopt.h */
diff --git a/contrib/binutils/include/hashtab.h b/contrib/binutils/include/hashtab.h
index be866b5..f7bd4ae 100644
--- a/contrib/binutils/include/hashtab.h
+++ b/contrib/binutils/include/hashtab.h
@@ -1,5 +1,5 @@
/* An expandable hash tables datatype.
- Copyright (C) 1999, 2000, 2002 Free Software Foundation, Inc.
+ Copyright (C) 1999, 2000, 2002, 2003 Free Software Foundation, Inc.
Contributed by Vladimir Makarov (vmakarov@cygnus.com).
This program is free software; you can redistribute it and/or modify
@@ -76,10 +76,16 @@ typedef PTR (*htab_alloc) PARAMS ((size_t, size_t));
/* We also need a free() routine. */
typedef void (*htab_free) PARAMS ((PTR));
+/* Memory allocation and deallocation; variants which take an extra
+ argument. */
+typedef PTR (*htab_alloc_with_arg) PARAMS ((void *, size_t, size_t));
+typedef void (*htab_free_with_arg) PARAMS ((void *, void *));
+
/* Hash tables are of the following type. The structure
(implementation) of this type is not needed for using the hash
tables. All work with hash table should be executed only through
- functions mentioned below. */
+ functions mentioned below. The size of this structure is subject to
+ change. */
struct htab GTY(())
{
@@ -115,6 +121,11 @@ struct htab GTY(())
/* Pointers to allocate/free functions. */
htab_alloc alloc_f;
htab_free free_f;
+
+ /* Alternate allocate/free functions, which take an extra argument. */
+ PTR GTY((skip (""))) alloc_arg;
+ htab_alloc_with_arg alloc_with_arg_f;
+ htab_free_with_arg free_with_arg_f;
};
typedef struct htab *htab_t;
@@ -128,10 +139,20 @@ extern htab_t htab_create_alloc PARAMS ((size_t, htab_hash,
htab_eq, htab_del,
htab_alloc, htab_free));
+extern htab_t htab_create_alloc_ex PARAMS ((size_t, htab_hash,
+ htab_eq, htab_del,
+ PTR, htab_alloc_with_arg,
+ htab_free_with_arg));
+
/* Backward-compatibility functions. */
extern htab_t htab_create PARAMS ((size_t, htab_hash, htab_eq, htab_del));
extern htab_t htab_try_create PARAMS ((size_t, htab_hash, htab_eq, htab_del));
+extern void htab_set_functions_ex PARAMS ((htab_t, htab_hash,
+ htab_eq, htab_del,
+ PTR, htab_alloc_with_arg,
+ htab_free_with_arg));
+
extern void htab_delete PARAMS ((htab_t));
extern void htab_empty PARAMS ((htab_t));
@@ -147,6 +168,7 @@ extern void htab_clear_slot PARAMS ((htab_t, void **));
extern void htab_remove_elt PARAMS ((htab_t, void *));
extern void htab_traverse PARAMS ((htab_t, htab_trav, void *));
+extern void htab_traverse_noresize PARAMS ((htab_t, htab_trav, void *));
extern size_t htab_size PARAMS ((htab_t));
extern size_t htab_elements PARAMS ((htab_t));
@@ -161,6 +183,11 @@ extern htab_eq htab_eq_pointer;
/* A hash function for null-terminated strings. */
extern hashval_t htab_hash_string PARAMS ((const PTR));
+/* An iterative hash function for arbitrary data. */
+extern hashval_t iterative_hash PARAMS ((const PTR, size_t, hashval_t));
+/* Shorthand for hashing something with an intrinsic size. */
+#define iterative_hash_object(OB,INIT) iterative_hash (&OB, sizeof (OB), INIT)
+
#ifdef __cplusplus
}
#endif /* __cplusplus */
diff --git a/contrib/binutils/include/libiberty.h b/contrib/binutils/include/libiberty.h
index 0463301..761b2cf 100644
--- a/contrib/binutils/include/libiberty.h
+++ b/contrib/binutils/include/libiberty.h
@@ -74,7 +74,7 @@ extern char **dupargv PARAMS ((char **)) ATTRIBUTE_MALLOC;
to find the declaration so provide a fully prototyped one. If it
is 1, we found it so don't provide any declaration at all. */
#if !HAVE_DECL_BASENAME
-#if defined (__GNU_LIBRARY__ ) || defined (__linux__) || defined (__FreeBSD__) || defined (__OpenBSD__) || defined (__CYGWIN__) || defined (__CYGWIN32__) || defined (HAVE_DECL_BASENAME)
+#if defined (__GNU_LIBRARY__ ) || defined (__linux__) || defined (__FreeBSD__) || defined (__OpenBSD__) || defined(__NetBSD__) || defined (__CYGWIN__) || defined (__CYGWIN32__) || defined (HAVE_DECL_BASENAME)
extern char *basename PARAMS ((const char *));
#else
extern char *basename ();
@@ -85,6 +85,10 @@ extern char *basename ();
extern const char *lbasename PARAMS ((const char *));
+/* A well-defined realpath () that is always compiled in. */
+
+extern char *lrealpath PARAMS ((const char *));
+
/* Concatenate an arbitrary number of strings. You must pass NULL as
the last argument of this function, to terminate the list of
strings. Allocates memory using xmalloc. */
@@ -145,6 +149,12 @@ extern char * getpwd PARAMS ((void));
extern long get_run_time PARAMS ((void));
+/* Generate a relocated path to some installation directory. Allocates
+ return value using malloc. */
+
+extern char *make_relative_prefix PARAMS ((const char *, const char *,
+ const char *));
+
/* Choose a temporary directory to use for scratch files. */
extern char *choose_temp_base PARAMS ((void)) ATTRIBUTE_MALLOC;
@@ -236,16 +246,20 @@ extern char *xstrdup PARAMS ((const char *)) ATTRIBUTE_MALLOC;
extern PTR xmemdup PARAMS ((const PTR, size_t, size_t)) ATTRIBUTE_MALLOC;
+/* Physical memory routines. Return values are in BYTES. */
+extern double physmem_total PARAMS ((void));
+extern double physmem_available PARAMS ((void));
+
/* hex character manipulation routines */
#define _hex_array_size 256
#define _hex_bad 99
-extern const char _hex_value[_hex_array_size];
+extern const unsigned char _hex_value[_hex_array_size];
extern void hex_init PARAMS ((void));
#define hex_p(c) (hex_value (c) != _hex_bad)
/* If you change this, note well: Some code relies on side effects in
the argument being performed exactly once. */
-#define hex_value(c) (_hex_value[(unsigned char) (c)])
+#define hex_value(c) ((unsigned int) _hex_value[(unsigned char) (c)])
/* Definitions used by the pexecute routine. */
@@ -264,16 +278,20 @@ extern int pexecute PARAMS ((const char *, char * const *, const char *,
extern int pwait PARAMS ((int, int *, int));
+#if !HAVE_DECL_ASPRINTF
/* Like sprintf but provides a pointer to malloc'd storage, which must
be freed by the caller. */
extern int asprintf PARAMS ((char **, const char *, ...)) ATTRIBUTE_PRINTF_2;
+#endif
+#if !HAVE_DECL_VASPRINTF
/* Like vsprintf but provides a pointer to malloc'd storage, which
must be freed by the caller. */
extern int vasprintf PARAMS ((char **, const char *, va_list))
ATTRIBUTE_PRINTF(2,0);
+#endif
#define ARRAY_SIZE(a) (sizeof (a) / sizeof ((a)[0]))
diff --git a/contrib/binutils/include/obstack.h b/contrib/binutils/include/obstack.h
index d86d9f2..5496ff2 100644
--- a/contrib/binutils/include/obstack.h
+++ b/contrib/binutils/include/obstack.h
@@ -343,7 +343,7 @@ extern int obstack_exit_failure;
#endif
-#define obstack_1grow_fast(h,achar) (*((h)->next_free)++ = achar)
+#define obstack_1grow_fast(h,achar) (*((h)->next_free)++ = (achar))
#define obstack_blank_fast(h,n) ((h)->next_free += (n))
@@ -411,7 +411,7 @@ __extension__ \
({ struct obstack *__o = (OBSTACK); \
if (__o->next_free + 1 > __o->chunk_limit) \
_obstack_newchunk (__o, 1); \
- *(__o->next_free)++ = (datum); \
+ obstack_1grow_fast (__o, datum); \
(void) 0; })
/* These assume that the obstack alignment is good enough for pointers or ints,
@@ -423,19 +423,28 @@ __extension__ \
({ struct obstack *__o = (OBSTACK); \
if (__o->next_free + sizeof (void *) > __o->chunk_limit) \
_obstack_newchunk (__o, sizeof (void *)); \
- *((void **)__o->next_free)++ = ((void *)datum); \
- (void) 0; })
+ obstack_ptr_grow_fast (__o, datum); })
# define obstack_int_grow(OBSTACK,datum) \
__extension__ \
({ struct obstack *__o = (OBSTACK); \
if (__o->next_free + sizeof (int) > __o->chunk_limit) \
_obstack_newchunk (__o, sizeof (int)); \
- *((int *)__o->next_free)++ = ((int)datum); \
+ obstack_int_grow_fast (__o, datum); })
+
+# define obstack_ptr_grow_fast(OBSTACK,aptr) \
+__extension__ \
+({ struct obstack *__o1 = (OBSTACK); \
+ *(const void **) __o1->next_free = (aptr); \
+ __o1->next_free += sizeof (const void *); \
(void) 0; })
-# define obstack_ptr_grow_fast(h,aptr) (*((void **) (h)->next_free)++ = (void *)aptr)
-# define obstack_int_grow_fast(h,aint) (*((int *) (h)->next_free)++ = (int) aint)
+# define obstack_int_grow_fast(OBSTACK,aint) \
+__extension__ \
+({ struct obstack *__o1 = (OBSTACK); \
+ *(int *) __o1->next_free = (aint); \
+ __o1->next_free += sizeof (int); \
+ (void) 0; })
# define obstack_blank(OBSTACK,length) \
__extension__ \
@@ -443,7 +452,7 @@ __extension__ \
int __len = (length); \
if (__o->chunk_limit - __o->next_free < __len) \
_obstack_newchunk (__o, __len); \
- __o->next_free += __len; \
+ obstack_blank_fast (__o, __len); \
(void) 0; })
# define obstack_alloc(OBSTACK,length) \
@@ -530,26 +539,29 @@ __extension__ \
# define obstack_1grow(h,datum) \
( (((h)->next_free + 1 > (h)->chunk_limit) \
? (_obstack_newchunk ((h), 1), 0) : 0), \
- (*((h)->next_free)++ = (datum)))
+ obstack_1grow_fast (h, datum))
# define obstack_ptr_grow(h,datum) \
( (((h)->next_free + sizeof (char *) > (h)->chunk_limit) \
? (_obstack_newchunk ((h), sizeof (char *)), 0) : 0), \
- (*((char **) (((h)->next_free+=sizeof(char *))-sizeof(char *))) = ((char *) datum)))
+ obstack_ptr_grow_fast (h, datum))
# define obstack_int_grow(h,datum) \
( (((h)->next_free + sizeof (int) > (h)->chunk_limit) \
? (_obstack_newchunk ((h), sizeof (int)), 0) : 0), \
- (*((int *) (((h)->next_free+=sizeof(int))-sizeof(int))) = ((int) datum)))
+ obstack_int_grow_fast (h, datum))
+
+# define obstack_ptr_grow_fast(h,aptr) \
+ (((const void **) ((h)->next_free += sizeof (void *)))[-1] = (aptr))
-# define obstack_ptr_grow_fast(h,aptr) (*((char **) (h)->next_free)++ = (char *) aptr)
-# define obstack_int_grow_fast(h,aint) (*((int *) (h)->next_free)++ = (int) aint)
+# define obstack_int_grow_fast(h,aint) \
+ (((int *) ((h)->next_free += sizeof (int)))[-1] = (aptr))
# define obstack_blank(h,length) \
( (h)->temp = (length), \
(((h)->chunk_limit - (h)->next_free < (h)->temp) \
? (_obstack_newchunk ((h), (h)->temp), 0) : 0), \
- ((h)->next_free += (h)->temp))
+ obstack_blank_fast (h, (h)->temp))
# define obstack_alloc(h,length) \
(obstack_blank ((h), (length)), obstack_finish ((h)))
diff --git a/contrib/binutils/include/opcode/ChangeLog b/contrib/binutils/include/opcode/ChangeLog
index 385b191..6c50775 100644
--- a/contrib/binutils/include/opcode/ChangeLog
+++ b/contrib/binutils/include/opcode/ChangeLog
@@ -1,2773 +1,39 @@
-2002-07-09 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+2004-04-08 Alan Modra <amodra@bigpond.net.au>
- * mips.h (INSN_MIPS16): New define.
+ Apply from mainline.
+ 2004-03-12 Jakub Jelinek <jakub@redhat.com>
+ * i386.h (i386_optab): Remove CpuNo64 from sysenter and sysexit.
-2002-07-08 Alan Modra <amodra@bigpond.net.au>
+2004-03-16 Alan Modra <amodra@bigpond.net.au>
- * i386.h: Remove IgnoreSize from movsx and movzx.
+ * ppc.h (PPC_OPERAND_GPR_0): Define. Bump other operand defines.
-2002-06-08 Alan Modra <amodra@bigpond.net.au>
+2004-03-12 Michal Ludvig <mludvig@suse.cz>
- * a29k.h: Replace CONST with const.
- (CONST): Don't define.
- * convex.h: Replace CONST with const.
- (CONST): Don't define.
- * dlx.h: Replace CONST with const.
- * or32.h (CONST): Don't define.
+ * i386.h (i386_optab): Added xstore as an alias for xstorerng.
-2002-05-30 Chris G. Demetriou <cgd@broadcom.com>
+2004-03-12 Michal Ludvig <mludvig@suse.cz>
- * mips.h (OP_SH_ALN, OP_MASK_ALN, OP_SH_VSEL, OP_MASK_VSEL)
- (MDMX_FMTSEL_IMM_QH, MDMX_FMTSEL_IMM_OB, MDMX_FMTSEL_VEC_QH)
- (MDMX_FMTSEL_VEC_OB, INSN_READ_MDMX_ACC, INSN_WRITE_MDMX_ACC)
- (INSN_MDMX): New constants, for MDMX support.
- (opcode character list): Add "O", "Q", "X", "Y", and "Z" for MDMX.
+ * i386.h (i386_optab): Added xstore/xcrypt insns.
-2002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
+2004-02-09 Anil Paranjpe <anilp1@KPITCummins.com>
- * dlx.h: New file.
+ * h8300.h (32bit ldc/stc): Add relaxing support.
-2002-05-25 Alan Modra <amodra@bigpond.net.au>
+2004-01-12 Anil Paranjpe <anilp1@KPITCummins.com>
- * ia64.h: Use #include "" instead of <> for local header files.
- * sparc.h: Likewise.
+ * h8300.h (BITOP): Pass MEMRELAX flag.
-2002-05-22 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+2004-01-09 Anil Paranjpe <anilp1@KPITCummins.com>
- * mips.h: Add M_DROL, M_DROL_I, M_DROR, M_DROR_I macro cases.
-
-2002-05-17 Andrey Volkov <avolkov@sources.redhat.com>
-
- * h8300.h: Corrected defs of all control regs
- and eepmov instr.
-
-2002-04-11 Alan Modra <amodra@bigpond.net.au>
-
- * i386.h: Add intel mode cmpsd and movsd.
- Put them before SSE2 insns, so that rep prefix works.
-
-2002-03-15 Chris G. Demetriou <cgd@broadcom.com>
-
- * mips.h (INSN_MIPS3D): New definition used to mark MIPS-3D
- instructions.
- (OPCODE_IS_MEMBER): Adjust comments to indicate that ASE bit masks
- may be passed along with the ISA bitmask.
-
-2002-03-05 Paul Koning <pkoning@equallogic.com>
-
- * pdp11.h: Add format codes for float instruction formats.
-
-2002-02-25 Alan Modra <amodra@bigpond.net.au>
-
- * ppc.h (PPC_OPCODE_POWER4, PPC_OPCODE_NOPOWER4): Define.
-
-Mon Feb 18 17:31:48 CET 2002 Jan Hubicka <jh@suse.cz>
-
- * i386.h (push,pop): Fix Reg64 to WordReg to allow 16bit operands.
-
-Mon Feb 11 12:53:19 CET 2002 Jan Hubicka <jh@suse.cz>
-
- * i386.h (push,pop): Allow 16bit operands in 64bit mode.
- (xchg): Fix.
- (in, out): Disable 64bit operands.
- (call, jmp): Avoid REX prefixes.
- (jcxz): Prohibit in 64bit mode
- (jrcxz, loop): Add 64bit variants.
- (movq): Fix patterns.
- (movmskps, pextrw, pinstrw): Add 64bit variants.
-
-2002-01-31 Ivan Guzvinec <ivang@opencores.org>
-
- * or32.h: New file.
-
-2002-01-22 Graydon Hoare <graydon@redhat.com>
-
- * cgen.h (CGEN_MAYBE_MULTI_IFLD): New structure.
- (CGEN_OPERAND): Add CGEN_MAYBE_MULTI_IFLD field.
-
-2002-01-21 Thomas Klausner <wiz@danbala.ifoer.tuwien.ac.at>
-
- * h8300.h: Comment typo fix.
-
-2002-01-03 matthew green <mrg@redhat.com>
-
- * ppc.h (PPC_OPCODE_BOOKE): BookE is not Motorola specific.
- (PPC_OPCODE_BOOKE64): Likewise.
-
-Mon Dec 31 16:45:41 2001 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h (call, ret): Move to end of table.
- (addb, addib): PA2.0 variants should have been PA2.0W.
- (ldw, ldh, ldb, stw, sth, stb, stwa): Reorder to keep disassembler
- happy.
- (fldw, fldd, fstw, fstd, bb): Likewise.
- (short loads/stores): Tweak format specifier slightly to keep
- disassembler happy.
- (indexed loads/stores): Likewise.
- (absolute loads/stores): Likewise.
-
-2001-12-04 Alexandre Oliva <aoliva@redhat.com>
-
- * d10v.h (OPERAND_NOSP): New macro.
-
-2001-11-29 Alexandre Oliva <aoliva@redhat.com>
-
- * d10v.h (OPERAND_SP): New macro.
-
-2001-11-15 Alan Modra <amodra@bigpond.net.au>
-
- * ppc.h (struct powerpc_operand <insert, extract>): Add dialect param.
-
-2001-11-11 Timothy Wall <twall@alum.mit.edu>
-
- * tic54x.h: Revise opcode layout; don't really need a separate
- structure for parallel opcodes.
-
-2001-11-13 Zack Weinberg <zack@codesourcery.com>
- Alan Modra <amodra@bigpond.net.au>
-
- * i386.h (i386_optab): Add entries for "sldr", "smsw" and "str" to
- accept WordReg.
-
-2001-11-04 Chris Demetriou <cgd@broadcom.com>
-
- * mips.h (OPCODE_IS_MEMBER): Remove extra space.
-
-2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
-
- * mmix.h: New file.
-
-2001-10-18 Chris Demetriou <cgd@broadcom.com>
-
- * mips.h (OPCODE_IS_MEMBER): Add a no-op term to the end
- of the expression, to make source code merging easier.
-
-2001-10-17 Chris Demetriou <cgd@broadcom.com>
-
- * mips.h: Sort coprocessor instruction argument characters
- in comment, add a few more words of description for "H".
-
-2001-10-17 Chris Demetriou <cgd@broadcom.com>
-
- * mips.h (INSN_SB1): New cpu-specific instruction bit.
- (OPCODE_IS_MEMBER): Allow instructions matching INSN_SB1
- if cpu is CPU_SB1.
-
-2001-10-17 matthew green <mrg@redhat.com>
-
- * ppc.h (PPC_OPCODE_BOOKE64): Fix typo.
-
-2001-10-12 matthew green <mrg@redhat.com>
-
- * ppc.h (PPC_OPCODE_BOOKE, PPC_OPCODE_BOOKE64, PPC_OPCODE_403): New
- opcode flags for BookE 32-bit, BookE 64-bit and PowerPC 403
- instructions, respectively.
-
-2001-09-27 Nick Clifton <nickc@cambridge.redhat.com>
-
- * v850.h: Remove spurious comment.
-
-2001-09-21 Nick Clifton <nickc@cambridge.redhat.com>
-
- * h8300.h: Fix compile time warning messages
-
-2001-09-04 Richard Henderson <rth@redhat.com>
-
- * alpha.h (struct alpha_operand): Pack elements into bitfields.
-
-2001-08-31 Eric Christopher <echristo@redhat.com>
-
- * mips.h: Remove CPU_MIPS32_4K.
-
-2001-08-27 Torbjorn Granlund <tege@swox.com>
-
- * ppc.h (PPC_OPERAND_DS): Define.
-
-2001-08-25 Andreas Jaeger <aj@suse.de>
-
- * d30v.h: Fix declaration of reg_name_cnt.
-
- * d10v.h: Fix declaration of d10v_reg_name_cnt.
-
- * arc.h: Add prototypes from opcodes/arc-opc.c.
-
-2001-08-16 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * mips.h (INSN_10000): Define.
- (OPCODE_IS_MEMBER): Check for INSN_10000.
-
-2001-08-10 Alan Modra <amodra@one.net.au>
-
- * ppc.h: Revert 2001-08-08.
-
-2001-08-10 Richard Sandiford <rsandifo@redhat.com>
-
- * mips.h (INSN_GP32): Remove.
- (OPCODE_IS_MEMBER): Remove gp32 parameter.
- (M_MOVE): New macro identifier.
-
-2001-08-08 Alan Modra <amodra@one.net.au>
-
- 1999-10-25 Torbjorn Granlund <tege@swox.com>
- * ppc.h (struct powerpc_operand): New field `reloc'.
-
-2001-08-01 Aldy Hernandez <aldyh@redhat.com>
-
- * mips.h (INSN_ISA_MASK): Nuke bits 12-15.
-
-2001-07-12 Jeff Johnston <jjohnstn@redhat.com>
-
- * cgen.h (CGEN_INSN): Add regex support.
- (build_insn_regex): Declare.
-
-2001-07-11 Frank Ch. Eigler <fche@redhat.com>
-
- * cgen.h (CGEN_MACH): Add insn_chunk_bitsize field.
- (cgen_cpu_desc): Ditto.
-
-2001-07-07 Ben Elliston <bje@redhat.com>
-
- * m88k.h: Clean up and reformat. Remove unused code.
-
-2001-06-14 Geoffrey Keating <geoffk@redhat.com>
-
- * cgen.h (cgen_keyword): Add nonalpha_chars field.
-
-2001-05-23 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * mips.h (CPU_R12000): Define.
-
-2001-05-23 John Healy <jhealy@redhat.com>
-
- * cgen.h: Increased CGEN_MAX_SYNTAX_ELEMENTS to 48.
-
-2001-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * mips.h (INSN_ISA_MASK): Define.
-
-2001-05-12 Alan Modra <amodra@one.net.au>
-
- * i386.h (i386_optab): Second operand of cvtps2dq is an xmm reg,
- not an mmx reg. Swap xmm/mmx regs on both movdq2q and movq2dq,
- and use InvMem as these insns must have register operands.
-
-2001-05-04 Alan Modra <amodra@one.net.au>
-
- * i386.h (i386_optab): Move InvMem to first operand of pmovmskb
- and pextrw to swap reg/rm assignments.
-
-2001-04-05 Hans-Peter Nilsson <hp@axis.com>
-
- * cris.h (enum cris_insn_version_usage): Correct comment for
- cris_ver_v3p.
-
-2001-03-24 Alan Modra <alan@linuxcare.com.au>
-
- * i386.h (i386_optab): Correct entry for "movntdq". Add "punpcklqdq".
- Add InvMem to first operand of "maskmovdqu".
-
-2001-03-22 Hans-Peter Nilsson <hp@axis.com>
-
- * cris.h (ADD_PC_INCR_OPCODE): New macro.
-
-2001-03-21 Kazu Hirata <kazu@hxi.com>
-
- * h8300.h: Fix formatting.
-
-2001-03-22 Alan Modra <alan@linuxcare.com.au>
-
- * i386.h (i386_optab): Add paddq, psubq.
-
-2001-03-19 Alan Modra <alan@linuxcare.com.au>
-
- * i386.h (REGNAM_AL, REGNAM_AX, REGNAM_EAX): Define.
-
-2001-02-28 Igor Shevlyakov <igor@windriver.com>
-
- * m68k.h: new defines for Coldfire V4. Update mcf to know
- about mcf5407.
-
-2001-02-18 lars brinkhoff <lars@nocrew.org>
-
- * pdp11.h: New file.
-
-2001-02-12 Jan Hubicka <jh@suse.cz>
-
- * i386.h (i386_optab): SSE integer converison instructions have
- 64bit versions on x86-64.
-
-2001-02-10 Nick Clifton <nickc@redhat.com>
-
- * mips.h: Remove extraneous whitespace. Formating change to allow
- for future contribution.
-
-2001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * s390.h: New file.
-
-2001-02-02 Patrick Macdonald <patrickm@redhat.com>
-
- * cgen.h (CGEN_SYNTAX_CHAR_TYPE): Typedef as unsigned short.
- (CGEN_MAX_SYNTAX_ELEMENTS): Rename from CGEN_MAX_SYNTAX_BYTES.
- (CGEN_SYNTAX): Define using CGEN_MAX_SYNTAX_ELEMENTS.
-
-2001-01-24 Karsten Keil <kkeil@suse.de>
-
- * i386.h (i386_optab): Fix swapgs
-
-2001-01-14 Alan Modra <alan@linuxcare.com.au>
-
- * hppa.h: Describe new '<' and '>' operand types, and tidy
- existing comments.
- (pa_opcodes): Add entries for missing wide mode ldi,ldo,ldw,stw.
- Remove duplicate "ldw j(s,b),x". Sort some entries.
-
-2001-01-13 Jan Hubicka <jh@suse.cz>
-
- * i386.h (i386_optab): Fix pusha and ret templates.
-
-2001-01-11 Peter Targett <peter.targett@arccores.com>
-
- * arc.h (ARC_MACH_5, ARC_MACH_6, ARC_MACH_7, ARC_MACH_8): New
- definitions for masking cpu type.
- (arc_ext_operand_value) New structure for storing extended
- operands.
- (ARC_OPERAND_*) Flags for operand values.
-
-2001-01-10 Jan Hubicka <jh@suse.cz>
-
- * i386.h (pinsrw): Add.
- (pshufw): Remove.
- (cvttpd2dq): Fix operands.
- (cvttps2dq): Likewise.
- (movq2q): Rename to movdq2q.
-
-2001-01-10 Richard Schaal <richard.schaal@intel.com>
-
- * i386.h: Correct movnti instruction.
-
-2001-01-09 Jeff Johnston <jjohnstn@redhat.com>
-
- * cgen.h (CGEN_SYNTAX_CHAR_TYPE): New typedef based on max number
- of operands (unsigned char or unsigned short).
- (CGEN_SYNTAX): Changed to make array CGEN_SYNTAX_CHAR_TYPE.
- (CGEN_SYNTAX_CHAR): Changed to cast to unsigned char.
-
-2001-01-05 Jan Hubicka <jh@suse.cz>
-
- * i386.h (i386_optab): Make [sml]fence template to use immext field.
-
-2001-01-03 Jan Hubicka <jh@suse.cz>
-
- * i386.h (i386_optab): Fix 64bit pushf template; Add instructions
- introduced by Pentium4
-
-2000-12-30 Jan Hubicka <jh@suse.cz>
-
- * i386.h (i386_optab): Add "rex*" instructions;
- add swapgs; disable jmp/call far direct instructions for
- 64bit mode; add syscall and sysret; disable registers for 0xc6
- template. Add 'q' suffixes to extendable instructions, disable
- obsolete instructions, add new sign/zero extension ones.
- (i386_regtab): Add extended registers.
- (*Suf): Add No_qSuf.
- (q_Suf, wlq_Suf, bwlq_Suf): New.
-
-2000-12-20 Jan Hubicka <jh@suse.cz>
-
- * i386.h (i386_optab): Replace "Imm" with "EncImm".
- (i386_regtab): Add flags field.
-
-2000-12-12 Nick Clifton <nickc@redhat.com>
-
- * mips.h: Fix formatting.
-
-2000-12-01 Chris Demetriou <cgd@sibyte.com>
-
- mips.h (OP_MASK_SYSCALL, OP_SH_SYSCALL): Delete.
- (OP_MASK_CODE20, OP_SH_CODE20): Define, with values of old
- OP_*_SYSCALL definitions.
- (OP_SH_CODE19, OP_MASK_CODE19): Define, for use as
- 19 bit wait codes.
- (MIPS operand specifier comments): Remove 'm', add 'U' and
- 'J', and update the meaning of 'B' so that it's more general.
-
- * mips.h (INSN_ISA1, INSN_ISA2, INSN_ISA3, INSN_ISA4,
- INSN_ISA5): Renumber, redefine to mean the ISA at which the
- instruction was added.
- (INSN_ISA32): New constant.
- (INSN_4650, INSN_4010, INSN_4100, INSN_3900, INSN_GP32):
- Renumber to avoid new and/or renumbered INSN_* constants.
- (INSN_MIPS32): Delete.
- (ISA_UNKNOWN): New constant to indicate unknown ISA.
- (ISA_MIPS1, ISA_MIPS2, ISA_MIPS3, ISA_MIPS4, ISA_MIPS5,
- ISA_MIPS32): New constants, defined to be the mask of INSN_*
- constants available at that ISA level.
- (CPU_UNKNOWN): New constant to indicate unknown CPU.
- (CPU_4K, CPU_MIPS32_4K): Rename the former to the latter,
- define it with a unique value.
- (OPCODE_IS_MEMBER): Update for new ISA membership-related
- constant meanings.
-
- * mips.h (INSN_ISA64, ISA_MIPS5, ISA_MIPS64): New
- definitions.
-
- * mips.h (CPU_SB1): New constant.
-
-2000-10-20 Jakub Jelinek <jakub@redhat.com>
-
- * sparc.h (enum sparc_opcode_arch_val): Add SPARC_OPCODE_ARCH_V9B.
- Note that '3' is used for siam operand.
-
-2000-09-22 Jim Wilson <wilson@cygnus.com>
-
- * ia64.h (enum ia64_dependency_semantics): Add IA64_DVS_STOP.
-
-2000-09-13 Anders Norlander <anorland@acc.umu.se>
-
- * mips.h: Use defines instead of hard-coded processor numbers.
- (CPU_R2000, CPU_R3000, CPU_R3900, CPU_R4000, CPU_R4010,
- CPU_VR4100, CPU_R4111, CPU_R4300, CPU_R4400, CPU_R4600, CPU_R4650,
- CPU_R5000, CPU_R6000, CPU_R8000, CPU_R10000, CPU_MIPS32, CPU_4K,
- CPU_4KC, CPU_4KM, CPU_4KP): Define..
- (OPCODE_IS_MEMBER): Use new defines.
- (OP_MASK_SEL, OP_SH_SEL): Define.
- (OP_MASK_CODE20, OP_SH_CODE20): Define.
- Add 'P' to used characters.
- Use 'H' for coprocessor select field.
- Use 'm' for 20 bit breakpoint code.
- Document new arg characters and add to used characters.
- (INSN_MIPS32): New define for MIPS32 extensions.
- (OPCODE_IS_MEMBER): Recognize MIPS32 instructions.
-
-2000-09-05 Alan Modra <alan@linuxcare.com.au>
-
- * hppa.h: Mention cz completer.
-
-2000-08-16 Jim Wilson <wilson@cygnus.com>
-
- * ia64.h (IA64_OPCODE_POSTINC): New.
-
-2000-08-15 H.J. Lu <hjl@gnu.org>
-
- * i386.h: Swap the Intel syntax "movsx"/"movzx" due to the
- IgnoreSize change.
-
-2000-08-08 Jason Eckhardt <jle@cygnus.com>
-
- * i860.h: Small formatting adjustments.
-
-2000-07-29 Marek Michalkiewicz <marekm@linux.org.pl>
-
- * avr.h (AVR_UNDEF_P, AVR_SKIP_P, AVR_DISP0_P): New macros.
- Move related opcodes closer to each other.
- Minor changes in comments, list undefined opcodes.
-
-2000-07-26 Dave Brolley <brolley@redhat.com>
-
- * cgen.h (cgen_hw_lookup_by_num): Second parameter is unsigned.
-
-2000-07-22 Jason Eckhardt <jle@cygnus.com>
-
- * i860.h (btne, bte, bla): Changed these opcodes
- to use sbroff ('r') instead of split16 ('s').
- (J, K, L, M): New operand types for 16-bit aligned fields.
- (ld.x, {p}fld.x, fst.x, pst.d): Changed these opcodes to
- use I, J, K, L, M instead of just I.
- (T, U): New operand types for split 16-bit aligned fields.
- (st.x): Changed these opcodes to use S, T, U instead of just S.
- (andh, andnoth, orh, xorh): Deleted 3-register forms as they do not
- exist on the i860.
- (pfgt.sd, pfle.sd): Deleted these as they do not exist on the i860.
- (pfeq.ss, pfeq.dd): New opcodes.
- (st.s): Fixed incorrect mask bits.
- (fmlow): Fixed incorrect mask bits.
- (fzchkl, pfzchkl): Fixed incorrect mask bits.
- (faddz, pfaddz): Fixed incorrect mask bits.
- (form, pform): Fixed incorrect mask bits.
- (pfld.l): Fixed incorrect mask bits.
- (fst.q): Fixed incorrect mask bits.
- (all floating point opcodes): Fixed incorrect mask bits for
- handling of dual bit.
-
-2000-07-20 Hans-Peter Nilsson <hp@axis.com>
-
- cris.h: New file.
-
-2000-06-26 Marek Michalkiewicz <marekm@linux.org.pl>
-
- * avr.h (AVR_ISA_WRAP): Remove, now assumed if not AVR_ISA_MEGA.
- (AVR_ISA_ESPM): Remove, because ESPM removed in databook update.
- (AVR_ISA_85xx): Remove, all uses changed back to AVR_ISA_2xxx.
- (AVR_ISA_M83): Define for ATmega83, ATmega85.
- (espm): Remove, because ESPM removed in databook update.
- (eicall, eijmp): Move to the end of opcode table.
-
-2000-06-18 Stephane Carrez <stcarrez@worldnet.fr>
-
- * m68hc11.h: New file for support of Motorola 68hc11.
-
-Fri Jun 9 21:51:50 2000 Denis Chertykov <denisc@overta.ru>
-
- * avr.h: clr,lsl,rol, ... moved after add,adc, ...
-
-Wed Jun 7 21:39:54 2000 Denis Chertykov <denisc@overta.ru>
-
- * avr.h: New file with AVR opcodes.
-
-Wed Apr 12 17:11:20 2000 Donald Lindsay <dlindsay@hound.cygnus.com>
-
- * d10v.h: added ALONE attribute for d10v_opcode.exec_type.
-
-2000-05-23 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
-
- * i386.h: Allow d suffix on iret, and add DefaultSize modifier.
-
-2000-05-17 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
-
- * i386.h: Use sl_FP, not sl_Suf for fild.
-
-2000-05-16 Frank Ch. Eigler <fche@redhat.com>
-
- * cgen.h (CGEN_MAX_SYNTAX_BYTES): Increase to 32. Check that
- it exceeds CGEN_ACTUAL_MAX_SYNTAX_BYTES, if set.
- (CGEN_MAX_IFMT_OPERANDS): Increase to 16. Check that it exceeds
- CGEN_ACTUAL_MAX_IFMT_OPERANDS, if set.
-
-2000-05-13 Alan Modra <alan@linuxcare.com.au>,
-
- * i386.h (i386_optab): Cpu686 for sysenter,sysexit,fxsave,fxrestore.
-
-2000-05-13 Alan Modra <alan@linuxcare.com.au>,
- Alexander Sokolov <robocop@netlink.ru>
-
- * i386.h (i386_optab): Add cpu_flags for all instructions.
-
-2000-05-13 Alan Modra <alan@linuxcare.com.au>
-
- From Gavin Romig-Koch <gavin@cygnus.com>
- * i386.h (wld_Suf): Define. Use on pushf, popf, pusha, popa.
-
-2000-05-04 Timothy Wall <twall@cygnus.com>
-
- * tic54x.h: New.
-
-2000-05-03 J.T. Conklin <jtc@redback.com>
-
- * ppc.h (PPC_OPCODE_ALTIVEC): New opcode flag for vector unit.
- (PPC_OPERAND_VR): New operand flag for vector registers.
-
-2000-05-01 Kazu Hirata <kazu@hxi.com>
-
- * h8300.h (EOP): Add missing initializer.
-
-Fri Apr 21 15:03:37 2000 Jason Eckhardt <jle@cygnus.com>
-
- * hppa.h (pa_opcodes): New opcodes for PA2.0 wide mode
- forms of ld/st{b,h,w,d} and fld/fst{w,d} (16-bit displacements).
- New operand types l,y,&,fe,fE,fx added to support above forms.
- (pa_opcodes): Replaced usage of 'x' as source/target for
- floating point double-word loads/stores with 'fx'.
-
-Fri Apr 21 13:20:53 2000 Richard Henderson <rth@cygnus.com>
- David Mosberger <davidm@hpl.hp.com>
- Timothy Wall <twall@cygnus.com>
- Jim Wilson <wilson@cygnus.com>
-
- * ia64.h: New file.
-
-2000-03-27 Nick Clifton <nickc@cygnus.com>
-
- * d30v.h (SHORT_A1): Fix value.
- (SHORT_AR): Renumber so that it is at the end of the list of short
- instructions, not the end of the list of long instructions.
-
-2000-03-26 Alan Modra <alan@linuxcare.com>
-
- * i386.h: (UNIXWARE_COMPAT): Rename to SYSV386_COMPAT as the
- problem isn't really specific to Unixware.
- (OLDGCC_COMPAT): Define.
- (i386_optab): If !OLDGCC_COMPAT, don't handle fsubp etc. with
- destination %st(0).
- Fix lots of comments.
-
-2000-03-02 J"orn Rennecke <amylaar@cygnus.co.uk>
-
- * d30v.h:
- (SHORT_B2r, SHORT_B3, SHORT_B3r, SHORT_B3b, SHORT_B3br): Updated.
- (SHORT_D1r, SHORT_D2, SHORT_D2r, SHORT_D2Br, SHORT_U): Updated.
- (SHORT_F, SHORT_AF, SHORT_T, SHORT_A5, SHORT_CMP, SHORT_CMPU): Updated.
- (SHORT_A1, SHORT_AA, SHORT_RA, SHORT_MODINC, SHORT_MODDEC): Updated.
- (SHORT_C1, SHORT_C2, SHORT_UF, SHORT_A2, SHORT_NONE, LONG): Updated.
- (LONG_U, LONG_Ur, LONG_CMP, LONG_M, LONG_M2, LONG_2, LONG_2r): Updated.
- (LONG_2b, LONG_2br, LONG_D, LONG_Dr, LONG_Dbr): Updated.
-
-2000-02-25 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h (fild, fistp): Change intel d_Suf form to fildd and
- fistpd without suffix.
-
-2000-02-24 Nick Clifton <nickc@cygnus.com>
-
- * cgen.h (cgen_cpu_desc): Rename field 'flags' to
- 'signed_overflow_ok_p'.
- Delete prototypes for cgen_set_flags() and cgen_get_flags().
-
-2000-02-24 Andrew Haley <aph@cygnus.com>
-
- * cgen.h (CGEN_INSN_MACH_HAS_P): New macro.
- (CGEN_CPU_TABLE): flags: new field.
- Add prototypes for new functions.
-
-2000-02-24 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h: Add some more UNIXWARE_COMPAT comments.
-
-2000-02-23 Linas Vepstas <linas@linas.org>
-
- * i370.h: New file.
-
-2000-02-22 Chandra Chavva <cchavva@cygnus.com>
-
- * d30v.h (FLAG_NOT_WITH_ADDSUBppp): Redefined as operation
- cannot be combined in parallel with ADD/SUBppp.
-
-2000-02-22 Andrew Haley <aph@cygnus.com>
-
- * mips.h: (OPCODE_IS_MEMBER): Add comment.
-
-1999-12-30 Andrew Haley <aph@cygnus.com>
-
- * mips.h (OPCODE_IS_MEMBER): Add gp32 arg, which determines
- whether synthetic opcodes (e.g. move) generate 32-bit or 64-bit
- insns.
-
-2000-01-15 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h: Qualify intel mode far call and jmp with x_Suf.
-
-1999-12-27 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h: Add JumpAbsolute qualifier to all non-intel mode
- indirect jumps and calls. Add FF/3 call for intel mode.
-
-Wed Dec 1 03:05:25 1999 Jeffrey A Law (law@cygnus.com)
-
- * mn10300.h: Add new operand types. Add new instruction formats.
-
-Wed Nov 24 20:28:58 1999 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h (pa_opcodes): Correctly handle immediate for PA2.0 "bb"
- instruction.
-
-1999-11-18 Gavin Romig-Koch <gavin@cygnus.com>
-
- * mips.h (INSN_ISA5): New.
-
-1999-11-01 Gavin Romig-Koch <gavin@cygnus.com>
-
- * mips.h (OPCODE_IS_MEMBER): New.
-
-1999-10-29 Nick Clifton <nickc@cygnus.com>
-
- * d30v.h (SHORT_AR): Define.
-
-1999-10-18 Michael Meissner <meissner@cygnus.com>
-
- * alpha.h (alpha_num_opcodes): Convert to unsigned.
- (alpha_num_operands): Ditto.
-
-Sun Oct 10 01:46:56 1999 Jerry Quinn <jerry.quinn.adv91@alum.dartmouth.org>
-
- * hppa.h (pa_opcodes): Add load and store cache control to
- instructions. Add ordered access load and store.
-
- * hppa.h (pa_opcode): Add new entries for addb and addib.
-
- * hppa.h (pa_opcodes): Fix cmpb and cmpib entries.
-
- * hppa.h (pa_opcodes): Add entries for cmpb and cmpib.
-
-Thu Oct 7 00:12:25 MDT 1999 Diego Novillo <dnovillo@cygnus.com>
-
- * d10v.h: Add flag RESTRICTED_NUM3 for imm3 operands.
-
-Thu Sep 23 07:08:38 1999 Jerry Quinn <jquinn@nortelnetworks.com>
-
- * hppa.h (pa_opcodes): Add "call" and "ret". Clean up "b", "bve"
- and "be" using completer prefixes.
-
- * hppa.h (pa_opcodes): Add initializers to silence compiler.
-
- * hppa.h: Update comments about character usage.
-
-Mon Sep 20 03:55:31 1999 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h (pa_opcodes): Fix minor thinkos introduced while cleaning
- up the new fstw & bve instructions.
-
-Sun Sep 19 10:40:59 1999 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h (pa_opcodes): Add remaining PA2.0 integer load/store
- instructions.
-
- * hppa.h (pa_opcodes): Add remaining PA2.0 FP load/store instructions.
-
- * hppa.h (pa_opcodes): Add long offset double word load/store
- instructions.
-
- * hppa.h (pa_opcodes): Add FLAG_STRICT variants of FP loads and
- stores.
-
- * hppa.h (pa_opcodes): Handle PA2.0 fcnv, fcmp and ftest insns.
-
- * hppa.h (pa_opcodes): Finish support for PA2.0 "b" instructions.
-
- * hppa.h (pa_opcodes): Handle PA2.0 "bve" instructions.
-
- * hppa.h (pa_opcodes): Add new syntax "be" instructions.
-
- * hppa.h (pa_opcodes): Note use of 'M' and 'L'.
-
- * hppa.h (pa_opcodes): Add support for "b,l".
-
- * hppa.h (pa_opcodes): Add support for "b,gate".
-
-Sat Sep 18 11:41:16 1999 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h (pa_opcodes): Use 'fX' for first register operand
- in xmpyu.
-
- * hppa.h (pa_opcodes): Fix mask for probe and probei.
-
- * hppa.h (pa_opcodes): Fix mask for depwi.
-
-Tue Sep 7 13:44:25 1999 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h (pa_opcodes): Add "addil" variant which has the %r1 as
- an explicit output argument.
-
-Mon Sep 6 04:41:42 1999 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h: Add strict variants of PA1.0/PA1.1 loads and stores.
- Add a few PA2.0 loads and store variants.
-
-1999-09-04 Steve Chamberlain <sac@pobox.com>
-
- * pj.h: New file.
-
-1999-08-29 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h (i386_regtab): Move %st to top of table, and split off
- other fp reg entries.
- (i386_float_regtab): To here.
-
-Sat Aug 28 00:25:25 1999 Jerry Quinn <jquinn@nortelnetworks.com>
-
- * hppa.h (pa_opcodes): Replace 'f' by 'v'. Prefix float register args
- by 'f'.
-
- * hppa.h (pa_opcodes): Add extrd, extrw, depd, depdi, depw, depwi.
- Add supporting args.
-
- * hppa.h: Document new completers and args.
- * hppa.h (pa_opcodes): Add 64 bit patterns and pa2.0 syntax for uxor,
- uaddcm, dcor, addi, add, sub, subi, shladd, rfi, and probe. Add pa2.0
- extensions for ssm, rsm, pdtlb, pitlb. Add performance instructions
- pmenb and pmdis.
-
- * hppa.h (pa_opcodes): Add pa2.0 instructions hadd, hshl,
- hshr, hsub, mixh, mixw, permh.
-
- * hppa.h (pa_opcodes): Change completers in instructions to
- use 'c' prefix.
-
- * hppa.h (pa_opcodes): Add popbts, new forms of bb, havg,
- hshladd, hshradd, shrpd, and shrpw instructions. Update arg comments.
-
- * hppa.h (pa_opcodes): Change fmpyfadd, fmpynfadd, fneg,
- fnegabs to use 'I' instead of 'F'.
-
-1999-08-21 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h: Add AMD athlon instructions, pfnacc, pfpnacc, pswapd.
- Document pf2iw and pi2fw as athlon insns. Remove pswapw.
- Alphabetically sort PIII insns.
-
-Wed Aug 18 18:14:40 1999 Doug Evans <devans@canuck.cygnus.com>
-
- * cgen.h (CGEN_INSN_MACH_HAS_P): New macro.
-
-Fri Aug 6 09:46:35 1999 Jerry Quinn <jquinn@nortelnetworks.com>
-
- * hppa.h (pa_opcodes): Add 64 bit versions of or, xor, and,
- and andcm. Add 32 and 64 bit version of cmpclr, cmpiclr.
-
- * hppa.h: Document 64 bit condition completers.
-
-Thu Aug 5 16:56:07 1999 Jerry Quinn <jquinn@nortelnetworks.com>
-
- * hppa.h (pa_opcodes): Change condition args to use '?' prefix.
-
-1999-08-04 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h (i386_optab): Add DefaultSize modifier to all insns
- that implicitly modify %esp. #undef d_Suf, x_suf, sld_suf,
- sldx_suf, bwld_Suf, d_FP, x_FP, sld_FP, sldx_FP at end of table.
-
-Wed Jul 28 02:04:24 1999 Jerry Quinn <jquinn@nortelnetworks.com>
- Jeff Law <law@cygnus.com>
-
- * hppa.h (pa_opcodes): Add "pushnom" and "pushbts".
-
- * hppa.h (pa_opcodes): Mark all PA2.0 opcodes with FLAG_STRICT.
-
- * hppa.h (pa_opcodes): Change xmpyu, fmpyfadd,
- and fmpynfadd to use 'J' and 'K' instead of 'E' and 'X'.
-
-1999-07-13 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h: Add "undocumented" AMD 3DNow! pf2iw, pi2fw, pswapw insns.
-
-Thu Jul 1 00:17:24 1999 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h (struct pa_opcode): Add new field "flags".
- (FLAGS_STRICT): Define.
-
-Fri Jun 25 04:22:04 1999 Jerry Quinn <jquinn@nortelnetworks.com>
- Jeff Law <law@cygnus.com>
-
- * hppa.h (pa_opcodes): Add pa2.0 clrbts instruction.
-
- * hppa.h (pa_opcodes): Add entries for mfia and mtsarcm instructions.
-
-1999-06-23 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h: Allow `l' suffix on bswap. Allow `w' suffix on arpl,
- lldt, lmsw, ltr, str, verr, verw. Add FP flag to fcmov*. Add FP
- flag to fcomi and friends.
-
-Fri May 28 15:26:11 1999 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h (pa_opcodes): Move integer arithmetic instructions after
- integer logical instructions.
-
-1999-05-28 Linus Nordberg <linus.nordberg@canit.se>
-
- * m68k.h: Document new formats `E', `G', `H' and new places `N',
- `n', `o'.
-
- * m68k.h: Define mcf5206e, mcf5307, mcf. Document new format `u'
- and new places `m', `M', `h'.
-
-Thu May 27 04:13:54 1999 Joel Sherrill (joel@OARcorp.com
-
- * hppa.h (pa_opcodes): Add several processor specific system
- instructions.
-
-Wed May 26 16:57:44 1999 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h (pa_opcodes): Add second entry for "comb", "comib",
- "addb", and "addib" to be used by the disassembler.
-
-1999-05-12 Alan Modra <alan@apri.levels.unisa.edu.au>
-
- * i386.h (ReverseModrm): Remove all occurences.
- (InvMem): Add to control/debug/test mov insns, movhlps, movlhps,
- movmskps, pextrw, pmovmskb, maskmovq.
- Change NoSuf to FP on all MMX, XMM and AMD insns as these all
- ignore the data size prefix.
-
- * i386.h (i386_optab, i386_regtab): Add support for PIII SIMD.
- Mostly stolen from Doug Ledford <dledford@redhat.com>
-
-Sat May 8 23:27:35 1999 Richard Henderson <rth@cygnus.com>
-
- * ppc.h (PPC_OPCODE_64_BRIDGE): New.
-
-1999-04-14 Doug Evans <devans@casey.cygnus.com>
-
- * cgen.h (CGEN_ATTR): Delete member num_nonbools.
- (CGEN_ATTR_TYPE): Update.
- (CGEN_ATTR_MASK): Number booleans starting at 0.
- (CGEN_ATTR_VALUE): Update.
- (CGEN_INSN_ATTR): Update.
-
-Mon Apr 12 23:43:27 1999 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h (fmpyfadd, fmpynfadd, fneg, fnegabs): New PA2.0
- instructions.
-
-Tue Mar 23 11:24:38 1999 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h (bb, bvb): Tweak opcode/mask.
-
-
-1999-03-22 Doug Evans <devans@casey.cygnus.com>
-
- * cgen.h (CGEN_ISA,CGEN_MACH): New typedefs.
- (struct cgen_cpu_desc): Rename member mach to machs. New member isas.
- New members word_bitsize,default_insn_bitsize,base_insn-bitsize,
- min_insn_bitsize,max_insn_bitsize,isa_table,mach_table,rebuild_tables.
- Delete member max_insn_size.
- (enum cgen_cpu_open_arg): New enum.
- (cpu_open): Update prototype.
- (cpu_open_1): Declare.
- (cgen_set_cpu): Delete.
-
-1999-03-11 Doug Evans <devans@casey.cygnus.com>
-
- * cgen.h (CGEN_HW_TABLE): Delete `num_init_entries' member.
- (CGEN_OPERAND_NIL): New macro.
- (CGEN_OPERAND): New member `type'.
- (@arch@_cgen_operand_table): Delete decl.
- (CGEN_OPERAND_INDEX,CGEN_OPERAND_TYPE,CGEN_OPERAND_ENTRY): Delete.
- (CGEN_OPERAND_TABLE): New struct.
- (cgen_operand_lookup_by_name,cgen_operand_lookup_by_num): Declare.
- (CGEN_OPINST): Pointer to operand table entry replaced with enum.
- (CGEN_CPU_TABLE): New member `isa'. Change member `operand_table',
- now a CGEN_OPERAND_TABLE. Add CGEN_CPU_DESC arg to
- {get,set}_{int,vma}_operand.
- (@arch@_cgen_cpu_open): New arg `isa'.
- (cgen_set_cpu): Ditto.
-
-Fri Feb 26 02:36:45 1999 Richard Henderson <rth@cygnus.com>
-
- * i386.h: Fill in cmov and fcmov alternates. Add fcomi short forms.
-
-1999-02-25 Doug Evans <devans@casey.cygnus.com>
-
- * cgen.h (enum cgen_asm_type): Add CGEN_ASM_NONE.
- (CGEN_HW_ENTRY): Delete member `next'. Change type of `type' to
- enum cgen_hw_type.
- (CGEN_HW_TABLE): New struct.
- (hw_table): Delete declaration.
- (CGEN_OPERAND): Change member hw to hw_type, change type from pointer
- to table entry to enum.
- (CGEN_OPINST): Ditto.
- (CGEN_CPU_TABLE): Change member hw_list to hw_table.
-
-Sat Feb 13 14:13:44 1999 Richard Henderson <rth@cygnus.com>
-
- * alpha.h (AXP_OPCODE_EV6): New.
- (AXP_OPCODE_NOPAL): Include it.
-
-1999-02-09 Doug Evans <devans@casey.cygnus.com>
-
- * cgen.h (CGEN_CPU_DESC): Renamed from CGEN_OPCODE_DESC.
- All uses updated. New members int_insn_p, max_insn_size,
- parse_operand,insert_operand,extract_operand,print_operand,
- sizeof_fields,set_fields_bitsize,get_int_operand,set_int_operand,
- get_vma_operand,set_vma_operand,parse_handlers,insert_handlers,
- extract_handlers,print_handlers.
- (CGEN_ATTR): Change type of num_nonbools to unsigned int.
- (CGEN_ATTR_BOOL_OFFSET): New macro.
- (CGEN_ATTR_MASK): Subtract it to compute bit number.
- (CGEN_ATTR_VALUE): Redo bool/nonbool attr calculation.
- (cgen_opcode_handler): Renamed from cgen_base.
- (CGEN_HW_ATTR_VALUE): Renamed from CGEN_HW_ATTR, all uses updated.
- (CGEN_OPERAND_ATTR_VALUE): Renamed from CGEN_OPERAND_ATTR,
- all uses updated.
- (CGEN_OPERAND_INDEX): Rewrite to use table entry, not global.
- (enum cgen_opinst_type): Renamed from cgen_operand_instance_type.
- (CGEN_IFLD_ATTR_VALUE): Renamed from CGEN_IFLD_ATTR, all uses updated.
- (CGEN_OPCODE,CGEN_IBASE): New types.
- (CGEN_INSN): Rewrite.
- (CGEN_{ASM,DIS}_HASH*): Delete.
- (init_opcode_table,init_ibld_table): Declare.
- (CGEN_INSN_ATTR): New type.
-
-Mon Feb 1 21:09:14 1999 Catherine Moore <clm@cygnus.com>
-
- * i386.h (d_Suf, x_Suf, sld_Suf, sldx_Suf, bwld_Suf): Define.
- (x_FP, d_FP, dls_FP, sldx_FP): Define.
- Change *Suf definitions to include x and d suffixes.
- (movsx): Use w_Suf and b_Suf.
- (movzx): Likewise.
- (movs): Use bwld_Suf.
- (fld): Change ordering. Use sld_FP.
- (fild): Add Intel Syntax equivalent of fildq.
- (fst): Use sld_FP.
- (fist): Use sld_FP.
- (fstp): Use sld_FP. Add x_FP version.
- (fistp): LLongMem version for Intel Syntax.
- (fcom, fcomp): Use sld_FP.
- (fadd, fiadd, fsub): Use sld_FP.
- (fsubr): Use sld_FP.
- (fmul, fimul, fdvi, fidiv, fdivr): Use sld_FP.
-
-1999-01-27 Doug Evans <devans@casey.cygnus.com>
-
- * cgen.h (enum cgen_mode): Add CGEN_MODE_TARGET_MAX, CGEN_MODE_INT,
- CGEN_MODE_UINT.
-
-1999-01-16 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h (bv): Fix mask.
-
-1999-01-05 Doug Evans <devans@casey.cygnus.com>
-
- * cgen.h (CGEN_ATTR_VALUE_TYPE): New typedef.
- (CGEN_ATTR): Use it.
- (CGEN_ATTR_TYPE,CGEN_ATTR_ENTRY): Ditto.
- (CGEN_ATTR_TABLE): New member dfault.
-
-1998-12-30 Gavin Romig-Koch <gavin@cygnus.com>
-
- * mips.h (MIPS16_INSN_BRANCH): New.
-
-Wed Dec 9 10:38:48 1998 David Taylor <taylor@texas.cygnus.com>
-
- The following is part of a change made by Edith Epstein
- <eepstein@sophia.cygnus.com> as part of a project to merge in
- changes by HP; HP did not create ChangeLog entries.
-
- * hppa.h (completer_chars): list of chars to not put a space
- after.
-
-Sun Dec 6 13:21:34 1998 Ian Lance Taylor <ian@cygnus.com>
-
- * i386.h (i386_optab): Permit w suffix on processor control and
- status word instructions.
-
-1998-11-30 Doug Evans <devans@casey.cygnus.com>
-
- * cgen.h (struct cgen_hw_entry): Delete const on attrs member.
- (struct cgen_keyword_entry): Ditto.
- (struct cgen_operand): Ditto.
- (CGEN_IFLD): New typedef, with associated access macros.
- (CGEN_IFMT): New typedef, with associated access macros.
- (CGEN_IFMT): Renamed from CGEN_FORMAT. New member `iflds'.
- (CGEN_IVALUE): New typedef.
- (struct cgen_insn): Delete const on syntax,attrs members.
- `format' now points to format data. Type of `value' is now
- CGEN_IVALUE.
- (struct cgen_opcode_table): New member ifld_table.
-
-1998-11-18 Doug Evans <devans@casey.cygnus.com>
-
- * cgen.h (cgen_extract_fn): Update type of `base_insn' arg.
- (CGEN_OPERAND_INSTANCE): New member `attrs'.
- (CGEN_OPERAND_INSTANCE_{ATTRS,ATTR}): New macros.
- (cgen_dis_lookup_insn): Update type of `base_insn' arg.
- (cgen_opcode_table): Update type of dis_hash fn.
- (extract_operand): Update type of `insn_value' arg.
-
-Thu Oct 29 11:38:36 1998 Doug Evans <devans@canuck.cygnus.com>
-
- * cgen.h (CGEN_VERSION_{MAJOR,MINOR,FIXLEVEL}): Delete.
-
-Tue Oct 27 08:57:59 1998 Gavin Romig-Koch <gavin@cygnus.com>
-
- * mips.h (INSN_MULT): Added.
-
-Tue Oct 20 11:31:34 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h (MAX_MNEM_SIZE): Rename from MAX_OPCODE_SIZE.
-
-Mon Oct 19 12:50:00 1998 Doug Evans <devans@seba.cygnus.com>
-
- * cgen.h (CGEN_INSN_INT): New typedef.
- (CGEN_INT_INSN_P): Renamed from CGEN_INT_INSN.
- (CGEN_INSN_BYTES): Renamed from cgen_insn_t.
- (CGEN_INSN_BYTES_PTR): New typedef.
- (CGEN_EXTRACT_INFO): New typedef.
- (cgen_insert_fn,cgen_extract_fn): Update.
- (cgen_opcode_table): New member `insn_endian'.
- (assemble_insn,lookup_insn,lookup_get_insn_operands): Update.
- (insert_operand,extract_operand): Update.
- (cgen_get_insn_value,cgen_put_insn_value): Add prototypes.
-
-Fri Oct 9 13:38:13 1998 Doug Evans <devans@seba.cygnus.com>
-
- * cgen.h (CGEN_ATTR_BOOLS): New macro.
- (struct CGEN_HW_ENTRY): New member `attrs'.
- (CGEN_HW_ATTR): New macro.
- (struct CGEN_OPERAND_INSTANCE): New member `name'.
- (CGEN_INSN_INVALID_P): New macro.
-
-Mon Oct 5 00:21:07 1998 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h: Add "fid".
-
-Sun Oct 4 21:00:00 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- From Robert Andrew Dale <rob@nb.net>
- * i386.h (i386_optab): Add AMD 3DNow! instructions.
- (AMD_3DNOW_OPCODE): Define.
-
-Tue Sep 22 17:53:47 1998 Nick Clifton <nickc@cygnus.com>
-
- * d30v.h (EITHER_BUT_PREFER_MU): Define.
-
-Mon Aug 10 14:09:38 1998 Doug Evans <devans@canuck.cygnus.com>
-
- * cgen.h (cgen_insn): #if 0 out element `cdx'.
-
-Mon Aug 3 12:21:57 1998 Doug Evans <devans@seba.cygnus.com>
-
- Move all global state data into opcode table struct, and treat
- opcode table as something that is "opened/closed".
- * cgen.h (CGEN_OPCODE_DESC): New type.
- (all fns): New first arg of opcode table descriptor.
- (cgen_set_parse_operand_fn): Add prototype.
- (cgen_current_machine,cgen_current_endian): Delete.
- (CGEN_OPCODE_TABLE): New members mach,endian,operand_table,
- parse_operand_fn,asm_hash_table,asm_hash_table_entries,
- dis_hash_table,dis_hash_table_entries.
- (opcode_open,opcode_close): Add prototypes.
-
- * cgen.h (cgen_insn): New element `cdx'.
-
-Thu Jul 30 21:44:25 1998 Frank Ch. Eigler <fche@cygnus.com>
-
- * d30v.h (FLAG_LKR): New flag for "left-kills-right" instructions.
-
-Tue Jul 28 10:59:07 1998 Jeffrey A Law (law@cygnus.com)
-
- * mn10300.h: Add "no_match_operands" field for instructions.
- (MN10300_MAX_OPERANDS): Define.
-
-Fri Jul 24 11:44:24 1998 Doug Evans <devans@canuck.cygnus.com>
-
- * cgen.h (cgen_macro_insn_count): Declare.
-
-Tue Jul 21 13:12:13 1998 Doug Evans <devans@seba.cygnus.com>
-
- * cgen.h (CGEN_VERSION_{MAJOR,MINOR,FIXLEVEL}): Define.
- (cgen_insert_fn,cgen_extract_fn): New arg `pc'.
- (get_operand,put_operand): Replaced with get_{int,vma}_operand,
- set_{int,vma}_operand.
-
-Fri Jun 26 11:09:06 1998 Jeffrey A Law (law@cygnus.com)
-
- * mn10300.h: Add "machine" field for instructions.
- (MN103, AM30): Define machine types.
-
-Fri Jun 19 16:09:09 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h: Use FP, not sl_Suf, for fxsave and fxrstor.
-
-1998-06-18 Ulrich Drepper <drepper@cygnus.com>
-
- * i386.h: Add support for fxsave, fxrstor, sysenter and sysexit.
-
-Sat Jun 13 11:31:35 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h (i386_optab): Add general form of aad and aam. Add ud2a
- and ud2b.
- (i386_regtab): Allow cr0..7, db0..7, dr0..7, tr0..7, not just
- those that happen to be implemented on pentiums.
-
-Tue Jun 9 12:16:01 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h: Change occurences of Data16 to Size16, Data32 to Size32,
- IgnoreDataSize to IgnoreSize. Flag address and data size prefixes
- with Size16|IgnoreSize or Size32|IgnoreSize.
-
-Mon Jun 8 12:15:52 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h (REPNE): Rename to REPNE_PREFIX_OPCODE.
- (REPE): Rename to REPE_PREFIX_OPCODE.
- (i386_regtab_end): Remove.
- (i386_prefixtab, i386_prefixtab_end): Remove.
- (i386_optab): Use NULL as sentinel rather than "" to suit rewrite
- of md_begin.
- (MAX_OPCODE_SIZE): Define.
- (i386_optab_end): Remove.
- (sl_Suf): Define.
- (sl_FP): Use sl_Suf.
-
- * i386.h (i386_optab): Allow 16 bit displacement for `mov
- mem,acc'. Combine 16 and 32 bit forms of various insns. Allow 16
- bit form of ljmp. Add IsPrefix modifier to prefixes. Add addr32,
- data32, dword, and adword prefixes.
- (i386_regtab): Add BaseIndex modifier to valid 16 bit base/index
- regs.
-
-Fri Jun 5 23:42:43 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h (i386_regtab): Remove BaseIndex modifier from esp.
-
- * i386.h: Allow `l' suffix on fld, fst, fstp, fcom, fcomp with
- register operands, because this is a common idiom. Flag them with
- a warning. Allow illegal faddp, fsubp, fsubrp, fmulp, fdivp,
- fdivrp because gcc erroneously generates them. Also flag with a
- warning.
-
- * i386.h: Add suffix modifiers to most insns, and tighter operand
- checks in some cases. Fix a number of UnixWare compatibility
- issues with float insns. Merge some floating point opcodes, using
- new FloatMF modifier.
- (WORD_PREFIX_OPCODE): Rename to DATA_PREFIX_OPCODE for
- consistency.
-
- * i386.h: Change occurence of ShortformW to W|ShortForm. Add
- IgnoreDataSize where appropriate.
-
-Wed Jun 3 18:28:45 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h: (one_byte_segment_defaults): Remove.
- (two_byte_segment_defaults): Remove.
- (i386_regtab): Add BaseIndex to 32 bit regs reg_type.
-
-Fri May 15 15:59:04 1998 Doug Evans <devans@seba.cygnus.com>
-
- * cgen.h (cgen_hw_lookup_by_name): Renamed from cgen_hw_lookup.
- (cgen_hw_lookup_by_num): Declare.
-
-Thu May 7 09:27:58 1998 Frank Ch. Eigler <fche@cygnus.com>
-
- * mips.h (OP_{SH,MASK}_CODE2): Added "q" operand format for lower
- ten bits of MIPS ISA1 "break" instruction, and for "sdbbp"
-
-Thu May 7 02:14:08 1998 Doug Evans <devans@charmed.cygnus.com>
-
- * cgen.h (cgen_asm_init_parse): Delete.
- (cgen_save_fixups,cgen_restore_fixups,cgen_swap_fixups): Delete.
- (cgen_asm_record_register,cgen_asm_finish_insn): Delete.
-
-Mon Apr 27 10:13:11 1998 Doug Evans <devans@seba.cygnus.com>
-
- * cgen.h (CGEN_ATTR_TYPE): Delete `const', moved to uses.
- (cgen_asm_finish_insn): Update prototype.
- (cgen_insn): New members num, data.
- (CGEN_INSN_TABLE): Members asm_hash, asm_hash_table_size,
- dis_hash, dis_hash_table_size moved to ...
- (CGEN_OPCODE_TABLE). Here. Renamed from CGEN_OPCODE_DATA.
- All uses updated. New members asm_hash_p, dis_hash_p.
- (CGEN_MINSN_EXPANSION): New struct.
- (cgen_expand_macro_insn): Declare.
- (cgen_macro_insn_count): Declare.
- (get_insn_operands): Update prototype.
- (lookup_get_insn_operands): Declare.
-
-Tue Apr 21 17:11:32 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h (i386_optab): Change iclrKludge and imulKludge to
- regKludge. Add operands types for string instructions.
-
-Mon Apr 20 14:40:29 1998 Tom Tromey <tromey@cygnus.com>
-
- * i386.h (X): Renamed from `Z_' to preserve formatting of opcode
- table.
-
-Sun Apr 19 13:54:06 1998 Tom Tromey <tromey@cygnus.com>
-
- * i386.h (Z_): Renamed from `_' to avoid clash with common alias
- for `gettext'.
-
-Fri Apr 3 12:04:48 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h: Remove NoModrm flag from all insns: it's never checked.
- Add IsString flag to string instructions.
- (IS_STRING): Don't define.
- (LOCK_PREFIX_OPCODE, CS_PREFIX_OPCODE, DS_PREFIX_OPCODE): Define.
- (ES_PREFIX_OPCODE, FS_PREFIX_OPCODE, GS_PREFIX_OPCODE): Define.
- (SS_PREFIX_OPCODE): Define.
-
-Mon Mar 30 21:31:56 1998 Ian Lance Taylor <ian@cygnus.com>
-
- * i386.h: Revert March 24 patch; no more LinearAddress.
-
-Mon Mar 30 10:25:54 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h (i386_optab): Remove fwait (9b) from all floating point
- instructions, and instead add FWait opcode modifier. Add short
- form of fldenv and fstenv.
- (FWAIT_OPCODE): Define.
-
- * i386.h (i386_optab): Change second operand constraint of `mov
- sreg,reg|mem' instruction from Reg16|Mem to WordReg|WordMem to
- allow legal instructions such as `movl %gs,%esi'
-
-Fri Mar 27 18:30:52 1998 Ian Lance Taylor <ian@cygnus.com>
-
- * h8300.h: Various changes to fully bracket initializers.
-
-Tue Mar 24 18:32:47 1998 H.J. Lu <hjl@gnu.org>
-
- * i386.h: Set LinearAddress for lidt and lgdt.
-
-Mon Mar 2 10:44:07 1998 Doug Evans <devans@seba.cygnus.com>
-
- * cgen.h (CGEN_BOOL_ATTR): New macro.
-
-Thu Feb 26 15:54:31 1998 Michael Meissner <meissner@cygnus.com>
-
- * d30v.h (FLAG_DELAY): New flag for delayed branches/jumps.
-
-Mon Feb 23 10:38:21 1998 Doug Evans <devans@seba.cygnus.com>
-
- * cgen.h (CGEN_CAT3): Delete. Use CONCAT3 now.
- (cgen_insn): Record syntax and format entries here, rather than
- separately.
-
-Tue Feb 17 21:42:56 1998 Nick Clifton <nickc@cygnus.com>
-
- * cgen.h (CGEN_SYNTAX_MAKE_FIELD): New macro.
-
-Tue Feb 17 16:00:56 1998 Doug Evans <devans@seba.cygnus.com>
-
- * cgen.h (cgen_insert_fn): Change type of result to const char *.
- (cgen_parse_{signed,unsigned}_integer): Delete min,max arguments.
- (CGEN_{INSN,KEYWORD,OPERAND}_NBOOL_ATTRS): Renamed from ..._MAX_ATTRS.
-
-Thu Feb 12 18:30:41 1998 Doug Evans <devans@canuck.cygnus.com>
-
- * cgen.h (lookup_insn): New argument alias_p.
-
-Thu Feb 12 03:41:00 1998 J"orn Rennecke <amylaar@cygnus.co.uk>
-
-Fix rac to accept only a0:
- * d10v.h (OPERAND_ACC): Split into:
- (OPERAND_ACC0, OPERAND_ACC1) .
- (OPERAND_GPR): Define.
-
-Wed Feb 11 17:31:53 1998 Doug Evans <devans@seba.cygnus.com>
-
- * cgen.h (CGEN_FIELDS): Define here.
- (CGEN_HW_ENTRY): New member `type'.
- (hw_list): Delete decl.
- (enum cgen_mode): Declare.
- (CGEN_OPERAND): New member `hw'.
- (enum cgen_operand_instance_type): Declare.
- (CGEN_OPERAND_INSTANCE): New type.
- (CGEN_INSN): New member `operands'.
- (CGEN_OPCODE_DATA): Make hw_list const.
- (get_insn_operands,lookup_insn): Add prototypes for.
-
-Tue Feb 3 17:11:23 1998 Doug Evans <devans@seba.cygnus.com>
-
- * cgen.h (CGEN_INSN_MAX_ATTRS): Renamed from CGEN_MAX_INSN_ATTRS.
- (CGEN_HW_ENTRY): Move `next' entry to end of struct.
- (CGEN_KEYWORD_MAX_ATTRS): Renamed from CGEN_MAX_KEYWORD_ATTRS.
- (CGEN_OPERAND_MAX_ATTRS): Renamed from CGEN_MAX_OPERAND_ATTRS.
-
-Mon Feb 2 19:19:15 1998 Ian Lance Taylor <ian@cygnus.com>
-
- * cgen.h: Correct typo in comment end marker.
-
-Mon Feb 2 17:10:38 1998 Steve Haworth <steve@pm.cse.rmit.EDU.AU>
-
- * tic30.h: New file.
-
-Thu Jan 22 17:54:56 1998 Nick Clifton <nickc@cygnus.com>
-
- * cgen.h: Add prototypes for cgen_save_fixups(),
- cgen_restore_fixups(), and cgen_swap_fixups(). Change prototype
- of cgen_asm_finish_insn() to return a char *.
-
-Wed Jan 14 17:21:43 1998 Nick Clifton <nickc@cygnus.com>
-
- * cgen.h: Formatting changes to improve readability.
-
-Mon Jan 12 11:37:36 1998 Doug Evans <devans@seba.cygnus.com>
-
- * cgen.h (*): Clean up pass over `struct foo' usage.
- (CGEN_ATTR): Make unsigned char.
- (CGEN_ATTR_TYPE): Update.
- (CGEN_ATTR_{ENTRY,TABLE}): New types.
- (cgen_base): Move member `attrs' to cgen_insn.
- (CGEN_KEYWORD): New member `null_entry'.
- (CGEN_{SYNTAX,FORMAT}): New types.
- (cgen_insn): Format and syntax separated from each other.
-
-Tue Dec 16 15:15:52 1997 Michael Meissner <meissner@cygnus.com>
-
- * d30v.h (d30v_opcode): Reorder flags somewhat, add new flags for
- 2 word load/store, ADDppp/SUBppp, 16/32 bit multiply. Make
- flags_{used,set} long.
- (d30v_operand): Make flags field long.
-
-Mon Dec 1 12:24:44 1997 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
-
- * m68k.h: Fix comment describing operand types.
-
-Sun Nov 23 22:31:27 1997 Michael Meissner <meissner@cygnus.com>
-
- * d30v.h (SHORT_CMPU): Add case for cmpu instruction, and move
- everything else after down.
-
-Tue Nov 18 18:45:14 1997 J"orn Rennecke <amylaar@cygnus.co.uk>
-
- * d10v.h (OPERAND_FLAG): Split into:
- (OPERAND_FFLAG, OPERAND_CFLAG) .
-
-Thu Nov 13 11:04:24 1997 Gavin Koch <gavin@cygnus.com>
-
- * mips.h (struct mips_opcode): Changed comments to reflect new
- field usage.
-
-Fri Oct 24 22:36:20 1997 Ken Raeburn <raeburn@cygnus.com>
-
- * mips.h: Added to comments a quick-ref list of all assigned
- operand type characters.
- (OP_{MASK,SH}_PERFREG): New macros.
-
-Wed Oct 22 17:28:33 1997 Richard Henderson <rth@cygnus.com>
-
- * sparc.h: Add '_' and '/' for v9a asr's.
- Patch from David Miller <davem@vger.rutgers.edu>
-
-Tue Oct 14 13:22:29 1997 Jeffrey A Law (law@cygnus.com)
-
- * h8300.h: Bit ops with absolute addresses not in the 8 bit
- area are not available in the base model (H8/300).
-
-Thu Sep 25 13:03:41 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * m68k.h: Remove documentation of ` operand specifier.
-
-Wed Sep 24 19:00:34 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * m68k.h: Document q and v operand specifiers.
-
-Mon Sep 15 18:28:37 1997 Nick Clifton <nickc@cygnus.com>
-
- * v850.h (struct v850_opcode): Add processors field.
- (PROCESSOR_V850, PROCESSOR_ALL): New bit constants.
- (PROCESSOR_V850E, PROCESSOR_NOT_V850): New bit constants.
- (PROCESSOR_V850EA): New bit constants.
-
-Mon Sep 15 11:29:43 1997 Ken Raeburn <raeburn@cygnus.com>
-
- Merge changes from Martin Hunt:
-
- * d30v.h: Allow up to 64 control registers. Add
- SHORT_A5S format.
-
- * d30v.h (LONG_Db): New form for delayed branches.
-
- * d30v.h: (LONG_Db): New form for repeati.
-
- * d30v.h (SHORT_D2B): New form.
-
- * d30v.h (SHORT_A2): New form.
-
- * d30v.h (OPERAND_2REG): Add new operand to indicate 2
- registers are used. Needed for VLIW optimization.
-
-Mon Sep 8 14:05:45 1997 Doug Evans <dje@canuck.cygnus.com>
-
- * cgen.h: Move assembler interface section
- up so cgen_parse_operand_result is defined for cgen_parse_address.
- (cgen_parse_address): Update prototype.
-
-Tue Sep 2 15:32:32 1997 Nick Clifton <nickc@cygnus.com>
-
- * v850.h (V850_OPREAND_ADJUST_SHORT_MEMORY): Removed.
-
-Tue Aug 26 12:21:52 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * i386.h (two_byte_segment_defaults): Correct base register 5 in
- modes 1 and 2 to be ss rather than ds. From Gabriel Paubert
- <paubert@iram.es>.
-
- * i386.h: Set ud2 to 0x0f0b. From Gabriel Paubert
- <paubert@iram.es>.
-
- * i386.h: Comment fixes for ficom[p]?{s,l} from Gabriel Paubert
- <paubert@iram.es>.
-
- * i386.h (JUMP_ON_CX_ZERO): Uncomment (define again).
- (JUMP_ON_ECX_ZERO): Remove commented out macro.
-
-Fri Aug 22 10:38:29 1997 Nick Clifton <nickc@cygnus.com>
-
- * v850.h (V850_NOT_R0): New flag.
-
-Mon Aug 18 11:05:58 1997 Nick Clifton <nickc@cygnus.com>
-
- * v850.h (struct v850_opcode): Remove flags field.
-
-Wed Aug 13 18:45:48 1997 Nick Clifton <nickc@cygnus.com>
-
- * v850.h (struct v850_opcode): Add flags field.
- (struct v850_operand): Extend meaning of 'bits' and 'shift'
- fields.
- (V850E_INSTRUCTION, V850EA_INSTRUCTION): New flags.
- (V850E_PUSH_POP, V850E_IMMEDIATE16, V850E_IMMEDIATE32): New flags.
-
-Fri Aug 8 16:58:42 1997 Doug Evans <dje@canuck.cygnus.com>
-
- * arc.h: New file.
-
-Thu Jul 24 21:16:58 1997 Doug Evans <dje@canuck.cygnus.com>
-
- * sparc.h (sparc_opcodes): Declare as const.
-
-Thu Jul 10 12:53:25 1997 Jeffrey A Law (law@cygnus.com)
-
- * mips.h (FP_S, FP_D): Define. Bitmasks indicating if an insn
- uses single or double precision floating point resources.
- (INSN_NO_ISA, INSN_ISA1): Define.
- (cpu specific INSN macros): Tweak into bitmasks outside the range
- of INSN_ISA field.
-
-Mon Jun 16 14:10:00 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
-
- * i386.h: Fix pand opcode.
-
-Mon Jun 2 11:35:09 1997 Gavin Koch <gavin@cygnus.com>
-
- * mips.h: Widen INSN_ISA and move it to a more convenient
- bit position. Add INSN_3900.
-
-Tue May 20 11:25:29 1997 Gavin Koch <gavin@cygnus.com>
-
- * mips.h (struct mips_opcode): added new field membership.
-
-Mon May 12 16:26:50 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
-
- * i386.h (movd): only Reg32 is allowed.
-
- * i386.h: add fcomp and ud2. From Wayne Scott
- <wscott@ichips.intel.com>.
-
-Mon May 5 17:16:21 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * i386.h: Add MMX instructions.
-
-Mon May 5 12:45:19 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
-
- * i386.h: Remove W modifier from conditional move instructions.
-
-Mon Apr 14 14:56:58 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * i386.h: Change the opcodes for fsubp, fsubrp, fdivp, and fdivrp
- with no arguments to match that generated by the UnixWare
- assembler.
-
-Thu Apr 10 14:35:00 1997 Doug Evans <dje@canuck.cygnus.com>
-
- * cgen.h (<cpu>_cgen_assemble_insn): New arg for errmsg.
- (cgen_parse_operand_fn): Declare.
- (cgen_init_parse_operand): Declare.
- (cgen_parse_operand): Renamed from cgen_asm_parse_operand,
- new argument `want'.
- (enum cgen_parse_operand_result): Renamed from cgen_asm_result.
- (enum cgen_parse_operand_type): New enum.
-
-Sat Apr 5 13:14:05 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * i386.h: Revert last patch for the NON_BROKEN_OPCODES cases.
-
-Fri Apr 4 11:46:11 1997 Doug Evans <dje@canuck.cygnus.com>
-
- * cgen.h: New file.
-
-Fri Apr 4 14:02:32 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * i386.h: Correct opcode values for fsubp, fsubrp, fdivp, and
- fdivrp.
-
-Tue Mar 25 22:57:26 1997 Stu Grossman (grossman@critters.cygnus.com)
-
- * v850.h (extract): Make unsigned.
-
-Mon Mar 24 14:38:15 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * i386.h: Add iclr.
-
-Thu Mar 20 19:49:10 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * i386.h: Change DW to W for cmpxchg and xadd, since they don't
- take a direction bit.
-
-Sat Mar 15 19:03:29 1997 H.J. Lu <hjl@lucon.org>
-
- * sparc.h (sparc_opcode_lookup_arch): Use full prototype.
-
-Fri Mar 14 15:22:01 1997 Ian Lance Taylor <ian@cygnus.com>
-
- * sparc.h: Include <ansidecl.h>. Update function declarations to
- use prototypes, and to use const when appropriate.
-
-Thu Mar 6 14:18:30 1997 Jeffrey A Law (law@cygnus.com)
-
- * mn10300.h (MN10300_OPERAND_RELAX): Define.
-
-Mon Feb 24 15:15:56 1997 Martin M. Hunt <hunt@pizza.cygnus.com>
-
- * d10v.h: Change pre_defined_registers to
- d10v_predefined_registers and reg_name_cnt to d10v_reg_name_cnt.
-
-Sat Feb 22 21:25:00 1997 Dawn Perchik <dawn@cygnus.com>
-
- * mips.h: Add macros for cop0, cop1 cop2 and cop3.
- Change mips_opcodes from const array to a pointer,
- and change bfd_mips_num_opcodes from const int to int,
- so that we can increase the size of the mips opcodes table
- dynamically.
-
-Fri Feb 21 16:34:18 1997 Martin M. Hunt <hunt@pizza.cygnus.com>
-
- * d30v.h (FLAG_X): Remove unused flag.
-
-Tue Feb 18 17:37:20 1997 Martin M. Hunt <hunt@pizza.cygnus.com>
-
- * d30v.h: New file.
-
-Fri Feb 14 13:16:15 1997 Fred Fish <fnf@cygnus.com>
-
- * tic80.h (PDS_NAME): Macro to access name field of predefined symbols.
- (PDS_VALUE): Macro to access value field of predefined symbols.
- (tic80_next_predefined_symbol): Add prototype.
-
-Mon Feb 10 10:32:17 1997 Fred Fish <fnf@cygnus.com>
-
- * tic80.h (tic80_symbol_to_value): Change prototype to match
- change in function, added class parameter.
-
-Thu Feb 6 17:30:15 1997 Fred Fish <fnf@cygnus.com>
-
- * tic80.h (TIC80_OPERAND_ENDMASK): Add for flagging TIc80
- endmask fields, which are somewhat weird in that 0 and 32 are
- treated exactly the same.
-
-Thu Jan 30 13:46:18 1997 Fred Fish <fnf@cygnus.com>
-
- * tic80.h: Change all the OPERAND defines to use the form (1 << X)
- rather than a constant that is 2**X. Reorder them to put bits for
- operands that have symbolic names in the upper bits, so they can
- be packed into an int where the lower bits contain the value that
- corresponds to that symbolic name.
- (predefined_symbo): Add struct.
- (tic80_predefined_symbols): Declare array of translations.
- (tic80_num_predefined_symbols): Declare size of that array.
- (tic80_value_to_symbol): Declare function.
- (tic80_symbol_to_value): Declare function.
-
-Wed Jan 29 09:37:25 1997 Jeffrey A Law (law@cygnus.com)
-
- * mn10200.h (MN10200_OPERAND_RELAX): Define.
-
-Sat Jan 18 15:18:59 1997 Fred Fish <fnf@cygnus.com>
-
- * tic80.h (TIC80_NO_R0_DEST): Add for opcodes where r0 cannot
- be the destination register.
-
-Thu Jan 16 20:48:55 1997 Fred Fish <fnf@cygnus.com>
-
- * tic80.h (struct tic80_opcode): Change "format" field to "flags".
- (FMT_UNUSED, FMT_SI, FMT_LI, FMT_REG): Delete.
- (TIC80_VECTOR): Define a flag bit for the flags. This one means
- that the opcode can have two vector instructions in a single
- 32 bit word and we have to encode/decode both.
-
-Tue Jan 14 19:37:09 1997 Fred Fish <fnf@cygnus.com>
-
- * tic80.h (TIC80_OPERAND_PCREL): Renamed from
- TIC80_OPERAND_RELATIVE for PC relative.
- (TIC80_OPERAND_BASEREL): New flag bit for register
- base relative.
-
-Mon Jan 13 15:56:38 1997 Fred Fish <fnf@cygnus.com>
-
- * tic80.h (TIC80_OPERAND_FLOAT): Add for floating point operands.
-
-Mon Jan 6 10:51:15 1997 Fred Fish <fnf@cygnus.com>
-
- * tic80.h (TIC80_OPERAND_SCALED): Operand may have optional
- ":s" modifier for scaling.
-
-Sun Jan 5 12:12:19 1997 Fred Fish <fnf@cygnus.com>
-
- * tic80.h (TIC80_OPERAND_M_SI): Add operand modifier for ":m".
- (TIC80_OPERAND_M_LI): Ditto
-
-Sat Jan 4 19:02:44 1997 Fred Fish <fnf@cygnus.com>
-
- * tic80.h (TIC80_OPERAND_BITNUM): Renamed from TIC80_OPERAND_CC_SZ.
- (TIC80_OPERAND_CC): New define for condition code operand.
- (TIC80_OPERAND_CR): New define for control register operand.
-
-Fri Jan 3 16:22:23 1997 Fred Fish <fnf@cygnus.com>
-
- * tic80.h (struct tic80_opcode): Name changed.
- (struct tic80_opcode): Remove format field.
- (struct tic80_operand): Add insertion and extraction functions.
- (TIC80_OPERAND_*): Remove old bogus values, start adding new
- correct ones.
- (FMT_*): Ditto.
-
-Tue Dec 31 15:05:41 1996 Michael Meissner <meissner@tiktok.cygnus.com>
-
- * v850.h (V850_OPERAND_ADJUST_SHORT_MEMORY): New flag to adjust
- type IV instruction offsets.
-
-Fri Dec 27 22:23:10 1996 Fred Fish <fnf@cygnus.com>
-
- * tic80.h: New file.
-
-Wed Dec 18 10:06:31 1996 Jeffrey A Law (law@cygnus.com)
-
- * mn10200.h (MN10200_OPERAND_NOCHECK): Define.
-
-Sat Dec 14 10:48:31 1996 Fred Fish <fnf@ninemoons.com>
-
- * mn10200.h: Fix comment, mn10200_operand not powerpc_operand.
- * mn10300.h: Fix comment, mn10300_operand not powerpc_operand.
- * v850.h: Fix comment, v850_operand not powerpc_operand.
-
-Mon Dec 9 16:45:39 1996 Jeffrey A Law (law@cygnus.com)
-
- * mn10200.h: Flesh out structures and definitions needed by
- the mn10200 assembler & disassembler.
-
-Tue Nov 26 10:46:56 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * mips.h: Add mips16 definitions.
-
-Mon Nov 25 17:56:54 1996 J.T. Conklin <jtc@cygnus.com>
-
- * m68k.h: Document new <, >, m, n, o and p operand specifiers.
-
-Wed Nov 20 10:59:41 1996 Jeffrey A Law (law@cygnus.com)
-
- * mn10300.h (MN10300_OPERAND_PCREL): Define.
- (MN10300_OPERAND_MEMADDR): Define.
-
-Tue Nov 19 13:30:40 1996 Jeffrey A Law (law@cygnus.com)
-
- * mn10300.h (MN10300_OPERAND_REG_LIST): Define.
-
-Wed Nov 6 13:41:08 1996 Jeffrey A Law (law@cygnus.com)
-
- * mn10300.h (MN10300_OPERAND_SPLIT): Define.
-
-Tue Nov 5 13:26:12 1996 Jeffrey A Law (law@cygnus.com)
-
- * mn10300.h (MN10300_OPERAND_EXTENDED): Define.
-
-Mon Nov 4 12:52:48 1996 Jeffrey A Law (law@cygnus.com)
-
- * mn10300.h (MN10300_OPERAND_REPEATED): Define.
-
-Fri Nov 1 10:31:02 1996 Richard Henderson <rth@tamu.edu>
-
- * alpha.h: Don't include "bfd.h"; private relocation types are now
- negative to minimize problems with shared libraries. Organize
- instruction subsets by AMASK extensions and PALcode
- implementation.
- (struct alpha_operand): Move flags slot for better packing.
-
-Tue Oct 29 12:19:10 1996 Jeffrey A Law (law@cygnus.com)
-
- * v850.h (V850_OPERAND_RELAX): New operand flag.
-
-Thu Oct 10 14:29:11 1996 Jeffrey A Law (law@cygnus.com)
-
- * mn10300.h (FMT_*): Move operand format definitions
- here.
-
-Tue Oct 8 14:48:07 1996 Jeffrey A Law (law@cygnus.com)
-
- * mn10300.h (MN10300_OPERAND_PAREN): Define.
-
-Mon Oct 7 16:52:11 1996 Jeffrey A Law (law@cygnus.com)
-
- * mn10300.h (mn10300_opcode): Add "format" field.
- (MN10300_OPERAND_*): Define.
-
-Thu Oct 3 10:33:46 1996 Jeffrey A Law (law@cygnus.com)
-
- * mn10x00.h: Delete.
- * mn10200.h, mn10300.h: New files.
-
-Wed Oct 2 21:31:26 1996 Jeffrey A Law (law@cygnus.com)
-
- * mn10x00.h: New file.
-
-Fri Sep 27 18:26:46 1996 Stu Grossman (grossman@critters.cygnus.com)
-
- * v850.h: Add new flag to indicate this instruction uses a PC
- displacement.
-
-Fri Sep 13 14:58:13 1996 Jeffrey A Law (law@cygnus.com)
-
- * h8300.h (stmac): Add missing instruction.
-
-Sat Aug 31 16:02:03 1996 Jeffrey A Law (law@cygnus.com)
-
- * v850.h (v850_opcode): Remove "size" field. Add "memop"
- field.
-
-Fri Aug 23 10:39:08 1996 Jeffrey A Law (law@cygnus.com)
-
- * v850.h (V850_OPERAND_EP): Define.
-
- * v850.h (v850_opcode): Add size field.
-
-Thu Aug 22 16:51:25 1996 J.T. Conklin <jtc@rtl.cygnus.com>
-
- * v850.h (v850_operands): Add insert and extract fields, pointers
- to functions used to handle unusual operand encoding.
- (V850_OPERAND_REG, V850_OPERAND_SRG, V850_OPERAND_CC,
- V850_OPERAND_SIGNED): Defined.
-
-Wed Aug 21 17:45:10 1996 J.T. Conklin <jtc@rtl.cygnus.com>
-
- * v850.h (v850_operands): Add flags field.
- (OPERAND_REG, OPERAND_NUM): Defined.
-
-Tue Aug 20 14:52:02 1996 J.T. Conklin <jtc@rtl.cygnus.com>
-
- * v850.h: New file.
-
-Fri Aug 16 14:44:15 1996 James G. Smith <jsmith@cygnus.co.uk>
-
- * mips.h (OP_SH_LOCC, OP_SH_HICC, OP_MASK_CC, OP_SH_COP1NORM,
- OP_MASK_COP1NORM, OP_SH_COP1SPEC, OP_MASK_COP1SPEC,
- OP_MASK_COP1SCLR, OP_MASK_COP1CMP, OP_SH_COP1CMP, OP_SH_FORMAT,
- OP_MASK_FORMAT, OP_SH_TRUE, OP_MASK_TRUE, OP_SH_GE, OP_MASK_GE,
- OP_SH_UNSIGNED, OP_MASK_UNSIGNED, OP_SH_HINT, OP_MASK_HINT):
- Defined.
-
-Fri Aug 16 00:15:15 1996 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h (pitlb, pitlbe, iitlba, iitlbp, fic, fice): Accept
- a 3 bit space id instead of a 2 bit space id.
-
-Thu Aug 15 13:11:46 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
-
- * d10v.h: Add some additional defines to support the
- assembler in determining which operations can be done in parallel.
-
-Tue Aug 6 11:13:22 1996 Jeffrey A Law (law@cygnus.com)
-
- * h8300.h (SN): Define.
- (eepmov.b): Renamed from "eepmov"
- (nop, bpt, rte, rts, sleep, clrmac): These have no size associated
- with them.
-
-Fri Jul 26 11:47:10 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
-
- * d10v.h (OPERAND_SHIFT): New operand flag.
-
-Thu Jul 25 12:06:22 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
-
- * d10v.h: Changes for divs, parallel-only instructions, and
- signed numbers.
-
-Mon Jul 22 11:21:15 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
-
- * d10v.h (pd_reg): Define. Putting the definition here allows
- the assembler and disassembler to share the same struct.
-
-Mon Jul 22 12:15:25 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * i960.h (i960_opcodes): "halt" takes an argument. From Stephen
- Williams <steve@icarus.com>.
-
-Wed Jul 17 14:46:38 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
-
- * d10v.h: New file.
-
-Thu Jul 11 12:09:15 1996 Jeffrey A Law (law@cygnus.com)
-
- * h8300.h (band, bclr): Force high bit of immediate nibble to zero.
-
-Wed Jul 3 14:30:12 1996 J.T. Conklin <jtc@rtl.cygnus.com>
-
- * m68k.h (mcf5200): New macro.
- Document names of coldfire control registers.
-
-Tue Jul 2 23:05:45 1996 Jeffrey A Law (law@cygnus.com)
-
- * h8300.h (SRC_IN_DST): Define.
-
- * h8300.h (UNOP3): Mark the register operand in this insn
- as a source operand, not a destination operand.
- (SHIFT_2, SHIFT_IMM): Remove. Eliminate all references.
- (UNOP3): Change SHIFT_IMM to IMM for H8/S bitops. Mark
- register operand with SRC_IN_DST.
-
-Fri Jun 21 13:52:17 1996 Richard Henderson <rth@tamu.edu>
-
- * alpha.h: New file.
-
-Thu Jun 20 15:02:57 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * rs6k.h: Remove obsolete file.
-
-Wed Jun 19 15:29:38 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * i386.h: Correct opcode values for faddp, fsubp, fsubrp, fmulp,
- fdivp, and fdivrp. Add ffreep.
-
-Tue Jun 18 16:06:00 1996 Jeffrey A. Law <law@rtl.cygnus.com>
-
- * h8300.h: Reorder various #defines for readability.
- (ABS32SRC, ABS32DST, DSP32LIST, ABS32LIST, A32LIST): Define.
- (BITOP): Accept additional (unused) argument. All callers changed.
- (EBITOP): Likewise.
- (O_LAST): Bump.
- (ldc, stc, movb, movw, movl): Use 32bit offsets and absolutes.
-
- * h8300.h (EXR, SHIFT_2, MACREG, SHIFT_IMM, RDINC): Define.
- (O_TAS, O_CLRMAC, O_LDMAC, O_MAC, O_LDM, O_STM): Define.
- (BITOP, EBITOP): Handle new H8/S addressing modes for
- bit insns.
- (UNOP3): Handle new shift/rotate insns on the H8/S.
- (insns using exr): New instructions.
- (tas, mac, ldmac, clrmac, ldm, stm): New instructions.
-
-Thu May 23 16:56:48 1996 Jeffrey A Law (law@cygnus.com)
-
- * h8300.h (add.l): Undo Apr 5th change. The manual I had
- was incorrect.
-
-Mon May 6 23:38:22 1996 Jeffrey A Law (law@cygnus.com)
-
- * h8300.h (START): Remove.
- (MEMRELAX): Define. Mark absolute memory operands in mov.b, mov.w
- and mov.l insns that can be relaxed.
-
-Tue Apr 30 18:30:58 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * i386.h: Remove Abs32 from lcall.
-
-Mon Apr 22 17:09:23 1996 Doug Evans <dje@blues.cygnus.com>
-
- * sparc.h (SPARC_OPCODE_ARCH_V9_P): New macro.
- (SLCPOP): New macro.
- Mark X,Y opcode letters as in use.
-
-Thu Apr 11 17:28:18 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * sparc.h (F_FLOAT, F_FBR): Define.
-
-Fri Apr 5 16:55:34 1996 Jeffrey A Law (law@cygnus.com)
-
- * h8300.h (ABS8MEM): Renamed from ABSMOV. Remove ABSMOV
- from all insns.
- (ABS8SRC,ABS8DST): Add ABS8MEM.
- (add.l): Fix reg+reg variant.
- (eepmov.w): Renamed from eepmovw.
- (ldc,stc): Fix many cases.
-
-Sun Mar 31 13:30:03 1996 Doug Evans <dje@canuck.cygnus.com>
-
- * sparc.h (SPARC_OPCODE_ARCH_MASK): New macro.
-
-Thu Mar 7 15:08:23 1996 Doug Evans <dje@charmed.cygnus.com>
-
- * sparc.h (O): Mark operand letter as in use.
-
-Tue Feb 20 20:46:21 1996 Doug Evans <dje@charmed.cygnus.com>
-
- * sparc.h (sparc_{encode,decode}_sparclet_cpreg): Declare.
- Mark operand letters uU as in use.
-
-Mon Feb 19 01:59:08 1996 Doug Evans <dje@charmed.cygnus.com>
-
- * sparc.h (sparc_opcode_arch_val): Add SPARC_OPCODE_ARCH_SPARCLET.
- (sparc_opcode_arch): Delete member `conflicts'. Add `supported'.
- (SPARC_OPCODE_SUPPORTED): New macro.
- (SPARC_OPCODE_CONFLICT_P): Rewrite.
- (F_NOTV9): Delete.
-
-Fri Feb 16 12:23:34 1996 Jeffrey A Law (law@cygnus.com)
-
- * sparc.h (sparc_opcode_lookup_arch) Make return type in
- declaration consistent with return type in definition.
-
-Wed Feb 14 18:14:11 1996 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * i386.h (i386_optab): Remove Data32 from pushf and popf.
-
-Thu Feb 8 14:27:21 1996 James Carlson <carlson@xylogics.com>
-
- * i386.h (i386_regtab): Add 80486 test registers.
-
-Mon Feb 5 18:35:46 1996 Ian Lance Taylor <ian@cygnus.com>
-
- * i960.h (I_HX): Define.
- (i960_opcodes): Add HX instruction.
-
-Mon Jan 29 12:43:39 1996 Ken Raeburn <raeburn@cygnus.com>
-
- * i386.h: Fix waiting forms of finit, fstenv, fsave, fstsw, fstcw,
- and fclex.
-
-Wed Jan 24 22:36:59 1996 Doug Evans <dje@charmed.cygnus.com>
-
- * sparc.h (enum sparc_opcode_arch_val): Replaces sparc_architecture.
- (SPARC_OPCODE_CONFLICT_P): Renamed from ARCHITECTURES_CONFLICT_P.
- (bfd_* defines): Delete.
- (sparc_opcode_archs): Replaces architecture_pname.
- (sparc_opcode_lookup_arch): Declare.
- (NUMOPCODES): Delete.
-
-Mon Jan 22 08:24:32 1996 Doug Evans <dje@charmed.cygnus.com>
-
- * sparc.h (enum sparc_architecture): Add v9a.
- (ARCHITECTURES_CONFLICT_P): Update.
-
-Thu Dec 28 13:27:53 1995 John Hassey <hassey@rtp.dg.com>
-
- * i386.h: Added Pentium Pro instructions.
-
-Thu Nov 2 22:59:22 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * m68k.h: Document new 'W' operand place.
-
-Tue Oct 24 10:49:10 1995 Jeffrey A Law (law@cygnus.com)
-
- * hppa.h: Add lci and syncdma instructions.
-
-Mon Oct 23 11:09:16 1995 James G. Smith <jsmith@pasanda.cygnus.co.uk>
-
- * mips.h: Added INSN_4100 flag to mark NEC VR4100 specific
- instructions.
-
-Mon Oct 16 10:28:15 1995 Michael Meissner <meissner@tiktok.cygnus.com>
-
- * ppc.h (PPC_OPCODE_{COMMON,ANY}): New opcode flags for
- assembler's -mcom and -many switches.
-
-Wed Oct 11 16:56:33 1995 Ken Raeburn <raeburn@cygnus.com>
-
- * i386.h: Fix cmpxchg8b extension opcode description.
-
-Thu Oct 5 18:03:36 1995 Ken Raeburn <raeburn@cygnus.com>
-
- * i386.h: Add Pentium instructions wrmsr, rdtsc, rdmsr, cmpxchg8b,
- and register cr4.
-
-Tue Sep 19 15:26:43 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * m68k.h: Change comment: split type P into types 0, 1 and 2.
-
-Wed Aug 30 13:50:55 1995 Doug Evans <dje@canuck.cygnus.com>
-
- * sparc.h (sparc_{encode,decode}_prefetch): Declare.
-
-Tue Aug 29 15:34:58 1995 Doug Evans <dje@canuck.cygnus.com>
-
- * sparc.h (sparc_{encode,decode}_{asi,membar}): Declare.
-
-Wed Aug 2 18:32:19 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * m68kmri.h: Remove.
-
- * m68k.h: Move tables into opcodes/m68k-opc.c, leaving just the
- declarations. Remove F_ALIAS and flag field of struct
- m68k_opcode. Change arch field of struct m68k_opcode to unsigned
- int. Make name and args fields of struct m68k_opcode const.
-
-Wed Aug 2 08:16:46 1995 Doug Evans <dje@canuck.cygnus.com>
-
- * sparc.h (F_NOTV9): Define.
-
-Tue Jul 11 14:20:42 1995 Jeff Spiegel <jeffs@lsil.com>
-
- * mips.h (INSN_4010): Define.
-
-Wed Jun 21 18:49:51 1995 Ken Raeburn <raeburn@cujo.cygnus.com>
-
- * m68k.h (TBL1): Reverse sense of "round" argument in result.
-
- Changes from Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>:
- * m68k.h: Fix argument descriptions of coprocessor
- instructions to allow only alterable operands where appropriate.
- [!NO_DEFAULT_SIZES]: An omitted size defaults to `w'.
- (m68k_opcode_aliases): Add more aliases.
-
-Fri Apr 14 22:15:34 1995 Ken Raeburn <raeburn@cujo.cygnus.com>
-
- * m68k.h: Added explcitly short-sized conditional branches, and a
- bunch of aliases (fmov*, ftest*, tdivul) to support gcc's
- svr4-based configurations.
-
-Mon Mar 13 21:30:01 1995 Ken Raeburn <raeburn@cujo.cygnus.com>
-
- Mon Feb 27 08:36:39 1995 Bryan Ford <baford@cs.utah.edu>
- * i386.h: added missing Data16/Data32 flags to a few instructions.
-
-Wed Mar 8 15:19:53 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * mips.h (OP_MASK_FR, OP_SH_FR): Define.
- (OP_MASK_BCC, OP_SH_BCC): Define.
- (OP_MASK_PREFX, OP_SH_PREFX): Define.
- (OP_MASK_CCC, OP_SH_CCC): Define.
- (INSN_READ_FPR_R): Define.
- (INSN_RFE): Delete.
-
-Wed Mar 8 03:13:23 1995 Ken Raeburn <raeburn@cujo.cygnus.com>
-
- * m68k.h (enum m68k_architecture): Deleted.
- (struct m68k_opcode_alias): New type.
- (m68k_opcodes): Now const. Deleted opcode aliases with exactly
- matching constraints, values and flags. As a side effect of this,
- the MOTOROLA_SYNTAX_ONLY and MIT_SYNTAX_ONLY macros, which so far
- as I know were never used, now may need re-examining.
- (numopcodes): Now const.
- (m68k_opcode_aliases, numaliases): New variables.
- (endop): Deleted.
- [DONT_DEFINE_TABLE]: Declare numopcodes, numaliases, and
- m68k_opcode_aliases; update declaration of m68k_opcodes.
-
-Mon Mar 6 10:02:00 1995 Jeff Law (law@snake.cs.utah.edu)
-
- * hppa.h (delay_type): Delete unused enumeration.
- (pa_opcode): Replace unused delayed field with an architecture
- field.
- (pa_opcodes): Mark each instruction as either PA1.0 or PA1.1.
-
-Fri Mar 3 16:10:24 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * mips.h (INSN_ISA4): Define.
-
-Fri Feb 24 19:13:37 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * mips.h (M_DLA_AB, M_DLI): Define.
-
-Thu Feb 23 17:33:09 1995 Jeff Law (law@snake.cs.utah.edu)
-
- * hppa.h (fstwx): Fix single-bit error.
-
-Wed Feb 15 12:19:52 1995 Ian Lance Taylor <ian@cygnus.com>
-
- * mips.h (M_ULD, M_ULD_A, M_USD, M_USD_A): Define.
-
-Mon Feb 6 10:35:23 1995 J.T. Conklin <jtc@rtl.cygnus.com>
-
- * i386.h: added cpuid instruction , and dr[0-7] aliases for the
- debug registers. From Charles Hannum (mycroft@netbsd.org).
-
-Mon Feb 6 03:31:54 1995 Ken Raeburn <raeburn@cujo.cygnus.com>
-
- Changes from Bryan Ford <baford@schirf.cs.utah.edu> for 16-bit
- i386 support:
- * i386.h (MOV_AX_DISP32): New macro.
- (i386_optab): Added Data16 and Data32 as needed. Added "w" forms
- of several call/return instructions.
- (ADDR_PREFIX_OPCODE): New macro.
-
-Mon Jan 23 16:45:43 1995 Ken Raeburn <raeburn@cujo.cygnus.com>
-
- Sat Jan 21 17:50:38 1995 Pat Rankin (rankin@eql.caltech.edu)
-
- * vax.h (struct vot_wot, field `args'): Make it pointer to const
- char.
- (struct vot, field `name'): ditto.
-
-Thu Jan 19 14:47:53 1995 Ken Raeburn <raeburn@cujo.cygnus.com>
-
- * vax.h: Supply and properly group all values in end sentinel.
-
-Tue Jan 17 10:55:30 1995 Ian Lance Taylor <ian@sanguine.cygnus.com>
-
- * mips.h (INSN_ISA, INSN_4650): Define.
-
-Wed Oct 19 13:34:17 1994 Ian Lance Taylor <ian@sanguine.cygnus.com>
-
- * a29k.h: Add operand type 'I' for `inv' and `iretinv'. On
- systems with a separate instruction and data cache, such as the
- 29040, these instructions take an optional argument.
-
-Wed Sep 14 17:44:20 1994 Ian Lance Taylor (ian@sanguine.cygnus.com)
-
- * mips.h (INSN_STORE_MEMORY): Correct value to not conflict with
- INSN_TRAP.
-
-Tue Sep 6 11:39:08 1994 Ian Lance Taylor (ian@sanguine.cygnus.com)
-
- * mips.h (INSN_STORE_MEMORY): Define.
-
-Thu Jul 28 19:28:07 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
-
- * sparc.h: Document new operand type 'x'.
-
-Tue Jul 26 17:48:05 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
-
- * i960.h (I_CX2): New instruction category. It includes
- instructions available on Cx and Jx processors.
- (I_JX): New instruction category, for JX-only instructions.
- (i960_opcodes): Put eshro and sysctl in I_CX2 category. Added
- Jx-only instructions, in I_JX category.
-
-Wed Jul 13 18:43:47 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
-
- * ns32k.h (endop): Made pointer const too.
-
-Sun Jul 10 11:01:09 1994 Ian Dall (dall@hfrd.dsto.gov.au)
-
- * ns32k.h: Drop Q operand type as there is no correct use
- for it. Add I and Z operand types which allow better checking.
-
-Thu Jul 7 12:34:48 1994 Steve Chamberlain (sac@jonny.cygnus.com)
-
- * h8300.h (xor.l) :fix bit pattern.
- (L_2): New size of operand.
- (trapa): Use it.
-
-Fri Jun 10 16:38:11 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * m68k.h: Move "trap" before "tpcc" to change disassembly.
-
-Fri Jun 3 15:57:36 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
-
- * sparc.h: Include v9 definitions.
-
-Thu Jun 2 12:23:17 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
-
- * m68k.h (m68060): Defined.
- (m68040up, mfloat, mmmu): Include it.
- (struct m68k_opcode): Widen `arch' field.
- (m68k_opcodes): Updated for M68060. Removed comments that were
- instructions commented out by "JF" years ago.
-
-Thu Apr 28 18:31:14 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
-
- * m68k.h (struct m68k_opcode): Shorten `arch' field to 8 bits, and
- add a one-bit `flags' field.
- (F_ALIAS): New macro.
-
-Wed Apr 27 11:29:52 1994 Steve Chamberlain (sac@cygnus.com)
-
- * h8300.h (dec, inc): Get encoding right.
-
-Mon Apr 4 13:12:43 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * ppc.h (struct powerpc_operand): Removed signedp field; just use
- a flag instead.
- (PPC_OPERAND_SIGNED): Define.
- (PPC_OPERAND_SIGNOPT): Define.
-
-Thu Mar 31 19:34:08 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
-
- * i386.h (IS_JUMP_ON_ECX_ZERO, "jcxz" pattern): Operand size
- prefix is 0x66, not 0x67. Patch from H.J. Lu (hlu@nynexst.com).
-
-Thu Mar 3 15:51:05 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
-
- * i386.h: Reverse last change. It'll be handled in gas instead.
-
-Thu Feb 24 15:29:05 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
-
- * i386.h (sar): Disabled the two-operand Imm1 form, since it was
- slower on the 486 and used the implicit shift count despite the
- explicit operand. The one-operand form is still available to get
- the shorter form with the implicit shift count.
-
-Thu Feb 17 12:27:52 1994 Torbjorn Granlund (tege@mexican.cygnus.com)
-
- * hppa.h: Fix typo in fstws arg string.
-
-Wed Feb 9 21:23:52 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * ppc.h (struct powerpc_opcode): Make operands field unsigned.
-
-Mon Feb 7 19:14:58 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * ppc.h (PPC_OPCODE_601): Define.
-
-Fri Feb 4 23:43:50 1994 Jeffrey A. Law (law@snake.cs.utah.edu)
-
- * hppa.h (addb): Use '@' for addb and addib pseudo ops.
- (so we can determine valid completers for both addb and addb[tf].)
-
- * hppa.h (xmpyu): No floating point format specifier for the
- xmpyu instruction.
-
-Fri Feb 4 23:36:52 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * ppc.h (PPC_OPERAND_NEXT): Define.
- (PPC_OPERAND_NEGATIVE): Change value to make room for above.
- (struct powerpc_macro): Define.
- (powerpc_macros, powerpc_num_macros): Declare.
-
-Fri Jan 21 19:13:50 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * ppc.h: New file. Header file for PowerPC opcode table.
-
-Mon Jan 17 00:14:23 1994 Jeffrey A. Law (law@snake.cs.utah.edu)
-
- * hppa.h: More minor template fixes for sfu and copr (to allow
- for easier disassembly).
-
- * hppa.h: Fix templates for all the sfu and copr instructions.
-
-Wed Dec 15 15:12:42 1993 Ken Raeburn (raeburn@cujo.cygnus.com)
-
- * i386.h (push): Permit Imm16 operand too.
-
-Sat Dec 11 16:14:06 1993 Steve Chamberlain (sac@thepub.cygnus.com)
-
- * h8300.h (andc): Exists in base arch.
-
-Wed Dec 1 12:15:32 1993 Jeffrey A. Law (law@snake.cs.utah.edu)
-
- * From Hisashi MINAMINO <minamino@sramhc.sra.co.jp>
- * hppa.h: #undef NONE to avoid conflict with hiux include files.
-
-Sun Nov 21 22:06:57 1993 Jeffrey A. Law (law@snake.cs.utah.edu)
-
- * hppa.h: Add FP quadword store instructions.
-
-Wed Nov 17 17:13:16 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * mips.h: (M_J_A): Added.
- (M_LA): Removed.
-
-Mon Nov 8 12:12:47 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * mips.h (OP_MASK_CACHE, OP_SH_CACHE): Define. From Ted Lemon
- <mellon@pepper.ncd.com>.
-
-Sun Nov 7 00:30:11 1993 Jeffrey A. Law (law@snake.cs.utah.edu)
-
- * hppa.h: Immediate field in probei instructions is unsigned,
- not low-sign extended.
-
-Wed Nov 3 10:30:00 1993 Jim Kingdon (kingdon@lioth.cygnus.com)
-
- * m88k.h (RRI10MASK): Change from 0xfc00ffe0 to 0xfc00fc00.
-
-Tue Nov 2 12:41:30 1993 Ken Raeburn (raeburn@rover.cygnus.com)
-
- * i386.h: Add "fxch" without operand.
-
-Mon Nov 1 18:13:03 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * mips.h (M_JAL_1, M_JAL_2, M_JAL_A): Added.
-
-Sat Oct 2 22:26:11 1993 Jeffrey A Law (law@snake.cs.utah.edu)
-
- * hppa.h: Add gfw and gfr to the opcode table.
-
-Wed Sep 29 16:23:00 1993 K. Richard Pixley (rich@sendai.cygnus.com)
-
- * m88k.h: extended to handle m88110.
-
-Tue Sep 28 19:19:08 1993 Jeffrey A Law (law@snake.cs.utah.edu)
-
- * hppa.h (be, ble): Use operand type 'z' to denote absolute branch
- addresses.
-
-Tue Sep 14 14:04:35 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * i960.h (i960_opcodes): Properly bracket initializers.
-
-Mon Sep 13 12:50:52 1993 K. Richard Pixley (rich@sendai.cygnus.com)
-
- * m88k.h (BOFLAG): rewrite to avoid nested comment.
-
-Mon Sep 13 15:46:06 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * m68k.h (two): Protect second argument with parentheses.
-
-Fri Sep 10 16:29:47 1993 Ken Raeburn (raeburn@cambridge.cygnus.com)
-
- * i386.h (i386_optab): Added new instruction "rsm" (for i386sl).
- Deleted old in/out instructions in "#if 0" section.
-
-Thu Sep 9 17:42:19 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * i386.h (i386_optab): Properly bracket initializers.
-
-Wed Aug 25 13:50:56 1993 Ken Raeburn (raeburn@cambridge.cygnus.com)
-
- * hppa.h (pa_opcode): Use '|' for movb and movib insns. (From
- Jeff Law, law@cs.utah.edu).
-
-Mon Aug 23 16:55:03 1993 Ken Raeburn (raeburn@cambridge.cygnus.com)
-
- * i386.h (lcall): Accept Imm32 operand also.
-
-Mon Aug 23 12:43:11 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * mips.h (M_ABSU): Removed (absolute value of unsigned number??).
- (M_DABS): Added.
-
-Thu Aug 19 15:08:37 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * mips.h (INSN_*): Changed values. Removed unused definitions.
- Added INSN_COND_BRANCH_LIKELY, INSN_ISA2 and INSN_ISA3. Split
- INSN_LOAD_DELAY into INSN_LOAD_MEMORY_DELAY and
- INSN_LOAD_COPROC_DELAY. Split INSN_COPROC_DELAY into
- INSN_COPROC_MOVE_DELAY and INSN_COPROC_MEMORY_DELAY.
- (M_*): Added new values for r6000 and r4000 macros.
- (ANY_DELAY): Removed.
-
-Wed Aug 18 15:37:48 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * mips.h: Added M_LI_S and M_LI_SS.
-
-Tue Aug 17 07:08:08 1993 Steve Chamberlain (sac@phydeaux.cygnus.com)
-
- * h8300.h: Get some rare mov.bs correct.
-
-Thu Aug 5 09:15:17 1993 Jim Kingdon (kingdon@lioth.cygnus.com)
-
- * sparc.h: Don't define const ourself; rely on ansidecl.h having
- been included.
-
-Fri Jul 30 18:41:11 1993 John Gilmore (gnu@cygnus.com)
-
- * sparc.h (F_JSR, F_UNBR, F_CONDBR): Add new flags to mark
- jump instructions, for use in disassemblers.
-
-Thu Jul 22 07:25:27 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * m88k.h: Make bitfields just unsigned, not unsigned long or
- unsigned short.
-
-Wed Jul 21 11:55:31 1993 Jim Kingdon (kingdon@deneb.cygnus.com)
-
- * hppa.h: New argument type 'y'. Use in various float instructions.
-
-Mon Jul 19 17:17:03 1993 Jim Kingdon (kingdon@deneb.cygnus.com)
-
- * hppa.h (break): First immediate field is unsigned.
-
- * hppa.h: Add rfir instruction.
-
-Sun Jul 18 16:28:08 1993 Jim Kingdon (kingdon@rtl.cygnus.com)
-
- * mips.h: Split the actual table out into ../../opcodes/mips-opc.c.
-
-Fri Jul 16 09:59:29 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * mips.h: Reworked the hazard information somewhat, and fixed some
- bugs in the instruction hazard descriptions.
-
-Thu Jul 15 12:42:01 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * m88k.h: Corrected a couple of opcodes.
-
-Tue Jul 6 15:17:35 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * mips.h: Replaced with version from Ralph Campbell and OSF. The
- new version includes instruction hazard information, but is
- otherwise reasonably similar.
-
-Thu Jul 1 20:36:17 1993 Doug Evans (dje@canuck.cygnus.com)
-
- * h8300.h: Fix typo in UNOP3 (affected sh[al][lr].l).
-
-Fri Jun 11 18:38:44 1993 Ken Raeburn (raeburn@cygnus.com)
-
- Patches from Jeff Law, law@cs.utah.edu:
- * hppa.h: Clean up some of the OLD_TABLE, non-OLD_TABLE braindamage.
- Make the tables be the same for the following instructions:
- "bb", "addb[tf]", "addib[tf]", "add", "add[loc]", "addco",
- "sh[123]add", "sh[123]add[lo]", "sub", "sub[obt]", "sub[bt]o",
- "ds", "comclr", "addi", "addi[ot]", "addito", "subi", "subio",
- "comiclr", "fadd", "fsub", "fmpy", "fdiv", "fsqrt", "fabs",
- "frnd", "fcpy", "fcnvff", "fcnvxf", "fcnvfx", "fcnvfxt",
- "fcmp", and "ftest".
-
- * hppa.h: Make new and old tables the same for "break", "mtctl",
- "mfctl", "bb", "ssm", "rsm", "xmpyu", "fmpyadd", "fmpysub".
- Fix typo in last patch. Collapse several #ifdefs into a
- single #ifdef.
-
- * hppa.h: Delete remaining OLD_TABLE code. Bring some
- of the comments up-to-date.
-
- * hppa.h: Update "free list" of letters and update
- comments describing each letter's function.
-
-Thu Jul 8 09:05:26 1993 Doug Evans (dje@canuck.cygnus.com)
-
- * h8300.h: Lots of little fixes for the h8/300h.
-
-Tue Jun 8 12:16:03 1993 Steve Chamberlain (sac@phydeaux.cygnus.com)
-
- Support for H8/300-H
- * h8300.h: Lots of new opcodes.
-
-Fri Jun 4 15:41:37 1993 Steve Chamberlain (sac@phydeaux.cygnus.com)
-
- * h8300.h: checkpoint, includes H8/300-H opcodes.
-
-Thu Jun 3 15:42:59 1993 Stu Grossman (grossman@cygnus.com)
-
- * Patches from Jeffrey Law <law@cs.utah.edu>.
- * hppa.h: Rework single precision FP
- instructions so that they correctly disassemble code
- PA1.1 code.
-
-Thu May 27 19:21:22 1993 Bruce Bauman (boot@osf.org)
-
- * i386.h (i386_optab, mov pattern): Remove Mem16 restriction from
- mov to allow instructions like mov ss,xyz(ecx) to assemble.
-
-Tue May 25 00:39:40 1993 Ken Raeburn (raeburn@cygnus.com)
-
- * hppa.h: Use new version from Utah if OLD_TABLE isn't defined;
- gdb will define it for now.
-
-Mon May 24 15:20:06 1993 Ken Raeburn (raeburn@cambridge.cygnus.com)
-
- * sparc.h: Don't end enumerator list with comma.
-
-Fri May 14 15:15:50 1993 Ian Lance Taylor (ian@cygnus.com)
-
- * Based on patches from davidj@ICSI.Berkeley.EDU (David Johnson):
- * mips.h (OP_MASK_COPZ, OP_SH_COPZ): Define.
- ("bc2t"): Correct typo.
- ("[ls]wc[023]"): Use T rather than t.
- ("c[0123]"): Define general coprocessor instructions.
-
-Mon May 10 06:02:25 1993 Ken Raeburn (raeburn@kr-pc.cygnus.com)
-
- * m68k.h: Move split point for gcc compilation more towards
- middle.
-
-Fri Apr 9 13:26:16 1993 Jim Kingdon (kingdon@cygnus.com)
-
- * rs6k.h: Clean up instructions for primary opcode 19 (many were
- simply wrong, ics, rfi, & rfsvc were missing).
- Add "a" to opr_ext for "bb". Doc fix.
-
-Thu Mar 18 13:45:31 1993 Per Bothner (bothner@rtl.cygnus.com)
-
- * i386.h: 486 extensions from John Hassey (hassey@dg-rtp.dg.com).
- * mips.h: Add casts, to suppress warnings about shifting too much.
- * m68k.h: Document the placement code '9'.
-
-Thu Feb 18 02:03:14 1993 John Gilmore (gnu@cygnus.com)
-
- * m68k.h (BREAK_UP_BIG_DECL, AND_OTHER_PART): Add kludge which
- allows callers to break up the large initialized struct full of
- opcodes into two half-sized ones. This permits GCC to compile
- this module, since it takes exponential space for initializers.
- (numopcodes, endop): Revise to use AND_OTHER_PART in size calcs.
-
-Thu Feb 4 02:06:56 1993 John Gilmore (gnu@cygnus.com)
-
- * a29k.h: Remove RCS crud, update GPL to v2, update copyrights.
- * convex.h: Added, from GDB's convx-opcode.h. Added CONST to all
- initialized structs in it.
-
-Thu Jan 28 21:32:22 1993 John Gilmore (gnu@cygnus.com)
-
- Delta 88 changes inspired by Carl Greco, <cgreco@Creighton.Edu>:
- * m88k.h (PMEM): Avoid previous definition from <sys/param.h>.
- (AND): Change to AND_ to avoid ansidecl.h `AND' conflict.
-
-Sat Jan 23 18:10:49 PST 1993 Ralph Campbell (ralphc@pyramid.com)
-
- * mips.h: document "i" and "j" operands correctly.
-
-Thu Jan 7 15:58:13 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
-
- * mips.h: Removed endianness dependency.
-
-Sun Jan 3 14:13:35 1993 Steve Chamberlain (sac@thepub.cygnus.com)
-
- * h8300.h: include info on number of cycles per instruction.
-
-Mon Dec 21 21:29:08 1992 Stu Grossman (grossman at cygnus.com)
-
- * hppa.h: Move handy aliases to the front. Fix masks for extract
- and deposit instructions.
-
-Sat Dec 12 16:09:48 1992 Ian Lance Taylor (ian@cygnus.com)
-
- * i386.h: accept shld and shrd both with and without the shift
- count argument, which is always %cl.
-
-Fri Nov 27 17:13:18 1992 Ken Raeburn (raeburn at cygnus.com)
-
- * i386.h (i386_optab_end, i386_regtab_end): Now const.
- (one_byte_segment_defaults, two_byte_segment_defaults,
- i386_prefixtab_end): Ditto.
-
-Mon Nov 23 10:47:25 1992 Ken Raeburn (raeburn@cygnus.com)
-
- * vax.h (bb*): Use "v" (bitfield type), not "a" (address operand)
- for operand 2; from John Carr, jfc@dsg.dec.com.
-
-Wed Nov 4 07:36:49 1992 Ken Raeburn (raeburn@cygnus.com)
-
- * m68k.h: Define FIXED_SIZE_BRANCH, so bsr and bra instructions
- always use 16-bit offsets. Makes calculated-size jump tables
- feasible.
-
-Fri Oct 16 22:52:43 1992 Ken Raeburn (raeburn@cygnus.com)
-
- * i386.h: Fix one-operand forms of in* and out* patterns.
-
-Tue Sep 22 14:08:14 1992 Ken Raeburn (raeburn@cambridge.cygnus.com)
-
- * m68k.h: Added CPU32 support.
-
-Tue Sep 22 00:38:41 1992 John Gilmore (gnu@cygnus.com)
-
- * mips.h (break): Disassemble the argument. Patch from
- jonathan@cs.stanford.edu (Jonathan Stone).
-
-Wed Sep 9 11:25:28 1992 Ian Lance Taylor (ian@cygnus.com)
-
- * m68k.h: merged Motorola and MIT syntax.
-
-Thu Sep 3 09:33:22 1992 Steve Chamberlain (sac@thepub.cygnus.com)
-
- * m68k.h (pmove): make the tests less strict, the 68k book is
- wrong.
-
-Tue Aug 25 23:25:19 1992 Ken Raeburn (raeburn@cambridge.cygnus.com)
-
- * m68k.h (m68ec030): Defined as alias for 68030.
- (m68k_opcodes): New type characters "3" for 68030 MMU regs and "t"
- for immediate 0-7 added. Set up some opcodes (ptest, bkpt) to use
- them. Tightened description of "fmovex" to distinguish it from
- some "pmove" encodings. Added "pmove" for 68030 MMU regs, cleaned
- up descriptions that claimed versions were available for chips not
- supporting them. Added "pmovefd".
-
-Mon Aug 24 12:04:51 1992 Steve Chamberlain (sac@thepub.cygnus.com)
-
- * m68k.h: fix where the . goes in divull
-
-Wed Aug 19 11:22:24 1992 Ian Lance Taylor (ian@cygnus.com)
-
- * m68k.h: the cas2 instruction is supposed to be written with
- indirection on the last two operands, which can be either data or
- address registers. Added a new operand type 'r' which accepts
- either register type. Added new cases for cas2l and cas2w which
- use them. Corrected masks for cas2 which failed to recognize use
- of address register.
-
-Fri Aug 14 14:20:38 1992 Per Bothner (bothner@cygnus.com)
-
- * m68k.h: Merged in patches (mostly m68040-specific) from
- Colin Smith <colin@wrs.com>.
-
- * m68k.h: Merged m68kmri.h and m68k.h (using the former as a
- base). Also cleaned up duplicates, re-ordered instructions for
- the sake of dis-assembling (so aliases come after standard names).
- * m68kmri.h: Now just defines some macros, and #includes m68k.h.
-
-Wed Aug 12 16:38:15 1992 Steve Chamberlain (sac@thepub.cygnus.com)
-
- * m68kmri.h: added various opcodes. Moved jbxx to bxxes. Filled in
- all missing .s
-
-Mon Aug 10 23:22:33 1992 Ken Raeburn (raeburn@cygnus.com)
-
- * sparc.h: Moved tables to BFD library.
-
- * i386.h (i386_optab): Add fildq, fistpq aliases used by gcc.
-
-Sun Jun 28 13:29:03 1992 Fred Fish (fnf@cygnus.com)
-
- * h8300.h: Finish filling in all the holes in the opcode table,
- so that the Lucid C compiler can digest this as well...
-
-Fri Jun 26 21:27:17 1992 John Gilmore (gnu at cygnus.com)
-
- * i386.h: Add setc, setnc, addr16, data16, repz, repnz aliases.
- Fix opcodes on various sizes of fild/fist instructions
- (16bit=no suffix, 32bit="l" suffix, 64bit="ll" suffix).
- Use tabs to indent for comments. Fixes suggested by Minh Tran-Le.
-
-Thu Jun 25 16:13:26 1992 Stu Grossman (grossman at cygnus.com)
-
- * h8300.h: Fill in all the holes in the opcode table so that the
- losing HPUX C compiler can digest this...
-
-Thu Jun 11 12:15:25 1992 John Gilmore (gnu at cygnus.com)
-
- * mips.h: Fix decoding of coprocessor instructions, somewhat.
- (Fix by Eric Anderson, 3jean@maas-neotek.arc.nasa.gov.)
-
-Thu May 28 11:17:44 1992 Jim Wilson (wilson@sphagnum.cygnus.com)
-
- * sparc.h: Add new architecture variant sparclite; add its scan
- and divscc opcodes. Define ARCHITECTURES_CONFLICT_P macro.
-
-Tue May 5 14:23:27 1992 Per Bothner (bothner@rtl.cygnus.com)
-
- * mips.h: Add some more opcode synonyms (from Frank Yellin,
- fy@lucid.com).
-
-Thu Apr 16 18:25:26 1992 Per Bothner (bothner@cygnus.com)
-
- * rs6k.h: New version from IBM (Metin).
-
-Thu Apr 9 00:31:19 1992 Per Bothner (bothner@rtl.cygnus.com)
-
- * rs6k.h: Fix incorrect extended opcode for instructions `fm'
- and `fd'. (From metin@ibmpa.awdpa.ibm.com (Metin G. Ozisik).)
-
-Tue Apr 7 13:38:47 1992 Stu Grossman (grossman at cygnus.com)
-
- * rs6k.h: Move from ../../gdb/rs6k-opcode.h.
-
-Fri Apr 3 11:30:20 1992 Fred Fish (fnf@cygnus.com)
-
- * m68k.h (one, two): Cast macro args to unsigned to suppress
- complaints from compiler and lint about integer overflow during
- shift.
-
-Sun Mar 29 12:22:08 1992 John Gilmore (gnu at cygnus.com)
-
- * sparc.h (OP): Avoid signed overflow when shifting to high order bit.
-
-Fri Mar 6 00:22:38 1992 John Gilmore (gnu at cygnus.com)
-
- * mips.h: Make bitfield layout depend on the HOST compiler,
- not on the TARGET system.
-
-Fri Feb 21 01:29:51 1992 K. Richard Pixley (rich@cygnus.com)
-
- * i386.h: added inb, inw, outb, outw opcodes, added att syntax for
- scmp, slod, smov, ssca, ssto. Curtesy Minh Tran-Le
- <TRANLE@INTELLICORP.COM>.
-
-Thu Jan 30 07:31:44 1992 Steve Chamberlain (sac at rtl.cygnus.com)
-
- * h8300.h: turned op_type enum into #define list
-
-Thu Jan 30 01:07:24 1992 John Gilmore (gnu at cygnus.com)
-
- * sparc.h: Remove "cypress" architecture. Remove "fitox" and
- similar instructions -- they've been renamed to "fitoq", etc.
- REALLY fix tsubcctv. Fix "fcmpeq" and "fcmpq" which had wrong
- number of arguments.
- * h8300.h: Remove extra ; which produces compiler warning.
-
-Tue Jan 28 22:59:22 1992 Stu Grossman (grossman at cygnus.com)
-
- * sparc.h: fix opcode for tsubcctv.
-
-Tue Jan 7 17:19:39 1992 K. Richard Pixley (rich at cygnus.com)
-
- * sparc.h: fba and cba are now aliases for fb and cb respectively.
-
-Fri Dec 27 10:55:50 1991 Per Bothner (bothner at cygnus.com)
-
- * sparc.h (nop): Made the 'lose' field be even tighter,
- so only a standard 'nop' is disassembled as a nop.
-
-Sun Dec 22 12:18:18 1991 Michael Tiemann (tiemann at cygnus.com)
-
- * sparc.h (nop): Add RD_GO to `lose' so that only %g0 in dest is
- disassembled as a nop.
-
-Wed Dec 18 17:19:44 1991 Stu Grossman (grossman at cygnus.com)
-
- * m68k.h, sparc.h: ANSIfy enums.
-
-Tue Dec 10 00:22:20 1991 K. Richard Pixley (rich at rtl.cygnus.com)
-
- * sparc.h: fix a typo.
-
-Sat Nov 30 20:40:51 1991 Steve Chamberlain (sac at rtl.cygnus.com)
-
- * a29k.h, arm.h, h8300.h, i386.h, i860.h, i960.h , m68k.h,
- m88k.h, mips.h , np1.h, ns32k.h, pn.h, pyr.h, sparc.h, tahoe.h,
- vax.h: Renamed from ../<foo>-opcode.h.
+ * h8300.h (BITOP): Dissallow operations on @aa:16 and @aa:32
+ except for the H8S.
+For older changes see ChangeLog-9103
Local Variables:
+mode: change-log
+left-margin: 8
+fill-column: 74
version-control: never
End:
diff --git a/contrib/binutils/include/opcode/ChangeLog-9103 b/contrib/binutils/include/opcode/ChangeLog-9103
new file mode 100644
index 0000000..0cdb1f3
--- /dev/null
+++ b/contrib/binutils/include/opcode/ChangeLog-9103
@@ -0,0 +1,3102 @@
+2003-10-21 Peter Barada <pbarada@mail.wm.sps.mot.com>
+ Bernardo Innocenti <bernie@develer.com>
+
+ * m68k.h: Add MCFv4/MCF5528x support.
+
+2003-10-19 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * mmix.h (JMP_INSN_BYTE): Define.
+
+2003-09-30 Chris Demetriou <cgd@broadcom.com>
+
+ * mips.h: Document +E, +F, +G, +H, and +I operand types.
+ Update documentation of I, +B and +C operand types.
+ (INSN_ISA64R2, ISA_MIPS64R2, CPU_MIPS64R2): New defines.
+ (M_DEXT, M_DINS): New enum values.
+
+2003-09-04 Nick Clifton <nickc@redhat.com>
+
+ * v850.h (PROCESSOR_V850E1): Define.
+
+2003-08-19 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc.h (PPC_OPCODE_440): Define. Formatting. Use hex for other
+ PPC_OPCODE_* defines.
+
+2003-08-16 Jason Eckhardt <jle@rice.edu>
+
+ * i860.h (fmov.ds): Expand as famov.ds.
+ (fmov.sd): Expand as famov.sd.
+ (pfmov.ds): Expand as pfamov.ds.
+
+2003-08-07 Michael Meissner <gnu@the-meissners.org>
+
+ * cgen.h: Remove PARAM macro usage in all prototypes.
+ (CGEN_EXTRACT_INFO): Use void * instead of PTR.
+ (cgen_print_fn): Ditto.
+ (CGEN_HW_ENTRY): Ditto.
+ (CGEN_MAYBE_MULTI_IFLD): Ditto.
+ (struct cgen_insn): Ditto.
+ (CGEN_CPU_TABLE): Ditto.
+
+2003-08-07 Alan Modra <amodra@bigpond.net.au>
+
+ * alpha.h: Remove PARAMS macro.
+ * arc.h: Likewise.
+ * d10v.h: Likewise.
+ * d30v.h: Likewise.
+ * i370.h: Likewise.
+ * or32.h: Likewise.
+ * pj.h: Likewise.
+ * ppc.h: Likewise.
+ * sparc.h: Likewise.
+ * tic80.h: Likewise.
+ * v850.h: Likewise.
+
+2003-07-18 Michael Snyder <msnyder@redhat.com>
+
+ * include/opcode/h8sx.h (DO_MOVA1, DO_MOVA2): Reformatting.
+
+2003-07-15 Richard Sandiford <rsandifo@redhat.com>
+
+ * mips.h (CPU_RM7000): New macro.
+ (OPCODE_IS_MEMBER): Match CPU_RM7000 against 4650 insns.
+
+2003-07-09 Alexandre Oliva <aoliva@redhat.com>
+
+ 2000-04-01 Alexandre Oliva <aoliva@cygnus.com>
+ * mn10300.h (AM33_2): Renamed from AM33.
+ 2000-03-31 Alexandre Oliva <aoliva@cygnus.com>
+ * mn10300.h (AM332, FMT_D3): Defined.
+ (MN10300_OPERAND_FSREG, MN10300_OPERAND_FDREG): Likewise.
+ (MN10300_OPERAND_FPCR): Likewise.
+
+2003-07-01 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * s390.h (s390_opcode_cpu_val): Add enum for cpu type z990.
+
+2003-06-25 Richard Sandiford <rsandifo@redhat.com>
+
+ * h8300.h (IMM2_NS, IMM8_NS, IMM16_NS): Remove.
+ (IMM8U, IMM8U_NS): Define.
+ (h8_opcodes): Use IMM8U_NS for mov.[wl] #xx:8,@yy.
+
+2003-06-25 Richard Sandiford <rsandifo@redhat.com>
+
+ * h8300.h (h8_opcodes): Fix the mov.l @(dd:32,ERs),ERd and
+ mov.l ERs,@(dd:32,ERd) entries.
+
+2003-06-23 H.J. Lu <hongjiu.lu@intel.com>
+
+ * i386.h (i386_optab): Support Intel Precott New Instructions.
+
+2003-06-10 Gary Hade <garyhade@us.ibm.com>
+
+ * ppc.h (PPC_OPERAND_DQ): Define.
+
+2003-06-10 Richard Sandiford <rsandifo@redhat.com>
+
+ * h8300.h (IMM4_NS, IMM8_NS): New.
+ (h8_opcodes): Replace IMM4 with IMM4_NS in mov.b and mov.w entries.
+ Likewise IMM8 for mov.w and mov.l. Likewise IMM16U for mov.l.
+
+2003-06-03 Michael Snyder <msnyder@redhat.com>
+
+ * h8300.h (enum h8_model): Add AV_H8S to distinguish from H8H.
+ (ldc): Split ccr ops from exr ops (which are only available
+ on H8S or H8SX).
+ (stc): Ditto.
+ (andc, orc, xorc): Ditto.
+ (ldmac, stmac, clrmac, mac): Change access to AV_H8S.
+
+2003-06-03 Michael Snyder <msnyder@redhat.com>
+ and Bernd Schmidt <bernds@redhat.com>
+ and Alexandre Oliva <aoliva@redhat.com>
+ * h8300.h: Add support for h8300sx instruction set.
+
+2003-05-23 Jason Eckhardt <jle@rice.edu>
+
+ * i860.h (expand_type): Add XP_ONLY.
+ (scyc.b): New XP instruction.
+ (ldio.l): Likewise.
+ (ldio.s): Likewise.
+ (ldio.b): Likewise.
+ (ldint.l): Likewise.
+ (ldint.s): Likewise.
+ (ldint.b): Likewise.
+ (stio.l): Likewise.
+ (stio.s): Likewise.
+ (stio.b): Likewise.
+ (pfld.q): Likewise.
+
+2003-05-20 Jason Eckhardt <jle@rice.edu>
+
+ * i860.h (flush): Set lower 3 bits properly and use 'L'
+ for the immediate operand type instead of 'i'.
+
+2003-05-20 Jason Eckhardt <jle@rice.edu>
+
+ * i860.h (fzchks): Both S and R bits must be set.
+ (pfzchks): Likewise.
+ (faddp): Likewise.
+ (pfaddp): Likewise.
+ (fix.ss): Remove (invalid instruction).
+ (pfix.ss): Likewise.
+ (ftrunc.ss): Likewise.
+ (pftrunc.ss): Likewise.
+
+2003-05-18 Jason Eckhardt <jle@rice.edu>
+
+ * i860.h (form, pform): Add missing .dd suffix.
+
+2003-05-13 Stephane Carrez <stcarrez@nerim.fr>
+
+ * m68hc11.h (M68HC12_BANK_VIRT): Define to 0x010000
+
+2003-04-07 Michael Snyder <msnyder@redhat.com>
+
+ * h8300.h (ldc/stc): Fix up src/dst swaps.
+
+2003-04-09 J. Grant <jg-binutils@jguk.org>
+
+ * mips.h: Correct comment typo.
+
+2003-03-21 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * s390.h (s390_opcode_arch_val): Rename to s390_opcode_mode_val.
+ (S390_OPCODE_ESAME): Rename to S390_OPCODE_ZARCH.
+ (s390_opcode): Remove architecture. Add modes and min_cpu.
+
+2003-03-17 D.Venkatasubramanian <dvenkat@noida.hcltech.com>
+
+ * h8300.h (O_SYS_CMDLINE): New pseudo opcode for command line
+ processing.
+
+2003-02-21 Noida D.Venkatasubramanian <dvenkat@noida.hcltech.com>
+
+ * h8300.h (ldmac, stmac): Replace MACREG with MS32 and MD32.
+
+2003-01-23 Alan Modra <amodra@bigpond.net.au>
+
+ * m68hc11.h (cpu6812s): Define.
+
+2003-01-07 Chris Demetriou <cgd@broadcom.com>
+
+ * mips.h: Fix missing space in comment.
+ (INSN_ISA1, INSN_ISA2, INSN_ISA3, INSN_ISA4, INSN_ISA5)
+ (INSN_ISA32, INSN_ISA32R2, INSN_ISA64): Shift values right
+ by four bits.
+
+2003-01-02 Chris Demetriou <cgd@broadcom.com>
+
+ * mips.h: Update copyright years to include 2002 (which had
+ been missed previously) and 2003. Make comments about "+A",
+ "+B", and "+C" operand types more descriptive.
+
+2002-12-31 Chris Demetriou <cgd@broadcom.com>
+
+ * mips.h: Note that the "+D" operand type name is now used.
+
+2002-12-30 Chris Demetriou <cgd@broadcom.com>
+
+ * mips.h: Document "+" as the start of two-character operand
+ type names, and add new "K", "+A", "+B", and "+C" operand types.
+ (OP_MASK_INSMSB, OP_SH_INSMSB, OP_MASK_EXTMSB)
+ (OP_SH_EXTMSB, INSN_ISA32R2, ISA_MIPS32R2, CPU_MIPS32R2): New
+ defines.
+
+2002-12-24 Dmitry Diky <diwil@mail.ru>
+
+ * msp430.h: New file. Defines msp430 opcodes.
+
+2002-12-30 D.Venkatasubramanian <dvenkat@noida.hcltech.com>
+
+ * h8300.h: Added some more pseudo opcodes for system call
+ processing.
+
+2002-12-19 Chris Demetriou <cgd@broadcom.com>
+
+ * mips.h (OP_OP_COP0, OP_OP_COP1, OP_OP_COP2, OP_OP_COP3)
+ (OP_OP_LWC1, OP_OP_LWC2, OP_OP_LWC3, OP_OP_LDC1, OP_OP_LDC2)
+ (OP_OP_LDC3, OP_OP_SWC1, OP_OP_SWC2, OP_OP_SWC3, OP_OP_SDC1)
+ (OP_OP_SDC2, OP_OP_SDC3): Define.
+
+2002-12-16 Alan Modra <amodra@bigpond.net.au>
+
+ * hppa.h (completer_chars): #if 0 out.
+
+ * ns32k.h (struct ns32k_opcode): Constify "name", "operands" and
+ "default_args".
+ (struct not_wot): Constify "args".
+ (struct not): Constify "name".
+ (numopcodes): Delete.
+ (endop): Delete.
+
+2002-12-13 Alan Modra <amodra@bigpond.net.au>
+
+ * pj.h (pj_opc_info_t): Add union.
+
+2002-12-04 David Mosberger <davidm@hpl.hp.com>
+
+ * ia64.h: Fix copyright message.
+ (IA64_OPND_AR_CSD): New operand kind.
+
+2002-12-03 Richard Henderson <rth@redhat.com>
+
+ * ia64.h (enum ia64_opnd): Add IA64_OPND_LDXMOV.
+
+2002-12-03 Alan Modra <amodra@bigpond.net.au>
+
+ * cgen.h (struct cgen_maybe_multi_ifield): Add "const PTR p" to union.
+ Constify "leaf" and "multi".
+
+2002-11-19 Klee Dienes <kdienes@apple.com>
+
+ * h8300.h (h8_opcode): Remove 'noperands', 'idx', and 'size'
+ fields.
+ (h8_opcodes). Modify initializer and initializer macros to no
+ longer initialize the removed fields.
+
+2002-11-19 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * tic4x.h (c4x_insts): Fixed LDHI constraint
+
+2002-11-18 Klee Dienes <kdienes@apple.com>
+
+ * h8300.h (h8_opcode): Remove 'length' field.
+ (h8_opcodes): Mark as 'const' (both the declaration and
+ definition). Modify initializer and initializer macros to no
+ longer initialize the length field.
+
+2002-11-18 Klee Dienes <kdienes@apple.com>
+
+ * arc.h (arc_ext_opcodes): Declare as extern.
+ (arc_ext_operands): Declare as extern.
+ * i860.h (i860_opcodes): Declare as const.
+
+2002-11-18 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * tic4x.h: File reordering. Added enhanced opcodes.
+
+2002-11-16 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * tic4x.h: Major rewrite of entire file. Define instruction
+ classes, and put each instruction into a class.
+
+2002-11-11 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * tic4x.h: Added new opcodes and corrected some bugs. Add support
+ for new DSP types.
+
+2002-10-14 Alan Modra <amodra@bigpond.net.au>
+
+ * cgen.h: Test __BFD_H_SEEN__ rather than BFD_VERSION_DATE.
+
+2002-09-30 Gavin Romig-Koch <gavin@redhat.com>
+ Ken Raeburn <raeburn@cygnus.com>
+ Aldy Hernandez <aldyh@redhat.com>
+ Eric Christopher <echristo@redhat.com>
+ Richard Sandiford <rsandifo@redhat.com>
+
+ * mips.h: Update comment for new opcodes.
+ (OP_MASK_VECBYTE, OP_SH_VECBYTE): New.
+ (OP_MASK_VECALIGN, OP_SH_VECALIGN): New.
+ (INSN_4111, INSN_4120, INSN_5400, INSN_5500): New.
+ (CPU_VR4120, CPU_VR5400, CPU_VR5500): New.
+ (OPCODE_IS_MEMBER): Handle the new CPU_* values and INSN_* flags.
+ Don't match CPU_R4111 with INSN_4100.
+
+2002-08-19 Elena Zannoni <ezannoni@redhat.com>
+
+ From matthew green <mrg@redhat.com>
+
+ * ppc.h (PPC_OPCODE_SPE): New opcode flag for Powerpc e500
+ instructions.
+ (PPC_OPCODE_ISEL, PPC_OPCODE_BRLOCK, PPC_OPCODE_PMR,
+ PPC_OPCODE_CACHELCK, PPC_OPCODE_RFMCI): New opcode flags for the
+ e500x2 Integer select, branch locking, performance monitor,
+ cache locking and machine check APUs, respectively.
+ (PPC_OPCODE_EFS): New opcode type for efs* instructions.
+ (PPC_OPCODE_CLASSIC): New opcode type for Classic PowerPC instructions.
+
+2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
+
+ * m68hc11.h (M6812_OP_PAGE): Define to identify call operand.
+ (M68HC12_BANK_VIRT, M68HC12_BANK_MASK, M68HC12_BANK_BASE,
+ M68HC12_BANK_SHIFT, M68HC12_BANK_PAGE_MASK): Define for 68HC12
+ memory banks.
+ (M6811_OC1M5, M6811_OC1M4, M6811_MODF): Fix value.
+
+2002-07-09 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * mips.h (INSN_MIPS16): New define.
+
+2002-07-08 Alan Modra <amodra@bigpond.net.au>
+
+ * i386.h: Remove IgnoreSize from movsx and movzx.
+
+2002-06-08 Alan Modra <amodra@bigpond.net.au>
+
+ * a29k.h: Replace CONST with const.
+ (CONST): Don't define.
+ * convex.h: Replace CONST with const.
+ (CONST): Don't define.
+ * dlx.h: Replace CONST with const.
+ * or32.h (CONST): Don't define.
+
+2002-05-30 Chris G. Demetriou <cgd@broadcom.com>
+
+ * mips.h (OP_SH_ALN, OP_MASK_ALN, OP_SH_VSEL, OP_MASK_VSEL)
+ (MDMX_FMTSEL_IMM_QH, MDMX_FMTSEL_IMM_OB, MDMX_FMTSEL_VEC_QH)
+ (MDMX_FMTSEL_VEC_OB, INSN_READ_MDMX_ACC, INSN_WRITE_MDMX_ACC)
+ (INSN_MDMX): New constants, for MDMX support.
+ (opcode character list): Add "O", "Q", "X", "Y", and "Z" for MDMX.
+
+2002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
+
+ * dlx.h: New file.
+
+2002-05-25 Alan Modra <amodra@bigpond.net.au>
+
+ * ia64.h: Use #include "" instead of <> for local header files.
+ * sparc.h: Likewise.
+
+2002-05-22 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * mips.h: Add M_DROL, M_DROL_I, M_DROR, M_DROR_I macro cases.
+
+2002-05-17 Andrey Volkov <avolkov@sources.redhat.com>
+
+ * h8300.h: Corrected defs of all control regs
+ and eepmov instr.
+
+2002-04-11 Alan Modra <amodra@bigpond.net.au>
+
+ * i386.h: Add intel mode cmpsd and movsd.
+ Put them before SSE2 insns, so that rep prefix works.
+
+2002-03-15 Chris G. Demetriou <cgd@broadcom.com>
+
+ * mips.h (INSN_MIPS3D): New definition used to mark MIPS-3D
+ instructions.
+ (OPCODE_IS_MEMBER): Adjust comments to indicate that ASE bit masks
+ may be passed along with the ISA bitmask.
+
+2002-03-05 Paul Koning <pkoning@equallogic.com>
+
+ * pdp11.h: Add format codes for float instruction formats.
+
+2002-02-25 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc.h (PPC_OPCODE_POWER4, PPC_OPCODE_NOPOWER4): Define.
+
+Mon Feb 18 17:31:48 CET 2002 Jan Hubicka <jh@suse.cz>
+
+ * i386.h (push,pop): Fix Reg64 to WordReg to allow 16bit operands.
+
+Mon Feb 11 12:53:19 CET 2002 Jan Hubicka <jh@suse.cz>
+
+ * i386.h (push,pop): Allow 16bit operands in 64bit mode.
+ (xchg): Fix.
+ (in, out): Disable 64bit operands.
+ (call, jmp): Avoid REX prefixes.
+ (jcxz): Prohibit in 64bit mode
+ (jrcxz, loop): Add 64bit variants.
+ (movq): Fix patterns.
+ (movmskps, pextrw, pinstrw): Add 64bit variants.
+
+2002-01-31 Ivan Guzvinec <ivang@opencores.org>
+
+ * or32.h: New file.
+
+2002-01-22 Graydon Hoare <graydon@redhat.com>
+
+ * cgen.h (CGEN_MAYBE_MULTI_IFLD): New structure.
+ (CGEN_OPERAND): Add CGEN_MAYBE_MULTI_IFLD field.
+
+2002-01-21 Thomas Klausner <wiz@danbala.ifoer.tuwien.ac.at>
+
+ * h8300.h: Comment typo fix.
+
+2002-01-03 matthew green <mrg@redhat.com>
+
+ * ppc.h (PPC_OPCODE_BOOKE): BookE is not Motorola specific.
+ (PPC_OPCODE_BOOKE64): Likewise.
+
+Mon Dec 31 16:45:41 2001 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h (call, ret): Move to end of table.
+ (addb, addib): PA2.0 variants should have been PA2.0W.
+ (ldw, ldh, ldb, stw, sth, stb, stwa): Reorder to keep disassembler
+ happy.
+ (fldw, fldd, fstw, fstd, bb): Likewise.
+ (short loads/stores): Tweak format specifier slightly to keep
+ disassembler happy.
+ (indexed loads/stores): Likewise.
+ (absolute loads/stores): Likewise.
+
+2001-12-04 Alexandre Oliva <aoliva@redhat.com>
+
+ * d10v.h (OPERAND_NOSP): New macro.
+
+2001-11-29 Alexandre Oliva <aoliva@redhat.com>
+
+ * d10v.h (OPERAND_SP): New macro.
+
+2001-11-15 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc.h (struct powerpc_operand <insert, extract>): Add dialect param.
+
+2001-11-11 Timothy Wall <twall@alum.mit.edu>
+
+ * tic54x.h: Revise opcode layout; don't really need a separate
+ structure for parallel opcodes.
+
+2001-11-13 Zack Weinberg <zack@codesourcery.com>
+ Alan Modra <amodra@bigpond.net.au>
+
+ * i386.h (i386_optab): Add entries for "sldr", "smsw" and "str" to
+ accept WordReg.
+
+2001-11-04 Chris Demetriou <cgd@broadcom.com>
+
+ * mips.h (OPCODE_IS_MEMBER): Remove extra space.
+
+2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * mmix.h: New file.
+
+2001-10-18 Chris Demetriou <cgd@broadcom.com>
+
+ * mips.h (OPCODE_IS_MEMBER): Add a no-op term to the end
+ of the expression, to make source code merging easier.
+
+2001-10-17 Chris Demetriou <cgd@broadcom.com>
+
+ * mips.h: Sort coprocessor instruction argument characters
+ in comment, add a few more words of description for "H".
+
+2001-10-17 Chris Demetriou <cgd@broadcom.com>
+
+ * mips.h (INSN_SB1): New cpu-specific instruction bit.
+ (OPCODE_IS_MEMBER): Allow instructions matching INSN_SB1
+ if cpu is CPU_SB1.
+
+2001-10-17 matthew green <mrg@redhat.com>
+
+ * ppc.h (PPC_OPCODE_BOOKE64): Fix typo.
+
+2001-10-12 matthew green <mrg@redhat.com>
+
+ * ppc.h (PPC_OPCODE_BOOKE, PPC_OPCODE_BOOKE64, PPC_OPCODE_403): New
+ opcode flags for BookE 32-bit, BookE 64-bit and PowerPC 403
+ instructions, respectively.
+
+2001-09-27 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * v850.h: Remove spurious comment.
+
+2001-09-21 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * h8300.h: Fix compile time warning messages
+
+2001-09-04 Richard Henderson <rth@redhat.com>
+
+ * alpha.h (struct alpha_operand): Pack elements into bitfields.
+
+2001-08-31 Eric Christopher <echristo@redhat.com>
+
+ * mips.h: Remove CPU_MIPS32_4K.
+
+2001-08-27 Torbjorn Granlund <tege@swox.com>
+
+ * ppc.h (PPC_OPERAND_DS): Define.
+
+2001-08-25 Andreas Jaeger <aj@suse.de>
+
+ * d30v.h: Fix declaration of reg_name_cnt.
+
+ * d10v.h: Fix declaration of d10v_reg_name_cnt.
+
+ * arc.h: Add prototypes from opcodes/arc-opc.c.
+
+2001-08-16 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * mips.h (INSN_10000): Define.
+ (OPCODE_IS_MEMBER): Check for INSN_10000.
+
+2001-08-10 Alan Modra <amodra@one.net.au>
+
+ * ppc.h: Revert 2001-08-08.
+
+2001-08-10 Richard Sandiford <rsandifo@redhat.com>
+
+ * mips.h (INSN_GP32): Remove.
+ (OPCODE_IS_MEMBER): Remove gp32 parameter.
+ (M_MOVE): New macro identifier.
+
+2001-08-08 Alan Modra <amodra@one.net.au>
+
+ 1999-10-25 Torbjorn Granlund <tege@swox.com>
+ * ppc.h (struct powerpc_operand): New field `reloc'.
+
+2001-08-01 Aldy Hernandez <aldyh@redhat.com>
+
+ * mips.h (INSN_ISA_MASK): Nuke bits 12-15.
+
+2001-07-12 Jeff Johnston <jjohnstn@redhat.com>
+
+ * cgen.h (CGEN_INSN): Add regex support.
+ (build_insn_regex): Declare.
+
+2001-07-11 Frank Ch. Eigler <fche@redhat.com>
+
+ * cgen.h (CGEN_MACH): Add insn_chunk_bitsize field.
+ (cgen_cpu_desc): Ditto.
+
+2001-07-07 Ben Elliston <bje@redhat.com>
+
+ * m88k.h: Clean up and reformat. Remove unused code.
+
+2001-06-14 Geoffrey Keating <geoffk@redhat.com>
+
+ * cgen.h (cgen_keyword): Add nonalpha_chars field.
+
+2001-05-23 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * mips.h (CPU_R12000): Define.
+
+2001-05-23 John Healy <jhealy@redhat.com>
+
+ * cgen.h: Increased CGEN_MAX_SYNTAX_ELEMENTS to 48.
+
+2001-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * mips.h (INSN_ISA_MASK): Define.
+
+2001-05-12 Alan Modra <amodra@one.net.au>
+
+ * i386.h (i386_optab): Second operand of cvtps2dq is an xmm reg,
+ not an mmx reg. Swap xmm/mmx regs on both movdq2q and movq2dq,
+ and use InvMem as these insns must have register operands.
+
+2001-05-04 Alan Modra <amodra@one.net.au>
+
+ * i386.h (i386_optab): Move InvMem to first operand of pmovmskb
+ and pextrw to swap reg/rm assignments.
+
+2001-04-05 Hans-Peter Nilsson <hp@axis.com>
+
+ * cris.h (enum cris_insn_version_usage): Correct comment for
+ cris_ver_v3p.
+
+2001-03-24 Alan Modra <alan@linuxcare.com.au>
+
+ * i386.h (i386_optab): Correct entry for "movntdq". Add "punpcklqdq".
+ Add InvMem to first operand of "maskmovdqu".
+
+2001-03-22 Hans-Peter Nilsson <hp@axis.com>
+
+ * cris.h (ADD_PC_INCR_OPCODE): New macro.
+
+2001-03-21 Kazu Hirata <kazu@hxi.com>
+
+ * h8300.h: Fix formatting.
+
+2001-03-22 Alan Modra <alan@linuxcare.com.au>
+
+ * i386.h (i386_optab): Add paddq, psubq.
+
+2001-03-19 Alan Modra <alan@linuxcare.com.au>
+
+ * i386.h (REGNAM_AL, REGNAM_AX, REGNAM_EAX): Define.
+
+2001-02-28 Igor Shevlyakov <igor@windriver.com>
+
+ * m68k.h: new defines for Coldfire V4. Update mcf to know
+ about mcf5407.
+
+2001-02-18 lars brinkhoff <lars@nocrew.org>
+
+ * pdp11.h: New file.
+
+2001-02-12 Jan Hubicka <jh@suse.cz>
+
+ * i386.h (i386_optab): SSE integer converison instructions have
+ 64bit versions on x86-64.
+
+2001-02-10 Nick Clifton <nickc@redhat.com>
+
+ * mips.h: Remove extraneous whitespace. Formating change to allow
+ for future contribution.
+
+2001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * s390.h: New file.
+
+2001-02-02 Patrick Macdonald <patrickm@redhat.com>
+
+ * cgen.h (CGEN_SYNTAX_CHAR_TYPE): Typedef as unsigned short.
+ (CGEN_MAX_SYNTAX_ELEMENTS): Rename from CGEN_MAX_SYNTAX_BYTES.
+ (CGEN_SYNTAX): Define using CGEN_MAX_SYNTAX_ELEMENTS.
+
+2001-01-24 Karsten Keil <kkeil@suse.de>
+
+ * i386.h (i386_optab): Fix swapgs
+
+2001-01-14 Alan Modra <alan@linuxcare.com.au>
+
+ * hppa.h: Describe new '<' and '>' operand types, and tidy
+ existing comments.
+ (pa_opcodes): Add entries for missing wide mode ldi,ldo,ldw,stw.
+ Remove duplicate "ldw j(s,b),x". Sort some entries.
+
+2001-01-13 Jan Hubicka <jh@suse.cz>
+
+ * i386.h (i386_optab): Fix pusha and ret templates.
+
+2001-01-11 Peter Targett <peter.targett@arccores.com>
+
+ * arc.h (ARC_MACH_5, ARC_MACH_6, ARC_MACH_7, ARC_MACH_8): New
+ definitions for masking cpu type.
+ (arc_ext_operand_value) New structure for storing extended
+ operands.
+ (ARC_OPERAND_*) Flags for operand values.
+
+2001-01-10 Jan Hubicka <jh@suse.cz>
+
+ * i386.h (pinsrw): Add.
+ (pshufw): Remove.
+ (cvttpd2dq): Fix operands.
+ (cvttps2dq): Likewise.
+ (movq2q): Rename to movdq2q.
+
+2001-01-10 Richard Schaal <richard.schaal@intel.com>
+
+ * i386.h: Correct movnti instruction.
+
+2001-01-09 Jeff Johnston <jjohnstn@redhat.com>
+
+ * cgen.h (CGEN_SYNTAX_CHAR_TYPE): New typedef based on max number
+ of operands (unsigned char or unsigned short).
+ (CGEN_SYNTAX): Changed to make array CGEN_SYNTAX_CHAR_TYPE.
+ (CGEN_SYNTAX_CHAR): Changed to cast to unsigned char.
+
+2001-01-05 Jan Hubicka <jh@suse.cz>
+
+ * i386.h (i386_optab): Make [sml]fence template to use immext field.
+
+2001-01-03 Jan Hubicka <jh@suse.cz>
+
+ * i386.h (i386_optab): Fix 64bit pushf template; Add instructions
+ introduced by Pentium4
+
+2000-12-30 Jan Hubicka <jh@suse.cz>
+
+ * i386.h (i386_optab): Add "rex*" instructions;
+ add swapgs; disable jmp/call far direct instructions for
+ 64bit mode; add syscall and sysret; disable registers for 0xc6
+ template. Add 'q' suffixes to extendable instructions, disable
+ obsolete instructions, add new sign/zero extension ones.
+ (i386_regtab): Add extended registers.
+ (*Suf): Add No_qSuf.
+ (q_Suf, wlq_Suf, bwlq_Suf): New.
+
+2000-12-20 Jan Hubicka <jh@suse.cz>
+
+ * i386.h (i386_optab): Replace "Imm" with "EncImm".
+ (i386_regtab): Add flags field.
+
+2000-12-12 Nick Clifton <nickc@redhat.com>
+
+ * mips.h: Fix formatting.
+
+2000-12-01 Chris Demetriou <cgd@sibyte.com>
+
+ mips.h (OP_MASK_SYSCALL, OP_SH_SYSCALL): Delete.
+ (OP_MASK_CODE20, OP_SH_CODE20): Define, with values of old
+ OP_*_SYSCALL definitions.
+ (OP_SH_CODE19, OP_MASK_CODE19): Define, for use as
+ 19 bit wait codes.
+ (MIPS operand specifier comments): Remove 'm', add 'U' and
+ 'J', and update the meaning of 'B' so that it's more general.
+
+ * mips.h (INSN_ISA1, INSN_ISA2, INSN_ISA3, INSN_ISA4,
+ INSN_ISA5): Renumber, redefine to mean the ISA at which the
+ instruction was added.
+ (INSN_ISA32): New constant.
+ (INSN_4650, INSN_4010, INSN_4100, INSN_3900, INSN_GP32):
+ Renumber to avoid new and/or renumbered INSN_* constants.
+ (INSN_MIPS32): Delete.
+ (ISA_UNKNOWN): New constant to indicate unknown ISA.
+ (ISA_MIPS1, ISA_MIPS2, ISA_MIPS3, ISA_MIPS4, ISA_MIPS5,
+ ISA_MIPS32): New constants, defined to be the mask of INSN_*
+ constants available at that ISA level.
+ (CPU_UNKNOWN): New constant to indicate unknown CPU.
+ (CPU_4K, CPU_MIPS32_4K): Rename the former to the latter,
+ define it with a unique value.
+ (OPCODE_IS_MEMBER): Update for new ISA membership-related
+ constant meanings.
+
+ * mips.h (INSN_ISA64, ISA_MIPS5, ISA_MIPS64): New
+ definitions.
+
+ * mips.h (CPU_SB1): New constant.
+
+2000-10-20 Jakub Jelinek <jakub@redhat.com>
+
+ * sparc.h (enum sparc_opcode_arch_val): Add SPARC_OPCODE_ARCH_V9B.
+ Note that '3' is used for siam operand.
+
+2000-09-22 Jim Wilson <wilson@cygnus.com>
+
+ * ia64.h (enum ia64_dependency_semantics): Add IA64_DVS_STOP.
+
+2000-09-13 Anders Norlander <anorland@acc.umu.se>
+
+ * mips.h: Use defines instead of hard-coded processor numbers.
+ (CPU_R2000, CPU_R3000, CPU_R3900, CPU_R4000, CPU_R4010,
+ CPU_VR4100, CPU_R4111, CPU_R4300, CPU_R4400, CPU_R4600, CPU_R4650,
+ CPU_R5000, CPU_R6000, CPU_R8000, CPU_R10000, CPU_MIPS32, CPU_4K,
+ CPU_4KC, CPU_4KM, CPU_4KP): Define..
+ (OPCODE_IS_MEMBER): Use new defines.
+ (OP_MASK_SEL, OP_SH_SEL): Define.
+ (OP_MASK_CODE20, OP_SH_CODE20): Define.
+ Add 'P' to used characters.
+ Use 'H' for coprocessor select field.
+ Use 'm' for 20 bit breakpoint code.
+ Document new arg characters and add to used characters.
+ (INSN_MIPS32): New define for MIPS32 extensions.
+ (OPCODE_IS_MEMBER): Recognize MIPS32 instructions.
+
+2000-09-05 Alan Modra <alan@linuxcare.com.au>
+
+ * hppa.h: Mention cz completer.
+
+2000-08-16 Jim Wilson <wilson@cygnus.com>
+
+ * ia64.h (IA64_OPCODE_POSTINC): New.
+
+2000-08-15 H.J. Lu <hjl@gnu.org>
+
+ * i386.h: Swap the Intel syntax "movsx"/"movzx" due to the
+ IgnoreSize change.
+
+2000-08-08 Jason Eckhardt <jle@cygnus.com>
+
+ * i860.h: Small formatting adjustments.
+
+2000-07-29 Marek Michalkiewicz <marekm@linux.org.pl>
+
+ * avr.h (AVR_UNDEF_P, AVR_SKIP_P, AVR_DISP0_P): New macros.
+ Move related opcodes closer to each other.
+ Minor changes in comments, list undefined opcodes.
+
+2000-07-26 Dave Brolley <brolley@redhat.com>
+
+ * cgen.h (cgen_hw_lookup_by_num): Second parameter is unsigned.
+
+2000-07-22 Jason Eckhardt <jle@cygnus.com>
+
+ * i860.h (btne, bte, bla): Changed these opcodes
+ to use sbroff ('r') instead of split16 ('s').
+ (J, K, L, M): New operand types for 16-bit aligned fields.
+ (ld.x, {p}fld.x, fst.x, pst.d): Changed these opcodes to
+ use I, J, K, L, M instead of just I.
+ (T, U): New operand types for split 16-bit aligned fields.
+ (st.x): Changed these opcodes to use S, T, U instead of just S.
+ (andh, andnoth, orh, xorh): Deleted 3-register forms as they do not
+ exist on the i860.
+ (pfgt.sd, pfle.sd): Deleted these as they do not exist on the i860.
+ (pfeq.ss, pfeq.dd): New opcodes.
+ (st.s): Fixed incorrect mask bits.
+ (fmlow): Fixed incorrect mask bits.
+ (fzchkl, pfzchkl): Fixed incorrect mask bits.
+ (faddz, pfaddz): Fixed incorrect mask bits.
+ (form, pform): Fixed incorrect mask bits.
+ (pfld.l): Fixed incorrect mask bits.
+ (fst.q): Fixed incorrect mask bits.
+ (all floating point opcodes): Fixed incorrect mask bits for
+ handling of dual bit.
+
+2000-07-20 Hans-Peter Nilsson <hp@axis.com>
+
+ cris.h: New file.
+
+2000-06-26 Marek Michalkiewicz <marekm@linux.org.pl>
+
+ * avr.h (AVR_ISA_WRAP): Remove, now assumed if not AVR_ISA_MEGA.
+ (AVR_ISA_ESPM): Remove, because ESPM removed in databook update.
+ (AVR_ISA_85xx): Remove, all uses changed back to AVR_ISA_2xxx.
+ (AVR_ISA_M83): Define for ATmega83, ATmega85.
+ (espm): Remove, because ESPM removed in databook update.
+ (eicall, eijmp): Move to the end of opcode table.
+
+2000-06-18 Stephane Carrez <stcarrez@worldnet.fr>
+
+ * m68hc11.h: New file for support of Motorola 68hc11.
+
+Fri Jun 9 21:51:50 2000 Denis Chertykov <denisc@overta.ru>
+
+ * avr.h: clr,lsl,rol, ... moved after add,adc, ...
+
+Wed Jun 7 21:39:54 2000 Denis Chertykov <denisc@overta.ru>
+
+ * avr.h: New file with AVR opcodes.
+
+Wed Apr 12 17:11:20 2000 Donald Lindsay <dlindsay@hound.cygnus.com>
+
+ * d10v.h: added ALONE attribute for d10v_opcode.exec_type.
+
+2000-05-23 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * i386.h: Allow d suffix on iret, and add DefaultSize modifier.
+
+2000-05-17 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * i386.h: Use sl_FP, not sl_Suf for fild.
+
+2000-05-16 Frank Ch. Eigler <fche@redhat.com>
+
+ * cgen.h (CGEN_MAX_SYNTAX_BYTES): Increase to 32. Check that
+ it exceeds CGEN_ACTUAL_MAX_SYNTAX_BYTES, if set.
+ (CGEN_MAX_IFMT_OPERANDS): Increase to 16. Check that it exceeds
+ CGEN_ACTUAL_MAX_IFMT_OPERANDS, if set.
+
+2000-05-13 Alan Modra <alan@linuxcare.com.au>,
+
+ * i386.h (i386_optab): Cpu686 for sysenter,sysexit,fxsave,fxrestore.
+
+2000-05-13 Alan Modra <alan@linuxcare.com.au>,
+ Alexander Sokolov <robocop@netlink.ru>
+
+ * i386.h (i386_optab): Add cpu_flags for all instructions.
+
+2000-05-13 Alan Modra <alan@linuxcare.com.au>
+
+ From Gavin Romig-Koch <gavin@cygnus.com>
+ * i386.h (wld_Suf): Define. Use on pushf, popf, pusha, popa.
+
+2000-05-04 Timothy Wall <twall@cygnus.com>
+
+ * tic54x.h: New.
+
+2000-05-03 J.T. Conklin <jtc@redback.com>
+
+ * ppc.h (PPC_OPCODE_ALTIVEC): New opcode flag for vector unit.
+ (PPC_OPERAND_VR): New operand flag for vector registers.
+
+2000-05-01 Kazu Hirata <kazu@hxi.com>
+
+ * h8300.h (EOP): Add missing initializer.
+
+Fri Apr 21 15:03:37 2000 Jason Eckhardt <jle@cygnus.com>
+
+ * hppa.h (pa_opcodes): New opcodes for PA2.0 wide mode
+ forms of ld/st{b,h,w,d} and fld/fst{w,d} (16-bit displacements).
+ New operand types l,y,&,fe,fE,fx added to support above forms.
+ (pa_opcodes): Replaced usage of 'x' as source/target for
+ floating point double-word loads/stores with 'fx'.
+
+Fri Apr 21 13:20:53 2000 Richard Henderson <rth@cygnus.com>
+ David Mosberger <davidm@hpl.hp.com>
+ Timothy Wall <twall@cygnus.com>
+ Jim Wilson <wilson@cygnus.com>
+
+ * ia64.h: New file.
+
+2000-03-27 Nick Clifton <nickc@cygnus.com>
+
+ * d30v.h (SHORT_A1): Fix value.
+ (SHORT_AR): Renumber so that it is at the end of the list of short
+ instructions, not the end of the list of long instructions.
+
+2000-03-26 Alan Modra <alan@linuxcare.com>
+
+ * i386.h: (UNIXWARE_COMPAT): Rename to SYSV386_COMPAT as the
+ problem isn't really specific to Unixware.
+ (OLDGCC_COMPAT): Define.
+ (i386_optab): If !OLDGCC_COMPAT, don't handle fsubp etc. with
+ destination %st(0).
+ Fix lots of comments.
+
+2000-03-02 J"orn Rennecke <amylaar@cygnus.co.uk>
+
+ * d30v.h:
+ (SHORT_B2r, SHORT_B3, SHORT_B3r, SHORT_B3b, SHORT_B3br): Updated.
+ (SHORT_D1r, SHORT_D2, SHORT_D2r, SHORT_D2Br, SHORT_U): Updated.
+ (SHORT_F, SHORT_AF, SHORT_T, SHORT_A5, SHORT_CMP, SHORT_CMPU): Updated.
+ (SHORT_A1, SHORT_AA, SHORT_RA, SHORT_MODINC, SHORT_MODDEC): Updated.
+ (SHORT_C1, SHORT_C2, SHORT_UF, SHORT_A2, SHORT_NONE, LONG): Updated.
+ (LONG_U, LONG_Ur, LONG_CMP, LONG_M, LONG_M2, LONG_2, LONG_2r): Updated.
+ (LONG_2b, LONG_2br, LONG_D, LONG_Dr, LONG_Dbr): Updated.
+
+2000-02-25 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h (fild, fistp): Change intel d_Suf form to fildd and
+ fistpd without suffix.
+
+2000-02-24 Nick Clifton <nickc@cygnus.com>
+
+ * cgen.h (cgen_cpu_desc): Rename field 'flags' to
+ 'signed_overflow_ok_p'.
+ Delete prototypes for cgen_set_flags() and cgen_get_flags().
+
+2000-02-24 Andrew Haley <aph@cygnus.com>
+
+ * cgen.h (CGEN_INSN_MACH_HAS_P): New macro.
+ (CGEN_CPU_TABLE): flags: new field.
+ Add prototypes for new functions.
+
+2000-02-24 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h: Add some more UNIXWARE_COMPAT comments.
+
+2000-02-23 Linas Vepstas <linas@linas.org>
+
+ * i370.h: New file.
+
+2000-02-22 Chandra Chavva <cchavva@cygnus.com>
+
+ * d30v.h (FLAG_NOT_WITH_ADDSUBppp): Redefined as operation
+ cannot be combined in parallel with ADD/SUBppp.
+
+2000-02-22 Andrew Haley <aph@cygnus.com>
+
+ * mips.h: (OPCODE_IS_MEMBER): Add comment.
+
+1999-12-30 Andrew Haley <aph@cygnus.com>
+
+ * mips.h (OPCODE_IS_MEMBER): Add gp32 arg, which determines
+ whether synthetic opcodes (e.g. move) generate 32-bit or 64-bit
+ insns.
+
+2000-01-15 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h: Qualify intel mode far call and jmp with x_Suf.
+
+1999-12-27 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h: Add JumpAbsolute qualifier to all non-intel mode
+ indirect jumps and calls. Add FF/3 call for intel mode.
+
+Wed Dec 1 03:05:25 1999 Jeffrey A Law (law@cygnus.com)
+
+ * mn10300.h: Add new operand types. Add new instruction formats.
+
+Wed Nov 24 20:28:58 1999 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h (pa_opcodes): Correctly handle immediate for PA2.0 "bb"
+ instruction.
+
+1999-11-18 Gavin Romig-Koch <gavin@cygnus.com>
+
+ * mips.h (INSN_ISA5): New.
+
+1999-11-01 Gavin Romig-Koch <gavin@cygnus.com>
+
+ * mips.h (OPCODE_IS_MEMBER): New.
+
+1999-10-29 Nick Clifton <nickc@cygnus.com>
+
+ * d30v.h (SHORT_AR): Define.
+
+1999-10-18 Michael Meissner <meissner@cygnus.com>
+
+ * alpha.h (alpha_num_opcodes): Convert to unsigned.
+ (alpha_num_operands): Ditto.
+
+Sun Oct 10 01:46:56 1999 Jerry Quinn <jerry.quinn.adv91@alum.dartmouth.org>
+
+ * hppa.h (pa_opcodes): Add load and store cache control to
+ instructions. Add ordered access load and store.
+
+ * hppa.h (pa_opcode): Add new entries for addb and addib.
+
+ * hppa.h (pa_opcodes): Fix cmpb and cmpib entries.
+
+ * hppa.h (pa_opcodes): Add entries for cmpb and cmpib.
+
+Thu Oct 7 00:12:25 MDT 1999 Diego Novillo <dnovillo@cygnus.com>
+
+ * d10v.h: Add flag RESTRICTED_NUM3 for imm3 operands.
+
+Thu Sep 23 07:08:38 1999 Jerry Quinn <jquinn@nortelnetworks.com>
+
+ * hppa.h (pa_opcodes): Add "call" and "ret". Clean up "b", "bve"
+ and "be" using completer prefixes.
+
+ * hppa.h (pa_opcodes): Add initializers to silence compiler.
+
+ * hppa.h: Update comments about character usage.
+
+Mon Sep 20 03:55:31 1999 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h (pa_opcodes): Fix minor thinkos introduced while cleaning
+ up the new fstw & bve instructions.
+
+Sun Sep 19 10:40:59 1999 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h (pa_opcodes): Add remaining PA2.0 integer load/store
+ instructions.
+
+ * hppa.h (pa_opcodes): Add remaining PA2.0 FP load/store instructions.
+
+ * hppa.h (pa_opcodes): Add long offset double word load/store
+ instructions.
+
+ * hppa.h (pa_opcodes): Add FLAG_STRICT variants of FP loads and
+ stores.
+
+ * hppa.h (pa_opcodes): Handle PA2.0 fcnv, fcmp and ftest insns.
+
+ * hppa.h (pa_opcodes): Finish support for PA2.0 "b" instructions.
+
+ * hppa.h (pa_opcodes): Handle PA2.0 "bve" instructions.
+
+ * hppa.h (pa_opcodes): Add new syntax "be" instructions.
+
+ * hppa.h (pa_opcodes): Note use of 'M' and 'L'.
+
+ * hppa.h (pa_opcodes): Add support for "b,l".
+
+ * hppa.h (pa_opcodes): Add support for "b,gate".
+
+Sat Sep 18 11:41:16 1999 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h (pa_opcodes): Use 'fX' for first register operand
+ in xmpyu.
+
+ * hppa.h (pa_opcodes): Fix mask for probe and probei.
+
+ * hppa.h (pa_opcodes): Fix mask for depwi.
+
+Tue Sep 7 13:44:25 1999 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h (pa_opcodes): Add "addil" variant which has the %r1 as
+ an explicit output argument.
+
+Mon Sep 6 04:41:42 1999 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h: Add strict variants of PA1.0/PA1.1 loads and stores.
+ Add a few PA2.0 loads and store variants.
+
+1999-09-04 Steve Chamberlain <sac@pobox.com>
+
+ * pj.h: New file.
+
+1999-08-29 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h (i386_regtab): Move %st to top of table, and split off
+ other fp reg entries.
+ (i386_float_regtab): To here.
+
+Sat Aug 28 00:25:25 1999 Jerry Quinn <jquinn@nortelnetworks.com>
+
+ * hppa.h (pa_opcodes): Replace 'f' by 'v'. Prefix float register args
+ by 'f'.
+
+ * hppa.h (pa_opcodes): Add extrd, extrw, depd, depdi, depw, depwi.
+ Add supporting args.
+
+ * hppa.h: Document new completers and args.
+ * hppa.h (pa_opcodes): Add 64 bit patterns and pa2.0 syntax for uxor,
+ uaddcm, dcor, addi, add, sub, subi, shladd, rfi, and probe. Add pa2.0
+ extensions for ssm, rsm, pdtlb, pitlb. Add performance instructions
+ pmenb and pmdis.
+
+ * hppa.h (pa_opcodes): Add pa2.0 instructions hadd, hshl,
+ hshr, hsub, mixh, mixw, permh.
+
+ * hppa.h (pa_opcodes): Change completers in instructions to
+ use 'c' prefix.
+
+ * hppa.h (pa_opcodes): Add popbts, new forms of bb, havg,
+ hshladd, hshradd, shrpd, and shrpw instructions. Update arg comments.
+
+ * hppa.h (pa_opcodes): Change fmpyfadd, fmpynfadd, fneg,
+ fnegabs to use 'I' instead of 'F'.
+
+1999-08-21 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h: Add AMD athlon instructions, pfnacc, pfpnacc, pswapd.
+ Document pf2iw and pi2fw as athlon insns. Remove pswapw.
+ Alphabetically sort PIII insns.
+
+Wed Aug 18 18:14:40 1999 Doug Evans <devans@canuck.cygnus.com>
+
+ * cgen.h (CGEN_INSN_MACH_HAS_P): New macro.
+
+Fri Aug 6 09:46:35 1999 Jerry Quinn <jquinn@nortelnetworks.com>
+
+ * hppa.h (pa_opcodes): Add 64 bit versions of or, xor, and,
+ and andcm. Add 32 and 64 bit version of cmpclr, cmpiclr.
+
+ * hppa.h: Document 64 bit condition completers.
+
+Thu Aug 5 16:56:07 1999 Jerry Quinn <jquinn@nortelnetworks.com>
+
+ * hppa.h (pa_opcodes): Change condition args to use '?' prefix.
+
+1999-08-04 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h (i386_optab): Add DefaultSize modifier to all insns
+ that implicitly modify %esp. #undef d_Suf, x_suf, sld_suf,
+ sldx_suf, bwld_Suf, d_FP, x_FP, sld_FP, sldx_FP at end of table.
+
+Wed Jul 28 02:04:24 1999 Jerry Quinn <jquinn@nortelnetworks.com>
+ Jeff Law <law@cygnus.com>
+
+ * hppa.h (pa_opcodes): Add "pushnom" and "pushbts".
+
+ * hppa.h (pa_opcodes): Mark all PA2.0 opcodes with FLAG_STRICT.
+
+ * hppa.h (pa_opcodes): Change xmpyu, fmpyfadd,
+ and fmpynfadd to use 'J' and 'K' instead of 'E' and 'X'.
+
+1999-07-13 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h: Add "undocumented" AMD 3DNow! pf2iw, pi2fw, pswapw insns.
+
+Thu Jul 1 00:17:24 1999 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h (struct pa_opcode): Add new field "flags".
+ (FLAGS_STRICT): Define.
+
+Fri Jun 25 04:22:04 1999 Jerry Quinn <jquinn@nortelnetworks.com>
+ Jeff Law <law@cygnus.com>
+
+ * hppa.h (pa_opcodes): Add pa2.0 clrbts instruction.
+
+ * hppa.h (pa_opcodes): Add entries for mfia and mtsarcm instructions.
+
+1999-06-23 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h: Allow `l' suffix on bswap. Allow `w' suffix on arpl,
+ lldt, lmsw, ltr, str, verr, verw. Add FP flag to fcmov*. Add FP
+ flag to fcomi and friends.
+
+Fri May 28 15:26:11 1999 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h (pa_opcodes): Move integer arithmetic instructions after
+ integer logical instructions.
+
+1999-05-28 Linus Nordberg <linus.nordberg@canit.se>
+
+ * m68k.h: Document new formats `E', `G', `H' and new places `N',
+ `n', `o'.
+
+ * m68k.h: Define mcf5206e, mcf5307, mcf. Document new format `u'
+ and new places `m', `M', `h'.
+
+Thu May 27 04:13:54 1999 Joel Sherrill (joel@OARcorp.com
+
+ * hppa.h (pa_opcodes): Add several processor specific system
+ instructions.
+
+Wed May 26 16:57:44 1999 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h (pa_opcodes): Add second entry for "comb", "comib",
+ "addb", and "addib" to be used by the disassembler.
+
+1999-05-12 Alan Modra <alan@apri.levels.unisa.edu.au>
+
+ * i386.h (ReverseModrm): Remove all occurences.
+ (InvMem): Add to control/debug/test mov insns, movhlps, movlhps,
+ movmskps, pextrw, pmovmskb, maskmovq.
+ Change NoSuf to FP on all MMX, XMM and AMD insns as these all
+ ignore the data size prefix.
+
+ * i386.h (i386_optab, i386_regtab): Add support for PIII SIMD.
+ Mostly stolen from Doug Ledford <dledford@redhat.com>
+
+Sat May 8 23:27:35 1999 Richard Henderson <rth@cygnus.com>
+
+ * ppc.h (PPC_OPCODE_64_BRIDGE): New.
+
+1999-04-14 Doug Evans <devans@casey.cygnus.com>
+
+ * cgen.h (CGEN_ATTR): Delete member num_nonbools.
+ (CGEN_ATTR_TYPE): Update.
+ (CGEN_ATTR_MASK): Number booleans starting at 0.
+ (CGEN_ATTR_VALUE): Update.
+ (CGEN_INSN_ATTR): Update.
+
+Mon Apr 12 23:43:27 1999 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h (fmpyfadd, fmpynfadd, fneg, fnegabs): New PA2.0
+ instructions.
+
+Tue Mar 23 11:24:38 1999 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h (bb, bvb): Tweak opcode/mask.
+
+
+1999-03-22 Doug Evans <devans@casey.cygnus.com>
+
+ * cgen.h (CGEN_ISA,CGEN_MACH): New typedefs.
+ (struct cgen_cpu_desc): Rename member mach to machs. New member isas.
+ New members word_bitsize,default_insn_bitsize,base_insn-bitsize,
+ min_insn_bitsize,max_insn_bitsize,isa_table,mach_table,rebuild_tables.
+ Delete member max_insn_size.
+ (enum cgen_cpu_open_arg): New enum.
+ (cpu_open): Update prototype.
+ (cpu_open_1): Declare.
+ (cgen_set_cpu): Delete.
+
+1999-03-11 Doug Evans <devans@casey.cygnus.com>
+
+ * cgen.h (CGEN_HW_TABLE): Delete `num_init_entries' member.
+ (CGEN_OPERAND_NIL): New macro.
+ (CGEN_OPERAND): New member `type'.
+ (@arch@_cgen_operand_table): Delete decl.
+ (CGEN_OPERAND_INDEX,CGEN_OPERAND_TYPE,CGEN_OPERAND_ENTRY): Delete.
+ (CGEN_OPERAND_TABLE): New struct.
+ (cgen_operand_lookup_by_name,cgen_operand_lookup_by_num): Declare.
+ (CGEN_OPINST): Pointer to operand table entry replaced with enum.
+ (CGEN_CPU_TABLE): New member `isa'. Change member `operand_table',
+ now a CGEN_OPERAND_TABLE. Add CGEN_CPU_DESC arg to
+ {get,set}_{int,vma}_operand.
+ (@arch@_cgen_cpu_open): New arg `isa'.
+ (cgen_set_cpu): Ditto.
+
+Fri Feb 26 02:36:45 1999 Richard Henderson <rth@cygnus.com>
+
+ * i386.h: Fill in cmov and fcmov alternates. Add fcomi short forms.
+
+1999-02-25 Doug Evans <devans@casey.cygnus.com>
+
+ * cgen.h (enum cgen_asm_type): Add CGEN_ASM_NONE.
+ (CGEN_HW_ENTRY): Delete member `next'. Change type of `type' to
+ enum cgen_hw_type.
+ (CGEN_HW_TABLE): New struct.
+ (hw_table): Delete declaration.
+ (CGEN_OPERAND): Change member hw to hw_type, change type from pointer
+ to table entry to enum.
+ (CGEN_OPINST): Ditto.
+ (CGEN_CPU_TABLE): Change member hw_list to hw_table.
+
+Sat Feb 13 14:13:44 1999 Richard Henderson <rth@cygnus.com>
+
+ * alpha.h (AXP_OPCODE_EV6): New.
+ (AXP_OPCODE_NOPAL): Include it.
+
+1999-02-09 Doug Evans <devans@casey.cygnus.com>
+
+ * cgen.h (CGEN_CPU_DESC): Renamed from CGEN_OPCODE_DESC.
+ All uses updated. New members int_insn_p, max_insn_size,
+ parse_operand,insert_operand,extract_operand,print_operand,
+ sizeof_fields,set_fields_bitsize,get_int_operand,set_int_operand,
+ get_vma_operand,set_vma_operand,parse_handlers,insert_handlers,
+ extract_handlers,print_handlers.
+ (CGEN_ATTR): Change type of num_nonbools to unsigned int.
+ (CGEN_ATTR_BOOL_OFFSET): New macro.
+ (CGEN_ATTR_MASK): Subtract it to compute bit number.
+ (CGEN_ATTR_VALUE): Redo bool/nonbool attr calculation.
+ (cgen_opcode_handler): Renamed from cgen_base.
+ (CGEN_HW_ATTR_VALUE): Renamed from CGEN_HW_ATTR, all uses updated.
+ (CGEN_OPERAND_ATTR_VALUE): Renamed from CGEN_OPERAND_ATTR,
+ all uses updated.
+ (CGEN_OPERAND_INDEX): Rewrite to use table entry, not global.
+ (enum cgen_opinst_type): Renamed from cgen_operand_instance_type.
+ (CGEN_IFLD_ATTR_VALUE): Renamed from CGEN_IFLD_ATTR, all uses updated.
+ (CGEN_OPCODE,CGEN_IBASE): New types.
+ (CGEN_INSN): Rewrite.
+ (CGEN_{ASM,DIS}_HASH*): Delete.
+ (init_opcode_table,init_ibld_table): Declare.
+ (CGEN_INSN_ATTR): New type.
+
+Mon Feb 1 21:09:14 1999 Catherine Moore <clm@cygnus.com>
+
+ * i386.h (d_Suf, x_Suf, sld_Suf, sldx_Suf, bwld_Suf): Define.
+ (x_FP, d_FP, dls_FP, sldx_FP): Define.
+ Change *Suf definitions to include x and d suffixes.
+ (movsx): Use w_Suf and b_Suf.
+ (movzx): Likewise.
+ (movs): Use bwld_Suf.
+ (fld): Change ordering. Use sld_FP.
+ (fild): Add Intel Syntax equivalent of fildq.
+ (fst): Use sld_FP.
+ (fist): Use sld_FP.
+ (fstp): Use sld_FP. Add x_FP version.
+ (fistp): LLongMem version for Intel Syntax.
+ (fcom, fcomp): Use sld_FP.
+ (fadd, fiadd, fsub): Use sld_FP.
+ (fsubr): Use sld_FP.
+ (fmul, fimul, fdvi, fidiv, fdivr): Use sld_FP.
+
+1999-01-27 Doug Evans <devans@casey.cygnus.com>
+
+ * cgen.h (enum cgen_mode): Add CGEN_MODE_TARGET_MAX, CGEN_MODE_INT,
+ CGEN_MODE_UINT.
+
+1999-01-16 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h (bv): Fix mask.
+
+1999-01-05 Doug Evans <devans@casey.cygnus.com>
+
+ * cgen.h (CGEN_ATTR_VALUE_TYPE): New typedef.
+ (CGEN_ATTR): Use it.
+ (CGEN_ATTR_TYPE,CGEN_ATTR_ENTRY): Ditto.
+ (CGEN_ATTR_TABLE): New member dfault.
+
+1998-12-30 Gavin Romig-Koch <gavin@cygnus.com>
+
+ * mips.h (MIPS16_INSN_BRANCH): New.
+
+Wed Dec 9 10:38:48 1998 David Taylor <taylor@texas.cygnus.com>
+
+ The following is part of a change made by Edith Epstein
+ <eepstein@sophia.cygnus.com> as part of a project to merge in
+ changes by HP; HP did not create ChangeLog entries.
+
+ * hppa.h (completer_chars): list of chars to not put a space
+ after.
+
+Sun Dec 6 13:21:34 1998 Ian Lance Taylor <ian@cygnus.com>
+
+ * i386.h (i386_optab): Permit w suffix on processor control and
+ status word instructions.
+
+1998-11-30 Doug Evans <devans@casey.cygnus.com>
+
+ * cgen.h (struct cgen_hw_entry): Delete const on attrs member.
+ (struct cgen_keyword_entry): Ditto.
+ (struct cgen_operand): Ditto.
+ (CGEN_IFLD): New typedef, with associated access macros.
+ (CGEN_IFMT): New typedef, with associated access macros.
+ (CGEN_IFMT): Renamed from CGEN_FORMAT. New member `iflds'.
+ (CGEN_IVALUE): New typedef.
+ (struct cgen_insn): Delete const on syntax,attrs members.
+ `format' now points to format data. Type of `value' is now
+ CGEN_IVALUE.
+ (struct cgen_opcode_table): New member ifld_table.
+
+1998-11-18 Doug Evans <devans@casey.cygnus.com>
+
+ * cgen.h (cgen_extract_fn): Update type of `base_insn' arg.
+ (CGEN_OPERAND_INSTANCE): New member `attrs'.
+ (CGEN_OPERAND_INSTANCE_{ATTRS,ATTR}): New macros.
+ (cgen_dis_lookup_insn): Update type of `base_insn' arg.
+ (cgen_opcode_table): Update type of dis_hash fn.
+ (extract_operand): Update type of `insn_value' arg.
+
+Thu Oct 29 11:38:36 1998 Doug Evans <devans@canuck.cygnus.com>
+
+ * cgen.h (CGEN_VERSION_{MAJOR,MINOR,FIXLEVEL}): Delete.
+
+Tue Oct 27 08:57:59 1998 Gavin Romig-Koch <gavin@cygnus.com>
+
+ * mips.h (INSN_MULT): Added.
+
+Tue Oct 20 11:31:34 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h (MAX_MNEM_SIZE): Rename from MAX_OPCODE_SIZE.
+
+Mon Oct 19 12:50:00 1998 Doug Evans <devans@seba.cygnus.com>
+
+ * cgen.h (CGEN_INSN_INT): New typedef.
+ (CGEN_INT_INSN_P): Renamed from CGEN_INT_INSN.
+ (CGEN_INSN_BYTES): Renamed from cgen_insn_t.
+ (CGEN_INSN_BYTES_PTR): New typedef.
+ (CGEN_EXTRACT_INFO): New typedef.
+ (cgen_insert_fn,cgen_extract_fn): Update.
+ (cgen_opcode_table): New member `insn_endian'.
+ (assemble_insn,lookup_insn,lookup_get_insn_operands): Update.
+ (insert_operand,extract_operand): Update.
+ (cgen_get_insn_value,cgen_put_insn_value): Add prototypes.
+
+Fri Oct 9 13:38:13 1998 Doug Evans <devans@seba.cygnus.com>
+
+ * cgen.h (CGEN_ATTR_BOOLS): New macro.
+ (struct CGEN_HW_ENTRY): New member `attrs'.
+ (CGEN_HW_ATTR): New macro.
+ (struct CGEN_OPERAND_INSTANCE): New member `name'.
+ (CGEN_INSN_INVALID_P): New macro.
+
+Mon Oct 5 00:21:07 1998 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h: Add "fid".
+
+Sun Oct 4 21:00:00 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ From Robert Andrew Dale <rob@nb.net>
+ * i386.h (i386_optab): Add AMD 3DNow! instructions.
+ (AMD_3DNOW_OPCODE): Define.
+
+Tue Sep 22 17:53:47 1998 Nick Clifton <nickc@cygnus.com>
+
+ * d30v.h (EITHER_BUT_PREFER_MU): Define.
+
+Mon Aug 10 14:09:38 1998 Doug Evans <devans@canuck.cygnus.com>
+
+ * cgen.h (cgen_insn): #if 0 out element `cdx'.
+
+Mon Aug 3 12:21:57 1998 Doug Evans <devans@seba.cygnus.com>
+
+ Move all global state data into opcode table struct, and treat
+ opcode table as something that is "opened/closed".
+ * cgen.h (CGEN_OPCODE_DESC): New type.
+ (all fns): New first arg of opcode table descriptor.
+ (cgen_set_parse_operand_fn): Add prototype.
+ (cgen_current_machine,cgen_current_endian): Delete.
+ (CGEN_OPCODE_TABLE): New members mach,endian,operand_table,
+ parse_operand_fn,asm_hash_table,asm_hash_table_entries,
+ dis_hash_table,dis_hash_table_entries.
+ (opcode_open,opcode_close): Add prototypes.
+
+ * cgen.h (cgen_insn): New element `cdx'.
+
+Thu Jul 30 21:44:25 1998 Frank Ch. Eigler <fche@cygnus.com>
+
+ * d30v.h (FLAG_LKR): New flag for "left-kills-right" instructions.
+
+Tue Jul 28 10:59:07 1998 Jeffrey A Law (law@cygnus.com)
+
+ * mn10300.h: Add "no_match_operands" field for instructions.
+ (MN10300_MAX_OPERANDS): Define.
+
+Fri Jul 24 11:44:24 1998 Doug Evans <devans@canuck.cygnus.com>
+
+ * cgen.h (cgen_macro_insn_count): Declare.
+
+Tue Jul 21 13:12:13 1998 Doug Evans <devans@seba.cygnus.com>
+
+ * cgen.h (CGEN_VERSION_{MAJOR,MINOR,FIXLEVEL}): Define.
+ (cgen_insert_fn,cgen_extract_fn): New arg `pc'.
+ (get_operand,put_operand): Replaced with get_{int,vma}_operand,
+ set_{int,vma}_operand.
+
+Fri Jun 26 11:09:06 1998 Jeffrey A Law (law@cygnus.com)
+
+ * mn10300.h: Add "machine" field for instructions.
+ (MN103, AM30): Define machine types.
+
+Fri Jun 19 16:09:09 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h: Use FP, not sl_Suf, for fxsave and fxrstor.
+
+1998-06-18 Ulrich Drepper <drepper@cygnus.com>
+
+ * i386.h: Add support for fxsave, fxrstor, sysenter and sysexit.
+
+Sat Jun 13 11:31:35 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h (i386_optab): Add general form of aad and aam. Add ud2a
+ and ud2b.
+ (i386_regtab): Allow cr0..7, db0..7, dr0..7, tr0..7, not just
+ those that happen to be implemented on pentiums.
+
+Tue Jun 9 12:16:01 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h: Change occurences of Data16 to Size16, Data32 to Size32,
+ IgnoreDataSize to IgnoreSize. Flag address and data size prefixes
+ with Size16|IgnoreSize or Size32|IgnoreSize.
+
+Mon Jun 8 12:15:52 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h (REPNE): Rename to REPNE_PREFIX_OPCODE.
+ (REPE): Rename to REPE_PREFIX_OPCODE.
+ (i386_regtab_end): Remove.
+ (i386_prefixtab, i386_prefixtab_end): Remove.
+ (i386_optab): Use NULL as sentinel rather than "" to suit rewrite
+ of md_begin.
+ (MAX_OPCODE_SIZE): Define.
+ (i386_optab_end): Remove.
+ (sl_Suf): Define.
+ (sl_FP): Use sl_Suf.
+
+ * i386.h (i386_optab): Allow 16 bit displacement for `mov
+ mem,acc'. Combine 16 and 32 bit forms of various insns. Allow 16
+ bit form of ljmp. Add IsPrefix modifier to prefixes. Add addr32,
+ data32, dword, and adword prefixes.
+ (i386_regtab): Add BaseIndex modifier to valid 16 bit base/index
+ regs.
+
+Fri Jun 5 23:42:43 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h (i386_regtab): Remove BaseIndex modifier from esp.
+
+ * i386.h: Allow `l' suffix on fld, fst, fstp, fcom, fcomp with
+ register operands, because this is a common idiom. Flag them with
+ a warning. Allow illegal faddp, fsubp, fsubrp, fmulp, fdivp,
+ fdivrp because gcc erroneously generates them. Also flag with a
+ warning.
+
+ * i386.h: Add suffix modifiers to most insns, and tighter operand
+ checks in some cases. Fix a number of UnixWare compatibility
+ issues with float insns. Merge some floating point opcodes, using
+ new FloatMF modifier.
+ (WORD_PREFIX_OPCODE): Rename to DATA_PREFIX_OPCODE for
+ consistency.
+
+ * i386.h: Change occurence of ShortformW to W|ShortForm. Add
+ IgnoreDataSize where appropriate.
+
+Wed Jun 3 18:28:45 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h: (one_byte_segment_defaults): Remove.
+ (two_byte_segment_defaults): Remove.
+ (i386_regtab): Add BaseIndex to 32 bit regs reg_type.
+
+Fri May 15 15:59:04 1998 Doug Evans <devans@seba.cygnus.com>
+
+ * cgen.h (cgen_hw_lookup_by_name): Renamed from cgen_hw_lookup.
+ (cgen_hw_lookup_by_num): Declare.
+
+Thu May 7 09:27:58 1998 Frank Ch. Eigler <fche@cygnus.com>
+
+ * mips.h (OP_{SH,MASK}_CODE2): Added "q" operand format for lower
+ ten bits of MIPS ISA1 "break" instruction, and for "sdbbp"
+
+Thu May 7 02:14:08 1998 Doug Evans <devans@charmed.cygnus.com>
+
+ * cgen.h (cgen_asm_init_parse): Delete.
+ (cgen_save_fixups,cgen_restore_fixups,cgen_swap_fixups): Delete.
+ (cgen_asm_record_register,cgen_asm_finish_insn): Delete.
+
+Mon Apr 27 10:13:11 1998 Doug Evans <devans@seba.cygnus.com>
+
+ * cgen.h (CGEN_ATTR_TYPE): Delete `const', moved to uses.
+ (cgen_asm_finish_insn): Update prototype.
+ (cgen_insn): New members num, data.
+ (CGEN_INSN_TABLE): Members asm_hash, asm_hash_table_size,
+ dis_hash, dis_hash_table_size moved to ...
+ (CGEN_OPCODE_TABLE). Here. Renamed from CGEN_OPCODE_DATA.
+ All uses updated. New members asm_hash_p, dis_hash_p.
+ (CGEN_MINSN_EXPANSION): New struct.
+ (cgen_expand_macro_insn): Declare.
+ (cgen_macro_insn_count): Declare.
+ (get_insn_operands): Update prototype.
+ (lookup_get_insn_operands): Declare.
+
+Tue Apr 21 17:11:32 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h (i386_optab): Change iclrKludge and imulKludge to
+ regKludge. Add operands types for string instructions.
+
+Mon Apr 20 14:40:29 1998 Tom Tromey <tromey@cygnus.com>
+
+ * i386.h (X): Renamed from `Z_' to preserve formatting of opcode
+ table.
+
+Sun Apr 19 13:54:06 1998 Tom Tromey <tromey@cygnus.com>
+
+ * i386.h (Z_): Renamed from `_' to avoid clash with common alias
+ for `gettext'.
+
+Fri Apr 3 12:04:48 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h: Remove NoModrm flag from all insns: it's never checked.
+ Add IsString flag to string instructions.
+ (IS_STRING): Don't define.
+ (LOCK_PREFIX_OPCODE, CS_PREFIX_OPCODE, DS_PREFIX_OPCODE): Define.
+ (ES_PREFIX_OPCODE, FS_PREFIX_OPCODE, GS_PREFIX_OPCODE): Define.
+ (SS_PREFIX_OPCODE): Define.
+
+Mon Mar 30 21:31:56 1998 Ian Lance Taylor <ian@cygnus.com>
+
+ * i386.h: Revert March 24 patch; no more LinearAddress.
+
+Mon Mar 30 10:25:54 1998 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h (i386_optab): Remove fwait (9b) from all floating point
+ instructions, and instead add FWait opcode modifier. Add short
+ form of fldenv and fstenv.
+ (FWAIT_OPCODE): Define.
+
+ * i386.h (i386_optab): Change second operand constraint of `mov
+ sreg,reg|mem' instruction from Reg16|Mem to WordReg|WordMem to
+ allow legal instructions such as `movl %gs,%esi'
+
+Fri Mar 27 18:30:52 1998 Ian Lance Taylor <ian@cygnus.com>
+
+ * h8300.h: Various changes to fully bracket initializers.
+
+Tue Mar 24 18:32:47 1998 H.J. Lu <hjl@gnu.org>
+
+ * i386.h: Set LinearAddress for lidt and lgdt.
+
+Mon Mar 2 10:44:07 1998 Doug Evans <devans@seba.cygnus.com>
+
+ * cgen.h (CGEN_BOOL_ATTR): New macro.
+
+Thu Feb 26 15:54:31 1998 Michael Meissner <meissner@cygnus.com>
+
+ * d30v.h (FLAG_DELAY): New flag for delayed branches/jumps.
+
+Mon Feb 23 10:38:21 1998 Doug Evans <devans@seba.cygnus.com>
+
+ * cgen.h (CGEN_CAT3): Delete. Use CONCAT3 now.
+ (cgen_insn): Record syntax and format entries here, rather than
+ separately.
+
+Tue Feb 17 21:42:56 1998 Nick Clifton <nickc@cygnus.com>
+
+ * cgen.h (CGEN_SYNTAX_MAKE_FIELD): New macro.
+
+Tue Feb 17 16:00:56 1998 Doug Evans <devans@seba.cygnus.com>
+
+ * cgen.h (cgen_insert_fn): Change type of result to const char *.
+ (cgen_parse_{signed,unsigned}_integer): Delete min,max arguments.
+ (CGEN_{INSN,KEYWORD,OPERAND}_NBOOL_ATTRS): Renamed from ..._MAX_ATTRS.
+
+Thu Feb 12 18:30:41 1998 Doug Evans <devans@canuck.cygnus.com>
+
+ * cgen.h (lookup_insn): New argument alias_p.
+
+Thu Feb 12 03:41:00 1998 J"orn Rennecke <amylaar@cygnus.co.uk>
+
+Fix rac to accept only a0:
+ * d10v.h (OPERAND_ACC): Split into:
+ (OPERAND_ACC0, OPERAND_ACC1) .
+ (OPERAND_GPR): Define.
+
+Wed Feb 11 17:31:53 1998 Doug Evans <devans@seba.cygnus.com>
+
+ * cgen.h (CGEN_FIELDS): Define here.
+ (CGEN_HW_ENTRY): New member `type'.
+ (hw_list): Delete decl.
+ (enum cgen_mode): Declare.
+ (CGEN_OPERAND): New member `hw'.
+ (enum cgen_operand_instance_type): Declare.
+ (CGEN_OPERAND_INSTANCE): New type.
+ (CGEN_INSN): New member `operands'.
+ (CGEN_OPCODE_DATA): Make hw_list const.
+ (get_insn_operands,lookup_insn): Add prototypes for.
+
+Tue Feb 3 17:11:23 1998 Doug Evans <devans@seba.cygnus.com>
+
+ * cgen.h (CGEN_INSN_MAX_ATTRS): Renamed from CGEN_MAX_INSN_ATTRS.
+ (CGEN_HW_ENTRY): Move `next' entry to end of struct.
+ (CGEN_KEYWORD_MAX_ATTRS): Renamed from CGEN_MAX_KEYWORD_ATTRS.
+ (CGEN_OPERAND_MAX_ATTRS): Renamed from CGEN_MAX_OPERAND_ATTRS.
+
+Mon Feb 2 19:19:15 1998 Ian Lance Taylor <ian@cygnus.com>
+
+ * cgen.h: Correct typo in comment end marker.
+
+Mon Feb 2 17:10:38 1998 Steve Haworth <steve@pm.cse.rmit.EDU.AU>
+
+ * tic30.h: New file.
+
+Thu Jan 22 17:54:56 1998 Nick Clifton <nickc@cygnus.com>
+
+ * cgen.h: Add prototypes for cgen_save_fixups(),
+ cgen_restore_fixups(), and cgen_swap_fixups(). Change prototype
+ of cgen_asm_finish_insn() to return a char *.
+
+Wed Jan 14 17:21:43 1998 Nick Clifton <nickc@cygnus.com>
+
+ * cgen.h: Formatting changes to improve readability.
+
+Mon Jan 12 11:37:36 1998 Doug Evans <devans@seba.cygnus.com>
+
+ * cgen.h (*): Clean up pass over `struct foo' usage.
+ (CGEN_ATTR): Make unsigned char.
+ (CGEN_ATTR_TYPE): Update.
+ (CGEN_ATTR_{ENTRY,TABLE}): New types.
+ (cgen_base): Move member `attrs' to cgen_insn.
+ (CGEN_KEYWORD): New member `null_entry'.
+ (CGEN_{SYNTAX,FORMAT}): New types.
+ (cgen_insn): Format and syntax separated from each other.
+
+Tue Dec 16 15:15:52 1997 Michael Meissner <meissner@cygnus.com>
+
+ * d30v.h (d30v_opcode): Reorder flags somewhat, add new flags for
+ 2 word load/store, ADDppp/SUBppp, 16/32 bit multiply. Make
+ flags_{used,set} long.
+ (d30v_operand): Make flags field long.
+
+Mon Dec 1 12:24:44 1997 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>
+
+ * m68k.h: Fix comment describing operand types.
+
+Sun Nov 23 22:31:27 1997 Michael Meissner <meissner@cygnus.com>
+
+ * d30v.h (SHORT_CMPU): Add case for cmpu instruction, and move
+ everything else after down.
+
+Tue Nov 18 18:45:14 1997 J"orn Rennecke <amylaar@cygnus.co.uk>
+
+ * d10v.h (OPERAND_FLAG): Split into:
+ (OPERAND_FFLAG, OPERAND_CFLAG) .
+
+Thu Nov 13 11:04:24 1997 Gavin Koch <gavin@cygnus.com>
+
+ * mips.h (struct mips_opcode): Changed comments to reflect new
+ field usage.
+
+Fri Oct 24 22:36:20 1997 Ken Raeburn <raeburn@cygnus.com>
+
+ * mips.h: Added to comments a quick-ref list of all assigned
+ operand type characters.
+ (OP_{MASK,SH}_PERFREG): New macros.
+
+Wed Oct 22 17:28:33 1997 Richard Henderson <rth@cygnus.com>
+
+ * sparc.h: Add '_' and '/' for v9a asr's.
+ Patch from David Miller <davem@vger.rutgers.edu>
+
+Tue Oct 14 13:22:29 1997 Jeffrey A Law (law@cygnus.com)
+
+ * h8300.h: Bit ops with absolute addresses not in the 8 bit
+ area are not available in the base model (H8/300).
+
+Thu Sep 25 13:03:41 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * m68k.h: Remove documentation of ` operand specifier.
+
+Wed Sep 24 19:00:34 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * m68k.h: Document q and v operand specifiers.
+
+Mon Sep 15 18:28:37 1997 Nick Clifton <nickc@cygnus.com>
+
+ * v850.h (struct v850_opcode): Add processors field.
+ (PROCESSOR_V850, PROCESSOR_ALL): New bit constants.
+ (PROCESSOR_V850E, PROCESSOR_NOT_V850): New bit constants.
+ (PROCESSOR_V850EA): New bit constants.
+
+Mon Sep 15 11:29:43 1997 Ken Raeburn <raeburn@cygnus.com>
+
+ Merge changes from Martin Hunt:
+
+ * d30v.h: Allow up to 64 control registers. Add
+ SHORT_A5S format.
+
+ * d30v.h (LONG_Db): New form for delayed branches.
+
+ * d30v.h: (LONG_Db): New form for repeati.
+
+ * d30v.h (SHORT_D2B): New form.
+
+ * d30v.h (SHORT_A2): New form.
+
+ * d30v.h (OPERAND_2REG): Add new operand to indicate 2
+ registers are used. Needed for VLIW optimization.
+
+Mon Sep 8 14:05:45 1997 Doug Evans <dje@canuck.cygnus.com>
+
+ * cgen.h: Move assembler interface section
+ up so cgen_parse_operand_result is defined for cgen_parse_address.
+ (cgen_parse_address): Update prototype.
+
+Tue Sep 2 15:32:32 1997 Nick Clifton <nickc@cygnus.com>
+
+ * v850.h (V850_OPREAND_ADJUST_SHORT_MEMORY): Removed.
+
+Tue Aug 26 12:21:52 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * i386.h (two_byte_segment_defaults): Correct base register 5 in
+ modes 1 and 2 to be ss rather than ds. From Gabriel Paubert
+ <paubert@iram.es>.
+
+ * i386.h: Set ud2 to 0x0f0b. From Gabriel Paubert
+ <paubert@iram.es>.
+
+ * i386.h: Comment fixes for ficom[p]?{s,l} from Gabriel Paubert
+ <paubert@iram.es>.
+
+ * i386.h (JUMP_ON_CX_ZERO): Uncomment (define again).
+ (JUMP_ON_ECX_ZERO): Remove commented out macro.
+
+Fri Aug 22 10:38:29 1997 Nick Clifton <nickc@cygnus.com>
+
+ * v850.h (V850_NOT_R0): New flag.
+
+Mon Aug 18 11:05:58 1997 Nick Clifton <nickc@cygnus.com>
+
+ * v850.h (struct v850_opcode): Remove flags field.
+
+Wed Aug 13 18:45:48 1997 Nick Clifton <nickc@cygnus.com>
+
+ * v850.h (struct v850_opcode): Add flags field.
+ (struct v850_operand): Extend meaning of 'bits' and 'shift'
+ fields.
+ (V850E_INSTRUCTION, V850EA_INSTRUCTION): New flags.
+ (V850E_PUSH_POP, V850E_IMMEDIATE16, V850E_IMMEDIATE32): New flags.
+
+Fri Aug 8 16:58:42 1997 Doug Evans <dje@canuck.cygnus.com>
+
+ * arc.h: New file.
+
+Thu Jul 24 21:16:58 1997 Doug Evans <dje@canuck.cygnus.com>
+
+ * sparc.h (sparc_opcodes): Declare as const.
+
+Thu Jul 10 12:53:25 1997 Jeffrey A Law (law@cygnus.com)
+
+ * mips.h (FP_S, FP_D): Define. Bitmasks indicating if an insn
+ uses single or double precision floating point resources.
+ (INSN_NO_ISA, INSN_ISA1): Define.
+ (cpu specific INSN macros): Tweak into bitmasks outside the range
+ of INSN_ISA field.
+
+Mon Jun 16 14:10:00 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
+
+ * i386.h: Fix pand opcode.
+
+Mon Jun 2 11:35:09 1997 Gavin Koch <gavin@cygnus.com>
+
+ * mips.h: Widen INSN_ISA and move it to a more convenient
+ bit position. Add INSN_3900.
+
+Tue May 20 11:25:29 1997 Gavin Koch <gavin@cygnus.com>
+
+ * mips.h (struct mips_opcode): added new field membership.
+
+Mon May 12 16:26:50 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
+
+ * i386.h (movd): only Reg32 is allowed.
+
+ * i386.h: add fcomp and ud2. From Wayne Scott
+ <wscott@ichips.intel.com>.
+
+Mon May 5 17:16:21 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * i386.h: Add MMX instructions.
+
+Mon May 5 12:45:19 1997 H.J. Lu <hjl@gnu.ai.mit.edu>
+
+ * i386.h: Remove W modifier from conditional move instructions.
+
+Mon Apr 14 14:56:58 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * i386.h: Change the opcodes for fsubp, fsubrp, fdivp, and fdivrp
+ with no arguments to match that generated by the UnixWare
+ assembler.
+
+Thu Apr 10 14:35:00 1997 Doug Evans <dje@canuck.cygnus.com>
+
+ * cgen.h (<cpu>_cgen_assemble_insn): New arg for errmsg.
+ (cgen_parse_operand_fn): Declare.
+ (cgen_init_parse_operand): Declare.
+ (cgen_parse_operand): Renamed from cgen_asm_parse_operand,
+ new argument `want'.
+ (enum cgen_parse_operand_result): Renamed from cgen_asm_result.
+ (enum cgen_parse_operand_type): New enum.
+
+Sat Apr 5 13:14:05 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * i386.h: Revert last patch for the NON_BROKEN_OPCODES cases.
+
+Fri Apr 4 11:46:11 1997 Doug Evans <dje@canuck.cygnus.com>
+
+ * cgen.h: New file.
+
+Fri Apr 4 14:02:32 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * i386.h: Correct opcode values for fsubp, fsubrp, fdivp, and
+ fdivrp.
+
+Tue Mar 25 22:57:26 1997 Stu Grossman (grossman@critters.cygnus.com)
+
+ * v850.h (extract): Make unsigned.
+
+Mon Mar 24 14:38:15 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * i386.h: Add iclr.
+
+Thu Mar 20 19:49:10 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * i386.h: Change DW to W for cmpxchg and xadd, since they don't
+ take a direction bit.
+
+Sat Mar 15 19:03:29 1997 H.J. Lu <hjl@lucon.org>
+
+ * sparc.h (sparc_opcode_lookup_arch): Use full prototype.
+
+Fri Mar 14 15:22:01 1997 Ian Lance Taylor <ian@cygnus.com>
+
+ * sparc.h: Include <ansidecl.h>. Update function declarations to
+ use prototypes, and to use const when appropriate.
+
+Thu Mar 6 14:18:30 1997 Jeffrey A Law (law@cygnus.com)
+
+ * mn10300.h (MN10300_OPERAND_RELAX): Define.
+
+Mon Feb 24 15:15:56 1997 Martin M. Hunt <hunt@pizza.cygnus.com>
+
+ * d10v.h: Change pre_defined_registers to
+ d10v_predefined_registers and reg_name_cnt to d10v_reg_name_cnt.
+
+Sat Feb 22 21:25:00 1997 Dawn Perchik <dawn@cygnus.com>
+
+ * mips.h: Add macros for cop0, cop1 cop2 and cop3.
+ Change mips_opcodes from const array to a pointer,
+ and change bfd_mips_num_opcodes from const int to int,
+ so that we can increase the size of the mips opcodes table
+ dynamically.
+
+Fri Feb 21 16:34:18 1997 Martin M. Hunt <hunt@pizza.cygnus.com>
+
+ * d30v.h (FLAG_X): Remove unused flag.
+
+Tue Feb 18 17:37:20 1997 Martin M. Hunt <hunt@pizza.cygnus.com>
+
+ * d30v.h: New file.
+
+Fri Feb 14 13:16:15 1997 Fred Fish <fnf@cygnus.com>
+
+ * tic80.h (PDS_NAME): Macro to access name field of predefined symbols.
+ (PDS_VALUE): Macro to access value field of predefined symbols.
+ (tic80_next_predefined_symbol): Add prototype.
+
+Mon Feb 10 10:32:17 1997 Fred Fish <fnf@cygnus.com>
+
+ * tic80.h (tic80_symbol_to_value): Change prototype to match
+ change in function, added class parameter.
+
+Thu Feb 6 17:30:15 1997 Fred Fish <fnf@cygnus.com>
+
+ * tic80.h (TIC80_OPERAND_ENDMASK): Add for flagging TIc80
+ endmask fields, which are somewhat weird in that 0 and 32 are
+ treated exactly the same.
+
+Thu Jan 30 13:46:18 1997 Fred Fish <fnf@cygnus.com>
+
+ * tic80.h: Change all the OPERAND defines to use the form (1 << X)
+ rather than a constant that is 2**X. Reorder them to put bits for
+ operands that have symbolic names in the upper bits, so they can
+ be packed into an int where the lower bits contain the value that
+ corresponds to that symbolic name.
+ (predefined_symbo): Add struct.
+ (tic80_predefined_symbols): Declare array of translations.
+ (tic80_num_predefined_symbols): Declare size of that array.
+ (tic80_value_to_symbol): Declare function.
+ (tic80_symbol_to_value): Declare function.
+
+Wed Jan 29 09:37:25 1997 Jeffrey A Law (law@cygnus.com)
+
+ * mn10200.h (MN10200_OPERAND_RELAX): Define.
+
+Sat Jan 18 15:18:59 1997 Fred Fish <fnf@cygnus.com>
+
+ * tic80.h (TIC80_NO_R0_DEST): Add for opcodes where r0 cannot
+ be the destination register.
+
+Thu Jan 16 20:48:55 1997 Fred Fish <fnf@cygnus.com>
+
+ * tic80.h (struct tic80_opcode): Change "format" field to "flags".
+ (FMT_UNUSED, FMT_SI, FMT_LI, FMT_REG): Delete.
+ (TIC80_VECTOR): Define a flag bit for the flags. This one means
+ that the opcode can have two vector instructions in a single
+ 32 bit word and we have to encode/decode both.
+
+Tue Jan 14 19:37:09 1997 Fred Fish <fnf@cygnus.com>
+
+ * tic80.h (TIC80_OPERAND_PCREL): Renamed from
+ TIC80_OPERAND_RELATIVE for PC relative.
+ (TIC80_OPERAND_BASEREL): New flag bit for register
+ base relative.
+
+Mon Jan 13 15:56:38 1997 Fred Fish <fnf@cygnus.com>
+
+ * tic80.h (TIC80_OPERAND_FLOAT): Add for floating point operands.
+
+Mon Jan 6 10:51:15 1997 Fred Fish <fnf@cygnus.com>
+
+ * tic80.h (TIC80_OPERAND_SCALED): Operand may have optional
+ ":s" modifier for scaling.
+
+Sun Jan 5 12:12:19 1997 Fred Fish <fnf@cygnus.com>
+
+ * tic80.h (TIC80_OPERAND_M_SI): Add operand modifier for ":m".
+ (TIC80_OPERAND_M_LI): Ditto
+
+Sat Jan 4 19:02:44 1997 Fred Fish <fnf@cygnus.com>
+
+ * tic80.h (TIC80_OPERAND_BITNUM): Renamed from TIC80_OPERAND_CC_SZ.
+ (TIC80_OPERAND_CC): New define for condition code operand.
+ (TIC80_OPERAND_CR): New define for control register operand.
+
+Fri Jan 3 16:22:23 1997 Fred Fish <fnf@cygnus.com>
+
+ * tic80.h (struct tic80_opcode): Name changed.
+ (struct tic80_opcode): Remove format field.
+ (struct tic80_operand): Add insertion and extraction functions.
+ (TIC80_OPERAND_*): Remove old bogus values, start adding new
+ correct ones.
+ (FMT_*): Ditto.
+
+Tue Dec 31 15:05:41 1996 Michael Meissner <meissner@tiktok.cygnus.com>
+
+ * v850.h (V850_OPERAND_ADJUST_SHORT_MEMORY): New flag to adjust
+ type IV instruction offsets.
+
+Fri Dec 27 22:23:10 1996 Fred Fish <fnf@cygnus.com>
+
+ * tic80.h: New file.
+
+Wed Dec 18 10:06:31 1996 Jeffrey A Law (law@cygnus.com)
+
+ * mn10200.h (MN10200_OPERAND_NOCHECK): Define.
+
+Sat Dec 14 10:48:31 1996 Fred Fish <fnf@ninemoons.com>
+
+ * mn10200.h: Fix comment, mn10200_operand not powerpc_operand.
+ * mn10300.h: Fix comment, mn10300_operand not powerpc_operand.
+ * v850.h: Fix comment, v850_operand not powerpc_operand.
+
+Mon Dec 9 16:45:39 1996 Jeffrey A Law (law@cygnus.com)
+
+ * mn10200.h: Flesh out structures and definitions needed by
+ the mn10200 assembler & disassembler.
+
+Tue Nov 26 10:46:56 1996 Ian Lance Taylor <ian@cygnus.com>
+
+ * mips.h: Add mips16 definitions.
+
+Mon Nov 25 17:56:54 1996 J.T. Conklin <jtc@cygnus.com>
+
+ * m68k.h: Document new <, >, m, n, o and p operand specifiers.
+
+Wed Nov 20 10:59:41 1996 Jeffrey A Law (law@cygnus.com)
+
+ * mn10300.h (MN10300_OPERAND_PCREL): Define.
+ (MN10300_OPERAND_MEMADDR): Define.
+
+Tue Nov 19 13:30:40 1996 Jeffrey A Law (law@cygnus.com)
+
+ * mn10300.h (MN10300_OPERAND_REG_LIST): Define.
+
+Wed Nov 6 13:41:08 1996 Jeffrey A Law (law@cygnus.com)
+
+ * mn10300.h (MN10300_OPERAND_SPLIT): Define.
+
+Tue Nov 5 13:26:12 1996 Jeffrey A Law (law@cygnus.com)
+
+ * mn10300.h (MN10300_OPERAND_EXTENDED): Define.
+
+Mon Nov 4 12:52:48 1996 Jeffrey A Law (law@cygnus.com)
+
+ * mn10300.h (MN10300_OPERAND_REPEATED): Define.
+
+Fri Nov 1 10:31:02 1996 Richard Henderson <rth@tamu.edu>
+
+ * alpha.h: Don't include "bfd.h"; private relocation types are now
+ negative to minimize problems with shared libraries. Organize
+ instruction subsets by AMASK extensions and PALcode
+ implementation.
+ (struct alpha_operand): Move flags slot for better packing.
+
+Tue Oct 29 12:19:10 1996 Jeffrey A Law (law@cygnus.com)
+
+ * v850.h (V850_OPERAND_RELAX): New operand flag.
+
+Thu Oct 10 14:29:11 1996 Jeffrey A Law (law@cygnus.com)
+
+ * mn10300.h (FMT_*): Move operand format definitions
+ here.
+
+Tue Oct 8 14:48:07 1996 Jeffrey A Law (law@cygnus.com)
+
+ * mn10300.h (MN10300_OPERAND_PAREN): Define.
+
+Mon Oct 7 16:52:11 1996 Jeffrey A Law (law@cygnus.com)
+
+ * mn10300.h (mn10300_opcode): Add "format" field.
+ (MN10300_OPERAND_*): Define.
+
+Thu Oct 3 10:33:46 1996 Jeffrey A Law (law@cygnus.com)
+
+ * mn10x00.h: Delete.
+ * mn10200.h, mn10300.h: New files.
+
+Wed Oct 2 21:31:26 1996 Jeffrey A Law (law@cygnus.com)
+
+ * mn10x00.h: New file.
+
+Fri Sep 27 18:26:46 1996 Stu Grossman (grossman@critters.cygnus.com)
+
+ * v850.h: Add new flag to indicate this instruction uses a PC
+ displacement.
+
+Fri Sep 13 14:58:13 1996 Jeffrey A Law (law@cygnus.com)
+
+ * h8300.h (stmac): Add missing instruction.
+
+Sat Aug 31 16:02:03 1996 Jeffrey A Law (law@cygnus.com)
+
+ * v850.h (v850_opcode): Remove "size" field. Add "memop"
+ field.
+
+Fri Aug 23 10:39:08 1996 Jeffrey A Law (law@cygnus.com)
+
+ * v850.h (V850_OPERAND_EP): Define.
+
+ * v850.h (v850_opcode): Add size field.
+
+Thu Aug 22 16:51:25 1996 J.T. Conklin <jtc@rtl.cygnus.com>
+
+ * v850.h (v850_operands): Add insert and extract fields, pointers
+ to functions used to handle unusual operand encoding.
+ (V850_OPERAND_REG, V850_OPERAND_SRG, V850_OPERAND_CC,
+ V850_OPERAND_SIGNED): Defined.
+
+Wed Aug 21 17:45:10 1996 J.T. Conklin <jtc@rtl.cygnus.com>
+
+ * v850.h (v850_operands): Add flags field.
+ (OPERAND_REG, OPERAND_NUM): Defined.
+
+Tue Aug 20 14:52:02 1996 J.T. Conklin <jtc@rtl.cygnus.com>
+
+ * v850.h: New file.
+
+Fri Aug 16 14:44:15 1996 James G. Smith <jsmith@cygnus.co.uk>
+
+ * mips.h (OP_SH_LOCC, OP_SH_HICC, OP_MASK_CC, OP_SH_COP1NORM,
+ OP_MASK_COP1NORM, OP_SH_COP1SPEC, OP_MASK_COP1SPEC,
+ OP_MASK_COP1SCLR, OP_MASK_COP1CMP, OP_SH_COP1CMP, OP_SH_FORMAT,
+ OP_MASK_FORMAT, OP_SH_TRUE, OP_MASK_TRUE, OP_SH_GE, OP_MASK_GE,
+ OP_SH_UNSIGNED, OP_MASK_UNSIGNED, OP_SH_HINT, OP_MASK_HINT):
+ Defined.
+
+Fri Aug 16 00:15:15 1996 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h (pitlb, pitlbe, iitlba, iitlbp, fic, fice): Accept
+ a 3 bit space id instead of a 2 bit space id.
+
+Thu Aug 15 13:11:46 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
+
+ * d10v.h: Add some additional defines to support the
+ assembler in determining which operations can be done in parallel.
+
+Tue Aug 6 11:13:22 1996 Jeffrey A Law (law@cygnus.com)
+
+ * h8300.h (SN): Define.
+ (eepmov.b): Renamed from "eepmov"
+ (nop, bpt, rte, rts, sleep, clrmac): These have no size associated
+ with them.
+
+Fri Jul 26 11:47:10 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
+
+ * d10v.h (OPERAND_SHIFT): New operand flag.
+
+Thu Jul 25 12:06:22 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
+
+ * d10v.h: Changes for divs, parallel-only instructions, and
+ signed numbers.
+
+Mon Jul 22 11:21:15 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
+
+ * d10v.h (pd_reg): Define. Putting the definition here allows
+ the assembler and disassembler to share the same struct.
+
+Mon Jul 22 12:15:25 1996 Ian Lance Taylor <ian@cygnus.com>
+
+ * i960.h (i960_opcodes): "halt" takes an argument. From Stephen
+ Williams <steve@icarus.com>.
+
+Wed Jul 17 14:46:38 1996 Martin M. Hunt <hunt@pizza.cygnus.com>
+
+ * d10v.h: New file.
+
+Thu Jul 11 12:09:15 1996 Jeffrey A Law (law@cygnus.com)
+
+ * h8300.h (band, bclr): Force high bit of immediate nibble to zero.
+
+Wed Jul 3 14:30:12 1996 J.T. Conklin <jtc@rtl.cygnus.com>
+
+ * m68k.h (mcf5200): New macro.
+ Document names of coldfire control registers.
+
+Tue Jul 2 23:05:45 1996 Jeffrey A Law (law@cygnus.com)
+
+ * h8300.h (SRC_IN_DST): Define.
+
+ * h8300.h (UNOP3): Mark the register operand in this insn
+ as a source operand, not a destination operand.
+ (SHIFT_2, SHIFT_IMM): Remove. Eliminate all references.
+ (UNOP3): Change SHIFT_IMM to IMM for H8/S bitops. Mark
+ register operand with SRC_IN_DST.
+
+Fri Jun 21 13:52:17 1996 Richard Henderson <rth@tamu.edu>
+
+ * alpha.h: New file.
+
+Thu Jun 20 15:02:57 1996 Ian Lance Taylor <ian@cygnus.com>
+
+ * rs6k.h: Remove obsolete file.
+
+Wed Jun 19 15:29:38 1996 Ian Lance Taylor <ian@cygnus.com>
+
+ * i386.h: Correct opcode values for faddp, fsubp, fsubrp, fmulp,
+ fdivp, and fdivrp. Add ffreep.
+
+Tue Jun 18 16:06:00 1996 Jeffrey A. Law <law@rtl.cygnus.com>
+
+ * h8300.h: Reorder various #defines for readability.
+ (ABS32SRC, ABS32DST, DSP32LIST, ABS32LIST, A32LIST): Define.
+ (BITOP): Accept additional (unused) argument. All callers changed.
+ (EBITOP): Likewise.
+ (O_LAST): Bump.
+ (ldc, stc, movb, movw, movl): Use 32bit offsets and absolutes.
+
+ * h8300.h (EXR, SHIFT_2, MACREG, SHIFT_IMM, RDINC): Define.
+ (O_TAS, O_CLRMAC, O_LDMAC, O_MAC, O_LDM, O_STM): Define.
+ (BITOP, EBITOP): Handle new H8/S addressing modes for
+ bit insns.
+ (UNOP3): Handle new shift/rotate insns on the H8/S.
+ (insns using exr): New instructions.
+ (tas, mac, ldmac, clrmac, ldm, stm): New instructions.
+
+Thu May 23 16:56:48 1996 Jeffrey A Law (law@cygnus.com)
+
+ * h8300.h (add.l): Undo Apr 5th change. The manual I had
+ was incorrect.
+
+Mon May 6 23:38:22 1996 Jeffrey A Law (law@cygnus.com)
+
+ * h8300.h (START): Remove.
+ (MEMRELAX): Define. Mark absolute memory operands in mov.b, mov.w
+ and mov.l insns that can be relaxed.
+
+Tue Apr 30 18:30:58 1996 Ian Lance Taylor <ian@cygnus.com>
+
+ * i386.h: Remove Abs32 from lcall.
+
+Mon Apr 22 17:09:23 1996 Doug Evans <dje@blues.cygnus.com>
+
+ * sparc.h (SPARC_OPCODE_ARCH_V9_P): New macro.
+ (SLCPOP): New macro.
+ Mark X,Y opcode letters as in use.
+
+Thu Apr 11 17:28:18 1996 Ian Lance Taylor <ian@cygnus.com>
+
+ * sparc.h (F_FLOAT, F_FBR): Define.
+
+Fri Apr 5 16:55:34 1996 Jeffrey A Law (law@cygnus.com)
+
+ * h8300.h (ABS8MEM): Renamed from ABSMOV. Remove ABSMOV
+ from all insns.
+ (ABS8SRC,ABS8DST): Add ABS8MEM.
+ (add.l): Fix reg+reg variant.
+ (eepmov.w): Renamed from eepmovw.
+ (ldc,stc): Fix many cases.
+
+Sun Mar 31 13:30:03 1996 Doug Evans <dje@canuck.cygnus.com>
+
+ * sparc.h (SPARC_OPCODE_ARCH_MASK): New macro.
+
+Thu Mar 7 15:08:23 1996 Doug Evans <dje@charmed.cygnus.com>
+
+ * sparc.h (O): Mark operand letter as in use.
+
+Tue Feb 20 20:46:21 1996 Doug Evans <dje@charmed.cygnus.com>
+
+ * sparc.h (sparc_{encode,decode}_sparclet_cpreg): Declare.
+ Mark operand letters uU as in use.
+
+Mon Feb 19 01:59:08 1996 Doug Evans <dje@charmed.cygnus.com>
+
+ * sparc.h (sparc_opcode_arch_val): Add SPARC_OPCODE_ARCH_SPARCLET.
+ (sparc_opcode_arch): Delete member `conflicts'. Add `supported'.
+ (SPARC_OPCODE_SUPPORTED): New macro.
+ (SPARC_OPCODE_CONFLICT_P): Rewrite.
+ (F_NOTV9): Delete.
+
+Fri Feb 16 12:23:34 1996 Jeffrey A Law (law@cygnus.com)
+
+ * sparc.h (sparc_opcode_lookup_arch) Make return type in
+ declaration consistent with return type in definition.
+
+Wed Feb 14 18:14:11 1996 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * i386.h (i386_optab): Remove Data32 from pushf and popf.
+
+Thu Feb 8 14:27:21 1996 James Carlson <carlson@xylogics.com>
+
+ * i386.h (i386_regtab): Add 80486 test registers.
+
+Mon Feb 5 18:35:46 1996 Ian Lance Taylor <ian@cygnus.com>
+
+ * i960.h (I_HX): Define.
+ (i960_opcodes): Add HX instruction.
+
+Mon Jan 29 12:43:39 1996 Ken Raeburn <raeburn@cygnus.com>
+
+ * i386.h: Fix waiting forms of finit, fstenv, fsave, fstsw, fstcw,
+ and fclex.
+
+Wed Jan 24 22:36:59 1996 Doug Evans <dje@charmed.cygnus.com>
+
+ * sparc.h (enum sparc_opcode_arch_val): Replaces sparc_architecture.
+ (SPARC_OPCODE_CONFLICT_P): Renamed from ARCHITECTURES_CONFLICT_P.
+ (bfd_* defines): Delete.
+ (sparc_opcode_archs): Replaces architecture_pname.
+ (sparc_opcode_lookup_arch): Declare.
+ (NUMOPCODES): Delete.
+
+Mon Jan 22 08:24:32 1996 Doug Evans <dje@charmed.cygnus.com>
+
+ * sparc.h (enum sparc_architecture): Add v9a.
+ (ARCHITECTURES_CONFLICT_P): Update.
+
+Thu Dec 28 13:27:53 1995 John Hassey <hassey@rtp.dg.com>
+
+ * i386.h: Added Pentium Pro instructions.
+
+Thu Nov 2 22:59:22 1995 Ian Lance Taylor <ian@cygnus.com>
+
+ * m68k.h: Document new 'W' operand place.
+
+Tue Oct 24 10:49:10 1995 Jeffrey A Law (law@cygnus.com)
+
+ * hppa.h: Add lci and syncdma instructions.
+
+Mon Oct 23 11:09:16 1995 James G. Smith <jsmith@pasanda.cygnus.co.uk>
+
+ * mips.h: Added INSN_4100 flag to mark NEC VR4100 specific
+ instructions.
+
+Mon Oct 16 10:28:15 1995 Michael Meissner <meissner@tiktok.cygnus.com>
+
+ * ppc.h (PPC_OPCODE_{COMMON,ANY}): New opcode flags for
+ assembler's -mcom and -many switches.
+
+Wed Oct 11 16:56:33 1995 Ken Raeburn <raeburn@cygnus.com>
+
+ * i386.h: Fix cmpxchg8b extension opcode description.
+
+Thu Oct 5 18:03:36 1995 Ken Raeburn <raeburn@cygnus.com>
+
+ * i386.h: Add Pentium instructions wrmsr, rdtsc, rdmsr, cmpxchg8b,
+ and register cr4.
+
+Tue Sep 19 15:26:43 1995 Ian Lance Taylor <ian@cygnus.com>
+
+ * m68k.h: Change comment: split type P into types 0, 1 and 2.
+
+Wed Aug 30 13:50:55 1995 Doug Evans <dje@canuck.cygnus.com>
+
+ * sparc.h (sparc_{encode,decode}_prefetch): Declare.
+
+Tue Aug 29 15:34:58 1995 Doug Evans <dje@canuck.cygnus.com>
+
+ * sparc.h (sparc_{encode,decode}_{asi,membar}): Declare.
+
+Wed Aug 2 18:32:19 1995 Ian Lance Taylor <ian@cygnus.com>
+
+ * m68kmri.h: Remove.
+
+ * m68k.h: Move tables into opcodes/m68k-opc.c, leaving just the
+ declarations. Remove F_ALIAS and flag field of struct
+ m68k_opcode. Change arch field of struct m68k_opcode to unsigned
+ int. Make name and args fields of struct m68k_opcode const.
+
+Wed Aug 2 08:16:46 1995 Doug Evans <dje@canuck.cygnus.com>
+
+ * sparc.h (F_NOTV9): Define.
+
+Tue Jul 11 14:20:42 1995 Jeff Spiegel <jeffs@lsil.com>
+
+ * mips.h (INSN_4010): Define.
+
+Wed Jun 21 18:49:51 1995 Ken Raeburn <raeburn@cujo.cygnus.com>
+
+ * m68k.h (TBL1): Reverse sense of "round" argument in result.
+
+ Changes from Andreas Schwab <schwab@issan.informatik.uni-dortmund.de>:
+ * m68k.h: Fix argument descriptions of coprocessor
+ instructions to allow only alterable operands where appropriate.
+ [!NO_DEFAULT_SIZES]: An omitted size defaults to `w'.
+ (m68k_opcode_aliases): Add more aliases.
+
+Fri Apr 14 22:15:34 1995 Ken Raeburn <raeburn@cujo.cygnus.com>
+
+ * m68k.h: Added explcitly short-sized conditional branches, and a
+ bunch of aliases (fmov*, ftest*, tdivul) to support gcc's
+ svr4-based configurations.
+
+Mon Mar 13 21:30:01 1995 Ken Raeburn <raeburn@cujo.cygnus.com>
+
+ Mon Feb 27 08:36:39 1995 Bryan Ford <baford@cs.utah.edu>
+ * i386.h: added missing Data16/Data32 flags to a few instructions.
+
+Wed Mar 8 15:19:53 1995 Ian Lance Taylor <ian@cygnus.com>
+
+ * mips.h (OP_MASK_FR, OP_SH_FR): Define.
+ (OP_MASK_BCC, OP_SH_BCC): Define.
+ (OP_MASK_PREFX, OP_SH_PREFX): Define.
+ (OP_MASK_CCC, OP_SH_CCC): Define.
+ (INSN_READ_FPR_R): Define.
+ (INSN_RFE): Delete.
+
+Wed Mar 8 03:13:23 1995 Ken Raeburn <raeburn@cujo.cygnus.com>
+
+ * m68k.h (enum m68k_architecture): Deleted.
+ (struct m68k_opcode_alias): New type.
+ (m68k_opcodes): Now const. Deleted opcode aliases with exactly
+ matching constraints, values and flags. As a side effect of this,
+ the MOTOROLA_SYNTAX_ONLY and MIT_SYNTAX_ONLY macros, which so far
+ as I know were never used, now may need re-examining.
+ (numopcodes): Now const.
+ (m68k_opcode_aliases, numaliases): New variables.
+ (endop): Deleted.
+ [DONT_DEFINE_TABLE]: Declare numopcodes, numaliases, and
+ m68k_opcode_aliases; update declaration of m68k_opcodes.
+
+Mon Mar 6 10:02:00 1995 Jeff Law (law@snake.cs.utah.edu)
+
+ * hppa.h (delay_type): Delete unused enumeration.
+ (pa_opcode): Replace unused delayed field with an architecture
+ field.
+ (pa_opcodes): Mark each instruction as either PA1.0 or PA1.1.
+
+Fri Mar 3 16:10:24 1995 Ian Lance Taylor <ian@cygnus.com>
+
+ * mips.h (INSN_ISA4): Define.
+
+Fri Feb 24 19:13:37 1995 Ian Lance Taylor <ian@cygnus.com>
+
+ * mips.h (M_DLA_AB, M_DLI): Define.
+
+Thu Feb 23 17:33:09 1995 Jeff Law (law@snake.cs.utah.edu)
+
+ * hppa.h (fstwx): Fix single-bit error.
+
+Wed Feb 15 12:19:52 1995 Ian Lance Taylor <ian@cygnus.com>
+
+ * mips.h (M_ULD, M_ULD_A, M_USD, M_USD_A): Define.
+
+Mon Feb 6 10:35:23 1995 J.T. Conklin <jtc@rtl.cygnus.com>
+
+ * i386.h: added cpuid instruction , and dr[0-7] aliases for the
+ debug registers. From Charles Hannum (mycroft@netbsd.org).
+
+Mon Feb 6 03:31:54 1995 Ken Raeburn <raeburn@cujo.cygnus.com>
+
+ Changes from Bryan Ford <baford@schirf.cs.utah.edu> for 16-bit
+ i386 support:
+ * i386.h (MOV_AX_DISP32): New macro.
+ (i386_optab): Added Data16 and Data32 as needed. Added "w" forms
+ of several call/return instructions.
+ (ADDR_PREFIX_OPCODE): New macro.
+
+Mon Jan 23 16:45:43 1995 Ken Raeburn <raeburn@cujo.cygnus.com>
+
+ Sat Jan 21 17:50:38 1995 Pat Rankin (rankin@eql.caltech.edu)
+
+ * vax.h (struct vot_wot, field `args'): Make it pointer to const
+ char.
+ (struct vot, field `name'): ditto.
+
+Thu Jan 19 14:47:53 1995 Ken Raeburn <raeburn@cujo.cygnus.com>
+
+ * vax.h: Supply and properly group all values in end sentinel.
+
+Tue Jan 17 10:55:30 1995 Ian Lance Taylor <ian@sanguine.cygnus.com>
+
+ * mips.h (INSN_ISA, INSN_4650): Define.
+
+Wed Oct 19 13:34:17 1994 Ian Lance Taylor <ian@sanguine.cygnus.com>
+
+ * a29k.h: Add operand type 'I' for `inv' and `iretinv'. On
+ systems with a separate instruction and data cache, such as the
+ 29040, these instructions take an optional argument.
+
+Wed Sep 14 17:44:20 1994 Ian Lance Taylor (ian@sanguine.cygnus.com)
+
+ * mips.h (INSN_STORE_MEMORY): Correct value to not conflict with
+ INSN_TRAP.
+
+Tue Sep 6 11:39:08 1994 Ian Lance Taylor (ian@sanguine.cygnus.com)
+
+ * mips.h (INSN_STORE_MEMORY): Define.
+
+Thu Jul 28 19:28:07 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
+
+ * sparc.h: Document new operand type 'x'.
+
+Tue Jul 26 17:48:05 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
+
+ * i960.h (I_CX2): New instruction category. It includes
+ instructions available on Cx and Jx processors.
+ (I_JX): New instruction category, for JX-only instructions.
+ (i960_opcodes): Put eshro and sysctl in I_CX2 category. Added
+ Jx-only instructions, in I_JX category.
+
+Wed Jul 13 18:43:47 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
+
+ * ns32k.h (endop): Made pointer const too.
+
+Sun Jul 10 11:01:09 1994 Ian Dall (dall@hfrd.dsto.gov.au)
+
+ * ns32k.h: Drop Q operand type as there is no correct use
+ for it. Add I and Z operand types which allow better checking.
+
+Thu Jul 7 12:34:48 1994 Steve Chamberlain (sac@jonny.cygnus.com)
+
+ * h8300.h (xor.l) :fix bit pattern.
+ (L_2): New size of operand.
+ (trapa): Use it.
+
+Fri Jun 10 16:38:11 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * m68k.h: Move "trap" before "tpcc" to change disassembly.
+
+Fri Jun 3 15:57:36 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
+
+ * sparc.h: Include v9 definitions.
+
+Thu Jun 2 12:23:17 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
+
+ * m68k.h (m68060): Defined.
+ (m68040up, mfloat, mmmu): Include it.
+ (struct m68k_opcode): Widen `arch' field.
+ (m68k_opcodes): Updated for M68060. Removed comments that were
+ instructions commented out by "JF" years ago.
+
+Thu Apr 28 18:31:14 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
+
+ * m68k.h (struct m68k_opcode): Shorten `arch' field to 8 bits, and
+ add a one-bit `flags' field.
+ (F_ALIAS): New macro.
+
+Wed Apr 27 11:29:52 1994 Steve Chamberlain (sac@cygnus.com)
+
+ * h8300.h (dec, inc): Get encoding right.
+
+Mon Apr 4 13:12:43 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * ppc.h (struct powerpc_operand): Removed signedp field; just use
+ a flag instead.
+ (PPC_OPERAND_SIGNED): Define.
+ (PPC_OPERAND_SIGNOPT): Define.
+
+Thu Mar 31 19:34:08 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
+
+ * i386.h (IS_JUMP_ON_ECX_ZERO, "jcxz" pattern): Operand size
+ prefix is 0x66, not 0x67. Patch from H.J. Lu (hlu@nynexst.com).
+
+Thu Mar 3 15:51:05 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
+
+ * i386.h: Reverse last change. It'll be handled in gas instead.
+
+Thu Feb 24 15:29:05 1994 Ken Raeburn (raeburn@cujo.cygnus.com)
+
+ * i386.h (sar): Disabled the two-operand Imm1 form, since it was
+ slower on the 486 and used the implicit shift count despite the
+ explicit operand. The one-operand form is still available to get
+ the shorter form with the implicit shift count.
+
+Thu Feb 17 12:27:52 1994 Torbjorn Granlund (tege@mexican.cygnus.com)
+
+ * hppa.h: Fix typo in fstws arg string.
+
+Wed Feb 9 21:23:52 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * ppc.h (struct powerpc_opcode): Make operands field unsigned.
+
+Mon Feb 7 19:14:58 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * ppc.h (PPC_OPCODE_601): Define.
+
+Fri Feb 4 23:43:50 1994 Jeffrey A. Law (law@snake.cs.utah.edu)
+
+ * hppa.h (addb): Use '@' for addb and addib pseudo ops.
+ (so we can determine valid completers for both addb and addb[tf].)
+
+ * hppa.h (xmpyu): No floating point format specifier for the
+ xmpyu instruction.
+
+Fri Feb 4 23:36:52 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * ppc.h (PPC_OPERAND_NEXT): Define.
+ (PPC_OPERAND_NEGATIVE): Change value to make room for above.
+ (struct powerpc_macro): Define.
+ (powerpc_macros, powerpc_num_macros): Declare.
+
+Fri Jan 21 19:13:50 1994 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * ppc.h: New file. Header file for PowerPC opcode table.
+
+Mon Jan 17 00:14:23 1994 Jeffrey A. Law (law@snake.cs.utah.edu)
+
+ * hppa.h: More minor template fixes for sfu and copr (to allow
+ for easier disassembly).
+
+ * hppa.h: Fix templates for all the sfu and copr instructions.
+
+Wed Dec 15 15:12:42 1993 Ken Raeburn (raeburn@cujo.cygnus.com)
+
+ * i386.h (push): Permit Imm16 operand too.
+
+Sat Dec 11 16:14:06 1993 Steve Chamberlain (sac@thepub.cygnus.com)
+
+ * h8300.h (andc): Exists in base arch.
+
+Wed Dec 1 12:15:32 1993 Jeffrey A. Law (law@snake.cs.utah.edu)
+
+ * From Hisashi MINAMINO <minamino@sramhc.sra.co.jp>
+ * hppa.h: #undef NONE to avoid conflict with hiux include files.
+
+Sun Nov 21 22:06:57 1993 Jeffrey A. Law (law@snake.cs.utah.edu)
+
+ * hppa.h: Add FP quadword store instructions.
+
+Wed Nov 17 17:13:16 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * mips.h: (M_J_A): Added.
+ (M_LA): Removed.
+
+Mon Nov 8 12:12:47 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * mips.h (OP_MASK_CACHE, OP_SH_CACHE): Define. From Ted Lemon
+ <mellon@pepper.ncd.com>.
+
+Sun Nov 7 00:30:11 1993 Jeffrey A. Law (law@snake.cs.utah.edu)
+
+ * hppa.h: Immediate field in probei instructions is unsigned,
+ not low-sign extended.
+
+Wed Nov 3 10:30:00 1993 Jim Kingdon (kingdon@lioth.cygnus.com)
+
+ * m88k.h (RRI10MASK): Change from 0xfc00ffe0 to 0xfc00fc00.
+
+Tue Nov 2 12:41:30 1993 Ken Raeburn (raeburn@rover.cygnus.com)
+
+ * i386.h: Add "fxch" without operand.
+
+Mon Nov 1 18:13:03 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * mips.h (M_JAL_1, M_JAL_2, M_JAL_A): Added.
+
+Sat Oct 2 22:26:11 1993 Jeffrey A Law (law@snake.cs.utah.edu)
+
+ * hppa.h: Add gfw and gfr to the opcode table.
+
+Wed Sep 29 16:23:00 1993 K. Richard Pixley (rich@sendai.cygnus.com)
+
+ * m88k.h: extended to handle m88110.
+
+Tue Sep 28 19:19:08 1993 Jeffrey A Law (law@snake.cs.utah.edu)
+
+ * hppa.h (be, ble): Use operand type 'z' to denote absolute branch
+ addresses.
+
+Tue Sep 14 14:04:35 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * i960.h (i960_opcodes): Properly bracket initializers.
+
+Mon Sep 13 12:50:52 1993 K. Richard Pixley (rich@sendai.cygnus.com)
+
+ * m88k.h (BOFLAG): rewrite to avoid nested comment.
+
+Mon Sep 13 15:46:06 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * m68k.h (two): Protect second argument with parentheses.
+
+Fri Sep 10 16:29:47 1993 Ken Raeburn (raeburn@cambridge.cygnus.com)
+
+ * i386.h (i386_optab): Added new instruction "rsm" (for i386sl).
+ Deleted old in/out instructions in "#if 0" section.
+
+Thu Sep 9 17:42:19 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * i386.h (i386_optab): Properly bracket initializers.
+
+Wed Aug 25 13:50:56 1993 Ken Raeburn (raeburn@cambridge.cygnus.com)
+
+ * hppa.h (pa_opcode): Use '|' for movb and movib insns. (From
+ Jeff Law, law@cs.utah.edu).
+
+Mon Aug 23 16:55:03 1993 Ken Raeburn (raeburn@cambridge.cygnus.com)
+
+ * i386.h (lcall): Accept Imm32 operand also.
+
+Mon Aug 23 12:43:11 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * mips.h (M_ABSU): Removed (absolute value of unsigned number??).
+ (M_DABS): Added.
+
+Thu Aug 19 15:08:37 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * mips.h (INSN_*): Changed values. Removed unused definitions.
+ Added INSN_COND_BRANCH_LIKELY, INSN_ISA2 and INSN_ISA3. Split
+ INSN_LOAD_DELAY into INSN_LOAD_MEMORY_DELAY and
+ INSN_LOAD_COPROC_DELAY. Split INSN_COPROC_DELAY into
+ INSN_COPROC_MOVE_DELAY and INSN_COPROC_MEMORY_DELAY.
+ (M_*): Added new values for r6000 and r4000 macros.
+ (ANY_DELAY): Removed.
+
+Wed Aug 18 15:37:48 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * mips.h: Added M_LI_S and M_LI_SS.
+
+Tue Aug 17 07:08:08 1993 Steve Chamberlain (sac@phydeaux.cygnus.com)
+
+ * h8300.h: Get some rare mov.bs correct.
+
+Thu Aug 5 09:15:17 1993 Jim Kingdon (kingdon@lioth.cygnus.com)
+
+ * sparc.h: Don't define const ourself; rely on ansidecl.h having
+ been included.
+
+Fri Jul 30 18:41:11 1993 John Gilmore (gnu@cygnus.com)
+
+ * sparc.h (F_JSR, F_UNBR, F_CONDBR): Add new flags to mark
+ jump instructions, for use in disassemblers.
+
+Thu Jul 22 07:25:27 1993 Ian Lance Taylor (ian@cygnus.com)
+
+ * m88k.h: Make bitfields just unsigned, not unsigned long or
+ unsigned short.
+
+Wed Jul 21 11:55:31 1993 Jim Kingdon (kingdon@deneb.cygnus.com)
+
+ * hppa.h: New argument type 'y'. Use in various float instructions.
+
+Mon Jul 19 17:17:03 1993 Jim Kingdon (kingdon@deneb.cygnus.com)
+
+ * hppa.h (break): First immediate field is unsigned.
+
+ * hppa.h: Add rfir instruction.
+
+Sun Jul 18 16:28:08 1993 Jim Kingdon (kingdon@rtl.cygnus.com)
+
+ * mips.h: Split the actual table out into ../../opcodes/mips-opc.c.
+
+Fri Jul 16 09:59:29 1993 Ian Lance Taylor (ian@cygnus.com)
+
+ * mips.h: Reworked the hazard information somewhat, and fixed some
+ bugs in the instruction hazard descriptions.
+
+Thu Jul 15 12:42:01 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * m88k.h: Corrected a couple of opcodes.
+
+Tue Jul 6 15:17:35 1993 Ian Lance Taylor (ian@cygnus.com)
+
+ * mips.h: Replaced with version from Ralph Campbell and OSF. The
+ new version includes instruction hazard information, but is
+ otherwise reasonably similar.
+
+Thu Jul 1 20:36:17 1993 Doug Evans (dje@canuck.cygnus.com)
+
+ * h8300.h: Fix typo in UNOP3 (affected sh[al][lr].l).
+
+Fri Jun 11 18:38:44 1993 Ken Raeburn (raeburn@cygnus.com)
+
+ Patches from Jeff Law, law@cs.utah.edu:
+ * hppa.h: Clean up some of the OLD_TABLE, non-OLD_TABLE braindamage.
+ Make the tables be the same for the following instructions:
+ "bb", "addb[tf]", "addib[tf]", "add", "add[loc]", "addco",
+ "sh[123]add", "sh[123]add[lo]", "sub", "sub[obt]", "sub[bt]o",
+ "ds", "comclr", "addi", "addi[ot]", "addito", "subi", "subio",
+ "comiclr", "fadd", "fsub", "fmpy", "fdiv", "fsqrt", "fabs",
+ "frnd", "fcpy", "fcnvff", "fcnvxf", "fcnvfx", "fcnvfxt",
+ "fcmp", and "ftest".
+
+ * hppa.h: Make new and old tables the same for "break", "mtctl",
+ "mfctl", "bb", "ssm", "rsm", "xmpyu", "fmpyadd", "fmpysub".
+ Fix typo in last patch. Collapse several #ifdefs into a
+ single #ifdef.
+
+ * hppa.h: Delete remaining OLD_TABLE code. Bring some
+ of the comments up-to-date.
+
+ * hppa.h: Update "free list" of letters and update
+ comments describing each letter's function.
+
+Thu Jul 8 09:05:26 1993 Doug Evans (dje@canuck.cygnus.com)
+
+ * h8300.h: Lots of little fixes for the h8/300h.
+
+Tue Jun 8 12:16:03 1993 Steve Chamberlain (sac@phydeaux.cygnus.com)
+
+ Support for H8/300-H
+ * h8300.h: Lots of new opcodes.
+
+Fri Jun 4 15:41:37 1993 Steve Chamberlain (sac@phydeaux.cygnus.com)
+
+ * h8300.h: checkpoint, includes H8/300-H opcodes.
+
+Thu Jun 3 15:42:59 1993 Stu Grossman (grossman@cygnus.com)
+
+ * Patches from Jeffrey Law <law@cs.utah.edu>.
+ * hppa.h: Rework single precision FP
+ instructions so that they correctly disassemble code
+ PA1.1 code.
+
+Thu May 27 19:21:22 1993 Bruce Bauman (boot@osf.org)
+
+ * i386.h (i386_optab, mov pattern): Remove Mem16 restriction from
+ mov to allow instructions like mov ss,xyz(ecx) to assemble.
+
+Tue May 25 00:39:40 1993 Ken Raeburn (raeburn@cygnus.com)
+
+ * hppa.h: Use new version from Utah if OLD_TABLE isn't defined;
+ gdb will define it for now.
+
+Mon May 24 15:20:06 1993 Ken Raeburn (raeburn@cambridge.cygnus.com)
+
+ * sparc.h: Don't end enumerator list with comma.
+
+Fri May 14 15:15:50 1993 Ian Lance Taylor (ian@cygnus.com)
+
+ * Based on patches from davidj@ICSI.Berkeley.EDU (David Johnson):
+ * mips.h (OP_MASK_COPZ, OP_SH_COPZ): Define.
+ ("bc2t"): Correct typo.
+ ("[ls]wc[023]"): Use T rather than t.
+ ("c[0123]"): Define general coprocessor instructions.
+
+Mon May 10 06:02:25 1993 Ken Raeburn (raeburn@kr-pc.cygnus.com)
+
+ * m68k.h: Move split point for gcc compilation more towards
+ middle.
+
+Fri Apr 9 13:26:16 1993 Jim Kingdon (kingdon@cygnus.com)
+
+ * rs6k.h: Clean up instructions for primary opcode 19 (many were
+ simply wrong, ics, rfi, & rfsvc were missing).
+ Add "a" to opr_ext for "bb". Doc fix.
+
+Thu Mar 18 13:45:31 1993 Per Bothner (bothner@rtl.cygnus.com)
+
+ * i386.h: 486 extensions from John Hassey (hassey@dg-rtp.dg.com).
+ * mips.h: Add casts, to suppress warnings about shifting too much.
+ * m68k.h: Document the placement code '9'.
+
+Thu Feb 18 02:03:14 1993 John Gilmore (gnu@cygnus.com)
+
+ * m68k.h (BREAK_UP_BIG_DECL, AND_OTHER_PART): Add kludge which
+ allows callers to break up the large initialized struct full of
+ opcodes into two half-sized ones. This permits GCC to compile
+ this module, since it takes exponential space for initializers.
+ (numopcodes, endop): Revise to use AND_OTHER_PART in size calcs.
+
+Thu Feb 4 02:06:56 1993 John Gilmore (gnu@cygnus.com)
+
+ * a29k.h: Remove RCS crud, update GPL to v2, update copyrights.
+ * convex.h: Added, from GDB's convx-opcode.h. Added CONST to all
+ initialized structs in it.
+
+Thu Jan 28 21:32:22 1993 John Gilmore (gnu@cygnus.com)
+
+ Delta 88 changes inspired by Carl Greco, <cgreco@Creighton.Edu>:
+ * m88k.h (PMEM): Avoid previous definition from <sys/param.h>.
+ (AND): Change to AND_ to avoid ansidecl.h `AND' conflict.
+
+Sat Jan 23 18:10:49 PST 1993 Ralph Campbell (ralphc@pyramid.com)
+
+ * mips.h: document "i" and "j" operands correctly.
+
+Thu Jan 7 15:58:13 1993 Ian Lance Taylor (ian@tweedledumb.cygnus.com)
+
+ * mips.h: Removed endianness dependency.
+
+Sun Jan 3 14:13:35 1993 Steve Chamberlain (sac@thepub.cygnus.com)
+
+ * h8300.h: include info on number of cycles per instruction.
+
+Mon Dec 21 21:29:08 1992 Stu Grossman (grossman at cygnus.com)
+
+ * hppa.h: Move handy aliases to the front. Fix masks for extract
+ and deposit instructions.
+
+Sat Dec 12 16:09:48 1992 Ian Lance Taylor (ian@cygnus.com)
+
+ * i386.h: accept shld and shrd both with and without the shift
+ count argument, which is always %cl.
+
+Fri Nov 27 17:13:18 1992 Ken Raeburn (raeburn at cygnus.com)
+
+ * i386.h (i386_optab_end, i386_regtab_end): Now const.
+ (one_byte_segment_defaults, two_byte_segment_defaults,
+ i386_prefixtab_end): Ditto.
+
+Mon Nov 23 10:47:25 1992 Ken Raeburn (raeburn@cygnus.com)
+
+ * vax.h (bb*): Use "v" (bitfield type), not "a" (address operand)
+ for operand 2; from John Carr, jfc@dsg.dec.com.
+
+Wed Nov 4 07:36:49 1992 Ken Raeburn (raeburn@cygnus.com)
+
+ * m68k.h: Define FIXED_SIZE_BRANCH, so bsr and bra instructions
+ always use 16-bit offsets. Makes calculated-size jump tables
+ feasible.
+
+Fri Oct 16 22:52:43 1992 Ken Raeburn (raeburn@cygnus.com)
+
+ * i386.h: Fix one-operand forms of in* and out* patterns.
+
+Tue Sep 22 14:08:14 1992 Ken Raeburn (raeburn@cambridge.cygnus.com)
+
+ * m68k.h: Added CPU32 support.
+
+Tue Sep 22 00:38:41 1992 John Gilmore (gnu@cygnus.com)
+
+ * mips.h (break): Disassemble the argument. Patch from
+ jonathan@cs.stanford.edu (Jonathan Stone).
+
+Wed Sep 9 11:25:28 1992 Ian Lance Taylor (ian@cygnus.com)
+
+ * m68k.h: merged Motorola and MIT syntax.
+
+Thu Sep 3 09:33:22 1992 Steve Chamberlain (sac@thepub.cygnus.com)
+
+ * m68k.h (pmove): make the tests less strict, the 68k book is
+ wrong.
+
+Tue Aug 25 23:25:19 1992 Ken Raeburn (raeburn@cambridge.cygnus.com)
+
+ * m68k.h (m68ec030): Defined as alias for 68030.
+ (m68k_opcodes): New type characters "3" for 68030 MMU regs and "t"
+ for immediate 0-7 added. Set up some opcodes (ptest, bkpt) to use
+ them. Tightened description of "fmovex" to distinguish it from
+ some "pmove" encodings. Added "pmove" for 68030 MMU regs, cleaned
+ up descriptions that claimed versions were available for chips not
+ supporting them. Added "pmovefd".
+
+Mon Aug 24 12:04:51 1992 Steve Chamberlain (sac@thepub.cygnus.com)
+
+ * m68k.h: fix where the . goes in divull
+
+Wed Aug 19 11:22:24 1992 Ian Lance Taylor (ian@cygnus.com)
+
+ * m68k.h: the cas2 instruction is supposed to be written with
+ indirection on the last two operands, which can be either data or
+ address registers. Added a new operand type 'r' which accepts
+ either register type. Added new cases for cas2l and cas2w which
+ use them. Corrected masks for cas2 which failed to recognize use
+ of address register.
+
+Fri Aug 14 14:20:38 1992 Per Bothner (bothner@cygnus.com)
+
+ * m68k.h: Merged in patches (mostly m68040-specific) from
+ Colin Smith <colin@wrs.com>.
+
+ * m68k.h: Merged m68kmri.h and m68k.h (using the former as a
+ base). Also cleaned up duplicates, re-ordered instructions for
+ the sake of dis-assembling (so aliases come after standard names).
+ * m68kmri.h: Now just defines some macros, and #includes m68k.h.
+
+Wed Aug 12 16:38:15 1992 Steve Chamberlain (sac@thepub.cygnus.com)
+
+ * m68kmri.h: added various opcodes. Moved jbxx to bxxes. Filled in
+ all missing .s
+
+Mon Aug 10 23:22:33 1992 Ken Raeburn (raeburn@cygnus.com)
+
+ * sparc.h: Moved tables to BFD library.
+
+ * i386.h (i386_optab): Add fildq, fistpq aliases used by gcc.
+
+Sun Jun 28 13:29:03 1992 Fred Fish (fnf@cygnus.com)
+
+ * h8300.h: Finish filling in all the holes in the opcode table,
+ so that the Lucid C compiler can digest this as well...
+
+Fri Jun 26 21:27:17 1992 John Gilmore (gnu at cygnus.com)
+
+ * i386.h: Add setc, setnc, addr16, data16, repz, repnz aliases.
+ Fix opcodes on various sizes of fild/fist instructions
+ (16bit=no suffix, 32bit="l" suffix, 64bit="ll" suffix).
+ Use tabs to indent for comments. Fixes suggested by Minh Tran-Le.
+
+Thu Jun 25 16:13:26 1992 Stu Grossman (grossman at cygnus.com)
+
+ * h8300.h: Fill in all the holes in the opcode table so that the
+ losing HPUX C compiler can digest this...
+
+Thu Jun 11 12:15:25 1992 John Gilmore (gnu at cygnus.com)
+
+ * mips.h: Fix decoding of coprocessor instructions, somewhat.
+ (Fix by Eric Anderson, 3jean@maas-neotek.arc.nasa.gov.)
+
+Thu May 28 11:17:44 1992 Jim Wilson (wilson@sphagnum.cygnus.com)
+
+ * sparc.h: Add new architecture variant sparclite; add its scan
+ and divscc opcodes. Define ARCHITECTURES_CONFLICT_P macro.
+
+Tue May 5 14:23:27 1992 Per Bothner (bothner@rtl.cygnus.com)
+
+ * mips.h: Add some more opcode synonyms (from Frank Yellin,
+ fy@lucid.com).
+
+Thu Apr 16 18:25:26 1992 Per Bothner (bothner@cygnus.com)
+
+ * rs6k.h: New version from IBM (Metin).
+
+Thu Apr 9 00:31:19 1992 Per Bothner (bothner@rtl.cygnus.com)
+
+ * rs6k.h: Fix incorrect extended opcode for instructions `fm'
+ and `fd'. (From metin@ibmpa.awdpa.ibm.com (Metin G. Ozisik).)
+
+Tue Apr 7 13:38:47 1992 Stu Grossman (grossman at cygnus.com)
+
+ * rs6k.h: Move from ../../gdb/rs6k-opcode.h.
+
+Fri Apr 3 11:30:20 1992 Fred Fish (fnf@cygnus.com)
+
+ * m68k.h (one, two): Cast macro args to unsigned to suppress
+ complaints from compiler and lint about integer overflow during
+ shift.
+
+Sun Mar 29 12:22:08 1992 John Gilmore (gnu at cygnus.com)
+
+ * sparc.h (OP): Avoid signed overflow when shifting to high order bit.
+
+Fri Mar 6 00:22:38 1992 John Gilmore (gnu at cygnus.com)
+
+ * mips.h: Make bitfield layout depend on the HOST compiler,
+ not on the TARGET system.
+
+Fri Feb 21 01:29:51 1992 K. Richard Pixley (rich@cygnus.com)
+
+ * i386.h: added inb, inw, outb, outw opcodes, added att syntax for
+ scmp, slod, smov, ssca, ssto. Curtesy Minh Tran-Le
+ <TRANLE@INTELLICORP.COM>.
+
+Thu Jan 30 07:31:44 1992 Steve Chamberlain (sac at rtl.cygnus.com)
+
+ * h8300.h: turned op_type enum into #define list
+
+Thu Jan 30 01:07:24 1992 John Gilmore (gnu at cygnus.com)
+
+ * sparc.h: Remove "cypress" architecture. Remove "fitox" and
+ similar instructions -- they've been renamed to "fitoq", etc.
+ REALLY fix tsubcctv. Fix "fcmpeq" and "fcmpq" which had wrong
+ number of arguments.
+ * h8300.h: Remove extra ; which produces compiler warning.
+
+Tue Jan 28 22:59:22 1992 Stu Grossman (grossman at cygnus.com)
+
+ * sparc.h: fix opcode for tsubcctv.
+
+Tue Jan 7 17:19:39 1992 K. Richard Pixley (rich at cygnus.com)
+
+ * sparc.h: fba and cba are now aliases for fb and cb respectively.
+
+Fri Dec 27 10:55:50 1991 Per Bothner (bothner at cygnus.com)
+
+ * sparc.h (nop): Made the 'lose' field be even tighter,
+ so only a standard 'nop' is disassembled as a nop.
+
+Sun Dec 22 12:18:18 1991 Michael Tiemann (tiemann at cygnus.com)
+
+ * sparc.h (nop): Add RD_GO to `lose' so that only %g0 in dest is
+ disassembled as a nop.
+
+Wed Dec 18 17:19:44 1991 Stu Grossman (grossman at cygnus.com)
+
+ * m68k.h, sparc.h: ANSIfy enums.
+
+Tue Dec 10 00:22:20 1991 K. Richard Pixley (rich at rtl.cygnus.com)
+
+ * sparc.h: fix a typo.
+
+Sat Nov 30 20:40:51 1991 Steve Chamberlain (sac at rtl.cygnus.com)
+
+ * a29k.h, arm.h, h8300.h, i386.h, i860.h, i960.h , m68k.h,
+ m88k.h, mips.h , np1.h, ns32k.h, pn.h, pyr.h, sparc.h, tahoe.h,
+ vax.h: Renamed from ../<foo>-opcode.h.
+
+
+Local Variables:
+version-control: never
+End:
diff --git a/contrib/binutils/include/opcode/alpha.h b/contrib/binutils/include/opcode/alpha.h
index 487b696..efe1626 100644
--- a/contrib/binutils/include/opcode/alpha.h
+++ b/contrib/binutils/include/opcode/alpha.h
@@ -1,5 +1,5 @@
/* alpha.h -- Header file for Alpha opcode table
- Copyright 1996, 1999 Free Software Foundation, Inc.
+ Copyright 1996, 1999, 2001, 2003 Free Software Foundation, Inc.
Contributed by Richard Henderson <rth@tamu.edu>,
patterned after the PPC opcode table written by Ian Lance Taylor.
@@ -108,8 +108,7 @@ struct alpha_operand
string (the operand will be inserted in any case). If the
operand value is legal, *ERRMSG will be unchanged (most operands
can accept any value). */
- unsigned (*insert) PARAMS ((unsigned instruction, int op,
- const char **errmsg));
+ unsigned (*insert) (unsigned instruction, int op, const char **errmsg);
/* Extraction function. This is used by the disassembler. To
extract this operand type from an instruction, check this field.
@@ -128,7 +127,7 @@ struct alpha_operand
non-zero if this operand type can not actually be extracted from
this operand (i.e., the instruction does not match). If the
operand is valid, *INVALID will not be changed. */
- int (*extract) PARAMS ((unsigned instruction, int *invalid));
+ int (*extract) (unsigned instruction, int *invalid);
};
/* Elements in the table are retrieved by indexing with values from
diff --git a/contrib/binutils/include/opcode/arc.h b/contrib/binutils/include/opcode/arc.h
new file mode 100644
index 0000000..629979d
--- /dev/null
+++ b/contrib/binutils/include/opcode/arc.h
@@ -0,0 +1,323 @@
+/* Opcode table for the ARC.
+ Copyright 1994, 1995, 1997, 2001, 2002, 2003
+ Free Software Foundation, Inc.
+ Contributed by Doug Evans (dje@cygnus.com).
+
+ This file is part of GAS, the GNU Assembler, GDB, the GNU debugger, and
+ the GNU Binutils.
+
+ GAS/GDB is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
+
+ GAS/GDB is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with GAS or GDB; see the file COPYING. If not, write to
+ the Free Software Foundation, 59 Temple Place - Suite 330, Boston,
+ MA 02111-1307, USA. */
+
+
+/* List of the various cpu types.
+ The tables currently use bit masks to say whether the instruction or
+ whatever is supported by a particular cpu. This lets us have one entry
+ apply to several cpus.
+
+ The `base' cpu must be 0. The cpu type is treated independently of
+ endianness. The complete `mach' number includes endianness.
+ These values are internal to opcodes/bfd/binutils/gas. */
+#define ARC_MACH_5 0
+#define ARC_MACH_6 1
+#define ARC_MACH_7 2
+#define ARC_MACH_8 4
+
+/* Additional cpu values can be inserted here and ARC_MACH_BIG moved down. */
+#define ARC_MACH_BIG 16
+
+/* Mask of number of bits necessary to record cpu type. */
+#define ARC_MACH_CPU_MASK (ARC_MACH_BIG - 1)
+
+/* Mask of number of bits necessary to record cpu type + endianness. */
+#define ARC_MACH_MASK ((ARC_MACH_BIG << 1) - 1)
+
+/* Type to denote an ARC instruction (at least a 32 bit unsigned int). */
+
+typedef unsigned int arc_insn;
+
+struct arc_opcode {
+ char *syntax; /* syntax of insn */
+ unsigned long mask, value; /* recognize insn if (op&mask) == value */
+ int flags; /* various flag bits */
+
+/* Values for `flags'. */
+
+/* Return CPU number, given flag bits. */
+#define ARC_OPCODE_CPU(bits) ((bits) & ARC_MACH_CPU_MASK)
+
+/* Return MACH number, given flag bits. */
+#define ARC_OPCODE_MACH(bits) ((bits) & ARC_MACH_MASK)
+
+/* First opcode flag bit available after machine mask. */
+#define ARC_OPCODE_FLAG_START (ARC_MACH_MASK + 1)
+
+/* This insn is a conditional branch. */
+#define ARC_OPCODE_COND_BRANCH (ARC_OPCODE_FLAG_START)
+#define SYNTAX_3OP (ARC_OPCODE_COND_BRANCH << 1)
+#define SYNTAX_LENGTH (SYNTAX_3OP )
+#define SYNTAX_2OP (SYNTAX_3OP << 1)
+#define OP1_MUST_BE_IMM (SYNTAX_2OP << 1)
+#define OP1_IMM_IMPLIED (OP1_MUST_BE_IMM << 1)
+#define SYNTAX_VALID (OP1_IMM_IMPLIED << 1)
+
+#define I(x) (((x) & 31) << 27)
+#define A(x) (((x) & ARC_MASK_REG) << ARC_SHIFT_REGA)
+#define B(x) (((x) & ARC_MASK_REG) << ARC_SHIFT_REGB)
+#define C(x) (((x) & ARC_MASK_REG) << ARC_SHIFT_REGC)
+#define R(x,b,m) (((x) & (m)) << (b)) /* value X, mask M, at bit B */
+
+/* These values are used to optimize assembly and disassembly. Each insn
+ is on a list of related insns (same first letter for assembly, same
+ insn code for disassembly). */
+
+ struct arc_opcode *next_asm; /* Next instr to try during assembly. */
+ struct arc_opcode *next_dis; /* Next instr to try during disassembly. */
+
+/* Macros to create the hash values for the lists. */
+#define ARC_HASH_OPCODE(string) \
+ ((string)[0] >= 'a' && (string)[0] <= 'z' ? (string)[0] - 'a' : 26)
+#define ARC_HASH_ICODE(insn) \
+ ((unsigned int) (insn) >> 27)
+
+ /* Macros to access `next_asm', `next_dis' so users needn't care about the
+ underlying mechanism. */
+#define ARC_OPCODE_NEXT_ASM(op) ((op)->next_asm)
+#define ARC_OPCODE_NEXT_DIS(op) ((op)->next_dis)
+};
+
+/* this is an "insert at front" linked list per Metaware spec
+ that new definitions override older ones. */
+extern struct arc_opcode *arc_ext_opcodes;
+
+struct arc_operand_value {
+ char *name; /* eg: "eq" */
+ short value; /* eg: 1 */
+ unsigned char type; /* index into `arc_operands' */
+ unsigned char flags; /* various flag bits */
+
+/* Values for `flags'. */
+
+/* Return CPU number, given flag bits. */
+#define ARC_OPVAL_CPU(bits) ((bits) & ARC_MACH_CPU_MASK)
+/* Return MACH number, given flag bits. */
+#define ARC_OPVAL_MACH(bits) ((bits) & ARC_MACH_MASK)
+};
+
+struct arc_ext_operand_value {
+ struct arc_ext_operand_value *next;
+ struct arc_operand_value operand;
+};
+
+extern struct arc_ext_operand_value *arc_ext_operands;
+
+struct arc_operand {
+/* One of the insn format chars. */
+ unsigned char fmt;
+
+/* The number of bits in the operand (may be unused for a modifier). */
+ unsigned char bits;
+
+/* How far the operand is left shifted in the instruction, or
+ the modifier's flag bit (may be unused for a modifier. */
+ unsigned char shift;
+
+/* Various flag bits. */
+ int flags;
+
+/* Values for `flags'. */
+
+/* This operand is a suffix to the opcode. */
+#define ARC_OPERAND_SUFFIX 1
+
+/* This operand is a relative branch displacement. The disassembler
+ prints these symbolically if possible. */
+#define ARC_OPERAND_RELATIVE_BRANCH 2
+
+/* This operand is an absolute branch address. The disassembler
+ prints these symbolically if possible. */
+#define ARC_OPERAND_ABSOLUTE_BRANCH 4
+
+/* This operand is an address. The disassembler
+ prints these symbolically if possible. */
+#define ARC_OPERAND_ADDRESS 8
+
+/* This operand is a long immediate value. */
+#define ARC_OPERAND_LIMM 0x10
+
+/* This operand takes signed values. */
+#define ARC_OPERAND_SIGNED 0x20
+
+/* This operand takes signed values, but also accepts a full positive
+ range of values. That is, if bits is 16, it takes any value from
+ -0x8000 to 0xffff. */
+#define ARC_OPERAND_SIGNOPT 0x40
+
+/* This operand should be regarded as a negative number for the
+ purposes of overflow checking (i.e., the normal most negative
+ number is disallowed and one more than the normal most positive
+ number is allowed). This flag will only be set for a signed
+ operand. */
+#define ARC_OPERAND_NEGATIVE 0x80
+
+/* This operand doesn't really exist. The program uses these operands
+ in special ways. */
+#define ARC_OPERAND_FAKE 0x100
+
+/* separate flags operand for j and jl instructions */
+#define ARC_OPERAND_JUMPFLAGS 0x200
+
+/* allow warnings and errors to be issued after call to insert_xxxxxx */
+#define ARC_OPERAND_WARN 0x400
+#define ARC_OPERAND_ERROR 0x800
+
+/* this is a load operand */
+#define ARC_OPERAND_LOAD 0x8000
+
+/* this is a store operand */
+#define ARC_OPERAND_STORE 0x10000
+
+/* Modifier values. */
+/* A dot is required before a suffix. Eg: .le */
+#define ARC_MOD_DOT 0x1000
+
+/* A normal register is allowed (not used, but here for completeness). */
+#define ARC_MOD_REG 0x2000
+
+/* An auxiliary register name is expected. */
+#define ARC_MOD_AUXREG 0x4000
+
+/* Sum of all ARC_MOD_XXX bits. */
+#define ARC_MOD_BITS 0x7000
+
+/* Non-zero if the operand type is really a modifier. */
+#define ARC_MOD_P(X) ((X) & ARC_MOD_BITS)
+
+/* enforce read/write only register restrictions */
+#define ARC_REGISTER_READONLY 0x01
+#define ARC_REGISTER_WRITEONLY 0x02
+#define ARC_REGISTER_NOSHORT_CUT 0x04
+
+/* Insertion function. This is used by the assembler. To insert an
+ operand value into an instruction, check this field.
+
+ If it is NULL, execute
+ i |= (p & ((1 << o->bits) - 1)) << o->shift;
+ (I is the instruction which we are filling in, O is a pointer to
+ this structure, and OP is the opcode value; this assumes twos
+ complement arithmetic).
+
+ If this field is not NULL, then simply call it with the
+ instruction and the operand value. It will return the new value
+ of the instruction. If the ERRMSG argument is not NULL, then if
+ the operand value is illegal, *ERRMSG will be set to a warning
+ string (the operand will be inserted in any case). If the
+ operand value is legal, *ERRMSG will be unchanged.
+
+ REG is non-NULL when inserting a register value. */
+
+ arc_insn (*insert)
+ (arc_insn insn, const struct arc_operand *operand, int mods,
+ const struct arc_operand_value *reg, long value, const char **errmsg);
+
+/* Extraction function. This is used by the disassembler. To
+ extract this operand type from an instruction, check this field.
+
+ If it is NULL, compute
+ op = ((i) >> o->shift) & ((1 << o->bits) - 1);
+ if ((o->flags & ARC_OPERAND_SIGNED) != 0
+ && (op & (1 << (o->bits - 1))) != 0)
+ op -= 1 << o->bits;
+ (I is the instruction, O is a pointer to this structure, and OP
+ is the result; this assumes twos complement arithmetic).
+
+ If this field is not NULL, then simply call it with the
+ instruction value. It will return the value of the operand. If
+ the INVALID argument is not NULL, *INVALID will be set to
+ non-zero if this operand type can not actually be extracted from
+ this operand (i.e., the instruction does not match). If the
+ operand is valid, *INVALID will not be changed.
+
+ INSN is a pointer to an array of two `arc_insn's. The first element is
+ the insn, the second is the limm if present.
+
+ Operands that have a printable form like registers and suffixes have
+ their struct arc_operand_value pointer stored in OPVAL. */
+
+ long (*extract)
+ (arc_insn *insn, const struct arc_operand *operand, int mods,
+ const struct arc_operand_value **opval, int *invalid);
+};
+
+/* Bits that say what version of cpu we have. These should be passed to
+ arc_init_opcode_tables. At present, all there is is the cpu type. */
+
+/* CPU number, given value passed to `arc_init_opcode_tables'. */
+#define ARC_HAVE_CPU(bits) ((bits) & ARC_MACH_CPU_MASK)
+/* MACH number, given value passed to `arc_init_opcode_tables'. */
+#define ARC_HAVE_MACH(bits) ((bits) & ARC_MACH_MASK)
+
+/* Special register values: */
+#define ARC_REG_SHIMM_UPDATE 61
+#define ARC_REG_SHIMM 63
+#define ARC_REG_LIMM 62
+
+/* Non-zero if REG is a constant marker. */
+#define ARC_REG_CONSTANT_P(REG) ((REG) >= 61)
+
+/* Positions and masks of various fields: */
+#define ARC_SHIFT_REGA 21
+#define ARC_SHIFT_REGB 15
+#define ARC_SHIFT_REGC 9
+#define ARC_MASK_REG 63
+
+/* Delay slot types. */
+#define ARC_DELAY_NONE 0 /* no delay slot */
+#define ARC_DELAY_NORMAL 1 /* delay slot in both cases */
+#define ARC_DELAY_JUMP 2 /* delay slot only if branch taken */
+
+/* Non-zero if X will fit in a signed 9 bit field. */
+#define ARC_SHIMM_CONST_P(x) ((long) (x) >= -256 && (long) (x) <= 255)
+
+extern const struct arc_operand arc_operands[];
+extern const int arc_operand_count;
+extern struct arc_opcode arc_opcodes[];
+extern const int arc_opcodes_count;
+extern const struct arc_operand_value arc_suffixes[];
+extern const int arc_suffixes_count;
+extern const struct arc_operand_value arc_reg_names[];
+extern const int arc_reg_names_count;
+extern unsigned char arc_operand_map[];
+
+/* Utility fns in arc-opc.c. */
+int arc_get_opcode_mach (int, int);
+
+/* `arc_opcode_init_tables' must be called before `arc_xxx_supported'. */
+void arc_opcode_init_tables (int);
+void arc_opcode_init_insert (void);
+void arc_opcode_init_extract (void);
+const struct arc_opcode *arc_opcode_lookup_asm (const char *);
+const struct arc_opcode *arc_opcode_lookup_dis (unsigned int);
+int arc_opcode_limm_p (long *);
+const struct arc_operand_value *arc_opcode_lookup_suffix
+ (const struct arc_operand *type, int value);
+int arc_opcode_supported (const struct arc_opcode *);
+int arc_opval_supported (const struct arc_operand_value *);
+int arc_limm_fixup_adjust (arc_insn);
+int arc_insn_is_j (arc_insn);
+int arc_insn_not_jl (arc_insn);
+int arc_operand_type (int);
+struct arc_operand_value *get_ext_suffix (char *);
+int arc_get_noshortcut_flag (void);
diff --git a/contrib/binutils/include/opcode/cgen.h b/contrib/binutils/include/opcode/cgen.h
index 09c5cbf..16366fd 100644
--- a/contrib/binutils/include/opcode/cgen.h
+++ b/contrib/binutils/include/opcode/cgen.h
@@ -1,6 +1,7 @@
/* Header file for targets using CGEN: Cpu tools GENerator.
-Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002
+Free Software Foundation, Inc.
This file is part of GDB, the GNU debugger, and the GNU Binutils.
@@ -26,7 +27,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
Perhaps the definition of bfd_vma can be moved outside of bfd.h.
Or perhaps one could duplicate its definition in another file.
Until such time, this file conditionally compiles definitions that require
- bfd_vma using BFD_VERSION_DATE. */
+ bfd_vma using __BFD_H_SEEN__. */
/* Enums must be defined before they can be used.
Allow them to be used in struct definitions, even though the enum must
@@ -241,9 +242,9 @@ typedef struct cgen_fields CGEN_FIELDS;
typedef struct {
/* A pointer to the disassemble_info struct.
- We don't require dis-asm.h so we use PTR for the type here.
+ We don't require dis-asm.h so we use void * for the type here.
If NULL, BYTES is full of valid data (VALID == -1). */
- PTR dis_info;
+ void *dis_info;
/* Points to a working buffer of sufficient size. */
unsigned char *insn_bytes;
/* Mask of bytes that are valid in INSN_BYTES. */
@@ -264,8 +265,8 @@ typedef struct {
If not it is left alone.
The result is NULL if success or an error message. */
typedef const char * (cgen_parse_fn)
- PARAMS ((CGEN_CPU_DESC, const CGEN_INSN *insn_,
- const char **strp_, CGEN_FIELDS *fields_));
+ (CGEN_CPU_DESC, const CGEN_INSN *insn_,
+ const char **strp_, CGEN_FIELDS *fields_);
/* Insert handler.
CD is a cpu table descriptor.
@@ -276,11 +277,11 @@ typedef const char * (cgen_parse_fn)
PC is the pc value of the insn.
The result is an error message or NULL if success. */
-#ifdef BFD_VERSION_DATE
+#ifdef __BFD_H_SEEN__
typedef const char * (cgen_insert_fn)
- PARAMS ((CGEN_CPU_DESC, const CGEN_INSN *insn_,
- CGEN_FIELDS *fields_, CGEN_INSN_BYTES_PTR insnp_,
- bfd_vma pc_));
+ (CGEN_CPU_DESC, const CGEN_INSN *insn_,
+ CGEN_FIELDS *fields_, CGEN_INSN_BYTES_PTR insnp_,
+ bfd_vma pc_);
#else
typedef const char * (cgen_insert_fn) ();
#endif
@@ -297,11 +298,11 @@ typedef const char * (cgen_insert_fn) ();
PC is the pc value of the insn.
The result is the length of the insn in bits or zero if not recognized. */
-#ifdef BFD_VERSION_DATE
+#ifdef __BFD_H_SEEN__
typedef int (cgen_extract_fn)
- PARAMS ((CGEN_CPU_DESC, const CGEN_INSN *insn_,
- CGEN_EXTRACT_INFO *ex_info_, CGEN_INSN_INT base_insn_,
- CGEN_FIELDS *fields_, bfd_vma pc_));
+ (CGEN_CPU_DESC, const CGEN_INSN *insn_,
+ CGEN_EXTRACT_INFO *ex_info_, CGEN_INSN_INT base_insn_,
+ CGEN_FIELDS *fields_, bfd_vma pc_);
#else
typedef int (cgen_extract_fn) ();
#endif
@@ -316,10 +317,10 @@ typedef int (cgen_extract_fn) ();
PC is the pc value of the insn.
LEN is the length of the insn, in bits. */
-#ifdef BFD_VERSION_DATE
+#ifdef __BFD_H_SEEN__
typedef void (cgen_print_fn)
- PARAMS ((CGEN_CPU_DESC, PTR info_, const CGEN_INSN *insn_,
- CGEN_FIELDS *fields_, bfd_vma pc_, int len_));
+ (CGEN_CPU_DESC, void * info_, const CGEN_INSN *insn_,
+ CGEN_FIELDS *fields_, bfd_vma pc_, int len_);
#else
typedef void (cgen_print_fn) ();
#endif
@@ -381,11 +382,11 @@ enum cgen_parse_operand_result
CGEN_PARSE_OPERAND_RESULT_ERROR
};
-#ifdef BFD_VERSION_DATE /* Don't require bfd.h unnecessarily. */
+#ifdef __BFD_H_SEEN__ /* Don't require bfd.h unnecessarily. */
typedef const char * (cgen_parse_operand_fn)
- PARAMS ((CGEN_CPU_DESC,
- enum cgen_parse_operand_type, const char **, int, int,
- enum cgen_parse_operand_result *, bfd_vma *));
+ (CGEN_CPU_DESC,
+ enum cgen_parse_operand_type, const char **, int, int,
+ enum cgen_parse_operand_result *, bfd_vma *);
#else
typedef const char * (cgen_parse_operand_fn) ();
#endif
@@ -393,11 +394,11 @@ typedef const char * (cgen_parse_operand_fn) ();
/* Set the cgen_parse_operand_fn callback. */
extern void cgen_set_parse_operand_fn
- PARAMS ((CGEN_CPU_DESC, cgen_parse_operand_fn));
+ (CGEN_CPU_DESC, cgen_parse_operand_fn);
/* Called before trying to match a table entry with the insn. */
-extern void cgen_init_parse_operand PARAMS ((CGEN_CPU_DESC));
+extern void cgen_init_parse_operand (CGEN_CPU_DESC);
/* Operand values (keywords, integers, symbols, etc.) */
@@ -421,7 +422,7 @@ typedef struct
/* There is currently no example where both index specs and value specs
are required, so for now both are clumped under "asm_data". */
enum cgen_asm_type asm_type;
- PTR asm_data;
+ void *asm_data;
#ifndef CGEN_HW_NBOOL_ATTRS
#define CGEN_HW_NBOOL_ATTRS 1
#endif
@@ -452,9 +453,9 @@ typedef struct {
} CGEN_HW_TABLE;
extern const CGEN_HW_ENTRY * cgen_hw_lookup_by_name
- PARAMS ((CGEN_CPU_DESC, const char *));
+ (CGEN_CPU_DESC, const char *);
extern const CGEN_HW_ENTRY * cgen_hw_lookup_by_num
- PARAMS ((CGEN_CPU_DESC, unsigned int));
+ (CGEN_CPU_DESC, unsigned int);
/* This struct is used to describe things like register names, etc. */
@@ -542,41 +543,41 @@ typedef struct
/* Lookup a keyword from its name. */
const CGEN_KEYWORD_ENTRY *cgen_keyword_lookup_name
- PARAMS ((CGEN_KEYWORD *, const char *));
+ (CGEN_KEYWORD *, const char *);
/* Lookup a keyword from its value. */
const CGEN_KEYWORD_ENTRY *cgen_keyword_lookup_value
- PARAMS ((CGEN_KEYWORD *, int));
+ (CGEN_KEYWORD *, int);
/* Add a keyword. */
-void cgen_keyword_add PARAMS ((CGEN_KEYWORD *, CGEN_KEYWORD_ENTRY *));
+void cgen_keyword_add (CGEN_KEYWORD *, CGEN_KEYWORD_ENTRY *);
/* Keyword searching.
This can be used to retrieve every keyword, or a subset. */
CGEN_KEYWORD_SEARCH cgen_keyword_search_init
- PARAMS ((CGEN_KEYWORD *, const char *));
+ (CGEN_KEYWORD *, const char *);
const CGEN_KEYWORD_ENTRY *cgen_keyword_search_next
- PARAMS ((CGEN_KEYWORD_SEARCH *));
+ (CGEN_KEYWORD_SEARCH *);
/* Operand value support routines. */
extern const char *cgen_parse_keyword
- PARAMS ((CGEN_CPU_DESC, const char **, CGEN_KEYWORD *, long *));
-#ifdef BFD_VERSION_DATE /* Don't require bfd.h unnecessarily. */
+ (CGEN_CPU_DESC, const char **, CGEN_KEYWORD *, long *);
+#ifdef __BFD_H_SEEN__ /* Don't require bfd.h unnecessarily. */
extern const char *cgen_parse_signed_integer
- PARAMS ((CGEN_CPU_DESC, const char **, int, long *));
+ (CGEN_CPU_DESC, const char **, int, long *);
extern const char *cgen_parse_unsigned_integer
- PARAMS ((CGEN_CPU_DESC, const char **, int, unsigned long *));
+ (CGEN_CPU_DESC, const char **, int, unsigned long *);
extern const char *cgen_parse_address
- PARAMS ((CGEN_CPU_DESC, const char **, int, int,
- enum cgen_parse_operand_result *, bfd_vma *));
+ (CGEN_CPU_DESC, const char **, int, int,
+ enum cgen_parse_operand_result *, bfd_vma *);
extern const char *cgen_validate_signed_integer
- PARAMS ((long, long, long));
+ (long, long, long);
extern const char *cgen_validate_unsigned_integer
- PARAMS ((unsigned long, unsigned long, unsigned long));
+ (unsigned long, unsigned long, unsigned long);
#endif
/* Operand modes. */
@@ -620,8 +621,9 @@ typedef struct cgen_maybe_multi_ifield
n: indexed by array of more cgen_maybe_multi_ifields. */
union
{
- struct cgen_maybe_multi_ifield * multi;
- struct cgen_ifld * leaf;
+ const void *p;
+ const struct cgen_maybe_multi_ifield * multi;
+ const struct cgen_ifld * leaf;
} val;
}
CGEN_MAYBE_MULTI_IFLD;
@@ -703,9 +705,9 @@ typedef struct {
} CGEN_OPERAND_TABLE;
extern const CGEN_OPERAND * cgen_operand_lookup_by_name
- PARAMS ((CGEN_CPU_DESC, const char *));
+ (CGEN_CPU_DESC, const char *);
extern const CGEN_OPERAND * cgen_operand_lookup_by_num
- PARAMS ((CGEN_CPU_DESC, int));
+ (CGEN_CPU_DESC, int);
/* Instruction operand instances.
@@ -1059,8 +1061,8 @@ typedef struct
/* Return number of instructions. This includes any added at run-time. */
-extern int cgen_insn_count PARAMS ((CGEN_CPU_DESC));
-extern int cgen_macro_insn_count PARAMS ((CGEN_CPU_DESC));
+extern int cgen_insn_count (CGEN_CPU_DESC);
+extern int cgen_macro_insn_count (CGEN_CPU_DESC);
/* Macros to access the other insn elements not recorded in CGEN_IBASE. */
@@ -1124,9 +1126,10 @@ typedef struct cgen_minsn_expansion {
If the expansion fails (e.g. "no match") NULL is returned.
Space for the expansion is obtained with malloc.
It is up to the caller to free it. */
- const char * (* fn) PARAMS ((const struct cgen_minsn_expansion *,
- const char *, const char **, int *,
- CGEN_OPERAND **));
+ const char * (* fn)
+ (const struct cgen_minsn_expansion *,
+ const char *, const char **, int *,
+ CGEN_OPERAND **);
#define CGEN_MIEXPN_FN(ex) ((ex)->fn)
/* Instruction(s) the macro expands to.
@@ -1144,15 +1147,15 @@ typedef struct cgen_minsn_expansion {
may contain further macro invocations. */
extern const char * cgen_expand_macro_insn
- PARAMS ((CGEN_CPU_DESC, const struct cgen_minsn_expansion *,
- const char *, const char **, int *, CGEN_OPERAND **));
+ (CGEN_CPU_DESC, const struct cgen_minsn_expansion *,
+ const char *, const char **, int *, CGEN_OPERAND **);
/* The assembler insn table is hashed based on some function of the mnemonic
(the actually hashing done is up to the target, but we provide a few
examples like the first letter or a function of the entire mnemonic). */
extern CGEN_INSN_LIST * cgen_asm_lookup_insn
- PARAMS ((CGEN_CPU_DESC, const char *));
+ (CGEN_CPU_DESC, const char *);
#define CGEN_ASM_LOOKUP_INSN(cd, string) cgen_asm_lookup_insn ((cd), (string))
#define CGEN_ASM_NEXT_INSN(insn) ((insn)->next)
@@ -1160,7 +1163,7 @@ extern CGEN_INSN_LIST * cgen_asm_lookup_insn
instruction (the actually hashing done is up to the target). */
extern CGEN_INSN_LIST * cgen_dis_lookup_insn
- PARAMS ((CGEN_CPU_DESC, const char *, CGEN_INSN_INT));
+ (CGEN_CPU_DESC, const char *, CGEN_INSN_INT);
/* FIXME: delete these two */
#define CGEN_DIS_LOOKUP_INSN(cd, buf, value) cgen_dis_lookup_insn ((cd), (buf), (value))
#define CGEN_DIS_NEXT_INSN(insn) ((insn)->next)
@@ -1244,25 +1247,24 @@ typedef struct cgen_cpu_desc
int int_insn_p;
/* Called to rebuild the tables after something has changed. */
- void (*rebuild_tables) PARAMS ((CGEN_CPU_DESC));
+ void (*rebuild_tables) (CGEN_CPU_DESC);
/* Operand parser callback. */
cgen_parse_operand_fn * parse_operand_fn;
/* Parse/insert/extract/print cover fns for operands. */
const char * (*parse_operand)
- PARAMS ((CGEN_CPU_DESC, int opindex_, const char **,
- CGEN_FIELDS *fields_));
-#ifdef BFD_VERSION_DATE
+ (CGEN_CPU_DESC, int opindex_, const char **, CGEN_FIELDS *fields_);
+#ifdef __BFD_H_SEEN__
const char * (*insert_operand)
- PARAMS ((CGEN_CPU_DESC, int opindex_, CGEN_FIELDS *fields_,
- CGEN_INSN_BYTES_PTR, bfd_vma pc_));
+ (CGEN_CPU_DESC, int opindex_, CGEN_FIELDS *fields_,
+ CGEN_INSN_BYTES_PTR, bfd_vma pc_);
int (*extract_operand)
- PARAMS ((CGEN_CPU_DESC, int opindex_, CGEN_EXTRACT_INFO *, CGEN_INSN_INT,
- CGEN_FIELDS *fields_, bfd_vma pc_));
+ (CGEN_CPU_DESC, int opindex_, CGEN_EXTRACT_INFO *, CGEN_INSN_INT,
+ CGEN_FIELDS *fields_, bfd_vma pc_);
void (*print_operand)
- PARAMS ((CGEN_CPU_DESC, int opindex_, PTR info_, CGEN_FIELDS * fields_,
- void const *attrs_, bfd_vma pc_, int length_));
+ (CGEN_CPU_DESC, int opindex_, void * info_, CGEN_FIELDS * fields_,
+ void const *attrs_, bfd_vma pc_, int length_);
#else
const char * (*insert_operand) ();
int (*extract_operand) ();
@@ -1278,19 +1280,19 @@ typedef struct cgen_cpu_desc
#define CGEN_CPU_SIZEOF_FIELDS(cd) ((cd)->sizeof_fields)
/* Set the bitsize field. */
- void (*set_fields_bitsize) PARAMS ((CGEN_FIELDS *fields_, int size_));
+ void (*set_fields_bitsize) (CGEN_FIELDS *fields_, int size_);
#define CGEN_CPU_SET_FIELDS_BITSIZE(cd) ((cd)->set_fields_bitsize)
/* CGEN_FIELDS accessors. */
int (*get_int_operand)
- PARAMS ((CGEN_CPU_DESC, int opindex_, const CGEN_FIELDS *fields_));
+ (CGEN_CPU_DESC, int opindex_, const CGEN_FIELDS *fields_);
void (*set_int_operand)
- PARAMS ((CGEN_CPU_DESC, int opindex_, CGEN_FIELDS *fields_, int value_));
-#ifdef BFD_VERSION_DATE
+ (CGEN_CPU_DESC, int opindex_, CGEN_FIELDS *fields_, int value_);
+#ifdef __BFD_H_SEEN__
bfd_vma (*get_vma_operand)
- PARAMS ((CGEN_CPU_DESC, int opindex_, const CGEN_FIELDS *fields_));
+ (CGEN_CPU_DESC, int opindex_, const CGEN_FIELDS *fields_);
void (*set_vma_operand)
- PARAMS ((CGEN_CPU_DESC, int opindex_, CGEN_FIELDS *fields_, bfd_vma value_));
+ (CGEN_CPU_DESC, int opindex_, CGEN_FIELDS *fields_, bfd_vma value_);
#else
long (*get_vma_operand) ();
void (*set_vma_operand) ();
@@ -1312,19 +1314,19 @@ typedef struct cgen_cpu_desc
#define CGEN_PRINT_FN(cd, insn) (cd->print_handlers[(insn)->opcode->handlers.print])
/* Return non-zero if insn should be added to hash table. */
- int (* asm_hash_p) PARAMS ((const CGEN_INSN *));
+ int (* asm_hash_p) (const CGEN_INSN *);
/* Assembler hash function. */
- unsigned int (* asm_hash) PARAMS ((const char *));
+ unsigned int (* asm_hash) (const char *);
/* Number of entries in assembler hash table. */
unsigned int asm_hash_size;
/* Return non-zero if insn should be added to hash table. */
- int (* dis_hash_p) PARAMS ((const CGEN_INSN *));
+ int (* dis_hash_p) (const CGEN_INSN *);
/* Disassembler hash function. */
- unsigned int (* dis_hash) PARAMS ((const char *, CGEN_INSN_INT));
+ unsigned int (* dis_hash) (const char *, CGEN_INSN_INT);
/* Number of entries in disassembler hash table. */
unsigned int dis_hash_size;
@@ -1379,81 +1381,80 @@ extern CGEN_CPU_DESC CGEN_SYM (cpu_open) (enum cgen_cpu_open_arg, ...);
/* Cover fn to handle simple case. */
-extern CGEN_CPU_DESC CGEN_SYM (cpu_open_1) PARAMS ((const char *mach_name_,
- enum cgen_endian endian_));
+extern CGEN_CPU_DESC CGEN_SYM (cpu_open_1)
+ (const char *mach_name_, enum cgen_endian endian_);
/* Close it. */
-extern void CGEN_SYM (cpu_close) PARAMS ((CGEN_CPU_DESC));
+extern void CGEN_SYM (cpu_close) (CGEN_CPU_DESC);
/* Initialize the opcode table for use.
Called by init_asm/init_dis. */
-extern void CGEN_SYM (init_opcode_table) PARAMS ((CGEN_CPU_DESC cd_));
+extern void CGEN_SYM (init_opcode_table) (CGEN_CPU_DESC cd_);
/* build the insn selection regex.
called by init_opcode_table */
-extern char * CGEN_SYM(build_insn_regex) PARAMS ((CGEN_INSN *insn_));
+extern char * CGEN_SYM(build_insn_regex) (CGEN_INSN *insn_);
/* Initialize the ibld table for use.
Called by init_asm/init_dis. */
-extern void CGEN_SYM (init_ibld_table) PARAMS ((CGEN_CPU_DESC cd_));
+extern void CGEN_SYM (init_ibld_table) (CGEN_CPU_DESC cd_);
/* Initialize an cpu table for assembler or disassembler use.
These must be called immediately after cpu_open. */
-extern void CGEN_SYM (init_asm) PARAMS ((CGEN_CPU_DESC));
-extern void CGEN_SYM (init_dis) PARAMS ((CGEN_CPU_DESC));
+extern void CGEN_SYM (init_asm) (CGEN_CPU_DESC);
+extern void CGEN_SYM (init_dis) (CGEN_CPU_DESC);
/* Initialize the operand instance table for use. */
-extern void CGEN_SYM (init_opinst_table) PARAMS ((CGEN_CPU_DESC cd_));
+extern void CGEN_SYM (init_opinst_table) (CGEN_CPU_DESC cd_);
/* Assemble an instruction. */
extern const CGEN_INSN * CGEN_SYM (assemble_insn)
- PARAMS ((CGEN_CPU_DESC, const char *, CGEN_FIELDS *,
- CGEN_INSN_BYTES_PTR, char **));
+ (CGEN_CPU_DESC, const char *, CGEN_FIELDS *,
+ CGEN_INSN_BYTES_PTR, char **);
extern const CGEN_KEYWORD CGEN_SYM (operand_mach);
-extern int CGEN_SYM (get_mach) PARAMS ((const char *));
+extern int CGEN_SYM (get_mach) (const char *);
/* Operand index computation. */
extern const CGEN_INSN * cgen_lookup_insn
- PARAMS ((CGEN_CPU_DESC, const CGEN_INSN * insn_,
- CGEN_INSN_INT int_value_, unsigned char *bytes_value_,
- int length_, CGEN_FIELDS *fields_, int alias_p_));
+ (CGEN_CPU_DESC, const CGEN_INSN * insn_,
+ CGEN_INSN_INT int_value_, unsigned char *bytes_value_,
+ int length_, CGEN_FIELDS *fields_, int alias_p_);
extern void cgen_get_insn_operands
- PARAMS ((CGEN_CPU_DESC, const CGEN_INSN * insn_,
- const CGEN_FIELDS *fields_, int *indices_));
+ (CGEN_CPU_DESC, const CGEN_INSN * insn_,
+ const CGEN_FIELDS *fields_, int *indices_);
extern const CGEN_INSN * cgen_lookup_get_insn_operands
- PARAMS ((CGEN_CPU_DESC, const CGEN_INSN *insn_,
- CGEN_INSN_INT int_value_, unsigned char *bytes_value_,
- int length_, int *indices_, CGEN_FIELDS *fields_));
+ (CGEN_CPU_DESC, const CGEN_INSN *insn_,
+ CGEN_INSN_INT int_value_, unsigned char *bytes_value_,
+ int length_, int *indices_, CGEN_FIELDS *fields_);
/* Cover fns to bfd_get/set. */
extern CGEN_INSN_INT cgen_get_insn_value
- PARAMS ((CGEN_CPU_DESC, unsigned char *, int));
+ (CGEN_CPU_DESC, unsigned char *, int);
extern void cgen_put_insn_value
- PARAMS ((CGEN_CPU_DESC, unsigned char *, int, CGEN_INSN_INT));
+ (CGEN_CPU_DESC, unsigned char *, int, CGEN_INSN_INT);
/* Read in a cpu description file.
??? For future concerns, including adding instructions to the assembler/
disassembler at run-time. */
-extern const char * cgen_read_cpu_file
- PARAMS ((CGEN_CPU_DESC, const char * filename_));
+extern const char * cgen_read_cpu_file (CGEN_CPU_DESC, const char * filename_);
/* Allow signed overflow of instruction fields. */
-extern void cgen_set_signed_overflow_ok PARAMS ((CGEN_CPU_DESC));
+extern void cgen_set_signed_overflow_ok (CGEN_CPU_DESC);
/* Generate an error message if a signed field in an instruction overflows. */
-extern void cgen_clear_signed_overflow_ok PARAMS ((CGEN_CPU_DESC));
+extern void cgen_clear_signed_overflow_ok (CGEN_CPU_DESC);
/* Will an error message be generated if a signed field in an instruction overflows ? */
-extern unsigned int cgen_signed_overflow_ok_p PARAMS ((CGEN_CPU_DESC));
+extern unsigned int cgen_signed_overflow_ok_p (CGEN_CPU_DESC);
#endif /* CGEN_H */
diff --git a/contrib/binutils/include/opcode/convex.h b/contrib/binutils/include/opcode/convex.h
new file mode 100644
index 0000000..ccf5568
--- /dev/null
+++ b/contrib/binutils/include/opcode/convex.h
@@ -0,0 +1,1707 @@
+/* Information for instruction disassembly on the Convex.
+ Copyright 1989, 1993, 2002 Free Software Foundation, Inc.
+
+This file is part of GDB.
+
+This program is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2 of the License, or
+(at your option) any later version.
+
+This program is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with this program; if not, write to the Free Software
+Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+#define xxx 0
+#define rrr 1
+#define rr 2
+#define rxr 3
+#define r 4
+#define nops 5
+#define nr 6
+#define pcrel 7
+#define lr 8
+#define rxl 9
+#define rlr 10
+#define rrl 11
+#define iml 12
+#define imr 13
+#define a1r 14
+#define a1l 15
+#define a2r 16
+#define a2l 17
+#define a3 18
+#define a4 19
+#define a5 20
+#define V 1
+#define S 2
+#define VM 3
+#define A 4
+#define VL 5
+#define VS 6
+#define VLS 7
+#define PSW 8
+/* Prevent an error during "make depend". */
+#if !defined (PC)
+#define PC 9
+#endif
+#define ITR 10
+#define VV 11
+#define ITSR 12
+#define TOC 13
+#define CIR 14
+#define TTR 15
+#define VMU 16
+#define VML 17
+#define ICR 18
+#define TCPU 19
+#define CPUID 20
+#define TID 21
+
+const char *op[] = {
+ "",
+ "v0\0v1\0v2\0v3\0v4\0v5\0v6\0v7",
+ "s0\0s1\0s2\0s3\0s4\0s5\0s6\0s7",
+ "vm",
+ "sp\0a1\0a2\0a3\0a4\0a5\0ap\0fp",
+ "vl",
+ "vs",
+ "vls",
+ "psw",
+ "pc",
+ "itr",
+ "vv",
+ "itsr",
+ "toc",
+ "cir",
+ "ttr",
+ "vmu",
+ "vml",
+ "icr",
+ "tcpu",
+ "cpuid",
+ "tid",
+};
+
+const struct formstr format0[] = {
+ {0,0,rrr,V,S,S}, /* mov */
+ {0,0,rrr,S,S,V}, /* mov */
+ {1,1,rrr,V,V,V}, /* merg.t */
+ {2,1,rrr,V,V,V}, /* mask.t */
+ {1,2,rrr,V,S,V}, /* merg.f */
+ {2,2,rrr,V,S,V}, /* mask.f */
+ {1,1,rrr,V,S,V}, /* merg.t */
+ {2,1,rrr,V,S,V}, /* mask.t */
+ {3,3,rrr,V,V,V}, /* mul.s */
+ {3,4,rrr,V,V,V}, /* mul.d */
+ {4,3,rrr,V,V,V}, /* div.s */
+ {4,4,rrr,V,V,V}, /* div.d */
+ {3,3,rrr,V,S,V}, /* mul.s */
+ {3,4,rrr,V,S,V}, /* mul.d */
+ {4,3,rrr,V,S,V}, /* div.s */
+ {4,4,rrr,V,S,V}, /* div.d */
+ {5,0,rrr,V,V,V}, /* and */
+ {6,0,rrr,V,V,V}, /* or */
+ {7,0,rrr,V,V,V}, /* xor */
+ {8,0,rrr,V,V,V}, /* shf */
+ {5,0,rrr,V,S,V}, /* and */
+ {6,0,rrr,V,S,V}, /* or */
+ {7,0,rrr,V,S,V}, /* xor */
+ {8,0,rrr,V,S,V}, /* shf */
+ {9,3,rrr,V,V,V}, /* add.s */
+ {9,4,rrr,V,V,V}, /* add.d */
+ {10,3,rrr,V,V,V}, /* sub.s */
+ {10,4,rrr,V,V,V}, /* sub.d */
+ {9,3,rrr,V,S,V}, /* add.s */
+ {9,4,rrr,V,S,V}, /* add.d */
+ {10,3,rrr,V,S,V}, /* sub.s */
+ {10,4,rrr,V,S,V}, /* sub.d */
+ {9,5,rrr,V,V,V}, /* add.b */
+ {9,6,rrr,V,V,V}, /* add.h */
+ {9,7,rrr,V,V,V}, /* add.w */
+ {9,8,rrr,V,V,V}, /* add.l */
+ {9,5,rrr,V,S,V}, /* add.b */
+ {9,6,rrr,V,S,V}, /* add.h */
+ {9,7,rrr,V,S,V}, /* add.w */
+ {9,8,rrr,V,S,V}, /* add.l */
+ {10,5,rrr,V,V,V}, /* sub.b */
+ {10,6,rrr,V,V,V}, /* sub.h */
+ {10,7,rrr,V,V,V}, /* sub.w */
+ {10,8,rrr,V,V,V}, /* sub.l */
+ {10,5,rrr,V,S,V}, /* sub.b */
+ {10,6,rrr,V,S,V}, /* sub.h */
+ {10,7,rrr,V,S,V}, /* sub.w */
+ {10,8,rrr,V,S,V}, /* sub.l */
+ {3,5,rrr,V,V,V}, /* mul.b */
+ {3,6,rrr,V,V,V}, /* mul.h */
+ {3,7,rrr,V,V,V}, /* mul.w */
+ {3,8,rrr,V,V,V}, /* mul.l */
+ {3,5,rrr,V,S,V}, /* mul.b */
+ {3,6,rrr,V,S,V}, /* mul.h */
+ {3,7,rrr,V,S,V}, /* mul.w */
+ {3,8,rrr,V,S,V}, /* mul.l */
+ {4,5,rrr,V,V,V}, /* div.b */
+ {4,6,rrr,V,V,V}, /* div.h */
+ {4,7,rrr,V,V,V}, /* div.w */
+ {4,8,rrr,V,V,V}, /* div.l */
+ {4,5,rrr,V,S,V}, /* div.b */
+ {4,6,rrr,V,S,V}, /* div.h */
+ {4,7,rrr,V,S,V}, /* div.w */
+ {4,8,rrr,V,S,V}, /* div.l */
+};
+
+const struct formstr format1[] = {
+ {11,0,xxx,0,0,0}, /* exit */
+ {12,0,a3,0,0,0}, /* jmp */
+ {13,2,a3,0,0,0}, /* jmpi.f */
+ {13,1,a3,0,0,0}, /* jmpi.t */
+ {14,2,a3,0,0,0}, /* jmpa.f */
+ {14,1,a3,0,0,0}, /* jmpa.t */
+ {15,2,a3,0,0,0}, /* jmps.f */
+ {15,1,a3,0,0,0}, /* jmps.t */
+ {16,0,a3,0,0,0}, /* tac */
+ {17,0,a1r,A,0,0}, /* ldea */
+ {18,8,a1l,VLS,0,0}, /* ld.l */
+ {18,9,a1l,VM,0,0}, /* ld.x */
+ {19,0,a3,0,0,0}, /* tas */
+ {20,0,a3,0,0,0}, /* pshea */
+ {21,8,a2l,VLS,0,0}, /* st.l */
+ {21,9,a2l,VM,0,0}, /* st.x */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {22,0,a3,0,0,0}, /* call */
+ {23,0,a3,0,0,0}, /* calls */
+ {24,0,a3,0,0,0}, /* callq */
+ {25,0,a1r,A,0,0}, /* pfork */
+ {26,5,a2r,S,0,0}, /* ste.b */
+ {26,6,a2r,S,0,0}, /* ste.h */
+ {26,7,a2r,S,0,0}, /* ste.w */
+ {26,8,a2r,S,0,0}, /* ste.l */
+ {18,5,a1r,A,0,0}, /* ld.b */
+ {18,6,a1r,A,0,0}, /* ld.h */
+ {18,7,a1r,A,0,0}, /* ld.w */
+ {27,7,a1r,A,0,0}, /* incr.w */
+ {21,5,a2r,A,0,0}, /* st.b */
+ {21,6,a2r,A,0,0}, /* st.h */
+ {21,7,a2r,A,0,0}, /* st.w */
+ {27,8,a1r,S,0,0}, /* incr.l */
+ {18,5,a1r,S,0,0}, /* ld.b */
+ {18,6,a1r,S,0,0}, /* ld.h */
+ {18,7,a1r,S,0,0}, /* ld.w */
+ {18,8,a1r,S,0,0}, /* ld.l */
+ {21,5,a2r,S,0,0}, /* st.b */
+ {21,6,a2r,S,0,0}, /* st.h */
+ {21,7,a2r,S,0,0}, /* st.w */
+ {21,8,a2r,S,0,0}, /* st.l */
+ {18,5,a1r,V,0,0}, /* ld.b */
+ {18,6,a1r,V,0,0}, /* ld.h */
+ {18,7,a1r,V,0,0}, /* ld.w */
+ {18,8,a1r,V,0,0}, /* ld.l */
+ {21,5,a2r,V,0,0}, /* st.b */
+ {21,6,a2r,V,0,0}, /* st.h */
+ {21,7,a2r,V,0,0}, /* st.w */
+ {21,8,a2r,V,0,0}, /* st.l */
+};
+
+const struct formstr format2[] = {
+ {28,5,rr,A,A,0}, /* cvtw.b */
+ {28,6,rr,A,A,0}, /* cvtw.h */
+ {29,7,rr,A,A,0}, /* cvtb.w */
+ {30,7,rr,A,A,0}, /* cvth.w */
+ {28,5,rr,S,S,0}, /* cvtw.b */
+ {28,6,rr,S,S,0}, /* cvtw.h */
+ {29,7,rr,S,S,0}, /* cvtb.w */
+ {30,7,rr,S,S,0}, /* cvth.w */
+ {28,3,rr,S,S,0}, /* cvtw.s */
+ {31,7,rr,S,S,0}, /* cvts.w */
+ {32,3,rr,S,S,0}, /* cvtd.s */
+ {31,4,rr,S,S,0}, /* cvts.d */
+ {31,8,rr,S,S,0}, /* cvts.l */
+ {32,8,rr,S,S,0}, /* cvtd.l */
+ {33,3,rr,S,S,0}, /* cvtl.s */
+ {33,4,rr,S,S,0}, /* cvtl.d */
+ {34,0,rr,A,A,0}, /* ldpa */
+ {8,0,nr,A,0,0}, /* shf */
+ {18,6,nr,A,0,0}, /* ld.h */
+ {18,7,nr,A,0,0}, /* ld.w */
+ {33,7,rr,S,S,0}, /* cvtl.w */
+ {28,8,rr,S,S,0}, /* cvtw.l */
+ {35,1,rr,S,S,0}, /* plc.t */
+ {36,0,rr,S,S,0}, /* tzc */
+ {37,6,rr,A,A,0}, /* eq.h */
+ {37,7,rr,A,A,0}, /* eq.w */
+ {37,6,nr,A,0,0}, /* eq.h */
+ {37,7,nr,A,0,0}, /* eq.w */
+ {37,5,rr,S,S,0}, /* eq.b */
+ {37,6,rr,S,S,0}, /* eq.h */
+ {37,7,rr,S,S,0}, /* eq.w */
+ {37,8,rr,S,S,0}, /* eq.l */
+ {38,6,rr,A,A,0}, /* leu.h */
+ {38,7,rr,A,A,0}, /* leu.w */
+ {38,6,nr,A,0,0}, /* leu.h */
+ {38,7,nr,A,0,0}, /* leu.w */
+ {38,5,rr,S,S,0}, /* leu.b */
+ {38,6,rr,S,S,0}, /* leu.h */
+ {38,7,rr,S,S,0}, /* leu.w */
+ {38,8,rr,S,S,0}, /* leu.l */
+ {39,6,rr,A,A,0}, /* ltu.h */
+ {39,7,rr,A,A,0}, /* ltu.w */
+ {39,6,nr,A,0,0}, /* ltu.h */
+ {39,7,nr,A,0,0}, /* ltu.w */
+ {39,5,rr,S,S,0}, /* ltu.b */
+ {39,6,rr,S,S,0}, /* ltu.h */
+ {39,7,rr,S,S,0}, /* ltu.w */
+ {39,8,rr,S,S,0}, /* ltu.l */
+ {40,6,rr,A,A,0}, /* le.h */
+ {40,7,rr,A,A,0}, /* le.w */
+ {40,6,nr,A,0,0}, /* le.h */
+ {40,7,nr,A,0,0}, /* le.w */
+ {40,5,rr,S,S,0}, /* le.b */
+ {40,6,rr,S,S,0}, /* le.h */
+ {40,7,rr,S,S,0}, /* le.w */
+ {40,8,rr,S,S,0}, /* le.l */
+ {41,6,rr,A,A,0}, /* lt.h */
+ {41,7,rr,A,A,0}, /* lt.w */
+ {41,6,nr,A,0,0}, /* lt.h */
+ {41,7,nr,A,0,0}, /* lt.w */
+ {41,5,rr,S,S,0}, /* lt.b */
+ {41,6,rr,S,S,0}, /* lt.h */
+ {41,7,rr,S,S,0}, /* lt.w */
+ {41,8,rr,S,S,0}, /* lt.l */
+ {9,7,rr,S,A,0}, /* add.w */
+ {8,0,rr,A,A,0}, /* shf */
+ {0,0,rr,A,A,0}, /* mov */
+ {0,0,rr,S,A,0}, /* mov */
+ {0,7,rr,S,S,0}, /* mov.w */
+ {8,0,rr,S,S,0}, /* shf */
+ {0,0,rr,S,S,0}, /* mov */
+ {0,0,rr,A,S,0}, /* mov */
+ {5,0,rr,A,A,0}, /* and */
+ {6,0,rr,A,A,0}, /* or */
+ {7,0,rr,A,A,0}, /* xor */
+ {42,0,rr,A,A,0}, /* not */
+ {5,0,rr,S,S,0}, /* and */
+ {6,0,rr,S,S,0}, /* or */
+ {7,0,rr,S,S,0}, /* xor */
+ {42,0,rr,S,S,0}, /* not */
+ {40,3,rr,S,S,0}, /* le.s */
+ {40,4,rr,S,S,0}, /* le.d */
+ {41,3,rr,S,S,0}, /* lt.s */
+ {41,4,rr,S,S,0}, /* lt.d */
+ {9,3,rr,S,S,0}, /* add.s */
+ {9,4,rr,S,S,0}, /* add.d */
+ {10,3,rr,S,S,0}, /* sub.s */
+ {10,4,rr,S,S,0}, /* sub.d */
+ {37,3,rr,S,S,0}, /* eq.s */
+ {37,4,rr,S,S,0}, /* eq.d */
+ {43,6,rr,A,A,0}, /* neg.h */
+ {43,7,rr,A,A,0}, /* neg.w */
+ {3,3,rr,S,S,0}, /* mul.s */
+ {3,4,rr,S,S,0}, /* mul.d */
+ {4,3,rr,S,S,0}, /* div.s */
+ {4,4,rr,S,S,0}, /* div.d */
+ {9,6,rr,A,A,0}, /* add.h */
+ {9,7,rr,A,A,0}, /* add.w */
+ {9,6,nr,A,0,0}, /* add.h */
+ {9,7,nr,A,0,0}, /* add.w */
+ {9,5,rr,S,S,0}, /* add.b */
+ {9,6,rr,S,S,0}, /* add.h */
+ {9,7,rr,S,S,0}, /* add.w */
+ {9,8,rr,S,S,0}, /* add.l */
+ {10,6,rr,A,A,0}, /* sub.h */
+ {10,7,rr,A,A,0}, /* sub.w */
+ {10,6,nr,A,0,0}, /* sub.h */
+ {10,7,nr,A,0,0}, /* sub.w */
+ {10,5,rr,S,S,0}, /* sub.b */
+ {10,6,rr,S,S,0}, /* sub.h */
+ {10,7,rr,S,S,0}, /* sub.w */
+ {10,8,rr,S,S,0}, /* sub.l */
+ {3,6,rr,A,A,0}, /* mul.h */
+ {3,7,rr,A,A,0}, /* mul.w */
+ {3,6,nr,A,0,0}, /* mul.h */
+ {3,7,nr,A,0,0}, /* mul.w */
+ {3,5,rr,S,S,0}, /* mul.b */
+ {3,6,rr,S,S,0}, /* mul.h */
+ {3,7,rr,S,S,0}, /* mul.w */
+ {3,8,rr,S,S,0}, /* mul.l */
+ {4,6,rr,A,A,0}, /* div.h */
+ {4,7,rr,A,A,0}, /* div.w */
+ {4,6,nr,A,0,0}, /* div.h */
+ {4,7,nr,A,0,0}, /* div.w */
+ {4,5,rr,S,S,0}, /* div.b */
+ {4,6,rr,S,S,0}, /* div.h */
+ {4,7,rr,S,S,0}, /* div.w */
+ {4,8,rr,S,S,0}, /* div.l */
+};
+
+const struct formstr format3[] = {
+ {32,3,rr,V,V,0}, /* cvtd.s */
+ {31,4,rr,V,V,0}, /* cvts.d */
+ {33,4,rr,V,V,0}, /* cvtl.d */
+ {32,8,rr,V,V,0}, /* cvtd.l */
+ {0,0,rrl,S,S,VM}, /* mov */
+ {0,0,rlr,S,VM,S}, /* mov */
+ {0,0,0,0,0,0},
+ {44,0,rr,S,S,0}, /* lop */
+ {36,0,rr,V,V,0}, /* tzc */
+ {44,0,rr,V,V,0}, /* lop */
+ {0,0,0,0,0,0},
+ {42,0,rr,V,V,0}, /* not */
+ {8,0,rr,S,V,0}, /* shf */
+ {35,1,rr,V,V,0}, /* plc.t */
+ {45,2,rr,V,V,0}, /* cprs.f */
+ {45,1,rr,V,V,0}, /* cprs.t */
+ {37,3,rr,V,V,0}, /* eq.s */
+ {37,4,rr,V,V,0}, /* eq.d */
+ {43,3,rr,V,V,0}, /* neg.s */
+ {43,4,rr,V,V,0}, /* neg.d */
+ {37,3,rr,S,V,0}, /* eq.s */
+ {37,4,rr,S,V,0}, /* eq.d */
+ {43,3,rr,S,S,0}, /* neg.s */
+ {43,4,rr,S,S,0}, /* neg.d */
+ {40,3,rr,V,V,0}, /* le.s */
+ {40,4,rr,V,V,0}, /* le.d */
+ {41,3,rr,V,V,0}, /* lt.s */
+ {41,4,rr,V,V,0}, /* lt.d */
+ {40,3,rr,S,V,0}, /* le.s */
+ {40,4,rr,S,V,0}, /* le.d */
+ {41,3,rr,S,V,0}, /* lt.s */
+ {41,4,rr,S,V,0}, /* lt.d */
+ {37,5,rr,V,V,0}, /* eq.b */
+ {37,6,rr,V,V,0}, /* eq.h */
+ {37,7,rr,V,V,0}, /* eq.w */
+ {37,8,rr,V,V,0}, /* eq.l */
+ {37,5,rr,S,V,0}, /* eq.b */
+ {37,6,rr,S,V,0}, /* eq.h */
+ {37,7,rr,S,V,0}, /* eq.w */
+ {37,8,rr,S,V,0}, /* eq.l */
+ {40,5,rr,V,V,0}, /* le.b */
+ {40,6,rr,V,V,0}, /* le.h */
+ {40,7,rr,V,V,0}, /* le.w */
+ {40,8,rr,V,V,0}, /* le.l */
+ {40,5,rr,S,V,0}, /* le.b */
+ {40,6,rr,S,V,0}, /* le.h */
+ {40,7,rr,S,V,0}, /* le.w */
+ {40,8,rr,S,V,0}, /* le.l */
+ {41,5,rr,V,V,0}, /* lt.b */
+ {41,6,rr,V,V,0}, /* lt.h */
+ {41,7,rr,V,V,0}, /* lt.w */
+ {41,8,rr,V,V,0}, /* lt.l */
+ {41,5,rr,S,V,0}, /* lt.b */
+ {41,6,rr,S,V,0}, /* lt.h */
+ {41,7,rr,S,V,0}, /* lt.w */
+ {41,8,rr,S,V,0}, /* lt.l */
+ {43,5,rr,V,V,0}, /* neg.b */
+ {43,6,rr,V,V,0}, /* neg.h */
+ {43,7,rr,V,V,0}, /* neg.w */
+ {43,8,rr,V,V,0}, /* neg.l */
+ {43,5,rr,S,S,0}, /* neg.b */
+ {43,6,rr,S,S,0}, /* neg.h */
+ {43,7,rr,S,S,0}, /* neg.w */
+ {43,8,rr,S,S,0}, /* neg.l */
+};
+
+const struct formstr format4[] = {
+ {46,0,nops,0,0,0}, /* nop */
+ {47,0,pcrel,0,0,0}, /* br */
+ {48,2,pcrel,0,0,0}, /* bri.f */
+ {48,1,pcrel,0,0,0}, /* bri.t */
+ {49,2,pcrel,0,0,0}, /* bra.f */
+ {49,1,pcrel,0,0,0}, /* bra.t */
+ {50,2,pcrel,0,0,0}, /* brs.f */
+ {50,1,pcrel,0,0,0}, /* brs.t */
+};
+
+const struct formstr format5[] = {
+ {51,5,rr,V,V,0}, /* ldvi.b */
+ {51,6,rr,V,V,0}, /* ldvi.h */
+ {51,7,rr,V,V,0}, /* ldvi.w */
+ {51,8,rr,V,V,0}, /* ldvi.l */
+ {28,3,rr,V,V,0}, /* cvtw.s */
+ {31,7,rr,V,V,0}, /* cvts.w */
+ {28,8,rr,V,V,0}, /* cvtw.l */
+ {33,7,rr,V,V,0}, /* cvtl.w */
+ {52,5,rxr,V,V,0}, /* stvi.b */
+ {52,6,rxr,V,V,0}, /* stvi.h */
+ {52,7,rxr,V,V,0}, /* stvi.w */
+ {52,8,rxr,V,V,0}, /* stvi.l */
+ {52,5,rxr,S,V,0}, /* stvi.b */
+ {52,6,rxr,S,V,0}, /* stvi.h */
+ {52,7,rxr,S,V,0}, /* stvi.w */
+ {52,8,rxr,S,V,0}, /* stvi.l */
+};
+
+const struct formstr format6[] = {
+ {53,0,r,A,0,0}, /* ldsdr */
+ {54,0,r,A,0,0}, /* ldkdr */
+ {55,3,r,S,0,0}, /* ln.s */
+ {55,4,r,S,0,0}, /* ln.d */
+ {56,0,nops,0,0,0}, /* patu */
+ {57,0,r,A,0,0}, /* pate */
+ {58,0,nops,0,0,0}, /* pich */
+ {59,0,nops,0,0,0}, /* plch */
+ {0,0,lr,PSW,A,0}, /* mov */
+ {0,0,rxl,A,PSW,0}, /* mov */
+ {0,0,lr,PC,A,0}, /* mov */
+ {60,0,r,S,0,0}, /* idle */
+ {0,0,lr,ITR,S,0}, /* mov */
+ {0,0,rxl,S,ITR,0}, /* mov */
+ {0,0,0,0,0,0},
+ {0,0,rxl,S,ITSR,0}, /* mov */
+ {61,0,nops,0,0,0}, /* rtnq */
+ {62,0,nops,0,0,0}, /* cfork */
+ {63,0,nops,0,0,0}, /* rtn */
+ {64,0,nops,0,0,0}, /* wfork */
+ {65,0,nops,0,0,0}, /* join */
+ {66,0,nops,0,0,0}, /* rtnc */
+ {67,3,r,S,0,0}, /* exp.s */
+ {67,4,r,S,0,0}, /* exp.d */
+ {68,3,r,S,0,0}, /* sin.s */
+ {68,4,r,S,0,0}, /* sin.d */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {69,3,r,S,0,0}, /* cos.s */
+ {69,4,r,S,0,0}, /* cos.d */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {70,7,r,A,0,0}, /* psh.w */
+ {0,0,0,0,0,0},
+ {71,7,r,A,0,0}, /* pop.w */
+ {0,0,0,0,0,0},
+ {70,7,r,S,0,0}, /* psh.w */
+ {70,8,r,S,0,0}, /* psh.l */
+ {71,7,r,S,0,0}, /* pop.w */
+ {71,8,r,S,0,0}, /* pop.l */
+ {72,0,nops,0,0,0}, /* eni */
+ {73,0,nops,0,0,0}, /* dsi */
+ {74,0,nops,0,0,0}, /* bkpt */
+ {75,0,nops,0,0,0}, /* msync */
+ {76,0,r,S,0,0}, /* mski */
+ {77,0,r,S,0,0}, /* xmti */
+ {0,0,rxl,S,VV,0}, /* mov */
+ {78,0,nops,0,0,0}, /* tstvv */
+ {0,0,lr,VS,A,0}, /* mov */
+ {0,0,rxl,A,VS,0}, /* mov */
+ {0,0,lr,VL,A,0}, /* mov */
+ {0,0,rxl,A,VL,0}, /* mov */
+ {0,7,lr,VS,S,0}, /* mov.w */
+ {0,7,rxl,S,VS,0}, /* mov.w */
+ {0,7,lr,VL,S,0}, /* mov.w */
+ {0,7,rxl,S,VL,0}, /* mov.w */
+ {79,0,r,A,0,0}, /* diag */
+ {80,0,nops,0,0,0}, /* pbkpt */
+ {81,3,r,S,0,0}, /* sqrt.s */
+ {81,4,r,S,0,0}, /* sqrt.d */
+ {82,0,nops,0,0,0}, /* casr */
+ {0,0,0,0,0,0},
+ {83,3,r,S,0,0}, /* atan.s */
+ {83,4,r,S,0,0}, /* atan.d */
+};
+
+const struct formstr format7[] = {
+ {84,5,r,V,0,0}, /* sum.b */
+ {84,6,r,V,0,0}, /* sum.h */
+ {84,7,r,V,0,0}, /* sum.w */
+ {84,8,r,V,0,0}, /* sum.l */
+ {85,0,r,V,0,0}, /* all */
+ {86,0,r,V,0,0}, /* any */
+ {87,0,r,V,0,0}, /* parity */
+ {0,0,0,0,0,0},
+ {88,5,r,V,0,0}, /* max.b */
+ {88,6,r,V,0,0}, /* max.h */
+ {88,7,r,V,0,0}, /* max.w */
+ {88,8,r,V,0,0}, /* max.l */
+ {89,5,r,V,0,0}, /* min.b */
+ {89,6,r,V,0,0}, /* min.h */
+ {89,7,r,V,0,0}, /* min.w */
+ {89,8,r,V,0,0}, /* min.l */
+ {84,3,r,V,0,0}, /* sum.s */
+ {84,4,r,V,0,0}, /* sum.d */
+ {90,3,r,V,0,0}, /* prod.s */
+ {90,4,r,V,0,0}, /* prod.d */
+ {88,3,r,V,0,0}, /* max.s */
+ {88,4,r,V,0,0}, /* max.d */
+ {89,3,r,V,0,0}, /* min.s */
+ {89,4,r,V,0,0}, /* min.d */
+ {90,5,r,V,0,0}, /* prod.b */
+ {90,6,r,V,0,0}, /* prod.h */
+ {90,7,r,V,0,0}, /* prod.w */
+ {90,8,r,V,0,0}, /* prod.l */
+ {35,2,lr,VM,S,0}, /* plc.f */
+ {35,1,lr,VM,S,0}, /* plc.t */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+};
+
+const struct formstr formatx[] = {
+ {0,0,0,0,0,0},
+};
+
+const struct formstr format1a[] = {
+ {91,0,imr,A,0,0}, /* halt */
+ {92,0,a4,0,0,0}, /* sysc */
+ {18,6,imr,A,0,0}, /* ld.h */
+ {18,7,imr,A,0,0}, /* ld.w */
+ {5,0,imr,A,0,0}, /* and */
+ {6,0,imr,A,0,0}, /* or */
+ {7,0,imr,A,0,0}, /* xor */
+ {8,0,imr,A,0,0}, /* shf */
+ {9,6,imr,A,0,0}, /* add.h */
+ {9,7,imr,A,0,0}, /* add.w */
+ {10,6,imr,A,0,0}, /* sub.h */
+ {10,7,imr,A,0,0}, /* sub.w */
+ {3,6,imr,A,0,0}, /* mul.h */
+ {3,7,imr,A,0,0}, /* mul.w */
+ {4,6,imr,A,0,0}, /* div.h */
+ {4,7,imr,A,0,0}, /* div.w */
+ {18,7,iml,VL,0,0}, /* ld.w */
+ {18,7,iml,VS,0,0}, /* ld.w */
+ {0,0,0,0,0,0},
+ {8,7,imr,S,0,0}, /* shf.w */
+ {93,0,a5,0,0,0}, /* trap */
+ {0,0,0,0,0,0},
+ {37,6,imr,A,0,0}, /* eq.h */
+ {37,7,imr,A,0,0}, /* eq.w */
+ {38,6,imr,A,0,0}, /* leu.h */
+ {38,7,imr,A,0,0}, /* leu.w */
+ {39,6,imr,A,0,0}, /* ltu.h */
+ {39,7,imr,A,0,0}, /* ltu.w */
+ {40,6,imr,A,0,0}, /* le.h */
+ {40,7,imr,A,0,0}, /* le.w */
+ {41,6,imr,A,0,0}, /* lt.h */
+ {41,7,imr,A,0,0}, /* lt.w */
+};
+
+const struct formstr format1b[] = {
+ {18,4,imr,S,0,0}, /* ld.d */
+ {18,10,imr,S,0,0}, /* ld.u */
+ {18,8,imr,S,0,0}, /* ld.l */
+ {18,7,imr,S,0,0}, /* ld.w */
+ {5,0,imr,S,0,0}, /* and */
+ {6,0,imr,S,0,0}, /* or */
+ {7,0,imr,S,0,0}, /* xor */
+ {8,0,imr,S,0,0}, /* shf */
+ {9,6,imr,S,0,0}, /* add.h */
+ {9,7,imr,S,0,0}, /* add.w */
+ {10,6,imr,S,0,0}, /* sub.h */
+ {10,7,imr,S,0,0}, /* sub.w */
+ {3,6,imr,S,0,0}, /* mul.h */
+ {3,7,imr,S,0,0}, /* mul.w */
+ {4,6,imr,S,0,0}, /* div.h */
+ {4,7,imr,S,0,0}, /* div.w */
+ {9,3,imr,S,0,0}, /* add.s */
+ {10,3,imr,S,0,0}, /* sub.s */
+ {3,3,imr,S,0,0}, /* mul.s */
+ {4,3,imr,S,0,0}, /* div.s */
+ {40,3,imr,S,0,0}, /* le.s */
+ {41,3,imr,S,0,0}, /* lt.s */
+ {37,6,imr,S,0,0}, /* eq.h */
+ {37,7,imr,S,0,0}, /* eq.w */
+ {38,6,imr,S,0,0}, /* leu.h */
+ {38,7,imr,S,0,0}, /* leu.w */
+ {39,6,imr,S,0,0}, /* ltu.h */
+ {39,7,imr,S,0,0}, /* ltu.w */
+ {40,6,imr,S,0,0}, /* le.h */
+ {40,7,imr,S,0,0}, /* le.w */
+ {41,6,imr,S,0,0}, /* lt.h */
+ {41,7,imr,S,0,0}, /* lt.w */
+};
+
+const struct formstr e0_format0[] = {
+ {10,3,rrr,S,V,V}, /* sub.s */
+ {10,4,rrr,S,V,V}, /* sub.d */
+ {4,3,rrr,S,V,V}, /* div.s */
+ {4,4,rrr,S,V,V}, /* div.d */
+ {10,11,rrr,S,V,V}, /* sub.s.f */
+ {10,12,rrr,S,V,V}, /* sub.d.f */
+ {4,11,rrr,S,V,V}, /* div.s.f */
+ {4,12,rrr,S,V,V}, /* div.d.f */
+ {3,11,rrr,V,V,V}, /* mul.s.f */
+ {3,12,rrr,V,V,V}, /* mul.d.f */
+ {4,11,rrr,V,V,V}, /* div.s.f */
+ {4,12,rrr,V,V,V}, /* div.d.f */
+ {3,11,rrr,V,S,V}, /* mul.s.f */
+ {3,12,rrr,V,S,V}, /* mul.d.f */
+ {4,11,rrr,V,S,V}, /* div.s.f */
+ {4,12,rrr,V,S,V}, /* div.d.f */
+ {5,2,rrr,V,V,V}, /* and.f */
+ {6,2,rrr,V,V,V}, /* or.f */
+ {7,2,rrr,V,V,V}, /* xor.f */
+ {8,2,rrr,V,V,V}, /* shf.f */
+ {5,2,rrr,V,S,V}, /* and.f */
+ {6,2,rrr,V,S,V}, /* or.f */
+ {7,2,rrr,V,S,V}, /* xor.f */
+ {8,2,rrr,V,S,V}, /* shf.f */
+ {9,11,rrr,V,V,V}, /* add.s.f */
+ {9,12,rrr,V,V,V}, /* add.d.f */
+ {10,11,rrr,V,V,V}, /* sub.s.f */
+ {10,12,rrr,V,V,V}, /* sub.d.f */
+ {9,11,rrr,V,S,V}, /* add.s.f */
+ {9,12,rrr,V,S,V}, /* add.d.f */
+ {10,11,rrr,V,S,V}, /* sub.s.f */
+ {10,12,rrr,V,S,V}, /* sub.d.f */
+ {9,13,rrr,V,V,V}, /* add.b.f */
+ {9,14,rrr,V,V,V}, /* add.h.f */
+ {9,15,rrr,V,V,V}, /* add.w.f */
+ {9,16,rrr,V,V,V}, /* add.l.f */
+ {9,13,rrr,V,S,V}, /* add.b.f */
+ {9,14,rrr,V,S,V}, /* add.h.f */
+ {9,15,rrr,V,S,V}, /* add.w.f */
+ {9,16,rrr,V,S,V}, /* add.l.f */
+ {10,13,rrr,V,V,V}, /* sub.b.f */
+ {10,14,rrr,V,V,V}, /* sub.h.f */
+ {10,15,rrr,V,V,V}, /* sub.w.f */
+ {10,16,rrr,V,V,V}, /* sub.l.f */
+ {10,13,rrr,V,S,V}, /* sub.b.f */
+ {10,14,rrr,V,S,V}, /* sub.h.f */
+ {10,15,rrr,V,S,V}, /* sub.w.f */
+ {10,16,rrr,V,S,V}, /* sub.l.f */
+ {3,13,rrr,V,V,V}, /* mul.b.f */
+ {3,14,rrr,V,V,V}, /* mul.h.f */
+ {3,15,rrr,V,V,V}, /* mul.w.f */
+ {3,16,rrr,V,V,V}, /* mul.l.f */
+ {3,13,rrr,V,S,V}, /* mul.b.f */
+ {3,14,rrr,V,S,V}, /* mul.h.f */
+ {3,15,rrr,V,S,V}, /* mul.w.f */
+ {3,16,rrr,V,S,V}, /* mul.l.f */
+ {4,13,rrr,V,V,V}, /* div.b.f */
+ {4,14,rrr,V,V,V}, /* div.h.f */
+ {4,15,rrr,V,V,V}, /* div.w.f */
+ {4,16,rrr,V,V,V}, /* div.l.f */
+ {4,13,rrr,V,S,V}, /* div.b.f */
+ {4,14,rrr,V,S,V}, /* div.h.f */
+ {4,15,rrr,V,S,V}, /* div.w.f */
+ {4,16,rrr,V,S,V}, /* div.l.f */
+};
+
+const struct formstr e0_format1[] = {
+ {0,0,0,0,0,0},
+ {94,0,a3,0,0,0}, /* tst */
+ {95,0,a3,0,0,0}, /* lck */
+ {96,0,a3,0,0,0}, /* ulk */
+ {17,0,a1r,S,0,0}, /* ldea */
+ {97,0,a1r,A,0,0}, /* spawn */
+ {98,0,a1r,A,0,0}, /* ldcmr */
+ {99,0,a2r,A,0,0}, /* stcmr */
+ {100,0,a1r,A,0,0}, /* popr */
+ {101,0,a2r,A,0,0}, /* pshr */
+ {102,7,a1r,A,0,0}, /* rcvr.w */
+ {103,7,a2r,A,0,0}, /* matm.w */
+ {104,7,a2r,A,0,0}, /* sndr.w */
+ {104,8,a2r,S,0,0}, /* sndr.l */
+ {102,8,a1r,S,0,0}, /* rcvr.l */
+ {103,8,a2r,S,0,0}, /* matm.l */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {105,7,a2r,A,0,0}, /* putr.w */
+ {105,8,a2r,S,0,0}, /* putr.l */
+ {106,7,a1r,A,0,0}, /* getr.w */
+ {106,8,a1r,S,0,0}, /* getr.l */
+ {26,13,a2r,S,0,0}, /* ste.b.f */
+ {26,14,a2r,S,0,0}, /* ste.h.f */
+ {26,15,a2r,S,0,0}, /* ste.w.f */
+ {26,16,a2r,S,0,0}, /* ste.l.f */
+ {107,7,a2r,A,0,0}, /* matr.w */
+ {108,7,a2r,A,0,0}, /* mat.w */
+ {109,7,a1r,A,0,0}, /* get.w */
+ {110,7,a1r,A,0,0}, /* rcv.w */
+ {0,0,0,0,0,0},
+ {111,7,a1r,A,0,0}, /* inc.w */
+ {112,7,a2r,A,0,0}, /* put.w */
+ {113,7,a2r,A,0,0}, /* snd.w */
+ {107,8,a2r,S,0,0}, /* matr.l */
+ {108,8,a2r,S,0,0}, /* mat.l */
+ {109,8,a1r,S,0,0}, /* get.l */
+ {110,8,a1r,S,0,0}, /* rcv.l */
+ {0,0,0,0,0,0},
+ {111,8,a1r,S,0,0}, /* inc.l */
+ {112,8,a2r,S,0,0}, /* put.l */
+ {113,8,a2r,S,0,0}, /* snd.l */
+ {18,13,a1r,V,0,0}, /* ld.b.f */
+ {18,14,a1r,V,0,0}, /* ld.h.f */
+ {18,15,a1r,V,0,0}, /* ld.w.f */
+ {18,16,a1r,V,0,0}, /* ld.l.f */
+ {21,13,a2r,V,0,0}, /* st.b.f */
+ {21,14,a2r,V,0,0}, /* st.h.f */
+ {21,15,a2r,V,0,0}, /* st.w.f */
+ {21,16,a2r,V,0,0}, /* st.l.f */
+};
+
+const struct formstr e0_format2[] = {
+ {28,5,rr,V,V,0}, /* cvtw.b */
+ {28,6,rr,V,V,0}, /* cvtw.h */
+ {29,7,rr,V,V,0}, /* cvtb.w */
+ {30,7,rr,V,V,0}, /* cvth.w */
+ {28,13,rr,V,V,0}, /* cvtw.b.f */
+ {28,14,rr,V,V,0}, /* cvtw.h.f */
+ {29,15,rr,V,V,0}, /* cvtb.w.f */
+ {30,15,rr,V,V,0}, /* cvth.w.f */
+ {31,8,rr,V,V,0}, /* cvts.l */
+ {32,7,rr,V,V,0}, /* cvtd.w */
+ {33,3,rr,V,V,0}, /* cvtl.s */
+ {28,4,rr,V,V,0}, /* cvtw.d */
+ {31,16,rr,V,V,0}, /* cvts.l.f */
+ {32,15,rr,V,V,0}, /* cvtd.w.f */
+ {33,11,rr,V,V,0}, /* cvtl.s.f */
+ {28,12,rr,V,V,0}, /* cvtw.d.f */
+ {114,0,rr,S,S,0}, /* enal */
+ {8,7,rr,S,S,0}, /* shf.w */
+ {115,0,rr,S,S,0}, /* enag */
+ {0,0,0,0,0,0},
+ {28,4,rr,S,S,0}, /* cvtw.d */
+ {32,7,rr,S,S,0}, /* cvtd.w */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {116,3,rr,S,S,0}, /* frint.s */
+ {116,4,rr,S,S,0}, /* frint.d */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {116,3,rr,V,V,0}, /* frint.s */
+ {116,4,rr,V,V,0}, /* frint.d */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {116,11,rr,V,V,0}, /* frint.s.f */
+ {116,12,rr,V,V,0}, /* frint.d.f */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {81,3,rr,V,V,0}, /* sqrt.s */
+ {81,4,rr,V,V,0}, /* sqrt.d */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {81,11,rr,V,V,0}, /* sqrt.s.f */
+ {81,12,rr,V,V,0}, /* sqrt.d.f */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+};
+
+const struct formstr e0_format3[] = {
+ {32,11,rr,V,V,0}, /* cvtd.s.f */
+ {31,12,rr,V,V,0}, /* cvts.d.f */
+ {33,12,rr,V,V,0}, /* cvtl.d.f */
+ {32,16,rr,V,V,0}, /* cvtd.l.f */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {36,2,rr,V,V,0}, /* tzc.f */
+ {44,2,rr,V,V,0}, /* lop.f */
+ {117,2,rr,V,V,0}, /* xpnd.f */
+ {42,2,rr,V,V,0}, /* not.f */
+ {8,2,rr,S,V,0}, /* shf.f */
+ {35,17,rr,V,V,0}, /* plc.t.f */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {37,11,rr,V,V,0}, /* eq.s.f */
+ {37,12,rr,V,V,0}, /* eq.d.f */
+ {43,11,rr,V,V,0}, /* neg.s.f */
+ {43,12,rr,V,V,0}, /* neg.d.f */
+ {37,11,rr,S,V,0}, /* eq.s.f */
+ {37,12,rr,S,V,0}, /* eq.d.f */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {40,11,rr,V,V,0}, /* le.s.f */
+ {40,12,rr,V,V,0}, /* le.d.f */
+ {41,11,rr,V,V,0}, /* lt.s.f */
+ {41,12,rr,V,V,0}, /* lt.d.f */
+ {40,11,rr,S,V,0}, /* le.s.f */
+ {40,12,rr,S,V,0}, /* le.d.f */
+ {41,11,rr,S,V,0}, /* lt.s.f */
+ {41,12,rr,S,V,0}, /* lt.d.f */
+ {37,13,rr,V,V,0}, /* eq.b.f */
+ {37,14,rr,V,V,0}, /* eq.h.f */
+ {37,15,rr,V,V,0}, /* eq.w.f */
+ {37,16,rr,V,V,0}, /* eq.l.f */
+ {37,13,rr,S,V,0}, /* eq.b.f */
+ {37,14,rr,S,V,0}, /* eq.h.f */
+ {37,15,rr,S,V,0}, /* eq.w.f */
+ {37,16,rr,S,V,0}, /* eq.l.f */
+ {40,13,rr,V,V,0}, /* le.b.f */
+ {40,14,rr,V,V,0}, /* le.h.f */
+ {40,15,rr,V,V,0}, /* le.w.f */
+ {40,16,rr,V,V,0}, /* le.l.f */
+ {40,13,rr,S,V,0}, /* le.b.f */
+ {40,14,rr,S,V,0}, /* le.h.f */
+ {40,15,rr,S,V,0}, /* le.w.f */
+ {40,16,rr,S,V,0}, /* le.l.f */
+ {41,13,rr,V,V,0}, /* lt.b.f */
+ {41,14,rr,V,V,0}, /* lt.h.f */
+ {41,15,rr,V,V,0}, /* lt.w.f */
+ {41,16,rr,V,V,0}, /* lt.l.f */
+ {41,13,rr,S,V,0}, /* lt.b.f */
+ {41,14,rr,S,V,0}, /* lt.h.f */
+ {41,15,rr,S,V,0}, /* lt.w.f */
+ {41,16,rr,S,V,0}, /* lt.l.f */
+ {43,13,rr,V,V,0}, /* neg.b.f */
+ {43,14,rr,V,V,0}, /* neg.h.f */
+ {43,15,rr,V,V,0}, /* neg.w.f */
+ {43,16,rr,V,V,0}, /* neg.l.f */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+};
+
+const struct formstr e0_format4[] = {
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+};
+
+const struct formstr e0_format5[] = {
+ {51,13,rr,V,V,0}, /* ldvi.b.f */
+ {51,14,rr,V,V,0}, /* ldvi.h.f */
+ {51,15,rr,V,V,0}, /* ldvi.w.f */
+ {51,16,rr,V,V,0}, /* ldvi.l.f */
+ {28,11,rr,V,V,0}, /* cvtw.s.f */
+ {31,15,rr,V,V,0}, /* cvts.w.f */
+ {28,16,rr,V,V,0}, /* cvtw.l.f */
+ {33,15,rr,V,V,0}, /* cvtl.w.f */
+ {52,13,rxr,V,V,0}, /* stvi.b.f */
+ {52,14,rxr,V,V,0}, /* stvi.h.f */
+ {52,15,rxr,V,V,0}, /* stvi.w.f */
+ {52,16,rxr,V,V,0}, /* stvi.l.f */
+ {52,13,rxr,S,V,0}, /* stvi.b.f */
+ {52,14,rxr,S,V,0}, /* stvi.h.f */
+ {52,15,rxr,S,V,0}, /* stvi.w.f */
+ {52,16,rxr,S,V,0}, /* stvi.l.f */
+};
+
+const struct formstr e0_format6[] = {
+ {0,0,rxl,S,CIR,0}, /* mov */
+ {0,0,lr,CIR,S,0}, /* mov */
+ {0,0,lr,TOC,S,0}, /* mov */
+ {0,0,lr,CPUID,S,0}, /* mov */
+ {0,0,rxl,S,TTR,0}, /* mov */
+ {0,0,lr,TTR,S,0}, /* mov */
+ {118,0,nops,0,0,0}, /* ctrsl */
+ {119,0,nops,0,0,0}, /* ctrsg */
+ {0,0,rxl,S,VMU,0}, /* mov */
+ {0,0,lr,VMU,S,0}, /* mov */
+ {0,0,rxl,S,VML,0}, /* mov */
+ {0,0,lr,VML,S,0}, /* mov */
+ {0,0,rxl,S,ICR,0}, /* mov */
+ {0,0,lr,ICR,S,0}, /* mov */
+ {0,0,rxl,S,TCPU,0}, /* mov */
+ {0,0,lr,TCPU,S,0}, /* mov */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {120,0,nops,0,0,0}, /* stop */
+ {0,0,0,0,0,0},
+ {0,0,rxl,S,TID,0}, /* mov */
+ {0,0,lr,TID,S,0}, /* mov */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+};
+
+const struct formstr e0_format7[] = {
+ {84,13,r,V,0,0}, /* sum.b.f */
+ {84,14,r,V,0,0}, /* sum.h.f */
+ {84,15,r,V,0,0}, /* sum.w.f */
+ {84,16,r,V,0,0}, /* sum.l.f */
+ {85,2,r,V,0,0}, /* all.f */
+ {86,2,r,V,0,0}, /* any.f */
+ {87,2,r,V,0,0}, /* parity.f */
+ {0,0,0,0,0,0},
+ {88,13,r,V,0,0}, /* max.b.f */
+ {88,14,r,V,0,0}, /* max.h.f */
+ {88,15,r,V,0,0}, /* max.w.f */
+ {88,16,r,V,0,0}, /* max.l.f */
+ {89,13,r,V,0,0}, /* min.b.f */
+ {89,14,r,V,0,0}, /* min.h.f */
+ {89,15,r,V,0,0}, /* min.w.f */
+ {89,16,r,V,0,0}, /* min.l.f */
+ {84,11,r,V,0,0}, /* sum.s.f */
+ {84,12,r,V,0,0}, /* sum.d.f */
+ {90,11,r,V,0,0}, /* prod.s.f */
+ {90,12,r,V,0,0}, /* prod.d.f */
+ {88,11,r,V,0,0}, /* max.s.f */
+ {88,12,r,V,0,0}, /* max.d.f */
+ {89,11,r,V,0,0}, /* min.s.f */
+ {89,12,r,V,0,0}, /* min.d.f */
+ {90,13,r,V,0,0}, /* prod.b.f */
+ {90,14,r,V,0,0}, /* prod.h.f */
+ {90,15,r,V,0,0}, /* prod.w.f */
+ {90,16,r,V,0,0}, /* prod.l.f */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+};
+
+const struct formstr e1_format0[] = {
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {10,18,rrr,S,V,V}, /* sub.s.t */
+ {10,19,rrr,S,V,V}, /* sub.d.t */
+ {4,18,rrr,S,V,V}, /* div.s.t */
+ {4,19,rrr,S,V,V}, /* div.d.t */
+ {3,18,rrr,V,V,V}, /* mul.s.t */
+ {3,19,rrr,V,V,V}, /* mul.d.t */
+ {4,18,rrr,V,V,V}, /* div.s.t */
+ {4,19,rrr,V,V,V}, /* div.d.t */
+ {3,18,rrr,V,S,V}, /* mul.s.t */
+ {3,19,rrr,V,S,V}, /* mul.d.t */
+ {4,18,rrr,V,S,V}, /* div.s.t */
+ {4,19,rrr,V,S,V}, /* div.d.t */
+ {5,1,rrr,V,V,V}, /* and.t */
+ {6,1,rrr,V,V,V}, /* or.t */
+ {7,1,rrr,V,V,V}, /* xor.t */
+ {8,1,rrr,V,V,V}, /* shf.t */
+ {5,1,rrr,V,S,V}, /* and.t */
+ {6,1,rrr,V,S,V}, /* or.t */
+ {7,1,rrr,V,S,V}, /* xor.t */
+ {8,1,rrr,V,S,V}, /* shf.t */
+ {9,18,rrr,V,V,V}, /* add.s.t */
+ {9,19,rrr,V,V,V}, /* add.d.t */
+ {10,18,rrr,V,V,V}, /* sub.s.t */
+ {10,19,rrr,V,V,V}, /* sub.d.t */
+ {9,18,rrr,V,S,V}, /* add.s.t */
+ {9,19,rrr,V,S,V}, /* add.d.t */
+ {10,18,rrr,V,S,V}, /* sub.s.t */
+ {10,19,rrr,V,S,V}, /* sub.d.t */
+ {9,20,rrr,V,V,V}, /* add.b.t */
+ {9,21,rrr,V,V,V}, /* add.h.t */
+ {9,22,rrr,V,V,V}, /* add.w.t */
+ {9,23,rrr,V,V,V}, /* add.l.t */
+ {9,20,rrr,V,S,V}, /* add.b.t */
+ {9,21,rrr,V,S,V}, /* add.h.t */
+ {9,22,rrr,V,S,V}, /* add.w.t */
+ {9,23,rrr,V,S,V}, /* add.l.t */
+ {10,20,rrr,V,V,V}, /* sub.b.t */
+ {10,21,rrr,V,V,V}, /* sub.h.t */
+ {10,22,rrr,V,V,V}, /* sub.w.t */
+ {10,23,rrr,V,V,V}, /* sub.l.t */
+ {10,20,rrr,V,S,V}, /* sub.b.t */
+ {10,21,rrr,V,S,V}, /* sub.h.t */
+ {10,22,rrr,V,S,V}, /* sub.w.t */
+ {10,23,rrr,V,S,V}, /* sub.l.t */
+ {3,20,rrr,V,V,V}, /* mul.b.t */
+ {3,21,rrr,V,V,V}, /* mul.h.t */
+ {3,22,rrr,V,V,V}, /* mul.w.t */
+ {3,23,rrr,V,V,V}, /* mul.l.t */
+ {3,20,rrr,V,S,V}, /* mul.b.t */
+ {3,21,rrr,V,S,V}, /* mul.h.t */
+ {3,22,rrr,V,S,V}, /* mul.w.t */
+ {3,23,rrr,V,S,V}, /* mul.l.t */
+ {4,20,rrr,V,V,V}, /* div.b.t */
+ {4,21,rrr,V,V,V}, /* div.h.t */
+ {4,22,rrr,V,V,V}, /* div.w.t */
+ {4,23,rrr,V,V,V}, /* div.l.t */
+ {4,20,rrr,V,S,V}, /* div.b.t */
+ {4,21,rrr,V,S,V}, /* div.h.t */
+ {4,22,rrr,V,S,V}, /* div.w.t */
+ {4,23,rrr,V,S,V}, /* div.l.t */
+};
+
+const struct formstr e1_format1[] = {
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {26,20,a2r,S,0,0}, /* ste.b.t */
+ {26,21,a2r,S,0,0}, /* ste.h.t */
+ {26,22,a2r,S,0,0}, /* ste.w.t */
+ {26,23,a2r,S,0,0}, /* ste.l.t */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {18,20,a1r,V,0,0}, /* ld.b.t */
+ {18,21,a1r,V,0,0}, /* ld.h.t */
+ {18,22,a1r,V,0,0}, /* ld.w.t */
+ {18,23,a1r,V,0,0}, /* ld.l.t */
+ {21,20,a2r,V,0,0}, /* st.b.t */
+ {21,21,a2r,V,0,0}, /* st.h.t */
+ {21,22,a2r,V,0,0}, /* st.w.t */
+ {21,23,a2r,V,0,0}, /* st.l.t */
+};
+
+const struct formstr e1_format2[] = {
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {28,20,rr,V,V,0}, /* cvtw.b.t */
+ {28,21,rr,V,V,0}, /* cvtw.h.t */
+ {29,22,rr,V,V,0}, /* cvtb.w.t */
+ {30,22,rr,V,V,0}, /* cvth.w.t */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {31,23,rr,V,V,0}, /* cvts.l.t */
+ {32,22,rr,V,V,0}, /* cvtd.w.t */
+ {33,18,rr,V,V,0}, /* cvtl.s.t */
+ {28,19,rr,V,V,0}, /* cvtw.d.t */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {116,18,rr,V,V,0}, /* frint.s.t */
+ {116,19,rr,V,V,0}, /* frint.d.t */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {81,18,rr,V,V,0}, /* sqrt.s.t */
+ {81,19,rr,V,V,0}, /* sqrt.d.t */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+};
+
+const struct formstr e1_format3[] = {
+ {32,18,rr,V,V,0}, /* cvtd.s.t */
+ {31,19,rr,V,V,0}, /* cvts.d.t */
+ {33,19,rr,V,V,0}, /* cvtl.d.t */
+ {32,23,rr,V,V,0}, /* cvtd.l.t */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {36,1,rr,V,V,0}, /* tzc.t */
+ {44,1,rr,V,V,0}, /* lop.t */
+ {117,1,rr,V,V,0}, /* xpnd.t */
+ {42,1,rr,V,V,0}, /* not.t */
+ {8,1,rr,S,V,0}, /* shf.t */
+ {35,24,rr,V,V,0}, /* plc.t.t */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {37,18,rr,V,V,0}, /* eq.s.t */
+ {37,19,rr,V,V,0}, /* eq.d.t */
+ {43,18,rr,V,V,0}, /* neg.s.t */
+ {43,19,rr,V,V,0}, /* neg.d.t */
+ {37,18,rr,S,V,0}, /* eq.s.t */
+ {37,19,rr,S,V,0}, /* eq.d.t */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {40,18,rr,V,V,0}, /* le.s.t */
+ {40,19,rr,V,V,0}, /* le.d.t */
+ {41,18,rr,V,V,0}, /* lt.s.t */
+ {41,19,rr,V,V,0}, /* lt.d.t */
+ {40,18,rr,S,V,0}, /* le.s.t */
+ {40,19,rr,S,V,0}, /* le.d.t */
+ {41,18,rr,S,V,0}, /* lt.s.t */
+ {41,19,rr,S,V,0}, /* lt.d.t */
+ {37,20,rr,V,V,0}, /* eq.b.t */
+ {37,21,rr,V,V,0}, /* eq.h.t */
+ {37,22,rr,V,V,0}, /* eq.w.t */
+ {37,23,rr,V,V,0}, /* eq.l.t */
+ {37,20,rr,S,V,0}, /* eq.b.t */
+ {37,21,rr,S,V,0}, /* eq.h.t */
+ {37,22,rr,S,V,0}, /* eq.w.t */
+ {37,23,rr,S,V,0}, /* eq.l.t */
+ {40,20,rr,V,V,0}, /* le.b.t */
+ {40,21,rr,V,V,0}, /* le.h.t */
+ {40,22,rr,V,V,0}, /* le.w.t */
+ {40,23,rr,V,V,0}, /* le.l.t */
+ {40,20,rr,S,V,0}, /* le.b.t */
+ {40,21,rr,S,V,0}, /* le.h.t */
+ {40,22,rr,S,V,0}, /* le.w.t */
+ {40,23,rr,S,V,0}, /* le.l.t */
+ {41,20,rr,V,V,0}, /* lt.b.t */
+ {41,21,rr,V,V,0}, /* lt.h.t */
+ {41,22,rr,V,V,0}, /* lt.w.t */
+ {41,23,rr,V,V,0}, /* lt.l.t */
+ {41,20,rr,S,V,0}, /* lt.b.t */
+ {41,21,rr,S,V,0}, /* lt.h.t */
+ {41,22,rr,S,V,0}, /* lt.w.t */
+ {41,23,rr,S,V,0}, /* lt.l.t */
+ {43,20,rr,V,V,0}, /* neg.b.t */
+ {43,21,rr,V,V,0}, /* neg.h.t */
+ {43,22,rr,V,V,0}, /* neg.w.t */
+ {43,23,rr,V,V,0}, /* neg.l.t */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+};
+
+const struct formstr e1_format4[] = {
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+};
+
+const struct formstr e1_format5[] = {
+ {51,20,rr,V,V,0}, /* ldvi.b.t */
+ {51,21,rr,V,V,0}, /* ldvi.h.t */
+ {51,22,rr,V,V,0}, /* ldvi.w.t */
+ {51,23,rr,V,V,0}, /* ldvi.l.t */
+ {28,18,rr,V,V,0}, /* cvtw.s.t */
+ {31,22,rr,V,V,0}, /* cvts.w.t */
+ {28,23,rr,V,V,0}, /* cvtw.l.t */
+ {33,22,rr,V,V,0}, /* cvtl.w.t */
+ {52,20,rxr,V,V,0}, /* stvi.b.t */
+ {52,21,rxr,V,V,0}, /* stvi.h.t */
+ {52,22,rxr,V,V,0}, /* stvi.w.t */
+ {52,23,rxr,V,V,0}, /* stvi.l.t */
+ {52,20,rxr,S,V,0}, /* stvi.b.t */
+ {52,21,rxr,S,V,0}, /* stvi.h.t */
+ {52,22,rxr,S,V,0}, /* stvi.w.t */
+ {52,23,rxr,S,V,0}, /* stvi.l.t */
+};
+
+const struct formstr e1_format6[] = {
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+};
+
+const struct formstr e1_format7[] = {
+ {84,20,r,V,0,0}, /* sum.b.t */
+ {84,21,r,V,0,0}, /* sum.h.t */
+ {84,22,r,V,0,0}, /* sum.w.t */
+ {84,23,r,V,0,0}, /* sum.l.t */
+ {85,1,r,V,0,0}, /* all.t */
+ {86,1,r,V,0,0}, /* any.t */
+ {87,1,r,V,0,0}, /* parity.t */
+ {0,0,0,0,0,0},
+ {88,20,r,V,0,0}, /* max.b.t */
+ {88,21,r,V,0,0}, /* max.h.t */
+ {88,22,r,V,0,0}, /* max.w.t */
+ {88,23,r,V,0,0}, /* max.l.t */
+ {89,20,r,V,0,0}, /* min.b.t */
+ {89,21,r,V,0,0}, /* min.h.t */
+ {89,22,r,V,0,0}, /* min.w.t */
+ {89,23,r,V,0,0}, /* min.l.t */
+ {84,18,r,V,0,0}, /* sum.s.t */
+ {84,19,r,V,0,0}, /* sum.d.t */
+ {90,18,r,V,0,0}, /* prod.s.t */
+ {90,19,r,V,0,0}, /* prod.d.t */
+ {88,18,r,V,0,0}, /* max.s.t */
+ {88,19,r,V,0,0}, /* max.d.t */
+ {89,18,r,V,0,0}, /* min.s.t */
+ {89,19,r,V,0,0}, /* min.d.t */
+ {90,20,r,V,0,0}, /* prod.b.t */
+ {90,21,r,V,0,0}, /* prod.h.t */
+ {90,22,r,V,0,0}, /* prod.w.t */
+ {90,23,r,V,0,0}, /* prod.l.t */
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+ {0,0,0,0,0,0},
+};
+
+char *lop[] = {
+ "mov", /* 0 */
+ "merg", /* 1 */
+ "mask", /* 2 */
+ "mul", /* 3 */
+ "div", /* 4 */
+ "and", /* 5 */
+ "or", /* 6 */
+ "xor", /* 7 */
+ "shf", /* 8 */
+ "add", /* 9 */
+ "sub", /* 10 */
+ "exit", /* 11 */
+ "jmp", /* 12 */
+ "jmpi", /* 13 */
+ "jmpa", /* 14 */
+ "jmps", /* 15 */
+ "tac", /* 16 */
+ "ldea", /* 17 */
+ "ld", /* 18 */
+ "tas", /* 19 */
+ "pshea", /* 20 */
+ "st", /* 21 */
+ "call", /* 22 */
+ "calls", /* 23 */
+ "callq", /* 24 */
+ "pfork", /* 25 */
+ "ste", /* 26 */
+ "incr", /* 27 */
+ "cvtw", /* 28 */
+ "cvtb", /* 29 */
+ "cvth", /* 30 */
+ "cvts", /* 31 */
+ "cvtd", /* 32 */
+ "cvtl", /* 33 */
+ "ldpa", /* 34 */
+ "plc", /* 35 */
+ "tzc", /* 36 */
+ "eq", /* 37 */
+ "leu", /* 38 */
+ "ltu", /* 39 */
+ "le", /* 40 */
+ "lt", /* 41 */
+ "not", /* 42 */
+ "neg", /* 43 */
+ "lop", /* 44 */
+ "cprs", /* 45 */
+ "nop", /* 46 */
+ "br", /* 47 */
+ "bri", /* 48 */
+ "bra", /* 49 */
+ "brs", /* 50 */
+ "ldvi", /* 51 */
+ "stvi", /* 52 */
+ "ldsdr", /* 53 */
+ "ldkdr", /* 54 */
+ "ln", /* 55 */
+ "patu", /* 56 */
+ "pate", /* 57 */
+ "pich", /* 58 */
+ "plch", /* 59 */
+ "idle", /* 60 */
+ "rtnq", /* 61 */
+ "cfork", /* 62 */
+ "rtn", /* 63 */
+ "wfork", /* 64 */
+ "join", /* 65 */
+ "rtnc", /* 66 */
+ "exp", /* 67 */
+ "sin", /* 68 */
+ "cos", /* 69 */
+ "psh", /* 70 */
+ "pop", /* 71 */
+ "eni", /* 72 */
+ "dsi", /* 73 */
+ "bkpt", /* 74 */
+ "msync", /* 75 */
+ "mski", /* 76 */
+ "xmti", /* 77 */
+ "tstvv", /* 78 */
+ "diag", /* 79 */
+ "pbkpt", /* 80 */
+ "sqrt", /* 81 */
+ "casr", /* 82 */
+ "atan", /* 83 */
+ "sum", /* 84 */
+ "all", /* 85 */
+ "any", /* 86 */
+ "parity", /* 87 */
+ "max", /* 88 */
+ "min", /* 89 */
+ "prod", /* 90 */
+ "halt", /* 91 */
+ "sysc", /* 92 */
+ "trap", /* 93 */
+ "tst", /* 94 */
+ "lck", /* 95 */
+ "ulk", /* 96 */
+ "spawn", /* 97 */
+ "ldcmr", /* 98 */
+ "stcmr", /* 99 */
+ "popr", /* 100 */
+ "pshr", /* 101 */
+ "rcvr", /* 102 */
+ "matm", /* 103 */
+ "sndr", /* 104 */
+ "putr", /* 105 */
+ "getr", /* 106 */
+ "matr", /* 107 */
+ "mat", /* 108 */
+ "get", /* 109 */
+ "rcv", /* 110 */
+ "inc", /* 111 */
+ "put", /* 112 */
+ "snd", /* 113 */
+ "enal", /* 114 */
+ "enag", /* 115 */
+ "frint", /* 116 */
+ "xpnd", /* 117 */
+ "ctrsl", /* 118 */
+ "ctrsg", /* 119 */
+ "stop", /* 120 */
+};
+
+char *rop[] = {
+ "", /* 0 */
+ ".t", /* 1 */
+ ".f", /* 2 */
+ ".s", /* 3 */
+ ".d", /* 4 */
+ ".b", /* 5 */
+ ".h", /* 6 */
+ ".w", /* 7 */
+ ".l", /* 8 */
+ ".x", /* 9 */
+ ".u", /* 10 */
+ ".s.f", /* 11 */
+ ".d.f", /* 12 */
+ ".b.f", /* 13 */
+ ".h.f", /* 14 */
+ ".w.f", /* 15 */
+ ".l.f", /* 16 */
+ ".t.f", /* 17 */
+ ".s.t", /* 18 */
+ ".d.t", /* 19 */
+ ".b.t", /* 20 */
+ ".h.t", /* 21 */
+ ".w.t", /* 22 */
+ ".l.t", /* 23 */
+ ".t.t", /* 24 */
+};
diff --git a/contrib/binutils/include/opcode/i386.h b/contrib/binutils/include/opcode/i386.h
index 71c204c..5e3673e 100644
--- a/contrib/binutils/include/opcode/i386.h
+++ b/contrib/binutils/include/opcode/i386.h
@@ -1,6 +1,6 @@
/* opcode/i386.h -- Intel 80386 opcode table
Copyright 1989, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001
+ 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler, and GDB, the GNU Debugger.
@@ -896,8 +896,8 @@ static const template i386_optab[] = {
{"cmpxchg8b",1,0x0fc7, 1, Cpu586, NoSuf|Modrm, { LLongMem, 0, 0} },
/* Pentium II/Pentium Pro extensions. */
-{"sysenter",0, 0x0f34, X, Cpu686|CpuNo64, NoSuf, { 0, 0, 0} },
-{"sysexit", 0, 0x0f35, X, Cpu686|CpuNo64, NoSuf, { 0, 0, 0} },
+{"sysenter",0, 0x0f34, X, Cpu686, NoSuf, { 0, 0, 0} },
+{"sysexit", 0, 0x0f35, X, Cpu686, NoSuf, { 0, 0, 0} },
{"fxsave", 1, 0x0fae, 0, Cpu686, FP|Modrm, { LLongMem, 0, 0} },
{"fxrstor", 1, 0x0fae, 1, Cpu686, FP|Modrm, { LLongMem, 0, 0} },
{"rdpmc", 0, 0x0f33, X, Cpu686, NoSuf, { 0, 0, 0} },
@@ -1302,6 +1302,30 @@ static const template i386_optab[] = {
{"punpckhqdq",2, 0x660f6d, X, CpuSSE2, FP|Modrm, { RegXMM|LLongMem, RegXMM, 0 } },
{"punpcklqdq",2, 0x660f6c, X, CpuSSE2, FP|Modrm, { RegXMM|LLongMem, RegXMM, 0 } },
+/* Prescott New Instructions. */
+
+{"addsubpd", 2, 0x660fd0, X, CpuPNI, FP|Modrm, { RegXMM|LLongMem, RegXMM, 0 } },
+{"addsubps", 2, 0xf20fd0, X, CpuPNI, FP|Modrm, { RegXMM|LLongMem, RegXMM, 0 } },
+{"fisttp", 1, 0xdf, 1, CpuPNI, sl_FP|FloatMF|Modrm, { ShortMem|LongMem, 0, 0} },
+/* Intel Syntax */
+{"fisttpd", 1, 0xdd, 1, CpuPNI, FP|Modrm, { LLongMem, 0, 0} },
+{"fisttpq", 1, 0xdd, 1, CpuPNI, FP|Modrm, { LLongMem, 0, 0} },
+{"fisttpll", 1, 0xdd, 1, CpuPNI, FP|Modrm, { LLongMem, 0, 0} },
+{"haddpd", 2, 0x660f7c, X, CpuPNI, FP|Modrm, { RegXMM|LLongMem, RegXMM, 0 } },
+{"haddps", 2, 0xf20f7c, X, CpuPNI, FP|Modrm, { RegXMM|LLongMem, RegXMM, 0 } },
+{"hsubpd", 2, 0x660f7d, X, CpuPNI, FP|Modrm, { RegXMM|LLongMem, RegXMM, 0 } },
+{"hsubps", 2, 0xf20f7d, X, CpuPNI, FP|Modrm, { RegXMM|LLongMem, RegXMM, 0 } },
+{"lddqu", 2, 0xf20ff0, X, CpuPNI, FP|Modrm, { LLongMem, RegXMM, 0 } },
+{"monitor", 0, 0x0f01, 0xc8, CpuPNI, FP|ImmExt, { 0, 0, 0} },
+/* Need to ensure only "monitor %eax,%ecx,%edx" is accepted. */
+{"monitor", 3, 0x0f01, 0xc8, CpuPNI, FP|ImmExt, { Reg32, Reg32, Reg32} },
+{"movddup", 2, 0xf20f12, X, CpuPNI, FP|Modrm, { RegXMM|LLongMem, RegXMM, 0 } },
+{"movshdup", 2, 0xf30f16, X, CpuPNI, FP|Modrm, { RegXMM|LLongMem, RegXMM, 0 } },
+{"movsldup", 2, 0xf30f12, X, CpuPNI, FP|Modrm, { RegXMM|LLongMem, RegXMM, 0 } },
+{"mwait", 0, 0x0f01, 0xc9, CpuPNI, FP|ImmExt, { 0, 0, 0} },
+/* Need to ensure only "mwait %eax,%ecx" is accepted. */
+{"mwait", 2, 0x0f01, 0xc9, CpuPNI, FP|ImmExt, { Reg32, Reg32, 0} },
+
/* AMD 3DNow! instructions. */
{"prefetch", 1, 0x0f0d, 0, Cpu3dnow, FP|Modrm, { ByteMem, 0, 0 } },
@@ -1337,6 +1361,15 @@ static const template i386_optab[] = {
{"sysret", 0, 0x0f07, X, CpuK6, lq_Suf|DefaultSize, { 0, 0, 0} },
{"swapgs", 0, 0x0f01, 0xf8, Cpu64, NoSuf|ImmExt, { 0, 0, 0} },
+/* VIA PadLock extensions. */
+{"xstorerng", 0, 0x0fa7c0, X, Cpu686|CpuPadLock, NoSuf|IsString, { 0, 0, 0} },
+{"xcryptecb", 0, 0xf30fa7c8, X, Cpu686|CpuPadLock, NoSuf|IsString, { 0, 0, 0} },
+{"xcryptcbc", 0, 0xf30fa7d0, X, Cpu686|CpuPadLock, NoSuf|IsString, { 0, 0, 0} },
+{"xcryptcfb", 0, 0xf30fa7e0, X, Cpu686|CpuPadLock, NoSuf|IsString, { 0, 0, 0} },
+{"xcryptofb", 0, 0xf30fa7e8, X, Cpu686|CpuPadLock, NoSuf|IsString, { 0, 0, 0} },
+/* alias for xstorerng */
+{"xstore", 0, 0x0fa7c0, X, Cpu686|CpuPadLock, NoSuf|IsString, { 0, 0, 0} },
+
/* sentinel */
{NULL, 0, 0, 0, 0, 0, { 0, 0, 0} }
};
diff --git a/contrib/binutils/include/opcode/ia64.h b/contrib/binutils/include/opcode/ia64.h
index d4e6d10..0d33fc6 100644
--- a/contrib/binutils/include/opcode/ia64.h
+++ b/contrib/binutils/include/opcode/ia64.h
@@ -1,7 +1,6 @@
/* ia64.h -- Header file for ia64 opcode table
- Copyright (C) 1998, 1999, 2002 David Mosberger-Tang <davidm@hpl.hp.com>
-
- See the file HP-COPYRIGHT for additional information. */
+ Copyright (C) 1998, 1999, 2002 Free Software Foundation, Inc.
+ Contributed by David Mosberger-Tang <davidm@hpl.hp.com> */
#ifndef opcode_ia64_h
#define opcode_ia64_h
@@ -39,13 +38,14 @@ enum ia64_unit
};
/* Changes to this enumeration must be propagated to the operand table in
- bfd/cpu-ia64-opc.c
- */
+ bfd/cpu-ia64-opc.c
+ */
enum ia64_opnd
{
IA64_OPND_NIL, /* no operand---MUST BE FIRST!*/
/* constants */
+ IA64_OPND_AR_CSD, /* application register csd (ar.csd) */
IA64_OPND_AR_CCV, /* application register ccv (ar.ccv) */
IA64_OPND_AR_PFS, /* application register pfs (ar.pfs) */
IA64_OPND_C1, /* the constant 1 */
@@ -133,6 +133,7 @@ enum ia64_opnd
IA64_OPND_TGT25b, /* signed 25-bit (ip + 16*bits 6-12, 20-32, 36) */
IA64_OPND_TGT25c, /* signed 25-bit (ip + 16*bits 13-32, 36) */
IA64_OPND_TGT64, /* 64-bit (ip + 16*bits 13-32, 36, 2-40(L)) */
+ IA64_OPND_LDXMOV, /* any symbol, generates R_IA64_LDXMOV. */
IA64_OPND_COUNT /* # of operand types (MUST BE LAST!) */
};
@@ -287,7 +288,7 @@ struct ia64_opcode
/* Used by ia64_find_next_opcode (). */
short ent_index;
- /* Opcode dependencies. */
+ /* Opcode dependencies. */
const struct ia64_opcode_dependency *dependencies;
};
diff --git a/contrib/binutils/include/opcode/np1.h b/contrib/binutils/include/opcode/np1.h
new file mode 100644
index 0000000..c3f7e29
--- /dev/null
+++ b/contrib/binutils/include/opcode/np1.h
@@ -0,0 +1,422 @@
+/* Print GOULD NPL instructions for GDB, the GNU debugger.
+ Copyright 1986, 1987, 1989, 1991 Free Software Foundation, Inc.
+
+This file is part of GDB.
+
+GDB is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 1, or (at your option)
+any later version.
+
+GDB is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GDB; see the file COPYING. If not, write to
+the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+struct gld_opcode
+{
+ char *name;
+ unsigned long opcode;
+ unsigned long mask;
+ char *args;
+ int length;
+};
+
+/* We store four bytes of opcode for all opcodes because that
+ is the most any of them need. The actual length of an instruction
+ is always at least 2 bytes, and at most four. The length of the
+ instruction is based on the opcode.
+
+ The mask component is a mask saying which bits must match
+ particular opcode in order for an instruction to be an instance
+ of that opcode.
+
+ The args component is a string containing characters
+ that are used to format the arguments to the instruction. */
+
+/* Kinds of operands:
+ r Register in first field
+ R Register in second field
+ b Base register in first field
+ B Base register in second field
+ v Vector register in first field
+ V Vector register in first field
+ A Optional address register (base register)
+ X Optional index register
+ I Immediate data (16bits signed)
+ O Offset field (16bits signed)
+ h Offset field (15bits signed)
+ d Offset field (14bits signed)
+ S Shift count field
+
+ any other characters are printed as is...
+*/
+
+/* The assembler requires that this array be sorted as follows:
+ all instances of the same mnemonic must be consecutive.
+ All instances of the same mnemonic with the same number of operands
+ must be consecutive.
+ */
+struct gld_opcode gld_opcodes[] =
+{
+{ "lb", 0xb4080000, 0xfc080000, "r,xOA,X", 4 },
+{ "lnb", 0xb8080000, 0xfc080000, "r,xOA,X", 4 },
+{ "lbs", 0xec080000, 0xfc080000, "r,xOA,X", 4 },
+{ "lh", 0xb4000001, 0xfc080001, "r,xOA,X", 4 },
+{ "lnh", 0xb8000001, 0xfc080001, "r,xOA,X", 4 },
+{ "lw", 0xb4000000, 0xfc080000, "r,xOA,X", 4 },
+{ "lnw", 0xb8000000, 0xfc080000, "r,xOA,X", 4 },
+{ "ld", 0xb4000002, 0xfc080002, "r,xOA,X", 4 },
+{ "lnd", 0xb8000002, 0xfc080002, "r,xOA,X", 4 },
+{ "li", 0xf8000000, 0xfc7f0000, "r,I", 4 },
+{ "lpa", 0x50080000, 0xfc080000, "r,xOA,X", 4 },
+{ "la", 0x50000000, 0xfc080000, "r,xOA,X", 4 },
+{ "labr", 0x58080000, 0xfc080000, "b,xOA,X", 4 },
+{ "lbp", 0x90080000, 0xfc080000, "r,xOA,X", 4 },
+{ "lhp", 0x90000001, 0xfc080001, "r,xOA,X", 4 },
+{ "lwp", 0x90000000, 0xfc080000, "r,xOA,X", 4 },
+{ "ldp", 0x90000002, 0xfc080002, "r,xOA,X", 4 },
+{ "suabr", 0x58000000, 0xfc080000, "b,xOA,X", 4 },
+{ "lf", 0xbc000000, 0xfc080000, "r,xOA,X", 4 },
+{ "lfbr", 0xbc080000, 0xfc080000, "b,xOA,X", 4 },
+{ "lwbr", 0x5c000000, 0xfc080000, "b,xOA,X", 4 },
+{ "stb", 0xd4080000, 0xfc080000, "r,xOA,X", 4 },
+{ "sth", 0xd4000001, 0xfc080001, "r,xOA,X", 4 },
+{ "stw", 0xd4000000, 0xfc080000, "r,xOA,X", 4 },
+{ "std", 0xd4000002, 0xfc080002, "r,xOA,X", 4 },
+{ "stf", 0xdc000000, 0xfc080000, "r,xOA,X", 4 },
+{ "stfbr", 0xdc080000, 0xfc080000, "b,xOA,X", 4 },
+{ "stwbr", 0x54000000, 0xfc080000, "b,xOA,X", 4 },
+{ "zmb", 0xd8080000, 0xfc080000, "r,xOA,X", 4 },
+{ "zmh", 0xd8000001, 0xfc080001, "r,xOA,X", 4 },
+{ "zmw", 0xd8000000, 0xfc080000, "r,xOA,X", 4 },
+{ "zmd", 0xd8000002, 0xfc080002, "r,xOA,X", 4 },
+{ "stbp", 0x94080000, 0xfc080000, "r,xOA,X", 4 },
+{ "sthp", 0x94000001, 0xfc080001, "r,xOA,X", 4 },
+{ "stwp", 0x94000000, 0xfc080000, "r,xOA,X", 4 },
+{ "stdp", 0x94000002, 0xfc080002, "r,xOA,X", 4 },
+{ "lil", 0xf80b0000, 0xfc7f0000, "r,D", 4 },
+{ "lwsl1", 0xec000000, 0xfc080000, "r,xOA,X", 4 },
+{ "lwsl2", 0xfc000000, 0xfc080000, "r,xOA,X", 4 },
+{ "lwsl3", 0xfc080000, 0xfc080000, "r,xOA,X", 4 },
+
+{ "lvb", 0xb0080000, 0xfc080000, "v,xOA,X", 4 },
+{ "lvh", 0xb0000001, 0xfc080001, "v,xOA,X", 4 },
+{ "lvw", 0xb0000000, 0xfc080000, "v,xOA,X", 4 },
+{ "lvd", 0xb0000002, 0xfc080002, "v,xOA,X", 4 },
+{ "liv", 0x3c040000, 0xfc0f0000, "v,R", 2 },
+{ "livf", 0x3c080000, 0xfc0f0000, "v,R", 2 },
+{ "stvb", 0xd0080000, 0xfc080000, "v,xOA,X", 4 },
+{ "stvh", 0xd0000001, 0xfc080001, "v,xOA,X", 4 },
+{ "stvw", 0xd0000000, 0xfc080000, "v,xOA,X", 4 },
+{ "stvd", 0xd0000002, 0xfc080002, "v,xOA,X", 4 },
+
+{ "trr", 0x2c000000, 0xfc0f0000, "r,R", 2 },
+{ "trn", 0x2c040000, 0xfc0f0000, "r,R", 2 },
+{ "trnd", 0x2c0c0000, 0xfc0f0000, "r,R", 2 },
+{ "trabs", 0x2c010000, 0xfc0f0000, "r,R", 2 },
+{ "trabsd", 0x2c090000, 0xfc0f0000, "r,R", 2 },
+{ "trc", 0x2c030000, 0xfc0f0000, "r,R", 2 },
+{ "xcr", 0x28040000, 0xfc0f0000, "r,R", 2 },
+{ "cxcr", 0x2c060000, 0xfc0f0000, "r,R", 2 },
+{ "cxcrd", 0x2c0e0000, 0xfc0f0000, "r,R", 2 },
+{ "tbrr", 0x2c020000, 0xfc0f0000, "r,B", 2 },
+{ "trbr", 0x28030000, 0xfc0f0000, "b,R", 2 },
+{ "xcbr", 0x28020000, 0xfc0f0000, "b,B", 2 },
+{ "tbrbr", 0x28010000, 0xfc0f0000, "b,B", 2 },
+
+{ "trvv", 0x28050000, 0xfc0f0000, "v,V", 2 },
+{ "trvvn", 0x2c050000, 0xfc0f0000, "v,V", 2 },
+{ "trvvnd", 0x2c0d0000, 0xfc0f0000, "v,V", 2 },
+{ "trvab", 0x2c070000, 0xfc0f0000, "v,V", 2 },
+{ "trvabd", 0x2c0f0000, 0xfc0f0000, "v,V", 2 },
+{ "cmpv", 0x14060000, 0xfc0f0000, "v,V", 2 },
+{ "expv", 0x14070000, 0xfc0f0000, "v,V", 2 },
+{ "mrvvlt", 0x10030000, 0xfc0f0000, "v,V", 2 },
+{ "mrvvle", 0x10040000, 0xfc0f0000, "v,V", 2 },
+{ "mrvvgt", 0x14030000, 0xfc0f0000, "v,V", 2 },
+{ "mrvvge", 0x14040000, 0xfc0f0000, "v,V", 2 },
+{ "mrvveq", 0x10050000, 0xfc0f0000, "v,V", 2 },
+{ "mrvvne", 0x10050000, 0xfc0f0000, "v,V", 2 },
+{ "mrvrlt", 0x100d0000, 0xfc0f0000, "v,R", 2 },
+{ "mrvrle", 0x100e0000, 0xfc0f0000, "v,R", 2 },
+{ "mrvrgt", 0x140d0000, 0xfc0f0000, "v,R", 2 },
+{ "mrvrge", 0x140e0000, 0xfc0f0000, "v,R", 2 },
+{ "mrvreq", 0x100f0000, 0xfc0f0000, "v,R", 2 },
+{ "mrvrne", 0x140f0000, 0xfc0f0000, "v,R", 2 },
+{ "trvr", 0x140b0000, 0xfc0f0000, "r,V", 2 },
+{ "trrv", 0x140c0000, 0xfc0f0000, "v,R", 2 },
+
+{ "bu", 0x40000000, 0xff880000, "xOA,X", 4 },
+{ "bns", 0x70080000, 0xff880000, "xOA,X", 4 },
+{ "bnco", 0x70880000, 0xff880000, "xOA,X", 4 },
+{ "bge", 0x71080000, 0xff880000, "xOA,X", 4 },
+{ "bne", 0x71880000, 0xff880000, "xOA,X", 4 },
+{ "bunge", 0x72080000, 0xff880000, "xOA,X", 4 },
+{ "bunle", 0x72880000, 0xff880000, "xOA,X", 4 },
+{ "bgt", 0x73080000, 0xff880000, "xOA,X", 4 },
+{ "bnany", 0x73880000, 0xff880000, "xOA,X", 4 },
+{ "bs" , 0x70000000, 0xff880000, "xOA,X", 4 },
+{ "bco", 0x70800000, 0xff880000, "xOA,X", 4 },
+{ "blt", 0x71000000, 0xff880000, "xOA,X", 4 },
+{ "beq", 0x71800000, 0xff880000, "xOA,X", 4 },
+{ "buge", 0x72000000, 0xff880000, "xOA,X", 4 },
+{ "bult", 0x72800000, 0xff880000, "xOA,X", 4 },
+{ "ble", 0x73000000, 0xff880000, "xOA,X", 4 },
+{ "bany", 0x73800000, 0xff880000, "xOA,X", 4 },
+{ "brlnk", 0x44000000, 0xfc080000, "r,xOA,X", 4 },
+{ "bib", 0x48000000, 0xfc080000, "r,xOA,X", 4 },
+{ "bih", 0x48080000, 0xfc080000, "r,xOA,X", 4 },
+{ "biw", 0x4c000000, 0xfc080000, "r,xOA,X", 4 },
+{ "bid", 0x4c080000, 0xfc080000, "r,xOA,X", 4 },
+{ "bivb", 0x60000000, 0xfc080000, "r,xOA,X", 4 },
+{ "bivh", 0x60080000, 0xfc080000, "r,xOA,X", 4 },
+{ "bivw", 0x64000000, 0xfc080000, "r,xOA,X", 4 },
+{ "bivd", 0x64080000, 0xfc080000, "r,xOA,X", 4 },
+{ "bvsb", 0x68000000, 0xfc080000, "r,xOA,X", 4 },
+{ "bvsh", 0x68080000, 0xfc080000, "r,xOA,X", 4 },
+{ "bvsw", 0x6c000000, 0xfc080000, "r,xOA,X", 4 },
+{ "bvsd", 0x6c080000, 0xfc080000, "r,xOA,X", 4 },
+
+{ "camb", 0x80080000, 0xfc080000, "r,xOA,X", 4 },
+{ "camh", 0x80000001, 0xfc080001, "r,xOA,X", 4 },
+{ "camw", 0x80000000, 0xfc080000, "r,xOA,X", 4 },
+{ "camd", 0x80000002, 0xfc080002, "r,xOA,X", 4 },
+{ "car", 0x10000000, 0xfc0f0000, "r,R", 2 },
+{ "card", 0x14000000, 0xfc0f0000, "r,R", 2 },
+{ "ci", 0xf8050000, 0xfc7f0000, "r,I", 4 },
+{ "chkbnd", 0x5c080000, 0xfc080000, "r,xOA,X", 4 },
+
+{ "cavv", 0x10010000, 0xfc0f0000, "v,V", 2 },
+{ "cavr", 0x10020000, 0xfc0f0000, "v,R", 2 },
+{ "cavvd", 0x10090000, 0xfc0f0000, "v,V", 2 },
+{ "cavrd", 0x100b0000, 0xfc0f0000, "v,R", 2 },
+
+{ "anmb", 0x84080000, 0xfc080000, "r,xOA,X", 4 },
+{ "anmh", 0x84000001, 0xfc080001, "r,xOA,X", 4 },
+{ "anmw", 0x84000000, 0xfc080000, "r,xOA,X", 4 },
+{ "anmd", 0x84000002, 0xfc080002, "r,xOA,X", 4 },
+{ "anr", 0x04000000, 0xfc0f0000, "r,R", 2 },
+{ "ani", 0xf8080000, 0xfc7f0000, "r,I", 4 },
+{ "ormb", 0xb8080000, 0xfc080000, "r,xOA,X", 4 },
+{ "ormh", 0xb8000001, 0xfc080001, "r,xOA,X", 4 },
+{ "ormw", 0xb8000000, 0xfc080000, "r,xOA,X", 4 },
+{ "ormd", 0xb8000002, 0xfc080002, "r,xOA,X", 4 },
+{ "orr", 0x08000000, 0xfc0f0000, "r,R", 2 },
+{ "oi", 0xf8090000, 0xfc7f0000, "r,I", 4 },
+{ "eomb", 0x8c080000, 0xfc080000, "r,xOA,X", 4 },
+{ "eomh", 0x8c000001, 0xfc080001, "r,xOA,X", 4 },
+{ "eomw", 0x8c000000, 0xfc080000, "r,xOA,X", 4 },
+{ "eomd", 0x8c000002, 0xfc080002, "r,xOA,X", 4 },
+{ "eor", 0x0c000000, 0xfc0f0000, "r,R", 2 },
+{ "eoi", 0xf80a0000, 0xfc7f0000, "r,I", 4 },
+
+{ "anvv", 0x04010000, 0xfc0f0000, "v,V", 2 },
+{ "anvr", 0x04020000, 0xfc0f0000, "v,R", 2 },
+{ "orvv", 0x08010000, 0xfc0f0000, "v,V", 2 },
+{ "orvr", 0x08020000, 0xfc0f0000, "v,R", 2 },
+{ "eovv", 0x0c010000, 0xfc0f0000, "v,V", 2 },
+{ "eovr", 0x0c020000, 0xfc0f0000, "v,R", 2 },
+
+{ "sacz", 0x100c0000, 0xfc0f0000, "r,R", 2 },
+{ "sla", 0x1c400000, 0xfc600000, "r,S", 2 },
+{ "sll", 0x1c600000, 0xfc600000, "r,S", 2 },
+{ "slc", 0x24400000, 0xfc600000, "r,S", 2 },
+{ "slad", 0x20400000, 0xfc600000, "r,S", 2 },
+{ "slld", 0x20600000, 0xfc600000, "r,S", 2 },
+{ "sra", 0x1c000000, 0xfc600000, "r,S", 2 },
+{ "srl", 0x1c200000, 0xfc600000, "r,S", 2 },
+{ "src", 0x24000000, 0xfc600000, "r,S", 2 },
+{ "srad", 0x20000000, 0xfc600000, "r,S", 2 },
+{ "srld", 0x20200000, 0xfc600000, "r,S", 2 },
+{ "sda", 0x3c030000, 0xfc0f0000, "r,R", 2 },
+{ "sdl", 0x3c020000, 0xfc0f0000, "r,R", 2 },
+{ "sdc", 0x3c010000, 0xfc0f0000, "r,R", 2 },
+{ "sdad", 0x3c0b0000, 0xfc0f0000, "r,R", 2 },
+{ "sdld", 0x3c0a0000, 0xfc0f0000, "r,R", 2 },
+
+{ "svda", 0x3c070000, 0xfc0f0000, "v,R", 2 },
+{ "svdl", 0x3c060000, 0xfc0f0000, "v,R", 2 },
+{ "svdc", 0x3c050000, 0xfc0f0000, "v,R", 2 },
+{ "svdad", 0x3c0e0000, 0xfc0f0000, "v,R", 2 },
+{ "svdld", 0x3c0d0000, 0xfc0f0000, "v,R", 2 },
+
+{ "sbm", 0xac080000, 0xfc080000, "f,xOA,X", 4 },
+{ "zbm", 0xac000000, 0xfc080000, "f,xOA,X", 4 },
+{ "tbm", 0xa8080000, 0xfc080000, "f,xOA,X", 4 },
+{ "incmb", 0xa0000000, 0xfc080000, "xOA,X", 4 },
+{ "incmh", 0xa0080000, 0xfc080000, "xOA,X", 4 },
+{ "incmw", 0xa4000000, 0xfc080000, "xOA,X", 4 },
+{ "incmd", 0xa4080000, 0xfc080000, "xOA,X", 4 },
+{ "sbmd", 0x7c080000, 0xfc080000, "r,xOA,X", 4 },
+{ "zbmd", 0x7c000000, 0xfc080000, "r,xOA,X", 4 },
+{ "tbmd", 0x78080000, 0xfc080000, "r,xOA,X", 4 },
+
+{ "ssm", 0x9c080000, 0xfc080000, "f,xOA,X", 4 },
+{ "zsm", 0x9c000000, 0xfc080000, "f,xOA,X", 4 },
+{ "tsm", 0x98080000, 0xfc080000, "f,xOA,X", 4 },
+
+{ "admb", 0xc8080000, 0xfc080000, "r,xOA,X", 4 },
+{ "admh", 0xc8000001, 0xfc080001, "r,xOA,X", 4 },
+{ "admw", 0xc8000000, 0xfc080000, "r,xOA,X", 4 },
+{ "admd", 0xc8000002, 0xfc080002, "r,xOA,X", 4 },
+{ "adr", 0x38000000, 0xfc0f0000, "r,R", 2 },
+{ "armb", 0xe8080000, 0xfc080000, "r,xOA,X", 4 },
+{ "armh", 0xe8000001, 0xfc080001, "r,xOA,X", 4 },
+{ "armw", 0xe8000000, 0xfc080000, "r,xOA,X", 4 },
+{ "armd", 0xe8000002, 0xfc080002, "r,xOA,X", 4 },
+{ "adi", 0xf8010000, 0xfc0f0000, "r,I", 4 },
+{ "sumb", 0xcc080000, 0xfc080000, "r,xOA,X", 4 },
+{ "sumh", 0xcc000001, 0xfc080001, "r,xOA,X", 4 },
+{ "sumw", 0xcc000000, 0xfc080000, "r,xOA,X", 4 },
+{ "sumd", 0xcc000002, 0xfc080002, "r,xOA,X", 4 },
+{ "sur", 0x3c000000, 0xfc0f0000, "r,R", 2 },
+{ "sui", 0xf8020000, 0xfc0f0000, "r,I", 4 },
+{ "mpmb", 0xc0080000, 0xfc080000, "r,xOA,X", 4 },
+{ "mpmh", 0xc0000001, 0xfc080001, "r,xOA,X", 4 },
+{ "mpmw", 0xc0000000, 0xfc080000, "r,xOA,X", 4 },
+{ "mpr", 0x38020000, 0xfc0f0000, "r,R", 2 },
+{ "mprd", 0x3c0f0000, 0xfc0f0000, "r,R", 2 },
+{ "mpi", 0xf8030000, 0xfc0f0000, "r,I", 4 },
+{ "dvmb", 0xc4080000, 0xfc080000, "r,xOA,X", 4 },
+{ "dvmh", 0xc4000001, 0xfc080001, "r,xOA,X", 4 },
+{ "dvmw", 0xc4000000, 0xfc080000, "r,xOA,X", 4 },
+{ "dvr", 0x380a0000, 0xfc0f0000, "r,R", 2 },
+{ "dvi", 0xf8040000, 0xfc0f0000, "r,I", 4 },
+{ "exs", 0x38080000, 0xfc0f0000, "r,R", 2 },
+
+{ "advv", 0x30000000, 0xfc0f0000, "v,V", 2 },
+{ "advvd", 0x30080000, 0xfc0f0000, "v,V", 2 },
+{ "adrv", 0x34000000, 0xfc0f0000, "v,R", 2 },
+{ "adrvd", 0x34080000, 0xfc0f0000, "v,R", 2 },
+{ "suvv", 0x30010000, 0xfc0f0000, "v,V", 2 },
+{ "suvvd", 0x30090000, 0xfc0f0000, "v,V", 2 },
+{ "surv", 0x34010000, 0xfc0f0000, "v,R", 2 },
+{ "survd", 0x34090000, 0xfc0f0000, "v,R", 2 },
+{ "mpvv", 0x30020000, 0xfc0f0000, "v,V", 2 },
+{ "mprv", 0x34020000, 0xfc0f0000, "v,R", 2 },
+
+{ "adfw", 0xe0080000, 0xfc080000, "r,xOA,X", 4 },
+{ "adfd", 0xe0080002, 0xfc080002, "r,xOA,X", 4 },
+{ "adrfw", 0x38010000, 0xfc0f0000, "r,R", 2 },
+{ "adrfd", 0x38090000, 0xfc0f0000, "r,R", 2 },
+{ "surfw", 0xe0000000, 0xfc080000, "r,xOA,X", 4 },
+{ "surfd", 0xe0000002, 0xfc080002, "r,xOA,X", 4 },
+{ "surfw", 0x38030000, 0xfc0f0000, "r,R", 2 },
+{ "surfd", 0x380b0000, 0xfc0f0000, "r,R", 2 },
+{ "mpfw", 0xe4080000, 0xfc080000, "r,xOA,X", 4 },
+{ "mpfd", 0xe4080002, 0xfc080002, "r,xOA,X", 4 },
+{ "mprfw", 0x38060000, 0xfc0f0000, "r,R", 2 },
+{ "mprfd", 0x380e0000, 0xfc0f0000, "r,R", 2 },
+{ "rfw", 0xe4000000, 0xfc080000, "r,xOA,X", 4 },
+{ "rfd", 0xe4000002, 0xfc080002, "r,xOA,X", 4 },
+{ "rrfw", 0x0c0e0000, 0xfc0f0000, "r", 2 },
+{ "rrfd", 0x0c0f0000, 0xfc0f0000, "r", 2 },
+
+{ "advvfw", 0x30040000, 0xfc0f0000, "v,V", 2 },
+{ "advvfd", 0x300c0000, 0xfc0f0000, "v,V", 2 },
+{ "adrvfw", 0x34040000, 0xfc0f0000, "v,R", 2 },
+{ "adrvfd", 0x340c0000, 0xfc0f0000, "v,R", 2 },
+{ "suvvfw", 0x30050000, 0xfc0f0000, "v,V", 2 },
+{ "suvvfd", 0x300d0000, 0xfc0f0000, "v,V", 2 },
+{ "survfw", 0x34050000, 0xfc0f0000, "v,R", 2 },
+{ "survfd", 0x340d0000, 0xfc0f0000, "v,R", 2 },
+{ "mpvvfw", 0x30060000, 0xfc0f0000, "v,V", 2 },
+{ "mpvvfd", 0x300e0000, 0xfc0f0000, "v,V", 2 },
+{ "mprvfw", 0x34060000, 0xfc0f0000, "v,R", 2 },
+{ "mprvfd", 0x340e0000, 0xfc0f0000, "v,R", 2 },
+{ "rvfw", 0x30070000, 0xfc0f0000, "v", 2 },
+{ "rvfd", 0x300f0000, 0xfc0f0000, "v", 2 },
+
+{ "fltw", 0x38070000, 0xfc0f0000, "r,R", 2 },
+{ "fltd", 0x380f0000, 0xfc0f0000, "r,R", 2 },
+{ "fixw", 0x38050000, 0xfc0f0000, "r,R", 2 },
+{ "fixd", 0x380d0000, 0xfc0f0000, "r,R", 2 },
+{ "cfpds", 0x3c090000, 0xfc0f0000, "r,R", 2 },
+
+{ "fltvw", 0x080d0000, 0xfc0f0000, "v,V", 2 },
+{ "fltvd", 0x080f0000, 0xfc0f0000, "v,V", 2 },
+{ "fixvw", 0x080c0000, 0xfc0f0000, "v,V", 2 },
+{ "fixvd", 0x080e0000, 0xfc0f0000, "v,V", 2 },
+{ "cfpvds", 0x0c0d0000, 0xfc0f0000, "v,V", 2 },
+
+{ "orvrn", 0x000a0000, 0xfc0f0000, "r,V", 2 },
+{ "andvrn", 0x00080000, 0xfc0f0000, "r,V", 2 },
+{ "frsteq", 0x04090000, 0xfc0f0000, "r,V", 2 },
+{ "sigma", 0x0c080000, 0xfc0f0000, "r,V", 2 },
+{ "sigmad", 0x0c0a0000, 0xfc0f0000, "r,V", 2 },
+{ "sigmf", 0x08080000, 0xfc0f0000, "r,V", 2 },
+{ "sigmfd", 0x080a0000, 0xfc0f0000, "r,V", 2 },
+{ "prodf", 0x04080000, 0xfc0f0000, "r,V", 2 },
+{ "prodfd", 0x040a0000, 0xfc0f0000, "r,V", 2 },
+{ "maxv", 0x10080000, 0xfc0f0000, "r,V", 2 },
+{ "maxvd", 0x100a0000, 0xfc0f0000, "r,V", 2 },
+{ "minv", 0x14080000, 0xfc0f0000, "r,V", 2 },
+{ "minvd", 0x140a0000, 0xfc0f0000, "r,V", 2 },
+
+{ "lpsd", 0xf0000000, 0xfc080000, "xOA,X", 4 },
+{ "ldc", 0xf0080000, 0xfc080000, "xOA,X", 4 },
+{ "spm", 0x040c0000, 0xfc0f0000, "r", 2 },
+{ "rpm", 0x040d0000, 0xfc0f0000, "r", 2 },
+{ "tritr", 0x00070000, 0xfc0f0000, "r", 2 },
+{ "trrit", 0x00060000, 0xfc0f0000, "r", 2 },
+{ "rpswt", 0x04080000, 0xfc0f0000, "r", 2 },
+{ "exr", 0xf8070000, 0xfc0f0000, "", 4 },
+{ "halt", 0x00000000, 0xfc0f0000, "", 2 },
+{ "wait", 0x00010000, 0xfc0f0000, "", 2 },
+{ "nop", 0x00020000, 0xfc0f0000, "", 2 },
+{ "eiae", 0x00030000, 0xfc0f0000, "", 2 },
+{ "efae", 0x000d0000, 0xfc0f0000, "", 2 },
+{ "diae", 0x000e0000, 0xfc0f0000, "", 2 },
+{ "dfae", 0x000f0000, 0xfc0f0000, "", 2 },
+{ "spvc", 0xf8060000, 0xfc0f0000, "r,T,N", 4 },
+{ "rdsts", 0x00090000, 0xfc0f0000, "r", 2 },
+{ "setcpu", 0x000c0000, 0xfc0f0000, "r", 2 },
+{ "cmc", 0x000b0000, 0xfc0f0000, "r", 2 },
+{ "trrcu", 0x00040000, 0xfc0f0000, "r", 2 },
+{ "attnio", 0x00050000, 0xfc0f0000, "", 2 },
+{ "fudit", 0x28080000, 0xfc0f0000, "", 2 },
+{ "break", 0x28090000, 0xfc0f0000, "", 2 },
+{ "frzss", 0x280a0000, 0xfc0f0000, "", 2 },
+{ "ripi", 0x04040000, 0xfc0f0000, "r,R", 2 },
+{ "xcp", 0x04050000, 0xfc0f0000, "r", 2 },
+{ "block", 0x04060000, 0xfc0f0000, "", 2 },
+{ "unblock", 0x04070000, 0xfc0f0000, "", 2 },
+{ "trsc", 0x08060000, 0xfc0f0000, "r,R", 2 },
+{ "tscr", 0x08070000, 0xfc0f0000, "r,R", 2 },
+{ "fq", 0x04080000, 0xfc0f0000, "r", 2 },
+{ "flupte", 0x2c080000, 0xfc0f0000, "r", 2 },
+{ "rviu", 0x040f0000, 0xfc0f0000, "", 2 },
+{ "ldel", 0x280c0000, 0xfc0f0000, "r,R", 2 },
+{ "ldu", 0x280d0000, 0xfc0f0000, "r,R", 2 },
+{ "stdecc", 0x280b0000, 0xfc0f0000, "r,R", 2 },
+{ "trpc", 0x08040000, 0xfc0f0000, "r", 2 },
+{ "tpcr", 0x08050000, 0xfc0f0000, "r", 2 },
+{ "ghalt", 0x0c050000, 0xfc0f0000, "r", 2 },
+{ "grun", 0x0c040000, 0xfc0f0000, "", 2 },
+{ "tmpr", 0x2c0a0000, 0xfc0f0000, "r,R", 2 },
+{ "trmp", 0x2c0b0000, 0xfc0f0000, "r,R", 2 },
+
+{ "trrve", 0x28060000, 0xfc0f0000, "r", 2 },
+{ "trver", 0x28070000, 0xfc0f0000, "r", 2 },
+{ "trvlr", 0x280f0000, 0xfc0f0000, "r", 2 },
+
+{ "linkfl", 0x18000000, 0xfc0f0000, "r,R", 2 },
+{ "linkbl", 0x18020000, 0xfc0f0000, "r,R", 2 },
+{ "linkfp", 0x18010000, 0xfc0f0000, "r,R", 2 },
+{ "linkbp", 0x18030000, 0xfc0f0000, "r,R", 2 },
+{ "linkpl", 0x18040000, 0xfc0f0000, "r,R", 2 },
+{ "ulinkl", 0x18080000, 0xfc0f0000, "r,R", 2 },
+{ "ulinkp", 0x18090000, 0xfc0f0000, "r,R", 2 },
+{ "ulinktl", 0x180a0000, 0xfc0f0000, "r,R", 2 },
+{ "ulinktp", 0x180b0000, 0xfc0f0000, "r,R", 2 },
+};
+
+int numopcodes = sizeof(gld_opcodes) / sizeof(gld_opcodes[0]);
+
+struct gld_opcode *endop = gld_opcodes + sizeof(gld_opcodes) /
+ sizeof(gld_opcodes[0]);
diff --git a/contrib/binutils/include/opcode/pn.h b/contrib/binutils/include/opcode/pn.h
new file mode 100644
index 0000000..8c427a2
--- /dev/null
+++ b/contrib/binutils/include/opcode/pn.h
@@ -0,0 +1,282 @@
+/* Print GOULD PN (PowerNode) instructions for GDB, the GNU debugger.
+ Copyright 1986, 1987, 1989, 1991 Free Software Foundation, Inc.
+
+This file is part of GDB.
+
+GDB is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 1, or (at your option)
+any later version.
+
+GDB is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GDB; see the file COPYING. If not, write to
+the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+struct gld_opcode
+{
+ char *name;
+ unsigned long opcode;
+ unsigned long mask;
+ char *args;
+ int length;
+};
+
+/* We store four bytes of opcode for all opcodes because that
+ is the most any of them need. The actual length of an instruction
+ is always at least 2 bytes, and at most four. The length of the
+ instruction is based on the opcode.
+
+ The mask component is a mask saying which bits must match
+ particular opcode in order for an instruction to be an instance
+ of that opcode.
+
+ The args component is a string containing characters
+ that are used to format the arguments to the instruction. */
+
+/* Kinds of operands:
+ r Register in first field
+ R Register in second field
+ b Base register in first field
+ B Base register in second field
+ v Vector register in first field
+ V Vector register in first field
+ A Optional address register (base register)
+ X Optional index register
+ I Immediate data (16bits signed)
+ O Offset field (16bits signed)
+ h Offset field (15bits signed)
+ d Offset field (14bits signed)
+ S Shift count field
+
+ any other characters are printed as is...
+*/
+
+/* The assembler requires that this array be sorted as follows:
+ all instances of the same mnemonic must be consecutive.
+ All instances of the same mnemonic with the same number of operands
+ must be consecutive.
+ */
+struct gld_opcode gld_opcodes[] =
+{
+{ "abm", 0xa0080000, 0xfc080000, "f,xOA,X", 4 },
+{ "abr", 0x18080000, 0xfc0c0000, "r,f", 2 },
+{ "aci", 0xfc770000, 0xfc7f8000, "r,I", 4 },
+{ "adfd", 0xe0080002, 0xfc080002, "r,xOA,X", 4 },
+{ "adfw", 0xe0080000, 0xfc080000, "r,xOA,X", 4 },
+{ "adi", 0xc8010000, 0xfc7f0000, "r,I", 4 },
+{ "admb", 0xb8080000, 0xfc080000, "r,xOA,X", 4 },
+{ "admd", 0xb8000002, 0xfc080002, "r,xOA,X", 4 },
+{ "admh", 0xb8000001, 0xfc080001, "r,xOA,X", 4 },
+{ "admw", 0xb8000000, 0xfc080000, "r,xOA,X", 4 },
+{ "adr", 0x38000000, 0xfc0f0000, "r,R", 2 },
+{ "adrfd", 0x38090000, 0xfc0f0000, "r,R", 2 },
+{ "adrfw", 0x38010000, 0xfc0f0000, "r,R", 2 },
+{ "adrm", 0x38080000, 0xfc0f0000, "r,R", 2 },
+{ "ai", 0xfc030000, 0xfc07ffff, "I", 4 },
+{ "anmb", 0x84080000, 0xfc080000, "r,xOA,X", 4 },
+{ "anmd", 0x84000002, 0xfc080002, "r,xOA,X", 4 },
+{ "anmh", 0x84000001, 0xfc080001, "r,xOA,X", 4 },
+{ "anmw", 0x84000000, 0xfc080000, "r,xOA,X", 4 },
+{ "anr", 0x04000000, 0xfc0f0000, "r,R", 2 },
+{ "armb", 0xe8080000, 0xfc080000, "r,xOA,X", 4 },
+{ "armd", 0xe8000002, 0xfc080002, "r,xOA,X", 4 },
+{ "armh", 0xe8000001, 0xfc080001, "r,xOA,X", 4 },
+{ "armw", 0xe8000000, 0xfc080000, "r,xOA,X", 4 },
+{ "bcf", 0xf0000000, 0xfc080000, "I,xOA,X", 4 },
+{ "bct", 0xec000000, 0xfc080000, "I,xOA,X", 4 },
+{ "bei", 0x00060000, 0xffff0000, "", 2 },
+{ "bft", 0xf0000000, 0xff880000, "xOA,X", 4 },
+{ "bib", 0xf4000000, 0xfc780000, "r,xOA", 4 },
+{ "bid", 0xf4600000, 0xfc780000, "r,xOA", 4 },
+{ "bih", 0xf4200000, 0xfc780000, "r,xOA", 4 },
+{ "biw", 0xf4400000, 0xfc780000, "r,xOA", 4 },
+{ "bl", 0xf8800000, 0xff880000, "xOA,X", 4 },
+{ "bsub", 0x5c080000, 0xff8f0000, "", 2 },
+{ "bsubm", 0x28080000, 0xfc080000, "", 4 },
+{ "bu", 0xec000000, 0xff880000, "xOA,X", 4 },
+{ "call", 0x28080000, 0xfc0f0000, "", 2 },
+{ "callm", 0x5c080000, 0xff880000, "", 4 },
+{ "camb", 0x90080000, 0xfc080000, "r,xOA,X", 4 },
+{ "camd", 0x90000002, 0xfc080002, "r,xOA,X", 4 },
+{ "camh", 0x90000001, 0xfc080001, "r,xOA,X", 4 },
+{ "camw", 0x90000000, 0xfc080000, "r.xOA,X", 4 },
+{ "car", 0x10000000, 0xfc0f0000, "r,R", 2 },
+{ "cd", 0xfc060000, 0xfc070000, "r,f", 4 },
+{ "cea", 0x000f0000, 0xffff0000, "", 2 },
+{ "ci", 0xc8050000, 0xfc7f0000, "r,I", 4 },
+{ "cmc", 0x040a0000, 0xfc7f0000, "r", 2 },
+{ "cmmb", 0x94080000, 0xfc080000, "r,xOA,X", 4 },
+{ "cmmd", 0x94000002, 0xfc080002, "r,xOA,X", 4 },
+{ "cmmh", 0x94000001, 0xfc080001, "r,xOA,X", 4 },
+{ "cmmw", 0x94000000, 0xfc080000, "r,xOA,X", 4 },
+{ "cmr", 0x14000000, 0xfc0f0000, "r,R", 2 },
+{ "daci", 0xfc7f0000, 0xfc7f8000, "r,I", 4 },
+{ "dae", 0x000e0000, 0xffff0000, "", 2 },
+{ "dai", 0xfc040000, 0xfc07ffff, "I", 4 },
+{ "dci", 0xfc6f0000, 0xfc7f8000, "r,I", 4 },
+{ "di", 0xfc010000, 0xfc07ffff, "I", 4 },
+{ "dvfd", 0xe4000002, 0xfc080002, "r,xOA,X", 4 },
+{ "dvfw", 0xe4000000, 0xfc080000, "r,xOA,X", 4 },
+{ "dvi", 0xc8040000, 0xfc7f0000, "r,I", 4 },
+{ "dvmb", 0xc4080000, 0xfc080000, "r,xOA,X", 4 },
+{ "dvmh", 0xc4000001, 0xfc080001, "r,xOA,X", 4 },
+{ "dvmw", 0xc4000000, 0xfc080000, "r,xOA,X", 4 },
+{ "dvr", 0x380a0000, 0xfc0f0000, "r,R", 2 },
+{ "dvrfd", 0x380c0000, 0xfc0f0000, "r,R", 4 },
+{ "dvrfw", 0x38040000, 0xfc0f0000, "r,xOA,X", 4 },
+{ "eae", 0x00080000, 0xffff0000, "", 2 },
+{ "eci", 0xfc670000, 0xfc7f8080, "r,I", 4 },
+{ "ecwcs", 0xfc4f0000, 0xfc7f8000, "", 4 },
+{ "ei", 0xfc000000, 0xfc07ffff, "I", 4 },
+{ "eomb", 0x8c080000, 0xfc080000, "r,xOA,X", 4 },
+{ "eomd", 0x8c000002, 0xfc080002, "r,xOA,X", 4 },
+{ "eomh", 0x8c000001, 0xfc080001, "r,xOA,X", 4 },
+{ "eomw", 0x8c000000, 0xfc080000, "r,xOA,X", 4 },
+{ "eor", 0x0c000000, 0xfc0f0000, "r,R", 2 },
+{ "eorm", 0x0c080000, 0xfc0f0000, "r,R", 2 },
+{ "es", 0x00040000, 0xfc7f0000, "r", 2 },
+{ "exm", 0xa8000000, 0xff880000, "xOA,X", 4 },
+{ "exr", 0xc8070000, 0xfc7f0000, "r", 2 },
+{ "exrr", 0xc8070002, 0xfc7f0002, "r", 2 },
+{ "fixd", 0x380d0000, 0xfc0f0000, "r,R", 2 },
+{ "fixw", 0x38050000, 0xfc0f0000, "r,R", 2 },
+{ "fltd", 0x380f0000, 0xfc0f0000, "r,R", 2 },
+{ "fltw", 0x38070000, 0xfc0f0000, "r,R", 2 },
+{ "grio", 0xfc3f0000, 0xfc7f8000, "r,I", 4 },
+{ "halt", 0x00000000, 0xffff0000, "", 2 },
+{ "hio", 0xfc370000, 0xfc7f8000, "r,I", 4 },
+{ "jwcs", 0xfa080000, 0xff880000, "xOA,X", 4 },
+{ "la", 0x50000000, 0xfc000000, "r,xOA,X", 4 },
+{ "labr", 0x58080000, 0xfc080000, "b,xOA,X", 4 },
+{ "lb", 0xac080000, 0xfc080000, "r,xOA,X", 4 },
+{ "lcs", 0x00030000, 0xfc7f0000, "r", 2 },
+{ "ld", 0xac000002, 0xfc080002, "r,xOA,X", 4 },
+{ "lear", 0x80000000, 0xfc080000, "r,xOA,X", 4 },
+{ "lf", 0xcc000000, 0xfc080000, "r,xOA,X", 4 },
+{ "lfbr", 0xcc080000, 0xfc080000, "b,xOA,X", 4 },
+{ "lh", 0xac000001, 0xfc080001, "r,xOA,X", 4 },
+{ "li", 0xc8000000, 0xfc7f0000, "r,I", 4 },
+{ "lmap", 0x2c070000, 0xfc7f0000, "r", 2 },
+{ "lmb", 0xb0080000, 0xfc080000, "r,xOA,X", 4 },
+{ "lmd", 0xb0000002, 0xfc080002, "r,xOA,X", 4 },
+{ "lmh", 0xb0000001, 0xfc080001, "r,xOA,X", 4 },
+{ "lmw", 0xb0000000, 0xfc080000, "r,xOA,X", 4 },
+{ "lnb", 0xb4080000, 0xfc080000, "r,xOA,X", 4 },
+{ "lnd", 0xb4000002, 0xfc080002, "r,xOA,X", 4 },
+{ "lnh", 0xb4000001, 0xfc080001, "r,xOA,X", 4 },
+{ "lnw", 0xb4000000, 0xfc080000, "r,xOA,X", 4 },
+{ "lpsd", 0xf9800000, 0xff880000, "r,xOA,X", 4 },
+{ "lpsdcm", 0xfa800000, 0xff880000, "r,xOA,X", 4 },
+{ "lw", 0xac000000, 0xfc080000, "r,xOA,X", 4 },
+{ "lwbr", 0x5c000000, 0xfc080000, "b,xOA,X", 4 },
+{ "mpfd", 0xe4080002, 0xfc080002, "r,xOA,X", 4 },
+{ "mpfw", 0xe4080000, 0xfc080000, "r,xOA,X", 4 },
+{ "mpi", 0xc8030000, 0xfc7f0000, "r,I", 4 },
+{ "mpmb", 0xc0080000, 0xfc080000, "r,xOA,X", 4 },
+{ "mpmh", 0xc0000001, 0xfc080001, "r,xOA,X", 4 },
+{ "mpmw", 0xc0000000, 0xfc080000, "r,xOA,X", 4 },
+{ "mpr", 0x38020000, 0xfc0f0000, "r,R", 2 },
+{ "mprfd", 0x380e0000, 0xfc0f0000, "r,R", 2 },
+{ "mprfw", 0x38060000, 0xfc0f0000, "r,R", 2 },
+{ "nop", 0x00020000, 0xffff0000, "", 2 },
+{ "ormb", 0x88080000, 0xfc080000, "r,xOA,X", 4 },
+{ "ormd", 0x88000002, 0xfc080002, "r,xOA,X", 4 },
+{ "ormh", 0x88000001, 0xfc080001, "r,xOA,X", 4 },
+{ "ormw", 0x88000000, 0xfc080000, "r,xOA,X", 4 },
+{ "orr", 0x08000000, 0xfc0f0000, "r,R", 2 },
+{ "orrm", 0x08080000, 0xfc0f0000, "r,R", 2 },
+{ "rdsts", 0x00090000, 0xfc7f0000, "r", 2 },
+{ "return", 0x280e0000, 0xfc7f0000, "", 2 },
+{ "ri", 0xfc020000, 0xfc07ffff, "I", 4 },
+{ "rnd", 0x00050000, 0xfc7f0000, "r", 2 },
+{ "rpswt", 0x040b0000, 0xfc7f0000, "r", 2 },
+{ "rschnl", 0xfc2f0000, 0xfc7f8000, "r,I", 4 },
+{ "rsctl", 0xfc470000, 0xfc7f8000, "r,I", 4 },
+{ "rwcs", 0x000b0000, 0xfc0f0000, "r,R", 2 },
+{ "sacz", 0x10080000, 0xfc0f0000, "r,R", 2 },
+{ "sbm", 0x98080000, 0xfc080000, "f,xOA,X", 4 },
+{ "sbr", 0x18000000, 0xfc0c0000, "r,f", 4 },
+{ "sea", 0x000d0000, 0xffff0000, "", 2 },
+{ "setcpu", 0x2c090000, 0xfc7f0000, "r", 2 },
+{ "sio", 0xfc170000, 0xfc7f8000, "r,I", 4 },
+{ "sipu", 0x000a0000, 0xffff0000, "", 2 },
+{ "sla", 0x1c400000, 0xfc600000, "r,S", 2 },
+{ "slad", 0x20400000, 0xfc600000, "r,S", 2 },
+{ "slc", 0x24400000, 0xfc600000, "r,S", 2 },
+{ "sll", 0x1c600000, 0xfc600000, "r,S", 2 },
+{ "slld", 0x20600000, 0xfc600000, "r,S", 2 },
+{ "smc", 0x04070000, 0xfc070000, "", 2 },
+{ "sra", 0x1c000000, 0xfc600000, "r,S", 2 },
+{ "srad", 0x20000000, 0xfc600000, "r,S", 2 },
+{ "src", 0x24000000, 0xfc600000, "r,S", 2 },
+{ "srl", 0x1c200000, 0xfc600000, "r,S", 2 },
+{ "srld", 0x20200000, 0xfc600000, "r,S", 2 },
+{ "stb", 0xd4080000, 0xfc080000, "r,xOA,X", 4 },
+{ "std", 0xd4000002, 0xfc080002, "r,xOA,X", 4 },
+{ "stf", 0xdc000000, 0xfc080000, "r,xOA,X", 4 },
+{ "stfbr", 0x54000000, 0xfc080000, "b,xOA,X", 4 },
+{ "sth", 0xd4000001, 0xfc080001, "r,xOA,X", 4 },
+{ "stmb", 0xd8080000, 0xfc080000, "r,xOA,X", 4 },
+{ "stmd", 0xd8000002, 0xfc080002, "r,xOA,X", 4 },
+{ "stmh", 0xd8000001, 0xfc080001, "r,xOA,X", 4 },
+{ "stmw", 0xd8000000, 0xfc080000, "r,xOA,X", 4 },
+{ "stpio", 0xfc270000, 0xfc7f8000, "r,I", 4 },
+{ "stw", 0xd4000000, 0xfc080000, "r,xOA,X", 4 },
+{ "stwbr", 0x54000000, 0xfc080000, "b,xOA,X", 4 },
+{ "suabr", 0x58000000, 0xfc080000, "b,xOA,X", 4 },
+{ "sufd", 0xe0000002, 0xfc080002, "r,xOA,X", 4 },
+{ "sufw", 0xe0000000, 0xfc080000, "r,xOA,X", 4 },
+{ "sui", 0xc8020000, 0xfc7f0000, "r,I", 4 },
+{ "sumb", 0xbc080000, 0xfc080000, "r,xOA,X", 4 },
+{ "sumd", 0xbc000002, 0xfc080002, "r,xOA,X", 4 },
+{ "sumh", 0xbc000001, 0xfc080001, "r,xOA,X", 4 },
+{ "sumw", 0xbc000000, 0xfc080000, "r,xOA,X", 4 },
+{ "sur", 0x3c000000, 0xfc0f0000, "r,R", 2 },
+{ "surfd", 0x380b0000, 0xfc0f0000, "r,xOA,X", 4 },
+{ "surfw", 0x38030000, 0xfc0f0000, "r,R", 2 },
+{ "surm", 0x3c080000, 0xfc0f0000, "r,R", 2 },
+{ "svc", 0xc8060000, 0xffff0000, "", 4 },
+{ "tbm", 0xa4080000, 0xfc080000, "f,xOA,X", 4 },
+{ "tbr", 0x180c0000, 0xfc0c0000, "r,f", 2 },
+{ "tbrr", 0x2c020000, 0xfc0f0000, "r,B", 2 },
+{ "tccr", 0x28040000, 0xfc7f0000, "", 2 },
+{ "td", 0xfc050000, 0xfc070000, "r,f", 4 },
+{ "tio", 0xfc1f0000, 0xfc7f8000, "r,I", 4 },
+{ "tmapr", 0x2c0a0000, 0xfc0f0000, "r,R", 2 },
+{ "tpcbr", 0x280c0000, 0xfc7f0000, "r", 2 },
+{ "trbr", 0x2c010000, 0xfc0f0000, "b,R", 2 },
+{ "trc", 0x2c030000, 0xfc0f0000, "r,R", 2 },
+{ "trcc", 0x28050000, 0xfc7f0000, "", 2 },
+{ "trcm", 0x2c0b0000, 0xfc0f0000, "r,R", 2 },
+{ "trn", 0x2c040000, 0xfc0f0000, "r,R", 2 },
+{ "trnm", 0x2c0c0000, 0xfc0f0000, "r,R", 2 },
+{ "trr", 0x2c000000, 0xfc0f0000, "r,R", 2 },
+{ "trrm", 0x2c080000, 0xfc0f0000, "r,R", 2 },
+{ "trsc", 0x2c0e0000, 0xfc0f0000, "r,R", 2 },
+{ "trsw", 0x28000000, 0xfc7f0000, "r", 2 },
+{ "tscr", 0x2c0f0000, 0xfc0f0000, "r,R", 2 },
+{ "uei", 0x00070000, 0xffff0000, "", 2 },
+{ "wait", 0x00010000, 0xffff0000, "", 2 },
+{ "wcwcs", 0xfc5f0000, 0xfc7f8000, "", 4 },
+{ "wwcs", 0x000c0000, 0xfc0f0000, "r,R", 2 },
+{ "xcbr", 0x28020000, 0xfc0f0000, "b,B", 2 },
+{ "xcr", 0x2c050000, 0xfc0f0000, "r,R", 2 },
+{ "xcrm", 0x2c0d0000, 0xfc0f0000, "r,R", 2 },
+{ "zbm", 0x9c080000, 0xfc080000, "f,xOA,X", 4 },
+{ "zbr", 0x18040000, 0xfc0c0000, "r,f", 2 },
+{ "zmb", 0xf8080000, 0xfc080000, "r,xOA,X", 4 },
+{ "zmd", 0xf8000002, 0xfc080002, "r,xOA,X", 4 },
+{ "zmh", 0xf8000001, 0xfc080001, "r,xOA,X", 4 },
+{ "zmw", 0xf8000000, 0xfc080000, "r,xOA,X", 4 },
+{ "zr", 0x0c000000, 0xfc0f0000, "r", 2 },
+};
+
+int numopcodes = sizeof(gld_opcodes) / sizeof(gld_opcodes[0]);
+
+struct gld_opcode *endop = gld_opcodes + sizeof(gld_opcodes) /
+ sizeof(gld_opcodes[0]);
diff --git a/contrib/binutils/include/opcode/ppc.h b/contrib/binutils/include/opcode/ppc.h
index f7db66f..d55caa7 100644
--- a/contrib/binutils/include/opcode/ppc.h
+++ b/contrib/binutils/include/opcode/ppc.h
@@ -1,5 +1,5 @@
/* ppc.h -- Header file for PowerPC opcode table
- Copyright 1994, 1995, 1999, 2000, 2001, 2002
+ Copyright 1994, 1995, 1999, 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support
@@ -59,53 +59,80 @@ extern const int powerpc_num_opcodes;
/* Values defined for the flags field of a struct powerpc_opcode. */
/* Opcode is defined for the PowerPC architecture. */
-#define PPC_OPCODE_PPC (01)
+#define PPC_OPCODE_PPC 1
/* Opcode is defined for the POWER (RS/6000) architecture. */
-#define PPC_OPCODE_POWER (02)
+#define PPC_OPCODE_POWER 2
/* Opcode is defined for the POWER2 (Rios 2) architecture. */
-#define PPC_OPCODE_POWER2 (04)
+#define PPC_OPCODE_POWER2 4
/* Opcode is only defined on 32 bit architectures. */
-#define PPC_OPCODE_32 (010)
+#define PPC_OPCODE_32 8
/* Opcode is only defined on 64 bit architectures. */
-#define PPC_OPCODE_64 (020)
+#define PPC_OPCODE_64 0x10
/* Opcode is supported by the Motorola PowerPC 601 processor. The 601
is assumed to support all PowerPC (PPC_OPCODE_PPC) instructions,
but it also supports many additional POWER instructions. */
-#define PPC_OPCODE_601 (040)
+#define PPC_OPCODE_601 0x20
/* Opcode is supported in both the Power and PowerPC architectures
(ie, compiler's -mcpu=common or assembler's -mcom). */
-#define PPC_OPCODE_COMMON (0100)
+#define PPC_OPCODE_COMMON 0x40
/* Opcode is supported for any Power or PowerPC platform (this is
for the assembler's -many option, and it eliminates duplicates). */
-#define PPC_OPCODE_ANY (0200)
+#define PPC_OPCODE_ANY 0x80
/* Opcode is supported as part of the 64-bit bridge. */
-#define PPC_OPCODE_64_BRIDGE (0400)
+#define PPC_OPCODE_64_BRIDGE 0x100
/* Opcode is supported by Altivec Vector Unit */
-#define PPC_OPCODE_ALTIVEC (01000)
+#define PPC_OPCODE_ALTIVEC 0x200
/* Opcode is supported by PowerPC 403 processor. */
-#define PPC_OPCODE_403 (02000)
+#define PPC_OPCODE_403 0x400
/* Opcode is supported by PowerPC BookE processor. */
-#define PPC_OPCODE_BOOKE (04000)
+#define PPC_OPCODE_BOOKE 0x800
/* Opcode is only supported by 64-bit PowerPC BookE processor. */
-#define PPC_OPCODE_BOOKE64 (010000)
+#define PPC_OPCODE_BOOKE64 0x1000
+
+/* Opcode is supported by PowerPC 440 processor. */
+#define PPC_OPCODE_440 0x2000
/* Opcode is only supported by Power4 architecture. */
-#define PPC_OPCODE_POWER4 (020000)
+#define PPC_OPCODE_POWER4 0x4000
/* Opcode isn't supported by Power4 architecture. */
-#define PPC_OPCODE_NOPOWER4 (040000)
+#define PPC_OPCODE_NOPOWER4 0x8000
+
+/* Opcode is only supported by POWERPC Classic architecture. */
+#define PPC_OPCODE_CLASSIC 0x10000
+
+/* Opcode is only supported by e500x2 Core. */
+#define PPC_OPCODE_SPE 0x20000
+
+/* Opcode is supported by e500x2 Integer select APU. */
+#define PPC_OPCODE_ISEL 0x40000
+
+/* Opcode is an e500 SPE floating point instruction. */
+#define PPC_OPCODE_EFS 0x80000
+
+/* Opcode is supported by branch locking APU. */
+#define PPC_OPCODE_BRLOCK 0x100000
+
+/* Opcode is supported by performance monitor APU. */
+#define PPC_OPCODE_PMR 0x200000
+
+/* Opcode is supported by cache locking APU. */
+#define PPC_OPCODE_CACHELCK 0x400000
+
+/* Opcode is supported by machine check APU. */
+#define PPC_OPCODE_RFMCI 0x800000
/* A macro to extract the major opcode from an instruction. */
#define PPC_OP(i) (((i) >> 26) & 0x3f)
@@ -124,7 +151,7 @@ struct powerpc_operand
operand value into an instruction, check this field.
If it is NULL, execute
- i |= (op & ((1 << o->bits) - 1)) << o->shift;
+ i |= (op & ((1 << o->bits) - 1)) << o->shift;
(i is the instruction which we are filling in, o is a pointer to
this structure, and op is the opcode value; this assumes twos
complement arithmetic).
@@ -136,15 +163,14 @@ struct powerpc_operand
string (the operand will be inserted in any case). If the
operand value is legal, *ERRMSG will be unchanged (most operands
can accept any value). */
- unsigned long (*insert) PARAMS ((unsigned long instruction, long op,
- int dialect,
- const char **errmsg));
+ unsigned long (*insert)
+ (unsigned long instruction, long op, int dialect, const char **errmsg);
/* Extraction function. This is used by the disassembler. To
extract this operand type from an instruction, check this field.
If it is NULL, compute
- op = ((i) >> o->shift) & ((1 << o->bits) - 1);
+ op = ((i) >> o->shift) & ((1 << o->bits) - 1);
if ((o->flags & PPC_OPERAND_SIGNED) != 0
&& (op & (1 << (o->bits - 1))) != 0)
op -= 1 << o->bits;
@@ -157,8 +183,7 @@ struct powerpc_operand
non-zero if this operand type can not actually be extracted from
this operand (i.e., the instruction does not match). If the
operand is valid, *INVALID will not be changed. */
- long (*extract) PARAMS ((unsigned long instruction, int dialect,
- int *invalid));
+ long (*extract) (unsigned long instruction, int dialect, int *invalid);
/* One bit syntax flags. */
unsigned long flags;
@@ -208,17 +233,20 @@ extern const struct powerpc_operand powerpc_operands[];
register names with a leading 'r'. */
#define PPC_OPERAND_GPR (040)
+/* Like PPC_OPERAND_GPR, but don't print a leading 'r' for r0. */
+#define PPC_OPERAND_GPR_0 (0100)
+
/* This operand names a floating point register. The disassembler
prints these with a leading 'f'. */
-#define PPC_OPERAND_FPR (0100)
+#define PPC_OPERAND_FPR (0200)
/* This operand is a relative branch displacement. The disassembler
prints these symbolically if possible. */
-#define PPC_OPERAND_RELATIVE (0200)
+#define PPC_OPERAND_RELATIVE (0400)
/* This operand is an absolute branch address. The disassembler
prints these symbolically if possible. */
-#define PPC_OPERAND_ABSOLUTE (0400)
+#define PPC_OPERAND_ABSOLUTE (01000)
/* This operand is optional, and is zero if omitted. This is used for
the optional BF and L fields in the comparison instructions. The
@@ -226,7 +254,7 @@ extern const struct powerpc_operand powerpc_operands[];
and the number of operands remaining for the opcode, and decide
whether this operand is present or not. The disassembler should
print this operand out only if it is not zero. */
-#define PPC_OPERAND_OPTIONAL (01000)
+#define PPC_OPERAND_OPTIONAL (02000)
/* This flag is only used with PPC_OPERAND_OPTIONAL. If this operand
is omitted, then for the next operand use this operand value plus
@@ -234,21 +262,24 @@ extern const struct powerpc_operand powerpc_operands[];
hack is needed because the Power rotate instructions can take
either 4 or 5 operands. The disassembler should print this operand
out regardless of the PPC_OPERAND_OPTIONAL field. */
-#define PPC_OPERAND_NEXT (02000)
+#define PPC_OPERAND_NEXT (04000)
/* This operand should be regarded as a negative number for the
purposes of overflow checking (i.e., the normal most negative
number is disallowed and one more than the normal most positive
number is allowed). This flag will only be set for a signed
operand. */
-#define PPC_OPERAND_NEGATIVE (04000)
+#define PPC_OPERAND_NEGATIVE (010000)
/* This operand names a vector unit register. The disassembler
prints these with a leading 'v'. */
-#define PPC_OPERAND_VR (010000)
+#define PPC_OPERAND_VR (020000)
/* This operand is for the DS field in a DS form instruction. */
-#define PPC_OPERAND_DS (020000)
+#define PPC_OPERAND_DS (040000)
+
+/* This operand is for the DQ field in a DQ form instruction. */
+#define PPC_OPERAND_DQ (0100000)
/* The POWER and PowerPC assemblers use a few macros. We keep them
with the operands table for simplicity. The macro table is an
diff --git a/contrib/binutils/include/opcode/s390.h b/contrib/binutils/include/opcode/s390.h
index 1a42be6..f582a4e 100644
--- a/contrib/binutils/include/opcode/s390.h
+++ b/contrib/binutils/include/opcode/s390.h
@@ -24,10 +24,18 @@
/* List of instruction sets variations. */
-enum s390_opcode_arch_val
+enum s390_opcode_mode_val
{
S390_OPCODE_ESA = 0,
- S390_OPCODE_ESAME
+ S390_OPCODE_ZARCH
+ };
+
+enum s390_opcode_cpu_val
+ {
+ S390_OPCODE_G5 = 0,
+ S390_OPCODE_G6,
+ S390_OPCODE_Z900,
+ S390_OPCODE_Z990
};
/* The opcode table is an array of struct s390_opcode. */
@@ -55,8 +63,11 @@ struct s390_opcode
appear in assembly code, and are terminated by a zero. */
unsigned char operands[6];
- /* Bitmask of architectures this opcode is available for. */
- unsigned int architecture;
+ /* Bitmask of execution modes this opcode is available for. */
+ unsigned int modes;
+
+ /* First cpu this opcode is available for. */
+ enum s390_opcode_cpu_val min_cpu;
};
/* The table itself is sorted by major opcode number, and is otherwise
diff --git a/contrib/binutils/include/opcode/sparc.h b/contrib/binutils/include/opcode/sparc.h
index c412923..c336493 100644
--- a/contrib/binutils/include/opcode/sparc.h
+++ b/contrib/binutils/include/opcode/sparc.h
@@ -1,6 +1,6 @@
/* Definitions for opcode table for the sparc.
- Copyright 1989, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 2000, 2002
- Free Software Foundation, Inc.
+ Copyright 1989, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 2000, 2002,
+ 2003 Free Software Foundation, Inc.
This file is part of GAS, the GNU Assembler, GDB, the GNU debugger, and
the GNU Binutils.
@@ -74,8 +74,7 @@ struct sparc_opcode_arch {
extern const struct sparc_opcode_arch sparc_opcode_archs[];
/* Given architecture name, look up it's sparc_opcode_arch_val value. */
-extern enum sparc_opcode_arch_val sparc_opcode_lookup_arch
- PARAMS ((const char *));
+extern enum sparc_opcode_arch_val sparc_opcode_lookup_arch (const char *);
/* Return the bitmask of supported architectures for ARCH. */
#define SPARC_OPCODE_SUPPORTED(ARCH) (sparc_opcode_archs[ARCH].supported)
@@ -223,14 +222,14 @@ The following chars are unused: (note: ,[] are used as punctuation)
extern const struct sparc_opcode sparc_opcodes[];
extern const int sparc_num_opcodes;
-extern int sparc_encode_asi PARAMS ((const char *));
-extern const char *sparc_decode_asi PARAMS ((int));
-extern int sparc_encode_membar PARAMS ((const char *));
-extern const char *sparc_decode_membar PARAMS ((int));
-extern int sparc_encode_prefetch PARAMS ((const char *));
-extern const char *sparc_decode_prefetch PARAMS ((int));
-extern int sparc_encode_sparclet_cpreg PARAMS ((const char *));
-extern const char *sparc_decode_sparclet_cpreg PARAMS ((int));
+extern int sparc_encode_asi (const char *);
+extern const char *sparc_decode_asi (int);
+extern int sparc_encode_membar (const char *);
+extern const char *sparc_decode_membar (int);
+extern int sparc_encode_prefetch (const char *);
+extern const char *sparc_decode_prefetch (int);
+extern int sparc_encode_sparclet_cpreg (const char *);
+extern const char *sparc_decode_sparclet_cpreg (int);
/*
* Local Variables:
diff --git a/contrib/binutils/include/partition.h b/contrib/binutils/include/partition.h
index 885a79b..5d3623f 100644
--- a/contrib/binutils/include/partition.h
+++ b/contrib/binutils/include/partition.h
@@ -78,4 +78,8 @@ extern void partition_print PARAMS((partition,
#define partition_find(partition__, element__) \
((partition__)->elements[(element__)].class_element)
+#ifdef __cplusplus
+}
+#endif /* __cplusplus */
+
#endif /* _PARTITION_H */
diff --git a/contrib/binutils/include/safe-ctype.h b/contrib/binutils/include/safe-ctype.h
index b2ad849..69a3f74 100644
--- a/contrib/binutils/include/safe-ctype.h
+++ b/contrib/binutils/include/safe-ctype.h
@@ -37,7 +37,24 @@ Boston, MA 02111-1307, USA. */
#ifdef isalpha
#error "safe-ctype.h and ctype.h may not be used simultaneously"
+#endif
+
+/* Determine host character set. */
+#define HOST_CHARSET_UNKNOWN 0
+#define HOST_CHARSET_ASCII 1
+#define HOST_CHARSET_EBCDIC 2
+
+#if '\n' == 0x0A && ' ' == 0x20 && '0' == 0x30 \
+ && 'A' == 0x41 && 'a' == 0x61 && '!' == 0x21
+# define HOST_CHARSET HOST_CHARSET_ASCII
#else
+# if '\n' == 0x15 && ' ' == 0x40 && '0' == 0xF0 \
+ && 'A' == 0xC1 && 'a' == 0x81 && '!' == 0x5A
+# define HOST_CHARSET HOST_CHARSET_EBCDIC
+# else
+# define HOST_CHARSET HOST_CHARSET_UNKNOWN
+# endif
+#endif
/* Categories. */
@@ -99,5 +116,4 @@ extern const unsigned char _sch_tolower[256];
#define TOUPPER(c) _sch_toupper[(c) & 0xff]
#define TOLOWER(c) _sch_tolower[(c) & 0xff]
-#endif /* no ctype.h */
#endif /* SAFE_CTYPE_H */
diff --git a/contrib/binutils/include/splay-tree.h b/contrib/binutils/include/splay-tree.h
index 23f7ac6..86707fc 100644
--- a/contrib/binutils/include/splay-tree.h
+++ b/contrib/binutils/include/splay-tree.h
@@ -36,6 +36,10 @@ extern "C" {
#include "ansidecl.h"
+#ifndef GTY
+#define GTY(X)
+#endif
+
/* Use typedefs for the key and data types to facilitate changing
these types, if necessary. These types should be sufficiently wide
that any pointer or scalar can be cast to these types, and then
@@ -65,7 +69,7 @@ typedef int (*splay_tree_foreach_fn) PARAMS((splay_tree_node, void*));
node structures. The first argument is the number of bytes needed;
the second is a data pointer the splay tree functions pass through
to the allocator. This function must never return zero. */
-typedef void *(*splay_tree_allocate_fn) PARAMS((int, void *));
+typedef PTR (*splay_tree_allocate_fn) PARAMS((int, void *));
/* The type of a function used to free memory allocated using the
corresponding splay_tree_allocate_fn. The first argument is the
@@ -74,24 +78,24 @@ typedef void *(*splay_tree_allocate_fn) PARAMS((int, void *));
typedef void (*splay_tree_deallocate_fn) PARAMS((void *, void *));
/* The nodes in the splay tree. */
-struct splay_tree_node_s
+struct splay_tree_node_s GTY(())
{
/* The key. */
- splay_tree_key key;
+ splay_tree_key GTY ((use_param1 (""))) key;
/* The value. */
- splay_tree_value value;
+ splay_tree_value GTY ((use_param2 (""))) value;
/* The left and right children, respectively. */
- splay_tree_node left;
- splay_tree_node right;
+ splay_tree_node GTY ((use_params (""))) left;
+ splay_tree_node GTY ((use_params (""))) right;
};
/* The splay tree itself. */
-typedef struct splay_tree_s
+struct splay_tree_s GTY(())
{
/* The root of the tree. */
- splay_tree_node root;
+ splay_tree_node GTY ((use_params (""))) root;
/* The comparision function. */
splay_tree_compare_fn comp;
@@ -105,9 +109,10 @@ typedef struct splay_tree_s
/* Allocate/free functions, and a data pointer to pass to them. */
splay_tree_allocate_fn allocate;
splay_tree_deallocate_fn deallocate;
- void *allocate_data;
+ PTR GTY((skip (""))) allocate_data;
-} *splay_tree;
+};
+typedef struct splay_tree_s *splay_tree;
extern splay_tree splay_tree_new PARAMS((splay_tree_compare_fn,
splay_tree_delete_key_fn,
diff --git a/contrib/binutils/install-sh b/contrib/binutils/install-sh
index e9de238..0ec27bc 100755
--- a/contrib/binutils/install-sh
+++ b/contrib/binutils/install-sh
@@ -1,19 +1,37 @@
#!/bin/sh
#
# install - install a program, script, or datafile
-# This comes from X11R5 (mit/util/scripts/install.sh).
#
-# Copyright 1991 by the Massachusetts Institute of Technology
+# This originates from X11R5 (mit/util/scripts/install.sh), which was
+# later released in X11R6 (xc/config/util/install.sh) with the
+# following copyright and license.
#
-# Permission to use, copy, modify, distribute, and sell this software and its
-# documentation for any purpose is hereby granted without fee, provided that
-# the above copyright notice appear in all copies and that both that
-# copyright notice and this permission notice appear in supporting
-# documentation, and that the name of M.I.T. not be used in advertising or
-# publicity pertaining to distribution of the software without specific,
-# written prior permission. M.I.T. makes no representations about the
-# suitability of this software for any purpose. It is provided "as is"
-# without express or implied warranty.
+# Copyright (C) 1994 X Consortium
+#
+# Permission is hereby granted, free of charge, to any person obtaining a copy
+# of this software and associated documentation files (the "Software"), to
+# deal in the Software without restriction, including without limitation the
+# rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
+# sell copies of the Software, and to permit persons to whom the Software is
+# furnished to do so, subject to the following conditions:
+#
+# The above copyright notice and this permission notice shall be included in
+# all copies or substantial portions of the Software.
+#
+# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+# X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
+# AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC-
+# TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+#
+# Except as contained in this notice, the name of the X Consortium shall not
+# be used in advertising or otherwise to promote the sale, use or other deal-
+# ings in this Software without prior written authorization from the X Consor-
+# tium.
+#
+#
+# FSF changes to this file are in the public domain.
#
# Calling this script install-sh is preferred over install.sh, to prevent
# `make' implicit rules from creating a file called install from it
@@ -56,7 +74,7 @@ dir_arg=""
while [ x"$1" != x ]; do
case $1 in
- -c) instcmd="$cpprog"
+ -c) instcmd=$cpprog
shift
continue;;
@@ -79,7 +97,7 @@ while [ x"$1" != x ]; do
shift
continue;;
- -s) stripcmd="$stripprog"
+ -s) stripcmd=$stripprog
shift
continue;;
@@ -106,128 +124,132 @@ done
if [ x"$src" = x ]
then
- echo "install: no input file specified"
+ echo "$0: no input file specified" >&2
exit 1
else
- true
+ :
fi
if [ x"$dir_arg" != x ]; then
dst=$src
src=""
-
- if [ -d $dst ]; then
+
+ if [ -d "$dst" ]; then
instcmd=:
chmodcmd=""
else
- instcmd=mkdir
+ instcmd=$mkdirprog
fi
else
# Waiting for this to be detected by the "$instcmd $src $dsttmp" command
-# might cause directories to be created, which would be especially bad
+# might cause directories to be created, which would be especially bad
# if $src (and thus $dsttmp) contains '*'.
- if [ -f $src -o -d $src ]
+ if [ -f "$src" ] || [ -d "$src" ]
then
- true
+ :
else
- echo "install: $src does not exist"
+ echo "$0: $src does not exist" >&2
exit 1
fi
-
+
if [ x"$dst" = x ]
then
- echo "install: no destination specified"
+ echo "$0: no destination specified" >&2
exit 1
else
- true
+ :
fi
# If destination is a directory, append the input filename; if your system
# does not like double slashes in filenames, you may need to add some logic
- if [ -d $dst ]
+ if [ -d "$dst" ]
then
- dst="$dst"/`basename $src`
+ dst=$dst/`basename "$src"`
else
- true
+ :
fi
fi
## this sed command emulates the dirname command
-dstdir=`echo $dst | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'`
+dstdir=`echo "$dst" | sed -e 's,[^/]*$,,;s,/$,,;s,^$,.,'`
# Make sure that the destination directory exists.
# this part is taken from Noah Friedman's mkinstalldirs script
# Skip lots of stat calls in the usual case.
if [ ! -d "$dstdir" ]; then
-defaultIFS='
-'
-IFS="${IFS-${defaultIFS}}"
+defaultIFS='
+ '
+IFS="${IFS-$defaultIFS}"
-oIFS="${IFS}"
+oIFS=$IFS
# Some sh's can't handle IFS=/ for some reason.
IFS='%'
-set - `echo ${dstdir} | sed -e 's@/@%@g' -e 's@^%@/@'`
-IFS="${oIFS}"
+set - `echo "$dstdir" | sed -e 's@/@%@g' -e 's@^%@/@'`
+IFS=$oIFS
pathcomp=''
while [ $# -ne 0 ] ; do
- pathcomp="${pathcomp}${1}"
+ pathcomp=$pathcomp$1
shift
- if [ ! -d "${pathcomp}" ] ;
+ if [ ! -d "$pathcomp" ] ;
then
- $mkdirprog "${pathcomp}"
+ $mkdirprog "$pathcomp"
else
- true
+ :
fi
- pathcomp="${pathcomp}/"
+ pathcomp=$pathcomp/
done
fi
if [ x"$dir_arg" != x ]
then
- $doit $instcmd $dst &&
+ $doit $instcmd "$dst" &&
- if [ x"$chowncmd" != x ]; then $doit $chowncmd $dst; else true ; fi &&
- if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dst; else true ; fi &&
- if [ x"$stripcmd" != x ]; then $doit $stripcmd $dst; else true ; fi &&
- if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dst; else true ; fi
+ if [ x"$chowncmd" != x ]; then $doit $chowncmd "$dst"; else : ; fi &&
+ if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd "$dst"; else : ; fi &&
+ if [ x"$stripcmd" != x ]; then $doit $stripcmd "$dst"; else : ; fi &&
+ if [ x"$chmodcmd" != x ]; then $doit $chmodcmd "$dst"; else : ; fi
else
# If we're going to rename the final executable, determine the name now.
- if [ x"$transformarg" = x ]
+ if [ x"$transformarg" = x ]
then
- dstfile=`basename $dst`
+ dstfile=`basename "$dst"`
else
- dstfile=`basename $dst $transformbasename |
+ dstfile=`basename "$dst" $transformbasename |
sed $transformarg`$transformbasename
fi
# don't allow the sed command to completely eliminate the filename
- if [ x"$dstfile" = x ]
+ if [ x"$dstfile" = x ]
then
- dstfile=`basename $dst`
+ dstfile=`basename "$dst"`
else
- true
+ :
fi
-# Make a temp file name in the proper directory.
+# Make a couple of temp file names in the proper directory.
dsttmp=$dstdir/#inst.$$#
+ rmtmp=$dstdir/#rm.$$#
-# Move or copy the file name to the temp name
+# Trap to clean up temp files at exit.
- $doit $instcmd $src $dsttmp &&
+ trap 'status=$?; rm -f "$dsttmp" "$rmtmp" && exit $status' 0
+ trap '(exit $?); exit' 1 2 13 15
- trap "rm -f ${dsttmp}" 0 &&
+# Move or copy the file name to the temp name
+
+ $doit $instcmd "$src" "$dsttmp" &&
# and set any options; do chmod last to preserve setuid bits
@@ -235,17 +257,38 @@ else
# ignore errors from any of these, just make sure not to ignore
# errors from the above "$doit $instcmd $src $dsttmp" command.
- if [ x"$chowncmd" != x ]; then $doit $chowncmd $dsttmp; else true;fi &&
- if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd $dsttmp; else true;fi &&
- if [ x"$stripcmd" != x ]; then $doit $stripcmd $dsttmp; else true;fi &&
- if [ x"$chmodcmd" != x ]; then $doit $chmodcmd $dsttmp; else true;fi &&
+ if [ x"$chowncmd" != x ]; then $doit $chowncmd "$dsttmp"; else :;fi &&
+ if [ x"$chgrpcmd" != x ]; then $doit $chgrpcmd "$dsttmp"; else :;fi &&
+ if [ x"$stripcmd" != x ]; then $doit $stripcmd "$dsttmp"; else :;fi &&
+ if [ x"$chmodcmd" != x ]; then $doit $chmodcmd "$dsttmp"; else :;fi &&
+
+# Now remove or move aside any old file at destination location. We try this
+# two ways since rm can't unlink itself on some systems and the destination
+# file might be busy for other reasons. In this case, the final cleanup
+# might fail but the new file should still install successfully.
+
+{
+ if [ -f "$dstdir/$dstfile" ]
+ then
+ $doit $rmcmd -f "$dstdir/$dstfile" 2>/dev/null ||
+ $doit $mvcmd -f "$dstdir/$dstfile" "$rmtmp" 2>/dev/null ||
+ {
+ echo "$0: cannot unlink or rename $dstdir/$dstfile" >&2
+ (exit 1); exit
+ }
+ else
+ :
+ fi
+} &&
# Now rename the file to the real destination.
- $doit $rmcmd -f $dstdir/$dstfile &&
- $doit $mvcmd $dsttmp $dstdir/$dstfile
+ $doit $mvcmd "$dsttmp" "$dstdir/$dstfile"
fi &&
+# The final little trick to "correctly" pass the exit status to the exit trap.
-exit 0
+{
+ (exit 0); exit
+}
diff --git a/contrib/binutils/ld/ChangeLog b/contrib/binutils/ld/ChangeLog
index 428de76..4b3c1f9 100644
--- a/contrib/binutils/ld/ChangeLog
+++ b/contrib/binutils/ld/ChangeLog
@@ -1,4802 +1,319 @@
-2002-11-27 David O'Brien <obrien@FreeBSD.org>
+2004-05-13 Joel Sherrill <joel@oarcorp.com>
- * configure.host: Fix generic FreeBSD configuration entry.
+ * configure.tgt (or32-*-rtems*): Switch to elf and
+ support versioned targets.
-2002-11-20 Alan Modra <amodra@bigpond.net.au>
+2004-05-13 Nick Clifton <nickc@redhat.com>
- * emulparams/elf64ppc.sh (DATA_ADDR): Don't define.
-
-2002-10-30 Daniel Jacobowitz <drow@mvista.com>
-
- * ld.1: Regenerated.
- * ldgram.c: Regenerated.
- * po/ld.pot: Regenerated.
-
-2002-10-29 Daniel Jacobowitz <drow@mvista.com>
-
- * emultempl/aix.em: Use include <> for generated headers.
- * emultempl/beos.em: Likewise.
- * emultempl/elf32.em: Likewise.
- * emultempl/pe.em: Likewise.
- * ldctor.c: Likewise.
- * ldexp.c: Likewise.
- * ldfile.c: Likewise.
- * ldlang.c: Likewise.
- * ldlex.c: Likewise.
- * ldlex.l: Likewise.
- * ldmain.c: Likewise.
- * ldmisc.c: Likewise.
- * ldwrite.c: Likewise.
- * lexsup.c: Likewise.
- * mri.c: Likewise.
- * pe-dll.c: Likewise.
-
-2002-10-28 Daniel Jacobowitz <drow@mvista.com>
-
- Merge from mainline:
- 2002-10-23 Jakub Jelinek <jakub@redhat.com>
- * emultempl/elf32.em (place_orphan): Don't put non-allocated .rel*
- sections into .rel{,a}.dyn.
-
- 2002-10-21 Danny Smith <dannysmith@users.sourceforeg.net>
- * scripttempl/pe.sc (__RUNTIME_PSEUDO_RELOC_LIST__,
- __RUNTIME_PSEUDO_RELOC_LIST_END__): Add only when relocating.
-
- 2002-10-16 Jakub Jelinek <jakub@redhat.com>
- * configure.tgt (s390x-*-linux*): Add elf_s390 emulation.
- (s390-*-linux*): Add elf64_s390 emulation if want64.
- * emulparams/elf64_sparc.sh (LIB_PATH): Update to match 2002-05-22
- genscript.sh changes.
- * emulparams/elf_x86_64.sh (LIB_PATH): Likewise.
- * emulparams/elf64_s390.sh (LIB_PATH): Set up native 64 bit dirs.
-
- 2002-10-10 Jakub Jelinek <jakub@redhat.com>
- * ldfile.c (ldfile_try_open_bfd): When searching skip linker scripts if
- they have OUTPUT_FORMAT not matching actual output format.
- * ldlang.c (lang_get_output_target): New function.
- (open_output): Use it.
- * ldlang.h (lang_get_output_target): New prototype.
-
- 2002-10-07 Ralf Habacker <Ralf.Habacker@freenet.de>
- * pe-dll.cc (autofilter_symbolprefixlist): Don't re-export
- auto-import symbols.
- (make_one): Create _nm_<symbol> for data only.
-
- 2002-10-10 Alan Modra <amodra@bigpond.net.au>
- * emultempl/elf32.em (output_rel_find): Prefer .rel script sections
- when orphan is .rel, .rela when orphan is .rela.
- (gld${EMULATION_NAME}_place_orphan): Handle combreloc .rel* case
- first. Remove outsecname var.
-
- 2002-09-30 Alan Modra <amodra@bigpond.net.au>
- * scripttempl/elfd30v.sc: Order reloc sections placing .plt last.
- * scripttempl/elfm68hc11.sc: Likewise.
- * scripttempl/elfm68hc12.sc: Likewise.
-
- * emultempl/elf32.em (output_rel_find): Always place orphan loadable
- reloc sections just before .rel.plt/.rela.plt.
- (gld${EMULATION_NAME}_place_orphan <.rel>): Remove combreloc code.
- Only put loadable reloc sections in hold_rel.
-
- 2002-09-29 H.J. Lu <hjl@gnu.org>
- * emulparams/elf32ppc.sh (OTHER_GOT_RELOC_SECTIONS): New.
-
- 2002-08-27 Egor Duda <deo@logos-m.ru>
- * scripttempl/pe.sc: Handle .rdata_runtime_pseudo_reloc sections.
- Add symbols for application to access them.
-
-2002-10-15 Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.c (load_symbols): Revert last change.
-
-2002-10-14 Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.c (load_symbols): Don't call bfd_link_add_symbols when
- just_syms_flag.
- (lang_reasonable_defaults): Don't compare against false.
- (size_input_section): Likewise.
- (lang_size_sections_1): Likewise.
- (lang_do_assignments): Likewise.
- (lang_add_output): Likewise.
-
-2002-10-11 Alan Modra <amodra@bigpond.net.au>
-
- * pe-dll.c (make_import_fixup_mark): Avoid type-punned pointer.
-
- * ldgram.y (memory_spec): Provide empty action.
- (section <NAME>): Likewise.
-
-2002-10-02 Alan Modra <amodra@bigpond.net.au>
-
- * emulparams/elf64ppc.sh (MAXPAGESIZE): Set to 0x10000.
-
-2002-09-25 Daniel Jacobowitz <drow@mvista.com>
-
- From "Anita Kulkarni" <AnitaK@kpit.com>
- * scripttempl/sh.sc: Handle .eh_frame* and .gcc_exc*
- sections.
-
-2002-09-25 Alan Modra <amodra@bigpond.net.au>
-
- * ldexp.c (fold_unary): New. Split out from exp_fold_tree.
- (fold_binary): Correct abs - non-abs case.
- (fold_trinary): New. Split out from exp_fold_tree.
-
-2002-09-24 Alan Modra <amodra@bigpond.net.au>
-
- * emulparams/elf64ppc.sh (DATA_ADDR): Define.
- * emulparams/elf64_aix.sh (DATA_ADDR): Don't use a fixed address
- for start of .data, instead align up to 256M boundary.
- * scripttempl/aix.sc: Likewise.
-
-2002-09-23 Daniel Jacobowitz <drow@mvista.com>
-
- Merge from mainline:
- 2002-09-22 Mark Elbrecht <snowball3@softhome.net>
- * scripttempl/i386go32.sc: Handle bss unique sections.
-
- 2002-09-11 Nick Clifton <nickc@redhat.com>
- * po/tr.po: Updated Turkish translation.
-
- 2002-08-28 Alan Modra <amodra@bigpond.net.au>
- * emultempl/aix.em (gld${EMULATION_NAME}_parse_args): Replace strtoll,
- strtoul and strtoull with bfd_scan_vma.
- (gld${EMULATION_NAME}_read_file): Likewise.
+ * po/fr.po: Updated French translation.
- 2002-08-07 Nick Clifton <nickc@redhat.com>
- * emultempl/armelf.em (arm_elf_before_allocation): Only search
- for an interworking bfd if there are input bfds.
+2004-05-05 Alexandre Oliva <aoliva@redhat.com>
- 2002-08-06 Alan Modra <amodra@bigpond.net.au>
- * emultempl/aix.em (gld*_before_parse): Set default arch. Reverts
- 2002-05-10 change.
+ * emulparams/elf32frvfd.sh (OUTPUT_FORMAT): Switch to new
+ elf32-frvfdpic.
- 2002-08-06 H.J. Lu <hjl@gnu.org>
- * ld.texinfo: Document --no-undefined-version.
+2004-04-29 Alan Modra <amodra@bigpond.net.au>
- * ldlang.c (lang_new_vers_pattern): Set the `symver' and
- `script.' fields to 0.
+ * pe-dll.c: Revert changes accidentally committed 2004-03-08.
+ (fill_edata): Correct pointer arithmetic.
- * ldmain.c (main): Initialize the allow_undefined_version to
- true.
+2004-04-21 Hans-Peter Nilsson <hp@axis.com>
- * lexsup.c (OPTION_NO_UNDEFINED_VERSION): New.
- (ld_options): Add --no-undefined-version.
- (parse_args): Support OPTION_NO_UNDEFINED_VERSION.
+ * NEWS: Mention change in DEFINED semantics.
- 2002-07-04 Bruno Haible <bruno@clisp.org>
- * emulparams/elf_i386_fbsd.sh: Set OUTPUT_FORMAT to
- elf32-i386-freebsd.
- * emulparams/elf64alpha_fbsd.sh: Set OUTPUT_FORMAT to
- elf64-alpha-freebsd.
+2004-04-20 Chris Demetriou <cgd@broadcom.com>
-2002-08-13 Alan Modra <amodra@bigpond.net.au>
+ * NEWS: Note that MIPS --embedded-relocs option is deprecated.
- * emulparams/elf32_dlx.sh (TARGET_PAGE_SIZE): Set to 1.
- (MAXPAGESIZE): Set to 1.
+2004-04-11 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
- * ld.h (ALIGN_N): Delete.
- * ldexp.h (align_n): Declare.
- * ldexp.c (align_n): New function.
- (fold_binary): Use align_n instead of ALIGN_N.
- (exp_fold_tree): Likewise.
- * ldlang.c (lang_size_sections_1): Likewise.
- (lang_one_common): Likewise.
- * ld.texinfo (ALIGN): Remove power of 2 restriction.
+ * configure.host: Remove mips*-dec-bsd* target.
+ * configure.tgt: Likewise.
-2002-07-23 Daniel Jacobowitz <drow@mvista.com>
+2004-04-09 Daniel Jacobowitz <drow@mvista.com>
Merge from mainline:
- 2002-07-14 H.J. Lu <hjl@gnu.org>
- * ld.texinfo: Document a .symver takes precedence over a
- version script.
-
-2002-07-25 Nick Clifton <nickc@redhat.com>
-
+ 2004-03-30 Nick Clifton <nickc@redhat.com>
* po/sv.po: Updated Swedish translation.
- * po/es.po: Updated Spanish translation.
- * po/fr.po: Updated French translation.
-
-2002-07-24 Nick Clifton <nickc@redhat.com>
-
- * po/sv.po: Updated Swedish translation.
- * po/es.po: Updated Spanish translation.
-
-2002-07-23 Daniel Jacobowitz <drow@mvista.com>
-
- * po/ld.pot: Regenerated.
-
-2002-07-23 Nick Clifton <nickc@redhat.com>
-
- * po/ld.po: Updated French translation.
-
-2002-07-20 Alan Modra <amodra@bigpond.net.au>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Don't
- bomb on /DISCARD/ input section.
- * emultempl/pe.em (gld_${EMULATION_NAME}_place_orphan): Likewise.
- * emultempl/mmo.em (mmo_place_orphan): Likewise.
-
-2002-07-19 Hans-Peter Nilsson <hp@bitrange.com>
-
- * emultempl/mmo.em (mmo_place_orphan): Handle case of no .text
- output section.
-
-2002-07-16 Nick Clifton <nickc@cambridge.redhat.com>
-
- * NEWS: Add 'Changes in 2.13'.
-
-2002-07-12 Alan Modra <amodra@bigpond.net.au>
-
- * emulparams/elf64ppc.sh (ARCH): Set to powerpc:common64.
- (COMMONPAGESIZE): Define.
-
-2002-07-09 Alan Modra <amodra@bigpond.net.au>
-
- * emulparams/hppanbsd.sh: Remark that hppaobsd.sh references this file.
-
-2002-07-09 Federico G. Schwindt <fgsch@olimpo.com.br>
-
- * configure.tgt: Add support for alpha-*-openbsd*, hppa-*-openbsd*,
- powerpc-*-openbsd* and sparc64-*-openbsd*.
- * Makefile.am (ALL_EMULATIONS): Add ehppaobsd.o.
- * Makefile.in: Regenerate.
- * emulparams/hppaobsd.sh: New file.
-
-2002-07-05 Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.c (print_wild_statement): Fix output formatting.
-
-2002-07-04 Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.c: (strip_excluded_output_sections): New function.
- (lang_process): Call it.
- (lang_size_sections_1): Revert 2002-06-10 change.
-
-2002-07-03 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am (check-DEJAGNU): Revert 2002-06-25 change.
- Run "make dep-am".
- * Makefile.in: Regenerate.
-
-2002-07-02 Alan Modra <amodra@bigpond.net.au>
-
- * ldfile.c (ldfile_try_open_bfd): Formatting.
-
- * ldmisc.c (demangle): Move so that it doesn't intrude between
- vfinfo comment and body. Add comment.
-
-2002-07-01 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * emulparams/vax.sh (OUTPUT_FORMAT): Use a.out-vax-bsd format.
-
-2002-07-01 Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.h (entry_sym): Make it a struct bfd_sym_chain.
- * ldlang.c (entry_sym): Likewise.
- (ldlang_undef_chain_list_type): Likewise.
- (lang_finish): Adjust references to entry_symbol.
- (lang_add_entry): Likewise.
- (lang_gc_sections): Use link_info.gc_sym_list.
- (lang_process): Set link_info.gc_sym_list.
- * ldlex.l: Include bfdlink.h.
- * ldmain.c (main): Init link_info.gc_sym_list.
- * emultempl/aix.em: Adjust references to entry_symbol.
- * emultempl/armcoff.em: Likewise.
- * emultempl/armelf.em: Likewise.
- * emultempl/pe.em: Likewise.
- * emultempl/ppc64elf.em (ppc_after_open): New function.
- (LDEMUL_AFTER_OPEN): Define.
- * emulparams/elf64ppc.sh: KEEP .opd sections.
-
-2002-06-29 Stephane Carrez <stcarrez@nerim.fr>
-
- * emulparams/m68hc12elfb.sh (EEPROM_MEMORY): Define.
- * emulparams/m68hc11elfb.sh (EEPROM_MEMORY): Define.
- * emulparams/m68hc11elf.sh (EEPROM_SIZE): Define.
- (EEPROM_START_ADDR): Define.
- (EEPROM_MEMORY): Define.
- * emulparams/m68hc12elf.sh: Likewise.
- * scripttempl/elfm68hc11.sc: Handle .eeprom section; handle .softregs
- section to put soft registers in .page0.
- * scripttempl/elfm68hc12.sc: Likewise but put soft registers in bss.
-
-2002-06-26 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * emulparams/hppa64linux.sh (OTHER_GOT_RELOC_SECTIONS): Add rela.opd
- section. Add ${RELOCATING-0}.
-
-Wed Jun 26 16:33:58 2002 J"orn Rennecke <joern.rennecke@superh.com>
-
- * emulparams/shelf.sh (STACK_ADDR): Don't define.
- (OTHER_SECTIONS): Define.
- * emulparams/shelf_nbsd.sh ((STACK_ADDR): Don't undef.
- (OTHER_SECTIONS): Undef.
-
-2002-06-26 Alan Modra <amodra@bigpond.net.au>
-
- * ldmisc.c (demangle): Restore dots stripped from sym name.
-
-2002-06-25 H.J. Lu <hjl@gnu.org>
-
- * Makefile.am (check-DEJAGNU): Set LC_ALL=C and export it.
- * Makefile.in: Regenerated.
-
-2002-06-20 Nick Clifton <nickc@cambridge.redhat.com>
-
- * ld.texinfo (Bug Reporting): Update text to suggest a limit on
- the size of attached object files, to allow make the object files
- available via FTP or HTTP and to mention that the mail will be
- sent to a mailing list.
-
-2002-06-20 Nathanael Nerode <neroden@twcny.rr.com>
-
- * ld/configure.host (romp): Drop support.
-
-2002-06-18 Chris Demetriou <cgd@broadcom.com>
-
- * emultempl/mipself.em (mips_elf${ELFSIZE}_check_sections): Check
- section flags for SEC_DATA, rather than for SEC_CODE being unset.
-
-2002-06-18 Chris Demetriou <cgd@broadcom.com>
-
- * emultempl/mipself.em (mips_elf${ELFSIZE}_check_sections): Fix
- format specifier used to print BFD name.
-
-2002-06-18 Dave Brolley <brolley@redhat.com>
-
- From Catherine Moore, Michael Meissner, Jim Blandy:
- * emulparams/elf32frv.sh: New file.
- * configure.tgt: Support frv-*-*.
- * Makefile.am (ALL_EMULATIONS): Add eelf32frv.o.
- (eelf32frv.c): New target.
-
-2002-06-17 Tom Rix <trix@redhat.com>
-
- * emultempl/elf32.em: gld*_get_script: Check for
- GENERATE_COMBRELOC_SCRIPT.
- * scripttempl/elfd10v.sc : Fix STACK and INSN.
- * emulparams/d10velf.sh : Fix TEXT_START_ADDR.
-
-Thu Jun 13 20:18:38 2002 J"orn Rennecke <joern.rennecke@superh.com>
-
- * configure.tgt: Add support for sh[1234]*le*-*-elf, sh[1234]*-*-elf.
-
-2002-06-12 H.J. Lu <hjl@gnu.org>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_try_needed): Return
- false if xvec doesn't match.
-
-2002-06-10 Richard Sandiford <rsandifo@redhat.com>
-
- * ldlang.c (lang_size_sections_1): Skip removed output sections.
-
-2002-06-08 Alan Modra <amodra@bigpond.net.au>
-
- * ldexp.c: Replace CONST with const.
- * ldfile.c: Likewise.
- * ldfile.h: Likewise.
- * ldlex.l: Likewise.
- * mri.c: Likewise.
- * pe-dll.h: Likewise.
-
-2002-06-07 Alan Modra <amodra@bigpond.net.au>
-
- * emultempl/ppc64elf.em (new_vers_pattern): Warning fix.
-
-2002-06-07 Charles Wilson <cwilson@ece.gatech.edu>
-
- * ld/ldmain.c (main): initialize link_info.pei386_auto_import
- to -1 == implicit enable.
- * ld/emultempl/pe.em (gld_${EMULATION_NAME}_before_parse):
- initialize link_info.pei386_auto_import to -1 == implicit
- enable.
- (gld_${EMULATION_NAME}_parse_args): When processing
- --enable-auto-import and --disable-auto-import options, use
- '1' and '0' instead of 'true' and 'false'.
- (pe_find_data_imports): Only issue message about auto-import
- when the feature is implicitly enabled. Downgrade message to
- informational instead of warning.
-
-2002-06-07 Alan Modra <amodra@bigpond.net.au>
-
- * scripttempl/elf.sc (.tbss): Fix mismatched parentheses/braces.
-
-2002-06-06 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * configure.host (hppa*64*-*-hpux11*): Define NATIVE_LIB_DIRS,
- HOSTING_CRT0 and HOSTING_LIBS.
-
-2002-06-05 J"orn Rennecke <joern.rennecke@superh.com>
-
- * configure.tgt (shle*-*-elf*, sh64le-*-elf*): New configurations.
-
-2002-06-05 Jason Thorpe <thorpej@wasabisystems.com>
-
- * emulparams/ns32knbsd.sh (EXECUTABLE_SYMBOLS): Set _DYNAMIC to 0.
- (NONPAGED_TEXT_START_ADDR): Set to 0x1000.
-
-2002-06-05 Alan Modra <amodra@bigpond.net.au>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Place
- SEC_EXCLUDE sections when doing a relocatable link.
-
-2002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
-
- * Makefile.am (ALL_EMULATIONS): Add eshelf32_nbsd.o,
- eshlelf32_nbsd.o, eshelf64_nbsd.o, and eshlelf64_nbsd.o.
- (eshelf32_nbsd.c, eshelf64_nbsd.c, eshlelf32_nbsd.c)
- (eshlelf64_nbsd.c): New rules.
- * Makefile.in: Regenerate.
- * configure.tgt (sh5le-*-netbsd*, sh5-*-netbsd*, sh64le-*-netbsd*)
- (sh64-*-netbsd*): New targets.
- * emulparams/shelf32_nbsd.sh: New file.
- * emulparams/shelf64_nbsd.sh: New file.
- * emulparams/shlelf32_nbsd.sh: New file.
- * emulparams/shlelf64_nbsd.sh: New file.
-
-2002-06-04 Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.c (section_already_linked): Call bfd_discard_group. Typo fix.
-
-2002-06-02 Marek Michalkiewicz <marekm@amelek.gda.pl>
-
- * scripttempl/avr.sc: Changes to support current GCC and avr-libc,
- C++ constructors/destructors, loosely based on the m68hc11 port.
-
-2002-05-31 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.in: Regenerate.
- * aclocal.m4: Regenerate.
- * config.in: Regenerate.
- * configure: Regenerate.
-
-2002-05-31 Graeme Peterson <gp@qnx.com>
-
- * Makefile.am (ALL_EMULATIONS): Add ei386nto.o.
- (ei386nto.c): Add rule.
- * Makefile.in: Regenerate.
- * configure.tgt: Add i[3456]86-*-nto-qnx*.
- * emulparams/i386nto.sh: New file.
-
-2002-05-29 Jason Thorpe <thorpej@wasabisystems.com>
-
- * NEWS: Add entry for VAX ELF support.
-
-2002-05-29 Matt Thomas <matt@3am-software.com>
- Jason Thorpe <thorpej@wasabisystems.com>
-
- * Makefile.am (ALL_EMULATIONS): Add eelf32vax.o and evaxnbsd.o.
- (eelf32vax.c)
- (evaxnbsd.c): New rules.
- * Makefile.in: Regenerate.
- * configure.tgt (vax-*-netbsdelf*)
- (vax-*-netbsdaout*)
- (vax-*-netbsd*): New targets.
- * emulparams/elf32vax.sh: New file.
- * emulparams/vaxnbsd.sh: New file.
-
-2002-05-29 Adam Nemet <anemet@lnxw.com>
-
- * emultempl/armelf.em (arm_elf_after_open): Don't determine
- bfd_for_interwork, instead add glue sections to each input bfd.
- (bfd_for_interwork): New global.
- (arm_elf_set_bfd_for_interworking): New function.
- (arm_elf_before_allocation): Use it.
-
-2002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
-
- * Makefile.am: Add DLX make target.
- * configure.tgt: Add DLX configuration.
- * Makefile.in: Regenerate.
- * emulparams/elf32_dlx.sh: New file
- * scripttempl/dlx.sc: New file
-
-2002-05-27 Per Lundberg <per@caleb.dnsalias.org>
-
- * Makefile.am (eelf_i386_chaos): Use elf_chaos.sc script.
- * Makefile.in: Regenerate.
- * emulparams/elf_chaos.sh: Use elf_chaos script.
- * scripttempl/elf_chaos.sc: New file.
-
-2002-05-27 Richard Sandiford <rsandifo@redhat.com>
-
- * ldlang.c (lang_size_sections_1): Move check for conflicting load
- addresses and regions from here...
- (lang_get_regions): ...to this new function.
- (lang_leave_output_section_statement): Use lang_get_regions.
- (lang_leave_overlay): Likewise.
- * mri.c (mri_draw_tree): Pass null as last argument to
- lang_leave_output_section_statement.
- * emultempl/elf32.em (gld*_place_orphan): Likewise.
- * emultempl/mmo.em (mmo_place_orphan): Likewise.
- * emultempl/pe.em (gld*_place_orphan): Likewise.
-
-2002-05-26 Jason Thorpe <thorpej@wasabisystems.com>
-
- * configure.tgt: Use ns32k-*-netbsd* instead of ns32k-pc532-netbsd*.
-
-2002-05-25 Kazu Hirata <kazu@cs.umass.edu>
-
- * ldemul.c: Fix formatting.
- * ldfile.c: Likewise.
- * pe-dll.c: Likewise.
- * pe-dll.h: Likewise.
-
-2002-05-25 Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.c (lang_process): Formatting, grammar.
-
- * ldlex.l: Use #include "" instead of <> for local header files.
-
-2002-05-24 TAMURA Kent <kent@netbsd.org>
-
- * configure.tgt: Add a target for i386-netbsdpe.
-
-2002-05-23 Jakub Jelinek <jakub@redhat.com>
-
- * scripttempl/elf.sc: Add .rel{,a}.t{bss,data}, .tdata and .tbss.
- * ldlang.c (lang_add_section): Set SEC_THREAD_LOCAL for
- output section if necessary. Handle .tbss.
- (lang_size_sections): Clear _raw_size for .tbss section
- (it allocates space in PT_TLS segment only).
- * ldwrite.c (build_link_order): Build link order for .tbss too.
-
-2002-05-23 Alan Modra <amodra@bigpond.net.au>
-
- * configure.in: Correct spelling of AC_PREREQ.
-2002-05-21 Danny Smith <dannysmith@users.sourceforge.net>
+ 2004-03-20 Alexandre Oliva <aoliva@redhat.com>
+ * emulparams/elf32frvfd.sh (MAXPAGESIZE): Change to 16Kb.
- * pe-dll.c (autofilter_liblist): Add more system libs excluded by
- default.
- (autofilter_objlist): Add crtbegin.o, crtend.o.
+ 2004-03-08 Danny Smith <dannysmith@users.sourceforge.net>
+ * pe-dll.c (pe_dll_generate_implib): Skip sections marked as
+ private when building implib.
-2002-05-21 Danny Smith <dannysmith@users.sourceforge.net>
+ 2004-03-01 Andreas Schwab <schwab@suse.de>
+ * ld.texinfo (Options): Fix example for --wrap.
- * emultempl/pe.em (OPTION_EXCLUDE_LIBS): Add new define.
- (longopts): Add new option --exclude-libs.
- (gld_${EMULATION_NAME}_list_options): Give quick help about it.
- (gld_${EMULATION_NAME}_parse_args): Use it.
- * pe-dll.h (pe_dll_add_excludes): Add second param to prototype.
- * pe-dll.c (exclude_list_struct): Add field type to distinguish symbols
- from whole archives.
- (pe_dll_add_excludes): Set excludes->type.
- (auto_export): Add new variable libname and set to archive basename if
- abfd. Use it when filtering default and user-specified libarary
- excludes. Let string "ALL" mean all libs when filtering user-specified
- libs.
- * ld.texinfo: Document --exclude-libs.
+ 2004-02-25 Danny Smith <dannysmith@users.sourceforge.net>
+ * pe-dll.c (fill_edata): Check that exported_symbol_sections is
+ not NULL.
-2002-05-22 Alan Modra <amodra@bigpond.net.au>
+ 2004-02-23 Ian Lance Taylor <ian@wasabisystems.com>
+ * ldlang.c (lang_check): Use %P, not %E, in error message.
- * ldemul.c (ldemul_new_vers_pattern): New function.
- * ldemul.h (ldemul_new_vers_pattern): Declare.
- (struct ld_emulation_xfer_struct): Add new_vers_pattern.
- * ldlang.c (lang_new_vers_pattern): Call ldemul_new_vers_pattern.
- * emultempl/ppc64elf.em (dotsyms): New static var.
- (gld${EMULATION_NAME}_new_vers_pattern): New function.
- (LDEMUL_NEW_VERS_PATTERN): Define.
- (PARSE_AND_LIST_PROLOGUE): Add OPTION_DOTSYMS, OPTION_NO_DOTSYMS.
- (PARSE_AND_LIST_LONGOPTS): Likewise.
- (PARSE_AND_LIST_ARGS_CASES): Handle them.
- * emultempl/aix.em (ld_${EMULATION_NAME}_emulation): Update
- initialiser.
- * emultempl/armcoff.em: Likewise.
- * emultempl/armelf_oabi.em: Likewise.
- * emultempl/beos.em: Likewise.
- * emultempl/elf32.em: Likewise.
- * emultempl/generic.em: Likewise.
- * emultempl/gld960.em: Likewise.
- * emultempl/gld960c.em: Likewise.
- * emultempl/linux.em: Likewise.
- * emultempl/lnk960.em: Likewise.
- * emultempl/m68kcoff.em: Likewise.
- * emultempl/mipsecoff.em: Likewise.
- * emultempl/pe.em: Likewise.
- * emultempl/sunos.em: Likewise.
- * emultempl/ticoff.em: Likewise.
- * emultempl/vanilla.em: Likewise.
+2004-04-08 Richard Sandiford <rsandifo@redhat.com>
-2002-05-22 Alan Modra <amodra@bigpond.net.au>
-
- * genscripts.sh (LIB_PATH): For native targets, concatenate $libdir
- and $NATIVE_LIB_DIRS. Add $tool_lib before other libs.
- (LIB_SEARCH_DIRS): No need to use "tr".
- (COMPILE_IN): Only set for native targets.
- * configure.host (NATIVE_LIB_DIRS): Specify all native search dirs
- here, rather than adding lib:/usr/lib:/usr/local/lib in genscripts.sh.
- * configure.tgt (powerpc*): Set tdir_*.
- (powerpcle*): Correct targ_extra_emuls.
- * emulparams/elf32ppc.sh (LIB_PATH): Set up native 64 bit dirs.
- * emulparams/elf64ppc.sh (LIB_PATH): Likewise.
-
-2002-05-22 Alan Modra <amodra@bigpond.net.au>
-
- * emultempl/pe.em (set_pe_subsystem): Don't set "cmdline" when
- calling lang_add_entry.
-
-2002-05-21 H.J. Lu (hjl@gnu.org)
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_parse_args): Handle
- "-z muldefs".
- (gld${EMULATION_NAME}_list_options): Add "-z muldefs".
-
- * ld.texinfo: Updated for --allow-multiple-definition and
- "-z muldefs".
-
- * ldmain.c (main): Initialize the allow_multiple_definition
- field to false.
-
- * lexsup.c (OPTION_ALLOW_MULTIPLE_DEFINITION): New.
- (ld_options): Add --allow-multiple-definition.
- (parse_args): Support OPTION_ALLOW_MULTIPLE_DEFINITION.
-
-2002-05-21 Jason Thorpe <thorpej@wasabisystems.com>
-
- * Makefile.am (ALL_EMULATIONS): Add earmelfb_nbsd.o.
- (earmelfb_nbsd.c): New rule.
- * Makefile.in: Regenerate.
- * configure.tgt (armeb-*-netbsdelf*): New target.
- (arm-*-netbsdelf*): Add armelfb_nbsd to targ_extra_emuls.
- (arm-*-netbsd*): Likewise.
- * emulparams/armelfb_nbsd.sh: New file.
-
-2002-05-18 Tom Rix <trix@redhat.com>
-
- * emultempl/aix.em (gld*_parse_args): Add -bnortl and -bnortllib
- support.
-
-2002-05-17 Marek Michalkiewicz <marekm@amelek.gda.pl>
-
- * Makefile.am: Add new emulations avr1, avr2, avr3, avr4, avr5.
- * Makefile.in: Regenerate.
- * configure.tgt (avr-*-*): Add avr[1-5] to targ_extra_emuls.
-
-2002-05-16 Marek Michalkiewicz <marekm@amelek.gda.pl>
-
- * emulparams/avr1.sh: New file.
- * emulparams/avr2.sh: New file.
- * emulparams/avr3.sh: New file.
- * emulparams/avr4.sh: New file.
- * emulparams/avr5.sh: New file.
- * scripttempl/avr.sc: New file.
-
-2002-05-15 Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.c (section_already_linked): Call bfd_link_just_syms.
- (lang_place_orphans): Abort if just_syms_flag.
-
-2002-05-10 Tom Rix <trix@redhat.com>
-
- * emultempl/aix.em: (gld*_set_output_arch): New function. Use
- architecture and machine information in the output bfd.
- (gld*_before_parse): Remove old arch and machine code.
- (choose_target): Rename to gld*_choose_target.
- (rtld): Change type to int.
- * ldfile.c (ldfile_try_open_bfd): Disable compatiblity check for
- objects in XCOFF archives.
- * ldfile.h: Update copyright date.
-
-2002-05-10 Jakub Jelinek <jakub@redhat.com>
-
- * ldmain.c (main): Enable -z combreloc by default.
-
-2002-05-07 Federico G. Schwindt <fgsch@olimpo.com.br>
-
- * Makefile.am: Honour DESTDIR.
- * Makefile.in: Regenerate.
-
-2002-05-07 Richard Sandiford <rsandifo@redhat.com>
-
- * ldlang.h (lang_output_section_statement_type): Add update_dot_tree.
- (lang_enter_overlay): Remove the last two parameters.
- (lang_leave_overlay): Take them here instead.
- * ldgram.y (memspec_at_opt): Set $$ to null if no region is given.
- (section): Pass LMA and crossref flag to lang_leave_overlay rather
- than lang_enter_overlay.
- * ldlang.c (lang_memory_region_lookup): Return null for null names.
- (lang_output_section_statement_lookup): Initialize update_dot_tree.
- (lang_size_sections_1): Evaluate it.
- (lang_leave_output_section_statement): Rework LMA lookup.
- (overlay_lma, overlay_nocrossrefs): Remove.
- (lang_enter_overlay): Remove LMA and crossref arguments.
- (lang_enter_overlay_section): Don't set the LMA here.
- (lang_leave_overlay): Take LMA and crossref arguments. Move the '.'
- assignment to the last section's update_dot_tree. Unconditionally
- use the load and run-time regions specified in the OVERLAY statement.
- Likewise the first section's LMA. Only set the other sections' LMAs
- when no load region is given.
-
-2002-05-06 Nick Clifton <nickc@redhat.com>
-
- * po/sv.po: New translation.
-
-2002-05-04 Alan Modra <amodra@bigpond.net.au>
-
- * emultempl/hppaelf.em (build_section_lists): New function.
- (gld${EMULATION_NAME}_finish): Call elf32_hppa_setup_section_lists
- and build_section_lists.
-
-2002-05-03 Kazu Hirata <kazu@cs.umass.edu>
-
- * ld.h: Fix formatting.
- * ldexp.c: Likewise.
- * ldfile.c: Likewise.
- * ldlang.c: Likewise.
- * ldmain.c: Likewise.
- * lexsup.c: Likewise.
- * pe-dll.c: Likewise.
-
-2002-05-02 Alan Modra <amodra@bigpond.net.au>
-
- * emultempl/ppc64elf.em (gld${EMULATION_NAME}_after_allocation):
- Adjust for ppc64_elf_set_toc change. #include libbfd.h.
- (build_section_lists): Do output_section tests here.
-
-2002-04-30 Tom Rix <trix@redhat.com>
-
- * emultempl/aix.em : (gld*_parse_arge): Formatting changes.
-
-2002-05-01 Alan Modra <amodra@bigpond.net.au>
-
- Long branch stubs, multiple stub sections.
- * emultempl/ppc64elf.em: Include ldctor.h.
- (stub_file): New var.
- (group_size): New var.
- (ppc_create_output_section_statements): New function.
- (struct hook_stub_info): New.
- (hook_in_stub): New function.
- (ppc_add_stub_section): New function.
- (ppc_layout_sections_again): New function.
- (build_section_lists): New function.
- (gld${EMULATION_NAME}_finish): Rewrite.
- (real_func): New var.
- (ppc_for_each_input_file_wrapper): New function.
- (ppc_lang_for_each_input_file): New function.
- (lang_for_each_input_file): Define.
- (PARSE_AND_LIST_PROLOGUE): Define.
- (PARSE_AND_LIST_LONGOPTS): Define.
- (PARSE_AND_LIST_OPTIONS): Define.
- (PARSE_AND_LIST_ARGS_CASES): Define.
- (LDEMUL_CREATE_OUTPUT_SECTION_STATEMENTS): Define.
-
-2002-04-30 Tom Rix <trix@redhat.com>
-
- * emultempl/aix.em (gld*_parse_arge, gld*_before_allocation): Add
- -blibpath, -bnolibpath support.
-
-2002-04-30 Mark Mitchell <mark@codesourcery.com>
-
- * Makefile.am (ALL_EMULATIONS): Add elf32ppcwindiss.o.
- (eelf32ppcwindiss.c): New target.
- * Makefile.in: Regenerated.
- * configure.tgt: Add support for powerpc-*-windiss.
- * emulparams/elf32ppcwindiss.sh: New file.
-
-2002-04-30 Richard Sandiford <rsandifo@redhat.com>
-
- * ldlang.c (print_assignment): Update print_dot for assignments to ".".
- * ldexp.c (exp_print_token): Add "infix_p" argument.
- (exp_print_tree): Update accordingly.
-
-2002-04-28 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am (mpw): New maintainer mode rule to make mpw-*.c files.
- * Makefile.in: Regenerate.
- * mpw-elfmips.c: Delete.
- * mpw-eppcmac.c: Delete.
- * mpw-esh.c: Delete.
- * mpw-idtmips.c: Delete.
-
-Wed Apr 17 19:23:14 2002 J"orn Rennecke <joern.rennecke@superh.com>
-
- * emulparams/shelf32.sh (MACHINE): Now sh5.
-
-2002-04-17 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * ldgram.y: Fix syntax warning.
-
-2002-04-11 Nick Clifton <nickc@cambridge.redhat.com>
-
- * emultempl/armelf.em (PARSE_AND_LIST_SHORTOPTS): Add 'n' in order
- to prevent "-n" from being taken as an abbreviation for
- "--no-pipeline-knowledge".
-
-2002-04-08 Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.c (lang_size_sections_1): Don't complain about
- SEC_NEVER_LOAD sections having no memory region specified.
-
- * ld.texinfo (Format Commands <OUTPUT_FORMAT>): Typo fix.
-
-2002-04-07 matthew green <mrg@redhat.com>
-
- * ld/configure.host (*-*-netbsd*): Add support for NetBSD/ELF.
-
-2002-04-04 Alan Modra <amodra@bigpond.net.au>
-
- * dep-in.sed: Cope with absolute paths.
- * Makefile.am (dep.sed): Subst TOPDIR and BFDDIR.
- Run "make dep-am".
- * Makefile.in: Regenerate.
-
-2002-04-04 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * emulparams/elf64btsmip.sh: n64 replaces .reginfo with .MIPS.options.
-
-2002-04-03 Jakub Jelinek <jakub@redhat.com>
-
- * ldexp.c (fold_binary) [DATA_SEGMENT_ALIGN]: If common page size
- is smaller than maximum, round dot up to common page boundary.
-
-2002-03-28 Alan Modra <amodra@bigpond.net.au>
-
- * configure.host: Set up for generic hosts first, then tweak as
- necessary in more specific targets.
- (HOSTING_LIBS): Include libgcc_eh.a if found.
-
-2002-03-23 Andreas Jaeger <aj@suse.de>
-
- * emulparams/elf_x86_64.sh (COMMONPAGESIZE): Set it.
-
-2002-03-21 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: Run "make dep-am".
- * Makefile.in: Regenerate.
-
-2002-03-21 Albert Chin-A-Young <china@thewrittenword.com>
-
- * genscripts.sh (LIB_SEARCH_DIRS): Quote path.
-
-2002-03-20 Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.c (ldlang_add_undef): If the output bfd has been opened,
- add the symbol to the linker hash table immediately.
- (lang_place_undefineds): Split symbol creation out..
- (insert_undefined): ..to here.
-
-2002-03-18 David O'Brien <obrien@FreeBSD.org>
-
- * emultempl/elf32.em: Use lbasename vs. basename to fix problem where
- the contents of the buffer returned from basename function will are
- getting overwritten while still being used.
-
-Mon Mar 18 17:38:39 CET 2002 Jan Hubicka <jh@suse.cz>
- Andreas Jaeger <aj@suse.de>
- Andreas Schwab <schwab@suse.de>
-
- * configure.tgt (x86_64-*-linux-gnu*): Configure i386 as native.
- * elf_x86_64.sh (ARCH): Set to i386:x86-64
- set libraries to default to lib64 paths.
-
-2002-03-18 Tom Rix <trix@redhat.com>
-
- * Makefile.am : Add eaix5ppc and eaix5rs6, AIX 5 support.
- * configure.tgt : Same.
- * emulparms/aix5ppc.sh : New file. For eaix5ppc.
- * emulparms/aix5rs6.sh : New file. For eaix5rs6.
- * emulparms/aixppc.sh : OUPUT_FORMAT_32BIT and OUTPUT_FORMAT_64BIT
- emulation parameters for better -b32, -b64 support.
- * emulparms/aixrs6.sh : Same.
- * emulparms/ppcmacos.sh : Same.
- * emultempl/aix.em (choose_target) : Use new emulation parameters
- OUTPUT_FORMAT_32BIT and OUTPUT_FORMAT_64BIT.
- * Makefile.in : Regenerate.
-
-2002-03-18 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/fr.po: Updated version.
-
-2002-03-18 Alan Modra <amodra@bigpond.net.au>
-
- * ldmain.c (main): Move .text readonly flag fudges from here..
- * ldlang.c (lang_process): ..to here.
-
-2002-03-14 Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.c (lang_check): Remove the word size check added in last
- change. Treat emitrelocations case as for relocatable links.
-
-2002-03-13 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/fr.po: Updated version.
-
-2002-03-13 Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.c (lang_check): Do relocatable link checks first, so that
- warn_mismatch can't override. Check compatible and word size too.
-
-2002-03-07 Daniel Jacobowitz <drow@mvista.com>
-
- * ld.texinfo: Wrap @menu in @ifnottex, not @ifinfo.
-
-2002-03-05 Jakub Jelinek <jakub@redhat.com>
-
- * scripttempl/elf.sc: Only use DATA_SEGMENT_END() together with
- DATA_SEGMENT_ALIGN.
-
-2002-03-04 H.J. Lu <hjl@gnu.org>
-
- * scripttempl/elf.sc: Put .preinit_array, .init_array and
- .fini_array in the data segment.
-
-2002-03-04 Alan Modra <amodra@bigpond.net.au>
-
- * scripttempl/elf.sc: Correct syntax errors in 2002-03-01 commit.
-
-2002-03-01 David Mosberger <davidm@hpl.hp.com>
-
- * scripttempl/elf.sc (SECTIONS): Add entries for .preinit_array,
- .init_array, and .fini_array.
-
-2002-02-20 Andreas Schwab <schwab@suse.de>
-
- * emulparams/elf64_ia64.sh (OTHER_READONLY_SECTIONS): Don't fold
- .IA64_unwind* in a relocatable link.
-
-2002-02-20 Nick Clifton <nickc@cambridge.redhat.com>
-
- * NEWS: Mark 2.12 branch.
-
-2002-02-19 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * emulparams/elf64_s390.sh (ARCH): Change to "s390:64-bit".
- * emulparams/elf_s390.sh (ARCH): Change to "s390:31-bit".
-
-2002-02-18 Tom Rix <trix@redhat.com>
-
- * emultempl/aix.em (gld*_parse_args): Add -brtl support.
- (gld*_before_allocation): Same.
- (gld*_create_output_section_statements): Generate
- __rtinit if run time linking. Add librtl.a to the link.
- (gld*_read_file): Clean.
-
-2002-02-18 Alan Modra <amodra@bigpond.net.au>
-
- * emulparams/elf64ppc.sh (OTHER_TEXT_SECTIONS): Define.
-
-2002-02-18 David O'Brien <obrien@FreeBSD.org>
-
- * Makefile.am: Add new files earmelf_fbsd, eelf32ppc_fbsd,
- eelf_i386_fbsd, eelf64_ia64_fbsd, eelf_x86_64_fbsd, eelf64_sparc_fbsd,
- and eelf64alpha_fbsd.
+ * emulparams/elf32bsmip.sh (EXTRA_EM_FILE): Define to irix.
+ * emulparams/elf64bmip.sh (EXTRA_EM_FILE): Likewise.
+ * emulparams/elf32bmipn32.sh (EXTRA_EM_FILE): Likewise.
+ * emultempl/irix.em: New file.
+ * Makefile.am (eelf32bsmip.c, eelf32bmipn32.c, eelf64bmip.c): Update
+ dependencies.
* Makefile.in: Regenerate.
- * configure.tgt(sparc64-*-freebsd, ia64-*-freebsd, i[3456]86-*-freebsd,
- x86_64-*-freebsd, arm-*-freebsd, alpha*-*-freebsd, powerpc-*-freebsd):
- use a FreeBSD-specific emulation rather than the psABI one.
- * emulparams/elf_fbsd.sh (ELF_INTERPRETER_NAME): Set appropriate value
- for all FreeBSD ELF systems.
- * emulparams/armelf_fbsd.sh: Bridge elf_fbsd.sh and the "native" psABI
- emulation.
- * emulparams/elf32ppc_fbsd.sh: Likewise.
- * emulparams/elf64_ia64_fbsd.sh: Likewise.
- * emulparams/elf64_sparc_fbsd.sh: Likewise.
- * emulparams/elf64alpha_fbsd.sh: Likewise.
- * emulparams/elf_i386_fbsd.sh: Likewise.
- * emulparams/elf_x86_64_fbsd.sh: Likewise.
-
-2002-02-18 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/tr.po: Updated version.
-
-2002-02-18 Alan Modra <amodra@bigpond.net.au>
-
- * ld.texinfo (Output Section Fill): Fix amateur texinfo.
- (FILL): Likewise.
-
-2002-02-17 Hans-Peter Nilsson <hp@bitrange.com>
-
- * emultempl/mmo.em (mmo_after_open): Don't call
- _bfd_mmix_check_all_relocs when producing ELF output.
-
-2002-02-15 Richard Henderson <rth@redhat.com>
-
- * emulparams/elf64alpha.sh (NOP): Adjust for big-endian
- definition. Emit a unop+nop pair.
-
-2002-02-15 Hans-Peter Nilsson <hp@bitrange.com>
- * emultempl/mmix-elfnmmo.em (mmix_after_allocation): Also check
- for presence of .MMIX.reg_contents.linker_allocated before early
- exit.
+2004-04-08 Alan Modra <amodra@bigpond.net.au>
- * NEWS: Mention support for MMIX.
-
-2002-02-15 Alan Modra <amodra@bigpond.net.au>
-
- Support arbitrary length fill patterns.
- * ld.texinfo (Output Section Fill): Describe fill expressions.
- (FILL): Refer to the above.
- * ldexp.h (etree_value_type): Add "str" field.
- (union etree_union): Add "str" to "value" struct.
- (exp_bigintop): Declare.
- (exp_get_fill): Declare.
- * ldexp.c: Include "safe-ctype.h".
- (exp_intop): Set value.str to NULL.
- (exp_bigintop): New function.
- (new_rel): Pass in "str", and set new.str from it.
- (new_rel_from_section): Set new.str to NULL.
- (fold_name): Adjust calls to new_rel.
- (exp_fold_tree): Likewise.
- (exp_get_fill): New function.
- * ldgram.y (struct big_int bigint, fill_type *fill): New.
- (INT): Returns a "bigint". Adjust all code handling INTs.
- (fill_opt): Returns a "fill".
- (fill_exp): Split out of fill_opt, use for FILL.
- * ldlang.h (struct _fill_type): New.
- (fill_type): Move typedef to ldexp.h.
- (lang_output_section_statement_type): "fill" is now a pointer.
- (lang_fill_statement_type): Likewise.
- (lang_padding_statement_type): Likewise.
- (lang_add_fill): Now takes a "fill_type *" param.
- (lang_leave_output_section_statement): Likewise.
- (lang_do_assignments): Likewise.
- (lang_size_sections): Likewise.
- (lang_leave_overlay_section): Likewise.
- (lang_leave_overlay): Likewise.
- * ldlang.c: Include ldgram.h after ldexp.h.
- (lang_output_section_statement_lookup): Adjust for fill_type change.
- (print_fill_statement): Likewise.
- (print_padding_statement): Likewise.
- (insert_pad): Now takes a "fill_type *" arg.
- (size_input_section): Likewise.
- (lang_size_sections_1): Likewise.
- (lang_size_sections): Likewise.
- (lang_do_assignments): Likewise.
- (lang_add_fill): Likewise.
- (lang_leave_output_section_statement): Likewise.
- (lang_leave_overlay_section): Likewise.
- (lang_leave_overlay): Likewise.
- Adjust all callers of the above function.
- * ldlex.l: Include ldgram.h after ldexp.h. Allow hex numbers
- starting with "0X" as well as "0x". Return bigint.str for hex
- numbers starting with "0x" or "0X", zero bigint.str otherwise.
- Always use base 16 for numbers starting with "$".
- * ldmain.c: Include ldgram.h after ldexp.h.
- * ldwrite.c (build_link_order): Use bfd_data_link_order in place
- of bfd_fill_link_order.
- * pe-dll.c: Adjust lang_do_assignments calls.
- * emultempl/elf32.em: Likewise.
+ Apply from mainline.
+ 2004-03-27 Alan Modra <amodra@bigpond.net.au>
+ * emultempl/elf32.em: Update new bfd_elf_discard_info name.
* emultempl/hppaelf.em: Likewise.
* emultempl/ppc64elf.em: Likewise.
- * emultempl/beos.em: Include ldgram.h after ldexp.h, adjust
- lang_add_assignment call.
- * emultempl/pe.em: Likewise.
-
-2002-02-14 Phil Edwards <pme@gcc.gnu.org>
-
- * ld.texinfo (VERSION scripts): Symbol names are globbing patterns.
- * ldgram.y (lang_new_vers_regex): Rename to lang_new_vers_pattern;
- the pattern in question is not a regexp.
- * ldlang.c: Likewise.
- * ldlang.h: Likewise.
- * ldlex.l (V_IDENTIFIER): Allow '[', ']', '-', '!', and '^' also.
-
-2002-02-12 Jakub Jelinek <jakub@redhat.com>
-
- * ldlex.l (DATA_SEGMENT_ALIGN, DATA_SEGMENT_END): New tokens.
- * ldgram.y (DATA_SEGMENT_ALIGN, DATA_SEGMENT_END): New tokens.
- (exp): Add DATA_SEGMENT_ALIGN (exp, exp) and DATA_SEGMENT_END (exp).
- * ldexp.c (exp_data_seg): New variable.
- (exp_print_token): Handle DATA_SEGMENT_ALIGN and DATA_SEGMENT_END.
- (fold_binary): Handle DATA_SEGMENT_ALIGN.
- (exp_fold_tree): Handle DATA_SEGMENT_END.
- Pass allocation_done when recursing instead of hardcoding
- lang_allocating_phase_enum.
- * ldexp.h (exp_data_seg): New.
- * ldlang.c (lang_size_sections_1): Renamed from lang_size_sections.
- (lang_size_sections): New.
- * ld.texinfo (DATA_SEGMENT_ALIGN, DATA_SEGMENT_END): Document.
- * scripttempl/elf.sc: Use DATA_SEGMENT_ALIGN and DATA_SEGMENT_END
- if COMMONPAGESIZE is defined.
- * emulparams/elf_i386.sh (COMMONPAGESIZE): Set to 4K.
- * emulparams/elf32_sparc.sh (COMMONPAGESIZE): Set to 8K.
- * emulparams/elf64_sparc.sh (COMMONPAGESIZE): Set to 8K.
- * emulparams/elf64alpha.sh (COMMONPAGESIZE): Set to 8K.
- * emulparams/elf64_ia64.sh (COMMONPAGESIZE): Set to 16K for shared
- libraries only.
-
-2002-02-11 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.in: Regenerate.
-
-2002-02-10 Daniel Jacobowitz <drow@mvista.com>
-
- * lexsup.c: Remove strtoul declaration.
-
-2002-02-10 Daniel Jacobowitz <drow@mvista.com>
-
- * ldmain.c: Add prototype for main ().
- * lexsup.c: Guard declaration of strtoul with HAVE_STDLIB_H.
- * emultempl/lnk960.em (lnk960_choose_target): Function should
- take two arguments.
-
-2002-02-10 Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.c (entry_section): New initialised variable.
- (lang_finish): Use it.
- * ldlang.h (entry_section): Declare.
- * emultempl/ppc64elf.em (gld${EMULATION_NAME}_finish): Set
- entry_section to ".opd".
-
-2002-02-09 Chris Demetriou <cgd@broadcom.com>
-
- * ld.texinfo (Options): Add back in -nostdlib documentation,
- which had been inadvertently removed.
-
-2002-02-09 Hans-Peter Nilsson <hp@bitrange.com>
-
- * emultempl/mmix-elfnmmo.em (mmix_after_allocation): Adjust
- register section vma to a sane value after emitting error. Make
- fatal conditions cause program exit when emitting message.
-
-2002-02-08 Ivan Guzvinec <ivang@opencores.org>
-
- * configure.tgt: Add or32-*-rtems target.
-
-2002-02-08 Alexandre Oliva <aoliva@redhat.com>
-
- Contribute sh64-elf.
- 2002-01-24 Alexandre Oliva <aoliva@redhat.com>
- * emulparams/shelf32.sh (STACK_ADDR): Define as formerly defined
- in OTHER_RELOCATABLE_SECTIONS.
- 2002-01-18 Alexandre Oliva <aoliva@redhat.com>
- * emulparams/shelf32.sh (STACK_ADDR): Define.
- (OTHER_RELOCATABLE_SECTIONS): Renamed to...
- (OTHER_SECTIONS): this. Removed stack settings.
- * emulparams/shelf64.sh (OTHER_RELOCATABLE_SECTIONS): Do not set.
- (OTHER_SECTIONS): Reset after sourcing shelf32.sh.
- 2001-03-12 DJ Delorie <dj@redhat.com>
- * emultempl/sh64elf.em (sh64_elf_$_before_allocation): Disable
- relaxing if any shmedia or mixed sections are found.
- 2001-03-07 DJ Delorie <dj@redhat.com>
- * emultempl/sh64elf.em (sh64_elf_before_allocation): Pass f to
- einfo. Gracefully decline to output to non-elf formats.
- 2001-03-06 Hans-Peter Nilsson <hpn@redhat.com>
- * emulparams/shelf64.sh (OTHER_RELOCATING_SECTIONS) <.stack>:
- Default to _end aligned to next multiple of 0x40000, plus 0x40000.
- * emulparams/shelf32.sh: Ditto.
- 2001-01-14 Hans-Peter Nilsson <hpn@cygnus.com>
- * emulparams/shelf32.sh (OTHER_RELOCATING_SECTIONS): Tweak
- comment.
- 2001-01-10 Ben Elliston <bje@redhat.com>
- * emulparams/shelf32.sh (OTHER_RELOCATING_SECTIONS): Avoid
- non-portable shell constructs. From Hans-Peter Nilsson.
- 2001-01-09 Hans-Peter Nilsson <hpn@cygnus.com>
- * emulparams/shelf64.sh (EXTRA_EM_FILE): Define empty.
- * Makefile.am (eshelf64.c, eshlelf64.c, eshlelf32.c): Adjust
- dependencies to the shell script include chain.
- * Makefile.in: Regenerate.
- 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
- * emultempl/sh64elf.em: Update and tweak comments.
- (sh64_elf_${EMULATION_NAME}_after_allocation): Always allocate and
- make a .cranges section SEC_IN_MEMORY.
- 2000-12-30 Hans-Peter Nilsson <hpn@cygnus.com>
- * emultempl/sh64elf.em
- (sh64_elf_${EMULATION_NAME}_before_allocation): Don't stop when
- .cranges section found to be necessary; continue and set stored
- section contents flags for sections with non-mixed contents.
- Use a struct sh64_section_data container and sh64_elf_section_data
- to store contents-type flags.
- Remove unused update of "isec".
- (sh64_elf_${EMULATION_NAME}_after_allocation): Only process
- sections marked SHF_SH5_ISA32_MIXED. Use sh64_elf_section_data to
- access contents-type flags. Assert that the associated container
- is initialized. Use that container, not elf_gp_size, to hold size
- of linker-generated cranges contents.
- 2000-12-18 Hans-Peter Nilsson <hpn@cygnus.com>
- * emultempl/sh64elf.em
- (sh64_elf_${EMULATION_NAME}_before_allocation): Exit early if
- there's already a .cranges section. When section flag difference
- is found, don't NULL-check cranges a second time. Tweak comments.
- (sh64_elf_${EMULATION_NAME}_after_allocation): Use size after
- merging, not max size, as size of ld-generated .cranges contents.
- Don't set ELF section flags in output section. When checking for
- needed .cranges descriptors, don't use a variable; compare
- incoming ELF section flags directly to SHF_SH5_ISA32_MIXED. Tweak
- comments.
- 2000-12-18 Hans-Peter Nilsson <hpn@cygnus.com>
- * emultempl/sh64elf.em: New file.
- * Makefile.am (eshelf32.c, eshlelf32.c): Adjust dependencies.
- * Makefile.in: Regenerate.
- * emulparams/shelf32.sh (OUTPUT_FORMAT): Only set if not set.
- (OTHER_RELOCATING_SECTIONS): Ditto.
- (EXTRA_EM_FILE): New, set to sh64elf if not set.
- * emulparams/shlelf32.sh: Stub out all settings except
- OUTPUT_FORMAT. Source shelf32.sh.
- * emulparams/shelf64.sh: Similar, but also keep ELF_SIZE and
- OTHER_RELOCATING_SECTIONS.
- (OTHER_RELOCATING_SECTIONS): Remove .cranges.
- * emulparams/shlelf64.sh: Stub out all settings except
- OUTPUT_FORMAT. Source shelf64.sh.
- 2000-12-15 Hans-Peter Nilsson <hpn@cygnus.com>
- * emulparams/shelf64.sh (OTHER_RELOCATING_SECTIONS): Include
- .cranges section.
- (DATA_START_SYMBOLS): Define, provide ___data.
- (OTHER_READONLY_SYMBOLS): Define, provide ___rodata and align to 8
- for consecutive .data section.
- (OTHER_GOT_SECTIONS): Define, align to 8 for consecutive .bss
- section after .data section.
- * emulparams/shlelf64.sh: Ditto.
- * emulparams/shelf32.sh: Ditto.
- (ALIGNMENT): Define to 8.
- * emulparams/shelf32.sh: Ditto.
- 2000-12-12 Hans-Peter Nilsson <hpn@cygnus.com>
- * configure.tgt (sh64-*-elf*): Assign targ_extra_libpath to get
- built-in linker scripts.
- 2000-11-30 Hans-Peter Nilsson <hpn@cygnus.com>
- * emulparams/shlelf64.sh: New.
- * emulparams/shelf64.sh: New.
- * configure.tgt (sh64-*-elf*): Add shelf64 and shlelf64 to
- targ_extra_emuls.
- * Makefile.am: Add support for shlelf64 and shelf64.
- * Makefile.in: Regenerate.
- 2000-11-29 Hans-Peter Nilsson <hpn@cygnus.com>
- * configure.tgt (sh64-*-elf*): Add shelf as default.
- Add shlelf to targ_extra_emuls.
- 2000-11-24 Hans-Peter Nilsson <hpn@cygnus.com>
- * emulparams/shelf32.sh: New file.
- * emulparams/shlelf32.sh: New file.
- * Makefile.am: Add support for shlelf32 and shelf32.
- * configure.tgt: Map sh64-*-elf* to shlelf32 and shelf32.
- * Makefile.in: Regenerate.
-
-2002-02-05 Hans-Peter Nilsson <hp@axis.com>
-
- * ldlang.c (lang_reset_memory_regions): Rename from
- reset_memory_regions. Change all callers. Make public.
- * ldlang.h (lang_reset_memory_regions): Prototype.
- * emultempl/elf32.em (gld${EMULATION_NAME}_finish): Call
- lang_reset_memory_regions before lang_size_sections.
- * emultempl/hppaelf.em (hppaelf_layout_sections_again): Likewise.
- * emultempl/ppc64elf.em (gld${EMULATION_NAME}_finish): Likewise.
-
-2002-02-04 Hans-Peter Nilsson <hp@bitrange.com>
-
- * emultempl/mmix-elfnmmo.em (mmix_after_allocation): Use signed
- arithmetic when checking for too many global registers.
-
-2002-02-02 Jason Thorpe <thorpej@wasabisystems.com>
-
- * Makefile.am (ALL_EMULATIONS): Add ehppanbsd.o.
- (ehppanbsd.c): New rule.
- * Makefile.in: Regenerate.
- * configure.tgt (hppa*-*-netbsd*): New target.
- * emulparams/hppalinux.sh: Add comment to check other files
- that source this file it is modified, and list which
- files that do.
- * emulparams/hppanbsd.sh: New file.
-
-2002-02-01 Geoffrey Keating <geoffk@redhat.com>
-
- * scripttempl/xstormy16.sc: Don't allocate extra space for the
- stack.
-
-2002-02-01 Hans-Peter Nilsson <hp@bitrange.com>
-
- Support on-demand global register allocation from
- R_MMIX_BASE_PLUS_OFFSET relocs.
- * emultempl/mmix-elfnmmo.em (mmix_after_allocation): Rename from
- mmix_set_reg_section_vma. Call
- _bfd_mmix_finalize_linker_allocated_gregs.
- (mmix_before_allocation): New function.
- (LDEMUL_AFTER_ALLOCATION): Set to mmix_after_allocation.
- (LDEMUL_BEFORE_ALLOCATION): Define to mmix_before_allocation.
- * scripttempl/mmo.sc (.text): Mark .init, .fini as KEEP.
- (.MMIX.reg_contents): Add .MMIX.reg_contents.linker_allocated
- before .MMIX.reg_contents.
- * emultempl/mmo.em (gldmmo_before_allocation): Define to default.
- (mmo_after_open): New function.
- (LDEMUL_AFTER_OPEN): Define to mmo_after_open.
- * emulparams/elf64mmix.sh (OTHER_SECTIONS): Tweak formatting. Add
- .MMIX.reg_contents.linker_allocated before .MMIX.reg_contents.
-
-2002-01-31 Ivan Guzvinec <ivang@opencores.org>
-
- * emulparams/or32.sh: New file.
- * emulparams/or32elf.sh: New file.
- * scripttempl/or32.sc: New file.
- * configure.tgt : Add support for or32.
- * configure: Regenerate
- * Makefile.am: Add support for or32.
- * Makefile.in: Regenerate.
- * NEWS: Mention support for or32.
- * po/ld.pot: Regenerate.
-
-2002-01-29 Chris Demetriou <cgd@broadcom.com>
- Mitch Lichtenberg <mpl@broadcom.com>
-
- * emulparams/elf32bmip.sh (EXTRA_EM_FILE): Define to be mipself.
- * emultempl/mipself.em: New file to handle MIPS ELF embedded
- reloc creation (ld --embedded-relocs).
-
-2002-01-27 Daniel Jacobowitz <drow@mvista.com>
-
- * configure: Regenerated.
-
-2002-01-26 Hans-Peter Nilsson <hp@bitrange.com>
-
- * Makefile.am (install): Depend on install-info.
- * Makefile.in: Regenerate.
-
-2002-01-26 Christian Rose <menthos@menthos.com>
-
- * ldmain.c (main): Use full sentences to ease translation.
-
-2002-01-26 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/fr.po: Updated version.
-
-2002-01-25 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/es.po: Updated version.
-
-2002-01-25 Andreas Jaeger <aj@suse.de>
-
- * ldlex.l (yy_input): Correct error check.
-
-2002-01-25 Alan Modra <amodra@bigpond.net.au>
-
- * ldmisc.c (demangle): Put back dots when string not demangled.
-
-2002-01-22 Richard Henderson <rth@redhat.com>
-
- * emulparams/elf64alpha.sh (NOP): Use unop.
-
-2002-01-21 Andreas Jaeger <aj@suse.de>
-
- * ldlex.l: Use fread instead of read.
-
-2002-01-21 Jason Thorpe <thorpej@wasabisystems.com>
-
- * configure.tgt (ia64-*-netbsd*): New target.
-
-2002-01-21 H.J. Lu <hjl@gnu.org>
-
- * emulparams/elf32btsmip.sh (SHLIB_TEXT_START_ADDR): Change to
- 0.
- * emulparams/elf64btsmip.sh (SHLIB_TEXT_START_ADDR): Likewise.
-
-2002-01-18 Andreas Jaeger <aj@suse.de>
-
- * ldver.c (ldversion): Update year.
-
-2002-01-17 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/ld.pot: Regenerate.
-
-2002-01-16 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am (eelf64ppc.c, eelf64lppc.c): Depend on ppc64elf.em.
- * Makefile.in: Regenerate.
- * emulparams/elf64ppc.sh (EXTRA_EM_FILE): Define.
- * emultempl/ppc64elf.em: New file.
-
-2002-01-15 DJ Delorie <dj@redhat.com>
-
- * scripttempl/pe.sc: Add support for constructor priorities.
-
-2002-01-07 Marek Michalkiewicz <marekm@amelek.gda.pl>
-
- * emulparams/avr1200.sh (DATA_START): Define as 0x60.
- * emulparams/avr23xx.sh: Likewise.
- * emulparams/avr4433.sh: Likewise.
- * emulparams/avr44x4.sh: Likewise.
- * emulparams/avr85xx.sh: Likewise.
- * emulparams/avrmega103.sh: Likewise.
- * emulparams/avrmega161.sh: Likewise.
- * emulparams/avrmega603.sh: Likewise.
- * scripttempl/elf32avr.sc: Use DATA_START instead of 0x60.
-
-2002-01-08 Alexandre Oliva <aoliva@redhat.com>
-
- * ldlang.c (walk_wild_section): Exclude object file if enclosing
- archive is excluded.
-
-2002-01-07 Jason Thorpe <thorpej@wasabisystems.com>
-
- * Makefile.am (ALL_EMULATIONS): Add eshelf_nbsd.o and eshlelf_nbsd.o.
- (eshelf_nbsd.c): New rule.
- (eshlelf_nbsd.c): New rule.
- * Makefile.in: Regenerate.
- * configure.tgt (sh*le-*-netbsdelf*): New target.
- (sh*-*-netbsdelf*): New target.
- * emulparams/shelf.sh: Document that shelf_nbsd.sh sources this file.
- * ld/emulparams/shelf_nbsd.sh: New emulation.
- * ld/emulparams/shlelf_nbsd.sh: New emulation.
-
-2002-01-07 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/es.po: New file: Spanish translation.
- * configure.in (ALL_LINGUAS): Add es.
- * configure: Regenerate.
-
-2002-01-06 John Marshall <jmarshall@acm.org>
-
- * ld.texinfo: Note that --emit-relocs is currently only
- implemented for ELF.
-
-2002-01-05 Alan Modra <amodra@bigpond.net.au>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Make use
- of bfd_section_list_remove and bfd_section_list_insert macros.
- * emultempl/pe.em (gld_${EMULATION_NAME}_place_orphan): Likewise.
- * emultempl/mmo.em (mmo_place_orphan): Likewise.
-
-2002-01-04 Jason Thorpe <thorpej@wasabisystems.com>
-
- * configure.tgt (x86_64-*-netbsd*): New target.
-
-2001-12-21 Tom Rix <trix@redhat.com>
-
- (gld*_create_output_section_statements): New function.
- For -binitfini support.
- * emultempl/aix.em (gld*_before_parse): Fix comment.
- * emultempl/aix.em (gld*_parse_args): Fix comment.
-
-2001-12-20 Jason Thorpe <thorpej@wasabisystems.com>
-
- * configure.tgt (mips*-dec-netbsd*): Delete alias for
- mips*el-*-netbsd*.
- (sparc64-*-netbsd*): Add elf32_sparc to targ_extra_emuls.
-
- * configure.tgt (arm-*-netbsdelf*): Add target.
- (arm-*-netbsd*): Add armelf and armelf_nbsd to targ_extra_emuls.
- * emulparams/armelf_nbsd.sh: Added.
- * Makefile.am: Add rules for earmelf_nbsd.
- * Makefile.in: Regenerate.
-
-2001-12-19 Andreas Jaeger <aj@suse.de>,
- Susanne Oberhauser <froh@suse.de>
-
- * configure.host: Add rules for x86_64-*linux-gnu. Change
- s390x-linux entry to use gcc to report configuration, replace gcc
- with $CC in s390-linux
-
-2001-12-19 Andreas Jaeger <aj@suse.de>
-
- * ld.texinfo (VERSION): Fix markup.
-
-2001-12-18 matthew green <mrg@eterna.com.au>
-
- * Makefile.am (ALL_EMULATIONS): Add m68kelfnbsd.o.
- (m68kelfnbsd.c): New rule.
- * Makefile.in: Regenerate.
- * configure.tgt (m68*-hp-netbsd*): Renamed to ..
- (m68*-*-netbsd*4k*): .. this.
- (m68*-*-netbsdelf*): New target.
- (m68*-*-netbsd*): Also include ELF support.
- (m68*-*-netbsdaout*): New alias for m68*-*-netbsd*.
- * emulparams/m68kelfnbsd.sh: New emulation.
-
-2001-12-18 Jakub Jelinek <jakub@redhat.com>
-
- * ldgram.y (vers_node): Support anonymous version tags.
- * ldlang.c (lang_register_vers_node): Ensure anonymous version
- tag is not defined together with non-anonymous versions.
- * ld.texinfo: Document it.
-
-2001-12-18 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/tr.po: New file: Turkish translation.
- * configure.in (ALL_LINGUAS): Add tr.
- * configure: Regenerate.
-
-2001-12-17 Jason Thorpe <thorpej@wasabisystems.com>
-
- * Makefile.am: Add rules for eelf64alpha_nbsd.
- * Makefile.in: Regenerate.
- * configure.tgt (alpha*-*-netbsd*): Set
- targ_emul to elf64alpha_nbsd.
- * emulparams/elf64alpha_nbsd.sh: Added.
-
-2001-12-17 Alan Modra <amodra@bigpond.net.au>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Adjust
- section_tail when fiddling with section list.
- (gld${EMULATION_NAME}_list_options): Ensure sentences aren't
- broken into separate strings to make translation easier.
- * emultempl/mmo.em (mmo_place_orphan): Adjust section_tail when
- fiddling with section list.
- * emultempl/pe.em (gld_${EMULATION_NAME}_place_orphan): Likewise.
-
-2001-12-16 Hans-Peter Nilsson <hp@bitrange.com>
-
- * scripttempl/mmo.sc: Add .debug_ranges to listed sections.
-
-2001-12-15 Alan Modra <amodra@bigpond.net.au>
-
- * ldmain.c (main): Initialise link_info.eh_frame_hdr.
-
-2001-12-13 Jakub Jelinek <jakub@redhat.com>
-
- * emultempl/elf32.em (finish): Supply output_bfd
- to bfd_elf*_discard_info.
- (OPTION_EH_FRAME_HDR): Define.
- (longopts): Add --eh-frame-hdr.
- (parse_args): Handle it.
- (list_options): Add --eh-frame-hdr to help.
- * emultempl/hppaelf.em (finish): Supply output_bfd
- to bfd_elf*_discard_info.
- * scripttempl/elf.sc (.eh_frame_hdr): Add.
-
-2001-12-13 Alan Modra <amodra@bigpond.net.au>
-
- * lexsup.c (parse_args): Don't pass shortopts to second call to
- getopt functions. Restore optind rather than decrementing before
- second call. Remove errind as it now duplicates last_optind.
-
-2001-12-11 Christopher Faylor <cgf@redhat.com>
-
- * emultempl/pe.em (gld_${EMULATION_NAME}_list_options): Fix typo.
-
-2001-12-07 Geoffrey Keating <geoffk@redhat.com>
- Richard Henderson <rth@redhat.com>
-
- * Makefile.am: Add support for xstormy16.
- * configure.tgt: Add support for xstormy16.
- * Makefile.in: Regenerate.
- * emulparams/elf32xstormy16.sh: New file.
- * scripttempl/xstormy16.sc: New file.
-
-2001-10-01 Christopher Faylor <cgf@cygnus.com>
-
- * Makefile.in (LIB_PATH): Make configurable.
- (GENSCRIPTS): Set LIB_PATH in environment.
- * configure.in: Substitute LIB_PATH.
- * configure: Regenerate.
- * configure.tgt (*cygwin): Set LIB_PATH for cross build.
- * configure.host (*cygwin): Add /usr/lib/w32api to NATIVE_LIB_DIRS.
-
-2001-12-07 Nick Clifton <nickc@cambridge.redhat.com>
-
- * lexsup.c (ld_options): Insert 'PROGRAM' into the text string
- describing the -N option so that it is easier to translate into
- foreign languages.
-
-2001-12-05 Nick Clifton <nickc@cambridge.redhat.com>
-
- * emultempl/pe.em (..._list_options): Replace multiple fprintf
- statements describing a single option with a single, newline
- escaped fprintf. This allows better translation into other
- languages.
-
- * ldmain.c (add_archive_element): Combine multiple strings
- into a single string to permit better translation into other
- languages.
-
-2001-12-05 Tom Rix <trix@redhat.com>
-
- * Makefile.am: Remove eaixppc64.
- * Makefile.in: Regenerate.
-
-2001-12-04 Tom Rix <trix@redhat.com>
-
- * emultempl/aix.em (choose_target): Change default target to
- OUTPUT_FORMAT for ppcmacos. Add braces to remove compiler
- warning.
- (gld*_read_file): Fix typo.
- (change_symbol_mode): Add prototype.
- (is_syscall): Same.
-
- * emulparams/aixppc.sh (SYSCALL_MASK, SYMBOL_MODE_MASK): Delete.
- * emulparams/aixrs6.sh : Same.
- * emulparams/ppcmacos.sh : Same.
- * emulparams/aixppc64.sh : Delete file.
- * emultempl/aix.em : Formatting changes.
-
-2001-12-04 Hans-Peter Nilsson <hp@axis.com>
-
- * emulparams/criself.sh (NO_SMALL_DATA): Set, to yes.
- (OTHER_BSS_END_SYMBOLS): Don't refer to .sbss when setting
- __Sbss.
- (OTHER_END_SYMBOLS): Fix formatting.
- * emulparams/crislinux.sh (NO_SMALL_DATA): Set, to yes.
- (OTHER_END_SYMBOLS): Fix formatting.
-
-2001-12-04 Alan Modra <amodra@bigpond.net.au>
-
- * ldexp.c (exp_print_token): Correct "table" entry for RSHIFT.
-
-2001-12-02 Tom Rix <trix@redhat.com>
-
- * configure.tgt : Remove eaixppc64 emulations.
- * Makefile.in : Remove eaixppc64.c
- * ldemul.c (ldemul_choose_target): New parameters argc, argv.
- (ldemul_default_target): Same.
- * emultempl/gld960.em (gld960_choose_target): Same.
- * emultempl/gld960c.em (gld960_choose_target): Same.
- * scripttempl/aix.sc: Remove OUTPUT_FORMAT.
- * emultempl/aix.em (is_syscall): syscall_mask now a variable.
- * emultempl/aix.em (gld*_read_file): symbol_mode_mask now a variable.
- * emultempl/aix.em (gld*_parse_args): Handle -b32 -b64 emulation.
- * emultempl/aix.em (choose_target): New function. Handle emulation of
- -b32 and -b64.
-
-2001-11-27 H.J. Lu <hjl@gnu.org>
-
- * emulparams/elf_i386.sh (NO_SMALL_DATA): Set to yes.
- * emulparams/elf_i386_be.sh (NO_SMALL_DATA): Likewise.
- * emulparams/elf_i386_chaos.sh (NO_SMALL_DATA): Likewise.
- * emulparams/elf_i386_ldso.sh (NO_SMALL_DATA): Likewise.
- * emulparams/elf_x86_64.sh (NO_SMALL_DATA): Likewise.
- * emulparams/m68kelf.sh (NO_SMALL_DATA): Likewise.
- * emulparams/elf32_sparc.sh (NO_SMALL_DATA): Likewise.
- * emulparams/elf64_sparc.sh (NO_SMALL_DATA): Likewise.
-
- * scripttempl/elf.sc (SBSS): New. Define if ${NO_SMALL_DATA}
- is not empty.
- (SDATA): Likewise.
- (REL_SDATA): Likewise.
- (REL_SBSS): Likewise.
- (REL_SDATA2): Likewise.
- (REL_SBSS2): Likewise.
- (SBSS2): Define if ${NO_SMALL_DATA} is not empty.
- (SDATA2): Likewise.
-
-2001-11-25 Stephane Carrez <Stephane.Carrez@worldnet.fr>
-
- * scripttempl/elfm68hc11.sc (CTOR, DTOR): Put constructor and
- destructor in rom.
- * scripttempl/elfm68hc12.sc (CTOR, DTOR): Likewise.
-
-2001-11-22 H.J. Lu <hjl@gnu.org>
-
- * Makefile.in: Regenerated with automake based on automake
- 1.4-8 in RedHat 7.1.
-
-2001-11-22 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am (CONFIG_STATUS_DEPENDENCIES): Define.
- (config.status): Delete rule.
- Add extra dependencies to cover sourced emulparams files.
- * Makefile.in: Regenerate.
-
- * scripttempl/elf.sc: Order <section>, <section>.* and
- corresponding linkonce sections as seen in input files.
- Formatting fixes. Zero vma of all sections if not relocating.
- (STACK): Define and insert if STACK_ADDR defined.
- (OTHER_RELOCATING_SECTIONS): Delete.
- (OTHER_END_SYMBOLS): Define.
- (OTHER_READONLY_SECTIONS): Always insert, not just when relocating.
- (OTHER_READWRITE_SECTIONS): Likewise.
- (OTHER_GOT_SECTIONS): Likewise.
- (OTHER_SDATA_SECTIONS): Likewise.
- (OTHER_BSS_SECTIONS): Likewise.
- * scripttempl/elfi370.sc (OTHER_READONLY_SECTIONS): Likewise.
- (OTHER_READWRITE_SECTIONS): Likewise.
- * scripttempl/nw.sc (OTHER_READONLY_SECTIONS): Likewise.
- (OTHER_READWRITE_SECTIONS): Likewise
-
- * emulparams/armelf.sh (OTHER_RELOCATING_SECTIONS): Delete.
- (STACK_ADDR): Define.
- * emulparams/armelf_oabi.sh: As for armelf.sh.
- * emulparams/elf32mcore.sh: As for armelf.sh.
- * emulparams/h8300elf.sh: As for armelf.sh.
- * emulparams/mn10200.sh: As for armelf.sh.
- * emulparams/shelf.sh: As for armelf.sh.
-
- * emulparams/elf32fr30.sh (OTHER_RELOCATING_SECTIONS): Delete.
- (OTHER_END_SYMBOLS): Define.
- * emulparams/m32relf.sh: As for elf32fr30.sh.
- * emulparams/h8300helf.sh: As for elf32fr30.sh.
- * emulparams/h8300self.sh: As for elf32fr30.sh.
-
- * emulparams/criself.sh (OTHER_READONLY_SECTIONS): Protect symbol
- defines with RELOCATING test.
- (OTHER_SDATA_SECTIONS): Likewise.
- (OTHER_RELOCATING_SECTIONS): Delete, replacing with..
- (OTHER_END_SYMBOLS): ..this.
- * emulparams/crislinux.sh: As for criself.sh.
-
- * emulparams/elf32bmipn32.sh (OTHER_SDATA_SECTIONS): Zero vma
- if not relocating.
- (OTHER_RELOCATING_SECTIONS): Delete, replacing with..
- (OTHER_SECTIONS): ..this. Zero vma if not relocating. Order
- normal and linkonce sections as seen in input files.
- * emulparams/elf32bmip.sh (DATA_ADDR): Don't define if EMBEDDED.
- (TEXT_DYNAMIC): Likewise.
- (INITIAL_READONLY_SECTIONS): Zero vma if not relocating.
- (OTHER_SDATA_SECTIONS): Likewise.
- * emulparams/elf32ppc.sh (OTHER_READWRITE_SECTIONS): Likewise.
- * emulparams/shlelf_linux.sh (OTHER_READWRITE_SECTIONS): Likewise.
- * emulparams/elf64alpha.sh (OTHER_READONLY_SECTIONS): Likewise.
- * emulparams/hppalinux.sh (OTHER_READONLY_SECTIONS): Likewise.
- * emulparams/elf64_aix.sh (OTHER_GOT_SECTIONS): Likewise.
- (OTHER_PLT_RELOC_SECTIONS): Likewise.
- (OTHER_READONLY_SECTIONS): Likewise. Order normal and linkonce
- sections as seen in input files.
- * emulparams/elf64_ia64.sh: As for emulparams/elf64_aix.sh.
- * emulparams/hppa64linux.sh (OTHER_READONLY_SECTIONS): Zero vma
- if not relocating.
- (OTHER_READWRITE_SECTIONS, OTHER_BSS_SECTIONS): Likewise.
- (OTHER_BSS_END_SYMBOLS): Merge from elf64hppa.sh.
- * emulparams/elf64mmix.sh (OTHER_RELOCATING_SECTIONS): Delete.
- (OTHER_SECTIONS): Instead, use this..
- (OTHER_END_SYMBOLS): ..and this.
-
- * emulparams/elf32b4300.sh: Source elf32bmip.sh, remove duplicates.
- * emulparams/elf32bsmip.sh: Likewise.
- * emulparams/elf32btsmip.sh: Likewise.
- * emulparams/elf32ebmip.sh: Likewise.
- * emulparams/elf32lmip.sh: Likewise.
- * emulparams/elf32elmip.sh: Source elf32lmip.sh, remove duplicates.
- * emulparams/elf32lsmip.sh: Likewise.
- * emulparams/elf32ltsmip.sh: Source elf32btsmip.sh, remove duplicates.
- * emulparams/elf32l4300.sh: Source elf32b4300.sh, remove duplicates.
- * emulparams/elf64bmip.sh: Source elf32bmipn32.sh, remove duplicates.
- * emulparams/elf64btsmip.sh: Likewise.
- * emulparams/elf64ltsmip.sh: Source elf64btsmip.sh, remove duplicates.
- * emulparams/elf32lppc.sh: Source elf32ppc.sh, remove duplicates.
- * emulparams/elf32ppclinux.sh: Likewise.
- * emulparams/elf32ppcsim.sh: Likewise.
- * emulparams/elf32lppcsim.sh: Source elf32lppc.sh, remove duplicates.
- * emulparams/elf64hppa.sh: Source hppa64linux.sh, remove duplicates.
- * emulparams/h8300helf.sh: Source h8300elf.sh, remove duplicates.
- * emulparams/h8300self.sh: Likewise.
- * emulparams/mn10300.sh: Source mn10200.sh, remove duplicates.
- * emulparams/sh.sh: Comment.
- * emulparams/shl.sh: Source sh.sh, remove duplicates.
- * emulparams/shlelf.sh: Source shelf.sh, remove duplicates.
- * emulparams/shelf_linux.sh: Source shlelf_linux.sh, remove duplicates.
-
-2001-11-21 David Heine <dlheine@tensilica.com>
- Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.c (map_input_to_output_sections): Replace "break"
- accidentally removed with 2001-08-03 change.
- (lang_gc_sections_1): Likewise.
-
-2001-11-21 Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.c (walk_wild_section): Move sec == NULL case out of loop.
-
-2001-11-20 Angela Marie Thomas <angela@redhat.com>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_finish): Use NULL instead
- of false when calling lang_size_sections.
- * emultempl/hppaelf.em (hppaelf_layout_sections_again): Likewise.
-
-2001-11-15 Alan Modra <amodra@bigpond.net.au>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_finish): Only emit this
- function when LDEMUL_FINISH isn't set to the same name. Don't
- call ${LDEMUL_FINISH}.
- (ld_${EMULATION_NAME}_emulation): Call $LDEMUL_FINISH if defined.
- * emultempl/armelf.em (arm_elf_finish): Call
- gld${EMULATION_NAME}_finish.
- * emultempl/hppaelf.em (hppaelf_finish): Rename to
- gld${EMULATION_NAME}_finish. Call bfd_elf32_discard_info and
- hppaelf_layout_sections_again if necessary.
- (need_laying_out): New var.
- (hppaelf_layaout_sections_again): Rename to
- hppaelf_layout_sections_again. Clear need_laying_out.
- (PARSE_AND_LIST_OPTIONS): Format text.
-
-2001-11-14 H.J. Lu <hjl@gnu.org>
-
- * emultempl/armelf.em (arm_elf_finish): Renamed from
- gld${EMULATION_NAME}_finish.
- (LDEMUL_FINISH): Set to arm_elf_finish.
-
-2001-11-14 Daniel Jacobowitz <drow@mvista.com>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_finish): New.
- (struct ld_emulation_xfer_struct): Use it.
-
-2001-11-13 Ross Alexander <ross.alexander@uk.neceur.com>
-
- * emulparams/elf64hppa.sh (OTHER_BSS_END_SYMBOLS): Add
- additional symbols referenced by newer crt0.o files from HP.
-
-2001-11-12 Anthony Green <green@redhat.com>
-
- * emulparams/armelf.sh (DATA_START_SYMBOLS): New symbol.
-
-2001-11-12 Alfred M. Szmidt <ams@kemisten.nu>
-
- * Makefile.am (GENSCRIPTS): Quote ${exec_prefix}.
- * Makefile.in: Regenerate.
-
-2001-11-02 Stephane Carrez <Stephane.Carrez@worldnet.fr>
-
- * ld.texinfo: Use @command for commands, @option for options.
- * Makefile.am (POD2MAN): Use 'GNU Development Tools' for
- the page man title.
- * Makefile.in: Rebuild.
-
-2001-11-04 Chris Demetriou <cgd@broadcom.com>
-
- * configure.tgt (mips*el-*-netbsd*, mips*-*-netbsd*):
- Add support for targets.
-
-2001-11-02 Nick Clifton <nickc@cambridge.redhat.com>
-
- * configure.in (ALL_LINGUAS): Add "fr" and "sv"
- * configure: Regernate.
- * po/fr.po: New file.
- * po/sv.po: New file.
-
-2001-11-01 NIIBE Yutaka <gniibe@m17n.org>
-
- * configure.tgt (sh-*-linux): Set targ_emul, targ_extra_emuls
- as little endian default and to support big endian.
-
-2001-11-01 Chris Demetriou <cgd@broadcom.com>
-
- * ld.texinfo (Options): Document new option, -nostdlib.
- * lexsup.c (OPTION_NOSTDLIB): New definition.
- (ld_options): Add entry for "nostdlib".
- (parse_args): Handle OPTIONS_NOSTDLIB.
- * ldfile.c (ldfile_add_library_path): Don't add directories
- to the search path if they weren't specified on the command line
- and -nostdlib was specified.
- * ld.h (ld_config_type): New member only_cmd_line_lib_dirs.
-
-2001-10-31 Nick Clifton <nickc@cambridge.redhat.com>
-
- * lexsup.c (parse_args): Prevent infinite parsing loop when
- "-rpath.a" is specified on the command line.
- Replace calls to fprintf with calls to einfo.
-
-2001-10-31 John Marshall <jmarshall@acm.org>
-
- * ld.texinfo: A historical requirement that MEMORY and SECTIONS
- appear only once across all the linker scripts involved in a link
- invocation no longer applies. Make the documentation reflect
- that.
-
-2001-10-31 NIIBE Yutaka <gniibe@m17n.org>
-
- * configure.tgt: Supports sh3/sh4/sh3eb/sh4eb-unknown-linux-gnu
- targets.
- (sh-*-linux*): Added targ_extra_libpath.
-
-2001-10-31 David Heine <dlheine@tensilica.com>
-
- * ldlang.c (lang_size_sections): Keep a valid output_offset field
- for padding statements.
-
-2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
-
- * configure.tgt (mmix-*-*): New target.
- * Makefile.am (ALL_EMULATIONS): Add eelf64mmix.o and emmo.o.
- Add dependencies to match.
- * emulparams/mmo.sh, emulparams/elf64mmix.sh, emultempl/mmo.em,
- emultempl/mmix-elfnmmo.em, emultempl/mmixelf.em,
- scripttempl/mmo.sc: New files.
- * gen-doc.texi: @set MMIX.
- * ld.texinfo: Ditto.
- [MMIX] Add MMIX node.
- * Makefile.in: Regenerate.
-
-2001-10-29 Kazu Hirata <kazu@hxi.com>
-
- * ldlang.c: Fix a comment typo.
-
-2001-10-23 Alan Modra <amodra@bigpond.net.au>
-
- * configure.host: Move alpha*-*-linux-gnu* entry to generic
- entries, and match *-*-linux*.
-
-2001-10-20 Alan Modra <amodra@bigpond.net.au>
-
- * ldgram.y (mri_script_command): Surround processing of INCLUDE
- with ldlex_script, ldlex_popstate.
- (ifile_p1): Likewise.
- * ldlex.l (EOF): Don't BEGIN(SCRIPT). Restore lineno from the
- correct slot.
- (lex_push_file): Save current lineno to lineno_stack. Set lineno
- to 1. Don't BEGIN(SCRIPT).
- (lex_redirect): Similarly.
- * ldmain.c (main): Set yydebug non-zero if YYDEBUG.
-
-2001-10-20 Nick Clifton <nickc@cambridge.redhat.com>
-
- * scripttempl/armcoff.sc: Define __EH_FRAME_BEGIN__ and
- __EH_FRAME_END__ and accept eh frames into data section.
- Add ctor and dtor sections.
-
-2001-10-19 Danny Smith <danny_r_smith_2001@yahoo.co.nz>
-
- * pe-dll.c (autofilter_objectlist): Add gcrt0.o.
- (auto-export): Fix indentation.
-
-2001-10-18 Danny Smith <danny_r_smith_2001@yahoo.co.nz>
-
- * pe-dll.c (autofilter_objectlist): Add startup objects
- for profiling.
- (auto-export): Constify char * p.
- Extract file basename and use strcmp rather than ststr
- for object lookup.
-
-2001-10-18 Chris Demetriou <cgd@broadcom.com>
-
- * ldmain.c (get_emulation): Improve comment about the handling
- of -mipsN options.
-
-2001-10-17 Alan Modra <amodra@bigpond.net.au>
-
- * po/POTFILES.in: Regenerate.
-
-2001-10-16 Vassili Karpov <malc@pulsesoft.com>
-
- * emultempl/elf32.em (gld*_list_options): Remove extra '\t' from
- -z nocopyreloc and -z nocombreloc usage strings.
-
-2001-10-12 Vassili Karpov <malc@pulsesoft.com>
-
- * emultempl/elf32.em (gld*_list_options): Include -z nocopyreloc
- in usage.
-
-2001-10-11 Aleksey Romanov <aromanov@ennovatenetworks.com>
-
- * scripttempl/armaout.sc: Place .bss section after end of aligned
- data section to match behaviour of aout code in constructrion of
- header.
-
-2001-10-11 Danny Smith <danny_r_smith_2001@yahoo.co.nz>
-
- * pe-dll.c (autofilter_entry_type autofilter_liblist: Add
- startup files for mingw32 dlls to list.
-
-2001-10-10 Chris Demetriou <cgd@broadcom.com>
-
- * emultempl/elf32.em: Fix shell 'if' usage for portability.
-
-2001-10-08 Aldy Hernandez <aldyh@redhat.com>
-
- * configure.tgt (targ): Add arm9e-*-elf.
-
-2001-10-05 H.J. Lu <hjl@gnu.org>
-
- * genscripts.sh: Fix a typo in the last change.
-
-2001-10-05 Jakub Jelinek <jakub@redhat.com>
-
- * emultempl/elf32.em (gld_*_list_options): Include -z combreloc and
- -z nocombreloc in usage.
-
-2001-10-03 Jim Blandy <jimb@redhat.com>
-
- * genscripts.sh: Include a comment at the top of each generated
- script, explaining its purpose.
-
-2001-10-03 Vassili Karpov <malc@pulsesoft.com>
-
- * emultempl/elf32.em (parse_args): Handle -z nocopyreloc.
- * NEWS: Mention -z nocopyreloc.
- * ld.texinfo (Options): Describe nocopyreloc.
-
-2001-10-03 Alan Modra <amodra@bigpond.net.au>
-
- * configure: Regenerate.
-
-2001-10-02 Alan Modra <amodra@bigpond.net.au>
-
- * ldver.h (ld_program_version): Remove declaration.
- * lexsup.c (parse_args): Move printing of copyright message..
- * ldver.c (ldversion): .. to here.
- Use BFD_VERSION_STRING in place of BFD_VERSION.
- (ld_program_version): Remove.
- * Makefile.am (Makefile): Depend on bfd/configure.in.
- Run "make dep-am".
- * Makefile.in: Regenerate.
-
-2001-09-30 Hans-Peter Nilsson <hp@bitrange.com>
-
- * Makefile.am: Update dependencies with "make dep-am".
- * Makefile.in: Regenerate.
-
-2001-09-29 John Reiser <jreiser@BitWagon.com>
-
- * ldlang.c (lang_common): Conditionally inhibit Common allocation.
- * lexsup.c: Add --no-define-common commandline option.
- * ldgram.y: Add INHIBIT_COMMON_ALLOCATION script command.
- * ldlex.l: Likewise.
- * ld.h: Add command_line.inhibit_common_definition.
- * ldmain.c (main): Initialize.
- * ld.texinfo: Document.
-
-2001-09-26 Alan Modra <amodra@bigpond.net.au>
-
- * ldmisc.c (USE_STDARG): Remove.
- (info_msg): Define using VPARAMS, VA_OPEN, VA_FIXEDARG, VA_CLOSE.
- (einfo): Likewise.
- (minfo): Likewise.
- (lfinfo): Likewise.
-
- * ldmisc.h: Remove #ifdef ANSI_PROTOTYPES and non-ansi
- declarations. Update copyright.
-
-2001-09-24 Charles Wilson <cwilson@ece.gatech.edu>
-
- * pe-dll.c: Remove obsoleted declaration of
- pe_get_data_import_dll_name.
- (pe_create_import_fixup): Fix thinko.
-
- * ld.texinfo(enable-auto-import): Clarify the explanation.
-
-2001-09-24 Nick Clifton <nickc@cambridge.redhat.com>
-
- * pe-dll.c (pe_create_import_fixup): Revert previous patch.
- * emultemp/pe.em (pe_data_import_dll): Move definition outside of
- DLL_SUPPORT controlled code.
-
-2001-09-24 Charles Wilson <cwilson@ece.gatech.edu>
-
- * emultempl/pe.em(pe_data_import_dll): Make static.
- (pe_get_data_import_dll_name): New accessor function.
- * pe-dll.c(pe_create_import_fixup): call
- pe_get_data_import_dll_name() from pe.em, instead of
- directly accessing pe_data_import_dll variable from pe.em.
-
-2001-09-18 Bruno Haible <haible@clisp.cons.org>
-
- * deffilep.y: Include "safe-ctype.h" instead of <ctype.h>.
- (def_file_add_directive): Use ISSPACE instead of isspace.
- (def_lex): Use ISDIGIT/ISXDIGIT/ISALPHA/ISALNUM instead of
- isdigit/isxdigit/isalpha/isalnum.
- * emultempl/aix.em: Include "safe-ctype.h" instead of <ctype.h>.
- (gld${EMULATION_NAME}_read_file): Use ISSPACE instead of isspace.
- * emultempl/elf32.em: Include "safe-ctype.h" instead of <ctype.h>.
- (gld${EMULATION_NAME}_place_orphan): Use ISALNUM instead of
- isalnum.
- * emultempl/gld960c.em: Include "safe-ctype.h" instead of <ctype.h>.
- (gld960_set_output_arch): Use ISUPPER/TOLOWER instead of
- isupper/tolower.
- * emultempl/sunos.em: Include "safe-ctype.h" instead of <ctype.h>.
- (gld${EMULATION_NAME}_search_dir): Use ISDIGIT instead of isdigit.
- * ldctor.c: Include "safe-ctype.h" instead of <ctype.h>.
- (ctor_prio): Use ISDIGIT instead of isdigit.
- * ldfile.c: Include "safe-ctype.h" instead of <ctype.h>.
- (ldfile_open_file_search): Use ISALPHA instead of isalpha.
- (ldfile_add_arch): Use ISUPPER/TOLOWER instead of
- isupper/tolower.
- * ldlang.c: Include "safe-ctype.h" instead of <ctype.h>.
- (stricpy): Use TOLOWER instead of isupper/tolower.
- (lang_leave_overlay_section): Use ISALNUM instead of isalnum.
- * ldlex.l: Include "safe-ctype.h" instead of <ctype.h>.
- (lex_warn_invalid): Use ISPRINT instead of isprint.
- * ldmain.c: Include "safe-ctype.h" instead of <ctype.h>.
- (main): For gettext, also set the LC_CTYPE locate facet.
- (add_keepsyms_file): Use ISSPACE instead of isspace.
- * lexsup.c: Include "safe-ctype.h" instead of <ctype.h>.
- (is_num, parse_args): Use ISDIGIT instead of isdigit.
- * mpw-elfmips.c: Include "safe-ctype.h" instead of <ctype.h>.
- (gldelf32ebmip_place_orphan): Use ISALNUM instead of isalnum.
- * mpw-eppcmac.c: Include "safe-ctype.h" instead of <ctype.h>.
- (gldppcmacos_read_file): Use ISSPACE instead of isspace.
- * pe-dll.c: Include "safe-ctype.h" instead of <ctype.h>.
- (quoteput): Use ISSPACE instead of isspace.
- (pe_dll_generate_implib, pe_process_import_defs): Use ISALNUM
- instead of isalnum.
-
-2001-09-18 Alan Modra <amodra@bigpond.net.au>
-
- * deffilep.y (def_stash_module): Constify "name" param.
-
- * pe-dll.c: Replace CONST with const throughout.
- (quick_symbol): Constify "n1", "n2", "n3" params.
- (make_singleton_name_thunk): Constify "import" param. Make
- "buffer_len" a size_t.
- (make_import_fixup_entry): Constify "name", "fixup_name",
- "dll_symname" params.
- (pe_get16): Cast args of bfd_seek. Replace bfd_read with bfd_bread.
- (pe_get32): Likewise.
- (pe_implied_import_dll): Likewise.
-
- * emultempl/beos.em (sort_by_file_name): Constify "ra", "rb".
- (sort_by_section_name): Likewise.
-
- * emultempl/pe.em: Move defines for arm_epoc_pe before bfd.h included.
- (make_import_fixup): Cast printf arg, rel->address to long rather
- than int.
- (gld_${EMULATION_NAME}_after_open): Don't compare NULL against int.
-
-2001-09-15 Alan Modra <amodra@bigpond.net.au>
-
- * ldmain.c (main): Rename BufferSize to ld_bufsz because HPUX
- defines BufferSize. Increase buffer size by one.
-
-2001-09-14 Ralf Habacker <Ralf.Habacker@freenet.de>
-
- * pe-dll.c (pe_walk_relocs_of_symbol): Fix memory leak.
-
-2001-09-14 Kevin Lo <kevlo@openbsd.org>
-
- * configure.tgt: Add arm-openbsd target.
-
-2001-09-12 H.J. Lu <hjl@gnu.org>
-
- * Makefile.am (ALL_EMULATIONS): Move eelf64ppc.o and
- eelf64lppc.o to ...
- (ALL_64_EMULATIONS): Here.
- * Makefile.in: Regenerated.
-
-2001-09-12 Paul Sokolovsky <Paul.Sokolovsky@technologist.com>
-
- * emultempl/pe.em(make_import_fixup): change signature to
- take asection as well as arelec; we need this for proper
- error reporting. Only call pe_create_import_fixup() if
- there is no attempt to add a constant addend to the reloc;
- otherwise, report error condition.
- * pe-dll.c(pe_walk_relocs_of_symbol): change signature,
- since final argument is a pointer to make_import_fixup().
- Change call to cb() to match make_import_fixup() signature.
- (make_import_fixup_mark): make buffer_len unsigned.
- * pe-dll.h: change signature of pe_walk_relocs_of_symbol.
-
-2001-09-12 Charles Wilson <cwilson@ece.gatech.edu>
-
- * ld.texinfo: add verbose documentation for auto-import
- direct-addressing workaround, to compliment the terse
- error message.
-
-2001-09-12 Andrew MacLeod <amacleod@redhat.com>
-
- * scripttempl/v850.sc: Add gcc_except_table sections.
-
-2001-09-11 Jeffrey A Law (law@cygnus.com)
-
- * emulparams/h8300helf.sh: Move stack to a much higher memory address.
- * emulparams/h8300self.sh: Similarly.
-
-2001-09-05 Danny Smith <dannysmith@users.souceforge.net>
-
- * ld.texinfo (Options, --stack): Correct default value for stack
- reserve.
-
-2001-09-05 Tom Rix <trix@redhat.com>
-
- * emultempl/aix.em : Handle import file XMC_XO and syscall symbols.
-
-2001-09-03 Andreas Jaeger <aj@suse.de>
-
- * emultempl/beos.em: Declare prototypes for comparions functions,
- adjust definitions.
-
-2001-09-02 Andreas Jaeger <aj@suse.de>
-
- * emultempl/aix.em: Add missing prototype.
- * emultempl/lnk960.em: Likewise.
- * emultempl/vanilla.em: Likewise.
- * emultempl/armcoff.em: Likewise.
- * emultempl/armelf_oabi.em: Likewise.
- * emultempl/beos.em: Likewise.
- * emultempl/gld960c.em: Likewise.
- * emultempl/gld960.em: Likewise.
-
- * emulparams/elf64alpha.sh (PARSE_AND_LIST_PROLOGUE): Add parameter
- for prototype declaration.
-
-2001-08-31 Eric Christopher <echristo@redhat.com>
- Jason Eckhardt <jle@redhat.com>
-
- * ldmain.c (get_emulation): Add support for -mips32 and -mips64.
-
-2001-08-31 Andreas Jaeger <aj@suse.de>
-
- * emultempl/pe.em: Add missing prototypes.
- (gld_${EMULATION_NAME}_after_open): Remove extra args to
- pe_find_data_imports.
- (pr_sym): Add unused attribute.
-
-2001-08-29 Joel Sherrill <joel@OARcorp.com>
-
- * configure.tgt (i[3456]86-*-rtems*, m68*-*-rtems*): Change
- default from coff to elf.
-
-2001-08-29 Jeff Law <law@redhat.com>
-
- * emulparams/h8300helf.sh: Resync with h8300elf.sh. Update
- ARCH specification.
- * emulparams/h8300self.sh: Similarly.
-
-2001-08-28 J"orn Rennecke <amylaar@redhat.com>
-
- * Makefile.am (ALL_EMULATIONS): Add eh8300elf.o, eh8300elf.o and
- eh8300self.o .
- (eh8300elf.c, eh8300helf.c, eh8300self.c): New targets.
- * configure.tgt (h8300-*-elf*): New case.
- * emulparams/h8300elf.sh, emulparams/h8300helf.sh: New files.
- * emulparams/h8300self.sh: New file.
- * Makefile.in: Regenerated.
-
-2001-08-28 Nick Clifton <nickc@cambridge.redhat.com>
-
- * ldmain.c (main): Rename BSIZE to BufferSize to avoid collision
- with macro name.
-
-2001-08-27 Linus Nordberg <linus@swox.com>
- Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am (ALL_EMULATIONS): Add eelf64ppc.o and eelf64lppc.o.
- (eelf64ppc.c, eelf64lppc.c): Add make targets.
- Run "make dep-am"
- * Makefile.in: Regenerate.
- * configure.tgt: Add powerpc64 support. Move pdp11, pjl, pj
- entries to correct alphabetical position.
- * emulparams/elf64ppc.sh: New.
- * emulparams/elf64lppc.sh: New.
-
-2001-08-27 Nick Clifton <nickc@cambridge.redhat.com>
-
- * ldmain.c (main): Declare BSIZE as static.
-
-2001-08-23 Jakub Jelinek <jakub@redhat.com>
-
- * emultempl/elf32.em (place_orphan): Place orphan .rel* sections
- into .rel.dyn resp. .rela.dyn if combreloc.
- (get_script): If .x linker script is equal to .xn, only put it
- once into the binary.
- Add .xc and .xsc scripts.
- (parse_args): Handle -z combreloc and -z nocombreloc.
- * scripttempl/elf.sc (.rela.sbss): Fix a typo.
- For .xc and .xsc scripts put all .rel* or .rela* input sections
- but .rel*.plt and PLT-like sections into .rel.dyn resp. .rela.dyn.
- * genscripts.sh (GENERATE_COMBRELOC_SCRIPT): Set if SCRIPT_NAME
- is elf.
- Strip trailing whitespace from script.
- Generate .xc and .xsc scripts if requested.
- * ldmain.c (main): Initialize link_info.combreloc and
- link_info.spare_dynamic_tags.
- * lexsup.c (OPTION_SPARE_DYNAMIC_TAGS): Define.
- (ld_options): Add --spare-dynamic-tags option.
- (parse_args): Likewise.
- * ld.texinfo: Document -z combreloc and -z nocombreloc.
- * ldint.texinfo: Document .xc and .xsc linker scripts.
- * NEWS: Add notes about -z combreloc and SHF_MERGE.
-
-2001-08-22 H.J. Lu <hjl@gnu.org>
-
- * emulparams/elf32fr30.sh: Add a newline.
-
-2001-08-21 Andreas Jaeger <aj@suse.de>
-
- * deffilep.y: Add missing prototypes.
- * pe-dll.c: Likewise.
-
-2001-08-20 Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.c (insert_pad): Fix typos in last patch.
-
- * ldlang.c: When traversing lang_statement_union_type lists,
- consistently use "header.next" rather than "next".
- * mpw-eppcmac.c: Likewise.
- * emultempl/beos.em: Likewise.
- * emultempl/hppaelf.em: Likewise.
- * emultempl/pe.em: Likewise.
- * ldlang.h (union lang_statement_union): Remove "next" field.
-
- * ldlang.c (insert_pad): Use offsetof macro.
- (lang_size_sections): Always neuter padding statements.
- * emultempl/hppaelf.em (hppaelf_delete_padding_statements): Delete.
-
- * pe-dll.c (pe_dll_fill_sections): Correct type of "relax" param
- passed to lang_size_sections.
- (pe_exe_fill_sections): Likewise.
- * emultempl/pe.em (output_prev_sec_find): Copied from elf32.em.
- (gld_${EMULATION_NAME}_place_orphan): Merge from elf32.em.
-
-2001-08-18 Alan Modra <amodra@bigpond.net.au>
-
- * emultempl/aix.em: Formatting fixes.
-
-2001-08-18 Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.c (insert_pad): Make use of an existing pad statement if
- available. Move code calculating alignment, adjusting section
- alignment power, and adjusting dot to ..
- (size_input_section): .. here. Remove unused relax param.
- (lang_size_sections): Change boolean `relax' param to boolean *.
- Adjust call to size_input_section. Make use of insert_pad to
- place pad after the assignment statement. If relaxing, zap
- padding statements.
- (reset_memory_regions): Reset output_bfd section sizes too.
- (relax_again): Move to..
- (lang_process): ..here. Adjust call to lang_size_sections, and
- remove duplicated code.
- * ldlang.h (lang_size_sections): Change `relax' param to boolean *.
-
-2001-08-17 Alan Modra <amodra@bigpond.net.au>
-
- * ld.texinfo: Document that fill values now use the four least
- significant bytes.
- * emulparams/elf32fr30.sh (NOP): Update.
- * emulparams/elf32mcore.sh: Likewise.
- * emulparams/elf64_s390.sh: Likewise.
- * emulparams/elf_i386.sh: Likewise.
- * emulparams/elf_i386_be.sh: Likewise.
- * emulparams/elf_i386_chaos.sh: Likewise.
- * emulparams/elf_i386_ldso.sh: Likewise.
- * emulparams/elf_s390.sh: Likewise.
- * emulparams/elf_x86_64.sh: Likewise.
- * emulparams/i386moss.sh: Likewise.
- * emulparams/i386nw.sh: Likewise.
- * emulparams/m68kelf.sh: Likewise.
- * scripttempl/elf.sc: Update NOP comment.
- * scripttempl/elfi370.sc: Likewise.
- * scripttempl/elfm68hc11.sc: Likewise.
- * scripttempl/elfm68hc12.sc: Likewise.
- * scripttempl/nw.sc: Likewise.
-
-2001-08-15 Tom Rix <trix@redhat.com>
-
- * ldgram.y (saved_script_handle): Initialize to NULL.
- * ldmain.c (main): Change check on saved_script_handle.
-
-2001-08-14 Alan Modra <amodra@bigpond.net.au>
-
- * emultempl/elf32.em: Formatting fixes.
- (output_prev_sec_find): Test for bfd_ind_section too; do so by
- looking at sec->owner.
- (output_rel_find): Move function inside LDEMUL_PLACE_ORPHAN test.
- (gld${EMULATION_NAME}_place_orphan): Add a few comments. Remove
- unused code, and reorganize orphan section placement code.
-
- * ldlang.c (wild_doit): Rename to lang_add_section.
- * ldlang.h: Here too.
- * mpw-elfmips.c: And here.
- * emultempl/beos.em: And here.
- * emultempl/elf32.em: And here.
- * emultempl/hppaelf.em: And here.
- * emultempl/pe.em: And here.
-
-2001-08-13 Richard Henderson <rth@redhat.com>
-
- * emultempl/needrelax.em: New file.
- * emulparams/elf64_ia64.sh (EXTRA_EM_FILE): Reference it.
- * Makefile.am (eelf64_ia64.c): Depend on it.
- * Makefile.in: Rebuild.
-
-2001-08-13 Alan Modra <amodra@bigpond.net.au>
-
- * emultempl/elf32.em: For SEC_EXCLUDE sections, ensure that
- output_section is set non-NULL.
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Return
- `true' for SEC_EXCLUDE sections so that the generic code doesn't
- needlessly create an output_section_statement. Treat a correctly
- named output_section_statement with NULL bfd_section as compatible.
-
-2001-08-13 Hans-Peter Nilsson <hp@bitrange.com>
-
- * emultempl/generic.em: Support EXTRA_EM_FILE.
- (ld_${EMULATION_NAME}_emulation): Support emulation parameters
- LDEMUL_BEFORE_PARSE, LDEMUL_SYSLIB, LDEMUL_HLL,
- LDEMUL_AFTER_PARSE, LDEMUL_AFTER_OPEN, LDEMUL_AFTER_ALLOCATION,
- LDEMUL_SET_OUTPUT_ARCH, LDEMUL_CHOOSE_TARGET,
- LDEMUL_BEFORE_ALLOCATION, LDEMUL_GET_SCRIPT, LDEMUL_FINISH,
- LDEMUL_CREATE_OUTPUT_SECTION_STATEMENTS,
- LDEMUL_OPEN_DYNAMIC_ARCHIVE, LDEMUL_PLACE_ORPHAN,
- LDEMUL_SET_SYMBOLS, LDEMUL_PARSE_ARGS, LDEMUL_UNRECOGNIZED_FILE,
- LDEMUL_LIST_OPTIONS, LDEMUL_RECOGNIZED_FILE,
- LDEMUL_FIND_POTENTIAL_LIBRARIES.
-
-2001-08-12 Richard Henderson <rth@redhat.com>
-
- * scripttempl/elf.sc, scripttempl/elfd30v.sc,
- scripttempl/elfm68hc11.sc, scripttempl/elfm68hc12.sc,
- scripttempl/v850.sc: Keep .jcr data.
-
-2001-08-12 H.J. Lu <hjl@gnu.org>
- Andrew Haley <aph@cambridge.redhat.com>
- Nick Clifton <nickc@redhat.com>
-
- * ldgram.y (had_script): Change name to saved_script_handle.
- Change type to file handle.
- * ld.h (had_script): Rename and retype.
- * ldfile.c (ldfile_open_command_file): Save the file handle
- used in saved_script_handle.
- * lexsup.c (parse_args): Do not allow -c option to alter
- saved_script_handle.
- * ldmain.c (main): Print out the linker script used if
- --verbose is given. Check saved_script_handle to obtain the
- external linker script used, or if NULL, dump the builtin
- script.
- * ld.texinfo: Document that --verbose now dumps the linker
- script used, regardless of whether it was an internal or an
- external script.
-
-2001-08-10 Andreas Jaeger <aj@suse.de>
-
- * configure.in: Add -Wstrict-prototypes and -Wmissing-prototypes
- to build warnings.
- * configure: Regenerate.
-
-2001-08-09 Alan Modra <amodra@bigpond.net.au>
-
- * emultempl/elf32.em (output_prev_sec_find): Add missing prototype.
-
- * scripttempl/elf.sc: Move non-text .dynamic section before
- .plt/.got/.sdata* group.
- (OTHER_GOT_SECTIONS): Move to immediately after .got.
- (OTHER_SDATA_SECTIONS): Add.
- * emulparams/criself.sh: Use OTHER_SDATA_SECTIONS rather than
- OTHER_GOT_SECTIONS.
- * emulparams/crislinux.sh: Likewise.
- * emulparams/elf32b4300.sh: Likewise.
- * emulparams/elf32bmip.sh: Likewise.
- * emulparams/elf32bmipn32.sh: Likewise.
- * emulparams/elf32bsmip.sh: Likewise.
- * emulparams/elf32btsmip.sh: Likewise.
- * emulparams/elf32ebmip.sh: Likewise.
- * emulparams/elf32elmip.sh: Likewise.
- * emulparams/elf32l4300.sh: Likewise.
- * emulparams/elf32lmip.sh: Likewise.
- * emulparams/elf32lsmip.sh: Likewise.
- * emulparams/elf32ltsmip.sh: Likewise.
- * emulparams/elf64bmip.sh: Likewise.
- * emulparams/elf64btsmip.sh: Likewise.
- * emulparams/elf64ltsmip.sh: Likewise.
-
-2001-08-08 Alan Modra <amodra@bigpond.net.au>
-
- * genscripts.sh: Source the emulparams script before each output
- script is generated so that variables like `RELOCATING' may affect
- variables defined in the emulparams script.
-
-2001-08-04 Alan Modra <amodra@bigpond.net.au>
-
- * emultempl/aix.em: ldexp.h,ldlang.h,ldfile.h,ldemul.h go in this
- order.
-
- * emultempl/beos.em (sort_sections): Modify for 2001-08-03 change,
- ie. iterate over wild_statement.section_list.
- (gld${EMULATION_NAME}_place_orphan): Likewise.
-
-2001-08-03 Stephane Carrez <Stephane.Carrez@worldnet.fr>
-
- * scripttempl/elfm68hc12.sc (FINISH_CODE, FINISH_RELOC): New to handle
- .fini[0-4] sections used by _exit
- (CTOR, DTOR): Export ctor/dtor symbols; move them to ROM.
- (*.text,*.data,*.bss): Take into account .text.*, .data.*, .bss.*.
- * scripttempl/elfm68hc11.sc: Likewise.
-
-2001-08-03 H.J. Lu <hjl@gnu.org>
-
- * emultempl/beos.em (init): Add the missing initialization.
-
-2001-08-03 Alan Modra <amodra@bigpond.net.au>
-
- * ld.texinfo (Input Section Basics): Clarify ordering of output
- sections.
- * ldlang.c (callback_t): Add wildcard_list param.
- (walk_wild_section): Remove "section" param. Rewrite for
- lang_wild_statement_type change. Remove unique_section_p test.
- (walk_wild_file): Remove "section" param.
- (walk_wild): Remove "section" and "file" params.
- (lang_gc_wild): Likewise.
- (wild): Likewise. Modify for lang_wild_statement_type change.
- (wild_sort): Likewise. Add "sec" param.
- (gc_section_callback): Likewise.
- (output_section_callback): Likewise. Do unique_section_p test.
- (map_input_to_output_sections): Modify call to wild.
- (lang_gc_sections_1): Likewise.
- (print_wild_statement): Modify for lang_wild_statement_type
- change.
- (lang_add_wild): Replace filename, filenames_sorted param with
- filespec. Replace section_name, sections_sorted,
- exclude_filename_list with section_list.
- * ldlang.h (lang_add_wild): Here too.
- (lang_wild_statement_type): Replace section_name, sections_sorted,
- and exclude_filename_list with section_list.
- * ldgram.y (current_file): Delete.
- (%union): Add wildcard_list.
- (file_NAME_list): Set type to wildcard_list. Build a linked list
- rather than calling lang_add_wild for each entry.
- (input_section_spec_no_keep): Call lang_add_wild here instead.
- * ld.h (struct wildcard_list): Declare.
- * mri.c (mri_draw_tree): Modify to suit new lang_add_wild.
-
-2001-08-02 Charles Wilson <cwilson@ece.gatech.edu>
-
- * ldmain.c (main): initialize link_info.pei386_auto_import
- * pe-dll.c: new tables for auto-export filtering
- (auto_export): change API, pass abfd for contextual filtering.
- Loop thru tables of excluded symbols instead of comparing
- "by hand".
-
-2001-08-02 Paul Sokolovsky <paul.sokolovsky@technologist.com>
-
- * pe-dll.c: new variable pe_dll_enable_extra_debug. New
- static variable current_sec (static struct sec *). Add
- forward declaration for add_bfd_to_link.
- (process_def_file): Don't export undefined symbols. Do not
- export symbols starting with "_imp__". Call auto_export()
- with new API.
- (pe_walk_relocs_of_symbol): New function.
- (generate_reloc): add optional extra debugging
- (pe_dll_generate_def_file): eliminate extraneous initial blank
- line in output
- (make_one): enlarge symtab to make room for __nm__ symbols
- (DATA auto-import support).
- (make_singleton_name_thunk): New function.
- (make_import_fixup_mark): New function.
- (make_import_fixup_entry): New function.
- (pe_create_import_fixup): New function.
- (add_bfd_to_link): Specify that 'name' argument is a CONST
- char *.
- * pe-dll.h: declare new variable pe_dll_extra_pe_debug;
- declare new functions pe_walk_relocs_of_symbol and
- pe_create_import_fixup.
- * emultempl/pe.em: add new options --enable-auto-import,
- --disable-auto-import, and --enable-extra-pe-debug.
- (make_import_fixup): New function.
- (pe_find_data_imports): New function.
- (pr_sym): New function.
- (gld_${EMULATION_NAME}_after_open): Add optional extra pe
- debugging. Call pe_find_data_imports. Mark .idata as DATA, not
- CODE.
-
-2001-08-02 Charles Wilson <cwilson@ece.gatech.edu>
-
- * ld.texinfo: add additional documentation for
- --export-all-symbols. Document --out-implib,
- --enable-auto-image-base, --disable-auto-image-base,
- --dll-search-prefix, --enable-auto-import, and
- --disable-auto-import.
- * ldint.texinfo: Add detailed documentation on auto-import
- implementation.
-
-2001-07-30 Nick Clifton <nickc@cambridge.redhat.com>
-
- * ld.texinfo (Simple Assignments): Fix computation in SECTIONS
- example.
-
-2001-07-24 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: Update dependencies with "make dep-am".
- * Makefile.in: Regenerate
-
-2001-07-23 Alan Modra <amodra@bigpond.net.au>
-
- * ldcref.c (check_section_sym_xref): New function.
- (check_nocrossrefs): Call it.
- (check_nocrossref): Interate over h->refs here instead of..
- (check_refs): ..here. Pass in the symbol name, section, and bfd
- rather than hash_entry pointers.
- (struct check_refs_info): Keep symbol name rather than hash entry.
- Remove "same".
- (check_reloc_refs): Tweak for above changes in check_refs_info.
- Only report references to section syms when symname is NULL to
- prevent duplicate messages for the same reloc.
-
-2001-07-19 Nick Clifton <nickc@cambridge.redhat.com>
-
- * ldexp.c (exp_print_tree): Use stderr if config.map_file is not
- available. Do not print NULL trees.
- (exp_print_token): Print unknown tokens with values > 126 as
- decimal values not ASCII characters.
-
- * ldlang.c (lang_leave_overlay): If a region is specified assign
- it to all sections inside the overlay unless they have been
- assigned to the own, non-default, memory region.
-
- * README: Add header for consistency with other README files.
-
-2001-07-14 H.J. Lu <hjl@gnu.org>
-
- * emultempl/elf32.em (output_prev_sec_find): Never return
- bfd_abs_section_ptr, bfd_com_section_ptr nor
- bfd_und_section_ptr.
-
-2001-07-14 Nick Clifton <nickc@cambridge.redhat.com>
-
- * Makefile.am (em32relf.c): Change dependency from generic.em to
- elf32.em.
- * Makefile.in: Regenerate.
-
-2001-07-14 matthew green <mrg@eterna.com.au>
-
- * configure.tgt (i386-*-netbsdelf*): New target.
- (i386-*-netbsd*): Set targ_extra_emuls to `elf_i386'
-
-2001-07-13 Jakub Jelinek <jakub@redhat.com>
-
- * emultempl/elf32.em (output_prev_sec_find): New.
- (place_orphan): Use it.
-
-2001-07-11 H.J. Lu <hjl@gnu.org>
-
- * ldmain.c (main): Fix typos in the last change.
-
-2001-07-11 Jakub Jelinek <jakub@redhat.com>
-
- * ldmain.c (main): Disallow -F and -f without -shared.
-
-2001-07-11 Nick Clifton <nickc@cambridge.redhat.com>
-
- * emultempl/pe.em (after_open): Check for the output_bfd not
- having any coff_data structure allocated to it.
-
-2001-07-09 David O'Brien <obrien@FreeBSD.org>
-
- * emultempl/elf32.em: Do not assuming that contents of the buffer
- returned from basename function will remain unchanged accross other
- function calls.
-
-2001-07-03 H.J. Lu <hjl@gnu.org>
-
- * scripttempl/elf.sc (DYNAMIC_PAD): Revert the change made on
- 2001-07-03. It creates dynamic entries even for static binaries.
-
-2001-07-03 Jakub Jelinek <jakub@redhat.com>
-
- * scripttempl/elf.sc (DYNAMIC_PAD): New variable.
- (DYNAMIC): Use it to reserve few dynamic entries for
- post-linking tools.
-
-2001-06-27 Alan Modra <amodra@bigpond.net.au>
-
- * emulparams/hppa64linux.sh: New file.
- * configure.tgt: hppa*64*-*-linux* uses hppa64linux.sh
- * Makefile.am (ALL_64_EMULATIONS): Add ehppa64linux.o
- (ehppa64linux.c): Add rule to make it.
- Run "make dep-am".
- * Makefile.in: Regenerate.
-
-2001-06-21 Hans-Peter Nilsson <hp@axis.com>
-
- * ld.texinfo (Options, -r): Mention restrictions when using
- different object formats.
-
-2001-06-19 Hans-Peter Nilsson <hp@axis.com>
-
- * ldlang.c (lang_check): Emit fatal error if relocatable link
- between different object flavours with relocations in input.
-
-2001-06-19 H.J. Lu <hjl@gnu.org>
-
- * ld.texinfo (-E, --export-dynamic): Mention --version-script.
- (--version-script): Mention the language support.
-
-2001-06-19 H.J. Lu <hjl@gnu.org>
-
- * ldlang.c (lang_check): Revert the change mode on 2001-06-15.
-
-2001-06-18 H.J. Lu <hjl@gnu.org>
-
- * Makefile.am (ld.1): Remove the prefix `$(srcdir)/'.
- (diststuff): Add $(MANS).
- * Makefile.in: Regenerated.
-
- * ld.1: Removed.
-
-2001-06-18 Hans-Peter Nilsson <hp@axis.com>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation):
- Update for API change in bfd_elf${ELFSIZE}_size_dynamic_sections.
- * mpw-elfmips.c (gldelf32ebmip_before_allocation): Ditto.
- * ld.h (args_type): Remove member export_dynamic. All users
- changed to use struct bfd_link_info member.
-
- * Makefile.am (ecriself.c, ed10velf.c, ei386moss.c): Depend on
- $(srcdir)/emultempl/elf32.em, not $(srcdir)/emultempl/generic.em.
- * Makefile.in: Regenerate.
-
-2001-06-18 H.J. Lu <hjl@gnu.org>
-
- * ldlang.c (init_os): Add the newline to the einfo call.
- (lang_check): Likewise.
- (lang_do_version_exports_section): Likewise.
-
-2001-06-15 H.J. Lu <hjl@gnu.org>
-
- * lexsup.c (parse_args); Save optind to report unrecognized
- option.
-
-2001-06-15 Hans-Peter Nilsson <hp@axis.com>
-
- * ldlang.c (lang_check): Emit fatal error if relocatable link
- between different object flavours.
-
- * lexsup.c (parse_args) <case OPTION_EXPORT_DYNAMIC, case 'E'>:
- Set new link_info member export_dynamic.
- * ldmain.c (main): Initialize new link_info member export_dynamic.
-
-2001-06-12 Nick Clifton <nickc@cambridge.redhat.com>
-
- * ldlang.c (walk_wild): Only call walk_wild_file if
- lookup_name returns something.
- (lookup_name): If load_symbols fails, return NULL.
- (load_symbols): Change to a boolean function.
- (open_input_bfds): If load_symbols fails then do not make the
- executable.
-
-2001-06-08 Alan Modra <amodra@bigpond.net.au>
-
- * ldlang.c (record_bfd_errors): Remove.
-
- * emultempl/aix.em: Fix copyright dates.
-
-2001-06-07 Andreas Jaeger <aj@suse.de>
-
- * elf_x86_64.sh (NONPAGED_TEXT_START_ADDR): Increase.
- (TEXT_START_ADDR): Likewise.
-
-2001-06-06 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * configure.host: Set HOSTING_CRT0/HOSTING_LIBS correctly for s/390.
-
-2001-06-05 Danny Smith <danny_r_smith_2001@yahoo.co.nz>
-
- * emultempl/pe.em (init): Reduce default stack reserve to 0x200000.
-
-2001-05-31 H.J. Lu <hjl@gnu.org>
-
- * ldlang.c (open_input_bfds): Don't change the bfd error
- handler whilst loading symbols.
-
-2001-05-28 Nick Clifton <nickc@cambridge.redhat.com>
-
- * configure.tgt: Remove i370-mvs architecture, it is not currently
- supported.
-
-2001-05-25 H.J. Lu <hjl@gnu.org>
-
- * emulparams/ppcmacos.sh: Add SYSCALL_MASK and SYMBOL_MODE_MASK
- like emulparams/aixppc.sh.
-
-2001-05-25 H.J. Lu <hjl@gnu.org>
-
- * emultempl/beos.em (gld${EMULATION_NAME}_before_parse): Move
- setting of output_filename after bfd_scan_arch.
- * emultempl/pe.em: Likewise.
-
-2001-05-25 H.J. Lu <hjl@gnu.org>
-
- * emulparams/aixrs6.sh: Add SYSCALL_MASK and SYMBOL_MODE_MASK
- like emulparams/aixppc.sh.
-
- * emultempl/aix.em (sc): Use ${srcdir}/emultempl/ostring.sed
- instead of ${srcdir}/emultempl/stringify.sed.
-
-2001-05-25 Timothy Wall <twall@oculustech.com>
-
- * emulparams/elf64_aix.sh: Change settings to match IBM linker
- output.
-
-2001-05-25 Alan Modra <amodra@one.net.au>
-
- * configure.host: Replace linuxoldld with linux*oldld.
- * configure.tgt: Likewise.
-
-2001-05-24 H.J. Lu <hjl@gnu.org>
-
- * emultempl/stringify.sed: Removed again.
-
-2001-05-24 H.J. Lu <hjl@gnu.org>
-
- * emultempl/aix.em (OUTPUT_ARCH): Defined.
- (gld${EMULATION_NAME}_before_parse): Initialize
- ldfile_output_architecture, ldfile_output_machine and
- ldfile_output_machine_name from ${OUTPUT_ARCH} if possible.
- * emultempl/beos.em: Likewise.
- * emultempl/elf32.em: Likewise.
- * emultempl/linux.em: Likewise.
- * emultempl/mipsecoff.em: Likewise.
- * emultempl/pe.em: Likewise.
- * emultempl/sunos.em: Likewise.
-
-2001-05-24 Tom Rix <trix@redhat.com>
-
- * emultempl/aix.em : (gld${EMULATION_NAME}_read_file)
- udate import file format.
- (change_symbol_mode) New, same
- (is_syscall) New, same
- * emulparams/aixppc.sh : add SYSCALL_MASK and SYMBOL_MODE_MASK
- * emulparams/aixppc64.sh : same
- * emulparams/aixrs6.sh : same
- * emulparams/ppcmacos.sh : same
- * emultempl/aix.em : use strtoull to parse options
- * Makefile.am : add eaixppc64 emulation for xcoff64
- * Makefile.in : same
- * configure.tgt : same
-
- * scripttempl/aix.sc : default text section offset to 0x10000000
- default data section offset to 0x20000000
- add .sv3264 and .sv64 pseudo sections
- loader and debug sections use the currect section offset.
-
- * emultempl/aix.em : Add xcoff64 support
- Add -binitfini support
- (gld${EMULATION_NAME}_before_parse) -binitfini
- (gld${EMULATION_NAME}_parse_args) same
- (gld${EMULATION_NAME}_before_allocation) format change for special
- sections
-
- * emulparams/aixppc64.sh : New file for xcoff64 support
-
-2001-05-23 Alexandre Oliva <aoliva@redhat.com>
-
- * emultempl/elf32.em (ELF_INTERPRETER_SET_DEFAULT): Use this new
- variable to avoid non-portable shell construct.
-
-2001-05-23 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * ldmain.c (get_emulation): Add -mips5 command line argument.
-
-2001-05-22 Alexandre Oliva <aoliva@redhat.com>
-
- * emulparams/elf_i386_ldso.sh: New, copied from elf_i386.sh.
- (ELF_INTERPRETER_NAME): Define it.
- * emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation): Use
- it.
- * configure.tgt (targ_emul, targ_extra_emuls)
- [i[3456]86-*-solaris2*, i[3456]86-*-solaris*]: Use elf_i386_ldso
- as primary, elf_i386 as extra.
- * Makefile.am (ALL_EMULATIONS): Added eelf_i386_ldso.o.
- (eelf_i386_ldso.c): New rule.
- * Makefile.in: Rebuilt.
-
-2001-05-22 Nick Clifton <nickc@redhat.com>
-
- * lexsup.c (ld_options): Allow -I to be an alias for
- --dynamic-linker. This is for Solaris compatability.
- * ld.texinfo: Document that -I can be used.
- * ld.1: Regenerate.
-
-2001-05-16 Alan Modra <amodra@one.net.au>
-
- * ldlang.c (wild_doit): Use linker_has_input to reliably determine
- whether an input section is the first one assigned to an output
- section.
- Assorted formatting fixes.
-
-2001-05-14 DJ Delorie <dj@delorie.com>
-
- * Makefile.am (ld.dvi): Search bfd/doc for texinfo files.
- * Makefile.in: Ditto.
-
-2001-05-11 Jakub Jelinek <jakub@redhat.com>
-
- * emulparams/elf64_ia64.sh (OTHER_READONLY_SECTIONS): Put
- .gnu.linkonce.ia64unw{,i} sections into corresponding .IA_64.unwind*
- output sections.
- * emulparams/elf64_aix.sh (OTHER_READONLY_SECTIONS): Likewise.
-
-2001-05-11 Jakub Jelinek <jakub@redhat.com>
-
- * ldlang.c (lang_process): Call bfd_merge_sections.
-
-2001-05-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * ldgram.y: Fix typo.
-
-2001-05-03 H.J. Lu <hjl@gnu.org>
-
- * emultempl/elf32.em: Include "libiberty.h".
- (gld${EMULATION_NAME}_vercheck): Call basename () to get the
- basename of the bfd filename.
- (gld${EMULATION_NAME}_stat_needed): Likewise.
- (gld${EMULATION_NAME}_try_needed): Likewise.
- (gld${EMULATION_NAME}_open_dynamic_archive): Likewise.
-
-2001-05-02 H.J. Lu <hjl@gnu.org>
-
- * emultempl/pe.em: Include <ctype.h>.
-
-2001-05-02 Johan Rydberg <jrydberg@opencores.org>
-
- * emulparams/elf32openrisc.sh: New file.
-
- * Makefile.am: Add OpenRISC target.
- * Makefile.in: Regenerated.
-
- * configure.tgt: Add openrisc-*-* mapping.
-
-2001-05-02 Nick Clifton <nickc@redhat.com>
-
- * emultempl/aix.em: Replace buystring with xstrdup.
- * emultempl/beos.em: Replace buystring with xstrdup.
-
-2001-05-02 H.J. Lu <hjl@gnu.org>
-
- * ldfile.c: Include "libiberty.h".
- * ldlex.l: Likewise.
-
- * ldmisc.c (buystring): Removed.
- * ldmisc.h: Likewise.
-
- * ldfile.c: Replace buystring with xstrdup.
- * ldlang.c: Likewise.
- * ldlex.l: Likewise.
- * ldmain.c: Likewise.
- * ldmisc.c: Likewise.
- * lexsup.c: Likewise.
- * mpw-eppcmac.c: Likewise.
-
-2001-04-30 Andreas Jaeger <aj@suse.de>
-
- * emulparms/elf_x86_64.sh (MAXPAGESIZE): Fix value.
-
-2001-04-28 Paul Sokolovsky <Paul.Sokolovsky@technologist.com>
-
- * ldlang.c (load_symbols): Give emulation a chance
- to process unrecognized file before fatal error is
- reported, not after.
-
-2001-04-27 Sean McNeil <sean@mcneil.com>
-
- * configure.tgt: Add arm-vxworks target.
- * scripttempl/armcoff.sc: Support .text or .data as a section name
- prefix.
- Define _etext.
-
-2001-04-13 J.T. Conklin <jtc@redback.com>
-
- * ld.texinfo: Document --fatal-warnings.
- * ld.1: Regenerate.
-
- * ldmisc.c (vfinfo): Set flag to inhibit making executable if
- warnings have been turned into errors.
- * lexsup.c (OPTION_WARN_FATAL): Define.
- (ld_options): Entry for --fatal-warnings.
- (parse_args): Handle OPTION_WARN_FATAL.
- * ld.h (ld_config_type): Add fatal_warnings field.
-
-2001-04-13 Jakub Jelinek <jakub@redhat.com>
-
- * ldmain.c (main): Default to discard_sec_merge.
- * lexsup.c (OPTION_DISCARD_NONE): Define.
- (ld_options): Add --discard-none.
- (parse_args): Handle OPTION_DISCARD_NONE.
- * ldlang.c (wild_doit): SEC_MERGE should be set in the output
- section only if SEC_MERGE and SEC_STRINGS flags and entsize of
- all its input sections match.
-
-2001-04-05 Steven J. Hill <sjhill@cotw.com>
-
- * Makefile.am (ALL_EMULATIONS): Add eelf32ltsmip.o.
- (ALL_64_EMULATIONS): Add eelf64btsmip.o and eelf64ltsmip.o.
- (eelf32ltsmip.c): New target.
- (eelf64btsmip.c): Likewise.
- (eelf64ltsmip.c): Likewise.
- * Makefile.in: Regenerated.
-
- * configure.tgt (mips*el-*-linux-gnu): Uses traditional MIPS
- target.
- (mips*-*-linux-gnu*): Likewise.
-
- * emulparams/elf32ltsmip.sh: New. Traditional little endian
- MIPS taget.
- * emulparams/elf64btsmip.sh: New. Traditional 64bit big endian
- target.
- * emulparams/elf64ltsmip.sh: New. Traditional 64bit little
- endian target.
-
-2001-04-05 Hans-Peter Nilsson <hp@axis.com>
-
- * emulparams/criself.sh (EXECUTABLE_SYMBOLS): Cannot provide
- correct value of __Stext here.
- (TEXT_START_SYMBOLS): Define; always define __Stext, to start of
- .startup section.
-
- * emulparams/crislinux.sh: Remove FIXME.
-
-2001-04-02 Alan Modra <alan@linuxcare.com.au>
-
- * emulparams/hppalinux.sh (MAXPAGESIZE): Set to 64k.
- (TEXT_START_ADDR, TARGET_PAGE_SIZE): Likewise.
-
-2001-03-27 Hans-Peter Nilsson <hp@axis.com>
-
- * configure.tgt (cris-*-*): Change default emulation to criself.
- (cris-*-*aout*): New rule.
-
-2001-03-27 Matthew Wilcox <willy@ldl.fc.hp.com>
-
- * emulparams/hppalinux.sh (MAXPAGESIZE): Set to 0x4000.
- (TEXT_START_ADDR, TARGET_PAGE_SIZE): Ditto.
-
-2001-03-26 Andreas Jaeger <aj@suse.de>
-
- * ld.texinfo (Overview): Fix syntax in texi code.
-
-2001-03-25 Stephane Carrez <Stephane.Carrez@worldnet.fr>
-
- * ld.texinfo: Put @c man indications to generate the ld man page.
- When generating man, define all the variables. Define SEEALSO
- and SYNOPSIS. Re-organize some lines to avoid the cross references.
- * Makefile.am (MANCONF, TEXI2POD, POD2MAN): New variables.
- (ld.1): Generate from ld.texinfo.
- * Makefile.in: Regenerate.
-
-2001-03-23 Mark Elbrecht <snowball3@bigfoot.com>
-
- * scripttempl/i386go32.sc: Support the GCC flags '-ffunction-sections'
- and '-fdata-sections'. Set the VMA of STABS sections to zero.
-
-2001-03-17 Ulrich Drepper <drepper@redhat.com>
-
- * emultmpl/elf32.em (gld${EMULATION_NAME}_search_needed): If NAME
- is an absolute path look only for this file and not along the path.
-
-2001-03-17 Ulrich Drepper <drepper@redhat.com>
-
- * emultempl/elf32.em (OPTION_GROUP): New macro.
- Add new option Bgroup to longopts.
- (gld*_parse_args): Handle GROUP_OPTION and recognize -z defs.
- (gld*_list_options): Add -Bgroup and -z defs.
- * ld.1: Document -Bgroup and -z defs.
- * ld.texinfo: Likewise.
-
-2001-03-07 Michael Meissner <meissner@redhat.com>
-
- * scripttempl/elfd10v.sc (.rodata,.rodata1,.data1,.sdata): Deal
- with sections created by -fdata-sections.
- (.dynbss,.bss): Ditto.
-
-2001-03-05 Alan Modra <alan@linuxcare.com.au>
-
- * emultempl/m68kelf.em (m68k_elf_after_allocation): Call
- after_allocation_default, not gld..._before_allocation.
-
-2001-02-27 Alan Modra <alan@linuxcare.com.au>
-
- * configure.in (BFD_VERSION): New.
- (AM_INIT_AUTOMAKE): Use $BFD_VERSION.
- * configure: Regenerate.
- * Makefile.am: Run "make dep-am"
- * Makefile.in: Regenerate.
-
-2001-02-26 Timothy Wall <twall@cygnus.com>
-
- * emulparams/elf64_aix.sh: Add additional read-only sections;
- uncomment lines which are now required.
-
-2001-02-26 H.J. Lu <hjl@gnu.org>
-
- * ldlang.c (open_input_bfds): Set the bfd error handler so
- that problems can be caught whilst loading symbols.
- (record_bfd_errors): New function: Report BFD errors and mark
- the executable output as being invalid.
-
-2001-02-22 Timothy Wall <twall@cygnus.com>
-
- * configure.host: Add configuration for ia64-*-aix*.
- * Makefile.am (ALL_64_EMULATIONS): Add emulation for ia64-*-aix*.
- Add dependencies for eelf64_aix.c.
- * Makefile.in: Regenerate.
- * configure.tgt: Add ia64-*-aix* mapping.
- * emulparams/elf64_aix.sh: Add settings for elf64 on aix5.
- * testsuite/ld-bootstrap/bootstrap.exp: Exclude ia64 flavor from
- AIX-specific test.
-
-2001-02-20 H.J. Lu <hjl@gnu.org>
-
- * ldfile.c (ldfile_open_file): Set entry->search_dirs_flag to
- false if we found the file.
-
-2001-02-18 David O'Brien <obrien@FreeBSD.org>
-
- * configure.tgt: Add FreeBSD/Alpha, FreeBSD/x86-64, FreeBSD/ia64,
- FreeBSD/PowerPC, FreeBSD/arm, and FreeBSD/sparc64 entries.
-
-2001-02-18 lars brinkhoff <lars@nocrew.org>
-
- * Makefile.am: Add PDP-11 target.
- * configure.tgt: Likewise.
- * emulparams/pdp11.sh: New file.
-
-2001-02-17 David O'Brien <obrien@FreeBSD.org>
-
- * configure.host: Add a generic FreeBSD configuration entry such that
- all [modern] FreeBSD systems on all platforms will look the same.
-
-2001-02-14 H.J. Lu <hjl@gnu.org>
-
- * configure.tgt: Remove mention of earmelf_linux26.
-
-2001-02-13 Richard Henderson <rth@redhat.com>
-
- * emulparams/elf64_ia64.sh (OTHER_GOT_SYMBOLS): Remove.
-
-2001-02-13 H.J. Lu <hjl@gnu.org>
-
- * ldexp.h (node_type): Add etree_provided.
- * ldexp.c (exp_fold_tree): Handle etree_provided. Set the node
- type to etree_provided if defined by PROVIDE. Allow updating
- for etree_provided.
- (exp_print_tree): Handle etree_provided.
- * mpw-elfmips.c (gldelf32ebmip_find_exp_assignment): Handle
- etree_provided.
-
-2001-02-09 David Mosberger <davidm@hpl.hp.com>
-
- * emulparams/elf64_ia64.sh (OTHER_READONLY_SECTIONS): Add
- .IA_64.unwind.* pattern to unwind table section and
- .IA_64.unwind_info* pattern to unwind info section.
-
-2001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * Makefile.am: Add linux target for S/390.
- * Makefile.in: Likewise.
- * configure.host: Likewise.
- * configure.tgt: Likewise.
- * emulparams/elf64_s390.sh: New file.
- * emulparams/elf_s390.sh: New file.
-
-2001-02-09 Jakub Jelinek <jakub@redhat.com>
-
- * configure.tgt (sparc64-*-linux-gnu*): Add elf32_sparc into
- targ_extra_libpath.
- (sparc-*-linux-gnu*): Add elf64_sparc into targ_extra_libpath.
-
-2001-02-06 Philip Blundell <philb@gnu.org>
-
- * Makefile.am: Remove mention of earmelf_linux26.
- * Makefile.in: Regenerate.
-
-2001-02-04 Philip Blundell <philb@gnu.org>
-
- * emulparams/armelf_linux.sh (TEXT_START_ADDR): Set to 0x8000.
- * emulparams/armelf_linux26.sh: Delete.
- * configure.tgt: Remove mention of armelf_linux26 emulation.
-
-2001-02-01 Nick Clifton <nickc@redhat.com>
-
- * ld.1: Replace occurances of -oformat with --oformat.
-
-2001-01-25 Jim Driftmyer <jdrift@stny.rr.com>
-
- * ldlang.c (lang_leave_overlay): Don't set lma_region when
- load_base is specified.
-
-2001-01-24 Hans-Peter Nilsson <hp@axis.com>
-
- * emultempl/elf32.em: Correct spelling in comments and listed
- options.
-
-2001-01-23 Alan Modra <alan@linuxcare.com.au>
-
- * ldlang.c (lang_leave_overlay): Only set lma_region from the
- default for the first section of a group of overlay sections.
-
-2001-01-22 Alan Modra <alan@linuxcare.com.au>
-
- * Makefile.am (GENSCRIPTS): Pass exec_prefix.
- * Makefile.in: Regenerate.
- * genscripts.sh: Use exec_prefix parameter to specify tool lib.
- Check for null tool_dir.
-
-2001-01-16 Jim Wilson <wilson@redhat.com>
-
- * emulparams/elf64_ia64.sh (OTHER_READONLY_SECTIONS): Add IA_64.unwind
- and IA_64.unwind.info.
-
-2001-01-16 H.J. Lu <hjl@gnu.org>
-
- * ldlang.c (lang_check): Merge the private data only if the
- input file has contents.
-
-2001-01-14 Alan Modra <alan@linuxcare.com.au>
-
- * emulparams/hppalinux.sh (OUTPUT_FORMAT): Set to elf32-hppa-linux.
-
- * emultempl/hppaelf.em (hppaelf_after_parse): New function,
- enabling search for libmilli. On a relocatable link, make .text
- sections unique.
- (LDEMUL_AFTER_PARSE): Define.
- (hppaelf_finish): Correct spelling of relocatable in comments.
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Don't
- rummage through the script for sections on the unique list.
- Correct length of strncmp for ".note".
- (gld${EMULATION_NAME}_check_needed): Rearrange function.
-
- * ldlang.c (unique_section_list): New var.
- (unique_section_p): New function.
- (walk_wild_section): Don't match sections on unique_section_list.
- (lang_add_unique): New function.
- Correct spelling of relocatable in comments.
-
- * ldlang.h (struct unique_sections): Declare.
- (unique_section_list): Declare.
- (unique_section_p): Declare.
- (lang_add_unique): Declare.
-
- * lexsup.c (ld_options): Allow --unique to take an optional arg.
- (parse_args [OPTION_UNIQUE]): Call lang_add_unique.
-
- * ld.texinfo (--unique): Update.
-
-2001-01-13 Nick Clifton <nickc@redhat.com>
-
- * lexsup.c (parse_args): Remove spurious white space.
-
-2001-01-12 Nick Clifton <nickc@redhat.com>
-
- * lexsup.c (parse_args): Update copyright date.
-
-2001-01-12 Philip Blundell <pb@futuretv.com>
-
- * configure.host: Set HOSTING_LIBS appropriately for ix86-cygwin.
-
-2001-01-10 Kazu Hirata <kazu@hxi.com>
-
- * scripttempl/h8300.sc: Fix formatting. Fix a comment typo.
- * scripttempl/h8300h.sc: Fix formatting.
- * scripttempl/h8300s.sc: Likewise.
- * scripttempl/h8500.sc: Likewise.
- * scripttempl/h8500b.sc: Likewise.
- * scripttempl/h8500c.sc: Likewise.
- * scripttempl/h8500m.sc: Likewise.
- * scripttempl/h8500s.sc: Likewise.
-
-2000-01-07 David O'Brien <obrien@BSDi.com>
-
- * emultempl/elf32.em: Only perform Linux ld hints processing when
- targeting Linux.
-
-2001-01-07 Philip Blundell <philb@gnu.org>
-
- * ld.texinfo (Bug Reporting): Update email address for reports.
-
-2000-12-31 Nick Clifton <nickc@redhat.com>
-
- * lexsup.c (parse_args): Set opterr to 0 and detect unparsed long
- options by checking for a return value of '?' not -1.
-
-2000-12-28 Nick Clifton <nickc@redhat.com>
-
- * lexsup.c (struct ld_option): Add new enum value:
- EXACTLY_TWO_DASHES.
- (ld_options[]): Change -omagic, -output and -oformat options
- to be EXACTLY_TWO_DASHES.
- (OUTPUT_COUNT): Use ARRAY_SIZE.
- (parse_args): Change parameter 'argc' to unsigned.
- Place EXACTLY_TWO_DASHES options into new really_longopts
- array.
- If getopt_long_only fails, try calling getopt_long using the
- really_longopts array.
- (help): Print a double dash for both EXACTLY_TWO_DASHES and
- TWO_DASHES options.
-
- * ldlex.h: Fix prototype of parse_args.
-
- * ld.texinfo: Document that long options starting with 'o'
- must be preceeded by two dashes. Change example of a single
- dashed long option from -oformat to -trace-symbol.
-
-2000-12-26 Danny Smith <danny_r_smith_2001@yahoo.co.nz>
-
- * emultempl/pe.em (OPTION_NO_DEFAULT_EXCLUDES): Define.
- (longopts[]): New --no-default-excludes option.
- (gld_${EMULATION_NAME}_list_options): Document.
- (gld_${EMULATION_NAME}_parse_args): Handle.
-
-2000-12-13 Michael Sokolov <msokolov@ivan.Harhan.ORG>
-
- * ldlang.c (new_stat): Revert the last beautification with "innocent"
- whitespace, it breaks the K&R C preprocessor.
-
-2000-12-11 DJ Delorie <dj@redhat.com>
-
- * ld.texinfo: Add notes about --whole-archive and gcc.
-
-2000-11-18 Fred Fish <fnf@be.com>
-
- * lexsup.c (OPTION_ALLOW_SHLIB_UNDEFINED): Define.
- (ld_options): Entry for --allow-shlib-undefined.
- (parse_args): Handle OPTION_ALLOW_SHLIB_UNDEFINED.
- * ldmain.c (main): Initialize link_info.allow_shlib_undefined
- to false.
- * ld.texinfo: Document new command line switch.
-
-2000-12-12 Geoffrey Keating <geoffk@redhat.com>
-
- * emulparams/elf32ppc.sh (OTHER_READWRITE_SECTIONS):
- .fixup is actually read/write.
- * emulparams/elf32lppc.sh (OTHER_READWRITE_SECTIONS): Likewise.
- * emulparams/elf32ppcsim.sh (OTHER_READWRITE_SECTIONS): Likewise.
- * emulparams/elf32lppcsim.sh (OTHER_READWRITE_SECTIONS): Likewise.
-
-2000-12-11 Jan Hubicka <jh@suse.cz>
-
- * NEWS: Add note about x86_64 architecture.
-
-2000-12-06 Mark Elbrecht <snowball3@bigfoot.com>
-
- * scripttempl/i386go32.sc: Use PROVIDE with _etext, _edata, _end.
- Set DWARF2 sections to a VMA of zero.
-
-2000-12-01 Joel Sherrill <joel@OARcorp.com>
-
- * configure.tgt (arm-*-rtems*, a29k-*rtems*, h8300-*-rtems*):
- New targets.
- (sparc*-*-rtemself*, sparc*-*-rtemsaout*): New targets.
- (sparc*-*-rtems*): Switched from a.out to ELF.
-
-2000-11-30 Jan Hubicka <jh@suse.cz>
-
- * Makefile.am (ALL_EMULATIONS): Add eelf_x86_64.o
- (eelf_x86_64.c): New.
- * Makefile.in: Regenerate.
- * configure.tgt: Add support for x86_64-*-linux-gnu*.
- * emulparams/elf_x86_64.sh: New.
-
-2000-11-30 Hans-Peter Nilsson <hp@axis.com>
-
- * emulparams/crislinux.sh (ENTRY): Change back to _start.
- (TEXT_START_SYMBOLS): Remove conditional setting of __start.
-
- * scripttempl/crisaout.sc: Change all RELOCATING not related to
- merging non-a.out sections into CONSTRUCTING.
-
-2000-11-28 Nick Clifton <nickc@redhat.com>
-
- * ld.1 (COPYING): Mention that the GNU Free Documentation
- License is present in the sources, but not the output, and
- also available from the GNU website.
- (GNU Free Documentation License): Comment out this section.
-
-2000-11-28 David O'Brien <obrien@dragon.nuxi.com>
-
- * emulparams/elf64alpha.sh (ENTRY): Remove leading underscore as ELF
- does not use them.
-
-2000-11-25 David O'Brien <obrien@FreeBSD.org>
-
- * ld.1: Remove old date so it does not give the impression the manpage
- is way out of date.
-
-2000-11-24 Nick Clifton <nickc@redhat.com>
-
- * configure.tgt (xscale-coff): Add target.
- (xscale-elf): Add target.
-
-2000-11-24 Fred Fish <fnf@be.com>
-
- * ldmain.c (main): Remove redundant init of config.make_executable
- to true.
-
-2000-11-15 Richard Henderson <rth@redhat.com>
-
- * emulparams/elf64alpha.sh (MAXPAGESIZE): Typo -- 64k, not 1M.
-
-2000-11-14 Kazu Hirata <kazu@hxi.com>
-
- * scripttempl/h8300.sc: Fix formatting.
- * scripttempl/h8300h.sc: Likewise.
- * scripttempl/h8300s.sc: Likewise.
-
-2000-11-14 Denis Chertykov <denisc@overta.ru>
-
- * scripttempl/elf32avr.sc: Fix bug in .eeprom segment.
-
-2000-11-09 Philip Blundell <pb@futuretv.com>
-
- * emultempl/pe.em: Define ___start_SECNAME and ___stop_SECNAME
- around orphan sections whose names can be represented in C.
-
-2000-11-07 Jim Wilson <wilson@redhat.com>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): New local
- hold_sdata. If SEC_SMALL_DATA set, set place to hold_sdata.
-
-2000-11-06 Nick Clifton <nickc@redhat.com>
-
- * ld.texinfo: Add GNU Free Documentation License.
- * ldint.texinfo: Add GNU Free Documentation License.
- * ld.1: Add GNU Free Documentation License.
-
-2000-11-05 Alan Modra <alan@linuxcare.com.au>
-
- * ldlex.l (yy_create_string_buffer): Init yy_is_our_buffer,
- yy_is_interactive, yy_at_bol, and yy_fill_buffer.
-
- * Makefile.am (DISTCLEANFILES): Add stringify.sed.
- Move 2000-11-02 Makefile.in changes to this file.
- * Makefile.in: Regenerate.
-
-2000-11-03 Nick Clifton <nickc@redhat.com>
-
- * scripttempl/h8300.sc: Use ${CONSTRUCTING...} to enclose
- constructors and destructors.
- * scripttempl/h8300h.sc: Ditto.
- * scripttempl/h8300s.sc: Ditto.
- * scripttempl/h8500.sc: Ditto.
- * scripttempl/h8500b.sc: Ditto.
- * scripttempl/h8500c.sc: Ditto.
- * scripttempl/h8500m.sc: Ditto.
- * scripttempl/h8500s.sc: Ditto.
- * scripttempl/v850.sc: Ditto.
- * scripttempl/w65.sc: Ditto.
- * scripttempl/z8000.sc: Ditto.
-
-2000-11-02 Per Lundberg <plundis@chaosdev.org>
-
- * Makefile.in (e_i386_chaos.c): New rule.
- (ALL_EMULATIONS): Added e_i386_chaos.o.
- * emulparams/elf_i386_chaos.sh: New file.
- * configure.tgt: Recognise i[3456]86-chaosdev-storm-chaos.
-
-2000-10-20 Jakub Jelinek <jakub@redhat.com>
-
- * emulparams/elf64_sparc.sh (TEXT_START_ADDR,
- NONPAGED_TEXT_START_ADDR): Set to 4GB for Solaris targets.
- Fix sed invocation, so that it coped with '/' in Solaris 64bit
- library path suffix.
- Based on patch by Andrew Macleod <amacleod@cygnus.com>.
-
-2000-10-18 Hans-Peter Nilsson <hp@axis.com>
-
- * scripttempl/crisaout.sc (.text, .data): Pad, with ALIGN (32),
- for consecutive sections.
-
-2000-10-17 Chandrakala Chavva <cchavva@redhat.com>
-
- * lexsup.c: New option OPTION_TARGET_HELP. Prints all target specific
- options.
- * ld.texinfo: Added notes about this new option.
-
-2000-10-16 Nick Clifton <nickc@redhat.com>
-
- * emultempl/pe.em (_after_open): Add tests of return values from
- bfd functions. Emit appropriate error messages if necessary.
-
-2000-10-13 Nick Clifton <nickc@redhat.com>
-
- * emultempl/pe.em (_after_open): Delete 'is2' and 'nsyms'
- local variables - they are not used, but leave in the call to
- bfd_canonicalize_symtab.
- (_open_dynamic_archive): Add #ifdef DLL_SUPPORT around use of
- pe_dll_search_prefix.
-
-2000-10-12 Charles Wilson <cwilson@ece.gatech.edu>
-
- * emultempl/pe.em (pe_dll_search_prefix): New variable,
- (longopts): New --dll-search-prefix option.
- (gld_${EMULATION_NAME}_list_options): Document.
- (gld_${EMULATION_NAME}_parse_args): Handle.
- (gld_${EMULATION_NAME}_open_dynamic_archive): When linking
- dynamically, search for a dll named '<prefix><basename>.dll'
- in preference to 'lib<basename>.dll' if --dll-search-prefix
- is specified.
-
-2000-10-12 Alan Modra <alan@linuxcare.com.au>
-
- * ldlang.c (section_already_linked): Set kept_section instead of
- sec->comdat->sec.
-
-2000-10-10 Kazu Hirata <kazu@hxi.com>
-
- * deffile.h: Fix formatting.
- * lexsup.c: Likewise.
- * mri.c: Likewise.
-
-2000-10-09 Paul Sokolovsky <Paul.Sokolovsky@technologist.com>
-
- * pe-dll.c (make_one): Do not generate code thunk for DATA
- exports.
- (process_def_file): deduce DATA flag for auto-export sumbols.
-
-2000-10-09 Kazu Hirata <kazu@hxi.com>
-
- * ld.h: Fix formatting.
- * ldcref.c: Likewise.
- * ldctor.h: Likewise.
- * ldemul.c: Likewise.
- * ldemul.h: Likewise.
- * ldexp.c: Likewise.
- * ldexp.h: Likewise.
- * ldfile.c: Likewise.
- * ldfile.h: Likewise.
- * ldlang.c: Likewise.
- * ldlang.h: Likewise.
- * ldmain.c: Likewise.
- * pe-dll.c: Likewise.
-
- * pe-dll.c: Revert some formatting fixes.
-
-2000-10-08 Kazu Hirata <kazu@hxi.com>
-
- * pe-dll.c: Fix formatting.
-
-2000-10-05 Kazu Hirata <kazu@hxi.com>
-
- * ldlang.c: Fix formatting.
-
-2000-10-03 DJ Delorie <dj@redhat.com>
-
- * pe-dll.c (fill_edata): initialize entire block
- (make_one): fill in correct section.
-
-2000-10-03 Kazu Hirata <kazu@hxi.com>
-
- * ldexp.c: Fix formatting.
-
-2000-10-02 DJ Delorie <dj@redhat.com>
-
- * emultempl/pe.em (gld_*_after_open): detect case where there two
- import libraries for same dll; rename one to ensure proper link
- order.
-
- * pe-dll.c (process_def_file): compare ordinals to -1, not 0; fix
- typo
- (generate_edata): fix typo
-
-2000-09-29 Hans-Peter Nilsson <hp@axis.com>
-
- * scripttempl/crisaout.sc (ENTRY): Now __start.
- (.text): Add default setting for __start.
- Remove CONSTRUCTORS handling.
- (/DISCARD/): Add .gnu.warning.*.
- * emulparams/crislinux.sh (ENTRY): Now __start.
- (TEXT_START_SYMBOLS): New; provide __Stext and __start default.
- * emulparams/criself.sh (OUTPUT_FORMAT): Now elf32-us-cris.
- (ENTRY): Now __start.
- (INITIAL_READONLY_SECTIONS): Add KEEP for .startup.
- (EXECUTABLE_SYMBOLS): Add default setting for __start.
-
-2000-09-29 Kazu Hirata <kazu@hxi.com>
-
- * deffile.h: Fix formatting.
- * ld.h: Likewise.
- * ldcref.c: Likewise.
- * ldctor.c: Likewise.
- * ldctor.h: Likewise.
- * ldemul.c: Likewise.
- * ldemul.h: Likewise.
- * ldexp.c: Likewise.
- * ldexp.h: Likewise.
- * ldfile.c: Likewise.
- * ldfile.h: Likewise.
- * ldlang.c: Likewise.
- * ldlang.h: Likewise.
- * lexsup.c: Likewise.
- * mri.c: Likewise.
- * pe-dll.c: Likewise.
-
-2000-09-28 Paul Sokolovsky <Paul.Sokolovsky@technologist.com>
-
- * pe-dll.c (process_def_file): Uninitialized data wasn't
- exported with --export-all-symbols switch.
-
-2000-09-28 DJ Delorie <dj@redhat.com>
-
- * pe-dll.c (fill_edata): rearrange the data so that ordinals and
- noname work properly.
-
-2000-09-28 Alan Modra <alan@linuxcare.com.au>
-
- * ld.texinfo (HPPA ELF32): New section.
-
- * emultempl/hppaelf.em (group_size): New.
- (hppaelf_finish): Pass group_size to elf32_hppa_size_stubs.
- (PARSE_AND_LIST_PROLOGUE): Add OPTION_STUBGROUP_SIZE.
- (PARSE_AND_LIST_LONGOPTS): Add --stub-group-size. Duplicate
- options to prevent abbreviations matching.
- (PARSE_AND_LIST_OPTIONS): Describe the above. Reformat.
- (PARSE_AND_LIST_ARGS_CASES): Handle it.
-
-2000-09-21 Michael Sokolov <msokolov@ivan.Harhan.ORG>
-
- * emultempl/m68kelf.em: Conditionalise the embedded relocs feature
- on the m68*-*-elf target. Make it support COFF input objects.
-
-2000-09-21 Kazu Hirata <kazu@hxi.com>
-
- * ldmain.c: Fix formatting.
- * ldmisc.c: Likewise.
- * ldver.c: Likewise.
- * ldwrite.c: Likewise.
-
-2000-09-21 Alan Modra <alan@linuxcare.com.au>
-
- * ldwrite.c (clone_section): Silence gcc warnings.
-
-2000-09-20 Alan Modra <alan@linuxcare.com.au>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Handle
- out of memory failure.
-
- * ldwrite.c (ldwrite): Remove unnecessary einfo arg.
- (clone_section): Handle out of memory failures. Rename var to
- avoid c++ reserved word.
-
-2000-09-18 Alan Modra <alan@linuxcare.com.au>
-
- * emultempl/hppaelf.em (hppaelf_add_stub_section): Rename
- stub_name param to stub_sec_name.
- (hppaelf_finish): Modify call to elf32_hppa_size_stubs.
-
-2000-09-10 Michael Sokolov <msokolov@ivan.Harhan.ORG>
-
- * emultempl/m68kelf.em: New file.
- * emulparams/m68kelf.sh (EXTRA_EM_FILE): Use it.
- * Makefile.am (em68kelf.c): Add dependency on m68kelf.em.
- * Makefile.in: Regenerate.
-
-2000-09-15 Alan Modra <alan@linuxcare.com.au>
-
- * emulparams/hppalinux.sh (DATA_START_SYMBOLS): Provide $global$
- only as needed.
-
-2000-09-13 Nick Clifton <nickc@redhat.com>
-
- * ldmain.c (multiple_definition): Disable relaxation if
- multiple symbol definitions are encountered - otherwise the
- linker could abort with an assertion failure.
-
-2000-09-10 Nick Clifton <nickc@redhat.com>
-
- * mri.c: Fix formatting.
-
-2000-09-07 H.J. Lu <hjl@gnu.org>
-
- * configure.in (AC_ISC_POSIX): Put after AC_CANONICAL_SYSTEM.
- * configure: Rebuild.
-
-2000-09-07 H.J. Lu <hjl@gnu.org>
-
- * Makefile.am (lexsup.o): Also depend on $(INCDIR)/demangle.h.
- * Makefile.in: Rebuild.
-
-2000-09-07 Alan Modra <alan@linuxcare.com.au>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Fix
- broken list handling. Create __start_SECNAME and __stop_SECNAME
- when no place-holder. Add some comments. Test both SEC_CODE and
- SEC_READONLY for hold_text to prevent .rodata orphan poisoning.
- Handle case where no output section statement created.
-
-2000-09-07 Niibe Yutaka <gniibe@m17n.org>, Kaz Kojima <kkojima@rr.iij4u.or.jp>, Alexandre Oliva <aoliva@redhat.com>
-
- * configure.tgt (sh-*-linux*): Added.
- * Makefile.am: Added eshelf_linux and eshlelf_linux.
- * Makefile.in: Rebuilt.
- * emulparams/shelf_linux.sh: New file.
- * emulparams/shlelf_linux.sh: New file.
-
-2000-09-06 Alan Modra <alan@linuxcare.com.au>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Don't
- try shuffling sections when the orphan happens to be the place
- holder. Keep count of unique section names generated so we speed
- the search for a new name.
-
-2000-09-06 Alexandre Oliva <aoliva@redhat.com>
-
- * configure: Rebuilt with new libtool.m4.
-
-2000-09-05 Nick Clifton <nickc@redhat.com>
-
- * Makefile.in: Regenerate.
- * aclocal.m4: Regenerate.
- * configure: Regenerate.
- * config.in: Regenerate.
- * po/ld.pot: Regenerate.
-
- * ldint.texinfo: Remove CVS revision marker - it foils local
- comparisons.
-
- * emultempl/ticoff.em: Remove extraneous comma.
-
-2000-09-05 Alan Modra <alan@linuxcare.com.au>
-
- * emultempl/hppaelf.em (hppaelf_add_stub_section): Add SEC_RELOC
- to stub section flags.
- (hppa_for_each_input_file_wrapper): New.
- (hppa_lang_for_each_input_file): New.
- (lang_for_each_input_file): Define to call above.
- (multi_subspace): New.
- (hppaelf_finish): Pass multi_subspace to elf32_hppa_size_stubs.
- (PARSE_AND_LIST_PROLOGUE): Define.
- (PARSE_AND_LIST_LONGOPTS): Define.
- (PARSE_AND_LIST_OPTIONS): Define.
- (PARSE_AND_LIST_ARGS_CASES): Define.
- (hppaelf_finish): Call elf32_hppa_set_gp.
- (hppaelf_set_output_arch): Remove.
- (LDEMUL_SET_OUTPUT_ARCH): Remove.
-
- * emulparams/hppalinux.sh (ELFSIZE): Define.
- (MACHINE): Define.
- (OTHER_READONLY_SECTIONS): Define.
- (DATA_PLT): Define.
- (GENERATE_SHLIB_SCRIPT): Define.
-
- * ldlang.c: Add missing prototypes, and tidy others. Change CONST
- to const throughout. Change `void *' to `PTR' throughout.
- (lang_memory_default): Function is local to file, add `static'.
-
- * Makefile.am (ehppaelf.c): Depend on emultempl/elf32.em.
- (ehppalinux.c): Likewise.
- (earmelf.c): Likewise.
- (earmelf_linux.c): Likewise.
- (earmelf_linux26.c): Likewise.
- * Makefile.in: Regenerate.
-
- * ld.h (ld_config_type): Add unique_orphan_sections.
- * lexsup.c (OPTION_UNIQUE): Define.
- (ld_options): Add "--unique".
- (parse_args): Handle it.
- * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Don't
- search for an existing output section if unique_orphan_sections is
- set. Make use of bfd_get_unique_section_name rather than
- duplicating code here.
- * ld.texinfo: Describe --unique.
-
- * lexsup.c (ld_options): Make split-by-reloc arg optional. Add
- optional arg to split-by-file.
+ * emultempl/sh64elf.em: Likewise.
+
+ 2004-03-25 Alan Modra <amodra@bigpond.net.au>
+ * emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation): Update
+ size_dynamic_sections call.
+
+ 2004-03-20 H.J. Lu <hongjiu.lu@intel.com>
+ * lexsup.c (parse_args): Don't set unresolved_syms_in_objects
+ or unresolved_syms_in_shared_libs for -Bdynamic and -Bstatic.
+
+ 2004-03-18 Alan Modra <amodra@bigpond.net.au>
+ * ld.texinfo: Add --as-needed doco.
+ * ldmain.c (as_needed): New global var.
+ * ldmain.h (as_needed): Declare.
+ * lexsup.c (option_values): Add OPTION_AS_NEEDED and
+ OPTION_NO_AS_NEEDED.
+ (ld_options): Likewise.
(parse_args): Handle them.
- * ld.texinfo: Update description of these options.
- * ldwrite.c (clone_section): Pass in the section name. Replace
- local code with bfd_get_unique_section_name.
- (split_sections): Tidy code and comments. Use a list traversal
- more appropriate to the list construction. Handle cooked section
- sizes. Split when split_by_reloc reached rather than exceeded.
- Track section size and split when split_by_file reached. Fix
- link_order_tail (even though it's not used).
- (ldwrite): Modify condition for calling split_sections to suit
- changed split_by_reloc and split_by_file.
- * ldmain.c (main): Init config.split_by_reloc and
- config.split_by_file to -1.
- * ld.h (ld_config_type): Change split_by_reloc to unsigned.
- Change split_by_file to bfd_size_type.
-
-2000-09-02 Nick Clifton <nickc@redhat.com>
-
- * configure.in: Increase version number to 2.10.91.
- * NEWS: Mention new ability to support removal of duplicate DWARF2
- debug information.
- * configure: Regenerate.
- * aclocal.m4: Regenerate.
- * config.in: Regenerate.
-
-2000-09-02 Daniel Berlin <dberlin@redhat.com>
-
- * scripttempl/elf.sc: Add .gnu.linkonce.wi.* to .debug_info
- sections.
- * scripttempl/elf32avr.sc: Ditto.
- * scripttempl/elfd10v.sc: Ditto.
- * scripttempl/elfd30v.sc: Ditto.
- * scripttempl/elfi370.sc: Ditto.
- * scripttempl/elfm68hc11.sc: Ditto.
- * scripttempl/elfm68hc12.sc: Ditto.
- * scripttempl/elfi386beos.sc: Ditto.
- * scripttempl/v850.sc: Ditto.
-
-2000-08-31 Alexandre Oliva <aoliva@redhat.com>
-
- * acinclude.m4: Include libtool and gettext macros from the
- top level.
- * aclocal.m4, configure: Rebuilt.
-
-2000-08-25 Nick Clifton <nickc@redhat.com>
-
- * ldlang.c (open_output): When choosing the target for a
- particular endianness, do nothing if the target is not
- supported.
-
-2000-08-25 H.J. Lu <hjl@gnu.org>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Don't
- check -rpath nor LD_RUN_PATH for cross link.
- * ld.texinfo: Document the change.
-
-2000-08-24 Hans-Peter Nilsson <hp@axis.com>
-
- * NEWS: Mention support for CRIS.
-
-2000-08-23 H.J. Lu <hjl@gnu.org>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Get
- the current runpath list from bfd_elf_get_runpath_list ()
- before search.
-
-2000-08-22 H.J. Lu <hjl@gnu.org>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Search
- the DT_RPATH/DT_RUNPATH entries for DT_NEEDED after
- LD_LIBRARY_PATH for native linker. Display the needed DSO if
- trace_file_tries is non-zero.
- (gld${EMULATION_NAME}_try_needed): Report the needed DSO found
- if trace_file_tries is non-zero.
-
- * ld.texinfo: Document the usage of DT_RPATH/DT_RUNPATH.
- * NEWS: Mention it.
-
-2000-08-14 Jason Eckhardt <jle@cygnus.com>
-
- * NEWS: Mention i860 support.
-
-2000-08-14 Andreas Schwab <schwab@suse.de>
-
- * scripttempl/elf.sc: Fix last change to use correct comment
- syntax.
-
-2000-08-10 Geoff Keating <geoffk@cygnus.com>
-
- * scripttempl/elf.sc: Add a comment giving the correspondence
- between sections, per-datum sections, and linkonce sections. Make
- the comment true even for .bss, .sdata, .sdata2, .sbss, and
- .sbss2.
-
-2000-08-10 Jason Eckhardt <jle@cygnus.com>
-
- * emulparams/elf32_i860.sh: New file.
- * configure.tgt: Recognize new target i860-stardent-{sysv4*|elf*}.
- * Makefile.am (ALL_EMULATIONS): Add eelf32_i860.o.
- (eelf32_i860.c): New rule.
- * Makefile.in: Regenerate.
-
-2000-08-10 Nick Clifton <nickc@cygnus.com>
-
- * emulparams/mipspe.sh (ENTRY): Add definition.
-
-2000-08-08 Peter Jeremy <peter.jeremy@alcatel.com.au>
-
- * emultempl/elf32.em (_after_close): Refer to -rpath not --rpath
- in error message.
+ * ldlang.h (lang_input_statement_type): Add as_needed field.
+ * ldlang.c (new_afile): Set p->as_needed.
+ * emultempl/elf32.em (gld${EMULATION_NAME}_load_symbols): New function.
+ (gld${EMULATION_NAME}_try_needed): Use bfd_elf_set_dyn_lib_class.
+ (ld_${EMULATION_NAME}_emulation): Set LDEMUL_RECOGNIZED_FILE entry.
+ * ldlang.c (open_input_bfds): Remove useless cast.
+ (lang_do_assignments_1): Likewise.
+ (lang_for_each_input_section): Delete.
-2000-08-08 Stephane Carrez <Stephane.Carrez@worldnet.fr>
+2004-03-23 Alan Modra <amodra@bigpond.net.au>
- * scripttempl/elfm68hc11.sc: Define __bss_size symbol to indicate
- the final size of .bss section.
- * scripttempl/elfm68hc12.sc: Likewise.
+ PR 51.
+ * emultempl/ppc64elf.em (ppc_create_output_section_statements): Set
+ link_info.wrap_char.
-2000-08-04 Alan Modra <alan@linuxcare.com.au>
+2004-03-17 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
- * emultempl/elf32.em (gld_${EMULATION_NAME}_parse_args): Rename to
- gld${EMULATION_NAME}_parse_args for consistency. Combine
- lastoptind and prevoptind vars, and keep track of last optind.
- (gld_${EMULATION_NAME}_list_options): Rename to
- gld${EMULATION_NAME}_list_options.
+ * configure.tgt: Switch sh-*-rtems* to ELF. Add sh-*-rtemscoff*.
-2000-08-03 Rodney Brown <RodneyBrown@pmsc.com>
+2004-03-05 Nathan Sidwell <nathan@codesourcery.com>
- * configure.tgt: Select targ_emul=elf_i386 for Unixware 7
- (i586-sco-sysv5uw7.1.0).
+ * ldlang.c (lang_add_section): Don't force SEC_LOAD on
+ SEC_THREAD_LOCAL.
+ (IGNORE_SECTION): Ignore .tbss sections too.
+ (lang_size_sections_1): .tbss sections do not advance dot.
-2000-07-27 H.J. Lu <hjl@gnu.org>
+2004-02-23 Nathan Sidwell <nathan@codesourcery.com>
- * emulparams/elf64alpha.sh (PARSE_AND_LIST_ARGS): Removed.
- (PARSE_AND_LIST_PROLOGUE): New.
- (PARSE_AND_LIST_LONGOPTS): Likewise.
- (PARSE_AND_LIST_OPTIONS): Likewise.
- (PARSE_AND_LIST_ARGS_CASES): Likewise.
- (PARSE_AND_LIST_EPILOGUE): Likewise.
+ * ldlang.h (struct lang_output_section_state): Change processed
+ field's type.
+ * ldexp.c (check, invalid): Remove.
+ (fold_name): Move valid_p assignments. Create undefined symbol
+ when needed. Directly exampine section's processd flag.
+ * ldlang.c (lang_output_section_statement_lookup): Adjust
+ processed field init.
+ (lang_size_sections_1): Allow LOADADDR when determining section's
+ VMA. Adjust error message. Fold data statement's expr.
+ (lang_size_sections): Correctly increment lang_statement_iteration.
-2000-07-28 Alan Modra <alan@linuxcare.com.au>
+2004-02-23 Alan Modra <amodra@bigpond.net.au>
- * emultempl/armelf.em: Elide functions common to elf32.em,
- ie. most of the file.
- (arm_elf_after_open): New. Do arm specific things then call
- gld${EMULATION_NAME}_after_open.
- (arm_elf_before_allocation): New. Call
- gld${EMULATION_NAME}_before_allocation then do arm specifics.
- (PARSE_AND_LIST_PROLOGUE): Define.
- (PARSE_AND_LIST_SHORTOPTS): Define.
- (PARSE_AND_LIST_LONGOPTS): Define.
- (PARSE_AND_LIST_OPTIONS): Define.
- (PARSE_AND_LIST_ARGS_CASES): Define.
- (LDEMUL_AFTER_OPEN): Define.
- (LDEMUL_BEFORE_ALLOCATION): Define.
- (LDEMUL_BEFORE_PARSE): Define.
- (LDEMUL_FINISH): Define.
+ * ldexp.c (fold_tree): Follow indirect symbols.
- * emultempl/hppaelf.em: Similarly zap most of this file.
- (hppaelf_add_stub_section): Prototype.
- (hppaelf_layaout_sections_again): Prototype.
- (hook_in_stub): Prototype.
- (LDEMUL_SET_OUTPUT_ARCH): Define.
- (LDEMUL_FINISH): Define.
- (LDEMUL_CREATE_OUTPUT_SECTION_STATEMENTS): Define.
+2004-02-20 Nathan Sidwell <nathan@codesourcery.com>
- * emulparams/armelf.sh (TEMPLATE_NAME): Use elf32.
- (EXTRA_EM_FILE): New.
- * emulparams/armelf_linux.sh: Likewise.
- * emulparams/armelf_linux26.sh: Likewise.
- * emulparams/hppalinux.sh: Likewise.
- * emulparams/hppaelf.sh: Likewise.
- (NOP): Define.
+ * ldgram.y (exp): Add two operand ALIGN.
+ * ldexp.c (fold_binary): Add ALIGN_K case.
+ * ld.texinfo (ALIGN): Document two operand version.
- * emultempl/elf32.em: Fix formatting.
- (EXTRA_EM_FILE): Source it.
- (LDEMUL_BEFORE_PARSE, LDEMUL_SYSLIB, LDEMUL_HLL,
- LDEMUL_AFTER_PARSE, LDEMUL_AFTER_OPEN, LDEMUL_AFTER_ALLOCATION,
- LDEMUL_SET_OUTPUT_ARCH, LDEMUL_CHOOSE_TARGET,
- LDEMUL_BEFORE_ALLOCATION, LDEMUL_GET_SCRIPT, LDEMUL_FINISH,
- LDEMUL_CREATE_OUTPUT_SECTION_STATEMENTS,
- LDEMUL_OPEN_DYNAMIC_ARCHIVE, LDEMUL_PLACE_ORPHAN,
- LDEMUL_SET_SYMBOLS, LDEMUL_PARSE_ARGS, LDEMUL_UNRECOGNIZED_FILE,
- LDEMUL_LIST_OPTIONS, LDEMUL_RECOGNIZED_FILE,
- LDEMUL_FIND_POTENTIAL_LIBRARIES): New shell vars. Add code to
- allow functions in this file to be overridden.
- (PARSE_AND_LIST_SHORTOPTS): Handle it.
+2004-02-19 Nathan Sidwell <nathan@codesourcery.com>
- * emultempl/m68kcoff.em: Include ldfile.h before ldemul.h.
-
- * emultempl/elf32.em: Reorganize file.
-
-2000-07-27 Ivan Kokshaysky <ink@jurassic.park.msu.ru>
-
- * emulparams/elf64alpha.sh: Implement "-taso" emulation
- specific option to fit 64-bit executable in the lower
- 31-bit address range. This is done by changing start
- address of .interp (the very first section of executable)
- and then setting EF_ALPHA_32BIT elf header flag.
-
-2000-07-21 Michael Sokolov <msokolov@ivan.Harhan.ORG>
-
- * emultempl/m68kcoff.em: New file.
- * emulparams/m68kcoff.sh (TEMPLATE_NAME): Use m68kcoff template.
- * Makefile.am (em68kcoff.c): Depend on m68kcoff.em rather than
- generic.em.
- * Makefile.in: Regenerate.
-
-2000-07-20 H.J. Lu <hjl@gnu.org>
-
- * emultempl/elf32.em (longopts): Duplicate "disable-new-dtags"
- and "disable-new-dtags" to stop getopt from treating -d/-e as
- abbreviations for these options.
-
-2000-07-20 H.J. Lu <hjl@gnu.org>
-
- * ld.texinfo: Add documentation for --disable-new-dtags and
- --enable-new-dtags.
-
- * ldmain.c (main): Initialize link_info.new_dtags to false.
-
- * emultempl/elf32.em (gld_${EMULATION_NAME}_parse_args): Add
- --disable-new-dtags and --enable-new-dtags.
- (gld_${EMULATION_NAME}_list_options): Likewise.
-
-2000-07-05 Kenneth Block <krblock@computer.org>
-
- * lexsup.c: Add optional style to demangle switch
- * ld.texinfo: Document optional style to demangle switch.
-
-2000-07-20 Hans-Peter Nilsson <hp@axis.com>
-
- * Makefile.am (ALL_EMULATIONS): Add ecrisaout.o, ecriself.o,
- ecrislinux.o.
- (ecrisaout.c, ecriself.c, ecrislinux.c): New rules.
- Regenerate dependencies.
- * Makefile.in: Rebuild.
- * configure.tgt (cris-*-*): New target.
- * emulparams/crisaout.sh, emulparams/criself.sh,
- emulparams/crislinux.sh, scripttempl/crisaout.sc: New files.
- * po/POTFILES.in, po/ld.pot: Regenerate.
-
-2000-07-20 H.J. Lu <hjl@gnu.org>
-
- * emultempl/elf32.em (gld_${EMULATION_NAME}_list_options):
- Print out ignored -z options.
-
-2000-07-19 H.J. Lu <hjl@gnu.org>
-
- * emulparams/elf32mcore.sh (PARSE_AND_LIST_ARGS): Removed.
- (PARSE_AND_LIST_PROLOGUE): New.
- (PARSE_AND_LIST_LONGOPTS): Likewise.
- (PARSE_AND_LIST_OPTIONS): Likewise.
- (PARSE_AND_LIST_ARGS_CASES): Likewise.
-
- * ldmain.c (main): Clear link_info.flags and link_info.flags_1.
-
- * lexsup.c (ld_options): Comment out 'z'.
- (parse_args): Likewise.
-
- * emultempl/elf32.em: Include "elf/common.h".
- (gld_${EMULATION_NAME}_parse_args): Defined. Handle some -z
- options.
- (gld_${EMULATION_NAME}_list_options): Likewise.
-
- * ld.texinfo: Add documentation for the recognized -z options.
-
-2000-07-19 H.J. Lu <hjl@gnu.org>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_try_needed): Call
- bfd_elf_set_dt_needed_soname ().
-
-2000-07-18 DJ Delorie <dj@cygnus.com>
-
- * pe-dll.c (pe_dll_id_target): check object target name also
-
-2000-07-18 Hans-Peter Nilsson <hp@axis.com>
-
- * scripttempl/elf.sc (.init): Only do ${INIT_START} and
- ${INIT_END} if relocating.
- (.fini): Likewise ${FINI_START} and ${FINI_END}.
-
-2000-07-16 Charles Wilson <cwilson@ece.gatech.edu>
-
- * emultempl/pe.em (gld_*_open_dynamic_archive): New search
- order for dynamic library '-lfoo' on pei386: libfoo.dll.a,
- foo.dll.a, libfoo.a, libfoo.dll, foo.dll. This fixes compatibility
- errors introduced by the old dynamic lib search order.
-
-2000-07-17 DJ Delorie <dj@cygnus.com>
-
- * pe-dll.c (process_def_file): auto-export data items also
- (pe_process_import_defs): also see if _imp_ form needed
-
-2000-07-12 Charles Wilson <cwilson@ece.gatech.edu>
-
- * pe-dll.c (make_one): fix a typo in the __imp_ name decoration
- for dll import libraries
-
-2000-07-12 Mark Elbrecht <snowball3@bigfoot.com>
-
- * scripttempl/i386go32.sc: Support the g++ attribute init_priority in
- gcc 2.95.2 and later.
-
-2000-07-11 Kazu Hirata <kazu@hxi.com>
-
- * ldfile.c (ldfile_try_open_bfd): Output '\n' after an error
- message.
-
-2000-07-10 Alan Modra <alan@linuxcare.com.au>
-
- * ldemul.h (struct lang_input_statement_struct): Remove forward
- declaration.
- (struct search_dirs): Likewise.
- * ldfile.h (struct lang_input_statement_struct): Likewise.
- Protect file from multiple inclusion.
- * ldlang.h (LANG_FOR_EACH_INPUT_STATEMENT): Move file_chain
- declaration from macro to file scope.
-
- * ldemul.c: ldexp.h,ldlang.h,ldfile.h,ldemul.h go in this order.
- * ldgram.y: Likewise here.
- * ldlang.c: And here.
- * ldmain.c: And here.
- * mpw-elfmips.c: And here.
- * mpw-eppcmac.c: And here.
- * emultempl/aix.em: And here.
- * emultempl/armcoff.em: And here.
- * emultempl/armelf.em: And here.
- * emultempl/armelf_oabi.em: And here.
- * emultempl/beos.em: And here.
- * emultempl/elf32.em: And here.
- * emultempl/hppaelf.em: And here.
- * emultempl/linux.em: And here.
- * emultempl/lnk960.em: And here.
- * emultempl/pe.em: And here.
- * emultempl/sunos.em: And here.
- * mpw-esh.c: And here. Include ldexp.h and ldlang.h too.
- * mpw-idtmips.c: Ditto.
- * emultempl/generic.em: Ditto.
- * emultempl/gld960.em: Ditto.
- * emultempl/gld960c.em: Ditto.
- * emultempl/mipsecoff.em: Ditto.
- * emultempl/ticoff.em: Ditto.
- * emultempl/vanilla.em: Ditto.
-
- * pe-dll.c: Include ldfile.h
- * ldver.c: Include ldexp.h, ldlang.h, ldfile.h
-
- * mpw-elfmips.c: (gldelf32ebmip_before_allocation): Add missing
- arguments to bfd_elf32_size_dynamic_sections call.
- (gldelf32ebmip_place_orphan): Add missing arguments to
- lang_leave_output_section_statement call.
-
-2000-07-10 H.J. Lu <hjl@gnu.org>
-
- * emultempl/pe.em (pe_enable_stdcall_fixup): Protect with
- DLL_SUPPORT.
- (strhash): Likewise.
- (compute_dll_image_base): Likewise.
- (pe_undef_found_sym): Likewise.
- (pe_undef_cdecl_match): Likewise.
- (gld_${EMULATION_NAME}_open_dynamic_archive): Mark the
- argument "arch" with ATTRIBUTE_UNUSED.
-
-2000-07-10 Alan Modra <alan@linuxcare.com.au>
-
- * configure.tgt: Remove extraneous hppa*-*-linux-gnu*.
-
- From Ryan Bradetich <rbradetich@uswest.net>
- * ldwrite.c (SSIZE): Remove to cure macro redefinition warning.
-
-2000-07-09 Alan Modra <alan@linuxcare.com.au>
-
- Changes to create multiple linker stubs, positioned immediately
- before the section where they are required.
- * emultempl/hppaelf.em: Include elf32-hppa.h.
- (stub_sec, file_chain): Delete.
- (hppaelf_create_output_section_statements): Don't make a stub
- section here.
- (hook_stub_info): New struct.
- (hook_in_stub): New function.
- (hppaelf_add_stub_section): New function.
- (hppaelf_finish): Do nothing for relocateable links. Modify the
- call to elf32_hppa_size_stubs. Move code for updating section
- layout from here...
- (hppaelf_layaout_sections_again): ..to here, a new function.
-
- * emultempl/hppaelf.em (hppaelf_delete_padding_statements): Fix
- broken list handling. Pass in a pointer to the list.
- (hppaelf_finish): Update call to hppaelf_delete_padding_statements
- for above changes.
- (hppaelf_before_parse): Prototype.
- (hppaelf_set_output_arch): Prototype.
- (hppaelf_create_output_section_statements): Prototype.
- (hppaelf_delete_padding_statements): Prototype.
- (hppaelf_finish): Prototype.
-
- Merge from elf32.em
- * emultempl/hppaelf.em: Include ctype.h.
- (struct orphan_save): New.
- (gld${EMULATION_NAME}_place_orphan): New.
- (output_rel_find): New.
- (hppaelf_get_script): Update from elf32.em.
- (ld_hppaelf_emulation): Rename to ld_${EMULATION_NAME}_emulation.
- Change emulation_name field to "${EMULATION_NAME}". Add
- gld${EMULATION_NAME}_place_orphan.
-
- * Makefile.am (ALL_EMULATIONS): Reinstate ehppaelf.o, add
- ehppalinux.o, sort it. Regenerate dependencies.
- (ehppalinux.c): Depend on hppaelf.em
- * Makefile.in: Regenerate.
-
- * configure.tgt: targ_emul=hppalinux for hppa*linux
-
- * emulparams/hppalinux.sh: New.
- * emulparams/hppaelf.sh (TARGET_PAGE_SIZE): Write in hex.
-
-2000-07-08 Alan Modra <alan@linuxcare.com.au>
-
- * lexsup.c (parse_args): Copy section name.
-
-2000-07-07 Charles Wilson <cwilson@ece.gatech.edu>
-
- * emultempl/pe.em: institute the following search order for
- dynamic libraries on pei386: libfoo.dll.a, foo.dll.a (import
- libs), libfoo.dll, foo.dll (link direct to dll). Fall back to
- static lib (libfoo.a) if none of the above are found.
-
-2000-07-07 Mumit Khan <khan@xraylith.wisc.edu>
-
- * emultempl/pe.em (pe_enable_auto_image_base): New variable.
- (longopts): New --{enable,disable}-auto-image-base options.
- (gld_${EMULATION_NAME}_list_options): Document.
- (gld_${EMULATION_NAME}_parse): Handle.
- (strhash): New static function.
- (compute_dll_image_base): New static function.
- (gld_${EMULATION_NAME}_set_symbols): Use.
-
-2000-07-05 DJ Delorie <dj@redhat.com>
-
- * MAINTAINERS: new
-
-2000-07-01 Koundinya K <kk@ddeorg.soft.net>
-
- * configure.tgt: Add traditional mips (mips*-*-sysv4*) target.
- * emulparams/elf32btsmip.sh: New file.
- * Makefile.am: Add traditional mips target.
- * Makefile.in: Rebuild.
-
-2000-07-01 H.J. Lu <hjl@gnu.org>
-
- * Makefile.am (EXTRA_ld_new_SOURCES): Set to deffilep.y for
- automake to use YLWRAP.
- * Makefile.in: Rebuild.
-
-2000-07-01 Alan Modra <alan@linuxcare.com.au>
-
- * Makefile.am (DEP): Fix 2000-06-22. grep after running dep.sed
- (CLEANFILES): Add DEPA.
- * Makefile.in: Regenerate.
-
-2000-06-30 Timothy Wall <twall@ppc>
-
- * scripttempl/tic54xcoff.sc: PAGE N is not implemented, so encode
- the page in the upper octet of the address.
-
-2000-06-26 Marek Michalkiewicz <marekm@linux.org.pl>
-
- * emulparams/avrmega161.sh (ARCH): Change to avr:5.
-
-2000-06-24 Alan Modra <alan@linuxcare.com.au>
-
- * NEWS: arm-elf does --gc-sections too.
-
-2000-06-22 Alan Modra <alan@linuxcare.com.au>
-
- * Makefile.am (DEP): grep for leading `/' in DEP1, and fail if we
- find one.
- * Makefile.in: Regenerate.
+ * ldlang.c (map_input_to_output_sections): Initialize sections
+ mentioned in a data statement expression.
+ (lang_do_assignments_1): Add data statement's expression's
+ section's vma.
-2000-06-21 H.J. Lu <hjl@gnu.org>
+2004-02-18 Nathan Sidwell <nathan@codesourcery.com>
- * Makefile.am: Rebuild dependency.
- * Makefile.in: Rebuild.
+ * ldgram.y (statement_anywhere): Add assert rule.
+ * ldlang.c (exp_init_os): Add assert case.
-2000-06-20 H.J. Lu <hjl@gnu.org>
+2004-02-14 Andrew Cagney <cagney@redhat.com>
- * Makefile.am: Rebuild dependency.
- * Makefile.in: Rebuild.
+ * ldmain.c (remove_output): Call bfd_cache_close.
-2000-06-20 Timothy Wall <twall@cygnus.com>
+2004-02-14 Richard Sandiford <rsandifo@redhat.com>
- * scripttempl/tic54xcoff.sc: New.
- * ldlang.c (wild_doit): Propagate SEC_BLOCK flag.
- * gen-doc.texi: Add flag for TI COFF.
- * ld.texinfo: Add documentation for TI COFF handling switches.
- * emultempl/ticoff.em: New. TI COFF handling.
- * configure.tgt: Add tic54x target.
- * Makefile.am: Add tic54x target.
- * Makefile.in: Ditto.
+ * emulparams/elf32bmipn32-defs.sh (OTHER_SECTIONS): Discard
+ .MIPS.content* and .MIPS.events* sections.
-2000-06-20 Alan Modra <alan@linuxcare.com.au>
+2004-02-09 Daniel Jacobowitz <drow@mvista.com>
- * ldmain.c (set_scripts_dir): Correct pointer comparison when
- checking for backslashes.
+ * emulparams/armelf.sh, emulparams/armelf_linux.sh: Move
+ .note.gnu.arm.ident to after allocated sections. Mark its
+ address as 0.
-2000-06-19 Alan Modra <alan@linuxcare.com.au>
+2004-02-09 Daniel Jacobowitz <drow@mvista.com>
- * NEWS: Move entries not in 2.10 above "Changes in version 2.10".
+ * emulparams/armelf_linux.sh (COMMONPAGESIZE): Set to 4KB.
+ * emulparams/elf32bmip.sh (COMMONPAGESIZE): Likewise.
+ * emulparams/elf32bmipn32.sh (COMMONPAGESIZE): Likewise.
+ * emulparams/elf32btsmipn32.sh (COMMONPAGESIZE): Likewise.
+ * emulparams/shlelf_linux.sh (COMMONPAGESIZE): Likewise.
-2000-06-18 Alan Modra <alan@linuxcare.com.au>
+2004-02-05 Nick Clifton <nickc@redhat.com>
- * NEWS: Update list of targets supporting --gc-sections.
+ * emultempl/pe.em (_after_open): Fix typo in previous delta.
- * scripttempl/elf.sc: KEEP .eh_frame contents.
- * scripttempl/elfd30v.sc: Same here.
+2004-02-04 Danny Smith <dannysmith@users.sourceforge.net>
-2000-06-18 Stephane Carrez <stcarrez@worldnet.fr>
+ * emultempl/pe.em (_after_open): Fix thinko in 2003-12-18 patch.
- * Makefile.am (ALL_EMULATIONS): Added new emulation for m68hc12
- and m68hc11 (elf).
- * Makefile.in: Rebuild.
- * configure.tgt: Recognize m68hc12 and m68hc11.
- * scripttempl/elfm68hc12.sc: New file.
- * emulparams/m68hc12elfb: New emulation.
- * emulparams/m68hc12elf: New emulation.
- * emulparams/m68hc11elfb.sh: New file. User configurable emulation
- (includes a memory.x script to define the ROM and RAM banks).
- * scripttempl/elfm68hc11.sc, emulparams/m68hc11elf.sh:
- New configuration files for support of Motorola 68hc11
+2004-01-28 Alan Modra <amodra@bigpond.net.au>
-2000-06-15 Alan Modra <alan@linuxcare.com.au>
+ * genscripts.sh: Fix typo.
- * ldmain.c (main): Only change SEC_READONLY for final link.
+ * genscripts.sh: Apply $LIBPATH_SUFFIX to $tool_lib and $libdir too.
-2000-06-13 H.J. Lu <hjl@gnu.org>
+2004-01-24 Jakub Jelinek <jakub@redhat.com>
- * configure: Regenerate.
+ * emulparams/elf64_ia64.sh: Put .rela.opd into
+ OTHER_GOT_RELOC_SECTIONS instead of OTHER_PLT_RELOC_SECTIONS.
-2000-06-08 David O'Brien <obrien@FreeBSD.org>
+2004-01-20 Danny Smith <dannysmith@users.sourceforge.net>
- * configure.in (VERSION): Update to show this is the CVS mainline.
+ * pe-dll.c (pe_create_import_fixup): Clear WP_TEXT flag.
+ * ld.texinfo (--omagic): Note that writable text section
+ does not conform to published PE-COFF specs.
+ (--enable-auto-import): Likewise.
-2000-06-07 Michael Sokolov <msokolov@ivan.Harhan.ORG>
+2004-01-15 Alan Modra <amodra@bigpond.net.au>
- * emultempl/mipsecoff.em (gld{EMULATION_NAME}_after_open): Require all
- input objects to be ECOFF.
- (check_sections): einfo takes %B, not %P, to print a BFD name.
+ * emulparams/elf32ppc.sh (COMMONPAGESIZE): Define.
-2000-06-05 Michael Matz <matz@ifh.de>
+2004-01-13 Nick Clifton <nickc@redhat.com>
- * ldgram.y (vers_defns): Handle 'extern "C++" { ... }' in
- version scripts.
-
- * ldlex.l (V_IDENTIFIER): Accept `::' in symbols.
-
-2000-05-23 Marek Michalkiewicz <marekm@linux.org.pl>
-
- * emulparams/avr1200.sh (STACK): Define as 0.
- * emulparams/avr23xx.sh (STACK): Define as last internal SRAM address.
- * emulparams/avr4433.sh (STACK): Likewise.
- * emulparams/avr44x4.sh (STACK): Likewise.
- * emulparams/avr85xx.sh (STACK): Likewise.
- * emulparams/avrmega103.sh (STACK): Likewise.
- * emulparams/avrmega161.sh (STACK): Likewise.
- * emulparams/avrmega603.sh (STACK): Likewise.
- * scripttempl/elf32avr.sc (__data_start): Define for gcrt1.
- (__stack): Define from ${STACK} for main().
-
-2000-05-26 Alan Modra <alan@linuxcare.com.au>
-
- * Makefile.am: Update dependencies with "make dep-am"
- * Makefile.in: Regenerate.
-
-2000-05-26 Eli Zaretskii <eliz@is.elta.co.il>
-
- * ldmain.c: Include filenames.h.
- (set_scripts_dir): Support backslashes in program name.
-
-2000-05-22 Igor Shevlyakov <igor@windriver.com>
-
- * ldmain.c (main): When deciding if ".text" section should be
- read-only, don't forget to reset SEC_READONLY because it
- could be already set.
-
-2000-05-22 Thomas de Lellis <tdel@windriver.com>
-
- * ld.1: Add documentation for new command line option:
- --section-start <sectionname>=<sectionorg>
- This is a generic version of -Ttext etc. which accepts
- any section name as a parameter instead of just text/data/
- bss.
- * ld.texinfo: More docs.
- * NEWS: More docs.
- * lexsup.c: (parse_args): Recognize new command line option.
- (ld_options): Add new option.
-
-2000-05-18 H.J. Lu <hjl@gnu.org>
-
- * lexsup.c (parse_args): `i' == `r', not `q'.
-
-2000-05-18 Jeffrey A Law (law@cygnus.com)
-
- * configure.tgt (hppa*64*-*-*): Enable PA64 target.
-
-2000-05-17 S. Bharadwaj Yadavalli <sby@scrugs.lkg.dec.com>
- Rick Gorton <gorton@scrugs.lkg.dec.com>
-
- Add support for '-q' == '--emit-relocs' switch.
- * ldmain.c (main): Default to false.
- * lexsup.c (parse_args): Turn on emitrelocations flag if set.
- * NEWS: Describe the emitrelocations switch.
- * ld.texinfo: Describe the emitrelocations switch.
-
-2000-05-16 Charles Wilson <cwilson@ece.gatech.edu>
-
- * emultempl/pe.em (_open_dynamic_archive): New function: Search
- the library path for "foo.dll" and "libfoo.dll" dynamic libraries
- before searching for 'libfoo.a' in response to a '-Bdynamic -lfoo'
- link options.
-
-2000-05-15 David O'Brien <obrien@FreeBSD.org>
-
- * lexsup.c (parse_args): Update the year in the copyright notice.
-
-2000-05-13 Alan Modra <alan@linuxcare.com.au>
-
- * ld.h (gettext, dgettext, dcgettext, textdomain, bindtextdomain):
- Replace defines with those from intl/libgettext.h to quieten gcc
- warnings.
-
-2000-05-10 H.J. Lu <hjl@gnu.org>
-
- * ldlang.c (open_input_bfds): Don't load the same file within
- a group again if the whole archive has been loaded already.
-
-2000-05-03 Alan Modra <alan@linuxcare.com.au>
-
- From Ulf Carlsson <ulfc@engr.sgi.com> and Andreas Jaeger <aj@suse.de>
- * lexsup.c (set_section_start): Use bfd_scan_vma rather than
- strtoul.
-
-2000-05-01 Jim Wilson <wilson@cygnus.com>
-
- * configure.host (ia64-*-linux-gnu*): Change gcc to ${CC}.
-
- * configure.host: Added HOSTING_CRT0, HOSTING_LIBS for
- host "ia64-*-linux-gnu*".
-
-2000-04-29 Andreas Jaeger <aj@suse.de>
-
- * ld.h: Correctly check GCC version.
-
-2000-04-25 Jeffrey A Law (law@cygnus.com)
-
- * Makefile.am: Add PA64 support. Add missing dependencies for
- PA32 elf support.
+ * ldlang.c (lang_get_regions): Add extra parameter 'have_vma'
+ which if true will prevent the LMA region being used as a
+ replacement for a default VMA region.
+ (lang_leave_output_section_statement): Pass extra parameter.
+ (lang_leave_overlay): Likewise.
+ * ld.texinfo (Output Section LMA): Document that the LMA
+ region can be set to the VMA region if no VMA has been set.
+ * ldlang.h (struct lang_output_section_phdr_list): Create a
+ typedef for this type. Minor formatting fixes.
+
+2004-01-13 Nick Clifton <nickc@redhat.com>
+
+ * ldlang.c (lang_size_sections_1): If dot is advanced, then
+ assume that the section should be allocated.
+
+2004-01-13 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (IGNORE_SECTION): Don't ignore SEC_ALLOC && !SEC_LOAD
+ sections. Do ignore SEC_NEVER_LOAD sections.
+ (lang_size_sections_1): Remove test made redundant with the above.
+
+2004-01-09 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/ppc64elf.em (ppc_before_allocation): Clear cached
+ program_header_size.
+
+2004-01-06 Alexandre Oliva <aoliva@redhat.com>
+
+ 2003-11-28 Alexandre Oliva <aoliva@redhat.com>
+ * emulparams/elf32frvfd.sh (EMBEDDED): Clear.
+ 2003-11-05 Alexandre Oliva <aoliva@redhat.com>
+ * emulparams/elf32frvfd.sh (STACK_ADDR): Unset.
+ (MAXPAGESIZE): Set to 64Kb.
+ (OTHER_READONLY_SECTIONS): Define __ROFIXUP_LIST__ and
+ __ROFIXUP_END__. Don't map .rofixup.got any more.
+ * emulparams/elf32frv.sh (NOP): Set.
+ 2003-10-31 Alexandre Oliva <aoliva@redhat.com>
+ * configure.tgt: Add frv-*-*linux*.
+ 2003-09-30 Alexandre Oliva <aoliva@redhat.com>
+ * Makefile.am (ALL_EMULATIONS): Added eelf32frvfd.o.
+ (eelf32frvfd.c): New.
+ * configure.tgt <frv-*-*>: Added it to targ_extra_emuls.
+ * emulparams/elf32frv.sh: Reverted previous two patches.
+ * emulparams/elf32frvfd.sh: New.
* Makefile.in: Rebuilt.
- * configure.tgt: Add PA64 support (currently disabled).
-
-2000-04-25 Alan Modra <alan@linuxcare.com.au>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_place_section): Delete.
- (output_rel_find): New function.
- (hold_section, hold_use): Delete.
- (hold_text, hold_rodata, hold_data, hold_bss, hold_rel,
- hold_interp): Make local to place_orphan.
- (gld${EMULATION_NAME}_place_orphan): Use lang_output_section_find
- rather than place_section to find possible previous use of orphan.
- Similarly find the place-holder output sections. Use returned
- value from lang_enter_output_section_statement rather than calling
- lang_output_section_statement_lookup.
- * emultempl/armelf.em: Same here.
- * emultempl/pe.em: Similar to above, but no need for output_rel_find.
-
- * ldlang.c (lang_enter_output_section_statement): Return output
- section statement.
- * ldlang.h (lang_enter_output_section_statement): Change
- declaration too.
-
- * ldlang.h (lang_output_section_statement): Export it.
- * ldlang.c (lang_output_section_statement): Ditto.
-
-2000-04-24 Nick Clifton <nickc@cygnus.com>
-
- * ld.texinfo (Output Section Data): Add note that section data
- commands cannot appear outside of section directives.
-
-2000-04-2 Matthew Green <mrg@cygnus.com>
-
- * configure.tgt: Add NetBSD/sparc ELF, and NetBSD/sparc64 support.
-
-2000-04-21 Richard Henderson <rth@cygnus.com>
- David Mosberger <davidm@hpl.hp.com>
-
- * Makefile.am (ALL_64_EMULATIONS): Add eelf64_ia64.o.
- (eelf64_ia64.c): New rule.
- * Makefile.in: Rebuild.
- * configure.tgt (ia64-*-elf*, ia64-*-linux*): New targets.
- * emulparams/elf64_ia64.sh: New file.
-
-2000-04-21 Richard Henderson <rth@cygnus.com>
-
- * scripttempl/elfd30v.sc: Place .gcc_except_table.
-
-2000-04-19 Alan Modra <alan@linuxcare.com.au>
-
- * dep-in.sed: Match space at start of file name, not at end.
-
-2000-04-18 H.J. Lu <hjl@gnu.org>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Call
- lang_leave_output_section_statement () after calling
- lang_enter_output_section_statement ().
- * emultempl/armelf.em: Likewise.
-
-2000-04-18 Alan Modra <alan@linuxcare.com.au>
-
- * emultempl/elf32.em (struct orphan_save): Add section field.
- (gld${EMULATION_NAME}_place_orphan): Use above to keep sections in
- better order, and place first orphan section as we did before the
- 2000-04-12 patch. Ignore ~SEC_ALLOC sections when choosing place.
- Don't call make_bfd_section here, let wild_doit do the job for us.
- Don't build a statement list when we'll only throw it away.
- * emultempl/armelf.em: Ditto.
- * emultempl/pe.em: Similarly.
-
-2000-04-14 Geoff Keating <geoffk@cygnus.com>
-
- * scripttempl/elfppc.sc: Remove.
- * emulparams/elf32ppc.sh: Use elf.sc.
- * emulparams/elf32lppc.sh: Use elf.sc.
- * emulparams/elf32ppclinux.sh: Use elf.sc.
- * emulparams/elf32ppcsim.sh: New file.
- * emulparams/elf32lppcsim.sh: New file.
- * Makefile.am: Update dependencies. Add elf32ppcsim ad elf32lppcsim.
- (ALL_EMULATIONS): Add elf32ppcsim ad elf32lppcsim.
- * Makefile.in: Regenerate.
- * configure.tgt (powerpc-*): Add elf32ppcsim and elf32lppcsim.
-
-2000-04-14 Alan Modra <alan@linuxcare.com.au>
-
- * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Process
- ~SEC_ALLOC sections too. Init start address of debug sections.
- * emultempl/armelf.em (gld${EMULATION_NAME}_place_orphan): Ditto.
- * emultempl/pe.em (gld${EMULATION_NAME}_place_orphan): Ditto.
- Also set all relocateable section start addresses.
-
-2000-04-13 Geoff Keating <geoffk@cygnus.com>
-
- * scripttempl/elf.sc: Add support for .sbss2 and .sdata2 sections.
- Add new BSS_PLT variable for when .plt need not be contained in
- the file. Move _etext so that it is also after .fini, and provide
- both etext and _etext with a leading underscore. Mark the start
- and end of .sbss.
-
-2000-04-12 Alan Modra <alan@linuxcare.com.au>
-
- * emultempl/elf32.em (struct orphan_save): New.
- (hold_text, hold_rodata, hold_data, hold_bss, hold_rel,
- hold_interp): Make them struct orphan_save.
- (gld${EMULATION_NAME}_place_section): Modify for new hold_*.
- (gld${EMULATION_NAME}_place_orphan): Add new orphan sections to
- the end of the relevant section list. Also add associated section
- statements to the end of any previous orphan statements.
- * emultempl/armelf.em: Similarly.
- * emultempl/pe.em: Similarly.
-
-2000-04-11 Alan Modra <alan@linuxcare.com.au>
-
- * ld.texinfo (Simple Example): Remove extraneous paragraph.
-
-2000-04-07 Andrew Cagney <cagney@b1.cygnus.com>
-
- * configure.in (WARN_CFLAGS): Set to -W -Wall by default. Add
- --enable-build-warnings option.
- * Makefile.am (AM_CFLAGS, WARN_CFLAGS): Add definitions.
- * Makefile.in, configure: Re-generate.
-
-2000-04-04 Alan Modra <alan@linuxcare.com.au>
-
- * po/ld.pot: Regenerate.
-
- * lexsup.c (help): Restore translated part of bug string.
-
- * Makefile.am (MKDEP): Use gcc -MM rather than mkdep.
- (DEP): Quote when passing vars to sub-make. Add warning message
- to end.
- (DEP1): Rewrite for "gcc -MM".
- (CLEANFILES): Add DEP2.
- Update dependencies.
- * Makefile.in: Regenerate.
-
-2000-04-03 Alan Modra <alan@linuxcare.com.au>
-
- * ld.h: #include "bin-bugs.h"
- * lexsup.c (help): Use REPORT_BUGS_TO.
-
-2000-03-27 Denis Chertykov <denisc@overta.ru>
-
- * configure.tgt (avr-*-*): New target support.
- * Makefile.am: Likewise.
- * scripttempl/elf32avr.sc: New script file.
- * emulparams/avr1200.sh: New file.
- * emulparams/avr23xx.sh: New file.
- * emulparams/avr4433.sh New file.
- * emulparams/avr44x4.sh New file.
- * emulparams/avr85xx.sh New file.
- * emulparams/avrmega103.sh New file.
- * emulparams/avrmega161.sh New file.
- * emulparams/avrmega603.sh New file.
- * Makefile.in: Regenerate.
-
-2000-03-09 Andreas Jaeger <aj@suse.de>
-
- * Makefile.am (check-DEJAGNU): Also unset LANG.
- * Makefile.in: Rebuild.
-
-2000-03-06 Ian Lance Taylor <ian@zembu.com>
-
- * ldfile.c (ldfile_try_open_bfd): Don't crash if we see an empty
- archive.
-
-2000-03-02 H.J. Lu <hjl@gnu.org>
-
- * emulparams/elf32mcore.sh: Include "getopt.h".
-
-2000-03-01 Ian Lance Taylor <ian@zembu.com>
-
- * configure.tgt: Remove *-*-aout, *-*-coff, and *-*-netware.
-
-2000-03-01 H.J. Lu <hjl@gnu.org>
-
- * emulparams/mipspe.sh: Add SUBSYSTEM and INITIAL_SYMBOL_CHAR.
- * emulparams/shpe.sh: Likewise.
-
-2000-03-01 Nick Clifton <nickc@cygnus.com>
-
- * pe-dll.c: Remove unused variables and add ATTRIBUTE_UNUSED
- to unused parameters.
-
- * emultempl/pe.em: Add "#ifdef DLL_SUPPORT" around static
- functions only used by DLL code.
- (_place_orphan): Initialise 'dollar'.
-
-2000-03-01 H.J. Lu <hjl@gnu.org>
-
- * ldmain.c (undefined_symbol): Take one more arg, fatal, to
- indicate if the undefined symbol is a fatal error or not.
- Don't delete the output file if "fatal" is false.
-
-2000-02-29 H.J. Lu <hjl@gnu.org>
-
- * Makefile.am (check-DEJAGNU): Also pass LIBS="$(LIBS)".
- Set LC_COLLATE and LC_ALL to null and export them. It is for
- sort which expects the C locale.
- Add $(LIBS) to all $(HOSTING_LIBS).
- * Makefile.in: Rebuild.
-
-2000-02-29 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * emultempl/{aix.em, armcoff.em, armelf.em, armelf_oabi.em,
- beos.em, elf32.em, generic.em, gld960.em, gld960c.em, hppaelf.em,
- linux.em, lnk960.em, mipsecoff.em, sunos.em, vanilla.em}
- (ld_emulation_xfer_struct): Add missing NULL initialiser for
- find_potential_libraries.
-
-2000-02-28 Jim Blandy <jimb@redhat.com>
-
- * ldgram.y (exclude_name_list): Don't require a comma to separate
- list entries; the lexer considers commas to be valid part of a
- filename, so in something like `foo, bar' the comma is considered
- part of the first filename, `foo,'.
- * ld.texinfo: Update section on EXCLUDE_FILE lists.
-
-2000-02-27 Loren J. Rittle <ljrittle@acm.org>
-
- * configure.host: Added HOSTING_CRT0, HOSTING_LIBS for
- host "i[3456]86-*-freebsdelf*".
-
-2000-02-27 Mark Elbrecht <snowball3@bigfoot.com>
-
- * scripttempl/i386go32.sc: Move misplaced semicolons.
-
-2000-02-25 Ian Lance Taylor <ian@zembu.com>
-
- * Makefile.am (ALL_EMULATIONS): Remove ehppaelf.o.
- (ALL_64_EMULATIONS): Remove eelf64hppa.o.
- (eelf64hppa.c, ehppaelf.c): Remove targets.
- * Makefile.in: Rebuild.
-
-2000-02-25 Alexandre Oliva <oliva@lsd.ic.unicamp.br>
-
- * configure.tgt (targ_extra_ofiles): Enable elf64_sparc on
- GNU/Linux/sparc, but keep the default as 32.
-
- * configure.tgt: Enable elf64_sparc on Solaris7+/sparc. And make
- it default if sparcv9 or sparc64.
-
-2000-02-24 Nick Clifton <nickc@cygnus.com>
-
- * Makefile.am: Add rules to build emipspe.o and earmpe.o.
- * Makefile.in: Regenerate.
- * configure.tgt: Add targets for arm-wince, sh-pe and mips-pe.
-
- * ldemul.h (ld_emulation_xfer_struct): Add new field:
- find_potential_libraries.
- * ldemul.c (ldemul_find_potential_libraries): New function.
-
- * ldfile.c (ldfile_open_file_search): Allow function to be
- exported.
- (ldfile_open_file): Call ldemul_find_potential_libraries.
- * ldfile.h: Add prototype for ldfile_open_file_search.
-
- * pe-dll.c: Add support for ARM, MIPS and SH targets.
-
- * emulparams/mipspe.sh: New file. Parameters for mips-pe target.
- * emulparams/shpe.sh: New file. Parameters for sh-pe target.
-
- * emultempl/pe.em: Add support for ARM, MIPS and SH DLLs.
- (gld_X_find_potential_libraries): New function. Search for
- libraries called "*.lib".
-
- * scripttempl/pe.sc: Add .pdata section.
-
-2000-02-23 Richard Henderson <rth@cygnus.com>
-
- * scripttempl/elfd10v.sc: Remove dynamic linking hooks.
- Add and use memory regions.
-
-2000-02-23 Linas Vepstas (linas@linas.org)
-
- * emulparams/elf32i370.sh, scripttempl/elfi370.sc: New.
-
- * Makefile.am: Add support for Linux/IBM 370.
- * configure.tgt: Likewise.
-
- * Makefile.in: Regenerate.
-
-2000-02-21 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * ldlang.c (print_input_section, print_data_statement,
- print_reloc_statement, print_padding_statement, insert_pad,
- size_input_section, lang_check_section_addresses,
- lang_size_sections, lang_do_assignments, lang_set_startof,
- lang_one_common): Change `opb' to unsigned.
- (lang_do_assignments): Also change `size' to unsigned.
-
-2000-02-16 Richard Henderson <rth@cygnus.com>
-
- * scripttempl/elf.sc: Place OTHER_PLT_RELOC_SECTION.
-
-2000-02-16 Timothy Wall <twall@cygnus.com>
-
- * mri.c (mri_draw_tree): Add default LMA region argument to call
- to lang_leave_output_section_statement.
- * ldlang.h: Update prototypes with LMA region arguments.
- * ldlang.c (lang_size_sections): Encapsulate region bounds
- checking in os_check_region call.
- (os_check_region): New function.
- (lang_output_section_statement_lookup): Initialize lma_region.
- (lang_leave_output_section_statement): Add LMA region argument.
- (lang_leave_overlay): Ditto.
- * ldgram.y: Handle LMA region syntax.
- * ld.texinfo (Output Section Description): Describe LMA region usage.
- * emultempl/armelf.em (gld$place_orphan): Add default value for
- lma region in call to lang_leave_output_section_statement.
- * emultempl/elf32.em (gld$place_orphan): Add default value for
- lma region in call to lang_leave_output_section_statement.
- * emultempl/pe.em (gld$place_orphan): Add default value for
- lma region in call to lang_leave_output_section_statement.
-
-
-2000-02-04 Timothy Wall <twall@redhat.com>
-
- * ldlang.c (lang_check_section_addresses): Use bytes instead of
- octets when calculating section end addresses.
-
-2000-02-04 Timothy Wall <twall@redhat.com>
-
- * ldlang.c (lang_size_sections): Fix typo in ALIGN_N invocation.
-
-2000-02-03 Timothy Wall <twall@redhat.com>
-
- * ldexp.c (fold_name): Make SIZEOF operator return byte count, not
- octet count.
- * ldlang.c (print_input_section, print_data_statement,
- print_reloc_statement, print_padding_statement): Print target
- address values and section sizes as bytes, not octets.
- (insert_pad) Calculate padding size in octets, and adjust "dot"
- by bytes.
- (size_input_section) Always adjust "dot" by bytes, not octets.
- (lang_check_section_addresses, lang_do_assignments) Adjust
- "dot" by bytes, not octets. Use the larger of the directive size
- or octets_per_byte for the number of octets actually allocated in
- the output section.
- (lang_set_startof) Make sure STARTOF returns a target address.
- (lang_one_common) Record size changes in octets.
- (lang_abs_symbol_at_end_of) Section end symbol's value is
- recorded in target bytes.
- * ld.texinfo: Updated description of BYTE, SHORT, LONG, etc.
- to be clear about behavior when an octet is smaller than one byte.
-
-2000-01-27 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * ldcref.c (output_cref): Don't pass message strings to printf
- as format arg.
- Update copyright.
-
- * ldmisc.c (vfinfo): Same here.
- Update copyright.
-
-2000-01-23 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * emultempl/{armcoff.em,armelf.em,armelf_oabi.em,beos.em,
- generic.em,gld960.em,gld960c.em,hppaelf.em,linux.em,lnk960.em,
- mipsecoff.em,sunos.em,vanilla.em} (ld_emulation_xfer_struct):
- Add missing NULL initialisers, and comments.
-
- * testsuite/ld-srec/sr3.cc (__rethrow): New.
-
-2000-01-21 Nick Clifton <nickc@cygnus.com>
-
- * ldlang.c (lang_size_sections): Fix typo in comment.
-
-2000-01-18 H.J. Lu <hjl@gnu.org>
-
- * ldlang.c (lang_size_sections): Also update the current
- address of a region if the SEC_NEVER_LOAD bit is not set.
-
-2000-01-10 Philip Blundell <pb@futuretv.com>
-
- * configure.tgt (arm*-*-conix*): New target.
-
-2000-01-07 Nick Clifton <nickc@cygnus.com>
-
- * ld.texinfo (Options): Remind users to preceed linker command
- line switches with -Wl, (or whatever is appropriate) if it is
- being invoked by a comnpiler driver program.
- Fix description of the behaviour of the -n command line switch.
-
-2000-01-05 Catherine Moore <clm@cygnus.com>
-
- * ld.h (wildcard_spec): Change exclude_name to exclude_name_list.
- (name_list): New.
- * ld.texinfo (EXCLUDE_FILE): Update documentation.
- * ldgram.y (wildcard_spec): Support a list of excluded_files.
- (exclude_name_list): New.
- ldlang.c (walk_wild_section): Support list of excluded files.
- (print_wild_statement): Likewise.
- (lang_add_wild): Likewise.
- * ldlang.h (lang_wild_statement_type): Likewise.
- * scripttempl/elf.sc (OTHER_EXCLUDE_FILES): Support.
-
-2000-01-04 Mumit Khan <khan@xraylith.wisc.edu>
-
- * pe-dll.c (pe_dll_warn_dup_exports): New variable.
- (process_def_file): Use.
- (pe_dll_compat_implib): New variable.
- (make_one): Use.
-
- * pe-dll.h: Add exports of pe_dll_warn_dup_exports and
- pe_dll_compat_implib.
-
- * emultempl/pe.em (longopts): Add warn-duplicate-exports and
- compat-implib options.
- (gld_${EMULATION_NAME}_list_options): List new options.
- (gld_${EMULATION_NAME}_parse_args): Handle.
-
- * pe-dll.c (pe_dll_generate_implib): Use the correct name for output
- dll.
-
- * deffilep.y (opt_name): Allow "." in name.
-
-For older changes see ChangeLog-9899
+ 2003-09-18 Alexandre Oliva <aoliva@redhat.com>
+ * emulparams/elf32frv.sh (OTHER_READONLY_SECTIONS): Added
+ .rofixup.got to .rofixup.
+ 2003-09-15 Alexandre Oliva <aoliva@redhat.com>
+ * emulparams/elf32frv.sh (MAXPAGESIZE): Make it 256KiB, not 256B.
+ (TEMPLATE_NAME, GENERATE_SHLIB_SCRIPT): Set.
+
+2004-01-05 Jakub Jelinek <jakub@redhat.com>
+
+ * emulparams/elf_s390.sh (NO_SMALL_DATA): Set to yes.
+ * emulparams/elf64_s390.sh (NO_SMALL_DATA): Set to yes.
+
+2004-01-03 Alan Modra <amodra@bigpond.net.au>
+
+ * ldexp.c (align_n): Make static.
+ * ldexp.h (align_n): Delete declaration.
+ * ldlang.h (lang_enter_output_section_statement): Remove
+ block_value param.
+ * ldlang.c (lang_enter_output_section_statement): Likewise.
+ (TO_ADDR, TO_SIZE): Define.
+ (opb_shift): New var.
+ (init_opb): New function.
+ (print_input_section): Call init_opb and use TO_ADDR.
+ (print_data_statement, print_reloc_statement): Likewise.
+ (print_padding_statement): Likewise.
+ (size_input_section): Use TO_SIZE and TO_ADDR, and global opb_shift.
+ (lang_check_section_addresses): Likewise.
+ (lang_size_sections_1): Likewise.
+ (lang_do_assignments_1): Likewise.
+ (lang_set_startof): Likewise.
+ (lang_one_common): Likewise. Combine power_of_two and opb_shift align.
+ (lang_process): Call init_opb.
+ (lang_abs_symbol_at_end_of): Use TO_ADDR and global opb_shift.
+ (lang_enter_overlay_section): Adjust
+ lang_enter_output_section_statement call.
+ * ldgram.y: Likewise.
+ * mri.c (mri_draw_tree): Likewise.
+ * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Likewise.
+ * emultempl/mmo.em (mmo_place_orphan): Likewise.
+ * emultempl/pe.em (gld${EMULATION_NAME}_place_orphan): Likewise.
+
+ * ldfile.c (ldfile_set_output_arch): Add defarch param.
+ * ldfile.h (ldfile_set_output_arch): Ditto.
+ * emultempl/aix.em (gld${EMULATION_NAME}_before_parse): Use
+ ldfile_set_output_arch.
+ * emultempl/beos.em (gld${EMULATION_NAME}_before_parse): Ditto.
+ * emultempl/elf32.em (gld${EMULATION_NAME}_before_parse): Ditto.
+ * emultempl/linux.em (gld${EMULATION_NAME}_before_parse): Ditto.
+ * emultempl/mipsecoff.em (gld${EMULATION_NAME}_before_parse): Ditto.
+ * emultempl/pe.em (gld${EMULATION_NAME}_before_parse): Ditto.
+ * emultempl/sunos.em (gld${EMULATION_NAME}_before_parse): Ditto.
+ * ldgram.y: Adjust ldfile_set_output_arch call.
+ * emultempl/armcoff.em (gld${EMULATION_NAME}_before_parse): Ditto.
+ * emultempl/armelf.em (gld${EMULATION_NAME}_before_parse): Ditto.
+ * emultempl/armelf_oabi.em (gld${EMULATION_NAME}_before_parse): Ditto.
+ * emultempl/generic.em (gld${EMULATION_NAME}_before_parse): Ditto.
+ * emultempl/gld960c.em (gld960_set_output_arch): Ditto.
+ * emultempl/m68kcoff.em (gld${EMULATION_NAME}_before_parse): Ditto.
+ * emultempl/ticoff.em (gld${EMULATION_NAME}_before_parse): Ditto.
+
+2004-01-02 Bernardo Innocenti <bernie@develer.com>
+
+ * configure.tgt: Add m68k-uClinux target.
+
+For older changes see ChangeLog-0203
Local Variables:
mode: change-log
diff --git a/contrib/binutils/ld/ChangeLog-0001 b/contrib/binutils/ld/ChangeLog-0001
new file mode 100644
index 0000000..9183afe
--- /dev/null
+++ b/contrib/binutils/ld/ChangeLog-0001
@@ -0,0 +1,3376 @@
+2001-12-21 Tom Rix <trix@redhat.com>
+
+ (gld*_create_output_section_statements): New function.
+ For -binitfini support.
+ * emultempl/aix.em (gld*_before_parse): Fix comment.
+ * emultempl/aix.em (gld*_parse_args): Fix comment.
+
+2001-12-20 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * configure.tgt (mips*-dec-netbsd*): Delete alias for
+ mips*el-*-netbsd*.
+ (sparc64-*-netbsd*): Add elf32_sparc to targ_extra_emuls.
+
+ * configure.tgt (arm-*-netbsdelf*): Add target.
+ (arm-*-netbsd*): Add armelf and armelf_nbsd to targ_extra_emuls.
+ * emulparams/armelf_nbsd.sh: Added.
+ * Makefile.am: Add rules for earmelf_nbsd.
+ * Makefile.in: Regenerate.
+
+2001-12-19 Andreas Jaeger <aj@suse.de>,
+ Susanne Oberhauser <froh@suse.de>
+
+ * configure.host: Add rules for x86_64-*linux-gnu. Change
+ s390x-linux entry to use gcc to report configuration, replace gcc
+ with $CC in s390-linux
+
+2001-12-19 Andreas Jaeger <aj@suse.de>
+
+ * ld.texinfo (VERSION): Fix markup.
+
+2001-12-18 matthew green <mrg@eterna.com.au>
+
+ * Makefile.am (ALL_EMULATIONS): Add m68kelfnbsd.o.
+ (m68kelfnbsd.c): New rule.
+ * Makefile.in: Regenerate.
+ * configure.tgt (m68*-hp-netbsd*): Renamed to ..
+ (m68*-*-netbsd*4k*): .. this.
+ (m68*-*-netbsdelf*): New target.
+ (m68*-*-netbsd*): Also include ELF support.
+ (m68*-*-netbsdaout*): New alias for m68*-*-netbsd*.
+ * emulparams/m68kelfnbsd.sh: New emulation.
+
+2001-12-18 Jakub Jelinek <jakub@redhat.com>
+
+ * ldgram.y (vers_node): Support anonymous version tags.
+ * ldlang.c (lang_register_vers_node): Ensure anonymous version
+ tag is not defined together with non-anonymous versions.
+ * ld.texinfo: Document it.
+
+2001-12-18 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/tr.po: New file: Turkish translation.
+ * configure.in (ALL_LINGUAS): Add tr.
+ * configure: Regenerate.
+
+2001-12-17 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * Makefile.am: Add rules for eelf64alpha_nbsd.
+ * Makefile.in: Regenerate.
+ * configure.tgt (alpha*-*-netbsd*): Set
+ targ_emul to elf64alpha_nbsd.
+ * emulparams/elf64alpha_nbsd.sh: Added.
+
+2001-12-17 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Adjust
+ section_tail when fiddling with section list.
+ (gld${EMULATION_NAME}_list_options): Ensure sentences aren't
+ broken into separate strings to make translation easier.
+ * emultempl/mmo.em (mmo_place_orphan): Adjust section_tail when
+ fiddling with section list.
+ * emultempl/pe.em (gld_${EMULATION_NAME}_place_orphan): Likewise.
+
+2001-12-16 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * scripttempl/mmo.sc: Add .debug_ranges to listed sections.
+
+2001-12-15 Alan Modra <amodra@bigpond.net.au>
+
+ * ldmain.c (main): Initialise link_info.eh_frame_hdr.
+
+2001-12-13 Jakub Jelinek <jakub@redhat.com>
+
+ * emultempl/elf32.em (finish): Supply output_bfd
+ to bfd_elf*_discard_info.
+ (OPTION_EH_FRAME_HDR): Define.
+ (longopts): Add --eh-frame-hdr.
+ (parse_args): Handle it.
+ (list_options): Add --eh-frame-hdr to help.
+ * emultempl/hppaelf.em (finish): Supply output_bfd
+ to bfd_elf*_discard_info.
+ * scripttempl/elf.sc (.eh_frame_hdr): Add.
+
+2001-12-13 Alan Modra <amodra@bigpond.net.au>
+
+ * lexsup.c (parse_args): Don't pass shortopts to second call to
+ getopt functions. Restore optind rather than decrementing before
+ second call. Remove errind as it now duplicates last_optind.
+
+2001-12-11 Christopher Faylor <cgf@redhat.com>
+
+ * emultempl/pe.em (gld_${EMULATION_NAME}_list_options): Fix typo.
+
+2001-12-07 Geoffrey Keating <geoffk@redhat.com>
+ Richard Henderson <rth@redhat.com>
+
+ * Makefile.am: Add support for xstormy16.
+ * configure.tgt: Add support for xstormy16.
+ * Makefile.in: Regenerate.
+ * emulparams/elf32xstormy16.sh: New file.
+ * scripttempl/xstormy16.sc: New file.
+
+2001-10-01 Christopher Faylor <cgf@cygnus.com>
+
+ * Makefile.in (LIB_PATH): Make configurable.
+ (GENSCRIPTS): Set LIB_PATH in environment.
+ * configure.in: Substitute LIB_PATH.
+ * configure: Regenerate.
+ * configure.tgt (*cygwin): Set LIB_PATH for cross build.
+ * configure.host (*cygwin): Add /usr/lib/w32api to NATIVE_LIB_DIRS.
+
+2001-12-07 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * lexsup.c (ld_options): Insert 'PROGRAM' into the text string
+ describing the -N option so that it is easier to translate into
+ foreign languages.
+
+2001-12-05 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * emultempl/pe.em (..._list_options): Replace multiple fprintf
+ statements describing a single option with a single, newline
+ escaped fprintf. This allows better translation into other
+ languages.
+
+ * ldmain.c (add_archive_element): Combine multiple strings
+ into a single string to permit better translation into other
+ languages.
+
+2001-12-05 Tom Rix <trix@redhat.com>
+
+ * Makefile.am: Remove eaixppc64.
+ * Makefile.in: Regenerate.
+
+2001-12-04 Tom Rix <trix@redhat.com>
+
+ * emultempl/aix.em (choose_target): Change default target to
+ OUTPUT_FORMAT for ppcmacos. Add braces to remove compiler
+ warning.
+ (gld*_read_file): Fix typo.
+ (change_symbol_mode): Add prototype.
+ (is_syscall): Same.
+
+ * emulparams/aixppc.sh (SYSCALL_MASK, SYMBOL_MODE_MASK): Delete.
+ * emulparams/aixrs6.sh : Same.
+ * emulparams/ppcmacos.sh : Same.
+ * emulparams/aixppc64.sh : Delete file.
+ * emultempl/aix.em : Formatting changes.
+
+2001-12-04 Hans-Peter Nilsson <hp@axis.com>
+
+ * emulparams/criself.sh (NO_SMALL_DATA): Set, to yes.
+ (OTHER_BSS_END_SYMBOLS): Don't refer to .sbss when setting
+ __Sbss.
+ (OTHER_END_SYMBOLS): Fix formatting.
+ * emulparams/crislinux.sh (NO_SMALL_DATA): Set, to yes.
+ (OTHER_END_SYMBOLS): Fix formatting.
+
+2001-12-04 Alan Modra <amodra@bigpond.net.au>
+
+ * ldexp.c (exp_print_token): Correct "table" entry for RSHIFT.
+
+2001-12-02 Tom Rix <trix@redhat.com>
+
+ * configure.tgt : Remove eaixppc64 emulations.
+ * Makefile.in : Remove eaixppc64.c
+ * ldemul.c (ldemul_choose_target): New parameters argc, argv.
+ (ldemul_default_target): Same.
+ * emultempl/gld960.em (gld960_choose_target): Same.
+ * emultempl/gld960c.em (gld960_choose_target): Same.
+ * scripttempl/aix.sc: Remove OUTPUT_FORMAT.
+ * emultempl/aix.em (is_syscall): syscall_mask now a variable.
+ * emultempl/aix.em (gld*_read_file): symbol_mode_mask now a variable.
+ * emultempl/aix.em (gld*_parse_args): Handle -b32 -b64 emulation.
+ * emultempl/aix.em (choose_target): New function. Handle emulation of
+ -b32 and -b64.
+
+2001-11-27 H.J. Lu <hjl@gnu.org>
+
+ * emulparams/elf_i386.sh (NO_SMALL_DATA): Set to yes.
+ * emulparams/elf_i386_be.sh (NO_SMALL_DATA): Likewise.
+ * emulparams/elf_i386_chaos.sh (NO_SMALL_DATA): Likewise.
+ * emulparams/elf_i386_ldso.sh (NO_SMALL_DATA): Likewise.
+ * emulparams/elf_x86_64.sh (NO_SMALL_DATA): Likewise.
+ * emulparams/m68kelf.sh (NO_SMALL_DATA): Likewise.
+ * emulparams/elf32_sparc.sh (NO_SMALL_DATA): Likewise.
+ * emulparams/elf64_sparc.sh (NO_SMALL_DATA): Likewise.
+
+ * scripttempl/elf.sc (SBSS): New. Define if ${NO_SMALL_DATA}
+ is not empty.
+ (SDATA): Likewise.
+ (REL_SDATA): Likewise.
+ (REL_SBSS): Likewise.
+ (REL_SDATA2): Likewise.
+ (REL_SBSS2): Likewise.
+ (SBSS2): Define if ${NO_SMALL_DATA} is not empty.
+ (SDATA2): Likewise.
+
+2001-11-25 Stephane Carrez <Stephane.Carrez@worldnet.fr>
+
+ * scripttempl/elfm68hc11.sc (CTOR, DTOR): Put constructor and
+ destructor in rom.
+ * scripttempl/elfm68hc12.sc (CTOR, DTOR): Likewise.
+
+2001-11-22 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.in: Regenerated with automake based on automake
+ 1.4-8 in RedHat 7.1.
+
+2001-11-22 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (CONFIG_STATUS_DEPENDENCIES): Define.
+ (config.status): Delete rule.
+ Add extra dependencies to cover sourced emulparams files.
+ * Makefile.in: Regenerate.
+
+ * scripttempl/elf.sc: Order <section>, <section>.* and
+ corresponding linkonce sections as seen in input files.
+ Formatting fixes. Zero vma of all sections if not relocating.
+ (STACK): Define and insert if STACK_ADDR defined.
+ (OTHER_RELOCATING_SECTIONS): Delete.
+ (OTHER_END_SYMBOLS): Define.
+ (OTHER_READONLY_SECTIONS): Always insert, not just when relocating.
+ (OTHER_READWRITE_SECTIONS): Likewise.
+ (OTHER_GOT_SECTIONS): Likewise.
+ (OTHER_SDATA_SECTIONS): Likewise.
+ (OTHER_BSS_SECTIONS): Likewise.
+ * scripttempl/elfi370.sc (OTHER_READONLY_SECTIONS): Likewise.
+ (OTHER_READWRITE_SECTIONS): Likewise.
+ * scripttempl/nw.sc (OTHER_READONLY_SECTIONS): Likewise.
+ (OTHER_READWRITE_SECTIONS): Likewise.
+
+ * emulparams/armelf.sh (OTHER_RELOCATING_SECTIONS): Delete.
+ (STACK_ADDR): Define.
+ * emulparams/armelf_oabi.sh: As for armelf.sh.
+ * emulparams/elf32mcore.sh: As for armelf.sh.
+ * emulparams/h8300elf.sh: As for armelf.sh.
+ * emulparams/mn10200.sh: As for armelf.sh.
+ * emulparams/shelf.sh: As for armelf.sh.
+
+ * emulparams/elf32fr30.sh (OTHER_RELOCATING_SECTIONS): Delete.
+ (OTHER_END_SYMBOLS): Define.
+ * emulparams/m32relf.sh: As for elf32fr30.sh.
+ * emulparams/h8300helf.sh: As for elf32fr30.sh.
+ * emulparams/h8300self.sh: As for elf32fr30.sh.
+
+ * emulparams/criself.sh (OTHER_READONLY_SECTIONS): Protect symbol
+ defines with RELOCATING test.
+ (OTHER_SDATA_SECTIONS): Likewise.
+ (OTHER_RELOCATING_SECTIONS): Delete, replacing with..
+ (OTHER_END_SYMBOLS): ..this.
+ * emulparams/crislinux.sh: As for criself.sh.
+
+ * emulparams/elf32bmipn32.sh (OTHER_SDATA_SECTIONS): Zero vma
+ if not relocating.
+ (OTHER_RELOCATING_SECTIONS): Delete, replacing with..
+ (OTHER_SECTIONS): ..this. Zero vma if not relocating. Order
+ normal and linkonce sections as seen in input files.
+ * emulparams/elf32bmip.sh (DATA_ADDR): Don't define if EMBEDDED.
+ (TEXT_DYNAMIC): Likewise.
+ (INITIAL_READONLY_SECTIONS): Zero vma if not relocating.
+ (OTHER_SDATA_SECTIONS): Likewise.
+ * emulparams/elf32ppc.sh (OTHER_READWRITE_SECTIONS): Likewise.
+ * emulparams/shlelf_linux.sh (OTHER_READWRITE_SECTIONS): Likewise.
+ * emulparams/elf64alpha.sh (OTHER_READONLY_SECTIONS): Likewise.
+ * emulparams/hppalinux.sh (OTHER_READONLY_SECTIONS): Likewise.
+ * emulparams/elf64_aix.sh (OTHER_GOT_SECTIONS): Likewise.
+ (OTHER_PLT_RELOC_SECTIONS): Likewise.
+ (OTHER_READONLY_SECTIONS): Likewise. Order normal and linkonce
+ sections as seen in input files.
+ * emulparams/elf64_ia64.sh: As for emulparams/elf64_aix.sh.
+ * emulparams/hppa64linux.sh (OTHER_READONLY_SECTIONS): Zero vma
+ if not relocating.
+ (OTHER_READWRITE_SECTIONS, OTHER_BSS_SECTIONS): Likewise.
+ (OTHER_BSS_END_SYMBOLS): Merge from elf64hppa.sh.
+ * emulparams/elf64mmix.sh (OTHER_RELOCATING_SECTIONS): Delete.
+ (OTHER_SECTIONS): Instead, use this..
+ (OTHER_END_SYMBOLS): ..and this.
+
+ * emulparams/elf32b4300.sh: Source elf32bmip.sh, remove duplicates.
+ * emulparams/elf32bsmip.sh: Likewise.
+ * emulparams/elf32btsmip.sh: Likewise.
+ * emulparams/elf32ebmip.sh: Likewise.
+ * emulparams/elf32lmip.sh: Likewise.
+ * emulparams/elf32elmip.sh: Source elf32lmip.sh, remove duplicates.
+ * emulparams/elf32lsmip.sh: Likewise.
+ * emulparams/elf32ltsmip.sh: Source elf32btsmip.sh, remove duplicates.
+ * emulparams/elf32l4300.sh: Source elf32b4300.sh, remove duplicates.
+ * emulparams/elf64bmip.sh: Source elf32bmipn32.sh, remove duplicates.
+ * emulparams/elf64btsmip.sh: Likewise.
+ * emulparams/elf64ltsmip.sh: Source elf64btsmip.sh, remove duplicates.
+ * emulparams/elf32lppc.sh: Source elf32ppc.sh, remove duplicates.
+ * emulparams/elf32ppclinux.sh: Likewise.
+ * emulparams/elf32ppcsim.sh: Likewise.
+ * emulparams/elf32lppcsim.sh: Source elf32lppc.sh, remove duplicates.
+ * emulparams/elf64hppa.sh: Source hppa64linux.sh, remove duplicates.
+ * emulparams/h8300helf.sh: Source h8300elf.sh, remove duplicates.
+ * emulparams/h8300self.sh: Likewise.
+ * emulparams/mn10300.sh: Source mn10200.sh, remove duplicates.
+ * emulparams/sh.sh: Comment.
+ * emulparams/shl.sh: Source sh.sh, remove duplicates.
+ * emulparams/shlelf.sh: Source shelf.sh, remove duplicates.
+ * emulparams/shelf_linux.sh: Source shlelf_linux.sh, remove duplicates.
+
+2001-11-21 David Heine <dlheine@tensilica.com>
+ Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (map_input_to_output_sections): Replace "break"
+ accidentally removed with 2001-08-03 change.
+ (lang_gc_sections_1): Likewise.
+
+2001-11-21 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (walk_wild_section): Move sec == NULL case out of loop.
+
+2001-11-20 Angela Marie Thomas <angela@redhat.com>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_finish): Use NULL instead
+ of false when calling lang_size_sections.
+ * emultempl/hppaelf.em (hppaelf_layout_sections_again): Likewise.
+
+2001-11-15 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_finish): Only emit this
+ function when LDEMUL_FINISH isn't set to the same name. Don't
+ call ${LDEMUL_FINISH}.
+ (ld_${EMULATION_NAME}_emulation): Call $LDEMUL_FINISH if defined.
+ * emultempl/armelf.em (arm_elf_finish): Call
+ gld${EMULATION_NAME}_finish.
+ * emultempl/hppaelf.em (hppaelf_finish): Rename to
+ gld${EMULATION_NAME}_finish. Call bfd_elf32_discard_info and
+ hppaelf_layout_sections_again if necessary.
+ (need_laying_out): New var.
+ (hppaelf_layaout_sections_again): Rename to
+ hppaelf_layout_sections_again. Clear need_laying_out.
+ (PARSE_AND_LIST_OPTIONS): Format text.
+
+2001-11-14 H.J. Lu <hjl@gnu.org>
+
+ * emultempl/armelf.em (arm_elf_finish): Renamed from
+ gld${EMULATION_NAME}_finish.
+ (LDEMUL_FINISH): Set to arm_elf_finish.
+
+2001-11-14 Daniel Jacobowitz <drow@mvista.com>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_finish): New.
+ (struct ld_emulation_xfer_struct): Use it.
+
+2001-11-13 Ross Alexander <ross.alexander@uk.neceur.com>
+
+ * emulparams/elf64hppa.sh (OTHER_BSS_END_SYMBOLS): Add
+ additional symbols referenced by newer crt0.o files from HP.
+
+2001-11-12 Anthony Green <green@redhat.com>
+
+ * emulparams/armelf.sh (DATA_START_SYMBOLS): New symbol.
+
+2001-11-12 Alfred M. Szmidt <ams@kemisten.nu>
+
+ * Makefile.am (GENSCRIPTS): Quote ${exec_prefix}.
+ * Makefile.in: Regenerate.
+
+2001-11-02 Stephane Carrez <Stephane.Carrez@worldnet.fr>
+
+ * ld.texinfo: Use @command for commands, @option for options.
+ * Makefile.am (POD2MAN): Use 'GNU Development Tools' for
+ the page man title.
+ * Makefile.in: Rebuild.
+
+2001-11-04 Chris Demetriou <cgd@broadcom.com>
+
+ * configure.tgt (mips*el-*-netbsd*, mips*-*-netbsd*):
+ Add support for targets.
+
+2001-11-02 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * configure.in (ALL_LINGUAS): Add "fr" and "sv"
+ * configure: Regernate.
+ * po/fr.po: New file.
+ * po/sv.po: New file.
+
+2001-11-01 NIIBE Yutaka <gniibe@m17n.org>
+
+ * configure.tgt (sh-*-linux): Set targ_emul, targ_extra_emuls
+ as little endian default and to support big endian.
+
+2001-11-01 Chris Demetriou <cgd@broadcom.com>
+
+ * ld.texinfo (Options): Document new option, -nostdlib.
+ * lexsup.c (OPTION_NOSTDLIB): New definition.
+ (ld_options): Add entry for "nostdlib".
+ (parse_args): Handle OPTIONS_NOSTDLIB.
+ * ldfile.c (ldfile_add_library_path): Don't add directories
+ to the search path if they weren't specified on the command line
+ and -nostdlib was specified.
+ * ld.h (ld_config_type): New member only_cmd_line_lib_dirs.
+
+2001-10-31 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * lexsup.c (parse_args): Prevent infinite parsing loop when
+ "-rpath.a" is specified on the command line.
+ Replace calls to fprintf with calls to einfo.
+
+2001-10-31 John Marshall <jmarshall@acm.org>
+
+ * ld.texinfo: A historical requirement that MEMORY and SECTIONS
+ appear only once across all the linker scripts involved in a link
+ invocation no longer applies. Make the documentation reflect
+ that.
+
+2001-10-31 NIIBE Yutaka <gniibe@m17n.org>
+
+ * configure.tgt: Supports sh3/sh4/sh3eb/sh4eb-unknown-linux-gnu
+ targets.
+ (sh-*-linux*): Added targ_extra_libpath.
+
+2001-10-31 David Heine <dlheine@tensilica.com>
+
+ * ldlang.c (lang_size_sections): Keep a valid output_offset field
+ for padding statements.
+
+2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * configure.tgt (mmix-*-*): New target.
+ * Makefile.am (ALL_EMULATIONS): Add eelf64mmix.o and emmo.o.
+ Add dependencies to match.
+ * emulparams/mmo.sh, emulparams/elf64mmix.sh, emultempl/mmo.em,
+ emultempl/mmix-elfnmmo.em, emultempl/mmixelf.em,
+ scripttempl/mmo.sc: New files.
+ * gen-doc.texi: @set MMIX.
+ * ld.texinfo: Ditto.
+ [MMIX] Add MMIX node.
+ * Makefile.in: Regenerate.
+
+2001-10-29 Kazu Hirata <kazu@hxi.com>
+
+ * ldlang.c: Fix a comment typo.
+
+2001-10-23 Alan Modra <amodra@bigpond.net.au>
+
+ * configure.host: Move alpha*-*-linux-gnu* entry to generic
+ entries, and match *-*-linux*.
+
+2001-10-20 Alan Modra <amodra@bigpond.net.au>
+
+ * ldgram.y (mri_script_command): Surround processing of INCLUDE
+ with ldlex_script, ldlex_popstate.
+ (ifile_p1): Likewise.
+ * ldlex.l (EOF): Don't BEGIN(SCRIPT). Restore lineno from the
+ correct slot.
+ (lex_push_file): Save current lineno to lineno_stack. Set lineno
+ to 1. Don't BEGIN(SCRIPT).
+ (lex_redirect): Similarly.
+ * ldmain.c (main): Set yydebug non-zero if YYDEBUG.
+
+2001-10-20 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * scripttempl/armcoff.sc: Define __EH_FRAME_BEGIN__ and
+ __EH_FRAME_END__ and accept eh frames into data section.
+ Add ctor and dtor sections.
+
+2001-10-19 Danny Smith <danny_r_smith_2001@yahoo.co.nz>
+
+ * pe-dll.c (autofilter_objectlist): Add gcrt0.o.
+ (auto-export): Fix indentation.
+
+2001-10-18 Danny Smith <danny_r_smith_2001@yahoo.co.nz>
+
+ * pe-dll.c (autofilter_objectlist): Add startup objects
+ for profiling.
+ (auto-export): Constify char * p.
+ Extract file basename and use strcmp rather than ststr
+ for object lookup.
+
+2001-10-18 Chris Demetriou <cgd@broadcom.com>
+
+ * ldmain.c (get_emulation): Improve comment about the handling
+ of -mipsN options.
+
+2001-10-17 Alan Modra <amodra@bigpond.net.au>
+
+ * po/POTFILES.in: Regenerate.
+
+2001-10-16 Vassili Karpov <malc@pulsesoft.com>
+
+ * emultempl/elf32.em (gld*_list_options): Remove extra '\t' from
+ -z nocopyreloc and -z nocombreloc usage strings.
+
+2001-10-12 Vassili Karpov <malc@pulsesoft.com>
+
+ * emultempl/elf32.em (gld*_list_options): Include -z nocopyreloc
+ in usage.
+
+2001-10-11 Aleksey Romanov <aromanov@ennovatenetworks.com>
+
+ * scripttempl/armaout.sc: Place .bss section after end of aligned
+ data section to match behaviour of aout code in constructrion of
+ header.
+
+2001-10-11 Danny Smith <danny_r_smith_2001@yahoo.co.nz>
+
+ * pe-dll.c (autofilter_entry_type autofilter_liblist: Add
+ startup files for mingw32 dlls to list.
+
+2001-10-10 Chris Demetriou <cgd@broadcom.com>
+
+ * emultempl/elf32.em: Fix shell 'if' usage for portability.
+
+2001-10-08 Aldy Hernandez <aldyh@redhat.com>
+
+ * configure.tgt (targ): Add arm9e-*-elf.
+
+2001-10-05 H.J. Lu <hjl@gnu.org>
+
+ * genscripts.sh: Fix a typo in the last change.
+
+2001-10-05 Jakub Jelinek <jakub@redhat.com>
+
+ * emultempl/elf32.em (gld_*_list_options): Include -z combreloc and
+ -z nocombreloc in usage.
+
+2001-10-03 Jim Blandy <jimb@redhat.com>
+
+ * genscripts.sh: Include a comment at the top of each generated
+ script, explaining its purpose.
+
+2001-10-03 Vassili Karpov <malc@pulsesoft.com>
+
+ * emultempl/elf32.em (parse_args): Handle -z nocopyreloc.
+ * NEWS: Mention -z nocopyreloc.
+ * ld.texinfo (Options): Describe nocopyreloc.
+
+2001-10-03 Alan Modra <amodra@bigpond.net.au>
+
+ * configure: Regenerate.
+
+2001-10-02 Alan Modra <amodra@bigpond.net.au>
+
+ * ldver.h (ld_program_version): Remove declaration.
+ * lexsup.c (parse_args): Move printing of copyright message..
+ * ldver.c (ldversion): .. to here.
+ Use BFD_VERSION_STRING in place of BFD_VERSION.
+ (ld_program_version): Remove.
+ * Makefile.am (Makefile): Depend on bfd/configure.in.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2001-09-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * Makefile.am: Update dependencies with "make dep-am".
+ * Makefile.in: Regenerate.
+
+2001-09-29 John Reiser <jreiser@BitWagon.com>
+
+ * ldlang.c (lang_common): Conditionally inhibit Common allocation.
+ * lexsup.c: Add --no-define-common commandline option.
+ * ldgram.y: Add INHIBIT_COMMON_ALLOCATION script command.
+ * ldlex.l: Likewise.
+ * ld.h: Add command_line.inhibit_common_definition.
+ * ldmain.c (main): Initialize.
+ * ld.texinfo: Document.
+
+2001-09-29 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (section_already_linked): Remove assignment to kept_section.
+
+2001-09-26 Alan Modra <amodra@bigpond.net.au>
+
+ * ldmisc.c (USE_STDARG): Remove.
+ (info_msg): Define using VPARAMS, VA_OPEN, VA_FIXEDARG, VA_CLOSE.
+ (einfo): Likewise.
+ (minfo): Likewise.
+ (lfinfo): Likewise.
+
+ * ldmisc.h: Remove #ifdef ANSI_PROTOTYPES and non-ansi
+ declarations. Update copyright.
+
+2001-09-24 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * pe-dll.c: Remove obsoleted declaration of
+ pe_get_data_import_dll_name.
+ (pe_create_import_fixup): Fix thinko.
+
+ * ld.texinfo(enable-auto-import): Clarify the explanation.
+
+2001-09-24 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * pe-dll.c (pe_create_import_fixup): Revert previous patch.
+ * emultemp/pe.em (pe_data_import_dll): Move definition outside of
+ DLL_SUPPORT controlled code.
+
+2001-09-24 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * emultempl/pe.em(pe_data_import_dll): Make static.
+ (pe_get_data_import_dll_name): New accessor function.
+ * pe-dll.c(pe_create_import_fixup): call
+ pe_get_data_import_dll_name() from pe.em, instead of
+ directly accessing pe_data_import_dll variable from pe.em.
+
+2001-09-18 Bruno Haible <haible@clisp.cons.org>
+
+ * deffilep.y: Include "safe-ctype.h" instead of <ctype.h>.
+ (def_file_add_directive): Use ISSPACE instead of isspace.
+ (def_lex): Use ISDIGIT/ISXDIGIT/ISALPHA/ISALNUM instead of
+ isdigit/isxdigit/isalpha/isalnum.
+ * emultempl/aix.em: Include "safe-ctype.h" instead of <ctype.h>.
+ (gld${EMULATION_NAME}_read_file): Use ISSPACE instead of isspace.
+ * emultempl/elf32.em: Include "safe-ctype.h" instead of <ctype.h>.
+ (gld${EMULATION_NAME}_place_orphan): Use ISALNUM instead of
+ isalnum.
+ * emultempl/gld960c.em: Include "safe-ctype.h" instead of <ctype.h>.
+ (gld960_set_output_arch): Use ISUPPER/TOLOWER instead of
+ isupper/tolower.
+ * emultempl/sunos.em: Include "safe-ctype.h" instead of <ctype.h>.
+ (gld${EMULATION_NAME}_search_dir): Use ISDIGIT instead of isdigit.
+ * ldctor.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (ctor_prio): Use ISDIGIT instead of isdigit.
+ * ldfile.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (ldfile_open_file_search): Use ISALPHA instead of isalpha.
+ (ldfile_add_arch): Use ISUPPER/TOLOWER instead of
+ isupper/tolower.
+ * ldlang.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (stricpy): Use TOLOWER instead of isupper/tolower.
+ (lang_leave_overlay_section): Use ISALNUM instead of isalnum.
+ * ldlex.l: Include "safe-ctype.h" instead of <ctype.h>.
+ (lex_warn_invalid): Use ISPRINT instead of isprint.
+ * ldmain.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (main): For gettext, also set the LC_CTYPE locate facet.
+ (add_keepsyms_file): Use ISSPACE instead of isspace.
+ * lexsup.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (is_num, parse_args): Use ISDIGIT instead of isdigit.
+ * mpw-elfmips.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (gldelf32ebmip_place_orphan): Use ISALNUM instead of isalnum.
+ * mpw-eppcmac.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (gldppcmacos_read_file): Use ISSPACE instead of isspace.
+ * pe-dll.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (quoteput): Use ISSPACE instead of isspace.
+ (pe_dll_generate_implib, pe_process_import_defs): Use ISALNUM
+ instead of isalnum.
+
+2001-09-18 Alan Modra <amodra@bigpond.net.au>
+
+ * deffilep.y (def_stash_module): Constify "name" param.
+
+ * pe-dll.c: Replace CONST with const throughout.
+ (quick_symbol): Constify "n1", "n2", "n3" params.
+ (make_singleton_name_thunk): Constify "import" param. Make
+ "buffer_len" a size_t.
+ (make_import_fixup_entry): Constify "name", "fixup_name",
+ "dll_symname" params.
+ (pe_get16): Cast args of bfd_seek. Replace bfd_read with bfd_bread.
+ (pe_get32): Likewise.
+ (pe_implied_import_dll): Likewise.
+
+ * emultempl/beos.em (sort_by_file_name): Constify "ra", "rb".
+ (sort_by_section_name): Likewise.
+
+ * emultempl/pe.em: Move defines for arm_epoc_pe before bfd.h included.
+ (make_import_fixup): Cast printf arg, rel->address to long rather
+ than int.
+ (gld_${EMULATION_NAME}_after_open): Don't compare NULL against int.
+
+2001-09-15 Alan Modra <amodra@bigpond.net.au>
+
+ * ldmain.c (main): Rename BufferSize to ld_bufsz because HPUX
+ defines BufferSize. Increase buffer size by one.
+
+2001-09-14 Ralf Habacker <Ralf.Habacker@freenet.de>
+
+ * pe-dll.c (pe_walk_relocs_of_symbol): Fix memory leak.
+
+2001-09-14 Kevin Lo <kevlo@openbsd.org>
+
+ * configure.tgt: Add arm-openbsd target.
+
+2001-09-12 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.am (ALL_EMULATIONS): Move eelf64ppc.o and
+ eelf64lppc.o to ...
+ (ALL_64_EMULATIONS): Here.
+ * Makefile.in: Regenerated.
+
+2001-09-12 Paul Sokolovsky <Paul.Sokolovsky@technologist.com>
+
+ * emultempl/pe.em(make_import_fixup): change signature to
+ take asection as well as arelec; we need this for proper
+ error reporting. Only call pe_create_import_fixup() if
+ there is no attempt to add a constant addend to the reloc;
+ otherwise, report error condition.
+ * pe-dll.c(pe_walk_relocs_of_symbol): change signature,
+ since final argument is a pointer to make_import_fixup().
+ Change call to cb() to match make_import_fixup() signature.
+ (make_import_fixup_mark): make buffer_len unsigned.
+ * pe-dll.h: change signature of pe_walk_relocs_of_symbol.
+
+2001-09-12 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * ld.texinfo: add verbose documentation for auto-import
+ direct-addressing workaround, to compliment the terse
+ error message.
+
+2001-09-12 Andrew MacLeod <amacleod@redhat.com>
+
+ * scripttempl/v850.sc: Add gcc_except_table sections.
+
+2001-09-11 Jeffrey A Law (law@cygnus.com)
+
+ * emulparams/h8300helf.sh: Move stack to a much higher memory address.
+ * emulparams/h8300self.sh: Similarly.
+
+2001-09-05 Danny Smith <dannysmith@users.souceforge.net>
+
+ * ld.texinfo (Options, --stack): Correct default value for stack
+ reserve.
+
+2001-09-05 Tom Rix <trix@redhat.com>
+
+ * emultempl/aix.em : Handle import file XMC_XO and syscall symbols.
+
+2001-09-03 Andreas Jaeger <aj@suse.de>
+
+ * emultempl/beos.em: Declare prototypes for comparions functions,
+ adjust definitions.
+
+2001-09-02 Andreas Jaeger <aj@suse.de>
+
+ * emultempl/aix.em: Add missing prototype.
+ * emultempl/lnk960.em: Likewise.
+ * emultempl/vanilla.em: Likewise.
+ * emultempl/armcoff.em: Likewise.
+ * emultempl/armelf_oabi.em: Likewise.
+ * emultempl/beos.em: Likewise.
+ * emultempl/gld960c.em: Likewise.
+ * emultempl/gld960.em: Likewise.
+
+ * emulparams/elf64alpha.sh (PARSE_AND_LIST_PROLOGUE): Add parameter
+ for prototype declaration.
+
+2001-08-31 Eric Christopher <echristo@redhat.com>
+ Jason Eckhardt <jle@redhat.com>
+
+ * ldmain.c (get_emulation): Add support for -mips32 and -mips64.
+
+2001-08-31 Andreas Jaeger <aj@suse.de>
+
+ * emultempl/pe.em: Add missing prototypes.
+ (gld_${EMULATION_NAME}_after_open): Remove extra args to
+ pe_find_data_imports.
+ (pr_sym): Add unused attribute.
+
+2001-08-29 Joel Sherrill <joel@OARcorp.com>
+
+ * configure.tgt (i[3456]86-*-rtems*, m68*-*-rtems*): Change
+ default from coff to elf.
+
+2001-08-29 Jeff Law <law@redhat.com>
+
+ * emulparams/h8300helf.sh: Resync with h8300elf.sh. Update
+ ARCH specification.
+ * emulparams/h8300self.sh: Similarly.
+
+2001-08-28 J"orn Rennecke <amylaar@redhat.com>
+
+ * Makefile.am (ALL_EMULATIONS): Add eh8300elf.o, eh8300elf.o and
+ eh8300self.o .
+ (eh8300elf.c, eh8300helf.c, eh8300self.c): New targets.
+ * configure.tgt (h8300-*-elf*): New case.
+ * emulparams/h8300elf.sh, emulparams/h8300helf.sh: New files.
+ * emulparams/h8300self.sh: New file.
+ * Makefile.in: Regenerated.
+
+2001-08-28 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * ldmain.c (main): Rename BSIZE to BufferSize to avoid collision
+ with macro name.
+
+2001-08-27 Linus Nordberg <linus@swox.com>
+ Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (ALL_EMULATIONS): Add eelf64ppc.o and eelf64lppc.o.
+ (eelf64ppc.c, eelf64lppc.c): Add make targets.
+ Run "make dep-am"
+ * Makefile.in: Regenerate.
+ * configure.tgt: Add powerpc64 support. Move pdp11, pjl, pj
+ entries to correct alphabetical position.
+ * emulparams/elf64ppc.sh: New.
+ * emulparams/elf64lppc.sh: New.
+
+2001-08-27 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * ldmain.c (main): Declare BSIZE as static.
+
+2001-08-23 Jakub Jelinek <jakub@redhat.com>
+
+ * emultempl/elf32.em (place_orphan): Place orphan .rel* sections
+ into .rel.dyn resp. .rela.dyn if combreloc.
+ (get_script): If .x linker script is equal to .xn, only put it
+ once into the binary.
+ Add .xc and .xsc scripts.
+ (parse_args): Handle -z combreloc and -z nocombreloc.
+ * scripttempl/elf.sc (.rela.sbss): Fix a typo.
+ For .xc and .xsc scripts put all .rel* or .rela* input sections
+ but .rel*.plt and PLT-like sections into .rel.dyn resp. .rela.dyn.
+ * genscripts.sh (GENERATE_COMBRELOC_SCRIPT): Set if SCRIPT_NAME
+ is elf.
+ Strip trailing whitespace from script.
+ Generate .xc and .xsc scripts if requested.
+ * ldmain.c (main): Initialize link_info.combreloc and
+ link_info.spare_dynamic_tags.
+ * lexsup.c (OPTION_SPARE_DYNAMIC_TAGS): Define.
+ (ld_options): Add --spare-dynamic-tags option.
+ (parse_args): Likewise.
+ * ld.texinfo: Document -z combreloc and -z nocombreloc.
+ * ldint.texinfo: Document .xc and .xsc linker scripts.
+ * NEWS: Add notes about -z combreloc and SHF_MERGE.
+
+2001-08-22 H.J. Lu <hjl@gnu.org>
+
+ * emulparams/elf32fr30.sh: Add a newline.
+
+2001-08-21 Andreas Jaeger <aj@suse.de>
+
+ * deffilep.y: Add missing prototypes.
+ * pe-dll.c: Likewise.
+
+2001-08-20 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (insert_pad): Fix typos in last patch.
+
+ * ldlang.c: When traversing lang_statement_union_type lists,
+ consistently use "header.next" rather than "next".
+ * mpw-eppcmac.c: Likewise.
+ * emultempl/beos.em: Likewise.
+ * emultempl/hppaelf.em: Likewise.
+ * emultempl/pe.em: Likewise.
+ * ldlang.h (union lang_statement_union): Remove "next" field.
+
+ * ldlang.c (insert_pad): Use offsetof macro.
+ (lang_size_sections): Always neuter padding statements.
+ * emultempl/hppaelf.em (hppaelf_delete_padding_statements): Delete.
+
+ * pe-dll.c (pe_dll_fill_sections): Correct type of "relax" param
+ passed to lang_size_sections.
+ (pe_exe_fill_sections): Likewise.
+ * emultempl/pe.em (output_prev_sec_find): Copied from elf32.em.
+ (gld_${EMULATION_NAME}_place_orphan): Merge from elf32.em.
+
+2001-08-18 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/aix.em: Formatting fixes.
+
+2001-08-18 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (insert_pad): Make use of an existing pad statement if
+ available. Move code calculating alignment, adjusting section
+ alignment power, and adjusting dot to ..
+ (size_input_section): .. here. Remove unused relax param.
+ (lang_size_sections): Change boolean `relax' param to boolean *.
+ Adjust call to size_input_section. Make use of insert_pad to
+ place pad after the assignment statement. If relaxing, zap
+ padding statements.
+ (reset_memory_regions): Reset output_bfd section sizes too.
+ (relax_again): Move to..
+ (lang_process): ..here. Adjust call to lang_size_sections, and
+ remove duplicated code.
+ * ldlang.h (lang_size_sections): Change `relax' param to boolean *.
+
+2001-08-17 Alan Modra <amodra@bigpond.net.au>
+
+ * ld.texinfo: Document that fill values now use the four least
+ significant bytes.
+ * emulparams/elf32fr30.sh (NOP): Update.
+ * emulparams/elf32mcore.sh: Likewise.
+ * emulparams/elf64_s390.sh: Likewise.
+ * emulparams/elf_i386.sh: Likewise.
+ * emulparams/elf_i386_be.sh: Likewise.
+ * emulparams/elf_i386_chaos.sh: Likewise.
+ * emulparams/elf_i386_ldso.sh: Likewise.
+ * emulparams/elf_s390.sh: Likewise.
+ * emulparams/elf_x86_64.sh: Likewise.
+ * emulparams/i386moss.sh: Likewise.
+ * emulparams/i386nw.sh: Likewise.
+ * emulparams/m68kelf.sh: Likewise.
+ * scripttempl/elf.sc: Update NOP comment.
+ * scripttempl/elfi370.sc: Likewise.
+ * scripttempl/elfm68hc11.sc: Likewise.
+ * scripttempl/elfm68hc12.sc: Likewise.
+ * scripttempl/nw.sc: Likewise.
+
+2001-08-15 Tom Rix <trix@redhat.com>
+
+ * ldgram.y (saved_script_handle): Initialize to NULL.
+ * ldmain.c (main): Change check on saved_script_handle.
+
+2001-08-14 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/elf32.em: Formatting fixes.
+ (output_prev_sec_find): Test for bfd_ind_section too; do so by
+ looking at sec->owner.
+ (output_rel_find): Move function inside LDEMUL_PLACE_ORPHAN test.
+ (gld${EMULATION_NAME}_place_orphan): Add a few comments. Remove
+ unused code, and reorganize orphan section placement code.
+
+ * ldlang.c (wild_doit): Rename to lang_add_section.
+ * ldlang.h: Here too.
+ * mpw-elfmips.c: And here.
+ * emultempl/beos.em: And here.
+ * emultempl/elf32.em: And here.
+ * emultempl/hppaelf.em: And here.
+ * emultempl/pe.em: And here.
+
+2001-08-13 Richard Henderson <rth@redhat.com>
+
+ * emultempl/needrelax.em: New file.
+ * emulparams/elf64_ia64.sh (EXTRA_EM_FILE): Reference it.
+ * Makefile.am (eelf64_ia64.c): Depend on it.
+ * Makefile.in: Rebuild.
+
+2001-08-13 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/elf32.em: For SEC_EXCLUDE sections, ensure that
+ output_section is set non-NULL.
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Return
+ `true' for SEC_EXCLUDE sections so that the generic code doesn't
+ needlessly create an output_section_statement. Treat a correctly
+ named output_section_statement with NULL bfd_section as compatible.
+
+2001-08-13 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * emultempl/generic.em: Support EXTRA_EM_FILE.
+ (ld_${EMULATION_NAME}_emulation): Support emulation parameters
+ LDEMUL_BEFORE_PARSE, LDEMUL_SYSLIB, LDEMUL_HLL,
+ LDEMUL_AFTER_PARSE, LDEMUL_AFTER_OPEN, LDEMUL_AFTER_ALLOCATION,
+ LDEMUL_SET_OUTPUT_ARCH, LDEMUL_CHOOSE_TARGET,
+ LDEMUL_BEFORE_ALLOCATION, LDEMUL_GET_SCRIPT, LDEMUL_FINISH,
+ LDEMUL_CREATE_OUTPUT_SECTION_STATEMENTS,
+ LDEMUL_OPEN_DYNAMIC_ARCHIVE, LDEMUL_PLACE_ORPHAN,
+ LDEMUL_SET_SYMBOLS, LDEMUL_PARSE_ARGS, LDEMUL_UNRECOGNIZED_FILE,
+ LDEMUL_LIST_OPTIONS, LDEMUL_RECOGNIZED_FILE,
+ LDEMUL_FIND_POTENTIAL_LIBRARIES.
+
+2001-08-12 Richard Henderson <rth@redhat.com>
+
+ * scripttempl/elf.sc, scripttempl/elfd30v.sc,
+ scripttempl/elfm68hc11.sc, scripttempl/elfm68hc12.sc,
+ scripttempl/v850.sc: Keep .jcr data.
+
+2001-08-12 H.J. Lu <hjl@gnu.org>
+ Andrew Haley <aph@cambridge.redhat.com>
+ Nick Clifton <nickc@redhat.com>
+
+ * ldgram.y (had_script): Change name to saved_script_handle.
+ Change type to file handle.
+ * ld.h (had_script): Rename and retype.
+ * ldfile.c (ldfile_open_command_file): Save the file handle
+ used in saved_script_handle.
+ * lexsup.c (parse_args): Do not allow -c option to alter
+ saved_script_handle.
+ * ldmain.c (main): Print out the linker script used if
+ --verbose is given. Check saved_script_handle to obtain the
+ external linker script used, or if NULL, dump the builtin
+ script.
+ * ld.texinfo: Document that --verbose now dumps the linker
+ script used, regardless of whether it was an internal or an
+ external script.
+
+2001-08-10 Andreas Jaeger <aj@suse.de>
+
+ * configure.in: Add -Wstrict-prototypes and -Wmissing-prototypes
+ to build warnings.
+ * configure: Regenerate.
+
+2001-08-09 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/elf32.em (output_prev_sec_find): Add missing prototype.
+
+ * scripttempl/elf.sc: Move non-text .dynamic section before
+ .plt/.got/.sdata* group.
+ (OTHER_GOT_SECTIONS): Move to immediately after .got.
+ (OTHER_SDATA_SECTIONS): Add.
+ * emulparams/criself.sh: Use OTHER_SDATA_SECTIONS rather than
+ OTHER_GOT_SECTIONS.
+ * emulparams/crislinux.sh: Likewise.
+ * emulparams/elf32b4300.sh: Likewise.
+ * emulparams/elf32bmip.sh: Likewise.
+ * emulparams/elf32bmipn32.sh: Likewise.
+ * emulparams/elf32bsmip.sh: Likewise.
+ * emulparams/elf32btsmip.sh: Likewise.
+ * emulparams/elf32ebmip.sh: Likewise.
+ * emulparams/elf32elmip.sh: Likewise.
+ * emulparams/elf32l4300.sh: Likewise.
+ * emulparams/elf32lmip.sh: Likewise.
+ * emulparams/elf32lsmip.sh: Likewise.
+ * emulparams/elf32ltsmip.sh: Likewise.
+ * emulparams/elf64bmip.sh: Likewise.
+ * emulparams/elf64btsmip.sh: Likewise.
+ * emulparams/elf64ltsmip.sh: Likewise.
+
+2001-08-08 Alan Modra <amodra@bigpond.net.au>
+
+ * genscripts.sh: Source the emulparams script before each output
+ script is generated so that variables like `RELOCATING' may affect
+ variables defined in the emulparams script.
+
+2001-08-04 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/aix.em: ldexp.h,ldlang.h,ldfile.h,ldemul.h go in this
+ order.
+
+ * emultempl/beos.em (sort_sections): Modify for 2001-08-03 change,
+ ie. iterate over wild_statement.section_list.
+ (gld${EMULATION_NAME}_place_orphan): Likewise.
+
+2001-08-03 Stephane Carrez <Stephane.Carrez@worldnet.fr>
+
+ * scripttempl/elfm68hc12.sc (FINISH_CODE, FINISH_RELOC): New to handle
+ .fini[0-4] sections used by _exit
+ (CTOR, DTOR): Export ctor/dtor symbols; move them to ROM.
+ (*.text,*.data,*.bss): Take into account .text.*, .data.*, .bss.*.
+ * scripttempl/elfm68hc11.sc: Likewise.
+
+2001-08-03 H.J. Lu <hjl@gnu.org>
+
+ * emultempl/beos.em (init): Add the missing initialization.
+
+2001-08-03 Alan Modra <amodra@bigpond.net.au>
+
+ * ld.texinfo (Input Section Basics): Clarify ordering of output
+ sections.
+ * ldlang.c (callback_t): Add wildcard_list param.
+ (walk_wild_section): Remove "section" param. Rewrite for
+ lang_wild_statement_type change. Remove unique_section_p test.
+ (walk_wild_file): Remove "section" param.
+ (walk_wild): Remove "section" and "file" params.
+ (lang_gc_wild): Likewise.
+ (wild): Likewise. Modify for lang_wild_statement_type change.
+ (wild_sort): Likewise. Add "sec" param.
+ (gc_section_callback): Likewise.
+ (output_section_callback): Likewise. Do unique_section_p test.
+ (map_input_to_output_sections): Modify call to wild.
+ (lang_gc_sections_1): Likewise.
+ (print_wild_statement): Modify for lang_wild_statement_type
+ change.
+ (lang_add_wild): Replace filename, filenames_sorted param with
+ filespec. Replace section_name, sections_sorted,
+ exclude_filename_list with section_list.
+ * ldlang.h (lang_add_wild): Here too.
+ (lang_wild_statement_type): Replace section_name, sections_sorted,
+ and exclude_filename_list with section_list.
+ * ldgram.y (current_file): Delete.
+ (%union): Add wildcard_list.
+ (file_NAME_list): Set type to wildcard_list. Build a linked list
+ rather than calling lang_add_wild for each entry.
+ (input_section_spec_no_keep): Call lang_add_wild here instead.
+ * ld.h (struct wildcard_list): Declare.
+ * mri.c (mri_draw_tree): Modify to suit new lang_add_wild.
+
+2001-08-02 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * ldmain.c (main): initialize link_info.pei386_auto_import
+ * pe-dll.c: new tables for auto-export filtering
+ (auto_export): change API, pass abfd for contextual filtering.
+ Loop thru tables of excluded symbols instead of comparing
+ "by hand".
+
+2001-08-02 Paul Sokolovsky <paul.sokolovsky@technologist.com>
+
+ * pe-dll.c: new variable pe_dll_enable_extra_debug. New
+ static variable current_sec (static struct sec *). Add
+ forward declaration for add_bfd_to_link.
+ (process_def_file): Don't export undefined symbols. Do not
+ export symbols starting with "_imp__". Call auto_export()
+ with new API.
+ (pe_walk_relocs_of_symbol): New function.
+ (generate_reloc): add optional extra debugging
+ (pe_dll_generate_def_file): eliminate extraneous initial blank
+ line in output
+ (make_one): enlarge symtab to make room for __nm__ symbols
+ (DATA auto-import support).
+ (make_singleton_name_thunk): New function.
+ (make_import_fixup_mark): New function.
+ (make_import_fixup_entry): New function.
+ (pe_create_import_fixup): New function.
+ (add_bfd_to_link): Specify that 'name' argument is a CONST
+ char *.
+ * pe-dll.h: declare new variable pe_dll_extra_pe_debug;
+ declare new functions pe_walk_relocs_of_symbol and
+ pe_create_import_fixup.
+ * emultempl/pe.em: add new options --enable-auto-import,
+ --disable-auto-import, and --enable-extra-pe-debug.
+ (make_import_fixup): New function.
+ (pe_find_data_imports): New function.
+ (pr_sym): New function.
+ (gld_${EMULATION_NAME}_after_open): Add optional extra pe
+ debugging. Call pe_find_data_imports. Mark .idata as DATA, not
+ CODE.
+
+2001-08-02 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * ld.texinfo: add additional documentation for
+ --export-all-symbols. Document --out-implib,
+ --enable-auto-image-base, --disable-auto-image-base,
+ --dll-search-prefix, --enable-auto-import, and
+ --disable-auto-import.
+ * ldint.texinfo: Add detailed documentation on auto-import
+ implementation.
+
+2001-07-30 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * ld.texinfo (Simple Assignments): Fix computation in SECTIONS
+ example.
+
+2001-07-24 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Update dependencies with "make dep-am".
+ * Makefile.in: Regenerate
+
+2001-07-23 Alan Modra <amodra@bigpond.net.au>
+
+ * ldcref.c (check_section_sym_xref): New function.
+ (check_nocrossrefs): Call it.
+ (check_nocrossref): Interate over h->refs here instead of..
+ (check_refs): ..here. Pass in the symbol name, section, and bfd
+ rather than hash_entry pointers.
+ (struct check_refs_info): Keep symbol name rather than hash entry.
+ Remove "same".
+ (check_reloc_refs): Tweak for above changes in check_refs_info.
+ Only report references to section syms when symname is NULL to
+ prevent duplicate messages for the same reloc.
+
+2001-07-19 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * ldexp.c (exp_print_tree): Use stderr if config.map_file is not
+ available. Do not print NULL trees.
+ (exp_print_token): Print unknown tokens with values > 126 as
+ decimal values not ASCII characters.
+
+ * ldlang.c (lang_leave_overlay): If a region is specified assign
+ it to all sections inside the overlay unless they have been
+ assigned to the own, non-default, memory region.
+
+ * README: Add header for consistency with other README files.
+
+2001-07-14 H.J. Lu <hjl@gnu.org>
+
+ * emultempl/elf32.em (output_prev_sec_find): Never return
+ bfd_abs_section_ptr, bfd_com_section_ptr nor
+ bfd_und_section_ptr.
+
+2001-07-14 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * Makefile.am (em32relf.c): Change dependency from generic.em to
+ elf32.em.
+ * Makefile.in: Regenerate.
+
+2001-07-14 matthew green <mrg@eterna.com.au>
+
+ * configure.tgt (i386-*-netbsdelf*): New target.
+ (i386-*-netbsd*): Set targ_extra_emuls to `elf_i386'
+
+2001-07-13 Jakub Jelinek <jakub@redhat.com>
+
+ * emultempl/elf32.em (output_prev_sec_find): New.
+ (place_orphan): Use it.
+
+2001-07-11 H.J. Lu <hjl@gnu.org>
+
+ * ldmain.c (main): Fix typos in the last change.
+
+2001-07-11 Jakub Jelinek <jakub@redhat.com>
+
+ * ldmain.c (main): Disallow -F and -f without -shared.
+
+2001-07-11 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * emultempl/pe.em (after_open): Check for the output_bfd not
+ having any coff_data structure allocated to it.
+
+2001-07-09 David O'Brien <obrien@FreeBSD.org>
+
+ * emultempl/elf32.em: Do not assuming that contents of the buffer
+ returned from basename function will remain unchanged accross other
+ function calls.
+
+2001-07-03 H.J. Lu <hjl@gnu.org>
+
+ * scripttempl/elf.sc (DYNAMIC_PAD): Revert the change made on
+ 2001-07-03. It creates dynamic entries even for static binaries.
+
+2001-07-03 Jakub Jelinek <jakub@redhat.com>
+
+ * scripttempl/elf.sc (DYNAMIC_PAD): New variable.
+ (DYNAMIC): Use it to reserve few dynamic entries for
+ post-linking tools.
+
+2001-06-27 Alan Modra <amodra@bigpond.net.au>
+
+ * emulparams/hppa64linux.sh: New file.
+ * configure.tgt: hppa*64*-*-linux* uses hppa64linux.sh
+ * Makefile.am (ALL_64_EMULATIONS): Add ehppa64linux.o
+ (ehppa64linux.c): Add rule to make it.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2001-06-21 Hans-Peter Nilsson <hp@axis.com>
+
+ * ld.texinfo (Options, -r): Mention restrictions when using
+ different object formats.
+
+2001-06-19 Hans-Peter Nilsson <hp@axis.com>
+
+ * ldlang.c (lang_check): Emit fatal error if relocatable link
+ between different object flavours with relocations in input.
+
+2001-06-19 H.J. Lu <hjl@gnu.org>
+
+ * ld.texinfo (-E, --export-dynamic): Mention --version-script.
+ (--version-script): Mention the language support.
+
+2001-06-19 H.J. Lu <hjl@gnu.org>
+
+ * ldlang.c (lang_check): Revert the change mode on 2001-06-15.
+
+2001-06-18 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.am (ld.1): Remove the prefix `$(srcdir)/'.
+ (diststuff): Add $(MANS).
+ * Makefile.in: Regenerated.
+
+ * ld.1: Removed.
+
+2001-06-18 Hans-Peter Nilsson <hp@axis.com>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation):
+ Update for API change in bfd_elf${ELFSIZE}_size_dynamic_sections.
+ * mpw-elfmips.c (gldelf32ebmip_before_allocation): Ditto.
+ * ld.h (args_type): Remove member export_dynamic. All users
+ changed to use struct bfd_link_info member.
+
+ * Makefile.am (ecriself.c, ed10velf.c, ei386moss.c): Depend on
+ $(srcdir)/emultempl/elf32.em, not $(srcdir)/emultempl/generic.em.
+ * Makefile.in: Regenerate.
+
+2001-06-18 H.J. Lu <hjl@gnu.org>
+
+ * ldlang.c (init_os): Add the newline to the einfo call.
+ (lang_check): Likewise.
+ (lang_do_version_exports_section): Likewise.
+
+2001-06-15 H.J. Lu <hjl@gnu.org>
+
+ * lexsup.c (parse_args); Save optind to report unrecognized
+ option.
+
+2001-06-15 Hans-Peter Nilsson <hp@axis.com>
+
+ * ldlang.c (lang_check): Emit fatal error if relocatable link
+ between different object flavours.
+
+ * lexsup.c (parse_args) <case OPTION_EXPORT_DYNAMIC, case 'E'>:
+ Set new link_info member export_dynamic.
+ * ldmain.c (main): Initialize new link_info member export_dynamic.
+
+2001-06-12 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * ldlang.c (walk_wild): Only call walk_wild_file if
+ lookup_name returns something.
+ (lookup_name): If load_symbols fails, return NULL.
+ (load_symbols): Change to a boolean function.
+ (open_input_bfds): If load_symbols fails then do not make the
+ executable.
+
+2001-06-08 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (record_bfd_errors): Remove.
+
+ * emultempl/aix.em: Fix copyright dates.
+
+2001-06-07 Andreas Jaeger <aj@suse.de>
+
+ * elf_x86_64.sh (NONPAGED_TEXT_START_ADDR): Increase.
+ (TEXT_START_ADDR): Likewise.
+
+2001-06-06 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * configure.host: Set HOSTING_CRT0/HOSTING_LIBS correctly for s/390.
+
+2001-06-05 Danny Smith <danny_r_smith_2001@yahoo.co.nz>
+
+ * emultempl/pe.em (init): Reduce default stack reserve to 0x200000.
+
+2001-05-31 H.J. Lu <hjl@gnu.org>
+
+ * ldlang.c (open_input_bfds): Don't change the bfd error
+ handler whilst loading symbols.
+
+2001-05-28 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * configure.tgt: Remove i370-mvs architecture, it is not currently
+ supported.
+
+2001-05-25 H.J. Lu <hjl@gnu.org>
+
+ * emulparams/ppcmacos.sh: Add SYSCALL_MASK and SYMBOL_MODE_MASK
+ like emulparams/aixppc.sh.
+
+2001-05-25 H.J. Lu <hjl@gnu.org>
+
+ * emultempl/beos.em (gld${EMULATION_NAME}_before_parse): Move
+ setting of output_filename after bfd_scan_arch.
+ * emultempl/pe.em: Likewise.
+
+2001-05-25 H.J. Lu <hjl@gnu.org>
+
+ * emulparams/aixrs6.sh: Add SYSCALL_MASK and SYMBOL_MODE_MASK
+ like emulparams/aixppc.sh.
+
+ * emultempl/aix.em (sc): Use ${srcdir}/emultempl/ostring.sed
+ instead of ${srcdir}/emultempl/stringify.sed.
+
+2001-05-25 Timothy Wall <twall@oculustech.com>
+
+ * emulparams/elf64_aix.sh: Change settings to match IBM linker
+ output.
+
+2001-05-25 Alan Modra <amodra@one.net.au>
+
+ * configure.host: Replace linuxoldld with linux*oldld.
+ * configure.tgt: Likewise.
+
+2001-05-24 H.J. Lu <hjl@gnu.org>
+
+ * emultempl/stringify.sed: Removed again.
+
+2001-05-24 H.J. Lu <hjl@gnu.org>
+
+ * emultempl/aix.em (OUTPUT_ARCH): Defined.
+ (gld${EMULATION_NAME}_before_parse): Initialize
+ ldfile_output_architecture, ldfile_output_machine and
+ ldfile_output_machine_name from ${OUTPUT_ARCH} if possible.
+ * emultempl/beos.em: Likewise.
+ * emultempl/elf32.em: Likewise.
+ * emultempl/linux.em: Likewise.
+ * emultempl/mipsecoff.em: Likewise.
+ * emultempl/pe.em: Likewise.
+ * emultempl/sunos.em: Likewise.
+
+2001-05-24 Tom Rix <trix@redhat.com>
+
+ * emultempl/aix.em : (gld${EMULATION_NAME}_read_file)
+ udate import file format.
+ (change_symbol_mode) New, same
+ (is_syscall) New, same
+ * emulparams/aixppc.sh : add SYSCALL_MASK and SYMBOL_MODE_MASK
+ * emulparams/aixppc64.sh : same
+ * emulparams/aixrs6.sh : same
+ * emulparams/ppcmacos.sh : same
+ * emultempl/aix.em : use strtoull to parse options
+ * Makefile.am : add eaixppc64 emulation for xcoff64
+ * Makefile.in : same
+ * configure.tgt : same
+
+ * scripttempl/aix.sc : default text section offset to 0x10000000
+ default data section offset to 0x20000000
+ add .sv3264 and .sv64 pseudo sections
+ loader and debug sections use the currect section offset.
+
+ * emultempl/aix.em : Add xcoff64 support
+ Add -binitfini support
+ (gld${EMULATION_NAME}_before_parse) -binitfini
+ (gld${EMULATION_NAME}_parse_args) same
+ (gld${EMULATION_NAME}_before_allocation) format change for special
+ sections
+
+ * emulparams/aixppc64.sh : New file for xcoff64 support
+
+2001-05-23 Alexandre Oliva <aoliva@redhat.com>
+
+ * emultempl/elf32.em (ELF_INTERPRETER_SET_DEFAULT): Use this new
+ variable to avoid non-portable shell construct.
+
+2001-05-23 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * ldmain.c (get_emulation): Add -mips5 command line argument.
+
+2001-05-22 Alexandre Oliva <aoliva@redhat.com>
+
+ * emulparams/elf_i386_ldso.sh: New, copied from elf_i386.sh.
+ (ELF_INTERPRETER_NAME): Define it.
+ * emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation): Use
+ it.
+ * configure.tgt (targ_emul, targ_extra_emuls)
+ [i[3456]86-*-solaris2*, i[3456]86-*-solaris*]: Use elf_i386_ldso
+ as primary, elf_i386 as extra.
+ * Makefile.am (ALL_EMULATIONS): Added eelf_i386_ldso.o.
+ (eelf_i386_ldso.c): New rule.
+ * Makefile.in: Rebuilt.
+
+2001-05-22 Nick Clifton <nickc@redhat.com>
+
+ * lexsup.c (ld_options): Allow -I to be an alias for
+ --dynamic-linker. This is for Solaris compatability.
+ * ld.texinfo: Document that -I can be used.
+ * ld.1: Regenerate.
+
+2001-05-16 Alan Modra <amodra@one.net.au>
+
+ * ldlang.c (wild_doit): Use linker_has_input to reliably determine
+ whether an input section is the first one assigned to an output
+ section.
+ Assorted formatting fixes.
+
+2001-05-14 DJ Delorie <dj@delorie.com>
+
+ * Makefile.am (ld.dvi): Search bfd/doc for texinfo files.
+ * Makefile.in: Ditto.
+
+2001-05-11 Jakub Jelinek <jakub@redhat.com>
+
+ * emulparams/elf64_ia64.sh (OTHER_READONLY_SECTIONS): Put
+ .gnu.linkonce.ia64unw{,i} sections into corresponding .IA_64.unwind*
+ output sections.
+ * emulparams/elf64_aix.sh (OTHER_READONLY_SECTIONS): Likewise.
+
+2001-05-11 Jakub Jelinek <jakub@redhat.com>
+
+ * ldlang.c (lang_process): Call bfd_merge_sections.
+
+2001-05-07 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * ldgram.y: Fix typo.
+
+2001-05-03 H.J. Lu <hjl@gnu.org>
+
+ * emultempl/elf32.em: Include "libiberty.h".
+ (gld${EMULATION_NAME}_vercheck): Call basename () to get the
+ basename of the bfd filename.
+ (gld${EMULATION_NAME}_stat_needed): Likewise.
+ (gld${EMULATION_NAME}_try_needed): Likewise.
+ (gld${EMULATION_NAME}_open_dynamic_archive): Likewise.
+
+2001-05-02 H.J. Lu <hjl@gnu.org>
+
+ * emultempl/pe.em: Include <ctype.h>.
+
+2001-05-02 Johan Rydberg <jrydberg@opencores.org>
+
+ * emulparams/elf32openrisc.sh: New file.
+
+ * Makefile.am: Add OpenRISC target.
+ * Makefile.in: Regenerated.
+
+ * configure.tgt: Add openrisc-*-* mapping.
+
+2001-05-02 Nick Clifton <nickc@redhat.com>
+
+ * emultempl/aix.em: Replace buystring with xstrdup.
+ * emultempl/beos.em: Replace buystring with xstrdup.
+
+2001-05-02 H.J. Lu <hjl@gnu.org>
+
+ * ldfile.c: Include "libiberty.h".
+ * ldlex.l: Likewise.
+
+ * ldmisc.c (buystring): Removed.
+ * ldmisc.h: Likewise.
+
+ * ldfile.c: Replace buystring with xstrdup.
+ * ldlang.c: Likewise.
+ * ldlex.l: Likewise.
+ * ldmain.c: Likewise.
+ * ldmisc.c: Likewise.
+ * lexsup.c: Likewise.
+ * mpw-eppcmac.c: Likewise.
+
+2001-04-30 Andreas Jaeger <aj@suse.de>
+
+ * emulparms/elf_x86_64.sh (MAXPAGESIZE): Fix value.
+
+2001-04-28 Paul Sokolovsky <Paul.Sokolovsky@technologist.com>
+
+ * ldlang.c (load_symbols): Give emulation a chance
+ to process unrecognized file before fatal error is
+ reported, not after.
+
+2001-04-27 Sean McNeil <sean@mcneil.com>
+
+ * configure.tgt: Add arm-vxworks target.
+ * scripttempl/armcoff.sc: Support .text or .data as a section name
+ prefix.
+ Define _etext.
+
+2001-04-13 J.T. Conklin <jtc@redback.com>
+
+ * ld.texinfo: Document --fatal-warnings.
+ * ld.1: Regenerate.
+
+ * ldmisc.c (vfinfo): Set flag to inhibit making executable if
+ warnings have been turned into errors.
+ * lexsup.c (OPTION_WARN_FATAL): Define.
+ (ld_options): Entry for --fatal-warnings.
+ (parse_args): Handle OPTION_WARN_FATAL.
+ * ld.h (ld_config_type): Add fatal_warnings field.
+
+2001-04-13 Jakub Jelinek <jakub@redhat.com>
+
+ * ldmain.c (main): Default to discard_sec_merge.
+ * lexsup.c (OPTION_DISCARD_NONE): Define.
+ (ld_options): Add --discard-none.
+ (parse_args): Handle OPTION_DISCARD_NONE.
+ * ldlang.c (wild_doit): SEC_MERGE should be set in the output
+ section only if SEC_MERGE and SEC_STRINGS flags and entsize of
+ all its input sections match.
+
+2001-04-05 Steven J. Hill <sjhill@cotw.com>
+
+ * Makefile.am (ALL_EMULATIONS): Add eelf32ltsmip.o.
+ (ALL_64_EMULATIONS): Add eelf64btsmip.o and eelf64ltsmip.o.
+ (eelf32ltsmip.c): New target.
+ (eelf64btsmip.c): Likewise.
+ (eelf64ltsmip.c): Likewise.
+ * Makefile.in: Regenerated.
+
+ * configure.tgt (mips*el-*-linux-gnu): Uses traditional MIPS
+ target.
+ (mips*-*-linux-gnu*): Likewise.
+
+ * emulparams/elf32ltsmip.sh: New. Traditional little endian
+ MIPS taget.
+ * emulparams/elf64btsmip.sh: New. Traditional 64bit big endian
+ target.
+ * emulparams/elf64ltsmip.sh: New. Traditional 64bit little
+ endian target.
+
+2001-04-05 Hans-Peter Nilsson <hp@axis.com>
+
+ * emulparams/criself.sh (EXECUTABLE_SYMBOLS): Cannot provide
+ correct value of __Stext here.
+ (TEXT_START_SYMBOLS): Define; always define __Stext, to start of
+ .startup section.
+
+ * emulparams/crislinux.sh: Remove FIXME.
+
+2001-04-02 Alan Modra <alan@linuxcare.com.au>
+
+ * emulparams/hppalinux.sh (MAXPAGESIZE): Set to 64k.
+ (TEXT_START_ADDR, TARGET_PAGE_SIZE): Likewise.
+
+2001-03-27 Hans-Peter Nilsson <hp@axis.com>
+
+ * configure.tgt (cris-*-*): Change default emulation to criself.
+ (cris-*-*aout*): New rule.
+
+2001-03-27 Matthew Wilcox <willy@ldl.fc.hp.com>
+
+ * emulparams/hppalinux.sh (MAXPAGESIZE): Set to 0x4000.
+ (TEXT_START_ADDR, TARGET_PAGE_SIZE): Ditto.
+
+2001-03-26 Andreas Jaeger <aj@suse.de>
+
+ * ld.texinfo (Overview): Fix syntax in texi code.
+
+2001-03-25 Stephane Carrez <Stephane.Carrez@worldnet.fr>
+
+ * ld.texinfo: Put @c man indications to generate the ld man page.
+ When generating man, define all the variables. Define SEEALSO
+ and SYNOPSIS. Re-organize some lines to avoid the cross references.
+ * Makefile.am (MANCONF, TEXI2POD, POD2MAN): New variables.
+ (ld.1): Generate from ld.texinfo.
+ * Makefile.in: Regenerate.
+
+2001-03-23 Mark Elbrecht <snowball3@bigfoot.com>
+
+ * scripttempl/i386go32.sc: Support the GCC flags '-ffunction-sections'
+ and '-fdata-sections'. Set the VMA of STABS sections to zero.
+
+2001-03-17 Ulrich Drepper <drepper@redhat.com>
+
+ * emultmpl/elf32.em (gld${EMULATION_NAME}_search_needed): If NAME
+ is an absolute path look only for this file and not along the path.
+
+2001-03-17 Ulrich Drepper <drepper@redhat.com>
+
+ * emultempl/elf32.em (OPTION_GROUP): New macro.
+ Add new option Bgroup to longopts.
+ (gld*_parse_args): Handle GROUP_OPTION and recognize -z defs.
+ (gld*_list_options): Add -Bgroup and -z defs.
+ * ld.1: Document -Bgroup and -z defs.
+ * ld.texinfo: Likewise.
+
+2001-03-07 Michael Meissner <meissner@redhat.com>
+
+ * scripttempl/elfd10v.sc (.rodata,.rodata1,.data1,.sdata): Deal
+ with sections created by -fdata-sections.
+ (.dynbss,.bss): Ditto.
+
+2001-03-05 Alan Modra <alan@linuxcare.com.au>
+
+ * emultempl/m68kelf.em (m68k_elf_after_allocation): Call
+ after_allocation_default, not gld..._before_allocation.
+
+2001-02-27 Alan Modra <alan@linuxcare.com.au>
+
+ * configure.in (BFD_VERSION): New.
+ (AM_INIT_AUTOMAKE): Use $BFD_VERSION.
+ * configure: Regenerate.
+ * Makefile.am: Run "make dep-am"
+ * Makefile.in: Regenerate.
+
+2001-02-26 Timothy Wall <twall@cygnus.com>
+
+ * emulparams/elf64_aix.sh: Add additional read-only sections;
+ uncomment lines which are now required.
+
+2001-02-26 H.J. Lu <hjl@gnu.org>
+
+ * ldlang.c (open_input_bfds): Set the bfd error handler so
+ that problems can be caught whilst loading symbols.
+ (record_bfd_errors): New function: Report BFD errors and mark
+ the executable output as being invalid.
+
+2001-02-22 Timothy Wall <twall@cygnus.com>
+
+ * configure.host: Add configuration for ia64-*-aix*.
+ * Makefile.am (ALL_64_EMULATIONS): Add emulation for ia64-*-aix*.
+ Add dependencies for eelf64_aix.c.
+ * Makefile.in: Regenerate.
+ * configure.tgt: Add ia64-*-aix* mapping.
+ * emulparams/elf64_aix.sh: Add settings for elf64 on aix5.
+
+2001-02-20 H.J. Lu <hjl@gnu.org>
+
+ * ldfile.c (ldfile_open_file): Set entry->search_dirs_flag to
+ false if we found the file.
+
+2001-02-18 David O'Brien <obrien@FreeBSD.org>
+
+ * configure.tgt: Add FreeBSD/Alpha, FreeBSD/x86-64, FreeBSD/ia64,
+ FreeBSD/PowerPC, FreeBSD/arm, and FreeBSD/sparc64 entries.
+
+2001-02-18 lars brinkhoff <lars@nocrew.org>
+
+ * Makefile.am: Add PDP-11 target.
+ * configure.tgt: Likewise.
+ * emulparams/pdp11.sh: New file.
+
+2001-02-17 David O'Brien <obrien@FreeBSD.org>
+
+ * configure.host: Add a generic FreeBSD configuration entry such that
+ all [modern] FreeBSD systems on all platforms will look the same.
+
+2001-02-14 H.J. Lu <hjl@gnu.org>
+
+ * configure.tgt: Remove mention of earmelf_linux26.
+
+2001-02-13 Richard Henderson <rth@redhat.com>
+
+ * emulparams/elf64_ia64.sh (OTHER_GOT_SYMBOLS): Remove.
+
+2001-02-13 H.J. Lu <hjl@gnu.org>
+
+ * ldexp.h (node_type): Add etree_provided.
+ * ldexp.c (exp_fold_tree): Handle etree_provided. Set the node
+ type to etree_provided if defined by PROVIDE. Allow updating
+ for etree_provided.
+ (exp_print_tree): Handle etree_provided.
+ * mpw-elfmips.c (gldelf32ebmip_find_exp_assignment): Handle
+ etree_provided.
+
+2001-02-09 David Mosberger <davidm@hpl.hp.com>
+
+ * emulparams/elf64_ia64.sh (OTHER_READONLY_SECTIONS): Add
+ .IA_64.unwind.* pattern to unwind table section and
+ .IA_64.unwind_info* pattern to unwind info section.
+
+2001-02-09 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * Makefile.am: Add linux target for S/390.
+ * Makefile.in: Likewise.
+ * configure.host: Likewise.
+ * configure.tgt: Likewise.
+ * emulparams/elf64_s390.sh: New file.
+ * emulparams/elf_s390.sh: New file.
+
+2001-02-09 Jakub Jelinek <jakub@redhat.com>
+
+ * configure.tgt (sparc64-*-linux-gnu*): Add elf32_sparc into
+ targ_extra_libpath.
+ (sparc-*-linux-gnu*): Add elf64_sparc into targ_extra_libpath.
+
+2001-02-06 Philip Blundell <philb@gnu.org>
+
+ * Makefile.am: Remove mention of earmelf_linux26.
+ * Makefile.in: Regenerate.
+
+2001-02-04 Philip Blundell <philb@gnu.org>
+
+ * emulparams/armelf_linux.sh (TEXT_START_ADDR): Set to 0x8000.
+ * emulparams/armelf_linux26.sh: Delete.
+ * configure.tgt: Remove mention of armelf_linux26 emulation.
+
+2001-02-01 Nick Clifton <nickc@redhat.com>
+
+ * ld.1: Replace occurances of -oformat with --oformat.
+
+2001-01-25 Jim Driftmyer <jdrift@stny.rr.com>
+
+ * ldlang.c (lang_leave_overlay): Don't set lma_region when
+ load_base is specified.
+
+2001-01-24 Hans-Peter Nilsson <hp@axis.com>
+
+ * emultempl/elf32.em: Correct spelling in comments and listed
+ options.
+
+2001-01-23 Alan Modra <alan@linuxcare.com.au>
+
+ * ldlang.c (lang_leave_overlay): Only set lma_region from the
+ default for the first section of a group of overlay sections.
+
+2001-01-22 Alan Modra <alan@linuxcare.com.au>
+
+ * Makefile.am (GENSCRIPTS): Pass exec_prefix.
+ * Makefile.in: Regenerate.
+ * genscripts.sh: Use exec_prefix parameter to specify tool lib.
+ Check for null tool_dir.
+
+2001-01-16 Jim Wilson <wilson@redhat.com>
+
+ * emulparams/elf64_ia64.sh (OTHER_READONLY_SECTIONS): Add IA_64.unwind
+ and IA_64.unwind.info.
+
+2001-01-16 H.J. Lu <hjl@gnu.org>
+
+ * ldlang.c (lang_check): Merge the private data only if the
+ input file has contents.
+
+2001-01-14 Alan Modra <alan@linuxcare.com.au>
+
+ * emulparams/hppalinux.sh (OUTPUT_FORMAT): Set to elf32-hppa-linux.
+
+ * emultempl/hppaelf.em (hppaelf_after_parse): New function,
+ enabling search for libmilli. On a relocatable link, make .text
+ sections unique.
+ (LDEMUL_AFTER_PARSE): Define.
+ (hppaelf_finish): Correct spelling of relocatable in comments.
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Don't
+ rummage through the script for sections on the unique list.
+ Correct length of strncmp for ".note".
+ (gld${EMULATION_NAME}_check_needed): Rearrange function.
+
+ * ldlang.c (unique_section_list): New var.
+ (unique_section_p): New function.
+ (walk_wild_section): Don't match sections on unique_section_list.
+ (lang_add_unique): New function.
+ Correct spelling of relocatable in comments.
+
+ * ldlang.h (struct unique_sections): Declare.
+ (unique_section_list): Declare.
+ (unique_section_p): Declare.
+ (lang_add_unique): Declare.
+
+ * lexsup.c (ld_options): Allow --unique to take an optional arg.
+ (parse_args [OPTION_UNIQUE]): Call lang_add_unique.
+
+ * ld.texinfo (--unique): Update.
+
+2001-01-13 Nick Clifton <nickc@redhat.com>
+
+ * lexsup.c (parse_args): Remove spurious white space.
+
+2001-01-12 Nick Clifton <nickc@redhat.com>
+
+ * lexsup.c (parse_args): Update copyright date.
+
+2001-01-12 Philip Blundell <pb@futuretv.com>
+
+ * configure.host: Set HOSTING_LIBS appropriately for ix86-cygwin.
+
+2001-01-10 Kazu Hirata <kazu@hxi.com>
+
+ * scripttempl/h8300.sc: Fix formatting. Fix a comment typo.
+ * scripttempl/h8300h.sc: Fix formatting.
+ * scripttempl/h8300s.sc: Likewise.
+ * scripttempl/h8500.sc: Likewise.
+ * scripttempl/h8500b.sc: Likewise.
+ * scripttempl/h8500c.sc: Likewise.
+ * scripttempl/h8500m.sc: Likewise.
+ * scripttempl/h8500s.sc: Likewise.
+
+2000-01-07 David O'Brien <obrien@BSDi.com>
+
+ * emultempl/elf32.em: Only perform Linux ld hints processing when
+ targeting Linux.
+
+2001-01-07 Philip Blundell <philb@gnu.org>
+
+ * ld.texinfo (Bug Reporting): Update email address for reports.
+
+2000-12-31 Nick Clifton <nickc@redhat.com>
+
+ * lexsup.c (parse_args): Set opterr to 0 and detect unparsed long
+ options by checking for a return value of '?' not -1.
+
+2000-12-28 Nick Clifton <nickc@redhat.com>
+
+ * lexsup.c (struct ld_option): Add new enum value:
+ EXACTLY_TWO_DASHES.
+ (ld_options[]): Change -omagic, -output and -oformat options
+ to be EXACTLY_TWO_DASHES.
+ (OUTPUT_COUNT): Use ARRAY_SIZE.
+ (parse_args): Change parameter 'argc' to unsigned.
+ Place EXACTLY_TWO_DASHES options into new really_longopts
+ array.
+ If getopt_long_only fails, try calling getopt_long using the
+ really_longopts array.
+ (help): Print a double dash for both EXACTLY_TWO_DASHES and
+ TWO_DASHES options.
+
+ * ldlex.h: Fix prototype of parse_args.
+
+ * ld.texinfo: Document that long options starting with 'o'
+ must be preceeded by two dashes. Change example of a single
+ dashed long option from -oformat to -trace-symbol.
+
+2000-12-26 Danny Smith <danny_r_smith_2001@yahoo.co.nz>
+
+ * emultempl/pe.em (OPTION_NO_DEFAULT_EXCLUDES): Define.
+ (longopts[]): New --no-default-excludes option.
+ (gld_${EMULATION_NAME}_list_options): Document.
+ (gld_${EMULATION_NAME}_parse_args): Handle.
+
+2000-12-13 Michael Sokolov <msokolov@ivan.Harhan.ORG>
+
+ * ldlang.c (new_stat): Revert the last beautification with "innocent"
+ whitespace, it breaks the K&R C preprocessor.
+
+2000-12-11 DJ Delorie <dj@redhat.com>
+
+ * ld.texinfo: Add notes about --whole-archive and gcc.
+
+2000-11-18 Fred Fish <fnf@be.com>
+
+ * lexsup.c (OPTION_ALLOW_SHLIB_UNDEFINED): Define.
+ (ld_options): Entry for --allow-shlib-undefined.
+ (parse_args): Handle OPTION_ALLOW_SHLIB_UNDEFINED.
+ * ldmain.c (main): Initialize link_info.allow_shlib_undefined
+ to false.
+ * ld.texinfo: Document new command line switch.
+
+2000-12-12 Geoffrey Keating <geoffk@redhat.com>
+
+ * emulparams/elf32ppc.sh (OTHER_READWRITE_SECTIONS):
+ .fixup is actually read/write.
+ * emulparams/elf32lppc.sh (OTHER_READWRITE_SECTIONS): Likewise.
+ * emulparams/elf32ppcsim.sh (OTHER_READWRITE_SECTIONS): Likewise.
+ * emulparams/elf32lppcsim.sh (OTHER_READWRITE_SECTIONS): Likewise.
+
+2000-12-11 Jan Hubicka <jh@suse.cz>
+
+ * NEWS: Add note about x86_64 architecture.
+
+2000-12-06 Mark Elbrecht <snowball3@bigfoot.com>
+
+ * scripttempl/i386go32.sc: Use PROVIDE with _etext, _edata, _end.
+ Set DWARF2 sections to a VMA of zero.
+
+2000-12-01 Joel Sherrill <joel@OARcorp.com>
+
+ * configure.tgt (arm-*-rtems*, a29k-*rtems*, h8300-*-rtems*):
+ New targets.
+ (sparc*-*-rtemself*, sparc*-*-rtemsaout*): New targets.
+ (sparc*-*-rtems*): Switched from a.out to ELF.
+
+2000-11-30 Jan Hubicka <jh@suse.cz>
+
+ * Makefile.am (ALL_EMULATIONS): Add eelf_x86_64.o
+ (eelf_x86_64.c): New.
+ * Makefile.in: Regenerate.
+ * configure.tgt: Add support for x86_64-*-linux-gnu*.
+ * emulparams/elf_x86_64.sh: New.
+
+2000-11-30 Hans-Peter Nilsson <hp@axis.com>
+
+ * emulparams/crislinux.sh (ENTRY): Change back to _start.
+ (TEXT_START_SYMBOLS): Remove conditional setting of __start.
+
+ * scripttempl/crisaout.sc: Change all RELOCATING not related to
+ merging non-a.out sections into CONSTRUCTING.
+
+2000-11-28 Nick Clifton <nickc@redhat.com>
+
+ * ld.1 (COPYING): Mention that the GNU Free Documentation
+ License is present in the sources, but not the output, and
+ also available from the GNU website.
+ (GNU Free Documentation License): Comment out this section.
+
+2000-11-28 David O'Brien <obrien@dragon.nuxi.com>
+
+ * emulparams/elf64alpha.sh (ENTRY): Remove leading underscore as ELF
+ does not use them.
+
+2000-11-25 David O'Brien <obrien@FreeBSD.org>
+
+ * ld.1: Remove old date so it does not give the impression the manpage
+ is way out of date.
+
+2000-11-24 Nick Clifton <nickc@redhat.com>
+
+ * configure.tgt (xscale-coff): Add target.
+ (xscale-elf): Add target.
+
+2000-11-24 Fred Fish <fnf@be.com>
+
+ * ldmain.c (main): Remove redundant init of config.make_executable
+ to true.
+
+2000-11-15 Richard Henderson <rth@redhat.com>
+
+ * emulparams/elf64alpha.sh (MAXPAGESIZE): Typo -- 64k, not 1M.
+
+2000-11-14 Kazu Hirata <kazu@hxi.com>
+
+ * scripttempl/h8300.sc: Fix formatting.
+ * scripttempl/h8300h.sc: Likewise.
+ * scripttempl/h8300s.sc: Likewise.
+
+2000-11-14 Denis Chertykov <denisc@overta.ru>
+
+ * scripttempl/elf32avr.sc: Fix bug in .eeprom segment.
+
+2000-11-09 Philip Blundell <pb@futuretv.com>
+
+ * emultempl/pe.em: Define ___start_SECNAME and ___stop_SECNAME
+ around orphan sections whose names can be represented in C.
+
+2000-11-07 Jim Wilson <wilson@redhat.com>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): New local
+ hold_sdata. If SEC_SMALL_DATA set, set place to hold_sdata.
+
+2000-11-06 Nick Clifton <nickc@redhat.com>
+
+ * ld.texinfo: Add GNU Free Documentation License.
+ * ldint.texinfo: Add GNU Free Documentation License.
+ * ld.1: Add GNU Free Documentation License.
+
+2000-11-05 Alan Modra <alan@linuxcare.com.au>
+
+ * ldlex.l (yy_create_string_buffer): Init yy_is_our_buffer,
+ yy_is_interactive, yy_at_bol, and yy_fill_buffer.
+
+ * Makefile.am (DISTCLEANFILES): Add stringify.sed.
+ Move 2000-11-02 Makefile.in changes to this file.
+ * Makefile.in: Regenerate.
+
+2000-11-03 Nick Clifton <nickc@redhat.com>
+
+ * scripttempl/h8300.sc: Use ${CONSTRUCTING...} to enclose
+ constructors and destructors.
+ * scripttempl/h8300h.sc: Ditto.
+ * scripttempl/h8300s.sc: Ditto.
+ * scripttempl/h8500.sc: Ditto.
+ * scripttempl/h8500b.sc: Ditto.
+ * scripttempl/h8500c.sc: Ditto.
+ * scripttempl/h8500m.sc: Ditto.
+ * scripttempl/h8500s.sc: Ditto.
+ * scripttempl/v850.sc: Ditto.
+ * scripttempl/w65.sc: Ditto.
+ * scripttempl/z8000.sc: Ditto.
+
+2000-11-02 Per Lundberg <plundis@chaosdev.org>
+
+ * Makefile.in (e_i386_chaos.c): New rule.
+ (ALL_EMULATIONS): Added e_i386_chaos.o.
+ * emulparams/elf_i386_chaos.sh: New file.
+ * configure.tgt: Recognise i[3456]86-chaosdev-storm-chaos.
+
+2000-10-20 Jakub Jelinek <jakub@redhat.com>
+
+ * emulparams/elf64_sparc.sh (TEXT_START_ADDR,
+ NONPAGED_TEXT_START_ADDR): Set to 4GB for Solaris targets.
+ Fix sed invocation, so that it coped with '/' in Solaris 64bit
+ library path suffix.
+ Based on patch by Andrew Macleod <amacleod@cygnus.com>.
+
+2000-10-18 Hans-Peter Nilsson <hp@axis.com>
+
+ * scripttempl/crisaout.sc (.text, .data): Pad, with ALIGN (32),
+ for consecutive sections.
+
+2000-10-17 Chandrakala Chavva <cchavva@redhat.com>
+
+ * lexsup.c: New option OPTION_TARGET_HELP. Prints all target specific
+ options.
+ * ld.texinfo: Added notes about this new option.
+
+2000-10-16 Nick Clifton <nickc@redhat.com>
+
+ * emultempl/pe.em (_after_open): Add tests of return values from
+ bfd functions. Emit appropriate error messages if necessary.
+
+2000-10-13 Nick Clifton <nickc@redhat.com>
+
+ * emultempl/pe.em (_after_open): Delete 'is2' and 'nsyms'
+ local variables - they are not used, but leave in the call to
+ bfd_canonicalize_symtab.
+ (_open_dynamic_archive): Add #ifdef DLL_SUPPORT around use of
+ pe_dll_search_prefix.
+
+2000-10-12 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * emultempl/pe.em (pe_dll_search_prefix): New variable,
+ (longopts): New --dll-search-prefix option.
+ (gld_${EMULATION_NAME}_list_options): Document.
+ (gld_${EMULATION_NAME}_parse_args): Handle.
+ (gld_${EMULATION_NAME}_open_dynamic_archive): When linking
+ dynamically, search for a dll named '<prefix><basename>.dll'
+ in preference to 'lib<basename>.dll' if --dll-search-prefix
+ is specified.
+
+2000-10-12 Alan Modra <alan@linuxcare.com.au>
+
+ * ldlang.c (section_already_linked): Set kept_section instead of
+ sec->comdat->sec.
+
+2000-10-10 Kazu Hirata <kazu@hxi.com>
+
+ * deffile.h: Fix formatting.
+ * lexsup.c: Likewise.
+ * mri.c: Likewise.
+
+2000-10-09 Paul Sokolovsky <Paul.Sokolovsky@technologist.com>
+
+ * pe-dll.c (make_one): Do not generate code thunk for DATA
+ exports.
+ (process_def_file): deduce DATA flag for auto-export sumbols.
+
+2000-10-09 Kazu Hirata <kazu@hxi.com>
+
+ * ld.h: Fix formatting.
+ * ldcref.c: Likewise.
+ * ldctor.h: Likewise.
+ * ldemul.c: Likewise.
+ * ldemul.h: Likewise.
+ * ldexp.c: Likewise.
+ * ldexp.h: Likewise.
+ * ldfile.c: Likewise.
+ * ldfile.h: Likewise.
+ * ldlang.c: Likewise.
+ * ldlang.h: Likewise.
+ * ldmain.c: Likewise.
+ * pe-dll.c: Likewise.
+
+ * pe-dll.c: Revert some formatting fixes.
+
+2000-10-08 Kazu Hirata <kazu@hxi.com>
+
+ * pe-dll.c: Fix formatting.
+
+2000-10-05 Kazu Hirata <kazu@hxi.com>
+
+ * ldlang.c: Fix formatting.
+
+2000-10-03 DJ Delorie <dj@redhat.com>
+
+ * pe-dll.c (fill_edata): initialize entire block
+ (make_one): fill in correct section.
+
+2000-10-03 Kazu Hirata <kazu@hxi.com>
+
+ * ldexp.c: Fix formatting.
+
+2000-10-02 DJ Delorie <dj@redhat.com>
+
+ * emultempl/pe.em (gld_*_after_open): detect case where there two
+ import libraries for same dll; rename one to ensure proper link
+ order.
+
+ * pe-dll.c (process_def_file): compare ordinals to -1, not 0; fix
+ typo
+ (generate_edata): fix typo
+
+2000-09-29 Hans-Peter Nilsson <hp@axis.com>
+
+ * scripttempl/crisaout.sc (ENTRY): Now __start.
+ (.text): Add default setting for __start.
+ Remove CONSTRUCTORS handling.
+ (/DISCARD/): Add .gnu.warning.*.
+ * emulparams/crislinux.sh (ENTRY): Now __start.
+ (TEXT_START_SYMBOLS): New; provide __Stext and __start default.
+ * emulparams/criself.sh (OUTPUT_FORMAT): Now elf32-us-cris.
+ (ENTRY): Now __start.
+ (INITIAL_READONLY_SECTIONS): Add KEEP for .startup.
+ (EXECUTABLE_SYMBOLS): Add default setting for __start.
+
+2000-09-29 Kazu Hirata <kazu@hxi.com>
+
+ * deffile.h: Fix formatting.
+ * ld.h: Likewise.
+ * ldcref.c: Likewise.
+ * ldctor.c: Likewise.
+ * ldctor.h: Likewise.
+ * ldemul.c: Likewise.
+ * ldemul.h: Likewise.
+ * ldexp.c: Likewise.
+ * ldexp.h: Likewise.
+ * ldfile.c: Likewise.
+ * ldfile.h: Likewise.
+ * ldlang.c: Likewise.
+ * ldlang.h: Likewise.
+ * lexsup.c: Likewise.
+ * mri.c: Likewise.
+ * pe-dll.c: Likewise.
+
+2000-09-28 Paul Sokolovsky <Paul.Sokolovsky@technologist.com>
+
+ * pe-dll.c (process_def_file): Uninitialized data wasn't
+ exported with --export-all-symbols switch.
+
+2000-09-28 DJ Delorie <dj@redhat.com>
+
+ * pe-dll.c (fill_edata): rearrange the data so that ordinals and
+ noname work properly.
+
+2000-09-28 Alan Modra <alan@linuxcare.com.au>
+
+ * ld.texinfo (HPPA ELF32): New section.
+
+ * emultempl/hppaelf.em (group_size): New.
+ (hppaelf_finish): Pass group_size to elf32_hppa_size_stubs.
+ (PARSE_AND_LIST_PROLOGUE): Add OPTION_STUBGROUP_SIZE.
+ (PARSE_AND_LIST_LONGOPTS): Add --stub-group-size. Duplicate
+ options to prevent abbreviations matching.
+ (PARSE_AND_LIST_OPTIONS): Describe the above. Reformat.
+ (PARSE_AND_LIST_ARGS_CASES): Handle it.
+
+2000-09-21 Michael Sokolov <msokolov@ivan.Harhan.ORG>
+
+ * emultempl/m68kelf.em: Conditionalise the embedded relocs feature
+ on the m68*-*-elf target. Make it support COFF input objects.
+
+2000-09-21 Kazu Hirata <kazu@hxi.com>
+
+ * ldmain.c: Fix formatting.
+ * ldmisc.c: Likewise.
+ * ldver.c: Likewise.
+ * ldwrite.c: Likewise.
+
+2000-09-21 Alan Modra <alan@linuxcare.com.au>
+
+ * ldwrite.c (clone_section): Silence gcc warnings.
+
+2000-09-20 Alan Modra <alan@linuxcare.com.au>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Handle
+ out of memory failure.
+
+ * ldwrite.c (ldwrite): Remove unnecessary einfo arg.
+ (clone_section): Handle out of memory failures. Rename var to
+ avoid c++ reserved word.
+
+2000-09-18 Alan Modra <alan@linuxcare.com.au>
+
+ * emultempl/hppaelf.em (hppaelf_add_stub_section): Rename
+ stub_name param to stub_sec_name.
+ (hppaelf_finish): Modify call to elf32_hppa_size_stubs.
+
+2000-09-10 Michael Sokolov <msokolov@ivan.Harhan.ORG>
+
+ * emultempl/m68kelf.em: New file.
+ * emulparams/m68kelf.sh (EXTRA_EM_FILE): Use it.
+ * Makefile.am (em68kelf.c): Add dependency on m68kelf.em.
+ * Makefile.in: Regenerate.
+
+2000-09-15 Alan Modra <alan@linuxcare.com.au>
+
+ * emulparams/hppalinux.sh (DATA_START_SYMBOLS): Provide $global$
+ only as needed.
+
+2000-09-13 Nick Clifton <nickc@redhat.com>
+
+ * ldmain.c (multiple_definition): Disable relaxation if
+ multiple symbol definitions are encountered - otherwise the
+ linker could abort with an assertion failure.
+
+2000-09-10 Nick Clifton <nickc@redhat.com>
+
+ * mri.c: Fix formatting.
+
+2000-09-07 H.J. Lu <hjl@gnu.org>
+
+ * configure.in (AC_ISC_POSIX): Put after AC_CANONICAL_SYSTEM.
+ * configure: Rebuild.
+
+2000-09-07 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.am (lexsup.o): Also depend on $(INCDIR)/demangle.h.
+ * Makefile.in: Rebuild.
+
+2000-09-07 Alan Modra <alan@linuxcare.com.au>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Fix
+ broken list handling. Create __start_SECNAME and __stop_SECNAME
+ when no place-holder. Add some comments. Test both SEC_CODE and
+ SEC_READONLY for hold_text to prevent .rodata orphan poisoning.
+ Handle case where no output section statement created.
+
+2000-09-07 Niibe Yutaka <gniibe@m17n.org>, Kaz Kojima <kkojima@rr.iij4u.or.jp>, Alexandre Oliva <aoliva@redhat.com>
+
+ * configure.tgt (sh-*-linux*): Added.
+ * Makefile.am: Added eshelf_linux and eshlelf_linux.
+ * Makefile.in: Rebuilt.
+ * emulparams/shelf_linux.sh: New file.
+ * emulparams/shlelf_linux.sh: New file.
+
+2000-09-06 Alan Modra <alan@linuxcare.com.au>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Don't
+ try shuffling sections when the orphan happens to be the place
+ holder. Keep count of unique section names generated so we speed
+ the search for a new name.
+
+2000-09-06 Alexandre Oliva <aoliva@redhat.com>
+
+ * configure: Rebuilt with new libtool.m4.
+
+2000-09-05 Nick Clifton <nickc@redhat.com>
+
+ * Makefile.in: Regenerate.
+ * aclocal.m4: Regenerate.
+ * configure: Regenerate.
+ * config.in: Regenerate.
+ * po/ld.pot: Regenerate.
+
+ * ldint.texinfo: Remove CVS revision marker - it foils local
+ comparisons.
+
+ * emultempl/ticoff.em: Remove extraneous comma.
+
+2000-09-05 Alan Modra <alan@linuxcare.com.au>
+
+ * emultempl/hppaelf.em (hppaelf_add_stub_section): Add SEC_RELOC
+ to stub section flags.
+ (hppa_for_each_input_file_wrapper): New.
+ (hppa_lang_for_each_input_file): New.
+ (lang_for_each_input_file): Define to call above.
+ (multi_subspace): New.
+ (hppaelf_finish): Pass multi_subspace to elf32_hppa_size_stubs.
+ (PARSE_AND_LIST_PROLOGUE): Define.
+ (PARSE_AND_LIST_LONGOPTS): Define.
+ (PARSE_AND_LIST_OPTIONS): Define.
+ (PARSE_AND_LIST_ARGS_CASES): Define.
+ (hppaelf_finish): Call elf32_hppa_set_gp.
+ (hppaelf_set_output_arch): Remove.
+ (LDEMUL_SET_OUTPUT_ARCH): Remove.
+
+ * emulparams/hppalinux.sh (ELFSIZE): Define.
+ (MACHINE): Define.
+ (OTHER_READONLY_SECTIONS): Define.
+ (DATA_PLT): Define.
+ (GENERATE_SHLIB_SCRIPT): Define.
+
+ * ldlang.c: Add missing prototypes, and tidy others. Change CONST
+ to const throughout. Change `void *' to `PTR' throughout.
+ (lang_memory_default): Function is local to file, add `static'.
+
+ * Makefile.am (ehppaelf.c): Depend on emultempl/elf32.em.
+ (ehppalinux.c): Likewise.
+ (earmelf.c): Likewise.
+ (earmelf_linux.c): Likewise.
+ (earmelf_linux26.c): Likewise.
+ * Makefile.in: Regenerate.
+
+ * ld.h (ld_config_type): Add unique_orphan_sections.
+ * lexsup.c (OPTION_UNIQUE): Define.
+ (ld_options): Add "--unique".
+ (parse_args): Handle it.
+ * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Don't
+ search for an existing output section if unique_orphan_sections is
+ set. Make use of bfd_get_unique_section_name rather than
+ duplicating code here.
+ * ld.texinfo: Describe --unique.
+
+ * lexsup.c (ld_options): Make split-by-reloc arg optional. Add
+ optional arg to split-by-file.
+ (parse_args): Handle them.
+ * ld.texinfo: Update description of these options.
+ * ldwrite.c (clone_section): Pass in the section name. Replace
+ local code with bfd_get_unique_section_name.
+ (split_sections): Tidy code and comments. Use a list traversal
+ more appropriate to the list construction. Handle cooked section
+ sizes. Split when split_by_reloc reached rather than exceeded.
+ Track section size and split when split_by_file reached. Fix
+ link_order_tail (even though it's not used).
+ (ldwrite): Modify condition for calling split_sections to suit
+ changed split_by_reloc and split_by_file.
+ * ldmain.c (main): Init config.split_by_reloc and
+ config.split_by_file to -1.
+ * ld.h (ld_config_type): Change split_by_reloc to unsigned.
+ Change split_by_file to bfd_size_type.
+
+2000-09-02 Nick Clifton <nickc@redhat.com>
+
+ * configure.in: Increase version number to 2.10.91.
+ * NEWS: Mention new ability to support removal of duplicate DWARF2
+ debug information.
+ * configure: Regenerate.
+ * aclocal.m4: Regenerate.
+ * config.in: Regenerate.
+
+2000-09-02 Daniel Berlin <dberlin@redhat.com>
+
+ * scripttempl/elf.sc: Add .gnu.linkonce.wi.* to .debug_info
+ sections.
+ * scripttempl/elf32avr.sc: Ditto.
+ * scripttempl/elfd10v.sc: Ditto.
+ * scripttempl/elfd30v.sc: Ditto.
+ * scripttempl/elfi370.sc: Ditto.
+ * scripttempl/elfm68hc11.sc: Ditto.
+ * scripttempl/elfm68hc12.sc: Ditto.
+ * scripttempl/elfi386beos.sc: Ditto.
+ * scripttempl/v850.sc: Ditto.
+
+2000-08-31 Alexandre Oliva <aoliva@redhat.com>
+
+ * acinclude.m4: Include libtool and gettext macros from the
+ top level.
+ * aclocal.m4, configure: Rebuilt.
+
+2000-08-25 Nick Clifton <nickc@redhat.com>
+
+ * ldlang.c (open_output): When choosing the target for a
+ particular endianness, do nothing if the target is not
+ supported.
+
+2000-08-25 H.J. Lu <hjl@gnu.org>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Don't
+ check -rpath nor LD_RUN_PATH for cross link.
+ * ld.texinfo: Document the change.
+
+2000-08-24 Hans-Peter Nilsson <hp@axis.com>
+
+ * NEWS: Mention support for CRIS.
+
+2000-08-23 H.J. Lu <hjl@gnu.org>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Get
+ the current runpath list from bfd_elf_get_runpath_list ()
+ before search.
+
+2000-08-22 H.J. Lu <hjl@gnu.org>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_after_open): Search
+ the DT_RPATH/DT_RUNPATH entries for DT_NEEDED after
+ LD_LIBRARY_PATH for native linker. Display the needed DSO if
+ trace_file_tries is non-zero.
+ (gld${EMULATION_NAME}_try_needed): Report the needed DSO found
+ if trace_file_tries is non-zero.
+
+ * ld.texinfo: Document the usage of DT_RPATH/DT_RUNPATH.
+ * NEWS: Mention it.
+
+2000-08-14 Jason Eckhardt <jle@cygnus.com>
+
+ * NEWS: Mention i860 support.
+
+2000-08-14 Andreas Schwab <schwab@suse.de>
+
+ * scripttempl/elf.sc: Fix last change to use correct comment
+ syntax.
+
+2000-08-10 Geoff Keating <geoffk@cygnus.com>
+
+ * scripttempl/elf.sc: Add a comment giving the correspondence
+ between sections, per-datum sections, and linkonce sections. Make
+ the comment true even for .bss, .sdata, .sdata2, .sbss, and
+ .sbss2.
+
+2000-08-10 Jason Eckhardt <jle@cygnus.com>
+
+ * emulparams/elf32_i860.sh: New file.
+ * configure.tgt: Recognize new target i860-stardent-{sysv4*|elf*}.
+ * Makefile.am (ALL_EMULATIONS): Add eelf32_i860.o.
+ (eelf32_i860.c): New rule.
+ * Makefile.in: Regenerate.
+
+2000-08-10 Nick Clifton <nickc@cygnus.com>
+
+ * emulparams/mipspe.sh (ENTRY): Add definition.
+
+2000-08-08 Peter Jeremy <peter.jeremy@alcatel.com.au>
+
+ * emultempl/elf32.em (_after_close): Refer to -rpath not --rpath
+ in error message.
+
+2000-08-08 Stephane Carrez <Stephane.Carrez@worldnet.fr>
+
+ * scripttempl/elfm68hc11.sc: Define __bss_size symbol to indicate
+ the final size of .bss section.
+ * scripttempl/elfm68hc12.sc: Likewise.
+
+2000-08-04 Alan Modra <alan@linuxcare.com.au>
+
+ * emultempl/elf32.em (gld_${EMULATION_NAME}_parse_args): Rename to
+ gld${EMULATION_NAME}_parse_args for consistency. Combine
+ lastoptind and prevoptind vars, and keep track of last optind.
+ (gld_${EMULATION_NAME}_list_options): Rename to
+ gld${EMULATION_NAME}_list_options.
+
+2000-08-03 Rodney Brown <RodneyBrown@pmsc.com>
+
+ * configure.tgt: Select targ_emul=elf_i386 for Unixware 7
+ (i586-sco-sysv5uw7.1.0).
+
+2000-07-27 H.J. Lu <hjl@gnu.org>
+
+ * emulparams/elf64alpha.sh (PARSE_AND_LIST_ARGS): Removed.
+ (PARSE_AND_LIST_PROLOGUE): New.
+ (PARSE_AND_LIST_LONGOPTS): Likewise.
+ (PARSE_AND_LIST_OPTIONS): Likewise.
+ (PARSE_AND_LIST_ARGS_CASES): Likewise.
+ (PARSE_AND_LIST_EPILOGUE): Likewise.
+
+2000-07-28 Alan Modra <alan@linuxcare.com.au>
+
+ * emultempl/armelf.em: Elide functions common to elf32.em,
+ ie. most of the file.
+ (arm_elf_after_open): New. Do arm specific things then call
+ gld${EMULATION_NAME}_after_open.
+ (arm_elf_before_allocation): New. Call
+ gld${EMULATION_NAME}_before_allocation then do arm specifics.
+ (PARSE_AND_LIST_PROLOGUE): Define.
+ (PARSE_AND_LIST_SHORTOPTS): Define.
+ (PARSE_AND_LIST_LONGOPTS): Define.
+ (PARSE_AND_LIST_OPTIONS): Define.
+ (PARSE_AND_LIST_ARGS_CASES): Define.
+ (LDEMUL_AFTER_OPEN): Define.
+ (LDEMUL_BEFORE_ALLOCATION): Define.
+ (LDEMUL_BEFORE_PARSE): Define.
+ (LDEMUL_FINISH): Define.
+
+ * emultempl/hppaelf.em: Similarly zap most of this file.
+ (hppaelf_add_stub_section): Prototype.
+ (hppaelf_layaout_sections_again): Prototype.
+ (hook_in_stub): Prototype.
+ (LDEMUL_SET_OUTPUT_ARCH): Define.
+ (LDEMUL_FINISH): Define.
+ (LDEMUL_CREATE_OUTPUT_SECTION_STATEMENTS): Define.
+
+ * emulparams/armelf.sh (TEMPLATE_NAME): Use elf32.
+ (EXTRA_EM_FILE): New.
+ * emulparams/armelf_linux.sh: Likewise.
+ * emulparams/armelf_linux26.sh: Likewise.
+ * emulparams/hppalinux.sh: Likewise.
+ * emulparams/hppaelf.sh: Likewise.
+ (NOP): Define.
+
+ * emultempl/elf32.em: Fix formatting.
+ (EXTRA_EM_FILE): Source it.
+ (LDEMUL_BEFORE_PARSE, LDEMUL_SYSLIB, LDEMUL_HLL,
+ LDEMUL_AFTER_PARSE, LDEMUL_AFTER_OPEN, LDEMUL_AFTER_ALLOCATION,
+ LDEMUL_SET_OUTPUT_ARCH, LDEMUL_CHOOSE_TARGET,
+ LDEMUL_BEFORE_ALLOCATION, LDEMUL_GET_SCRIPT, LDEMUL_FINISH,
+ LDEMUL_CREATE_OUTPUT_SECTION_STATEMENTS,
+ LDEMUL_OPEN_DYNAMIC_ARCHIVE, LDEMUL_PLACE_ORPHAN,
+ LDEMUL_SET_SYMBOLS, LDEMUL_PARSE_ARGS, LDEMUL_UNRECOGNIZED_FILE,
+ LDEMUL_LIST_OPTIONS, LDEMUL_RECOGNIZED_FILE,
+ LDEMUL_FIND_POTENTIAL_LIBRARIES): New shell vars. Add code to
+ allow functions in this file to be overridden.
+ (PARSE_AND_LIST_SHORTOPTS): Handle it.
+
+ * emultempl/m68kcoff.em: Include ldfile.h before ldemul.h.
+
+ * emultempl/elf32.em: Reorganize file.
+
+2000-07-27 Ivan Kokshaysky <ink@jurassic.park.msu.ru>
+
+ * emulparams/elf64alpha.sh: Implement "-taso" emulation
+ specific option to fit 64-bit executable in the lower
+ 31-bit address range. This is done by changing start
+ address of .interp (the very first section of executable)
+ and then setting EF_ALPHA_32BIT elf header flag.
+
+2000-07-21 Michael Sokolov <msokolov@ivan.Harhan.ORG>
+
+ * emultempl/m68kcoff.em: New file.
+ * emulparams/m68kcoff.sh (TEMPLATE_NAME): Use m68kcoff template.
+ * Makefile.am (em68kcoff.c): Depend on m68kcoff.em rather than
+ generic.em.
+ * Makefile.in: Regenerate.
+
+2000-07-20 H.J. Lu <hjl@gnu.org>
+
+ * emultempl/elf32.em (longopts): Duplicate "disable-new-dtags"
+ and "disable-new-dtags" to stop getopt from treating -d/-e as
+ abbreviations for these options.
+
+2000-07-20 H.J. Lu <hjl@gnu.org>
+
+ * ld.texinfo: Add documentation for --disable-new-dtags and
+ --enable-new-dtags.
+
+ * ldmain.c (main): Initialize link_info.new_dtags to false.
+
+ * emultempl/elf32.em (gld_${EMULATION_NAME}_parse_args): Add
+ --disable-new-dtags and --enable-new-dtags.
+ (gld_${EMULATION_NAME}_list_options): Likewise.
+
+2000-07-05 Kenneth Block <krblock@computer.org>
+
+ * lexsup.c: Add optional style to demangle switch
+ * ld.texinfo: Document optional style to demangle switch.
+
+2000-07-20 Hans-Peter Nilsson <hp@axis.com>
+
+ * Makefile.am (ALL_EMULATIONS): Add ecrisaout.o, ecriself.o,
+ ecrislinux.o.
+ (ecrisaout.c, ecriself.c, ecrislinux.c): New rules.
+ Regenerate dependencies.
+ * Makefile.in: Rebuild.
+ * configure.tgt (cris-*-*): New target.
+ * emulparams/crisaout.sh, emulparams/criself.sh,
+ emulparams/crislinux.sh, scripttempl/crisaout.sc: New files.
+ * po/POTFILES.in, po/ld.pot: Regenerate.
+
+2000-07-20 H.J. Lu <hjl@gnu.org>
+
+ * emultempl/elf32.em (gld_${EMULATION_NAME}_list_options):
+ Print out ignored -z options.
+
+2000-07-19 H.J. Lu <hjl@gnu.org>
+
+ * emulparams/elf32mcore.sh (PARSE_AND_LIST_ARGS): Removed.
+ (PARSE_AND_LIST_PROLOGUE): New.
+ (PARSE_AND_LIST_LONGOPTS): Likewise.
+ (PARSE_AND_LIST_OPTIONS): Likewise.
+ (PARSE_AND_LIST_ARGS_CASES): Likewise.
+
+ * ldmain.c (main): Clear link_info.flags and link_info.flags_1.
+
+ * lexsup.c (ld_options): Comment out 'z'.
+ (parse_args): Likewise.
+
+ * emultempl/elf32.em: Include "elf/common.h".
+ (gld_${EMULATION_NAME}_parse_args): Defined. Handle some -z
+ options.
+ (gld_${EMULATION_NAME}_list_options): Likewise.
+
+ * ld.texinfo: Add documentation for the recognized -z options.
+
+2000-07-19 H.J. Lu <hjl@gnu.org>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_try_needed): Call
+ bfd_elf_set_dt_needed_soname ().
+
+2000-07-18 DJ Delorie <dj@cygnus.com>
+
+ * pe-dll.c (pe_dll_id_target): check object target name also
+
+2000-07-18 Hans-Peter Nilsson <hp@axis.com>
+
+ * scripttempl/elf.sc (.init): Only do ${INIT_START} and
+ ${INIT_END} if relocating.
+ (.fini): Likewise ${FINI_START} and ${FINI_END}.
+
+2000-07-16 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * emultempl/pe.em (gld_*_open_dynamic_archive): New search
+ order for dynamic library '-lfoo' on pei386: libfoo.dll.a,
+ foo.dll.a, libfoo.a, libfoo.dll, foo.dll. This fixes compatibility
+ errors introduced by the old dynamic lib search order.
+
+2000-07-17 DJ Delorie <dj@cygnus.com>
+
+ * pe-dll.c (process_def_file): auto-export data items also
+ (pe_process_import_defs): also see if _imp_ form needed
+
+2000-07-12 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * pe-dll.c (make_one): fix a typo in the __imp_ name decoration
+ for dll import libraries
+
+2000-07-12 Mark Elbrecht <snowball3@bigfoot.com>
+
+ * scripttempl/i386go32.sc: Support the g++ attribute init_priority in
+ gcc 2.95.2 and later.
+
+2000-07-11 Kazu Hirata <kazu@hxi.com>
+
+ * ldfile.c (ldfile_try_open_bfd): Output '\n' after an error
+ message.
+
+2000-07-10 Alan Modra <alan@linuxcare.com.au>
+
+ * ldemul.h (struct lang_input_statement_struct): Remove forward
+ declaration.
+ (struct search_dirs): Likewise.
+ * ldfile.h (struct lang_input_statement_struct): Likewise.
+ Protect file from multiple inclusion.
+ * ldlang.h (LANG_FOR_EACH_INPUT_STATEMENT): Move file_chain
+ declaration from macro to file scope.
+
+ * ldemul.c: ldexp.h,ldlang.h,ldfile.h,ldemul.h go in this order.
+ * ldgram.y: Likewise here.
+ * ldlang.c: And here.
+ * ldmain.c: And here.
+ * mpw-elfmips.c: And here.
+ * mpw-eppcmac.c: And here.
+ * emultempl/aix.em: And here.
+ * emultempl/armcoff.em: And here.
+ * emultempl/armelf.em: And here.
+ * emultempl/armelf_oabi.em: And here.
+ * emultempl/beos.em: And here.
+ * emultempl/elf32.em: And here.
+ * emultempl/hppaelf.em: And here.
+ * emultempl/linux.em: And here.
+ * emultempl/lnk960.em: And here.
+ * emultempl/pe.em: And here.
+ * emultempl/sunos.em: And here.
+ * mpw-esh.c: And here. Include ldexp.h and ldlang.h too.
+ * mpw-idtmips.c: Ditto.
+ * emultempl/generic.em: Ditto.
+ * emultempl/gld960.em: Ditto.
+ * emultempl/gld960c.em: Ditto.
+ * emultempl/mipsecoff.em: Ditto.
+ * emultempl/ticoff.em: Ditto.
+ * emultempl/vanilla.em: Ditto.
+
+ * pe-dll.c: Include ldfile.h
+ * ldver.c: Include ldexp.h, ldlang.h, ldfile.h
+
+ * mpw-elfmips.c: (gldelf32ebmip_before_allocation): Add missing
+ arguments to bfd_elf32_size_dynamic_sections call.
+ (gldelf32ebmip_place_orphan): Add missing arguments to
+ lang_leave_output_section_statement call.
+
+2000-07-10 H.J. Lu <hjl@gnu.org>
+
+ * emultempl/pe.em (pe_enable_stdcall_fixup): Protect with
+ DLL_SUPPORT.
+ (strhash): Likewise.
+ (compute_dll_image_base): Likewise.
+ (pe_undef_found_sym): Likewise.
+ (pe_undef_cdecl_match): Likewise.
+ (gld_${EMULATION_NAME}_open_dynamic_archive): Mark the
+ argument "arch" with ATTRIBUTE_UNUSED.
+
+2000-07-10 Alan Modra <alan@linuxcare.com.au>
+
+ * configure.tgt: Remove extraneous hppa*-*-linux-gnu*.
+
+ From Ryan Bradetich <rbradetich@uswest.net>
+ * ldwrite.c (SSIZE): Remove to cure macro redefinition warning.
+
+2000-07-09 Alan Modra <alan@linuxcare.com.au>
+
+ Changes to create multiple linker stubs, positioned immediately
+ before the section where they are required.
+ * emultempl/hppaelf.em: Include elf32-hppa.h.
+ (stub_sec, file_chain): Delete.
+ (hppaelf_create_output_section_statements): Don't make a stub
+ section here.
+ (hook_stub_info): New struct.
+ (hook_in_stub): New function.
+ (hppaelf_add_stub_section): New function.
+ (hppaelf_finish): Do nothing for relocateable links. Modify the
+ call to elf32_hppa_size_stubs. Move code for updating section
+ layout from here...
+ (hppaelf_layaout_sections_again): ..to here, a new function.
+
+ * emultempl/hppaelf.em (hppaelf_delete_padding_statements): Fix
+ broken list handling. Pass in a pointer to the list.
+ (hppaelf_finish): Update call to hppaelf_delete_padding_statements
+ for above changes.
+ (hppaelf_before_parse): Prototype.
+ (hppaelf_set_output_arch): Prototype.
+ (hppaelf_create_output_section_statements): Prototype.
+ (hppaelf_delete_padding_statements): Prototype.
+ (hppaelf_finish): Prototype.
+
+ Merge from elf32.em
+ * emultempl/hppaelf.em: Include ctype.h.
+ (struct orphan_save): New.
+ (gld${EMULATION_NAME}_place_orphan): New.
+ (output_rel_find): New.
+ (hppaelf_get_script): Update from elf32.em.
+ (ld_hppaelf_emulation): Rename to ld_${EMULATION_NAME}_emulation.
+ Change emulation_name field to "${EMULATION_NAME}". Add
+ gld${EMULATION_NAME}_place_orphan.
+
+ * Makefile.am (ALL_EMULATIONS): Reinstate ehppaelf.o, add
+ ehppalinux.o, sort it. Regenerate dependencies.
+ (ehppalinux.c): Depend on hppaelf.em
+ * Makefile.in: Regenerate.
+
+ * configure.tgt: targ_emul=hppalinux for hppa*linux
+
+ * emulparams/hppalinux.sh: New.
+ * emulparams/hppaelf.sh (TARGET_PAGE_SIZE): Write in hex.
+
+2000-07-08 Alan Modra <alan@linuxcare.com.au>
+
+ * lexsup.c (parse_args): Copy section name.
+
+2000-07-07 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * emultempl/pe.em: institute the following search order for
+ dynamic libraries on pei386: libfoo.dll.a, foo.dll.a (import
+ libs), libfoo.dll, foo.dll (link direct to dll). Fall back to
+ static lib (libfoo.a) if none of the above are found.
+
+2000-07-07 Mumit Khan <khan@xraylith.wisc.edu>
+
+ * emultempl/pe.em (pe_enable_auto_image_base): New variable.
+ (longopts): New --{enable,disable}-auto-image-base options.
+ (gld_${EMULATION_NAME}_list_options): Document.
+ (gld_${EMULATION_NAME}_parse): Handle.
+ (strhash): New static function.
+ (compute_dll_image_base): New static function.
+ (gld_${EMULATION_NAME}_set_symbols): Use.
+
+2000-07-05 DJ Delorie <dj@redhat.com>
+
+ * MAINTAINERS: new
+
+2000-07-01 Koundinya K <kk@ddeorg.soft.net>
+
+ * configure.tgt: Add traditional mips (mips*-*-sysv4*) target.
+ * emulparams/elf32btsmip.sh: New file.
+ * Makefile.am: Add traditional mips target.
+ * Makefile.in: Rebuild.
+
+2000-07-01 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.am (EXTRA_ld_new_SOURCES): Set to deffilep.y for
+ automake to use YLWRAP.
+ * Makefile.in: Rebuild.
+
+2000-07-01 Alan Modra <alan@linuxcare.com.au>
+
+ * Makefile.am (DEP): Fix 2000-06-22. grep after running dep.sed
+ (CLEANFILES): Add DEPA.
+ * Makefile.in: Regenerate.
+
+2000-06-30 Timothy Wall <twall@ppc>
+
+ * scripttempl/tic54xcoff.sc: PAGE N is not implemented, so encode
+ the page in the upper octet of the address.
+
+2000-06-26 Marek Michalkiewicz <marekm@linux.org.pl>
+
+ * emulparams/avrmega161.sh (ARCH): Change to avr:5.
+
+2000-06-24 Alan Modra <alan@linuxcare.com.au>
+
+ * NEWS: arm-elf does --gc-sections too.
+
+2000-06-22 Alan Modra <alan@linuxcare.com.au>
+
+ * Makefile.am (DEP): grep for leading `/' in DEP1, and fail if we
+ find one.
+ * Makefile.in: Regenerate.
+
+2000-06-21 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.am: Rebuild dependency.
+ * Makefile.in: Rebuild.
+
+2000-06-20 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.am: Rebuild dependency.
+ * Makefile.in: Rebuild.
+
+2000-06-20 Timothy Wall <twall@cygnus.com>
+
+ * scripttempl/tic54xcoff.sc: New.
+ * ldlang.c (wild_doit): Propagate SEC_BLOCK flag.
+ * gen-doc.texi: Add flag for TI COFF.
+ * ld.texinfo: Add documentation for TI COFF handling switches.
+ * emultempl/ticoff.em: New. TI COFF handling.
+ * configure.tgt: Add tic54x target.
+ * Makefile.am: Add tic54x target.
+ * Makefile.in: Ditto.
+
+2000-06-20 Alan Modra <alan@linuxcare.com.au>
+
+ * ldmain.c (set_scripts_dir): Correct pointer comparison when
+ checking for backslashes.
+
+2000-06-19 Alan Modra <alan@linuxcare.com.au>
+
+ * NEWS: Move entries not in 2.10 above "Changes in version 2.10".
+
+2000-06-18 Alan Modra <alan@linuxcare.com.au>
+
+ * NEWS: Update list of targets supporting --gc-sections.
+
+ * scripttempl/elf.sc: KEEP .eh_frame contents.
+ * scripttempl/elfd30v.sc: Same here.
+
+2000-06-18 Stephane Carrez <stcarrez@worldnet.fr>
+
+ * Makefile.am (ALL_EMULATIONS): Added new emulation for m68hc12
+ and m68hc11 (elf).
+ * Makefile.in: Rebuild.
+ * configure.tgt: Recognize m68hc12 and m68hc11.
+ * scripttempl/elfm68hc12.sc: New file.
+ * emulparams/m68hc12elfb: New emulation.
+ * emulparams/m68hc12elf: New emulation.
+ * emulparams/m68hc11elfb.sh: New file. User configurable emulation
+ (includes a memory.x script to define the ROM and RAM banks).
+ * scripttempl/elfm68hc11.sc, emulparams/m68hc11elf.sh:
+ New configuration files for support of Motorola 68hc11
+
+2000-06-15 Alan Modra <alan@linuxcare.com.au>
+
+ * ldmain.c (main): Only change SEC_READONLY for final link.
+
+2000-06-13 H.J. Lu <hjl@gnu.org>
+
+ * configure: Regenerate.
+
+2000-06-08 David O'Brien <obrien@FreeBSD.org>
+
+ * configure.in (VERSION): Update to show this is the CVS mainline.
+
+2000-06-07 Michael Sokolov <msokolov@ivan.Harhan.ORG>
+
+ * emultempl/mipsecoff.em (gld{EMULATION_NAME}_after_open): Require all
+ input objects to be ECOFF.
+ (check_sections): einfo takes %B, not %P, to print a BFD name.
+
+2000-06-05 Michael Matz <matz@ifh.de>
+
+ * ldgram.y (vers_defns): Handle 'extern "C++" { ... }' in
+ version scripts.
+
+ * ldlex.l (V_IDENTIFIER): Accept `::' in symbols.
+
+2000-05-23 Marek Michalkiewicz <marekm@linux.org.pl>
+
+ * emulparams/avr1200.sh (STACK): Define as 0.
+ * emulparams/avr23xx.sh (STACK): Define as last internal SRAM address.
+ * emulparams/avr4433.sh (STACK): Likewise.
+ * emulparams/avr44x4.sh (STACK): Likewise.
+ * emulparams/avr85xx.sh (STACK): Likewise.
+ * emulparams/avrmega103.sh (STACK): Likewise.
+ * emulparams/avrmega161.sh (STACK): Likewise.
+ * emulparams/avrmega603.sh (STACK): Likewise.
+ * scripttempl/elf32avr.sc (__data_start): Define for gcrt1.
+ (__stack): Define from ${STACK} for main().
+
+2000-05-26 Alan Modra <alan@linuxcare.com.au>
+
+ * Makefile.am: Update dependencies with "make dep-am"
+ * Makefile.in: Regenerate.
+
+2000-05-26 Eli Zaretskii <eliz@is.elta.co.il>
+
+ * ldmain.c: Include filenames.h.
+ (set_scripts_dir): Support backslashes in program name.
+
+2000-05-22 Igor Shevlyakov <igor@windriver.com>
+
+ * ldmain.c (main): When deciding if ".text" section should be
+ read-only, don't forget to reset SEC_READONLY because it
+ could be already set.
+
+2000-05-22 Thomas de Lellis <tdel@windriver.com>
+
+ * ld.1: Add documentation for new command line option:
+ --section-start <sectionname>=<sectionorg>
+ This is a generic version of -Ttext etc. which accepts
+ any section name as a parameter instead of just text/data/
+ bss.
+ * ld.texinfo: More docs.
+ * NEWS: More docs.
+ * lexsup.c: (parse_args): Recognize new command line option.
+ (ld_options): Add new option.
+
+2000-05-18 H.J. Lu <hjl@gnu.org>
+
+ * lexsup.c (parse_args): `i' == `r', not `q'.
+
+2000-05-18 Jeffrey A Law (law@cygnus.com)
+
+ * configure.tgt (hppa*64*-*-*): Enable PA64 target.
+
+2000-05-17 S. Bharadwaj Yadavalli <sby@scrugs.lkg.dec.com>
+ Rick Gorton <gorton@scrugs.lkg.dec.com>
+
+ Add support for '-q' == '--emit-relocs' switch.
+ * ldmain.c (main): Default to false.
+ * lexsup.c (parse_args): Turn on emitrelocations flag if set.
+ * NEWS: Describe the emitrelocations switch.
+ * ld.texinfo: Describe the emitrelocations switch.
+
+2000-05-16 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * emultempl/pe.em (_open_dynamic_archive): New function: Search
+ the library path for "foo.dll" and "libfoo.dll" dynamic libraries
+ before searching for 'libfoo.a' in response to a '-Bdynamic -lfoo'
+ link options.
+
+2000-05-15 David O'Brien <obrien@FreeBSD.org>
+
+ * lexsup.c (parse_args): Update the year in the copyright notice.
+
+2000-05-13 Alan Modra <alan@linuxcare.com.au>
+
+ * ld.h (gettext, dgettext, dcgettext, textdomain, bindtextdomain):
+ Replace defines with those from intl/libgettext.h to quieten gcc
+ warnings.
+
+2000-05-10 H.J. Lu <hjl@gnu.org>
+
+ * ldlang.c (open_input_bfds): Don't load the same file within
+ a group again if the whole archive has been loaded already.
+
+2000-05-03 Alan Modra <alan@linuxcare.com.au>
+
+ From Ulf Carlsson <ulfc@engr.sgi.com> and Andreas Jaeger <aj@suse.de>
+ * lexsup.c (set_section_start): Use bfd_scan_vma rather than
+ strtoul.
+
+2000-05-01 Jim Wilson <wilson@cygnus.com>
+
+ * configure.host (ia64-*-linux-gnu*): Change gcc to ${CC}.
+
+ * configure.host: Added HOSTING_CRT0, HOSTING_LIBS for
+ host "ia64-*-linux-gnu*".
+
+2000-04-29 Andreas Jaeger <aj@suse.de>
+
+ * ld.h: Correctly check GCC version.
+
+2000-04-25 Jeffrey A Law (law@cygnus.com)
+
+ * Makefile.am: Add PA64 support. Add missing dependencies for
+ PA32 elf support.
+ * Makefile.in: Rebuilt.
+ * configure.tgt: Add PA64 support (currently disabled).
+
+2000-04-25 Alan Modra <alan@linuxcare.com.au>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_place_section): Delete.
+ (output_rel_find): New function.
+ (hold_section, hold_use): Delete.
+ (hold_text, hold_rodata, hold_data, hold_bss, hold_rel,
+ hold_interp): Make local to place_orphan.
+ (gld${EMULATION_NAME}_place_orphan): Use lang_output_section_find
+ rather than place_section to find possible previous use of orphan.
+ Similarly find the place-holder output sections. Use returned
+ value from lang_enter_output_section_statement rather than calling
+ lang_output_section_statement_lookup.
+ * emultempl/armelf.em: Same here.
+ * emultempl/pe.em: Similar to above, but no need for output_rel_find.
+
+ * ldlang.c (lang_enter_output_section_statement): Return output
+ section statement.
+ * ldlang.h (lang_enter_output_section_statement): Change
+ declaration too.
+
+ * ldlang.h (lang_output_section_statement): Export it.
+ * ldlang.c (lang_output_section_statement): Ditto.
+
+2000-04-24 Nick Clifton <nickc@cygnus.com>
+
+ * ld.texinfo (Output Section Data): Add note that section data
+ commands cannot appear outside of section directives.
+
+2000-04-2 Matthew Green <mrg@cygnus.com>
+
+ * configure.tgt: Add NetBSD/sparc ELF, and NetBSD/sparc64 support.
+
+2000-04-21 Richard Henderson <rth@cygnus.com>
+ David Mosberger <davidm@hpl.hp.com>
+
+ * Makefile.am (ALL_64_EMULATIONS): Add eelf64_ia64.o.
+ (eelf64_ia64.c): New rule.
+ * Makefile.in: Rebuild.
+ * configure.tgt (ia64-*-elf*, ia64-*-linux*): New targets.
+ * emulparams/elf64_ia64.sh: New file.
+
+2000-04-21 Richard Henderson <rth@cygnus.com>
+
+ * scripttempl/elfd30v.sc: Place .gcc_except_table.
+
+2000-04-19 Alan Modra <alan@linuxcare.com.au>
+
+ * dep-in.sed: Match space at start of file name, not at end.
+
+2000-04-18 H.J. Lu <hjl@gnu.org>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Call
+ lang_leave_output_section_statement () after calling
+ lang_enter_output_section_statement ().
+ * emultempl/armelf.em: Likewise.
+
+2000-04-18 Alan Modra <alan@linuxcare.com.au>
+
+ * emultempl/elf32.em (struct orphan_save): Add section field.
+ (gld${EMULATION_NAME}_place_orphan): Use above to keep sections in
+ better order, and place first orphan section as we did before the
+ 2000-04-12 patch. Ignore ~SEC_ALLOC sections when choosing place.
+ Don't call make_bfd_section here, let wild_doit do the job for us.
+ Don't build a statement list when we'll only throw it away.
+ * emultempl/armelf.em: Ditto.
+ * emultempl/pe.em: Similarly.
+
+2000-04-14 Geoff Keating <geoffk@cygnus.com>
+
+ * scripttempl/elfppc.sc: Remove.
+ * emulparams/elf32ppc.sh: Use elf.sc.
+ * emulparams/elf32lppc.sh: Use elf.sc.
+ * emulparams/elf32ppclinux.sh: Use elf.sc.
+ * emulparams/elf32ppcsim.sh: New file.
+ * emulparams/elf32lppcsim.sh: New file.
+ * Makefile.am: Update dependencies. Add elf32ppcsim ad elf32lppcsim.
+ (ALL_EMULATIONS): Add elf32ppcsim ad elf32lppcsim.
+ * Makefile.in: Regenerate.
+ * configure.tgt (powerpc-*): Add elf32ppcsim and elf32lppcsim.
+
+2000-04-14 Alan Modra <alan@linuxcare.com.au>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Process
+ ~SEC_ALLOC sections too. Init start address of debug sections.
+ * emultempl/armelf.em (gld${EMULATION_NAME}_place_orphan): Ditto.
+ * emultempl/pe.em (gld${EMULATION_NAME}_place_orphan): Ditto.
+ Also set all relocateable section start addresses.
+
+2000-04-13 Geoff Keating <geoffk@cygnus.com>
+
+ * scripttempl/elf.sc: Add support for .sbss2 and .sdata2 sections.
+ Add new BSS_PLT variable for when .plt need not be contained in
+ the file. Move _etext so that it is also after .fini, and provide
+ both etext and _etext with a leading underscore. Mark the start
+ and end of .sbss.
+
+2000-04-12 Alan Modra <alan@linuxcare.com.au>
+
+ * emultempl/elf32.em (struct orphan_save): New.
+ (hold_text, hold_rodata, hold_data, hold_bss, hold_rel,
+ hold_interp): Make them struct orphan_save.
+ (gld${EMULATION_NAME}_place_section): Modify for new hold_*.
+ (gld${EMULATION_NAME}_place_orphan): Add new orphan sections to
+ the end of the relevant section list. Also add associated section
+ statements to the end of any previous orphan statements.
+ * emultempl/armelf.em: Similarly.
+ * emultempl/pe.em: Similarly.
+
+2000-04-11 Alan Modra <alan@linuxcare.com.au>
+
+ * ld.texinfo (Simple Example): Remove extraneous paragraph.
+
+2000-04-07 Andrew Cagney <cagney@b1.cygnus.com>
+
+ * configure.in (WARN_CFLAGS): Set to -W -Wall by default. Add
+ --enable-build-warnings option.
+ * Makefile.am (AM_CFLAGS, WARN_CFLAGS): Add definitions.
+ * Makefile.in, configure: Re-generate.
+
+2000-04-04 Alan Modra <alan@linuxcare.com.au>
+
+ * po/ld.pot: Regenerate.
+
+ * lexsup.c (help): Restore translated part of bug string.
+
+ * Makefile.am (MKDEP): Use gcc -MM rather than mkdep.
+ (DEP): Quote when passing vars to sub-make. Add warning message
+ to end.
+ (DEP1): Rewrite for "gcc -MM".
+ (CLEANFILES): Add DEP2.
+ Update dependencies.
+ * Makefile.in: Regenerate.
+
+2000-04-03 Alan Modra <alan@linuxcare.com.au>
+
+ * ld.h: #include "bin-bugs.h"
+ * lexsup.c (help): Use REPORT_BUGS_TO.
+
+2000-03-27 Denis Chertykov <denisc@overta.ru>
+
+ * configure.tgt (avr-*-*): New target support.
+ * Makefile.am: Likewise.
+ * scripttempl/elf32avr.sc: New script file.
+ * emulparams/avr1200.sh: New file.
+ * emulparams/avr23xx.sh: New file.
+ * emulparams/avr4433.sh New file.
+ * emulparams/avr44x4.sh New file.
+ * emulparams/avr85xx.sh New file.
+ * emulparams/avrmega103.sh New file.
+ * emulparams/avrmega161.sh New file.
+ * emulparams/avrmega603.sh New file.
+ * Makefile.in: Regenerate.
+
+2000-03-09 Andreas Jaeger <aj@suse.de>
+
+ * Makefile.am (check-DEJAGNU): Also unset LANG.
+ * Makefile.in: Rebuild.
+
+2000-03-06 Ian Lance Taylor <ian@zembu.com>
+
+ * ldfile.c (ldfile_try_open_bfd): Don't crash if we see an empty
+ archive.
+
+2000-03-02 H.J. Lu <hjl@gnu.org>
+
+ * emulparams/elf32mcore.sh: Include "getopt.h".
+
+2000-03-01 Ian Lance Taylor <ian@zembu.com>
+
+ * configure.tgt: Remove *-*-aout, *-*-coff, and *-*-netware.
+
+2000-03-01 H.J. Lu <hjl@gnu.org>
+
+ * emulparams/mipspe.sh: Add SUBSYSTEM and INITIAL_SYMBOL_CHAR.
+ * emulparams/shpe.sh: Likewise.
+
+2000-03-01 Nick Clifton <nickc@cygnus.com>
+
+ * pe-dll.c: Remove unused variables and add ATTRIBUTE_UNUSED
+ to unused parameters.
+
+ * emultempl/pe.em: Add "#ifdef DLL_SUPPORT" around static
+ functions only used by DLL code.
+ (_place_orphan): Initialise 'dollar'.
+
+2000-03-01 H.J. Lu <hjl@gnu.org>
+
+ * ldmain.c (undefined_symbol): Take one more arg, fatal, to
+ indicate if the undefined symbol is a fatal error or not.
+ Don't delete the output file if "fatal" is false.
+
+2000-02-29 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.am (check-DEJAGNU): Also pass LIBS="$(LIBS)".
+ Set LC_COLLATE and LC_ALL to null and export them. It is for
+ sort which expects the C locale.
+ Add $(LIBS) to all $(HOSTING_LIBS).
+ * Makefile.in: Rebuild.
+
+2000-02-29 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * emultempl/{aix.em, armcoff.em, armelf.em, armelf_oabi.em,
+ beos.em, elf32.em, generic.em, gld960.em, gld960c.em, hppaelf.em,
+ linux.em, lnk960.em, mipsecoff.em, sunos.em, vanilla.em}
+ (ld_emulation_xfer_struct): Add missing NULL initialiser for
+ find_potential_libraries.
+
+2000-02-28 Jim Blandy <jimb@redhat.com>
+
+ * ldgram.y (exclude_name_list): Don't require a comma to separate
+ list entries; the lexer considers commas to be valid part of a
+ filename, so in something like `foo, bar' the comma is considered
+ part of the first filename, `foo,'.
+ * ld.texinfo: Update section on EXCLUDE_FILE lists.
+
+2000-02-27 Loren J. Rittle <ljrittle@acm.org>
+
+ * configure.host: Added HOSTING_CRT0, HOSTING_LIBS for
+ host "i[3456]86-*-freebsdelf*".
+
+2000-02-27 Mark Elbrecht <snowball3@bigfoot.com>
+
+ * scripttempl/i386go32.sc: Move misplaced semicolons.
+
+2000-02-25 Ian Lance Taylor <ian@zembu.com>
+
+ * Makefile.am (ALL_EMULATIONS): Remove ehppaelf.o.
+ (ALL_64_EMULATIONS): Remove eelf64hppa.o.
+ (eelf64hppa.c, ehppaelf.c): Remove targets.
+ * Makefile.in: Rebuild.
+
+2000-02-25 Alexandre Oliva <oliva@lsd.ic.unicamp.br>
+
+ * configure.tgt (targ_extra_ofiles): Enable elf64_sparc on
+ GNU/Linux/sparc, but keep the default as 32.
+
+ * configure.tgt: Enable elf64_sparc on Solaris7+/sparc. And make
+ it default if sparcv9 or sparc64.
+
+2000-02-24 Nick Clifton <nickc@cygnus.com>
+
+ * Makefile.am: Add rules to build emipspe.o and earmpe.o.
+ * Makefile.in: Regenerate.
+ * configure.tgt: Add targets for arm-wince, sh-pe and mips-pe.
+
+ * ldemul.h (ld_emulation_xfer_struct): Add new field:
+ find_potential_libraries.
+ * ldemul.c (ldemul_find_potential_libraries): New function.
+
+ * ldfile.c (ldfile_open_file_search): Allow function to be
+ exported.
+ (ldfile_open_file): Call ldemul_find_potential_libraries.
+ * ldfile.h: Add prototype for ldfile_open_file_search.
+
+ * pe-dll.c: Add support for ARM, MIPS and SH targets.
+
+ * emulparams/mipspe.sh: New file. Parameters for mips-pe target.
+ * emulparams/shpe.sh: New file. Parameters for sh-pe target.
+
+ * emultempl/pe.em: Add support for ARM, MIPS and SH DLLs.
+ (gld_X_find_potential_libraries): New function. Search for
+ libraries called "*.lib".
+
+ * scripttempl/pe.sc: Add .pdata section.
+
+2000-02-23 Richard Henderson <rth@cygnus.com>
+
+ * scripttempl/elfd10v.sc: Remove dynamic linking hooks.
+ Add and use memory regions.
+
+2000-02-23 Linas Vepstas (linas@linas.org)
+
+ * emulparams/elf32i370.sh, scripttempl/elfi370.sc: New.
+
+ * Makefile.am: Add support for Linux/IBM 370.
+ * configure.tgt: Likewise.
+
+ * Makefile.in: Regenerate.
+
+2000-02-21 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * ldlang.c (print_input_section, print_data_statement,
+ print_reloc_statement, print_padding_statement, insert_pad,
+ size_input_section, lang_check_section_addresses,
+ lang_size_sections, lang_do_assignments, lang_set_startof,
+ lang_one_common): Change `opb' to unsigned.
+ (lang_do_assignments): Also change `size' to unsigned.
+
+2000-02-16 Richard Henderson <rth@cygnus.com>
+
+ * scripttempl/elf.sc: Place OTHER_PLT_RELOC_SECTION.
+
+2000-02-16 Timothy Wall <twall@cygnus.com>
+
+ * mri.c (mri_draw_tree): Add default LMA region argument to call
+ to lang_leave_output_section_statement.
+ * ldlang.h: Update prototypes with LMA region arguments.
+ * ldlang.c (lang_size_sections): Encapsulate region bounds
+ checking in os_check_region call.
+ (os_check_region): New function.
+ (lang_output_section_statement_lookup): Initialize lma_region.
+ (lang_leave_output_section_statement): Add LMA region argument.
+ (lang_leave_overlay): Ditto.
+ * ldgram.y: Handle LMA region syntax.
+ * ld.texinfo (Output Section Description): Describe LMA region usage.
+ * emultempl/armelf.em (gld$place_orphan): Add default value for
+ lma region in call to lang_leave_output_section_statement.
+ * emultempl/elf32.em (gld$place_orphan): Add default value for
+ lma region in call to lang_leave_output_section_statement.
+ * emultempl/pe.em (gld$place_orphan): Add default value for
+ lma region in call to lang_leave_output_section_statement.
+
+
+2000-02-04 Timothy Wall <twall@redhat.com>
+
+ * ldlang.c (lang_check_section_addresses): Use bytes instead of
+ octets when calculating section end addresses.
+
+2000-02-04 Timothy Wall <twall@redhat.com>
+
+ * ldlang.c (lang_size_sections): Fix typo in ALIGN_N invocation.
+
+2000-02-03 Timothy Wall <twall@redhat.com>
+
+ * ldexp.c (fold_name): Make SIZEOF operator return byte count, not
+ octet count.
+ * ldlang.c (print_input_section, print_data_statement,
+ print_reloc_statement, print_padding_statement): Print target
+ address values and section sizes as bytes, not octets.
+ (insert_pad) Calculate padding size in octets, and adjust "dot"
+ by bytes.
+ (size_input_section) Always adjust "dot" by bytes, not octets.
+ (lang_check_section_addresses, lang_do_assignments) Adjust
+ "dot" by bytes, not octets. Use the larger of the directive size
+ or octets_per_byte for the number of octets actually allocated in
+ the output section.
+ (lang_set_startof) Make sure STARTOF returns a target address.
+ (lang_one_common) Record size changes in octets.
+ (lang_abs_symbol_at_end_of) Section end symbol's value is
+ recorded in target bytes.
+ * ld.texinfo: Updated description of BYTE, SHORT, LONG, etc.
+ to be clear about behavior when an octet is smaller than one byte.
+
+2000-01-27 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * ldcref.c (output_cref): Don't pass message strings to printf
+ as format arg.
+ Update copyright.
+
+ * ldmisc.c (vfinfo): Same here.
+ Update copyright.
+
+2000-01-23 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * emultempl/{armcoff.em,armelf.em,armelf_oabi.em,beos.em,
+ generic.em,gld960.em,gld960c.em,hppaelf.em,linux.em,lnk960.em,
+ mipsecoff.em,sunos.em,vanilla.em} (ld_emulation_xfer_struct):
+ Add missing NULL initialisers, and comments.
+
+2000-01-21 Nick Clifton <nickc@cygnus.com>
+
+ * ldlang.c (lang_size_sections): Fix typo in comment.
+
+2000-01-18 H.J. Lu <hjl@gnu.org>
+
+ * ldlang.c (lang_size_sections): Also update the current
+ address of a region if the SEC_NEVER_LOAD bit is not set.
+
+2000-01-10 Philip Blundell <pb@futuretv.com>
+
+ * configure.tgt (arm*-*-conix*): New target.
+
+2000-01-07 Nick Clifton <nickc@cygnus.com>
+
+ * ld.texinfo (Options): Remind users to preceed linker command
+ line switches with -Wl, (or whatever is appropriate) if it is
+ being invoked by a comnpiler driver program.
+ Fix description of the behaviour of the -n command line switch.
+
+2000-01-05 Catherine Moore <clm@cygnus.com>
+
+ * ld.h (wildcard_spec): Change exclude_name to exclude_name_list.
+ (name_list): New.
+ * ld.texinfo (EXCLUDE_FILE): Update documentation.
+ * ldgram.y (wildcard_spec): Support a list of excluded_files.
+ (exclude_name_list): New.
+ ldlang.c (walk_wild_section): Support list of excluded files.
+ (print_wild_statement): Likewise.
+ (lang_add_wild): Likewise.
+ * ldlang.h (lang_wild_statement_type): Likewise.
+ * scripttempl/elf.sc (OTHER_EXCLUDE_FILES): Support.
+
+2000-01-04 Mumit Khan <khan@xraylith.wisc.edu>
+
+ * pe-dll.c (pe_dll_warn_dup_exports): New variable.
+ (process_def_file): Use.
+ (pe_dll_compat_implib): New variable.
+ (make_one): Use.
+
+ * pe-dll.h: Add exports of pe_dll_warn_dup_exports and
+ pe_dll_compat_implib.
+
+ * emultempl/pe.em (longopts): Add warn-duplicate-exports and
+ compat-implib options.
+ (gld_${EMULATION_NAME}_list_options): List new options.
+ (gld_${EMULATION_NAME}_parse_args): Handle.
+
+ * pe-dll.c (pe_dll_generate_implib): Use the correct name for output
+ dll.
+
+ * deffilep.y (opt_name): Allow "." in name.
+
+For older changes see ChangeLog-9899
+
+Local Variables:
+mode: change-log
+left-margin: 8
+fill-column: 74
+version-control: never
+End:
diff --git a/contrib/binutils/ld/ChangeLog-0203 b/contrib/binutils/ld/ChangeLog-0203
new file mode 100644
index 0000000..ee5354d
--- /dev/null
+++ b/contrib/binutils/ld/ChangeLog-0203
@@ -0,0 +1,3580 @@
+2003-12-19 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
+
+ Add m32r-linux and PIC support. Add new ABI that uses RELA.
+ * Makefile.am: Added em32rlelf.c, em32relf_linux.c,
+ em32rlelf_linux.c.
+ * Makefile.in: Regenerate.
+ * configure.tgt (m32r*-*-linux*, m32r*le-*-linux*, m32r*le-*-*):Added.
+ * emulparams/m32relf_linux.sh: Added.
+ * emulparams/m32rlelf.sh: Ditto.
+ * emulparams/m32rlelf_linux.sh: Ditto.
+ * NEWS: Mention support m32r Linux.
+
+2003-12-18 Eric Youngdale <eric@mkssoftware.com>
+ Nick Clifton <nickc@redhat.com>
+
+ * emultempl/pe.em (_after_open): When scanning MS import
+ libraries allow for the possible presence of static objects.
+
+2003-12-07 H.J. Lu <hongjiu.lu@intel.com>
+
+ * ldlang.c (lang_vers_match): Pass "DMGL_PARAMS | DMGL_ANSI" to
+ cplus_demangle.
+
+2003-12-07 Kazu Hirata <kazu@cs.umass.edu>
+
+ * ldemul.c: Convert to ISO-C.
+ * ldver.c: Likewise.
+
+2003-12-06 Kazu Hirata <kazu@cs.umass.edu>
+
+ * lexsup.c (is_num): Remove.
+
+2003-12-05 Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
+
+ * pe-dll.c (generate_reloc): Remap ARM_26D relocation from 5 to
+ 0. This fixes "bad fixup" error generated by MS linker.
+
+2003-12-04 H.J. Lu <hongjiu.lu@intel.com>
+
+ * emultempl/ia64elf.em (gld${EMULATION_NAME}_after_parse): Set
+ link_info.need_relax_finalize to TRUE.
+
+ * ldlang.c (lang_process): Use link_info.need_relax_finalize
+ instead of link_info.relax_finalizing.
+ * ldmain.c (main): Likewise.
+
+2003-12-04 Dmitry Semyonov <Dmitry.Semyonov@oktet.ru>
+
+ * armpe.sh (RELOCATEABLE_OUTPUT_FORMAT): Define.
+
+2003-12-04 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (lang_do_assignments): Function return is void.
+ * ldlang.h (lang_do_assignments): Ditto.
+ * emultempl/netbsd.em (gld${EMULATION_NAME}_before_parse): Declare.
+ * Makefile.am (ens32knbsd.c): Depend on netbsd.em.
+ * Makefile.in: Regenerate.
+
+2003-12-03 Dave Airlie <airlied@linux.ie>
+
+ * configure.tgt: Add vax-linux-gnu target.
+
+2003-12-03 Dmitry Diky <diwil@mail.ru>
+
+ * scripttempl/elf32msp430.sc (HEAP_SECTION_MSP430): New section for
+ forthcoming devices.
+ (_etext): provide this defenition for all scripts.
+
+2003-12-02 Kazu Hirata <kazu@cs.umass.edu>
+
+ * emultempl/beos.em: Remove ARGSUSED.
+
+2003-12-03 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/pe.em (pe_fixup_stdcalls): Update for renamed
+ bfd_link_hash_entry field "next" -> "und_next".
+ (pe_find_data_imports): Likewise.
+ (gld_${EMULATION_NAME}_after_open): Likewise.
+ * emultempl/sunos.em (before_allocation): Likewise.
+
+2003-12-02 Nick Clifton <nickc@redhat.com>
+
+ * ld.texinfo (Options): --ignore-all is no longer the default
+ behaviour for shared libraries and dynamic executables.
+
+2003-12-02 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2003-12-02 Alan Modra <amodra@bigpond.net.au>
+
+ * ldmain.c (main): Remove mpc860c0 code.
+ * lexsup.c (enum option_values): Delete OPTION_MPC860C0.
+ (ld_options): Delete mpc860c0 entry.
+ (parse_args): Likewise.
+
+2003-12-01 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation): Test
+ hash table type rather than testing creator flavour.
+ * emultempl/hppaelf.em (hppaelf_create_output_section_statements):
+ Only create stub_file bfd if hash table creator is as expected.
+ (gld${EMULATION_NAME}_finish): Test stub_file.
+
+2003-11-28 Marcel Moolenaar <marcel@xcllnt.net>
+
+ * emulparams/elf64_ia64_fbsd.sh (TEXT_START_ADDR): Define.
+ (DATA_ADDR): Unset.
+
+2003-11-18 James E Wilson <wilson@specifixinc.com>
+
+ * ldlang.c (lang_process): Move lang_reset_memory_regions call after
+ lang_do_assignments call.
+
+ * emulparams/elf64_ia64.sh (OTHER_PLT_RELOC_SECTIONS): Include
+ .rela.opd if -pie.
+
+2003-11-10 Jonathan Wilson <jonwil@tpgi.com.au>
+
+ * scripttempl/pe.sc: Add support for TLS sections.
+
+2003-11-09 Alan Modra <amodra@bigpond.net.au>
+
+ * configure.host (HOSTING_LIBS): Group libgcc and libc with
+ --start-group, --end-group pair.
+ (*-*-netbsd*, am33_2.0-*-linux*): Use the default HOSTING_LIBS.
+ (am33_2.0-*-linux*): Edit default HOSTING_CRT0.
+ (arm*-*-linux-gnu*): Remove extraneous '*' in sed expression.
+ (hppa*64*-*-linux*, hppa*-*-linux*): Remove target specific case.
+
+2003-11-07 Jonathan R. Grant <jg-binutils@jguk.org>
+
+ * ldfile.c (ldfile_open_file): Use "No such file" error message.
+
+2003-11-06 Bruno Rohee <bruno@rohee.com>
+
+ * ls.texinfo: Fix "the the" typo.
+
+2003-11-05 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/pe.em (gld_${EMULATION_NAME}_after_open): Only do
+ pe_dll_extra_pe_debug stuff when DLL_SUPPORT defined.
+ (pr_sym): Move inside #ifdef DLL_SUPPORT.
+
+ * emultempl/ppc64elf.em (gld${EMULATION_NAME}_new_vers_pattern): Zap
+ unused variable.
+
+ * emulparams/elf32_i860.sh (TEXT_START_ADDR): Define.
+
+2003-11-04 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_before_allocation): Call
+ _bfd_elf_tls_setup.
+
+2003-10-31 Nick Clifton <nickc@redhat.com>
+
+ * ldlang.c (lookup_name): When looking for a previously loaded
+ file compare the local_sym_name not the filename, as the
+ filename might have been transformed via the search directory
+ path lookup.
+ If the sought-for file has not been found in the input file
+ chain then create a new node with the search_dirs_flag set so
+ that the entire set of directory paths will be scanned for it.
+
+2003-10-30 Andrew Cagney <cagney@redhat.com>
+
+ * emultempl/pe.em, pe-dll.c: Replace "struct symbol_cache_entry"
+ with "struct bfd_symbol".
+
+2003-10-30 Phil Edwards <phil@codesourcery.com>
+
+ * Makefile.am (ALL_EMULATIONS): Add elf32mipswindiss.o.
+ (eelf32mipswindiss.c): New target.
+ * Makefile.in: Regenerated.
+ * emulparams/elf32mipswindiss.sh: New file.
+ * configure.tgt (i[3-7]86-*-vxworks*, arm-*-vxworks, sh-*-vxworks,
+ mips*-*-vxworks*): Use ELF now.
+ (mips*-*-windiss): New stanza, use elf32mipswindiss.
+
+2003-10-27 Stephane Carrez <stcarrez@nerim.fr>
+
+ * scripttempl/elfm68hc12.sc: Define eeprom memory region.
+
+2003-10-25 Kazu Hirata <kazu@cs.umass.edu>
+
+ * ChangeLog-9197: Fix typos.
+ * NEWS: Likewise.
+ * ld.texinfo: Likewise.
+ * ldlang.c: Fix comment typos.
+
+2003-10-24 H.J. Lu <hongjiu.lu@intel.com>
+
+ * ldlang.c (lang_vers_match): Fix a typo.
+
+2003-10-24 H.J. Lu <hongjiu.lu@intel.com>
+
+ * ldlang.c (lang_vers_match): Check demangled symbols.
+
+2003-10-24 H.J. Lu <hongjiu.lu@intel.com>
+
+ * ldlang.c (lang_vers_match): Check "symbol" instead of
+ "wildcard" and "pattern". Fix a typo.
+ (lang_finalize_version_expr_head): Likewise.
+ (lang_register_vers_node): Likewise.
+ (realsymbol): New function.
+ (lang_new_vers_pattern): Set "symbol" and remove "wildcard".
+
+ * ldlex.l (V_IDENTIFIER): Allow '\\'.
+
+2003-10-24 Nick Clifton <nickc@redhat.com>
+
+ * emultempl/m68hc1xelf.em (before_allocation): Add missing second
+ parameter to lang_memory_region_lookup.
+
+2003-10-22 Jakub Jelinek <jakub@redhat.com>
+
+ * ldlang.c: Include hashtab.h.
+ (lang_vers_match_lang_c, lang_vers_match_lang_cplusplus,
+ lang_vers_match_lang_java): Remove.
+ (lang_vers_match): New function.
+ (lang_new_vers_pattern): Initialize wildcard and mask
+ fields, don't initialize match.
+ (lang_new_vers_node): Use xcalloc. Adjust for globals and
+ locals field type changes. Set match field.
+ (version_expr_head_hash, version_expr_head_eq): New functions.
+ (lang_finalize_version_expr_head): New function.
+ (lang_register_vers_node): Call lang_finalize_version_expr_head.
+ Search in hash table if not wildcard when looking for duplicates.
+ * emultempl/ppc64elf.em (new_vers_pattern): Don't bother with
+ duplicate checking. Initialize all fields of dot_entry from entry
+ with the exception of pattern and next.
+
+2003-10-21 Nick Clifton <nickc@redhat.com>
+
+ * ldlang.c (lang_memory_region_lookup): Add second parameter -
+ create - which is true if the region is being created. Issue
+ appropriate warning messages for finding and not finding
+ already created regions.
+ (lang_memory_default): Use DEFAULT_MEMORY_REGION.
+ (lang_leave_overlay_section): Likewise.
+ (lang_size_sections_1): Likewise.
+ Pass second parameter to lang_memory_region_lookup.
+ (lang_get_regions): Likewise.
+ * ldlang.h (DEFAULT_MEMORY_REGION): Define.
+ Update prototype for lang_memory_region_lookup.
+ * ldgram.y: Pass second parameter to lang_memory_region_lookup.
+ Use DEFAULT_MEMORY_REGION instead of "*default".
+
+2003-10-20 Andrew Cagney <cagney@redhat.com>
+
+ * pe-dll.c: Replace "struct sec" with "struct bfd_section".
+
+2003-10-19 Marek Michalkiewicz <marekm@amelek.gda.pl>
+
+ * Makefile.am: Remove old (before GCC 3.3) emulations for AVR
+ target: avr1200, avr23xx, avr4433, avr44x4, avr85xx, avrmega103,
+ avrmega161, avrmega603. Default to avr2.
+ * Makefile.in: Regenerate.
+ * configure.tgt: Likewise.
+ * emulparams/avr1200.sh: Remove.
+ * emulparams/avr23xx.sh: Remove.
+ * emulparams/avr4433.sh: Remove.
+ * emulparams/avr44x4.sh: Remove.
+ * emulparams/avr85xx.sh: Remove.
+ * emulparams/avrmega103.sh: Remove.
+ * emulparams/avrmega161.sh: Remove.
+ * emulparams/avrmega603.sh: Remove.
+ * scripttempl/elf32avr.sc: Remove.
+
+2003-10-19 Andreas Schwab <schwab@suse.de>
+
+ * emultempl/ticoff.em (gld_${EMULATION_NAME}_list_options): Add
+ newline to message.
+
+ * deffilep.y: Remove commas from %token lines.
+
+2003-10-18 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * emultempl/mmix-elfnmmo.em (mmix_before_allocation): Force linker
+ relaxation always; don't exclude relocatable linking. Adjust for
+ _bfd_mmix_prepare_linker_allocated_gregs renamed to
+ _bfd_mmix_before_linker_allocation.
+ (mmix_after_allocation): Adjust for
+ _bfd_mmix_finalize_linker_allocated_gregs renamed to
+ _bfd_mmix_after_linker_allocation.
+ * scripttempl/mmo.sc: Use ADDR (.text), not . - SIZEOF (.text).
+
+ * ldlang.c (lang_size_sections): Last, set _cooked_size for output
+ sections.
+
+2003-10-16 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (GENSCRIPTS_EXTRA, GEN_EXTRA_DEPENDS): Remove. Use
+ GENSCRIPTS and GEN_DEPENDS in place of these.
+ * Makefile.in: Regenerate.
+ * genscripts_extra.sh: Delete. Merge extra functionality to..
+ * genscripts.sh: ..here.
+
+ * emulparams/gld960.sh (TEXT_START_ADDR, TARGET_PAGE_SIZE): Define.
+ * emulparams/gld960coff.sh (TEXT_START_ADDR, TARGET_PAGE_SIZE): Ditto.
+ * emulparams/lnk960.sh (TEXT_START_ADDR, TARGET_PAGE_SIZE): Ditto.
+ * emulparams/m88kbcs.sh (TEXT_START_ADDR, TARGET_PAGE_SIZE): Ditto.
+ * emulparams/vanilla.sh (TEXT_START_ADDR, TARGET_PAGE_SIZE): Ditto.
+
+2003-10-16 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/ia64elf.em (gld${EMULATION_NAME}_after_parse): Don't
+ use $EMULATION_NAME to call bfd function.
+
+2003-10-14 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * pe-dll.c (pe_implied_import_dll): Also scan .rdata sections
+ to identify data symbols.
+
+2003-10-13 Richard Sandiford <rsandifo@redhat.com>
+
+ * emulparams/elf32bmipn32-defs.sh (INITIAL_READONLY_SECTIONS): Move
+ definition from elf64btsmip.sh.
+ (TEXT_DYNAMIC): Likewise elf32btsmipn32.sh.
+ * emulparams/elf32btsmipn32.sh (TEXT_DYNAMIC): Remove.
+ * emulparams/elf64btsmip.sh (INITIAL_READONLY_SECTIONS): Remove.
+ * emulparams/elf64bmip.sh (SHLIB_TEXT_START_ADDR): Define.
+ (EXECUTABLE_SYMBOLS): Set __elf_header correctly for shared objects.
+ Define __program_header_table in terms of __elf_header.
+
+2003-10-10 H.J. Lu <hongjiu.lu@intel.com>
+
+ * Makefile.am (eelf64_ia64.c): Also depend on
+ $(srcdir)/emultempl/ia64elf.em.
+ * Makefile.in: Regenerated.
+
+ * emulparams/elf64_ia64.sh (EXTRA_EM_FILE): Set to ia64elf.
+
+ * emultempl/ia64elf.em: New.
+
+2003-10-12 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * emulparams/shelf32_nbsd.sh (OTHER_SECTIONS): Redefine.
+
+2003-10-11 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * ld.texinfo (Builtin Functions) <DEFINED>: Say that only symbols
+ defined before the statement using DEFINED yield 1.
+ * ldexp.c (fold_name) <case DEFINED>: In lang_first_phase_enum,
+ call lang_track_definedness on symbol. In subsequent phases, use
+ lang_symbol_definition_iteration and lang_statement_iteration to
+ check whether the symbol was defined before the current statement.
+ (exp_fold_tree) <case etree_assign et al>: Call
+ lang_update_definedness before updating symbol type when setting
+ symbol.
+ * ldlang.c (lang_definedness_table): New variable.
+ (lang_definedness_newfunc, lang_track_definedness)
+ (lang_symbol_definition_iteration, lang_update_definedness): New
+ functions.
+ (lang_init): Initialize lang_definedness_table and
+ lang_statement_iteration.
+ (lang_finish): Destroy bfd_hash_table_free.
+ (lang_size_sections): Increment lang_statement_iteration.
+ (lang_do_assignments_1): New function with former
+ lang_do_assignments contents. Change recursive calls to call this
+ function.
+ (lang_do_assignments): Evacuate contents. Increment
+ lang_statement_iteration, then just call lang_do_assignments_1.
+ * ldlang.h (struct lang_definedness_hash_entry)
+ (lang_statement_iteration, lang_track_definedness)
+ (lang_symbol_definition_iteration, lang_update_definedness):
+ Declare.
+
+2003-10-09 H.J. Lu <hongjiu.lu@intel.com>
+
+ * scripttempl/elf.sc (__executable_start): Provide.
+
+2003-10-09 Daniel Jacobowitz <drow@mvista.com>
+
+ * emulparams/armelf.sh: Define NO_SMALL_DATA.
+ * emulparams/armelf_linux.sh, emulparams/armelf_oabi.sh,
+ emulparams/armnto.sh: Likewise.
+
+2003-10-08 Alexandre Oliva <aoliva@redhat.com>
+
+ * ldlang.c (lang_size_sections_1): Use IGNORE_SECTION to tell
+ whether to skip test for no memory region.
+
+2003-10-08 Nick Clifton <nickc@redhat.com>
+
+ * lexsup.c (parse_args: OPTION_CALL_SHARED): Revise comment
+ describing defaults. Change default to report unresolved symbols
+ in object files as well.
+
+2003-10-08 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * ldexp.c (fold_name) <case DEFINED>: Set section of result to
+ abs_output_section.
+
+2003-10-07 Bob Wilson <bob.wilson@acm.org>
+
+ * emulparams/elf32xtensa.sh (OTHER_READONLY_SECTIONS,
+ OTHER_READWRITE_SECTIONS, OTHER_SECTIONS): Set section addresses to
+ zero for relocatable links.
+
+2003-10-07 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
+
+ * configure.host (HOSTING_LIBS): Define for hppa*-*-linux*.
+
+2003-10-07 Nathan Sidwell <nathan@codesourcery.com>
+
+ * ldwrite.c (unsplittable_name): New.
+ (clone_section): Strip existing numeric suffix. Only truncate names
+ for coff targets.
+ (split_sections): Use unsplittable_name.
+
+2003-10-06 Nick Clifton <nickc@redhat.com>
+
+ * lexsup.c (parse_args): Report unresolved symbols in shared
+ libraries when creating a dynamic executable. This is a
+ restoration of the default behaviour for previous versions of
+ the linker.
+
+2003-10-06 Matt Thomas <matt@3am-software.com>
+
+ * emulparams/hppanbsd.sh: Remove OUTPUT_FORMAT.
+ * emulparams/hppaobsd.sh: Add OUTPUT_FORMAT="elf32-hppa".
+
+2003-10-06 Robert Millan <robertmh@gnu.org>
+
+ * configure.tgt: Match GNU/KNetBSD with new knetbsd*-gnu triplet.
+
+2003-10-02 Ivan Warren <ivan@vmfacility.fr>
+
+ * pe-dll.c (make_one): Correct sym def order & pick right sym for
+ .idata$7 reloc.
+
+2003-09-30 Chris Demetriou <cgd@broadcom.com>
+
+ * NEWS: Add an indication of the cutoff for 2.14.
+
+2003-09-30 Chris Demetriou <cgd@broadcom.com>
+
+ * ldmain.c (get_emulation): Ignore "-mips64r2".
+
+2003-09-03 Robert Millan <robertmh@gnu.org>
+
+ * configure.host: Match GNU/KFreeBSD with new kfreebsd*-gnu
+ triplet.
+ * configure.tgt: Likewise.
+
+2003-08-29 Jafa <jafa@silicondust.com>
+
+ * emulparams/elf32ip2k.sh (TEMPLATE_NAME): Define.
+
+2003-08-21 Nick Clifton <nickc@redhat.com>
+
+ * po/tr.po: Updated Turkish translation.
+
+2003-08-20 Nick Clifton <nickc@redhat.com>
+
+ * ldmain.c: Initialise the new fields in bfd_link_info to
+ NOT_YET_SET.
+ * lexsup.c (enum option_values): New enum. Use this to
+ replace the hand coded values for the long switch options.
+ (ld_options): Add 'unresolved-symbols',
+ 'warn-unresolved-symbols' and 'error-unresolved-symbols'.
+ (parse_args): Handle the new switches. Set the values of
+ unresolved_symbols_in_objects and
+ unresolved_symbols_in_shared_libs appropriately. If they were
+ not initialised by the command line, install default values.
+ * emultempl/elf32.em (handle_option): Update OPTION_GROUP and
+ -z defs to use the new fields in bfd_link_info.
+ * ld.texinfo: Document the new switches.
+ * NEWS: Mention this feature.
+
+2003-08-15 Dmitry Diky <diwil@mail.ru>
+
+ * Makefile.am (GENSCRIPTS_EXTRA): New script definition which
+ calls genscripts_extra.sh.
+ Rearrange all msp430 depends using this script.
+ * Makefile.in: Regenerate.
+ * genscripts_extra.sh: New file: Similar to genscripts.sh, except
+ that the script to be run to generate the emulations can be passed
+ as an optional parameter instead of being computed from the
+ emulation name.
+ * emulparams/msp430all.sh: New file: Combine all msp430 subdevice
+ definitions into one file.
+ * emulparams/msp430x*.sh: Removed.
+
+2003-08-15 Nick Clifton <nickc@redhat.com>
+
+ * ld.texinfo (Options): Put keywords for the -z option into a
+ table. Add more text describing what the -z now option does.
+
+2003-08-14 Alan Modra <amodra@bigpond.net.au>
+
+ * dep-in.sed: Remove libintl.h.
+ * Makefile.am (POTFILES.in): Unset LC_COLLATE.
+ * Makefile.in: Regenerate.
+
+2003-08-13 Alan Modra <amodra@bigpond.net.au>
+
+ * genscripts.sh (libpath.exp): Only generate for first emulation.
+ (LIB_PATH): Correct order of paths. Don't add $tool_lib when
+ already present or when LIB_PATH is set to ":".
+
+2003-08-12 Ian Lance Taylor <ian@airs.com>
+
+ * ldmain.c (undefined_symbol): Change parameter name from `fatal'
+ to `error'. If only a warning, put warning in the reported
+ string. Consistently set failure flag when not a warning.
+
+2003-08-08 Dmitry Diky <diwil@mail.ru>
+
+ * Makefile.am: Add xW42 and xE42 parts. Sort MPU list according to
+ gcc order.
+ * Makefile.in: Regenerate.
+ * configure.tgt: Add extra emulations.
+ * emulparams/msp430xE423.sh: New file.
+ * emulparams/msp430xE427.sh: New file.
+ * emulparams/msp430xW425.sh: New file.
+ * emulparams/msp430xE425.sh: New file.
+ * emulparams/msp430xW423.sh: New file.
+ * emulparams/msp430xW427.sh: New file.
+
+2003-08-07 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * emultempl/pe.em (gld_${EMULATION_NAME}_before_parse):
+ Change second (cmdline) arg to lang_add_entry to FALSE.
+ (set_pe_subsystem): Change second arg to lang_add_entry to TRUE.
+
+2003-08-05 Christian Groessler <chris@groessler.org>
+ Jason Eckhardt <jle@rice.edu>
+
+ * configure.tgt: Recognize new target i860-*-coff.
+ * Makefile.am (ALL_EMULATIONS): Add ecoff_i860.o.
+ (ecoff_i860.c): New rule.
+ * emulparams/coff_i860.sh: New file.
+ * scripttempl/i860coff.sc: New file.
+ * Makefile.in: Regenerate.
+
+2003-08-04 Nick Clifton <nickc@redhat.com>
+
+ * emultempl/elf32.em (before_allocation): Prepend "warning: "
+ to messages produced for .gnu.warning.SYMBOL sections.
+
+2003-08-04 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/elf32.em (output_rel_find): Add "isdyn" param. Put
+ .rel.dyn before other reloc sections. Don't stop looking for reloc
+ sections on finding one that isn't allocated. Match .rel even when
+ placing .rela and vice versa, when setting last_rel and
+ last_rel_alloc for the first time. If no reloc sections in script,
+ prefer allocated section over non-alloc.
+ (gld${EMULATION_NAME}_place_orphan): Handle orphan .rel.dyn.
+
+2003-07-29 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * emulparams/shelf.sh (OTHER_SECTIONS): Don't include .stack
+ section for shared library.
+ * emulparams/shelf32.sh (OTHER_SECTIONS): Likewise.
+ * emulparams/shelf64.sh (OTHER_SECTIONS): Likewise.
+
+2003-07-29 Stephane Carrez <stcarrez@nerim.fr>
+
+ * scripttempl/elfm68hc12.sc: Add gcc_except_table.
+ * scripttempl/elfm68hc11.sc: Likewise.
+
+2003-07-28 Alan Modra <amodra@bigpond.net.au>
+
+ * emulparams/elf64ppc.sh (GOT): Fix for shell brace matching.
+
+ * emulparams/elf64ppc.sh (GOT): Don't merge .toc into .got for ld -r.
+
+2003-07-27 Alan Modra <amodra@bigpond.net.au>
+
+ * ld.texinfo: Typo fixes. Document SUBALIGN.
+ * ldgram.y (opt_subalign): Add.
+ * ldlex.l (SUBALIGN): Recognize.
+ * ldlang.c (overlay_subalign): New var.
+ (lang_enter_overlay): Add subalign param.
+ (lang_enter_overlay_section): Pass overlay_subalign to
+ lang_enter_output_section_statement.
+ * ldlang.h (lang_enter_overlay): Update.
+
+2003-07-24 Nick Clifton <nickc@redhat.com>
+
+ * po/fr.po: Updated French translation.
+
+2003-07-23 Stephane Carrez <stcarrez@nerim.fr>
+
+ * scripttempl/elfm68hc11.sc: Keep ctor/dtor sections; Take into
+ account .tramp sections;
+ * scripttempl/elfm68hc12.sc: Likewise.
+
+2003-07-17 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * ld/pe-dll.c: Add libcygwin to autofilter_liblist[]
+
+2003-07-17 Nick Clifton <nickc@redhat.com>
+
+ * po/es.po: New Spanish translation.
+
+2003-07-11 Alan Modra <amodra@bigpond.net.au>
+
+ * po/ld.pot: Regenerate.
+
+2003-07-10 Bob Wilson <bob.wilson@acm.org>
+
+ * emulparams/elf32xtensa.sh (OTHER_READONLY_SECTIONS): Replace .xt.lit
+ with new .got.loc section.
+ (OTHER_READWRITE_SECTIONS): Do not combine linkonce sections for
+ non-relocating links.
+ (OTHER_SECTIONS): Add .xt.lit here. Change it to keep linkonce
+ sections separate for non-relocating links; likewise for .xt.insn.
+
+2003-07-10 Alexandre Oliva <aoliva@redhat.com>
+
+ 2001-08-22 Alexandre Oliva <aoliva@redhat.com>
+ * emulparams/elf32am33lin.sh: Adjust to match kernel parameters.
+ 2001-05-09 Alexandre Oliva <aoliva@redhat.com>
+ * configure.host (am33_2.0-*-linux*): Added.
+ * configure.tgt (am33_2.0-*-linux*): Likewise.
+ * emulparams/elf32am33lin.sh: New.
+ * Makefile.am (eelf32am33lin.c): New rule.
+ * Makefile.in: Rebuilt.
+
+2003-07-09 Alexandre Oliva <aoliva@redhat.com>
+
+ 2001-04-17 Alexandre Oliva <aoliva@redhat.com>
+ * emulparams/mn10300.sh (TEMPLATE_NAME): Define.
+ (GENERATE_SHLIB_SCRIPT): Likewise.
+
+2003-07-10 Alan Modra <amodra@bigpond.net.au>
+
+ * emulparams/elf64ppc.sh (OTHER_GOT_SECTIONS): Don't define.
+ (GOT): Define.
+ * emultempl/ppc64elf.em (stub_added): New static var.
+ (ppc_create_output_section_statements): Call ppc64_elf_init_stub_bfd.
+ (ppc_add_stub_section): Set stub_added.
+ (gld${EMULATION_NAME}_finish): Look for .got rather than .toc. Adjust
+ ppc64_elf_size_stubs call and test for stubs.
+ * scripttempl/elf.sc (GOT): Define and use.
+
+2003-07-08 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * emultempl/sh64elf.em (sh64_elf_${EMULATION_NAME}_after_allocation):
+ Allow second call from ldemul_finish.
+
+2003-07-04 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * emulparams/shelf32.sh (STACK_ADDR): Don't define.
+ (OTHER_SECTIONS): Include .stack.
+ * emulparams/shelf64.sh (OTHER_SECTIONS): Likewise.
+
+2003-07-02 Jakub Jelinek <jakub@redhat.com>
+
+ * emulparams/elf64_ia64.sh (OTHER_READONLY_SECTIONS): Don't include
+ .opd if -pie.
+ (OTHER_READWRITE_SECTIONS): Include .opd if -pie.
+ * scripttempl/elf.sc: Use SHLIB_DATA_ADDR instead of DATA_ADDR
+ if -pie.
+
+2003-06-28 Alan Modra <amodra@bigpond.net.au>
+
+ * ld.h: Convert to C90, remove unnecessary prototypes and casts.
+ Replace PTR with void *. Formatting.
+ * ldcref.c: Likewise.
+ * ldctor.c: Likewise.
+ * ldctor.h: Likewise.
+ * ldemul.h: Likewise.
+ * ldexp.c: Likewise.
+ * ldexp.h: Likewise.
+ * ldfile.c: Likewise.
+ * ldfile.h: Likewise.
+ * ldlang.c: Likewise.
+ * ldlang.h: Likewise.
+ * ldlex.h: Likewise.
+ * ldlex.l: Likewise.
+ * ldmain.c: Likewise.
+ * ldmain.h: Likewise.
+ * ldmisc.c: Likewise.
+ * ldmisc.h: Likewise.
+ * ldver.h: Likewise.
+ * ldwrite.c: Likewise.
+ * ldwrite.h: Likewise.
+ * lexsup.c: Likewise.
+ * mri.c: Likewise.
+ * mri.h: Likewise.
+ * pe-dll.c: Likewise.
+ * pe-dll.h: Likewise.
+ * deffilep.y: Likewise.
+ * deffile.h: Likewise. Don't include ansidecl.h.
+ * emulparams/elf32mcore.sh: Remove unnecessary cast.
+ * emultempl/m68kcoff.em: Likewise.
+ * emultempl/m68kelf.em: Likewise.
+ * emultempl/ticoff.em: Remove lang_add_output_format declaration.
+ * sysdep.h: Don't include ansidecl.h.
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2003-06-27 Nick Clifton <nickc@redhat.com>
+
+ * deffilep.y (def_file_add_directive): Cope with NUL seperated
+ directives. Fix reporting of unparseable directives.
+ (def_error): Check for a NULL def_filename.
+
+2003-06-27 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/aix.em: Convert to C90, remove unnecessary prototypes
+ and casts. Replace PTR with void *. Formatting.
+ * emultempl/alphaelf.em: Likewise.
+ * emultempl/armcoff.em: Likewise.
+ * emultempl/armelf.em: Likewise.
+ * emultempl/armelf_oabi.em: Likewise.
+ * emultempl/beos.em: Likewise.
+ * emultempl/elf32.em: Likewise.
+ * emultempl/generic.em: Likewise.
+ * emultempl/gld960.em: Likewise.
+ * emultempl/gld960c.em: Likewise.
+ * emultempl/hppaelf.em: Likewise.
+ * emultempl/linux.em: Likewise.
+ * emultempl/lnk960.em: Likewise.
+ * emultempl/m68hc1xelf.em: Likewise.
+ * emultempl/m68kcoff.em: Likewise.
+ * emultempl/m68kelf.em: Likewise.
+ * emultempl/mipsecoff.em: Likewise.
+ * emultempl/mipself.em: Likewise.
+ * emultempl/mmix-elfnmmo.em: Likewise.
+ * emultempl/mmixelf.em: Likewise.
+ * emultempl/mmo.em: Likewise.
+ * emultempl/needrelax.em: Likewise.
+ * emultempl/netbsd.em: Likewise.
+ * emultempl/pe.em: Likewise.
+ * emultempl/sh64elf.em: Likewise.
+ * emultempl/sunos.em: Likewise.
+ * emultempl/ticoff.em: Likewise.
+ * emultempl/vanilla.em: Likewise.
+ * emultempl/xtensaelf.em: Likewise.
+ * Makefile.am: Correct dependencies.
+ * Makefile.in: Regenerate.
+
+2003-06-25 Alan Modra <amodra@bigpond.net.au>
+
+ * ld.texinfo: Correct spelling of "relocatable".
+ * ldctor.c: Likewise.
+ * ldexp.c: Likewise.
+ * ldfile.c: Likewise.
+ * ldint.texinfo: Likewise.
+ * ldlang.c: Likewise.
+ * ldmain.c: Likewise.
+ * ldwrite.c: Likewise.
+ * lexsup.c: Likewise.
+ * emultempl/aix.em: Likewise.
+ * emultempl/alphaelf.em: Likewise.
+ * emultempl/armcoff.em: Likewise.
+ * emultempl/armelf_oabi.em: Likewise.
+ * emultempl/beos.em: Likewise.
+ * emultempl/elf32.em: Likewise.
+ * emultempl/generic.em: Likewise.
+ * emultempl/gld960.em: Likewise.
+ * emultempl/gld960c.em: Likewise.
+ * emultempl/hppaelf.em: Likewise.
+ * emultempl/linux.em: Likewise.
+ * emultempl/lnk960.em: Likewise.
+ * emultempl/m68hc1xelf.em: Likewise.
+ * emultempl/m68kcoff.em: Likewise.
+ * emultempl/m68kelf.em: Likewise.
+ * emultempl/mipsecoff.em: Likewise.
+ * emultempl/mipself.em: Likewise.
+ * emultempl/mmix-elfnmmo.em: Likewise.
+ * emultempl/mmo.em: Likewise.
+ * emultempl/needrelax.em: Likewise.
+ * emultempl/pe.em: Likewise.
+ * emultempl/ppc64elf.em: Likewise.
+ * emultempl/sh64elf.em: Likewise.
+ * emultempl/sunos.em: Likewise.
+ * emultempl/ticoff.em: Likewise.
+ * emultempl/xtensaelf.em: Likewise.
+
+2003-06-24 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/ppc32elf.em: Convert to C90.
+
+2003-06-20 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/ppc64elf.em: Convert to C90 function definitions, remove
+ unnecessary prototypes and casts.
+
+2003-06-19 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/ppc64elf.em (gld${EMULATION_NAME}_finish): Dump out
+ statistics from ppc64_elf_build_stubs.
+
+2003-06-19 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/ppc64elf.em (build_section_lists): Check return status
+ from ppc64_elf_next_input_section.
+
+2003-06-17 H.J. Lu <hongjiu.lu@intel.com>
+
+ * ldlang.c (section_already_linked): Put back assignment of
+ kept_section.
+
+2003-06-17 Rainer Keuchel <rkeuchel@allgeier.com>
+
+ * pe-dll.c (generate_reloc): Catch and ignore an ARM_26D
+ reloc.
+
+2003-06-17 Loren James Rittle <rittle@latour.rsch.comm.mot.com>
+
+ * configure.host (*-*-freebsd*): Add known path for ld-elf.so.1
+ if not produced by gcc.
+
+2003-06-16 Hans-Peter Nilsson <hp@axis.com>
+
+ * configure.tgt: Add specific case for cris-*-linux-gnu*
+ with crislinux emulation only.
+
+2003-06-13 Robert Millan <zeratul2@wanadoo.es>
+
+ * configure.tgt: Add i386-netbsd-gnu target.
+
+2003-06-12 Richard Sandiford <rsandifo@redhat.com>
+
+ * configure.tgt (mips*-sgi-irix6*): Add the o32 and n64 emulations
+ to $targ_extra_libpath.
+
+2003-06-11 H.J. Lu <hongjiu.lu@intel.com>
+
+ * po/Make-in (DESTDIR): New.
+ (install-data-yes): Support $(DESTDIR).
+ (uninstall): Likewise.
+
+2003-06-10 Doug Evans <dje@sebabeach.org>
+
+ * Makefile.am (ALL_EMULATIONS): Add em32relf.o.
+ * Makefile.in: Regenerate.
+
+2003-06-10 Richard Sandiford <rsandifo@redhat.com>
+
+ * configure.tgt (h8300*): Add h8300sxn emulations.
+ * Makefile.am (ALL_EMULATIONS): Add eh8300sxn.o and eh8300sxnelf.o.
+ (eh8300sxn.c, eh8300sxnelf.c): New rules.
+ * Makefile.in: Regenerate.
+ * emulparams/h8300sxnelf.sh, emulparams/h8300sxn.sh: New files.
+ * scripttempl/h8300sxn.sc: New file.
+
+2003-06-10 Alan Modra <amodra@bigpond.net.au>
+
+ * emulparams/elf64ppc.sh (EXECUTABLE_SYMBOLS, OTHER_BSS_END_SYMBOLS,
+ CTOR_START, CTOR_END, DTOR_START, DTOR_END): Don't define.
+
+2003-06-08 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/ppc64elf.em (emit_stub_syms, toc_section): New vars.
+ (build_toc_list): New function.
+ (gld${EMULATION_NAME}_finish): Call build_toc_list and
+ ppc64_elf_reinit_toc. Adjust ppc64_elf_build_stubs call.
+ (OPTION_STUBSYMS): Define.
+ (PARSE_AND_LIST_LONGOPTS): Add emit-stub-syms.
+ (PARSE_AND_LIST_OPTIONS): Document.
+ (PARSE_AND_LIST_ARGS_CASES): Handle.
+
+2003-06-05 Roland McGrath <roland@redhat.com>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_list_options): Remove
+ extra \t in -z noexecstack line.
+
+2003-05-23 Jakub Jelinek <jakub@redhat.com>
+
+ * ldgram.y (phdr_type): Grok PT_GNU_STACK.
+ * emultempl/elf32.em (gld${EMULATION_NAME}_handle_option): Add
+ -z execstack and -z noexecstack.
+ (gld${EMULATION_NAME}_list_options): Likewise.
+ * scripttempl/elf.sc: If not -r, discard .note.GNU-stack section.
+
+2003-06-03 Michael Snyder <msnyder@redhat.com>
+ and Bernd Schmidt <bernds@redhat.com>
+ and Alexandre Oliva <aoliva@redhat.com>
+
+ * Makefile.am: Add new emulations for h8300sx.
+ * Makefile.in: Regenerate.
+ * configure.tgt: Add new emulations.
+ * emulparams/h8300sx.sh: New emulation.
+ * emulparams/h8300sxelf.sh: Ditto.
+ * scripttempl/h8300sx.sc: Ditto.
+
+2003-06-03 H.J. Lu <hongjiu.lu@intel.com>
+
+ * ldmisc.c: Include "bfdlink.h".
+ (error_handler): Handle LD_DEFINITION_IN_DISCARDED_SECTION
+ and -LD_DEFINITION_IN_DISCARDED_SECTION.
+
+ * Makefile.am: Rebuild dependency.
+ * Makefile.in: Regenerated.
+
+2003-06-03 Kaz Kojima <kkojima@rr.iij4u.or.jp>
+
+ * emulparams/shlelf_linux.sh (GENERATE_PIE_SCRIPT): Set to yes.
+ * emulparams/shlelf32_linux.sh (GENERATE_PIE_SCRIPT): Likewize.
+
+2003-06-02 Fabrizio Gennari <fabrizio.ge@tiscalinet.it>
+
+ * pe-dll.c (fill_edata): Scan table pe_dll->exports, which is
+ sorted alphabetically, instead of exported_symbols, which is
+ sorted by ordinal.
+
+2003-05-30 Ulrich Drepper <drepper@redhat.com>
+ Jakub Jelinek <jakub@redhat.com>
+
+ * lexsup.c (OPTION_PIE): Define.
+ (ld_options): Add -pie and --pic-executable options.
+ (parse_args): Handle OPTION_PIE.
+ * ldmain.c (main): Initialize link_info.pie and
+ link_info.executable.
+ * genscripts.sh: Generate PIE scripts.
+ * ld.texinfo: Document -pie and --pic-executable options.
+ * emultempl/elf32.em (gld${EMULATION_NAME}_after_open):
+ (gld${EMULATION_NAME}_place_orphan): Likewise.
+ (gld${EMULATION_NAME}_get_script): Include PIE scripts.
+ * scripttempl/elf.sc: In PIE scripts set . the same way as in
+ shared scripts.
+ * emulparams/elf_i386.sh (GENERATE_PIE_SCRIPT): Set to yes.
+ * emulparams/elf64_ia64.sh (GENERATE_PIE_SCRIPT): Likewise.
+ * emulparams/elf32ppc.sh (GENERATE_PIE_SCRIPT): Likewise.
+ * emulparams/elf64ppc.sh (GENERATE_PIE_SCRIPT): Likewise.
+ * emulparams/elf_x86_64.sh (GENERATE_PIE_SCRIPT): Likewise.
+ * emulparams/elf_s390.sh (GENERATE_PIE_SCRIPT): Likewise.
+ * emulparams/elf32_sparc.sh (GENERATE_PIE_SCRIPT): Likewise.
+ * emulparams/elf64_sparc.sh (GENERATE_PIE_SCRIPT): Likewise.
+ * emulparams/elf64alpha.sh (GENERATE_PIE_SCRIPT): Likewise.
+ * emulparams/elf64_s390.sh (GENERATE_PIE_SCRIPT): Likewise.
+ * emulparams/elf_i386.sh (GENERATE_PIE_SCRIPT): Likewise.
+
+2003-05-30 H.J. Lu <hongjiu.lu@intel.com>
+
+ * genscripts.sh: Create tmpdir/libpath.exp.
+
+2003-05-30 Nick Clifton <nickc@redhat.com>
+
+ * emultempl/armelf.em (arm_elf_before_allocation): Replace ASSERT
+ with a test for a NULL bfd_for_interworking.
+
+2003-05-29 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * configure.host (*-*-netbsd*): Set HOSTING_CRT0 and HOSTING_LIBS
+ correctly for more recent versions of NetBSD.
+ (alpha*-*-netbsd*): Remove.
+ (i[3-7]86-*-netbsd*): Remove.
+
+2003-05-29 Nick Clifton <nickc@redhat.com>
+
+ * emultempl/pe.em: Include "safe-ctype.h" instead of <ctype.h>.
+
+2003-05-26 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * emulparams/elf64btsmip.sh: Set TEXT_START_ADDR to 0x120000000 to
+ trap on pointer crops.
+
+2003-05-21 Marcus Comstedt <marcus@mc.pp.se>
+
+ * configure.tgt: Check for a target triplet of shl-...-netbsdelf
+ as well as shle-...-netbsdelf.
+
+2003-05-16 Kelley Cook <kelleycook@wideopenwest.com>
+
+ * configure.host: Accept i[3-7]86 variants.
+ * configure.tgt: Likewise.
+
+2003-05-15 H.J. Lu <hongjiu.lu@intel.com>
+
+ * emulparams/elf64_ia64.sh: Don't set COMMONPAGESIZE for now.
+
+2003-05-09 Daniel Jacobowitz <drow@mvista.com>
+
+ * Makefile.am (ALL_EMULATIONS): Add earmelfb.o and earmelfb_linux.o.
+ (earmelfb.c, earmelfb_linux.c): New rules.
+ * Makefile.in: Regenerated.
+ * emulparams/armelfb.sh, emulparams/armelfb_linux.sh: New files.
+ * configure.tgt: Add armeb-elf and arm*b-*-linux-gnu.
+
+2003-05-09 Nick Clifton <nickc@redhat.com>
+
+ * ldlang.c (lang_size_sections_1): Default to generating a
+ fatal error message if a loadable section is not allocated
+ to a memory region when regions are defined.
+
+2003-05-09 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (em68hc11elf.c): Correct dependencies.
+ (em68hc11elfb.c, em68hc12elf.c, em68hc12elfb.c): Likewise.
+ * Makefile.in: Regenerate.
+ * emultempl/elf32.em (find_exp_assignment): Adjust for changed
+ bfd_elf_record_link_assignment name.
+
+2003-05-07 Alexandre Oliva <aoliva@redhat.com>
+
+ * ldmain.h (overflow_cutoff_limit): Declare.
+ * ldmain.c (overflow_cutoff_limit): Define, initialized to 10.
+ (reloc_overflow): Limit error messages based on it.
+ * lexsup.c (parse_args) <OPTION_VERBOSE>: Set cutoff to
+ unlimited.
+
+2003-05-05 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlex.l: Accept C style comments in version scripts.
+
+2003-04-28 H.J. Lu <hjl@gnu.org>
+
+ * ldlang.c (lang_process): Add the relax finalize pass.
+
+ * ldmain.c (main): Initialize link_info.relax_finalizing to
+ FALSE.
+
+2003-04-24 Roland McGrath <roland@redhat.com>
+
+ * ldgram.y (phdr_type): Grok PT_TLS and PT_GNU_EH_FRAME names.
+ If a name string is unknown, give an error rather than crashing later.
+
+2003-04-23 Dhananjay Deshpande <dhananjayd@kpitcummins.com>
+
+ * Makefile.am (ALL_EMULATIONS): Add eh8300hn.o, eh8300sn.o,
+ eh8300hnelf.o, eh8300snelf.o and respective rules.
+ * Makefile.in: Regenerate.
+ * configure.tgt: Add h8300hn, h8300sn, h8300hnelf, h8300snelf
+ * emulparams/h8300hn.sh: New
+ * emulparams/h8300sn.sh: New
+ * emulparams/h8300hnelf.sh: New
+ * emulparams/h8300snelf.sh: New
+ * scripttempl/h8300hn.sc: new
+ * scripttempl/h8300sn.sc: new
+
+2003-04-23 H.J. Lu <hjl@gnu.org>
+
+ * ldmain.c (link_callbacks): Initialize error_handler.
+
+ * ldmisc.c (error_handler): New function.
+
+ * ldmisc.h (error_handler): New prototype.
+
+2003-04-21 Stephane Carrez <stcarrez@nerim.fr>
+
+ * emulparams/m68hc11elf.sh: Use m68hc1xelf.em extra.
+ * emulparams/m68hc11elfb.sh: Likewise.
+ * emulparams/m68hc12elf.sh: Likewise.
+ * emulparams/m68hc12elfb.sh: Likewise.
+
+2003-04-19 Stephane Carrez <stcarrez@nerim.fr>
+
+ * emultempl/m68hc1xelf.em: New file to generate far trampolines on
+ 68HC11 and 68HC12.
+ (LDEMUL_BEFORE_ALLOCATION): Override to gather the trampolines to
+ generate.
+ (LDEMUL_FINISH): Override to generate the trampolines after gc and
+ linker relaxation.
+ (LDEMUL_CREATE_OUTPUT_SECTION_STATEMENTS): Override to create the
+ stub file for trampolines.
+ (PARSE_AND_LIST_OPTIONS, PARSE_AND_LIST_LONGOPTS): New options
+ --no-trampoline and --bank-window to control the memory bank window.
+
+2003-04-18 H.J. Lu <hjl@gnu.org>
+
+ * ldfile.c (ldfile_add_library_path): Remove the unused
+ variable.
+
+2003-04-18 Andrew Haley <aph@cambridge.redhat.com>
+
+ * scripttempl/xstormy16.sc (__data, __rdata): New.
+
+2003-04-16 Nick Clifton <nickc@redhat.com>
+
+ * scripttempl/xstormy16.sc: Add .jcr section mapping.
+
+2003-04-15 H.J. Lu <hjl@gnu.org>
+
+ From Debian by Jack Howarth <howarth@nitro.med.uc.edu>:
+
+ * ldlex.l: Use YY_CURRENT_BUFFER instead of yy_current_buffer.
+
+2003-04-15 Rohit Kumar Srivastava <rohits@kpitcummins.com>
+
+ * h8-doc.texi: Replace occurrances of 'Hitachi' with 'Renesas'.
+ * ld.texinfo: Likewise.
+
+2003-04-14 Alan Modra <amodra@bigpond.net.au>
+
+ From Prashanth Tamraparni <prashanth_t@in.ibm.com>
+ * scripttempl/elf.sc (CTOR): Handle crtbeginS.o, crtendS.o and
+ other variants of crtbegin.o, crtend.o.
+ (DTOR): Likewise.
+ * scripttempl/crisaout.sc (ctors, dtors): Likewise.
+ * scripttempl/elf_chaos.sc (CTOR, DTOR): Likewise.
+ * scripttempl/elfd10v.sc (CTOR, DTOR): Likewise.
+ * scripttempl/elfd30v.sc (CTOR, DTOR): Likewise.
+ * scripttempl/elfxtensa.sc (CTOR, DTOR): Likewise.
+ * scripttempl/iq2000.sc (CTOR, DTOR): Likewise.
+ * scripttempl/mmo.sc (ctors, dtors): Likewise.
+ * scripttempl/xstormy16.sc (CTOR, DTOR): Likewise.
+
+2003-04-09 Dmitry Diky <diwil@mail.ru>
+
+ * scripttempl/elf32msp430.sc: Add initX, finiX, ctors, dtors
+ sections to respect C++ constructor/destructor. Add ctors/dtors
+ start/stop definitions.
+ * scripttempl/elf32msp430_3.sc: Likewise.
+
+2003-04-06 Nick Clifton <nickc@redhat.com>
+
+ * ld.texinfo (Options): Add a reminder of the target specific
+ nature to the description of the i386 PE specific options, for
+ readers who have not read all the way through the manual.
+
+2003-04-04 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * configure.tgt: Fixed bug in list of targ_extra_emuls.
+ * emulparams/tic3xcoff.sh (SCRIPT_NAME): Namespace
+ cleanup. Replace s/c4x/tic4x and s/c3x/tic3x/
+ * emulparams/tic3xcoff_onchip.sh: Ditto
+ * emulparams/tic4xcoff.sh: Ditto
+ * scripttempl/tic4xcoff.sc: Ditto
+
+2003-04-03 Nick Clifton <nickc@redhat.com>
+
+ * NEWS: Mention support for Xtensa architecture.
+
+2003-04-02 Nick Clifton <nickc@redhat.com>
+
+ * pe-dll.c (pe_detail_list): arm-pe targets use underscores.
+
+2003-04-01 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * emultempl/pe.em (gld_${EMULATION_NAME}_after_open):
+ Don't call pe_dll_build_section() if link_info.relocateable.
+ (gld_${EMULATION_NAME}_finish): Don't call pe_dll_fill_sections()
+ if link_info.relocateable.
+
+2003-04-01 Fabrizio Gennari <fabrizio.ge@tiscalinet.it>
+
+ * pe-dll.c (process_def_file): Don't create an export
+ section if there are no exports and we're building an exe
+ (pe_dll_build_sections): Ditto
+ (pe_dll_fill_sections): Conditionalize setting
+ abfd->dll true on info->shared
+ * emultempl/pe.em (gld_${EMULATION_NAME}_after_open):
+ If i386pe or armpe, call pe_dll_build_section()
+ for both exe's and dll's, not just dll's.
+ (gld_${EMULATION_NAME}_finish): For all targets except
+ shpe and mipspe, call pe_dll_fill_sections() for both
+ exe's and dll's, not just dll's.
+
+2003-04-02 Bob Wilson <bob.wilson@acm.org>
+
+ * emulparams/xtensa-config.sh: Remove comment indicating that this is
+ a generated file.
+
+2003-04-01 Bob Wilson <bob.wilson@acm.org>
+
+ * Makefile.am (ALL_EMULATIONS): Add eelf32xtensa.o.
+ (eelf32xtensa.c): New target.
+ * Makefile.in: Regenerate.
+ * configure.tgt: Handle xtensa-*-*.
+ * gen-doc.texi: Set XTENSA variable.
+ * ld.texinfo: Set XTENSA variable. Add new Xtensa node.
+ * emulparams/elf32xtensa.sh: New file.
+ * emulparams/xtensa-config.sh: Likewise.
+ * emultempl/xtensaelf.em: Likewise.
+ * scripttempl/elfxtensa.sc: Likewise.
+
+2003-04-01 Jakub Jelinek <jakub@redhat.com>
+
+ * configure.tgt (powerpc*-*-linux*): Add elf32ppc to ppc64
+ targ_extra_libpath. Add elf64ppc to ppc targ_extra_libpath
+ if --enable-64-bit-bfd.
+
+2003-04-01 Nick Clifton <nickc@redhat.com>
+
+ * emulparams/armelf.sh (OTHER_READONLY_SECTIONS): Change name of
+ note section.
+ * emulparams/armelf_linux.sh (OTHER_READONLY_SECTIONS): Change
+ name of note section.
+
+2003-03-31 Alexandre Oliva <aoliva@redhat.com>
+
+ * ld.texinfo (-Tbss, -Tdata, -Ttext): Document in terms of
+ --section-start.
+
+2003-03-31 David Heine <dlheine@suif.stanford.edu>
+
+ * ldfile.c (ldfile_add_library_path): Always allocate space for
+ the filename.
+ * ldlang.c (lang_register_vers_node): Free the node if it cannot
+ be used.
+ * ldmain.c (set_scripts_dir): Always free the constructed
+ directory name.
+ (add_keepsyms_file): Fix memory leak.
+ * ldmisc.c (vfinfo): Likewise.
+ * lexsup.c (parse_args): Likewise.
+
+2003-03-25 Stan Cox <scox@redhat.com>
+ Nick Clifton <nickc@redhat.com>
+
+ Contribute support for Intel's iWMMXt chip - an ARM variant:
+
+ * emulparams/armelf.sh (OTHER_READONLY_SECTIONS): Define.
+ * emulparams/armelf_linux.sh (OTHER_READONLY_SECTIONS): Define.
+ * scripttempl/armcoff.sc (.data): Ensure 8 byte alignment.
+ (.bss): Likewise.
+
+2003-03-25 Alexandre Oliva <aoliva@redhat.com>
+
+ * ldmain.h (ld_canon_sysroot, ld_canon_sysroot_len): Declare.
+ * ldmain.c (ld_canon_sysroot, ld_canon_sysroot_len): Define.
+ (main): Initialize them.
+ * ldfile.c: Include pathnames.h.
+ (is_sysrooted_pathname): New.
+ (ldfile_add_library_path): Use it.
+ (ldfile_open_file_search): Likewise. Use IS_ABSOLUTE_PATH. Don't
+ search_dirs if given an absolute pathname.
+ (ldfile_open_file): Issue error message for sysrooted
+ absolute pathnames.
+ * Makefile.am: Updated dependencies.
+ * Makefile.in: Rebuild.
+
+2003-03-24 Daniel Néri <dne@mayonnaise.net>
+
+ * ld.texinfo: Rename all occurances of C54X to TIC54X.
+
+2003-03-19 Andreas Schwab <schwab@suse.de>
+
+ * ldfile.c (ldfile_try_open_bfd): Pop lexer start condition after
+ eof.
+
+2003-03-18 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * deffilep.y (opt_base): If no number given, set to default
+ (-1), not 0.
+
+2003-03-13 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * deffilep.y (def_import): Use default extension of "dll"
+ if no extension provided in parsed IMPORT definition.
+
+ * deffilep.y (def_lex): Revert 2003-03-12 change.
+ (dot_name): New id type and rule.
+ (expline): Use instead of ID.
+ (opt_equal_name): Likewise.
+
+2003-03-12 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * deffilep.y (def_lex): Accept '.' as valid non-lead char.
+
+2003-03-07 Christopher Faylor <cgf@redhat.com>
+
+ * configure.tgt: Add NATIVE_LIB_DIRS for cygwin target back after
+ apparent accidental removal on 2003-01-06.
+
+2003-03-04 Dmitry Diky <diwil@mail.ru>
+
+ * Makefile.am: Add new devices x1122 x1132 emulation
+ * configure.tgt: Likewise.
+ * Makefile.in: Regenerate.
+ * emulparams/msp430x1122.sh: New file.
+ * emulparams/msp430x1132.sh: New file.
+
+2003-03-03 Alexandre Oliva <aoliva@redhat.com>
+
+ * ldmain.c (set_scripts_dir): Look for relative to TOOLBINDIR as
+ well.
+
+ * ldfile.h (struct search_dirs): Added sysrooted field.
+ * ldlang.h (struct lang_input_statement_struct): Likewise.
+ * ldfile.c (ldfile_add_library_path): Mark sysrooted paths.
+ (ldfile_open_file_search): Look for sysrooted filename starting
+ with / in ld_sysroot instead of in the current directory. Clear
+ sysrooted flag if it's found in the current directory. Set it
+ from the search directory's sysrooted flag where it is found
+ otherwise.
+ * ldlang.c (ldlang_sysrooted_script): New static variable.
+ (new_afile): Mark search_file_enums as sysrooted if
+ ldlang_sysrooted_script.
+ (load_symbols): Set ldlang_sysrooted_script according to the
+ script's sysrooted field while processing it.
+ * ld.texinfo: Document INPUT behavior in sysroot.
+
+2003-03-02 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * scripttempl/pe.sc: Use PROVIDE with etext, end, _end,
+
+2003-03-03 Alan Modra <amodra@bigpond.net.au>
+
+ * emulparams/elf64alpha.sh (EXTRA_EM_FILE): Define.
+ (PARSE_AND_LIST_PROLOGUE, PARSE_AND_LIST_LONGOPTS,
+ PARSE_AND_LIST_OPTIONS, PARSE_AND_LIST_ARGS_CASES,
+ PARSE_AND_LIST_EPILOGUE): Don't define.
+ * emultempl/alphaelf.em: New file.
+
+2003-03-01 Alan Modra <amodra@bigpond.net.au>
+
+ * ldemul.c: Include getopt.h.
+ * emultempl/elf32.em: Include getopt.h earlier.
+ * emultempl/ticoff.em: Likewise.
+
+2003-02-28 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_get_script): Add combreloc
+ support when scripts read from files.
+
+2003-02-28 Alan Modra <amodra@bigpond.net.au>
+
+ * ldemul.c (ldemul_parse_args): Return FALSE by default.
+ * ldemul.h (struct ld_emulation_xfer_struct): Update parse_args
+ comment.
+
+ * ldemul.c (ldemul_add_options, ldemul_handle_option): New functions.
+ (ldemul_parse_args): Return bfd_boolean. Formatting.
+ * ldemul.h (ldemul_add_options, ldemul_handle_option): Declare.
+ (ldemul_parse_args): Adjust.
+ (struct ld_emulation_xfer_struct): Add add_options and handle_option.
+ Return bfd_boolean from parse_args.
+ * lexsup.c (parse_args): Malloc shortopts, longopts and
+ really_longopts. Call ldemul_add_options and ldemul_handle_option.
+ * emultempl/aix.em (gld${EMULATION_NAME}_add_options): Split out from
+ gld${EMULATION_NAME}_parse_args.
+ (gld${EMULATION_NAME}_handle_option): Likewise.
+ (ld_${EMULATION_NAME}_emulation): Adjust initializer.
+ * emultempl/armcoff.em: As for aix.em, but remove parse_args.
+ * emultempl/beos.em: Likewise.
+ * emultempl/pe.em: Likewise.
+ * emultempl/ticoff.em: Likewise.
+ * emultempl/elf32.em: Likewise. Don't duplicate long options either.
+ (gld${EMULATION_NAME}_add_sysroot): Prototype.
+ * emultempl/armelf.em (PARSE_AND_LIST_LONGOPTS): Don't duplicate
+ options.
+ * emultempl/hppaelf.em (PARSE_AND_LIST_LONGOPTS): Likewise.
+ * emultempl/ppc32elf.em (PARSE_AND_LIST_LONGOPTS): Likewise.
+ * emultempl/ppc64elf.em (PARSE_AND_LIST_LONGOPTS): Likewise.
+ * emultempl/armelf_oabi.em (ld_${EMULATION_NAME}_emulation): Adjust
+ initializer.
+ * emultempl/generic.em: Likewise.
+ * emultempl/gld960.em: Likewise.
+ * emultempl/gld960c.em: Likewise.
+ * emultempl/linux.em: Likewise.
+ * emultempl/lnk960.em: Likewise.
+ * emultempl/m68kcoff.em: Likewise.
+ * emultempl/mipsecoff.em: Likewise.
+ * emultempl/sunos.em: Likewise.
+ * emultempl/vanilla.em: Likewise.
+ * emultempl/netbsd.em (gldnetbsd_before_parse): Prototype.
+
+2003-02-25 Alexandre Oliva <aoliva@redhat.com>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_add_sysroot): Fix
+ memory allocation error.
+
+ * Makefile.am (ldmain.o): Define TOOLBINDIR.
+ * Makefile.in: Rebuilt.
+ * ldmain.c (ld_sysroot): Try to set from TOOLBINDIR too.
+
+2003-02-21 Bob Wilson <bob.wilson@acm.org>
+
+ * ldlang.c (lang_size_sections_1): Add CHECK_REGIONS argument and only
+ call os_region_check when it is set.
+ (lang_size_sections): Add CHECK_REGIONS argument and pass it through to
+ lang_size_sections_1.
+ (lang_process): Change lang_size_sections calls to set CHECK_REGIONS
+ only for the last call, not on every relaxation iteration.
+ * ldlang.h (lang_size_sections): Update prototype.
+ * pe-dll.c (pe_dll_fill_sections): Set CHECK_REGIONS argument in calls
+ to lang_size_sections.
+ (pe_exe_fill_sections): Likewise.
+ * emultempl/elf32.em (gld${EMULATION_NAME}_finish): Likewise.
+ * emultempl/hppaelf.em (hppaelf_layout_sections_again): Likewise.
+ * emultempl/ppc64elf.em (ppc_before_allocation): Likewise.
+ (ppc_layout_sections_again): Likewise.
+
+2003-02-21 Bob Wilson <bob.wilson@acm.org>
+
+ * gen-doc.texi: Set ARM and HPPA variables.
+ * ld.texinfo: Fix typos and obvious texinfo mistakes. Make section
+ title capitalization more consistent. Add missing menu entries for
+ machine-specific sections and conditionalize them consistently.
+ Conditionalize text that is irrelevant when SingleFormat is set.
+ Add @group divisions to improve page breaks in long examples.
+ Use @iftex/@ifnottex instead of @iftex/@ifinfo so that HTML output
+ is correct. Remove "FIXME" comment about not using
+ @raisesections/@lowersections. Use @raisesections/@lowersections
+ consistently for machine-specific sections. Change to be more polite
+ about poor bug reports. Replace FDL appendix with include of fdl.texi.
+ Move WIN32 node to match its order in the menus.
+ * fdl.texi: New file.
+
+2003-02-20 Alexandre Oliva <aoliva@redhat.com>
+
+ * configure.in (TARGET_SYSTEM_ROOT): Set default to
+ ${exec_prefix}/${target_alias}/sys-root. Match explicit
+ '${exec_prefix}' (in addition to the expansion thereof) as
+ relocatable.
+ * configure: Rebuilt.
+
+2003-02-20 Phil Edwards <pme@gcc.gnu.org>
+
+ * ldgram.y (vers_defns): Also recurse with 'EXTERN NAME' patterns.
+
+2003-02-20 Harri Porten <porten@kde.org>
+
+ * ldgram.y (vers_defns): Allow optional trailing semicolon in
+ EXTERN NAME block;
+
+2003-02-18 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/ppc32elf.em: New file.
+ * emulparams/elf32ppc.sh (EXTRA_EM_FILE): Define.
+ * Makefile.am (eelf32lppc.c): Depend on emultempl/ppc32elf.em.
+ (eelf32lppcnto.c): Likewise.
+ (eelf32lppcsim.c): Likewise.
+ (eelf32ppcnto.c): Likewise.
+ (eelf32ppc.c): Likewise.
+ (eelf32ppc_fbsd.c): Likewise.
+ (eelf32ppcsim.c): Likewise.
+ (eelf32ppclinux.c): Likewise.
+ * Makefile.in: Regenerate.
+
+2003-02-18 Alan Modra <amodra@bigpond.net.au>
+
+ * ld.texinfo: Remove spaces between @samp and opening brace.
+
+2003-02-18 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/ppc64elf.em (ppc_create_output_section_statements): Check
+ hash creator.
+ (ppc_before_allocation): Don't do optimizations if wrong hash table.
+ (gld${EMULATION_NAME}_finish): Ditto.
+
+2003-02-17 Nick Clifton <nickc@redhat.com>
+
+ * ldmain.c (main) Default allow_shlib_undefined to true.
+ * lexsup.c (ld_options): Add --no-allow-shlib-undefined.
+ (parse_args): Parse the new switch.
+ * ld.texinfo: Document new switch and default behaviour of
+ allowing undefined symbols in shared libraries.
+
+2003-02-11 Dmitry Diky <diwil@mail.ru>
+
+ * scripttempl/elf32msp430.sc: Add new data anchors definitions.
+ * scripttempl/elf32msp430_3.sc: Likewise.
+
+2003-02-11 Uwe Stieber <uwe@wwws.de>
+
+ * configure.tgt: Add support for kaOS as cross build target
+ system.
+
+2003-02-10 John Daivid Anglin <dave.anglin@nrc-cnrc.gc.ca>
+
+ * hppaelf.em (group_size): Change default back to 1.
+
+2003-02-09 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/ppc64elf.em: Add "no-tls-optimize" option and support code.
+
+2003-02-07 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
+
+ * hppaelf.em (group_size): Change default to -1.
+
+2003-02-07 Nick Clifton <nickc@redhat.com>
+
+ * emultempl/armelf.em (PARSE_AND_LIST_SHORTOPTS): Remove 'n' short
+ opt.
+ (PARSE_AND_LIST_LONGOPTS): Add duplicate entry for
+ no-pipeline-knowledge. This will prevent the getopt package from
+ thinking that there are any shorter abbreviations for
+ --no-pipeline-knowledge.
+
+2003-02-07 Jakub Jelinek <jakub@redhat.com>
+
+ * genscripts.sh (LIB_PATH): Don't append LIBPATH_SUFFIX to paths
+ which already have it. Avoid duplicates.
+
+2003-02-06 Jakub Jelinek <jakub@redhat.com>
+
+ * emulparams/elf64_s390.sh (LIBPATH_SUFFIX): Set to 64.
+ * emulparams/elf_x86_64.sh (LIBPATH_SUFFIX): Likewise.
+ * emulparams/elf64_sparc.sh (LIBPATH_SUFFIX): Set instead of suffix.
+
+2003-02-05 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/ppc64elf.em (ppc_before_allocation): Size sections then
+ call ppc64_elf_tls_optimize.
+
+2003-02-03 Daniel Jacobowitz <drow@mvista.com>
+
+ * emultempl/elf32.em: Move gld${EMULATION_NAME}_add_sysroot
+ outside of GNU/Linux conditional.
+
+2003-01-28 Ralf Habacker <ralf.habacker@freenet.de>
+
+ * deffilep.y (def_get_module): New function: locate an already
+ added module.
+ * deffile.h (def_get_module): New prototype.
+ * pe-dll.c (pe_implied_import_dll): Add code to prevent importing
+ a dll multiple times.
+
+2003-01-23 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/sh64elf.em: Include elf32-sh64.h.
+ (sh64_elf_${EMULATION_NAME}_before_allocation): Adjust for changed
+ sh64_elf_section_data.
+ (sh64_elf_${EMULATION_NAME}_after_allocation): Likewise.
+
+2003-01-23 Wu Yongwei <adah@netstd.com>
+
+ * ld.texinfo: Remove an extra "i" in --dll-search-prefix.
+ * emultempl/pe.em (gld_${EMULATION_NAME}_list_options): Move a
+ cross-80th-column-margin "an" to the next line.
+
+2003-01-21 Nick Clifton <nickc@redhat.com>
+
+ * emulparams/tic3xcoff-onchip.sh: Rename to ...z
+ * emulparams/tic3xcoff_onchip.sh: ...this.
+ * Makefile.am (etic3xcoff_onchip.c): Fix name of generated C file.
+ * Makefile.in: Regenerate.
+
+2003-01-21 Fabio Alemagna <falemagn@aros.org>
+
+ * configure.tgt: Handle i[3456]86-*-aros*
+
+2003-01-19 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * Makefile.am: Added etic3xcoff.o and etic4xcoff_onchip.o
+ * Makefile.in: Regenerate
+ * configure.tgt: Added extra target emulations
+ * emulparams/tic3xcoff.sh: Remove old settings
+ * emulparams/tic4xcoff.sh: Ditto
+ * emulparams/tic3xcoff-onchip.sh: Added new
+ * scripttempl/tic4xcoff.sc: Revise and combine both c3x and c4x
+ * scripttempl/tic3xcoff.sc: Remove
+
+2003-01-17 Andreas Jaeger <aj@suse.de>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_add_sysroot): Do not
+ skip ':'.
+
+2003-01-16 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.in: Regenerate.
+
+2003-01-14 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * ld.texinfo (node WIN32): Some clarifications
+ and formatting fixups.
+
+2003-01-09 Chris Demetriou <cgd@broadcom.com>
+
+ * ldmain.c (get_emulation): Sort -mipsNN checks in the usual
+ order, and handle (ignore) -mips32r2.
+
+2003-01-09 Daniel Jacobowitz <drow@mvista.com>
+
+ * ldmain.c (main): Make sure ld_sysroot is initialized.
+
+2003-01-06 Daniel Jacobowitz <drow@mvista.com>
+
+ * Makefile.am (eelf32iq10.c): Fix tab/whitespace mixup.
+
+ * Makefile.am (ldmain.o): Add @TARGET_SYSTEM_ROOT_DEFINE@.
+ (GENSCRIPTS): Add @use_sysroot@.
+ * Makefile.in: Regenerated.
+ * configure.host: Move setting of NATIVE_LIB_DIRS to...
+ * configure.tgt: ... here. Use ${target} instead of ${host}
+ for NATIVE_LIB_DIRS.
+ * configure.in: Add --with-sysroot.
+ * configure: Regenerated.
+ * genscripts.sh: Accept use_sysroot option. Set new variables
+ NATIVE and USE_LIBPATH. Prepend "=" to directory names if
+ $use_sysroot. Don't search $tool_lib if $use_sysroot.
+ * ldfile.c (ldfile_add_library_path): Handle leading '='.
+ * ldmain.c (TARGET_SYSTEM_ROOT): Define if not defined.
+ (ld_sysroot): New variable.
+ (main): Initialize ld_sysroot.
+ * ldmain.h (ld_sysroot): New extern.
+ * emultempl/elf32.em: Use NATIVE and USE_LIBPATH instead of
+ searching $EMULATION_LIBPATH.
+ (gld${EMULATION_NAME}_add_sysroot): New function.
+ (gld${EMULATION_NAME}_check_ld_so_conf): Use it. Honor ld_sysroot.
+ (gld${EMULATION_NAME}_after_open): Likewise. Only search
+ environment variables if $NATIVE.
+ * ld.texinfo (Options): Mention "=" prefix in the description of -L.
+ * NEWS: Mention --with-sysroot.
+
+ * emulparams/elf32bmipn32-defs.sh: Set NATIVE and LIBPATH_SUFFIX
+ instead of setting LIB_PATH.
+ * emulparams/elf32ppc.sh: Likewise.
+ * emulparams/elf64_s390.sh: Likewise.
+ * emulparams/elf64_sparc.sh: Likewise.
+ * emulparams/elf64ppc.sh: Likewise.
+ * emulparams/elf_x86_64.sh: Likewise.
+
+ * emulparams/elf64_aix.sh: Add "=" prefixes to LIB_PATH.
+ * emulparams/elf64hppa.sh: Add "=" prefixes to LIB_PATH.
+
+2003-01-03 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * pe-dll.c (autofilter_symbollist): Add cygwin_crt0.
+
+2003-01-04 Daniel Jacobowitz <drow@mvista.com>
+
+ * Makefile.am (ldmain.o): Pass BINDIR.
+ * Makefile.in: Regenerated.
+ * ldmain.c (set_scripts_dir): Use make_relative_prefix for the first
+ search path.
+
+2003-01-02 Ben Elliston <bje@redhat.com>
+
+ * Makefile.am (ALL_EMULATIONS): Add eelf32iq2000.o.
+ (eelf32iq2000.c): New target.
+ * Makefile.in: Regenerate.
+ * configure.tgt: Handle iq2000-*-elf.
+ * emulparams/elf32iq10.sh: New file.
+ * emulparams/elf32iq2000.sh: New file.
+ * scripttempl/iq2000.sc: New file.
+
+2003-01-02 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * pe-dll.c (autofilter_symbollist): Add do_pseudo_reloc
+ and _pei386_runtime_relocator to the exclude list.
+
+2003-01-01 Kazu Hirata <kazu@cs.umass.edu>
+
+ * ldfile.c: Fix comment typos.
+ * ldlang.c: Likewise.
+ * mri.c: Likewise.
+ * pe-dll.c: Likewise.
+
+2003-01-01 Daniel Jacobowitz <drow@mvista.com>
+
+ Suggested by Manfred Hollstein <manfred.h@gmx.net>:
+ * Makefile.am (ld.1): Depend on configdoc.texi
+ and ldver.texi.
+ * Makefile.in: Regenerated.
+
+2002-12-24 Dmitry Diky <diwil@mail.ru>
+
+ * Makefile.am: Add msp430 target.
+ * configure.tgt: Likewise.
+ * Makefile.in: Regenerate.
+ * emulparams/msp430x???.sh: New files. Linker script parameters
+ for various msp430 configurations.
+ * gen-doc.texi: Enable msp430 documenation.
+ * ld.texinfo: Document msp430 sections.
+ * scripttempl/elf32msp430.sc: New file. Linker script for msp430.
+ * scripttempl/elf32msp430_3.sc: New file. Linker script for msp430.
+
+2002-12-30 Ralf Habacker <Ralf.Habacker@freenet.de>
+ Charles Wilson <cwilson@ece.gatech.edu>
+
+ * config.in (HAVE_REALPATH): New entry.
+ (HAVE_SYS_STAT_H, HAVE_SYS_TYPES_H): Removed: obsolete.
+
+2002-12-30 Ralf Habacker <ralf.habacker@freenet.de>
+
+ * ld.texinfo: New win32 topics: 'symbol aliasing' and 'export dll
+ symbols'.
+
+2002-12-23 Alan Modra <amodra@bigpond.net.au>
+
+ * ldmain.c (main): Init "strip_discarded".
+ * lexsup.c (OPTION_STRIP_DISCARDED): Define.
+ (OPTION_NO_STRIP_DISCARDED): Define.
+ (ld_options): Add "strip-discarded" and "no-strip-discarded".
+ (parse_args): Handle them.
+
+2002-12-23 Nick Clifton <nickc@redhat.com>
+
+ * ld.h (struct args_type): Add new field
+ 'accept_unknown_input_architecture'.
+ * ldmain.c (main): Initialise 'accept_unknown_input_architecture'
+ to false.
+ * ldlang.c (lang_check): Pass accept_unknown_input_architecture to
+ bfd_arch_get_compatible.
+ * ldfile.c (ldfile_try_open_bfd): Likewise.
+ * lexsup.c (ld_options): Add new command line switch
+ --accept-unknown-input-architecture and its inverse.
+ (parse_args): Handle --accept-unknown-input-architecture.
+ * ld.texinfo: Document new linker option.
+ * NEWS: Mention new linker option.
+
+2002-12-20 Alan Modra <amodra@bigpond.net.au>
+
+ * ldmain.c (main): Re-order link_info initialization. Init all
+ fields.
+
+2002-12-19 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * ld.texinfo: Clarify and extend the documentation
+ in the Machine Dependent, WIN32 section.
+
+2002-12-18 Ralf Habacker <ralf.habacker@freenet.de>
+
+ * ld.texinfo: Add win32 machine depending section.
+ * gen-doc.texi: Enable win32 machine depending section.
+
+ * configure.host: Add win32 library search path.
+
+2002-12-17 Ralf Habacker <ralf.habacker@freenet.de>
+
+ * emultempl/pe.em (pe_find_data_imports): Don't search for data
+ import when auto-import is disabled.
+
+2002-12-17 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * emultempl/pe.em (..._recognized_file): Use LD_PATHMAX+1 to
+ account for trailing '\0'.
+
+2002-12-17 Nick Clifton <nickc@redhat.com>
+
+ * emultempl/pe.em (longopts): Duplicate entry for --compact-implib
+ so that it is not confused with -c.
+
+2002-12-13 Ralf Habacker <Ralf.Habacker@freenet.de>
+ Charles Wilson <cwilson@ece.gatech.edu>
+
+ * configure.in: Add check for realpath function.
+ * configure: Regenerate.
+ * config.in: Regenerate.
+ * aclocal.m4: Regenerate.
+ * deffile.h: Add .data field to def_file_import
+ structure.
+ * pe-dll.c (pe_proces_import_defs): Use .data field of
+ def_file_import structure to initialize flag_data field of
+ def_file_export structure.
+ (pe_implied_import_dll): New variables exp_funcbase and
+ [data|bss]_[start|end]. Use DLL's internal name to set dll_name,
+ not filename (which may be a symlink). Scan the sections and
+ initialize [data|bss]_[start|end]. When scanning the export
+ table, skip _nm_ symbols, and mark any symbols whose rva indicates
+ that it is in the .bss or .data sections as data.
+ * sysdep.h: Include limits.h and sys/param.h, and define
+ LD_PATHMAX as appropriate. Also define REALPATH as realpath if it
+ exists, NULL otherwise.
+ * emultempl/pe.em (gld_${EMULATION_NAME}_after_open): Call
+ pe_process_import_defs before pe_find_data_imports, so that
+ auto-import will check the virtual implib as well as "real"
+ implibs.
+ (gld_${EMULATION_NAME}_recognized_file): Use REALPATH to follow
+ symlinks to their target; check that the target's extension is
+ .dll before calling pe_implied_import_dll(), not the filename
+ itself (which may be a symlink).
+
+2002-12-10 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/elf32.em (struct orphan_save): Add os_tail field.
+ (gld${EMULATION_NAME}_place_orphan): Re-order output_section_statement
+ list too.
+
+2002-12-08 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.h: Formatting.
+
+2002-12-07 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (init_os): Ensure sections mentioned in load_base
+ are initialized.
+
+2002-12-05 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Set
+ load_base for orphans that follow a section with load_base set.
+
+2002-12-01 H.J. Lu <hjl@gnu.org>
+
+ * ld.texinfo: Remove the extra `;' in sample version script.
+
+2002-11-30 Alan Modra <amodra@bigpond.net.au>
+
+ * configure.host: Correct dynamic-linker for powerpc64 hosts.
+
+ * Makefile.am (eelf32ppcwindiss.c): Correct dependencies.
+ * Makefile.in: Regenerate.
+
+ * ld.h, ldcref.c, ldctor.c, ldctor.h, ldemul.c, ldemul.h, ldexp.c,
+ ldexp.h, ldfile.c, ldfile.h, ldgram.y, ldlang.c, ldlang.h, ldmain.c,
+ ldmain.h, ldmisc.c, ldwrite.c, lexsup.c, mri.c, pe-dll.c, pe-dll.h,
+ emulparams/elf32b4300.sh, emultempl/aix.em, emultempl/armcoff.em,
+ emultempl/armelf.em, emultempl/armelf_oabi.em, emultempl/beos.em,
+ emultempl/elf32.em, emultempl/generic.em, emultempl/gld960.em,
+ emultempl/gld960c.em, emultempl/hppaelf.em, emultempl/linux.em,
+ emultempl/lnk960.em, emultempl/m68kcoff.em, emultempl/mipsecoff.em,
+ emultempl/mmix-elfnmmo.em, emultempl/mmixelf.em, emultempl/mmo.em,
+ emultempl/needrelax.em, emultempl/pe.em, emultempl/ppc64elf.em,
+ emultempl/sh64elf.em, emultempl/sunos.em, emultempl/ticoff.em: Replace
+ boolean with bfd_boolean, true with TRUE, false with FALSE. Simplify
+ comparisons of bfd_boolean vars with TRUE/FALSE. Formatting.
+
+2002-11-27 David O'Brien <obrien@FreeBSD.org>
+
+ * configure.host: Fix generic FreeBSD configuration entry.
+
+2002-11-27 H.J. Lu <hjl@gnu.org>
+
+ * ld.texinfo: Add the missing `;' to sample version scripts.
+
+2002-11-20 Alan Modra <amodra@bigpond.net.au>
+
+ * emulparams/elf64ppc.sh (SEGMENT_SIZE): Don't define.
+
+2002-11-14 Egor Duda <deo@logos-m.ru>
+
+ * ldmain.c (main): Make runtime relocs disabled by default. Remove
+ assignment which has no effect.
+ * pe-dll.h (pe_create_import_fixup): Change prototype.
+ * pe-dll.c (make_runtime_pseudo_reloc): New function.
+ (pe_create_runtime_relocator_reference): Ditto.
+ (pe_create_import_fixup): Handle relocations with non-zero addends.
+ * emultempl/pe.em: Add options --enable-runtime-pseudo-reloc and
+ --disable-runtime-pseudo-reloc.
+ (make_import_fixup): Handle relocations with non-zero addends. Create
+ an external reference to _pei386_runtime_relocator symbol if at least
+ one pseudo reloc was created.
+ * ld.texinfo: Document --enable-runtime-pseudo-reloc and
+ --disable-runtime-pseudo-reloc options.
+
+2002-11-12 Earl Chew <earl_chew@agilent.com>
+
+ * ldlang.c (lang_add_section): Discard debugging sections that have
+ been marked SEC_EXCLUDE.
+
+2002-11-12 Nick Clifton <nickc@redhat.com>
+
+ * configure.in (ALL_LINGUAS): Add da.
+ * configure: Regenerate.
+ * po/da.po: New Danish translation.
+
+2002-11-12 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/ppc64elf.em (ppc_before_allocation): New function.
+ (LDEMUL_BEFORE_ALLOCATION): Define.
+ (gld${EMULATION_NAME}_finish): Run discard_info for relocatable
+ linking.
+ * emultemp/hppaelf.em ((gld${EMULATION_NAME}_finish): Likewise.
+
+2002-11-11 Christopher Faylor <cgf@redhat.com>
+
+ * configure.tgt (LIB_PATH): Default to searching w32api directory under
+ cygwin.
+
+2002-11-11 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * pe-dll.c (autofilter_liblist): add libmingwex and libgcj to the list
+ of restricted auto-export libs.
+
+2002-11-11 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * pe-dll.c (autofilter_liblist): Generalize library names to catch more
+ creative library naming instances like, e.g., libstdc++-2.a.
+
+2002-11-06 Alexandre Oliva <aoliva@redhat.com>
+
+ * emulparams/elf32btsmipn32.sh (TEXT_DYNAMIC): Define.
+ * emulparams/elf64btsmip.sh (TEXT_DYNAMIC): Likewise.
+
+2002-11-07 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * deffilep.y (def_lex): Handle '@' as first character of an ID.
+ * pe-dll.c (auto-export): Filter on "_imp_" prefix, not "_imp__".
+ (make_one): Don't prefix decorated fastcall symbols with '_'.
+ (pe_process_import_defs): Likewise.
+ * emultempl/pe.em (pe_fixup_stdcalls): Don't fixup fastcall
+ symbols to cdecl names or vise-versa.
+
+2002-10-13 Eric Kohl <ekohl@rz-online.de>
+
+ * pe-dll.c (process_def_file): Handle fastcall symbols when
+ generating undecorated aliases. Don't prefix decorated fastcall
+ symbols with '_'.
+ (fill_exported_offsets): Don't prefix decorated fastcall symbols
+ with '_'.
+
+2002-10-29 Daniel Jacobowitz <drow@mvista.com>
+
+ * emultempl/aix.em: Use include <> for generated headers.
+ * emultempl/beos.em: Likewise.
+ * emultempl/elf32.em: Likewise.
+ * emultempl/pe.em: Likewise.
+ * ldctor.c: Likewise.
+ * ldexp.c: Likewise.
+ * ldfile.c: Likewise.
+ * ldlang.c: Likewise.
+ * ldlex.c: Likewise.
+ * ldlex.l: Likewise.
+ * ldmain.c: Likewise.
+ * ldmisc.c: Likewise.
+ * ldwrite.c: Likewise.
+ * lexsup.c: Likewise.
+ * mri.c: Likewise.
+ * pe-dll.c: Likewise.
+
+2002-10-23 Jakub Jelinek <jakub@redhat.com>
+
+ * emultempl/elf32.em (place_orphan): Don't put non-allocated .rel*
+ sections into .rel{,a}.dyn.
+
+2002-10-23 Nick Clifton <nickc@redhat.com>
+
+ * lexsup.c (OPTION_NO_OMAGIC): Define.
+ (ld_options): Add "no-omagic" option.
+ (parse_args): Parse --no-omagic.
+ * ld.texinfo: Document --no-omagic.
+ * NEWS: Mention new option.
+
+2002-10-21 Danny Smith <dannysmith@users.sourceforeg.net>
+
+ * scripttempl/pe.sc (__RUNTIME_PSEUDO_RELOC_LIST__,
+ __RUNTIME_PSEUDO_RELOC_LIST_END__): Add only when relocating.
+
+2002-10-22 Alexandre Oliva <aoliva@redhat.com>
+
+ * emulparams/elf32bmipn32-defs.sh: Set ELFSIZE according to
+ emulation name. Set LIB_PATH only for native tools, and
+ search the ABI-specific versions of NATIVE_LIB_DIRS before the
+ .../lib variants, not instead of them. Mostly copied from...
+ * emulparams/elf32ppc.sh: ... here. Fixed typo.
+ * emulparams/elf64bmip-defs.sh: Backed out.
+ * emulparams/elf64bmip.sh: Import elf32bmipn32-defs.sh again.
+ * emulparams/elf64btsmip.sh: Likewise.
+ (DATA_ADDR, NONPAGED_TEXT_START_ADDR, SHLIB_TEXT_START_ADDR,
+ TEXT_DYNAMIC): Removed.
+
+2002-10-17 Alexandre Oliva <aoliva@redhat.com>
+
+ * emulparams/elf32bmipn32-defs.sh (LIB_PATH): Set to /usr/lib32.
+ (GENERATE_SHLIB_SCRIPT): Set to yes.
+ (EXECUTABLE_SYMBOLS, WRITABLE_RODATA): Moved to...
+ * emulparams/elf32bmipn32.sh: here.
+ (GENERATE_SHLIB_SCRIPT): Deleted as redundant.
+ * emulparams/elf32btsmipn32.sh: Delete redundant unsets.
+ * emulparams/elf64bmip-defs.sh: New file. Extend
+ elf32bmipn32-defs.sh by overiding ELFSIZE and LIB_PATH.
+ * emulparams/elf64bmip.sh: Bring in definitions from
+ elf64bmip-defs.sh.
+ (ELFSIZE, GENERATE_SHLIB_SCRIPT, LIB_PATH): Delete redundant
+ settings.
+ (WRITABLE_RODATA): Moved from elf32bmipn32-defs.sh.
+ * emulparams/elf64btsmip.sh: Bring in definitions from
+ elf64bmip-defs.sh.
+ (ELFSIZE, GENERATE_SHLIB_SCRIPT): Delete, redundant.
+ (EXECUTABLE_SYMBOLS, WRITABLE_RODATA): Delete redundant unsets.
+
+2002-10-16 Jakub Jelinek <jakub@redhat.com>
+
+ * configure.tgt (s390x-*-linux*): Add elf_s390 emulation.
+ (s390-*-linux*): Add elf64_s390 emulation if want64.
+ * emulparams/elf64_sparc.sh (LIB_PATH): Update to match 2002-05-22
+ genscript.sh changes.
+ * emulparams/elf_x86_64.sh (LIB_PATH): Likewise.
+ * emulparams/elf64_s390.sh (LIB_PATH): Set up native 64 bit dirs.
+
+2002-10-15 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (load_symbols): Revert last change.
+
+2002-10-14 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (load_symbols): Don't call bfd_link_add_symbols when
+ just_syms_flag.
+ (lang_reasonable_defaults): Don't compare against false.
+ (size_input_section): Likewise.
+ (lang_size_sections_1): Likewise.
+ (lang_do_assignments): Likewise.
+ (lang_add_output): Likewise.
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * ldver.c: #include "bfdver.h".
+
+2002-10-13 Stephane Carrez <stcarrez@nerim.fr>
+
+ * scripttempl/elfm68hc11.sc: Use KEEP for .vectors, .installN,
+ .finiN section.
+ * scripttempl/elfm68hc12.sc: Likewise.
+
+2002-10-11 Alan Modra <amodra@bigpond.net.au>
+
+ * pe-dll.c (make_import_fixup_mark): Avoid type-punned pointer.
+
+ * ldgram.y (memory_spec): Provide empty action.
+ (section <NAME>): Likewise.
+
+2002-10-10 Jakub Jelinek <jakub@redhat.com>
+
+ * ldfile.c (ldfile_try_open_bfd): When searching skip linker scripts if
+ they have OUTPUT_FORMAT not matching actual output format.
+ * ldlang.c (lang_get_output_target): New function.
+ (open_output): Use it.
+ * ldlang.h (lang_get_output_target): New prototype.
+
+2002-10-10 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/elf32.em (output_rel_find): Prefer .rel script sections
+ when orphan is .rel, .rela when orphan is .rela.
+ (gld${EMULATION_NAME}_place_orphan): Handle combreloc .rel* case
+ first. Remove outsecname var.
+
+2002-10-09 Richard Shann <richard.shann@superh.com>
+ Stephen Clarke <stephen.clarke@superh.com>
+
+ * Makefile.am: Add eshelf32_linux.o and
+ eshlelf32_linux.o, new emulations for sh64 Linux.
+ * Makefile.in: Regenerate.
+ * configure.tgt: Add sh64eb-*-linux* and sh64-*-linux* emulations.
+ * emulparams/shelf32_linux.sh: New file.
+ * emulparams/shlelf32_linux.sh: New file.
+
+2002-10-08 H.J. Lu <hjl@gnu.org>
+
+ * ldlang.c (lang_file_exist): Removed.
+ (new_afile): Revert the last change.
+ * ldlang.h (lang_file_exist): Removed.
+ * lexsup.c (parse_args): Revert the last change.
+
+2002-10-07 Ralf Habacker <Ralf.Habacker@freenet.de>
+
+ * pe-dll.cc (autofilter_symbolprefixlist): Don't re-export
+ auto-import symbols.
+ (make_one): Create _nm_<symbol> for data only.
+
+2002-10-05 Elias Athanasopoulos <eathan@otenet.gr>
+
+ * ldlang.c (lang_file_exist): New function.
+ (new_afile): Abort if the filename to be added matches the linker
+ output filename.
+ * ldlang.h: Add prototype for lang_file_exist.
+ * lexsup.c (parse_args): Abort if the output filename matches
+ one of the input filenames.
+
+2002-10-02 Alan Modra <amodra@bigpond.net.au>
+
+ * emulparams/elf64ppc.sh (MAXPAGESIZE): Set to 0x10000.
+
+2002-09-30 Alan Modra <amodra@bigpond.net.au>
+
+ * scripttempl/elfd30v.sc: Order reloc sections placing .plt last.
+ * scripttempl/elfm68hc11.sc: Likewise.
+ * scripttempl/elfm68hc12.sc: Likewise.
+
+ * emultempl/elf32.em (output_rel_find): Always place orphan loadable
+ reloc sections just before .rel.plt/.rela.plt.
+ (gld${EMULATION_NAME}_place_orphan <.rel>): Remove combreloc code.
+ Only put loadable reloc sections in hold_rel.
+
+2002-09-29 H.J. Lu <hjl@gnu.org>
+
+ * emulparams/elf32ppc.sh (OTHER_GOT_RELOC_SECTIONS): New.
+
+2002-09-25 Daniel Jacobowitz <drow@mvista.com>
+
+ From "Anita Kulkarni" <AnitaK@kpit.com>
+ * scripttempl/sh.sc: Handle .eh_frame* and .gcc_exc*
+ sections.
+
+2002-09-25 Alan Modra <amodra@bigpond.net.au>
+
+ * genscripts.sh (SEGMENT_SIZE): Use MAXPAGESIZE before
+ TARGET_PAGE_SIZE.
+ * scripttempl/elf.sc (DATA_SEGMENT_ALIGN): Incorporate
+ SEGMENT_SIZE alignment.
+ * emulparams/elf64ppc.sh (DATA_ADDR): Delete.
+ (SEGMENT_SIZE): Define.
+
+ * ldexp.c (fold_unary): New. Split out from exp_fold_tree.
+ (fold_binary): Correct abs - non-abs case.
+ (fold_trinary): New. Split out from exp_fold_tree.
+
+2002-09-24 Alan Modra <amodra@bigpond.net.au>
+
+ * emulparams/elf64ppc.sh (DATA_ADDR): Define.
+ * emulparams/elf64_aix.sh (DATA_ADDR): Don't use a fixed address
+ for start of .data, instead align up to 256M boundary.
+ * scripttempl/aix.sc: Likewise.
+
+2002-09-22 Mark Elbrecht <snowball3@softhome.net>
+
+ * scripttempl/i386go32.sc: Handle bss unique sections.
+
+2002-09-21 Alan Modra <amodra@bigpond.net.au>
+
+ * ldmisc.c (vfinfo <%C,%D,%G>): Always output bfd, section and offset.
+
+2002-09-17 Stan Cox <scox@redhat.com>
+
+ * emulparams/elf32bmipn32-defs.sh: New file.
+ * emulparams/elf32bmipn32.sh: Use elf32bmipn32-defs.sh.
+ * emulparams/elf32btsmipn32.sh: Likewise.
+ * emulparams/elf64bmip.sh: Likewise.
+ * emulparams/elf64btsmip.sh: Likewise.
+
+2002-09-16 Bruno Haible <bruno@clisp.org>
+
+ * emulparams/elf_i386_fbsd.sh: Set OUTPUT_FORMAT to
+ elf32-i386-freebsd.
+ * emulparams/elf64alpha_fbsd.sh: Set OUTPUT_FORMAT to
+ elf64-alpha-freebsd.
+
+2002-09-11 Nick Clifton <nickc@redhat.com>
+
+ * NEWS: New TI port supports both C4x and C3x series of DSPs.
+
+ * po/tr.po: Updated Turkish translation.
+
+2002-09-06 Jeffrey A Law (law@redhat.com)
+
+ * configure.tgt (h8300-*-hms*, h8500-*-hms*): Restore.
+
+2002-09-02 Nick Clifton <nickc@redhat.com>
+
+ * scripttempl/v850.sc: Add EXTERN references to __ctbpm __gp and
+ __ep.
+ * emulparams/v850.sh (TEMPLATE_NAME): Define.
+
+2002-08-30 Nick Clifton <nickc@redhat.com>
+
+ * scripttempl/elfd10v.sc (MEMORY): Remove UNIFIED, it is not
+ used. Change INSN to start at 0x01000000 and extend for
+ 256K (ignoring holes). Start the STACK on a word aligned
+ boundary.
+ (.rodata): Start it at the READONLY_START_ADDR.
+
+2002-08-30 Alan Modra <amodra@bigpond.net.au>
+
+ * emulparams/elf32ppc.sh (ARCH): Set to "powerpc:common".
+
+2002-08-28 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * Makefile.am: Add etic4xcoff.o in ALL_EMULATIONS list and
+ added makefile targets for this file.
+ * Makefile.in: Regenerate.
+ * configure.tgt: Added tic4x-coff and c4x-coff emulations.
+ * NEWS: Mention new port.
+
+2002-08-28 Michael Hayes <m.hayes@elec.canterbury.ac.nz>
+
+ * emulparams/tic3xcoff.sh: New file.
+ * emulparams/tic4xcoff.sh: New file.
+ * scripttempl/tic3xcoff.sc: New file.
+ * scripttempl/tic4xcoff.sc: New file.
+
+2002-08-28 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/aix.em (gld${EMULATION_NAME}_parse_args): Replace strtoll,
+ strtoul and strtoull with bfd_scan_vma.
+ (gld${EMULATION_NAME}_read_file): Likewise.
+
+2002-08-28 Alan Modra <amodra@bigpond.net.au>
+
+ * configure.tgt: Remove h8[35]00-*-hms*. Add h8500-*-rtems*.
+
+2002-08-27 Egor Duda <deo@logos-m.ru>
+
+ * scripttempl/pe.sc: Handle .rdata_runtime_pseudo_reloc sections.
+ Add symbols for application to access them.
+
+2002-08-27 Nick Clifton <nickc@redhat.com>
+
+ * emultempl/armelf.em: Revert this patch, it is not needed.
+
+ 2002-08-22 Adam Nemet <anemet@lnxw.com>
+
+2002-08-20 Dan Kegel <dank@kegel.com>
+
+ * configure.in: added --with-lib-path argument to ld's configure
+ to set LIB_PATH.
+ * NEWS: Document new switch.
+ * README: Mention new switch.
+ * configure: Regenerate.
+ * Makefile.in: Regenerate.
+
+ Based on this patch:
+ 2001-04-25 Christopher Faylor <cgf@cygnus.com>
+
+ * Makefile.in (LIB_PATH): Make configurable.
+ (GENSCRIPTS): Set LIB_PATH in environment.
+ * configure.in: Substitute LIB_PATH.
+
+2002-08-22 Adam Nemet <anemet@lnxw.com>
+
+ * emultempl/armelf.em: Include elf-bfd.h and elf/arm.h.
+ (arm_elf_finish): Set the last bit of DT_INIT and DT_FINI
+ depending on the type of the function.
+ (arm_elf_convert_thumb_symbol_to_address): New function.
+
+2002-08-22 Graeme Peterson <gp@qnx.com>
+
+ * Makefile.am: Add esh{l}elf_nto.o files.
+ * Makefile.in: Regenerate.
+ * configure.tgt: Add support for sh-**-nto* targets.
+ * emulparams/shelf_nto.sh: New file.
+ * emulparams/shlelf_nto.sh: New file.
+
+2002-08-21 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * ldlang.c (offsetof): Define if not defined.
+
+2002-08-14 H.J. Lu <hjl@gnu.org>
+
+ * configure.tgt: Always enable 64bit emulations for 32bit
+ Linux/mips.
+
+2002-08-13 Alan Modra <amodra@bigpond.net.au>
+
+ * emulparams/elf32_dlx.sh (TARGET_PAGE_SIZE): Set to 1.
+ (MAXPAGESIZE): Set to 1.
+
+ * ld.h (ALIGN_N): Delete.
+ * ldexp.h (align_n): Declare.
+ * ldexp.c (align_n): New function.
+ (fold_binary): Use align_n instead of ALIGN_N.
+ (exp_fold_tree): Likewise.
+ * ldlang.c (lang_size_sections_1): Likewise.
+ (lang_one_common): Likewise.
+ * ld.texinfo (ALIGN): Remove power of 2 restriction.
+
+2002-07-31 Graeme Peterson <gp@qnx.com>
+
+ * configure.tgt: Add support for powerpc{le}-*-nto* targets.
+ * Makefile.am: Add eelf32{l}ppcnto.o files.
+ * Makefile.in: Regenerate.
+ * emulparams/elf32lppcnto.sh: New file.
+ * emulparams/elf32ppcnto.sh: New file.
+
+2002-08-07 H.J. Lu <hjl@gnu.org>
+
+ * ld.texinfo: Document --no-undefined-version.
+
+ * ldlang.c (lang_new_vers_pattern): Set the `symver' and
+ `script.' fields to 0.
+
+ * ldmain.c (main): Initialize the allow_undefined_version to
+ true.
+
+ * lexsup.c (OPTION_NO_UNDEFINED_VERSION): New.
+ (ld_options): Add --no-undefined-version.
+ (parse_args): Support OPTION_NO_UNDEFINED_VERSION.
+
+2002-08-07 Nick Clifton <nickc@redhat.com>
+
+ * emultempl/armelf.em (arm_elf_before_allocation): Only search for
+ an interworking bfd if there are input bfds. (107501)
+
+2002-08-06 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/aix.em (gld*_before_parse): Set default arch. Reverts
+ 2002-05-10 change.
+
+2002-08-01 Nick Clifton <nickc@redhat.com>
+
+ * emulparams/armelf.sh: Revert previous delta.
+ * scripttempl/elf.sc: Revert previous delta.
+
+2002-07-31 H.J. Lu <hjl@gnu.org>
+
+ * configure.tgt (powerpc*-*-linux*): Enable elf64ppc for
+ --enable-64-bit-bfd.
+
+2002-07-31 H.J. Lu <hjl@gnu.org>
+
+ * configure.tgt: Enable x86-64 emulation for Linux/i386 if
+ 64bit BFD is selected.
+
+2002-07-31 H.J. Lu <hjl@gnu.org>
+
+ * configure.tgt: Enable 64bit emulations for 32bit Linux/mips
+ if 64bit BFD is selected.
+
+2002-07-31 Ian Dall <ian@sibyl.beware.dropbear.id.au>
+
+ * emultempl/netbsd.em (LDEMUL_BEFORE_PARSE): New file to custom set
+ link_info.common_skip_ar_aymbols.
+ * emulparams/ns32knbsd.sh (EXTRA_EM_FILE): Refer to extra file.
+
+ * ldmain.c (main): Initialize new field
+ link_info.common_skip_ar_aymbols.
+
+2002-07-31 Adam Nemet <anemet@lnxw.com>
+
+ * emulparams/armelf.sh (OTHER_PLT_SECTIONS): New variable. Set it
+ to .plt.thumb.
+ * scripttempl/elf.sc: Comment it. Use the same way as ${PLT} is
+ used.
+
+2002-07-31 Nick Clifton <nickc@redhat.com>
+
+ * NEWS: Retroactively add entry for Lars Brinkhoff's contribution
+ of the PDP-11 and 2.11BSD a.out support.
+
+2002-07-31 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * Makefile.am (eelf32btsmipn32.o, eelf32ltsmipn32.o): New emulations
+ for n32 ABI support.
+ * Makefile.in: Regenerate.
+ * configure.tgt (mips64*el-*-linux-gnu*,mips64*-*-linux-gnu*): Add
+ n32 ABI emulations for these 64 bit targets.
+ * emulparams/elf32bmipn32.sh: Expand comment.
+ * emulparams/elf32btsmipn32.sh: New file, for traditional big endian
+ n32 ABI.
+ * emulparams/elf32ltsmipn32.sh: Likewise for little endian.
+
+2002-07-30 Graeme Peterson <gp@qnx.com>
+
+ * configure.tgt: Add support for arm-*-nto target.
+ * Makefile.am: Add earmnto.o file.
+ * Makefile.in: Regenerate.
+ * NEWS: Mention port of ARM support to QNX.
+ * emulparams/armnto.sh: New file.
+
+2002-07-30 Jakub Jelinek <jakub@redhat.com>
+
+ * ldlang.c (lang_add_section): Don't turn .tbss into normal sections
+ for relocatable link.
+ (lang_size_sections_1): Don't make .tbss zero size for relocatable
+ link.
+
+2002-07-26 Bernd Schmidt <bernds@redhat.com>
+
+ * emulparams/elf32frv.sh (OTHER_RELOCATING_SECTIONS): Delete.
+ (STACK_ADDR): New.
+
+2002-07-25 Nick Clifton <nickc@redhat.com>
+
+ * po/sv.po: Updated Swedish translation.
+ * po/es.po: Updated Spanish translation.
+ * po/fr.po: Updated French translation.
+
+2002-07-24 Nick Clifton <nickc@redhat.com>
+
+ * po/sv.po: Updated Swedish translation.
+ * po/es.po: Updated Spanish translation.
+
+2002-07-23 Nick Clifton <nickc@redhat.com>
+
+ * po/fr.po: Updated French translation.
+
+2002-07-20 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Don't
+ bomb on /DISCARD/ input section.
+ * emultempl/pe.em (gld_${EMULATION_NAME}_place_orphan): Likewise.
+ * emultempl/mmo.em (mmo_place_orphan): Likewise.
+
+2002-07-19 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * emultempl/mmo.em (mmo_place_orphan): Handle case of no .text
+ output section.
+
+2002-07-16 Denis Chertykov <denisc@overta.ru>
+ Nick Clifton <nickc@redhat.com>
+ Frank Ch. Eigler <fche@redhat.com>
+ John Healy <jhealy@redhat.com>
+
+ * configure.tgt: Add support for ip2k-elf.
+ * Makefile.am: Add support for ip2k-elf.
+ * Makefile.in: Regenerate.
+ * emulparams/elf32ip2k.sh: New file.
+ * scripttempl/ip2k.sc: New file
+ * NEWS: Mention support for new port.
+
+2002-07-16 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * NEWS: Add 'Changes in 2.13'.
+
+2002-07-14 H.J. Lu <hjl@gnu.org>
+
+ * ld.texinfo: Document a .symver takes precedence over a
+ version script.
+
+2002-07-12 Alan Modra <amodra@bigpond.net.au>
+
+ * emulparams/elf64ppc.sh (ARCH): Set to powerpc:common64.
+ (COMMONPAGESIZE): Define.
+
+2002-07-09 Alan Modra <amodra@bigpond.net.au>
+
+ * emulparams/hppanbsd.sh: Remark that hppaobsd.sh references this file.
+
+2002-07-09 Federico G. Schwindt <fgsch@olimpo.com.br>
+
+ * configure.tgt: Add support for alpha-*-openbsd*, hppa-*-openbsd*,
+ powerpc-*-openbsd* and sparc64-*-openbsd*.
+ * Makefile.am (ALL_EMULATIONS): Add ehppaobsd.o.
+ * Makefile.in: Regenerate.
+ * emulparams/hppaobsd.sh: New file.
+
+2002-07-05 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (print_wild_statement): Fix output formatting.
+
+2002-07-04 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c: (strip_excluded_output_sections): New function.
+ (lang_process): Call it.
+ (lang_size_sections_1): Revert 2002-06-10 change.
+
+2002-07-03 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (check-DEJAGNU): Revert 2002-06-25 change.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2002-07-02 Alan Modra <amodra@bigpond.net.au>
+
+ * ldfile.c (ldfile_try_open_bfd): Formatting.
+
+ * ldmisc.c (demangle): Move so that it doesn't intrude between
+ vfinfo comment and body. Add comment.
+
+2002-07-01 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * emulparams/vax.sh (OUTPUT_FORMAT): Use a.out-vax-bsd format.
+
+2002-07-01 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.h (entry_sym): Make it a struct bfd_sym_chain.
+ * ldlang.c (entry_sym): Likewise.
+ (ldlang_undef_chain_list_type): Likewise.
+ (lang_finish): Adjust references to entry_symbol.
+ (lang_add_entry): Likewise.
+ (lang_gc_sections): Use link_info.gc_sym_list.
+ (lang_process): Set link_info.gc_sym_list.
+ * ldlex.l: Include bfdlink.h.
+ * ldmain.c (main): Init link_info.gc_sym_list.
+ * emultempl/aix.em: Adjust references to entry_symbol.
+ * emultempl/armcoff.em: Likewise.
+ * emultempl/armelf.em: Likewise.
+ * emultempl/pe.em: Likewise.
+ * emultempl/ppc64elf.em (ppc_after_open): New function.
+ (LDEMUL_AFTER_OPEN): Define.
+ * emulparams/elf64ppc.sh: KEEP .opd sections.
+
+2002-06-29 Stephane Carrez <stcarrez@nerim.fr>
+
+ * emulparams/m68hc12elfb.sh (EEPROM_MEMORY): Define.
+ * emulparams/m68hc11elfb.sh (EEPROM_MEMORY): Define.
+ * emulparams/m68hc11elf.sh (EEPROM_SIZE): Define.
+ (EEPROM_START_ADDR): Define.
+ (EEPROM_MEMORY): Define.
+ * emulparams/m68hc12elf.sh: Likewise.
+ * scripttempl/elfm68hc11.sc: Handle .eeprom section; handle .softregs
+ section to put soft registers in .page0.
+ * scripttempl/elfm68hc12.sc: Likewise but put soft registers in bss.
+
+2002-06-26 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * emulparams/hppa64linux.sh (OTHER_GOT_RELOC_SECTIONS): Add rela.opd
+ section. Add ${RELOCATING-0}.
+
+2002-06-26 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * emulparams/shelf.sh (STACK_ADDR): Don't define.
+ (OTHER_SECTIONS): Define.
+ * emulparams/shelf_nbsd.sh ((STACK_ADDR): Don't undef.
+ (OTHER_SECTIONS): Undef.
+
+2002-06-26 Alan Modra <amodra@bigpond.net.au>
+
+ * ldmisc.c (demangle): Restore dots stripped from sym name.
+
+2002-06-25 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.am (check-DEJAGNU): Set LC_ALL=C and export it.
+ * Makefile.in: Regenerated.
+
+2002-06-20 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * ld.texinfo (Bug Reporting): Update text to suggest a limit on
+ the size of attached object files, to allow make the object files
+ available via FTP or HTTP and to mention that the mail will be
+ sent to a mailing list.
+
+2002-06-20 Nathanael Nerode <neroden@twcny.rr.com>
+
+ * configure.host (romp): Drop support.
+
+2002-06-18 Chris Demetriou <cgd@broadcom.com>
+
+ * emultempl/mipself.em (mips_elf${ELFSIZE}_check_sections): Check
+ section flags for SEC_DATA, rather than for SEC_CODE being unset.
+
+2002-06-18 Chris Demetriou <cgd@broadcom.com>
+
+ * emultempl/mipself.em (mips_elf${ELFSIZE}_check_sections): Fix
+ format specifier used to print BFD name.
+
+2002-06-18 Dave Brolley <brolley@redhat.com>
+
+ From Catherine Moore, Michael Meissner, Jim Blandy:
+ * emulparams/elf32frv.sh: New file.
+ * configure.tgt: Support frv-*-*.
+ * Makefile.am (ALL_EMULATIONS): Add eelf32frv.o.
+ (eelf32frv.c): New target.
+
+2002-06-17 Tom Rix <trix@redhat.com>
+
+ * emultempl/elf32.em: gld*_get_script: Check for
+ GENERATE_COMBRELOC_SCRIPT.
+ * scripttempl/elfd10v.sc : Fix STACK and INSN.
+ * emulparams/d10velf.sh : Fix TEXT_START_ADDR.
+
+2002-06-13 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * configure.tgt: Add support for sh[1234]*le*-*-elf, sh[1234]*-*-elf.
+
+2002-06-12 H.J. Lu <hjl@gnu.org>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_try_needed): Return
+ false if xvec doesn't match.
+
+2002-06-10 Richard Sandiford <rsandifo@redhat.com>
+
+ * ldlang.c (lang_size_sections_1): Skip removed output sections.
+
+2002-06-08 Alan Modra <amodra@bigpond.net.au>
+
+ * ldexp.c: Replace CONST with const.
+ * ldfile.c: Likewise.
+ * ldfile.h: Likewise.
+ * ldlex.l: Likewise.
+ * mri.c: Likewise.
+ * pe-dll.h: Likewise.
+
+2002-06-07 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/ppc64elf.em (new_vers_pattern): Warning fix.
+
+2002-06-07 Charles Wilson <cwilson@ece.gatech.edu>
+
+ * ldmain.c (main): initialize link_info.pei386_auto_import
+ to -1 == implicit enable.
+ * emultempl/pe.em (gld_${EMULATION_NAME}_before_parse):
+ initialize link_info.pei386_auto_import to -1 == implicit
+ enable.
+ (gld_${EMULATION_NAME}_parse_args): When processing
+ --enable-auto-import and --disable-auto-import options, use
+ '1' and '0' instead of 'true' and 'false'.
+ (pe_find_data_imports): Only issue message about auto-import
+ when the feature is implicitly enabled. Downgrade message to
+ informational instead of warning.
+
+2002-06-07 Alan Modra <amodra@bigpond.net.au>
+
+ * scripttempl/elf.sc (.tbss): Fix mismatched parentheses/braces.
+
+2002-06-06 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * configure.host (hppa*64*-*-hpux11*): Define NATIVE_LIB_DIRS,
+ HOSTING_CRT0 and HOSTING_LIBS.
+
+2002-06-05 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * configure.tgt (shle*-*-elf*, sh64le-*-elf*): New configurations.
+
+2002-06-05 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * emulparams/ns32knbsd.sh (EXECUTABLE_SYMBOLS): Set _DYNAMIC to 0.
+ (NONPAGED_TEXT_START_ADDR): Set to 0x1000.
+
+2002-06-05 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Place
+ SEC_EXCLUDE sections when doing a relocatable link.
+
+2002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * Makefile.am (ALL_EMULATIONS): Add eshelf32_nbsd.o,
+ eshlelf32_nbsd.o, eshelf64_nbsd.o, and eshlelf64_nbsd.o.
+ (eshelf32_nbsd.c, eshelf64_nbsd.c, eshlelf32_nbsd.c)
+ (eshlelf64_nbsd.c): New rules.
+ * Makefile.in: Regenerate.
+ * configure.tgt (sh5le-*-netbsd*, sh5-*-netbsd*, sh64le-*-netbsd*)
+ (sh64-*-netbsd*): New targets.
+ * emulparams/shelf32_nbsd.sh: New file.
+ * emulparams/shelf64_nbsd.sh: New file.
+ * emulparams/shlelf32_nbsd.sh: New file.
+ * emulparams/shlelf64_nbsd.sh: New file.
+
+2002-06-04 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (section_already_linked): Call bfd_discard_group. Typo fix.
+
+2002-06-02 Marek Michalkiewicz <marekm@amelek.gda.pl>
+
+ * scripttempl/avr.sc: Changes to support current GCC and avr-libc,
+ C++ constructors/destructors, loosely based on the m68hc11 port.
+
+2002-05-31 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.in: Regenerate.
+ * aclocal.m4: Regenerate.
+ * config.in: Regenerate.
+ * configure: Regenerate.
+
+2002-05-31 Graeme Peterson <gp@qnx.com>
+
+ * Makefile.am (ALL_EMULATIONS): Add ei386nto.o.
+ (ei386nto.c): Add rule.
+ * Makefile.in: Regenerate.
+ * configure.tgt: Add i[3456]86-*-nto-qnx*.
+ * emulparams/i386nto.sh: New file.
+
+2002-05-29 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * NEWS: Add entry for VAX ELF support.
+
+2002-05-29 Matt Thomas <matt@3am-software.com>
+ Jason Thorpe <thorpej@wasabisystems.com>
+
+ * Makefile.am (ALL_EMULATIONS): Add eelf32vax.o and evaxnbsd.o.
+ (eelf32vax.c)
+ (evaxnbsd.c): New rules.
+ * Makefile.in: Regenerate.
+ * configure.tgt (vax-*-netbsdelf*)
+ (vax-*-netbsdaout*)
+ (vax-*-netbsd*): New targets.
+ * emulparams/elf32vax.sh: New file.
+ * emulparams/vaxnbsd.sh: New file.
+
+2002-05-29 Adam Nemet <anemet@lnxw.com>
+
+ * emultempl/armelf.em (arm_elf_after_open): Don't determine
+ bfd_for_interwork, instead add glue sections to each input bfd.
+ (bfd_for_interwork): New global.
+ (arm_elf_set_bfd_for_interworking): New function.
+ (arm_elf_before_allocation): Use it.
+
+2002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
+
+ * Makefile.am: Add DLX make target.
+ * configure.tgt: Add DLX configuration.
+ * Makefile.in: Regenerate.
+ * emulparams/elf32_dlx.sh: New file
+ * scripttempl/dlx.sc: New file
+
+2002-05-27 Per Lundberg <per@caleb.dnsalias.org>
+
+ * Makefile.am (eelf_i386_chaos): Use elf_chaos.sc script.
+ * Makefile.in: Regenerate.
+ * emulparams/elf_chaos.sh: Use elf_chaos script.
+ * scripttempl/elf_chaos.sc: New file.
+
+2002-05-27 Richard Sandiford <rsandifo@redhat.com>
+
+ * ldlang.c (lang_size_sections_1): Move check for conflicting load
+ addresses and regions from here...
+ (lang_get_regions): ...to this new function.
+ (lang_leave_output_section_statement): Use lang_get_regions.
+ (lang_leave_overlay): Likewise.
+ * mri.c (mri_draw_tree): Pass null as last argument to
+ lang_leave_output_section_statement.
+ * emultempl/elf32.em (gld*_place_orphan): Likewise.
+ * emultempl/mmo.em (mmo_place_orphan): Likewise.
+ * emultempl/pe.em (gld*_place_orphan): Likewise.
+
+2002-05-26 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * configure.tgt: Use ns32k-*-netbsd* instead of ns32k-pc532-netbsd*.
+
+2002-05-25 Kazu Hirata <kazu@cs.umass.edu>
+
+ * ldemul.c: Fix formatting.
+ * ldfile.c: Likewise.
+ * pe-dll.c: Likewise.
+ * pe-dll.h: Likewise.
+
+2002-05-25 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (lang_process): Formatting, grammar.
+
+ * ldlex.l: Use #include "" instead of <> for local header files.
+
+2002-05-24 TAMURA Kent <kent@netbsd.org>
+
+ * configure.tgt: Add a target for i386-netbsdpe.
+
+2002-05-23 Jakub Jelinek <jakub@redhat.com>
+
+ * scripttempl/elf.sc: Add .rel{,a}.t{bss,data}, .tdata and .tbss.
+ * ldlang.c (lang_add_section): Set SEC_THREAD_LOCAL for
+ output section if necessary. Handle .tbss.
+ (lang_size_sections): Clear _raw_size for .tbss section
+ (it allocates space in PT_TLS segment only).
+ * ldwrite.c (build_link_order): Build link order for .tbss too.
+
+2002-05-23 Alan Modra <amodra@bigpond.net.au>
+
+ * configure.in: Correct spelling of AC_PREREQ.
+
+2002-05-21 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * pe-dll.c (autofilter_liblist): Add more system libs excluded by
+ default.
+ (autofilter_objlist): Add crtbegin.o, crtend.o.
+
+2002-05-21 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * emultempl/pe.em (OPTION_EXCLUDE_LIBS): Add new define.
+ (longopts): Add new option --exclude-libs.
+ (gld_${EMULATION_NAME}_list_options): Give quick help about it.
+ (gld_${EMULATION_NAME}_parse_args): Use it.
+ * pe-dll.h (pe_dll_add_excludes): Add second param to prototype.
+ * pe-dll.c (exclude_list_struct): Add field type to distinguish symbols
+ from whole archives.
+ (pe_dll_add_excludes): Set excludes->type.
+ (auto_export): Add new variable libname and set to archive basename if
+ abfd. Use it when filtering default and user-specified libarary
+ excludes. Let string "ALL" mean all libs when filtering user-specified
+ libs.
+ * ld.texinfo: Document --exclude-libs.
+
+2002-05-22 Alan Modra <amodra@bigpond.net.au>
+
+ * ldemul.c (ldemul_new_vers_pattern): New function.
+ * ldemul.h (ldemul_new_vers_pattern): Declare.
+ (struct ld_emulation_xfer_struct): Add new_vers_pattern.
+ * ldlang.c (lang_new_vers_pattern): Call ldemul_new_vers_pattern.
+ * emultempl/ppc64elf.em (dotsyms): New static var.
+ (gld${EMULATION_NAME}_new_vers_pattern): New function.
+ (LDEMUL_NEW_VERS_PATTERN): Define.
+ (PARSE_AND_LIST_PROLOGUE): Add OPTION_DOTSYMS, OPTION_NO_DOTSYMS.
+ (PARSE_AND_LIST_LONGOPTS): Likewise.
+ (PARSE_AND_LIST_ARGS_CASES): Handle them.
+ * emultempl/aix.em (ld_${EMULATION_NAME}_emulation): Update
+ initialiser.
+ * emultempl/armcoff.em: Likewise.
+ * emultempl/armelf_oabi.em: Likewise.
+ * emultempl/beos.em: Likewise.
+ * emultempl/elf32.em: Likewise.
+ * emultempl/generic.em: Likewise.
+ * emultempl/gld960.em: Likewise.
+ * emultempl/gld960c.em: Likewise.
+ * emultempl/linux.em: Likewise.
+ * emultempl/lnk960.em: Likewise.
+ * emultempl/m68kcoff.em: Likewise.
+ * emultempl/mipsecoff.em: Likewise.
+ * emultempl/pe.em: Likewise.
+ * emultempl/sunos.em: Likewise.
+ * emultempl/ticoff.em: Likewise.
+ * emultempl/vanilla.em: Likewise.
+
+2002-05-22 Alan Modra <amodra@bigpond.net.au>
+
+ * genscripts.sh (LIB_PATH): For native targets, concatenate $libdir
+ and $NATIVE_LIB_DIRS. Add $tool_lib before other libs.
+ (LIB_SEARCH_DIRS): No need to use "tr".
+ (COMPILE_IN): Only set for native targets.
+ * configure.host (NATIVE_LIB_DIRS): Specify all native search dirs
+ here, rather than adding lib:/usr/lib:/usr/local/lib in genscripts.sh.
+ * configure.tgt (powerpc*): Set tdir_*.
+ (powerpcle*): Correct targ_extra_emuls.
+ * emulparams/elf32ppc.sh (LIB_PATH): Set up native 64 bit dirs.
+ * emulparams/elf64ppc.sh (LIB_PATH): Likewise.
+
+2002-05-22 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/pe.em (set_pe_subsystem): Don't set "cmdline" when
+ calling lang_add_entry.
+
+2002-05-21 H.J. Lu (hjl@gnu.org)
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_parse_args): Handle
+ "-z muldefs".
+ (gld${EMULATION_NAME}_list_options): Add "-z muldefs".
+
+ * ld.texinfo: Updated for --allow-multiple-definition and
+ "-z muldefs".
+
+ * ldmain.c (main): Initialize the allow_multiple_definition
+ field to false.
+
+ * lexsup.c (OPTION_ALLOW_MULTIPLE_DEFINITION): New.
+ (ld_options): Add --allow-multiple-definition.
+ (parse_args): Support OPTION_ALLOW_MULTIPLE_DEFINITION.
+
+2002-05-21 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * Makefile.am (ALL_EMULATIONS): Add earmelfb_nbsd.o.
+ (earmelfb_nbsd.c): New rule.
+ * Makefile.in: Regenerate.
+ * configure.tgt (armeb-*-netbsdelf*): New target.
+ (arm-*-netbsdelf*): Add armelfb_nbsd to targ_extra_emuls.
+ (arm-*-netbsd*): Likewise.
+ * emulparams/armelfb_nbsd.sh: New file.
+
+2002-05-18 Tom Rix <trix@redhat.com>
+
+ * emultempl/aix.em (gld*_parse_args): Add -bnortl and -bnortllib
+ support.
+
+2002-05-17 Marek Michalkiewicz <marekm@amelek.gda.pl>
+
+ * Makefile.am: Add new emulations avr1, avr2, avr3, avr4, avr5.
+ * Makefile.in: Regenerate.
+ * configure.tgt (avr-*-*): Add avr[1-5] to targ_extra_emuls.
+
+2002-05-16 Marek Michalkiewicz <marekm@amelek.gda.pl>
+
+ * emulparams/avr1.sh: New file.
+ * emulparams/avr2.sh: New file.
+ * emulparams/avr3.sh: New file.
+ * emulparams/avr4.sh: New file.
+ * emulparams/avr5.sh: New file.
+ * scripttempl/avr.sc: New file.
+
+2002-05-15 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (section_already_linked): Call bfd_link_just_syms.
+ (lang_place_orphans): Abort if just_syms_flag.
+
+2002-05-10 Tom Rix <trix@redhat.com>
+
+ * emultempl/aix.em: (gld*_set_output_arch): New function. Use
+ architecture and machine information in the output bfd.
+ (gld*_before_parse): Remove old arch and machine code.
+ (choose_target): Rename to gld*_choose_target.
+ (rtld): Change type to int.
+ * ldfile.c (ldfile_try_open_bfd): Disable compatiblity check for
+ objects in XCOFF archives.
+ * ldfile.h: Update copyright date.
+
+2002-05-10 Jakub Jelinek <jakub@redhat.com>
+
+ * ldmain.c (main): Enable -z combreloc by default.
+
+2002-05-07 Federico G. Schwindt <fgsch@olimpo.com.br>
+
+ * Makefile.am: Honour DESTDIR.
+ * Makefile.in: Regenerate.
+
+2002-05-07 Richard Sandiford <rsandifo@redhat.com>
+
+ * ldlang.h (lang_output_section_statement_type): Add update_dot_tree.
+ (lang_enter_overlay): Remove the last two parameters.
+ (lang_leave_overlay): Take them here instead.
+ * ldgram.y (memspec_at_opt): Set $$ to null if no region is given.
+ (section): Pass LMA and crossref flag to lang_leave_overlay rather
+ than lang_enter_overlay.
+ * ldlang.c (lang_memory_region_lookup): Return null for null names.
+ (lang_output_section_statement_lookup): Initialize update_dot_tree.
+ (lang_size_sections_1): Evaluate it.
+ (lang_leave_output_section_statement): Rework LMA lookup.
+ (overlay_lma, overlay_nocrossrefs): Remove.
+ (lang_enter_overlay): Remove LMA and crossref arguments.
+ (lang_enter_overlay_section): Don't set the LMA here.
+ (lang_leave_overlay): Take LMA and crossref arguments. Move the '.'
+ assignment to the last section's update_dot_tree. Unconditionally
+ use the load and run-time regions specified in the OVERLAY statement.
+ Likewise the first section's LMA. Only set the other sections' LMAs
+ when no load region is given.
+
+2002-05-06 Nick Clifton <nickc@redhat.com>
+
+ * po/sv.po: New translation.
+
+2002-05-04 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/hppaelf.em (build_section_lists): New function.
+ (gld${EMULATION_NAME}_finish): Call elf32_hppa_setup_section_lists
+ and build_section_lists.
+
+2002-05-03 Kazu Hirata <kazu@cs.umass.edu>
+
+ * ld.h: Fix formatting.
+ * ldexp.c: Likewise.
+ * ldfile.c: Likewise.
+ * ldlang.c: Likewise.
+ * ldmain.c: Likewise.
+ * lexsup.c: Likewise.
+ * pe-dll.c: Likewise.
+
+2002-05-02 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/ppc64elf.em (gld${EMULATION_NAME}_after_allocation):
+ Adjust for ppc64_elf_set_toc change. #include libbfd.h.
+ (build_section_lists): Do output_section tests here.
+
+2002-04-30 Tom Rix <trix@redhat.com>
+
+ * emultempl/aix.em : (gld*_parse_arge): Formatting changes.
+
+2002-05-01 Alan Modra <amodra@bigpond.net.au>
+
+ Long branch stubs, multiple stub sections.
+ * emultempl/ppc64elf.em: Include ldctor.h.
+ (stub_file): New var.
+ (group_size): New var.
+ (ppc_create_output_section_statements): New function.
+ (struct hook_stub_info): New.
+ (hook_in_stub): New function.
+ (ppc_add_stub_section): New function.
+ (ppc_layout_sections_again): New function.
+ (build_section_lists): New function.
+ (gld${EMULATION_NAME}_finish): Rewrite.
+ (real_func): New var.
+ (ppc_for_each_input_file_wrapper): New function.
+ (ppc_lang_for_each_input_file): New function.
+ (lang_for_each_input_file): Define.
+ (PARSE_AND_LIST_PROLOGUE): Define.
+ (PARSE_AND_LIST_LONGOPTS): Define.
+ (PARSE_AND_LIST_OPTIONS): Define.
+ (PARSE_AND_LIST_ARGS_CASES): Define.
+ (LDEMUL_CREATE_OUTPUT_SECTION_STATEMENTS): Define.
+
+2002-04-30 Tom Rix <trix@redhat.com>
+
+ * emultempl/aix.em (gld*_parse_arge, gld*_before_allocation): Add
+ -blibpath, -bnolibpath support.
+
+2002-04-30 Mark Mitchell <mark@codesourcery.com>
+
+ * Makefile.am (ALL_EMULATIONS): Add elf32ppcwindiss.o.
+ (eelf32ppcwindiss.c): New target.
+ * Makefile.in: Regenerated.
+ * configure.tgt: Add support for powerpc-*-windiss.
+ * emulparams/elf32ppcwindiss.sh: New file.
+
+2002-04-30 Richard Sandiford <rsandifo@redhat.com>
+
+ * ldlang.c (print_assignment): Update print_dot for assignments to ".".
+ * ldexp.c (exp_print_token): Add "infix_p" argument.
+ (exp_print_tree): Update accordingly.
+
+2002-04-28 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (mpw): New maintainer mode rule to make mpw-*.c files.
+ * Makefile.in: Regenerate.
+ * mpw-elfmips.c: Delete.
+ * mpw-eppcmac.c: Delete.
+ * mpw-esh.c: Delete.
+ * mpw-idtmips.c: Delete.
+
+2002-04-17 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * emulparams/shelf32.sh (MACHINE): Now sh5.
+
+2002-04-17 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * ldgram.y: Fix syntax warning.
+
+2002-04-11 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * emultempl/armelf.em (PARSE_AND_LIST_SHORTOPTS): Add 'n' in order
+ to prevent "-n" from being taken as an abbreviation for
+ "--no-pipeline-knowledge".
+
+2002-04-08 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (lang_size_sections_1): Don't complain about
+ SEC_NEVER_LOAD sections having no memory region specified.
+
+ * ld.texinfo (Format Commands <OUTPUT_FORMAT>): Typo fix.
+
+2002-04-07 matthew green <mrg@redhat.com>
+
+ * configure.host (*-*-netbsd*): Add support for NetBSD/ELF.
+
+2002-04-04 Alan Modra <amodra@bigpond.net.au>
+
+ * dep-in.sed: Cope with absolute paths.
+ * Makefile.am (dep.sed): Subst TOPDIR and BFDDIR.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2002-04-04 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * emulparams/elf64btsmip.sh: n64 replaces .reginfo with .MIPS.options.
+
+2002-04-03 Jakub Jelinek <jakub@redhat.com>
+
+ * ldexp.c (fold_binary) [DATA_SEGMENT_ALIGN]: If common page size
+ is smaller than maximum, round dot up to common page boundary.
+
+2002-03-28 Alan Modra <amodra@bigpond.net.au>
+
+ * configure.host: Set up for generic hosts first, then tweak as
+ necessary in more specific targets.
+ (HOSTING_LIBS): Include libgcc_eh.a if found.
+
+2002-03-23 Andreas Jaeger <aj@suse.de>
+
+ * emulparams/elf_x86_64.sh (COMMONPAGESIZE): Set it.
+
+2002-03-21 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2002-03-21 Albert Chin-A-Young <china@thewrittenword.com>
+
+ * genscripts.sh (LIB_SEARCH_DIRS): Quote path.
+
+2002-03-20 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (ldlang_add_undef): If the output bfd has been opened,
+ add the symbol to the linker hash table immediately.
+ (lang_place_undefineds): Split symbol creation out..
+ (insert_undefined): ..to here.
+
+2002-03-18 David O'Brien <obrien@FreeBSD.org>
+
+ * emultempl/elf32.em: Use lbasename vs. basename to fix problem where
+ the contents of the buffer returned from basename function will are
+ getting overwritten while still being used.
+
+2002-03-18 Jan Hubicka <jh@suse.cz>
+ Andreas Jaeger <aj@suse.de>
+ Andreas Schwab <schwab@suse.de>
+
+ * configure.tgt (x86_64-*-linux-gnu*): Configure i386 as native.
+ * elf_x86_64.sh (ARCH): Set to i386:x86-64
+ set libraries to default to lib64 paths.
+
+2002-03-18 Tom Rix <trix@redhat.com>
+
+ * Makefile.am : Add eaix5ppc and eaix5rs6, AIX 5 support.
+ * configure.tgt : Same.
+ * emulparms/aix5ppc.sh : New file. For eaix5ppc.
+ * emulparms/aix5rs6.sh : New file. For eaix5rs6.
+ * emulparms/aixppc.sh : OUPUT_FORMAT_32BIT and OUTPUT_FORMAT_64BIT
+ emulation parameters for better -b32, -b64 support.
+ * emulparms/aixrs6.sh : Same.
+ * emulparms/ppcmacos.sh : Same.
+ * emultempl/aix.em (choose_target) : Use new emulation parameters
+ OUTPUT_FORMAT_32BIT and OUTPUT_FORMAT_64BIT.
+ * Makefile.in : Regenerate.
+
+2002-03-18 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/fr.po: Updated version.
+
+2002-03-18 Alan Modra <amodra@bigpond.net.au>
+
+ * ldmain.c (main): Move .text readonly flag fudges from here..
+ * ldlang.c (lang_process): ..to here.
+
+2002-03-14 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (lang_check): Remove the word size check added in last
+ change. Treat emitrelocations case as for relocatable links.
+
+2002-03-13 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/fr.po: Updated version.
+
+2002-03-13 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (lang_check): Do relocatable link checks first, so that
+ warn_mismatch can't override. Check compatible and word size too.
+
+2002-03-07 Daniel Jacobowitz <drow@mvista.com>
+
+ * ld.texinfo: Wrap @menu in @ifnottex, not @ifinfo.
+
+2002-03-05 Jakub Jelinek <jakub@redhat.com>
+
+ * scripttempl/elf.sc: Only use DATA_SEGMENT_END() together with
+ DATA_SEGMENT_ALIGN.
+
+2002-03-04 H.J. Lu <hjl@gnu.org>
+
+ * scripttempl/elf.sc: Put .preinit_array, .init_array and
+ .fini_array in the data segment.
+
+2002-03-04 Alan Modra <amodra@bigpond.net.au>
+
+ * scripttempl/elf.sc: Correct syntax errors in 2002-03-01 commit.
+
+2002-03-01 David Mosberger <davidm@hpl.hp.com>
+
+ * scripttempl/elf.sc (SECTIONS): Add entries for .preinit_array,
+ .init_array, and .fini_array.
+
+2002-02-20 Andreas Schwab <schwab@suse.de>
+
+ * emulparams/elf64_ia64.sh (OTHER_READONLY_SECTIONS): Don't fold
+ .IA64_unwind* in a relocatable link.
+
+2002-02-20 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * NEWS: Mark 2.12 branch.
+
+2002-02-19 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * emulparams/elf64_s390.sh (ARCH): Change to "s390:64-bit".
+ * emulparams/elf_s390.sh (ARCH): Change to "s390:31-bit".
+
+2002-02-18 Tom Rix <trix@redhat.com>
+
+ * emultempl/aix.em (gld*_parse_args): Add -brtl support.
+ (gld*_before_allocation): Same.
+ (gld*_create_output_section_statements): Generate
+ __rtinit if run time linking. Add librtl.a to the link.
+ (gld*_read_file): Clean.
+
+2002-02-18 Alan Modra <amodra@bigpond.net.au>
+
+ * emulparams/elf64ppc.sh (OTHER_TEXT_SECTIONS): Define.
+
+2002-02-18 David O'Brien <obrien@FreeBSD.org>
+
+ * Makefile.am: Add new files earmelf_fbsd, eelf32ppc_fbsd,
+ eelf_i386_fbsd, eelf64_ia64_fbsd, eelf_x86_64_fbsd, eelf64_sparc_fbsd,
+ and eelf64alpha_fbsd.
+ * Makefile.in: Regenerate.
+ * configure.tgt(sparc64-*-freebsd, ia64-*-freebsd, i[3456]86-*-freebsd,
+ x86_64-*-freebsd, arm-*-freebsd, alpha*-*-freebsd, powerpc-*-freebsd):
+ use a FreeBSD-specific emulation rather than the psABI one.
+ * emulparams/elf_fbsd.sh (ELF_INTERPRETER_NAME): Set appropriate value
+ for all FreeBSD ELF systems.
+ * emulparams/armelf_fbsd.sh: Bridge elf_fbsd.sh and the "native" psABI
+ emulation.
+ * emulparams/elf32ppc_fbsd.sh: Likewise.
+ * emulparams/elf64_ia64_fbsd.sh: Likewise.
+ * emulparams/elf64_sparc_fbsd.sh: Likewise.
+ * emulparams/elf64alpha_fbsd.sh: Likewise.
+ * emulparams/elf_i386_fbsd.sh: Likewise.
+ * emulparams/elf_x86_64_fbsd.sh: Likewise.
+
+2002-02-18 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/tr.po: Updated version.
+
+2002-02-18 Alan Modra <amodra@bigpond.net.au>
+
+ * ld.texinfo (Output Section Fill): Fix amateur texinfo.
+ (FILL): Likewise.
+
+2002-02-17 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * emultempl/mmo.em (mmo_after_open): Don't call
+ _bfd_mmix_check_all_relocs when producing ELF output.
+
+2002-02-15 Richard Henderson <rth@redhat.com>
+
+ * emulparams/elf64alpha.sh (NOP): Adjust for big-endian
+ definition. Emit a unop+nop pair.
+
+2002-02-15 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * emultempl/mmix-elfnmmo.em (mmix_after_allocation): Also check
+ for presence of .MMIX.reg_contents.linker_allocated before early
+ exit.
+
+ * NEWS: Mention support for MMIX.
+
+2002-02-15 Alan Modra <amodra@bigpond.net.au>
+
+ Support arbitrary length fill patterns.
+ * ld.texinfo (Output Section Fill): Describe fill expressions.
+ (FILL): Refer to the above.
+ * ldexp.h (etree_value_type): Add "str" field.
+ (union etree_union): Add "str" to "value" struct.
+ (exp_bigintop): Declare.
+ (exp_get_fill): Declare.
+ * ldexp.c: Include "safe-ctype.h".
+ (exp_intop): Set value.str to NULL.
+ (exp_bigintop): New function.
+ (new_rel): Pass in "str", and set new.str from it.
+ (new_rel_from_section): Set new.str to NULL.
+ (fold_name): Adjust calls to new_rel.
+ (exp_fold_tree): Likewise.
+ (exp_get_fill): New function.
+ * ldgram.y (struct big_int bigint, fill_type *fill): New.
+ (INT): Returns a "bigint". Adjust all code handling INTs.
+ (fill_opt): Returns a "fill".
+ (fill_exp): Split out of fill_opt, use for FILL.
+ * ldlang.h (struct _fill_type): New.
+ (fill_type): Move typedef to ldexp.h.
+ (lang_output_section_statement_type): "fill" is now a pointer.
+ (lang_fill_statement_type): Likewise.
+ (lang_padding_statement_type): Likewise.
+ (lang_add_fill): Now takes a "fill_type *" param.
+ (lang_leave_output_section_statement): Likewise.
+ (lang_do_assignments): Likewise.
+ (lang_size_sections): Likewise.
+ (lang_leave_overlay_section): Likewise.
+ (lang_leave_overlay): Likewise.
+ * ldlang.c: Include ldgram.h after ldexp.h.
+ (lang_output_section_statement_lookup): Adjust for fill_type change.
+ (print_fill_statement): Likewise.
+ (print_padding_statement): Likewise.
+ (insert_pad): Now takes a "fill_type *" arg.
+ (size_input_section): Likewise.
+ (lang_size_sections_1): Likewise.
+ (lang_size_sections): Likewise.
+ (lang_do_assignments): Likewise.
+ (lang_add_fill): Likewise.
+ (lang_leave_output_section_statement): Likewise.
+ (lang_leave_overlay_section): Likewise.
+ (lang_leave_overlay): Likewise.
+ Adjust all callers of the above function.
+ * ldlex.l: Include ldgram.h after ldexp.h. Allow hex numbers
+ starting with "0X" as well as "0x". Return bigint.str for hex
+ numbers starting with "0x" or "0X", zero bigint.str otherwise.
+ Always use base 16 for numbers starting with "$".
+ * ldmain.c: Include ldgram.h after ldexp.h.
+ * ldwrite.c (build_link_order): Use bfd_data_link_order in place
+ of bfd_fill_link_order.
+ * pe-dll.c: Adjust lang_do_assignments calls.
+ * emultempl/elf32.em: Likewise.
+ * emultempl/hppaelf.em: Likewise.
+ * emultempl/ppc64elf.em: Likewise.
+ * emultempl/beos.em: Include ldgram.h after ldexp.h, adjust
+ lang_add_assignment call.
+ * emultempl/pe.em: Likewise.
+
+2002-02-14 Phil Edwards <pme@gcc.gnu.org>
+
+ * ld.texinfo (VERSION scripts): Symbol names are globbing patterns.
+ * ldgram.y (lang_new_vers_regex): Rename to lang_new_vers_pattern;
+ the pattern in question is not a regexp.
+ * ldlang.c: Likewise.
+ * ldlang.h: Likewise.
+ * ldlex.l (V_IDENTIFIER): Allow '[', ']', '-', '!', and '^' also.
+
+2002-02-12 Jakub Jelinek <jakub@redhat.com>
+
+ * ldlex.l (DATA_SEGMENT_ALIGN, DATA_SEGMENT_END): New tokens.
+ * ldgram.y (DATA_SEGMENT_ALIGN, DATA_SEGMENT_END): New tokens.
+ (exp): Add DATA_SEGMENT_ALIGN (exp, exp) and DATA_SEGMENT_END (exp).
+ * ldexp.c (exp_data_seg): New variable.
+ (exp_print_token): Handle DATA_SEGMENT_ALIGN and DATA_SEGMENT_END.
+ (fold_binary): Handle DATA_SEGMENT_ALIGN.
+ (exp_fold_tree): Handle DATA_SEGMENT_END.
+ Pass allocation_done when recursing instead of hardcoding
+ lang_allocating_phase_enum.
+ * ldexp.h (exp_data_seg): New.
+ * ldlang.c (lang_size_sections_1): Renamed from lang_size_sections.
+ (lang_size_sections): New.
+ * ld.texinfo (DATA_SEGMENT_ALIGN, DATA_SEGMENT_END): Document.
+ * scripttempl/elf.sc: Use DATA_SEGMENT_ALIGN and DATA_SEGMENT_END
+ if COMMONPAGESIZE is defined.
+ * emulparams/elf_i386.sh (COMMONPAGESIZE): Set to 4K.
+ * emulparams/elf32_sparc.sh (COMMONPAGESIZE): Set to 8K.
+ * emulparams/elf64_sparc.sh (COMMONPAGESIZE): Set to 8K.
+ * emulparams/elf64alpha.sh (COMMONPAGESIZE): Set to 8K.
+ * emulparams/elf64_ia64.sh (COMMONPAGESIZE): Set to 16K for shared
+ libraries only.
+
+2002-02-11 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.in: Regenerate.
+
+2002-02-10 Daniel Jacobowitz <drow@mvista.com>
+
+ * lexsup.c: Remove strtoul declaration.
+
+2002-02-10 Daniel Jacobowitz <drow@mvista.com>
+
+ * ldmain.c: Add prototype for main ().
+ * lexsup.c: Guard declaration of strtoul with HAVE_STDLIB_H.
+ * emultempl/lnk960.em (lnk960_choose_target): Function should
+ take two arguments.
+
+2002-02-10 Alan Modra <amodra@bigpond.net.au>
+
+ * ldlang.c (entry_section): New initialised variable.
+ (lang_finish): Use it.
+ * ldlang.h (entry_section): Declare.
+ * emultempl/ppc64elf.em (gld${EMULATION_NAME}_finish): Set
+ entry_section to ".opd".
+
+2002-02-09 Chris Demetriou <cgd@broadcom.com>
+
+ * ld.texinfo (Options): Add back in -nostdlib documentation,
+ which had been inadvertently removed.
+
+2002-02-09 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * emultempl/mmix-elfnmmo.em (mmix_after_allocation): Adjust
+ register section vma to a sane value after emitting error. Make
+ fatal conditions cause program exit when emitting message.
+
+2002-02-08 Ivan Guzvinec <ivang@opencores.org>
+
+ * configure.tgt: Add or32-*-rtems target.
+
+2002-02-08 Alexandre Oliva <aoliva@redhat.com>
+
+ Contribute sh64-elf.
+ 2002-01-24 Alexandre Oliva <aoliva@redhat.com>
+ * emulparams/shelf32.sh (STACK_ADDR): Define as formerly defined
+ in OTHER_RELOCATABLE_SECTIONS.
+ 2002-01-18 Alexandre Oliva <aoliva@redhat.com>
+ * emulparams/shelf32.sh (STACK_ADDR): Define.
+ (OTHER_RELOCATABLE_SECTIONS): Renamed to...
+ (OTHER_SECTIONS): this. Removed stack settings.
+ * emulparams/shelf64.sh (OTHER_RELOCATABLE_SECTIONS): Do not set.
+ (OTHER_SECTIONS): Reset after sourcing shelf32.sh.
+ 2001-03-12 DJ Delorie <dj@redhat.com>
+ * emultempl/sh64elf.em (sh64_elf_$_before_allocation): Disable
+ relaxing if any shmedia or mixed sections are found.
+ 2001-03-07 DJ Delorie <dj@redhat.com>
+ * emultempl/sh64elf.em (sh64_elf_before_allocation): Pass f to
+ einfo. Gracefully decline to output to non-elf formats.
+ 2001-03-06 Hans-Peter Nilsson <hpn@redhat.com>
+ * emulparams/shelf64.sh (OTHER_RELOCATING_SECTIONS) <.stack>:
+ Default to _end aligned to next multiple of 0x40000, plus 0x40000.
+ * emulparams/shelf32.sh: Ditto.
+ 2001-01-14 Hans-Peter Nilsson <hpn@cygnus.com>
+ * emulparams/shelf32.sh (OTHER_RELOCATING_SECTIONS): Tweak
+ comment.
+ 2001-01-10 Ben Elliston <bje@redhat.com>
+ * emulparams/shelf32.sh (OTHER_RELOCATING_SECTIONS): Avoid
+ non-portable shell constructs. From Hans-Peter Nilsson.
+ 2001-01-09 Hans-Peter Nilsson <hpn@cygnus.com>
+ * emulparams/shelf64.sh (EXTRA_EM_FILE): Define empty.
+ * Makefile.am (eshelf64.c, eshlelf64.c, eshlelf32.c): Adjust
+ dependencies to the shell script include chain.
+ * Makefile.in: Regenerate.
+ 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
+ * emultempl/sh64elf.em: Update and tweak comments.
+ (sh64_elf_${EMULATION_NAME}_after_allocation): Always allocate and
+ make a .cranges section SEC_IN_MEMORY.
+ 2000-12-30 Hans-Peter Nilsson <hpn@cygnus.com>
+ * emultempl/sh64elf.em
+ (sh64_elf_${EMULATION_NAME}_before_allocation): Don't stop when
+ .cranges section found to be necessary; continue and set stored
+ section contents flags for sections with non-mixed contents.
+ Use a struct sh64_section_data container and sh64_elf_section_data
+ to store contents-type flags.
+ Remove unused update of "isec".
+ (sh64_elf_${EMULATION_NAME}_after_allocation): Only process
+ sections marked SHF_SH5_ISA32_MIXED. Use sh64_elf_section_data to
+ access contents-type flags. Assert that the associated container
+ is initialized. Use that container, not elf_gp_size, to hold size
+ of linker-generated cranges contents.
+ 2000-12-18 Hans-Peter Nilsson <hpn@cygnus.com>
+ * emultempl/sh64elf.em
+ (sh64_elf_${EMULATION_NAME}_before_allocation): Exit early if
+ there's already a .cranges section. When section flag difference
+ is found, don't NULL-check cranges a second time. Tweak comments.
+ (sh64_elf_${EMULATION_NAME}_after_allocation): Use size after
+ merging, not max size, as size of ld-generated .cranges contents.
+ Don't set ELF section flags in output section. When checking for
+ needed .cranges descriptors, don't use a variable; compare
+ incoming ELF section flags directly to SHF_SH5_ISA32_MIXED. Tweak
+ comments.
+ 2000-12-18 Hans-Peter Nilsson <hpn@cygnus.com>
+ * emultempl/sh64elf.em: New file.
+ * Makefile.am (eshelf32.c, eshlelf32.c): Adjust dependencies.
+ * Makefile.in: Regenerate.
+ * emulparams/shelf32.sh (OUTPUT_FORMAT): Only set if not set.
+ (OTHER_RELOCATING_SECTIONS): Ditto.
+ (EXTRA_EM_FILE): New, set to sh64elf if not set.
+ * emulparams/shlelf32.sh: Stub out all settings except
+ OUTPUT_FORMAT. Source shelf32.sh.
+ * emulparams/shelf64.sh: Similar, but also keep ELF_SIZE and
+ OTHER_RELOCATING_SECTIONS.
+ (OTHER_RELOCATING_SECTIONS): Remove .cranges.
+ * emulparams/shlelf64.sh: Stub out all settings except
+ OUTPUT_FORMAT. Source shelf64.sh.
+ 2000-12-15 Hans-Peter Nilsson <hpn@cygnus.com>
+ * emulparams/shelf64.sh (OTHER_RELOCATING_SECTIONS): Include
+ .cranges section.
+ (DATA_START_SYMBOLS): Define, provide ___data.
+ (OTHER_READONLY_SYMBOLS): Define, provide ___rodata and align to 8
+ for consecutive .data section.
+ (OTHER_GOT_SECTIONS): Define, align to 8 for consecutive .bss
+ section after .data section.
+ * emulparams/shlelf64.sh: Ditto.
+ * emulparams/shelf32.sh: Ditto.
+ (ALIGNMENT): Define to 8.
+ * emulparams/shelf32.sh: Ditto.
+ 2000-12-12 Hans-Peter Nilsson <hpn@cygnus.com>
+ * configure.tgt (sh64-*-elf*): Assign targ_extra_libpath to get
+ built-in linker scripts.
+ 2000-11-30 Hans-Peter Nilsson <hpn@cygnus.com>
+ * emulparams/shlelf64.sh: New.
+ * emulparams/shelf64.sh: New.
+ * configure.tgt (sh64-*-elf*): Add shelf64 and shlelf64 to
+ targ_extra_emuls.
+ * Makefile.am: Add support for shlelf64 and shelf64.
+ * Makefile.in: Regenerate.
+ 2000-11-29 Hans-Peter Nilsson <hpn@cygnus.com>
+ * configure.tgt (sh64-*-elf*): Add shelf as default.
+ Add shlelf to targ_extra_emuls.
+ 2000-11-24 Hans-Peter Nilsson <hpn@cygnus.com>
+ * emulparams/shelf32.sh: New file.
+ * emulparams/shlelf32.sh: New file.
+ * Makefile.am: Add support for shlelf32 and shelf32.
+ * configure.tgt: Map sh64-*-elf* to shlelf32 and shelf32.
+ * Makefile.in: Regenerate.
+
+2002-02-05 Hans-Peter Nilsson <hp@axis.com>
+
+ * ldlang.c (lang_reset_memory_regions): Rename from
+ reset_memory_regions. Change all callers. Make public.
+ * ldlang.h (lang_reset_memory_regions): Prototype.
+ * emultempl/elf32.em (gld${EMULATION_NAME}_finish): Call
+ lang_reset_memory_regions before lang_size_sections.
+ * emultempl/hppaelf.em (hppaelf_layout_sections_again): Likewise.
+ * emultempl/ppc64elf.em (gld${EMULATION_NAME}_finish): Likewise.
+
+2002-02-04 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * emultempl/mmix-elfnmmo.em (mmix_after_allocation): Use signed
+ arithmetic when checking for too many global registers.
+
+2002-02-02 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * Makefile.am (ALL_EMULATIONS): Add ehppanbsd.o.
+ (ehppanbsd.c): New rule.
+ * Makefile.in: Regenerate.
+ * configure.tgt (hppa*-*-netbsd*): New target.
+ * emulparams/hppalinux.sh: Add comment to check other files
+ that source this file it is modified, and list which
+ files that do.
+ * emulparams/hppanbsd.sh: New file.
+
+2002-02-01 Geoffrey Keating <geoffk@redhat.com>
+
+ * scripttempl/xstormy16.sc: Don't allocate extra space for the
+ stack.
+
+2002-02-01 Hans-Peter Nilsson <hp@bitrange.com>
+
+ Support on-demand global register allocation from
+ R_MMIX_BASE_PLUS_OFFSET relocs.
+ * emultempl/mmix-elfnmmo.em (mmix_after_allocation): Rename from
+ mmix_set_reg_section_vma. Call
+ _bfd_mmix_finalize_linker_allocated_gregs.
+ (mmix_before_allocation): New function.
+ (LDEMUL_AFTER_ALLOCATION): Set to mmix_after_allocation.
+ (LDEMUL_BEFORE_ALLOCATION): Define to mmix_before_allocation.
+ * scripttempl/mmo.sc (.text): Mark .init, .fini as KEEP.
+ (.MMIX.reg_contents): Add .MMIX.reg_contents.linker_allocated
+ before .MMIX.reg_contents.
+ * emultempl/mmo.em (gldmmo_before_allocation): Define to default.
+ (mmo_after_open): New function.
+ (LDEMUL_AFTER_OPEN): Define to mmo_after_open.
+ * emulparams/elf64mmix.sh (OTHER_SECTIONS): Tweak formatting. Add
+ .MMIX.reg_contents.linker_allocated before .MMIX.reg_contents.
+
+2002-01-31 Ivan Guzvinec <ivang@opencores.org>
+
+ * emulparams/or32.sh: New file.
+ * emulparams/or32elf.sh: New file.
+ * scripttempl/or32.sc: New file.
+ * configure.tgt : Add support for or32.
+ * configure: Regenerate
+ * Makefile.am: Add support for or32.
+ * Makefile.in: Regenerate.
+ * NEWS: Mention support for or32.
+ * po/ld.pot: Regenerate.
+
+2002-01-29 Chris Demetriou <cgd@broadcom.com>
+ Mitch Lichtenberg <mpl@broadcom.com>
+
+ * emulparams/elf32bmip.sh (EXTRA_EM_FILE): Define to be mipself.
+ * emultempl/mipself.em: New file to handle MIPS ELF embedded
+ reloc creation (ld --embedded-relocs).
+
+2002-01-27 Daniel Jacobowitz <drow@mvista.com>
+
+ * configure: Regenerated.
+
+2002-01-26 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * Makefile.am (install): Depend on install-info.
+ * Makefile.in: Regenerate.
+
+2002-01-26 Christian Rose <menthos@menthos.com>
+
+ * ldmain.c (main): Use full sentences to ease translation.
+
+2002-01-26 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/fr.po: Updated version.
+
+2002-01-25 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/es.po: Updated version.
+
+2002-01-25 Andreas Jaeger <aj@suse.de>
+
+ * ldlex.l (yy_input): Correct error check.
+
+2002-01-25 Alan Modra <amodra@bigpond.net.au>
+
+ * ldmisc.c (demangle): Put back dots when string not demangled.
+
+2002-01-22 Richard Henderson <rth@redhat.com>
+
+ * emulparams/elf64alpha.sh (NOP): Use unop.
+
+2002-01-21 Andreas Jaeger <aj@suse.de>
+
+ * ldlex.l: Use fread instead of read.
+
+2002-01-21 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * configure.tgt (ia64-*-netbsd*): New target.
+
+2002-01-21 H.J. Lu <hjl@gnu.org>
+
+ * emulparams/elf32btsmip.sh (SHLIB_TEXT_START_ADDR): Change to
+ 0.
+ * emulparams/elf64btsmip.sh (SHLIB_TEXT_START_ADDR): Likewise.
+
+2002-01-18 Andreas Jaeger <aj@suse.de>
+
+ * ldver.c (ldversion): Update year.
+
+2002-01-17 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/ld.pot: Regenerate.
+
+2002-01-16 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (eelf64ppc.c, eelf64lppc.c): Depend on ppc64elf.em.
+ * Makefile.in: Regenerate.
+ * emulparams/elf64ppc.sh (EXTRA_EM_FILE): Define.
+ * emultempl/ppc64elf.em: New file.
+
+2002-01-15 DJ Delorie <dj@redhat.com>
+
+ * scripttempl/pe.sc: Add support for constructor priorities.
+
+2002-01-07 Marek Michalkiewicz <marekm@amelek.gda.pl>
+
+ * emulparams/avr1200.sh (DATA_START): Define as 0x60.
+ * emulparams/avr23xx.sh: Likewise.
+ * emulparams/avr4433.sh: Likewise.
+ * emulparams/avr44x4.sh: Likewise.
+ * emulparams/avr85xx.sh: Likewise.
+ * emulparams/avrmega103.sh: Likewise.
+ * emulparams/avrmega161.sh: Likewise.
+ * emulparams/avrmega603.sh: Likewise.
+ * scripttempl/elf32avr.sc: Use DATA_START instead of 0x60.
+
+2002-01-08 Alexandre Oliva <aoliva@redhat.com>
+
+ * ldlang.c (walk_wild_section): Exclude object file if enclosing
+ archive is excluded.
+
+2002-01-07 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * Makefile.am (ALL_EMULATIONS): Add eshelf_nbsd.o and eshlelf_nbsd.o.
+ (eshelf_nbsd.c): New rule.
+ (eshlelf_nbsd.c): New rule.
+ * Makefile.in: Regenerate.
+ * configure.tgt (sh*le-*-netbsdelf*): New target.
+ (sh*-*-netbsdelf*): New target.
+ * emulparams/shelf.sh: Document that shelf_nbsd.sh sources this file.
+ * emulparams/shelf_nbsd.sh: New emulation.
+ * emulparams/shlelf_nbsd.sh: New emulation.
+
+2002-01-07 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/es.po: New file: Spanish translation.
+ * configure.in (ALL_LINGUAS): Add es.
+ * configure: Regenerate.
+
+2002-01-06 John Marshall <jmarshall@acm.org>
+
+ * ld.texinfo: Note that --emit-relocs is currently only
+ implemented for ELF.
+
+2002-01-05 Alan Modra <amodra@bigpond.net.au>
+
+ * emultempl/elf32.em (gld${EMULATION_NAME}_place_orphan): Make use
+ of bfd_section_list_remove and bfd_section_list_insert macros.
+ * emultempl/pe.em (gld_${EMULATION_NAME}_place_orphan): Likewise.
+ * emultempl/mmo.em (mmo_place_orphan): Likewise.
+
+2002-01-04 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * configure.tgt (x86_64-*-netbsd*): New target.
+
+For older changes see ChangeLog-0001
+
+Local Variables:
+mode: change-log
+left-margin: 8
+fill-column: 74
+version-control: never
+End:
diff --git a/contrib/binutils/ld/ChangeLog-9197 b/contrib/binutils/ld/ChangeLog-9197
index 291326d..9307f33 100644
--- a/contrib/binutils/ld/ChangeLog-9197
+++ b/contrib/binutils/ld/ChangeLog-9197
@@ -7574,7 +7574,7 @@ Tue Oct 8 16:00:57 1991 Per Bothner (bothner at cygnus.com)
* Makefile.in: Add LIB_PATH macro, which if set is used to replace
the SEARCH_DIR commands in the scripts (using ugly sed magic).
This is primarily intended for cross-linking, where you would
- place libaries in a different place than native libraries.
+ place libraries in a different place than native libraries.
Also, emulations made from ldtemplate now use $(srcdir).
* scripttempl/ldglda29k.sc: Change SEARCH_DIR commands to a
conventional form; people can use the Makefile's LIB_PATH to
diff --git a/contrib/binutils/ld/Makefile.am b/contrib/binutils/ld/Makefile.am
index 8247d25..a2f1ac1 100644
--- a/contrib/binutils/ld/Makefile.am
+++ b/contrib/binutils/ld/Makefile.am
@@ -30,8 +30,9 @@ EMUL_EXTRA_OFILES = @EMUL_EXTRA_OFILES@
# (The default is usually /lib:/usr/lib:/usr/local/lib, unless building
# a cross-linker, in which case the default is empty. See genscripts.sh.)
# Otherwise, they are replaced with the ones given in LIB_PATH,
-# which may have the form: LIB_PATH=/lib:/usr/local/lib
-LIB_PATH =
+# which may have the form: LIB_PATH=/lib:/usr/local/lib. This can be set
+# when the linker is configured via the --with-lib-path configure switch.
+LIB_PATH = @LIB_PATH@
BASEDIR = $(srcdir)/..
BFDDIR = $(BASEDIR)/bfd
@@ -117,26 +118,22 @@ ALL_EMULATIONS = \
earmaoutl.o \
earmcoff.o \
earmelf.o \
+ earmelfb.o \
earmelf_fbsd.o \
earmelf_linux.o \
+ earmelfb_linux.o \
earmelf_nbsd.o \
earmelfb_nbsd.o \
earmelf_oabi.o \
+ earmnto.o \
earmnbsd.o \
earmpe.o \
- eavr1200.o \
- eavr23xx.o \
- eavr4433.o \
- eavr44x4.o \
- eavr85xx.o \
- eavrmega103.o \
- eavrmega161.o \
- eavrmega603.o \
- eavr1.o \
eavr2.o \
+ eavr1.o \
eavr3.o \
eavr4.o \
eavr5.o \
+ ecoff_i860.o \
ecoff_sparc.o \
ecrisaout.o \
ecriself.o \
@@ -155,25 +152,34 @@ ALL_EMULATIONS = \
eelf32bmip.o \
eelf32bmipn32.o \
eelf32btsmip.o \
+ eelf32btsmipn32.o \
eelf32ltsmip.o \
+ eelf32ltsmipn32.o \
eelf32ebmip.o \
eelf32elmip.o \
eelf32fr30.o \
eelf32frv.o \
eelf32i370.o \
+ eelf32ip2k.o \
+ eelf32iq2000.o \
+ eelf32iq10.o \
eelf32l4300.o \
eelf32lmip.o \
eelf32lppc.o \
+ eelf32lppcnto.o \
eelf32lppcsim.o \
eelf32mcore.o \
+ eelf32mipswindiss.o \
eelf32openrisc.o \
eelf32ppc.o \
eelf32ppc_fbsd.o \
eelf32ppclinux.o \
+ eelf32ppcnto.o \
eelf32ppcsim.o \
eelf32ppcwindiss.o \
eelf32vax.o \
eelf32xstormy16.o \
+ eelf32xtensa.o \
eelf_i386.o \
eelf_i386_be.o \
eelf_i386_chaos.o \
@@ -186,8 +192,16 @@ ALL_EMULATIONS = \
eh8300h.o \
eh8300s.o \
eh8300elf.o \
+ eh8300hn.o \
+ eh8300sn.o \
+ eh8300sx.o \
eh8300helf.o \
eh8300self.o \
+ eh8300hnelf.o \
+ eh8300snelf.o \
+ eh8300sxelf.o \
+ eh8300sxn.o \
+ eh8300sxnelf.o \
eh8500.o \
eh8500b.o \
eh8500c.o \
@@ -215,6 +229,10 @@ ALL_EMULATIONS = \
ei386pe.o \
ei386pe_posix.o \
elnk960.o \
+ em32relf.o \
+ em32rlelf.o \
+ em32relf_linux.o \
+ em32rlelf_linux.o \
em68hc11elf.o \
em68hc11elfb.o \
em68hc12elf.o \
@@ -238,6 +256,53 @@ ALL_EMULATIONS = \
emipslit.o \
emipslnews.o \
emipspe.o \
+ emsp430x110.o \
+ emsp430x112.o \
+ emsp430x1101.o \
+ emsp430x1111.o \
+ emsp430x1121.o \
+ emsp430x1122.o \
+ emsp430x1132.o \
+ emsp430x122.o \
+ emsp430x123.o \
+ emsp430x1222.o \
+ emsp430x1232.o \
+ emsp430x133.o \
+ emsp430x135.o \
+ emsp430x1331.o \
+ emsp430x1351.o \
+ emsp430x147.o \
+ emsp430x148.o \
+ emsp430x149.o \
+ emsp430x155.o \
+ emsp430x156.o \
+ emsp430x157.o \
+ emsp430x167.o \
+ emsp430x168.o \
+ emsp430x169.o \
+ emsp430x311.o \
+ emsp430x312.o \
+ emsp430x313.o \
+ emsp430x314.o \
+ emsp430x315.o \
+ emsp430x323.o \
+ emsp430x325.o \
+ emsp430x336.o \
+ emsp430x337.o \
+ emsp430x412.o \
+ emsp430x413.o \
+ emsp430xE423.o \
+ emsp430xE425.o \
+ emsp430xE427.o \
+ emsp430xW423.o \
+ emsp430xW425.o \
+ emsp430xW427.o \
+ emsp430x435.o \
+ emsp430x436.o \
+ emsp430x437.o \
+ emsp430x447.o \
+ emsp430x448.o \
+ emsp430x449.o \
enews.o \
ens32knbsd.o \
eor32.o \
@@ -254,6 +319,8 @@ ALL_EMULATIONS = \
esh.o \
eshelf32.o \
eshlelf32.o \
+ eshelf32_linux.o \
+ eshlelf32_linux.o \
eshelf32_nbsd.o \
eshlelf32_nbsd.o \
eshelf.o \
@@ -261,6 +328,8 @@ ALL_EMULATIONS = \
eshlelf_linux.o \
eshelf_nbsd.o \
eshlelf_nbsd.o \
+ eshelf_nto.o \
+ eshlelf_nto.o \
eshl.o \
eshlelf.o \
eshpe.o \
@@ -273,6 +342,9 @@ ALL_EMULATIONS = \
esun4.o \
etic30aout.o \
etic30coff.o \
+ etic3xcoff.o \
+ etic3xcoff_onchip.o \
+ etic4xcoff.o \
etic54xcoff.o \
etic80coff.o \
evanilla.o \
@@ -281,6 +353,7 @@ ALL_EMULATIONS = \
evsta.o \
ew65.o \
ez8001.o \
+ eelf32frvfd.o \
ez8002.o
ALL_64_EMULATIONS = \
@@ -337,11 +410,15 @@ EMULATION_FILES = emultempl/pe.em emultempl/armcoff.em
POTFILES = $(CFILES) $(HFILES) $(EMULATION_FILES)
po/POTFILES.in: @MAINT@ Makefile
- for file in $(POTFILES); do echo $$file; done | sort > tmp \
+ for f in $(POTFILES); do echo $$f; done | LC_COLLATE= sort > tmp \
&& mv tmp $(srcdir)/po/POTFILES.in
ldmain.o: ldmain.c config.status
- $(COMPILE) -c -DDEFAULT_EMULATION='"$(EMUL)"' -DSCRIPTDIR='"$(scriptdir)"' -DTARGET='"@target@"' $(srcdir)/ldmain.c
+ $(COMPILE) -c -DDEFAULT_EMULATION='"$(EMUL)"' \
+ -DSCRIPTDIR='"$(scriptdir)"' -DBINDIR='"$(bindir)"' \
+ -DTOOLBINDIR='"$(tooldir)/bin"' \
+ -DTARGET='"@target@"' @TARGET_SYSTEM_ROOT_DEFINE@ \
+ $(srcdir)/ldmain.c
ldemul-list.h: Makefile
(echo "/* This file is automatically generated. DO NOT EDIT! */";\
@@ -363,8 +440,9 @@ stringify.sed: ${srcdir}/emultempl/$(STRINGIFY)
# These all start with e so 'make clean' can find them.
-GENSCRIPTS = $(SHELL) $(srcdir)/genscripts.sh ${srcdir} ${libdir} "${exec_prefix}" @host@ @target@ @target_alias@ "@EMULATION_LIBPATH@" "@NATIVE_LIB_DIRS@"
+GENSCRIPTS = LIB_PATH='${LIB_PATH}' $(SHELL) $(srcdir)/genscripts.sh ${srcdir} ${libdir} "${exec_prefix}" @host@ @target@ @target_alias@ "@EMULATION_LIBPATH@" "@NATIVE_LIB_DIRS@" @use_sysroot@
GEN_DEPENDS = $(srcdir)/genscripts.sh stringify.sed
+
@TDIRS@
ea29k.c: $(srcdir)/emulparams/a29k.sh \
@@ -392,6 +470,10 @@ earmelf.c: $(srcdir)/emulparams/armelf.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/armelf.em \
$(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} armelf "$(tdir_armelf)"
+earmelfb.c: $(srcdir)/emulparams/armelfb.sh $(srcdir)/emulparams/armelf.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/armelf.em \
+ $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} armelfb "$(tdir_armelfb)"
earmelf_oabi.c: $(srcdir)/emulparams/armelf_oabi.sh \
$(srcdir)/emultempl/armelf_oabi.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} armelf_oabi "$(tdir_armelf)"
@@ -404,6 +486,11 @@ earmelf_linux.c: $(srcdir)/emulparams/armelf_linux.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/armelf.em \
$(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} armelf_linux "$(tdir_armelf_linux)"
+earmelfb_linux.c: $(srcdir)/emulparams/armelfb_linux.sh \
+ $(srcdir)/emulparams/armelf_linux.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/armelf.em \
+ $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} armelfb_linux "$(tdir_armelfb_linux)"
earmelf_nbsd.c: $(srcdir)/emulparams/armelf_nbsd.sh \
$(srcdir)/emulparams/armelf.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/armelf.em \
@@ -427,64 +514,39 @@ earmcoff.c: $(srcdir)/emulparams/armcoff.sh \
earmnbsd.c: $(srcdir)/emulparams/armnbsd.sh \
$(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/aout.sc ${GEN_DEPENDS}
${GENSCRIPTS} armnbsd "$(tdir_armnbsd)"
+earmnto.c: $(srcdir)/emulparams/armnto.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/armelf.em \
+ $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} armnto "$(tdir_armnto)"
earm_epoc_pe.c: $(srcdir)/emulparams/arm_epoc_pe.sh \
$(srcdir)/emultempl/pe.em $(srcdir)/scripttempl/epocpe.sc ${GEN_DEPENDS}
${GENSCRIPTS} arm_epoc_pe "$(tdir_armpe)"
earmpe.c: $(srcdir)/emulparams/armpe.sh \
$(srcdir)/emultempl/pe.em $(srcdir)/scripttempl/pe.sc ${GEN_DEPENDS}
${GENSCRIPTS} armpe "$(tdir_armpe)"
-eavr85xx.c: $(srcdir)/emulparams/avr85xx.sh \
- $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32avr.sc \
- ${GEN_DEPENDS}
- ${GENSCRIPTS} avr85xx "$(tdir_avr85xx)"
-eavr1200.c: $(srcdir)/emulparams/avr1200.sh \
- $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32avr.sc \
- ${GEN_DEPENDS}
- ${GENSCRIPTS} avr1200 "$(tdir_avr85xx)"
-eavr23xx.c: $(srcdir)/emulparams/avr23xx.sh \
- $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32avr.sc \
- ${GEN_DEPENDS}
- ${GENSCRIPTS} avr23xx "$(tdir_avr85xx)"
-eavr44x4.c: $(srcdir)/emulparams/avr44x4.sh \
- $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32avr.sc \
- ${GEN_DEPENDS}
- ${GENSCRIPTS} avr44x4 "$(tdir_avr85xx)"
-eavr4433.c: $(srcdir)/emulparams/avr4433.sh \
- $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32avr.sc \
- ${GEN_DEPENDS}
- ${GENSCRIPTS} avr4433 "$(tdir_avr85xx)"
-eavrmega603.c: $(srcdir)/emulparams/avrmega603.sh \
- $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32avr.sc \
- ${GEN_DEPENDS}
- ${GENSCRIPTS} avrmega603 "$(tdir_avr85xx)"
-eavrmega103.c: $(srcdir)/emulparams/avrmega103.sh \
- $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32avr.sc \
- ${GEN_DEPENDS}
- ${GENSCRIPTS} avrmega103 "$(tdir_avr85xx)"
-eavrmega161.c: $(srcdir)/emulparams/avrmega161.sh \
- $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32avr.sc \
- ${GEN_DEPENDS}
- ${GENSCRIPTS} avrmega161 "$(tdir_avr85xx)"
-eavr1.c: $(srcdir)/emulparams/avr1.sh \
+eavr2.c: $(srcdir)/emulparams/avr2.sh \
$(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/avr.sc \
${GEN_DEPENDS}
- ${GENSCRIPTS} avr1 "$(tdir_avr85xx)"
-eavr2.c: $(srcdir)/emulparams/avr2.sh \
+ ${GENSCRIPTS} avr2 "$(tdir_avr2)"
+eavr1.c: $(srcdir)/emulparams/avr1.sh \
$(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/avr.sc \
${GEN_DEPENDS}
- ${GENSCRIPTS} avr2 "$(tdir_avr85xx)"
+ ${GENSCRIPTS} avr1 "$(tdir_avr2)"
eavr3.c: $(srcdir)/emulparams/avr3.sh \
$(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/avr.sc \
${GEN_DEPENDS}
- ${GENSCRIPTS} avr3 "$(tdir_avr85xx)"
+ ${GENSCRIPTS} avr3 "$(tdir_avr2)"
eavr4.c: $(srcdir)/emulparams/avr4.sh \
$(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/avr.sc \
${GEN_DEPENDS}
- ${GENSCRIPTS} avr4 "$(tdir_avr85xx)"
+ ${GENSCRIPTS} avr4 "$(tdir_avr2)"
eavr5.c: $(srcdir)/emulparams/avr5.sh \
$(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/avr.sc \
${GEN_DEPENDS}
- ${GENSCRIPTS} avr5 "$(tdir_avr85xx)"
+ ${GENSCRIPTS} avr5 "$(tdir_avr2)"
+ecoff_i860.c: $(srcdir)/emulparams/coff_i860.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/i860coff.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} coff_i860 "$(tdir_coff_i860)"
ecoff_sparc.c: $(srcdir)/emulparams/coff_sparc.sh \
$(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/sparccoff.sc ${GEN_DEPENDS}
${GENSCRIPTS} coff_sparc "$(tdir_coff_sparc)"
@@ -522,9 +584,17 @@ eelf32xstormy16.c: $(srcdir)/emulparams/elf32xstormy16.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/needrelax.em \
$(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32xstormy16 "$(tdir_xstormy16)"
+eelf32am33lin.c: $(srcdir)/emulparams/elf32am33lin.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} elf32am33lin "$(tdir_mn10300)"
eelf32vax.c: $(srcdir)/emulparams/elf32vax.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32vax "$(tdir_elf32vax)"
+eelf32xtensa.c: $(srcdir)/emulparams/elf32xtensa.sh \
+ $(srcdir)/emulparams/xtensa-config.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/xtensaelf.em \
+ $(srcdir)/scripttempl/elfxtensa.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} elf32xtensa "$(tdir_elf32xtensa)"
eelf32fr30.c: $(srcdir)/emulparams/elf32fr30.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32fr30 "$(tdir_fr30)"
@@ -537,6 +607,15 @@ eelf32mcore.c: $(srcdir)/emulparams/elf32mcore.sh \
em32relf.c: $(srcdir)/emulparams/m32relf.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} m32relf "$(tdir_m32r)"
+em32rlelf.c: $(srcdir)/emulparams/m32rlelf.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} m32rlelf "$(tdir_m32rlelf)"
+em32relf_linux.c: $(srcdir)/emulparams/m32relf_linux.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} m32relf_linux "$(tdir_m32relf_linux)"
+em32rlelf_linux.c: $(srcdir)/emulparams/m32rlelf_linux.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} m32rlelf_linux "$(tdir_m32rlelf_linux)"
eelf32_sparc.c: $(srcdir)/emulparams/elf32_sparc.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32_sparc "$(tdir_elf32_sparc)"
@@ -547,73 +626,101 @@ eelf32_i960.c: $(srcdir)/emulparams/elf32_i960.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32_i960 "$(tdir_elf32_i960)"
eelf32b4300.c: $(srcdir)/emulparams/elf32b4300.sh \
- $(srcdir)/emulparams/elf32bmip.sh \
+ $(srcdir)/emulparams/elf32bmip.sh $(srcdir)/emultempl/mipself.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32b4300 "$(tdir_elf32b4300)"
eelf32bmip.c: $(srcdir)/emulparams/elf32bmip.sh \
+ $(srcdir)/emultempl/mipself.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32bmip "$(tdir_elf32bmip)"
eelf32bsmip.c: $(srcdir)/emulparams/elf32bsmip.sh \
- $(srcdir)/emulparams/elf32bmip.sh \
+ $(srcdir)/emulparams/elf32bmip.sh $(srcdir)/emultempl/irix.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32bsmip "$(tdir_elf32bsmip)"
eelf32btsmip.c: $(srcdir)/emulparams/elf32btsmip.sh \
- $(srcdir)/emulparams/elf32bmip.sh \
+ $(srcdir)/emulparams/elf32bmip.sh $(srcdir)/emultempl/mipself.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32btsmip "$(tdir_elf32btsmip)"
+eelf32btsmipn32.c: $(srcdir)/emulparams/elf32btsmipn32.sh \
+ $(srcdir)/emulparams/elf32bmip.sh $(srcdir)/emultempl/mipself.em \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} elf32btsmipn32 "$(tdir_elf32btsmipn32)"
eelf32ltsmip.c: $(srcdir)/emulparams/elf32ltsmip.sh \
$(srcdir)/emulparams/elf32btsmip.sh $(srcdir)/emulparams/elf32bmip.sh \
+ $(srcdir)/emultempl/mipself.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32ltsmip "$(tdir_elf32ltsmip)"
+eelf32ltsmipn32.c: $(srcdir)/emulparams/elf32ltsmipn32.sh \
+ $(srcdir)/emulparams/elf32btsmip.sh $(srcdir)/emulparams/elf32bmip.sh \
+ $(srcdir)/emultempl/mipself.em \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} elf32ltsmipn32 "$(tdir_elf32ltsmipn32)"
eelf32ebmip.c: $(srcdir)/emulparams/elf32ebmip.sh \
- $(srcdir)/emulparams/elf32bmip.sh \
+ $(srcdir)/emulparams/elf32bmip.sh $(srcdir)/emultempl/mipself.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32ebmip "$(tdir_elf32ebmip)"
eelf32elmip.c: $(srcdir)/emulparams/elf32elmip.sh \
$(srcdir)/emulparams/elf32lmip.sh $(srcdir)/emulparams/elf32bmip.sh \
+ $(srcdir)/emultempl/mipself.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32elmip "$(tdir_elf32elmip)"
eelf32bmipn32.c: $(srcdir)/emulparams/elf32bmipn32.sh \
+ $(srcdir)/emultempl/irix.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32bmipn32 "$(tdir_elf32bmipn32)"
eelf32l4300.c: $(srcdir)/emulparams/elf32l4300.sh \
$(srcdir)/emulparams/elf32b4300.sh $(srcdir)/emulparams/elf32bmip.sh \
+ $(srcdir)/emultempl/mipself.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32l4300 "$(tdir_elf32l4300)"
eelf32lmip.c: $(srcdir)/emulparams/elf32lmip.sh \
- $(srcdir)/emulparams/elf32bmip.sh \
+ $(srcdir)/emulparams/elf32bmip.sh $(srcdir)/emultempl/mipself.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32lmip "$(tdir_elf32lmip)"
+eelf32mipswindiss.c: $(srcdir)/emulparams/elf32mipswindiss.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} elf32mipswindiss "$(tdir_elf32mipswindiss)"
eelf32lppc.c: $(srcdir)/emulparams/elf32lppc.sh \
- $(srcdir)/emulparams/elf32ppc.sh \
+ $(srcdir)/emulparams/elf32ppc.sh $(srcdir)/emultempl/ppc32elf.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32lppc "$(tdir_elf32lppc)"
+eelf32lppcnto.c: $(srcdir)/emulparams/elf32lppcnto.sh \
+ $(srcdir)/emulparams/elf32ppc.sh $(srcdir)/emultempl/ppc32elf.em \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} elf32lppcnto "$(tdir_elf32lppcnto)"
eelf32lppcsim.c: $(srcdir)/emulparams/elf32lppcsim.sh \
$(srcdir)/emulparams/elf32lppc.sh $(srcdir)/emulparams/elf32ppc.sh \
+ $(srcdir)/emultempl/ppc32elf.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32lppcsim "$(tdir_elf32lppcsim)"
-eelf32ppcwindiss.c: $(srcdir)/emulparams/elf32ppcwindiss.sh ${GEN_DEPENDS}
+eelf32ppcnto.c: $(srcdir)/emulparams/elf32ppcnto.sh \
+ $(srcdir)/emulparams/elf32ppc.sh $(srcdir)/emultempl/ppc32elf.em \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} elf32ppcnto "$(tdir_elf32ppcnto)"
+eelf32ppcwindiss.c: $(srcdir)/emulparams/elf32ppcwindiss.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32ppcwindiss "$(tdir_elf32ppcwindiss)"
eelf32lsmip.c: $(srcdir)/emulparams/elf32lsmip.sh \
$(srcdir)/emulparams/elf32lmip.sh $(srcdir)/emulparams/elf32bmip.sh \
+ $(srcdir)/emultempl/mipself.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32lsmip "$(tdir_elf32lsmip)"
eelf32openrisc.c: $(srcdir)/emulparams/elf32openrisc.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32openrisc "$(tdir_openrisc)"
-eelf32ppc.c: $(srcdir)/emulparams/elf32ppc.sh \
+eelf32ppc.c: $(srcdir)/emulparams/elf32ppc.sh $(srcdir)/emultempl/ppc32elf.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32ppc "$(tdir_elf32ppc)"
eelf32ppc_fbsd.c: $(srcdir)/emulparams/elf32ppc_fbsd.sh \
- $(srcdir)/emulparams/elf32ppc.sh \
+ $(srcdir)/emulparams/elf32ppc.sh $(srcdir)/emultempl/ppc32elf.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32ppc_fbsd "$(tdir_elf32ppc_fbsd)"
eelf32ppcsim.c: $(srcdir)/emulparams/elf32ppcsim.sh \
- $(srcdir)/emulparams/elf32ppc.sh \
+ $(srcdir)/emulparams/elf32ppc.sh $(srcdir)/emultempl/ppc32elf.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32ppcsim "$(tdir_elf32ppcsim)"
eelf32ppclinux.c: $(srcdir)/emulparams/elf32ppclinux.sh \
- $(srcdir)/emulparams/elf32ppc.sh \
+ $(srcdir)/emulparams/elf32ppc.sh $(srcdir)/emultempl/ppc32elf.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32ppclinux "$(tdir_elf32ppclinux)"
eelf64ppc.c: $(srcdir)/emulparams/elf64ppc.sh $(srcdir)/emultempl/ppc64elf.em \
@@ -626,6 +733,15 @@ eelf64lppc.c: $(srcdir)/emulparams/elf64lppc.sh \
eelf32i370.c: $(srcdir)/emulparams/elf32i370.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elfi370.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf32i370 "$(tdir_elf32i370)"
+eelf32ip2k.c: $(srcdir)/emulparams/elf32ip2k.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/ip2k.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} elf32ip2k "$(tdir_ip2k)"
+eelf32iq2000.c: $(srcdir)/emulparams/elf32iq2000.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/iq2000.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} elf32iq2000 "$(tdir_iq2000)"
+eelf32iq10.c: $(srcdir)/emulparams/elf32iq10.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/iq2000.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} elf32iq10 "$(tdir_iq10)"
eelf64alpha.c: $(srcdir)/emulparams/elf64alpha.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf64alpha "$(tdir_elf64alpha)"
@@ -645,12 +761,14 @@ eelf64_aix.c: $(srcdir)/emulparams/elf64_aix.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf64_aix "$(tdir_elf64_aix)"
eelf64_ia64.c: $(srcdir)/emulparams/elf64_ia64.sh \
- $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/needrelax.em \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/ia64elf.em \
+ $(srcdir)/emultempl/needrelax.em \
$(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf64_ia64 "$(tdir_elf64_ia64)"
eelf64_ia64_fbsd.c: $(srcdir)/emulparams/elf64_ia64_fbsd.sh \
$(srcdir)/emulparams/elf64_ia64.sh \
- $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/needrelax.em \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/emultempl/ia64elf.em \
+ $(srcdir)/emultempl/needrelax.em \
$(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf64_ia64_fbsd "$(tdir_elf64_ia64_fbsd)"
eelf64_s390.c: $(srcdir)/emulparams/elf64_s390.sh \
@@ -664,7 +782,7 @@ eelf64_sparc_fbsd.c: $(srcdir)/emulparams/elf64_sparc_fbsd.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf64_sparc_fbsd "$(tdir_elf64_sparc_fbsd)"
eelf64bmip.c: $(srcdir)/emulparams/elf64bmip.sh \
- $(srcdir)/emulparams/elf32bmipn32.sh \
+ $(srcdir)/emulparams/elf32bmipn32.sh $(srcdir)/emultempl/irix.em \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} elf64bmip "$(tdir_elf64bmip)"
eelf64mmix.c: $(srcdir)/emulparams/elf64mmix.sh \
@@ -724,6 +842,18 @@ eh8300h.c: $(srcdir)/emulparams/h8300h.sh \
eh8300s.c: $(srcdir)/emulparams/h8300s.sh \
$(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/h8300s.sc ${GEN_DEPENDS}
${GENSCRIPTS} h8300s "$(tdir_h8300s)"
+eh8300hn.c: $(srcdir)/emulparams/h8300hn.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/h8300hn.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} h8300hn "$(tdir_h8300hn)"
+eh8300sn.c: $(srcdir)/emulparams/h8300sn.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/h8300sn.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} h8300sn "$(tdir_h8300sn)"
+eh8300sx.c: $(srcdir)/emulparams/h8300sx.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/h8300sx.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} h8300sx "$(tdir_h8300sx)"
+eh8300sxn.c: $(srcdir)/emulparams/h8300sxn.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/h8300sxn.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} h8300sxn "$(tdir_h8300sxn)"
eh8300elf.c: $(srcdir)/emulparams/h8300elf.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} h8300elf "$(tdir_h8300elf)"
@@ -735,6 +865,22 @@ eh8300self.c: $(srcdir)/emulparams/h8300self.sh \
$(srcdir)/emulparams/h8300elf.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} h8300self "$(tdir_h8300self)"
+eh8300hnelf.c: $(srcdir)/emulparams/h8300hnelf.sh \
+ $(srcdir)/emulparams/h8300elf.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} h8300hnelf "$(tdir_h8300hnelf)"
+eh8300snelf.c: $(srcdir)/emulparams/h8300snelf.sh \
+ $(srcdir)/emulparams/h8300elf.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} h8300snelf "$(tdir_h8300snelf)"
+eh8300sxelf.c: $(srcdir)/emulparams/h8300sxelf.sh \
+ $(srcdir)/emulparams/h8300elf.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} h8300sxelf "$(tdir_h8300sxelf)"
+eh8300sxnelf.c: $(srcdir)/emulparams/h8300sxnelf.sh \
+ $(srcdir)/emulparams/h8300elf.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} h8300sxnelf "$(tdir_h8300sxnelf)"
eh8500.c: $(srcdir)/emulparams/h8500.sh \
$(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/h8500.sc ${GEN_DEPENDS}
${GENSCRIPTS} h8500 "$(tdir_h8500)"
@@ -825,16 +971,20 @@ elnk960.c: $(srcdir)/emulparams/lnk960.sh \
$(srcdir)/emultempl/lnk960.em $(srcdir)/scripttempl/i960.sc ${GEN_DEPENDS}
${GENSCRIPTS} lnk960 "$(tdir_lnk960)"
em68hc11elf.c: $(srcdir)/emulparams/m68hc11elf.sh \
- $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elfm68hc11.sc ${GEN_DEPENDS}
+ $(srcdir)/emultempl/m68hc1xelf.em $(srcdir)/emultempl/elf32.em \
+ $(srcdir)/scripttempl/elfm68hc11.sc ${GEN_DEPENDS}
${GENSCRIPTS} m68hc11elf "$(tdir_m68hc11)"
em68hc11elfb.c: $(srcdir)/emulparams/m68hc11elfb.sh \
- $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elfm68hc11.sc ${GEN_DEPENDS}
+ $(srcdir)/emultempl/m68hc1xelf.em $(srcdir)/emultempl/elf32.em \
+ $(srcdir)/scripttempl/elfm68hc11.sc ${GEN_DEPENDS}
${GENSCRIPTS} m68hc11elfb "$(tdir_m68hc11b)"
em68hc12elf.c: $(srcdir)/emulparams/m68hc12elf.sh \
- $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elfm68hc12.sc ${GEN_DEPENDS}
+ $(srcdir)/emultempl/m68hc1xelf.em $(srcdir)/emultempl/elf32.em \
+ $(srcdir)/scripttempl/elfm68hc12.sc ${GEN_DEPENDS}
${GENSCRIPTS} m68hc12elf "$(tdir_m68hc12)"
em68hc12elfb.c: $(srcdir)/emulparams/m68hc12elfb.sh \
- $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elfm68hc12.sc ${GEN_DEPENDS}
+ $(srcdir)/emultempl/m68hc1xelf.em $(srcdir)/emultempl/elf32.em \
+ $(srcdir)/scripttempl/elfm68hc12.sc ${GEN_DEPENDS}
${GENSCRIPTS} m68hc12elfb "$(tdir_m68hc12b)"
em68k4knbsd.c: $(srcdir)/emulparams/m68k4knbsd.sh \
$(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/aout.sc ${GEN_DEPENDS}
@@ -903,11 +1053,200 @@ emn10300.c: $(srcdir)/emulparams/mn10300.sh \
emn10200.c: $(srcdir)/emulparams/mn10200.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} mn10200 "$(tdir_mn10200)"
+emsp430x110.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x110 "$(tdir_msp430x110)" msp430all
+emsp430x112.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x112 "$(tdir_msp430x112)" msp430all
+emsp430x1101.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x1101 "$(tdir_msp430x1101)" msp430all
+emsp430x1111.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x1111 "$(tdir_msp430x1111)" msp430all
+emsp430x1121.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x1121 "$(tdir_msp430x1121)" msp430all
+emsp430x1122.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x1122 "$(tdir_msp430x1122)" msp430all
+emsp430x1132.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x1132 "$(tdir_msp430x1132)" msp430all
+emsp430x122.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x122 "$(tdir_msp430x122)" msp430all
+emsp430x123.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x123 "$(tdir_msp430x123)" msp430all
+emsp430x1222.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x1222 "$(tdir_msp430x1222)" msp430all
+emsp430x1232.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x1232 "$(tdir_msp430x1232)" msp430all
+emsp430x133.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x133 "$(tdir_msp430x133)" msp430all
+emsp430x135.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x135 "$(tdir_msp430x135)" msp430all
+emsp430x1331.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x1331 "$(tdir_msp430x1331)" msp430all
+emsp430x1351.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x1351 "$(tdir_msp430x1351)" msp430all
+emsp430x147.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x147 "$(tdir_msp430x147)" msp430all
+emsp430x148.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x148 "$(tdir_msp430x148)" msp430all
+emsp430x149.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x149 "$(tdir_msp430x149)" msp430all
+emsp430x155.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x155 "$(tdir_msp430x155)" msp430all
+emsp430x156.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x156 "$(tdir_msp430x156)" msp430all
+emsp430x157.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x157 "$(tdir_msp430x157)" msp430all
+emsp430x167.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x167 "$(tdir_msp430x167)" msp430all
+emsp430x168.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x168 "$(tdir_msp430x168)" msp430all
+emsp430x169.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x169 "$(tdir_msp430x169)" msp430all
+emsp430x311.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430_3.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x311 "$(tdir_msp430x311)" msp430all
+emsp430x312.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430_3.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x312 "$(tdir_msp430x312)" msp430all
+emsp430x313.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430_3.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x313 "$(tdir_msp430x313)" msp430all
+emsp430x314.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430_3.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x314 "$(tdir_msp430x314)" msp430all
+emsp430x315.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430_3.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x315 "$(tdir_msp430x315)" msp430all
+emsp430x323.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430_3.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x323 "$(tdir_msp430x323)" msp430all
+emsp430x325.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430_3.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x325 "$(tdir_msp430x325)" msp430all
+emsp430x336.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430_3.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x336 "$(tdir_msp430x336)" msp430all
+emsp430x337.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430_3.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x337 "$(tdir_msp430x337)" msp430all
+emsp430x412.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x412 "$(tdir_msp430x412)" msp430all
+emsp430x413.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x413 "$(tdir_msp430x413)" msp430all
+emsp430xE423.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430xE423 "$(tdir_msp430xE423)" msp430all
+emsp430xE425.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430xE425 "$(tdir_msp430xE425)" msp430all
+emsp430xE427.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430xE427 "$(tdir_msp430xE427)" msp430all
+emsp430xW423.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430xW423 "$(tdir_msp430xW423)" msp430all
+emsp430xW425.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430xW425 "$(tdir_msp430xW425)" msp430all
+emsp430xW427.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430xW427 "$(tdir_msp430xW427)" msp430all
+emsp430x435.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x435 "$(tdir_msp430x435)" msp430all
+emsp430x436.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x436 "$(tdir_msp430x436)" msp430all
+emsp430x437.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x437 "$(tdir_msp430x437)" msp430all
+emsp430x447.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x447 "$(tdir_msp430x447)" msp430all
+emsp430x448.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x448 "$(tdir_msp430x448)" msp430all
+emsp430x449.c: $(srcdir)/emulparams/msp430all.sh \
+ $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/elf32msp430.sc \
+ ${GEN_DEPENDS}
+ ${GENSCRIPTS} msp430x449 "$(tdir_msp430x449)" msp430all
enews.c: $(srcdir)/emulparams/news.sh \
$(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/aout.sc ${GEN_DEPENDS}
${GENSCRIPTS} news "$(tdir_news)"
ens32knbsd.c: $(srcdir)/emulparams/ns32knbsd.sh \
- $(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/aout.sc ${GEN_DEPENDS}
+ $(srcdir)/emultempl/generic.em $(srcdir)/emultempl/netbsd.em \
+ $(srcdir)/scripttempl/aout.sc ${GEN_DEPENDS}
${GENSCRIPTS} ns32knbsd "$(tdir_ns32knbsd)"
eor32.c: $(srcdir)/emulparams/or32.sh \
$(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/or32.sc ${GEN_DEPENDS}
@@ -953,6 +1292,12 @@ eshelf32.c: $(srcdir)/emulparams/shelf32.sh \
$(srcdir)/emultempl/sh64elf.em $(INCDIR)/elf/sh.h $(BFDDIR)/elf-bfd.h \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} shelf32 "$(tdir_shelf32)"
+eshelf32_linux.c: $(srcdir)/emulparams/shelf32_linux.sh \
+ $(srcdir)/emulparams/shelf32.sh \
+ $(BFDDIR)/libbfd.h $(INCDIR)/libiberty.h \
+ $(srcdir)/emultempl/sh64elf.em $(INCDIR)/elf/sh.h $(BFDDIR)/elf-bfd.h \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} shelf32_linux "$(tdir_shelf32_linux)"
eshelf32_nbsd.c: $(srcdir)/emulparams/shelf32_nbsd.sh \
$(srcdir)/emulparams/shelf32.sh \
$(BFDDIR)/libbfd.h $(INCDIR)/libiberty.h \
@@ -977,11 +1322,17 @@ eshelf_nbsd.c: $(srcdir)/emulparams/shelf_nbsd.sh \
$(srcdir)/emulparams/shelf.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} shelf_nbsd "$(tdir_shelf_nbsd)"
+eshelf_nto.c: $(srcdir)/emulparams/shelf_nto.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} shelf_nto "$(tdir_shelf_nto)"
eshlelf_nbsd.c: $(srcdir)/emulparams/shlelf_nbsd.sh \
$(srcdir)/emulparams/shelf_nbsd.sh \
$(srcdir)/emulparams/shelf.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} shlelf_nbsd "$(tdir_shlelf_nbsd)"
+eshlelf_nto.c: $(srcdir)/emulparams/shlelf_nto.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} shlelf_nto "$(tdir_shlelf_nto)"
eshlelf.c: $(srcdir)/emulparams/shlelf.sh \
$(srcdir)/emulparams/shelf.sh \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
@@ -991,6 +1342,12 @@ eshlelf32.c: $(srcdir)/emulparams/shlelf32.sh \
$(srcdir)/emultempl/sh64elf.em $(INCDIR)/elf/sh.h $(BFDDIR)/elf-bfd.h \
$(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
${GENSCRIPTS} shlelf32 "$(tdir_shlelf32)"
+eshlelf32_linux.c: $(srcdir)/emulparams/shlelf32_linux.sh \
+ $(srcdir)/emulparams/shelf32_linux.sh $(srcdir)/emulparams/shelf32.sh \
+ $(BFDDIR)/libbfd.h $(INCDIR)/libiberty.h \
+ $(srcdir)/emultempl/sh64elf.em $(INCDIR)/elf/sh.h $(BFDDIR)/elf-bfd.h \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} shlelf32_linux "$(tdir_shlelf32_linux)"
eshlelf32_nbsd.c: $(srcdir)/emulparams/shlelf32_nbsd.sh \
$(srcdir)/emulparams/shelf32_nbsd.sh $(srcdir)/emulparams/shelf32.sh \
$(BFDDIR)/libbfd.h $(INCDIR)/libiberty.h \
@@ -1040,6 +1397,15 @@ etic30aout.c: $(srcdir)/emulparams/tic30aout.sh \
etic30coff.c: $(srcdir)/emulparams/tic30coff.sh \
$(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/tic30coff.sc ${GEN_DEPENDS}
${GENSCRIPTS} tic30coff "$(tdir_tic30coff)"
+etic3xcoff.c: $(srcdir)/emulparams/tic3xcoff.sh \
+ $(srcdir)/emultempl/ticoff.em $(srcdir)/scripttempl/tic4xcoff.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} tic3xcoff "$(tdir_tic4xcoff)"
+etic3xcoff_onchip.c: $(srcdir)/emulparams/tic3xcoff_onchip.sh \
+ $(srcdir)/emultempl/ticoff.em $(srcdir)/scripttempl/tic4xcoff.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} tic3xcoff_onchip "$(tdir_tic4xcoff)"
+etic4xcoff.c: $(srcdir)/emulparams/tic4xcoff.sh \
+ $(srcdir)/emultempl/ticoff.em $(srcdir)/scripttempl/tic4xcoff.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} tic4xcoff "$(tdir_tic4xcoff)"
etic54xcoff.c: $(srcdir)/emulparams/tic54xcoff.sh \
$(srcdir)/emultempl/ticoff.em $(srcdir)/scripttempl/tic54xcoff.sc ${GEN_DEPENDS}
${GENSCRIPTS} tic54xcoff "$(tdir_tic54xcoff)"
@@ -1070,6 +1436,10 @@ ez8001.c: $(srcdir)/emulparams/z8001.sh \
ez8002.c: $(srcdir)/emulparams/z8002.sh \
$(srcdir)/emultempl/generic.em $(srcdir)/scripttempl/z8000.sc ${GEN_DEPENDS}
${GENSCRIPTS} z8002 "$(tdir_z8002)"
+eelf32frvfd.c: $(srcdir)/emulparams/elf32frvfd.sh \
+ $(srcdir)/emulparams/elf32frv.sh \
+ $(srcdir)/emultempl/elf32.em $(srcdir)/scripttempl/elf.sc ${GEN_DEPENDS}
+ ${GENSCRIPTS} elf32frvfd "$(tdir_frv)"
# We need this for automake to use YLWRAP.
EXTRA_ld_new_SOURCES = deffilep.y
@@ -1186,7 +1556,7 @@ ld.dvi: $(srcdir)/ld.texinfo configdoc.texi ldver.texi
# Build the man page from the texinfo file
# The sed command removes the no-adjust Nroff command so that
# the man output looks standard.
-ld.1: $(srcdir)/ld.texinfo
+ld.1: $(srcdir)/ld.texinfo configdoc.texi ldver.texi
touch $@
-$(TEXI2POD) $(MANCONF) < $(srcdir)/ld.texinfo > ld.pod
-($(POD2MAN) ld.pod | \
@@ -1331,13 +1701,14 @@ ldfile.o: ldfile.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h sysdep.h config.h $(INCDIR)/fopen-same.h \
$(INCDIR)/bfdlink.h $(INCDIR)/safe-ctype.h ld.h $(INCDIR)/bin-bugs.h \
ldmisc.h ldexp.h ldlang.h ldfile.h ldmain.h ldgram.h \
- ldlex.h ldemul.h $(INCDIR)/libiberty.h
+ ldlex.h ldemul.h $(INCDIR)/libiberty.h $(INCDIR)/filenames.h
ldlang.o: ldlang.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h sysdep.h config.h $(INCDIR)/fopen-same.h \
$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h $(INCDIR)/obstack.h \
$(INCDIR)/bfdlink.h ld.h $(INCDIR)/bin-bugs.h ldmain.h \
ldexp.h ldlang.h ldgram.h ldlex.h ldmisc.h ldctor.h \
- ldfile.h ldemul.h $(INCDIR)/fnmatch.h $(INCDIR)/demangle.h
+ ldfile.h ldemul.h $(INCDIR)/fnmatch.h $(INCDIR)/demangle.h \
+ $(INCDIR)/hashtab.h
ldmain.o: ldmain.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h sysdep.h config.h $(INCDIR)/fopen-same.h \
$(INCDIR)/safe-ctype.h $(INCDIR)/libiberty.h $(INCDIR)/progress.h \
@@ -1345,18 +1716,19 @@ ldmain.o: ldmain.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
ldmain.h ldmisc.h ldwrite.h ldexp.h ldlang.h ldgram.h \
ldlex.h ldfile.h ldemul.h ldctor.h
ldmisc.o: ldmisc.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/symcat.h sysdep.h config.h $(INCDIR)/fopen-same.h \
- $(INCDIR)/libiberty.h $(INCDIR)/demangle.h ld.h $(INCDIR)/bin-bugs.h \
- ldmisc.h ldexp.h ldlang.h ldgram.h ldlex.h ldmain.h \
- ldfile.h
+ $(INCDIR)/symcat.h $(INCDIR)/bfdlink.h sysdep.h config.h \
+ $(INCDIR)/fopen-same.h $(INCDIR)/libiberty.h $(INCDIR)/demangle.h \
+ ld.h $(INCDIR)/bin-bugs.h ldmisc.h ldexp.h ldlang.h \
+ ldgram.h ldlex.h ldmain.h ldfile.h
ldver.o: ldver.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/symcat.h sysdep.h config.h $(INCDIR)/fopen-same.h \
- ld.h $(INCDIR)/bin-bugs.h ldver.h ldexp.h ldlang.h \
- ldfile.h ldemul.h ldmain.h
+ $(INCDIR)/symcat.h ../bfd/bfdver.h sysdep.h config.h \
+ $(INCDIR)/fopen-same.h ld.h $(INCDIR)/bin-bugs.h ldver.h \
+ ldexp.h ldlang.h ldfile.h ldemul.h ldmain.h
ldwrite.o: ldwrite.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h sysdep.h config.h $(INCDIR)/fopen-same.h \
- $(INCDIR)/bfdlink.h $(INCDIR)/libiberty.h ld.h $(INCDIR)/bin-bugs.h \
- ldexp.h ldlang.h ldwrite.h ldmisc.h ldgram.h ldmain.h
+ $(INCDIR)/bfdlink.h $(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h \
+ ld.h $(INCDIR)/bin-bugs.h ldexp.h ldlang.h ldwrite.h \
+ ldmisc.h ldgram.h ldmain.h
lexsup.o: lexsup.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h sysdep.h config.h $(INCDIR)/fopen-same.h \
$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h $(INCDIR)/bfdlink.h \
@@ -1381,7 +1753,7 @@ ldgram.o: ldgram.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/bfdlink.h ld.h $(INCDIR)/bin-bugs.h ldexp.h \
ldver.h ldlang.h ldfile.h ldemul.h ldmisc.h ldmain.h \
mri.h ldctor.h ldlex.h
-ldlex.o: ldlex.c $(INCDIR)/ansidecl.h ../bfd/bfd.h \
+ldlex.o: ldlex.c ../bfd/bfd.h $(INCDIR)/ansidecl.h \
$(INCDIR)/symcat.h sysdep.h config.h $(INCDIR)/fopen-same.h \
$(INCDIR)/safe-ctype.h $(INCDIR)/bfdlink.h ld.h $(INCDIR)/bin-bugs.h \
ldmisc.h ldexp.h ldlang.h ldgram.h ldfile.h ldlex.h \
diff --git a/contrib/binutils/ld/NEWS b/contrib/binutils/ld/NEWS
index 383bd8c..81512c4 100644
--- a/contrib/binutils/ld/NEWS
+++ b/contrib/binutils/ld/NEWS
@@ -1,4 +1,41 @@
-*- text -*-
+
+* The linker script operator DEFINED() will now yield 1 only for a symbol that
+ is defined before the statement where DEFINED is used.
+
+* The MIPS --embedded-relocs (used to embed relocations into binaries for
+ Embedded-PIC code) is deprecated and will be removed in a future release.
+
+* m32r Linux (ELF) support added by Renesas.
+
+* Improved linker's handling of unresolved symbols. The switch
+ --unresolved-symbols=<method> has been added to tell the linker when it
+ should report them and the switch --warn-unresolved-symbols has been added to
+ make reports be issued as warning messages rather than errors.
+
+Changes in 2.14:
+
+* Added support for Xtensa architecture.
+
+* Added --with-sysroot configure switch to specify a target system root, for
+ linking against a target filesystem image.
+
+* Added --accept-unknown-linker-format to restore old linker behaviour (pre
+ 2.14) of silently accepting and linking in any files in an unknown binary
+ file format.
+
+* Added --no-omagic to undo the effects of the -N option.
+
+* Support for Texas Instruments TMS320C4x and TMS320C3x series of
+ DSP's contributed by Michael Hayes and Svein E. Seldal.
+
+* Added --with-lib-path configure switch to specify default value for
+ LIB_PATH.
+
+* ARM port to QNX operating system added by Graeme Peterson.
+
+* IP2K support added by Denis Chertykov.
+
Changes in 2.13:
* Support for the Fujitsu FRV architecture added by Red Hat. Models for FR400
@@ -52,6 +89,8 @@ Changes in version 2.11:
* Support for CRIS (Axis Communications ETRAX series).
+* Support for PDP-11 and 2.11BSD a.out format, by Lars Brinkhoff.
+
Changes in version 2.10:
* Added AT> to the linker script language to allow load-time allocation of
@@ -75,7 +114,7 @@ Changes in version 2.10:
wildcard file names.
* Added -O option to optimize linker output (as of this writing, this only
-affects ELF shared library generation).
+ affects ELF shared library generation).
* The -e option now accepts a number as well as a symbol name.
@@ -146,7 +185,7 @@ not copied into the output file. This is used by glibc.
* When an ELF section named .gnu.warning.SYMBOL is encountered in an input
file, and the symbol SYMBOL is referenced by some object file, the contents of
the section are displayed as an error message. The section is not copied into
-the output file, unless doing a relocateable or shared link. This is used by
+the output file, unless doing a relocatable or shared link. This is used by
glibc.
* New options -split-by-reloc and -split-by-file.
@@ -169,7 +208,7 @@ Changes in version 2.5:
* The linker now supports linking against SunOS shared libraries. It still can
not link SunOS PIC (Position Independent Code) files, so it can not be used to
-generate shared libaries.
+generate shared libraries.
* The linker now supports linking against ELF shared libraries for the i386
(UnixWare) and SPARC (Solaris). It can also link ELF PIC files, and can be
diff --git a/contrib/binutils/ld/README b/contrib/binutils/ld/README
index 6fef769..a953e42 100644
--- a/contrib/binutils/ld/README
+++ b/contrib/binutils/ld/README
@@ -28,7 +28,8 @@ See ../binutils/README.
If you want to make a cross-linker, you may want to specify
a different search path of -lfoo libraries than the default.
-You can do this by setting the LIB_PATH variable in ./Makefile.
+You can do this by setting the LIB_PATH variable in ./Makefile
+or using the --with-lib-path configure switch.
To build just the linker, make the target all-ld from the top level
directory (one directory above this one).
diff --git a/contrib/binutils/ld/aclocal.m4 b/contrib/binutils/ld/aclocal.m4
index 6111817..7b50bb9 100644
--- a/contrib/binutils/ld/aclocal.m4
+++ b/contrib/binutils/ld/aclocal.m4
@@ -27,6 +27,24 @@ AC_DEFUN([CY_WITH_NLS],)
AC_SUBST(INTLLIBS)
])
+#serial 1
+# This test replaces the one in autoconf.
+# Currently this macro should have the same name as the autoconf macro
+# because gettext's gettext.m4 (distributed in the automake package)
+# still uses it. Otherwise, the use in gettext.m4 makes autoheader
+# give these diagnostics:
+# configure.in:556: AC_TRY_COMPILE was called before AC_ISC_POSIX
+# configure.in:556: AC_TRY_RUN was called before AC_ISC_POSIX
+
+undefine([AC_ISC_POSIX])
+
+AC_DEFUN([AC_ISC_POSIX],
+ [
+ dnl This test replaces the obsolescent AC_ISC_POSIX kludge.
+ AC_CHECK_LIB(cposix, strerror, [LIBS="$LIBS -lcposix"])
+ ]
+)
+
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
diff --git a/contrib/binutils/ld/config.in b/contrib/binutils/ld/config.in
index 14e50d1..f76bb42 100644
--- a/contrib/binutils/ld/config.in
+++ b/contrib/binutils/ld/config.in
@@ -70,6 +70,9 @@
/* Define if you have the putenv function. */
#undef HAVE_PUTENV
+/* Define if you have the realpath function. */
+#undef HAVE_REALPATH
+
/* Define if you have the sbrk function. */
#undef HAVE_SBRK
@@ -127,12 +130,6 @@
/* Define if you have the <sys/param.h> header file. */
#undef HAVE_SYS_PARAM_H
-/* Define if you have the <sys/stat.h> header file. */
-#undef HAVE_SYS_STAT_H
-
-/* Define if you have the <sys/types.h> header file. */
-#undef HAVE_SYS_TYPES_H
-
/* Define if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
diff --git a/contrib/binutils/ld/configure b/contrib/binutils/ld/configure
index e1c48d7..410f9c2 100755
--- a/contrib/binutils/ld/configure
+++ b/contrib/binutils/ld/configure
@@ -24,11 +24,15 @@ ac_help="$ac_help
ac_help="$ac_help
--with-pic try to use only PIC/non-PIC objects [default=use both]"
ac_help="$ac_help
+ --with-lib-path=dir1:dir2... set default LIB_PATH"
+ac_help="$ac_help
--enable-targets alternative target configurations"
ac_help="$ac_help
--enable-64-bit-bfd 64-bit support (on hosts with narrower word sizes)"
ac_help="$ac_help
- --enable-build-warnings Enable build-time compiler warnings if gcc is used"
+ --with-sysroot[=DIR] Search for usr/lib et al within DIR."
+ac_help="$ac_help
+ --enable-build-warnings enable build-time compiler warnings if gcc is used"
ac_help="$ac_help
--disable-nls do not use Native Language Support"
ac_help="$ac_help
@@ -53,6 +57,7 @@ program_suffix=NONE
program_transform_name=s,x,x,
silent=
site=
+sitefile=
srcdir=
target=NONE
verbose=
@@ -167,6 +172,7 @@ Configuration:
--help print this message
--no-create do not create output files
--quiet, --silent do not print \`checking...' messages
+ --site-file=FILE use FILE as the site file
--version print the version of autoconf that created configure
Directory and file names:
--prefix=PREFIX install architecture-independent files in PREFIX
@@ -337,6 +343,11 @@ EOF
-site=* | --site=* | --sit=*)
site="$ac_optarg" ;;
+ -site-file | --site-file | --site-fil | --site-fi | --site-f)
+ ac_prev=sitefile ;;
+ -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
+ sitefile="$ac_optarg" ;;
+
-srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
ac_prev=srcdir ;;
-srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
@@ -502,12 +513,16 @@ fi
srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
# Prefer explicitly selected file to automatically selected ones.
-if test -z "$CONFIG_SITE"; then
- if test "x$prefix" != xNONE; then
- CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
- else
- CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
+if test -z "$sitefile"; then
+ if test -z "$CONFIG_SITE"; then
+ if test "x$prefix" != xNONE; then
+ CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
+ else
+ CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
+ fi
fi
+else
+ CONFIG_SITE="$sitefile"
fi
for ac_site_file in $CONFIG_SITE; do
if test -r "$ac_site_file"; then
@@ -546,12 +561,12 @@ else
fi
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:550: checking for Cygwin environment" >&5
+echo "configure:565: checking for Cygwin environment" >&5
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 555 "configure"
+#line 570 "configure"
#include "confdefs.h"
int main() {
@@ -562,7 +577,7 @@ int main() {
return __CYGWIN__;
; return 0; }
EOF
-if { (eval echo configure:566: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:581: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_cygwin=yes
else
@@ -579,19 +594,19 @@ echo "$ac_t""$ac_cv_cygwin" 1>&6
CYGWIN=
test "$ac_cv_cygwin" = yes && CYGWIN=yes
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:583: checking for mingw32 environment" >&5
+echo "configure:598: checking for mingw32 environment" >&5
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 588 "configure"
+#line 603 "configure"
#include "confdefs.h"
int main() {
return __MINGW32__;
; return 0; }
EOF
-if { (eval echo configure:595: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:610: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_mingw32=yes
else
@@ -656,7 +671,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:660: checking host system type" >&5
+echo "configure:675: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -677,7 +692,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:681: checking target system type" >&5
+echo "configure:696: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -695,7 +710,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:699: checking build system type" >&5
+echo "configure:714: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -717,249 +732,49 @@ test "$host_alias" != "$target_alias" &&
NONENONEs,x,x, &&
program_prefix=${target_alias}-
-# Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:724: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_CC="gcc"
- break
- fi
- done
- IFS="$ac_save_ifs"
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-if test -z "$CC"; then
- # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:754: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_prog_rejected=no
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
- ac_prog_rejected=yes
- continue
- fi
- ac_cv_prog_CC="cc"
- break
- fi
- done
- IFS="$ac_save_ifs"
-if test $ac_prog_rejected = yes; then
- # We found a bogon in the path, so make sure we never use it.
- set dummy $ac_cv_prog_CC
- shift
- if test $# -gt 0; then
- # We chose a different compiler from the bogus one.
- # However, it has the same basename, so the bogon will be chosen
- # first if we set CC to just the basename; use the full file name.
- shift
- set dummy "$ac_dir/$ac_word" "$@"
- shift
- ac_cv_prog_CC="$@"
- fi
-fi
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
- if test -z "$CC"; then
- case "`uname -s`" in
- *win32* | *WIN32*)
- # Extract the first word of "cl", so it can be a program name with args.
-set dummy cl; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:805: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+ echo $ac_n "checking for strerror in -lcposix""... $ac_c" 1>&6
+echo "configure:738: checking for strerror in -lcposix" >&5
+ac_lib_var=`echo cposix'_'strerror | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_CC="cl"
- break
- fi
- done
- IFS="$ac_save_ifs"
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
- ;;
- esac
- fi
- test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
-fi
-
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:837: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
-
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-cat > conftest.$ac_ext << EOF
-
-#line 848 "configure"
+ ac_save_LIBS="$LIBS"
+LIBS="-lcposix $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 746 "configure"
#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error. */
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char strerror();
-main(){return(0);}
+int main() {
+strerror()
+; return 0; }
EOF
-if { (eval echo configure:853: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- ac_cv_prog_cc_works=yes
- # If we can't run a trivial program, we are probably using a cross compiler.
- if (./conftest; exit) 2>/dev/null; then
- ac_cv_prog_cc_cross=no
- else
- ac_cv_prog_cc_cross=yes
- fi
+if { (eval echo configure:757: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ rm -rf conftest*
+ eval "ac_cv_lib_$ac_lib_var=yes"
else
echo "configure: failed program was:" >&5
cat conftest.$ac_ext >&5
- ac_cv_prog_cc_works=no
-fi
-rm -fr conftest*
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
-if test $ac_cv_prog_cc_works = no; then
- { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
-fi
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:879: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
-echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
-cross_compiling=$ac_cv_prog_cc_cross
-
-echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:884: checking whether we are using GNU C" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.c <<EOF
-#ifdef __GNUC__
- yes;
-#endif
-EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:893: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
- ac_cv_prog_gcc=yes
-else
- ac_cv_prog_gcc=no
-fi
-fi
-
-echo "$ac_t""$ac_cv_prog_gcc" 1>&6
-
-if test $ac_cv_prog_gcc = yes; then
- GCC=yes
-else
- GCC=
-fi
-
-ac_test_CFLAGS="${CFLAGS+set}"
-ac_save_CFLAGS="$CFLAGS"
-CFLAGS=
-echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:912: checking whether ${CC-cc} accepts -g" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- echo 'void f(){}' > conftest.c
-if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
- ac_cv_prog_cc_g=yes
-else
- ac_cv_prog_cc_g=no
+ rm -rf conftest*
+ eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
+LIBS="$ac_save_LIBS"
fi
-
-echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
-if test "$ac_test_CFLAGS" = set; then
- CFLAGS="$ac_save_CFLAGS"
-elif test $ac_cv_prog_cc_g = yes; then
- if test "$GCC" = yes; then
- CFLAGS="-g -O2"
- else
- CFLAGS="-g"
- fi
-else
- if test "$GCC" = yes; then
- CFLAGS="-O2"
- else
- CFLAGS=
- fi
-fi
-
-echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
-echo "configure:944: checking for POSIXized ISC" >&5
-if test -d /etc/conf/kconfig.d &&
- grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
-then
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
- ISC=yes # If later tests want to check for ISC.
- cat >> confdefs.h <<\EOF
-#define _POSIX_SOURCE 1
-EOF
-
- if test "$GCC" = yes; then
- CC="$CC -posix"
- else
- CC="$CC -Xp"
- fi
+ LIBS="$LIBS -lcposix"
else
echo "$ac_t""no" 1>&6
- ISC=
fi
+
+
BFD_VERSION=`sed -n -e 's/^.._INIT_AUTOMAKE.*,[ ]*\([^ ]*\)[ ]*).*/\1/p' < ${srcdir}/../bfd/configure.in`
# Find a good install program. We prefer a C program (faster),
@@ -974,7 +789,7 @@ BFD_VERSION=`sed -n -e 's/^.._INIT_AUTOMAKE.*,[ ]*\([^ ]*\)[ ]*).*/\1/p' < ${
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:978: checking for a BSD compatible install" >&5
+echo "configure:793: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1027,7 +842,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:1031: checking whether build environment is sane" >&5
+echo "configure:846: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -1084,7 +899,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:1088: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:903: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1130,7 +945,7 @@ EOF
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:1134: checking for working aclocal" >&5
+echo "configure:949: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1143,7 +958,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:1147: checking for working autoconf" >&5
+echo "configure:962: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1156,7 +971,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:1160: checking for working automake" >&5
+echo "configure:975: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1169,7 +984,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:1173: checking for working autoheader" >&5
+echo "configure:988: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1182,7 +997,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:1186: checking for working makeinfo" >&5
+echo "configure:1001: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1265,6 +1080,228 @@ else
enable_fast_install=yes
fi
+# Extract the first word of "gcc", so it can be a program name with args.
+set dummy gcc; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:1087: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$CC"; then
+ ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_CC="gcc"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+CC="$ac_cv_prog_CC"
+if test -n "$CC"; then
+ echo "$ac_t""$CC" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+if test -z "$CC"; then
+ # Extract the first word of "cc", so it can be a program name with args.
+set dummy cc; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:1117: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$CC"; then
+ ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_prog_rejected=no
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
+ ac_prog_rejected=yes
+ continue
+ fi
+ ac_cv_prog_CC="cc"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+if test $ac_prog_rejected = yes; then
+ # We found a bogon in the path, so make sure we never use it.
+ set dummy $ac_cv_prog_CC
+ shift
+ if test $# -gt 0; then
+ # We chose a different compiler from the bogus one.
+ # However, it has the same basename, so the bogon will be chosen
+ # first if we set CC to just the basename; use the full file name.
+ shift
+ set dummy "$ac_dir/$ac_word" "$@"
+ shift
+ ac_cv_prog_CC="$@"
+ fi
+fi
+fi
+fi
+CC="$ac_cv_prog_CC"
+if test -n "$CC"; then
+ echo "$ac_t""$CC" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ if test -z "$CC"; then
+ case "`uname -s`" in
+ *win32* | *WIN32*)
+ # Extract the first word of "cl", so it can be a program name with args.
+set dummy cl; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:1168: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$CC"; then
+ ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_CC="cl"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+CC="$ac_cv_prog_CC"
+if test -n "$CC"; then
+ echo "$ac_t""$CC" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+ ;;
+ esac
+ fi
+ test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
+fi
+
+echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
+echo "configure:1200: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+
+ac_ext=c
+# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
+ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
+cross_compiling=$ac_cv_prog_cc_cross
+
+cat > conftest.$ac_ext << EOF
+
+#line 1211 "configure"
+#include "confdefs.h"
+
+main(){return(0);}
+EOF
+if { (eval echo configure:1216: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ ac_cv_prog_cc_works=yes
+ # If we can't run a trivial program, we are probably using a cross compiler.
+ if (./conftest; exit) 2>/dev/null; then
+ ac_cv_prog_cc_cross=no
+ else
+ ac_cv_prog_cc_cross=yes
+ fi
+else
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+ ac_cv_prog_cc_works=no
+fi
+rm -fr conftest*
+ac_ext=c
+# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
+ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
+cross_compiling=$ac_cv_prog_cc_cross
+
+echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
+if test $ac_cv_prog_cc_works = no; then
+ { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
+fi
+echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
+echo "configure:1242: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
+cross_compiling=$ac_cv_prog_cc_cross
+
+echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
+echo "configure:1247: checking whether we are using GNU C" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ cat > conftest.c <<EOF
+#ifdef __GNUC__
+ yes;
+#endif
+EOF
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1256: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+ ac_cv_prog_gcc=yes
+else
+ ac_cv_prog_gcc=no
+fi
+fi
+
+echo "$ac_t""$ac_cv_prog_gcc" 1>&6
+
+if test $ac_cv_prog_gcc = yes; then
+ GCC=yes
+else
+ GCC=
+fi
+
+ac_test_CFLAGS="${CFLAGS+set}"
+ac_save_CFLAGS="$CFLAGS"
+CFLAGS=
+echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
+echo "configure:1275: checking whether ${CC-cc} accepts -g" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ echo 'void f(){}' > conftest.c
+if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
+ ac_cv_prog_cc_g=yes
+else
+ ac_cv_prog_cc_g=no
+fi
+rm -f conftest*
+
+fi
+
+echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
+if test "$ac_test_CFLAGS" = set; then
+ CFLAGS="$ac_save_CFLAGS"
+elif test $ac_cv_prog_cc_g = yes; then
+ if test "$GCC" = yes; then
+ CFLAGS="-g -O2"
+ else
+ CFLAGS="-g"
+ fi
+else
+ if test "$GCC" = yes; then
+ CFLAGS="-O2"
+ else
+ CFLAGS=
+ fi
+fi
+
# Check whether --with-gnu-ld or --without-gnu-ld was given.
if test "${with_gnu_ld+set}" = set; then
withval="$with_gnu_ld"
@@ -1277,7 +1314,7 @@ ac_prog=ld
if test "$GCC" = yes; then
# Check if gcc -print-prog-name=ld gives a path.
echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
-echo "configure:1281: checking for ld used by GCC" >&5
+echo "configure:1318: checking for ld used by GCC" >&5
case $host in
*-*-mingw*)
# gcc leaves a trailing carriage return which upsets mingw
@@ -1307,10 +1344,10 @@ echo "configure:1281: checking for ld used by GCC" >&5
esac
elif test "$with_gnu_ld" = yes; then
echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
-echo "configure:1311: checking for GNU ld" >&5
+echo "configure:1348: checking for GNU ld" >&5
else
echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
-echo "configure:1314: checking for non-GNU ld" >&5
+echo "configure:1351: checking for non-GNU ld" >&5
fi
if eval "test \"`echo '$''{'lt_cv_path_LD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1345,7 +1382,7 @@ else
fi
test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
-echo "configure:1349: checking if the linker ($LD) is GNU ld" >&5
+echo "configure:1386: checking if the linker ($LD) is GNU ld" >&5
if eval "test \"`echo '$''{'lt_cv_prog_gnu_ld'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1362,7 +1399,7 @@ with_gnu_ld=$lt_cv_prog_gnu_ld
echo $ac_n "checking for $LD option to reload object files""... $ac_c" 1>&6
-echo "configure:1366: checking for $LD option to reload object files" >&5
+echo "configure:1403: checking for $LD option to reload object files" >&5
if eval "test \"`echo '$''{'lt_cv_ld_reload_flag'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1374,7 +1411,7 @@ reload_flag=$lt_cv_ld_reload_flag
test -n "$reload_flag" && reload_flag=" $reload_flag"
echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
-echo "configure:1378: checking for BSD-compatible nm" >&5
+echo "configure:1415: checking for BSD-compatible nm" >&5
if eval "test \"`echo '$''{'lt_cv_path_NM'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1412,7 +1449,7 @@ NM="$lt_cv_path_NM"
echo "$ac_t""$NM" 1>&6
echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:1416: checking whether ln -s works" >&5
+echo "configure:1453: checking whether ln -s works" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1433,7 +1470,7 @@ else
fi
echo $ac_n "checking how to recognise dependant libraries""... $ac_c" 1>&6
-echo "configure:1437: checking how to recognise dependant libraries" >&5
+echo "configure:1474: checking how to recognise dependant libraries" >&5
if eval "test \"`echo '$''{'lt_cv_deplibs_check_method'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1543,7 +1580,7 @@ irix5* | irix6*)
# This must be Linux ELF.
linux-gnu*)
case $host_cpu in
- alpha* | hppa* | i*86 | powerpc* | sparc* | ia64* )
+ alpha* | mips* | hppa* | i*86 | powerpc* | sparc* | ia64* )
lt_cv_deplibs_check_method=pass_all ;;
*)
# glibc up to 2.1.1 does not perform some relocations on ARM
@@ -1606,13 +1643,13 @@ file_magic_cmd=$lt_cv_file_magic_cmd
deplibs_check_method=$lt_cv_deplibs_check_method
echo $ac_n "checking for object suffix""... $ac_c" 1>&6
-echo "configure:1610: checking for object suffix" >&5
+echo "configure:1647: checking for object suffix" >&5
if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
rm -f conftest*
echo 'int i = 1;' > conftest.$ac_ext
-if { (eval echo configure:1616: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1653: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
for ac_file in conftest.*; do
case $ac_file in
*.c) ;;
@@ -1632,7 +1669,7 @@ ac_objext=$ac_cv_objext
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:1636: checking for executable suffix" >&5
+echo "configure:1673: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1642,10 +1679,10 @@ else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:1646: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:1683: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
- *.c | *.o | *.obj) ;;
+ *.c | *.o | *.obj | *.ilk | *.pdb) ;;
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
esac
done
@@ -1675,7 +1712,7 @@ case $deplibs_check_method in
file_magic*)
if test "$file_magic_cmd" = '$MAGIC_CMD'; then
echo $ac_n "checking for ${ac_tool_prefix}file""... $ac_c" 1>&6
-echo "configure:1679: checking for ${ac_tool_prefix}file" >&5
+echo "configure:1716: checking for ${ac_tool_prefix}file" >&5
if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1737,7 +1774,7 @@ fi
if test -z "$lt_cv_path_MAGIC_CMD"; then
if test -n "$ac_tool_prefix"; then
echo $ac_n "checking for file""... $ac_c" 1>&6
-echo "configure:1741: checking for file" >&5
+echo "configure:1778: checking for file" >&5
if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1808,7 +1845,7 @@ esac
# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1812: checking for $ac_word" >&5
+echo "configure:1849: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1840,7 +1877,7 @@ if test -n "$ac_tool_prefix"; then
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1844: checking for $ac_word" >&5
+echo "configure:1881: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1875,7 +1912,7 @@ fi
# Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
set dummy ${ac_tool_prefix}strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1879: checking for $ac_word" >&5
+echo "configure:1916: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1907,7 +1944,7 @@ if test -n "$ac_tool_prefix"; then
# Extract the first word of "strip", so it can be a program name with args.
set dummy strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1911: checking for $ac_word" >&5
+echo "configure:1948: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1974,8 +2011,21 @@ test x"$pic_mode" = xno && libtool_flags="$libtool_flags --prefer-non-pic"
case $host in
*-*-irix6*)
# Find out which ABI we are using.
- echo '#line 1978 "configure"' > conftest.$ac_ext
- if { (eval echo configure:1979: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ echo '#line 2015 "configure"' > conftest.$ac_ext
+ if { (eval echo configure:2016: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ if test "$lt_cv_prog_gnu_ld" = yes; then
+ case `/usr/bin/file conftest.$ac_objext` in
+ *32-bit*)
+ LD="${LD-ld} -melf32bsmip"
+ ;;
+ *N32*)
+ LD="${LD-ld} -melf32bmipn32"
+ ;;
+ *64-bit*)
+ LD="${LD-ld} -melf64bmip"
+ ;;
+ esac
+ else
case `/usr/bin/file conftest.$ac_objext` in
*32-bit*)
LD="${LD-ld} -32"
@@ -1987,6 +2037,7 @@ case $host in
LD="${LD-ld} -64"
;;
esac
+ fi
fi
rm -rf conftest*
;;
@@ -1994,7 +2045,7 @@ case $host in
ia64-*-hpux*)
# Find out which ABI we are using.
echo 'int i;' > conftest.$ac_ext
- if { (eval echo configure:1998: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ if { (eval echo configure:2049: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
case "`/usr/bin/file conftest.o`" in
*ELF-32*)
HPUX_IA64_MODE="32"
@@ -2012,7 +2063,7 @@ ia64-*-hpux*)
SAVE_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -belf"
echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
-echo "configure:2016: checking whether the C compiler needs -belf" >&5
+echo "configure:2067: checking whether the C compiler needs -belf" >&5
if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2025,14 +2076,14 @@ ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$a
cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext <<EOF
-#line 2029 "configure"
+#line 2080 "configure"
#include "confdefs.h"
int main() {
; return 0; }
EOF
-if { (eval echo configure:2036: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2087: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
lt_cv_cc_needs_belf=yes
else
@@ -2148,6 +2199,12 @@ exec 5>>./config.log
+# Check whether --with-lib-path or --without-lib-path was given.
+if test "${with_lib_path+set}" = set; then
+ withval="$with_lib_path"
+ LIB_PATH=$withval
+fi
+
# Check whether --enable-targets or --disable-targets was given.
if test "${enable_targets+set}" = set; then
enableval="$enable_targets"
@@ -2170,6 +2227,47 @@ else
want64=false
fi
+# Check whether --with-sysroot or --without-sysroot was given.
+if test "${with_sysroot+set}" = set; then
+ withval="$with_sysroot"
+
+ case ${with_sysroot} in
+ yes) TARGET_SYSTEM_ROOT='${exec_prefix}/${target_alias}/sys-root' ;;
+ *) TARGET_SYSTEM_ROOT=$with_sysroot ;;
+ esac
+
+ TARGET_SYSTEM_ROOT_DEFINE='-DTARGET_SYSTEM_ROOT=\"$(TARGET_SYSTEM_ROOT)\"'
+ use_sysroot=yes
+
+ if test "x$exec_prefix" = xNONE; then
+ if test "x$prefix" = xNONE; then
+ test_prefix=/usr/local
+ else
+ test_prefix=$prefix
+ fi
+ else
+ test_prefix=$exec_prefix
+ fi
+ case ${TARGET_SYSTEM_ROOT} in
+ "${test_prefix}"|"${test_prefix}/"*|\
+ '${exec_prefix}'|'${exec_prefix}/'*)
+ t="$TARGET_SYSTEM_ROOT_DEFINE -DTARGET_SYSTEM_ROOT_RELOCATABLE"
+ TARGET_SYSTEM_ROOT_DEFINE="$t"
+ ;;
+ esac
+
+else
+
+ use_sysroot=no
+ TARGET_SYSTEM_ROOT=
+ TARGET_SYSTEM_ROOT_DEFINE='-DTARGET_SYSTEM_ROOT=\"\"'
+
+fi
+
+
+
+
+
build_warnings="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
# Check whether --enable-build-warnings or --disable-build-warnings was given.
if test "${enable_build_warnings+set}" = set; then
@@ -2209,7 +2307,7 @@ fi
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2213: checking for $ac_word" >&5
+echo "configure:2311: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2239,7 +2337,7 @@ if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2243: checking for $ac_word" >&5
+echo "configure:2341: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2290,7 +2388,7 @@ fi
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2294: checking for $ac_word" >&5
+echo "configure:2392: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2322,7 +2420,7 @@ fi
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:2326: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:2424: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -2333,12 +2431,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 2337 "configure"
+#line 2435 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:2342: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2440: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -2364,12 +2462,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:2368: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:2466: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:2373: checking whether we are using GNU C" >&5
+echo "configure:2471: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2378,7 +2476,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2382: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2480: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -2397,7 +2495,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:2401: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:2499: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2440,7 +2538,7 @@ fi
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:2444: checking for a BSD compatible install" >&5
+echo "configure:2542: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -2493,9 +2591,9 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
-ALL_LINGUAS="fr sv tr es"
+ALL_LINGUAS="fr sv tr es da"
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:2499: checking how to run the C preprocessor" >&5
+echo "configure:2597: checking how to run the C preprocessor" >&5
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
@@ -2510,13 +2608,13 @@ else
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp.
cat > conftest.$ac_ext <<EOF
-#line 2514 "configure"
+#line 2612 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2520: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2618: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -2527,13 +2625,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF
-#line 2531 "configure"
+#line 2629 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2537: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2635: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -2544,13 +2642,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -nologo -E"
cat > conftest.$ac_ext <<EOF
-#line 2548 "configure"
+#line 2646 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2554: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2652: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -2577,7 +2675,7 @@ echo "$ac_t""$CPP" 1>&6
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2581: checking for $ac_word" >&5
+echo "configure:2679: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2605,12 +2703,12 @@ else
fi
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:2609: checking for ANSI C header files" >&5
+echo "configure:2707: checking for ANSI C header files" >&5
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2614 "configure"
+#line 2712 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
@@ -2618,7 +2716,7 @@ else
#include <float.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2622: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2720: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -2635,7 +2733,7 @@ rm -f conftest*
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 2639 "configure"
+#line 2737 "configure"
#include "confdefs.h"
#include <string.h>
EOF
@@ -2653,7 +2751,7 @@ fi
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 2657 "configure"
+#line 2755 "configure"
#include "confdefs.h"
#include <stdlib.h>
EOF
@@ -2674,7 +2772,7 @@ if test "$cross_compiling" = yes; then
:
else
cat > conftest.$ac_ext <<EOF
-#line 2678 "configure"
+#line 2776 "configure"
#include "confdefs.h"
#include <ctype.h>
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -2685,7 +2783,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
exit (0); }
EOF
-if { (eval echo configure:2689: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2787: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
else
@@ -2709,12 +2807,12 @@ EOF
fi
echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:2713: checking for working const" >&5
+echo "configure:2811: checking for working const" >&5
if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2718 "configure"
+#line 2816 "configure"
#include "confdefs.h"
int main() {
@@ -2763,7 +2861,7 @@ ccp = (char const *const *) p;
; return 0; }
EOF
-if { (eval echo configure:2767: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2865: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_const=yes
else
@@ -2784,21 +2882,21 @@ EOF
fi
echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:2788: checking for inline" >&5
+echo "configure:2886: checking for inline" >&5
if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
cat > conftest.$ac_ext <<EOF
-#line 2795 "configure"
+#line 2893 "configure"
#include "confdefs.h"
int main() {
} $ac_kw foo() {
; return 0; }
EOF
-if { (eval echo configure:2802: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2900: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_inline=$ac_kw; break
else
@@ -2824,12 +2922,12 @@ EOF
esac
echo $ac_n "checking for off_t""... $ac_c" 1>&6
-echo "configure:2828: checking for off_t" >&5
+echo "configure:2926: checking for off_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2833 "configure"
+#line 2931 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -2857,12 +2955,12 @@ EOF
fi
echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:2861: checking for size_t" >&5
+echo "configure:2959: checking for size_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2866 "configure"
+#line 2964 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -2892,19 +2990,19 @@ fi
# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
# for constant arguments. Useless!
echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:2896: checking for working alloca.h" >&5
+echo "configure:2994: checking for working alloca.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2901 "configure"
+#line 2999 "configure"
#include "confdefs.h"
#include <alloca.h>
int main() {
char *p = alloca(2 * sizeof(int));
; return 0; }
EOF
-if { (eval echo configure:2908: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3006: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_header_alloca_h=yes
else
@@ -2925,12 +3023,12 @@ EOF
fi
echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:2929: checking for alloca" >&5
+echo "configure:3027: checking for alloca" >&5
if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2934 "configure"
+#line 3032 "configure"
#include "confdefs.h"
#ifdef __GNUC__
@@ -2958,7 +3056,7 @@ int main() {
char *p = (char *) alloca(1);
; return 0; }
EOF
-if { (eval echo configure:2962: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3060: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_func_alloca_works=yes
else
@@ -2990,12 +3088,12 @@ EOF
echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:2994: checking whether alloca needs Cray hooks" >&5
+echo "configure:3092: checking whether alloca needs Cray hooks" >&5
if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2999 "configure"
+#line 3097 "configure"
#include "confdefs.h"
#if defined(CRAY) && ! defined(CRAY2)
webecray
@@ -3020,12 +3118,12 @@ echo "$ac_t""$ac_cv_os_cray" 1>&6
if test $ac_cv_os_cray = yes; then
for ac_func in _getb67 GETB67 getb67; do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3024: checking for $ac_func" >&5
+echo "configure:3122: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3029 "configure"
+#line 3127 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3048,7 +3146,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3052: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3150: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3075,7 +3173,7 @@ done
fi
echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:3079: checking stack direction for C alloca" >&5
+echo "configure:3177: checking stack direction for C alloca" >&5
if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3083,7 +3181,7 @@ else
ac_cv_c_stack_direction=0
else
cat > conftest.$ac_ext <<EOF
-#line 3087 "configure"
+#line 3185 "configure"
#include "confdefs.h"
find_stack_direction ()
{
@@ -3102,7 +3200,7 @@ main ()
exit (find_stack_direction() < 0);
}
EOF
-if { (eval echo configure:3106: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3204: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_stack_direction=1
else
@@ -3123,21 +3221,21 @@ EOF
fi
-for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
+for ac_hdr in unistd.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3131: checking for $ac_hdr" >&5
+echo "configure:3229: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3136 "configure"
+#line 3234 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3141: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3239: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -3166,12 +3264,12 @@ done
for ac_func in getpagesize
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3170: checking for $ac_func" >&5
+echo "configure:3268: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3175 "configure"
+#line 3273 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3194,7 +3292,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3198: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3296: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3219,7 +3317,7 @@ fi
done
echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:3223: checking for working mmap" >&5
+echo "configure:3321: checking for working mmap" >&5
if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3227,7 +3325,7 @@ else
ac_cv_func_mmap_fixed_mapped=no
else
cat > conftest.$ac_ext <<EOF
-#line 3231 "configure"
+#line 3329 "configure"
#include "confdefs.h"
/* Thanks to Mike Haertel and Jim Avera for this test.
@@ -3255,24 +3353,11 @@ else
#include <fcntl.h>
#include <sys/mman.h>
-#if HAVE_SYS_TYPES_H
-# include <sys/types.h>
-#endif
-
-#if HAVE_STDLIB_H
-# include <stdlib.h>
-#endif
-
-#if HAVE_SYS_STAT_H
-# include <sys/stat.h>
-#endif
-
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
-
/* This mess was copied from the GNU getpagesize.h. */
#ifndef HAVE_GETPAGESIZE
+# ifdef HAVE_UNISTD_H
+# include <unistd.h>
+# endif
/* Assume that all systems that can run configure have sys/param.h. */
# ifndef HAVE_SYS_PARAM_H
@@ -3380,7 +3465,7 @@ main()
}
EOF
-if { (eval echo configure:3384: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3469: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_func_mmap_fixed_mapped=yes
else
@@ -3408,17 +3493,17 @@ unistd.h values.h sys/param.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3412: checking for $ac_hdr" >&5
+echo "configure:3497: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3417 "configure"
+#line 3502 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3422: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3507: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -3448,12 +3533,12 @@ done
__argz_count __argz_stringify __argz_next
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3452: checking for $ac_func" >&5
+echo "configure:3537: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3457 "configure"
+#line 3542 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3476,7 +3561,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3480: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3565: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3505,12 +3590,12 @@ done
for ac_func in stpcpy
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3509: checking for $ac_func" >&5
+echo "configure:3594: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3514 "configure"
+#line 3599 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3533,7 +3618,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3537: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3622: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3567,19 +3652,19 @@ EOF
if test $ac_cv_header_locale_h = yes; then
echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
-echo "configure:3571: checking for LC_MESSAGES" >&5
+echo "configure:3656: checking for LC_MESSAGES" >&5
if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3576 "configure"
+#line 3661 "configure"
#include "confdefs.h"
#include <locale.h>
int main() {
return LC_MESSAGES
; return 0; }
EOF
-if { (eval echo configure:3583: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3668: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
am_cv_val_LC_MESSAGES=yes
else
@@ -3600,7 +3685,7 @@ EOF
fi
fi
echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
-echo "configure:3604: checking whether NLS is requested" >&5
+echo "configure:3689: checking whether NLS is requested" >&5
# Check whether --enable-nls or --disable-nls was given.
if test "${enable_nls+set}" = set; then
enableval="$enable_nls"
@@ -3620,7 +3705,7 @@ fi
EOF
echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
-echo "configure:3624: checking whether included gettext is requested" >&5
+echo "configure:3709: checking whether included gettext is requested" >&5
# Check whether --with-included-gettext or --without-included-gettext was given.
if test "${with_included_gettext+set}" = set; then
withval="$with_included_gettext"
@@ -3639,17 +3724,17 @@ fi
ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
-echo "configure:3643: checking for libintl.h" >&5
+echo "configure:3728: checking for libintl.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3648 "configure"
+#line 3733 "configure"
#include "confdefs.h"
#include <libintl.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3653: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3738: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -3666,19 +3751,19 @@ fi
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
-echo "configure:3670: checking for gettext in libc" >&5
+echo "configure:3755: checking for gettext in libc" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3675 "configure"
+#line 3760 "configure"
#include "confdefs.h"
#include <libintl.h>
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:3682: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3767: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libc=yes
else
@@ -3694,7 +3779,7 @@ echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
if test "$gt_cv_func_gettext_libc" != "yes"; then
echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
-echo "configure:3698: checking for bindtextdomain in -lintl" >&5
+echo "configure:3783: checking for bindtextdomain in -lintl" >&5
ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -3702,7 +3787,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lintl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 3706 "configure"
+#line 3791 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -3713,7 +3798,7 @@ int main() {
bindtextdomain()
; return 0; }
EOF
-if { (eval echo configure:3717: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3802: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -3729,19 +3814,19 @@ fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
-echo "configure:3733: checking for gettext in libintl" >&5
+echo "configure:3818: checking for gettext in libintl" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3738 "configure"
+#line 3823 "configure"
#include "confdefs.h"
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:3745: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3830: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libintl=yes
else
@@ -3769,7 +3854,7 @@ EOF
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3773: checking for $ac_word" >&5
+echo "configure:3858: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3803,12 +3888,12 @@ fi
for ac_func in dcgettext
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3807: checking for $ac_func" >&5
+echo "configure:3892: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3812 "configure"
+#line 3897 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3831,7 +3916,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3835: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3920: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3858,7 +3943,7 @@ done
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3862: checking for $ac_word" >&5
+echo "configure:3947: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3894,7 +3979,7 @@ fi
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3898: checking for $ac_word" >&5
+echo "configure:3983: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3926,7 +4011,7 @@ else
fi
cat > conftest.$ac_ext <<EOF
-#line 3930 "configure"
+#line 4015 "configure"
#include "confdefs.h"
int main() {
@@ -3934,7 +4019,7 @@ extern int _nl_msg_cat_cntr;
return _nl_msg_cat_cntr
; return 0; }
EOF
-if { (eval echo configure:3938: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4023: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
CATOBJEXT=.gmo
DATADIRNAME=share
@@ -3966,7 +4051,7 @@ fi
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3970: checking for $ac_word" >&5
+echo "configure:4055: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4000,7 +4085,7 @@ fi
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4004: checking for $ac_word" >&5
+echo "configure:4089: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4036,7 +4121,7 @@ fi
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4040: checking for $ac_word" >&5
+echo "configure:4125: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4126,7 +4211,7 @@ fi
LINGUAS=
else
echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
-echo "configure:4130: checking for catalogs to be installed" >&5
+echo "configure:4215: checking for catalogs to be installed" >&5
NEW_LINGUAS=
for lang in ${LINGUAS=$ALL_LINGUAS}; do
case "$ALL_LINGUAS" in
@@ -4154,17 +4239,17 @@ echo "configure:4130: checking for catalogs to be installed" >&5
if test "$CATOBJEXT" = ".cat"; then
ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
-echo "configure:4158: checking for linux/version.h" >&5
+echo "configure:4243: checking for linux/version.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4163 "configure"
+#line 4248 "configure"
#include "confdefs.h"
#include <linux/version.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4168: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4253: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -4229,7 +4314,7 @@ fi
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:4233: checking for executable suffix" >&5
+echo "configure:4318: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4239,10 +4324,10 @@ else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:4243: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:4328: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
- *.c | *.o | *.obj) ;;
+ *.c | *.o | *.obj | *.ilk | *.pdb) ;;
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
esac
done
@@ -4265,7 +4350,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4269: checking for $ac_word" >&5
+echo "configure:4354: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4301,7 +4386,7 @@ do
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4305: checking for $ac_word" >&5
+echo "configure:4390: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4334,7 +4419,7 @@ test -n "$LEX" || LEX=""$missing_dir/missing flex""
# Extract the first word of "flex", so it can be a program name with args.
set dummy flex; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4338: checking for $ac_word" >&5
+echo "configure:4423: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4368,7 +4453,7 @@ then
*) ac_lib=l ;;
esac
echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6
-echo "configure:4372: checking for yywrap in -l$ac_lib" >&5
+echo "configure:4457: checking for yywrap in -l$ac_lib" >&5
ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -4376,7 +4461,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-l$ac_lib $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4380 "configure"
+#line 4465 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -4387,7 +4472,7 @@ int main() {
yywrap()
; return 0; }
EOF
-if { (eval echo configure:4391: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4476: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -4410,7 +4495,7 @@ fi
fi
echo $ac_n "checking lex output file root""... $ac_c" 1>&6
-echo "configure:4414: checking lex output file root" >&5
+echo "configure:4499: checking lex output file root" >&5
if eval "test \"`echo '$''{'ac_cv_prog_lex_root'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4431,7 +4516,7 @@ echo "$ac_t""$ac_cv_prog_lex_root" 1>&6
LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
echo $ac_n "checking whether yytext is a pointer""... $ac_c" 1>&6
-echo "configure:4435: checking whether yytext is a pointer" >&5
+echo "configure:4520: checking whether yytext is a pointer" >&5
if eval "test \"`echo '$''{'ac_cv_prog_lex_yytext_pointer'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4443,14 +4528,14 @@ echo 'extern char *yytext;' >>$LEX_OUTPUT_ROOT.c
ac_save_LIBS="$LIBS"
LIBS="$LIBS $LEXLIB"
cat > conftest.$ac_ext <<EOF
-#line 4447 "configure"
+#line 4532 "configure"
#include "confdefs.h"
`cat $LEX_OUTPUT_ROOT.c`
int main() {
; return 0; }
EOF
-if { (eval echo configure:4454: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4539: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_prog_lex_yytext_pointer=yes
else
@@ -4473,7 +4558,7 @@ fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:4477: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:4562: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -4507,17 +4592,17 @@ for ac_hdr in string.h strings.h stdlib.h unistd.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:4511: checking for $ac_hdr" >&5
+echo "configure:4596: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4516 "configure"
+#line 4601 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4521: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4606: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -4543,15 +4628,15 @@ else
fi
done
-for ac_func in sbrk
+for ac_func in sbrk realpath
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:4550: checking for $ac_func" >&5
+echo "configure:4635: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4555 "configure"
+#line 4640 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -4574,7 +4659,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:4578: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4663: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -4603,12 +4688,12 @@ for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
-echo "configure:4607: checking for $ac_hdr that defines DIR" >&5
+echo "configure:4692: checking for $ac_hdr that defines DIR" >&5
if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4612 "configure"
+#line 4697 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <$ac_hdr>
@@ -4616,7 +4701,7 @@ int main() {
DIR *dirp = 0;
; return 0; }
EOF
-if { (eval echo configure:4620: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4705: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
eval "ac_cv_header_dirent_$ac_safe=yes"
else
@@ -4641,7 +4726,7 @@ done
# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
if test $ac_header_dirent = dirent.h; then
echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
-echo "configure:4645: checking for opendir in -ldir" >&5
+echo "configure:4730: checking for opendir in -ldir" >&5
ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -4649,7 +4734,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-ldir $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4653 "configure"
+#line 4738 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -4660,7 +4745,7 @@ int main() {
opendir()
; return 0; }
EOF
-if { (eval echo configure:4664: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4749: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -4682,7 +4767,7 @@ fi
else
echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
-echo "configure:4686: checking for opendir in -lx" >&5
+echo "configure:4771: checking for opendir in -lx" >&5
ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -4690,7 +4775,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lx $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 4694 "configure"
+#line 4779 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -4701,7 +4786,7 @@ int main() {
opendir()
; return 0; }
EOF
-if { (eval echo configure:4705: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4790: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -4734,12 +4819,12 @@ EOF
esac
echo $ac_n "checking whether strstr must be declared""... $ac_c" 1>&6
-echo "configure:4738: checking whether strstr must be declared" >&5
+echo "configure:4823: checking whether strstr must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_strstr'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4743 "configure"
+#line 4828 "configure"
#include "confdefs.h"
#include <stdio.h>
@@ -4760,7 +4845,7 @@ int main() {
char *(*pfn) = (char *(*)) strstr
; return 0; }
EOF
-if { (eval echo configure:4764: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4849: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_strstr=no
else
@@ -4781,12 +4866,12 @@ EOF
fi
echo $ac_n "checking whether free must be declared""... $ac_c" 1>&6
-echo "configure:4785: checking whether free must be declared" >&5
+echo "configure:4870: checking whether free must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_free'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4790 "configure"
+#line 4875 "configure"
#include "confdefs.h"
#include <stdio.h>
@@ -4807,7 +4892,7 @@ int main() {
char *(*pfn) = (char *(*)) free
; return 0; }
EOF
-if { (eval echo configure:4811: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4896: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_free=no
else
@@ -4828,12 +4913,12 @@ EOF
fi
echo $ac_n "checking whether sbrk must be declared""... $ac_c" 1>&6
-echo "configure:4832: checking whether sbrk must be declared" >&5
+echo "configure:4917: checking whether sbrk must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_sbrk'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4837 "configure"
+#line 4922 "configure"
#include "confdefs.h"
#include <stdio.h>
@@ -4854,7 +4939,7 @@ int main() {
char *(*pfn) = (char *(*)) sbrk
; return 0; }
EOF
-if { (eval echo configure:4858: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4943: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_sbrk=no
else
@@ -4875,12 +4960,12 @@ EOF
fi
echo $ac_n "checking whether getenv must be declared""... $ac_c" 1>&6
-echo "configure:4879: checking whether getenv must be declared" >&5
+echo "configure:4964: checking whether getenv must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_getenv'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4884 "configure"
+#line 4969 "configure"
#include "confdefs.h"
#include <stdio.h>
@@ -4901,7 +4986,7 @@ int main() {
char *(*pfn) = (char *(*)) getenv
; return 0; }
EOF
-if { (eval echo configure:4905: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4990: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_getenv=no
else
@@ -4922,12 +5007,12 @@ EOF
fi
echo $ac_n "checking whether environ must be declared""... $ac_c" 1>&6
-echo "configure:4926: checking whether environ must be declared" >&5
+echo "configure:5011: checking whether environ must be declared" >&5
if eval "test \"`echo '$''{'bfd_cv_decl_needed_environ'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4931 "configure"
+#line 5016 "configure"
#include "confdefs.h"
#include <stdio.h>
@@ -4948,7 +5033,7 @@ int main() {
char *(*pfn) = (char *(*)) environ
; return 0; }
EOF
-if { (eval echo configure:4952: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5037: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
bfd_cv_decl_needed_environ=no
else
@@ -4976,19 +5061,19 @@ fi
# constants, while still supporting pre-ANSI compilers which do not
# support string concatenation.
echo $ac_n "checking whether ANSI C string concatenation works""... $ac_c" 1>&6
-echo "configure:4980: checking whether ANSI C string concatenation works" >&5
+echo "configure:5065: checking whether ANSI C string concatenation works" >&5
if eval "test \"`echo '$''{'ld_cv_string_concatenation'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4985 "configure"
+#line 5070 "configure"
#include "confdefs.h"
int main() {
char *a = "a" "a";
; return 0; }
EOF
-if { (eval echo configure:4992: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5077: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ld_cv_string_concatenation=yes
else
@@ -5092,6 +5177,7 @@ fi
+
EMULATION_LIBPATH=$all_libpath
@@ -5262,7 +5348,6 @@ s%@build_alias@%$build_alias%g
s%@build_cpu@%$build_cpu%g
s%@build_vendor@%$build_vendor%g
s%@build_os@%$build_os%g
-s%@CC@%$CC%g
s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
s%@INSTALL_DATA@%$INSTALL_DATA%g
@@ -5274,12 +5359,16 @@ s%@AUTOMAKE@%$AUTOMAKE%g
s%@AUTOHEADER@%$AUTOHEADER%g
s%@MAKEINFO@%$MAKEINFO%g
s%@SET_MAKE@%$SET_MAKE%g
+s%@CC@%$CC%g
s%@LN_S@%$LN_S%g
s%@OBJEXT@%$OBJEXT%g
s%@EXEEXT@%$EXEEXT%g
s%@RANLIB@%$RANLIB%g
s%@STRIP@%$STRIP%g
s%@LIBTOOL@%$LIBTOOL%g
+s%@use_sysroot@%$use_sysroot%g
+s%@TARGET_SYSTEM_ROOT@%$TARGET_SYSTEM_ROOT%g
+s%@TARGET_SYSTEM_ROOT_DEFINE@%$TARGET_SYSTEM_ROOT_DEFINE%g
s%@WARN_CFLAGS@%$WARN_CFLAGS%g
s%@CPP@%$CPP%g
s%@ALLOCA@%$ALLOCA%g
@@ -5320,6 +5409,7 @@ s%@EMUL@%$EMUL%g
s%@TDIRS@%%g
s%@EMULATION_OFILES@%$EMULATION_OFILES%g
s%@EMUL_EXTRA_OFILES@%$EMUL_EXTRA_OFILES%g
+s%@LIB_PATH@%$LIB_PATH%g
s%@EMULATION_LIBPATH@%$EMULATION_LIBPATH%g
s%@TESTBFDLIB@%$TESTBFDLIB%g
diff --git a/contrib/binutils/ld/configure.in b/contrib/binutils/ld/configure.in
index b89c2a1..4358cbe 100644
--- a/contrib/binutils/ld/configure.in
+++ b/contrib/binutils/ld/configure.in
@@ -13,6 +13,7 @@ AM_INIT_AUTOMAKE(ld, ${BFD_VERSION})
AM_PROG_LIBTOOL
+AC_ARG_WITH(lib-path, [ --with-lib-path=dir1:dir2... set default LIB_PATH],LIB_PATH=$withval)
AC_ARG_ENABLE(targets,
[ --enable-targets alternative target configurations],
[case "${enableval}" in
@@ -29,9 +30,45 @@ AC_ARG_ENABLE(64-bit-bfd,
*) AC_MSG_ERROR(bad value ${enableval} for 64-bit-bfd option) ;;
esac],[want64=false])dnl
+AC_ARG_WITH(sysroot,
+[ --with-sysroot[=DIR] Search for usr/lib et al within DIR.],
+[
+ case ${with_sysroot} in
+ yes) TARGET_SYSTEM_ROOT='${exec_prefix}/${target_alias}/sys-root' ;;
+ *) TARGET_SYSTEM_ROOT=$with_sysroot ;;
+ esac
+
+ TARGET_SYSTEM_ROOT_DEFINE='-DTARGET_SYSTEM_ROOT=\"$(TARGET_SYSTEM_ROOT)\"'
+ use_sysroot=yes
+
+ if test "x$exec_prefix" = xNONE; then
+ if test "x$prefix" = xNONE; then
+ test_prefix=/usr/local
+ else
+ test_prefix=$prefix
+ fi
+ else
+ test_prefix=$exec_prefix
+ fi
+ case ${TARGET_SYSTEM_ROOT} in
+ "${test_prefix}"|"${test_prefix}/"*|\
+ '${exec_prefix}'|'${exec_prefix}/'*)
+ t="$TARGET_SYSTEM_ROOT_DEFINE -DTARGET_SYSTEM_ROOT_RELOCATABLE"
+ TARGET_SYSTEM_ROOT_DEFINE="$t"
+ ;;
+ esac
+], [
+ use_sysroot=no
+ TARGET_SYSTEM_ROOT=
+ TARGET_SYSTEM_ROOT_DEFINE='-DTARGET_SYSTEM_ROOT=\"\"'
+])
+AC_SUBST(use_sysroot)
+AC_SUBST(TARGET_SYSTEM_ROOT)
+AC_SUBST(TARGET_SYSTEM_ROOT_DEFINE)
+
build_warnings="-W -Wall -Wstrict-prototypes -Wmissing-prototypes"
AC_ARG_ENABLE(build-warnings,
-[ --enable-build-warnings Enable build-time compiler warnings if gcc is used],
+[ --enable-build-warnings enable build-time compiler warnings if gcc is used],
[case "${enableval}" in
yes) ;;
no) build_warnings="-w";;
@@ -64,7 +101,7 @@ fi
AC_PROG_CC
AC_PROG_INSTALL
-ALL_LINGUAS="fr sv tr es"
+ALL_LINGUAS="fr sv tr es da"
CY_GNU_GETTEXT
AC_EXEEXT
@@ -82,7 +119,7 @@ AC_SUBST(HOSTING_LIBS)
AC_SUBST(NATIVE_LIB_DIRS)
AC_CHECK_HEADERS(string.h strings.h stdlib.h unistd.h)
-AC_CHECK_FUNCS(sbrk)
+AC_CHECK_FUNCS(sbrk realpath)
AC_HEADER_DIRENT
BFD_BINARY_FOPEN
@@ -202,6 +239,7 @@ else
fi
AC_SUBST(EMULATION_OFILES)
AC_SUBST(EMUL_EXTRA_OFILES)
+AC_SUBST(LIB_PATH)
EMULATION_LIBPATH=$all_libpath
AC_SUBST(EMULATION_LIBPATH)
diff --git a/contrib/binutils/ld/deffile.h b/contrib/binutils/ld/deffile.h
index efd7834..f1e3301 100644
--- a/contrib/binutils/ld/deffile.h
+++ b/contrib/binutils/ld/deffile.h
@@ -1,5 +1,5 @@
/* deffile.h - header for .DEF file parser
- Copyright 1998, 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2002, 2003 Free Software Foundation, Inc.
Written by DJ Delorie dj@cygnus.com
This file is part of GLD, the Gnu Linker.
@@ -22,8 +22,6 @@
#ifndef DEFFILE_H
#define DEFFILE_H
-#include "ansidecl.h"
-
/* DEF storage definitions. Note that any ordinal may be zero, and
any pointer may be NULL, if not defined by the DEF file. */
@@ -52,65 +50,54 @@ typedef struct def_file_import {
def_file_module *module; /* always set */
char *name; /* may be NULL; either this or ordinal will be set */
int ordinal; /* may be -1 */
+ int data; /* = 1 if data */
} def_file_import;
typedef struct def_file {
- /* from the NAME or LIBRARY command */
+ /* From the NAME or LIBRARY command. */
char *name;
int is_dll; /* -1 if NAME/LIBRARY not given */
bfd_vma base_address; /* (bfd_vma)(-1) if unspecified */
- /* from the DESCRIPTION command */
+ /* From the DESCRIPTION command. */
char *description;
- /* from the STACK/HEAP command, -1 if unspecified */
+ /* From the STACK/HEAP command, -1 if unspecified. */
int stack_reserve, stack_commit;
int heap_reserve, heap_commit;
- /* from the SECTION/SEGMENT commands */
+ /* From the SECTION/SEGMENT commands. */
int num_section_defs;
def_file_section *section_defs;
- /* from the EXPORTS commands */
+ /* From the EXPORTS commands. */
int num_exports;
def_file_export *exports;
- /* used by imports for module names */
+ /* Used by imports for module names. */
def_file_module *modules;
- /* from the IMPORTS commands */
+ /* From the IMPORTS commands. */
int num_imports;
def_file_import *imports;
- /* from the VERSION command, -1 if not specified */
+ /* From the VERSION command, -1 if not specified. */
int version_major, version_minor;
} def_file;
-extern def_file *def_file_empty PARAMS ((void));
-
-/* add_to may be NULL. If not, this .def is appended to it */
-extern def_file *def_file_parse PARAMS ((const char *_filename,
- def_file * _add_to));
-
-extern void def_file_free PARAMS ((def_file * _def));
-
-extern def_file_export *def_file_add_export PARAMS ((def_file * _def,
- const char *_name,
- const char *_internal_name,
- int _ordinal));
-
-extern def_file_import *def_file_add_import PARAMS ((def_file * _def,
- const char *_name,
- const char *_from,
- int _ordinal,
- const char *_imported_name));
-
-extern void def_file_add_directive PARAMS ((def_file * _def,
- const char *param,
- int len));
-
+extern def_file *def_file_empty (void);
+
+/* The second arg may be NULL. If not, this .def is appended to it. */
+extern def_file *def_file_parse (const char *, def_file *);
+extern void def_file_free (def_file *);
+extern def_file_export *def_file_add_export (def_file *, const char *,
+ const char *, int);
+extern def_file_import *def_file_add_import (def_file *, const char *,
+ const char *, int, const char *);
+extern void def_file_add_directive (def_file *, const char *, int);
+extern def_file_module *def_get_module (def_file *, const char *);
#ifdef DEF_FILE_PRINT
-extern void def_file_print PARAMS ((FILE * _file, def_file * _def));
+extern void def_file_print (FILE *, def_file *);
#endif
#endif /* DEFFILE_H */
diff --git a/contrib/binutils/ld/deffilep.y b/contrib/binutils/ld/deffilep.y
index 51d17f8..80cf548 100644
--- a/contrib/binutils/ld/deffilep.y
+++ b/contrib/binutils/ld/deffilep.y
@@ -1,23 +1,23 @@
%{ /* deffilep.y - parser for .def files */
-/* Copyright 1995, 1997, 1998, 1999, 2000, 2001
+/* Copyright 1995, 1997, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
-This file is part of GNU Binutils.
+ This file is part of GNU Binutils.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include <stdio.h>
#include "libiberty.h"
@@ -37,7 +37,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
yacc generated parsers in ld. Note that these are only the variables
produced by yacc. If other parser generators (bison, byacc, etc) produce
additional global names that conflict at link time, then those parser
- generators need to be fixed instead of adding those names to this list. */
+ generators need to be fixed instead of adding those names to this list. */
#define yymaxdepth def_maxdepth
#define yyparse def_parse
@@ -66,8 +66,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define yy_yyv def_yyv
#define yyval def_val
#define yylloc def_lloc
-#define yyreds def_reds /* With YYDEBUG defined */
-#define yytoks def_toks /* With YYDEBUG defined */
+#define yyreds def_reds /* With YYDEBUG defined. */
+#define yytoks def_toks /* With YYDEBUG defined. */
#define yylhs def_yylhs
#define yylen def_yylen
#define yydefred def_yydefred
@@ -78,25 +78,21 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define yytable def_yytable
#define yycheck def_yycheck
-static void def_description PARAMS ((const char *));
-static void def_exports PARAMS ((const char *, const char *, int, int));
-static void def_heapsize PARAMS ((int, int));
-static void def_import
- PARAMS ((const char *, const char *, const char *, const char *, int));
-static void def_library PARAMS ((const char *, int));
-static def_file_module *def_stash_module PARAMS ((def_file *, const char *));
-static void def_name PARAMS ((const char *, int));
-static void def_section PARAMS ((const char *, int));
-static void def_section_alt PARAMS ((const char *, const char *));
-static void def_stacksize PARAMS ((int, int));
-static void def_version PARAMS ((int, int));
-static void def_directive PARAMS ((char *));
-static int def_parse PARAMS ((void));
-static int def_error PARAMS ((const char *));
-static void put_buf PARAMS ((char));
-static int def_getc PARAMS ((void));
-static int def_ungetc PARAMS ((int));
-static int def_lex PARAMS ((void));
+static void def_description (const char *);
+static void def_exports (const char *, const char *, int, int);
+static void def_heapsize (int, int);
+static void def_import (const char *, const char *, const char *, const char *,
+ int);
+static void def_library (const char *, int);
+static void def_name (const char *, int);
+static void def_section (const char *, int);
+static void def_section_alt (const char *, const char *);
+static void def_stacksize (int, int);
+static void def_version (int, int);
+static void def_directive (char *);
+static int def_parse (void);
+static int def_error (const char *);
+static int def_lex (void);
static int lex_forced_token = 0;
static const char *lex_parse_string = 0;
@@ -109,15 +105,15 @@ static const char *lex_parse_string_end = 0;
int number;
};
-%token NAME, LIBRARY, DESCRIPTION, STACKSIZE, HEAPSIZE, CODE, DATAU, DATAL
-%token SECTIONS, EXPORTS, IMPORTS, VERSIONK, BASE, CONSTANTU, CONSTANTL
-%token PRIVATEU, PRIVATEL
+%token NAME LIBRARY DESCRIPTION STACKSIZE HEAPSIZE CODE DATAU DATAL
+%token SECTIONS EXPORTS IMPORTS VERSIONK BASE CONSTANTU CONSTANTL
+%token PRIVATEU PRIVATEL
%token READ WRITE EXECUTE SHARED NONAMEU NONAMEL DIRECTIVE
%token <id> ID
%token <number> NUMBER
%type <number> opt_base opt_ordinal
%type <number> attr attr_list opt_number exp_opt_list exp_opt
-%type <id> opt_name opt_equal_name
+%type <id> opt_name opt_equal_name dot_name
%%
@@ -152,7 +148,7 @@ expline:
/* The opt_comma is necessary to support both the usual
DEF file syntax as well as .drectve syntax which
mandates <expsym>,<expoptlist>. */
- ID opt_equal_name opt_ordinal opt_comma exp_opt_list
+ dot_name opt_equal_name opt_ordinal opt_comma exp_opt_list
{ def_exports ($1, $2, $3, $5); }
;
exp_opt_list:
@@ -219,7 +215,7 @@ attr:
opt_name: ID { $$ = $1; }
| ID '.' ID
{
- char * name = xmalloc (strlen ($1) + 1 + strlen ($3) + 1);
+ char *name = xmalloc (strlen ($1) + 1 + strlen ($3) + 1);
sprintf (name, "%s.%s", $1, $3);
$$ = name;
}
@@ -232,14 +228,22 @@ opt_ordinal:
;
opt_equal_name:
- '=' ID { $$ = $2; }
+ '=' dot_name { $$ = $2; }
| { $$ = 0; }
;
opt_base: BASE '=' NUMBER { $$ = $3;}
- | { $$ = 0;}
+ | { $$ = -1;}
;
+dot_name: ID { $$ = $1; }
+ | dot_name '.' ID
+ {
+ char *name = xmalloc (strlen ($1) + 1 + strlen ($3) + 1);
+ sprintf (name, "%s.%s", $1, $3);
+ $$ = name;
+ }
+ ;
%%
@@ -264,12 +268,12 @@ struct directive
static struct directive *directives = 0;
def_file *
-def_file_empty ()
+def_file_empty (void)
{
- def_file *rv = (def_file *) xmalloc (sizeof (def_file));
+ def_file *rv = xmalloc (sizeof (def_file));
memset (rv, 0, sizeof (def_file));
rv->is_dll = -1;
- rv->base_address = (bfd_vma) (-1);
+ rv->base_address = (bfd_vma) -1;
rv->stack_reserve = rv->stack_commit = -1;
rv->heap_reserve = rv->heap_commit = -1;
rv->version_major = rv->version_minor = -1;
@@ -277,9 +281,7 @@ def_file_empty ()
}
def_file *
-def_file_parse (filename, add_to)
- const char *filename;
- def_file *add_to;
+def_file_parse (const char *filename, def_file *add_to)
{
struct directive *d;
@@ -322,10 +324,10 @@ def_file_parse (filename, add_to)
}
void
-def_file_free (def)
- def_file *def;
+def_file_free (def_file *def)
{
int i;
+
if (!def)
return;
if (def->name)
@@ -383,17 +385,16 @@ def_file_free (def)
#ifdef DEF_FILE_PRINT
void
-def_file_print (file, def)
- FILE *file;
- def_file *def;
+def_file_print (FILE *file, def_file *def)
{
int i;
+
fprintf (file, ">>>> def_file at 0x%08x\n", def);
if (def->name)
fprintf (file, " name: %s\n", def->name ? def->name : "(unspecified)");
if (def->is_dll != -1)
fprintf (file, " is dll: %s\n", def->is_dll ? "yes" : "no");
- if (def->base_address != (bfd_vma) (-1))
+ if (def->base_address != (bfd_vma) -1)
fprintf (file, " base address: 0x%08x\n", def->base_address);
if (def->description)
fprintf (file, " description: `%s'\n", def->description);
@@ -409,6 +410,7 @@ def_file_print (file, def)
if (def->num_section_defs > 0)
{
fprintf (file, " section defs:\n");
+
for (i = 0; i < def->num_section_defs; i++)
{
fprintf (file, " name: `%s', class: `%s', flags:",
@@ -428,6 +430,7 @@ def_file_print (file, def)
if (def->num_exports > 0)
{
fprintf (file, " exports:\n");
+
for (i = 0; i < def->num_exports; i++)
{
fprintf (file, " name: `%s', int: `%s', ordinal: %d, flags:",
@@ -448,6 +451,7 @@ def_file_print (file, def)
if (def->num_imports > 0)
{
fprintf (file, " imports:\n");
+
for (i = 0; i < def->num_imports; i++)
{
fprintf (file, " int: %s, from: `%s', name: `%s', ordinal: %d\n",
@@ -457,28 +461,31 @@ def_file_print (file, def)
def->imports[i].ordinal);
}
}
+
if (def->version_major != -1)
fprintf (file, " version: %d.%d\n", def->version_major, def->version_minor);
+
fprintf (file, "<<<< def_file at 0x%08x\n", def);
}
#endif
def_file_export *
-def_file_add_export (def, external_name, internal_name, ordinal)
- def_file *def;
- const char *external_name;
- const char *internal_name;
- int ordinal;
+def_file_add_export (def_file *def,
+ const char *external_name,
+ const char *internal_name,
+ int ordinal)
{
def_file_export *e;
int max_exports = ROUND_UP(def->num_exports, 32);
+
if (def->num_exports >= max_exports)
{
- max_exports = ROUND_UP(def->num_exports+1, 32);
+ max_exports = ROUND_UP(def->num_exports + 1, 32);
if (def->exports)
- def->exports = (def_file_export *) xrealloc (def->exports, max_exports * sizeof (def_file_export));
+ def->exports = xrealloc (def->exports,
+ max_exports * sizeof (def_file_export));
else
- def->exports = (def_file_export *) xmalloc (max_exports * sizeof (def_file_export));
+ def->exports = xmalloc (max_exports * sizeof (def_file_export));
}
e = def->exports + def->num_exports;
memset (e, 0, sizeof (def_file_export));
@@ -493,16 +500,26 @@ def_file_add_export (def, external_name, internal_name, ordinal)
return e;
}
-static def_file_module *
-def_stash_module (def, name)
- def_file *def;
- const char *name;
+def_file_module *
+def_get_module (def_file *def, const char *name)
{
def_file_module *s;
- for (s=def->modules; s; s=s->next)
+
+ for (s = def->modules; s; s = s->next)
if (strcmp (s->name, name) == 0)
return s;
- s = (def_file_module *) xmalloc (sizeof (def_file_module) + strlen (name));
+
+ return NULL;
+}
+
+static def_file_module *
+def_stash_module (def_file *def, const char *name)
+{
+ def_file_module *s;
+
+ if ((s = def_get_module (def, name)) != NULL)
+ return s;
+ s = xmalloc (sizeof (def_file_module) + strlen (name));
s->next = def->modules;
def->modules = s;
s->user_data = 0;
@@ -511,22 +528,24 @@ def_stash_module (def, name)
}
def_file_import *
-def_file_add_import (def, name, module, ordinal, internal_name)
- def_file *def;
- const char *name;
- const char *module;
- int ordinal;
- const char *internal_name;
+def_file_add_import (def_file *def,
+ const char *name,
+ const char *module,
+ int ordinal,
+ const char *internal_name)
{
def_file_import *i;
- int max_imports = ROUND_UP(def->num_imports, 16);
+ int max_imports = ROUND_UP (def->num_imports, 16);
+
if (def->num_imports >= max_imports)
{
- max_imports = ROUND_UP(def->num_imports+1, 16);
+ max_imports = ROUND_UP (def->num_imports+1, 16);
+
if (def->imports)
- def->imports = (def_file_import *) xrealloc (def->imports, max_imports * sizeof (def_file_import));
+ def->imports = xrealloc (def->imports,
+ max_imports * sizeof (def_file_import));
else
- def->imports = (def_file_import *) xmalloc (max_imports * sizeof (def_file_import));
+ def->imports = xmalloc (max_imports * sizeof (def_file_import));
}
i = def->imports + def->num_imports;
memset (i, 0, sizeof (def_file_import));
@@ -540,6 +559,7 @@ def_file_add_import (def, name, module, ordinal, internal_name)
else
i->internal_name = i->name;
def->num_imports++;
+
return i;
}
@@ -558,29 +578,40 @@ diropts[] =
};
void
-def_file_add_directive (my_def, param, len)
- def_file *my_def;
- const char *param;
- int len;
+def_file_add_directive (def_file *my_def, const char *param, int len)
{
def_file *save_def = def;
const char *pend = param + len;
- const char *tend = param;
+ char * tend = (char *) param;
int i;
def = my_def;
while (param < pend)
{
- while (param < pend && ISSPACE (*param))
+ while (param < pend
+ && (ISSPACE (*param) || *param == '\n' || *param == 0))
param++;
- for (tend = param + 1;
- tend < pend && !(ISSPACE (tend[-1]) && *tend == '-');
- tend++);
+
+ if (param == pend)
+ break;
+
+ /* Scan forward until we encounter any of:
+ - the end of the buffer
+ - the start of a new option
+ - a newline seperating options
+ - a NUL seperating options. */
+ for (tend = (char *) (param + 1);
+ (tend < pend
+ && !(ISSPACE (tend[-1]) && *tend == '-')
+ && *tend != '\n' && *tend != 0);
+ tend++)
+ ;
for (i = 0; diropts[i].param; i++)
{
int len = strlen (diropts[i].param);
+
if (tend - param >= len
&& strncmp (param, diropts[i].param, len) == 0
&& (param[len] == ':' || param[len] == ' '))
@@ -589,17 +620,23 @@ def_file_add_directive (my_def, param, len)
lex_parse_string = param + len + 1;
lex_forced_token = diropts[i].token;
saw_newline = 0;
- def_parse ();
+ if (def_parse ())
+ continue;
break;
}
}
if (!diropts[i].param)
{
+ char saved;
+
+ saved = * tend;
+ * tend = 0;
/* xgettext:c-format */
- einfo (_("Warning: .drectve `%.*s' unrecognized\n"),
- tend - param, param);
+ einfo (_("Warning: .drectve `%s' unrecognized\n"), param);
+ * tend = saved;
}
+
lex_parse_string = 0;
param = tend;
}
@@ -607,14 +644,10 @@ def_file_add_directive (my_def, param, len)
def = save_def;
}
-/*****************************************************************************
- Parser Callbacks
- *****************************************************************************/
+/* Parser Callbacks. */
static void
-def_name (name, base)
- const char *name;
- int base;
+def_name (const char *name, int base)
{
if (def->name)
free (def->name);
@@ -624,9 +657,7 @@ def_name (name, base)
}
static void
-def_library (name, base)
- const char *name;
- int base;
+def_library (const char *name, int base)
{
if (def->name)
free (def->name);
@@ -636,55 +667,52 @@ def_library (name, base)
}
static void
-def_description (text)
- const char *text;
+def_description (const char *text)
{
int len = def->description ? strlen (def->description) : 0;
+
len += strlen (text) + 1;
if (def->description)
{
- def->description = (char *) xrealloc (def->description, len);
+ def->description = xrealloc (def->description, len);
strcat (def->description, text);
}
else
{
- def->description = (char *) xmalloc (len);
+ def->description = xmalloc (len);
strcpy (def->description, text);
}
}
static void
-def_stacksize (reserve, commit)
- int reserve;
- int commit;
+def_stacksize (int reserve, int commit)
{
def->stack_reserve = reserve;
def->stack_commit = commit;
}
static void
-def_heapsize (reserve, commit)
- int reserve;
- int commit;
+def_heapsize (int reserve, int commit)
{
def->heap_reserve = reserve;
def->heap_commit = commit;
}
static void
-def_section (name, attr)
- const char *name;
- int attr;
+def_section (const char *name, int attr)
{
def_file_section *s;
- int max_sections = ROUND_UP(def->num_section_defs, 4);
+ int max_sections = ROUND_UP (def->num_section_defs, 4);
+
if (def->num_section_defs >= max_sections)
{
- max_sections = ROUND_UP(def->num_section_defs+1, 4);
+ max_sections = ROUND_UP (def->num_section_defs+1, 4);
+
if (def->section_defs)
- def->section_defs = (def_file_section *) xrealloc (def->section_defs, max_sections * sizeof (def_file_import));
+ def->section_defs = xrealloc (def->section_defs,
+ max_sections * sizeof (def_file_import));
else
- def->section_defs = (def_file_section *) xmalloc (max_sections * sizeof (def_file_import));
+ def->section_defs = xmalloc (max_sections * sizeof (def_file_import));
}
s = def->section_defs + def->num_section_defs;
memset (s, 0, sizeof (def_file_section));
@@ -702,11 +730,10 @@ def_section (name, attr)
}
static void
-def_section_alt (name, attr)
- const char *name;
- const char *attr;
+def_section_alt (const char *name, const char *attr)
{
int aval = 0;
+
for (; *attr; attr++)
{
switch (*attr)
@@ -733,11 +760,10 @@ def_section_alt (name, attr)
}
static void
-def_exports (external_name, internal_name, ordinal, flags)
- const char *external_name;
- const char *internal_name;
- int ordinal;
- int flags;
+def_exports (const char *external_name,
+ const char *internal_name,
+ int ordinal,
+ int flags)
{
def_file_export *dfe;
@@ -759,21 +785,18 @@ def_exports (external_name, internal_name, ordinal, flags)
}
static void
-def_import (internal_name, module, dllext, name, ordinal)
- const char *internal_name;
- const char *module;
- const char *dllext;
- const char *name;
- int ordinal;
+def_import (const char *internal_name,
+ const char *module,
+ const char *dllext,
+ const char *name,
+ int ordinal)
{
char *buf = 0;
-
- if (dllext != NULL)
- {
- buf = (char *) xmalloc (strlen (module) + strlen (dllext) + 2);
- sprintf (buf, "%s.%s", module, dllext);
- module = buf;
- }
+ const char *ext = dllext ? dllext : "dll";
+
+ buf = xmalloc (strlen (module) + strlen (ext) + 2);
+ sprintf (buf, "%s.%s", module, ext);
+ module = buf;
def_file_add_import (def, name, module, ordinal, internal_name);
if (buf)
@@ -781,19 +804,17 @@ def_import (internal_name, module, dllext, name, ordinal)
}
static void
-def_version (major, minor)
- int major;
- int minor;
+def_version (int major, int minor)
{
def->version_major = major;
def->version_minor = minor;
}
static void
-def_directive (str)
- char *str;
+def_directive (char *str)
{
- struct directive *d = (struct directive *) xmalloc (sizeof (struct directive));
+ struct directive *d = xmalloc (sizeof (struct directive));
+
d->next = directives;
directives = d;
d->name = xstrdup (str);
@@ -801,41 +822,37 @@ def_directive (str)
}
static int
-def_error (err)
- const char *err;
+def_error (const char *err)
{
- einfo ("%P: %s:%d: %s\n", def_filename, linenumber, err);
-
+ einfo ("%P: %s:%d: %s\n",
+ def_filename ? def_filename : "<unknown-file>", linenumber, err);
return 0;
}
-/*****************************************************************************
- Lexical Scanner
- *****************************************************************************/
+/* Lexical Scanner. */
#undef TRACE
#define TRACE 0
-/* Never freed, but always reused as needed, so no real leak */
+/* Never freed, but always reused as needed, so no real leak. */
static char *buffer = 0;
static int buflen = 0;
static int bufptr = 0;
static void
-put_buf (c)
- char c;
+put_buf (char c)
{
if (bufptr == buflen)
{
- buflen += 50; /* overly reasonable, eh? */
+ buflen += 50; /* overly reasonable, eh? */
if (buffer)
- buffer = (char *) xrealloc (buffer, buflen + 1);
+ buffer = xrealloc (buffer, buflen + 1);
else
- buffer = (char *) xmalloc (buflen + 1);
+ buffer = xmalloc (buflen + 1);
}
buffer[bufptr++] = c;
- buffer[bufptr] = 0; /* not optimal, but very convenient */
+ buffer[bufptr] = 0; /* not optimal, but very convenient. */
}
static struct
@@ -874,9 +891,10 @@ tokens[] =
};
static int
-def_getc ()
+def_getc (void)
{
int rv;
+
if (lex_parse_string)
{
if (lex_parse_string >= lex_parse_string_end)
@@ -894,8 +912,7 @@ def_getc ()
}
static int
-def_ungetc (c)
- int c;
+def_ungetc (int c)
{
if (lex_parse_string)
{
@@ -907,7 +924,7 @@ def_ungetc (c)
}
static int
-def_lex ()
+def_lex (void)
{
int c, i, q;
@@ -923,7 +940,7 @@ def_lex ()
c = def_getc ();
- /* trim leading whitespace */
+ /* Trim leading whitespace. */
while (c != EOF && (c == ' ' || c == '\t') && saw_newline)
c = def_getc ();
@@ -946,7 +963,8 @@ def_lex ()
return def_lex ();
return 0;
}
- /* must be something else */
+
+ /* Must be something else. */
saw_newline = 0;
if (ISDIGIT (c))
@@ -966,9 +984,27 @@ def_lex ()
return NUMBER;
}
- if (ISALPHA (c) || strchr ("$:-_?", c))
+ if (ISALPHA (c) || strchr ("$:-_?@", c))
{
bufptr = 0;
+ q = c;
+ put_buf (c);
+ c = def_getc ();
+
+ if (q == '@')
+ {
+ if (ISBLANK (c) ) /* '@' followed by whitespace. */
+ return (q);
+ else if (ISDIGIT (c)) /* '@' followed by digit. */
+ {
+ def_ungetc (c);
+ return (q);
+ }
+#if TRACE
+ printf ("lex: @ returns itself\n");
+#endif
+ }
+
while (c != EOF && (ISALNUM (c) || strchr ("$:-_?/@", c)))
{
put_buf (c);
@@ -976,14 +1012,17 @@ def_lex ()
}
if (c != EOF)
def_ungetc (c);
- for (i = 0; tokens[i].name; i++)
- if (strcmp (tokens[i].name, buffer) == 0)
- {
+ if (ISALPHA (q)) /* Check for tokens. */
+ {
+ for (i = 0; tokens[i].name; i++)
+ if (strcmp (tokens[i].name, buffer) == 0)
+ {
#if TRACE
- printf ("lex: `%s' is a string token\n", buffer);
+ printf ("lex: `%s' is a string token\n", buffer);
#endif
- return tokens[i].token;
- }
+ return tokens[i].token;
+ }
+ }
#if TRACE
printf ("lex: `%s' returns ID\n", buffer);
#endif
@@ -996,6 +1035,7 @@ def_lex ()
q = c;
c = def_getc ();
bufptr = 0;
+
while (c != EOF && c != q)
{
put_buf (c);
@@ -1008,7 +1048,7 @@ def_lex ()
return ID;
}
- if (c == '=' || c == '.' || c == '@' || c == ',')
+ if (c == '=' || c == '.' || c == ',')
{
#if TRACE
printf ("lex: `%c' returns itself\n", c);
diff --git a/contrib/binutils/ld/dep-in.sed b/contrib/binutils/ld/dep-in.sed
index aad7d92..83418e2 100644
--- a/contrib/binutils/ld/dep-in.sed
+++ b/contrib/binutils/ld/dep-in.sed
@@ -8,6 +8,7 @@ s!@BFDDIR@!$(BFDDIR)!g
s!@TOPDIR@/bfd!$(BFDDIR)!g
s!@SRCDIR@/!!g
s! \.\./bfd/hosts/[^ ]*\.h! !g
+s! \.\./intl/libintl\.h!!g
s/\\\n */ /g
diff --git a/contrib/binutils/ld/emulparams/arcelf.sh b/contrib/binutils/ld/emulparams/arcelf.sh
new file mode 100644
index 0000000..b1c9c17
--- /dev/null
+++ b/contrib/binutils/ld/emulparams/arcelf.sh
@@ -0,0 +1,11 @@
+SCRIPT_NAME=elf
+OUTPUT_FORMAT="elf32-littlearc"
+LITTLE_OUTPUT_FORMAT="elf32-littlearc"
+BIG_OUTPUT_FORMAT="elf32-bigarc"
+TEXT_START_ADDR=0x0
+MAXPAGESIZE=0x1000
+NONPAGED_TEXT_START_ADDR=0x0
+ARCH=arc
+MACHINE=
+ENTRY=start
+#TEMPLATE_NAME=elf32
diff --git a/contrib/binutils/ld/emulparams/armelf.sh b/contrib/binutils/ld/emulparams/armelf.sh
index 0e8ebc5..35a6d23 100644
--- a/contrib/binutils/ld/emulparams/armelf.sh
+++ b/contrib/binutils/ld/emulparams/armelf.sh
@@ -9,6 +9,7 @@ EXTRA_EM_FILE=armelf
OTHER_TEXT_SECTIONS='*(.glue_7t) *(.glue_7)'
OTHER_BSS_SYMBOLS='__bss_start__ = .;'
OTHER_BSS_END_SYMBOLS='_bss_end__ = . ; __bss_end__ = . ; __end__ = . ;'
+OTHER_SECTIONS='.note.gnu.arm.ident 0 : { KEEP (*(.note.gnu.arm.ident)) }'
DATA_START_SYMBOLS='__data_start = . ;';
@@ -22,3 +23,6 @@ EMBEDDED=yes
# This sets the stack to the top of the simulator memory (2^19 bytes).
STACK_ADDR=0x80000
+
+# ARM does not support .s* sections.
+NO_SMALL_DATA=yes
diff --git a/contrib/binutils/ld/emulparams/armelf_linux.sh b/contrib/binutils/ld/emulparams/armelf_linux.sh
index d04d967..88a2d19 100644
--- a/contrib/binutils/ld/emulparams/armelf_linux.sh
+++ b/contrib/binutils/ld/emulparams/armelf_linux.sh
@@ -4,6 +4,7 @@ OUTPUT_FORMAT="elf32-littlearm"
BIG_OUTPUT_FORMAT="elf32-bigarm"
LITTLE_OUTPUT_FORMAT="elf32-littlearm"
MAXPAGESIZE=0x8000
+COMMONPAGESIZE=0x1000
TEMPLATE_NAME=elf32
EXTRA_EM_FILE=armelf
GENERATE_SHLIB_SCRIPT=yes
@@ -12,5 +13,9 @@ DATA_START_SYMBOLS='__data_start = . ;';
OTHER_TEXT_SECTIONS='*(.glue_7t) *(.glue_7)'
OTHER_BSS_SYMBOLS='__bss_start__ = .;'
OTHER_BSS_END_SYMBOLS='_bss_end__ = . ; __bss_end__ = . ; __end__ = . ;'
+OTHER_SECTIONS='.note.gnu.arm.ident 0 : { KEEP (*(.note.gnu.arm.ident)) }'
TEXT_START_ADDR=0x00008000
+
+# ARM does not support .s* sections.
+NO_SMALL_DATA=yes
diff --git a/contrib/binutils/ld/emulparams/armelf_oabi.sh b/contrib/binutils/ld/emulparams/armelf_oabi.sh
index f1c967d..0c2c1d3 100644
--- a/contrib/binutils/ld/emulparams/armelf_oabi.sh
+++ b/contrib/binutils/ld/emulparams/armelf_oabi.sh
@@ -18,3 +18,6 @@ EMBEDDED=yes
# This sets the stack to the top of the simulator memory (2^19 bytes).
STACK_ADDR=0x80000
+
+# ARM does not support .s* sections.
+NO_SMALL_DATA=yes
diff --git a/contrib/binutils/ld/emulparams/armpe.sh b/contrib/binutils/ld/emulparams/armpe.sh
index 257c9de..aa60536 100644
--- a/contrib/binutils/ld/emulparams/armpe.sh
+++ b/contrib/binutils/ld/emulparams/armpe.sh
@@ -1,8 +1,12 @@
ARCH=arm
SCRIPT_NAME=pe
+
OUTPUT_FORMAT="pei-arm-little"
LITTLE_OUTPUT_FORMAT="pei-arm-little"
BIG_OUTPUT_FORMAT="pei-arm-big"
+
+RELOCATEABLE_OUTPUT_FORMAT="pe-arm-little"
+
TEMPLATE_NAME=pe
ENTRY="_mainCRTStartup"
SUBSYSTEM=PE_DEF_SUBSYSTEM
diff --git a/contrib/binutils/ld/emulparams/elf32_sparc.sh b/contrib/binutils/ld/emulparams/elf32_sparc.sh
index 15a837d..af23252 100644
--- a/contrib/binutils/ld/emulparams/elf32_sparc.sh
+++ b/contrib/binutils/ld/emulparams/elf32_sparc.sh
@@ -10,4 +10,5 @@ MACHINE=
TEMPLATE_NAME=elf32
DATA_PLT=
GENERATE_SHLIB_SCRIPT=yes
+GENERATE_PIE_SCRIPT=yes
NO_SMALL_DATA=yes
diff --git a/contrib/binutils/ld/emulparams/elf32b4300.sh b/contrib/binutils/ld/emulparams/elf32b4300.sh
new file mode 100644
index 0000000..d3e4354
--- /dev/null
+++ b/contrib/binutils/ld/emulparams/elf32b4300.sh
@@ -0,0 +1,10 @@
+# If you change this file, please also look at files which source this one:
+# elf32l4300.sh
+
+EMBEDDED=yes
+. ${srcdir}/emulparams/elf32bmip.sh
+TEXT_START_ADDR=0xa0020000
+unset NONPAGED_TEXT_START_ADDR
+unset SHLIB_TEXT_START_ADDR
+EXECUTABLE_SYMBOLS='_DYNAMIC_LINK = 0;'
+DYNAMIC_LINK=FALSE
diff --git a/contrib/binutils/ld/emulparams/elf32bmip.sh b/contrib/binutils/ld/emulparams/elf32bmip.sh
new file mode 100644
index 0000000..94e1c9c
--- /dev/null
+++ b/contrib/binutils/ld/emulparams/elf32bmip.sh
@@ -0,0 +1,37 @@
+# If you change this file, please also look at files which source this one:
+# elf32b4300.sh elf32bsmip.sh elf32btsmip.sh elf32ebmip.sh elf32lmip.sh
+
+SCRIPT_NAME=elf
+OUTPUT_FORMAT="elf32-bigmips"
+BIG_OUTPUT_FORMAT="elf32-bigmips"
+LITTLE_OUTPUT_FORMAT="elf32-littlemips"
+TEXT_START_ADDR=0x0400000
+test -n "${EMBEDDED}" || DATA_ADDR=0x10000000
+MAXPAGESIZE=0x40000
+COMMONPAGESIZE=0x1000
+NONPAGED_TEXT_START_ADDR=0x0400000
+SHLIB_TEXT_START_ADDR=0x5ffe0000
+test -n "${EMBEDDED}" || TEXT_DYNAMIC=
+INITIAL_READONLY_SECTIONS="
+ .reginfo ${RELOCATING-0} : { *(.reginfo) }
+"
+OTHER_TEXT_SECTIONS='*(.mips16.fn.*) *(.mips16.call.*)'
+OTHER_GOT_SYMBOLS='
+ _gp = ALIGN(16) + 0x7ff0;
+'
+OTHER_SDATA_SECTIONS="
+ .lit8 ${RELOCATING-0} : { *(.lit8) }
+ .lit4 ${RELOCATING-0} : { *(.lit4) }
+"
+TEXT_START_SYMBOLS='_ftext = . ;'
+DATA_START_SYMBOLS='_fdata = . ;'
+OTHER_BSS_SYMBOLS='_fbss = .;'
+OTHER_SECTIONS='
+ .gptab.sdata : { *(.gptab.data) *(.gptab.sdata) }
+ .gptab.sbss : { *(.gptab.bss) *(.gptab.sbss) }
+'
+ARCH=mips
+MACHINE=
+TEMPLATE_NAME=elf32
+EXTRA_EM_FILE=mipself
+GENERATE_SHLIB_SCRIPT=yes
diff --git a/contrib/binutils/ld/emulparams/elf32bmipn32.sh b/contrib/binutils/ld/emulparams/elf32bmipn32.sh
new file mode 100755
index 0000000..a320eb2
--- /dev/null
+++ b/contrib/binutils/ld/emulparams/elf32bmipn32.sh
@@ -0,0 +1,22 @@
+. ${srcdir}/emulparams/elf32bmipn32-defs.sh
+OUTPUT_FORMAT="elf32-nbigmips"
+BIG_OUTPUT_FORMAT="elf32-nbigmips"
+LITTLE_OUTPUT_FORMAT="elf32-nlittlemips"
+SHLIB_TEXT_START_ADDR=0x5ffe0000
+COMMONPAGESIZE=0x1000
+
+# IRIX6 defines these symbols. 0x34 is the size of the ELF header.
+EXECUTABLE_SYMBOLS="
+ __dso_displacement = 0;
+ __elf_header = ${TEXT_START_ADDR};
+ __program_header_table = ${TEXT_START_ADDR} + 0x34;
+"
+
+# There are often dynamic relocations against the .rodata section.
+# Setting DT_TEXTREL in the .dynamic section does not convince the
+# IRIX6 linker to permit relocations against the text segment.
+# Following the IRIX linker, we simply put .rodata in the data
+# segment.
+WRITABLE_RODATA=
+
+EXTRA_EM_FILE=irix
diff --git a/contrib/binutils/ld/emulparams/elf32bsmip.sh b/contrib/binutils/ld/emulparams/elf32bsmip.sh
new file mode 100755
index 0000000..dfe0fe0
--- /dev/null
+++ b/contrib/binutils/ld/emulparams/elf32bsmip.sh
@@ -0,0 +1,3 @@
+. ${srcdir}/emulparams/elf32bmip.sh
+ENTRY=__start
+EXTRA_EM_FILE=irix
diff --git a/contrib/binutils/ld/emulparams/elf32ebmip.sh b/contrib/binutils/ld/emulparams/elf32ebmip.sh
new file mode 100644
index 0000000..704b43e
--- /dev/null
+++ b/contrib/binutils/ld/emulparams/elf32ebmip.sh
@@ -0,0 +1,2 @@
+EMBEDDED=yes
+. ${srcdir}/emulparams/elf32bmip.sh
diff --git a/contrib/binutils/ld/emulparams/elf32elmip.sh b/contrib/binutils/ld/emulparams/elf32elmip.sh
new file mode 100644
index 0000000..c94e503
--- /dev/null
+++ b/contrib/binutils/ld/emulparams/elf32elmip.sh
@@ -0,0 +1,2 @@
+EMBEDDED=yes
+. ${srcdir}/emulparams/elf32lmip.sh
diff --git a/contrib/binutils/ld/emulparams/elf32l4300.sh b/contrib/binutils/ld/emulparams/elf32l4300.sh
new file mode 100644
index 0000000..865792a
--- /dev/null
+++ b/contrib/binutils/ld/emulparams/elf32l4300.sh
@@ -0,0 +1,4 @@
+. ${srcdir}/emulparams/elf32b4300.sh
+OUTPUT_FORMAT="elf32-littlemips"
+BIG_OUTPUT_FORMAT="elf32-bigmips"
+LITTLE_OUTPUT_FORMAT="elf32-littlemips"
diff --git a/contrib/binutils/ld/emulparams/elf32lmip.sh b/contrib/binutils/ld/emulparams/elf32lmip.sh
new file mode 100644
index 0000000..14d4ded
--- /dev/null
+++ b/contrib/binutils/ld/emulparams/elf32lmip.sh
@@ -0,0 +1,7 @@
+# If you change this file, please also look at files which source this one:
+# elf32elmip.sh elf32lsmip.sh
+
+. ${srcdir}/emulparams/elf32bmip.sh
+OUTPUT_FORMAT="elf32-littlemips"
+BIG_OUTPUT_FORMAT="elf32-bigmips"
+LITTLE_OUTPUT_FORMAT="elf32-littlemips"
diff --git a/contrib/binutils/ld/emulparams/elf32lsmip.sh b/contrib/binutils/ld/emulparams/elf32lsmip.sh
new file mode 100755
index 0000000..62e4f98
--- /dev/null
+++ b/contrib/binutils/ld/emulparams/elf32lsmip.sh
@@ -0,0 +1,2 @@
+. ${srcdir}/emulparams/elf32lmip.sh
+ENTRY=__start
diff --git a/contrib/binutils/ld/emulparams/elf32ppc.sh b/contrib/binutils/ld/emulparams/elf32ppc.sh
index 778260b..d95cb786 100644
--- a/contrib/binutils/ld/emulparams/elf32ppc.sh
+++ b/contrib/binutils/ld/emulparams/elf32ppc.sh
@@ -2,12 +2,15 @@
# elf32lppc.sh elf32ppclinux.sh elf32ppcsim.sh
TEMPLATE_NAME=elf32
+EXTRA_EM_FILE=ppc32elf
GENERATE_SHLIB_SCRIPT=yes
+GENERATE_PIE_SCRIPT=yes
SCRIPT_NAME=elf
OUTPUT_FORMAT="elf32-powerpc"
TEXT_START_ADDR=0x01800000
MAXPAGESIZE=0x10000
-ARCH=powerpc
+COMMONPAGESIZE=0x1000
+ARCH=powerpc:common
MACHINE=
BSS_PLT=
EXECUTABLE_SYMBOLS='PROVIDE (__stack = 0); PROVIDE (___stack = 0);'
@@ -25,18 +28,14 @@ OTHER_GOT_RELOC_SECTIONS="
# Treat a host that matches the target with the possible exception of "64"
# in the name as if it were native.
if test `echo "$host" | sed -e s/64//` = `echo "$target" | sed -e s/64//`; then
- case " $EMULATION_LIBPATH " in
- *" ${EMULATION_NAME} "*)
- LIB_PATH=${libdir}
- for lib in ${NATIVE_LIB_DIRS}; do
- case :${LIB_PATH}: in
- *:${lib}:*) ;;
- *) LIB_PATH=${LIB_PATH}:${lib} ;;
- esac
- done
- # Look for 64 bit target libraries in /lib64, /usr/lib64 etc., first.
- case "$EMULATION_NAME" in
- *64*) LIB_PATH=`echo ${LIB_PATH}: | sed -e s,:,64:,g`$LIB_PATH
- esac
- esac
+ case " $EMULATION_LIBPATH " in
+ *" ${EMULATION_NAME} "*)
+ NATIVE=yes
+ ;;
+ esac
fi
+
+# Look for 64 bit target libraries in /lib64, /usr/lib64 etc., first.
+case "$EMULATION_NAME" in
+ *64*) LIBPATH_SUFFIX=64 ;;
+esac
diff --git a/contrib/binutils/ld/emulparams/elf64_ia64.sh b/contrib/binutils/ld/emulparams/elf64_ia64.sh
index 76f35e4..60c8c4c 100644
--- a/contrib/binutils/ld/emulparams/elf64_ia64.sh
+++ b/contrib/binutils/ld/emulparams/elf64_ia64.sh
@@ -2,24 +2,34 @@
SCRIPT_NAME=elf
ELFSIZE=64
TEMPLATE_NAME=elf32
-EXTRA_EM_FILE=needrelax
+EXTRA_EM_FILE=ia64elf
OUTPUT_FORMAT="elf64-ia64-little"
ARCH=ia64
MACHINE=
MAXPAGESIZE=0x10000
-if test -n "$CREATE_SHLIB"; then
+# FIXME: It interferes with linker relaxation. Disable it until it is
+# fixed.
+if test "0" = "1" -a -n "$CREATE_SHLIB"; then
# Optimize shared libraries for 16K page size
COMMONPAGESIZE=0x4000
fi
TEXT_START_ADDR="0x4000000000000000"
DATA_ADDR="0x6000000000000000 + (. & (${MAXPAGESIZE} - 1))"
GENERATE_SHLIB_SCRIPT=yes
+GENERATE_PIE_SCRIPT=yes
NOP=0x00300000010070000002000001000400 # a bundle full of nops
OTHER_GOT_SECTIONS="
.IA_64.pltoff ${RELOCATING-0} : { *(.IA_64.pltoff) }"
OTHER_PLT_RELOC_SECTIONS="
.rela.IA_64.pltoff ${RELOCATING-0} : { *(.rela.IA_64.pltoff) }"
-OTHER_READONLY_SECTIONS="
- .opd ${RELOCATING-0} : { *(.opd) }
+OTHER_READONLY_SECTIONS=
+OTHER_READWRITE_SECTIONS=
+test -z "$CREATE_PIE" && OTHER_READONLY_SECTIONS="
+ .opd ${RELOCATING-0} : { *(.opd) }"
+test -n "$CREATE_PIE" && OTHER_READWRITE_SECTIONS="
+ .opd ${RELOCATING-0} : { *(.opd) }"
+test -n "$CREATE_PIE" && OTHER_GOT_RELOC_SECTIONS="
+ .rela.opd ${RELOCATING-0} : { *(.rela.opd) }"
+OTHER_READONLY_SECTIONS="${OTHER_READONLY_SECTIONS}
.IA_64.unwind_info ${RELOCATING-0} : { *(.IA_64.unwind_info${RELOCATING+* .gnu.linkonce.ia64unwi.*}) }
.IA_64.unwind ${RELOCATING-0} : { *(.IA_64.unwind${RELOCATING+* .gnu.linkonce.ia64unw.*}) }"
diff --git a/contrib/binutils/ld/emulparams/elf64_ia64_fbsd.sh b/contrib/binutils/ld/emulparams/elf64_ia64_fbsd.sh
index d9c9600..47cde5c 100644
--- a/contrib/binutils/ld/emulparams/elf64_ia64_fbsd.sh
+++ b/contrib/binutils/ld/emulparams/elf64_ia64_fbsd.sh
@@ -1,2 +1,4 @@
. ${srcdir}/emulparams/elf64_ia64.sh
+TEXT_START_ADDR="0x2000000000000000"
+unset DATA_ADDR
. ${srcdir}/emulparams/elf_fbsd.sh
diff --git a/contrib/binutils/ld/emulparams/elf64_s390.sh b/contrib/binutils/ld/emulparams/elf64_s390.sh
index 236fd17..0c689a9 100644
--- a/contrib/binutils/ld/emulparams/elf64_s390.sh
+++ b/contrib/binutils/ld/emulparams/elf64_s390.sh
@@ -9,6 +9,8 @@ MACHINE=
NOP=0x07070707
TEMPLATE_NAME=elf32
GENERATE_SHLIB_SCRIPT=yes
+GENERATE_PIE_SCRIPT=yes
+NO_SMALL_DATA=yes
# Treat a host that matches the target with the possible exception of "x"
# in the name as if it were native.
@@ -16,26 +18,17 @@ if test `echo "$host" | sed -e s/390x/390/` \
= `echo "$target" | sed -e s/390x/390/`; then
case " $EMULATION_LIBPATH " in
*" ${EMULATION_NAME} "*)
- LIB_PATH=${libdir}
- for lib in ${NATIVE_LIB_DIRS}; do
- case :${LIB_PATH}: in
- *:${lib}:*) ;;
- *) LIB_PATH=${LIB_PATH}:${lib} ;;
- esac
- done
-
- case "$target" in
- s390*-linux*)
- suffix=64 ;;
- esac
-
- # Look for 64 bit target libraries in /lib64, /usr/lib64 etc., first
- # on Linux.
- if [ -n "$suffix" ]; then
- case "$EMULATION_NAME" in
- *64*)
- LIB_PATH=`echo ${LIB_PATH}: | sed -e s,:,$suffix:,g`$LIB_PATH ;;
- esac
- fi ;;
+ NATIVE=yes
esac
fi
+
+# Look for 64 bit target libraries in /lib64, /usr/lib64 etc., first
+# on Linux.
+case "$target" in
+ s390*-linux*)
+ case "$EMULATION_NAME" in
+ *64*)
+ LIBPATH_SUFFIX=64 ;;
+ esac
+ ;;
+esac
diff --git a/contrib/binutils/ld/emulparams/elf64_sparc.sh b/contrib/binutils/ld/emulparams/elf64_sparc.sh
index 7a4d2dc..0c0f5d8 100644
--- a/contrib/binutils/ld/emulparams/elf64_sparc.sh
+++ b/contrib/binutils/ld/emulparams/elf64_sparc.sh
@@ -8,6 +8,7 @@ ARCH="sparc:v9"
MACHINE=
DATA_PLT=
GENERATE_SHLIB_SCRIPT=yes
+GENERATE_PIE_SCRIPT=yes
NOP=0x01000000
NO_SMALL_DATA=yes
@@ -28,31 +29,23 @@ if test `echo "$host" | sed -e 's/64//;s/v[789]//'` \
= `echo "$target" | sed -e 's/64//;s/v[789]//'`; then
case " $EMULATION_LIBPATH " in
*" ${EMULATION_NAME} "*)
- LIB_PATH=${libdir}
- for lib in ${NATIVE_LIB_DIRS}; do
- case :${LIB_PATH}: in
- *:${lib}:*) ;;
- *) LIB_PATH=${LIB_PATH}:${lib} ;;
- esac
- done
-
- # Linux and Solaris modify the default library search path
- # to first include a 64-bit specific directory. It's put
- # in slightly different places on the two systems.
- case "$target" in
- sparc*-linux*)
- suffix=64 ;;
- sparc*-solaris*)
- suffix=/sparcv9 ;;
- esac
-
- # Look for 64 bit target libraries in /lib64, /usr/lib64 etc., first
- # on Linux and /lib/sparcv9, /usr/lib/sparcv9 etc. on Solaris.
- if [ -n "$suffix" ]; then
- case "$EMULATION_NAME" in
- *64*)
- LIB_PATH=`echo ${LIB_PATH}: | sed -e s,:,$suffix:,g`$LIB_PATH ;;
- esac
- fi ;;
+ NATIVE=yes
+ ;;
esac
fi
+
+# Linux and Solaris modify the default library search path
+# to first include a 64-bit specific directory. It's put
+# in slightly different places on the two systems.
+# Look for 64 bit target libraries in /lib64, /usr/lib64 etc., first
+# on Linux and /lib/sparcv9, /usr/lib/sparcv9 etc. on Solaris.
+case "$EMULATION_NAME" in
+ *64*)
+ case "$target" in
+ sparc*-linux*)
+ LIBPATH_SUFFIX=64 ;;
+ sparc*-solaris*)
+ LIBPATH_SUFFIX=/sparcv9 ;;
+ esac
+ ;;
+esac
diff --git a/contrib/binutils/ld/emulparams/elf64bmip.sh b/contrib/binutils/ld/emulparams/elf64bmip.sh
new file mode 100755
index 0000000..a4ce6d4
--- /dev/null
+++ b/contrib/binutils/ld/emulparams/elf64bmip.sh
@@ -0,0 +1,23 @@
+. ${srcdir}/emulparams/elf32bmipn32-defs.sh
+OUTPUT_FORMAT="elf64-bigmips"
+BIG_OUTPUT_FORMAT="elf64-bigmips"
+LITTLE_OUTPUT_FORMAT="elf64-littlemips"
+SHLIB_TEXT_START_ADDR=0x3ffffe0000
+
+# IRIX6 defines these symbols. 0x40 is the size of the ELF header.
+EXECUTABLE_SYMBOLS="
+ __dso_displacement = 0;
+ ${CREATE_SHLIB-${CREATE_PIE-__elf_header = ${TEXT_START_ADDR};}}
+ ${CREATE_SHLIB+__elf_header = ${SHLIB_TEXT_START_ADDR};}
+ ${CREATE_PIE+__elf_header = ${SHLIB_TEXT_START_ADDR};}
+ __program_header_table = __elf_header + 0x40;
+"
+
+# There are often dynamic relocations against the .rodata section.
+# Setting DT_TEXTREL in the .dynamic section does not convince the
+# IRIX6 linker to permit relocations against the text segment.
+# Following the IRIX linker, we simply put .rodata in the data
+# segment.
+WRITABLE_RODATA=
+
+EXTRA_EM_FILE=irix
diff --git a/contrib/binutils/ld/emulparams/elf64ppc.sh b/contrib/binutils/ld/emulparams/elf64ppc.sh
index add6c54..c190b18 100644
--- a/contrib/binutils/ld/emulparams/elf64ppc.sh
+++ b/contrib/binutils/ld/emulparams/elf64ppc.sh
@@ -2,29 +2,31 @@ TEMPLATE_NAME=elf32
EXTRA_EM_FILE=ppc64elf
ELFSIZE=64
GENERATE_SHLIB_SCRIPT=yes
+GENERATE_PIE_SCRIPT=yes
SCRIPT_NAME=elf
OUTPUT_FORMAT="elf64-powerpc"
TEXT_START_ADDR=0x10000000
-#DATA_ADDR="ALIGN (0x10000000) + (. & (${MAXPAGESIZE} - 1))"
+#SEGMENT_SIZE=0x10000000
MAXPAGESIZE=0x10000
COMMONPAGESIZE=0x1000
ARCH=powerpc:common64
MACHINE=
NOP=0x60000000
-EXECUTABLE_SYMBOLS='PROVIDE (__stack = 0); PROVIDE (___stack = 0);'
-OTHER_BSS_END_SYMBOLS='__end = .;'
-CTOR_START='PROVIDE (__CTOR_LIST__ = .); PROVIDE (___CTOR_LIST__ = .);'
-CTOR_END='PROVIDE (__CTOR_END__ = .); PROVIDE (___CTOR_END__ = .);'
-DTOR_START='PROVIDE (__DTOR_LIST__ = .); PROVIDE (___DTOR_LIST__ = .);'
-DTOR_END='PROVIDE (__DTOR_END__ = .); PROVIDE (___DTOR_END__ = .);'
OTHER_TEXT_SECTIONS="*(.sfpr .glink)"
BSS_PLT=
OTHER_BSS_SYMBOLS="
.tocbss ${RELOCATING-0}${RELOCATING+ALIGN(8)} : { *(.tocbss)}"
OTHER_PLT_RELOC_SECTIONS="
.rela.tocbss ${RELOCATING-0} : { *(.rela.tocbss) }"
-OTHER_GOT_SECTIONS="
- .toc ${RELOCATING-0}${RELOCATING+ALIGN(8)} : { *(.toc) }"
+
+if test x${RELOCATING+set} = xset; then
+ GOT="
+ .got ALIGN(8) : { *(.got .toc) }"
+else
+ GOT="
+ .got 0 : { *(.got) }
+ .toc 0 : { *(.toc) }"
+fi
OTHER_GOT_RELOC_SECTIONS="
.rela.toc ${RELOCATING-0} : { *(.rela.toc) }"
OTHER_READWRITE_SECTIONS="
@@ -34,18 +36,14 @@ OTHER_READWRITE_SECTIONS="
# Treat a host that matches the target with the possible exception of "64"
# in the name as if it were native.
if test `echo "$host" | sed -e s/64//` = `echo "$target" | sed -e s/64//`; then
- case " $EMULATION_LIBPATH " in
- *" ${EMULATION_NAME} "*)
- LIB_PATH=${libdir}
- for lib in ${NATIVE_LIB_DIRS}; do
- case :${LIB_PATH}: in
- *:${lib}:*) ;;
- *) LIB_PATH=${LIB_PATH}:${lib} ;;
- esac
- done
- # Look for 64 bit target libraries in /lib64, /usr/lib64 etc., first.
- case "$EMULATION_NAME" in
- *64*) LIB_PATH=`echo ${LIB_PATH}: | sed -e s,:,64:,g`$LIB_PATH
- esac
- esac
+ case " $EMULATION_LIBPATH " in
+ *" ${EMULATION_NAME} "*)
+ NATIVE=yes
+ ;;
+ esac
fi
+
+# Look for 64 bit target libraries in /lib64, /usr/lib64 etc., first.
+case "$EMULATION_NAME" in
+ *64*) LIBPATH_SUFFIX=64 ;;
+esac
diff --git a/contrib/binutils/ld/emulparams/elf_i386.sh b/contrib/binutils/ld/emulparams/elf_i386.sh
index f1b8522..2382286 100644
--- a/contrib/binutils/ld/emulparams/elf_i386.sh
+++ b/contrib/binutils/ld/emulparams/elf_i386.sh
@@ -9,4 +9,5 @@ MACHINE=
NOP=0x90909090
TEMPLATE_NAME=elf32
GENERATE_SHLIB_SCRIPT=yes
+GENERATE_PIE_SCRIPT=yes
NO_SMALL_DATA=yes
diff --git a/contrib/binutils/ld/emulparams/elf_s390.sh b/contrib/binutils/ld/emulparams/elf_s390.sh
index 2804ace..e710673 100644
--- a/contrib/binutils/ld/emulparams/elf_s390.sh
+++ b/contrib/binutils/ld/emulparams/elf_s390.sh
@@ -8,3 +8,5 @@ MACHINE=
NOP=0x07070707
TEMPLATE_NAME=elf32
GENERATE_SHLIB_SCRIPT=yes
+GENERATE_PIE_SCRIPT=yes
+NO_SMALL_DATA=yes
diff --git a/contrib/binutils/ld/emulparams/elf_x86_64.sh b/contrib/binutils/ld/emulparams/elf_x86_64.sh
index a428bfc..6d37058 100644
--- a/contrib/binutils/ld/emulparams/elf_x86_64.sh
+++ b/contrib/binutils/ld/emulparams/elf_x86_64.sh
@@ -10,32 +10,22 @@ MACHINE=
NOP=0x90909090
TEMPLATE_NAME=elf32
GENERATE_SHLIB_SCRIPT=yes
+GENERATE_PIE_SCRIPT=yes
NO_SMALL_DATA=yes
if [ "x${host}" = "x${target}" ]; then
case " $EMULATION_LIBPATH " in
*" ${EMULATION_NAME} "*)
- LIB_PATH=${libdir}
- for lib in ${NATIVE_LIB_DIRS}; do
- case :${LIB_PATH}: in
- *:${lib}:*) ;;
- *) LIB_PATH=${LIB_PATH}:${lib} ;;
- esac
- done
-
- # Linux modify the default library search path to first include
- # a 64-bit specific directory.
- case "$target" in
- x86_64*-linux*)
- suffix=64 ;;
- esac
-
- # Look for 64 bit target libraries in /lib64, /usr/lib64 etc., first.
- if [ -n "$suffix" ]; then
- case "$EMULATION_NAME" in
- *64*)
- LIB_PATH=`echo ${LIB_PATH}: | sed -e s,:,$suffix:,g`$LIB_PATH ;;
- esac
- fi ;;
+ NATIVE=yes
esac
fi
+
+# Linux modify the default library search path to first include
+# a 64-bit specific directory.
+case "$target" in
+ x86_64*-linux*)
+ case "$EMULATION_NAME" in
+ *64*) LIBPATH_SUFFIX=64 ;;
+ esac
+ ;;
+esac
diff --git a/contrib/binutils/ld/emulparams/sh.sh b/contrib/binutils/ld/emulparams/sh.sh
new file mode 100644
index 0000000..52d1443
--- /dev/null
+++ b/contrib/binutils/ld/emulparams/sh.sh
@@ -0,0 +1,8 @@
+# If you change this file, please also look at files which source this one:
+# shl.sh
+
+SCRIPT_NAME=sh
+OUTPUT_FORMAT="coff-sh"
+TEXT_START_ADDR=0x8000
+TARGET_PAGE_SIZE=128
+ARCH=sh
diff --git a/contrib/binutils/ld/emulparams/shl.sh b/contrib/binutils/ld/emulparams/shl.sh
new file mode 100644
index 0000000..5fbb165
--- /dev/null
+++ b/contrib/binutils/ld/emulparams/shl.sh
@@ -0,0 +1,2 @@
+. ${srcdir}/emulparams/sh.sh
+OUTPUT_FORMAT="coff-shl"
diff --git a/contrib/binutils/ld/emulparams/shlelf.sh b/contrib/binutils/ld/emulparams/shlelf.sh
new file mode 100755
index 0000000..e19678b
--- /dev/null
+++ b/contrib/binutils/ld/emulparams/shlelf.sh
@@ -0,0 +1,2 @@
+. ${srcdir}/emulparams/shelf.sh
+OUTPUT_FORMAT="elf32-shl"
diff --git a/contrib/binutils/ld/emulparams/vanilla.sh b/contrib/binutils/ld/emulparams/vanilla.sh
index d8a3b72..eabb7cd 100644
--- a/contrib/binutils/ld/emulparams/vanilla.sh
+++ b/contrib/binutils/ld/emulparams/vanilla.sh
@@ -1,5 +1,5 @@
SCRIPT_NAME=vanilla
-TEXT_START_ADDR=??
-TARGET_PAGE_SIZE=??
+TEXT_START_ADDR=0
+TARGET_PAGE_SIZE=128
ARCH=unknown
TEMPLATE_NAME=vanilla
diff --git a/contrib/binutils/ld/emulparams/vsta.sh b/contrib/binutils/ld/emulparams/vsta.sh
new file mode 100644
index 0000000..cc6249b
--- /dev/null
+++ b/contrib/binutils/ld/emulparams/vsta.sh
@@ -0,0 +1,8 @@
+SCRIPT_NAME=aout
+OUTPUT_FORMAT="a.out-i386"
+TEXT_START_ADDR=0x1020
+TARGET_PAGE_SIZE=0x1000
+SEGMENT_SIZE=0x400000
+NONPAGED_TEXT_START_ADDR=0x0
+ARCH=i386
+
diff --git a/contrib/binutils/ld/emultempl/alphaelf.em b/contrib/binutils/ld/emultempl/alphaelf.em
new file mode 100644
index 0000000..7e64323
--- /dev/null
+++ b/contrib/binutils/ld/emultempl/alphaelf.em
@@ -0,0 +1,80 @@
+# This shell script emits a C file. -*- C -*-
+# Copyright 2003 Free Software Foundation, Inc.
+#
+# This file is part of GLD, the Gnu Linker.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+#
+
+# This file is sourced from elf32.em, and defines extra alpha
+# specific routines.
+#
+cat >>e${EMULATION_NAME}.c <<EOF
+
+#include "elf/internal.h"
+#include "elf/alpha.h"
+#include "elf-bfd.h"
+
+static int elf64alpha_32bit = 0;
+
+/* Set the start address as in the Tru64 ld. */
+#define ALPHA_TEXT_START_32BIT 0x12000000
+
+static void
+alpha_after_parse (void)
+{
+ if (elf64alpha_32bit && !link_info.shared && !link_info.relocatable)
+ lang_section_start (".interp",
+ exp_binop ('+',
+ exp_intop (ALPHA_TEXT_START_32BIT),
+ exp_nameop (SIZEOF_HEADERS, NULL)));
+}
+
+static void
+alpha_finish (void)
+{
+ if (elf64alpha_32bit)
+ elf_elfheader (output_bfd)->e_flags |= EF_ALPHA_32BIT;
+
+ gld${EMULATION_NAME}_finish ();
+}
+EOF
+
+# Define some shell vars to insert bits of code into the standard elf
+# parse_args and list_options functions.
+#
+PARSE_AND_LIST_PROLOGUE='
+#define OPTION_TASO 300
+'
+
+PARSE_AND_LIST_LONGOPTS='
+ {"taso", no_argument, NULL, OPTION_TASO},
+'
+
+PARSE_AND_LIST_OPTIONS='
+ fprintf (file, _(" -taso\t\t\tLoad executable in the lower 31-bit addressable\n"));
+ fprintf (file, _("\t\t\t virtual address range\n"));
+'
+
+PARSE_AND_LIST_ARGS_CASES='
+ case OPTION_TASO:
+ elf64alpha_32bit = 1;
+ break;
+'
+
+# Put these extra alpha routines in ld_${EMULATION_NAME}_emulation
+#
+LDEMUL_AFTER_PARSE=alpha_after_parse
+LDEMUL_FINISH=alpha_finish
diff --git a/contrib/binutils/ld/emultempl/armcoff.em b/contrib/binutils/ld/emultempl/armcoff.em
index 0b5e7bc..468c3b0 100644
--- a/contrib/binutils/ld/emultempl/armcoff.em
+++ b/contrib/binutils/ld/emultempl/armcoff.em
@@ -4,8 +4,8 @@ cat >e${EMULATION_NAME}.c <<EOF
/* This file is is generated by a shell script. DO NOT EDIT! */
/* emulate the original gld for the given ${EMULATION_NAME}
- Copyright 1991, 1993, 1996, 1997, 1998, 1999, 2000, 2001, 2002
- Free Software Foundation, Inc.
+ Copyright 1991, 1993, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
+ 2004 Free Software Foundation, Inc.
Written by Steve Chamberlain steve@cygnus.com
This file is part of GLD, the Gnu Linker.
@@ -40,16 +40,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "ldfile.h"
#include "ldemul.h"
-static void gld${EMULATION_NAME}_before_parse PARAMS ((void));
-static void gld${EMULATION_NAME}_before_allocation PARAMS ((void));
-static char *gld${EMULATION_NAME}_get_script PARAMS ((int *isfile));
-static int gld${EMULATION_NAME}_parse_args PARAMS((int, char **));
-static void gld${EMULATION_NAME}_list_options PARAMS ((FILE *));
-static void gld${EMULATION_NAME}_finish PARAMS ((void));
-static void gld${EMULATION_NAME}_after_open PARAMS ((void));
-
-/* If true, then interworking stubs which support calls to old, non-interworking
- aware ARM code should be generated. */
+/* If TRUE, then interworking stubs which support calls to old,
+ non-interworking aware ARM code should be generated. */
static int support_old_code = 0;
static char * thumb_entry_symbol = NULL;
@@ -57,49 +49,37 @@ static char * thumb_entry_symbol = NULL;
#define OPTION_SUPPORT_OLD_CODE 300
#define OPTION_THUMB_ENTRY 301
-static struct option longopts[] =
+static void
+gld${EMULATION_NAME}_add_options
+ (int ns ATTRIBUTE_UNUSED, char **shortopts ATTRIBUTE_UNUSED, int nl,
+ struct option **longopts, int nrl ATTRIBUTE_UNUSED,
+ struct option **really_longopts ATTRIBUTE_UNUSED)
{
- {"support-old-code", no_argument, NULL, OPTION_SUPPORT_OLD_CODE},
- {"thumb-entry", required_argument, NULL, OPTION_THUMB_ENTRY},
- {NULL, no_argument, NULL, 0}
-};
+ static const struct option xtra_long[] = {
+ {"support-old-code", no_argument, NULL, OPTION_SUPPORT_OLD_CODE},
+ {"thumb-entry", required_argument, NULL, OPTION_THUMB_ENTRY},
+ {NULL, no_argument, NULL, 0}
+ };
+
+ *longopts = xrealloc (*longopts,
+ nl * sizeof (struct option) + sizeof (xtra_long));
+ memcpy (*longopts + nl, &xtra_long, sizeof (xtra_long));
+}
static void
-gld${EMULATION_NAME}_list_options (file)
- FILE * file;
+gld${EMULATION_NAME}_list_options (FILE *file)
{
fprintf (file, _(" --support-old-code Support interworking with old code\n"));
fprintf (file, _(" --thumb-entry=<sym> Set the entry point to be Thumb symbol <sym>\n"));
}
-static int
-gld${EMULATION_NAME}_parse_args (argc, argv)
- int argc;
- char ** argv;
+static bfd_boolean
+gld${EMULATION_NAME}_handle_option (int optc)
{
- int longind;
- int optc;
- int prevoptind = optind;
- int prevopterr = opterr;
- int wanterror;
- static int lastoptind = -1;
-
- if (lastoptind != optind)
- opterr = 0;
-
- wanterror = opterr;
- lastoptind = optind;
-
- optc = getopt_long_only (argc, argv, "-", longopts, & longind);
- opterr = prevopterr;
-
switch (optc)
{
default:
- if (wanterror)
- xexit (1);
- optind = prevoptind;
- return 0;
+ return FALSE;
case OPTION_SUPPORT_OLD_CODE:
support_old_code = 1;
@@ -109,15 +89,15 @@ gld${EMULATION_NAME}_parse_args (argc, argv)
thumb_entry_symbol = optarg;
break;
}
-
- return 1;
+
+ return TRUE;
}
static void
-gld${EMULATION_NAME}_before_parse ()
+gld${EMULATION_NAME}_before_parse (void)
{
#ifndef TARGET_ /* I.e., if not generic. */
- ldfile_set_output_arch ("`echo ${ARCH}`");
+ ldfile_set_output_arch ("`echo ${ARCH}`", bfd_arch_unknown);
#endif /* not TARGET_ */
}
@@ -125,7 +105,7 @@ gld${EMULATION_NAME}_before_parse ()
sections, but before any sizes or addresses have been set. */
static void
-gld${EMULATION_NAME}_before_allocation ()
+gld${EMULATION_NAME}_before_allocation (void)
{
/* we should be able to set the size of the interworking stub section */
@@ -148,7 +128,7 @@ gld${EMULATION_NAME}_before_allocation ()
}
static void
-gld${EMULATION_NAME}_after_open ()
+gld${EMULATION_NAME}_after_open (void)
{
if (strstr (bfd_get_target (output_bfd), "arm") == NULL)
{
@@ -159,7 +139,7 @@ gld${EMULATION_NAME}_after_open ()
einfo ("%F%X%P: error: cannot change output format whilst linking ARM binaries\n");
return;
}
-
+
{
LANG_FOR_EACH_INPUT_STATEMENT (is)
{
@@ -170,14 +150,15 @@ gld${EMULATION_NAME}_after_open ()
}
static void
-gld${EMULATION_NAME}_finish PARAMS((void))
+gld${EMULATION_NAME}_finish (void)
{
struct bfd_link_hash_entry * h;
if (thumb_entry_symbol == NULL)
return;
-
- h = bfd_link_hash_lookup (link_info.hash, thumb_entry_symbol, false, false, true);
+
+ h = bfd_link_hash_lookup (link_info.hash, thumb_entry_symbol,
+ FALSE, FALSE, TRUE);
if (h != (struct bfd_link_hash_entry *) NULL
&& (h->type == bfd_link_hash_defined
@@ -186,21 +167,21 @@ gld${EMULATION_NAME}_finish PARAMS((void))
{
static char buffer[32];
bfd_vma val;
-
+
/* Special procesing is required for a Thumb entry symbol. The
bottom bit of its address must be set. */
val = (h->u.def.value
+ bfd_get_section_vma (output_bfd,
h->u.def.section->output_section)
+ h->u.def.section->output_offset);
-
+
val |= 1;
/* Now convert this value into a string and store it in entry_symbol
- where the lang_finish() function will pick it up. */
+ where the lang_finish() function will pick it up. */
buffer[0] = '0';
buffer[1] = 'x';
-
+
sprintf_vma (buffer + 2, val);
if (entry_symbol.name != NULL && entry_from_cmdline)
@@ -213,8 +194,7 @@ gld${EMULATION_NAME}_finish PARAMS((void))
}
static char *
-gld${EMULATION_NAME}_get_script (isfile)
- int *isfile;
+gld${EMULATION_NAME}_get_script (int *isfile)
EOF
if test -n "$COMPILE_IN"
@@ -225,33 +205,33 @@ then
sc="-f stringify.sed"
cat >>e${EMULATION_NAME}.c <<EOF
-{
+{
*isfile = 0;
- if (link_info.relocateable == true && config.build_constructors == true)
+ if (link_info.relocatable && config.build_constructors)
return
EOF
-sed $sc ldscripts/${EMULATION_NAME}.xu >> e${EMULATION_NAME}.c
-echo ' ; else if (link_info.relocateable == true) return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.xr >> e${EMULATION_NAME}.c
-echo ' ; else if (!config.text_read_only) return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.xbn >> e${EMULATION_NAME}.c
-echo ' ; else if (!config.magic_demand_paged) return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.xn >> e${EMULATION_NAME}.c
-echo ' ; else return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.x >> e${EMULATION_NAME}.c
-echo '; }' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xu >> e${EMULATION_NAME}.c
+echo ' ; else if (link_info.relocatable) return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xr >> e${EMULATION_NAME}.c
+echo ' ; else if (!config.text_read_only) return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xbn >> e${EMULATION_NAME}.c
+echo ' ; else if (!config.magic_demand_paged) return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xn >> e${EMULATION_NAME}.c
+echo ' ; else return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.x >> e${EMULATION_NAME}.c
+echo '; }' >> e${EMULATION_NAME}.c
else
# Scripts read from the filesystem.
cat >>e${EMULATION_NAME}.c <<EOF
-{
+{
*isfile = 1;
- if (link_info.relocateable == true && config.build_constructors == true)
+ if (link_info.relocatable && config.build_constructors)
return "ldscripts/${EMULATION_NAME}.xu";
- else if (link_info.relocateable == true)
+ else if (link_info.relocatable)
return "ldscripts/${EMULATION_NAME}.xr";
else if (!config.text_read_only)
return "ldscripts/${EMULATION_NAME}.xbn";
@@ -266,7 +246,7 @@ fi
cat >>e${EMULATION_NAME}.c <<EOF
-struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
+struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
{
gld${EMULATION_NAME}_before_parse,
syslib_default,
@@ -285,7 +265,9 @@ struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
NULL, /* open dynamic archive */
NULL, /* place orphan */
NULL, /* set symbols */
- gld${EMULATION_NAME}_parse_args,
+ NULL, /* parse_args */
+ gld${EMULATION_NAME}_add_options,
+ gld${EMULATION_NAME}_handle_option,
NULL, /* unrecognised file */
gld${EMULATION_NAME}_list_options,
NULL, /* recognized file */
diff --git a/contrib/binutils/ld/emultempl/armelf.em b/contrib/binutils/ld/emultempl/armelf.em
index 0e65c04..0c051ad 100644
--- a/contrib/binutils/ld/emultempl/armelf.em
+++ b/contrib/binutils/ld/emultempl/armelf.em
@@ -1,5 +1,5 @@
# This shell script emits a C file. -*- C -*-
-# Copyright 1991, 1993, 1996, 1997, 1998, 1999, 2000, 2002
+# Copyright 1991, 1993, 1996, 1997, 1998, 1999, 2000, 2002, 2003, 2004
# Free Software Foundation, Inc.
#
# This file is part of GLD, the Gnu Linker.
@@ -28,21 +28,18 @@ static int no_pipeline_knowledge = 0;
static char *thumb_entry_symbol = NULL;
static bfd *bfd_for_interwork;
-
static void
-gld${EMULATION_NAME}_before_parse ()
+gld${EMULATION_NAME}_before_parse (void)
{
#ifndef TARGET_ /* I.e., if not generic. */
- ldfile_set_output_arch ("`echo ${ARCH}`");
+ ldfile_set_output_arch ("`echo ${ARCH}`", bfd_arch_unknown);
#endif /* not TARGET_ */
- config.dynamic_link = ${DYNAMIC_LINK-true};
- config.has_shared = `if test -n "$GENERATE_SHLIB_SCRIPT" ; then echo true ; else echo false ; fi`;
+ config.dynamic_link = ${DYNAMIC_LINK-TRUE};
+ config.has_shared = `if test -n "$GENERATE_SHLIB_SCRIPT" ; then echo TRUE ; else echo FALSE ; fi`;
}
-static void arm_elf_after_open PARAMS ((void));
-
static void
-arm_elf_after_open ()
+arm_elf_after_open (void)
{
if (strstr (bfd_get_target (output_bfd), "arm") == NULL)
{
@@ -65,15 +62,11 @@ arm_elf_after_open ()
gld${EMULATION_NAME}_after_open ();
}
-static void arm_elf_set_bfd_for_interworking
- PARAMS ((lang_statement_union_type *));
-
static void
-arm_elf_set_bfd_for_interworking (statement)
- lang_statement_union_type *statement;
+arm_elf_set_bfd_for_interworking (lang_statement_union_type *statement)
{
if (statement->header.type == lang_input_section_enum
- && statement->input_section.ifile->just_syms_flag == false)
+ && !statement->input_section.ifile->just_syms_flag)
{
asection *i = statement->input_section.section;
asection *output_section = i->output_section;
@@ -85,15 +78,13 @@ arm_elf_set_bfd_for_interworking (statement)
&& ! i->owner->output_has_begun)
{
bfd_for_interwork = i->owner;
- bfd_for_interwork->output_has_begun = true;
+ bfd_for_interwork->output_has_begun = TRUE;
}
}
}
-static void arm_elf_before_allocation PARAMS ((void));
-
static void
-arm_elf_before_allocation ()
+arm_elf_before_allocation (void)
{
bfd *tem;
@@ -105,14 +96,18 @@ arm_elf_before_allocation ()
/* The interworking bfd must be the last one in the link. */
bfd_for_interwork = NULL;
for (tem = link_info.input_bfds; tem != NULL; tem = tem->link_next)
- tem->output_has_begun = false;
+ tem->output_has_begun = FALSE;
lang_for_each_statement (arm_elf_set_bfd_for_interworking);
- ASSERT (bfd_for_interwork != NULL);
for (tem = link_info.input_bfds; tem != NULL; tem = tem->link_next)
- tem->output_has_begun = false;
-
- bfd_elf32_arm_get_bfd_for_interworking (bfd_for_interwork, &link_info);
+ tem->output_has_begun = FALSE;
+
+ /* If bfd_for_interwork is NULL, then there are no loadable sections
+ with real contents to be linked, so we are not going to have to
+ create any interworking stubs, so it is OK not to call
+ bfd_elf32_arm_get_bfd_for_interworking. */
+ if (bfd_for_interwork != NULL)
+ bfd_elf32_arm_get_bfd_for_interworking (bfd_for_interwork, &link_info);
}
/* We should be able to set the size of the interworking stub section. */
@@ -134,10 +129,8 @@ arm_elf_before_allocation ()
bfd_elf32_arm_allocate_interworking_sections (& link_info);
}
-static void arm_elf_finish PARAMS ((void));
-
static void
-arm_elf_finish ()
+arm_elf_finish (void)
{
struct bfd_link_hash_entry * h;
@@ -146,9 +139,9 @@ arm_elf_finish ()
if (thumb_entry_symbol == NULL)
return;
-
+
h = bfd_link_hash_lookup (link_info.hash, thumb_entry_symbol,
- false, false, true);
+ FALSE, FALSE, TRUE);
if (h != (struct bfd_link_hash_entry *) NULL
&& (h->type == bfd_link_hash_defined
@@ -157,21 +150,21 @@ arm_elf_finish ()
{
static char buffer[32];
bfd_vma val;
-
+
/* Special procesing is required for a Thumb entry symbol. The
bottom bit of its address must be set. */
val = (h->u.def.value
+ bfd_get_section_vma (output_bfd,
h->u.def.section->output_section)
+ h->u.def.section->output_offset);
-
+
val |= 1;
/* Now convert this value into a string and store it in entry_symbol
- where the lang_finish() function will pick it up. */
+ where the lang_finish() function will pick it up. */
buffer[0] = '0';
buffer[1] = 'x';
-
+
sprintf_vma (buffer + 2, val);
if (entry_symbol.name != NULL && entry_from_cmdline)
@@ -193,12 +186,7 @@ PARSE_AND_LIST_PROLOGUE='
#define OPTION_THUMB_ENTRY 301
'
-# Note we add 'n' to the short option list in order to prevent
-# getopt_long_only from thinking that -n is a unique abbreviation
-# for --no-pipeline-knowledge. There is no case to handle 'n' here
-# however, so instead it will be passed back to parse_args() in
-# lexsup.c where it will be handled.
-PARSE_AND_LIST_SHORTOPTS=pn
+PARSE_AND_LIST_SHORTOPTS=p
PARSE_AND_LIST_LONGOPTS='
{ "no-pipeline-knowledge", no_argument, NULL, '\'p\''},
diff --git a/contrib/binutils/ld/emultempl/armelf_oabi.em b/contrib/binutils/ld/emultempl/armelf_oabi.em
index aae7ea9..d75c658 100644
--- a/contrib/binutils/ld/emultempl/armelf_oabi.em
+++ b/contrib/binutils/ld/emultempl/armelf_oabi.em
@@ -4,8 +4,8 @@ cat >e${EMULATION_NAME}.c <<EOF
/* This file is is generated by a shell script. DO NOT EDIT! */
/* emulate the original gld for the given ${EMULATION_NAME}
- Copyright 1991, 1993, 1996, 1997, 1998, 1999, 2000, 2001
- Free Software Foundation, Inc.
+ Copyright 1991, 1993, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
+ 2004 Free Software Foundation, Inc.
Written by Steve Chamberlain steve@cygnus.com
This file is part of GLD, the Gnu Linker.
@@ -47,16 +47,11 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "ldfile.h"
#include "ldemul.h"
-static void gld${EMULATION_NAME}_before_parse PARAMS ((void));
-static void gld${EMULATION_NAME}_before_allocation PARAMS ((void));
-static char *gld${EMULATION_NAME}_get_script PARAMS ((int *isfile));
-static void gld${EMULATION_NAME}_after_open PARAMS ((void));
-
static void
-gld${EMULATION_NAME}_before_parse ()
+gld${EMULATION_NAME}_before_parse (void)
{
#ifndef TARGET_ /* I.e., if not generic. */
- ldfile_set_output_arch ("`echo ${ARCH}`");
+ ldfile_set_output_arch ("`echo ${ARCH}`", bfd_arch_unknown);
#endif /* not TARGET_ */
}
@@ -64,7 +59,7 @@ gld${EMULATION_NAME}_before_parse ()
sections, but before any sizes or addresses have been set. */
static void
-gld${EMULATION_NAME}_before_allocation ()
+gld${EMULATION_NAME}_before_allocation (void)
{
/* we should be able to set the size of the interworking stub section */
@@ -86,7 +81,7 @@ gld${EMULATION_NAME}_before_allocation ()
}
static void
-gld${EMULATION_NAME}_after_open ()
+gld${EMULATION_NAME}_after_open (void)
{
LANG_FOR_EACH_INPUT_STATEMENT (is)
@@ -98,8 +93,7 @@ gld${EMULATION_NAME}_after_open ()
}
static char *
-gld${EMULATION_NAME}_get_script (isfile)
- int *isfile;
+gld${EMULATION_NAME}_get_script (int *isfile)
EOF
if test -n "$COMPILE_IN"
@@ -110,33 +104,33 @@ then
sc="-f stringify.sed"
cat >>e${EMULATION_NAME}.c <<EOF
-{
+{
*isfile = 0;
- if (link_info.relocateable == true && config.build_constructors == true)
+ if (link_info.relocatable && config.build_constructors)
return
EOF
-sed $sc ldscripts/${EMULATION_NAME}.xu >> e${EMULATION_NAME}.c
-echo ' ; else if (link_info.relocateable == true) return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.xr >> e${EMULATION_NAME}.c
-echo ' ; else if (!config.text_read_only) return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.xbn >> e${EMULATION_NAME}.c
-echo ' ; else if (!config.magic_demand_paged) return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.xn >> e${EMULATION_NAME}.c
-echo ' ; else return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.x >> e${EMULATION_NAME}.c
-echo '; }' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xu >> e${EMULATION_NAME}.c
+echo ' ; else if (link_info.relocatable) return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xr >> e${EMULATION_NAME}.c
+echo ' ; else if (!config.text_read_only) return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xbn >> e${EMULATION_NAME}.c
+echo ' ; else if (!config.magic_demand_paged) return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xn >> e${EMULATION_NAME}.c
+echo ' ; else return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.x >> e${EMULATION_NAME}.c
+echo '; }' >> e${EMULATION_NAME}.c
else
# Scripts read from the filesystem.
cat >>e${EMULATION_NAME}.c <<EOF
-{
+{
*isfile = 1;
- if (link_info.relocateable == true && config.build_constructors == true)
+ if (link_info.relocatable && config.build_constructors)
return "ldscripts/${EMULATION_NAME}.xu";
- else if (link_info.relocateable == true)
+ else if (link_info.relocatable)
return "ldscripts/${EMULATION_NAME}.xr";
else if (!config.text_read_only)
return "ldscripts/${EMULATION_NAME}.xbn";
@@ -151,7 +145,7 @@ fi
cat >>e${EMULATION_NAME}.c <<EOF
-struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
+struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
{
gld${EMULATION_NAME}_before_parse,
syslib_default,
@@ -171,6 +165,8 @@ struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
NULL, /* place orphan */
NULL, /* set symbols */
NULL, /* parse args */
+ NULL, /* add_options */
+ NULL, /* handle_option */
NULL, /* unrecognized file */
NULL, /* list options */
NULL, /* recognized file */
diff --git a/contrib/binutils/ld/emultempl/generic.em b/contrib/binutils/ld/emultempl/generic.em
index 397422c..4d17ca2 100644
--- a/contrib/binutils/ld/emultempl/generic.em
+++ b/contrib/binutils/ld/emultempl/generic.em
@@ -4,7 +4,7 @@ cat >e${EMULATION_NAME}.c <<EOF
/* This file is is generated by a shell script. DO NOT EDIT! */
/* emulate the original gld for the given ${EMULATION_NAME}
- Copyright 1991, 1992, 1994, 1996, 2000, 2001
+ Copyright 1991, 1992, 1994, 1996, 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
Written by Steve Chamberlain steve@cygnus.com
@@ -39,9 +39,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "ldfile.h"
#include "ldemul.h"
-static void gld${EMULATION_NAME}_before_parse PARAMS ((void));
-static char *gld${EMULATION_NAME}_get_script PARAMS ((int *isfile));
-
EOF
# Import any needed special functions and/or overrides.
@@ -54,10 +51,10 @@ if test x"$LDEMUL_BEFORE_PARSE" != xgld"$EMULATION_NAME"_before_parse; then
cat >>e${EMULATION_NAME}.c <<EOF
static void
-gld${EMULATION_NAME}_before_parse()
+gld${EMULATION_NAME}_before_parse (void)
{
#ifndef TARGET_ /* I.e., if not generic. */
- ldfile_set_output_arch ("`echo ${ARCH}`");
+ ldfile_set_output_arch ("`echo ${ARCH}`", bfd_arch_unknown);
#endif /* not TARGET_ */
}
@@ -68,8 +65,7 @@ if test x"$LDEMUL_GET_SCRIPT" != xgld"$EMULATION_NAME"_get_script; then
cat >>e${EMULATION_NAME}.c <<EOF
static char *
-gld${EMULATION_NAME}_get_script(isfile)
- int *isfile;
+gld${EMULATION_NAME}_get_script (int *isfile)
EOF
if test -n "$COMPILE_IN"
@@ -80,33 +76,33 @@ then
sc="-f stringify.sed"
cat >>e${EMULATION_NAME}.c <<EOF
-{
+{
*isfile = 0;
- if (link_info.relocateable == true && config.build_constructors == true)
+ if (link_info.relocatable && config.build_constructors)
return
EOF
-sed $sc ldscripts/${EMULATION_NAME}.xu >> e${EMULATION_NAME}.c
-echo ' ; else if (link_info.relocateable == true) return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.xr >> e${EMULATION_NAME}.c
-echo ' ; else if (!config.text_read_only) return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.xbn >> e${EMULATION_NAME}.c
-echo ' ; else if (!config.magic_demand_paged) return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.xn >> e${EMULATION_NAME}.c
-echo ' ; else return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.x >> e${EMULATION_NAME}.c
-echo '; }' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xu >> e${EMULATION_NAME}.c
+echo ' ; else if (link_info.relocatable) return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xr >> e${EMULATION_NAME}.c
+echo ' ; else if (!config.text_read_only) return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xbn >> e${EMULATION_NAME}.c
+echo ' ; else if (!config.magic_demand_paged) return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xn >> e${EMULATION_NAME}.c
+echo ' ; else return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.x >> e${EMULATION_NAME}.c
+echo '; }' >> e${EMULATION_NAME}.c
else
# Scripts read from the filesystem.
cat >>e${EMULATION_NAME}.c <<EOF
-{
+{
*isfile = 1;
- if (link_info.relocateable == true && config.build_constructors == true)
+ if (link_info.relocatable && config.build_constructors)
return "ldscripts/${EMULATION_NAME}.xu";
- else if (link_info.relocateable == true)
+ else if (link_info.relocatable)
return "ldscripts/${EMULATION_NAME}.xr";
else if (!config.text_read_only)
return "ldscripts/${EMULATION_NAME}.xbn";
@@ -121,7 +117,7 @@ fi
cat >>e${EMULATION_NAME}.c <<EOF
-struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
+struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
{
${LDEMUL_BEFORE_PARSE-gld${EMULATION_NAME}_before_parse},
${LDEMUL_SYSLIB-syslib_default},
@@ -141,6 +137,8 @@ struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
${LDEMUL_PLACE_ORPHAN-NULL},
${LDEMUL_SET_SYMBOLS-NULL},
${LDEMUL_PARSE_ARGS-NULL},
+ NULL, /* add_options */
+ NULL, /* handle_option */
${LDEMUL_UNRECOGNIZED_FILE-NULL},
${LDEMUL_LIST_OPTIONS-NULL},
${LDEMUL_RECOGNIZED_FILE-NULL},
diff --git a/contrib/binutils/ld/emultempl/ia64elf.em b/contrib/binutils/ld/emultempl/ia64elf.em
new file mode 100644
index 0000000..eee467b
--- /dev/null
+++ b/contrib/binutils/ld/emultempl/ia64elf.em
@@ -0,0 +1,62 @@
+# This shell script emits a C file. -*- C -*-
+# Copyright 2003 Free Software Foundation, Inc.
+#
+# This file is part of GLD, the Gnu Linker.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+#
+
+# This file is sourced from elf32.em, and defines extra ia64-elf
+# specific routines.
+#
+# Define some shell vars to insert bits of code into the standard elf
+# parse_args and list_options functions.
+#
+cat >>e${EMULATION_NAME}.c <<EOF
+
+/* None zero if generating binary for Intel Itanium processor. */
+static int itanium = 0;
+
+static void
+gld${EMULATION_NAME}_after_parse (void)
+{
+ link_info.need_relax_finalize = TRUE;
+ bfd_elf${ELFSIZE}_ia64_after_parse (itanium);
+}
+
+EOF
+
+PARSE_AND_LIST_PROLOGUE='
+#define OPTION_ITANIUM 300
+'
+
+PARSE_AND_LIST_LONGOPTS='
+ { "itanium", no_argument, NULL, OPTION_ITANIUM},
+'
+
+PARSE_AND_LIST_OPTIONS='
+ fprintf (file, _("\
+ --itanium Generate code for Intel Itanium processor\n"
+ ));
+'
+
+PARSE_AND_LIST_ARGS_CASES='
+ case OPTION_ITANIUM:
+ itanium = 1;
+ break;
+'
+
+LDEMUL_AFTER_PARSE=gld${EMULATION_NAME}_after_parse
+. ${srcdir}/emultempl/needrelax.em
diff --git a/contrib/binutils/ld/emultempl/linux.em b/contrib/binutils/ld/emultempl/linux.em
index fda490b..d041b68 100644
--- a/contrib/binutils/ld/emultempl/linux.em
+++ b/contrib/binutils/ld/emultempl/linux.em
@@ -1,6 +1,6 @@
# This shell script emits a C file. -*- C -*-
# It does some substitutions.
-if [ -z "$MACHINE" ]; then
+if [ -z "$MACHINE" ]; then
OUTPUT_ARCH=${ARCH}
else
OUTPUT_ARCH=${ARCH}:${MACHINE}
@@ -9,7 +9,7 @@ cat >e${EMULATION_NAME}.c <<EOF
/* This file is is generated by a shell script. DO NOT EDIT! */
/* Linux a.out emulation code for ${EMULATION_NAME}
- Copyright 1991, 1993, 1994, 1995, 1996, 1998, 1999, 2000
+ Copyright 1991, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2002, 2003, 2004
Free Software Foundation, Inc.
Written by Steve Chamberlain <sac@cygnus.com>
Linux support by Eric Youngdale <ericy@cais.cais.com>
@@ -44,45 +44,25 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "ldfile.h"
#include "ldemul.h"
-static void gld${EMULATION_NAME}_before_parse PARAMS ((void));
-static boolean gld${EMULATION_NAME}_open_dynamic_archive
- PARAMS ((const char *, search_dirs_type *, lang_input_statement_type *));
-static void gld${EMULATION_NAME}_find_address_statement
- PARAMS ((lang_statement_union_type *));
-static void gld${EMULATION_NAME}_create_output_section_statements
- PARAMS ((void));
-static void gld${EMULATION_NAME}_before_allocation PARAMS ((void));
-static char *gld${EMULATION_NAME}_get_script PARAMS ((int *isfile));
-
static void
-gld${EMULATION_NAME}_before_parse()
+gld${EMULATION_NAME}_before_parse (void)
{
- const bfd_arch_info_type *arch = bfd_scan_arch ("${OUTPUT_ARCH}");
- if (arch)
- {
- ldfile_output_architecture = arch->arch;
- ldfile_output_machine = arch->mach;
- ldfile_output_machine_name = arch->printable_name;
- }
- else
- ldfile_output_architecture = bfd_arch_${ARCH};
- config.dynamic_link = true;
- config.has_shared = true;
+ ldfile_set_output_arch ("${OUTPUT_ARCH}", bfd_arch_`echo ${ARCH} | sed -e 's/:.*//'`);
+ config.dynamic_link = TRUE;
+ config.has_shared = TRUE;
}
/* Try to open a dynamic archive. This is where we know that Linux
dynamic libraries have an extension of .sa. */
-static boolean
-gld${EMULATION_NAME}_open_dynamic_archive (arch, search, entry)
- const char *arch;
- search_dirs_type *search;
- lang_input_statement_type *entry;
+static bfd_boolean
+gld${EMULATION_NAME}_open_dynamic_archive
+ (const char *arch, search_dirs_type *search, lang_input_statement_type *entry)
{
char *string;
if (! entry->is_archive)
- return false;
+ return FALSE;
string = (char *) xmalloc (strlen (search->name)
+ strlen (entry->filename)
@@ -94,12 +74,12 @@ gld${EMULATION_NAME}_open_dynamic_archive (arch, search, entry)
if (! ldfile_try_open_bfd (string, entry))
{
free (string);
- return false;
+ return FALSE;
}
entry->filename = string;
- return true;
+ return TRUE;
}
/* This is called by the create_output_section_statements routine via
@@ -110,8 +90,7 @@ gld${EMULATION_NAME}_open_dynamic_archive (arch, search, entry)
Linux tools. */
static void
-gld${EMULATION_NAME}_find_address_statement (s)
- lang_statement_union_type *s;
+gld${EMULATION_NAME}_find_address_statement (lang_statement_union_type *s)
{
if (s->header.type == lang_address_statement_enum
&& strcmp (s->address_statement.section_name, ".text") == 0)
@@ -124,7 +103,7 @@ gld${EMULATION_NAME}_find_address_statement (s)
/* This is called before opening the input BFD's. */
static void
-gld${EMULATION_NAME}_create_output_section_statements ()
+gld${EMULATION_NAME}_create_output_section_statements (void)
{
lang_for_each_statement (gld${EMULATION_NAME}_find_address_statement);
}
@@ -133,9 +112,9 @@ gld${EMULATION_NAME}_create_output_section_statements ()
sections, but before any sizes or addresses have been set. */
static void
-gld${EMULATION_NAME}_before_allocation ()
+gld${EMULATION_NAME}_before_allocation (void)
{
- if (link_info.relocateable)
+ if (link_info.relocatable)
return;
/* Let the backend work out the sizes of any sections required by
@@ -145,8 +124,7 @@ gld${EMULATION_NAME}_before_allocation ()
}
static char *
-gld${EMULATION_NAME}_get_script(isfile)
- int *isfile;
+gld${EMULATION_NAME}_get_script (int *isfile)
EOF
if test -n "$COMPILE_IN"
@@ -157,33 +135,33 @@ then
sc="-f stringify.sed"
cat >>e${EMULATION_NAME}.c <<EOF
-{
+{
*isfile = 0;
- if (link_info.relocateable == true && config.build_constructors == true)
+ if (link_info.relocatable && config.build_constructors)
return
EOF
-sed $sc ldscripts/${EMULATION_NAME}.xu >> e${EMULATION_NAME}.c
-echo ' ; else if (link_info.relocateable == true) return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.xr >> e${EMULATION_NAME}.c
-echo ' ; else if (!config.text_read_only) return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.xbn >> e${EMULATION_NAME}.c
-echo ' ; else if (!config.magic_demand_paged) return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.xn >> e${EMULATION_NAME}.c
-echo ' ; else return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.x >> e${EMULATION_NAME}.c
-echo '; }' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xu >> e${EMULATION_NAME}.c
+echo ' ; else if (link_info.relocatable) return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xr >> e${EMULATION_NAME}.c
+echo ' ; else if (!config.text_read_only) return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xbn >> e${EMULATION_NAME}.c
+echo ' ; else if (!config.magic_demand_paged) return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xn >> e${EMULATION_NAME}.c
+echo ' ; else return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.x >> e${EMULATION_NAME}.c
+echo '; }' >> e${EMULATION_NAME}.c
else
# Scripts read from the filesystem.
cat >>e${EMULATION_NAME}.c <<EOF
-{
+{
*isfile = 1;
- if (link_info.relocateable == true && config.build_constructors == true)
+ if (link_info.relocatable && config.build_constructors)
return "ldscripts/${EMULATION_NAME}.xu";
- else if (link_info.relocateable == true)
+ else if (link_info.relocatable)
return "ldscripts/${EMULATION_NAME}.xr";
else if (!config.text_read_only)
return "ldscripts/${EMULATION_NAME}.xbn";
@@ -198,7 +176,7 @@ fi
cat >>e${EMULATION_NAME}.c <<EOF
-struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
+struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
{
gld${EMULATION_NAME}_before_parse,
syslib_default,
@@ -218,6 +196,8 @@ struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
NULL, /* place orphan */
NULL, /* set symbols */
NULL, /* parse args */
+ NULL, /* add_options */
+ NULL, /* handle_option */
NULL, /* unrecognized file */
NULL, /* list options */
NULL, /* recognized file */
diff --git a/contrib/binutils/ld/emultempl/needrelax.em b/contrib/binutils/ld/emultempl/needrelax.em
index 9bb96c2..65e622b 100644
--- a/contrib/binutils/ld/emultempl/needrelax.em
+++ b/contrib/binutils/ld/emultempl/needrelax.em
@@ -1,5 +1,5 @@
# This shell script emits a C file. -*- C -*-
-# Copyright (C) 2001 Free Software Foundation, Inc.
+# Copyright 2001, 2002, 2003 Free Software Foundation, Inc.
#
# This file is part of GLD, the Gnu Linker.
#
@@ -25,16 +25,14 @@ LDEMUL_BEFORE_ALLOCATION=need_relax_${EMULATION_NAME}_before_allocation
cat >>e${EMULATION_NAME}.c <<EOF
-static void need_relax_${EMULATION_NAME}_before_allocation PARAMS ((void));
-
static void
-need_relax_${EMULATION_NAME}_before_allocation ()
+need_relax_${EMULATION_NAME}_before_allocation (void)
{
/* Call main function; we're just extending it. */
gld${EMULATION_NAME}_before_allocation ();
/* Force -relax on if not doing a relocatable link. */
- if (! link_info.relocateable)
- command_line.relax = true;
+ if (! link_info.relocatable)
+ command_line.relax = TRUE;
}
EOF
diff --git a/contrib/binutils/ld/emultempl/netbsd.em b/contrib/binutils/ld/emultempl/netbsd.em
new file mode 100644
index 0000000..43715e4
--- /dev/null
+++ b/contrib/binutils/ld/emultempl/netbsd.em
@@ -0,0 +1,13 @@
+LDEMUL_BEFORE_PARSE=gldnetbsd_before_parse
+
+cat >>e${EMULATION_NAME}.c <<EOF
+static void
+gld${EMULATION_NAME}_before_parse (void);
+
+static void
+gldnetbsd_before_parse (void)
+{
+ gld${EMULATION_NAME}_before_parse ();
+ link_info.common_skip_ar_aymbols = bfd_link_common_skip_text;
+}
+EOF
diff --git a/contrib/binutils/ld/emultempl/pe.em b/contrib/binutils/ld/emultempl/pe.em
index 474b984..7d6c2e8 100644
--- a/contrib/binutils/ld/emultempl/pe.em
+++ b/contrib/binutils/ld/emultempl/pe.em
@@ -9,22 +9,22 @@ rm -f e${EMULATION_NAME}.c
(echo;echo;echo;echo;echo)>e${EMULATION_NAME}.c # there, now line numbers match ;-)
cat >>e${EMULATION_NAME}.c <<EOF
/* This file is part of GLD, the Gnu Linker.
- Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
+ Copyright 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* For WINDOWS_NT */
/* The original file generated returned different default scripts depending
@@ -68,8 +68,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "deffile.h"
#include "pe-dll.h"
-
-#include <ctype.h>
+#include "safe-ctype.h"
/* Permit the emulation parameters to override the default section
alignment by setting OVERRIDE_SECTION_ALIGNMENT. FIXME: This makes
@@ -104,42 +103,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define PE_DEF_FILE_ALIGNMENT 0x00000200
#endif
-static void gld_${EMULATION_NAME}_set_symbols PARAMS ((void));
-static void gld_${EMULATION_NAME}_after_open PARAMS ((void));
-static void gld_${EMULATION_NAME}_before_parse PARAMS ((void));
-static void gld_${EMULATION_NAME}_after_parse PARAMS ((void));
-static void gld_${EMULATION_NAME}_before_allocation PARAMS ((void));
-static asection *output_prev_sec_find
- PARAMS ((lang_output_section_statement_type *));
-static boolean gld_${EMULATION_NAME}_place_orphan
- PARAMS ((lang_input_statement_type *, asection *));
-static char *gld_${EMULATION_NAME}_get_script PARAMS ((int *));
-static int gld_${EMULATION_NAME}_parse_args PARAMS ((int, char **));
-static void gld_${EMULATION_NAME}_finish PARAMS ((void));
-static boolean gld_${EMULATION_NAME}_open_dynamic_archive
- PARAMS ((const char *, search_dirs_type *, lang_input_statement_type *));
-static void gld_${EMULATION_NAME}_list_options PARAMS ((FILE *));
-static void set_pe_name PARAMS ((char *, long));
-static void set_pe_subsystem PARAMS ((void));
-static void set_pe_value PARAMS ((char *));
-static void set_pe_stack_heap PARAMS ((char *, char *));
-
-#ifdef DLL_SUPPORT
-static boolean pe_undef_cdecl_match
- PARAMS ((struct bfd_link_hash_entry *, PTR));
-static void pe_fixup_stdcalls PARAMS ((void));
-static int make_import_fixup PARAMS ((arelent *, asection *));
-static void pe_find_data_imports PARAMS ((void));
-#endif
-
-static boolean pr_sym PARAMS ((struct bfd_hash_entry *, PTR string));
-static boolean gld_${EMULATION_NAME}_unrecognized_file
- PARAMS ((lang_input_statement_type *));
-static boolean gld_${EMULATION_NAME}_recognized_file
- PARAMS ((lang_input_statement_type *));
-static int gld_${EMULATION_NAME}_find_potential_libraries
- PARAMS ((char *, lang_input_statement_type *));
-
static struct internal_extra_pe_aouthdr pe;
static int dll;
@@ -148,7 +111,7 @@ static char * thumb_entry_symbol = NULL;
static lang_assignment_statement_type *image_base_statement = 0;
#ifdef DLL_SUPPORT
-static int pe_enable_stdcall_fixup = -1; /* 0=disable 1=enable */
+static int pe_enable_stdcall_fixup = -1; /* 0=disable 1=enable. */
static char *pe_out_def_filename = NULL;
static char *pe_implib_filename = NULL;
static int pe_enable_auto_image_base = 0;
@@ -158,28 +121,21 @@ static char *pe_dll_search_prefix = NULL;
extern const char *output_filename;
static void
-gld_${EMULATION_NAME}_before_parse()
+gld_${EMULATION_NAME}_before_parse (void)
{
- const bfd_arch_info_type *arch = bfd_scan_arch ("${OUTPUT_ARCH}");
- if (arch)
- {
- ldfile_output_architecture = arch->arch;
- ldfile_output_machine = arch->mach;
- ldfile_output_machine_name = arch->printable_name;
- }
- else
- ldfile_output_architecture = bfd_arch_${ARCH};
+ ldfile_set_output_arch ("${OUTPUT_ARCH}", bfd_arch_`echo ${ARCH} | sed -e 's/:.*//'`);
output_filename = "${EXECUTABLE_NAME:-a.exe}";
#ifdef DLL_SUPPORT
- config.dynamic_link = true;
+ config.dynamic_link = TRUE;
config.has_shared = 1;
link_info.pei386_auto_import = -1;
+ link_info.pei386_runtime_pseudo_reloc = FALSE;
#if (PE_DEF_SUBSYSTEM == 9) || (PE_DEF_SUBSYSTEM == 2)
#if defined TARGET_IS_mipspe || defined TARGET_IS_armpe
- lang_add_entry ("WinMainCRTStartup", 1);
+ lang_add_entry ("WinMainCRTStartup", FALSE);
#else
- lang_add_entry ("_WinMainCRTStartup", 1);
+ lang_add_entry ("_WinMainCRTStartup", FALSE);
#endif
#endif
#endif
@@ -187,7 +143,7 @@ gld_${EMULATION_NAME}_before_parse()
/* PE format extra command line options. */
-/* Used for setting flags in the PE header. */
+/* Used for setting flags in the PE header. */
#define OPTION_BASE_FILE (300 + 1)
#define OPTION_DLL (OPTION_BASE_FILE + 1)
#define OPTION_FILE_ALIGNMENT (OPTION_DLL + 1)
@@ -199,8 +155,8 @@ gld_${EMULATION_NAME}_before_parse()
#define OPTION_MINOR_OS_VERSION (OPTION_MINOR_IMAGE_VERSION + 1)
#define OPTION_MINOR_SUBSYSTEM_VERSION (OPTION_MINOR_OS_VERSION + 1)
#define OPTION_SECTION_ALIGNMENT (OPTION_MINOR_SUBSYSTEM_VERSION + 1)
-#define OPTION_STACK (OPTION_SECTION_ALIGNMENT + 1)
-#define OPTION_SUBSYSTEM (OPTION_STACK + 1)
+#define OPTION_STACK (OPTION_SECTION_ALIGNMENT + 1)
+#define OPTION_SUBSYSTEM (OPTION_STACK + 1)
#define OPTION_HEAP (OPTION_SUBSYSTEM + 1)
#define OPTION_SUPPORT_OLD_CODE (OPTION_HEAP + 1)
#define OPTION_OUT_DEF (OPTION_SUPPORT_OLD_CODE + 1)
@@ -222,54 +178,73 @@ gld_${EMULATION_NAME}_before_parse()
#define OPTION_DLL_DISABLE_AUTO_IMPORT (OPTION_DLL_ENABLE_AUTO_IMPORT + 1)
#define OPTION_ENABLE_EXTRA_PE_DEBUG (OPTION_DLL_DISABLE_AUTO_IMPORT + 1)
#define OPTION_EXCLUDE_LIBS (OPTION_ENABLE_EXTRA_PE_DEBUG + 1)
+#define OPTION_DLL_ENABLE_RUNTIME_PSEUDO_RELOC \
+ (OPTION_EXCLUDE_LIBS + 1)
+#define OPTION_DLL_DISABLE_RUNTIME_PSEUDO_RELOC \
+ (OPTION_DLL_ENABLE_RUNTIME_PSEUDO_RELOC + 1)
-static struct option longopts[] = {
- /* PE options */
- {"base-file", required_argument, NULL, OPTION_BASE_FILE},
- {"dll", no_argument, NULL, OPTION_DLL},
- {"file-alignment", required_argument, NULL, OPTION_FILE_ALIGNMENT},
- {"heap", required_argument, NULL, OPTION_HEAP},
- {"image-base", required_argument, NULL, OPTION_IMAGE_BASE},
- {"major-image-version", required_argument, NULL, OPTION_MAJOR_IMAGE_VERSION},
- {"major-os-version", required_argument, NULL, OPTION_MAJOR_OS_VERSION},
- {"major-subsystem-version", required_argument, NULL, OPTION_MAJOR_SUBSYSTEM_VERSION},
- {"minor-image-version", required_argument, NULL, OPTION_MINOR_IMAGE_VERSION},
- {"minor-os-version", required_argument, NULL, OPTION_MINOR_OS_VERSION},
- {"minor-subsystem-version", required_argument, NULL, OPTION_MINOR_SUBSYSTEM_VERSION},
- {"section-alignment", required_argument, NULL, OPTION_SECTION_ALIGNMENT},
- {"stack", required_argument, NULL, OPTION_STACK},
- {"subsystem", required_argument, NULL, OPTION_SUBSYSTEM},
- {"support-old-code", no_argument, NULL, OPTION_SUPPORT_OLD_CODE},
- {"thumb-entry", required_argument, NULL, OPTION_THUMB_ENTRY},
+static void
+gld${EMULATION_NAME}_add_options
+ (int ns ATTRIBUTE_UNUSED, char **shortopts ATTRIBUTE_UNUSED, int nl,
+ struct option **longopts, int nrl ATTRIBUTE_UNUSED,
+ struct option **really_longopts ATTRIBUTE_UNUSED)
+{
+ static const struct option xtra_long[] = {
+ /* PE options */
+ {"base-file", required_argument, NULL, OPTION_BASE_FILE},
+ {"dll", no_argument, NULL, OPTION_DLL},
+ {"file-alignment", required_argument, NULL, OPTION_FILE_ALIGNMENT},
+ {"heap", required_argument, NULL, OPTION_HEAP},
+ {"image-base", required_argument, NULL, OPTION_IMAGE_BASE},
+ {"major-image-version", required_argument, NULL, OPTION_MAJOR_IMAGE_VERSION},
+ {"major-os-version", required_argument, NULL, OPTION_MAJOR_OS_VERSION},
+ {"major-subsystem-version", required_argument, NULL, OPTION_MAJOR_SUBSYSTEM_VERSION},
+ {"minor-image-version", required_argument, NULL, OPTION_MINOR_IMAGE_VERSION},
+ {"minor-os-version", required_argument, NULL, OPTION_MINOR_OS_VERSION},
+ {"minor-subsystem-version", required_argument, NULL, OPTION_MINOR_SUBSYSTEM_VERSION},
+ {"section-alignment", required_argument, NULL, OPTION_SECTION_ALIGNMENT},
+ {"stack", required_argument, NULL, OPTION_STACK},
+ {"subsystem", required_argument, NULL, OPTION_SUBSYSTEM},
+ {"support-old-code", no_argument, NULL, OPTION_SUPPORT_OLD_CODE},
+ {"thumb-entry", required_argument, NULL, OPTION_THUMB_ENTRY},
#ifdef DLL_SUPPORT
- /* getopt allows abbreviations, so we do this to stop it from treating -o
- as an abbreviation for this option */
- {"output-def", required_argument, NULL, OPTION_OUT_DEF},
- {"output-def", required_argument, NULL, OPTION_OUT_DEF},
- {"export-all-symbols", no_argument, NULL, OPTION_EXPORT_ALL},
- {"exclude-symbols", required_argument, NULL, OPTION_EXCLUDE_SYMBOLS},
- {"exclude-libs", required_argument, NULL, OPTION_EXCLUDE_LIBS},
- {"kill-at", no_argument, NULL, OPTION_KILL_ATS},
- {"add-stdcall-alias", no_argument, NULL, OPTION_STDCALL_ALIASES},
- {"enable-stdcall-fixup", no_argument, NULL, OPTION_ENABLE_STDCALL_FIXUP},
- {"disable-stdcall-fixup", no_argument, NULL, OPTION_DISABLE_STDCALL_FIXUP},
- {"out-implib", required_argument, NULL, OPTION_IMPLIB_FILENAME},
- {"warn-duplicate-exports", no_argument, NULL, OPTION_WARN_DUPLICATE_EXPORTS},
- {"compat-implib", no_argument, NULL, OPTION_IMP_COMPAT},
- {"enable-auto-image-base", no_argument, NULL, OPTION_ENABLE_AUTO_IMAGE_BASE},
- {"disable-auto-image-base", no_argument, NULL, OPTION_DISABLE_AUTO_IMAGE_BASE},
- {"dll-search-prefix", required_argument, NULL, OPTION_DLL_SEARCH_PREFIX},
- {"no-default-excludes", no_argument, NULL, OPTION_NO_DEFAULT_EXCLUDES},
- {"enable-auto-import", no_argument, NULL, OPTION_DLL_ENABLE_AUTO_IMPORT},
- {"disable-auto-import", no_argument, NULL, OPTION_DLL_DISABLE_AUTO_IMPORT},
- {"enable-extra-pe-debug", no_argument, NULL, OPTION_ENABLE_EXTRA_PE_DEBUG},
+ /* getopt allows abbreviations, so we do this to stop it from treating -o
+ as an abbreviation for this option */
+ {"output-def", required_argument, NULL, OPTION_OUT_DEF},
+ {"output-def", required_argument, NULL, OPTION_OUT_DEF},
+ {"export-all-symbols", no_argument, NULL, OPTION_EXPORT_ALL},
+ {"exclude-symbols", required_argument, NULL, OPTION_EXCLUDE_SYMBOLS},
+ {"exclude-libs", required_argument, NULL, OPTION_EXCLUDE_LIBS},
+ {"kill-at", no_argument, NULL, OPTION_KILL_ATS},
+ {"add-stdcall-alias", no_argument, NULL, OPTION_STDCALL_ALIASES},
+ {"enable-stdcall-fixup", no_argument, NULL, OPTION_ENABLE_STDCALL_FIXUP},
+ {"disable-stdcall-fixup", no_argument, NULL, OPTION_DISABLE_STDCALL_FIXUP},
+ {"out-implib", required_argument, NULL, OPTION_IMPLIB_FILENAME},
+ {"warn-duplicate-exports", no_argument, NULL, OPTION_WARN_DUPLICATE_EXPORTS},
+ /* getopt() allows abbreviations, so we do this to stop it from
+ treating -c as an abbreviation for these --compat-implib. */
+ {"compat-implib", no_argument, NULL, OPTION_IMP_COMPAT},
+ {"compat-implib", no_argument, NULL, OPTION_IMP_COMPAT},
+ {"enable-auto-image-base", no_argument, NULL, OPTION_ENABLE_AUTO_IMAGE_BASE},
+ {"disable-auto-image-base", no_argument, NULL, OPTION_DISABLE_AUTO_IMAGE_BASE},
+ {"dll-search-prefix", required_argument, NULL, OPTION_DLL_SEARCH_PREFIX},
+ {"no-default-excludes", no_argument, NULL, OPTION_NO_DEFAULT_EXCLUDES},
+ {"enable-auto-import", no_argument, NULL, OPTION_DLL_ENABLE_AUTO_IMPORT},
+ {"disable-auto-import", no_argument, NULL, OPTION_DLL_DISABLE_AUTO_IMPORT},
+ {"enable-extra-pe-debug", no_argument, NULL, OPTION_ENABLE_EXTRA_PE_DEBUG},
+ {"enable-runtime-pseudo-reloc", no_argument, NULL, OPTION_DLL_ENABLE_RUNTIME_PSEUDO_RELOC},
+ {"disable-runtime-pseudo-reloc", no_argument, NULL, OPTION_DLL_DISABLE_RUNTIME_PSEUDO_RELOC},
#endif
- {NULL, no_argument, NULL, 0}
-};
+ {NULL, no_argument, NULL, 0}
+ };
+ *longopts = (struct option *)
+ xrealloc (*longopts, nl * sizeof (struct option) + sizeof (xtra_long));
+ memcpy (*longopts + nl, &xtra_long, sizeof (xtra_long));
+}
/* PE/WIN32; added routines to get the subsystem type, heap and/or stack
- parameters which may be input from the command line */
+ parameters which may be input from the command line. */
typedef struct
{
@@ -310,9 +285,9 @@ static definfo init[] =
{ NULL, 0, 0, NULL, 0 }
};
+
static void
-gld_${EMULATION_NAME}_list_options (file)
- FILE * file;
+gld_${EMULATION_NAME}_list_options (FILE *file)
{
fprintf (file, _(" --base_file <basefile> Generate a base file for relocatable DLLs\n"));
fprintf (file, _(" --dll Set image base to the default for DLLs\n"));
@@ -335,7 +310,7 @@ gld_${EMULATION_NAME}_list_options (file)
fprintf (file, _(" --disable-stdcall-fixup Don't link _sym to _sym@nn\n"));
fprintf (file, _(" --enable-stdcall-fixup Link _sym to _sym@nn without warnings\n"));
fprintf (file, _(" --exclude-symbols sym,sym,... Exclude symbols from automatic export\n"));
- fprintf (file, _(" --exclude-libs lib,lib,... Exclude libraries from automatic export\n"));
+ fprintf (file, _(" --exclude-libs lib,lib,... Exclude libraries from automatic export\n"));
fprintf (file, _(" --export-all-symbols Automatically export all globals to DLL\n"));
fprintf (file, _(" --kill-at Remove @nn from exported symbols\n"));
fprintf (file, _(" --out-implib <file> Generate import library\n"));
@@ -346,24 +321,29 @@ gld_${EMULATION_NAME}_list_options (file)
fprintf (file, _(" --enable-auto-image-base Automatically choose image base for DLLs\n\
unless user specifies one\n"));
fprintf (file, _(" --disable-auto-image-base Do not auto-choose image base. (default)\n"));
- fprintf (file, _(" --dll-search-prefix=<string> When linking dynamically to a dll without an\n\
- importlib, use <string><basename>.dll \n\
+ fprintf (file, _(" --dll-search-prefix=<string> When linking dynamically to a dll without\n\
+ an importlib, use <string><basename>.dll\n\
in preference to lib<basename>.dll \n"));
- fprintf (file, _(" --enable-auto-import Do sophistcated linking of _sym to \n\
+ fprintf (file, _(" --enable-auto-import Do sophistcated linking of _sym to\n\
__imp_sym for DATA references\n"));
fprintf (file, _(" --disable-auto-import Do not auto-import DATA items from DLLs\n"));
+ fprintf (file, _(" --enable-runtime-pseudo-reloc Work around auto-import limitations by\n\
+ adding pseudo-relocations resolved at\n\
+ runtime.\n"));
+ fprintf (file, _(" --disable-runtime-pseudo-reloc Do not add runtime pseudo-relocations for\n\
+ auto-imported DATA.\n"));
fprintf (file, _(" --enable-extra-pe-debug Enable verbose debug output when building\n\
or linking to DLLs (esp. auto-import)\n"));
#endif
}
+
static void
-set_pe_name (name, val)
- char *name;
- long val;
+set_pe_name (char *name, long val)
{
int i;
- /* Find the name and set it. */
+
+ /* Find the name and set it. */
for (i = 0; init[i].ptr; i++)
{
if (strcmp (name, init[i].symbol) == 0)
@@ -373,12 +353,12 @@ set_pe_name (name, val)
return;
}
}
- abort();
+ abort ();
}
static void
-set_pe_subsystem ()
+set_pe_subsystem (void)
{
const char *sver;
int len;
@@ -451,7 +431,7 @@ set_pe_subsystem ()
entry = alc_entry;
}
- lang_add_entry (entry, 0);
+ lang_add_entry (entry, TRUE);
return;
}
@@ -461,11 +441,8 @@ set_pe_subsystem ()
}
-
static void
-set_pe_value (name)
- char *name;
-
+set_pe_value (char *name)
{
char *end;
@@ -477,10 +454,9 @@ set_pe_value (name)
optarg = end;
}
+
static void
-set_pe_stack_heap (resname, comname)
- char *resname;
- char *comname;
+set_pe_stack_heap (char *resname, char *comname)
{
set_pe_value (resname);
@@ -494,38 +470,16 @@ set_pe_stack_heap (resname, comname)
}
-
-static int
-gld_${EMULATION_NAME}_parse_args(argc, argv)
- int argc;
- char **argv;
+static bfd_boolean
+gld${EMULATION_NAME}_handle_option (int optc)
{
- int longind;
- int optc;
- int prevoptind = optind;
- int prevopterr = opterr;
- int wanterror;
- static int lastoptind = -1;
-
- if (lastoptind != optind)
- opterr = 0;
- wanterror = opterr;
-
- lastoptind = optind;
-
- optc = getopt_long_only (argc, argv, "-", longopts, &longind);
- opterr = prevopterr;
-
switch (optc)
{
default:
- if (wanterror)
- xexit (1);
- optind = prevoptind;
- return 0;
+ return FALSE;
case OPTION_BASE_FILE:
- link_info.base_file = (PTR) fopen (optarg, FOPEN_WB);
+ link_info.base_file = fopen (optarg, FOPEN_WB);
if (link_info.base_file == NULL)
{
/* xgettext:c-format */
@@ -535,7 +489,7 @@ gld_${EMULATION_NAME}_parse_args(argc, argv)
}
break;
- /* PE options */
+ /* PE options. */
case OPTION_HEAP:
set_pe_stack_heap ("__size_of_heap_reserve__", "__size_of_heap_commit__");
break;
@@ -622,7 +576,7 @@ gld_${EMULATION_NAME}_parse_args(argc, argv)
pe_enable_auto_image_base = 0;
break;
case OPTION_DLL_SEARCH_PREFIX:
- pe_dll_search_prefix = xstrdup( optarg );
+ pe_dll_search_prefix = xstrdup (optarg);
break;
case OPTION_NO_DEFAULT_EXCLUDES:
pe_dll_do_default_excludes = 0;
@@ -633,12 +587,18 @@ gld_${EMULATION_NAME}_parse_args(argc, argv)
case OPTION_DLL_DISABLE_AUTO_IMPORT:
link_info.pei386_auto_import = 0;
break;
+ case OPTION_DLL_ENABLE_RUNTIME_PSEUDO_RELOC:
+ link_info.pei386_runtime_pseudo_reloc = 1;
+ break;
+ case OPTION_DLL_DISABLE_RUNTIME_PSEUDO_RELOC:
+ link_info.pei386_runtime_pseudo_reloc = 0;
+ break;
case OPTION_ENABLE_EXTRA_PE_DEBUG:
pe_dll_extra_pe_debug = 1;
break;
#endif
}
- return 1;
+ return TRUE;
}
@@ -666,7 +626,8 @@ strhash (const char *str)
return hash;
}
-/* Use the output file to create a image base for relocatable DLLs. */
+/* Use the output file to create a image base for relocatable DLLs. */
+
static unsigned long
compute_dll_image_base (const char *ofile)
{
@@ -679,16 +640,16 @@ compute_dll_image_base (const char *ofile)
read. */
static void
-gld_${EMULATION_NAME}_set_symbols ()
+gld_${EMULATION_NAME}_set_symbols (void)
{
/* Run through and invent symbols for all the
- names and insert the defaults. */
+ names and insert the defaults. */
int j;
lang_statement_list_type *save;
if (!init[IMAGEBASEOFF].inited)
{
- if (link_info.relocateable)
+ if (link_info.relocatable)
init[IMAGEBASEOFF].value = 0;
else if (init[DLLOFF].value || link_info.shared)
#ifdef DLL_SUPPORT
@@ -701,11 +662,11 @@ gld_${EMULATION_NAME}_set_symbols ()
init[IMAGEBASEOFF].value = NT_EXE_IMAGE_BASE;
}
- /* Don't do any symbol assignments if this is a relocateable link. */
- if (link_info.relocateable)
+ /* Don't do any symbol assignments if this is a relocatable link. */
+ if (link_info.relocatable)
return;
- /* Glue the assignments into the abs section */
+ /* Glue the assignments into the abs section. */
save = stat_ptr;
stat_ptr = &(abs_output_section->children);
@@ -716,20 +677,20 @@ gld_${EMULATION_NAME}_set_symbols ()
lang_assignment_statement_type *rv;
rv = lang_add_assignment (exp_assop ('=', init[j].symbol,
exp_intop (val)));
- if (init[j].size == sizeof(short))
- *(short *)init[j].ptr = val;
- else if (init[j].size == sizeof(int))
- *(int *)init[j].ptr = val;
- else if (init[j].size == sizeof(long))
- *(long *)init[j].ptr = val;
+ if (init[j].size == sizeof (short))
+ *(short *) init[j].ptr = val;
+ else if (init[j].size == sizeof (int))
+ *(int *) init[j].ptr = val;
+ else if (init[j].size == sizeof (long))
+ *(long *) init[j].ptr = val;
/* This might be a long long or other special type. */
- else if (init[j].size == sizeof(bfd_vma))
- *(bfd_vma *)init[j].ptr = val;
- else abort();
+ else if (init[j].size == sizeof (bfd_vma))
+ *(bfd_vma *) init[j].ptr = val;
+ else abort ();
if (j == IMAGEBASEOFF)
image_base_statement = rv;
}
- /* Restore the pointer. */
+ /* Restore the pointer. */
stat_ptr = save;
if (pe.FileAlignment >
@@ -743,7 +704,7 @@ gld_${EMULATION_NAME}_set_symbols ()
have been read. */
static void
-gld_${EMULATION_NAME}_after_parse ()
+gld_${EMULATION_NAME}_after_parse (void)
{
/* The Windows libraries are designed for the linker to treat the
entry point as an undefined symbol. Otherwise, the .obj that
@@ -758,7 +719,7 @@ gld_${EMULATION_NAME}_after_parse ()
opened, so registering the symbol as undefined will make a
difference. */
- if (! link_info.relocateable && entry_symbol.name != NULL)
+ if (! link_info.relocatable && entry_symbol.name != NULL)
ldlang_add_undef (entry_symbol.name);
}
@@ -772,222 +733,212 @@ char * pe_data_import_dll;
#ifdef DLL_SUPPORT
static struct bfd_link_hash_entry *pe_undef_found_sym;
-static boolean
-pe_undef_cdecl_match (h, string)
- struct bfd_link_hash_entry *h;
- PTR string;
+static bfd_boolean
+pe_undef_cdecl_match (struct bfd_link_hash_entry *h, void *inf)
{
int sl;
- sl = strlen (string); /* silence compiler warning */
+ char *string = inf;
+
+ sl = strlen (string);
if (h->type == bfd_link_hash_defined
&& strncmp (h->root.string, string, sl) == 0
&& h->root.string[sl] == '@')
{
pe_undef_found_sym = h;
- return false;
+ return FALSE;
}
- return true;
+ return TRUE;
}
static void
-pe_fixup_stdcalls ()
+pe_fixup_stdcalls (void)
{
static int gave_warning_message = 0;
struct bfd_link_hash_entry *undef, *sym;
- char *at;
+
if (pe_dll_extra_pe_debug)
- {
- printf ("%s\n", __FUNCTION__);
- }
+ printf ("%s\n", __FUNCTION__);
- for (undef = link_info.hash->undefs; undef; undef=undef->next)
+ for (undef = link_info.hash->undefs; undef; undef=undef->und_next)
if (undef->type == bfd_link_hash_undefined)
- {
- at = strchr (undef->root.string, '@');
- if (at)
{
- /* The symbol is a stdcall symbol, so let's look for a cdecl
- symbol with the same name and resolve to that */
- char *cname = xstrdup (undef->root.string);
- at = strchr (cname, '@');
- *at = 0;
- sym = bfd_link_hash_lookup (link_info.hash, cname, 0, 0, 1);
- if (sym && sym->type == bfd_link_hash_defined)
- {
- undef->type = bfd_link_hash_defined;
- undef->u.def.value = sym->u.def.value;
- undef->u.def.section = sym->u.def.section;
- if (pe_enable_stdcall_fixup == -1)
- {
- einfo (_("Warning: resolving %s by linking to %s\n"),
- undef->root.string, cname);
- if (! gave_warning_message)
- {
- gave_warning_message = 1;
- einfo(_("Use --enable-stdcall-fixup to disable these warnings\n"));
- einfo(_("Use --disable-stdcall-fixup to disable these fixups\n"));
- }
- }
- }
- }
- else
- {
- /* The symbol is a cdecl symbol, so we look for stdcall
- symbols - which means scanning the whole symbol table */
- pe_undef_found_sym = 0;
- bfd_link_hash_traverse (link_info.hash, pe_undef_cdecl_match,
- (PTR) undef->root.string);
- sym = pe_undef_found_sym;
- if (sym)
- {
- undef->type = bfd_link_hash_defined;
- undef->u.def.value = sym->u.def.value;
- undef->u.def.section = sym->u.def.section;
- if (pe_enable_stdcall_fixup == -1)
- {
- einfo (_("Warning: resolving %s by linking to %s\n"),
- undef->root.string, sym->root.string);
- if (! gave_warning_message)
- {
- gave_warning_message = 1;
- einfo(_("Use --enable-stdcall-fixup to disable these warnings\n"));
- einfo(_("Use --disable-stdcall-fixup to disable these fixups\n"));
- }
- }
- }
+ char* at = strchr (undef->root.string, '@');
+ int lead_at = (*undef->root.string == '@');
+ /* For now, don't try to fixup fastcall symbols. */
+
+ if (at && !lead_at)
+ {
+ /* The symbol is a stdcall symbol, so let's look for a
+ cdecl symbol with the same name and resolve to that. */
+ char *cname = xstrdup (undef->root.string /* + lead_at */);
+ at = strchr (cname, '@');
+ *at = 0;
+ sym = bfd_link_hash_lookup (link_info.hash, cname, 0, 0, 1);
+
+ if (sym && sym->type == bfd_link_hash_defined)
+ {
+ undef->type = bfd_link_hash_defined;
+ undef->u.def.value = sym->u.def.value;
+ undef->u.def.section = sym->u.def.section;
+
+ if (pe_enable_stdcall_fixup == -1)
+ {
+ einfo (_("Warning: resolving %s by linking to %s\n"),
+ undef->root.string, cname);
+ if (! gave_warning_message)
+ {
+ gave_warning_message = 1;
+ einfo (_("Use --enable-stdcall-fixup to disable these warnings\n"));
+ einfo (_("Use --disable-stdcall-fixup to disable these fixups\n"));
+ }
+ }
+ }
+ }
+ else
+ {
+ /* The symbol is a cdecl symbol, so we look for stdcall
+ symbols - which means scanning the whole symbol table. */
+ pe_undef_found_sym = 0;
+ bfd_link_hash_traverse (link_info.hash, pe_undef_cdecl_match,
+ (char *) undef->root.string);
+ sym = pe_undef_found_sym;
+ if (sym)
+ {
+ undef->type = bfd_link_hash_defined;
+ undef->u.def.value = sym->u.def.value;
+ undef->u.def.section = sym->u.def.section;
+
+ if (pe_enable_stdcall_fixup == -1)
+ {
+ einfo (_("Warning: resolving %s by linking to %s\n"),
+ undef->root.string, sym->root.string);
+ if (! gave_warning_message)
+ {
+ gave_warning_message = 1;
+ einfo (_("Use --enable-stdcall-fixup to disable these warnings\n"));
+ einfo (_("Use --disable-stdcall-fixup to disable these fixups\n"));
+ }
+ }
+ }
+ }
}
- }
}
static int
-make_import_fixup (rel, s)
- arelent *rel;
- asection *s;
+make_import_fixup (arelent *rel, asection *s)
{
- struct symbol_cache_entry *sym = *rel->sym_ptr_ptr;
+ struct bfd_symbol *sym = *rel->sym_ptr_ptr;
+ int addend = 0;
if (pe_dll_extra_pe_debug)
- {
- printf ("arelent: %s@%#lx: add=%li\n", sym->name,
- (long) rel->address, (long) rel->addend);
- }
+ printf ("arelent: %s@%#lx: add=%li\n", sym->name,
+ (long) rel->address, (long) rel->addend);
- {
- int addend = 0;
- if (!bfd_get_section_contents(s->owner, s, &addend, rel->address, sizeof(addend)))
- {
- einfo (_("%C: Cannot get section contents - auto-import exception\n"),
- s->owner, s, rel->address);
- }
+ if (! bfd_get_section_contents (s->owner, s, &addend, rel->address, sizeof (addend)))
+ einfo (_("%C: Cannot get section contents - auto-import exception\n"),
+ s->owner, s, rel->address);
- if (addend == 0)
- pe_create_import_fixup (rel);
- else
- {
- einfo (_("%C: variable '%T' can't be auto-imported. Please read the documentation for ld's --enable-auto-import for details.\n"),
- s->owner, s, rel->address, sym->name);
- einfo ("%X");
- }
- }
+ pe_create_import_fixup (rel, s, addend);
return 1;
}
static void
-pe_find_data_imports ()
+pe_find_data_imports (void)
{
struct bfd_link_hash_entry *undef, *sym;
- for (undef = link_info.hash->undefs; undef; undef=undef->next)
+
+ if (link_info.pei386_auto_import == 0)
+ return;
+
+ for (undef = link_info.hash->undefs; undef; undef=undef->und_next)
{
if (undef->type == bfd_link_hash_undefined)
{
- /* C++ symbols are *long* */
+ /* C++ symbols are *long*. */
char buf[4096];
- if (pe_dll_extra_pe_debug)
- {
- printf ("%s:%s\n", __FUNCTION__, undef->root.string);
- }
+
+ if (pe_dll_extra_pe_debug)
+ printf ("%s:%s\n", __FUNCTION__, undef->root.string);
+
sprintf (buf, "__imp_%s", undef->root.string);
sym = bfd_link_hash_lookup (link_info.hash, buf, 0, 0, 1);
+
if (sym && sym->type == bfd_link_hash_defined)
{
- if (link_info.pei386_auto_import == -1)
- info_msg (_("Info: resolving %s by linking to %s (auto-import)\n"),
- undef->root.string, buf);
- {
- bfd *b = sym->u.def.section->owner;
- asymbol **symbols;
- int nsyms, symsize, i;
-
- symsize = bfd_get_symtab_upper_bound (b);
- symbols = (asymbol **) xmalloc (symsize);
- nsyms = bfd_canonicalize_symtab (b, symbols);
-
- for (i = 0; i < nsyms; i++)
- {
- if (memcmp(symbols[i]->name, "__head_",
- sizeof ("__head_") - 1))
- continue;
- if (pe_dll_extra_pe_debug)
- {
- printf ("->%s\n", symbols[i]->name);
- }
- pe_data_import_dll = (char*) (symbols[i]->name +
- sizeof ("__head_") - 1);
- break;
- }
- }
-
- pe_walk_relocs_of_symbol (&link_info, undef->root.string,
- make_import_fixup);
-
- /* let's differentiate it somehow from defined */
- undef->type = bfd_link_hash_defweak;
- /* we replace original name with __imp_ prefixed, this
- 1) may trash memory 2) leads to duplicate symbol generation.
- Still, IMHO it's better than having name poluted. */
- undef->root.string = sym->root.string;
- undef->u.def.value = sym->u.def.value;
- undef->u.def.section = sym->u.def.section;
+ bfd *b = sym->u.def.section->owner;
+ asymbol **symbols;
+ int nsyms, symsize, i;
+
+ if (link_info.pei386_auto_import == -1)
+ info_msg (_("Info: resolving %s by linking to %s (auto-import)\n"),
+ undef->root.string, buf);
+
+ symsize = bfd_get_symtab_upper_bound (b);
+ symbols = (asymbol **) xmalloc (symsize);
+ nsyms = bfd_canonicalize_symtab (b, symbols);
+
+ for (i = 0; i < nsyms; i++)
+ {
+ if (memcmp (symbols[i]->name, "__head_",
+ sizeof ("__head_") - 1))
+ continue;
+
+ if (pe_dll_extra_pe_debug)
+ printf ("->%s\n", symbols[i]->name);
+
+ pe_data_import_dll = (char*) (symbols[i]->name +
+ sizeof ("__head_") - 1);
+ break;
+ }
+
+ pe_walk_relocs_of_symbol (&link_info, undef->root.string,
+ make_import_fixup);
+
+ /* Let's differentiate it somehow from defined. */
+ undef->type = bfd_link_hash_defweak;
+ /* We replace original name with __imp_ prefixed, this
+ 1) may trash memory 2) leads to duplicate symbol generation.
+ Still, IMHO it's better than having name poluted. */
+ undef->root.string = sym->root.string;
+ undef->u.def.value = sym->u.def.value;
+ undef->u.def.section = sym->u.def.section;
}
}
}
}
-#endif /* DLL_SUPPORT */
-static boolean
-pr_sym (h, string)
- struct bfd_hash_entry *h;
- PTR string ATTRIBUTE_UNUSED;
+static bfd_boolean
+pr_sym (struct bfd_hash_entry *h, void *inf ATTRIBUTE_UNUSED)
{
if (pe_dll_extra_pe_debug)
- {
- printf("+%s\n",h->string);
- }
- return true;
+ printf ("+%s\n", h->string);
+
+ return TRUE;
}
+#endif /* DLL_SUPPORT */
static void
-gld_${EMULATION_NAME}_after_open ()
+gld_${EMULATION_NAME}_after_open (void)
{
-
+#ifdef DLL_SUPPORT
if (pe_dll_extra_pe_debug)
{
bfd *a;
struct bfd_link_hash_entry *sym;
+
printf ("%s()\n", __FUNCTION__);
- for (sym = link_info.hash->undefs; sym; sym=sym->next)
+ for (sym = link_info.hash->undefs; sym; sym=sym->und_next)
printf ("-%s\n", sym->root.string);
- bfd_hash_traverse (&link_info.hash->table, pr_sym,NULL);
+ bfd_hash_traverse (&link_info.hash->table, pr_sym, NULL);
for (a = link_info.input_bfds; a; a = a->link_next)
- {
- printf("*%s\n",a->filename);
- }
+ printf ("*%s\n",a->filename);
}
+#endif
/* Pass the wacky PE command line options into the output bfd.
FIXME: This should be done via a function, rather than by
@@ -1003,10 +954,15 @@ gld_${EMULATION_NAME}_after_open ()
if (pe_enable_stdcall_fixup) /* -1=warn or 1=disable */
pe_fixup_stdcalls ();
+ pe_process_import_defs (output_bfd, & link_info);
+
pe_find_data_imports ();
- pe_process_import_defs(output_bfd, &link_info);
+#if ! (defined (TARGET_IS_i386pe) || defined (TARGET_IS_armpe))
if (link_info.shared)
+#else
+ if (!link_info.relocatable)
+#endif
pe_dll_build_sections (output_bfd, &link_info);
#ifndef TARGET_IS_i386pe
@@ -1046,7 +1002,7 @@ gld_${EMULATION_NAME}_after_open ()
head/tail objects, causing an improper import table. We detect
those cases and rename the "other" import libraries to match
the one the head/tail come from, so that the linker will sort
- things nicely and produce a valid import table. */
+ things nicely and produce a valid import table. */
LANG_FOR_EACH_INPUT_STATEMENT (is)
{
@@ -1105,7 +1061,7 @@ gld_${EMULATION_NAME}_after_open ()
for (i = 0; i < nrelocs; i++)
{
- struct symbol_cache_entry *s;
+ struct bfd_symbol *s;
struct bfd_link_hash_entry * blhe;
bfd *other_bfd;
char *n;
@@ -1118,7 +1074,7 @@ gld_${EMULATION_NAME}_after_open ()
/* Thunk section with reloc to another bfd. */
blhe = bfd_link_hash_lookup (link_info.hash,
s->name,
- false, false, true);
+ FALSE, FALSE, TRUE);
if (blhe == NULL
|| blhe->type != bfd_link_hash_defined)
@@ -1151,6 +1107,7 @@ gld_${EMULATION_NAME}_after_open ()
int is_ms_arch = 0;
bfd *cur_arch = 0;
lang_input_statement_type *is2;
+ lang_input_statement_type *is3;
/* Careful - this is a shell script. Watch those dollar signs! */
/* Microsoft import libraries have every member named the same,
@@ -1165,21 +1122,59 @@ gld_${EMULATION_NAME}_after_open ()
{
if (is->the_bfd->my_archive)
{
+ char *pnt;
bfd *arch = is->the_bfd->my_archive;
+
if (cur_arch != arch)
{
cur_arch = arch;
is_ms_arch = 1;
- for (is2 = is;
- is2 && is2->the_bfd->my_archive == arch;
- is2 = (lang_input_statement_type *)is2->next)
+
+ for (is3 = is;
+ is3 && is3->the_bfd->my_archive == arch;
+ is3 = (lang_input_statement_type *) is3->next)
+ {
+ /* A MS dynamic import library can also contain static
+ members, so look for the first element with a .dll
+ extension, and use that for the remainder of the
+ comparisons. */
+ pnt = strrchr (is3->the_bfd->filename, '.');
+ if (pnt != NULL && strcmp (pnt, ".dll") == 0)
+ break;
+ }
+
+ if (is3 == NULL)
+ is_ms_arch = 0;
+ else
{
- if (strcmp (is->the_bfd->filename, is2->the_bfd->filename))
- is_ms_arch = 0;
+ /* OK, found one. Now look to see if the remaining
+ (dynamic import) members use the same name. */
+ for (is2 = is;
+ is2 && is2->the_bfd->my_archive == arch;
+ is2 = (lang_input_statement_type *) is2->next)
+ {
+ /* Skip static members, ie anything with a .obj
+ extension. */
+ pnt = strrchr (is2->the_bfd->filename, '.');
+ if (pnt != NULL && strcmp (pnt, ".obj") == 0)
+ continue;
+
+ if (strcmp (is3->the_bfd->filename,
+ is2->the_bfd->filename))
+ {
+ is_ms_arch = 0;
+ break;
+ }
+ }
}
}
- if (is_ms_arch)
+ /* This fragment might have come from an .obj file in a Microsoft
+ import, and not an actual import record. If this is the case,
+ then leave the filename alone. */
+ pnt = strrchr (is->the_bfd->filename, '.');
+
+ if (is_ms_arch && (strcmp (pnt, ".dll") == 0))
{
int idata2 = 0, reloc_count=0;
asection *sec;
@@ -1213,10 +1208,10 @@ gld_${EMULATION_NAME}_after_open ()
}
static void
-gld_${EMULATION_NAME}_before_allocation()
+gld_${EMULATION_NAME}_before_allocation (void)
{
#ifdef TARGET_IS_ppcpe
- /* Here we rummage through the found bfds to collect toc information */
+ /* Here we rummage through the found bfds to collect toc information. */
{
LANG_FOR_EACH_INPUT_STATEMENT (is)
{
@@ -1228,7 +1223,7 @@ gld_${EMULATION_NAME}_before_allocation()
}
}
- /* We have seen it all. Allocate it, and carry on */
+ /* We have seen it all. Allocate it, and carry on. */
ppc_allocate_toc_section (&link_info);
#endif /* TARGET_IS_ppcpe */
@@ -1238,7 +1233,7 @@ gld_${EMULATION_NAME}_before_allocation()
Here we rummage through the found bfds to collect glue
information. FIXME: should this be based on a command line
- option? krk@cygnus.com */
+ option? krk@cygnus.com. */
{
LANG_FOR_EACH_INPUT_STATEMENT (is)
{
@@ -1252,114 +1247,118 @@ gld_${EMULATION_NAME}_before_allocation()
}
}
- /* We have seen it all. Allocate it, and carry on */
+ /* We have seen it all. Allocate it, and carry on. */
bfd_arm_pe_allocate_interworking_sections (& link_info);
#endif /* TARGET_IS_armpe */
}
#ifdef DLL_SUPPORT
/* This is called when an input file isn't recognized as a BFD. We
- check here for .DEF files and pull them in automatically. */
+ check here for .DEF files and pull them in automatically. */
static int
-saw_option(char *option)
+saw_option (char *option)
{
int i;
- for (i=0; init[i].ptr; i++)
+
+ for (i = 0; init[i].ptr; i++)
if (strcmp (init[i].symbol, option) == 0)
return init[i].inited;
return 0;
}
#endif /* DLL_SUPPORT */
-static boolean
-gld_${EMULATION_NAME}_unrecognized_file(entry)
- lang_input_statement_type *entry ATTRIBUTE_UNUSED;
+static bfd_boolean
+gld_${EMULATION_NAME}_unrecognized_file (lang_input_statement_type *entry ATTRIBUTE_UNUSED)
{
#ifdef DLL_SUPPORT
const char *ext = entry->filename + strlen (entry->filename) - 4;
if (strcmp (ext, ".def") == 0 || strcmp (ext, ".DEF") == 0)
- {
- if (pe_def_file == 0)
- pe_def_file = def_file_empty ();
- def_file_parse (entry->filename, pe_def_file);
- if (pe_def_file)
{
- int i, buflen=0, len;
- char *buf;
- for (i=0; i<pe_def_file->num_exports; i++)
- {
- len = strlen(pe_def_file->exports[i].internal_name);
- if (buflen < len+2)
- buflen = len+2;
- }
- buf = (char *) xmalloc (buflen);
- for (i=0; i<pe_def_file->num_exports; i++)
+ if (pe_def_file == 0)
+ pe_def_file = def_file_empty ();
+
+ def_file_parse (entry->filename, pe_def_file);
+
+ if (pe_def_file)
{
- struct bfd_link_hash_entry *h;
- sprintf(buf, "_%s", pe_def_file->exports[i].internal_name);
+ int i, buflen=0, len;
+ char *buf;
- h = bfd_link_hash_lookup (link_info.hash, buf, true, true, true);
- if (h == (struct bfd_link_hash_entry *) NULL)
- einfo (_("%P%F: bfd_link_hash_lookup failed: %E\n"));
- if (h->type == bfd_link_hash_new)
+ for (i = 0; i < pe_def_file->num_exports; i++)
{
- h->type = bfd_link_hash_undefined;
- h->u.undef.abfd = NULL;
- bfd_link_add_undef (link_info.hash, h);
+ len = strlen (pe_def_file->exports[i].internal_name);
+ if (buflen < len + 2)
+ buflen = len + 2;
}
- }
- free (buf);
- /* def_file_print (stdout, pe_def_file); */
- if (pe_def_file->is_dll == 1)
- link_info.shared = 1;
+ buf = (char *) xmalloc (buflen);
- if (pe_def_file->base_address != (bfd_vma)(-1))
- {
- pe.ImageBase =
- pe_data (output_bfd)->pe_opthdr.ImageBase =
- init[IMAGEBASEOFF].value = pe_def_file->base_address;
- init[IMAGEBASEOFF].inited = 1;
- if (image_base_statement)
- image_base_statement->exp =
- exp_assop ('=', "__image_base__", exp_intop (pe.ImageBase));
- }
+ for (i = 0; i < pe_def_file->num_exports; i++)
+ {
+ struct bfd_link_hash_entry *h;
+
+ sprintf (buf, "_%s", pe_def_file->exports[i].internal_name);
+
+ h = bfd_link_hash_lookup (link_info.hash, buf, TRUE, TRUE, TRUE);
+ if (h == (struct bfd_link_hash_entry *) NULL)
+ einfo (_("%P%F: bfd_link_hash_lookup failed: %E\n"));
+ if (h->type == bfd_link_hash_new)
+ {
+ h->type = bfd_link_hash_undefined;
+ h->u.undef.abfd = NULL;
+ bfd_link_add_undef (link_info.hash, h);
+ }
+ }
+ free (buf);
+
+ /* def_file_print (stdout, pe_def_file); */
+ if (pe_def_file->is_dll == 1)
+ link_info.shared = 1;
+
+ if (pe_def_file->base_address != (bfd_vma)(-1))
+ {
+ pe.ImageBase =
+ pe_data (output_bfd)->pe_opthdr.ImageBase =
+ init[IMAGEBASEOFF].value = pe_def_file->base_address;
+ init[IMAGEBASEOFF].inited = 1;
+ if (image_base_statement)
+ image_base_statement->exp =
+ exp_assop ('=', "__image_base__", exp_intop (pe.ImageBase));
+ }
#if 0
- /* Not sure if these *should* be set */
- if (pe_def_file->version_major != -1)
- {
- pe.MajorImageVersion = pe_def_file->version_major;
- pe.MinorImageVersion = pe_def_file->version_minor;
- }
+ /* Not sure if these *should* be set. */
+ if (pe_def_file->version_major != -1)
+ {
+ pe.MajorImageVersion = pe_def_file->version_major;
+ pe.MinorImageVersion = pe_def_file->version_minor;
+ }
#endif
- if (pe_def_file->stack_reserve != -1
- && ! saw_option ("__size_of_stack_reserve__"))
- {
- pe.SizeOfStackReserve = pe_def_file->stack_reserve;
- if (pe_def_file->stack_commit != -1)
- pe.SizeOfStackCommit = pe_def_file->stack_commit;
- }
- if (pe_def_file->heap_reserve != -1
- && ! saw_option ("__size_of_heap_reserve__"))
- {
- pe.SizeOfHeapReserve = pe_def_file->heap_reserve;
- if (pe_def_file->heap_commit != -1)
- pe.SizeOfHeapCommit = pe_def_file->heap_commit;
- }
- return true;
+ if (pe_def_file->stack_reserve != -1
+ && ! saw_option ("__size_of_stack_reserve__"))
+ {
+ pe.SizeOfStackReserve = pe_def_file->stack_reserve;
+ if (pe_def_file->stack_commit != -1)
+ pe.SizeOfStackCommit = pe_def_file->stack_commit;
+ }
+ if (pe_def_file->heap_reserve != -1
+ && ! saw_option ("__size_of_heap_reserve__"))
+ {
+ pe.SizeOfHeapReserve = pe_def_file->heap_reserve;
+ if (pe_def_file->heap_commit != -1)
+ pe.SizeOfHeapCommit = pe_def_file->heap_commit;
+ }
+ return TRUE;
+ }
}
- }
#endif
- return false;
-
+ return FALSE;
}
-static boolean
-gld_${EMULATION_NAME}_recognized_file(entry)
- lang_input_statement_type *entry ATTRIBUTE_UNUSED;
+static bfd_boolean
+gld_${EMULATION_NAME}_recognized_file (lang_input_statement_type *entry ATTRIBUTE_UNUSED)
{
#ifdef DLL_SUPPORT
#ifdef TARGET_IS_i386pe
@@ -1376,23 +1375,31 @@ gld_${EMULATION_NAME}_recognized_file(entry)
#endif
if (bfd_get_format (entry->the_bfd) == bfd_object)
{
- const char *ext = entry->filename + strlen (entry->filename) - 4;
+ char fbuf[LD_PATHMAX + 1];
+ const char *ext;
+
+ if (REALPATH (entry->filename, fbuf) == NULL)
+ strncpy (fbuf, entry->filename, sizeof (fbuf));
+
+ ext = fbuf + strlen (fbuf) - 4;
+
if (strcmp (ext, ".dll") == 0 || strcmp (ext, ".DLL") == 0)
- return pe_implied_import_dll (entry->filename);
+ return pe_implied_import_dll (fbuf);
}
#endif
- return false;
+ return FALSE;
}
static void
-gld_${EMULATION_NAME}_finish ()
+gld_${EMULATION_NAME}_finish (void)
{
#if defined(TARGET_IS_armpe) || defined(TARGET_IS_arm_epoc_pe)
struct bfd_link_hash_entry * h;
if (thumb_entry_symbol != NULL)
{
- h = bfd_link_hash_lookup (link_info.hash, thumb_entry_symbol, false, false, true);
+ h = bfd_link_hash_lookup (link_info.hash, thumb_entry_symbol,
+ FALSE, FALSE, TRUE);
if (h != (struct bfd_link_hash_entry *) NULL
&& (h->type == bfd_link_hash_defined
@@ -1429,7 +1436,11 @@ gld_${EMULATION_NAME}_finish ()
#endif /* defined(TARGET_IS_armpe) || defined(TARGET_IS_arm_epoc_pe) */
#ifdef DLL_SUPPORT
- if (link_info.shared)
+ if (link_info.shared
+#if !defined(TARGET_IS_shpe) && !defined(TARGET_IS_mipspe)
+ || (!link_info.relocatable && pe_def_file->num_exports != 0)
+#endif
+ )
{
pe_dll_fill_sections (output_bfd, &link_info);
if (pe_implib_filename)
@@ -1447,9 +1458,10 @@ gld_${EMULATION_NAME}_finish ()
pe_dll_generate_def_file (pe_out_def_filename);
#endif /* DLL_SUPPORT */
- /* I don't know where .idata gets set as code, but it shouldn't be */
+ /* I don't know where .idata gets set as code, but it shouldn't be. */
{
asection *asec = bfd_get_section_by_name (output_bfd, ".idata");
+
if (asec)
{
asec->flags &= ~SEC_CODE;
@@ -1463,8 +1475,7 @@ gld_${EMULATION_NAME}_finish ()
Used by place_orphan. */
static asection *
-output_prev_sec_find (os)
- lang_output_section_statement_type *os;
+output_prev_sec_find (lang_output_section_statement_type *os)
{
asection *s = (asection *) NULL;
lang_statement_union_type *u;
@@ -1505,11 +1516,8 @@ struct orphan_save
lang_statement_union_type **stmt;
};
-/*ARGSUSED*/
-static boolean
-gld_${EMULATION_NAME}_place_orphan (file, s)
- lang_input_statement_type *file;
- asection *s;
+static bfd_boolean
+gld_${EMULATION_NAME}_place_orphan (lang_input_statement_type *file, asection *s)
{
const char *secname;
char *hold_section_name;
@@ -1521,9 +1529,8 @@ gld_${EMULATION_NAME}_place_orphan (file, s)
secname = bfd_get_section_name (s->owner, s);
/* Look through the script to see where to place this section. */
-
hold_section_name = xstrdup (secname);
- if (!link_info.relocateable)
+ if (!link_info.relocatable)
{
dollar = strchr (hold_section_name, '$');
if (dollar != NULL)
@@ -1614,7 +1621,7 @@ gld_${EMULATION_NAME}_place_orphan (file, s)
/* If the name of the section is representable in C, then create
symbols to mark the start and the end of the section. */
for (ps = outsecname; *ps != '\0'; ps++)
- if (! isalnum ((unsigned char) *ps) && *ps != '_')
+ if (! ISALNUM ((unsigned char) *ps) && *ps != '_')
break;
if (*ps == '\0')
{
@@ -1629,7 +1636,7 @@ gld_${EMULATION_NAME}_place_orphan (file, s)
}
}
- if (link_info.relocateable || (s->flags & (SEC_LOAD | SEC_ALLOC)) == 0)
+ if (link_info.relocatable || (s->flags & (SEC_LOAD | SEC_ALLOC)) == 0)
address = exp_intop ((bfd_vma) 0);
else
{
@@ -1640,7 +1647,6 @@ gld_${EMULATION_NAME}_place_orphan (file, s)
}
os = lang_enter_output_section_statement (outsecname, address, 0,
- (bfd_vma) 0,
(etree_type *) NULL,
(etree_type *) NULL,
(etree_type *) NULL);
@@ -1655,8 +1661,8 @@ gld_${EMULATION_NAME}_place_orphan (file, s)
{
char *symname;
- /* lang_leave_ouput_section_statement resets stat_ptr. Put
- stat_ptr back where we want it. */
+ /* lang_leave_ouput_section_statement resets stat_ptr.
+ Put stat_ptr back where we want it. */
if (place != NULL)
stat_ptr = &add;
@@ -1748,12 +1754,11 @@ gld_${EMULATION_NAME}_place_orphan (file, s)
if (dollar != NULL)
{
- boolean found_dollar;
+ bfd_boolean found_dollar;
/* The section name has a '$'. Sort it with the other '$'
sections. */
-
- found_dollar = false;
+ found_dollar = FALSE;
for ( ; *pl != NULL; pl = &(*pl)->header.next)
{
lang_input_section_type *ls;
@@ -1772,7 +1777,7 @@ gld_${EMULATION_NAME}_place_orphan (file, s)
}
else
{
- found_dollar = true;
+ found_dollar = TRUE;
if (strcmp (secname, lname) < 0)
break;
}
@@ -1788,20 +1793,19 @@ gld_${EMULATION_NAME}_place_orphan (file, s)
free (hold_section_name);
- return true;
+ return TRUE;
}
-static boolean
-gld_${EMULATION_NAME}_open_dynamic_archive (arch, search, entry)
- const char * arch ATTRIBUTE_UNUSED;
- search_dirs_type * search;
- lang_input_statement_type * entry;
+static bfd_boolean
+gld_${EMULATION_NAME}_open_dynamic_archive
+ (const char *arch ATTRIBUTE_UNUSED, search_dirs_type *search,
+ lang_input_statement_type *entry)
{
const char * filename;
char * string;
if (! entry->is_archive)
- return false;
+ return FALSE;
filename = entry->filename;
@@ -1813,65 +1817,63 @@ gld_${EMULATION_NAME}_open_dynamic_archive (arch, search, entry)
#endif
+ 1);
- /* Try "libfoo.dll.a" first (preferred explicit import library for dll's */
+ /* Try "libfoo.dll.a" first (preferred explicit import library for dll's. */
sprintf (string, "%s/lib%s.dll.a", search->name, filename);
if (! ldfile_try_open_bfd (string, entry))
{
- /* Try "foo.dll.a" next (alternate explicit import library for dll's */
+ /* Try "foo.dll.a" next (alternate explicit import library for dll's. */
sprintf (string, "%s/%s.dll.a", search->name, filename);
if (! ldfile_try_open_bfd (string, entry))
{
-/*
- Try libfoo.a next. Normally, this would be interpreted as a static
- library, but it *could* be an import library. For backwards compatibility,
- libfoo.a needs to ==precede== libfoo.dll and foo.dll in the search,
- or sometimes errors occur when building legacy packages.
-
- Putting libfoo.a here means that in a failure case (i.e. the library
- -lfoo is not found) we will search for libfoo.a twice before
- giving up -- once here, and once when searching for a "static" lib.
- for a "static" lib.
-*/
+ /* Try libfoo.a next. Normally, this would be interpreted as a static
+ library, but it *could* be an import library. For backwards compatibility,
+ libfoo.a needs to ==precede== libfoo.dll and foo.dll in the search,
+ or sometimes errors occur when building legacy packages.
+
+ Putting libfoo.a here means that in a failure case (i.e. the library
+ -lfoo is not found) we will search for libfoo.a twice before
+ giving up -- once here, and once when searching for a "static" lib.
+ for a "static" lib. */
/* Try "libfoo.a" (import lib, or static lib, but must
- take precedence over dll's) */
+ take precedence over dll's). */
sprintf (string, "%s/lib%s.a", search->name, filename);
if (! ldfile_try_open_bfd (string, entry))
{
#ifdef DLL_SUPPORT
if (pe_dll_search_prefix)
{
- /* Try "<prefix>foo.dll" (preferred dll name, if specified) */
+ /* Try "<prefix>foo.dll" (preferred dll name, if specified). */
sprintf (string, "%s/%s%s.dll", search->name, pe_dll_search_prefix, filename);
if (! ldfile_try_open_bfd (string, entry))
{
- /* Try "libfoo.dll" (default preferred dll name) */
+ /* Try "libfoo.dll" (default preferred dll name). */
sprintf (string, "%s/lib%s.dll", search->name, filename);
if (! ldfile_try_open_bfd (string, entry))
{
- /* Finally, try "foo.dll" (alternate dll name) */
+ /* Finally, try "foo.dll" (alternate dll name). */
sprintf (string, "%s/%s.dll", search->name, filename);
if (! ldfile_try_open_bfd (string, entry))
{
free (string);
- return false;
+ return FALSE;
}
}
}
}
- else /* pe_dll_search_prefix not specified */
+ else /* pe_dll_search_prefix not specified. */
#endif
{
- /* Try "libfoo.dll" (preferred dll name) */
+ /* Try "libfoo.dll" (preferred dll name). */
sprintf (string, "%s/lib%s.dll", search->name, filename);
if (! ldfile_try_open_bfd (string, entry))
{
- /* Finally, try "foo.dll" (alternate dll name) */
+ /* Finally, try "foo.dll" (alternate dll name). */
sprintf (string, "%s/%s.dll", search->name, filename);
if (! ldfile_try_open_bfd (string, entry))
{
free (string);
- return false;
+ return FALSE;
}
}
}
@@ -1881,20 +1883,18 @@ gld_${EMULATION_NAME}_open_dynamic_archive (arch, search, entry)
entry->filename = string;
- return true;
+ return TRUE;
}
static int
-gld_${EMULATION_NAME}_find_potential_libraries (name, entry)
- char * name;
- lang_input_statement_type * entry;
+gld_${EMULATION_NAME}_find_potential_libraries
+ (char *name, lang_input_statement_type *entry)
{
return ldfile_open_file_search (name, entry, "", ".lib");
}
static char *
-gld_${EMULATION_NAME}_get_script(isfile)
- int *isfile;
+gld_${EMULATION_NAME}_get_script (int *isfile)
EOF
# Scripts compiled in.
# sed commands to quote an ld script as a C string.
@@ -1904,19 +1904,19 @@ cat >>e${EMULATION_NAME}.c <<EOF
{
*isfile = 0;
- if (link_info.relocateable == true && config.build_constructors == true)
+ if (link_info.relocatable && config.build_constructors)
return
EOF
-sed $sc ldscripts/${EMULATION_NAME}.xu >> e${EMULATION_NAME}.c
-echo ' ; else if (link_info.relocateable == true) return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.xr >> e${EMULATION_NAME}.c
-echo ' ; else if (!config.text_read_only) return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.xbn >> e${EMULATION_NAME}.c
-echo ' ; else if (!config.magic_demand_paged) return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.xn >> e${EMULATION_NAME}.c
-echo ' ; else return' >> e${EMULATION_NAME}.c
-sed $sc ldscripts/${EMULATION_NAME}.x >> e${EMULATION_NAME}.c
-echo '; }' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xu >> e${EMULATION_NAME}.c
+echo ' ; else if (link_info.relocatable) return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xr >> e${EMULATION_NAME}.c
+echo ' ; else if (!config.text_read_only) return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xbn >> e${EMULATION_NAME}.c
+echo ' ; else if (!config.magic_demand_paged) return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.xn >> e${EMULATION_NAME}.c
+echo ' ; else return' >> e${EMULATION_NAME}.c
+sed $sc ldscripts/${EMULATION_NAME}.x >> e${EMULATION_NAME}.c
+echo '; }' >> e${EMULATION_NAME}.c
cat >>e${EMULATION_NAME}.c <<EOF
@@ -1935,16 +1935,18 @@ struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
gld_${EMULATION_NAME}_get_script,
"${EMULATION_NAME}",
"${OUTPUT_FORMAT}",
- gld_${EMULATION_NAME}_finish, /* finish */
- NULL, /* create output section statements */
+ gld_${EMULATION_NAME}_finish,
+ NULL, /* Create output section statements. */
gld_${EMULATION_NAME}_open_dynamic_archive,
gld_${EMULATION_NAME}_place_orphan,
gld_${EMULATION_NAME}_set_symbols,
- gld_${EMULATION_NAME}_parse_args,
+ NULL, /* parse_args */
+ gld${EMULATION_NAME}_add_options,
+ gld${EMULATION_NAME}_handle_option,
gld_${EMULATION_NAME}_unrecognized_file,
gld_${EMULATION_NAME}_list_options,
gld_${EMULATION_NAME}_recognized_file,
gld_${EMULATION_NAME}_find_potential_libraries,
- NULL /* new_vers_pattern */
+ NULL /* new_vers_pattern. */
};
EOF
diff --git a/contrib/binutils/ld/emultempl/ppc64elf.em b/contrib/binutils/ld/emultempl/ppc64elf.em
index cf6918e..4f408a9 100644
--- a/contrib/binutils/ld/emultempl/ppc64elf.em
+++ b/contrib/binutils/ld/emultempl/ppc64elf.em
@@ -1,5 +1,5 @@
# This shell script emits a C file. -*- C -*-
-# Copyright 2002 Free Software Foundation, Inc.
+# Copyright 2002, 2003, 2004 Free Software Foundation, Inc.
#
# This file is part of GLD, the Gnu Linker.
#
@@ -25,10 +25,12 @@ cat >>e${EMULATION_NAME}.c <<EOF
#include "ldctor.h"
#include "libbfd.h"
+#include "elf-bfd.h"
#include "elf64-ppc.h"
/* Fake input file for stubs. */
static lang_input_statement_type *stub_file;
+static int stub_added = 0;
/* Whether we need to call ppc_layout_sections_again. */
static int need_laying_out = 0;
@@ -41,21 +43,30 @@ static bfd_signed_vma group_size = 1;
/* Whether to add ".foo" entries for each "foo" in a version script. */
static int dotsyms = 1;
-static void ppc_create_output_section_statements PARAMS ((void));
-static void ppc_after_open PARAMS ((void));
-static asection *ppc_add_stub_section PARAMS ((const char *, asection *));
-static void ppc_layout_sections_again PARAMS ((void));
-static void gld${EMULATION_NAME}_after_allocation PARAMS ((void));
-static void build_section_lists PARAMS ((lang_statement_union_type *));
-static struct bfd_elf_version_expr *gld${EMULATION_NAME}_new_vers_pattern
- PARAMS ((struct bfd_elf_version_expr *));
+/* Whether to run tls optimization. */
+static int notlsopt = 0;
+
+/* Whether to emit symbols for stubs. */
+static int emit_stub_syms = 0;
+
+static asection *toc_section = 0;
+
/* This is called before the input files are opened. We create a new
fake input file to hold the stub sections. */
static void
-ppc_create_output_section_statements ()
+ppc_create_output_section_statements (void)
{
+ extern const bfd_target bfd_elf64_powerpc_vec;
+ extern const bfd_target bfd_elf64_powerpcle_vec;
+
+ if (link_info.hash->creator != &bfd_elf64_powerpc_vec
+ && link_info.hash->creator != &bfd_elf64_powerpcle_vec)
+ return;
+
+ link_info.wrap_char = '.';
+
stub_file = lang_add_input_file ("linker stubs",
lang_input_file_is_fake_enum,
NULL);
@@ -70,10 +81,11 @@ ppc_create_output_section_statements ()
}
ldlang_add_file (stub_file);
+ ppc64_elf_init_stub_bfd (stub_file->the_bfd, &link_info);
}
static void
-ppc_after_open ()
+ppc_after_open (void)
{
if (!ppc64_elf_mark_entry_syms (&link_info))
{
@@ -84,6 +96,39 @@ ppc_after_open ()
gld${EMULATION_NAME}_after_open ();
}
+static void
+ppc_before_allocation (void)
+{
+ if (stub_file != NULL)
+ {
+ if (!ppc64_elf_edit_opd (output_bfd, &link_info))
+ {
+ einfo ("%X%P: can not edit opd %E\n");
+ return;
+ }
+
+ if (ppc64_elf_tls_setup (output_bfd, &link_info) && !notlsopt)
+ {
+ /* Size the sections. This is premature, but we want to know the
+ TLS segment layout so that certain optimizations can be done. */
+ lang_size_sections (stat_ptr->head, abs_output_section,
+ &stat_ptr->head, 0, 0, NULL, TRUE);
+
+ if (!ppc64_elf_tls_optimize (output_bfd, &link_info))
+ {
+ einfo ("%X%P: TLS problem %E\n");
+ return;
+ }
+
+ /* We must not cache anything from the preliminary sizing. */
+ elf_tdata (output_bfd)->program_header_size = 0;
+ lang_reset_memory_regions ();
+ }
+ }
+
+ gld${EMULATION_NAME}_before_allocation ();
+}
+
struct hook_stub_info
{
lang_statement_list_type add;
@@ -92,16 +137,11 @@ struct hook_stub_info
/* Traverse the linker tree to find the spot where the stub goes. */
-static boolean hook_in_stub
- PARAMS ((struct hook_stub_info *, lang_statement_union_type **));
-
-static boolean
-hook_in_stub (info, lp)
- struct hook_stub_info *info;
- lang_statement_union_type **lp;
+static bfd_boolean
+hook_in_stub (struct hook_stub_info *info, lang_statement_union_type **lp)
{
lang_statement_union_type *l;
- boolean ret;
+ bfd_boolean ret;
for (; (l = *lp) != NULL; lp = &l->header.next)
{
@@ -139,7 +179,7 @@ hook_in_stub (info, lp)
before its associated input section. */
*lp = info->add.head;
*(info->add.tail) = l;
- return true;
+ return TRUE;
}
break;
@@ -160,7 +200,7 @@ hook_in_stub (info, lp)
break;
}
}
- return false;
+ return FALSE;
}
@@ -170,9 +210,7 @@ hook_in_stub (info, lp)
immediately before INPUT_SECTION. */
static asection *
-ppc_add_stub_section (stub_sec_name, input_section)
- const char *stub_sec_name;
- asection *input_section;
+ppc_add_stub_section (const char *stub_sec_name, asection *input_section)
{
asection *stub_sec;
flagword flags;
@@ -201,6 +239,7 @@ ppc_add_stub_section (stub_sec_name, input_section)
if (info.add.head == NULL)
goto err_ret;
+ stub_added = 1;
if (hook_in_stub (&info, &os->children.head))
return stub_sec;
@@ -213,7 +252,7 @@ ppc_add_stub_section (stub_sec_name, input_section)
/* Another call-back for ppc64_elf_size_stubs. */
static void
-ppc_layout_sections_again ()
+ppc_layout_sections_again (void)
{
/* If we have changed sizes of the stub sections, then we need
to recalculate all the section offsets. This may mean we need to
@@ -224,38 +263,47 @@ ppc_layout_sections_again ()
/* Resize the sections. */
lang_size_sections (stat_ptr->head, abs_output_section,
- &stat_ptr->head, 0, (bfd_vma) 0, NULL);
+ &stat_ptr->head, 0, 0, NULL, TRUE);
/* Recalculate TOC base. */
ldemul_after_allocation ();
/* Do the assignments again. */
- lang_do_assignments (stat_ptr->head, abs_output_section,
- (fill_type *) 0, (bfd_vma) 0);
+ lang_do_assignments (stat_ptr->head, abs_output_section, NULL, 0);
}
/* Call the back-end function to set TOC base after we have placed all
the sections. */
static void
-gld${EMULATION_NAME}_after_allocation ()
+gld${EMULATION_NAME}_after_allocation (void)
{
- if (!link_info.relocateable)
+ if (!link_info.relocatable)
_bfd_set_gp_value (output_bfd, ppc64_elf_toc (output_bfd));
}
static void
-build_section_lists (statement)
- lang_statement_union_type *statement;
+build_toc_list (lang_statement_union_type *statement)
+{
+ if (statement->header.type == lang_input_section_enum
+ && !statement->input_section.ifile->just_syms_flag
+ && statement->input_section.section->output_section == toc_section)
+ ppc64_elf_next_toc_section (&link_info, statement->input_section.section);
+}
+
+
+static void
+build_section_lists (lang_statement_union_type *statement)
{
if (statement->header.type == lang_input_section_enum
&& !statement->input_section.ifile->just_syms_flag
&& statement->input_section.section->output_section != NULL
&& statement->input_section.section->output_section->owner == output_bfd)
{
- ppc64_elf_next_input_section (&link_info,
- statement->input_section.section);
+ if (!ppc64_elf_next_input_section (&link_info,
+ statement->input_section.section))
+ einfo ("%X%P: can not size stub section: %E\n");
}
}
@@ -263,58 +311,75 @@ build_section_lists (statement)
/* Final emulation specific call. */
static void
-gld${EMULATION_NAME}_finish ()
+gld${EMULATION_NAME}_finish (void)
{
- int ret;
-
/* e_entry on PowerPC64 points to the function descriptor for
_start. If _start is missing, default to the first function
descriptor in the .opd section. */
entry_section = ".opd";
- /* If generating a relocatable output file, then we don't have any
- stubs. */
- if (link_info.relocateable)
- return;
-
- /* bfd_elf64_discard_info just plays with debugging sections,
+ /* bfd_elf_discard_info just plays with debugging sections,
ie. doesn't affect any code, so we can delay resizing the
sections. It's likely we'll resize everything in the process of
adding stubs. */
- if (bfd_elf${ELFSIZE}_discard_info (output_bfd, &link_info))
+ if (bfd_elf_discard_info (output_bfd, &link_info))
need_laying_out = 1;
- ret = ppc64_elf_setup_section_lists (output_bfd, &link_info);
- if (ret != 0)
+ /* If generating a relocatable output file, then we don't have any
+ stubs. */
+ if (stub_file != NULL && !link_info.relocatable)
{
- if (ret < 0)
+ int ret = ppc64_elf_setup_section_lists (output_bfd, &link_info);
+ if (ret != 0)
{
- einfo ("%X%P: can not size stub section: %E\n");
- return;
- }
+ if (ret < 0)
+ {
+ einfo ("%X%P: can not size stub section: %E\n");
+ return;
+ }
- lang_for_each_statement (build_section_lists);
+ toc_section = bfd_get_section_by_name (output_bfd, ".got");
+ if (toc_section != NULL)
+ lang_for_each_statement (build_toc_list);
- /* Call into the BFD backend to do the real work. */
- if (!ppc64_elf_size_stubs (output_bfd,
- stub_file->the_bfd,
- &link_info,
- group_size,
- &ppc_add_stub_section,
- &ppc_layout_sections_again))
- {
- einfo ("%X%P: can not size stub section: %E\n");
- return;
+ ppc64_elf_reinit_toc (output_bfd, &link_info);
+
+ lang_for_each_statement (build_section_lists);
+
+ /* Call into the BFD backend to do the real work. */
+ if (!ppc64_elf_size_stubs (output_bfd,
+ &link_info,
+ group_size,
+ &ppc_add_stub_section,
+ &ppc_layout_sections_again))
+ {
+ einfo ("%X%P: can not size stub section: %E\n");
+ return;
+ }
}
}
if (need_laying_out)
ppc_layout_sections_again ();
- if (stub_file->the_bfd->sections != NULL)
+ if (stub_added)
{
- if (!ppc64_elf_build_stubs (&link_info))
+ char *msg = NULL;
+ char *line, *endline;
+
+ if (!ppc64_elf_build_stubs (emit_stub_syms, &link_info,
+ config.stats ? &msg : NULL))
einfo ("%X%P: can not build stubs: %E\n");
+
+ for (line = msg; line != NULL; line = endline)
+ {
+ endline = strchr (line, '\n');
+ if (endline != NULL)
+ *endline++ = '\0';
+ fprintf (stderr, "%s: %s\n", program_name, line);
+ }
+ if (msg != NULL)
+ free (msg);
}
}
@@ -337,55 +402,24 @@ gld${EMULATION_NAME}_finish ()
exported. Lack of an exported function code sym may cause a
definition to be pulled in from a static library. */
-struct bfd_elf_version_expr *
-gld${EMULATION_NAME}_new_vers_pattern (entry)
- struct bfd_elf_version_expr *entry;
+static struct bfd_elf_version_expr *
+gld${EMULATION_NAME}_new_vers_pattern (struct bfd_elf_version_expr *entry)
{
struct bfd_elf_version_expr *dot_entry;
- struct bfd_elf_version_expr *next;
unsigned int len;
char *dot_pat;
- if (!dotsyms || entry->pattern[0] == '*')
+ if (!dotsyms || entry->pattern[0] == '*' || entry->pattern[0] == '.')
return entry;
- /* Is the script adding ".foo" explicitly? */
- if (entry->pattern[0] == '.')
- {
- /* We may have added this pattern automatically. Don't add it
- again. Quadratic behaviour here is acceptable as the list
- may be traversed for each input bfd symbol. */
- for (next = entry->next; next != NULL; next = next->next)
- {
- if (strcmp (next->pattern, entry->pattern) == 0
- && next->match == entry->match)
- {
- next = entry->next;
- free ((char *) entry->pattern);
- free (entry);
- return next;
- }
- }
- return entry;
- }
-
- /* Don't add ".foo" if the script has already done so. */
- for (next = entry->next; next != NULL; next = next->next)
- {
- if (next->pattern[0] == '.'
- && strcmp (next->pattern + 1, entry->pattern) == 0
- && next->match == entry->match)
- return entry;
- }
-
- dot_entry = (struct bfd_elf_version_expr *) xmalloc (sizeof *dot_entry);
+ dot_entry = xmalloc (sizeof *dot_entry);
+ *dot_entry = *entry;
dot_entry->next = entry;
len = strlen (entry->pattern) + 2;
dot_pat = xmalloc (len);
dot_pat[0] = '.';
memcpy (dot_pat + 1, entry->pattern, len - 1);
dot_entry->pattern = dot_pat;
- dot_entry->match = entry->match;
return dot_entry;
}
@@ -393,23 +427,16 @@ gld${EMULATION_NAME}_new_vers_pattern (entry)
/* Avoid processing the fake stub_file in vercheck, stat_needed and
check_needed routines. */
-static void ppc_for_each_input_file_wrapper
- PARAMS ((lang_input_statement_type *));
-static void ppc_lang_for_each_input_file
- PARAMS ((void (*) (lang_input_statement_type *)));
+static void (*real_func) (lang_input_statement_type *);
-static void (*real_func) PARAMS ((lang_input_statement_type *));
-
-static void ppc_for_each_input_file_wrapper (l)
- lang_input_statement_type *l;
+static void ppc_for_each_input_file_wrapper (lang_input_statement_type *l)
{
if (l != stub_file)
(*real_func) (l);
}
static void
-ppc_lang_for_each_input_file (func)
- void (*func) PARAMS ((lang_input_statement_type *));
+ppc_lang_for_each_input_file (void (*func) (lang_input_statement_type *))
{
real_func = func;
lang_for_each_input_file (&ppc_for_each_input_file_wrapper);
@@ -424,19 +451,18 @@ EOF
#
PARSE_AND_LIST_PROLOGUE='
#define OPTION_STUBGROUP_SIZE 301
-#define OPTION_DOTSYMS (OPTION_STUBGROUP_SIZE + 1)
+#define OPTION_STUBSYMS (OPTION_STUBGROUP_SIZE + 1)
+#define OPTION_DOTSYMS (OPTION_STUBSYMS + 1)
#define OPTION_NO_DOTSYMS (OPTION_DOTSYMS + 1)
+#define OPTION_NO_TLS_OPT (OPTION_NO_DOTSYMS + 1)
'
-# The options are repeated below so that no abbreviations are allowed.
-# Otherwise -s matches stub-group-size
PARSE_AND_LIST_LONGOPTS='
{ "stub-group-size", required_argument, NULL, OPTION_STUBGROUP_SIZE },
- { "stub-group-size", required_argument, NULL, OPTION_STUBGROUP_SIZE },
+ { "emit-stub-syms", no_argument, NULL, OPTION_STUBSYMS },
{ "dotsyms", no_argument, NULL, OPTION_DOTSYMS },
- { "dotsyms", no_argument, NULL, OPTION_DOTSYMS },
- { "no-dotsyms", no_argument, NULL, OPTION_NO_DOTSYMS },
{ "no-dotsyms", no_argument, NULL, OPTION_NO_DOTSYMS },
+ { "no-tls-optimize", no_argument, NULL, OPTION_NO_TLS_OPT },
'
PARSE_AND_LIST_OPTIONS='
@@ -450,6 +476,9 @@ PARSE_AND_LIST_OPTIONS='
the linker should choose suitable defaults.\n"
));
fprintf (file, _("\
+ --emit-stub-syms Label linker stubs with a symbol.\n"
+ ));
+ fprintf (file, _("\
--dotsyms For every version pattern \"foo\" in a version script,\n\
add \".foo\" so that function code symbols are\n\
treated the same as function descriptor symbols.\n\
@@ -458,6 +487,9 @@ PARSE_AND_LIST_OPTIONS='
fprintf (file, _("\
--no-dotsyms Don'\''t do anything special in version scripts.\n"
));
+ fprintf (file, _("\
+ --no-tls-optimize Don'\''t try to optimize TLS accesses.\n"
+ ));
'
PARSE_AND_LIST_ARGS_CASES='
@@ -470,22 +502,27 @@ PARSE_AND_LIST_ARGS_CASES='
}
break;
+ case OPTION_STUBSYMS:
+ emit_stub_syms = 1;
+ break;
+
case OPTION_DOTSYMS:
- {
- dotsyms = 1;
- }
+ dotsyms = 1;
break;
case OPTION_NO_DOTSYMS:
- {
- dotsyms = 0;
- }
+ dotsyms = 0;
+ break;
+
+ case OPTION_NO_TLS_OPT:
+ notlsopt = 1;
break;
'
# Put these extra ppc64elf routines in ld_${EMULATION_NAME}_emulation
#
LDEMUL_AFTER_OPEN=ppc_after_open
+LDEMUL_BEFORE_ALLOCATION=ppc_before_allocation
LDEMUL_AFTER_ALLOCATION=gld${EMULATION_NAME}_after_allocation
LDEMUL_FINISH=gld${EMULATION_NAME}_finish
LDEMUL_CREATE_OUTPUT_SECTION_STATEMENTS=ppc_create_output_section_statements
diff --git a/contrib/binutils/ld/emultempl/sunos.em b/contrib/binutils/ld/emultempl/sunos.em
index 64e5ea5..358bc9a 100644
--- a/contrib/binutils/ld/emultempl/sunos.em
+++ b/contrib/binutils/ld/emultempl/sunos.em
@@ -1,6 +1,6 @@
# This shell script emits a C file. -*- C -*-
# It does some substitutions.
-if [ -z "$MACHINE" ]; then
+if [ -z "$MACHINE" ]; then
OUTPUT_ARCH=${ARCH}
else
OUTPUT_ARCH=${ARCH}:${MACHINE}
@@ -9,8 +9,8 @@ cat >e${EMULATION_NAME}.c <<EOF
/* This file is is generated by a shell script. DO NOT EDIT! */
/* SunOS emulation code for ${EMULATION_NAME}
- Copyright 1991, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000
- Free Software Foundation, Inc.
+ Copyright 1991, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2002,
+ 2003, 2004 Free Software Foundation, Inc.
Written by Steve Chamberlain <sac@cygnus.com>
SunOS shared library support by Ian Lance Taylor <ian@cygnus.com>
@@ -61,45 +61,31 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
# endif
#endif
-static void gld${EMULATION_NAME}_before_parse PARAMS ((void));
-static void gld${EMULATION_NAME}_set_symbols PARAMS ((void));
-static void gld${EMULATION_NAME}_create_output_section_statements
- PARAMS ((void));
static void gld${EMULATION_NAME}_find_so
- PARAMS ((lang_input_statement_type *));
+ (lang_input_statement_type *);
static char *gld${EMULATION_NAME}_search_dir
- PARAMS ((const char *, const char *, boolean *));
-static void gld${EMULATION_NAME}_after_open PARAMS ((void));
+ (const char *, const char *, bfd_boolean *);
static void gld${EMULATION_NAME}_check_needed
- PARAMS ((lang_input_statement_type *));
-static boolean gld${EMULATION_NAME}_search_needed
- PARAMS ((const char *, const char *));
-static boolean gld${EMULATION_NAME}_try_needed
- PARAMS ((const char *, const char *));
-static void gld${EMULATION_NAME}_before_allocation PARAMS ((void));
+ (lang_input_statement_type *);
+static bfd_boolean gld${EMULATION_NAME}_search_needed
+ (const char *, const char *);
+static bfd_boolean gld${EMULATION_NAME}_try_needed
+ (const char *, const char *);
static void gld${EMULATION_NAME}_find_assignment
- PARAMS ((lang_statement_union_type *));
-static void gld${EMULATION_NAME}_find_exp_assignment PARAMS ((etree_type *));
+ (lang_statement_union_type *);
+static void gld${EMULATION_NAME}_find_exp_assignment
+ (etree_type *);
static void gld${EMULATION_NAME}_count_need
- PARAMS ((lang_input_statement_type *));
+ (lang_input_statement_type *);
static void gld${EMULATION_NAME}_set_need
- PARAMS ((lang_input_statement_type *));
-static char *gld${EMULATION_NAME}_get_script PARAMS ((int *isfile));
+ (lang_input_statement_type *);
static void
-gld${EMULATION_NAME}_before_parse()
+gld${EMULATION_NAME}_before_parse (void)
{
- const bfd_arch_info_type *arch = bfd_scan_arch ("${OUTPUT_ARCH}");
- if (arch)
- {
- ldfile_output_architecture = arch->arch;
- ldfile_output_machine = arch->mach;
- ldfile_output_machine_name = arch->printable_name;
- }
- else
- ldfile_output_architecture = bfd_arch_${ARCH};
- config.dynamic_link = true;
- config.has_shared = true;
+ ldfile_set_output_arch ("${OUTPUT_ARCH}", bfd_arch_`echo ${ARCH} | sed -e 's/:.*//'`);
+ config.dynamic_link = TRUE;
+ config.has_shared = TRUE;
}
/* This is called after the command line arguments have been parsed,
@@ -108,7 +94,7 @@ gld${EMULATION_NAME}_before_parse()
list. */
static void
-gld${EMULATION_NAME}_set_symbols ()
+gld${EMULATION_NAME}_set_symbols (void)
{
EOF
if [ "x${host}" = "x${target}" ] ; then
@@ -131,7 +117,7 @@ cat >>e${EMULATION_NAME}.c <<EOF
if (c != NULL)
*c++ = '\0';
if (*l != '\0')
- ldfile_add_library_path (l, false);
+ ldfile_add_library_path (l, FALSE);
if (c == NULL)
break;
l = c;
@@ -154,7 +140,7 @@ cat >>e${EMULATION_NAME}.c <<EOF
search it after including the .so file. */
static void
-gld${EMULATION_NAME}_create_output_section_statements ()
+gld${EMULATION_NAME}_create_output_section_statements (void)
{
lang_for_each_input_file (gld${EMULATION_NAME}_find_so);
}
@@ -162,8 +148,7 @@ gld${EMULATION_NAME}_create_output_section_statements ()
/* Search the directory for a .so file for each library search. */
static void
-gld${EMULATION_NAME}_find_so (inp)
- lang_input_statement_type *inp;
+gld${EMULATION_NAME}_find_so (lang_input_statement_type *inp)
{
search_dirs_type *search;
char *found = NULL;
@@ -179,7 +164,7 @@ gld${EMULATION_NAME}_find_so (inp)
for (search = search_head; search != NULL; search = search->next)
{
- boolean found_static;
+ bfd_boolean found_static;
found = gld${EMULATION_NAME}_search_dir (search->name, inp->filename,
&found_static);
@@ -202,7 +187,7 @@ gld${EMULATION_NAME}_find_so (inp)
/* Turn off the search_dirs_flag to prevent ldfile_open_file from
searching for this file again. */
- inp->search_dirs_flag = false;
+ inp->search_dirs_flag = FALSE;
free (found);
@@ -234,10 +219,8 @@ gld${EMULATION_NAME}_find_so (inp)
/* Search a directory for a .so file. */
static char *
-gld${EMULATION_NAME}_search_dir (dirname, filename, found_static)
- const char *dirname;
- const char *filename;
- boolean *found_static;
+gld${EMULATION_NAME}_search_dir
+ (const char *dirname, const char *filename, bfd_boolean *found_static)
{
int force_maj, force_min;
const char *dot;
@@ -252,7 +235,7 @@ gld${EMULATION_NAME}_search_dir (dirname, filename, found_static)
int statval;
struct stat st;
- *found_static = false;
+ *found_static = FALSE;
force_maj = -1;
force_min = -1;
@@ -284,7 +267,7 @@ gld${EMULATION_NAME}_search_dir (dirname, filename, found_static)
if (dir == NULL)
return NULL;
dirnamelen = strlen (dirname);
-
+
while ((entry = readdir (dir)) != NULL)
{
const char *s;
@@ -297,14 +280,14 @@ gld${EMULATION_NAME}_search_dir (dirname, filename, found_static)
if (dot == NULL
&& strcmp (entry->d_name + 3 + len, ".a") == 0)
{
- *found_static = true;
+ *found_static = TRUE;
continue;
}
/* We accept libfoo.so without a version number, even though the
- native linker does not. This is more convenient for packages
- which just generate .so files for shared libraries, as on ELF
- systems. */
+ native linker does not. This is more convenient for packages
+ which just generate .so files for shared libraries, as on ELF
+ systems. */
if (strncmp (entry->d_name + 3 + len, ".so", 3) != 0)
continue;
if (entry->d_name[6 + len] == '\0')
@@ -373,17 +356,17 @@ gld${EMULATION_NAME}_search_dir (dirname, filename, found_static)
between after_open and check_needed. */
static struct bfd_link_needed_list *global_needed;
-static boolean global_found;
+static bfd_boolean global_found;
/* This is called after all the input files have been opened. */
static void
-gld${EMULATION_NAME}_after_open ()
+gld${EMULATION_NAME}_after_open (void)
{
struct bfd_link_needed_list *needed, *l;
/* We only need to worry about this when doing a final link. */
- if (link_info.relocateable || link_info.shared)
+ if (link_info.relocatable || link_info.shared)
return;
/* Get the list of files which appear in ld_need entries in dynamic
@@ -412,7 +395,7 @@ gld${EMULATION_NAME}_after_open ()
/* See if this file was included in the link explicitly. */
global_needed = l;
- global_found = false;
+ global_found = FALSE;
lang_for_each_input_file (gld${EMULATION_NAME}_check_needed);
if (global_found)
continue;
@@ -513,15 +496,13 @@ cat >>e${EMULATION_NAME}.c <<EOF
/* Search for a needed file in a path. */
-static boolean
-gld${EMULATION_NAME}_search_needed (path, name)
- const char *path;
- const char *name;
+static bfd_boolean
+gld${EMULATION_NAME}_search_needed (const char *path, const char *name)
{
const char *s;
if (path == NULL || *path == '\0')
- return false;
+ return FALSE;
while (1)
{
const char *dir;
@@ -542,7 +523,7 @@ gld${EMULATION_NAME}_search_needed (path, name)
}
if (gld${EMULATION_NAME}_try_needed (dir, name))
- return true;
+ return TRUE;
if (dircopy != NULL)
free (dircopy);
@@ -552,41 +533,39 @@ gld${EMULATION_NAME}_search_needed (path, name)
path = s + 1;
}
- return false;
+ return FALSE;
}
/* This function is called for each possible directory for a needed
dynamic object. */
-static boolean
-gld${EMULATION_NAME}_try_needed (dir, name)
- const char *dir;
- const char *name;
+static bfd_boolean
+gld${EMULATION_NAME}_try_needed (const char *dir, const char *name)
{
char *file;
char *alc;
- boolean ignore;
+ bfd_boolean ignore;
bfd *abfd;
file = gld${EMULATION_NAME}_search_dir (dir, name, &ignore);
if (file == NULL)
- return false;
+ return FALSE;
alc = (char *) xmalloc (strlen (dir) + strlen (file) + 2);
sprintf (alc, "%s/%s", dir, file);
free (file);
abfd = bfd_openr (alc, bfd_get_target (output_bfd));
if (abfd == NULL)
- return false;
+ return FALSE;
if (! bfd_check_format (abfd, bfd_object))
{
(void) bfd_close (abfd);
- return false;
+ return FALSE;
}
if ((bfd_get_file_flags (abfd) & DYNAMIC) == 0)
{
(void) bfd_close (abfd);
- return false;
+ return FALSE;
}
/* We've found the needed dynamic object. */
@@ -595,7 +574,7 @@ gld${EMULATION_NAME}_try_needed (dir, name)
if (! bfd_link_add_symbols (abfd, &link_info))
einfo ("%F%B: could not read symbols: %E\n", abfd);
- return true;
+ return TRUE;
}
/* See if we have already included a needed object in the link. This
@@ -603,15 +582,14 @@ gld${EMULATION_NAME}_try_needed (dir, name)
dynamic object more than once. */
static void
-gld${EMULATION_NAME}_check_needed (s)
- lang_input_statement_type *s;
+gld${EMULATION_NAME}_check_needed (lang_input_statement_type *s)
{
if (s->filename == NULL)
return;
if (strncmp (global_needed->name, "-l", 2) != 0)
{
if (strcmp (s->filename, global_needed->name) == 0)
- global_found = true;
+ global_found = TRUE;
}
else
{
@@ -651,7 +629,7 @@ gld${EMULATION_NAME}_check_needed (s)
|| (smin != lmin && smin != -1 && lmin != -1))
return;
- global_found = true;
+ global_found = TRUE;
}
}
@@ -659,7 +637,7 @@ gld${EMULATION_NAME}_check_needed (s)
to lang_for_each_statement. Ick. */
static const char *find_assign;
-static boolean found_assign;
+static bfd_boolean found_assign;
/* We need to use static variables to pass information around the call
to lang_for_each_input_file. Ick. */
@@ -679,7 +657,7 @@ static bfd_byte *need_pnames;
sections, but before any sizes or addresses have been set. */
static void
-gld${EMULATION_NAME}_before_allocation ()
+gld${EMULATION_NAME}_before_allocation (void)
{
struct bfd_link_hash_entry *hdyn = NULL;
asection *sneed;
@@ -689,11 +667,11 @@ gld${EMULATION_NAME}_before_allocation ()
/* The SunOS native linker creates a shared library whenever there
are any undefined symbols in a link, unless -e is used. This is
pretty weird, but we are compatible. */
- if (! link_info.shared && ! link_info.relocateable && ! entry_from_cmdline)
+ if (! link_info.shared && ! link_info.relocatable && ! entry_from_cmdline)
{
struct bfd_link_hash_entry *h;
-
- for (h = link_info.hash->undefs; h != NULL; h = h->next)
+
+ for (h = link_info.hash->undefs; h != NULL; h = h->und_next)
{
if (h->type == bfd_link_hash_undefined
&& h->u.undef.abfd != NULL
@@ -702,11 +680,11 @@ gld${EMULATION_NAME}_before_allocation ()
&& strcmp (h->root.string, "__GLOBAL_OFFSET_TABLE_") != 0)
{
find_assign = h->root.string;
- found_assign = false;
+ found_assign = FALSE;
lang_for_each_statement (gld${EMULATION_NAME}_find_assignment);
if (! found_assign)
{
- link_info.shared = true;
+ link_info.shared = TRUE;
break;
}
}
@@ -718,7 +696,7 @@ gld${EMULATION_NAME}_before_allocation ()
lang_output_section_statement_type *os;
/* Set the .text section to start at 0x20, not 0x2020. FIXME:
- This is too magical. */
+ This is too magical. */
os = lang_output_section_statement_lookup (".text");
if (os->addr_tree == NULL)
os->addr_tree = exp_intop (0x20);
@@ -730,10 +708,10 @@ gld${EMULATION_NAME}_before_allocation ()
one. We need to create the symbol before calling
size_dynamic_sections, although we can't set the value until
afterward. */
- if (! link_info.relocateable)
+ if (! link_info.relocatable)
{
- hdyn = bfd_link_hash_lookup (link_info.hash, "__DYNAMIC", true, false,
- false);
+ hdyn = bfd_link_hash_lookup (link_info.hash, "__DYNAMIC", TRUE, FALSE,
+ FALSE);
if (hdyn == NULL)
einfo ("%P%F: bfd_link_hash_lookup: %E\n");
if (! bfd_sunos_record_link_assignment (output_bfd, &link_info,
@@ -823,7 +801,7 @@ gld${EMULATION_NAME}_before_allocation ()
/* We must assign a value to __DYNAMIC. It should be zero if we are
not doing a dynamic link, or the start of the .dynamic section if
we are doing one. */
- if (! link_info.relocateable)
+ if (! link_info.relocatable)
{
hdyn->type = bfd_link_hash_defined;
hdyn->u.def.value = 0;
@@ -842,8 +820,7 @@ gld${EMULATION_NAME}_before_allocation ()
symbols which are referred to by dynamic objects. */
static void
-gld${EMULATION_NAME}_find_assignment (s)
- lang_statement_union_type *s;
+gld${EMULATION_NAME}_find_assignment (lang_statement_union_type *s)
{
if (s->header.type == lang_assignment_statement_enum
&& (find_assign == NULL || ! found_assign))
@@ -853,8 +830,7 @@ gld${EMULATION_NAME}_find_assignment (s)
/* Look through an expression for an assignment statement. */
static void
-gld${EMULATION_NAME}_find_exp_assignment (exp)
- etree_type *exp;
+gld${EMULATION_NAME}_find_exp_assignment (etree_type *exp)
{
switch (exp->type.node_class)
{
@@ -862,7 +838,7 @@ gld${EMULATION_NAME}_find_exp_assignment (exp)
if (find_assign != NULL)
{
if (strcmp (find_assign, exp->assign.dst) == 0)
- found_assign = true;
+ found_assign = TRUE;
return;
}
@@ -902,8 +878,7 @@ gld${EMULATION_NAME}_find_exp_assignment (exp)
for more information. */
static void
-gld${EMULATION_NAME}_count_need (inp)
- lang_input_statement_type *inp;
+gld${EMULATION_NAME}_count_need (lang_input_statement_type *inp)
{
if (inp->the_bfd != NULL
&& (inp->the_bfd->flags & DYNAMIC) != 0)
@@ -924,8 +899,7 @@ gld${EMULATION_NAME}_count_need (inp)
/* Fill in the contents of the .need section. */
static void
-gld${EMULATION_NAME}_set_need (inp)
- lang_input_statement_type *inp;
+gld${EMULATION_NAME}_set_need (lang_input_statement_type *inp)
{
if (inp->the_bfd != NULL
&& (inp->the_bfd->flags & DYNAMIC) != 0)
@@ -974,8 +948,7 @@ gld${EMULATION_NAME}_set_need (inp)
}
static char *
-gld${EMULATION_NAME}_get_script(isfile)
- int *isfile;
+gld${EMULATION_NAME}_get_script (int *isfile)
EOF
if test -n "$COMPILE_IN"
@@ -986,14 +959,14 @@ then
sc="-f stringify.sed"
cat >>e${EMULATION_NAME}.c <<EOF
-{
+{
*isfile = 0;
- if (link_info.relocateable == true && config.build_constructors == true)
+ if (link_info.relocatable && config.build_constructors)
return
EOF
sed $sc ldscripts/${EMULATION_NAME}.xu >> e${EMULATION_NAME}.c
-echo ' ; else if (link_info.relocateable == true) return' >> e${EMULATION_NAME}.c
+echo ' ; else if (link_info.relocatable) return' >> e${EMULATION_NAME}.c
sed $sc ldscripts/${EMULATION_NAME}.xr >> e${EMULATION_NAME}.c
echo ' ; else if (!config.text_read_only) return' >> e${EMULATION_NAME}.c
sed $sc ldscripts/${EMULATION_NAME}.xbn >> e${EMULATION_NAME}.c
@@ -1007,12 +980,12 @@ else
# Scripts read from the filesystem.
cat >>e${EMULATION_NAME}.c <<EOF
-{
+{
*isfile = 1;
- if (link_info.relocateable == true && config.build_constructors == true)
+ if (link_info.relocatable && config.build_constructors)
return "ldscripts/${EMULATION_NAME}.xu";
- else if (link_info.relocateable == true)
+ else if (link_info.relocatable)
return "ldscripts/${EMULATION_NAME}.xr";
else if (!config.text_read_only)
return "ldscripts/${EMULATION_NAME}.xbn";
@@ -1027,7 +1000,7 @@ fi
cat >>e${EMULATION_NAME}.c <<EOF
-struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
+struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
{
gld${EMULATION_NAME}_before_parse,
syslib_default,
@@ -1047,6 +1020,8 @@ struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
NULL, /* place orphan */
gld${EMULATION_NAME}_set_symbols,
NULL, /* parse args */
+ NULL, /* add_options */
+ NULL, /* handle_option */
NULL, /* unrecognized file */
NULL, /* list options */
NULL, /* recognized file */
diff --git a/contrib/binutils/ld/emultempl/ticoff.em b/contrib/binutils/ld/emultempl/ticoff.em
index eb10317..8f86b04 100644
--- a/contrib/binutils/ld/emultempl/ticoff.em
+++ b/contrib/binutils/ld/emultempl/ticoff.em
@@ -3,7 +3,7 @@
(echo;echo;echo;echo)>e${EMULATION_NAME}.c # there, now line numbers match ;-)
cat >>e${EMULATION_NAME}.c <<EOF
/* This file is part of GLD, the Gnu Linker.
- Copyright 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1999, 2000, 2002, 2003, 2004 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -20,110 +20,87 @@ along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
/* For TI COFF */
-/* Need to determine load and run pages for output sections */
-
+/* Need to determine load and run pages for output sections */
+
#define TARGET_IS_${EMULATION_NAME}
#include "bfd.h"
#include "sysdep.h"
#include "bfdlink.h"
+#include "getopt.h"
#include "ld.h"
#include "ldmain.h"
#include "ldmisc.h"
-
#include "ldexp.h"
#include "ldlang.h"
#include "ldfile.h"
#include "ldemul.h"
-#include "getopt.h"
-
static int coff_version;
-static void gld_${EMULATION_NAME}_before_parse PARAMS ((void));
-static char *gld_${EMULATION_NAME}_get_script PARAMS ((int *));
-static int gld_${EMULATION_NAME}_parse_args PARAMS ((int, char **));
-static void gld_${EMULATION_NAME}_list_options PARAMS ((FILE *));
-
/* TI COFF extra command line options */
#define OPTION_COFF_FORMAT (300 + 1)
-static struct option longopts[] =
+static void
+gld${EMULATION_NAME}_add_options
+ (int ns ATTRIBUTE_UNUSED, char **shortopts ATTRIBUTE_UNUSED, int nl,
+ struct option **longopts, int nrl ATTRIBUTE_UNUSED,
+ struct option **really_longopts ATTRIBUTE_UNUSED)
{
- /* TI COFF options */
- {"format", required_argument, NULL, OPTION_COFF_FORMAT },
- {NULL, no_argument, NULL, 0}
-};
+ static const struct option xtra_long[] = {
+ /* TI COFF options */
+ {"format", required_argument, NULL, OPTION_COFF_FORMAT },
+ {NULL, no_argument, NULL, 0}
+ };
+
+ *longopts = (struct option *)
+ xrealloc (*longopts, nl * sizeof (struct option) + sizeof (xtra_long));
+ memcpy (*longopts + nl, &xtra_long, sizeof (xtra_long));
+}
static void
-gld_${EMULATION_NAME}_list_options (file)
- FILE * file;
+gld_${EMULATION_NAME}_list_options (FILE * file)
{
- fprintf (file, _(" --format 0|1|2 Specify which COFF version to use"));
-}
+ fprintf (file, _(" --format 0|1|2 Specify which COFF version to use\n"));
+}
-static int
-gld_${EMULATION_NAME}_parse_args(argc, argv)
- int argc;
- char **argv;
+static bfd_boolean
+gld${EMULATION_NAME}_handle_option (int optc)
{
- int longind;
- int optc;
- int prevoptind = optind;
- int prevopterr = opterr;
- int wanterror;
- static int lastoptind = -1;
-
- if (lastoptind != optind)
- opterr = 0;
- wanterror = opterr;
-
- lastoptind = optind;
-
- optc = getopt_long_only (argc, argv, "-", longopts, &longind);
- opterr = prevopterr;
-
switch (optc)
{
default:
- if (wanterror)
- xexit (1);
- optind = prevoptind;
- return 0;
+ return FALSE;
case OPTION_COFF_FORMAT:
if ((*optarg == '0' || *optarg == '1' || *optarg == '2')
&& optarg[1] == '\0')
{
- extern void lang_add_output_format
- PARAMS ((const char *, const char *, const char *, int));
static char buf[] = "coffX-${OUTPUT_FORMAT_TEMPLATE}";
coff_version = *optarg - '0';
buf[4] = *optarg;
- lang_add_output_format (buf, NULL, NULL, 0);
+ lang_add_output_format (buf, NULL, NULL, 0);
}
else
{
einfo (_("%P%F: invalid COFF format version %s\n"), optarg);
-
}
break;
}
- return 1;
+ return FALSE;
}
static void
-gld_${EMULATION_NAME}_before_parse()
+gld_${EMULATION_NAME}_before_parse(void)
{
#ifndef TARGET_ /* I.e., if not generic. */
- ldfile_set_output_arch ("`echo ${ARCH}`");
+ ldfile_set_output_arch ("`echo ${ARCH}`", bfd_arch_unknown);
#endif /* not TARGET_ */
}
static char *
-gld_${EMULATION_NAME}_get_script (isfile)
- int *isfile;
+gld_${EMULATION_NAME}_get_script (int *isfile)
EOF
if test -n "$COMPILE_IN"
then
@@ -136,11 +113,11 @@ s/$/\\n\\/
$s/$/n"/
'
cat >>e${EMULATION_NAME}.c <<EOF
-{
+{
*isfile = 0;
- if (link_info.relocateable == true && config.build_constructors == true)
+ if (link_info.relocatable && config.build_constructors)
return `sed "$sc" ldscripts/${EMULATION_NAME}.xu`;
- else if (link_info.relocateable == true)
+ else if (link_info.relocatable)
return `sed "$sc" ldscripts/${EMULATION_NAME}.xr`;
else if (!config.text_read_only)
return `sed "$sc" ldscripts/${EMULATION_NAME}.xbn`;
@@ -155,12 +132,12 @@ else
# Scripts read from the filesystem.
cat >>e${EMULATION_NAME}.c <<EOF
-{
+{
*isfile = 1;
- if (link_info.relocateable == true && config.build_constructors == true)
+ if (link_info.relocatable && config.build_constructors)
return "ldscripts/${EMULATION_NAME}.xu";
- else if (link_info.relocateable == true)
+ else if (link_info.relocatable)
return "ldscripts/${EMULATION_NAME}.xr";
else if (!config.text_read_only)
return "ldscripts/${EMULATION_NAME}.xbn";
@@ -174,7 +151,7 @@ EOF
fi
cat >>e${EMULATION_NAME}.c <<EOF
-struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
+struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
{
gld_${EMULATION_NAME}_before_parse,
syslib_default,
@@ -193,7 +170,9 @@ struct ld_emulation_xfer_struct ld_${EMULATION_NAME}_emulation =
NULL, /* open dynamic archive */
NULL, /* place orphan */
NULL, /* set_symbols */
- gld_${EMULATION_NAME}_parse_args,
+ NULL, /* parse_args */
+ gld${EMULATION_NAME}_add_options,
+ gld${EMULATION_NAME}_handle_option,
NULL, /* unrecognized_file */
gld_${EMULATION_NAME}_list_options,
NULL, /* recognized file */
diff --git a/contrib/binutils/ld/emultempl/vanilla.em b/contrib/binutils/ld/emultempl/vanilla.em
index 4c38207..2141083 100644
--- a/contrib/binutils/ld/emultempl/vanilla.em
+++ b/contrib/binutils/ld/emultempl/vanilla.em
@@ -2,7 +2,8 @@
# It does some substitutions.
cat >e${EMULATION_NAME}.c <<EOF
/* A vanilla emulation with no defaults
- Copyright 1991, 1992, 1994, 2000, 2001 Free Software Foundation, Inc.
+ Copyright 1991, 1992, 1994, 2000, 2001, 2002, 2003
+ Free Software Foundation, Inc.
Written by Steve Chamberlain steve@cygnus.com
This file is part of GLD, the Gnu Linker.
@@ -34,17 +35,12 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "ldfile.h"
#include "ldemul.h"
-static void vanilla_before_parse PARAMS ((void));
-static void vanilla_set_output_arch PARAMS ((void));
-static char *vanilla_get_script PARAMS ((int *));
-
-
-static void vanilla_before_parse()
+static void vanilla_before_parse (void)
{
}
static void
-vanilla_set_output_arch()
+vanilla_set_output_arch (void)
{
/* Set the output architecture and machine if possible */
unsigned long machine = 0;
@@ -52,14 +48,13 @@ vanilla_set_output_arch()
}
static char *
-vanilla_get_script(isfile)
- int *isfile;
+vanilla_get_script (int *isfile)
{
*isfile = 0;
return "";
}
-struct ld_emulation_xfer_struct ld_vanilla_emulation =
+struct ld_emulation_xfer_struct ld_vanilla_emulation =
{
vanilla_before_parse,
syslib_default,
@@ -79,6 +74,8 @@ struct ld_emulation_xfer_struct ld_vanilla_emulation =
NULL, /* place orphan */
NULL, /* set symbols */
NULL, /* parse args */
+ NULL, /* add_options */
+ NULL, /* handle_option */
NULL, /* unrecognized file */
NULL, /* list options */
NULL, /* recognized file */
diff --git a/contrib/binutils/ld/fdl.texi b/contrib/binutils/ld/fdl.texi
new file mode 100644
index 0000000..c6409a3
--- /dev/null
+++ b/contrib/binutils/ld/fdl.texi
@@ -0,0 +1,367 @@
+@c -*-texinfo-*-
+@node GNU Free Documentation License
+@appendix GNU Free Documentation License
+@center Version 1.1, March 2000
+
+@display
+Copyright (C) 2000, Free Software Foundation, Inc.
+59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+Everyone is permitted to copy and distribute verbatim copies
+of this license document, but changing it is not allowed.
+@end display
+@sp 1
+@enumerate 0
+@item
+PREAMBLE
+
+The purpose of this License is to make a manual, textbook, or other
+written document ``free'' in the sense of freedom: to assure everyone
+the effective freedom to copy and redistribute it, with or without
+modifying it, either commercially or noncommercially. Secondarily,
+this License preserves for the author and publisher a way to get
+credit for their work, while not being considered responsible for
+modifications made by others.
+
+This License is a kind of ``copyleft'', which means that derivative
+works of the document must themselves be free in the same sense. It
+complements the GNU General Public License, which is a copyleft
+license designed for free software.
+
+We have designed this License in order to use it for manuals for free
+software, because free software needs free documentation: a free
+program should come with manuals providing the same freedoms that the
+software does. But this License is not limited to software manuals;
+it can be used for any textual work, regardless of subject matter or
+whether it is published as a printed book. We recommend this License
+principally for works whose purpose is instruction or reference.
+
+@sp 1
+@item
+APPLICABILITY AND DEFINITIONS
+
+This License applies to any manual or other work that contains a
+notice placed by the copyright holder saying it can be distributed
+under the terms of this License. The ``Document'', below, refers to any
+such manual or work. Any member of the public is a licensee, and is
+addressed as ``you.''
+
+A ``Modified Version'' of the Document means any work containing the
+Document or a portion of it, either copied verbatim, or with
+modifications and/or translated into another language.
+
+A ``Secondary Section'' is a named appendix or a front-matter section of
+the Document that deals exclusively with the relationship of the
+publishers or authors of the Document to the Document's overall subject
+(or to related matters) and contains nothing that could fall directly
+within that overall subject. (For example, if the Document is in part a
+textbook of mathematics, a Secondary Section may not explain any
+mathematics.) The relationship could be a matter of historical
+connection with the subject or with related matters, or of legal,
+commercial, philosophical, ethical or political position regarding
+them.
+
+The ``Invariant Sections'' are certain Secondary Sections whose titles
+are designated, as being those of Invariant Sections, in the notice
+that says that the Document is released under this License.
+
+The ``Cover Texts'' are certain short passages of text that are listed,
+as Front-Cover Texts or Back-Cover Texts, in the notice that says that
+the Document is released under this License.
+
+A ``Transparent'' copy of the Document means a machine-readable copy,
+represented in a format whose specification is available to the
+general public, whose contents can be viewed and edited directly and
+straightforwardly with generic text editors or (for images composed of
+pixels) generic paint programs or (for drawings) some widely available
+drawing editor, and that is suitable for input to text formatters or
+for automatic translation to a variety of formats suitable for input
+to text formatters. A copy made in an otherwise Transparent file
+format whose markup has been designed to thwart or discourage
+subsequent modification by readers is not Transparent. A copy that is
+not ``Transparent'' is called ``Opaque.''
+
+Examples of suitable formats for Transparent copies include plain
+ASCII without markup, Texinfo input format, LaTeX input format, SGML
+or XML using a publicly available DTD, and standard-conforming simple
+HTML designed for human modification. Opaque formats include
+PostScript, PDF, proprietary formats that can be read and edited only
+by proprietary word processors, SGML or XML for which the DTD and/or
+processing tools are not generally available, and the
+machine-generated HTML produced by some word processors for output
+purposes only.
+
+The ``Title Page'' means, for a printed book, the title page itself,
+plus such following pages as are needed to hold, legibly, the material
+this License requires to appear in the title page. For works in
+formats which do not have any title page as such, ``Title Page'' means
+the text near the most prominent appearance of the work's title,
+preceding the beginning of the body of the text.
+@sp 1
+@item
+VERBATIM COPYING
+
+You may copy and distribute the Document in any medium, either
+commercially or noncommercially, provided that this License, the
+copyright notices, and the license notice saying this License applies
+to the Document are reproduced in all copies, and that you add no other
+conditions whatsoever to those of this License. You may not use
+technical measures to obstruct or control the reading or further
+copying of the copies you make or distribute. However, you may accept
+compensation in exchange for copies. If you distribute a large enough
+number of copies you must also follow the conditions in section 3.
+
+You may also lend copies, under the same conditions stated above, and
+you may publicly display copies.
+@sp 1
+@item
+COPYING IN QUANTITY
+
+If you publish printed copies of the Document numbering more than 100,
+and the Document's license notice requires Cover Texts, you must enclose
+the copies in covers that carry, clearly and legibly, all these Cover
+Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on
+the back cover. Both covers must also clearly and legibly identify
+you as the publisher of these copies. The front cover must present
+the full title with all words of the title equally prominent and
+visible. You may add other material on the covers in addition.
+Copying with changes limited to the covers, as long as they preserve
+the title of the Document and satisfy these conditions, can be treated
+as verbatim copying in other respects.
+
+If the required texts for either cover are too voluminous to fit
+legibly, you should put the first ones listed (as many as fit
+reasonably) on the actual cover, and continue the rest onto adjacent
+pages.
+
+If you publish or distribute Opaque copies of the Document numbering
+more than 100, you must either include a machine-readable Transparent
+copy along with each Opaque copy, or state in or with each Opaque copy
+a publicly-accessible computer-network location containing a complete
+Transparent copy of the Document, free of added material, which the
+general network-using public has access to download anonymously at no
+charge using public-standard network protocols. If you use the latter
+option, you must take reasonably prudent steps, when you begin
+distribution of Opaque copies in quantity, to ensure that this
+Transparent copy will remain thus accessible at the stated location
+until at least one year after the last time you distribute an Opaque
+copy (directly or through your agents or retailers) of that edition to
+the public.
+
+It is requested, but not required, that you contact the authors of the
+Document well before redistributing any large number of copies, to give
+them a chance to provide you with an updated version of the Document.
+@sp 1
+@item
+MODIFICATIONS
+
+You may copy and distribute a Modified Version of the Document under
+the conditions of sections 2 and 3 above, provided that you release
+the Modified Version under precisely this License, with the Modified
+Version filling the role of the Document, thus licensing distribution
+and modification of the Modified Version to whoever possesses a copy
+of it. In addition, you must do these things in the Modified Version:
+
+A. Use in the Title Page (and on the covers, if any) a title distinct
+ from that of the Document, and from those of previous versions
+ (which should, if there were any, be listed in the History section
+ of the Document). You may use the same title as a previous version
+ if the original publisher of that version gives permission.@*
+B. List on the Title Page, as authors, one or more persons or entities
+ responsible for authorship of the modifications in the Modified
+ Version, together with at least five of the principal authors of the
+ Document (all of its principal authors, if it has less than five).@*
+C. State on the Title page the name of the publisher of the
+ Modified Version, as the publisher.@*
+D. Preserve all the copyright notices of the Document.@*
+E. Add an appropriate copyright notice for your modifications
+ adjacent to the other copyright notices.@*
+F. Include, immediately after the copyright notices, a license notice
+ giving the public permission to use the Modified Version under the
+ terms of this License, in the form shown in the Addendum below.@*
+G. Preserve in that license notice the full lists of Invariant Sections
+ and required Cover Texts given in the Document's license notice.@*
+H. Include an unaltered copy of this License.@*
+I. Preserve the section entitled ``History'', and its title, and add to
+ it an item stating at least the title, year, new authors, and
+ publisher of the Modified Version as given on the Title Page. If
+ there is no section entitled ``History'' in the Document, create one
+ stating the title, year, authors, and publisher of the Document as
+ given on its Title Page, then add an item describing the Modified
+ Version as stated in the previous sentence.@*
+J. Preserve the network location, if any, given in the Document for
+ public access to a Transparent copy of the Document, and likewise
+ the network locations given in the Document for previous versions
+ it was based on. These may be placed in the ``History'' section.
+ You may omit a network location for a work that was published at
+ least four years before the Document itself, or if the original
+ publisher of the version it refers to gives permission.@*
+K. In any section entitled ``Acknowledgements'' or ``Dedications'',
+ preserve the section's title, and preserve in the section all the
+ substance and tone of each of the contributor acknowledgements
+ and/or dedications given therein.@*
+L. Preserve all the Invariant Sections of the Document,
+ unaltered in their text and in their titles. Section numbers
+ or the equivalent are not considered part of the section titles.@*
+M. Delete any section entitled ``Endorsements.'' Such a section
+ may not be included in the Modified Version.@*
+N. Do not retitle any existing section as ``Endorsements''
+ or to conflict in title with any Invariant Section.@*
+@sp 1
+If the Modified Version includes new front-matter sections or
+appendices that qualify as Secondary Sections and contain no material
+copied from the Document, you may at your option designate some or all
+of these sections as invariant. To do this, add their titles to the
+list of Invariant Sections in the Modified Version's license notice.
+These titles must be distinct from any other section titles.
+
+You may add a section entitled ``Endorsements'', provided it contains
+nothing but endorsements of your Modified Version by various
+parties--for example, statements of peer review or that the text has
+been approved by an organization as the authoritative definition of a
+standard.
+
+You may add a passage of up to five words as a Front-Cover Text, and a
+passage of up to 25 words as a Back-Cover Text, to the end of the list
+of Cover Texts in the Modified Version. Only one passage of
+Front-Cover Text and one of Back-Cover Text may be added by (or
+through arrangements made by) any one entity. If the Document already
+includes a cover text for the same cover, previously added by you or
+by arrangement made by the same entity you are acting on behalf of,
+you may not add another; but you may replace the old one, on explicit
+permission from the previous publisher that added the old one.
+
+The author(s) and publisher(s) of the Document do not by this License
+give permission to use their names for publicity for or to assert or
+imply endorsement of any Modified Version.
+@sp 1
+@item
+COMBINING DOCUMENTS
+
+You may combine the Document with other documents released under this
+License, under the terms defined in section 4 above for modified
+versions, provided that you include in the combination all of the
+Invariant Sections of all of the original documents, unmodified, and
+list them all as Invariant Sections of your combined work in its
+license notice.
+
+The combined work need only contain one copy of this License, and
+multiple identical Invariant Sections may be replaced with a single
+copy. If there are multiple Invariant Sections with the same name but
+different contents, make the title of each such section unique by
+adding at the end of it, in parentheses, the name of the original
+author or publisher of that section if known, or else a unique number.
+Make the same adjustment to the section titles in the list of
+Invariant Sections in the license notice of the combined work.
+
+In the combination, you must combine any sections entitled ``History''
+in the various original documents, forming one section entitled
+``History''; likewise combine any sections entitled ``Acknowledgements'',
+and any sections entitled ``Dedications.'' You must delete all sections
+entitled ``Endorsements.''
+@sp 1
+@item
+COLLECTIONS OF DOCUMENTS
+
+You may make a collection consisting of the Document and other documents
+released under this License, and replace the individual copies of this
+License in the various documents with a single copy that is included in
+the collection, provided that you follow the rules of this License for
+verbatim copying of each of the documents in all other respects.
+
+You may extract a single document from such a collection, and distribute
+it individually under this License, provided you insert a copy of this
+License into the extracted document, and follow this License in all
+other respects regarding verbatim copying of that document.
+@sp 1
+@item
+AGGREGATION WITH INDEPENDENT WORKS
+
+A compilation of the Document or its derivatives with other separate
+and independent documents or works, in or on a volume of a storage or
+distribution medium, does not as a whole count as a Modified Version
+of the Document, provided no compilation copyright is claimed for the
+compilation. Such a compilation is called an ``aggregate'', and this
+License does not apply to the other self-contained works thus compiled
+with the Document, on account of their being thus compiled, if they
+are not themselves derivative works of the Document.
+
+If the Cover Text requirement of section 3 is applicable to these
+copies of the Document, then if the Document is less than one quarter
+of the entire aggregate, the Document's Cover Texts may be placed on
+covers that surround only the Document within the aggregate.
+Otherwise they must appear on covers around the whole aggregate.
+@sp 1
+@item
+TRANSLATION
+
+Translation is considered a kind of modification, so you may
+distribute translations of the Document under the terms of section 4.
+Replacing Invariant Sections with translations requires special
+permission from their copyright holders, but you may include
+translations of some or all Invariant Sections in addition to the
+original versions of these Invariant Sections. You may include a
+translation of this License provided that you also include the
+original English version of this License. In case of a disagreement
+between the translation and the original English version of this
+License, the original English version will prevail.
+@sp 1
+@item
+TERMINATION
+
+You may not copy, modify, sublicense, or distribute the Document except
+as expressly provided for under this License. Any other attempt to
+copy, modify, sublicense or distribute the Document is void, and will
+automatically terminate your rights under this License. However,
+parties who have received copies, or rights, from you under this
+License will not have their licenses terminated so long as such
+parties remain in full compliance.
+@sp 1
+@item
+FUTURE REVISIONS OF THIS LICENSE
+
+The Free Software Foundation may publish new, revised versions
+of the GNU Free Documentation License from time to time. Such new
+versions will be similar in spirit to the present version, but may
+differ in detail to address new problems or concerns. See
+http://www.gnu.org/copyleft/.
+
+Each version of the License is given a distinguishing version number.
+If the Document specifies that a particular numbered version of this
+License ``or any later version'' applies to it, you have the option of
+following the terms and conditions either of that specified version or
+of any later version that has been published (not as a draft) by the
+Free Software Foundation. If the Document does not specify a version
+number of this License, you may choose any version ever published (not
+as a draft) by the Free Software Foundation.
+
+@end enumerate
+
+@unnumberedsec ADDENDUM: How to use this License for your documents
+
+To use this License in a document you have written, include a copy of
+the License in the document and put the following copyright and
+license notices just after the title page:
+
+@smallexample
+@group
+Copyright (C) @var{year} @var{your name}.
+Permission is granted to copy, distribute and/or modify this document
+under the terms of the GNU Free Documentation License, Version 1.1
+or any later version published by the Free Software Foundation;
+with the Invariant Sections being @var{list their titles}, with the
+Front-Cover Texts being @var{list}, and with the Back-Cover Texts being @var{list}.
+A copy of the license is included in the section entitled "GNU
+Free Documentation License."
+@end group
+@end smallexample
+
+If you have no Invariant Sections, write ``with no Invariant Sections''
+instead of saying which ones are invariant. If you have no
+Front-Cover Texts, write ``no Front-Cover Texts'' instead of
+``Front-Cover Texts being @var{list}''; likewise for Back-Cover Texts.
+
+If your document contains nontrivial examples of program code, we
+recommend releasing these examples in parallel under your choice of
+free software license, such as the GNU General Public License,
+to permit their use in free software.
diff --git a/contrib/binutils/ld/gen-doc.texi b/contrib/binutils/ld/gen-doc.texi
index c0ebac7..5add195 100644
--- a/contrib/binutils/ld/gen-doc.texi
+++ b/contrib/binutils/ld/gen-doc.texi
@@ -5,8 +5,13 @@
@c 2. Specific target machines
@set H8300
@set I960
+@set ARM
+@set HPPA
@set MMIX
+@set MSP430
@set TICOFF
+@set WIN32
+@set XTENSA
@c 3. Properties of this configuration
@clear SingleFormat
diff --git a/contrib/binutils/ld/genscripts.sh b/contrib/binutils/ld/genscripts.sh
index 36e0a9d..0168203 100755
--- a/contrib/binutils/ld/genscripts.sh
+++ b/contrib/binutils/ld/genscripts.sh
@@ -1,15 +1,61 @@
#!/bin/sh
# genscripts.sh - generate the ld-emulation-target specific files
#
-# Usage: genscripts.sh srcdir libdir exec_prefix \
-# host target target_alias default_emulation \
-# native_lib_dirs this_emulation tool_dir
+# Usage: genscripts_extra.sh \
+# srcdir \
+# libdir \
+# exec_prefix \
+# host \
+# target \
+# target_alias \
+# default_emulation \
+# native_lib_dirs \
+# use_sysroot \
+# this_emulation \
+# optional:
+# tool_dir \
+# customizer_script
#
# Sample usage:
-# genscripts.sh /djm/ld-devo/devo/ld /usr/local/lib /usr/local \
-# sparc-sun-sunos4.1.3 sparc-sun-sunos4.1.3 sparc-sun-sunos4.1.3 sun4 \
-# "" sun3 sparc-sun-sunos4.1.3
-# produces sun3.x sun3.xbn sun3.xn sun3.xr sun3.xu em_sun3.c
+#
+# genscripts_extra.sh \
+# /sources/ld \
+# /usr/local/lib \
+# /usr/local \
+# sparc-sun-sunos4.1.3 \
+# sparc-sun-sunos4.1.3 \
+# sparc-sun-sunos4.1.3 \
+# sun4 \
+# "" \
+# no \
+# sun3 \
+# sparc-sun-sunos4.1.3 \
+# sparc.sh
+#
+# produces the linker scripts:
+#
+# sun3.x [default linker script]
+# sun3.xbn [used when the linker is invoked with "-N"]
+# sun3.xn [used when the linker is invoked with "-n"]
+# sun3.xr [used when the linker is invoked with "-r"]
+# sun3.xu [used when the linker is invoked with "-Ur"]
+# and maybe:
+# sun3.xc [used when the linker is invoked with "-z combreloc"]
+# sun3.xsc [used when the linker is invoked with "--shared"]
+# sun3.xdc [used when the linker is invoked with "-pie"]
+#
+# It also produced the C source file:
+#
+# em_sun3.c
+#
+# which is then compiled into the linker.
+#
+# The linker scripts are created by running the shell script
+# /sources/ld/emulparams/sparc.sh to set the value of ${SCRIPT_NAME}
+# (and any other variables it wants to). ${SCRIPT_NAME} is then
+# invoked with a variable called ${LD_FLAG} to tell it which version
+# of the linker script to create.
+
srcdir=$1
libdir=$2
@@ -19,17 +65,26 @@ target=$5
target_alias=$6
EMULATION_LIBPATH=$7
NATIVE_LIB_DIRS=$8
-EMULATION_NAME=$9
+use_sysroot=$9
shift 9
-# Can't use ${1:-$target_alias} here due to an Ultrix shell bug.
-if [ "x$1" = "x" ] ; then
+EMULATION_NAME=$1
+TOOL_LIB=$2
+CUSTOMIZER_SCRIPT=$3
+
+# Can't use ${TOOL_LIB:-$target_alias} here due to an Ultrix shell bug.
+if [ "x${TOOL_LIB}" = "x" ] ; then
tool_lib=${exec_prefix}/${target_alias}/lib
else
- tool_lib=${exec_prefix}/$1/lib
+ tool_lib=${exec_prefix}/${TOOL_LIB}/lib
+fi
+
+if [ "x${CUSTOMIZER_SCRIPT}" = "x" ] ; then
+ CUSTOMIZER_SCRIPT=${EMULATION_NAME}
fi
+CUSTOMIZER_SCRIPT="${srcdir}/emulparams/${CUSTOMIZER_SCRIPT}.sh"
# Include the emulation-specific parameters:
-. ${srcdir}/emulparams/${EMULATION_NAME}.sh
+. ${CUSTOMIZER_SCRIPT} ${EMULATION_NAME}
if test -d ldscripts; then
true
@@ -37,34 +92,113 @@ else
mkdir ldscripts
fi
+# Set some flags for the emultempl scripts. USE_LIBPATH will
+# be set for any libpath-using emulation; NATIVE will be set for a
+# libpath-using emulation where ${host} = ${target}. NATIVE
+# may already have been set by the emulparams file, but that's OK
+# (it'll just get set to "yes" twice).
+
+case " $EMULATION_LIBPATH " in
+ *" ${EMULATION_NAME} "*)
+ if [ "x${host}" = "x${target}" ] ; then
+ NATIVE=yes
+ USE_LIBPATH=yes
+ elif [ "x${use_sysroot}" = "xyes" ] ; then
+ USE_LIBPATH=yes
+ fi
+ ;;
+esac
+
+# If the emulparams file sets NATIVE, make sure USE_LIBPATH is set also.
+if test "x$NATIVE" = "xyes" ; then
+ USE_LIBPATH=yes
+fi
+
# Set the library search path, for libraries named by -lfoo.
# If LIB_PATH is defined (e.g., by Makefile) and non-empty, it is used.
# Otherwise, the default is set here.
#
# The format is the usual list of colon-separated directories.
# To force a logically empty LIB_PATH, do LIBPATH=":".
+#
+# If we are using a sysroot, prefix library paths with "=" to indicate this.
+#
+# If the emulparams file set LIBPATH_SUFFIX, prepend an extra copy of
+# the library path with the suffix applied.
-if [ "x${LIB_PATH}" = "x" ] ; then
- if [ "x${host}" = "x${target}" ] ; then
- case " $EMULATION_LIBPATH " in
- *" ${EMULATION_NAME} "*)
- # Native, and default or emulation requesting LIB_PATH.
- LIB_PATH=${libdir}
- for lib in ${NATIVE_LIB_DIRS}; do
- case :${LIB_PATH}: in
- *:${lib}:*) ;;
- *) LIB_PATH=${LIB_PATH}:${lib} ;;
- esac
- done
+if [ "x${LIB_PATH}" = "x" ] && [ "x${USE_LIBPATH}" = xyes ] ; then
+ LIB_PATH2=
+
+ libs=${NATIVE_LIB_DIRS}
+ if [ "x${use_sysroot}" != "xyes" ] ; then
+ case " ${libs} " in
+ *" ${libdir} "*) ;;
+ *) libs="${libdir} ${libs}" ;;
+ esac
+ case " ${libs} " in
+ *" ${tool_lib} "*) ;;
+ *) libs="${tool_lib} ${libs}" ;;
esac
fi
+
+ for lib in ${libs}; do
+ # The "=" is harmless if we aren't using a sysroot, but also needless.
+ if [ "x${use_sysroot}" = "xyes" ] ; then
+ lib="=${lib}"
+ fi
+ addsuffix=
+ case "${LIBPATH_SUFFIX}:${lib}" in
+ :*) ;;
+ *:*${LIBPATH_SUFFIX}) ;;
+ *) addsuffix=yes ;;
+ esac
+ if test -n "$addsuffix"; then
+ case :${LIB_PATH}: in
+ *:${lib}${LIBPATH_SUFFIX}:*) ;;
+ ::) LIB_PATH=${lib}${LIBPATH_SUFFIX} ;;
+ *) LIB_PATH=${LIB_PATH}:${lib}${LIBPATH_SUFFIX} ;;
+ esac
+ case :${LIB_PATH}:${LIB_PATH2}: in
+ *:${lib}:*) ;;
+ *::) LIB_PATH2=${lib} ;;
+ *) LIB_PATH2=${LIB_PATH2}:${lib} ;;
+ esac
+ else
+ case :${LIB_PATH2}: in
+ *:${lib}:*) ;;
+ ::) LIB_PATH2=${lib} ;;
+ *) LIB_PATH2=${LIB_PATH2}:${lib} ;;
+ esac
+ fi
+ done
+
+ case :${LIB_PATH}:${LIB_PATH2}: in
+ *:: | ::*) LIB_PATH=${LIB_PATH}${LIB_PATH2} ;;
+ *) LIB_PATH=${LIB_PATH}:${LIB_PATH2} ;;
+ esac
fi
-# Always search $(tooldir)/lib, aka /usr/local/TARGET/lib.
-LIB_PATH=${tool_lib}:${LIB_PATH}
+# Always search $(tooldir)/lib, aka /usr/local/TARGET/lib, except for
+# sysrooted configurations and when LIBPATH=":".
+if [ "x${use_sysroot}" != "xyes" ] ; then
+ case :${LIB_PATH}: in
+ ::: | *:${tool_lib}:*) ;;
+ ::) LIB_PATH=${tool_lib} ;;
+ *) LIB_PATH=${tool_lib}:${LIB_PATH} ;;
+ esac
+fi
LIB_SEARCH_DIRS=`echo ${LIB_PATH} | sed -e 's/:/ /g' -e 's/\([^ ][^ ]*\)/SEARCH_DIR(\\"\1\\");/g'`
+# We need it for testsuite.
+case " $EMULATION_LIBPATH " in
+ *" ${EMULATION_NAME} "*)
+ test -d tmpdir || mkdir tmpdir
+ test -f tmpdir/libpath.exp || \
+ echo "set libpath \"${LIB_PATH}\"" | sed -e 's/:/ /g' > tmpdir/libpath.exp
+ ;;
+esac
+
# Generate 5 or 6 script files from a master script template in
# ${srcdir}/scripttempl/${SCRIPT_NAME}.sh. Which one of the 5 or 6
# script files is actually used depends on command line options given
@@ -90,10 +224,10 @@ if [ "x$SCRIPT_NAME" = "xelf" ]; then
GENERATE_COMBRELOC_SCRIPT=yes
fi
-SEGMENT_SIZE=${SEGMENT_SIZE-${TARGET_PAGE_SIZE}}
+SEGMENT_SIZE=${SEGMENT_SIZE-${MAXPAGESIZE-${TARGET_PAGE_SIZE}}}
# Determine DATA_ALIGNMENT for the 5 variants, using
-# values specified in the emulparams/<emulation>.sh file or default.
+# values specified in the emulparams/<script_to_run>.sh file or default.
DATA_ALIGNMENT_="${DATA_ALIGNMENT_-${DATA_ALIGNMENT-ALIGN(${SEGMENT_SIZE})}}"
DATA_ALIGNMENT_n="${DATA_ALIGNMENT_n-${DATA_ALIGNMENT_}}"
@@ -105,7 +239,7 @@ LD_FLAG=r
DATA_ALIGNMENT=${DATA_ALIGNMENT_r}
DEFAULT_DATA_ALIGNMENT="ALIGN(${SEGMENT_SIZE})"
( echo "/* Script for ld -r: link without relocation */"
- . ${srcdir}/emulparams/${EMULATION_NAME}.sh
+ . ${CUSTOMIZER_SCRIPT} ${EMULATION_NAME}
. ${srcdir}/scripttempl/${SCRIPT_NAME}.sc
) | sed -e '/^ *$/d;s/[ ]*$//' > ldscripts/${EMULATION_NAME}.xr
@@ -113,7 +247,7 @@ LD_FLAG=u
DATA_ALIGNMENT=${DATA_ALIGNMENT_u}
CONSTRUCTING=" "
( echo "/* Script for ld -Ur: link w/out relocation, do create constructors */"
- . ${srcdir}/emulparams/${EMULATION_NAME}.sh
+ . ${CUSTOMIZER_SCRIPT} ${EMULATION_NAME}
. ${srcdir}/scripttempl/${SCRIPT_NAME}.sc
) | sed -e '/^ *$/d;s/[ ]*$//' > ldscripts/${EMULATION_NAME}.xu
@@ -121,7 +255,7 @@ LD_FLAG=
DATA_ALIGNMENT=${DATA_ALIGNMENT_}
RELOCATING=" "
( echo "/* Default linker script, for normal executables */"
- . ${srcdir}/emulparams/${EMULATION_NAME}.sh
+ . ${CUSTOMIZER_SCRIPT} ${EMULATION_NAME}
. ${srcdir}/scripttempl/${SCRIPT_NAME}.sc
) | sed -e '/^ *$/d;s/[ ]*$//' > ldscripts/${EMULATION_NAME}.x
@@ -129,14 +263,14 @@ LD_FLAG=n
DATA_ALIGNMENT=${DATA_ALIGNMENT_n}
TEXT_START_ADDR=${NONPAGED_TEXT_START_ADDR-${TEXT_START_ADDR}}
( echo "/* Script for -n: mix text and data on same page */"
- . ${srcdir}/emulparams/${EMULATION_NAME}.sh
+ . ${CUSTOMIZER_SCRIPT} ${EMULATION_NAME}
. ${srcdir}/scripttempl/${SCRIPT_NAME}.sc
) | sed -e '/^ *$/d;s/[ ]*$//' > ldscripts/${EMULATION_NAME}.xn
LD_FLAG=N
DATA_ALIGNMENT=${DATA_ALIGNMENT_N}
( echo "/* Script for -N: mix text and data on same page; don't align data */"
- . ${srcdir}/emulparams/${EMULATION_NAME}.sh
+ . ${CUSTOMIZER_SCRIPT} ${EMULATION_NAME}
. ${srcdir}/scripttempl/${SCRIPT_NAME}.sc
) | sed -e '/^ *$/d;s/[ ]*$//' > ldscripts/${EMULATION_NAME}.xbn
@@ -145,7 +279,7 @@ if test -n "$GENERATE_COMBRELOC_SCRIPT"; then
LD_FLAG=c
COMBRELOC=ldscripts/${EMULATION_NAME}.xc.tmp
( echo "/* Script for -z combreloc: combine and sort reloc sections */"
- . ${srcdir}/emulparams/${EMULATION_NAME}.sh
+ . ${CUSTOMIZER_SCRIPT} ${EMULATION_NAME}
. ${srcdir}/scripttempl/${SCRIPT_NAME}.sc
) | sed -e '/^ *$/d;s/[ ]*$//' > ldscripts/${EMULATION_NAME}.xc
rm -f ${COMBRELOC}
@@ -159,7 +293,7 @@ if test -n "$GENERATE_SHLIB_SCRIPT"; then
# Note that TEXT_START_ADDR is set to NONPAGED_TEXT_START_ADDR.
(
echo "/* Script for ld --shared: link shared library */"
- . ${srcdir}/emulparams/${EMULATION_NAME}.sh
+ . ${CUSTOMIZER_SCRIPT} ${EMULATION_NAME}
. ${srcdir}/scripttempl/${SCRIPT_NAME}.sc
) | sed -e '/^ *$/d;s/[ ]*$//' > ldscripts/${EMULATION_NAME}.xs
if test -n "$GENERATE_COMBRELOC_SCRIPT"; then
@@ -167,12 +301,37 @@ if test -n "$GENERATE_SHLIB_SCRIPT"; then
DATA_ALIGNMENT=${DATA_ALIGNMENT_sc-${DATA_ALIGNMENT}}
COMBRELOC=ldscripts/${EMULATION_NAME}.xc.tmp
( echo "/* Script for --shared -z combreloc: shared library, combine & sort relocs */"
- . ${srcdir}/emulparams/${EMULATION_NAME}.sh
+ . ${CUSTOMIZER_SCRIPT} ${EMULATION_NAME}
. ${srcdir}/scripttempl/${SCRIPT_NAME}.sc
) | sed -e '/^ *$/d;s/[ ]*$//' > ldscripts/${EMULATION_NAME}.xsc
rm -f ${COMBRELOC}
COMBRELOC=
fi
+ unset CREATE_SHLIB
+fi
+
+if test -n "$GENERATE_PIE_SCRIPT"; then
+ LD_FLAG=pie
+ DATA_ALIGNMENT=${DATA_ALIGNMENT_s-${DATA_ALIGNMENT_}}
+ CREATE_PIE=" "
+ # Note that TEXT_START_ADDR is set to NONPAGED_TEXT_START_ADDR.
+ (
+ echo "/* Script for ld -pie: link position independent executable */"
+ . ${CUSTOMIZER_SCRIPT} ${EMULATION_NAME}
+ . ${srcdir}/scripttempl/${SCRIPT_NAME}.sc
+ ) | sed -e '/^ *$/d;s/[ ]*$//' > ldscripts/${EMULATION_NAME}.xd
+ if test -n "$GENERATE_COMBRELOC_SCRIPT"; then
+ LD_FLAG=cpie
+ DATA_ALIGNMENT=${DATA_ALIGNMENT_sc-${DATA_ALIGNMENT}}
+ COMBRELOC=ldscripts/${EMULATION_NAME}.xc.tmp
+ ( echo "/* Script for -pie -z combreloc: position independent executable, combine & sort relocs */"
+ . ${CUSTOMIZER_SCRIPT} ${EMULATION_NAME}
+ . ${srcdir}/scripttempl/${SCRIPT_NAME}.sc
+ ) | sed -e '/^ *$/d;s/[ ]*$//' > ldscripts/${EMULATION_NAME}.xdc
+ rm -f ${COMBRELOC}
+ COMBRELOC=
+ fi
+ unset CREATE_PIE
fi
case " $EMULATION_LIBPATH " in
diff --git a/contrib/binutils/ld/h8-doc.texi b/contrib/binutils/ld/h8-doc.texi
index f3c62a1..bbb1fd9 100644
--- a/contrib/binutils/ld/h8-doc.texi
+++ b/contrib/binutils/ld/h8-doc.texi
@@ -4,7 +4,7 @@
@c 2. Specific target machines
@set H8300
-@set Hitachi
+@set Renesas
@clear I960
@c 3. Properties of this configuration
diff --git a/contrib/binutils/ld/ld.h b/contrib/binutils/ld/ld.h
index 438e00d..dde4cfe 100644
--- a/contrib/binutils/ld/ld.h
+++ b/contrib/binutils/ld/ld.h
@@ -70,7 +70,7 @@ name_list;
struct wildcard_spec {
const char *name;
struct name_list *exclude_name_list;
- boolean sorted;
+ bfd_boolean sorted;
};
struct wildcard_list {
@@ -93,11 +93,11 @@ typedef struct user_section_struct {
typedef struct {
/* 1 => assign space to common symbols even if `relocatable_output'. */
- boolean force_common_definition;
+ bfd_boolean force_common_definition;
/* 1 => do not assign addresses to common symbols. */
- boolean inhibit_common_definition;
- boolean relax;
+ bfd_boolean inhibit_common_definition;
+ bfd_boolean relax;
/* Name of runtime interpreter to invoke. */
char *interpreter;
@@ -115,22 +115,22 @@ typedef struct {
/* Big or little endian as set on command line. */
enum { ENDIAN_UNSET = 0, ENDIAN_BIG, ENDIAN_LITTLE } endian;
- /* If true, build MIPS embedded PIC relocation tables in the output
+ /* If TRUE, build MIPS embedded PIC relocation tables in the output
file. */
- boolean embedded_relocs;
+ bfd_boolean embedded_relocs;
- /* If true, force generation of a file with a .exe file. */
- boolean force_exe_suffix;
+ /* If TRUE, force generation of a file with a .exe file. */
+ bfd_boolean force_exe_suffix;
- /* If true, generate a cross reference report. */
- boolean cref;
+ /* If TRUE, generate a cross reference report. */
+ bfd_boolean cref;
- /* If true (which is the default), warn about mismatched input
+ /* If TRUE (which is the default), warn about mismatched input
files. */
- boolean warn_mismatch;
+ bfd_boolean warn_mismatch;
/* Remove unreferenced sections? */
- boolean gc_sections;
+ bfd_boolean gc_sections;
/* Name of shared object whose symbol table should be filtered with
this shared object. From the --filter option. */
@@ -144,9 +144,15 @@ typedef struct {
.exports sections. */
char *version_exports_section;
- /* If true (the default) check section addresses, once compute,
+ /* If TRUE (the default) check section addresses, once compute,
fpor overlaps. */
- boolean check_section_addresses;
+ bfd_boolean check_section_addresses;
+
+ /* If TRUE allow the linking of input files in an unknown architecture
+ assuming that the user knows what they are doing. This was the old
+ behaviour of the linker. The new default behaviour is to reject such
+ input files. */
+ bfd_boolean accept_unknown_input_arch;
} args_type;
@@ -156,60 +162,60 @@ typedef int token_code_type;
typedef struct {
bfd_size_type specified_data_size;
- boolean magic_demand_paged;
- boolean make_executable;
+ bfd_boolean magic_demand_paged;
+ bfd_boolean make_executable;
- /* If true, doing a dynamic link. */
- boolean dynamic_link;
+ /* If TRUE, doing a dynamic link. */
+ bfd_boolean dynamic_link;
- /* If true, -shared is supported. */
+ /* If TRUE, -shared is supported. */
/* ??? A better way to do this is perhaps to define this in the
ld_emulation_xfer_struct since this is really a target dependent
parameter. */
- boolean has_shared;
+ bfd_boolean has_shared;
- /* If true, build constructors. */
- boolean build_constructors;
+ /* If TRUE, build constructors. */
+ bfd_boolean build_constructors;
- /* If true, warn about any constructors. */
- boolean warn_constructors;
+ /* If TRUE, warn about any constructors. */
+ bfd_boolean warn_constructors;
- /* If true, warn about merging common symbols with others. */
- boolean warn_common;
+ /* If TRUE, warn about merging common symbols with others. */
+ bfd_boolean warn_common;
- /* If true, only warn once about a particular undefined symbol. */
- boolean warn_once;
+ /* If TRUE, only warn once about a particular undefined symbol. */
+ bfd_boolean warn_once;
- /* If true, warn if multiple global-pointers are needed (Alpha
+ /* If TRUE, warn if multiple global-pointers are needed (Alpha
only). */
- boolean warn_multiple_gp;
+ bfd_boolean warn_multiple_gp;
- /* If true, warn if the starting address of an output section
+ /* If TRUE, warn if the starting address of an output section
changes due to the alignment of an input section. */
- boolean warn_section_align;
+ bfd_boolean warn_section_align;
- /* If true, warning messages are fatal */
- boolean fatal_warnings;
+ /* If TRUE, warning messages are fatal */
+ bfd_boolean fatal_warnings;
- boolean sort_common;
+ bfd_boolean sort_common;
- boolean text_read_only;
+ bfd_boolean text_read_only;
char *map_filename;
FILE *map_file;
- boolean stats;
+ bfd_boolean stats;
/* If set, orphan input sections will be mapped to separate output
sections. */
- boolean unique_orphan_sections;
+ bfd_boolean unique_orphan_sections;
unsigned int split_by_reloc;
bfd_size_type split_by_file;
/* If set, only search library directories explicitly selected
on the command line. */
- boolean only_cmd_line_lib_dirs;
+ bfd_boolean only_cmd_line_lib_dirs;
} ld_config_type;
extern ld_config_type config;
@@ -221,23 +227,20 @@ typedef enum {
} lang_phase_type;
extern FILE * saved_script_handle;
-extern boolean force_make_executable;
+extern bfd_boolean force_make_executable;
/* Non-zero if we are processing a --defsym from the command line. */
extern int parsing_defsym;
-extern int yyparse PARAMS ((void));
-
-extern void add_cref PARAMS ((const char *, bfd *, asection *, bfd_vma));
-extern void output_cref PARAMS ((FILE *));
-extern void check_nocrossrefs PARAMS ((void));
-
-extern void ld_abort PARAMS ((const char *, int, const char *))
- ATTRIBUTE_NORETURN;
+extern int yyparse (void);
+extern void add_cref (const char *, bfd *, asection *, bfd_vma);
+extern void output_cref (FILE *);
+extern void check_nocrossrefs (void);
+extern void ld_abort (const char *, int, const char *) ATTRIBUTE_NORETURN;
/* If gcc >= 2.6, we can give a function name, too. */
#if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 6)
-#define __PRETTY_FUNCTION__ ((char*) NULL)
+#define __PRETTY_FUNCTION__ NULL
#endif
#undef abort
diff --git a/contrib/binutils/ld/ld.texinfo b/contrib/binutils/ld/ld.texinfo
index 789e894..4310c12 100644
--- a/contrib/binutils/ld/ld.texinfo
+++ b/contrib/binutils/ld/ld.texinfo
@@ -1,7 +1,7 @@
\input texinfo
@setfilename ld.info
@c Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
-@c 2001, 2002 Free Software Foundation, Inc.
+@c 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
@syncodeindex ky cp
@include configdoc.texi
@c (configdoc.texi is generated by the Makefile)
@@ -36,13 +36,16 @@
@set MCORE
@set MIPS
@set MMIX
+@set MSP430
@set PDP11
@set PJ
@set SH
@set SPARC
-@set C54X
+@set TIC54X
@set V850
@set VAX
+@set WIN32
+@set XTENSA
@end ifset
@c man end
@@ -58,7 +61,7 @@ END-INFO-DIR-ENTRY
This file documents the @sc{gnu} linker LD version @value{VERSION}.
Copyright (C) 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000,
-2001, 2002 Free Software Foundation, Inc.
+2001, 2002, 2003, 2004 Free Software Foundation, Inc.
@ignore
@@ -67,7 +70,7 @@ under the terms of the GNU Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
-section entitled "GNU Free Documentation License".
+section entitled ``GNU Free Documentation License''.
Permission is granted to process this file through Tex and print the
results, provided the printed document carries copying permission
@@ -102,14 +105,15 @@ notice identical to this one except for the removal of this paragraph
@vskip 0pt plus 1filll
@c man begin COPYRIGHT
-Copyright @copyright{} 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001 Free Software Foundation, Inc.
+Copyright @copyright{} 1991, 92, 93, 94, 95, 96, 97, 98, 99, 2000, 2001,
+2002, 2003, 2004 Free Software Foundation, Inc.
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.1
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
-section entitled "GNU Free Documentation License".
+section entitled ``GNU Free Documentation License''.
@c man end
@end titlepage
@@ -123,7 +127,7 @@ This file documents the @sc{gnu} linker ld version @value{VERSION}.
This document is distributed under the terms of the GNU Free
Documentation License. A copy of the license is included in the
-section entitled "GNU Free Documentation License".
+section entitled ``GNU Free Documentation License''.
@menu
* Overview:: Overview
@@ -136,15 +140,27 @@ section entitled "GNU Free Documentation License".
@ifset H8300
* H8/300:: ld and the H8/300
@end ifset
-@ifset Hitachi
-* Hitachi:: ld and other Hitachi micros
+@ifset Renesas
+* Renesas:: ld and other Renesas micros
@end ifset
@ifset I960
* i960:: ld and the Intel 960 family
@end ifset
+@ifset ARM
+* ARM:: ld and the ARM family
+@end ifset
+@ifset HPPA
+* HPPA ELF32:: ld and HPPA 32-bit ELF
+@end ifset
@ifset TICOFF
* TI COFF:: ld and the TI COFF
@end ifset
+@ifset WIN32
+* Win32:: ld and WIN32 (cygwin/mingw)
+@end ifset
+@ifset XTENSA
+* Xtensa:: ld and Xtensa Processors
+@end ifset
@end ifclear
@ifclear SingleFormat
* BFD:: BFD
@@ -274,7 +290,7 @@ and the script command language. If @emph{no} binary input files at all
are specified, the linker does not produce any output, and issues the
message @samp{No input files}.
-If the linker can not recognize the format of an object file, it will
+If the linker cannot recognize the format of an object file, it will
assume that it is a linker script. A script specified in this way
augments the main linker script used for the link (either the default
linker script or the one specified by using @samp{-T}). This feature
@@ -292,7 +308,7 @@ option that requires them.
For options whose names are multiple letters, either one dash or two can
precede the option name; for example, @samp{-trace-symbol} and
-@samp{--trace-symbol} are equivalent. Note - there is one exception to
+@samp{--trace-symbol} are equivalent. Note---there is one exception to
this rule. Multiple letter options that start with a lower case 'o' can
only be preceeded by two dashes. This is to reduce confusion with the
@samp{-o} option. So for example @samp{-omagic} sets the output file
@@ -306,8 +322,8 @@ immediately following the option that requires them. For example,
Unique abbreviations of the names of multiple-letter options are
accepted.
-Note - if the linker is being invoked indirectly, via a compiler driver
-(eg @samp{gcc}) then all the linker command line options should be
+Note---if the linker is being invoked indirectly, via a compiler driver
+(e.g. @samp{gcc}) then all the linker command line options should be
prefixed by @samp{-Wl,} (or whatever is appropriate for the particular
compiler driver) like this:
@@ -452,6 +468,7 @@ You can also use the version script to control what symbols should
be added to the dynamic symbol table if the output format supports it.
See the description of @samp{--version-script} in @ref{VERSION}.
+@ifclear SingleFormat
@cindex big-endian objects
@cindex endianness
@kindex -EB
@@ -462,6 +479,7 @@ Link big-endian objects. This affects the default output format.
@kindex -EL
@item -EL
Link little-endian objects. This affects the default output format.
+@end ifclear
@kindex -f
@kindex --auxiliary
@@ -504,11 +522,15 @@ used to select a subset of the symbols provided by the object
Some older linkers used the @option{-F} option throughout a compilation
toolchain for specifying object-file format for both input and output
-object files. The @sc{gnu} linker uses other mechanisms for this
-purpose: the @option{-b}, @option{--format}, @option{--oformat} options, the
+object files.
+@ifclear SingleFormat
+The @sc{gnu} linker uses other mechanisms for this purpose: the
+@option{-b}, @option{--format}, @option{--oformat} options, the
@code{TARGET} command in linker scripts, and the @code{GNUTARGET}
-environment variable. The @sc{gnu} linker will ignore the @option{-F}
-option when not creating an ELF shared object.
+environment variable.
+@end ifclear
+The @sc{gnu} linker will ignore the @option{-F} option when not
+creating an ELF shared object.
@cindex finalization function
@kindex -fini
@@ -604,6 +626,9 @@ on the command line are searched before the default directories. All
@option{-L} options apply to all @option{-l} options, regardless of the
order in which the options appear.
+If @var{searchdir} begins with @code{=}, then the @code{=} will be replaced
+by the @dfn{sysroot prefix}, a path specified when the linker is configured.
+
@ifset UsesEnvVars
The default set of paths searched (without being specified with
@samp{-L}) depends on which emulation mode @command{ld} is using, and in
@@ -660,8 +685,19 @@ Turn off page alignment of sections, and mark the output as
@item -N
@itemx --omagic
Set the text and data sections to be readable and writable. Also, do
-not page-align the data segment. If the output format supports Unix
-style magic numbers, mark the output as @code{OMAGIC}.
+not page-align the data segment, and disable linking against shared
+libraries. If the output format supports Unix style magic numbers,
+mark the output as @code{OMAGIC}. Note: Although a writable text section
+is allowed for PE-COFF targets, it does not conform to the format
+specification published by Microsoft.
+
+@kindex --no-omagic
+@cindex OMAGIC
+@item --no-omagic
+This option negates most of the effects of the @option{-N} option. It
+sets the text section to be read-only, and forces the data segment to
+be page-aligned. Note - this option does not enable linking against
+shared libraries. Use @option{-Bdynamic} for this.
@kindex -o @var{output}
@kindex --output=@var{output}
@@ -694,9 +730,9 @@ This option is currently only supported on ELF platforms.
@cindex partial link
@cindex relocatable output
@kindex -r
-@kindex --relocateable
+@kindex --relocatable
@item -r
-@itemx --relocateable
+@itemx --relocatable
Generate relocatable output---i.e., generate an output file that can in
turn serve as input to @command{ld}. This is often called @dfn{partial
linking}. As a side effect, in environments that support standard Unix
@@ -841,29 +877,68 @@ for Solaris compatibility.
@kindex -z @var{keyword}
@item -z @var{keyword}
-The recognized keywords are @code{initfirst}, @code{interpose},
-@code{loadfltr}, @code{nodefaultlib}, @code{nodelete}, @code{nodlopen},
-@code{nodump}, @code{now}, @code{origin}, @code{combreloc}, @code{nocombreloc}
-and @code{nocopyreloc}.
-The other keywords are
-ignored for Solaris compatibility. @code{initfirst} marks the object
-to be initialized first at runtime before any other objects.
-@code{interpose} marks the object that its symbol table interposes
-before all symbols but the primary executable. @code{loadfltr} marks
-the object that its filtees be processed immediately at runtime.
-@code{nodefaultlib} marks the object that the search for dependencies
-of this object will ignore any default library search paths.
-@code{nodelete} marks the object shouldn't be unloaded at runtime.
-@code{nodlopen} marks the object not available to @code{dlopen}.
-@code{nodump} marks the object can not be dumped by @code{dldump}.
-@code{now} marks the object with the non-lazy runtime binding.
-@code{origin} marks the object may contain $ORIGIN.
-@code{defs} disallows undefined symbols.
-@code{muldefs} allows multiple definitions.
-@code{combreloc} combines multiple reloc sections and sorts them
-to make dynamic symbol lookup caching possible.
-@code{nocombreloc} disables multiple reloc sections combining.
-@code{nocopyreloc} disables production of copy relocs.
+The recognized keywords are:
+@table @samp
+
+@item combreloc
+Combines multiple reloc sections and sorts them to make dynamic symbol
+lookup caching possible.
+
+@item defs
+Disallows undefined symbols in object files. Undefined symbols in
+shared libraries are still allowed.
+
+@item initfirst
+This option is only meaningful when building a shared object.
+It marks the object so that its runtime initialization will occur
+before the runtime initialization of any other objects brought into
+the process at the same time. Similarly the runtime finalization of
+the object will occur after the runtime finalization of any other
+objects.
+
+@item interpose
+Marks the object that its symbol table interposes before all symbols
+but the primary executable.
+
+@item loadfltr
+Marks the object that its filters be processed immediately at
+runtime.
+
+@item muldefs
+Allows multiple definitions.
+
+@item nocombreloc
+Disables multiple reloc sections combining.
+
+@item nocopyreloc
+Disables production of copy relocs.
+
+@item nodefaultlib
+Marks the object that the search for dependencies of this object will
+ignore any default library search paths.
+
+@item nodelete
+Marks the object shouldn't be unloaded at runtime.
+
+@item nodlopen
+Marks the object not available to @code{dlopen}.
+
+@item nodump
+Marks the object can not be dumped by @code{dldump}.
+
+@item now
+When generating an executable or shared library, mark it to tell the
+dynamic linker to resolve all symbols when the program is started, or
+when the shared library is linked to using dlopen, instead of
+deferring function call resolution to the point when the function is
+first called.
+
+@item origin
+Marks the object may contain $ORIGIN.
+
+@end table
+
+Other keywords are ignored for Solaris compatibility.
@kindex -(
@cindex groups of archives
@@ -885,6 +960,30 @@ Using this option has a significant performance cost. It is best to use
it only when there are unavoidable circular references between two or
more archives.
+@kindex --accept-unknown-input-arch
+@kindex --no-accept-unknown-input-arch
+@item --accept-unknown-input-arch
+@itemx --no-accept-unknown-input-arch
+Tells the linker to accept input files whose architecture cannot be
+recognised. The assumption is that the user knows what they are doing
+and deliberately wants to link in these unknown input files. This was
+the default behaviour of the linker, before release 2.14. The default
+behaviour from release 2.14 onwards is to reject such input files, and
+so the @samp{--accept-unknown-input-arch} option has been added to
+restore the old behaviour.
+
+@kindex --as-needed
+@kindex --no-as-needed
+@item --as-needed
+@itemx --no-as-needed
+This option affects ELF DT_NEEDED tags for dynamic libraries mentioned
+on the command line after the @option{--as-needed} option. Normally,
+the linker will add a DT_NEEDED tag for each dynamic library mentioned
+on the command line, regardless of whether the library is actually
+needed. @option{--as-needed} causes DT_NEEDED tags to only be emitted
+for libraries that satisfy some reference from regular objects.
+@option{--no-as-needed} restores the default behaviour.
+
@kindex -assert @var{keyword}
@item -assert @var{keyword}
This option is ignored for SunOS compatibility.
@@ -907,8 +1006,8 @@ multiple times on the command line: it affects library searching for
Set the @code{DF_1_GROUP} flag in the @code{DT_FLAGS_1} entry in the dynamic
section. This causes the runtime linker to handle lookups in this
object and its dependencies to be performed only inside the group.
-@option{--no-undefined} is implied. This option is only meaningful on ELF
-platforms which support shared libraries.
+@option{--unresolved-symbols=report-all} is implied. This option is
+only meaningful on ELF platforms which support shared libraries.
@kindex -Bstatic
@kindex -dn
@@ -922,7 +1021,8 @@ Do not link against shared libraries. This is only meaningful on
platforms for which shared libraries are supported. The different
variants of this option are for compatibility with various systems. You
may use this option multiple times on the command line: it affects
-library searching for @option{-l} options which follow it.
+library searching for @option{-l} options which follow it. This
+option also implies @option{--unresolved-symbols=report-all}.
@kindex -Bsymbolic
@item -Bsymbolic
@@ -941,7 +1041,7 @@ been assigned to see if there any overlaps. Normally the linker will
perform this check, and if it finds any overlaps it will produce
suitable error messages. The linker does know about, and does make
allowances for sections in overlays. The default behaviour can be
-restored by using the command line switch @samp{--check-sections}.
+restored by using the command line switch @option{--check-sections}.
@cindex cross reference table
@kindex --cref
@@ -1062,7 +1162,7 @@ Print a summary of all target specific options on the standard output and exit.
@kindex -Map
@item -Map @var{mapfile}
Print a link map to the file @var{mapfile}. See the description of the
-@samp{-M} option, above.
+@option{-M} option, above.
@cindex memory usage
@kindex --no-keep-memory
@@ -1077,9 +1177,11 @@ while linking a large executable.
@kindex -z defs
@item --no-undefined
@itemx -z defs
-Normally when creating a non-symbolic shared library, undefined symbols
-are allowed and left to be resolved by the runtime loader. These options
-disallows such undefined symbols.
+Report unresolved symbol references from regular object files. This
+is done even if the linker is creating a non-symbolic shared library.
+The switch @option{--[no-]allow-shlib-undefined} controls the
+behaviour for reporting unresolved references found in shared
+libraries being linked in.
@kindex --allow-multiple-definition
@kindex -z muldefs
@@ -1090,17 +1192,24 @@ report a fatal error. These options allow multiple definitions and the
first definition will be used.
@kindex --allow-shlib-undefined
+@kindex --no-allow-shlib-undefined
@item --allow-shlib-undefined
-Allow undefined symbols in shared objects even when --no-undefined is
-set. The net result will be that undefined symbols in regular objects
-will still trigger an error, but undefined symbols in shared objects
-will be ignored. The implementation of no_undefined makes the
-assumption that the runtime linker will choke on undefined symbols.
-However there is at least one system (BeOS) where undefined symbols in
-shared libraries is normal since the kernel patches them at load time to
-select which function is most appropriate for the current architecture.
-I.E. dynamically select an appropriate memset function. Apparently it
-is also normal for HPPA shared libraries to have undefined symbols.
+@itemx --no-allow-shlib-undefined
+Allows (the default) or disallows undefined symbols in shared libraries.
+This switch is similar to @option{--no-undefined} except that it
+determines the behaviour when the undefined symbols are in a
+shared library rather than a regular object file. It does not affect
+how undefined symbols in regular object files are handled.
+
+The reason that @option{--allow-shlib-undefined} is the default is that
+the shared library being specified at link time may not be the same as
+the one that is available at load time, so the symbols might actually be
+resolvable at load time. Plus there are some systems, (eg BeOS) where
+undefined symbols in shared libraries is normal. (The kernel patches
+them at load time to select which function is most appropriate
+for the current architecture. This is used for example to dynamically
+select an appropriate memset function). Apparently it is also normal
+for HPPA shared libraries to have undefined symbols.
@kindex --no-undefined-version
@item --no-undefined-version
@@ -1153,6 +1262,18 @@ command @code{OUTPUT_FORMAT} can also specify the output format, but
this option overrides it. @xref{BFD}.
@end ifclear
+@kindex -pie
+@kindex --pic-executable
+@item -pie
+@itemx --pic-executable
+@cindex position independent executables
+Create a position independent executable. This is currently only supported on
+ELF platforms. Position independent executables are similar to shared
+libraries in that they are relocated by the dynamic linker to the virtual
+address the OS chooses for them (which can vary between invocations). Like
+normal dynamically linked executables they can be executed and symbols
+defined in the executable cannot be overridden by shared libraries.
+
@kindex -qmagic
@item -qmagic
This option is ignored for Linux compatibility.
@@ -1175,7 +1296,9 @@ This option is only supported on a few targets.
@ifset I960
@xref{i960,, @command{ld} and the Intel 960 family}.
@end ifset
-
+@ifset XTENSA
+@xref{Xtensa,, @command{ld} and Xtensa Processors}.
+@end ifset
On some platforms, the @samp{--relax} option performs global
optimizations that become possible when the linker resolves addressing
@@ -1375,11 +1498,39 @@ sign (``@key{=}''), and @var{org}.
@item -Tbss @var{org}
@itemx -Tdata @var{org}
@itemx -Ttext @var{org}
-Use @var{org} as the starting address for---respectively---the
-@code{bss}, @code{data}, or the @code{text} segment of the output file.
-@var{org} must be a single hexadecimal integer;
-for compatibility with other linkers, you may omit the leading
-@samp{0x} usually associated with hexadecimal values.
+Same as --section-start, with @code{.bss}, @code{.data} or
+@code{.text} as the @var{sectionname}.
+
+@kindex --unresolved-symbols
+@item --unresolved-symbols=@var{method}
+Determine how to handle unresolved symbols. There are four possible
+values for @samp{method}:
+
+@table @samp
+@item ignore-all
+Do not report any unresolved symbols.
+
+@item report-all
+Report all unresolved symbols. This is the default.
+
+@item ignore-in-object-files
+Report unresolved symbols that are contained in shared libraries, but
+ignore them if they come from regular object files.
+
+@item ignore-in-shared-libs
+Report unresolved symbols that come from regular object files, but
+ignore them if they come from shared libraries. This can be useful
+when creating a dynamic binary and it is known that all the shared
+libraries that it should be referencing are included on the linker's
+command line.
+@end table
+
+The behaviour for shared libraries on their own can also be controlled
+by the @option{--[no-]allow-shlib-undefined} option.
+
+Normally the linker will generate an error message for each reported
+unresolved symbol but the option @option{--warn-unresolved-symbols}
+can change this to a warning.
@kindex --verbose
@cindex verbose
@@ -1394,7 +1545,7 @@ the linker script being used by the linker.
@itemx --version-script=@var{version-scriptfile}
Specify the name of a version script to the linker. This is typically
used when creating shared libraries to specify additional information
-about the version heirarchy for the library being created. This option
+about the version hierarchy for the library being created. This option
is only meaningful on ELF platforms which support shared libraries.
@xref{VERSION}.
@@ -1403,10 +1554,10 @@ is only meaningful on ELF platforms which support shared libraries.
@cindex combining symbols, warnings on
@item --warn-common
Warn when a common symbol is combined with another common symbol or with
-a symbol definition. Unix linkers allow this somewhat sloppy practice,
+a symbol definition. Unix linkers allow this somewhat sloppy practise,
but linkers on some other operating systems do not. This option allows
you to find potential problems from combining global symbols.
-Unfortunately, some C libraries use this practice, so you may get some
+Unfortunately, some C libraries use this practise, so you may get some
warnings about symbols in the libraries as well as in your programs.
There are three kinds of global symbols, illustrated here by C examples:
@@ -1520,6 +1671,17 @@ The address will only be changed if it not explicitly specified; that
is, if the @code{SECTIONS} command does not specify a start address for
the section (@pxref{SECTIONS}).
+@kindex --warn-unresolved-symbols
+@item --warn-unresolved-symbols
+If the linker is going to report an unresolved symbol (see the option
+@option{--unresolved-symbols}) it will normally generate an error.
+This option makes it generate a warning instead.
+
+@kindex --error-unresolved-symbols
+@item --error-unresolved-symbols
+This restores the linker's default behaviour of generating errors when
+it is reporting unresolved symbols.
+
@kindex --whole-archive
@cindex including an entire archive
@item --whole-archive
@@ -1552,9 +1714,9 @@ Here is a trivial example:
@smallexample
void *
-__wrap_malloc (int c)
+__wrap_malloc (size_t c)
@{
- printf ("malloc called with %ld\n", c);
+ printf ("malloc called with %zu\n", c);
return __real_malloc (c);
@}
@end smallexample
@@ -1585,7 +1747,7 @@ those options are only available for ELF systems.
@c man end
-@subsection Options specific to i386 PE targets
+@subsection Options Specific to i386 PE Targets
@c man begin OPTIONS
@@ -1609,25 +1771,28 @@ values by either a space or an equals sign.
@item --add-stdcall-alias
If given, symbols with a stdcall suffix (@@@var{nn}) will be exported
as-is and also with the suffix stripped.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --base-file
@item --base-file @var{file}
Use @var{file} as the name of a file in which to save the base
addresses of all the relocations needed for generating DLLs with
@file{dlltool}.
+[This is an i386 PE specific option]
@kindex --dll
@item --dll
Create a DLL instead of a regular executable. You may also use
@option{-shared} or specify a @code{LIBRARY} in a given @code{.def}
file.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --enable-stdcall-fixup
@kindex --disable-stdcall-fixup
@item --enable-stdcall-fixup
@itemx --disable-stdcall-fixup
If the link finds a symbol that it cannot resolve, it will attempt to
-do "fuzzy linking" by looking for another defined symbol that differs
+do ``fuzzy linking'' by looking for another defined symbol that differs
only in the format of the symbol name (cdecl vs stdcall) and will
resolve that symbol by linking to the match. For example, the
undefined symbol @code{_foo} might be linked to the function
@@ -1639,6 +1804,7 @@ to be usable. If you specify @option{--enable-stdcall-fixup}, this
feature is fully enabled and warnings are not printed. If you specify
@option{--disable-stdcall-fixup}, this feature is disabled and such
mismatches are considered to be errors.
+[This option is specific to the i386 PE targeted port of the linker]
@cindex DLLs, creating
@kindex --export-all-symbols
@@ -1665,11 +1831,13 @@ These cygwin-excludes are: @code{_cygwin_dll_entry@@12},
@code{_fmode}, @code{_impure_ptr}, @code{cygwin_attach_dll},
@code{cygwin_premain0}, @code{cygwin_premain1}, @code{cygwin_premain2},
@code{cygwin_premain3}, and @code{environ}.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --exclude-symbols
@item --exclude-symbols @var{symbol},@var{symbol},...
Specifies a list of symbols which should not be automatically
exported. The symbol names may be delimited by commas or colons.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --exclude-libs
@item --exclude-libs @var{lib},@var{lib},...
@@ -1678,12 +1846,14 @@ exported. The library names may be delimited by commas or colons. Specifying
@code{--exclude-libs ALL} excludes symbols in all archive libraries from
automatic export. Symbols explicitly listed in a .def file are still exported,
regardless of this option.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --file-alignment
@item --file-alignment
Specify the file alignment. Sections in the file will always begin at
file offsets which are multiples of this number. This defaults to
512.
+[This option is specific to the i386 PE targeted port of the linker]
@cindex heap size
@kindex --heap
@@ -1692,6 +1862,7 @@ file offsets which are multiples of this number. This defaults to
Specify the amount of memory to reserve (and optionally commit) to be
used as heap for this program. The default is 1Mb reserved, 4K
committed.
+[This option is specific to the i386 PE targeted port of the linker]
@cindex image base
@kindex --image-base
@@ -1702,35 +1873,43 @@ is loaded. To reduce the need to relocate and improve performance of
your dlls, each should have a unique base address and not overlap any
other dlls. The default is 0x400000 for executables, and 0x10000000
for dlls.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --kill-at
@item --kill-at
If given, the stdcall suffixes (@@@var{nn}) will be stripped from
symbols before they are exported.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --major-image-version
@item --major-image-version @var{value}
-Sets the major number of the "image version". Defaults to 1.
+Sets the major number of the ``image version''. Defaults to 1.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --major-os-version
@item --major-os-version @var{value}
-Sets the major number of the "os version". Defaults to 4.
+Sets the major number of the ``os version''. Defaults to 4.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --major-subsystem-version
@item --major-subsystem-version @var{value}
-Sets the major number of the "subsystem version". Defaults to 4.
+Sets the major number of the ``subsystem version''. Defaults to 4.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --minor-image-version
@item --minor-image-version @var{value}
-Sets the minor number of the "image version". Defaults to 0.
+Sets the minor number of the ``image version''. Defaults to 0.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --minor-os-version
@item --minor-os-version @var{value}
-Sets the minor number of the "os version". Defaults to 0.
+Sets the minor number of the ``os version''. Defaults to 0.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --minor-subsystem-version
@item --minor-subsystem-version @var{value}
-Sets the minor number of the "subsystem version". Defaults to 0.
+Sets the minor number of the ``subsystem version''. Defaults to 0.
+[This option is specific to the i386 PE targeted port of the linker]
@cindex DEF files, creating
@cindex DLLs, creating
@@ -1741,6 +1920,7 @@ file corresponding to the DLL the linker is generating. This DEF file
(which should be called @code{*.def}) may be used to create an import
library with @code{dlltool} or may be used as a reference to
automatically or implicitly exported symbols.
+[This option is specific to the i386 PE targeted port of the linker]
@cindex DLLs, creating
@kindex --out-implib
@@ -1748,9 +1928,10 @@ automatically or implicitly exported symbols.
The linker will create the file @var{file} which will contain an
import lib corresponding to the DLL the linker is generating. This
import lib (which should be called @code{*.dll.a} or @code{*.a}
-may be used to link clients against the generated DLL; this behavior
+may be used to link clients against the generated DLL; this behaviour
makes it possible to skip a separate @code{dlltool} import library
creation step.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --enable-auto-image-base
@item --enable-auto-image-base
@@ -1759,29 +1940,37 @@ using the @code{--image-base} argument. By using a hash generated
from the dllname to create unique image bases for each DLL, in-memory
collisions and relocations which can delay program execution are
avoided.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --disable-auto-image-base
@item --disable-auto-image-base
Do not automatically generate a unique image base. If there is no
user-specified image base (@code{--image-base}) then use the platform
default.
+[This option is specific to the i386 PE targeted port of the linker]
@cindex DLLs, linking to
@kindex --dll-search-prefix
@item --dll-search-prefix @var{string}
-When linking dynamically to a dll without an import library, i
+When linking dynamically to a dll without an import library,
search for @code{<string><basename>.dll} in preference to
-@code{lib<basename>.dll}. This behavior allows easy distinction
+@code{lib<basename>.dll}. This behaviour allows easy distinction
between DLLs built for the various "subplatforms": native, cygwin,
uwin, pw, etc. For instance, cygwin DLLs typically use
@code{--dll-search-prefix=cyg}.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --enable-auto-import
@item --enable-auto-import
Do sophisticated linking of @code{_symbol} to @code{__imp__symbol} for
DATA imports from DLLs, and create the necessary thunking symbols when
-building the DLLs with those DATA exports. This generally will 'just
-work' -- but sometimes you may see this message:
+building the import libraries with those DATA exports. Note: Use of the
+'auto-import' extension will cause the text section of the image file
+to be made writable. This does not conform to the PE-COFF format
+specification published by Microsoft.
+
+Using 'auto-import' generally will 'just work' -- but sometimes you may
+see this message:
"variable '<var>' can't be auto-imported. Please read the
documentation for ld's @code{--enable-auto-import} for details."
@@ -1799,7 +1988,11 @@ the warning, and exit.
There are several ways to address this difficulty, regardless of the
data type of the exported variable:
-One solution is to force one of the 'constants' to be a variable --
+One way is to use --enable-runtime-pseudo-reloc switch. This leaves the task
+of adjusting references in your client code for runtime environment, so
+this method works only when runtime environment supports this feature.
+
+A second solution is to force one of the 'constants' to be a variable --
that is, unknown and un-optimizable at compile time. For arrays,
there are two possibilities: a) make the indexee (the array's address)
a variable, or b) make the 'constant' index a variable. Thus:
@@ -1835,9 +2028,9 @@ extern_ll -->
@{ volatile long long * local_ll=&extern_ll; *local_ll @}
@end example
-A second method of dealing with this difficulty is to abandon
+A third method of dealing with this difficulty is to abandon
'auto-import' for the offending symbol and mark it with
-@code{__declspec(dllimport)}. However, in practice that
+@code{__declspec(dllimport)}. However, in practise that
requires using compile-time #defines to indicate whether you are
building a DLL, building client code that will link to the DLL, or
merely building/linking to a static library. In making the choice
@@ -1886,24 +2079,42 @@ void main(int argc, char **argv)@{
@}
@end example
-A third way to avoid this problem is to re-code your
+A fourth way to avoid this problem is to re-code your
library to use a functional interface rather than a data interface
for the offending variables (e.g. set_foo() and get_foo() accessor
functions).
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --disable-auto-import
@item --disable-auto-import
-Do not attempt to do sophisticalted linking of @code{_symbol} to
+Do not attempt to do sophisticated linking of @code{_symbol} to
@code{__imp__symbol} for DATA imports from DLLs.
+[This option is specific to the i386 PE targeted port of the linker]
+
+@kindex --enable-runtime-pseudo-reloc
+@item --enable-runtime-pseudo-reloc
+If your code contains expressions described in --enable-auto-import section,
+that is, DATA imports from DLL with non-zero offset, this switch will create
+a vector of 'runtime pseudo relocations' which can be used by runtime
+environment to adjust references to such data in your client code.
+[This option is specific to the i386 PE targeted port of the linker]
+
+@kindex --disable-runtime-pseudo-reloc
+@item --disable-runtime-pseudo-reloc
+Do not create pseudo relocations for non-zero offset DATA imports from
+DLLs. This is the default.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --enable-extra-pe-debug
@item --enable-extra-pe-debug
Show additional debug info related to auto-import symbol thunking.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --section-alignment
@item --section-alignment
Sets the section alignment. Sections in memory will always begin at
addresses which are a multiple of this number. Defaults to 0x1000.
+[This option is specific to the i386 PE targeted port of the linker]
@cindex stack size
@kindex --stack
@@ -1912,6 +2123,7 @@ addresses which are a multiple of this number. Defaults to 0x1000.
Specify the amount of memory to reserve (and optionally commit) to be
used as stack for this program. The default is 2Mb reserved, 4K
committed.
+[This option is specific to the i386 PE targeted port of the linker]
@kindex --subsystem
@item --subsystem @var{which}
@@ -1921,6 +2133,7 @@ Specifies the subsystem under which your program will execute. The
legal values for @var{which} are @code{native}, @code{windows},
@code{console}, and @code{posix}. You may optionally set the
subsystem version also.
+[This option is specific to the i386 PE targeted port of the linker]
@end table
@@ -1932,9 +2145,13 @@ subsystem version also.
@c man begin ENVIRONMENT
-You can change the behavior of @command{ld} with the environment variables
-@code{GNUTARGET}, @code{LDEMULATION}, and @code{COLLECT_NO_DEMANGLE}.
+You can change the behaviour of @command{ld} with the environment variables
+@ifclear SingleFormat
+@code{GNUTARGET},
+@end ifclear
+@code{LDEMULATION} and @code{COLLECT_NO_DEMANGLE}.
+@ifclear SingleFormat
@kindex GNUTARGET
@cindex default input format
@code{GNUTARGET} determines the input-file object format if you don't
@@ -1948,6 +2165,7 @@ there is no method of ensuring that the magic number used to specify
object-file formats is unique. However, the configuration procedure for
BFD on each system places the conventional format for that system first
in the search-list, so ambiguities are resolved in favor of convention.
+@end ifclear
@kindex LDEMULATION
@cindex default emulation
@@ -2174,7 +2392,7 @@ In this section we describe the simple linker script commands.
@end menu
@node Entry Point
-@subsection Setting the entry point
+@subsection Setting the Entry Point
@kindex ENTRY(@var{symbol})
@cindex start of execution
@cindex first instruction
@@ -2203,7 +2421,7 @@ The address @code{0}.
@end itemize
@node File Commands
-@subsection Commands dealing with files
+@subsection Commands Dealing with Files
@cindex linker script file commands
Several linker script commands deal with files.
@@ -2232,10 +2450,13 @@ then you can put @samp{INPUT (subr.o)} in your linker script.
In fact, if you like, you can list all of your input files in the linker
script, and then invoke the linker with nothing but a @samp{-T} option.
-The linker will first try to open the file in the current directory. If
-it is not found, the linker will search through the archive library
-search path. See the description of @samp{-L} in @ref{Options,,Command
-Line Options}.
+In case a @dfn{sysroot prefix} is configured, and the filename starts
+with the @samp{/} character, and the script being processed was
+located inside the @dfn{sysroot prefix}, the filename will be looked
+for in the @dfn{sysroot prefix}. Otherwise, the linker will try to
+open the file in the current directory. If it is not found, the
+linker will search through the archive library search path. See the
+description of @samp{-L} in @ref{Options,,Command Line Options}.
If you use @samp{INPUT (-l@var{file})}, @command{ld} will transform the
name to @code{lib@var{file}.a}, as with the command line argument
@@ -2290,7 +2511,7 @@ first file.
@ifclear SingleFormat
@node Format Commands
-@subsection Commands dealing with object file formats
+@subsection Commands Dealing with Object File Formats
A couple of linker script commands deal with object file formats.
@table @code
@@ -2337,7 +2558,7 @@ command is also used to set the format for the output file. @xref{BFD}.
@end ifclear
@node Miscellaneous Commands
-@subsection Other linker script commands
+@subsection Other Linker Script Commands
There are a few other linker scripts commands.
@table @code
@@ -2504,7 +2725,7 @@ If the program references @samp{etext} but does not define it, the
linker will use the definition in the linker script.
@node SECTIONS
-@section SECTIONS command
+@section SECTIONS Command
@kindex SECTIONS
The @code{SECTIONS} command tells the linker how to map input sections
into output sections, and how to place the output sections in memory.
@@ -2561,11 +2782,12 @@ in the first input file. The first section will be at address zero.
@end menu
@node Output Section Description
-@subsection Output section description
+@subsection Output Section Description
The full description of an output section looks like this:
@smallexample
@group
-@var{section} [@var{address}] [(@var{type})] : [AT(@var{lma})]
+@var{section} [@var{address}] [(@var{type})] :
+ [AT(@var{lma})] [SUBALIGN(@var{subsection_align})]
@{
@var{output-section-command}
@var{output-section-command}
@@ -2594,7 +2816,7 @@ a special output section keyword (@pxref{Output Section Keywords})
@end itemize
@node Output Section Name
-@subsection Output section name
+@subsection Output Section Name
@cindex name, section
@cindex section name
The name of the output section is @var{section}. @var{section} must
@@ -2612,7 +2834,7 @@ The output section name @samp{/DISCARD/} is special; @ref{Output Section
Discarding}.
@node Output Section Address
-@subsection Output section address
+@subsection Output Section Description
@cindex address, section
@cindex section address
The @var{address} is an expression for the VMA (the virtual memory
@@ -2659,7 +2881,7 @@ Specifying @var{address} for a section will change the value of the
location counter.
@node Input Section
-@subsection Input section description
+@subsection Input Section Description
@cindex input sections
@cindex mapping input sections to output sections
The most common output section command is an input section description.
@@ -2678,7 +2900,7 @@ map the input files into your memory layout.
@end menu
@node Input Section Basics
-@subsubsection Input section basics
+@subsubsection Input Section Basics
@cindex input section basics
An input section description consists of a file name optionally followed
by a list of section names in parentheses.
@@ -2739,7 +2961,7 @@ though it appeared on the command line. Note that this differs from an
the archive search path.
@node Input Section Wildcards
-@subsubsection Input section wildcard patterns
+@subsubsection Input Section Wildcard Patterns
@cindex input section wildcards
@cindex wildcard file name patterns
@cindex file name wildcard patterns
@@ -2816,7 +3038,7 @@ SECTIONS @{
@end smallexample
@node Input Section Common
-@subsubsection Input section for common symbols
+@subsubsection Input Section for Common Symbols
@cindex common symbol placement
@cindex uninitialized data placement
A special notation is needed for common symbols, because in many object
@@ -2852,7 +3074,7 @@ notation is now considered obsolete. It is equivalent to
@samp{*(COMMON)}.
@node Input Section Keep
-@subsubsection Input section and garbage collection
+@subsubsection Input Section and Garbage Collection
@cindex KEEP
@cindex garbage collection
When link-time garbage collection is in use (@samp{--gc-sections}),
@@ -2862,7 +3084,7 @@ with @code{KEEP()}, as in @code{KEEP(*(.init))} or
@code{KEEP(SORT(*)(.ctors))}.
@node Input Section Example
-@subsubsection Input section example
+@subsubsection Input Section Example
The following example is a complete linker script. It tells the linker
to read all of the sections from file @file{all.o} and place them at the
start of output section @samp{outputa} which starts at location
@@ -2881,11 +3103,15 @@ SECTIONS @{
all.o
foo.o (.input1)
@}
+@end group
+@group
outputb :
@{
foo.o (.input2)
foo1.o (.input1)
@}
+@end group
+@group
outputc :
@{
*(.input1)
@@ -2896,7 +3122,7 @@ SECTIONS @{
@end smallexample
@node Output Section Data
-@subsection Output section data
+@subsection Output Section Data
@cindex data
@cindex section data
@cindex output section data
@@ -2936,7 +3162,7 @@ When the object file format does not have an explicit endianness, as is
true of, for example, S-records, the value will be stored in the
endianness of the first input object file.
-Note - these commands only work inside a section description and not
+Note---these commands only work inside a section description and not
between them, so the following will produce an error from the linker:
@smallexample
SECTIONS @{@ .text : @{@ *(.text) @}@ LONG(1) .data : @{@ *(.data) @}@ @}@
@@ -2973,7 +3199,7 @@ precedence. @xref{Output Section Fill}, for details on the fill
expression.
@node Output Section Keywords
-@subsection Output section keywords
+@subsection Output Section Keywords
There are a couple of keywords which can appear as output section
commands.
@@ -3052,7 +3278,7 @@ scripts.
@end table
@node Output Section Discarding
-@subsection Output section discarding
+@subsection Output Section Discarding
@cindex discarding sections
@cindex sections, discarding
@cindex removing sections
@@ -3076,13 +3302,14 @@ input sections. Any input sections which are assigned to an output
section named @samp{/DISCARD/} are not included in the output file.
@node Output Section Attributes
-@subsection Output section attributes
+@subsection Output Section Attributes
@cindex output section attributes
We showed above that the full description of an output section looked
like this:
@smallexample
@group
-@var{section} [@var{address}] [(@var{type})] : [AT(@var{lma})]
+@var{section} [@var{address}] [(@var{type})] :
+ [AT(@var{lma})] [SUBALIGN(@var{subsection_align})]
@{
@var{output-section-command}
@var{output-section-command}
@@ -3097,13 +3324,14 @@ remaining section attributes.
@menu
* Output Section Type:: Output section type
* Output Section LMA:: Output section LMA
+* Forced Input Alignment:: Forced Input Alignment
* Output Section Region:: Output section region
* Output Section Phdr:: Output section phdr
* Output Section Fill:: Output section fill
@end menu
@node Output Section Type
-@subsubsection Output section type
+@subsubsection Output Section Type
Each output section may have a type. The type is a keyword in
parentheses. The following types are defined:
@@ -3140,7 +3368,7 @@ SECTIONS @{
@end smallexample
@node Output Section LMA
-@subsubsection Output section LMA
+@subsubsection Output Section LMA
@kindex AT>@var{lma_region}
@kindex AT(@var{lma})
@cindex load address
@@ -3153,8 +3381,13 @@ Address}).
The linker will normally set the LMA equal to the VMA. You can change
that by using the @code{AT} keyword. The expression @var{lma} that
follows the @code{AT} keyword specifies the load address of the
-section. Alternatively, with @samp{AT>@var{lma_region}} expression,
-you may specify a memory region for the section's load address. @xref{MEMORY}.
+section.
+
+Alternatively, with @samp{AT>@var{lma_region}} expression, you may
+specify a memory region for the section's load address. @xref{MEMORY}.
+Note that if the section has not had a VMA assigned to it then the
+linker will use the @var{lma_region} as the VMA region as well.
+@xref{Output Section Region}.
@cindex ROM initialized data
@cindex initialized data in ROM
@@ -3204,8 +3437,17 @@ for (dst = &_bstart; dst< &_bend; dst++)
@end group
@end smallexample
+@node Forced Input Alignment
+@subsubsection Forced Input Alignment
+@kindex SUBALIGN(@var{subsection_align})
+@cindex forcing input section alignment
+@cindex input section alignment
+You can force input section alignment within an output section by using
+SUBALIGN. The value specified overrides any alignment given by input
+sections, whether larger or smaller.
+
@node Output Section Region
-@subsubsection Output section region
+@subsubsection Output Section Region
@kindex >@var{region}
@cindex section, assigning to memory region
@cindex memory regions and sections
@@ -3221,7 +3463,7 @@ SECTIONS @{ ROM : @{ *(.text) @} >rom @}
@end smallexample
@node Output Section Phdr
-@subsubsection Output section phdr
+@subsubsection Output Section Phdr
@kindex :@var{phdr}
@cindex section, assigning to program header
@cindex program headers and sections
@@ -3241,7 +3483,7 @@ SECTIONS @{ .text : @{ *(.text) @} :text @}
@end smallexample
@node Output Section Fill
-@subsubsection Output section fill
+@subsubsection Output Section Fill
@kindex =@var{fillexp}
@cindex section fill pattern
@cindex fill pattern, entire section
@@ -3269,7 +3511,7 @@ SECTIONS @{ .text : @{ *(.text) @} =0x90909090 @}
@end smallexample
@node Overlay Description
-@subsection Overlay description
+@subsection Overlay Description
@kindex OVERLAY
@cindex overlays
An overlay description provides an easy way to describe sections which
@@ -3383,7 +3625,7 @@ example could have been written identically as follows.
@end smallexample
@node MEMORY
-@section MEMORY command
+@section MEMORY Command
@kindex MEMORY
@cindex memory regions
@cindex regions of memory
@@ -3718,7 +3960,7 @@ and @samp{bar2} are bound to the version node @samp{VERS_2.0}.
When the linker finds a symbol defined in a library which is not
specifically bound to a version node, it will effectively bind it to an
unspecified base version of the library. You can bind all otherwise
-unspecified symbols to a given version node by using @samp{global: *}
+unspecified symbols to a given version node by using @samp{global: *;}
somewhere in the version script.
The names of the version nodes have no specific meaning other than what
@@ -3732,7 +3974,7 @@ symbols, only selects which symbols will be globally visible out and which
won't.
@smallexample
-@{ global: foo; bar; local: *; @}
+@{ global: foo; bar; local: *; @};
@end smallexample
When you link an application against a shared library that has versioned
@@ -3801,7 +4043,7 @@ you would effectively have multiple definitions of the same symbol.
If you wish to bind a reference to a specific version of the symbol
within the shared library, you can use the aliases of convenience
-(i.e. @samp{old_foo}), or you can use the @samp{.symver} directive to
+(i.e., @samp{old_foo}), or you can use the @samp{.symver} directive to
specifically bind to an external version of the function in question.
You can also specify the language in the version script:
@@ -3857,20 +4099,20 @@ hexadecimal. The linker considers other integers to be decimal.
In addition, you can use the suffixes @code{K} and @code{M} to scale a
constant by
@c TEXI2ROFF-KILL
-@ifinfo
+@ifnottex
@c END TEXI2ROFF-KILL
@code{1024} or @code{1024*1024}
@c TEXI2ROFF-KILL
-@end ifinfo
+@end ifnottex
@tex
${\rm 1024}$ or ${\rm 1024}^2$
@end tex
@c END TEXI2ROFF-KILL
respectively. For example, the following all refer to the same quantity:
@smallexample
- _fourk_1 = 4K;
- _fourk_2 = 4096;
- _fourk_3 = 0x1000;
+_fourk_1 = 4K;
+_fourk_2 = 4096;
+_fourk_3 = 0x1000;
@end smallexample
@node Symbols
@@ -3885,8 +4127,8 @@ Unquoted symbol names must not conflict with any keywords. You can
specify a symbol which contains odd characters or has the same name as a
keyword by surrounding the symbol name in double quotes:
@smallexample
- "SECTION" = 9;
- "with a space" = "also with a space" + 10;
+"SECTION" = 9;
+"with a space" = "also with a space" + 10;
@end smallexample
Since symbols can contain many non-alphabetic characters, it is safest
@@ -3934,7 +4176,7 @@ specifies what data to write in the gaps (@pxref{Output Section Fill}).
@cindex dot inside sections
Note: @code{.} actually refers to the byte offset from the start of the
current containing object. Normally this is the @code{SECTIONS}
-statement, whoes start address is 0, hence @code{.} can be used as an
+statement, whose start address is 0, hence @code{.} can be used as an
absolute address. If @code{.} is used inside a section description
however, it refers to the byte offset from the start of that section,
not an absolute address. Thus in a script like this:
@@ -3973,7 +4215,7 @@ the @samp{.data} output section itself.
The linker recognizes the standard C set of arithmetic operators, with
the standard bindings and precedence levels:
@c TEXI2ROFF-KILL
-@ifinfo
+@ifnottex
@c END TEXI2ROFF-KILL
@smallexample
precedence associativity Operators Notes
@@ -3995,7 +4237,7 @@ Notes:
(1) Prefix operators
(2) @xref{Assignments}.
@c TEXI2ROFF-KILL
-@end ifinfo
+@end ifnottex
@tex
\vskip \baselineskip
%"lispnarrowing" is the extra indent used generally for smallexample
@@ -4153,17 +4395,25 @@ SECTIONS @{ @dots{}
@end group
@end smallexample
-@item ALIGN(@var{exp})
-@kindex ALIGN(@var{exp})
+@item ALIGN(@var{align})
+@itemx ALIGN(@var{exp},@var{align})
+@kindex ALIGN(@var{align})
+@kindex ALIGN(@var{exp},@var{align})
@cindex round up location counter
@cindex align location counter
-Return the location counter (@code{.}) aligned to the next @var{exp}
-boundary.
-@code{ALIGN} doesn't change the value of the location counter---it just
-does arithmetic on it. Here is an example which aligns the output
-@code{.data} section to the next @code{0x2000} byte boundary after the
-preceding section and sets a variable within the section to the next
-@code{0x8000} boundary after the input sections:
+@cindex round up expression
+@cindex align expression
+Return the location counter (@code{.}) or arbitrary expression aligned
+to the next @var{align} boundary. The single operand @code{ALIGN}
+doesn't change the value of the location counter---it just does
+arithmetic on it. The two operand @code{ALIGN} allows an arbitrary
+expression to be aligned upwards (@code{ALIGN(@var{align})} is
+equivalent to @code{ALIGN(., @var{align})}).
+
+Here is an example which aligns the output @code{.data} section to the
+next @code{0x2000} byte boundary after the preceding section and sets a
+variable within the section to the next @code{0x8000} boundary after the
+input sections:
@smallexample
@group
SECTIONS @{ @dots{}
@@ -4231,7 +4481,8 @@ evaluation purposes.
@kindex DEFINED(@var{symbol})
@cindex symbol defaults
Return 1 if @var{symbol} is in the linker global symbol table and is
-defined, otherwise return 0. You can use this function to provide
+defined before the statement using DEFINED in the script, otherwise
+return 0. You can use this function to provide
default values for symbols. For example, the following script fragment
shows how to set a global symbol @samp{begin} to the first location in
the @samp{.text} section---but if a symbol called @samp{begin} already
@@ -4345,21 +4596,36 @@ sections describe them. Machines where @command{ld} has no additional
functionality are not listed.
@menu
-* H8/300:: @code{ld} and the H8/300
-* i960:: @code{ld} and the Intel 960 family
-* ARM:: @code{ld} and the ARM family
-* HPPA ELF32:: @code{ld} and HPPA 32-bit ELF
+@ifset H8300
+* H8/300:: @command{ld} and the H8/300
+@end ifset
+@ifset I960
+* i960:: @command{ld} and the Intel 960 family
+@end ifset
+@ifset ARM
+* ARM:: @command{ld} and the ARM family
+@end ifset
+@ifset HPPA
+* HPPA ELF32:: @command{ld} and HPPA 32-bit ELF
+@end ifset
@ifset MMIX
-* MMIX:: @code{ld} and MMIX
+* MMIX:: @command{ld} and MMIX
+@end ifset
+@ifset MSP430
+* MSP430:: @command{ld} and MSP430
@end ifset
@ifset TICOFF
* TI COFF:: @command{ld} and TI COFF
@end ifset
+@ifset WIN32
+* WIN32:: @command{ld} and WIN32 (cygwin/mingw)
+@end ifset
+@ifset XTENSA
+* Xtensa:: @command{ld} and Xtensa Processors
+@end ifset
@end menu
@end ifset
-@c FIXME! This could use @raisesections/@lowersections, but there seems to be a conflict
-@c between those and node-defaulting.
@ifset H8300
@ifclear GENERIC
@raisesections
@@ -4397,15 +4663,15 @@ top page of memory).
@end ifset
@ifclear GENERIC
-@ifset Hitachi
+@ifset Renesas
@c This stuff is pointless to say unless you're especially concerned
-@c with Hitachi chips; don't enable it for generic case, please.
-@node Hitachi
-@chapter @command{ld} and other Hitachi chips
+@c with Renesas chips; don't enable it for generic case, please.
+@node Renesas
+@chapter @command{ld} and Other Renesas Chips
-@command{ld} also supports the H8/300H, the H8/500, and the Hitachi SH. No
-special features, commands, or command-line options are required for
-these chips.
+@command{ld} also supports the Renesas (formerly Hitachi) H8/300H,
+H8/500, and SH chips. No special features, commands, or command-line
+options are required for these chips.
@end ifset
@end ifclear
@@ -4415,7 +4681,7 @@ these chips.
@end ifclear
@node i960
-@section @command{ld} and the Intel 960 family
+@section @command{ld} and the Intel 960 Family
@cindex i960 support
@@ -4466,12 +4732,13 @@ not itself call any subroutines).
@end ifclear
@end ifset
+@ifset ARM
@ifclear GENERIC
@raisesections
@end ifclear
@node ARM
-@section @command{ld}'s support for interworking between ARM and Thumb code
+@section @command{ld}'s Support for Interworking Between ARM and Thumb Code
@cindex ARM interworking support
@kindex --support-old-code
@@ -4495,8 +4762,18 @@ But it also sets the bottom bit of the address, so that it can be
branched to using a BX instruction, and the program will start
executing in Thumb mode straight away.
+@ifclear GENERIC
+@lowersections
+@end ifclear
+@end ifset
+
+@ifset HPPA
+@ifclear GENERIC
+@raisesections
+@end ifclear
+
@node HPPA ELF32
-@section @command{ld} and HPPA 32-bit ELF support
+@section @command{ld} and HPPA 32-bit ELF Support
@cindex HPPA multiple sub-space stubs
@kindex --multi-subspace
When generating a shared library, @command{ld} will by default generate
@@ -4527,10 +4804,19 @@ single input section larger than the group size specified will of course
create a larger group (of one section). If input sections are too
large, it may not be possible for a branch to reach its stub.
+@ifclear GENERIC
+@lowersections
+@end ifclear
+@end ifset
+
@ifset MMIX
+@ifclear GENERIC
+@raisesections
+@end ifclear
+
@node MMIX
@section @code{ld} and MMIX
-For MMIX, there is choice of generating @code{ELF} object files or
+For MMIX, there is a choice of generating @code{ELF} object files or
@code{mmo} object files when linking. The simulator @code{mmix}
understands the @code{mmo} format. The binutils @code{objcopy} utility
can translate between the two formats.
@@ -4551,11 +4837,60 @@ script uses these to set the default start address of a section.
Initial and trailing multiples of zero-valued 32-bit words in a section,
are left out from an mmo file.
+
+@ifclear GENERIC
+@lowersections
+@end ifclear
+@end ifset
+
+@ifset MSP430
+@ifclear GENERIC
+@raisesections
+@end ifclear
+
+@node MSP430
+@section @code{ld} and MSP430
+For the MSP430 it is possible to select the MPU architecture. The flag @samp{-m [mpu type]}
+will select an appropriate linker script for selected MPU type. (To get a list of known MPUs
+just pass @samp{-m help} option to the linker).
+
+@cindex MSP430 extra sections
+The linker will recognize some extra sections which are MSP430 specific:
+
+@table @code
+@item @samp{.vectors}
+Defines a portion of ROM where interrupt vectors located.
+
+@item @samp{.bootloader}
+Defines the bootloader portion of the ROM (if applicable). Any code
+in this section will be uploaded to the MPU.
+
+@item @samp{.infomem}
+Defines an information memory section (if applicable). Any code in
+this section will be uploaded to the MPU.
+
+@item @samp{.infomemnobits}
+This is the same as the @samp{.infomem} section except that any code
+in this section will not be uploaded to the MPU.
+
+@item @samp{.noinit}
+Denotes a portion of RAM located above @samp{.bss} section.
+
+The last two sections are used by gcc.
+@end table
+
+@ifclear GENERIC
+@lowersections
+@end ifclear
@end ifset
@ifset TICOFF
+@ifclear GENERIC
+@raisesections
+@end ifclear
+
@node TI COFF
-@section @command{ld}'s support for various TI COFF versions
+@section @command{ld}'s Support for Various TI COFF Versions
@cindex TI COFF versions
@kindex --format=@var{version}
The @samp{--format} switch allows selection of one of the various
@@ -4563,11 +4898,427 @@ TI COFF versions. The latest of this writing is 2; versions 0 and 1 are
also supported. The TI COFF versions also vary in header byte-order
format; @command{ld} will read any version or byte order, but the output
header format depends on the default specified by the specific target.
+
+@ifclear GENERIC
+@lowersections
+@end ifclear
@end ifset
+@ifset WIN32
+@ifclear GENERIC
+@raisesections
+@end ifclear
+
+@node WIN32
+@section @command{ld} and WIN32 (cygwin/mingw)
+
+This section describes some of the win32 specific @command{ld} issues.
+See @ref{Options,,Command Line Options} for detailed decription of the
+command line options mentioned here.
+
+@table @emph
+@cindex import libraries
+@item import libraries
+The standard Windows linker creates and uses so-called import
+libraries, which contains information for linking to dll's. They are
+regular static archives and are handled as any other static
+archive. The cygwin and mingw ports of @command{ld} have specific
+support for creating such libraries provided with the
+@samp{--out-implib} command line option.
+
+@item exporting DLL symbols
+@cindex exporting DLL symbols
+The cygwin/mingw @command{ld} has several ways to export symbols for dll's.
+
+@table @emph
+@item using auto-export functionality
+@cindex using auto-export functionality
+By default @command{ld} exports symbols with the auto-export functionality,
+which is controlled by the following command line options:
+
+@itemize
+@item --export-all-symbols [This is the default]
+@item --exclude-symbols
+@item --exclude-libs
+@end itemize
+
+If, however, @samp{--export-all-symbols} is not given explicitly on the
+command line, then the default auto-export behavior will be @emph{disabled}
+if either of the following are true:
+
+@itemize
+@item A DEF file is used.
+@item Any symbol in any object file was marked with the __declspec(dllexport) attribute.
+@end itemize
+
+@item using a DEF file
+@cindex using a DEF file
+Another way of exporting symbols is using a DEF file. A DEF file is
+an ASCII file containing definitions of symbols which should be
+exported when a dll is created. Usually it is named @samp{<dll
+name>.def} and is added as any other object file to the linker's
+command line. The file's name must end in @samp{.def} or @samp{.DEF}.
+
+@example
+gcc -o <output> <objectfiles> <dll name>.def
+@end example
+
+Using a DEF file turns off the normal auto-export behavior, unless the
+@samp{--export-all-symbols} option is also used.
+
+Here is an example of a DEF file for a shared library called @samp{xyz.dll}:
+
+@example
+LIBRARY "xyz.dll" BASE=0x10000000
+
+EXPORTS
+foo
+bar
+_bar = bar
+@end example
+
+This example defines a base address and three symbols. The third
+symbol is an alias for the second. For the complete format
+specification see ld/deffilep.y in the binutils sources.
+
+@cindex creating a DEF file
+While linking a shared dll, @command{ld} is able to create a DEF file
+with the @samp{--output-def <file>} command line option.
+
+@item Using decorations
+@cindex Using decorations
+Another way of marking symbols for export is to modify the source code
+itself, so that when building the DLL each symbol to be exported is
+declared as:
+
+@example
+__declspec(dllexport) int a_variable
+__declspec(dllexport) void a_function(int with_args)
+@end example
+
+All such symbols will be exported from the DLL. If, however,
+any of the object files in the DLL contain symbols decorated in
+this way, then the normal auto-export behavior is disabled, unless
+the @samp{--export-all-symbols} option is also used.
+
+Note that object files that wish to access these symbols must @emph{not}
+decorate them with dllexport. Instead, they should use dllimport,
+instead:
+
+@example
+__declspec(dllimport) int a_variable
+__declspec(dllimport) void a_function(int with_args)
+@end example
+
+This complicates the structure of library header files, because
+when included by the library itself the header must declare the
+variables and functions as dllexport, but when included by client
+code the header must declare them as dllimport. There are a number
+of idioms that are typically used to do this; often client code can
+omit the __declspec() declaration completely. See
+@samp{--enable-auto-import} and @samp{automatic data imports} for more
+imformation.
+@end table
+
+@cindex automatic data imports
+@item automatic data imports
+The standard Windows dll format supports data imports from dlls only
+by adding special decorations (dllimport/dllexport), which let the
+compiler produce specific assembler instructions to deal with this
+issue. This increases the effort necessary to port existing Un*x
+code to these platforms, especially for large
+c++ libraries and applications. The auto-import feature, which was
+initially provided by Paul Sokolovsky, allows one to omit the
+decorations to archieve a behavior that conforms to that on POSIX/Un*x
+platforms. This feature is enabled with the @samp{--enable-auto-import}
+command-line option, although it is enabled by default on cygwin/mingw.
+The @samp{--enable-auto-import} option itself now serves mainly to
+suppress any warnings that are ordinarily emitted when linked objects
+trigger the feature's use.
+
+auto-import of variables does not always work flawlessly without
+additional assistance. Sometimes, you will see this message
+
+"variable '<var>' can't be auto-imported. Please read the
+documentation for ld's @code{--enable-auto-import} for details."
+
+The @samp{--enable-auto-import} documentation explains why this error
+occurs, and several methods that can be used to overcome this difficulty.
+One of these methods is the @emph{runtime pseudo-relocs} feature, described
+below.
+
+@cindex runtime pseudo-relocation
+For complex variables imported from DLLs (such as structs or classes),
+object files typically contain a base address for the variable and an
+offset (@emph{addend}) within the variable--to specify a particular
+field or public member, for instance. Unfortunately, the runtime loader used
+in win32 environments is incapable of fixing these references at runtime
+without the additional information supplied by dllimport/dllexport decorations.
+The standard auto-import feature described above is unable to resolve these
+references.
+
+The @samp{--enable-runtime-pseudo-relocs} switch allows these references to
+be resolved without error, while leaving the task of adjusting the references
+themselves (with their non-zero addends) to specialized code provided by the
+runtime environment. Recent versions of the cygwin and mingw environments and
+compilers provide this runtime support; older versions do not. However, the
+support is only necessary on the developer's platform; the compiled result will
+run without error on an older system.
+
+@samp{--enable-runtime-pseudo-relocs} is not the default; it must be explicitly
+enabled as needed.
+
+@cindex direct linking to a dll
+@item direct linking to a dll
+The cygwin/mingw ports of @command{ld} support the direct linking,
+including data symbols, to a dll without the usage of any import
+libraries. This is much faster and uses much less memory than does the
+traditional import library method, expecially when linking large
+libraries or applications. When @command{ld} creates an import lib, each
+function or variable exported from the dll is stored in its own bfd, even
+though a single bfd could contain many exports. The overhead involved in
+storing, loading, and processing so many bfd's is quite large, and explains the
+tremendous time, memory, and storage needed to link against particularly
+large or complex libraries when using import libs.
+
+Linking directly to a dll uses no extra command-line switches other than
+@samp{-L} and @samp{-l}, because @command{ld} already searches for a number
+of names to match each library. All that is needed from the developer's
+perspective is an understanding of this search, in order to force ld to
+select the dll instead of an import library.
+
+
+For instance, when ld is called with the argument @samp{-lxxx} it will attempt
+to find, in the first directory of its search path,
+
+@example
+libxxx.dll.a
+xxx.dll.a
+libxxx.a
+cygxxx.dll (*)
+libxxx.dll
+xxx.dll
+@end example
+
+before moving on to the next directory in the search path.
+
+(*) Actually, this is not @samp{cygxxx.dll} but in fact is @samp{<prefix>xxx.dll},
+where @samp{<prefix>} is set by the @command{ld} option
+@samp{--dll-search-prefix=<prefix>}. In the case of cygwin, the standard gcc spec
+file includes @samp{--dll-search-prefix=cyg}, so in effect we actually search for
+@samp{cygxxx.dll}.
+
+Other win32-based unix environments, such as mingw or pw32, may use other
+@samp{<prefix>}es, although at present only cygwin makes use of this feature. It
+was originally intended to help avoid name conflicts among dll's built for the
+various win32/un*x environments, so that (for example) two versions of a zlib dll
+could coexist on the same machine.
+
+The generic cygwin/mingw path layout uses a @samp{bin} directory for
+applications and dll's and a @samp{lib} directory for the import
+libraries (using cygwin nomenclature):
+
+@example
+bin/
+ cygxxx.dll
+lib/
+ libxxx.dll.a (in case of dll's)
+ libxxx.a (in case of static archive)
+@end example
+
+Linking directly to a dll without using the import library can be
+done two ways:
+
+1. Use the dll directly by adding the @samp{bin} path to the link line
+@example
+gcc -Wl,-verbose -o a.exe -L../bin/ -lxxx
+@end example
+
+However, as the dll's often have version numbers appended to their names
+(@samp{cygncurses-5.dll}) this will often fail, unless one specifies
+@samp{-L../bin -lncurses-5} to include the version. Import libs are generally
+not versioned, and do not have this difficulty.
+
+2. Create a symbolic link from the dll to a file in the @samp{lib}
+directory according to the above mentioned search pattern. This
+should be used to avoid unwanted changes in the tools needed for
+making the app/dll.
+
+@example
+ln -s bin/cygxxx.dll lib/[cyg|lib|]xxx.dll[.a]
+@end example
+
+Then you can link without any make environment changes.
+
+@example
+gcc -Wl,-verbose -o a.exe -L../lib/ -lxxx
+@end example
+
+This technique also avoids the version number problems, because the following is
+perfectly legal
+
+@example
+bin/
+ cygxxx-5.dll
+lib/
+ libxxx.dll.a -> ../bin/cygxxx-5.dll
+@end example
+
+Linking directly to a dll without using an import lib will work
+even when auto-import features are exercised, and even when
+@samp{--enable-runtime-pseudo-relocs} is used.
+
+Given the improvements in speed and memory usage, one might justifiably
+wonder why import libraries are used at all. There are two reasons:
+
+1. Until recently, the link-directly-to-dll functionality did @emph{not}
+work with auto-imported data.
+
+2. Sometimes it is necessary to include pure static objects within the
+import library (which otherwise contains only bfd's for indirection
+symbols that point to the exports of a dll). Again, the import lib
+for the cygwin kernel makes use of this ability, and it is not
+possible to do this without an import lib.
+
+So, import libs are not going away. But the ability to replace
+true import libs with a simple symbolic link to (or a copy of)
+a dll, in most cases, is a useful addition to the suite of tools
+binutils makes available to the win32 developer. Given the
+massive improvements in memory requirements during linking, storage
+requirements, and linking speed, we expect that many developers
+will soon begin to use this feature whenever possible.
+
+@item symbol aliasing
+@table @emph
+@item adding additional names
+Sometimes, it is useful to export symbols with additional names.
+A symbol @samp{foo} will be exported as @samp{foo}, but it can also be
+exported as @samp{_foo} by using special directives in the DEF file
+when creating the dll. This will affect also the optional created
+import library. Consider the following DEF file:
+
+@example
+LIBRARY "xyz.dll" BASE=0x61000000
+
+EXPORTS
+foo
+_foo = foo
+@end example
+
+The line @samp{_foo = foo} maps the symbol @samp{foo} to @samp{_foo}.
+
+Another method for creating a symbol alias is to create it in the
+source code using the "weak" attribute:
+
+@example
+void foo () @{ /* Do something. */; @}
+void _foo () __attribute__ ((weak, alias ("foo")));
+@end example
+
+See the gcc manual for more information about attributes and weak
+symbols.
+
+@item renaming symbols
+Sometimes it is useful to rename exports. For instance, the cygwin
+kernel does this regularly. A symbol @samp{_foo} can be exported as
+@samp{foo} but not as @samp{_foo} by using special directives in the
+DEF file. (This will also affect the import library, if it is
+created). In the following example:
+
+@example
+LIBRARY "xyz.dll" BASE=0x61000000
+
+EXPORTS
+_foo = foo
+@end example
+
+The line @samp{_foo = foo} maps the exported symbol @samp{foo} to
+@samp{_foo}.
+@end table
+
+Note: using a DEF file disables the default auto-export behavior,
+unless the @samp{--export-all-symbols} command line option is used.
+If, however, you are trying to rename symbols, then you should list
+@emph{all} desired exports in the DEF file, including the symbols
+that are not being renamed, and do @emph{not} use the
+@samp{--export-all-symbols} option. If you list only the
+renamed symbols in the DEF file, and use @samp{--export-all-symbols}
+to handle the other symbols, then the both the new names @emph{and}
+the original names for the renamed symbols will be exported.
+In effect, you'd be aliasing those symbols, not renaming them,
+which is probably not what you wanted.
+@end table
+
@ifclear GENERIC
@lowersections
@end ifclear
+@end ifset
+
+@ifset XTENSA
+@ifclear GENERIC
+@raisesections
+@end ifclear
+
+@node Xtensa
+@section @code{ld} and Xtensa Processors
+
+@cindex Xtensa processors
+The default @command{ld} behavior for Xtensa processors is to interpret
+@code{SECTIONS} commands so that lists of explicitly named sections in a
+specification with a wildcard file will be interleaved when necessary to
+keep literal pools within the range of PC-relative load offsets. For
+example, with the command:
+
+@smallexample
+SECTIONS
+@{
+ .text : @{
+ *(.literal .text)
+ @}
+@}
+@end smallexample
+
+@noindent
+@command{ld} may interleave some of the @code{.literal}
+and @code{.text} sections from different object files to ensure that the
+literal pools are within the range of PC-relative load offsets. A valid
+interleaving might place the @code{.literal} sections from an initial
+group of files followed by the @code{.text} sections of that group of
+files. Then, the @code{.literal} sections from the rest of the files
+and the @code{.text} sections from the rest of the files would follow.
+The non-interleaved order can still be specified as:
+
+@smallexample
+SECTIONS
+@{
+ .text : @{
+ *(.literal) *(.text)
+ @}
+@}
+@end smallexample
+
+@cindex @code{--relax} on Xtensa
+@cindex relaxing on Xtensa
+@kindex --no-relax
+The Xtensa version of @command{ld} enables the @option{--relax} option by
+default to attempt to reduce space in the output image by combining
+literals with identical values. It also provides the
+@option{--no-relax} option to disable this optimization. When enabled,
+the relaxation algorithm ensures that a literal will only be merged with
+another literal when the new merged literal location is within the
+offset range of all of its uses.
+
+The relaxation mechanism will also attempt to optimize
+assembler-generated ``longcall'' sequences of
+@code{L32R}/@code{CALLX@var{n}} when the target is known to fit into a
+@code{CALL@var{n}} instruction encoding. The current optimization
+converts the sequence into @code{NOP}/@code{CALL@var{n}} and removes the
+literal referenced by the @code{L32R} instruction.
+
+@ifclear GENERIC
+@lowersections
+@end ifclear
+@end ifset
@ifclear SingleFormat
@node BFD
@@ -4607,7 +5358,7 @@ conversion and during output. @xref{BFD information loss}.
@end menu
@node BFD outline
-@section How it works: an outline of BFD
+@section How It Works: An Outline of BFD
@cindex opening object files
@include bfdsumm.texi
@end ifclear
@@ -4634,7 +5385,7 @@ information that enables us to fix the bug.
@end menu
@node Bug Criteria
-@section Have you found a bug?
+@section Have You Found a Bug?
@cindex bug criteria
If you are not sure whether you have found a bug, here are some guidelines:
@@ -4663,7 +5414,7 @@ improvement of @command{ld} are welcome in any case.
@end itemize
@node Bug Reporting
-@section How to report bugs
+@section How to Report Bugs
@cindex bug reports
@cindex @command{ld} bugs, reporting
@@ -4698,9 +5449,9 @@ the bug if it is new to us. Therefore, always write your bug reports
on the assumption that the bug has not been reported previously.
Sometimes people give a few sketchy facts and ask, ``Does this ring a
-bell?'' Those bug reports are useless, and we urge everyone to
-@emph{refuse to respond to them} except to chide the sender to report
-bugs properly.
+bell?'' This cannot help us fix a bug, so it is basically useless. We
+respond by asking for enough details to enable us to investigate.
+You might as well expedite matters by sending them to begin with.
To enable us to fix the bug, you should include all these things:
@@ -4959,369 +5710,7 @@ If you have more than one @code{SECT} statement for the same
@var{secname}, only the @emph{first} sets the start address.
@end table
-@node GNU Free Documentation License
-@appendix GNU Free Documentation License
-@cindex GNU Free Documentation License
-
- GNU Free Documentation License
-
- Version 1.1, March 2000
-
- Copyright (C) 2000 Free Software Foundation, Inc.
- 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-
- Everyone is permitted to copy and distribute verbatim copies
- of this license document, but changing it is not allowed.
-
-
-0. PREAMBLE
-
-The purpose of this License is to make a manual, textbook, or other
-written document "free" in the sense of freedom: to assure everyone
-the effective freedom to copy and redistribute it, with or without
-modifying it, either commercially or noncommercially. Secondarily,
-this License preserves for the author and publisher a way to get
-credit for their work, while not being considered responsible for
-modifications made by others.
-
-This License is a kind of "copyleft", which means that derivative
-works of the document must themselves be free in the same sense. It
-complements the GNU General Public License, which is a copyleft
-license designed for free software.
-
-We have designed this License in order to use it for manuals for free
-software, because free software needs free documentation: a free
-program should come with manuals providing the same freedoms that the
-software does. But this License is not limited to software manuals;
-it can be used for any textual work, regardless of subject matter or
-whether it is published as a printed book. We recommend this License
-principally for works whose purpose is instruction or reference.
-
-
-1. APPLICABILITY AND DEFINITIONS
-
-This License applies to any manual or other work that contains a
-notice placed by the copyright holder saying it can be distributed
-under the terms of this License. The "Document", below, refers to any
-such manual or work. Any member of the public is a licensee, and is
-addressed as "you".
-
-A "Modified Version" of the Document means any work containing the
-Document or a portion of it, either copied verbatim, or with
-modifications and/or translated into another language.
-
-A "Secondary Section" is a named appendix or a front-matter section of
-the Document that deals exclusively with the relationship of the
-publishers or authors of the Document to the Document's overall subject
-(or to related matters) and contains nothing that could fall directly
-within that overall subject. (For example, if the Document is in part a
-textbook of mathematics, a Secondary Section may not explain any
-mathematics.) The relationship could be a matter of historical
-connection with the subject or with related matters, or of legal,
-commercial, philosophical, ethical or political position regarding
-them.
-
-The "Invariant Sections" are certain Secondary Sections whose titles
-are designated, as being those of Invariant Sections, in the notice
-that says that the Document is released under this License.
-
-The "Cover Texts" are certain short passages of text that are listed,
-as Front-Cover Texts or Back-Cover Texts, in the notice that says that
-the Document is released under this License.
-
-A "Transparent" copy of the Document means a machine-readable copy,
-represented in a format whose specification is available to the
-general public, whose contents can be viewed and edited directly and
-straightforwardly with generic text editors or (for images composed of
-pixels) generic paint programs or (for drawings) some widely available
-drawing editor, and that is suitable for input to text formatters or
-for automatic translation to a variety of formats suitable for input
-to text formatters. A copy made in an otherwise Transparent file
-format whose markup has been designed to thwart or discourage
-subsequent modification by readers is not Transparent. A copy that is
-not "Transparent" is called "Opaque".
-
-Examples of suitable formats for Transparent copies include plain
-ASCII without markup, Texinfo input format, LaTeX input format, SGML
-or XML using a publicly available DTD, and standard-conforming simple
-HTML designed for human modification. Opaque formats include
-PostScript, PDF, proprietary formats that can be read and edited only
-by proprietary word processors, SGML or XML for which the DTD and/or
-processing tools are not generally available, and the
-machine-generated HTML produced by some word processors for output
-purposes only.
-
-The "Title Page" means, for a printed book, the title page itself,
-plus such following pages as are needed to hold, legibly, the material
-this License requires to appear in the title page. For works in
-formats which do not have any title page as such, "Title Page" means
-the text near the most prominent appearance of the work's title,
-preceding the beginning of the body of the text.
-
-
-2. VERBATIM COPYING
-
-You may copy and distribute the Document in any medium, either
-commercially or noncommercially, provided that this License, the
-copyright notices, and the license notice saying this License applies
-to the Document are reproduced in all copies, and that you add no other
-conditions whatsoever to those of this License. You may not use
-technical measures to obstruct or control the reading or further
-copying of the copies you make or distribute. However, you may accept
-compensation in exchange for copies. If you distribute a large enough
-number of copies you must also follow the conditions in section 3.
-
-You may also lend copies, under the same conditions stated above, and
-you may publicly display copies.
-
-
-3. COPYING IN QUANTITY
-
-If you publish printed copies of the Document numbering more than 100,
-and the Document's license notice requires Cover Texts, you must enclose
-the copies in covers that carry, clearly and legibly, all these Cover
-Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on
-the back cover. Both covers must also clearly and legibly identify
-you as the publisher of these copies. The front cover must present
-the full title with all words of the title equally prominent and
-visible. You may add other material on the covers in addition.
-Copying with changes limited to the covers, as long as they preserve
-the title of the Document and satisfy these conditions, can be treated
-as verbatim copying in other respects.
-
-If the required texts for either cover are too voluminous to fit
-legibly, you should put the first ones listed (as many as fit
-reasonably) on the actual cover, and continue the rest onto adjacent
-pages.
-
-If you publish or distribute Opaque copies of the Document numbering
-more than 100, you must either include a machine-readable Transparent
-copy along with each Opaque copy, or state in or with each Opaque copy
-a publicly-accessible computer-network location containing a complete
-Transparent copy of the Document, free of added material, which the
-general network-using public has access to download anonymously at no
-charge using public-standard network protocols. If you use the latter
-option, you must take reasonably prudent steps, when you begin
-distribution of Opaque copies in quantity, to ensure that this
-Transparent copy will remain thus accessible at the stated location
-until at least one year after the last time you distribute an Opaque
-copy (directly or through your agents or retailers) of that edition to
-the public.
-
-It is requested, but not required, that you contact the authors of the
-Document well before redistributing any large number of copies, to give
-them a chance to provide you with an updated version of the Document.
-
-
-4. MODIFICATIONS
-
-You may copy and distribute a Modified Version of the Document under
-the conditions of sections 2 and 3 above, provided that you release
-the Modified Version under precisely this License, with the Modified
-Version filling the role of the Document, thus licensing distribution
-and modification of the Modified Version to whoever possesses a copy
-of it. In addition, you must do these things in the Modified Version:
-
-A. Use in the Title Page (and on the covers, if any) a title distinct
- from that of the Document, and from those of previous versions
- (which should, if there were any, be listed in the History section
- of the Document). You may use the same title as a previous version
- if the original publisher of that version gives permission.
-B. List on the Title Page, as authors, one or more persons or entities
- responsible for authorship of the modifications in the Modified
- Version, together with at least five of the principal authors of the
- Document (all of its principal authors, if it has less than five).
-C. State on the Title page the name of the publisher of the
- Modified Version, as the publisher.
-D. Preserve all the copyright notices of the Document.
-E. Add an appropriate copyright notice for your modifications
- adjacent to the other copyright notices.
-F. Include, immediately after the copyright notices, a license notice
- giving the public permission to use the Modified Version under the
- terms of this License, in the form shown in the Addendum below.
-G. Preserve in that license notice the full lists of Invariant Sections
- and required Cover Texts given in the Document's license notice.
-H. Include an unaltered copy of this License.
-I. Preserve the section entitled "History", and its title, and add to
- it an item stating at least the title, year, new authors, and
- publisher of the Modified Version as given on the Title Page. If
- there is no section entitled "History" in the Document, create one
- stating the title, year, authors, and publisher of the Document as
- given on its Title Page, then add an item describing the Modified
- Version as stated in the previous sentence.
-J. Preserve the network location, if any, given in the Document for
- public access to a Transparent copy of the Document, and likewise
- the network locations given in the Document for previous versions
- it was based on. These may be placed in the "History" section.
- You may omit a network location for a work that was published at
- least four years before the Document itself, or if the original
- publisher of the version it refers to gives permission.
-K. In any section entitled "Acknowledgements" or "Dedications",
- preserve the section's title, and preserve in the section all the
- substance and tone of each of the contributor acknowledgements
- and/or dedications given therein.
-L. Preserve all the Invariant Sections of the Document,
- unaltered in their text and in their titles. Section numbers
- or the equivalent are not considered part of the section titles.
-M. Delete any section entitled "Endorsements". Such a section
- may not be included in the Modified Version.
-N. Do not retitle any existing section as "Endorsements"
- or to conflict in title with any Invariant Section.
-
-If the Modified Version includes new front-matter sections or
-appendices that qualify as Secondary Sections and contain no material
-copied from the Document, you may at your option designate some or all
-of these sections as invariant. To do this, add their titles to the
-list of Invariant Sections in the Modified Version's license notice.
-These titles must be distinct from any other section titles.
-
-You may add a section entitled "Endorsements", provided it contains
-nothing but endorsements of your Modified Version by various
-parties--for example, statements of peer review or that the text has
-been approved by an organization as the authoritative definition of a
-standard.
-
-You may add a passage of up to five words as a Front-Cover Text, and a
-passage of up to 25 words as a Back-Cover Text, to the end of the list
-of Cover Texts in the Modified Version. Only one passage of
-Front-Cover Text and one of Back-Cover Text may be added by (or
-through arrangements made by) any one entity. If the Document already
-includes a cover text for the same cover, previously added by you or
-by arrangement made by the same entity you are acting on behalf of,
-you may not add another; but you may replace the old one, on explicit
-permission from the previous publisher that added the old one.
-
-The author(s) and publisher(s) of the Document do not by this License
-give permission to use their names for publicity for or to assert or
-imply endorsement of any Modified Version.
-
-
-5. COMBINING DOCUMENTS
-
-You may combine the Document with other documents released under this
-License, under the terms defined in section 4 above for modified
-versions, provided that you include in the combination all of the
-Invariant Sections of all of the original documents, unmodified, and
-list them all as Invariant Sections of your combined work in its
-license notice.
-
-The combined work need only contain one copy of this License, and
-multiple identical Invariant Sections may be replaced with a single
-copy. If there are multiple Invariant Sections with the same name but
-different contents, make the title of each such section unique by
-adding at the end of it, in parentheses, the name of the original
-author or publisher of that section if known, or else a unique number.
-Make the same adjustment to the section titles in the list of
-Invariant Sections in the license notice of the combined work.
-
-In the combination, you must combine any sections entitled "History"
-in the various original documents, forming one section entitled
-"History"; likewise combine any sections entitled "Acknowledgements",
-and any sections entitled "Dedications". You must delete all sections
-entitled "Endorsements."
-
-
-6. COLLECTIONS OF DOCUMENTS
-
-You may make a collection consisting of the Document and other documents
-released under this License, and replace the individual copies of this
-License in the various documents with a single copy that is included in
-the collection, provided that you follow the rules of this License for
-verbatim copying of each of the documents in all other respects.
-
-You may extract a single document from such a collection, and distribute
-it individually under this License, provided you insert a copy of this
-License into the extracted document, and follow this License in all
-other respects regarding verbatim copying of that document.
-
-
-7. AGGREGATION WITH INDEPENDENT WORKS
-
-A compilation of the Document or its derivatives with other separate
-and independent documents or works, in or on a volume of a storage or
-distribution medium, does not as a whole count as a Modified Version
-of the Document, provided no compilation copyright is claimed for the
-compilation. Such a compilation is called an "aggregate", and this
-License does not apply to the other self-contained works thus compiled
-with the Document, on account of their being thus compiled, if they
-are not themselves derivative works of the Document.
-
-If the Cover Text requirement of section 3 is applicable to these
-copies of the Document, then if the Document is less than one quarter
-of the entire aggregate, the Document's Cover Texts may be placed on
-covers that surround only the Document within the aggregate.
-Otherwise they must appear on covers around the whole aggregate.
-
-
-8. TRANSLATION
-
-Translation is considered a kind of modification, so you may
-distribute translations of the Document under the terms of section 4.
-Replacing Invariant Sections with translations requires special
-permission from their copyright holders, but you may include
-translations of some or all Invariant Sections in addition to the
-original versions of these Invariant Sections. You may include a
-translation of this License provided that you also include the
-original English version of this License. In case of a disagreement
-between the translation and the original English version of this
-License, the original English version will prevail.
-
-
-9. TERMINATION
-
-You may not copy, modify, sublicense, or distribute the Document except
-as expressly provided for under this License. Any other attempt to
-copy, modify, sublicense or distribute the Document is void, and will
-automatically terminate your rights under this License. However,
-parties who have received copies, or rights, from you under this
-License will not have their licenses terminated so long as such
-parties remain in full compliance.
-
-
-10. FUTURE REVISIONS OF THIS LICENSE
-
-The Free Software Foundation may publish new, revised versions
-of the GNU Free Documentation License from time to time. Such new
-versions will be similar in spirit to the present version, but may
-differ in detail to address new problems or concerns. See
-http://www.gnu.org/copyleft/.
-
-Each version of the License is given a distinguishing version number.
-If the Document specifies that a particular numbered version of this
-License "or any later version" applies to it, you have the option of
-following the terms and conditions either of that specified version or
-of any later version that has been published (not as a draft) by the
-Free Software Foundation. If the Document does not specify a version
-number of this License, you may choose any version ever published (not
-as a draft) by the Free Software Foundation.
-
-
-ADDENDUM: How to use this License for your documents
-
-To use this License in a document you have written, include a copy of
-the License in the document and put the following copyright and
-license notices just after the title page:
-
-@smallexample
- Copyright (c) YEAR YOUR NAME.
- Permission is granted to copy, distribute and/or modify this document
- under the terms of the GNU Free Documentation License, Version 1.1
- or any later version published by the Free Software Foundation;
- with the Invariant Sections being LIST THEIR TITLES, with the
- Front-Cover Texts being LIST, and with the Back-Cover Texts being LIST.
- A copy of the license is included in the section entitled "GNU
- Free Documentation License".
-@end smallexample
-
-If you have no Invariant Sections, write "with no Invariant Sections"
-instead of saying which ones are invariant. If you have no
-Front-Cover Texts, write "no Front-Cover Texts" instead of
-"Front-Cover Texts being LIST"; likewise for Back-Cover Texts.
-
-If your document contains nontrivial examples of program code, we
-recommend releasing these examples in parallel under your choice of
-free software license, such as the GNU General Public License,
-to permit their use in free software.
+@include fdl.texi
@node Index
@unnumbered Index
diff --git a/contrib/binutils/ld/ldcref.c b/contrib/binutils/ld/ldcref.c
index c6ea18b..3094735 100644
--- a/contrib/binutils/ld/ldcref.c
+++ b/contrib/binutils/ld/ldcref.c
@@ -1,5 +1,6 @@
/* ldcref.c -- output a cross reference table
- Copyright 1996, 1997, 1998, 2000 Free Software Foundation, Inc.
+ Copyright 1996, 1997, 1998, 2000, 2002, 2003
+ Free Software Foundation, Inc.
Written by Ian Lance Taylor <ian@cygnus.com>
This file is part of GLD, the Gnu Linker.
@@ -65,18 +66,14 @@ struct cref_hash_table {
struct bfd_hash_table root;
};
-/* Local functions. */
+/* Forward declarations. */
-static struct bfd_hash_entry *cref_hash_newfunc
- PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-static boolean cref_fill_array PARAMS ((struct cref_hash_entry *, PTR));
-static int cref_sort_array PARAMS ((const PTR, const PTR));
-static void output_one_cref PARAMS ((FILE *, struct cref_hash_entry *));
-static boolean check_nocrossref PARAMS ((struct cref_hash_entry *, PTR));
-static void check_section_sym_xref PARAMS ((lang_input_statement_type *));
-static void check_refs
- PARAMS ((const char *, asection *, bfd *, struct lang_nocrossrefs *));
-static void check_reloc_refs PARAMS ((bfd *, asection *, PTR));
+static void output_one_cref (FILE *, struct cref_hash_entry *);
+static void check_section_sym_xref (lang_input_statement_type *);
+static bfd_boolean check_nocrossref (struct cref_hash_entry *, void *);
+static void check_refs (const char *, asection *, bfd *,
+ struct lang_nocrossrefs *);
+static void check_reloc_refs (bfd *, asection *, void *);
/* Look up an entry in the cref hash table. */
@@ -89,7 +86,7 @@ static void check_reloc_refs PARAMS ((bfd *, asection *, PTR));
#define cref_hash_traverse(table, func, info) \
(bfd_hash_traverse \
(&(table)->root, \
- (boolean (*) PARAMS ((struct bfd_hash_entry *, PTR))) (func), \
+ (bfd_boolean (*) (struct bfd_hash_entry *, void *)) (func), \
(info)))
/* The cref hash table. */
@@ -98,7 +95,7 @@ static struct cref_hash_table cref_table;
/* Whether the cref hash table has been initialized. */
-static boolean cref_initialized;
+static bfd_boolean cref_initialized;
/* The number of symbols seen so far. */
@@ -107,10 +104,9 @@ static size_t cref_symcount;
/* Create an entry in a cref hash table. */
static struct bfd_hash_entry *
-cref_hash_newfunc (entry, table, string)
- struct bfd_hash_entry *entry;
- struct bfd_hash_table *table;
- const char *string;
+cref_hash_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table,
+ const char *string)
{
struct cref_hash_entry *ret = (struct cref_hash_entry *) entry;
@@ -120,7 +116,7 @@ cref_hash_newfunc (entry, table, string)
ret = ((struct cref_hash_entry *)
bfd_hash_allocate (table, sizeof (struct cref_hash_entry)));
if (ret == NULL)
- return (struct bfd_hash_entry *) ret;
+ return NULL;
/* Call the allocation method of the superclass. */
ret = ((struct cref_hash_entry *)
@@ -132,22 +128,21 @@ cref_hash_newfunc (entry, table, string)
ret->refs = NULL;
/* Keep a count of the number of entries created in the hash
- table. */
+ table. */
++cref_symcount;
}
- return (struct bfd_hash_entry *) ret;
+ return &ret->root;
}
/* Add a symbol to the cref hash table. This is called for every
symbol that is seen during the link. */
void
-add_cref (name, abfd, section, value)
- const char *name;
- bfd *abfd;
- asection *section;
- bfd_vma value ATTRIBUTE_UNUSED;
+add_cref (const char *name,
+ bfd *abfd,
+ asection *section,
+ bfd_vma value ATTRIBUTE_UNUSED)
{
struct cref_hash_entry *h;
struct cref_ref *r;
@@ -156,10 +151,10 @@ add_cref (name, abfd, section, value)
{
if (! bfd_hash_table_init (&cref_table.root, cref_hash_newfunc))
einfo (_("%X%P: bfd_hash_table_init of cref table failed: %E\n"));
- cref_initialized = true;
+ cref_initialized = TRUE;
}
- h = cref_hash_lookup (&cref_table, name, true, false);
+ h = cref_hash_lookup (&cref_table, name, TRUE, FALSE);
if (h == NULL)
einfo (_("%X%P: cref_hash_lookup failed: %E\n"));
@@ -169,33 +164,31 @@ add_cref (name, abfd, section, value)
if (r == NULL)
{
- r = (struct cref_ref *) xmalloc (sizeof *r);
+ r = xmalloc (sizeof *r);
r->next = h->refs;
h->refs = r;
r->abfd = abfd;
- r->def = false;
- r->common = false;
- r->undef = false;
+ r->def = FALSE;
+ r->common = FALSE;
+ r->undef = FALSE;
}
if (bfd_is_und_section (section))
- r->undef = true;
+ r->undef = TRUE;
else if (bfd_is_com_section (section))
- r->common = true;
+ r->common = TRUE;
else
- r->def = true;
+ r->def = TRUE;
}
/* Copy the addresses of the hash table entries into an array. This
is called via cref_hash_traverse. We also fill in the demangled
name. */
-static boolean
-cref_fill_array (h, data)
- struct cref_hash_entry *h;
- PTR data;
+static bfd_boolean
+cref_fill_array (struct cref_hash_entry *h, void *data)
{
- struct cref_hash_entry ***pph = (struct cref_hash_entry ***) data;
+ struct cref_hash_entry ***pph = data;
ASSERT (h->demangled == NULL);
h->demangled = demangle (h->root.string);
@@ -204,18 +197,16 @@ cref_fill_array (h, data)
++*pph;
- return true;
+ return TRUE;
}
/* Sort an array of cref hash table entries by name. */
static int
-cref_sort_array (a1, a2)
- const PTR a1;
- const PTR a2;
+cref_sort_array (const void *a1, const void *a2)
{
- const struct cref_hash_entry **p1 = (const struct cref_hash_entry **) a1;
- const struct cref_hash_entry **p2 = (const struct cref_hash_entry **) a2;
+ const struct cref_hash_entry * const *p1 = a1;
+ const struct cref_hash_entry * const *p2 = a2;
return strcmp ((*p1)->demangled, (*p2)->demangled);
}
@@ -225,8 +216,7 @@ cref_sort_array (a1, a2)
#define FILECOL (50)
void
-output_cref (fp)
- FILE *fp;
+output_cref (FILE *fp)
{
int len;
struct cref_hash_entry **csyms, **csym_fill, **csym, **csym_end;
@@ -249,8 +239,7 @@ output_cref (fp)
return;
}
- csyms = ((struct cref_hash_entry **)
- xmalloc (cref_symcount * sizeof (*csyms)));
+ csyms = xmalloc (cref_symcount * sizeof (*csyms));
csym_fill = csyms;
cref_hash_traverse (&cref_table, cref_fill_array, &csym_fill);
@@ -266,16 +255,14 @@ output_cref (fp)
/* Output one entry in the cross reference table. */
static void
-output_one_cref (fp, h)
- FILE *fp;
- struct cref_hash_entry *h;
+output_one_cref (FILE *fp, struct cref_hash_entry *h)
{
int len;
struct bfd_link_hash_entry *hl;
struct cref_ref *r;
- hl = bfd_link_hash_lookup (link_info.hash, h->root.string, false,
- false, true);
+ hl = bfd_link_hash_lookup (link_info.hash, h->root.string, FALSE,
+ FALSE, TRUE);
if (hl == NULL)
einfo ("%P: symbol `%T' missing from main hash table\n",
h->root.string);
@@ -336,12 +323,12 @@ output_one_cref (fp, h)
/* Check for prohibited cross references. */
void
-check_nocrossrefs ()
+check_nocrossrefs (void)
{
if (! cref_initialized)
return;
- cref_hash_traverse (&cref_table, check_nocrossref, (PTR) NULL);
+ cref_hash_traverse (&cref_table, check_nocrossref, NULL);
lang_for_each_file (check_section_sym_xref);
}
@@ -349,8 +336,7 @@ check_nocrossrefs ()
/* Checks for prohibited cross references to section symbols. */
static void
-check_section_sym_xref (statement)
- lang_input_statement_type *statement;
+check_section_sym_xref (lang_input_statement_type *statement)
{
bfd *abfd;
asection *sec;
@@ -381,10 +367,8 @@ check_section_sym_xref (statement)
/* Check one symbol to see if it is a prohibited cross reference. */
-static boolean
-check_nocrossref (h, ignore)
- struct cref_hash_entry *h;
- PTR ignore ATTRIBUTE_UNUSED;
+static bfd_boolean
+check_nocrossref (struct cref_hash_entry *h, void *ignore ATTRIBUTE_UNUSED)
{
struct bfd_link_hash_entry *hl;
asection *defsec;
@@ -393,22 +377,22 @@ check_nocrossref (h, ignore)
struct lang_nocrossref *ncr;
struct cref_ref *ref;
- hl = bfd_link_hash_lookup (link_info.hash, h->root.string, false,
- false, true);
+ hl = bfd_link_hash_lookup (link_info.hash, h->root.string, FALSE,
+ FALSE, TRUE);
if (hl == NULL)
{
einfo (_("%P: symbol `%T' missing from main hash table\n"),
h->root.string);
- return true;
+ return TRUE;
}
if (hl->type != bfd_link_hash_defined
&& hl->type != bfd_link_hash_defweak)
- return true;
+ return TRUE;
defsec = hl->u.def.section->output_section;
if (defsec == NULL)
- return true;
+ return TRUE;
defsecname = bfd_get_section_name (defsec->owner, defsec);
for (ncrs = nocrossref_list; ncrs != NULL; ncrs = ncrs->next)
@@ -417,7 +401,7 @@ check_nocrossref (h, ignore)
for (ref = h->refs; ref != NULL; ref = ref->next)
check_refs (hl->root.string, hl->u.def.section, ref->abfd, ncrs);
- return true;
+ return TRUE;
}
/* The struct is used to pass information from check_refs to
@@ -436,11 +420,10 @@ struct check_refs_info {
prohibited sections. */
static void
-check_refs (name, sec, abfd, ncrs)
- const char *name;
- asection *sec;
- bfd *abfd;
- struct lang_nocrossrefs *ncrs;
+check_refs (const char *name,
+ asection *sec,
+ bfd *abfd,
+ struct lang_nocrossrefs *ncrs)
{
lang_input_statement_type *li;
asymbol **asymbols;
@@ -452,7 +435,7 @@ check_refs (name, sec, abfd, ncrs)
the BFD in which the symbol is defined, since even a single
BFD might contain a prohibited cross reference. */
- li = (lang_input_statement_type *) abfd->usrdata;
+ li = abfd->usrdata;
if (li != NULL && li->asymbols != NULL)
asymbols = li->asymbols;
else
@@ -463,7 +446,7 @@ check_refs (name, sec, abfd, ncrs)
symsize = bfd_get_symtab_upper_bound (abfd);
if (symsize < 0)
einfo (_("%B%F: could not read symbols; %E\n"), abfd);
- asymbols = (asymbol **) xmalloc (symsize);
+ asymbols = xmalloc (symsize);
symbol_count = bfd_canonicalize_symtab (abfd, asymbols);
if (symbol_count < 0)
einfo (_("%B%F: could not read symbols: %E\n"), abfd);
@@ -478,7 +461,7 @@ check_refs (name, sec, abfd, ncrs)
info.defsec = sec;
info.ncrs = ncrs;
info.asymbols = asymbols;
- bfd_map_over_sections (abfd, check_reloc_refs, (PTR) &info);
+ bfd_map_over_sections (abfd, check_reloc_refs, &info);
if (li == NULL)
free (asymbols);
@@ -491,12 +474,9 @@ check_refs (name, sec, abfd, ncrs)
INFO->SYM_NAME, then we report a prohibited cross reference error. */
static void
-check_reloc_refs (abfd, sec, iarg)
- bfd *abfd;
- asection *sec;
- PTR iarg;
+check_reloc_refs (bfd *abfd, asection *sec, void *iarg)
{
- struct check_refs_info *info = (struct check_refs_info *) iarg;
+ struct check_refs_info *info = iarg;
asection *outsec;
const char *outsecname;
asection *outdefsec;
@@ -538,7 +518,7 @@ check_reloc_refs (abfd, sec, iarg)
if (relsize == 0)
return;
- relpp = (arelent **) xmalloc (relsize);
+ relpp = xmalloc (relsize);
relcount = bfd_canonicalize_reloc (abfd, sec, relpp, info->asymbols);
if (relcount < 0)
einfo (_("%B%F: could not read relocs: %E\n"), abfd);
@@ -557,9 +537,9 @@ check_reloc_refs (abfd, sec, iarg)
&& bfd_get_section (*q->sym_ptr_ptr) == info->defsec)))
{
/* We found a reloc for the symbol. The symbol is defined
- in OUTSECNAME. This reloc is from a section which is
- mapped into a section from which references to OUTSECNAME
- are prohibited. We must report an error. */
+ in OUTSECNAME. This reloc is from a section which is
+ mapped into a section from which references to OUTSECNAME
+ are prohibited. We must report an error. */
einfo (_("%X%C: prohibited cross reference from %s to `%T' in %s\n"),
abfd, sec, q->address, outsecname,
bfd_asymbol_name (*q->sym_ptr_ptr), outdefsecname);
diff --git a/contrib/binutils/ld/ldctor.c b/contrib/binutils/ld/ldctor.c
index aa6a05b..34d5e52 100644
--- a/contrib/binutils/ld/ldctor.c
+++ b/contrib/binutils/ld/ldctor.c
@@ -1,6 +1,6 @@
/* ldctor.c -- constructor support routines
- Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001
- Free Software Foundation, Inc.
+ Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
+ 2002, 2003 Free Software Foundation, Inc.
By Steve Chamberlain <sac@cygnus.com>
This file is part of GLD, the Gnu Linker.
@@ -33,9 +33,6 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
#include "ldmain.h"
#include "ldctor.h"
-static int ctor_prio PARAMS ((const char *));
-static int ctor_cmp PARAMS ((const PTR, const PTR));
-
/* The list of statements needed to handle constructors. These are
invoked by the command CONSTRUCTORS in the linker script. */
lang_statement_list_type constructor_list;
@@ -43,7 +40,7 @@ lang_statement_list_type constructor_list;
/* Whether the constructors should be sorted. Note that this is
global for the entire link; we assume that there is only a single
CONSTRUCTORS command in the linker script. */
-boolean constructors_sorted;
+bfd_boolean constructors_sorted;
/* The sets we have seen. */
struct set_info *sets;
@@ -56,24 +53,23 @@ struct set_info *sets;
function will construct the sets. */
void
-ldctor_add_set_entry (h, reloc, name, section, value)
- struct bfd_link_hash_entry *h;
- bfd_reloc_code_real_type reloc;
- const char *name;
- asection *section;
- bfd_vma value;
+ldctor_add_set_entry (struct bfd_link_hash_entry *h,
+ bfd_reloc_code_real_type reloc,
+ const char *name,
+ asection *section,
+ bfd_vma value)
{
struct set_info *p;
struct set_element *e;
struct set_element **epp;
- for (p = sets; p != (struct set_info *) NULL; p = p->next)
+ for (p = sets; p != NULL; p = p->next)
if (p->h == h)
break;
- if (p == (struct set_info *) NULL)
+ if (p == NULL)
{
- p = (struct set_info *) xmalloc (sizeof (struct set_info));
+ p = xmalloc (sizeof (struct set_info));
p->next = sets;
sets = p;
p->h = h;
@@ -109,7 +105,7 @@ ldctor_add_set_entry (h, reloc, name, section, value)
}
}
- e = (struct set_element *) xmalloc (sizeof (struct set_element));
+ e = xmalloc (sizeof (struct set_element));
e->next = NULL;
e->name = name;
e->section = section;
@@ -126,8 +122,7 @@ ldctor_add_set_entry (h, reloc, name, section, value)
symbol name. */
static int
-ctor_prio (name)
- const char *name;
+ctor_prio (const char *name)
{
/* The name will look something like _GLOBAL_$I$65535$test02__Fv.
There might be extra leading underscores, and the $ characters
@@ -155,12 +150,10 @@ ctor_prio (name)
is called via qsort. */
static int
-ctor_cmp (p1, p2)
- const PTR p1;
- const PTR p2;
+ctor_cmp (const void *p1, const void *p2)
{
- const struct set_element **pe1 = (const struct set_element **) p1;
- const struct set_element **pe2 = (const struct set_element **) p2;
+ const struct set_element * const *pe1 = p1;
+ const struct set_element * const *pe2 = p2;
const char *n1;
const char *n2;
int prio1;
@@ -202,18 +195,18 @@ ctor_cmp (p1, p2)
themselves into constructor_list. */
void
-ldctor_build_sets ()
+ldctor_build_sets (void)
{
- static boolean called;
+ static bfd_boolean called;
lang_statement_list_type *old;
- boolean header_printed;
+ bfd_boolean header_printed;
struct set_info *p;
/* The emulation code may call us directly, but we only want to do
this once. */
if (called)
return;
- called = true;
+ called = TRUE;
if (constructors_sorted)
{
@@ -230,7 +223,7 @@ ldctor_build_sets ()
for (e = p->elements; e != NULL; e = e->next)
++c;
- array = (struct set_element **) xmalloc (c * sizeof *array);
+ array = xmalloc (c * sizeof *array);
i = 0;
for (e = p->elements; e != NULL; e = e->next)
@@ -256,8 +249,8 @@ ldctor_build_sets ()
lang_list_init (stat_ptr);
- header_printed = false;
- for (p = sets; p != (struct set_info *) NULL; p = p->next)
+ header_printed = FALSE;
+ for (p = sets; p != NULL; p = p->next)
{
struct set_element *e;
reloc_howto_type *howto;
@@ -278,12 +271,12 @@ ldctor_build_sets ()
.long elementN
.long 0
except that we use the right size instead of .long. When
- generating relocateable output, we generate relocs instead of
+ generating relocatable output, we generate relocs instead of
addresses. */
howto = bfd_reloc_type_lookup (output_bfd, p->reloc);
- if (howto == (reloc_howto_type *) NULL)
+ if (howto == NULL)
{
- if (link_info.relocateable)
+ if (link_info.relocatable)
{
einfo (_("%P%X: %s does not support reloc %s for set %s\n"),
bfd_get_target (output_bfd),
@@ -292,7 +285,7 @@ ldctor_build_sets ()
continue;
}
- /* If this is not a relocateable link, all we need is the
+ /* If this is not a relocatable link, all we need is the
size, which we can get from the input BFD. */
if (p->elements->section->owner != NULL)
howto = bfd_reloc_type_lookup (p->elements->section->owner,
@@ -331,9 +324,9 @@ ldctor_build_sets ()
exp_intop (reloc_size))));
lang_add_assignment (exp_assop ('=', p->h->root.string,
exp_nameop (NAME, ".")));
- lang_add_data (size, exp_intop ((bfd_vma) p->count));
+ lang_add_data (size, exp_intop (p->count));
- for (e = p->elements; e != (struct set_element *) NULL; e = e->next)
+ for (e = p->elements; e != NULL; e = e->next)
{
if (config.map_file != NULL)
{
@@ -342,7 +335,7 @@ ldctor_build_sets ()
if (! header_printed)
{
minfo (_("\nSet Symbol\n\n"));
- header_printed = true;
+ header_printed = TRUE;
}
minfo ("%s", p->h->root.string);
@@ -369,7 +362,7 @@ ldctor_build_sets ()
if (! bfd_is_abs_section (e->section))
e->section->flags |= SEC_KEEP;
- if (link_info.relocateable)
+ if (link_info.relocatable)
lang_add_reloc (p->reloc, howto, e->section, e->name,
exp_intop (e->value));
else
diff --git a/contrib/binutils/ld/ldctor.h b/contrib/binutils/ld/ldctor.h
index 7d8c848..436df6c0 100644
--- a/contrib/binutils/ld/ldctor.h
+++ b/contrib/binutils/ld/ldctor.h
@@ -1,5 +1,5 @@
/* ldctor.h - linker constructor support
- Copyright 1991, 1992, 1993, 1994, 1995, 1998, 2000
+ Copyright 1991, 1992, 1993, 1994, 1995, 1998, 2000, 2002, 2003
Free Software Foundation, Inc.
This file is part of GLD, the Gnu Linker.
@@ -28,7 +28,7 @@ extern lang_statement_list_type constructor_list;
/* Whether the constructors should be sorted. Note that this is
global for the entire link; we assume that there is only a single
CONSTRUCTORS command in the linker script. */
-extern boolean constructors_sorted;
+extern bfd_boolean constructors_sorted;
/* We keep a list of these structures for each set we build. */
@@ -51,9 +51,10 @@ struct set_element {
extern struct set_info *sets;
-extern void ldctor_add_set_entry PARAMS ((struct bfd_link_hash_entry *,
- bfd_reloc_code_real_type,
- const char *, asection *, bfd_vma));
-extern void ldctor_build_sets PARAMS ((void));
+extern void ldctor_add_set_entry
+ (struct bfd_link_hash_entry *, bfd_reloc_code_real_type, const char *,
+ asection *, bfd_vma);
+extern void ldctor_build_sets
+ (void);
#endif
diff --git a/contrib/binutils/ld/ldemul.c b/contrib/binutils/ld/ldemul.c
index c90673b..760c55d 100644
--- a/contrib/binutils/ld/ldemul.c
+++ b/contrib/binutils/ld/ldemul.c
@@ -1,5 +1,5 @@
/* ldemul.c -- clearing house for ld emulation states
- Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000
+ Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000, 2002, 2003
Free Software Foundation, Inc.
This file is part of GLD, the Gnu Linker.
@@ -21,6 +21,7 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
#include "bfd.h"
#include "sysdep.h"
+#include "getopt.h"
#include "ld.h"
#include "ldmisc.h"
@@ -34,144 +35,147 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
ld_emulation_xfer_type *ld_emulation;
void
-ldemul_hll (name)
- char *name;
+ldemul_hll (char *name)
{
ld_emulation->hll (name);
}
void
-ldemul_syslib (name)
- char *name;
+ldemul_syslib (char *name)
{
ld_emulation->syslib (name);
}
void
-ldemul_after_parse ()
+ldemul_after_parse (void)
{
ld_emulation->after_parse ();
}
void
-ldemul_before_parse ()
+ldemul_before_parse (void)
{
ld_emulation->before_parse ();
}
void
-ldemul_after_open ()
+ldemul_after_open (void)
{
ld_emulation->after_open ();
}
void
-ldemul_after_allocation ()
+ldemul_after_allocation (void)
{
ld_emulation->after_allocation ();
}
void
-ldemul_before_allocation ()
+ldemul_before_allocation (void)
{
if (ld_emulation->before_allocation)
ld_emulation->before_allocation ();
}
void
-ldemul_set_output_arch ()
+ldemul_set_output_arch (void)
{
ld_emulation->set_output_arch ();
}
void
-ldemul_finish ()
+ldemul_finish (void)
{
if (ld_emulation->finish)
ld_emulation->finish ();
}
void
-ldemul_set_symbols ()
+ldemul_set_symbols (void)
{
if (ld_emulation->set_symbols)
ld_emulation->set_symbols ();
}
void
-ldemul_create_output_section_statements ()
+ldemul_create_output_section_statements (void)
{
if (ld_emulation->create_output_section_statements)
ld_emulation->create_output_section_statements ();
}
char *
-ldemul_get_script (isfile)
- int *isfile;
+ldemul_get_script (int *isfile)
{
return ld_emulation->get_script (isfile);
}
-boolean
-ldemul_open_dynamic_archive (arch, search, entry)
- const char *arch;
- search_dirs_type *search;
- lang_input_statement_type *entry;
+bfd_boolean
+ldemul_open_dynamic_archive (const char *arch, search_dirs_type *search,
+ lang_input_statement_type *entry)
{
if (ld_emulation->open_dynamic_archive)
return (*ld_emulation->open_dynamic_archive) (arch, search, entry);
- return false;
+ return FALSE;
}
-boolean
-ldemul_place_orphan (file, s)
- lang_input_statement_type *file;
- asection *s;
+bfd_boolean
+ldemul_place_orphan (lang_input_statement_type *file, asection *s)
{
if (ld_emulation->place_orphan)
return (*ld_emulation->place_orphan) (file, s);
- return false;
+ return FALSE;
}
-int
-ldemul_parse_args (argc, argv)
- int argc;
- char **argv;
+void
+ldemul_add_options (int ns, char **shortopts, int nl,
+ struct option **longopts, int nrl,
+ struct option **really_longopts)
+{
+ if (ld_emulation->add_options)
+ (*ld_emulation->add_options) (ns, shortopts, nl, longopts,
+ nrl, really_longopts);
+}
+
+bfd_boolean
+ldemul_handle_option (int optc)
+{
+ if (ld_emulation->handle_option)
+ return (*ld_emulation->handle_option) (optc);
+ return FALSE;
+}
+
+bfd_boolean
+ldemul_parse_args (int argc, char **argv)
{
/* Try and use the emulation parser if there is one. */
if (ld_emulation->parse_args)
- {
- return ld_emulation->parse_args (argc, argv);
- }
- return 0;
+ return (*ld_emulation->parse_args) (argc, argv);
+ return FALSE;
}
/* Let the emulation code handle an unrecognized file. */
-boolean
-ldemul_unrecognized_file (entry)
- lang_input_statement_type *entry;
+bfd_boolean
+ldemul_unrecognized_file (lang_input_statement_type *entry)
{
if (ld_emulation->unrecognized_file)
return (*ld_emulation->unrecognized_file) (entry);
- return false;
+ return FALSE;
}
/* Let the emulation code handle a recognized file. */
-boolean
-ldemul_recognized_file (entry)
- lang_input_statement_type *entry;
+bfd_boolean
+ldemul_recognized_file (lang_input_statement_type *entry)
{
if (ld_emulation->recognized_file)
return (*ld_emulation->recognized_file) (entry);
- return false;
+ return FALSE;
}
char *
-ldemul_choose_target (argc, argv)
- int argc;
- char **argv;
+ldemul_choose_target (int argc, char **argv)
{
return ld_emulation->choose_target (argc, argv);
}
@@ -180,9 +184,7 @@ ldemul_choose_target (argc, argv)
/* The default choose_target function. */
char *
-ldemul_default_target (argc, argv)
- int argc ATTRIBUTE_UNUSED;
- char **argv ATTRIBUTE_UNUSED;
+ldemul_default_target (int argc ATTRIBUTE_UNUSED, char **argv ATTRIBUTE_UNUSED)
{
char *from_outside = getenv (TARGET_ENVIRON);
if (from_outside != (char *) NULL)
@@ -191,27 +193,27 @@ ldemul_default_target (argc, argv)
}
void
-after_parse_default ()
+after_parse_default (void)
{
}
void
-after_open_default ()
+after_open_default (void)
{
}
void
-after_allocation_default ()
+after_allocation_default (void)
{
}
void
-before_allocation_default ()
+before_allocation_default (void)
{
}
void
-set_output_arch_default ()
+set_output_arch_default (void)
{
/* Set the output architecture and machine if possible. */
bfd_set_arch_mach (output_bfd,
@@ -219,15 +221,13 @@ set_output_arch_default ()
}
void
-syslib_default (ignore)
- char *ignore ATTRIBUTE_UNUSED;
+syslib_default (char *ignore ATTRIBUTE_UNUSED)
{
info_msg (_("%S SYSLIB ignored\n"));
}
void
-hll_default (ignore)
- char *ignore ATTRIBUTE_UNUSED;
+hll_default (char *ignore ATTRIBUTE_UNUSED)
{
info_msg (_("%S HLL ignored\n"));
}
@@ -235,8 +235,7 @@ hll_default (ignore)
ld_emulation_xfer_type *ld_emulations[] = { EMULATION_LIST };
void
-ldemul_choose_mode (target)
- char *target;
+ldemul_choose_mode (char *target)
{
ld_emulation_xfer_type **eptr = ld_emulations;
/* Ignore "gld" prefix. */
@@ -257,16 +256,15 @@ ldemul_choose_mode (target)
}
void
-ldemul_list_emulations (f)
- FILE *f;
+ldemul_list_emulations (FILE *f)
{
ld_emulation_xfer_type **eptr = ld_emulations;
- boolean first = true;
+ bfd_boolean first = TRUE;
for (; *eptr; eptr++)
{
if (first)
- first = false;
+ first = FALSE;
else
fprintf (f, " ");
fprintf (f, "%s", (*eptr)->emulation_name);
@@ -274,8 +272,7 @@ ldemul_list_emulations (f)
}
void
-ldemul_list_emulation_options (f)
- FILE *f;
+ldemul_list_emulation_options (FILE *f)
{
ld_emulation_xfer_type **eptr;
int options_found = 0;
@@ -299,9 +296,7 @@ ldemul_list_emulation_options (f)
}
int
-ldemul_find_potential_libraries (name, entry)
- char *name;
- lang_input_statement_type *entry;
+ldemul_find_potential_libraries (char *name, lang_input_statement_type *entry)
{
if (ld_emulation->find_potential_libraries)
return ld_emulation->find_potential_libraries (name, entry);
@@ -310,8 +305,7 @@ ldemul_find_potential_libraries (name, entry)
}
struct bfd_elf_version_expr *
-ldemul_new_vers_pattern (entry)
- struct bfd_elf_version_expr *entry;
+ldemul_new_vers_pattern (struct bfd_elf_version_expr *entry)
{
if (ld_emulation->new_vers_pattern)
entry = (*ld_emulation->new_vers_pattern) (entry);
diff --git a/contrib/binutils/ld/ldemul.h b/contrib/binutils/ld/ldemul.h
index 3e27500..8feef67 100644
--- a/contrib/binutils/ld/ldemul.h
+++ b/contrib/binutils/ld/ldemul.h
@@ -1,5 +1,5 @@
/* ld-emul.h - Linker emulation header file
- Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000
+ Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000, 2002, 2003
Free Software Foundation, Inc.
This file is part of GLD, the Gnu Linker.
@@ -17,76 +17,104 @@
#ifndef LDEMUL_H
#define LDEMUL_H
-extern void ldemul_hll PARAMS ((char *));
-extern void ldemul_syslib PARAMS ((char *));
-extern void ldemul_after_parse PARAMS ((void));
-extern void ldemul_before_parse PARAMS ((void));
-extern void ldemul_after_open PARAMS ((void));
-extern void ldemul_after_allocation PARAMS ((void));
-extern void ldemul_before_allocation PARAMS ((void));
-extern void ldemul_set_output_arch PARAMS ((void));
-extern char *ldemul_choose_target PARAMS ((int, char**));
-extern void ldemul_choose_mode PARAMS ((char *));
-extern void ldemul_list_emulations PARAMS ((FILE *));
-extern void ldemul_list_emulation_options PARAMS ((FILE *));
-extern char *ldemul_get_script PARAMS ((int *isfile));
-extern void ldemul_finish PARAMS ((void));
-extern void ldemul_set_symbols PARAMS ((void));
-extern void ldemul_create_output_section_statements PARAMS ((void));
-extern boolean ldemul_place_orphan
- PARAMS ((struct lang_input_statement_struct *, asection *));
-extern int ldemul_parse_args PARAMS ((int, char **));
-extern boolean ldemul_unrecognized_file
- PARAMS ((struct lang_input_statement_struct *));
-extern boolean ldemul_recognized_file
- PARAMS ((struct lang_input_statement_struct *));
-extern boolean ldemul_open_dynamic_archive
- PARAMS ((const char *, struct search_dirs *,
- struct lang_input_statement_struct *));
-extern char *ldemul_default_target PARAMS ((int, char**));
-extern void after_parse_default PARAMS ((void));
-extern void after_open_default PARAMS ((void));
-extern void after_allocation_default PARAMS ((void));
-extern void before_allocation_default PARAMS ((void));
-extern void set_output_arch_default PARAMS ((void));
-extern void syslib_default PARAMS ((char*));
-extern void hll_default PARAMS ((char*));
+extern void ldemul_hll
+ (char *);
+extern void ldemul_syslib
+ (char *);
+extern void ldemul_after_parse
+ (void);
+extern void ldemul_before_parse
+ (void);
+extern void ldemul_after_open
+ (void);
+extern void ldemul_after_allocation
+ (void);
+extern void ldemul_before_allocation
+ (void);
+extern void ldemul_set_output_arch
+ (void);
+extern char *ldemul_choose_target
+ (int, char**);
+extern void ldemul_choose_mode
+ (char *);
+extern void ldemul_list_emulations
+ (FILE *);
+extern void ldemul_list_emulation_options
+ (FILE *);
+extern char *ldemul_get_script
+ (int *isfile);
+extern void ldemul_finish
+ (void);
+extern void ldemul_set_symbols
+ (void);
+extern void ldemul_create_output_section_statements
+ (void);
+extern bfd_boolean ldemul_place_orphan
+ (struct lang_input_statement_struct *, asection *);
+extern bfd_boolean ldemul_parse_args
+ (int, char **);
+extern void ldemul_add_options
+ (int, char **, int, struct option **, int, struct option **);
+extern bfd_boolean ldemul_handle_option
+ (int);
+extern bfd_boolean ldemul_unrecognized_file
+ (struct lang_input_statement_struct *);
+extern bfd_boolean ldemul_recognized_file
+ (struct lang_input_statement_struct *);
+extern bfd_boolean ldemul_open_dynamic_archive
+ (const char *, struct search_dirs *, struct lang_input_statement_struct *);
+extern char *ldemul_default_target
+ (int, char**);
+extern void after_parse_default
+ (void);
+extern void after_open_default
+ (void);
+extern void after_allocation_default
+ (void);
+extern void before_allocation_default
+ (void);
+extern void set_output_arch_default
+ (void);
+extern void syslib_default
+ (char*);
+extern void hll_default
+ (char*);
extern int ldemul_find_potential_libraries
- PARAMS ((char *, struct lang_input_statement_struct *));
+ (char *, struct lang_input_statement_struct *);
extern struct bfd_elf_version_expr *ldemul_new_vers_pattern
- PARAMS ((struct bfd_elf_version_expr *));
+ (struct bfd_elf_version_expr *);
typedef struct ld_emulation_xfer_struct {
/* Run before parsing the command line and script file.
Set the architecture, maybe other things. */
- void (*before_parse) PARAMS ((void));
+ void (*before_parse) (void);
/* Handle the SYSLIB (low level library) script command. */
- void (*syslib) PARAMS ((char *));
+ void (*syslib) (char *);
/* Handle the HLL (high level library) script command. */
- void (*hll) PARAMS ((char *));
+ void (*hll) (char *);
/* Run after parsing the command line and script file. */
- void (*after_parse) PARAMS ((void));
+ void (*after_parse) (void);
/* Run after opening all input files, and loading the symbols. */
- void (*after_open) PARAMS ((void));
+ void (*after_open) (void);
/* Run after allocating output sections. */
- void (*after_allocation) PARAMS ( (void));
+ void (*after_allocation) (void);
/* Set the output architecture and machine if possible. */
- void (*set_output_arch) PARAMS ((void));
+ void (*set_output_arch) (void);
/* Decide which target name to use. */
- char * (*choose_target) PARAMS ((int, char**));
+ char * (*choose_target) (int, char**);
/* Run before allocating output sections. */
- void (*before_allocation) PARAMS ((void));
+ void (*before_allocation) (void);
/* Return the appropriate linker script. */
- char * (*get_script) PARAMS ((int *isfile));
+ char * (*get_script) (int *isfile);
/* The name of this emulation. */
char *emulation_name;
@@ -95,56 +123,65 @@ typedef struct ld_emulation_xfer_struct {
char *target_name;
/* Run after assigning values from the script. */
- void (*finish) PARAMS ((void));
+ void (*finish) (void);
/* Create any output sections needed by the target. */
- void (*create_output_section_statements) PARAMS ((void));
+ void (*create_output_section_statements) (void);
/* Try to open a dynamic library. ARCH is an architecture name, and
is normally the empty string. ENTRY is the lang_input_statement
that should be opened. */
- boolean (*open_dynamic_archive)
- PARAMS ((const char *arch, struct search_dirs *,
- struct lang_input_statement_struct *entry));
+ bfd_boolean (*open_dynamic_archive)
+ (const char *arch, struct search_dirs *,
+ struct lang_input_statement_struct *entry);
- /* Place an orphan section. Return true if it was placed, false if
+ /* Place an orphan section. Return TRUE if it was placed, FALSE if
the default action should be taken. This field may be NULL, in
which case the default action will always be taken. */
- boolean (*place_orphan)
- PARAMS ((struct lang_input_statement_struct *, asection *));
+ bfd_boolean (*place_orphan)
+ (struct lang_input_statement_struct *, asection *);
/* Run after assigning parsing with the args, but before
reading the script. Used to initialize symbols used in the script. */
- void (*set_symbols) PARAMS ((void));
+ void (*set_symbols) (void);
- /* Run to parse args which the base linker doesn't
- understand. Return non zero on sucess. */
- int (*parse_args) PARAMS ((int, char **));
+ /* Parse args which the base linker doesn't understand.
+ Return TRUE if the arg needs no further processing. */
+ bfd_boolean (*parse_args) (int, char **);
+
+ /* Hook to add options to parameters passed by the base linker to
+ getopt_long and getopt_long_only calls. */
+ void (*add_options)
+ (int, char **, int, struct option **, int, struct option **);
+
+ /* Companion to the above to handle an option. Returns TRUE if it is
+ one of our options. */
+ bfd_boolean (*handle_option) (int);
/* Run to handle files which are not recognized as object files or
- archives. Return true if the file was handled. */
- boolean (*unrecognized_file)
- PARAMS ((struct lang_input_statement_struct *));
+ archives. Return TRUE if the file was handled. */
+ bfd_boolean (*unrecognized_file)
+ (struct lang_input_statement_struct *);
/* Run to list the command line options which parse_args handles. */
- void (* list_options) PARAMS ((FILE *));
+ void (* list_options) (FILE *);
/* Run to specially handle files which *are* recognized as object
- files or archives. Return true if the file was handled. */
- boolean (*recognized_file)
- PARAMS ((struct lang_input_statement_struct *));
+ files or archives. Return TRUE if the file was handled. */
+ bfd_boolean (*recognized_file)
+ (struct lang_input_statement_struct *);
/* Called when looking for libraries in a directory specified
via a linker command line option or linker script option.
Files that match the pattern "lib*.a" have already been scanned.
(For VMS files matching ":lib*.a" have also been scanned). */
int (* find_potential_libraries)
- PARAMS ((char *, struct lang_input_statement_struct *));
+ (char *, struct lang_input_statement_struct *);
/* Called when adding a new version pattern. PowerPC64-ELF uses
this hook to add a pattern matching ".foo" for every "foo". */
struct bfd_elf_version_expr * (*new_vers_pattern)
- PARAMS ((struct bfd_elf_version_expr *));
+ (struct bfd_elf_version_expr *);
} ld_emulation_xfer_type;
diff --git a/contrib/binutils/ld/ldexp.c b/contrib/binutils/ld/ldexp.c
index e88e322..4d9a857 100644
--- a/contrib/binutils/ld/ldexp.c
+++ b/contrib/binutils/ld/ldexp.c
@@ -1,6 +1,6 @@
/* This module handles expression trees.
Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
- 2001, 2002
+ 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
Written by Steve Chamberlain of Cygnus Support <sac@cygnus.com>.
@@ -41,49 +41,18 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
#include "libiberty.h"
#include "safe-ctype.h"
-static void exp_print_token PARAMS ((token_code_type code, int infix_p));
-static void make_abs PARAMS ((etree_value_type *ptr));
-static etree_value_type new_abs PARAMS ((bfd_vma value));
-static void check PARAMS ((lang_output_section_statement_type *os,
- const char *name, const char *op));
-static etree_value_type new_rel
- PARAMS ((bfd_vma, char *, lang_output_section_statement_type *section));
-static etree_value_type new_rel_from_section
- PARAMS ((bfd_vma value, lang_output_section_statement_type *section));
-static etree_value_type fold_unary
- PARAMS ((etree_type *tree,
- lang_output_section_statement_type *current_section,
- lang_phase_type allocation_done,
- bfd_vma dot, bfd_vma *dotp));
-static etree_value_type fold_binary
- PARAMS ((etree_type *tree,
- lang_output_section_statement_type *current_section,
- lang_phase_type allocation_done,
- bfd_vma dot, bfd_vma *dotp));
-static etree_value_type fold_trinary
- PARAMS ((etree_type *tree,
- lang_output_section_statement_type *current_section,
- lang_phase_type allocation_done,
- bfd_vma dot, bfd_vma *dotp));
-static etree_value_type fold_name
- PARAMS ((etree_type *tree,
- lang_output_section_statement_type *current_section,
- lang_phase_type allocation_done,
- bfd_vma dot));
static etree_value_type exp_fold_tree_no_dot
- PARAMS ((etree_type *tree,
- lang_output_section_statement_type *current_section,
- lang_phase_type allocation_done));
+ (etree_type *, lang_output_section_statement_type *, lang_phase_type);
+static bfd_vma align_n
+ (bfd_vma, bfd_vma);
struct exp_data_seg exp_data_seg;
/* Print the string representation of the given token. Surround it
- with spaces if INFIX_P is true. */
+ with spaces if INFIX_P is TRUE. */
static void
-exp_print_token (code, infix_p)
- token_code_type code;
- int infix_p;
+exp_print_token (token_code_type code, int infix_p)
{
static const struct
{
@@ -130,7 +99,7 @@ exp_print_token (code, infix_p)
{ ADDR, "ADDR" },
{ LOADADDR, "LOADADDR" },
{ MAX_K, "MAX_K" },
- { REL, "relocateable" },
+ { REL, "relocatable" },
{ DATA_SEGMENT_ALIGN, "DATA_SEGMENT_ALIGN" },
{ DATA_SEGMENT_END, "DATA_SEGMENT_END" }
};
@@ -155,8 +124,7 @@ exp_print_token (code, infix_p)
}
static void
-make_abs (ptr)
- etree_value_type *ptr;
+make_abs (etree_value_type *ptr)
{
asection *s = ptr->section->bfd_section;
ptr->value += s->vma;
@@ -164,33 +132,19 @@ make_abs (ptr)
}
static etree_value_type
-new_abs (value)
- bfd_vma value;
+new_abs (bfd_vma value)
{
etree_value_type new;
- new.valid_p = true;
+ new.valid_p = TRUE;
new.section = abs_output_section;
new.value = value;
return new;
}
-static void
-check (os, name, op)
- lang_output_section_statement_type *os;
- const char *name;
- const char *op;
-{
- if (os == NULL)
- einfo (_("%F%P: %s uses undefined section %s\n"), op, name);
- if (! os->processed)
- einfo (_("%F%P: %s forward reference of section %s\n"), op, name);
-}
-
etree_type *
-exp_intop (value)
- bfd_vma value;
+exp_intop (bfd_vma value)
{
- etree_type *new = (etree_type *) stat_alloc (sizeof (new->value));
+ etree_type *new = stat_alloc (sizeof (new->value));
new->type.node_code = INT;
new->value.value = value;
new->value.str = NULL;
@@ -199,11 +153,9 @@ exp_intop (value)
}
etree_type *
-exp_bigintop (value, str)
- bfd_vma value;
- char *str;
+exp_bigintop (bfd_vma value, char *str)
{
- etree_type *new = (etree_type *) stat_alloc (sizeof (new->value));
+ etree_type *new = stat_alloc (sizeof (new->value));
new->type.node_code = INT;
new->value.value = value;
new->value.str = str;
@@ -211,14 +163,12 @@ exp_bigintop (value, str)
return new;
}
-/* Build an expression representing an unnamed relocateable value. */
+/* Build an expression representing an unnamed relocatable value. */
etree_type *
-exp_relop (section, value)
- asection *section;
- bfd_vma value;
+exp_relop (asection *section, bfd_vma value)
{
- etree_type *new = (etree_type *) stat_alloc (sizeof (new->rel));
+ etree_type *new = stat_alloc (sizeof (new->rel));
new->type.node_code = REL;
new->type.node_class = etree_rel;
new->rel.section = section;
@@ -227,13 +177,12 @@ exp_relop (section, value)
}
static etree_value_type
-new_rel (value, str, section)
- bfd_vma value;
- char *str;
- lang_output_section_statement_type *section;
+new_rel (bfd_vma value,
+ char *str,
+ lang_output_section_statement_type *section)
{
etree_value_type new;
- new.valid_p = true;
+ new.valid_p = TRUE;
new.value = value;
new.str = str;
new.section = section;
@@ -241,12 +190,11 @@ new_rel (value, str, section)
}
static etree_value_type
-new_rel_from_section (value, section)
- bfd_vma value;
- lang_output_section_statement_type *section;
+new_rel_from_section (bfd_vma value,
+ lang_output_section_statement_type *section)
{
etree_value_type new;
- new.valid_p = true;
+ new.valid_p = TRUE;
new.value = value;
new.str = NULL;
new.section = section;
@@ -257,12 +205,11 @@ new_rel_from_section (value, section)
}
static etree_value_type
-fold_unary (tree, current_section, allocation_done, dot, dotp)
- etree_type *tree;
- lang_output_section_statement_type *current_section;
- lang_phase_type allocation_done;
- bfd_vma dot;
- bfd_vma *dotp;
+fold_unary (etree_type *tree,
+ lang_output_section_statement_type *current_section,
+ lang_phase_type allocation_done,
+ bfd_vma dot,
+ bfd_vma *dotp)
{
etree_value_type result;
@@ -278,7 +225,7 @@ fold_unary (tree, current_section, allocation_done, dot, dotp)
result = new_rel_from_section (align_n (dot, result.value),
current_section);
else
- result.valid_p = false;
+ result.valid_p = FALSE;
break;
case ABSOLUTE:
@@ -288,7 +235,7 @@ fold_unary (tree, current_section, allocation_done, dot, dotp)
result.section = abs_output_section;
}
else
- result.valid_p = false;
+ result.valid_p = FALSE;
break;
case '~':
@@ -314,7 +261,7 @@ fold_unary (tree, current_section, allocation_done, dot, dotp)
result.value = align_n (dot, result.value);
}
else
- result.valid_p = false;
+ result.valid_p = FALSE;
break;
case DATA_SEGMENT_END:
@@ -331,7 +278,7 @@ fold_unary (tree, current_section, allocation_done, dot, dotp)
}
}
else
- result.valid_p = false;
+ result.valid_p = FALSE;
break;
default:
@@ -344,12 +291,11 @@ fold_unary (tree, current_section, allocation_done, dot, dotp)
}
static etree_value_type
-fold_binary (tree, current_section, allocation_done, dot, dotp)
- etree_type *tree;
- lang_output_section_statement_type *current_section;
- lang_phase_type allocation_done;
- bfd_vma dot;
- bfd_vma *dotp;
+fold_binary (etree_type *tree,
+ lang_output_section_statement_type *current_section,
+ lang_phase_type allocation_done,
+ bfd_vma dot,
+ bfd_vma *dotp)
{
etree_value_type result;
@@ -437,6 +383,10 @@ fold_binary (tree, current_section, allocation_done, dot, dotp)
result = other;
break;
+ case ALIGN_K:
+ result.value = align_n (result.value, other.value);
+ break;
+
case DATA_SEGMENT_ALIGN:
if (allocation_done != lang_first_phase_enum
&& current_section == abs_output_section
@@ -462,7 +412,7 @@ fold_binary (tree, current_section, allocation_done, dot, dotp)
& (maxpage - other.value);
}
else
- result.valid_p = false;
+ result.valid_p = FALSE;
break;
default:
@@ -471,7 +421,7 @@ fold_binary (tree, current_section, allocation_done, dot, dotp)
}
else
{
- result.valid_p = false;
+ result.valid_p = FALSE;
}
}
@@ -479,12 +429,11 @@ fold_binary (tree, current_section, allocation_done, dot, dotp)
}
static etree_value_type
-fold_trinary (tree, current_section, allocation_done, dot, dotp)
- etree_type *tree;
- lang_output_section_statement_type *current_section;
- lang_phase_type allocation_done;
- bfd_vma dot;
- bfd_vma *dotp;
+fold_trinary (etree_type *tree,
+ lang_output_section_statement_type *current_section,
+ lang_phase_type allocation_done,
+ bfd_vma dot,
+ bfd_vma *dotp)
{
etree_value_type result;
@@ -500,63 +449,50 @@ fold_trinary (tree, current_section, allocation_done, dot, dotp)
return result;
}
-etree_value_type
-invalid ()
-{
- etree_value_type new;
- new.valid_p = false;
- return new;
-}
-
static etree_value_type
-fold_name (tree, current_section, allocation_done, dot)
- etree_type *tree;
- lang_output_section_statement_type *current_section;
- lang_phase_type allocation_done;
- bfd_vma dot;
+fold_name (etree_type *tree,
+ lang_output_section_statement_type *current_section,
+ lang_phase_type allocation_done,
+ bfd_vma dot)
{
etree_value_type result;
+ result.valid_p = FALSE;
+
switch (tree->type.node_code)
{
case SIZEOF_HEADERS:
if (allocation_done != lang_first_phase_enum)
- {
- result = new_abs ((bfd_vma)
- bfd_sizeof_headers (output_bfd,
- link_info.relocateable));
- }
- else
- {
- result.valid_p = false;
- }
+ result = new_abs (bfd_sizeof_headers (output_bfd,
+ link_info.relocatable));
break;
case DEFINED:
if (allocation_done == lang_first_phase_enum)
- result.valid_p = false;
+ lang_track_definedness (tree->name.name);
else
{
struct bfd_link_hash_entry *h;
+ int def_iteration
+ = lang_symbol_definition_iteration (tree->name.name);
h = bfd_wrapped_link_hash_lookup (output_bfd, &link_info,
tree->name.name,
- false, false, true);
- result.value = (h != (struct bfd_link_hash_entry *) NULL
+ FALSE, FALSE, TRUE);
+ result.value = (h != NULL
&& (h->type == bfd_link_hash_defined
|| h->type == bfd_link_hash_defweak
- || h->type == bfd_link_hash_common));
- result.section = 0;
- result.valid_p = true;
+ || h->type == bfd_link_hash_common)
+ && (def_iteration == lang_statement_iteration
+ || def_iteration == -1));
+ result.section = abs_output_section;
+ result.valid_p = TRUE;
}
break;
case NAME:
- result.valid_p = false;
if (tree->name.name[0] == '.' && tree->name.name[1] == 0)
{
if (allocation_done != lang_first_phase_enum)
result = new_rel_from_section (dot, current_section);
- else
- result = invalid ();
}
else if (allocation_done != lang_first_phase_enum)
{
@@ -564,10 +500,11 @@ fold_name (tree, current_section, allocation_done, dot)
h = bfd_wrapped_link_hash_lookup (output_bfd, &link_info,
tree->name.name,
- false, false, true);
- if (h != NULL
- && (h->type == bfd_link_hash_defined
- || h->type == bfd_link_hash_defweak))
+ TRUE, FALSE, TRUE);
+ if (!h)
+ einfo (_("%P%F: bfd_link_hash_lookup failed: %E\n"));
+ else if (h->type == bfd_link_hash_defined
+ || h->type == bfd_link_hash_defweak)
{
if (bfd_is_abs_section (h->u.def.section))
result = new_abs (h->u.def.value);
@@ -600,6 +537,12 @@ fold_name (tree, current_section, allocation_done, dot)
else if (allocation_done == lang_final_phase_enum)
einfo (_("%F%S: undefined symbol `%s' referenced in expression\n"),
tree->name.name);
+ else if (h->type == bfd_link_hash_new)
+ {
+ h->type = bfd_link_hash_undefined;
+ h->u.undef.abfd = NULL;
+ bfd_link_add_undef (link_info.hash, h);
+ }
}
break;
@@ -609,11 +552,9 @@ fold_name (tree, current_section, allocation_done, dot)
lang_output_section_statement_type *os;
os = lang_output_section_find (tree->name.name);
- check (os, tree->name.name, "ADDR");
- result = new_rel (0, NULL, os);
+ if (os && os->processed > 0)
+ result = new_rel (0, NULL, os);
}
- else
- result = invalid ();
break;
case LOADADDR:
@@ -622,16 +563,16 @@ fold_name (tree, current_section, allocation_done, dot)
lang_output_section_statement_type *os;
os = lang_output_section_find (tree->name.name);
- check (os, tree->name.name, "LOADADDR");
- if (os->load_base == NULL)
- result = new_rel (0, NULL, os);
- else
- result = exp_fold_tree_no_dot (os->load_base,
- abs_output_section,
- allocation_done);
+ if (os && os->processed != 0)
+ {
+ if (os->load_base == NULL)
+ result = new_rel (0, NULL, os);
+ else
+ result = exp_fold_tree_no_dot (os->load_base,
+ abs_output_section,
+ allocation_done);
+ }
}
- else
- result = invalid ();
break;
case SIZEOF:
@@ -641,11 +582,9 @@ fold_name (tree, current_section, allocation_done, dot)
lang_output_section_statement_type *os;
os = lang_output_section_find (tree->name.name);
- check (os, tree->name.name, "SIZEOF");
- result = new_abs (os->bfd_section->_raw_size / opb);
+ if (os && os->processed > 0)
+ result = new_abs (os->bfd_section->_raw_size / opb);
}
- else
- result = invalid ();
break;
default:
@@ -657,18 +596,17 @@ fold_name (tree, current_section, allocation_done, dot)
}
etree_value_type
-exp_fold_tree (tree, current_section, allocation_done, dot, dotp)
- etree_type *tree;
- lang_output_section_statement_type *current_section;
- lang_phase_type allocation_done;
- bfd_vma dot;
- bfd_vma *dotp;
+exp_fold_tree (etree_type *tree,
+ lang_output_section_statement_type *current_section,
+ lang_phase_type allocation_done,
+ bfd_vma dot,
+ bfd_vma *dotp)
{
etree_value_type result;
if (tree == NULL)
{
- result.valid_p = false;
+ result.valid_p = FALSE;
return result;
}
@@ -680,7 +618,7 @@ exp_fold_tree (tree, current_section, allocation_done, dot, dotp)
case etree_rel:
if (allocation_done != lang_final_phase_enum)
- result.valid_p = false;
+ result.valid_p = FALSE;
else
result = new_rel ((tree->rel.value
+ tree->rel.section->output_section->vma
@@ -761,22 +699,23 @@ exp_fold_tree (tree, current_section, allocation_done, dot, dotp)
dot, dotp);
if (result.valid_p)
{
- boolean create;
+ bfd_boolean create;
struct bfd_link_hash_entry *h;
if (tree->type.node_class == etree_assign)
- create = true;
+ create = TRUE;
else
- create = false;
+ create = FALSE;
h = bfd_link_hash_lookup (link_info.hash, tree->assign.dst,
- create, false, false);
- if (h == (struct bfd_link_hash_entry *) NULL)
+ create, FALSE, TRUE);
+ if (h == NULL)
{
- if (tree->type.node_class == etree_assign)
+ if (create)
einfo (_("%P%F:%s: hash creation failed\n"),
tree->assign.dst);
}
else if (tree->type.node_class == etree_provide
+ && h->type != bfd_link_hash_new
&& h->type != bfd_link_hash_undefined
&& h->type != bfd_link_hash_common)
{
@@ -787,6 +726,7 @@ exp_fold_tree (tree, current_section, allocation_done, dot, dotp)
{
/* FIXME: Should we worry if the symbol is already
defined? */
+ lang_update_definedness (tree->assign.dst, h);
h->type = bfd_link_hash_defined;
h->u.def.value = result.value;
h->u.def.section = result.section->bfd_section;
@@ -810,20 +750,15 @@ exp_fold_tree (tree, current_section, allocation_done, dot, dotp)
}
static etree_value_type
-exp_fold_tree_no_dot (tree, current_section, allocation_done)
- etree_type *tree;
- lang_output_section_statement_type *current_section;
- lang_phase_type allocation_done;
+exp_fold_tree_no_dot (etree_type *tree,
+ lang_output_section_statement_type *current_section,
+ lang_phase_type allocation_done)
{
- return exp_fold_tree (tree, current_section, allocation_done,
- (bfd_vma) 0, (bfd_vma *) NULL);
+ return exp_fold_tree (tree, current_section, allocation_done, 0, NULL);
}
etree_type *
-exp_binop (code, lhs, rhs)
- int code;
- etree_type *lhs;
- etree_type *rhs;
+exp_binop (int code, etree_type *lhs, etree_type *rhs)
{
etree_type value, *new;
etree_value_type r;
@@ -839,17 +774,13 @@ exp_binop (code, lhs, rhs)
{
return exp_intop (r.value);
}
- new = (etree_type *) stat_alloc (sizeof (new->binary));
- memcpy ((char *) new, (char *) &value, sizeof (new->binary));
+ new = stat_alloc (sizeof (new->binary));
+ memcpy (new, &value, sizeof (new->binary));
return new;
}
etree_type *
-exp_trinop (code, cond, lhs, rhs)
- int code;
- etree_type *cond;
- etree_type *lhs;
- etree_type *rhs;
+exp_trinop (int code, etree_type *cond, etree_type *lhs, etree_type *rhs)
{
etree_type value, *new;
etree_value_type r;
@@ -858,21 +789,17 @@ exp_trinop (code, cond, lhs, rhs)
value.trinary.cond = cond;
value.trinary.rhs = rhs;
value.type.node_class = etree_trinary;
- r = exp_fold_tree_no_dot (&value,
- (lang_output_section_statement_type *) NULL,
- lang_first_phase_enum);
+ r = exp_fold_tree_no_dot (&value, NULL, lang_first_phase_enum);
if (r.valid_p)
return exp_intop (r.value);
- new = (etree_type *) stat_alloc (sizeof (new->trinary));
- memcpy ((char *) new, (char *) &value, sizeof (new->trinary));
+ new = stat_alloc (sizeof (new->trinary));
+ memcpy (new, &value, sizeof (new->trinary));
return new;
}
etree_type *
-exp_unop (code, child)
- int code;
- etree_type *child;
+exp_unop (int code, etree_type *child)
{
etree_type value, *new;
@@ -885,15 +812,13 @@ exp_unop (code, child)
if (r.valid_p)
return exp_intop (r.value);
- new = (etree_type *) stat_alloc (sizeof (new->unary));
- memcpy ((char *) new, (char *) &value, sizeof (new->unary));
+ new = stat_alloc (sizeof (new->unary));
+ memcpy (new, &value, sizeof (new->unary));
return new;
}
etree_type *
-exp_nameop (code, name)
- int code;
- const char *name;
+exp_nameop (int code, const char *name)
{
etree_type value, *new;
etree_value_type r;
@@ -901,23 +826,18 @@ exp_nameop (code, name)
value.name.name = name;
value.name.type.node_class = etree_name;
- r = exp_fold_tree_no_dot (&value,
- (lang_output_section_statement_type *) NULL,
- lang_first_phase_enum);
+ r = exp_fold_tree_no_dot (&value, NULL, lang_first_phase_enum);
if (r.valid_p)
return exp_intop (r.value);
- new = (etree_type *) stat_alloc (sizeof (new->name));
- memcpy ((char *) new, (char *) &value, sizeof (new->name));
+ new = stat_alloc (sizeof (new->name));
+ memcpy (new, &value, sizeof (new->name));
return new;
}
etree_type *
-exp_assop (code, dst, src)
- int code;
- const char *dst;
- etree_type *src;
+exp_assop (int code, const char *dst, etree_type *src)
{
etree_type value, *new;
@@ -931,21 +851,19 @@ exp_assop (code, dst, src)
if (exp_fold_tree_no_dot (&value, &result))
return exp_intop (result);
#endif
- new = (etree_type *) stat_alloc (sizeof (new->assign));
- memcpy ((char *) new, (char *) &value, sizeof (new->assign));
+ new = stat_alloc (sizeof (new->assign));
+ memcpy (new, &value, sizeof (new->assign));
return new;
}
/* Handle PROVIDE. */
etree_type *
-exp_provide (dst, src)
- const char *dst;
- etree_type *src;
+exp_provide (const char *dst, etree_type *src)
{
etree_type *n;
- n = (etree_type *) stat_alloc (sizeof (n->assign));
+ n = stat_alloc (sizeof (n->assign));
n->assign.type.node_code = '=';
n->assign.type.node_class = etree_provide;
n->assign.src = src;
@@ -956,13 +874,11 @@ exp_provide (dst, src)
/* Handle ASSERT. */
etree_type *
-exp_assert (exp, message)
- etree_type *exp;
- const char *message;
+exp_assert (etree_type *exp, const char *message)
{
etree_type *n;
- n = (etree_type *) stat_alloc (sizeof (n->assert_s));
+ n = stat_alloc (sizeof (n->assert_s));
n->assert_s.type.node_code = '!';
n->assert_s.type.node_class = etree_assert;
n->assert_s.child = exp;
@@ -971,8 +887,7 @@ exp_assert (exp, message)
}
void
-exp_print_tree (tree)
- etree_type *tree;
+exp_print_tree (etree_type *tree)
{
if (config.map_file == NULL)
config.map_file = stderr;
@@ -995,14 +910,14 @@ exp_print_tree (tree)
return;
case etree_assign:
#if 0
- if (tree->assign.dst->sdefs != (asymbol *) NULL)
+ if (tree->assign.dst->sdefs != NULL)
fprintf (config.map_file, "%s (%x) ", tree->assign.dst->name,
tree->assign.dst->sdefs->value);
else
fprintf (config.map_file, "%s (UNDEFINED)", tree->assign.dst->name);
#endif
fprintf (config.map_file, "%s", tree->assign.dst);
- exp_print_token (tree->type.node_code, true);
+ exp_print_token (tree->type.node_code, TRUE);
exp_print_tree (tree->assign.src);
break;
case etree_provide:
@@ -1014,7 +929,7 @@ exp_print_tree (tree)
case etree_binary:
fprintf (config.map_file, "(");
exp_print_tree (tree->binary.lhs);
- exp_print_token (tree->type.node_code, true);
+ exp_print_token (tree->type.node_code, TRUE);
exp_print_tree (tree->binary.rhs);
fprintf (config.map_file, ")");
break;
@@ -1026,7 +941,7 @@ exp_print_tree (tree)
exp_print_tree (tree->trinary.rhs);
break;
case etree_unary:
- exp_print_token (tree->unary.type.node_code, false);
+ exp_print_token (tree->unary.type.node_code, FALSE);
if (tree->unary.child)
{
fprintf (config.map_file, " (");
@@ -1051,7 +966,7 @@ exp_print_tree (tree)
}
else
{
- exp_print_token (tree->type.node_code, false);
+ exp_print_token (tree->type.node_code, FALSE);
if (tree->name.name)
fprintf (config.map_file, " (%s)", tree->name.name);
}
@@ -1063,11 +978,10 @@ exp_print_tree (tree)
}
bfd_vma
-exp_get_vma (tree, def, name, allocation_done)
- etree_type *tree;
- bfd_vma def;
- char *name;
- lang_phase_type allocation_done;
+exp_get_vma (etree_type *tree,
+ bfd_vma def,
+ char *name,
+ lang_phase_type allocation_done)
{
etree_value_type r;
@@ -1083,21 +997,19 @@ exp_get_vma (tree, def, name, allocation_done)
}
int
-exp_get_value_int (tree, def, name, allocation_done)
- etree_type *tree;
- int def;
- char *name;
- lang_phase_type allocation_done;
+exp_get_value_int (etree_type *tree,
+ int def,
+ char *name,
+ lang_phase_type allocation_done)
{
- return (int) exp_get_vma (tree, (bfd_vma) def, name, allocation_done);
+ return exp_get_vma (tree, def, name, allocation_done);
}
fill_type *
-exp_get_fill (tree, def, name, allocation_done)
- etree_type *tree;
- fill_type *def;
- char *name;
- lang_phase_type allocation_done;
+exp_get_fill (etree_type *tree,
+ fill_type *def,
+ char *name,
+ lang_phase_type allocation_done)
{
fill_type *fill;
etree_value_type r;
@@ -1115,7 +1027,7 @@ exp_get_fill (tree, def, name, allocation_done)
{
unsigned char *dst;
unsigned char *s;
- fill = (fill_type *) xmalloc ((len + 1) / 2 + sizeof (*fill) - 1);
+ fill = xmalloc ((len + 1) / 2 + sizeof (*fill) - 1);
fill->size = (len + 1) / 2;
dst = fill->data;
s = r.str;
@@ -1140,7 +1052,7 @@ exp_get_fill (tree, def, name, allocation_done)
}
else
{
- fill = (fill_type *) xmalloc (4 + sizeof (*fill) - 1);
+ fill = xmalloc (4 + sizeof (*fill) - 1);
val = r.value;
fill->data[0] = (val >> 24) & 0xff;
fill->data[1] = (val >> 16) & 0xff;
@@ -1152,11 +1064,10 @@ exp_get_fill (tree, def, name, allocation_done)
}
bfd_vma
-exp_get_abs_int (tree, def, name, allocation_done)
- etree_type *tree;
- int def ATTRIBUTE_UNUSED;
- char *name;
- lang_phase_type allocation_done;
+exp_get_abs_int (etree_type *tree,
+ int def ATTRIBUTE_UNUSED,
+ char *name,
+ lang_phase_type allocation_done)
{
etree_value_type res;
res = exp_fold_tree_no_dot (tree, abs_output_section, allocation_done);
@@ -1169,9 +1080,8 @@ exp_get_abs_int (tree, def, name, allocation_done)
return res.value;
}
-bfd_vma align_n (value, align)
- bfd_vma value;
- bfd_vma align;
+static bfd_vma
+align_n (bfd_vma value, bfd_vma align)
{
if (align <= 1)
return value;
diff --git a/contrib/binutils/ld/ldexp.h b/contrib/binutils/ld/ldexp.h
index 3f3508e..99e7073 100644
--- a/contrib/binutils/ld/ldexp.h
+++ b/contrib/binutils/ld/ldexp.h
@@ -1,6 +1,6 @@
/* ldexp.h -
- Copyright 1991, 1992, 1993, 1994, 1995, 1998, 1999, 2000, 2001, 2002
- Free Software Foundation, Inc.
+ Copyright 1991, 1992, 1993, 1994, 1995, 1998, 1999, 2000, 2001, 2002,
+ 2003, 2004 Free Software Foundation, Inc.
This file is part of GLD, the Gnu Linker.
@@ -27,23 +27,25 @@ typedef struct {
bfd_vma value;
char *str;
struct lang_output_section_statement_struct *section;
- boolean valid_p;
+ bfd_boolean valid_p;
} etree_value_type;
typedef struct {
int node_code;
- enum { etree_binary,
- etree_trinary,
- etree_unary,
- etree_name,
- etree_assign,
- etree_provide,
- etree_provided,
- etree_undef,
- etree_unspec,
- etree_value,
- etree_assert,
- etree_rel } node_class;
+ enum {
+ etree_binary,
+ etree_trinary,
+ etree_unary,
+ etree_name,
+ etree_assign,
+ etree_provide,
+ etree_provided,
+ etree_undef,
+ etree_unspec,
+ etree_value,
+ etree_assert,
+ etree_rel
+ } node_class;
} node_type;
typedef union etree_union {
@@ -101,27 +103,40 @@ extern struct exp_data_seg {
typedef struct _fill_type fill_type;
-etree_type *exp_intop PARAMS ((bfd_vma));
-etree_type *exp_bigintop PARAMS ((bfd_vma, char *));
-etree_type *exp_relop PARAMS ((asection *, bfd_vma));
-etree_value_type invalid PARAMS ((void));
-etree_value_type exp_fold_tree PARAMS ((etree_type *, struct
- lang_output_section_statement_struct *,
- lang_phase_type,
- bfd_vma, bfd_vma *));
-etree_type *exp_binop PARAMS ((int, etree_type *, etree_type *));
-etree_type *exp_trinop PARAMS ((int,etree_type *, etree_type *, etree_type *));
-etree_type *exp_unop PARAMS ((int, etree_type *));
-etree_type *exp_nameop PARAMS ((int, const char *));
-etree_type *exp_assop PARAMS ((int, const char *, etree_type *));
-etree_type *exp_provide PARAMS ((const char *, etree_type *));
-etree_type *exp_assert PARAMS ((etree_type *, const char *));
-void exp_print_tree PARAMS ((etree_type *));
-bfd_vma exp_get_vma PARAMS ((etree_type *, bfd_vma, char *, lang_phase_type));
-int exp_get_value_int PARAMS ((etree_type *, int, char *, lang_phase_type));
-fill_type *exp_get_fill PARAMS ((etree_type *, fill_type *, char *,
- lang_phase_type));
-bfd_vma exp_get_abs_int PARAMS ((etree_type *, int, char *, lang_phase_type));
-bfd_vma align_n PARAMS ((bfd_vma, bfd_vma));
+etree_type *exp_intop
+ (bfd_vma);
+etree_type *exp_bigintop
+ (bfd_vma, char *);
+etree_type *exp_relop
+ (asection *, bfd_vma);
+etree_value_type invalid
+ (void);
+etree_value_type exp_fold_tree
+ (etree_type *, struct lang_output_section_statement_struct *,
+ lang_phase_type, bfd_vma, bfd_vma *);
+etree_type *exp_binop
+ (int, etree_type *, etree_type *);
+etree_type *exp_trinop
+ (int,etree_type *, etree_type *, etree_type *);
+etree_type *exp_unop
+ (int, etree_type *);
+etree_type *exp_nameop
+ (int, const char *);
+etree_type *exp_assop
+ (int, const char *, etree_type *);
+etree_type *exp_provide
+ (const char *, etree_type *);
+etree_type *exp_assert
+ (etree_type *, const char *);
+void exp_print_tree
+ (etree_type *);
+bfd_vma exp_get_vma
+ (etree_type *, bfd_vma, char *, lang_phase_type);
+int exp_get_value_int
+ (etree_type *, int, char *, lang_phase_type);
+fill_type *exp_get_fill
+ (etree_type *, fill_type *, char *, lang_phase_type);
+bfd_vma exp_get_abs_int
+ (etree_type *, int, char *, lang_phase_type);
#endif
diff --git a/contrib/binutils/ld/ldfile.c b/contrib/binutils/ld/ldfile.c
index d706eec..a6f0d60 100644
--- a/contrib/binutils/ld/ldfile.c
+++ b/contrib/binutils/ld/ldfile.c
@@ -1,23 +1,23 @@
/* Linker file opening and searching.
- Copyright 1991, 1992, 1993, 1994, 1995, 1998, 1999, 2000, 2001, 2002
- Free Software Foundation, Inc.
+ Copyright 1991, 1992, 1993, 1994, 1995, 1998, 1999, 2000, 2001, 2002,
+ 2003, 2004 Free Software Foundation, Inc.
-This file is part of GLD, the Gnu Linker.
+ This file is part of GLD, the Gnu Linker.
-GLD is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
+ GLD is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
-GLD is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ GLD is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with GLD; see the file COPYING. If not, write to the Free
-Software Foundation, 59 Temple Place - Suite 330, Boston, MA
-02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with GLD; see the file COPYING. If not, write to the Free
+ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA. */
/* ldfile.c: look after all the file stuff. */
@@ -35,67 +35,106 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
#include "ldlex.h"
#include "ldemul.h"
#include "libiberty.h"
+#include "filenames.h"
-const char *ldfile_input_filename;
-boolean ldfile_assumed_script = false;
-const char *ldfile_output_machine_name = "";
+const char * ldfile_input_filename;
+bfd_boolean ldfile_assumed_script = FALSE;
+const char * ldfile_output_machine_name = "";
unsigned long ldfile_output_machine;
enum bfd_architecture ldfile_output_architecture;
-search_dirs_type *search_head;
+search_dirs_type * search_head;
#ifndef MPW
#ifdef VMS
-char *slash = "";
+char * slash = "";
#else
#if defined (_WIN32) && ! defined (__CYGWIN32__)
-char *slash = "\\";
+char * slash = "\\";
#else
-char *slash = "/";
+char * slash = "/";
#endif
#endif
#else /* MPW */
/* The MPW path char is a colon. */
-char *slash = ":";
+char * slash = ":";
#endif /* MPW */
-/* LOCAL */
-
-static search_dirs_type **search_tail_ptr = &search_head;
-
-typedef struct search_arch {
+typedef struct search_arch
+{
char *name;
struct search_arch *next;
} search_arch_type;
+static search_dirs_type **search_tail_ptr = &search_head;
static search_arch_type *search_arch_head;
static search_arch_type **search_arch_tail_ptr = &search_arch_head;
-static FILE *try_open PARAMS ((const char *name, const char *exten));
+/* Test whether a pathname, after canonicalization, is the same or a
+ sub-directory of the sysroot directory. */
+
+static bfd_boolean
+is_sysrooted_pathname (const char *name, bfd_boolean notsame)
+{
+ char * realname = ld_canon_sysroot ? lrealpath (name) : NULL;
+ int len;
+ bfd_boolean result;
+
+ if (! realname)
+ return FALSE;
+
+ len = strlen (realname);
+
+ if (((! notsame && len == ld_canon_sysroot_len)
+ || (len >= ld_canon_sysroot_len
+ && IS_DIR_SEPARATOR (realname[ld_canon_sysroot_len])
+ && (realname[ld_canon_sysroot_len] = '\0') == '\0'))
+ && FILENAME_CMP (ld_canon_sysroot, realname) == 0)
+ result = TRUE;
+ else
+ result = FALSE;
+
+ if (realname)
+ free (realname);
+
+ return result;
+}
+
+/* Adds NAME to the library search path.
+ Makes a copy of NAME using xmalloc(). */
void
-ldfile_add_library_path (name, cmdline)
- const char *name;
- boolean cmdline;
+ldfile_add_library_path (const char *name, bfd_boolean cmdline)
{
search_dirs_type *new;
if (!cmdline && config.only_cmd_line_lib_dirs)
return;
- new = (search_dirs_type *) xmalloc (sizeof (search_dirs_type));
+ new = xmalloc (sizeof (search_dirs_type));
new->next = NULL;
- new->name = name;
new->cmdline = cmdline;
*search_tail_ptr = new;
search_tail_ptr = &new->next;
+
+ /* If a directory is marked as honoring sysroot, prepend the sysroot path
+ now. */
+ if (name[0] == '=')
+ {
+ new->name = concat (ld_sysroot, name + 1, NULL);
+ new->sysrooted = TRUE;
+ }
+ else
+ {
+ new->name = xstrdup (name);
+ new->sysrooted = is_sysrooted_pathname (name, FALSE);
+ }
}
/* Try to open a BFD for a lang_input_statement. */
-boolean
-ldfile_try_open_bfd (attempt, entry)
- const char *attempt;
- lang_input_statement_type *entry;
+bfd_boolean
+ldfile_try_open_bfd (const char *attempt,
+ lang_input_statement_type *entry)
{
entry->the_bfd = bfd_openr (attempt, entry->target);
@@ -111,7 +150,7 @@ ldfile_try_open_bfd (attempt, entry)
{
if (bfd_get_error () == bfd_error_invalid_target)
einfo (_("%F%P: invalid BFD target `%s'\n"), entry->target);
- return false;
+ return FALSE;
}
/* If we are searching for this file, see if the architecture is
@@ -142,8 +181,8 @@ ldfile_try_open_bfd (attempt, entry)
/* Try to interpret the file as a linker script. */
ldfile_open_command_file (attempt);
-
- ldfile_assumed_script = true;
+
+ ldfile_assumed_script = TRUE;
parser_input = input_selected;
ldlex_both ();
token = INPUT_SCRIPT;
@@ -207,10 +246,11 @@ ldfile_try_open_bfd (attempt, entry)
if (yylval.bigint.str)
free (yylval.bigint.str);
break;
- }
+ }
token = yylex ();
}
- ldfile_assumed_script = false;
+ ldlex_popstate ();
+ ldfile_assumed_script = FALSE;
fclose (yyin);
yyin = NULL;
if (skip)
@@ -219,14 +259,15 @@ ldfile_try_open_bfd (attempt, entry)
attempt, entry->local_sym_name);
bfd_close (entry->the_bfd);
entry->the_bfd = NULL;
- return false;
+ return FALSE;
}
}
- return true;
+ return TRUE;
}
- if ((bfd_arch_get_compatible (check, output_bfd) == NULL)
- /* XCOFF archives can have 32 and 64 bit objects */
+ if ((bfd_arch_get_compatible (check, output_bfd,
+ command_line.accept_unknown_input_arch) == NULL)
+ /* XCOFF archives can have 32 and 64 bit objects. */
&& ! (bfd_get_flavour (check) == bfd_target_xcoff_flavour
&& bfd_get_flavour (output_bfd) == bfd_target_xcoff_flavour
&& bfd_check_format (entry->the_bfd, bfd_archive)))
@@ -235,23 +276,22 @@ ldfile_try_open_bfd (attempt, entry)
attempt, entry->local_sym_name);
bfd_close (entry->the_bfd);
entry->the_bfd = NULL;
- return false;
+ return FALSE;
}
}
}
- return true;
+ return TRUE;
}
/* Search for and open the file specified by ENTRY. If it is an
archive, use ARCH, LIB and SUFFIX to modify the file name. */
-boolean
-ldfile_open_file_search (arch, entry, lib, suffix)
- const char *arch;
- lang_input_statement_type *entry;
- const char *lib;
- const char *suffix;
+bfd_boolean
+ldfile_open_file_search (const char *arch,
+ lang_input_statement_type *entry,
+ const char *lib,
+ const char *suffix)
{
search_dirs_type *search;
@@ -259,61 +299,72 @@ ldfile_open_file_search (arch, entry, lib, suffix)
directory first. */
if (! entry->is_archive)
{
- if (ldfile_try_open_bfd (entry->filename, entry))
- return true;
+ if (entry->sysrooted && IS_ABSOLUTE_PATH (entry->filename))
+ {
+ char *name = concat (ld_sysroot, entry->filename,
+ (const char *) NULL);
+ if (ldfile_try_open_bfd (name, entry))
+ {
+ entry->filename = name;
+ return TRUE;
+ }
+ free (name);
+ }
+ else if (ldfile_try_open_bfd (entry->filename, entry))
+ {
+ entry->sysrooted = IS_ABSOLUTE_PATH (entry->filename)
+ && is_sysrooted_pathname (entry->filename, TRUE);
+ return TRUE;
+ }
+
+ if (IS_ABSOLUTE_PATH (entry->filename))
+ return FALSE;
}
- for (search = search_head;
- search != (search_dirs_type *) NULL;
- search = search->next)
+ for (search = search_head; search != NULL; search = search->next)
{
char *string;
- if (entry->dynamic && ! link_info.relocateable)
+ if (entry->dynamic && ! link_info.relocatable)
{
if (ldemul_open_dynamic_archive (arch, search, entry))
- return true;
+ {
+ entry->sysrooted = search->sysrooted;
+ return TRUE;
+ }
}
- string = (char *) xmalloc (strlen (search->name)
- + strlen (slash)
- + strlen (lib)
- + strlen (entry->filename)
- + strlen (arch)
- + strlen (suffix)
- + 1);
+ string = xmalloc (strlen (search->name)
+ + strlen (slash)
+ + strlen (lib)
+ + strlen (entry->filename)
+ + strlen (arch)
+ + strlen (suffix)
+ + 1);
if (entry->is_archive)
sprintf (string, "%s%s%s%s%s%s", search->name, slash,
lib, entry->filename, arch, suffix);
- else if (entry->filename[0] == '/' || entry->filename[0] == '.'
-#if defined (__MSDOS__) || defined (_WIN32)
- || entry->filename[0] == '\\'
- || (ISALPHA (entry->filename[0])
- && entry->filename[1] == ':')
-#endif
- )
- strcpy (string, entry->filename);
else
sprintf (string, "%s%s%s", search->name, slash, entry->filename);
if (ldfile_try_open_bfd (string, entry))
{
entry->filename = string;
- return true;
+ entry->sysrooted = search->sysrooted;
+ return TRUE;
}
free (string);
}
- return false;
+ return FALSE;
}
/* Open the input file specified by ENTRY. */
void
-ldfile_open_file (entry)
- lang_input_statement_type *entry;
+ldfile_open_file (lang_input_statement_type *entry)
{
if (entry->the_bfd != NULL)
return;
@@ -323,20 +374,18 @@ ldfile_open_file (entry)
if (ldfile_try_open_bfd (entry->filename, entry))
return;
if (strcmp (entry->filename, entry->local_sym_name) != 0)
- einfo (_("%F%P: cannot open %s for %s: %E\n"),
+ einfo (_("%F%P: %s (%s): No such file: %E\n"),
entry->filename, entry->local_sym_name);
else
- einfo (_("%F%P: cannot open %s: %E\n"), entry->local_sym_name);
+ einfo (_("%F%P: %s: No such file: %E\n"), entry->local_sym_name);
}
else
{
search_arch_type *arch;
- boolean found = false;
+ bfd_boolean found = FALSE;
/* Try to open <filename><suffix> or lib<filename><suffix>.a */
- for (arch = search_arch_head;
- arch != (search_arch_type *) NULL;
- arch = arch->next)
+ for (arch = search_arch_head; arch != NULL; arch = arch->next)
{
found = ldfile_open_file_search (arch->name, entry, "lib", ".a");
if (found)
@@ -354,7 +403,12 @@ ldfile_open_file (entry)
/* If we have found the file, we don't need to search directories
again. */
if (found)
- entry->search_dirs_flag = false;
+ entry->search_dirs_flag = FALSE;
+ else if (entry->sysrooted
+ && ld_sysroot
+ && IS_ABSOLUTE_PATH (entry->local_sym_name))
+ einfo (_("%F%P: cannot find %s inside %s\n"),
+ entry->local_sym_name, ld_sysroot);
else
einfo (_("%F%P: cannot find %s\n"), entry->local_sym_name);
}
@@ -363,9 +417,7 @@ ldfile_open_file (entry)
/* Try to open NAME; if that fails, try NAME with EXTEN appended to it. */
static FILE *
-try_open (name, exten)
- const char *name;
- const char *exten;
+try_open (const char *name, const char *exten)
{
FILE *result;
char buff[1000];
@@ -401,12 +453,10 @@ try_open (name, exten)
}
/* Try to open NAME; if that fails, look for it in any directories
- specified with -L, without and with EXTEND apppended. */
+ specified with -L, without and with EXTEND appended. */
FILE *
-ldfile_find_command_file (name, extend)
- const char *name;
- const char *extend;
+ldfile_find_command_file (const char *name, const char *extend)
{
search_dirs_type *search;
FILE *result;
@@ -414,12 +464,10 @@ ldfile_find_command_file (name, extend)
/* First try raw name. */
result = try_open (name, "");
- if (result == (FILE *) NULL)
+ if (result == NULL)
{
/* Try now prefixes. */
- for (search = search_head;
- search != (search_dirs_type *) NULL;
- search = search->next)
+ for (search = search_head; search != NULL; search = search->next)
{
sprintf (buffer, "%s%s%s", search->name, slash, name);
@@ -433,13 +481,12 @@ ldfile_find_command_file (name, extend)
}
void
-ldfile_open_command_file (name)
- const char *name;
+ldfile_open_command_file (const char *name)
{
FILE *ldlex_input_stack;
ldlex_input_stack = ldfile_find_command_file (name, "");
- if (ldlex_input_stack == (FILE *) NULL)
+ if (ldlex_input_stack == NULL)
{
bfd_set_error (bfd_error_system_call);
einfo (_("%P%F: cannot open linker script file %s: %E\n"), name);
@@ -455,8 +502,7 @@ ldfile_open_command_file (name)
#ifdef GNU960
static char *
-gnu960_map_archname (name)
- char *name;
+gnu960_map_archname (char *name)
{
struct tabentry { char *cmd_switch; char *arch; };
static struct tabentry arch_tab[] =
@@ -486,11 +532,9 @@ gnu960_map_archname (name)
}
void
-ldfile_add_arch (name)
- char *name;
+ldfile_add_arch (char *name)
{
- search_arch_type *new =
- (search_arch_type *) xmalloc ((bfd_size_type) (sizeof (search_arch_type)));
+ search_arch_type *new = xmalloc (sizeof (search_arch_type));
if (*name != '\0')
{
@@ -503,7 +547,7 @@ ldfile_add_arch (name)
ldfile_output_machine_name = name;
}
- new->next = (search_arch_type *) NULL;
+ new->next = NULL;
new->name = gnu960_map_archname (name);
*search_arch_tail_ptr = new;
search_arch_tail_ptr = &new->next;
@@ -512,17 +556,15 @@ ldfile_add_arch (name)
#else /* not GNU960 */
void
-ldfile_add_arch (in_name)
- const char *in_name;
+ldfile_add_arch (const char *in_name)
{
char *name = xstrdup (in_name);
- search_arch_type *new =
- (search_arch_type *) xmalloc (sizeof (search_arch_type));
+ search_arch_type *new = xmalloc (sizeof (search_arch_type));
ldfile_output_machine_name = in_name;
new->name = name;
- new->next = (search_arch_type *) NULL;
+ new->next = NULL;
while (*name)
{
*name = TOLOWER (*name);
@@ -537,8 +579,7 @@ ldfile_add_arch (in_name)
/* Set the output architecture. */
void
-ldfile_set_output_arch (string)
- const char *string;
+ldfile_set_output_arch (const char *string, enum bfd_architecture defarch)
{
const bfd_arch_info_type *arch = bfd_scan_arch (string);
@@ -548,8 +589,8 @@ ldfile_set_output_arch (string)
ldfile_output_machine = arch->mach;
ldfile_output_machine_name = arch->printable_name;
}
+ else if (defarch != bfd_arch_unknown)
+ ldfile_output_architecture = defarch;
else
- {
- einfo (_("%P%F: cannot represent machine `%s'\n"), string);
- }
+ einfo (_("%P%F: cannot represent machine `%s'\n"), string);
}
diff --git a/contrib/binutils/ld/ldfile.h b/contrib/binutils/ld/ldfile.h
index 11a4232..6d5f09d 100644
--- a/contrib/binutils/ld/ldfile.h
+++ b/contrib/binutils/ld/ldfile.h
@@ -1,12 +1,12 @@
/* ldfile.h -
- Copyright 1991, 1992, 1993, 1994, 1995, 2000, 2002
+ Copyright 1991, 1992, 1993, 1994, 1995, 2000, 2002, 2003, 2004
Free Software Foundation, Inc.
This file is part of GLD, the Gnu Linker.
GLD is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 1, or (at your option)
+ the Free Software Foundation; either version 2, or (at your option)
any later version.
GLD is distributed in the hope that it will be useful,
@@ -16,13 +16,14 @@
You should have received a copy of the GNU General Public License
along with GLD; see the file COPYING. If not, write to
- the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ the Free Software Foundation, 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
#ifndef LDFILE_H
#define LDFILE_H
extern const char *ldfile_input_filename;
-extern boolean ldfile_assumed_script;
+extern bfd_boolean ldfile_assumed_script;
extern unsigned long ldfile_output_machine;
extern enum bfd_architecture ldfile_output_architecture;
extern const char *ldfile_output_machine_name;
@@ -35,23 +36,30 @@ typedef struct search_dirs {
struct search_dirs *next;
/* Name of directory. */
const char *name;
- /* true if this is from the command line. */
- boolean cmdline;
+ /* TRUE if this is from the command line. */
+ bfd_boolean cmdline;
+ /* true if this is from within the sys-root. */
+ bfd_boolean sysrooted;
} search_dirs_type;
extern search_dirs_type *search_head;
-extern void ldfile_add_arch PARAMS ((const char *));
-extern void ldfile_add_library_path PARAMS ((const char *, boolean cmdline));
-extern void ldfile_open_command_file PARAMS ((const char *name));
-extern void ldfile_open_file PARAMS ((struct lang_input_statement_struct *));
-extern boolean ldfile_try_open_bfd
- PARAMS ((const char *, struct lang_input_statement_struct *));
+extern void ldfile_add_arch
+ (const char *);
+extern void ldfile_add_library_path
+ (const char *, bfd_boolean cmdline);
+extern void ldfile_open_command_file
+ (const char *name);
+extern void ldfile_open_file
+ (struct lang_input_statement_struct *);
+extern bfd_boolean ldfile_try_open_bfd
+ (const char *, struct lang_input_statement_struct *);
extern FILE *ldfile_find_command_file
- PARAMS ((const char *name, const char *extend));
-extern void ldfile_set_output_arch PARAMS ((const char *));
-extern boolean ldfile_open_file_search
- PARAMS ((const char *arch, struct lang_input_statement_struct *,
- const char *lib, const char *suffix));
+ (const char *name, const char *extend);
+extern void ldfile_set_output_arch
+ (const char *, enum bfd_architecture);
+extern bfd_boolean ldfile_open_file_search
+ (const char *arch, struct lang_input_statement_struct *,
+ const char *lib, const char *suffix);
#endif
diff --git a/contrib/binutils/ld/ldgram.y b/contrib/binutils/ld/ldgram.y
index d2533c2..6c46c85 100644
--- a/contrib/binutils/ld/ldgram.y
+++ b/contrib/binutils/ld/ldgram.y
@@ -1,6 +1,6 @@
/* A YACC grammar to parse a superset of the AT&T linker scripting language.
Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
- 2001, 2002 Free Software Foundation, Inc.
+ 2001, 2002, 2003 Free Software Foundation, Inc.
Written by Steve Chamberlain of Cygnus Support (steve@cygnus.com).
This file is part of GNU ld.
@@ -29,7 +29,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "bfd.h"
#include "sysdep.h"
#include "bfdlink.h"
-#include "ld.h"
+#include "ld.h"
#include "ldexp.h"
#include "ldver.h"
#include "ldlang.h"
@@ -49,13 +49,13 @@ static enum section_type sectype;
lang_memory_region_type *region;
-boolean ldgram_want_filename = true;
-FILE * saved_script_handle = NULL;
-boolean force_make_executable = false;
+bfd_boolean ldgram_want_filename = TRUE;
+FILE *saved_script_handle = NULL;
+bfd_boolean force_make_executable = FALSE;
-boolean ldgram_in_script = false;
-boolean ldgram_had_equals = false;
-boolean ldgram_had_keep = false;
+bfd_boolean ldgram_in_script = FALSE;
+bfd_boolean ldgram_had_equals = FALSE;
+bfd_boolean ldgram_had_keep = FALSE;
char *ldgram_vers_current_lang = NULL;
#define ERROR_NAME_MAX 20
@@ -81,8 +81,8 @@ static int error_index;
union etree_union *etree;
struct phdr_info
{
- boolean filehdr;
- boolean phdrs;
+ bfd_boolean filehdr;
+ bfd_boolean phdrs;
union etree_union *at;
union etree_union *flags;
} phdr;
@@ -94,7 +94,7 @@ static int error_index;
}
%type <etree> exp opt_exp_with_type mustbe_exp opt_at phdr_type phdr_val
-%type <etree> opt_exp_without_type
+%type <etree> opt_exp_without_type opt_subalign
%type <fill> fill_opt fill_exp
%type <name_list> exclude_name_list
%type <wildcard_list> file_NAME_list
@@ -102,7 +102,7 @@ static int error_index;
%type <name> memspec_at_opt
%type <cname> wildcard_name
%type <wildcard> wildcard_spec
-%token <bigint> INT
+%token <bigint> INT
%token <name> NAME LNAME
%type <integer> length
%type <phdr> phdr_qualifiers
@@ -110,7 +110,7 @@ static int error_index;
%type <section_phdr> phdr_opt
%type <integer> opt_nocrossrefs
-%right <token> PLUSEQ MINUSEQ MULTEQ DIVEQ '=' LSHIFTEQ RSHIFTEQ ANDEQ OREQ
+%right <token> PLUSEQ MINUSEQ MULTEQ DIVEQ '=' LSHIFTEQ RSHIFTEQ ANDEQ OREQ
%right <token> '?' ':'
%left <token> OROR
%left <token> ANDAND
@@ -125,7 +125,7 @@ static int error_index;
%left <token> '*' '/' '%'
%right UNARY
-%token END
+%token END
%left <token> '('
%token <token> ALIGN_K BLOCK BIND QUAD SQUAD LONG SHORT BYTE
%token SECTIONS PHDRS SORT DATA_SEGMENT_ALIGN DATA_SEGMENT_END
@@ -142,7 +142,7 @@ static int error_index;
%token STARTUP HLL SYSLIB FLOAT NOFLOAT NOCROSSREFS
%token ORIGIN FILL
%token LENGTH CREATE_OBJECT_SYMBOLS INPUT GROUP OUTPUT CONSTRUCTORS
-%token ALIGNMOD AT PROVIDE
+%token ALIGNMOD AT SUBALIGN PROVIDE
%type <token> assign_op atype attributes_opt
%type <name> filename
%token CHIP LIST SECT ABSOLUTE LOAD NEWLINE ENDWORD ORDER NAMEWORD ASSERT_K
@@ -158,7 +158,7 @@ static int error_index;
%%
-file:
+file:
INPUT_SCRIPT script_file
| INPUT_MRI_SCRIPT mri_script_file
| INPUT_VERSION_SCRIPT version_script_file
@@ -178,7 +178,7 @@ defsym_expr:
}
;
-/* SYNTAX WITHIN AN MRI SCRIPT FILE */
+/* SYNTAX WITHIN AN MRI SCRIPT FILE */
mri_script_file:
{
ldlex_mri_script ();
@@ -198,7 +198,7 @@ mri_script_lines:
;
mri_script_command:
- CHIP exp
+ CHIP exp
| CHIP exp ',' exp
| NAME {
einfo(_("%P%F: unrecognised keyword in MRI style script '%s'\n"),$1);
@@ -207,12 +207,12 @@ mri_script_command:
config.map_filename = "-";
}
| ORDER ordernamelist
- | ENDWORD
+ | ENDWORD
| PUBLIC NAME '=' exp
{ mri_public($2, $4); }
| PUBLIC NAME ',' exp
{ mri_public($2, $4); }
- | PUBLIC NAME exp
+ | PUBLIC NAME exp
{ mri_public($2, $3); }
| FORMAT NAME
{ mri_format($2); }
@@ -232,8 +232,8 @@ mri_script_command:
{ mri_alignmod($2,$4); }
| ABSOLUTE mri_abs_name_list
| LOAD mri_load_name_list
- | NAMEWORD NAME
- { mri_name($2); }
+ | NAMEWORD NAME
+ { mri_name($2); }
| ALIAS NAME ',' NAME
{ mri_alias($2,$4,0);}
| ALIAS NAME ',' INT
@@ -249,7 +249,7 @@ mri_script_command:
mri_script_lines END
{ ldlex_popstate (); }
| START NAME
- { lang_add_entry ($2, false); }
+ { lang_add_entry ($2, FALSE); }
|
;
@@ -319,7 +319,7 @@ ifile_p1:
| TARGET_K '(' NAME ')'
{ lang_add_target($3); }
| SEARCH_DIR '(' filename ')'
- { ldfile_add_library_path ($3, false); }
+ { ldfile_add_library_path ($3, FALSE); }
| OUTPUT '(' filename ')'
{ lang_add_output($3, 1); }
| OUTPUT_FORMAT '(' NAME ')'
@@ -328,11 +328,11 @@ ifile_p1:
| OUTPUT_FORMAT '(' NAME ',' NAME ',' NAME ')'
{ lang_add_output_format ($3, $5, $7, 1); }
| OUTPUT_ARCH '(' NAME ')'
- { ldfile_set_output_arch($3); }
+ { ldfile_set_output_arch ($3, bfd_arch_unknown); }
| FORCE_COMMON_ALLOCATION
- { command_line.force_common_definition = true ; }
+ { command_line.force_common_definition = TRUE ; }
| INHIBIT_COMMON_ALLOCATION
- { command_line.inhibit_common_definition = true ; }
+ { command_line.inhibit_common_definition = TRUE ; }
| INPUT '(' input_list ')'
| GROUP
{ lang_enter_group (); }
@@ -340,7 +340,7 @@ ifile_p1:
{ lang_leave_group (); }
| MAP '(' filename ')'
{ lang_add_map($3); }
- | INCLUDE filename
+ | INCLUDE filename
{ ldlex_script (); ldfile_open_command_file($2); }
ifile_list END
{ ldlex_popstate (); }
@@ -384,8 +384,11 @@ sec_or_group_p1:
statement_anywhere:
ENTRY '(' NAME ')'
- { lang_add_entry ($3, false); }
+ { lang_add_entry ($3, FALSE); }
| assignment end
+ | ASSERT_K {ldlex_expression ();} '(' exp ',' NAME ')'
+ { ldlex_popstate ();
+ lang_add_assignment (exp_assert ($4, $6)); }
;
/* The '*' and '?' cases are there because the lexer returns them as
@@ -409,25 +412,25 @@ wildcard_spec:
wildcard_name
{
$$.name = $1;
- $$.sorted = false;
+ $$.sorted = FALSE;
$$.exclude_name_list = NULL;
}
| EXCLUDE_FILE '(' exclude_name_list ')' wildcard_name
{
$$.name = $5;
- $$.sorted = false;
+ $$.sorted = FALSE;
$$.exclude_name_list = $3;
}
| SORT '(' wildcard_name ')'
{
$$.name = $3;
- $$.sorted = true;
+ $$.sorted = TRUE;
$$.exclude_name_list = NULL;
}
| SORT '(' EXCLUDE_FILE '(' exclude_name_list ')' wildcard_name ')'
{
$$.name = $7;
- $$.sorted = true;
+ $$.sorted = TRUE;
$$.exclude_name_list = $5;
}
;
@@ -439,7 +442,7 @@ exclude_name_list:
tmp = (struct name_list *) xmalloc (sizeof *tmp);
tmp->name = $2;
tmp->next = $1;
- $$ = tmp;
+ $$ = tmp;
}
|
wildcard_name
@@ -478,7 +481,7 @@ input_section_spec_no_keep:
struct wildcard_spec tmp;
tmp.name = $1;
tmp.exclude_name_list = NULL;
- tmp.sorted = false;
+ tmp.sorted = FALSE;
lang_add_wild (&tmp, NULL, ldgram_had_keep);
}
| '[' file_NAME_list ']'
@@ -494,26 +497,26 @@ input_section_spec_no_keep:
input_section_spec:
input_section_spec_no_keep
| KEEP '('
- { ldgram_had_keep = true; }
+ { ldgram_had_keep = TRUE; }
input_section_spec_no_keep ')'
- { ldgram_had_keep = false; }
+ { ldgram_had_keep = FALSE; }
;
statement:
assignment end
| CREATE_OBJECT_SYMBOLS
{
- lang_add_attribute(lang_object_symbols_statement_enum);
+ lang_add_attribute(lang_object_symbols_statement_enum);
}
| ';'
| CONSTRUCTORS
{
-
- lang_add_attribute(lang_constructors_statement_enum);
+
+ lang_add_attribute(lang_constructors_statement_enum);
}
| SORT '(' CONSTRUCTORS ')'
{
- constructors_sorted = true;
+ constructors_sorted = TRUE;
lang_add_attribute (lang_constructors_statement_enum);
}
| input_section_spec
@@ -521,7 +524,7 @@ statement:
{
lang_add_data ((int) $1, $3);
}
-
+
| FILL '(' fill_exp ')'
{
lang_add_fill ($3);
@@ -532,7 +535,7 @@ statement_list:
statement_list statement
| statement
;
-
+
statement_list_opt:
/* empty */
| statement_list
@@ -627,7 +630,7 @@ memory_spec_list:
memory_spec: NAME
- { region = lang_memory_region_lookup($1); }
+ { region = lang_memory_region_lookup ($1, TRUE); }
attributes_opt ':'
origin_spec opt_comma length_spec
{}
@@ -697,11 +700,11 @@ low_level_library:
floating_point_support:
FLOAT
- { lang_float(true); }
+ { lang_float(TRUE); }
| NOFLOAT
- { lang_float(false); }
+ { lang_float(FALSE); }
;
-
+
nocrossref_list:
/* empty */
{
@@ -801,6 +804,8 @@ exp :
{ $$ = exp_unop(ABSOLUTE, $3); }
| ALIGN_K '(' exp ')'
{ $$ = exp_unop(ALIGN_K,$3); }
+ | ALIGN_K '(' exp ',' exp ')'
+ { $$ = exp_binop(ALIGN_K,$3,$5); }
| DATA_SEGMENT_ALIGN '(' exp ',' exp ')'
{ $$ = exp_binop (DATA_SEGMENT_ALIGN, $3, $5); }
| DATA_SEGMENT_END '(' exp ')'
@@ -828,31 +833,37 @@ opt_at:
| { $$ = 0; }
;
+opt_subalign:
+ SUBALIGN '(' exp ')' { $$ = $3; }
+ | { $$ = 0; }
+ ;
+
section: NAME { ldlex_expression(); }
- opt_exp_with_type
- opt_at { ldlex_popstate (); ldlex_script (); }
+ opt_exp_with_type
+ opt_at
+ opt_subalign { ldlex_popstate (); ldlex_script (); }
'{'
{
lang_enter_output_section_statement($1, $3,
sectype,
- 0, 0, 0, $4);
+ 0, $5, $4);
}
- statement_list_opt
+ statement_list_opt
'}' { ldlex_popstate (); ldlex_expression (); }
memspec_opt memspec_at_opt phdr_opt fill_opt
{
ldlex_popstate ();
- lang_leave_output_section_statement ($14, $11, $13, $12);
+ lang_leave_output_section_statement ($15, $12, $14, $13);
}
opt_comma
{}
| OVERLAY
{ ldlex_expression (); }
- opt_exp_without_type opt_nocrossrefs opt_at
+ opt_exp_without_type opt_nocrossrefs opt_at opt_subalign
{ ldlex_popstate (); ldlex_script (); }
- '{'
+ '{'
{
- lang_enter_overlay ($3);
+ lang_enter_overlay ($3, $6);
}
overlay_section
'}'
@@ -861,7 +872,7 @@ section: NAME { ldlex_expression(); }
{
ldlex_popstate ();
lang_leave_overlay ($5, (int) $4,
- $15, $12, $14, $13);
+ $16, $13, $15, $14);
}
opt_comma
| /* The GROUP case is just enough to support the gcc
@@ -918,7 +929,7 @@ opt_nocrossrefs:
memspec_opt:
'>' NAME
{ $$ = $2; }
- | { $$ = "*default*"; }
+ | { $$ = DEFAULT_MEMORY_REGION; }
;
phdr_opt:
@@ -933,7 +944,7 @@ phdr_opt:
n = ((struct lang_output_section_phdr_list *)
xmalloc (sizeof *n));
n->name = $3;
- n->used = false;
+ n->used = FALSE;
n->next = $1;
$$ = n;
}
@@ -990,7 +1001,7 @@ phdr_type:
{
"PT_NULL", "PT_LOAD", "PT_DYNAMIC",
"PT_INTERP", "PT_NOTE", "PT_SHLIB",
- "PT_PHDR"
+ "PT_PHDR", "PT_TLS"
};
s = $1->name.name;
@@ -1002,6 +1013,20 @@ phdr_type:
$$ = exp_intop (i);
break;
}
+ if (i == sizeof phdr_types / sizeof phdr_types[0])
+ {
+ if (strcmp (s, "PT_GNU_EH_FRAME") == 0)
+ $$ = exp_intop (0x6474e550);
+ else if (strcmp (s, "PT_GNU_STACK") == 0)
+ $$ = exp_intop (0x6474e551);
+ else
+ {
+ einfo (_("\
+%X%P:%S: unknown phdr type `%s' (try integer literal)\n"),
+ s);
+ $$ = exp_intop (0);
+ }
+ }
}
}
;
@@ -1015,9 +1040,9 @@ phdr_qualifiers:
{
$$ = $3;
if (strcmp ($1, "FILEHDR") == 0 && $2 == NULL)
- $$.filehdr = true;
+ $$.filehdr = TRUE;
else if (strcmp ($1, "PHDRS") == 0 && $2 == NULL)
- $$.phdrs = true;
+ $$.phdrs = TRUE;
else if (strcmp ($1, "FLAGS") == 0 && $2 != NULL)
$$.flags = $2;
else
@@ -1130,23 +1155,38 @@ vers_defns:
{
$$ = lang_new_vers_pattern ($1, $3, ldgram_vers_current_lang);
}
+ | vers_defns ';' EXTERN NAME '{'
+ {
+ $<name>$ = ldgram_vers_current_lang;
+ ldgram_vers_current_lang = $4;
+ }
+ vers_defns opt_semicolon '}'
+ {
+ $$ = $7;
+ ldgram_vers_current_lang = $<name>6;
+ }
| EXTERN NAME '{'
{
$<name>$ = ldgram_vers_current_lang;
ldgram_vers_current_lang = $2;
}
- vers_defns '}'
+ vers_defns opt_semicolon '}'
{
$$ = $5;
ldgram_vers_current_lang = $<name>4;
}
;
+opt_semicolon:
+ /* empty */
+ | ';'
+ ;
+
%%
void
-yyerror(arg)
+yyerror(arg)
const char *arg;
-{
+{
if (ldfile_assumed_script)
einfo (_("%P:%s: file format not recognized; treating as linker script\n"),
ldfile_input_filename);
diff --git a/contrib/binutils/ld/ldint.texinfo b/contrib/binutils/ld/ldint.texinfo
index 489750a..5486764 100644
--- a/contrib/binutils/ld/ldint.texinfo
+++ b/contrib/binutils/ld/ldint.texinfo
@@ -1,6 +1,6 @@
\input texinfo
@setfilename ldint.info
-@c Copyright 1992, 1994, 1995, 1996, 1997, 1998, 1999, 2000
+@c Copyright 1992, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2003
@c Free Software Foundation, Inc.
@ifinfo
@@ -334,7 +334,7 @@ be run when doing a final relocation, they should be enclosed within a
variable substitution based on @code{RELOCATING}. For example, on many
targets special symbols such as @code{_end} should be defined when doing
a final link. Naturally, those symbols should not be defined when doing
-a relocateable link using @code{-r}. The @file{scripttempl} script
+a relocatable link using @code{-r}. The @file{scripttempl} script
could use a construct like this to define those symbols:
@smallexample
$@{RELOCATING+ _end = .;@}
diff --git a/contrib/binutils/ld/ldlang.c b/contrib/binutils/ld/ldlang.c
index 0eb06b2..0c08601 100644
--- a/contrib/binutils/ld/ldlang.c
+++ b/contrib/binutils/ld/ldlang.c
@@ -1,24 +1,24 @@
/* Linker command language support.
Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
- 2001, 2002
+ 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
-This file is part of GLD, the Gnu Linker.
+ This file is part of GLD, the Gnu Linker.
-GLD is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
+ GLD is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
-GLD is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ GLD is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with GLD; see the file COPYING. If not, write to the Free
-Software Foundation, 59 Temple Place - Suite 330, Boston, MA
-02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with GLD; see the file COPYING. If not, write to the Free
+ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA. */
#include "bfd.h"
#include "sysdep.h"
@@ -39,174 +39,72 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
#include "ldemul.h"
#include "fnmatch.h"
#include "demangle.h"
+#include "hashtab.h"
-/* FORWARDS */
-static lang_statement_union_type *new_statement
- PARAMS ((enum statement_enum, size_t, lang_statement_list_type *));
+#ifndef offsetof
+#define offsetof(TYPE, MEMBER) ((size_t) & (((TYPE*) 0)->MEMBER))
+#endif
-/* LOCALS */
+/* Locals variables. */
static struct obstack stat_obstack;
#define obstack_chunk_alloc xmalloc
#define obstack_chunk_free free
static const char *startup_file;
static lang_statement_list_type input_file_chain;
-static boolean placed_commons = false;
+static bfd_boolean placed_commons = FALSE;
static lang_output_section_statement_type *default_common_section;
-static boolean map_option_f;
+static bfd_boolean map_option_f;
static bfd_vma print_dot;
static lang_input_statement_type *first_file;
static const char *current_target;
static const char *output_target;
static lang_statement_list_type statement_list;
static struct lang_phdr *lang_phdr_list;
-
-static void lang_for_each_statement_worker
- PARAMS ((void (*) (lang_statement_union_type *),
- lang_statement_union_type *));
-static lang_input_statement_type *new_afile
- PARAMS ((const char *, lang_input_file_enum_type, const char *, boolean));
-static lang_memory_region_type *lang_memory_default PARAMS ((asection *));
-static void lang_map_flags PARAMS ((flagword));
-static void init_os PARAMS ((lang_output_section_statement_type *));
-static void exp_init_os PARAMS ((etree_type *));
-static void section_already_linked PARAMS ((bfd *, asection *, PTR));
-static struct bfd_hash_entry *already_linked_newfunc
- PARAMS ((struct bfd_hash_entry *, struct bfd_hash_table *, const char *));
-static void already_linked_table_init PARAMS ((void));
-static void already_linked_table_free PARAMS ((void));
-static boolean wildcardp PARAMS ((const char *));
-static lang_statement_union_type *wild_sort
- PARAMS ((lang_wild_statement_type *, struct wildcard_list *,
- lang_input_statement_type *, asection *));
-static void output_section_callback
- PARAMS ((lang_wild_statement_type *, struct wildcard_list *, asection *,
- lang_input_statement_type *, PTR));
-static lang_input_statement_type *lookup_name PARAMS ((const char *));
-static boolean load_symbols
- PARAMS ((lang_input_statement_type *, lang_statement_list_type *));
-static void wild
- PARAMS ((lang_wild_statement_type *,
- const char *, lang_output_section_statement_type *));
-static bfd *open_output PARAMS ((const char *));
-static void ldlang_open_output PARAMS ((lang_statement_union_type *));
-static void open_input_bfds PARAMS ((lang_statement_union_type *, boolean));
-static void lang_reasonable_defaults PARAMS ((void));
-static void insert_undefined PARAMS ((const char *));
-static void lang_place_undefineds PARAMS ((void));
-static void map_input_to_output_sections
- PARAMS ((lang_statement_union_type *, const char *,
- lang_output_section_statement_type *));
-static void strip_excluded_output_sections PARAMS ((void));
-static void print_output_section_statement
- PARAMS ((lang_output_section_statement_type *));
-static void print_assignment
- PARAMS ((lang_assignment_statement_type *,
- lang_output_section_statement_type *));
-static void print_input_statement PARAMS ((lang_input_statement_type *));
-static boolean print_one_symbol PARAMS ((struct bfd_link_hash_entry *, PTR));
-static void print_input_section PARAMS ((lang_input_section_type *));
-static void print_fill_statement PARAMS ((lang_fill_statement_type *));
-static void print_data_statement PARAMS ((lang_data_statement_type *));
-static void print_address_statement PARAMS ((lang_address_statement_type *));
-static void print_reloc_statement PARAMS ((lang_reloc_statement_type *));
-static void print_padding_statement PARAMS ((lang_padding_statement_type *));
-static void print_wild_statement
- PARAMS ((lang_wild_statement_type *, lang_output_section_statement_type *));
-static void print_group
- PARAMS ((lang_group_statement_type *, lang_output_section_statement_type *));
-static void print_statement
- PARAMS ((lang_statement_union_type *, lang_output_section_statement_type *));
-static void print_statement_list
- PARAMS ((lang_statement_union_type *, lang_output_section_statement_type *));
-static void print_statements PARAMS ((void));
-static void insert_pad
- PARAMS ((lang_statement_union_type **, fill_type *,
- unsigned int, asection *, bfd_vma));
-static bfd_vma size_input_section
- PARAMS ((lang_statement_union_type **, lang_output_section_statement_type *,
- fill_type *, bfd_vma));
-static void lang_finish PARAMS ((void));
-static void ignore_bfd_errors PARAMS ((const char *, ...));
-static void lang_check PARAMS ((void));
-static void lang_common PARAMS ((void));
-static boolean lang_one_common PARAMS ((struct bfd_link_hash_entry *, PTR));
-static void lang_place_orphans PARAMS ((void));
-static int topower PARAMS ((int));
-static void lang_set_startof PARAMS ((void));
-static void gc_section_callback
- PARAMS ((lang_wild_statement_type *, struct wildcard_list *, asection *,
- lang_input_statement_type *, PTR));
-static void lang_get_regions PARAMS ((struct memory_region_struct **,
- struct memory_region_struct **,
- const char *, const char *, int));
-static void lang_record_phdrs PARAMS ((void));
-static void lang_gc_wild PARAMS ((lang_wild_statement_type *));
-static void lang_gc_sections_1 PARAMS ((lang_statement_union_type *));
-static void lang_gc_sections PARAMS ((void));
-static int lang_vers_match_lang_c
- PARAMS ((struct bfd_elf_version_expr *, const char *));
-static int lang_vers_match_lang_cplusplus
- PARAMS ((struct bfd_elf_version_expr *, const char *));
-static int lang_vers_match_lang_java
- PARAMS ((struct bfd_elf_version_expr *, const char *));
-static void lang_do_version_exports_section PARAMS ((void));
-static void lang_check_section_addresses PARAMS ((void));
-static void os_region_check
- PARAMS ((lang_output_section_statement_type *,
- struct memory_region_struct *, etree_type *, bfd_vma));
-static bfd_vma lang_size_sections_1
- PARAMS ((lang_statement_union_type *, lang_output_section_statement_type *,
- lang_statement_union_type **, fill_type *, bfd_vma, boolean *));
-
-typedef void (*callback_t) PARAMS ((lang_wild_statement_type *,
- struct wildcard_list *,
- asection *,
- lang_input_statement_type *,
- PTR));
-static void walk_wild
- PARAMS ((lang_wild_statement_type *, callback_t, PTR));
-static void walk_wild_section
- PARAMS ((lang_wild_statement_type *, lang_input_statement_type *,
- callback_t, PTR));
-static void walk_wild_file
- PARAMS ((lang_wild_statement_type *, lang_input_statement_type *,
- callback_t, PTR));
-
-static int get_target PARAMS ((const bfd_target *, PTR));
-static void stricpy PARAMS ((char *, char *));
-static void strcut PARAMS ((char *, char *));
-static int name_compare PARAMS ((char *, char *));
-static int closest_target_match PARAMS ((const bfd_target *, PTR));
-static char * get_first_input_target PARAMS ((void));
-
-/* EXPORTS */
+static struct bfd_hash_table lang_definedness_table;
+
+/* Forward declarations. */
+static void exp_init_os (etree_type *);
+static bfd_boolean wildcardp (const char *);
+static lang_input_statement_type *lookup_name (const char *);
+static bfd_boolean load_symbols (lang_input_statement_type *,
+ lang_statement_list_type *);
+static struct bfd_hash_entry *lang_definedness_newfunc
+ (struct bfd_hash_entry *, struct bfd_hash_table *, const char *);
+static void insert_undefined (const char *);
+static void print_statement (lang_statement_union_type *,
+ lang_output_section_statement_type *);
+static void print_statement_list (lang_statement_union_type *,
+ lang_output_section_statement_type *);
+static void print_statements (void);
+static bfd_boolean lang_one_common (struct bfd_link_hash_entry *, void *);
+static void lang_record_phdrs (void);
+static void lang_do_version_exports_section (void);
+
+typedef void (*callback_t) (lang_wild_statement_type *, struct wildcard_list *,
+ asection *, lang_input_statement_type *, void *);
+
+/* Exported variables. */
lang_output_section_statement_type *abs_output_section;
lang_statement_list_type lang_output_section_statement;
lang_statement_list_type *stat_ptr = &statement_list;
lang_statement_list_type file_chain = { NULL, NULL };
struct bfd_sym_chain entry_symbol = { NULL, NULL };
const char *entry_section = ".text";
-boolean entry_from_cmdline;
-boolean lang_has_input_file = false;
-boolean had_output_filename = false;
-boolean lang_float_flag = false;
-boolean delete_output_file_on_failure = false;
+bfd_boolean entry_from_cmdline;
+bfd_boolean lang_has_input_file = FALSE;
+bfd_boolean had_output_filename = FALSE;
+bfd_boolean lang_float_flag = FALSE;
+bfd_boolean delete_output_file_on_failure = FALSE;
struct lang_nocrossrefs *nocrossref_list;
struct unique_sections *unique_section_list;
+static bfd_boolean ldlang_sysrooted_script = FALSE;
+int lang_statement_iteration = 0;
etree_type *base; /* Relocation base - or null */
-#if defined (__STDC__) || defined (ALMOST_STDC)
-#define cat(a,b) a##b
-#else
-#define cat(a,b) a/**/b
-#endif
-
-/* Don't beautify the line below with "innocent" whitespace, it breaks
- the K&R C preprocessor! */
#define new_stat(x, y) \
- (cat (x,_type)*) new_statement (cat (x,_enum), sizeof (cat (x,_type)), y)
+ (x##_type *) new_statement (x##_enum, sizeof (x##_type), y)
#define outside_section_address(q) \
((q)->output_offset + (q)->output_section->vma)
@@ -216,16 +114,14 @@ etree_type *base; /* Relocation base - or null */
#define SECTION_NAME_MAP_LENGTH (16)
-PTR
-stat_alloc (size)
- size_t size;
+void *
+stat_alloc (size_t size)
{
return obstack_alloc (&stat_obstack, size);
}
-boolean
-unique_section_p (secnam)
- const char *secnam;
+bfd_boolean
+unique_section_p (const char *secnam)
{
struct unique_sections *unam;
@@ -234,20 +130,19 @@ unique_section_p (secnam)
? fnmatch (unam->name, secnam, 0) == 0
: strcmp (unam->name, secnam) == 0)
{
- return true;
+ return TRUE;
}
- return false;
+ return FALSE;
}
/* Generic traversal routines for finding matching sections. */
static void
-walk_wild_section (ptr, file, callback, data)
- lang_wild_statement_type *ptr;
- lang_input_statement_type *file;
- callback_t callback;
- PTR data;
+walk_wild_section (lang_wild_statement_type *ptr,
+ lang_input_statement_type *file,
+ callback_t callback,
+ void *data)
{
asection *s;
@@ -264,7 +159,7 @@ walk_wild_section (ptr, file, callback, data)
while (sec != NULL)
{
- boolean skip = false;
+ bfd_boolean skip = FALSE;
struct name_list *list_tmp;
/* Don't process sections from files which were
@@ -318,11 +213,10 @@ walk_wild_section (ptr, file, callback, data)
/* Handle a wild statement for a single file F. */
static void
-walk_wild_file (s, f, callback, data)
- lang_wild_statement_type *s;
- lang_input_statement_type *f;
- callback_t callback;
- PTR data;
+walk_wild_file (lang_wild_statement_type *s,
+ lang_input_statement_type *f,
+ callback_t callback,
+ void *data)
{
if (f->the_bfd == NULL
|| ! bfd_check_format (f->the_bfd, bfd_archive))
@@ -333,7 +227,7 @@ walk_wild_file (s, f, callback, data)
/* This is an archive file. We must map each member of the
archive separately. */
- member = bfd_openr_next_archived_file (f->the_bfd, (bfd *) NULL);
+ member = bfd_openr_next_archived_file (f->the_bfd, NULL);
while (member != NULL)
{
/* When lookup_name is called, it will call the add_symbols
@@ -343,9 +237,7 @@ walk_wild_file (s, f, callback, data)
lang_input_statement. */
if (member->usrdata != NULL)
{
- walk_wild_section (s,
- (lang_input_statement_type *) member->usrdata,
- callback, data);
+ walk_wild_section (s, member->usrdata, callback, data);
}
member = bfd_openr_next_archived_file (f->the_bfd, member);
@@ -354,10 +246,7 @@ walk_wild_file (s, f, callback, data)
}
static void
-walk_wild (s, callback, data)
- lang_wild_statement_type *s;
- callback_t callback;
- PTR data;
+walk_wild (lang_wild_statement_type *s, callback_t callback, void *data)
{
const char *file_spec = s->filename;
@@ -392,11 +281,10 @@ walk_wild (s, callback, data)
function for each node. */
static void
-lang_for_each_statement_worker (func, s)
- void (*func) PARAMS ((lang_statement_union_type *));
- lang_statement_union_type *s;
+lang_for_each_statement_worker (void (*func) (lang_statement_union_type *),
+ lang_statement_union_type *s)
{
- for (; s != (lang_statement_union_type *) NULL; s = s->header.next)
+ for (; s != NULL; s = s->header.next)
{
func (s);
@@ -439,8 +327,7 @@ lang_for_each_statement_worker (func, s)
}
void
-lang_for_each_statement (func)
- void (*func) PARAMS ((lang_statement_union_type *));
+lang_for_each_statement (void (*func) (lang_statement_union_type *))
{
lang_for_each_statement_worker (func, statement_list.head);
}
@@ -448,26 +335,24 @@ lang_for_each_statement (func)
/*----------------------------------------------------------------------*/
void
-lang_list_init (list)
- lang_statement_list_type *list;
+lang_list_init (lang_statement_list_type *list)
{
- list->head = (lang_statement_union_type *) NULL;
+ list->head = NULL;
list->tail = &list->head;
}
/* Build a new statement node for the parse tree. */
static lang_statement_union_type *
-new_statement (type, size, list)
- enum statement_enum type;
- size_t size;
- lang_statement_list_type *list;
+new_statement (enum statement_enum type,
+ size_t size,
+ lang_statement_list_type *list)
{
- lang_statement_union_type *new = (lang_statement_union_type *)
- stat_alloc (size);
+ lang_statement_union_type *new;
+ new = stat_alloc (size);
new->header.type = type;
- new->header.next = (lang_statement_union_type *) NULL;
+ new->header.next = NULL;
lang_statement_append (list, new, &new->header.next);
return new;
}
@@ -477,16 +362,15 @@ new_statement (type, size, list)
or prefix it with a -l etc.
We can be supplied with requests for input files more than once;
- they may, for example be split over serveral lines like foo.o(.text)
+ they may, for example be split over several lines like foo.o(.text)
foo.o(.data) etc, so when asked for a file we check that we haven't
got it already so we don't duplicate the bfd. */
static lang_input_statement_type *
-new_afile (name, file_type, target, add_to_list)
- const char *name;
- lang_input_file_enum_type file_type;
- const char *target;
- boolean add_to_list;
+new_afile (const char *name,
+ lang_input_file_enum_type file_type,
+ const char *target,
+ bfd_boolean add_to_list)
{
lang_input_statement_type *p;
@@ -494,74 +378,76 @@ new_afile (name, file_type, target, add_to_list)
p = new_stat (lang_input_statement, stat_ptr);
else
{
- p = ((lang_input_statement_type *)
- stat_alloc (sizeof (lang_input_statement_type)));
+ p = stat_alloc (sizeof (lang_input_statement_type));
p->header.next = NULL;
}
- lang_has_input_file = true;
+ lang_has_input_file = TRUE;
p->target = target;
+ p->sysrooted = FALSE;
switch (file_type)
{
case lang_input_file_is_symbols_only_enum:
p->filename = name;
- p->is_archive = false;
- p->real = true;
+ p->is_archive = FALSE;
+ p->real = TRUE;
p->local_sym_name = name;
- p->just_syms_flag = true;
- p->search_dirs_flag = false;
+ p->just_syms_flag = TRUE;
+ p->search_dirs_flag = FALSE;
break;
case lang_input_file_is_fake_enum:
p->filename = name;
- p->is_archive = false;
- p->real = false;
+ p->is_archive = FALSE;
+ p->real = FALSE;
p->local_sym_name = name;
- p->just_syms_flag = false;
- p->search_dirs_flag = false;
+ p->just_syms_flag = FALSE;
+ p->search_dirs_flag = FALSE;
break;
case lang_input_file_is_l_enum:
- p->is_archive = true;
+ p->is_archive = TRUE;
p->filename = name;
- p->real = true;
- p->local_sym_name = concat ("-l", name, (const char *) NULL);
- p->just_syms_flag = false;
- p->search_dirs_flag = true;
+ p->real = TRUE;
+ p->local_sym_name = concat ("-l", name, NULL);
+ p->just_syms_flag = FALSE;
+ p->search_dirs_flag = TRUE;
break;
case lang_input_file_is_marker_enum:
p->filename = name;
- p->is_archive = false;
- p->real = false;
+ p->is_archive = FALSE;
+ p->real = FALSE;
p->local_sym_name = name;
- p->just_syms_flag = false;
- p->search_dirs_flag = true;
+ p->just_syms_flag = FALSE;
+ p->search_dirs_flag = TRUE;
break;
case lang_input_file_is_search_file_enum:
+ p->sysrooted = ldlang_sysrooted_script;
p->filename = name;
- p->is_archive = false;
- p->real = true;
+ p->is_archive = FALSE;
+ p->real = TRUE;
p->local_sym_name = name;
- p->just_syms_flag = false;
- p->search_dirs_flag = true;
+ p->just_syms_flag = FALSE;
+ p->search_dirs_flag = TRUE;
break;
case lang_input_file_is_file_enum:
p->filename = name;
- p->is_archive = false;
- p->real = true;
+ p->is_archive = FALSE;
+ p->real = TRUE;
p->local_sym_name = name;
- p->just_syms_flag = false;
- p->search_dirs_flag = false;
+ p->just_syms_flag = FALSE;
+ p->search_dirs_flag = FALSE;
break;
default:
FAIL ();
}
- p->the_bfd = (bfd *) NULL;
- p->asymbols = (asymbol **) NULL;
- p->next_real_file = (lang_statement_union_type *) NULL;
- p->next = (lang_statement_union_type *) NULL;
+ p->the_bfd = NULL;
+ p->asymbols = NULL;
+ p->next_real_file = NULL;
+ p->next = NULL;
p->symbol_count = 0;
p->dynamic = config.dynamic_link;
+ p->as_needed = as_needed;
p->whole_archive = whole_archive;
- p->loaded = false;
+ p->loaded = FALSE;
lang_statement_append (&input_file_chain,
(lang_statement_union_type *) p,
&p->next_real_file);
@@ -569,19 +455,18 @@ new_afile (name, file_type, target, add_to_list)
}
lang_input_statement_type *
-lang_add_input_file (name, file_type, target)
- const char *name;
- lang_input_file_enum_type file_type;
- const char *target;
+lang_add_input_file (const char *name,
+ lang_input_file_enum_type file_type,
+ const char *target)
{
- lang_has_input_file = true;
- return new_afile (name, file_type, target, true);
+ lang_has_input_file = TRUE;
+ return new_afile (name, file_type, target, TRUE);
}
/* Build enough state so that the parser can build its tree. */
void
-lang_init ()
+lang_init (void)
{
obstack_begin (&stat_obstack, 1000);
@@ -592,14 +477,25 @@ lang_init ()
lang_list_init (&input_file_chain);
lang_list_init (&lang_output_section_statement);
lang_list_init (&file_chain);
- first_file = lang_add_input_file ((char *) NULL,
- lang_input_file_is_marker_enum,
- (char *) NULL);
+ first_file = lang_add_input_file (NULL, lang_input_file_is_marker_enum,
+ NULL);
abs_output_section =
lang_output_section_statement_lookup (BFD_ABS_SECTION_NAME);
abs_output_section->bfd_section = bfd_abs_section_ptr;
+ /* The value "3" is ad-hoc, somewhat related to the expected number of
+ DEFINED expressions in a linker script. For most default linker
+ scripts, there are none. Why a hash table then? Well, it's somewhat
+ simpler to re-use working machinery than using a linked list in terms
+ of code-complexity here in ld, besides the initialization which just
+ looks like other code here. */
+ if (bfd_hash_table_init_n (&lang_definedness_table,
+ lang_definedness_newfunc, 3) != TRUE)
+ einfo (_("%P%F: out of memory during initialization"));
+
+ /* Callers of exp_fold_tree need to increment this. */
+ lang_statement_iteration = 0;
}
/*----------------------------------------------------------------------
@@ -610,30 +506,34 @@ lang_init ()
We maintain a list of all the regions here.
If no regions are specified in the script, then the default is used
- which is created when looked up to be the entire data space. */
+ which is created when looked up to be the entire data space.
+
+ If create is true we are creating a region inside a MEMORY block.
+ In this case it is probably an error to create a region that has
+ already been created. If we are not inside a MEMORY block it is
+ dubious to use an undeclared region name (except DEFAULT_MEMORY_REGION)
+ and so we issue a warning. */
static lang_memory_region_type *lang_memory_region_list;
static lang_memory_region_type **lang_memory_region_list_tail = &lang_memory_region_list;
lang_memory_region_type *
-lang_memory_region_lookup (name)
- const char *const name;
+lang_memory_region_lookup (const char *const name, bfd_boolean create)
{
lang_memory_region_type *p;
+ lang_memory_region_type *new;
/* NAME is NULL for LMA memspecs if no region was specified. */
if (name == NULL)
return NULL;
- for (p = lang_memory_region_list;
- p != (lang_memory_region_type *) NULL;
- p = p->next)
- {
- if (strcmp (p->name, name) == 0)
- {
- return p;
- }
- }
+ for (p = lang_memory_region_list; p != NULL; p = p->next)
+ if (strcmp (p->name, name) == 0)
+ {
+ if (create)
+ einfo (_("%P:%S: warning: redeclaration of memory region '%s'\n"), name);
+ return p;
+ }
#if 0
/* This code used to always use the first region in the list as the
@@ -642,38 +542,35 @@ lang_memory_region_lookup (name)
NOLOAD sections to work reasonably without requiring a region.
People should specify what region they mean, if they really want
a region. */
- if (strcmp (name, "*default*") == 0)
+ if (strcmp (name, DEFAULT_MEMORY_REGION) == 0)
{
- if (lang_memory_region_list != (lang_memory_region_type *) NULL)
- {
- return lang_memory_region_list;
- }
+ if (lang_memory_region_list != NULL)
+ return lang_memory_region_list;
}
#endif
- {
- lang_memory_region_type *new =
- (lang_memory_region_type *) stat_alloc (sizeof (lang_memory_region_type));
+ if (!create && strcmp (name, DEFAULT_MEMORY_REGION))
+ einfo (_("%P:%S: warning: memory region %s not declared\n"), name);
- new->name = xstrdup (name);
- new->next = (lang_memory_region_type *) NULL;
+ new = stat_alloc (sizeof (lang_memory_region_type));
+
+ new->name = xstrdup (name);
+ new->next = NULL;
- *lang_memory_region_list_tail = new;
- lang_memory_region_list_tail = &new->next;
- new->origin = 0;
- new->flags = 0;
- new->not_flags = 0;
- new->length = ~(bfd_size_type) 0;
- new->current = 0;
- new->had_full_message = false;
+ *lang_memory_region_list_tail = new;
+ lang_memory_region_list_tail = &new->next;
+ new->origin = 0;
+ new->flags = 0;
+ new->not_flags = 0;
+ new->length = ~(bfd_size_type) 0;
+ new->current = 0;
+ new->had_full_message = FALSE;
- return new;
- }
+ return new;
}
static lang_memory_region_type *
-lang_memory_default (section)
- asection *section;
+lang_memory_default (asection *section)
{
lang_memory_region_type *p;
@@ -683,9 +580,7 @@ lang_memory_default (section)
if ((sec_flags & (SEC_ALLOC | SEC_READONLY | SEC_CODE)) == SEC_ALLOC)
sec_flags |= SEC_DATA;
- for (p = lang_memory_region_list;
- p != (lang_memory_region_type *) NULL;
- p = p->next)
+ for (p = lang_memory_region_list; p != NULL; p = p->next)
{
if ((p->flags & sec_flags) != 0
&& (p->not_flags & sec_flags) == 0)
@@ -693,59 +588,51 @@ lang_memory_default (section)
return p;
}
}
- return lang_memory_region_lookup ("*default*");
+ return lang_memory_region_lookup (DEFAULT_MEMORY_REGION, FALSE);
}
lang_output_section_statement_type *
-lang_output_section_find (name)
- const char *const name;
+lang_output_section_find (const char *const name)
{
lang_statement_union_type *u;
lang_output_section_statement_type *lookup;
- for (u = lang_output_section_statement.head;
- u != (lang_statement_union_type *) NULL;
- u = lookup->next)
+ for (u = lang_output_section_statement.head; u != NULL; u = lookup->next)
{
lookup = &u->output_section_statement;
if (strcmp (name, lookup->name) == 0)
- {
- return lookup;
- }
+ return lookup;
}
- return (lang_output_section_statement_type *) NULL;
+ return NULL;
}
lang_output_section_statement_type *
-lang_output_section_statement_lookup (name)
- const char *const name;
+lang_output_section_statement_lookup (const char *const name)
{
lang_output_section_statement_type *lookup;
lookup = lang_output_section_find (name);
- if (lookup == (lang_output_section_statement_type *) NULL)
+ if (lookup == NULL)
{
-
- lookup = (lang_output_section_statement_type *)
- new_stat (lang_output_section_statement, stat_ptr);
- lookup->region = (lang_memory_region_type *) NULL;
- lookup->lma_region = (lang_memory_region_type *) NULL;
- lookup->fill = (fill_type *) 0;
+ lookup = new_stat (lang_output_section_statement, stat_ptr);
+ lookup->region = NULL;
+ lookup->lma_region = NULL;
+ lookup->fill = 0;
lookup->block_value = 1;
lookup->name = name;
- lookup->next = (lang_statement_union_type *) NULL;
- lookup->bfd_section = (asection *) NULL;
- lookup->processed = false;
+ lookup->next = NULL;
+ lookup->bfd_section = NULL;
+ lookup->processed = 0;
lookup->sectype = normal_section;
- lookup->addr_tree = (etree_type *) NULL;
+ lookup->addr_tree = NULL;
lang_list_init (&lookup->children);
- lookup->memspec = (const char *) NULL;
+ lookup->memspec = NULL;
lookup->flags = 0;
lookup->subsection_alignment = -1;
lookup->section_alignment = -1;
- lookup->load_base = (union etree_union *) NULL;
+ lookup->load_base = NULL;
lookup->update_dot_tree = NULL;
lookup->phdrs = NULL;
@@ -757,8 +644,7 @@ lang_output_section_statement_lookup (name)
}
static void
-lang_map_flags (flag)
- flagword flag;
+lang_map_flags (flagword flag)
{
if (flag & SEC_ALLOC)
minfo ("a");
@@ -777,7 +663,7 @@ lang_map_flags (flag)
}
void
-lang_map ()
+lang_map (void)
{
lang_memory_region_type *m;
@@ -785,9 +671,7 @@ lang_map ()
fprintf (config.map_file, "%-16s %-18s %-18s %s\n",
_("Name"), _("Origin"), _("Length"), _("Attributes"));
- for (m = lang_memory_region_list;
- m != (lang_memory_region_type *) NULL;
- m = m->next)
+ for (m = lang_memory_region_list; m != NULL; m = m->next)
{
char buf[100];
int len;
@@ -833,8 +717,7 @@ lang_map ()
/* Initialize an output section. */
static void
-init_os (s)
- lang_output_section_statement_type *s;
+init_os (lang_output_section_statement_type *s)
{
section_userdata_type *new;
@@ -844,13 +727,12 @@ init_os (s)
if (strcmp (s->name, DISCARD_SECTION_NAME) == 0)
einfo (_("%P%F: Illegal use of `%s' section\n"), DISCARD_SECTION_NAME);
- new = ((section_userdata_type *)
- stat_alloc (sizeof (section_userdata_type)));
+ new = stat_alloc (sizeof (section_userdata_type));
s->bfd_section = bfd_get_section_by_name (output_bfd, s->name);
- if (s->bfd_section == (asection *) NULL)
+ if (s->bfd_section == NULL)
s->bfd_section = bfd_make_section (output_bfd, s->name);
- if (s->bfd_section == (asection *) NULL)
+ if (s->bfd_section == NULL)
{
einfo (_("%P%F: output format %s cannot represent section called %s\n"),
output_bfd->xvec->name, s->name);
@@ -860,20 +742,22 @@ init_os (s)
/* We initialize an output sections output offset to minus its own
vma to allow us to output a section through itself. */
s->bfd_section->output_offset = 0;
- get_userdata (s->bfd_section) = (PTR) new;
+ get_userdata (s->bfd_section) = new;
/* If there is a base address, make sure that any sections it might
mention are initialized. */
if (s->addr_tree != NULL)
exp_init_os (s->addr_tree);
+
+ if (s->load_base != NULL)
+ exp_init_os (s->load_base);
}
/* Make sure that all output sections mentioned in an expression are
initialized. */
static void
-exp_init_os (exp)
- etree_type *exp;
+exp_init_os (etree_type *exp)
{
switch (exp->type.node_class)
{
@@ -892,6 +776,10 @@ exp_init_os (exp)
exp_init_os (exp->trinary.rhs);
break;
+ case etree_assert:
+ exp_init_os (exp->assert_s.child);
+ break;
+
case etree_unary:
exp_init_os (exp->unary.child);
break;
@@ -948,12 +836,9 @@ struct already_linked
static struct bfd_hash_table already_linked_table;
static void
-section_already_linked (abfd, sec, data)
- bfd *abfd;
- asection *sec;
- PTR data;
+section_already_linked (bfd *abfd, asection *sec, void *data)
{
- lang_input_statement_type *entry = (lang_input_statement_type *) data;
+ lang_input_statement_type *entry = data;
flagword flags;
const char *name;
struct already_linked *l;
@@ -993,7 +878,7 @@ section_already_linked (abfd, sec, data)
already_linked_list =
((struct already_linked_hash_entry *)
- bfd_hash_lookup (&already_linked_table, name, true, false));
+ bfd_hash_lookup (&already_linked_table, name, TRUE, FALSE));
for (l = already_linked_list->entry; l != NULL; l = l->next)
{
@@ -1037,8 +922,11 @@ section_already_linked (abfd, sec, data)
/* Set the output_section field so that lang_add_section
does not create a lang_input_section structure for this
- section. */
+ section. Since there might be a symbol in the section
+ being discarded, we must retain a pointer to the section
+ which we are really going to use. */
sec->output_section = bfd_abs_section_ptr;
+ sec->kept_section = l->sec;
if (flags & SEC_GROUP)
bfd_discard_group (abfd, sec);
@@ -1050,8 +938,7 @@ section_already_linked (abfd, sec, data)
/* This is the first section with this name. Record it. Allocate
the memory from the same obstack as the hash table is kept in. */
- l = ((struct already_linked *)
- bfd_hash_allocate (&already_linked_table, sizeof *l));
+ l = bfd_hash_allocate (&already_linked_table, sizeof *l);
l->sec = sec;
l->next = already_linked_list->entry;
@@ -1062,21 +949,20 @@ section_already_linked (abfd, sec, data)
initialize the table, fill in an entry and remove the table. */
static struct bfd_hash_entry *
-already_linked_newfunc (entry, table, string)
- struct bfd_hash_entry *entry ATTRIBUTE_UNUSED;
- struct bfd_hash_table *table;
- const char *string ATTRIBUTE_UNUSED;
+already_linked_newfunc (struct bfd_hash_entry *entry ATTRIBUTE_UNUSED,
+ struct bfd_hash_table *table,
+ const char *string ATTRIBUTE_UNUSED)
{
struct already_linked_hash_entry *ret =
bfd_hash_allocate (table, sizeof (struct already_linked_hash_entry));
ret->entry = NULL;
- return (struct bfd_hash_entry *) ret;
+ return &ret->root;
}
static void
-already_linked_table_init ()
+already_linked_table_init (void)
{
if (! bfd_hash_table_init_n (&already_linked_table,
already_linked_newfunc,
@@ -1085,7 +971,7 @@ already_linked_table_init ()
}
static void
-already_linked_table_free ()
+already_linked_table_free (void)
{
bfd_hash_table_free (&already_linked_table);
}
@@ -1096,15 +982,14 @@ already_linked_table_free ()
explicit actions, like foo.o(.text), bar.o(.text) and
foo.o(.text, .data). */
-/* Return true if the PATTERN argument is a wildcard pattern.
+/* Return TRUE if the PATTERN argument is a wildcard pattern.
Although backslashes are treated specially if a pattern contains
wildcards, we do not consider the mere presence of a backslash to
be enough to cause the pattern to be treated as a wildcard.
That lets us handle DOS filenames more naturally. */
-static boolean
-wildcardp (pattern)
- const char *pattern;
+static bfd_boolean
+wildcardp (const char *pattern)
{
const char *s;
@@ -1112,8 +997,8 @@ wildcardp (pattern)
if (*s == '?'
|| *s == '*'
|| *s == '[')
- return true;
- return false;
+ return TRUE;
+ return FALSE;
}
/* Add SECTION to the output section OUTPUT. Do this by creating a
@@ -1121,35 +1006,35 @@ wildcardp (pattern)
input file which holds SECTION. */
void
-lang_add_section (ptr, section, output, file)
- lang_statement_list_type *ptr;
- asection *section;
- lang_output_section_statement_type *output;
- lang_input_statement_type *file;
+lang_add_section (lang_statement_list_type *ptr,
+ asection *section,
+ lang_output_section_statement_type *output,
+ lang_input_statement_type *file)
{
flagword flags;
- boolean discard;
+ bfd_boolean discard;
flags = bfd_get_section_flags (section->owner, section);
- discard = false;
+ discard = FALSE;
- /* If we are doing a final link, discard sections marked with
- SEC_EXCLUDE. */
- if (! link_info.relocateable
- && (flags & SEC_EXCLUDE) != 0)
- discard = true;
+ /* Discard sections marked with SEC_EXCLUDE if we are doing a final
+ link. Discard debugging sections marked with SEC_EXCLUDE on a
+ relocatable link too. */
+ if ((flags & SEC_EXCLUDE) != 0
+ && ((flags & SEC_DEBUGGING) != 0 || !link_info.relocatable))
+ discard = TRUE;
/* Discard input sections which are assigned to a section named
DISCARD_SECTION_NAME. */
if (strcmp (output->name, DISCARD_SECTION_NAME) == 0)
- discard = true;
+ discard = TRUE;
/* Discard debugging sections if we are stripping debugging
information. */
if ((link_info.strip == strip_debugger || link_info.strip == strip_all)
&& (flags & SEC_DEBUGGING) != 0)
- discard = true;
+ discard = TRUE;
if (discard)
{
@@ -1163,7 +1048,7 @@ lang_add_section (ptr, section, output, file)
if (section->output_section == NULL)
{
- boolean first;
+ bfd_boolean first;
lang_input_section_type *new;
flagword flags;
@@ -1196,7 +1081,7 @@ lang_add_section (ptr, section, output, file)
format targets, .text$foo sections go into .text and it's odd
to see .text with SEC_LINK_ONCE set. */
- if (! link_info.relocateable)
+ if (! link_info.relocatable)
flags &= ~ (SEC_LINK_ONCE | SEC_LINK_DUPLICATES);
/* If this is not the first input section, and the SEC_READONLY
@@ -1217,10 +1102,6 @@ lang_add_section (ptr, section, output, file)
flags &= ~ (SEC_MERGE | SEC_STRINGS);
}
- /* For now make .tbss normal section. */
- if ((flags & SEC_THREAD_LOCAL) && ! link_info.relocateable)
- flags |= SEC_LOAD;
-
section->output_section->flags |= flags;
if (flags & SEC_MERGE)
@@ -1254,7 +1135,7 @@ lang_add_section (ptr, section, output, file)
if (section->alignment_power > output->bfd_section->alignment_power)
output->bfd_section->alignment_power = section->alignment_power;
- /* If supplied an aligment, then force it. */
+ /* If supplied an alignment, then force it. */
if (output->section_alignment != -1)
output->bfd_section->alignment_power = output->section_alignment;
@@ -1273,11 +1154,10 @@ lang_add_section (ptr, section, output, file)
new section should just go at the end of the current list. */
static lang_statement_union_type *
-wild_sort (wild, sec, file, section)
- lang_wild_statement_type *wild;
- struct wildcard_list *sec;
- lang_input_statement_type *file;
- asection *section;
+wild_sort (lang_wild_statement_type *wild,
+ struct wildcard_list *sec,
+ lang_input_statement_type *file,
+ asection *section)
{
const char *section_name;
lang_statement_union_type *l;
@@ -1300,7 +1180,7 @@ wild_sort (wild, sec, file, section)
if (wild->filenames_sorted)
{
const char *fn, *ln;
- boolean fa, la;
+ bfd_boolean fa, la;
int i;
/* The PE support for the .idata section as generated by
@@ -1312,24 +1192,24 @@ wild_sort (wild, sec, file, section)
&& bfd_my_archive (file->the_bfd) != NULL)
{
fn = bfd_get_filename (bfd_my_archive (file->the_bfd));
- fa = true;
+ fa = TRUE;
}
else
{
fn = file->filename;
- fa = false;
+ fa = FALSE;
}
if (ls->ifile->the_bfd != NULL
&& bfd_my_archive (ls->ifile->the_bfd) != NULL)
{
ln = bfd_get_filename (bfd_my_archive (ls->ifile->the_bfd));
- la = true;
+ la = TRUE;
}
else
{
ln = ls->ifile->filename;
- la = false;
+ la = FALSE;
}
i = strcmp (fn, ln);
@@ -1373,12 +1253,11 @@ wild_sort (wild, sec, file, section)
NULL, in which case it is a wild card. */
static void
-output_section_callback (ptr, sec, section, file, output)
- lang_wild_statement_type *ptr;
- struct wildcard_list *sec;
- asection *section;
- lang_input_statement_type *file;
- PTR output;
+output_section_callback (lang_wild_statement_type *ptr,
+ struct wildcard_list *sec,
+ asection *section,
+ lang_input_statement_type *file,
+ void *output)
{
lang_statement_union_type *before;
@@ -1434,36 +1313,40 @@ output_section_callback (ptr, sec, section, file, output)
already and had its symbols read. If not then we'll read it. */
static lang_input_statement_type *
-lookup_name (name)
- const char *name;
+lookup_name (const char *name)
{
lang_input_statement_type *search;
for (search = (lang_input_statement_type *) input_file_chain.head;
- search != (lang_input_statement_type *) NULL;
+ search != NULL;
search = (lang_input_statement_type *) search->next_real_file)
{
- if (search->filename == (char *) NULL && name == (char *) NULL)
+ /* Use the local_sym_name as the name of the file that has
+ already been loaded as filename might have been transformed
+ via the search directory lookup mechanism. */
+ const char * filename = search->local_sym_name;
+
+ if (filename == NULL && name == NULL)
return search;
- if (search->filename != (char *) NULL
- && name != (char *) NULL
- && strcmp (search->filename, name) == 0)
+ if (filename != NULL
+ && name != NULL
+ && strcmp (filename, name) == 0)
break;
}
- if (search == (lang_input_statement_type *) NULL)
- search = new_afile (name, lang_input_file_is_file_enum, default_target,
- false);
+ if (search == NULL)
+ search = new_afile (name, lang_input_file_is_search_file_enum, default_target,
+ FALSE);
/* If we have already added this file, or this file is not real
(FIXME: can that ever actually happen?) or the name is NULL
(FIXME: can that ever actually happen?) don't add this file. */
if (search->loaded
|| ! search->real
- || search->filename == (const char *) NULL)
+ || search->filename == NULL)
return search;
- if (! load_symbols (search, (lang_statement_list_type *) NULL))
+ if (! load_symbols (search, NULL))
return NULL;
return search;
@@ -1471,15 +1354,14 @@ lookup_name (name)
/* Get the symbols for an input file. */
-static boolean
-load_symbols (entry, place)
- lang_input_statement_type *entry;
- lang_statement_list_type *place;
+static bfd_boolean
+load_symbols (lang_input_statement_type *entry,
+ lang_statement_list_type *place)
{
char **matching;
if (entry->loaded)
- return true;
+ return TRUE;
ldfile_open_file (entry);
@@ -1488,13 +1370,14 @@ load_symbols (entry, place)
{
bfd_error_type err;
lang_statement_list_type *hold;
- boolean bad_load = true;
+ bfd_boolean bad_load = TRUE;
+ bfd_boolean save_ldlang_sysrooted_script;
err = bfd_get_error ();
/* See if the emulation has some special knowledge. */
if (ldemul_unrecognized_file (entry))
- return true;
+ return TRUE;
if (err == bfd_error_file_ambiguously_recognized)
{
@@ -1510,7 +1393,7 @@ load_symbols (entry, place)
|| place == NULL)
einfo (_("%F%B: file not recognized: %E\n"), entry->the_bfd);
else
- bad_load = false;
+ bad_load = FALSE;
bfd_close (entry->the_bfd);
entry->the_bfd = NULL;
@@ -1520,19 +1403,22 @@ load_symbols (entry, place)
hold = stat_ptr;
stat_ptr = place;
+ save_ldlang_sysrooted_script = ldlang_sysrooted_script;
+ ldlang_sysrooted_script = entry->sysrooted;
- ldfile_assumed_script = true;
+ ldfile_assumed_script = TRUE;
parser_input = input_script;
yyparse ();
- ldfile_assumed_script = false;
+ ldfile_assumed_script = FALSE;
+ ldlang_sysrooted_script = save_ldlang_sysrooted_script;
stat_ptr = hold;
return ! bad_load;
}
if (ldemul_recognized_file (entry))
- return true;
+ return TRUE;
/* We don't call ldlang_add_file for an archive. Instead, the
add_symbols entry point will call ldlang_add_file, via the
@@ -1553,7 +1439,7 @@ load_symbols (entry, place)
if (entry->whole_archive)
{
bfd *member = NULL;
- boolean loaded = true;
+ bfd_boolean loaded = TRUE;
for (;;)
{
@@ -1566,7 +1452,7 @@ load_symbols (entry, place)
{
einfo (_("%F%B: member %B in archive is not an object\n"),
entry->the_bfd, member);
- loaded = false;
+ loaded = FALSE;
}
if (! ((*link_info.callbacks->add_archive_element)
@@ -1576,7 +1462,7 @@ load_symbols (entry, place)
if (! bfd_link_add_symbols (member, &link_info))
{
einfo (_("%F%B: could not read symbols: %E\n"), member);
- loaded = false;
+ loaded = FALSE;
}
}
@@ -1587,7 +1473,7 @@ load_symbols (entry, place)
}
if (bfd_link_add_symbols (entry->the_bfd, &link_info))
- entry->loaded = true;
+ entry->loaded = TRUE;
else
einfo (_("%F%B: could not read symbols: %E\n"), entry->the_bfd);
@@ -1601,14 +1487,13 @@ load_symbols (entry, place)
the output section. */
static void
-wild (s, target, output)
- lang_wild_statement_type *s;
- const char *target ATTRIBUTE_UNUSED;
- lang_output_section_statement_type *output;
+wild (lang_wild_statement_type *s,
+ const char *target ATTRIBUTE_UNUSED,
+ lang_output_section_statement_type *output)
{
struct wildcard_list *sec;
- walk_wild (s, output_section_callback, (PTR) output);
+ walk_wild (s, output_section_callback, output);
for (sec = s->section_list; sec != NULL; sec = sec->next)
{
@@ -1623,14 +1508,12 @@ wild (s, target, output)
}
}
-/* Return true iff target is the sought target. */
+/* Return TRUE iff target is the sought target. */
static int
-get_target (target, data)
- const bfd_target *target;
- PTR data;
+get_target (const bfd_target *target, void *data)
{
- const char *sought = (const char *) data;
+ const char *sought = data;
return strcmp (target->name, sought) == 0;
}
@@ -1638,9 +1521,7 @@ get_target (target, data)
/* Like strcpy() but convert to lower case as well. */
static void
-stricpy (dest, src)
- char *dest;
- char *src;
+stricpy (char *dest, char *src)
{
char c;
@@ -1650,13 +1531,11 @@ stricpy (dest, src)
*dest = 0;
}
-/* Remove the first occurance of needle (if any) in haystack
+/* Remove the first occurrence of needle (if any) in haystack
from haystack. */
static void
-strcut (haystack, needle)
- char *haystack;
- char *needle;
+strcut (char *haystack, char *needle)
{
haystack = strstr (haystack, needle);
@@ -1675,9 +1554,7 @@ strcut (haystack, needle)
Return a value indicating how "similar" they are. */
static int
-name_compare (first, second)
- char *first;
- char *second;
+name_compare (char *first, char *second)
{
char *copy1;
char *copy2;
@@ -1690,7 +1567,7 @@ name_compare (first, second)
stricpy (copy1, first);
stricpy (copy2, second);
- /* Remove and endian strings from the name. */
+ /* Remove size and endian strings from the name. */
strcut (copy1, "big");
strcut (copy1, "little");
strcut (copy2, "big");
@@ -1720,11 +1597,9 @@ static const bfd_target *winner;
match to the original output target. */
static int
-closest_target_match (target, data)
- const bfd_target *target;
- PTR data;
+closest_target_match (const bfd_target *target, void *data)
{
- const bfd_target *original = (const bfd_target *) data;
+ const bfd_target *original = data;
if (command_line.endian == ENDIAN_BIG
&& target->byteorder != BFD_ENDIAN_BIG)
@@ -1758,7 +1633,7 @@ closest_target_match (target, data)
/* Return the BFD target format of the first input file. */
static char *
-get_first_input_target ()
+get_first_input_target (void)
{
char *target = NULL;
@@ -1784,12 +1659,12 @@ get_first_input_target ()
}
const char *
-lang_get_output_target ()
+lang_get_output_target (void)
{
const char *target;
/* Has the user told us which output format to use? */
- if (output_target != (char *) NULL)
+ if (output_target != NULL)
return output_target;
/* No - has the current target been set to something other than
@@ -1809,8 +1684,7 @@ lang_get_output_target ()
/* Open the output file. */
static bfd *
-open_output (name)
- const char *name;
+open_output (const char *name)
{
bfd *output;
@@ -1824,7 +1698,7 @@ open_output (name)
enum bfd_endian desired_endian;
/* Get the chosen target. */
- target = bfd_search_for_target (get_target, (PTR) output_target);
+ target = bfd_search_for_target (get_target, (void *) output_target);
/* If the target is not supported, we cannot do anything. */
if (target != NULL)
@@ -1850,8 +1724,8 @@ open_output (name)
/* Try to find a target as similar as possible to
the default target, but which has the desired
endian characteristic. */
- (void) bfd_search_for_target (closest_target_match,
- (PTR) target);
+ bfd_search_for_target (closest_target_match,
+ (void *) target);
/* Oh dear - we could not find any targets that
satisfy our requirements. */
@@ -1866,7 +1740,7 @@ open_output (name)
output = bfd_openw (name, output_target);
- if (output == (bfd *) NULL)
+ if (output == NULL)
{
if (bfd_get_error () == bfd_error_invalid_target)
einfo (_("%P%F: target %s not found\n"), output_target);
@@ -1874,7 +1748,7 @@ open_output (name)
einfo (_("%P%F: cannot open output file %s: %E\n"), name);
}
- delete_output_file_on_failure = true;
+ delete_output_file_on_failure = TRUE;
#if 0
output->flags |= D_PAGED;
@@ -1888,7 +1762,7 @@ open_output (name)
einfo (_("%P%F:%s: can not set architecture: %E\n"), name);
link_info.hash = bfd_link_hash_table_create (output);
- if (link_info.hash == (struct bfd_link_hash_table *) NULL)
+ if (link_info.hash == NULL)
einfo (_("%P%F: can not create link hash table: %E\n"));
bfd_set_gp_size (output, g_switch_value);
@@ -1896,16 +1770,15 @@ open_output (name)
}
static void
-ldlang_open_output (statement)
- lang_statement_union_type *statement;
+ldlang_open_output (lang_statement_union_type *statement)
{
switch (statement->header.type)
{
case lang_output_statement_enum:
- ASSERT (output_bfd == (bfd *) NULL);
+ ASSERT (output_bfd == NULL);
output_bfd = open_output (statement->output_statement.name);
ldemul_set_output_arch ();
- if (config.magic_demand_paged && !link_info.relocateable)
+ if (config.magic_demand_paged && !link_info.relocatable)
output_bfd->flags |= D_PAGED;
else
output_bfd->flags &= ~D_PAGED;
@@ -1927,14 +1800,36 @@ ldlang_open_output (statement)
}
}
+/* Convert between addresses in bytes and sizes in octets.
+ For currently supported targets, octets_per_byte is always a power
+ of two, so we can use shifts. */
+#define TO_ADDR(X) ((X) >> opb_shift)
+#define TO_SIZE(X) ((X) << opb_shift)
+
+/* Support the above. */
+static unsigned int opb_shift = 0;
+
+static void
+init_opb (void)
+{
+ unsigned x = bfd_arch_mach_octets_per_byte (ldfile_output_architecture,
+ ldfile_output_machine);
+ opb_shift = 0;
+ if (x > 1)
+ while ((x & 1) == 0)
+ {
+ x >>= 1;
+ ++opb_shift;
+ }
+ ASSERT (x == 1);
+}
+
/* Open all the input files. */
static void
-open_input_bfds (s, force)
- lang_statement_union_type *s;
- boolean force;
+open_input_bfds (lang_statement_union_type *s, bfd_boolean force)
{
- for (; s != (lang_statement_union_type *) NULL; s = s->header.next)
+ for (; s != NULL; s = s->header.next)
{
switch (s->header.type)
{
@@ -1948,7 +1843,7 @@ open_input_bfds (s, force)
/* Maybe we should load the file's symbols. */
if (s->wild_statement.filename
&& ! wildcardp (s->wild_statement.filename))
- (void) lookup_name (s->wild_statement.filename);
+ lookup_name (s->wild_statement.filename);
open_input_bfds (s->wild_statement.children.head, force);
break;
case lang_group_statement_enum:
@@ -1962,7 +1857,7 @@ open_input_bfds (s, force)
do
{
undefs = link_info.hash->undefs_tail;
- open_input_bfds (s->group_statement.children.head, true);
+ open_input_bfds (s->group_statement.children.head, TRUE);
}
while (undefs != link_info.hash->undefs_tail);
}
@@ -1986,12 +1881,12 @@ open_input_bfds (s, force)
&& s->input_statement.loaded
&& bfd_check_format (s->input_statement.the_bfd,
bfd_archive))
- s->input_statement.loaded = false;
+ s->input_statement.loaded = FALSE;
lang_list_init (&add);
if (! load_symbols (&s->input_statement, &add))
- config.make_executable = false;
+ config.make_executable = FALSE;
if (add.head != NULL)
{
@@ -2010,7 +1905,7 @@ open_input_bfds (s, force)
section. */
static void
-lang_reasonable_defaults ()
+lang_reasonable_defaults (void)
{
#if 0
lang_output_section_statement_lookup (".text");
@@ -2025,12 +1920,91 @@ lang_reasonable_defaults ()
&default_common_section->children);
new->section_name = "COMMON";
- new->filename = (char *) NULL;
+ new->filename = NULL;
lang_list_init (&new->children);
}
#endif
}
+/* Add a symbol to a hash of symbols used in DEFINED (NAME) expressions. */
+
+void
+lang_track_definedness (const char *name)
+{
+ if (bfd_hash_lookup (&lang_definedness_table, name, TRUE, FALSE) == NULL)
+ einfo (_("%P%F: bfd_hash_lookup failed creating symbol %s\n"), name);
+}
+
+/* New-function for the definedness hash table. */
+
+static struct bfd_hash_entry *
+lang_definedness_newfunc (struct bfd_hash_entry *entry,
+ struct bfd_hash_table *table ATTRIBUTE_UNUSED,
+ const char *name ATTRIBUTE_UNUSED)
+{
+ struct lang_definedness_hash_entry *ret
+ = (struct lang_definedness_hash_entry *) entry;
+
+ if (ret == NULL)
+ ret = (struct lang_definedness_hash_entry *)
+ bfd_hash_allocate (table, sizeof (struct lang_definedness_hash_entry));
+
+ if (ret == NULL)
+ einfo (_("%P%F: bfd_hash_allocate failed creating symbol %s\n"), name);
+
+ ret->iteration = -1;
+ return &ret->root;
+}
+
+/* Return the iteration when the definition of NAME was last updated. A
+ value of -1 means that the symbol is not defined in the linker script
+ or the command line, but may be defined in the linker symbol table. */
+
+int
+lang_symbol_definition_iteration (const char *name)
+{
+ struct lang_definedness_hash_entry *defentry
+ = (struct lang_definedness_hash_entry *)
+ bfd_hash_lookup (&lang_definedness_table, name, FALSE, FALSE);
+
+ /* We've already created this one on the presence of DEFINED in the
+ script, so it can't be NULL unless something is borked elsewhere in
+ the code. */
+ if (defentry == NULL)
+ FAIL ();
+
+ return defentry->iteration;
+}
+
+/* Update the definedness state of NAME. */
+
+void
+lang_update_definedness (const char *name, struct bfd_link_hash_entry *h)
+{
+ struct lang_definedness_hash_entry *defentry
+ = (struct lang_definedness_hash_entry *)
+ bfd_hash_lookup (&lang_definedness_table, name, FALSE, FALSE);
+
+ /* We don't keep track of symbols not tested with DEFINED. */
+ if (defentry == NULL)
+ return;
+
+ /* If the symbol was already defined, and not from an earlier statement
+ iteration, don't update the definedness iteration, because that'd
+ make the symbol seem defined in the linker script at this point, and
+ it wasn't; it was defined in some object. If we do anyway, DEFINED
+ would start to yield false before this point and the construct "sym =
+ DEFINED (sym) ? sym : X;" would change sym to X despite being defined
+ in an object. */
+ if (h->type != bfd_link_hash_undefined
+ && h->type != bfd_link_hash_common
+ && h->type != bfd_link_hash_new
+ && defentry->iteration == -1)
+ return;
+
+ defentry->iteration = lang_statement_iteration;
+}
+
/* Add the supplied name to the symbol table as an undefined reference.
This is a two step process as the symbol table doesn't even exist at
the time the ld command line is processed. First we put the name
@@ -2042,12 +2016,10 @@ typedef struct bfd_sym_chain ldlang_undef_chain_list_type;
#define ldlang_undef_chain_list_head entry_symbol.next
void
-ldlang_add_undef (name)
- const char *const name;
+ldlang_add_undef (const char *const name)
{
ldlang_undef_chain_list_type *new =
- ((ldlang_undef_chain_list_type *)
- stat_alloc (sizeof (ldlang_undef_chain_list_type)));
+ stat_alloc (sizeof (ldlang_undef_chain_list_type));
new->next = ldlang_undef_chain_list_head;
ldlang_undef_chain_list_head = new;
@@ -2061,13 +2033,12 @@ ldlang_add_undef (name)
/* Insert NAME as undefined in the symbol table. */
static void
-insert_undefined (name)
- const char *name;
+insert_undefined (const char *name)
{
struct bfd_link_hash_entry *h;
- h = bfd_link_hash_lookup (link_info.hash, name, true, false, true);
- if (h == (struct bfd_link_hash_entry *) NULL)
+ h = bfd_link_hash_lookup (link_info.hash, name, TRUE, FALSE, TRUE);
+ if (h == NULL)
einfo (_("%P%F: bfd_link_hash_lookup failed: %E\n"));
if (h->type == bfd_link_hash_new)
{
@@ -2082,27 +2053,22 @@ insert_undefined (name)
script file. */
static void
-lang_place_undefineds ()
+lang_place_undefineds (void)
{
ldlang_undef_chain_list_type *ptr;
- for (ptr = ldlang_undef_chain_list_head;
- ptr != (ldlang_undef_chain_list_type *) NULL;
- ptr = ptr->next)
- {
- insert_undefined (ptr->name);
- }
+ for (ptr = ldlang_undef_chain_list_head; ptr != NULL; ptr = ptr->next)
+ insert_undefined (ptr->name);
}
-/* Open input files and attatch to output sections. */
+/* Open input files and attach to output sections. */
static void
-map_input_to_output_sections (s, target, output_section_statement)
- lang_statement_union_type *s;
- const char *target;
- lang_output_section_statement_type *output_section_statement;
+map_input_to_output_sections
+ (lang_statement_union_type *s, const char *target,
+ lang_output_section_statement_type *output_section_statement)
{
- for (; s != (lang_statement_union_type *) NULL; s = s->header.next)
+ for (; s != NULL; s = s->header.next)
{
switch (s->header.type)
{
@@ -2129,10 +2095,14 @@ map_input_to_output_sections (s, target, output_section_statement)
target,
output_section_statement);
break;
+ case lang_data_statement_enum:
+ /* Make sure that any sections mentioned in the expression
+ are initialized. */
+ exp_init_os (s->data_statement.exp);
+ /* FALLTHROUGH */
case lang_fill_statement_enum:
case lang_input_section_enum:
case lang_object_symbols_statement_enum:
- case lang_data_statement_enum:
case lang_reloc_statement_enum:
case lang_padding_statement_enum:
case lang_input_statement_enum:
@@ -2173,7 +2143,7 @@ map_input_to_output_sections (s, target, output_section_statement)
sections if they turn out to be not needed. Clean them up here. */
static void
-strip_excluded_output_sections ()
+strip_excluded_output_sections (void)
{
lang_statement_union_type *u;
@@ -2204,8 +2174,8 @@ strip_excluded_output_sections ()
}
static void
-print_output_section_statement (output_section_statement)
- lang_output_section_statement_type *output_section_statement;
+print_output_section_statement
+ (lang_output_section_statement_type *output_section_statement)
{
asection *section = output_section_statement->bfd_section;
int len;
@@ -2250,9 +2220,8 @@ print_output_section_statement (output_section_statement)
}
static void
-print_assignment (assignment, output_section)
- lang_assignment_statement_type *assignment;
- lang_output_section_statement_type *output_section;
+print_assignment (lang_assignment_statement_type *assignment,
+ lang_output_section_statement_type *output_section)
{
int i;
etree_value_type result;
@@ -2290,10 +2259,9 @@ print_assignment (assignment, output_section)
}
static void
-print_input_statement (statm)
- lang_input_statement_type *statm;
+print_input_statement (lang_input_statement_type *statm)
{
- if (statm->filename != (char *) NULL)
+ if (statm->filename != NULL)
{
fprintf (config.map_file, "LOAD %s\n", statm->filename);
}
@@ -2302,12 +2270,10 @@ print_input_statement (statm)
/* Print all symbols defined in a particular section. This is called
via bfd_link_hash_traverse. */
-static boolean
-print_one_symbol (hash_entry, ptr)
- struct bfd_link_hash_entry *hash_entry;
- PTR ptr;
+static bfd_boolean
+print_one_symbol (struct bfd_link_hash_entry *hash_entry, void *ptr)
{
- asection *sec = (asection *) ptr;
+ asection *sec = ptr;
if ((hash_entry->type == bfd_link_hash_defined
|| hash_entry->type == bfd_link_hash_defweak)
@@ -2325,19 +2291,18 @@ print_one_symbol (hash_entry, ptr)
minfo (" %T\n", hash_entry->root.string);
}
- return true;
+ return TRUE;
}
/* Print information about an input section to the map file. */
static void
-print_input_section (in)
- lang_input_section_type *in;
+print_input_section (lang_input_section_type *in)
{
asection *i = in->section;
bfd_size_type size = i->_cooked_size != 0 ? i->_cooked_size : i->_raw_size;
- unsigned opb = bfd_arch_mach_octets_per_byte (ldfile_output_architecture,
- ldfile_output_machine);
+
+ init_opb ();
if (size != 0)
{
print_space ();
@@ -2361,7 +2326,7 @@ print_input_section (in)
}
minfo ("0x%V %W %B\n",
- i->output_section->vma + i->output_offset, size / opb,
+ i->output_section->vma + i->output_offset, TO_ADDR (size),
i->owner);
if (i->_cooked_size != 0 && i->_cooked_size != i->_raw_size)
@@ -2381,16 +2346,16 @@ print_input_section (in)
minfo (_("%W (size before relaxing)\n"), i->_raw_size);
}
- bfd_link_hash_traverse (link_info.hash, print_one_symbol, (PTR) i);
+ bfd_link_hash_traverse (link_info.hash, print_one_symbol, i);
- print_dot = i->output_section->vma + i->output_offset + size / opb;
+ print_dot = (i->output_section->vma + i->output_offset
+ + TO_ADDR (size));
}
}
}
static void
-print_fill_statement (fill)
- lang_fill_statement_type *fill;
+print_fill_statement (lang_fill_statement_type *fill)
{
size_t size;
unsigned char *p;
@@ -2401,16 +2366,14 @@ print_fill_statement (fill)
}
static void
-print_data_statement (data)
- lang_data_statement_type *data;
+print_data_statement (lang_data_statement_type *data)
{
int i;
bfd_vma addr;
bfd_size_type size;
const char *name;
- unsigned opb = bfd_arch_mach_octets_per_byte (ldfile_output_architecture,
- ldfile_output_machine);
+ init_opb ();
for (i = 0; i < SECTION_NAME_MAP_LENGTH; i++)
print_space ();
@@ -2454,16 +2417,14 @@ print_data_statement (data)
print_nl ();
- print_dot = addr + size / opb;
-
+ print_dot = addr + TO_ADDR (size);
}
/* Print an address statement. These are generated by options like
-Ttext. */
static void
-print_address_statement (address)
- lang_address_statement_type *address;
+print_address_statement (lang_address_statement_type *address)
{
minfo (_("Address of section %s set to "), address->section_name);
exp_print_tree (address->address);
@@ -2473,15 +2434,13 @@ print_address_statement (address)
/* Print a reloc statement. */
static void
-print_reloc_statement (reloc)
- lang_reloc_statement_type *reloc;
+print_reloc_statement (lang_reloc_statement_type *reloc)
{
int i;
bfd_vma addr;
bfd_size_type size;
- unsigned opb = bfd_arch_mach_octets_per_byte (ldfile_output_architecture,
- ldfile_output_machine);
+ init_opb ();
for (i = 0; i < SECTION_NAME_MAP_LENGTH; i++)
print_space ();
@@ -2502,18 +2461,16 @@ print_reloc_statement (reloc)
print_nl ();
- print_dot = addr + size / opb;
+ print_dot = addr + TO_ADDR (size);
}
static void
-print_padding_statement (s)
- lang_padding_statement_type *s;
+print_padding_statement (lang_padding_statement_type *s)
{
int len;
bfd_vma addr;
- unsigned opb = bfd_arch_mach_octets_per_byte (ldfile_output_architecture,
- ldfile_output_machine);
+ init_opb ();
minfo (" *fill*");
len = sizeof " *fill*" - 1;
@@ -2538,13 +2495,12 @@ print_padding_statement (s)
print_nl ();
- print_dot = addr + s->size / opb;
+ print_dot = addr + TO_ADDR (s->size);
}
static void
-print_wild_statement (w, os)
- lang_wild_statement_type *w;
- lang_output_section_statement_type *os;
+print_wild_statement (lang_wild_statement_type *w,
+ lang_output_section_statement_type *os)
{
struct wildcard_list *sec;
@@ -2591,9 +2547,8 @@ print_wild_statement (w, os)
/* Print a group statement. */
static void
-print_group (s, os)
- lang_group_statement_type *s;
- lang_output_section_statement_type *os;
+print_group (lang_group_statement_type *s,
+ lang_output_section_statement_type *os)
{
fprintf (config.map_file, "START GROUP\n");
print_statement_list (s->children.head, os);
@@ -2604,9 +2559,8 @@ print_group (s, os)
This can be called for any statement type. */
static void
-print_statement_list (s, os)
- lang_statement_union_type *s;
- lang_output_section_statement_type *os;
+print_statement_list (lang_statement_union_type *s,
+ lang_output_section_statement_type *os)
{
while (s != NULL)
{
@@ -2619,9 +2573,8 @@ print_statement_list (s, os)
This can be called for any statement type. */
static void
-print_statement (s, os)
- lang_statement_union_type *s;
- lang_output_section_statement_type *os;
+print_statement (lang_statement_union_type *s,
+ lang_output_section_statement_type *os)
{
switch (s->header.type)
{
@@ -2691,7 +2644,7 @@ print_statement (s, os)
}
static void
-print_statements ()
+print_statements (void)
{
print_statement_list (statement_list.head, abs_output_section);
}
@@ -2702,9 +2655,7 @@ print_statements ()
Intended to be called from GDB. */
void
-dprint_statement (s, n)
- lang_statement_union_type *s;
- int n;
+dprint_statement (lang_statement_union_type *s, int n)
{
FILE *map_save = config.map_file;
@@ -2725,12 +2676,11 @@ dprint_statement (s, n)
}
static void
-insert_pad (ptr, fill, alignment_needed, output_section, dot)
- lang_statement_union_type **ptr;
- fill_type *fill;
- unsigned int alignment_needed;
- asection *output_section;
- bfd_vma dot;
+insert_pad (lang_statement_union_type **ptr,
+ fill_type *fill,
+ unsigned int alignment_needed,
+ asection *output_section,
+ bfd_vma dot)
{
static fill_type zero_fill = { 1, { 0 } };
lang_statement_union_type *pad;
@@ -2747,13 +2697,12 @@ insert_pad (ptr, fill, alignment_needed, output_section, dot)
else
{
/* Make a new padding statement, linked into existing chain. */
- pad = ((lang_statement_union_type *)
- stat_alloc (sizeof (lang_padding_statement_type)));
+ pad = stat_alloc (sizeof (lang_padding_statement_type));
pad->header.next = *ptr;
*ptr = pad;
pad->header.type = lang_padding_statement_enum;
pad->padding_statement.output_section = output_section;
- if (fill == (fill_type *) 0)
+ if (fill == NULL)
fill = &zero_fill;
pad->padding_statement.fill = fill;
}
@@ -2765,19 +2714,16 @@ insert_pad (ptr, fill, alignment_needed, output_section, dot)
/* Work out how much this section will move the dot point. */
static bfd_vma
-size_input_section (this_ptr, output_section_statement, fill, dot)
- lang_statement_union_type **this_ptr;
- lang_output_section_statement_type *output_section_statement;
- fill_type *fill;
- bfd_vma dot;
+size_input_section (lang_statement_union_type **this_ptr,
+ lang_output_section_statement_type *output_section_statement,
+ fill_type *fill,
+ bfd_vma dot)
{
lang_input_section_type *is = &((*this_ptr)->input_section);
asection *i = is->section;
if (!is->ifile->just_syms_flag)
{
- unsigned opb = bfd_arch_mach_octets_per_byte (ldfile_output_architecture,
- ldfile_output_machine);
unsigned int alignment_needed;
asection *o;
@@ -2797,7 +2743,7 @@ size_input_section (this_ptr, output_section_statement, fill, dot)
if (alignment_needed != 0)
{
- insert_pad (this_ptr, fill, alignment_needed * opb, o, dot);
+ insert_pad (this_ptr, fill, TO_SIZE (alignment_needed), o, dot);
dot += alignment_needed;
}
@@ -2807,10 +2753,10 @@ size_input_section (this_ptr, output_section_statement, fill, dot)
/* Mark how big the output section must be to contain this now. */
if (i->_cooked_size != 0)
- dot += i->_cooked_size / opb;
+ dot += TO_ADDR (i->_cooked_size);
else
- dot += i->_raw_size / opb;
- o->_raw_size = (dot - o->vma) * opb;
+ dot += TO_ADDR (i->_raw_size);
+ o->_raw_size = TO_SIZE (dot - o->vma);
}
else
{
@@ -2821,8 +2767,11 @@ size_input_section (this_ptr, output_section_statement, fill, dot)
}
#define IGNORE_SECTION(bfd, s) \
- (((bfd_get_section_flags (bfd, s) & (SEC_ALLOC | SEC_LOAD)) \
- != (SEC_ALLOC | SEC_LOAD)) \
+ (((bfd_get_section_flags (bfd, s) & SEC_THREAD_LOCAL) \
+ ? ((bfd_get_section_flags (bfd, s) & (SEC_LOAD | SEC_NEVER_LOAD)) \
+ != SEC_LOAD) \
+ : ((bfd_get_section_flags (bfd, s) & (SEC_ALLOC | SEC_NEVER_LOAD)) \
+ != SEC_ALLOC)) \
|| bfd_section_size (bfd, s) == 0)
/* Check to see if any allocated sections overlap with other allocated
@@ -2830,10 +2779,9 @@ size_input_section (this_ptr, output_section_statement, fill, dot)
the output section addresses of the two sections. */
static void
-lang_check_section_addresses ()
+lang_check_section_addresses (void)
{
asection *s;
- unsigned opb = bfd_octets_per_byte (output_bfd);
/* Scan all sections in the output list. */
for (s = output_bfd->sections; s != NULL; s = s->next)
@@ -2861,10 +2809,10 @@ lang_check_section_addresses ()
/* We must check the sections' LMA addresses not their
VMA addresses because overlay sections can have
overlapping VMAs but they must have distinct LMAs. */
- s_start = bfd_section_lma (output_bfd, s);
+ s_start = bfd_section_lma (output_bfd, s);
os_start = bfd_section_lma (output_bfd, os);
- s_end = s_start + bfd_section_size (output_bfd, s) / opb - 1;
- os_end = os_start + bfd_section_size (output_bfd, os) / opb - 1;
+ s_end = s_start + TO_ADDR (bfd_section_size (output_bfd, s)) - 1;
+ os_end = os_start + TO_ADDR (bfd_section_size (output_bfd, os)) - 1;
/* Look for an overlap. */
if ((s_end < os_start) || (s_start > os_end))
@@ -2887,18 +2835,17 @@ _("%X%P: section %s [%V -> %V] overlaps section %s [%V -> %V]\n"),
calculation wraps around. */
static void
-os_region_check (os, region, tree, base)
- lang_output_section_statement_type *os;
- struct memory_region_struct *region;
- etree_type *tree;
- bfd_vma base;
+os_region_check (lang_output_section_statement_type *os,
+ lang_memory_region_type *region,
+ etree_type *tree,
+ bfd_vma base)
{
if ((region->current < region->origin
|| (region->current - region->origin > region->length))
&& ((region->current != region->origin + region->length)
|| base == 0))
{
- if (tree != (etree_type *) NULL)
+ if (tree != NULL)
{
einfo (_("%X%P: address 0x%v of %B section %s is not within region %s\n"),
region->current,
@@ -2921,19 +2868,17 @@ os_region_check (os, region, tree, base)
/* Set the sizes for all the output sections. */
static bfd_vma
-lang_size_sections_1 (s, output_section_statement, prev, fill, dot, relax)
- lang_statement_union_type *s;
- lang_output_section_statement_type *output_section_statement;
- lang_statement_union_type **prev;
- fill_type *fill;
- bfd_vma dot;
- boolean *relax;
+lang_size_sections_1
+ (lang_statement_union_type *s,
+ lang_output_section_statement_type *output_section_statement,
+ lang_statement_union_type **prev,
+ fill_type *fill,
+ bfd_vma dot,
+ bfd_boolean *relax,
+ bfd_boolean check_regions)
{
- unsigned opb = bfd_arch_mach_octets_per_byte (ldfile_output_architecture,
- ldfile_output_machine);
-
/* Size up the sections from their constituent parts. */
- for (; s != (lang_statement_union_type *) NULL; s = s->header.next)
+ for (; s != NULL; s = s->header.next)
{
switch (s->header.type)
{
@@ -2976,35 +2921,49 @@ lang_size_sections_1 (s, output_section_statement, prev, fill, dot, relax)
}
else
{
- if (os->addr_tree == (etree_type *) NULL)
+ if (os->addr_tree == NULL)
{
/* No address specified for this section, get one
from the region specification. */
- if (os->region == (lang_memory_region_type *) NULL
+ if (os->region == NULL
|| (((bfd_get_section_flags (output_bfd, os->bfd_section)
& (SEC_ALLOC | SEC_LOAD)) != 0)
&& os->region->name[0] == '*'
- && strcmp (os->region->name, "*default*") == 0))
+ && strcmp (os->region->name, DEFAULT_MEMORY_REGION) == 0))
{
os->region = lang_memory_default (os->bfd_section);
}
/* If a loadable section is using the default memory
region, and some non default memory regions were
- defined, issue a warning. */
- if ((bfd_get_section_flags (output_bfd, os->bfd_section)
- & (SEC_ALLOC | SEC_LOAD)) != 0
- && (bfd_get_section_flags (output_bfd, os->bfd_section)
- & SEC_NEVER_LOAD) == 0
- && ! link_info.relocateable
- && strcmp (os->region->name, "*default*") == 0
+ defined, issue an error message. */
+ if (!IGNORE_SECTION (output_bfd, os->bfd_section)
+ && ! link_info.relocatable
+ && check_regions
+ && strcmp (os->region->name, DEFAULT_MEMORY_REGION) == 0
&& lang_memory_region_list != NULL
&& (strcmp (lang_memory_region_list->name,
- "*default*") != 0
+ DEFAULT_MEMORY_REGION) != 0
|| lang_memory_region_list->next != NULL))
- einfo (_("%P: warning: no memory region specified for section `%s'\n"),
- bfd_get_section_name (output_bfd,
- os->bfd_section));
+ {
+ /* By default this is an error rather than just a
+ warning because if we allocate the section to the
+ default memory region we can end up creating an
+ excessively large binary, or even seg faulting when
+ attempting to perform a negative seek. See
+ http://sources.redhat.com/ml/binutils/2003-04/msg00423.html
+ for an example of this. This behaviour can be
+ overridden by the using the --no-check-sections
+ switch. */
+ if (command_line.check_section_addresses)
+ einfo (_("%P%F: error: no memory region specified for loadable section `%s'\n"),
+ bfd_get_section_name (output_bfd,
+ os->bfd_section));
+ else
+ einfo (_("%P: warning: no memory region specified for loadable section `%s'\n"),
+ bfd_get_section_name (output_bfd,
+ os->bfd_section));
+ }
dot = os->region->current;
@@ -3025,12 +2984,15 @@ lang_size_sections_1 (s, output_section_statement, prev, fill, dot, relax)
{
etree_value_type r;
+ os->processed = -1;
r = exp_fold_tree (os->addr_tree,
abs_output_section,
lang_allocating_phase_enum,
dot, &dot);
+ os->processed = 0;
+
if (!r.valid_p)
- einfo (_("%F%S: non constant address expression for section %s\n"),
+ einfo (_("%F%S: non constant or forward reference address expression for section %s\n"),
os->name);
dot = r.value + r.section->bfd_section->vma;
@@ -3048,26 +3010,29 @@ lang_size_sections_1 (s, output_section_statement, prev, fill, dot, relax)
}
lang_size_sections_1 (os->children.head, os, &os->children.head,
- os->fill, dot, relax);
+ os->fill, dot, relax, check_regions);
/* Put the section within the requested block size, or
align at the block boundary. */
- after = align_n (os->bfd_section->vma
- + os->bfd_section->_raw_size / opb,
- (bfd_vma) os->block_value);
+ after = ((os->bfd_section->vma
+ + TO_ADDR (os->bfd_section->_raw_size)
+ + os->block_value - 1)
+ & - (bfd_vma) os->block_value);
if (bfd_is_abs_section (os->bfd_section))
ASSERT (after == os->bfd_section->vma);
- else if ((os->bfd_section->flags & SEC_HAS_CONTENTS) == 0
- && (os->bfd_section->flags & SEC_THREAD_LOCAL)
- && ! link_info.relocateable)
- os->bfd_section->_raw_size = 0;
else
- os->bfd_section->_raw_size =
- (after - os->bfd_section->vma) * opb;
+ os->bfd_section->_raw_size
+ = TO_SIZE (after - os->bfd_section->vma);
+
+ dot = os->bfd_section->vma;
+ /* .tbss sections effectively have zero size. */
+ if ((os->bfd_section->flags & SEC_HAS_CONTENTS) != 0
+ || (os->bfd_section->flags & SEC_THREAD_LOCAL) == 0
+ || link_info.relocatable)
+ dot += TO_ADDR (os->bfd_section->_raw_size);
- dot = os->bfd_section->vma + os->bfd_section->_raw_size / opb;
- os->processed = true;
+ os->processed = 1;
if (os->update_dot_tree != 0)
exp_fold_tree (os->update_dot_tree, abs_output_section,
@@ -3081,7 +3046,7 @@ lang_size_sections_1 (s, output_section_statement, prev, fill, dot, relax)
If the SEC_NEVER_LOAD bit is not set, it will affect the
addresses of sections after it. We have to update
dot. */
- if (os->region != (lang_memory_region_type *) NULL
+ if (os->region != NULL
&& ((bfd_get_section_flags (output_bfd, os->bfd_section)
& SEC_NEVER_LOAD) == 0
|| (bfd_get_section_flags (output_bfd, os->bfd_section)
@@ -3089,9 +3054,10 @@ lang_size_sections_1 (s, output_section_statement, prev, fill, dot, relax)
{
os->region->current = dot;
- /* Make sure the new address is within the region. */
- os_region_check (os, os->region, os->addr_tree,
- os->bfd_section->vma);
+ if (check_regions)
+ /* Make sure the new address is within the region. */
+ os_region_check (os, os->region, os->addr_tree,
+ os->bfd_section->vma);
/* If there's no load address specified, use the run
region as the load region. */
@@ -3103,9 +3069,10 @@ lang_size_sections_1 (s, output_section_statement, prev, fill, dot, relax)
/* Set load_base, which will be handled later. */
os->load_base = exp_intop (os->lma_region->current);
os->lma_region->current +=
- os->bfd_section->_raw_size / opb;
- os_region_check (os, os->lma_region, NULL,
- os->bfd_section->lma);
+ TO_ADDR (os->bfd_section->_raw_size);
+ if (check_regions)
+ os_region_check (os, os->lma_region, NULL,
+ os->bfd_section->lma);
}
}
}
@@ -3115,7 +3082,7 @@ lang_size_sections_1 (s, output_section_statement, prev, fill, dot, relax)
dot = lang_size_sections_1 (constructor_list.head,
output_section_statement,
&s->wild_statement.children.head,
- fill, dot, relax);
+ fill, dot, relax, check_regions);
break;
case lang_data_statement_enum:
@@ -3127,6 +3094,11 @@ lang_size_sections_1 (s, output_section_statement, prev, fill, dot, relax)
s->data_statement.output_section =
output_section_statement->bfd_section;
+ /* We might refer to provided symbols in the expression, and
+ need to mark them as needed. */
+ exp_fold_tree (s->data_statement.exp, abs_output_section,
+ lang_allocating_phase_enum, dot, &dot);
+
switch (s->data_statement.type)
{
default:
@@ -3145,9 +3117,9 @@ lang_size_sections_1 (s, output_section_statement, prev, fill, dot, relax)
size = BYTE_SIZE;
break;
}
- if (size < opb)
- size = opb;
- dot += size / opb;
+ if (size < TO_SIZE ((unsigned) 1))
+ size = TO_SIZE ((unsigned) 1);
+ dot += TO_ADDR (size);
output_section_statement->bfd_section->_raw_size += size;
/* The output section gets contents, and then we inspect for
any flags set in the input script which override any ALLOC. */
@@ -3169,7 +3141,7 @@ lang_size_sections_1 (s, output_section_statement, prev, fill, dot, relax)
s->reloc_statement.output_section =
output_section_statement->bfd_section;
size = bfd_get_reloc_size (s->reloc_statement.howto);
- dot += size / opb;
+ dot += TO_ADDR (size);
output_section_statement->bfd_section->_raw_size += size;
}
break;
@@ -3179,7 +3151,7 @@ lang_size_sections_1 (s, output_section_statement, prev, fill, dot, relax)
dot = lang_size_sections_1 (s->wild_statement.children.head,
output_section_statement,
&s->wild_statement.children.head,
- fill, dot, relax);
+ fill, dot, relax, check_regions);
break;
@@ -3202,12 +3174,12 @@ lang_size_sections_1 (s, output_section_statement, prev, fill, dot, relax)
}
else
{
- boolean again;
+ bfd_boolean again;
if (! bfd_relax_section (i->owner, i, &link_info, &again))
einfo (_("%P%F: can't relax section: %E\n"));
if (again)
- *relax = true;
+ *relax = TRUE;
}
dot = size_input_section (prev, output_section_statement,
output_section_statement->fill, dot);
@@ -3237,20 +3209,26 @@ lang_size_sections_1 (s, output_section_statement, prev, fill, dot, relax)
{
/* If we don't have an output section, then just adjust
the default memory address. */
- lang_memory_region_lookup ("*default*")->current = newdot;
+ lang_memory_region_lookup (DEFAULT_MEMORY_REGION, FALSE)->current = newdot;
}
else
{
/* Insert a pad after this statement. We can't
put the pad before when relaxing, in case the
assignment references dot. */
- insert_pad (&s->header.next, fill, (newdot - dot) * opb,
+ insert_pad (&s->header.next, fill, TO_SIZE (newdot - dot),
output_section_statement->bfd_section, dot);
/* Don't neuter the pad below when relaxing. */
s = s->header.next;
}
+ /* If dot is advanced, this implies that the section should
+ have space allocated to it, unless the user has explicitly
+ stated that the section should never be loaded. */
+ if (!(output_section_statement->flags & (SEC_NEVER_LOAD | SEC_ALLOC)))
+ output_section_statement->bfd_section->flags |= SEC_ALLOC;
+
dot = newdot;
}
}
@@ -3277,7 +3255,7 @@ lang_size_sections_1 (s, output_section_statement, prev, fill, dot, relax)
dot = lang_size_sections_1 (s->group_statement.children.head,
output_section_statement,
&s->group_statement.children.head,
- fill, dot, relax);
+ fill, dot, relax, check_regions);
break;
default:
@@ -3294,19 +3272,24 @@ lang_size_sections_1 (s, output_section_statement, prev, fill, dot, relax)
}
bfd_vma
-lang_size_sections (s, output_section_statement, prev, fill, dot, relax)
- lang_statement_union_type *s;
- lang_output_section_statement_type *output_section_statement;
- lang_statement_union_type **prev;
- fill_type *fill;
- bfd_vma dot;
- boolean *relax;
+lang_size_sections
+ (lang_statement_union_type *s,
+ lang_output_section_statement_type *output_section_statement,
+ lang_statement_union_type **prev,
+ fill_type *fill,
+ bfd_vma dot,
+ bfd_boolean *relax,
+ bfd_boolean check_regions)
{
bfd_vma result;
+ asection *o;
+
+ /* Callers of exp_fold_tree need to increment this. */
+ lang_statement_iteration++;
exp_data_seg.phase = exp_dataseg_none;
result = lang_size_sections_1 (s, output_section_statement, prev, fill,
- dot, relax);
+ dot, relax, check_regions);
if (exp_data_seg.phase == exp_dataseg_end_seen)
{
/* If DATA_SEGMENT_ALIGN DATA_SEGMENT_END pair was seen, check whether
@@ -3321,33 +3304,41 @@ lang_size_sections (s, output_section_statement, prev, fill, dot, relax)
&& first + last <= exp_data_seg.pagesize)
{
exp_data_seg.phase = exp_dataseg_adjust;
+ lang_statement_iteration++;
result = lang_size_sections_1 (s, output_section_statement, prev,
- fill, dot, relax);
+ fill, dot, relax, check_regions);
}
}
+ /* Some backend relaxers want to refer to the output section size. Give
+ them a section size that does not change on the next call while they
+ relax. We can't set this at top because lang_reset_memory_regions
+ which is called before we get here, sets _raw_size to 0 on relaxing
+ rounds. */
+ for (o = output_bfd->sections; o != NULL; o = o->next)
+ o->_cooked_size = o->_raw_size;
+
return result;
}
-bfd_vma
-lang_do_assignments (s, output_section_statement, fill, dot)
- lang_statement_union_type *s;
- lang_output_section_statement_type *output_section_statement;
- fill_type *fill;
- bfd_vma dot;
-{
- unsigned opb = bfd_arch_mach_octets_per_byte (ldfile_output_architecture,
- ldfile_output_machine);
+/* Worker function for lang_do_assignments. Recursiveness goes here. */
- for (; s != (lang_statement_union_type *) NULL; s = s->header.next)
+static bfd_vma
+lang_do_assignments_1
+ (lang_statement_union_type *s,
+ lang_output_section_statement_type *output_section_statement,
+ fill_type *fill,
+ bfd_vma dot)
+{
+ for (; s != NULL; s = s->header.next)
{
switch (s->header.type)
{
case lang_constructors_statement_enum:
- dot = lang_do_assignments (constructor_list.head,
- output_section_statement,
- fill,
- dot);
+ dot = lang_do_assignments_1 (constructor_list.head,
+ output_section_statement,
+ fill,
+ dot);
break;
case lang_output_section_statement_enum:
@@ -3358,9 +3349,9 @@ lang_do_assignments (s, output_section_statement, fill, dot)
if (os->bfd_section != NULL)
{
dot = os->bfd_section->vma;
- (void) lang_do_assignments (os->children.head, os,
- os->fill, dot);
- dot = os->bfd_section->vma + os->bfd_section->_raw_size / opb;
+ lang_do_assignments_1 (os->children.head, os, os->fill, dot);
+ dot = (os->bfd_section->vma
+ + TO_ADDR (os->bfd_section->_raw_size));
}
if (os->load_base)
@@ -3378,9 +3369,9 @@ lang_do_assignments (s, output_section_statement, fill, dot)
break;
case lang_wild_statement_enum:
- dot = lang_do_assignments (s->wild_statement.children.head,
- output_section_statement,
- fill, dot);
+ dot = lang_do_assignments_1 (s->wild_statement.children.head,
+ output_section_statement,
+ fill, dot);
break;
@@ -3398,9 +3389,10 @@ lang_do_assignments (s, output_section_statement, fill, dot)
value = exp_fold_tree (s->data_statement.exp,
abs_output_section,
lang_final_phase_enum, dot, &dot);
- s->data_statement.value = value.value;
if (!value.valid_p)
einfo (_("%F%P: invalid data statement\n"));
+ s->data_statement.value
+ = value.value + value.section->bfd_section->vma;
}
{
unsigned int size;
@@ -3422,9 +3414,9 @@ lang_do_assignments (s, output_section_statement, fill, dot)
size = BYTE_SIZE;
break;
}
- if (size < opb)
- size = opb;
- dot += size / opb;
+ if (size < TO_SIZE ((unsigned) 1))
+ size = TO_SIZE ((unsigned) 1);
+ dot += TO_ADDR (size);
}
break;
@@ -3439,7 +3431,7 @@ lang_do_assignments (s, output_section_statement, fill, dot)
if (!value.valid_p)
einfo (_("%F%P: invalid reloc statement\n"));
}
- dot += bfd_get_reloc_size (s->reloc_statement.howto) / opb;
+ dot += TO_ADDR (bfd_get_reloc_size (s->reloc_statement.howto));
break;
case lang_input_section_enum:
@@ -3447,9 +3439,9 @@ lang_do_assignments (s, output_section_statement, fill, dot)
asection *in = s->input_section.section;
if (in->_cooked_size != 0)
- dot += in->_cooked_size / opb;
+ dot += TO_ADDR (in->_cooked_size);
else
- dot += in->_raw_size / opb;
+ dot += TO_ADDR (in->_raw_size);
}
break;
@@ -3469,13 +3461,13 @@ lang_do_assignments (s, output_section_statement, fill, dot)
break;
case lang_padding_statement_enum:
- dot += s->padding_statement.size / opb;
+ dot += TO_ADDR (s->padding_statement.size);
break;
case lang_group_statement_enum:
- dot = lang_do_assignments (s->group_statement.children.head,
- output_section_statement,
- fill, dot);
+ dot = lang_do_assignments_1 (s->group_statement.children.head,
+ output_section_statement,
+ fill, dot);
break;
@@ -3490,6 +3482,17 @@ lang_do_assignments (s, output_section_statement, fill, dot)
return dot;
}
+void
+lang_do_assignments (lang_statement_union_type *s,
+ lang_output_section_statement_type *output_section_statement,
+ fill_type *fill,
+ bfd_vma dot)
+{
+ /* Callers of exp_fold_tree need to increment this. */
+ lang_statement_iteration++;
+ lang_do_assignments_1 (s, output_section_statement, fill, dot);
+}
+
/* Fix any .startof. or .sizeof. symbols. When the assemblers see the
operator .startof. (section_name), it produces an undefined symbol
.startof.section_name. Similarly, when it sees
@@ -3498,11 +3501,11 @@ lang_do_assignments (s, output_section_statement, fill, dot)
such symbols, and set them to the correct value. */
static void
-lang_set_startof ()
+lang_set_startof (void)
{
asection *s;
- if (link_info.relocateable)
+ if (link_info.relocatable)
return;
for (s = output_bfd->sections; s != NULL; s = s->next)
@@ -3515,7 +3518,7 @@ lang_set_startof ()
buf = xmalloc (10 + strlen (secname));
sprintf (buf, ".startof.%s", secname);
- h = bfd_link_hash_lookup (link_info.hash, buf, false, false, true);
+ h = bfd_link_hash_lookup (link_info.hash, buf, FALSE, FALSE, TRUE);
if (h != NULL && h->type == bfd_link_hash_undefined)
{
h->type = bfd_link_hash_defined;
@@ -3524,18 +3527,14 @@ lang_set_startof ()
}
sprintf (buf, ".sizeof.%s", secname);
- h = bfd_link_hash_lookup (link_info.hash, buf, false, false, true);
+ h = bfd_link_hash_lookup (link_info.hash, buf, FALSE, FALSE, TRUE);
if (h != NULL && h->type == bfd_link_hash_undefined)
{
- unsigned opb;
-
- opb = bfd_arch_mach_octets_per_byte (ldfile_output_architecture,
- ldfile_output_machine);
h->type = bfd_link_hash_defined;
if (s->_cooked_size != 0)
- h->u.def.value = s->_cooked_size / opb;
+ h->u.def.value = TO_ADDR (s->_cooked_size);
else
- h->u.def.value = s->_raw_size / opb;
+ h->u.def.value = TO_ADDR (s->_raw_size);
h->u.def.section = bfd_abs_section_ptr;
}
@@ -3544,27 +3543,27 @@ lang_set_startof ()
}
static void
-lang_finish ()
+lang_finish (void)
{
struct bfd_link_hash_entry *h;
- boolean warn;
+ bfd_boolean warn;
- if (link_info.relocateable || link_info.shared)
- warn = false;
+ if (link_info.relocatable || link_info.shared)
+ warn = FALSE;
else
- warn = true;
+ warn = TRUE;
- if (entry_symbol.name == (const char *) NULL)
+ if (entry_symbol.name == NULL)
{
/* No entry has been specified. Look for start, but don't warn
if we don't find it. */
entry_symbol.name = "start";
- warn = false;
+ warn = FALSE;
}
h = bfd_link_hash_lookup (link_info.hash, entry_symbol.name,
- false, false, true);
- if (h != (struct bfd_link_hash_entry *) NULL
+ FALSE, FALSE, TRUE);
+ if (h != NULL
&& (h->type == bfd_link_hash_defined
|| h->type == bfd_link_hash_defweak)
&& h->u.def.section->output_section != NULL)
@@ -3598,7 +3597,7 @@ lang_finish ()
/* Can't find the entry symbol, and it's not a number. Use
the first address in the text section. */
ts = bfd_get_section_by_name (output_bfd, entry_section);
- if (ts != (asection *) NULL)
+ if (ts != NULL)
{
if (warn)
einfo (_("%P: warning: cannot find entry symbol %s; defaulting to %V\n"),
@@ -3617,18 +3616,15 @@ lang_finish ()
}
}
}
+
+ bfd_hash_table_free (&lang_definedness_table);
}
/* This is a small function used when we want to ignore errors from
BFD. */
static void
-#ifdef ANSI_PROTOTYPES
ignore_bfd_errors (const char *s ATTRIBUTE_UNUSED, ...)
-#else
-ignore_bfd_errors (s)
- const char *s ATTRIBUTE_UNUSED;
-#endif
{
/* Don't do anything. */
}
@@ -3638,18 +3634,17 @@ ignore_bfd_errors (s)
other checking that is needed. */
static void
-lang_check ()
+lang_check (void)
{
lang_statement_union_type *file;
bfd *input_bfd;
const bfd_arch_info_type *compatible;
- for (file = file_chain.head;
- file != (lang_statement_union_type *) NULL;
- file = file->input_statement.next)
+ for (file = file_chain.head; file != NULL; file = file->input_statement.next)
{
input_bfd = file->input_statement.the_bfd;
- compatible = bfd_arch_get_compatible (input_bfd, output_bfd);
+ compatible = bfd_arch_get_compatible (input_bfd, output_bfd,
+ command_line.accept_unknown_input_arch);
/* In general it is not possible to perform a relocatable
link between differing object formats when the input
@@ -3657,7 +3652,7 @@ lang_check ()
input format may not have equivalent representations in
the output format (and besides BFD does not translate
relocs for other link purposes than a final link). */
- if ((link_info.relocateable || link_info.emitrelocations)
+ if ((link_info.relocatable || link_info.emitrelocations)
&& (compatible == NULL
|| bfd_get_flavour (input_bfd) != bfd_get_flavour (output_bfd))
&& (bfd_get_file_flags (input_bfd) & HAS_RELOC) != 0)
@@ -3692,7 +3687,7 @@ lang_check ()
if (! bfd_merge_private_bfd_data (input_bfd, output_bfd))
{
if (command_line.warn_mismatch)
- einfo (_("%E%X: failed to merge target specific data of file %B\n"),
+ einfo (_("%P%X: failed to merge target specific data of file %B\n"),
input_bfd);
}
if (! command_line.warn_mismatch)
@@ -3706,54 +3701,49 @@ lang_check ()
to roughly sort the entries by size. */
static void
-lang_common ()
+lang_common (void)
{
if (command_line.inhibit_common_definition)
return;
- if (link_info.relocateable
+ if (link_info.relocatable
&& ! command_line.force_common_definition)
return;
if (! config.sort_common)
- bfd_link_hash_traverse (link_info.hash, lang_one_common, (PTR) NULL);
+ bfd_link_hash_traverse (link_info.hash, lang_one_common, NULL);
else
{
int power;
for (power = 4; power >= 0; power--)
- bfd_link_hash_traverse (link_info.hash, lang_one_common,
- (PTR) &power);
+ bfd_link_hash_traverse (link_info.hash, lang_one_common, &power);
}
}
/* Place one common symbol in the correct section. */
-static boolean
-lang_one_common (h, info)
- struct bfd_link_hash_entry *h;
- PTR info;
+static bfd_boolean
+lang_one_common (struct bfd_link_hash_entry *h, void *info)
{
unsigned int power_of_two;
bfd_vma size;
asection *section;
- unsigned opb = bfd_arch_mach_octets_per_byte (ldfile_output_architecture,
- ldfile_output_machine);
if (h->type != bfd_link_hash_common)
- return true;
+ return TRUE;
size = h->u.c.size;
power_of_two = h->u.c.p->alignment_power;
if (config.sort_common
&& power_of_two < (unsigned int) *(int *) info)
- return true;
+ return TRUE;
section = h->u.c.p->section;
- /* Increase the size of the section. */
- section->_cooked_size = align_n ((section->_cooked_size + opb - 1) / opb,
- (bfd_vma) 1 << power_of_two) * opb;
+ /* Increase the size of the section to align the common sym. */
+ section->_cooked_size += ((bfd_vma) 1 << (power_of_two + opb_shift)) - 1;
+ section->_cooked_size &= (- (bfd_vma) 1 << (power_of_two + opb_shift));
/* Adjust the alignment if necessary. */
if (power_of_two > section->alignment_power)
@@ -3774,7 +3764,7 @@ lang_one_common (h, info)
if (config.map_file != NULL)
{
- static boolean header_printed;
+ static bfd_boolean header_printed;
int len;
char *name;
char buf[50];
@@ -3783,7 +3773,7 @@ lang_one_common (h, info)
{
minfo (_("\nAllocating common symbols\n"));
minfo (_("Common symbol size file\n\n"));
- header_printed = true;
+ header_printed = TRUE;
}
name = demangle (h->root.string);
@@ -3819,7 +3809,7 @@ lang_one_common (h, info)
minfo ("%B\n", section->owner);
}
- return true;
+ return TRUE;
}
/* Run through the input files and ensure that every input section has
@@ -3827,19 +3817,17 @@ lang_one_common (h, info)
an input request and place it into the statement tree. */
static void
-lang_place_orphans ()
+lang_place_orphans (void)
{
LANG_FOR_EACH_INPUT_STATEMENT (file)
{
asection *s;
- for (s = file->the_bfd->sections;
- s != (asection *) NULL;
- s = s->next)
+ for (s = file->the_bfd->sections; s != NULL; s = s->next)
{
- if (s->output_section == (asection *) NULL)
+ if (s->output_section == NULL)
{
- /* This section of the file is not attatched, root
+ /* This section of the file is not attached, root
around for a sensible place for it to go. */
if (file->just_syms_flag)
@@ -3851,7 +3839,7 @@ lang_place_orphans ()
/* This is a lonely common section which must have
come from an archive. We attach to the section
with the wildcard. */
- if (! link_info.relocateable
+ if (! link_info.relocatable
|| command_line.force_common_definition)
{
if (default_common_section == NULL)
@@ -3885,10 +3873,7 @@ lang_place_orphans ()
}
void
-lang_set_flags (ptr, flags, invert)
- lang_memory_region_type *ptr;
- const char *flags;
- int invert;
+lang_set_flags (lang_memory_region_type *ptr, const char *flags, int invert)
{
flagword *ptr_flags;
@@ -3930,8 +3915,7 @@ lang_set_flags (ptr, flags, invert)
on an archive, but not on the elements. */
void
-lang_for_each_input_file (func)
- void (*func) PARAMS ((lang_input_statement_type *));
+lang_for_each_input_file (void (*func) (lang_input_statement_type *))
{
lang_input_statement_type *f;
@@ -3946,8 +3930,7 @@ lang_for_each_input_file (func)
not be called on the archive file itself. */
void
-lang_for_each_file (func)
- void (*func) PARAMS ((lang_input_statement_type *));
+lang_for_each_file (void (*func) (lang_input_statement_type *))
{
LANG_FOR_EACH_INPUT_STATEMENT (f)
{
@@ -3955,32 +3938,8 @@ lang_for_each_file (func)
}
}
-#if 0
-
-/* Not used. */
-
void
-lang_for_each_input_section (func)
- void (*func) PARAMS ((bfd *ab, asection *as));
-{
- LANG_FOR_EACH_INPUT_STATEMENT (f)
- {
- asection *s;
-
- for (s = f->the_bfd->sections;
- s != (asection *) NULL;
- s = s->next)
- {
- func (f->the_bfd, s);
- }
- }
-}
-
-#endif
-
-void
-ldlang_add_file (entry)
- lang_input_statement_type *entry;
+ldlang_add_file (lang_input_statement_type *entry)
{
bfd **pp;
@@ -3990,14 +3949,12 @@ ldlang_add_file (entry)
/* The BFD linker needs to have a list of all input BFDs involved in
a link. */
- ASSERT (entry->the_bfd->link_next == (bfd *) NULL);
+ ASSERT (entry->the_bfd->link_next == NULL);
ASSERT (entry->the_bfd != output_bfd);
- for (pp = &link_info.input_bfds;
- *pp != (bfd *) NULL;
- pp = &(*pp)->link_next)
+ for (pp = &link_info.input_bfds; *pp != NULL; pp = &(*pp)->link_next)
;
*pp = entry->the_bfd;
- entry->the_bfd->usrdata = (PTR) entry;
+ entry->the_bfd->usrdata = entry;
bfd_set_gp_size (entry->the_bfd, g_switch_value);
/* Look through the sections and check for any which should not be
@@ -4010,27 +3967,24 @@ ldlang_add_file (entry)
each backend which might set the SEC_LINK_ONCE flag. If we do
this, we should probably handle SEC_EXCLUDE in the same way. */
- bfd_map_over_sections (entry->the_bfd, section_already_linked, (PTR) entry);
+ bfd_map_over_sections (entry->the_bfd, section_already_linked, entry);
}
void
-lang_add_output (name, from_script)
- const char *name;
- int from_script;
+lang_add_output (const char *name, int from_script)
{
/* Make -o on command line override OUTPUT in script. */
if (!had_output_filename || !from_script)
{
output_filename = name;
- had_output_filename = true;
+ had_output_filename = TRUE;
}
}
static lang_output_section_statement_type *current_section;
static int
-topower (x)
- int x;
+topower (int x)
{
unsigned int i = 1;
int l;
@@ -4049,16 +4003,12 @@ topower (x)
}
lang_output_section_statement_type *
-lang_enter_output_section_statement (output_section_statement_name,
- address_exp, sectype, block_value,
- align, subalign, ebase)
- const char *output_section_statement_name;
- etree_type *address_exp;
- enum section_type sectype;
- bfd_vma block_value;
- etree_type *align;
- etree_type *subalign;
- etree_type *ebase;
+lang_enter_output_section_statement (const char *output_section_statement_name,
+ etree_type *address_exp,
+ enum section_type sectype,
+ etree_type *align,
+ etree_type *subalign,
+ etree_type *ebase)
{
lang_output_section_statement_type *os;
@@ -4073,7 +4023,7 @@ lang_enter_output_section_statement (output_section_statement_name,
#endif
/* Make next things chain into subchain of this. */
- if (os->addr_tree == (etree_type *) NULL)
+ if (os->addr_tree == NULL)
{
os->addr_tree = address_exp;
}
@@ -4082,7 +4032,7 @@ lang_enter_output_section_statement (output_section_statement_name,
os->flags = SEC_NO_FLAGS;
else
os->flags = SEC_NEVER_LOAD;
- os->block_value = block_value ? block_value : 1;
+ os->block_value = 1;
stat_ptr = &os->children;
os->subsection_alignment =
@@ -4095,7 +4045,7 @@ lang_enter_output_section_statement (output_section_statement_name,
}
void
-lang_final ()
+lang_final (void)
{
lang_output_statement_type *new =
new_stat (lang_output_statement, stat_ptr);
@@ -4106,14 +4056,12 @@ lang_final ()
/* Reset the current counters in the regions. */
void
-lang_reset_memory_regions ()
+lang_reset_memory_regions (void)
{
lang_memory_region_type *p = lang_memory_region_list;
asection *o;
- for (p = lang_memory_region_list;
- p != (lang_memory_region_type *) NULL;
- p = p->next)
+ for (p = lang_memory_region_list; p != NULL; p = p->next)
{
p->old_length = (bfd_size_type) (p->current - p->origin);
p->current = p->origin;
@@ -4127,12 +4075,11 @@ lang_reset_memory_regions ()
should be as well. */
static void
-gc_section_callback (ptr, sec, section, file, data)
- lang_wild_statement_type *ptr;
- struct wildcard_list *sec ATTRIBUTE_UNUSED;
- asection *section;
- lang_input_statement_type *file ATTRIBUTE_UNUSED;
- PTR data ATTRIBUTE_UNUSED;
+gc_section_callback (lang_wild_statement_type *ptr,
+ struct wildcard_list *sec ATTRIBUTE_UNUSED,
+ asection *section,
+ lang_input_statement_type *file ATTRIBUTE_UNUSED,
+ void *data ATTRIBUTE_UNUSED)
{
if (ptr->keep_sections)
section->flags |= SEC_KEEP;
@@ -4141,8 +4088,7 @@ gc_section_callback (ptr, sec, section, file, data)
/* Handle a wild statement, marking it against GC. */
static void
-lang_gc_wild (s)
- lang_wild_statement_type *s;
+lang_gc_wild (lang_wild_statement_type *s)
{
walk_wild (s, gc_section_callback, NULL);
}
@@ -4150,10 +4096,9 @@ lang_gc_wild (s)
/* Iterate over sections marking them against GC. */
static void
-lang_gc_sections_1 (s)
- lang_statement_union_type *s;
+lang_gc_sections_1 (lang_statement_union_type *s)
{
- for (; s != (lang_statement_union_type *) NULL; s = s->header.next)
+ for (; s != NULL; s = s->header.next)
{
switch (s->header.type)
{
@@ -4176,7 +4121,7 @@ lang_gc_sections_1 (s)
}
static void
-lang_gc_sections ()
+lang_gc_sections (void)
{
struct bfd_link_hash_entry *h;
ldlang_undef_chain_list_type *ulist;
@@ -4191,9 +4136,9 @@ lang_gc_sections ()
for (ulist = link_info.gc_sym_list; ulist; ulist = ulist->next)
{
h = bfd_link_hash_lookup (link_info.hash, ulist->name,
- false, false, false);
+ FALSE, FALSE, FALSE);
- if (h != (struct bfd_link_hash_entry *) NULL
+ if (h != NULL
&& (h->type == bfd_link_hash_defined
|| h->type == bfd_link_hash_defweak)
&& ! bfd_is_abs_section (h->u.def.section))
@@ -4206,13 +4151,14 @@ lang_gc_sections ()
}
void
-lang_process ()
+lang_process (void)
{
lang_reasonable_defaults ();
current_target = default_target;
/* Open the output file. */
lang_for_each_statement (ldlang_open_output);
+ init_opb ();
ldemul_create_output_section_statements ();
@@ -4223,7 +4169,7 @@ lang_process ()
/* Create a bfd for each input file. */
current_target = default_target;
- open_input_bfds (statement_list.head, false);
+ open_input_bfds (statement_list.head, FALSE);
link_info.gc_sym_list = &entry_symbol;
if (entry_symbol.name == NULL)
@@ -4263,18 +4209,17 @@ lang_process ()
/* Run through the contours of the script and attach input sections
to the correct output sections. */
- map_input_to_output_sections (statement_list.head, (char *) NULL,
- (lang_output_section_statement_type *) NULL);
+ map_input_to_output_sections (statement_list.head, NULL, NULL);
/* Find any sections not attached explicitly and handle them. */
lang_place_orphans ();
- if (! link_info.relocateable)
+ if (! link_info.relocatable)
{
/* Look for a text section and set the readonly attribute in it. */
asection *found = bfd_get_section_by_name (output_bfd, ".text");
- if (found != (asection *) NULL)
+ if (found != NULL)
{
if (config.text_read_only)
found->flags |= SEC_READONLY;
@@ -4287,7 +4232,7 @@ lang_process ()
and other back-ends size dynamic sections. */
ldemul_before_allocation ();
- if (!link_info.relocateable)
+ if (!link_info.relocatable)
strip_excluded_output_sections ();
/* We must record the program headers before we try to fix the
@@ -4295,21 +4240,19 @@ lang_process ()
lang_record_phdrs ();
/* Size up the sections. */
- lang_size_sections (statement_list.head,
- abs_output_section,
- &statement_list.head, 0, (bfd_vma) 0, NULL);
+ lang_size_sections (statement_list.head, abs_output_section,
+ &statement_list.head, 0, 0, NULL,
+ command_line.relax ? FALSE : TRUE);
/* Now run around and relax if we can. */
if (command_line.relax)
{
/* Keep relaxing until bfd_relax_section gives up. */
- boolean relax_again;
+ bfd_boolean relax_again;
do
{
- lang_reset_memory_regions ();
-
- relax_again = false;
+ relax_again = FALSE;
/* Note: pe-dll.c does something like this also. If you find
you need to change this code, you probably need to change
@@ -4317,18 +4260,33 @@ lang_process ()
/* Do all the assignments with our current guesses as to
section sizes. */
- lang_do_assignments (statement_list.head,
- abs_output_section,
- (fill_type *) 0, (bfd_vma) 0);
+ lang_do_assignments (statement_list.head, abs_output_section,
+ NULL, 0);
+
+ /* We must do this after lang_do_assignments, because it uses
+ _raw_size. */
+ lang_reset_memory_regions ();
/* Perform another relax pass - this time we know where the
globals are, so can make a better guess. */
- lang_size_sections (statement_list.head,
- abs_output_section,
- &statement_list.head, 0, (bfd_vma) 0,
- &relax_again);
+ lang_size_sections (statement_list.head, abs_output_section,
+ &statement_list.head, 0, 0, &relax_again, FALSE);
+
+ /* If the normal relax is done and the relax finalize pass
+ is not performed yet, we perform another relax pass. */
+ if (!relax_again && link_info.need_relax_finalize)
+ {
+ link_info.need_relax_finalize = FALSE;
+ relax_again = TRUE;
+ }
}
while (relax_again);
+
+ /* Final extra sizing to report errors. */
+ lang_do_assignments (statement_list.head, abs_output_section, NULL, 0);
+ lang_reset_memory_regions ();
+ lang_size_sections (statement_list.head, abs_output_section,
+ &statement_list.head, 0, 0, NULL, TRUE);
}
/* See if anything special should be done now we know how big
@@ -4341,12 +4299,10 @@ lang_process ()
/* Do all the assignments, now that we know the final resting places
of all the symbols. */
- lang_do_assignments (statement_list.head,
- abs_output_section,
- (fill_type *) 0, (bfd_vma) 0);
+ lang_do_assignments (statement_list.head, abs_output_section, NULL, 0);
/* Make sure that the section addresses make sense. */
- if (! link_info.relocateable
+ if (! link_info.relocatable
&& command_line.check_section_addresses)
lang_check_section_addresses ();
@@ -4359,10 +4315,9 @@ lang_process ()
/* EXPORTED TO YACC */
void
-lang_add_wild (filespec, section_list, keep_sections)
- struct wildcard_spec *filespec;
- struct wildcard_list *section_list;
- boolean keep_sections;
+lang_add_wild (struct wildcard_spec *filespec,
+ struct wildcard_list *section_list,
+ bfd_boolean keep_sections)
{
struct wildcard_list *curr, *next;
lang_wild_statement_type *new;
@@ -4373,7 +4328,7 @@ lang_add_wild (filespec, section_list, keep_sections)
section_list = curr, curr = next)
{
if (curr->spec.name != NULL && strcmp (curr->spec.name, "COMMON") == 0)
- placed_commons = true;
+ placed_commons = TRUE;
next = curr->next;
curr->next = section_list;
@@ -4384,12 +4339,12 @@ lang_add_wild (filespec, section_list, keep_sections)
if (strcmp (filespec->name, "*") == 0)
filespec->name = NULL;
else if (! wildcardp (filespec->name))
- lang_has_input_file = true;
+ lang_has_input_file = TRUE;
}
new = new_stat (lang_wild_statement, stat_ptr);
new->filename = NULL;
- new->filenames_sorted = false;
+ new->filenames_sorted = FALSE;
if (filespec != NULL)
{
new->filename = filespec->name;
@@ -4401,9 +4356,7 @@ lang_add_wild (filespec, section_list, keep_sections)
}
void
-lang_section_start (name, address)
- const char *name;
- etree_type *address;
+lang_section_start (const char *name, etree_type *address)
{
lang_address_statement_type *ad;
@@ -4418,9 +4371,7 @@ lang_section_start (name, address)
precedence. */
void
-lang_add_entry (name, cmdline)
- const char *name;
- boolean cmdline;
+lang_add_entry (const char *name, bfd_boolean cmdline)
{
if (entry_symbol.name == NULL
|| cmdline
@@ -4432,8 +4383,7 @@ lang_add_entry (name, cmdline)
}
void
-lang_add_target (name)
- const char *name;
+lang_add_target (const char *name)
{
lang_target_statement_type *new = new_stat (lang_target_statement,
stat_ptr);
@@ -4443,15 +4393,14 @@ lang_add_target (name)
}
void
-lang_add_map (name)
- const char *name;
+lang_add_map (const char *name)
{
while (*name)
{
switch (*name)
{
case 'F':
- map_option_f = true;
+ map_option_f = TRUE;
break;
}
name++;
@@ -4459,8 +4408,7 @@ lang_add_map (name)
}
void
-lang_add_fill (fill)
- fill_type *fill;
+lang_add_fill (fill_type *fill)
{
lang_fill_statement_type *new = new_stat (lang_fill_statement,
stat_ptr);
@@ -4469,9 +4417,7 @@ lang_add_fill (fill)
}
void
-lang_add_data (type, exp)
- int type;
- union etree_union *exp;
+lang_add_data (int type, union etree_union *exp)
{
lang_data_statement_type *new = new_stat (lang_data_statement,
@@ -4490,12 +4436,11 @@ lang_add_data (type, exp)
NAME must be NULL. ADDEND is an expression for the addend. */
void
-lang_add_reloc (reloc, howto, section, name, addend)
- bfd_reloc_code_real_type reloc;
- reloc_howto_type *howto;
- asection *section;
- const char *name;
- union etree_union *addend;
+lang_add_reloc (bfd_reloc_code_real_type reloc,
+ reloc_howto_type *howto,
+ asection *section,
+ const char *name,
+ union etree_union *addend)
{
lang_reloc_statement_type *p = new_stat (lang_reloc_statement, stat_ptr);
@@ -4511,8 +4456,7 @@ lang_add_reloc (reloc, howto, section, name, addend)
}
lang_assignment_statement_type *
-lang_add_assignment (exp)
- etree_type *exp;
+lang_add_assignment (etree_type *exp)
{
lang_assignment_statement_type *new = new_stat (lang_assignment_statement,
stat_ptr);
@@ -4522,30 +4466,27 @@ lang_add_assignment (exp)
}
void
-lang_add_attribute (attribute)
- enum statement_enum attribute;
+lang_add_attribute (enum statement_enum attribute)
{
new_statement (attribute, sizeof (lang_statement_union_type), stat_ptr);
}
void
-lang_startup (name)
- const char *name;
+lang_startup (const char *name)
{
- if (startup_file != (char *) NULL)
+ if (startup_file != NULL)
{
einfo (_("%P%Fmultiple STARTUP files\n"));
}
first_file->filename = name;
first_file->local_sym_name = name;
- first_file->real = true;
+ first_file->real = TRUE;
startup_file = name;
}
void
-lang_float (maybe)
- boolean maybe;
+lang_float (bfd_boolean maybe)
{
lang_float_flag = maybe;
}
@@ -4554,43 +4495,47 @@ lang_float (maybe)
/* Work out the load- and run-time regions from a script statement, and
store them in *LMA_REGION and *REGION respectively.
- MEMSPEC is the name of the run-time region, or "*default*" if the
- statement didn't specify one. LMA_MEMSPEC is the name of the
- load-time region, or null if the statement didn't specify one.
- HAVE_LMA_P is true if the statement had an explicit load address.
+ MEMSPEC is the name of the run-time region, or the value of
+ DEFAULT_MEMORY_REGION if the statement didn't specify one.
+ LMA_MEMSPEC is the name of the load-time region, or null if the
+ statement didn't specify one.HAVE_LMA_P is TRUE if the statement
+ had an explicit load address.
It is an error to specify both a load region and a load address. */
static void
-lang_get_regions (region, lma_region, memspec, lma_memspec, have_lma_p)
- struct memory_region_struct **region, **lma_region;
- const char *memspec, *lma_memspec;
- int have_lma_p;
-{
- *lma_region = lang_memory_region_lookup (lma_memspec);
-
- /* If no runtime region has been given, but the load region has
- been, use the load region. */
- if (lma_memspec != 0 && strcmp (memspec, "*default*") == 0)
+lang_get_regions (lang_memory_region_type **region,
+ lang_memory_region_type **lma_region,
+ const char *memspec,
+ const char *lma_memspec,
+ bfd_boolean have_lma,
+ bfd_boolean have_vma)
+{
+ *lma_region = lang_memory_region_lookup (lma_memspec, FALSE);
+
+ /* If no runtime region or VMA has been specified, but the load region has
+ been specified, then use the load region for the runtime region as well. */
+ if (lma_memspec != NULL
+ && ! have_vma
+ && strcmp (memspec, DEFAULT_MEMORY_REGION) == 0)
*region = *lma_region;
else
- *region = lang_memory_region_lookup (memspec);
+ *region = lang_memory_region_lookup (memspec, FALSE);
- if (have_lma_p && lma_memspec != 0)
+ if (have_lma && lma_memspec != 0)
einfo (_("%X%P:%S: section has both a load address and a load region\n"));
}
void
-lang_leave_output_section_statement (fill, memspec, phdrs, lma_memspec)
- fill_type *fill;
- const char *memspec;
- struct lang_output_section_phdr_list *phdrs;
- const char *lma_memspec;
+lang_leave_output_section_statement (fill_type *fill, const char *memspec,
+ lang_output_section_phdr_list *phdrs,
+ const char *lma_memspec)
{
lang_get_regions (&current_section->region,
&current_section->lma_region,
memspec, lma_memspec,
- current_section->load_base != 0);
+ current_section->load_base != NULL,
+ current_section->addr_tree != NULL);
current_section->fill = fill;
current_section->phdrs = phdrs;
stat_ptr = &statement_list;
@@ -4602,14 +4547,12 @@ lang_leave_output_section_statement (fill, memspec, phdrs, lma_memspec)
If the symbol already exists, then do nothing. */
void
-lang_abs_symbol_at_beginning_of (secname, name)
- const char *secname;
- const char *name;
+lang_abs_symbol_at_beginning_of (const char *secname, const char *name)
{
struct bfd_link_hash_entry *h;
- h = bfd_link_hash_lookup (link_info.hash, name, true, true, true);
- if (h == (struct bfd_link_hash_entry *) NULL)
+ h = bfd_link_hash_lookup (link_info.hash, name, TRUE, TRUE, TRUE);
+ if (h == NULL)
einfo (_("%P%F: bfd_link_hash_lookup failed: %E\n"));
if (h->type == bfd_link_hash_new
@@ -4620,7 +4563,7 @@ lang_abs_symbol_at_beginning_of (secname, name)
h->type = bfd_link_hash_defined;
sec = bfd_get_section_by_name (output_bfd, secname);
- if (sec == (asection *) NULL)
+ if (sec == NULL)
h->u.def.value = 0;
else
h->u.def.value = bfd_get_section_vma (output_bfd, sec);
@@ -4635,14 +4578,12 @@ lang_abs_symbol_at_beginning_of (secname, name)
If the symbol already exists, then do nothing. */
void
-lang_abs_symbol_at_end_of (secname, name)
- const char *secname;
- const char *name;
+lang_abs_symbol_at_end_of (const char *secname, const char *name)
{
struct bfd_link_hash_entry *h;
- h = bfd_link_hash_lookup (link_info.hash, name, true, true, true);
- if (h == (struct bfd_link_hash_entry *) NULL)
+ h = bfd_link_hash_lookup (link_info.hash, name, TRUE, TRUE, TRUE);
+ if (h == NULL)
einfo (_("%P%F: bfd_link_hash_lookup failed: %E\n"));
if (h->type == bfd_link_hash_new
@@ -4653,22 +4594,20 @@ lang_abs_symbol_at_end_of (secname, name)
h->type = bfd_link_hash_defined;
sec = bfd_get_section_by_name (output_bfd, secname);
- if (sec == (asection *) NULL)
+ if (sec == NULL)
h->u.def.value = 0;
else
h->u.def.value = (bfd_get_section_vma (output_bfd, sec)
- + bfd_section_size (output_bfd, sec) /
- bfd_octets_per_byte (output_bfd));
+ + TO_ADDR (bfd_section_size (output_bfd, sec)));
h->u.def.section = bfd_abs_section_ptr;
}
}
void
-lang_statement_append (list, element, field)
- lang_statement_list_type *list;
- lang_statement_union_type *element;
- lang_statement_union_type **field;
+lang_statement_append (lang_statement_list_type *list,
+ lang_statement_union_type *element,
+ lang_statement_union_type **field)
{
*(list->tail) = element;
list->tail = field;
@@ -4677,11 +4616,10 @@ lang_statement_append (list, element, field)
/* Set the output format type. -oformat overrides scripts. */
void
-lang_add_output_format (format, big, little, from_script)
- const char *format;
- const char *big;
- const char *little;
- int from_script;
+lang_add_output_format (const char *format,
+ const char *big,
+ const char *little,
+ int from_script)
{
if (output_target == NULL || !from_script)
{
@@ -4700,7 +4638,7 @@ lang_add_output_format (format, big, little, from_script)
stat_ptr to build new statements within the group. */
void
-lang_enter_group ()
+lang_enter_group (void)
{
lang_group_statement_type *g;
@@ -4715,7 +4653,7 @@ lang_enter_group ()
but currently they can't. */
void
-lang_leave_group ()
+lang_leave_group (void)
{
stat_ptr = &statement_list;
}
@@ -4724,17 +4662,16 @@ lang_leave_group ()
command in a linker script. */
void
-lang_new_phdr (name, type, filehdr, phdrs, at, flags)
- const char *name;
- etree_type *type;
- boolean filehdr;
- boolean phdrs;
- etree_type *at;
- etree_type *flags;
+lang_new_phdr (const char *name,
+ etree_type *type,
+ bfd_boolean filehdr,
+ bfd_boolean phdrs,
+ etree_type *at,
+ etree_type *flags)
{
struct lang_phdr *n, **pp;
- n = (struct lang_phdr *) stat_alloc (sizeof (struct lang_phdr));
+ n = stat_alloc (sizeof (struct lang_phdr));
n->next = NULL;
n->name = name;
n->type = exp_get_value_int (type, 0, "program header type",
@@ -4753,16 +4690,16 @@ lang_new_phdr (name, type, filehdr, phdrs, at, flags)
should not be calling an ELF specific function here. */
static void
-lang_record_phdrs ()
+lang_record_phdrs (void)
{
unsigned int alc;
asection **secs;
- struct lang_output_section_phdr_list *last;
+ lang_output_section_phdr_list *last;
struct lang_phdr *l;
lang_statement_union_type *u;
alc = 10;
- secs = (asection **) xmalloc (alc * sizeof (asection *));
+ secs = xmalloc (alc * sizeof (asection *));
last = NULL;
for (l = lang_phdr_list; l != NULL; l = l->next)
{
@@ -4776,7 +4713,7 @@ lang_record_phdrs ()
u = u->output_section_statement.next)
{
lang_output_section_statement_type *os;
- struct lang_output_section_phdr_list *pl;
+ lang_output_section_phdr_list *pl;
os = &u->output_section_statement;
@@ -4802,12 +4739,11 @@ lang_record_phdrs ()
if (c >= alc)
{
alc *= 2;
- secs = ((asection **)
- xrealloc (secs, alc * sizeof (asection *)));
+ secs = xrealloc (secs, alc * sizeof (asection *));
}
secs[c] = os->bfd_section;
++c;
- pl->used = true;
+ pl->used = TRUE;
}
}
}
@@ -4837,7 +4773,7 @@ lang_record_phdrs ()
u != NULL;
u = u->output_section_statement.next)
{
- struct lang_output_section_phdr_list *pl;
+ lang_output_section_phdr_list *pl;
if (u->output_section_statement.bfd_section == NULL)
continue;
@@ -4854,24 +4790,25 @@ lang_record_phdrs ()
/* Record a list of sections which may not be cross referenced. */
void
-lang_add_nocrossref (l)
- struct lang_nocrossref *l;
+lang_add_nocrossref (lang_nocrossref_type *l)
{
struct lang_nocrossrefs *n;
- n = (struct lang_nocrossrefs *) xmalloc (sizeof *n);
+ n = xmalloc (sizeof *n);
n->next = nocrossref_list;
n->list = l;
nocrossref_list = n;
/* Set notice_all so that we get informed about all symbols. */
- link_info.notice_all = true;
+ link_info.notice_all = TRUE;
}
/* Overlay handling. We handle overlays with some static variables. */
/* The overlay virtual address. */
static etree_type *overlay_vma;
+/* And subsection alignment. */
+static etree_type *overlay_subalign;
/* An expression for the maximum section size seen so far. */
static etree_type *overlay_max;
@@ -4888,13 +4825,15 @@ static struct overlay_list *overlay_list;
/* Start handling an overlay. */
void
-lang_enter_overlay (vma_expr)
- etree_type *vma_expr;
+lang_enter_overlay (etree_type *vma_expr, etree_type *subalign)
{
/* The grammar should prevent nested overlays from occurring. */
- ASSERT (overlay_vma == NULL && overlay_max == NULL);
+ ASSERT (overlay_vma == NULL
+ && overlay_subalign == NULL
+ && overlay_max == NULL);
overlay_vma = vma_expr;
+ overlay_subalign = subalign;
}
/* Start a section in an overlay. We handle this by calling
@@ -4902,14 +4841,13 @@ lang_enter_overlay (vma_expr)
lang_leave_overlay sets up the LMA and memory regions. */
void
-lang_enter_overlay_section (name)
- const char *name;
+lang_enter_overlay_section (const char *name)
{
struct overlay_list *n;
etree_type *size;
lang_enter_output_section_statement (name, overlay_vma, normal_section,
- 0, 0, 0, 0);
+ 0, overlay_subalign, 0);
/* If this is the first section, then base the VMA of future
sections on this one. This will work correctly even if `.' is
@@ -4918,7 +4856,7 @@ lang_enter_overlay_section (name)
overlay_vma = exp_nameop (ADDR, name);
/* Remember the section. */
- n = (struct overlay_list *) xmalloc (sizeof *n);
+ n = xmalloc (sizeof *n);
n->os = current_section;
n->next = overlay_list;
overlay_list = n;
@@ -4936,9 +4874,8 @@ lang_enter_overlay_section (name)
here. */
void
-lang_leave_overlay_section (fill, phdrs)
- fill_type *fill;
- struct lang_output_section_phdr_list *phdrs;
+lang_leave_overlay_section (fill_type *fill,
+ lang_output_section_phdr_list *phdrs)
{
const char *name;
char *clean, *s2;
@@ -4947,10 +4884,11 @@ lang_leave_overlay_section (fill, phdrs)
name = current_section->name;
- /* For now, assume that "*default*" is the run-time memory region and
- that no load-time region has been specified. It doesn't really
- matter what we say here, since lang_leave_overlay will override it. */
- lang_leave_output_section_statement (fill, "*default*", phdrs, 0);
+ /* For now, assume that DEFAULT_MEMORY_REGION is the run-time memory
+ region and that no load-time region has been specified. It doesn't
+ really matter what we say here, since lang_leave_overlay will
+ override it. */
+ lang_leave_output_section_statement (fill, DEFAULT_MEMORY_REGION, phdrs, 0);
/* Define the magic symbols. */
@@ -4980,22 +4918,21 @@ lang_leave_overlay_section (fill, phdrs)
looks through all the sections in the overlay and sets them. */
void
-lang_leave_overlay (lma_expr, nocrossrefs, fill, memspec, phdrs, lma_memspec)
- etree_type *lma_expr;
- int nocrossrefs;
- fill_type *fill;
- const char *memspec;
- struct lang_output_section_phdr_list *phdrs;
- const char *lma_memspec;
+lang_leave_overlay (etree_type *lma_expr,
+ int nocrossrefs,
+ fill_type *fill,
+ const char *memspec,
+ lang_output_section_phdr_list *phdrs,
+ const char *lma_memspec)
{
lang_memory_region_type *region;
lang_memory_region_type *lma_region;
struct overlay_list *l;
- struct lang_nocrossref *nocrossref;
+ lang_nocrossref_type *nocrossref;
lang_get_regions (&region, &lma_region,
memspec, lma_memspec,
- lma_expr != 0);
+ lma_expr != NULL, FALSE);
nocrossref = NULL;
@@ -5010,7 +4947,7 @@ lang_leave_overlay (lma_expr, nocrossrefs, fill, memspec, phdrs, lma_memspec)
{
struct overlay_list *next;
- if (fill != (fill_type *) 0 && l->os->fill == (fill_type *) 0)
+ if (fill != NULL && l->os->fill == NULL)
l->os->fill = fill;
l->os->region = region;
@@ -5032,9 +4969,9 @@ lang_leave_overlay (lma_expr, nocrossrefs, fill, memspec, phdrs, lma_memspec)
if (nocrossrefs)
{
- struct lang_nocrossref *nc;
+ lang_nocrossref_type *nc;
- nc = (struct lang_nocrossref *) xmalloc (sizeof *nc);
+ nc = xmalloc (sizeof *nc);
nc->name = l->os->name;
nc->next = nocrossref;
nocrossref = nc;
@@ -5059,97 +4996,181 @@ lang_leave_overlay (lma_expr, nocrossrefs, fill, memspec, phdrs, lma_memspec)
struct bfd_elf_version_tree *lang_elf_version_info;
-static int
-lang_vers_match_lang_c (expr, sym)
- struct bfd_elf_version_expr *expr;
- const char *sym;
-{
- if (expr->pattern[0] == '*' && expr->pattern[1] == '\0')
- return 1;
- return fnmatch (expr->pattern, sym, 0) == 0;
-}
+/* If PREV is NULL, return first version pattern matching particular symbol.
+ If PREV is non-NULL, return first version pattern matching particular
+ symbol after PREV (previously returned by lang_vers_match). */
-static int
-lang_vers_match_lang_cplusplus (expr, sym)
- struct bfd_elf_version_expr *expr;
- const char *sym;
+static struct bfd_elf_version_expr *
+lang_vers_match (struct bfd_elf_version_expr_head *head,
+ struct bfd_elf_version_expr *prev,
+ const char *sym)
{
- char *alt_sym;
- int result;
+ const char *cxx_sym = sym;
+ const char *java_sym = sym;
+ struct bfd_elf_version_expr *expr = NULL;
- if (expr->pattern[0] == '*' && expr->pattern[1] == '\0')
- return 1;
+ if (head->mask & BFD_ELF_VERSION_CXX_TYPE)
+ {
+ cxx_sym = cplus_demangle (sym, DMGL_PARAMS | DMGL_ANSI);
+ if (!cxx_sym)
+ cxx_sym = sym;
+ }
+ if (head->mask & BFD_ELF_VERSION_JAVA_TYPE)
+ {
+ java_sym = cplus_demangle (sym, DMGL_JAVA);
+ if (!java_sym)
+ java_sym = sym;
+ }
- alt_sym = cplus_demangle (sym, /* DMGL_NO_TPARAMS */ 0);
- if (!alt_sym)
+ if (head->htab && (prev == NULL || prev->symbol))
{
- /* cplus_demangle (also) returns NULL when it is not a C++ symbol.
- Should we early out false in this case? */
- result = fnmatch (expr->pattern, sym, 0) == 0;
+ struct bfd_elf_version_expr e;
+
+ switch (prev ? prev->mask : 0)
+ {
+ case 0:
+ if (head->mask & BFD_ELF_VERSION_C_TYPE)
+ {
+ e.symbol = sym;
+ expr = htab_find (head->htab, &e);
+ while (expr && strcmp (expr->symbol, sym) == 0)
+ if (expr->mask == BFD_ELF_VERSION_C_TYPE)
+ goto out_ret;
+ else
+ expr = expr->next;
+ }
+ /* Fallthrough */
+ case BFD_ELF_VERSION_C_TYPE:
+ if (head->mask & BFD_ELF_VERSION_CXX_TYPE)
+ {
+ e.symbol = cxx_sym;
+ expr = htab_find (head->htab, &e);
+ while (expr && strcmp (expr->symbol, cxx_sym) == 0)
+ if (expr->mask == BFD_ELF_VERSION_CXX_TYPE)
+ goto out_ret;
+ else
+ expr = expr->next;
+ }
+ /* Fallthrough */
+ case BFD_ELF_VERSION_CXX_TYPE:
+ if (head->mask & BFD_ELF_VERSION_JAVA_TYPE)
+ {
+ e.symbol = java_sym;
+ expr = htab_find (head->htab, &e);
+ while (expr && strcmp (expr->symbol, java_sym) == 0)
+ if (expr->mask == BFD_ELF_VERSION_JAVA_TYPE)
+ goto out_ret;
+ else
+ expr = expr->next;
+ }
+ /* Fallthrough */
+ default:
+ break;
+ }
}
+
+ /* Finally, try the wildcards. */
+ if (prev == NULL || prev->symbol)
+ expr = head->remaining;
else
+ expr = prev->next;
+ while (expr)
{
- result = fnmatch (expr->pattern, alt_sym, 0) == 0;
- free (alt_sym);
+ const char *s;
+
+ if (expr->pattern[0] == '*' && expr->pattern[1] == '\0')
+ break;
+
+ if (expr->mask == BFD_ELF_VERSION_JAVA_TYPE)
+ s = java_sym;
+ else if (expr->mask == BFD_ELF_VERSION_CXX_TYPE)
+ s = cxx_sym;
+ else
+ s = sym;
+ if (fnmatch (expr->pattern, s, 0) == 0)
+ break;
+ expr = expr->next;
}
- return result;
+out_ret:
+ if (cxx_sym != sym)
+ free ((char *) cxx_sym);
+ if (java_sym != sym)
+ free ((char *) java_sym);
+ return expr;
}
-static int
-lang_vers_match_lang_java (expr, sym)
- struct bfd_elf_version_expr *expr;
- const char *sym;
+/* Return NULL if the PATTERN argument is a glob pattern, otherwise,
+ return a string pointing to the symbol name. */
+
+static const char *
+realsymbol (const char *pattern)
{
- char *alt_sym;
- int result;
+ const char *p;
+ bfd_boolean changed = FALSE, backslash = FALSE;
+ char *s, *symbol = xmalloc (strlen (pattern) + 1);
- if (expr->pattern[0] == '*' && expr->pattern[1] == '\0')
- return 1;
+ for (p = pattern, s = symbol; *p != '\0'; ++p)
+ {
+ /* It is a glob pattern only if there is no preceding
+ backslash. */
+ if (! backslash && (*p == '?' || *p == '*' || *p == '['))
+ {
+ free (symbol);
+ return NULL;
+ }
- alt_sym = cplus_demangle (sym, DMGL_JAVA);
- if (!alt_sym)
+ if (backslash)
+ {
+ /* Remove the preceding backslash. */
+ *(s - 1) = *p;
+ changed = TRUE;
+ }
+ else
+ *s++ = *p;
+
+ backslash = *p == '\\';
+ }
+
+ if (changed)
{
- /* cplus_demangle (also) returns NULL when it is not a Java symbol.
- Should we early out false in this case? */
- result = fnmatch (expr->pattern, sym, 0) == 0;
+ *s = '\0';
+ return symbol;
}
else
{
- result = fnmatch (expr->pattern, alt_sym, 0) == 0;
- free (alt_sym);
+ free (symbol);
+ return pattern;
}
-
- return result;
}
/* This is called for each variable name or match expression. */
struct bfd_elf_version_expr *
-lang_new_vers_pattern (orig, new, lang)
- struct bfd_elf_version_expr *orig;
- const char *new;
- const char *lang;
+lang_new_vers_pattern (struct bfd_elf_version_expr *orig,
+ const char *new,
+ const char *lang)
{
struct bfd_elf_version_expr *ret;
- ret = (struct bfd_elf_version_expr *) xmalloc (sizeof *ret);
+ ret = xmalloc (sizeof *ret);
ret->next = orig;
ret->pattern = new;
ret->symver = 0;
ret->script = 0;
+ ret->symbol = realsymbol (new);
if (lang == NULL || strcasecmp (lang, "C") == 0)
- ret->match = lang_vers_match_lang_c;
+ ret->mask = BFD_ELF_VERSION_C_TYPE;
else if (strcasecmp (lang, "C++") == 0)
- ret->match = lang_vers_match_lang_cplusplus;
+ ret->mask = BFD_ELF_VERSION_CXX_TYPE;
else if (strcasecmp (lang, "Java") == 0)
- ret->match = lang_vers_match_lang_java;
+ ret->mask = BFD_ELF_VERSION_JAVA_TYPE;
else
{
einfo (_("%X%P: unknown language `%s' in version information\n"),
lang);
- ret->match = lang_vers_match_lang_c;
+ ret->mask = BFD_ELF_VERSION_C_TYPE;
}
return ldemul_new_vers_pattern (ret);
@@ -5159,21 +5180,16 @@ lang_new_vers_pattern (orig, new, lang)
expressions. */
struct bfd_elf_version_tree *
-lang_new_vers_node (globals, locals)
- struct bfd_elf_version_expr *globals;
- struct bfd_elf_version_expr *locals;
+lang_new_vers_node (struct bfd_elf_version_expr *globals,
+ struct bfd_elf_version_expr *locals)
{
struct bfd_elf_version_tree *ret;
- ret = (struct bfd_elf_version_tree *) xmalloc (sizeof *ret);
- ret->next = NULL;
- ret->name = NULL;
- ret->vernum = 0;
- ret->globals = globals;
- ret->locals = locals;
- ret->deps = NULL;
+ ret = xcalloc (1, sizeof *ret);
+ ret->globals.list = globals;
+ ret->locals.list = locals;
+ ret->match = lang_vers_match;
ret->name_indx = (unsigned int) -1;
- ret->used = 0;
return ret;
}
@@ -5181,14 +5197,109 @@ lang_new_vers_node (globals, locals)
static int version_index;
+static hashval_t
+version_expr_head_hash (const void *p)
+{
+ const struct bfd_elf_version_expr *e = p;
+
+ return htab_hash_string (e->symbol);
+}
+
+static int
+version_expr_head_eq (const void *p1, const void *p2)
+{
+ const struct bfd_elf_version_expr *e1 = p1;
+ const struct bfd_elf_version_expr *e2 = p2;
+
+ return strcmp (e1->symbol, e2->symbol) == 0;
+}
+
+static void
+lang_finalize_version_expr_head (struct bfd_elf_version_expr_head *head)
+{
+ size_t count = 0;
+ struct bfd_elf_version_expr *e, *next;
+ struct bfd_elf_version_expr **list_loc, **remaining_loc;
+
+ for (e = head->list; e; e = e->next)
+ {
+ if (e->symbol)
+ count++;
+ head->mask |= e->mask;
+ }
+
+ if (count)
+ {
+ head->htab = htab_create (count * 2, version_expr_head_hash,
+ version_expr_head_eq, NULL);
+ list_loc = &head->list;
+ remaining_loc = &head->remaining;
+ for (e = head->list; e; e = next)
+ {
+ next = e->next;
+ if (!e->symbol)
+ {
+ *remaining_loc = e;
+ remaining_loc = &e->next;
+ }
+ else
+ {
+ void **loc = htab_find_slot (head->htab, e, INSERT);
+
+ if (*loc)
+ {
+ struct bfd_elf_version_expr *e1, *last;
+
+ e1 = *loc;
+ last = NULL;
+ do
+ {
+ if (e1->mask == e->mask)
+ {
+ last = NULL;
+ break;
+ }
+ last = e1;
+ e1 = e1->next;
+ }
+ while (e1 && strcmp (e1->symbol, e->symbol) == 0);
+
+ if (last == NULL)
+ {
+ /* This is a duplicate. */
+ /* FIXME: Memory leak. Sometimes pattern is not
+ xmalloced alone, but in larger chunk of memory. */
+ /* free (e->symbol); */
+ free (e);
+ }
+ else
+ {
+ e->next = last->next;
+ last->next = e;
+ }
+ }
+ else
+ {
+ *loc = e;
+ *list_loc = e;
+ list_loc = &e->next;
+ }
+ }
+ }
+ *remaining_loc = NULL;
+ *list_loc = head->remaining;
+ }
+ else
+ head->remaining = head->list;
+}
+
/* This is called when we know the name and dependencies of the
version. */
void
-lang_register_vers_node (name, version, deps)
- const char *name;
- struct bfd_elf_version_tree *version;
- struct bfd_elf_version_deps *deps;
+lang_register_vers_node (const char *name,
+ struct bfd_elf_version_tree *version,
+ struct bfd_elf_version_deps *deps)
{
struct bfd_elf_version_tree *t, **pp;
struct bfd_elf_version_expr *e1;
@@ -5200,6 +5311,7 @@ lang_register_vers_node (name, version, deps)
|| (lang_elf_version_info && lang_elf_version_info->name[0] == '\0'))
{
einfo (_("%X%P: anonymous version tag cannot be combined with other version tags\n"));
+ free (version);
return;
}
@@ -5208,32 +5320,59 @@ lang_register_vers_node (name, version, deps)
if (strcmp (t->name, name) == 0)
einfo (_("%X%P: duplicate version tag `%s'\n"), name);
+ lang_finalize_version_expr_head (&version->globals);
+ lang_finalize_version_expr_head (&version->locals);
+
/* Check the global and local match names, and make sure there
aren't any duplicates. */
- for (e1 = version->globals; e1 != NULL; e1 = e1->next)
+ for (e1 = version->globals.list; e1 != NULL; e1 = e1->next)
{
for (t = lang_elf_version_info; t != NULL; t = t->next)
{
struct bfd_elf_version_expr *e2;
- for (e2 = t->locals; e2 != NULL; e2 = e2->next)
- if (strcmp (e1->pattern, e2->pattern) == 0)
- einfo (_("%X%P: duplicate expression `%s' in version information\n"),
- e1->pattern);
+ if (t->locals.htab && e1->symbol)
+ {
+ e2 = htab_find (t->locals.htab, e1);
+ while (e2 && strcmp (e1->symbol, e2->symbol) == 0)
+ {
+ if (e1->mask == e2->mask)
+ einfo (_("%X%P: duplicate expression `%s' in version information\n"),
+ e1->symbol);
+ e2 = e2->next;
+ }
+ }
+ else if (!e1->symbol)
+ for (e2 = t->locals.remaining; e2 != NULL; e2 = e2->next)
+ if (strcmp (e1->pattern, e2->pattern) == 0 && e1->mask == e2->mask)
+ einfo (_("%X%P: duplicate expression `%s' in version information\n"),
+ e1->pattern);
}
}
- for (e1 = version->locals; e1 != NULL; e1 = e1->next)
+ for (e1 = version->locals.list; e1 != NULL; e1 = e1->next)
{
for (t = lang_elf_version_info; t != NULL; t = t->next)
{
struct bfd_elf_version_expr *e2;
- for (e2 = t->globals; e2 != NULL; e2 = e2->next)
- if (strcmp (e1->pattern, e2->pattern) == 0)
- einfo (_("%X%P: duplicate expression `%s' in version information\n"),
- e1->pattern);
+ if (t->globals.htab && e1->symbol)
+ {
+ e2 = htab_find (t->globals.htab, e1);
+ while (e2 && strcmp (e1->symbol, e2->symbol) == 0)
+ {
+ if (e1->mask == e2->mask)
+ einfo (_("%X%P: duplicate expression `%s' in version information\n"),
+ e1->symbol);
+ e2 = e2->next;
+ }
+ }
+ else if (!e1->symbol)
+ for (e2 = t->globals.remaining; e2 != NULL; e2 = e2->next)
+ if (strcmp (e1->pattern, e2->pattern) == 0 && e1->mask == e2->mask)
+ einfo (_("%X%P: duplicate expression `%s' in version information\n"),
+ e1->pattern);
}
}
@@ -5255,14 +5394,12 @@ lang_register_vers_node (name, version, deps)
/* This is called when we see a version dependency. */
struct bfd_elf_version_deps *
-lang_add_vers_depend (list, name)
- struct bfd_elf_version_deps *list;
- const char *name;
+lang_add_vers_depend (struct bfd_elf_version_deps *list, const char *name)
{
struct bfd_elf_version_deps *ret;
struct bfd_elf_version_tree *t;
- ret = (struct bfd_elf_version_deps *) xmalloc (sizeof *ret);
+ ret = xmalloc (sizeof *ret);
ret->next = list;
for (t = lang_elf_version_info; t != NULL; t = t->next)
@@ -5280,7 +5417,7 @@ lang_add_vers_depend (list, name)
}
static void
-lang_do_version_exports_section ()
+lang_do_version_exports_section (void)
{
struct bfd_elf_version_expr *greg = NULL, *lreg;
@@ -5318,8 +5455,7 @@ lang_do_version_exports_section ()
}
void
-lang_add_unique (name)
- const char *name;
+lang_add_unique (const char *name)
{
struct unique_sections *ent;
@@ -5327,7 +5463,7 @@ lang_add_unique (name)
if (strcmp (ent->name, name) == 0)
return;
- ent = (struct unique_sections *) xmalloc (sizeof *ent);
+ ent = xmalloc (sizeof *ent);
ent->name = xstrdup (name);
ent->next = unique_section_list;
unique_section_list = ent;
diff --git a/contrib/binutils/ld/ldlang.h b/contrib/binutils/ld/ldlang.h
index 57c8c51..649fea1 100644
--- a/contrib/binutils/ld/ldlang.h
+++ b/contrib/binutils/ld/ldlang.h
@@ -1,6 +1,6 @@
/* ldlang.h - linker command language support
Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
- 2001, 2002
+ 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
This file is part of GLD, the Gnu Linker.
@@ -23,7 +23,10 @@
#ifndef LDLANG_H
#define LDLANG_H
-typedef enum {
+#define DEFAULT_MEMORY_REGION "*default*"
+
+typedef enum
+{
lang_input_file_is_l_enum,
lang_input_file_is_symbols_only_enum,
lang_input_file_is_marker_enum,
@@ -32,17 +35,20 @@ typedef enum {
lang_input_file_is_file_enum
} lang_input_file_enum_type;
-struct _fill_type {
+struct _fill_type
+{
size_t size;
unsigned char data[1];
};
-typedef struct statement_list {
+typedef struct statement_list
+{
union lang_statement_union *head;
union lang_statement_union **tail;
} lang_statement_list_type;
-typedef struct memory_region_struct {
+typedef struct memory_region_struct
+{
char *name;
struct memory_region_struct *next;
bfd_vma origin;
@@ -51,12 +57,14 @@ typedef struct memory_region_struct {
bfd_size_type old_length;
flagword flags;
flagword not_flags;
- boolean had_full_message;
+ bfd_boolean had_full_message;
} lang_memory_region_type;
-typedef struct lang_statement_header_struct {
+typedef struct lang_statement_header_struct
+{
union lang_statement_union *next;
- enum statement_enum {
+ enum statement_enum
+ {
lang_output_section_statement_enum,
lang_assignment_statement_enum,
lang_input_statement_enum,
@@ -77,24 +85,28 @@ typedef struct lang_statement_header_struct {
} type;
} lang_statement_header_type;
-typedef struct {
+typedef struct
+{
lang_statement_header_type header;
union etree_union *exp;
} lang_assignment_statement_type;
-typedef struct lang_target_statement_struct {
+typedef struct lang_target_statement_struct
+{
lang_statement_header_type header;
const char *target;
} lang_target_statement_type;
-typedef struct lang_output_statement_struct {
+typedef struct lang_output_statement_struct
+{
lang_statement_header_type header;
const char *name;
} lang_output_statement_type;
/* Section types specified in a linker script. */
-enum section_type {
+enum section_type
+{
normal_section,
dsect_section,
copy_section,
@@ -103,16 +115,18 @@ enum section_type {
overlay_section
};
-/* This structure holds a list of program headers describing segments
- in which this section should be placed. */
+/* This structure holds a list of program headers describing
+ segments in which this section should be placed. */
-struct lang_output_section_phdr_list {
+typedef struct lang_output_section_phdr_list
+{
struct lang_output_section_phdr_list *next;
const char *name;
- boolean used;
-};
+ bfd_boolean used;
+} lang_output_section_phdr_list;
-typedef struct lang_output_section_statement_struct {
+typedef struct lang_output_section_statement_struct
+{
lang_statement_header_type header;
union etree_union *addr_tree;
lang_statement_list_type children;
@@ -120,18 +134,18 @@ typedef struct lang_output_section_statement_struct {
union lang_statement_union *next;
const char *name;
- boolean processed;
+ int processed;
asection *bfd_section;
- flagword flags; /* Or together of all input sections */
+ flagword flags; /* Or together of all input sections. */
enum section_type sectype;
- struct memory_region_struct *region;
- struct memory_region_struct *lma_region;
+ lang_memory_region_type *region;
+ lang_memory_region_type *lma_region;
size_t block_value;
fill_type *fill;
- int subsection_alignment; /* alignment of components */
- int section_alignment; /* alignment of start of section */
+ int subsection_alignment; /* Alignment of components. */
+ int section_alignment; /* Alignment of start of section. */
union etree_union *load_base;
@@ -141,25 +155,29 @@ typedef struct lang_output_section_statement_struct {
to move '.' past all the overlaid sections. */
union etree_union *update_dot_tree;
- struct lang_output_section_phdr_list *phdrs;
+ lang_output_section_phdr_list *phdrs;
} lang_output_section_statement_type;
-typedef struct {
+typedef struct
+{
lang_statement_header_type header;
} lang_common_statement_type;
-typedef struct {
+typedef struct
+{
lang_statement_header_type header;
} lang_object_symbols_statement_type;
-typedef struct {
+typedef struct
+{
lang_statement_header_type header;
fill_type *fill;
int size;
asection *output_section;
} lang_fill_statement_type;
-typedef struct {
+typedef struct
+{
lang_statement_header_type header;
unsigned int type;
union etree_union *exp;
@@ -170,7 +188,8 @@ typedef struct {
/* Generate a reloc in the output file. */
-typedef struct {
+typedef struct
+{
lang_statement_header_type header;
/* Reloc to generate. */
@@ -179,12 +198,12 @@ typedef struct {
/* Reloc howto structure. */
reloc_howto_type *howto;
- /* Section to generate reloc against. Exactly one of section and
- name must be NULL. */
+ /* Section to generate reloc against.
+ Exactly one of section and name must be NULL. */
asection *section;
- /* Name of symbol to generate reloc against. Exactly one of section
- and name must be NULL. */
+ /* Name of symbol to generate reloc against.
+ Exactly one of section and name must be NULL. */
const char *name;
/* Expression for addend. */
@@ -200,18 +219,19 @@ typedef struct {
bfd_vma output_vma;
} lang_reloc_statement_type;
-typedef struct lang_input_statement_struct {
+typedef struct lang_input_statement_struct
+{
lang_statement_header_type header;
/* Name of this file. */
const char *filename;
- /* Name to use for the symbol giving address of text start */
- /* Usually the same as filename, but for a file spec'd with -l
- this is the -l switch itself rather than the filename. */
+ /* Name to use for the symbol giving address of text start.
+ Usually the same as filename, but for a file spec'd with
+ -l this is the -l switch itself rather than the filename. */
const char *local_sym_name;
bfd *the_bfd;
- boolean closed;
+ bfd_boolean closed;
file_ptr passive_position;
/* Symbol table of the file. */
@@ -220,66 +240,80 @@ typedef struct lang_input_statement_struct {
/* Point to the next file - whatever it is, wanders up and down
archives */
-
union lang_statement_union *next;
- /* Point to the next file, but skips archive contents */
+
+ /* Point to the next file, but skips archive contents. */
union lang_statement_union *next_real_file;
- boolean is_archive;
+ bfd_boolean is_archive;
/* 1 means search a set of directories for this file. */
- boolean search_dirs_flag;
+ bfd_boolean search_dirs_flag;
+
+ /* 1 means this was found in a search directory marked as sysrooted,
+ if search_dirs_flag is false, otherwise, that it should be
+ searched in ld_sysroot before any other location, as long as it
+ starts with a slash. */
+ bfd_boolean sysrooted;
/* 1 means this is base file of incremental load.
Do not load this file's text or data.
Also default text_start to after this file's bss. */
-
- boolean just_syms_flag;
+ bfd_boolean just_syms_flag;
/* Whether to search for this entry as a dynamic archive. */
- boolean dynamic;
+ bfd_boolean dynamic;
+
+ /* Whether this entry should cause a DT_NEEDED tag only when
+ satisfying references from regular files, or always. */
+ bfd_boolean as_needed;
/* Whether to include the entire contents of an archive. */
- boolean whole_archive;
+ bfd_boolean whole_archive;
- boolean loaded;
+ bfd_boolean loaded;
#if 0
unsigned int globals_in_this_file;
#endif
const char *target;
- boolean real;
+ bfd_boolean real;
} lang_input_statement_type;
-typedef struct {
+typedef struct
+{
lang_statement_header_type header;
asection *section;
lang_input_statement_type *ifile;
} lang_input_section_type;
-typedef struct {
+typedef struct
+{
lang_statement_header_type header;
asection *section;
union lang_statement_union *file;
} lang_afile_asection_pair_statement_type;
-typedef struct lang_wild_statement_struct {
+typedef struct lang_wild_statement_struct
+{
lang_statement_header_type header;
const char *filename;
- boolean filenames_sorted;
+ bfd_boolean filenames_sorted;
struct wildcard_list *section_list;
- boolean keep_sections;
+ bfd_boolean keep_sections;
lang_statement_list_type children;
} lang_wild_statement_type;
-typedef struct lang_address_statement_struct {
+typedef struct lang_address_statement_struct
+{
lang_statement_header_type header;
const char *section_name;
union etree_union *address;
} lang_address_statement_type;
-typedef struct {
+typedef struct
+{
lang_statement_header_type header;
bfd_vma output_offset;
size_t size;
@@ -292,12 +326,14 @@ typedef struct {
symbols are found. The effect is to search a group of libraries as
though they were a single library. */
-typedef struct {
+typedef struct
+{
lang_statement_header_type header;
lang_statement_list_type children;
} lang_group_statement_type;
-typedef union lang_statement_union {
+typedef union lang_statement_union
+{
lang_statement_header_type header;
lang_wild_statement_type wild_statement;
lang_data_statement_type data_statement;
@@ -320,12 +356,13 @@ typedef union lang_statement_union {
/* This structure holds information about a program header, from the
PHDRS command in the linker script. */
-struct lang_phdr {
+struct lang_phdr
+{
struct lang_phdr *next;
const char *name;
unsigned long type;
- boolean filehdr;
- boolean phdrs;
+ bfd_boolean filehdr;
+ bfd_boolean phdrs;
etree_type *at;
etree_type *flags;
};
@@ -333,16 +370,18 @@ struct lang_phdr {
/* This structure is used to hold a list of sections which may not
cross reference each other. */
-struct lang_nocrossref {
+typedef struct lang_nocrossref
+{
struct lang_nocrossref *next;
const char *name;
-};
+} lang_nocrossref_type;
/* The list of nocrossref lists. */
-struct lang_nocrossrefs {
+struct lang_nocrossrefs
+{
struct lang_nocrossrefs *next;
- struct lang_nocrossref *list;
+ lang_nocrossref_type *list;
};
extern struct lang_nocrossrefs *nocrossref_list;
@@ -350,139 +389,181 @@ extern struct lang_nocrossrefs *nocrossref_list;
/* This structure is used to hold a list of input section names which
will not match an output section in the linker script. */
-struct unique_sections {
+struct unique_sections
+{
struct unique_sections *next;
const char *name;
};
+/* This structure records symbols for which we need to keep track of
+ definedness for use in the DEFINED () test. */
+
+struct lang_definedness_hash_entry
+{
+ struct bfd_hash_entry root;
+ int iteration;
+};
+
extern struct unique_sections *unique_section_list;
extern lang_output_section_statement_type *abs_output_section;
extern lang_statement_list_type lang_output_section_statement;
-extern boolean lang_has_input_file;
+extern bfd_boolean lang_has_input_file;
extern etree_type *base;
extern lang_statement_list_type *stat_ptr;
-extern boolean delete_output_file_on_failure;
+extern bfd_boolean delete_output_file_on_failure;
extern struct bfd_sym_chain entry_symbol;
extern const char *entry_section;
-extern boolean entry_from_cmdline;
+extern bfd_boolean entry_from_cmdline;
extern lang_statement_list_type file_chain;
-extern void lang_init PARAMS ((void));
-extern struct memory_region_struct *lang_memory_region_lookup
- PARAMS ((const char *const));
-extern struct memory_region_struct *lang_memory_region_default
- PARAMS ((asection *));
-extern void lang_map PARAMS ((void));
-extern void lang_set_flags PARAMS ((lang_memory_region_type *, const char *,
- int));
-extern void lang_add_output PARAMS ((const char *, int from_script));
+extern int lang_statement_iteration;
+
+extern void lang_init
+ (void);
+extern lang_memory_region_type *lang_memory_region_lookup
+ (const char *const, bfd_boolean);
+extern lang_memory_region_type *lang_memory_region_default
+ (asection *);
+extern void lang_map
+ (void);
+extern void lang_set_flags
+ (lang_memory_region_type *, const char *, int);
+extern void lang_add_output
+ (const char *, int from_script);
extern lang_output_section_statement_type *lang_enter_output_section_statement
- PARAMS ((const char *output_section_statement_name,
- etree_type * address_exp,
- enum section_type sectype,
- bfd_vma block_value,
- etree_type *align,
- etree_type *subalign,
- etree_type *));
-extern void lang_final PARAMS ((void));
-extern void lang_process PARAMS ((void));
-extern void lang_section_start PARAMS ((const char *, union etree_union *));
-extern void lang_add_entry PARAMS ((const char *, boolean));
-extern void lang_add_target PARAMS ((const char *));
+ (const char *output_section_statement_name,
+ etree_type *address_exp,
+ enum section_type sectype,
+ etree_type *align,
+ etree_type *subalign,
+ etree_type *);
+extern void lang_final
+ (void);
+extern void lang_process
+ (void);
+extern void lang_section_start
+ (const char *, union etree_union *);
+extern void lang_add_entry
+ (const char *, bfd_boolean);
+extern void lang_add_target
+ (const char *);
extern void lang_add_wild
- PARAMS ((struct wildcard_spec *, struct wildcard_list *, boolean));
-extern void lang_add_map PARAMS ((const char *));
-extern void lang_add_fill PARAMS ((fill_type *));
-extern lang_assignment_statement_type * lang_add_assignment PARAMS ((union etree_union *));
-extern void lang_add_attribute PARAMS ((enum statement_enum));
-extern void lang_startup PARAMS ((const char *));
-extern void lang_float PARAMS ((enum bfd_boolean));
+ (struct wildcard_spec *, struct wildcard_list *, bfd_boolean);
+extern void lang_add_map
+ (const char *);
+extern void lang_add_fill
+ (fill_type *);
+extern lang_assignment_statement_type *lang_add_assignment
+ (union etree_union *);
+extern void lang_add_attribute
+ (enum statement_enum);
+extern void lang_startup
+ (const char *);
+extern void lang_float
+ (bfd_boolean);
extern void lang_leave_output_section_statement
- PARAMS ((fill_type *, const char *, struct lang_output_section_phdr_list *,
- const char *));
-extern void lang_abs_symbol_at_end_of PARAMS ((const char *, const char *));
-extern void lang_abs_symbol_at_beginning_of PARAMS ((const char *,
- const char *));
-extern void lang_statement_append PARAMS ((struct statement_list *,
- union lang_statement_union *,
- union lang_statement_union **));
+ (fill_type *, const char *, lang_output_section_phdr_list *,
+ const char *);
+extern void lang_abs_symbol_at_end_of
+ (const char *, const char *);
+extern void lang_abs_symbol_at_beginning_of
+ (const char *, const char *);
+extern void lang_statement_append
+ (lang_statement_list_type *, lang_statement_union_type *,
+ lang_statement_union_type **);
extern void lang_for_each_input_file
- PARAMS ((void (*dothis) (lang_input_statement_type *)));
+ (void (*dothis) (lang_input_statement_type *));
extern void lang_for_each_file
- PARAMS ((void (*dothis) (lang_input_statement_type *)));
-extern void lang_reset_memory_regions PARAMS ((void));
-extern bfd_vma lang_do_assignments
- PARAMS ((lang_statement_union_type * s,
- lang_output_section_statement_type *output_section_statement,
- fill_type *fill,
- bfd_vma dot));
-
-#define LANG_FOR_EACH_INPUT_STATEMENT(statement) \
- lang_input_statement_type *statement; \
- for (statement = (lang_input_statement_type *)file_chain.head;\
- statement != (lang_input_statement_type *)NULL; \
- statement = (lang_input_statement_type *)statement->next)\
-
-extern void lang_process PARAMS ((void));
-extern void ldlang_add_file PARAMS ((lang_input_statement_type *));
+ (void (*dothis) (lang_input_statement_type *));
+extern void lang_reset_memory_regions
+ (void);
+extern void lang_do_assignments
+ (lang_statement_union_type *, lang_output_section_statement_type *,
+ fill_type *, bfd_vma);
+
+#define LANG_FOR_EACH_INPUT_STATEMENT(statement) \
+ lang_input_statement_type *statement; \
+ for (statement = (lang_input_statement_type *) file_chain.head; \
+ statement != (lang_input_statement_type *) NULL; \
+ statement = (lang_input_statement_type *) statement->next) \
+
+extern void lang_process
+ (void);
+extern void ldlang_add_file
+ (lang_input_statement_type *);
extern lang_output_section_statement_type *lang_output_section_find
- PARAMS ((const char * const));
+ (const char * const);
extern lang_input_statement_type *lang_add_input_file
- PARAMS ((const char *name, lang_input_file_enum_type file_type,
- const char *target));
-extern void lang_add_keepsyms_file PARAMS ((const char *filename));
+ (const char *, lang_input_file_enum_type, const char *);
+extern void lang_add_keepsyms_file
+ (const char *);
extern lang_output_section_statement_type *
- lang_output_section_statement_lookup PARAMS ((const char * const name));
-extern void ldlang_add_undef PARAMS ((const char *const name));
-extern void lang_add_output_format PARAMS ((const char *, const char *,
- const char *, int from_script));
-extern void lang_list_init PARAMS ((lang_statement_list_type*));
-extern void lang_add_data PARAMS ((int type, union etree_union *));
+ lang_output_section_statement_lookup
+ (const char *const);
+extern void ldlang_add_undef
+ (const char *const);
+extern void lang_add_output_format
+ (const char *, const char *, const char *, int);
+extern void lang_list_init
+ (lang_statement_list_type *);
+extern void lang_add_data
+ (int type, union etree_union *);
extern void lang_add_reloc
- PARAMS ((bfd_reloc_code_real_type reloc, reloc_howto_type *howto,
- asection *section, const char *name, union etree_union *addend));
+ (bfd_reloc_code_real_type, reloc_howto_type *, asection *, const char *,
+ union etree_union *);
extern void lang_for_each_statement
- PARAMS ((void (*func) (lang_statement_union_type *)));
-extern PTR stat_alloc PARAMS ((size_t size));
-extern void dprint_statement PARAMS ((lang_statement_union_type *, int));
+ (void (*) (lang_statement_union_type *));
+extern void *stat_alloc
+ (size_t);
+extern void dprint_statement
+ (lang_statement_union_type *, int);
extern bfd_vma lang_size_sections
- PARAMS ((lang_statement_union_type *s,
- lang_output_section_statement_type *output_section_statement,
- lang_statement_union_type **prev, fill_type *fill,
- bfd_vma dot, boolean *relax));
-extern void lang_enter_group PARAMS ((void));
-extern void lang_leave_group PARAMS ((void));
+ (lang_statement_union_type *, lang_output_section_statement_type *,
+ lang_statement_union_type **, fill_type *, bfd_vma, bfd_boolean *,
+ bfd_boolean);
+extern void lang_enter_group
+ (void);
+extern void lang_leave_group
+ (void);
extern void lang_add_section
- PARAMS ((lang_statement_list_type *ptr, asection *section,
- lang_output_section_statement_type *output,
- lang_input_statement_type *file));
+ (lang_statement_list_type *, asection *,
+ lang_output_section_statement_type *, lang_input_statement_type *);
extern void lang_new_phdr
- PARAMS ((const char *, etree_type *, boolean, boolean, etree_type *,
- etree_type *));
-extern void lang_add_nocrossref PARAMS ((struct lang_nocrossref *));
-extern void lang_enter_overlay PARAMS ((etree_type *));
-extern void lang_enter_overlay_section PARAMS ((const char *));
+ (const char *, etree_type *, bfd_boolean, bfd_boolean, etree_type *,
+ etree_type *);
+extern void lang_add_nocrossref
+ (lang_nocrossref_type *);
+extern void lang_enter_overlay
+ (etree_type *, etree_type *);
+extern void lang_enter_overlay_section
+ (const char *);
extern void lang_leave_overlay_section
- PARAMS ((fill_type *, struct lang_output_section_phdr_list *));
+ (fill_type *, lang_output_section_phdr_list *);
extern void lang_leave_overlay
- PARAMS ((etree_type *, int, fill_type *, const char *,
- struct lang_output_section_phdr_list *, const char *));
+ (etree_type *, int, fill_type *, const char *,
+ lang_output_section_phdr_list *, const char *);
extern struct bfd_elf_version_tree *lang_elf_version_info;
extern struct bfd_elf_version_expr *lang_new_vers_pattern
- PARAMS ((struct bfd_elf_version_expr *, const char *, const char *));
+ (struct bfd_elf_version_expr *, const char *, const char *);
extern struct bfd_elf_version_tree *lang_new_vers_node
- PARAMS ((struct bfd_elf_version_expr *, struct bfd_elf_version_expr *));
+ (struct bfd_elf_version_expr *, struct bfd_elf_version_expr *);
extern struct bfd_elf_version_deps *lang_add_vers_depend
- PARAMS ((struct bfd_elf_version_deps *, const char *));
+ (struct bfd_elf_version_deps *, const char *);
extern void lang_register_vers_node
- PARAMS ((const char *, struct bfd_elf_version_tree *,
- struct bfd_elf_version_deps *));
-boolean unique_section_p PARAMS ((const char *));
-extern void lang_add_unique PARAMS ((const char *));
-extern const char *lang_get_output_target PARAMS ((void));
+ (const char *, struct bfd_elf_version_tree *, struct bfd_elf_version_deps *);
+bfd_boolean unique_section_p
+ (const char *);
+extern void lang_add_unique
+ (const char *);
+extern const char *lang_get_output_target
+ (void);
+extern void lang_track_definedness (const char *);
+extern int lang_symbol_definition_iteration (const char *);
+extern void lang_update_definedness
+ (const char *, struct bfd_link_hash_entry *);
#endif
diff --git a/contrib/binutils/ld/ldlex.h b/contrib/binutils/ld/ldlex.h
index 36f2ad3..f956e9c 100644
--- a/contrib/binutils/ld/ldlex.h
+++ b/contrib/binutils/ld/ldlex.h
@@ -1,5 +1,5 @@
/* ldlex.h -
- Copyright 1991, 1992, 1993, 1994, 1995, 1997, 2000
+ Copyright 1991, 1992, 1993, 1994, 1995, 1997, 2000, 2003
Free Software Foundation, Inc.
This file is part of GLD, the Gnu Linker.
@@ -39,25 +39,25 @@ extern unsigned int lineno;
extern const char *lex_string;
/* In ldlex.l. */
-extern int yylex PARAMS ((void));
-extern void lex_push_file PARAMS ((FILE *, const char *));
-extern void lex_redirect PARAMS ((const char *));
-extern void ldlex_script PARAMS ((void));
-extern void ldlex_mri_script PARAMS ((void));
-extern void ldlex_version_script PARAMS ((void));
-extern void ldlex_version_file PARAMS ((void));
-extern void ldlex_defsym PARAMS ((void));
-extern void ldlex_expression PARAMS ((void));
-extern void ldlex_both PARAMS ((void));
-extern void ldlex_command PARAMS ((void));
-extern void ldlex_popstate PARAMS ((void));
+extern int yylex (void);
+extern void lex_push_file (FILE *, const char *);
+extern void lex_redirect (const char *);
+extern void ldlex_script (void);
+extern void ldlex_mri_script (void);
+extern void ldlex_version_script (void);
+extern void ldlex_version_file (void);
+extern void ldlex_defsym (void);
+extern void ldlex_expression (void);
+extern void ldlex_both (void);
+extern void ldlex_command (void);
+extern void ldlex_popstate (void);
/* In lexsup.c. */
-extern int lex_input PARAMS ((void));
-extern void lex_unput PARAMS ((int));
+extern int lex_input (void);
+extern void lex_unput (int);
#ifndef yywrap
-extern int yywrap PARAMS ((void));
+extern int yywrap (void);
#endif
-extern void parse_args PARAMS ((unsigned, char **));
+extern void parse_args (unsigned, char **);
#endif
diff --git a/contrib/binutils/ld/ldlex.l b/contrib/binutils/ld/ldlex.l
index 5b799c4..aeac817 100644
--- a/contrib/binutils/ld/ldlex.l
+++ b/contrib/binutils/ld/ldlex.l
@@ -1,7 +1,7 @@
%{
/* Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001, 2002 Free Software Foundation, Inc.
+ 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
This file is part of GLD, the Gnu Linker.
@@ -26,7 +26,6 @@ This was written by steve chamberlain
*/
-#include "ansidecl.h"
#include <stdio.h>
#ifdef MPW
@@ -69,7 +68,7 @@ const char *lex_string = NULL;
Otherwise, stack elements 0 through `include_stack_ptr - 1' are valid. */
#undef YY_INPUT
-#define YY_INPUT(buf,result,max_size) yy_input(buf, &result, max_size)
+#define YY_INPUT(buf,result,max_size) yy_input (buf, &result, max_size)
#define MAX_INCLUDE_DEPTH 10
static YY_BUFFER_STATE include_stack[MAX_INCLUDE_DEPTH];
@@ -78,14 +77,11 @@ static unsigned int lineno_stack[MAX_INCLUDE_DEPTH];
static unsigned int include_stack_ptr = 0;
static int vers_node_nesting = 0;
-static YY_BUFFER_STATE yy_create_string_buffer PARAMS ((const char *string,
- size_t size));
-static void yy_input PARAMS ((char *, int *result, int max_size));
+static void yy_input (char *, int *, int);
+static void comment (void);
+static void lex_warn_invalid (char *where, char *what);
-static void comment PARAMS ((void));
-static void lex_warn_invalid PARAMS ((char *where, char *what));
-
-/* STATES
+/* STATES
EXPRESSION definitely in an expression
SCRIPT definitely in a script
BOTH either EXPRESSION or SCRIPT
@@ -99,7 +95,7 @@ static void lex_warn_invalid PARAMS ((char *where, char *what));
/* Some versions of flex want this. */
#ifndef yywrap
-int yywrap () { return 1; }
+int yywrap (void) { return 1; }
#endif
%}
@@ -112,12 +108,12 @@ FILENAMECHAR1 [_a-zA-Z\/\.\\\$\_\~]
SYMBOLCHARN [_a-zA-Z\/\.\\\$\_\~0-9]
FILENAMECHAR [_a-zA-Z0-9\/\.\-\_\+\=\$\:\[\]\\\,\~]
WILDCHAR [_a-zA-Z0-9\/\.\-\_\+\=\$\:\[\]\\\,\~\?\*]
-WHITE [ \t\n\r]+
+WHITE [ \t\n\r]+
NOCFILENAMECHAR [_a-zA-Z0-9\/\.\-\_\+\$\:\[\]\\\~]
V_TAG [.$_a-zA-Z][._a-zA-Z0-9]*
-V_IDENTIFIER [*?.$_a-zA-Z\[\]\-\!\^]([*?.$_a-zA-Z0-9\[\]\-\!\^]|::)*
+V_IDENTIFIER [*?.$_a-zA-Z\[\]\-\!\^\\]([*?.$_a-zA-Z0-9\[\]\-\!\^\\]|::)*
%s SCRIPT
%s EXPRESSION
@@ -144,24 +140,24 @@ V_IDENTIFIER [*?.$_a-zA-Z\[\]\-\!\^]([*?.$_a-zA-Z0-9\[\]\-\!\^]|::)*
}
}
-<BOTH,SCRIPT,EXPRESSION>"/*" { comment(); }
+<BOTH,SCRIPT,EXPRESSION,VERS_START,VERS_NODE,VERS_SCRIPT>"/*" { comment (); }
<DEFSYMEXP>"-" { RTOKEN('-');}
<DEFSYMEXP>"+" { RTOKEN('+');}
-<DEFSYMEXP>{FILENAMECHAR1}{SYMBOLCHARN}* { yylval.name = xstrdup(yytext); return NAME; }
+<DEFSYMEXP>{FILENAMECHAR1}{SYMBOLCHARN}* { yylval.name = xstrdup (yytext); return NAME; }
<DEFSYMEXP>"=" { RTOKEN('='); }
<MRI,EXPRESSION>"$"([0-9A-Fa-f])+ {
- yylval.integer = bfd_scan_vma (yytext+1, 0,16);
- yylval.bigint.str = (char *) 0;
+ yylval.integer = bfd_scan_vma (yytext + 1, 0, 16);
+ yylval.bigint.str = NULL;
return INT;
}
<MRI,EXPRESSION>([0-9A-Fa-f])+(H|h|X|x|B|b|O|o|D|d) {
int ibase ;
- switch (yytext[yyleng-1]) {
- case 'X':
+ switch (yytext[yyleng - 1]) {
+ case 'X':
case 'x':
case 'H':
case 'h':
@@ -180,7 +176,7 @@ V_IDENTIFIER [*?.$_a-zA-Z\[\]\-\!\^]([*?.$_a-zA-Z0-9\[\]\-\!\^]|::)*
}
yylval.integer = bfd_scan_vma (yytext, 0,
ibase);
- yylval.bigint.str = (char *) 0;
+ yylval.bigint.str = NULL;
return INT;
}
<SCRIPT,DEFSYMEXP,MRI,BOTH,EXPRESSION>((("$"|0[xX])([0-9A-Fa-f])+)|(([0-9])+))(M|K|m|k)? {
@@ -193,14 +189,14 @@ V_IDENTIFIER [*?.$_a-zA-Z\[\]\-\!\^]([*?.$_a-zA-Z0-9\[\]\-\!\^]|::)*
ibase = 16;
}
yylval.integer = bfd_scan_vma (s, 0, ibase);
- yylval.bigint.str = (char *) 0;
- if (yytext[yyleng-1] == 'M'
- || yytext[yyleng-1] == 'm')
+ yylval.bigint.str = NULL;
+ if (yytext[yyleng - 1] == 'M'
+ || yytext[yyleng - 1] == 'm')
{
yylval.integer *= 1024 * 1024;
}
- else if (yytext[yyleng-1] == 'K'
- || yytext[yyleng-1]=='k')
+ else if (yytext[yyleng - 1] == 'K'
+ || yytext[yyleng - 1]=='k')
{
yylval.integer *= 1024;
}
@@ -310,6 +306,7 @@ V_IDENTIFIER [*?.$_a-zA-Z\[\]\-\!\^]([*?.$_a-zA-Z0-9\[\]\-\!\^]|::)*
<BOTH,SCRIPT>"INCLUDE" { RTOKEN(INCLUDE);}
<BOTH,SCRIPT>"PHDRS" { RTOKEN (PHDRS); }
<EXPRESSION,BOTH,SCRIPT>"AT" { RTOKEN(AT);}
+<EXPRESSION,BOTH,SCRIPT>"SUBALIGN" { RTOKEN(SUBALIGN);}
<EXPRESSION,BOTH,SCRIPT>"PROVIDE" { RTOKEN(PROVIDE); }
<EXPRESSION,BOTH,SCRIPT>"KEEP" { RTOKEN(KEEP); }
<EXPRESSION,BOTH,SCRIPT>"EXCLUDE_FILE" { RTOKEN(EXCLUDE_FILE); }
@@ -355,13 +352,13 @@ V_IDENTIFIER [*?.$_a-zA-Z\[\]\-\!\^]([*?.$_a-zA-Z0-9\[\]\-\!\^]|::)*
<MRI>{FILENAMECHAR1}{NOCFILENAMECHAR}* {
/* Filename without commas, needed to parse mri stuff */
- yylval.name = xstrdup(yytext);
+ yylval.name = xstrdup (yytext);
return NAME;
}
<BOTH,EXPRESSION>{FILENAMECHAR1}{FILENAMECHAR}* {
- yylval.name = xstrdup(yytext);
+ yylval.name = xstrdup (yytext);
return NAME;
}
<BOTH,EXPRESSION>"-l"{FILENAMECHAR}+ {
@@ -375,12 +372,12 @@ V_IDENTIFIER [*?.$_a-zA-Z\[\]\-\!\^]([*?.$_a-zA-Z0-9\[\]\-\!\^]|::)*
try again. */
if (yytext[0] == '/' && yytext[1] == '*')
{
- yyless(2);
+ yyless (2);
comment ();
}
else
{
- yylval.name = xstrdup(yytext);
+ yylval.name = xstrdup (yytext);
return NAME;
}
}
@@ -388,8 +385,8 @@ V_IDENTIFIER [*?.$_a-zA-Z\[\]\-\!\^]([*?.$_a-zA-Z0-9\[\]\-\!\^]|::)*
<EXPRESSION,BOTH,SCRIPT,VERS_NODE>"\""[^\"]*"\"" {
/* No matter the state, quotes
give what's inside */
- yylval.name = xstrdup(yytext+1);
- yylval.name[yyleng-2] = 0;
+ yylval.name = xstrdup (yytext + 1);
+ yylval.name[yyleng - 2] = 0;
return NAME;
}
<BOTH,SCRIPT,EXPRESSION>"\n" { lineno++;}
@@ -411,7 +408,7 @@ V_IDENTIFIER [*?.$_a-zA-Z\[\]\-\!\^]([*?.$_a-zA-Z0-9\[\]\-\!\^]|::)*
<VERS_START>"{" { BEGIN(VERS_SCRIPT); return *yytext; }
-<VERS_SCRIPT>"{" { BEGIN(VERS_NODE);
+<VERS_SCRIPT>"{" { BEGIN(VERS_NODE);
vers_node_nesting = 0;
return *yytext;
}
@@ -430,14 +427,14 @@ V_IDENTIFIER [*?.$_a-zA-Z\[\]\-\!\^]([*?.$_a-zA-Z0-9\[\]\-\!\^]|::)*
<<EOF>> {
include_stack_ptr--;
-
- if (include_stack_ptr == 0)
+
+ if (include_stack_ptr == 0)
{
- yyterminate();
+ yyterminate ();
}
- else
+ else
{
- yy_switch_to_buffer(include_stack[include_stack_ptr]);
+ yy_switch_to_buffer (include_stack[include_stack_ptr]);
}
ldfile_input_filename = file_name_stack[include_stack_ptr - 1];
@@ -446,9 +443,9 @@ V_IDENTIFIER [*?.$_a-zA-Z\[\]\-\!\^]([*?.$_a-zA-Z0-9\[\]\-\!\^]|::)*
return END;
}
-<SCRIPT,MRI,VERS_START,VERS_SCRIPT,VERS_NODE>. lex_warn_invalid(" in script", yytext);
-<EXPRESSION,DEFSYMEXP,BOTH>. lex_warn_invalid(" in expression", yytext);
-
+<SCRIPT,MRI,VERS_START,VERS_SCRIPT,VERS_NODE>. lex_warn_invalid (" in script", yytext);
+<EXPRESSION,DEFSYMEXP,BOTH>. lex_warn_invalid (" in expression", yytext);
+
%%
@@ -456,13 +453,11 @@ V_IDENTIFIER [*?.$_a-zA-Z\[\]\-\!\^]([*?.$_a-zA-Z0-9\[\]\-\!\^]|::)*
saving the current input info on the include stack. */
void
-lex_push_file (file, name)
- FILE *file;
- const char *name;
+lex_push_file (FILE *file, const char *name)
{
- if (include_stack_ptr >= MAX_INCLUDE_DEPTH)
+ if (include_stack_ptr >= MAX_INCLUDE_DEPTH)
{
- einfo("%F:includes nested too deeply\n");
+ einfo ("%F:includes nested too deeply\n");
}
file_name_stack[include_stack_ptr] = name;
lineno_stack[include_stack_ptr] = lineno;
@@ -471,27 +466,25 @@ lex_push_file (file, name)
include_stack_ptr++;
lineno = 1;
yyin = file;
- yy_switch_to_buffer(yy_create_buffer(yyin, YY_BUF_SIZE));
+ yy_switch_to_buffer (yy_create_buffer (yyin, YY_BUF_SIZE));
}
/* Return a newly created flex input buffer containing STRING,
which is SIZE bytes long. */
-static YY_BUFFER_STATE
-yy_create_string_buffer (string, size)
- const char *string;
- size_t size;
+static YY_BUFFER_STATE
+yy_create_string_buffer (const char *string, size_t size)
{
YY_BUFFER_STATE b;
/* Calls to m-alloc get turned by sed into xm-alloc. */
- b = (YY_BUFFER_STATE) malloc (sizeof (struct yy_buffer_state));
+ b = malloc (sizeof (struct yy_buffer_state));
b->yy_input_file = 0;
b->yy_buf_size = size;
/* yy_ch_buf has to be 2 characters longer than the size given because
we need to put in 2 end-of-buffer characters. */
- b->yy_ch_buf = (char *) malloc ((unsigned) (b->yy_buf_size + 3));
+ b->yy_ch_buf = malloc ((unsigned) (b->yy_buf_size + 3));
b->yy_ch_buf[0] = '\n';
strcpy (b->yy_ch_buf+1, string);
@@ -520,13 +513,12 @@ yy_create_string_buffer (string, size)
on the include stack. */
void
-lex_redirect (string)
- const char *string;
+lex_redirect (const char *string)
{
YY_BUFFER_STATE tmp;
yy_init = 0;
- if (include_stack_ptr >= MAX_INCLUDE_DEPTH)
+ if (include_stack_ptr >= MAX_INCLUDE_DEPTH)
{
einfo("%F: macros nested too deeply\n");
}
@@ -546,56 +538,56 @@ static int state_stack[MAX_INCLUDE_DEPTH * 2];
static int *state_stack_p = state_stack;
void
-ldlex_script ()
+ldlex_script (void)
{
*(state_stack_p)++ = yy_start;
BEGIN (SCRIPT);
}
void
-ldlex_mri_script ()
+ldlex_mri_script (void)
{
*(state_stack_p)++ = yy_start;
BEGIN (MRI);
}
void
-ldlex_version_script ()
+ldlex_version_script (void)
{
*(state_stack_p)++ = yy_start;
BEGIN (VERS_START);
}
void
-ldlex_version_file ()
+ldlex_version_file (void)
{
*(state_stack_p)++ = yy_start;
BEGIN (VERS_SCRIPT);
}
void
-ldlex_defsym ()
+ldlex_defsym (void)
{
*(state_stack_p)++ = yy_start;
BEGIN (DEFSYMEXP);
}
-
+
void
-ldlex_expression ()
+ldlex_expression (void)
{
*(state_stack_p)++ = yy_start;
BEGIN (EXPRESSION);
}
void
-ldlex_both ()
+ldlex_both (void)
{
*(state_stack_p)++ = yy_start;
BEGIN (BOTH);
}
void
-ldlex_popstate ()
+ldlex_popstate (void)
{
yy_start = *(--state_stack_p);
}
@@ -605,18 +597,15 @@ ldlex_popstate ()
either the number of characters read, or 0 to indicate EOF. */
static void
-yy_input (buf, result, max_size)
- char *buf;
- int *result;
- int max_size;
+yy_input (char *buf, int *result, int max_size)
{
- *result = 0;
- if (yy_current_buffer->yy_input_file)
+ *result = 0;
+ if (YY_CURRENT_BUFFER->yy_input_file)
{
if (yyin)
{
- *result = fread ((char *) buf, 1, max_size, yyin);
- if (*result < max_size && ferror (yyin))
+ *result = fread (buf, 1, max_size, yyin);
+ if (*result < max_size && ferror (yyin))
einfo ("%F%P: read in flex scanner failed\n");
}
}
@@ -625,14 +614,14 @@ yy_input (buf, result, max_size)
/* Eat the rest of a C-style comment. */
static void
-comment ()
+comment (void)
{
int c;
while (1)
{
c = input();
- while (c != '*' && c != EOF)
+ while (c != '*' && c != EOF)
{
if (c == '\n')
lineno++;
@@ -663,8 +652,7 @@ comment ()
in context WHERE. */
static void
-lex_warn_invalid (where, what)
- char *where, *what;
+lex_warn_invalid (char *where, char *what)
{
char buf[5];
diff --git a/contrib/binutils/ld/ldmain.c b/contrib/binutils/ld/ldmain.c
index 41d778f..d0e0b12 100644
--- a/contrib/binutils/ld/ldmain.c
+++ b/contrib/binutils/ld/ldmain.c
@@ -1,25 +1,25 @@
/* Main program of GNU linker.
Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
- 2002
+ 2002, 2003, 2004
Free Software Foundation, Inc.
Written by Steve Chamberlain steve@cygnus.com
-This file is part of GLD, the Gnu Linker.
+ This file is part of GLD, the Gnu Linker.
-GLD is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
+ GLD is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
-GLD is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ GLD is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with GLD; see the file COPYING. If not, write to the Free
-Software Foundation, 59 Temple Place - Suite 330, Boston, MA
-02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with GLD; see the file COPYING. If not, write to the Free
+ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA. */
#include "bfd.h"
#include "sysdep.h"
@@ -42,7 +42,7 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
#include "ldemul.h"
#include "ldctor.h"
-/* Somewhere above, sys/stat.h got included . . . . */
+/* Somewhere above, sys/stat.h got included. */
#if !defined(S_ISDIR) && defined(S_IFDIR)
#define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
#endif
@@ -51,14 +51,13 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
#ifdef HAVE_SBRK
#ifdef NEED_DECLARATION_SBRK
-extern PTR sbrk ();
+extern void *sbrk ();
#endif
#endif
-int main PARAMS ((int, char **));
-
-static char *get_emulation PARAMS ((int, char **));
-static void set_scripts_dir PARAMS ((void));
+#ifndef TARGET_SYSTEM_ROOT
+#define TARGET_SYSTEM_ROOT ""
+#endif
/* EXPORTS */
@@ -68,6 +67,13 @@ const char *output_filename = "a.out";
/* Name this program was invoked by. */
char *program_name;
+/* The prefix for system library directories. */
+char *ld_sysroot;
+
+/* The canonical representation of ld_sysroot. */
+char * ld_canon_sysroot;
+int ld_canon_sysroot_len;
+
/* The file that we're creating. */
bfd *output_bfd = 0;
@@ -75,65 +81,67 @@ bfd *output_bfd = 0;
int g_switch_value = 8;
/* Nonzero means print names of input files as processed. */
-boolean trace_files;
+bfd_boolean trace_files;
/* Nonzero means same, but note open failures, too. */
-boolean trace_file_tries;
+bfd_boolean trace_file_tries;
/* Nonzero means version number was printed, so exit successfully
instead of complaining if no input files are given. */
-boolean version_printed;
+bfd_boolean version_printed;
/* Nonzero means link in every member of an archive. */
-boolean whole_archive;
+bfd_boolean whole_archive;
+
+/* Nonzero means create DT_NEEDED entries only if a dynamic library
+ actually satisfies some reference in a regular object. */
+bfd_boolean as_needed;
-/* True if we should demangle symbol names. */
-boolean demangling;
+/* TRUE if we should demangle symbol names. */
+bfd_boolean demangling;
args_type command_line;
ld_config_type config;
-static void remove_output PARAMS ((void));
-static boolean check_for_scripts_dir PARAMS ((char *dir));
-static boolean add_archive_element PARAMS ((struct bfd_link_info *, bfd *,
- const char *));
-static boolean multiple_definition PARAMS ((struct bfd_link_info *,
- const char *,
- bfd *, asection *, bfd_vma,
- bfd *, asection *, bfd_vma));
-static boolean multiple_common PARAMS ((struct bfd_link_info *,
- const char *, bfd *,
- enum bfd_link_hash_type, bfd_vma,
- bfd *, enum bfd_link_hash_type,
- bfd_vma));
-static boolean add_to_set PARAMS ((struct bfd_link_info *,
- struct bfd_link_hash_entry *,
- bfd_reloc_code_real_type,
- bfd *, asection *, bfd_vma));
-static boolean constructor_callback PARAMS ((struct bfd_link_info *,
- boolean constructor,
- const char *name,
- bfd *, asection *, bfd_vma));
-static boolean warning_callback PARAMS ((struct bfd_link_info *,
- const char *, const char *, bfd *,
- asection *, bfd_vma));
-static void warning_find_reloc PARAMS ((bfd *, asection *, PTR));
-static boolean undefined_symbol PARAMS ((struct bfd_link_info *,
- const char *, bfd *,
- asection *, bfd_vma, boolean));
-static boolean reloc_overflow PARAMS ((struct bfd_link_info *, const char *,
- const char *, bfd_vma,
- bfd *, asection *, bfd_vma));
-static boolean reloc_dangerous PARAMS ((struct bfd_link_info *, const char *,
- bfd *, asection *, bfd_vma));
-static boolean unattached_reloc PARAMS ((struct bfd_link_info *,
- const char *, bfd *, asection *,
- bfd_vma));
-static boolean notice PARAMS ((struct bfd_link_info *, const char *,
- bfd *, asection *, bfd_vma));
-
-static struct bfd_link_callbacks link_callbacks = {
+static char *get_emulation
+ (int, char **);
+static void set_scripts_dir
+ (void);
+static bfd_boolean add_archive_element
+ (struct bfd_link_info *, bfd *, const char *);
+static bfd_boolean multiple_definition
+ (struct bfd_link_info *, const char *, bfd *, asection *, bfd_vma,
+ bfd *, asection *, bfd_vma);
+static bfd_boolean multiple_common
+ (struct bfd_link_info *, const char *, bfd *, enum bfd_link_hash_type,
+ bfd_vma, bfd *, enum bfd_link_hash_type, bfd_vma);
+static bfd_boolean add_to_set
+ (struct bfd_link_info *, struct bfd_link_hash_entry *,
+ bfd_reloc_code_real_type, bfd *, asection *, bfd_vma);
+static bfd_boolean constructor_callback
+ (struct bfd_link_info *, bfd_boolean, const char *, bfd *,
+ asection *, bfd_vma);
+static bfd_boolean warning_callback
+ (struct bfd_link_info *, const char *, const char *, bfd *,
+ asection *, bfd_vma);
+static void warning_find_reloc
+ (bfd *, asection *, void *);
+static bfd_boolean undefined_symbol
+ (struct bfd_link_info *, const char *, bfd *, asection *, bfd_vma,
+ bfd_boolean);
+static bfd_boolean reloc_overflow
+ (struct bfd_link_info *, const char *, const char *, bfd_vma,
+ bfd *, asection *, bfd_vma);
+static bfd_boolean reloc_dangerous
+ (struct bfd_link_info *, const char *, bfd *, asection *, bfd_vma);
+static bfd_boolean unattached_reloc
+ (struct bfd_link_info *, const char *, bfd *, asection *, bfd_vma);
+static bfd_boolean notice
+ (struct bfd_link_info *, const char *, bfd *, asection *, bfd_vma);
+
+static struct bfd_link_callbacks link_callbacks =
+{
add_archive_element,
multiple_definition,
multiple_common,
@@ -144,27 +152,26 @@ static struct bfd_link_callbacks link_callbacks = {
reloc_overflow,
reloc_dangerous,
unattached_reloc,
- notice
+ notice,
+ error_handler
};
struct bfd_link_info link_info;
static void
-remove_output ()
+remove_output (void)
{
if (output_filename)
{
- if (output_bfd && output_bfd->iostream)
- fclose ((FILE *) (output_bfd->iostream));
+ if (output_bfd)
+ bfd_cache_close (output_bfd);
if (delete_output_file_on_failure)
unlink (output_filename);
}
}
int
-main (argc, argv)
- int argc;
- char **argv;
+main (int argc, char **argv)
{
char *emulation;
long start_time = get_run_time ();
@@ -189,6 +196,52 @@ main (argc, argv)
xatexit (remove_output);
+#ifdef TARGET_SYSTEM_ROOT_RELOCATABLE
+ ld_sysroot = make_relative_prefix (program_name, BINDIR,
+ TARGET_SYSTEM_ROOT);
+
+ if (ld_sysroot)
+ {
+ struct stat s;
+ int res = stat (ld_sysroot, &s) == 0 && S_ISDIR (s.st_mode);
+
+ if (!res)
+ {
+ free (ld_sysroot);
+ ld_sysroot = NULL;
+ }
+ }
+
+ if (! ld_sysroot)
+ {
+ ld_sysroot = make_relative_prefix (program_name, TOOLBINDIR,
+ TARGET_SYSTEM_ROOT);
+
+ if (ld_sysroot)
+ {
+ struct stat s;
+ int res = stat (ld_sysroot, &s) == 0 && S_ISDIR (s.st_mode);
+
+ if (!res)
+ {
+ free (ld_sysroot);
+ ld_sysroot = NULL;
+ }
+ }
+ }
+
+ if (! ld_sysroot)
+#endif
+ ld_sysroot = TARGET_SYSTEM_ROOT;
+
+ if (ld_sysroot && *ld_sysroot)
+ ld_canon_sysroot = lrealpath (ld_sysroot);
+
+ if (ld_canon_sysroot)
+ ld_canon_sysroot_len = strlen (ld_canon_sysroot);
+ else
+ ld_canon_sysroot_len = -1;
+
/* Set the default BFD target based on the configured target. Doing
this permits the linker to be configured for a particular target,
and linked against a shared BFD library which was configured for
@@ -207,19 +260,20 @@ main (argc, argv)
#endif
/* Initialize the data about options. */
- trace_files = trace_file_tries = version_printed = false;
- whole_archive = false;
- config.build_constructors = true;
- config.dynamic_link = false;
- config.has_shared = false;
+ trace_files = trace_file_tries = version_printed = FALSE;
+ whole_archive = FALSE;
+ config.build_constructors = TRUE;
+ config.dynamic_link = FALSE;
+ config.has_shared = FALSE;
config.split_by_reloc = (unsigned) -1;
config.split_by_file = (bfd_size_type) -1;
- command_line.force_common_definition = false;
- command_line.inhibit_common_definition = false;
+ command_line.force_common_definition = FALSE;
+ command_line.inhibit_common_definition = FALSE;
command_line.interpreter = NULL;
command_line.rpath = NULL;
- command_line.warn_mismatch = true;
- command_line.check_section_addresses = true;
+ command_line.warn_mismatch = TRUE;
+ command_line.check_section_addresses = TRUE;
+ command_line.accept_unknown_input_arch = FALSE;
/* We initialize DEMANGLING based on the environment variable
COLLECT_NO_DEMANGLE. The gcc collect2 program will demangle the
@@ -228,67 +282,72 @@ main (argc, argv)
interface by default. */
demangling = getenv ("COLLECT_NO_DEMANGLE") == NULL;
- link_info.callbacks = &link_callbacks;
- link_info.relocateable = false;
- link_info.emitrelocations = false;
- link_info.shared = false;
- link_info.symbolic = false;
- link_info.export_dynamic = false;
- link_info.static_link = false;
- link_info.traditional_format = false;
- link_info.optimize = false;
- link_info.no_undefined = false;
- link_info.allow_shlib_undefined = false;
- link_info.allow_multiple_definition = false;
- link_info.allow_undefined_version = true;
+ link_info.relocatable = FALSE;
+ link_info.emitrelocations = FALSE;
+ link_info.task_link = FALSE;
+ link_info.shared = FALSE;
+ link_info.pie = FALSE;
+ link_info.executable = FALSE;
+ link_info.symbolic = FALSE;
+ link_info.export_dynamic = FALSE;
+ link_info.static_link = FALSE;
+ link_info.traditional_format = FALSE;
+ link_info.optimize = FALSE;
+ link_info.unresolved_syms_in_objects = RM_NOT_YET_SET;
+ link_info.unresolved_syms_in_shared_libs = RM_NOT_YET_SET;
+ link_info.allow_multiple_definition = FALSE;
+ link_info.allow_undefined_version = TRUE;
+ link_info.keep_memory = TRUE;
+ link_info.notice_all = FALSE;
+ link_info.nocopyreloc = FALSE;
+ link_info.new_dtags = FALSE;
+ link_info.combreloc = TRUE;
+ link_info.eh_frame_hdr = FALSE;
+ link_info.strip_discarded = TRUE;
link_info.strip = strip_none;
link_info.discard = discard_sec_merge;
- link_info.keep_memory = true;
- link_info.input_bfds = NULL;
- link_info.create_object_symbols_section = NULL;
- link_info.gc_sym_list = NULL;
+ link_info.common_skip_ar_aymbols = bfd_link_common_skip_none;
+ link_info.callbacks = &link_callbacks;
link_info.hash = NULL;
link_info.keep_hash = NULL;
- link_info.notice_all = false;
link_info.notice_hash = NULL;
link_info.wrap_hash = NULL;
- link_info.mpc860c0 = 0;
+ link_info.input_bfds = NULL;
+ link_info.create_object_symbols_section = NULL;
+ link_info.gc_sym_list = NULL;
+ link_info.base_file = NULL;
/* SVR4 linkers seem to set DT_INIT and DT_FINI based on magic _init
and _fini symbols. We are compatible. */
link_info.init_function = "_init";
link_info.fini_function = "_fini";
- link_info.new_dtags = false;
- link_info.eh_frame_hdr = false;
- link_info.flags = (bfd_vma) 0;
- link_info.flags_1 = (bfd_vma) 0;
- link_info.pei386_auto_import = false;
link_info.pei386_auto_import = -1;
- link_info.combreloc = true;
+ link_info.pei386_runtime_pseudo_reloc = FALSE;
link_info.spare_dynamic_tags = 5;
+ link_info.flags = 0;
+ link_info.flags_1 = 0;
+ link_info.need_relax_finalize = FALSE;
ldfile_add_arch ("");
- config.make_executable = true;
- force_make_executable = false;
- config.magic_demand_paged = true;
- config.text_read_only = true;
+ config.make_executable = TRUE;
+ force_make_executable = FALSE;
+ config.magic_demand_paged = TRUE;
+ config.text_read_only = TRUE;
emulation = get_emulation (argc, argv);
ldemul_choose_mode (emulation);
default_target = ldemul_choose_target (argc, argv);
lang_init ();
ldemul_before_parse ();
- lang_has_input_file = false;
+ lang_has_input_file = FALSE;
parse_args (argc, argv);
ldemul_set_symbols ();
- if (link_info.relocateable)
+ if (link_info.relocatable)
{
if (command_line.gc_sections)
einfo ("%P%F: --gc-sections and -r may not be used together\n");
- if (link_info.mpc860c0)
- einfo (_("%P%F: -r and --mpc860c0 may not be used together\n"));
else if (command_line.relax)
einfo (_("%P%F: --relax and -r may not be used together\n"));
if (link_info.shared)
@@ -303,10 +362,13 @@ main (argc, argv)
einfo (_("%P%F: -f may not be used without -shared\n"));
}
+ if (! link_info.shared || link_info.pie)
+ link_info.executable = TRUE;
+
/* Treat ld -r -s as ld -r -S -x (i.e., strip all local symbols). I
don't see how else this can be handled, since in this case we
must preserve all externally visible symbols. */
- if (link_info.relocateable && link_info.strip == strip_all)
+ if (link_info.relocatable && link_info.strip == strip_all)
{
link_info.strip = strip_debugger;
if (link_info.discard == discard_sec_merge)
@@ -371,7 +433,7 @@ main (argc, argv)
lang_final ();
- if (lang_has_input_file == false)
+ if (!lang_has_input_file)
{
if (version_printed)
xexit (0);
@@ -379,9 +441,7 @@ main (argc, argv)
}
if (trace_files)
- {
- info_msg (_("%P: mode %s\n"), emulation);
- }
+ info_msg (_("%P: mode %s\n"), emulation);
ldemul_after_parse ();
@@ -407,8 +467,7 @@ main (argc, argv)
/* Print error messages for any missing symbols, for any warning
symbols, and possibly multiple definitions. */
-
- if (link_info.relocateable)
+ if (link_info.relocatable)
output_bfd->flags &= ~EXEC_P;
else
output_bfd->flags |= EXEC_P;
@@ -422,20 +481,16 @@ main (argc, argv)
if (nocrossref_list != NULL)
check_nocrossrefs ();
- /* Even if we're producing relocateable output, some non-fatal errors should
+ /* Even if we're producing relocatable output, some non-fatal errors should
be reported in the exit status. (What non-fatal errors, if any, do we
- want to ignore for relocateable output?) */
-
- if (config.make_executable == false && force_make_executable == false)
+ want to ignore for relocatable output?) */
+ if (!config.make_executable && !force_make_executable)
{
- if (trace_files == true)
- {
- einfo (_("%P: link errors found, deleting executable `%s'\n"),
- output_filename);
- }
+ if (trace_files)
+ einfo (_("%P: link errors found, deleting executable `%s'\n"),
+ output_filename);
/* The file will be removed by remove_output. */
-
xexit (1);
}
else
@@ -446,9 +501,10 @@ main (argc, argv)
/* If the --force-exe-suffix is enabled, and we're making an
executable file and it doesn't end in .exe, copy it to one
which does. */
- if (! link_info.relocateable && command_line.force_exe_suffix)
+ if (! link_info.relocatable && command_line.force_exe_suffix)
{
int len = strlen (output_filename);
+
if (len < 4
|| (strcasecmp (output_filename + len - 4, ".exe") != 0
&& strcasecmp (output_filename + len - 4, ".dll") != 0))
@@ -459,28 +515,29 @@ main (argc, argv)
char *buf = xmalloc (bsize);
int l;
char *dst_name = xmalloc (len + 5);
+
strcpy (dst_name, output_filename);
strcat (dst_name, ".exe");
src = fopen (output_filename, FOPEN_RB);
dst = fopen (dst_name, FOPEN_WB);
if (!src)
- einfo (_("%X%P: unable to open for source of copy `%s'\n"), output_filename);
+ einfo (_("%X%P: unable to open for source of copy `%s'\n"),
+ output_filename);
if (!dst)
- einfo (_("%X%P: unable to open for destination of copy `%s'\n"), dst_name);
+ einfo (_("%X%P: unable to open for destination of copy `%s'\n"),
+ dst_name);
while ((l = fread (buf, 1, bsize, src)) > 0)
{
int done = fwrite (buf, 1, l, dst);
+
if (done != l)
- {
- einfo (_("%P: Error writing file `%s'\n"), dst_name);
- }
+ einfo (_("%P: Error writing file `%s'\n"), dst_name);
}
+
fclose (src);
if (fclose (dst) == EOF)
- {
- einfo (_("%P: Error closing file `%s'\n"), dst_name);
- }
+ einfo (_("%P: Error closing file `%s'\n"), dst_name);
free (dst_name);
free (buf);
}
@@ -492,7 +549,7 @@ main (argc, argv)
if (config.stats)
{
#ifdef HAVE_SBRK
- char *lim = (char *) sbrk (0);
+ char *lim = sbrk (0);
#endif
long run_time = get_run_time () - start_time;
@@ -515,9 +572,7 @@ main (argc, argv)
state that's needed by the lex&yacc argument parser (parse_args). */
static char *
-get_emulation (argc, argv)
- int argc;
- char **argv;
+get_emulation (int argc, char **argv)
{
char *emulation;
int i;
@@ -539,17 +594,17 @@ get_emulation (argc, argv)
i++;
}
else
- {
- einfo (_("%P%F: missing argument to -m\n"));
- }
+ einfo (_("%P%F: missing argument to -m\n"));
}
else if (strcmp (argv[i], "-mips1") == 0
|| strcmp (argv[i], "-mips2") == 0
|| strcmp (argv[i], "-mips3") == 0
+ || strcmp (argv[i], "-mips4") == 0
+ || strcmp (argv[i], "-mips5") == 0
|| strcmp (argv[i], "-mips32") == 0
+ || strcmp (argv[i], "-mips32r2") == 0
|| strcmp (argv[i], "-mips64") == 0
- || strcmp (argv[i], "-mips4") == 0
- || strcmp (argv[i], "-mips5") == 0)
+ || strcmp (argv[i], "-mips64r2") == 0)
{
/* FIXME: The arguments -mips1, -mips2, -mips3, etc. are
passed to the linker by some MIPS compilers. They
@@ -577,27 +632,26 @@ get_emulation (argc, argv)
}
/* If directory DIR contains an "ldscripts" subdirectory,
- add DIR to the library search path and return true,
- else return false. */
+ add DIR to the library search path and return TRUE,
+ else return FALSE. */
-static boolean
-check_for_scripts_dir (dir)
- char *dir;
+static bfd_boolean
+check_for_scripts_dir (char *dir)
{
size_t dirlen;
char *buf;
struct stat s;
- boolean res;
+ bfd_boolean res;
dirlen = strlen (dir);
/* sizeof counts the terminating NUL. */
- buf = (char *) xmalloc (dirlen + sizeof ("/ldscripts"));
+ buf = xmalloc (dirlen + sizeof ("/ldscripts"));
sprintf (buf, "%s/ldscripts", dir);
res = stat (buf, &s) == 0 && S_ISDIR (s.st_mode);
free (buf);
if (res)
- ldfile_add_library_path (dir, false);
+ ldfile_add_library_path (dir, FALSE);
return res;
}
@@ -606,14 +660,36 @@ check_for_scripts_dir (dir)
We look for the "ldscripts" directory in:
SCRIPTDIR (passed from Makefile)
+ (adjusted according to the current location of the binary)
+ SCRIPTDIR (passed from Makefile)
the dir where this program is (for using it from the build tree)
- the dir where this program is/../lib (for installing the tool suite elsewhere) */
+ the dir where this program is/../lib
+ (for installing the tool suite elsewhere). */
static void
-set_scripts_dir ()
+set_scripts_dir (void)
{
char *end, *dir;
size_t dirlen;
+ bfd_boolean found;
+
+ dir = make_relative_prefix (program_name, BINDIR, SCRIPTDIR);
+ if (dir)
+ {
+ found = check_for_scripts_dir (dir);
+ free (dir);
+ if (found)
+ return;
+ }
+
+ dir = make_relative_prefix (program_name, TOOLBINDIR, SCRIPTDIR);
+ if (dir)
+ {
+ found = check_for_scripts_dir (dir);
+ free (dir);
+ if (found)
+ return;
+ }
if (check_for_scripts_dir (SCRIPTDIR))
/* We've been installed normally. */
@@ -625,81 +701,74 @@ set_scripts_dir ()
{
/* We could have \foo\bar, or /foo\bar. */
char *bslash = strrchr (program_name, '\\');
+
if (end == NULL || (bslash != NULL && bslash > end))
end = bslash;
}
#endif
if (end == NULL)
- {
- /* Don't look for ldscripts in the current directory. There is
- too much potential for confusion. */
- return;
- }
+ /* Don't look for ldscripts in the current directory. There is
+ too much potential for confusion. */
+ return;
dirlen = end - program_name;
/* Make a copy of program_name in dir.
Leave room for later "/../lib". */
- dir = (char *) xmalloc (dirlen + 8);
+ dir = xmalloc (dirlen + 8);
strncpy (dir, program_name, dirlen);
dir[dirlen] = '\0';
if (check_for_scripts_dir (dir))
- /* Don't free dir. */
- return;
+ {
+ free (dir);
+ return;
+ }
/* Look for "ldscripts" in <the dir where our binary is>/../lib. */
strcpy (dir + dirlen, "/../lib");
- if (check_for_scripts_dir (dir))
- return;
-
- /* Well, we tried. */
+ check_for_scripts_dir (dir);
free (dir);
}
void
-add_ysym (name)
- const char *name;
+add_ysym (const char *name)
{
- if (link_info.notice_hash == (struct bfd_hash_table *) NULL)
+ if (link_info.notice_hash == NULL)
{
- link_info.notice_hash = ((struct bfd_hash_table *)
- xmalloc (sizeof (struct bfd_hash_table)));
+ link_info.notice_hash = xmalloc (sizeof (struct bfd_hash_table));
if (! bfd_hash_table_init_n (link_info.notice_hash,
bfd_hash_newfunc,
61))
einfo (_("%P%F: bfd_hash_table_init failed: %E\n"));
}
- if (bfd_hash_lookup (link_info.notice_hash, name, true, true)
- == (struct bfd_hash_entry *) NULL)
+ if (bfd_hash_lookup (link_info.notice_hash, name, TRUE, TRUE) == NULL)
einfo (_("%P%F: bfd_hash_lookup failed: %E\n"));
}
/* Record a symbol to be wrapped, from the --wrap option. */
void
-add_wrap (name)
- const char *name;
+add_wrap (const char *name)
{
if (link_info.wrap_hash == NULL)
{
- link_info.wrap_hash = ((struct bfd_hash_table *)
- xmalloc (sizeof (struct bfd_hash_table)));
+ link_info.wrap_hash = xmalloc (sizeof (struct bfd_hash_table));
if (! bfd_hash_table_init_n (link_info.wrap_hash,
bfd_hash_newfunc,
61))
einfo (_("%P%F: bfd_hash_table_init failed: %E\n"));
}
- if (bfd_hash_lookup (link_info.wrap_hash, name, true, true) == NULL)
+
+ if (bfd_hash_lookup (link_info.wrap_hash, name, TRUE, TRUE) == NULL)
einfo (_("%P%F: bfd_hash_lookup failed: %E\n"));
}
/* Handle the -retain-symbols-file option. */
void
-add_keepsyms_file (filename)
- const char *filename;
+add_keepsyms_file (const char *filename)
{
FILE *file;
char *buf;
@@ -710,20 +779,19 @@ add_keepsyms_file (filename)
einfo (_("%X%P: error: duplicate retain-symbols-file\n"));
file = fopen (filename, "r");
- if (file == (FILE *) NULL)
+ if (file == NULL)
{
bfd_set_error (bfd_error_system_call);
einfo ("%X%P: %s: %E\n", filename);
return;
}
- link_info.keep_hash = ((struct bfd_hash_table *)
- xmalloc (sizeof (struct bfd_hash_table)));
+ link_info.keep_hash = xmalloc (sizeof (struct bfd_hash_table));
if (! bfd_hash_table_init (link_info.keep_hash, bfd_hash_newfunc))
einfo (_("%P%F: bfd_hash_table_init failed: %E\n"));
bufsize = 100;
- buf = (char *) xmalloc (bufsize);
+ buf = xmalloc (bufsize);
c = getc (file);
while (c != EOF)
@@ -749,8 +817,7 @@ add_keepsyms_file (filename)
buf[len] = '\0';
- if (bfd_hash_lookup (link_info.keep_hash, buf, true, true)
- == (struct bfd_hash_entry *) NULL)
+ if (bfd_hash_lookup (link_info.keep_hash, buf, TRUE, TRUE) == NULL)
einfo (_("%P%F: bfd_hash_lookup for insertion failed: %E\n"));
}
}
@@ -758,6 +825,7 @@ add_keepsyms_file (filename)
if (link_info.strip != strip_none)
einfo (_("%P: `-retain-symbols-file' overrides `-s' and `-S'\n"));
+ free (buf);
link_info.strip = strip_some;
}
@@ -766,24 +834,22 @@ add_keepsyms_file (filename)
/* This is called when BFD has decided to include an archive member in
a link. */
-static boolean
-add_archive_element (info, abfd, name)
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
- bfd *abfd;
- const char *name;
+static bfd_boolean
+add_archive_element (struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ bfd *abfd,
+ const char *name)
{
lang_input_statement_type *input;
- input = ((lang_input_statement_type *)
- xmalloc (sizeof (lang_input_statement_type)));
+ input = xmalloc (sizeof (lang_input_statement_type));
input->filename = abfd->filename;
input->local_sym_name = abfd->filename;
input->the_bfd = abfd;
input->asymbols = NULL;
input->next = NULL;
- input->just_syms_flag = false;
- input->loaded = false;
- input->search_dirs_flag = false;
+ input->just_syms_flag = FALSE;
+ input->loaded = FALSE;
+ input->search_dirs_flag = FALSE;
/* FIXME: The following fields are not set: header.next,
header.type, closed, passive_position, symbol_count,
@@ -793,14 +859,14 @@ add_archive_element (info, abfd, name)
ldlang_add_file (input);
- if (config.map_file != (FILE *) NULL)
+ if (config.map_file != NULL)
{
- static boolean header_printed;
+ static bfd_boolean header_printed;
struct bfd_link_hash_entry *h;
bfd *from;
int len;
- h = bfd_link_hash_lookup (link_info.hash, name, false, false, true);
+ h = bfd_link_hash_lookup (link_info.hash, name, FALSE, FALSE, TRUE);
if (h == NULL)
from = NULL;
@@ -834,7 +900,7 @@ add_archive_element (info, abfd, name)
sprintf (buf, _("Archive member included because of file (symbol)\n\n"));
minfo ("%s", buf);
- header_printed = true;
+ header_printed = TRUE;
}
if (bfd_my_archive (abfd) == NULL)
@@ -873,22 +939,21 @@ add_archive_element (info, abfd, name)
if (trace_files || trace_file_tries)
info_msg ("%I\n", input);
- return true;
+ return TRUE;
}
/* This is called when BFD has discovered a symbol which is defined
multiple times. */
-static boolean
-multiple_definition (info, name, obfd, osec, oval, nbfd, nsec, nval)
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
- const char *name;
- bfd *obfd;
- asection *osec;
- bfd_vma oval;
- bfd *nbfd;
- asection *nsec;
- bfd_vma nval;
+static bfd_boolean
+multiple_definition (struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ const char *name,
+ bfd *obfd,
+ asection *osec,
+ bfd_vma oval,
+ bfd *nbfd,
+ asection *nsec,
+ bfd_vma nval)
{
/* If either section has the output_section field set to
bfd_abs_section_ptr, it means that the section is being
@@ -901,11 +966,11 @@ multiple_definition (info, name, obfd, osec, oval, nbfd, nsec, nval)
|| (nsec->output_section != NULL
&& ! bfd_is_abs_section (nsec)
&& bfd_is_abs_section (nsec->output_section)))
- return true;
+ return TRUE;
einfo (_("%X%C: multiple definition of `%T'\n"),
nbfd, nsec, nval, name);
- if (obfd != (bfd *) NULL)
+ if (obfd != NULL)
einfo (_("%D: first defined here\n"), obfd, osec, oval);
if (command_line.relax)
@@ -914,7 +979,7 @@ multiple_definition (info, name, obfd, osec, oval, nbfd, nsec, nval)
command_line.relax = 0;
}
- return true;
+ return TRUE;
}
/* This is called when there is a definition of a common symbol, or
@@ -922,19 +987,18 @@ multiple_definition (info, name, obfd, osec, oval, nbfd, nsec, nval)
or when two common symbols are found. We only do something if
-warn-common was used. */
-static boolean
-multiple_common (info, name, obfd, otype, osize, nbfd, ntype, nsize)
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
- const char *name;
- bfd *obfd;
- enum bfd_link_hash_type otype;
- bfd_vma osize;
- bfd *nbfd;
- enum bfd_link_hash_type ntype;
- bfd_vma nsize;
+static bfd_boolean
+multiple_common (struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ const char *name,
+ bfd *obfd,
+ enum bfd_link_hash_type otype,
+ bfd_vma osize,
+ bfd *nbfd,
+ enum bfd_link_hash_type ntype,
+ bfd_vma nsize)
{
if (! config.warn_common)
- return true;
+ return TRUE;
if (ntype == bfd_link_hash_defined
|| ntype == bfd_link_hash_defweak
@@ -981,30 +1045,29 @@ multiple_common (info, name, obfd, otype, osize, nbfd, ntype, nsize)
}
}
- return true;
+ return TRUE;
}
/* This is called when BFD has discovered a set element. H is the
entry in the linker hash table for the set. SECTION and VALUE
represent a value which should be added to the set. */
-static boolean
-add_to_set (info, h, reloc, abfd, section, value)
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
- struct bfd_link_hash_entry *h;
- bfd_reloc_code_real_type reloc;
- bfd *abfd;
- asection *section;
- bfd_vma value;
+static bfd_boolean
+add_to_set (struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ struct bfd_link_hash_entry *h,
+ bfd_reloc_code_real_type reloc,
+ bfd *abfd,
+ asection *section,
+ bfd_vma value)
{
if (config.warn_constructors)
einfo (_("%P: warning: global constructor %s used\n"),
h->root.string);
if (! config.build_constructors)
- return true;
+ return TRUE;
- ldctor_add_set_entry (h, reloc, (const char *) NULL, section, value);
+ ldctor_add_set_entry (h, reloc, NULL, section, value);
if (h->type == bfd_link_hash_new)
{
@@ -1015,7 +1078,7 @@ add_to_set (info, h, reloc, abfd, section, value)
ourselves. */
}
- return true;
+ return TRUE;
}
/* This is called when BFD has discovered a constructor. This is only
@@ -1023,14 +1086,13 @@ add_to_set (info, h, reloc, abfd, section, value)
constructors in some more clever fashion. This is similar to
adding an element to a set, but less general. */
-static boolean
-constructor_callback (info, constructor, name, abfd, section, value)
- struct bfd_link_info *info;
- boolean constructor;
- const char *name;
- bfd *abfd;
- asection *section;
- bfd_vma value;
+static bfd_boolean
+constructor_callback (struct bfd_link_info *info,
+ bfd_boolean constructor,
+ const char *name,
+ bfd *abfd,
+ asection *section,
+ bfd_vma value)
{
char *s;
struct bfd_link_hash_entry *h;
@@ -1040,12 +1102,12 @@ constructor_callback (info, constructor, name, abfd, section, value)
einfo (_("%P: warning: global constructor %s used\n"), name);
if (! config.build_constructors)
- return true;
+ return TRUE;
/* Ensure that BFD_RELOC_CTOR exists now, so that we can give a
useful error message. */
if (bfd_reloc_type_lookup (output_bfd, BFD_RELOC_CTOR) == NULL
- && (link_info.relocateable
+ && (link_info.relocatable
|| bfd_reloc_type_lookup (abfd, BFD_RELOC_CTOR) == NULL))
einfo (_("%P%F: BFD backend error: BFD_RELOC_CTOR unsupported\n"));
@@ -1057,7 +1119,7 @@ constructor_callback (info, constructor, name, abfd, section, value)
else
strcpy (s, "__DTOR_LIST__");
- h = bfd_link_hash_lookup (info->hash, set_name, true, true, true);
+ h = bfd_link_hash_lookup (info->hash, set_name, TRUE, TRUE, TRUE);
if (h == (struct bfd_link_hash_entry *) NULL)
einfo (_("%P%F: bfd_link_hash_lookup failed: %E\n"));
if (h->type == bfd_link_hash_new)
@@ -1070,14 +1132,15 @@ constructor_callback (info, constructor, name, abfd, section, value)
}
ldctor_add_set_entry (h, BFD_RELOC_CTOR, name, section, value);
- return true;
+ return TRUE;
}
/* A structure used by warning_callback to pass information through
bfd_map_over_sections. */
-struct warning_callback_info {
- boolean found;
+struct warning_callback_info
+{
+ bfd_boolean found;
const char *warning;
const char *symbol;
asymbol **asymbols;
@@ -1085,20 +1148,19 @@ struct warning_callback_info {
/* This is called when there is a reference to a warning symbol. */
-static boolean
-warning_callback (info, warning, symbol, abfd, section, address)
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
- const char *warning;
- const char *symbol;
- bfd *abfd;
- asection *section;
- bfd_vma address;
+static bfd_boolean
+warning_callback (struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ const char *warning,
+ const char *symbol,
+ bfd *abfd,
+ asection *section,
+ bfd_vma address)
{
/* This is a hack to support warn_multiple_gp. FIXME: This should
have a cleaner interface, but what? */
if (! config.warn_multiple_gp
&& strcmp (warning, "using multiple gp values") == 0)
- return true;
+ return TRUE;
if (section != NULL)
einfo ("%C: %s\n", abfd, section, address, warning);
@@ -1114,7 +1176,6 @@ warning_callback (info, warning, symbol, abfd, section, address)
/* Look through the relocs to see if we can find a plausible
address. */
-
entry = (lang_input_statement_type *) abfd->usrdata;
if (entry != NULL && entry->asymbols != NULL)
asymbols = entry->asymbols;
@@ -1126,7 +1187,7 @@ warning_callback (info, warning, symbol, abfd, section, address)
symsize = bfd_get_symtab_upper_bound (abfd);
if (symsize < 0)
einfo (_("%B%F: could not read symbols: %E\n"), abfd);
- asymbols = (asymbol **) xmalloc (symsize);
+ asymbols = xmalloc (symsize);
symbol_count = bfd_canonicalize_symtab (abfd, asymbols);
if (symbol_count < 0)
einfo (_("%B%F: could not read symbols: %E\n"), abfd);
@@ -1137,11 +1198,11 @@ warning_callback (info, warning, symbol, abfd, section, address)
}
}
- info.found = false;
+ info.found = FALSE;
info.warning = warning;
info.symbol = symbol;
info.asymbols = asymbols;
- bfd_map_over_sections (abfd, warning_find_reloc, (PTR) &info);
+ bfd_map_over_sections (abfd, warning_find_reloc, &info);
if (! info.found)
einfo ("%B: %s\n", abfd, warning);
@@ -1150,7 +1211,7 @@ warning_callback (info, warning, symbol, abfd, section, address)
free (asymbols);
}
- return true;
+ return TRUE;
}
/* This is called by warning_callback for each section. It checks the
@@ -1159,12 +1220,9 @@ warning_callback (info, warning, symbol, abfd, section, address)
to give an error message with a file and line number. */
static void
-warning_find_reloc (abfd, sec, iarg)
- bfd *abfd;
- asection *sec;
- PTR iarg;
+warning_find_reloc (bfd *abfd, asection *sec, void *iarg)
{
- struct warning_callback_info *info = (struct warning_callback_info *) iarg;
+ struct warning_callback_info *info = iarg;
long relsize;
arelent **relpp;
long relcount;
@@ -1179,7 +1237,7 @@ warning_find_reloc (abfd, sec, iarg)
if (relsize == 0)
return;
- relpp = (arelent **) xmalloc (relsize);
+ relpp = xmalloc (relsize);
relcount = bfd_canonicalize_reloc (abfd, sec, relpp, info->asymbols);
if (relcount < 0)
einfo (_("%B%F: could not read relocs: %E\n"), abfd);
@@ -1196,7 +1254,7 @@ warning_find_reloc (abfd, sec, iarg)
{
/* We found a reloc for the symbol we are looking for. */
einfo ("%C: %s\n", abfd, sec, q->address, info->warning);
- info->found = true;
+ info->found = TRUE;
break;
}
}
@@ -1206,14 +1264,13 @@ warning_find_reloc (abfd, sec, iarg)
/* This is called when an undefined symbol is found. */
-static boolean
-undefined_symbol (info, name, abfd, section, address, fatal)
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
- const char *name;
- bfd *abfd;
- asection *section;
- bfd_vma address;
- boolean fatal ATTRIBUTE_UNUSED;
+static bfd_boolean
+undefined_symbol (struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ const char *name,
+ bfd *abfd,
+ asection *section,
+ bfd_vma address,
+ bfd_boolean error)
{
static char *error_name;
static unsigned int error_count;
@@ -1225,31 +1282,29 @@ undefined_symbol (info, name, abfd, section, address, fatal)
static struct bfd_hash_table *hash;
/* Only warn once about a particular undefined symbol. */
-
if (hash == NULL)
{
- hash = ((struct bfd_hash_table *)
- xmalloc (sizeof (struct bfd_hash_table)));
+ hash = xmalloc (sizeof (struct bfd_hash_table));
if (! bfd_hash_table_init (hash, bfd_hash_newfunc))
einfo (_("%F%P: bfd_hash_table_init failed: %E\n"));
}
- if (bfd_hash_lookup (hash, name, false, false) != NULL)
- return true;
+ if (bfd_hash_lookup (hash, name, FALSE, FALSE) != NULL)
+ return TRUE;
- if (bfd_hash_lookup (hash, name, true, true) == NULL)
+ if (bfd_hash_lookup (hash, name, TRUE, TRUE) == NULL)
einfo (_("%F%P: bfd_hash_lookup failed: %E\n"));
}
/* We never print more than a reasonable number of errors in a row
for a single symbol. */
- if (error_name != (char *) NULL
+ if (error_name != NULL
&& strcmp (name, error_name) == 0)
++error_count;
else
{
error_count = 0;
- if (error_name != (char *) NULL)
+ if (error_name != NULL)
free (error_name);
error_name = xstrdup (name);
}
@@ -1258,107 +1313,143 @@ undefined_symbol (info, name, abfd, section, address, fatal)
{
if (error_count < MAX_ERRORS_IN_A_ROW)
{
- einfo (_("%C: undefined reference to `%T'\n"),
- abfd, section, address, name);
- if (fatal)
- einfo ("%X");
+ if (error)
+ einfo (_("%X%C: undefined reference to `%T'\n"),
+ abfd, section, address, name);
+ else
+ einfo (_("%C: warning: undefined reference to `%T'\n"),
+ abfd, section, address, name);
}
else if (error_count == MAX_ERRORS_IN_A_ROW)
- einfo (_("%D: more undefined references to `%T' follow\n"),
- abfd, section, address, name);
+ {
+ if (error)
+ einfo (_("%X%D: more undefined references to `%T' follow\n"),
+ abfd, section, address, name);
+ else
+ einfo (_("%D: warning: more undefined references to `%T' follow\n"),
+ abfd, section, address, name);
+ }
+ else if (error)
+ einfo ("%X");
}
else
{
if (error_count < MAX_ERRORS_IN_A_ROW)
{
- einfo (_("%B: undefined reference to `%T'\n"),
- abfd, name);
- if (fatal)
- einfo ("%X");
+ if (error)
+ einfo (_("%X%B: undefined reference to `%T'\n"),
+ abfd, name);
+ else
+ einfo (_("%B: warning: undefined reference to `%T'\n"),
+ abfd, name);
}
else if (error_count == MAX_ERRORS_IN_A_ROW)
- einfo (_("%B: more undefined references to `%T' follow\n"),
- abfd, name);
+ {
+ if (error)
+ einfo (_("%X%B: more undefined references to `%T' follow\n"),
+ abfd, name);
+ else
+ einfo (_("%B: warning: more undefined references to `%T' follow\n"),
+ abfd, name);
+ }
+ else if (error)
+ einfo ("%X");
}
- return true;
+ return TRUE;
}
+/* Counter to limit the number of relocation overflow error messages
+ to print. Errors are printed as it is decremented. When it's
+ called and the counter is zero, a final message is printed
+ indicating more relocations were omitted. When it gets to -1, no
+ such errors are printed. If it's initially set to a value less
+ than -1, all such errors will be printed (--verbose does this). */
+
+int overflow_cutoff_limit = 10;
+
/* This is called when a reloc overflows. */
-static boolean
-reloc_overflow (info, name, reloc_name, addend, abfd, section, address)
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
- const char *name;
- const char *reloc_name;
- bfd_vma addend;
- bfd *abfd;
- asection *section;
- bfd_vma address;
+static bfd_boolean
+reloc_overflow (struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ const char *name,
+ const char *reloc_name,
+ bfd_vma addend,
+ bfd *abfd,
+ asection *section,
+ bfd_vma address)
{
- if (abfd == (bfd *) NULL)
+ if (overflow_cutoff_limit == -1)
+ return TRUE;
+
+ if (abfd == NULL)
einfo (_("%P%X: generated"));
else
einfo ("%X%C:", abfd, section, address);
+
+ if (overflow_cutoff_limit >= 0
+ && overflow_cutoff_limit-- == 0)
+ {
+ einfo (_(" additional relocation overflows omitted from the output\n"));
+ return TRUE;
+ }
+
einfo (_(" relocation truncated to fit: %s %T"), reloc_name, name);
if (addend != 0)
einfo ("+%v", addend);
einfo ("\n");
- return true;
+ return TRUE;
}
/* This is called when a dangerous relocation is made. */
-static boolean
-reloc_dangerous (info, message, abfd, section, address)
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
- const char *message;
- bfd *abfd;
- asection *section;
- bfd_vma address;
+static bfd_boolean
+reloc_dangerous (struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ const char *message,
+ bfd *abfd,
+ asection *section,
+ bfd_vma address)
{
- if (abfd == (bfd *) NULL)
+ if (abfd == NULL)
einfo (_("%P%X: generated"));
else
einfo ("%X%C:", abfd, section, address);
einfo (_("dangerous relocation: %s\n"), message);
- return true;
+ return TRUE;
}
/* This is called when a reloc is being generated attached to a symbol
that is not being output. */
-static boolean
-unattached_reloc (info, name, abfd, section, address)
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
- const char *name;
- bfd *abfd;
- asection *section;
- bfd_vma address;
+static bfd_boolean
+unattached_reloc (struct bfd_link_info *info ATTRIBUTE_UNUSED,
+ const char *name,
+ bfd *abfd,
+ asection *section,
+ bfd_vma address)
{
- if (abfd == (bfd *) NULL)
+ if (abfd == NULL)
einfo (_("%P%X: generated"));
else
einfo ("%X%C:", abfd, section, address);
einfo (_(" reloc refers to symbol `%T' which is not being output\n"), name);
- return true;
+ return TRUE;
}
/* This is called if link_info.notice_all is set, or when a symbol in
link_info.notice_hash is found. Symbols are put in notice_hash
using the -y option. */
-static boolean
-notice (info, name, abfd, section, value)
- struct bfd_link_info *info;
- const char *name;
- bfd *abfd;
- asection *section;
- bfd_vma value;
+static bfd_boolean
+notice (struct bfd_link_info *info,
+ const char *name,
+ bfd *abfd,
+ asection *section,
+ bfd_vma value)
{
if (! info->notice_all
|| (info->notice_hash != NULL
- && bfd_hash_lookup (info->notice_hash, name, false, false) != NULL))
+ && bfd_hash_lookup (info->notice_hash, name, FALSE, FALSE) != NULL))
{
if (bfd_is_und_section (section))
einfo ("%B: reference to %s\n", abfd, name);
@@ -1369,5 +1460,5 @@ notice (info, name, abfd, section, value)
if (command_line.cref || nocrossref_list != NULL)
add_cref (name, abfd, section, value);
- return true;
+ return TRUE;
}
diff --git a/contrib/binutils/ld/ldmain.h b/contrib/binutils/ld/ldmain.h
index f5d8b0d..8cab5fe 100644
--- a/contrib/binutils/ld/ldmain.h
+++ b/contrib/binutils/ld/ldmain.h
@@ -1,5 +1,5 @@
/* ldmain.h -
- Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1999
+ Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1999, 2002, 2003, 2004
Free Software Foundation, Inc.
This file is part of GLD, the Gnu Linker.
@@ -23,19 +23,24 @@
#define LDMAIN_H
extern char *program_name;
+extern char *ld_sysroot;
+extern char *ld_canon_sysroot;
+extern int ld_canon_sysroot_len;
extern bfd *output_bfd;
extern char *default_target;
-extern boolean trace_files;
-extern boolean trace_file_tries;
-extern boolean version_printed;
-extern boolean whole_archive;
-extern boolean demangling;
+extern bfd_boolean trace_files;
+extern bfd_boolean trace_file_tries;
+extern bfd_boolean version_printed;
+extern bfd_boolean whole_archive;
+extern bfd_boolean as_needed;
+extern bfd_boolean demangling;
extern int g_switch_value;
extern const char *output_filename;
extern struct bfd_link_info link_info;
+extern int overflow_cutoff_limit;
-extern void add_ysym PARAMS ((const char *));
-extern void add_wrap PARAMS ((const char *));
-extern void add_keepsyms_file PARAMS ((const char *filename));
+extern void add_ysym (const char *);
+extern void add_wrap (const char *);
+extern void add_keepsyms_file (const char *);
#endif
diff --git a/contrib/binutils/ld/ldmisc.c b/contrib/binutils/ld/ldmisc.c
index 7f9746a..def598d 100644
--- a/contrib/binutils/ld/ldmisc.c
+++ b/contrib/binutils/ld/ldmisc.c
@@ -1,37 +1,32 @@
/* ldmisc.c
Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2002
+ 2000, 2002, 2003
Free Software Foundation, Inc.
Written by Steve Chamberlain of Cygnus Support.
-This file is part of GLD, the Gnu Linker.
+ This file is part of GLD, the Gnu Linker.
-GLD is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
+ GLD is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
-GLD is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ GLD is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with GLD; see the file COPYING. If not, write to the Free
-Software Foundation, 59 Temple Place - Suite 330, Boston, MA
-02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with GLD; see the file COPYING. If not, write to the Free
+ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA. */
#include "bfd.h"
+#include "bfdlink.h"
#include "sysdep.h"
#include "libiberty.h"
#include "demangle.h"
-
-#ifdef ANSI_PROTOTYPES
#include <stdarg.h>
-#else
-#include <varargs.h>
-#endif
-
#include "ld.h"
#include "ldmisc.h"
#include "ldexp.h"
@@ -41,8 +36,6 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
#include "ldmain.h"
#include "ldfile.h"
-static void vfinfo PARAMS ((FILE *, const char *, va_list));
-
/*
%% literal %
%F error is fatal
@@ -66,12 +59,9 @@ static void vfinfo PARAMS ((FILE *, const char *, va_list));
*/
static void
-vfinfo (fp, fmt, arg)
- FILE *fp;
- const char *fmt;
- va_list arg;
+vfinfo (FILE *fp, const char *fmt, va_list arg)
{
- boolean fatal = false;
+ bfd_boolean fatal = FALSE;
while (*fmt != '\0')
{
@@ -97,7 +87,7 @@ vfinfo (fp, fmt, arg)
case 'X':
/* no object output, fail return */
- config.make_executable = false;
+ config.make_executable = FALSE;
break;
case 'V':
@@ -125,7 +115,7 @@ vfinfo (fp, fmt, arg)
case 'W':
/* hex bfd_vma with 0x with no leading zeroes taking up
- 8 spaces. */
+ 8 spaces. */
{
char buf[100];
bfd_vma value;
@@ -153,7 +143,7 @@ vfinfo (fp, fmt, arg)
{
const char *name = va_arg (arg, const char *);
- if (name == (const char *) NULL || *name == 0)
+ if (name == NULL || *name == 0)
fprintf (fp, _("no symbol"));
else if (! demangling)
fprintf (fp, "%s", name);
@@ -182,7 +172,7 @@ vfinfo (fp, fmt, arg)
case 'F':
/* Error is fatal. */
- fatal = true;
+ fatal = TRUE;
break;
case 'P':
@@ -236,9 +226,8 @@ vfinfo (fp, fmt, arg)
case 'C':
case 'D':
case 'G':
- /* Clever filename:linenumber with function name if possible,
- or section name as a last resort. The arguments are a BFD,
- a section, and an offset. */
+ /* Clever filename:linenumber with function name if possible.
+ The arguments are a BFD, a section, and an offset. */
{
static bfd *last_bfd;
static char *last_file = NULL;
@@ -251,7 +240,7 @@ vfinfo (fp, fmt, arg)
const char *filename;
const char *functionname;
unsigned int linenumber;
- boolean discard_last;
+ bfd_boolean discard_last;
abfd = va_arg (arg, bfd *);
section = va_arg (arg, asection *);
@@ -269,7 +258,7 @@ vfinfo (fp, fmt, arg)
symsize = bfd_get_symtab_upper_bound (abfd);
if (symsize < 0)
einfo (_("%B%F: could not read symbols\n"), abfd);
- asymbols = (asymbol **) xmalloc (symsize);
+ asymbols = xmalloc (symsize);
symbol_count = bfd_canonicalize_symtab (abfd, asymbols);
if (symbol_count < 0)
einfo (_("%B%F: could not read symbols\n"), abfd);
@@ -280,68 +269,57 @@ vfinfo (fp, fmt, arg)
}
}
- discard_last = true;
+ lfinfo (fp, "%B(%s+0x%v)", abfd, section->name, offset);
+
+ discard_last = TRUE;
if (bfd_find_nearest_line (abfd, section, asymbols, offset,
&filename, &functionname,
&linenumber))
{
- if (functionname != NULL && fmt[-1] == 'G')
- {
- lfinfo (fp, "%B:", abfd);
- if (filename != NULL
- && strcmp (filename, bfd_get_filename (abfd)) != 0)
- fprintf (fp, "%s:", filename);
- lfinfo (fp, "%T", functionname);
- }
- else if (functionname != NULL && fmt[-1] == 'C')
- {
- if (filename == (char *) NULL)
- filename = abfd->filename;
+ bfd_boolean need_colon = TRUE;
+ if (functionname != NULL && fmt[-1] == 'C')
+ {
if (last_bfd == NULL
|| last_file == NULL
|| last_function == NULL
|| last_bfd != abfd
- || strcmp (last_file, filename) != 0
+ || (filename != NULL
+ && strcmp (last_file, filename) != 0)
|| strcmp (last_function, functionname) != 0)
{
- /* We use abfd->filename in this initial line,
- in case filename is a .h file or something
- similarly unhelpful. */
- lfinfo (fp, _("%B: In function `%T':\n"),
- abfd, functionname);
+ lfinfo (fp, _(": In function `%T':\n"),
+ functionname);
+ need_colon = FALSE;
last_bfd = abfd;
if (last_file != NULL)
free (last_file);
- last_file = xstrdup (filename);
+ last_file = NULL;
+ if (filename)
+ last_file = xstrdup (filename);
if (last_function != NULL)
free (last_function);
last_function = xstrdup (functionname);
}
- discard_last = false;
- if (linenumber != 0)
- fprintf (fp, "%s:%u", filename, linenumber);
- else
- lfinfo (fp, "%s(%s+0x%v)", filename, section->name,
- offset);
+ discard_last = FALSE;
}
- else if (filename == NULL
- || strcmp (filename, abfd->filename) == 0)
+
+ if (filename != NULL)
{
- lfinfo (fp, "%B(%s+0x%v)", abfd, section->name,
- offset);
- if (linenumber != 0)
- lfinfo (fp, ":%u", linenumber);
+ if (need_colon)
+ putc (':', fp);
+ fputs (filename, fp);
}
- else if (linenumber != 0)
- lfinfo (fp, "%B:%s:%u", abfd, filename, linenumber);
- else
- lfinfo (fp, "%B(%s+0x%v):%s", abfd, section->name,
- offset, filename);
+
+ if (functionname != NULL && fmt[-1] == 'G')
+ lfinfo (fp, ":%T", functionname);
+ else if (filename != NULL && linenumber != 0)
+ fprintf (fp, ":%u", linenumber);
}
- else
- lfinfo (fp, "%B(%s+0x%v)", abfd, section->name, offset);
+
+ if (asymbols != NULL && entry == NULL)
+ free (asymbols);
if (discard_last)
{
@@ -379,9 +357,9 @@ vfinfo (fp, fmt, arg)
}
if (config.fatal_warnings)
- config.make_executable = false;
+ config.make_executable = FALSE;
- if (fatal == true)
+ if (fatal)
xexit (1);
}
@@ -389,8 +367,7 @@ vfinfo (fp, fmt, arg)
other such chars that would otherwise confuse the demangler. */
char *
-demangle (name)
- const char *name;
+demangle (const char *name)
{
char *res;
const char *p;
@@ -431,34 +408,32 @@ demangle (name)
/* Format info message and print on stdout. */
/* (You would think this should be called just "info", but then you
- would hosed by LynxOS, which defines that name in its libc.) */
+ would be hosed by LynxOS, which defines that name in its libc.) */
void
-info_msg VPARAMS ((const char *fmt, ...))
+info_msg (const char *fmt, ...)
{
- VA_OPEN (arg, fmt);
- VA_FIXEDARG (arg, const char *, fmt);
+ va_list arg;
+ va_start (arg, fmt);
vfinfo (stdout, fmt, arg);
- VA_CLOSE (arg);
+ va_end (arg);
}
/* ('e' for error.) Format info message and print on stderr. */
void
-einfo VPARAMS ((const char *fmt, ...))
+einfo (const char *fmt, ...)
{
- VA_OPEN (arg, fmt);
- VA_FIXEDARG (arg, const char *, fmt);
+ va_list arg;
+ va_start (arg, fmt);
vfinfo (stderr, fmt, arg);
- VA_CLOSE (arg);
+ va_end (arg);
}
void
-info_assert (file, line)
- const char *file;
- unsigned int line;
+info_assert (const char *file, unsigned int line)
{
einfo (_("%F%P: internal error %s %d\n"), file, line);
}
@@ -466,36 +441,35 @@ info_assert (file, line)
/* ('m' for map) Format info message and print on map. */
void
-minfo VPARAMS ((const char *fmt, ...))
+minfo (const char *fmt, ...)
{
- VA_OPEN (arg, fmt);
- VA_FIXEDARG (arg, const char *, fmt);
+ va_list arg;
+ va_start (arg, fmt);
vfinfo (config.map_file, fmt, arg);
- VA_CLOSE (arg);
+ va_end (arg);
}
void
-lfinfo VPARAMS ((FILE *file, const char *fmt, ...))
+lfinfo (FILE *file, const char *fmt, ...)
{
- VA_OPEN (arg, fmt);
- VA_FIXEDARG (arg, FILE *, file);
- VA_FIXEDARG (arg, const char *, fmt);
+ va_list arg;
+ va_start (arg, fmt);
vfinfo (file, fmt, arg);
- VA_CLOSE (arg);
+ va_end (arg);
}
/* Functions to print the link map. */
void
-print_space ()
+print_space (void)
{
fprintf (config.map_file, " ");
}
void
-print_nl ()
+print_nl (void)
{
fprintf (config.map_file, "\n");
}
@@ -504,10 +478,7 @@ print_nl ()
call this function. */
void
-ld_abort (file, line, fn)
- const char *file;
- int line;
- const char *fn;
+ld_abort (const char *file, int line, const char *fn)
{
if (fn != NULL)
einfo (_("%P: internal error: aborting at %s line %d in %s\n"),
@@ -518,3 +489,64 @@ ld_abort (file, line, fn)
einfo (_("%P%F: please report this bug\n"));
xexit (1);
}
+
+bfd_boolean
+error_handler (int id, const char *fmt, ...)
+{
+ va_list arg;
+
+ va_start (arg, fmt);
+
+ switch (id)
+ {
+ default:
+ break;
+
+ /* We can be called with
+
+ error_handler (-LD_DEFINITION_IN_DISCARDED_SECTION, "", 0);
+
+ to make this error non-fatal and
+
+ error_handler (-LD_DEFINITION_IN_DISCARDED_SECTION, "", 1);
+
+ to make this error fatal. */
+ case -LD_DEFINITION_IN_DISCARDED_SECTION:
+ case LD_DEFINITION_IN_DISCARDED_SECTION:
+ {
+ static struct bfd_hash_table *hash;
+ static int fatal = 1;
+ const char *name;
+
+ if (id == -LD_DEFINITION_IN_DISCARDED_SECTION)
+ {
+ fatal = va_arg (arg, int);
+ goto out;
+ }
+
+ name = va_arg (arg, const char *);
+ /* Only warn once about a particular undefined symbol. */
+ if (hash == NULL)
+ {
+ hash = xmalloc (sizeof (struct bfd_hash_table));
+ if (! bfd_hash_table_init (hash, bfd_hash_newfunc))
+ einfo (_("%F%P: bfd_hash_table_init failed: %E\n"));
+ }
+
+ if (bfd_hash_lookup (hash, name, FALSE, FALSE) != NULL)
+ goto out;
+
+ if (bfd_hash_lookup (hash, name, TRUE, TRUE) == NULL)
+ einfo (_("%F%P: bfd_hash_lookup failed: %E\n"));
+
+ if (fatal)
+ config.make_executable = FALSE;
+ }
+ break;
+ }
+ vfinfo (stderr, fmt, arg);
+
+out:
+ va_end (arg);
+ return TRUE;
+}
diff --git a/contrib/binutils/ld/ldmisc.h b/contrib/binutils/ld/ldmisc.h
index aa3f6af..b2812fb 100644
--- a/contrib/binutils/ld/ldmisc.h
+++ b/contrib/binutils/ld/ldmisc.h
@@ -1,5 +1,5 @@
/* ldmisc.h -
- Copyright 1991, 1992, 1993, 1994, 1996, 1997, 2001
+ Copyright 1991, 1992, 1993, 1994, 1996, 1997, 2001, 2003
Free Software Foundation, Inc.
This file is part of GLD, the Gnu Linker.
@@ -22,15 +22,16 @@
#ifndef LDMISC_H
#define LDMISC_H
-extern void einfo PARAMS ((const char *, ...));
-extern void minfo PARAMS ((const char *, ...));
-extern void info_msg PARAMS ((const char *, ...));
-extern void lfinfo PARAMS ((FILE *, const char *, ...));
-extern void info_assert PARAMS ((const char *, unsigned int));
-extern void yyerror PARAMS ((const char *));
-extern PTR xmalloc PARAMS ((size_t));
-extern PTR xrealloc PARAMS ((PTR, size_t));
-extern void xexit PARAMS ((int));
+extern bfd_boolean error_handler (int, const char *, ...);
+extern void einfo (const char *, ...);
+extern void minfo (const char *, ...);
+extern void info_msg (const char *, ...);
+extern void lfinfo (FILE *, const char *, ...);
+extern void info_assert (const char *, unsigned int);
+extern void yyerror (const char *);
+extern void *xmalloc (size_t);
+extern void *xrealloc (void *, size_t);
+extern void xexit (int);
#define ASSERT(x) \
do { if (!(x)) info_assert(__FILE__,__LINE__); } while (0)
@@ -38,8 +39,8 @@ do { if (!(x)) info_assert(__FILE__,__LINE__); } while (0)
#define FAIL() \
do { info_assert(__FILE__,__LINE__); } while (0)
-extern void print_space PARAMS ((void));
-extern void print_nl PARAMS ((void));
-extern char *demangle PARAMS ((const char *));
+extern void print_space (void);
+extern void print_nl (void);
+extern char *demangle (const char *);
#endif
diff --git a/contrib/binutils/ld/ldver.c b/contrib/binutils/ld/ldver.c
index f81884c..710bf90 100644
--- a/contrib/binutils/ld/ldver.c
+++ b/contrib/binutils/ld/ldver.c
@@ -20,6 +20,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include <stdio.h>
#include "bfd.h"
+#include "bfdver.h"
#include "sysdep.h"
#include "ld.h"
@@ -31,8 +32,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "ldmain.h"
void
-ldversion (noisy)
- int noisy;
+ldversion (int noisy)
{
/* Output for noisy == 2 is intended to follow the GNU standards. */
fprintf (stdout, _("GNU ld version %s\n"), BFD_VERSION_STRING);
diff --git a/contrib/binutils/ld/ldver.h b/contrib/binutils/ld/ldver.h
index ef06937..fd840a8 100644
--- a/contrib/binutils/ld/ldver.h
+++ b/contrib/binutils/ld/ldver.h
@@ -1,5 +1,5 @@
/* ldver.h -- Header file for ldver.c.
- Copyright 1991, 1992, 1993, 1996 Free Software Foundation, Inc.
+ Copyright 1991, 1992, 1993, 1996, 2003 Free Software Foundation, Inc.
This file is part of GLD, the Gnu Linker.
@@ -17,4 +17,4 @@ You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-void ldversion PARAMS ((int));
+void ldversion (int);
diff --git a/contrib/binutils/ld/ldver.texi b/contrib/binutils/ld/ldver.texi
new file mode 100644
index 0000000..3610a96
--- /dev/null
+++ b/contrib/binutils/ld/ldver.texi
@@ -0,0 +1 @@
+@set VERSION 2.15
diff --git a/contrib/binutils/ld/ldwrite.c b/contrib/binutils/ld/ldwrite.c
index eb31171..e4bec32 100644
--- a/contrib/binutils/ld/ldwrite.c
+++ b/contrib/binutils/ld/ldwrite.c
@@ -1,5 +1,5 @@
/* ldwrite.c -- write out the linked file
- Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000, 2002
+ Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000, 2002, 2003
Free Software Foundation, Inc.
Written by Steve Chamberlain sac@cygnus.com
@@ -23,6 +23,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "sysdep.h"
#include "bfdlink.h"
#include "libiberty.h"
+#include "safe-ctype.h"
#include "ld.h"
#include "ldexp.h"
@@ -32,15 +33,10 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include <ldgram.h>
#include "ldmain.h"
-static void build_link_order PARAMS ((lang_statement_union_type *));
-static asection *clone_section PARAMS ((bfd *, asection *, const char *, int *));
-static void split_sections PARAMS ((bfd *, struct bfd_link_info *));
-
/* Build link_order structures for the BFD linker. */
static void
-build_link_order (statement)
- lang_statement_union_type *statement;
+build_link_order (lang_statement_union_type *statement)
{
switch (statement->header.type)
{
@@ -49,7 +45,7 @@ build_link_order (statement)
asection *output_section;
struct bfd_link_order *link_order;
bfd_vma value;
- boolean big_endian = false;
+ bfd_boolean big_endian = FALSE;
output_section = statement->data_statement.output_section;
ASSERT (output_section->owner == output_bfd);
@@ -60,7 +56,7 @@ build_link_order (statement)
link_order->type = bfd_data_link_order;
link_order->offset = statement->data_statement.output_vma;
- link_order->u.data.contents = (bfd_byte *) xmalloc (QUAD_SIZE);
+ link_order->u.data.contents = xmalloc (QUAD_SIZE);
value = statement->data_statement.value;
@@ -70,24 +66,24 @@ build_link_order (statement)
endianness are big endian, so we must swap here if the
input file is little endian. */
if (bfd_big_endian (output_bfd))
- big_endian = true;
+ big_endian = TRUE;
else if (bfd_little_endian (output_bfd))
- big_endian = false;
+ big_endian = FALSE;
else
{
- boolean swap;
+ bfd_boolean swap;
- swap = false;
+ swap = FALSE;
if (command_line.endian == ENDIAN_BIG)
- big_endian = true;
+ big_endian = TRUE;
else if (command_line.endian == ENDIAN_LITTLE)
{
- big_endian = false;
- swap = true;
+ big_endian = FALSE;
+ swap = TRUE;
}
else if (command_line.endian == ENDIAN_UNSET)
{
- big_endian = true;
+ big_endian = TRUE;
{
LANG_FOR_EACH_INPUT_STATEMENT (s)
{
@@ -95,8 +91,8 @@ build_link_order (statement)
{
if (bfd_little_endian (s->the_bfd))
{
- big_endian = false;
- swap = true;
+ big_endian = FALSE;
+ swap = TRUE;
}
break;
}
@@ -197,9 +193,7 @@ build_link_order (statement)
link_order->offset = rs->output_vma;
link_order->size = bfd_get_reloc_size (rs->howto);
- link_order->u.reloc.p =
- ((struct bfd_link_order_reloc *)
- xmalloc (sizeof (struct bfd_link_order_reloc)));
+ link_order->u.reloc.p = xmalloc (sizeof (struct bfd_link_order_reloc));
link_order->u.reloc.p->reloc = rs->reloc;
link_order->u.reloc.p->addend = rs->addend_value;
@@ -226,7 +220,7 @@ build_link_order (statement)
case lang_input_section_enum:
/* Create a new link_order in the output section with this
attached */
- if (statement->input_section.ifile->just_syms_flag == false)
+ if (!statement->input_section.ifile->just_syms_flag)
{
asection *i = statement->input_section.section;
asection *output_section = i->output_section;
@@ -292,9 +286,24 @@ build_link_order (statement)
}
}
-/* Call BFD to write out the linked file. */
+/* Return true if NAME is the name of an unsplittable section. These
+ are the stabs strings, dwarf strings. */
-/**********************************************************************/
+static bfd_boolean
+unsplittable_name (const char *name)
+{
+ if (strncmp (name, ".stab", 5) == 0)
+ {
+ /* There are several stab like string sections. We pattern match on
+ ".stab...str" */
+ unsigned len = strlen (name);
+ if (strcmp (&name[len-3], "str") == 0)
+ return TRUE;
+ }
+ else if (strcmp (name, "$GDB_STRINGS$") == 0)
+ return TRUE;
+ return FALSE;
+}
/* Wander around the input sections, make sure that
we'll never try and create an output section with more relocs
@@ -302,31 +311,53 @@ build_link_order (statement)
creating new output sections with all the right bits. */
#define TESTIT 1
static asection *
-clone_section (abfd, s, name, count)
- bfd *abfd;
- asection *s;
- const char *name;
- int *count;
+clone_section (bfd *abfd, asection *s, const char *name, int *count)
{
- char templ[6];
+ char *tname;
char *sname;
+ unsigned int len;
asection *n;
struct bfd_link_hash_entry *h;
- /* Invent a section name from the first five chars of the base
- section name and a digit suffix. */
- strncpy (templ, name, sizeof (templ) - 1);
- templ[sizeof (templ) - 1] = '\0';
- if ((sname = bfd_get_unique_section_name (abfd, templ, count)) == NULL
+ /* Invent a section name from the section name and a dotted numeric
+ suffix. */
+ len = strlen (name);
+ tname = xmalloc (len + 1);
+ memcpy (tname, name, len + 1);
+ /* Remove a dotted number suffix, from a previous split link. */
+ while (len && ISDIGIT (tname[len-1]))
+ len--;
+ if (len > 1 && tname[len-1] == '.')
+ /* It was a dotted number. */
+ tname[len-1] = 0;
+
+ /* We want to use the whole of the original section name for the
+ split name, but coff can be restricted to 8 character names. */
+ if (bfd_family_coff (abfd) && strlen (tname) > 5)
+ {
+ /* Some section names cannot be truncated, as the name is
+ used to locate some other section. */
+ if (strncmp (name, ".stab", 5) == 0
+ || strcmp (name, "$GDB_SYMBOLS$") == 0)
+ {
+ einfo (_ ("%F%P: cannot create split section name for %s\n"), name);
+ /* Silence gcc warnings. einfo exits, so we never reach here. */
+ return NULL;
+ }
+ tname[5] = 0;
+ }
+
+ if ((sname = bfd_get_unique_section_name (abfd, tname, count)) == NULL
|| (n = bfd_make_section_anyway (abfd, sname)) == NULL
|| (h = bfd_link_hash_lookup (link_info.hash,
- sname, true, true, false)) == NULL)
+ sname, TRUE, TRUE, FALSE)) == NULL)
{
einfo (_("%F%P: clone section failed: %E\n"));
/* Silence gcc warnings. einfo exits, so we never reach here. */
return NULL;
}
-
+ free (tname);
+
/* Set up section symbol. */
h->type = bfd_link_hash_defined;
h->u.def.value = 0;
@@ -348,8 +379,7 @@ clone_section (abfd, s, name, count)
#if TESTING
static void
-ds (s)
- asection *s;
+ds (asection *s)
{
struct bfd_link_order *l = s->link_order_head;
printf ("vma %x size %x\n", s->vma, s->_raw_size);
@@ -368,10 +398,7 @@ ds (s)
printf ("\n");
}
-dump (s, a1, a2)
- char *s;
- asection *a1;
- asection *a2;
+dump (char *s, asection *a1, asection *a2)
{
printf ("%s\n", s);
ds (a1);
@@ -379,8 +406,7 @@ dump (s, a1, a2)
}
static void
-sanity_check (abfd)
- bfd *abfd;
+sanity_check (bfd *abfd)
{
asection *s;
for (s = abfd->sections; s; s = s->next)
@@ -403,9 +429,7 @@ sanity_check (abfd)
#endif
static void
-split_sections (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info;
+split_sections (bfd *abfd, struct bfd_link_info *info)
{
asection *original_sec;
int nsecs = abfd->section_count;
@@ -441,7 +465,7 @@ split_sections (abfd, info)
|| info->strip == strip_some)
thislines = sec->lineno_count;
- if (info->relocateable)
+ if (info->relocatable)
thisrelocs = sec->reloc_count;
if (sec->_cooked_size != 0)
@@ -450,7 +474,7 @@ split_sections (abfd, info)
thissize = sec->_raw_size;
}
- else if (info->relocateable
+ else if (info->relocatable
&& (p->type == bfd_section_reloc_link_order
|| p->type == bfd_symbol_reloc_link_order))
thisrelocs++;
@@ -458,7 +482,8 @@ split_sections (abfd, info)
if (l != NULL
&& (thisrelocs + relocs >= config.split_by_reloc
|| thislines + lines >= config.split_by_reloc
- || thissize + sec_size >= config.split_by_file))
+ || (thissize + sec_size >= config.split_by_file))
+ && !unsplittable_name (cursor->name))
{
/* Create a new section and put this link order and the
following link orders into it. */
@@ -524,10 +549,10 @@ split_sections (abfd, info)
sanity_check (abfd);
}
-/**********************************************************************/
+/* Call BFD to write out the linked file. */
void
-ldwrite ()
+ldwrite (void)
{
/* Reset error indicator, which can typically something like invalid
format from opening up the .o files. */
diff --git a/contrib/binutils/ld/ldwrite.h b/contrib/binutils/ld/ldwrite.h
index 68d8b52..13617c0 100644
--- a/contrib/binutils/ld/ldwrite.h
+++ b/contrib/binutils/ld/ldwrite.h
@@ -1,5 +1,5 @@
/* ldwrite.h -
- Copyright 1991, 1992, 1993 Free Software Foundation, Inc.
+ Copyright 1991, 1992, 1993, 2003 Free Software Foundation, Inc.
This file is part of GLD, the Gnu Linker.
@@ -15,6 +15,7 @@
You should have received a copy of the GNU General Public License
along with GLD; see the file COPYING. If not, write to
- the Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ the Free Software Foundation, 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
-void ldwrite PARAMS ((void));
+void ldwrite (void);
diff --git a/contrib/binutils/ld/lexsup.c b/contrib/binutils/ld/lexsup.c
index f0d4c50..b377bd4 100644
--- a/contrib/binutils/ld/lexsup.c
+++ b/contrib/binutils/ld/lexsup.c
@@ -1,24 +1,24 @@
/* Parse options for the GNU linker.
Copyright 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
- 2001, 2002
+ 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
-This file is part of GLD, the Gnu Linker.
+ This file is part of GLD, the Gnu Linker.
-GLD is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2, or (at your option)
-any later version.
+ GLD is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
-GLD is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ GLD is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with GLD; see the file COPYING. If not, write to the Free
-Software Foundation, 59 Temple Place - Suite 330, Boston, MA
-02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with GLD; see the file COPYING. If not, write to the Free
+ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA. */
#include "bfd.h"
#include "sysdep.h"
@@ -53,85 +53,97 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
#define S_ISDIR(m) (((m) & S_IFMT) == S_IFDIR)
#endif
-static int is_num PARAMS ((const char *, int, int, int));
-static void set_default_dirlist PARAMS ((char *dirlist_ptr));
-static void set_section_start PARAMS ((char *sect, char *valstr));
-static void help PARAMS ((void));
+static void set_default_dirlist (char *);
+static void set_section_start (char *, char *);
+static void help (void);
/* Non-zero if we are processing a --defsym from the command line. */
int parsing_defsym = 0;
/* Codes used for the long options with no short synonyms. 150 isn't
special; it's just an arbitrary non-ASCII char value. */
-
-#define OPTION_ASSERT 150
-#define OPTION_CALL_SHARED (OPTION_ASSERT + 1)
-#define OPTION_CREF (OPTION_CALL_SHARED + 1)
-#define OPTION_DEFSYM (OPTION_CREF + 1)
-#define OPTION_DEMANGLE (OPTION_DEFSYM + 1)
-#define OPTION_DYNAMIC_LINKER (OPTION_DEMANGLE + 1)
-#define OPTION_EB (OPTION_DYNAMIC_LINKER + 1)
-#define OPTION_EL (OPTION_EB + 1)
-#define OPTION_EMBEDDED_RELOCS (OPTION_EL + 1)
-#define OPTION_EXPORT_DYNAMIC (OPTION_EMBEDDED_RELOCS + 1)
-#define OPTION_HELP (OPTION_EXPORT_DYNAMIC + 1)
-#define OPTION_IGNORE (OPTION_HELP + 1)
-#define OPTION_MAP (OPTION_IGNORE + 1)
-#define OPTION_NO_DEMANGLE (OPTION_MAP + 1)
-#define OPTION_NO_KEEP_MEMORY (OPTION_NO_DEMANGLE + 1)
-#define OPTION_NO_WARN_MISMATCH (OPTION_NO_KEEP_MEMORY + 1)
-#define OPTION_NOINHIBIT_EXEC (OPTION_NO_WARN_MISMATCH + 1)
-#define OPTION_NON_SHARED (OPTION_NOINHIBIT_EXEC + 1)
-#define OPTION_NO_WHOLE_ARCHIVE (OPTION_NON_SHARED + 1)
-#define OPTION_OFORMAT (OPTION_NO_WHOLE_ARCHIVE + 1)
-#define OPTION_RELAX (OPTION_OFORMAT + 1)
-#define OPTION_RETAIN_SYMBOLS_FILE (OPTION_RELAX + 1)
-#define OPTION_RPATH (OPTION_RETAIN_SYMBOLS_FILE + 1)
-#define OPTION_RPATH_LINK (OPTION_RPATH + 1)
-#define OPTION_SHARED (OPTION_RPATH_LINK + 1)
-#define OPTION_SONAME (OPTION_SHARED + 1)
-#define OPTION_SORT_COMMON (OPTION_SONAME + 1)
-#define OPTION_STATS (OPTION_SORT_COMMON + 1)
-#define OPTION_SYMBOLIC (OPTION_STATS + 1)
-#define OPTION_TASK_LINK (OPTION_SYMBOLIC + 1)
-#define OPTION_TBSS (OPTION_TASK_LINK + 1)
-#define OPTION_TDATA (OPTION_TBSS + 1)
-#define OPTION_TTEXT (OPTION_TDATA + 1)
-#define OPTION_TRADITIONAL_FORMAT (OPTION_TTEXT + 1)
-#define OPTION_UR (OPTION_TRADITIONAL_FORMAT + 1)
-#define OPTION_VERBOSE (OPTION_UR + 1)
-#define OPTION_VERSION (OPTION_VERBOSE + 1)
-#define OPTION_VERSION_SCRIPT (OPTION_VERSION + 1)
-#define OPTION_VERSION_EXPORTS_SECTION (OPTION_VERSION_SCRIPT + 1)
-#define OPTION_WARN_COMMON (OPTION_VERSION_EXPORTS_SECTION + 1)
-#define OPTION_WARN_CONSTRUCTORS (OPTION_WARN_COMMON + 1)
-#define OPTION_WARN_FATAL (OPTION_WARN_CONSTRUCTORS + 1)
-#define OPTION_WARN_MULTIPLE_GP (OPTION_WARN_FATAL + 1)
-#define OPTION_WARN_ONCE (OPTION_WARN_MULTIPLE_GP + 1)
-#define OPTION_WARN_SECTION_ALIGN (OPTION_WARN_ONCE + 1)
-#define OPTION_SPLIT_BY_RELOC (OPTION_WARN_SECTION_ALIGN + 1)
-#define OPTION_SPLIT_BY_FILE (OPTION_SPLIT_BY_RELOC + 1)
-#define OPTION_WHOLE_ARCHIVE (OPTION_SPLIT_BY_FILE + 1)
-#define OPTION_WRAP (OPTION_WHOLE_ARCHIVE + 1)
-#define OPTION_FORCE_EXE_SUFFIX (OPTION_WRAP + 1)
-#define OPTION_GC_SECTIONS (OPTION_FORCE_EXE_SUFFIX + 1)
-#define OPTION_NO_GC_SECTIONS (OPTION_GC_SECTIONS + 1)
-#define OPTION_CHECK_SECTIONS (OPTION_NO_GC_SECTIONS + 1)
-#define OPTION_NO_CHECK_SECTIONS (OPTION_CHECK_SECTIONS + 1)
-#define OPTION_MPC860C0 (OPTION_NO_CHECK_SECTIONS + 1)
-#define OPTION_NO_UNDEFINED (OPTION_MPC860C0 + 1)
-#define OPTION_INIT (OPTION_NO_UNDEFINED + 1)
-#define OPTION_FINI (OPTION_INIT + 1)
-#define OPTION_SECTION_START (OPTION_FINI + 1)
-#define OPTION_UNIQUE (OPTION_SECTION_START + 1)
-#define OPTION_TARGET_HELP (OPTION_UNIQUE + 1)
-#define OPTION_ALLOW_SHLIB_UNDEFINED (OPTION_TARGET_HELP + 1)
-#define OPTION_ALLOW_MULTIPLE_DEFINITION (OPTION_ALLOW_SHLIB_UNDEFINED + 1)
-#define OPTION_NO_UNDEFINED_VERSION (OPTION_ALLOW_MULTIPLE_DEFINITION + 1)
-#define OPTION_DISCARD_NONE (OPTION_NO_UNDEFINED_VERSION + 1)
-#define OPTION_SPARE_DYNAMIC_TAGS (OPTION_DISCARD_NONE + 1)
-#define OPTION_NO_DEFINE_COMMON (OPTION_SPARE_DYNAMIC_TAGS + 1)
-#define OPTION_NOSTDLIB (OPTION_NO_DEFINE_COMMON + 1)
+enum option_values
+{
+ OPTION_ASSERT = 150,
+ OPTION_CALL_SHARED,
+ OPTION_CREF,
+ OPTION_DEFSYM,
+ OPTION_DEMANGLE,
+ OPTION_DYNAMIC_LINKER,
+ OPTION_EB,
+ OPTION_EL,
+ OPTION_EMBEDDED_RELOCS,
+ OPTION_EXPORT_DYNAMIC,
+ OPTION_HELP,
+ OPTION_IGNORE,
+ OPTION_MAP,
+ OPTION_NO_DEMANGLE,
+ OPTION_NO_KEEP_MEMORY,
+ OPTION_NO_WARN_MISMATCH,
+ OPTION_NOINHIBIT_EXEC,
+ OPTION_NON_SHARED,
+ OPTION_NO_WHOLE_ARCHIVE,
+ OPTION_OFORMAT,
+ OPTION_RELAX,
+ OPTION_RETAIN_SYMBOLS_FILE,
+ OPTION_RPATH,
+ OPTION_RPATH_LINK,
+ OPTION_SHARED,
+ OPTION_SONAME,
+ OPTION_SORT_COMMON,
+ OPTION_STATS,
+ OPTION_SYMBOLIC,
+ OPTION_TASK_LINK,
+ OPTION_TBSS,
+ OPTION_TDATA,
+ OPTION_TTEXT,
+ OPTION_TRADITIONAL_FORMAT,
+ OPTION_UR,
+ OPTION_VERBOSE,
+ OPTION_VERSION,
+ OPTION_VERSION_SCRIPT,
+ OPTION_VERSION_EXPORTS_SECTION,
+ OPTION_WARN_COMMON,
+ OPTION_WARN_CONSTRUCTORS,
+ OPTION_WARN_FATAL,
+ OPTION_WARN_MULTIPLE_GP,
+ OPTION_WARN_ONCE,
+ OPTION_WARN_SECTION_ALIGN,
+ OPTION_SPLIT_BY_RELOC,
+ OPTION_SPLIT_BY_FILE ,
+ OPTION_WHOLE_ARCHIVE,
+ OPTION_AS_NEEDED,
+ OPTION_NO_AS_NEEDED,
+ OPTION_WRAP,
+ OPTION_FORCE_EXE_SUFFIX,
+ OPTION_GC_SECTIONS,
+ OPTION_NO_GC_SECTIONS,
+ OPTION_CHECK_SECTIONS,
+ OPTION_NO_CHECK_SECTIONS,
+ OPTION_NO_UNDEFINED,
+ OPTION_INIT,
+ OPTION_FINI,
+ OPTION_SECTION_START,
+ OPTION_UNIQUE,
+ OPTION_TARGET_HELP,
+ OPTION_ALLOW_SHLIB_UNDEFINED,
+ OPTION_NO_ALLOW_SHLIB_UNDEFINED,
+ OPTION_ALLOW_MULTIPLE_DEFINITION,
+ OPTION_NO_UNDEFINED_VERSION,
+ OPTION_DISCARD_NONE,
+ OPTION_SPARE_DYNAMIC_TAGS,
+ OPTION_NO_DEFINE_COMMON,
+ OPTION_NOSTDLIB,
+ OPTION_NO_OMAGIC,
+ OPTION_STRIP_DISCARDED,
+ OPTION_NO_STRIP_DISCARDED,
+ OPTION_ACCEPT_UNKNOWN_INPUT_ARCH,
+ OPTION_NO_ACCEPT_UNKNOWN_INPUT_ARCH,
+ OPTION_PIE,
+ OPTION_UNRESOLVED_SYMBOLS,
+ OPTION_WARN_UNRESOLVED_SYMBOLS,
+ OPTION_ERROR_UNRESOLVED_SYMBOLS
+};
/* The long options. This structure is used for both the option
parsing and the help text. */
@@ -217,6 +229,8 @@ static const struct ld_option ld_options[] =
{ {"omagic", no_argument, NULL, 'N'},
'N', NULL, N_("Do not page align data, do not make text readonly"),
EXACTLY_TWO_DASHES },
+ { {"no-omagic", no_argument, NULL, OPTION_NO_OMAGIC},
+ '\0', NULL, N_("Page align data, make text readonly"), EXACTLY_TWO_DASHES },
{ {"output", required_argument, NULL, 'o'},
'o', N_("FILE"), N_("Set output file name"), EXACTLY_TWO_DASHES },
{ {NULL, required_argument, NULL, '\0'},
@@ -225,8 +239,8 @@ static const struct ld_option ld_options[] =
'\0', NULL, N_("Ignored for SVR4 compatibility"), ONE_DASH },
{ {"emit-relocs", no_argument, NULL, 'q'},
'q', NULL, "Generate relocations in final output", TWO_DASHES },
- { {"relocateable", no_argument, NULL, 'r'},
- 'r', NULL, N_("Generate relocateable output"), TWO_DASHES },
+ { {"relocatable", no_argument, NULL, 'r'},
+ 'r', NULL, N_("Generate relocatable output"), TWO_DASHES },
{ {NULL, no_argument, NULL, '\0'},
'i', NULL, NULL, ONE_DASH },
{ {"just-symbols", required_argument, NULL, 'R'},
@@ -236,6 +250,10 @@ static const struct ld_option ld_options[] =
's', NULL, N_("Strip all symbols"), TWO_DASHES },
{ {"strip-debug", no_argument, NULL, 'S'},
'S', NULL, N_("Strip debugging symbols"), TWO_DASHES },
+ { {"strip-discarded", no_argument, NULL, OPTION_STRIP_DISCARDED},
+ '\0', NULL, N_("Strip symbols in discarded sections"), TWO_DASHES },
+ { {"no-strip-discarded", no_argument, NULL, OPTION_NO_STRIP_DISCARDED},
+ '\0', NULL, N_("Do not strip symbols in discarded sections"), TWO_DASHES },
{ {"trace", no_argument, NULL, 't'},
't', NULL, N_("Trace file opens"), TWO_DASHES },
{ {"script", required_argument, NULL, 'T'},
@@ -264,6 +282,10 @@ static const struct ld_option ld_options[] =
'(', NULL, N_("Start a group"), TWO_DASHES },
{ {"end-group", no_argument, NULL, ')'},
')', NULL, N_("End a group"), TWO_DASHES },
+ { {"accept-unknown-input-arch", no_argument, NULL, OPTION_ACCEPT_UNKNOWN_INPUT_ARCH},
+ '\0', NULL, N_("Accept input files whose architecture cannot be determined"), TWO_DASHES },
+ { {"no-accept-unknown-input-arch", no_argument, NULL, OPTION_NO_ACCEPT_UNKNOWN_INPUT_ARCH},
+ '\0', NULL, N_("Reject input files whose architecture is unknown"), TWO_DASHES },
{ {"assert", required_argument, NULL, OPTION_ASSERT},
'\0', N_("KEYWORD"), N_("Ignored for SunOS compatibility"), ONE_DASH },
{ {"Bdynamic", no_argument, NULL, OPTION_CALL_SHARED},
@@ -318,9 +340,11 @@ static const struct ld_option ld_options[] =
{ {"no-keep-memory", no_argument, NULL, OPTION_NO_KEEP_MEMORY},
'\0', NULL, N_("Use less memory and more disk I/O"), TWO_DASHES },
{ {"no-undefined", no_argument, NULL, OPTION_NO_UNDEFINED},
- '\0', NULL, N_("Allow no undefined symbols"), TWO_DASHES },
+ '\0', NULL, N_("Do not allow unresolved references in object files"), TWO_DASHES },
{ {"allow-shlib-undefined", no_argument, NULL, OPTION_ALLOW_SHLIB_UNDEFINED},
- '\0', NULL, N_("Allow undefined symbols in shared objects"), TWO_DASHES },
+ '\0', NULL, N_("Allow unresolved references in shared libaries"), TWO_DASHES },
+ { {"no-allow-shlib-undefined", no_argument, NULL, OPTION_NO_ALLOW_SHLIB_UNDEFINED},
+ '\0', NULL, N_("Do not allow unresolved references in shared libs"), TWO_DASHES },
{ {"allow-multiple-definition", no_argument, NULL, OPTION_ALLOW_MULTIPLE_DEFINITION},
'\0', NULL, N_("Allow multiple definitions"), TWO_DASHES },
{ {"no-undefined-version", no_argument, NULL, OPTION_NO_UNDEFINED_VERSION},
@@ -352,6 +376,10 @@ static const struct ld_option ld_options[] =
'\0', NULL, N_("Create a shared library"), ONE_DASH },
{ {"Bshareable", no_argument, NULL, OPTION_SHARED }, /* FreeBSD. */
'\0', NULL, NULL, ONE_DASH },
+ { {"pie", no_argument, NULL, OPTION_PIE},
+ '\0', NULL, N_("Create a position independent executable"), ONE_DASH },
+ { {"pic-executable", no_argument, NULL, OPTION_PIE},
+ '\0', NULL, NULL, TWO_DASHES },
{ {"sort-common", no_argument, NULL, OPTION_SORT_COMMON},
'\0', NULL, N_("Sort common symbols by size"), TWO_DASHES },
{ {"sort_common", no_argument, NULL, OPTION_SORT_COMMON},
@@ -378,6 +406,9 @@ static const struct ld_option ld_options[] =
'\0', N_("ADDRESS"), N_("Set address of .data section"), ONE_DASH },
{ {"Ttext", required_argument, NULL, OPTION_TTEXT},
'\0', N_("ADDRESS"), N_("Set address of .text section"), ONE_DASH },
+ { {"unresolved-symbols=<method>", required_argument, NULL, OPTION_UNRESOLVED_SYMBOLS},
+ '\0', NULL, N_("How to handle unresolved symbols. <method> is:\n\t\t\t\tignore-all, report-all, ignore-in-object-files,\n\t\t\t\tignore-in-shared-libs"),
+ TWO_DASHES },
{ {"verbose", no_argument, NULL, OPTION_VERBOSE},
'\0', NULL, N_("Output lots of information during link"), TWO_DASHES },
{ {"dll-verbose", no_argument, NULL, OPTION_VERBOSE}, /* Linux. */
@@ -400,59 +431,41 @@ static const struct ld_option ld_options[] =
{ {"warn-section-align", no_argument, NULL, OPTION_WARN_SECTION_ALIGN},
'\0', NULL, N_("Warn if start of section changes due to alignment"),
TWO_DASHES },
+ { {"warn-unresolved-symbols", no_argument, NULL, OPTION_WARN_UNRESOLVED_SYMBOLS},
+ '\0', NULL, N_("Report unresolved symbols as warnings"), TWO_DASHES },
+ { {"error-unresolved-symbols", no_argument, NULL, OPTION_ERROR_UNRESOLVED_SYMBOLS},
+ '\0', NULL, N_("Report unresolved symbols as errors"), TWO_DASHES },
{ {"fatal-warnings", no_argument, NULL, OPTION_WARN_FATAL},
'\0', NULL, N_("Treat warnings as errors"),
TWO_DASHES },
{ {"whole-archive", no_argument, NULL, OPTION_WHOLE_ARCHIVE},
'\0', NULL, N_("Include all objects from following archives"), TWO_DASHES },
+ { {"as-needed", no_argument, NULL, OPTION_AS_NEEDED},
+ '\0', NULL, N_("Only set DT_NEEDED for following dynamic libs if used"), TWO_DASHES },
+ { {"no-as-needed", no_argument, NULL, OPTION_NO_AS_NEEDED},
+ '\0', NULL, N_("Always set DT_NEEDED for following dynamic libs"), TWO_DASHES },
{ {"wrap", required_argument, NULL, OPTION_WRAP},
- '\0', N_("SYMBOL"), N_("Use wrapper functions for SYMBOL"), TWO_DASHES },
- { {"mpc860c0", optional_argument, NULL, OPTION_MPC860C0},
- '\0', N_("[=WORDS]"), N_("Modify problematic branches in last WORDS (1-10,\n\t\t\t\tdefault 5) words of a page"), TWO_DASHES }
+ '\0', N_("SYMBOL"), N_("Use wrapper functions for SYMBOL"), TWO_DASHES }
};
#define OPTION_COUNT ARRAY_SIZE (ld_options)
-/* Test STRING for containing a string of digits that form a number
- between MIN and MAX. The return value is the number or ERR. */
-
-static int
-is_num (string, min, max, err)
- const char *string;
- int min;
- int max;
- int err;
-{
- int result = 0;
-
- for (; *string; ++string)
- {
- if (! ISDIGIT (*string))
- {
- result = err;
- break;
- }
- result = result * 10 + (*string - '0');
- }
- if (result < min || result > max)
- result = err;
-
- return result;
-}
-
void
-parse_args (argc, argv)
- unsigned argc;
- char **argv;
+parse_args (unsigned argc, char **argv)
{
unsigned i;
int is, il, irl;
int ingroup = 0;
char *default_dirlist = NULL;
- char shortopts[OPTION_COUNT * 3 + 2];
- struct option longopts[OPTION_COUNT + 1];
- struct option really_longopts[OPTION_COUNT + 1];
+ char *shortopts;
+ struct option *longopts;
+ struct option *really_longopts;
int last_optind;
+ enum report_method how_to_report_unresolved_symbols = RM_GENERATE_ERROR;
+
+ shortopts = xmalloc (OPTION_COUNT * 3 + 2);
+ longopts = xmalloc (sizeof (*longopts) * (OPTION_COUNT + 1));
+ really_longopts = xmalloc (sizeof (*really_longopts) * (OPTION_COUNT + 1));
/* Starting the short option string with '-' is for programs that
expect options and other ARGV-elements in any order and that care about
@@ -498,6 +511,8 @@ parse_args (argc, argv)
longopts[il].name = NULL;
really_longopts[irl].name = NULL;
+ ldemul_add_options (is, &shortopts, il, &longopts, irl, &really_longopts);
+
/* The -G option is ambiguous on different platforms. Sometimes it
specifies the largest data size to put into the small data
section. Sometimes it is equivalent to --shared. Unfortunately,
@@ -535,7 +550,7 @@ parse_args (argc, argv)
{
char *n;
- n = (char *) xmalloc (strlen (argv[i]) + 20);
+ n = xmalloc (strlen (argv[i]) + 20);
sprintf (n, "--library=%s", argv[i] + 2);
argv[i] = n;
}
@@ -568,6 +583,9 @@ parse_args (argc, argv)
optc = getopt_long (argc, argv, "-", really_longopts, &longind);
}
+ if (ldemul_handle_option (optc))
+ continue;
+
if (optc == -1)
break;
@@ -579,21 +597,20 @@ parse_args (argc, argv)
einfo (_("%P%F: use the --help option for usage information\n"));
case 1: /* File name. */
- lang_add_input_file (optarg, lang_input_file_is_file_enum,
- (char *) NULL);
+ lang_add_input_file (optarg, lang_input_file_is_file_enum, NULL);
break;
case OPTION_IGNORE:
break;
case 'a':
/* For HP/UX compatibility. Actually -a shared should mean
- ``use only shared libraries'' but, then, we don't
- currently support shared libraries on HP/UX anyhow. */
+ ``use only shared libraries'' but, then, we don't
+ currently support shared libraries on HP/UX anyhow. */
if (strcmp (optarg, "archive") == 0)
- config.dynamic_link = false;
+ config.dynamic_link = FALSE;
else if (strcmp (optarg, "shared") == 0
|| strcmp (optarg, "default") == 0)
- config.dynamic_link = true;
+ config.dynamic_link = TRUE;
else
einfo (_("%P%F: unrecognized -a option `%s'\n"), optarg);
break;
@@ -622,17 +639,17 @@ parse_args (argc, argv)
yyparse ();
break;
case OPTION_CALL_SHARED:
- config.dynamic_link = true;
+ config.dynamic_link = TRUE;
break;
case OPTION_NON_SHARED:
- config.dynamic_link = false;
+ config.dynamic_link = FALSE;
break;
case OPTION_CREF:
- command_line.cref = true;
- link_info.notice_all = true;
+ command_line.cref = TRUE;
+ link_info.notice_all = TRUE;
break;
case 'd':
- command_line.force_common_definition = true;
+ command_line.force_common_definition = TRUE;
break;
case OPTION_DEFSYM:
lex_string = optarg;
@@ -644,7 +661,7 @@ parse_args (argc, argv)
lex_string = NULL;
break;
case OPTION_DEMANGLE:
- demangling = true;
+ demangling = TRUE;
if (optarg != NULL)
{
enum demangling_styles style;
@@ -668,20 +685,19 @@ parse_args (argc, argv)
command_line.endian = ENDIAN_LITTLE;
break;
case OPTION_EMBEDDED_RELOCS:
- command_line.embedded_relocs = true;
+ command_line.embedded_relocs = TRUE;
break;
case OPTION_EXPORT_DYNAMIC:
case 'E': /* HP/UX compatibility. */
- link_info.export_dynamic = true;
+ link_info.export_dynamic = TRUE;
break;
case 'e':
- lang_add_entry (optarg, true);
+ lang_add_entry (optarg, TRUE);
break;
case 'f':
if (command_line.auxiliary_filters == NULL)
{
- command_line.auxiliary_filters =
- (char **) xmalloc (2 * sizeof (char *));
+ command_line.auxiliary_filters = xmalloc (2 * sizeof (char *));
command_line.auxiliary_filters[0] = optarg;
command_line.auxiliary_filters[1] = NULL;
}
@@ -693,9 +709,9 @@ parse_args (argc, argv)
c = 0;
for (p = command_line.auxiliary_filters; *p != NULL; p++)
++c;
- command_line.auxiliary_filters =
- (char **) xrealloc (command_line.auxiliary_filters,
- (c + 2) * sizeof (char *));
+ command_line.auxiliary_filters
+ = xrealloc (command_line.auxiliary_filters,
+ (c + 2) * sizeof (char *));
command_line.auxiliary_filters[c] = optarg;
command_line.auxiliary_filters[c + 1] = NULL;
}
@@ -704,7 +720,7 @@ parse_args (argc, argv)
command_line.filter_shlib = optarg;
break;
case OPTION_FORCE_EXE_SUFFIX:
- command_line.force_exe_suffix = true;
+ command_line.force_exe_suffix = TRUE;
break;
case 'G':
{
@@ -718,18 +734,17 @@ parse_args (argc, argv)
/* Ignore. */
break;
case OPTION_GC_SECTIONS:
- command_line.gc_sections = true;
+ command_line.gc_sections = TRUE;
break;
case OPTION_HELP:
help ();
xexit (0);
break;
case 'L':
- ldfile_add_library_path (optarg, true);
+ ldfile_add_library_path (optarg, TRUE);
break;
case 'l':
- lang_add_input_file (optarg, lang_input_file_is_l_enum,
- (char *) NULL);
+ lang_add_input_file (optarg, lang_input_file_is_l_enum, NULL);
break;
case 'M':
config.map_filename = "-";
@@ -741,49 +756,97 @@ parse_args (argc, argv)
config.map_filename = optarg;
break;
case 'N':
- config.text_read_only = false;
- config.magic_demand_paged = false;
- config.dynamic_link = false;
+ config.text_read_only = FALSE;
+ config.magic_demand_paged = FALSE;
+ config.dynamic_link = FALSE;
+ break;
+ case OPTION_NO_OMAGIC:
+ config.text_read_only = TRUE;
+ config.magic_demand_paged = TRUE;
+ /* NB/ Does not set dynamic_link to TRUE.
+ Use --call-shared or -Bdynamic for this. */
break;
case 'n':
- config.magic_demand_paged = false;
- config.dynamic_link = false;
+ config.magic_demand_paged = FALSE;
+ config.dynamic_link = FALSE;
break;
case OPTION_NO_DEFINE_COMMON:
- command_line.inhibit_common_definition = true;
+ command_line.inhibit_common_definition = TRUE;
break;
case OPTION_NO_DEMANGLE:
- demangling = false;
+ demangling = FALSE;
break;
case OPTION_NO_GC_SECTIONS:
- command_line.gc_sections = false;
+ command_line.gc_sections = FALSE;
break;
case OPTION_NO_KEEP_MEMORY:
- link_info.keep_memory = false;
+ link_info.keep_memory = FALSE;
break;
case OPTION_NO_UNDEFINED:
- link_info.no_undefined = true;
+ link_info.unresolved_syms_in_objects = how_to_report_unresolved_symbols;
break;
case OPTION_ALLOW_SHLIB_UNDEFINED:
- link_info.allow_shlib_undefined = true;
+ link_info.unresolved_syms_in_shared_libs = RM_IGNORE;
break;
+ case OPTION_NO_ALLOW_SHLIB_UNDEFINED:
+ link_info.unresolved_syms_in_shared_libs = how_to_report_unresolved_symbols;
+ break;
+ case OPTION_UNRESOLVED_SYMBOLS:
+ if (strcmp (optarg, "ignore-all") == 0)
+ {
+ link_info.unresolved_syms_in_objects = RM_IGNORE;
+ link_info.unresolved_syms_in_shared_libs = RM_IGNORE;
+ }
+ else if (strcmp (optarg, "report-all") == 0)
+ {
+ link_info.unresolved_syms_in_objects = how_to_report_unresolved_symbols;
+ link_info.unresolved_syms_in_shared_libs = how_to_report_unresolved_symbols;
+ }
+ else if (strcmp (optarg, "ignore-in-object-files") == 0)
+ {
+ link_info.unresolved_syms_in_objects = RM_IGNORE;
+ link_info.unresolved_syms_in_shared_libs = how_to_report_unresolved_symbols;
+ }
+ else if (strcmp (optarg, "ignore-in-shared-libs") == 0)
+ {
+ link_info.unresolved_syms_in_objects = how_to_report_unresolved_symbols;
+ link_info.unresolved_syms_in_shared_libs = RM_IGNORE;
+ }
+ else
+ einfo (_("%P%F: bad --unresolved-symbols option: %s\n"), optarg);
+ break;
+ case OPTION_WARN_UNRESOLVED_SYMBOLS:
+ how_to_report_unresolved_symbols = RM_GENERATE_WARNING;
+ if (link_info.unresolved_syms_in_objects == RM_GENERATE_ERROR)
+ link_info.unresolved_syms_in_objects = RM_GENERATE_WARNING;
+ if (link_info.unresolved_syms_in_shared_libs == RM_GENERATE_ERROR)
+ link_info.unresolved_syms_in_shared_libs = RM_GENERATE_WARNING;
+ break;
+
+ case OPTION_ERROR_UNRESOLVED_SYMBOLS:
+ how_to_report_unresolved_symbols = RM_GENERATE_ERROR;
+ if (link_info.unresolved_syms_in_objects == RM_GENERATE_WARNING)
+ link_info.unresolved_syms_in_objects = RM_GENERATE_ERROR;
+ if (link_info.unresolved_syms_in_shared_libs == RM_GENERATE_WARNING)
+ link_info.unresolved_syms_in_shared_libs = RM_GENERATE_ERROR;
+ break;
case OPTION_ALLOW_MULTIPLE_DEFINITION:
- link_info.allow_multiple_definition = true;
+ link_info.allow_multiple_definition = TRUE;
break;
case OPTION_NO_UNDEFINED_VERSION:
- link_info.allow_undefined_version = false;
+ link_info.allow_undefined_version = FALSE;
break;
case OPTION_NO_WARN_MISMATCH:
- command_line.warn_mismatch = false;
+ command_line.warn_mismatch = FALSE;
break;
case OPTION_NOINHIBIT_EXEC:
- force_make_executable = true;
+ force_make_executable = TRUE;
break;
case OPTION_NOSTDLIB:
- config.only_cmd_line_lib_dirs = true;
+ config.only_cmd_line_lib_dirs = TRUE;
break;
case OPTION_NO_WHOLE_ARCHIVE:
- whole_archive = false;
+ whole_archive = FALSE;
break;
case 'O':
/* FIXME "-O<non-digits> <value>" used to set the address of
@@ -793,16 +856,16 @@ parse_args (argc, argv)
getopt can't handle two args to an option without kludges. */
/* Enable optimizations of output files. */
- link_info.optimize = strtoul (optarg, NULL, 0) ? true : false;
+ link_info.optimize = strtoul (optarg, NULL, 0) ? TRUE : FALSE;
break;
case 'o':
lang_add_output (optarg, 0);
break;
case OPTION_OFORMAT:
- lang_add_output_format (optarg, (char *) NULL, (char *) NULL, 0);
+ lang_add_output_format (optarg, NULL, NULL, 0);
break;
case 'q':
- link_info.emitrelocations = true;
+ link_info.emitrelocations = TRUE;
break;
case 'i':
case 'r':
@@ -817,11 +880,11 @@ parse_args (argc, argv)
and will seg-fault the next time around. */
einfo(_("%P%F: bad -rpath option\n"));
- link_info.relocateable = true;
- config.build_constructors = false;
- config.magic_demand_paged = false;
- config.text_read_only = false;
- config.dynamic_link = false;
+ link_info.relocatable = TRUE;
+ config.build_constructors = FALSE;
+ config.magic_demand_paged = FALSE;
+ config.text_read_only = FALSE;
+ config.dynamic_link = FALSE;
break;
case 'R':
/* The GNU linker traditionally uses -R to mean to include
@@ -839,7 +902,7 @@ parse_args (argc, argv)
{
lang_add_input_file (optarg,
lang_input_file_is_symbols_only_enum,
- (char *) NULL);
+ NULL);
break;
}
}
@@ -898,7 +961,7 @@ parse_args (argc, argv)
}
break;
case OPTION_RELAX:
- command_line.relax = true;
+ command_line.relax = TRUE;
break;
case OPTION_RETAIN_SYMBOLS_FILE:
add_keepsyms_file (optarg);
@@ -909,27 +972,50 @@ parse_args (argc, argv)
case 's':
link_info.strip = strip_all;
break;
+ case OPTION_STRIP_DISCARDED:
+ link_info.strip_discarded = TRUE;
+ break;
+ case OPTION_NO_STRIP_DISCARDED:
+ link_info.strip_discarded = FALSE;
+ break;
case OPTION_SHARED:
if (config.has_shared)
- link_info.shared = true;
+ {
+ link_info.shared = TRUE;
+ /* When creating a shared library, the default
+ behaviour is to ignore any unresolved references. */
+ if (link_info.unresolved_syms_in_objects == RM_NOT_YET_SET)
+ link_info.unresolved_syms_in_objects = RM_IGNORE;
+ if (link_info.unresolved_syms_in_shared_libs == RM_NOT_YET_SET)
+ link_info.unresolved_syms_in_shared_libs = RM_IGNORE;
+ }
else
einfo (_("%P%F: -shared not supported\n"));
break;
+ case OPTION_PIE:
+ if (config.has_shared)
+ {
+ link_info.shared = TRUE;
+ link_info.pie = TRUE;
+ }
+ else
+ einfo (_("%P%F: -pie not supported\n"));
+ break;
case 'h': /* Used on Solaris. */
case OPTION_SONAME:
command_line.soname = optarg;
break;
case OPTION_SORT_COMMON:
- config.sort_common = true;
+ config.sort_common = TRUE;
break;
case OPTION_STATS:
- config.stats = true;
+ config.stats = TRUE;
break;
case OPTION_SYMBOLIC:
- link_info.symbolic = true;
+ link_info.symbolic = TRUE;
break;
case 't':
- trace_files = true;
+ trace_files = TRUE;
break;
case 'T':
ldfile_open_command_file (optarg);
@@ -978,17 +1064,17 @@ parse_args (argc, argv)
set_section_start (".text", optarg);
break;
case OPTION_TRADITIONAL_FORMAT:
- link_info.traditional_format = true;
+ link_info.traditional_format = TRUE;
break;
case OPTION_TASK_LINK:
- link_info.task_link = true;
+ link_info.task_link = TRUE;
/* Fall through - do an implied -r option. */
case OPTION_UR:
- link_info.relocateable = true;
- config.build_constructors = true;
- config.magic_demand_paged = false;
- config.text_read_only = false;
- config.dynamic_link = false;
+ link_info.relocatable = TRUE;
+ config.build_constructors = TRUE;
+ config.magic_demand_paged = FALSE;
+ config.text_read_only = FALSE;
+ config.dynamic_link = FALSE;
break;
case 'u':
ldlang_add_undef (optarg);
@@ -997,20 +1083,21 @@ parse_args (argc, argv)
if (optarg != NULL)
lang_add_unique (optarg);
else
- config.unique_orphan_sections = true;
+ config.unique_orphan_sections = TRUE;
break;
case OPTION_VERBOSE:
ldversion (1);
- version_printed = true;
- trace_file_tries = true;
+ version_printed = TRUE;
+ trace_file_tries = TRUE;
+ overflow_cutoff_limit = -2;
break;
case 'v':
ldversion (0);
- version_printed = true;
+ version_printed = TRUE;
break;
case 'V':
ldversion (1);
- version_printed = true;
+ version_printed = TRUE;
break;
case OPTION_VERSION:
ldversion (2);
@@ -1018,8 +1105,8 @@ parse_args (argc, argv)
break;
case OPTION_VERSION_SCRIPT:
/* This option indicates a small script that only specifies
- version information. Read it, but don't assume that
- we've seen a linker script. */
+ version information. Read it, but don't assume that
+ we've seen a linker script. */
{
FILE *hold_script_handle;
@@ -1037,25 +1124,31 @@ parse_args (argc, argv)
command_line.version_exports_section = optarg;
break;
case OPTION_WARN_COMMON:
- config.warn_common = true;
+ config.warn_common = TRUE;
break;
case OPTION_WARN_CONSTRUCTORS:
- config.warn_constructors = true;
+ config.warn_constructors = TRUE;
break;
case OPTION_WARN_FATAL:
- config.fatal_warnings = true;
+ config.fatal_warnings = TRUE;
break;
case OPTION_WARN_MULTIPLE_GP:
- config.warn_multiple_gp = true;
+ config.warn_multiple_gp = TRUE;
break;
case OPTION_WARN_ONCE:
- config.warn_once = true;
+ config.warn_once = TRUE;
break;
case OPTION_WARN_SECTION_ALIGN:
- config.warn_section_align = true;
+ config.warn_section_align = TRUE;
break;
case OPTION_WHOLE_ARCHIVE:
- whole_archive = true;
+ whole_archive = TRUE;
+ break;
+ case OPTION_AS_NEEDED:
+ as_needed = TRUE;
+ break;
+ case OPTION_NO_AS_NEEDED:
+ as_needed = FALSE;
break;
case OPTION_WRAP:
add_wrap (optarg);
@@ -1072,6 +1165,8 @@ parse_args (argc, argv)
case 'Y':
if (strncmp (optarg, "P,", 2) == 0)
optarg += 2;
+ if (default_dirlist != NULL)
+ free (default_dirlist);
default_dirlist = xstrdup (optarg);
break;
case 'y':
@@ -1093,10 +1188,16 @@ parse_args (argc, argv)
config.split_by_file = 1;
break;
case OPTION_CHECK_SECTIONS:
- command_line.check_section_addresses = true;
+ command_line.check_section_addresses = TRUE;
break;
case OPTION_NO_CHECK_SECTIONS:
- command_line.check_section_addresses = false;
+ command_line.check_section_addresses = FALSE;
+ break;
+ case OPTION_ACCEPT_UNKNOWN_INPUT_ARCH:
+ command_line.accept_unknown_input_arch = TRUE;
+ break;
+ case OPTION_NO_ACCEPT_UNKNOWN_INPUT_ARCH:
+ command_line.accept_unknown_input_arch = FALSE;
break;
case '(':
if (ingroup)
@@ -1112,22 +1213,6 @@ parse_args (argc, argv)
lang_leave_group ();
ingroup = 0;
break;
- case OPTION_MPC860C0:
- /* Default value (in bytes). */
- link_info.mpc860c0 = 20;
- if (optarg)
- {
- unsigned words;
-
- words = is_num (optarg, 1, 10, 0);
- if (words == 0)
- einfo (_("%P%F: invalid argument to option \"mpc860c0\"\n"));
-
- /* Convert words to bytes. */
- link_info.mpc860c0 = words * 4;
- }
- command_line.relax = true;
- break;
case OPTION_INIT:
link_info.init_function = optarg;
@@ -1143,16 +1228,25 @@ parse_args (argc, argv)
lang_leave_group ();
if (default_dirlist != NULL)
- set_default_dirlist (default_dirlist);
+ {
+ set_default_dirlist (default_dirlist);
+ free (default_dirlist);
+ }
+ if (link_info.unresolved_syms_in_objects == RM_NOT_YET_SET)
+ /* FIXME: Should we allow emulations a chance to set this ? */
+ link_info.unresolved_syms_in_objects = how_to_report_unresolved_symbols;
+
+ if (link_info.unresolved_syms_in_shared_libs == RM_NOT_YET_SET)
+ /* FIXME: Should we allow emulations a chance to set this ? */
+ link_info.unresolved_syms_in_shared_libs = how_to_report_unresolved_symbols;
}
/* Add the (colon-separated) elements of DIRLIST_PTR to the
library search path. */
static void
-set_default_dirlist (dirlist_ptr)
- char *dirlist_ptr;
+set_default_dirlist (char *dirlist_ptr)
{
char *p;
@@ -1162,7 +1256,7 @@ set_default_dirlist (dirlist_ptr)
if (p != NULL)
*p = '\0';
if (*dirlist_ptr != '\0')
- ldfile_add_library_path (dirlist_ptr, true);
+ ldfile_add_library_path (dirlist_ptr, TRUE);
if (p == NULL)
break;
dirlist_ptr = p + 1;
@@ -1170,8 +1264,7 @@ set_default_dirlist (dirlist_ptr)
}
static void
-set_section_start (sect, valstr)
- char *sect, *valstr;
+set_section_start (char *sect, char *valstr)
{
const char *end;
bfd_vma val = bfd_scan_vma (valstr, &end, 16);
@@ -1183,7 +1276,7 @@ set_section_start (sect, valstr)
/* Print help messages for the options. */
static void
-help ()
+help (void)
{
unsigned i;
const char **targets, **pp;
@@ -1195,13 +1288,13 @@ help ()
{
if (ld_options[i].doc != NULL)
{
- boolean comma;
+ bfd_boolean comma;
int len;
unsigned j;
printf (" ");
- comma = false;
+ comma = FALSE;
len = 2;
j = i;
@@ -1222,7 +1315,7 @@ help ()
printf ("%s", _(ld_options[j].arg));
len += strlen (_(ld_options[j].arg));
}
- comma = true;
+ comma = TRUE;
}
++j;
}
@@ -1251,7 +1344,7 @@ help ()
printf (" %s", _(ld_options[j].arg));
len += 1 + strlen (_(ld_options[j].arg));
}
- comma = true;
+ comma = TRUE;
}
++j;
}
diff --git a/contrib/binutils/ld/mri.c b/contrib/binutils/ld/mri.c
index 62a7f08..f7edd88 100644
--- a/contrib/binutils/ld/mri.c
+++ b/contrib/binutils/ld/mri.c
@@ -1,6 +1,6 @@
/* mri.c -- handle MRI style linker scripts
- Copyright 1991, 1992, 1993, 1994, 1996, 1997, 1998, 1999, 2000, 2002
- Free Software Foundation, Inc.
+ Copyright 1991, 1992, 1993, 1994, 1996, 1997, 1998, 1999, 2000, 2002,
+ 2003, 2004 Free Software Foundation, Inc.
This file is part of GLD, the Gnu Linker.
@@ -53,17 +53,8 @@ struct section_name_struct *alias;
struct section_name_struct *alignment;
struct section_name_struct *subalignment;
-static struct section_name_struct **lookup
- PARAMS ((const char *name, struct section_name_struct **list));
-static void mri_add_to_list PARAMS ((struct section_name_struct **list,
- const char *name, etree_type *vma,
- const char *zalias, etree_type *align,
- etree_type *subalign));
-
static struct section_name_struct **
-lookup (name, list)
- const char *name;
- struct section_name_struct **list;
+lookup (const char *name, struct section_name_struct **list)
{
struct section_name_struct **ptr = list;
@@ -77,24 +68,23 @@ lookup (name, list)
ptr = &((*ptr)->next);
}
- *ptr = (struct section_name_struct *) xmalloc (sizeof (struct section_name_struct));
+ *ptr = xmalloc (sizeof (struct section_name_struct));
return ptr;
}
static void
-mri_add_to_list (list, name, vma, zalias, align, subalign)
- struct section_name_struct **list;
- const char *name;
- etree_type *vma;
- const char *zalias;
- etree_type *align;
- etree_type *subalign;
+mri_add_to_list (struct section_name_struct **list,
+ const char *name,
+ etree_type *vma,
+ const char *zalias,
+ etree_type *align,
+ etree_type *subalign)
{
struct section_name_struct **ptr = lookup (name, list);
(*ptr)->name = name;
(*ptr)->vma = vma;
- (*ptr)->next = (struct section_name_struct *) NULL;
+ (*ptr)->next = NULL;
(*ptr)->ok_to_load = 0;
(*ptr)->alias = zalias;
(*ptr)->align = align;
@@ -102,9 +92,7 @@ mri_add_to_list (list, name, vma, zalias, align, subalign)
}
void
-mri_output_section (name, vma)
- const char *name;
- etree_type *vma;
+mri_output_section (const char *name, etree_type *vma)
{
mri_add_to_list (&address, name, vma, 0, 0, 0);
}
@@ -113,15 +101,13 @@ mri_output_section (name, vma)
marked thus. */
void
-mri_only_load (name)
- const char *name;
+mri_only_load (const char *name)
{
mri_add_to_list (&only_load, name, 0, 0, 0, 0);
}
void
-mri_base (exp)
- etree_type *exp;
+mri_base (etree_type *exp)
{
base = exp;
}
@@ -129,7 +115,7 @@ mri_base (exp)
static int done_tree = 0;
void
-mri_draw_tree ()
+mri_draw_tree (void)
{
if (done_tree)
return;
@@ -142,32 +128,30 @@ mri_draw_tree ()
r = lang_memory_region_lookup("long");
r->current = r->origin = exp_get_vma (base, (bfd_vma)0, "origin",
lang_first_phase_enum);
- r->length = (bfd_size_type) exp_get_vma (0, (bfd_vma) ~((bfd_size_type)0),
- "length", lang_first_phase_enum);
+ r->length = (bfd_size_type) exp_get_vma (0, ~(bfd_vma) 0, "length",
+ lang_first_phase_enum);
}
#endif
/* Now build the statements for the ldlang machine. */
- /* Attatch the addresses of any which have addresses,
+ /* Attach the addresses of any which have addresses,
and add the ones not mentioned. */
- if (address != (struct section_name_struct *) NULL)
+ if (address != NULL)
{
struct section_name_struct *alist;
struct section_name_struct *olist;
- if (order == (struct section_name_struct *) NULL)
+ if (order == NULL)
order = address;
for (alist = address;
- alist != (struct section_name_struct *) NULL;
+ alist != NULL;
alist = alist->next)
{
int done = 0;
- for (olist = order;
- done == 0 && olist != (struct section_name_struct *) NULL;
- olist = olist->next)
+ for (olist = order; done == 0 && olist != NULL; olist = olist->next)
{
if (strcmp (alist->name, olist->name) == 0)
{
@@ -186,12 +170,12 @@ mri_draw_tree ()
/* If we're only supposed to load a subset of them in, then prune
the list. */
- if (only_load != (struct section_name_struct *) NULL)
+ if (only_load != NULL)
{
struct section_name_struct *ptr1;
struct section_name_struct *ptr2;
- if (order == (struct section_name_struct *) NULL)
+ if (order == NULL)
order = only_load;
/* See if this name is in the list, if it is then we can load it. */
@@ -210,7 +194,7 @@ mri_draw_tree ()
}
/* Create the order of sections to load. */
- if (order != (struct section_name_struct *) NULL)
+ if (order != NULL)
{
/* Been told to output the sections in a certain order. */
struct section_name_struct *p = order;
@@ -236,31 +220,28 @@ mri_draw_tree ()
lang_enter_output_section_statement (p->name, base,
p->ok_to_load ? 0 : noload_section,
- 1, align, subalign,
- (etree_type *) NULL);
+ align, subalign, NULL);
base = 0;
- tmp = (struct wildcard_list *) xmalloc (sizeof *tmp);
+ tmp = xmalloc (sizeof *tmp);
tmp->next = NULL;
tmp->spec.name = p->name;
tmp->spec.exclude_name_list = NULL;
- tmp->spec.sorted = false;
- lang_add_wild (NULL, tmp, false);
+ tmp->spec.sorted = FALSE;
+ lang_add_wild (NULL, tmp, FALSE);
/* If there is an alias for this section, add it too. */
for (aptr = alias; aptr; aptr = aptr->next)
if (strcmp (aptr->alias, p->name) == 0)
{
- tmp = (struct wildcard_list *) xmalloc (sizeof *tmp);
+ tmp = xmalloc (sizeof *tmp);
tmp->next = NULL;
tmp->spec.name = aptr->name;
tmp->spec.exclude_name_list = NULL;
- tmp->spec.sorted = false;
- lang_add_wild (NULL, tmp, false);
+ tmp->spec.sorted = FALSE;
+ lang_add_wild (NULL, tmp, FALSE);
}
- lang_leave_output_section_statement
- (0, "*default*", (struct lang_output_section_phdr_list *) NULL,
- NULL);
+ lang_leave_output_section_statement (0, "*default*", NULL, NULL);
p = p->next;
}
@@ -270,29 +251,23 @@ mri_draw_tree ()
}
void
-mri_load (name)
- const char *name;
+mri_load (const char *name)
{
base = 0;
- lang_add_input_file (name,
- lang_input_file_is_file_enum, (char *) NULL);
+ lang_add_input_file (name, lang_input_file_is_file_enum, NULL);
#if 0
lang_leave_output_section_statement (0, "*default*");
#endif
}
void
-mri_order (name)
- const char *name;
+mri_order (const char *name)
{
mri_add_to_list (&order, name, 0, 0, 0, 0);
}
void
-mri_alias (want, is, isn)
- const char *want;
- const char *is;
- int isn;
+mri_alias (const char *want, const char *is, int isn)
{
if (!is)
{
@@ -311,56 +286,47 @@ mri_alias (want, is, isn)
}
void
-mri_name (name)
- const char *name;
+mri_name (const char *name)
{
lang_add_output (name, 1);
}
void
-mri_format (name)
- const char *name;
+mri_format (const char *name)
{
if (strcmp (name, "S") == 0)
- lang_add_output_format ("srec", (char *) NULL, (char *) NULL, 1);
+ lang_add_output_format ("srec", NULL, NULL, 1);
else if (strcmp (name, "IEEE") == 0)
- lang_add_output_format ("ieee", (char *) NULL, (char *) NULL, 1);
+ lang_add_output_format ("ieee", NULL, NULL, 1);
else if (strcmp (name, "COFF") == 0)
- lang_add_output_format ("coff-m68k", (char *) NULL, (char *) NULL, 1);
+ lang_add_output_format ("coff-m68k", NULL, NULL, 1);
else
einfo (_("%P%F: unknown format type %s\n"), name);
}
void
-mri_public (name, exp)
- const char *name;
- etree_type *exp;
+mri_public (const char *name, etree_type *exp)
{
lang_add_assignment (exp_assop ('=', name, exp));
}
void
-mri_align (name, exp)
- const char *name;
- etree_type *exp;
+mri_align (const char *name, etree_type *exp)
{
mri_add_to_list (&alignment, name, 0, 0, exp, 0);
}
void
-mri_alignmod (name, exp)
- const char *name;
- etree_type *exp;
+mri_alignmod (const char *name, etree_type *exp)
{
mri_add_to_list (&subalignment, name, 0, 0, 0, exp);
}
void
-mri_truncate (exp)
- unsigned int exp;
+mri_truncate (unsigned int exp)
{
symbol_truncate = exp;
}
diff --git a/contrib/binutils/ld/mri.h b/contrib/binutils/ld/mri.h
index e857e3d..b430d20 100644
--- a/contrib/binutils/ld/mri.h
+++ b/contrib/binutils/ld/mri.h
@@ -1,5 +1,5 @@
/* mri.h -- header file for MRI scripting functions
- Copyright 1993, 1995, 1996 Free Software Foundation, Inc.
+ Copyright 1993, 1995, 1996, 2003 Free Software Foundation, Inc.
This file is part of GLD, the Gnu Linker.
@@ -22,18 +22,18 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
extern unsigned int symbol_truncate;
-extern void mri_output_section PARAMS ((const char *name, etree_type *vma));
-extern void mri_only_load PARAMS ((const char *name));
-extern void mri_base PARAMS ((etree_type *exp));
-extern void mri_load PARAMS ((const char *name));
-extern void mri_order PARAMS ((const char *name));
-extern void mri_alias PARAMS ((const char *want, const char *is, int isn));
-extern void mri_name PARAMS ((const char *name));
-extern void mri_format PARAMS ((const char *name));
-extern void mri_public PARAMS ((const char *name, etree_type *exp));
-extern void mri_align PARAMS ((const char *name, etree_type *exp));
-extern void mri_alignmod PARAMS ((const char *name, etree_type *exp));
-extern void mri_truncate PARAMS ((unsigned int exp));
-extern void mri_draw_tree PARAMS ((void));
+extern void mri_output_section (const char *, etree_type *);
+extern void mri_only_load (const char *);
+extern void mri_base (etree_type *);
+extern void mri_load (const char *);
+extern void mri_order (const char *);
+extern void mri_alias (const char *, const char *, int);
+extern void mri_name (const char *);
+extern void mri_format (const char *);
+extern void mri_public (const char *, etree_type *);
+extern void mri_align (const char *, etree_type *);
+extern void mri_alignmod (const char *, etree_type *);
+extern void mri_truncate (unsigned int);
+extern void mri_draw_tree (void);
#endif
diff --git a/contrib/binutils/ld/pe-dll.c b/contrib/binutils/ld/pe-dll.c
index e59c32d..45d00ae 100644
--- a/contrib/binutils/ld/pe-dll.c
+++ b/contrib/binutils/ld/pe-dll.c
@@ -1,5 +1,6 @@
/* Routines to help build PEI-format DLLs (Win32 etc)
- Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2001, 2002, 2003, 2004
+ Free Software Foundation, Inc.
Written by DJ Delorie <dj@cygnus.com>
This file is part of GLD, the Gnu Linker.
@@ -59,7 +60,7 @@
code modifications).
2. This is done completely in bounds of the PE specification (to be fair,
- there's a place where it pokes nose out of, but in practise it works).
+ there's a place where it pokes nose out of, but in practice it works).
So, resulting module can be used with any other PE compiler/linker.
3. Auto-import is fully compatible with standard import method and they
@@ -74,7 +75,7 @@
The obvious and only way to get rid of dllimport insanity is to make client
access variable directly in the DLL, bypassing extra dereference. I.e.,
- whenever client contains someting like
+ whenever client contains something like
mov dll_var,%eax,
@@ -82,7 +83,7 @@
DLL. The aim is to make OS loader do so, and than make ld help with that.
Import section of PE made following way: there's a vector of structures
each describing imports from particular DLL. Each such structure points
- to two other parellel vectors: one holding imported names, and one which
+ to two other parallel vectors: one holding imported names, and one which
will hold address of corresponding imported name. So, the solution is
de-vectorize these structures, making import locations be sparse and
pointing directly into code. Before continuing, it is worth a note that,
@@ -104,7 +105,7 @@
above: PE specification rambles that name vector (OriginalFirstThunk)
should run in parallel with addresses vector (FirstThunk), i.e. that they
should have same number of elements and terminated with zero. We violate
- this, since FirstThunk points directly into machine code. But in practise,
+ this, since FirstThunk points directly into machine code. But in practice,
OS loader implemented the sane way: it goes thru OriginalFirstThunk and
puts addresses to FirstThunk, not something else. It once again should be
noted that dll and symbol name structures are reused across fixup entries
@@ -115,13 +116,12 @@
in windows9x kernel32.dll, so if you use it, you have two
IMAGE_IMPORT_DESCRIPTORS for kernel32.dll). Yet other question is whether
referencing the same PE structures several times is valid. The answer is why
- not, prohibitting that (detecting violation) would require more work on
+ not, prohibiting that (detecting violation) would require more work on
behalf of loader than not doing it.
See also: ld/emultempl/pe.em. */
-static void
-add_bfd_to_link PARAMS ((bfd *, const char *, struct bfd_link_info *));
+static void add_bfd_to_link (bfd *, const char *, struct bfd_link_info *);
/* For emultempl/pe.em. */
@@ -138,9 +138,10 @@ int pe_dll_extra_pe_debug = 0;
static bfd_vma image_base;
static bfd *filler_bfd;
-static struct sec *edata_s, *reloc_s;
+static struct bfd_section *edata_s, *reloc_s;
static unsigned char *edata_d, *reloc_d;
static size_t edata_sz, reloc_sz;
+static int runtime_pseudo_relocs_created = 0;
typedef struct
{
@@ -198,7 +199,7 @@ static pe_details_type pe_detail_list[] =
11 /* ARM_RVA32 */,
PE_ARCH_arm,
bfd_arch_arm,
- 0
+ 1
},
{
"epoc-pei-arm-little",
@@ -222,18 +223,24 @@ static autofilter_entry_type autofilter_symbollist[] =
{ "_cygwin_crt0_common@8", 21 },
{ "_cygwin_noncygwin_dll_entry@12", 30 },
{ "impure_ptr", 10 },
+ { "_pei386_runtime_relocator", 25 },
+ { "do_pseudo_reloc", 15 },
+ { "cygwin_crt0", 11 },
{ NULL, 0 }
};
/* Do not specify library suffix explicitly, to allow for dllized versions. */
static autofilter_entry_type autofilter_liblist[] =
{
- { "libgcc.", 7 },
- { "libstdc++.", 10 },
- { "libmingw32.", 11 },
- { "libg2c.", 7 },
- { "libsupc++.", 10 },
- { "libobjc.", 8 },
+ { "libcygwin", 9 },
+ { "libgcc", 6 },
+ { "libstdc++", 9 },
+ { "libmingw32", 10 },
+ { "libmingwex", 10 },
+ { "libg2c", 6 },
+ { "libsupc++", 9 },
+ { "libobjc", 7 },
+ { "libgcj", 6 },
{ NULL, 0 }
};
@@ -281,35 +288,8 @@ static autofilter_entry_type autofilter_symbolsuffixlist[] =
#define U(str) (pe_details->underscored ? "_" str : str)
-static int reloc_sort PARAMS ((const void *, const void *));
-static int pe_export_sort PARAMS ((const void *, const void *));
-static int auto_export PARAMS ((bfd *, def_file *, const char *));
-static void process_def_file PARAMS ((bfd *, struct bfd_link_info *));
-static void build_filler_bfd PARAMS ((int));
-static void generate_edata PARAMS ((bfd *, struct bfd_link_info *));
-static void fill_exported_offsets PARAMS ((bfd *, struct bfd_link_info *));
-static void fill_edata PARAMS ((bfd *, struct bfd_link_info *));
-static void generate_reloc PARAMS ((bfd *, struct bfd_link_info *));
-static void quoteput PARAMS ((char *, FILE *, int));
-static asection *quick_section PARAMS ((bfd *, const char *, int, int));
-static void quick_symbol
- PARAMS ((bfd *, const char *, const char *, const char *,
- asection *, int, int));
-static void quick_reloc PARAMS ((bfd *, int, int, int));
-static bfd *make_head PARAMS ((bfd *));
-static bfd *make_tail PARAMS ((bfd *));
-static bfd *make_one PARAMS ((def_file_export *, bfd *));
-static bfd *make_singleton_name_thunk PARAMS ((const char *, bfd *));
-static char *make_import_fixup_mark PARAMS ((arelent *));
-static bfd *make_import_fixup_entry
- PARAMS ((const char *, const char *, const char *, bfd *));
-static unsigned int pe_get16 PARAMS ((bfd *, int));
-static unsigned int pe_get32 PARAMS ((bfd *, int));
-static unsigned int pe_as32 PARAMS ((void *));
-
void
-pe_dll_id_target (target)
- const char *target;
+pe_dll_id_target (const char *target)
{
int i;
@@ -336,21 +316,19 @@ typedef struct
reloc_data_type;
static int
-reloc_sort (va, vb)
- const void *va, *vb;
+reloc_sort (const void *va, const void *vb)
{
- bfd_vma a = ((reloc_data_type *) va)->vma;
- bfd_vma b = ((reloc_data_type *) vb)->vma;
+ bfd_vma a = ((const reloc_data_type *) va)->vma;
+ bfd_vma b = ((const reloc_data_type *) vb)->vma;
return (a > b) ? 1 : ((a < b) ? -1 : 0);
}
static int
-pe_export_sort (va, vb)
- const void *va, *vb;
+pe_export_sort (const void *va, const void *vb)
{
- def_file_export *a = (def_file_export *) va;
- def_file_export *b = (def_file_export *) vb;
+ const def_file_export *a = va;
+ const def_file_export *b = vb;
return strcmp (a->name, b->name);
}
@@ -362,7 +340,7 @@ pe_export_sort (va, vb)
defined, since we can't export symbols we don't have. */
static bfd_vma *exported_symbol_offsets;
-static struct sec **exported_symbol_sections;
+static struct bfd_section **exported_symbol_sections;
static int export_table_size;
static int count_exported;
static int count_exported_byname;
@@ -382,9 +360,7 @@ exclude_list_struct;
static struct exclude_list_struct *excludes = 0;
void
-pe_dll_add_excludes (new_excludes, type)
- const char *new_excludes;
- const int type;
+pe_dll_add_excludes (const char *new_excludes, const int type)
{
char *local_copy;
char *exclude_string;
@@ -396,9 +372,8 @@ pe_dll_add_excludes (new_excludes, type)
{
struct exclude_list_struct *new_exclude;
- new_exclude = ((struct exclude_list_struct *)
- xmalloc (sizeof (struct exclude_list_struct)));
- new_exclude->string = (char *) xmalloc (strlen (exclude_string) + 1);
+ new_exclude = xmalloc (sizeof (struct exclude_list_struct));
+ new_exclude->string = xmalloc (strlen (exclude_string) + 1);
strcpy (new_exclude->string, exclude_string);
new_exclude->type = type;
new_exclude->next = excludes;
@@ -413,10 +388,7 @@ pe_dll_add_excludes (new_excludes, type)
It can be used for contextual checks. */
static int
-auto_export (abfd, d, n)
- bfd *abfd;
- def_file *d;
- const char *n;
+auto_export (bfd *abfd, def_file *d, const char *n)
{
int i;
struct exclude_list_struct *ex;
@@ -443,7 +415,7 @@ auto_export (abfd, d, n)
n, abfd, abfd->my_archive);
/* First of all, make context checks:
- Don't export anything from standard libs. */
+ Don't export anything from standard libs. */
if (libname)
{
afptr = autofilter_liblist;
@@ -525,14 +497,12 @@ auto_export (abfd, d, n)
}
static void
-process_def_file (abfd, info)
- bfd *abfd ATTRIBUTE_UNUSED;
- struct bfd_link_info *info;
+process_def_file (bfd *abfd ATTRIBUTE_UNUSED, struct bfd_link_info *info)
{
int i, j;
struct bfd_link_hash_entry *blhe;
bfd *b;
- struct sec *s;
+ struct bfd_section *s;
def_file_export *e = 0;
if (!pe_def_file)
@@ -554,6 +524,12 @@ process_def_file (abfd, info)
}
}
+ /* If we are not building a DLL, when there are no exports
+ we do not build an export table at all. */
+ if (!pe_dll_export_everything && pe_def_file->num_exports == 0
+ && !info->shared)
+ return;
+
/* Now, maybe export everything else the default way. */
if (pe_dll_export_everything || pe_def_file->num_exports == 0)
{
@@ -563,14 +539,14 @@ process_def_file (abfd, info)
int nsyms, symsize;
symsize = bfd_get_symtab_upper_bound (b);
- symbols = (asymbol **) xmalloc (symsize);
+ symbols = xmalloc (symsize);
nsyms = bfd_canonicalize_symtab (b, symbols);
for (j = 0; j < nsyms; j++)
{
/* We should export symbols which are either global or not
- anything at all. (.bss data is the latter)
- We should not export undefined symbols. */
+ anything at all. (.bss data is the latter)
+ We should not export undefined symbols. */
if (symbols[j]->section != &bfd_und_section
&& ((symbols[j]->flags & BSF_GLOBAL)
|| (symbols[j]->flags == BFD_FORT_COMM_DEFAULT_VALUE)))
@@ -579,11 +555,11 @@ process_def_file (abfd, info)
/* We should not re-export imported stuff. */
{
- char *name = (char *) xmalloc (strlen (sn) + 2 + 6);
+ char *name = xmalloc (strlen (sn) + 2 + 6);
sprintf (name, "%s%s", U("_imp_"), sn);
blhe = bfd_link_hash_lookup (info->hash, name,
- false, false, false);
+ FALSE, FALSE, FALSE);
free (name);
if (blhe && blhe->type == bfd_link_hash_defined)
@@ -616,9 +592,10 @@ process_def_file (abfd, info)
if (strchr (pe_def_file->exports[i].name, '@'))
{
/* This will preserve internal_name, which may have been
- pointing to the same memory as name, or might not
- have. */
- char *tmp = xstrdup (pe_def_file->exports[i].name);
+ pointing to the same memory as name, or might not
+ have. */
+ int lead_at = (*pe_def_file->exports[i].name == '@');
+ char *tmp = xstrdup (pe_def_file->exports[i].name + lead_at);
*(strchr (tmp, '@')) = 0;
pe_def_file->exports[i].name = tmp;
@@ -632,7 +609,8 @@ process_def_file (abfd, info)
{
if (strchr (pe_def_file->exports[i].name, '@'))
{
- char *tmp = xstrdup (pe_def_file->exports[i].name);
+ int lead_at = (*pe_def_file->exports[i].name == '@');
+ char *tmp = xstrdup (pe_def_file->exports[i].name + lead_at);
*(strchr (tmp, '@')) = 0;
if (auto_export (NULL, pe_def_file, tmp))
@@ -648,17 +626,18 @@ process_def_file (abfd, info)
/* Convenience, but watch out for it changing. */
e = pe_def_file->exports;
- exported_symbol_offsets = (bfd_vma *) xmalloc (NE * sizeof (bfd_vma));
- exported_symbol_sections = (struct sec **) xmalloc (NE * sizeof (struct sec *));
+ exported_symbol_offsets = xmalloc (NE * sizeof (bfd_vma));
+ exported_symbol_sections = xmalloc (NE * sizeof (struct bfd_section *));
- memset (exported_symbol_sections, 0, NE * sizeof (struct sec *));
+ memset (exported_symbol_sections, 0, NE * sizeof (struct bfd_section *));
max_ordinal = 0;
min_ordinal = 65536;
count_exported = 0;
count_exported_byname = 0;
count_with_ordinals = 0;
- qsort (pe_def_file->exports, NE, sizeof (pe_def_file->exports[0]), pe_export_sort);
+ qsort (pe_def_file->exports, NE, sizeof (pe_def_file->exports[0]),
+ pe_export_sort);
for (i = 0, j = 0; i < NE; i++)
{
if (i > 0 && strcmp (e[i].name, e[i - 1].name) == 0)
@@ -699,9 +678,11 @@ process_def_file (abfd, info)
for (i = 0; i < NE; i++)
{
- char *name = (char *) xmalloc (strlen (pe_def_file->exports[i].internal_name) + 2);
+ char *name;
- if (pe_details->underscored)
+ name = xmalloc (strlen (pe_def_file->exports[i].internal_name) + 2);
+ if (pe_details->underscored
+ && (*pe_def_file->exports[i].internal_name != '@'))
{
*name = '_';
strcpy (name + 1, pe_def_file->exports[i].internal_name);
@@ -711,7 +692,7 @@ process_def_file (abfd, info)
blhe = bfd_link_hash_lookup (info->hash,
name,
- false, false, true);
+ FALSE, FALSE, TRUE);
if (blhe
&& (blhe->type == bfd_link_hash_defined
@@ -764,8 +745,7 @@ process_def_file (abfd, info)
/* Build the bfd that will contain .edata and .reloc sections. */
static void
-build_filler_bfd (include_edata)
- int include_edata;
+build_filler_bfd (int include_edata)
{
lang_input_statement_type *filler_file;
filler_file = lang_add_input_file ("dll stuff",
@@ -819,9 +799,7 @@ build_filler_bfd (include_edata)
/* Gather all the exported symbols and build the .edata section. */
static void
-generate_edata (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
+generate_edata (bfd *abfd, struct bfd_link_info *info ATTRIBUTE_UNUSED)
{
int i, next_ordinal;
int name_table_size = 0;
@@ -852,7 +830,7 @@ generate_edata (abfd, info)
}
export_table_size = max_ordinal - min_ordinal + 1;
- exported_symbols = (int *) xmalloc (export_table_size * sizeof (int));
+ exported_symbols = xmalloc (export_table_size * sizeof (int));
for (i = 0; i < export_table_size; i++)
exported_symbols[i] = -1;
@@ -904,18 +882,18 @@ generate_edata (abfd, info)
been done in process_def_file(). */
static void
-fill_exported_offsets (abfd, info)
- bfd *abfd ATTRIBUTE_UNUSED;
- struct bfd_link_info *info;
+fill_exported_offsets (bfd *abfd ATTRIBUTE_UNUSED, struct bfd_link_info *info)
{
int i;
struct bfd_link_hash_entry *blhe;
for (i = 0; i < pe_def_file->num_exports; i++)
{
- char *name = (char *) xmalloc (strlen (pe_def_file->exports[i].internal_name) + 2);
+ char *name;
- if (pe_details->underscored)
+ name = xmalloc (strlen (pe_def_file->exports[i].internal_name) + 2);
+ if (pe_details->underscored
+ && *pe_def_file->exports[i].internal_name != '@')
{
*name = '_';
strcpy (name + 1, pe_def_file->exports[i].internal_name);
@@ -925,9 +903,9 @@ fill_exported_offsets (abfd, info)
blhe = bfd_link_hash_lookup (info->hash,
name,
- false, false, true);
+ FALSE, FALSE, TRUE);
- if (blhe && (blhe->type == bfd_link_hash_defined))
+ if (blhe && blhe->type == bfd_link_hash_defined)
exported_symbol_offsets[i] = blhe->u.def.value;
free (name);
@@ -935,30 +913,29 @@ fill_exported_offsets (abfd, info)
}
static void
-fill_edata (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
+fill_edata (bfd *abfd, struct bfd_link_info *info ATTRIBUTE_UNUSED)
{
- int i, hint;
+ int s, hint;
unsigned char *edirectory;
- unsigned long *eaddresses;
- unsigned long *enameptrs;
- unsigned short *eordinals;
+ unsigned char *eaddresses;
+ unsigned char *enameptrs;
+ unsigned char *eordinals;
unsigned char *enamestr;
time_t now;
time (&now);
- edata_d = (unsigned char *) xmalloc (edata_sz);
+ edata_d = xmalloc (edata_sz);
/* Note use of array pointer math here. */
edirectory = edata_d;
- eaddresses = (unsigned long *) (edata_d + 40);
- enameptrs = eaddresses + export_table_size;
- eordinals = (unsigned short *) (enameptrs + count_exported_byname);
- enamestr = (char *) (eordinals + count_exported_byname);
+ eaddresses = edata_d + 40;
+ enameptrs = eaddresses + 4 * export_table_size;
+ eordinals = enameptrs + 4 * count_exported_byname;
+ enamestr = eordinals + 2 * count_exported_byname;
-#define ERVA(ptr) (((unsigned char *)(ptr) - edata_d) + edata_s->output_section->vma - image_base)
+#define ERVA(ptr) (((unsigned char *)(ptr) - edata_d) \
+ + edata_s->output_section->vma - image_base)
memset (edata_d, 0, edata_sz);
bfd_put_32 (abfd, now, edata_d + 4);
@@ -980,32 +957,36 @@ fill_edata (abfd, info)
fill_exported_offsets (abfd, info);
- /* Ok, now for the filling in part. */
+ /* Ok, now for the filling in part.
+ Scan alphabetically - ie the ordering in the exports[] table,
+ rather than by ordinal - the ordering in the exported_symbol[]
+ table. See dlltool.c and:
+ http://sources.redhat.com/ml/binutils/2003-04/msg00379.html
+ for more information. */
hint = 0;
- for (i = 0; i < export_table_size; i++)
+ for (s = 0; s < NE; s++)
{
- int s = exported_symbols[i];
-
- if (s != -1)
+ struct bfd_section *ssec = exported_symbol_sections[s];
+ if (ssec && pe_def_file->exports[s].ordinal != -1)
{
- struct sec *ssec = exported_symbol_sections[s];
unsigned long srva = (exported_symbol_offsets[s]
+ ssec->output_section->vma
+ ssec->output_offset);
int ord = pe_def_file->exports[s].ordinal;
bfd_put_32 (abfd, srva - image_base,
- (void *) (eaddresses + ord - min_ordinal));
+ eaddresses + 4 * (ord - min_ordinal));
if (!pe_def_file->exports[s].flag_noname)
{
char *ename = pe_def_file->exports[s].name;
- bfd_put_32 (abfd, ERVA (enamestr), (void *) enameptrs);
- enameptrs++;
+
+ bfd_put_32 (abfd, ERVA (enamestr), enameptrs);
+ enameptrs += 4;
strcpy (enamestr, ename);
enamestr += strlen (enamestr) + 1;
- bfd_put_16 (abfd, ord - min_ordinal, (void *) eordinals);
- eordinals++;
+ bfd_put_16 (abfd, ord - min_ordinal, eordinals);
+ eordinals += 2;
pe_def_file->exports[s].hint = hint++;
}
}
@@ -1013,13 +994,12 @@ fill_edata (abfd, info)
}
-static struct sec *current_sec;
+static struct bfd_section *current_sec;
void
-pe_walk_relocs_of_symbol (info, name, cb)
- struct bfd_link_info *info;
- const char *name;
- int (*cb) (arelent *, asection *);
+pe_walk_relocs_of_symbol (struct bfd_link_info *info,
+ const char *name,
+ int (*cb) (arelent *, asection *))
{
bfd *b;
asection *s;
@@ -1030,7 +1010,7 @@ pe_walk_relocs_of_symbol (info, name, cb)
int nsyms, symsize;
symsize = bfd_get_symtab_upper_bound (b);
- symbols = (asymbol **) xmalloc (symsize);
+ symbols = xmalloc (symsize);
nsyms = bfd_canonicalize_symtab (b, symbols);
for (s = b->sections; s; s = s->next)
@@ -1047,12 +1027,12 @@ pe_walk_relocs_of_symbol (info, name, cb)
current_sec = s;
relsize = bfd_get_reloc_upper_bound (b, s);
- relocs = (arelent **) xmalloc ((size_t) relsize);
+ relocs = xmalloc (relsize);
nrelocs = bfd_canonicalize_reloc (b, s, relocs, symbols);
for (i = 0; i < nrelocs; i++)
{
- struct symbol_cache_entry *sym = *relocs[i]->sym_ptr_ptr;
+ struct bfd_symbol *sym = *relocs[i]->sym_ptr_ptr;
if (!strcmp (name, sym->name))
cb (relocs[i], s);
@@ -1070,28 +1050,25 @@ pe_walk_relocs_of_symbol (info, name, cb)
/* Gather all the relocations and build the .reloc section. */
static void
-generate_reloc (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info;
+generate_reloc (bfd *abfd, struct bfd_link_info *info)
{
/* For .reloc stuff. */
reloc_data_type *reloc_data;
int total_relocs = 0;
int i;
- unsigned long sec_page = (unsigned long) (-1);
+ unsigned long sec_page = (unsigned long) -1;
unsigned long page_ptr, page_count;
int bi;
bfd *b;
- struct sec *s;
+ struct bfd_section *s;
total_relocs = 0;
for (b = info->input_bfds; b; b = b->link_next)
for (s = b->sections; s; s = s->next)
total_relocs += s->reloc_count;
- reloc_data =
- (reloc_data_type *) xmalloc (total_relocs * sizeof (reloc_data_type));
+ reloc_data = xmalloc (total_relocs * sizeof (reloc_data_type));
total_relocs = 0;
bi = 0;
@@ -1125,25 +1102,25 @@ generate_reloc (abfd, info)
}
symsize = bfd_get_symtab_upper_bound (b);
- symbols = (asymbol **) xmalloc (symsize);
+ symbols = xmalloc (symsize);
nsyms = bfd_canonicalize_symtab (b, symbols);
relsize = bfd_get_reloc_upper_bound (b, s);
- relocs = (arelent **) xmalloc ((size_t) relsize);
+ relocs = xmalloc (relsize);
nrelocs = bfd_canonicalize_reloc (b, s, relocs, symbols);
for (i = 0; i < nrelocs; i++)
{
if (pe_dll_extra_pe_debug)
{
- struct symbol_cache_entry *sym = *relocs[i]->sym_ptr_ptr;
+ struct bfd_symbol *sym = *relocs[i]->sym_ptr_ptr;
printf ("rel: %s\n", sym->name);
}
if (!relocs[i]->howto->pc_relative
&& relocs[i]->howto->type != pe_details->imagebase_reloc)
{
bfd_vma sym_vma;
- struct symbol_cache_entry *sym = *relocs[i]->sym_ptr_ptr;
+ struct bfd_symbol *sym = *relocs[i]->sym_ptr_ptr;
sym_vma = (relocs[i]->addend
+ sym->value
@@ -1178,6 +1155,18 @@ generate_reloc (abfd, info)
reloc_data[total_relocs].type = 5;
total_relocs++;
break;
+ case BITS_AND_SHIFT (24, 2):
+ /* FIXME: 0 is ARM_26D, it is defined in bfd/coff-arm.c
+ Those ARM_xxx definitions should go in proper
+ header someday. */
+ if (relocs[i]->howto->type == 0
+ /* Older GNU linkers used 5 instead of 0 for this reloc. */
+ || relocs[i]->howto->type == 5)
+ /* This is an ARM_26D reloc, which is an ARM_26 reloc
+ that has already been fully processed during a
+ previous link stage, so ignore it here. */
+ break;
+ /* Fall through. */
default:
/* xgettext:c-format */
einfo (_("%XError: %d-bit reloc in dll\n"),
@@ -1218,10 +1207,10 @@ generate_reloc (abfd, info)
}
reloc_sz = (reloc_sz + 3) & ~3; /* 4-byte align. */
- reloc_d = (unsigned char *) xmalloc (reloc_sz);
- sec_page = (unsigned long) (-1);
+ reloc_d = xmalloc (reloc_sz);
+ sec_page = (unsigned long) -1;
reloc_sz = 0;
- page_ptr = (unsigned long) (-1);
+ page_ptr = (unsigned long) -1;
page_count = 0;
for (i = 0; i < total_relocs; i++)
@@ -1234,7 +1223,7 @@ generate_reloc (abfd, info)
while (reloc_sz & 3)
reloc_d[reloc_sz++] = 0;
- if (page_ptr != (unsigned long) (-1))
+ if (page_ptr != (unsigned long) -1)
bfd_put_32 (abfd, reloc_sz - page_ptr, reloc_d + page_ptr + 4);
bfd_put_32 (abfd, this_page, reloc_d + reloc_sz);
@@ -1260,7 +1249,7 @@ generate_reloc (abfd, info)
while (reloc_sz & 3)
reloc_d[reloc_sz++] = 0;
- if (page_ptr != (unsigned long) (-1))
+ if (page_ptr != (unsigned long) -1)
bfd_put_32 (abfd, reloc_sz - page_ptr, reloc_d + page_ptr + 4);
while (reloc_sz < reloc_s->_raw_size)
@@ -1271,10 +1260,7 @@ generate_reloc (abfd, info)
corresponds to it. */
static void
-quoteput (s, f, needs_quotes)
- char *s;
- FILE *f;
- int needs_quotes;
+quoteput (char *s, FILE *f, int needs_quotes)
{
char *cp;
@@ -1307,8 +1293,7 @@ quoteput (s, f, needs_quotes)
}
void
-pe_dll_generate_def_file (pe_out_def_filename)
- const char *pe_out_def_filename;
+pe_dll_generate_def_file (const char *pe_out_def_filename)
{
int i;
FILE *out = fopen (pe_out_def_filename, "w");
@@ -1476,11 +1461,7 @@ static char *dll_symname;
#define UNDSEC (asection *) &bfd_und_section
static asection *
-quick_section (abfd, name, flags, align)
- bfd *abfd;
- const char *name;
- int flags;
- int align;
+quick_section (bfd *abfd, const char *name, int flags, int align)
{
asection *sec;
asymbol *sym;
@@ -1502,17 +1483,16 @@ quick_section (abfd, name, flags, align)
}
static void
-quick_symbol (abfd, n1, n2, n3, sec, flags, addr)
- bfd *abfd;
- const char *n1;
- const char *n2;
- const char *n3;
- asection *sec;
- int flags;
- int addr;
+quick_symbol (bfd *abfd,
+ const char *n1,
+ const char *n2,
+ const char *n3,
+ asection *sec,
+ int flags,
+ int addr)
{
asymbol *sym;
- char *name = (char *) xmalloc (strlen (n1) + strlen (n2) + strlen (n3) + 1);
+ char *name = xmalloc (strlen (n1) + strlen (n2) + strlen (n3) + 1);
strcpy (name, n1);
strcat (name, n2);
@@ -1529,19 +1509,15 @@ static arelent *reltab = 0;
static int relcount = 0, relsize = 0;
static void
-quick_reloc (abfd, address, which_howto, symidx)
- bfd *abfd;
- int address;
- int which_howto;
- int symidx;
+quick_reloc (bfd *abfd, int address, int which_howto, int symidx)
{
- if (relcount >= (relsize - 1))
+ if (relcount >= relsize - 1)
{
relsize += 10;
if (reltab)
- reltab = (arelent *) xrealloc (reltab, relsize * sizeof (arelent));
+ reltab = xrealloc (reltab, relsize * sizeof (arelent));
else
- reltab = (arelent *) xmalloc (relsize * sizeof (arelent));
+ reltab = xmalloc (relsize * sizeof (arelent));
}
reltab[relcount].address = address;
reltab[relcount].addend = 0;
@@ -1557,7 +1533,7 @@ save_relocs (asection *sec)
sec->relocation = reltab;
sec->reloc_count = relcount;
- sec->orelocation = (arelent **) xmalloc ((relcount + 1) * sizeof (arelent *));
+ sec->orelocation = xmalloc ((relcount + 1) * sizeof (arelent *));
for (i = 0; i < relcount; i++)
sec->orelocation[i] = sec->relocation + i;
sec->orelocation[relcount] = 0;
@@ -1584,15 +1560,14 @@ save_relocs (asection *sec)
hname: */
static bfd *
-make_head (parent)
- bfd *parent;
+make_head (bfd *parent)
{
asection *id2, *id5, *id4;
unsigned char *d2, *d5, *d4;
char *oname;
bfd *abfd;
- oname = (char *) xmalloc (20);
+ oname = xmalloc (20);
sprintf (oname, "d%06d.o", tmp_seq);
tmp_seq++;
@@ -1604,7 +1579,7 @@ make_head (parent)
bfd_set_arch_mach (abfd, pe_details->bfd_arch, 0);
symptr = 0;
- symtab = (asymbol **) xmalloc (6 * sizeof (asymbol *));
+ symtab = xmalloc (6 * sizeof (asymbol *));
id2 = quick_section (abfd, ".idata$2", SEC_HAS_CONTENTS, 2);
id5 = quick_section (abfd, ".idata$5", SEC_HAS_CONTENTS, 2);
id4 = quick_section (abfd, ".idata$4", SEC_HAS_CONTENTS, 2);
@@ -1618,7 +1593,7 @@ make_head (parent)
the start of the list of sections from other objects. */
bfd_set_section_size (abfd, id2, 20);
- d2 = (unsigned char *) xmalloc (20);
+ d2 = xmalloc (20);
id2->contents = d2;
memset (d2, 0, 20);
d2[0] = d2[16] = 4; /* Reloc addend. */
@@ -1628,12 +1603,12 @@ make_head (parent)
save_relocs (id2);
bfd_set_section_size (abfd, id5, 4);
- d5 = (unsigned char *) xmalloc (4);
+ d5 = xmalloc (4);
id5->contents = d5;
memset (d5, 0, 4);
bfd_set_section_size (abfd, id4, 4);
- d4 = (unsigned char *) xmalloc (4);
+ d4 = xmalloc (4);
id4->contents = d4;
memset (d4, 0, 4);
@@ -1657,8 +1632,7 @@ make_head (parent)
.asciz "my.dll" */
static bfd *
-make_tail (parent)
- bfd *parent;
+make_tail (bfd *parent)
{
asection *id4, *id5, *id7;
unsigned char *d4, *d5, *d7;
@@ -1666,7 +1640,7 @@ make_tail (parent)
char *oname;
bfd *abfd;
- oname = (char *) xmalloc (20);
+ oname = xmalloc (20);
sprintf (oname, "d%06d.o", tmp_seq);
tmp_seq++;
@@ -1678,19 +1652,19 @@ make_tail (parent)
bfd_set_arch_mach (abfd, pe_details->bfd_arch, 0);
symptr = 0;
- symtab = (asymbol **) xmalloc (5 * sizeof (asymbol *));
+ symtab = xmalloc (5 * sizeof (asymbol *));
id4 = quick_section (abfd, ".idata$4", SEC_HAS_CONTENTS, 2);
id5 = quick_section (abfd, ".idata$5", SEC_HAS_CONTENTS, 2);
id7 = quick_section (abfd, ".idata$7", SEC_HAS_CONTENTS, 2);
quick_symbol (abfd, U (""), dll_symname, "_iname", id7, BSF_GLOBAL, 0);
bfd_set_section_size (abfd, id4, 4);
- d4 = (unsigned char *) xmalloc (4);
+ d4 = xmalloc (4);
id4->contents = d4;
memset (d4, 0, 4);
bfd_set_section_size (abfd, id5, 4);
- d5 = (unsigned char *) xmalloc (4);
+ d5 = xmalloc (4);
id5->contents = d5;
memset (d5, 0, 4);
@@ -1698,7 +1672,7 @@ make_tail (parent)
if (len & 1)
len++;
bfd_set_section_size (abfd, id7, len);
- d7 = (unsigned char *) xmalloc (len);
+ d7 = xmalloc (len);
id7->contents = d7;
strcpy (d7, dll_filename);
@@ -1763,9 +1737,7 @@ static unsigned char jmp_mips_bytes[] =
};
static bfd *
-make_one (exp, parent)
- def_file_export *exp;
- bfd *parent;
+make_one (def_file_export *exp, bfd *parent)
{
asection *tx, *id7, *id5, *id4, *id6;
unsigned char *td = NULL, *d7, *d5, *d4, *d6 = NULL;
@@ -1793,7 +1765,7 @@ make_one (exp, parent)
abort ();
}
- oname = (char *) xmalloc (20);
+ oname = xmalloc (20);
sprintf (oname, "d%06d.o", tmp_seq);
tmp_seq++;
@@ -1805,29 +1777,47 @@ make_one (exp, parent)
bfd_set_arch_mach (abfd, pe_details->bfd_arch, 0);
symptr = 0;
- symtab = (asymbol **) xmalloc (11 * sizeof (asymbol *));
+ symtab = xmalloc (11 * sizeof (asymbol *));
tx = quick_section (abfd, ".text", SEC_CODE|SEC_HAS_CONTENTS, 2);
id7 = quick_section (abfd, ".idata$7", SEC_HAS_CONTENTS, 2);
id5 = quick_section (abfd, ".idata$5", SEC_HAS_CONTENTS, 2);
id4 = quick_section (abfd, ".idata$4", SEC_HAS_CONTENTS, 2);
id6 = quick_section (abfd, ".idata$6", SEC_HAS_CONTENTS, 2);
- if (! exp->flag_data)
- quick_symbol (abfd, U (""), exp->internal_name, "", tx, BSF_GLOBAL, 0);
- quick_symbol (abfd, U ("_head_"), dll_symname, "", UNDSEC, BSF_GLOBAL, 0);
- quick_symbol (abfd, U ("_imp__"), exp->internal_name, "", id5, BSF_GLOBAL, 0);
- /* Symbol to reference ord/name of imported
- data symbol, used to implement auto-import. */
- if (exp->flag_data)
- quick_symbol (abfd, U("_nm__"), exp->internal_name, "", id6,
- BSF_GLOBAL,0);
+
+ if (*exp->internal_name == '@')
+ {
+ quick_symbol (abfd, U ("_head_"), dll_symname, "", UNDSEC,
+ BSF_GLOBAL, 0);
+ if (! exp->flag_data)
+ quick_symbol (abfd, "", exp->internal_name, "", tx, BSF_GLOBAL, 0);
+ quick_symbol (abfd, U ("_imp_"), exp->internal_name, "", id5,
+ BSF_GLOBAL, 0);
+ /* Fastcall applies only to functions,
+ so no need for auto-import symbol. */
+ }
+ else
+ {
+ quick_symbol (abfd, U ("_head_"), dll_symname, "", UNDSEC,
+ BSF_GLOBAL, 0);
+ if (! exp->flag_data)
+ quick_symbol (abfd, U (""), exp->internal_name, "", tx,
+ BSF_GLOBAL, 0);
+ quick_symbol (abfd, U ("_imp__"), exp->internal_name, "", id5,
+ BSF_GLOBAL, 0);
+ /* Symbol to reference ord/name of imported
+ data symbol, used to implement auto-import. */
+ if (exp->flag_data)
+ quick_symbol (abfd, U("_nm__"), exp->internal_name, "", id6,
+ BSF_GLOBAL,0);
+ }
if (pe_dll_compat_implib)
- quick_symbol (abfd, U ("__imp_"), exp->internal_name, "",
- id5, BSF_GLOBAL, 0);
+ quick_symbol (abfd, U ("__imp_"), exp->internal_name, "", id5,
+ BSF_GLOBAL, 0);
if (! exp->flag_data)
{
bfd_set_section_size (abfd, tx, jmp_byte_count);
- td = (unsigned char *) xmalloc (jmp_byte_count);
+ td = xmalloc (jmp_byte_count);
tx->contents = td;
memcpy (td, jmp_bytes, jmp_byte_count);
@@ -1851,14 +1841,14 @@ make_one (exp, parent)
}
bfd_set_section_size (abfd, id7, 4);
- d7 = (unsigned char *) xmalloc (4);
+ d7 = xmalloc (4);
id7->contents = d7;
memset (d7, 0, 4);
- quick_reloc (abfd, 0, BFD_RELOC_RVA, 6);
+ quick_reloc (abfd, 0, BFD_RELOC_RVA, 5);
save_relocs (id7);
bfd_set_section_size (abfd, id5, 4);
- d5 = (unsigned char *) xmalloc (4);
+ d5 = xmalloc (4);
id5->contents = d5;
memset (d5, 0, 4);
@@ -1875,7 +1865,7 @@ make_one (exp, parent)
}
bfd_set_section_size (abfd, id4, 4);
- d4 = (unsigned char *) xmalloc (4);
+ d4 = xmalloc (4);
id4->contents = d4;
memset (d4, 0, 4);
@@ -1902,7 +1892,7 @@ make_one (exp, parent)
if (len & 1)
len++;
bfd_set_section_size (abfd, id6, len);
- d6 = (unsigned char *) xmalloc (len);
+ d6 = xmalloc (len);
id6->contents = d6;
memset (d6, 0, len);
d6[0] = exp->hint & 0xff;
@@ -1924,9 +1914,7 @@ make_one (exp, parent)
}
static bfd *
-make_singleton_name_thunk (import, parent)
- const char *import;
- bfd *parent;
+make_singleton_name_thunk (const char *import, bfd *parent)
{
/* Name thunks go to idata$4. */
asection *id4;
@@ -1934,7 +1922,7 @@ make_singleton_name_thunk (import, parent)
char *oname;
bfd *abfd;
- oname = (char *) xmalloc (20);
+ oname = xmalloc (20);
sprintf (oname, "nmth%06d.o", tmp_seq);
tmp_seq++;
@@ -1946,13 +1934,13 @@ make_singleton_name_thunk (import, parent)
bfd_set_arch_mach (abfd, pe_details->bfd_arch, 0);
symptr = 0;
- symtab = (asymbol **) xmalloc (3 * sizeof (asymbol *));
+ symtab = xmalloc (3 * sizeof (asymbol *));
id4 = quick_section (abfd, ".idata$4", SEC_HAS_CONTENTS, 2);
quick_symbol (abfd, U ("_nm_thnk_"), import, "", id4, BSF_GLOBAL, 0);
quick_symbol (abfd, U ("_nm_"), import, "", UNDSEC, BSF_GLOBAL, 0);
bfd_set_section_size (abfd, id4, 8);
- d4 = (unsigned char *) xmalloc (4);
+ d4 = xmalloc (4);
id4->contents = d4;
memset (d4, 0, 8);
quick_reloc (abfd, 0, BFD_RELOC_RVA, 2);
@@ -1967,22 +1955,21 @@ make_singleton_name_thunk (import, parent)
}
static char *
-make_import_fixup_mark (rel)
- arelent *rel;
+make_import_fixup_mark (arelent *rel)
{
/* We convert reloc to symbol, for later reference. */
static int counter;
static char *fixup_name = NULL;
static size_t buffer_len = 0;
- struct symbol_cache_entry *sym = *rel->sym_ptr_ptr;
+ struct bfd_symbol *sym = *rel->sym_ptr_ptr;
bfd *abfd = bfd_asymbol_bfd (sym);
struct bfd_link_hash_entry *bh;
if (!fixup_name)
{
- fixup_name = (char *) xmalloc (384);
+ fixup_name = xmalloc (384);
buffer_len = 384;
}
@@ -1992,10 +1979,10 @@ make_import_fixup_mark (rel)
overflowing this buffer... */
{
free (fixup_name);
- /* New buffer size is length of symbol, plus 25, but then
- rounded up to the nearest multiple of 128. */
+ /* New buffer size is length of symbol, plus 25, but
+ then rounded up to the nearest multiple of 128. */
buffer_len = ((strlen (sym->name) + 25) + 127) & ~127;
- fixup_name = (char *) xmalloc (buffer_len);
+ fixup_name = xmalloc (buffer_len);
}
sprintf (fixup_name, "__fu%d_%s", counter++, sym->name);
@@ -2003,7 +1990,7 @@ make_import_fixup_mark (rel)
bh = NULL;
bfd_coff_link_add_one_symbol (&link_info, abfd, fixup_name, BSF_GLOBAL,
current_sec, /* sym->section, */
- rel->address, NULL, true, false, &bh);
+ rel->address, NULL, TRUE, FALSE, &bh);
if (0)
{
@@ -2025,18 +2012,17 @@ make_import_fixup_mark (rel)
.rva __fuNN_SYM (pointer to reference (address) in text) */
static bfd *
-make_import_fixup_entry (name, fixup_name, dll_symname, parent)
- const char *name;
- const char *fixup_name;
- const char *dll_symname;
- bfd *parent;
+make_import_fixup_entry (const char *name,
+ const char *fixup_name,
+ const char *dll_symname,
+ bfd *parent)
{
asection *id3;
unsigned char *d3;
char *oname;
bfd *abfd;
- oname = (char *) xmalloc (20);
+ oname = xmalloc (20);
sprintf (oname, "fu%06d.o", tmp_seq);
tmp_seq++;
@@ -2048,7 +2034,7 @@ make_import_fixup_entry (name, fixup_name, dll_symname, parent)
bfd_set_arch_mach (abfd, pe_details->bfd_arch, 0);
symptr = 0;
- symtab = (asymbol **) xmalloc (6 * sizeof (asymbol *));
+ symtab = xmalloc (6 * sizeof (asymbol *));
id3 = quick_section (abfd, ".idata$3", SEC_HAS_CONTENTS, 2);
#if 0
@@ -2059,7 +2045,7 @@ make_import_fixup_entry (name, fixup_name, dll_symname, parent)
quick_symbol (abfd, "", fixup_name, "", UNDSEC, BSF_GLOBAL, 0);
bfd_set_section_size (abfd, id3, 20);
- d3 = (unsigned char *) xmalloc (20);
+ d3 = xmalloc (20);
id3->contents = d3;
memset (d3, 0, 20);
@@ -2076,15 +2062,109 @@ make_import_fixup_entry (name, fixup_name, dll_symname, parent)
return abfd;
}
+/* .section .rdata_runtime_pseudo_reloc
+ .long addend
+ .rva __fuNN_SYM (pointer to reference (address) in text) */
+
+static bfd *
+make_runtime_pseudo_reloc (const char *name ATTRIBUTE_UNUSED,
+ const char *fixup_name,
+ int addend,
+ bfd *parent)
+{
+ asection *rt_rel;
+ unsigned char *rt_rel_d;
+ char *oname;
+ bfd *abfd;
+
+ oname = xmalloc (20);
+ sprintf (oname, "rtr%06d.o", tmp_seq);
+ tmp_seq++;
+
+ abfd = bfd_create (oname, parent);
+ bfd_find_target (pe_details->object_target, abfd);
+ bfd_make_writable (abfd);
+
+ bfd_set_format (abfd, bfd_object);
+ bfd_set_arch_mach (abfd, pe_details->bfd_arch, 0);
+
+ symptr = 0;
+ symtab = xmalloc (2 * sizeof (asymbol *));
+ rt_rel = quick_section (abfd, ".rdata_runtime_pseudo_reloc",
+ SEC_HAS_CONTENTS, 2);
+
+ quick_symbol (abfd, "", fixup_name, "", UNDSEC, BSF_GLOBAL, 0);
+
+ bfd_set_section_size (abfd, rt_rel, 8);
+ rt_rel_d = xmalloc (8);
+ rt_rel->contents = rt_rel_d;
+ memset (rt_rel_d, 0, 8);
+ bfd_put_32 (abfd, addend, rt_rel_d);
+
+ quick_reloc (abfd, 4, BFD_RELOC_RVA, 1);
+ save_relocs (rt_rel);
+
+ bfd_set_symtab (abfd, symtab, symptr);
+
+ bfd_set_section_contents (abfd, rt_rel, rt_rel_d, 0, 8);
+
+ bfd_make_readable (abfd);
+ return abfd;
+}
+
+/* .section .rdata
+ .rva __pei386_runtime_relocator */
+
+static bfd *
+pe_create_runtime_relocator_reference (bfd *parent)
+{
+ asection *extern_rt_rel;
+ unsigned char *extern_rt_rel_d;
+ char *oname;
+ bfd *abfd;
+
+ oname = xmalloc (20);
+ sprintf (oname, "ertr%06d.o", tmp_seq);
+ tmp_seq++;
+
+ abfd = bfd_create (oname, parent);
+ bfd_find_target (pe_details->object_target, abfd);
+ bfd_make_writable (abfd);
+
+ bfd_set_format (abfd, bfd_object);
+ bfd_set_arch_mach (abfd, pe_details->bfd_arch, 0);
+
+ symptr = 0;
+ symtab = xmalloc (2 * sizeof (asymbol *));
+ extern_rt_rel = quick_section (abfd, ".rdata", SEC_HAS_CONTENTS, 2);
+
+ quick_symbol (abfd, "", "__pei386_runtime_relocator", "", UNDSEC,
+ BSF_NO_FLAGS, 0);
+
+ bfd_set_section_size (abfd, extern_rt_rel, 4);
+ extern_rt_rel_d = xmalloc (4);
+ extern_rt_rel->contents = extern_rt_rel_d;
+
+ quick_reloc (abfd, 0, BFD_RELOC_RVA, 1);
+ save_relocs (extern_rt_rel);
+
+ bfd_set_symtab (abfd, symtab, symptr);
+
+ bfd_set_section_contents (abfd, extern_rt_rel, extern_rt_rel_d, 0, 4);
+
+ bfd_make_readable (abfd);
+ return abfd;
+}
+
void
-pe_create_import_fixup (rel)
- arelent *rel;
+pe_create_import_fixup (arelent *rel, asection *s, int addend)
{
char buf[300];
- struct symbol_cache_entry *sym = *rel->sym_ptr_ptr;
+ struct bfd_symbol *sym = *rel->sym_ptr_ptr;
struct bfd_link_hash_entry *name_thunk_sym;
const char *name = sym->name;
char *fixup_name = make_import_fixup_mark (rel);
+ bfd *b;
sprintf (buf, U ("_nm_thnk_%s"), name);
@@ -2096,24 +2176,48 @@ pe_create_import_fixup (rel)
add_bfd_to_link (b, b->filename, &link_info);
/* If we ever use autoimport, we have to cast text section writable. */
- config.text_read_only = false;
+ config.text_read_only = FALSE;
+ output_bfd->flags &= ~WP_TEXT;
}
- {
- extern char * pe_data_import_dll;
- char * dll_symname = pe_data_import_dll ? pe_data_import_dll : "unknown";
+ if (addend == 0 || link_info.pei386_runtime_pseudo_reloc)
+ {
+ extern char * pe_data_import_dll;
+ char * dll_symname = pe_data_import_dll ? pe_data_import_dll : "unknown";
- bfd *b = make_import_fixup_entry (name, fixup_name, dll_symname,
- output_bfd);
- add_bfd_to_link (b, b->filename, &link_info);
- }
+ b = make_import_fixup_entry (name, fixup_name, dll_symname, output_bfd);
+ add_bfd_to_link (b, b->filename, &link_info);
+ }
+
+ if (addend != 0)
+ {
+ if (link_info.pei386_runtime_pseudo_reloc)
+ {
+ if (pe_dll_extra_pe_debug)
+ printf ("creating runtime pseudo-reloc entry for %s (addend=%d)\n",
+ fixup_name, addend);
+ b = make_runtime_pseudo_reloc (name, fixup_name, addend, output_bfd);
+ add_bfd_to_link (b, b->filename, &link_info);
+
+ if (runtime_pseudo_relocs_created == 0)
+ {
+ b = pe_create_runtime_relocator_reference (output_bfd);
+ add_bfd_to_link (b, b->filename, &link_info);
+ }
+ runtime_pseudo_relocs_created++;
+ }
+ else
+ {
+ einfo (_("%C: variable '%T' can't be auto-imported. Please read the documentation for ld's --enable-auto-import for details.\n"),
+ s->owner, s, rel->address, sym->name);
+ einfo ("%X");
+ }
+ }
}
void
-pe_dll_generate_implib (def, impfilename)
- def_file *def;
- const char *impfilename;
+pe_dll_generate_implib (def_file *def, const char *impfilename)
{
int i;
bfd *ar_head;
@@ -2153,6 +2257,9 @@ pe_dll_generate_implib (def, impfilename)
char *internal = def->exports[i].internal_name;
bfd *n;
+ /* Don't add PRIVATE entries to import lib. */
+ if (pe_def_file->exports[i].flag_private)
+ continue;
def->exports[i].internal_name = def->exports[i].name;
n = make_one (def->exports + i, outarch);
n->next = head;
@@ -2185,10 +2292,7 @@ pe_dll_generate_implib (def, impfilename)
}
static void
-add_bfd_to_link (abfd, name, link_info)
- bfd *abfd;
- const char *name;
- struct bfd_link_info *link_info;
+add_bfd_to_link (bfd *abfd, const char *name, struct bfd_link_info *link_info)
{
lang_input_statement_type *fake_file;
@@ -2203,9 +2307,7 @@ add_bfd_to_link (abfd, name, link_info)
}
void
-pe_process_import_defs (output_bfd, link_info)
- bfd *output_bfd;
- struct bfd_link_info *link_info;
+pe_process_import_defs (bfd *output_bfd, struct bfd_link_info *link_info)
{
def_file_module *module;
@@ -2231,20 +2333,35 @@ pe_process_import_defs (output_bfd, link_info)
{
def_file_export exp;
struct bfd_link_hash_entry *blhe;
-
+ int lead_at = (*pe_def_file->imports[i].internal_name == '@');
/* See if we need this import. */
- char *name = (char *) xmalloc (strlen (pe_def_file->imports[i].internal_name) + 2 + 6);
- sprintf (name, "%s%s", U (""), pe_def_file->imports[i].internal_name);
+ size_t len = strlen (pe_def_file->imports[i].internal_name);
+ char *name = xmalloc (len + 2 + 6);
+
+ if (lead_at)
+ sprintf (name, "%s%s", "",
+ pe_def_file->imports[i].internal_name);
+ else
+ sprintf (name, "%s%s",U (""),
+ pe_def_file->imports[i].internal_name);
+
blhe = bfd_link_hash_lookup (link_info->hash, name,
- false, false, false);
+ FALSE, FALSE, FALSE);
+
if (!blhe || (blhe && blhe->type != bfd_link_hash_undefined))
{
- sprintf (name, "%s%s", U ("_imp__"),
- pe_def_file->imports[i].internal_name);
+ if (lead_at)
+ sprintf (name, "%s%s", U ("_imp_"),
+ pe_def_file->imports[i].internal_name);
+ else
+ sprintf (name, "%s%s", U ("_imp__"),
+ pe_def_file->imports[i].internal_name);
+
blhe = bfd_link_hash_lookup (link_info->hash, name,
- false, false, false);
+ FALSE, FALSE, FALSE);
}
free (name);
+
if (blhe && blhe->type == bfd_link_hash_undefined)
{
bfd *one;
@@ -2261,7 +2378,7 @@ pe_process_import_defs (output_bfd, link_info)
exp.hint = exp.ordinal >= 0 ? exp.ordinal : 0;
exp.flag_private = 0;
exp.flag_constant = 0;
- exp.flag_data = 0;
+ exp.flag_data = pe_def_file->imports[i].data;
exp.flag_noname = exp.name ? 0 : 1;
one = make_one (&exp, output_bfd);
add_bfd_to_link (one, one->filename, link_info);
@@ -2278,13 +2395,11 @@ pe_process_import_defs (output_bfd, link_info)
}
/* We were handed a *.DLL file. Parse it and turn it into a set of
- IMPORTS directives in the def file. Return true if the file was
- handled, false if not. */
+ IMPORTS directives in the def file. Return TRUE if the file was
+ handled, FALSE if not. */
static unsigned int
-pe_get16 (abfd, where)
- bfd *abfd;
- int where;
+pe_get16 (bfd *abfd, int where)
{
unsigned char b[2];
@@ -2294,9 +2409,7 @@ pe_get16 (abfd, where)
}
static unsigned int
-pe_get32 (abfd, where)
- bfd *abfd;
- int where;
+pe_get32 (bfd *abfd, int where)
{
unsigned char b[4];
@@ -2308,8 +2421,7 @@ pe_get32 (abfd, where)
#if 0 /* This is not currently used. */
static unsigned int
-pe_as16 (ptr)
- void *ptr;
+pe_as16 (void *ptr)
{
unsigned char *b = ptr;
@@ -2319,24 +2431,31 @@ pe_as16 (ptr)
#endif
static unsigned int
-pe_as32 (ptr)
- void *ptr;
+pe_as32 (void *ptr)
{
unsigned char *b = ptr;
return b[0] + (b[1] << 8) + (b[2] << 16) + (b[3] << 24);
}
-boolean
-pe_implied_import_dll (filename)
- const char *filename;
+bfd_boolean
+pe_implied_import_dll (const char *filename)
{
bfd *dll;
unsigned long pe_header_offset, opthdr_ofs, num_entries, i;
unsigned long export_rva, export_size, nsections, secptr, expptr;
+ unsigned long exp_funcbase;
unsigned char *expdata, *erva;
unsigned long name_rvas, ordinals, nexp, ordbase;
const char *dll_name;
+ /* Initialization with start > end guarantees that is_data
+ will not be set by mistake, and avoids compiler warning. */
+ unsigned long data_start = 1;
+ unsigned long data_end = 0;
+ unsigned long rdata_start = 1;
+ unsigned long rdata_end = 0;
+ unsigned long bss_start = 1;
+ unsigned long bss_end = 0;
/* No, I can't use bfd here. kernel32.dll puts its export table in
the middle of the .rdata section. */
@@ -2344,27 +2463,23 @@ pe_implied_import_dll (filename)
if (!dll)
{
einfo ("%Xopen %s: %s\n", filename, bfd_errmsg (bfd_get_error ()));
- return false;
+ return FALSE;
}
/* PEI dlls seem to be bfd_objects. */
if (!bfd_check_format (dll, bfd_object))
{
einfo ("%X%s: this doesn't appear to be a DLL\n", filename);
- return false;
+ return FALSE;
}
- dll_name = filename;
- for (i = 0; filename[i]; i++)
- if (filename[i] == '/' || filename[i] == '\\' || filename[i] == ':')
- dll_name = filename + i + 1;
-
+ /* Get pe_header, optional header and numbers of export entries. */
pe_header_offset = pe_get32 (dll, 0x3c);
opthdr_ofs = pe_header_offset + 4 + 20;
num_entries = pe_get32 (dll, opthdr_ofs + 92);
if (num_entries < 1) /* No exports. */
- return false;
+ return FALSE;
export_rva = pe_get32 (dll, opthdr_ofs + 96);
export_size = pe_get32 (dll, opthdr_ofs + 100);
@@ -2373,6 +2488,7 @@ pe_implied_import_dll (filename)
pe_get16 (dll, pe_header_offset + 4 + 16));
expptr = 0;
+ /* Get the rva and size of the export section. */
for (i = 0; i < nsections; i++)
{
char sname[8];
@@ -2393,7 +2509,50 @@ pe_implied_import_dll (filename)
}
}
- expdata = (unsigned char *) xmalloc (export_size);
+ /* Scan sections and store the base and size of the
+ data and bss segments in data/base_start/end. */
+ for (i = 0; i < nsections; i++)
+ {
+ unsigned long secptr1 = secptr + 40 * i;
+ unsigned long vsize = pe_get32 (dll, secptr1 + 8);
+ unsigned long vaddr = pe_get32 (dll, secptr1 + 12);
+ unsigned long flags = pe_get32 (dll, secptr1 + 36);
+ char sec_name[9];
+
+ sec_name[8] = '\0';
+ bfd_seek (dll, (file_ptr) secptr1 + 0, SEEK_SET);
+ bfd_bread (sec_name, (bfd_size_type) 8, dll);
+
+ if (strcmp(sec_name,".data") == 0)
+ {
+ data_start = vaddr;
+ data_end = vaddr + vsize;
+
+ if (pe_dll_extra_pe_debug)
+ printf ("%s %s: 0x%08lx-0x%08lx (0x%08lx)\n",
+ __FUNCTION__, sec_name, vaddr, vaddr + vsize, flags);
+ }
+ else if (strcmp(sec_name,".rdata") == 0)
+ {
+ rdata_start = vaddr;
+ rdata_end = vaddr + vsize;
+
+ if (pe_dll_extra_pe_debug)
+ printf ("%s %s: 0x%08lx-0x%08lx (0x%08lx)\n",
+ __FUNCTION__, sec_name, vaddr, vaddr + vsize, flags);
+ }
+ else if (strcmp (sec_name,".bss") == 0)
+ {
+ bss_start = vaddr;
+ bss_end = vaddr + vsize;
+
+ if (pe_dll_extra_pe_debug)
+ printf ("%s %s: 0x%08lx-0x%08lx (0x%08lx)\n",
+ __FUNCTION__, sec_name, vaddr, vaddr + vsize, flags);
+ }
+ }
+
+ expdata = xmalloc (export_size);
bfd_seek (dll, (file_ptr) expptr, SEEK_SET);
bfd_bread (expdata, (bfd_size_type) export_size, dll);
erva = expdata - export_rva;
@@ -2405,17 +2564,56 @@ pe_implied_import_dll (filename)
name_rvas = pe_as32 (expdata + 32);
ordinals = pe_as32 (expdata + 36);
ordbase = pe_as32 (expdata + 16);
+ exp_funcbase = pe_as32 (expdata + 28);
+
+ /* Use internal dll name instead of filename
+ to enable symbolic dll linking. */
+ dll_name = pe_as32 (expdata + 12) + erva;
+ /* Check to see if the dll has already been added to
+ the definition list and if so return without error.
+ This avoids multiple symbol definitions. */
+ if (def_get_module (pe_def_file, dll_name))
+ {
+ if (pe_dll_extra_pe_debug)
+ printf ("%s is already loaded\n", dll_name);
+ return TRUE;
+ }
+
+ /* Iterate through the list of symbols. */
for (i = 0; i < nexp; i++)
{
+ /* Pointer to the names vector. */
unsigned long name_rva = pe_as32 (erva + name_rvas + i * 4);
def_file_import *imp;
-
- imp = def_file_add_import (pe_def_file, erva + name_rva, dll_name,
- i, 0);
+ /* Pointer to the function address vector. */
+ unsigned long func_rva = pe_as32 (erva + exp_funcbase + i * 4);
+ int is_data = 0;
+
+ /* Skip unwanted symbols, which are
+ exported in buggy auto-import releases. */
+ if (strncmp (erva + name_rva, "_nm_", 4) != 0)
+ {
+ /* is_data is true if the address is in the data, rdata or bss
+ segment. */
+ is_data =
+ (func_rva >= data_start && func_rva < data_end)
+ || (func_rva >= rdata_start && func_rva < rdata_end)
+ || (func_rva >= bss_start && func_rva < bss_end);
+
+ imp = def_file_add_import (pe_def_file, erva + name_rva,
+ dll_name, i, 0);
+ /* Mark symbol type. */
+ imp->data = is_data;
+
+ if (pe_dll_extra_pe_debug)
+ printf ("%s dll-name: %s sym: %s addr: 0x%lx %s\n",
+ __FUNCTION__, dll_name, erva + name_rva,
+ func_rva, is_data ? "(data)" : "");
+ }
}
- return true;
+ return TRUE;
}
/* These are the main functions, called from the emulation. The first
@@ -2424,30 +2622,27 @@ pe_implied_import_dll (filename)
can put the right values in place. */
void
-pe_dll_build_sections (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info;
+pe_dll_build_sections (bfd *abfd, struct bfd_link_info *info)
{
pe_dll_id_target (bfd_get_target (abfd));
process_def_file (abfd, info);
+ if (pe_def_file->num_exports == 0 && !info->shared)
+ return;
+
generate_edata (abfd, info);
build_filler_bfd (1);
}
void
-pe_exe_build_sections (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info ATTRIBUTE_UNUSED;
+pe_exe_build_sections (bfd *abfd, struct bfd_link_info *info ATTRIBUTE_UNUSED)
{
pe_dll_id_target (bfd_get_target (abfd));
build_filler_bfd (0);
}
void
-pe_dll_fill_sections (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info;
+pe_dll_fill_sections (bfd *abfd, struct bfd_link_info *info)
{
pe_dll_id_target (bfd_get_target (abfd));
image_base = pe_data (abfd)->pe_opthdr.ImageBase;
@@ -2459,29 +2654,26 @@ pe_dll_fill_sections (abfd, info)
/* Resize the sections. */
lang_size_sections (stat_ptr->head, abs_output_section,
- &stat_ptr->head, 0, (bfd_vma) 0, NULL);
+ &stat_ptr->head, 0, 0, NULL, TRUE);
/* Redo special stuff. */
ldemul_after_allocation ();
/* Do the assignments again. */
- lang_do_assignments (stat_ptr->head,
- abs_output_section,
- (fill_type *) 0, (bfd_vma) 0);
+ lang_do_assignments (stat_ptr->head, abs_output_section, NULL, 0);
}
fill_edata (abfd, info);
- pe_data (abfd)->dll = 1;
+ if (info->shared)
+ pe_data (abfd)->dll = 1;
edata_s->contents = edata_d;
reloc_s->contents = reloc_d;
}
void
-pe_exe_fill_sections (abfd, info)
- bfd *abfd;
- struct bfd_link_info *info;
+pe_exe_fill_sections (bfd *abfd, struct bfd_link_info *info)
{
pe_dll_id_target (bfd_get_target (abfd));
image_base = pe_data (abfd)->pe_opthdr.ImageBase;
@@ -2493,15 +2685,13 @@ pe_exe_fill_sections (abfd, info)
/* Resize the sections. */
lang_size_sections (stat_ptr->head, abs_output_section,
- &stat_ptr->head, 0, (bfd_vma) 0, NULL);
+ &stat_ptr->head, 0, 0, NULL, TRUE);
/* Redo special stuff. */
ldemul_after_allocation ();
/* Do the assignments again. */
- lang_do_assignments (stat_ptr->head,
- abs_output_section,
- (fill_type *) 0, (bfd_vma) 0);
+ lang_do_assignments (stat_ptr->head, abs_output_section, NULL, 0);
}
reloc_s->contents = reloc_d;
}
diff --git a/contrib/binutils/ld/pe-dll.h b/contrib/binutils/ld/pe-dll.h
index b8fcdb9..029bf33 100644
--- a/contrib/binutils/ld/pe-dll.h
+++ b/contrib/binutils/ld/pe-dll.h
@@ -1,5 +1,5 @@
/* pe-dll.h: Header file for routines used to build Windows DLLs.
- Copyright 1999, 2000, 2002 Free Software Foundation, Inc.
+ Copyright 1999, 2000, 2002, 2003 Free Software Foundation, Inc.
This file is part of GLD, the Gnu Linker.
@@ -35,20 +35,28 @@ extern int pe_dll_warn_dup_exports;
extern int pe_dll_compat_implib;
extern int pe_dll_extra_pe_debug;
-extern void pe_dll_id_target PARAMS ((const char *));
-extern void pe_dll_add_excludes PARAMS ((const char *, const int));
-extern void pe_dll_generate_def_file PARAMS ((const char *));
-extern void pe_dll_generate_implib PARAMS ((def_file *, const char *));
-extern void pe_process_import_defs PARAMS ((bfd *, struct bfd_link_info *));
-extern boolean pe_implied_import_dll PARAMS ((const char *));
-extern void pe_dll_build_sections PARAMS ((bfd *, struct bfd_link_info *));
-extern void pe_exe_build_sections PARAMS ((bfd *, struct bfd_link_info *));
-extern void pe_dll_fill_sections PARAMS ((bfd *, struct bfd_link_info *));
-extern void pe_exe_fill_sections PARAMS ((bfd *, struct bfd_link_info *));
-
-extern void pe_walk_relocs_of_symbol PARAMS ((struct bfd_link_info * info,
- const char *name,
- int (*cb) (arelent *, asection *)));
-
-extern void pe_create_import_fixup PARAMS ((arelent * rel));
+extern void pe_dll_id_target
+ (const char *);
+extern void pe_dll_add_excludes
+ (const char *, const int);
+extern void pe_dll_generate_def_file
+ (const char *);
+extern void pe_dll_generate_implib
+ (def_file *, const char *);
+extern void pe_process_import_defs
+ (bfd *, struct bfd_link_info *);
+extern bfd_boolean pe_implied_import_dll
+ (const char *);
+extern void pe_dll_build_sections
+ (bfd *, struct bfd_link_info *);
+extern void pe_exe_build_sections
+ (bfd *, struct bfd_link_info *);
+extern void pe_dll_fill_sections
+ (bfd *, struct bfd_link_info *);
+extern void pe_exe_fill_sections
+ (bfd *, struct bfd_link_info *);
+extern void pe_walk_relocs_of_symbol
+ (struct bfd_link_info *, const char *, int (*) (arelent *, asection *));
+extern void pe_create_import_fixup
+ (arelent * rel, asection *, int);
#endif /* PE_DLL_H */
diff --git a/contrib/binutils/ld/scripttempl/armcoff.sc b/contrib/binutils/ld/scripttempl/armcoff.sc
index c61f734..781301c 100644
--- a/contrib/binutils/ld/scripttempl/armcoff.sc
+++ b/contrib/binutils/ld/scripttempl/armcoff.sc
@@ -44,7 +44,7 @@ SECTIONS
${RELOCATING+ etext = .;}
${RELOCATING+ _etext = .;}
}
- .data ${RELOCATING+${DATA_ADDR-0x40000 + (. & 0xfffc0fff)}} : {
+ .data ${RELOCATING+${DATA_ADDR-0x40000 + (ALIGN(0x8) & 0xfffc0fff)}} : {
${RELOCATING+ __data_start__ = . ;}
*(.data*)
@@ -60,7 +60,7 @@ SECTIONS
}
${CONSTRUCTING+${RELOCATING-$CTOR}}
${CONSTRUCTING+${RELOCATING-$DTOR}}
- .bss ${RELOCATING+ SIZEOF(.data) + ADDR(.data)} :
+ .bss ${RELOCATING+ ALIGN(0x8)} :
{
${RELOCATING+ __bss_start__ = . ;}
*(.bss)
diff --git a/contrib/binutils/ld/scripttempl/elf.sc b/contrib/binutils/ld/scripttempl/elf.sc
index 6bbe1b8..187a289 100644
--- a/contrib/binutils/ld/scripttempl/elf.sc
+++ b/contrib/binutils/ld/scripttempl/elf.sc
@@ -72,18 +72,20 @@ if [ -z "$MACHINE" ]; then OUTPUT_ARCH=${ARCH}; else OUTPUT_ARCH=${ARCH}:${MACHI
test -z "${ELFSIZE}" && ELFSIZE=32
test -z "${ALIGNMENT}" && ALIGNMENT="${ELFSIZE} / 8"
test "$LD_FLAG" = "N" && DATA_ADDR=.
-test -n "$CREATE_SHLIB" && test -n "$SHLIB_DATA_ADDR" && COMMONPAGESIZE=""
-test -z "$CREATE_SHLIB" && test -n "$DATA_ADDR" && COMMONPAGESIZE=""
-DATA_SEGMENT_ALIGN="ALIGN(${MAXPAGESIZE}) + (. & (${MAXPAGESIZE} - 1))"
+test -n "$CREATE_SHLIB$CREATE_PIE" && test -n "$SHLIB_DATA_ADDR" && COMMONPAGESIZE=""
+test -z "$CREATE_SHLIB$CREATE_PIE" && test -n "$DATA_ADDR" && COMMONPAGESIZE=""
+DATA_SEGMENT_ALIGN="ALIGN(${SEGMENT_SIZE}) + (. & (${MAXPAGESIZE} - 1))"
DATA_SEGMENT_END=""
if test -n "${COMMONPAGESIZE}"; then
- DATA_SEGMENT_ALIGN="DATA_SEGMENT_ALIGN(${MAXPAGESIZE}, ${COMMONPAGESIZE})"
+ DATA_SEGMENT_ALIGN="ALIGN (${SEGMENT_SIZE}) - ((${MAXPAGESIZE} - .) & (${MAXPAGESIZE} - 1)); . = DATA_SEGMENT_ALIGN (${MAXPAGESIZE}, ${COMMONPAGESIZE})"
DATA_SEGMENT_END=". = DATA_SEGMENT_END (.);"
fi
INTERP=".interp ${RELOCATING-0} : { *(.interp) }"
PLT=".plt ${RELOCATING-0} : { *(.plt) }"
+test -z "$GOT" && GOT=".got ${RELOCATING-0} : { *(.got.plt) *(.got) }"
DYNAMIC=".dynamic ${RELOCATING-0} : { *(.dynamic) }"
RODATA=".rodata ${RELOCATING-0} : { *(.rodata${RELOCATING+ .rodata.* .gnu.linkonce.r.*}) }"
+STACKNOTE="/DISCARD/ : { *(.note.GNU-stack) }"
if test -z "${NO_SMALL_DATA}"; then
SBSS=".sbss ${RELOCATING-0} :
{
@@ -127,14 +129,14 @@ CTOR=".ctors ${CONSTRUCTING-0} :
doesn't matter which directory crtbegin.o
is in. */
- KEEP (*crtbegin.o(.ctors))
+ KEEP (*crtbegin*.o(.ctors))
/* We don't want to include the .ctor section from
from the crtend.o file until after the sorted ctors.
The .ctor section from the crtend file contains the
end of ctors marker and it must be last */
- KEEP (*(EXCLUDE_FILE (*crtend.o $OTHER_EXCLUDE_FILES) .ctors))
+ KEEP (*(EXCLUDE_FILE (*crtend*.o $OTHER_EXCLUDE_FILES) .ctors))
KEEP (*(SORT(.ctors.*)))
KEEP (*(.ctors))
${CONSTRUCTING+${CTOR_END}}
@@ -142,8 +144,8 @@ CTOR=".ctors ${CONSTRUCTING-0} :
DTOR=".dtors ${CONSTRUCTING-0} :
{
${CONSTRUCTING+${DTOR_START}}
- KEEP (*crtbegin.o(.dtors))
- KEEP (*(EXCLUDE_FILE (*crtend.o $OTHER_EXCLUDE_FILES) .dtors))
+ KEEP (*crtbegin*.o(.dtors))
+ KEEP (*(EXCLUDE_FILE (*crtend*.o $OTHER_EXCLUDE_FILES) .dtors))
KEEP (*(SORT(.dtors.*)))
KEEP (*(.dtors))
${CONSTRUCTING+${DTOR_END}}
@@ -180,8 +182,9 @@ ${RELOCATING- /* For some reason, the Solaris linker makes bad executables
SECTIONS
{
/* Read-only sections, merged into text segment: */
- ${CREATE_SHLIB-${RELOCATING+. = ${TEXT_BASE_ADDRESS};}}
+ ${CREATE_SHLIB-${CREATE_PIE-${RELOCATING+PROVIDE (__executable_start = ${TEXT_START_ADDR}); . = ${TEXT_BASE_ADDRESS};}}}
${CREATE_SHLIB+${RELOCATING+. = ${SHLIB_TEXT_START_ADDR:-0} + SIZEOF_HEADERS;}}
+ ${CREATE_PIE+${RELOCATING+. = ${SHLIB_TEXT_START_ADDR:-0} + SIZEOF_HEADERS;}}
${CREATE_SHLIB-${INTERP}}
${INITIAL_READONLY_SECTIONS}
${TEXT_DYNAMIC+${DYNAMIC}}
@@ -283,8 +286,9 @@ cat <<EOF
/* Adjust the address for the data segment. We want to adjust up to
the same address within the page on the next page up. */
- ${CREATE_SHLIB-${RELOCATING+. = ${DATA_ADDR-${DATA_SEGMENT_ALIGN}};}}
+ ${CREATE_SHLIB-${CREATE_PIE-${RELOCATING+. = ${DATA_ADDR-${DATA_SEGMENT_ALIGN}};}}}
${CREATE_SHLIB+${RELOCATING+. = ${SHLIB_DATA_ADDR-${DATA_SEGMENT_ALIGN}};}}
+ ${CREATE_PIE+${RELOCATING+. = ${SHLIB_DATA_ADDR-${DATA_SEGMENT_ALIGN}};}}
/* Ensure the __preinit_array_start label is properly aligned. We
could instead move the label definition inside the section, but
@@ -322,7 +326,7 @@ cat <<EOF
.jcr ${RELOCATING-0} : { KEEP (*(.jcr)) }
${DATA_PLT+${PLT}}
${RELOCATING+${OTHER_GOT_SYMBOLS}}
- .got ${RELOCATING-0} : { *(.got.plt) *(.got) }
+ ${GOT}
${OTHER_GOT_SECTIONS}
${CREATE_SHLIB+${SDATA2}}
${CREATE_SHLIB+${SBSS2}}
@@ -395,5 +399,6 @@ cat <<EOF
${STACK_ADDR+${STACK}}
${OTHER_SECTIONS}
${RELOCATING+${OTHER_END_SYMBOLS}}
+ ${RELOCATING+${STACKNOTE}}
}
EOF
diff --git a/contrib/binutils/ld/scripttempl/pe.sc b/contrib/binutils/ld/scripttempl/pe.sc
index a22611c..da09eb4 100644
--- a/contrib/binutils/ld/scripttempl/pe.sc
+++ b/contrib/binutils/ld/scripttempl/pe.sc
@@ -25,6 +25,10 @@ if test "${RELOCATING}"; then
SORT(*)(.idata$6)
SORT(*)(.idata$7)'
R_CRT='*(SORT(.CRT$*))'
+ R_TLS='
+ *(.tls)
+ *(.tls$)
+ *(SORT(.tls$*))'
R_RSRC='*(SORT(.rsrc$*))'
else
R_TEXT=
@@ -60,7 +64,7 @@ SECTIONS
${RELOCATING+ *(.fini)}
/* ??? Why is .gcc_exc here? */
${RELOCATING+ *(.gcc_exc)}
- ${RELOCATING+ etext = .;}
+ ${RELOCATING+PROVIDE (etext = .);}
*(.gcc_except_table)
}
@@ -129,11 +133,16 @@ SECTIONS
${R_CRT}
}
+ .tls ${RELOCATING+BLOCK(__section_alignment__)} :
+ {
+ ${R_TLS}
+ }
+
.endjunk ${RELOCATING+BLOCK(__section_alignment__)} :
{
/* end is deprecated, don't use it */
- ${RELOCATING+ end = .;}
- ${RELOCATING+ _end = .;}
+ ${RELOCATING+PROVIDE (end = .);}
+ ${RELOCATING+PROVIDE ( _end = .);}
${RELOCATING+ __end__ = .;}
}
diff --git a/contrib/binutils/ld/sysdep.h b/contrib/binutils/ld/sysdep.h
index 24688a6..f164e74 100644
--- a/contrib/binutils/ld/sysdep.h
+++ b/contrib/binutils/ld/sysdep.h
@@ -1,5 +1,6 @@
/* sysdep.h -- handle host dependencies for the GNU linker
- Copyright 1995, 1996, 1997, 1999 Free Software Foundation, Inc.
+ Copyright 1995, 1996, 1997, 1999, 2002, 2003
+ Free Software Foundation, Inc.
This file is part of GLD, the Gnu Linker.
@@ -21,8 +22,6 @@
#ifndef LD_SYSDEP_H
#define LD_SYSDEP_H
-#include "ansidecl.h"
-
#include "config.h"
#include <stdio.h>
@@ -48,6 +47,30 @@ extern char *strrchr ();
#include <unistd.h>
#endif
+/* for PATH_MAX */
+#ifdef HAVE_LIMITS_H
+#include <limits.h>
+#endif
+/* for MAXPATHLEN */
+#ifdef HAVE_SYS_PARAM_H
+#include <sys/param.h>
+#endif
+#ifdef PATH_MAX
+# define LD_PATHMAX PATH_MAX
+#else
+# ifdef MAXPATHLEN
+# define LD_PATHMAX MAXPATHLEN
+# else
+# define LD_PATHMAX 1024
+# endif
+#endif
+
+#ifdef HAVE_REALPATH
+# define REALPATH(a,b) realpath (a, b)
+#else
+# define REALPATH(a,b) NULL
+#endif
+
#ifdef USE_BINARY_FOPEN
#include "fopen-bin.h"
#else
diff --git a/contrib/binutils/libiberty/ChangeLog b/contrib/binutils/libiberty/ChangeLog
index a82516e..08b7d5b 100644
--- a/contrib/binutils/libiberty/ChangeLog
+++ b/contrib/binutils/libiberty/ChangeLog
@@ -1,9 +1,958 @@
-2002-10-28 Daniel Jacobowitz <drow@mvista.com>
+2004-02-16 Matt Kraai <kraai@alumni.cmu.edu>
+
+ * regex.c: Include <ansidecl.h>.
+ (regcomp): Cast i to int.
+ (regerror): Add ATTRIBUTE_UNUSED to parameter preg.
+
+2004-01-25 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * configure.ac: Add m4_pattern_allow(LIBOBJS).
+ * configure: Regenerate.
+
+2004-01-22 DJ Delorie <dj@redhat.com>
+
+ * Makefile.in: Convert to ./ throughout. Rebuild dependencies
+ with explicit build rules.
+ (VPATH): Remove.
+ (.c.o): Poison.
+ * configure.ac (pexecute, LIBOBJS): Add ./ .
+ * maint-tool: Build dependencies with explicit rules.
+
+2004-01-15 Kazu Hirata <kazu@cs.umass.edu>
+
+ * strdup.c (strdup): Constify the argument.
+
+2004-01-14 Loren J. Rittle <ljrittle@acm.org>
+
+ * Makefile.in (distclean): Remove config.cache.
+
+2004-01-13 Daniel Jacobowitz <drow@mvista.com>
+
+ * cp-demangle.c (d_make_comp): DEMANGLE_COMPONENT_CONSTRUCTION_VTABLE
+ takes two parameters.
+ * cp-demint.c (cplus_demangle_fill_component): Likewise.
+
+2004-01-12 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * cp-demangle.c: Include "cp-demangle.h". If IN_GLIBCPP_V3 is
+ defined, rename some functions which are to become static via
+ #define.
+ (CP_STATIC_IF_GLIBCPP_V3): Define.
+ (struct d_operator_info): Move definition to cp-demangle.h, and
+ rename to demangle_operator_info. Change all uses.
+ (enum d_builtin_type_print): Move definition to cp-demangle.h.
+ (struct d_builtin_type_info): Move definition to cp-demangle.h,
+ and rename to demangle_builtin_type_info. Change all uses.
+ (enum d_comp_type): Move definition to include/demangle.h, and
+ rename to demangle_component_type, and change all enums to start
+ with DEMANGLE_COMPONENT_ instead of D_. Change all uses.
+ (struct d_comp): Move definition to include/demangle.h, and rename
+ to demangle_component. Change all uses.
+ (struct d_info): Move definition to cp-demangle.h.
+ (cplus_demangle_fill_name): New function.
+ (cplus_demangle_fill_extended_operator): New function.
+ (cplus_demangle_fill_ctor): New function.
+ (cplus_demangle_fill_dtor): New function.
+ (d_make_empty): Remove type parameter. Change all callers.
+ (d_make_name): Use cplus_demangle_fill_name.
+ (d_make_extended_operator): Use
+ cplus_demangle_fill_extended_operator.
+ (d_make_ctor): Use cplus_demangle_fill_ctor.
+ (d_make_dtor): Use cplus_demangle_fill_dtor.
+ (cplus_demangle_mangled_name): Rename from d_mangled_name. Make
+ non-static by default. Change all callers.
+ (cplus_demangle_operators): Rename from d_operators. Change all
+ uses. Make non-static by default. Add sentinel at end of array.
+ (d_operator_name): Adjust initialization of high for new sentinel
+ in cplus_demangle_operators.
+ (cplus_demangle_builtin_types): Rename from d_builtin_types.
+ Change all uses. Make non-static by default. Change initializer
+ to use D_BUILTIN_TYPE_COUNT instead of magic number 26.
+ (cplus_demangle_type): Rename from d_type. Make non-static by
+ default. Change all callers.
+ (cplus_demangle_init_info): Rename from d_init_info. Make
+ non-static by default. Change all callers.
+ * cp-demangle.h: New file.
+ * cp-demint.c: New file.
+ * Makefile.in: Rebuild dependencies.
+ (CFILES): Add cp-demint.c.
+ (REQUIRED_OFILES): Add cp-demint.o.
+
+2004-01-09 Kelley Cook <kcook@gcc.gnu.org>
+
+ * configure.in: Rename file to ...
+ * configure.ac: ... this.
+ * Makefile.in: Update a comment for above change.
+ * README: Likewise.
+ * config.in: Regenerate.
+
+2004-01-02 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * cp-demangle.c (d_encoding): When DMGL_PARAMS is not set, strip
+ CV-qualifiers from D_COMP_LOCAL_NAME right subtree.
+ * cplus-dem.c (demangle_arm_hp_template): Set DMGL_PARAMS when
+ demangling template parameters.
+ * testsuite/test-demangle.c (fail): New static function.
+ (main): Support new options in input file: --no-params,
+ --is-v3-ctor, and --is-v3-dtor.
+ * testsuite/demangle-expected: Add --no-params to most tests, and
+ add the correct result when parameters are not demangled. Add
+ some simple tests for V3 constructor/destructor recognition.
+
+2003-12-25 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * cp-demangle.c (is_ctor_or_dtor): Fix error in last change.
+
+2003-12-22 Daniel Jacobowitz <drow@mvista.com>
+
+ PR debug/13272
+ * Makefile.in (lbasename.o): Depend on filenames.h.
+ * lbasename.c: Include "filenames.h" instead of defining
+ its macros locally.
+
+2003-12-22 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * cp-demangle.c (CP_DYNAMIC_ARRAYS): Define if compiler supports
+ dynamic arrays.
+ (struct d_operator_info): Add len field.
+ (struct d_builtin_type_info): Add len and java_len fields.
+ (struct d_standard_sub_info): Add simple_len, full_len, and
+ set_last_name_len fields.
+ (struct d_comp): Add len field to s_string.
+ (struct d_info): Add send, did_subs, and expansion fields.
+ (d_append_string_constant): Define.
+ (d_append_string): Remove. Change all users to use
+ d_append_string_constant or d_append_buffer instead.
+ (d_make_sub): Add len parameter. Change all callers.
+ (d_name): Increase expansion when substituting std::.
+ (d_unqualified_name): Increase expansion for an operator.
+ (d_number): Don't use multiplication for negative numbers.
+ (d_identifier): Make sure there are enough characters in the
+ string for the specified length. Adjust expansion for an
+ anonymous namespace.
+ (d_operators): Initialize len field.
+ (d_special_name, d_ctor_dtor_name): Increase expansion.
+ (d_builtin_types): Initialize len and java_len fields.
+ (d_type): Increase expansion for a builtin type.
+ (d_cv_qualifiers): Increase expansion for each qualifier.
+ (d_bare_function_type): Decrease expansion when removing single
+ void parameter.
+ (d_template_param): Increment did_subs.
+ (d_expression): Increase expansion for an operator.
+ (d_expr_primary): Decrease expansion for a type we will print
+ specially.
+ (standard_subs): Initialize new fields.
+ (d_substitution): Increment did_subs when doing a normal
+ substitution. Increase expansion for a special substitution.
+ (d_print): Add estimate parameter. Change all callers.
+ (d_print_comp) [D_COMP_NAME]: Handle C++ case inline.
+ (d_print_comp) [D_COMP_BINARY]: Use length to avoid strcmp call.
+ (d_print_java_identifier): Rename from d_print_identifier. Handle
+ only Java case. Change caller.
+ (d_init_info): Change return type to void. Change all callers.
+ Initialize send, did_subs, and expansion fields. Do not
+ initialize comps and subs fields.
+ (d_demangle): Ifdef CP_DYNAMIC_ARRAYS, allocate comps and subs
+ arrays on stack. Make an estimate of the length of the demangled
+ name. Ifdef CP_DEMANGLE_DEBUG, print estimation failures.
+ (is_ctor_or_dtor): Ifdef CP_DYNAMIC_ARRAYS, allocate comps and
+ subs arrays on stack.
+
+2003-12-20 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * cp-demangle.c (d_identifier): In Java mode, skip an optional '$'
+ after the identifier.
+ * testsuite/demangle-expected: Add test case.
+
+2003-12-19 Ian Lance Taylor <ian@wasabisystems.com>
+
+ Fix for PR c++/13447:
+ * cp-demangle.c (enum d_comp_type): Add D_COMP_LOCAL_NAME.
+ (d_dump, d_make_comp): Handle D_COMP_LOCAL_NAME.
+ (is_ctor_dtor_or_conversion): Handle D_COMP_LOCAL_NAME like
+ D_COMP_QUAL_NAME.
+ (is_ctor_or_dtor): Likewise.
+ (d_local_name): Use D_COMP_LOCAL_NAME rather than
+ D_COMP_QUAL_NAME.
+ (d_print_comp) [D_COMP_LOCAL_NAME]: New.
+ (d_prinT_comp) [D_COMP_TYPED_NAME]: If the left tree is
+ D_COMP_LOCAL_NAME, pull any qualifiers off its right subtree.
+ (d_print_mod_list): Handle D_COMP_LOCAL_NAME.
+ * testsuite/demangle-expected: Add two test cases.
+
+ * cp-demangle.c (d_print_function_type): Clear the global modifier
+ list when printing the modifiers, not just when printing the
+ function parameters.
+ * testsuite/demangle-expected: Add two test cases.
+
+2003-12-15 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * cp-demangle.c (d_print_function_type): Print the function
+ parameters with no modifiers.
+ * testsuite/demangle-expected: Add test case.
+
+ * cp-demangle.c (d_demangle): If DMGL_PARAMS is not set, don't
+ expect that we've read the entire string.
+ (is_ctor_or_dtor): Don't expect that we've read the entire
+ string--reverse patch of 2003-11-29.
+
+2003-12-15 Brendan Kehoe <brendan@zen.org>
+
+ * libiberty/Makefile.in (floatformat.o): Add dependency on
+ config.h to accompany change of 2003-12-03.
+
+2003-12-15 Ian Lance Taylor <ian@wasabisystems.com>
+
+ Fix handling of constructor/destructor of standard substitution:
+ * cp-demangle.c (struct d_standard_sub_info): Define.
+ (d_substitution): Add prefix argument. Change all callers.
+ Rework handling of standard substitutions to print full name when
+ qualifying a constructor/destructor, or when DMGL_VERBOSE is set.
+ * testsuite/demangle-expected: Add test case.
+
+ Fix handling of negative literal constants:
+ * cp-demangle.c (enum d_comp_type): Add D_COMP_LITERAL_NEG.
+ (d_dump, d_make_comp): Handle D_COMP_LITERAL_NEG.
+ (d_expr_primary): Use D_COMP_LITERAL_NEG for a negative number.
+ (d_print_comp): Handle D_COMP_LITERAL_NEG.
+ * testsuite/demangle-expected: Add test case.
+
+2003-12-04 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * cp-demangle.c (IS_UPPER, IS_LOWER): Define.
+ (d_last_char): Define new macro.
+ (d_make_name): Reject an empty name.
+ (d_prefix, d_unqualified_name, d_type): Use new IS_* macros.
+ (d_substitution, d_print_identifier): Likewise.
+ (d_print_comp) [D_COMP_OPERATOR]: Likewise.
+ (d_print_comp) [D_COMP_TEMPLATE]: Use new d_last_char macro.
+ (d_print_mod) Use new d_last_char macro.
+ (d_print_cast): Use new d_last_char macro.
+ (is_ctor_or_dtor): Don't leak memory.
+
+ Fix handling of member function modifiers:
+ * cp-demangle.c (enum d_comp_type): Add D_COMP_RESTRICT_THIS,
+ D_COMP_VOLATILE_THIS, and D_COMP_CONST_THIS.
+ (d_dump): Dump new d_comp_type values.
+ (d_make_comp): Accept new d_comp_type values.
+ (has_return_type): Only accept _THIS variants of qualifiers.
+ (d_encoding): Without DMGL_PARAMS, only remove _THIS variants of
+ qualifiers.
+ (d_cv_qualifiers): Add member_fn parameter. Change all callers.
+ (d_print_comp) [D_COMP_TYPED_NAME]: Rather than removing
+ qualifiers and printing them at the end, add _THIS qualifiers to
+ the modifier list.
+ (d_print_comp) [D_COMP_*_THIS]: New cases.
+ (d_print_comp) [D_COMP_PTRMEM_TYPE]: Remove special handling of
+ qualifiers.
+ (d_print_mod_list): Add suffix parameter. Change all callers.
+ Keep walking the list even if the current modifier has been
+ printed.
+ (d_print_mod): Handle new _THIS qualifiers.
+ (d_print_function_type): Handle new _THIS qualifiers when deciding
+ whether to print a parenthesis. Put a space before the
+ parenthesis in some cases. Call d_print_mod_list again at the
+ end, passing suffix as 1.
+ (is_ctor_or_dtor): Look for new _THIS qualifiers.
+ * testsuite/demangle-expected: Add test case.
+
+ Fix for PR gcc/13304:
+ * cp-demangle.c (d_print_comp) [D_COMP_TEMPLATE]: If the character
+ before the '<' is itself a '<', insert a space.
+ (d_print_cast): Likewise.
+ * testsuite/demangle-expected: Add test case.
+
+ Fix for PR gcc/13244:
+ * cp-demangle.c (d_print_comp) [D_COMP_BINARY]: Wrap an expression
+ which uses the '>' operator in an extra layer of parens.
+ * testsuite/demangle-expected: Add test case.
+
+2003-12-03 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * floatformat.c: Include "config.h" and <string.h> if available.
+ (INFINITY, NAN): Define if not defined by <math.h>.
+ (floatformat_to_double): Handle NaN, infinity, and denormalized
+ numbers.
+ (floatformat_from_double): Likewise.
+ (ieee_test): In debugging code, use little endian rather than big
+ endian. Correct tests to handle NaN and to check correct sign of
+ zero. Omit m68k extended test.
+ (main): Add more debugging cases.
+
+2003-11-29 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * cp-demangle.c (d_demangle): Only return success if we consumed
+ the entire demangled string.
+ (is_ctor_or_dtor): Likewise.
+
+ * testsuite/demangle-expected: Revert one part of 2003-06-26 patch
+ to restore expected result of EDG test case to original expected
+ result.
+
+2003-11-26 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * cp-demangle.c (struct d_print_mod): Add templates field.
+ (d_make_builtin_type): Check for NULL type.
+ (d_make_extended_operator): Check for NULL name.
+ (d_make_ctor, d_make_dtor): Likewise.
+ (d_mangled_name): Add top_level parameter. Change all callers.
+ (d_encoding): If DMGL_PARAMS is not set, strip off initial
+ CV-qualifiers.
+ (d_type): Check some return values we rely on.
+ (d_bare_function_type, d_array_type): Likewise.
+ (d_pointer_to_member_type, d_template_args): Likewise.
+ (d_add_substitution): Fail if argument is NULL.
+ (d_print_resize): Check whether buf is NULL.
+ (d_print_comp): Save current templates list with each modifier.
+ Don't pass the modifier list down when printing a template.
+ (d_print_cast): Don't pass the modifier list down when printing a
+ template.
+ (d_print_mod_list): Temporarily set templates list while printing
+ a modifier.
+ (d_print_mod): Check that buf is not NULL before using it.
+ (d_print_function_type): Print parens if there is no modifier.
+ (d_init_info): Permit as many substitutions as there are
+ characters in the mangled name.
+ * testsuite/demangle-expected: Add two new test cases.
+
+2003-11-25 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * cp-demangle.c (java_demangle_v3): Pass DMGL_PARAMS to
+ d_demangle.
+
+2003-11-22 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * cp-demangle.c (d_encoding): Add top_level parameter. Change all
+ callers.
+ (print_usage): Display new -p option.
+ (long_options): Add --no-params.
+ (main): Accept and handle -p.
+
+2003-11-21 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * cp-demangle.c (has_return_type): Skip qualifiers when checking
+ whether we have a template.
+ * testsuite/demangle-expected: Add four new tests.
+
+2003-11-20 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * testsuite/demangle-expected: Minor changes to match output of
+ new demangler: adjust whitespace in four tests, and change order
+ of qualifiers in one test.
+
+ * cp-demangle.c: Complete rewrite.
+
+2003-11-19 Mark Mitchell <mark@codesourcery.com>
+
+ * cp-demangle.c (demangle_type): Correct thinko in substitution
+ processing.
+
+2003-11-18 Ian Lance Taylor <ian@wasabisystems.com>
+
+ * cp-demangle.c (demangle_operator_name): Remove space before
+ "sizeof".
+ (demangle_type_ptr): Put qualifiers in the right place. Handle
+ qualifiers in pointer to member specially.
+ (demangle_type): Handle qualifiers for pointer or reference
+ specially. Handle function type.
+ (demangle_local_name): Save and restore caret around demangling of
+ initial encoding.
+
+ * testsuite/test-demangle.c (main): Don't pass DMGL_VERBOSE to
+ cplus_demangle.
+
+ * testsuite/Makefile.in (test-demangle): Depend upon libiberty.a.
+
+2003-10-31 Andreas Jaeger <aj@suse.de>
+
+ * floatformat.c (floatformat_always_valid): Add unused attribute.
+
+2003-10-30 Josef Zlomek <zlomekj@suse.cz>
+
+ Jan Hubicka <jh@suse.cz>
+ * vasprintf.c (int_vasprintf): Pass va_list by value.
+ Use va_copy for copying va_list.
+ (vasprintf): Pass va_list by value.
+
+2003-10-30 Josef Zlomek <zlomekj@suse.cz>
+
+ * hashtab.c (htab_find_slot_with_hash): Decrease n_deleted
+ instead of increasing n_elements when inserting to deleted slot.
+
+2003-10-20 J. Brobecker <brobecker@gnat.com>
+
+ * cplus-dem.c (demangle_template): Register a new Btype only
+ when needed.
+ * testsuite/demangle-expected: Add a new test.
+
+2003-10-16 H.J. Lu <hongjiu.lu@intel.com>
+
+ * testsuite/demangle-expected: Update the expected output of
+ _GLOBAL__I__Z2fnv.
+
+2003-10-02 Daniel Jacobowitz <drow@mvista.com>
+
+ * strerror.c: Revert last change. Declare static sys_nerr
+ and sys_errlist using different names.
+
+2003-10-01 Daniel Jacobowitz <drow@mvista.com>
+
+ * strerror.c: Don't provide or reference sys_errlist if
+ strerror is available.
+
+2003-10-01 H.J. Lu <hongjiu.lu@intel.com>
+
+ * configure.in: Check if $MAKEINFO is missing.
+ * configure: Regenerated.
+
+2003-09-24 Daniel Jacobowitz <drow@mvista.com>
+
+ * configure.in: Use AC_PROG_CPP_WERROR.
+ * configure: Regenerated.
+
+2003-09-22 Andrew Cagney <cagney@redhat.com>
+
+ * floatformat.c (floatformat_i387_ext_is_valid): New function.
+ (floatformat_always_valid): New function.
+ (floatformat_i387_ext): Initialize new "is_valid" field to
+ "floatformat_i387_ext_is_valid".
+ (floatformat_ieee_single_little): Initialize "is_valid" field to
+ floatformat_always_valid.
+ (floatformat_ieee_double_big): Ditto.
+ (floatformat_ieee_double_little): Ditto.
+ (floatformat_ieee_double_little): Ditto.
+ (floatformat_ieee_double_littlebyte_bigword): Ditto.
+ (floatformat_i960_ext): Ditto.
+ (floatformat_m88110_ext): Ditto.
+ (floatformat_m88110_harris_ext): Ditto.
+ (floatformat_arm_ext_big): Ditto.
+ (floatformat_arm_ext_littlebyte_bigword): Ditto.
+ (floatformat_ia64_spill_big): Ditto.
+ (floatformat_ia64_spill_little): Ditto.
+ (floatformat_ia64_quad_big): Ditto.
+ (floatformat_ia64_quad_little): Ditto.
+ (floatformat_ia64_quad_little): Ditto.
+ (floatformat_is_valid): Call "is_valid".
+
+2003-09-15 Andrew Cagney <cagney@redhat.com>
+
+ * floatformat.c (get_field): Make "data" constant.
+ (floatformat_is_valid, floatformat_to_double): Make "from"
+ constant, fix casts.
+ (floatformat_from_double): Make "from" constant.
+
+2003-09-15 Daniel Jacobowitz <drow@mvista.com>
+
+ * floatformat.c (floatformat_is_valid): New function.
+ (get_field, put_field): Correct comments.
+
+2003-09-06 Josef Zlomek <zlomekj@suse.cz>
+
+ * fibheap.c (fibheap_replace_key_data): Change type of OKEY to
+ FIBHEAPKEY_T.
+
+2003-09-02 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
+
+ PR bootstrap/12100
+ * aclocal.m4 (AC_LANG_FUNC_LINK_TRY): Define.
+ * configure: Rebuilt.
+
+2003-08-27 Daniel Jacobowitz <drow@mvista.com>
+
+ * aclocal.m4: Include acx.m4 and no-executables.m4.
+ (libiberty_AC_FUNC_STRNCMP): Use AC_LIBOBJ.
+ (LIB_AC_PROG_CC): Remove.
+ * configure.in: Update AC_PREREQ to 2.57. Use GCC_NO_EXECUTABLES.
+ Use AC_PROG_CC and set ac_libiberty_warn_cflags instead of using
+ LIB_AC_PROG_CC. Use AC_LIBOBJ. Call AC_ISC_POSIX later, only if
+ performing link tests.
+ * configure: Regenerated.
+
+2003-08-12 Nathanael Nerode <neroden@gcc.gnu.org>
+
+ * cp-demangle.c: Clarify what package(s) this is part of.
+
+2003-07-05 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * pex-win32.c (pexecute): Mark parameters this_pname and
+ temp_base as unused. Remove unused variables retries,
+ sleep_interval. Initialize org_stdin, org_stdout.
+ (pwait): Mark parameter flags as unused.
+
+2003-07-02 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * pex-win32.c (fix_argv): Ensure that the executable pathname
+ uses Win32 backslashes.
+ (pexecute): Cast away constness when assigning *errmsg_arg.
+
+2003-06-26 H.J. Lu <hongjiu.lu@intel.com>
+
+ * testsuite/demangle-expected: Add more GNU V3 testcases.
+
+2003-06-22 Zack Weinberg <zack@codesourcery.com>
+
+ * safe-ctype.c: Use HOST_CHARSET_ASCII and HOST_CHARSET_EBCDIC,
+ not HC_ASCII and HC_EBCDIC.
+ Add documentation in form expected by gather-docs.
+ * hex.c: Use HOST_CHARSET, not hand-coded check of character set.
+ * Makefile.in, functions.texi: Regenerate.
+
+2003-06-21 Zack Weinberg <zack@codesourcery.com>
+
+ * safe-ctype.c: Separate out EOF==-1 check. Use HOST_CHARSET
+ for charset determination.
+
+2003-06-19 Dara Hazeghi <dhazeghi@yahoo.com>
+
+ * configure.in: Add check for malloc.h needed by
+ m68k for function free().
+ * configure: Regenerated.
+ * config.in: Add HAVE_MALLOC_H.
+ * hashtab.c: include malloc.h were available for
+ free().
+
+2003-06-09 Albert Chin-A-Young <china@thewrittenword.com>
+
+ PR bootstrap/10974
+ * physmem.c: Update comment.
+ * configure.in: Modify test for _system_configuration for older
+ AIX systems.
+
+ * config.in, configure: Regenerated.
+
+2003-06-05 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
+
+ PR other/10810
+ * test-demangle.c (getline): Fix fence-post error.
+
+2003-06-03 Nick Clifton <nickc@redhat.com>
+
+ * asprintf.c: Change comment to note that -1 is returned upon
+ error.
+ * vasprintf.c: Likewise.
+ (vasprintf): Return -1 upon error.
+ * functions.texi: Document changes to asprintf and vasprintf.
+
+2003-05-19 Kelley Cook <kelleycook@wideopenwest.com>
+
+ * config.table: Accept i[345867]86 variant.
+
+2003-05-15 Jim Blandy <jimb@redhat.com>
+
+ * hex.c (_hex_value): Make this unsigned.
+ (hex_value): Update documentation for new return type. hex_value
+ now expands to an unsigned int expression, to avoid unexpected
+ sign extension when we store it in a bfd_vma, which is larger than
+ int on some platforms.
+ * functions.texi: Regenerated.
+
+2003-05-07 Josef Zlomek <zlomekj@suse.cz>
+
+ * splay-tree.c (splay_tree_predecessor): Fix comment.
+ (splay_tree_successor): Fix comment.
+
+2003-05-07 Jason Merrill <jason@redhat.com>
+
+ * hashtab.c (iterative_hash): New fn.
+ * configure.in: Add AC_C_BIGENDIAN_CROSS.
+ * aclocal.m4: Include accross.m4.
+ * configure, config.in: Regenerate.
+
+2003-05-04 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * configure.in (AC_CHECK_FUNCS): Don't make multiple calls.
+ * configure: Regenerate.
+
+2003-05-03 Carlo Wood <carlo@alinoe.com>
+
+ * cp-demangle.c: Fix typo in "char_traints" string-literal.
+
+2003-04-22 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * vsnprintf.c (vsnprintf): Don't pad string with extra nulls.
+ (main): Test that we don't write too much data.
+
+2003-04-16 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * configure.in (funcs, AC_CHECK_FUNCS): Add snprintf and
+ vsnprintf.
+ * snprintf.c, vsnprintf.c: New files.
+ * Makefile.in (CFILES): Add snprintf.c and vsnprintf.c.
+ (CONFIGURED_OFILES): Add snprintf.o and vsnprintf.o.
+ Regenerate dependencies.
+
+ * functions.texi, configure, config.in: Regenerated.
+
+2003-04-15 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * mempcpy.c, stpcpy.c, stpncpy.c: New files.
+ * configure.in (funcs, AC_CHECK_FUNCS): Add mempcpy, stpcpy
+ and stpncpy.
+ * Makefile.in (CFILES): Add mempcpy.c, stpcpy.c and stpncpy.c.
+ (CONFIGURED_OFILES): Add mempcpy.o, stpcpy.o and stpncpy.o.
+ Regenerate dependencies.
+
+ * functions.texi, configure, config.in: Regenerated.
+
+2003-04-15 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * argv.c: Fix comments.
+ * calloc.c: Don't unnecessarily include "libiberty.h".
+ (bzero): Add prototype.
+ * floatformat.c: Include "ansidecl.h", rely on ANSI_PROTOTYPES.
+ * getcwd.c (getcwd): Use standard definition to avoid conflicts
+ with system headers.
+ * hashtab.c (htab_traverse): Delete unused variables.
+ * rename.c: Include "ansidecl.h".
+ (rename): Use standard definition to avoid conflicts with system
+ headers.
+ * strsignal.c: Rely on ANSI_PROTOTYPES.
+ * strstr.c: Check GNUC >= 2, not GNUC == 2.
+ * vfprintf.c: Include "ansidecl.h", rely on ANSI_PROTOTYPES.
+ * vprintf.c: Include "ansidecl.h" earlier, rely on
+ ANSI_PROTOTYPES.
+ * vsprintf.c: Include "ansidecl.h" earlier, rely on
+ ANSI_PROTOTYPES and possibly include <stdarg.h>.
+
+ * Makefile.in: Regenerate dependencies.
+
+2003-04-15 DJ Delorie <dj@redhat.com>
+
+ * maint-tool (deps): Scan for headers in $srcdir also.
+
+2003-04-15 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ PR target/10338
+ PR bootstrap/10198
+ PR bootstrap/10140
+ * getopt.c (exchange, _getopt_initialize): Use mempcpy not
+ __mempcpy.
+ * regex.c (regerror): Likewise.
+
+2003-04-14 Roger Sayle <roger@eyesopen.com>
+
+ * argv.c: Use ANSI_PROTOTYPES instead of __STDC__.
+ * memchr.c: Likewise.
+ * strcasecmp.c: Likewise.
+ * strncasecmp.c: Likewise.
+ * strncmp.c: Likewise.
+ * xatexit.c: Likewise.
+ * xmalloc.c: Likewise.
+
+ * copysign.c: Use traditional function declaration instead of DEFUN.
+ * sigsetmask.c: Likewise.
+
+ * memcmp.c: Both of the above, ANSI_PROTOTYPES and DEFUN.
+ * memset.c: Likewise.
+
+ * memcpy.c: ANSI_PROTOTYPES, DEFUN and prototype bcopy.
+ * memmove.c: Likewise.
+
+2003-04-14 Roger Sayle <roger@eyesopen.com>
+
+ * strdup.c (strdup): Tweak implementation to use memcpy.
+
+2003-04-14 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * configure.in (HAVE_UINTPTR_T): Always define.
+ * configure: Regenerated.
+
+2003-03-23 Alexandre Oliva <aoliva@redhat.com>
+
+ * Makefile.in (MULTIOSDIR): New macro. Use $(CC) $(LIBCFLAGS)
+ instead of $$CC alone.
+ (install_to_tooldir): Use it.
+
+2003-17-03 Jan Hubicka <jh@suse.cz>
+
+ * hashtab.c (htab_traverse_noresize): Break out from ...
+ * hashtab.c (htab_traverse): ... here.
+
+2003-12-03 Jan Hubicka <jh@suse.cz>
+
+ * hashtab.c (htab_expand): Fix warning.
+
+ * hashtab.c (htab_expand): Compute the size of hashtable based
+ on the number of elements actually used.
+ (htab_traverse): Call htab_expand when table is too empty.
+
+2003-03-11 Carlo Wood <carlo@gnu.org>
+
+ * cplus-dem.c (demangle_integral_value): Correction to reflect
+ patch of 2002-01-10 in order to also make negative multi-digits
+ without leading underscore work.
+
+2003-03-03 Mark Mitchell <mark@codesourcery.com>
+
+ * cplus-dem.c: Add license exception to copyright notice.
+
+2003-02-27 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * physmem.c: Formatting changes from upstream.
+
+2003-02-24 Danny Smith <dannysmith@users.source.forge.net>
+
+ * physmem.c (physmem_total): Add _WIN32 support.
+ (physmem_available): Likewise.
+
+2003-02-24 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
+
+ * physmem.c (physmem_total) [HAVE_GETSYSINFO]: Test for
+ GSI_PHYSMEM.
+ (physmem_available) [HAVE_TABLE]: Test for TBL_VMSTATS.
+
+2003-02-22 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * configure.in: Check for sys/systemcfg.h and
+ _system_configuration.
+ * physmem.c: Add support for AIX. Tweek formatting as per
+ upstream coreutils beta.
+
+2003-02-22 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+ Richard Earnshaw <rearnsha@arm.com>
+ Geoffrey Keating <geoffk@apple.com>
+
+ * configure.in: Check for sys/sysctl.h and sysctl.
+ * physmem.c: Add support for *bsd and darwin.
+ * Makefile.in: Generate depedency for physmem.o.
+
+2003-02-21 Rainer Orth <ro@TechFak.Uni-Bielefeld.DE>
+
+ * physmem.c (physmem_total) [HAVE_GETSYSINFO]: Use getsysinfo on
+ Tru64 UNIX.
+ (physmem_available) [HAVE_TABLE && HAVE_SYS_TABLE_H]: Use table on
+ Tru64 UNIX.
+
+ * configure.in (AC_CHECK_HEADERS): Check for sys/sysinfo.h,
+ machine/hal_sysinfo.h, sys/table.h.
+ (checkfuncs, AC_CHECKFUNCS): Check for getsysinfo, table.
+ * configure, config.in: Regenerate.
+
+2003-02-21 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * configure.in: Check for sys/sysmp.h and sysmp.
+ * physmem.c: Pull upstream copy, add support for irix6.
+
+ * config.in, configure: Regenerated.
+
+2003-02-21 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * physmem.c (physmem_total, physmem_available): De-ANSI-fy.
+ * configure.in (AC_CHECK_FUNCS): Add pstat_getstatic and
+ pstat_getdynamic.
+
+2003-02-20 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * Makefile.in (CFILES): Add physmem.c.
+ (REQUIRED_OFILES): Add physmem.o.
+ * configure.in: Check for sys/pstat.h.
+ (checkfuncs): Add pstat_getstatic and pstat_getdynamic.
+ * physmem.c: New file, copied from textutils.
+
+ * config.in, configure: Regenerated.
+
+2003-02-20 Daniel Jacobowitz <drow@mvista.com>
+
+ * Makefile.in (CFILES): Add lrealpath.c.
+ (REQUIRED_OFILES): Add lrealpath.o.
+ (lrealpath.o): Add rule.
+ * aclocal.m4 (libiberty_NEED_DECLARATION): Add.
+ * configure.in: Add realpath and canonicalize_file_name to
+ checkfuncs and AC_CHECK_FUNCS. Use libiberty_NEED_DECLARATION
+ for canonicalize_file_name.
+ * lrealpath.c: New file.
+ * make-relative-prefix.c: Update documentation.
+ (make_relative_prefix): Simplify. Use lbasename and lrealpath.
+ * config.in: Regenerated.
+ * configure: Regenerated.
+ * functions.texi: Regenerated.
+
+2003-02-20 jmc <jmc@prioris.mini.pw.edu.pl>
+
+ * cplus_dem.c: Fix typo: intializes -> initializes.
+
+2003-02-20 Alexandre Oliva <aoliva@redhat.com>
+
+ * configure.in: Propagate ORIGINAL_LD_FOR_MULTILIBS to
+ config.status.
+ * configure: Rebuilt.
+
+2003-02-13 Daniel Jacobowitz <drow@mvista.com>
+
+ Fix PR c++/7612.
+ * cplus-dem.c (demangle_signature): Call string_delete.
+ Remove extra string_init.
+ (demangle_arm_hp_template): Call string_delete instead of
+ string_clear. Add missing string_delete call.
+ (demangle_qualified): Add missing string_delete call.
+ (do_type): Remove unused variable btype. Add missing string_delete
+ call. Call string_delete instead of string_clear.
+ (demangle_fund_type): Move variable btype inside of the switch
+ statement. Add missing string_delete call.
+ (do_arg): Call string_delete instead of string_clear. Remove extra
+ string_init.
+ (demangle_nested_args): Free work->previous_argument.
+
+2003-02-12 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * acconfig.h: New file. Add uintptr_t.
+ * config.in: Regenerated.
+
+2003-02-04 Joseph S. Myers <jsm@polyomino.org.uk>
+
+ * libiberty.texi: Update to GFDL 1.2.
+
+2003-01-30 Christian Cornelssen <ccorn@cs.tu-berlin.de>
+
+ * Makefile.in (libiberty_topdir): New subst.
+ (mkinstalldirs): Redefine in terms of the above.
+ * configure.in: AC_SUBST it.
+ * configure: Regenerate.
+
+2003-01-28 Christian Cornelssen <ccorn@cs.tu-berlin.de>
+
+ * Makefile.in (all-subdir, check-subdir, installcheck-subdir)
+ (info-subdir, install-info-subdir, clean-info-subdir)
+ (dvi-subdir, install-subdir, etags-subdir, mostlyclean-subdir)
+ (clean-subdir, distclean-subdir, maintainer-clean-subdir):
+ Pass $(FLAGS_TO_PASS).
+
+2003-01-27 Alexandre Oliva <aoliva@redhat.com>
+
+ * Makefile.in (install_to_tooldir): Instead of $(MULTISUBDIR), use
+ /`$$CC -print-multi-os-directory`.
+
+2003-01-26 Daniel Jacobowitz <drow@mvista.com>
+
+ * hashtab.c (htab_create_alloc_ex): New function.
+ (hatab_set_functions_ex): New function.
+ (htab_delete, htab_expand): Support alternate allocation functions.
+
+2003-01-24 Christopher Faylor <cgf@redhat.com>
+
+ * configure.in: Remove special pex-cygwin consideration.
+ * configure: Regenerate.
+ * pex-cygwin.c: Remove.
+ * Makefile.in: Remove pex-cygwin.[co] lines.
+
+2003-01-24 Zack Weinberg <zack@codesourcery.com>
+
+ * Makefile.in (CFILES): Add pex-*.c.
+ (REQUIRED_OFILES): Change pexecute.o to @pexecute@
+ (CONFIGURED_OFILES): Add pex-*.o.
+ (TEXIFILES): Add pexecute.txh.
+ (pexecute.o): Delete rule.
+ (pex-cygwin.o, pex-djgpp.o, pex-mpw.o, pex-msdos.o, pex-os2.o,
+ pex-unix.o, pex-win32.o): New rules.
+ * configure.in: Change AC_INIT argument to xmalloc.c.
+ Compute appropriate pexecute implementation and substitute it
+ as @pexecute@.
+
+ * pexecute.c: Split up into...
+ * pex-cygwin.c, pex-djgpp.c, pex-mpw.c, pex-msdos.c, pex-os2.c,
+ pex-unix.c, pex-win32.c, pex-common.h, pexecute.txh: ... these
+ new files.
+
+ * functions.texi: Regenerate.
+ * configure: Regenerate.
+
+2003-01-20 Josef Zlomek <zlomekj@suse.cz>
+
+ * hashtab.c (htab_expand): Fix allocation of new entries.
+
+2003-01-09 Christian Cornelssen <ccorn@cs.tu-berlin.de>
+
+ * Makefile.in (FLAGS_TO_PASS): Also pass DESTDIR.
+
+ * Makefile.in (install_to_libdir, install_to_tooldir): Add a
+ mkinstalldirs command.
+
+2002-12-04 Danny Smith <dannysmith@users.sourceforge.net>
+
+ * make-relative-prefix.c (HAVE_HOST_EXECUTABLE_SUFFIX):
+ Define for hosts with HOST_EXECUTABLE_SUFFIX.
+
+2002-11-24 Nick Clifton <nickc@redhat.com>
+
+ * make-relative-prefix.c (make_relative_prefix): Ensure return
+ string is empty before using strcat to construct it.
+
+2002-11-22 Daniel Jacobowitz <drow@mvista.com>
+
+ * Makefile.in: Add make-relative-prefix.c.
+ * make-relative-prefix.c: New file.
+ * functions.texi: Rebuilt.
+
+2002-11-16 Jakub Jelinek <jakub@redhat.com>
+
+ * md5.c (md5_process_block): Avoid `function-like macro "F{G,H,I}" must be
+ used with arguments in traditional C' warnings.
+
+2002-10-16 Jakub Jelinek <jakub@redhat.com>
- Merge from mainline:
- 2002-10-16 Jakub Jelinek <jakub@redhat.com>
* config.table: Use mh-s390pic for s390x too.
+2002-10-06 Andreas Jaeger <aj@suse.de>
+
+ * libiberty/cplus-dem.c (ada_demangle): Get rid of unneeded
+ variable and of strict-aliasing warning.
+ (grow_vect): Use char as first parameter.
+
+2002-09-22 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * Makefile.in (all): Fix multilib parallel build.
+
+2002-09-19 John David Anglin <dave@hiuly1.hia.nrc.ca>
+
+ * cp-demangle.c (demangling_new): Cast 0 to enum.
+ (demangle_char): Cast return of strdup to char *.
+ (is_gnu_v3_mangled_ctor): Cast 0 to enum.
+ (is_gnu_v3_mangled_dtor): Likewise.
+ * cplus-dem.c (grow_vect): Cast return of xrealloc to void *.
+ (work_stuff_copy_to_from): Cast return of xmalloc to char **.
+ * fibheap.c (fibnode_new): Cast return of xcalloc to fibnode_t.
+ * md5.c (md5_process_bytes): Cast results back to const void *.
+ (md5_process_block): Add cast to const md5_uint32 *.
+ * regex.c (re_compile_fastmap): Cast enum to UCHAR_T.
+ * safe-ctype.c (L, XL, U, XU, D, P, _, C, Z, M, V, T, S): Add cast to
+ unsigned short.
+ * splay-tree.c (splay_tree_xmalloc_allocate): Cast return of xmalloc
+ to void *.
+ * vasprintf.c (int_vasprintf): Cast return of malloc to char *.
+
+2002-09-19 Nick Clifton <nickc@redhat.com>
+
+ * README: Update email addresses for bugs and patches.
+
+2002-09-10 Mike Stump <mrs@apple.com>
+
+ * splay-tree.c (splay_tree_successor): Fix comments.
+
+2002-09-11 Zack Weinberg <zack@codesourcery.com>
+
+ * cplus-dem.c: Code under #ifdef MAIN moved to gcc/cp/cxxfilt.c.
+ * testsuite/Makefile.in: Adjust for test-demangle.
+ * testsuite/regress-demangle: Deleted.
+ * testsuite/test-demangle.c: New file.
+ * testsuite/demangle-expected: Change \$ to $ throughout, now that
+ this file is not being read by a shell script.
+
+2002-09-05 Roger Sayle <roger@eyesopen.com>
+
+ * regex.c: Only use "#pragma alloca" on AIX when not using gcc.
+
+2002-08-07 DJ Delorie <dj@redhat.com>
+
+ * regex.c (re_error_msgid): Just use a simple array of strings.
+ (re_compile_pattern): Compensate.
+ (re_comp): Likewise.
+ (re_comp): Likewise.
+ (regerror): Likewise.
+
+2002-07-29 Neil Booth <neil@daikokuya.co.uk>
+
+ * cplus-dem.c (PREPEND_BLANK): Remove.
+
2002-07-10 Jason Merrill <jason@redhat.com>
* cp-demangle.c (demangle_identifier): Support extended Unicode
@@ -86,7 +1035,7 @@
2002-03-30 Bryce McKinlay <bryce@waitaki.otago.ac.nz>
- * cp-demangle.c (java_demangle_v3): Don't try to release "demangled"
+ * cp-demangle.c (java_demangle_v3): Don't try to release "demangled"
if it is NULL.
2002-03-27 DJ Delorie <dj@redhat.com>
@@ -500,10 +1449,10 @@ Thu Nov 15 11:06:25 2001 Jeffrey A Law (law@cygnus.com)
2001-08-22 Matt Kraai <kraai@alumni.carnegiemellon.edu>
- * fibheap.c (fibheap_init, fibnode_init): Remove.
- (fibheap_new, fibnode_new): Use xcalloc to allocate and
- initialize memory.
- (fibheap_insert): Remove check for node allocation failure.
+ * fibheap.c (fibheap_init, fibnode_init): Remove.
+ (fibheap_new, fibnode_new): Use xcalloc to allocate and
+ initialize memory.
+ (fibheap_insert): Remove check for node allocation failure.
2001-08-21 Richard Henderson <rth@redhat.com>
diff --git a/contrib/binutils/libiberty/Makefile.in b/contrib/binutils/libiberty/Makefile.in
index 5a25987..bbb5c2a 100644
--- a/contrib/binutils/libiberty/Makefile.in
+++ b/contrib/binutils/libiberty/Makefile.in
@@ -1,6 +1,6 @@
#
# Makefile
-# Copyright (C) 1990, 91-99, 2000, 2001, 2002
+# Copyright (C) 1990, 91-99, 2000, 2001, 2002, 2003, 2004
# Free Software Foundation
#
# This file is part of the libiberty library.
@@ -26,8 +26,8 @@
# Makefile for libiberty directory
#
+libiberty_topdir = @libiberty_topdir@
srcdir = @srcdir@
-VPATH = @srcdir@
prefix = @prefix@
@@ -50,7 +50,7 @@ MULTICLEAN = true
INSTALL = @INSTALL@
INSTALL_PROGRAM = @INSTALL_PROGRAM@
INSTALL_DATA = @INSTALL_DATA@
-mkinstalldirs = $(SHELL) $(srcdir)/../mkinstalldirs
+mkinstalldirs = $(SHELL) $(libiberty_topdir)/mkinstalldirs
# Some compilers can't handle cc -c blah.c -o foo/blah.o.
OUTPUT_OPTION = @OUTPUT_OPTION@
@@ -69,8 +69,8 @@ PICFLAG =
MAKEOVERRIDES =
-TARGETLIB = libiberty.a
-TESTLIB = testlib.a
+TARGETLIB = ./libiberty.a
+TESTLIB = ./testlib.a
LIBOBJS = @LIBOBJS@
@@ -84,6 +84,7 @@ FLAGS_TO_PASS = \
"AR_FLAGS=$(AR_FLAGS)" \
"CC=$(CC)" \
"CFLAGS=$(CFLAGS)" \
+ "DESTDIR=$(DESTDIR)" \
"LIBCFLAGS=$(LIBCFLAGS)" \
"EXTRA_OFILES=$(EXTRA_OFILES)" \
"HDEFINES=$(HDEFINES)" \
@@ -105,7 +106,7 @@ SUBDIRS = testsuite
# FIXME: add @BUILD_INFO@ once we're sure it works for everyone.
all: stamp-picdir $(TARGETLIB) needed-list required-list all-subdir
- @$(MULTIDO) $(FLAGS_TO_PASS) multi-do DO=all
+ @: $(MAKE) ; exec $(MULTIDO) $(FLAGS_TO_PASS) multi-do DO=all
.PHONY: check installcheck
check: check-subdir
@@ -116,76 +117,85 @@ installcheck: installcheck-subdir
INCDIR=$(srcdir)/$(MULTISRCTOP)../include
COMPILE.c = $(CC) -c @DEFS@ $(LIBCFLAGS) -I. -I$(INCDIR) $(HDEFINES) @ac_libiberty_warn_cflags@
+
+# Just to make sure we don't use a built-in rule with VPATH
.c.o:
- if [ x"$(PICFLAG)" != x ]; then \
- $(COMPILE.c) $(PICFLAG) $< -o pic/$@; \
- else true; fi
- $(COMPILE.c) $< $(OUTPUT_OPTION)
+ false
# NOTE: If you add new files to the library, add them to this list
# (alphabetical), and add them to REQUIRED_OFILES, or
-# CONFIGURED_OFILES and funcs in configure.in.
+# CONFIGURED_OFILES and funcs in configure.ac. Also run "make maint-deps"
+# to build the new rules.
CFILES = alloca.c argv.c asprintf.c atexit.c \
basename.c bcmp.c bcopy.c bsearch.c bzero.c \
calloc.c choose-temp.c clock.c concat.c cp-demangle.c \
- cplus-dem.c \
+ cp-demint.c cplus-dem.c \
dyn-string.c \
fdmatch.c ffs.c fibheap.c floatformat.c fnmatch.c \
getcwd.c getopt.c getopt1.c getpagesize.c getpwd.c getruntime.c \
hashtab.c hex.c \
index.c insque.c \
lbasename.c \
+ lrealpath.c \
+ make-relative-prefix.c \
make-temp-file.c md5.c memchr.c memcmp.c memcpy.c memmove.c \
- memset.c mkstemps.c \
+ mempcpy.c memset.c mkstemps.c \
objalloc.c obstack.c \
- partition.c pexecute.c putenv.c \
+ partition.c \
+ pex-djgpp.c pex-mpw.c pex-msdos.c pex-os2.c \
+ pex-unix.c pex-win32.c \
+ physmem.c putenv.c \
random.c regex.c rename.c rindex.c \
- safe-ctype.c setenv.c sigsetmask.c sort.c spaces.c \
- splay-tree.c strcasecmp.c strchr.c strdup.c strerror.c \
- strncasecmp.c strncmp.c strrchr.c strsignal.c strstr.c \
- strtod.c strtol.c strtoul.c \
+ safe-ctype.c setenv.c sigsetmask.c snprintf.c sort.c spaces.c \
+ splay-tree.c stpcpy.c stpncpy.c strcasecmp.c strchr.c strdup.c \
+ strerror.c strncasecmp.c strncmp.c strrchr.c strsignal.c \
+ strstr.c strtod.c strtol.c strtoul.c \
ternary.c tmpnam.c \
- vasprintf.c vfork.c vfprintf.c vprintf.c vsprintf.c \
+ vasprintf.c vfork.c vfprintf.c vprintf.c vsnprintf.c vsprintf.c \
waitpid.c \
xatexit.c xexit.c xmalloc.c xmemdup.c xstrdup.c xstrerror.c
# These are always included in the library. The first four are listed
# first and by compile time to optimize parallel builds.
-REQUIRED_OFILES = regex.o cplus-dem.o cp-demangle.o md5.o \
- alloca.o argv.o \
- choose-temp.o concat.o \
- dyn-string.o \
- fdmatch.o fibheap.o floatformat.o fnmatch.o \
- getopt.o getopt1.o getpwd.o getruntime.o \
- hashtab.o hex.o \
- lbasename.o \
- make-temp-file.o \
- objalloc.o obstack.o \
- partition.o pexecute.o \
- safe-ctype.o sort.o spaces.o splay-tree.o strerror.o \
- strsignal.o \
- ternary.o \
- xatexit.o xexit.o xmalloc.o xmemdup.o xstrdup.o xstrerror.o
+REQUIRED_OFILES = ./regex.o ./cplus-dem.o ./cp-demangle.o ./cp-demint.o ./md5.o \
+ ./alloca.o ./argv.o \
+ ./choose-temp.o ./concat.o \
+ ./dyn-string.o \
+ ./fdmatch.o ./fibheap.o ./floatformat.o ./fnmatch.o \
+ ./getopt.o ./getopt1.o ./getpwd.o ./getruntime.o \
+ ./hashtab.o ./hex.o \
+ ./lbasename.o \
+ ./lrealpath.o \
+ ./make-relative-prefix.o \
+ ./make-temp-file.o \
+ ./objalloc.o ./obstack.o \
+ ./partition.o ./physmem.o @pexecute@ \
+ ./safe-ctype.o ./sort.o ./spaces.o ./splay-tree.o ./strerror.o \
+ ./strsignal.o \
+ ./ternary.o \
+ ./xatexit.o ./xexit.o ./xmalloc.o ./xmemdup.o ./xstrdup.o ./xstrerror.o
# These are all the objects that configure may add to the library via
# $funcs or EXTRA_OFILES. This list exists here only for "make
# maint-missing" and "make check".
-CONFIGURED_OFILES = asprintf.o atexit.o \
- basename.o bcmp.o bcopy.o bsearch.o bzero.o \
- calloc.o clock.o copysign.o \
- _doprnt.o \
- ffs.o \
- getcwd.o getpagesize.o \
- index.o insque.o \
- memchr.o memcmp.o memcpy.o memmove.o memset.o mkstemps.o \
- putenv.o \
- random.o rename.o rindex.o \
- setenv.o sigsetmask.o strcasecmp.o strchr.o strdup.o \
- strncasecmp.o strncmp.o strrchr.o strstr.o strtod.o strtol.o \
- strtoul.o \
- tmpnam.o \
- vasprintf.o vfork.o vfprintf.o vprintf.o vsprintf.o \
- waitpid.o
+CONFIGURED_OFILES = ./asprintf.o ./atexit.o \
+ ./basename.o ./bcmp.o ./bcopy.o ./bsearch.o ./bzero.o \
+ ./calloc.o ./clock.o ./copysign.o \
+ ./_doprnt.o \
+ ./ffs.o \
+ ./getcwd.o ./getpagesize.o \
+ ./index.o ./insque.o \
+ ./memchr.o ./memcmp.o ./memcpy.o ./memmove.o ./mempcpy.o ./memset.o ./mkstemps.o \
+ ./pex-djgpp.o ./pex-mpw.o ./pex-msdos.o ./pex-os2.o \
+ ./pex-unix.o ./pex-win32.o \
+ ./putenv.o \
+ ./random.o ./rename.o ./rindex.o \
+ ./setenv.o ./sigsetmask.o ./snprintf.o ./stpcpy.o ./stpncpy.o ./strcasecmp.o \
+ ./strchr.o ./strdup.o ./strncasecmp.o ./strncmp.o ./strrchr.o ./strstr.o \
+ ./strtod.o ./strtol.o ./strtoul.o \
+ ./tmpnam.o \
+ ./vasprintf.o ./vfork.o ./vfprintf.o ./vprintf.o ./vsnprintf.o ./vsprintf.o \
+ ./waitpid.o
# These files are installed if the library has been configured to do so.
INSTALLED_HEADERS = \
@@ -237,7 +247,7 @@ TEXISRC = \
# Additional files that have texi snippets that need to be collected
# and sorted. Some are here because the sources are imported from
# elsewhere. Others represent headers in ../include.
-TEXIFILES = fnmatch.txh
+TEXIFILES = fnmatch.txh pexecute.txh
libiberty.info : $(srcdir)/libiberty.texi $(TEXISRC)
$(MAKEINFO) -I$(srcdir) $(srcdir)/libiberty.texi
@@ -259,6 +269,7 @@ INSTALL_DEST = @INSTALL_DEST@
install: install_to_$(INSTALL_DEST) install-subdir
install_to_libdir: all
+ ${mkinstalldirs} $(DESTDIR)$(libdir)$(MULTISUBDIR)
$(INSTALL_DATA) $(TARGETLIB) $(DESTDIR)$(libdir)$(MULTISUBDIR)/$(TARGETLIB)n
( cd $(DESTDIR)$(libdir)$(MULTISUBDIR) ; $(RANLIB) $(TARGETLIB)n )
mv -f $(DESTDIR)$(libdir)$(MULTISUBDIR)/$(TARGETLIB)n $(DESTDIR)$(libdir)$(MULTISUBDIR)/$(TARGETLIB)
@@ -274,10 +285,16 @@ install_to_libdir: all
fi
@$(MULTIDO) $(FLAGS_TO_PASS) multi-do DO=install
+# This is tricky. Even though CC in the Makefile contains
+# multilib-specific flags, it's overridden by FLAGS_TO_PASS from the
+# default multilib, so we have to take LIBCFLAGS into account as well,
+# since it will be passed the multilib flags.
+MULTIOSDIR = `$(CC) $(LIBCFLAGS) -print-multi-os-directory`
install_to_tooldir: all
- $(INSTALL_DATA) $(TARGETLIB) $(DESTDIR)$(tooldir)/lib$(MULTISUBDIR)/$(TARGETLIB)n
- ( cd $(DESTDIR)$(tooldir)/lib$(MULTISUBDIR) ; $(RANLIB) $(TARGETLIB)n )
- mv -f $(DESTDIR)$(tooldir)/lib$(MULTISUBDIR)/$(TARGETLIB)n $(DESTDIR)$(tooldir)/lib$(MULTISUBDIR)/$(TARGETLIB)
+ ${mkinstalldirs} $(DESTDIR)$(tooldir)/lib/$(MULTIOSDIR)
+ $(INSTALL_DATA) $(TARGETLIB) $(DESTDIR)$(tooldir)/lib/$(MULTIOSDIR)/$(TARGETLIB)n
+ ( cd $(DESTDIR)$(tooldir)/lib/$(MULTIOSDIR) ; $(RANLIB) $(TARGETLIB)n )
+ mv -f $(DESTDIR)$(tooldir)/lib/$(MULTIOSDIR)/$(TARGETLIB)n $(DESTDIR)$(tooldir)/lib/$(MULTIOSDIR)/$(TARGETLIB)
@$(MULTIDO) $(FLAGS_TO_PASS) multi-do DO=install
# needed-list is used by libstdc++. NEEDED is the list of functions
@@ -358,7 +375,7 @@ clean: clean-subdir
distclean: distclean-subdir
$(MAKE) SUBDIRS="" clean
@$(MULTICLEAN) multi-clean DO=distclean
- -rm -f *~ Makefile config.status xhost-mkfrag TAGS multilib.out
+ -rm -f *~ Makefile config.cache config.status xhost-mkfrag TAGS multilib.out
-rm -f config.log
-rmdir testsuite 2>/dev/null
maintainer-clean realclean: maintainer-clean-subdir
@@ -372,8 +389,8 @@ Makefile: $(srcdir)/Makefile.in config.status
# Depending on Makefile makes sure that config.status has been re-run
# if needed. This prevents problems with parallel builds.
config.h: stamp-h ; @true
-stamp-h: config.in config.status Makefile
- CONFIG_FILES= CONFIG_HEADERS=config.h:config.in $(SHELL) ./config.status
+stamp-h: $(srcdir)/config.in config.status Makefile
+ CONFIG_FILES= CONFIG_HEADERS=config.h:$(srcdir)/config.in $(SHELL) ./config.status
config.status: $(srcdir)/configure $(srcdir)/config.table
$(SHELL) ./config.status --recheck
@@ -388,7 +405,7 @@ maintainer-clean-subdir: config.h
@subdirs='$(SUBDIRS)'; \
target=`echo $@ | sed -e 's/-subdir//'`; \
for dir in $$subdirs ; do \
- cd $$dir && $(MAKE) $$target; \
+ cd $$dir && $(MAKE) $(FLAGS_TO_PASS) $$target; \
done
$(REQUIRED_OFILES) $(EXTRA_OFILES) $(LIBOBJS): stamp-picdir
@@ -397,87 +414,643 @@ $(CONFIGURED_OFILES): stamp-picdir
# The dependencies in the remainder of this file are automatically
# generated by "make maint-deps". Manual edits will be lost.
-_doprnt.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/safe-ctype.h
-alloca.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-argv.o: $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-asprintf.o: $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-atexit.o: config.h
-basename.o: $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
+./_doprnt.o: $(srcdir)/_doprnt.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/safe-ctype.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/_doprnt.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/_doprnt.c $(OUTPUT_OPTION)
+
+./alloca.o: $(srcdir)/alloca.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/alloca.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/alloca.c $(OUTPUT_OPTION)
+
+./argv.o: $(srcdir)/argv.c $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/argv.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/argv.c $(OUTPUT_OPTION)
+
+./asprintf.o: $(srcdir)/asprintf.c $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/asprintf.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/asprintf.c $(OUTPUT_OPTION)
+
+./atexit.o: $(srcdir)/atexit.c config.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/atexit.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/atexit.c $(OUTPUT_OPTION)
+
+./basename.o: $(srcdir)/basename.c $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
$(INCDIR)/safe-ctype.h
-bsearch.o: config.h $(INCDIR)/ansidecl.h
-calloc.o: $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-choose-temp.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-clock.o: config.h
-concat.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-copysign.o: $(INCDIR)/ansidecl.h
-cp-demangle.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/demangle.h \
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/basename.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/basename.c $(OUTPUT_OPTION)
+
+./bcmp.o: $(srcdir)/bcmp.c
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/bcmp.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/bcmp.c $(OUTPUT_OPTION)
+
+./bcopy.o: $(srcdir)/bcopy.c
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/bcopy.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/bcopy.c $(OUTPUT_OPTION)
+
+./bsearch.o: $(srcdir)/bsearch.c config.h $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/bsearch.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/bsearch.c $(OUTPUT_OPTION)
+
+./bzero.o: $(srcdir)/bzero.c
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/bzero.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/bzero.c $(OUTPUT_OPTION)
+
+./calloc.o: $(srcdir)/calloc.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/calloc.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/calloc.c $(OUTPUT_OPTION)
+
+./choose-temp.o: $(srcdir)/choose-temp.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/choose-temp.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/choose-temp.c $(OUTPUT_OPTION)
+
+./clock.o: $(srcdir)/clock.c config.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/clock.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/clock.c $(OUTPUT_OPTION)
+
+./concat.o: $(srcdir)/concat.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/concat.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/concat.c $(OUTPUT_OPTION)
+
+./copysign.o: $(srcdir)/copysign.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/copysign.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/copysign.c $(OUTPUT_OPTION)
+
+./cp-demangle.o: $(srcdir)/cp-demangle.c config.h $(INCDIR)/ansidecl.h \
+ $(srcdir)/cp-demangle.h $(INCDIR)/demangle.h \
$(INCDIR)/dyn-string.h $(INCDIR)/getopt.h $(INCDIR)/libiberty.h
-cplus-dem.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/demangle.h \
- $(INCDIR)/getopt.h $(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
-dyn-string.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/dyn-string.h \
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/cp-demangle.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/cp-demangle.c $(OUTPUT_OPTION)
+
+./cp-demint.o: $(srcdir)/cp-demint.c config.h $(INCDIR)/ansidecl.h \
+ $(srcdir)/cp-demangle.h $(INCDIR)/demangle.h \
+ $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/cp-demint.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/cp-demint.c $(OUTPUT_OPTION)
+
+./cplus-dem.o: $(srcdir)/cplus-dem.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/demangle.h $(INCDIR)/libiberty.h \
+ $(INCDIR)/safe-ctype.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/cplus-dem.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/cplus-dem.c $(OUTPUT_OPTION)
+
+./dyn-string.o: $(srcdir)/dyn-string.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/dyn-string.h $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/dyn-string.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/dyn-string.c $(OUTPUT_OPTION)
+
+./fdmatch.o: $(srcdir)/fdmatch.c $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/fdmatch.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/fdmatch.c $(OUTPUT_OPTION)
+
+./ffs.o: $(srcdir)/ffs.c
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/ffs.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/ffs.c $(OUTPUT_OPTION)
+
+./fibheap.o: $(srcdir)/fibheap.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/fibheap.h $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/fibheap.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/fibheap.c $(OUTPUT_OPTION)
+
+./floatformat.o: $(srcdir)/floatformat.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/floatformat.h $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/floatformat.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/floatformat.c $(OUTPUT_OPTION)
+
+./fnmatch.o: $(srcdir)/fnmatch.c config.h $(INCDIR)/fnmatch.h \
+ $(INCDIR)/safe-ctype.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/fnmatch.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/fnmatch.c $(OUTPUT_OPTION)
+
+./getcwd.o: $(srcdir)/getcwd.c config.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/getcwd.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/getcwd.c $(OUTPUT_OPTION)
+
+./getopt.o: $(srcdir)/getopt.c config.h $(INCDIR)/getopt.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/getopt.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/getopt.c $(OUTPUT_OPTION)
+
+./getopt1.o: $(srcdir)/getopt1.c config.h $(INCDIR)/getopt.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/getopt1.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/getopt1.c $(OUTPUT_OPTION)
+
+./getpagesize.o: $(srcdir)/getpagesize.c config.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/getpagesize.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/getpagesize.c $(OUTPUT_OPTION)
+
+./getpwd.o: $(srcdir)/getpwd.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/getpwd.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/getpwd.c $(OUTPUT_OPTION)
+
+./getruntime.o: $(srcdir)/getruntime.c config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/libiberty.h
-fdmatch.o: $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-fibheap.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/fibheap.h \
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/getruntime.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/getruntime.c $(OUTPUT_OPTION)
+
+./hashtab.o: $(srcdir)/hashtab.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/hashtab.h $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/hashtab.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/hashtab.c $(OUTPUT_OPTION)
+
+./hex.o: $(srcdir)/hex.c $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
+ $(INCDIR)/safe-ctype.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/hex.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/hex.c $(OUTPUT_OPTION)
+
+./index.o: $(srcdir)/index.c
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/index.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/index.c $(OUTPUT_OPTION)
+
+./insque.o: $(srcdir)/insque.c
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/insque.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/insque.c $(OUTPUT_OPTION)
+
+./lbasename.o: $(srcdir)/lbasename.c $(INCDIR)/ansidecl.h $(INCDIR)/filenames.h \
+ $(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/lbasename.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/lbasename.c $(OUTPUT_OPTION)
+
+./lrealpath.o: $(srcdir)/lrealpath.c config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/libiberty.h
-floatformat.o: $(INCDIR)/ansidecl.h $(INCDIR)/floatformat.h
-fnmatch.o: config.h $(INCDIR)/fnmatch.h $(INCDIR)/safe-ctype.h
-getcwd.o: config.h
-getopt.o: config.h $(INCDIR)/getopt.h
-getopt1.o: config.h $(INCDIR)/getopt.h
-getpagesize.o: config.h
-getpwd.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-getruntime.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-hashtab.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/hashtab.h \
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/lrealpath.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/lrealpath.c $(OUTPUT_OPTION)
+
+./make-relative-prefix.o: $(srcdir)/make-relative-prefix.c config.h \
+ $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/make-relative-prefix.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/make-relative-prefix.c $(OUTPUT_OPTION)
+
+./make-temp-file.o: $(srcdir)/make-temp-file.c config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/libiberty.h
-hex.o: $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-lbasename.o: $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/make-temp-file.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/make-temp-file.c $(OUTPUT_OPTION)
+
+./md5.o: $(srcdir)/md5.c config.h $(INCDIR)/ansidecl.h $(INCDIR)/md5.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/md5.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/md5.c $(OUTPUT_OPTION)
+
+./memchr.o: $(srcdir)/memchr.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/memchr.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/memchr.c $(OUTPUT_OPTION)
+
+./memcmp.o: $(srcdir)/memcmp.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/memcmp.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/memcmp.c $(OUTPUT_OPTION)
+
+./memcpy.o: $(srcdir)/memcpy.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/memcpy.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/memcpy.c $(OUTPUT_OPTION)
+
+./memmove.o: $(srcdir)/memmove.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/memmove.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/memmove.c $(OUTPUT_OPTION)
+
+./mempcpy.o: $(srcdir)/mempcpy.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/mempcpy.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/mempcpy.c $(OUTPUT_OPTION)
+
+./memset.o: $(srcdir)/memset.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/memset.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/memset.c $(OUTPUT_OPTION)
+
+./mkstemps.o: $(srcdir)/mkstemps.c config.h $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/mkstemps.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/mkstemps.c $(OUTPUT_OPTION)
+
+./mpw.o: $(srcdir)/mpw.c
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/mpw.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/mpw.c $(OUTPUT_OPTION)
+
+./msdos.o: $(srcdir)/msdos.c
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/msdos.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/msdos.c $(OUTPUT_OPTION)
+
+./objalloc.o: $(srcdir)/objalloc.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/objalloc.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/objalloc.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/objalloc.c $(OUTPUT_OPTION)
+
+./obstack.o: $(srcdir)/obstack.c config.h $(INCDIR)/obstack.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/obstack.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/obstack.c $(OUTPUT_OPTION)
+
+./partition.o: $(srcdir)/partition.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h $(INCDIR)/partition.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/partition.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/partition.c $(OUTPUT_OPTION)
+
+./pex-djgpp.o: $(srcdir)/pex-djgpp.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h $(srcdir)/pex-common.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/pex-djgpp.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/pex-djgpp.c $(OUTPUT_OPTION)
+
+./pex-mpw.o: $(srcdir)/pex-mpw.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h $(srcdir)/pex-common.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/pex-mpw.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/pex-mpw.c $(OUTPUT_OPTION)
+
+./pex-msdos.o: $(srcdir)/pex-msdos.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h $(srcdir)/pex-common.h \
$(INCDIR)/safe-ctype.h
-make-temp-file.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-md5.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/md5.h
-memchr.o: $(INCDIR)/ansidecl.h
-memcmp.o: $(INCDIR)/ansidecl.h
-memcpy.o: $(INCDIR)/ansidecl.h
-memmove.o: $(INCDIR)/ansidecl.h
-memset.o: $(INCDIR)/ansidecl.h
-mkstemps.o: config.h $(INCDIR)/ansidecl.h
-objalloc.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/objalloc.h
-obstack.o: config.h $(INCDIR)/obstack.h
-partition.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
- $(INCDIR)/partition.h
-pexecute.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/pex-msdos.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/pex-msdos.c $(OUTPUT_OPTION)
+
+./pex-os2.o: $(srcdir)/pex-os2.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h $(srcdir)/pex-common.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/pex-os2.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/pex-os2.c $(OUTPUT_OPTION)
+
+./pex-unix.o: $(srcdir)/pex-unix.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h $(srcdir)/pex-common.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/pex-unix.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/pex-unix.c $(OUTPUT_OPTION)
+
+./pex-win32.o: $(srcdir)/pex-win32.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h $(srcdir)/pex-common.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/pex-win32.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/pex-win32.c $(OUTPUT_OPTION)
+
+./physmem.o: $(srcdir)/physmem.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/physmem.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/physmem.c $(OUTPUT_OPTION)
+
+./putenv.o: $(srcdir)/putenv.c config.h $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/putenv.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/putenv.c $(OUTPUT_OPTION)
+
+./random.o: $(srcdir)/random.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/random.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/random.c $(OUTPUT_OPTION)
+
+./regex.o: $(srcdir)/regex.c config.h $(INCDIR)/xregex.h $(INCDIR)/xregex2.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/regex.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/regex.c $(OUTPUT_OPTION)
+
+./rename.o: $(srcdir)/rename.c config.h $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/rename.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/rename.c $(OUTPUT_OPTION)
+
+./rindex.o: $(srcdir)/rindex.c
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/rindex.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/rindex.c $(OUTPUT_OPTION)
+
+./safe-ctype.o: $(srcdir)/safe-ctype.c $(INCDIR)/ansidecl.h \
$(INCDIR)/safe-ctype.h
-putenv.o: config.h $(INCDIR)/ansidecl.h
-random.o: $(INCDIR)/ansidecl.h
-regex.o: config.h $(INCDIR)/xregex.h $(INCDIR)/xregex2.h
-rename.o: config.h
-safe-ctype.o: $(INCDIR)/ansidecl.h $(INCDIR)/safe-ctype.h
-setenv.o: config.h $(INCDIR)/ansidecl.h
-sigsetmask.o: $(INCDIR)/ansidecl.h
-sort.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/safe-ctype.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/safe-ctype.c $(OUTPUT_OPTION)
+
+./setenv.o: $(srcdir)/setenv.c config.h $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/setenv.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/setenv.c $(OUTPUT_OPTION)
+
+./sigsetmask.o: $(srcdir)/sigsetmask.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/sigsetmask.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/sigsetmask.c $(OUTPUT_OPTION)
+
+./snprintf.o: $(srcdir)/snprintf.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/snprintf.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/snprintf.c $(OUTPUT_OPTION)
+
+./sort.o: $(srcdir)/sort.c config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
$(INCDIR)/sort.h
-spaces.o: $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-splay-tree.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
- $(INCDIR)/splay-tree.h
-strcasecmp.o: $(INCDIR)/ansidecl.h
-strchr.o: $(INCDIR)/ansidecl.h
-strerror.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-strncasecmp.o: $(INCDIR)/ansidecl.h
-strncmp.o: $(INCDIR)/ansidecl.h
-strrchr.o: $(INCDIR)/ansidecl.h
-strsignal.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-strtod.o: $(INCDIR)/ansidecl.h $(INCDIR)/safe-ctype.h
-strtol.o: config.h $(INCDIR)/safe-ctype.h
-strtoul.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/safe-ctype.h
-ternary.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
- $(INCDIR)/ternary.h
-vasprintf.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-vfork.o: $(INCDIR)/ansidecl.h
-vprintf.o: $(INCDIR)/ansidecl.h
-vsprintf.o: $(INCDIR)/ansidecl.h
-waitpid.o: config.h
-xatexit.o: $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-xexit.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-xmalloc.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-xmemdup.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-xstrdup.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
-xstrerror.o: config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/sort.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/sort.c $(OUTPUT_OPTION)
+
+./spaces.o: $(srcdir)/spaces.c $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/spaces.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/spaces.c $(OUTPUT_OPTION)
+
+./splay-tree.o: $(srcdir)/splay-tree.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h $(INCDIR)/splay-tree.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/splay-tree.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/splay-tree.c $(OUTPUT_OPTION)
+
+./stpcpy.o: $(srcdir)/stpcpy.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/stpcpy.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/stpcpy.c $(OUTPUT_OPTION)
+
+./stpncpy.o: $(srcdir)/stpncpy.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/stpncpy.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/stpncpy.c $(OUTPUT_OPTION)
+
+./strcasecmp.o: $(srcdir)/strcasecmp.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/strcasecmp.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/strcasecmp.c $(OUTPUT_OPTION)
+
+./strchr.o: $(srcdir)/strchr.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/strchr.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/strchr.c $(OUTPUT_OPTION)
+
+./strdup.o: $(srcdir)/strdup.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/strdup.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/strdup.c $(OUTPUT_OPTION)
+
+./strerror.o: $(srcdir)/strerror.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/strerror.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/strerror.c $(OUTPUT_OPTION)
+
+./strncasecmp.o: $(srcdir)/strncasecmp.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/strncasecmp.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/strncasecmp.c $(OUTPUT_OPTION)
+
+./strncmp.o: $(srcdir)/strncmp.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/strncmp.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/strncmp.c $(OUTPUT_OPTION)
+
+./strrchr.o: $(srcdir)/strrchr.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/strrchr.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/strrchr.c $(OUTPUT_OPTION)
+
+./strsignal.o: $(srcdir)/strsignal.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/strsignal.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/strsignal.c $(OUTPUT_OPTION)
+
+./strstr.o: $(srcdir)/strstr.c
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/strstr.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/strstr.c $(OUTPUT_OPTION)
+
+./strtod.o: $(srcdir)/strtod.c $(INCDIR)/ansidecl.h $(INCDIR)/safe-ctype.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/strtod.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/strtod.c $(OUTPUT_OPTION)
+
+./strtol.o: $(srcdir)/strtol.c config.h $(INCDIR)/safe-ctype.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/strtol.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/strtol.c $(OUTPUT_OPTION)
+
+./strtoul.o: $(srcdir)/strtoul.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/safe-ctype.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/strtoul.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/strtoul.c $(OUTPUT_OPTION)
+
+./ternary.o: $(srcdir)/ternary.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h $(INCDIR)/ternary.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/ternary.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/ternary.c $(OUTPUT_OPTION)
+
+./tmpnam.o: $(srcdir)/tmpnam.c
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/tmpnam.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/tmpnam.c $(OUTPUT_OPTION)
+
+./vasprintf.o: $(srcdir)/vasprintf.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/vasprintf.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/vasprintf.c $(OUTPUT_OPTION)
+
+./vfork.o: $(srcdir)/vfork.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/vfork.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/vfork.c $(OUTPUT_OPTION)
+
+./vfprintf.o: $(srcdir)/vfprintf.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/vfprintf.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/vfprintf.c $(OUTPUT_OPTION)
+
+./vprintf.o: $(srcdir)/vprintf.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/vprintf.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/vprintf.c $(OUTPUT_OPTION)
+
+./vsnprintf.o: $(srcdir)/vsnprintf.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/vsnprintf.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/vsnprintf.c $(OUTPUT_OPTION)
+
+./vsprintf.o: $(srcdir)/vsprintf.c $(INCDIR)/ansidecl.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/vsprintf.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/vsprintf.c $(OUTPUT_OPTION)
+
+./waitpid.o: $(srcdir)/waitpid.c config.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/waitpid.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/waitpid.c $(OUTPUT_OPTION)
+
+./xatexit.o: $(srcdir)/xatexit.c $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/xatexit.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/xatexit.c $(OUTPUT_OPTION)
+
+./xexit.o: $(srcdir)/xexit.c config.h $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/xexit.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/xexit.c $(OUTPUT_OPTION)
+
+./xmalloc.o: $(srcdir)/xmalloc.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/xmalloc.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/xmalloc.c $(OUTPUT_OPTION)
+
+./xmemdup.o: $(srcdir)/xmemdup.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/xmemdup.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/xmemdup.c $(OUTPUT_OPTION)
+
+./xstrdup.o: $(srcdir)/xstrdup.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/xstrdup.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/xstrdup.c $(OUTPUT_OPTION)
+
+./xstrerror.o: $(srcdir)/xstrerror.c config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h
+ if [ x"$(PICFLAG)" != x ]; then \
+ $(COMPILE.c) $(PICFLAG) $(srcdir)/xstrerror.c -o pic/$@; \
+ else true; fi
+ $(COMPILE.c) $(srcdir)/xstrerror.c $(OUTPUT_OPTION)
+
diff --git a/contrib/binutils/libiberty/README b/contrib/binutils/libiberty/README
index 9f5226a..886bd67 100644
--- a/contrib/binutils/libiberty/README
+++ b/contrib/binutils/libiberty/README
@@ -15,7 +15,8 @@ The library must be configured from the top source directory. Don't
try to run configure in this directory. Follow the configuration
instructions in ../README.
-Please report bugs and fixes to "bug-gnu-utils@prep.ai.mit.edu". Thank you.
+Please report bugs to "gcc-bugs@gcc.gnu.org" and send fixes to
+"gcc-patches@gcc.gnu.org". Thank you.
ADDING A NEW FILE
=================
@@ -33,7 +34,7 @@ name of the function must be the same as the name of the file.
* Add the source file name to CFILES.
* Add the function to name to the funcs shell variable in
- configure.in.
+ configure.ac.
* Add the function to the AC_CHECK_FUNCS lists just after the
setting of the funcs shell variable. These AC_CHECK_FUNCS calls
diff --git a/contrib/binutils/libiberty/aclocal.m4 b/contrib/binutils/libiberty/aclocal.m4
index 103e246..f33e0c6 100644
--- a/contrib/binutils/libiberty/aclocal.m4
+++ b/contrib/binutils/libiberty/aclocal.m4
@@ -1,3 +1,7 @@
+sinclude(../config/accross.m4)
+sinclude(../config/acx.m4)
+sinclude(../config/no-executables.m4)
+
dnl See whether strncmp reads past the end of its string parameters.
dnl On some versions of SunOS4 at least, strncmp reads a word at a time
dnl but erroneously reads past the end of strings. This can cause
@@ -69,7 +73,7 @@ main ()
ac_cv_func_strncmp_works=no)
rm -f core core.* *.core])
if test $ac_cv_func_strncmp_works = no ; then
- LIBOBJS="$LIBOBJS strncmp.o"
+ AC_LIBOBJ([strncmp])
fi
])
@@ -87,47 +91,34 @@ then AC_DEFINE(NEED_DECLARATION_ERRNO, 1,
fi
])
-# FIXME: We temporarily define our own version of AC_PROG_CC. This is
-# copied from autoconf 2.12, but does not call AC_PROG_CC_WORKS. We
-# are probably using a cross compiler, which will not be able to fully
-# link an executable. This should really be fixed in autoconf
-# itself.
-
-AC_DEFUN(LIB_AC_PROG_CC,
-[AC_BEFORE([$0], [AC_PROG_CPP])dnl
-AC_PROVIDE([AC_PROG_CC])
-AC_CHECK_PROG(CC, gcc, gcc)
-if test -z "$CC"; then
- AC_CHECK_PROG(CC, cc, cc, , , /usr/ucb/cc)
- test -z "$CC" && AC_MSG_ERROR([no acceptable cc found in \$PATH])
-fi
-
-AC_PROG_CC_GNU
-
-if test $ac_cv_prog_gcc = yes; then
- GCC=yes
- ac_libiberty_warn_cflags='-W -Wall -Wtraditional -pedantic'
-dnl Check whether -g works, even if CFLAGS is set, in case the package
-dnl plays around with CFLAGS (such as to build both debugging and
-dnl normal versions of a library), tasteless as that idea is.
- ac_test_CFLAGS="${CFLAGS+set}"
- ac_save_CFLAGS="$CFLAGS"
- CFLAGS=
- AC_PROG_CC_G
- if test "$ac_test_CFLAGS" = set; then
- CFLAGS="$ac_save_CFLAGS"
- elif test $ac_cv_prog_cc_g = yes; then
- CFLAGS="-g -O2"
- else
- CFLAGS="-O2"
- fi
-else
- GCC=
- ac_libiberty_warn_cflags=
- test "${CFLAGS+set}" = set || CFLAGS="-g"
+dnl See whether we need a declaration for a function.
+AC_DEFUN(libiberty_NEED_DECLARATION,
+[AC_MSG_CHECKING([whether $1 must be declared])
+AC_CACHE_VAL(libiberty_cv_decl_needed_$1,
+[AC_TRY_COMPILE([
+#include "confdefs.h"
+#include <stdio.h>
+#ifdef HAVE_STRING_H
+#include <string.h>
+#else
+#ifdef HAVE_STRINGS_H
+#include <strings.h>
+#endif
+#endif
+#ifdef HAVE_STDLIB_H
+#include <stdlib.h>
+#endif
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif],
+[char *(*pfn) = (char *(*)) $1],
+libiberty_cv_decl_needed_$1=no, libiberty_cv_decl_needed_$1=yes)])
+AC_MSG_RESULT($libiberty_cv_decl_needed_$1)
+if test $libiberty_cv_decl_needed_$1 = yes; then
+ AC_DEFINE([NEED_DECLARATION_]translit($1, [a-z], [A-Z]), 1,
+ [Define if $1 is not declared in system header files.])
fi
-AC_SUBST(ac_libiberty_warn_cflags)
-])
+])dnl
# Work around a bug in autoheader. This can go away when we switch to
# autoconf >2.50. The use of define instead of AC_DEFUN is
@@ -189,3 +180,52 @@ AC_DEFINE_UNQUOTED(STACK_DIRECTION, $ac_cv_c_stack_direction,
STACK_DIRECTION < 0 => grows toward lower addresses
STACK_DIRECTION = 0 => direction of growth unknown])
])
+
+# AC_LANG_FUNC_LINK_TRY(C)(FUNCTION)
+# ----------------------------------
+# Don't include <ctype.h> because on OSF/1 3.0 it includes
+# <sys/types.h> which includes <sys/select.h> which contains a
+# prototype for select. Similarly for bzero.
+#
+# This test used to merely assign f=$1 in main(), but that was
+# optimized away by HP unbundled cc A.05.36 for ia64 under +O3,
+# presumably on the basis that there's no need to do that store if the
+# program is about to exit. Conversely, the AIX linker optimizes an
+# unused external declaration that initializes f=$1. So this test
+# program has both an external initialization of f, and a use of f in
+# main that affects the exit status.
+#
+m4_define([AC_LANG_FUNC_LINK_TRY(C)],
+[AC_LANG_PROGRAM(
+[/* System header to define __stub macros and hopefully few prototypes,
+ which can conflict with char $1 (); below.
+ Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+ <limits.h> exists even on freestanding compilers. Under hpux,
+ including <limits.h> includes <sys/time.h> and causes problems
+ checking for functions defined therein. */
+#if defined (__STDC__) && !defined (_HPUX_SOURCE)
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char $1 ();
+/* The GNU C library defines this for functions which it implements
+ to always fail with ENOSYS. Some functions are actually named
+ something starting with __ and the normal name is an alias. */
+#if defined (__stub_$1) || defined (__stub___$1)
+choke me
+#else
+char (*f) () = $1;
+#endif
+#ifdef __cplusplus
+}
+#endif
+], [return f != $1;])])
+
diff --git a/contrib/binutils/libiberty/argv.c b/contrib/binutils/libiberty/argv.c
index 4205579..31d8ef5 100644
--- a/contrib/binutils/libiberty/argv.c
+++ b/contrib/binutils/libiberty/argv.c
@@ -29,13 +29,13 @@ Boston, MA 02111-1307, USA. */
/* Routines imported from standard C runtime libraries. */
-#ifdef __STDC__
+#ifdef ANSI_PROTOTYPES
#include <stddef.h>
#include <string.h>
#include <stdlib.h>
-#else /* !__STDC__ */
+#else /* !ANSI_PROTOTYPES */
#if !defined _WIN32 || defined __GNUC__
extern char *memcpy (); /* Copy memory region */
@@ -46,7 +46,7 @@ extern void free (); /* Free malloc'd memory */
extern char *strdup (); /* Duplicate a string */
#endif
-#endif /* __STDC__ */
+#endif /* ANSI_PROTOTYPES */
#ifndef NULL
diff --git a/contrib/binutils/libiberty/asprintf.c b/contrib/binutils/libiberty/asprintf.c
index 5de7756..cd0543a 100644
--- a/contrib/binutils/libiberty/asprintf.c
+++ b/contrib/binutils/libiberty/asprintf.c
@@ -1,6 +1,6 @@
/* Like sprintf but provides a pointer to malloc'd storage, which must
be freed by the caller.
- Copyright (C) 1997 Free Software Foundation, Inc.
+ Copyright (C) 1997, 2003 Free Software Foundation, Inc.
Contributed by Cygnus Solutions.
This file is part of the libiberty library.
@@ -37,7 +37,7 @@ pass a pointer to a pointer. This function will compute the size of
the buffer needed, allocate memory with @code{malloc}, and store a
pointer to the allocated memory in @code{*@var{resptr}}. The value
returned is the same as @code{sprintf} would return. If memory could
-not be allocated, zero is returned and @code{NULL} is stored in
+not be allocated, minus one is returned and @code{NULL} is stored in
@code{*@var{resptr}}.
@end deftypefn
diff --git a/contrib/binutils/libiberty/calloc.c b/contrib/binutils/libiberty/calloc.c
index b342f6c..5073682 100644
--- a/contrib/binutils/libiberty/calloc.c
+++ b/contrib/binutils/libiberty/calloc.c
@@ -13,8 +13,6 @@ Uses @code{malloc} to allocate storage for @var{nelem} objects of
*/
#include "ansidecl.h"
-#include "libiberty.h"
-
#ifdef ANSI_PROTOTYPES
#include <stddef.h>
#else
@@ -23,6 +21,7 @@ Uses @code{malloc} to allocate storage for @var{nelem} objects of
/* For systems with larger pointers than ints, this must be declared. */
PTR malloc PARAMS ((size_t));
+void bzero PARAMS ((PTR, size_t));
PTR
calloc (nelem, elsize)
diff --git a/contrib/binutils/libiberty/config.in b/contrib/binutils/libiberty/config.in
index e06bbce..8e5071a 100644
--- a/contrib/binutils/libiberty/config.in
+++ b/contrib/binutils/libiberty/config.in
@@ -1,254 +1,376 @@
-/* config.in. Generated automatically from configure.in by autoheader 2.13. */
+/* config.in. Generated from configure.ac by autoheader. */
+/* Define to `unsigned long' if <sys/types.h> doesn't define. */
+#undef uintptr_t
-/* Define to empty if the keyword does not work. */
-#undef const
-
-/* Define if you have a working `mmap' system call. */
-#undef HAVE_MMAP
-
-/* Define if you have <sys/wait.h> that is POSIX.1 compatible. */
-#undef HAVE_SYS_WAIT_H
-
-/* Define if you have <vfork.h>. */
-#undef HAVE_VFORK_H
-
-/* Define as __inline if that's what the C compiler calls it. */
-#undef inline
-
-/* Define to `int' if <sys/types.h> doesn't define. */
-#undef pid_t
-
-/* Define if you need to in order for stat and other things to work. */
-#undef _POSIX_SOURCE
-/* Define if you have the ANSI C header files. */
-#undef STDC_HEADERS
-
-/* Define if you can safely include both <sys/time.h> and <time.h>. */
-#undef TIME_WITH_SYS_TIME
+/* 1234 = LIL_ENDIAN, 4321 = BIGENDIAN */
+#undef BYTEORDER
-/* Define vfork as fork if vfork does not work. */
-#undef vfork
+/* Define to one of _getb67, GETB67, getb67 for Cray-2 and Cray-YMP systems.
+ This function is required for alloca.c support on those systems. */
+#undef CRAY_STACKSEG_END
-/* Define if you have the _doprnt function. */
-#undef HAVE__DOPRNT
+/* Define to 1 if you have the <alloca.h> header file. */
+#undef HAVE_ALLOCA_H
-/* Define if you have the asprintf function. */
+/* Define to 1 if you have the `asprintf' function. */
#undef HAVE_ASPRINTF
-/* Define if you have the atexit function. */
+/* Define to 1 if you have the `atexit' function. */
#undef HAVE_ATEXIT
-/* Define if you have the basename function. */
+/* Define to 1 if you have the `basename' function. */
#undef HAVE_BASENAME
-/* Define if you have the bcmp function. */
+/* Define to 1 if you have the `bcmp' function. */
#undef HAVE_BCMP
-/* Define if you have the bcopy function. */
+/* Define to 1 if you have the `bcopy' function. */
#undef HAVE_BCOPY
-/* Define if you have the bsearch function. */
+/* Define to 1 if you have the `bsearch' function. */
#undef HAVE_BSEARCH
-/* Define if you have the bzero function. */
+/* Define to 1 if you have the `bzero' function. */
#undef HAVE_BZERO
-/* Define if you have the calloc function. */
+/* Define to 1 if you have the `calloc' function. */
#undef HAVE_CALLOC
-/* Define if you have the clock function. */
+/* Define to 1 if you have the `canonicalize_file_name' function. */
+#undef HAVE_CANONICALIZE_FILE_NAME
+
+/* Define to 1 if you have the `clock' function. */
#undef HAVE_CLOCK
-/* Define if you have the ffs function. */
+/* Define to 1 if you have the <fcntl.h> header file. */
+#undef HAVE_FCNTL_H
+
+/* Define to 1 if you have the `ffs' function. */
#undef HAVE_FFS
-/* Define if you have the getcwd function. */
+/* Define to 1 if you have the `fork' function. */
+#undef HAVE_FORK
+
+/* Define to 1 if you have the `getcwd' function. */
#undef HAVE_GETCWD
-/* Define if you have the getpagesize function. */
+/* Define to 1 if you have the `getpagesize' function. */
#undef HAVE_GETPAGESIZE
-/* Define if you have the getrusage function. */
+/* Define to 1 if you have the `getrusage' function. */
#undef HAVE_GETRUSAGE
-/* Define if you have the gettimeofday function. */
+/* Define to 1 if you have the `getsysinfo' function. */
+#undef HAVE_GETSYSINFO
+
+/* Define to 1 if you have the `gettimeofday' function. */
#undef HAVE_GETTIMEOFDAY
-/* Define if you have the index function. */
+/* Define to 1 if you have the `index' function. */
#undef HAVE_INDEX
-/* Define if you have the insque function. */
+/* Define to 1 if you have the `insque' function. */
#undef HAVE_INSQUE
-/* Define if you have the memchr function. */
+/* Define to 1 if you have the <inttypes.h> header file. */
+#undef HAVE_INTTYPES_H
+
+/* Define to 1 if you have the <limits.h> header file. */
+#undef HAVE_LIMITS_H
+
+/* Define to 1 if you have the <machine/hal_sysinfo.h> header file. */
+#undef HAVE_MACHINE_HAL_SYSINFO_H
+
+/* Define to 1 if you have the <malloc.h> header file. */
+#undef HAVE_MALLOC_H
+
+/* Define to 1 if you have the `memchr' function. */
#undef HAVE_MEMCHR
-/* Define if you have the memcmp function. */
+/* Define to 1 if you have the `memcmp' function. */
#undef HAVE_MEMCMP
-/* Define if you have the memcpy function. */
+/* Define to 1 if you have the `memcpy' function. */
#undef HAVE_MEMCPY
-/* Define if you have the memmove function. */
+/* Define to 1 if you have the `memmove' function. */
#undef HAVE_MEMMOVE
-/* Define if you have the memset function. */
+/* Define to 1 if you have the <memory.h> header file. */
+#undef HAVE_MEMORY_H
+
+/* Define to 1 if you have the `mempcpy' function. */
+#undef HAVE_MEMPCPY
+
+/* Define to 1 if you have the `memset' function. */
#undef HAVE_MEMSET
-/* Define if you have the mkstemps function. */
+/* Define to 1 if you have the `mkstemps' function. */
#undef HAVE_MKSTEMPS
-/* Define if you have the on_exit function. */
+/* Define to 1 if you have a working `mmap' system call. */
+#undef HAVE_MMAP
+
+/* Define to 1 if you have the `on_exit' function. */
#undef HAVE_ON_EXIT
-/* Define if you have the psignal function. */
+/* Define to 1 if you have the `psignal' function. */
#undef HAVE_PSIGNAL
-/* Define if you have the putenv function. */
+/* Define to 1 if you have the `pstat_getdynamic' function. */
+#undef HAVE_PSTAT_GETDYNAMIC
+
+/* Define to 1 if you have the `pstat_getstatic' function. */
+#undef HAVE_PSTAT_GETSTATIC
+
+/* Define to 1 if you have the `putenv' function. */
#undef HAVE_PUTENV
-/* Define if you have the random function. */
+/* Define to 1 if you have the `random' function. */
#undef HAVE_RANDOM
-/* Define if you have the rename function. */
+/* Define to 1 if you have the `realpath' function. */
+#undef HAVE_REALPATH
+
+/* Define to 1 if you have the `rename' function. */
#undef HAVE_RENAME
-/* Define if you have the rindex function. */
+/* Define to 1 if you have the `rindex' function. */
#undef HAVE_RINDEX
-/* Define if you have the sbrk function. */
+/* Define to 1 if you have the `sbrk' function. */
#undef HAVE_SBRK
-/* Define if you have the setenv function. */
+/* Define to 1 if you have the `setenv' function. */
#undef HAVE_SETENV
-/* Define if you have the sigsetmask function. */
+/* Define to 1 if you have the `sigsetmask' function. */
#undef HAVE_SIGSETMASK
-/* Define if you have the strcasecmp function. */
+/* Define to 1 if you have the `snprintf' function. */
+#undef HAVE_SNPRINTF
+
+/* Define to 1 if you have the <stdint.h> header file. */
+#undef HAVE_STDINT_H
+
+/* Define to 1 if you have the <stdlib.h> header file. */
+#undef HAVE_STDLIB_H
+
+/* Define to 1 if you have the `stpcpy' function. */
+#undef HAVE_STPCPY
+
+/* Define to 1 if you have the `stpncpy' function. */
+#undef HAVE_STPNCPY
+
+/* Define to 1 if you have the `strcasecmp' function. */
#undef HAVE_STRCASECMP
-/* Define if you have the strchr function. */
+/* Define to 1 if you have the `strchr' function. */
#undef HAVE_STRCHR
-/* Define if you have the strdup function. */
+/* Define to 1 if you have the `strdup' function. */
#undef HAVE_STRDUP
-/* Define if you have the strerror function. */
+/* Define to 1 if you have the `strerror' function. */
#undef HAVE_STRERROR
-/* Define if you have the strncasecmp function. */
+/* Define to 1 if you have the <strings.h> header file. */
+#undef HAVE_STRINGS_H
+
+/* Define to 1 if you have the <string.h> header file. */
+#undef HAVE_STRING_H
+
+/* Define to 1 if you have the `strncasecmp' function. */
#undef HAVE_STRNCASECMP
-/* Define if you have the strrchr function. */
+/* Define to 1 if you have the `strrchr' function. */
#undef HAVE_STRRCHR
-/* Define if you have the strsignal function. */
+/* Define to 1 if you have the `strsignal' function. */
#undef HAVE_STRSIGNAL
-/* Define if you have the strstr function. */
+/* Define to 1 if you have the `strstr' function. */
#undef HAVE_STRSTR
-/* Define if you have the strtod function. */
+/* Define to 1 if you have the `strtod' function. */
#undef HAVE_STRTOD
-/* Define if you have the strtol function. */
+/* Define to 1 if you have the `strtol' function. */
#undef HAVE_STRTOL
-/* Define if you have the strtoul function. */
+/* Define to 1 if you have the `strtoul' function. */
#undef HAVE_STRTOUL
-/* Define if you have the sysconf function. */
+/* Define to 1 if you have the `sysconf' function. */
#undef HAVE_SYSCONF
-/* Define if you have the times function. */
+/* Define to 1 if you have the `sysctl' function. */
+#undef HAVE_SYSCTL
+
+/* Define to 1 if you have the `sysmp' function. */
+#undef HAVE_SYSMP
+
+/* Define if you have the sys_errlist variable. */
+#undef HAVE_SYS_ERRLIST
+
+/* Define to 1 if you have the <sys/file.h> header file. */
+#undef HAVE_SYS_FILE_H
+
+/* Define to 1 if you have the <sys/mman.h> header file. */
+#undef HAVE_SYS_MMAN_H
+
+/* Define if you have the sys_nerr variable. */
+#undef HAVE_SYS_NERR
+
+/* Define to 1 if you have the <sys/param.h> header file. */
+#undef HAVE_SYS_PARAM_H
+
+/* Define to 1 if you have the <sys/pstat.h> header file. */
+#undef HAVE_SYS_PSTAT_H
+
+/* Define to 1 if you have the <sys/resource.h> header file. */
+#undef HAVE_SYS_RESOURCE_H
+
+/* Define if you have the sys_siglist variable. */
+#undef HAVE_SYS_SIGLIST
+
+/* Define to 1 if you have the <sys/stat.h> header file. */
+#undef HAVE_SYS_STAT_H
+
+/* Define to 1 if you have the <sys/sysctl.h> header file. */
+#undef HAVE_SYS_SYSCTL_H
+
+/* Define to 1 if you have the <sys/sysinfo.h> header file. */
+#undef HAVE_SYS_SYSINFO_H
+
+/* Define to 1 if you have the <sys/sysmp.h> header file. */
+#undef HAVE_SYS_SYSMP_H
+
+/* Define to 1 if you have the <sys/systemcfg.h> header file. */
+#undef HAVE_SYS_SYSTEMCFG_H
+
+/* Define to 1 if you have the <sys/table.h> header file. */
+#undef HAVE_SYS_TABLE_H
+
+/* Define to 1 if you have the <sys/time.h> header file. */
+#undef HAVE_SYS_TIME_H
+
+/* Define to 1 if you have the <sys/types.h> header file. */
+#undef HAVE_SYS_TYPES_H
+
+/* Define to 1 if you have <sys/wait.h> that is POSIX.1 compatible. */
+#undef HAVE_SYS_WAIT_H
+
+/* Define to 1 if you have the `table' function. */
+#undef HAVE_TABLE
+
+/* Define to 1 if you have the `times' function. */
#undef HAVE_TIMES
-/* Define if you have the tmpnam function. */
+/* Define to 1 if you have the <time.h> header file. */
+#undef HAVE_TIME_H
+
+/* Define to 1 if you have the `tmpnam' function. */
#undef HAVE_TMPNAM
-/* Define if you have the vasprintf function. */
+/* Define if you have the \`uintptr_t' type. */
+#undef HAVE_UINTPTR_T
+
+/* Define to 1 if you have the <unistd.h> header file. */
+#undef HAVE_UNISTD_H
+
+/* Define to 1 if you have the `vasprintf' function. */
#undef HAVE_VASPRINTF
-/* Define if you have the vfprintf function. */
+/* Define to 1 if you have the `vfork' function. */
+#undef HAVE_VFORK
+
+/* Define to 1 if you have the <vfork.h> header file. */
+#undef HAVE_VFORK_H
+
+/* Define to 1 if you have the `vfprintf' function. */
#undef HAVE_VFPRINTF
-/* Define if you have the vprintf function. */
+/* Define to 1 if you have the `vprintf' function. */
#undef HAVE_VPRINTF
-/* Define if you have the vsprintf function. */
+/* Define to 1 if you have the `vsnprintf' function. */
+#undef HAVE_VSNPRINTF
+
+/* Define to 1 if you have the `vsprintf' function. */
#undef HAVE_VSPRINTF
-/* Define if you have the waitpid function. */
+/* Define to 1 if you have the `waitpid' function. */
#undef HAVE_WAITPID
-/* Define if you have the <alloca.h> header file. */
-#undef HAVE_ALLOCA_H
+/* Define to 1 if `fork' works. */
+#undef HAVE_WORKING_FORK
-/* Define if you have the <fcntl.h> header file. */
-#undef HAVE_FCNTL_H
+/* Define to 1 if `vfork' works. */
+#undef HAVE_WORKING_VFORK
-/* Define if you have the <limits.h> header file. */
-#undef HAVE_LIMITS_H
+/* Define to 1 if you have the `_doprnt' function. */
+#undef HAVE__DOPRNT
-/* Define if you have the <stdlib.h> header file. */
-#undef HAVE_STDLIB_H
+/* Define if you have the _system_configuration variable. */
+#undef HAVE__SYSTEM_CONFIGURATION
-/* Define if you have the <string.h> header file. */
-#undef HAVE_STRING_H
+/* Define if the host machine stores words of multi-word integers in
+ big-endian order. */
+#undef HOST_WORDS_BIG_ENDIAN
-/* Define if you have the <strings.h> header file. */
-#undef HAVE_STRINGS_H
+/* Define if canonicalize_file_name is not declared in system header files. */
+#undef NEED_DECLARATION_CANONICALIZE_FILE_NAME
-/* Define if you have the <sys/file.h> header file. */
-#undef HAVE_SYS_FILE_H
+/* Define if errno must be declared even when <errno.h> is included. */
+#undef NEED_DECLARATION_ERRNO
-/* Define if you have the <sys/mman.h> header file. */
-#undef HAVE_SYS_MMAN_H
+/* Define to 1 if your C compiler doesn't accept -c and -o together. */
+#undef NO_MINUS_C_MINUS_O
-/* Define if you have the <sys/param.h> header file. */
-#undef HAVE_SYS_PARAM_H
+/* Define to the address where bug reports for this package should be sent. */
+#undef PACKAGE_BUGREPORT
-/* Define if you have the <sys/resource.h> header file. */
-#undef HAVE_SYS_RESOURCE_H
+/* Define to the full name of this package. */
+#undef PACKAGE_NAME
-/* Define if you have the <sys/stat.h> header file. */
-#undef HAVE_SYS_STAT_H
+/* Define to the full name and version of this package. */
+#undef PACKAGE_STRING
-/* Define if you have the <sys/time.h> header file. */
-#undef HAVE_SYS_TIME_H
+/* Define to the one symbol short name of this package. */
+#undef PACKAGE_TARNAME
-/* Define if you have the <time.h> header file. */
-#undef HAVE_TIME_H
+/* Define to the version of this package. */
+#undef PACKAGE_VERSION
-/* Define if you have the <unistd.h> header file. */
-#undef HAVE_UNISTD_H
+/* Define if you know the direction of stack growth for your system; otherwise
+ it will be automatically deduced at run-time. STACK_DIRECTION > 0 => grows
+ toward higher addresses STACK_DIRECTION < 0 => grows toward lower addresses
+ STACK_DIRECTION = 0 => direction of growth unknown */
+#undef STACK_DIRECTION
-/* Define if errno must be declared even when <errno.h> is included. */
-#undef NEED_DECLARATION_ERRNO
+/* Define to 1 if you have the ANSI C header files. */
+#undef STDC_HEADERS
-/* Define if you have the `uintptr_t' type. */
-#undef HAVE_UINTPTR_T
+/* Define to 1 if you can safely include both <sys/time.h> and <time.h>. */
+#undef TIME_WITH_SYS_TIME
-/* Define if you have the sys_errlist variable. */
-#undef HAVE_SYS_ERRLIST
+/* whether byteorder is bigendian */
+#undef WORDS_BIGENDIAN
-/* Define if you have the sys_nerr variable. */
-#undef HAVE_SYS_NERR
+/* Define to empty if `const' does not conform to ANSI C. */
+#undef const
-/* Define if you have the sys_siglist variable. */
-#undef HAVE_SYS_SIGLIST
+/* Define as `__inline' if that's what the C compiler calls it, or to nothing
+ if it is not supported. */
+#undef inline
-/* Define to one of _getb67, GETB67, getb67 for Cray-2 and Cray-YMP
- systems. This function is required for alloca.c support on those
- systems. */
-#undef CRAY_STACKSEG_END
+/* Define to `int' if <sys/types.h> does not define. */
+#undef pid_t
-/* Define if you know the direction of stack growth for your system;
- otherwise it will be automatically deduced at run-time.
- STACK_DIRECTION > 0 => grows toward higher addresses
- STACK_DIRECTION < 0 => grows toward lower addresses
- STACK_DIRECTION = 0 => direction of growth unknown */
-#undef STACK_DIRECTION
+/* Define to `unsigned long' if <sys/types.h> does not define. */
+#undef uintptr_t
+/* Define as `fork' if `vfork' does not work. */
+#undef vfork
diff --git a/contrib/binutils/libiberty/config.table b/contrib/binutils/libiberty/config.table
index df48ce9..1867cfea 100644
--- a/contrib/binutils/libiberty/config.table
+++ b/contrib/binutils/libiberty/config.table
@@ -11,7 +11,7 @@ case "${host}" in
*-*-freebsd2.1.*) frag=mh-fbsd21 ;;
*-*-freebsd2.2.[012]) frag=mh-fbsd21 ;;
i370-*-opened*) frag=mh-openedition ;;
- i[345]86-*-windows*) frag=mh-windows ;;
+ i[34567]86-*-windows*) frag=mh-windows ;;
esac
if [ -n "${frag}" ]; then
@@ -34,7 +34,7 @@ if [ "${shared}" = "yes" ]; then
alpha*-*-linux*) frag=mh-elfalphapic ;;
arm*-*-*) frag=mh-armpic ;;
hppa*-*-*) frag=mh-papic ;;
- i[3456]86-*-* | x86_64-*-*)
+ i[34567]86-*-* | x86_64-*-*)
frag=mh-x86pic ;;
powerpc*-*-aix*) ;;
powerpc*-*-*) frag=mh-ppcpic ;;
diff --git a/contrib/binutils/libiberty/configure b/contrib/binutils/libiberty/configure
index cac9f56..2f65976 100755
--- a/contrib/binutils/libiberty/configure
+++ b/contrib/binutils/libiberty/configure
@@ -1,40 +1,324 @@
#! /bin/sh
-
# Guess values for system-dependent variables and create Makefiles.
-# Generated automatically using autoconf version 2.13
-# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
+# Generated by GNU Autoconf 2.57.
#
+# Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
+# Free Software Foundation, Inc.
# This configure script is free software; the Free Software Foundation
# gives unlimited permission to copy, distribute and modify it.
+## --------------------- ##
+## M4sh Initialization. ##
+## --------------------- ##
+
+# Be Bourne compatible
+if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
+ emulate sh
+ NULLCMD=:
+ # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
+ # is contrary to our usage. Disable this feature.
+ alias -g '${1+"$@"}'='"$@"'
+elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
+ set -o posix
+fi
+
+# Support unset when possible.
+if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
+ as_unset=unset
+else
+ as_unset=false
+fi
+
+
+# Work around bugs in pre-3.0 UWIN ksh.
+$as_unset ENV MAIL MAILPATH
+PS1='$ '
+PS2='> '
+PS4='+ '
+
+# NLS nuisances.
+for as_var in \
+ LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
+ LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
+ LC_TELEPHONE LC_TIME
+do
+ if (set +x; test -n "`(eval $as_var=C; export $as_var) 2>&1`"); then
+ eval $as_var=C; export $as_var
+ else
+ $as_unset $as_var
+ fi
+done
+
+# Required to use basename.
+if expr a : '\(a\)' >/dev/null 2>&1; then
+ as_expr=expr
+else
+ as_expr=false
+fi
+
+if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
+ as_basename=basename
+else
+ as_basename=false
+fi
+
+
+# Name of the executable.
+as_me=`$as_basename "$0" ||
+$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
+ X"$0" : 'X\(//\)$' \| \
+ X"$0" : 'X\(/\)$' \| \
+ . : '\(.\)' 2>/dev/null ||
+echo X/"$0" |
+ sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
+ /^X\/\(\/\/\)$/{ s//\1/; q; }
+ /^X\/\(\/\).*/{ s//\1/; q; }
+ s/.*/./; q'`
+
+
+# PATH needs CR, and LINENO needs CR and PATH.
+# Avoid depending upon Character Ranges.
+as_cr_letters='abcdefghijklmnopqrstuvwxyz'
+as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
+as_cr_Letters=$as_cr_letters$as_cr_LETTERS
+as_cr_digits='0123456789'
+as_cr_alnum=$as_cr_Letters$as_cr_digits
+
+# The user is always right.
+if test "${PATH_SEPARATOR+set}" != set; then
+ echo "#! /bin/sh" >conf$$.sh
+ echo "exit 0" >>conf$$.sh
+ chmod +x conf$$.sh
+ if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
+ PATH_SEPARATOR=';'
+ else
+ PATH_SEPARATOR=:
+ fi
+ rm -f conf$$.sh
+fi
+
+
+ as_lineno_1=$LINENO
+ as_lineno_2=$LINENO
+ as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
+ test "x$as_lineno_1" != "x$as_lineno_2" &&
+ test "x$as_lineno_3" = "x$as_lineno_2" || {
+ # Find who we are. Look in the path if we contain no path at all
+ # relative or not.
+ case $0 in
+ *[\\/]* ) as_myself=$0 ;;
+ *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
+done
+
+ ;;
+ esac
+ # We did not find ourselves, most probably we were run as `sh COMMAND'
+ # in which case we are not to be found in the path.
+ if test "x$as_myself" = x; then
+ as_myself=$0
+ fi
+ if test ! -f "$as_myself"; then
+ { echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2
+ { (exit 1); exit 1; }; }
+ fi
+ case $CONFIG_SHELL in
+ '')
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for as_base in sh bash ksh sh5; do
+ case $as_dir in
+ /*)
+ if ("$as_dir/$as_base" -c '
+ as_lineno_1=$LINENO
+ as_lineno_2=$LINENO
+ as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
+ test "x$as_lineno_1" != "x$as_lineno_2" &&
+ test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
+ $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
+ $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
+ CONFIG_SHELL=$as_dir/$as_base
+ export CONFIG_SHELL
+ exec "$CONFIG_SHELL" "$0" ${1+"$@"}
+ fi;;
+ esac
+ done
+done
+;;
+ esac
+
+ # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
+ # uniformly replaced by the line number. The first 'sed' inserts a
+ # line-number line before each line; the second 'sed' does the real
+ # work. The second script uses 'N' to pair each line-number line
+ # with the numbered line, and appends trailing '-' during
+ # substitution so that $LINENO is not a special case at line end.
+ # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
+ # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
+ sed '=' <$as_myself |
+ sed '
+ N
+ s,$,-,
+ : loop
+ s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
+ t loop
+ s,-$,,
+ s,^['$as_cr_digits']*\n,,
+ ' >$as_me.lineno &&
+ chmod +x $as_me.lineno ||
+ { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
+ { (exit 1); exit 1; }; }
+
+ # Don't try to exec as it changes $[0], causing all sort of problems
+ # (the dirname of $[0] is not the place where we might find the
+ # original and so on. Autoconf is especially sensible to this).
+ . ./$as_me.lineno
+ # Exit status is that of the last command.
+ exit
+}
+
+
+case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
+ *c*,-n*) ECHO_N= ECHO_C='
+' ECHO_T=' ' ;;
+ *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
+ *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
+esac
+
+if expr a : '\(a\)' >/dev/null 2>&1; then
+ as_expr=expr
+else
+ as_expr=false
+fi
+
+rm -f conf$$ conf$$.exe conf$$.file
+echo >conf$$.file
+if ln -s conf$$.file conf$$ 2>/dev/null; then
+ # We could just check for DJGPP; but this test a) works b) is more generic
+ # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
+ if test -f conf$$.exe; then
+ # Don't use ln at all; we don't have any links
+ as_ln_s='cp -p'
+ else
+ as_ln_s='ln -s'
+ fi
+elif ln conf$$.file conf$$ 2>/dev/null; then
+ as_ln_s=ln
+else
+ as_ln_s='cp -p'
+fi
+rm -f conf$$ conf$$.exe conf$$.file
+
+if mkdir -p . 2>/dev/null; then
+ as_mkdir_p=:
+else
+ as_mkdir_p=false
+fi
+
+as_executable_p="test -f"
+
+# Sed expression to map a string onto a valid CPP name.
+as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
+
+# Sed expression to map a string onto a valid variable name.
+as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
+
+
+# IFS
+# We need space, tab and new line, in precisely that order.
+as_nl='
+'
+IFS=" $as_nl"
+
+# CDPATH.
+$as_unset CDPATH
-# Defaults:
-ac_help=
+
+# Name of the host.
+# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
+# so uname gets run too.
+ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
+
+exec 6>&1
+
+#
+# Initializations.
+#
ac_default_prefix=/usr/local
-# Any additions from configure.in:
-ac_help="$ac_help
- --with-target-subdir=SUBDIR Configuring in a subdirectory for target"
-ac_help="$ac_help
- --with-build-subdir=SUBDIR Configuring in a subdirectory for build"
-ac_help="$ac_help
- --with-cross-host=HOST Configuring with a cross compiler"
-ac_help="$ac_help
- --with-newlib Configuring with newlib"
-ac_help="$ac_help
- --enable-maintainer-mode
- enable make rules and dependencies not useful
- (and sometimes confusing) to the casual installer"
-ac_help="$ac_help
- --enable-install-libiberty Install headers for end users"
+ac_config_libobj_dir=.
+cross_compiling=no
+subdirs=
+MFLAGS=
+MAKEFLAGS=
+SHELL=${CONFIG_SHELL-/bin/sh}
+
+# Maximum number of lines to put in a shell here document.
+# This variable seems obsolete. It should probably be removed, and
+# only ac_max_sed_lines should be used.
+: ${ac_max_here_lines=38}
+
+# Identity of this package.
+PACKAGE_NAME=
+PACKAGE_TARNAME=
+PACKAGE_VERSION=
+PACKAGE_STRING=
+PACKAGE_BUGREPORT=
+
+ac_unique_file="xmalloc.c"
+# Factoring default headers for most tests.
+ac_includes_default="\
+#include <stdio.h>
+#if HAVE_SYS_TYPES_H
+# include <sys/types.h>
+#endif
+#if HAVE_SYS_STAT_H
+# include <sys/stat.h>
+#endif
+#if STDC_HEADERS
+# include <stdlib.h>
+# include <stddef.h>
+#else
+# if HAVE_STDLIB_H
+# include <stdlib.h>
+# endif
+#endif
+#if HAVE_STRING_H
+# if !STDC_HEADERS && HAVE_MEMORY_H
+# include <memory.h>
+# endif
+# include <string.h>
+#endif
+#if HAVE_STRINGS_H
+# include <strings.h>
+#endif
+#if HAVE_INTTYPES_H
+# include <inttypes.h>
+#else
+# if HAVE_STDINT_H
+# include <stdint.h>
+# endif
+#endif
+#if HAVE_UNISTD_H
+# include <unistd.h>
+#endif"
+
+ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS libiberty_topdir MAINT NOTMAINT MAKEINFO BUILD_INFO PERL HAVE_PERL build build_cpu build_vendor build_os host host_cpu host_vendor host_os AR ac_ct_AR RANLIB ac_ct_RANLIB CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP ac_libiberty_warn_cflags NO_MINUS_C_MINUS_O OUTPUT_OPTION INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA EGREP LIBOBJS CHECK target_header_dir pexecute INSTALL_DEST LTLIBOBJS'
+ac_subst_files='host_makefile_frag'
# Initialize some variables set by options.
+ac_init_help=
+ac_init_version=false
# The variables have the same names as the options, with
# dashes changed to underlines.
-build=NONE
-cache_file=./config.cache
+cache_file=/dev/null
exec_prefix=NONE
-host=NONE
no_create=
-nonopt=NONE
no_recursion=
prefix=NONE
program_prefix=NONE
@@ -43,10 +327,15 @@ program_transform_name=s,x,x,
silent=
site=
srcdir=
-target=NONE
verbose=
x_includes=NONE
x_libraries=NONE
+
+# Installation directory options.
+# These are left unexpanded so users can "make install exec_prefix=/foo"
+# and all the variables that are supposed to be based on exec_prefix
+# by default will actually change.
+# Use braces instead of parens because sh, perl, etc. also accept them.
bindir='${exec_prefix}/bin'
sbindir='${exec_prefix}/sbin'
libexecdir='${exec_prefix}/libexec'
@@ -60,17 +349,9 @@ oldincludedir='/usr/include'
infodir='${prefix}/info'
mandir='${prefix}/man'
-# Initialize some other variables.
-subdirs=
-MFLAGS= MAKEFLAGS=
-SHELL=${CONFIG_SHELL-/bin/sh}
-# Maximum number of lines to put in a shell here document.
-ac_max_here_lines=12
-
ac_prev=
for ac_option
do
-
# If the previous option needs an argument, assign it.
if test -n "$ac_prev"; then
eval "$ac_prev=\$ac_option"
@@ -78,59 +359,59 @@ do
continue
fi
- case "$ac_option" in
- -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
- *) ac_optarg= ;;
- esac
+ ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
# Accept the important Cygnus configure options, so we can diagnose typos.
- case "$ac_option" in
+ case $ac_option in
-bindir | --bindir | --bindi | --bind | --bin | --bi)
ac_prev=bindir ;;
-bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
- bindir="$ac_optarg" ;;
+ bindir=$ac_optarg ;;
-build | --build | --buil | --bui | --bu)
- ac_prev=build ;;
+ ac_prev=build_alias ;;
-build=* | --build=* | --buil=* | --bui=* | --bu=*)
- build="$ac_optarg" ;;
+ build_alias=$ac_optarg ;;
-cache-file | --cache-file | --cache-fil | --cache-fi \
| --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
ac_prev=cache_file ;;
-cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
| --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
- cache_file="$ac_optarg" ;;
+ cache_file=$ac_optarg ;;
+
+ --config-cache | -C)
+ cache_file=config.cache ;;
-datadir | --datadir | --datadi | --datad | --data | --dat | --da)
ac_prev=datadir ;;
-datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
| --da=*)
- datadir="$ac_optarg" ;;
+ datadir=$ac_optarg ;;
-disable-* | --disable-*)
- ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
+ ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
# Reject names that are not valid shell variable names.
- if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
- { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
- fi
- ac_feature=`echo $ac_feature| sed 's/-/_/g'`
- eval "enable_${ac_feature}=no" ;;
+ expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
+ { echo "$as_me: error: invalid feature name: $ac_feature" >&2
+ { (exit 1); exit 1; }; }
+ ac_feature=`echo $ac_feature | sed 's/-/_/g'`
+ eval "enable_$ac_feature=no" ;;
-enable-* | --enable-*)
- ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
+ ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
# Reject names that are not valid shell variable names.
- if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
- { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
- fi
- ac_feature=`echo $ac_feature| sed 's/-/_/g'`
- case "$ac_option" in
- *=*) ;;
+ expr "x$ac_feature" : ".*[^-_$as_cr_alnum]" >/dev/null &&
+ { echo "$as_me: error: invalid feature name: $ac_feature" >&2
+ { (exit 1); exit 1; }; }
+ ac_feature=`echo $ac_feature | sed 's/-/_/g'`
+ case $ac_option in
+ *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
*) ac_optarg=yes ;;
esac
- eval "enable_${ac_feature}='$ac_optarg'" ;;
+ eval "enable_$ac_feature='$ac_optarg'" ;;
-exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
| --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
@@ -139,95 +420,47 @@ do
-exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
| --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
| --exec=* | --exe=* | --ex=*)
- exec_prefix="$ac_optarg" ;;
+ exec_prefix=$ac_optarg ;;
-gas | --gas | --ga | --g)
# Obsolete; use --with-gas.
with_gas=yes ;;
- -help | --help | --hel | --he)
- # Omit some internal or obsolete options to make the list less imposing.
- # This message is too long to be a string in the A/UX 3.1 sh.
- cat << EOF
-Usage: configure [options] [host]
-Options: [defaults in brackets after descriptions]
-Configuration:
- --cache-file=FILE cache test results in FILE
- --help print this message
- --no-create do not create output files
- --quiet, --silent do not print \`checking...' messages
- --version print the version of autoconf that created configure
-Directory and file names:
- --prefix=PREFIX install architecture-independent files in PREFIX
- [$ac_default_prefix]
- --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
- [same as prefix]
- --bindir=DIR user executables in DIR [EPREFIX/bin]
- --sbindir=DIR system admin executables in DIR [EPREFIX/sbin]
- --libexecdir=DIR program executables in DIR [EPREFIX/libexec]
- --datadir=DIR read-only architecture-independent data in DIR
- [PREFIX/share]
- --sysconfdir=DIR read-only single-machine data in DIR [PREFIX/etc]
- --sharedstatedir=DIR modifiable architecture-independent data in DIR
- [PREFIX/com]
- --localstatedir=DIR modifiable single-machine data in DIR [PREFIX/var]
- --libdir=DIR object code libraries in DIR [EPREFIX/lib]
- --includedir=DIR C header files in DIR [PREFIX/include]
- --oldincludedir=DIR C header files for non-gcc in DIR [/usr/include]
- --infodir=DIR info documentation in DIR [PREFIX/info]
- --mandir=DIR man documentation in DIR [PREFIX/man]
- --srcdir=DIR find the sources in DIR [configure dir or ..]
- --program-prefix=PREFIX prepend PREFIX to installed program names
- --program-suffix=SUFFIX append SUFFIX to installed program names
- --program-transform-name=PROGRAM
- run sed PROGRAM on installed program names
-EOF
- cat << EOF
-Host type:
- --build=BUILD configure for building on BUILD [BUILD=HOST]
- --host=HOST configure for HOST [guessed]
- --target=TARGET configure for TARGET [TARGET=HOST]
-Features and packages:
- --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
- --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
- --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
- --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
- --x-includes=DIR X include files are in DIR
- --x-libraries=DIR X library files are in DIR
-EOF
- if test -n "$ac_help"; then
- echo "--enable and --with options recognized:$ac_help"
- fi
- exit 0 ;;
+ -help | --help | --hel | --he | -h)
+ ac_init_help=long ;;
+ -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
+ ac_init_help=recursive ;;
+ -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
+ ac_init_help=short ;;
-host | --host | --hos | --ho)
- ac_prev=host ;;
+ ac_prev=host_alias ;;
-host=* | --host=* | --hos=* | --ho=*)
- host="$ac_optarg" ;;
+ host_alias=$ac_optarg ;;
-includedir | --includedir | --includedi | --included | --include \
| --includ | --inclu | --incl | --inc)
ac_prev=includedir ;;
-includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
| --includ=* | --inclu=* | --incl=* | --inc=*)
- includedir="$ac_optarg" ;;
+ includedir=$ac_optarg ;;
-infodir | --infodir | --infodi | --infod | --info | --inf)
ac_prev=infodir ;;
-infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
- infodir="$ac_optarg" ;;
+ infodir=$ac_optarg ;;
-libdir | --libdir | --libdi | --libd)
ac_prev=libdir ;;
-libdir=* | --libdir=* | --libdi=* | --libd=*)
- libdir="$ac_optarg" ;;
+ libdir=$ac_optarg ;;
-libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
| --libexe | --libex | --libe)
ac_prev=libexecdir ;;
-libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
| --libexe=* | --libex=* | --libe=*)
- libexecdir="$ac_optarg" ;;
+ libexecdir=$ac_optarg ;;
-localstatedir | --localstatedir | --localstatedi | --localstated \
| --localstate | --localstat | --localsta | --localst \
@@ -236,19 +469,19 @@ EOF
-localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
| --localstate=* | --localstat=* | --localsta=* | --localst=* \
| --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
- localstatedir="$ac_optarg" ;;
+ localstatedir=$ac_optarg ;;
-mandir | --mandir | --mandi | --mand | --man | --ma | --m)
ac_prev=mandir ;;
-mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
- mandir="$ac_optarg" ;;
+ mandir=$ac_optarg ;;
-nfp | --nfp | --nf)
# Obsolete; use --without-fp.
with_fp=no ;;
-no-create | --no-create | --no-creat | --no-crea | --no-cre \
- | --no-cr | --no-c)
+ | --no-cr | --no-c | -n)
no_create=yes ;;
-no-recursion | --no-recursion | --no-recursio | --no-recursi \
@@ -262,26 +495,26 @@ EOF
-oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
| --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
| --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
- oldincludedir="$ac_optarg" ;;
+ oldincludedir=$ac_optarg ;;
-prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
ac_prev=prefix ;;
-prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
- prefix="$ac_optarg" ;;
+ prefix=$ac_optarg ;;
-program-prefix | --program-prefix | --program-prefi | --program-pref \
| --program-pre | --program-pr | --program-p)
ac_prev=program_prefix ;;
-program-prefix=* | --program-prefix=* | --program-prefi=* \
| --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
- program_prefix="$ac_optarg" ;;
+ program_prefix=$ac_optarg ;;
-program-suffix | --program-suffix | --program-suffi | --program-suff \
| --program-suf | --program-su | --program-s)
ac_prev=program_suffix ;;
-program-suffix=* | --program-suffix=* | --program-suffi=* \
| --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
- program_suffix="$ac_optarg" ;;
+ program_suffix=$ac_optarg ;;
-program-transform-name | --program-transform-name \
| --program-transform-nam | --program-transform-na \
@@ -298,7 +531,7 @@ EOF
| --program-transfo=* | --program-transf=* \
| --program-trans=* | --program-tran=* \
| --progr-tra=* | --program-tr=* | --program-t=*)
- program_transform_name="$ac_optarg" ;;
+ program_transform_name=$ac_optarg ;;
-q | -quiet | --quiet | --quie | --qui | --qu | --q \
| -silent | --silent | --silen | --sile | --sil)
@@ -308,7 +541,7 @@ EOF
ac_prev=sbindir ;;
-sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
| --sbi=* | --sb=*)
- sbindir="$ac_optarg" ;;
+ sbindir=$ac_optarg ;;
-sharedstatedir | --sharedstatedir | --sharedstatedi \
| --sharedstated | --sharedstate | --sharedstat | --sharedsta \
@@ -319,58 +552,57 @@ EOF
| --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
| --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
| --sha=* | --sh=*)
- sharedstatedir="$ac_optarg" ;;
+ sharedstatedir=$ac_optarg ;;
-site | --site | --sit)
ac_prev=site ;;
-site=* | --site=* | --sit=*)
- site="$ac_optarg" ;;
+ site=$ac_optarg ;;
-srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
ac_prev=srcdir ;;
-srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
- srcdir="$ac_optarg" ;;
+ srcdir=$ac_optarg ;;
-sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
| --syscon | --sysco | --sysc | --sys | --sy)
ac_prev=sysconfdir ;;
-sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
| --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
- sysconfdir="$ac_optarg" ;;
+ sysconfdir=$ac_optarg ;;
-target | --target | --targe | --targ | --tar | --ta | --t)
- ac_prev=target ;;
+ ac_prev=target_alias ;;
-target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
- target="$ac_optarg" ;;
+ target_alias=$ac_optarg ;;
-v | -verbose | --verbose | --verbos | --verbo | --verb)
verbose=yes ;;
- -version | --version | --versio | --versi | --vers)
- echo "configure generated by autoconf version 2.13"
- exit 0 ;;
+ -version | --version | --versio | --versi | --vers | -V)
+ ac_init_version=: ;;
-with-* | --with-*)
- ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
+ ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
# Reject names that are not valid shell variable names.
- if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
- { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
- fi
+ expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
+ { echo "$as_me: error: invalid package name: $ac_package" >&2
+ { (exit 1); exit 1; }; }
ac_package=`echo $ac_package| sed 's/-/_/g'`
- case "$ac_option" in
- *=*) ;;
+ case $ac_option in
+ *=*) ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`;;
*) ac_optarg=yes ;;
esac
- eval "with_${ac_package}='$ac_optarg'" ;;
+ eval "with_$ac_package='$ac_optarg'" ;;
-without-* | --without-*)
- ac_package=`echo $ac_option|sed -e 's/-*without-//'`
+ ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
# Reject names that are not valid shell variable names.
- if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
- { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
- fi
- ac_package=`echo $ac_package| sed 's/-/_/g'`
- eval "with_${ac_package}=no" ;;
+ expr "x$ac_package" : ".*[^-_$as_cr_alnum]" >/dev/null &&
+ { echo "$as_me: error: invalid package name: $ac_package" >&2
+ { (exit 1); exit 1; }; }
+ ac_package=`echo $ac_package | sed 's/-/_/g'`
+ eval "with_$ac_package=no" ;;
--x)
# Obsolete; use --with-x.
@@ -381,99 +613,110 @@ EOF
ac_prev=x_includes ;;
-x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
| --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
- x_includes="$ac_optarg" ;;
+ x_includes=$ac_optarg ;;
-x-libraries | --x-libraries | --x-librarie | --x-librari \
| --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
ac_prev=x_libraries ;;
-x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
| --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
- x_libraries="$ac_optarg" ;;
+ x_libraries=$ac_optarg ;;
- -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
+ -*) { echo "$as_me: error: unrecognized option: $ac_option
+Try \`$0 --help' for more information." >&2
+ { (exit 1); exit 1; }; }
;;
+ *=*)
+ ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
+ # Reject names that are not valid shell variable names.
+ expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
+ { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
+ { (exit 1); exit 1; }; }
+ ac_optarg=`echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"`
+ eval "$ac_envvar='$ac_optarg'"
+ export $ac_envvar ;;
+
*)
- if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
- echo "configure: warning: $ac_option: invalid host type" 1>&2
- fi
- if test "x$nonopt" != xNONE; then
- { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
- fi
- nonopt="$ac_option"
+ # FIXME: should be removed in autoconf 3.0.
+ echo "$as_me: WARNING: you should use --build, --host, --target" >&2
+ expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
+ echo "$as_me: WARNING: invalid host type: $ac_option" >&2
+ : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
;;
esac
done
if test -n "$ac_prev"; then
- { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
+ ac_option=--`echo $ac_prev | sed 's/_/-/g'`
+ { echo "$as_me: error: missing argument to $ac_option" >&2
+ { (exit 1); exit 1; }; }
fi
-trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
-
-# File descriptor usage:
-# 0 standard input
-# 1 file creation
-# 2 errors and warnings
-# 3 some systems may open it to /dev/tty
-# 4 used on the Kubota Titan
-# 6 checking for... messages and results
-# 5 compiler messages saved in config.log
-if test "$silent" = yes; then
- exec 6>/dev/null
-else
- exec 6>&1
-fi
-exec 5>./config.log
-
-echo "\
-This file contains any messages produced by compilers while
-running configure, to aid debugging if configure makes a mistake.
-" 1>&5
+# Be sure to have absolute paths.
+for ac_var in exec_prefix prefix
+do
+ eval ac_val=$`echo $ac_var`
+ case $ac_val in
+ [\\/$]* | ?:[\\/]* | NONE | '' ) ;;
+ *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
+ { (exit 1); exit 1; }; };;
+ esac
+done
-# Strip out --no-create and --no-recursion so they do not pile up.
-# Also quote any args containing shell metacharacters.
-ac_configure_args=
-for ac_arg
+# Be sure to have absolute paths.
+for ac_var in bindir sbindir libexecdir datadir sysconfdir sharedstatedir \
+ localstatedir libdir includedir oldincludedir infodir mandir
do
- case "$ac_arg" in
- -no-create | --no-create | --no-creat | --no-crea | --no-cre \
- | --no-cr | --no-c) ;;
- -no-recursion | --no-recursion | --no-recursio | --no-recursi \
- | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
- *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
- ac_configure_args="$ac_configure_args '$ac_arg'" ;;
- *) ac_configure_args="$ac_configure_args $ac_arg" ;;
+ eval ac_val=$`echo $ac_var`
+ case $ac_val in
+ [\\/$]* | ?:[\\/]* ) ;;
+ *) { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
+ { (exit 1); exit 1; }; };;
esac
done
-# NLS nuisances.
-# Only set these to C if already set. These must not be set unconditionally
-# because not all systems understand e.g. LANG=C (notably SCO).
-# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
-# Non-C LC_CTYPE values break the ctype check.
-if test "${LANG+set}" = set; then LANG=C; export LANG; fi
-if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
-if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
-if test "${LC_CTYPE+set}" = set; then LC_CTYPE=C; export LC_CTYPE; fi
+# There might be people who depend on the old broken behavior: `$host'
+# used to hold the argument of --host etc.
+# FIXME: To remove some day.
+build=$build_alias
+host=$host_alias
+target=$target_alias
+
+# FIXME: To remove some day.
+if test "x$host_alias" != x; then
+ if test "x$build_alias" = x; then
+ cross_compiling=maybe
+ echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
+ If a cross compiler is detected then cross compile mode will be used." >&2
+ elif test "x$build_alias" != "x$host_alias"; then
+ cross_compiling=yes
+ fi
+fi
-# confdefs.h avoids OS command line length limits that DEFS can exceed.
-rm -rf conftest* confdefs.h
-# AIX cpp loses on an empty file, so make sure it contains at least a newline.
-echo > confdefs.h
+ac_tool_prefix=
+test -n "$host_alias" && ac_tool_prefix=$host_alias-
+
+test "$silent" = yes && exec 6>/dev/null
-# A filename unique to this package, relative to the directory that
-# configure is in, which we can look for to find out if srcdir is correct.
-ac_unique_file=pexecute.c
# Find the source files, if location was not specified.
if test -z "$srcdir"; then
ac_srcdir_defaulted=yes
# Try the directory containing this script, then its parent.
- ac_prog=$0
- ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
- test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
+ ac_confdir=`(dirname "$0") 2>/dev/null ||
+$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
+ X"$0" : 'X\(//\)[^/]' \| \
+ X"$0" : 'X\(//\)$' \| \
+ X"$0" : 'X\(/\)' \| \
+ . : '\(.\)' 2>/dev/null ||
+echo X"$0" |
+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
+ /^X\(\/\/\)[^/].*/{ s//\1/; q; }
+ /^X\(\/\/\)$/{ s//\1/; q; }
+ /^X\(\/\).*/{ s//\1/; q; }
+ s/.*/./; q'`
srcdir=$ac_confdir
if test ! -r $srcdir/$ac_unique_file; then
srcdir=..
@@ -483,13 +726,442 @@ else
fi
if test ! -r $srcdir/$ac_unique_file; then
if test "$ac_srcdir_defaulted" = yes; then
- { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
+ { echo "$as_me: error: cannot find sources ($ac_unique_file) in $ac_confdir or .." >&2
+ { (exit 1); exit 1; }; }
else
- { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
+ { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
+ { (exit 1); exit 1; }; }
fi
fi
-srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
+(cd $srcdir && test -r ./$ac_unique_file) 2>/dev/null ||
+ { echo "$as_me: error: sources are in $srcdir, but \`cd $srcdir' does not work" >&2
+ { (exit 1); exit 1; }; }
+srcdir=`echo "$srcdir" | sed 's%\([^\\/]\)[\\/]*$%\1%'`
+ac_env_build_alias_set=${build_alias+set}
+ac_env_build_alias_value=$build_alias
+ac_cv_env_build_alias_set=${build_alias+set}
+ac_cv_env_build_alias_value=$build_alias
+ac_env_host_alias_set=${host_alias+set}
+ac_env_host_alias_value=$host_alias
+ac_cv_env_host_alias_set=${host_alias+set}
+ac_cv_env_host_alias_value=$host_alias
+ac_env_target_alias_set=${target_alias+set}
+ac_env_target_alias_value=$target_alias
+ac_cv_env_target_alias_set=${target_alias+set}
+ac_cv_env_target_alias_value=$target_alias
+ac_env_CC_set=${CC+set}
+ac_env_CC_value=$CC
+ac_cv_env_CC_set=${CC+set}
+ac_cv_env_CC_value=$CC
+ac_env_CFLAGS_set=${CFLAGS+set}
+ac_env_CFLAGS_value=$CFLAGS
+ac_cv_env_CFLAGS_set=${CFLAGS+set}
+ac_cv_env_CFLAGS_value=$CFLAGS
+ac_env_LDFLAGS_set=${LDFLAGS+set}
+ac_env_LDFLAGS_value=$LDFLAGS
+ac_cv_env_LDFLAGS_set=${LDFLAGS+set}
+ac_cv_env_LDFLAGS_value=$LDFLAGS
+ac_env_CPPFLAGS_set=${CPPFLAGS+set}
+ac_env_CPPFLAGS_value=$CPPFLAGS
+ac_cv_env_CPPFLAGS_set=${CPPFLAGS+set}
+ac_cv_env_CPPFLAGS_value=$CPPFLAGS
+ac_env_CPP_set=${CPP+set}
+ac_env_CPP_value=$CPP
+ac_cv_env_CPP_set=${CPP+set}
+ac_cv_env_CPP_value=$CPP
+
+#
+# Report the --help message.
+#
+if test "$ac_init_help" = "long"; then
+ # Omit some internal or obsolete options to make the list less imposing.
+ # This message is too long to be a string in the A/UX 3.1 sh.
+ cat <<_ACEOF
+\`configure' configures this package to adapt to many kinds of systems.
+
+Usage: $0 [OPTION]... [VAR=VALUE]...
+
+To assign environment variables (e.g., CC, CFLAGS...), specify them as
+VAR=VALUE. See below for descriptions of some of the useful variables.
+
+Defaults for the options are specified in brackets.
+
+Configuration:
+ -h, --help display this help and exit
+ --help=short display options specific to this package
+ --help=recursive display the short help of all the included packages
+ -V, --version display version information and exit
+ -q, --quiet, --silent do not print \`checking...' messages
+ --cache-file=FILE cache test results in FILE [disabled]
+ -C, --config-cache alias for \`--cache-file=config.cache'
+ -n, --no-create do not create output files
+ --srcdir=DIR find the sources in DIR [configure dir or \`..']
+
+_ACEOF
+
+ cat <<_ACEOF
+Installation directories:
+ --prefix=PREFIX install architecture-independent files in PREFIX
+ [$ac_default_prefix]
+ --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
+ [PREFIX]
+
+By default, \`make install' will install all the files in
+\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
+an installation prefix other than \`$ac_default_prefix' using \`--prefix',
+for instance \`--prefix=\$HOME'.
+
+For better control, use the options below.
+
+Fine tuning of the installation directories:
+ --bindir=DIR user executables [EPREFIX/bin]
+ --sbindir=DIR system admin executables [EPREFIX/sbin]
+ --libexecdir=DIR program executables [EPREFIX/libexec]
+ --datadir=DIR read-only architecture-independent data [PREFIX/share]
+ --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
+ --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
+ --localstatedir=DIR modifiable single-machine data [PREFIX/var]
+ --libdir=DIR object code libraries [EPREFIX/lib]
+ --includedir=DIR C header files [PREFIX/include]
+ --oldincludedir=DIR C header files for non-gcc [/usr/include]
+ --infodir=DIR info documentation [PREFIX/info]
+ --mandir=DIR man documentation [PREFIX/man]
+_ACEOF
+
+ cat <<\_ACEOF
+
+System types:
+ --build=BUILD configure for building on BUILD [guessed]
+ --host=HOST cross-compile to build programs to run on HOST [BUILD]
+_ACEOF
+fi
+
+if test -n "$ac_init_help"; then
+
+ cat <<\_ACEOF
+
+Optional Features:
+ --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
+ --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
+ --enable-maintainer-mode
+ enable make rules and dependencies not useful
+ (and sometimes confusing) to the casual installer
+ --enable-install-libiberty Install headers for end users
+
+Optional Packages:
+ --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
+ --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
+ --with-target-subdir=SUBDIR Configuring in a subdirectory for target
+ --with-build-subdir=SUBDIR Configuring in a subdirectory for build
+ --with-cross-host=HOST Configuring with a cross compiler
+ --with-newlib Configuring with newlib
+
+Some influential environment variables:
+ CC C compiler command
+ CFLAGS C compiler flags
+ LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
+ nonstandard directory <lib dir>
+ CPPFLAGS C/C++ preprocessor flags, e.g. -I<include dir> if you have
+ headers in a nonstandard directory <include dir>
+ CPP C preprocessor
+
+Use these variables to override the choices made by `configure' or to help
+it to find libraries and programs with nonstandard names/locations.
+
+_ACEOF
+fi
+
+if test "$ac_init_help" = "recursive"; then
+ # If there are subdirs, report their specific --help.
+ ac_popdir=`pwd`
+ for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
+ test -d $ac_dir || continue
+ ac_builddir=.
+
+if test "$ac_dir" != .; then
+ ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
+ # A "../" for each directory in $ac_dir_suffix.
+ ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
+else
+ ac_dir_suffix= ac_top_builddir=
+fi
+
+case $srcdir in
+ .) # No --srcdir option. We are building in place.
+ ac_srcdir=.
+ if test -z "$ac_top_builddir"; then
+ ac_top_srcdir=.
+ else
+ ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
+ fi ;;
+ [\\/]* | ?:[\\/]* ) # Absolute path.
+ ac_srcdir=$srcdir$ac_dir_suffix;
+ ac_top_srcdir=$srcdir ;;
+ *) # Relative path.
+ ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
+ ac_top_srcdir=$ac_top_builddir$srcdir ;;
+esac
+# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
+# absolute.
+ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
+ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
+ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
+ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
+
+ cd $ac_dir
+ # Check for guested configure; otherwise get Cygnus style configure.
+ if test -f $ac_srcdir/configure.gnu; then
+ echo
+ $SHELL $ac_srcdir/configure.gnu --help=recursive
+ elif test -f $ac_srcdir/configure; then
+ echo
+ $SHELL $ac_srcdir/configure --help=recursive
+ elif test -f $ac_srcdir/configure.ac ||
+ test -f $ac_srcdir/configure.in; then
+ echo
+ $ac_configure --help
+ else
+ echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
+ fi
+ cd $ac_popdir
+ done
+fi
+
+test -n "$ac_init_help" && exit 0
+if $ac_init_version; then
+ cat <<\_ACEOF
+
+Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002
+Free Software Foundation, Inc.
+This configure script is free software; the Free Software Foundation
+gives unlimited permission to copy, distribute and modify it.
+_ACEOF
+ exit 0
+fi
+exec 5>config.log
+cat >&5 <<_ACEOF
+This file contains any messages produced by compilers while
+running configure, to aid debugging if configure makes a mistake.
+
+It was created by $as_me, which was
+generated by GNU Autoconf 2.57. Invocation command line was
+
+ $ $0 $@
+
+_ACEOF
+{
+cat <<_ASUNAME
+## --------- ##
+## Platform. ##
+## --------- ##
+
+hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
+uname -m = `(uname -m) 2>/dev/null || echo unknown`
+uname -r = `(uname -r) 2>/dev/null || echo unknown`
+uname -s = `(uname -s) 2>/dev/null || echo unknown`
+uname -v = `(uname -v) 2>/dev/null || echo unknown`
+
+/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
+/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
+
+/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
+/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
+/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
+hostinfo = `(hostinfo) 2>/dev/null || echo unknown`
+/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
+/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
+/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
+
+_ASUNAME
+
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ echo "PATH: $as_dir"
+done
+
+} >&5
+
+cat >&5 <<_ACEOF
+
+
+## ----------- ##
+## Core tests. ##
+## ----------- ##
+
+_ACEOF
+
+
+# Keep a trace of the command line.
+# Strip out --no-create and --no-recursion so they do not pile up.
+# Strip out --silent because we don't want to record it for future runs.
+# Also quote any args containing shell meta-characters.
+# Make two passes to allow for proper duplicate-argument suppression.
+ac_configure_args=
+ac_configure_args0=
+ac_configure_args1=
+ac_sep=
+ac_must_keep_next=false
+for ac_pass in 1 2
+do
+ for ac_arg
+ do
+ case $ac_arg in
+ -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
+ -q | -quiet | --quiet | --quie | --qui | --qu | --q \
+ | -silent | --silent | --silen | --sile | --sil)
+ continue ;;
+ *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
+ ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
+ esac
+ case $ac_pass in
+ 1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
+ 2)
+ ac_configure_args1="$ac_configure_args1 '$ac_arg'"
+ if test $ac_must_keep_next = true; then
+ ac_must_keep_next=false # Got value, back to normal.
+ else
+ case $ac_arg in
+ *=* | --config-cache | -C | -disable-* | --disable-* \
+ | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
+ | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
+ | -with-* | --with-* | -without-* | --without-* | --x)
+ case "$ac_configure_args0 " in
+ "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
+ esac
+ ;;
+ -* ) ac_must_keep_next=true ;;
+ esac
+ fi
+ ac_configure_args="$ac_configure_args$ac_sep'$ac_arg'"
+ # Get rid of the leading space.
+ ac_sep=" "
+ ;;
+ esac
+ done
+done
+$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
+$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
+
+# When interrupted or exit'd, cleanup temporary files, and complete
+# config.log. We remove comments because anyway the quotes in there
+# would cause problems or look ugly.
+# WARNING: Be sure not to use single quotes in there, as some shells,
+# such as our DU 5.0 friend, will then `close' the trap.
+trap 'exit_status=$?
+ # Save into config.log some information that might help in debugging.
+ {
+ echo
+
+ cat <<\_ASBOX
+## ---------------- ##
+## Cache variables. ##
+## ---------------- ##
+_ASBOX
+ echo
+ # The following way of writing the cache mishandles newlines in values,
+{
+ (set) 2>&1 |
+ case `(ac_space='"'"' '"'"'; set | grep ac_space) 2>&1` in
+ *ac_space=\ *)
+ sed -n \
+ "s/'"'"'/'"'"'\\\\'"'"''"'"'/g;
+ s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='"'"'\\2'"'"'/p"
+ ;;
+ *)
+ sed -n \
+ "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
+ ;;
+ esac;
+}
+ echo
+
+ cat <<\_ASBOX
+## ----------------- ##
+## Output variables. ##
+## ----------------- ##
+_ASBOX
+ echo
+ for ac_var in $ac_subst_vars
+ do
+ eval ac_val=$`echo $ac_var`
+ echo "$ac_var='"'"'$ac_val'"'"'"
+ done | sort
+ echo
+
+ if test -n "$ac_subst_files"; then
+ cat <<\_ASBOX
+## ------------- ##
+## Output files. ##
+## ------------- ##
+_ASBOX
+ echo
+ for ac_var in $ac_subst_files
+ do
+ eval ac_val=$`echo $ac_var`
+ echo "$ac_var='"'"'$ac_val'"'"'"
+ done | sort
+ echo
+ fi
+
+ if test -s confdefs.h; then
+ cat <<\_ASBOX
+## ----------- ##
+## confdefs.h. ##
+## ----------- ##
+_ASBOX
+ echo
+ sed "/^$/d" confdefs.h | sort
+ echo
+ fi
+ test "$ac_signal" != 0 &&
+ echo "$as_me: caught signal $ac_signal"
+ echo "$as_me: exit $exit_status"
+ } >&5
+ rm -f core core.* *.core &&
+ rm -rf conftest* confdefs* conf$$* $ac_clean_files &&
+ exit $exit_status
+ ' 0
+for ac_signal in 1 2 13 15; do
+ trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
+done
+ac_signal=0
+
+# confdefs.h avoids OS command line length limits that DEFS can exceed.
+rm -rf conftest* confdefs.h
+# AIX cpp loses on an empty file, so make sure it contains at least a newline.
+echo >confdefs.h
+
+# Predefined preprocessor variables.
+
+cat >>confdefs.h <<_ACEOF
+#define PACKAGE_NAME "$PACKAGE_NAME"
+_ACEOF
+
+
+cat >>confdefs.h <<_ACEOF
+#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
+_ACEOF
+
+cat >>confdefs.h <<_ACEOF
+#define PACKAGE_VERSION "$PACKAGE_VERSION"
+_ACEOF
+
+
+cat >>confdefs.h <<_ACEOF
+#define PACKAGE_STRING "$PACKAGE_STRING"
+_ACEOF
+
+
+cat >>confdefs.h <<_ACEOF
+#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
+_ACEOF
+
+
+# Let the site file select an alternate cache file if it wants to.
# Prefer explicitly selected file to automatically selected ones.
if test -z "$CONFIG_SITE"; then
if test "x$prefix" != xNONE; then
@@ -500,39 +1172,103 @@ if test -z "$CONFIG_SITE"; then
fi
for ac_site_file in $CONFIG_SITE; do
if test -r "$ac_site_file"; then
- echo "loading site script $ac_site_file"
+ { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
+echo "$as_me: loading site script $ac_site_file" >&6;}
+ sed 's/^/| /' "$ac_site_file" >&5
. "$ac_site_file"
fi
done
if test -r "$cache_file"; then
- echo "loading cache $cache_file"
- . $cache_file
+ # Some versions of bash will fail to source /dev/null (special
+ # files actually), so we avoid doing that.
+ if test -f "$cache_file"; then
+ { echo "$as_me:$LINENO: loading cache $cache_file" >&5
+echo "$as_me: loading cache $cache_file" >&6;}
+ case $cache_file in
+ [\\/]* | ?:[\\/]* ) . $cache_file;;
+ *) . ./$cache_file;;
+ esac
+ fi
else
- echo "creating cache $cache_file"
- > $cache_file
+ { echo "$as_me:$LINENO: creating cache $cache_file" >&5
+echo "$as_me: creating cache $cache_file" >&6;}
+ >$cache_file
+fi
+
+# Check that the precious variables saved in the cache have kept the same
+# value.
+ac_cache_corrupted=false
+for ac_var in `(set) 2>&1 |
+ sed -n 's/^ac_env_\([a-zA-Z_0-9]*\)_set=.*/\1/p'`; do
+ eval ac_old_set=\$ac_cv_env_${ac_var}_set
+ eval ac_new_set=\$ac_env_${ac_var}_set
+ eval ac_old_val="\$ac_cv_env_${ac_var}_value"
+ eval ac_new_val="\$ac_env_${ac_var}_value"
+ case $ac_old_set,$ac_new_set in
+ set,)
+ { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
+echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
+ ac_cache_corrupted=: ;;
+ ,set)
+ { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
+echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
+ ac_cache_corrupted=: ;;
+ ,);;
+ *)
+ if test "x$ac_old_val" != "x$ac_new_val"; then
+ { echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
+echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
+ { echo "$as_me:$LINENO: former value: $ac_old_val" >&5
+echo "$as_me: former value: $ac_old_val" >&2;}
+ { echo "$as_me:$LINENO: current value: $ac_new_val" >&5
+echo "$as_me: current value: $ac_new_val" >&2;}
+ ac_cache_corrupted=:
+ fi;;
+ esac
+ # Pass precious variables to config.status.
+ if test "$ac_new_set" = set; then
+ case $ac_new_val in
+ *" "*|*" "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?\"\']*)
+ ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
+ *) ac_arg=$ac_var=$ac_new_val ;;
+ esac
+ case " $ac_configure_args " in
+ *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
+ *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
+ esac
+ fi
+done
+if $ac_cache_corrupted; then
+ { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
+echo "$as_me: error: changes in the environment can compromise the build" >&2;}
+ { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
+echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
+ { (exit 1); exit 1; }; }
fi
ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-ac_exeext=
-ac_objext=o
-if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
- # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
- if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
- ac_n= ac_c='
-' ac_t=' '
- else
- ac_n=-n ac_c= ac_t=
- fi
-else
- ac_n= ac_c='\c' ac_t=
-fi
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -542,30 +1278,30 @@ fi
# exported. We don't use libtool yet, but some day we might, so...
ORIGINAL_LD_FOR_MULTILIBS=$LD
+
# Check whether --with-target-subdir or --without-target-subdir was given.
if test "${with_target_subdir+set}" = set; then
withval="$with_target_subdir"
- :
-fi
+
+fi;
# Check whether --with-build-subdir or --without-build-subdir was given.
if test "${with_build_subdir+set}" = set; then
withval="$with_build_subdir"
- :
-fi
+
+fi;
# Check whether --with-cross-host or --without-cross-host was given.
if test "${with_cross_host+set}" = set; then
withval="$with_cross_host"
- :
-fi
+
+fi;
# Check whether --with-newlib or --without-newlib was given.
if test "${with_newlib+set}" = set; then
withval="$with_newlib"
- :
-fi
+fi;
if test "${srcdir}" = "."; then
if test -n "${with_build_subdir}"; then
@@ -583,6 +1319,7 @@ if test "${srcdir}" = "."; then
else
libiberty_topdir="${srcdir}/.."
fi
+
ac_aux_dir=
for ac_dir in $libiberty_topdir $srcdir/$libiberty_topdir; do
if test -f $ac_dir/install-sh; then
@@ -593,29 +1330,35 @@ for ac_dir in $libiberty_topdir $srcdir/$libiberty_topdir; do
ac_aux_dir=$ac_dir
ac_install_sh="$ac_aux_dir/install.sh -c"
break
+ elif test -f $ac_dir/shtool; then
+ ac_aux_dir=$ac_dir
+ ac_install_sh="$ac_aux_dir/shtool install -c"
+ break
fi
done
if test -z "$ac_aux_dir"; then
- { echo "configure: error: can not find install-sh or install.sh in $libiberty_topdir $srcdir/$libiberty_topdir" 1>&2; exit 1; }
+ { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in $libiberty_topdir $srcdir/$libiberty_topdir" >&5
+echo "$as_me: error: cannot find install-sh or install.sh in $libiberty_topdir $srcdir/$libiberty_topdir" >&2;}
+ { (exit 1); exit 1; }; }
fi
-ac_config_guess=$ac_aux_dir/config.guess
-ac_config_sub=$ac_aux_dir/config.sub
-ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
+ac_config_guess="$SHELL $ac_aux_dir/config.guess"
+ac_config_sub="$SHELL $ac_aux_dir/config.sub"
+ac_configure="$SHELL $ac_aux_dir/configure" # This should be Cygnus configure.
-echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:609: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "$as_me:$LINENO: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo $ECHO_N "checking whether to enable maintainer-specific portions of Makefiles... $ECHO_C" >&6
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
maintainer_mode=$enableval
else
maintainer_mode=no
-fi
+fi;
-
-echo "$ac_t""$maintainer_mode" 1>&6
+echo "$as_me:$LINENO: result: $maintainer_mode" >&5
+echo "${ECHO_T}$maintainer_mode" >&6
if test "$maintainer_mode" = "yes"; then
MAINT=''
@@ -629,31 +1372,37 @@ fi
# rely on it - libiberty is built before texinfo.
# Extract the first word of "makeinfo", so it can be a program name with args.
set dummy makeinfo; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:634: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_MAKEINFO'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+if test "${ac_cv_prog_MAKEINFO+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
if test -n "$MAKEINFO"; then
ac_cv_prog_MAKEINFO="$MAKEINFO" # Let the user override the test.
else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_MAKEINFO="makeinfo"
- break
- fi
- done
- IFS="$ac_save_ifs"
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ ac_cv_prog_MAKEINFO="makeinfo"
+ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+done
+
fi
fi
-MAKEINFO="$ac_cv_prog_MAKEINFO"
+MAKEINFO=$ac_cv_prog_MAKEINFO
if test -n "$MAKEINFO"; then
- echo "$ac_t""$MAKEINFO" 1>&6
+ echo "$as_me:$LINENO: result: $MAKEINFO" >&5
+echo "${ECHO_T}$MAKEINFO" >&6
else
- echo "$ac_t""no" 1>&6
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
fi
if test "x$MAKEINFO" = "x"; then
@@ -661,12 +1410,25 @@ if test "x$MAKEINFO" = "x"; then
BUILD_INFO=
else
BUILD_INFO=info
- case x"`$MAKEINFO --version | grep 'GNU texinfo'`" in
- x*\ [1-3].* )
- MAKEINFO="@echo $MAKEINFO is too old, 4.0 or newer required; true"
+ case "$MAKEINFO" in
+ */missing\ makeinfo*)
BUILD_INFO=
- echo "configure: warning:
-*** Makeinfo is too old. Info documentation will not be built." 1>&2
+ { echo "$as_me:$LINENO: WARNING:
+*** Makeinfo is missing. Info documentation will not be built." >&5
+echo "$as_me: WARNING:
+*** Makeinfo is missing. Info documentation will not be built." >&2;}
+ ;;
+ *)
+ case x"`$MAKEINFO --version | grep 'GNU texinfo'`" in
+ x*\ [1-3].* )
+ MAKEINFO="@echo $MAKEINFO is too old, 4.0 or newer required; true"
+ BUILD_INFO=
+ { echo "$as_me:$LINENO: WARNING:
+*** Makeinfo is too old. Info documentation will not be built." >&5
+echo "$as_me: WARNING:
+*** Makeinfo is too old. Info documentation will not be built." >&2;}
+ ;;
+ esac
;;
esac
fi
@@ -675,31 +1437,37 @@ fi
# Extract the first word of "perl", so it can be a program name with args.
set dummy perl; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:680: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_PERL'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+if test "${ac_cv_prog_PERL+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
if test -n "$PERL"; then
ac_cv_prog_PERL="$PERL" # Let the user override the test.
else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_PERL="perl"
- break
- fi
- done
- IFS="$ac_save_ifs"
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ ac_cv_prog_PERL="perl"
+ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+done
+
fi
fi
-PERL="$ac_cv_prog_PERL"
+PERL=$ac_cv_prog_PERL
if test -n "$PERL"; then
- echo "$ac_t""$PERL" 1>&6
+ echo "$as_me:$LINENO: result: $PERL" >&5
+echo "${ECHO_T}$PERL" >&6
else
- echo "$ac_t""no" 1>&6
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
fi
if test x"$PERL" = x""; then
@@ -709,324 +1477,1431 @@ else
fi
-
# Make sure we can run config.sub.
-if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
-else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
-fi
-
-echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:720: checking host system type" >&5
+$ac_config_sub sun4 >/dev/null 2>&1 ||
+ { { echo "$as_me:$LINENO: error: cannot run $ac_config_sub" >&5
+echo "$as_me: error: cannot run $ac_config_sub" >&2;}
+ { (exit 1); exit 1; }; }
-host_alias=$host
-case "$host_alias" in
-NONE)
- case $nonopt in
- NONE)
- if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
- else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
- fi ;;
- *) host_alias=$nonopt ;;
- esac ;;
-esac
+echo "$as_me:$LINENO: checking build system type" >&5
+echo $ECHO_N "checking build system type... $ECHO_C" >&6
+if test "${ac_cv_build+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_cv_build_alias=$build_alias
+test -z "$ac_cv_build_alias" &&
+ ac_cv_build_alias=`$ac_config_guess`
+test -z "$ac_cv_build_alias" &&
+ { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
+echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
+ { (exit 1); exit 1; }; }
+ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
+ { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_build_alias failed" >&5
+echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed" >&2;}
+ { (exit 1); exit 1; }; }
-host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
-host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$host" 1>&6
+fi
+echo "$as_me:$LINENO: result: $ac_cv_build" >&5
+echo "${ECHO_T}$ac_cv_build" >&6
+build=$ac_cv_build
+build_cpu=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+build_vendor=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+build_os=`echo $ac_cv_build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
+echo "$as_me:$LINENO: checking host system type" >&5
+echo $ECHO_N "checking host system type... $ECHO_C" >&6
+if test "${ac_cv_host+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_cv_host_alias=$host_alias
+test -z "$ac_cv_host_alias" &&
+ ac_cv_host_alias=$ac_cv_build_alias
+ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
+ { { echo "$as_me:$LINENO: error: $ac_config_sub $ac_cv_host_alias failed" >&5
+echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
+ { (exit 1); exit 1; }; }
-echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:743: checking build system type" >&5
+fi
+echo "$as_me:$LINENO: result: $ac_cv_host" >&5
+echo "${ECHO_T}$ac_cv_host" >&6
+host=$ac_cv_host
+host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
+host_vendor=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
+host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-build_alias=$build
-case "$build_alias" in
-NONE)
- case $nonopt in
- NONE) build_alias=$host_alias ;;
- *) build_alias=$nonopt ;;
- esac ;;
-esac
-build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
-build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
-build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
-build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
-echo "$ac_t""$build" 1>&6
-if test $host != $build; then
- ac_tool_prefix=${host_alias}-
-else
- ac_tool_prefix=
-fi
-# Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
+if test -n "$ac_tool_prefix"; then
+ # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
set dummy ${ac_tool_prefix}ar; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:769: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+if test "${ac_cv_prog_AR+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
if test -n "$AR"; then
ac_cv_prog_AR="$AR" # Let the user override the test.
else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_AR="${ac_tool_prefix}ar"
- break
- fi
- done
- IFS="$ac_save_ifs"
- test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="ar"
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ ac_cv_prog_AR="${ac_tool_prefix}ar"
+ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+done
+
fi
fi
-AR="$ac_cv_prog_AR"
+AR=$ac_cv_prog_AR
if test -n "$AR"; then
- echo "$ac_t""$AR" 1>&6
+ echo "$as_me:$LINENO: result: $AR" >&5
+echo "${ECHO_T}$AR" >&6
else
- echo "$ac_t""no" 1>&6
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
fi
+fi
+if test -z "$ac_cv_prog_AR"; then
+ ac_ct_AR=$AR
+ # Extract the first word of "ar", so it can be a program name with args.
+set dummy ar; ac_word=$2
+echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test -n "$ac_ct_AR"; then
+ ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ ac_cv_prog_ac_ct_AR="ar"
+ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+done
+fi
+fi
+ac_ct_AR=$ac_cv_prog_ac_ct_AR
+if test -n "$ac_ct_AR"; then
+ echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
+echo "${ECHO_T}$ac_ct_AR" >&6
+else
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
+
+ AR=$ac_ct_AR
+else
+ AR="$ac_cv_prog_AR"
+fi
-# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
+if test -n "$ac_tool_prefix"; then
+ # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:801: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+if test "${ac_cv_prog_RANLIB+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
if test -n "$RANLIB"; then
ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
- break
- fi
- done
- IFS="$ac_save_ifs"
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
+ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+done
+
fi
fi
-RANLIB="$ac_cv_prog_RANLIB"
+RANLIB=$ac_cv_prog_RANLIB
if test -n "$RANLIB"; then
- echo "$ac_t""$RANLIB" 1>&6
+ echo "$as_me:$LINENO: result: $RANLIB" >&5
+echo "${ECHO_T}$RANLIB" >&6
else
- echo "$ac_t""no" 1>&6
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
fi
-
+fi
if test -z "$ac_cv_prog_RANLIB"; then
-if test -n "$ac_tool_prefix"; then
+ ac_ct_RANLIB=$RANLIB
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:833: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
- if test -n "$RANLIB"; then
- ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
+ if test -n "$ac_ct_RANLIB"; then
+ ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_RANLIB="ranlib"
- break
- fi
- done
- IFS="$ac_save_ifs"
- test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ ac_cv_prog_ac_ct_RANLIB="ranlib"
+ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+done
+
+ test -z "$ac_cv_prog_ac_ct_RANLIB" && ac_cv_prog_ac_ct_RANLIB=":"
fi
fi
-RANLIB="$ac_cv_prog_RANLIB"
-if test -n "$RANLIB"; then
- echo "$ac_t""$RANLIB" 1>&6
+ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
+if test -n "$ac_ct_RANLIB"; then
+ echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
+echo "${ECHO_T}$ac_ct_RANLIB" >&6
else
- echo "$ac_t""no" 1>&6
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
fi
+ RANLIB=$ac_ct_RANLIB
else
- RANLIB=":"
-fi
+ RANLIB="$ac_cv_prog_RANLIB"
fi
-# Extract the first word of "gcc", so it can be a program name with args.
+ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+if test -n "$ac_tool_prefix"; then
+ # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
+set dummy ${ac_tool_prefix}gcc; ac_word=$2
+echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+if test "${ac_cv_prog_CC+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test -n "$CC"; then
+ ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ ac_cv_prog_CC="${ac_tool_prefix}gcc"
+ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+done
+
+fi
+fi
+CC=$ac_cv_prog_CC
+if test -n "$CC"; then
+ echo "$as_me:$LINENO: result: $CC" >&5
+echo "${ECHO_T}$CC" >&6
+else
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
+
+fi
+if test -z "$ac_cv_prog_CC"; then
+ ac_ct_CC=$CC
+ # Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:870: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test -n "$ac_ct_CC"; then
+ ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ ac_cv_prog_ac_ct_CC="gcc"
+ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+done
+
+fi
+fi
+ac_ct_CC=$ac_cv_prog_ac_ct_CC
+if test -n "$ac_ct_CC"; then
+ echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
+echo "${ECHO_T}$ac_ct_CC" >&6
+else
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
+
+ CC=$ac_ct_CC
+else
+ CC="$ac_cv_prog_CC"
+fi
+
+if test -z "$CC"; then
+ if test -n "$ac_tool_prefix"; then
+ # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
+set dummy ${ac_tool_prefix}cc; ac_word=$2
+echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+if test "${ac_cv_prog_CC+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_CC="gcc"
- break
- fi
- done
- IFS="$ac_save_ifs"
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ ac_cv_prog_CC="${ac_tool_prefix}cc"
+ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+done
+
fi
fi
-CC="$ac_cv_prog_CC"
+CC=$ac_cv_prog_CC
if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
+ echo "$as_me:$LINENO: result: $CC" >&5
+echo "${ECHO_T}$CC" >&6
+else
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
+
+fi
+if test -z "$ac_cv_prog_CC"; then
+ ac_ct_CC=$CC
+ # Extract the first word of "cc", so it can be a program name with args.
+set dummy cc; ac_word=$2
+echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test -n "$ac_ct_CC"; then
+ ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ ac_cv_prog_ac_ct_CC="cc"
+ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+done
+
+fi
+fi
+ac_ct_CC=$ac_cv_prog_ac_ct_CC
+if test -n "$ac_ct_CC"; then
+ echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
+echo "${ECHO_T}$ac_ct_CC" >&6
+else
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
+
+ CC=$ac_ct_CC
else
- echo "$ac_t""no" 1>&6
+ CC="$ac_cv_prog_CC"
fi
+fi
if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:900: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+if test "${ac_cv_prog_CC+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
if test -n "$CC"; then
ac_cv_prog_CC="$CC" # Let the user override the test.
else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
ac_prog_rejected=no
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
- ac_prog_rejected=yes
- continue
- fi
- ac_cv_prog_CC="cc"
- break
- fi
- done
- IFS="$ac_save_ifs"
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
+ ac_prog_rejected=yes
+ continue
+ fi
+ ac_cv_prog_CC="cc"
+ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+done
+
if test $ac_prog_rejected = yes; then
# We found a bogon in the path, so make sure we never use it.
set dummy $ac_cv_prog_CC
shift
- if test $# -gt 0; then
+ if test $# != 0; then
# We chose a different compiler from the bogus one.
# However, it has the same basename, so the bogon will be chosen
# first if we set CC to just the basename; use the full file name.
shift
- set dummy "$ac_dir/$ac_word" "$@"
- shift
- ac_cv_prog_CC="$@"
+ ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
fi
fi
fi
fi
-CC="$ac_cv_prog_CC"
+CC=$ac_cv_prog_CC
if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
+ echo "$as_me:$LINENO: result: $CC" >&5
+echo "${ECHO_T}$CC" >&6
else
- echo "$ac_t""no" 1>&6
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
fi
- test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
fi
+if test -z "$CC"; then
+ if test -n "$ac_tool_prefix"; then
+ for ac_prog in cl
+ do
+ # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
+set dummy $ac_tool_prefix$ac_prog; ac_word=$2
+echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+if test "${ac_cv_prog_CC+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test -n "$CC"; then
+ ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
+ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+done
-echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:949: checking whether we are using GNU C" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+fi
+fi
+CC=$ac_cv_prog_CC
+if test -n "$CC"; then
+ echo "$as_me:$LINENO: result: $CC" >&5
+echo "${ECHO_T}$CC" >&6
else
- cat > conftest.c <<EOF
-#ifdef __GNUC__
- yes;
-#endif
-EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:958: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
- ac_cv_prog_gcc=yes
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
+
+ test -n "$CC" && break
+ done
+fi
+if test -z "$CC"; then
+ ac_ct_CC=$CC
+ for ac_prog in cl
+do
+ # Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test -n "$ac_ct_CC"; then
+ ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
+else
+as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ ac_cv_prog_ac_ct_CC="$ac_prog"
+ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+done
+
+fi
+fi
+ac_ct_CC=$ac_cv_prog_ac_ct_CC
+if test -n "$ac_ct_CC"; then
+ echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
+echo "${ECHO_T}$ac_ct_CC" >&6
+else
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
+
+ test -n "$ac_ct_CC" && break
+done
+
+ CC=$ac_ct_CC
+fi
+
+fi
+
+
+test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
+See \`config.log' for more details." >&5
+echo "$as_me: error: no acceptable C compiler found in \$PATH
+See \`config.log' for more details." >&2;}
+ { (exit 1); exit 1; }; }
+
+# Provide some information about the compiler.
+echo "$as_me:$LINENO:" \
+ "checking for C compiler version" >&5
+ac_compiler=`set X $ac_compile; echo $2`
+{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
+ (eval $ac_compiler --version </dev/null >&5) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }
+{ (eval echo "$as_me:$LINENO: \"$ac_compiler -v </dev/null >&5\"") >&5
+ (eval $ac_compiler -v </dev/null >&5) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }
+{ (eval echo "$as_me:$LINENO: \"$ac_compiler -V </dev/null >&5\"") >&5
+ (eval $ac_compiler -V </dev/null >&5) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }
+
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+
+int
+main ()
+{
+
+ ;
+ return 0;
+}
+_ACEOF
+# FIXME: Cleanup?
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; then
+ gcc_no_link=no
+else
+ gcc_no_link=yes
+fi
+
+if test x$gcc_no_link = xyes; then
+ # Setting cross_compile will disable run tests; it will
+ # also disable AC_CHECK_FILE but that's generally
+ # correct if we can't link.
+ cross_compiling=yes
+ EXEEXT=
+else
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+
+int
+main ()
+{
+
+ ;
+ return 0;
+}
+_ACEOF
+ac_clean_files_save=$ac_clean_files
+ac_clean_files="$ac_clean_files a.out a.exe b.out"
+# Try to create an executable without -o first, disregard a.out.
+# It will help us diagnose broken compilers, and finding out an intuition
+# of exeext.
+echo "$as_me:$LINENO: checking for C compiler default output" >&5
+echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
+ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
+if { (eval echo "$as_me:$LINENO: \"$ac_link_default\"") >&5
+ (eval $ac_link_default) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; then
+ # Find the output, starting from the most likely. This scheme is
+# not robust to junk in `.', hence go to wildcards (a.*) only as a last
+# resort.
+
+# Be careful to initialize this variable, since it used to be cached.
+# Otherwise an old cache value of `no' led to `EXEEXT = no' in a Makefile.
+ac_cv_exeext=
+# b.out is created by i960 compilers.
+for ac_file in a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out
+do
+ test -f "$ac_file" || continue
+ case $ac_file in
+ *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj )
+ ;;
+ conftest.$ac_ext )
+ # This is the source file.
+ ;;
+ [ab].out )
+ # We found the default executable, but exeext='' is most
+ # certainly right.
+ break;;
+ *.* )
+ ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
+ # FIXME: I believe we export ac_cv_exeext for Libtool,
+ # but it would be cool to find out if it's true. Does anybody
+ # maintain Libtool? --akim.
+ export ac_cv_exeext
+ break;;
+ * )
+ break;;
+ esac
+done
else
- ac_cv_prog_gcc=no
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
+See \`config.log' for more details." >&5
+echo "$as_me: error: C compiler cannot create executables
+See \`config.log' for more details." >&2;}
+ { (exit 77); exit 77; }; }
+fi
+
+ac_exeext=$ac_cv_exeext
+echo "$as_me:$LINENO: result: $ac_file" >&5
+echo "${ECHO_T}$ac_file" >&6
+
+# Check the compiler produces executables we can run. If not, either
+# the compiler is broken, or we cross compile.
+echo "$as_me:$LINENO: checking whether the C compiler works" >&5
+echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
+# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
+# If not cross compiling, check that we can run a simple program.
+if test "$cross_compiling" != yes; then
+ if { ac_try='./$ac_file'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ cross_compiling=no
+ else
+ if test "$cross_compiling" = maybe; then
+ cross_compiling=yes
+ else
+ { { echo "$as_me:$LINENO: error: cannot run C compiled programs.
+If you meant to cross compile, use \`--host'.
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot run C compiled programs.
+If you meant to cross compile, use \`--host'.
+See \`config.log' for more details." >&2;}
+ { (exit 1); exit 1; }; }
+ fi
+ fi
fi
+echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+
+rm -f a.out a.exe conftest$ac_cv_exeext b.out
+ac_clean_files=$ac_clean_files_save
+# Check the compiler produces executables we can run. If not, either
+# the compiler is broken, or we cross compile.
+echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
+echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
+echo "$as_me:$LINENO: result: $cross_compiling" >&5
+echo "${ECHO_T}$cross_compiling" >&6
+
+echo "$as_me:$LINENO: checking for suffix of executables" >&5
+echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; then
+ # If both `conftest.exe' and `conftest' are `present' (well, observable)
+# catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
+# work properly (i.e., refer to `conftest.exe'), while it won't with
+# `rm'.
+for ac_file in conftest.exe conftest conftest.*; do
+ test -f "$ac_file" || continue
+ case $ac_file in
+ *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.o | *.obj ) ;;
+ *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
+ export ac_cv_exeext
+ break;;
+ * ) break;;
+ esac
+done
+else
+ { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
+See \`config.log' for more details." >&2;}
+ { (exit 1); exit 1; }; }
fi
-echo "$ac_t""$ac_cv_prog_gcc" 1>&6
+rm -f conftest$ac_cv_exeext
+echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
+echo "${ECHO_T}$ac_cv_exeext" >&6
-if test $ac_cv_prog_gcc = yes; then
- GCC=yes
- ac_libiberty_warn_cflags='-W -Wall -Wtraditional -pedantic'
- ac_test_CFLAGS="${CFLAGS+set}"
- ac_save_CFLAGS="$CFLAGS"
- CFLAGS=
- echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:974: checking whether ${CC-cc} accepts -g" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- echo 'void f(){}' > conftest.c
-if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
- ac_cv_prog_cc_g=yes
+rm -f conftest.$ac_ext
+EXEEXT=$ac_cv_exeext
+ac_exeext=$EXEEXT
+fi
+echo "$as_me:$LINENO: checking for suffix of object files" >&5
+echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6
+if test "${ac_cv_objext+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
- ac_cv_prog_cc_g=no
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+
+int
+main ()
+{
+
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.o conftest.obj
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; then
+ for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
+ case $ac_file in
+ *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg ) ;;
+ *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
+ break;;
+ esac
+done
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
+See \`config.log' for more details." >&5
+echo "$as_me: error: cannot compute suffix of object files: cannot compile
+See \`config.log' for more details." >&2;}
+ { (exit 1); exit 1; }; }
fi
-rm -f conftest*
+rm -f conftest.$ac_cv_objext conftest.$ac_ext
fi
+echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
+echo "${ECHO_T}$ac_cv_objext" >&6
+OBJEXT=$ac_cv_objext
+ac_objext=$OBJEXT
+echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
+echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
+if test "${ac_cv_c_compiler_gnu+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+
+int
+main ()
+{
+#ifndef __GNUC__
+ choke me
+#endif
+
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ ac_compiler_gnu=yes
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_compiler_gnu=no
+fi
+rm -f conftest.$ac_objext conftest.$ac_ext
+ac_cv_c_compiler_gnu=$ac_compiler_gnu
+
+fi
+echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
+echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
+GCC=`test $ac_compiler_gnu = yes && echo yes`
+ac_test_CFLAGS=${CFLAGS+set}
+ac_save_CFLAGS=$CFLAGS
+CFLAGS="-g"
+echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
+echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
+if test "${ac_cv_prog_cc_g+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+
+int
+main ()
+{
+
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ ac_cv_prog_cc_g=yes
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
-echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
- if test "$ac_test_CFLAGS" = set; then
- CFLAGS="$ac_save_CFLAGS"
- elif test $ac_cv_prog_cc_g = yes; then
+ac_cv_prog_cc_g=no
+fi
+rm -f conftest.$ac_objext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
+echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
+if test "$ac_test_CFLAGS" = set; then
+ CFLAGS=$ac_save_CFLAGS
+elif test $ac_cv_prog_cc_g = yes; then
+ if test "$GCC" = yes; then
CFLAGS="-g -O2"
else
+ CFLAGS="-g"
+ fi
+else
+ if test "$GCC" = yes; then
CFLAGS="-O2"
+ else
+ CFLAGS=
+ fi
+fi
+echo "$as_me:$LINENO: checking for $CC option to accept ANSI C" >&5
+echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
+if test "${ac_cv_prog_cc_stdc+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_cv_prog_cc_stdc=no
+ac_save_CC=$CC
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <stdarg.h>
+#include <stdio.h>
+#include <sys/types.h>
+#include <sys/stat.h>
+/* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
+struct buf { int x; };
+FILE * (*rcsopen) (struct buf *, struct stat *, int);
+static char *e (p, i)
+ char **p;
+ int i;
+{
+ return p[i];
+}
+static char *f (char * (*g) (char **, int), char **p, ...)
+{
+ char *s;
+ va_list v;
+ va_start (v,p);
+ s = g (p, va_arg (v,int));
+ va_end (v);
+ return s;
+}
+int test (int i, double x);
+struct s1 {int (*f) (int a);};
+struct s2 {int (*f) (double a);};
+int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
+int argc;
+char **argv;
+int
+main ()
+{
+return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
+ ;
+ return 0;
+}
+_ACEOF
+# Don't try gcc -ansi; that turns off useful extensions and
+# breaks some systems' header files.
+# AIX -qlanglvl=ansi
+# Ultrix and OSF/1 -std1
+# HP-UX 10.20 and later -Ae
+# HP-UX older versions -Aa -D_HPUX_SOURCE
+# SVR4 -Xc -D__EXTENSIONS__
+for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
+do
+ CC="$ac_save_CC $ac_arg"
+ rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ ac_cv_prog_cc_stdc=$ac_arg
+break
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+fi
+rm -f conftest.$ac_objext
+done
+rm -f conftest.$ac_ext conftest.$ac_objext
+CC=$ac_save_CC
+
+fi
+
+case "x$ac_cv_prog_cc_stdc" in
+ x|xno)
+ echo "$as_me:$LINENO: result: none needed" >&5
+echo "${ECHO_T}none needed" >&6 ;;
+ *)
+ echo "$as_me:$LINENO: result: $ac_cv_prog_cc_stdc" >&5
+echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
+ CC="$CC $ac_cv_prog_cc_stdc" ;;
+esac
+
+# Some people use a C++ compiler to compile C. Since we use `exit',
+# in C++ we need to declare it. In case someone uses the same compiler
+# for both compiling C and C++ we need to have the C++ compiler decide
+# the declaration of exit, since it's the most demanding environment.
+cat >conftest.$ac_ext <<_ACEOF
+#ifndef __cplusplus
+ choke me
+#endif
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ for ac_declaration in \
+ ''\
+ '#include <stdlib.h>' \
+ 'extern "C" void std::exit (int) throw (); using std::exit;' \
+ 'extern "C" void std::exit (int); using std::exit;' \
+ 'extern "C" void exit (int) throw ();' \
+ 'extern "C" void exit (int);' \
+ 'void exit (int);'
+do
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <stdlib.h>
+$ac_declaration
+int
+main ()
+{
+exit (42);
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ :
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+continue
+fi
+rm -f conftest.$ac_objext conftest.$ac_ext
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+$ac_declaration
+int
+main ()
+{
+exit (42);
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ break
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+fi
+rm -f conftest.$ac_objext conftest.$ac_ext
+done
+rm -f conftest*
+if test -n "$ac_declaration"; then
+ echo '#ifdef __cplusplus' >>confdefs.h
+ echo $ac_declaration >>confdefs.h
+ echo '#endif' >>confdefs.h
+fi
+
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+fi
+rm -f conftest.$ac_objext conftest.$ac_ext
+ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
+ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
+echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
+# On Suns, sometimes $CPP names a directory.
+if test -n "$CPP" && test -d "$CPP"; then
+ CPP=
+fi
+if test -z "$CPP"; then
+ if test "${ac_cv_prog_CPP+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ # Double quotes because CPP needs to be expanded
+ for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
+ do
+ ac_preproc_ok=false
+for ac_c_preproc_warn_flag in '' yes
+do
+ # Use a header file that comes with gcc, so configuring glibc
+ # with a fresh cross-compiler works.
+ # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+ # <limits.h> exists even on freestanding compilers.
+ # On the NeXT, cc -E runs the code through the compiler's parser,
+ # not just through cpp. "Syntax error" is here to catch this case.
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#ifdef __STDC__
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
+ Syntax error
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } >/dev/null; then
+ if test -s conftest.err; then
+ ac_cpp_err=$ac_c_preproc_warn_flag
+ else
+ ac_cpp_err=
+ fi
+else
+ ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+ :
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ # Broken: fails on valid input.
+continue
+fi
+rm -f conftest.err conftest.$ac_ext
+
+ # OK, works on sane cases. Now check whether non-existent headers
+ # can be detected and how.
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <ac_nonexistent.h>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } >/dev/null; then
+ if test -s conftest.err; then
+ ac_cpp_err=$ac_c_preproc_warn_flag
+ else
+ ac_cpp_err=
+ fi
+else
+ ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+ # Broken: success on invalid input.
+continue
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ # Passes both tests.
+ac_preproc_ok=:
+break
+fi
+rm -f conftest.err conftest.$ac_ext
+
+done
+# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
+rm -f conftest.err conftest.$ac_ext
+if $ac_preproc_ok; then
+ break
+fi
+
+ done
+ ac_cv_prog_CPP=$CPP
+
+fi
+ CPP=$ac_cv_prog_CPP
+else
+ ac_cv_prog_CPP=$CPP
+fi
+echo "$as_me:$LINENO: result: $CPP" >&5
+echo "${ECHO_T}$CPP" >&6
+ac_preproc_ok=false
+for ac_c_preproc_warn_flag in '' yes
+do
+ # Use a header file that comes with gcc, so configuring glibc
+ # with a fresh cross-compiler works.
+ # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+ # <limits.h> exists even on freestanding compilers.
+ # On the NeXT, cc -E runs the code through the compiler's parser,
+ # not just through cpp. "Syntax error" is here to catch this case.
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#ifdef __STDC__
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
+ Syntax error
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } >/dev/null; then
+ if test -s conftest.err; then
+ ac_cpp_err=$ac_c_preproc_warn_flag
+ else
+ ac_cpp_err=
+ fi
+else
+ ac_cpp_err=yes
+fi
+if test -z "$ac_cpp_err"; then
+ :
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ # Broken: fails on valid input.
+continue
+fi
+rm -f conftest.err conftest.$ac_ext
+
+ # OK, works on sane cases. Now check whether non-existent headers
+ # can be detected and how.
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <ac_nonexistent.h>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } >/dev/null; then
+ if test -s conftest.err; then
+ ac_cpp_err=$ac_c_preproc_warn_flag
+ else
+ ac_cpp_err=
fi
else
- GCC=
- ac_libiberty_warn_cflags=
- test "${CFLAGS+set}" = set || CFLAGS="-g"
+ ac_cpp_err=yes
fi
+if test -z "$ac_cpp_err"; then
+ # Broken: success on invalid input.
+continue
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+ # Passes both tests.
+ac_preproc_ok=:
+break
+fi
+rm -f conftest.err conftest.$ac_ext
+
+done
+# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
+rm -f conftest.err conftest.$ac_ext
+if $ac_preproc_ok; then
+ :
+else
+ { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
+See \`config.log' for more details." >&5
+echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
+See \`config.log' for more details." >&2;}
+ { (exit 1); exit 1; }; }
+fi
+
+ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
+
+ac_c_preproc_warn_flag=yes
+
+if test x$GCC = xyes; then
+ ac_libiberty_warn_cflags='-W -Wall -Wtraditional -pedantic'
+fi
if test "x$CC" != xcc; then
- echo $ac_n "checking whether $CC and cc understand -c and -o together""... $ac_c" 1>&6
-echo "configure:1006: checking whether $CC and cc understand -c and -o together" >&5
+ echo "$as_me:$LINENO: checking whether $CC and cc understand -c and -o together" >&5
+echo $ECHO_N "checking whether $CC and cc understand -c and -o together... $ECHO_C" >&6
else
- echo $ac_n "checking whether cc understands -c and -o together""... $ac_c" 1>&6
-echo "configure:1009: checking whether cc understands -c and -o together" >&5
+ echo "$as_me:$LINENO: checking whether cc understands -c and -o together" >&5
+echo $ECHO_N "checking whether cc understands -c and -o together... $ECHO_C" >&6
fi
-set dummy $CC; ac_cc="`echo $2 |
- sed -e 's/[^a-zA-Z0-9_]/_/g' -e 's/^[0-9]/_/'`"
-if eval "test \"`echo '$''{'ac_cv_prog_cc_${ac_cc}_c_o'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+set dummy $CC; ac_cc=`echo $2 |
+ sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
+if eval "test \"\${ac_cv_prog_cc_${ac_cc}_c_o+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
- echo 'foo(){}' > conftest.c
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+
+int
+main ()
+{
+
+ ;
+ return 0;
+}
+_ACEOF
# Make sure it works both with $CC and with simple cc.
# We do the test twice because some compilers refuse to overwrite an
# existing .o file with -o, though they will create one.
-ac_try='${CC-cc} -c conftest.c -o conftest.o 1>&5'
-if { (eval echo configure:1021: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } &&
- test -f conftest.o && { (eval echo configure:1022: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; };
+ac_try='$CC -c conftest.$ac_ext -o conftest.$ac_objext >&5'
+if { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ test -f conftest.$ac_objext && { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); };
then
eval ac_cv_prog_cc_${ac_cc}_c_o=yes
if test "x$CC" != xcc; then
# Test first that cc exists at all.
- if { ac_try='cc -c conftest.c 1>&5'; { (eval echo configure:1027: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
- ac_try='cc -c conftest.c -o conftest.o 1>&5'
- if { (eval echo configure:1029: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } &&
- test -f conftest.o && { (eval echo configure:1030: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; };
+ if { ac_try='cc -c conftest.$ac_ext >&5'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ ac_try='cc -c conftest.$ac_ext -o conftest.$ac_objext >&5'
+ if { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ test -f conftest.$ac_objext && { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); };
then
# cc works too.
:
@@ -1043,12 +2918,15 @@ rm -f conftest*
fi
if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" = yes"; then
- echo "$ac_t""yes" 1>&6
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
else
- echo "$ac_t""no" 1>&6
- cat >> confdefs.h <<\EOF
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+
+cat >>confdefs.h <<\_ACEOF
#define NO_MINUS_C_MINUS_O 1
-EOF
+_ACEOF
fi
@@ -1061,147 +2939,362 @@ fi
-echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
-echo "configure:1066: checking for POSIXized ISC" >&5
-if test -d /etc/conf/kconfig.d &&
- grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
-then
- echo "$ac_t""yes" 1>&6
- ISC=yes # If later tests want to check for ISC.
- cat >> confdefs.h <<\EOF
-#define _POSIX_SOURCE 1
-EOF
- if test "$GCC" = yes; then
- CC="$CC -posix"
- else
- CC="$CC -Xp"
- fi
+echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
+echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
+if test "${ac_cv_c_const+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
- echo "$ac_t""no" 1>&6
- ISC=
-fi
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
-echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:1087: checking for working const" >&5
-if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 1092 "configure"
-#include "confdefs.h"
+int
+main ()
+{
+/* FIXME: Include the comments suggested by Paul. */
+#ifndef __cplusplus
+ /* Ultrix mips cc rejects this. */
+ typedef int charset[2];
+ const charset x;
+ /* SunOS 4.1.1 cc rejects this. */
+ char const *const *ccp;
+ char **p;
+ /* NEC SVR4.0.2 mips cc rejects this. */
+ struct point {int x, y;};
+ static struct point const zero = {0,0};
+ /* AIX XL C 1.02.0.0 rejects this.
+ It does not let you subtract one const X* pointer from another in
+ an arm of an if-expression whose if-part is not a constant
+ expression */
+ const char *g = "string";
+ ccp = &g + (g ? g-g : 0);
+ /* HPUX 7.0 cc rejects these. */
+ ++ccp;
+ p = (char**) ccp;
+ ccp = (char const *const *) p;
+ { /* SCO 3.2v4 cc rejects this. */
+ char *t;
+ char const *s = 0 ? (char *) 0 : (char const *) 0;
+
+ *t++ = 0;
+ }
+ { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
+ int x[] = {25, 17};
+ const int *foo = &x[0];
+ ++foo;
+ }
+ { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
+ typedef const int *iptr;
+ iptr p = 0;
+ ++p;
+ }
+ { /* AIX XL C 1.02.0.0 rejects this saying
+ "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
+ struct s { int j; const int *ap[3]; };
+ struct s *b; b->j = 5;
+ }
+ { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
+ const int foo = 10;
+ }
+#endif
-int main() {
-
-/* Ultrix mips cc rejects this. */
-typedef int charset[2]; const charset x;
-/* SunOS 4.1.1 cc rejects this. */
-char const *const *ccp;
-char **p;
-/* NEC SVR4.0.2 mips cc rejects this. */
-struct point {int x, y;};
-static struct point const zero = {0,0};
-/* AIX XL C 1.02.0.0 rejects this.
- It does not let you subtract one const X* pointer from another in an arm
- of an if-expression whose if-part is not a constant expression */
-const char *g = "string";
-ccp = &g + (g ? g-g : 0);
-/* HPUX 7.0 cc rejects these. */
-++ccp;
-p = (char**) ccp;
-ccp = (char const *const *) p;
-{ /* SCO 3.2v4 cc rejects this. */
- char *t;
- char const *s = 0 ? (char *) 0 : (char const *) 0;
-
- *t++ = 0;
-}
-{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
- int x[] = {25, 17};
- const int *foo = &x[0];
- ++foo;
-}
-{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
- typedef const int *iptr;
- iptr p = 0;
- ++p;
+ ;
+ return 0;
}
-{ /* AIX XL C 1.02.0.0 rejects this saying
- "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
- struct s { int j; const int *ap[3]; };
- struct s *b; b->j = 5;
-}
-{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
- const int foo = 10;
-}
-
-; return 0; }
-EOF
-if { (eval echo configure:1141: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
ac_cv_c_const=yes
else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- ac_cv_c_const=no
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_c_const=no
fi
-rm -f conftest*
+rm -f conftest.$ac_objext conftest.$ac_ext
fi
-
-echo "$ac_t""$ac_cv_c_const" 1>&6
+echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
+echo "${ECHO_T}$ac_cv_c_const" >&6
if test $ac_cv_c_const = no; then
- cat >> confdefs.h <<\EOF
-#define const
-EOF
+
+cat >>confdefs.h <<\_ACEOF
+#define const
+_ACEOF
fi
-echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:1162: checking for inline" >&5
-if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+echo "$as_me:$LINENO: checking for inline" >&5
+echo $ECHO_N "checking for inline... $ECHO_C" >&6
+if test "${ac_cv_c_inline+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
- cat > conftest.$ac_ext <<EOF
-#line 1169 "configure"
-#include "confdefs.h"
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#ifndef __cplusplus
+typedef int foo_t;
+static $ac_kw foo_t static_foo () {return 0; }
+$ac_kw foo_t foo () {return 0; }
+#endif
-int main() {
-} $ac_kw foo() {
-; return 0; }
-EOF
-if { (eval echo configure:1176: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
ac_cv_c_inline=$ac_kw; break
else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
fi
-rm -f conftest*
+rm -f conftest.$ac_objext conftest.$ac_ext
done
fi
-
-echo "$ac_t""$ac_cv_c_inline" 1>&6
-case "$ac_cv_c_inline" in
+echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
+echo "${ECHO_T}$ac_cv_c_inline" >&6
+case $ac_cv_c_inline in
inline | yes) ;;
- no) cat >> confdefs.h <<\EOF
-#define inline
-EOF
+ no)
+cat >>confdefs.h <<\_ACEOF
+#define inline
+_ACEOF
;;
- *) cat >> confdefs.h <<EOF
+ *) cat >>confdefs.h <<_ACEOF
#define inline $ac_cv_c_inline
-EOF
+_ACEOF
;;
esac
+echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
+echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6
+if test "${ac_cv_c_bigendian+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_cv_c_bigendian=unknown
+# See if sys/param.h defines the BYTE_ORDER macro.
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <sys/types.h>
+#include <sys/param.h>
+int
+main ()
+{
+
+#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
+ bogus endian macros
+#endif
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ # It does; now see whether it defined to BIG_ENDIAN or not.
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <sys/types.h>
+#include <sys/param.h>
+int
+main ()
+{
+
+#if BYTE_ORDER != BIG_ENDIAN
+ not big endian
+#endif
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ ac_cv_c_bigendian=yes
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_c_bigendian=no
+fi
+rm -f conftest.$ac_objext conftest.$ac_ext
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+fi
+rm -f conftest.$ac_objext conftest.$ac_ext
+if test $ac_cv_c_bigendian = unknown; then
+if test "$cross_compiling" = yes; then
+ echo $ac_n "cross-compiling... " 2>&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+main () {
+ /* Are we little or big endian? From Harbison&Steele. */
+ union
+ {
+ long l;
+ char c[sizeof (long)];
+ } u;
+ u.l = 1;
+ exit (u.c[sizeof (long) - 1] == 1);
+}
+_ACEOF
+rm -f conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ ac_cv_c_bigendian=no
+else
+ echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+( exit $ac_status )
+ac_cv_c_bigendian=yes
+fi
+rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+fi
+fi
+fi
+echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
+echo "${ECHO_T}$ac_cv_c_bigendian" >&6
+if test $ac_cv_c_bigendian = unknown; then
+echo "$as_me:$LINENO: checking to probe for byte ordering" >&5
+echo $ECHO_N "checking to probe for byte ordering... $ECHO_C" >&6
+
+cat >conftest.c <<EOF
+short ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
+short ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
+void _ascii() { char* s = (char*) ascii_mm; s = (char*) ascii_ii; }
+short ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
+short ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
+void _ebcdic() { char* s = (char*) ebcdic_mm; s = (char*) ebcdic_ii; }
+int main() { _ascii (); _ebcdic (); return 0; }
+EOF
+ if test -f conftest.c ; then
+ if ${CC-cc} ${CFLAGS} conftest.c -o conftest.o && test -f conftest.o ; then
+ if test `grep -l BIGenDianSyS conftest.o` ; then
+ echo $ac_n ' big endian probe OK, ' 1>&6
+ ac_cv_c_bigendian=yes
+ fi
+ if test `grep -l LiTTleEnDian conftest.o` ; then
+ echo $ac_n ' little endian probe OK, ' 1>&6
+ if test $ac_cv_c_bigendian = yes ; then
+ ac_cv_c_bigendian=unknown;
+ else
+ ac_cv_c_bigendian=no
+ fi
+ fi
+ echo $ac_n 'guessing bigendian ... ' >&6
+ fi
+ fi
+echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
+echo "${ECHO_T}$ac_cv_c_bigendian" >&6
+fi
+if test $ac_cv_c_bigendian = yes; then
+
+cat >>confdefs.h <<\_ACEOF
+#define WORDS_BIGENDIAN 1
+_ACEOF
+cat >>confdefs.h <<\_ACEOF
+#define HOST_WORDS_BIG_ENDIAN 1
+_ACEOF
+
+ BYTEORDER=4321
+else
+ BYTEORDER=1234
+fi
+
+cat >>confdefs.h <<_ACEOF
+#define BYTEORDER $BYTEORDER
+_ACEOF
+
+if test $ac_cv_c_bigendian = unknown; then
+ { { echo "$as_me:$LINENO: error: unknown endianess - sorry" >&5
+echo "$as_me: error: unknown endianess - sorry" >&2;}
+ { (exit please pre-set ac_cv_c_bigendian); exit please pre-set ac_cv_c_bigendian; }; }
+fi
+
+ ac_config_headers="$ac_config_headers config.h:config.in"
+
+
# Find a good install program. We prefer a C program (faster),
# so one script is as good as another. But avoid the broken or
@@ -1210,60 +3303,73 @@ esac
# SunOS /usr/etc/install
# IRIX /sbin/install
# AIX /bin/install
+# AmigaOS /C/install, which installs bootblocks on floppy discs
# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
# AFS /usr/afsws/bin/install, which mishandles nonexistent args
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
-echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:1219: checking for a BSD compatible install" >&5
+echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
+echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6
if test -z "$INSTALL"; then
-if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS=":"
- for ac_dir in $PATH; do
- # Account for people who put trailing slashes in PATH elements.
- case "$ac_dir/" in
- /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
- *)
- # OSF1 and SCO ODT 3.0 have their own names for install.
- # Don't use installbsd from OSF since it installs stuff as root
- # by default.
- for ac_prog in ginstall scoinst install; do
- if test -f $ac_dir/$ac_prog; then
- if test $ac_prog = install &&
- grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
- # AIX install. It has an incompatible calling convention.
- :
- else
- ac_cv_path_install="$ac_dir/$ac_prog -c"
- break 2
- fi
- fi
+if test "${ac_cv_path_install+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ # Account for people who put trailing slashes in PATH elements.
+case $as_dir/ in
+ ./ | .// | /cC/* | \
+ /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
+ /usr/ucb/* ) ;;
+ *)
+ # OSF1 and SCO ODT 3.0 have their own names for install.
+ # Don't use installbsd from OSF since it installs stuff as root
+ # by default.
+ for ac_prog in ginstall scoinst install; do
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if $as_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then
+ if test $ac_prog = install &&
+ grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
+ # AIX install. It has an incompatible calling convention.
+ :
+ elif test $ac_prog = install &&
+ grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
+ # program-specific install script used by HP pwplus--don't use.
+ :
+ else
+ ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
+ break 3
+ fi
+ fi
done
- ;;
- esac
- done
- IFS="$ac_save_IFS"
+ done
+ ;;
+esac
+done
+
fi
if test "${ac_cv_path_install+set}" = set; then
- INSTALL="$ac_cv_path_install"
+ INSTALL=$ac_cv_path_install
else
# As a last resort, use the slow shell script. We don't cache a
# path for INSTALL within a source directory, because that will
# break other packages using the cache if that directory is
# removed, or if the path is relative.
- INSTALL="$ac_install_sh"
+ INSTALL=$ac_install_sh
fi
fi
-echo "$ac_t""$INSTALL" 1>&6
+echo "$as_me:$LINENO: result: $INSTALL" >&5
+echo "${ECHO_T}$INSTALL" >&6
# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
# It thinks the first close brace ends the variable substitution.
test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
-test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
+test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
@@ -1275,278 +3381,331 @@ host_makefile_frag=${frag}
# It's OK to check for header files. Although the compiler may not be
# able to link anything, it had better be able to at least compile
# something.
-echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:1280: checking how to run the C preprocessor" >&5
-# On Suns, sometimes $CPP names a directory.
-if test -n "$CPP" && test -d "$CPP"; then
- CPP=
-fi
-if test -z "$CPP"; then
-if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- # This must be in double quotes, not single quotes, because CPP may get
- # substituted into the Makefile and "${CC-cc}" will confuse make.
- CPP="${CC-cc} -E"
- # On the NeXT, cc -E runs the code through the compiler's parser,
- # not just through cpp.
- cat > conftest.$ac_ext <<EOF
-#line 1295 "configure"
-#include "confdefs.h"
-#include <assert.h>
-Syntax Error
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1301: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- :
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- CPP="${CC-cc} -E -traditional-cpp"
- cat > conftest.$ac_ext <<EOF
-#line 1312 "configure"
-#include "confdefs.h"
-#include <assert.h>
-Syntax Error
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1318: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- :
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- CPP="${CC-cc} -nologo -E"
- cat > conftest.$ac_ext <<EOF
-#line 1329 "configure"
-#include "confdefs.h"
-#include <assert.h>
-Syntax Error
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1335: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- :
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+for ac_header in sys/file.h sys/param.h limits.h stdlib.h malloc.h string.h unistd.h strings.h sys/time.h time.h sys/resource.h sys/stat.h sys/mman.h fcntl.h alloca.h sys/pstat.h sys/sysmp.h sys/sysinfo.h machine/hal_sysinfo.h sys/table.h sys/sysctl.h sys/systemcfg.h
+do
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <$ac_header>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } >/dev/null; then
+ if test -s conftest.err; then
+ ac_cpp_err=$ac_c_preproc_warn_flag
+ else
+ ac_cpp_err=
+ fi
else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- CPP=/lib/cpp
+ ac_cpp_err=yes
fi
-rm -f conftest*
-fi
-rm -f conftest*
-fi
-rm -f conftest*
- ac_cv_prog_CPP="$CPP"
-fi
- CPP="$ac_cv_prog_CPP"
+if test -z "$ac_cpp_err"; then
+ eval "$as_ac_Header=yes"
else
- ac_cv_prog_CPP="$CPP"
-fi
-echo "$ac_t""$CPP" 1>&6
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
-for ac_hdr in sys/file.h sys/param.h limits.h stdlib.h string.h unistd.h strings.h sys/time.h time.h sys/resource.h sys/stat.h sys/mman.h fcntl.h alloca.h
-do
-ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:1363: checking for $ac_hdr" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 1368 "configure"
-#include "confdefs.h"
-#include <$ac_hdr>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1373: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- rm -rf conftest*
- eval "ac_cv_header_$ac_safe=yes"
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_header_$ac_safe=no"
+ eval "$as_ac_Header=no"
fi
-rm -f conftest*
+rm -f conftest.err conftest.$ac_ext
fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
- cat >> confdefs.h <<EOF
-#define $ac_tr_hdr 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
+
fi
done
-echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6
-echo "configure:1400: checking for sys/wait.h that is POSIX.1 compatible" >&5
-if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 1405 "configure"
-#include "confdefs.h"
+echo "$as_me:$LINENO: checking for sys/wait.h that is POSIX.1 compatible" >&5
+echo $ECHO_N "checking for sys/wait.h that is POSIX.1 compatible... $ECHO_C" >&6
+if test "${ac_cv_header_sys_wait_h+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
#include <sys/types.h>
#include <sys/wait.h>
#ifndef WEXITSTATUS
-#define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
+# define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
#endif
#ifndef WIFEXITED
-#define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
+# define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
#endif
-int main() {
-int s;
-wait (&s);
-s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
-; return 0; }
-EOF
-if { (eval echo configure:1421: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
+
+int
+main ()
+{
+ int s;
+ wait (&s);
+ s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
ac_cv_header_sys_wait_h=yes
else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- ac_cv_header_sys_wait_h=no
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_header_sys_wait_h=no
fi
-rm -f conftest*
+rm -f conftest.$ac_objext conftest.$ac_ext
fi
-
-echo "$ac_t""$ac_cv_header_sys_wait_h" 1>&6
+echo "$as_me:$LINENO: result: $ac_cv_header_sys_wait_h" >&5
+echo "${ECHO_T}$ac_cv_header_sys_wait_h" >&6
if test $ac_cv_header_sys_wait_h = yes; then
- cat >> confdefs.h <<\EOF
+
+cat >>confdefs.h <<\_ACEOF
#define HAVE_SYS_WAIT_H 1
-EOF
+_ACEOF
fi
-echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
-echo "configure:1442: checking whether time.h and sys/time.h may both be included" >&5
-if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+echo "$as_me:$LINENO: checking whether time.h and sys/time.h may both be included" >&5
+echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
+if test "${ac_cv_header_time+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat > conftest.$ac_ext <<EOF
-#line 1447 "configure"
-#include "confdefs.h"
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
#include <sys/types.h>
#include <sys/time.h>
#include <time.h>
-int main() {
-struct tm *tp;
-; return 0; }
-EOF
-if { (eval echo configure:1456: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
+
+int
+main ()
+{
+if ((struct tm *) 0)
+return 0;
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
ac_cv_header_time=yes
else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- ac_cv_header_time=no
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_header_time=no
fi
-rm -f conftest*
+rm -f conftest.$ac_objext conftest.$ac_ext
fi
-
-echo "$ac_t""$ac_cv_header_time" 1>&6
+echo "$as_me:$LINENO: result: $ac_cv_header_time" >&5
+echo "${ECHO_T}$ac_cv_header_time" >&6
if test $ac_cv_header_time = yes; then
- cat >> confdefs.h <<\EOF
+
+cat >>confdefs.h <<\_ACEOF
#define TIME_WITH_SYS_TIME 1
-EOF
+_ACEOF
fi
-echo $ac_n "checking whether errno must be declared""... $ac_c" 1>&6
-echo "configure:1478: checking whether errno must be declared" >&5
-if eval "test \"`echo '$''{'libiberty_cv_declare_errno'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+echo "$as_me:$LINENO: checking whether errno must be declared" >&5
+echo $ECHO_N "checking whether errno must be declared... $ECHO_C" >&6
+if test "${libiberty_cv_declare_errno+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat > conftest.$ac_ext <<EOF
-#line 1483 "configure"
-#include "confdefs.h"
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
#include <errno.h>
-int main() {
+int
+main ()
+{
int x = errno;
-; return 0; }
-EOF
-if { (eval echo configure:1490: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
libiberty_cv_declare_errno=no
else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- libiberty_cv_declare_errno=yes
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+libiberty_cv_declare_errno=yes
fi
-rm -f conftest*
+rm -f conftest.$ac_objext conftest.$ac_ext
fi
-
-echo "$ac_t""$libiberty_cv_declare_errno" 1>&6
+echo "$as_me:$LINENO: result: $libiberty_cv_declare_errno" >&5
+echo "${ECHO_T}$libiberty_cv_declare_errno" >&6
if test $libiberty_cv_declare_errno = yes
-then cat >> confdefs.h <<\EOF
+then
+cat >>confdefs.h <<\_ACEOF
#define NEED_DECLARATION_ERRNO 1
-EOF
+_ACEOF
fi
-echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:1512: checking for ANSI C header files" >&5
-if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+echo "$as_me:$LINENO: checking for egrep" >&5
+echo $ECHO_N "checking for egrep... $ECHO_C" >&6
+if test "${ac_cv_prog_egrep+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat > conftest.$ac_ext <<EOF
-#line 1517 "configure"
-#include "confdefs.h"
+ if echo a | (grep -E '(a|b)') >/dev/null 2>&1
+ then ac_cv_prog_egrep='grep -E'
+ else ac_cv_prog_egrep='egrep'
+ fi
+fi
+echo "$as_me:$LINENO: result: $ac_cv_prog_egrep" >&5
+echo "${ECHO_T}$ac_cv_prog_egrep" >&6
+ EGREP=$ac_cv_prog_egrep
+
+
+echo "$as_me:$LINENO: checking for ANSI C header files" >&5
+echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
+if test "${ac_cv_header_stdc+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
#include <stdlib.h>
#include <stdarg.h>
#include <string.h>
#include <float.h>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:1525: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- rm -rf conftest*
+
+int
+main ()
+{
+
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
ac_cv_header_stdc=yes
else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- ac_cv_header_stdc=no
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_header_stdc=no
fi
-rm -f conftest*
+rm -f conftest.$ac_objext conftest.$ac_ext
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
-cat > conftest.$ac_ext <<EOF
-#line 1542 "configure"
-#include "confdefs.h"
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
#include <string.h>
-EOF
+
+_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- egrep "memchr" >/dev/null 2>&1; then
+ $EGREP "memchr" >/dev/null 2>&1; then
:
else
- rm -rf conftest*
ac_cv_header_stdc=no
fi
rm -f conftest*
@@ -1555,16 +3714,20 @@ fi
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
-cat > conftest.$ac_ext <<EOF
-#line 1560 "configure"
-#include "confdefs.h"
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
#include <stdlib.h>
-EOF
+
+_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- egrep "free" >/dev/null 2>&1; then
+ $EGREP "free" >/dev/null 2>&1; then
:
else
- rm -rf conftest*
ac_cv_header_stdc=no
fi
rm -f conftest*
@@ -1573,116 +3736,259 @@ fi
if test $ac_cv_header_stdc = yes; then
# /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
-if test "$cross_compiling" = yes; then
+ if test "$cross_compiling" = yes; then
:
else
- cat > conftest.$ac_ext <<EOF
-#line 1581 "configure"
-#include "confdefs.h"
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
#include <ctype.h>
-#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
-#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
-#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
-int main () { int i; for (i = 0; i < 256; i++)
-if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
-exit (0); }
+#if ((' ' & 0x0FF) == 0x020)
+# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
+# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
+#else
+# define ISLOWER(c) \
+ (('a' <= (c) && (c) <= 'i') \
+ || ('j' <= (c) && (c) <= 'r') \
+ || ('s' <= (c) && (c) <= 'z'))
+# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
+#endif
-EOF
-if { (eval echo configure:1592: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-then
+#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
+int
+main ()
+{
+ int i;
+ for (i = 0; i < 256; i++)
+ if (XOR (islower (i), ISLOWER (i))
+ || toupper (i) != TOUPPER (i))
+ exit(2);
+ exit (0);
+}
+_ACEOF
+rm -f conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
:
else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -fr conftest*
- ac_cv_header_stdc=no
+ echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+( exit $ac_status )
+ac_cv_header_stdc=no
fi
-rm -fr conftest*
+rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
-
fi
fi
-
-echo "$ac_t""$ac_cv_header_stdc" 1>&6
+echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
+echo "${ECHO_T}$ac_cv_header_stdc" >&6
if test $ac_cv_header_stdc = yes; then
- cat >> confdefs.h <<\EOF
+
+cat >>confdefs.h <<\_ACEOF
#define STDC_HEADERS 1
-EOF
+_ACEOF
fi
-echo $ac_n "checking for uintptr_t""... $ac_c" 1>&6
-echo "configure:1616: checking for uintptr_t" >&5
-if eval "test \"`echo '$''{'ac_cv_type_uintptr_t'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 1621 "configure"
-#include "confdefs.h"
-#include <sys/types.h>
-#if STDC_HEADERS
-#include <stdlib.h>
-#include <stddef.h>
-#endif
-EOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- egrep "(^|[^a-zA-Z_0-9])uintptr_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
- rm -rf conftest*
- ac_cv_type_uintptr_t=yes
+# On IRIX 5.3, sys/types and inttypes.h are conflicting.
+
+
+
+
+
+
+
+
+
+for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
+ inttypes.h stdint.h unistd.h
+do
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <$ac_header>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } >/dev/null; then
+ if test -s conftest.err; then
+ ac_cpp_err=$ac_c_preproc_warn_flag
+ else
+ ac_cpp_err=
+ fi
else
- rm -rf conftest*
- ac_cv_type_uintptr_t=no
+ ac_cpp_err=yes
fi
-rm -f conftest*
+if test -z "$ac_cpp_err"; then
+ eval "$as_ac_Header=yes"
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+ eval "$as_ac_Header=no"
fi
-echo "$ac_t""$ac_cv_type_uintptr_t" 1>&6
-if test $ac_cv_type_uintptr_t = no; then
- cat >> confdefs.h <<\EOF
-#define uintptr_t unsigned long
-EOF
+rm -f conftest.err conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
fi
+done
-if test $ac_cv_type_uintptr_t = yes
-then
- cat >> confdefs.h <<\EOF
-#define HAVE_UINTPTR_T 1
-EOF
+echo "$as_me:$LINENO: checking for uintptr_t" >&5
+echo $ECHO_N "checking for uintptr_t... $ECHO_C" >&6
+if test "${ac_cv_type_uintptr_t+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+$ac_includes_default
+int
+main ()
+{
+if ((uintptr_t *) 0)
+ return 0;
+if (sizeof (uintptr_t))
+ return 0;
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ ac_cv_type_uintptr_t=yes
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+ac_cv_type_uintptr_t=no
fi
-
-echo $ac_n "checking for pid_t""... $ac_c" 1>&6
-echo "configure:1658: checking for pid_t" >&5
-if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+rm -f conftest.$ac_objext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: $ac_cv_type_uintptr_t" >&5
+echo "${ECHO_T}$ac_cv_type_uintptr_t" >&6
+if test $ac_cv_type_uintptr_t = yes; then
+ :
else
- cat > conftest.$ac_ext <<EOF
-#line 1663 "configure"
-#include "confdefs.h"
-#include <sys/types.h>
-#if STDC_HEADERS
-#include <stdlib.h>
-#include <stddef.h>
-#endif
-EOF
-if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- egrep "(^|[^a-zA-Z_0-9])pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
- rm -rf conftest*
+
+cat >>confdefs.h <<_ACEOF
+#define uintptr_t unsigned long
+_ACEOF
+
+fi
+
+# Given the above check, we always have uintptr_t or a fallback
+# definition. So define HAVE_UINTPTR_T in case any imported code
+# relies on it.
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_UINTPTR_T 1
+_ACEOF
+
+
+echo "$as_me:$LINENO: checking for pid_t" >&5
+echo $ECHO_N "checking for pid_t... $ECHO_C" >&6
+if test "${ac_cv_type_pid_t+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+$ac_includes_default
+int
+main ()
+{
+if ((pid_t *) 0)
+ return 0;
+if (sizeof (pid_t))
+ return 0;
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
ac_cv_type_pid_t=yes
else
- rm -rf conftest*
- ac_cv_type_pid_t=no
-fi
-rm -f conftest*
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+ac_cv_type_pid_t=no
+fi
+rm -f conftest.$ac_objext conftest.$ac_ext
fi
-echo "$ac_t""$ac_cv_type_pid_t" 1>&6
-if test $ac_cv_type_pid_t = no; then
- cat >> confdefs.h <<\EOF
+echo "$as_me:$LINENO: result: $ac_cv_type_pid_t" >&5
+echo "${ECHO_T}$ac_cv_type_pid_t" >&6
+if test $ac_cv_type_pid_t = yes; then
+ :
+else
+
+cat >>confdefs.h <<_ACEOF
#define pid_t int
-EOF
+_ACEOF
fi
@@ -1708,6 +4014,7 @@ funcs="$funcs memchr"
funcs="$funcs memcmp"
funcs="$funcs memcpy"
funcs="$funcs memmove"
+funcs="$funcs mempcpy"
funcs="$funcs memset"
funcs="$funcs mkstemps"
funcs="$funcs putenv"
@@ -1715,7 +4022,10 @@ funcs="$funcs random"
funcs="$funcs rename"
funcs="$funcs rindex"
funcs="$funcs setenv"
+funcs="$funcs snprintf"
funcs="$funcs sigsetmask"
+funcs="$funcs stpcpy"
+funcs="$funcs stpncpy"
funcs="$funcs strcasecmp"
funcs="$funcs strchr"
funcs="$funcs strdup"
@@ -1729,6 +4039,7 @@ funcs="$funcs tmpnam"
funcs="$funcs vasprintf"
funcs="$funcs vfprintf"
funcs="$funcs vprintf"
+funcs="$funcs vsnprintf"
funcs="$funcs vsprintf"
funcs="$funcs waitpid"
@@ -1737,406 +4048,187 @@ funcs="$funcs waitpid"
vars="sys_errlist sys_nerr sys_siglist"
checkfuncs="getrusage on_exit psignal strerror strsignal sysconf times sbrk gettimeofday"
+checkfuncs="$checkfuncs realpath canonicalize_file_name pstat_getstatic pstat_getdynamic sysmp"
+checkfuncs="$checkfuncs getsysinfo table sysctl"
# These are neither executed nor required, but they help keep
# autoheader happy without adding a bunch of text to acconfig.h.
if test "x" = "y"; then
- for ac_func in asprintf atexit basename bcmp bcopy bsearch bzero calloc clock
-do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1748: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 1753 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func(); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func();
-int main() {
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-; return 0; }
-EOF
-if { (eval echo configure:1776: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
- cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
-fi
-done
- for ac_func in getcwd getpagesize index insque mkstemps memchr memcmp memcpy
-do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1803: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 1808 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func(); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func();
-int main() {
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-; return 0; }
-EOF
-if { (eval echo configure:1831: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
- cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
-fi
-done
- for ac_func in memmove memset putenv random rename rindex sigsetmask
-do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1858: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 1863 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func(); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func();
-int main() {
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-; return 0; }
-EOF
-if { (eval echo configure:1886: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
- cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
-fi
-done
- for ac_func in strcasecmp setenv strchr strdup strncasecmp strrchr strstr
-do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1913: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 1918 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func(); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func();
-int main() {
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-; return 0; }
-EOF
-if { (eval echo configure:1941: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
- cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
-fi
-done
- for ac_func in strtod strtol strtoul tmpnam vasprintf vfprintf vprintf
-do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:1968: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 1973 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func(); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func();
-int main() {
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-; return 0; }
-EOF
-if { (eval echo configure:1996: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
- cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
-fi
-done
- for ac_func in vsprintf waitpid getrusage on_exit psignal strerror strsignal
-do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2023: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2028 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func(); below. */
-#include <assert.h>
-/* Override any gcc2 internal prototype to avoid an error. */
-/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func();
-int main() {
-/* The GNU C library defines this for functions which it implements
- to always fail with ENOSYS. Some functions are actually named
- something starting with __ and the normal name is an alias. */
-#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
-choke me
-#else
-$ac_func();
-#endif
-; return 0; }
-EOF
-if { (eval echo configure:2051: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
- cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
-fi
-done
- for ac_func in sysconf times sbrk gettimeofday ffs
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+for ac_func in asprintf atexit basename bcmp bcopy bsearch bzero calloc clock \
+ getcwd getpagesize index insque mkstemps memchr memcmp memcpy \
+ memmove mempcpy memset putenv random rename rindex sigsetmask \
+ strcasecmp setenv stpcpy stpncpy strchr strdup strncasecmp strrchr strstr \
+ strtod strtol strtoul tmpnam vasprintf vfprintf vprintf \
+ vsprintf waitpid getrusage on_exit psignal strerror strsignal \
+ sysconf times sbrk gettimeofday ffs snprintf vsnprintf \
+ pstat_getstatic pstat_getdynamic sysmp getsysinfo table sysctl \
+ realpath canonicalize_file_name
do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2078: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2083 "configure"
-#include "confdefs.h"
+as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
+echo "$as_me:$LINENO: checking for $ac_func" >&5
+echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
+if eval "test \"\${$as_ac_var+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test x$gcc_no_link = xyes; then
+ { { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
+echo "$as_me: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&2;}
+ { (exit 1); exit 1; }; }
+fi
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func(); below. */
-#include <assert.h>
+ which can conflict with char $ac_func (); below.
+ Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+ <limits.h> exists even on freestanding compilers. Under hpux,
+ including <limits.h> includes <sys/time.h> and causes problems
+ checking for functions defined therein. */
+#if defined (__STDC__) && !defined (_HPUX_SOURCE)
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func();
-
-int main() {
-
+ builtin and then its argument prototype would still apply. */
+char $ac_func ();
/* The GNU C library defines this for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
-$ac_func();
+char (*f) () = $ac_func;
+#endif
+#ifdef __cplusplus
+}
#endif
-; return 0; }
-EOF
-if { (eval echo configure:2106: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
+int
+main ()
+{
+return f != $ac_func;
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ eval "$as_ac_var=yes"
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+eval "$as_ac_var=no"
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
+if test `eval echo '${'$as_ac_var'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
+_ACEOF
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
- cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
fi
done
- cat >> confdefs.h <<\EOF
+
+cat >>confdefs.h <<\_ACEOF
#define HAVE_SYS_ERRLIST 1
-EOF
+_ACEOF
- cat >> confdefs.h <<\EOF
+
+cat >>confdefs.h <<\_ACEOF
#define HAVE_SYS_NERR 1
-EOF
+_ACEOF
- cat >> confdefs.h <<\EOF
+
+cat >>confdefs.h <<\_ACEOF
#define HAVE_SYS_SIGLIST 1
-EOF
+_ACEOF
fi
@@ -2158,7 +4250,12 @@ if test -n "${with_target_subdir}"; then
# newlib provide and which ones we will be expected to provide.
if test "x${with_newlib}" = "xyes"; then
- LIBOBJS="asprintf.o basename.o insque.o random.o strdup.o vasprintf.o"
+ LIBOBJS="$LIBOBJS asprintf.$ac_objext"
+ LIBOBJS="$LIBOBJS basename.$ac_objext"
+ LIBOBJS="$LIBOBJS insque.$ac_objext"
+ LIBOBJS="$LIBOBJS random.$ac_objext"
+ LIBOBJS="$LIBOBJS strdup.$ac_objext"
+ LIBOBJS="$LIBOBJS vasprintf.$ac_objext"
for f in $funcs; do
case "$f" in
@@ -2166,9 +4263,9 @@ if test -n "${with_target_subdir}"; then
;;
*)
n=HAVE_`echo $f | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
- cat >> confdefs.h <<EOF
+ cat >>confdefs.h <<_ACEOF
#define $n 1
-EOF
+_ACEOF
;;
esac
@@ -2194,17 +4291,16 @@ if test "${enable_install_libiberty+set}" = set; then
enable_install_libiberty=$enableval
else
enable_install_libiberty=no
-fi
-
+fi;
# Option parsed, now set things appropriately.
case x"$enable_install_libiberty" in
xyes|x)
target_header_dir=libiberty
;;
- xno)
+ xno)
target_header_dir=
;;
- *)
+ *)
# This could be sanity-checked in various ways...
target_header_dir="${enable_install_libiberty}"
;;
@@ -2241,8 +4337,16 @@ if test -z "${setobjs}"; then
# Handle VxWorks configuration specially, since on VxWorks the
# libraries are actually on the target board, not in the file
# system.
- LIBOBJS="basename.o getpagesize.o insque.o random.o strcasecmp.o"
- LIBOBJS="$LIBOBJS strncasecmp.o strdup.o vfork.o waitpid.o vasprintf.o"
+ LIBOBJS="$LIBOBJS basename.$ac_objext"
+ LIBOBJS="$LIBOBJS getpagesize.$ac_objext"
+ LIBOBJS="$LIBOBJS insque.$ac_objext"
+ LIBOBJS="$LIBOBJS random.$ac_objext"
+ LIBOBJS="$LIBOBJS strcasecmp.$ac_objext"
+ LIBOBJS="$LIBOBJS strncasecmp.$ac_objext"
+ LIBOBJS="$LIBOBJS strdup.$ac_objext"
+ LIBOBJS="$LIBOBJS vfork.$ac_objext"
+ LIBOBJS="$LIBOBJS waitpid.$ac_objext"
+ LIBOBJS="$LIBOBJS vasprintf.$ac_objext"
for f in $funcs; do
case "$f" in
basename | getpagesize | insque | random | strcasecmp)
@@ -2251,9 +4355,9 @@ if test -z "${setobjs}"; then
;;
*)
n=HAVE_`echo $f | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
- cat >> confdefs.h <<EOF
+ cat >>confdefs.h <<_ACEOF
#define $n 1
-EOF
+_ACEOF
;;
esac
@@ -2291,11 +4395,11 @@ if test -z "${setobjs}"; then
# missing.
# DJ - only if we're *building* cygwin, not just building *with* cygwin
-
+
if test -n "${with_target_subdir}"
then
funcs="`echo $funcs | sed -e 's/random//'`"
- LIBOBJS="$LIBOBJS random.o"
+ LIBOBJS="$LIBOBJS random.$ac_objext"
vars="`echo $vars | sed -e 's/sys_siglist//'`"
checkfuncs="`echo $checkfuncs | sed -e 's/strsignal//' -e 's/psignal//'`"
fi
@@ -2309,19 +4413,19 @@ if test -z "${setobjs}"; then
;;
*-*-uwin*)
- # Under some versions of uwin, vfork is notoriously buggy and the test
+ # Under some versions of uwin, vfork is notoriously buggy and the test
# can hang configure; on other versions, vfork exists just as a stub.
# FIXME: This should be removed once vfork in uwin's runtime is fixed.
ac_cv_func_vfork_works=no
# Under uwin 2.0+, sys_nerr and sys_errlist exist, but they are
- # macros (actually, these are imported from a DLL, but the end effect
+ # macros (actually, these are imported from a DLL, but the end effect
# is the same), so the test below won't find them.
libiberty_cv_var_sys_nerr=yes
libiberty_cv_var_sys_errlist=yes
;;
*-*-*vms*)
- # Under VMS, vfork works very different than on Unix. The standard test
+ # Under VMS, vfork works very different than on Unix. The standard test
# won't work, and it isn't easily adaptable. It makes more sense to
# just force it.
ac_cv_func_vfork_works=yes
@@ -2331,205 +4435,354 @@ if test -z "${setobjs}"; then
# We haven't set the list of objects yet. Use the standard autoconf
# tests. This will only work if the compiler works.
- echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:2336: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
-
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-cat > conftest.$ac_ext << EOF
+ echo "$as_me:$LINENO: checking for library containing strerror" >&5
+echo $ECHO_N "checking for library containing strerror... $ECHO_C" >&6
+if test "${ac_cv_search_strerror+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_func_search_save_LIBS=$LIBS
+ac_cv_search_strerror=no
+if test x$gcc_no_link = xyes; then
+ { { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
+echo "$as_me: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&2;}
+ { (exit 1); exit 1; }; }
+fi
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
-#line 2347 "configure"
-#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char strerror ();
+int
+main ()
+{
+strerror ();
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ ac_cv_search_strerror="none required"
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+if test "$ac_cv_search_strerror" = no; then
+ for ac_lib in cposix; do
+ LIBS="-l$ac_lib $ac_func_search_save_LIBS"
+ if test x$gcc_no_link = xyes; then
+ { { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
+echo "$as_me: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&2;}
+ { (exit 1); exit 1; }; }
+fi
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
-main(){return(0);}
-EOF
-if { (eval echo configure:2352: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- ac_cv_prog_cc_works=yes
- # If we can't run a trivial program, we are probably using a cross compiler.
- if (./conftest; exit) 2>/dev/null; then
- ac_cv_prog_cc_cross=no
- else
- ac_cv_prog_cc_cross=yes
- fi
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- ac_cv_prog_cc_works=no
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char strerror ();
+int
+main ()
+{
+strerror ();
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ ac_cv_search_strerror="-l$ac_lib"
+break
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+ done
fi
-rm -fr conftest*
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
+LIBS=$ac_func_search_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_search_strerror" >&5
+echo "${ECHO_T}$ac_cv_search_strerror" >&6
+if test "$ac_cv_search_strerror" != no; then
+ test "$ac_cv_search_strerror" = "none required" || LIBS="$ac_cv_search_strerror $LIBS"
-echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
-if test $ac_cv_prog_cc_works = no; then
- { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:2378: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
-echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
-cross_compiling=$ac_cv_prog_cc_cross
- for ac_func in $funcs
+
+for ac_func in $funcs
do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2385: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2390 "configure"
-#include "confdefs.h"
+as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
+echo "$as_me:$LINENO: checking for $ac_func" >&5
+echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
+if eval "test \"\${$as_ac_var+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test x$gcc_no_link = xyes; then
+ { { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
+echo "$as_me: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&2;}
+ { (exit 1); exit 1; }; }
+fi
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func(); below. */
-#include <assert.h>
+ which can conflict with char $ac_func (); below.
+ Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+ <limits.h> exists even on freestanding compilers. Under hpux,
+ including <limits.h> includes <sys/time.h> and causes problems
+ checking for functions defined therein. */
+#if defined (__STDC__) && !defined (_HPUX_SOURCE)
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func();
-
-int main() {
-
+ builtin and then its argument prototype would still apply. */
+char $ac_func ();
/* The GNU C library defines this for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
-$ac_func();
+char (*f) () = $ac_func;
+#endif
+#ifdef __cplusplus
+}
#endif
-; return 0; }
-EOF
-if { (eval echo configure:2413: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
- cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
-LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}"
+int
+main ()
+{
+return f != $ac_func;
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ eval "$as_ac_var=yes"
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+eval "$as_ac_var=no"
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
+if test `eval echo '${'$as_ac_var'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
+_ACEOF
+
+else
+ LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
fi
done
- echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:2440: checking whether alloca needs Cray hooks" >&5
-if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+ echo "$as_me:$LINENO: checking whether alloca needs Cray hooks" >&5
+echo $ECHO_N "checking whether alloca needs Cray hooks... $ECHO_C" >&6
+if test "${ac_cv_os_cray+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat > conftest.$ac_ext <<EOF
-#line 2445 "configure"
-#include "confdefs.h"
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
#if defined(CRAY) && ! defined(CRAY2)
webecray
#else
wenotbecray
#endif
-EOF
+_ACEOF
if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
- egrep "webecray" >/dev/null 2>&1; then
- rm -rf conftest*
+ $EGREP "webecray" >/dev/null 2>&1; then
ac_cv_os_cray=yes
else
- rm -rf conftest*
ac_cv_os_cray=no
fi
rm -f conftest*
fi
-
-echo "$ac_t""$ac_cv_os_cray" 1>&6
+echo "$as_me:$LINENO: result: $ac_cv_os_cray" >&5
+echo "${ECHO_T}$ac_cv_os_cray" >&6
if test $ac_cv_os_cray = yes; then
for ac_func in _getb67 GETB67 getb67; do
- echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2470: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2475 "configure"
-#include "confdefs.h"
+ as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
+echo "$as_me:$LINENO: checking for $ac_func" >&5
+echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
+if eval "test \"\${$as_ac_var+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test x$gcc_no_link = xyes; then
+ { { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
+echo "$as_me: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&2;}
+ { (exit 1); exit 1; }; }
+fi
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func(); below. */
-#include <assert.h>
+ which can conflict with char $ac_func (); below.
+ Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+ <limits.h> exists even on freestanding compilers. Under hpux,
+ including <limits.h> includes <sys/time.h> and causes problems
+ checking for functions defined therein. */
+#if defined (__STDC__) && !defined (_HPUX_SOURCE)
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func();
-
-int main() {
-
+ builtin and then its argument prototype would still apply. */
+char $ac_func ();
/* The GNU C library defines this for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
-$ac_func();
+char (*f) () = $ac_func;
+#endif
+#ifdef __cplusplus
+}
#endif
-; return 0; }
-EOF
-if { (eval echo configure:2498: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- cat >> confdefs.h <<EOF
+int
+main ()
+{
+return f != $ac_func;
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ eval "$as_ac_var=yes"
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+eval "$as_ac_var=no"
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
+if test `eval echo '${'$as_ac_var'}'` = yes; then
+
+cat >>confdefs.h <<_ACEOF
#define CRAY_STACKSEG_END $ac_func
-EOF
+_ACEOF
break
-else
- echo "$ac_t""no" 1>&6
fi
done
fi
-echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:2524: checking stack direction for C alloca" >&5
-if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+echo "$as_me:$LINENO: checking stack direction for C alloca" >&5
+echo $ECHO_N "checking stack direction for C alloca... $ECHO_C" >&6
+if test "${ac_cv_c_stack_direction+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
if test "$cross_compiling" = yes; then
ac_cv_c_stack_direction=0
else
- cat > conftest.$ac_ext <<EOF
-#line 2532 "configure"
-#include "confdefs.h"
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
find_stack_direction ()
{
static char *addr = 0;
@@ -2546,142 +4799,289 @@ main ()
{
exit (find_stack_direction() < 0);
}
-EOF
-if { (eval echo configure:2551: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-then
+_ACEOF
+rm -f conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
ac_cv_c_stack_direction=1
else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -fr conftest*
- ac_cv_c_stack_direction=-1
+ echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+( exit $ac_status )
+ac_cv_c_stack_direction=-1
fi
-rm -fr conftest*
+rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
-
fi
+echo "$as_me:$LINENO: result: $ac_cv_c_stack_direction" >&5
+echo "${ECHO_T}$ac_cv_c_stack_direction" >&6
-echo "$ac_t""$ac_cv_c_stack_direction" 1>&6
-cat >> confdefs.h <<EOF
+cat >>confdefs.h <<_ACEOF
#define STACK_DIRECTION $ac_cv_c_stack_direction
-EOF
+_ACEOF
+
+
- ac_safe=`echo "vfork.h" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for vfork.h""... $ac_c" 1>&6
-echo "configure:2573: checking for vfork.h" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+for ac_header in unistd.h vfork.h
+do
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <$ac_header>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } >/dev/null; then
+ if test -s conftest.err; then
+ ac_cpp_err=$ac_c_preproc_warn_flag
+ else
+ ac_cpp_err=
+ fi
else
- cat > conftest.$ac_ext <<EOF
-#line 2578 "configure"
-#include "confdefs.h"
-#include <vfork.h>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2583: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- rm -rf conftest*
- eval "ac_cv_header_$ac_safe=yes"
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_header_$ac_safe=no"
+ ac_cpp_err=yes
fi
-rm -f conftest*
+if test -z "$ac_cpp_err"; then
+ eval "$as_ac_Header=yes"
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ eval "$as_ac_Header=no"
fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- cat >> confdefs.h <<\EOF
-#define HAVE_VFORK_H 1
-EOF
+rm -f conftest.err conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
-else
- echo "$ac_t""no" 1>&6
fi
+done
-echo $ac_n "checking for working vfork""... $ac_c" 1>&6
-echo "configure:2608: checking for working vfork" >&5
-if eval "test \"`echo '$''{'ac_cv_func_vfork_works'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test "$cross_compiling" = yes; then
- echo $ac_n "checking for vfork""... $ac_c" 1>&6
-echo "configure:2614: checking for vfork" >&5
-if eval "test \"`echo '$''{'ac_cv_func_vfork'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2619 "configure"
-#include "confdefs.h"
+
+
+for ac_func in fork vfork
+do
+as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
+echo "$as_me:$LINENO: checking for $ac_func" >&5
+echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
+if eval "test \"\${$as_ac_var+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test x$gcc_no_link = xyes; then
+ { { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
+echo "$as_me: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&2;}
+ { (exit 1); exit 1; }; }
+fi
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char vfork(); below. */
-#include <assert.h>
+ which can conflict with char $ac_func (); below.
+ Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+ <limits.h> exists even on freestanding compilers. Under hpux,
+ including <limits.h> includes <sys/time.h> and causes problems
+ checking for functions defined therein. */
+#if defined (__STDC__) && !defined (_HPUX_SOURCE)
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char vfork();
-
-int main() {
-
+ builtin and then its argument prototype would still apply. */
+char $ac_func ();
/* The GNU C library defines this for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
-#if defined (__stub_vfork) || defined (__stub___vfork)
+#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
-vfork();
+char (*f) () = $ac_func;
+#endif
+#ifdef __cplusplus
+}
#endif
-; return 0; }
-EOF
-if { (eval echo configure:2642: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_func_vfork=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_func_vfork=no"
-fi
-rm -f conftest*
+int
+main ()
+{
+return f != $ac_func;
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ eval "$as_ac_var=yes"
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+eval "$as_ac_var=no"
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
+if test `eval echo '${'$as_ac_var'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
+_ACEOF
+
fi
+done
-if eval "test \"`echo '$ac_cv_func_'vfork`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- :
+if test "x$ac_cv_func_fork" = xyes; then
+ echo "$as_me:$LINENO: checking for working fork" >&5
+echo $ECHO_N "checking for working fork... $ECHO_C" >&6
+if test "${ac_cv_func_fork_works+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
- echo "$ac_t""no" 1>&6
+ if test "$cross_compiling" = yes; then
+ ac_cv_func_fork_works=cross
+else
+ cat >conftest.$ac_ext <<_ACEOF
+/* By Ruediger Kuhlmann. */
+ #include <sys/types.h>
+ #if HAVE_UNISTD_H
+ # include <unistd.h>
+ #endif
+ /* Some systems only have a dummy stub for fork() */
+ int main ()
+ {
+ if (fork() < 0)
+ exit (1);
+ exit (0);
+ }
+_ACEOF
+rm -f conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ ac_cv_func_fork_works=yes
+else
+ echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+( exit $ac_status )
+ac_cv_func_fork_works=no
+fi
+rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
+fi
+fi
+echo "$as_me:$LINENO: result: $ac_cv_func_fork_works" >&5
+echo "${ECHO_T}$ac_cv_func_fork_works" >&6
+
+else
+ ac_cv_func_fork_works=$ac_cv_func_fork
+fi
+if test "x$ac_cv_func_fork_works" = xcross; then
+ case $host in
+ *-*-amigaos* | *-*-msdosdjgpp*)
+ # Override, as these systems have only a dummy fork() stub
+ ac_cv_func_fork_works=no
+ ;;
+ *)
+ ac_cv_func_fork_works=yes
+ ;;
+ esac
+ { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
+echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
fi
-
ac_cv_func_vfork_works=$ac_cv_func_vfork
+if test "x$ac_cv_func_vfork" = xyes; then
+ echo "$as_me:$LINENO: checking for working vfork" >&5
+echo $ECHO_N "checking for working vfork... $ECHO_C" >&6
+if test "${ac_cv_func_vfork_works+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
- cat > conftest.$ac_ext <<EOF
-#line 2664 "configure"
-#include "confdefs.h"
+ if test "$cross_compiling" = yes; then
+ ac_cv_func_vfork_works=cross
+else
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
/* Thanks to Paul Eggert for this test. */
#include <stdio.h>
+#include <stdlib.h>
#include <sys/types.h>
#include <sys/stat.h>
-#ifdef HAVE_UNISTD_H
-#include <unistd.h>
+#include <sys/wait.h>
+#if HAVE_UNISTD_H
+# include <unistd.h>
#endif
-#ifdef HAVE_VFORK_H
-#include <vfork.h>
+#if HAVE_VFORK_H
+# include <vfork.h>
#endif
/* On some sparc systems, changes by the child to local and incoming
- argument registers are propagated back to the parent.
- The compiler is told about this with #include <vfork.h>,
- but some compilers (e.g. gcc -O) don't grok <vfork.h>.
- Test for this by using a static variable whose address
- is put into a register that is clobbered by the vfork. */
-static
+ argument registers are propagated back to the parent. The compiler
+ is told about this with #include <vfork.h>, but some compilers
+ (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
+ static variable whose address is put into a register that is
+ clobbered by the vfork. */
+static void
#ifdef __cplusplus
sparc_address_test (int arg)
-#else
+# else
sparc_address_test (arg) int arg;
#endif
{
@@ -2699,25 +5099,27 @@ sparc_address_test (arg) int arg;
}
}
}
-main() {
+
+int
+main ()
+{
pid_t parent = getpid ();
pid_t child;
- sparc_address_test ();
+ sparc_address_test (0);
child = vfork ();
if (child == 0) {
- /* Here is another test for sparc vfork register problems.
- This test uses lots of local variables, at least
- as many local variables as main has allocated so far
- including compiler temporaries. 4 locals are enough for
- gcc 1.40.3 on a Solaris 4.1.3 sparc, but we use 8 to be safe.
- A buggy compiler should reuse the register of parent
- for one of the local variables, since it will think that
- parent can't possibly be used any more in this routine.
- Assigning to the local variable will thus munge parent
- in the parent process. */
+ /* Here is another test for sparc vfork register problems. This
+ test uses lots of local variables, at least as many local
+ variables as main has allocated so far including compiler
+ temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
+ 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
+ reuse the register of parent for one of the local variables,
+ since it will think that parent can't possibly be used any more
+ in this routine. Assigning to the local variable will thus
+ munge parent in the parent process. */
pid_t
p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
@@ -2727,11 +5129,10 @@ main() {
|| p != p5 || p != p6 || p != p7)
_exit(1);
- /* On some systems (e.g. IRIX 3.3),
- vfork doesn't separate parent from child file descriptors.
- If the child closes a descriptor before it execs or exits,
- this munges the parent's descriptor as well.
- Test for this by closing stdout in the child. */
+ /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
+ from child file descriptors. If the child closes a descriptor
+ before it execs or exits, this munges the parent's descriptor
+ as well. Test for this by closing stdout in the child. */
_exit(close(fileno(stdout)) != 0);
} else {
int status;
@@ -2754,351 +5155,708 @@ main() {
);
}
}
-EOF
-if { (eval echo configure:2759: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-then
+_ACEOF
+rm -f conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
ac_cv_func_vfork_works=yes
else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -fr conftest*
- ac_cv_func_vfork_works=no
+ echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+( exit $ac_status )
+ac_cv_func_vfork_works=no
+fi
+rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
-rm -fr conftest*
fi
+echo "$as_me:$LINENO: result: $ac_cv_func_vfork_works" >&5
+echo "${ECHO_T}$ac_cv_func_vfork_works" >&6
+fi;
+if test "x$ac_cv_func_fork_works" = xcross; then
+ ac_cv_func_vfork_works=ac_cv_func_vfork
+ { echo "$as_me:$LINENO: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
+echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
fi
-echo "$ac_t""$ac_cv_func_vfork_works" 1>&6
-if test $ac_cv_func_vfork_works = no; then
- cat >> confdefs.h <<\EOF
+if test "x$ac_cv_func_vfork_works" = xyes; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_WORKING_VFORK 1
+_ACEOF
+
+else
+
+cat >>confdefs.h <<\_ACEOF
#define vfork fork
-EOF
+_ACEOF
+
+fi
+if test "x$ac_cv_func_fork_works" = xyes; then
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE_WORKING_FORK 1
+_ACEOF
fi
if test $ac_cv_func_vfork_works = no; then
- LIBOBJS="$LIBOBJS vfork.o"
+ LIBOBJS="$LIBOBJS vfork.$ac_objext"
fi
# We only need _doprnt if we might use it to implement v*printf.
if test $ac_cv_func_vprintf != yes \
|| test $ac_cv_func_vfprintf != yes \
|| test $ac_cv_func_vsprintf != yes; then
- for ac_func in _doprnt
+
+for ac_func in _doprnt
do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2791: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2796 "configure"
-#include "confdefs.h"
+as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
+echo "$as_me:$LINENO: checking for $ac_func" >&5
+echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
+if eval "test \"\${$as_ac_var+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test x$gcc_no_link = xyes; then
+ { { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
+echo "$as_me: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&2;}
+ { (exit 1); exit 1; }; }
+fi
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func(); below. */
-#include <assert.h>
+ which can conflict with char $ac_func (); below.
+ Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+ <limits.h> exists even on freestanding compilers. Under hpux,
+ including <limits.h> includes <sys/time.h> and causes problems
+ checking for functions defined therein. */
+#if defined (__STDC__) && !defined (_HPUX_SOURCE)
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func();
-
-int main() {
-
+ builtin and then its argument prototype would still apply. */
+char $ac_func ();
/* The GNU C library defines this for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
-$ac_func();
+char (*f) () = $ac_func;
+#endif
+#ifdef __cplusplus
+}
#endif
-; return 0; }
-EOF
-if { (eval echo configure:2819: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
- cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
-LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}"
+int
+main ()
+{
+return f != $ac_func;
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ eval "$as_ac_var=yes"
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+eval "$as_ac_var=no"
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
+if test `eval echo '${'$as_ac_var'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
+_ACEOF
+
+else
+ LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
fi
done
else
- for ac_func in _doprnt
+
+for ac_func in _doprnt
do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2849: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2854 "configure"
-#include "confdefs.h"
+as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
+echo "$as_me:$LINENO: checking for $ac_func" >&5
+echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
+if eval "test \"\${$as_ac_var+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test x$gcc_no_link = xyes; then
+ { { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
+echo "$as_me: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&2;}
+ { (exit 1); exit 1; }; }
+fi
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func(); below. */
-#include <assert.h>
+ which can conflict with char $ac_func (); below.
+ Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+ <limits.h> exists even on freestanding compilers. Under hpux,
+ including <limits.h> includes <sys/time.h> and causes problems
+ checking for functions defined therein. */
+#if defined (__STDC__) && !defined (_HPUX_SOURCE)
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func();
-
-int main() {
-
+ builtin and then its argument prototype would still apply. */
+char $ac_func ();
/* The GNU C library defines this for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
-$ac_func();
+char (*f) () = $ac_func;
+#endif
+#ifdef __cplusplus
+}
#endif
-; return 0; }
-EOF
-if { (eval echo configure:2877: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
+int
+main ()
+{
+return f != $ac_func;
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ eval "$as_ac_var=yes"
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+eval "$as_ac_var=no"
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
+if test `eval echo '${'$as_ac_var'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
+_ACEOF
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
- cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
fi
done
fi
for v in $vars; do
- echo $ac_n "checking for $v""... $ac_c" 1>&6
-echo "configure:2905: checking for $v" >&5
- if eval "test \"`echo '$''{'libiberty_cv_var_$v'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 2910 "configure"
-#include "confdefs.h"
+ echo "$as_me:$LINENO: checking for $v" >&5
+echo $ECHO_N "checking for $v... $ECHO_C" >&6
+ if eval "test \"\${libiberty_cv_var_$v+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test x$gcc_no_link = xyes; then
+ { { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
+echo "$as_me: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&2;}
+ { (exit 1); exit 1; }; }
+fi
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
int *p;
-int main() {
+int
+main ()
+{
extern int $v []; p = $v;
-; return 0; }
-EOF
-if { (eval echo configure:2917: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
eval "libiberty_cv_var_$v=yes"
else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "libiberty_cv_var_$v=no"
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+eval "libiberty_cv_var_$v=no"
fi
-rm -f conftest*
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
fi
if eval "test \"`echo '$libiberty_cv_var_'$v`\" = yes"; then
- echo "$ac_t""yes" 1>&6
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
n=HAVE_`echo $v | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
- cat >> confdefs.h <<EOF
+ cat >>confdefs.h <<_ACEOF
#define $n 1
-EOF
+_ACEOF
else
- echo "$ac_t""no" 1>&6
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
fi
done
- for ac_func in $checkfuncs
-do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2943: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+
+ # special check for _system_configuration because AIX <4.3.2 do not
+ # contain the `physmem' member.
+ echo "$as_me:$LINENO: checking for external symbol _system_configuration" >&5
+echo $ECHO_N "checking for external symbol _system_configuration... $ECHO_C" >&6
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <sys/systemcfg.h>
+int
+main ()
+{
+double x = _system_configuration.physmem;
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ echo "$as_me:$LINENO: result: yes" >&5
+echo "${ECHO_T}yes" >&6
+
+cat >>confdefs.h <<\_ACEOF
+#define HAVE__SYSTEM_CONFIGURATION 1
+_ACEOF
+
else
- cat > conftest.$ac_ext <<EOF
-#line 2948 "configure"
-#include "confdefs.h"
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
+rm -f conftest.$ac_objext conftest.$ac_ext
+
+
+for ac_func in $checkfuncs
+do
+as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
+echo "$as_me:$LINENO: checking for $ac_func" >&5
+echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
+if eval "test \"\${$as_ac_var+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test x$gcc_no_link = xyes; then
+ { { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
+echo "$as_me: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&2;}
+ { (exit 1); exit 1; }; }
+fi
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func(); below. */
-#include <assert.h>
+ which can conflict with char $ac_func (); below.
+ Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+ <limits.h> exists even on freestanding compilers. Under hpux,
+ including <limits.h> includes <sys/time.h> and causes problems
+ checking for functions defined therein. */
+#if defined (__STDC__) && !defined (_HPUX_SOURCE)
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func();
-
-int main() {
-
+ builtin and then its argument prototype would still apply. */
+char $ac_func ();
/* The GNU C library defines this for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
-$ac_func();
+char (*f) () = $ac_func;
+#endif
+#ifdef __cplusplus
+}
#endif
-; return 0; }
-EOF
-if { (eval echo configure:2971: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=yes"
+int
+main ()
+{
+return f != $ac_func;
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ eval "$as_ac_var=yes"
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+eval "$as_ac_var=no"
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
+if test `eval echo '${'$as_ac_var'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
+_ACEOF
+
+fi
+done
+
+ echo "$as_me:$LINENO: checking whether canonicalize_file_name must be declared" >&5
+echo $ECHO_N "checking whether canonicalize_file_name must be declared... $ECHO_C" >&6
+if test "${libiberty_cv_decl_needed_canonicalize_file_name+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=no"
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+
+#include "confdefs.h"
+#include <stdio.h>
+#ifdef HAVE_STRING_H
+#include <string.h>
+#else
+#ifdef HAVE_STRINGS_H
+#include <strings.h>
+#endif
+#endif
+#ifdef HAVE_STDLIB_H
+#include <stdlib.h>
+#endif
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
+int
+main ()
+{
+char *(*pfn) = (char *(*)) canonicalize_file_name
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext
+if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
+ (eval $ac_compile) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest.$ac_objext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ libiberty_cv_decl_needed_canonicalize_file_name=no
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+libiberty_cv_decl_needed_canonicalize_file_name=yes
fi
-rm -f conftest*
+rm -f conftest.$ac_objext conftest.$ac_ext
fi
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
- cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
+echo "$as_me:$LINENO: result: $libiberty_cv_decl_needed_canonicalize_file_name" >&5
+echo "${ECHO_T}$libiberty_cv_decl_needed_canonicalize_file_name" >&6
+if test $libiberty_cv_decl_needed_canonicalize_file_name = yes; then
+
+cat >>confdefs.h <<\_ACEOF
+#define NEED_DECLARATION_CANONICALIZE_FILE_NAME 1
+_ACEOF
+
fi
-done
fi
-for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
-do
-ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
-echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3001: checking for $ac_hdr" >&5
-if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 3006 "configure"
-#include "confdefs.h"
-#include <$ac_hdr>
-EOF
-ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3011: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
-ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
-if test -z "$ac_err"; then
- rm -rf conftest*
- eval "ac_cv_header_$ac_safe=yes"
-else
- echo "$ac_err" >&5
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_header_$ac_safe=no"
+# Figure out which version of pexecute to use.
+case "${host}" in
+ *-*-mingw* | *-*-winnt*) pexecute=./pex-win32.o ;;
+ *-*-msdosdjgpp*) pexecute=./pex-djgpp.o ;;
+ *-*-msdos*) pexecute=./pex-msdos.o ;;
+ *-*-os2-emx*) pexecute=./pex-os2.o ;;
+ *) pexecute=./pex-unix.o ;;
+esac
+
+
+if test x$gcc_no_link = xyes; then
+ if test "x${ac_cv_func_mmap_fixed_mapped+set}" != xset; then
+ ac_cv_func_mmap_fixed_mapped=no
+ fi
fi
-rm -f conftest*
+if test "x${ac_cv_func_mmap_fixed_mapped+set}" != xset; then
+
+
+for ac_header in stdlib.h unistd.h
+do
+as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
+echo "$as_me:$LINENO: checking for $ac_header" >&5
+echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
+if eval "test \"\${$as_ac_Header+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <$ac_header>
+_ACEOF
+if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
+ (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } >/dev/null; then
+ if test -s conftest.err; then
+ ac_cpp_err=$ac_c_preproc_warn_flag
+ else
+ ac_cpp_err=
+ fi
+else
+ ac_cpp_err=yes
fi
-if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
- cat >> confdefs.h <<EOF
-#define $ac_tr_hdr 1
-EOF
-
+if test -z "$ac_cpp_err"; then
+ eval "$as_ac_Header=yes"
else
- echo "$ac_t""no" 1>&6
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ eval "$as_ac_Header=no"
+fi
+rm -f conftest.err conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
+if test `eval echo '${'$as_ac_Header'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
+_ACEOF
+
fi
done
+
for ac_func in getpagesize
do
-echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3040: checking for $ac_func" >&5
-if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.$ac_ext <<EOF
-#line 3045 "configure"
-#include "confdefs.h"
+as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
+echo "$as_me:$LINENO: checking for $ac_func" >&5
+echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
+if eval "test \"\${$as_ac_var+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ if test x$gcc_no_link = xyes; then
+ { { echo "$as_me:$LINENO: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&5
+echo "$as_me: error: Link tests are not allowed after GCC_NO_EXECUTABLES." >&2;}
+ { (exit 1); exit 1; }; }
+fi
+cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
/* System header to define __stub macros and hopefully few prototypes,
- which can conflict with char $ac_func(); below. */
-#include <assert.h>
+ which can conflict with char $ac_func (); below.
+ Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+ <limits.h> exists even on freestanding compilers. Under hpux,
+ including <limits.h> includes <sys/time.h> and causes problems
+ checking for functions defined therein. */
+#if defined (__STDC__) && !defined (_HPUX_SOURCE)
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
/* We use char because int might match the return type of a gcc2
- builtin and then its argument prototype would still apply. */
-char $ac_func();
-
-int main() {
-
+ builtin and then its argument prototype would still apply. */
+char $ac_func ();
/* The GNU C library defines this for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
-$ac_func();
+char (*f) () = $ac_func;
+#endif
+#ifdef __cplusplus
+}
#endif
-; return 0; }
-EOF
-if { (eval echo configure:3068: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=yes"
-else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -rf conftest*
- eval "ac_cv_func_$ac_func=no"
-fi
-rm -f conftest*
-fi
+int
+main ()
+{
+return f != $ac_func;
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ eval "$as_ac_var=yes"
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+eval "$as_ac_var=no"
+fi
+rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
+if test `eval echo '${'$as_ac_var'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
+_ACEOF
-if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
- echo "$ac_t""yes" 1>&6
- ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
- cat >> confdefs.h <<EOF
-#define $ac_tr_func 1
-EOF
-
-else
- echo "$ac_t""no" 1>&6
fi
done
-echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:3093: checking for working mmap" >&5
-if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+echo "$as_me:$LINENO: checking for working mmap" >&5
+echo $ECHO_N "checking for working mmap... $ECHO_C" >&6
+if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
if test "$cross_compiling" = yes; then
ac_cv_func_mmap_fixed_mapped=no
else
- cat > conftest.$ac_ext <<EOF
-#line 3101 "configure"
-#include "confdefs.h"
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+$ac_includes_default
+/* malloc might have been renamed as rpl_malloc. */
+#undef malloc
/* Thanks to Mike Haertel and Jim Avera for this test.
Here is a matrix of mmap possibilities:
@@ -3112,47 +5870,34 @@ else
back from the file, nor mmap's back from the file at a different
address. (There have been systems where private was not correctly
implemented like the infamous i386 svr4.0, and systems where the
- VM page cache was not coherent with the filesystem buffer cache
+ VM page cache was not coherent with the file system buffer cache
like early versions of FreeBSD and possibly contemporary NetBSD.)
For shared mappings, we should conversely verify that changes get
- propogated back to all the places they're supposed to be.
+ propagated back to all the places they're supposed to be.
Grep wants private fixed already mapped.
The main things grep needs to know about mmap are:
* does it exist and is it safe to write into the mmap'd area
* how to use it (BSD variants) */
-#include <sys/types.h>
+
#include <fcntl.h>
#include <sys/mman.h>
-#if HAVE_SYS_TYPES_H
-# include <sys/types.h>
-#endif
-
-#if HAVE_STDLIB_H
-# include <stdlib.h>
-#endif
-
-#if HAVE_SYS_STAT_H
-# include <sys/stat.h>
-#endif
-
-#if HAVE_UNISTD_H
-# include <unistd.h>
+#if !STDC_HEADERS && !HAVE_STDLIB_H
+char *malloc ();
#endif
/* This mess was copied from the GNU getpagesize.h. */
-#ifndef HAVE_GETPAGESIZE
-
+#if !HAVE_GETPAGESIZE
/* Assume that all systems that can run configure have sys/param.h. */
-# ifndef HAVE_SYS_PARAM_H
+# if !HAVE_SYS_PARAM_H
# define HAVE_SYS_PARAM_H 1
# endif
# ifdef _SC_PAGESIZE
# define getpagesize() sysconf(_SC_PAGESIZE)
# else /* no _SC_PAGESIZE */
-# ifdef HAVE_SYS_PARAM_H
+# if HAVE_SYS_PARAM_H
# include <sys/param.h>
# ifdef EXEC_PAGESIZE
# define getpagesize() EXEC_PAGESIZE
@@ -3179,111 +5924,114 @@ else
#endif /* no HAVE_GETPAGESIZE */
-#ifdef __cplusplus
-extern "C" { void *malloc(unsigned); }
-#else
-char *malloc();
-#endif
-
int
-main()
+main ()
{
- char *data, *data2, *data3;
- int i, pagesize;
- int fd;
-
- pagesize = getpagesize();
-
- /*
- * First, make a file with some known garbage in it.
- */
- data = malloc(pagesize);
- if (!data)
- exit(1);
- for (i = 0; i < pagesize; ++i)
- *(data + i) = rand();
- umask(0);
- fd = creat("conftestmmap", 0600);
- if (fd < 0)
- exit(1);
- if (write(fd, data, pagesize) != pagesize)
- exit(1);
- close(fd);
-
- /*
- * Next, try to mmap the file at a fixed address which
- * already has something else allocated at it. If we can,
- * also make sure that we see the same garbage.
- */
- fd = open("conftestmmap", O_RDWR);
- if (fd < 0)
- exit(1);
- data2 = malloc(2 * pagesize);
- if (!data2)
- exit(1);
- data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
- if (data2 != mmap(data2, pagesize, PROT_READ | PROT_WRITE,
- MAP_PRIVATE | MAP_FIXED, fd, 0L))
- exit(1);
- for (i = 0; i < pagesize; ++i)
- if (*(data + i) != *(data2 + i))
- exit(1);
-
- /*
- * Finally, make sure that changes to the mapped area
- * do not percolate back to the file as seen by read().
- * (This is a bug on some variants of i386 svr4.0.)
- */
- for (i = 0; i < pagesize; ++i)
- *(data2 + i) = *(data2 + i) + 1;
- data3 = malloc(pagesize);
- if (!data3)
- exit(1);
- if (read(fd, data3, pagesize) != pagesize)
- exit(1);
- for (i = 0; i < pagesize; ++i)
- if (*(data + i) != *(data3 + i))
- exit(1);
- close(fd);
- unlink("conftestmmap");
- exit(0);
-}
+ char *data, *data2, *data3;
+ int i, pagesize;
+ int fd;
-EOF
-if { (eval echo configure:3254: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-then
+ pagesize = getpagesize ();
+
+ /* First, make a file with some known garbage in it. */
+ data = (char *) malloc (pagesize);
+ if (!data)
+ exit (1);
+ for (i = 0; i < pagesize; ++i)
+ *(data + i) = rand ();
+ umask (0);
+ fd = creat ("conftest.mmap", 0600);
+ if (fd < 0)
+ exit (1);
+ if (write (fd, data, pagesize) != pagesize)
+ exit (1);
+ close (fd);
+
+ /* Next, try to mmap the file at a fixed address which already has
+ something else allocated at it. If we can, also make sure that
+ we see the same garbage. */
+ fd = open ("conftest.mmap", O_RDWR);
+ if (fd < 0)
+ exit (1);
+ data2 = (char *) malloc (2 * pagesize);
+ if (!data2)
+ exit (1);
+ data2 += (pagesize - ((int) data2 & (pagesize - 1))) & (pagesize - 1);
+ if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
+ MAP_PRIVATE | MAP_FIXED, fd, 0L))
+ exit (1);
+ for (i = 0; i < pagesize; ++i)
+ if (*(data + i) != *(data2 + i))
+ exit (1);
+
+ /* Finally, make sure that changes to the mapped area do not
+ percolate back to the file as seen by read(). (This is a bug on
+ some variants of i386 svr4.0.) */
+ for (i = 0; i < pagesize; ++i)
+ *(data2 + i) = *(data2 + i) + 1;
+ data3 = (char *) malloc (pagesize);
+ if (!data3)
+ exit (1);
+ if (read (fd, data3, pagesize) != pagesize)
+ exit (1);
+ for (i = 0; i < pagesize; ++i)
+ if (*(data + i) != *(data3 + i))
+ exit (1);
+ close (fd);
+ exit (0);
+}
+_ACEOF
+rm -f conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
ac_cv_func_mmap_fixed_mapped=yes
else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -fr conftest*
- ac_cv_func_mmap_fixed_mapped=no
+ echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+( exit $ac_status )
+ac_cv_func_mmap_fixed_mapped=no
fi
-rm -fr conftest*
+rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
-
fi
-
-echo "$ac_t""$ac_cv_func_mmap_fixed_mapped" 1>&6
+echo "$as_me:$LINENO: result: $ac_cv_func_mmap_fixed_mapped" >&5
+echo "${ECHO_T}$ac_cv_func_mmap_fixed_mapped" >&6
if test $ac_cv_func_mmap_fixed_mapped = yes; then
- cat >> confdefs.h <<\EOF
+
+cat >>confdefs.h <<\_ACEOF
#define HAVE_MMAP 1
-EOF
+_ACEOF
fi
+rm -f conftest.mmap
+fi
-echo $ac_n "checking for working strncmp""... $ac_c" 1>&6
-echo "configure:3278: checking for working strncmp" >&5
-if eval "test \"`echo '$''{'ac_cv_func_strncmp_works'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
+echo "$as_me:$LINENO: checking for working strncmp" >&5
+echo $ECHO_N "checking for working strncmp... $ECHO_C" >&6
+if test "${ac_cv_func_strncmp_works+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
else
if test "$cross_compiling" = yes; then
ac_cv_func_strncmp_works=no
else
- cat > conftest.$ac_ext <<EOF
-#line 3286 "configure"
-#include "confdefs.h"
+ cat >conftest.$ac_ext <<_ACEOF
+#line $LINENO "configure"
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
/* Test by Jim Wilson and Kaveh Ghazi.
Check whether strncmp reads past the end of its string parameters. */
@@ -3323,7 +6071,7 @@ main ()
dev_zero = open ("/dev/zero", O_RDONLY);
if (dev_zero < 0)
exit (1);
-
+
p = (char *) mmap (0, MAP_LEN, PROT_READ|PROT_WRITE,
MAP_ANON|MAP_PRIVATE, dev_zero, 0);
if (p == (char *)-1)
@@ -3345,25 +6093,35 @@ main ()
exit (0);
}
-EOF
-if { (eval echo configure:3350: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
-then
+_ACEOF
+rm -f conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
ac_cv_func_strncmp_works=yes
else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -fr conftest*
- ac_cv_func_strncmp_works=no
+ echo "$as_me: program exited with status $ac_status" >&5
+echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+( exit $ac_status )
+ac_cv_func_strncmp_works=no
fi
-rm -fr conftest*
+rm -f core core.* *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
-
rm -f core core.* *.core
fi
-
-echo "$ac_t""$ac_cv_func_strncmp_works" 1>&6
+echo "$as_me:$LINENO: result: $ac_cv_func_strncmp_works" >&5
+echo "${ECHO_T}$ac_cv_func_strncmp_works" >&6
if test $ac_cv_func_strncmp_works = no ; then
- LIBOBJS="$LIBOBJS strncmp.o"
+ LIBOBJS="$LIBOBJS strncmp.$ac_objext"
fi
@@ -3376,394 +6134,1178 @@ else
fi
+
+L=""
+for l in x $LIBOBJS; do
+ case $l in
+ x) ;;
+ *) L="$L ./$l" ;;
+ esac
+done
+LIBOBJS="$L"
+
# We need multilib support, but only if configuring for the target.
-trap '' 1 2 15
-cat > confcache <<\EOF
+ ac_config_files="$ac_config_files Makefile testsuite/Makefile"
+ ac_config_commands="$ac_config_commands default"
+cat >confcache <<\_ACEOF
# This file is a shell script that caches the results of configure
# tests run on this system so they can be shared between configure
-# scripts and configure runs. It is not useful on other systems.
-# If it contains results you don't want to keep, you may remove or edit it.
+# scripts and configure runs, see configure's option --config-cache.
+# It is not useful on other systems. If it contains results you don't
+# want to keep, you may remove or edit it.
#
-# By default, configure uses ./config.cache as the cache file,
-# creating it if it does not exist already. You can give configure
-# the --cache-file=FILE option to use a different cache file; that is
-# what configure does when it calls configure scripts in
-# subdirectories, so they share the cache.
-# Giving --cache-file=/dev/null disables caching, for debugging configure.
-# config.status only pays attention to the cache file if you give it the
-# --recheck option to rerun configure.
+# config.status only pays attention to the cache file if you give it
+# the --recheck option to rerun configure.
#
-EOF
+# `ac_cv_env_foo' variables (set or unset) will be overridden when
+# loading this file, other *unset* `ac_cv_foo' will be assigned the
+# following values.
+
+_ACEOF
+
# The following way of writing the cache mishandles newlines in values,
# but we know of no workaround that is simple, portable, and efficient.
# So, don't put newlines in cache variables' values.
# Ultrix sh set writes to stderr and can't be redirected directly,
# and sets the high bit in the cache file unless we assign to the vars.
-(set) 2>&1 |
- case `(ac_space=' '; set | grep ac_space) 2>&1` in
- *ac_space=\ *)
- # `set' does not quote correctly, so add quotes (double-quote substitution
- # turns \\\\ into \\, and sed turns \\ into \).
- sed -n \
- -e "s/'/'\\\\''/g" \
- -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
- ;;
- *)
- # `set' quotes correctly as required by POSIX, so do not add quotes.
- sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
- ;;
- esac >> confcache
-if cmp -s $cache_file confcache; then
- :
-else
+{
+ (set) 2>&1 |
+ case `(ac_space=' '; set | grep ac_space) 2>&1` in
+ *ac_space=\ *)
+ # `set' does not quote correctly, so add quotes (double-quote
+ # substitution turns \\\\ into \\, and sed turns \\ into \).
+ sed -n \
+ "s/'/'\\\\''/g;
+ s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
+ ;;
+ *)
+ # `set' quotes correctly as required by POSIX, so do not add quotes.
+ sed -n \
+ "s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1=\\2/p"
+ ;;
+ esac;
+} |
+ sed '
+ t clear
+ : clear
+ s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
+ t end
+ /^ac_cv_env/!s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
+ : end' >>confcache
+if diff $cache_file confcache >/dev/null 2>&1; then :; else
if test -w $cache_file; then
- echo "updating cache $cache_file"
- cat confcache > $cache_file
+ test "x$cache_file" != "x/dev/null" && echo "updating cache $cache_file"
+ cat confcache >$cache_file
else
echo "not updating unwritable cache $cache_file"
fi
fi
rm -f confcache
-trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
-
test "x$prefix" = xNONE && prefix=$ac_default_prefix
# Let make expand exec_prefix.
test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
-# Any assignment to VPATH causes Sun make to only execute
-# the first set of double-colon rules, so remove it if not needed.
-# If there is a colon in the path, we need to keep it.
+# VPATH may cause trouble with some makes, so we remove $(srcdir),
+# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
+# trailing colons and then remove the whole line if VPATH becomes empty
+# (actually we leave an empty line to preserve line numbers).
if test "x$srcdir" = x.; then
- ac_vpsub='/^[ ]*VPATH[ ]*=[^:]*$/d'
+ ac_vpsub='/^[ ]*VPATH[ ]*=/{
+s/:*\$(srcdir):*/:/;
+s/:*\${srcdir}:*/:/;
+s/:*@srcdir@:*/:/;
+s/^\([^=]*=[ ]*\):*/\1/;
+s/:*$//;
+s/^[^=]*=[ ]*$//;
+}'
fi
-trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
-
DEFS=-DHAVE_CONFIG_H
-# Without the "./", some shells look in PATH for config.status.
-: ${CONFIG_STATUS=./config.status}
+ac_libobjs=
+ac_ltlibobjs=
+for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
+ # 1. Remove the extension, and $U if already installed.
+ ac_i=`echo "$ac_i" |
+ sed 's/\$U\././;s/\.o$//;s/\.obj$//'`
+ # 2. Add them.
+ ac_libobjs="$ac_libobjs $ac_i\$U.$ac_objext"
+ ac_ltlibobjs="$ac_ltlibobjs $ac_i"'$U.lo'
+done
+LIBOBJS=$ac_libobjs
-echo creating $CONFIG_STATUS
-rm -f $CONFIG_STATUS
-cat > $CONFIG_STATUS <<EOF
-#! /bin/sh
-# Generated automatically by configure.
+LTLIBOBJS=$ac_ltlibobjs
+
+
+
+: ${CONFIG_STATUS=./config.status}
+ac_clean_files_save=$ac_clean_files
+ac_clean_files="$ac_clean_files $CONFIG_STATUS"
+{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
+echo "$as_me: creating $CONFIG_STATUS" >&6;}
+cat >$CONFIG_STATUS <<_ACEOF
+#! $SHELL
+# Generated by $as_me.
# Run this file to recreate the current configuration.
-# This directory was configured as follows,
-# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
-#
-# $0 $ac_configure_args
-#
# Compiler output produced by configure, useful for debugging
-# configure, is in ./config.log if it exists.
+# configure, is in config.log if it exists.
-ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
-for ac_option
+debug=false
+ac_cs_recheck=false
+ac_cs_silent=false
+SHELL=\${CONFIG_SHELL-$SHELL}
+_ACEOF
+
+cat >>$CONFIG_STATUS <<\_ACEOF
+## --------------------- ##
+## M4sh Initialization. ##
+## --------------------- ##
+
+# Be Bourne compatible
+if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
+ emulate sh
+ NULLCMD=:
+ # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
+ # is contrary to our usage. Disable this feature.
+ alias -g '${1+"$@"}'='"$@"'
+elif test -n "${BASH_VERSION+set}" && (set -o posix) >/dev/null 2>&1; then
+ set -o posix
+fi
+
+# Support unset when possible.
+if (FOO=FOO; unset FOO) >/dev/null 2>&1; then
+ as_unset=unset
+else
+ as_unset=false
+fi
+
+
+# Work around bugs in pre-3.0 UWIN ksh.
+$as_unset ENV MAIL MAILPATH
+PS1='$ '
+PS2='> '
+PS4='+ '
+
+# NLS nuisances.
+for as_var in \
+ LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
+ LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
+ LC_TELEPHONE LC_TIME
do
- case "\$ac_option" in
- -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
- echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
- exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
- -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
- echo "$CONFIG_STATUS generated by autoconf version 2.13"
- exit 0 ;;
- -help | --help | --hel | --he | --h)
- echo "\$ac_cs_usage"; exit 0 ;;
- *) echo "\$ac_cs_usage"; exit 1 ;;
- esac
+ if (set +x; test -n "`(eval $as_var=C; export $as_var) 2>&1`"); then
+ eval $as_var=C; export $as_var
+ else
+ $as_unset $as_var
+ fi
done
-ac_given_srcdir=$srcdir
-ac_given_INSTALL="$INSTALL"
+# Required to use basename.
+if expr a : '\(a\)' >/dev/null 2>&1; then
+ as_expr=expr
+else
+ as_expr=false
+fi
-trap 'rm -fr `echo "Makefile testsuite/Makefile config.h:config.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
-EOF
-cat >> $CONFIG_STATUS <<EOF
+if (basename /) >/dev/null 2>&1 && test "X`basename / 2>&1`" = "X/"; then
+ as_basename=basename
+else
+ as_basename=false
+fi
-# Protect against being on the right side of a sed subst in config.status.
-sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
- s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
-$ac_vpsub
-$extrasub
-s%@SHELL@%$SHELL%g
-s%@CFLAGS@%$CFLAGS%g
-s%@CPPFLAGS@%$CPPFLAGS%g
-s%@CXXFLAGS@%$CXXFLAGS%g
-s%@FFLAGS@%$FFLAGS%g
-s%@DEFS@%$DEFS%g
-s%@LDFLAGS@%$LDFLAGS%g
-s%@LIBS@%$LIBS%g
-s%@exec_prefix@%$exec_prefix%g
-s%@prefix@%$prefix%g
-s%@program_transform_name@%$program_transform_name%g
-s%@bindir@%$bindir%g
-s%@sbindir@%$sbindir%g
-s%@libexecdir@%$libexecdir%g
-s%@datadir@%$datadir%g
-s%@sysconfdir@%$sysconfdir%g
-s%@sharedstatedir@%$sharedstatedir%g
-s%@localstatedir@%$localstatedir%g
-s%@libdir@%$libdir%g
-s%@includedir@%$includedir%g
-s%@oldincludedir@%$oldincludedir%g
-s%@infodir@%$infodir%g
-s%@mandir@%$mandir%g
-s%@MAINT@%$MAINT%g
-s%@NOTMAINT@%$NOTMAINT%g
-s%@MAKEINFO@%$MAKEINFO%g
-s%@BUILD_INFO@%$BUILD_INFO%g
-s%@PERL@%$PERL%g
-s%@HAVE_PERL@%$HAVE_PERL%g
-s%@host@%$host%g
-s%@host_alias@%$host_alias%g
-s%@host_cpu@%$host_cpu%g
-s%@host_vendor@%$host_vendor%g
-s%@host_os@%$host_os%g
-s%@build@%$build%g
-s%@build_alias@%$build_alias%g
-s%@build_cpu@%$build_cpu%g
-s%@build_vendor@%$build_vendor%g
-s%@build_os@%$build_os%g
-s%@AR@%$AR%g
-s%@RANLIB@%$RANLIB%g
-s%@CC@%$CC%g
-s%@ac_libiberty_warn_cflags@%$ac_libiberty_warn_cflags%g
-s%@NO_MINUS_C_MINUS_O@%$NO_MINUS_C_MINUS_O%g
-s%@OUTPUT_OPTION@%$OUTPUT_OPTION%g
-s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
-s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
-s%@INSTALL_DATA@%$INSTALL_DATA%g
-/@host_makefile_frag@/r $host_makefile_frag
-s%@host_makefile_frag@%%g
-s%@CPP@%$CPP%g
-s%@CHECK@%$CHECK%g
-s%@target_header_dir@%$target_header_dir%g
-s%@LIBOBJS@%$LIBOBJS%g
-s%@INSTALL_DEST@%$INSTALL_DEST%g
-CEOF
-EOF
+# Name of the executable.
+as_me=`$as_basename "$0" ||
+$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
+ X"$0" : 'X\(//\)$' \| \
+ X"$0" : 'X\(/\)$' \| \
+ . : '\(.\)' 2>/dev/null ||
+echo X/"$0" |
+ sed '/^.*\/\([^/][^/]*\)\/*$/{ s//\1/; q; }
+ /^X\/\(\/\/\)$/{ s//\1/; q; }
+ /^X\/\(\/\).*/{ s//\1/; q; }
+ s/.*/./; q'`
+
-cat >> $CONFIG_STATUS <<\EOF
-
-# Split the substitutions into bite-sized pieces for seds with
-# small command number limits, like on Digital OSF/1 and HP-UX.
-ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
-ac_file=1 # Number of current file.
-ac_beg=1 # First line for current file.
-ac_end=$ac_max_sed_cmds # Line after last line for current file.
-ac_more_lines=:
-ac_sed_cmds=""
-while $ac_more_lines; do
- if test $ac_beg -gt 1; then
- sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
+# PATH needs CR, and LINENO needs CR and PATH.
+# Avoid depending upon Character Ranges.
+as_cr_letters='abcdefghijklmnopqrstuvwxyz'
+as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
+as_cr_Letters=$as_cr_letters$as_cr_LETTERS
+as_cr_digits='0123456789'
+as_cr_alnum=$as_cr_Letters$as_cr_digits
+
+# The user is always right.
+if test "${PATH_SEPARATOR+set}" != set; then
+ echo "#! /bin/sh" >conf$$.sh
+ echo "exit 0" >>conf$$.sh
+ chmod +x conf$$.sh
+ if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
+ PATH_SEPARATOR=';'
else
- sed "${ac_end}q" conftest.subs > conftest.s$ac_file
+ PATH_SEPARATOR=:
fi
- if test ! -s conftest.s$ac_file; then
- ac_more_lines=false
- rm -f conftest.s$ac_file
+ rm -f conf$$.sh
+fi
+
+
+ as_lineno_1=$LINENO
+ as_lineno_2=$LINENO
+ as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
+ test "x$as_lineno_1" != "x$as_lineno_2" &&
+ test "x$as_lineno_3" = "x$as_lineno_2" || {
+ # Find who we are. Look in the path if we contain no path at all
+ # relative or not.
+ case $0 in
+ *[\\/]* ) as_myself=$0 ;;
+ *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
+done
+
+ ;;
+ esac
+ # We did not find ourselves, most probably we were run as `sh COMMAND'
+ # in which case we are not to be found in the path.
+ if test "x$as_myself" = x; then
+ as_myself=$0
+ fi
+ if test ! -f "$as_myself"; then
+ { { echo "$as_me:$LINENO: error: cannot find myself; rerun with an absolute path" >&5
+echo "$as_me: error: cannot find myself; rerun with an absolute path" >&2;}
+ { (exit 1); exit 1; }; }
+ fi
+ case $CONFIG_SHELL in
+ '')
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for as_base in sh bash ksh sh5; do
+ case $as_dir in
+ /*)
+ if ("$as_dir/$as_base" -c '
+ as_lineno_1=$LINENO
+ as_lineno_2=$LINENO
+ as_lineno_3=`(expr $as_lineno_1 + 1) 2>/dev/null`
+ test "x$as_lineno_1" != "x$as_lineno_2" &&
+ test "x$as_lineno_3" = "x$as_lineno_2" ') 2>/dev/null; then
+ $as_unset BASH_ENV || test "${BASH_ENV+set}" != set || { BASH_ENV=; export BASH_ENV; }
+ $as_unset ENV || test "${ENV+set}" != set || { ENV=; export ENV; }
+ CONFIG_SHELL=$as_dir/$as_base
+ export CONFIG_SHELL
+ exec "$CONFIG_SHELL" "$0" ${1+"$@"}
+ fi;;
+ esac
+ done
+done
+;;
+ esac
+
+ # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
+ # uniformly replaced by the line number. The first 'sed' inserts a
+ # line-number line before each line; the second 'sed' does the real
+ # work. The second script uses 'N' to pair each line-number line
+ # with the numbered line, and appends trailing '-' during
+ # substitution so that $LINENO is not a special case at line end.
+ # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
+ # second 'sed' script. Blame Lee E. McMahon for sed's syntax. :-)
+ sed '=' <$as_myself |
+ sed '
+ N
+ s,$,-,
+ : loop
+ s,^\(['$as_cr_digits']*\)\(.*\)[$]LINENO\([^'$as_cr_alnum'_]\),\1\2\1\3,
+ t loop
+ s,-$,,
+ s,^['$as_cr_digits']*\n,,
+ ' >$as_me.lineno &&
+ chmod +x $as_me.lineno ||
+ { { echo "$as_me:$LINENO: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&5
+echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2;}
+ { (exit 1); exit 1; }; }
+
+ # Don't try to exec as it changes $[0], causing all sort of problems
+ # (the dirname of $[0] is not the place where we might find the
+ # original and so on. Autoconf is especially sensible to this).
+ . ./$as_me.lineno
+ # Exit status is that of the last command.
+ exit
+}
+
+
+case `echo "testing\c"; echo 1,2,3`,`echo -n testing; echo 1,2,3` in
+ *c*,-n*) ECHO_N= ECHO_C='
+' ECHO_T=' ' ;;
+ *c*,* ) ECHO_N=-n ECHO_C= ECHO_T= ;;
+ *) ECHO_N= ECHO_C='\c' ECHO_T= ;;
+esac
+
+if expr a : '\(a\)' >/dev/null 2>&1; then
+ as_expr=expr
+else
+ as_expr=false
+fi
+
+rm -f conf$$ conf$$.exe conf$$.file
+echo >conf$$.file
+if ln -s conf$$.file conf$$ 2>/dev/null; then
+ # We could just check for DJGPP; but this test a) works b) is more generic
+ # and c) will remain valid once DJGPP supports symlinks (DJGPP 2.04).
+ if test -f conf$$.exe; then
+ # Don't use ln at all; we don't have any links
+ as_ln_s='cp -p'
else
- if test -z "$ac_sed_cmds"; then
- ac_sed_cmds="sed -f conftest.s$ac_file"
- else
- ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
- fi
- ac_file=`expr $ac_file + 1`
- ac_beg=$ac_end
- ac_end=`expr $ac_end + $ac_max_sed_cmds`
+ as_ln_s='ln -s'
fi
+elif ln conf$$.file conf$$ 2>/dev/null; then
+ as_ln_s=ln
+else
+ as_ln_s='cp -p'
+fi
+rm -f conf$$ conf$$.exe conf$$.file
+
+if mkdir -p . 2>/dev/null; then
+ as_mkdir_p=:
+else
+ as_mkdir_p=false
+fi
+
+as_executable_p="test -f"
+
+# Sed expression to map a string onto a valid CPP name.
+as_tr_cpp="sed y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
+
+# Sed expression to map a string onto a valid variable name.
+as_tr_sh="sed y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
+
+
+# IFS
+# We need space, tab and new line, in precisely that order.
+as_nl='
+'
+IFS=" $as_nl"
+
+# CDPATH.
+$as_unset CDPATH
+
+exec 6>&1
+
+# Open the log real soon, to keep \$[0] and so on meaningful, and to
+# report actual input values of CONFIG_FILES etc. instead of their
+# values after options handling. Logging --version etc. is OK.
+exec 5>>config.log
+{
+ echo
+ sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
+## Running $as_me. ##
+_ASBOX
+} >&5
+cat >&5 <<_CSEOF
+
+This file was extended by $as_me, which was
+generated by GNU Autoconf 2.57. Invocation command line was
+
+ CONFIG_FILES = $CONFIG_FILES
+ CONFIG_HEADERS = $CONFIG_HEADERS
+ CONFIG_LINKS = $CONFIG_LINKS
+ CONFIG_COMMANDS = $CONFIG_COMMANDS
+ $ $0 $@
+
+_CSEOF
+echo "on `(hostname || uname -n) 2>/dev/null | sed 1q`" >&5
+echo >&5
+_ACEOF
+
+# Files that config.status was made for.
+if test -n "$ac_config_files"; then
+ echo "config_files=\"$ac_config_files\"" >>$CONFIG_STATUS
+fi
+
+if test -n "$ac_config_headers"; then
+ echo "config_headers=\"$ac_config_headers\"" >>$CONFIG_STATUS
+fi
+
+if test -n "$ac_config_links"; then
+ echo "config_links=\"$ac_config_links\"" >>$CONFIG_STATUS
+fi
+
+if test -n "$ac_config_commands"; then
+ echo "config_commands=\"$ac_config_commands\"" >>$CONFIG_STATUS
+fi
+
+cat >>$CONFIG_STATUS <<\_ACEOF
+
+ac_cs_usage="\
+\`$as_me' instantiates files from templates according to the
+current configuration.
+
+Usage: $0 [OPTIONS] [FILE]...
+
+ -h, --help print this help, then exit
+ -V, --version print version number, then exit
+ -q, --quiet do not print progress messages
+ -d, --debug don't remove temporary files
+ --recheck update $as_me by reconfiguring in the same conditions
+ --file=FILE[:TEMPLATE]
+ instantiate the configuration file FILE
+ --header=FILE[:TEMPLATE]
+ instantiate the configuration header FILE
+
+Configuration files:
+$config_files
+
+Configuration headers:
+$config_headers
+
+Configuration commands:
+$config_commands
+
+Report bugs to <bug-autoconf@gnu.org>."
+_ACEOF
+
+cat >>$CONFIG_STATUS <<_ACEOF
+ac_cs_version="\\
+config.status
+configured by $0, generated by GNU Autoconf 2.57,
+ with options \\"`echo "$ac_configure_args" | sed 's/[\\""\`\$]/\\\\&/g'`\\"
+
+Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
+Free Software Foundation, Inc.
+This config.status script is free software; the Free Software Foundation
+gives unlimited permission to copy, distribute and modify it."
+srcdir=$srcdir
+INSTALL="$INSTALL"
+_ACEOF
+
+cat >>$CONFIG_STATUS <<\_ACEOF
+# If no file are specified by the user, then we need to provide default
+# value. By we need to know if files were specified by the user.
+ac_need_defaults=:
+while test $# != 0
+do
+ case $1 in
+ --*=*)
+ ac_option=`expr "x$1" : 'x\([^=]*\)='`
+ ac_optarg=`expr "x$1" : 'x[^=]*=\(.*\)'`
+ ac_shift=:
+ ;;
+ -*)
+ ac_option=$1
+ ac_optarg=$2
+ ac_shift=shift
+ ;;
+ *) # This is not an option, so the user has probably given explicit
+ # arguments.
+ ac_option=$1
+ ac_need_defaults=false;;
+ esac
+
+ case $ac_option in
+ # Handling of the options.
+_ACEOF
+cat >>$CONFIG_STATUS <<\_ACEOF
+ -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
+ ac_cs_recheck=: ;;
+ --version | --vers* | -V )
+ echo "$ac_cs_version"; exit 0 ;;
+ --he | --h)
+ # Conflict between --help and --header
+ { { echo "$as_me:$LINENO: error: ambiguous option: $1
+Try \`$0 --help' for more information." >&5
+echo "$as_me: error: ambiguous option: $1
+Try \`$0 --help' for more information." >&2;}
+ { (exit 1); exit 1; }; };;
+ --help | --hel | -h )
+ echo "$ac_cs_usage"; exit 0 ;;
+ --debug | --d* | -d )
+ debug=: ;;
+ --file | --fil | --fi | --f )
+ $ac_shift
+ CONFIG_FILES="$CONFIG_FILES $ac_optarg"
+ ac_need_defaults=false;;
+ --header | --heade | --head | --hea )
+ $ac_shift
+ CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
+ ac_need_defaults=false;;
+ -q | -quiet | --quiet | --quie | --qui | --qu | --q \
+ | -silent | --silent | --silen | --sile | --sil | --si | --s)
+ ac_cs_silent=: ;;
+
+ # This is an error.
+ -*) { { echo "$as_me:$LINENO: error: unrecognized option: $1
+Try \`$0 --help' for more information." >&5
+echo "$as_me: error: unrecognized option: $1
+Try \`$0 --help' for more information." >&2;}
+ { (exit 1); exit 1; }; } ;;
+
+ *) ac_config_targets="$ac_config_targets $1" ;;
+
+ esac
+ shift
done
-if test -z "$ac_sed_cmds"; then
- ac_sed_cmds=cat
+
+ac_configure_extra_args=
+
+if $ac_cs_silent; then
+ exec 6>/dev/null
+ ac_configure_extra_args="$ac_configure_extra_args --silent"
fi
-EOF
-cat >> $CONFIG_STATUS <<EOF
+_ACEOF
+cat >>$CONFIG_STATUS <<_ACEOF
+if \$ac_cs_recheck; then
+ echo "running $SHELL $0 " $ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
+ exec $SHELL $0 $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
+fi
-CONFIG_FILES=\${CONFIG_FILES-"Makefile testsuite/Makefile"}
-EOF
-cat >> $CONFIG_STATUS <<\EOF
-for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
- # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
- case "$ac_file" in
- *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
- ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- *) ac_file_in="${ac_file}.in" ;;
+_ACEOF
+
+cat >>$CONFIG_STATUS <<_ACEOF
+#
+# INIT-COMMANDS section.
+#
+
+srcdir=${srcdir}
+host=${host}
+target=${target}
+with_target_subdir=${with_target_subdir}
+with_build_subdir=${with_build_subdir}
+with_multisubdir=${with_multisubdir}
+ac_configure_args="--enable-multilib ${ac_configure_args}"
+CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
+ORIGINAL_LD_FOR_MULTILIBS="${ORIGINAL_LD_FOR_MULTILIBS}"
+libiberty_topdir=${libiberty_topdir}
+
+
+_ACEOF
+
+
+
+cat >>$CONFIG_STATUS <<\_ACEOF
+for ac_config_target in $ac_config_targets
+do
+ case "$ac_config_target" in
+ # Handling of arguments.
+ "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
+ "testsuite/Makefile" ) CONFIG_FILES="$CONFIG_FILES testsuite/Makefile" ;;
+ "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
+ "config.h" ) CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;;
+ *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
+echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
+ { (exit 1); exit 1; }; };;
esac
+done
- # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
+# If the user did not use the arguments to specify the items to instantiate,
+# then the envvar interface is used. Set only those that are not.
+# We use the long form for the default assignment because of an extremely
+# bizarre bug on SunOS 4.1.3.
+if $ac_need_defaults; then
+ test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
+ test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
+ test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
+fi
+
+# Have a temporary directory for convenience. Make it in the build tree
+# simply because there is no reason to put it here, and in addition,
+# creating and moving files from /tmp can sometimes cause problems.
+# Create a temporary directory, and hook for its removal unless debugging.
+$debug ||
+{
+ trap 'exit_status=$?; rm -rf $tmp && exit $exit_status' 0
+ trap '{ (exit 1); exit 1; }' 1 2 13 15
+}
- # Remove last slash and all that follows it. Not all systems have dirname.
- ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
- if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
- # The file is in a subdirectory.
- test ! -d "$ac_dir" && mkdir "$ac_dir"
- ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
- # A "../" for each directory in $ac_dir_suffix.
- ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
- else
- ac_dir_suffix= ac_dots=
+# Create a (secure) tmp directory for tmp files.
+
+{
+ tmp=`(umask 077 && mktemp -d -q "./confstatXXXXXX") 2>/dev/null` &&
+ test -n "$tmp" && test -d "$tmp"
+} ||
+{
+ tmp=./confstat$$-$RANDOM
+ (umask 077 && mkdir $tmp)
+} ||
+{
+ echo "$me: cannot create a temporary directory in ." >&2
+ { (exit 1); exit 1; }
+}
+
+_ACEOF
+
+cat >>$CONFIG_STATUS <<_ACEOF
+
+#
+# CONFIG_FILES section.
+#
+
+# No need to generate the scripts if there are no CONFIG_FILES.
+# This happens for instance when ./config.status config.h
+if test -n "\$CONFIG_FILES"; then
+ # Protect against being on the right side of a sed subst in config.status.
+ sed 's/,@/@@/; s/@,/@@/; s/,;t t\$/@;t t/; /@;t t\$/s/[\\\\&,]/\\\\&/g;
+ s/@@/,@/; s/@@/@,/; s/@;t t\$/,;t t/' >\$tmp/subs.sed <<\\CEOF
+s,@SHELL@,$SHELL,;t t
+s,@PATH_SEPARATOR@,$PATH_SEPARATOR,;t t
+s,@PACKAGE_NAME@,$PACKAGE_NAME,;t t
+s,@PACKAGE_TARNAME@,$PACKAGE_TARNAME,;t t
+s,@PACKAGE_VERSION@,$PACKAGE_VERSION,;t t
+s,@PACKAGE_STRING@,$PACKAGE_STRING,;t t
+s,@PACKAGE_BUGREPORT@,$PACKAGE_BUGREPORT,;t t
+s,@exec_prefix@,$exec_prefix,;t t
+s,@prefix@,$prefix,;t t
+s,@program_transform_name@,$program_transform_name,;t t
+s,@bindir@,$bindir,;t t
+s,@sbindir@,$sbindir,;t t
+s,@libexecdir@,$libexecdir,;t t
+s,@datadir@,$datadir,;t t
+s,@sysconfdir@,$sysconfdir,;t t
+s,@sharedstatedir@,$sharedstatedir,;t t
+s,@localstatedir@,$localstatedir,;t t
+s,@libdir@,$libdir,;t t
+s,@includedir@,$includedir,;t t
+s,@oldincludedir@,$oldincludedir,;t t
+s,@infodir@,$infodir,;t t
+s,@mandir@,$mandir,;t t
+s,@build_alias@,$build_alias,;t t
+s,@host_alias@,$host_alias,;t t
+s,@target_alias@,$target_alias,;t t
+s,@DEFS@,$DEFS,;t t
+s,@ECHO_C@,$ECHO_C,;t t
+s,@ECHO_N@,$ECHO_N,;t t
+s,@ECHO_T@,$ECHO_T,;t t
+s,@LIBS@,$LIBS,;t t
+s,@libiberty_topdir@,$libiberty_topdir,;t t
+s,@MAINT@,$MAINT,;t t
+s,@NOTMAINT@,$NOTMAINT,;t t
+s,@MAKEINFO@,$MAKEINFO,;t t
+s,@BUILD_INFO@,$BUILD_INFO,;t t
+s,@PERL@,$PERL,;t t
+s,@HAVE_PERL@,$HAVE_PERL,;t t
+s,@build@,$build,;t t
+s,@build_cpu@,$build_cpu,;t t
+s,@build_vendor@,$build_vendor,;t t
+s,@build_os@,$build_os,;t t
+s,@host@,$host,;t t
+s,@host_cpu@,$host_cpu,;t t
+s,@host_vendor@,$host_vendor,;t t
+s,@host_os@,$host_os,;t t
+s,@AR@,$AR,;t t
+s,@ac_ct_AR@,$ac_ct_AR,;t t
+s,@RANLIB@,$RANLIB,;t t
+s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t
+s,@CC@,$CC,;t t
+s,@CFLAGS@,$CFLAGS,;t t
+s,@LDFLAGS@,$LDFLAGS,;t t
+s,@CPPFLAGS@,$CPPFLAGS,;t t
+s,@ac_ct_CC@,$ac_ct_CC,;t t
+s,@EXEEXT@,$EXEEXT,;t t
+s,@OBJEXT@,$OBJEXT,;t t
+s,@CPP@,$CPP,;t t
+s,@ac_libiberty_warn_cflags@,$ac_libiberty_warn_cflags,;t t
+s,@NO_MINUS_C_MINUS_O@,$NO_MINUS_C_MINUS_O,;t t
+s,@OUTPUT_OPTION@,$OUTPUT_OPTION,;t t
+s,@INSTALL_PROGRAM@,$INSTALL_PROGRAM,;t t
+s,@INSTALL_SCRIPT@,$INSTALL_SCRIPT,;t t
+s,@INSTALL_DATA@,$INSTALL_DATA,;t t
+s,@EGREP@,$EGREP,;t t
+s,@LIBOBJS@,$LIBOBJS,;t t
+s,@CHECK@,$CHECK,;t t
+s,@target_header_dir@,$target_header_dir,;t t
+s,@pexecute@,$pexecute,;t t
+s,@INSTALL_DEST@,$INSTALL_DEST,;t t
+s,@LTLIBOBJS@,$LTLIBOBJS,;t t
+/@host_makefile_frag@/r $host_makefile_frag
+s,@host_makefile_frag@,,;t t
+CEOF
+
+_ACEOF
+
+ cat >>$CONFIG_STATUS <<\_ACEOF
+ # Split the substitutions into bite-sized pieces for seds with
+ # small command number limits, like on Digital OSF/1 and HP-UX.
+ ac_max_sed_lines=48
+ ac_sed_frag=1 # Number of current file.
+ ac_beg=1 # First line for current file.
+ ac_end=$ac_max_sed_lines # Line after last line for current file.
+ ac_more_lines=:
+ ac_sed_cmds=
+ while $ac_more_lines; do
+ if test $ac_beg -gt 1; then
+ sed "1,${ac_beg}d; ${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
+ else
+ sed "${ac_end}q" $tmp/subs.sed >$tmp/subs.frag
+ fi
+ if test ! -s $tmp/subs.frag; then
+ ac_more_lines=false
+ else
+ # The purpose of the label and of the branching condition is to
+ # speed up the sed processing (if there are no `@' at all, there
+ # is no need to browse any of the substitutions).
+ # These are the two extra sed commands mentioned above.
+ (echo ':t
+ /@[a-zA-Z_][a-zA-Z_0-9]*@/!b' && cat $tmp/subs.frag) >$tmp/subs-$ac_sed_frag.sed
+ if test -z "$ac_sed_cmds"; then
+ ac_sed_cmds="sed -f $tmp/subs-$ac_sed_frag.sed"
+ else
+ ac_sed_cmds="$ac_sed_cmds | sed -f $tmp/subs-$ac_sed_frag.sed"
+ fi
+ ac_sed_frag=`expr $ac_sed_frag + 1`
+ ac_beg=$ac_end
+ ac_end=`expr $ac_end + $ac_max_sed_lines`
+ fi
+ done
+ if test -z "$ac_sed_cmds"; then
+ ac_sed_cmds=cat
fi
+fi # test -n "$CONFIG_FILES"
- case "$ac_given_srcdir" in
- .) srcdir=.
- if test -z "$ac_dots"; then top_srcdir=.
- else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
- /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
- *) # Relative path.
- srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
- top_srcdir="$ac_dots$ac_given_srcdir" ;;
+_ACEOF
+cat >>$CONFIG_STATUS <<\_ACEOF
+for ac_file in : $CONFIG_FILES; do test "x$ac_file" = x: && continue
+ # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
+ case $ac_file in
+ - | *:- | *:-:* ) # input from stdin
+ cat >$tmp/stdin
+ ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
+ ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
+ *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
+ ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
+ * ) ac_file_in=$ac_file.in ;;
esac
- case "$ac_given_INSTALL" in
- [/$]*) INSTALL="$ac_given_INSTALL" ;;
- *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
- esac
+ # Compute @srcdir@, @top_srcdir@, and @INSTALL@ for subdirectories.
+ ac_dir=`(dirname "$ac_file") 2>/dev/null ||
+$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
+ X"$ac_file" : 'X\(//\)[^/]' \| \
+ X"$ac_file" : 'X\(//\)$' \| \
+ X"$ac_file" : 'X\(/\)' \| \
+ . : '\(.\)' 2>/dev/null ||
+echo X"$ac_file" |
+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
+ /^X\(\/\/\)[^/].*/{ s//\1/; q; }
+ /^X\(\/\/\)$/{ s//\1/; q; }
+ /^X\(\/\).*/{ s//\1/; q; }
+ s/.*/./; q'`
+ { if $as_mkdir_p; then
+ mkdir -p "$ac_dir"
+ else
+ as_dir="$ac_dir"
+ as_dirs=
+ while test ! -d "$as_dir"; do
+ as_dirs="$as_dir $as_dirs"
+ as_dir=`(dirname "$as_dir") 2>/dev/null ||
+$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
+ X"$as_dir" : 'X\(//\)[^/]' \| \
+ X"$as_dir" : 'X\(//\)$' \| \
+ X"$as_dir" : 'X\(/\)' \| \
+ . : '\(.\)' 2>/dev/null ||
+echo X"$as_dir" |
+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
+ /^X\(\/\/\)[^/].*/{ s//\1/; q; }
+ /^X\(\/\/\)$/{ s//\1/; q; }
+ /^X\(\/\).*/{ s//\1/; q; }
+ s/.*/./; q'`
+ done
+ test ! -n "$as_dirs" || mkdir $as_dirs
+ fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
+echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
+ { (exit 1); exit 1; }; }; }
- echo creating "$ac_file"
- rm -f "$ac_file"
- configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
- case "$ac_file" in
- *Makefile*) ac_comsub="1i\\
-# $configure_input" ;;
- *) ac_comsub= ;;
+ ac_builddir=.
+
+if test "$ac_dir" != .; then
+ ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
+ # A "../" for each directory in $ac_dir_suffix.
+ ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
+else
+ ac_dir_suffix= ac_top_builddir=
+fi
+
+case $srcdir in
+ .) # No --srcdir option. We are building in place.
+ ac_srcdir=.
+ if test -z "$ac_top_builddir"; then
+ ac_top_srcdir=.
+ else
+ ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
+ fi ;;
+ [\\/]* | ?:[\\/]* ) # Absolute path.
+ ac_srcdir=$srcdir$ac_dir_suffix;
+ ac_top_srcdir=$srcdir ;;
+ *) # Relative path.
+ ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
+ ac_top_srcdir=$ac_top_builddir$srcdir ;;
+esac
+# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
+# absolute.
+ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
+ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
+ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
+ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
+
+
+ case $INSTALL in
+ [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
+ *) ac_INSTALL=$ac_top_builddir$INSTALL ;;
esac
- ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
- sed -e "$ac_comsub
-s%@configure_input@%$configure_input%g
-s%@srcdir@%$srcdir%g
-s%@top_srcdir@%$top_srcdir%g
-s%@INSTALL@%$INSTALL%g
-" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
-fi; done
-rm -f conftest.s*
+ if test x"$ac_file" != x-; then
+ { echo "$as_me:$LINENO: creating $ac_file" >&5
+echo "$as_me: creating $ac_file" >&6;}
+ rm -f "$ac_file"
+ fi
+ # Let's still pretend it is `configure' which instantiates (i.e., don't
+ # use $as_me), people would be surprised to read:
+ # /* config.h. Generated by config.status. */
+ if test x"$ac_file" = x-; then
+ configure_input=
+ else
+ configure_input="$ac_file. "
+ fi
+ configure_input=$configure_input"Generated from `echo $ac_file_in |
+ sed 's,.*/,,'` by configure."
+
+ # First look for the input files in the build tree, otherwise in the
+ # src tree.
+ ac_file_inputs=`IFS=:
+ for f in $ac_file_in; do
+ case $f in
+ -) echo $tmp/stdin ;;
+ [\\/$]*)
+ # Absolute (can't be DOS-style, as IFS=:)
+ test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
+echo "$as_me: error: cannot find input file: $f" >&2;}
+ { (exit 1); exit 1; }; }
+ echo $f;;
+ *) # Relative
+ if test -f "$f"; then
+ # Build tree
+ echo $f
+ elif test -f "$srcdir/$f"; then
+ # Source tree
+ echo $srcdir/$f
+ else
+ # /dev/null tree
+ { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
+echo "$as_me: error: cannot find input file: $f" >&2;}
+ { (exit 1); exit 1; }; }
+ fi;;
+ esac
+ done` || { (exit 1); exit 1; }
+_ACEOF
+cat >>$CONFIG_STATUS <<_ACEOF
+ sed "$ac_vpsub
+$extrasub
+_ACEOF
+cat >>$CONFIG_STATUS <<\_ACEOF
+:t
+/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
+s,@configure_input@,$configure_input,;t t
+s,@srcdir@,$ac_srcdir,;t t
+s,@abs_srcdir@,$ac_abs_srcdir,;t t
+s,@top_srcdir@,$ac_top_srcdir,;t t
+s,@abs_top_srcdir@,$ac_abs_top_srcdir,;t t
+s,@builddir@,$ac_builddir,;t t
+s,@abs_builddir@,$ac_abs_builddir,;t t
+s,@top_builddir@,$ac_top_builddir,;t t
+s,@abs_top_builddir@,$ac_abs_top_builddir,;t t
+s,@INSTALL@,$ac_INSTALL,;t t
+" $ac_file_inputs | (eval "$ac_sed_cmds") >$tmp/out
+ rm -f $tmp/stdin
+ if test x"$ac_file" != x-; then
+ mv $tmp/out $ac_file
+ else
+ cat $tmp/out
+ rm -f $tmp/out
+ fi
+
+done
+_ACEOF
+cat >>$CONFIG_STATUS <<\_ACEOF
+
+#
+# CONFIG_HEADER section.
+#
# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
# NAME is the cpp macro being defined and VALUE is the value it is being given.
#
# ac_d sets the value in "#define NAME VALUE" lines.
-ac_dA='s%^\([ ]*\)#\([ ]*define[ ][ ]*\)'
-ac_dB='\([ ][ ]*\)[^ ]*%\1#\2'
-ac_dC='\3'
-ac_dD='%g'
-# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
-ac_uA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
-ac_uB='\([ ]\)%\1#\2define\3'
+ac_dA='s,^\([ ]*\)#\([ ]*define[ ][ ]*\)'
+ac_dB='[ ].*$,\1#\2'
+ac_dC=' '
+ac_dD=',;t'
+# ac_u turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
+ac_uA='s,^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
+ac_uB='$,\1#\2define\3'
ac_uC=' '
-ac_uD='\4%g'
-# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
-ac_eA='s%^\([ ]*\)#\([ ]*\)undef\([ ][ ]*\)'
-ac_eB='$%\1#\2define\3'
-ac_eC=' '
-ac_eD='%g'
-
-if test "${CONFIG_HEADERS+set}" != set; then
-EOF
-cat >> $CONFIG_STATUS <<EOF
- CONFIG_HEADERS="config.h:config.in"
-EOF
-cat >> $CONFIG_STATUS <<\EOF
-fi
-for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
+ac_uD=',;t'
+
+for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
# Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
- case "$ac_file" in
- *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
- ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
- *) ac_file_in="${ac_file}.in" ;;
+ case $ac_file in
+ - | *:- | *:-:* ) # input from stdin
+ cat >$tmp/stdin
+ ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
+ ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
+ *:* ) ac_file_in=`echo "$ac_file" | sed 's,[^:]*:,,'`
+ ac_file=`echo "$ac_file" | sed 's,:.*,,'` ;;
+ * ) ac_file_in=$ac_file.in ;;
esac
- echo creating $ac_file
-
- rm -f conftest.frag conftest.in conftest.out
- ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
- cat $ac_file_inputs > conftest.in
-
-EOF
-
-# Transform confdefs.h into a sed script conftest.vals that substitutes
-# the proper values into config.h.in to produce config.h. And first:
-# Protect against being on the right side of a sed subst in config.status.
-# Protect against being in an unquoted here document in config.status.
-rm -f conftest.vals
-cat > conftest.hdr <<\EOF
-s/[\\&%]/\\&/g
-s%[\\$`]%\\&%g
-s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
-s%ac_d%ac_u%gp
-s%ac_u%ac_e%gp
-EOF
-sed -n -f conftest.hdr confdefs.h > conftest.vals
-rm -f conftest.hdr
+ test x"$ac_file" != x- && { echo "$as_me:$LINENO: creating $ac_file" >&5
+echo "$as_me: creating $ac_file" >&6;}
+
+ # First look for the input files in the build tree, otherwise in the
+ # src tree.
+ ac_file_inputs=`IFS=:
+ for f in $ac_file_in; do
+ case $f in
+ -) echo $tmp/stdin ;;
+ [\\/$]*)
+ # Absolute (can't be DOS-style, as IFS=:)
+ test -f "$f" || { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
+echo "$as_me: error: cannot find input file: $f" >&2;}
+ { (exit 1); exit 1; }; }
+ echo $f;;
+ *) # Relative
+ if test -f "$f"; then
+ # Build tree
+ echo $f
+ elif test -f "$srcdir/$f"; then
+ # Source tree
+ echo $srcdir/$f
+ else
+ # /dev/null tree
+ { { echo "$as_me:$LINENO: error: cannot find input file: $f" >&5
+echo "$as_me: error: cannot find input file: $f" >&2;}
+ { (exit 1); exit 1; }; }
+ fi;;
+ esac
+ done` || { (exit 1); exit 1; }
+ # Remove the trailing spaces.
+ sed 's/[ ]*$//' $ac_file_inputs >$tmp/in
+
+_ACEOF
+
+# Transform confdefs.h into two sed scripts, `conftest.defines' and
+# `conftest.undefs', that substitutes the proper values into
+# config.h.in to produce config.h. The first handles `#define'
+# templates, and the second `#undef' templates.
+# And first: Protect against being on the right side of a sed subst in
+# config.status. Protect against being in an unquoted here document
+# in config.status.
+rm -f conftest.defines conftest.undefs
+# Using a here document instead of a string reduces the quoting nightmare.
+# Putting comments in sed scripts is not portable.
+#
+# `end' is used to avoid that the second main sed command (meant for
+# 0-ary CPP macros) applies to n-ary macro definitions.
+# See the Autoconf documentation for `clear'.
+cat >confdef2sed.sed <<\_ACEOF
+s/[\\&,]/\\&/g
+s,[\\$`],\\&,g
+t clear
+: clear
+s,^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*\)\(([^)]*)\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1\2${ac_dC}\3${ac_dD},gp
+t end
+s,^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)$,${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD},gp
+: end
+_ACEOF
+# If some macros were called several times there might be several times
+# the same #defines, which is useless. Nevertheless, we may not want to
+# sort them, since we want the *last* AC-DEFINE to be honored.
+uniq confdefs.h | sed -n -f confdef2sed.sed >conftest.defines
+sed 's/ac_d/ac_u/g' conftest.defines >conftest.undefs
+rm -f confdef2sed.sed
# This sed command replaces #undef with comments. This is necessary, for
# example, in the case of _POSIX_SOURCE, which is predefined and required
# on some systems where configure will not decide to define it.
-cat >> conftest.vals <<\EOF
-s%^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
-EOF
-
-# Break up conftest.vals because some shells have a limit on
-# the size of here documents, and old seds have small limits too.
+cat >>conftest.undefs <<\_ACEOF
+s,^[ ]*#[ ]*undef[ ][ ]*[a-zA-Z_][a-zA-Z_0-9]*,/* & */,
+_ACEOF
+
+# Break up conftest.defines because some shells have a limit on the size
+# of here documents, and old seds have small limits too (100 cmds).
+echo ' # Handle all the #define templates only if necessary.' >>$CONFIG_STATUS
+echo ' if grep "^[ ]*#[ ]*define" $tmp/in >/dev/null; then' >>$CONFIG_STATUS
+echo ' # If there are no defines, we may have an empty if/fi' >>$CONFIG_STATUS
+echo ' :' >>$CONFIG_STATUS
+rm -f conftest.tail
+while grep . conftest.defines >/dev/null
+do
+ # Write a limited-size here document to $tmp/defines.sed.
+ echo ' cat >$tmp/defines.sed <<CEOF' >>$CONFIG_STATUS
+ # Speed up: don't consider the non `#define' lines.
+ echo '/^[ ]*#[ ]*define/!b' >>$CONFIG_STATUS
+ # Work around the forget-to-reset-the-flag bug.
+ echo 't clr' >>$CONFIG_STATUS
+ echo ': clr' >>$CONFIG_STATUS
+ sed ${ac_max_here_lines}q conftest.defines >>$CONFIG_STATUS
+ echo 'CEOF
+ sed -f $tmp/defines.sed $tmp/in >$tmp/out
+ rm -f $tmp/in
+ mv $tmp/out $tmp/in
+' >>$CONFIG_STATUS
+ sed 1,${ac_max_here_lines}d conftest.defines >conftest.tail
+ rm -f conftest.defines
+ mv conftest.tail conftest.defines
+done
+rm -f conftest.defines
+echo ' fi # grep' >>$CONFIG_STATUS
+echo >>$CONFIG_STATUS
+# Break up conftest.undefs because some shells have a limit on the size
+# of here documents, and old seds have small limits too (100 cmds).
+echo ' # Handle all the #undef templates' >>$CONFIG_STATUS
rm -f conftest.tail
-while :
+while grep . conftest.undefs >/dev/null
do
- ac_lines=`grep -c . conftest.vals`
- # grep -c gives empty output for an empty file on some AIX systems.
- if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
- # Write a limited-size here document to conftest.frag.
- echo ' cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
- sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
+ # Write a limited-size here document to $tmp/undefs.sed.
+ echo ' cat >$tmp/undefs.sed <<CEOF' >>$CONFIG_STATUS
+ # Speed up: don't consider the non `#undef'
+ echo '/^[ ]*#[ ]*undef/!b' >>$CONFIG_STATUS
+ # Work around the forget-to-reset-the-flag bug.
+ echo 't clr' >>$CONFIG_STATUS
+ echo ': clr' >>$CONFIG_STATUS
+ sed ${ac_max_here_lines}q conftest.undefs >>$CONFIG_STATUS
echo 'CEOF
- sed -f conftest.frag conftest.in > conftest.out
- rm -f conftest.in
- mv conftest.out conftest.in
-' >> $CONFIG_STATUS
- sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
- rm -f conftest.vals
- mv conftest.tail conftest.vals
-done
-rm -f conftest.vals
-
-cat >> $CONFIG_STATUS <<\EOF
- rm -f conftest.frag conftest.h
- echo "/* $ac_file. Generated automatically by configure. */" > conftest.h
- cat conftest.in >> conftest.h
- rm -f conftest.in
- if cmp -s $ac_file conftest.h 2>/dev/null; then
- echo "$ac_file is unchanged"
- rm -f conftest.h
+ sed -f $tmp/undefs.sed $tmp/in >$tmp/out
+ rm -f $tmp/in
+ mv $tmp/out $tmp/in
+' >>$CONFIG_STATUS
+ sed 1,${ac_max_here_lines}d conftest.undefs >conftest.tail
+ rm -f conftest.undefs
+ mv conftest.tail conftest.undefs
+done
+rm -f conftest.undefs
+
+cat >>$CONFIG_STATUS <<\_ACEOF
+ # Let's still pretend it is `configure' which instantiates (i.e., don't
+ # use $as_me), people would be surprised to read:
+ # /* config.h. Generated by config.status. */
+ if test x"$ac_file" = x-; then
+ echo "/* Generated by configure. */" >$tmp/config.h
else
- # Remove last slash and all that follows it. Not all systems have dirname.
- ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
- if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
- # The file is in a subdirectory.
- test ! -d "$ac_dir" && mkdir "$ac_dir"
- fi
- rm -f $ac_file
- mv conftest.h $ac_file
+ echo "/* $ac_file. Generated by configure. */" >$tmp/config.h
fi
-fi; done
+ cat $tmp/in >>$tmp/config.h
+ rm -f $tmp/in
+ if test x"$ac_file" != x-; then
+ if diff $ac_file $tmp/config.h >/dev/null 2>&1; then
+ { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
+echo "$as_me: $ac_file is unchanged" >&6;}
+ else
+ ac_dir=`(dirname "$ac_file") 2>/dev/null ||
+$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
+ X"$ac_file" : 'X\(//\)[^/]' \| \
+ X"$ac_file" : 'X\(//\)$' \| \
+ X"$ac_file" : 'X\(/\)' \| \
+ . : '\(.\)' 2>/dev/null ||
+echo X"$ac_file" |
+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
+ /^X\(\/\/\)[^/].*/{ s//\1/; q; }
+ /^X\(\/\/\)$/{ s//\1/; q; }
+ /^X\(\/\).*/{ s//\1/; q; }
+ s/.*/./; q'`
+ { if $as_mkdir_p; then
+ mkdir -p "$ac_dir"
+ else
+ as_dir="$ac_dir"
+ as_dirs=
+ while test ! -d "$as_dir"; do
+ as_dirs="$as_dir $as_dirs"
+ as_dir=`(dirname "$as_dir") 2>/dev/null ||
+$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
+ X"$as_dir" : 'X\(//\)[^/]' \| \
+ X"$as_dir" : 'X\(//\)$' \| \
+ X"$as_dir" : 'X\(/\)' \| \
+ . : '\(.\)' 2>/dev/null ||
+echo X"$as_dir" |
+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
+ /^X\(\/\/\)[^/].*/{ s//\1/; q; }
+ /^X\(\/\/\)$/{ s//\1/; q; }
+ /^X\(\/\).*/{ s//\1/; q; }
+ s/.*/./; q'`
+ done
+ test ! -n "$as_dirs" || mkdir $as_dirs
+ fi || { { echo "$as_me:$LINENO: error: cannot create directory \"$ac_dir\"" >&5
+echo "$as_me: error: cannot create directory \"$ac_dir\"" >&2;}
+ { (exit 1); exit 1; }; }; }
-EOF
-cat >> $CONFIG_STATUS <<EOF
-srcdir=${srcdir}
-host=${host}
-target=${target}
-with_target_subdir=${with_target_subdir}
-with_build_subdir=${with_build_subdir}
-with_multisubdir=${with_multisubdir}
-ac_configure_args="--enable-multilib ${ac_configure_args}"
-CONFIG_SHELL=${CONFIG_SHELL-/bin/sh}
-libiberty_topdir=${libiberty_topdir}
+ rm -f $ac_file
+ mv $tmp/config.h $ac_file
+ fi
+ else
+ cat $tmp/config.h
+ rm -f $tmp/config.h
+ fi
+done
+_ACEOF
+cat >>$CONFIG_STATUS <<\_ACEOF
-EOF
-cat >> $CONFIG_STATUS <<\EOF
-test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h
+#
+# CONFIG_COMMANDS section.
+#
+for ac_file in : $CONFIG_COMMANDS; do test "x$ac_file" = x: && continue
+ ac_dest=`echo "$ac_file" | sed 's,:.*,,'`
+ ac_source=`echo "$ac_file" | sed 's,[^:]*:,,'`
+ ac_dir=`(dirname "$ac_dest") 2>/dev/null ||
+$as_expr X"$ac_dest" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
+ X"$ac_dest" : 'X\(//\)[^/]' \| \
+ X"$ac_dest" : 'X\(//\)$' \| \
+ X"$ac_dest" : 'X\(/\)' \| \
+ . : '\(.\)' 2>/dev/null ||
+echo X"$ac_dest" |
+ sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ s//\1/; q; }
+ /^X\(\/\/\)[^/].*/{ s//\1/; q; }
+ /^X\(\/\/\)$/{ s//\1/; q; }
+ /^X\(\/\).*/{ s//\1/; q; }
+ s/.*/./; q'`
+ ac_builddir=.
+
+if test "$ac_dir" != .; then
+ ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
+ # A "../" for each directory in $ac_dir_suffix.
+ ac_top_builddir=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,../,g'`
+else
+ ac_dir_suffix= ac_top_builddir=
+fi
+
+case $srcdir in
+ .) # No --srcdir option. We are building in place.
+ ac_srcdir=.
+ if test -z "$ac_top_builddir"; then
+ ac_top_srcdir=.
+ else
+ ac_top_srcdir=`echo $ac_top_builddir | sed 's,/$,,'`
+ fi ;;
+ [\\/]* | ?:[\\/]* ) # Absolute path.
+ ac_srcdir=$srcdir$ac_dir_suffix;
+ ac_top_srcdir=$srcdir ;;
+ *) # Relative path.
+ ac_srcdir=$ac_top_builddir$srcdir$ac_dir_suffix
+ ac_top_srcdir=$ac_top_builddir$srcdir ;;
+esac
+# Don't blindly perform a `cd "$ac_dir"/$ac_foo && pwd` since $ac_foo can be
+# absolute.
+ac_abs_builddir=`cd "$ac_dir" && cd $ac_builddir && pwd`
+ac_abs_top_builddir=`cd "$ac_dir" && cd ${ac_top_builddir}. && pwd`
+ac_abs_srcdir=`cd "$ac_dir" && cd $ac_srcdir && pwd`
+ac_abs_top_srcdir=`cd "$ac_dir" && cd $ac_top_srcdir && pwd`
+
+
+ { echo "$as_me:$LINENO: executing $ac_dest commands" >&5
+echo "$as_me: executing $ac_dest commands" >&6;}
+ case $ac_dest in
+ default ) test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h
if test -n "$CONFIG_FILES"; then
if test -n "${with_build_subdir}" || test -n "${with_target_subdir}"; then
# FIXME: We shouldn't need to set ac_file
@@ -3771,10 +7313,37 @@ if test -n "$CONFIG_FILES"; then
LD="${ORIGINAL_LD_FOR_MULTILIBS}"
. ${libiberty_topdir}/config-ml.in
fi
-fi
-exit 0
-EOF
+fi ;;
+ esac
+done
+_ACEOF
+
+cat >>$CONFIG_STATUS <<\_ACEOF
+
+{ (exit 0); exit 0; }
+_ACEOF
chmod +x $CONFIG_STATUS
-rm -fr confdefs* $ac_clean_files
-test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
+ac_clean_files=$ac_clean_files_save
+
+
+# configure is writing to config.log, and then calls config.status.
+# config.status does its own redirection, appending to config.log.
+# Unfortunately, on DOS this fails, as config.log is still kept open
+# by configure, so config.status won't be able to write to it; its
+# output is simply discarded. So we exec the FD to /dev/null,
+# effectively closing config.log, so it can be properly (re)opened and
+# appended to by config.status. When coming back to configure, we
+# need to make the FD available again.
+if test "$no_create" != yes; then
+ ac_cs_success=:
+ ac_config_status_args=
+ test "$silent" = yes &&
+ ac_config_status_args="$ac_config_status_args --quiet"
+ exec 5>/dev/null
+ $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
+ exec 5>>config.log
+ # Use ||, not &&, to avoid exiting from the if with $? = 1, which
+ # would make configure fail if this is the last instruction.
+ $ac_cs_success || { (exit 1); exit 1; }
+fi
diff --git a/contrib/binutils/libiberty/copysign.c b/contrib/binutils/libiberty/copysign.c
index 5c48a54..d288be2 100644
--- a/contrib/binutils/libiberty/copysign.c
+++ b/contrib/binutils/libiberty/copysign.c
@@ -131,7 +131,9 @@ typedef union
#if defined(__IEEE_BIG_ENDIAN) || defined(__IEEE_LITTLE_ENDIAN)
-double DEFUN(copysign, (x, y), double x AND double y)
+double
+copysign (x, y)
+ double x, y;
{
__ieee_double_shape_type a,b;
b.value = y;
@@ -142,7 +144,9 @@ double DEFUN(copysign, (x, y), double x AND double y)
#else
-double DEFUN(copysign, (x, y), double x AND double y)
+double
+copysign (x, y)
+ double x, y;
{
if ((x < 0 && y > 0) || (x > 0 && y < 0))
return -x;
diff --git a/contrib/binutils/libiberty/cp-demangle.c b/contrib/binutils/libiberty/cp-demangle.c
index eece533..19f191e 100644
--- a/contrib/binutils/libiberty/cp-demangle.c
+++ b/contrib/binutils/libiberty/cp-demangle.c
@@ -1,10 +1,10 @@
-/* Demangler for IA64 / g++ V3 ABI.
- Copyright (C) 2000, 2001, 2002 Free Software Foundation, Inc.
- Written by Alex Samuel <samuel@codesourcery.com>.
+/* Demangler for g++ V3 ABI.
+ Copyright (C) 2003, 2004 Free Software Foundation, Inc.
+ Written by Ian Lance Taylor <ian@wasabisystems.com>.
- This file is part of GNU CC.
+ This file is part of the libiberty library, which is part of GCC.
- This program is free software; you can redistribute it and/or modify
+ This file is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
@@ -28,3643 +28,3910 @@
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
-/* This file implements demangling of C++ names mangled according to
- the IA64 / g++ V3 ABI. Use the cp_demangle function to
- demangle a mangled name, or compile with the preprocessor macro
- STANDALONE_DEMANGLER defined to create a demangling filter
- executable (functionally similar to c++filt, but includes this
- demangler only). */
+/* This code implements a demangler for the g++ V3 ABI. The ABI is
+ described on this web page:
+ http://www.codesourcery.com/cxx-abi/abi.html#mangling
+
+ This code was written while looking at the demangler written by
+ Alex Samuel <samuel@codesourcery.com>.
+
+ This code first pulls the mangled name apart into a list of
+ components, and then walks the list generating the demangled
+ name.
+
+ This file will normally define the following functions, q.v.:
+ char *cplus_demangle_v3(const char *mangled, int options)
+ char *java_demangle_v3(const char *mangled)
+ enum gnu_v3_ctor_kinds is_gnu_v3_mangled_ctor (const char *name)
+ enum gnu_v3_dtor_kinds is_gnu_v3_mangled_dtor (const char *name)
+
+ Also, the interface to the component list is public, and defined in
+ demangle.h. The interface consists of these types, which are
+ defined in demangle.h:
+ enum demangle_component_type
+ struct demangle_component
+ and these functions defined in this file:
+ cplus_demangle_fill_name
+ cplus_demangle_fill_extended_operator
+ cplus_demangle_fill_ctor
+ cplus_demangle_fill_dtor
+ cplus_demangle_print
+ and other functions defined in the file cp-demint.c.
+
+ This file also defines some other functions and variables which are
+ only to be used by the file cp-demint.c.
+
+ Preprocessor macros you can define while compiling this file:
+
+ IN_LIBGCC2
+ If defined, this file defines the following function, q.v.:
+ char *__cxa_demangle (const char *mangled, char *buf, size_t *len,
+ int *status)
+ instead of cplus_demangle_v3() and java_demangle_v3().
+
+ IN_GLIBCPP_V3
+ If defined, this file defines only __cxa_demangle(), and no other
+ publically visible functions or variables.
+
+ STANDALONE_DEMANGLER
+ If defined, this file defines a main() function which demangles
+ any arguments, or, if none, demangles stdin.
+
+ CP_DEMANGLE_DEBUG
+ If defined, turns on debugging mode, which prints information on
+ stdout about the mangled string. This is not generally useful.
+*/
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
-#include <sys/types.h>
+#include <stdio.h>
#ifdef HAVE_STDLIB_H
#include <stdlib.h>
#endif
-
-#include <stdio.h>
-
#ifdef HAVE_STRING_H
#include <string.h>
#endif
-#include <ctype.h>
-
#include "ansidecl.h"
#include "libiberty.h"
-#include "dyn-string.h"
#include "demangle.h"
+#include "cp-demangle.h"
-/* If CP_DEMANGLE_DEBUG is defined, a trace of the grammar evaluation,
- and other debugging output, will be generated. */
-#ifdef CP_DEMANGLE_DEBUG
-#define DEMANGLE_TRACE(PRODUCTION, DM) \
- fprintf (stderr, " -> %-24s at position %3d\n", \
- (PRODUCTION), current_position (DM));
-#else
-#define DEMANGLE_TRACE(PRODUCTION, DM)
-#endif
+/* If IN_GLIBCPP_V3 is defined, some functions are made static. We
+ also rename them via #define to avoid compiler errors when the
+ static definition conflicts with the extern declaration in a header
+ file. */
+#ifdef IN_GLIBCPP_V3
-/* Don't include <ctype.h>, to prevent additional unresolved symbols
- from being dragged into the C++ runtime library. */
-#define IS_DIGIT(CHAR) ((CHAR) >= '0' && (CHAR) <= '9')
-#define IS_ALPHA(CHAR) \
- (((CHAR) >= 'a' && (CHAR) <= 'z') \
- || ((CHAR) >= 'A' && (CHAR) <= 'Z'))
+#define CP_STATIC_IF_GLIBCPP_V3 static
-/* The prefix prepended by GCC to an identifier represnting the
- anonymous namespace. */
-#define ANONYMOUS_NAMESPACE_PREFIX "_GLOBAL_"
+#define cplus_demangle_fill_name d_fill_name
+static int
+d_fill_name PARAMS ((struct demangle_component *, const char *, int));
-/* Character(s) to use for namespace separation in demangled output */
-#define NAMESPACE_SEPARATOR (dm->style == DMGL_JAVA ? "." : "::")
+#define cplus_demangle_fill_extended_operator d_fill_extended_operator
+static int
+d_fill_extended_operator PARAMS ((struct demangle_component *, int,
+ struct demangle_component *));
-/* If flag_verbose is zero, some simplifications will be made to the
- output to make it easier to read and supress details that are
- generally not of interest to the average C++ programmer.
- Otherwise, the demangled representation will attempt to convey as
- much information as the mangled form. */
-static int flag_verbose;
+#define cplus_demangle_fill_ctor d_fill_ctor
+static int
+d_fill_ctor PARAMS ((struct demangle_component *, enum gnu_v3_ctor_kinds,
+ struct demangle_component *));
-/* If flag_strict is non-zero, demangle strictly according to the
- specification -- don't demangle special g++ manglings. */
-static int flag_strict;
+#define cplus_demangle_fill_dtor d_fill_dtor
+static int
+d_fill_dtor PARAMS ((struct demangle_component *, enum gnu_v3_dtor_kinds,
+ struct demangle_component *));
-/* String_list_t is an extended form of dyn_string_t which provides a
- link field and a caret position for additions to the string. A
- string_list_t may safely be cast to and used as a dyn_string_t. */
+#define cplus_demangle_mangled_name d_mangled_name
+static struct demangle_component *
+d_mangled_name PARAMS ((struct d_info *, int));
-struct string_list_def
-{
- /* The dyn_string; must be first. */
- struct dyn_string string;
+#define cplus_demangle_type d_type
+static struct demangle_component *
+d_type PARAMS ((struct d_info *));
- /* The position at which additional text is added to this string
- (using the result_add* macros). This value is an offset from the
- end of the string, not the beginning (and should be
- non-positive). */
- int caret_position;
+#define cplus_demangle_print d_print
+static char *
+d_print PARAMS ((int, const struct demangle_component *, int, size_t *));
- /* The next string in the list. */
- struct string_list_def *next;
-};
+#define cplus_demangle_init_info d_init_info
+static void
+d_init_info PARAMS ((const char *, int, size_t, struct d_info *));
+
+#else /* ! defined(IN_GLIBCPP_V3) */
+#define CP_STATIC_IF_GLIBCPP_V3
+#endif /* ! defined(IN_GLIBCPP_V3) */
+
+/* See if the compiler supports dynamic arrays. */
-typedef struct string_list_def *string_list_t;
+#ifdef __GNUC__
+#define CP_DYNAMIC_ARRAYS
+#else
+#ifdef __STDC__
+#ifdef __STDC_VERSION__
+#if __STDC_VERSION__ >= 199901L
+#define CP_DYNAMIC_ARRAYS
+#endif /* __STDC__VERSION >= 199901L */
+#endif /* defined (__STDC_VERSION__) */
+#endif /* defined (__STDC__) */
+#endif /* ! defined (__GNUC__) */
+
+/* We avoid pulling in the ctype tables, to prevent pulling in
+ additional unresolved symbols when this code is used in a library.
+ FIXME: Is this really a valid reason? This comes from the original
+ V3 demangler code.
+
+ As of this writing this file has the following undefined references
+ when compiled with -DIN_GLIBCPP_V3: malloc, realloc, free, memcpy,
+ strcpy, strcat, strlen. */
+
+#define IS_DIGIT(c) ((c) >= '0' && (c) <= '9')
+#define IS_UPPER(c) ((c) >= 'A' && (c) <= 'Z')
+#define IS_LOWER(c) ((c) >= 'a' && (c) <= 'z')
+
+/* The prefix prepended by GCC to an identifier represnting the
+ anonymous namespace. */
+#define ANONYMOUS_NAMESPACE_PREFIX "_GLOBAL_"
+#define ANONYMOUS_NAMESPACE_PREFIX_LEN \
+ (sizeof (ANONYMOUS_NAMESPACE_PREFIX) - 1)
-/* Data structure representing a potential substitution. */
+/* Information we keep for the standard substitutions. */
-struct substitution_def
+struct d_standard_sub_info
{
- /* The demangled text of the substitution. */
- dyn_string_t text;
+ /* The code for this substitution. */
+ char code;
+ /* The simple string it expands to. */
+ const char *simple_expansion;
+ /* The length of the simple expansion. */
+ int simple_len;
+ /* The results of a full, verbose, expansion. This is used when
+ qualifying a constructor/destructor, or when in verbose mode. */
+ const char *full_expansion;
+ /* The length of the full expansion. */
+ int full_len;
+ /* What to set the last_name field of d_info to; NULL if we should
+ not set it. This is only relevant when qualifying a
+ constructor/destructor. */
+ const char *set_last_name;
+ /* The length of set_last_name. */
+ int set_last_name_len;
+};
+
+/* Accessors for subtrees of struct demangle_component. */
+
+#define d_left(dc) ((dc)->u.s_binary.left)
+#define d_right(dc) ((dc)->u.s_binary.right)
- /* Whether this substitution represents a template item. */
- int template_p : 1;
+/* A list of templates. This is used while printing. */
+
+struct d_print_template
+{
+ /* Next template on the list. */
+ struct d_print_template *next;
+ /* This template. */
+ const struct demangle_component *template;
};
-/* Data structure representing a template argument list. */
+/* A list of type modifiers. This is used while printing. */
-struct template_arg_list_def
+struct d_print_mod
{
- /* The next (lower) template argument list in the stack of currently
- active template arguments. */
- struct template_arg_list_def *next;
+ /* Next modifier on the list. These are in the reverse of the order
+ in which they appeared in the mangled string. */
+ struct d_print_mod *next;
+ /* The modifier. */
+ const struct demangle_component *mod;
+ /* Whether this modifier was printed. */
+ int printed;
+ /* The list of templates which applies to this modifier. */
+ struct d_print_template *templates;
+};
- /* The first element in the list of template arguments in
- left-to-right order. */
- string_list_t first_argument;
+/* We use this structure to hold information during printing. */
- /* The last element in the arguments lists. */
- string_list_t last_argument;
+struct d_print_info
+{
+ /* The options passed to the demangler. */
+ int options;
+ /* Buffer holding the result. */
+ char *buf;
+ /* Current length of data in buffer. */
+ size_t len;
+ /* Allocated size of buffer. */
+ size_t alc;
+ /* The current list of templates, if any. */
+ struct d_print_template *templates;
+ /* The current list of modifiers (e.g., pointer, reference, etc.),
+ if any. */
+ struct d_print_mod *modifiers;
+ /* Set to 1 if we had a memory allocation failure. */
+ int allocation_failure;
};
-typedef struct template_arg_list_def *template_arg_list_t;
+#define d_print_saw_error(dpi) ((dpi)->buf == NULL)
-/* Data structure to maintain the state of the current demangling. */
+#define d_append_char(dpi, c) \
+ do \
+ { \
+ if ((dpi)->buf != NULL && (dpi)->len < (dpi)->alc) \
+ (dpi)->buf[(dpi)->len++] = (c); \
+ else \
+ d_print_append_char ((dpi), (c)); \
+ } \
+ while (0)
-struct demangling_def
-{
- /* The full mangled name being mangled. */
- const char *name;
+#define d_append_buffer(dpi, s, l) \
+ do \
+ { \
+ if ((dpi)->buf != NULL && (dpi)->len + (l) <= (dpi)->alc) \
+ { \
+ memcpy ((dpi)->buf + (dpi)->len, (s), (l)); \
+ (dpi)->len += l; \
+ } \
+ else \
+ d_print_append_buffer ((dpi), (s), (l)); \
+ } \
+ while (0)
- /* Pointer into name at the current position. */
- const char *next;
+#define d_append_string_constant(dpi, s) \
+ d_append_buffer (dpi, (s), sizeof (s) - 1)
- /* Stack for strings containing demangled result generated so far.
- Text is emitted to the topmost (first) string. */
- string_list_t result;
+#define d_last_char(dpi) \
+ ((dpi)->buf == NULL || (dpi)->len == 0 ? '\0' : (dpi)->buf[(dpi)->len - 1])
- /* The number of presently available substitutions. */
- int num_substitutions;
+#ifdef CP_DEMANGLE_DEBUG
+static void
+d_dump PARAMS ((struct demangle_component *, int));
+#endif
- /* The allocated size of the substitutions array. */
- int substitutions_allocated;
+static struct demangle_component *
+d_make_empty PARAMS ((struct d_info *));
- /* An array of available substitutions. The number of elements in
- the array is given by num_substitions, and the allocated array
- size in substitutions_size.
+static struct demangle_component *
+d_make_comp PARAMS ((struct d_info *, enum demangle_component_type,
+ struct demangle_component *,
+ struct demangle_component *));
- The most recent substition is at the end, so
+static struct demangle_component *
+d_make_name PARAMS ((struct d_info *, const char *, int));
- - `S_' corresponds to substititutions[num_substitutions - 1]
- - `S0_' corresponds to substititutions[num_substitutions - 2]
+static struct demangle_component *
+d_make_builtin_type PARAMS ((struct d_info *,
+ const struct demangle_builtin_type_info *));
- etc. */
- struct substitution_def *substitutions;
+static struct demangle_component *
+d_make_operator PARAMS ((struct d_info *,
+ const struct demangle_operator_info *));
- /* The stack of template argument lists. */
- template_arg_list_t template_arg_lists;
+static struct demangle_component *
+d_make_extended_operator PARAMS ((struct d_info *, int,
+ struct demangle_component *));
- /* The most recently demangled source-name. */
- dyn_string_t last_source_name;
-
- /* Language style to use for demangled output. */
- int style;
+static struct demangle_component *
+d_make_ctor PARAMS ((struct d_info *, enum gnu_v3_ctor_kinds,
+ struct demangle_component *));
- /* Set to non-zero iff this name is a constructor. The actual value
- indicates what sort of constructor this is; see demangle.h. */
- enum gnu_v3_ctor_kinds is_constructor;
+static struct demangle_component *
+d_make_dtor PARAMS ((struct d_info *, enum gnu_v3_dtor_kinds,
+ struct demangle_component *));
- /* Set to non-zero iff this name is a destructor. The actual value
- indicates what sort of destructor this is; see demangle.h. */
- enum gnu_v3_dtor_kinds is_destructor;
+static struct demangle_component *
+d_make_template_param PARAMS ((struct d_info *, long));
-};
+static struct demangle_component *
+d_make_sub PARAMS ((struct d_info *, const char *, int));
-typedef struct demangling_def *demangling_t;
-
-/* This type is the standard return code from most functions. Values
- other than STATUS_OK contain descriptive messages. */
-typedef const char *status_t;
-
-/* Special values that can be used as a status_t. */
-#define STATUS_OK NULL
-#define STATUS_ERROR "Error."
-#define STATUS_UNIMPLEMENTED "Unimplemented."
-#define STATUS_INTERNAL_ERROR "Internal error."
-
-/* This status code indicates a failure in malloc or realloc. */
-static const char *const status_allocation_failed = "Allocation failed.";
-#define STATUS_ALLOCATION_FAILED status_allocation_failed
-
-/* Non-zero if STATUS indicates that no error has occurred. */
-#define STATUS_NO_ERROR(STATUS) ((STATUS) == STATUS_OK)
-
-/* Evaluate EXPR, which must produce a status_t. If the status code
- indicates an error, return from the current function with that
- status code. */
-#define RETURN_IF_ERROR(EXPR) \
- do \
- { \
- status_t s = EXPR; \
- if (!STATUS_NO_ERROR (s)) \
- return s; \
- } \
- while (0)
+static int
+has_return_type PARAMS ((struct demangle_component *));
-static status_t int_to_dyn_string
- PARAMS ((int, dyn_string_t));
-static string_list_t string_list_new
- PARAMS ((int));
-static void string_list_delete
- PARAMS ((string_list_t));
-static status_t result_add_separated_char
- PARAMS ((demangling_t, int));
-static status_t result_push
- PARAMS ((demangling_t));
-static string_list_t result_pop
- PARAMS ((demangling_t));
-static int substitution_start
- PARAMS ((demangling_t));
-static status_t substitution_add
- PARAMS ((demangling_t, int, int));
-static dyn_string_t substitution_get
- PARAMS ((demangling_t, int, int *));
-#ifdef CP_DEMANGLE_DEBUG
-static void substitutions_print
- PARAMS ((demangling_t, FILE *));
-#endif
-static template_arg_list_t template_arg_list_new
- PARAMS ((void));
-static void template_arg_list_delete
- PARAMS ((template_arg_list_t));
-static void template_arg_list_add_arg
- PARAMS ((template_arg_list_t, string_list_t));
-static string_list_t template_arg_list_get_arg
- PARAMS ((template_arg_list_t, int));
-static void push_template_arg_list
- PARAMS ((demangling_t, template_arg_list_t));
-static void pop_to_template_arg_list
- PARAMS ((demangling_t, template_arg_list_t));
-#ifdef CP_DEMANGLE_DEBUG
-static void template_arg_list_print
- PARAMS ((template_arg_list_t, FILE *));
-#endif
-static template_arg_list_t current_template_arg_list
- PARAMS ((demangling_t));
-static demangling_t demangling_new
- PARAMS ((const char *, int));
-static void demangling_delete
- PARAMS ((demangling_t));
-
-/* The last character of DS. Warning: DS is evaluated twice. */
-#define dyn_string_last_char(DS) \
- (dyn_string_buf (DS)[dyn_string_length (DS) - 1])
-
-/* Append a space character (` ') to DS if it does not already end
- with one. Evaluates to 1 on success, or 0 on allocation failure. */
-#define dyn_string_append_space(DS) \
- ((dyn_string_length (DS) > 0 \
- && dyn_string_last_char (DS) != ' ') \
- ? dyn_string_append_char ((DS), ' ') \
- : 1)
-
-/* Returns the index of the current position in the mangled name. */
-#define current_position(DM) ((DM)->next - (DM)->name)
-
-/* Returns the character at the current position of the mangled name. */
-#define peek_char(DM) (*((DM)->next))
-
-/* Returns the character one past the current position of the mangled
- name. */
-#define peek_char_next(DM) \
- (peek_char (DM) == '\0' ? '\0' : (*((DM)->next + 1)))
-
-/* Returns the character at the current position, and advances the
- current position to the next character. */
-#define next_char(DM) (*((DM)->next)++)
-
-/* Returns non-zero if the current position is the end of the mangled
- name, i.e. one past the last character. */
-#define end_of_name_p(DM) (peek_char (DM) == '\0')
-
-/* Advances the current position by one character. */
-#define advance_char(DM) (++(DM)->next)
-
-/* Returns the string containing the current demangled result. */
-#define result_string(DM) (&(DM)->result->string)
-
-/* Returns the position at which new text is inserted into the
- demangled result. */
-#define result_caret_pos(DM) \
- (result_length (DM) + \
- ((string_list_t) result_string (DM))->caret_position)
-
-/* Adds a dyn_string_t to the demangled result. */
-#define result_add_string(DM, STRING) \
- (dyn_string_insert (&(DM)->result->string, \
- result_caret_pos (DM), (STRING)) \
- ? STATUS_OK : STATUS_ALLOCATION_FAILED)
-
-/* Adds NUL-terminated string CSTR to the demangled result. */
-#define result_add(DM, CSTR) \
- (dyn_string_insert_cstr (&(DM)->result->string, \
- result_caret_pos (DM), (CSTR)) \
- ? STATUS_OK : STATUS_ALLOCATION_FAILED)
-
-/* Adds character CHAR to the demangled result. */
-#define result_add_char(DM, CHAR) \
- (dyn_string_insert_char (&(DM)->result->string, \
- result_caret_pos (DM), (CHAR)) \
- ? STATUS_OK : STATUS_ALLOCATION_FAILED)
-
-/* Inserts a dyn_string_t to the demangled result at position POS. */
-#define result_insert_string(DM, POS, STRING) \
- (dyn_string_insert (&(DM)->result->string, (POS), (STRING)) \
- ? STATUS_OK : STATUS_ALLOCATION_FAILED)
-
-/* Inserts NUL-terminated string CSTR to the demangled result at
- position POS. */
-#define result_insert(DM, POS, CSTR) \
- (dyn_string_insert_cstr (&(DM)->result->string, (POS), (CSTR)) \
- ? STATUS_OK : STATUS_ALLOCATION_FAILED)
-
-/* Inserts character CHAR to the demangled result at position POS. */
-#define result_insert_char(DM, POS, CHAR) \
- (dyn_string_insert_char (&(DM)->result->string, (POS), (CHAR)) \
- ? STATUS_OK : STATUS_ALLOCATION_FAILED)
-
-/* The length of the current demangled result. */
-#define result_length(DM) \
- dyn_string_length (&(DM)->result->string)
-
-/* Appends a (less-than, greater-than) character to the result in DM
- to (open, close) a template argument or parameter list. Appends a
- space first if necessary to prevent spurious elision of angle
- brackets with the previous character. */
-#define result_open_template_list(DM) result_add_separated_char(DM, '<')
-#define result_close_template_list(DM) result_add_separated_char(DM, '>')
-
-/* Appends a base 10 representation of VALUE to DS. STATUS_OK on
- success. On failure, deletes DS and returns an error code. */
-
-static status_t
-int_to_dyn_string (value, ds)
- int value;
- dyn_string_t ds;
-{
- int i;
- int mask = 1;
+static int
+is_ctor_dtor_or_conversion PARAMS ((struct demangle_component *));
- /* Handle zero up front. */
- if (value == 0)
- {
- if (!dyn_string_append_char (ds, '0'))
- return STATUS_ALLOCATION_FAILED;
- return STATUS_OK;
- }
+static struct demangle_component *
+d_encoding PARAMS ((struct d_info *, int));
- /* For negative numbers, emit a minus sign. */
- if (value < 0)
- {
- if (!dyn_string_append_char (ds, '-'))
- return STATUS_ALLOCATION_FAILED;
- value = -value;
- }
-
- /* Find the power of 10 of the first digit. */
- i = value;
- while (i > 9)
- {
- mask *= 10;
- i /= 10;
- }
+static struct demangle_component *
+d_name PARAMS ((struct d_info *));
- /* Write the digits. */
- while (mask > 0)
- {
- int digit = value / mask;
+static struct demangle_component *
+d_nested_name PARAMS ((struct d_info *));
- if (!dyn_string_append_char (ds, '0' + digit))
- return STATUS_ALLOCATION_FAILED;
+static struct demangle_component *
+d_prefix PARAMS ((struct d_info *));
- value -= digit * mask;
- mask /= 10;
- }
+static struct demangle_component *
+d_unqualified_name PARAMS ((struct d_info *));
- return STATUS_OK;
-}
+static struct demangle_component *
+d_source_name PARAMS ((struct d_info *));
-/* Creates a new string list node. The contents of the string are
- empty, but the initial buffer allocation is LENGTH. The string
- list node should be deleted with string_list_delete. Returns NULL
- if allocation fails. */
+static long
+d_number PARAMS ((struct d_info *));
-static string_list_t
-string_list_new (length)
- int length;
-{
- string_list_t s = (string_list_t) malloc (sizeof (struct string_list_def));
- s->caret_position = 0;
- if (s == NULL)
- return NULL;
- if (!dyn_string_init ((dyn_string_t) s, length))
- return NULL;
- return s;
-}
+static struct demangle_component *
+d_identifier PARAMS ((struct d_info *, int));
-/* Deletes the entire string list starting at NODE. */
+static struct demangle_component *
+d_operator_name PARAMS ((struct d_info *));
-static void
-string_list_delete (node)
- string_list_t node;
-{
- while (node != NULL)
- {
- string_list_t next = node->next;
- dyn_string_delete ((dyn_string_t) node);
- node = next;
- }
-}
+static struct demangle_component *
+d_special_name PARAMS ((struct d_info *));
-/* Appends CHARACTER to the demangled result. If the current trailing
- character of the result is CHARACTER, a space is inserted first. */
+static int
+d_call_offset PARAMS ((struct d_info *, int));
-static status_t
-result_add_separated_char (dm, character)
- demangling_t dm;
- int character;
-{
- char *result = dyn_string_buf (result_string (dm));
- int caret_pos = result_caret_pos (dm);
+static struct demangle_component *
+d_ctor_dtor_name PARAMS ((struct d_info *));
- /* Add a space if the last character is already the character we
- want to add. */
- if (caret_pos > 0 && result[caret_pos - 1] == character)
- RETURN_IF_ERROR (result_add_char (dm, ' '));
- /* Add the character. */
- RETURN_IF_ERROR (result_add_char (dm, character));
+static struct demangle_component **
+d_cv_qualifiers PARAMS ((struct d_info *, struct demangle_component **, int));
- return STATUS_OK;
-}
+static struct demangle_component *
+d_function_type PARAMS ((struct d_info *));
-/* Allocates and pushes a new string onto the demangled results stack
- for DM. Subsequent demangling with DM will emit to the new string.
- Returns STATUS_OK on success, STATUS_ALLOCATION_FAILED on
- allocation failure. */
+static struct demangle_component *
+d_bare_function_type PARAMS ((struct d_info *, int));
-static status_t
-result_push (dm)
- demangling_t dm;
-{
- string_list_t new_string = string_list_new (0);
- if (new_string == NULL)
- /* Allocation failed. */
- return STATUS_ALLOCATION_FAILED;
-
- /* Link the new string to the front of the list of result strings. */
- new_string->next = (string_list_t) dm->result;
- dm->result = new_string;
- return STATUS_OK;
-}
+static struct demangle_component *
+d_class_enum_type PARAMS ((struct d_info *));
-/* Removes and returns the topmost element on the demangled results
- stack for DM. The caller assumes ownership for the returned
- string. */
+static struct demangle_component *
+d_array_type PARAMS ((struct d_info *));
-static string_list_t
-result_pop (dm)
- demangling_t dm;
-{
- string_list_t top = dm->result;
- dm->result = top->next;
- return top;
-}
+static struct demangle_component *
+d_pointer_to_member_type PARAMS ((struct d_info *));
-/* Returns the current value of the caret for the result string. The
- value is an offet from the end of the result string. */
+static struct demangle_component *
+d_template_param PARAMS ((struct d_info *));
-static int
-result_get_caret (dm)
- demangling_t dm;
-{
- return ((string_list_t) result_string (dm))->caret_position;
-}
+static struct demangle_component *
+d_template_args PARAMS ((struct d_info *));
-/* Sets the value of the caret for the result string, counted as an
- offet from the end of the result string. */
+static struct demangle_component *
+d_template_arg PARAMS ((struct d_info *));
-static void
-result_set_caret (dm, position)
- demangling_t dm;
- int position;
-{
- ((string_list_t) result_string (dm))->caret_position = position;
-}
+static struct demangle_component *
+d_expression PARAMS ((struct d_info *));
-/* Shifts the position of the next addition to the result by
- POSITION_OFFSET. A negative value shifts the caret to the left. */
+static struct demangle_component *
+d_expr_primary PARAMS ((struct d_info *));
-static void
-result_shift_caret (dm, position_offset)
- demangling_t dm;
- int position_offset;
-{
- ((string_list_t) result_string (dm))->caret_position += position_offset;
-}
+static struct demangle_component *
+d_local_name PARAMS ((struct d_info *));
-/* Returns non-zero if the character that comes right before the place
- where text will be added to the result is a space. In this case,
- the caller should supress adding another space. */
+static int
+d_discriminator PARAMS ((struct d_info *));
static int
-result_previous_char_is_space (dm)
- demangling_t dm;
-{
- char *result = dyn_string_buf (result_string (dm));
- int pos = result_caret_pos (dm);
- return pos > 0 && result[pos - 1] == ' ';
-}
+d_add_substitution PARAMS ((struct d_info *, struct demangle_component *));
-/* Returns the start position of a fragment of the demangled result
- that will be a substitution candidate. Should be called at the
- start of productions that can add substitutions. */
+static struct demangle_component *
+d_substitution PARAMS ((struct d_info *, int));
-static int
-substitution_start (dm)
- demangling_t dm;
-{
- return result_caret_pos (dm);
-}
+static void
+d_print_resize PARAMS ((struct d_print_info *, size_t));
-/* Adds the suffix of the current demangled result of DM starting at
- START_POSITION as a potential substitution. If TEMPLATE_P is
- non-zero, this potential substitution is a template-id. */
+static void
+d_print_append_char PARAMS ((struct d_print_info *, int));
-static status_t
-substitution_add (dm, start_position, template_p)
- demangling_t dm;
- int start_position;
- int template_p;
-{
- dyn_string_t result = result_string (dm);
- dyn_string_t substitution = dyn_string_new (0);
- int i;
+static void
+d_print_append_buffer PARAMS ((struct d_print_info *, const char *, size_t));
- if (substitution == NULL)
- return STATUS_ALLOCATION_FAILED;
+static void
+d_print_error PARAMS ((struct d_print_info *));
- /* Extract the substring of the current demangling result that
- represents the subsitution candidate. */
- if (!dyn_string_substring (substitution,
- result, start_position, result_caret_pos (dm)))
- {
- dyn_string_delete (substitution);
- return STATUS_ALLOCATION_FAILED;
- }
+static void
+d_print_comp PARAMS ((struct d_print_info *,
+ const struct demangle_component *));
- /* If there's no room for the new entry, grow the array. */
- if (dm->substitutions_allocated == dm->num_substitutions)
- {
- size_t new_array_size;
- if (dm->substitutions_allocated > 0)
- dm->substitutions_allocated *= 2;
- else
- dm->substitutions_allocated = 2;
- new_array_size =
- sizeof (struct substitution_def) * dm->substitutions_allocated;
-
- dm->substitutions = (struct substitution_def *)
- realloc (dm->substitutions, new_array_size);
- if (dm->substitutions == NULL)
- /* Realloc failed. */
- {
- dyn_string_delete (substitution);
- return STATUS_ALLOCATION_FAILED;
- }
- }
+static void
+d_print_java_identifier PARAMS ((struct d_print_info *, const char *, int));
- /* Add the substitution to the array. */
- i = dm->num_substitutions++;
- dm->substitutions[i].text = substitution;
- dm->substitutions[i].template_p = template_p;
+static void
+d_print_mod_list PARAMS ((struct d_print_info *, struct d_print_mod *, int));
-#ifdef CP_DEMANGLE_DEBUG
- substitutions_print (dm, stderr);
-#endif
+static void
+d_print_mod PARAMS ((struct d_print_info *,
+ const struct demangle_component *));
- return STATUS_OK;
-}
+static void
+d_print_function_type PARAMS ((struct d_print_info *,
+ const struct demangle_component *,
+ struct d_print_mod *));
-/* Returns the Nth-most-recent substitution. Sets *TEMPLATE_P to
- non-zero if the substitution is a template-id, zero otherwise.
- N is numbered from zero. DM retains ownership of the returned
- string. If N is negative, or equal to or greater than the current
- number of substitution candidates, returns NULL. */
-
-static dyn_string_t
-substitution_get (dm, n, template_p)
- demangling_t dm;
- int n;
- int *template_p;
-{
- struct substitution_def *sub;
+static void
+d_print_array_type PARAMS ((struct d_print_info *,
+ const struct demangle_component *,
+ struct d_print_mod *));
- /* Make sure N is in the valid range. */
- if (n < 0 || n >= dm->num_substitutions)
- return NULL;
+static void
+d_print_expr_op PARAMS ((struct d_print_info *,
+ const struct demangle_component *));
- sub = &(dm->substitutions[n]);
- *template_p = sub->template_p;
- return sub->text;
-}
+static void
+d_print_cast PARAMS ((struct d_print_info *,
+ const struct demangle_component *));
+
+static char *
+d_demangle PARAMS ((const char *, int, size_t *));
#ifdef CP_DEMANGLE_DEBUG
-/* Debugging routine to print the current substitutions to FP. */
static void
-substitutions_print (dm, fp)
- demangling_t dm;
- FILE *fp;
+d_dump (dc, indent)
+ struct demangle_component *dc;
+ int indent;
{
- int seq_id;
- int num = dm->num_substitutions;
+ int i;
- fprintf (fp, "SUBSTITUTIONS:\n");
- for (seq_id = -1; seq_id < num - 1; ++seq_id)
- {
- int template_p;
- dyn_string_t text = substitution_get (dm, seq_id + 1, &template_p);
+ if (dc == NULL)
+ return;
- if (seq_id == -1)
- fprintf (fp, " S_ ");
- else
- fprintf (fp, " S%d_", seq_id);
- fprintf (fp, " %c: %s\n", template_p ? '*' : ' ', dyn_string_buf (text));
+ for (i = 0; i < indent; ++i)
+ putchar (' ');
+
+ switch (dc->type)
+ {
+ case DEMANGLE_COMPONENT_NAME:
+ printf ("name '%.*s'\n", dc->u.s_name.len, dc->u.s_name.s);
+ return;
+ case DEMANGLE_COMPONENT_TEMPLATE_PARAM:
+ printf ("template parameter %ld\n", dc->u.s_number.number);
+ return;
+ case DEMANGLE_COMPONENT_CTOR:
+ printf ("constructor %d\n", (int) dc->u.s_ctor.kind);
+ d_dump (dc->u.s_ctor.name, indent + 2);
+ return;
+ case DEMANGLE_COMPONENT_DTOR:
+ printf ("destructor %d\n", (int) dc->u.s_dtor.kind);
+ d_dump (dc->u.s_dtor.name, indent + 2);
+ return;
+ case DEMANGLE_COMPONENT_SUB_STD:
+ printf ("standard substitution %s\n", dc->u.s_string.string);
+ return;
+ case DEMANGLE_COMPONENT_BUILTIN_TYPE:
+ printf ("builtin type %s\n", dc->u.s_builtin.type->name);
+ return;
+ case DEMANGLE_COMPONENT_OPERATOR:
+ printf ("operator %s\n", dc->u.s_operator.op->name);
+ return;
+ case DEMANGLE_COMPONENT_EXTENDED_OPERATOR:
+ printf ("extended operator with %d args\n",
+ dc->u.s_extended_operator.args);
+ d_dump (dc->u.s_extended_operator.name, indent + 2);
+ return;
+
+ case DEMANGLE_COMPONENT_QUAL_NAME:
+ printf ("qualified name\n");
+ break;
+ case DEMANGLE_COMPONENT_LOCAL_NAME:
+ printf ("local name\n");
+ break;
+ case DEMANGLE_COMPONENT_TYPED_NAME:
+ printf ("typed name\n");
+ break;
+ case DEMANGLE_COMPONENT_TEMPLATE:
+ printf ("template\n");
+ break;
+ case DEMANGLE_COMPONENT_VTABLE:
+ printf ("vtable\n");
+ break;
+ case DEMANGLE_COMPONENT_VTT:
+ printf ("VTT\n");
+ break;
+ case DEMANGLE_COMPONENT_CONSTRUCTION_VTABLE:
+ printf ("construction vtable\n");
+ break;
+ case DEMANGLE_COMPONENT_TYPEINFO:
+ printf ("typeinfo\n");
+ break;
+ case DEMANGLE_COMPONENT_TYPEINFO_NAME:
+ printf ("typeinfo name\n");
+ break;
+ case DEMANGLE_COMPONENT_TYPEINFO_FN:
+ printf ("typeinfo function\n");
+ break;
+ case DEMANGLE_COMPONENT_THUNK:
+ printf ("thunk\n");
+ break;
+ case DEMANGLE_COMPONENT_VIRTUAL_THUNK:
+ printf ("virtual thunk\n");
+ break;
+ case DEMANGLE_COMPONENT_COVARIANT_THUNK:
+ printf ("covariant thunk\n");
+ break;
+ case DEMANGLE_COMPONENT_JAVA_CLASS:
+ printf ("java class\n");
+ break;
+ case DEMANGLE_COMPONENT_GUARD:
+ printf ("guard\n");
+ break;
+ case DEMANGLE_COMPONENT_REFTEMP:
+ printf ("reference temporary\n");
+ break;
+ case DEMANGLE_COMPONENT_RESTRICT:
+ printf ("restrict\n");
+ break;
+ case DEMANGLE_COMPONENT_VOLATILE:
+ printf ("volatile\n");
+ break;
+ case DEMANGLE_COMPONENT_CONST:
+ printf ("const\n");
+ break;
+ case DEMANGLE_COMPONENT_RESTRICT_THIS:
+ printf ("restrict this\n");
+ break;
+ case DEMANGLE_COMPONENT_VOLATILE_THIS:
+ printf ("volatile this\n");
+ break;
+ case DEMANGLE_COMPONENT_CONST_THIS:
+ printf ("const this\n");
+ break;
+ case DEMANGLE_COMPONENT_VENDOR_TYPE_QUAL:
+ printf ("vendor type qualifier\n");
+ break;
+ case DEMANGLE_COMPONENT_POINTER:
+ printf ("pointer\n");
+ break;
+ case DEMANGLE_COMPONENT_REFERENCE:
+ printf ("reference\n");
+ break;
+ case DEMANGLE_COMPONENT_COMPLEX:
+ printf ("complex\n");
+ break;
+ case DEMANGLE_COMPONENT_IMAGINARY:
+ printf ("imaginary\n");
+ break;
+ case DEMANGLE_COMPONENT_VENDOR_TYPE:
+ printf ("vendor type\n");
+ break;
+ case DEMANGLE_COMPONENT_FUNCTION_TYPE:
+ printf ("function type\n");
+ break;
+ case DEMANGLE_COMPONENT_ARRAY_TYPE:
+ printf ("array type\n");
+ break;
+ case DEMANGLE_COMPONENT_PTRMEM_TYPE:
+ printf ("pointer to member type\n");
+ break;
+ case DEMANGLE_COMPONENT_ARGLIST:
+ printf ("argument list\n");
+ break;
+ case DEMANGLE_COMPONENT_TEMPLATE_ARGLIST:
+ printf ("template argument list\n");
+ break;
+ case DEMANGLE_COMPONENT_CAST:
+ printf ("cast\n");
+ break;
+ case DEMANGLE_COMPONENT_UNARY:
+ printf ("unary operator\n");
+ break;
+ case DEMANGLE_COMPONENT_BINARY:
+ printf ("binary operator\n");
+ break;
+ case DEMANGLE_COMPONENT_BINARY_ARGS:
+ printf ("binary operator arguments\n");
+ break;
+ case DEMANGLE_COMPONENT_TRINARY:
+ printf ("trinary operator\n");
+ break;
+ case DEMANGLE_COMPONENT_TRINARY_ARG1:
+ printf ("trinary operator arguments 1\n");
+ break;
+ case DEMANGLE_COMPONENT_TRINARY_ARG2:
+ printf ("trinary operator arguments 1\n");
+ break;
+ case DEMANGLE_COMPONENT_LITERAL:
+ printf ("literal\n");
+ break;
+ case DEMANGLE_COMPONENT_LITERAL_NEG:
+ printf ("negative literal\n");
+ break;
}
+
+ d_dump (d_left (dc), indent + 2);
+ d_dump (d_right (dc), indent + 2);
}
#endif /* CP_DEMANGLE_DEBUG */
-/* Creates a new template argument list. Returns NULL if allocation
- fails. */
+/* Fill in a DEMANGLE_COMPONENT_NAME. */
-static template_arg_list_t
-template_arg_list_new ()
+CP_STATIC_IF_GLIBCPP_V3
+int
+cplus_demangle_fill_name (p, s, len)
+ struct demangle_component *p;
+ const char *s;
+ int len;
{
- template_arg_list_t new_list =
- (template_arg_list_t) malloc (sizeof (struct template_arg_list_def));
- if (new_list == NULL)
- return NULL;
- /* Initialize the new list to have no arguments. */
- new_list->first_argument = NULL;
- new_list->last_argument = NULL;
- /* Return the new list. */
- return new_list;
+ if (p == NULL || s == NULL || len == 0)
+ return 0;
+ p->type = DEMANGLE_COMPONENT_NAME;
+ p->u.s_name.s = s;
+ p->u.s_name.len = len;
+ return 1;
}
-/* Deletes a template argument list and the template arguments it
- contains. */
+/* Fill in a DEMANGLE_COMPONENT_EXTENDED_OPERATOR. */
-static void
-template_arg_list_delete (list)
- template_arg_list_t list;
+CP_STATIC_IF_GLIBCPP_V3
+int
+cplus_demangle_fill_extended_operator (p, args, name)
+ struct demangle_component *p;
+ int args;
+ struct demangle_component *name;
{
- /* If there are any arguments on LIST, delete them. */
- if (list->first_argument != NULL)
- string_list_delete (list->first_argument);
- /* Delete LIST. */
- free (list);
+ if (p == NULL || args < 0 || name == NULL)
+ return 0;
+ p->type = DEMANGLE_COMPONENT_EXTENDED_OPERATOR;
+ p->u.s_extended_operator.args = args;
+ p->u.s_extended_operator.name = name;
+ return 1;
}
-/* Adds ARG to the template argument list ARG_LIST. */
+/* Fill in a DEMANGLE_COMPONENT_CTOR. */
-static void
-template_arg_list_add_arg (arg_list, arg)
- template_arg_list_t arg_list;
- string_list_t arg;
+CP_STATIC_IF_GLIBCPP_V3
+int
+cplus_demangle_fill_ctor (p, kind, name)
+ struct demangle_component *p;
+ enum gnu_v3_ctor_kinds kind;
+ struct demangle_component *name;
{
- if (arg_list->first_argument == NULL)
- /* If there were no arguments before, ARG is the first one. */
- arg_list->first_argument = arg;
- else
- /* Make ARG the last argument on the list. */
- arg_list->last_argument->next = arg;
- /* Make ARG the last on the list. */
- arg_list->last_argument = arg;
- arg->next = NULL;
+ if (p == NULL
+ || name == NULL
+ || (kind < gnu_v3_complete_object_ctor
+ && kind > gnu_v3_complete_object_allocating_ctor))
+ return 0;
+ p->type = DEMANGLE_COMPONENT_CTOR;
+ p->u.s_ctor.kind = kind;
+ p->u.s_ctor.name = name;
+ return 1;
+}
+
+/* Fill in a DEMANGLE_COMPONENT_DTOR. */
+
+CP_STATIC_IF_GLIBCPP_V3
+int
+cplus_demangle_fill_dtor (p, kind, name)
+ struct demangle_component *p;
+ enum gnu_v3_dtor_kinds kind;
+ struct demangle_component *name;
+{
+ if (p == NULL
+ || name == NULL
+ || (kind < gnu_v3_deleting_dtor
+ && kind > gnu_v3_base_object_dtor))
+ return 0;
+ p->type = DEMANGLE_COMPONENT_DTOR;
+ p->u.s_dtor.kind = kind;
+ p->u.s_dtor.name = name;
+ return 1;
}
-/* Returns the template arugment at position INDEX in template
- argument list ARG_LIST. */
+/* Add a new component. */
-static string_list_t
-template_arg_list_get_arg (arg_list, index)
- template_arg_list_t arg_list;
- int index;
+static struct demangle_component *
+d_make_empty (di)
+ struct d_info *di;
{
- string_list_t arg = arg_list->first_argument;
- /* Scan down the list of arguments to find the one at position
- INDEX. */
- while (index--)
+ struct demangle_component *p;
+
+ if (di->next_comp >= di->num_comps)
+ return NULL;
+ p = &di->comps[di->next_comp];
+ ++di->next_comp;
+ return p;
+}
+
+/* Add a new generic component. */
+
+static struct demangle_component *
+d_make_comp (di, type, left, right)
+ struct d_info *di;
+ enum demangle_component_type type;
+ struct demangle_component *left;
+ struct demangle_component *right;
+{
+ struct demangle_component *p;
+
+ /* We check for errors here. A typical error would be a NULL return
+ from a subroutine. We catch those here, and return NULL
+ upward. */
+ switch (type)
{
- arg = arg->next;
- if (arg == NULL)
- /* Ran out of arguments before INDEX hit zero. That's an
- error. */
+ /* These types require two parameters. */
+ case DEMANGLE_COMPONENT_QUAL_NAME:
+ case DEMANGLE_COMPONENT_LOCAL_NAME:
+ case DEMANGLE_COMPONENT_TYPED_NAME:
+ case DEMANGLE_COMPONENT_TEMPLATE:
+ case DEMANGLE_COMPONENT_CONSTRUCTION_VTABLE:
+ case DEMANGLE_COMPONENT_VENDOR_TYPE_QUAL:
+ case DEMANGLE_COMPONENT_PTRMEM_TYPE:
+ case DEMANGLE_COMPONENT_UNARY:
+ case DEMANGLE_COMPONENT_BINARY:
+ case DEMANGLE_COMPONENT_BINARY_ARGS:
+ case DEMANGLE_COMPONENT_TRINARY:
+ case DEMANGLE_COMPONENT_TRINARY_ARG1:
+ case DEMANGLE_COMPONENT_TRINARY_ARG2:
+ case DEMANGLE_COMPONENT_LITERAL:
+ case DEMANGLE_COMPONENT_LITERAL_NEG:
+ if (left == NULL || right == NULL)
+ return NULL;
+ break;
+
+ /* These types only require one parameter. */
+ case DEMANGLE_COMPONENT_VTABLE:
+ case DEMANGLE_COMPONENT_VTT:
+ case DEMANGLE_COMPONENT_TYPEINFO:
+ case DEMANGLE_COMPONENT_TYPEINFO_NAME:
+ case DEMANGLE_COMPONENT_TYPEINFO_FN:
+ case DEMANGLE_COMPONENT_THUNK:
+ case DEMANGLE_COMPONENT_VIRTUAL_THUNK:
+ case DEMANGLE_COMPONENT_COVARIANT_THUNK:
+ case DEMANGLE_COMPONENT_JAVA_CLASS:
+ case DEMANGLE_COMPONENT_GUARD:
+ case DEMANGLE_COMPONENT_REFTEMP:
+ case DEMANGLE_COMPONENT_POINTER:
+ case DEMANGLE_COMPONENT_REFERENCE:
+ case DEMANGLE_COMPONENT_COMPLEX:
+ case DEMANGLE_COMPONENT_IMAGINARY:
+ case DEMANGLE_COMPONENT_VENDOR_TYPE:
+ case DEMANGLE_COMPONENT_ARGLIST:
+ case DEMANGLE_COMPONENT_TEMPLATE_ARGLIST:
+ case DEMANGLE_COMPONENT_CAST:
+ if (left == NULL)
return NULL;
+ break;
+
+ /* This needs a right parameter, but the left parameter can be
+ empty. */
+ case DEMANGLE_COMPONENT_ARRAY_TYPE:
+ if (right == NULL)
+ return NULL;
+ break;
+
+ /* These are allowed to have no parameters--in some cases they
+ will be filled in later. */
+ case DEMANGLE_COMPONENT_FUNCTION_TYPE:
+ case DEMANGLE_COMPONENT_RESTRICT:
+ case DEMANGLE_COMPONENT_VOLATILE:
+ case DEMANGLE_COMPONENT_CONST:
+ case DEMANGLE_COMPONENT_RESTRICT_THIS:
+ case DEMANGLE_COMPONENT_VOLATILE_THIS:
+ case DEMANGLE_COMPONENT_CONST_THIS:
+ break;
+
+ /* Other types should not be seen here. */
+ default:
+ return NULL;
}
- /* Return the argument at position INDEX. */
- return arg;
+
+ p = d_make_empty (di);
+ if (p != NULL)
+ {
+ p->type = type;
+ p->u.s_binary.left = left;
+ p->u.s_binary.right = right;
+ }
+ return p;
}
-/* Pushes ARG_LIST onto the top of the template argument list stack. */
+/* Add a new name component. */
-static void
-push_template_arg_list (dm, arg_list)
- demangling_t dm;
- template_arg_list_t arg_list;
+static struct demangle_component *
+d_make_name (di, s, len)
+ struct d_info *di;
+ const char *s;
+ int len;
{
- arg_list->next = dm->template_arg_lists;
- dm->template_arg_lists = arg_list;
-#ifdef CP_DEMANGLE_DEBUG
- fprintf (stderr, " ** pushing template arg list\n");
- template_arg_list_print (arg_list, stderr);
-#endif
+ struct demangle_component *p;
+
+ p = d_make_empty (di);
+ if (! cplus_demangle_fill_name (p, s, len))
+ return NULL;
+ return p;
}
-/* Pops and deletes elements on the template argument list stack until
- arg_list is the topmost element. If arg_list is NULL, all elements
- are popped and deleted. */
+/* Add a new builtin type component. */
-static void
-pop_to_template_arg_list (dm, arg_list)
- demangling_t dm;
- template_arg_list_t arg_list;
+static struct demangle_component *
+d_make_builtin_type (di, type)
+ struct d_info *di;
+ const struct demangle_builtin_type_info *type;
{
- while (dm->template_arg_lists != arg_list)
+ struct demangle_component *p;
+
+ if (type == NULL)
+ return NULL;
+ p = d_make_empty (di);
+ if (p != NULL)
{
- template_arg_list_t top = dm->template_arg_lists;
- /* Disconnect the topmost element from the list. */
- dm->template_arg_lists = top->next;
- /* Delete the popped element. */
- template_arg_list_delete (top);
-#ifdef CP_DEMANGLE_DEBUG
- fprintf (stderr, " ** removing template arg list\n");
-#endif
+ p->type = DEMANGLE_COMPONENT_BUILTIN_TYPE;
+ p->u.s_builtin.type = type;
}
+ return p;
}
-#ifdef CP_DEMANGLE_DEBUG
+/* Add a new operator component. */
-/* Prints the contents of ARG_LIST to FP. */
-
-static void
-template_arg_list_print (arg_list, fp)
- template_arg_list_t arg_list;
- FILE *fp;
+static struct demangle_component *
+d_make_operator (di, op)
+ struct d_info *di;
+ const struct demangle_operator_info *op;
{
- string_list_t arg;
- int index = -1;
+ struct demangle_component *p;
- fprintf (fp, "TEMPLATE ARGUMENT LIST:\n");
- for (arg = arg_list->first_argument; arg != NULL; arg = arg->next)
+ p = d_make_empty (di);
+ if (p != NULL)
{
- if (index == -1)
- fprintf (fp, " T_ : ");
- else
- fprintf (fp, " T%d_ : ", index);
- ++index;
- fprintf (fp, "%s\n", dyn_string_buf ((dyn_string_t) arg));
+ p->type = DEMANGLE_COMPONENT_OPERATOR;
+ p->u.s_operator.op = op;
}
+ return p;
}
-#endif /* CP_DEMANGLE_DEBUG */
-
-/* Returns the topmost element on the stack of template argument
- lists. If there is no list of template arguments, returns NULL. */
+/* Add a new extended operator component. */
-static template_arg_list_t
-current_template_arg_list (dm)
- demangling_t dm;
+static struct demangle_component *
+d_make_extended_operator (di, args, name)
+ struct d_info *di;
+ int args;
+ struct demangle_component *name;
{
- return dm->template_arg_lists;
+ struct demangle_component *p;
+
+ p = d_make_empty (di);
+ if (! cplus_demangle_fill_extended_operator (p, args, name))
+ return NULL;
+ return p;
}
-/* Allocates a demangling_t object for demangling mangled NAME. A new
- result must be pushed before the returned object can be used.
- Returns NULL if allocation fails. */
+/* Add a new constructor component. */
-static demangling_t
-demangling_new (name, style)
- const char *name;
- int style;
+static struct demangle_component *
+d_make_ctor (di, kind, name)
+ struct d_info *di;
+ enum gnu_v3_ctor_kinds kind;
+ struct demangle_component *name;
{
- demangling_t dm;
- dm = (demangling_t) malloc (sizeof (struct demangling_def));
- if (dm == NULL)
- return NULL;
+ struct demangle_component *p;
- dm->name = name;
- dm->next = name;
- dm->result = NULL;
- dm->num_substitutions = 0;
- dm->substitutions_allocated = 10;
- dm->template_arg_lists = NULL;
- dm->last_source_name = dyn_string_new (0);
- if (dm->last_source_name == NULL)
+ p = d_make_empty (di);
+ if (! cplus_demangle_fill_ctor (p, kind, name))
return NULL;
- dm->substitutions = (struct substitution_def *)
- malloc (dm->substitutions_allocated * sizeof (struct substitution_def));
- if (dm->substitutions == NULL)
- {
- dyn_string_delete (dm->last_source_name);
- return NULL;
- }
- dm->style = style;
- dm->is_constructor = 0;
- dm->is_destructor = 0;
+ return p;
+}
+
+/* Add a new destructor component. */
+
+static struct demangle_component *
+d_make_dtor (di, kind, name)
+ struct d_info *di;
+ enum gnu_v3_dtor_kinds kind;
+ struct demangle_component *name;
+{
+ struct demangle_component *p;
- return dm;
+ p = d_make_empty (di);
+ if (! cplus_demangle_fill_dtor (p, kind, name))
+ return NULL;
+ return p;
}
-/* Deallocates a demangling_t object and all memory associated with
- it. */
+/* Add a new template parameter. */
-static void
-demangling_delete (dm)
- demangling_t dm;
+static struct demangle_component *
+d_make_template_param (di, i)
+ struct d_info *di;
+ long i;
{
- int i;
- template_arg_list_t arg_list = dm->template_arg_lists;
+ struct demangle_component *p;
- /* Delete the stack of template argument lists. */
- while (arg_list != NULL)
+ p = d_make_empty (di);
+ if (p != NULL)
{
- template_arg_list_t next = arg_list->next;
- template_arg_list_delete (arg_list);
- arg_list = next;
+ p->type = DEMANGLE_COMPONENT_TEMPLATE_PARAM;
+ p->u.s_number.number = i;
}
- /* Delete the list of substitutions. */
- for (i = dm->num_substitutions; --i >= 0; )
- dyn_string_delete (dm->substitutions[i].text);
- free (dm->substitutions);
- /* Delete the demangled result. */
- string_list_delete (dm->result);
- /* Delete the stored identifier name. */
- dyn_string_delete (dm->last_source_name);
- /* Delete the context object itself. */
- free (dm);
+ return p;
}
-/* These functions demangle an alternative of the corresponding
- production in the mangling spec. The first argument of each is a
- demangling context structure for the current demangling
- operation. Most emit demangled text directly to the topmost result
- string on the result string stack in the demangling context
- structure. */
-
-static status_t demangle_char
- PARAMS ((demangling_t, int));
-static status_t demangle_mangled_name
- PARAMS ((demangling_t));
-static status_t demangle_encoding
- PARAMS ((demangling_t));
-static status_t demangle_name
- PARAMS ((demangling_t, int *));
-static status_t demangle_nested_name
- PARAMS ((demangling_t, int *));
-static status_t demangle_prefix
- PARAMS ((demangling_t, int *));
-static status_t demangle_unqualified_name
- PARAMS ((demangling_t, int *));
-static status_t demangle_source_name
- PARAMS ((demangling_t));
-static status_t demangle_number
- PARAMS ((demangling_t, int *, int, int));
-static status_t demangle_number_literally
- PARAMS ((demangling_t, dyn_string_t, int, int));
-static status_t demangle_identifier
- PARAMS ((demangling_t, int, dyn_string_t));
-static status_t demangle_operator_name
- PARAMS ((demangling_t, int, int *, int *));
-static status_t demangle_nv_offset
- PARAMS ((demangling_t));
-static status_t demangle_v_offset
- PARAMS ((demangling_t));
-static status_t demangle_call_offset
- PARAMS ((demangling_t));
-static status_t demangle_special_name
- PARAMS ((demangling_t));
-static status_t demangle_ctor_dtor_name
- PARAMS ((demangling_t));
-static status_t demangle_type_ptr
- PARAMS ((demangling_t, int *, int));
-static status_t demangle_type
- PARAMS ((demangling_t));
-static status_t demangle_CV_qualifiers
- PARAMS ((demangling_t, dyn_string_t));
-static status_t demangle_builtin_type
- PARAMS ((demangling_t));
-static status_t demangle_function_type
- PARAMS ((demangling_t, int *));
-static status_t demangle_bare_function_type
- PARAMS ((demangling_t, int *));
-static status_t demangle_class_enum_type
- PARAMS ((demangling_t, int *));
-static status_t demangle_array_type
- PARAMS ((demangling_t, int *));
-static status_t demangle_template_param
- PARAMS ((demangling_t));
-static status_t demangle_template_args
- PARAMS ((demangling_t));
-static status_t demangle_literal
- PARAMS ((demangling_t));
-static status_t demangle_template_arg
- PARAMS ((demangling_t));
-static status_t demangle_expression
- PARAMS ((demangling_t));
-static status_t demangle_scope_expression
- PARAMS ((demangling_t));
-static status_t demangle_expr_primary
- PARAMS ((demangling_t));
-static status_t demangle_substitution
- PARAMS ((demangling_t, int *));
-static status_t demangle_local_name
- PARAMS ((demangling_t));
-static status_t demangle_discriminator
- PARAMS ((demangling_t, int));
-static status_t cp_demangle
- PARAMS ((const char *, dyn_string_t, int));
-static status_t cp_demangle_type
- PARAMS ((const char*, dyn_string_t));
-
-/* When passed to demangle_bare_function_type, indicates that the
- function's return type is not encoded before its parameter types. */
-#define BFT_NO_RETURN_TYPE NULL
-
-/* Check that the next character is C. If so, consume it. If not,
- return an error. */
-
-static status_t
-demangle_char (dm, c)
- demangling_t dm;
- int c;
+/* Add a new standard substitution component. */
+
+static struct demangle_component *
+d_make_sub (di, name, len)
+ struct d_info *di;
+ const char *name;
+ int len;
{
- static char *error_message = NULL;
+ struct demangle_component *p;
- if (peek_char (dm) == c)
+ p = d_make_empty (di);
+ if (p != NULL)
{
- advance_char (dm);
- return STATUS_OK;
- }
- else
- {
- if (error_message == NULL)
- error_message = strdup ("Expected ?");
- error_message[9] = c;
- return error_message;
+ p->type = DEMANGLE_COMPONENT_SUB_STD;
+ p->u.s_string.string = name;
+ p->u.s_string.len = len;
}
+ return p;
}
-/* Demangles and emits a <mangled-name>.
+/* <mangled-name> ::= _Z <encoding>
- <mangled-name> ::= _Z <encoding> */
+ TOP_LEVEL is non-zero when called at the top level. */
-static status_t
-demangle_mangled_name (dm)
- demangling_t dm;
+CP_STATIC_IF_GLIBCPP_V3
+struct demangle_component *
+cplus_demangle_mangled_name (di, top_level)
+ struct d_info *di;
+ int top_level;
{
- DEMANGLE_TRACE ("mangled-name", dm);
- RETURN_IF_ERROR (demangle_char (dm, '_'));
- RETURN_IF_ERROR (demangle_char (dm, 'Z'));
- RETURN_IF_ERROR (demangle_encoding (dm));
- return STATUS_OK;
+ if (d_next_char (di) != '_')
+ return NULL;
+ if (d_next_char (di) != 'Z')
+ return NULL;
+ return d_encoding (di, top_level);
}
-/* Demangles and emits an <encoding>.
+/* Return whether a function should have a return type. The argument
+ is the function name, which may be qualified in various ways. The
+ rules are that template functions have return types with some
+ exceptions, function types which are not part of a function name
+ mangling have return types with some exceptions, and non-template
+ function names do not have return types. The exceptions are that
+ constructors, destructors, and conversion operators do not have
+ return types. */
+
+static int
+has_return_type (dc)
+ struct demangle_component *dc;
+{
+ if (dc == NULL)
+ return 0;
+ switch (dc->type)
+ {
+ default:
+ return 0;
+ case DEMANGLE_COMPONENT_TEMPLATE:
+ return ! is_ctor_dtor_or_conversion (d_left (dc));
+ case DEMANGLE_COMPONENT_RESTRICT_THIS:
+ case DEMANGLE_COMPONENT_VOLATILE_THIS:
+ case DEMANGLE_COMPONENT_CONST_THIS:
+ return has_return_type (d_left (dc));
+ }
+}
- <encoding> ::= <function name> <bare-function-type>
- ::= <data name>
- ::= <special-name> */
+/* Return whether a name is a constructor, a destructor, or a
+ conversion operator. */
-static status_t
-demangle_encoding (dm)
- demangling_t dm;
+static int
+is_ctor_dtor_or_conversion (dc)
+ struct demangle_component *dc;
{
- int encode_return_type;
- int start_position;
- template_arg_list_t old_arg_list = current_template_arg_list (dm);
- char peek = peek_char (dm);
+ if (dc == NULL)
+ return 0;
+ switch (dc->type)
+ {
+ default:
+ return 0;
+ case DEMANGLE_COMPONENT_QUAL_NAME:
+ case DEMANGLE_COMPONENT_LOCAL_NAME:
+ return is_ctor_dtor_or_conversion (d_right (dc));
+ case DEMANGLE_COMPONENT_CTOR:
+ case DEMANGLE_COMPONENT_DTOR:
+ case DEMANGLE_COMPONENT_CAST:
+ return 1;
+ }
+}
- DEMANGLE_TRACE ("encoding", dm);
-
- /* Remember where the name starts. If it turns out to be a template
- function, we'll have to insert the return type here. */
- start_position = result_caret_pos (dm);
+/* <encoding> ::= <(function) name> <bare-function-type>
+ ::= <(data) name>
+ ::= <special-name>
+
+ TOP_LEVEL is non-zero when called at the top level, in which case
+ if DMGL_PARAMS is not set we do not demangle the function
+ parameters. We only set this at the top level, because otherwise
+ we would not correctly demangle names in local scopes. */
+
+static struct demangle_component *
+d_encoding (di, top_level)
+ struct d_info *di;
+ int top_level;
+{
+ char peek = d_peek_char (di);
if (peek == 'G' || peek == 'T')
- RETURN_IF_ERROR (demangle_special_name (dm));
+ return d_special_name (di);
else
{
- /* Now demangle the name. */
- RETURN_IF_ERROR (demangle_name (dm, &encode_return_type));
+ struct demangle_component *dc;
- /* If there's anything left, the name was a function name, with
- maybe its return type, and its parameter types, following. */
- if (!end_of_name_p (dm)
- && peek_char (dm) != 'E')
+ dc = d_name (di);
+
+ if (dc != NULL && top_level && (di->options & DMGL_PARAMS) == 0)
{
- if (encode_return_type)
- /* Template functions have their return type encoded. The
- return type should be inserted at start_position. */
- RETURN_IF_ERROR
- (demangle_bare_function_type (dm, &start_position));
- else
- /* Non-template functions don't have their return type
- encoded. */
- RETURN_IF_ERROR
- (demangle_bare_function_type (dm, BFT_NO_RETURN_TYPE));
- }
- }
+ /* Strip off any initial CV-qualifiers, as they really apply
+ to the `this' parameter, and they were not output by the
+ v2 demangler without DMGL_PARAMS. */
+ while (dc->type == DEMANGLE_COMPONENT_RESTRICT_THIS
+ || dc->type == DEMANGLE_COMPONENT_VOLATILE_THIS
+ || dc->type == DEMANGLE_COMPONENT_CONST_THIS)
+ dc = d_left (dc);
+
+ /* If the top level is a DEMANGLE_COMPONENT_LOCAL_NAME, then
+ there may be CV-qualifiers on its right argument which
+ really apply here; this happens when parsing a class
+ which is local to a function. */
+ if (dc->type == DEMANGLE_COMPONENT_LOCAL_NAME)
+ {
+ struct demangle_component *dcr;
+
+ dcr = d_right (dc);
+ while (dcr->type == DEMANGLE_COMPONENT_RESTRICT_THIS
+ || dcr->type == DEMANGLE_COMPONENT_VOLATILE_THIS
+ || dcr->type == DEMANGLE_COMPONENT_CONST_THIS)
+ dcr = d_left (dcr);
+ dc->u.s_binary.right = dcr;
+ }
- /* Pop off template argument lists that were built during the
- mangling of this name, to restore the old template context. */
- pop_to_template_arg_list (dm, old_arg_list);
+ return dc;
+ }
- return STATUS_OK;
+ peek = d_peek_char (di);
+ if (peek == '\0' || peek == 'E')
+ return dc;
+ return d_make_comp (di, DEMANGLE_COMPONENT_TYPED_NAME, dc,
+ d_bare_function_type (di, has_return_type (dc)));
+ }
}
-/* Demangles and emits a <name>.
-
- <name> ::= <unscoped-name>
- ::= <unscoped-template-name> <template-args>
- ::= <nested-name>
- ::= <local-name>
+/* <name> ::= <nested-name>
+ ::= <unscoped-name>
+ ::= <unscoped-template-name> <template-args>
+ ::= <local-name>
- <unscoped-name> ::= <unqualified-name>
- ::= St <unqualified-name> # ::std::
+ <unscoped-name> ::= <unqualified-name>
+ ::= St <unqualified-name>
- <unscoped-template-name>
- ::= <unscoped-name>
- ::= <substitution> */
+ <unscoped-template-name> ::= <unscoped-name>
+ ::= <substitution>
+*/
-static status_t
-demangle_name (dm, encode_return_type)
- demangling_t dm;
- int *encode_return_type;
+static struct demangle_component *
+d_name (di)
+ struct d_info *di;
{
- int start = substitution_start (dm);
- char peek = peek_char (dm);
- int is_std_substitution = 0;
-
- /* Generally, the return type is encoded if the function is a
- template-id, and suppressed otherwise. There are a few cases,
- though, in which the return type is not encoded even for a
- templated function. In these cases, this flag is set. */
- int suppress_return_type = 0;
-
- DEMANGLE_TRACE ("name", dm);
+ char peek = d_peek_char (di);
+ struct demangle_component *dc;
switch (peek)
{
case 'N':
- /* This is a <nested-name>. */
- RETURN_IF_ERROR (demangle_nested_name (dm, encode_return_type));
- break;
+ return d_nested_name (di);
case 'Z':
- RETURN_IF_ERROR (demangle_local_name (dm));
- *encode_return_type = 0;
- break;
+ return d_local_name (di);
case 'S':
- /* The `St' substitution allows a name nested in std:: to appear
- without being enclosed in a nested name. */
- if (peek_char_next (dm) == 't')
- {
- (void) next_char (dm);
- (void) next_char (dm);
- RETURN_IF_ERROR (result_add (dm, "std::"));
- RETURN_IF_ERROR
- (demangle_unqualified_name (dm, &suppress_return_type));
- is_std_substitution = 1;
- }
- else
- RETURN_IF_ERROR (demangle_substitution (dm, encode_return_type));
- /* Check if a template argument list immediately follows.
- If so, then we just demangled an <unqualified-template-name>. */
- if (peek_char (dm) == 'I')
- {
- /* A template name of the form std::<unqualified-name> is a
- substitution candidate. */
- if (is_std_substitution)
- RETURN_IF_ERROR (substitution_add (dm, start, 0));
- /* Demangle the <template-args> here. */
- RETURN_IF_ERROR (demangle_template_args (dm));
- *encode_return_type = !suppress_return_type;
- }
- else
- *encode_return_type = 0;
+ {
+ int subst;
- break;
+ if (d_peek_next_char (di) != 't')
+ {
+ dc = d_substitution (di, 0);
+ subst = 1;
+ }
+ else
+ {
+ d_advance (di, 2);
+ dc = d_make_comp (di, DEMANGLE_COMPONENT_QUAL_NAME,
+ d_make_name (di, "std", 3),
+ d_unqualified_name (di));
+ di->expansion += 3;
+ subst = 0;
+ }
- default:
- /* This is an <unscoped-name> or <unscoped-template-name>. */
- RETURN_IF_ERROR (demangle_unqualified_name (dm, &suppress_return_type));
+ if (d_peek_char (di) != 'I')
+ {
+ /* The grammar does not permit this case to occur if we
+ called d_substitution() above (i.e., subst == 1). We
+ don't bother to check. */
+ }
+ else
+ {
+ /* This is <template-args>, which means that we just saw
+ <unscoped-template-name>, which is a substitution
+ candidate if we didn't just get it from a
+ substitution. */
+ if (! subst)
+ {
+ if (! d_add_substitution (di, dc))
+ return NULL;
+ }
+ dc = d_make_comp (di, DEMANGLE_COMPONENT_TEMPLATE, dc,
+ d_template_args (di));
+ }
- /* If the <unqualified-name> is followed by template args, this
- is an <unscoped-template-name>. */
- if (peek_char (dm) == 'I')
- {
- /* Add a substitution for the unqualified template name. */
- RETURN_IF_ERROR (substitution_add (dm, start, 0));
+ return dc;
+ }
- RETURN_IF_ERROR (demangle_template_args (dm));
- *encode_return_type = !suppress_return_type;
+ default:
+ dc = d_unqualified_name (di);
+ if (d_peek_char (di) == 'I')
+ {
+ /* This is <template-args>, which means that we just saw
+ <unscoped-template-name>, which is a substitution
+ candidate. */
+ if (! d_add_substitution (di, dc))
+ return NULL;
+ dc = d_make_comp (di, DEMANGLE_COMPONENT_TEMPLATE, dc,
+ d_template_args (di));
}
- else
- *encode_return_type = 0;
-
- break;
+ return dc;
}
-
- return STATUS_OK;
}
-/* Demangles and emits a <nested-name>.
-
- <nested-name> ::= N [<CV-qualifiers>] <prefix> <unqulified-name> E */
+/* <nested-name> ::= N [<CV-qualifiers>] <prefix> <unqualified-name> E
+ ::= N [<CV-qualifiers>] <template-prefix> <template-args> E
+*/
-static status_t
-demangle_nested_name (dm, encode_return_type)
- demangling_t dm;
- int *encode_return_type;
+static struct demangle_component *
+d_nested_name (di)
+ struct d_info *di;
{
- char peek;
+ struct demangle_component *ret;
+ struct demangle_component **pret;
- DEMANGLE_TRACE ("nested-name", dm);
+ if (d_next_char (di) != 'N')
+ return NULL;
- RETURN_IF_ERROR (demangle_char (dm, 'N'));
+ pret = d_cv_qualifiers (di, &ret, 1);
+ if (pret == NULL)
+ return NULL;
- peek = peek_char (dm);
- if (peek == 'r' || peek == 'V' || peek == 'K')
- {
- dyn_string_t cv_qualifiers;
- status_t status;
-
- /* Snarf up CV qualifiers. */
- cv_qualifiers = dyn_string_new (24);
- if (cv_qualifiers == NULL)
- return STATUS_ALLOCATION_FAILED;
- demangle_CV_qualifiers (dm, cv_qualifiers);
-
- /* Emit them, preceded by a space. */
- status = result_add_char (dm, ' ');
- if (STATUS_NO_ERROR (status))
- status = result_add_string (dm, cv_qualifiers);
- /* The CV qualifiers that occur in a <nested-name> will be
- qualifiers for member functions. These are placed at the end
- of the function. Therefore, shift the caret to the left by
- the length of the qualifiers, so other text is inserted
- before them and they stay at the end. */
- result_shift_caret (dm, -dyn_string_length (cv_qualifiers) - 1);
- /* Clean up. */
- dyn_string_delete (cv_qualifiers);
- RETURN_IF_ERROR (status);
- }
+ *pret = d_prefix (di);
+ if (*pret == NULL)
+ return NULL;
- RETURN_IF_ERROR (demangle_prefix (dm, encode_return_type));
- /* No need to demangle the final <unqualified-name>; demangle_prefix
- will handle it. */
- RETURN_IF_ERROR (demangle_char (dm, 'E'));
+ if (d_next_char (di) != 'E')
+ return NULL;
- return STATUS_OK;
+ return ret;
}
-/* Demangles and emits a <prefix>.
-
- <prefix> ::= <prefix> <unqualified-name>
- ::= <template-prefix> <template-args>
- ::= # empty
- ::= <substitution>
+/* <prefix> ::= <prefix> <unqualified-name>
+ ::= <template-prefix> <template-args>
+ ::= <template-param>
+ ::=
+ ::= <substitution>
- <template-prefix> ::= <prefix>
- ::= <substitution> */
+ <template-prefix> ::= <prefix> <(template) unqualified-name>
+ ::= <template-param>
+ ::= <substitution>
+*/
-static status_t
-demangle_prefix (dm, encode_return_type)
- demangling_t dm;
- int *encode_return_type;
+static struct demangle_component *
+d_prefix (di)
+ struct d_info *di;
{
- int start = substitution_start (dm);
- int nested = 0;
-
- /* ENCODE_RETURN_TYPE is updated as we decend the nesting chain.
- After <template-args>, it is set to non-zero; after everything
- else it is set to zero. */
-
- /* Generally, the return type is encoded if the function is a
- template-id, and suppressed otherwise. There are a few cases,
- though, in which the return type is not encoded even for a
- templated function. In these cases, this flag is set. */
- int suppress_return_type = 0;
-
- DEMANGLE_TRACE ("prefix", dm);
+ struct demangle_component *ret = NULL;
while (1)
{
char peek;
+ enum demangle_component_type comb_type;
+ struct demangle_component *dc;
- if (end_of_name_p (dm))
- return "Unexpected end of name in <compound-name>.";
-
- peek = peek_char (dm);
-
- /* We'll initialize suppress_return_type to false, and set it to true
- if we end up demangling a constructor name. However, make
- sure we're not actually about to demangle template arguments
- -- if so, this is the <template-args> following a
- <template-prefix>, so we'll want the previous flag value
- around. */
- if (peek != 'I')
- suppress_return_type = 0;
-
- if (IS_DIGIT ((unsigned char) peek)
- || (peek >= 'a' && peek <= 'z')
- || peek == 'C' || peek == 'D'
- || peek == 'S')
- {
- /* We have another level of scope qualification. */
- if (nested)
- RETURN_IF_ERROR (result_add (dm, NAMESPACE_SEPARATOR));
- else
- nested = 1;
+ peek = d_peek_char (di);
+ if (peek == '\0')
+ return NULL;
- if (peek == 'S')
- /* The substitution determines whether this is a
- template-id. */
- RETURN_IF_ERROR (demangle_substitution (dm, encode_return_type));
- else
- {
- /* It's just a name. */
- RETURN_IF_ERROR
- (demangle_unqualified_name (dm, &suppress_return_type));
- *encode_return_type = 0;
- }
- }
- else if (peek == 'Z')
- RETURN_IF_ERROR (demangle_local_name (dm));
+ /* The older code accepts a <local-name> here, but I don't see
+ that in the grammar. The older code does not accept a
+ <template-param> here. */
+
+ comb_type = DEMANGLE_COMPONENT_QUAL_NAME;
+ if (IS_DIGIT (peek)
+ || IS_LOWER (peek)
+ || peek == 'C'
+ || peek == 'D')
+ dc = d_unqualified_name (di);
+ else if (peek == 'S')
+ dc = d_substitution (di, 1);
else if (peek == 'I')
{
- RETURN_IF_ERROR (demangle_template_args (dm));
-
- /* Now we want to indicate to the caller that we've
- demangled template arguments, thus the prefix was a
- <template-prefix>. That's so that the caller knows to
- demangle the function's return type, if this turns out to
- be a function name. But, if it's a member template
- constructor or a templated conversion operator, report it
- as untemplated. Those never get encoded return types. */
- *encode_return_type = !suppress_return_type;
+ if (ret == NULL)
+ return NULL;
+ comb_type = DEMANGLE_COMPONENT_TEMPLATE;
+ dc = d_template_args (di);
}
+ else if (peek == 'T')
+ dc = d_template_param (di);
else if (peek == 'E')
- /* All done. */
- return STATUS_OK;
+ return ret;
+ else
+ return NULL;
+
+ if (ret == NULL)
+ ret = dc;
else
- return "Unexpected character in <compound-name>.";
+ ret = d_make_comp (di, comb_type, ret, dc);
- if (peek != 'S'
- && peek_char (dm) != 'E')
- /* Add a new substitution for the prefix thus far. */
- RETURN_IF_ERROR (substitution_add (dm, start, *encode_return_type));
+ if (peek != 'S' && d_peek_char (di) != 'E')
+ {
+ if (! d_add_substitution (di, ret))
+ return NULL;
+ }
}
}
-/* Demangles and emits an <unqualified-name>. If this
- <unqualified-name> is for a special function type that should never
- have its return type encoded (particularly, a constructor or
- conversion operator), *SUPPRESS_RETURN_TYPE is set to 1; otherwise,
- it is set to zero.
-
- <unqualified-name> ::= <operator-name>
- ::= <special-name>
- ::= <source-name> */
+/* <unqualified-name> ::= <operator-name>
+ ::= <ctor-dtor-name>
+ ::= <source-name>
+*/
-static status_t
-demangle_unqualified_name (dm, suppress_return_type)
- demangling_t dm;
- int *suppress_return_type;
+static struct demangle_component *
+d_unqualified_name (di)
+ struct d_info *di;
{
- char peek = peek_char (dm);
-
- DEMANGLE_TRACE ("unqualified-name", dm);
-
- /* By default, don't force suppression of the return type (though
- non-template functions still don't get a return type encoded). */
- *suppress_return_type = 0;
+ char peek;
- if (IS_DIGIT ((unsigned char) peek))
- RETURN_IF_ERROR (demangle_source_name (dm));
- else if (peek >= 'a' && peek <= 'z')
+ peek = d_peek_char (di);
+ if (IS_DIGIT (peek))
+ return d_source_name (di);
+ else if (IS_LOWER (peek))
{
- int num_args;
-
- /* Conversion operators never have a return type encoded. */
- if (peek == 'c' && peek_char_next (dm) == 'v')
- *suppress_return_type = 1;
+ struct demangle_component *ret;
- RETURN_IF_ERROR (demangle_operator_name (dm, 0, &num_args, NULL));
+ ret = d_operator_name (di);
+ if (ret != NULL && ret->type == DEMANGLE_COMPONENT_OPERATOR)
+ di->expansion += sizeof "operator" + ret->u.s_operator.op->len - 2;
+ return ret;
}
else if (peek == 'C' || peek == 'D')
- {
- /* Constructors never have a return type encoded. */
- if (peek == 'C')
- *suppress_return_type = 1;
-
- RETURN_IF_ERROR (demangle_ctor_dtor_name (dm));
- }
+ return d_ctor_dtor_name (di);
else
- return "Unexpected character in <unqualified-name>.";
-
- return STATUS_OK;
+ return NULL;
}
-/* Demangles and emits <source-name>.
+/* <source-name> ::= <(positive length) number> <identifier> */
- <source-name> ::= <length number> <identifier> */
-
-static status_t
-demangle_source_name (dm)
- demangling_t dm;
+static struct demangle_component *
+d_source_name (di)
+ struct d_info *di;
{
- int length;
-
- DEMANGLE_TRACE ("source-name", dm);
-
- /* Decode the length of the identifier. */
- RETURN_IF_ERROR (demangle_number (dm, &length, 10, 0));
- if (length == 0)
- return "Zero length in <source-name>.";
-
- /* Now the identifier itself. It's placed into last_source_name,
- where it can be used to build a constructor or destructor name. */
- RETURN_IF_ERROR (demangle_identifier (dm, length,
- dm->last_source_name));
-
- /* Emit it. */
- RETURN_IF_ERROR (result_add_string (dm, dm->last_source_name));
+ long len;
+ struct demangle_component *ret;
- return STATUS_OK;
+ len = d_number (di);
+ if (len <= 0)
+ return NULL;
+ ret = d_identifier (di, len);
+ di->last_name = ret;
+ return ret;
}
-/* Demangles a number, either a <number> or a <positive-number> at the
- current position, consuming all consecutive digit characters. Sets
- *VALUE to the resulting numberand returns STATUS_OK. The number is
- interpreted as BASE, which must be either 10 or 36. If IS_SIGNED
- is non-zero, negative numbers -- prefixed with `n' -- are accepted.
-
- <number> ::= [n] <positive-number>
-
- <positive-number> ::= <decimal integer> */
-
-static status_t
-demangle_number (dm, value, base, is_signed)
- demangling_t dm;
- int *value;
- int base;
- int is_signed;
-{
- dyn_string_t number = dyn_string_new (10);
-
- DEMANGLE_TRACE ("number", dm);
-
- if (number == NULL)
- return STATUS_ALLOCATION_FAILED;
-
- demangle_number_literally (dm, number, base, is_signed);
- *value = strtol (dyn_string_buf (number), NULL, base);
- dyn_string_delete (number);
-
- return STATUS_OK;
-}
+/* number ::= [n] <(non-negative decimal integer)> */
-/* Demangles a number at the current position. The digits (and minus
- sign, if present) that make up the number are appended to STR.
- Only base-BASE digits are accepted; BASE must be either 10 or 36.
- If IS_SIGNED, negative numbers -- prefixed with `n' -- are
- accepted. Does not consume a trailing underscore or other
- terminating character. */
-
-static status_t
-demangle_number_literally (dm, str, base, is_signed)
- demangling_t dm;
- dyn_string_t str;
- int base;
- int is_signed;
+static long
+d_number (di)
+ struct d_info *di;
{
- DEMANGLE_TRACE ("number*", dm);
-
- if (base != 10 && base != 36)
- return STATUS_INTERNAL_ERROR;
+ int negative;
+ char peek;
+ long ret;
- /* An `n' denotes a negative number. */
- if (is_signed && peek_char (dm) == 'n')
+ negative = 0;
+ peek = d_peek_char (di);
+ if (peek == 'n')
{
- /* Skip past the n. */
- advance_char (dm);
- /* The normal way to write a negative number is with a minus
- sign. */
- if (!dyn_string_append_char (str, '-'))
- return STATUS_ALLOCATION_FAILED;
+ negative = 1;
+ d_advance (di, 1);
+ peek = d_peek_char (di);
}
- /* Loop until we hit a non-digit. */
+ ret = 0;
while (1)
{
- char peek = peek_char (dm);
- if (IS_DIGIT ((unsigned char) peek)
- || (base == 36 && peek >= 'A' && peek <= 'Z'))
+ if (! IS_DIGIT (peek))
{
- /* Accumulate digits. */
- if (!dyn_string_append_char (str, next_char (dm)))
- return STATUS_ALLOCATION_FAILED;
+ if (negative)
+ ret = - ret;
+ return ret;
}
- else
- /* Not a digit? All done. */
- break;
+ ret = ret * 10 + peek - '0';
+ d_advance (di, 1);
+ peek = d_peek_char (di);
}
-
- return STATUS_OK;
}
-/* Demangles an identifier at the current position of LENGTH
- characters and places it in IDENTIFIER. */
+/* identifier ::= <(unqualified source code identifier)> */
-static status_t
-demangle_identifier (dm, length, identifier)
- demangling_t dm;
- int length;
- dyn_string_t identifier;
+static struct demangle_component *
+d_identifier (di, len)
+ struct d_info *di;
+ int len;
{
- DEMANGLE_TRACE ("identifier", dm);
+ const char *name;
- dyn_string_clear (identifier);
- if (!dyn_string_resize (identifier, length))
- return STATUS_ALLOCATION_FAILED;
+ name = d_str (di);
- while (length-- > 0)
- {
- int ch;
- if (end_of_name_p (dm))
- return "Unexpected end of name in <identifier>.";
- ch = next_char (dm);
-
- /* Handle extended Unicode characters. We encode them as __U{hex}_,
- where {hex} omits leading 0's. For instance, '$' is encoded as
- "__U24_". */
- if (ch == '_'
- && peek_char (dm) == '_'
- && peek_char_next (dm) == 'U')
- {
- char buf[10];
- int pos = 0;
- advance_char (dm); advance_char (dm); length -= 2;
- while (length-- > 0)
- {
- ch = next_char (dm);
- if (!isxdigit (ch))
- break;
- buf[pos++] = ch;
- }
- if (ch != '_' || length < 0)
- return STATUS_ERROR;
- if (pos == 0)
- {
- /* __U_ just means __U. */
- if (!dyn_string_append_cstr (identifier, "__U"))
- return STATUS_ALLOCATION_FAILED;
- continue;
- }
- else
- {
- buf[pos] = '\0';
- ch = strtol (buf, 0, 16);
- }
- }
-
- if (!dyn_string_append_char (identifier, ch))
- return STATUS_ALLOCATION_FAILED;
- }
+ if (di->send - name < len)
+ return NULL;
- /* GCC encodes anonymous namespaces using a `_GLOBAL_[_.$]N.'
- followed by the source file name and some random characters.
- Unless we're in strict mode, decipher these names appropriately. */
- if (!flag_strict)
+ d_advance (di, len);
+
+ /* A Java mangled name may have a trailing '$' if it is a C++
+ keyword. This '$' is not included in the length count. We just
+ ignore the '$'. */
+ if ((di->options & DMGL_JAVA) != 0
+ && d_peek_char (di) == '$')
+ d_advance (di, 1);
+
+ /* Look for something which looks like a gcc encoding of an
+ anonymous namespace, and replace it with a more user friendly
+ name. */
+ if (len >= (int) ANONYMOUS_NAMESPACE_PREFIX_LEN + 2
+ && memcmp (name, ANONYMOUS_NAMESPACE_PREFIX,
+ ANONYMOUS_NAMESPACE_PREFIX_LEN) == 0)
{
- char *name = dyn_string_buf (identifier);
- int prefix_length = strlen (ANONYMOUS_NAMESPACE_PREFIX);
-
- /* Compare the first, fixed part. */
- if (strncmp (name, ANONYMOUS_NAMESPACE_PREFIX, prefix_length) == 0)
- {
- name += prefix_length;
- /* The next character might be a period, an underscore, or
- dollar sign, depending on the target architecture's
- assembler's capabilities. After that comes an `N'. */
- if ((*name == '.' || *name == '_' || *name == '$')
- && *(name + 1) == 'N')
- /* This looks like the anonymous namespace identifier.
- Replace it with something comprehensible. */
- dyn_string_copy_cstr (identifier, "(anonymous namespace)");
+ const char *s;
+
+ s = name + ANONYMOUS_NAMESPACE_PREFIX_LEN;
+ if ((*s == '.' || *s == '_' || *s == '$')
+ && s[1] == 'N')
+ {
+ di->expansion -= len - sizeof "(anonymous namespace)";
+ return d_make_name (di, "(anonymous namespace)",
+ sizeof "(anonymous namespace)" - 1);
}
}
- return STATUS_OK;
+ return d_make_name (di, name, len);
}
-/* Demangles and emits an <operator-name>. If SHORT_NAME is non-zero,
- the short form is emitted; otherwise the full source form
- (`operator +' etc.) is emitted. *NUM_ARGS is set to the number of
- operands that the operator takes. If TYPE_ARG is non-NULL,
- *TYPE_ARG is set to 1 if the first argument is a type and 0
- otherwise.
-
- <operator-name>
- ::= nw # new
- ::= na # new[]
- ::= dl # delete
- ::= da # delete[]
- ::= ps # + (unary)
- ::= ng # - (unary)
- ::= ad # & (unary)
- ::= de # * (unary)
- ::= co # ~
- ::= pl # +
- ::= mi # -
- ::= ml # *
- ::= dv # /
- ::= rm # %
- ::= an # &
- ::= or # |
- ::= eo # ^
- ::= aS # =
- ::= pL # +=
- ::= mI # -=
- ::= mL # *=
- ::= dV # /=
- ::= rM # %=
- ::= aN # &=
- ::= oR # |=
- ::= eO # ^=
- ::= ls # <<
- ::= rs # >>
- ::= lS # <<=
- ::= rS # >>=
- ::= eq # ==
- ::= ne # !=
- ::= lt # <
- ::= gt # >
- ::= le # <=
- ::= ge # >=
- ::= nt # !
- ::= aa # &&
- ::= oo # ||
- ::= pp # ++
- ::= mm # --
- ::= cm # ,
- ::= pm # ->*
- ::= pt # ->
- ::= cl # ()
- ::= ix # []
- ::= qu # ?
- ::= st # sizeof (a type)
- ::= sz # sizeof (an expression)
- ::= cv <type> # cast
- ::= v [0-9] <source-name> # vendor extended operator */
-
-static status_t
-demangle_operator_name (dm, short_name, num_args, type_arg)
- demangling_t dm;
- int short_name;
- int *num_args;
- int *type_arg;
-{
- struct operator_code
- {
- /* The mangled code for this operator. */
- const char *const code;
- /* The source name of this operator. */
- const char *const name;
- /* The number of arguments this operator takes. */
- const int num_args;
- };
-
- static const struct operator_code operators[] =
- {
- { "aN", "&=" , 2 },
- { "aS", "=" , 2 },
- { "aa", "&&" , 2 },
- { "ad", "&" , 1 },
- { "an", "&" , 2 },
- { "cl", "()" , 0 },
- { "cm", "," , 2 },
- { "co", "~" , 1 },
- { "dV", "/=" , 2 },
- { "da", " delete[]", 1 },
- { "de", "*" , 1 },
- { "dl", " delete" , 1 },
- { "dv", "/" , 2 },
- { "eO", "^=" , 2 },
- { "eo", "^" , 2 },
- { "eq", "==" , 2 },
- { "ge", ">=" , 2 },
- { "gt", ">" , 2 },
- { "ix", "[]" , 2 },
- { "lS", "<<=" , 2 },
- { "le", "<=" , 2 },
- { "ls", "<<" , 2 },
- { "lt", "<" , 2 },
- { "mI", "-=" , 2 },
- { "mL", "*=" , 2 },
- { "mi", "-" , 2 },
- { "ml", "*" , 2 },
- { "mm", "--" , 1 },
- { "na", " new[]" , 1 },
- { "ne", "!=" , 2 },
- { "ng", "-" , 1 },
- { "nt", "!" , 1 },
- { "nw", " new" , 1 },
- { "oR", "|=" , 2 },
- { "oo", "||" , 2 },
- { "or", "|" , 2 },
- { "pL", "+=" , 2 },
- { "pl", "+" , 2 },
- { "pm", "->*" , 2 },
- { "pp", "++" , 1 },
- { "ps", "+" , 1 },
- { "pt", "->" , 2 },
- { "qu", "?" , 3 },
- { "rM", "%=" , 2 },
- { "rS", ">>=" , 2 },
- { "rm", "%" , 2 },
- { "rs", ">>" , 2 },
- { "sz", " sizeof" , 1 }
- };
-
- const int num_operators =
- sizeof (operators) / sizeof (struct operator_code);
-
- int c0 = next_char (dm);
- int c1 = next_char (dm);
- const struct operator_code* p1 = operators;
- const struct operator_code* p2 = operators + num_operators;
-
- DEMANGLE_TRACE ("operator-name", dm);
-
- /* Assume the first argument is not a type. */
- if (type_arg)
- *type_arg = 0;
-
- /* Is this a vendor-extended operator? */
- if (c0 == 'v' && IS_DIGIT (c1))
- {
- RETURN_IF_ERROR (result_add (dm, "operator "));
- RETURN_IF_ERROR (demangle_source_name (dm));
- *num_args = 0;
- return STATUS_OK;
- }
+/* operator_name ::= many different two character encodings.
+ ::= cv <type>
+ ::= v <digit> <source-name>
+*/
- /* Is this a conversion operator? */
- if (c0 == 'c' && c1 == 'v')
- {
- RETURN_IF_ERROR (result_add (dm, "operator "));
- /* Demangle the converted-to type. */
- RETURN_IF_ERROR (demangle_type (dm));
- *num_args = 0;
- return STATUS_OK;
- }
+#define NL(s) s, (sizeof s) - 1
- /* Is it the sizeof variant that takes a type? */
- if (c0 == 's' && c1 == 't')
- {
- RETURN_IF_ERROR (result_add (dm, " sizeof"));
- *num_args = 1;
- if (type_arg)
- *type_arg = 1;
- return STATUS_OK;
- }
+CP_STATIC_IF_GLIBCPP_V3
+const struct demangle_operator_info cplus_demangle_operators[] =
+{
+ { "aN", NL ("&="), 2 },
+ { "aS", NL ("="), 2 },
+ { "aa", NL ("&&"), 2 },
+ { "ad", NL ("&"), 1 },
+ { "an", NL ("&"), 2 },
+ { "cl", NL ("()"), 0 },
+ { "cm", NL (","), 2 },
+ { "co", NL ("~"), 1 },
+ { "dV", NL ("/="), 2 },
+ { "da", NL ("delete[]"), 1 },
+ { "de", NL ("*"), 1 },
+ { "dl", NL ("delete"), 1 },
+ { "dv", NL ("/"), 2 },
+ { "eO", NL ("^="), 2 },
+ { "eo", NL ("^"), 2 },
+ { "eq", NL ("=="), 2 },
+ { "ge", NL (">="), 2 },
+ { "gt", NL (">"), 2 },
+ { "ix", NL ("[]"), 2 },
+ { "lS", NL ("<<="), 2 },
+ { "le", NL ("<="), 2 },
+ { "ls", NL ("<<"), 2 },
+ { "lt", NL ("<"), 2 },
+ { "mI", NL ("-="), 2 },
+ { "mL", NL ("*="), 2 },
+ { "mi", NL ("-"), 2 },
+ { "ml", NL ("*"), 2 },
+ { "mm", NL ("--"), 1 },
+ { "na", NL ("new[]"), 1 },
+ { "ne", NL ("!="), 2 },
+ { "ng", NL ("-"), 1 },
+ { "nt", NL ("!"), 1 },
+ { "nw", NL ("new"), 1 },
+ { "oR", NL ("|="), 2 },
+ { "oo", NL ("||"), 2 },
+ { "or", NL ("|"), 2 },
+ { "pL", NL ("+="), 2 },
+ { "pl", NL ("+"), 2 },
+ { "pm", NL ("->*"), 2 },
+ { "pp", NL ("++"), 1 },
+ { "ps", NL ("+"), 1 },
+ { "pt", NL ("->"), 2 },
+ { "qu", NL ("?"), 3 },
+ { "rM", NL ("%="), 2 },
+ { "rS", NL (">>="), 2 },
+ { "rm", NL ("%"), 2 },
+ { "rs", NL (">>"), 2 },
+ { "st", NL ("sizeof "), 1 },
+ { "sz", NL ("sizeof "), 1 },
+ { NULL, NULL, 0, 0 }
+};
- /* Perform a binary search for the operator code. */
- while (1)
+static struct demangle_component *
+d_operator_name (di)
+ struct d_info *di;
+{
+ char c1;
+ char c2;
+
+ c1 = d_next_char (di);
+ c2 = d_next_char (di);
+ if (c1 == 'v' && IS_DIGIT (c2))
+ return d_make_extended_operator (di, c2 - '0', d_source_name (di));
+ else if (c1 == 'c' && c2 == 'v')
+ return d_make_comp (di, DEMANGLE_COMPONENT_CAST,
+ cplus_demangle_type (di), NULL);
+ else
{
- const struct operator_code* p = p1 + (p2 - p1) / 2;
- char match0 = p->code[0];
- char match1 = p->code[1];
-
- if (c0 == match0 && c1 == match1)
- /* Found it. */
+ /* LOW is the inclusive lower bound. */
+ int low = 0;
+ /* HIGH is the exclusive upper bound. We subtract one to ignore
+ the sentinel at the end of the array. */
+ int high = ((sizeof (cplus_demangle_operators)
+ / sizeof (cplus_demangle_operators[0]))
+ - 1);
+
+ while (1)
{
- if (!short_name)
- RETURN_IF_ERROR (result_add (dm, "operator"));
- RETURN_IF_ERROR (result_add (dm, p->name));
- *num_args = p->num_args;
+ int i;
+ const struct demangle_operator_info *p;
- return STATUS_OK;
- }
+ i = low + (high - low) / 2;
+ p = cplus_demangle_operators + i;
- if (p == p1)
- /* Couldn't find it. */
- return "Unknown code in <operator-name>.";
+ if (c1 == p->code[0] && c2 == p->code[1])
+ return d_make_operator (di, p);
- /* Try again. */
- if (c0 < match0 || (c0 == match0 && c1 < match1))
- p2 = p;
- else
- p1 = p;
+ if (c1 < p->code[0] || (c1 == p->code[0] && c2 < p->code[1]))
+ high = i;
+ else
+ low = i + 1;
+ if (low == high)
+ return NULL;
+ }
}
}
-/* Demangles and omits an <nv-offset>.
-
- <nv-offset> ::= <offset number> # non-virtual base override */
+/* <special-name> ::= TV <type>
+ ::= TT <type>
+ ::= TI <type>
+ ::= TS <type>
+ ::= GV <(object) name>
+ ::= T <call-offset> <(base) encoding>
+ ::= Tc <call-offset> <call-offset> <(base) encoding>
+ Also g++ extensions:
+ ::= TC <type> <(offset) number> _ <(base) type>
+ ::= TF <type>
+ ::= TJ <type>
+ ::= GR <name>
+*/
-static status_t
-demangle_nv_offset (dm)
- demangling_t dm;
+static struct demangle_component *
+d_special_name (di)
+ struct d_info *di;
{
- dyn_string_t number;
- status_t status = STATUS_OK;
-
- DEMANGLE_TRACE ("h-offset", dm);
+ char c;
- /* Demangle the offset. */
- number = dyn_string_new (4);
- if (number == NULL)
- return STATUS_ALLOCATION_FAILED;
- demangle_number_literally (dm, number, 10, 1);
-
- /* Don't display the offset unless in verbose mode. */
- if (flag_verbose)
+ di->expansion += 20;
+ c = d_next_char (di);
+ if (c == 'T')
{
- status = result_add (dm, " [nv:");
- if (STATUS_NO_ERROR (status))
- status = result_add_string (dm, number);
- if (STATUS_NO_ERROR (status))
- status = result_add_char (dm, ']');
- }
-
- /* Clean up. */
- dyn_string_delete (number);
- RETURN_IF_ERROR (status);
- return STATUS_OK;
-}
+ switch (d_next_char (di))
+ {
+ case 'V':
+ di->expansion -= 5;
+ return d_make_comp (di, DEMANGLE_COMPONENT_VTABLE,
+ cplus_demangle_type (di), NULL);
+ case 'T':
+ di->expansion -= 10;
+ return d_make_comp (di, DEMANGLE_COMPONENT_VTT,
+ cplus_demangle_type (di), NULL);
+ case 'I':
+ return d_make_comp (di, DEMANGLE_COMPONENT_TYPEINFO,
+ cplus_demangle_type (di), NULL);
+ case 'S':
+ return d_make_comp (di, DEMANGLE_COMPONENT_TYPEINFO_NAME,
+ cplus_demangle_type (di), NULL);
-/* Demangles and emits a <v-offset>.
+ case 'h':
+ if (! d_call_offset (di, 'h'))
+ return NULL;
+ return d_make_comp (di, DEMANGLE_COMPONENT_THUNK,
+ d_encoding (di, 0), NULL);
- <v-offset> ::= <offset number> _ <virtual offset number>
- # virtual base override, with vcall offset */
+ case 'v':
+ if (! d_call_offset (di, 'v'))
+ return NULL;
+ return d_make_comp (di, DEMANGLE_COMPONENT_VIRTUAL_THUNK,
+ d_encoding (di, 0), NULL);
-static status_t
-demangle_v_offset (dm)
- demangling_t dm;
-{
- dyn_string_t number;
- status_t status = STATUS_OK;
+ case 'c':
+ if (! d_call_offset (di, '\0'))
+ return NULL;
+ if (! d_call_offset (di, '\0'))
+ return NULL;
+ return d_make_comp (di, DEMANGLE_COMPONENT_COVARIANT_THUNK,
+ d_encoding (di, 0), NULL);
- DEMANGLE_TRACE ("v-offset", dm);
+ case 'C':
+ {
+ struct demangle_component *derived_type;
+ long offset;
+ struct demangle_component *base_type;
+
+ derived_type = cplus_demangle_type (di);
+ offset = d_number (di);
+ if (offset < 0)
+ return NULL;
+ if (d_next_char (di) != '_')
+ return NULL;
+ base_type = cplus_demangle_type (di);
+ /* We don't display the offset. FIXME: We should display
+ it in verbose mode. */
+ di->expansion += 5;
+ return d_make_comp (di, DEMANGLE_COMPONENT_CONSTRUCTION_VTABLE,
+ base_type, derived_type);
+ }
- /* Demangle the offset. */
- number = dyn_string_new (4);
- if (number == NULL)
- return STATUS_ALLOCATION_FAILED;
- demangle_number_literally (dm, number, 10, 1);
+ case 'F':
+ return d_make_comp (di, DEMANGLE_COMPONENT_TYPEINFO_FN,
+ cplus_demangle_type (di), NULL);
+ case 'J':
+ return d_make_comp (di, DEMANGLE_COMPONENT_JAVA_CLASS,
+ cplus_demangle_type (di), NULL);
- /* Don't display the offset unless in verbose mode. */
- if (flag_verbose)
- {
- status = result_add (dm, " [v:");
- if (STATUS_NO_ERROR (status))
- status = result_add_string (dm, number);
- if (STATUS_NO_ERROR (status))
- result_add_char (dm, ',');
+ default:
+ return NULL;
+ }
}
- dyn_string_delete (number);
- RETURN_IF_ERROR (status);
-
- /* Demangle the separator. */
- RETURN_IF_ERROR (demangle_char (dm, '_'));
+ else if (c == 'G')
+ {
+ switch (d_next_char (di))
+ {
+ case 'V':
+ return d_make_comp (di, DEMANGLE_COMPONENT_GUARD, d_name (di), NULL);
- /* Demangle the vcall offset. */
- number = dyn_string_new (4);
- if (number == NULL)
- return STATUS_ALLOCATION_FAILED;
- demangle_number_literally (dm, number, 10, 1);
+ case 'R':
+ return d_make_comp (di, DEMANGLE_COMPONENT_REFTEMP, d_name (di),
+ NULL);
- /* Don't display the vcall offset unless in verbose mode. */
- if (flag_verbose)
- {
- status = result_add_string (dm, number);
- if (STATUS_NO_ERROR (status))
- status = result_add_char (dm, ']');
+ default:
+ return NULL;
+ }
}
- dyn_string_delete (number);
- RETURN_IF_ERROR (status);
-
- return STATUS_OK;
+ else
+ return NULL;
}
-/* Demangles and emits a <call-offset>.
+/* <call-offset> ::= h <nv-offset> _
+ ::= v <v-offset> _
- <call-offset> ::= h <nv-offset> _
- ::= v <v-offset> _ */
+ <nv-offset> ::= <(offset) number>
-static status_t
-demangle_call_offset (dm)
- demangling_t dm;
-{
- DEMANGLE_TRACE ("call-offset", dm);
+ <v-offset> ::= <(offset) number> _ <(virtual offset) number>
- switch (peek_char (dm))
- {
- case 'h':
- advance_char (dm);
- /* Demangle the offset. */
- RETURN_IF_ERROR (demangle_nv_offset (dm));
- /* Demangle the separator. */
- RETURN_IF_ERROR (demangle_char (dm, '_'));
- break;
+ The C parameter, if not '\0', is a character we just read which is
+ the start of the <call-offset>.
- case 'v':
- advance_char (dm);
- /* Demangle the offset. */
- RETURN_IF_ERROR (demangle_v_offset (dm));
- /* Demangle the separator. */
- RETURN_IF_ERROR (demangle_char (dm, '_'));
- break;
+ We don't display the offset information anywhere. FIXME: We should
+ display it in verbose mode. */
- default:
- return "Unrecognized <call-offset>.";
- }
+static int
+d_call_offset (di, c)
+ struct d_info *di;
+ int c;
+{
+ long offset;
+ long virtual_offset;
- return STATUS_OK;
-}
+ if (c == '\0')
+ c = d_next_char (di);
+
+ if (c == 'h')
+ offset = d_number (di);
+ else if (c == 'v')
+ {
+ offset = d_number (di);
+ if (d_next_char (di) != '_')
+ return 0;
+ virtual_offset = d_number (di);
+ }
+ else
+ return 0;
-/* Demangles and emits a <special-name>.
+ if (d_next_char (di) != '_')
+ return 0;
- <special-name> ::= GV <object name> # Guard variable
- ::= TV <type> # virtual table
- ::= TT <type> # VTT
- ::= TI <type> # typeinfo structure
- ::= TS <type> # typeinfo name
+ return 1;
+}
- Other relevant productions include thunks:
+/* <ctor-dtor-name> ::= C1
+ ::= C2
+ ::= C3
+ ::= D0
+ ::= D1
+ ::= D2
+*/
- <special-name> ::= T <call-offset> <base encoding>
- # base is the nominal target function of thunk
+static struct demangle_component *
+d_ctor_dtor_name (di)
+ struct d_info *di;
+{
+ if (di->last_name != NULL)
+ {
+ if (di->last_name->type == DEMANGLE_COMPONENT_NAME)
+ di->expansion += di->last_name->u.s_name.len;
+ else if (di->last_name->type == DEMANGLE_COMPONENT_SUB_STD)
+ di->expansion += di->last_name->u.s_string.len;
+ }
+ switch (d_next_char (di))
+ {
+ case 'C':
+ {
+ enum gnu_v3_ctor_kinds kind;
- <special-name> ::= Tc <call-offset> <call-offset> <base encoding>
- # base is the nominal target function of thunk
- # first call-offset is 'this' adjustment
- # second call-offset is result adjustment
+ switch (d_next_char (di))
+ {
+ case '1':
+ kind = gnu_v3_complete_object_ctor;
+ break;
+ case '2':
+ kind = gnu_v3_base_object_ctor;
+ break;
+ case '3':
+ kind = gnu_v3_complete_object_allocating_ctor;
+ break;
+ default:
+ return NULL;
+ }
+ return d_make_ctor (di, kind, di->last_name);
+ }
- where
+ case 'D':
+ {
+ enum gnu_v3_dtor_kinds kind;
- <call-offset> ::= h <nv-offset> _
- ::= v <v-offset> _
+ switch (d_next_char (di))
+ {
+ case '0':
+ kind = gnu_v3_deleting_dtor;
+ break;
+ case '1':
+ kind = gnu_v3_complete_object_dtor;
+ break;
+ case '2':
+ kind = gnu_v3_base_object_dtor;
+ break;
+ default:
+ return NULL;
+ }
+ return d_make_dtor (di, kind, di->last_name);
+ }
- Also demangles the special g++ manglings,
+ default:
+ return NULL;
+ }
+}
- <special-name> ::= TC <type> <offset number> _ <base type>
- # construction vtable
- ::= TF <type> # typeinfo function (old ABI only)
- ::= TJ <type> # java Class structure */
+/* <type> ::= <builtin-type>
+ ::= <function-type>
+ ::= <class-enum-type>
+ ::= <array-type>
+ ::= <pointer-to-member-type>
+ ::= <template-param>
+ ::= <template-template-param> <template-args>
+ ::= <substitution>
+ ::= <CV-qualifiers> <type>
+ ::= P <type>
+ ::= R <type>
+ ::= C <type>
+ ::= G <type>
+ ::= U <source-name> <type>
+
+ <builtin-type> ::= various one letter codes
+ ::= u <source-name>
+*/
-static status_t
-demangle_special_name (dm)
- demangling_t dm;
+CP_STATIC_IF_GLIBCPP_V3
+const struct demangle_builtin_type_info
+cplus_demangle_builtin_types[D_BUILTIN_TYPE_COUNT] =
{
- dyn_string_t number;
- int unused;
- char peek = peek_char (dm);
-
- DEMANGLE_TRACE ("special-name", dm);
+ /* a */ { NL ("signed char"), NL ("signed char"), D_PRINT_INT },
+ /* b */ { NL ("bool"), NL ("boolean"), D_PRINT_BOOL },
+ /* c */ { NL ("char"), NL ("byte"), D_PRINT_INT },
+ /* d */ { NL ("double"), NL ("double"), D_PRINT_DEFAULT },
+ /* e */ { NL ("long double"), NL ("long double"), D_PRINT_DEFAULT },
+ /* f */ { NL ("float"), NL ("float"), D_PRINT_DEFAULT },
+ /* g */ { NL ("__float128"), NL ("__float128"), D_PRINT_DEFAULT },
+ /* h */ { NL ("unsigned char"), NL ("unsigned char"), D_PRINT_INT },
+ /* i */ { NL ("int"), NL ("int"), D_PRINT_INT },
+ /* j */ { NL ("unsigned int"), NL ("unsigned"), D_PRINT_INT },
+ /* k */ { NULL, 0, NULL, 0, D_PRINT_DEFAULT },
+ /* l */ { NL ("long"), NL ("long"), D_PRINT_LONG },
+ /* m */ { NL ("unsigned long"), NL ("unsigned long"), D_PRINT_LONG },
+ /* n */ { NL ("__int128"), NL ("__int128"), D_PRINT_DEFAULT },
+ /* o */ { NL ("unsigned __int128"), NL ("unsigned __int128"), D_PRINT_DEFAULT },
+ /* p */ { NULL, 0, NULL, 0, D_PRINT_DEFAULT },
+ /* q */ { NULL, 0, NULL, 0, D_PRINT_DEFAULT },
+ /* r */ { NULL, 0, NULL, 0, D_PRINT_DEFAULT },
+ /* s */ { NL ("short"), NL ("short"), D_PRINT_INT },
+ /* t */ { NL ("unsigned short"), NL ("unsigned short"), D_PRINT_INT },
+ /* u */ { NULL, 0, NULL, 0, D_PRINT_DEFAULT },
+ /* v */ { NL ("void"), NL ("void"), D_PRINT_VOID },
+ /* w */ { NL ("wchar_t"), NL ("char"), D_PRINT_INT },
+ /* x */ { NL ("long long"), NL ("long"), D_PRINT_DEFAULT },
+ /* y */ { NL ("unsigned long long"), NL ("unsigned long long"), D_PRINT_DEFAULT },
+ /* z */ { NL ("..."), NL ("..."), D_PRINT_DEFAULT },
+};
- if (peek == 'G')
+CP_STATIC_IF_GLIBCPP_V3
+struct demangle_component *
+cplus_demangle_type (di)
+ struct d_info *di;
+{
+ char peek;
+ struct demangle_component *ret;
+ int can_subst;
+
+ /* The ABI specifies that when CV-qualifiers are used, the base type
+ is substitutable, and the fully qualified type is substitutable,
+ but the base type with a strict subset of the CV-qualifiers is
+ not substitutable. The natural recursive implementation of the
+ CV-qualifiers would cause subsets to be substitutable, so instead
+ we pull them all off now.
+
+ FIXME: The ABI says that order-insensitive vendor qualifiers
+ should be handled in the same way, but we have no way to tell
+ which vendor qualifiers are order-insensitive and which are
+ order-sensitive. So we just assume that they are all
+ order-sensitive. g++ 3.4 supports only one vendor qualifier,
+ __vector, and it treats it as order-sensitive when mangling
+ names. */
+
+ peek = d_peek_char (di);
+ if (peek == 'r' || peek == 'V' || peek == 'K')
{
- /* Consume the G. */
- advance_char (dm);
- switch (peek_char (dm))
- {
- case 'V':
- /* A guard variable name. */
- advance_char (dm);
- RETURN_IF_ERROR (result_add (dm, "guard variable for "));
- RETURN_IF_ERROR (demangle_name (dm, &unused));
- break;
+ struct demangle_component **pret;
- case 'R':
- /* A reference temporary. */
- advance_char (dm);
- RETURN_IF_ERROR (result_add (dm, "reference temporary for "));
- RETURN_IF_ERROR (demangle_name (dm, &unused));
- break;
-
- default:
- return "Unrecognized <special-name>.";
- }
+ pret = d_cv_qualifiers (di, &ret, 0);
+ if (pret == NULL)
+ return NULL;
+ *pret = cplus_demangle_type (di);
+ if (! d_add_substitution (di, ret))
+ return NULL;
+ return ret;
}
- else if (peek == 'T')
+
+ can_subst = 1;
+
+ switch (peek)
{
- status_t status = STATUS_OK;
+ case 'a': case 'b': case 'c': case 'd': case 'e': case 'f': case 'g':
+ case 'h': case 'i': case 'j': case 'l': case 'm': case 'n':
+ case 'o': case 's': case 't':
+ case 'v': case 'w': case 'x': case 'y': case 'z':
+ ret = d_make_builtin_type (di,
+ &cplus_demangle_builtin_types[peek - 'a']);
+ di->expansion += ret->u.s_builtin.type->len;
+ can_subst = 0;
+ d_advance (di, 1);
+ break;
- /* Other C++ implementation miscellania. Consume the T. */
- advance_char (dm);
+ case 'u':
+ d_advance (di, 1);
+ ret = d_make_comp (di, DEMANGLE_COMPONENT_VENDOR_TYPE,
+ d_source_name (di), NULL);
+ break;
- switch (peek_char (dm))
- {
- case 'V':
- /* Virtual table. */
- advance_char (dm);
- RETURN_IF_ERROR (result_add (dm, "vtable for "));
- RETURN_IF_ERROR (demangle_type (dm));
- break;
+ case 'F':
+ ret = d_function_type (di);
+ break;
- case 'T':
- /* VTT structure. */
- advance_char (dm);
- RETURN_IF_ERROR (result_add (dm, "VTT for "));
- RETURN_IF_ERROR (demangle_type (dm));
- break;
+ case '0': case '1': case '2': case '3': case '4':
+ case '5': case '6': case '7': case '8': case '9':
+ case 'N':
+ case 'Z':
+ ret = d_class_enum_type (di);
+ break;
- case 'I':
- /* Typeinfo structure. */
- advance_char (dm);
- RETURN_IF_ERROR (result_add (dm, "typeinfo for "));
- RETURN_IF_ERROR (demangle_type (dm));
- break;
+ case 'A':
+ ret = d_array_type (di);
+ break;
- case 'F':
- /* Typeinfo function. Used only in old ABI with new mangling. */
- advance_char (dm);
- RETURN_IF_ERROR (result_add (dm, "typeinfo fn for "));
- RETURN_IF_ERROR (demangle_type (dm));
- break;
+ case 'M':
+ ret = d_pointer_to_member_type (di);
+ break;
- case 'S':
- /* Character string containing type name, used in typeinfo. */
- advance_char (dm);
- RETURN_IF_ERROR (result_add (dm, "typeinfo name for "));
- RETURN_IF_ERROR (demangle_type (dm));
- break;
+ case 'T':
+ ret = d_template_param (di);
+ if (d_peek_char (di) == 'I')
+ {
+ /* This is <template-template-param> <template-args>. The
+ <template-template-param> part is a substitution
+ candidate. */
+ if (! d_add_substitution (di, ret))
+ return NULL;
+ ret = d_make_comp (di, DEMANGLE_COMPONENT_TEMPLATE, ret,
+ d_template_args (di));
+ }
+ break;
- case 'J':
- /* The java Class variable corresponding to a C++ class. */
- advance_char (dm);
- RETURN_IF_ERROR (result_add (dm, "java Class for "));
- RETURN_IF_ERROR (demangle_type (dm));
- break;
+ case 'S':
+ /* If this is a special substitution, then it is the start of
+ <class-enum-type>. */
+ {
+ char peek_next;
- case 'h':
- /* Non-virtual thunk. */
- advance_char (dm);
- RETURN_IF_ERROR (result_add (dm, "non-virtual thunk"));
- RETURN_IF_ERROR (demangle_nv_offset (dm));
- /* Demangle the separator. */
- RETURN_IF_ERROR (demangle_char (dm, '_'));
- /* Demangle and emit the target name and function type. */
- RETURN_IF_ERROR (result_add (dm, " to "));
- RETURN_IF_ERROR (demangle_encoding (dm));
- break;
+ peek_next = d_peek_next_char (di);
+ if (IS_DIGIT (peek_next)
+ || peek_next == '_'
+ || IS_UPPER (peek_next))
+ {
+ ret = d_substitution (di, 0);
+ /* The substituted name may have been a template name and
+ may be followed by tepmlate args. */
+ if (d_peek_char (di) == 'I')
+ ret = d_make_comp (di, DEMANGLE_COMPONENT_TEMPLATE, ret,
+ d_template_args (di));
+ else
+ can_subst = 0;
+ }
+ else
+ {
+ ret = d_class_enum_type (di);
+ /* If the substitution was a complete type, then it is not
+ a new substitution candidate. However, if the
+ substitution was followed by template arguments, then
+ the whole thing is a substitution candidate. */
+ if (ret != NULL && ret->type == DEMANGLE_COMPONENT_SUB_STD)
+ can_subst = 0;
+ }
+ }
+ break;
- case 'v':
- /* Virtual thunk. */
- advance_char (dm);
- RETURN_IF_ERROR (result_add (dm, "virtual thunk"));
- RETURN_IF_ERROR (demangle_v_offset (dm));
- /* Demangle the separator. */
- RETURN_IF_ERROR (demangle_char (dm, '_'));
- /* Demangle and emit the target function. */
- RETURN_IF_ERROR (result_add (dm, " to "));
- RETURN_IF_ERROR (demangle_encoding (dm));
- break;
+ case 'P':
+ d_advance (di, 1);
+ ret = d_make_comp (di, DEMANGLE_COMPONENT_POINTER,
+ cplus_demangle_type (di), NULL);
+ break;
- case 'c':
- /* Covariant return thunk. */
- advance_char (dm);
- RETURN_IF_ERROR (result_add (dm, "covariant return thunk"));
- RETURN_IF_ERROR (demangle_call_offset (dm));
- RETURN_IF_ERROR (demangle_call_offset (dm));
- /* Demangle and emit the target function. */
- RETURN_IF_ERROR (result_add (dm, " to "));
- RETURN_IF_ERROR (demangle_encoding (dm));
- break;
+ case 'R':
+ d_advance (di, 1);
+ ret = d_make_comp (di, DEMANGLE_COMPONENT_REFERENCE,
+ cplus_demangle_type (di), NULL);
+ break;
- case 'C':
- /* TC is a special g++ mangling for a construction vtable. */
- if (!flag_strict)
- {
- dyn_string_t derived_type;
+ case 'C':
+ d_advance (di, 1);
+ ret = d_make_comp (di, DEMANGLE_COMPONENT_COMPLEX,
+ cplus_demangle_type (di), NULL);
+ break;
- advance_char (dm);
- RETURN_IF_ERROR (result_add (dm, "construction vtable for "));
+ case 'G':
+ d_advance (di, 1);
+ ret = d_make_comp (di, DEMANGLE_COMPONENT_IMAGINARY,
+ cplus_demangle_type (di), NULL);
+ break;
- /* Demangle the derived type off to the side. */
- RETURN_IF_ERROR (result_push (dm));
- RETURN_IF_ERROR (demangle_type (dm));
- derived_type = (dyn_string_t) result_pop (dm);
+ case 'U':
+ d_advance (di, 1);
+ ret = d_source_name (di);
+ ret = d_make_comp (di, DEMANGLE_COMPONENT_VENDOR_TYPE_QUAL,
+ cplus_demangle_type (di), ret);
+ break;
- /* Demangle the offset. */
- number = dyn_string_new (4);
- if (number == NULL)
- {
- dyn_string_delete (derived_type);
- return STATUS_ALLOCATION_FAILED;
- }
- demangle_number_literally (dm, number, 10, 1);
- /* Demangle the underscore separator. */
- status = demangle_char (dm, '_');
-
- /* Demangle the base type. */
- if (STATUS_NO_ERROR (status))
- status = demangle_type (dm);
-
- /* Emit the derived type. */
- if (STATUS_NO_ERROR (status))
- status = result_add (dm, "-in-");
- if (STATUS_NO_ERROR (status))
- status = result_add_string (dm, derived_type);
- dyn_string_delete (derived_type);
-
- /* Don't display the offset unless in verbose mode. */
- if (flag_verbose)
- {
- status = result_add_char (dm, ' ');
- if (STATUS_NO_ERROR (status))
- result_add_string (dm, number);
- }
- dyn_string_delete (number);
- RETURN_IF_ERROR (status);
- break;
- }
- /* If flag_strict, fall through. */
+ default:
+ return NULL;
+ }
- default:
- return "Unrecognized <special-name>.";
- }
+ if (can_subst)
+ {
+ if (! d_add_substitution (di, ret))
+ return NULL;
}
- else
- return STATUS_ERROR;
- return STATUS_OK;
+ return ret;
}
-/* Demangles and emits a <ctor-dtor-name>.
-
- <ctor-dtor-name>
- ::= C1 # complete object (in-charge) ctor
- ::= C2 # base object (not-in-charge) ctor
- ::= C3 # complete object (in-charge) allocating ctor
- ::= D0 # deleting (in-charge) dtor
- ::= D1 # complete object (in-charge) dtor
- ::= D2 # base object (not-in-charge) dtor */
-
-static status_t
-demangle_ctor_dtor_name (dm)
- demangling_t dm;
-{
- static const char *const ctor_flavors[] =
- {
- "in-charge",
- "not-in-charge",
- "allocating"
- };
- static const char *const dtor_flavors[] =
- {
- "in-charge deleting",
- "in-charge",
- "not-in-charge"
- };
+/* <CV-qualifiers> ::= [r] [V] [K] */
- int flavor;
- char peek = peek_char (dm);
+static struct demangle_component **
+d_cv_qualifiers (di, pret, member_fn)
+ struct d_info *di;
+ struct demangle_component **pret;
+ int member_fn;
+{
+ char peek;
- DEMANGLE_TRACE ("ctor-dtor-name", dm);
-
- if (peek == 'C')
+ peek = d_peek_char (di);
+ while (peek == 'r' || peek == 'V' || peek == 'K')
{
- /* A constructor name. Consume the C. */
- advance_char (dm);
- flavor = next_char (dm);
- if (flavor < '1' || flavor > '3')
- return "Unrecognized constructor.";
- RETURN_IF_ERROR (result_add_string (dm, dm->last_source_name));
- switch (flavor)
+ enum demangle_component_type t;
+
+ d_advance (di, 1);
+ if (peek == 'r')
{
- case '1': dm->is_constructor = gnu_v3_complete_object_ctor;
- break;
- case '2': dm->is_constructor = gnu_v3_base_object_ctor;
- break;
- case '3': dm->is_constructor = gnu_v3_complete_object_allocating_ctor;
- break;
+ t = (member_fn
+ ? DEMANGLE_COMPONENT_RESTRICT_THIS
+ : DEMANGLE_COMPONENT_RESTRICT);
+ di->expansion += sizeof "restrict";
}
- /* Print the flavor of the constructor if in verbose mode. */
- if (flag_verbose)
+ else if (peek == 'V')
{
- RETURN_IF_ERROR (result_add (dm, "["));
- RETURN_IF_ERROR (result_add (dm, ctor_flavors[flavor - '1']));
- RETURN_IF_ERROR (result_add_char (dm, ']'));
+ t = (member_fn
+ ? DEMANGLE_COMPONENT_VOLATILE_THIS
+ : DEMANGLE_COMPONENT_VOLATILE);
+ di->expansion += sizeof "volatile";
}
- }
- else if (peek == 'D')
- {
- /* A destructor name. Consume the D. */
- advance_char (dm);
- flavor = next_char (dm);
- if (flavor < '0' || flavor > '2')
- return "Unrecognized destructor.";
- RETURN_IF_ERROR (result_add_char (dm, '~'));
- RETURN_IF_ERROR (result_add_string (dm, dm->last_source_name));
- switch (flavor)
- {
- case '0': dm->is_destructor = gnu_v3_deleting_dtor;
- break;
- case '1': dm->is_destructor = gnu_v3_complete_object_dtor;
- break;
- case '2': dm->is_destructor = gnu_v3_base_object_dtor;
- break;
- }
- /* Print the flavor of the destructor if in verbose mode. */
- if (flag_verbose)
+ else
{
- RETURN_IF_ERROR (result_add (dm, " ["));
- RETURN_IF_ERROR (result_add (dm, dtor_flavors[flavor - '0']));
- RETURN_IF_ERROR (result_add_char (dm, ']'));
+ t = (member_fn
+ ? DEMANGLE_COMPONENT_CONST_THIS
+ : DEMANGLE_COMPONENT_CONST);
+ di->expansion += sizeof "const";
}
+
+ *pret = d_make_comp (di, t, NULL, NULL);
+ if (*pret == NULL)
+ return NULL;
+ pret = &d_left (*pret);
+
+ peek = d_peek_char (di);
}
- else
- return STATUS_ERROR;
- return STATUS_OK;
+ return pret;
}
-/* Handle pointer, reference, and pointer-to-member cases for
- demangle_type. All consecutive `P's, `R's, and 'M's are joined to
- build a pointer/reference type. We snarf all these, plus the
- following <type>, all at once since we need to know whether we have
- a pointer to data or pointer to function to construct the right
- output syntax. C++'s pointer syntax is hairy.
-
- This function adds substitution candidates for every nested
- pointer/reference type it processes, including the outermost, final
- type, assuming the substitution starts at SUBSTITUTION_START in the
- demangling result. For example, if this function demangles
- `PP3Foo', it will add a substitution for `Foo', `Foo*', and
- `Foo**', in that order.
-
- *INSERT_POS is a quantity used internally, when this function calls
- itself recursively, to figure out where to insert pointer
- punctuation on the way up. On entry to this function, INSERT_POS
- should point to a temporary value, but that value need not be
- initialized.
-
- <type> ::= P <type>
- ::= R <type>
- ::= <pointer-to-member-type>
-
- <pointer-to-member-type> ::= M </class/ type> </member/ type> */
-
-static status_t
-demangle_type_ptr (dm, insert_pos, substitution_start)
- demangling_t dm;
- int *insert_pos;
- int substitution_start;
-{
- status_t status;
- int is_substitution_candidate = 1;
+/* <function-type> ::= F [Y] <bare-function-type> E */
- DEMANGLE_TRACE ("type*", dm);
+static struct demangle_component *
+d_function_type (di)
+ struct d_info *di;
+{
+ struct demangle_component *ret;
- /* Scan forward, collecting pointers and references into symbols,
- until we hit something else. Then emit the type. */
- switch (peek_char (dm))
+ if (d_next_char (di) != 'F')
+ return NULL;
+ if (d_peek_char (di) == 'Y')
{
- case 'P':
- /* A pointer. Snarf the `P'. */
- advance_char (dm);
- /* Demangle the underlying type. */
- RETURN_IF_ERROR (demangle_type_ptr (dm, insert_pos,
- substitution_start));
- /* Insert an asterisk where we're told to; it doesn't
- necessarily go at the end. If we're doing Java style output,
- there is no pointer symbol. */
- if (dm->style != DMGL_JAVA)
- RETURN_IF_ERROR (result_insert_char (dm, *insert_pos, '*'));
- /* The next (outermost) pointer or reference character should go
- after this one. */
- ++(*insert_pos);
- break;
+ /* Function has C linkage. We don't print this information.
+ FIXME: We should print it in verbose mode. */
+ d_advance (di, 1);
+ }
+ ret = d_bare_function_type (di, 1);
+ if (d_next_char (di) != 'E')
+ return NULL;
+ return ret;
+}
- case 'R':
- /* A reference. Snarf the `R'. */
- advance_char (dm);
- /* Demangle the underlying type. */
- RETURN_IF_ERROR (demangle_type_ptr (dm, insert_pos,
- substitution_start));
- /* Insert an ampersand where we're told to; it doesn't
- necessarily go at the end. */
- RETURN_IF_ERROR (result_insert_char (dm, *insert_pos, '&'));
- /* The next (outermost) pointer or reference character should go
- after this one. */
- ++(*insert_pos);
- break;
+/* <bare-function-type> ::= <type>+ */
- case 'M':
+static struct demangle_component *
+d_bare_function_type (di, has_return_type)
+ struct d_info *di;
+ int has_return_type;
+{
+ struct demangle_component *return_type;
+ struct demangle_component *tl;
+ struct demangle_component **ptl;
+
+ return_type = NULL;
+ tl = NULL;
+ ptl = &tl;
+ while (1)
{
- /* A pointer-to-member. */
- dyn_string_t class_type;
-
- /* Eat the 'M'. */
- advance_char (dm);
-
- /* Capture the type of which this is a pointer-to-member. */
- RETURN_IF_ERROR (result_push (dm));
- RETURN_IF_ERROR (demangle_type (dm));
- class_type = (dyn_string_t) result_pop (dm);
-
- if (peek_char (dm) == 'F')
- /* A pointer-to-member function. We want output along the
- lines of `void (C::*) (int, int)'. Demangle the function
- type, which would in this case give `void () (int, int)'
- and set *insert_pos to the spot between the first
- parentheses. */
- status = demangle_type_ptr (dm, insert_pos, substitution_start);
- else if (peek_char (dm) == 'A')
- /* A pointer-to-member array variable. We want output that
- looks like `int (Klass::*) [10]'. Demangle the array type
- as `int () [10]', and set *insert_pos to the spot between
- the parentheses. */
- status = demangle_array_type (dm, insert_pos);
+ char peek;
+ struct demangle_component *type;
+
+ peek = d_peek_char (di);
+ if (peek == '\0' || peek == 'E')
+ break;
+ type = cplus_demangle_type (di);
+ if (type == NULL)
+ return NULL;
+ if (has_return_type)
+ {
+ return_type = type;
+ has_return_type = 0;
+ }
else
- {
- /* A pointer-to-member variable. Demangle the type of the
- pointed-to member. */
- status = demangle_type (dm);
- /* Make it pretty. */
- if (STATUS_NO_ERROR (status)
- && !result_previous_char_is_space (dm))
- status = result_add_char (dm, ' ');
- /* The pointer-to-member notation (e.g. `C::*') follows the
- member's type. */
- *insert_pos = result_caret_pos (dm);
+ {
+ *ptl = d_make_comp (di, DEMANGLE_COMPONENT_ARGLIST, type, NULL);
+ if (*ptl == NULL)
+ return NULL;
+ ptl = &d_right (*ptl);
}
+ }
- /* Build the pointer-to-member notation. */
- if (STATUS_NO_ERROR (status))
- status = result_insert (dm, *insert_pos, "::*");
- if (STATUS_NO_ERROR (status))
- status = result_insert_string (dm, *insert_pos, class_type);
- /* There may be additional levels of (pointer or reference)
- indirection in this type. If so, the `*' and `&' should be
- added after the pointer-to-member notation (e.g. `C::*&' for
- a reference to a pointer-to-member of class C). */
- *insert_pos += dyn_string_length (class_type) + 3;
-
- /* Clean up. */
- dyn_string_delete (class_type);
-
- RETURN_IF_ERROR (status);
+ /* There should be at least one parameter type besides the optional
+ return type. A function which takes no arguments will have a
+ single parameter type void. */
+ if (tl == NULL)
+ return NULL;
+
+ /* If we have a single parameter type void, omit it. */
+ if (d_right (tl) == NULL
+ && d_left (tl)->type == DEMANGLE_COMPONENT_BUILTIN_TYPE
+ && d_left (tl)->u.s_builtin.type->print == D_PRINT_VOID)
+ {
+ di->expansion -= d_left (tl)->u.s_builtin.type->len;
+ tl = NULL;
}
- break;
- case 'F':
- /* Ooh, tricky, a pointer-to-function. When we demangle the
- function type, the return type should go at the very
- beginning. */
- *insert_pos = result_caret_pos (dm);
- /* The parentheses indicate this is a function pointer or
- reference type. */
- RETURN_IF_ERROR (result_add (dm, "()"));
- /* Now demangle the function type. The return type will be
- inserted before the `()', and the argument list will go after
- it. */
- RETURN_IF_ERROR (demangle_function_type (dm, insert_pos));
- /* We should now have something along the lines of
- `void () (int, int)'. The pointer or reference characters
- have to inside the first set of parentheses. *insert_pos has
- already been updated to point past the end of the return
- type. Move it one character over so it points inside the
- `()'. */
- ++(*insert_pos);
- break;
+ return d_make_comp (di, DEMANGLE_COMPONENT_FUNCTION_TYPE, return_type, tl);
+}
- case 'A':
- /* An array pointer or reference. demangle_array_type will figure
- out where the asterisks and ampersands go. */
- RETURN_IF_ERROR (demangle_array_type (dm, insert_pos));
- break;
+/* <class-enum-type> ::= <name> */
- default:
- /* No more pointer or reference tokens; this is therefore a
- pointer to data. Finish up by demangling the underlying
- type. */
- RETURN_IF_ERROR (demangle_type (dm));
- /* The pointer or reference characters follow the underlying
- type, as in `int*&'. */
- *insert_pos = result_caret_pos (dm);
- /* Because of the production <type> ::= <substitution>,
- demangle_type will already have added the underlying type as
- a substitution candidate. Don't do it again. */
- is_substitution_candidate = 0;
- break;
- }
-
- if (is_substitution_candidate)
- RETURN_IF_ERROR (substitution_add (dm, substitution_start, 0));
-
- return STATUS_OK;
+static struct demangle_component *
+d_class_enum_type (di)
+ struct d_info *di;
+{
+ return d_name (di);
}
-/* Demangles and emits a <type>.
-
- <type> ::= <builtin-type>
- ::= <function-type>
- ::= <class-enum-type>
- ::= <array-type>
- ::= <pointer-to-member-type>
- ::= <template-param>
- ::= <template-template-param> <template-args>
- ::= <CV-qualifiers> <type>
- ::= P <type> # pointer-to
- ::= R <type> # reference-to
- ::= C <type> # complex pair (C 2000)
- ::= G <type> # imaginary (C 2000)
- ::= U <source-name> <type> # vendor extended type qualifier
- ::= <substitution> */
-
-static status_t
-demangle_type (dm)
- demangling_t dm;
+/* <array-type> ::= A <(positive dimension) number> _ <(element) type>
+ ::= A [<(dimension) expression>] _ <(element) type>
+*/
+
+static struct demangle_component *
+d_array_type (di)
+ struct d_info *di;
{
- int start = substitution_start (dm);
- char peek = peek_char (dm);
- char peek_next;
- int encode_return_type = 0;
- template_arg_list_t old_arg_list = current_template_arg_list (dm);
- int insert_pos;
-
- /* A <type> can be a <substitution>; therefore, this <type> is a
- substitution candidate unless a special condition holds (see
- below). */
- int is_substitution_candidate = 1;
-
- DEMANGLE_TRACE ("type", dm);
-
- /* A <class-enum-type> can start with a digit (a <source-name>), an
- N (a <nested-name>), or a Z (a <local-name>). */
- if (IS_DIGIT ((unsigned char) peek) || peek == 'N' || peek == 'Z')
- RETURN_IF_ERROR (demangle_class_enum_type (dm, &encode_return_type));
- /* Lower-case letters begin <builtin-type>s, except for `r', which
- denotes restrict. */
- else if (peek >= 'a' && peek <= 'z' && peek != 'r')
+ char peek;
+ struct demangle_component *dim;
+
+ if (d_next_char (di) != 'A')
+ return NULL;
+
+ peek = d_peek_char (di);
+ if (peek == '_')
+ dim = NULL;
+ else if (IS_DIGIT (peek))
{
- RETURN_IF_ERROR (demangle_builtin_type (dm));
- /* Built-in types are not substitution candidates. */
- is_substitution_candidate = 0;
- }
- else
- switch (peek)
- {
- case 'r':
- case 'V':
- case 'K':
- /* CV-qualifiers (including restrict). We have to demangle
- them off to the side, since C++ syntax puts them in a funny
- place for qualified pointer and reference types. */
+ const char *s;
+
+ s = d_str (di);
+ do
{
- status_t status;
- dyn_string_t cv_qualifiers = dyn_string_new (24);
- int old_caret_position = result_get_caret (dm);
-
- if (cv_qualifiers == NULL)
- return STATUS_ALLOCATION_FAILED;
-
- /* Decode all adjacent CV qualifiers. */
- demangle_CV_qualifiers (dm, cv_qualifiers);
- /* Emit them, and shift the caret left so that the
- underlying type will be emitted before the qualifiers. */
- status = result_add_string (dm, cv_qualifiers);
- result_shift_caret (dm, -dyn_string_length (cv_qualifiers));
- /* Clean up. */
- dyn_string_delete (cv_qualifiers);
- RETURN_IF_ERROR (status);
- /* Also prepend a blank, if needed. */
- RETURN_IF_ERROR (result_add_char (dm, ' '));
- result_shift_caret (dm, -1);
-
- /* Demangle the underlying type. It will be emitted before
- the CV qualifiers, since we moved the caret. */
- RETURN_IF_ERROR (demangle_type (dm));
-
- /* Put the caret back where it was previously. */
- result_set_caret (dm, old_caret_position);
+ d_advance (di, 1);
+ peek = d_peek_char (di);
}
- break;
-
- case 'F':
- return "Non-pointer or -reference function type.";
+ while (IS_DIGIT (peek));
+ dim = d_make_name (di, s, d_str (di) - s);
+ if (dim == NULL)
+ return NULL;
+ }
+ else
+ {
+ dim = d_expression (di);
+ if (dim == NULL)
+ return NULL;
+ }
- case 'A':
- RETURN_IF_ERROR (demangle_array_type (dm, NULL));
- break;
+ if (d_next_char (di) != '_')
+ return NULL;
- case 'T':
- /* It's either a <template-param> or a
- <template-template-param>. In either case, demangle the
- `T' token first. */
- RETURN_IF_ERROR (demangle_template_param (dm));
+ return d_make_comp (di, DEMANGLE_COMPONENT_ARRAY_TYPE, dim,
+ cplus_demangle_type (di));
+}
- /* Check for a template argument list; if one is found, it's a
- <template-template-param> ::= <template-param>
- ::= <substitution> */
- if (peek_char (dm) == 'I')
- {
- /* Add a substitution candidate. The template parameter
- `T' token is a substitution candidate by itself,
- without the template argument list. */
- RETURN_IF_ERROR (substitution_add (dm, start, encode_return_type));
-
- /* Now demangle the template argument list. */
- RETURN_IF_ERROR (demangle_template_args (dm));
- /* The entire type, including the template template
- parameter and its argument list, will be added as a
- substitution candidate below. */
- }
+/* <pointer-to-member-type> ::= M <(class) type> <(member) type> */
- break;
+static struct demangle_component *
+d_pointer_to_member_type (di)
+ struct d_info *di;
+{
+ struct demangle_component *cl;
+ struct demangle_component *mem;
+ struct demangle_component **pmem;
- case 'S':
- /* First check if this is a special substitution. If it is,
- this is a <class-enum-type>. Special substitutions have a
- letter following the `S'; other substitutions have a digit
- or underscore. */
- peek_next = peek_char_next (dm);
- if (IS_DIGIT (peek_next) || peek_next == '_')
- {
- RETURN_IF_ERROR (demangle_substitution (dm, &encode_return_type));
-
- /* The substituted name may have been a template name.
- Check if template arguments follow, and if so, demangle
- them. */
- if (peek_char (dm) == 'I')
- RETURN_IF_ERROR (demangle_template_args (dm));
- else
- /* A substitution token is not itself a substitution
- candidate. (However, if the substituted template is
- instantiated, the resulting type is.) */
- is_substitution_candidate = 0;
- }
- else
- {
- /* Now some trickiness. We have a special substitution
- here. Often, the special substitution provides the
- name of a template that's subsequently instantiated,
- for instance `SaIcE' => std::allocator<char>. In these
- cases we need to add a substitution candidate for the
- entire <class-enum-type> and thus don't want to clear
- the is_substitution_candidate flag.
-
- However, it's possible that what we have here is a
- substitution token representing an entire type, such as
- `Ss' => std::string. In this case, we mustn't add a
- new substitution candidate for this substitution token.
- To detect this case, remember where the start of the
- substitution token is. */
- const char *next = dm->next;
- /* Now demangle the <class-enum-type>. */
- RETURN_IF_ERROR
- (demangle_class_enum_type (dm, &encode_return_type));
- /* If all that was just demangled is the two-character
- special substitution token, supress the addition of a
- new candidate for it. */
- if (dm->next == next + 2)
- is_substitution_candidate = 0;
- }
+ if (d_next_char (di) != 'M')
+ return NULL;
- break;
+ cl = cplus_demangle_type (di);
+
+ /* The ABI specifies that any type can be a substitution source, and
+ that M is followed by two types, and that when a CV-qualified
+ type is seen both the base type and the CV-qualified types are
+ substitution sources. The ABI also specifies that for a pointer
+ to a CV-qualified member function, the qualifiers are attached to
+ the second type. Given the grammar, a plain reading of the ABI
+ suggests that both the CV-qualified member function and the
+ non-qualified member function are substitution sources. However,
+ g++ does not work that way. g++ treats only the CV-qualified
+ member function as a substitution source. FIXME. So to work
+ with g++, we need to pull off the CV-qualifiers here, in order to
+ avoid calling add_substitution() in cplus_demangle_type(). */
+
+ pmem = d_cv_qualifiers (di, &mem, 1);
+ if (pmem == NULL)
+ return NULL;
+ *pmem = cplus_demangle_type (di);
- case 'P':
- case 'R':
- case 'M':
- RETURN_IF_ERROR (demangle_type_ptr (dm, &insert_pos, start));
- /* demangle_type_ptr adds all applicable substitution
- candidates. */
- is_substitution_candidate = 0;
- break;
+ return d_make_comp (di, DEMANGLE_COMPONENT_PTRMEM_TYPE, cl, mem);
+}
- case 'C':
- /* A C99 complex type. */
- RETURN_IF_ERROR (result_add (dm, "complex "));
- advance_char (dm);
- RETURN_IF_ERROR (demangle_type (dm));
- break;
+/* <template-param> ::= T_
+ ::= T <(parameter-2 non-negative) number> _
+*/
- case 'G':
- /* A C99 imaginary type. */
- RETURN_IF_ERROR (result_add (dm, "imaginary "));
- advance_char (dm);
- RETURN_IF_ERROR (demangle_type (dm));
- break;
+static struct demangle_component *
+d_template_param (di)
+ struct d_info *di;
+{
+ long param;
- case 'U':
- /* Vendor-extended type qualifier. */
- advance_char (dm);
- RETURN_IF_ERROR (demangle_source_name (dm));
- RETURN_IF_ERROR (result_add_char (dm, ' '));
- RETURN_IF_ERROR (demangle_type (dm));
- break;
+ if (d_next_char (di) != 'T')
+ return NULL;
- default:
- return "Unexpected character in <type>.";
- }
+ if (d_peek_char (di) == '_')
+ param = 0;
+ else
+ {
+ param = d_number (di);
+ if (param < 0)
+ return NULL;
+ param += 1;
+ }
- if (is_substitution_candidate)
- /* Add a new substitution for the type. If this type was a
- <template-param>, pass its index since from the point of
- substitutions; a <template-param> token is a substitution
- candidate distinct from the type that is substituted for it. */
- RETURN_IF_ERROR (substitution_add (dm, start, encode_return_type));
+ if (d_next_char (di) != '_')
+ return NULL;
- /* Pop off template argument lists added during mangling of this
- type. */
- pop_to_template_arg_list (dm, old_arg_list);
+ ++di->did_subs;
- return STATUS_OK;
+ return d_make_template_param (di, param);
}
-/* C++ source names of builtin types, indexed by the mangled code
- letter's position in the alphabet ('a' -> 0, 'b' -> 1, etc). */
-static const char *const builtin_type_names[26] =
-{
- "signed char", /* a */
- "bool", /* b */
- "char", /* c */
- "double", /* d */
- "long double", /* e */
- "float", /* f */
- "__float128", /* g */
- "unsigned char", /* h */
- "int", /* i */
- "unsigned", /* j */
- NULL, /* k */
- "long", /* l */
- "unsigned long", /* m */
- "__int128", /* n */
- "unsigned __int128", /* o */
- NULL, /* p */
- NULL, /* q */
- NULL, /* r */
- "short", /* s */
- "unsigned short", /* t */
- NULL, /* u */
- "void", /* v */
- "wchar_t", /* w */
- "long long", /* x */
- "unsigned long long", /* y */
- "..." /* z */
-};
-
-/* Java source names of builtin types. Types that arn't valid in Java
- are also included here - we don't fail if someone attempts to demangle a
- C++ symbol in Java style. */
-static const char *const java_builtin_type_names[26] =
-{
- "signed char", /* a */
- "boolean", /* C++ "bool" */ /* b */
- "byte", /* C++ "char" */ /* c */
- "double", /* d */
- "long double", /* e */
- "float", /* f */
- "__float128", /* g */
- "unsigned char", /* h */
- "int", /* i */
- "unsigned", /* j */
- NULL, /* k */
- "long", /* l */
- "unsigned long", /* m */
- "__int128", /* n */
- "unsigned __int128", /* o */
- NULL, /* p */
- NULL, /* q */
- NULL, /* r */
- "short", /* s */
- "unsigned short", /* t */
- NULL, /* u */
- "void", /* v */
- "char", /* C++ "wchar_t" */ /* w */
- "long", /* C++ "long long" */ /* x */
- "unsigned long long", /* y */
- "..." /* z */
-};
+/* <template-args> ::= I <template-arg>+ E */
-/* Demangles and emits a <builtin-type>.
-
- <builtin-type> ::= v # void
- ::= w # wchar_t
- ::= b # bool
- ::= c # char
- ::= a # signed char
- ::= h # unsigned char
- ::= s # short
- ::= t # unsigned short
- ::= i # int
- ::= j # unsigned int
- ::= l # long
- ::= m # unsigned long
- ::= x # long long, __int64
- ::= y # unsigned long long, __int64
- ::= n # __int128
- ::= o # unsigned __int128
- ::= f # float
- ::= d # double
- ::= e # long double, __float80
- ::= g # __float128
- ::= z # ellipsis
- ::= u <source-name> # vendor extended type */
-
-static status_t
-demangle_builtin_type (dm)
- demangling_t dm;
+static struct demangle_component *
+d_template_args (di)
+ struct d_info *di;
{
+ struct demangle_component *hold_last_name;
+ struct demangle_component *al;
+ struct demangle_component **pal;
- char code = peek_char (dm);
+ /* Preserve the last name we saw--don't let the template arguments
+ clobber it, as that would give us the wrong name for a subsequent
+ constructor or destructor. */
+ hold_last_name = di->last_name;
- DEMANGLE_TRACE ("builtin-type", dm);
+ if (d_next_char (di) != 'I')
+ return NULL;
- if (code == 'u')
+ al = NULL;
+ pal = &al;
+ while (1)
{
- advance_char (dm);
- RETURN_IF_ERROR (demangle_source_name (dm));
- return STATUS_OK;
+ struct demangle_component *a;
+
+ a = d_template_arg (di);
+ if (a == NULL)
+ return NULL;
+
+ *pal = d_make_comp (di, DEMANGLE_COMPONENT_TEMPLATE_ARGLIST, a, NULL);
+ if (*pal == NULL)
+ return NULL;
+ pal = &d_right (*pal);
+
+ if (d_peek_char (di) == 'E')
+ {
+ d_advance (di, 1);
+ break;
+ }
}
- else if (code >= 'a' && code <= 'z')
+
+ di->last_name = hold_last_name;
+
+ return al;
+}
+
+/* <template-arg> ::= <type>
+ ::= X <expression> E
+ ::= <expr-primary>
+*/
+
+static struct demangle_component *
+d_template_arg (di)
+ struct d_info *di;
+{
+ struct demangle_component *ret;
+
+ switch (d_peek_char (di))
{
- const char *type_name;
- /* Java uses different names for some built-in types. */
- if (dm->style == DMGL_JAVA)
- type_name = java_builtin_type_names[code - 'a'];
- else
- type_name = builtin_type_names[code - 'a'];
- if (type_name == NULL)
- return "Unrecognized <builtin-type> code.";
+ case 'X':
+ d_advance (di, 1);
+ ret = d_expression (di);
+ if (d_next_char (di) != 'E')
+ return NULL;
+ return ret;
- RETURN_IF_ERROR (result_add (dm, type_name));
- advance_char (dm);
- return STATUS_OK;
+ case 'L':
+ return d_expr_primary (di);
+
+ default:
+ return cplus_demangle_type (di);
}
- else
- return "Non-alphabetic <builtin-type> code.";
}
-/* Demangles all consecutive CV-qualifiers (const, volatile, and
- restrict) at the current position. The qualifiers are appended to
- QUALIFIERS. Returns STATUS_OK. */
+/* <expression> ::= <(unary) operator-name> <expression>
+ ::= <(binary) operator-name> <expression> <expression>
+ ::= <(trinary) operator-name> <expression> <expression> <expression>
+ ::= st <type>
+ ::= <template-param>
+ ::= sr <type> <unqualified-name>
+ ::= sr <type> <unqualified-name> <template-args>
+ ::= <expr-primary>
+*/
-static status_t
-demangle_CV_qualifiers (dm, qualifiers)
- demangling_t dm;
- dyn_string_t qualifiers;
+static struct demangle_component *
+d_expression (di)
+ struct d_info *di;
{
- DEMANGLE_TRACE ("CV-qualifiers", dm);
+ char peek;
- while (1)
+ peek = d_peek_char (di);
+ if (peek == 'L')
+ return d_expr_primary (di);
+ else if (peek == 'T')
+ return d_template_param (di);
+ else if (peek == 's' && d_peek_next_char (di) == 'r')
{
- switch (peek_char (dm))
+ struct demangle_component *type;
+ struct demangle_component *name;
+
+ d_advance (di, 2);
+ type = cplus_demangle_type (di);
+ name = d_unqualified_name (di);
+ if (d_peek_char (di) != 'I')
+ return d_make_comp (di, DEMANGLE_COMPONENT_QUAL_NAME, type, name);
+ else
+ return d_make_comp (di, DEMANGLE_COMPONENT_QUAL_NAME, type,
+ d_make_comp (di, DEMANGLE_COMPONENT_TEMPLATE, name,
+ d_template_args (di)));
+ }
+ else
+ {
+ struct demangle_component *op;
+ int args;
+
+ op = d_operator_name (di);
+ if (op == NULL)
+ return NULL;
+
+ if (op->type == DEMANGLE_COMPONENT_OPERATOR)
+ di->expansion += op->u.s_operator.op->len - 2;
+
+ if (op->type == DEMANGLE_COMPONENT_OPERATOR
+ && strcmp (op->u.s_operator.op->code, "st") == 0)
+ return d_make_comp (di, DEMANGLE_COMPONENT_UNARY, op,
+ cplus_demangle_type (di));
+
+ switch (op->type)
{
- case 'r':
- if (!dyn_string_append_space (qualifiers))
- return STATUS_ALLOCATION_FAILED;
- if (!dyn_string_append_cstr (qualifiers, "restrict"))
- return STATUS_ALLOCATION_FAILED;
+ default:
+ return NULL;
+ case DEMANGLE_COMPONENT_OPERATOR:
+ args = op->u.s_operator.op->args;
break;
-
- case 'V':
- if (!dyn_string_append_space (qualifiers))
- return STATUS_ALLOCATION_FAILED;
- if (!dyn_string_append_cstr (qualifiers, "volatile"))
- return STATUS_ALLOCATION_FAILED;
+ case DEMANGLE_COMPONENT_EXTENDED_OPERATOR:
+ args = op->u.s_extended_operator.args;
break;
-
- case 'K':
- if (!dyn_string_append_space (qualifiers))
- return STATUS_ALLOCATION_FAILED;
- if (!dyn_string_append_cstr (qualifiers, "const"))
- return STATUS_ALLOCATION_FAILED;
+ case DEMANGLE_COMPONENT_CAST:
+ args = 1;
break;
+ }
+ switch (args)
+ {
+ case 1:
+ return d_make_comp (di, DEMANGLE_COMPONENT_UNARY, op,
+ d_expression (di));
+ case 2:
+ {
+ struct demangle_component *left;
+
+ left = d_expression (di);
+ return d_make_comp (di, DEMANGLE_COMPONENT_BINARY, op,
+ d_make_comp (di,
+ DEMANGLE_COMPONENT_BINARY_ARGS,
+ left,
+ d_expression (di)));
+ }
+ case 3:
+ {
+ struct demangle_component *first;
+ struct demangle_component *second;
+
+ first = d_expression (di);
+ second = d_expression (di);
+ return d_make_comp (di, DEMANGLE_COMPONENT_TRINARY, op,
+ d_make_comp (di,
+ DEMANGLE_COMPONENT_TRINARY_ARG1,
+ first,
+ d_make_comp (di,
+ DEMANGLE_COMPONENT_TRINARY_ARG2,
+ second,
+ d_expression (di))));
+ }
default:
- return STATUS_OK;
+ return NULL;
}
-
- advance_char (dm);
}
}
-/* Demangles and emits a <function-type>. *FUNCTION_NAME_POS is the
- position in the result string of the start of the function
- identifier, at which the function's return type will be inserted;
- *FUNCTION_NAME_POS is updated to position past the end of the
- function's return type.
+/* <expr-primary> ::= L <type> <(value) number> E
+ ::= L <type> <(value) float> E
+ ::= L <mangled-name> E
+*/
- <function-type> ::= F [Y] <bare-function-type> E */
+static struct demangle_component *
+d_expr_primary (di)
+ struct d_info *di;
+{
+ struct demangle_component *ret;
-static status_t
-demangle_function_type (dm, function_name_pos)
- demangling_t dm;
- int *function_name_pos;
+ if (d_next_char (di) != 'L')
+ return NULL;
+ if (d_peek_char (di) == '_')
+ ret = cplus_demangle_mangled_name (di, 0);
+ else
+ {
+ struct demangle_component *type;
+ enum demangle_component_type t;
+ const char *s;
+
+ type = cplus_demangle_type (di);
+
+ /* If we have a type we know how to print, we aren't going to
+ print the type name itself. */
+ if (type->type == DEMANGLE_COMPONENT_BUILTIN_TYPE
+ && type->u.s_builtin.type->print != D_PRINT_DEFAULT)
+ di->expansion -= type->u.s_builtin.type->len;
+
+ /* Rather than try to interpret the literal value, we just
+ collect it as a string. Note that it's possible to have a
+ floating point literal here. The ABI specifies that the
+ format of such literals is machine independent. That's fine,
+ but what's not fine is that versions of g++ up to 3.2 with
+ -fabi-version=1 used upper case letters in the hex constant,
+ and dumped out gcc's internal representation. That makes it
+ hard to tell where the constant ends, and hard to dump the
+ constant in any readable form anyhow. We don't attempt to
+ handle these cases. */
+
+ t = DEMANGLE_COMPONENT_LITERAL;
+ if (d_peek_char (di) == 'n')
+ {
+ t = DEMANGLE_COMPONENT_LITERAL_NEG;
+ d_advance (di, 1);
+ }
+ s = d_str (di);
+ while (d_peek_char (di) != 'E')
+ d_advance (di, 1);
+ ret = d_make_comp (di, t, type, d_make_name (di, s, d_str (di) - s));
+ }
+ if (d_next_char (di) != 'E')
+ return NULL;
+ return ret;
+}
+
+/* <local-name> ::= Z <(function) encoding> E <(entity) name> [<discriminator>]
+ ::= Z <(function) encoding> E s [<discriminator>]
+*/
+
+static struct demangle_component *
+d_local_name (di)
+ struct d_info *di;
{
- DEMANGLE_TRACE ("function-type", dm);
- RETURN_IF_ERROR (demangle_char (dm, 'F'));
- if (peek_char (dm) == 'Y')
+ struct demangle_component *function;
+
+ if (d_next_char (di) != 'Z')
+ return NULL;
+
+ function = d_encoding (di, 0);
+
+ if (d_next_char (di) != 'E')
+ return NULL;
+
+ if (d_peek_char (di) == 's')
{
- /* Indicate this function has C linkage if in verbose mode. */
- if (flag_verbose)
- RETURN_IF_ERROR (result_add (dm, " [extern \"C\"] "));
- advance_char (dm);
+ d_advance (di, 1);
+ if (! d_discriminator (di))
+ return NULL;
+ return d_make_comp (di, DEMANGLE_COMPONENT_LOCAL_NAME, function,
+ d_make_name (di, "string literal",
+ sizeof "string literal" - 1));
}
- RETURN_IF_ERROR (demangle_bare_function_type (dm, function_name_pos));
- RETURN_IF_ERROR (demangle_char (dm, 'E'));
- return STATUS_OK;
+ else
+ {
+ struct demangle_component *name;
+
+ name = d_name (di);
+ if (! d_discriminator (di))
+ return NULL;
+ return d_make_comp (di, DEMANGLE_COMPONENT_LOCAL_NAME, function, name);
+ }
+}
+
+/* <discriminator> ::= _ <(non-negative) number>
+
+ We demangle the discriminator, but we don't print it out. FIXME:
+ We should print it out in verbose mode. */
+
+static int
+d_discriminator (di)
+ struct d_info *di;
+{
+ long discrim;
+
+ if (d_peek_char (di) != '_')
+ return 1;
+ d_advance (di, 1);
+ discrim = d_number (di);
+ if (discrim < 0)
+ return 0;
+ return 1;
+}
+
+/* Add a new substitution. */
+
+static int
+d_add_substitution (di, dc)
+ struct d_info *di;
+ struct demangle_component *dc;
+{
+ if (dc == NULL)
+ return 0;
+ if (di->next_sub >= di->num_subs)
+ return 0;
+ di->subs[di->next_sub] = dc;
+ ++di->next_sub;
+ return 1;
}
-/* Demangles and emits a <bare-function-type>. RETURN_TYPE_POS is the
- position in the result string at which the function return type
- should be inserted. If RETURN_TYPE_POS is BFT_NO_RETURN_TYPE, the
- function's return type is assumed not to be encoded.
+/* <substitution> ::= S <seq-id> _
+ ::= S_
+ ::= St
+ ::= Sa
+ ::= Sb
+ ::= Ss
+ ::= Si
+ ::= So
+ ::= Sd
+
+ If PREFIX is non-zero, then this type is being used as a prefix in
+ a qualified name. In this case, for the standard substitutions, we
+ need to check whether we are being used as a prefix for a
+ constructor or destructor, and return a full template name.
+ Otherwise we will get something like std::iostream::~iostream()
+ which does not correspond particularly well to any function which
+ actually appears in the source.
+*/
- <bare-function-type> ::= <signature type>+ */
+static const struct d_standard_sub_info standard_subs[] =
+{
+ { 't', NL ("std"),
+ NL ("std"),
+ NULL, 0 },
+ { 'a', NL ("std::allocator"),
+ NL ("std::allocator"),
+ NL ("allocator") },
+ { 'b', NL ("std::basic_string"),
+ NL ("std::basic_string"),
+ NL ("basic_string") },
+ { 's', NL ("std::string"),
+ NL ("std::basic_string<char, std::char_traits<char>, std::allocator<char> >"),
+ NL ("basic_string") },
+ { 'i', NL ("std::istream"),
+ NL ("std::basic_istream<char, std::char_traits<char> >"),
+ NL ("basic_istream") },
+ { 'o', NL ("std::ostream"),
+ NL ("std::basic_ostream<char, std::char_traits<char> >"),
+ NL ("basic_ostream") },
+ { 'd', NL ("std::iostream"),
+ NL ("std::basic_iostream<char, std::char_traits<char> >"),
+ NL ("basic_iostream") }
+};
-static status_t
-demangle_bare_function_type (dm, return_type_pos)
- demangling_t dm;
- int *return_type_pos;
+static struct demangle_component *
+d_substitution (di, prefix)
+ struct d_info *di;
+ int prefix;
{
- /* Sequence is the index of the current function parameter, counting
- from zero. The value -1 denotes the return type. */
- int sequence =
- (return_type_pos == BFT_NO_RETURN_TYPE ? 0 : -1);
+ char c;
- DEMANGLE_TRACE ("bare-function-type", dm);
+ if (d_next_char (di) != 'S')
+ return NULL;
- RETURN_IF_ERROR (result_add_char (dm, '('));
- while (!end_of_name_p (dm) && peek_char (dm) != 'E')
+ c = d_next_char (di);
+ if (c == '_' || IS_DIGIT (c) || IS_UPPER (c))
{
- if (sequence == -1)
- /* We're decoding the function's return type. */
+ int id;
+
+ id = 0;
+ if (c != '_')
{
- dyn_string_t return_type;
- status_t status = STATUS_OK;
-
- /* Decode the return type off to the side. */
- RETURN_IF_ERROR (result_push (dm));
- RETURN_IF_ERROR (demangle_type (dm));
- return_type = (dyn_string_t) result_pop (dm);
-
- /* Add a space to the end of the type. Insert the return
- type where we've been asked to. */
- if (!dyn_string_append_space (return_type))
- status = STATUS_ALLOCATION_FAILED;
- if (STATUS_NO_ERROR (status))
+ do
{
- if (!dyn_string_insert (result_string (dm), *return_type_pos,
- return_type))
- status = STATUS_ALLOCATION_FAILED;
+ if (IS_DIGIT (c))
+ id = id * 36 + c - '0';
+ else if (IS_UPPER (c))
+ id = id * 36 + c - 'A' + 10;
else
- *return_type_pos += dyn_string_length (return_type);
+ return NULL;
+ c = d_next_char (di);
}
+ while (c != '_');
- dyn_string_delete (return_type);
- RETURN_IF_ERROR (status);
+ ++id;
}
- else
+
+ if (id >= di->next_sub)
+ return NULL;
+
+ ++di->did_subs;
+
+ return di->subs[id];
+ }
+ else
+ {
+ int verbose;
+ const struct d_standard_sub_info *p;
+ const struct d_standard_sub_info *pend;
+
+ verbose = (di->options & DMGL_VERBOSE) != 0;
+ if (! verbose && prefix)
{
- /* Skip `void' parameter types. One should only occur as
- the only type in a parameter list; in that case, we want
- to print `foo ()' instead of `foo (void)'. */
- if (peek_char (dm) == 'v')
- /* Consume the v. */
- advance_char (dm);
- else
+ char peek;
+
+ peek = d_peek_char (di);
+ if (peek == 'C' || peek == 'D')
+ verbose = 1;
+ }
+
+ pend = (&standard_subs[0]
+ + sizeof standard_subs / sizeof standard_subs[0]);
+ for (p = &standard_subs[0]; p < pend; ++p)
+ {
+ if (c == p->code)
{
- /* Separate parameter types by commas. */
- if (sequence > 0)
- RETURN_IF_ERROR (result_add (dm, ", "));
- /* Demangle the type. */
- RETURN_IF_ERROR (demangle_type (dm));
+ const char *s;
+ int len;
+
+ if (p->set_last_name != NULL)
+ di->last_name = d_make_sub (di, p->set_last_name,
+ p->set_last_name_len);
+ if (verbose)
+ {
+ s = p->full_expansion;
+ len = p->full_len;
+ }
+ else
+ {
+ s = p->simple_expansion;
+ len = p->simple_len;
+ }
+ di->expansion += len;
+ return d_make_sub (di, s, len);
}
}
- ++sequence;
+ return NULL;
}
- RETURN_IF_ERROR (result_add_char (dm, ')'));
+}
- /* We should have demangled at least one parameter type (which would
- be void, for a function that takes no parameters), plus the
- return type, if we were supposed to demangle that. */
- if (sequence == -1)
- return "Missing function return type.";
- else if (sequence == 0)
- return "Missing function parameter.";
+/* Resize the print buffer. */
- return STATUS_OK;
-}
+static void
+d_print_resize (dpi, add)
+ struct d_print_info *dpi;
+ size_t add;
+{
+ size_t need;
-/* Demangles and emits a <class-enum-type>. *ENCODE_RETURN_TYPE is set to
- non-zero if the type is a template-id, zero otherwise.
+ if (dpi->buf == NULL)
+ return;
+ need = dpi->len + add;
+ while (need > dpi->alc)
+ {
+ size_t newalc;
+ char *newbuf;
+
+ newalc = dpi->alc * 2;
+ newbuf = realloc (dpi->buf, newalc);
+ if (newbuf == NULL)
+ {
+ free (dpi->buf);
+ dpi->buf = NULL;
+ dpi->allocation_failure = 1;
+ return;
+ }
+ dpi->buf = newbuf;
+ dpi->alc = newalc;
+ }
+}
- <class-enum-type> ::= <name> */
+/* Append a character to the print buffer. */
-static status_t
-demangle_class_enum_type (dm, encode_return_type)
- demangling_t dm;
- int *encode_return_type;
+static void
+d_print_append_char (dpi, c)
+ struct d_print_info *dpi;
+ int c;
{
- DEMANGLE_TRACE ("class-enum-type", dm);
+ if (dpi->buf != NULL)
+ {
+ if (dpi->len >= dpi->alc)
+ {
+ d_print_resize (dpi, 1);
+ if (dpi->buf == NULL)
+ return;
+ }
- RETURN_IF_ERROR (demangle_name (dm, encode_return_type));
- return STATUS_OK;
+ dpi->buf[dpi->len] = c;
+ ++dpi->len;
+ }
}
-/* Demangles and emits an <array-type>.
+/* Append a buffer to the print buffer. */
- If PTR_INSERT_POS is not NULL, the array type is formatted as a
- pointer or reference to an array, except that asterisk and
- ampersand punctuation is omitted (since it's not know at this
- point). *PTR_INSERT_POS is set to the position in the demangled
- name at which this punctuation should be inserted. For example,
- `A10_i' is demangled to `int () [10]' and *PTR_INSERT_POS points
- between the parentheses.
+static void
+d_print_append_buffer (dpi, s, l)
+ struct d_print_info *dpi;
+ const char *s;
+ size_t l;
+{
+ if (dpi->buf != NULL)
+ {
+ if (dpi->len + l > dpi->alc)
+ {
+ d_print_resize (dpi, l);
+ if (dpi->buf == NULL)
+ return;
+ }
- If PTR_INSERT_POS is NULL, the array type is assumed not to be
- pointer- or reference-qualified. Then, for example, `A10_i' is
- demangled simply as `int[10]'.
+ memcpy (dpi->buf + dpi->len, s, l);
+ dpi->len += l;
+ }
+}
- <array-type> ::= A [<dimension number>] _ <element type>
- ::= A <dimension expression> _ <element type> */
+/* Indicate that an error occurred during printing. */
-static status_t
-demangle_array_type (dm, ptr_insert_pos)
- demangling_t dm;
- int *ptr_insert_pos;
+static void
+d_print_error (dpi)
+ struct d_print_info *dpi;
{
- status_t status = STATUS_OK;
- dyn_string_t array_size = NULL;
- char peek;
+ free (dpi->buf);
+ dpi->buf = NULL;
+}
- DEMANGLE_TRACE ("array-type", dm);
+/* Turn components into a human readable string. OPTIONS is the
+ options bits passed to the demangler. DC is the tree to print.
+ ESTIMATE is a guess at the length of the result. This returns a
+ string allocated by malloc, or NULL on error. On success, this
+ sets *PALC to the size of the allocated buffer. On failure, this
+ sets *PALC to 0 for a bad parse, or to 1 for a memory allocation
+ failure. */
- RETURN_IF_ERROR (demangle_char (dm, 'A'));
+CP_STATIC_IF_GLIBCPP_V3
+char *
+cplus_demangle_print (options, dc, estimate, palc)
+ int options;
+ const struct demangle_component *dc;
+ int estimate;
+ size_t *palc;
+{
+ struct d_print_info dpi;
- /* Demangle the array size into array_size. */
- peek = peek_char (dm);
- if (peek == '_')
- /* Array bound is omitted. This is a C99-style VLA. */
- ;
- else if (IS_DIGIT (peek_char (dm)))
+ dpi.options = options;
+
+ dpi.alc = estimate + 1;
+ dpi.buf = malloc (dpi.alc);
+ if (dpi.buf == NULL)
{
- /* It looks like a constant array bound. */
- array_size = dyn_string_new (10);
- if (array_size == NULL)
- return STATUS_ALLOCATION_FAILED;
- status = demangle_number_literally (dm, array_size, 10, 0);
+ *palc = 1;
+ return NULL;
}
+
+ dpi.len = 0;
+ dpi.templates = NULL;
+ dpi.modifiers = NULL;
+
+ dpi.allocation_failure = 0;
+
+ d_print_comp (&dpi, dc);
+
+ d_append_char (&dpi, '\0');
+
+ if (dpi.buf != NULL)
+ *palc = dpi.alc;
else
- {
- /* Anything is must be an expression for a nont-constant array
- bound. This happens if the array type occurs in a template
- and the array bound references a template parameter. */
- RETURN_IF_ERROR (result_push (dm));
- RETURN_IF_ERROR (demangle_expression (dm));
- array_size = (dyn_string_t) result_pop (dm);
- }
- /* array_size may have been allocated by now, so we can't use
- RETURN_IF_ERROR until it's been deallocated. */
+ *palc = dpi.allocation_failure;
+
+ return dpi.buf;
+}
- /* Demangle the base type of the array. */
- if (STATUS_NO_ERROR (status))
- status = demangle_char (dm, '_');
- if (STATUS_NO_ERROR (status))
- status = demangle_type (dm);
+/* Subroutine to handle components. */
- if (ptr_insert_pos != NULL)
+static void
+d_print_comp (dpi, dc)
+ struct d_print_info *dpi;
+ const struct demangle_component *dc;
+{
+ if (dc == NULL)
{
- /* This array is actually part of an pointer- or
- reference-to-array type. Format appropriately, except we
- don't know which and how much punctuation to use. */
- if (STATUS_NO_ERROR (status))
- status = result_add (dm, " () ");
- /* Let the caller know where to insert the punctuation. */
- *ptr_insert_pos = result_caret_pos (dm) - 2;
+ d_print_error (dpi);
+ return;
}
+ if (d_print_saw_error (dpi))
+ return;
- /* Emit the array dimension syntax. */
- if (STATUS_NO_ERROR (status))
- status = result_add_char (dm, '[');
- if (STATUS_NO_ERROR (status) && array_size != NULL)
- status = result_add_string (dm, array_size);
- if (STATUS_NO_ERROR (status))
- status = result_add_char (dm, ']');
- if (array_size != NULL)
- dyn_string_delete (array_size);
-
- RETURN_IF_ERROR (status);
-
- return STATUS_OK;
-}
+ switch (dc->type)
+ {
+ case DEMANGLE_COMPONENT_NAME:
+ if ((dpi->options & DMGL_JAVA) == 0)
+ d_append_buffer (dpi, dc->u.s_name.s, dc->u.s_name.len);
+ else
+ d_print_java_identifier (dpi, dc->u.s_name.s, dc->u.s_name.len);
+ return;
+
+ case DEMANGLE_COMPONENT_QUAL_NAME:
+ case DEMANGLE_COMPONENT_LOCAL_NAME:
+ d_print_comp (dpi, d_left (dc));
+ if ((dpi->options & DMGL_JAVA) == 0)
+ d_append_string_constant (dpi, "::");
+ else
+ d_append_char (dpi, '.');
+ d_print_comp (dpi, d_right (dc));
+ return;
-/* Demangles and emits a <template-param>.
+ case DEMANGLE_COMPONENT_TYPED_NAME:
+ {
+ struct d_print_mod *hold_modifiers;
+ struct demangle_component *typed_name;
+ struct d_print_mod adpm[4];
+ unsigned int i;
+ struct d_print_template dpt;
+
+ /* Pass the name down to the type so that it can be printed in
+ the right place for the type. We also have to pass down
+ any CV-qualifiers, which apply to the this parameter. */
+ hold_modifiers = dpi->modifiers;
+ i = 0;
+ typed_name = d_left (dc);
+ while (typed_name != NULL)
+ {
+ if (i >= sizeof adpm / sizeof adpm[0])
+ {
+ d_print_error (dpi);
+ return;
+ }
+
+ adpm[i].next = dpi->modifiers;
+ dpi->modifiers = &adpm[i];
+ adpm[i].mod = typed_name;
+ adpm[i].printed = 0;
+ adpm[i].templates = dpi->templates;
+ ++i;
+
+ if (typed_name->type != DEMANGLE_COMPONENT_RESTRICT_THIS
+ && typed_name->type != DEMANGLE_COMPONENT_VOLATILE_THIS
+ && typed_name->type != DEMANGLE_COMPONENT_CONST_THIS)
+ break;
- <template-param> ::= T_ # first template parameter
- ::= T <parameter-2 number> _ */
+ typed_name = d_left (typed_name);
+ }
-static status_t
-demangle_template_param (dm)
- demangling_t dm;
-{
- int parm_number;
- template_arg_list_t current_arg_list = current_template_arg_list (dm);
- string_list_t arg;
+ /* If typed_name is a template, then it applies to the
+ function type as well. */
+ if (typed_name->type == DEMANGLE_COMPONENT_TEMPLATE)
+ {
+ dpt.next = dpi->templates;
+ dpi->templates = &dpt;
+ dpt.template = typed_name;
+ }
- DEMANGLE_TRACE ("template-param", dm);
+ /* If typed_name is a DEMANGLE_COMPONENT_LOCAL_NAME, then
+ there may be CV-qualifiers on its right argument which
+ really apply here; this happens when parsing a class which
+ is local to a function. */
+ if (typed_name->type == DEMANGLE_COMPONENT_LOCAL_NAME)
+ {
+ struct demangle_component *local_name;
+
+ local_name = d_right (typed_name);
+ while (local_name->type == DEMANGLE_COMPONENT_RESTRICT_THIS
+ || local_name->type == DEMANGLE_COMPONENT_VOLATILE_THIS
+ || local_name->type == DEMANGLE_COMPONENT_CONST_THIS)
+ {
+ if (i >= sizeof adpm / sizeof adpm[0])
+ {
+ d_print_error (dpi);
+ return;
+ }
+
+ adpm[i] = adpm[i - 1];
+ adpm[i].next = &adpm[i - 1];
+ dpi->modifiers = &adpm[i];
+
+ adpm[i - 1].mod = local_name;
+ adpm[i - 1].printed = 0;
+ adpm[i - 1].templates = dpi->templates;
+ ++i;
+
+ local_name = d_left (local_name);
+ }
+ }
- /* Make sure there is a template argmust list in which to look up
- this parameter reference. */
- if (current_arg_list == NULL)
- return "Template parameter outside of template.";
+ d_print_comp (dpi, d_right (dc));
- RETURN_IF_ERROR (demangle_char (dm, 'T'));
- if (peek_char (dm) == '_')
- parm_number = 0;
- else
- {
- RETURN_IF_ERROR (demangle_number (dm, &parm_number, 10, 0));
- ++parm_number;
- }
- RETURN_IF_ERROR (demangle_char (dm, '_'));
+ if (typed_name->type == DEMANGLE_COMPONENT_TEMPLATE)
+ dpi->templates = dpt.next;
- arg = template_arg_list_get_arg (current_arg_list, parm_number);
- if (arg == NULL)
- /* parm_number exceeded the number of arguments in the current
- template argument list. */
- return "Template parameter number out of bounds.";
- RETURN_IF_ERROR (result_add_string (dm, (dyn_string_t) arg));
+ /* If the modifiers didn't get printed by the type, print them
+ now. */
+ while (i > 0)
+ {
+ --i;
+ if (! adpm[i].printed)
+ {
+ d_append_char (dpi, ' ');
+ d_print_mod (dpi, adpm[i].mod);
+ }
+ }
- return STATUS_OK;
-}
+ dpi->modifiers = hold_modifiers;
-/* Demangles and emits a <template-args>.
+ return;
+ }
- <template-args> ::= I <template-arg>+ E */
+ case DEMANGLE_COMPONENT_TEMPLATE:
+ {
+ struct d_print_mod *hold_dpm;
-static status_t
-demangle_template_args (dm)
- demangling_t dm;
-{
- int first = 1;
- dyn_string_t old_last_source_name;
- template_arg_list_t arg_list = template_arg_list_new ();
+ /* Don't push modifiers into a template definition. Doing so
+ could give the wrong definition for a template argument.
+ Instead, treat the template essentially as a name. */
- if (arg_list == NULL)
- return STATUS_ALLOCATION_FAILED;
+ hold_dpm = dpi->modifiers;
+ dpi->modifiers = NULL;
- /* Preserve the most recently demangled source name. */
- old_last_source_name = dm->last_source_name;
- dm->last_source_name = dyn_string_new (0);
+ d_print_comp (dpi, d_left (dc));
+ if (d_last_char (dpi) == '<')
+ d_append_char (dpi, ' ');
+ d_append_char (dpi, '<');
+ d_print_comp (dpi, d_right (dc));
+ /* Avoid generating two consecutive '>' characters, to avoid
+ the C++ syntactic ambiguity. */
+ if (d_last_char (dpi) == '>')
+ d_append_char (dpi, ' ');
+ d_append_char (dpi, '>');
- DEMANGLE_TRACE ("template-args", dm);
+ dpi->modifiers = hold_dpm;
- if (dm->last_source_name == NULL)
- return STATUS_ALLOCATION_FAILED;
+ return;
+ }
- RETURN_IF_ERROR (demangle_char (dm, 'I'));
- RETURN_IF_ERROR (result_open_template_list (dm));
- do
- {
- string_list_t arg;
+ case DEMANGLE_COMPONENT_TEMPLATE_PARAM:
+ {
+ long i;
+ struct demangle_component *a;
+ struct d_print_template *hold_dpt;
- if (first)
- first = 0;
+ if (dpi->templates == NULL)
+ {
+ d_print_error (dpi);
+ return;
+ }
+ i = dc->u.s_number.number;
+ for (a = d_right (dpi->templates->template);
+ a != NULL;
+ a = d_right (a))
+ {
+ if (a->type != DEMANGLE_COMPONENT_TEMPLATE_ARGLIST)
+ {
+ d_print_error (dpi);
+ return;
+ }
+ if (i <= 0)
+ break;
+ --i;
+ }
+ if (i != 0 || a == NULL)
+ {
+ d_print_error (dpi);
+ return;
+ }
+
+ /* While processing this parameter, we need to pop the list of
+ templates. This is because the template parameter may
+ itself be a reference to a parameter of an outer
+ template. */
+
+ hold_dpt = dpi->templates;
+ dpi->templates = hold_dpt->next;
+
+ d_print_comp (dpi, d_left (a));
+
+ dpi->templates = hold_dpt;
+
+ return;
+ }
+
+ case DEMANGLE_COMPONENT_CTOR:
+ d_print_comp (dpi, dc->u.s_ctor.name);
+ return;
+
+ case DEMANGLE_COMPONENT_DTOR:
+ d_append_char (dpi, '~');
+ d_print_comp (dpi, dc->u.s_dtor.name);
+ return;
+
+ case DEMANGLE_COMPONENT_VTABLE:
+ d_append_string_constant (dpi, "vtable for ");
+ d_print_comp (dpi, d_left (dc));
+ return;
+
+ case DEMANGLE_COMPONENT_VTT:
+ d_append_string_constant (dpi, "VTT for ");
+ d_print_comp (dpi, d_left (dc));
+ return;
+
+ case DEMANGLE_COMPONENT_CONSTRUCTION_VTABLE:
+ d_append_string_constant (dpi, "construction vtable for ");
+ d_print_comp (dpi, d_left (dc));
+ d_append_string_constant (dpi, "-in-");
+ d_print_comp (dpi, d_right (dc));
+ return;
+
+ case DEMANGLE_COMPONENT_TYPEINFO:
+ d_append_string_constant (dpi, "typeinfo for ");
+ d_print_comp (dpi, d_left (dc));
+ return;
+
+ case DEMANGLE_COMPONENT_TYPEINFO_NAME:
+ d_append_string_constant (dpi, "typeinfo name for ");
+ d_print_comp (dpi, d_left (dc));
+ return;
+
+ case DEMANGLE_COMPONENT_TYPEINFO_FN:
+ d_append_string_constant (dpi, "typeinfo fn for ");
+ d_print_comp (dpi, d_left (dc));
+ return;
+
+ case DEMANGLE_COMPONENT_THUNK:
+ d_append_string_constant (dpi, "non-virtual thunk to ");
+ d_print_comp (dpi, d_left (dc));
+ return;
+
+ case DEMANGLE_COMPONENT_VIRTUAL_THUNK:
+ d_append_string_constant (dpi, "virtual thunk to ");
+ d_print_comp (dpi, d_left (dc));
+ return;
+
+ case DEMANGLE_COMPONENT_COVARIANT_THUNK:
+ d_append_string_constant (dpi, "covariant return thunk to ");
+ d_print_comp (dpi, d_left (dc));
+ return;
+
+ case DEMANGLE_COMPONENT_JAVA_CLASS:
+ d_append_string_constant (dpi, "java Class for ");
+ d_print_comp (dpi, d_left (dc));
+ return;
+
+ case DEMANGLE_COMPONENT_GUARD:
+ d_append_string_constant (dpi, "guard variable for ");
+ d_print_comp (dpi, d_left (dc));
+ return;
+
+ case DEMANGLE_COMPONENT_REFTEMP:
+ d_append_string_constant (dpi, "reference temporary for ");
+ d_print_comp (dpi, d_left (dc));
+ return;
+
+ case DEMANGLE_COMPONENT_SUB_STD:
+ d_append_buffer (dpi, dc->u.s_string.string, dc->u.s_string.len);
+ return;
+
+ case DEMANGLE_COMPONENT_RESTRICT:
+ case DEMANGLE_COMPONENT_VOLATILE:
+ case DEMANGLE_COMPONENT_CONST:
+ case DEMANGLE_COMPONENT_RESTRICT_THIS:
+ case DEMANGLE_COMPONENT_VOLATILE_THIS:
+ case DEMANGLE_COMPONENT_CONST_THIS:
+ case DEMANGLE_COMPONENT_VENDOR_TYPE_QUAL:
+ case DEMANGLE_COMPONENT_POINTER:
+ case DEMANGLE_COMPONENT_REFERENCE:
+ case DEMANGLE_COMPONENT_COMPLEX:
+ case DEMANGLE_COMPONENT_IMAGINARY:
+ {
+ /* We keep a list of modifiers on the stack. */
+ struct d_print_mod dpm;
+
+ dpm.next = dpi->modifiers;
+ dpi->modifiers = &dpm;
+ dpm.mod = dc;
+ dpm.printed = 0;
+ dpm.templates = dpi->templates;
+
+ d_print_comp (dpi, d_left (dc));
+
+ /* If the modifier didn't get printed by the type, print it
+ now. */
+ if (! dpm.printed)
+ d_print_mod (dpi, dc);
+
+ dpi->modifiers = dpm.next;
+
+ return;
+ }
+
+ case DEMANGLE_COMPONENT_BUILTIN_TYPE:
+ if ((dpi->options & DMGL_JAVA) == 0)
+ d_append_buffer (dpi, dc->u.s_builtin.type->name,
+ dc->u.s_builtin.type->len);
else
- RETURN_IF_ERROR (result_add (dm, ", "));
+ d_append_buffer (dpi, dc->u.s_builtin.type->java_name,
+ dc->u.s_builtin.type->java_len);
+ return;
- /* Capture the template arg. */
- RETURN_IF_ERROR (result_push (dm));
- RETURN_IF_ERROR (demangle_template_arg (dm));
- arg = result_pop (dm);
+ case DEMANGLE_COMPONENT_VENDOR_TYPE:
+ d_print_comp (dpi, d_left (dc));
+ return;
- /* Emit it in the demangled name. */
- RETURN_IF_ERROR (result_add_string (dm, (dyn_string_t) arg));
+ case DEMANGLE_COMPONENT_FUNCTION_TYPE:
+ {
+ if (d_left (dc) != NULL)
+ {
+ struct d_print_mod dpm;
- /* Save it for use in expanding <template-param>s. */
- template_arg_list_add_arg (arg_list, arg);
- }
- while (peek_char (dm) != 'E');
- /* Append the '>'. */
- RETURN_IF_ERROR (result_close_template_list (dm));
+ /* We must pass this type down as a modifier in order to
+ print it in the right location. */
- /* Consume the 'E'. */
- advance_char (dm);
+ dpm.next = dpi->modifiers;
+ dpi->modifiers = &dpm;
+ dpm.mod = dc;
+ dpm.printed = 0;
+ dpm.templates = dpi->templates;
- /* Restore the most recent demangled source name. */
- dyn_string_delete (dm->last_source_name);
- dm->last_source_name = old_last_source_name;
+ d_print_comp (dpi, d_left (dc));
- /* Push the list onto the top of the stack of template argument
- lists, so that arguments from it are used from now on when
- expanding <template-param>s. */
- push_template_arg_list (dm, arg_list);
+ dpi->modifiers = dpm.next;
- return STATUS_OK;
-}
+ if (dpm.printed)
+ return;
-/* This function, which does not correspond to a production in the
- mangling spec, handles the `literal' production for both
- <template-arg> and <expr-primary>. It does not expect or consume
- the initial `L' or final `E'. The demangling is given by:
+ d_append_char (dpi, ' ');
+ }
- <literal> ::= <type> </value/ number>
+ d_print_function_type (dpi, dc, dpi->modifiers);
- and the emitted output is `(type)number'. */
+ return;
+ }
-static status_t
-demangle_literal (dm)
- demangling_t dm;
-{
- char peek = peek_char (dm);
- dyn_string_t value_string;
- status_t status;
+ case DEMANGLE_COMPONENT_ARRAY_TYPE:
+ {
+ struct d_print_mod dpm;
- DEMANGLE_TRACE ("literal", dm);
+ /* We must pass this type down as a modifier in order to print
+ multi-dimensional arrays correctly. */
- if (!flag_verbose && peek >= 'a' && peek <= 'z')
- {
- /* If not in verbose mode and this is a builtin type, see if we
- can produce simpler numerical output. In particular, for
- integer types shorter than `long', just write the number
- without type information; for bools, write `true' or `false'.
- Other refinements could be made here too. */
-
- /* This constant string is used to map from <builtin-type> codes
- (26 letters of the alphabet) to codes that determine how the
- value will be displayed. The codes are:
- b: display as bool
- i: display as int
- l: display as long
- A space means the value will be represented using cast
- notation. */
- static const char *const code_map = "ibi iii ll ii i ";
-
- char code = code_map[peek - 'a'];
- /* FIXME: Implement demangling of floats and doubles. */
- if (code == 'u')
- return STATUS_UNIMPLEMENTED;
- if (code == 'b')
- {
- /* It's a boolean. */
- char value;
-
- /* Consume the b. */
- advance_char (dm);
- /* Look at the next character. It should be 0 or 1,
- corresponding to false or true, respectively. */
- value = peek_char (dm);
- if (value == '0')
- RETURN_IF_ERROR (result_add (dm, "false"));
- else if (value == '1')
- RETURN_IF_ERROR (result_add (dm, "true"));
- else
- return "Unrecognized bool constant.";
- /* Consume the 0 or 1. */
- advance_char (dm);
- return STATUS_OK;
- }
- else if (code == 'i' || code == 'l')
- {
- /* It's an integer or long. */
-
- /* Consume the type character. */
- advance_char (dm);
-
- /* Demangle the number and write it out. */
- value_string = dyn_string_new (0);
- status = demangle_number_literally (dm, value_string, 10, 1);
- if (STATUS_NO_ERROR (status))
- status = result_add_string (dm, value_string);
- /* For long integers, append an l. */
- if (code == 'l' && STATUS_NO_ERROR (status))
- status = result_add_char (dm, code);
- dyn_string_delete (value_string);
-
- RETURN_IF_ERROR (status);
- return STATUS_OK;
- }
- /* ...else code == ' ', so fall through to represent this
- literal's type explicitly using cast syntax. */
- }
+ dpm.next = dpi->modifiers;
+ dpi->modifiers = &dpm;
+ dpm.mod = dc;
+ dpm.printed = 0;
+ dpm.templates = dpi->templates;
- RETURN_IF_ERROR (result_add_char (dm, '('));
- RETURN_IF_ERROR (demangle_type (dm));
- RETURN_IF_ERROR (result_add_char (dm, ')'));
+ d_print_comp (dpi, d_right (dc));
- value_string = dyn_string_new (0);
- if (value_string == NULL)
- return STATUS_ALLOCATION_FAILED;
+ dpi->modifiers = dpm.next;
- status = demangle_number_literally (dm, value_string, 10, 1);
- if (STATUS_NO_ERROR (status))
- status = result_add_string (dm, value_string);
- dyn_string_delete (value_string);
- RETURN_IF_ERROR (status);
+ if (dpm.printed)
+ return;
- return STATUS_OK;
-}
+ d_print_array_type (dpi, dc, dpi->modifiers);
-/* Demangles and emits a <template-arg>.
+ return;
+ }
- <template-arg> ::= <type> # type
- ::= L <type> <value number> E # literal
- ::= LZ <encoding> E # external name
- ::= X <expression> E # expression */
+ case DEMANGLE_COMPONENT_PTRMEM_TYPE:
+ {
+ struct d_print_mod dpm;
-static status_t
-demangle_template_arg (dm)
- demangling_t dm;
-{
- DEMANGLE_TRACE ("template-arg", dm);
+ dpm.next = dpi->modifiers;
+ dpi->modifiers = &dpm;
+ dpm.mod = dc;
+ dpm.printed = 0;
+ dpm.templates = dpi->templates;
- switch (peek_char (dm))
- {
- case 'L':
- advance_char (dm);
+ d_print_comp (dpi, d_right (dc));
- if (peek_char (dm) == 'Z')
+ /* If the modifier didn't get printed by the type, print it
+ now. */
+ if (! dpm.printed)
+ {
+ d_append_char (dpi, ' ');
+ d_print_comp (dpi, d_left (dc));
+ d_append_string_constant (dpi, "::*");
+ }
+
+ dpi->modifiers = dpm.next;
+
+ return;
+ }
+
+ case DEMANGLE_COMPONENT_ARGLIST:
+ case DEMANGLE_COMPONENT_TEMPLATE_ARGLIST:
+ d_print_comp (dpi, d_left (dc));
+ if (d_right (dc) != NULL)
{
- /* External name. */
- advance_char (dm);
- /* FIXME: Standard is contradictory here. */
- RETURN_IF_ERROR (demangle_encoding (dm));
+ d_append_string_constant (dpi, ", ");
+ d_print_comp (dpi, d_right (dc));
}
+ return;
+
+ case DEMANGLE_COMPONENT_OPERATOR:
+ {
+ char c;
+
+ d_append_string_constant (dpi, "operator");
+ c = dc->u.s_operator.op->name[0];
+ if (IS_LOWER (c))
+ d_append_char (dpi, ' ');
+ d_append_buffer (dpi, dc->u.s_operator.op->name,
+ dc->u.s_operator.op->len);
+ return;
+ }
+
+ case DEMANGLE_COMPONENT_EXTENDED_OPERATOR:
+ d_append_string_constant (dpi, "operator ");
+ d_print_comp (dpi, dc->u.s_extended_operator.name);
+ return;
+
+ case DEMANGLE_COMPONENT_CAST:
+ d_append_string_constant (dpi, "operator ");
+ d_print_cast (dpi, dc);
+ return;
+
+ case DEMANGLE_COMPONENT_UNARY:
+ if (d_left (dc)->type != DEMANGLE_COMPONENT_CAST)
+ d_print_expr_op (dpi, d_left (dc));
else
- RETURN_IF_ERROR (demangle_literal (dm));
- RETURN_IF_ERROR (demangle_char (dm, 'E'));
- break;
+ {
+ d_append_string_constant (dpi, "((");
+ d_print_cast (dpi, d_left (dc));
+ d_append_char (dpi, ')');
+ }
+ d_append_char (dpi, '(');
+ d_print_comp (dpi, d_right (dc));
+ d_append_char (dpi, ')');
+ if (d_left (dc)->type == DEMANGLE_COMPONENT_CAST)
+ d_append_char (dpi, ')');
+ return;
+
+ case DEMANGLE_COMPONENT_BINARY:
+ if (d_right (dc)->type != DEMANGLE_COMPONENT_BINARY_ARGS)
+ {
+ d_print_error (dpi);
+ return;
+ }
- case 'X':
- /* Expression. */
- advance_char (dm);
- RETURN_IF_ERROR (demangle_expression (dm));
- RETURN_IF_ERROR (demangle_char (dm, 'E'));
- break;
+ /* We wrap an expression which uses the greater-than operator in
+ an extra layer of parens so that it does not get confused
+ with the '>' which ends the template parameters. */
+ if (d_left (dc)->type == DEMANGLE_COMPONENT_OPERATOR
+ && d_left (dc)->u.s_operator.op->len == 1
+ && d_left (dc)->u.s_operator.op->name[0] == '>')
+ d_append_char (dpi, '(');
+
+ d_append_char (dpi, '(');
+ d_print_comp (dpi, d_left (d_right (dc)));
+ d_append_string_constant (dpi, ") ");
+ d_print_expr_op (dpi, d_left (dc));
+ d_append_string_constant (dpi, " (");
+ d_print_comp (dpi, d_right (d_right (dc)));
+ d_append_char (dpi, ')');
+
+ if (d_left (dc)->type == DEMANGLE_COMPONENT_OPERATOR
+ && d_left (dc)->u.s_operator.op->len == 1
+ && d_left (dc)->u.s_operator.op->name[0] == '>')
+ d_append_char (dpi, ')');
+
+ return;
+
+ case DEMANGLE_COMPONENT_BINARY_ARGS:
+ /* We should only see this as part of DEMANGLE_COMPONENT_BINARY. */
+ d_print_error (dpi);
+ return;
+
+ case DEMANGLE_COMPONENT_TRINARY:
+ if (d_right (dc)->type != DEMANGLE_COMPONENT_TRINARY_ARG1
+ || d_right (d_right (dc))->type != DEMANGLE_COMPONENT_TRINARY_ARG2)
+ {
+ d_print_error (dpi);
+ return;
+ }
+ d_append_char (dpi, '(');
+ d_print_comp (dpi, d_left (d_right (dc)));
+ d_append_string_constant (dpi, ") ");
+ d_print_expr_op (dpi, d_left (dc));
+ d_append_string_constant (dpi, " (");
+ d_print_comp (dpi, d_left (d_right (d_right (dc))));
+ d_append_string_constant (dpi, ") : (");
+ d_print_comp (dpi, d_right (d_right (d_right (dc))));
+ d_append_char (dpi, ')');
+ return;
+
+ case DEMANGLE_COMPONENT_TRINARY_ARG1:
+ case DEMANGLE_COMPONENT_TRINARY_ARG2:
+ /* We should only see these are part of DEMANGLE_COMPONENT_TRINARY. */
+ d_print_error (dpi);
+ return;
+
+ case DEMANGLE_COMPONENT_LITERAL:
+ case DEMANGLE_COMPONENT_LITERAL_NEG:
+ /* For some builtin types, produce simpler output. */
+ if (d_left (dc)->type == DEMANGLE_COMPONENT_BUILTIN_TYPE)
+ {
+ switch (d_left (dc)->u.s_builtin.type->print)
+ {
+ case D_PRINT_INT:
+ if (d_right (dc)->type == DEMANGLE_COMPONENT_NAME)
+ {
+ if (dc->type == DEMANGLE_COMPONENT_LITERAL_NEG)
+ d_append_char (dpi, '-');
+ d_print_comp (dpi, d_right (dc));
+ return;
+ }
+ break;
+
+ case D_PRINT_LONG:
+ if (d_right (dc)->type == DEMANGLE_COMPONENT_NAME)
+ {
+ if (dc->type == DEMANGLE_COMPONENT_LITERAL_NEG)
+ d_append_char (dpi, '-');
+ d_print_comp (dpi, d_right (dc));
+ d_append_char (dpi, 'l');
+ return;
+ }
+ break;
+
+ case D_PRINT_BOOL:
+ if (d_right (dc)->type == DEMANGLE_COMPONENT_NAME
+ && d_right (dc)->u.s_name.len == 1
+ && dc->type == DEMANGLE_COMPONENT_LITERAL)
+ {
+ switch (d_right (dc)->u.s_name.s[0])
+ {
+ case '0':
+ d_append_string_constant (dpi, "false");
+ return;
+ case '1':
+ d_append_string_constant (dpi, "true");
+ return;
+ default:
+ break;
+ }
+ }
+ break;
+
+ default:
+ break;
+ }
+ }
+
+ d_append_char (dpi, '(');
+ d_print_comp (dpi, d_left (dc));
+ d_append_char (dpi, ')');
+ if (dc->type == DEMANGLE_COMPONENT_LITERAL_NEG)
+ d_append_char (dpi, '-');
+ d_print_comp (dpi, d_right (dc));
+ return;
default:
- RETURN_IF_ERROR (demangle_type (dm));
- break;
+ d_print_error (dpi);
+ return;
}
-
- return STATUS_OK;
}
-/* Demangles and emits an <expression>.
+/* Print a Java dentifier. For Java we try to handle encoded extended
+ Unicode characters. The C++ ABI doesn't mention Unicode encoding,
+ so we don't it for C++. Characters are encoded as
+ __U<hex-char>+_. */
- <expression> ::= <unary operator-name> <expression>
- ::= <binary operator-name> <expression> <expression>
- ::= <expr-primary>
- ::= <scope-expression> */
-
-static status_t
-demangle_expression (dm)
- demangling_t dm;
+static void
+d_print_java_identifier (dpi, name, len)
+ struct d_print_info *dpi;
+ const char *name;
+ int len;
{
- char peek = peek_char (dm);
-
- DEMANGLE_TRACE ("expression", dm);
+ const char *p;
+ const char *end;
- if (peek == 'L' || peek == 'T')
- RETURN_IF_ERROR (demangle_expr_primary (dm));
- else if (peek == 's' && peek_char_next (dm) == 'r')
- RETURN_IF_ERROR (demangle_scope_expression (dm));
- else
- /* An operator expression. */
+ end = name + len;
+ for (p = name; p < end; ++p)
{
- int num_args;
- int type_arg;
- status_t status = STATUS_OK;
- dyn_string_t operator_name;
-
- /* We have an operator name. Since we want to output binary
- operations in infix notation, capture the operator name
- first. */
- RETURN_IF_ERROR (result_push (dm));
- RETURN_IF_ERROR (demangle_operator_name (dm, 1, &num_args,
- &type_arg));
- operator_name = (dyn_string_t) result_pop (dm);
-
- /* If it's binary, do an operand first. */
- if (num_args > 1)
+ if (end - p > 3
+ && p[0] == '_'
+ && p[1] == '_'
+ && p[2] == 'U')
{
- status = result_add_char (dm, '(');
- if (STATUS_NO_ERROR (status))
- status = demangle_expression (dm);
- if (STATUS_NO_ERROR (status))
- status = result_add_char (dm, ')');
- }
+ unsigned long c;
+ const char *q;
- /* Emit the operator. */
- if (STATUS_NO_ERROR (status))
- status = result_add_string (dm, operator_name);
- dyn_string_delete (operator_name);
- RETURN_IF_ERROR (status);
-
- /* Emit its second (if binary) or only (if unary) operand. */
- RETURN_IF_ERROR (result_add_char (dm, '('));
- if (type_arg)
- RETURN_IF_ERROR (demangle_type (dm));
- else
- RETURN_IF_ERROR (demangle_expression (dm));
- RETURN_IF_ERROR (result_add_char (dm, ')'));
+ c = 0;
+ for (q = p + 3; q < end; ++q)
+ {
+ int dig;
+
+ if (IS_DIGIT (*q))
+ dig = *q - '0';
+ else if (*q >= 'A' && *q <= 'F')
+ dig = *q - 'A' + 10;
+ else if (*q >= 'a' && *q <= 'f')
+ dig = *q - 'a' + 10;
+ else
+ break;
- /* The ternary operator takes a third operand. */
- if (num_args == 3)
- {
- RETURN_IF_ERROR (result_add (dm, ":("));
- RETURN_IF_ERROR (demangle_expression (dm));
- RETURN_IF_ERROR (result_add_char (dm, ')'));
+ c = c * 16 + dig;
+ }
+ /* If the Unicode character is larger than 256, we don't try
+ to deal with it here. FIXME. */
+ if (q < end && *q == '_' && c < 256)
+ {
+ d_append_char (dpi, c);
+ p = q;
+ continue;
+ }
}
- }
- return STATUS_OK;
+ d_append_char (dpi, *p);
+ }
}
-/* Demangles and emits a <scope-expression>.
+/* Print a list of modifiers. SUFFIX is 1 if we are printing
+ qualifiers on this after printing a function. */
- <scope-expression> ::= sr <qualifying type> <source-name>
- ::= sr <qualifying type> <encoding> */
-
-static status_t
-demangle_scope_expression (dm)
- demangling_t dm;
+static void
+d_print_mod_list (dpi, mods, suffix)
+ struct d_print_info *dpi;
+ struct d_print_mod *mods;
+ int suffix;
{
- RETURN_IF_ERROR (demangle_char (dm, 's'));
- RETURN_IF_ERROR (demangle_char (dm, 'r'));
- RETURN_IF_ERROR (demangle_type (dm));
- RETURN_IF_ERROR (result_add (dm, "::"));
- RETURN_IF_ERROR (demangle_encoding (dm));
- return STATUS_OK;
-}
+ struct d_print_template *hold_dpt;
-/* Demangles and emits an <expr-primary>.
+ if (mods == NULL || d_print_saw_error (dpi))
+ return;
- <expr-primary> ::= <template-param>
- ::= L <type> <value number> E # literal
- ::= L <mangled-name> E # external name */
+ if (mods->printed
+ || (! suffix
+ && (mods->mod->type == DEMANGLE_COMPONENT_RESTRICT_THIS
+ || mods->mod->type == DEMANGLE_COMPONENT_VOLATILE_THIS
+ || mods->mod->type == DEMANGLE_COMPONENT_CONST_THIS)))
+ {
+ d_print_mod_list (dpi, mods->next, suffix);
+ return;
+ }
-static status_t
-demangle_expr_primary (dm)
- demangling_t dm;
-{
- char peek = peek_char (dm);
+ mods->printed = 1;
- DEMANGLE_TRACE ("expr-primary", dm);
+ hold_dpt = dpi->templates;
+ dpi->templates = mods->templates;
- if (peek == 'T')
- RETURN_IF_ERROR (demangle_template_param (dm));
- else if (peek == 'L')
+ if (mods->mod->type == DEMANGLE_COMPONENT_FUNCTION_TYPE)
+ {
+ d_print_function_type (dpi, mods->mod, mods->next);
+ dpi->templates = hold_dpt;
+ return;
+ }
+ else if (mods->mod->type == DEMANGLE_COMPONENT_ARRAY_TYPE)
+ {
+ d_print_array_type (dpi, mods->mod, mods->next);
+ dpi->templates = hold_dpt;
+ return;
+ }
+ else if (mods->mod->type == DEMANGLE_COMPONENT_LOCAL_NAME)
{
- /* Consume the `L'. */
- advance_char (dm);
- peek = peek_char (dm);
+ struct d_print_mod *hold_modifiers;
+ struct demangle_component *dc;
- if (peek == '_')
- RETURN_IF_ERROR (demangle_mangled_name (dm));
+ /* When this is on the modifier stack, we have pulled any
+ qualifiers off the right argument already. Otherwise, we
+ print it as usual, but don't let the left argument see any
+ modifiers. */
+
+ hold_modifiers = dpi->modifiers;
+ dpi->modifiers = NULL;
+ d_print_comp (dpi, d_left (mods->mod));
+ dpi->modifiers = hold_modifiers;
+
+ if ((dpi->options & DMGL_JAVA) == 0)
+ d_append_string_constant (dpi, "::");
else
- RETURN_IF_ERROR (demangle_literal (dm));
+ d_append_char (dpi, '.');
+
+ dc = d_right (mods->mod);
+ while (dc->type == DEMANGLE_COMPONENT_RESTRICT_THIS
+ || dc->type == DEMANGLE_COMPONENT_VOLATILE_THIS
+ || dc->type == DEMANGLE_COMPONENT_CONST_THIS)
+ dc = d_left (dc);
- RETURN_IF_ERROR (demangle_char (dm, 'E'));
+ d_print_comp (dpi, dc);
+
+ dpi->templates = hold_dpt;
+ return;
}
- else
- return STATUS_ERROR;
- return STATUS_OK;
+ d_print_mod (dpi, mods->mod);
+
+ dpi->templates = hold_dpt;
+
+ d_print_mod_list (dpi, mods->next, suffix);
}
-/* Demangles and emits a <substitution>. Sets *TEMPLATE_P to non-zero
- if the substitution is the name of a template, zero otherwise.
-
- <substitution> ::= S <seq-id> _
- ::= S_
-
- ::= St # ::std::
- ::= Sa # ::std::allocator
- ::= Sb # ::std::basic_string
- ::= Ss # ::std::basic_string<char,
- ::std::char_traits<char>,
- ::std::allocator<char> >
- ::= Si # ::std::basic_istream<char,
- std::char_traits<char> >
- ::= So # ::std::basic_ostream<char,
- std::char_traits<char> >
- ::= Sd # ::std::basic_iostream<char,
- std::char_traits<char> >
-*/
+/* Print a modifier. */
-static status_t
-demangle_substitution (dm, template_p)
- demangling_t dm;
- int *template_p;
+static void
+d_print_mod (dpi, mod)
+ struct d_print_info *dpi;
+ const struct demangle_component *mod;
{
- int seq_id;
- int peek;
- dyn_string_t text;
-
- DEMANGLE_TRACE ("substitution", dm);
+ switch (mod->type)
+ {
+ case DEMANGLE_COMPONENT_RESTRICT:
+ case DEMANGLE_COMPONENT_RESTRICT_THIS:
+ d_append_string_constant (dpi, " restrict");
+ return;
+ case DEMANGLE_COMPONENT_VOLATILE:
+ case DEMANGLE_COMPONENT_VOLATILE_THIS:
+ d_append_string_constant (dpi, " volatile");
+ return;
+ case DEMANGLE_COMPONENT_CONST:
+ case DEMANGLE_COMPONENT_CONST_THIS:
+ d_append_string_constant (dpi, " const");
+ return;
+ case DEMANGLE_COMPONENT_VENDOR_TYPE_QUAL:
+ d_append_char (dpi, ' ');
+ d_print_comp (dpi, d_right (mod));
+ return;
+ case DEMANGLE_COMPONENT_POINTER:
+ /* There is no pointer symbol in Java. */
+ if ((dpi->options & DMGL_JAVA) == 0)
+ d_append_char (dpi, '*');
+ return;
+ case DEMANGLE_COMPONENT_REFERENCE:
+ d_append_char (dpi, '&');
+ return;
+ case DEMANGLE_COMPONENT_COMPLEX:
+ d_append_string_constant (dpi, "complex ");
+ return;
+ case DEMANGLE_COMPONENT_IMAGINARY:
+ d_append_string_constant (dpi, "imaginary ");
+ return;
+ case DEMANGLE_COMPONENT_PTRMEM_TYPE:
+ if (d_last_char (dpi) != '(')
+ d_append_char (dpi, ' ');
+ d_print_comp (dpi, d_left (mod));
+ d_append_string_constant (dpi, "::*");
+ return;
+ case DEMANGLE_COMPONENT_TYPED_NAME:
+ d_print_comp (dpi, d_left (mod));
+ return;
+ default:
+ /* Otherwise, we have something that won't go back on the
+ modifier stack, so we can just print it. */
+ d_print_comp (dpi, mod);
+ return;
+ }
+}
- RETURN_IF_ERROR (demangle_char (dm, 'S'));
+/* Print a function type, except for the return type. */
- /* Scan the substitution sequence index. A missing number denotes
- the first index. */
- peek = peek_char (dm);
- if (peek == '_')
- seq_id = -1;
- /* If the following character is 0-9 or a capital letter, interpret
- the sequence up to the next underscore as a base-36 substitution
- index. */
- else if (IS_DIGIT ((unsigned char) peek)
- || (peek >= 'A' && peek <= 'Z'))
- RETURN_IF_ERROR (demangle_number (dm, &seq_id, 36, 0));
- else
+static void
+d_print_function_type (dpi, dc, mods)
+ struct d_print_info *dpi;
+ const struct demangle_component *dc;
+ struct d_print_mod *mods;
+{
+ int need_paren;
+ int saw_mod;
+ struct d_print_mod *p;
+ struct d_print_mod *hold_modifiers;
+
+ need_paren = 0;
+ saw_mod = 0;
+ for (p = mods; p != NULL; p = p->next)
{
- const char *new_last_source_name = NULL;
+ if (p->printed)
+ break;
- switch (peek)
+ saw_mod = 1;
+ switch (p->mod->type)
{
- case 't':
- RETURN_IF_ERROR (result_add (dm, "std"));
- break;
-
- case 'a':
- RETURN_IF_ERROR (result_add (dm, "std::allocator"));
- new_last_source_name = "allocator";
- *template_p = 1;
+ case DEMANGLE_COMPONENT_RESTRICT:
+ case DEMANGLE_COMPONENT_VOLATILE:
+ case DEMANGLE_COMPONENT_CONST:
+ case DEMANGLE_COMPONENT_VENDOR_TYPE_QUAL:
+ case DEMANGLE_COMPONENT_POINTER:
+ case DEMANGLE_COMPONENT_REFERENCE:
+ case DEMANGLE_COMPONENT_COMPLEX:
+ case DEMANGLE_COMPONENT_IMAGINARY:
+ case DEMANGLE_COMPONENT_PTRMEM_TYPE:
+ need_paren = 1;
break;
-
- case 'b':
- RETURN_IF_ERROR (result_add (dm, "std::basic_string"));
- new_last_source_name = "basic_string";
- *template_p = 1;
+ case DEMANGLE_COMPONENT_RESTRICT_THIS:
+ case DEMANGLE_COMPONENT_VOLATILE_THIS:
+ case DEMANGLE_COMPONENT_CONST_THIS:
break;
-
- case 's':
- if (!flag_verbose)
- {
- RETURN_IF_ERROR (result_add (dm, "std::string"));
- new_last_source_name = "string";
- }
- else
- {
- RETURN_IF_ERROR (result_add (dm, "std::basic_string<char, std::char_traits<char>, std::allocator<char> >"));
- new_last_source_name = "basic_string";
- }
- *template_p = 0;
+ default:
break;
+ }
+ if (need_paren)
+ break;
+ }
- case 'i':
- if (!flag_verbose)
- {
- RETURN_IF_ERROR (result_add (dm, "std::istream"));
- new_last_source_name = "istream";
- }
- else
- {
- RETURN_IF_ERROR (result_add (dm, "std::basic_istream<char, std::char_traints<char> >"));
- new_last_source_name = "basic_istream";
- }
- *template_p = 0;
+ if (d_left (dc) != NULL && ! saw_mod)
+ need_paren = 1;
+
+ if (need_paren)
+ {
+ switch (d_last_char (dpi))
+ {
+ case ' ':
+ case '(':
+ case '*':
break;
- case 'o':
- if (!flag_verbose)
- {
- RETURN_IF_ERROR (result_add (dm, "std::ostream"));
- new_last_source_name = "ostream";
- }
- else
- {
- RETURN_IF_ERROR (result_add (dm, "std::basic_ostream<char, std::char_traits<char> >"));
- new_last_source_name = "basic_ostream";
- }
- *template_p = 0;
+ default:
+ d_append_char (dpi, ' ');
break;
+ }
+
+ d_append_char (dpi, '(');
+ }
+
+ hold_modifiers = dpi->modifiers;
+ dpi->modifiers = NULL;
- case 'd':
- if (!flag_verbose)
+ d_print_mod_list (dpi, mods, 0);
+
+ if (need_paren)
+ d_append_char (dpi, ')');
+
+ d_append_char (dpi, '(');
+
+ if (d_right (dc) != NULL)
+ d_print_comp (dpi, d_right (dc));
+
+ d_append_char (dpi, ')');
+
+ d_print_mod_list (dpi, mods, 1);
+
+ dpi->modifiers = hold_modifiers;
+}
+
+/* Print an array type, except for the element type. */
+
+static void
+d_print_array_type (dpi, dc, mods)
+ struct d_print_info *dpi;
+ const struct demangle_component *dc;
+ struct d_print_mod *mods;
+{
+ int need_space;
+
+ need_space = 1;
+ if (mods != NULL)
+ {
+ int need_paren;
+ struct d_print_mod *p;
+
+ need_paren = 0;
+ for (p = mods; p != NULL; p = p->next)
+ {
+ if (p->printed)
+ break;
+
+ if (p->mod->type == DEMANGLE_COMPONENT_ARRAY_TYPE)
{
- RETURN_IF_ERROR (result_add (dm, "std::iostream"));
- new_last_source_name = "iostream";
+ need_space = 0;
+ break;
}
else
{
- RETURN_IF_ERROR (result_add (dm, "std::basic_iostream<char, std::char_traits<char> >"));
- new_last_source_name = "basic_iostream";
+ need_paren = 1;
+ need_space = 1;
+ break;
}
- *template_p = 0;
- break;
-
- default:
- return "Unrecognized <substitution>.";
}
-
- /* Consume the character we just processed. */
- advance_char (dm);
- if (new_last_source_name != NULL)
- {
- if (!dyn_string_copy_cstr (dm->last_source_name,
- new_last_source_name))
- return STATUS_ALLOCATION_FAILED;
- }
+ if (need_paren)
+ d_append_string_constant (dpi, " (");
+
+ d_print_mod_list (dpi, mods, 0);
- return STATUS_OK;
+ if (need_paren)
+ d_append_char (dpi, ')');
}
- /* Look up the substitution text. Since `S_' is the most recent
- substitution, `S0_' is the second-most-recent, etc., shift the
- numbering by one. */
- text = substitution_get (dm, seq_id + 1, template_p);
- if (text == NULL)
- return "Substitution number out of range.";
+ if (need_space)
+ d_append_char (dpi, ' ');
- /* Emit the substitution text. */
- RETURN_IF_ERROR (result_add_string (dm, text));
+ d_append_char (dpi, '[');
- RETURN_IF_ERROR (demangle_char (dm, '_'));
- return STATUS_OK;
-}
+ if (d_left (dc) != NULL)
+ d_print_comp (dpi, d_left (dc));
-/* Demangles and emits a <local-name>.
+ d_append_char (dpi, ']');
+}
- <local-name> := Z <function encoding> E <entity name> [<discriminator>]
- := Z <function encoding> E s [<discriminator>] */
+/* Print an operator in an expression. */
-static status_t
-demangle_local_name (dm)
- demangling_t dm;
+static void
+d_print_expr_op (dpi, dc)
+ struct d_print_info *dpi;
+ const struct demangle_component *dc;
{
- DEMANGLE_TRACE ("local-name", dm);
+ if (dc->type == DEMANGLE_COMPONENT_OPERATOR)
+ d_append_buffer (dpi, dc->u.s_operator.op->name,
+ dc->u.s_operator.op->len);
+ else
+ d_print_comp (dpi, dc);
+}
- RETURN_IF_ERROR (demangle_char (dm, 'Z'));
- RETURN_IF_ERROR (demangle_encoding (dm));
- RETURN_IF_ERROR (demangle_char (dm, 'E'));
- RETURN_IF_ERROR (result_add (dm, "::"));
+/* Print a cast. */
- if (peek_char (dm) == 's')
- {
- /* Local character string literal. */
- RETURN_IF_ERROR (result_add (dm, "string literal"));
- /* Consume the s. */
- advance_char (dm);
- RETURN_IF_ERROR (demangle_discriminator (dm, 0));
- }
+static void
+d_print_cast (dpi, dc)
+ struct d_print_info *dpi;
+ const struct demangle_component *dc;
+{
+ if (d_left (dc)->type != DEMANGLE_COMPONENT_TEMPLATE)
+ d_print_comp (dpi, d_left (dc));
else
{
- int unused;
- /* Local name for some other entity. Demangle its name. */
- RETURN_IF_ERROR (demangle_name (dm, &unused));
- RETURN_IF_ERROR (demangle_discriminator (dm, 1));
- }
-
- return STATUS_OK;
- }
-
- /* Optimonally demangles and emits a <discriminator>. If there is no
- <discriminator> at the current position in the mangled string, the
- descriminator is assumed to be zero. Emit the discriminator number
- in parentheses, unless SUPPRESS_FIRST is non-zero and the
- discriminator is zero.
-
- <discriminator> ::= _ <number> */
-
-static status_t
-demangle_discriminator (dm, suppress_first)
- demangling_t dm;
- int suppress_first;
-{
- /* Output for <discriminator>s to the demangled name is completely
- suppressed if not in verbose mode. */
+ struct d_print_mod *hold_dpm;
+ struct d_print_template dpt;
- if (peek_char (dm) == '_')
- {
- /* Consume the underscore. */
- advance_char (dm);
- if (flag_verbose)
- RETURN_IF_ERROR (result_add (dm, " [#"));
- /* Check if there's a number following the underscore. */
- if (IS_DIGIT ((unsigned char) peek_char (dm)))
- {
- int discriminator;
- /* Demangle the number. */
- RETURN_IF_ERROR (demangle_number (dm, &discriminator, 10, 0));
- if (flag_verbose)
- /* Write the discriminator. The mangled number is two
- less than the discriminator ordinal, counting from
- zero. */
- RETURN_IF_ERROR (int_to_dyn_string (discriminator + 1,
- (dyn_string_t) dm->result));
- }
- else
- return STATUS_ERROR;
- if (flag_verbose)
- RETURN_IF_ERROR (result_add_char (dm, ']'));
- }
- else if (!suppress_first)
- {
- if (flag_verbose)
- RETURN_IF_ERROR (result_add (dm, " [#0]"));
+ /* It appears that for a templated cast operator, we need to put
+ the template parameters in scope for the operator name, but
+ not for the parameters. The effect is that we need to handle
+ the template printing here. */
+
+ hold_dpm = dpi->modifiers;
+ dpi->modifiers = NULL;
+
+ dpt.next = dpi->templates;
+ dpi->templates = &dpt;
+ dpt.template = d_left (dc);
+
+ d_print_comp (dpi, d_left (d_left (dc)));
+
+ dpi->templates = dpt.next;
+
+ if (d_last_char (dpi) == '<')
+ d_append_char (dpi, ' ');
+ d_append_char (dpi, '<');
+ d_print_comp (dpi, d_right (d_left (dc)));
+ /* Avoid generating two consecutive '>' characters, to avoid
+ the C++ syntactic ambiguity. */
+ if (d_last_char (dpi) == '>')
+ d_append_char (dpi, ' ');
+ d_append_char (dpi, '>');
+
+ dpi->modifiers = hold_dpm;
}
+}
+
+/* Initialize the information structure we use to pass around
+ information. */
- return STATUS_OK;
+CP_STATIC_IF_GLIBCPP_V3
+void
+cplus_demangle_init_info (mangled, options, len, di)
+ const char *mangled;
+ int options;
+ size_t len;
+ struct d_info *di;
+{
+ di->s = mangled;
+ di->send = mangled + len;
+ di->options = options;
+
+ di->n = mangled;
+
+ /* We can not need more components than twice the number of chars in
+ the mangled string. Most components correspond directly to
+ chars, but the ARGLIST types are exceptions. */
+ di->num_comps = 2 * len;
+ di->next_comp = 0;
+
+ /* Similarly, we can not need more substitutions than there are
+ chars in the mangled string. */
+ di->num_subs = len;
+ di->next_sub = 0;
+ di->did_subs = 0;
+
+ di->last_name = NULL;
+
+ di->expansion = 0;
}
-/* Demangle NAME into RESULT, which must be an initialized
- dyn_string_t. On success, returns STATUS_OK. On failure, returns
- an error message, and the contents of RESULT are unchanged. */
+/* Entry point for the demangler. If MANGLED is a g++ v3 ABI mangled
+ name, return a buffer allocated with malloc holding the demangled
+ name. OPTIONS is the usual libiberty demangler options. On
+ success, this sets *PALC to the allocated size of the returned
+ buffer. On failure, this sets *PALC to 0 for a bad name, or 1 for
+ a memory allocation failure. On failure, this returns NULL. */
-static status_t
-cp_demangle (name, result, style)
- const char *name;
- dyn_string_t result;
- int style;
+static char *
+d_demangle (mangled, options, palc)
+ const char* mangled;
+ int options;
+ size_t *palc;
{
- status_t status;
- int length = strlen (name);
+ size_t len;
+ int type;
+ struct d_info di;
+ struct demangle_component *dc;
+ int estimate;
+ char *ret;
- if (length > 2 && name[0] == '_' && name[1] == 'Z')
- {
- demangling_t dm = demangling_new (name, style);
- if (dm == NULL)
- return STATUS_ALLOCATION_FAILED;
+ *palc = 0;
- status = result_push (dm);
- if (status != STATUS_OK)
- {
- demangling_delete (dm);
- return status;
- }
+ len = strlen (mangled);
+
+ if (mangled[0] == '_' && mangled[1] == 'Z')
+ type = 0;
+ else if (strncmp (mangled, "_GLOBAL_", 8) == 0
+ && (mangled[8] == '.' || mangled[8] == '_' || mangled[8] == '$')
+ && (mangled[9] == 'D' || mangled[9] == 'I')
+ && mangled[10] == '_')
+ {
+ char *r;
- status = demangle_mangled_name (dm);
- if (STATUS_NO_ERROR (status))
+ r = malloc (40 + len - 11);
+ if (r == NULL)
+ *palc = 1;
+ else
{
- dyn_string_t demangled = (dyn_string_t) result_pop (dm);
- if (!dyn_string_copy (result, demangled))
- return STATUS_ALLOCATION_FAILED;
- dyn_string_delete (demangled);
+ if (mangled[9] == 'I')
+ strcpy (r, "global constructors keyed to ");
+ else
+ strcpy (r, "global destructors keyed to ");
+ strcat (r, mangled + 11);
}
-
- demangling_delete (dm);
+ return r;
}
else
{
- /* It's evidently not a mangled C++ name. It could be the name
- of something with C linkage, though, so just copy NAME into
- RESULT. */
- if (!dyn_string_copy_cstr (result, name))
- return STATUS_ALLOCATION_FAILED;
- status = STATUS_OK;
+ if ((options & DMGL_TYPES) == 0)
+ return NULL;
+ type = 1;
}
- return status;
-}
+ cplus_demangle_init_info (mangled, options, len, &di);
-/* Demangle TYPE_NAME into RESULT, which must be an initialized
- dyn_string_t. On success, returns STATUS_OK. On failiure, returns
- an error message, and the contents of RESULT are unchanged. */
+ {
+#ifdef CP_DYNAMIC_ARRAYS
+ __extension__ struct demangle_component comps[di.num_comps];
+ __extension__ struct demangle_component *subs[di.num_subs];
-static status_t
-cp_demangle_type (type_name, result)
- const char* type_name;
- dyn_string_t result;
-{
- status_t status;
- demangling_t dm = demangling_new (type_name, DMGL_GNU_V3);
-
- if (dm == NULL)
- return STATUS_ALLOCATION_FAILED;
-
- /* Demangle the type name. The demangled name is stored in dm. */
- status = result_push (dm);
- if (status != STATUS_OK)
- {
- demangling_delete (dm);
- return status;
- }
+ di.comps = &comps[0];
+ di.subs = &subs[0];
+#else
+ di.comps = ((struct demangle_component *)
+ malloc (di.num_comps * sizeof (struct demangle_component)));
+ di.subs = ((struct demangle_component **)
+ malloc (di.num_subs * sizeof (struct demangle_component *)));
+ if (di.comps == NULL || di.subs == NULL)
+ {
+ if (di.comps != NULL)
+ free (di.comps);
+ if (di.subs != NULL)
+ free (di.subs);
+ *palc = 1;
+ return NULL;
+ }
+#endif
- status = demangle_type (dm);
+ if (! type)
+ dc = cplus_demangle_mangled_name (&di, 1);
+ else
+ dc = cplus_demangle_type (&di);
- if (STATUS_NO_ERROR (status))
- {
- /* The demangling succeeded. Pop the result out of dm and copy
- it into RESULT. */
- dyn_string_t demangled = (dyn_string_t) result_pop (dm);
- if (!dyn_string_copy (result, demangled))
- return STATUS_ALLOCATION_FAILED;
- dyn_string_delete (demangled);
- }
+ /* If DMGL_PARAMS is set, then if we didn't consume the entire
+ mangled string, then we didn't successfully demangle it. If
+ DMGL_PARAMS is not set, we didn't look at the trailing
+ parameters. */
+ if (((options & DMGL_PARAMS) != 0) && d_peek_char (&di) != '\0')
+ dc = NULL;
+
+#ifdef CP_DEMANGLE_DEBUG
+ if (dc == NULL)
+ printf ("failed demangling\n");
+ else
+ d_dump (dc, 0);
+#endif
+
+ /* We try to guess the length of the demangled string, to minimize
+ calls to realloc during demangling. */
+ estimate = len + di.expansion + 10 * di.did_subs;
+ estimate += estimate / 8;
+
+ ret = NULL;
+ if (dc != NULL)
+ ret = cplus_demangle_print (options, dc, estimate, palc);
+
+#ifndef CP_DYNAMIC_ARRAYS
+ free (di.comps);
+ free (di.subs);
+#endif
- /* Clean up. */
- demangling_delete (dm);
+#ifdef CP_DEMANGLE_DEBUG
+ if (ret != NULL)
+ {
+ int rlen;
+
+ rlen = strlen (ret);
+ if (rlen > 2 * estimate)
+ printf ("*** Length %d much greater than estimate %d\n",
+ rlen, estimate);
+ else if (rlen > estimate)
+ printf ("*** Length %d greater than estimate %d\n",
+ rlen, estimate);
+ else if (rlen < estimate / 2)
+ printf ("*** Length %d much less than estimate %d\n",
+ rlen, estimate);
+ }
+#endif
+ }
- return status;
+ return ret;
}
#if defined(IN_LIBGCC2) || defined(IN_GLIBCPP_V3)
+
extern char *__cxa_demangle PARAMS ((const char *, char *, size_t *, int *));
-/* ia64 ABI-mandated entry point in the C++ runtime library for performing
- demangling. MANGLED_NAME is a NUL-terminated character string
- containing the name to be demangled.
+/* ia64 ABI-mandated entry point in the C++ runtime library for
+ performing demangling. MANGLED_NAME is a NUL-terminated character
+ string containing the name to be demangled.
OUTPUT_BUFFER is a region of memory, allocated with malloc, of
*LENGTH bytes, into which the demangled name is stored. If
OUTPUT_BUFFER is not long enough, it is expanded using realloc.
OUTPUT_BUFFER may instead be NULL; in that case, the demangled name
- is placed in a region of memory allocated with malloc.
+ is placed in a region of memory allocated with malloc.
If LENGTH is non-NULL, the length of the buffer conaining the
- demangled name, is placed in *LENGTH.
+ demangled name, is placed in *LENGTH.
The return value is a pointer to the start of the NUL-terminated
demangled name, or NULL if the demangling fails. The caller is
- responsible for deallocating this memory using free.
+ responsible for deallocating this memory using free.
*STATUS is set to one of the following values:
0: The demangling operation succeeded.
- -1: A memory allocation failiure occurred.
+ -1: A memory allocation failure occurred.
-2: MANGLED_NAME is not a valid name under the C++ ABI mangling rules.
-3: One of the arguments is invalid.
- The demagling is performed using the C++ ABI mangling rules, with
+ The demangling is performed using the C++ ABI mangling rules, with
GNU extensions. */
char *
@@ -3674,137 +3941,74 @@ __cxa_demangle (mangled_name, output_buffer, length, status)
size_t *length;
int *status;
{
- struct dyn_string demangled_name;
- status_t result;
+ char *demangled;
+ size_t alc;
if (status == NULL)
return NULL;
- if (mangled_name == NULL) {
- *status = -3;
- return NULL;
- }
+ if (mangled_name == NULL)
+ {
+ *status = -3;
+ return NULL;
+ }
- /* Did the caller provide a buffer for the demangled name? */
- if (output_buffer == NULL) {
- /* No; dyn_string will malloc a buffer for us. */
- if (!dyn_string_init (&demangled_name, 0))
- {
- *status = -1;
- return NULL;
- }
- }
- else {
- /* Yes. Check that the length was provided. */
- if (length == NULL) {
+ if (output_buffer != NULL && length == NULL)
+ {
*status = -3;
return NULL;
}
- /* Install the buffer into a dyn_string. */
- demangled_name.allocated = *length;
- demangled_name.length = 0;
- demangled_name.s = output_buffer;
- }
- if (mangled_name[0] == '_' && mangled_name[1] == 'Z')
- /* MANGLED_NAME apprears to be a function or variable name.
- Demangle it accordingly. */
- result = cp_demangle (mangled_name, &demangled_name, 0);
- else
- /* Try to demangled MANGLED_NAME as the name of a type. */
- result = cp_demangle_type (mangled_name, &demangled_name);
+ demangled = d_demangle (mangled_name, DMGL_TYPES, &alc);
- if (result == STATUS_OK)
- /* The demangling succeeded. */
+ if (demangled == NULL)
{
- /* If LENGTH isn't NULL, store the allocated buffer length
- there; the buffer may have been realloced by dyn_string
- functions. */
- if (length != NULL)
- *length = demangled_name.allocated;
- /* The operation was a success. */
- *status = 0;
- return dyn_string_buf (&demangled_name);
+ if (alc == 1)
+ *status = -1;
+ else
+ *status = -2;
+ return NULL;
}
- else if (result == STATUS_ALLOCATION_FAILED)
- /* A call to malloc or realloc failed during the demangling
- operation. */
+
+ if (output_buffer == NULL)
{
- *status = -1;
- return NULL;
+ if (length != NULL)
+ *length = alc;
}
else
- /* The demangling failed for another reason, most probably because
- MANGLED_NAME isn't a valid mangled name. */
{
- /* If the buffer containing the demangled name wasn't provided
- by the caller, free it. */
- if (output_buffer == NULL)
- free (dyn_string_buf (&demangled_name));
- *status = -2;
- return NULL;
+ if (strlen (demangled) < *length)
+ {
+ strcpy (output_buffer, demangled);
+ free (demangled);
+ demangled = output_buffer;
+ }
+ else
+ {
+ free (output_buffer);
+ *length = alc;
+ }
}
+
+ *status = 0;
+
+ return demangled;
}
#else /* ! (IN_LIBGCC2 || IN_GLIBCPP_V3) */
-/* Variant entry point for integration with the existing cplus-dem
- demangler. Attempts to demangle MANGLED. If the demangling
- succeeds, returns a buffer, allocated with malloc, containing the
- demangled name. The caller must deallocate the buffer using free.
- If the demangling failes, returns NULL. */
+/* Entry point for libiberty demangler. If MANGLED is a g++ v3 ABI
+ mangled name, return a buffer allocated with malloc holding the
+ demangled name. Otherwise, return NULL. */
char *
cplus_demangle_v3 (mangled, options)
const char* mangled;
int options;
{
- dyn_string_t demangled;
- status_t status;
- int type = !!(options & DMGL_TYPES);
-
- if (mangled[0] == '_' && mangled[1] == 'Z')
- /* It is not a type. */
- type = 0;
- else
- {
- /* It is a type. Stop if we don't want to demangle types. */
- if (!type)
- return NULL;
- }
-
- flag_verbose = !!(options & DMGL_VERBOSE);
+ size_t alc;
- /* Create a dyn_string to hold the demangled name. */
- demangled = dyn_string_new (0);
- /* Attempt the demangling. */
- if (!type)
- /* Appears to be a function or variable name. */
- status = cp_demangle (mangled, demangled, 0);
- else
- /* Try to demangle it as the name of a type. */
- status = cp_demangle_type (mangled, demangled);
-
- if (STATUS_NO_ERROR (status))
- /* Demangling succeeded. */
- {
- /* Grab the demangled result from the dyn_string. It was
- allocated with malloc, so we can return it directly. */
- char *return_value = dyn_string_release (demangled);
- /* Hand back the demangled name. */
- return return_value;
- }
- else if (status == STATUS_ALLOCATION_FAILED)
- {
- fprintf (stderr, "Memory allocation failed.\n");
- abort ();
- }
- else
- /* Demangling failed. */
- {
- dyn_string_delete (demangled);
- return NULL;
- }
+ return d_demangle (mangled, options, &alc);
}
/* Demangle a Java symbol. Java uses a subset of the V3 ABI C++ mangling
@@ -3818,195 +4022,179 @@ char *
java_demangle_v3 (mangled)
const char* mangled;
{
- dyn_string_t demangled;
- char *next;
- char *end;
- int len;
- status_t status;
- int nesting = 0;
- char *cplus_demangled;
- char *return_value;
-
- /* Create a dyn_string to hold the demangled name. */
- demangled = dyn_string_new (0);
-
- /* Attempt the demangling. */
- status = cp_demangle ((char *) mangled, demangled, DMGL_JAVA);
-
- if (STATUS_NO_ERROR (status))
- /* Demangling succeeded. */
- {
- /* Grab the demangled result from the dyn_string. */
- cplus_demangled = dyn_string_release (demangled);
- }
- else if (status == STATUS_ALLOCATION_FAILED)
- {
- fprintf (stderr, "Memory allocation failed.\n");
- abort ();
- }
- else
- /* Demangling failed. */
- {
- dyn_string_delete (demangled);
- return NULL;
- }
-
- len = strlen (cplus_demangled);
- next = cplus_demangled;
- end = next + len;
- demangled = NULL;
-
- /* Replace occurances of JArray<TYPE> with TYPE[]. */
- while (next < end)
+ size_t alc;
+ char *demangled;
+ int nesting;
+ char *from;
+ char *to;
+
+ demangled = d_demangle (mangled, DMGL_JAVA | DMGL_PARAMS, &alc);
+
+ if (demangled == NULL)
+ return NULL;
+
+ nesting = 0;
+ from = demangled;
+ to = from;
+ while (*from != '\0')
{
- char *open_str = strstr (next, "JArray<");
- char *close_str = NULL;
- if (nesting > 0)
- close_str = strchr (next, '>');
-
- if (open_str != NULL && (close_str == NULL || close_str > open_str))
- {
+ if (strncmp (from, "JArray<", 7) == 0)
+ {
+ from += 7;
++nesting;
-
- if (!demangled)
- demangled = dyn_string_new(len);
-
- /* Copy prepending symbols, if any. */
- if (open_str > next)
- {
- open_str[0] = 0;
- dyn_string_append_cstr (demangled, next);
- }
- next = open_str + 7;
}
- else if (close_str != NULL)
- {
+ else if (nesting > 0 && *from == '>')
+ {
+ while (to > demangled && to[-1] == ' ')
+ --to;
+ *to++ = '[';
+ *to++ = ']';
--nesting;
-
- /* Copy prepending type symbol, if any. Squash any spurious
- whitespace. */
- if (close_str > next && next[0] != ' ')
- {
- close_str[0] = 0;
- dyn_string_append_cstr (demangled, next);
- }
- dyn_string_append_cstr (demangled, "[]");
- next = close_str + 1;
+ ++from;
}
else
- {
- /* There are no more arrays. Copy the rest of the symbol, or
- simply return the original symbol if no changes were made. */
- if (next == cplus_demangled)
- return cplus_demangled;
-
- dyn_string_append_cstr (demangled, next);
- next = end;
- }
+ *to++ = *from++;
}
- free (cplus_demangled);
-
- if (demangled)
- return_value = dyn_string_release (demangled);
- else
- return_value = NULL;
+ *to = '\0';
- return return_value;
+ return demangled;
}
#endif /* IN_LIBGCC2 || IN_GLIBCPP_V3 */
-
#ifndef IN_GLIBCPP_V3
-/* Demangle NAME in the G++ V3 ABI demangling style, and return either
- zero, indicating that some error occurred, or a demangling_t
- holding the results. */
-static demangling_t
-demangle_v3_with_details (name)
- const char *name;
+
+/* Demangle a string in order to find out whether it is a constructor
+ or destructor. Return non-zero on success. Set *CTOR_KIND and
+ *DTOR_KIND appropriately. */
+
+static int
+is_ctor_or_dtor (mangled, ctor_kind, dtor_kind)
+ const char *mangled;
+ enum gnu_v3_ctor_kinds *ctor_kind;
+ enum gnu_v3_dtor_kinds *dtor_kind;
{
- demangling_t dm;
- status_t status;
+ struct d_info di;
+ struct demangle_component *dc;
+ int ret;
- if (strncmp (name, "_Z", 2))
- return 0;
+ *ctor_kind = (enum gnu_v3_ctor_kinds) 0;
+ *dtor_kind = (enum gnu_v3_dtor_kinds) 0;
- dm = demangling_new (name, DMGL_GNU_V3);
- if (dm == NULL)
- {
- fprintf (stderr, "Memory allocation failed.\n");
- abort ();
- }
+ cplus_demangle_init_info (mangled, DMGL_GNU_V3, strlen (mangled), &di);
- status = result_push (dm);
- if (! STATUS_NO_ERROR (status))
- {
- demangling_delete (dm);
- fprintf (stderr, "%s\n", status);
- abort ();
- }
+ {
+#ifdef CP_DYNAMIC_ARRAYS
+ __extension__ struct demangle_component comps[di.num_comps];
+ __extension__ struct demangle_component *subs[di.num_subs];
- status = demangle_mangled_name (dm);
- if (STATUS_NO_ERROR (status))
- return dm;
+ di.comps = &comps[0];
+ di.subs = &subs[0];
+#else
+ di.comps = ((struct demangle_component *)
+ malloc (di.num_comps * sizeof (struct demangle_component)));
+ di.subs = ((struct demangle_component **)
+ malloc (di.num_subs * sizeof (struct demangle_component *)));
+ if (di.comps == NULL || di.subs == NULL)
+ {
+ if (di.comps != NULL)
+ free (di.comps);
+ if (di.subs != NULL)
+ free (di.subs);
+ return 0;
+ }
+#endif
- demangling_delete (dm);
- return 0;
+ dc = cplus_demangle_mangled_name (&di, 1);
+
+ /* Note that because we did not pass DMGL_PARAMS, we don't expect
+ to demangle the entire string. */
+
+ ret = 0;
+ while (dc != NULL)
+ {
+ switch (dc->type)
+ {
+ default:
+ dc = NULL;
+ break;
+ case DEMANGLE_COMPONENT_TYPED_NAME:
+ case DEMANGLE_COMPONENT_TEMPLATE:
+ case DEMANGLE_COMPONENT_RESTRICT_THIS:
+ case DEMANGLE_COMPONENT_VOLATILE_THIS:
+ case DEMANGLE_COMPONENT_CONST_THIS:
+ dc = d_left (dc);
+ break;
+ case DEMANGLE_COMPONENT_QUAL_NAME:
+ case DEMANGLE_COMPONENT_LOCAL_NAME:
+ dc = d_right (dc);
+ break;
+ case DEMANGLE_COMPONENT_CTOR:
+ *ctor_kind = dc->u.s_ctor.kind;
+ ret = 1;
+ dc = NULL;
+ break;
+ case DEMANGLE_COMPONENT_DTOR:
+ *dtor_kind = dc->u.s_dtor.kind;
+ ret = 1;
+ dc = NULL;
+ break;
+ }
+ }
+
+#ifndef CP_DYNAMIC_ARRAYS
+ free (di.subs);
+ free (di.comps);
+#endif
+ }
+
+ return ret;
}
+/* Return whether NAME is the mangled form of a g++ V3 ABI constructor
+ name. A non-zero return indicates the type of constructor. */
-/* Return non-zero iff NAME is the mangled form of a constructor name
- in the G++ V3 ABI demangling style. Specifically, return:
- - '1' if NAME is a complete object constructor,
- - '2' if NAME is a base object constructor, or
- - '3' if NAME is a complete object allocating constructor. */
enum gnu_v3_ctor_kinds
is_gnu_v3_mangled_ctor (name)
const char *name;
{
- demangling_t dm = demangle_v3_with_details (name);
+ enum gnu_v3_ctor_kinds ctor_kind;
+ enum gnu_v3_dtor_kinds dtor_kind;
- if (dm)
- {
- enum gnu_v3_ctor_kinds result = dm->is_constructor;
- demangling_delete (dm);
- return result;
- }
- else
- return 0;
+ if (! is_ctor_or_dtor (name, &ctor_kind, &dtor_kind))
+ return (enum gnu_v3_ctor_kinds) 0;
+ return ctor_kind;
}
-/* Return non-zero iff NAME is the mangled form of a destructor name
- in the G++ V3 ABI demangling style. Specifically, return:
- - '0' if NAME is a deleting destructor,
- - '1' if NAME is a complete object destructor, or
- - '2' if NAME is a base object destructor. */
+/* Return whether NAME is the mangled form of a g++ V3 ABI destructor
+ name. A non-zero return indicates the type of destructor. */
+
enum gnu_v3_dtor_kinds
is_gnu_v3_mangled_dtor (name)
const char *name;
{
- demangling_t dm = demangle_v3_with_details (name);
+ enum gnu_v3_ctor_kinds ctor_kind;
+ enum gnu_v3_dtor_kinds dtor_kind;
- if (dm)
- {
- enum gnu_v3_dtor_kinds result = dm->is_destructor;
- demangling_delete (dm);
- return result;
- }
- else
- return 0;
+ if (! is_ctor_or_dtor (name, &ctor_kind, &dtor_kind))
+ return (enum gnu_v3_dtor_kinds) 0;
+ return dtor_kind;
}
-#endif /* IN_GLIBCPP_V3 */
+#endif /* IN_GLIBCPP_V3 */
#ifdef STANDALONE_DEMANGLER
#include "getopt.h"
+#include "dyn-string.h"
-static void print_usage
- PARAMS ((FILE* fp, int exit_value));
+static void print_usage PARAMS ((FILE* fp, int exit_value));
+
+#define IS_ALPHA(CHAR) \
+ (((CHAR) >= 'a' && (CHAR) <= 'z') \
+ || ((CHAR) >= 'A' && (CHAR) <= 'Z'))
/* Non-zero if CHAR is a character than can occur in a mangled name. */
#define is_mangled_char(CHAR) \
@@ -4026,7 +4214,7 @@ print_usage (fp, exit_value)
fprintf (fp, "Usage: %s [options] [names ...]\n", program_name);
fprintf (fp, "Options:\n");
fprintf (fp, " -h,--help Display this message.\n");
- fprintf (fp, " -s,--strict Demangle standard names only.\n");
+ fprintf (fp, " -p,--no-params Don't display function parameters\n");
fprintf (fp, " -v,--verbose Produce verbose demanglings.\n");
fprintf (fp, "If names are provided, they are demangled. Otherwise filters standard input.\n");
@@ -4036,10 +4224,10 @@ print_usage (fp, exit_value)
/* Option specification for getopt_long. */
static const struct option long_options[] =
{
- { "help", no_argument, NULL, 'h' },
- { "strict", no_argument, NULL, 's' },
- { "verbose", no_argument, NULL, 'v' },
- { NULL, no_argument, NULL, 0 },
+ { "help", no_argument, NULL, 'h' },
+ { "no-params", no_argument, NULL, 'p' },
+ { "verbose", no_argument, NULL, 'v' },
+ { NULL, no_argument, NULL, 0 },
};
/* Main entry for a demangling filter executable. It will demangle
@@ -4052,9 +4240,9 @@ main (argc, argv)
int argc;
char *argv[];
{
- status_t status;
int i;
int opt_char;
+ int options = DMGL_PARAMS | DMGL_ANSI | DMGL_TYPES;
/* Use the program name of this program, as invoked. */
program_name = argv[0];
@@ -4062,7 +4250,7 @@ main (argc, argv)
/* Parse options. */
do
{
- opt_char = getopt_long (argc, argv, "hsv", long_options, NULL);
+ opt_char = getopt_long (argc, argv, "hpv", long_options, NULL);
switch (opt_char)
{
case '?': /* Unrecognized option. */
@@ -4073,12 +4261,12 @@ main (argc, argv)
print_usage (stdout, 0);
break;
- case 's':
- flag_strict = 1;
+ case 'p':
+ options &= ~ DMGL_PARAMS;
break;
case 'v':
- flag_verbose = 1;
+ options |= DMGL_VERBOSE;
break;
}
}
@@ -4088,41 +4276,12 @@ main (argc, argv)
/* No command line arguments were provided. Filter stdin. */
{
dyn_string_t mangled = dyn_string_new (3);
- dyn_string_t demangled = dyn_string_new (0);
- status_t status;
+ char *s;
/* Read all of input. */
while (!feof (stdin))
{
- char c = getchar ();
-
- /* The first character of a mangled name is an underscore. */
- if (feof (stdin))
- break;
- if (c != '_')
- {
- /* It's not a mangled name. Print the character and go
- on. */
- putchar (c);
- continue;
- }
- c = getchar ();
-
- /* The second character of a mangled name is a capital `Z'. */
- if (feof (stdin))
- break;
- if (c != 'Z')
- {
- /* It's not a mangled name. Print the previous
- underscore, the `Z', and go on. */
- putchar ('_');
- putchar (c);
- continue;
- }
-
- /* Start keeping track of the candidate mangled name. */
- dyn_string_append_char (mangled, '_');
- dyn_string_append_char (mangled, 'Z');
+ char c;
/* Pile characters into mangled until we hit one that can't
occur in a mangled name. */
@@ -4135,62 +4294,53 @@ main (argc, argv)
c = getchar ();
}
- /* Attempt to demangle the name. */
- status = cp_demangle (dyn_string_buf (mangled), demangled, 0);
-
- /* If the demangling succeeded, great! Print out the
- demangled version. */
- if (STATUS_NO_ERROR (status))
- fputs (dyn_string_buf (demangled), stdout);
- /* Abort on allocation failures. */
- else if (status == STATUS_ALLOCATION_FAILED)
+ if (dyn_string_length (mangled) > 0)
{
- fprintf (stderr, "Memory allocation failed.\n");
- abort ();
+ s = cplus_demangle_v3 (dyn_string_buf (mangled), options);
+
+ if (s != NULL)
+ {
+ fputs (s, stdout);
+ free (s);
+ }
+ else
+ {
+ /* It might not have been a mangled name. Print the
+ original text. */
+ fputs (dyn_string_buf (mangled), stdout);
+ }
+
+ dyn_string_clear (mangled);
}
- /* Otherwise, it might not have been a mangled name. Just
- print out the original text. */
- else
- fputs (dyn_string_buf (mangled), stdout);
/* If we haven't hit EOF yet, we've read one character that
can't occur in a mangled name, so print it out. */
if (!feof (stdin))
putchar (c);
-
- /* Clear the candidate mangled name, to start afresh next
- time we hit a `_Z'. */
- dyn_string_clear (mangled);
}
dyn_string_delete (mangled);
- dyn_string_delete (demangled);
}
else
/* Demangle command line arguments. */
{
- dyn_string_t result = dyn_string_new (0);
-
/* Loop over command line arguments. */
for (i = optind; i < argc; ++i)
{
+ char *s;
+
/* Attempt to demangle. */
- status = cp_demangle (argv[i], result, 0);
+ s = cplus_demangle_v3 (argv[i], options);
/* If it worked, print the demangled name. */
- if (STATUS_NO_ERROR (status))
- printf ("%s\n", dyn_string_buf (result));
- /* Abort on allocaiton failures. */
- else if (status == STATUS_ALLOCATION_FAILED)
+ if (s != NULL)
{
- fprintf (stderr, "Memory allocation failed.\n");
- abort ();
+ printf ("%s\n", s);
+ free (s);
}
- /* If not, print the error message to stderr instead. */
- else
- fprintf (stderr, "%s\n", status);
+ else
+ fprintf (stderr, "Failed: %s\n", argv[i]);
}
- dyn_string_delete (result);
}
return 0;
diff --git a/contrib/binutils/libiberty/cp-demangle.h b/contrib/binutils/libiberty/cp-demangle.h
new file mode 100644
index 0000000..d3c57ce
--- /dev/null
+++ b/contrib/binutils/libiberty/cp-demangle.h
@@ -0,0 +1,139 @@
+/* Internal demangler interface for g++ V3 ABI.
+ Copyright (C) 2003, 2004 Free Software Foundation, Inc.
+ Written by Ian Lance Taylor <ian@wasabisystems.com>.
+
+ This file is part of the libiberty library, which is part of GCC.
+
+ This file is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ In addition to the permissions in the GNU General Public License, the
+ Free Software Foundation gives you unlimited permission to link the
+ compiled version of this file into combinations with other programs,
+ and to distribute those combinations without any restriction coming
+ from the use of this file. (The General Public License restrictions
+ do apply in other respects; for example, they cover modification of
+ the file, and distribution when not linked into a combined
+ executable.)
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+*/
+
+/* This file provides some definitions shared by cp-demangle.c and
+ cp-demint.c. It should not be included by any other files. */
+
+/* Information we keep for operators. */
+
+struct demangle_operator_info
+{
+ /* Mangled name. */
+ const char *code;
+ /* Real name. */
+ const char *name;
+ /* Length of real name. */
+ int len;
+ /* Number of arguments. */
+ int args;
+};
+
+/* How to print the value of a builtin type. */
+
+enum d_builtin_type_print
+{
+ /* Print as (type)val. */
+ D_PRINT_DEFAULT,
+ /* Print as integer. */
+ D_PRINT_INT,
+ /* Print as long, with trailing `l'. */
+ D_PRINT_LONG,
+ /* Print as bool. */
+ D_PRINT_BOOL,
+ /* Print in usual way, but here to detect void. */
+ D_PRINT_VOID
+};
+
+/* Information we keep for a builtin type. */
+
+struct demangle_builtin_type_info
+{
+ /* Type name. */
+ const char *name;
+ /* Length of type name. */
+ int len;
+ /* Type name when using Java. */
+ const char *java_name;
+ /* Length of java name. */
+ int java_len;
+ /* How to print a value of this type. */
+ enum d_builtin_type_print print;
+};
+
+/* The information structure we pass around. */
+
+struct d_info
+{
+ /* The string we are demangling. */
+ const char *s;
+ /* The end of the string we are demangling. */
+ const char *send;
+ /* The options passed to the demangler. */
+ int options;
+ /* The next character in the string to consider. */
+ const char *n;
+ /* The array of components. */
+ struct demangle_component *comps;
+ /* The index of the next available component. */
+ int next_comp;
+ /* The number of available component structures. */
+ int num_comps;
+ /* The array of substitutions. */
+ struct demangle_component **subs;
+ /* The index of the next substitution. */
+ int next_sub;
+ /* The number of available entries in the subs array. */
+ int num_subs;
+ /* The number of substitutions which we actually made from the subs
+ array, plus the number of template parameter references we
+ saw. */
+ int did_subs;
+ /* The last name we saw, for constructors and destructors. */
+ struct demangle_component *last_name;
+ /* A running total of the length of large expansions from the
+ mangled name to the demangled name, such as standard
+ substitutions and builtin types. */
+ int expansion;
+};
+
+#define d_peek_char(di) (*((di)->n))
+#define d_peek_next_char(di) ((di)->n[1])
+#define d_advance(di, i) ((di)->n += (i))
+#define d_next_char(di) (*((di)->n++))
+#define d_str(di) ((di)->n)
+
+/* Functions and arrays in cp-demangle.c which are referenced by
+ functions in cp-demint.c. */
+
+extern const struct demangle_operator_info cplus_demangle_operators[];
+
+#define D_BUILTIN_TYPE_COUNT (26)
+
+extern const struct demangle_builtin_type_info
+cplus_demangle_builtin_types[D_BUILTIN_TYPE_COUNT];
+
+extern struct demangle_component *
+cplus_demangle_mangled_name PARAMS ((struct d_info *, int));
+
+extern struct demangle_component *
+cplus_demangle_type PARAMS ((struct d_info *));
+
+extern void
+cplus_demangle_init_info PARAMS ((const char *, int, size_t, struct d_info *));
diff --git a/contrib/binutils/libiberty/cp-demint.c b/contrib/binutils/libiberty/cp-demint.c
new file mode 100644
index 0000000..533202d
--- /dev/null
+++ b/contrib/binutils/libiberty/cp-demint.c
@@ -0,0 +1,241 @@
+/* Demangler component interface functions.
+ Copyright (C) 2004 Free Software Foundation, Inc.
+ Written by Ian Lance Taylor <ian@wasabisystems.com>.
+
+ This file is part of the libiberty library, which is part of GCC.
+
+ This file is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ In addition to the permissions in the GNU General Public License, the
+ Free Software Foundation gives you unlimited permission to link the
+ compiled version of this file into combinations with other programs,
+ and to distribute those combinations without any restriction coming
+ from the use of this file. (The General Public License restrictions
+ do apply in other respects; for example, they cover modification of
+ the file, and distribution when not linked into a combined
+ executable.)
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+*/
+
+/* This file implements a few interface functions which are provided
+ for use with struct demangle_component trees. These functions are
+ declared in demangle.h. These functions are closely tied to the
+ demangler code in cp-demangle.c, and other interface functions can
+ be found in that file. We put these functions in a separate file
+ because they are not needed by the demangler, and so we avoid
+ having them pulled in by programs which only need the
+ demangler. */
+
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
+#ifdef HAVE_STDLIB_H
+#include <stdlib.h>
+#endif
+#ifdef HAVE_STRING_H
+#include <string.h>
+#endif
+
+#include "ansidecl.h"
+#include "libiberty.h"
+#include "demangle.h"
+#include "cp-demangle.h"
+
+/* Fill in most component types. */
+
+int
+cplus_demangle_fill_component (p, type, left, right)
+ struct demangle_component *p;
+ enum demangle_component_type type;
+ struct demangle_component *left;
+ struct demangle_component *right;
+{
+ if (p == NULL)
+ return 0;
+ switch (type)
+ {
+ case DEMANGLE_COMPONENT_QUAL_NAME:
+ case DEMANGLE_COMPONENT_LOCAL_NAME:
+ case DEMANGLE_COMPONENT_TYPED_NAME:
+ case DEMANGLE_COMPONENT_TEMPLATE:
+ case DEMANGLE_COMPONENT_CONSTRUCTION_VTABLE:
+ case DEMANGLE_COMPONENT_VENDOR_TYPE_QUAL:
+ case DEMANGLE_COMPONENT_FUNCTION_TYPE:
+ case DEMANGLE_COMPONENT_ARRAY_TYPE:
+ case DEMANGLE_COMPONENT_PTRMEM_TYPE:
+ case DEMANGLE_COMPONENT_ARGLIST:
+ case DEMANGLE_COMPONENT_TEMPLATE_ARGLIST:
+ case DEMANGLE_COMPONENT_UNARY:
+ case DEMANGLE_COMPONENT_BINARY:
+ case DEMANGLE_COMPONENT_BINARY_ARGS:
+ case DEMANGLE_COMPONENT_TRINARY:
+ case DEMANGLE_COMPONENT_TRINARY_ARG1:
+ case DEMANGLE_COMPONENT_TRINARY_ARG2:
+ case DEMANGLE_COMPONENT_LITERAL:
+ case DEMANGLE_COMPONENT_LITERAL_NEG:
+ break;
+
+ /* These component types only have one subtree. */
+ case DEMANGLE_COMPONENT_VTABLE:
+ case DEMANGLE_COMPONENT_VTT:
+ case DEMANGLE_COMPONENT_TYPEINFO:
+ case DEMANGLE_COMPONENT_TYPEINFO_NAME:
+ case DEMANGLE_COMPONENT_TYPEINFO_FN:
+ case DEMANGLE_COMPONENT_THUNK:
+ case DEMANGLE_COMPONENT_VIRTUAL_THUNK:
+ case DEMANGLE_COMPONENT_COVARIANT_THUNK:
+ case DEMANGLE_COMPONENT_JAVA_CLASS:
+ case DEMANGLE_COMPONENT_GUARD:
+ case DEMANGLE_COMPONENT_REFTEMP:
+ case DEMANGLE_COMPONENT_RESTRICT:
+ case DEMANGLE_COMPONENT_VOLATILE:
+ case DEMANGLE_COMPONENT_CONST:
+ case DEMANGLE_COMPONENT_RESTRICT_THIS:
+ case DEMANGLE_COMPONENT_VOLATILE_THIS:
+ case DEMANGLE_COMPONENT_CONST_THIS:
+ case DEMANGLE_COMPONENT_POINTER:
+ case DEMANGLE_COMPONENT_REFERENCE:
+ case DEMANGLE_COMPONENT_COMPLEX:
+ case DEMANGLE_COMPONENT_IMAGINARY:
+ case DEMANGLE_COMPONENT_VENDOR_TYPE:
+ case DEMANGLE_COMPONENT_CAST:
+ if (right != NULL)
+ return 0;
+ break;
+
+ default:
+ /* Other types do not use subtrees. */
+ return 0;
+ }
+
+ p->type = type;
+ p->u.s_binary.left = left;
+ p->u.s_binary.right = right;
+
+ return 1;
+}
+
+/* Fill in a DEMANGLE_COMPONENT_BUILTIN_TYPE. */
+
+int
+cplus_demangle_fill_builtin_type (p, typename)
+ struct demangle_component *p;
+ const char *typename;
+{
+ int len;
+ unsigned int i;
+
+ if (p == NULL || typename == NULL)
+ return 0;
+ len = strlen (typename);
+ for (i = 0; i < D_BUILTIN_TYPE_COUNT; ++i)
+ {
+ if (len == cplus_demangle_builtin_types[i].len
+ && strcmp (typename, cplus_demangle_builtin_types[i].name) == 0)
+ {
+ p->type = DEMANGLE_COMPONENT_BUILTIN_TYPE;
+ p->u.s_builtin.type = &cplus_demangle_builtin_types[i];
+ return 1;
+ }
+ }
+ return 0;
+}
+
+/* Fill in a DEMANGLE_COMPONENT_OPERATOR. */
+
+int
+cplus_demangle_fill_operator (p, opname, args)
+ struct demangle_component *p;
+ const char *opname;
+ int args;
+{
+ int len;
+ unsigned int i;
+
+ if (p == NULL || opname == NULL)
+ return 0;
+ len = strlen (opname);
+ for (i = 0; cplus_demangle_operators[i].name != NULL; ++i)
+ {
+ if (len == cplus_demangle_operators[i].len
+ && args == cplus_demangle_operators[i].args
+ && strcmp (opname, cplus_demangle_operators[i].name) == 0)
+ {
+ p->type = DEMANGLE_COMPONENT_OPERATOR;
+ p->u.s_operator.op = &cplus_demangle_operators[i];
+ return 1;
+ }
+ }
+ return 0;
+}
+
+/* Translate a mangled name into components. */
+
+struct demangle_component *
+cplus_demangle_v3_components (mangled, options, mem)
+ const char *mangled;
+ int options;
+ void **mem;
+{
+ size_t len;
+ int type;
+ struct d_info di;
+ struct demangle_component *dc;
+
+ len = strlen (mangled);
+
+ if (mangled[0] == '_' && mangled[1] == 'Z')
+ type = 0;
+ else
+ {
+ if ((options & DMGL_TYPES) == 0)
+ return NULL;
+ type = 1;
+ }
+
+ cplus_demangle_init_info (mangled, options, len, &di);
+
+ di.comps = ((struct demangle_component *)
+ malloc (di.num_comps * sizeof (struct demangle_component)));
+ di.subs = ((struct demangle_component **)
+ malloc (di.num_subs * sizeof (struct demangle_component *)));
+ if (di.comps == NULL || di.subs == NULL)
+ {
+ if (di.comps != NULL)
+ free (di.comps);
+ if (di.subs != NULL)
+ free (di.subs);
+ return NULL;
+ }
+
+ if (! type)
+ dc = cplus_demangle_mangled_name (&di, 1);
+ else
+ dc = cplus_demangle_type (&di);
+
+ /* If DMGL_PARAMS is set, then if we didn't consume the entire
+ mangled string, then we didn't successfully demangle it. */
+ if ((options & DMGL_PARAMS) != 0 && d_peek_char (&di) != '\0')
+ dc = NULL;
+
+ free (di.subs);
+
+ if (dc != NULL)
+ *mem = di.comps;
+ else
+ free (di.comps);
+
+ return dc;
+}
diff --git a/contrib/binutils/libiberty/cplus-dem.c b/contrib/binutils/libiberty/cplus-dem.c
index 203e30d..f3c4464 100644
--- a/contrib/binutils/libiberty/cplus-dem.c
+++ b/contrib/binutils/libiberty/cplus-dem.c
@@ -1,6 +1,6 @@
/* Demangler for GNU C++
Copyright 1989, 1991, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2001 Free Software Foundation, Inc.
+ 2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
Written by James Clark (jjc@jclark.uucp)
Rewritten by Fred Fish (fnf@cygnus.com) for ARM and Lucid demangling
Modified by Satish Pai (pai@apollo.hp.com) for HP demangling
@@ -11,6 +11,15 @@ modify it under the terms of the GNU Library General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
+In addition to the permissions in the GNU Library General Public
+License, the Free Software Foundation gives you unlimited permission
+to link the compiled version of this file into combinations with other
+programs, and to distribute those combinations without any restriction
+coming from the use of this file. (The Library Public License
+restrictions do apply in other respects; for example, they cover
+modification of the file, and distribution when not linked into a
+combined executable.)
+
Libiberty is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
@@ -305,8 +314,6 @@ const struct demangler_engine libiberty_demanglers[] =
};
#define STRING_EMPTY(str) ((str) -> b == (str) -> p)
-#define PREPEND_BLANK(str) {if (!STRING_EMPTY(str)) \
- string_prepend(str, " ");}
#define APPEND_BLANK(str) {if (!STRING_EMPTY(str)) \
string_append(str, " ");}
#define LEN_STRING(str) ( (STRING_EMPTY(str))?0:((str)->p - (str)->b))
@@ -516,7 +523,7 @@ recursively_demangle PARAMS ((struct work_stuff *, const char **, string *,
int));
static void
-grow_vect PARAMS ((void **, size_t *, size_t, int));
+grow_vect PARAMS ((char **, size_t *, size_t, int));
/* Translate count to integer, consuming tokens in the process.
Conversion terminates on the first non-digit character.
@@ -938,7 +945,7 @@ cplus_demangle (mangled, options)
static void
grow_vect (old_vect, size, min_size, element_size)
- void **old_vect;
+ char **old_vect;
size_t *size;
size_t min_size;
int element_size;
@@ -948,7 +955,7 @@ grow_vect (old_vect, size, min_size, element_size)
*size *= 2;
if (*size < min_size)
*size = min_size;
- *old_vect = xrealloc (*old_vect, *size * element_size);
+ *old_vect = (void *) xrealloc (*old_vect, *size * element_size);
}
}
@@ -971,8 +978,7 @@ ada_demangle (mangled, option)
char *demangled = NULL;
int at_start_name;
int changed;
- char *demangling_buffer = NULL;
- size_t demangling_buffer_size = 0;
+ size_t demangled_size = 0;
changed = 0;
@@ -1000,10 +1006,9 @@ ada_demangle (mangled, option)
}
/* Make demangled big enough for possible expansion by operator name. */
- grow_vect ((void **) &(demangling_buffer),
- &demangling_buffer_size, 2 * len0 + 1,
+ grow_vect (&demangled,
+ &demangled_size, 2 * len0 + 1,
sizeof (char));
- demangled = demangling_buffer;
if (ISDIGIT ((unsigned char) mangled[len0 - 1])) {
for (i = len0 - 2; i >= 0 && ISDIGIT ((unsigned char) mangled[i]); i -= 1)
@@ -1053,10 +1058,10 @@ ada_demangle (mangled, option)
return demangled;
Suppress:
- grow_vect ((void **) &(demangling_buffer),
- &demangling_buffer_size, strlen (mangled) + 3,
+ grow_vect (&demangled,
+ &demangled_size, strlen (mangled) + 3,
sizeof (char));
- demangled = demangling_buffer;
+
if (mangled[0] == '<')
strcpy (demangled, mangled);
else
@@ -1068,7 +1073,7 @@ ada_demangle (mangled, option)
/* This function performs most of what cplus_demangle use to do, but
to be able to demangle a name with a B, K or n code, we need to
have a longer term memory of what types have been seen. The original
- now intializes and cleans up the squangle code info, while internal
+ now initializes and cleans up the squangle code info, while internal
calls go directly to this routine to avoid resetting that info. */
static char *
@@ -1208,7 +1213,7 @@ work_stuff_copy_to_from (to, from)
if (from->ntmpl_args)
to->tmpl_argvec
- = xmalloc (from->ntmpl_args * sizeof (to->tmpl_argvec[0]));
+ = (char **) xmalloc (from->ntmpl_args * sizeof (to->tmpl_argvec[0]));
for (i = 0; i < from->ntmpl_args; i++)
{
@@ -1433,6 +1438,7 @@ demangle_signature (work, mangled, declp)
{
string_append (&s, SCOPE_STRING (work));
string_prepends (declp, &s);
+ string_delete (&s);
}
oldmangled = NULL;
expect_func = 1;
@@ -1512,7 +1518,6 @@ demangle_signature (work, mangled, declp)
{
/* Read the return type. */
string return_type;
- string_init (&return_type);
(*mangled)++;
success = do_type (work, mangled, &return_type);
@@ -1792,31 +1797,34 @@ demangle_integral_value (work, mangled, s)
success = 0;
- /* Negative numbers are indicated with a leading `m'. */
- if (**mangled == 'm')
- {
- string_appendn (s, "-", 1);
- (*mangled)++;
- }
- else if (mangled[0][0] == '_' && mangled[0][1] == 'm')
- {
- /* Since consume_count_with_underscores does not handle the
- `m'-prefix we must do it here, using consume_count and
- adjusting underscores: we have to consume the underscore
- matching the prepended one. */
- multidigit_without_leading_underscore = 1;
- string_appendn (s, "-", 1);
- (*mangled) += 2;
- }
- else if (**mangled == '_')
- {
- /* Do not consume a following underscore;
- multidigit_without_leading_underscore will consume what should be
- consumed. */
- leave_following_underscore = 1;
+ if (**mangled == '_')
+ {
+ if (mangled[0][1] == 'm')
+ {
+ /* Since consume_count_with_underscores does not handle the
+ `m'-prefix we must do it here, using consume_count and
+ adjusting underscores: we have to consume the underscore
+ matching the prepended one. */
+ multidigit_without_leading_underscore = 1;
+ string_appendn (s, "-", 1);
+ (*mangled) += 2;
+ }
+ else
+ {
+ /* Do not consume a following underscore;
+ consume_count_with_underscores will consume what
+ should be consumed. */
+ leave_following_underscore = 1;
+ }
}
else
{
+ /* Negative numbers are indicated with a leading `m'. */
+ if (**mangled == 'm')
+ {
+ string_appendn (s, "-", 1);
+ (*mangled)++;
+ }
/* Since consume_count_with_underscores does not handle
multi-digit numbers that do not start with an underscore,
and this number can be an integer template parameter,
@@ -1857,7 +1865,7 @@ demangle_integral_value (work, mangled, s)
/* All is well. */
success = 1;
}
- }
+ }
return success;
}
@@ -2035,13 +2043,10 @@ demangle_template (work, mangled, tname, trawname, is_type, remember)
const char *start;
int is_java_array = 0;
string temp;
- int bindex = 0;
(*mangled)++;
if (is_type)
{
- if (remember)
- bindex = register_Btype (work);
start = *mangled;
/* get template name */
if (**mangled == 'z')
@@ -2218,7 +2223,10 @@ demangle_template (work, mangled, tname, trawname, is_type, remember)
}
if (is_type && remember)
- remember_Btype (work, tname->b, LEN_STRING (tname), bindex);
+ {
+ const int bindex = register_Btype (work);
+ remember_Btype (work, tname->b, LEN_STRING (tname), bindex);
+ }
/*
if (work -> static_type)
@@ -2310,6 +2318,7 @@ demangle_arm_hp_template (work, mangled, n, declp)
if (HP_DEMANGLING && ((*mangled)[n] == 'X'))
{
char *start_spec_args = NULL;
+ int hold_options;
/* First check for and omit template specialization pseudo-arguments,
such as in "Spec<#1,#1.*>" */
@@ -2322,10 +2331,16 @@ demangle_arm_hp_template (work, mangled, n, declp)
string_init (&arg);
if (work->temp_start == -1) /* non-recursive call */
work->temp_start = declp->p - declp->b;
+
+ /* We want to unconditionally demangle parameter types in
+ template parameters. */
+ hold_options = work->options;
+ work->options |= DMGL_PARAMS;
+
string_append (declp, "<");
while (1)
{
- string_clear (&arg);
+ string_delete (&arg);
switch (**mangled)
{
case 'T':
@@ -2368,21 +2383,29 @@ demangle_arm_hp_template (work, mangled, n, declp)
string_delete (&arg);
if (**mangled == '_')
(*mangled)++;
+ work->options = hold_options;
return;
}
/* ARM template? (Also handles HP cfront extensions) */
else if (arm_pt (work, *mangled, n, &p, &args))
{
+ int hold_options;
string type_str;
string_init (&arg);
string_appendn (declp, *mangled, p - *mangled);
if (work->temp_start == -1) /* non-recursive call */
work->temp_start = declp->p - declp->b;
+
+ /* We want to unconditionally demangle parameter types in
+ template parameters. */
+ hold_options = work->options;
+ work->options |= DMGL_PARAMS;
+
string_append (declp, "<");
/* should do error checking here */
while (args < e) {
- string_clear (&arg);
+ string_delete (&arg);
/* Check for type or literal here */
switch (*args)
@@ -2397,6 +2420,7 @@ demangle_arm_hp_template (work, mangled, n, declp)
goto cfront_template_args_done;
string_append (&arg, "(");
string_appends (&arg, &type_str);
+ string_delete (&type_str);
string_append (&arg, ")");
if (*args != 'L')
goto cfront_template_args_done;
@@ -2421,7 +2445,10 @@ demangle_arm_hp_template (work, mangled, n, declp)
/* Fail if we didn't make any progress: prevent infinite loop. */
if (args == old_args)
- return;
+ {
+ work->options = hold_options;
+ return;
+ }
}
}
string_appends (declp, &arg);
@@ -2432,6 +2459,7 @@ demangle_arm_hp_template (work, mangled, n, declp)
if (args >= e)
--declp->p; /* remove extra comma */
string_append (declp, ">");
+ work->options = hold_options;
}
else if (n>10 && strncmp (*mangled, "_GLOBAL_", 8) == 0
&& (*mangled)[9] == 'N'
@@ -3354,6 +3382,7 @@ demangle_qualified (work, mangled, result, isfuncname, append)
}
else
{
+ string_delete (&last_name);
success = do_type (work, mangled, &last_name);
if (!success)
break;
@@ -3496,10 +3525,8 @@ do_type (work, mangled, result)
string decl;
const char *remembered_type;
int type_quals;
- string btype;
type_kind_t tk = tk_none;
- string_init (&btype);
string_init (&decl);
string_init (result);
@@ -3617,6 +3644,7 @@ do_type (work, mangled, result)
string temp;
do_type (work, mangled, &temp);
string_prepends (&decl, &temp);
+ string_delete (&temp);
}
else if (**mangled == 't')
{
@@ -3627,7 +3655,7 @@ do_type (work, mangled, result)
if (success)
{
string_prependn (&decl, temp.b, temp.p - temp.b);
- string_clear (&temp);
+ string_delete (&temp);
}
else
break;
@@ -3807,11 +3835,8 @@ demangle_fund_type (work, mangled, result)
int success = 1;
char buf[10];
unsigned int dec = 0;
- string btype;
type_kind_t tk = tk_integral;
- string_init (&btype);
-
/* First pick off any type qualifiers. There can be more than one. */
while (!done)
@@ -3983,8 +4008,11 @@ demangle_fund_type (work, mangled, result)
}
case 't':
{
+ string btype;
+ string_init (&btype);
success = demangle_template (work, mangled, &btype, 0, 1, 1);
string_appends (result, &btype);
+ string_delete (&btype);
break;
}
default:
@@ -4186,12 +4214,9 @@ do_arg (work, mangled, result)
do not want to add additional types to the back-referenceable
type vector when processing a repeated type. */
if (work->previous_argument)
- string_clear (work->previous_argument);
+ string_delete (work->previous_argument);
else
- {
- work->previous_argument = (string*) xmalloc (sizeof (string));
- string_init (work->previous_argument);
- }
+ work->previous_argument = (string*) xmalloc (sizeof (string));
if (!do_type (work, mangled, work->previous_argument))
return 0;
@@ -4555,7 +4580,10 @@ demangle_nested_args (work, mangled, declp)
/* Restore the previous_argument field. */
if (work->previous_argument)
- string_delete (work->previous_argument);
+ {
+ string_delete (work->previous_argument);
+ free ((char *) work->previous_argument);
+ }
work->previous_argument = saved_previous_argument;
--work->forgetting_types;
work->nrepeats = saved_nrepeats;
@@ -4880,337 +4908,3 @@ string_append_template_idx (s, idx)
sprintf(buf, "T%d", idx);
string_append (s, buf);
}
-
-/* To generate a standalone demangler program for testing purposes,
- just compile and link this file with -DMAIN and libiberty.a. When
- run, it demangles each command line arg, or each stdin string, and
- prints the result on stdout. */
-
-#ifdef MAIN
-
-#include "getopt.h"
-
-static const char *program_name;
-static const char *program_version = VERSION;
-static int flags = DMGL_PARAMS | DMGL_ANSI | DMGL_VERBOSE;
-
-static void demangle_it PARAMS ((char *));
-static void usage PARAMS ((FILE *, int)) ATTRIBUTE_NORETURN;
-static void fatal PARAMS ((const char *)) ATTRIBUTE_NORETURN;
-static void print_demangler_list PARAMS ((FILE *));
-
-static void
-demangle_it (mangled_name)
- char *mangled_name;
-{
- char *result;
-
- /* For command line args, also try to demangle type encodings. */
- result = cplus_demangle (mangled_name, flags | DMGL_TYPES);
- if (result == NULL)
- {
- printf ("%s\n", mangled_name);
- }
- else
- {
- printf ("%s\n", result);
- free (result);
- }
-}
-
-static void
-print_demangler_list (stream)
- FILE *stream;
-{
- const struct demangler_engine *demangler;
-
- fprintf (stream, "{%s", libiberty_demanglers->demangling_style_name);
-
- for (demangler = libiberty_demanglers + 1;
- demangler->demangling_style != unknown_demangling;
- ++demangler)
- fprintf (stream, ",%s", demangler->demangling_style_name);
-
- fprintf (stream, "}");
-}
-
-static void
-usage (stream, status)
- FILE *stream;
- int status;
-{
- fprintf (stream, "\
-Usage: %s [-_] [-n] [--strip-underscores] [--no-strip-underscores] \n",
- program_name);
-
- fprintf (stream, "\
- [-s ");
- print_demangler_list (stream);
- fprintf (stream, "]\n");
-
- fprintf (stream, "\
- [--format ");
- print_demangler_list (stream);
- fprintf (stream, "]\n");
-
- fprintf (stream, "\
- [--help] [--version] [arg...]\n");
- exit (status);
-}
-
-#define MBUF_SIZE 32767
-char mbuffer[MBUF_SIZE];
-
-/* Defined in the automatically-generated underscore.c. */
-extern int prepends_underscore;
-
-int strip_underscore = 0;
-
-static const struct option long_options[] = {
- {"strip-underscores", no_argument, 0, '_'},
- {"format", required_argument, 0, 's'},
- {"help", no_argument, 0, 'h'},
- {"no-strip-underscores", no_argument, 0, 'n'},
- {"version", no_argument, 0, 'v'},
- {0, no_argument, 0, 0}
-};
-
-/* More 'friendly' abort that prints the line and file.
- config.h can #define abort fancy_abort if you like that sort of thing. */
-
-void
-fancy_abort ()
-{
- fatal ("Internal gcc abort.");
-}
-
-
-static const char *
-standard_symbol_characters PARAMS ((void));
-
-static const char *
-hp_symbol_characters PARAMS ((void));
-
-static const char *
-gnu_v3_symbol_characters PARAMS ((void));
-
-/* Return the string of non-alnum characters that may occur
- as a valid symbol component, in the standard assembler symbol
- syntax. */
-
-static const char *
-standard_symbol_characters ()
-{
- return "_$.";
-}
-
-
-/* Return the string of non-alnum characters that may occur
- as a valid symbol name component in an HP object file.
-
- Note that, since HP's compiler generates object code straight from
- C++ source, without going through an assembler, its mangled
- identifiers can use all sorts of characters that no assembler would
- tolerate, so the alphabet this function creates is a little odd.
- Here are some sample mangled identifiers offered by HP:
-
- typeid*__XT24AddressIndExpClassMember_
- [Vftptr]key:__dt__32OrdinaryCompareIndExpClassMemberFv
- __ct__Q2_9Elf64_Dyn18{unnamed.union.#1}Fv
-
- This still seems really weird to me, since nowhere else in this
- file is there anything to recognize curly brackets, parens, etc.
- I've talked with Srikanth <srikanth@cup.hp.com>, and he assures me
- this is right, but I still strongly suspect that there's a
- misunderstanding here.
-
- If we decide it's better for c++filt to use HP's assembler syntax
- to scrape identifiers out of its input, here's the definition of
- the symbol name syntax from the HP assembler manual:
-
- Symbols are composed of uppercase and lowercase letters, decimal
- digits, dollar symbol, period (.), ampersand (&), pound sign(#) and
- underscore (_). A symbol can begin with a letter, digit underscore or
- dollar sign. If a symbol begins with a digit, it must contain a
- non-digit character.
-
- So have fun. */
-static const char *
-hp_symbol_characters ()
-{
- return "_$.<>#,*&[]:(){}";
-}
-
-
-/* Return the string of non-alnum characters that may occur
- as a valid symbol component in the GNU C++ V3 ABI mangling
- scheme. */
-
-static const char *
-gnu_v3_symbol_characters ()
-{
- return "_$.";
-}
-
-
-extern int main PARAMS ((int, char **));
-
-int
-main (argc, argv)
- int argc;
- char **argv;
-{
- char *result;
- int c;
- const char *valid_symbols;
- enum demangling_styles style = auto_demangling;
-
- program_name = argv[0];
-
- strip_underscore = prepends_underscore;
-
- while ((c = getopt_long (argc, argv, "_ns:", long_options, (int *) 0)) != EOF)
- {
- switch (c)
- {
- case '?':
- usage (stderr, 1);
- break;
- case 'h':
- usage (stdout, 0);
- case 'n':
- strip_underscore = 0;
- break;
- case 'v':
- printf ("GNU %s (C++ demangler), version %s\n", program_name, program_version);
- return (0);
- case '_':
- strip_underscore = 1;
- break;
- case 's':
- {
- style = cplus_demangle_name_to_style (optarg);
- if (style == unknown_demangling)
- {
- fprintf (stderr, "%s: unknown demangling style `%s'\n",
- program_name, optarg);
- return (1);
- }
- else
- cplus_demangle_set_style (style);
- }
- break;
- }
- }
-
- if (optind < argc)
- {
- for ( ; optind < argc; optind++)
- {
- demangle_it (argv[optind]);
- }
- }
- else
- {
- switch (current_demangling_style)
- {
- case gnu_demangling:
- case lucid_demangling:
- case arm_demangling:
- case java_demangling:
- case edg_demangling:
- case gnat_demangling:
- case auto_demangling:
- valid_symbols = standard_symbol_characters ();
- break;
- case hp_demangling:
- valid_symbols = hp_symbol_characters ();
- break;
- case gnu_v3_demangling:
- valid_symbols = gnu_v3_symbol_characters ();
- break;
- default:
- /* Folks should explicitly indicate the appropriate alphabet for
- each demangling. Providing a default would allow the
- question to go unconsidered. */
- abort ();
- }
-
- for (;;)
- {
- int i = 0;
- c = getchar ();
- /* Try to read a label. */
- while (c != EOF && (ISALNUM (c) || strchr (valid_symbols, c)))
- {
- if (i >= MBUF_SIZE-1)
- break;
- mbuffer[i++] = c;
- c = getchar ();
- }
- if (i > 0)
- {
- int skip_first = 0;
-
- if (mbuffer[0] == '.' || mbuffer[0] == '$')
- ++skip_first;
- if (strip_underscore && mbuffer[skip_first] == '_')
- ++skip_first;
-
- if (skip_first > i)
- skip_first = i;
-
- mbuffer[i] = 0;
- flags |= (int) style;
- result = cplus_demangle (mbuffer + skip_first, flags);
- if (result)
- {
- if (mbuffer[0] == '.')
- putc ('.', stdout);
- fputs (result, stdout);
- free (result);
- }
- else
- fputs (mbuffer, stdout);
-
- fflush (stdout);
- }
- if (c == EOF)
- break;
- putchar (c);
- fflush (stdout);
- }
- }
-
- return (0);
-}
-
-static void
-fatal (str)
- const char *str;
-{
- fprintf (stderr, "%s: %s\n", program_name, str);
- exit (1);
-}
-
-PTR
-xmalloc (size)
- size_t size;
-{
- register PTR value = (PTR) malloc (size);
- if (value == 0)
- fatal ("virtual memory exhausted");
- return value;
-}
-
-PTR
-xrealloc (ptr, size)
- PTR ptr;
- size_t size;
-{
- register PTR value = (PTR) realloc (ptr, size);
- if (value == 0)
- fatal ("virtual memory exhausted");
- return value;
-}
-#endif /* main */
diff --git a/contrib/binutils/libiberty/fibheap.c b/contrib/binutils/libiberty/fibheap.c
index 0ba9b8d..bcecf80 100644
--- a/contrib/binutils/libiberty/fibheap.c
+++ b/contrib/binutils/libiberty/fibheap.c
@@ -66,7 +66,7 @@ fibnode_new ()
{
fibnode_t node;
- node = xcalloc (1, sizeof *node);
+ node = (fibnode_t) xcalloc (1, sizeof *node);
node->left = node;
node->right = node;
@@ -218,7 +218,7 @@ fibheap_replace_key_data (heap, node, key, data)
void *data;
{
void *odata;
- int okey;
+ fibheapkey_t okey;
fibnode_t y;
/* If we wanted to, we could actually do a real increase by redeleting and
diff --git a/contrib/binutils/libiberty/floatformat.c b/contrib/binutils/libiberty/floatformat.c
index d9e9fad..a0f6535 100644
--- a/contrib/binutils/libiberty/floatformat.c
+++ b/contrib/binutils/libiberty/floatformat.c
@@ -1,5 +1,5 @@
/* IEEE floating point support routines, for GDB, the GNU Debugger.
- Copyright (C) 1991, 1994, 1999, 2000 Free Software Foundation, Inc.
+ Copyright (C) 1991, 1994, 1999, 2000, 2003 Free Software Foundation, Inc.
This file is part of GDB.
@@ -17,17 +17,51 @@ You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+/* This is needed to pick up the NAN macro on some systems. */
+#define _GNU_SOURCE
+
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
+#include <math.h>
+
+#ifdef HAVE_STRING_H
+#include <string.h>
+#endif
+
+#include "ansidecl.h"
+#include "libiberty.h"
#include "floatformat.h"
-#include <math.h> /* ldexp */
-#ifdef __STDC__
-#include <stddef.h>
-extern void *memcpy (void *s1, const void *s2, size_t n);
-extern void *memset (void *s, int c, size_t n);
+
+#ifndef INFINITY
+#ifdef HUGE_VAL
+#define INFINITY HUGE_VAL
#else
-extern char *memcpy ();
-extern char *memset ();
+#define INFINITY (1.0 / 0.0)
+#endif
#endif
+#ifndef NAN
+#define NAN (0.0 / 0.0)
+#endif
+
+static unsigned long get_field PARAMS ((const unsigned char *,
+ enum floatformat_byteorders,
+ unsigned int,
+ unsigned int,
+ unsigned int));
+static int floatformat_always_valid PARAMS ((const struct floatformat *fmt,
+ const char *from));
+
+static int
+floatformat_always_valid (fmt, from)
+ const struct floatformat *fmt ATTRIBUTE_UNUSED;
+ const char *from ATTRIBUTE_UNUSED;
+{
+ return 1;
+}
+
/* The odds that CHAR_BIT will be anything but 8 are low enough that I'm not
going to bother with trying to muck around with whether it is defined in
a system header, what we do if not, etc. */
@@ -38,25 +72,29 @@ const struct floatformat floatformat_ieee_single_big =
{
floatformat_big, 32, 0, 1, 8, 127, 255, 9, 23,
floatformat_intbit_no,
- "floatformat_ieee_single_big"
+ "floatformat_ieee_single_big",
+ floatformat_always_valid
};
const struct floatformat floatformat_ieee_single_little =
{
floatformat_little, 32, 0, 1, 8, 127, 255, 9, 23,
floatformat_intbit_no,
- "floatformat_ieee_single_little"
+ "floatformat_ieee_single_little",
+ floatformat_always_valid
};
const struct floatformat floatformat_ieee_double_big =
{
floatformat_big, 64, 0, 1, 11, 1023, 2047, 12, 52,
floatformat_intbit_no,
- "floatformat_ieee_double_big"
+ "floatformat_ieee_double_big",
+ floatformat_always_valid
};
const struct floatformat floatformat_ieee_double_little =
{
floatformat_little, 64, 0, 1, 11, 1023, 2047, 12, 52,
floatformat_intbit_no,
- "floatformat_ieee_double_little"
+ "floatformat_ieee_double_little",
+ floatformat_always_valid
};
/* floatformat for IEEE double, little endian byte order, with big endian word
@@ -66,34 +104,64 @@ const struct floatformat floatformat_ieee_double_littlebyte_bigword =
{
floatformat_littlebyte_bigword, 64, 0, 1, 11, 1023, 2047, 12, 52,
floatformat_intbit_no,
- "floatformat_ieee_double_littlebyte_bigword"
+ "floatformat_ieee_double_littlebyte_bigword",
+ floatformat_always_valid
};
+static int floatformat_i387_ext_is_valid PARAMS ((const struct floatformat *fmt, const char *from));
+
+static int
+floatformat_i387_ext_is_valid (fmt, from)
+ const struct floatformat *fmt;
+ const char *from;
+{
+ /* In the i387 double-extended format, if the exponent is all ones,
+ then the integer bit must be set. If the exponent is neither 0
+ nor ~0, the intbit must also be set. Only if the exponent is
+ zero can it be zero, and then it must be zero. */
+ unsigned long exponent, int_bit;
+ const unsigned char *ufrom = (const unsigned char *) from;
+
+ exponent = get_field (ufrom, fmt->byteorder, fmt->totalsize,
+ fmt->exp_start, fmt->exp_len);
+ int_bit = get_field (ufrom, fmt->byteorder, fmt->totalsize,
+ fmt->man_start, 1);
+
+ if ((exponent == 0) != (int_bit == 0))
+ return 0;
+ else
+ return 1;
+}
+
const struct floatformat floatformat_i387_ext =
{
floatformat_little, 80, 0, 1, 15, 0x3fff, 0x7fff, 16, 64,
floatformat_intbit_yes,
- "floatformat_i387_ext"
+ "floatformat_i387_ext",
+ floatformat_i387_ext_is_valid
};
const struct floatformat floatformat_m68881_ext =
{
/* Note that the bits from 16 to 31 are unused. */
floatformat_big, 96, 0, 1, 15, 0x3fff, 0x7fff, 32, 64,
floatformat_intbit_yes,
- "floatformat_m68881_ext"
+ "floatformat_m68881_ext",
+ floatformat_always_valid
};
const struct floatformat floatformat_i960_ext =
{
/* Note that the bits from 0 to 15 are unused. */
floatformat_little, 96, 16, 17, 15, 0x3fff, 0x7fff, 32, 64,
floatformat_intbit_yes,
- "floatformat_i960_ext"
+ "floatformat_i960_ext",
+ floatformat_always_valid
};
const struct floatformat floatformat_m88110_ext =
{
floatformat_big, 80, 0, 1, 15, 0x3fff, 0x7fff, 16, 64,
floatformat_intbit_yes,
- "floatformat_m88110_ext"
+ "floatformat_m88110_ext",
+ floatformat_always_valid
};
const struct floatformat floatformat_m88110_harris_ext =
{
@@ -101,58 +169,59 @@ const struct floatformat floatformat_m88110_harris_ext =
double, and the last 64 bits are wasted. */
floatformat_big,128, 0, 1, 11, 0x3ff, 0x7ff, 12, 52,
floatformat_intbit_no,
- "floatformat_m88110_ext_harris"
+ "floatformat_m88110_ext_harris",
+ floatformat_always_valid
};
const struct floatformat floatformat_arm_ext_big =
{
/* Bits 1 to 16 are unused. */
floatformat_big, 96, 0, 17, 15, 0x3fff, 0x7fff, 32, 64,
floatformat_intbit_yes,
- "floatformat_arm_ext_big"
+ "floatformat_arm_ext_big",
+ floatformat_always_valid
};
const struct floatformat floatformat_arm_ext_littlebyte_bigword =
{
/* Bits 1 to 16 are unused. */
floatformat_littlebyte_bigword, 96, 0, 17, 15, 0x3fff, 0x7fff, 32, 64,
floatformat_intbit_yes,
- "floatformat_arm_ext_littlebyte_bigword"
+ "floatformat_arm_ext_littlebyte_bigword",
+ floatformat_always_valid
};
const struct floatformat floatformat_ia64_spill_big =
{
floatformat_big, 128, 0, 1, 17, 65535, 0x1ffff, 18, 64,
floatformat_intbit_yes,
- "floatformat_ia64_spill_big"
+ "floatformat_ia64_spill_big",
+ floatformat_always_valid
};
const struct floatformat floatformat_ia64_spill_little =
{
floatformat_little, 128, 0, 1, 17, 65535, 0x1ffff, 18, 64,
floatformat_intbit_yes,
- "floatformat_ia64_spill_little"
+ "floatformat_ia64_spill_little",
+ floatformat_always_valid
};
const struct floatformat floatformat_ia64_quad_big =
{
floatformat_big, 128, 0, 1, 15, 16383, 0x7fff, 16, 112,
floatformat_intbit_no,
- "floatformat_ia64_quad_big"
+ "floatformat_ia64_quad_big",
+ floatformat_always_valid
};
const struct floatformat floatformat_ia64_quad_little =
{
floatformat_little, 128, 0, 1, 15, 16383, 0x7fff, 16, 112,
floatformat_intbit_no,
- "floatformat_ia64_quad_little"
+ "floatformat_ia64_quad_little",
+ floatformat_always_valid
};
-static unsigned long get_field PARAMS ((unsigned char *,
- enum floatformat_byteorders,
- unsigned int,
- unsigned int,
- unsigned int));
-
-/* Extract a field which starts at START and is LEN bytes long. DATA and
+/* Extract a field which starts at START and is LEN bits long. DATA and
TOTAL_LEN are the thing we are extracting it from, in byteorder ORDER. */
static unsigned long
get_field (data, order, total_len, start, len)
- unsigned char *data;
+ const unsigned char *data;
enum floatformat_byteorders order;
unsigned int total_len;
unsigned int start;
@@ -206,10 +275,10 @@ get_field (data, order, total_len, start, len)
void
floatformat_to_double (fmt, from, to)
const struct floatformat *fmt;
- char *from;
+ const char *from;
double *to;
{
- unsigned char *ufrom = (unsigned char *)from;
+ const unsigned char *ufrom = (const unsigned char *)from;
double dto;
long exponent;
unsigned long mant;
@@ -219,9 +288,45 @@ floatformat_to_double (fmt, from, to)
exponent = get_field (ufrom, fmt->byteorder, fmt->totalsize,
fmt->exp_start, fmt->exp_len);
- /* Note that if exponent indicates a NaN, we can't really do anything useful
- (not knowing if the host has NaN's, or how to build one). So it will
- end up as an infinity or something close; that is OK. */
+
+ /* If the exponent indicates a NaN, we don't have information to
+ decide what to do. So we handle it like IEEE, except that we
+ don't try to preserve the type of NaN. FIXME. */
+ if ((unsigned long) exponent == fmt->exp_nan)
+ {
+ int nan;
+
+ mant_off = fmt->man_start;
+ mant_bits_left = fmt->man_len;
+ nan = 0;
+ while (mant_bits_left > 0)
+ {
+ mant_bits = min (mant_bits_left, 32);
+
+ if (get_field (ufrom, fmt->byteorder, fmt->totalsize,
+ mant_off, mant_bits) != 0)
+ {
+ /* This is a NaN. */
+ nan = 1;
+ break;
+ }
+
+ mant_off += mant_bits;
+ mant_bits_left -= mant_bits;
+ }
+
+ if (nan)
+ dto = NAN;
+ else
+ dto = INFINITY;
+
+ if (get_field (ufrom, fmt->byteorder, fmt->totalsize, fmt->sign_start, 1))
+ dto = -dto;
+
+ *to = dto;
+
+ return;
+ }
mant_bits_left = fmt->man_len;
mant_off = fmt->man_start;
@@ -254,8 +359,18 @@ floatformat_to_double (fmt, from, to)
mant = get_field (ufrom, fmt->byteorder, fmt->totalsize,
mant_off, mant_bits);
- dto += ldexp ((double)mant, exponent - mant_bits);
- exponent -= mant_bits;
+ /* Handle denormalized numbers. FIXME: What should we do for
+ non-IEEE formats? */
+ if (exponent == 0 && mant != 0)
+ dto += ldexp ((double)mant,
+ (- fmt->exp_bias
+ - mant_bits
+ - (mant_off - fmt->man_start)
+ + 1));
+ else
+ dto += ldexp ((double)mant, exponent - mant_bits);
+ if (exponent != 0)
+ exponent -= mant_bits;
mant_off += mant_bits;
mant_bits_left -= mant_bits;
}
@@ -272,7 +387,7 @@ static void put_field PARAMS ((unsigned char *, enum floatformat_byteorders,
unsigned int,
unsigned long));
-/* Set a field which starts at START and is LEN bytes long. DATA and
+/* Set a field which starts at START and is LEN bits long. DATA and
TOTAL_LEN are the thing we are extracting it from, in byteorder ORDER. */
static void
put_field (data, order, total_len, start, len, stuff_to_put)
@@ -330,7 +445,7 @@ put_field (data, order, total_len, start, len, stuff_to_put)
void
floatformat_from_double (fmt, from, to)
const struct floatformat *fmt;
- double *from;
+ const double *from;
char *to;
{
double dfrom;
@@ -340,33 +455,54 @@ floatformat_from_double (fmt, from, to)
int mant_bits_left;
unsigned char *uto = (unsigned char *)to;
- memcpy (&dfrom, from, sizeof (dfrom));
+ dfrom = *from;
memset (uto, 0, fmt->totalsize / FLOATFORMAT_CHAR_BIT);
+
+ /* If negative, set the sign bit. */
+ if (dfrom < 0)
+ {
+ put_field (uto, fmt->byteorder, fmt->totalsize, fmt->sign_start, 1, 1);
+ dfrom = -dfrom;
+ }
+
if (dfrom == 0)
- return; /* Result is zero */
+ {
+ /* 0.0. */
+ return;
+ }
+
if (dfrom != dfrom)
{
- /* From is NaN */
+ /* NaN. */
put_field (uto, fmt->byteorder, fmt->totalsize, fmt->exp_start,
fmt->exp_len, fmt->exp_nan);
- /* Be sure it's not infinity, but NaN value is irrel */
+ /* Be sure it's not infinity, but NaN value is irrelevant. */
put_field (uto, fmt->byteorder, fmt->totalsize, fmt->man_start,
32, 1);
return;
}
- /* If negative, set the sign bit. */
- if (dfrom < 0)
+ if (dfrom + dfrom == dfrom)
{
- put_field (uto, fmt->byteorder, fmt->totalsize, fmt->sign_start, 1, 1);
- dfrom = -dfrom;
+ /* This can only happen for an infinite value (or zero, which we
+ already handled above). */
+ put_field (uto, fmt->byteorder, fmt->totalsize, fmt->exp_start,
+ fmt->exp_len, fmt->exp_nan);
+ return;
}
- /* How to tell an infinity from an ordinary number? FIXME-someday */
-
mant = frexp (dfrom, &exponent);
- put_field (uto, fmt->byteorder, fmt->totalsize, fmt->exp_start, fmt->exp_len,
- exponent + fmt->exp_bias - 1);
+ if (exponent + fmt->exp_bias - 1 > 0)
+ put_field (uto, fmt->byteorder, fmt->totalsize, fmt->exp_start,
+ fmt->exp_len, exponent + fmt->exp_bias - 1);
+ else
+ {
+ /* Handle a denormalized number. FIXME: What should we do for
+ non-IEEE formats? */
+ put_field (uto, fmt->byteorder, fmt->totalsize, fmt->exp_start,
+ fmt->exp_len, 0);
+ mant = ldexp (mant, exponent + fmt->exp_bias - 1);
+ }
mant_bits_left = fmt->man_len;
mant_off = fmt->man_start;
@@ -379,12 +515,11 @@ floatformat_from_double (fmt, from, to)
mant_long = (unsigned long)mant;
mant -= mant_long;
- /* If the integer bit is implicit, then we need to discard it.
- If we are discarding a zero, we should be (but are not) creating
- a denormalized number which means adjusting the exponent
- (I think). */
+ /* If the integer bit is implicit, and we are not creating a
+ denormalized number, then we need to discard it. */
if ((unsigned int) mant_bits_left == fmt->man_len
- && fmt->intbit == floatformat_intbit_no)
+ && fmt->intbit == floatformat_intbit_no
+ && exponent + fmt->exp_bias - 1 > 0)
{
mant_long &= 0x7fffffff;
mant_bits -= 1;
@@ -403,9 +538,21 @@ floatformat_from_double (fmt, from, to)
}
}
+/* Return non-zero iff the data at FROM is a valid number in format FMT. */
+
+int
+floatformat_is_valid (fmt, from)
+ const struct floatformat *fmt;
+ const char *from;
+{
+ return fmt->is_valid (fmt, from);
+}
+
#ifdef IEEE_DEBUG
+#include <stdio.h>
+
/* This is to be run on a host which uses IEEE floating point. */
void
@@ -413,19 +560,31 @@ ieee_test (n)
double n;
{
double result;
- char exten[16];
- floatformat_to_double (&floatformat_ieee_double_big, &n, &result);
- if (n != result)
+ floatformat_to_double (&floatformat_ieee_double_little, (char *) &n,
+ &result);
+ if ((n != result && (! isnan (n) || ! isnan (result)))
+ || (n < 0 && result >= 0)
+ || (n >= 0 && result < 0))
printf ("Differ(to): %.20g -> %.20g\n", n, result);
- floatformat_from_double (&floatformat_ieee_double_big, &n, &result);
- if (n != result)
+
+ floatformat_from_double (&floatformat_ieee_double_little, &n,
+ (char *) &result);
+ if ((n != result && (! isnan (n) || ! isnan (result)))
+ || (n < 0 && result >= 0)
+ || (n >= 0 && result < 0))
printf ("Differ(from): %.20g -> %.20g\n", n, result);
- floatformat_from_double (&floatformat_m68881_ext, &n, exten);
- floatformat_to_double (&floatformat_m68881_ext, exten, &result);
- if (n != result)
- printf ("Differ(to+from): %.20g -> %.20g\n", n, result);
+#if 0
+ {
+ char exten[16];
+
+ floatformat_from_double (&floatformat_m68881_ext, &n, exten);
+ floatformat_to_double (&floatformat_m68881_ext, exten, &result);
+ if (n != result)
+ printf ("Differ(to+from): %.20g -> %.20g\n", n, result);
+ }
+#endif
#if IEEE_DEBUG > 1
/* This is to be run on a host which uses 68881 format. */
@@ -440,12 +599,22 @@ ieee_test (n)
int
main ()
{
+ ieee_test (0.0);
ieee_test (0.5);
ieee_test (256.0);
ieee_test (0.12345);
ieee_test (234235.78907234);
ieee_test (-512.0);
ieee_test (-0.004321);
+ ieee_test (1.2E-70);
+ ieee_test (1.2E-316);
+ ieee_test (4.9406564584124654E-324);
+ ieee_test (- 4.9406564584124654E-324);
+ ieee_test (- 0.0);
+ ieee_test (- INFINITY);
+ ieee_test (- NAN);
+ ieee_test (INFINITY);
+ ieee_test (NAN);
return 0;
}
#endif
diff --git a/contrib/binutils/libiberty/functions.texi b/contrib/binutils/libiberty/functions.texi
index b518243..aac4424 100644
--- a/contrib/binutils/libiberty/functions.texi
+++ b/contrib/binutils/libiberty/functions.texi
@@ -3,6 +3,28 @@
@c Edit the *.c files, configure with --enable-maintainer-mode,
@c and let gather-docs build you a new copy.
+@c safe-ctype.c:24
+@defvr Extension HOST_CHARSET
+This macro indicates the basic character set and encoding used by the
+host: more precisely, the encoding used for character constants in
+preprocessor @samp{#if} statements (the C "execution character set").
+It is defined by @file{safe-ctype.h}, and will be an integer constant
+with one of the following values:
+
+@ftable @code
+@item HOST_CHARSET_UNKNOWN
+The host character set is unknown - that is, not one of the next two
+possibilities.
+
+@item HOST_CHARSET_ASCII
+The host character set is ASCII.
+
+@item HOST_CHARSET_EBCDIC
+The host character set is some variant of EBCDIC. (Only one of the
+nineteen EBCDIC varying characters is tested; exercise caution.)
+@end ftable
+@end defvr
+
@c alloca.c:26
@deftypefn Replacement void* alloca (size_t @var{size})
@@ -29,7 +51,7 @@ pass a pointer to a pointer. This function will compute the size of
the buffer needed, allocate memory with @code{malloc}, and store a
pointer to the allocated memory in @code{*@var{resptr}}. The value
returned is the same as @code{sprintf} would return. If memory could
-not be allocated, zero is returned and @code{NULL} is stored in
+not be allocated, minus one is returned and @code{NULL} is stored in
@code{*@var{resptr}}.
@end deftypefn
@@ -276,7 +298,7 @@ itself.
@end deftypefn
-@c getruntime.c:78
+@c getruntime.c:82
@deftypefn Replacement long get_run_time (void)
Returns the time used so far, in microseconds. If possible, this is
@@ -317,16 +339,17 @@ between calls to @code{getpwd}.
@end deftypefn
-@c hex.c:25
+@c hex.c:30
@deftypefn Extension void hex_init (void)
Initializes the array mapping the current character set to
corresponding hex values. This function must be called before any
-call to @code{hex_p} or @code{hex_value}.
+call to @code{hex_p} or @code{hex_value}. If you fail to call it, a
+default ASCII-based table will normally be used on ASCII systems.
@end deftypefn
-@c hex.c:33
+@c hex.c:39
@deftypefn Extension int hex_p (int @var{c})
Evaluates to non-zero if the given character is a valid hex character,
@@ -335,14 +358,20 @@ or zero if it is not. Note that the value you pass will be cast to
@end deftypefn
-@c hex.c:41
-@deftypefn Extension int hex_value (int @var{c})
+@c hex.c:47
+@deftypefn Extension unsigned int hex_value (int @var{c})
Returns the numeric equivalent of the given character when interpreted
as a hexidecimal digit. The result is undefined if you pass an
invalid hex digit. Note that the value you pass will be cast to
@code{unsigned char} within the macro.
+The @code{hex_value} macro returns @code{unsigned int}, rather than
+signed @code{int}, to make it easier to use in parsing addresses from
+hex dump files: a signed @code{int} would be sign-extended when
+converted to a wider unsigned type --- like @code{bfd_vma}, on some
+systems.
+
@end deftypefn
@c index.c:5
@@ -375,6 +404,78 @@ struct qelem @{
@end deftypefn
+@c safe-ctype.c:45
+@deffn Extension ISALPHA (@var{c})
+@deffnx Extension ISALNUM (@var{c})
+@deffnx Extension ISBLANK (@var{c})
+@deffnx Extension ISCNTRL (@var{c})
+@deffnx Extension ISDIGIT (@var{c})
+@deffnx Extension ISGRAPH (@var{c})
+@deffnx Extension ISLOWER (@var{c})
+@deffnx Extension ISPRINT (@var{c})
+@deffnx Extension ISPUNCT (@var{c})
+@deffnx Extension ISSPACE (@var{c})
+@deffnx Extension ISUPPER (@var{c})
+@deffnx Extension ISXDIGIT (@var{c})
+
+These twelve macros are defined by @file{safe-ctype.h}. Each has the
+same meaning as the corresponding macro (with name in lowercase)
+defined by the standard header @file{ctype.h}. For example,
+@code{ISALPHA} returns true for alphabetic characters and false for
+others. However, there are two differences between these macros and
+those provided by @file{ctype.h}:
+
+@itemize @bullet
+@item These macros are guaranteed to have well-defined behavior for all
+values representable by @code{signed char} and @code{unsigned char}, and
+for @code{EOF}.
+
+@item These macros ignore the current locale; they are true for these
+fixed sets of characters:
+@multitable {@code{XDIGIT}} {yada yada yada yada yada yada yada yada}
+@item @code{ALPHA} @tab @kbd{A-Za-z}
+@item @code{ALNUM} @tab @kbd{A-Za-z0-9}
+@item @code{BLANK} @tab @kbd{space tab}
+@item @code{CNTRL} @tab @code{!PRINT}
+@item @code{DIGIT} @tab @kbd{0-9}
+@item @code{GRAPH} @tab @code{ALNUM || PUNCT}
+@item @code{LOWER} @tab @kbd{a-z}
+@item @code{PRINT} @tab @code{GRAPH ||} @kbd{space}
+@item @code{PUNCT} @tab @kbd{`~!@@#$%^&*()_-=+[@{]@}\|;:'",<.>/?}
+@item @code{SPACE} @tab @kbd{space tab \n \r \f \v}
+@item @code{UPPER} @tab @kbd{A-Z}
+@item @code{XDIGIT} @tab @kbd{0-9A-Fa-f}
+@end multitable
+
+Note that, if the host character set is ASCII or a superset thereof,
+all these macros will return false for all values of @code{char} outside
+the range of 7-bit ASCII. In particular, both ISPRINT and ISCNTRL return
+false for characters with numeric values from 128 to 255.
+@end itemize
+@end deffn
+
+@c safe-ctype.c:94
+@deffn Extension ISIDNUM (@var{c})
+@deffnx Extension ISIDST (@var{c})
+@deffnx Extension IS_VSPACE (@var{c})
+@deffnx Extension IS_NVSPACE (@var{c})
+@deffnx Extension IS_SPACE_OR_NUL (@var{c})
+@deffnx Extension IS_ISOBASIC (@var{c})
+These six macros are defined by @file{safe-ctype.h} and provide
+additional character classes which are useful when doing lexical
+analysis of C or similar languages. They are true for the following
+sets of characters:
+
+@multitable {@code{SPACE_OR_NUL}} {yada yada yada yada yada yada yada yada}
+@item @code{IDNUM} @tab @kbd{A-Za-z0-9_}
+@item @code{IDST} @tab @kbd{A-Za-z_}
+@item @code{VSPACE} @tab @kbd{\r \n}
+@item @code{NVSPACE} @tab @kbd{space tab \f \v \0}
+@item @code{SPACE_OR_NUL} @tab @code{VSPACE || NVSPACE}
+@item @code{ISOBASIC} @tab @code{VSPACE || NVSPACE || PRINT}
+@end multitable
+@end deffn
+
@c lbasename.c:23
@deftypefn Replacement {const char*} lbasename (const char *@var{name})
@@ -391,6 +492,41 @@ and a path ending in @code{/} returns the empty string after it.
@end deftypefn
+@c lrealpath.c:25
+@deftypefn Replacement {const char*} lrealpath (const char *@var{name})
+
+Given a pointer to a string containing a pathname, returns a canonical
+version of the filename. Symlinks will be resolved, and ``.'' and ``..''
+components will be simplified. The returned value will be allocated using
+@code{malloc}, or @code{NULL} will be returned on a memory allocation error.
+
+@end deftypefn
+
+@c make-relative-prefix.c:24
+@deftypefn Extension {const char*} make_relative_prefix (const char *@var{progname}, const char *@var{bin_prefix}, const char *@var{prefix})
+
+Given three paths @var{progname}, @var{bin_prefix}, @var{prefix},
+return the path that is in the same position relative to
+@var{progname}'s directory as @var{prefix} is relative to
+@var{bin_prefix}. That is, a string starting with the directory
+portion of @var{progname}, followed by a relative pathname of the
+difference between @var{bin_prefix} and @var{prefix}.
+
+If @var{progname} does not contain any directory separators,
+@code{make_relative_prefix} will search @env{PATH} to find a program
+named @var{progname}. Also, if @var{progname} is a symbolic link,
+the symbolic link will be resolved.
+
+For example, if @var{bin_prefix} is @code{/alpha/beta/gamma/gcc/delta},
+@var{prefix} is @code{/alpha/beta/gamma/omega/}, and @var{progname} is
+@code{/red/green/blue/gcc}, then this function will return
+@code{/red/green/blue/../../omega/}.
+
+The return value is normally allocated via @code{malloc}. If no
+relative prefix can be found, return @code{NULL}.
+
+@end deftypefn
+
@c make-temp-file.c:138
@deftypefn Replacement char* make_temp_file (const char *@var{suffix})
@@ -440,6 +576,14 @@ Copies @var{count} bytes from memory area @var{from} to memory area
@end deftypefn
+@c mempcpy.c:23
+@deftypefn Supplemental void* mempcpy (void *@var{out}, const void *@var{in}, size_t @var{length})
+
+Copies @var{length} bytes from memory region @var{in} to region
+@var{out}. Returns a pointer to @var{out} + @var{length}.
+
+@end deftypefn
+
@c memset.c:6
@deftypefn Supplemental void* memset (void *@var{s}, int @var{c}, size_t @var{count})
@@ -466,7 +610,7 @@ reading and writing.
@end deftypefn
-@c pexecute.c:67
+@c pexecute.txh:1
@deftypefn Extension int pexecute (const char *@var{program}, char * const *@var{argv}, const char *@var{this_pname}, const char *@var{temp_base}, char **@var{errmsg_fmt}, char **@var{errmsg_arg}, int flags)
Executes a program.
@@ -481,14 +625,15 @@ use if needed. This is currently only needed for MS-DOS ports that
don't use @code{go32} (do any still exist?). Ports that don't need it
can pass @code{NULL}.
-(@code{@var{flags} & PEXECUTE_SEARCH}) is non-zero if @env{PATH} should be searched
-(??? It's not clear that GCC passes this flag correctly). (@code{@var{flags} &
-PEXECUTE_FIRST}) is nonzero for the first process in chain.
-(@code{@var{flags} & PEXECUTE_FIRST}) is nonzero for the last process
-in chain. The first/last flags could be simplified to only mark the
-last of a chain of processes but that requires the caller to always
-mark the last one (and not give up early if some error occurs).
-It's more robust to require the caller to mark both ends of the chain.
+(@code{@var{flags} & PEXECUTE_SEARCH}) is non-zero if @env{PATH}
+should be searched (??? It's not clear that GCC passes this flag
+correctly). (@code{@var{flags} & PEXECUTE_FIRST}) is nonzero for the
+first process in chain. (@code{@var{flags} & PEXECUTE_FIRST}) is
+nonzero for the last process in chain. The first/last flags could be
+simplified to only mark the last of a chain of processes but that
+requires the caller to always mark the last one (and not give up
+early if some error occurs). It's more robust to require the caller
+to mark both ends of the chain.
The result is the pid on systems like Unix where we
@code{fork}/@code{exec} and on systems like WIN32 and OS/2 where we
@@ -523,21 +668,23 @@ name is unset/removed.
@end deftypefn
-@c pexecute.c:104
+@c pexecute.txh:39
@deftypefn Extension int pwait (int @var{pid}, int *@var{status}, int @var{flags})
Waits for a program started by @code{pexecute} to finish.
@var{pid} is the process id of the task to wait for. @var{status} is
-the `status' argument to wait. @var{flags} is currently unused (allows
-future enhancement without breaking upward compatibility). Pass 0 for now.
+the `status' argument to wait. @var{flags} is currently unused
+(allows future enhancement without breaking upward compatibility).
+Pass 0 for now.
The result is the pid of the child reaped, or -1 for failure
(@code{errno} says why).
-On systems that don't support waiting for a particular child, @var{pid} is
-ignored. On systems like MS-DOS that don't really multitask @code{pwait}
-is just a mechanism to provide a consistent interface for the caller.
+On systems that don't support waiting for a particular child,
+@var{pid} is ignored. On systems like MS-DOS that don't really
+multitask @code{pwait} is just a mechanism to provide a consistent
+interface for the caller.
@end deftypefn
@@ -626,6 +773,19 @@ be the value @code{1}).
@end deftypefn
+@c snprintf.c:28
+@deftypefn Supplemental int snprintf (char *@var{buf}, size_t @var{n}, const char *@var{format}, ...)
+
+This function is similar to sprintf, but it will print at most @var{n}
+characters. On error the return value is -1, otherwise it returns the
+number of characters that would have been printed had @var{n} been
+sufficiently large, regardless of the actual value of @var{n}. Note
+some pre-C99 system libraries do not implement this correctly so users
+cannot generally rely on the return value if the system version of
+this function is used.
+
+@end deftypefn
+
@c spaces.c:22
@deftypefn Extension char* spaces (int @var{count})
@@ -635,6 +795,24 @@ valid until at least the next call.
@end deftypefn
+@c stpcpy.c:23
+@deftypefn Supplemental char* stpcpy (char *@var{dst}, const char *@var{src})
+
+Copies the string @var{src} into @var{dst}. Returns a pointer to
+@var{dst} + strlen(@var{src}).
+
+@end deftypefn
+
+@c stpncpy.c:23
+@deftypefn Supplemental char* stpncpy (char *@var{dst}, const char *@var{src}, size_t @var{len})
+
+Copies the string @var{src} into @var{dst}, copying exactly @var{len}
+and padding with zeros if necessary. If @var{len} < strlen(@var{src})
+then return @var{dst} + @var{len}, otherwise returns @var{dst} +
+strlen(@var{src}).
+
+@end deftypefn
+
@c strcasecmp.c:15
@deftypefn Supplemental int strcasecmp (const char *@var{s1}, const char *@var{s2})
@@ -838,7 +1016,7 @@ you pass a pointer to a pointer. This function will compute the size
of the buffer needed, allocate memory with @code{malloc}, and store a
pointer to the allocated memory in @code{*@var{resptr}}. The value
returned is the same as @code{vsprintf} would return. If memory could
-not be allocated, zero is returned and @code{NULL} is stored in
+not be allocated, minus one is returned and @code{NULL} is stored in
@code{*@var{resptr}}.
@end deftypefn
@@ -864,6 +1042,19 @@ nonstandard but common function @code{_doprnt}.
@end deftypefn
+@c vsnprintf.c:28
+@deftypefn Supplemental int vsnprintf (char *@var{buf}, size_t @var{n}, const char *@var{format}, va_list @var{ap})
+
+This function is similar to vsprintf, but it will print at most
+@var{n} characters. On error the return value is -1, otherwise it
+returns the number of characters that would have been printed had
+@var{n} been sufficiently large, regardless of the actual value of
+@var{n}. Note some pre-C99 system libraries do not implement this
+correctly so users cannot generally rely on the return value if the
+system version of this function is used.
+
+@end deftypefn
+
@c waitpid.c:3
@deftypefn Supplemental int waitpid (int @var{pid}, int *@var{status}, int)
diff --git a/contrib/binutils/libiberty/getcwd.c b/contrib/binutils/libiberty/getcwd.c
index 465b4e0..a19d267 100644
--- a/contrib/binutils/libiberty/getcwd.c
+++ b/contrib/binutils/libiberty/getcwd.c
@@ -40,7 +40,7 @@ extern int errno;
char *
getcwd (buf, len)
char *buf;
- int len;
+ size_t len;
{
char ourbuf[MAXPATHLEN];
char *result;
diff --git a/contrib/binutils/libiberty/getopt.c b/contrib/binutils/libiberty/getopt.c
new file mode 100644
index 0000000..a1e4827
--- /dev/null
+++ b/contrib/binutils/libiberty/getopt.c
@@ -0,0 +1,1056 @@
+/* Getopt for GNU.
+ NOTE: getopt is now part of the C library, so if you don't know what
+ "Keep this file name-space clean" means, talk to drepper@gnu.org
+ before changing it!
+
+ Copyright (C) 1987, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98
+ Free Software Foundation, Inc.
+
+ NOTE: This source is derived from an old version taken from the GNU C
+ Library (glibc).
+
+ This program is free software; you can redistribute it and/or modify it
+ under the terms of the GNU General Public License as published by the
+ Free Software Foundation; either version 2, or (at your option) any
+ later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
+ USA. */
+
+/* This tells Alpha OSF/1 not to define a getopt prototype in <stdio.h>.
+ Ditto for AIX 3.2 and <stdlib.h>. */
+#ifndef _NO_PROTO
+# define _NO_PROTO
+#endif
+
+#ifdef HAVE_CONFIG_H
+# include <config.h>
+#endif
+
+#if !defined __STDC__ || !__STDC__
+/* This is a separate conditional since some stdc systems
+ reject `defined (const)'. */
+# ifndef const
+# define const
+# endif
+#endif
+
+#include <stdio.h>
+
+/* Comment out all this code if we are using the GNU C Library, and are not
+ actually compiling the library itself. This code is part of the GNU C
+ Library, but also included in many other GNU distributions. Compiling
+ and linking in this code is a waste when using the GNU C library
+ (especially if it is a shared library). Rather than having every GNU
+ program understand `configure --with-gnu-libc' and omit the object files,
+ it is simpler to just do this in the source for each such file. */
+
+#define GETOPT_INTERFACE_VERSION 2
+#if !defined _LIBC && defined __GLIBC__ && __GLIBC__ >= 2
+# include <gnu-versions.h>
+# if _GNU_GETOPT_INTERFACE_VERSION == GETOPT_INTERFACE_VERSION
+# define ELIDE_CODE
+# endif
+#endif
+
+#ifndef ELIDE_CODE
+
+
+/* This needs to come after some library #include
+ to get __GNU_LIBRARY__ defined. */
+#ifdef __GNU_LIBRARY__
+/* Don't include stdlib.h for non-GNU C libraries because some of them
+ contain conflicting prototypes for getopt. */
+# include <stdlib.h>
+# include <unistd.h>
+#endif /* GNU C library. */
+
+#ifdef VMS
+# include <unixlib.h>
+# if HAVE_STRING_H - 0
+# include <string.h>
+# endif
+#endif
+
+#ifndef _
+/* This is for other GNU distributions with internationalized messages.
+ When compiling libc, the _ macro is predefined. */
+# if (HAVE_LIBINTL_H && ENABLE_NLS) || defined _LIBC
+# include <libintl.h>
+# define _(msgid) gettext (msgid)
+# else
+# define _(msgid) (msgid)
+# endif
+#endif
+
+/* This version of `getopt' appears to the caller like standard Unix `getopt'
+ but it behaves differently for the user, since it allows the user
+ to intersperse the options with the other arguments.
+
+ As `getopt' works, it permutes the elements of ARGV so that,
+ when it is done, all the options precede everything else. Thus
+ all application programs are extended to handle flexible argument order.
+
+ Setting the environment variable POSIXLY_CORRECT disables permutation.
+ Then the behavior is completely standard.
+
+ GNU application programs can use a third alternative mode in which
+ they can distinguish the relative order of options and other arguments. */
+
+#include "getopt.h"
+
+/* For communication from `getopt' to the caller.
+ When `getopt' finds an option that takes an argument,
+ the argument value is returned here.
+ Also, when `ordering' is RETURN_IN_ORDER,
+ each non-option ARGV-element is returned here. */
+
+char *optarg = NULL;
+
+/* Index in ARGV of the next element to be scanned.
+ This is used for communication to and from the caller
+ and for communication between successive calls to `getopt'.
+
+ On entry to `getopt', zero means this is the first call; initialize.
+
+ When `getopt' returns -1, this is the index of the first of the
+ non-option elements that the caller should itself scan.
+
+ Otherwise, `optind' communicates from one call to the next
+ how much of ARGV has been scanned so far. */
+
+/* 1003.2 says this must be 1 before any call. */
+int optind = 1;
+
+/* Formerly, initialization of getopt depended on optind==0, which
+ causes problems with re-calling getopt as programs generally don't
+ know that. */
+
+int __getopt_initialized = 0;
+
+/* The next char to be scanned in the option-element
+ in which the last option character we returned was found.
+ This allows us to pick up the scan where we left off.
+
+ If this is zero, or a null string, it means resume the scan
+ by advancing to the next ARGV-element. */
+
+static char *nextchar;
+
+/* Callers store zero here to inhibit the error message
+ for unrecognized options. */
+
+int opterr = 1;
+
+/* Set to an option character which was unrecognized.
+ This must be initialized on some systems to avoid linking in the
+ system's own getopt implementation. */
+
+int optopt = '?';
+
+/* Describe how to deal with options that follow non-option ARGV-elements.
+
+ If the caller did not specify anything,
+ the default is REQUIRE_ORDER if the environment variable
+ POSIXLY_CORRECT is defined, PERMUTE otherwise.
+
+ REQUIRE_ORDER means don't recognize them as options;
+ stop option processing when the first non-option is seen.
+ This is what Unix does.
+ This mode of operation is selected by either setting the environment
+ variable POSIXLY_CORRECT, or using `+' as the first character
+ of the list of option characters.
+
+ PERMUTE is the default. We permute the contents of ARGV as we scan,
+ so that eventually all the non-options are at the end. This allows options
+ to be given in any order, even with programs that were not written to
+ expect this.
+
+ RETURN_IN_ORDER is an option available to programs that were written
+ to expect options and other ARGV-elements in any order and that care about
+ the ordering of the two. We describe each non-option ARGV-element
+ as if it were the argument of an option with character code 1.
+ Using `-' as the first character of the list of option characters
+ selects this mode of operation.
+
+ The special argument `--' forces an end of option-scanning regardless
+ of the value of `ordering'. In the case of RETURN_IN_ORDER, only
+ `--' can cause `getopt' to return -1 with `optind' != ARGC. */
+
+static enum
+{
+ REQUIRE_ORDER, PERMUTE, RETURN_IN_ORDER
+} ordering;
+
+/* Value of POSIXLY_CORRECT environment variable. */
+static char *posixly_correct;
+
+#ifdef __GNU_LIBRARY__
+/* We want to avoid inclusion of string.h with non-GNU libraries
+ because there are many ways it can cause trouble.
+ On some systems, it contains special magic macros that don't work
+ in GCC. */
+# include <string.h>
+# define my_index strchr
+#else
+
+# if HAVE_STRING_H
+# include <string.h>
+# else
+# if HAVE_STRINGS_H
+# include <strings.h>
+# endif
+# endif
+
+/* Avoid depending on library functions or files
+ whose names are inconsistent. */
+
+#ifndef getenv
+extern char *getenv ();
+#endif
+
+static char *
+my_index (str, chr)
+ const char *str;
+ int chr;
+{
+ while (*str)
+ {
+ if (*str == chr)
+ return (char *) str;
+ str++;
+ }
+ return 0;
+}
+
+/* If using GCC, we can safely declare strlen this way.
+ If not using GCC, it is ok not to declare it. */
+#ifdef __GNUC__
+/* Note that Motorola Delta 68k R3V7 comes with GCC but not stddef.h.
+ That was relevant to code that was here before. */
+# if (!defined __STDC__ || !__STDC__) && !defined strlen
+/* gcc with -traditional declares the built-in strlen to return int,
+ and has done so at least since version 2.4.5. -- rms. */
+extern int strlen (const char *);
+# endif /* not __STDC__ */
+#endif /* __GNUC__ */
+
+#endif /* not __GNU_LIBRARY__ */
+
+/* Handle permutation of arguments. */
+
+/* Describe the part of ARGV that contains non-options that have
+ been skipped. `first_nonopt' is the index in ARGV of the first of them;
+ `last_nonopt' is the index after the last of them. */
+
+static int first_nonopt;
+static int last_nonopt;
+
+#ifdef _LIBC
+/* Bash 2.0 gives us an environment variable containing flags
+ indicating ARGV elements that should not be considered arguments. */
+
+/* Defined in getopt_init.c */
+extern char *__getopt_nonoption_flags;
+
+static int nonoption_flags_max_len;
+static int nonoption_flags_len;
+
+static int original_argc;
+static char *const *original_argv;
+
+/* Make sure the environment variable bash 2.0 puts in the environment
+ is valid for the getopt call we must make sure that the ARGV passed
+ to getopt is that one passed to the process. */
+static void
+__attribute__ ((unused))
+store_args_and_env (int argc, char *const *argv)
+{
+ /* XXX This is no good solution. We should rather copy the args so
+ that we can compare them later. But we must not use malloc(3). */
+ original_argc = argc;
+ original_argv = argv;
+}
+# ifdef text_set_element
+text_set_element (__libc_subinit, store_args_and_env);
+# endif /* text_set_element */
+
+# define SWAP_FLAGS(ch1, ch2) \
+ if (nonoption_flags_len > 0) \
+ { \
+ char __tmp = __getopt_nonoption_flags[ch1]; \
+ __getopt_nonoption_flags[ch1] = __getopt_nonoption_flags[ch2]; \
+ __getopt_nonoption_flags[ch2] = __tmp; \
+ }
+#else /* !_LIBC */
+# define SWAP_FLAGS(ch1, ch2)
+#endif /* _LIBC */
+
+/* Exchange two adjacent subsequences of ARGV.
+ One subsequence is elements [first_nonopt,last_nonopt)
+ which contains all the non-options that have been skipped so far.
+ The other is elements [last_nonopt,optind), which contains all
+ the options processed since those non-options were skipped.
+
+ `first_nonopt' and `last_nonopt' are relocated so that they describe
+ the new indices of the non-options in ARGV after they are moved. */
+
+#if defined __STDC__ && __STDC__
+static void exchange (char **);
+#endif
+
+static void
+exchange (argv)
+ char **argv;
+{
+ int bottom = first_nonopt;
+ int middle = last_nonopt;
+ int top = optind;
+ char *tem;
+
+ /* Exchange the shorter segment with the far end of the longer segment.
+ That puts the shorter segment into the right place.
+ It leaves the longer segment in the right place overall,
+ but it consists of two parts that need to be swapped next. */
+
+#ifdef _LIBC
+ /* First make sure the handling of the `__getopt_nonoption_flags'
+ string can work normally. Our top argument must be in the range
+ of the string. */
+ if (nonoption_flags_len > 0 && top >= nonoption_flags_max_len)
+ {
+ /* We must extend the array. The user plays games with us and
+ presents new arguments. */
+ char *new_str = malloc (top + 1);
+ if (new_str == NULL)
+ nonoption_flags_len = nonoption_flags_max_len = 0;
+ else
+ {
+ memset (mempcpy (new_str, __getopt_nonoption_flags,
+ nonoption_flags_max_len),
+ '\0', top + 1 - nonoption_flags_max_len);
+ nonoption_flags_max_len = top + 1;
+ __getopt_nonoption_flags = new_str;
+ }
+ }
+#endif
+
+ while (top > middle && middle > bottom)
+ {
+ if (top - middle > middle - bottom)
+ {
+ /* Bottom segment is the short one. */
+ int len = middle - bottom;
+ register int i;
+
+ /* Swap it with the top part of the top segment. */
+ for (i = 0; i < len; i++)
+ {
+ tem = argv[bottom + i];
+ argv[bottom + i] = argv[top - (middle - bottom) + i];
+ argv[top - (middle - bottom) + i] = tem;
+ SWAP_FLAGS (bottom + i, top - (middle - bottom) + i);
+ }
+ /* Exclude the moved bottom segment from further swapping. */
+ top -= len;
+ }
+ else
+ {
+ /* Top segment is the short one. */
+ int len = top - middle;
+ register int i;
+
+ /* Swap it with the bottom part of the bottom segment. */
+ for (i = 0; i < len; i++)
+ {
+ tem = argv[bottom + i];
+ argv[bottom + i] = argv[middle + i];
+ argv[middle + i] = tem;
+ SWAP_FLAGS (bottom + i, middle + i);
+ }
+ /* Exclude the moved top segment from further swapping. */
+ bottom += len;
+ }
+ }
+
+ /* Update records for the slots the non-options now occupy. */
+
+ first_nonopt += (optind - last_nonopt);
+ last_nonopt = optind;
+}
+
+/* Initialize the internal data when the first call is made. */
+
+#if defined __STDC__ && __STDC__
+static const char *_getopt_initialize (int, char *const *, const char *);
+#endif
+static const char *
+_getopt_initialize (argc, argv, optstring)
+ int argc;
+ char *const *argv;
+ const char *optstring;
+{
+ /* Start processing options with ARGV-element 1 (since ARGV-element 0
+ is the program name); the sequence of previously skipped
+ non-option ARGV-elements is empty. */
+
+ first_nonopt = last_nonopt = optind;
+
+ nextchar = NULL;
+
+ posixly_correct = getenv ("POSIXLY_CORRECT");
+
+ /* Determine how to handle the ordering of options and nonoptions. */
+
+ if (optstring[0] == '-')
+ {
+ ordering = RETURN_IN_ORDER;
+ ++optstring;
+ }
+ else if (optstring[0] == '+')
+ {
+ ordering = REQUIRE_ORDER;
+ ++optstring;
+ }
+ else if (posixly_correct != NULL)
+ ordering = REQUIRE_ORDER;
+ else
+ ordering = PERMUTE;
+
+#ifdef _LIBC
+ if (posixly_correct == NULL
+ && argc == original_argc && argv == original_argv)
+ {
+ if (nonoption_flags_max_len == 0)
+ {
+ if (__getopt_nonoption_flags == NULL
+ || __getopt_nonoption_flags[0] == '\0')
+ nonoption_flags_max_len = -1;
+ else
+ {
+ const char *orig_str = __getopt_nonoption_flags;
+ int len = nonoption_flags_max_len = strlen (orig_str);
+ if (nonoption_flags_max_len < argc)
+ nonoption_flags_max_len = argc;
+ __getopt_nonoption_flags =
+ (char *) malloc (nonoption_flags_max_len);
+ if (__getopt_nonoption_flags == NULL)
+ nonoption_flags_max_len = -1;
+ else
+ memset (mempcpy (__getopt_nonoption_flags, orig_str, len),
+ '\0', nonoption_flags_max_len - len);
+ }
+ }
+ nonoption_flags_len = nonoption_flags_max_len;
+ }
+ else
+ nonoption_flags_len = 0;
+#endif
+
+ return optstring;
+}
+
+/* Scan elements of ARGV (whose length is ARGC) for option characters
+ given in OPTSTRING.
+
+ If an element of ARGV starts with '-', and is not exactly "-" or "--",
+ then it is an option element. The characters of this element
+ (aside from the initial '-') are option characters. If `getopt'
+ is called repeatedly, it returns successively each of the option characters
+ from each of the option elements.
+
+ If `getopt' finds another option character, it returns that character,
+ updating `optind' and `nextchar' so that the next call to `getopt' can
+ resume the scan with the following option character or ARGV-element.
+
+ If there are no more option characters, `getopt' returns -1.
+ Then `optind' is the index in ARGV of the first ARGV-element
+ that is not an option. (The ARGV-elements have been permuted
+ so that those that are not options now come last.)
+
+ OPTSTRING is a string containing the legitimate option characters.
+ If an option character is seen that is not listed in OPTSTRING,
+ return '?' after printing an error message. If you set `opterr' to
+ zero, the error message is suppressed but we still return '?'.
+
+ If a char in OPTSTRING is followed by a colon, that means it wants an arg,
+ so the following text in the same ARGV-element, or the text of the following
+ ARGV-element, is returned in `optarg'. Two colons mean an option that
+ wants an optional arg; if there is text in the current ARGV-element,
+ it is returned in `optarg', otherwise `optarg' is set to zero.
+
+ If OPTSTRING starts with `-' or `+', it requests different methods of
+ handling the non-option ARGV-elements.
+ See the comments about RETURN_IN_ORDER and REQUIRE_ORDER, above.
+
+ Long-named options begin with `--' instead of `-'.
+ Their names may be abbreviated as long as the abbreviation is unique
+ or is an exact match for some defined option. If they have an
+ argument, it follows the option name in the same ARGV-element, separated
+ from the option name by a `=', or else the in next ARGV-element.
+ When `getopt' finds a long-named option, it returns 0 if that option's
+ `flag' field is nonzero, the value of the option's `val' field
+ if the `flag' field is zero.
+
+ The elements of ARGV aren't really const, because we permute them.
+ But we pretend they're const in the prototype to be compatible
+ with other systems.
+
+ LONGOPTS is a vector of `struct option' terminated by an
+ element containing a name which is zero.
+
+ LONGIND returns the index in LONGOPT of the long-named option found.
+ It is only valid when a long-named option has been found by the most
+ recent call.
+
+ If LONG_ONLY is nonzero, '-' as well as '--' can introduce
+ long-named options. */
+
+int
+_getopt_internal (argc, argv, optstring, longopts, longind, long_only)
+ int argc;
+ char *const *argv;
+ const char *optstring;
+ const struct option *longopts;
+ int *longind;
+ int long_only;
+{
+ optarg = NULL;
+
+ if (optind == 0 || !__getopt_initialized)
+ {
+ if (optind == 0)
+ optind = 1; /* Don't scan ARGV[0], the program name. */
+ optstring = _getopt_initialize (argc, argv, optstring);
+ __getopt_initialized = 1;
+ }
+
+ /* Test whether ARGV[optind] points to a non-option argument.
+ Either it does not have option syntax, or there is an environment flag
+ from the shell indicating it is not an option. The later information
+ is only used when the used in the GNU libc. */
+#ifdef _LIBC
+# define NONOPTION_P (argv[optind][0] != '-' || argv[optind][1] == '\0' \
+ || (optind < nonoption_flags_len \
+ && __getopt_nonoption_flags[optind] == '1'))
+#else
+# define NONOPTION_P (argv[optind][0] != '-' || argv[optind][1] == '\0')
+#endif
+
+ if (nextchar == NULL || *nextchar == '\0')
+ {
+ /* Advance to the next ARGV-element. */
+
+ /* Give FIRST_NONOPT & LAST_NONOPT rational values if OPTIND has been
+ moved back by the user (who may also have changed the arguments). */
+ if (last_nonopt > optind)
+ last_nonopt = optind;
+ if (first_nonopt > optind)
+ first_nonopt = optind;
+
+ if (ordering == PERMUTE)
+ {
+ /* If we have just processed some options following some non-options,
+ exchange them so that the options come first. */
+
+ if (first_nonopt != last_nonopt && last_nonopt != optind)
+ exchange ((char **) argv);
+ else if (last_nonopt != optind)
+ first_nonopt = optind;
+
+ /* Skip any additional non-options
+ and extend the range of non-options previously skipped. */
+
+ while (optind < argc && NONOPTION_P)
+ optind++;
+ last_nonopt = optind;
+ }
+
+ /* The special ARGV-element `--' means premature end of options.
+ Skip it like a null option,
+ then exchange with previous non-options as if it were an option,
+ then skip everything else like a non-option. */
+
+ if (optind != argc && !strcmp (argv[optind], "--"))
+ {
+ optind++;
+
+ if (first_nonopt != last_nonopt && last_nonopt != optind)
+ exchange ((char **) argv);
+ else if (first_nonopt == last_nonopt)
+ first_nonopt = optind;
+ last_nonopt = argc;
+
+ optind = argc;
+ }
+
+ /* If we have done all the ARGV-elements, stop the scan
+ and back over any non-options that we skipped and permuted. */
+
+ if (optind == argc)
+ {
+ /* Set the next-arg-index to point at the non-options
+ that we previously skipped, so the caller will digest them. */
+ if (first_nonopt != last_nonopt)
+ optind = first_nonopt;
+ return -1;
+ }
+
+ /* If we have come to a non-option and did not permute it,
+ either stop the scan or describe it to the caller and pass it by. */
+
+ if (NONOPTION_P)
+ {
+ if (ordering == REQUIRE_ORDER)
+ return -1;
+ optarg = argv[optind++];
+ return 1;
+ }
+
+ /* We have found another option-ARGV-element.
+ Skip the initial punctuation. */
+
+ nextchar = (argv[optind] + 1
+ + (longopts != NULL && argv[optind][1] == '-'));
+ }
+
+ /* Decode the current option-ARGV-element. */
+
+ /* Check whether the ARGV-element is a long option.
+
+ If long_only and the ARGV-element has the form "-f", where f is
+ a valid short option, don't consider it an abbreviated form of
+ a long option that starts with f. Otherwise there would be no
+ way to give the -f short option.
+
+ On the other hand, if there's a long option "fubar" and
+ the ARGV-element is "-fu", do consider that an abbreviation of
+ the long option, just like "--fu", and not "-f" with arg "u".
+
+ This distinction seems to be the most useful approach. */
+
+ if (longopts != NULL
+ && (argv[optind][1] == '-'
+ || (long_only && (argv[optind][2] || !my_index (optstring, argv[optind][1])))))
+ {
+ char *nameend;
+ const struct option *p;
+ const struct option *pfound = NULL;
+ int exact = 0;
+ int ambig = 0;
+ int indfound = -1;
+ int option_index;
+
+ for (nameend = nextchar; *nameend && *nameend != '='; nameend++)
+ /* Do nothing. */ ;
+
+ /* Test all long options for either exact match
+ or abbreviated matches. */
+ for (p = longopts, option_index = 0; p->name; p++, option_index++)
+ if (!strncmp (p->name, nextchar, nameend - nextchar))
+ {
+ if ((unsigned int) (nameend - nextchar)
+ == (unsigned int) strlen (p->name))
+ {
+ /* Exact match found. */
+ pfound = p;
+ indfound = option_index;
+ exact = 1;
+ break;
+ }
+ else if (pfound == NULL)
+ {
+ /* First nonexact match found. */
+ pfound = p;
+ indfound = option_index;
+ }
+ else
+ /* Second or later nonexact match found. */
+ ambig = 1;
+ }
+
+ if (ambig && !exact)
+ {
+ if (opterr)
+ fprintf (stderr, _("%s: option `%s' is ambiguous\n"),
+ argv[0], argv[optind]);
+ nextchar += strlen (nextchar);
+ optind++;
+ optopt = 0;
+ return '?';
+ }
+
+ if (pfound != NULL)
+ {
+ option_index = indfound;
+ optind++;
+ if (*nameend)
+ {
+ /* Don't test has_arg with >, because some C compilers don't
+ allow it to be used on enums. */
+ if (pfound->has_arg)
+ optarg = nameend + 1;
+ else
+ {
+ if (opterr)
+ {
+ if (argv[optind - 1][1] == '-')
+ /* --option */
+ fprintf (stderr,
+ _("%s: option `--%s' doesn't allow an argument\n"),
+ argv[0], pfound->name);
+ else
+ /* +option or -option */
+ fprintf (stderr,
+ _("%s: option `%c%s' doesn't allow an argument\n"),
+ argv[0], argv[optind - 1][0], pfound->name);
+
+ nextchar += strlen (nextchar);
+
+ optopt = pfound->val;
+ return '?';
+ }
+ }
+ }
+ else if (pfound->has_arg == 1)
+ {
+ if (optind < argc)
+ optarg = argv[optind++];
+ else
+ {
+ if (opterr)
+ fprintf (stderr,
+ _("%s: option `%s' requires an argument\n"),
+ argv[0], argv[optind - 1]);
+ nextchar += strlen (nextchar);
+ optopt = pfound->val;
+ return optstring[0] == ':' ? ':' : '?';
+ }
+ }
+ nextchar += strlen (nextchar);
+ if (longind != NULL)
+ *longind = option_index;
+ if (pfound->flag)
+ {
+ *(pfound->flag) = pfound->val;
+ return 0;
+ }
+ return pfound->val;
+ }
+
+ /* Can't find it as a long option. If this is not getopt_long_only,
+ or the option starts with '--' or is not a valid short
+ option, then it's an error.
+ Otherwise interpret it as a short option. */
+ if (!long_only || argv[optind][1] == '-'
+ || my_index (optstring, *nextchar) == NULL)
+ {
+ if (opterr)
+ {
+ if (argv[optind][1] == '-')
+ /* --option */
+ fprintf (stderr, _("%s: unrecognized option `--%s'\n"),
+ argv[0], nextchar);
+ else
+ /* +option or -option */
+ fprintf (stderr, _("%s: unrecognized option `%c%s'\n"),
+ argv[0], argv[optind][0], nextchar);
+ }
+ nextchar = (char *) "";
+ optind++;
+ optopt = 0;
+ return '?';
+ }
+ }
+
+ /* Look at and handle the next short option-character. */
+
+ {
+ char c = *nextchar++;
+ char *temp = my_index (optstring, c);
+
+ /* Increment `optind' when we start to process its last character. */
+ if (*nextchar == '\0')
+ ++optind;
+
+ if (temp == NULL || c == ':')
+ {
+ if (opterr)
+ {
+ if (posixly_correct)
+ /* 1003.2 specifies the format of this message. */
+ fprintf (stderr, _("%s: illegal option -- %c\n"),
+ argv[0], c);
+ else
+ fprintf (stderr, _("%s: invalid option -- %c\n"),
+ argv[0], c);
+ }
+ optopt = c;
+ return '?';
+ }
+ /* Convenience. Treat POSIX -W foo same as long option --foo */
+ if (temp[0] == 'W' && temp[1] == ';')
+ {
+ char *nameend;
+ const struct option *p;
+ const struct option *pfound = NULL;
+ int exact = 0;
+ int ambig = 0;
+ int indfound = 0;
+ int option_index;
+
+ /* This is an option that requires an argument. */
+ if (*nextchar != '\0')
+ {
+ optarg = nextchar;
+ /* If we end this ARGV-element by taking the rest as an arg,
+ we must advance to the next element now. */
+ optind++;
+ }
+ else if (optind == argc)
+ {
+ if (opterr)
+ {
+ /* 1003.2 specifies the format of this message. */
+ fprintf (stderr, _("%s: option requires an argument -- %c\n"),
+ argv[0], c);
+ }
+ optopt = c;
+ if (optstring[0] == ':')
+ c = ':';
+ else
+ c = '?';
+ return c;
+ }
+ else
+ /* We already incremented `optind' once;
+ increment it again when taking next ARGV-elt as argument. */
+ optarg = argv[optind++];
+
+ /* optarg is now the argument, see if it's in the
+ table of longopts. */
+
+ for (nextchar = nameend = optarg; *nameend && *nameend != '='; nameend++)
+ /* Do nothing. */ ;
+
+ /* Test all long options for either exact match
+ or abbreviated matches. */
+ for (p = longopts, option_index = 0; p->name; p++, option_index++)
+ if (!strncmp (p->name, nextchar, nameend - nextchar))
+ {
+ if ((unsigned int) (nameend - nextchar) == strlen (p->name))
+ {
+ /* Exact match found. */
+ pfound = p;
+ indfound = option_index;
+ exact = 1;
+ break;
+ }
+ else if (pfound == NULL)
+ {
+ /* First nonexact match found. */
+ pfound = p;
+ indfound = option_index;
+ }
+ else
+ /* Second or later nonexact match found. */
+ ambig = 1;
+ }
+ if (ambig && !exact)
+ {
+ if (opterr)
+ fprintf (stderr, _("%s: option `-W %s' is ambiguous\n"),
+ argv[0], argv[optind]);
+ nextchar += strlen (nextchar);
+ optind++;
+ return '?';
+ }
+ if (pfound != NULL)
+ {
+ option_index = indfound;
+ if (*nameend)
+ {
+ /* Don't test has_arg with >, because some C compilers don't
+ allow it to be used on enums. */
+ if (pfound->has_arg)
+ optarg = nameend + 1;
+ else
+ {
+ if (opterr)
+ fprintf (stderr, _("\
+%s: option `-W %s' doesn't allow an argument\n"),
+ argv[0], pfound->name);
+
+ nextchar += strlen (nextchar);
+ return '?';
+ }
+ }
+ else if (pfound->has_arg == 1)
+ {
+ if (optind < argc)
+ optarg = argv[optind++];
+ else
+ {
+ if (opterr)
+ fprintf (stderr,
+ _("%s: option `%s' requires an argument\n"),
+ argv[0], argv[optind - 1]);
+ nextchar += strlen (nextchar);
+ return optstring[0] == ':' ? ':' : '?';
+ }
+ }
+ nextchar += strlen (nextchar);
+ if (longind != NULL)
+ *longind = option_index;
+ if (pfound->flag)
+ {
+ *(pfound->flag) = pfound->val;
+ return 0;
+ }
+ return pfound->val;
+ }
+ nextchar = NULL;
+ return 'W'; /* Let the application handle it. */
+ }
+ if (temp[1] == ':')
+ {
+ if (temp[2] == ':')
+ {
+ /* This is an option that accepts an argument optionally. */
+ if (*nextchar != '\0')
+ {
+ optarg = nextchar;
+ optind++;
+ }
+ else
+ optarg = NULL;
+ nextchar = NULL;
+ }
+ else
+ {
+ /* This is an option that requires an argument. */
+ if (*nextchar != '\0')
+ {
+ optarg = nextchar;
+ /* If we end this ARGV-element by taking the rest as an arg,
+ we must advance to the next element now. */
+ optind++;
+ }
+ else if (optind == argc)
+ {
+ if (opterr)
+ {
+ /* 1003.2 specifies the format of this message. */
+ fprintf (stderr,
+ _("%s: option requires an argument -- %c\n"),
+ argv[0], c);
+ }
+ optopt = c;
+ if (optstring[0] == ':')
+ c = ':';
+ else
+ c = '?';
+ }
+ else
+ /* We already incremented `optind' once;
+ increment it again when taking next ARGV-elt as argument. */
+ optarg = argv[optind++];
+ nextchar = NULL;
+ }
+ }
+ return c;
+ }
+}
+
+int
+getopt (argc, argv, optstring)
+ int argc;
+ char *const *argv;
+ const char *optstring;
+{
+ return _getopt_internal (argc, argv, optstring,
+ (const struct option *) 0,
+ (int *) 0,
+ 0);
+}
+
+#endif /* Not ELIDE_CODE. */
+
+#ifdef TEST
+
+/* Compile with -DTEST to make an executable for use in testing
+ the above definition of `getopt'. */
+
+int
+main (argc, argv)
+ int argc;
+ char **argv;
+{
+ int c;
+ int digit_optind = 0;
+
+ while (1)
+ {
+ int this_option_optind = optind ? optind : 1;
+
+ c = getopt (argc, argv, "abc:d:0123456789");
+ if (c == -1)
+ break;
+
+ switch (c)
+ {
+ case '0':
+ case '1':
+ case '2':
+ case '3':
+ case '4':
+ case '5':
+ case '6':
+ case '7':
+ case '8':
+ case '9':
+ if (digit_optind != 0 && digit_optind != this_option_optind)
+ printf ("digits occur in two different argv-elements.\n");
+ digit_optind = this_option_optind;
+ printf ("option %c\n", c);
+ break;
+
+ case 'a':
+ printf ("option a\n");
+ break;
+
+ case 'b':
+ printf ("option b\n");
+ break;
+
+ case 'c':
+ printf ("option c with value `%s'\n", optarg);
+ break;
+
+ case '?':
+ break;
+
+ default:
+ printf ("?? getopt returned character code 0%o ??\n", c);
+ }
+ }
+
+ if (optind < argc)
+ {
+ printf ("non-option ARGV-elements: ");
+ while (optind < argc)
+ printf ("%s ", argv[optind++]);
+ printf ("\n");
+ }
+
+ exit (0);
+}
+
+#endif /* TEST */
diff --git a/contrib/binutils/libiberty/getopt1.c b/contrib/binutils/libiberty/getopt1.c
new file mode 100644
index 0000000..a3637c2
--- /dev/null
+++ b/contrib/binutils/libiberty/getopt1.c
@@ -0,0 +1,190 @@
+/* getopt_long and getopt_long_only entry points for GNU getopt.
+ Copyright (C) 1987,88,89,90,91,92,93,94,96,97,98
+ Free Software Foundation, Inc.
+
+ NOTE: This source is derived from an old version taken from the GNU C
+ Library (glibc).
+
+ This program is free software; you can redistribute it and/or modify it
+ under the terms of the GNU General Public License as published by the
+ Free Software Foundation; either version 2, or (at your option) any
+ later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
+ USA. */
+
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include "getopt.h"
+
+#if !defined __STDC__ || !__STDC__
+/* This is a separate conditional since some stdc systems
+ reject `defined (const)'. */
+#ifndef const
+#define const
+#endif
+#endif
+
+#include <stdio.h>
+
+/* Comment out all this code if we are using the GNU C Library, and are not
+ actually compiling the library itself. This code is part of the GNU C
+ Library, but also included in many other GNU distributions. Compiling
+ and linking in this code is a waste when using the GNU C library
+ (especially if it is a shared library). Rather than having every GNU
+ program understand `configure --with-gnu-libc' and omit the object files,
+ it is simpler to just do this in the source for each such file. */
+
+#define GETOPT_INTERFACE_VERSION 2
+#if !defined _LIBC && defined __GLIBC__ && __GLIBC__ >= 2
+#include <gnu-versions.h>
+#if _GNU_GETOPT_INTERFACE_VERSION == GETOPT_INTERFACE_VERSION
+#define ELIDE_CODE
+#endif
+#endif
+
+#ifndef ELIDE_CODE
+
+
+/* This needs to come after some library #include
+ to get __GNU_LIBRARY__ defined. */
+#ifdef __GNU_LIBRARY__
+#include <stdlib.h>
+#endif
+
+#ifndef NULL
+#define NULL 0
+#endif
+
+int
+getopt_long (argc, argv, options, long_options, opt_index)
+ int argc;
+ char *const *argv;
+ const char *options;
+ const struct option *long_options;
+ int *opt_index;
+{
+ return _getopt_internal (argc, argv, options, long_options, opt_index, 0);
+}
+
+/* Like getopt_long, but '-' as well as '--' can indicate a long option.
+ If an option that starts with '-' (not '--') doesn't match a long option,
+ but does match a short option, it is parsed as a short option
+ instead. */
+
+int
+getopt_long_only (argc, argv, options, long_options, opt_index)
+ int argc;
+ char *const *argv;
+ const char *options;
+ const struct option *long_options;
+ int *opt_index;
+{
+ return _getopt_internal (argc, argv, options, long_options, opt_index, 1);
+}
+
+
+#endif /* Not ELIDE_CODE. */
+
+#ifdef TEST
+
+#include <stdio.h>
+
+int
+main (argc, argv)
+ int argc;
+ char **argv;
+{
+ int c;
+ int digit_optind = 0;
+
+ while (1)
+ {
+ int this_option_optind = optind ? optind : 1;
+ int option_index = 0;
+ static struct option long_options[] =
+ {
+ {"add", 1, 0, 0},
+ {"append", 0, 0, 0},
+ {"delete", 1, 0, 0},
+ {"verbose", 0, 0, 0},
+ {"create", 0, 0, 0},
+ {"file", 1, 0, 0},
+ {0, 0, 0, 0}
+ };
+
+ c = getopt_long (argc, argv, "abc:d:0123456789",
+ long_options, &option_index);
+ if (c == -1)
+ break;
+
+ switch (c)
+ {
+ case 0:
+ printf ("option %s", long_options[option_index].name);
+ if (optarg)
+ printf (" with arg %s", optarg);
+ printf ("\n");
+ break;
+
+ case '0':
+ case '1':
+ case '2':
+ case '3':
+ case '4':
+ case '5':
+ case '6':
+ case '7':
+ case '8':
+ case '9':
+ if (digit_optind != 0 && digit_optind != this_option_optind)
+ printf ("digits occur in two different argv-elements.\n");
+ digit_optind = this_option_optind;
+ printf ("option %c\n", c);
+ break;
+
+ case 'a':
+ printf ("option a\n");
+ break;
+
+ case 'b':
+ printf ("option b\n");
+ break;
+
+ case 'c':
+ printf ("option c with value `%s'\n", optarg);
+ break;
+
+ case 'd':
+ printf ("option d with value `%s'\n", optarg);
+ break;
+
+ case '?':
+ break;
+
+ default:
+ printf ("?? getopt returned character code 0%o ??\n", c);
+ }
+ }
+
+ if (optind < argc)
+ {
+ printf ("non-option ARGV-elements: ");
+ while (optind < argc)
+ printf ("%s ", argv[optind++]);
+ printf ("\n");
+ }
+
+ exit (0);
+}
+
+#endif /* TEST */
diff --git a/contrib/binutils/libiberty/getpwd.c b/contrib/binutils/libiberty/getpwd.c
index f508b1e..31c7d20 100644
--- a/contrib/binutils/libiberty/getpwd.c
+++ b/contrib/binutils/libiberty/getpwd.c
@@ -35,6 +35,9 @@ extern int errno;
#if HAVE_SYS_STAT_H
#include <sys/stat.h>
#endif
+#if HAVE_LIMITS_H
+#include <limits.h>
+#endif
/* Prototype these in case the system headers don't provide them. */
extern char *getpwd ();
diff --git a/contrib/binutils/libiberty/hashtab.c b/contrib/binutils/libiberty/hashtab.c
index 6bf59ff..231fbc0 100644
--- a/contrib/binutils/libiberty/hashtab.c
+++ b/contrib/binutils/libiberty/hashtab.c
@@ -1,5 +1,5 @@
/* An expandable hash tables datatype.
- Copyright (C) 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright (C) 1999, 2000, 2001, 2002, 2003 Free Software Foundation, Inc.
Contributed by Vladimir Makarov (vmakarov@cygnus.com).
This file is part of the libiberty library.
@@ -45,6 +45,10 @@ Boston, MA 02111-1307, USA. */
#include <string.h>
#endif
+#ifdef HAVE_MALLOC_H
+#include <malloc.h>
+#endif
+
#include <stdio.h>
#include "libiberty.h"
@@ -191,6 +195,63 @@ htab_create_alloc (size, hash_f, eq_f, del_f, alloc_f, free_f)
return result;
}
+/* As above, but use the variants of alloc_f and free_f which accept
+ an extra argument. */
+
+htab_t
+htab_create_alloc_ex (size, hash_f, eq_f, del_f, alloc_arg, alloc_f,
+ free_f)
+ size_t size;
+ htab_hash hash_f;
+ htab_eq eq_f;
+ htab_del del_f;
+ PTR alloc_arg;
+ htab_alloc_with_arg alloc_f;
+ htab_free_with_arg free_f;
+{
+ htab_t result;
+
+ size = higher_prime_number (size);
+ result = (htab_t) (*alloc_f) (alloc_arg, 1, sizeof (struct htab));
+ if (result == NULL)
+ return NULL;
+ result->entries = (PTR *) (*alloc_f) (alloc_arg, size, sizeof (PTR));
+ if (result->entries == NULL)
+ {
+ if (free_f != NULL)
+ (*free_f) (alloc_arg, result);
+ return NULL;
+ }
+ result->size = size;
+ result->hash_f = hash_f;
+ result->eq_f = eq_f;
+ result->del_f = del_f;
+ result->alloc_arg = alloc_arg;
+ result->alloc_with_arg_f = alloc_f;
+ result->free_with_arg_f = free_f;
+ return result;
+}
+
+/* Update the function pointers and allocation parameter in the htab_t. */
+
+void
+htab_set_functions_ex (htab, hash_f, eq_f, del_f, alloc_arg, alloc_f, free_f)
+ htab_t htab;
+ htab_hash hash_f;
+ htab_eq eq_f;
+ htab_del del_f;
+ PTR alloc_arg;
+ htab_alloc_with_arg alloc_f;
+ htab_free_with_arg free_f;
+{
+ htab->hash_f = hash_f;
+ htab->eq_f = eq_f;
+ htab->del_f = del_f;
+ htab->alloc_arg = alloc_arg;
+ htab->alloc_with_arg_f = alloc_f;
+ htab->free_with_arg_f = free_f;
+}
+
/* These functions exist solely for backward compatibility. */
#undef htab_create
@@ -234,6 +295,11 @@ htab_delete (htab)
(*htab->free_f) (htab->entries);
(*htab->free_f) (htab);
}
+ else if (htab->free_with_arg_f != NULL)
+ {
+ (*htab->free_with_arg_f) (htab->alloc_arg, htab->entries);
+ (*htab->free_with_arg_f) (htab->alloc_arg, htab);
+ }
}
/* This function clears all entries in the given hash table. */
@@ -306,16 +372,29 @@ htab_expand (htab)
PTR *olimit;
PTR *p;
PTR *nentries;
+ size_t nsize;
oentries = htab->entries;
olimit = oentries + htab->size;
- htab->size = higher_prime_number (htab->size * 2);
-
- nentries = (PTR *) (*htab->alloc_f) (htab->size, sizeof (PTR *));
+ /* Resize only when table after removal of unused elements is either
+ too full or too empty. */
+ if ((htab->n_elements - htab->n_deleted) * 2 > htab->size
+ || ((htab->n_elements - htab->n_deleted) * 8 < htab->size
+ && htab->size > 32))
+ nsize = higher_prime_number ((htab->n_elements - htab->n_deleted) * 2);
+ else
+ nsize = htab->size;
+
+ if (htab->alloc_with_arg_f != NULL)
+ nentries = (PTR *) (*htab->alloc_with_arg_f) (htab->alloc_arg, nsize,
+ sizeof (PTR *));
+ else
+ nentries = (PTR *) (*htab->alloc_f) (nsize, sizeof (PTR *));
if (nentries == NULL)
return 0;
htab->entries = nentries;
+ htab->size = nsize;
htab->n_elements -= htab->n_deleted;
htab->n_deleted = 0;
@@ -338,6 +417,8 @@ htab_expand (htab)
if (htab->free_f != NULL)
(*htab->free_f) (oentries);
+ else if (htab->free_with_arg_f != NULL)
+ (*htab->free_with_arg_f) (htab->alloc_arg, oentries);
return 1;
}
@@ -454,14 +535,14 @@ htab_find_slot_with_hash (htab, element, hash, insert)
if (insert == NO_INSERT)
return NULL;
- htab->n_elements++;
-
if (first_deleted_slot)
{
+ htab->n_deleted--;
*first_deleted_slot = EMPTY_ENTRY;
return first_deleted_slot;
}
+ htab->n_elements++;
return &htab->entries[index];
}
@@ -526,13 +607,16 @@ htab_clear_slot (htab, slot)
argument. */
void
-htab_traverse (htab, callback, info)
+htab_traverse_noresize (htab, callback, info)
htab_t htab;
htab_trav callback;
PTR info;
{
- PTR *slot = htab->entries;
- PTR *limit = slot + htab->size;
+ PTR *slot;
+ PTR *limit;
+
+ slot = htab->entries;
+ limit = slot + htab->size;
do
{
@@ -545,6 +629,21 @@ htab_traverse (htab, callback, info)
while (++slot < limit);
}
+/* Like htab_traverse_noresize, but does resize the table when it is
+ too empty to improve effectivity of subsequent calls. */
+
+void
+htab_traverse (htab, callback, info)
+ htab_t htab;
+ htab_trav callback;
+ PTR info;
+{
+ if ((htab->n_elements - htab->n_deleted) * 8 < htab->size)
+ htab_expand (htab);
+
+ htab_traverse_noresize (htab, callback, info);
+}
+
/* Return the current size of given hash table. */
size_t
@@ -614,3 +713,141 @@ htab_hash_string (p)
return r;
}
+
+/* DERIVED FROM:
+--------------------------------------------------------------------
+lookup2.c, by Bob Jenkins, December 1996, Public Domain.
+hash(), hash2(), hash3, and mix() are externally useful functions.
+Routines to test the hash are included if SELF_TEST is defined.
+You can use this free for any purpose. It has no warranty.
+--------------------------------------------------------------------
+*/
+
+/*
+--------------------------------------------------------------------
+mix -- mix 3 32-bit values reversibly.
+For every delta with one or two bit set, and the deltas of all three
+ high bits or all three low bits, whether the original value of a,b,c
+ is almost all zero or is uniformly distributed,
+* If mix() is run forward or backward, at least 32 bits in a,b,c
+ have at least 1/4 probability of changing.
+* If mix() is run forward, every bit of c will change between 1/3 and
+ 2/3 of the time. (Well, 22/100 and 78/100 for some 2-bit deltas.)
+mix() was built out of 36 single-cycle latency instructions in a
+ structure that could supported 2x parallelism, like so:
+ a -= b;
+ a -= c; x = (c>>13);
+ b -= c; a ^= x;
+ b -= a; x = (a<<8);
+ c -= a; b ^= x;
+ c -= b; x = (b>>13);
+ ...
+ Unfortunately, superscalar Pentiums and Sparcs can't take advantage
+ of that parallelism. They've also turned some of those single-cycle
+ latency instructions into multi-cycle latency instructions. Still,
+ this is the fastest good hash I could find. There were about 2^^68
+ to choose from. I only looked at a billion or so.
+--------------------------------------------------------------------
+*/
+/* same, but slower, works on systems that might have 8 byte hashval_t's */
+#define mix(a,b,c) \
+{ \
+ a -= b; a -= c; a ^= (c>>13); \
+ b -= c; b -= a; b ^= (a<< 8); \
+ c -= a; c -= b; c ^= ((b&0xffffffff)>>13); \
+ a -= b; a -= c; a ^= ((c&0xffffffff)>>12); \
+ b -= c; b -= a; b = (b ^ (a<<16)) & 0xffffffff; \
+ c -= a; c -= b; c = (c ^ (b>> 5)) & 0xffffffff; \
+ a -= b; a -= c; a = (a ^ (c>> 3)) & 0xffffffff; \
+ b -= c; b -= a; b = (b ^ (a<<10)) & 0xffffffff; \
+ c -= a; c -= b; c = (c ^ (b>>15)) & 0xffffffff; \
+}
+
+/*
+--------------------------------------------------------------------
+hash() -- hash a variable-length key into a 32-bit value
+ k : the key (the unaligned variable-length array of bytes)
+ len : the length of the key, counting by bytes
+ level : can be any 4-byte value
+Returns a 32-bit value. Every bit of the key affects every bit of
+the return value. Every 1-bit and 2-bit delta achieves avalanche.
+About 36+6len instructions.
+
+The best hash table sizes are powers of 2. There is no need to do
+mod a prime (mod is sooo slow!). If you need less than 32 bits,
+use a bitmask. For example, if you need only 10 bits, do
+ h = (h & hashmask(10));
+In which case, the hash table should have hashsize(10) elements.
+
+If you are hashing n strings (ub1 **)k, do it like this:
+ for (i=0, h=0; i<n; ++i) h = hash( k[i], len[i], h);
+
+By Bob Jenkins, 1996. bob_jenkins@burtleburtle.net. You may use this
+code any way you wish, private, educational, or commercial. It's free.
+
+See http://burtleburtle.net/bob/hash/evahash.html
+Use for hash table lookup, or anything where one collision in 2^32 is
+acceptable. Do NOT use for cryptographic purposes.
+--------------------------------------------------------------------
+*/
+
+hashval_t iterative_hash (k_in, length, initval)
+ const PTR k_in; /* the key */
+ register size_t length; /* the length of the key */
+ register hashval_t initval; /* the previous hash, or an arbitrary value */
+{
+ register const unsigned char *k = (const unsigned char *)k_in;
+ register hashval_t a,b,c,len;
+
+ /* Set up the internal state */
+ len = length;
+ a = b = 0x9e3779b9; /* the golden ratio; an arbitrary value */
+ c = initval; /* the previous hash value */
+
+ /*---------------------------------------- handle most of the key */
+#ifndef WORDS_BIGENDIAN
+ /* On a little-endian machine, if the data is 4-byte aligned we can hash
+ by word for better speed. This gives nondeterministic results on
+ big-endian machines. */
+ if (sizeof (hashval_t) == 4 && (((size_t)k)&3) == 0)
+ while (len >= 12) /* aligned */
+ {
+ a += *(hashval_t *)(k+0);
+ b += *(hashval_t *)(k+4);
+ c += *(hashval_t *)(k+8);
+ mix(a,b,c);
+ k += 12; len -= 12;
+ }
+ else /* unaligned */
+#endif
+ while (len >= 12)
+ {
+ a += (k[0] +((hashval_t)k[1]<<8) +((hashval_t)k[2]<<16) +((hashval_t)k[3]<<24));
+ b += (k[4] +((hashval_t)k[5]<<8) +((hashval_t)k[6]<<16) +((hashval_t)k[7]<<24));
+ c += (k[8] +((hashval_t)k[9]<<8) +((hashval_t)k[10]<<16)+((hashval_t)k[11]<<24));
+ mix(a,b,c);
+ k += 12; len -= 12;
+ }
+
+ /*------------------------------------- handle the last 11 bytes */
+ c += length;
+ switch(len) /* all the case statements fall through */
+ {
+ case 11: c+=((hashval_t)k[10]<<24);
+ case 10: c+=((hashval_t)k[9]<<16);
+ case 9 : c+=((hashval_t)k[8]<<8);
+ /* the first byte of c is reserved for the length */
+ case 8 : b+=((hashval_t)k[7]<<24);
+ case 7 : b+=((hashval_t)k[6]<<16);
+ case 6 : b+=((hashval_t)k[5]<<8);
+ case 5 : b+=k[4];
+ case 4 : a+=((hashval_t)k[3]<<24);
+ case 3 : a+=((hashval_t)k[2]<<16);
+ case 2 : a+=((hashval_t)k[1]<<8);
+ case 1 : a+=k[0];
+ /* case 0: nothing left to add */
+ }
+ mix(a,b,c);
+ /*-------------------------------------------- report the result */
+ return c;
+}
diff --git a/contrib/binutils/libiberty/hex.c b/contrib/binutils/libiberty/hex.c
index 5f82292..e4c5dfa 100644
--- a/contrib/binutils/libiberty/hex.c
+++ b/contrib/binutils/libiberty/hex.c
@@ -19,6 +19,11 @@ Boston, MA 02111-1307, USA. */
#include <stdio.h> /* for EOF */
#include "libiberty.h"
+#include "safe-ctype.h" /* for HOST_CHARSET_ASCII */
+
+#if EOF != -1
+ #error "hex.c requires EOF == -1"
+#endif
/*
@@ -39,13 +44,19 @@ or zero if it is not. Note that the value you pass will be cast to
@end deftypefn
-@deftypefn Extension int hex_value (int @var{c})
+@deftypefn Extension unsigned int hex_value (int @var{c})
Returns the numeric equivalent of the given character when interpreted
as a hexidecimal digit. The result is undefined if you pass an
invalid hex digit. Note that the value you pass will be cast to
@code{unsigned char} within the macro.
+The @code{hex_value} macro returns @code{unsigned int}, rather than
+signed @code{int}, to make it easier to use in parsing addresses from
+hex dump files: a signed @code{int} would be sign-extended when
+converted to a wider unsigned type --- like @code{bfd_vma}, on some
+systems.
+
@end deftypefn
@undocumented _hex_array_size
@@ -56,11 +67,9 @@ invalid hex digit. Note that the value you pass will be cast to
/* Are we ASCII? */
-#if '\n' == 0x0A && ' ' == 0x20 && '0' == 0x30 \
- && 'A' == 0x41 && 'a' == 0x61 && '!' == 0x21 \
- && EOF == -1
+#if HOST_CHARSET == HOST_CHARSET_ASCII
-const char _hex_value[_hex_array_size] =
+const unsigned char _hex_value[_hex_array_size] =
{
_hex_bad, _hex_bad, _hex_bad, _hex_bad, /* NUL SOH STX ETX */
_hex_bad, _hex_bad, _hex_bad, _hex_bad, /* EOT ENQ ACK BEL */
@@ -139,7 +148,7 @@ const char _hex_value[_hex_array_size] =
#else
-char _hex_value[_hex_array_size];
+unsigned char _hex_value[_hex_array_size];
#endif /* not ASCII */
diff --git a/contrib/binutils/libiberty/lbasename.c b/contrib/binutils/libiberty/lbasename.c
index 43cb73f..200a87f 100644
--- a/contrib/binutils/libiberty/lbasename.c
+++ b/contrib/binutils/libiberty/lbasename.c
@@ -40,25 +40,7 @@ and a path ending in @code{/} returns the empty string after it.
#include "ansidecl.h"
#include "libiberty.h"
#include "safe-ctype.h"
-
-#ifndef DIR_SEPARATOR
-# define DIR_SEPARATOR '/'
-#endif
-
-#if defined (_WIN32) || defined (__MSDOS__) \
- || defined (__DJGPP__) || defined (__OS2__)
-# define HAVE_DOS_BASED_FILE_SYSTEM
-# ifndef DIR_SEPARATOR_2
-# define DIR_SEPARATOR_2 '\\'
-# endif
-#endif
-
-#ifndef DIR_SEPARATOR_2
-# define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR)
-#else
-# define IS_DIR_SEPARATOR(ch) \
- (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2))
-#endif
+#include "filenames.h"
const char *
lbasename (name)
diff --git a/contrib/binutils/libiberty/libiberty.texi b/contrib/binutils/libiberty/libiberty.texi
index 4b60d6a..b57e3c5 100644
--- a/contrib/binutils/libiberty/libiberty.texi
+++ b/contrib/binutils/libiberty/libiberty.texi
@@ -29,7 +29,7 @@ This edition accompanies GCC 3, September 2001.
Copyright @copyright{} 2001 Free Software Foundation, Inc.
Permission is granted to copy, distribute and/or modify this document
- under the terms of the GNU Free Documentation License, Version 1.1
+ under the terms of the GNU Free Documentation License, Version 1.2
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
@@ -58,7 +58,7 @@ notice identical to this one except for the removal of this paragraph
Copyright @copyright{} 2001 Free Software Foundation, Inc.
Permission is granted to copy, distribute and/or modify this document
- under the terms of the GNU Free Documentation License, Version 1.1
+ under the terms of the GNU Free Documentation License, Version 1.2
or any later version published by the Free Software Foundation;
with no Invariant Sections, with no Front-Cover Texts, and with no
Back-Cover Texts. A copy of the license is included in the
diff --git a/contrib/binutils/libiberty/lrealpath.c b/contrib/binutils/libiberty/lrealpath.c
new file mode 100644
index 0000000..b001b38
--- /dev/null
+++ b/contrib/binutils/libiberty/lrealpath.c
@@ -0,0 +1,128 @@
+/* Libiberty realpath. Like realpath, but more consistent behavior.
+ Based on gdb_realpath from GDB.
+
+ Copyright 2003 Free Software Foundation, Inc.
+
+ This file is part of the libiberty library.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330,
+ Boston, MA 02111-1307, USA. */
+
+/*
+
+@deftypefn Replacement {const char*} lrealpath (const char *@var{name})
+
+Given a pointer to a string containing a pathname, returns a canonical
+version of the filename. Symlinks will be resolved, and ``.'' and ``..''
+components will be simplified. The returned value will be allocated using
+@code{malloc}, or @code{NULL} will be returned on a memory allocation error.
+
+@end deftypefn
+
+*/
+
+#include "config.h"
+#include "ansidecl.h"
+#include "libiberty.h"
+
+#ifdef HAVE_LIMITS_H
+#include <limits.h>
+#endif
+#ifdef HAVE_STDLIB_H
+#include <stdlib.h>
+#endif
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
+#ifdef HAVE_STRING_H
+#include <string.h>
+#endif
+
+/* On GNU libc systems the declaration is only visible with _GNU_SOURCE. */
+#if defined(HAVE_CANONICALIZE_FILE_NAME) \
+ && defined(NEED_DECLARATION_CANONICALIZE_FILE_NAME)
+extern char *canonicalize_file_name (const char *);
+#endif
+
+#if defined(HAVE_REALPATH)
+# if defined (PATH_MAX)
+# define REALPATH_LIMIT PATH_MAX
+# else
+# if defined (MAXPATHLEN)
+# define REALPATH_LIMIT MAXPATHLEN
+# endif
+# endif
+#endif
+
+char *
+lrealpath (filename)
+ const char *filename;
+{
+ /* Method 1: The system has a compile time upper bound on a filename
+ path. Use that and realpath() to canonicalize the name. This is
+ the most common case. Note that, if there isn't a compile time
+ upper bound, you want to avoid realpath() at all costs. */
+#if defined(REALPATH_LIMIT)
+ {
+ char buf[REALPATH_LIMIT];
+ const char *rp = realpath (filename, buf);
+ if (rp == NULL)
+ rp = filename;
+ return strdup (rp);
+ }
+#endif /* REALPATH_LIMIT */
+
+ /* Method 2: The host system (i.e., GNU) has the function
+ canonicalize_file_name() which malloc's a chunk of memory and
+ returns that, use that. */
+#if defined(HAVE_CANONICALIZE_FILE_NAME)
+ {
+ char *rp = canonicalize_file_name (filename);
+ if (rp == NULL)
+ return strdup (filename);
+ else
+ return rp;
+ }
+#endif
+
+ /* Method 3: Now we're getting desperate! The system doesn't have a
+ compile time buffer size and no alternative function. Query the
+ OS, using pathconf(), for the buffer limit. Care is needed
+ though, some systems do not limit PATH_MAX (return -1 for
+ pathconf()) making it impossible to pass a correctly sized buffer
+ to realpath() (it could always overflow). On those systems, we
+ skip this. */
+#if defined (HAVE_REALPATH) && defined (HAVE_UNISTD_H)
+ {
+ /* Find out the max path size. */
+ long path_max = pathconf ("/", _PC_PATH_MAX);
+ if (path_max > 0)
+ {
+ /* PATH_MAX is bounded. */
+ char *buf, *rp, *ret;
+ buf = malloc (path_max);
+ if (buf == NULL)
+ return NULL;
+ rp = realpath (filename, buf);
+ ret = strdup (rp ? rp : filename);
+ free (buf);
+ return ret;
+ }
+ }
+#endif
+
+ /* This system is a lost cause, just duplicate the filename. */
+ return strdup (filename);
+}
diff --git a/contrib/binutils/libiberty/maint-tool b/contrib/binutils/libiberty/maint-tool
index ceeb48d..bfc5304 100644
--- a/contrib/binutils/libiberty/maint-tool
+++ b/contrib/binutils/libiberty/maint-tool
@@ -213,6 +213,12 @@ sub locals_first {
sub deps {
+ $crule = "\tif [ x\"\$(PICFLAG)\" != x ]; then \\\n";
+ $crule .= "\t \$(COMPILE.c) \$(PICFLAG) \$< -o pic/\$@; \\\n";
+ $crule .= "\telse true; fi\n";
+ $crule .= "\t\$(COMPILE.c) \$< \$(OUTPUT_OPTION)\n";
+ $crule .= "\n";
+
$incdir = shift @ARGV;
opendir(INC, $incdir);
@@ -223,6 +229,14 @@ sub deps {
}
$mine{'config.h'} = "config.h";
+ opendir(INC, $srcdir);
+ while ($f = readdir INC) {
+ next unless $f =~ /\.h$/;
+ $mine{$f} = "\$(srcdir)/$f";
+ $deps{$f} = join(' ', &deps_for("$srcdir/$f"));
+ }
+ $mine{'config.h'} = "config.h";
+
open(IN, "$srcdir/Makefile.in");
open(OUT, ">$srcdir/Makefile.tmp");
while (<IN>) {
@@ -252,10 +266,10 @@ sub deps {
@deps = sort { &locals_first($a,$b) } keys %scanned;
$obj = $f;
$obj =~ s/\.c$/.o/;
- $obj = "$obj:";
+ $obj = "./$obj:";
if ($#deps >= 0) {
- print OUT $obj;
- $len = length($obj);
+ print OUT "$obj \$(srcdir)/$f";
+ $len = length("$obj $f");
for $dt (@deps) {
$d = $mine{$dt};
if ($len + length($d) > 70) {
@@ -267,7 +281,12 @@ sub deps {
}
}
print OUT "\n";
+ } else {
+ print OUT "$obj \$(srcdir)/$f\n";
}
+ $c = $crule;
+ $c =~ s@\$\<@\$\(srcdir\)\/$f@g;
+ print OUT $c;
}
}
closedir(S);
diff --git a/contrib/binutils/libiberty/make-relative-prefix.c b/contrib/binutils/libiberty/make-relative-prefix.c
new file mode 100644
index 0000000..dc4f8d5
--- /dev/null
+++ b/contrib/binutils/libiberty/make-relative-prefix.c
@@ -0,0 +1,396 @@
+/* Relative (relocatable) prefix support.
+ Copyright (C) 1987, 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
+ 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
+
+This file is part of libiberty.
+
+GCC is free software; you can redistribute it and/or modify it under
+the terms of the GNU General Public License as published by the Free
+Software Foundation; either version 2, or (at your option) any later
+version.
+
+GCC is distributed in the hope that it will be useful, but WITHOUT ANY
+WARRANTY; without even the implied warranty of MERCHANTABILITY or
+FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
+for more details.
+
+You should have received a copy of the GNU General Public License
+along with GCC; see the file COPYING. If not, write to the Free
+Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+02111-1307, USA. */
+
+/*
+
+@deftypefn Extension {const char*} make_relative_prefix (const char *@var{progname}, const char *@var{bin_prefix}, const char *@var{prefix})
+
+Given three paths @var{progname}, @var{bin_prefix}, @var{prefix},
+return the path that is in the same position relative to
+@var{progname}'s directory as @var{prefix} is relative to
+@var{bin_prefix}. That is, a string starting with the directory
+portion of @var{progname}, followed by a relative pathname of the
+difference between @var{bin_prefix} and @var{prefix}.
+
+If @var{progname} does not contain any directory separators,
+@code{make_relative_prefix} will search @env{PATH} to find a program
+named @var{progname}. Also, if @var{progname} is a symbolic link,
+the symbolic link will be resolved.
+
+For example, if @var{bin_prefix} is @code{/alpha/beta/gamma/gcc/delta},
+@var{prefix} is @code{/alpha/beta/gamma/omega/}, and @var{progname} is
+@code{/red/green/blue/gcc}, then this function will return
+@code{/red/green/blue/../../omega/}.
+
+The return value is normally allocated via @code{malloc}. If no
+relative prefix can be found, return @code{NULL}.
+
+@end deftypefn
+
+*/
+
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
+#ifdef HAVE_STDLIB_H
+#include <stdlib.h>
+#endif
+#ifdef HAVE_UNISTD_H
+#include <unistd.h>
+#endif
+
+#include <string.h>
+
+#include "ansidecl.h"
+#include "libiberty.h"
+
+#ifndef R_OK
+#define R_OK 4
+#define W_OK 2
+#define X_OK 1
+#endif
+
+#ifndef DIR_SEPARATOR
+# define DIR_SEPARATOR '/'
+#endif
+
+#if defined (_WIN32) || defined (__MSDOS__) \
+ || defined (__DJGPP__) || defined (__OS2__)
+# define HAVE_DOS_BASED_FILE_SYSTEM
+# define HAVE_HOST_EXECUTABLE_SUFFIX
+# define HOST_EXECUTABLE_SUFFIX ".exe"
+# ifndef DIR_SEPARATOR_2
+# define DIR_SEPARATOR_2 '\\'
+# endif
+# define PATH_SEPARATOR ';'
+#else
+# define PATH_SEPARATOR ':'
+#endif
+
+#ifndef DIR_SEPARATOR_2
+# define IS_DIR_SEPARATOR(ch) ((ch) == DIR_SEPARATOR)
+#else
+# define IS_DIR_SEPARATOR(ch) \
+ (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2))
+#endif
+
+#define DIR_UP ".."
+
+static char *save_string PARAMS ((const char *, int));
+static char **split_directories PARAMS ((const char *, int *));
+static void free_split_directories PARAMS ((char **));
+
+static char *
+save_string (s, len)
+ const char *s;
+ int len;
+{
+ char *result = malloc (len + 1);
+
+ memcpy (result, s, len);
+ result[len] = 0;
+ return result;
+}
+
+/* Split a filename into component directories. */
+
+static char **
+split_directories (name, ptr_num_dirs)
+ const char *name;
+ int *ptr_num_dirs;
+{
+ int num_dirs = 0;
+ char **dirs;
+ const char *p, *q;
+ int ch;
+
+ /* Count the number of directories. Special case MSDOS disk names as part
+ of the initial directory. */
+ p = name;
+#ifdef HAVE_DOS_BASED_FILE_SYSTEM
+ if (name[1] == ':' && IS_DIR_SEPARATOR (name[2]))
+ {
+ p += 3;
+ num_dirs++;
+ }
+#endif /* HAVE_DOS_BASED_FILE_SYSTEM */
+
+ while ((ch = *p++) != '\0')
+ {
+ if (IS_DIR_SEPARATOR (ch))
+ {
+ num_dirs++;
+ while (IS_DIR_SEPARATOR (*p))
+ p++;
+ }
+ }
+
+ dirs = (char **) malloc (sizeof (char *) * (num_dirs + 2));
+ if (dirs == NULL)
+ return NULL;
+
+ /* Now copy the directory parts. */
+ num_dirs = 0;
+ p = name;
+#ifdef HAVE_DOS_BASED_FILE_SYSTEM
+ if (name[1] == ':' && IS_DIR_SEPARATOR (name[2]))
+ {
+ dirs[num_dirs++] = save_string (p, 3);
+ if (dirs[num_dirs - 1] == NULL)
+ {
+ free (dirs);
+ return NULL;
+ }
+ p += 3;
+ }
+#endif /* HAVE_DOS_BASED_FILE_SYSTEM */
+
+ q = p;
+ while ((ch = *p++) != '\0')
+ {
+ if (IS_DIR_SEPARATOR (ch))
+ {
+ while (IS_DIR_SEPARATOR (*p))
+ p++;
+
+ dirs[num_dirs++] = save_string (q, p - q);
+ if (dirs[num_dirs - 1] == NULL)
+ {
+ dirs[num_dirs] = NULL;
+ free_split_directories (dirs);
+ return NULL;
+ }
+ q = p;
+ }
+ }
+
+ if (p - 1 - q > 0)
+ dirs[num_dirs++] = save_string (q, p - 1 - q);
+ dirs[num_dirs] = NULL;
+
+ if (dirs[num_dirs - 1] == NULL)
+ {
+ free_split_directories (dirs);
+ return NULL;
+ }
+
+ if (ptr_num_dirs)
+ *ptr_num_dirs = num_dirs;
+ return dirs;
+}
+
+/* Release storage held by split directories. */
+
+static void
+free_split_directories (dirs)
+ char **dirs;
+{
+ int i = 0;
+
+ while (dirs[i] != NULL)
+ free (dirs[i++]);
+
+ free ((char *) dirs);
+}
+
+/* Given three strings PROGNAME, BIN_PREFIX, PREFIX, return a string that gets
+ to PREFIX starting with the directory portion of PROGNAME and a relative
+ pathname of the difference between BIN_PREFIX and PREFIX.
+
+ For example, if BIN_PREFIX is /alpha/beta/gamma/gcc/delta, PREFIX is
+ /alpha/beta/gamma/omega/, and PROGNAME is /red/green/blue/gcc, then this
+ function will return /red/green/blue/../../omega/.
+
+ If no relative prefix can be found, return NULL. */
+
+char *
+make_relative_prefix (progname, bin_prefix, prefix)
+ const char *progname;
+ const char *bin_prefix;
+ const char *prefix;
+{
+ char **prog_dirs, **bin_dirs, **prefix_dirs;
+ int prog_num, bin_num, prefix_num;
+ int i, n, common;
+ int needed_len;
+ char *ret, *ptr, *full_progname = NULL;
+
+ if (progname == NULL || bin_prefix == NULL || prefix == NULL)
+ return NULL;
+
+ /* If there is no full pathname, try to find the program by checking in each
+ of the directories specified in the PATH environment variable. */
+ if (lbasename (progname) == progname)
+ {
+ char *temp;
+
+ temp = getenv ("PATH");
+ if (temp)
+ {
+ char *startp, *endp, *nstore;
+ size_t prefixlen = strlen (temp) + 1;
+ if (prefixlen < 2)
+ prefixlen = 2;
+
+ nstore = (char *) alloca (prefixlen + strlen (progname) + 1);
+
+ startp = endp = temp;
+ while (1)
+ {
+ if (*endp == PATH_SEPARATOR || *endp == 0)
+ {
+ if (endp == startp)
+ {
+ nstore[0] = '.';
+ nstore[1] = DIR_SEPARATOR;
+ nstore[2] = '\0';
+ }
+ else
+ {
+ strncpy (nstore, startp, endp - startp);
+ if (! IS_DIR_SEPARATOR (endp[-1]))
+ {
+ nstore[endp - startp] = DIR_SEPARATOR;
+ nstore[endp - startp + 1] = 0;
+ }
+ else
+ nstore[endp - startp] = 0;
+ }
+ strcat (nstore, progname);
+ if (! access (nstore, X_OK)
+#ifdef HAVE_HOST_EXECUTABLE_SUFFIX
+ || ! access (strcat (nstore, HOST_EXECUTABLE_SUFFIX), X_OK)
+#endif
+ )
+ {
+ progname = nstore;
+ break;
+ }
+
+ if (*endp == 0)
+ break;
+ endp = startp = endp + 1;
+ }
+ else
+ endp++;
+ }
+ }
+ }
+
+ full_progname = lrealpath (progname);
+ if (full_progname == NULL)
+ return NULL;
+
+ prog_dirs = split_directories (full_progname, &prog_num);
+ bin_dirs = split_directories (bin_prefix, &bin_num);
+ free (full_progname);
+ if (bin_dirs == NULL || prog_dirs == NULL)
+ return NULL;
+
+ /* Remove the program name from comparison of directory names. */
+ prog_num--;
+
+ /* If we are still installed in the standard location, we don't need to
+ specify relative directories. Also, if argv[0] still doesn't contain
+ any directory specifiers after the search above, then there is not much
+ we can do. */
+ if (prog_num == bin_num)
+ {
+ for (i = 0; i < bin_num; i++)
+ {
+ if (strcmp (prog_dirs[i], bin_dirs[i]) != 0)
+ break;
+ }
+
+ if (prog_num <= 0 || i == bin_num)
+ {
+ free_split_directories (prog_dirs);
+ free_split_directories (bin_dirs);
+ prog_dirs = bin_dirs = (char **) 0;
+ return NULL;
+ }
+ }
+
+ prefix_dirs = split_directories (prefix, &prefix_num);
+ if (prefix_dirs == NULL)
+ {
+ free_split_directories (prog_dirs);
+ free_split_directories (bin_dirs);
+ return NULL;
+ }
+
+ /* Find how many directories are in common between bin_prefix & prefix. */
+ n = (prefix_num < bin_num) ? prefix_num : bin_num;
+ for (common = 0; common < n; common++)
+ {
+ if (strcmp (bin_dirs[common], prefix_dirs[common]) != 0)
+ break;
+ }
+
+ /* If there are no common directories, there can be no relative prefix. */
+ if (common == 0)
+ {
+ free_split_directories (prog_dirs);
+ free_split_directories (bin_dirs);
+ free_split_directories (prefix_dirs);
+ return NULL;
+ }
+
+ /* Two passes: first figure out the size of the result string, and
+ then construct it. */
+ needed_len = 0;
+ for (i = 0; i < prog_num; i++)
+ needed_len += strlen (prog_dirs[i]);
+ needed_len += sizeof (DIR_UP) * (bin_num - common);
+ for (i = common; i < prefix_num; i++)
+ needed_len += strlen (prefix_dirs[i]);
+ needed_len += 1; /* Trailing NUL. */
+
+ ret = (char *) malloc (needed_len);
+ if (ret == NULL)
+ return NULL;
+
+ /* Build up the pathnames in argv[0]. */
+ *ret = '\0';
+ for (i = 0; i < prog_num; i++)
+ strcat (ret, prog_dirs[i]);
+
+ /* Now build up the ..'s. */
+ ptr = ret + strlen(ret);
+ for (i = common; i < bin_num; i++)
+ {
+ strcpy (ptr, DIR_UP);
+ ptr += sizeof (DIR_UP) - 1;
+ *(ptr++) = DIR_SEPARATOR;
+ }
+ *ptr = '\0';
+
+ /* Put in directories to move over to prefix. */
+ for (i = common; i < prefix_num; i++)
+ strcat (ret, prefix_dirs[i]);
+
+ free_split_directories (prog_dirs);
+ free_split_directories (bin_dirs);
+ free_split_directories (prefix_dirs);
+
+ return ret;
+}
diff --git a/contrib/binutils/libiberty/md5.c b/contrib/binutils/libiberty/md5.c
index 9450586..e458f2a 100644
--- a/contrib/binutils/libiberty/md5.c
+++ b/contrib/binutils/libiberty/md5.c
@@ -229,7 +229,7 @@ md5_process_bytes (buffer, len, ctx)
ctx->buflen = (left_over + add) & 63;
}
- buffer = (const char *) buffer + add;
+ buffer = (const void *) ((const char *) buffer + add);
len -= add;
}
@@ -237,7 +237,7 @@ md5_process_bytes (buffer, len, ctx)
if (len > 64)
{
md5_process_block (buffer, len & ~63, ctx);
- buffer = (const char *) buffer + (len & ~63);
+ buffer = (const void *) ((const char *) buffer + (len & ~63));
len &= 63;
}
@@ -269,7 +269,7 @@ md5_process_block (buffer, len, ctx)
struct md5_ctx *ctx;
{
md5_uint32 correct_words[16];
- const md5_uint32 *words = buffer;
+ const md5_uint32 *words = (const md5_uint32 *) buffer;
size_t nwords = len / sizeof (md5_uint32);
const md5_uint32 *endp = words + nwords;
md5_uint32 A = ctx->A;
@@ -343,68 +343,76 @@ md5_process_block (buffer, len, ctx)
in CORRECT_WORDS. Redefine the macro to take an additional first
argument specifying the function to use. */
#undef OP
-#define OP(f, a, b, c, d, k, s, T) \
+#define OP(a, b, c, d, k, s, T) \
do \
{ \
- a += f (b, c, d) + correct_words[k] + T; \
+ a += FX (b, c, d) + correct_words[k] + T; \
CYCLIC (a, s); \
a += b; \
} \
while (0)
+#define FX(b, c, d) FG (b, c, d)
+
/* Round 2. */
- OP (FG, A, B, C, D, 1, 5, (md5_uint32) 0xf61e2562);
- OP (FG, D, A, B, C, 6, 9, (md5_uint32) 0xc040b340);
- OP (FG, C, D, A, B, 11, 14, (md5_uint32) 0x265e5a51);
- OP (FG, B, C, D, A, 0, 20, (md5_uint32) 0xe9b6c7aa);
- OP (FG, A, B, C, D, 5, 5, (md5_uint32) 0xd62f105d);
- OP (FG, D, A, B, C, 10, 9, (md5_uint32) 0x02441453);
- OP (FG, C, D, A, B, 15, 14, (md5_uint32) 0xd8a1e681);
- OP (FG, B, C, D, A, 4, 20, (md5_uint32) 0xe7d3fbc8);
- OP (FG, A, B, C, D, 9, 5, (md5_uint32) 0x21e1cde6);
- OP (FG, D, A, B, C, 14, 9, (md5_uint32) 0xc33707d6);
- OP (FG, C, D, A, B, 3, 14, (md5_uint32) 0xf4d50d87);
- OP (FG, B, C, D, A, 8, 20, (md5_uint32) 0x455a14ed);
- OP (FG, A, B, C, D, 13, 5, (md5_uint32) 0xa9e3e905);
- OP (FG, D, A, B, C, 2, 9, (md5_uint32) 0xfcefa3f8);
- OP (FG, C, D, A, B, 7, 14, (md5_uint32) 0x676f02d9);
- OP (FG, B, C, D, A, 12, 20, (md5_uint32) 0x8d2a4c8a);
+ OP (A, B, C, D, 1, 5, (md5_uint32) 0xf61e2562);
+ OP (D, A, B, C, 6, 9, (md5_uint32) 0xc040b340);
+ OP (C, D, A, B, 11, 14, (md5_uint32) 0x265e5a51);
+ OP (B, C, D, A, 0, 20, (md5_uint32) 0xe9b6c7aa);
+ OP (A, B, C, D, 5, 5, (md5_uint32) 0xd62f105d);
+ OP (D, A, B, C, 10, 9, (md5_uint32) 0x02441453);
+ OP (C, D, A, B, 15, 14, (md5_uint32) 0xd8a1e681);
+ OP (B, C, D, A, 4, 20, (md5_uint32) 0xe7d3fbc8);
+ OP (A, B, C, D, 9, 5, (md5_uint32) 0x21e1cde6);
+ OP (D, A, B, C, 14, 9, (md5_uint32) 0xc33707d6);
+ OP (C, D, A, B, 3, 14, (md5_uint32) 0xf4d50d87);
+ OP (B, C, D, A, 8, 20, (md5_uint32) 0x455a14ed);
+ OP (A, B, C, D, 13, 5, (md5_uint32) 0xa9e3e905);
+ OP (D, A, B, C, 2, 9, (md5_uint32) 0xfcefa3f8);
+ OP (C, D, A, B, 7, 14, (md5_uint32) 0x676f02d9);
+ OP (B, C, D, A, 12, 20, (md5_uint32) 0x8d2a4c8a);
+
+#undef FX
+#define FX(b, c, d) FH (b, c, d)
/* Round 3. */
- OP (FH, A, B, C, D, 5, 4, (md5_uint32) 0xfffa3942);
- OP (FH, D, A, B, C, 8, 11, (md5_uint32) 0x8771f681);
- OP (FH, C, D, A, B, 11, 16, (md5_uint32) 0x6d9d6122);
- OP (FH, B, C, D, A, 14, 23, (md5_uint32) 0xfde5380c);
- OP (FH, A, B, C, D, 1, 4, (md5_uint32) 0xa4beea44);
- OP (FH, D, A, B, C, 4, 11, (md5_uint32) 0x4bdecfa9);
- OP (FH, C, D, A, B, 7, 16, (md5_uint32) 0xf6bb4b60);
- OP (FH, B, C, D, A, 10, 23, (md5_uint32) 0xbebfbc70);
- OP (FH, A, B, C, D, 13, 4, (md5_uint32) 0x289b7ec6);
- OP (FH, D, A, B, C, 0, 11, (md5_uint32) 0xeaa127fa);
- OP (FH, C, D, A, B, 3, 16, (md5_uint32) 0xd4ef3085);
- OP (FH, B, C, D, A, 6, 23, (md5_uint32) 0x04881d05);
- OP (FH, A, B, C, D, 9, 4, (md5_uint32) 0xd9d4d039);
- OP (FH, D, A, B, C, 12, 11, (md5_uint32) 0xe6db99e5);
- OP (FH, C, D, A, B, 15, 16, (md5_uint32) 0x1fa27cf8);
- OP (FH, B, C, D, A, 2, 23, (md5_uint32) 0xc4ac5665);
+ OP (A, B, C, D, 5, 4, (md5_uint32) 0xfffa3942);
+ OP (D, A, B, C, 8, 11, (md5_uint32) 0x8771f681);
+ OP (C, D, A, B, 11, 16, (md5_uint32) 0x6d9d6122);
+ OP (B, C, D, A, 14, 23, (md5_uint32) 0xfde5380c);
+ OP (A, B, C, D, 1, 4, (md5_uint32) 0xa4beea44);
+ OP (D, A, B, C, 4, 11, (md5_uint32) 0x4bdecfa9);
+ OP (C, D, A, B, 7, 16, (md5_uint32) 0xf6bb4b60);
+ OP (B, C, D, A, 10, 23, (md5_uint32) 0xbebfbc70);
+ OP (A, B, C, D, 13, 4, (md5_uint32) 0x289b7ec6);
+ OP (D, A, B, C, 0, 11, (md5_uint32) 0xeaa127fa);
+ OP (C, D, A, B, 3, 16, (md5_uint32) 0xd4ef3085);
+ OP (B, C, D, A, 6, 23, (md5_uint32) 0x04881d05);
+ OP (A, B, C, D, 9, 4, (md5_uint32) 0xd9d4d039);
+ OP (D, A, B, C, 12, 11, (md5_uint32) 0xe6db99e5);
+ OP (C, D, A, B, 15, 16, (md5_uint32) 0x1fa27cf8);
+ OP (B, C, D, A, 2, 23, (md5_uint32) 0xc4ac5665);
+
+#undef FX
+#define FX(b, c, d) FI (b, c, d)
/* Round 4. */
- OP (FI, A, B, C, D, 0, 6, (md5_uint32) 0xf4292244);
- OP (FI, D, A, B, C, 7, 10, (md5_uint32) 0x432aff97);
- OP (FI, C, D, A, B, 14, 15, (md5_uint32) 0xab9423a7);
- OP (FI, B, C, D, A, 5, 21, (md5_uint32) 0xfc93a039);
- OP (FI, A, B, C, D, 12, 6, (md5_uint32) 0x655b59c3);
- OP (FI, D, A, B, C, 3, 10, (md5_uint32) 0x8f0ccc92);
- OP (FI, C, D, A, B, 10, 15, (md5_uint32) 0xffeff47d);
- OP (FI, B, C, D, A, 1, 21, (md5_uint32) 0x85845dd1);
- OP (FI, A, B, C, D, 8, 6, (md5_uint32) 0x6fa87e4f);
- OP (FI, D, A, B, C, 15, 10, (md5_uint32) 0xfe2ce6e0);
- OP (FI, C, D, A, B, 6, 15, (md5_uint32) 0xa3014314);
- OP (FI, B, C, D, A, 13, 21, (md5_uint32) 0x4e0811a1);
- OP (FI, A, B, C, D, 4, 6, (md5_uint32) 0xf7537e82);
- OP (FI, D, A, B, C, 11, 10, (md5_uint32) 0xbd3af235);
- OP (FI, C, D, A, B, 2, 15, (md5_uint32) 0x2ad7d2bb);
- OP (FI, B, C, D, A, 9, 21, (md5_uint32) 0xeb86d391);
+ OP (A, B, C, D, 0, 6, (md5_uint32) 0xf4292244);
+ OP (D, A, B, C, 7, 10, (md5_uint32) 0x432aff97);
+ OP (C, D, A, B, 14, 15, (md5_uint32) 0xab9423a7);
+ OP (B, C, D, A, 5, 21, (md5_uint32) 0xfc93a039);
+ OP (A, B, C, D, 12, 6, (md5_uint32) 0x655b59c3);
+ OP (D, A, B, C, 3, 10, (md5_uint32) 0x8f0ccc92);
+ OP (C, D, A, B, 10, 15, (md5_uint32) 0xffeff47d);
+ OP (B, C, D, A, 1, 21, (md5_uint32) 0x85845dd1);
+ OP (A, B, C, D, 8, 6, (md5_uint32) 0x6fa87e4f);
+ OP (D, A, B, C, 15, 10, (md5_uint32) 0xfe2ce6e0);
+ OP (C, D, A, B, 6, 15, (md5_uint32) 0xa3014314);
+ OP (B, C, D, A, 13, 21, (md5_uint32) 0x4e0811a1);
+ OP (A, B, C, D, 4, 6, (md5_uint32) 0xf7537e82);
+ OP (D, A, B, C, 11, 10, (md5_uint32) 0xbd3af235);
+ OP (C, D, A, B, 2, 15, (md5_uint32) 0x2ad7d2bb);
+ OP (B, C, D, A, 9, 21, (md5_uint32) 0xeb86d391);
/* Add the starting values of the context. */
A += A_save;
diff --git a/contrib/binutils/libiberty/memchr.c b/contrib/binutils/libiberty/memchr.c
index f94bea0..3948125 100644
--- a/contrib/binutils/libiberty/memchr.c
+++ b/contrib/binutils/libiberty/memchr.c
@@ -15,7 +15,7 @@ returned.
*/
#include <ansidecl.h>
-#ifdef __STDC__
+#ifdef ANSI_PROTOTYPES
#include <stddef.h>
#else
#define size_t unsigned long
diff --git a/contrib/binutils/libiberty/memcmp.c b/contrib/binutils/libiberty/memcmp.c
index d8d3997..92f2b6e 100644
--- a/contrib/binutils/libiberty/memcmp.c
+++ b/contrib/binutils/libiberty/memcmp.c
@@ -16,15 +16,17 @@ as if comparing unsigned char arrays.
*/
#include <ansidecl.h>
-#ifdef __STDC__
+#ifdef ANSI_PROTOTYPES
#include <stddef.h>
#else
#define size_t unsigned long
#endif
int
-DEFUN(memcmp, (str1, str2, count),
- const PTR str1 AND const PTR str2 AND size_t count)
+memcmp (str1, str2, count)
+ const PTR str1;
+ const PTR str2;
+ size_t count;
{
register const unsigned char *s1 = (const unsigned char*)str1;
register const unsigned char *s2 = (const unsigned char*)str2;
diff --git a/contrib/binutils/libiberty/memcpy.c b/contrib/binutils/libiberty/memcpy.c
index 0f2bac7..5eece7a 100644
--- a/contrib/binutils/libiberty/memcpy.c
+++ b/contrib/binutils/libiberty/memcpy.c
@@ -13,14 +13,19 @@ Copies @var{length} bytes from memory region @var{in} to region
*/
#include <ansidecl.h>
-#ifdef __STDC__
+#ifdef ANSI_PROTOTYPES
#include <stddef.h>
#else
#define size_t unsigned long
#endif
+void bcopy PARAMS((const void*, void*, size_t));
+
PTR
-DEFUN(memcpy, (out, in, length), PTR out AND const PTR in AND size_t length)
+memcpy (out, in, length)
+ PTR out;
+ const PTR in;
+ size_t length;
{
bcopy(in, out, length);
return out;
diff --git a/contrib/binutils/libiberty/memmove.c b/contrib/binutils/libiberty/memmove.c
index 3ec7320..00ac053 100644
--- a/contrib/binutils/libiberty/memmove.c
+++ b/contrib/binutils/libiberty/memmove.c
@@ -13,12 +13,14 @@ Copies @var{count} bytes from memory area @var{from} to memory area
*/
#include <ansidecl.h>
-#ifdef __STDC__
+#ifdef ANSI_PROTOTYPES
#include <stddef.h>
#else
#define size_t unsigned long
#endif
+void bcopy PARAMS ((const void*, void*, size_t));
+
PTR
memmove (s1, s2, n)
PTR s1;
diff --git a/contrib/binutils/libiberty/memset.c b/contrib/binutils/libiberty/memset.c
index 489ca17..5119f85 100644
--- a/contrib/binutils/libiberty/memset.c
+++ b/contrib/binutils/libiberty/memset.c
@@ -13,15 +13,17 @@ Sets the first @var{count} bytes of @var{s} to the constant byte
*/
#include <ansidecl.h>
-#ifdef __STDC__
+#ifdef ANSI_PROTOTYPES
#include <stddef.h>
#else
#define size_t unsigned long
#endif
PTR
-DEFUN(memset, (dest, val, len),
- PTR dest AND register int val AND register size_t len)
+memset (dest, val, len)
+ PTR dest;
+ register int val;
+ register size_t len;
{
register unsigned char *ptr = (unsigned char*)dest;
while (len-- > 0)
diff --git a/contrib/binutils/libiberty/physmem.c b/contrib/binutils/libiberty/physmem.c
new file mode 100644
index 0000000..f64e07c
--- /dev/null
+++ b/contrib/binutils/libiberty/physmem.c
@@ -0,0 +1,305 @@
+/* Calculate the size of physical memory.
+ Copyright 2000, 2001, 2003 Free Software Foundation, Inc.
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software Foundation,
+ Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+/* Written by Paul Eggert. */
+
+#if HAVE_CONFIG_H
+# include <config.h>
+#endif
+
+#if HAVE_UNISTD_H
+# include <unistd.h>
+#endif
+
+#if HAVE_SYS_PSTAT_H
+# include <sys/pstat.h>
+#endif
+
+#if HAVE_SYS_SYSMP_H
+# include <sys/sysmp.h>
+#endif
+
+#if HAVE_SYS_SYSINFO_H && HAVE_MACHINE_HAL_SYSINFO_H
+# include <sys/sysinfo.h>
+# include <machine/hal_sysinfo.h>
+#endif
+
+#if HAVE_SYS_TABLE_H
+# include <sys/table.h>
+#endif
+
+#include <sys/types.h>
+
+#if HAVE_SYS_PARAM_H
+# include <sys/param.h>
+#endif
+
+#if HAVE_SYS_SYSCTL_H
+# include <sys/sysctl.h>
+#endif
+
+#if HAVE_SYS_SYSTEMCFG_H
+# include <sys/systemcfg.h>
+#endif
+
+#ifdef _WIN32
+# define WIN32_LEAN_AND_MEAN
+# include <windows.h>
+/* MEMORYSTATUSEX is missing from older windows headers, so define
+ a local replacement. */
+typedef struct
+{
+ DWORD dwLength;
+ DWORD dwMemoryLoad;
+ DWORDLONG ullTotalPhys;
+ DWORDLONG ullAvailPhys;
+ DWORDLONG ullTotalPageFile;
+ DWORDLONG ullAvailPageFile;
+ DWORDLONG ullTotalVirtual;
+ DWORDLONG ullAvailVirtual;
+ DWORDLONG ullAvailExtendedVirtual;
+} lMEMORYSTATUSEX;
+typedef WINBOOL (WINAPI *PFN_MS_EX) (lMEMORYSTATUSEX*);
+#endif
+
+#include "libiberty.h"
+
+/* Return the total amount of physical memory. */
+double
+physmem_total ()
+{
+#if defined _SC_PHYS_PAGES && defined _SC_PAGESIZE
+ { /* This works on linux-gnu, solaris2 and cygwin. */
+ double pages = sysconf (_SC_PHYS_PAGES);
+ double pagesize = sysconf (_SC_PAGESIZE);
+ if (0 <= pages && 0 <= pagesize)
+ return pages * pagesize;
+ }
+#endif
+
+#if HAVE_PSTAT_GETSTATIC
+ { /* This works on hpux11. */
+ struct pst_static pss;
+ if (0 <= pstat_getstatic (&pss, sizeof pss, 1, 0))
+ {
+ double pages = pss.physical_memory;
+ double pagesize = pss.page_size;
+ if (0 <= pages && 0 <= pagesize)
+ return pages * pagesize;
+ }
+ }
+#endif
+
+#if HAVE_SYSMP && defined MP_SAGET && defined MPSA_RMINFO && defined _SC_PAGESIZE
+ { /* This works on irix6. */
+ struct rminfo realmem;
+ if (sysmp (MP_SAGET, MPSA_RMINFO, &realmem, sizeof realmem) == 0)
+ {
+ double pagesize = sysconf (_SC_PAGESIZE);
+ double pages = realmem.physmem;
+ if (0 <= pages && 0 <= pagesize)
+ return pages * pagesize;
+ }
+ }
+#endif
+
+#if HAVE_GETSYSINFO && defined GSI_PHYSMEM
+ { /* This works on Tru64 UNIX V4/5. */
+ int physmem;
+
+ if (getsysinfo (GSI_PHYSMEM, (caddr_t) &physmem, sizeof (physmem),
+ NULL, NULL, NULL) == 1)
+ {
+ double kbytes = physmem;
+
+ if (0 <= kbytes)
+ return kbytes * 1024.0;
+ }
+ }
+#endif
+
+#if HAVE_SYSCTL && defined HW_PHYSMEM
+ { /* This works on *bsd and darwin. */
+ unsigned int physmem;
+ size_t len = sizeof physmem;
+ static int mib[2] = { CTL_HW, HW_PHYSMEM };
+
+ if (sysctl (mib, ARRAY_SIZE (mib), &physmem, &len, NULL, 0) == 0
+ && len == sizeof (physmem))
+ return (double) physmem;
+ }
+#endif
+
+#if HAVE__SYSTEM_CONFIGURATION
+ /* This works on AIX 4.3.3+. */
+ return _system_configuration.physmem;
+#endif
+
+#if defined _WIN32
+ { /* this works on windows */
+ PFN_MS_EX pfnex;
+ HMODULE h = GetModuleHandle ("kernel32.dll");
+
+ if (!h)
+ return 0.0;
+
+ /* Use GlobalMemoryStatusEx if available. */
+ if ((pfnex = (PFN_MS_EX) GetProcAddress (h, "GlobalMemoryStatusEx")))
+ {
+ lMEMORYSTATUSEX lms_ex;
+ lms_ex.dwLength = sizeof lms_ex;
+ if (!pfnex (&lms_ex))
+ return 0.0;
+ return (double) lms_ex.ullTotalPhys;
+ }
+
+ /* Fall back to GlobalMemoryStatus which is always available.
+ but returns wrong results for physical memory > 4GB. */
+ else
+ {
+ MEMORYSTATUS ms;
+ GlobalMemoryStatus (&ms);
+ return (double) ms.dwTotalPhys;
+ }
+ }
+#endif
+
+ /* Return 0 if we can't determine the value. */
+ return 0;
+}
+
+/* Return the amount of physical memory available. */
+double
+physmem_available ()
+{
+#if defined _SC_AVPHYS_PAGES && defined _SC_PAGESIZE
+ { /* This works on linux-gnu, solaris2 and cygwin. */
+ double pages = sysconf (_SC_AVPHYS_PAGES);
+ double pagesize = sysconf (_SC_PAGESIZE);
+ if (0 <= pages && 0 <= pagesize)
+ return pages * pagesize;
+ }
+#endif
+
+#if HAVE_PSTAT_GETSTATIC && HAVE_PSTAT_GETDYNAMIC
+ { /* This works on hpux11. */
+ struct pst_static pss;
+ struct pst_dynamic psd;
+ if (0 <= pstat_getstatic (&pss, sizeof pss, 1, 0)
+ && 0 <= pstat_getdynamic (&psd, sizeof psd, 1, 0))
+ {
+ double pages = psd.psd_free;
+ double pagesize = pss.page_size;
+ if (0 <= pages && 0 <= pagesize)
+ return pages * pagesize;
+ }
+ }
+#endif
+
+#if HAVE_SYSMP && defined MP_SAGET && defined MPSA_RMINFO && defined _SC_PAGESIZE
+ { /* This works on irix6. */
+ struct rminfo realmem;
+ if (sysmp (MP_SAGET, MPSA_RMINFO, &realmem, sizeof realmem) == 0)
+ {
+ double pagesize = sysconf (_SC_PAGESIZE);
+ double pages = realmem.availrmem;
+ if (0 <= pages && 0 <= pagesize)
+ return pages * pagesize;
+ }
+ }
+#endif
+
+#if HAVE_TABLE && defined TBL_VMSTATS
+ { /* This works on Tru64 UNIX V4/5. */
+ struct tbl_vmstats vmstats;
+
+ if (table (TBL_VMSTATS, 0, &vmstats, 1, sizeof (vmstats)) == 1)
+ {
+ double pages = vmstats.free_count;
+ double pagesize = vmstats.pagesize;
+
+ if (0 <= pages && 0 <= pagesize)
+ return pages * pagesize;
+ }
+ }
+#endif
+
+#if HAVE_SYSCTL && defined HW_USERMEM
+ { /* This works on *bsd and darwin. */
+ unsigned int usermem;
+ size_t len = sizeof usermem;
+ static int mib[2] = { CTL_HW, HW_USERMEM };
+
+ if (sysctl (mib, ARRAY_SIZE (mib), &usermem, &len, NULL, 0) == 0
+ && len == sizeof (usermem))
+ return (double) usermem;
+ }
+#endif
+
+#if defined _WIN32
+ { /* this works on windows */
+ PFN_MS_EX pfnex;
+ HMODULE h = GetModuleHandle ("kernel32.dll");
+
+ if (!h)
+ return 0.0;
+
+ /* Use GlobalMemoryStatusEx if available. */
+ if ((pfnex = (PFN_MS_EX) GetProcAddress (h, "GlobalMemoryStatusEx")))
+ {
+ lMEMORYSTATUSEX lms_ex;
+ lms_ex.dwLength = sizeof lms_ex;
+ if (!pfnex (&lms_ex))
+ return 0.0;
+ return (double) lms_ex.ullAvailPhys;
+ }
+
+ /* Fall back to GlobalMemoryStatus which is always available.
+ but returns wrong results for physical memory > 4GB */
+ else
+ {
+ MEMORYSTATUS ms;
+ GlobalMemoryStatus (&ms);
+ return (double) ms.dwAvailPhys;
+ }
+ }
+#endif
+
+ /* Guess 25% of physical memory. */
+ return physmem_total () / 4;
+}
+
+
+#if DEBUG
+
+# include <stdio.h>
+# include <stdlib.h>
+
+int
+main ()
+{
+ printf ("%12.f %12.f\n", physmem_total (), physmem_available ());
+ exit (0);
+}
+
+#endif /* DEBUG */
+
+/*
+Local Variables:
+compile-command: "gcc -DDEBUG -DHAVE_CONFIG_H -I.. -g -O -Wall -W physmem.c"
+End:
+*/
diff --git a/contrib/binutils/libiberty/regex.c b/contrib/binutils/libiberty/regex.c
index a64cd562..522b0ee 100644
--- a/contrib/binutils/libiberty/regex.c
+++ b/contrib/binutils/libiberty/regex.c
@@ -2,7 +2,7 @@
version 0.12.
(Implements POSIX draft P1003.2/D11.2, except for some of the
internationalization features.)
- Copyright (C) 1993-1999, 2000, 2001 Free Software Foundation, Inc.
+ Copyright (C) 1993-1999, 2000, 2001, 2002 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
@@ -25,7 +25,7 @@
routines with an "x" prefix so they do not collide with the native regex
routines or with other components regex routines. */
/* AIX requires this to be the first thing in the file. */
-#if defined _AIX && !defined REGEX_MALLOC
+#if defined _AIX && !defined __GNUC__ && !defined REGEX_MALLOC
#pragma alloca
#endif
@@ -36,6 +36,8 @@
# include <config.h>
#endif
+#include <ansidecl.h>
+
#ifndef PARAMS
# if defined __GNUC__ || (defined __STDC__ && __STDC__)
# define PARAMS(args) args
@@ -1373,80 +1375,26 @@ weak_alias (__re_set_syntax, re_set_syntax)
POSIX doesn't require that we do anything for REG_NOERROR,
but why not be nice? */
-static const char re_error_msgid[] =
+static const char *re_error_msgid[] =
{
-# define REG_NOERROR_IDX 0
- gettext_noop ("Success") /* REG_NOERROR */
- "\0"
-# define REG_NOMATCH_IDX (REG_NOERROR_IDX + sizeof "Success")
- gettext_noop ("No match") /* REG_NOMATCH */
- "\0"
-# define REG_BADPAT_IDX (REG_NOMATCH_IDX + sizeof "No match")
- gettext_noop ("Invalid regular expression") /* REG_BADPAT */
- "\0"
-# define REG_ECOLLATE_IDX (REG_BADPAT_IDX + sizeof "Invalid regular expression")
- gettext_noop ("Invalid collation character") /* REG_ECOLLATE */
- "\0"
-# define REG_ECTYPE_IDX (REG_ECOLLATE_IDX + sizeof "Invalid collation character")
- gettext_noop ("Invalid character class name") /* REG_ECTYPE */
- "\0"
-# define REG_EESCAPE_IDX (REG_ECTYPE_IDX + sizeof "Invalid character class name")
- gettext_noop ("Trailing backslash") /* REG_EESCAPE */
- "\0"
-# define REG_ESUBREG_IDX (REG_EESCAPE_IDX + sizeof "Trailing backslash")
- gettext_noop ("Invalid back reference") /* REG_ESUBREG */
- "\0"
-# define REG_EBRACK_IDX (REG_ESUBREG_IDX + sizeof "Invalid back reference")
- gettext_noop ("Unmatched [ or [^") /* REG_EBRACK */
- "\0"
-# define REG_EPAREN_IDX (REG_EBRACK_IDX + sizeof "Unmatched [ or [^")
- gettext_noop ("Unmatched ( or \\(") /* REG_EPAREN */
- "\0"
-# define REG_EBRACE_IDX (REG_EPAREN_IDX + sizeof "Unmatched ( or \\(")
- gettext_noop ("Unmatched \\{") /* REG_EBRACE */
- "\0"
-# define REG_BADBR_IDX (REG_EBRACE_IDX + sizeof "Unmatched \\{")
- gettext_noop ("Invalid content of \\{\\}") /* REG_BADBR */
- "\0"
-# define REG_ERANGE_IDX (REG_BADBR_IDX + sizeof "Invalid content of \\{\\}")
- gettext_noop ("Invalid range end") /* REG_ERANGE */
- "\0"
-# define REG_ESPACE_IDX (REG_ERANGE_IDX + sizeof "Invalid range end")
- gettext_noop ("Memory exhausted") /* REG_ESPACE */
- "\0"
-# define REG_BADRPT_IDX (REG_ESPACE_IDX + sizeof "Memory exhausted")
- gettext_noop ("Invalid preceding regular expression") /* REG_BADRPT */
- "\0"
-# define REG_EEND_IDX (REG_BADRPT_IDX + sizeof "Invalid preceding regular expression")
- gettext_noop ("Premature end of regular expression") /* REG_EEND */
- "\0"
-# define REG_ESIZE_IDX (REG_EEND_IDX + sizeof "Premature end of regular expression")
- gettext_noop ("Regular expression too big") /* REG_ESIZE */
- "\0"
-# define REG_ERPAREN_IDX (REG_ESIZE_IDX + sizeof "Regular expression too big")
+ gettext_noop ("Success"), /* REG_NOERROR */
+ gettext_noop ("No match"), /* REG_NOMATCH */
+ gettext_noop ("Invalid regular expression"), /* REG_BADPAT */
+ gettext_noop ("Invalid collation character"), /* REG_ECOLLATE */
+ gettext_noop ("Invalid character class name"), /* REG_ECTYPE */
+ gettext_noop ("Trailing backslash"), /* REG_EESCAPE */
+ gettext_noop ("Invalid back reference"), /* REG_ESUBREG */
+ gettext_noop ("Unmatched [ or [^"), /* REG_EBRACK */
+ gettext_noop ("Unmatched ( or \\("), /* REG_EPAREN */
+ gettext_noop ("Unmatched \\{"), /* REG_EBRACE */
+ gettext_noop ("Invalid content of \\{\\}"), /* REG_BADBR */
+ gettext_noop ("Invalid range end"), /* REG_ERANGE */
+ gettext_noop ("Memory exhausted"), /* REG_ESPACE */
+ gettext_noop ("Invalid preceding regular expression"), /* REG_BADRPT */
+ gettext_noop ("Premature end of regular expression"), /* REG_EEND */
+ gettext_noop ("Regular expression too big"), /* REG_ESIZE */
gettext_noop ("Unmatched ) or \\)") /* REG_ERPAREN */
};
-
-static const size_t re_error_msgid_idx[] =
- {
- REG_NOERROR_IDX,
- REG_NOMATCH_IDX,
- REG_BADPAT_IDX,
- REG_ECOLLATE_IDX,
- REG_ECTYPE_IDX,
- REG_EESCAPE_IDX,
- REG_ESUBREG_IDX,
- REG_EBRACK_IDX,
- REG_EPAREN_IDX,
- REG_EBRACE_IDX,
- REG_BADBR_IDX,
- REG_ERANGE_IDX,
- REG_ESPACE_IDX,
- REG_BADRPT_IDX,
- REG_EEND_IDX,
- REG_ESIZE_IDX,
- REG_ERPAREN_IDX
- };
#endif /* INSIDE_RECURSION */
@@ -4702,7 +4650,7 @@ PREFIX(re_compile_fastmap) (bufp)
while (1)
{
- if (p == pend || *p == succeed)
+ if (p == pend || *p == (UCHAR_T) succeed)
{
/* We have reached the (effective) end of pattern. */
if (!FAIL_STACK_EMPTY ())
@@ -7944,7 +7892,7 @@ re_compile_pattern (pattern, length, bufp)
if (!ret)
return NULL;
- return gettext (re_error_msgid + re_error_msgid_idx[(int) ret]);
+ return gettext (re_error_msgid[(int) ret]);
}
#ifdef _LIBC
weak_alias (__re_compile_pattern, re_compile_pattern)
@@ -7981,14 +7929,12 @@ re_comp (s)
{
re_comp_buf.buffer = (unsigned char *) malloc (200);
if (re_comp_buf.buffer == NULL)
- return (char *) gettext (re_error_msgid
- + re_error_msgid_idx[(int) REG_ESPACE]);
+ return (char *) gettext (re_error_msgid[(int) REG_ESPACE]);
re_comp_buf.allocated = 200;
re_comp_buf.fastmap = (char *) malloc (1 << BYTEWIDTH);
if (re_comp_buf.fastmap == NULL)
- return (char *) gettext (re_error_msgid
- + re_error_msgid_idx[(int) REG_ESPACE]);
+ return (char *) gettext (re_error_msgid[(int) REG_ESPACE]);
}
/* Since `re_exec' always passes NULL for the `regs' argument, we
@@ -8008,7 +7954,7 @@ re_comp (s)
return NULL;
/* Yes, we're discarding `const' here if !HAVE_LIBINTL. */
- return (char *) gettext (re_error_msgid + re_error_msgid_idx[(int) ret]);
+ return (char *) gettext (re_error_msgid[(int) ret]);
}
@@ -8096,7 +8042,7 @@ regcomp (preg, pattern, cflags)
/* Map uppercase characters to corresponding lowercase ones. */
for (i = 0; i < CHAR_SET_SIZE; i++)
- preg->translate[i] = ISUPPER (i) ? TOLOWER (i) : i;
+ preg->translate[i] = ISUPPER (i) ? TOLOWER (i) : (int) i;
}
else
preg->translate = NULL;
@@ -8231,7 +8177,7 @@ weak_alias (__regexec, regexec)
size_t
regerror (errcode, preg, errbuf, errbuf_size)
int errcode;
- const regex_t *preg;
+ const regex_t *preg ATTRIBUTE_UNUSED;
char *errbuf;
size_t errbuf_size;
{
@@ -8239,15 +8185,15 @@ regerror (errcode, preg, errbuf, errbuf_size)
size_t msg_size;
if (errcode < 0
- || errcode >= (int) (sizeof (re_error_msgid_idx)
- / sizeof (re_error_msgid_idx[0])))
+ || errcode >= (int) (sizeof (re_error_msgid)
+ / sizeof (re_error_msgid[0])))
/* Only error codes returned by the rest of the code should be passed
to this routine. If we are given anything else, or if other regex
code generates an invalid error code, then the program has a bug.
Dump core so we can fix it. */
abort ();
- msg = gettext (re_error_msgid + re_error_msgid_idx[errcode]);
+ msg = gettext (re_error_msgid[errcode]);
msg_size = strlen (msg) + 1; /* Includes the null. */
@@ -8256,7 +8202,7 @@ regerror (errcode, preg, errbuf, errbuf_size)
if (msg_size > errbuf_size)
{
#if defined HAVE_MEMPCPY || defined _LIBC
- *((char *) __mempcpy (errbuf, msg, errbuf_size - 1)) = '\0';
+ *((char *) mempcpy (errbuf, msg, errbuf_size - 1)) = '\0';
#else
memcpy (errbuf, msg, errbuf_size - 1);
errbuf[errbuf_size - 1] = 0;
diff --git a/contrib/binutils/libiberty/rename.c b/contrib/binutils/libiberty/rename.c
index 0563062..399980a 100644
--- a/contrib/binutils/libiberty/rename.c
+++ b/contrib/binutils/libiberty/rename.c
@@ -12,6 +12,7 @@ exists, it is removed.
*/
+#include "ansidecl.h"
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
@@ -22,8 +23,8 @@ exists, it is removed.
int
rename (zfrom, zto)
- char *zfrom;
- char *zto;
+ const char *zfrom;
+ const char *zto;
{
if (link (zfrom, zto) < 0)
{
diff --git a/contrib/binutils/libiberty/safe-ctype.c b/contrib/binutils/libiberty/safe-ctype.c
index 0c2be3e..91a0e9a 100644
--- a/contrib/binutils/libiberty/safe-ctype.c
+++ b/contrib/binutils/libiberty/safe-ctype.c
@@ -19,20 +19,109 @@ License along with libiberty; see the file COPYING.LIB. If
not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */
-/* This is a compatible replacement of the standard C library's <ctype.h>
- with the following properties:
-
- - Implements all isxxx() macros required by C99.
- - Also implements some character classes useful when
- parsing C-like languages.
- - Does not change behavior depending on the current locale.
- - Behaves properly for all values in the range of a signed or
- unsigned char. */
+/*
+
+@defvr Extension HOST_CHARSET
+This macro indicates the basic character set and encoding used by the
+host: more precisely, the encoding used for character constants in
+preprocessor @samp{#if} statements (the C "execution character set").
+It is defined by @file{safe-ctype.h}, and will be an integer constant
+with one of the following values:
+
+@ftable @code
+@item HOST_CHARSET_UNKNOWN
+The host character set is unknown - that is, not one of the next two
+possibilities.
+
+@item HOST_CHARSET_ASCII
+The host character set is ASCII.
+
+@item HOST_CHARSET_EBCDIC
+The host character set is some variant of EBCDIC. (Only one of the
+nineteen EBCDIC varying characters is tested; exercise caution.)
+@end ftable
+@end defvr
+
+@deffn Extension ISALPHA (@var{c})
+@deffnx Extension ISALNUM (@var{c})
+@deffnx Extension ISBLANK (@var{c})
+@deffnx Extension ISCNTRL (@var{c})
+@deffnx Extension ISDIGIT (@var{c})
+@deffnx Extension ISGRAPH (@var{c})
+@deffnx Extension ISLOWER (@var{c})
+@deffnx Extension ISPRINT (@var{c})
+@deffnx Extension ISPUNCT (@var{c})
+@deffnx Extension ISSPACE (@var{c})
+@deffnx Extension ISUPPER (@var{c})
+@deffnx Extension ISXDIGIT (@var{c})
+
+These twelve macros are defined by @file{safe-ctype.h}. Each has the
+same meaning as the corresponding macro (with name in lowercase)
+defined by the standard header @file{ctype.h}. For example,
+@code{ISALPHA} returns true for alphabetic characters and false for
+others. However, there are two differences between these macros and
+those provided by @file{ctype.h}:
+
+@itemize @bullet
+@item These macros are guaranteed to have well-defined behavior for all
+values representable by @code{signed char} and @code{unsigned char}, and
+for @code{EOF}.
+
+@item These macros ignore the current locale; they are true for these
+fixed sets of characters:
+@multitable {@code{XDIGIT}} {yada yada yada yada yada yada yada yada}
+@item @code{ALPHA} @tab @kbd{A-Za-z}
+@item @code{ALNUM} @tab @kbd{A-Za-z0-9}
+@item @code{BLANK} @tab @kbd{space tab}
+@item @code{CNTRL} @tab @code{!PRINT}
+@item @code{DIGIT} @tab @kbd{0-9}
+@item @code{GRAPH} @tab @code{ALNUM || PUNCT}
+@item @code{LOWER} @tab @kbd{a-z}
+@item @code{PRINT} @tab @code{GRAPH ||} @kbd{space}
+@item @code{PUNCT} @tab @kbd{`~!@@#$%^&*()_-=+[@{]@}\|;:'",<.>/?}
+@item @code{SPACE} @tab @kbd{space tab \n \r \f \v}
+@item @code{UPPER} @tab @kbd{A-Z}
+@item @code{XDIGIT} @tab @kbd{0-9A-Fa-f}
+@end multitable
+
+Note that, if the host character set is ASCII or a superset thereof,
+all these macros will return false for all values of @code{char} outside
+the range of 7-bit ASCII. In particular, both ISPRINT and ISCNTRL return
+false for characters with numeric values from 128 to 255.
+@end itemize
+@end deffn
+
+@deffn Extension ISIDNUM (@var{c})
+@deffnx Extension ISIDST (@var{c})
+@deffnx Extension IS_VSPACE (@var{c})
+@deffnx Extension IS_NVSPACE (@var{c})
+@deffnx Extension IS_SPACE_OR_NUL (@var{c})
+@deffnx Extension IS_ISOBASIC (@var{c})
+These six macros are defined by @file{safe-ctype.h} and provide
+additional character classes which are useful when doing lexical
+analysis of C or similar languages. They are true for the following
+sets of characters:
+
+@multitable {@code{SPACE_OR_NUL}} {yada yada yada yada yada yada yada yada}
+@item @code{IDNUM} @tab @kbd{A-Za-z0-9_}
+@item @code{IDST} @tab @kbd{A-Za-z_}
+@item @code{VSPACE} @tab @kbd{\r \n}
+@item @code{NVSPACE} @tab @kbd{space tab \f \v \0}
+@item @code{SPACE_OR_NUL} @tab @code{VSPACE || NVSPACE}
+@item @code{ISOBASIC} @tab @code{VSPACE || NVSPACE || PRINT}
+@end multitable
+@end deffn
+
+*/
#include "ansidecl.h"
#include <safe-ctype.h>
#include <stdio.h> /* for EOF */
+#if EOF != -1
+ #error "<safe-ctype.h> requires EOF == -1"
+#endif
+
/* Shorthand */
#define bl _sch_isblank
#define cn _sch_iscntrl
@@ -48,25 +137,23 @@ Boston, MA 02111-1307, USA. */
#define xd _sch_isxdigit
/* Masks. */
-#define L lo|is |pr /* lower case letter */
-#define XL lo|is|xd|pr /* lowercase hex digit */
-#define U up|is |pr /* upper case letter */
-#define XU up|is|xd|pr /* uppercase hex digit */
-#define D di |xd|pr /* decimal digit */
-#define P pn |pr /* punctuation */
-#define _ pn|is |pr /* underscore */
-
-#define C cn /* control character */
-#define Z nv |cn /* NUL */
-#define M nv|sp |cn /* cursor movement: \f \v */
-#define V vs|sp |cn /* vertical space: \r \n */
-#define T nv|sp|bl|cn /* tab */
-#define S nv|sp|bl|pr /* space */
+#define L (const unsigned short) (lo|is |pr) /* lower case letter */
+#define XL (const unsigned short) (lo|is|xd|pr) /* lowercase hex digit */
+#define U (const unsigned short) (up|is |pr) /* upper case letter */
+#define XU (const unsigned short) (up|is|xd|pr) /* uppercase hex digit */
+#define D (const unsigned short) (di |xd|pr) /* decimal digit */
+#define P (const unsigned short) (pn |pr) /* punctuation */
+#define _ (const unsigned short) (pn|is |pr) /* underscore */
+
+#define C (const unsigned short) ( cn) /* control character */
+#define Z (const unsigned short) (nv |cn) /* NUL */
+#define M (const unsigned short) (nv|sp |cn) /* cursor movement: \f \v */
+#define V (const unsigned short) (vs|sp |cn) /* vertical space: \r \n */
+#define T (const unsigned short) (nv|sp|bl|cn) /* tab */
+#define S (const unsigned short) (nv|sp|bl|pr) /* space */
/* Are we ASCII? */
-#if '\n' == 0x0A && ' ' == 0x20 && '0' == 0x30 \
- && 'A' == 0x41 && 'a' == 0x61 && '!' == 0x21 \
- && EOF == -1
+#if HOST_CHARSET == HOST_CHARSET_ASCII
const unsigned short _sch_istable[256] =
{
@@ -159,5 +246,9 @@ const unsigned char _sch_toupper[256] =
};
#else
- #error "Unsupported host character set"
-#endif /* not ASCII */
+# if HOST_CHARSET == HOST_CHARSET_EBCDIC
+ #error "FIXME: write tables for EBCDIC"
+# else
+ #error "Unrecognized host character set"
+# endif
+#endif
diff --git a/contrib/binutils/libiberty/sigsetmask.c b/contrib/binutils/libiberty/sigsetmask.c
index f705fbb..4de3e4b 100644
--- a/contrib/binutils/libiberty/sigsetmask.c
+++ b/contrib/binutils/libiberty/sigsetmask.c
@@ -25,8 +25,8 @@ extern void abort PARAMS ((void)) ATTRIBUTE_NORETURN;
#ifdef SIG_SETMASK
int
-DEFUN(sigsetmask,(set),
- int set)
+sigsetmask (set)
+ int set;
{
sigset_t new;
sigset_t old;
diff --git a/contrib/binutils/libiberty/splay-tree.c b/contrib/binutils/libiberty/splay-tree.c
index 7999447..fc98db1 100644
--- a/contrib/binutils/libiberty/splay-tree.c
+++ b/contrib/binutils/libiberty/splay-tree.c
@@ -234,7 +234,7 @@ splay_tree_xmalloc_allocate (size, data)
int size;
void *data ATTRIBUTE_UNUSED;
{
- return xmalloc (size);
+ return (void *) xmalloc (size);
}
static void
@@ -472,7 +472,7 @@ splay_tree_predecessor (sp, key)
if (comparison < 0)
return sp->root;
- /* Otherwise, find the leftmost element of the right subtree. */
+ /* Otherwise, find the rightmost element of the left subtree. */
node = sp->root->left;
if (node)
while (node->right)
@@ -482,7 +482,7 @@ splay_tree_predecessor (sp, key)
}
/* Return the immediate successor KEY, or NULL if there is no
- predecessor. KEY need not be present in the tree. */
+ successor. KEY need not be present in the tree. */
splay_tree_node
splay_tree_successor (sp, key)
@@ -492,7 +492,7 @@ splay_tree_successor (sp, key)
int comparison;
splay_tree_node node;
- /* If the tree is empty, there is certainly no predecessor. */
+ /* If the tree is empty, there is certainly no successor. */
if (!sp->root)
return NULL;
@@ -505,7 +505,7 @@ splay_tree_successor (sp, key)
if (comparison > 0)
return sp->root;
- /* Otherwise, find the rightmost element of the left subtree. */
+ /* Otherwise, find the leftmost element of the right subtree. */
node = sp->root->right;
if (node)
while (node->left)
diff --git a/contrib/binutils/libiberty/strcasecmp.c b/contrib/binutils/libiberty/strcasecmp.c
index 4bfe650..d2608dc 100644
--- a/contrib/binutils/libiberty/strcasecmp.c
+++ b/contrib/binutils/libiberty/strcasecmp.c
@@ -25,7 +25,7 @@ static char sccsid[] = "@(#)strcasecmp.c 5.5 (Berkeley) 11/24/87";
#endif /* LIBC_SCCS and not lint */
#include <ansidecl.h>
-#ifdef __STDC__
+#ifdef ANSI_PROTOTYPES
#include <stddef.h>
#else
#define size_t unsigned long
diff --git a/contrib/binutils/libiberty/strdup.c b/contrib/binutils/libiberty/strdup.c
index 49233ba..a3f17d3 100644
--- a/contrib/binutils/libiberty/strdup.c
+++ b/contrib/binutils/libiberty/strdup.c
@@ -9,13 +9,24 @@ Returns a pointer to a copy of @var{s} in memory obtained from
*/
+#include <ansidecl.h>
+#ifdef ANSI_PROTOTYPES
+#include <stddef.h>
+#else
+#define size_t unsigned long
+#endif
+
+extern size_t strlen PARAMS ((const char*));
+extern PTR malloc PARAMS ((size_t));
+extern PTR memcpy PARAMS ((PTR, const PTR, size_t));
+
char *
strdup(s)
- char *s;
+ const char *s;
{
- char *result = (char*)malloc(strlen(s) + 1);
- if (result == (char*)0)
- return (char*)0;
- strcpy(result, s);
- return result;
+ size_t len = strlen (s) + 1;
+ char *result = (char*) malloc (len);
+ if (result == (char*) 0)
+ return (char*) 0;
+ return (char*) memcpy (result, s, len);
}
diff --git a/contrib/binutils/libiberty/strerror.c b/contrib/binutils/libiberty/strerror.c
index 18050c2..83a5992 100644
--- a/contrib/binutils/libiberty/strerror.c
+++ b/contrib/binutils/libiberty/strerror.c
@@ -462,6 +462,8 @@ static int num_error_names = 0;
#ifndef HAVE_SYS_ERRLIST
+#define sys_nerr sys_nerr__
+#define sys_errlist sys_errlist__
static int sys_nerr;
static const char **sys_errlist;
@@ -472,7 +474,6 @@ extern char *sys_errlist[];
#endif
-
/*
NAME
diff --git a/contrib/binutils/libiberty/strncasecmp.c b/contrib/binutils/libiberty/strncasecmp.c
index 77cb421..10feee8 100644
--- a/contrib/binutils/libiberty/strncasecmp.c
+++ b/contrib/binutils/libiberty/strncasecmp.c
@@ -25,7 +25,7 @@ static char sccsid[] = "@(#)strcasecmp.c 5.5 (Berkeley) 11/24/87";
#endif /* LIBC_SCCS and not lint */
#include <ansidecl.h>
-#ifdef __STDC__
+#ifdef ANSI_PROTOTYPES
#include <stddef.h>
#else
#define size_t unsigned long
diff --git a/contrib/binutils/libiberty/strncmp.c b/contrib/binutils/libiberty/strncmp.c
index 819cea6..ad87e1fd 100644
--- a/contrib/binutils/libiberty/strncmp.c
+++ b/contrib/binutils/libiberty/strncmp.c
@@ -13,7 +13,7 @@ Compares the first @var{n} bytes of two strings, returning a value as
*/
#include <ansidecl.h>
-#ifdef __STDC__
+#ifdef ANSI_PROTOTYPES
#include <stddef.h>
#else
#define size_t unsigned long
diff --git a/contrib/binutils/libiberty/strsignal.c b/contrib/binutils/libiberty/strsignal.c
index 86c8aca..a8a7d34 100644
--- a/contrib/binutils/libiberty/strsignal.c
+++ b/contrib/binutils/libiberty/strsignal.c
@@ -42,7 +42,7 @@ extern PTR memset ();
#undef sys_nsig
#ifndef NULL
-# ifdef __STDC__
+# ifdef ANSI_PROTOTYPES
# define NULL (void *) 0
# else
# define NULL 0
diff --git a/contrib/binutils/libiberty/strstr.c b/contrib/binutils/libiberty/strstr.c
index 470e04b..a059c7f 100644
--- a/contrib/binutils/libiberty/strstr.c
+++ b/contrib/binutils/libiberty/strstr.c
@@ -27,8 +27,8 @@ strstr (s1, s2)
register char *p = s1;
extern char *strchr ();
extern int strncmp ();
-#if __GNUC__==2
- extern __SIZE_TYPE__ strlen ();
+#if __GNUC__ >= 2
+ extern __SIZE_TYPE__ strlen (const char *);
#endif
register int len = strlen (s2);
diff --git a/contrib/binutils/libiberty/vasprintf.c b/contrib/binutils/libiberty/vasprintf.c
index d438225..d3d4f3a 100644
--- a/contrib/binutils/libiberty/vasprintf.c
+++ b/contrib/binutils/libiberty/vasprintf.c
@@ -1,6 +1,6 @@
/* Like vsprintf but provides a pointer to malloc'd storage, which must
be freed by the caller.
- Copyright (C) 1994 Free Software Foundation, Inc.
+ Copyright (C) 1994, 2003 Free Software Foundation, Inc.
This file is part of the libiberty library.
Libiberty is free software; you can redistribute it and/or
@@ -52,20 +52,20 @@ you pass a pointer to a pointer. This function will compute the size
of the buffer needed, allocate memory with @code{malloc}, and store a
pointer to the allocated memory in @code{*@var{resptr}}. The value
returned is the same as @code{vsprintf} would return. If memory could
-not be allocated, zero is returned and @code{NULL} is stored in
+not be allocated, minus one is returned and @code{NULL} is stored in
@code{*@var{resptr}}.
@end deftypefn
*/
-static int int_vasprintf PARAMS ((char **, const char *, va_list *));
+static int int_vasprintf PARAMS ((char **, const char *, va_list));
static int
int_vasprintf (result, format, args)
char **result;
const char *format;
- va_list *args;
+ va_list args;
{
const char *p = format;
/* Add one to make sure that it is never zero, which might cause malloc
@@ -73,7 +73,11 @@ int_vasprintf (result, format, args)
int total_width = strlen (format) + 1;
va_list ap;
- memcpy ((PTR) &ap, (PTR) args, sizeof (va_list));
+#ifdef va_copy
+ va_copy (ap, args);
+#else
+ memcpy ((PTR) &ap, (PTR) &args, sizeof (va_list));
+#endif
while (*p != '\0')
{
@@ -135,14 +139,17 @@ int_vasprintf (result, format, args)
p++;
}
}
+#ifdef va_copy
+ va_end (ap);
+#endif
#ifdef TEST
global_total_width = total_width;
#endif
- *result = malloc (total_width);
+ *result = (char *) malloc (total_width);
if (*result != NULL)
- return vsprintf (*result, format, *args);
+ return vsprintf (*result, format, args);
else
- return 0;
+ return -1;
}
int
@@ -155,7 +162,7 @@ vasprintf (result, format, args)
va_list args;
#endif
{
- return int_vasprintf (result, format, &args);
+ return int_vasprintf (result, format, args);
}
#ifdef TEST
diff --git a/contrib/binutils/libiberty/vfprintf.c b/contrib/binutils/libiberty/vfprintf.c
index db7b2ff..18f09d4 100644
--- a/contrib/binutils/libiberty/vfprintf.c
+++ b/contrib/binutils/libiberty/vfprintf.c
@@ -3,7 +3,8 @@
Copyright (C) 1998 Free Software Foundation, Inc.
*/
-#ifdef __STDC__
+#include "ansidecl.h"
+#ifdef ANSI_PROTOTYPES
#include <stdarg.h>
#else
#include <varargs.h>
diff --git a/contrib/binutils/libiberty/vprintf.c b/contrib/binutils/libiberty/vprintf.c
index c57c3e4..9487896 100644
--- a/contrib/binutils/libiberty/vprintf.c
+++ b/contrib/binutils/libiberty/vprintf.c
@@ -15,13 +15,13 @@ nonstandard but common function @code{_doprnt}.
*/
-#ifdef __STDC__
+#include <ansidecl.h>
+#ifdef ANSI_PROTOTYPES
#include <stdarg.h>
#else
#include <varargs.h>
#endif
#include <stdio.h>
-#include <ansidecl.h>
#undef vprintf
int
vprintf (format, ap)
diff --git a/contrib/binutils/libiberty/vsprintf.c b/contrib/binutils/libiberty/vsprintf.c
index b69e9bc..9f09d7e 100644
--- a/contrib/binutils/libiberty/vsprintf.c
+++ b/contrib/binutils/libiberty/vsprintf.c
@@ -26,9 +26,13 @@ the resulting executable to be covered by the GNU General Public License.
This exception does not however invalidate any other reasons why
the executable file might be covered by the GNU General Public License. */
+#include <ansidecl.h>
+#ifdef ANSI_PROTOTYPES
+#include <stdarg.h>
+#else
#include <varargs.h>
+#endif
#include <stdio.h>
-#include <ansidecl.h>
#undef vsprintf
#if defined _IOSTRG && defined _IOWRT
diff --git a/contrib/binutils/libiberty/xatexit.c b/contrib/binutils/libiberty/xatexit.c
index abf3407..075599c 100644
--- a/contrib/binutils/libiberty/xatexit.c
+++ b/contrib/binutils/libiberty/xatexit.c
@@ -27,7 +27,7 @@ failure. If you use @code{xatexit} to register functions, you must use
#include <stdio.h>
-#ifdef __STDC__
+#ifdef ANSI_PROTOTYPES
#include <stddef.h>
#else
#define size_t unsigned long
diff --git a/contrib/binutils/libiberty/xmalloc.c b/contrib/binutils/libiberty/xmalloc.c
index 4c8249a..c3fe1a8 100644
--- a/contrib/binutils/libiberty/xmalloc.c
+++ b/contrib/binutils/libiberty/xmalloc.c
@@ -68,7 +68,7 @@ function will be called to print an error message and terminate execution.
#include <stdio.h>
-#ifdef __STDC__
+#ifdef ANSI_PROTOTYPES
#include <stddef.h>
#else
#define size_t unsigned long
diff --git a/contrib/binutils/libtool.m4 b/contrib/binutils/libtool.m4
index 3f452bc..d2e3608 100644
--- a/contrib/binutils/libtool.m4
+++ b/contrib/binutils/libtool.m4
@@ -144,6 +144,19 @@ case $host in
# Find out which ABI we are using.
echo '[#]line __oline__ "configure"' > conftest.$ac_ext
if AC_TRY_EVAL(ac_compile); then
+ if test "$lt_cv_prog_gnu_ld" = yes; then
+ case `/usr/bin/file conftest.$ac_objext` in
+ *32-bit*)
+ LD="${LD-ld} -melf32bsmip"
+ ;;
+ *N32*)
+ LD="${LD-ld} -melf32bmipn32"
+ ;;
+ *64-bit*)
+ LD="${LD-ld} -melf64bmip"
+ ;;
+ esac
+ else
case `/usr/bin/file conftest.$ac_objext` in
*32-bit*)
LD="${LD-ld} -32"
@@ -155,6 +168,7 @@ case $host in
LD="${LD-ld} -64"
;;
esac
+ fi
fi
rm -rf conftest*
;;
@@ -622,7 +636,7 @@ irix5* | irix6*)
# This must be Linux ELF.
linux-gnu*)
case $host_cpu in
- alpha* | hppa* | i*86 | powerpc* | sparc* | ia64* )
+ alpha* | mips* | hppa* | i*86 | powerpc* | sparc* | ia64* )
lt_cv_deplibs_check_method=pass_all ;;
*)
# glibc up to 2.1.1 does not perform some relocations on ARM
diff --git a/contrib/binutils/ltcf-c.sh b/contrib/binutils/ltcf-c.sh
index ea6a31f..d60a3ba 100644
--- a/contrib/binutils/ltcf-c.sh
+++ b/contrib/binutils/ltcf-c.sh
@@ -108,7 +108,7 @@ EOF
extract_expsyms_cmds='test -f $output_objdir/impgen.c || \
sed -e "/^# \/\* impgen\.c starts here \*\//,/^# \/\* impgen.c ends here \*\// { s/^# //; p; }" -e d < $0 > $output_objdir/impgen.c~
test -f $output_objdir/impgen.exe || (cd $output_objdir && \
- if test "x$HOST_CC" != "x" ; then $HOST_CC -o impgen impgen.c ; \
+ if test "x$BUILD_CC" != "x" ; then $BUILD_CC -o impgen impgen.c ; \
else $CC -o impgen impgen.c ; fi)~
$output_objdir/impgen $dir/$soroot > $output_objdir/$soname-def'
diff --git a/contrib/binutils/ltcf-cxx.sh b/contrib/binutils/ltcf-cxx.sh
index bdc67f9..9059b1a 100644
--- a/contrib/binutils/ltcf-cxx.sh
+++ b/contrib/binutils/ltcf-cxx.sh
@@ -2,7 +2,7 @@
# ltcf-cxx.sh - Create a C++ compiler specific configuration
#
-# Copyright (C) 1996-1999, 2000, 2001 Free Software Foundation, Inc.
+# Copyright (C) 1996-1999, 2000, 2001, 2003 Free Software Foundation, Inc.
# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
#
# Original C++ support by:Gary V. Vaughan <gvv@techie.com>
@@ -68,11 +68,16 @@ if { ac_try='${CC-c++} -E conftest.$ac_ext'; { (eval echo \"$ac_try\") 1>&5; (ev
# Set up default GNU C++ configuration
# Check if GNU C++ uses GNU ld as the underlying linker, since the
- # archiving commands below assume that GNU ld is being used.
- if eval "`$CC -print-prog-name=ld` --version 2>&1" | \
- egrep 'GNU ld' > /dev/null; then
- with_gnu_ld=yes
-
+ # archiving commands below assume that GNU ld is being used. The
+ # assumption here is that the linker is going to be the same as that
+ # used by the C compiler. For the purposes of GCC, this is ok, but
+ # if someone uses g++ along with a non-GNU C compiler that doesn't
+ # use GNU ld, we may lose. This is ok for the toolchain tree, since
+ # the only users of ltcf-cxx.sh are libstdc++-v3 and libjava,
+ # anyway, and those use both gcc and g++, so the settings are bound
+ # to be the same.
+
+ if test "$with_gnu_ld" = yes; then
archive_cmds='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib'
archive_expsym_cmds='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib'
@@ -92,7 +97,6 @@ if { ac_try='${CC-c++} -E conftest.$ac_ext'; { (eval echo \"$ac_try\") 1>&5; (ev
whole_archive_flag_spec=
fi
else
- with_gnu_ld=no
wlarc=
# A generic and very simple default shared library creation
@@ -110,7 +114,6 @@ if { ac_try='${CC-c++} -E conftest.$ac_ext'; { (eval echo \"$ac_try\") 1>&5; (ev
else
with_gcc=no
- with_gnu_ld=no
wlarc=
fi
@@ -323,7 +326,7 @@ case $host_os in
if test "$with_gnu_ld" = no; then
archive_cmds='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && echo ${wl}-set_version ${wl}$verstring` ${wl}-update_registry ${wl}${objdir}/so_locations -o $lib'
else
- archive_cmds='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -o $lib'
+ archive_cmds='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && echo -set_version $verstring` -o $lib'
fi
fi
hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir'
@@ -610,9 +613,9 @@ case $host_os in
if test "$with_gcc" = yes && test "$with_gnu_ld" = no; then
no_undefined_flag=' ${wl}-z ${wl}defs'
if $CC --version | egrep -v '^2\.7' > /dev/null; then
- archive_cmds='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $linker_flags ${wl}-h $wl$soname -o $lib'
+ archive_cmds='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
- $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags~$rm $lib.exp'
+ $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
# Commands to make compiler produce verbose output that lists
# what "hidden" libraries, object files and flags are used when
@@ -621,9 +624,9 @@ case $host_os in
else
# g++ 2.7 appears to require `-G' NOT `-shared' on this
# platform.
- archive_cmds='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $linker_flags ${wl}-h $wl$soname -o $lib'
+ archive_cmds='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
- $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags~$rm $lib.exp'
+ $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
# Commands to make compiler produce verbose output that lists
# what "hidden" libraries, object files and flags are used when
diff --git a/contrib/binutils/ltcf-gcj.sh b/contrib/binutils/ltcf-gcj.sh
index 7be8712..2d70497 100644
--- a/contrib/binutils/ltcf-gcj.sh
+++ b/contrib/binutils/ltcf-gcj.sh
@@ -2,7 +2,7 @@
# ltcf-gcj.sh - Create a GCJ compiler specific configuration
#
-# Copyright (C) 1996-1999, 2000, 2001 Free Software Foundation, Inc.
+# Copyright (C) 1996-1999, 2000, 2001, 2003 Free Software Foundation, Inc.
# Originally by Gordon Matzigkeit <gord@gnu.ai.mit.edu>, 1996
#
# Original GCJ support by:
@@ -111,7 +111,7 @@ EOF
extract_expsyms_cmds='test -f $output_objdir/impgen.c || \
sed -e "/^# \/\* impgen\.c starts here \*\//,/^# \/\* impgen.c ends here \*\// { s/^# //; p; }" -e d < $0 > $output_objdir/impgen.c~
test -f $output_objdir/impgen.exe || (cd $output_objdir && \
- if test "x$HOST_CC" != "x" ; then $HOST_CC -o impgen impgen.c ; \
+ if test "x$BUILD_CC" != "x" ; then $BUILD_CC -o impgen impgen.c ; \
else $CC -o impgen impgen.c ; fi)~
$output_objdir/impgen $dir/$soroot > $output_objdir/$soname-def'
@@ -492,9 +492,9 @@ else
solaris*)
no_undefined_flag=' ${wl}-z ${wl}defs'
- archive_cmds='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $linker_flags ${wl}-h $wl$soname -o $lib'
+ archive_cmds='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib'
archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
- $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags~$rm $lib.exp'
+ $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
# Commands to make compiler produce verbose output that lists
# what "hidden" libraries, object files and flags are used when
diff --git a/contrib/binutils/ltconfig b/contrib/binutils/ltconfig
index 5ccefe0..0a8c7d2 100755
--- a/contrib/binutils/ltconfig
+++ b/contrib/binutils/ltconfig
@@ -1111,6 +1111,18 @@ darwin* | rhapsody*)
shlibpath_var=DYLD_LIBRARY_PATH
;;
+freebsd*-gnu*)
+ version_type=linux
+ need_lib_prefix=no
+ need_version=no
+ library_names_spec='${libname}${release}.so$versuffix ${libname}${release}.so${major} ${libname}.so'
+ soname_spec='${libname}${release}.so${major}'
+ shlibpath_var=LD_LIBRARY_PATH
+ shlibpath_overrides_runpath=no
+ hardcode_into_libs=yes
+ dynamic_linker='GNU/FreeBSD ld.so'
+ ;;
+
freebsd1*)
dynamic_linker=no
;;
@@ -1167,7 +1179,7 @@ hpux9* | hpux10* | hpux11*)
shlibpath_var=LD_LIBRARY_PATH
shlibpath_overrides_runpath=yes # Unless +noenvvar is specified.
if test "X$HPUX_IA64_MODE" = X32; then
- sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32/usr/local/lib"
+ sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib"
else
sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64"
fi
@@ -1186,6 +1198,11 @@ hpux9* | hpux10* | hpux11*)
;;
irix5* | irix6*)
+ if test "$with_gnu_ld" = yes; then
+ version_type=linux
+ else
+ version_type=irix
+ fi
version_type=irix
need_lib_prefix=no
need_version=no
@@ -1197,9 +1214,12 @@ irix5* | irix6*)
;;
*)
case $LD in # libtool.m4 will add one of these switches to LD
- *-32|*"-32 ") libsuff= shlibsuff= libmagic=32-bit;;
- *-n32|*"-n32 ") libsuff=32 shlibsuff=N32 libmagic=N32;;
- *-64|*"-64 ") libsuff=64 shlibsuff=64 libmagic=64-bit;;
+ *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ")
+ libsuff= shlibsuff= libmagic=32-bit;;
+ *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ")
+ libsuff=32 shlibsuff=N32 libmagic=N32;;
+ *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ")
+ libsuff=64 shlibsuff=64 libmagic=64-bit;;
*) libsuff= shlibsuff= libmagic=never-match;;
esac
;;
diff --git a/contrib/binutils/missing b/contrib/binutils/missing
index 7789652..25c9667 100644
--- a/contrib/binutils/missing
+++ b/contrib/binutils/missing
@@ -1,7 +1,7 @@
#! /bin/sh
# Common stub for a few missing GNU programs while installing.
-# Copyright (C) 1996, 1997 Free Software Foundation, Inc.
-# Franc,ois Pinard <pinard@iro.umontreal.ca>, 1996.
+# Copyright (C) 1996, 1997, 1999, 2000, 2002 Free Software Foundation, Inc.
+# Originally by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -18,11 +18,37 @@
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
# 02111-1307, USA.
+# As a special exception to the GNU General Public License, if you
+# distribute this file as part of a program that contains a
+# configuration script generated by Autoconf, you may include it under
+# the same distribution terms that you use for the rest of that program.
+
if test $# -eq 0; then
echo 1>&2 "Try \`$0 --help' for more information"
exit 1
fi
+run=:
+
+# In the cases where this matters, `missing' is being run in the
+# srcdir already.
+if test -f configure.ac; then
+ configure_ac=configure.ac
+else
+ configure_ac=configure.in
+fi
+
+case "$1" in
+--run)
+ # Try to run requested program, and just exit if it succeeds.
+ run=
+ shift
+ "$@" && exit 0
+ ;;
+esac
+
+# If it does not exist, or fails to run (possibly an outdated version),
+# try to emulate it.
case "$1" in
-h|--h|--he|--hel|--help)
@@ -35,6 +61,7 @@ error status if there is no known handling for PROGRAM.
Options:
-h, --help display this help and exit
-v, --version output version information and exit
+ --run try to run the given command, and emulate it if it fails
Supported PROGRAM values:
aclocal touch file \`aclocal.m4'
@@ -43,13 +70,15 @@ Supported PROGRAM values:
automake touch all \`Makefile.in' files
bison create \`y.tab.[ch]', if possible, from existing .[ch]
flex create \`lex.yy.c', if possible, from existing .c
+ help2man touch the output file
lex create \`lex.yy.c', if possible, from existing .c
makeinfo touch the output file
+ tar try tar, gnutar, gtar, then tar without non-portable flags
yacc create \`y.tab.[ch]', if possible, from existing .[ch]"
;;
-v|--v|--ve|--ver|--vers|--versi|--versio|--version)
- echo "missing - GNU libit 0.0"
+ echo "missing 0.4 - GNU automake"
;;
-*)
@@ -58,31 +87,46 @@ Supported PROGRAM values:
exit 1
;;
- aclocal)
+ aclocal*)
+ if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
+ # We have it, but it failed.
+ exit 1
+ fi
+
echo 1>&2 "\
WARNING: \`$1' is missing on your system. You should only need it if
- you modified \`acinclude.m4' or \`configure.in'. You might want
+ you modified \`acinclude.m4' or \`${configure_ac}'. You might want
to install the \`Automake' and \`Perl' packages. Grab them from
any GNU archive site."
touch aclocal.m4
;;
autoconf)
+ if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
+ # We have it, but it failed.
+ exit 1
+ fi
+
echo 1>&2 "\
WARNING: \`$1' is missing on your system. You should only need it if
- you modified \`configure.in'. You might want to install the
+ you modified \`${configure_ac}'. You might want to install the
\`Autoconf' and \`GNU m4' packages. Grab them from any GNU
archive site."
touch configure
;;
autoheader)
+ if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
+ # We have it, but it failed.
+ exit 1
+ fi
+
echo 1>&2 "\
WARNING: \`$1' is missing on your system. You should only need it if
- you modified \`acconfig.h' or \`configure.in'. You might want
+ you modified \`acconfig.h' or \`${configure_ac}'. You might want
to install the \`Autoconf' and \`GNU m4' packages. Grab them
from any GNU archive site."
- files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' configure.in`
+ files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' ${configure_ac}`
test -z "$files" && files="config.h"
touch_files=
for f in $files; do
@@ -95,10 +139,15 @@ WARNING: \`$1' is missing on your system. You should only need it if
touch $touch_files
;;
- automake)
+ automake*)
+ if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
+ # We have it, but it failed.
+ exit 1
+ fi
+
echo 1>&2 "\
WARNING: \`$1' is missing on your system. You should only need it if
- you modified \`Makefile.am', \`acinclude.m4' or \`configure.in'.
+ you modified \`Makefile.am', \`acinclude.m4' or \`${configure_ac}'.
You might want to install the \`Automake' and \`Perl' packages.
Grab them from any GNU archive site."
find . -type f -name Makefile.am -print |
@@ -106,6 +155,34 @@ WARNING: \`$1' is missing on your system. You should only need it if
while read f; do touch "$f"; done
;;
+ autom4te)
+ if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
+ # We have it, but it failed.
+ exit 1
+ fi
+
+ echo 1>&2 "\
+WARNING: \`$1' is needed, and you do not seem to have it handy on your
+ system. You might have modified some files without having the
+ proper tools for further handling them.
+ You can get \`$1' as part of \`Autoconf' from any GNU
+ archive site."
+
+ file=`echo "$*" | sed -n 's/.*--output[ =]*\([^ ]*\).*/\1/p'`
+ test -z "$file" && file=`echo "$*" | sed -n 's/.*-o[ ]*\([^ ]*\).*/\1/p'`
+ if test -f "$file"; then
+ touch $file
+ else
+ test -z "$file" || exec >$file
+ echo "#! /bin/sh"
+ echo "# Created by GNU Automake missing as a replacement of"
+ echo "# $ $@"
+ echo "exit 0"
+ chmod +x $file
+ exit 1
+ fi
+ ;;
+
bison|yacc)
echo 1>&2 "\
WARNING: \`$1' is missing on your system. You should only need it if
@@ -159,7 +236,37 @@ WARNING: \`$1' is missing on your system. You should only need it if
fi
;;
+ help2man)
+ if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
+ # We have it, but it failed.
+ exit 1
+ fi
+
+ echo 1>&2 "\
+WARNING: \`$1' is missing on your system. You should only need it if
+ you modified a dependency of a manual page. You may need the
+ \`Help2man' package in order for those modifications to take
+ effect. You can get \`Help2man' from any GNU archive site."
+
+ file=`echo "$*" | sed -n 's/.*-o \([^ ]*\).*/\1/p'`
+ if test -z "$file"; then
+ file=`echo "$*" | sed -n 's/.*--output=\([^ ]*\).*/\1/p'`
+ fi
+ if [ -f "$file" ]; then
+ touch $file
+ else
+ test -z "$file" || exec >$file
+ echo ".ab help2man is required to generate this page"
+ exit 1
+ fi
+ ;;
+
makeinfo)
+ if test -z "$run" && (makeinfo --version) > /dev/null 2>&1; then
+ # We have makeinfo, but it failed.
+ exit 1
+ fi
+
echo 1>&2 "\
WARNING: \`$1' is missing on your system. You should only need it if
you modified a \`.texi' or \`.texinfo' file, or any other file
@@ -175,6 +282,45 @@ WARNING: \`$1' is missing on your system. You should only need it if
touch $file
;;
+ tar)
+ shift
+ if test -n "$run"; then
+ echo 1>&2 "ERROR: \`tar' requires --run"
+ exit 1
+ fi
+
+ # We have already tried tar in the generic part.
+ # Look for gnutar/gtar before invocation to avoid ugly error
+ # messages.
+ if (gnutar --version > /dev/null 2>&1); then
+ gnutar "$@" && exit 0
+ fi
+ if (gtar --version > /dev/null 2>&1); then
+ gtar "$@" && exit 0
+ fi
+ firstarg="$1"
+ if shift; then
+ case "$firstarg" in
+ *o*)
+ firstarg=`echo "$firstarg" | sed s/o//`
+ tar "$firstarg" "$@" && exit 0
+ ;;
+ esac
+ case "$firstarg" in
+ *h*)
+ firstarg=`echo "$firstarg" | sed s/h//`
+ tar "$firstarg" "$@" && exit 0
+ ;;
+ esac
+ fi
+
+ echo 1>&2 "\
+WARNING: I can't seem to be able to run \`tar' with the given arguments.
+ You may want to install GNU tar or Free paxutils, or check the
+ command line arguments."
+ exit 1
+ ;;
+
*)
echo 1>&2 "\
WARNING: \`$1' is needed, and you do not seem to have it handy on your
diff --git a/contrib/binutils/mkinstalldirs b/contrib/binutils/mkinstalldirs
index cc8783e..d2d5f21 100755
--- a/contrib/binutils/mkinstalldirs
+++ b/contrib/binutils/mkinstalldirs
@@ -2,35 +2,110 @@
# mkinstalldirs --- make directory hierarchy
# Author: Noah Friedman <friedman@prep.ai.mit.edu>
# Created: 1993-05-16
-# Last modified: 1994-03-25
# Public domain
errstatus=0
+dirmode=""
-for file in ${1+"$@"} ; do
- set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'`
- shift
+usage="\
+Usage: mkinstalldirs [-h] [--help] [-m mode] dir ..."
- pathcomp=
- for d in ${1+"$@"} ; do
- pathcomp="$pathcomp$d"
- case "$pathcomp" in
- -* ) pathcomp=./$pathcomp ;;
- esac
+# process command line arguments
+while test $# -gt 0 ; do
+ case $1 in
+ -h | --help | --h*) # -h for help
+ echo "$usage" 1>&2
+ exit 0
+ ;;
+ -m) # -m PERM arg
+ shift
+ test $# -eq 0 && { echo "$usage" 1>&2; exit 1; }
+ dirmode=$1
+ shift
+ ;;
+ --) # stop option processing
+ shift
+ break
+ ;;
+ -*) # unknown option
+ echo "$usage" 1>&2
+ exit 1
+ ;;
+ *) # first non-opt arg
+ break
+ ;;
+ esac
+done
+
+for file
+do
+ if test -d "$file"; then
+ shift
+ else
+ break
+ fi
+done
+
+case $# in
+ 0) exit 0 ;;
+esac
+
+case $dirmode in
+ '')
+ if mkdir -p -- . 2>/dev/null; then
+ echo "mkdir -p -- $*"
+ exec mkdir -p -- "$@"
+ fi
+ ;;
+ *)
+ if mkdir -m "$dirmode" -p -- . 2>/dev/null; then
+ echo "mkdir -m $dirmode -p -- $*"
+ exec mkdir -m "$dirmode" -p -- "$@"
+ fi
+ ;;
+esac
+
+for file
+do
+ set fnord `echo ":$file" | sed -ne 's/^:\//#/;s/^://;s/\// /g;s/^#/\//;p'`
+ shift
+
+ pathcomp=
+ for d
+ do
+ pathcomp="$pathcomp$d"
+ case $pathcomp in
+ -*) pathcomp=./$pathcomp ;;
+ esac
+
+ if test ! -d "$pathcomp"; then
+ echo "mkdir $pathcomp"
+
+ mkdir "$pathcomp" || lasterr=$?
- if test ! -d "$pathcomp"; then
- echo "mkdir $pathcomp" 1>&2
- mkdir "$pathcomp" > /dev/null 2>&1 || lasterr=$?
- fi
+ if test ! -d "$pathcomp"; then
+ errstatus=$lasterr
+ else
+ if test ! -z "$dirmode"; then
+ echo "chmod $dirmode $pathcomp"
+ lasterr=""
+ chmod "$dirmode" "$pathcomp" || lasterr=$?
- if test ! -d "$pathcomp"; then
- errstatus=$lasterr
- fi
+ if test ! -z "$lasterr"; then
+ errstatus=$lasterr
+ fi
+ fi
+ fi
+ fi
- pathcomp="$pathcomp/"
- done
+ pathcomp="$pathcomp/"
+ done
done
exit $errstatus
+# Local Variables:
+# mode: shell-script
+# sh-indentation: 2
+# End:
# mkinstalldirs ends here
diff --git a/contrib/binutils/opcodes/ChangeLog b/contrib/binutils/opcodes/ChangeLog
index 3c9dfc3..88c6b3e 100644
--- a/contrib/binutils/opcodes/ChangeLog
+++ b/contrib/binutils/opcodes/ChangeLog
@@ -1,2934 +1,187 @@
-2002-10-30 Daniel Jacobowitz <drow@mvista.com>
+2004-05-13 Nick Clifton <nickc@redhat.com>
- * po/opcodes.pot: Regenerated.
-
-2002-10-28 Daniel Jacobowitz <drow@mvista.com>
-
- Merge from mainline:
- 2002-10-07 Nathan Tallent <eraxxon@alumni.rice.edu>
- * sparc-opc.c (sparc_opcodes) <fb, fba, fbe, fbz, fbg, fbge,
- fbl, fble, fblg, fbn, fbne, fbnz, fbo, fbu, fbue, fbug, fbuge,
- fbul, fbule>: Add conditional/unconditional branch
- classification.
-
- 2002-09-24 Nick Clifton <nickc@redhat.com>
- * po/de.po: Updated Danish translation file.
-
-2002-09-04 Nick Clifton <nickc@redhat.com>
- Daniel Jacobowitz <drow@mvista.com>
-
- * disassemble.c (disassembler_usage): Add invocation of
- print_ppc_disassembler_options.
- * ppc-dis.c (print_ppc_disassembler_options): New function.
-
-2002-09-23 Daniel Jacobowitz <drow@mvista.com>
-
- Merge from mainline:
- 2002-09-11 Nick Clifton <nickc@redhat.com>
- * po/da.po: Updated Danish translation file.
-
- 2002-09-04 Nick Clifton <nickc@redhat.com>
- * ppc-opc.c: The BookE implementations of the TLBWE and TLBRE
- instructions do not take any arguments.
-
- 2002-09-04 Nick Clifton <nickc@redhat.com>
- * ppc-opc.c (extsw, extsw.): Do not allow for the BookE32.
-
- 2002-08-09 Nick Clifton <nickc@redhat.com>
- * po/sv.po: Updated Swedish translation.
-
-2002-08-20 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
-
- * mips-opc.c (mips_builtin_opcodes): Remove "dla" and "la" as
- aliases to "daddiu" and "addiu".
-
-2002-07-30 Daniel Jacobowitz <drow@mvista.com>
-
- Merge from mainline:
- 2002-07-30 Nick Clifton <nickc@redhat.com>
- * po/sv.po: Updated Swedish translation.
-
-2002-07-25 Nick Clifton <nickc@redhat.com>
-
- * po/sv.po: Updated Swedish translation.
- * po/es.po: Updated Spanish translation.
- * po/pr_BR.po: Updated Brazilian Portuguese translation.
- * po/tr.po: Updated Turkish translation.
* po/fr.po: Updated French translation.
-2002-07-24 Nick Clifton <nickc@redhat.com>
-
- * po/sv.po: Updated Swedish translation.
- * po/es.po: Updated Spanish translation.
- * po/pr_BR.po: Updated Brazilian Portuguese translation.
-
-2002-07-23 Daniel Jacobowitz <drow@mvista.com>
-
- * po/opcodes.pot: Regenerated.
-
-2002-07-23 Nick Clifton <nickc@redhat.com>
-
- * po/fr.po: Updated French translation.
- * po/pr_BR.po: New Brazilian Portuguese translation.
- * po/id.po: Updated Indonesian translation.
- * configure.in (LINGUAS): Add pr_BR.
- * configure: Regenerate.
-
-2002-07-17 David Mosberger <davidm@hpl.hp.com>
-
- * ia64-opc-b.c (bWhc): New macro.
- (mWhc): Ditto.
- (OpPaWhcD): Ditto.
- (ia64_opcodes_b): Correct patterns for indirect call
- instructions to use 3-bit "wh" field.
- * ia64-asmtab.c: Regnerate.
-
-2002-07-09 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * mips-dis.c (mips_isa_type): Add MIPS16 insn handling.
- * mips-opc.c (I16): New define.
- (mips_builtin_opcodes): Make jalx an I16 insn.
-
-2002-06-18 Dave Brolley <brolley@redhat.com>
-
- * po/POTFILES.in: Add frv-*.[ch].
- * disassemble.c (ARCH_frv): New macro.
- (disassembler): Handle bfd_arch_frv.
- * configure.in: Support frv_bfd_arch.
- * Makefile.am (HFILES): Add frv-*.h.
- (CFILES): Add frv-*.c
- (ALL_MACHINES): Add frv-*.lo.
- (CLEANFILES): Add stamp-frv.
- (FRV_DEPS): New variable.
- (stamp-frv): New target.
- (frv-asm.lo): New target.
- (frv-desc.lo): New target.
- (frv-dis.lo): New target.
- (frv-ibld.lo): New target.
- (frv-opc.lo): New target.
- (frv-*.[ch]): New files.
-
-2002-06-18 Ben Elliston <bje@redhat.com>
-
- * Makefile.am (CGENDEPS): Remove unnecessary stamp-cgen.
- * Makefile.in: Regenerate.
-
-2002-06-08 Alan Modra <amodra@bigpond.net.au>
-
- * a29k-dis.c: Replace CONST with const.
- * h8300-dis.c: Likewise.
- * m68k-dis.c: Likewise.
- * or32-dis.c: Likewise.
- * sparc-dis.c: Likewise.
-
-2002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
-
- * configure.in: Add "sh5*-*" to list of targets which include
- sh64 support.
- * configure: Regenerate.
-
-2002-05-31 Chris G. Demetriou <cgd@broadcom.com>
-
- * mips-opc.c: Clean up a few whitespace issues, and sort a
- few entries understanding that 'x' follows 'w' in the alphabet.
-
-2002-05-31 Chris G. Demetriou <cgd@broadcom.com>
- Ed Satterthwaite <ehs@broadcom.com>
-
- * mips-opc.c: Add support for SB-1 MDMX subset and extensions.
-
-2002-05-31 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: Run "make dep-am".
- * Makefile.in: Regenerate.
- * po/POTFILES.in: Regenerate.
-
-2002-05-30 Chris G. Demetriou <cgd@broadcom.com>
- Ed Satterthwaite <ehs@broadcom.com>
-
- * mips-dis.c (print_insn_arg): Add support for 'O', 'Q', 'X', 'Y',
- and 'Z' formats, for MDMX.
- (mips_isa_type): Add MDMX instructions to the ISA
- bit mask for bfd_mach_mipsisa64.
- * mips-opc.c: Add support for MDMX instructions.
- (MX): New definition.
-
- * mips-dis.c: Update copyright years to include 2002.
-
-2002-05-30 Diego Novillo <dnovillo@redhat.com>
-
- * d10v-opc.c (d10v_opcodes): `btsti' does not modify its
- arguments.
-
-2002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
-
- * configure.in: Add DLX configuraton support.
- * configure: Regenerate.
- * Makefile.am: Add DLX configuraton support.
- * Makefile.in: Regenerate.
- * disassemble.c: Add DLX support.
- * dlx-dis.c: New file.
-
-2002-05-25 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am (sh-dis.lo): Don't put make commands in deps.
- * Makefile.in: Regenerate.
- * arc-dis.c: Use #include "" instead of <> for local header files.
- * m68k-dis.c: Likewise.
-
-Wed May 22 20:11:51 2002 J"orn Rennecke <joern.rennecke@superh.com>
-
- * Makefile.am (sh-dis.lo): Compile with @archdefs@.
- * Makefile.in: regenerate.
-
- * sh-dis.c (print_insn_sh): If coff and bfd_mach_sh, use arch_sh4
- for disassembly.
-
-2002-05-22 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * mips-opc.c (mips_builtin_opcodes): Add drol, dror macros.
-
-Fri May 17 14:26:44 2002 J"orn Rennecke <joern.rennecke@superh.com>
-
- * disassemble.c (disassembler): Just use print_insn_sh for bfd_arch_sh.
- * sh-dis.c (LITTLE_BIT): Delete.
- (print_insn_sh, print_insn_shl): Deleted.
- (print_insn_shx): Renamed to
- (print_insn_sh). No longer static. Handle SHmedia instructions.
- Use info->endian to determine endianness.
- * sh64-dis.c (print_insn_sh64, print_insn_sh64l): Delete.
- (print_insn_sh64x): No longer static. Renamed to
- (print_insn_sh64). Removed pfun_compact and endian arguments.
- If we got an uneven address to indicate SHmedia, adjust it.
- Return -2 for SHcompact instructions.
-
-2002-05-17 Alan Modra <amodra@bigpond.net.au>
-
- * acinclude.m4 (AM_INSTALL_LIBBFD): Fake to fool autotools.
- * configure.in: Invoke AM_INSTALL_LIBBFD.
- * Makefile.am (install-data-local): Move to..
- (install_libopcodes): .. New target.
- (uninstall_libopcodes): Likewise.
- (install-bfdlibLTLIBRARIES): Likewise.
- (uninstall-bfdlibLTLIBRARIES): Likewise.
- (bfdlibdir): New.
- (bfdincludedir): New.
- (lib_LTLIBRARIES): Rename to bfdlib_LTLIBRARIES.
- * aclocal.m4: Regenerate.
- * configure: Regenerate.
- * Makefile.in: Regenerate.
-
-2002-05-15 Nick Clifton <nickc@cambridge.redhat.com>
-
- * fr30-asm.c: Regenerate.
- * fr30-desc.c: Regenerate.
- * fr30-dis.c: Regenerate.
- * m32r-asm.c: Regenerate.
- * m32r-desc.c: Regenerate.
- * m32r-dis.c: Regenerate.
- * openrisc-asm.c: Regenerate.
- * openrisc-desc.c: Regenerate.
- * openrisc-dis.c: Regenerate.
- * xstormy16-asm.c: Regenerate.
- * xstormy16-desc.c: Regenerate.
- * xstormy16-dis.c: Regenerate.
-
-2002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * mips-dis.c (is_newabi): EABI is not a NewABI.
-
-2002-05-13 Jason Thorpe <thorpej@wasabisystems.com>
-
- * configure.in (shle-*-*elf*): Include sh64 support.
- * configure: Regenerate.
-
-2002-04-28 Jason Thorpe <thorpej@wasabisystems.com>
-
- * vax-dis.c (print_insn_arg): Pass the insn info to print_insn_mode.
- (print_insn_mode): Print some basic info about floating point values.
-
-2002-05-09 Anton Blanchard <anton@samba.org>
-
- * ppc-opc.c: Add "tlbiel" for POWER4.
-
-2002-05-07 Graydon Hoare <graydon@redhat.com>
-
- * cgen-dis.in: (print_insn_@arch@): Cache list of opened CPUs rather
- than just most-recently-opened.
-
-2002-05-01 Alan Modra <amodra@bigpond.net.au>
-
- * ppc-opc.c: Add "tlbsx." and "tlbsxe." for booke.
-
-2002-04-24 Christian Groessler <chris@groessler.org>
-
- * z8k-dis.c (print_insn_z8k): Set disassemble_info to 2
- bytes_per_chunk, 6 bytes_per_line for nicer display of the hex
- codes.
- (z8k_lookup_instr): CLASS_IGNORE case added.
- (output_instr): Don't print hex codes, they are already
- printed.
- (unpack_instr): ARG_NIM4 case added. ARG_NIM8 case
- fixed. Support CLASS_BIT_1OR2 and CLASS_IGNORE cases.
- (unparse_instr): Fix base and indexed addressing disassembly:
- The index is inside the brackets.
- * z8kgen.c (gas): Add ARG_NIM4 and CLASS_IGNORE defines.
- (opt): Fix shift left/right arithmetic/logical byte defines:
- The high byte of the immediate word is ignored by the
- processor.
- Fix n parameter of ldm opcodes: The opcode contains (n-1).
- (args): Fix "n" entry.
- (toks): Add "nim4" and "iiii" entries.
- * z8k-opc.h: Regenerated with new z8kgen.c.
-
-2002-04-24 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/id.po: New Indonesian translation.
- * configure.in (ALL_LIGUAS): Add id.po
- * configure: Regenerate.
-
-2002-04-17 matthew green <mrg@redhat.com>
-
- * ppc-opc.c (powerpc_opcode): Fix dssall operand list.
-
-2002-04-04 Alan Modra <amodra@bigpond.net.au>
-
- * dep-in.sed: Cope with absolute paths.
- * Makefile.am (dep.sed): Subst TOPDIR.
- Run "make dep-am".
- * Makefile.in: Regenerate.
- * ppc-opc.c: Whitespace.
- * s390-dis.c: Fix copyright date.
-
-2002-03-23 matthew green <mrg@redhat.com>
-
- * ppc-opc.c (vmaddfp): Fix operand order.
-
-2002-03-21 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: Run "make dep-am".
- * Makefile.in: Regenerate.
-
-2002-03-21 Anton Blanchard <anton@samba.org>
-
- * ppc-opc.c: Add optional field to mtmsrd.
- (MTMSRD_L, XRLARB_MASK): Define.
-
-Mon Mar 18 21:10:43 CET 2002 Jan Hubicka <jh@suse.cz>
-
- * i386-dis.c (prefix_name): Fix handling of 32bit address prefix
- in 64bit mode.
- (print_insn) Likewise.
- (putop): Fix handling of 'E'
- (OP_E, OP_OFF): handle 32bit addressing mode in 64bit.
- (ptr_reg): Likewise.
-
-2002-03-18 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/fr.po: Updated version.
-
-2002-03-16 Chris Demetriou <cgd@broadcom.com>
-
- * mips-opc.c (M3D): Tweak comment.
- (mips_builtin_op): Add comment indicating that opcodes of the
- same name must be placed together in the table, and sort
- the "recip.fmt", "recip1.fmt", "recip2.fmt", "rsqrt.fmt",
- "rsqrt1.fmt", and "rsqrt2.fmt" opcodes by name.
-
-2002-03-16 Nick Clifton <nickc@cambridge.redhat.com>
-
- * Makefile.am: Tidy up sh64 rules.
- * Makefile.in: Regenerate.
-
-2002-03-15 Chris G. Demetriou <cgd@broadcom.com>
-
- * mips-dis.c: Update copyright years.
-
-2002-03-15 Chris G. Demetriou <cgd@broadcom.com>
-
- * mips-dis.c (mips_isa_type): Add MIPS3D instructions to the ISA
- bit masks for bfd_mach_mips_sb1 and bfd_mach_mipsisa64. Add
- comments for bfd_mach_mipsisa32 and bfd_mach_mipsisa64 that
- indicate that they should dissassemble all applicable
- MIPS-specified ASEs.
- * mips-opc.c: Add support for MIPS-3D instructions.
- (M3D): New definition.
-
- * mips-opc.c: Update copyright years.
-
-2002-03-15 Chris G. Demetriou <cgd@broadcom.com>
-
- * mips-opc.c (mips_builtin_opcodes): Sort bc<N> opcodes by name.
-
-2002-03-15 Chris Demetriou <cgd@broadcom.com>
-
- * mips-dis.c (is_newabi): Fix ABI decoding.
-
-2002-03-14 Chris G. Demetriou <cgd@broadcom.com>
-
- * mips-dis.c (mips_isa_type): Fix formatting of bfd_mach_mipsisa32
- and bfd_mach_mipsisa64 cases to match the rest.
-
-2002-03-13 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/fr.po: Updated version.
-
-2002-03-13 Alan Modra <amodra@bigpond.net.au>
-
- * ppc-opc.c: Add optional `L' field to tlbie.
- (XRTLRA_MASK): Define.
-
-2002-03-06 Chris Demetriou <cgd@broadcom.com>
-
- * mips-opc.c (mips_builtin_opcodes): Mark "pref" as being
- present on I4.
-
- * mips-opc.c (mips_builtin_opcodes): Add "movn.ps" and "movz.ps".
-
-2002-03-05 Paul Koning <pkoning@equallogic.com>
-
- * pdp11-opc.c: Fix "mark" operand type. Fix operand types
- for float opcodes that take float operands. Add alternate
- names (xxxD vs. xxxF) for float opcodes.
- * pdp11-dis.c (print_operand): Clean up formatting for mode 67.
- (print_foperand): New function to handle float opcode operands.
- (print_insn_pdp11): Use print_foperand to disassemble float ops.
-
-2002-02-27 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/de.po: Updated.
-
-2002-02-26 Brian Gaeke <brg@dgate.org>
-
- * Makefile.am (install-data-local): Install dis-asm.h.
-
-2002-02-26 Nick Clifton <nickc@cambridge.redhat.com>
-
- * configure.in (LINGUAS): Add de.po.
- * configure: Regenerate.
- * po/de.po: New file.
-
-2002-02-25 Alan Modra <amodra@bigpond.net.au>
-
- * ppc-dis.c (powerpc_dialect): Handle power4 option.
- * ppc-opc.c (insert_bdm): Correct description of "at" branch
- hints. Test PPC_OPCODE_POWER4 to determine branch hint flavour.
- (extract_bdm, insert_bdp, extract_bdp, valid_bo): Likewise.
- (BOFM64, BOFP64, BOTM64, BOFP64): Rename to BOFM4, BOFP4 etc.
- (BODNZM64, BODNZP64, BODZM64, BODZP64): Likewise.
- (PPCCOM32, PPCCOM64): Delete.
- (NOPOWER4, POWER4): Define.
- (powerpc_opcodes): Replace occurences of PPCCOM32 with NOPOWER4,
- and PPCCOM4 with POWER4 so that "at" style branch hint opcodes
- are enabled for power4 rather than ppc64.
-
-2002-02-20 Tom Rix <trix@redhat.com>
-
- * ppc-opc.c (powerpc_operands): Add WS field. Use for tlbre, tlbwe.
-
-2002-02-19 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * s390-dis.c (init_disasm): Use renamed architecture defines.
-
-2002-02-19 matthew green <mrg@redhat.com>
-
- * ppc-opc.c (powerpc_dialect): Fix comment; BookE is not Motorola
- specific.
-
-2002-02-18 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/tr.po: Updated translation.
-
-2002-02-15 Richard Henderson <rth@redhat.com>
-
- * alpha-opc.c (alpha_opcodes): Fix thinko in ret pseudo
- disassembly mask.
-
-2002-02-15 Richard Henderson <rth@redhat.com>
-
- * alpha-opc.c (alpha_opcodes): Add simple pseudos for
- lda, ldah, jmp, ret.
-
-2002-02-14 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/da.po: Updated translation.
-
-2002-02-12 Graydon Hoare <graydon@redhat.com>
-
- * cgen-asm.in (parse_insn_normal): Change call from
- @arch@_cgen_parse_operand to cd->parse_operand, to
- facilitate CGEN_ASM_INIT_HOOK doing useful work.
-
-2002-02-11 Alexandre Oliva <aoliva@redhat.com>
-
- * sparc-dis.c (print_insn_sparc): Make sure 0xFFFFFFFF is not
- sign-extended.
-
-2002-02-11 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: "make dep-am".
- * Makefile.in: Regenerate.
- * aclocal.m4: Regenerate.
- * config.in: Regenerate.
- * configure: Regenerate.
-
-2002-02-10 Hans-Peter Nilsson <hp@bitrange.com>
-
- * configure.in <bfd_sh_arc>: For sh-* and shl-*, enable sh64
- support only for sh-*-*elf*, shl-*-*elf*, sh-*-linux* and
- shl-*-linux*.
- * configure: Regenerate.
-
-2002-02-10 Daniel Jacobowitz <drow@mvista.com>
-
- * cgen-dis.c: Add prototypes for count_decodable_bits
- and add_insn_to_hash_chain.
-
-2002-02-08 Alexandre Oliva <aoliva@redhat.com>
-
- * configure.in <bfd_sh_arc>: Enable sh64 support on sh-*.
- * configure: Rebuilt.
-
-2002-02-08 Ivan Guzvinec <ivang@opencores.org>
-
- * or32-opc.c: Fix compile time warning messages.
- * or32-dis.c: Fix compile time warning messages.
-
-2002-02-08 Alexandre Oliva <aoliva@redhat.com>
-
- Contribute sh64-elf.
- 2001-10-08 Nick Clifton <nickc@cambridge.redhat.com>
- * sh64-opc.c: Regenerate.
- 2001-03-13 DJ Delorie <dj@redhat.com>
- * sh64-opc.h: Rename A_RESV_Fx to A_REUSE_PREV so that its
- purpose is more obvious.
- * sh64-opc.c (shmedia_table): Ditto.
- * sh64-dis.c (initialize_shmedia_opcode_mask_table): Ditto.
- (print_insn_shmedia): Ditto.
- 2001-03-12 DJ Delorie <dj@redhat.com>
- * sh64-opc.c: Adjust comments to reflect reality: replace bits
- 3:0 with zeros (not "reserved"), replace "rrrrrr" with
- "gggggg" for two-operand floating point opcodes. Remove
- "fsina".
- 2001-01-08 Hans-Peter Nilsson <hpn@cygnus.com>
- * sh64-dis.c (print_insn_shmedia) <failing read_memory_func>:
- Correct printing of .byte:s. Return number of printed bytes or
- -1; never 0.
- (print_insn_sh64x) <not CRT_SH5_ISA16>: Ditto. Print as .byte:s
- to next four-byte-alignment if insn or data is not aligned.
- 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
- * sh64-dis.c: Update comments and fix comment formatting.
- (initialize_shmedia_opcode_mask_table) <case A_IMMM>:
- Abort instead of setting length to 0.
- (crange_qsort_cmpb, crange_qsort_cmpl, crange_bsearch_cmpb,
- crange_bsearch_cmpl, sh64_get_contents_type,
- sh64_address_in_cranges): Move to bfd/elf32-sh64.c.
- 2001-01-05 Hans-Peter Nilsson <hpn@cygnus.com>
- * sh64-opc.c: Remove #if 0:d entries for instructions not found in
- SH-5/ST50-023-04: fcosa.s, fsrra.s and prefo.
- 2000-12-30 Hans-Peter Nilsson <hpn@cygnus.com>
- * sh64-dis.c (print_insn_shmedia): Display MOVI/SHORI-formed
- address with same prefix as SHcompact.
- In the disassembler, use a .cranges section for linked executables.
- * sh64-dis.c (SAVED_MOVI_R, SAVED_MOVI_IMM): Move to head of file
- and update for using structure in info->private_data.
- (struct sh64_disassemble_info): New.
- (is_shmedia_p): Delete.
- (crange_qsort_cmpb): New function.
- (crange_qsort_cmpl, crange_bsearch_cmpb): New functions.
- (crange_bsearch_cmpl, sh64_address_in_cranges): New functions.
- (init_sh64_disasm_info, sh64_get_contents_type_disasm): New functions.
- (sh64_get_contents_type, sh64_address_is_shmedia): New functions.
- (print_insn_shmedia): Correct displaying of address after MOVI/SHORI
- pair. Display addresses for linked executables only.
- (print_insn_sh64x_media): Initialize info->private_data by calling
- init_sh64_disasm_info.
- (print_insn_sh64x): Ditto. Find out type of contents by calling
- sh64_contents_type_disasm. Display data regions using ".long" and
- ".byte" similar to unrecognized opcodes.
- 2000-12-19 Hans-Peter Nilsson <hpn@cygnus.com>
- * sh64-dis.c (is_shmedia_p): Check info->section and look for ISA
- information in section flags before considering symbols. Don't
- assume an info->mach setting of bfd_mach_sh5 means SHmedia code.
- * configure.in (bfd_sh_arch): Check presence of sh64 insns by
- matching $target $canon_targets instead of looking at the
- now-removed -DINCLUDE_SHMEDIA in $targ_cflags.
- * configure: Regenerate.
- 2000-11-25 Hans-Peter Nilsson <hpn@cygnus.com>
- * sh64-opc.c (shmedia_creg_table): New.
- * sh64-opc.h (shmedia_creg_info): New type.
- (shmedia_creg_table): Declare.
- * sh64-dis.c (creg_name): New function.
- (print_insn_shmedia): Use it.
- * disassemble.c (disassembler) [ARCH_sh, INCLUDE_SHMEDIA]: Map
- bfd_mach_sh5 to print_insn_sh64 if big-endian and to
- print_insn_sh64l if little-endian.
- * sh64-dis.c (print_insn_shmedia): Make r unsigned.
- (print_insn_sh64l): New.
- (print_insn_sh64x): New.
- (print_insn_sh64x_media): New.
- (print_insn_sh64): Break out code to print_insn_sh64x and
- print_insn_sh64x_media.
- 2000-11-24 Hans-Peter Nilsson <hpn@cygnus.com>
- * sh64-opc.h: New file
- * sh64-opc.c: New file
- * sh64-dis.c: New file
- * Makefile.am: Add sh64 targets.
- (HFILES): Add sh64-opc.h.
- (CFILES): Add sh64-opc.c and sh64-dis.c.
- (ALL_MACHINES): Add sh64 files.
- * Makefile.in: Regenerate.
- * configure.in: Add support for sh64 to bfd_sh_arch.
- * configure: Regenerate.
- * disassemble.c [ARCH_all] (INCLUDE_SHMEDIA): Define.
- (disassembler) [ARCH_sh, INCLUDE_SHMEDIA]: Map bfd_mach_sh5 to
- print_insn_sh64.
- * sh-dis.c (print_insn_shx): Handle bfd_mach_sh5 as arch_sh4.
- * po/POTFILES.in: Regenerate.
- * po/opcodes.pot: Regenerate.
-
-2002-02-04 Frank Ch. Eigler <fche@redhat.com>
-
- * cgen-dis.in (print_insn_@arch@): Support disassemble_info.insn_sets.
-
-2002-02-04 Alexandre Oliva <aoliva@redhat.com>
-
- * sh-opc.h (sh_arg_type): Added A_DISP_PC_ABS.
-
-2002-02-01 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: Run "make dep-am"
- * Makefile.in: Regenerate.
-
-2002-01-31 Ivan Guzvinec <ivang@opencores.org>
-
- * or32-dis.c: New file.
- * or32-opc.c: New file.
- * configure.in: Add support for or32.
- * configure: Regenerate.
- * Makefile.am: Add support for or32.
- * Makefile.in: Regenerate.
- * disassemble.c: Add support for or32.
- * po/POTFILES.in: Regenerate.
- * po/opcodes.pot: Regenerate.
-
-2002-01-27 Daniel Jacobowitz <drow@mvista.com>
-
- * configure: Regenerated.
-
-2002-01-26 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/fr.po: Updated version.
-
-2002-01-25 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/es.po: Updated version.
-
-2002-01-24 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/da.po: New version.
-
-2002-01-23 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/da.po: New file: Spanish translation.
- * configure.in (ALL_LINGUAS): Add da.
- * configure: Regenerate.
-
-2002-01-22 Graydon Hoare <graydon@redhat.com>
-
- * fr30-asm.c: Regenerate.
- * fr30-desc.c: Likewise.
- * fr30-desc.h: Likewise.
- * fr30-dis.c: Likewise.
- * fr30-ibld.c: Likewise.
- * fr30-opc.c: Likewise.
- * fr30-opc.h: Likewise.
- * m32r-asm.c: Likewise.
- * m32r-desc.c: Likewise.
- * m32r-desc.h: Likewise.
- * m32r-dis.c: Likewise.
- * m32r-ibld.c: Likewise.
- * m32r-opc.c: Likewise.
- * m32r-opc.h: Likewise.
- * m32r-opinst.c: Likewise.
- * openrisc-asm.c: Likewise.
- * openrisc-desc.c: Likewise.
- * openrisc-desc.h: Likewise.
- * openrisc-dis.c: Likewise.
- * openrisc-ibld.c: Likewise.
- * openrisc-opc.c: Likewise.
- * openrisc-opc.h: Likewise.
- * xstormy16-desc.c: Likewise.
-
-2002-01-22 Richard Henderson <rth@redhat.com>
-
- * alpha-dis.c (print_insn_alpha): Also mask the base opcode for
- comparison.
-
-2002-01-22 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: Run "make dep-am".
- * Makefile.in: Regenerate.
- * opcodes/po/POTFILES.in: Regenerate.
-
-2002-01-19 Richard Earnshaw <rearnsha@arm.com>
-
- * arm-opc.h (arm_opcodes): Use generic rule %5?hb instead of %h.
- * arm-dis.c (print_insn_arm): Don't handle 'h' case.
-
-2002-01-18 Keith Walker <keith.walker@arm.com>
+2004-05-05 Alan Modra <amodra@bigpond.net.au>
- * arm-opc.h (arm_opcodes): Add bxj instruction.
+ PR 146.
+ * ppc-opc.c (PPCVEC): Remove PPC_OPCODE_PPC.
-2002-01-17 Nick Clifton <nickc@cambridge.redhat.com>
+2004-04-09 Daniel Jacobowitz <drow@mvista.com>
- * po/opcodes.pot: Regenerate.
- * po/fr.po: Regenerate.
- * po/sv.po: Regenerate.
- * po/tr.po: Regenerate.
-
-2002-01-16 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/tr.po: Import new version.
-
-2002-01-15 Richard Earnshaw <rearnsha@arm.com>
-
- * arm-opc.h (arm_opcodes): Add patterns for VFP instructions.
- * arm-dis.c (print_insn_arm): Support new disassembly qualifiers for
- VFP bitfields.
-
-2002-01-10 matthew green <mrg@redhat.com>
-
- * xstormy16-asm.c: Regenerate.
- * xstormy16-desc.c: Likewise.
- * xstormy16-desc.h: Likewise.
- * xstormy16-dis.c: Likewise.
- * xstormy16-opc.c: Likewise.
- * xstormy16-opc.h: Likewise.
-
-2002-01-07 Nick Clifton <nickc@cambridge.redhat.com>
-
- * po/es.po: New file: Spanish translation.
- * configure.in (ALL_LINGUAS): Add es.
- * configure: Regenerate.
-
-2001-12-31 Jeffrey A Law (law@redhat.com)
-
- * hppa-dis.c (print_insn_hppa): Handle new 'c' mode completers,
- 'X', 'M', and 'A'. No longer emit a space after 'x' or 's'.
- Always emit a space after 'H'.
-
-2001-12-18 matthew green <mrg@redhat.com>
-
- * ppc-opc.c (PPCVEC): Include PPC_OPCODE_ANY.
-
-2001-12-17 Richard Henderson <rth@redhat.com>
-
- * alpha-opc.c (unop): Encode with RB as $sp.
-
-2001-12-07 Geoffrey Keating <geoffk@redhat.com>
-
- * Makefile.am: Add support for xstormy16.
- * Makefile.in: Regenerate.
- * configure.in: Add support for xstormy16.
- * configure: Regenerate.
- * disassemble.c: Add support for xstormy16.
- * xstormy16-asm.c: New generated file.
- * xstormy16-desc.c: New generated file.
- * xstormy16-desc.h: New generated file.
- * xstormy16-dis.c: New generated file.
- * xstormy16-ibld.c: New generated file.
- * xstormy16-opc.c: New generated file.
- * xstormy16-opc.h: New generated file.
-
-2001-12-06 Richard Henderson <rth@redhat.com>
-
- * alpha-opc.c (alpha_opcodes): Add wh64en.
-
-2001-12-04 Alexandre Oliva <aoliva@redhat.com>
-
- * d10v-opc.c (d10v_predefined_registers): Remove warnings
- introduced in Nov 29's patch.
-
- * d10v-dis.c (print_operand): Apply REGISTER_MASK to `num' of
- unmatched register.
-
- * d10v-dis.c (print_operand): Disregard OPERAND_SP in register
- predefined value.
-
- * d10v-opc.c (RSRC_NOSP): New macro.
- (d10v_operands): Add it.
- (d10v_opcodes): Use RSRC_NOSP in post-decrement "st" and "st2w".
-
-2001-11-29 Alexandre Oliva <aoliva@redhat.com>
-
- * d10v-opc.c (d10v_predefined_registers): Mark `sp' as OPERAND_SP.
- (RSRC_SP): New macro.
- (d10v_operands): Add it.
- (d10v_opcodes): Adjust "st" and "st2w" to use RSRC_SP.
-
-2001-11-23 Lars Brinkhoff <lars@nocrew.org>
-
- * pdp11-dis.c (print_insn_pdp11): Handle illegal instructions.
- Also, break out of the loop as soon as an instruction has been
- printed.
-
-2001-11-17 matthew green <mrg@redhat.com>
-
- * ppc-opc.c (mfvrsave, mtvrsave): New instructions.
-
-2001-11-15 Alan Modra <amodra@bigpond.net.au>
-
- * po/POTFILES.in: Regenerate.
-
- * ppc-opc.c (PPC64): Revert 2001-10-12. Do include PPC_OPCODE_PPC.
- (insert_bat, extract_bat, insert_bba, extract_bba,
- insert_bd, extract_bd, insert_bdm, extract_bdm,
- insert_bdp, extract_bdp, valid_bo,
- insert_bo, extract_bo, insert_boe, extract_boe,
- insert_ds, extract_ds, insert_de, extract_de,
- insert_des, extract_des, insert_li, extract_li,
- insert_mbe, extract_mbe, insert_mb6, extract_mb6,
- insert_nb, extract_nb, insert_nsi, extract_nsi,
- insert_ral, insert_ram, insert_ras,
- insert_rbs, extract_rbs, insert_sh6, extract_sh6,
- insert_spr, extract_spr, insert_tbr, extract_tbr): Add dialect param.
- (extract_bd, extract_bdm, extract_bdp,
- extract_ds, extract_des,
- extract_li, extract_nsi): Implement sign extension without conditional.
- (insert_bdm, extract_bdm,
- insert_bdp, extract_bdp, valid_bo): Handle 64 bit branch hints.
- (extract_bdm, extract_bdp): Correct 32 bit validation.
- (AT1_MASK, AT2_MASK): Define.
- (BBOAT_MASK): Define.
- (BBOATCB_MASK, BBOAT2CB_MASK, BBOATBI_MASK): Define.
- (BOFM64, BOFP64, BOTM64, BOTP64): Define.
- (BODNZM64, BODNZP64, BODZM64, BODZP64): Define.
- (PPCCOM32, PPCCOM64): Define.
- (powerpc_opcodes): Modify existing 32 bit insns with branch hints
- and add new patterns to implement 64 bit branches with hints. Move
- booke instructions so they match before ppc64.
-
- * ppc-dis.c (powerpc_dialect): Set PPC_OPCODE_64 in dialect for
- 64 bit default targets, and parse "32" and "64" in options.
- Formatting fixes.
- (print_insn_powerpc): Pass dialect to operand->extract.
-
-2001-11-14 Dave Brolley <brolley@redhat.com>
-
- * cgen-dis.c (count_decodable_bits): New function.
- (add_insn_to_hash_chain): New function.
- (hash_insn_array): Call add_insn_to_hash_chain.
- (hash_insn_list): Call add_insn_to_hash_chain.
- * m32r-dis.c: Regenerated.
- * fr30-dis.c: Regenerated.
-
-2001-11-14 Andreas Jaeger <aj@suse.de>
-
- * i386-dis.c (print_insn): Use x86-64 as option.
-
-2001-11-14 Alan Modra <amodra@bigpond.net.au>
-
- * disassemble.c (disassembler): Call print_insn_i386.
- * i386-dis.c (SUFFIX_ALWAYS): Define.
- (struct dis_private): Add orig_sizeflag.
- (print_insn_i386): Make it a wrapper, calling..
- (print_insn): ..The old body of print_insn_i386. Avoid longjmp
- warning without using volatile by moving orig_sizeflag to priv,
- and removing inbuf. Parse disassembler_options.
- (print_insn_i386_att, print_insn_i386_intel): Move initialisation
- code to print_insn.
- (putop): Remove #ifdef SUFFIX_ALWAYS.
-
-2001-11-11 Timothy Wall <twall@alum.mit.edu>
-
- * tic54x-dis.c: Use revised opcode structure. Export opcode
- template lookup.
- (has_lkaddr): Don't forget about Lmem insns.
- * tic54x-opc.c: Add emulation trap. Parallel table now uses
- standard opcode templates.
-
-2001-11-13 Zack Weinberg <zack@codesourcery.com>
-
- * i386-dis.c (grps): Change "sldt", "str", and "smsw" entries
- to "sldtQ", "strQ", "smswQ" respectively; all with Ev operand
- category instead of Ew.
-
-2001-11-12 Niraj Gupta <ngupta@zumanetworks.com>
-
- * m68k-opc.c: Fix definitions of wddata[bwl].
-
-2001-11-09 Richard Sandiford <rsandifo@redhat.com>
-
- * cgen-asm.c (cgen_parse_keyword): If the keyword is too big to
- fit in the buffer, try to match the empty keyword.
-
-2001-11-09 Nick Clifton <nickc@cambridge.redhat.com>
-
- * cgen-ibld.in (extract_1): Fix badly placed #if 0.
- * fr30-ibld.c: Regenerate.
- * m32r-ibld.c: Regenerate.
- * openrisc-ibld.c: Regenerate.
-
-2001-11-04 Chris Demetriou <cgd@broadcom.com>
-
- * mips-dis.c (print_insn_mips): Remove spaces at end of line.
-
-2001-11-02 Nick Clifton <nickc@cambridge.redhat.com>
-
- * configure.in (ALL_LINGUAS): Add "fr", "sv" and "tr".
- * configure: Regernate.
- * po/fr.po: New file.
- * po/sv.po: New file.
- * po/tr.po: New file.
-
-2001-11-01 Stephane Carrez <Stephane.Carrez@worldnet.fr>
-
- * m68hc11-dis.c (print_insn): Fix disassembly of movb with a
- constant as source.
-
-2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
-
- * Makefile.am (CFILES): Add mmix-dis.c and mmix-opc.c. Regenerate
- dependencies.
- * Makefile.in: Regenerate.
- * mmix-dis.c, mmix-opc.c: New files.
-
-2001-10-29 Kazu Hirata <kazu@hxi.com>
-
- * d30v-dis.c: Fix a comment typo.
-
-2001-10-23 Chris Demetriou <cgd@broadcom.com>
-
- * mips-opc.c (mips_builtin_opcodes): Mark "bgezall" and
- "bltzall" as writing GPR 31 (since they do).
-
- * mips-dis.c (print_insn_arg): Calculate info->target
- where appropriate.
- (print_insn_mips): Fill in instruction info.
- (print_mips16_insn_arg): Remove unneded variable 'val'.
- Removed duplicated instruction target calculations,
- calculate once and print that result. Use same idiom for
- masking the jump segment bits as is used in print_insn_arg.
-
-2001-10-20 Alan Modra <amodra@bigpond.net.au>
-
- * ppc-opc.c (CT): Make it an optional operand.
-
-2001-10-17 Chris Demetriou <cgd@broadcom.com>
-
- * mips-dis.c (mips_isa_type): Make the ISA used to disassemble
- SB-1 binaries include instructions specific to the SB-1.
- * mips-opc.c (SB1): New definition.
- (mips_builtin_opcodes): Add SB-1 extension opcodes "div.ps",
- "recip.ps", "rsqrt.ps", and "sqrt.ps".
-
-2001-10-17 matthew green <mrg@redhat.com>
-
- * ppc-opc.c (STRM): New AltiVec operand.
- (XDSS): New AltiVec instruction form.
- (mtvscr): Correct operand list.
- (dst, dstt, dstst, dststt, dss, dssall): AltiVec instructions.
-
-2001-10-17 Alan Modra <amodra@bigpond.net.au>
-
- * po/POTFILES.in: Regenerate.
-
-2001-10-13 matthew green <mrg@redhat.com>
-
- * ppc-opc.c (MO): New macro for MO field of mbar instruction.
- (powerpc_opcodes): Add rfci, wrtee, wrteei, mfdcrx, mfdcr,
- mtdcrx, mtdcr, msync, dcba and mbar as BookE instructions.
-
-2001-10-13 Nick Clifton <nickc@cambridge.redhat.com>
-
- * cgen-ibld.in: Include safe-ctype.h in preference to
- ctype.h.
- * cgen-asm.in: Include safe-ctype.h in preference to
- ctype.h. Fix formatting. Use ISSPACE instead of isspace and
- TOLOWER instead of tolower.
- (@arch@_cgen_build_insn_regex): Remove duplication of syntax
- string elements in constructed regular expression.
- * fr30-asm.c: Regenerate.
- * fr30-desc.c: Regenerate.
- * fr30-ibld.c: Regenerate.
- * m32r-asm.c: Regenerate.
- * m32r-desc.c: Regenerate.
- * m32r-ibld.c: Regenerate.
- * openrisc-asm.c: Regenerate.
- * openrisc-desc.c: Regenerate.
- * openrisc-ibld.c: Regenerate.
- * po/opcodes.pot: Regenerate.
-
-2001-10-12 matthew green <mrg@redhat.com>
-
- * ppc-opc.c (insert_de, extract_de, insert_des, extract_des): New
- instruction field instruction/extraction functions for new BookE
- DE form instructions.
- (CT): New macro for CT field in an X form instruction.
- (DE, DES, DEO, DE_MASK): New macros for DE/DES fields in DE form
- instructions.
- (PPC64): Don't include PPC_OPCODE_PPC.
- (403): New opcode macro for PPC403 processors.
- (BOOKE): New opcode macro for BookE processors.
- (bce, bcel, bcea, bcela, bclre, bclrel: New BookE instructions.
- (bcctre, bcctrel, be, bel, bea, bela, icbt, icbte, lwzxe): Likewise.
- (dcbste, lwzuxe, luxe, dcbfe, lbzxe, lwarxe, lbzuxe): Likewise.
- (stwcxe, stwxe, stxe, stwuxe, stuxe, stbxe, dcbtste, stbuxe): Likewise.
- (mfapidi, dcbte, lhzxe, lhzuxe, lhaxe, lhauxe, subfe64): Likewise.
- (subfeo64, adde64, addeo64, sthxe, sthuxe, subfze64): Likewise.
- (subfzeo64, addze64, addzeo64, dcbie, subfme64, subfmeo64): Likewise.
- (addme64, addmeo64, stdcxe., mcrxr64, lwbrxe, lfsxe, lfsuxe): Likewise.
- (lfdxe, lfduxe, stwbrxe, stfsxe, stfsuxe, stfdxe, dcbae): Likewise.
- (stfduxe, tlbivax, tlbivaxe, lhbrxe, ldxe, lduxe, tlbsx): Likewise.
- (tlbsxe, sthbrxe, stdxe, stduxe, icbie, stfiwxe, dcbze, lbze): Likewise.
- (lbzue, ldue, lhze, lhzue, lhae, lhaue, lwze, lwzue): Likewise.
- (stbe, stbue, sthe, sthue, stwe, stwue, lfse, lfsue, lfde): Likewise.
- (lfdue, stde, stdue, stfse, stfsue, stfde, stfdue): Likewise.
-
- * ppc-dis.c (print_insn_big_powerpc, print_insn_little_powerpc): Look
- for a disassembler option of `booke', `booke32' or `booke64' to enable
- BookE support in the disassembler.
-
-2001-10-12 John Healy <jhealy@redhat.com>
-
- * cgen-dis.in (print_insn): Use min (cd->base_insn_bitsize, buflen*8)
- for the length when extracting the base part of the insn.
-
-2001-10-09 Bruno Haible <haible@clisp.cons.org>
-
- * cgen-asm.in (*_cgen_build_insn_regex): Generate a case sensitive
- regular expression. Fix some formatting problems.
- * fr30-asm.c: Regenerate.
- * openrisc-asm.c: Regenerate.
+ Merge from mainline:
+ 2004-03-30 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
* m32r-asm.c: Regenerate.
-2001-10-09 Christian Groessler <cpg@aladdin.de>
-
- * z8k-dis.c (unparse_instr): Fixed formatting. Change disassembly
- of indirect register memory accesses to be same format the
- assembler accepts.
-
-2001-10-09 Nick Clifton <nickc@cambridge.redhat.com>
-
- * sh-opc.h: Fix encoding of least significant nibble of the
- DSP single data transfer instructions.
-
- * sh-dis.c (print_insn_shx): Fix decoding of As opcode in DSP
- instructions.
-
-2001-10-08 Nick Clifton <nickc@cambridge.redhat.com>
-
- * cgen-asm.in: Fix compile time warning messages in generated
- C files.
- * cgen-dis.in: The same.
- * cgen-ibld.in: The same.
- * fr30-asm.c: Regenerate.
- * fr30-desc.c: Regenerate.
- * fr30-dis.c: Regenerate.
- * fr30-ibld.c: Regenerate.
- * fr30-opc.c: Regenerate.
- * m32r-asm.c: Regenerate.
- * m32r-desc.c: Regenerate.
- * m32r-dis.c: Regenerate.
- * m32r-ibld.c: Regenerate.
- * m32r-opc.c: Regenerate.
- * m32r-opinst.c Regenerate.
- * openrisc-asm.c: Regenerate.
- * openrisc-desc.c: Regenerate.
- * openrisc-dis.c: Regenerate.
- * openrisc-ibld.c: Regenerate.
- * openrisc-opc.c: Regenerate.
- * openrisc-opc.h: Regenerate.
- * Makefile.in: Regenerate.
- * po/POTFILES.in: Regenerate.
- * po/opcodes.pot: Regenerate.
-
-2001-10-08 Aldy Hernandez <aldyh@redhat.com>
-
- * arm-opc.h (arm_opcodes): Add cirrus insns.
-
- * arm-dis.c (print_insn_arm): Add 'I' case.
-
-2001-10-03 Alan Modra <amodra@bigpond.net.au>
-
- * po/POTFILES.in: Regenerate.
- * configure: Regenerate.
-
-2001-10-02 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am (Makefile): Depend on bfd/configure.in.
- Run "make dep-am".
- * Makefile.in: Regenerate.
-
-2001-09-30 John Healy <jhealy@redhat.com>
-
- * cgen-ibld.in (insert_1): Switched bfd_get_bits and bfd_set_bits
- calls to cgen_get_insn_value and cgen_put_insn_value calls.
- (extract_1): Switched bfd_get_bits call to cgen_get_insn_value call.
-
-2001-09-30 Hans-Peter Nilsson <hp@bitrange.com>
-
- * Makefile.am: Update dependencies with "make dep-am".
- * Makefile.in: Regenerate.
-
-2001-09-26 Alan Modra <amodra@bigpond.net.au>
-
- * arc-dis.c: Formatting fixes.
- (my_sprintf): Define using VPARAMS, VA_OPEN, VA_FIXEDARG, VA_CLOSE.
-
-2001-09-21 Bruno Haible <haible@clisp.cons.org>
-
- * arc-dis.c: Don't include <ctype.h>.
- * openrisc-desc.c: Likewise.
- * openrisc-ibld.c: Likewise.
-
-2001-09-20 Nick Clifton <nickc@cambridge.redhat.com>
-
- * fr30-opc.c: Fix compile time warning messages.
- * i370-opc.c: Fix compile time warning messages.
- * i960-dis.c: Fix compile time warning messages.
- * m32r-asm.c: Fix compile time warning messages.
- * m32r-desc.c: Fix compile time warning messages.
- * m32r-dis.c: Fix compile time warning messages.
- * m32r-ibld.c: Fix compile time warning messages.
- * m32r-opc.c: Fix compile time warning messages.
- * m32r-opinst.c: Fix compile time warning messages.
- * ns32k-dis.c: Fix compile time warning messages.
- * openrisc-asm.c: Fix compile time warning messages.
- * openrisc-desc.c: Fix compile time warning messages.
- * openrisc-dis.c: Fix compile time warning messages.
- * openrisc-ibld.c: Fix compile time warning messages.
- * openrisc-opc.c: Fix compile time warning messages.
- * pdp11-dis.c: Fix compile time warning messages.
- * tic54x-dis.c: Fix compile time warning messages.
- * v850-opc.c: Fix compile time warning messages.
- * vax-dis.c: Fix compile time warning messages.
- * w65-opc.h: Fix compile time warning messages.
- * z8k-opc.h: Fix compile time warning messages.
- * z8kgen.c: Fix compile time warning messages.
-
-2001-09-19 Nick Clifton <nickc@cambridge.redhat.com>
-
- * arm-dis.c: Fix compile time warning messages.
- * cgen-asm.c: Fix compile time warning messages.
- * cgen-dis.c: Fix compile time warning messages.
- * cris-dis.c: Fix compile time warning messages.
- * d10v-dis.c: Fix compile time warning messages.
- * fr30-asm.c: Fix compile time warning messages.
- * fr30-desc.c: Fix compile time warning messages.
- * fr30-dis.c: Fix compile time warning messages.
- * fr30-ibld.c: Fix compile time warning messages.
-
-2001-09-18 Bruno Haible <haible@clisp.cons.org>
-
- * cgen-asm.c: Include "safe-ctype.h" instead of <ctype.h>.
- (cgen_parse_keyword): Use ISALNUM instead of isalnum.
- * cgen-opc.c: Include "safe-ctype.h" instead of <ctype.h>.
- (cgen_keyword_lookup_name): Use ISALPHA/TOLOWER instead of
- isalpha/tolower.
- (cgen_keyword_add): Use ISALNUM instead of isalnum.
- (hash_keyword_name): Use TOLOWER instead of tolower.
- * fr30-asm.c: Include "safe-ctype.h" instead of <ctype.h>.
- (parse_insn_normal): Use TOLOWER/ISSPACE instead of
- tolower/isspace.
- (fr30_cgen_assemble_insn): Use ISSPACE instead of isspace.
- * fr30-desc.c: Don't include <ctype.h>.
- * fr30-ibld.c: Likewise.
- * ia64-gen.c: Include "safe-ctype.h" instead of <ctype.h>.
- (load_insn_classes, parse_resource_users, load_depfile): Use
- ISSPACE instead of isspace.
- * m32r-asm.c: Include "safe-ctype.h" instead of <ctype.h>.
- (parse_insn_normal): Use TOLOWER/ISSPACE instead of
- tolower/isspace.
- (m32r_cgen_assemble_insn): Use ISSPACE instead of isspace.
- * m32r-desc.c: Don't include <ctype.h>.
- * m32r-ibld.c: Likewise.
- * openrisc-asm.c: Include "safe-ctype.h" instead of <ctype.h>.
- (parse_insn_normal): Use TOLOWER/ISSPACE instead of
- tolower/isspace.
- (openrisc_cgen_assemble_insn): Use ISSPACE instead of isspace.
-
-2001-09-18 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * Makefile.am: Add rules and dependencies to create the s/390 opcode
- table out of s390-opc.txt automatically.
- * configure.in: Add BFD_CC_FOR_BUILD to allow CC_FOR_BUILD to be used.
- * s390-mkopc.c (dumpTable): Change output to create a complete file.
- * s390-opc.c: New improved opcode format macros and remove the
- pregenerated opcode table.
- * s390-opc.txt: Adapt to new improved opcode format macros.
-
-2001-09-14 David Schleef <ds@schleef.org>
-
- * ppc-opc.c (VXA, VXA_MASK): Fix mask bits.
-
-2001-09-04 Alan Modra <amodra@bigpond.net.au>
-
- * i386-dis.c (grps): Don't print the implicit al/ax/eax register
- for opcode 0xf6 or 0xf7 forms of mul, imul, div, idiv insns.
-
-2001-08-31 Eric Christopher <echristo@redhat.com>
- Jason Eckhardt <jle@redhat.com>
-
- * mips-dis.c: Add support for bfd_mach_mipsisa32 and
- bfd_mach_mipsisa64. Remove bfd_mach_mips32, bfd_mach_mips32_4k,
- bfd_mach_mips64.
-
-2001-08-31 Andreas Jaeger <aj@suse.de>
-
- * tic54x-opc.c: Add default initializers to avoid warnings.
-
- * arc-opc.c: Include "sysdep.h" to get stdio.h as include file.
- * arc-ext.c: Likewise.
-
-2001-08-28 matthew green <mrg@redhat.com>
-
- * ppc-opc.c (icbt): Order correctly.
-
-2001-08-27 David Edelsohn <dje@watson.ibm.com>
- Torbjorn Granlund <tege@swox.com>
-
- * ppc-opc.c (DS): Add PPC_OPERAND_DS flag.
- (LS): Define.
- (insert_ds): Complain if not a multiple of 4.
- (XSYNC): Define.
- (XSYNC_MASK): Define.
- (powerpc_opcodes): Add "slbmte", "lwsync", "ptesync", "slbmfev",
- "slbmfee". Modify "sync" to use XSYNC_MASK and LS.
-
-2001-08-26 Andreas Jaeger <aj@suse.de>
-
- * h8500-opc.h: Add default initializers to h8500_table to shut up
- GCC warnings.
-
-2001-08-25 Andreas Jaeger <aj@suse.de>
-
- * tic54x-dis.c: Add unused attributes where needed.
-
- * z8k-dis.c (output_instr): Add unused attribute.
-
- * h8300-dis.c: Add missing prototypes.
- (bfd_h8_disassemble): Make static.
-
- * cris-dis.c: Add missing prototype.
- * h8500-dis.c: Likewise.
- * m68hc11-dis.c: Likewise.
- * pj-dis.c: Likewise.
- * tic54x-dis.c: Likewise.
- * v850-dis.c: Likewise.
- * vax-dis.c: Likewise.
- * w65-dis.c: Likewise.
- * z8k-dis.c: Likewise.
-
- * d10v-dis.c: Add missing prototype.
- (dis_long): Remove unused variable.
- (dis_2_short): Likewise.
-
- * sh-dis.c: Add missing prototypes.
- * v850-opc.c: Likewise.
- Add unused attributes where needed.
-
- * ns32k-dis.c: Add missing prototypes.
- (bit_extract_simple): Remove unused variable.
-
-2001-08-23 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * opcodes/s390-opc.c: Add "low or high" and "not low or high"
- branch instructions for gcc 3.0.
- * opcodes/s390-opc.txt: Likewise.
-
-2001-08-21 Andreas Jaeger <aj@suse.de>
-
- * i960-dis.c: Add parameters for prototypes
- (ctrl): Add unused attributes.
- (cobr): Likewise.
- (put_abs): Likewise.
-
- * mips-dis.c: Add missing prototypes.
- * a29k-dis.c: Likewise.
- * arc-dis.c: Likewise.
- * ia64-opc.c: Likewise.
-
- * s390-dis.c: Add missing prototypes.
- (init_disasm): Remove unused attribute since the parameter is
- used.
-
-2001-08-16 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * mips-opc.c (M1): Define. Reformatted Code.
- (mips_builtin_opcodes): Added performance counter opcodes mfpc, mfps,
- mtps, mtps. Typo.
-
-2001-08-16 Jonathan Larmour <jlarmour@redhat.com>
-
- * mips-opc.c: R3900s can support all branch likely INSN_MACROs where
- the corresponding non-likely insn is in MIPS I.
-
-2001-08-13 Kazu Hirata <kazu@hxi.com>
-
- * mcore-dis.c: Fix formatting.
- * mips-dis.c: Likewise.
- * pj-dis.c: Likewise.
- * z8k-dis.c: Likewise.
-
-2001-08-12 Richard Henderson <rth@redhat.com>
-
- * cgen-ibld.in (extract_normal): Match type of VALUE and MASK
- to *VALUEP. Regenerate all cgen files.
-
-2001-08-10 Richard Sandiford <rsandifo@redhat.com>
-
- * mips-dis.c (print_insn_mips): Remove OPCODE_IS_MEMBER's gp32
- argument.
- * mips-opc.c (G6): Undefine.
- (mips_builtin_opcodes): Remove gp32 entry for "move". Add macro
- as the first "move" alternative.
-
-2001-08-10 Andreas Jaeger <aj@suse.de>
-
- * configure.in: Add -Wstrict-prototypes and -Wmissing-prototypes
- to build warnings.
- * configure: Regenerate.
-
-2001-08-10 Alan Modra <amodra@bigpond.net.au>
-
- * ppc-opc.c: Revert 2001-08-08.
-
-2001-08-09 Alan Modra <amodra@bigpond.net.au>
-
- * dis-buf.c (generic_strcat_address): Add missing prototype.
- #if 0 the functions as it is unused.
-
-2001-08-08 Alan Modra <amodra@bigpond.net.au>
-
- 1999-10-25 Torbjorn Granlund <tege@swox.com>
- * ppc-opc.c: Include "bfd.h".
- (powerpc_operands): Add new field for reloc type.
-
-2001-07-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * mips-dis.c (print_insn_arg): Don't use software integer registers
- for coprocessor registers.
- (get_mips_isa): Removed.
- (is_newabi): New function, checks if NewABI is used.
- (_print_insn_mips): Get distinction between old ABI and new ABI right.
-
-2001-08-01 Christian Groessler <cpg@aladdin.de>
-
- * z8kgen.c: Fixed indentation of opt[] array. Include stdio.h to
- get stderr definition.
- (internal, gas): Removed warnings.
- (gas): Create a correct final entry for created array.
- * z8k-opc.h: Recreated with new z8kgen.
-
-2001-07-28 Kazu Hirata <kazu@hxi.com>
-
- * i386-dis.c: Fix formatting.
-
-2001-07-28 Matthias Kramm <kramm@quiss.org>
-
- * i386-dis.c: Change formatting conventions for architecture
- i386:intel to better match the format of various intel i386
- assemblers, like nasm, tasm or masm.
-
-2001-07-24 Alan Modra <amodra@bigpond.net.au>
-
- * Makefile.am: Update dependencies with "make dep-am".
- * Makefile.in: Regenerate
-
-2001-07-24 Kazu Hirata <kazu@hxi.com>
-
- * alpha-dis.c: Fix formatting.
- * cris-dis.c: Likewise.
- * d10v-dis.c: Likewise.
- * d30v-dis.c: Likewise.
- * m10300-dis.c: Likewise.
- * tic54x-dis.c: Likewise.
-
-2001-07-23 Kazu Hirata <kazu@hxi.com>
-
- * m68k-dis.c: Fix formatting.
- * pj-dis.c: Likewise.
- * s390-dis.c: Likewise.
- * z8k-dis.c: Likewise.
-
-2001-07-21 Chris Demetriou <cgd@broadcom.com>
-
- * mips-opc.c (mips_builtin_opcodes): Sort c.le.s and c.lt.s
- into the rest of the surrounding definitions.
-
-2001-07-18 Alan Modra <amodra@bigpond.net.au>
-
- * i386-dis.c (grps): Print l or w suffix, and require mem modrm
- for lgdt, lidt, sgdt, sidt.
-
-2001-07-13 Philip Blundell <philb@gnu.org>
-
- * arm-dis.c (print_insn_arm): Use decimal for offsets in LDR/STR.
-
-2001-07-12 Jeff Johnston <jjohnstn@redhat.com>
-
- * cgen-asm.in: Include "xregex.h" always to enable the libiberty
- regex support.
- (@arch@_cgen_build_insn_regex): New routine from Graydon.
- (@arch@_cgen_assemble_insn): Add Graydon's code to use regex
- to verify if it is worth parsing the insn as insn "x". Also update
- error message when insn is not a recognized format of the insn vs
- when the insn is completely unrecognized.
-
-2001-07-11 Frank Ch. Eigler <fche@redhat.com>
-
- * cgen-dis.in (print_insn): Use cgen_get_insn_value instead of
- bfd_get_bits.
- * cgen-opc.c (cgen_get_insn_value, cgen_put_insn_value): Respect
- non-zero CGEN_CPU_DESC->insn_chunk_bitsize.
-
-2001-07-09 Andreas Jaeger <aj@suse.de>, Karsten Keil <kkeil@suse.de>
-
- * i386-dis.c (set_op): Handle 64 bit and 32 bit mode.
- (OP_J): Use bfd_vma for mask to work properly with 64 bits.
- (op_address,op_riprel): Use bfd_vma to handle 64 bits.
-
-2001-07-05 Ben Elliston <bje@redhat.com>
-
- * Makefile.am (CPUDIR): Define.
- (stamp-m32r): Update dependencies.
- (stamp-fr30): Ditto.
- (stamp-openrisc): Ditto.
- * Makefile.in: Regenerate.
-
-2001-07-03 Zoltan Hidvegi <hzoli@hzoli.2y.net>
-
- * ppc-opc.c: Fix encoding of 'clf' instruction.
-
-2001-06-30 Geoffrey Keating <geoffk@redhat.com>
-
- * cgen-ibld.in (insert_normal): Support CGEN_IFLD_SIGN_OPT.
-
-2001-06-28 Geoffrey Keating <geoffk@redhat.com>
-
- * cgen-asm.c (cgen_parse_keyword): Allow any first character.
- * cgen-opc.c (cgen_keyword_add): Ignore special first
- character when building nonalpha_chars field.
-
-2001-06-24 Ben Elliston <bje@redhat.com>
-
- * m88k-dis.c: Format to conform to GNU coding standards.
-
-2001-06-23 Andreas Jaeger <aj@suse.de>
-
- * disassemble.c (disassembler_usage): Add unused attribute.
-
-2001-06-22 Eric Christopher <echristo@redhat.com>
-
- * mips-opc.c: Move prefx to start of the table.
-
-2001-06-22 Stacey Sheldon <ssheldon@Catena.com>
-
- * arc-opc.c (insert_st_syntax): Fix over-optimisation of ST
- instruction.
-
-2001-06-22 Pauli <pauli@moreton.com.au>
-
- * m68k-opc.c: Add wdebug instruction.
-
-2001-06-15 Aldy Hernandez <aldyh@redhat.com>
-
- * m10300-opc.c (mn10300_opcodes): Change opcode for AM33 subc.
-
-2001-06-14 Geoffrey Keating <geoffk@redhat.com>
-
- * cgen-asm.c (cgen_parse_keyword): When looking for the
- boundaries of a keyword, allow any special characters
- that are actually in one of the allowed keyword.
- * cgen-opc.c (cgen_keyword_add): Add any special characters
- to the nonalpha_chars field.
-
-2001-06-12 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * s390-opc.c: Add lgh instruction.
- * s390-opc.txt: Likewise.
-
-2001-06-11 Alan Modra <amodra@bigpond.net.au>
-
- * i386-dis.c: Group function prototypes in one place.
- (FLOATCODE): Redefine as 1.
- (USE_GROUPS): Redefine as 2.
- (USE_PREFIX_USER_TABLE): Redefine as 3.
- (X86_64_SPECIAL): Define as 4.
- (GRP1b..GRPAMD): Move USE_GROUPS to bytecode1, index to bytecode2.
- (PREGRP0..PREGRP26): Similarly with USE_PREFIX_USER_TABLE.
- (dis386_att, dis386_intel, disx86_64_att, disx86_64_intel): Delete.
- (dis386): New table combining above four tables.
- (dis386_twobyte_att, dis386_twobyte_intel): Delete.
- (dis386_twobyte): New table combining above two tables.
- (x86_64_table): New table to handle x86_64.
- (X86_64_0): Define.
- (float_mem_att, float_mem_intel): Delet.
- (float_mem): New table combining above two tables.
- (print_insn_i386): Modify for above.
- (dofloat): Likewise.
- (putop): Handle '{', '|' and '}' to select alternative mnemonics.
- Return 0 on success, 1 if no valid alternative.
- (putop <case 'F'>, <case 'H'>): Print nothing for intel_syntax.
- (putop <case 'T'>): Move to case 'U', and share case 'Q' code.
- (putop <case 'I'>): Move to case 'T', and share case 'P' code.
- (OP_REG <case rAX_reg .. rDI_reg>): Handle as for eAX_reg .. eDI_reg
- if not 64-bit mode.
- (OP_I <case q_mode>): Handle as for v_mode if not 64-bit mode.
- (OP_I64): If not 64-bit mode, call OP_I.
- OP_OFF64): If not 64-bit mode, call OP_OFF.
- (OP_ST, OP_STi, OP_SEG, OP_DIR, OP_OFF, OP_OFF64, OP_MMX): Rename
- 'ignore'/'ignored' to 'bytemode'.
-
-2001-06-10 Alan Modra <amodra@bigpond.net.au>
-
- * configure.in: Sort 'ta' case statement.
- * configure: Regenerate.
-
- * i386-dis.c (dis386_att): Add 'H' to conditional branch and
- loop,jcxz insns.
- (disx86_64_att): Likewise.
- (dis386_twobyte_att): Likewise.
- (print_insn_i386): Don't print branch hints as a prefix.
- (putop): 'H' macro prints branch hints.
- (get64): Kill compile warnings.
-
-2001-06-09 Alexandre Oliva <aoliva@redhat.com>
-
- * sh-opc.h (sh_table): Don't use empty initializers.
-
-2001-06-06 Christian Groessler <cpg@aladdin.de>
-
- * z8k-dis.c: Fix formatting.
- (unpack_instr): Remove unused cases in switch statement. Add
- safety abort() in default case.
- (unparse_instr): Add safety abort() in default case.
-
-2001-06-06 Peter Jakubek <pjak@snafu.de>
-
- * m68k-dis.c (print_insn_m68k): Fix typo.
- * m68k-opc.c (m68k_opcodes): Correct allowed operands for
- mcf (ColdFire) div, rem and moveb instructions.
-
-2001-06-06 Alan Modra <amodra@bigpond.net.au>
-
- * i386-dis.c (cond_jump_flag, loop_jcxz_flag): Define.
- (cond_jump_mode, loop_jcxz_mode): Define.
- (dis386_att): Add cond_jump_flag and loop_jcxz_flag as
- appropriate, and 'F' suffix to loop insns.
- (disx86_64_att): Likewise.
- (dis386_twobyte_att): Likewise.
- (print_insn_i386): Don't output addr prefix for loop, jcxz insns.
- Output data size prefix for long conditional jumps. Output cs and
- ds branch hints.
- (putop): Handle 'F', and mark PREFIX_ADDR used for case 'E'.
- (OP_J): Don't make PREFIX_DATA used.
-
-2001-06-04 Alexandre Oliva <aoliva@redhat.com>
-
- * sh-opc.h (sh_table): Complete last element entry to avoid
- compiler warning.
-
-2001-05-16 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * mips-dis.c (mips_isa_type): Add MIPS r12k support.
-
-2001-05-23 Alan Modra <amodra@one.net.au>
-
- * arc-opc.c: Whitespace changes.
-
-2001-05-18 Hans-Peter Nilsson <hp@axis.com>
-
- * cris-opc.c (cris_spec_regs): Add missing initializer field for
- last element.
-
-2001-05-15 Frank Ch. Eigler <fche@redhat.com>
-
- * cgen-dis.in (extract_normal): Complete support for min<base case.
-
-2001-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
-
- * mips-dis.c (INSNLEN): Rename MAXLEN.
- (std_reg_names): Replace by mips32_reg_names and mips64_reg_names.
- (print_insn_arg): Remove $ prefix of register names.
- (set_mips_isa_type): Remove.
- (mips_isa_type): New function.
- (get_mips_isa): New Function.
- (print_insn_mips): Rename _print_insn_mips.
- (_print_insn_mips): New function, contains code which was
- duplicated in print_insn_big_mips and print_insn_little_mips.
- (print_insn_big_mips): Moved code to _print_insn_mips.
- (print_insn_little_mips): Likewise.
- (print_mips16_insn_arg): Remove $ prefix of register names.
- Print error message before abort.
-
-2001-05-14 J.T. Conklin <jtc@redback.com>
-
- * ppc-opc.c (powerpc_opcodes): Fixed extended opcode field of
- simplified mnemonics used for setting PPC750-specific special
- purpose registers.
+ 2004-03-08 Nick Clifton <nickc@redhat.com>
+ * po/de.po: Updated German translation.
-2001-05-12 H.J. Lu <hjl@gnu.org>
+ 2004-02-26 Andrew Stubbs <andrew.stubbs@superh.com>
+ * sh-opc.h: Move fsca and fsrra instructions from sh4a to sh4.
+ Also correct mistake in the comment.
- * i386-dis.c (print_insn_i386): Always set `mod', `reg' and
- `rm'.
+ 2004-02-26 Andrew Stubbs <andrew.stubbs@superh.com>
+ * sh-dis.c (print_insn_sh): Add REG_N_D nibble type to
+ ensure that double registers have even numbers.
+ Add REG_N_B01 for nn01 (binary 01) nibble to ensure
+ that reserved instruction 0xfffd does not decode the same
+ as 0xfdfd (ftrv).
+ * sh-opc.h: Add REG_N_D nibble type and use it whereever
+ REG_N refers to a double register.
+ Add REG_N_B01 nibble type and use it instead of REG_NM
+ in ftrv.
+ Adjust the bit patterns in a few comments.
-2001-05-12 Peter Targett <peter.targett@arccores.com>
+2004-04-08 Alan Modra <amodra@bigpond.net.au>
- * arc-opc.c (arc_reg_names): Correct attribute for lp_count
- register to r/w. Formatting fixes throughout file.
+ Apply from mainline.
+ 2004-02-25 Aldy Hernandez <aldyh@redhat.com>
+ * ppc-opc.c (powerpc_opcodes): Change mask for dcbt and dcbtst.
-2001-05-12 Alan Modra <amodra@one.net.au>
+ 2004-02-20 Aldy Hernandez <aldyh@redhat.com>
+ * ppc-opc.c (powerpc_opcodes): Move mfmcsrr0 before mfdc_dat.
- * i386-dis.c (prefix_user_table): Correct movq2dq, movdq2q, and
- movq operands.
- (twobyte_has_modrm): Update table.
- (need_modrm): Give it file scope.
- (MODRM_CHECK): Define.
- (dofloat): Use MODRM_CHECK.
- (OP_E): Likewise.
- (OP_EM): Likewise.
- (OP_EX): Likewise.
+ 2004-02-20 Aldy Hernandez <aldyh@redhat.com>
+ * ppc-opc.c (powerpc_opcodes): Add m*ivor35.
-2001-05-07 Frank Ch. Eigler <fche@redhat.com>
+ 2004-02-20 Aldy Hernandez <aldyh@redhat.com>
+ * ppc-opc.c (powerpc_opcodes): Add mfivor32, mfivor33, mfivor34,
+ mtivor32, mtivor33, mtivor34.
- * cgen-dis.in (default_print_insn): Tolerate min<base instructions
- even at end of a section.
- * cgen-ibld.in (extract_normal): Tolerate min!=base!=max instructions
- by ignoring precariously-unpacked insn_value in favor of raw buffer.
+ 2004-02-19 Aldy Hernandez <aldyh@redhat.com>
+ * ppc-opc.c (powerpc_opcodes): Add mfmcar.
-2001-05-03 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+2004-03-15 Aldy Hernandez <aldyh@redhat.com>
+
+ * ppc-opc.c (powerpc_opcodes): Add BOOKE versions of mfsprg.
- * disassemble.c (disassembler_usage): Remove unused attribute.
+2004-03-16 Alan Modra <amodra@bigpond.net.au>
-2001-05-04 Frank Ch. Eigler <fche@redhat.com>
+ * ppc-dis.c (print_insn_powerpc): Don't print tabs. Handle
+ PPC_OPERANDS_GPR_0.
+ * ppc-opc.c (RA0): Define.
+ (RAQ, RAL, RAM, RAS, RSQ, RTQ, RSO): Use PPC_OPERAND_GPR_0.
+ (RAOPT): Rename from RAO. Update all uses.
+ (powerpc_opcodes): Use RA0 as appropriate.
- * m32r-dis.c, -asm.c, -ibld.c: Regenerated with disassembler fixes.
+2004-03-15 Alan Modra <amodra@bigpond.net.au>
-2001-05-04 Frank Ch. Eigler <fche@redhat.com>
+ * sparc-dis.c (print_insn_sparc): Update getword prototype.
- * cgen-dis.in (print_insn): Remove call to read_insn. Instead,
- assume incoming buffer already has the base insn loaded. Handle
- smaller-than-base instructions for variable-length case.
+2004-03-13 Alan Modra <amodra@bigpond.net.au>
-2001-05-04 Alan Modra <amodra@one.net.au>
+ Apply the following patches from mainline
+ 2004-03-12 Michal Ludvig <mludvig@suse.cz>
+ * i386-dis.c (GRPPLOCK): Delete.
+ (grps): Delete GRPPLOCK entry.
- * i386-dis.c (Ev, Ed): Remove duplicate define.
- (Gd): Define.
- (XS): Define.
- (OP_XS): New function.
- (dis386_twobyte_att): Correct pinsrw, pextrw, pmovmskb, and
- movmskp operands.
- (dis386_twobyte_intel): Likewise.
- (prefix_user_table): Use MS for maskmovq operand.
+ 2004-03-12 Alan Modra <amodra@bigpond.net.au>
+ * i386-dis.c (OP_M, OP_0f0e, OP_0fae, NOP_Fixup): New functions.
+ (M, Mp): Use OP_M.
+ (None, PADLOCK_SPECIAL, PADLOCK_0): Delete.
+ (GRPPADLCK): Define.
+ (dis386): Use NOP_Fixup on "nop".
+ (dis386_twobyte): Use GRPPADLCK on opcode 0xa7.
+ (twobyte_has_modrm): Set for 0xa7.
+ (padlock_table): Delete. Move to..
+ (grps): ..here, using OP_0f07. Use OP_Ofae on lfence, mfence
+ and clflush.
+ (print_insn): Revert PADLOCK_SPECIAL code.
+ (OP_E): Delete sfence, lfence, mfence checks.
-2001-04-27 Johan Rydberg <jrydberg@opencores.org>
+ 2004-03-12 Jakub Jelinek <jakub@redhat.com>
+ * i386-dis.c (grps): Use INVLPG_Fixup instead of OP_E for invlpg.
+ (INVLPG_Fixup): New function.
+ (PNI_Fixup): Remove ATTRIBUTE_UNUSED from sizeflag.
- * Makefile.am: Add OpenRISC target.
- * Makefile.in: Regenerated.
+ 2004-03-12 Alan Modra <amodra@bigpond.net.au>
+ * i386-dis.c (grps): Use clflush by default for 0x0fae/7.
+ (OP_E): Twiddle clflush to sfence here.
- * disassemble.c (disassembler): Recognize the OpenRISC disassembly.
+2004-03-12 Michal Ludvig <mludvig@suse.cz>
- * configure.in (bfd_openrisc_arch): Add target.
- * configure: Regenerated.
+ * i386-dis.c (PADLOCK_SPECIAL, PADLOCK_0): New defines.
+ (dis386_twobyte): Opcode 0xa7 is PADLOCK_0.
+ (padlock_table): New struct with PadLock instructions.
+ (print_insn): Handle PADLOCK_SPECIAL.
- * openrisc-asm.c: New file.
- * openrisc-desc.c: Likewise.
- * openrisc-desc.h: Likewise.
- * openrisc-dis.c: Likewise.
- * openrisc-ibld.c: Likewise.
- * openrisc-opc.c: Likewise.
- * openrisc-opc.h: Likewise.
+2004-02-10 Petko Manolov <petkan@nucleusys.com>
-2001-04-24 Christian Groessler <cpg@aladdin.de>
+ * arm-opc.h Maverick accumulator register opcode fixes.
- * z8k-dis.c: add names of control registers (ctrl_names);
- (seg_length): provides instruction length fixup for segmented
- mode; (unpack_instr): correctly handle ARG_DISP16, ARG_DISP12,
- CLASS_0DISP7, CLASS_1DISP7, CLASS_DISP8 and CLASS_PR cases;
- (unparse_intr): handle CLASS_PR, print addresses without '#'
- * z8k-opc.h: re-created with new z8kgen
- * z8kgen.c: merged in fixes which were in existing z8k-opc.h; new
- entries for ldctl/ldctlb instruction
+2004-02-13 Ben Elliston <bje@wasabisystems.com>
-2001-04-06 Andreas Jaeger <aj@suse.de>
-
- * i386-dis.c: Add ffreep instruction.
-
-2001-03-30 Alexandre Oliva <aoliva@redhat.com>
-
- * ppc-opc.c (insert_mbe): Shift mask initializer as long.
-
-2001-03-24 Alan Modra <alan@linuxcare.com.au>
-
- * i386-dis.c (PREGRP25): Define.
- (dis386_twobyte_att): Use here in place of "movntq" entry.
- (dis386_twobyte_intel): Likewise.
- (prefix_user_table): Add PREGRP25 entry for "movntq" and "movntdq".
- (PREGRP26): Define.
- (dis386_twobyte_att): Use here.
- (dis386_twobyte_intel): Likewise.
- (prefix_user_table): Add PREGRP26 entry for "punpcklqdq".
- (prefix_user_table <maskmovdqu>): XM operand, not MX.
- (prefix_user_table): Cosmetic changes to "bad" entries.
-
-2001-03-23 Nick Clifton <nickc@redhat.com>
-
- * mips-opc.c: Remove extraneous whitespace.
- * mips-dis.c: Remove extraneous whitespace.
-
-2001-03-22 Ben Elliston <bje@redhat.com>
-
- * cgen-asm.in (@arch@_cgen_assemble_insn): Move tmp_errmsg
- declaration inside CGEN_VERBOSE_ASSEMBLER_ERRORS conditional.
- * cgen-ibld.in (put_insn_int_value): Mark cd parameter as unused
- to allay a compiler warning.
-
-2001-03-22 Alan Modra <alan@linuxcare.com.au>
-
- * i386-dis.c (dis386_twobyte_att): Add entries for paddq, psubq.
- (dis386_twobyte_intel): Likewise.
- (twobyte_has_modrm): Set entry for paddq, psubq.
-
-2001-03-20 Patrick Macdonald <patrickm@redhat.com>
-
- * cgen-dis.in (print_insn_@arch@): Add support for target machine
- determination via CGEN_COMPUTE_MACH.
- * fr30-desc.c: Regenerate.
- * fr30-dis.c: Regenerate.
- * fr30-opc.h: Regenerate.
- * m32r-desc.c: Regenerate.
- * m32r-dis.c: Regenerate.
- * m32r-opc.h: Regenerate.
- * m32r-opinst.c: Regenerate.
-
-2001-03-20 H.J. Lu <hjl@gnu.org>
-
- * configure.in: Remove the redundent AC_ARG_PROGRAM.
- * configure: Rebuild.
-
-2001-03-19 Jim Wilson <wilson@redhat.com>
-
- * ia64-gen.c (fetch_insn_class): If xsect, then ignore comment and
- notestr if larger than xsect.
- (in_class): Handle format M5.
- * ia64-asmtab.c: Regnerate.
-
-2001-03-19 John David Anglin <dave@hiauly1.hia.nrc.ca>
-
- * vax-dis.c (print_insn_vax): Only fetch two bytes if the info buffer
- has more than one byte left to read.
-
-2001-03-16 Martin Schwidefsky <schwidefsky@de.ibm.com>
-
- * s390-opc.c: Add new opcodes. Smooth out formatting.
- * s390-opc.txt: Add new opcodes.
-
-2001-03-06 Nick Clifton <nickc@redhat.com>
-
- * arm-dis.c (print_insn_thumb): Compute destination address
- of BLX(1) instruction by taking bit 1 from PC and not from bit
- 0 of the offset.
-
-2001-03-06 Igor Shevlyakov <igor@windriver.com>
-
- * m68k-dis.c (print_insn_m68k): Recognize Coldfire CPUs
- so command line switches will work.
-
-2001-03-05 Dave Brolley <brolley@redhat.com>
-
- * fr30-asm.c: Regenerate.
- * fr30-desc.c: Regenerate.
- * fr30-desc.h: Regenerate.
- * fr30-dis.c: Regenerate.
- * fr30-ibld.c: Regenerate.
- * fr30-opc.c: Regenerate.
- * fr30-opc.h: Regenerate.
- * m32r-asm.c: Regenerate.
- * m32r-desc.c: Regenerate.
- * m32r-desc.h: Regenerate.
* m32r-dis.c: Regenerate.
- * m32r-ibld.c: Regenerate.
- * m32r-opc.c: Regenerate.
- * m32r-opc.h: Regenerate.
- * m32r-opinst.c: Regenerate.
-
-2001-02-28 Igor Shevlyakov <igor@windriver.com>
-
- * m68k-opc.c: fix cpushl according to Motorola. Enable
- bunch of instructions for Coldfire 5407 and add all new.
-
-2001-02-27 Alan Modra <alan@linuxcare.com.au>
-
- * configure.in (BFD_VERSION): Do without grep.
- * configure: Regenerate.
- * Makefile.am: Run "make dep-am".
- * Makefile.in: Regenerate.
-
-2001-02-23 David Mosberger <davidm@hpl.hp.com>
-
- * ia64-opc-a.c: Add missing pseudo-ops for "cmp" and "cmp4".
- * ia64-asmtab.c: Regenerate.
-
-2001-02-21 David Mosberger <davidm@hpl.hp.com>
-
- * ia64-opc-d.c (ia64_opcodes_d): Break the "add" pattern into two
- separate variants: one for IMM22 and the other for IMM14.
- * ia64-asmtab.c: Regenerate.
-
-2001-02-21 Greg McGary <greg@mcgary.org>
-
- * cgen-opc.c (cgen_get_insn_value): Add missing `return'.
-
-2001-02-20 H.J. Lu <hjl@gnu.org>
-
- * Makefile.am (ia64-ic.tbl): Remove the target.
- (ia64-raw.tbl): Likewise.
- (ia64-waw.tbl): Likewise.
- (ia64-war.tbl): Likewise.
- (ia64-asmtab.c): Generate it in the source directory.
- * Makefile.in: Regenerated.
-
-2001-02-18 lars brinkhoff <lars@nocrew.org>
-
- * Makefile.am: Add PDP-11 target.
- * configure.in: Likewise.
- * disassemble.c: Likewise.
- * pdp11-dis.c: New file.
- * pdp11-opc.c: New file.
-
-2001-02-14 Jim Wilson <wilson@redhat.com>
-
- * ia64-ic.tbl: Update from Intel. Add setf to fr-writers.
- * ia64-asmtab.c: Regenerate.
-
-Mon Feb 12 17:41:26 CET 2001 Jan Hubicka <jh@suse.cz>
-
- * i386-dis.c (prefix_user_t): Add 'Y' to SSE ineger converison
- instructions.
- (putop): Handle 'Y'
-2001-02-11 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+2004-01-27 Michael Snyder <msnyder@redhat.com>
- * mips-dis.c (print_insn_arg): Use top four bits of the address of
- the following instruction not of the jump itself for the jump
- target.
- (print_mips16_insn_arg): Likewise.
+ * sh-opc.h (sh_table): "fsrra", not "fssra".
-2001-02-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
+2004-01-23 Andrew Over <andrew.over@cs.anu.edu.au>
- * Makefile.am (stamp-lib): ranlib the libopcodes.a in the build
- directory.
- * Makefile.in: Regenerate.
-
-2001-02-09 Schwidefsky <schwidefsky@de.ibm.com>
-
- * Makefile.am: Add linux target for S/390.
- * Makefile.in: Likewise.
- * configure.in: Likewise.
- * disassemble.c: Likewise.
- * s390-dis.c: New file.
- * s390-mkopc.c: New file.
- * s390-opc.c: New file.
- * s390-opc.txt: New file.
-
-2001-02-05 Jim Wilson <wilson@redhat.com>
-
- * ia64-asmtab.c: Revert 2000-12-16 change.
-
-2001-02-02 Patrick Macdonald <patrickm@redhat.com>
-
- * fr30-desc.h: Regenerate with CGEN_MAX_SYNTAX_ELEMENTS.
- * m32r-desc.h: Regenerate.
-
-Thu Feb 1 16:29:06 MET 2001 Jan Hubicka <jh@suse.cz>
-
- * i386-dis.c (dis386_att, grps): Use 'T' for push/pop
- (putop): Handle 'T', alphabetize order, fix 'I' handling in Intel syntax
-
-2001-01-14 Alan Modra <alan@linuxcare.com.au>
-
- * hppa-dis.c (print_insn_hppa): Handle '>' and '<' arg types.
-
-2001-01-13 Nick Clifton <nickc@redhat.com>
-
- * disassemble.c: Remove spurious white space.
+ * sparc-opc.c (fdtox, fstox, fqtox, fxtod, fxtos, fxtoq): Tighten
+ contraints.
-Sat Jan 13 01:48:24 MET 2001 Jan Hubicka <jh@suse.cz>
+2004-01-19 Andrew Over <andrew.over@cs.anu.edu.au>
- * i386-dis.c (dis386_att, disx86_64_att): Fix ret, lret and iret
- templates.
+ * sparc-opc.c (sparc_opcodes) <f[dsq]tox, fxto[dsq]>: Fix args.
-2001-01-11 Peter Targett <peter.targett@arccores.com>
+2004-01-19 Alan Modra <amodra@bigpond.net.au>
- * configure.in: Add arc-ext.lo for bfd_arc_arch selection.
- * Makefile.am (C_FILES): Add arc-ext.c.
- (ALL_MACHINES) Add arc-ext.lo.
- (INCLUDES) Add opcode directory to list.
- New dependency entry for arc-ext.lo.
- * disassemble.c (disassembler): Correct call to
- arc_get_disassembler.
- * arc-opc.c: New update for ARC, including full base
- instructions for ARC variants.
- * arc-dis.h, arc-dis.c: New update for ARC, including
- extensibility functionality.
- * arc-ext.h, arc-ext.c: New files for handling extensibility.
+ * i386-dis.c (OP_E): Print scale factor on intel mode sib when not
+ 1. Don't print scale factor on AT&T mode when index missing.
-2001-01-10 Jan Hubicka <jh@suse.cz>
+2004-01-16 Alexandre Oliva <aoliva@redhat.com>
- * i386-dis.c (PREGRP15 - PREGRP24): New.
- (dis386_twobyt): Add SSE2 instructions.
- (twobyte_uses_SSE_prefix: Rename from ... ; add new SSE instructions.
- (twobyte_uses_f3_prefix): ... this one.
- (grps): Add SSE instructions.
- (prefix_user_table): Add two new slots; add SSE2 instructions.
- (print_insn_i386): Rename uses_f3_prefix to uses_SSE_prefix;
- Handle the REPNZ and Data16 prefixes as well; do proper lookup
- to prefix_user_table.
- (OP_E): Accept mfence and lfence as well.
- (OP_MMX): Data16 prefix turns MMX to SSE; support REX extensions.
- (OP_XMM): Support REX extensions.
- (OP_EM): Likewise.
- (OP_EX): Likewise.
+ * m10300-opc.c (mov): 8- and 24-bit immediates are zero-extended
+ when loaded into XR registers.
-2001-01-09 Nick Clifton <nickc@redhat.com>
+2004-01-14 Richard Sandiford <rsandifo@redhat.com>
- * arm-dis.c (print_insn): Set pc to zero for instructions with
- a reloc associated with them.
+ * frv-desc.h: Regenerate.
+ * frv-desc.c: Regenerate.
+ * frv-opc.c: Regenerate.
-2001-01-09 Jeff Johnston <jjohnstn@redhat.com>
+2004-01-13 Michael Snyder <msnyder@redhat.com>
- * cgen-asm.in (parse_insn_normal): Changed syn to be
- CGEN_SYNTAX_CHAR_TYPE. Changed all references to *syn
- as character to use CGEN_SYNTAX_CHAR macro and all comparisons
- to '\0' to use 0 instead.
- * cgen-dis.in (print_insn_normal): Ditto.
- * cgen-ibld.in (insert_insn_normal, extract_insn_normal): Ditto.
+ * sh-dis.c (print_insn_sh): Allocate 4 bytes for insn.
-2001-01-05 Jan Hubicka <jh@suse.cz>
+2004-01-09 Paul Brook <paul@codesourcery.com>
- * i386-dis.c: Add x86_64 support.
- (rex): New static variable.
- (REX_MODE64, REX_EXTX, REX_EXTY, REX_EXTZ): New constants.
- (USED_REX): New macro.
- (Ev, Ed, Rm, Iq, Iv64, Cm, Dm, Rm*, Ob64, Ov64): New macros.
- (OP_I64, OP_OFF64, OP_IMREG): New functions.
- (OP_REG, OP_OFF): Declare.
- (get64, get32, get32s): New functions.
- (r??_reg): New constants.
- (dis386_att): Change templates of instruction implicitly promoted
- to 64bit; change e?? to RMe?? for unwind RM byte instructions.
- (grps): Likewise.
- (dis386_intel): Likewise.
- (dixx86_64_att): New table based on dis386_att.
- (dixx86_64_intel): New table based on dis386_intel.
- (names64, names8rex): New global variable.
- (names32, names16): Add extended registers.
- (prefix_user_t): Recognize rex prefixes.
- (prefix_name): Print REX prefixes nicely.
- (op_riprel): New global variable.
- (start_pc): Set type to bfd_vma.
- (print_insn_i386): Detect the 64bit mode and use proper table;
- move ckprefix after initializing the buffer; output unused rex prefixes;
- output information about target of RIP relative addresses.
- (putop): Support 'O' and 'I'. Update handling of "P', 'Q', 'R' and 'S';
- (print_operand_value): New function.
- (OP_E, OP_G, OP_REG, OP_I, OP_J, OP_DIR, OP_OFF, OP_D): Add support for
- REX prefix and new modes.
- (get64, get32s): New.
- (get32): Return bfd_signed_vma type.
- (set_op): Initialize the op_riprel.
- * disassemble.c (disassembler): Recognize the x86-64 disassembly.
+ * arm-opc.h (arm_opcodes): Move generic mcrr after known
+ specific opcodes.
-2001-01-03 Richard Sandiford <r.sandiford@redhat.com>
-
- cgen-dis.in (read_insn): Use bfd_get_bits()
-
-2001-01-02 Richard Sandiford <rsandifo@redhat.com>
-
- * cgen-dis.c (hash_insn_array): Use bfd_put_bits().
- (hash_insn_list): Likewise
- * cgen-ibld.in (insert_1): Use bfd_put_bits() and bfd_get_bits().
- (extract_1): Use bfd_get_bits().
- (extract_normal): Apply sign extension to both extraction
- methods.
- * cgen-opc.c (cgen_get_insn_value): Use bfd_get_bits()
- (cgen_put_insn_value): Use bfd_put_bits()
-
-2000-12-28 Frank Ch. Eigler <fche@redhat.com>
-
- * cgen-asm.in (parse_insn_normal): Print better error message for
- instructions with missing operands.
-
-2000-12-21 Santeri Paavolainen <santtu@ssh.com>
-
- * cgen-opc.c: Include alloca.h if HAVE_ALLOCA_H is defined.
-
-2000-12-16 Nick Clifton <nickc@redhat.com>
+2004-01-07 Daniel Jacobowitz <drow@mvista.com>
+ * Makefile.am (libopcodes_la_DEPENDENCIES)
+ (libopcodes_la_LIBADD): Revert 2003-05-17 change. Add explanatory
+ comment about the problem.
* Makefile.in: Regenerate.
- * aclocal.m4: Regenerate.
- * config.in: Regenerate.
- * configure.in: Add spacing.
- * configure: Regenerate.
- * ia64-asmtab.c: Regenerate.
- * po/opcodes.pot: Regenerate.
-
-2000-12-12 Frank Ch. Eigler <fche@redhat.com>
-
- * cgen-asm.in (@arch@_cgen_assemble_insn): Prefer printing insert-time
- error messages over later parse-time ones.
-
-2000-12-12 Jim Wilson <wilson@redhat.com>
-
- * ia64-dis.c (print_insn_ia64): Cast away const on ia64_free_opcode
- argument.
- * ia64-gen.c (insert_deplist): Cast sizeof result to int.
- (print_dependency_table): Print NULL if semantics field not set.
- (insert_opcode_dependencies): Mark cmp parameter as unused.
- (print_main_table): Use fprintf_vma to print long long fields.
- (main): Mark argv paramter as unused. Convert to old style definition.
- * ia64-opc.c (ia64_find_dependency): Cast sizeof result to int.
- * ia64-asmtab.c: Regnerate.
-
-2000-12-09 Nick Clifton <nickc@redhat.com>
-
- * m32r-dis.c (print_insn): Prevent re-read of instruction from
- wrong address.
-
- * fr30-dis.c: Regenerate.
-
-2000-12-08 Peter Targett <peter.targett@arccores.com>
-
- * configure.in: Add arc-ext.lo for bfd_arc_arch selection.
- * Makefile.am (C_FILES): Add arc-ext.c.
- (ALL_MACHINES) Add arc-ext.lo.
- (INCLUDES) Add opcode directory to list.
- New dependency entry for arc-ext.lo.
- * disassemble.c (disassembler): Correct call to
- arc_get_disassembler.
- * arc-opc.c: New update for ARC, including full base
- instructions for ARC variants.
- * arc-dis.h, arc-dis.c: New update for ARC, including
- extensibility functionality.
- * arc-ext.h, arc-ext.c: New files for handling extensibility.
-
-2000-12-03 Chris Demetriou cgd@sibyte.com
-
- * mips-opc.c (mips_builtin_opcodes): Use the WR_HILO, RD_HILO,
- MOD_HILO, and MOD_LO macros.
-
- * mips-opc.c (M1, M2): Delete.
- (mips_builtin_opcodes): Remove all uses of M1.
-
- * mips-opc.c (mips_builtin_opcodes): Make the dmfc2 and dmtc2
- instructions take "G" format second operands and use the
- correct flags.
- There are mfc3 and mtc3 opcodes, so add dmfc3 and dmtc3 opcodes to
- match.
- Delete "sel" code operands from mfc1 and mtc1.
- Add MIPS64 opcode changes (dclo, dclz), and "sel" code variants
- for dm[ft]c[023].
-
-2000-12-03 Ed Satterthwaite ehs@sibyte.com and
- Chris Demetriou cgd@sibyte.com
-
- * mips-opc.c (mips_builtin_opcodes): Finish additions
- for MIPS32 support, and clean up existing entries for
- aesthetics, consistency with the MIPS32 ISA, and
- with consistency the rest of the table.
-
-2000-12-01 Nick Clifton <nickc@redhat.com>
-
- * mips16-opc.c (mips16_opcodes): Add initialiser for membership
- field.
-
-2000-12-01 Chris Demetriou <cgd@sibyte.com>
-
- mips-dis.c (print_insn_arg): Handle new 'U' and 'J' argument
- specifiers. Update 'B' for new constant names, and remove
- 'm'.
- mips-opc.c (mips_builtin_opcodes): Place "pref" and "ssnop"
- near the top of the array, so they are disassembled properly.
- Enable "ssnop" for MIPS32. Add "break" variant with 20 bit
- code for MIPS32. Update "clo" and "clz" to use 'U' operand
- specifier. Add 'H' format specifier variants for "mfc1,"
- "mfc2," "mfc3," "mtc1," "mtc2," and "mtc3" for MIPS32. Update
- MIPS32 "sdbbp" to use 'B' operand specifier. Add MIPS32
- "wait" variant which uses 'J' operand specifier.
-
- * mips-dis.c (set_mips_isa_type): Update to use
- CPU_UNKNOWN and ISA_* constants. Add bfd_mach_mips32 case.
- Replace bfd_mach_mips4K with bfd_mach_mips32_4k case.
- * mips-opc.c (I32): New constant for instructions added in
- MIPS32.
- (P4): Delete.
- (mips_builtin_opcodes) Replace all uses of P4 with I32.
-
- * mips-dis.c (set_mips_isa_type): Add cases for
- bfd_mach_mips5 and bfd_mach_mips64.
- * mips-opc.c (I64): New definitions.
-
- * mips-dis.c (set_mips_isa_type): Add case for
- bfd_mach_mips_sb1.
-
-2000-11-28 Hans-Peter Nilsson <hp@bitrange.com>
-
- * sh-dis.c (print_insn_ddt): Make insn_x, insn_y unsigned.
- (print_insn_ppi): Make nib1, nib2, nib3 unsigned.
- Initialize variable dc to NULL.
- (print_insn_shx): Remove unused label d_reg_n.
-
-2000-11-24 Nick Clifton <nickc@redhat.com>
-
- * arm-opc.h: Add new opcode formatting parameter 'B'.
- (arm_opcodes): Add XScale, v5, and v5te instructions.
- (thumb_opcodes): Add v5t instructions.
-
- * arm-dis.c (print_insn_arm): Handle new 'B' format
- parameter.
- (print_insn_thumb): Decode BLX(1) instruction.
-
-2000-11-21 Chris Demetriou <cgd@sibyte.com>
-
- * mips-opc.c: Fix file header comment.
-
-2000-11-14 Hans-Peter Nilsson <hp@axis.com>
-
- * cris-dis.c (cris_get_disassembler): If abfd is NULL, return
- print_insn_cris_with_register_prefix.
-
-2000-11-11 Alexandre Oliva <aoliva@redhat.com>
-
- * sh-opc.h: The operand of `mov.w r0, (<disp>,GBR)' is IMM1, not 0.
-
-2000-11-07 Matthew Green <mrg@redhat.com>
-
- * cgen-dis.in (print_insn): All insns which can fit into insn_value
- must be loaded there in their entirety.
-
-2000-10-20 Jakub Jelinek <jakub@redhat.com>
-
- * sparc-dis.c (v9a_asr_reg_names): Add v9b ASRs.
- (compute_arch_mask): Add v8plusb and v9b machines.
- (print_insn_sparc): siam mode decoding, accept ASRs up to 25.
- * sparc-opc.c: Support for Cheetah instruction set.
- (prefetch_table): Add #invalidate.
-
-2000-10-16 Nick Clifton <nickc@redhat.com>
-
- * mcore-dis.c (imsk): Change mask for OC to 0xFE00.
-
-2000-10-06 Dave Brolley <brolley@redhat.com>
-
- * fr30-desc.h: Regenerate.
- * m32r-desc.h: Regenerate.
- * m32r-ibld.c: Regenerate.
-
-2000-10-05 Jim Wilson <wilson@redhat.com>
-
- * ia64-ic.tbl: Update from Intel.
- * ia64-asmtab.c: Regenerate.
-
-2000-10-04 Kazu Hirata <kazu@hxi.com>
-
- * ia64-gen.c: Convert C++-style comments to C-style comments.
- * tic54x-dis.c: Likewise.
-
-2000-09-29 Hans-Peter Nilsson <hp@axis.com>
-
- Changes to add dollar prefix to registers for files where user symbols
- don't have a leading underscore. Fix formatting.
- * cris-dis.c (REGISTER_PREFIX_CHAR): New.
- (format_reg): Add parameter with_reg_prefix. All callers changed.
- (print_with_operands): Ditto.
- (print_insn_cris_generic): Renamed from print_insn_cris, add
- parameter with_reg_prefix.
- (print_insn_cris_with_register_prefix,
- print_insn_cris_without_register_prefix, cris_get_disassembler):
- New.
- * disassemble.c (disassembler) [ARCH_cris]: Call cris_get_disassembler.
-
-2000-09-22 Jim Wilson <wilson@redhat.com>
-
- * ia64-opc-f.c (ia64_opcodes_f): Add fpcmp pseudo-ops for
- gt, ge, ngt, and nge.
- * ia64-asmtab.c: Regenerate.
-
- * ia64-dis.c (print_insn_ia64): Revert Aug 7 byte skip count change.
- * ia64-gen.c (parse_semantics): Handle IA64_DVS_STOP.
- (lookup_specifier): Handle "PR%, 1 to 15" and "PR%, 16 to 62".
- * ia64-ic.tbl, ia64-raw.tbl, ia64-war.tbl, ia64-waw.tbl: Update.
- * ia64-asmtab.c: Regnerate.
-
-2000-09-13 Anders Norlander <anorland@acc.umu.se>
-
- * mips-opc.c (mips_builtin_opcodes): Support cache instruction on 4K cores.
- Add mfc0 and mtc0 with sub-selection values.
- Add clo and clz opcodes.
- Add msub and msubu instructions for MIPS32.
- Add madd/maddu aliases for mad/madu for MIPS32.
- Support wait, deret, eret, movn, pref for MIPS32.
- Support tlbp, tlbr, tlbwi, tlbwr.
- (P4): New define.
-
- * mips-dis.c (print_insn_arg): Print sdbbp 'm' args.
- (print_insn_arg): Handle 'H' args.
- (set_mips_isa_type): Recognize 4K.
- Use CPU_* defines instead of hardcoded numbers.
-
-2000-09-11 Catherine Moore <clm@redhat.com>
-
- * d30v-opc.c (d30v_operand_t): New operand type Rb2.
- (d30v_format_tab): Use Rb2 for modinc and moddec.
-
-2000-09-07 Catherine Moore <clm@redhat.com>
-
- * d30v-opc.c (d30v_format_tab): Use format Ra for
- modinc and moddec.
-
-2000-09-06 Alexandre Oliva <aoliva@redhat.com>
-
- * configure: Rebuilt with new libtool.m4.
-
-2000-09-05 Nick Clifton <nickc@redhat.com>
-
- * configure: Regenerate.
- * po/opcodes.pot: Regenerate.
-
-2000-08-31 Alexandre Oliva <aoliva@redhat.com>
-
- * acinclude.m4: Include libtool and gettext macros from the
- top level.
- * aclocal.m4, configure: Rebuilt.
-
-2000-08-30 Kazu Hirata <kazu@hxi.com>
-
- * tic80-dis.c: Fix formatting.
-
-2000-08-29 Kazu Hirata <kazu@hxi.com>
-
- * w65-dis.c: Fix formatting.
-
-2000-08-28 Mark Hatle <mhatle@mvista.com>
-
- * ppc-opc.c: Add XTLB macro for a few PPC 4xx extended mnemonics.
- (powerpc_opcodes): Add table entries for PPC 405 instructions.
- Changed rfci, icbt, mfdcr, dccci, mtdcr, iccci from PPC to PPC403
- instructions. Added extended mnemonic mftbl as defined in the
- 405GP manual for all PPCs.
-
-2000-08-28 Jim Wilson <wilson@redhat.com>
-
- * ia64-dis.c (print_insn_ia64): Add failed label after ia64_free_opcode
- call. Change last goto to use failed instead of done.
-
-2000-08-28 Dave Brolley <brolley@redhat.com>
-
- * cgen-ibld.in (cgen_put_insn_int_value): New function.
- (insert_normal): Allow for non-zero word_offset with CGEN_INT_INSN_P.
- (insert_insn_normal): Use cgen_put_insn_int_value with CGEN_INT_INSN_P.
- (extract_normal): Allow for non-zero word_offset with CGEN_INT_INSN_P.
- * cgen-dis.in (read_insn): New static function.
- (print_insn): Use read_insn to read the insn into the buffer and set
- up for disassembly.
- (print_insn): in CGEN_INT_INSN_P, make sure that the entire insn is
- in the buffer.
- * fr30-asm.c: Regenerated.
- * fr30-desc.c: Regenerated.
- * fr30-desc.h: Regenerated.
- * fr30-dis.c: Regenerated.
- * fr30-ibld.c: Regenerated.
- * fr30-opc.c: Regenerated.
- * fr30-opc.h: Regenerated.
- * m32r-asm.c: Regenerated.
- * m32r-desc.c: Regenerated.
- * m32r-desc.h: Regenerated.
- * m32r-dis.c: Regenerated.
- * m32r-ibld.c: Regenerated.
- * m32r-opc.c: Regenerated.
-
-2000-08-28 Kazu Hirata <kazu@hxi.com>
-
- * tic30-dis.c: Fix formatting.
-
-2000-08-27 Kazu Hirata <kazu@hxi.com>
-
- * sh-dis.c: Fix formatting.
-
-2000-08-24 David Edelsohn <dje@watson.ibm.com>
-
- * ppc-opc.c (powerpc_opcodes): Add rfid, mtsrd, mtsrdin, mtmsrd.
-
-2000-08-24 Kazu Hirata <kazu@hxi.com>
-
- * z8k-dis.c: Fix formatting.
-
-2000-08-16 Jim Wilson <wilson@redhat.com>
-
- * ia64-ic.tbl (pr-readers-nobr-nomovpr): Add addl, adds. Delete
- break, mov-immediate, nop.
- * ia64-opc-f.c: Delete fpsub instructions.
- * ia64-opc-m.c: Add POSTINC to all instructions with postincrement
- address operand. Rewrite using macros to avoid long lines.
- * ia64-opc.h (POSTINC): Define.
- * ia64-asmtab.c: Regenerate.
-
-2000-08-15 Jim Wilson <wilson@redhat.com>
-
- * ia64-ic.tbl: Add missing entries.
-
-2000-08-08 Jason Eckhardt <jle@redhat.com>
-
- * i860-dis.c (print_br_address): Change third argument from int
- to long.
-
-2000-08-07 Richard Henderson <rth@redhat.com>
-
- * ia64-dis.c (print_insn_ia64): Get byte skip count correct
- for MLI templates. Handle IA64_OPND_TGT64.
-
-2000-08-04 Ben Elliston <bje@redhat.com>
-
- * cgen-dis.in, cgen-asm.in, cgen-ibld.in: New files.
- * cgen.sh: Likewise.
-
-2000-08-02 Jim Wilson <wilson@redhat.com>
-
- * ia64-dis.c (print_insn_ia64): Call ia64_free_opcode at end.
-
-2000-07-29 Marek Michalkiewicz <marekm@linux.org.pl>
-
- * avr-dis.c (avr_operand): Use PARAMS macro in declaration.
- Change return type from void to int. Check the combination
- of operands, return 1 if valid. Fix to avoid BUF overflow.
- Report undefined combinations of operands in COMMENT.
- Report internal errors to stderr. Output the adiw/sbiw
- constant operand in both decimal and hex.
- (print_insn_avr): Disassemble ldd/std with displacement of 0
- as ld/st. Check avr_operand () return value, handle invalid
- combinations of operands like unknown opcodes.
-
-2000-07-28 Ben Elliston <bje@redhat.com>
-
- * Makefile.am (CGEN, CGENDEPS, CGENDIR, CGENFLAGS): New.
- (run-cgen, stamp-m32r, stamp-fr30): New targets.
- * Makefile.in: Regenerate.
- * configure.in: Add --enable-cgen-maint option.
- * configure: Regenerate.
-
-2000-07-26 Dave Brolley <brolley@redhat.com>
-
- * cgen-opc.c (cgen_hw_lookup_by_name): 'i' is now unsigned.
- (cgen_hw_lookup_by_num): Ditto.
- (cgen_operand_lookup_by_name): Ditto.
- (print_address): Ditto.
- (print_keyword): Ditto.
- * cgen-dis.c (hash_insn_array): Mark unused parameters with
- ATTRIBUTE_UNUSED.
- * cgen-asm.c (hash_insn_array): Mark unused parameters with
- ATTRIBUTE_UNUSED.
- (cgen_parse_keyword): Ditto.
-
-2000-07-22 Jason Eckhardt <jle@redhat.com>
-
- * i860-dis.c: New file.
- (print_insn_i860): New function.
- (print_br_address): New function.
- (sign_extend): New function.
- (BITWISE_OP): New macro.
- (I860_REG_PREFIX): New macro.
- (grnames, frnames, crnames): New structures.
-
- * disassemble.c (ARCH_i860): Define.
- (disassembler): Add check for bfd_arch_i860 to set disassemble
- function to print_insn_i860.
-
- * Makefile.in (CFILES): Added i860-dis.c.
- (ALL_MACHINES): Added i860-dis.lo.
- (i860-dis.lo): New dependences.
-
- * configure.in: New bits for bfd_i860_arch.
-
- * configure: Regenerated.
-
-2000-07-20 Hans-Peter Nilsson <hp@axis.com>
-
- * Makefile.am (CFILES): Add cris-dis.c and cris-opc.c.
- (ALL_MACHINES): Add cris-dis.lo and cris-opc.lo.
- (cris-dis.lo, cris-opc.lo): New rules.
- * Makefile.in: Rebuild.
- * configure.in (bfd_cris_arch): New target.
- * configure: Rebuild.
- * disassemble.c (ARCH_cris): Define.
- (disassembler): Support ARCH_cris.
- * cris-dis.c, cris-opc.c: New files.
- * po/POTFILES.in, po/opcodes.pot: Regenerate.
-
-2000-07-11 Jakub Jelinek <jakub@redhat.com>
-
- * sparc-opc.c (sparc_opcodes): popc has 0 in rs1, not rs2.
- Reported by Bill Clarke <llib@computer.org>.
-
-2000-07-09 Geoffrey Keating <geoffk@redhat.com>
-
- * ppc-opc.c (powerpc_opcodes): Correct suffix for vslw.
- Patch by Randall J Fisher <rfisher@ecn.purdue.edu>.
-
-2000-07-09 Alan Modra <alan@linuxcare.com.au>
-
- * hppa-dis.c (fput_reg, fput_fp_reg, fput_fp_reg_r, fput_creg,
- fput_const, extract_3, extract_5_load, extract_5_store,
- extract_5r_store, extract_5R_store, extract_10U_store,
- extract_5Q_store, extract_11, extract_14, extract_16, extract_21,
- extract_12, extract_17, extract_22): Prototype.
- (print_insn_hppa): Rename inner block opcode -> opc to avoid
- shadowing outer block.
- (GET_BIT): Define.
-
-2000-07-05 DJ Delorie <dj@redhat.com>
-
- * MAINTAINERS: new
-
-2000-07-04 Alexandre Oliva <aoliva@redhat.com>
-
- * arm-dis.c (print_insn_arm): Output combinations of PSR flags.
-
-2000-07-03 Marek Michalkiewicz <marekm@linux.org.pl>
-
- * avr-dis.c (avr_operand): Change _ () to _() around all strings
- marked for translation (exception from the usual coding style).
- (print_insn_avr): Initialize insn2 to avoid warnings.
-
-2000-07-03 Kazu Hirata <kazu@hxi.com>
-
- * h8300-dis.c (bfd_h8_disassemble): Improve readability.
- * h8500-dis.c: Fix formatting.
-
-2000-07-01 Alan Modra <alan@linuxcare.com.au>
-
- * Makefile.am (DEP): Fix 2000-06-22. grep after running dep.sed
- (CLEANFILES): Add DEPA.
- * Makefile.in: Regenerate.
-
-2000-06-26 Scott Bambrough <scottb@netwinder.org>
-
- * arm-dis.c (regnames): Add an additional register set to match
- the set used by GCC. Make it the default.
-
-2000-06-22 Alan Modra <alan@linuxcare.com.au>
-
- * Makefile.am (DEP): grep for leading `/' in DEP1, and fail if we
- find one.
- * Makefile.in: Regenerate.
-
-2000-06-20 H.J. Lu <hjl@gnu.org>
-
- * Makefile.am: Rebuild dependency.
- * Makefile.in: Rebuild.
-
-2000-06-18 Stephane Carrez <stcarrez@worldnet.fr>
-
- * Makefile.in, configure: regenerate
- * disassemble.c (disassembler): Recognize ARCH_m68hc12,
- ARCH_m68hc11.
- * m68hc11-dis.c (read_memory, print_insn, print_insn_m68hc12):
- New functions.
- * configure.in: Recognize m68hc12 and m68hc11.
- * m68hc11-dis.c, m68hc11-opc.c: New files for support of m68hc1x
- * Makefile.am (CFILES, ALL_MACHINES): New files for disassembly
- and opcode generation for m68hc11 and m68hc12.
-
-2000-06-16 Nick Duffek <nsd@redhat.com>
-
- * disassemble.c (disassembler): Refer to the PowerPC 620 using
- bfd_mach_ppc_620 instead of 620.
-
-2000-06-12 Kazu Hirata <kazu@hxi.com>
-
- * h8300-dis.c: Fix formatting.
- (bfd_h8_disassemble): Distinguish adds/subs, inc/dec.[wl]
- correctly.
-
-2000-06-09 Denis Chertykov <denisc@overta.ru>
-
- * avr-dis.c (avr_operand): Bugfix for jmp/call address.
-
-2000-06-07 Denis Chertykov <denisc@overta.ru>
-
- * avr-dis.c: completely rewritten.
-
-2000-06-02 Kazu Hirata <kazu@hxi.com>
-
- * h8300-dis.c: Follow the GNU coding style.
- (bfd_h8_disassemble) Fix a typo.
-
-2000-06-01 Kazu Hirata <kazu@hxi.com>
-
- * h8300-dis.c (bfd_h8_disassemble_init): Fix a typo.
- (bfd_h8_disassemble): Distinguish the operand size of inc/dev.[wl]
- correctly. Fix a typo.
-
-2000-05-31 Nick Clifton <nickc@redhat.com>
-
- * opintl.h (_(String)): Explain why dgettext is used instead of
- gettext.
-
-2000-05-30 Nick Clifton <nickc@redhat.com>
-
- * opintl.h (gettext, dgettext, dcgettext, textdomain,
- bindtextdomain): Replace defines with those from intl/libgettext.h
- to quieten gcc warnings.
-
-2000-05-26 Alan Modra <alan@linuxcare.com.au>
-
- * Makefile.am: Update dependencies with "make dep-am"
- * Makefile.in: Regenerate.
-
-2000-05-25 Alexandre Oliva <aoliva@redhat.com>
-
- * m10300-dis.c (disassemble): Don't assume 32-bit longs when
- sign-extending operands.
-
-2000-05-15 Donald Lindsay <dlindsay@redhat.com>
-
- * d10v-opc.c (d10v_opcodes): add ALONE tag to all short branches
- except brf's.
-
-2000-05-21 Nick Clifton <nickc@redhat.com>
-
- * Makefile.am (LIBIBERTY): Define.
-
-2000-05-19 Diego Novillo <dnovillo@redhat.com>
-
- * mips-dis.c (REGISTER_NAMES): Rename to STD_REGISTER_NAMES.
- (STD_REGISTER_NAMES): New name for REGISTER_NAMES.
- (reg_names): Rename to std_reg_names. Change it to a char **
- static variable.
- (std_reg_names): New name for reg_names.
- (set_mips_isa_type): Set reg_names to point to std_reg_names by
- default.
-
-2000-05-16 Frank Ch. Eigler <fche@redhat.com>
-
- * fr30-desc.h: Partially regenerated to account for changed
- CGEN_MAX_* -> CGEN_ACTUAL_MAX_* macros.
- * m32r-desc.h: Ditto.
-
-2000-05-15 Nick Clifton <nickc@redhat.com>
-
- * arm-opc.h: Use upper case for flasg in MSR and MRS
- instructions. Allow any bit to be set in the field_mask of
- the MSR instruction.
-
- * arm-dis.c (print_insn_arm): Decode _x and _s bits of the
- field_mask of an MSR instruction.
-
-2000-05-11 Thomas de Lellis <tdel@windriver.com>
-
- * arm-opc.h: Disassembly of thumb ldsb/ldsh
- instructions changed to ldrsb/ldrsh.
-
-2000-05-11 Ulf Carlsson <ulfc@engr.sgi.com>
-
- * mips-dis.c (print_insn_arg): Don't mask top 32 bits of 64-bit
- target addresses for 'jal' and 'j'.
-
-2000-05-10 Geoff Keating <geoffk@redhat.com>
-
- * ppc-opc.c (powerpc_opcodes): Make the predicted-branch opcodes
- also available in common mode when powerpc syntax is being used.
-
-2000-05-08 Alan Modra <alan@linuxcare.com.au>
-
- * m68k-dis.c (dummy_printer): Add ATTRIBUTE_UNUSED to args.
- (dummy_print_address): Ditto.
-
-2000-05-04 Timothy Wall <twall@redhat.com>
-
- * tic54x-opc.c: New.
- * tic54x-dis.c: New.
- * disassemble.c (disassembler): Add ARCH_tic54x.
- * configure.in: Added tic54x target.
- * configure: Ditto.
- * Makefile.am: Add tic54x dependencies.
- * Makefile.in: Ditto.
-
-2000-05-03 J.T. Conklin <jtc@redback.com>
-
- * ppc-opc.c (VA, VB, VC, VD, VS, SIMM, UIMM, SHB): New macros, for
- vector unit operands.
- (VX, VX_MASK, VXA, VXA_MASK, VXR, VXR_MASK): New macros, for vector
- unit instruction formats.
- (PPCVEC): New macro, mask for vector instructions.
- (powerpc_operands): Add table entries for above operand types.
- (powerpc_opcodes): Add table entries for vector instructions.
-
- * ppc-dis.c (print_insn_big_powerpc): Add PPC_OPCODE_ALTIVEC to mask.
- (print_insn_little_powerpc): Likewise.
- (print_insn_powerpc): Prepend 'v' when printing vector registers.
-
-2000-04-24 Clinton Popetz <cpopetz@redhat.com>
-
- * configure.in: Add bfd_powerpc_64_arch.
- * disassemble.c (disassembler): Use print_insn_big_powerpc for
- 64 bit code.
-
-2000-04-24 Nick Clifton <nickc@redhat.com>
-
- * fr30-desc.c (fr30_cgen_cpu_open): Initialise signed_overflow
- field.
-
-2000-04-23 Denis Chertykov <denisc@overta.ru>
-
- * avr-dis.c (reg_fmul_d): New. Extract destination register from
- FMUL instruction.
- (reg_fmul_r): New. Extract source register from FMUL instruction.
- (reg_muls_d): New. Extract destination register from MULS instruction.
- (reg_muls_r): New. Extract source register from MULS instruction.
- (reg_movw_d): New. Extract destination register from MOVW instruction.
- (reg_movw_r): New. Extract source register from MOVW instruction.
- (print_insn_avr): Handle MOVW, MULS, MULSU, FMUL, FMULS, FMULSU,
- EICALL, EIJMP, LPM r,Z, ELPM r,Z, SPM, ESPM instructions.
-
-2000-04-22 Timothy Wall <twall@redhat.com>
-
- * ia64-gen.c (general): Add an ordered table of primary
- opcode names, as well as priority fields to disassembly data
- structures to enforce a preferred disassembly format based on the
- ordering of the opcode tables.
- (load_insn_classes): Show a useful message if IC tables are missing.
- (load_depfile): Ditto.
- * ia64-asmtab.h (struct ia64_dis_names ): Add priority flag to
- distinguish preferred disassembly.
- * ia64-opc-f.c: Reorder some insn for preferred disassembly
- format. Fix incorrect flag on fma.s/fma.s.s0.
- * ia64-opc.c: Scan *all* disassembly matches and use the one with
- the highest priority.
- * ia64-opc-b.c: Use more abbreviations.
- * ia64-asmtab.c: Regenerate.
-
-2000-04-21 Jason Eckhardt <jle@redhat.com>
-
- * hppa-dis.c (extract_16): New function.
- (print_insn_hppa): Fix incorrect handling of 'fe'. Added handling of
- new operand types l,y,&,fe,fE,fx.
-
-2000-04-21 Richard Henderson <rth@redhat.com>
- David Mosberger <davidm@hpl.hp.com>
- Timothy Wall <twall@redhat.com>
- Bob Manson <manson@charmed.cygnus.com>
- Jim Wilson <wilson@redhat.com>
-
- * Makefile.am (HFILES): Add ia64-asmtab.h, ia64-opc.h.
- (CFILES): Add ia64-dis.c, ia64-opc-a.c, ia64-opc-b.c, ia64-opc-f.c,
- ia64-opc-i.c, ia64-opc-m.c, ia64-opc-d.c, ia64-opc.c, ia64-gen.c,
- ia64-asmtab.c.
- (ALL_MACHINES): Add ia64-dis.lo, ia64-opc.lo.
- (ia64-ic.tbl, ia64-raw.tbl, ia64-waw.tbl, ia64-war.tbl, ia64-gen,
- ia64-gen.o, ia64-asmtab.c, ia64-dis.lo, ia64-opc.lo): New rules.
- * Makefile.in: Rebuild.
- * configure Rebuild.
- * configure.in (bfd_ia64_arch): New target.
- * disassemble.c (ARCH_ia64): Define.
- (disassembler): Support ARCH_ia64.
- * ia64-asmtab.c, ia64-asmtab.h, ia64-dis.c, ia64-gen.c ia64-ic.tbl,
- ia64-opc-a.c, ia64-opc-b.c, ia64-opc-d.c ia64-opc-f.c, ia64-opc-i.c,
- ia64-opc-m.c, ia64-opc-x.c, ia64-opc.c, ia64-opc.h, ia64-raw.tbl,
- ia64-war.tbl, ia64-waw.tbl: New files.
-
-2000-04-20 Alexandre Oliva <aoliva@redhat.com>
-
- * m10300-dis.c (HAVE_AM30, HAVE_AM33): Define.
- (disassemble): Use them.
-
-2000-04-14 Alan Modra <alan@linuxcare.com.au>
-
- * sysdep.h: Include "ansidecl.h" not <ansidecl.h>
- * Makefile.am: Update dependencies.
- * Makefile.in: Regenerate.
-
-2000-04-14 Michael Sokolov <msokolov@ivan.Harhan.ORG>
-
- * a29k-dis.c, alpha-dis.c, alpha-opc.c, arc-dis.c, arc-opc.c,
- avr-dis.c, d10v-dis.c, d10v-opc.c, d30v-dis.c, d30v-opc.c,
- disassemble.c, h8300-dis.c, h8500-dis.c, hppa-dis.c, i370-dis.c,
- i370-opc.c, i960-dis.c, m10200-dis.c, m10200-opc.c, m10300-dis.c,
- m10300-opc.c, m68k-dis.c, m68k-opc.c, m88k-dis.c, mcore-dis.c,
- mips-dis.c, mips-opc.c, mips16-opc.c, pj-dis.c, pj-opc.c,
- ppc-dis.c, ppc-opc.c, sh-dis.c, sparc-dis.c, sparc-opc.c,
- tic80-dis.c, tic80-opc.c, v850-dis.c, v850-opc.c, vax-dis.c,
- w65-dis.c, z8k-dis.c, z8kgen.c: Include sysdep.h. Remove
- ansidecl.h as sysdep.h includes it.
-
-2000-04-7 Andrew Cagney <cagney@b1.redhat.com>
-
- * configure.in (WARN_CFLAGS): Set to -W -Wall by default. Add
- --enable-build-warnings option.
- * Makefile.am (AM_CFLAGS, WARN_CFLAGS): Add definitions.
- * Makefile.in, configure: Re-generate.
-
-2000-04-05 J"orn Rennecke <amylaar@redhat.com>
-
- * sh-opc.h (sh_table): Use A_DISP_PC / PCRELIMM_8BY2 for ldre & ldrs.
- stc GBR,@-<REG_N> is available for arch_sh1_up.
- Group parallel processing insn with identical mnemonics together.
- Make three-operand psha / pshl come first.
-
-2000-04-05 J"orn Rennecke <amylaar@redhat.co.uk>
-
- * sh-opc.h (sh_nibble_type): Remove DISP_8 and DISP_4.
- Split IMM_[48]{,BY[24]} into IMM[01]_[48]{,BY[24]}. Add REPEAT.
- (sh_arg_type): Add A_PC.
- (sh_table): Update entries using immediates. Add repeat.
- * sh-dis.c (print_insn_shx): Remove DISP_8 and DISP_4.
- Split IMM_[48]{,BY[24]} into IMM[01]_[48]{,BY[24]}. Add REPEAT.
-
-2000-04-04 Alan Modra <alan@linuxcare.com.au>
-
- * po/opcodes.pot: Regenerate.
-
- * Makefile.am (MKDEP): Use gcc -MM rather than mkdep.
- (DEP): Quote when passing vars to sub-make. Add warning message
- to end.
- (DEP1): Rewrite for "gcc -MM".
- (CLEANFILES): Add DEP2.
- Update dependencies.
- * Makefile.in: Regenerate.
-
-2000-04-03 Denis Chertykov <denisc@overta.ru>
-
- * avr-dis.c: Syntax cleanup.
- (add0fff): Print the pc relative address as a signed number.
- (add03f8): Likewise.
-
-2000-04-01 Ian Lance Taylor <ian@zembu.com>
-
- * disassemble.c (disassembler_usage): Don't use a prototype. Mark
- the parameter ATTRIBUTE_UNUSED.
- * ppc-opc.c: Add ATTRIBUTE_UNUSED as needed.
-
-2000-04-01 Alexandre Oliva <aoliva@redhat.com>
-
- * m10300-opc.c: SP-based offsets are always unsigned.
-
-2000-03-29 Thomas de Lellis <tdel@windriver.com>
-
- * arm-opc.h (thumb_opcodes): Disassemble 0xde.. to "bal"
- [branch always] instead of "undefined".
-
-2000-03-27 Nick Clifton <nickc@redhat.com>
-
- * d30v-opc.c (d30v_format_table): Move SHORT_AR to end of list of
- short instructions, from end of list of long instructions.
-
-2000-03-27 Ian Lance Taylor <ian@zembu.com>
-
- * Makefile.am (CFILES): Add avr-dis.c.
- (ALL_MACHINES): Add avr-dis.lo.
-
-2000-03-27 Alan Modra <alan@linuxcare.com>
-
- * avr-dis.c (add0fff, add03f8): Don't use structure bitfields to
- truncate integers.
- (print_insn_avr): Call function via pointer in K&R compatible way.
- (dispLDD, regPP, reg50, reg104, reg40, reg20w, lit404, lit204,
- add0fff, add03f8): Convert to old style function declaration and
- add prototype.
- (avrdis_opcode): Add prototype.
-
-2000-03-27 Denis Chertykov <denisc@overta.ru>
-
- * avr-dis.c: New file. AVR disassembler.
- * configure.in (bfd_avr_arch): New architecture support.
- * disassemble.c: Likewise.
- * configure: Regenerate.
-
-2000-03-06 J"oern Rennecke <amylaar@redhat.com>
-
- * sh-opc.h (sh_table): ldre and ldrs have a *signed* displacement.
-
-2000-03-02 J"orn Rennecke <amylaar@redhat.co.uk>
-
- * d30v-dis.c (print_insn): Remove d*i hacks. Use per-operand
- flag to determine if operand is pc-relative.
- * d30v-opc.c:
- (d30v_format_table):
- (REL6S3): Renamed from IMM6S3.
- Added flag OPERAND_PCREL.
- (REL12S3, REL18S3, REL32): Split from IMM12S3, IMM18S3, REL32, with
- added flag OPERAND_PCREL.
- (IMM12S3U): Replaced with REL12S3.
- (SHORT_D2, LONG_D): Delay target is pc-relative.
- (SHORT_B2r, SHORT_B3r, SHORT_B3br, SHORT_D2r, LONG_Ur, LONG_2r):
- Split from SHORT_B2, SHORT_D2, SHORT_B3b, SHORT_D2, LONG_U, LONG_2r,
- using the REL* operands.
- (LONG_2br, LONG_Dr): Likewise, from LONG_2b, LONG_D.
- (SHORT_D1r, SHORT_D2Br, LONG_Dbr): Renamed from SHORT_D1, SHORT_D2B,
- LONG_Db, using REL* operands.
- (SHORT_U, SHORT_A5S): Removed stray alternatives.
- (d30v_opcode_table): Use new *r formats.
-
-2000-02-28 Nick Clifton <nickc@redhat.com>
-
- * m32r-desc.c (m32r_cgen_cpu_open): Replace 'flags' with
- 'signed_overflow_ok_p'.
-
-2000-02-27 Eli Zaretskii <eliz@is.elta.co.il>
-
- * Makefile.am (stamp-lib): Use $(LIBTOOL) --config to get the
- name of the libtool directory.
- * Makefile.in: Rebuild.
-
-2000-02-24 Nick Clifton <nickc@redhat.com>
-
- * cgen-opc.c (cgen_set_signed_overflow_ok): New function.
- (cgen_clear_signed_overflow_ok): New function.
- (cgen_signed_overflow_ok_p): New function.
-
-2000-02-23 Andrew Haley <aph@redhat.com>
-
- * m32r-asm.c, m32r-desc.c, m32r-desc.h, m32r-dis.c,
- m32r-ibld.c, m32r-opc.h: Rebuild.
-
-2000-02-23 Linas Vepstas <linas@linas.org>
-
- * i370-dis.c, i370-opc.c: New.
-
- * disassemble.c (ARCH_i370): Define.
- (disassembler): Handle it.
-
- * Makefile.am: Add support for Linux/IBM 370.
- * configure.in: Likewise.
-
- * Makefile.in: Regenerate.
- * configure: Likewise.
-
-2000-02-22 Chandra Chavva <cchavva@redhat.com>
-
- * d30v-opc.c (d30v_opcode_tab) : Added FLAG_NOT_WITH_ADDSUBppp to
- ST2H, STB, STH, STHH, STW and ST2H opcodes to prohibit parallel
- procedure.
-
-2000-02-22 Andrew Haley <aph@redhat.com>
-
- * mips-dis.c (_print_insn_mips): New arg for OPCODE_IS_MEMBER:
- force gp32 to zero.
- * mips-opc.c (G6): New define.
- (mips_builtin_op): Add "move" definition for -gp32.
-
-2000-02-22 Ian Lance Taylor <ian@zembu.com>
-
- From Grant Erickson <gerickso@Brocade.COM>:
- * ppc-opc.c: Correct dcread--it takes 3 arguments, not 2.
-
-2000-02-21 Alan Modra <alan@spri.levels.unisa.edu.au>
-
- * dis-buf.c (buffer_read_memory): Change `length' param and all int
- vars to unsigned.
-
-2000-02-17 J"orn Rennecke <amylaar@redhat.co.uk>
-
- * sh-dis.c (print_movxy, print_insn_ddt, print_dsp_reg): New functions.
- (print_insn_ppi): Likewise.
- (print_insn_shx): Use info->mach to select appropriate insn set.
- Add support for sh-dsp. Remove FD_REG_N support.
- * sh-opc.h (sh_nibble_type): Add new values for sh-dsp support.
- (sh_arg_type): Likewise. Remove FD_REG_N.
- (sh_dsp_reg_nums): New enum.
- (arch_sh1, arch_sh2, arch_sh3, arch_sh3e, arch_sh4): New macros.
- (arch_sh_dsp, arch_sh3_dsp, arch_sh1_up, arch_sh2_up): Likewise.
- (arch_sh3_up, arch_sh3e_up, arch_sh4_up, arch_sh_dsp_up): Likewise.
- (arch_sh3_dsp_up): Likewise.
- (sh_opcode_info): New field: arch.
- (sh_table): Split up insn with FD_REG_N into ones with F_REG_N and
- D_REG_N. Fill in arch field. Add sh-dsp insns.
-
-2000-02-14 Fernando Nasser <fnasser@totem.to.redhat.com>
-
- * arm-dis.c: Change flavor name from atpcs-special to
- special-atpcs to prevent name conflict in gdb.
- (get_arm_regname_num_options, set_arm_regname_option,
- get_arm_regnames): New functions. API to access the several
- flavor of register names. Note: Used by gdb.
- (print_insn_thumb): Use the register name entry from the currently
- selected flavor for LR and PC.
-
-2000-02-10 Nick Clifton <nickc@redhat.com>
-
- * mcore-opc.h (enum mcore_opclass): Add MULSH and OPSR
- classes.
- (mcore_table): Add "idly4", "psrclr", "psrset", "mulsh" and
- "mulsh.h" instructions.
- * mcore-dis.c (imsk array): Add masks for MULSH and OPSR
- classes.
- (print_insn_mcore): Add support for little endian targets.
- Add support for MULSH and OPSR classes.
-
-2000-02-07 Nick Clifton <nickc@redhat.com>
-
- * arm-dis.c (parse_arm_diassembler_option): Rename again.
- Previous delat did not take.
-
-2000-02-03 Timothy Wall <twall@redhat.com>
-
- * dis-buf.c (buffer_read_memory): Use octets_per_byte field
- to adjust target address bounds checking and calculate the
- appropriate octet offset into data.
-
-2000-01-27 Nick Clifton <nickc@redhat.com>
-
- * arm-dis.c: (parse_disassembler_option): Rename to
- parse_arm_disassembler_option and allow to be exported.
-
- * disassemble.c (disassembler_usage): New function: Print out any
- target specific disassembler options.
- Call arm_disassembler_options() if the ARM architecture is being
- supported.
-
- * arm-dis.c (NUM_ELEM): Define this macro if not already
- defined.
- (arm_regname): New struct type for ARM register names.
- (arm_toggle_regnames): Delete.
- (parse_disassembler_option): Use register name structure.
- (print_insn): New function: Combines duplicate code found in
- print_insn_big_arm and print_insn_little_arm.
- (print_insn_big_arm): Call print_insn.
- (print_insn_little_arm): Call print_insn.
- (print_arm_disassembler_options): Display list of supported,
- ARM specific disassembler options.
-
-2000-01-27 Thomas de Lellis <tdel@windriver.com>
-
- * arm-dis.c (printf_insn_big_arm): Treat ELF symbols with the
- ARM_STT_16BIT flag as Thumb code symbols.
-
- * arm-dis.c (printf_insn_little_arm): Ditto.
-
-2000-01-25 Thomas de Lellis <tdel@windriver.com>
-
- * arm-dis.c (printf_insn_thumb): Prevent double dumping
- of raw thumb instructions.
-2000-01-20 Nick Clifton <nickc@redhat.com>
+2004-01-06 Alexandre Oliva <aoliva@redhat.com>
- * mcore-opc.h (mcore_table): Add "add" as an alias for "addu".
+ 2003-12-19 Alexandre Oliva <aoliva@redhat.com>
+ * frv-asm.c (parse_ulo16, parse_uhi16, parse_d12): Fix some
+ cut&paste errors in shifting/truncating numerical operands.
+ 2003-08-04 Alexandre Oliva <aoliva@redhat.com>
+ * frv-asm.c (parse_ulo16): Parse gotofflo and gotofffuncdesclo.
+ (parse_uslo16): Likewise.
+ (parse_uhi16): Parse gotoffhi and gotofffuncdeschi.
+ (parse_d12): Parse gotoff12 and gotofffuncdesc12.
+ (parse_s12): Likewise.
+ 2003-08-04 Alexandre Oliva <aoliva@redhat.com>
+ * frv-asm.c (parse_ulo16): Parse gotlo and gotfuncdesclo.
+ (parse_uslo16): Likewise.
+ (parse_uhi16): Parse gothi and gotfuncdeschi.
+ (parse_d12): Parse got12 and gotfuncdesc12.
+ (parse_s12): Likewise.
-2000-01-03 Nick Clifton <nickc@cygnus.com>
+2004-01-02 Albert Bartoszko <albar@nt.kegel.com.pl>
- * arm-dis.c (streq): New macro.
- (strneq): New macro.
- (force_thumb): ew local variable.
- (parse_disassembler_option): New function: Parse a single, ARM
- specific disassembler command line switch.
- (parse_disassembler_option): Call parse_disassembler_option to
- parse individual command line switches.
- (print_insn_big_arm): Check force_thumb.
- (print_insn_little_arm): Check force_thumb.
+ * msp430-dis.c (msp430_doubleoperand): Check for an 'add'
+ instruction which looks similar to an 'rla' instruction.
-For older changes see ChangeLog-9899
+For older changes see ChangeLog-0203
Local Variables:
mode: change-log
diff --git a/contrib/binutils/opcodes/ChangeLog-0001 b/contrib/binutils/opcodes/ChangeLog-0001
new file mode 100644
index 0000000..085453a
--- /dev/null
+++ b/contrib/binutils/opcodes/ChangeLog-0001
@@ -0,0 +1,2224 @@
+2001-12-31 Jeffrey A Law (law@redhat.com)
+
+ * hppa-dis.c (print_insn_hppa): Handle new 'c' mode completers,
+ 'X', 'M', and 'A'. No longer emit a space after 'x' or 's'.
+ Always emit a space after 'H'.
+
+2001-12-18 matthew green <mrg@redhat.com>
+
+ * ppc-opc.c (PPCVEC): Include PPC_OPCODE_ANY.
+
+2001-12-17 Richard Henderson <rth@redhat.com>
+
+ * alpha-opc.c (unop): Encode with RB as $sp.
+
+2001-12-07 Geoffrey Keating <geoffk@redhat.com>
+
+ * Makefile.am: Add support for xstormy16.
+ * Makefile.in: Regenerate.
+ * configure.in: Add support for xstormy16.
+ * configure: Regenerate.
+ * disassemble.c: Add support for xstormy16.
+ * xstormy16-asm.c: New generated file.
+ * xstormy16-desc.c: New generated file.
+ * xstormy16-desc.h: New generated file.
+ * xstormy16-dis.c: New generated file.
+ * xstormy16-ibld.c: New generated file.
+ * xstormy16-opc.c: New generated file.
+ * xstormy16-opc.h: New generated file.
+
+2001-12-06 Richard Henderson <rth@redhat.com>
+
+ * alpha-opc.c (alpha_opcodes): Add wh64en.
+
+2001-12-04 Alexandre Oliva <aoliva@redhat.com>
+
+ * d10v-opc.c (d10v_predefined_registers): Remove warnings
+ introduced in Nov 29's patch.
+
+ * d10v-dis.c (print_operand): Apply REGISTER_MASK to `num' of
+ unmatched register.
+
+ * d10v-dis.c (print_operand): Disregard OPERAND_SP in register
+ predefined value.
+
+ * d10v-opc.c (RSRC_NOSP): New macro.
+ (d10v_operands): Add it.
+ (d10v_opcodes): Use RSRC_NOSP in post-decrement "st" and "st2w".
+
+2001-11-29 Alexandre Oliva <aoliva@redhat.com>
+
+ * d10v-opc.c (d10v_predefined_registers): Mark `sp' as OPERAND_SP.
+ (RSRC_SP): New macro.
+ (d10v_operands): Add it.
+ (d10v_opcodes): Adjust "st" and "st2w" to use RSRC_SP.
+
+2001-11-23 Lars Brinkhoff <lars@nocrew.org>
+
+ * pdp11-dis.c (print_insn_pdp11): Handle illegal instructions.
+ Also, break out of the loop as soon as an instruction has been
+ printed.
+
+2001-11-17 matthew green <mrg@redhat.com>
+
+ * ppc-opc.c (mfvrsave, mtvrsave): New instructions.
+
+2001-11-15 Alan Modra <amodra@bigpond.net.au>
+
+ * po/POTFILES.in: Regenerate.
+
+ * ppc-opc.c (PPC64): Revert 2001-10-12. Do include PPC_OPCODE_PPC.
+ (insert_bat, extract_bat, insert_bba, extract_bba,
+ insert_bd, extract_bd, insert_bdm, extract_bdm,
+ insert_bdp, extract_bdp, valid_bo,
+ insert_bo, extract_bo, insert_boe, extract_boe,
+ insert_ds, extract_ds, insert_de, extract_de,
+ insert_des, extract_des, insert_li, extract_li,
+ insert_mbe, extract_mbe, insert_mb6, extract_mb6,
+ insert_nb, extract_nb, insert_nsi, extract_nsi,
+ insert_ral, insert_ram, insert_ras,
+ insert_rbs, extract_rbs, insert_sh6, extract_sh6,
+ insert_spr, extract_spr, insert_tbr, extract_tbr): Add dialect param.
+ (extract_bd, extract_bdm, extract_bdp,
+ extract_ds, extract_des,
+ extract_li, extract_nsi): Implement sign extension without conditional.
+ (insert_bdm, extract_bdm,
+ insert_bdp, extract_bdp, valid_bo): Handle 64 bit branch hints.
+ (extract_bdm, extract_bdp): Correct 32 bit validation.
+ (AT1_MASK, AT2_MASK): Define.
+ (BBOAT_MASK): Define.
+ (BBOATCB_MASK, BBOAT2CB_MASK, BBOATBI_MASK): Define.
+ (BOFM64, BOFP64, BOTM64, BOTP64): Define.
+ (BODNZM64, BODNZP64, BODZM64, BODZP64): Define.
+ (PPCCOM32, PPCCOM64): Define.
+ (powerpc_opcodes): Modify existing 32 bit insns with branch hints
+ and add new patterns to implement 64 bit branches with hints. Move
+ booke instructions so they match before ppc64.
+
+ * ppc-dis.c (powerpc_dialect): Set PPC_OPCODE_64 in dialect for
+ 64 bit default targets, and parse "32" and "64" in options.
+ Formatting fixes.
+ (print_insn_powerpc): Pass dialect to operand->extract.
+
+2001-11-14 Dave Brolley <brolley@redhat.com>
+
+ * cgen-dis.c (count_decodable_bits): New function.
+ (add_insn_to_hash_chain): New function.
+ (hash_insn_array): Call add_insn_to_hash_chain.
+ (hash_insn_list): Call add_insn_to_hash_chain.
+ * m32r-dis.c: Regenerated.
+ * fr30-dis.c: Regenerated.
+
+2001-11-14 Andreas Jaeger <aj@suse.de>
+
+ * i386-dis.c (print_insn): Use x86-64 as option.
+
+2001-11-14 Alan Modra <amodra@bigpond.net.au>
+
+ * disassemble.c (disassembler): Call print_insn_i386.
+ * i386-dis.c (SUFFIX_ALWAYS): Define.
+ (struct dis_private): Add orig_sizeflag.
+ (print_insn_i386): Make it a wrapper, calling..
+ (print_insn): ..The old body of print_insn_i386. Avoid longjmp
+ warning without using volatile by moving orig_sizeflag to priv,
+ and removing inbuf. Parse disassembler_options.
+ (print_insn_i386_att, print_insn_i386_intel): Move initialisation
+ code to print_insn.
+ (putop): Remove #ifdef SUFFIX_ALWAYS.
+
+2001-11-11 Timothy Wall <twall@alum.mit.edu>
+
+ * tic54x-dis.c: Use revised opcode structure. Export opcode
+ template lookup.
+ (has_lkaddr): Don't forget about Lmem insns.
+ * tic54x-opc.c: Add emulation trap. Parallel table now uses
+ standard opcode templates.
+
+2001-11-13 Zack Weinberg <zack@codesourcery.com>
+
+ * i386-dis.c (grps): Change "sldt", "str", and "smsw" entries
+ to "sldtQ", "strQ", "smswQ" respectively; all with Ev operand
+ category instead of Ew.
+
+2001-11-12 Niraj Gupta <ngupta@zumanetworks.com>
+
+ * m68k-opc.c: Fix definitions of wddata[bwl].
+
+2001-11-09 Richard Sandiford <rsandifo@redhat.com>
+
+ * cgen-asm.c (cgen_parse_keyword): If the keyword is too big to
+ fit in the buffer, try to match the empty keyword.
+
+2001-11-09 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * cgen-ibld.in (extract_1): Fix badly placed #if 0.
+ * fr30-ibld.c: Regenerate.
+ * m32r-ibld.c: Regenerate.
+ * openrisc-ibld.c: Regenerate.
+
+2001-11-04 Chris Demetriou <cgd@broadcom.com>
+
+ * mips-dis.c (print_insn_mips): Remove spaces at end of line.
+
+2001-11-02 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * configure.in (ALL_LINGUAS): Add "fr", "sv" and "tr".
+ * configure: Regernate.
+ * po/fr.po: New file.
+ * po/sv.po: New file.
+ * po/tr.po: New file.
+
+2001-11-01 Stephane Carrez <Stephane.Carrez@worldnet.fr>
+
+ * m68hc11-dis.c (print_insn): Fix disassembly of movb with a
+ constant as source.
+
+2001-10-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * Makefile.am (CFILES): Add mmix-dis.c and mmix-opc.c. Regenerate
+ dependencies.
+ * Makefile.in: Regenerate.
+ * mmix-dis.c, mmix-opc.c: New files.
+
+2001-10-29 Kazu Hirata <kazu@hxi.com>
+
+ * d30v-dis.c: Fix a comment typo.
+
+2001-10-23 Chris Demetriou <cgd@broadcom.com>
+
+ * mips-opc.c (mips_builtin_opcodes): Mark "bgezall" and
+ "bltzall" as writing GPR 31 (since they do).
+
+ * mips-dis.c (print_insn_arg): Calculate info->target
+ where appropriate.
+ (print_insn_mips): Fill in instruction info.
+ (print_mips16_insn_arg): Remove unneded variable 'val'.
+ Removed duplicated instruction target calculations,
+ calculate once and print that result. Use same idiom for
+ masking the jump segment bits as is used in print_insn_arg.
+
+2001-10-20 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc-opc.c (CT): Make it an optional operand.
+
+2001-10-17 Chris Demetriou <cgd@broadcom.com>
+
+ * mips-dis.c (mips_isa_type): Make the ISA used to disassemble
+ SB-1 binaries include instructions specific to the SB-1.
+ * mips-opc.c (SB1): New definition.
+ (mips_builtin_opcodes): Add SB-1 extension opcodes "div.ps",
+ "recip.ps", "rsqrt.ps", and "sqrt.ps".
+
+2001-10-17 matthew green <mrg@redhat.com>
+
+ * ppc-opc.c (STRM): New AltiVec operand.
+ (XDSS): New AltiVec instruction form.
+ (mtvscr): Correct operand list.
+ (dst, dstt, dstst, dststt, dss, dssall): AltiVec instructions.
+
+2001-10-17 Alan Modra <amodra@bigpond.net.au>
+
+ * po/POTFILES.in: Regenerate.
+
+2001-10-13 matthew green <mrg@redhat.com>
+
+ * ppc-opc.c (MO): New macro for MO field of mbar instruction.
+ (powerpc_opcodes): Add rfci, wrtee, wrteei, mfdcrx, mfdcr,
+ mtdcrx, mtdcr, msync, dcba and mbar as BookE instructions.
+
+2001-10-13 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * cgen-ibld.in: Include safe-ctype.h in preference to
+ ctype.h.
+ * cgen-asm.in: Include safe-ctype.h in preference to
+ ctype.h. Fix formatting. Use ISSPACE instead of isspace and
+ TOLOWER instead of tolower.
+ (@arch@_cgen_build_insn_regex): Remove duplication of syntax
+ string elements in constructed regular expression.
+ * fr30-asm.c: Regenerate.
+ * fr30-desc.c: Regenerate.
+ * fr30-ibld.c: Regenerate.
+ * m32r-asm.c: Regenerate.
+ * m32r-desc.c: Regenerate.
+ * m32r-ibld.c: Regenerate.
+ * openrisc-asm.c: Regenerate.
+ * openrisc-desc.c: Regenerate.
+ * openrisc-ibld.c: Regenerate.
+ * po/opcodes.pot: Regenerate.
+
+2001-10-12 matthew green <mrg@redhat.com>
+
+ * ppc-opc.c (insert_de, extract_de, insert_des, extract_des): New
+ instruction field instruction/extraction functions for new BookE
+ DE form instructions.
+ (CT): New macro for CT field in an X form instruction.
+ (DE, DES, DEO, DE_MASK): New macros for DE/DES fields in DE form
+ instructions.
+ (PPC64): Don't include PPC_OPCODE_PPC.
+ (403): New opcode macro for PPC403 processors.
+ (BOOKE): New opcode macro for BookE processors.
+ (bce, bcel, bcea, bcela, bclre, bclrel: New BookE instructions.
+ (bcctre, bcctrel, be, bel, bea, bela, icbt, icbte, lwzxe): Likewise.
+ (dcbste, lwzuxe, luxe, dcbfe, lbzxe, lwarxe, lbzuxe): Likewise.
+ (stwcxe, stwxe, stxe, stwuxe, stuxe, stbxe, dcbtste, stbuxe): Likewise.
+ (mfapidi, dcbte, lhzxe, lhzuxe, lhaxe, lhauxe, subfe64): Likewise.
+ (subfeo64, adde64, addeo64, sthxe, sthuxe, subfze64): Likewise.
+ (subfzeo64, addze64, addzeo64, dcbie, subfme64, subfmeo64): Likewise.
+ (addme64, addmeo64, stdcxe., mcrxr64, lwbrxe, lfsxe, lfsuxe): Likewise.
+ (lfdxe, lfduxe, stwbrxe, stfsxe, stfsuxe, stfdxe, dcbae): Likewise.
+ (stfduxe, tlbivax, tlbivaxe, lhbrxe, ldxe, lduxe, tlbsx): Likewise.
+ (tlbsxe, sthbrxe, stdxe, stduxe, icbie, stfiwxe, dcbze, lbze): Likewise.
+ (lbzue, ldue, lhze, lhzue, lhae, lhaue, lwze, lwzue): Likewise.
+ (stbe, stbue, sthe, sthue, stwe, stwue, lfse, lfsue, lfde): Likewise.
+ (lfdue, stde, stdue, stfse, stfsue, stfde, stfdue): Likewise.
+
+ * ppc-dis.c (print_insn_big_powerpc, print_insn_little_powerpc): Look
+ for a disassembler option of `booke', `booke32' or `booke64' to enable
+ BookE support in the disassembler.
+
+2001-10-12 John Healy <jhealy@redhat.com>
+
+ * cgen-dis.in (print_insn): Use min (cd->base_insn_bitsize, buflen*8)
+ for the length when extracting the base part of the insn.
+
+2001-10-09 Bruno Haible <haible@clisp.cons.org>
+
+ * cgen-asm.in (*_cgen_build_insn_regex): Generate a case sensitive
+ regular expression. Fix some formatting problems.
+ * fr30-asm.c: Regenerate.
+ * openrisc-asm.c: Regenerate.
+ * m32r-asm.c: Regenerate.
+
+2001-10-09 Christian Groessler <cpg@aladdin.de>
+
+ * z8k-dis.c (unparse_instr): Fixed formatting. Change disassembly
+ of indirect register memory accesses to be same format the
+ assembler accepts.
+
+2001-10-09 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * sh-opc.h: Fix encoding of least significant nibble of the
+ DSP single data transfer instructions.
+
+ * sh-dis.c (print_insn_shx): Fix decoding of As opcode in DSP
+ instructions.
+
+2001-10-08 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * cgen-asm.in: Fix compile time warning messages in generated
+ C files.
+ * cgen-dis.in: The same.
+ * cgen-ibld.in: The same.
+ * fr30-asm.c: Regenerate.
+ * fr30-desc.c: Regenerate.
+ * fr30-dis.c: Regenerate.
+ * fr30-ibld.c: Regenerate.
+ * fr30-opc.c: Regenerate.
+ * m32r-asm.c: Regenerate.
+ * m32r-desc.c: Regenerate.
+ * m32r-dis.c: Regenerate.
+ * m32r-ibld.c: Regenerate.
+ * m32r-opc.c: Regenerate.
+ * m32r-opinst.c Regenerate.
+ * openrisc-asm.c: Regenerate.
+ * openrisc-desc.c: Regenerate.
+ * openrisc-dis.c: Regenerate.
+ * openrisc-ibld.c: Regenerate.
+ * openrisc-opc.c: Regenerate.
+ * openrisc-opc.h: Regenerate.
+ * Makefile.in: Regenerate.
+ * po/POTFILES.in: Regenerate.
+ * po/opcodes.pot: Regenerate.
+
+2001-10-08 Aldy Hernandez <aldyh@redhat.com>
+
+ * arm-opc.h (arm_opcodes): Add cirrus insns.
+
+ * arm-dis.c (print_insn_arm): Add 'I' case.
+
+2001-10-03 Alan Modra <amodra@bigpond.net.au>
+
+ * po/POTFILES.in: Regenerate.
+ * configure: Regenerate.
+
+2001-10-02 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (Makefile): Depend on bfd/configure.in.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2001-09-30 John Healy <jhealy@redhat.com>
+
+ * cgen-ibld.in (insert_1): Switched bfd_get_bits and bfd_set_bits
+ calls to cgen_get_insn_value and cgen_put_insn_value calls.
+ (extract_1): Switched bfd_get_bits call to cgen_get_insn_value call.
+
+2001-09-30 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * Makefile.am: Update dependencies with "make dep-am".
+ * Makefile.in: Regenerate.
+
+2001-09-26 Alan Modra <amodra@bigpond.net.au>
+
+ * arc-dis.c: Formatting fixes.
+ (my_sprintf): Define using VPARAMS, VA_OPEN, VA_FIXEDARG, VA_CLOSE.
+
+2001-09-21 Bruno Haible <haible@clisp.cons.org>
+
+ * arc-dis.c: Don't include <ctype.h>.
+ * openrisc-desc.c: Likewise.
+ * openrisc-ibld.c: Likewise.
+
+2001-09-20 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * fr30-opc.c: Fix compile time warning messages.
+ * i370-opc.c: Fix compile time warning messages.
+ * i960-dis.c: Fix compile time warning messages.
+ * m32r-asm.c: Fix compile time warning messages.
+ * m32r-desc.c: Fix compile time warning messages.
+ * m32r-dis.c: Fix compile time warning messages.
+ * m32r-ibld.c: Fix compile time warning messages.
+ * m32r-opc.c: Fix compile time warning messages.
+ * m32r-opinst.c: Fix compile time warning messages.
+ * ns32k-dis.c: Fix compile time warning messages.
+ * openrisc-asm.c: Fix compile time warning messages.
+ * openrisc-desc.c: Fix compile time warning messages.
+ * openrisc-dis.c: Fix compile time warning messages.
+ * openrisc-ibld.c: Fix compile time warning messages.
+ * openrisc-opc.c: Fix compile time warning messages.
+ * pdp11-dis.c: Fix compile time warning messages.
+ * tic54x-dis.c: Fix compile time warning messages.
+ * v850-opc.c: Fix compile time warning messages.
+ * vax-dis.c: Fix compile time warning messages.
+ * w65-opc.h: Fix compile time warning messages.
+ * z8k-opc.h: Fix compile time warning messages.
+ * z8kgen.c: Fix compile time warning messages.
+
+2001-09-19 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * arm-dis.c: Fix compile time warning messages.
+ * cgen-asm.c: Fix compile time warning messages.
+ * cgen-dis.c: Fix compile time warning messages.
+ * cris-dis.c: Fix compile time warning messages.
+ * d10v-dis.c: Fix compile time warning messages.
+ * fr30-asm.c: Fix compile time warning messages.
+ * fr30-desc.c: Fix compile time warning messages.
+ * fr30-dis.c: Fix compile time warning messages.
+ * fr30-ibld.c: Fix compile time warning messages.
+
+2001-09-18 Bruno Haible <haible@clisp.cons.org>
+
+ * cgen-asm.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (cgen_parse_keyword): Use ISALNUM instead of isalnum.
+ * cgen-opc.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (cgen_keyword_lookup_name): Use ISALPHA/TOLOWER instead of
+ isalpha/tolower.
+ (cgen_keyword_add): Use ISALNUM instead of isalnum.
+ (hash_keyword_name): Use TOLOWER instead of tolower.
+ * fr30-asm.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (parse_insn_normal): Use TOLOWER/ISSPACE instead of
+ tolower/isspace.
+ (fr30_cgen_assemble_insn): Use ISSPACE instead of isspace.
+ * fr30-desc.c: Don't include <ctype.h>.
+ * fr30-ibld.c: Likewise.
+ * ia64-gen.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (load_insn_classes, parse_resource_users, load_depfile): Use
+ ISSPACE instead of isspace.
+ * m32r-asm.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (parse_insn_normal): Use TOLOWER/ISSPACE instead of
+ tolower/isspace.
+ (m32r_cgen_assemble_insn): Use ISSPACE instead of isspace.
+ * m32r-desc.c: Don't include <ctype.h>.
+ * m32r-ibld.c: Likewise.
+ * openrisc-asm.c: Include "safe-ctype.h" instead of <ctype.h>.
+ (parse_insn_normal): Use TOLOWER/ISSPACE instead of
+ tolower/isspace.
+ (openrisc_cgen_assemble_insn): Use ISSPACE instead of isspace.
+
+2001-09-18 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * Makefile.am: Add rules and dependencies to create the s/390 opcode
+ table out of s390-opc.txt automatically.
+ * configure.in: Add BFD_CC_FOR_BUILD to allow CC_FOR_BUILD to be used.
+ * s390-mkopc.c (dumpTable): Change output to create a complete file.
+ * s390-opc.c: New improved opcode format macros and remove the
+ pregenerated opcode table.
+ * s390-opc.txt: Adapt to new improved opcode format macros.
+
+2001-09-14 David Schleef <ds@schleef.org>
+
+ * ppc-opc.c (VXA, VXA_MASK): Fix mask bits.
+
+2001-09-04 Alan Modra <amodra@bigpond.net.au>
+
+ * i386-dis.c (grps): Don't print the implicit al/ax/eax register
+ for opcode 0xf6 or 0xf7 forms of mul, imul, div, idiv insns.
+
+2001-08-31 Eric Christopher <echristo@redhat.com>
+ Jason Eckhardt <jle@redhat.com>
+
+ * mips-dis.c: Add support for bfd_mach_mipsisa32 and
+ bfd_mach_mipsisa64. Remove bfd_mach_mips32, bfd_mach_mips32_4k,
+ bfd_mach_mips64.
+
+2001-08-31 Andreas Jaeger <aj@suse.de>
+
+ * tic54x-opc.c: Add default initializers to avoid warnings.
+
+ * arc-opc.c: Include "sysdep.h" to get stdio.h as include file.
+ * arc-ext.c: Likewise.
+
+2001-08-28 matthew green <mrg@redhat.com>
+
+ * ppc-opc.c (icbt): Order correctly.
+
+2001-08-27 David Edelsohn <dje@watson.ibm.com>
+ Torbjorn Granlund <tege@swox.com>
+
+ * ppc-opc.c (DS): Add PPC_OPERAND_DS flag.
+ (LS): Define.
+ (insert_ds): Complain if not a multiple of 4.
+ (XSYNC): Define.
+ (XSYNC_MASK): Define.
+ (powerpc_opcodes): Add "slbmte", "lwsync", "ptesync", "slbmfev",
+ "slbmfee". Modify "sync" to use XSYNC_MASK and LS.
+
+2001-08-26 Andreas Jaeger <aj@suse.de>
+
+ * h8500-opc.h: Add default initializers to h8500_table to shut up
+ GCC warnings.
+
+2001-08-25 Andreas Jaeger <aj@suse.de>
+
+ * tic54x-dis.c: Add unused attributes where needed.
+
+ * z8k-dis.c (output_instr): Add unused attribute.
+
+ * h8300-dis.c: Add missing prototypes.
+ (bfd_h8_disassemble): Make static.
+
+ * cris-dis.c: Add missing prototype.
+ * h8500-dis.c: Likewise.
+ * m68hc11-dis.c: Likewise.
+ * pj-dis.c: Likewise.
+ * tic54x-dis.c: Likewise.
+ * v850-dis.c: Likewise.
+ * vax-dis.c: Likewise.
+ * w65-dis.c: Likewise.
+ * z8k-dis.c: Likewise.
+
+ * d10v-dis.c: Add missing prototype.
+ (dis_long): Remove unused variable.
+ (dis_2_short): Likewise.
+
+ * sh-dis.c: Add missing prototypes.
+ * v850-opc.c: Likewise.
+ Add unused attributes where needed.
+
+ * ns32k-dis.c: Add missing prototypes.
+ (bit_extract_simple): Remove unused variable.
+
+2001-08-23 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * s390-opc.c: Add "low or high" and "not low or high"
+ branch instructions for gcc 3.0.
+ * s390-opc.txt: Likewise.
+
+2001-08-21 Andreas Jaeger <aj@suse.de>
+
+ * i960-dis.c: Add parameters for prototypes
+ (ctrl): Add unused attributes.
+ (cobr): Likewise.
+ (put_abs): Likewise.
+
+ * mips-dis.c: Add missing prototypes.
+ * a29k-dis.c: Likewise.
+ * arc-dis.c: Likewise.
+ * ia64-opc.c: Likewise.
+
+ * s390-dis.c: Add missing prototypes.
+ (init_disasm): Remove unused attribute since the parameter is
+ used.
+
+2001-08-16 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * mips-opc.c (M1): Define. Reformatted Code.
+ (mips_builtin_opcodes): Added performance counter opcodes mfpc, mfps,
+ mtps, mtps. Typo.
+
+2001-08-16 Jonathan Larmour <jlarmour@redhat.com>
+
+ * mips-opc.c: R3900s can support all branch likely INSN_MACROs where
+ the corresponding non-likely insn is in MIPS I.
+
+2001-08-13 Kazu Hirata <kazu@hxi.com>
+
+ * mcore-dis.c: Fix formatting.
+ * mips-dis.c: Likewise.
+ * pj-dis.c: Likewise.
+ * z8k-dis.c: Likewise.
+
+2001-08-12 Richard Henderson <rth@redhat.com>
+
+ * cgen-ibld.in (extract_normal): Match type of VALUE and MASK
+ to *VALUEP. Regenerate all cgen files.
+
+2001-08-10 Richard Sandiford <rsandifo@redhat.com>
+
+ * mips-dis.c (print_insn_mips): Remove OPCODE_IS_MEMBER's gp32
+ argument.
+ * mips-opc.c (G6): Undefine.
+ (mips_builtin_opcodes): Remove gp32 entry for "move". Add macro
+ as the first "move" alternative.
+
+2001-08-10 Andreas Jaeger <aj@suse.de>
+
+ * configure.in: Add -Wstrict-prototypes and -Wmissing-prototypes
+ to build warnings.
+ * configure: Regenerate.
+
+2001-08-10 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc-opc.c: Revert 2001-08-08.
+
+2001-08-09 Alan Modra <amodra@bigpond.net.au>
+
+ * dis-buf.c (generic_strcat_address): Add missing prototype.
+ #if 0 the functions as it is unused.
+
+2001-08-08 Alan Modra <amodra@bigpond.net.au>
+
+ 1999-10-25 Torbjorn Granlund <tege@swox.com>
+ * ppc-opc.c: Include "bfd.h".
+ (powerpc_operands): Add new field for reloc type.
+
+2001-07-21 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * mips-dis.c (print_insn_arg): Don't use software integer registers
+ for coprocessor registers.
+ (get_mips_isa): Removed.
+ (is_newabi): New function, checks if NewABI is used.
+ (_print_insn_mips): Get distinction between old ABI and new ABI right.
+
+2001-08-01 Christian Groessler <cpg@aladdin.de>
+
+ * z8kgen.c: Fixed indentation of opt[] array. Include stdio.h to
+ get stderr definition.
+ (internal, gas): Removed warnings.
+ (gas): Create a correct final entry for created array.
+ * z8k-opc.h: Recreated with new z8kgen.
+
+2001-07-28 Kazu Hirata <kazu@hxi.com>
+
+ * i386-dis.c: Fix formatting.
+
+2001-07-28 Matthias Kramm <kramm@quiss.org>
+
+ * i386-dis.c: Change formatting conventions for architecture
+ i386:intel to better match the format of various intel i386
+ assemblers, like nasm, tasm or masm.
+
+2001-07-24 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Update dependencies with "make dep-am".
+ * Makefile.in: Regenerate
+
+2001-07-24 Kazu Hirata <kazu@hxi.com>
+
+ * alpha-dis.c: Fix formatting.
+ * cris-dis.c: Likewise.
+ * d10v-dis.c: Likewise.
+ * d30v-dis.c: Likewise.
+ * m10300-dis.c: Likewise.
+ * tic54x-dis.c: Likewise.
+
+2001-07-23 Kazu Hirata <kazu@hxi.com>
+
+ * m68k-dis.c: Fix formatting.
+ * pj-dis.c: Likewise.
+ * s390-dis.c: Likewise.
+ * z8k-dis.c: Likewise.
+
+2001-07-21 Chris Demetriou <cgd@broadcom.com>
+
+ * mips-opc.c (mips_builtin_opcodes): Sort c.le.s and c.lt.s
+ into the rest of the surrounding definitions.
+
+2001-07-18 Alan Modra <amodra@bigpond.net.au>
+
+ * i386-dis.c (grps): Print l or w suffix, and require mem modrm
+ for lgdt, lidt, sgdt, sidt.
+
+2001-07-13 Philip Blundell <philb@gnu.org>
+
+ * arm-dis.c (print_insn_arm): Use decimal for offsets in LDR/STR.
+
+2001-07-12 Jeff Johnston <jjohnstn@redhat.com>
+
+ * cgen-asm.in: Include "xregex.h" always to enable the libiberty
+ regex support.
+ (@arch@_cgen_build_insn_regex): New routine from Graydon.
+ (@arch@_cgen_assemble_insn): Add Graydon's code to use regex
+ to verify if it is worth parsing the insn as insn "x". Also update
+ error message when insn is not a recognized format of the insn vs
+ when the insn is completely unrecognized.
+
+2001-07-11 Frank Ch. Eigler <fche@redhat.com>
+
+ * cgen-dis.in (print_insn): Use cgen_get_insn_value instead of
+ bfd_get_bits.
+ * cgen-opc.c (cgen_get_insn_value, cgen_put_insn_value): Respect
+ non-zero CGEN_CPU_DESC->insn_chunk_bitsize.
+
+2001-07-09 Andreas Jaeger <aj@suse.de>, Karsten Keil <kkeil@suse.de>
+
+ * i386-dis.c (set_op): Handle 64 bit and 32 bit mode.
+ (OP_J): Use bfd_vma for mask to work properly with 64 bits.
+ (op_address,op_riprel): Use bfd_vma to handle 64 bits.
+
+2001-07-05 Ben Elliston <bje@redhat.com>
+
+ * Makefile.am (CPUDIR): Define.
+ (stamp-m32r): Update dependencies.
+ (stamp-fr30): Ditto.
+ (stamp-openrisc): Ditto.
+ * Makefile.in: Regenerate.
+
+2001-07-03 Zoltan Hidvegi <hzoli@hzoli.2y.net>
+
+ * ppc-opc.c: Fix encoding of 'clf' instruction.
+
+2001-06-30 Geoffrey Keating <geoffk@redhat.com>
+
+ * cgen-ibld.in (insert_normal): Support CGEN_IFLD_SIGN_OPT.
+
+2001-06-28 Geoffrey Keating <geoffk@redhat.com>
+
+ * cgen-asm.c (cgen_parse_keyword): Allow any first character.
+ * cgen-opc.c (cgen_keyword_add): Ignore special first
+ character when building nonalpha_chars field.
+
+2001-06-24 Ben Elliston <bje@redhat.com>
+
+ * m88k-dis.c: Format to conform to GNU coding standards.
+
+2001-06-23 Andreas Jaeger <aj@suse.de>
+
+ * disassemble.c (disassembler_usage): Add unused attribute.
+
+2001-06-22 Eric Christopher <echristo@redhat.com>
+
+ * mips-opc.c: Move prefx to start of the table.
+
+2001-06-22 Stacey Sheldon <ssheldon@Catena.com>
+
+ * arc-opc.c (insert_st_syntax): Fix over-optimisation of ST
+ instruction.
+
+2001-06-22 Pauli <pauli@moreton.com.au>
+
+ * m68k-opc.c: Add wdebug instruction.
+
+2001-06-15 Aldy Hernandez <aldyh@redhat.com>
+
+ * m10300-opc.c (mn10300_opcodes): Change opcode for AM33 subc.
+
+2001-06-14 Geoffrey Keating <geoffk@redhat.com>
+
+ * cgen-asm.c (cgen_parse_keyword): When looking for the
+ boundaries of a keyword, allow any special characters
+ that are actually in one of the allowed keyword.
+ * cgen-opc.c (cgen_keyword_add): Add any special characters
+ to the nonalpha_chars field.
+
+2001-06-12 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * s390-opc.c: Add lgh instruction.
+ * s390-opc.txt: Likewise.
+
+2001-06-11 Alan Modra <amodra@bigpond.net.au>
+
+ * i386-dis.c: Group function prototypes in one place.
+ (FLOATCODE): Redefine as 1.
+ (USE_GROUPS): Redefine as 2.
+ (USE_PREFIX_USER_TABLE): Redefine as 3.
+ (X86_64_SPECIAL): Define as 4.
+ (GRP1b..GRPAMD): Move USE_GROUPS to bytecode1, index to bytecode2.
+ (PREGRP0..PREGRP26): Similarly with USE_PREFIX_USER_TABLE.
+ (dis386_att, dis386_intel, disx86_64_att, disx86_64_intel): Delete.
+ (dis386): New table combining above four tables.
+ (dis386_twobyte_att, dis386_twobyte_intel): Delete.
+ (dis386_twobyte): New table combining above two tables.
+ (x86_64_table): New table to handle x86_64.
+ (X86_64_0): Define.
+ (float_mem_att, float_mem_intel): Delet.
+ (float_mem): New table combining above two tables.
+ (print_insn_i386): Modify for above.
+ (dofloat): Likewise.
+ (putop): Handle '{', '|' and '}' to select alternative mnemonics.
+ Return 0 on success, 1 if no valid alternative.
+ (putop <case 'F'>, <case 'H'>): Print nothing for intel_syntax.
+ (putop <case 'T'>): Move to case 'U', and share case 'Q' code.
+ (putop <case 'I'>): Move to case 'T', and share case 'P' code.
+ (OP_REG <case rAX_reg .. rDI_reg>): Handle as for eAX_reg .. eDI_reg
+ if not 64-bit mode.
+ (OP_I <case q_mode>): Handle as for v_mode if not 64-bit mode.
+ (OP_I64): If not 64-bit mode, call OP_I.
+ OP_OFF64): If not 64-bit mode, call OP_OFF.
+ (OP_ST, OP_STi, OP_SEG, OP_DIR, OP_OFF, OP_OFF64, OP_MMX): Rename
+ 'ignore'/'ignored' to 'bytemode'.
+
+2001-06-10 Alan Modra <amodra@bigpond.net.au>
+
+ * configure.in: Sort 'ta' case statement.
+ * configure: Regenerate.
+
+ * i386-dis.c (dis386_att): Add 'H' to conditional branch and
+ loop,jcxz insns.
+ (disx86_64_att): Likewise.
+ (dis386_twobyte_att): Likewise.
+ (print_insn_i386): Don't print branch hints as a prefix.
+ (putop): 'H' macro prints branch hints.
+ (get64): Kill compile warnings.
+
+2001-06-09 Alexandre Oliva <aoliva@redhat.com>
+
+ * sh-opc.h (sh_table): Don't use empty initializers.
+
+2001-06-06 Christian Groessler <cpg@aladdin.de>
+
+ * z8k-dis.c: Fix formatting.
+ (unpack_instr): Remove unused cases in switch statement. Add
+ safety abort() in default case.
+ (unparse_instr): Add safety abort() in default case.
+
+2001-06-06 Peter Jakubek <pjak@snafu.de>
+
+ * m68k-dis.c (print_insn_m68k): Fix typo.
+ * m68k-opc.c (m68k_opcodes): Correct allowed operands for
+ mcf (ColdFire) div, rem and moveb instructions.
+
+2001-06-06 Alan Modra <amodra@bigpond.net.au>
+
+ * i386-dis.c (cond_jump_flag, loop_jcxz_flag): Define.
+ (cond_jump_mode, loop_jcxz_mode): Define.
+ (dis386_att): Add cond_jump_flag and loop_jcxz_flag as
+ appropriate, and 'F' suffix to loop insns.
+ (disx86_64_att): Likewise.
+ (dis386_twobyte_att): Likewise.
+ (print_insn_i386): Don't output addr prefix for loop, jcxz insns.
+ Output data size prefix for long conditional jumps. Output cs and
+ ds branch hints.
+ (putop): Handle 'F', and mark PREFIX_ADDR used for case 'E'.
+ (OP_J): Don't make PREFIX_DATA used.
+
+2001-06-04 Alexandre Oliva <aoliva@redhat.com>
+
+ * sh-opc.h (sh_table): Complete last element entry to avoid
+ compiler warning.
+
+2001-05-16 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * mips-dis.c (mips_isa_type): Add MIPS r12k support.
+
+2001-05-23 Alan Modra <amodra@one.net.au>
+
+ * arc-opc.c: Whitespace changes.
+
+2001-05-18 Hans-Peter Nilsson <hp@axis.com>
+
+ * cris-opc.c (cris_spec_regs): Add missing initializer field for
+ last element.
+
+2001-05-15 Frank Ch. Eigler <fche@redhat.com>
+
+ * cgen-dis.in (extract_normal): Complete support for min<base case.
+
+2001-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * mips-dis.c (INSNLEN): Rename MAXLEN.
+ (std_reg_names): Replace by mips32_reg_names and mips64_reg_names.
+ (print_insn_arg): Remove $ prefix of register names.
+ (set_mips_isa_type): Remove.
+ (mips_isa_type): New function.
+ (get_mips_isa): New Function.
+ (print_insn_mips): Rename _print_insn_mips.
+ (_print_insn_mips): New function, contains code which was
+ duplicated in print_insn_big_mips and print_insn_little_mips.
+ (print_insn_big_mips): Moved code to _print_insn_mips.
+ (print_insn_little_mips): Likewise.
+ (print_mips16_insn_arg): Remove $ prefix of register names.
+ Print error message before abort.
+
+2001-05-14 J.T. Conklin <jtc@redback.com>
+
+ * ppc-opc.c (powerpc_opcodes): Fixed extended opcode field of
+ simplified mnemonics used for setting PPC750-specific special
+ purpose registers.
+
+2001-05-12 H.J. Lu <hjl@gnu.org>
+
+ * i386-dis.c (print_insn_i386): Always set `mod', `reg' and
+ `rm'.
+
+2001-05-12 Peter Targett <peter.targett@arccores.com>
+
+ * arc-opc.c (arc_reg_names): Correct attribute for lp_count
+ register to r/w. Formatting fixes throughout file.
+
+2001-05-12 Alan Modra <amodra@one.net.au>
+
+ * i386-dis.c (prefix_user_table): Correct movq2dq, movdq2q, and
+ movq operands.
+ (twobyte_has_modrm): Update table.
+ (need_modrm): Give it file scope.
+ (MODRM_CHECK): Define.
+ (dofloat): Use MODRM_CHECK.
+ (OP_E): Likewise.
+ (OP_EM): Likewise.
+ (OP_EX): Likewise.
+
+2001-05-07 Frank Ch. Eigler <fche@redhat.com>
+
+ * cgen-dis.in (default_print_insn): Tolerate min<base instructions
+ even at end of a section.
+ * cgen-ibld.in (extract_normal): Tolerate min!=base!=max instructions
+ by ignoring precariously-unpacked insn_value in favor of raw buffer.
+
+2001-05-03 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * disassemble.c (disassembler_usage): Remove unused attribute.
+
+2001-05-04 Frank Ch. Eigler <fche@redhat.com>
+
+ * m32r-dis.c, -asm.c, -ibld.c: Regenerated with disassembler fixes.
+
+2001-05-04 Frank Ch. Eigler <fche@redhat.com>
+
+ * cgen-dis.in (print_insn): Remove call to read_insn. Instead,
+ assume incoming buffer already has the base insn loaded. Handle
+ smaller-than-base instructions for variable-length case.
+
+2001-05-04 Alan Modra <amodra@one.net.au>
+
+ * i386-dis.c (Ev, Ed): Remove duplicate define.
+ (Gd): Define.
+ (XS): Define.
+ (OP_XS): New function.
+ (dis386_twobyte_att): Correct pinsrw, pextrw, pmovmskb, and
+ movmskp operands.
+ (dis386_twobyte_intel): Likewise.
+ (prefix_user_table): Use MS for maskmovq operand.
+
+2001-04-27 Johan Rydberg <jrydberg@opencores.org>
+
+ * Makefile.am: Add OpenRISC target.
+ * Makefile.in: Regenerated.
+
+ * disassemble.c (disassembler): Recognize the OpenRISC disassembly.
+
+ * configure.in (bfd_openrisc_arch): Add target.
+ * configure: Regenerated.
+
+ * openrisc-asm.c: New file.
+ * openrisc-desc.c: Likewise.
+ * openrisc-desc.h: Likewise.
+ * openrisc-dis.c: Likewise.
+ * openrisc-ibld.c: Likewise.
+ * openrisc-opc.c: Likewise.
+ * openrisc-opc.h: Likewise.
+
+2001-04-24 Christian Groessler <cpg@aladdin.de>
+
+ * z8k-dis.c: add names of control registers (ctrl_names);
+ (seg_length): provides instruction length fixup for segmented
+ mode; (unpack_instr): correctly handle ARG_DISP16, ARG_DISP12,
+ CLASS_0DISP7, CLASS_1DISP7, CLASS_DISP8 and CLASS_PR cases;
+ (unparse_intr): handle CLASS_PR, print addresses without '#'
+ * z8k-opc.h: re-created with new z8kgen
+ * z8kgen.c: merged in fixes which were in existing z8k-opc.h; new
+ entries for ldctl/ldctlb instruction
+
+2001-04-06 Andreas Jaeger <aj@suse.de>
+
+ * i386-dis.c: Add ffreep instruction.
+
+2001-03-30 Alexandre Oliva <aoliva@redhat.com>
+
+ * ppc-opc.c (insert_mbe): Shift mask initializer as long.
+
+2001-03-24 Alan Modra <alan@linuxcare.com.au>
+
+ * i386-dis.c (PREGRP25): Define.
+ (dis386_twobyte_att): Use here in place of "movntq" entry.
+ (dis386_twobyte_intel): Likewise.
+ (prefix_user_table): Add PREGRP25 entry for "movntq" and "movntdq".
+ (PREGRP26): Define.
+ (dis386_twobyte_att): Use here.
+ (dis386_twobyte_intel): Likewise.
+ (prefix_user_table): Add PREGRP26 entry for "punpcklqdq".
+ (prefix_user_table <maskmovdqu>): XM operand, not MX.
+ (prefix_user_table): Cosmetic changes to "bad" entries.
+
+2001-03-23 Nick Clifton <nickc@redhat.com>
+
+ * mips-opc.c: Remove extraneous whitespace.
+ * mips-dis.c: Remove extraneous whitespace.
+
+2001-03-22 Ben Elliston <bje@redhat.com>
+
+ * cgen-asm.in (@arch@_cgen_assemble_insn): Move tmp_errmsg
+ declaration inside CGEN_VERBOSE_ASSEMBLER_ERRORS conditional.
+ * cgen-ibld.in (put_insn_int_value): Mark cd parameter as unused
+ to allay a compiler warning.
+
+2001-03-22 Alan Modra <alan@linuxcare.com.au>
+
+ * i386-dis.c (dis386_twobyte_att): Add entries for paddq, psubq.
+ (dis386_twobyte_intel): Likewise.
+ (twobyte_has_modrm): Set entry for paddq, psubq.
+
+2001-03-20 Patrick Macdonald <patrickm@redhat.com>
+
+ * cgen-dis.in (print_insn_@arch@): Add support for target machine
+ determination via CGEN_COMPUTE_MACH.
+ * fr30-desc.c: Regenerate.
+ * fr30-dis.c: Regenerate.
+ * fr30-opc.h: Regenerate.
+ * m32r-desc.c: Regenerate.
+ * m32r-dis.c: Regenerate.
+ * m32r-opc.h: Regenerate.
+ * m32r-opinst.c: Regenerate.
+
+2001-03-20 H.J. Lu <hjl@gnu.org>
+
+ * configure.in: Remove the redundent AC_ARG_PROGRAM.
+ * configure: Rebuild.
+
+2001-03-19 Jim Wilson <wilson@redhat.com>
+
+ * ia64-gen.c (fetch_insn_class): If xsect, then ignore comment and
+ notestr if larger than xsect.
+ (in_class): Handle format M5.
+ * ia64-asmtab.c: Regnerate.
+
+2001-03-19 John David Anglin <dave@hiauly1.hia.nrc.ca>
+
+ * vax-dis.c (print_insn_vax): Only fetch two bytes if the info buffer
+ has more than one byte left to read.
+
+2001-03-16 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * s390-opc.c: Add new opcodes. Smooth out formatting.
+ * s390-opc.txt: Add new opcodes.
+
+2001-03-06 Nick Clifton <nickc@redhat.com>
+
+ * arm-dis.c (print_insn_thumb): Compute destination address
+ of BLX(1) instruction by taking bit 1 from PC and not from bit
+ 0 of the offset.
+
+2001-03-06 Igor Shevlyakov <igor@windriver.com>
+
+ * m68k-dis.c (print_insn_m68k): Recognize Coldfire CPUs
+ so command line switches will work.
+
+2001-03-05 Dave Brolley <brolley@redhat.com>
+
+ * fr30-asm.c: Regenerate.
+ * fr30-desc.c: Regenerate.
+ * fr30-desc.h: Regenerate.
+ * fr30-dis.c: Regenerate.
+ * fr30-ibld.c: Regenerate.
+ * fr30-opc.c: Regenerate.
+ * fr30-opc.h: Regenerate.
+ * m32r-asm.c: Regenerate.
+ * m32r-desc.c: Regenerate.
+ * m32r-desc.h: Regenerate.
+ * m32r-dis.c: Regenerate.
+ * m32r-ibld.c: Regenerate.
+ * m32r-opc.c: Regenerate.
+ * m32r-opc.h: Regenerate.
+ * m32r-opinst.c: Regenerate.
+
+2001-02-28 Igor Shevlyakov <igor@windriver.com>
+
+ * m68k-opc.c: fix cpushl according to Motorola. Enable
+ bunch of instructions for Coldfire 5407 and add all new.
+
+2001-02-27 Alan Modra <alan@linuxcare.com.au>
+
+ * configure.in (BFD_VERSION): Do without grep.
+ * configure: Regenerate.
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2001-02-23 David Mosberger <davidm@hpl.hp.com>
+
+ * ia64-opc-a.c: Add missing pseudo-ops for "cmp" and "cmp4".
+ * ia64-asmtab.c: Regenerate.
+
+2001-02-21 David Mosberger <davidm@hpl.hp.com>
+
+ * ia64-opc-d.c (ia64_opcodes_d): Break the "add" pattern into two
+ separate variants: one for IMM22 and the other for IMM14.
+ * ia64-asmtab.c: Regenerate.
+
+2001-02-21 Greg McGary <greg@mcgary.org>
+
+ * cgen-opc.c (cgen_get_insn_value): Add missing `return'.
+
+2001-02-20 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.am (ia64-ic.tbl): Remove the target.
+ (ia64-raw.tbl): Likewise.
+ (ia64-waw.tbl): Likewise.
+ (ia64-war.tbl): Likewise.
+ (ia64-asmtab.c): Generate it in the source directory.
+ * Makefile.in: Regenerated.
+
+2001-02-18 lars brinkhoff <lars@nocrew.org>
+
+ * Makefile.am: Add PDP-11 target.
+ * configure.in: Likewise.
+ * disassemble.c: Likewise.
+ * pdp11-dis.c: New file.
+ * pdp11-opc.c: New file.
+
+2001-02-14 Jim Wilson <wilson@redhat.com>
+
+ * ia64-ic.tbl: Update from Intel. Add setf to fr-writers.
+ * ia64-asmtab.c: Regenerate.
+
+2001-02-12 Jan Hubicka <jh@suse.cz>
+
+ * i386-dis.c (prefix_user_t): Add 'Y' to SSE ineger converison
+ instructions.
+ (putop): Handle 'Y'
+
+2001-02-11 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * mips-dis.c (print_insn_arg): Use top four bits of the address of
+ the following instruction not of the jump itself for the jump
+ target.
+ (print_mips16_insn_arg): Likewise.
+
+2001-02-11 Michael Sokolov <msokolov@ivan.Harhan.ORG>
+
+ * Makefile.am (stamp-lib): ranlib the libopcodes.a in the build
+ directory.
+ * Makefile.in: Regenerate.
+
+2001-02-09 Schwidefsky <schwidefsky@de.ibm.com>
+
+ * Makefile.am: Add linux target for S/390.
+ * Makefile.in: Likewise.
+ * configure.in: Likewise.
+ * disassemble.c: Likewise.
+ * s390-dis.c: New file.
+ * s390-mkopc.c: New file.
+ * s390-opc.c: New file.
+ * s390-opc.txt: New file.
+
+2001-02-05 Jim Wilson <wilson@redhat.com>
+
+ * ia64-asmtab.c: Revert 2000-12-16 change.
+
+2001-02-02 Patrick Macdonald <patrickm@redhat.com>
+
+ * fr30-desc.h: Regenerate with CGEN_MAX_SYNTAX_ELEMENTS.
+ * m32r-desc.h: Regenerate.
+
+2001-02-01 Jan Hubicka <jh@suse.cz>
+
+ * i386-dis.c (dis386_att, grps): Use 'T' for push/pop
+ (putop): Handle 'T', alphabetize order, fix 'I' handling in Intel syntax
+
+2001-01-14 Alan Modra <alan@linuxcare.com.au>
+
+ * hppa-dis.c (print_insn_hppa): Handle '>' and '<' arg types.
+
+2001-01-13 Nick Clifton <nickc@redhat.com>
+
+ * disassemble.c: Remove spurious white space.
+
+2001-01-13 Jan Hubicka <jh@suse.cz>
+
+ * i386-dis.c (dis386_att, disx86_64_att): Fix ret, lret and iret
+ templates.
+
+2001-01-11 Peter Targett <peter.targett@arccores.com>
+
+ * configure.in: Add arc-ext.lo for bfd_arc_arch selection.
+ * Makefile.am (C_FILES): Add arc-ext.c.
+ (ALL_MACHINES) Add arc-ext.lo.
+ (INCLUDES) Add opcode directory to list.
+ New dependency entry for arc-ext.lo.
+ * disassemble.c (disassembler): Correct call to
+ arc_get_disassembler.
+ * arc-opc.c: New update for ARC, including full base
+ instructions for ARC variants.
+ * arc-dis.h, arc-dis.c: New update for ARC, including
+ extensibility functionality.
+ * arc-ext.h, arc-ext.c: New files for handling extensibility.
+
+2001-01-10 Jan Hubicka <jh@suse.cz>
+
+ * i386-dis.c (PREGRP15 - PREGRP24): New.
+ (dis386_twobyt): Add SSE2 instructions.
+ (twobyte_uses_SSE_prefix: Rename from ... ; add new SSE instructions.
+ (twobyte_uses_f3_prefix): ... this one.
+ (grps): Add SSE instructions.
+ (prefix_user_table): Add two new slots; add SSE2 instructions.
+ (print_insn_i386): Rename uses_f3_prefix to uses_SSE_prefix;
+ Handle the REPNZ and Data16 prefixes as well; do proper lookup
+ to prefix_user_table.
+ (OP_E): Accept mfence and lfence as well.
+ (OP_MMX): Data16 prefix turns MMX to SSE; support REX extensions.
+ (OP_XMM): Support REX extensions.
+ (OP_EM): Likewise.
+ (OP_EX): Likewise.
+
+2001-01-09 Nick Clifton <nickc@redhat.com>
+
+ * arm-dis.c (print_insn): Set pc to zero for instructions with
+ a reloc associated with them.
+
+2001-01-09 Jeff Johnston <jjohnstn@redhat.com>
+
+ * cgen-asm.in (parse_insn_normal): Changed syn to be
+ CGEN_SYNTAX_CHAR_TYPE. Changed all references to *syn
+ as character to use CGEN_SYNTAX_CHAR macro and all comparisons
+ to '\0' to use 0 instead.
+ * cgen-dis.in (print_insn_normal): Ditto.
+ * cgen-ibld.in (insert_insn_normal, extract_insn_normal): Ditto.
+
+2001-01-05 Jan Hubicka <jh@suse.cz>
+
+ * i386-dis.c: Add x86_64 support.
+ (rex): New static variable.
+ (REX_MODE64, REX_EXTX, REX_EXTY, REX_EXTZ): New constants.
+ (USED_REX): New macro.
+ (Ev, Ed, Rm, Iq, Iv64, Cm, Dm, Rm*, Ob64, Ov64): New macros.
+ (OP_I64, OP_OFF64, OP_IMREG): New functions.
+ (OP_REG, OP_OFF): Declare.
+ (get64, get32, get32s): New functions.
+ (r??_reg): New constants.
+ (dis386_att): Change templates of instruction implicitly promoted
+ to 64bit; change e?? to RMe?? for unwind RM byte instructions.
+ (grps): Likewise.
+ (dis386_intel): Likewise.
+ (dixx86_64_att): New table based on dis386_att.
+ (dixx86_64_intel): New table based on dis386_intel.
+ (names64, names8rex): New global variable.
+ (names32, names16): Add extended registers.
+ (prefix_user_t): Recognize rex prefixes.
+ (prefix_name): Print REX prefixes nicely.
+ (op_riprel): New global variable.
+ (start_pc): Set type to bfd_vma.
+ (print_insn_i386): Detect the 64bit mode and use proper table;
+ move ckprefix after initializing the buffer; output unused rex prefixes;
+ output information about target of RIP relative addresses.
+ (putop): Support 'O' and 'I'. Update handling of "P', 'Q', 'R' and 'S';
+ (print_operand_value): New function.
+ (OP_E, OP_G, OP_REG, OP_I, OP_J, OP_DIR, OP_OFF, OP_D): Add support for
+ REX prefix and new modes.
+ (get64, get32s): New.
+ (get32): Return bfd_signed_vma type.
+ (set_op): Initialize the op_riprel.
+ * disassemble.c (disassembler): Recognize the x86-64 disassembly.
+
+2001-01-03 Richard Sandiford <r.sandiford@redhat.com>
+
+ cgen-dis.in (read_insn): Use bfd_get_bits()
+
+2001-01-02 Richard Sandiford <rsandifo@redhat.com>
+
+ * cgen-dis.c (hash_insn_array): Use bfd_put_bits().
+ (hash_insn_list): Likewise
+ * cgen-ibld.in (insert_1): Use bfd_put_bits() and bfd_get_bits().
+ (extract_1): Use bfd_get_bits().
+ (extract_normal): Apply sign extension to both extraction
+ methods.
+ * cgen-opc.c (cgen_get_insn_value): Use bfd_get_bits()
+ (cgen_put_insn_value): Use bfd_put_bits()
+
+2000-12-28 Frank Ch. Eigler <fche@redhat.com>
+
+ * cgen-asm.in (parse_insn_normal): Print better error message for
+ instructions with missing operands.
+
+2000-12-21 Santeri Paavolainen <santtu@ssh.com>
+
+ * cgen-opc.c: Include alloca.h if HAVE_ALLOCA_H is defined.
+
+2000-12-16 Nick Clifton <nickc@redhat.com>
+
+ * Makefile.in: Regenerate.
+ * aclocal.m4: Regenerate.
+ * config.in: Regenerate.
+ * configure.in: Add spacing.
+ * configure: Regenerate.
+ * ia64-asmtab.c: Regenerate.
+ * po/opcodes.pot: Regenerate.
+
+2000-12-12 Frank Ch. Eigler <fche@redhat.com>
+
+ * cgen-asm.in (@arch@_cgen_assemble_insn): Prefer printing insert-time
+ error messages over later parse-time ones.
+
+2000-12-12 Jim Wilson <wilson@redhat.com>
+
+ * ia64-dis.c (print_insn_ia64): Cast away const on ia64_free_opcode
+ argument.
+ * ia64-gen.c (insert_deplist): Cast sizeof result to int.
+ (print_dependency_table): Print NULL if semantics field not set.
+ (insert_opcode_dependencies): Mark cmp parameter as unused.
+ (print_main_table): Use fprintf_vma to print long long fields.
+ (main): Mark argv paramter as unused. Convert to old style definition.
+ * ia64-opc.c (ia64_find_dependency): Cast sizeof result to int.
+ * ia64-asmtab.c: Regnerate.
+
+2000-12-09 Nick Clifton <nickc@redhat.com>
+
+ * m32r-dis.c (print_insn): Prevent re-read of instruction from
+ wrong address.
+
+ * fr30-dis.c: Regenerate.
+
+2000-12-08 Peter Targett <peter.targett@arccores.com>
+
+ * configure.in: Add arc-ext.lo for bfd_arc_arch selection.
+ * Makefile.am (C_FILES): Add arc-ext.c.
+ (ALL_MACHINES) Add arc-ext.lo.
+ (INCLUDES) Add opcode directory to list.
+ New dependency entry for arc-ext.lo.
+ * disassemble.c (disassembler): Correct call to
+ arc_get_disassembler.
+ * arc-opc.c: New update for ARC, including full base
+ instructions for ARC variants.
+ * arc-dis.h, arc-dis.c: New update for ARC, including
+ extensibility functionality.
+ * arc-ext.h, arc-ext.c: New files for handling extensibility.
+
+2000-12-03 Chris Demetriou cgd@sibyte.com
+
+ * mips-opc.c (mips_builtin_opcodes): Use the WR_HILO, RD_HILO,
+ MOD_HILO, and MOD_LO macros.
+
+ * mips-opc.c (M1, M2): Delete.
+ (mips_builtin_opcodes): Remove all uses of M1.
+
+ * mips-opc.c (mips_builtin_opcodes): Make the dmfc2 and dmtc2
+ instructions take "G" format second operands and use the
+ correct flags.
+ There are mfc3 and mtc3 opcodes, so add dmfc3 and dmtc3 opcodes to
+ match.
+ Delete "sel" code operands from mfc1 and mtc1.
+ Add MIPS64 opcode changes (dclo, dclz), and "sel" code variants
+ for dm[ft]c[023].
+
+2000-12-03 Ed Satterthwaite ehs@sibyte.com and
+ Chris Demetriou cgd@sibyte.com
+
+ * mips-opc.c (mips_builtin_opcodes): Finish additions
+ for MIPS32 support, and clean up existing entries for
+ aesthetics, consistency with the MIPS32 ISA, and
+ with consistency the rest of the table.
+
+2000-12-01 Nick Clifton <nickc@redhat.com>
+
+ * mips16-opc.c (mips16_opcodes): Add initialiser for membership
+ field.
+
+2000-12-01 Chris Demetriou <cgd@sibyte.com>
+
+ mips-dis.c (print_insn_arg): Handle new 'U' and 'J' argument
+ specifiers. Update 'B' for new constant names, and remove
+ 'm'.
+ mips-opc.c (mips_builtin_opcodes): Place "pref" and "ssnop"
+ near the top of the array, so they are disassembled properly.
+ Enable "ssnop" for MIPS32. Add "break" variant with 20 bit
+ code for MIPS32. Update "clo" and "clz" to use 'U' operand
+ specifier. Add 'H' format specifier variants for "mfc1,"
+ "mfc2," "mfc3," "mtc1," "mtc2," and "mtc3" for MIPS32. Update
+ MIPS32 "sdbbp" to use 'B' operand specifier. Add MIPS32
+ "wait" variant which uses 'J' operand specifier.
+
+ * mips-dis.c (set_mips_isa_type): Update to use
+ CPU_UNKNOWN and ISA_* constants. Add bfd_mach_mips32 case.
+ Replace bfd_mach_mips4K with bfd_mach_mips32_4k case.
+ * mips-opc.c (I32): New constant for instructions added in
+ MIPS32.
+ (P4): Delete.
+ (mips_builtin_opcodes) Replace all uses of P4 with I32.
+
+ * mips-dis.c (set_mips_isa_type): Add cases for
+ bfd_mach_mips5 and bfd_mach_mips64.
+ * mips-opc.c (I64): New definitions.
+
+ * mips-dis.c (set_mips_isa_type): Add case for
+ bfd_mach_mips_sb1.
+
+2000-11-28 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * sh-dis.c (print_insn_ddt): Make insn_x, insn_y unsigned.
+ (print_insn_ppi): Make nib1, nib2, nib3 unsigned.
+ Initialize variable dc to NULL.
+ (print_insn_shx): Remove unused label d_reg_n.
+
+2000-11-24 Nick Clifton <nickc@redhat.com>
+
+ * arm-opc.h: Add new opcode formatting parameter 'B'.
+ (arm_opcodes): Add XScale, v5, and v5te instructions.
+ (thumb_opcodes): Add v5t instructions.
+
+ * arm-dis.c (print_insn_arm): Handle new 'B' format
+ parameter.
+ (print_insn_thumb): Decode BLX(1) instruction.
+
+2000-11-21 Chris Demetriou <cgd@sibyte.com>
+
+ * mips-opc.c: Fix file header comment.
+
+2000-11-14 Hans-Peter Nilsson <hp@axis.com>
+
+ * cris-dis.c (cris_get_disassembler): If abfd is NULL, return
+ print_insn_cris_with_register_prefix.
+
+2000-11-11 Alexandre Oliva <aoliva@redhat.com>
+
+ * sh-opc.h: The operand of `mov.w r0, (<disp>,GBR)' is IMM1, not 0.
+
+2000-11-07 Matthew Green <mrg@redhat.com>
+
+ * cgen-dis.in (print_insn): All insns which can fit into insn_value
+ must be loaded there in their entirety.
+
+2000-10-20 Jakub Jelinek <jakub@redhat.com>
+
+ * sparc-dis.c (v9a_asr_reg_names): Add v9b ASRs.
+ (compute_arch_mask): Add v8plusb and v9b machines.
+ (print_insn_sparc): siam mode decoding, accept ASRs up to 25.
+ * sparc-opc.c: Support for Cheetah instruction set.
+ (prefetch_table): Add #invalidate.
+
+2000-10-16 Nick Clifton <nickc@redhat.com>
+
+ * mcore-dis.c (imsk): Change mask for OC to 0xFE00.
+
+2000-10-06 Dave Brolley <brolley@redhat.com>
+
+ * fr30-desc.h: Regenerate.
+ * m32r-desc.h: Regenerate.
+ * m32r-ibld.c: Regenerate.
+
+2000-10-05 Jim Wilson <wilson@redhat.com>
+
+ * ia64-ic.tbl: Update from Intel.
+ * ia64-asmtab.c: Regenerate.
+
+2000-10-04 Kazu Hirata <kazu@hxi.com>
+
+ * ia64-gen.c: Convert C++-style comments to C-style comments.
+ * tic54x-dis.c: Likewise.
+
+2000-09-29 Hans-Peter Nilsson <hp@axis.com>
+
+ Changes to add dollar prefix to registers for files where user symbols
+ don't have a leading underscore. Fix formatting.
+ * cris-dis.c (REGISTER_PREFIX_CHAR): New.
+ (format_reg): Add parameter with_reg_prefix. All callers changed.
+ (print_with_operands): Ditto.
+ (print_insn_cris_generic): Renamed from print_insn_cris, add
+ parameter with_reg_prefix.
+ (print_insn_cris_with_register_prefix,
+ print_insn_cris_without_register_prefix, cris_get_disassembler):
+ New.
+ * disassemble.c (disassembler) [ARCH_cris]: Call cris_get_disassembler.
+
+2000-09-22 Jim Wilson <wilson@redhat.com>
+
+ * ia64-opc-f.c (ia64_opcodes_f): Add fpcmp pseudo-ops for
+ gt, ge, ngt, and nge.
+ * ia64-asmtab.c: Regenerate.
+
+ * ia64-dis.c (print_insn_ia64): Revert Aug 7 byte skip count change.
+ * ia64-gen.c (parse_semantics): Handle IA64_DVS_STOP.
+ (lookup_specifier): Handle "PR%, 1 to 15" and "PR%, 16 to 62".
+ * ia64-ic.tbl, ia64-raw.tbl, ia64-war.tbl, ia64-waw.tbl: Update.
+ * ia64-asmtab.c: Regnerate.
+
+2000-09-13 Anders Norlander <anorland@acc.umu.se>
+
+ * mips-opc.c (mips_builtin_opcodes): Support cache instruction on 4K cores.
+ Add mfc0 and mtc0 with sub-selection values.
+ Add clo and clz opcodes.
+ Add msub and msubu instructions for MIPS32.
+ Add madd/maddu aliases for mad/madu for MIPS32.
+ Support wait, deret, eret, movn, pref for MIPS32.
+ Support tlbp, tlbr, tlbwi, tlbwr.
+ (P4): New define.
+
+ * mips-dis.c (print_insn_arg): Print sdbbp 'm' args.
+ (print_insn_arg): Handle 'H' args.
+ (set_mips_isa_type): Recognize 4K.
+ Use CPU_* defines instead of hardcoded numbers.
+
+2000-09-11 Catherine Moore <clm@redhat.com>
+
+ * d30v-opc.c (d30v_operand_t): New operand type Rb2.
+ (d30v_format_tab): Use Rb2 for modinc and moddec.
+
+2000-09-07 Catherine Moore <clm@redhat.com>
+
+ * d30v-opc.c (d30v_format_tab): Use format Ra for
+ modinc and moddec.
+
+2000-09-06 Alexandre Oliva <aoliva@redhat.com>
+
+ * configure: Rebuilt with new libtool.m4.
+
+2000-09-05 Nick Clifton <nickc@redhat.com>
+
+ * configure: Regenerate.
+ * po/opcodes.pot: Regenerate.
+
+2000-08-31 Alexandre Oliva <aoliva@redhat.com>
+
+ * acinclude.m4: Include libtool and gettext macros from the
+ top level.
+ * aclocal.m4, configure: Rebuilt.
+
+2000-08-30 Kazu Hirata <kazu@hxi.com>
+
+ * tic80-dis.c: Fix formatting.
+
+2000-08-29 Kazu Hirata <kazu@hxi.com>
+
+ * w65-dis.c: Fix formatting.
+
+2000-08-28 Mark Hatle <mhatle@mvista.com>
+
+ * ppc-opc.c: Add XTLB macro for a few PPC 4xx extended mnemonics.
+ (powerpc_opcodes): Add table entries for PPC 405 instructions.
+ Changed rfci, icbt, mfdcr, dccci, mtdcr, iccci from PPC to PPC403
+ instructions. Added extended mnemonic mftbl as defined in the
+ 405GP manual for all PPCs.
+
+2000-08-28 Jim Wilson <wilson@redhat.com>
+
+ * ia64-dis.c (print_insn_ia64): Add failed label after ia64_free_opcode
+ call. Change last goto to use failed instead of done.
+
+2000-08-28 Dave Brolley <brolley@redhat.com>
+
+ * cgen-ibld.in (cgen_put_insn_int_value): New function.
+ (insert_normal): Allow for non-zero word_offset with CGEN_INT_INSN_P.
+ (insert_insn_normal): Use cgen_put_insn_int_value with CGEN_INT_INSN_P.
+ (extract_normal): Allow for non-zero word_offset with CGEN_INT_INSN_P.
+ * cgen-dis.in (read_insn): New static function.
+ (print_insn): Use read_insn to read the insn into the buffer and set
+ up for disassembly.
+ (print_insn): in CGEN_INT_INSN_P, make sure that the entire insn is
+ in the buffer.
+ * fr30-asm.c: Regenerated.
+ * fr30-desc.c: Regenerated.
+ * fr30-desc.h: Regenerated.
+ * fr30-dis.c: Regenerated.
+ * fr30-ibld.c: Regenerated.
+ * fr30-opc.c: Regenerated.
+ * fr30-opc.h: Regenerated.
+ * m32r-asm.c: Regenerated.
+ * m32r-desc.c: Regenerated.
+ * m32r-desc.h: Regenerated.
+ * m32r-dis.c: Regenerated.
+ * m32r-ibld.c: Regenerated.
+ * m32r-opc.c: Regenerated.
+
+2000-08-28 Kazu Hirata <kazu@hxi.com>
+
+ * tic30-dis.c: Fix formatting.
+
+2000-08-27 Kazu Hirata <kazu@hxi.com>
+
+ * sh-dis.c: Fix formatting.
+
+2000-08-24 David Edelsohn <dje@watson.ibm.com>
+
+ * ppc-opc.c (powerpc_opcodes): Add rfid, mtsrd, mtsrdin, mtmsrd.
+
+2000-08-24 Kazu Hirata <kazu@hxi.com>
+
+ * z8k-dis.c: Fix formatting.
+
+2000-08-16 Jim Wilson <wilson@redhat.com>
+
+ * ia64-ic.tbl (pr-readers-nobr-nomovpr): Add addl, adds. Delete
+ break, mov-immediate, nop.
+ * ia64-opc-f.c: Delete fpsub instructions.
+ * ia64-opc-m.c: Add POSTINC to all instructions with postincrement
+ address operand. Rewrite using macros to avoid long lines.
+ * ia64-opc.h (POSTINC): Define.
+ * ia64-asmtab.c: Regenerate.
+
+2000-08-15 Jim Wilson <wilson@redhat.com>
+
+ * ia64-ic.tbl: Add missing entries.
+
+2000-08-08 Jason Eckhardt <jle@redhat.com>
+
+ * i860-dis.c (print_br_address): Change third argument from int
+ to long.
+
+2000-08-07 Richard Henderson <rth@redhat.com>
+
+ * ia64-dis.c (print_insn_ia64): Get byte skip count correct
+ for MLI templates. Handle IA64_OPND_TGT64.
+
+2000-08-04 Ben Elliston <bje@redhat.com>
+
+ * cgen-dis.in, cgen-asm.in, cgen-ibld.in: New files.
+ * cgen.sh: Likewise.
+
+2000-08-02 Jim Wilson <wilson@redhat.com>
+
+ * ia64-dis.c (print_insn_ia64): Call ia64_free_opcode at end.
+
+2000-07-29 Marek Michalkiewicz <marekm@linux.org.pl>
+
+ * avr-dis.c (avr_operand): Use PARAMS macro in declaration.
+ Change return type from void to int. Check the combination
+ of operands, return 1 if valid. Fix to avoid BUF overflow.
+ Report undefined combinations of operands in COMMENT.
+ Report internal errors to stderr. Output the adiw/sbiw
+ constant operand in both decimal and hex.
+ (print_insn_avr): Disassemble ldd/std with displacement of 0
+ as ld/st. Check avr_operand () return value, handle invalid
+ combinations of operands like unknown opcodes.
+
+2000-07-28 Ben Elliston <bje@redhat.com>
+
+ * Makefile.am (CGEN, CGENDEPS, CGENDIR, CGENFLAGS): New.
+ (run-cgen, stamp-m32r, stamp-fr30): New targets.
+ * Makefile.in: Regenerate.
+ * configure.in: Add --enable-cgen-maint option.
+ * configure: Regenerate.
+
+2000-07-26 Dave Brolley <brolley@redhat.com>
+
+ * cgen-opc.c (cgen_hw_lookup_by_name): 'i' is now unsigned.
+ (cgen_hw_lookup_by_num): Ditto.
+ (cgen_operand_lookup_by_name): Ditto.
+ (print_address): Ditto.
+ (print_keyword): Ditto.
+ * cgen-dis.c (hash_insn_array): Mark unused parameters with
+ ATTRIBUTE_UNUSED.
+ * cgen-asm.c (hash_insn_array): Mark unused parameters with
+ ATTRIBUTE_UNUSED.
+ (cgen_parse_keyword): Ditto.
+
+2000-07-22 Jason Eckhardt <jle@redhat.com>
+
+ * i860-dis.c: New file.
+ (print_insn_i860): New function.
+ (print_br_address): New function.
+ (sign_extend): New function.
+ (BITWISE_OP): New macro.
+ (I860_REG_PREFIX): New macro.
+ (grnames, frnames, crnames): New structures.
+
+ * disassemble.c (ARCH_i860): Define.
+ (disassembler): Add check for bfd_arch_i860 to set disassemble
+ function to print_insn_i860.
+
+ * Makefile.in (CFILES): Added i860-dis.c.
+ (ALL_MACHINES): Added i860-dis.lo.
+ (i860-dis.lo): New dependences.
+
+ * configure.in: New bits for bfd_i860_arch.
+
+ * configure: Regenerated.
+
+2000-07-20 Hans-Peter Nilsson <hp@axis.com>
+
+ * Makefile.am (CFILES): Add cris-dis.c and cris-opc.c.
+ (ALL_MACHINES): Add cris-dis.lo and cris-opc.lo.
+ (cris-dis.lo, cris-opc.lo): New rules.
+ * Makefile.in: Rebuild.
+ * configure.in (bfd_cris_arch): New target.
+ * configure: Rebuild.
+ * disassemble.c (ARCH_cris): Define.
+ (disassembler): Support ARCH_cris.
+ * cris-dis.c, cris-opc.c: New files.
+ * po/POTFILES.in, po/opcodes.pot: Regenerate.
+
+2000-07-11 Jakub Jelinek <jakub@redhat.com>
+
+ * sparc-opc.c (sparc_opcodes): popc has 0 in rs1, not rs2.
+ Reported by Bill Clarke <llib@computer.org>.
+
+2000-07-09 Geoffrey Keating <geoffk@redhat.com>
+
+ * ppc-opc.c (powerpc_opcodes): Correct suffix for vslw.
+ Patch by Randall J Fisher <rfisher@ecn.purdue.edu>.
+
+2000-07-09 Alan Modra <alan@linuxcare.com.au>
+
+ * hppa-dis.c (fput_reg, fput_fp_reg, fput_fp_reg_r, fput_creg,
+ fput_const, extract_3, extract_5_load, extract_5_store,
+ extract_5r_store, extract_5R_store, extract_10U_store,
+ extract_5Q_store, extract_11, extract_14, extract_16, extract_21,
+ extract_12, extract_17, extract_22): Prototype.
+ (print_insn_hppa): Rename inner block opcode -> opc to avoid
+ shadowing outer block.
+ (GET_BIT): Define.
+
+2000-07-05 DJ Delorie <dj@redhat.com>
+
+ * MAINTAINERS: new
+
+2000-07-04 Alexandre Oliva <aoliva@redhat.com>
+
+ * arm-dis.c (print_insn_arm): Output combinations of PSR flags.
+
+2000-07-03 Marek Michalkiewicz <marekm@linux.org.pl>
+
+ * avr-dis.c (avr_operand): Change _ () to _() around all strings
+ marked for translation (exception from the usual coding style).
+ (print_insn_avr): Initialize insn2 to avoid warnings.
+
+2000-07-03 Kazu Hirata <kazu@hxi.com>
+
+ * h8300-dis.c (bfd_h8_disassemble): Improve readability.
+ * h8500-dis.c: Fix formatting.
+
+2000-07-01 Alan Modra <alan@linuxcare.com.au>
+
+ * Makefile.am (DEP): Fix 2000-06-22. grep after running dep.sed
+ (CLEANFILES): Add DEPA.
+ * Makefile.in: Regenerate.
+
+2000-06-26 Scott Bambrough <scottb@netwinder.org>
+
+ * arm-dis.c (regnames): Add an additional register set to match
+ the set used by GCC. Make it the default.
+
+2000-06-22 Alan Modra <alan@linuxcare.com.au>
+
+ * Makefile.am (DEP): grep for leading `/' in DEP1, and fail if we
+ find one.
+ * Makefile.in: Regenerate.
+
+2000-06-20 H.J. Lu <hjl@gnu.org>
+
+ * Makefile.am: Rebuild dependency.
+ * Makefile.in: Rebuild.
+
+2000-06-18 Stephane Carrez <stcarrez@worldnet.fr>
+
+ * Makefile.in, configure: regenerate
+ * disassemble.c (disassembler): Recognize ARCH_m68hc12,
+ ARCH_m68hc11.
+ * m68hc11-dis.c (read_memory, print_insn, print_insn_m68hc12):
+ New functions.
+ * configure.in: Recognize m68hc12 and m68hc11.
+ * m68hc11-dis.c, m68hc11-opc.c: New files for support of m68hc1x
+ * Makefile.am (CFILES, ALL_MACHINES): New files for disassembly
+ and opcode generation for m68hc11 and m68hc12.
+
+2000-06-16 Nick Duffek <nsd@redhat.com>
+
+ * disassemble.c (disassembler): Refer to the PowerPC 620 using
+ bfd_mach_ppc_620 instead of 620.
+
+2000-06-12 Kazu Hirata <kazu@hxi.com>
+
+ * h8300-dis.c: Fix formatting.
+ (bfd_h8_disassemble): Distinguish adds/subs, inc/dec.[wl]
+ correctly.
+
+2000-06-09 Denis Chertykov <denisc@overta.ru>
+
+ * avr-dis.c (avr_operand): Bugfix for jmp/call address.
+
+2000-06-07 Denis Chertykov <denisc@overta.ru>
+
+ * avr-dis.c: completely rewritten.
+
+2000-06-02 Kazu Hirata <kazu@hxi.com>
+
+ * h8300-dis.c: Follow the GNU coding style.
+ (bfd_h8_disassemble) Fix a typo.
+
+2000-06-01 Kazu Hirata <kazu@hxi.com>
+
+ * h8300-dis.c (bfd_h8_disassemble_init): Fix a typo.
+ (bfd_h8_disassemble): Distinguish the operand size of inc/dev.[wl]
+ correctly. Fix a typo.
+
+2000-05-31 Nick Clifton <nickc@redhat.com>
+
+ * opintl.h (_(String)): Explain why dgettext is used instead of
+ gettext.
+
+2000-05-30 Nick Clifton <nickc@redhat.com>
+
+ * opintl.h (gettext, dgettext, dcgettext, textdomain,
+ bindtextdomain): Replace defines with those from intl/libgettext.h
+ to quieten gcc warnings.
+
+2000-05-26 Alan Modra <alan@linuxcare.com.au>
+
+ * Makefile.am: Update dependencies with "make dep-am"
+ * Makefile.in: Regenerate.
+
+2000-05-25 Alexandre Oliva <aoliva@redhat.com>
+
+ * m10300-dis.c (disassemble): Don't assume 32-bit longs when
+ sign-extending operands.
+
+2000-05-15 Donald Lindsay <dlindsay@redhat.com>
+
+ * d10v-opc.c (d10v_opcodes): add ALONE tag to all short branches
+ except brf's.
+
+2000-05-21 Nick Clifton <nickc@redhat.com>
+
+ * Makefile.am (LIBIBERTY): Define.
+
+2000-05-19 Diego Novillo <dnovillo@redhat.com>
+
+ * mips-dis.c (REGISTER_NAMES): Rename to STD_REGISTER_NAMES.
+ (STD_REGISTER_NAMES): New name for REGISTER_NAMES.
+ (reg_names): Rename to std_reg_names. Change it to a char **
+ static variable.
+ (std_reg_names): New name for reg_names.
+ (set_mips_isa_type): Set reg_names to point to std_reg_names by
+ default.
+
+2000-05-16 Frank Ch. Eigler <fche@redhat.com>
+
+ * fr30-desc.h: Partially regenerated to account for changed
+ CGEN_MAX_* -> CGEN_ACTUAL_MAX_* macros.
+ * m32r-desc.h: Ditto.
+
+2000-05-15 Nick Clifton <nickc@redhat.com>
+
+ * arm-opc.h: Use upper case for flasg in MSR and MRS
+ instructions. Allow any bit to be set in the field_mask of
+ the MSR instruction.
+
+ * arm-dis.c (print_insn_arm): Decode _x and _s bits of the
+ field_mask of an MSR instruction.
+
+2000-05-11 Thomas de Lellis <tdel@windriver.com>
+
+ * arm-opc.h: Disassembly of thumb ldsb/ldsh
+ instructions changed to ldrsb/ldrsh.
+
+2000-05-11 Ulf Carlsson <ulfc@engr.sgi.com>
+
+ * mips-dis.c (print_insn_arg): Don't mask top 32 bits of 64-bit
+ target addresses for 'jal' and 'j'.
+
+2000-05-10 Geoff Keating <geoffk@redhat.com>
+
+ * ppc-opc.c (powerpc_opcodes): Make the predicted-branch opcodes
+ also available in common mode when powerpc syntax is being used.
+
+2000-05-08 Alan Modra <alan@linuxcare.com.au>
+
+ * m68k-dis.c (dummy_printer): Add ATTRIBUTE_UNUSED to args.
+ (dummy_print_address): Ditto.
+
+2000-05-04 Timothy Wall <twall@redhat.com>
+
+ * tic54x-opc.c: New.
+ * tic54x-dis.c: New.
+ * disassemble.c (disassembler): Add ARCH_tic54x.
+ * configure.in: Added tic54x target.
+ * configure: Ditto.
+ * Makefile.am: Add tic54x dependencies.
+ * Makefile.in: Ditto.
+
+2000-05-03 J.T. Conklin <jtc@redback.com>
+
+ * ppc-opc.c (VA, VB, VC, VD, VS, SIMM, UIMM, SHB): New macros, for
+ vector unit operands.
+ (VX, VX_MASK, VXA, VXA_MASK, VXR, VXR_MASK): New macros, for vector
+ unit instruction formats.
+ (PPCVEC): New macro, mask for vector instructions.
+ (powerpc_operands): Add table entries for above operand types.
+ (powerpc_opcodes): Add table entries for vector instructions.
+
+ * ppc-dis.c (print_insn_big_powerpc): Add PPC_OPCODE_ALTIVEC to mask.
+ (print_insn_little_powerpc): Likewise.
+ (print_insn_powerpc): Prepend 'v' when printing vector registers.
+
+2000-04-24 Clinton Popetz <cpopetz@redhat.com>
+
+ * configure.in: Add bfd_powerpc_64_arch.
+ * disassemble.c (disassembler): Use print_insn_big_powerpc for
+ 64 bit code.
+
+2000-04-24 Nick Clifton <nickc@redhat.com>
+
+ * fr30-desc.c (fr30_cgen_cpu_open): Initialise signed_overflow
+ field.
+
+2000-04-23 Denis Chertykov <denisc@overta.ru>
+
+ * avr-dis.c (reg_fmul_d): New. Extract destination register from
+ FMUL instruction.
+ (reg_fmul_r): New. Extract source register from FMUL instruction.
+ (reg_muls_d): New. Extract destination register from MULS instruction.
+ (reg_muls_r): New. Extract source register from MULS instruction.
+ (reg_movw_d): New. Extract destination register from MOVW instruction.
+ (reg_movw_r): New. Extract source register from MOVW instruction.
+ (print_insn_avr): Handle MOVW, MULS, MULSU, FMUL, FMULS, FMULSU,
+ EICALL, EIJMP, LPM r,Z, ELPM r,Z, SPM, ESPM instructions.
+
+2000-04-22 Timothy Wall <twall@redhat.com>
+
+ * ia64-gen.c (general): Add an ordered table of primary
+ opcode names, as well as priority fields to disassembly data
+ structures to enforce a preferred disassembly format based on the
+ ordering of the opcode tables.
+ (load_insn_classes): Show a useful message if IC tables are missing.
+ (load_depfile): Ditto.
+ * ia64-asmtab.h (struct ia64_dis_names ): Add priority flag to
+ distinguish preferred disassembly.
+ * ia64-opc-f.c: Reorder some insn for preferred disassembly
+ format. Fix incorrect flag on fma.s/fma.s.s0.
+ * ia64-opc.c: Scan *all* disassembly matches and use the one with
+ the highest priority.
+ * ia64-opc-b.c: Use more abbreviations.
+ * ia64-asmtab.c: Regenerate.
+
+2000-04-21 Jason Eckhardt <jle@redhat.com>
+
+ * hppa-dis.c (extract_16): New function.
+ (print_insn_hppa): Fix incorrect handling of 'fe'. Added handling of
+ new operand types l,y,&,fe,fE,fx.
+
+2000-04-21 Richard Henderson <rth@redhat.com>
+ David Mosberger <davidm@hpl.hp.com>
+ Timothy Wall <twall@redhat.com>
+ Bob Manson <manson@charmed.cygnus.com>
+ Jim Wilson <wilson@redhat.com>
+
+ * Makefile.am (HFILES): Add ia64-asmtab.h, ia64-opc.h.
+ (CFILES): Add ia64-dis.c, ia64-opc-a.c, ia64-opc-b.c, ia64-opc-f.c,
+ ia64-opc-i.c, ia64-opc-m.c, ia64-opc-d.c, ia64-opc.c, ia64-gen.c,
+ ia64-asmtab.c.
+ (ALL_MACHINES): Add ia64-dis.lo, ia64-opc.lo.
+ (ia64-ic.tbl, ia64-raw.tbl, ia64-waw.tbl, ia64-war.tbl, ia64-gen,
+ ia64-gen.o, ia64-asmtab.c, ia64-dis.lo, ia64-opc.lo): New rules.
+ * Makefile.in: Rebuild.
+ * configure Rebuild.
+ * configure.in (bfd_ia64_arch): New target.
+ * disassemble.c (ARCH_ia64): Define.
+ (disassembler): Support ARCH_ia64.
+ * ia64-asmtab.c, ia64-asmtab.h, ia64-dis.c, ia64-gen.c ia64-ic.tbl,
+ ia64-opc-a.c, ia64-opc-b.c, ia64-opc-d.c ia64-opc-f.c, ia64-opc-i.c,
+ ia64-opc-m.c, ia64-opc-x.c, ia64-opc.c, ia64-opc.h, ia64-raw.tbl,
+ ia64-war.tbl, ia64-waw.tbl: New files.
+
+2000-04-20 Alexandre Oliva <aoliva@redhat.com>
+
+ * m10300-dis.c (HAVE_AM30, HAVE_AM33): Define.
+ (disassemble): Use them.
+
+2000-04-14 Alan Modra <alan@linuxcare.com.au>
+
+ * sysdep.h: Include "ansidecl.h" not <ansidecl.h>
+ * Makefile.am: Update dependencies.
+ * Makefile.in: Regenerate.
+
+2000-04-14 Michael Sokolov <msokolov@ivan.Harhan.ORG>
+
+ * a29k-dis.c, alpha-dis.c, alpha-opc.c, arc-dis.c, arc-opc.c,
+ avr-dis.c, d10v-dis.c, d10v-opc.c, d30v-dis.c, d30v-opc.c,
+ disassemble.c, h8300-dis.c, h8500-dis.c, hppa-dis.c, i370-dis.c,
+ i370-opc.c, i960-dis.c, m10200-dis.c, m10200-opc.c, m10300-dis.c,
+ m10300-opc.c, m68k-dis.c, m68k-opc.c, m88k-dis.c, mcore-dis.c,
+ mips-dis.c, mips-opc.c, mips16-opc.c, pj-dis.c, pj-opc.c,
+ ppc-dis.c, ppc-opc.c, sh-dis.c, sparc-dis.c, sparc-opc.c,
+ tic80-dis.c, tic80-opc.c, v850-dis.c, v850-opc.c, vax-dis.c,
+ w65-dis.c, z8k-dis.c, z8kgen.c: Include sysdep.h. Remove
+ ansidecl.h as sysdep.h includes it.
+
+2000-04-7 Andrew Cagney <cagney@b1.redhat.com>
+
+ * configure.in (WARN_CFLAGS): Set to -W -Wall by default. Add
+ --enable-build-warnings option.
+ * Makefile.am (AM_CFLAGS, WARN_CFLAGS): Add definitions.
+ * Makefile.in, configure: Re-generate.
+
+2000-04-05 J"orn Rennecke <amylaar@redhat.com>
+
+ * sh-opc.h (sh_table): Use A_DISP_PC / PCRELIMM_8BY2 for ldre & ldrs.
+ stc GBR,@-<REG_N> is available for arch_sh1_up.
+ Group parallel processing insn with identical mnemonics together.
+ Make three-operand psha / pshl come first.
+
+2000-04-05 J"orn Rennecke <amylaar@redhat.co.uk>
+
+ * sh-opc.h (sh_nibble_type): Remove DISP_8 and DISP_4.
+ Split IMM_[48]{,BY[24]} into IMM[01]_[48]{,BY[24]}. Add REPEAT.
+ (sh_arg_type): Add A_PC.
+ (sh_table): Update entries using immediates. Add repeat.
+ * sh-dis.c (print_insn_shx): Remove DISP_8 and DISP_4.
+ Split IMM_[48]{,BY[24]} into IMM[01]_[48]{,BY[24]}. Add REPEAT.
+
+2000-04-04 Alan Modra <alan@linuxcare.com.au>
+
+ * po/opcodes.pot: Regenerate.
+
+ * Makefile.am (MKDEP): Use gcc -MM rather than mkdep.
+ (DEP): Quote when passing vars to sub-make. Add warning message
+ to end.
+ (DEP1): Rewrite for "gcc -MM".
+ (CLEANFILES): Add DEP2.
+ Update dependencies.
+ * Makefile.in: Regenerate.
+
+2000-04-03 Denis Chertykov <denisc@overta.ru>
+
+ * avr-dis.c: Syntax cleanup.
+ (add0fff): Print the pc relative address as a signed number.
+ (add03f8): Likewise.
+
+2000-04-01 Ian Lance Taylor <ian@zembu.com>
+
+ * disassemble.c (disassembler_usage): Don't use a prototype. Mark
+ the parameter ATTRIBUTE_UNUSED.
+ * ppc-opc.c: Add ATTRIBUTE_UNUSED as needed.
+
+2000-04-01 Alexandre Oliva <aoliva@redhat.com>
+
+ * m10300-opc.c: SP-based offsets are always unsigned.
+
+2000-03-29 Thomas de Lellis <tdel@windriver.com>
+
+ * arm-opc.h (thumb_opcodes): Disassemble 0xde.. to "bal"
+ [branch always] instead of "undefined".
+
+2000-03-27 Nick Clifton <nickc@redhat.com>
+
+ * d30v-opc.c (d30v_format_table): Move SHORT_AR to end of list of
+ short instructions, from end of list of long instructions.
+
+2000-03-27 Ian Lance Taylor <ian@zembu.com>
+
+ * Makefile.am (CFILES): Add avr-dis.c.
+ (ALL_MACHINES): Add avr-dis.lo.
+
+2000-03-27 Alan Modra <alan@linuxcare.com>
+
+ * avr-dis.c (add0fff, add03f8): Don't use structure bitfields to
+ truncate integers.
+ (print_insn_avr): Call function via pointer in K&R compatible way.
+ (dispLDD, regPP, reg50, reg104, reg40, reg20w, lit404, lit204,
+ add0fff, add03f8): Convert to old style function declaration and
+ add prototype.
+ (avrdis_opcode): Add prototype.
+
+2000-03-27 Denis Chertykov <denisc@overta.ru>
+
+ * avr-dis.c: New file. AVR disassembler.
+ * configure.in (bfd_avr_arch): New architecture support.
+ * disassemble.c: Likewise.
+ * configure: Regenerate.
+
+2000-03-06 J"oern Rennecke <amylaar@redhat.com>
+
+ * sh-opc.h (sh_table): ldre and ldrs have a *signed* displacement.
+
+2000-03-02 J"orn Rennecke <amylaar@redhat.co.uk>
+
+ * d30v-dis.c (print_insn): Remove d*i hacks. Use per-operand
+ flag to determine if operand is pc-relative.
+ * d30v-opc.c:
+ (d30v_format_table):
+ (REL6S3): Renamed from IMM6S3.
+ Added flag OPERAND_PCREL.
+ (REL12S3, REL18S3, REL32): Split from IMM12S3, IMM18S3, REL32, with
+ added flag OPERAND_PCREL.
+ (IMM12S3U): Replaced with REL12S3.
+ (SHORT_D2, LONG_D): Delay target is pc-relative.
+ (SHORT_B2r, SHORT_B3r, SHORT_B3br, SHORT_D2r, LONG_Ur, LONG_2r):
+ Split from SHORT_B2, SHORT_D2, SHORT_B3b, SHORT_D2, LONG_U, LONG_2r,
+ using the REL* operands.
+ (LONG_2br, LONG_Dr): Likewise, from LONG_2b, LONG_D.
+ (SHORT_D1r, SHORT_D2Br, LONG_Dbr): Renamed from SHORT_D1, SHORT_D2B,
+ LONG_Db, using REL* operands.
+ (SHORT_U, SHORT_A5S): Removed stray alternatives.
+ (d30v_opcode_table): Use new *r formats.
+
+2000-02-28 Nick Clifton <nickc@redhat.com>
+
+ * m32r-desc.c (m32r_cgen_cpu_open): Replace 'flags' with
+ 'signed_overflow_ok_p'.
+
+2000-02-27 Eli Zaretskii <eliz@is.elta.co.il>
+
+ * Makefile.am (stamp-lib): Use $(LIBTOOL) --config to get the
+ name of the libtool directory.
+ * Makefile.in: Rebuild.
+
+2000-02-24 Nick Clifton <nickc@redhat.com>
+
+ * cgen-opc.c (cgen_set_signed_overflow_ok): New function.
+ (cgen_clear_signed_overflow_ok): New function.
+ (cgen_signed_overflow_ok_p): New function.
+
+2000-02-23 Andrew Haley <aph@redhat.com>
+
+ * m32r-asm.c, m32r-desc.c, m32r-desc.h, m32r-dis.c,
+ m32r-ibld.c, m32r-opc.h: Rebuild.
+
+2000-02-23 Linas Vepstas <linas@linas.org>
+
+ * i370-dis.c, i370-opc.c: New.
+
+ * disassemble.c (ARCH_i370): Define.
+ (disassembler): Handle it.
+
+ * Makefile.am: Add support for Linux/IBM 370.
+ * configure.in: Likewise.
+
+ * Makefile.in: Regenerate.
+ * configure: Likewise.
+
+2000-02-22 Chandra Chavva <cchavva@redhat.com>
+
+ * d30v-opc.c (d30v_opcode_tab) : Added FLAG_NOT_WITH_ADDSUBppp to
+ ST2H, STB, STH, STHH, STW and ST2H opcodes to prohibit parallel
+ procedure.
+
+2000-02-22 Andrew Haley <aph@redhat.com>
+
+ * mips-dis.c (_print_insn_mips): New arg for OPCODE_IS_MEMBER:
+ force gp32 to zero.
+ * mips-opc.c (G6): New define.
+ (mips_builtin_op): Add "move" definition for -gp32.
+
+2000-02-22 Ian Lance Taylor <ian@zembu.com>
+
+ From Grant Erickson <gerickso@Brocade.COM>:
+ * ppc-opc.c: Correct dcread--it takes 3 arguments, not 2.
+
+2000-02-21 Alan Modra <alan@spri.levels.unisa.edu.au>
+
+ * dis-buf.c (buffer_read_memory): Change `length' param and all int
+ vars to unsigned.
+
+2000-02-17 J"orn Rennecke <amylaar@redhat.co.uk>
+
+ * sh-dis.c (print_movxy, print_insn_ddt, print_dsp_reg): New functions.
+ (print_insn_ppi): Likewise.
+ (print_insn_shx): Use info->mach to select appropriate insn set.
+ Add support for sh-dsp. Remove FD_REG_N support.
+ * sh-opc.h (sh_nibble_type): Add new values for sh-dsp support.
+ (sh_arg_type): Likewise. Remove FD_REG_N.
+ (sh_dsp_reg_nums): New enum.
+ (arch_sh1, arch_sh2, arch_sh3, arch_sh3e, arch_sh4): New macros.
+ (arch_sh_dsp, arch_sh3_dsp, arch_sh1_up, arch_sh2_up): Likewise.
+ (arch_sh3_up, arch_sh3e_up, arch_sh4_up, arch_sh_dsp_up): Likewise.
+ (arch_sh3_dsp_up): Likewise.
+ (sh_opcode_info): New field: arch.
+ (sh_table): Split up insn with FD_REG_N into ones with F_REG_N and
+ D_REG_N. Fill in arch field. Add sh-dsp insns.
+
+2000-02-14 Fernando Nasser <fnasser@totem.to.redhat.com>
+
+ * arm-dis.c: Change flavor name from atpcs-special to
+ special-atpcs to prevent name conflict in gdb.
+ (get_arm_regname_num_options, set_arm_regname_option,
+ get_arm_regnames): New functions. API to access the several
+ flavor of register names. Note: Used by gdb.
+ (print_insn_thumb): Use the register name entry from the currently
+ selected flavor for LR and PC.
+
+2000-02-10 Nick Clifton <nickc@redhat.com>
+
+ * mcore-opc.h (enum mcore_opclass): Add MULSH and OPSR
+ classes.
+ (mcore_table): Add "idly4", "psrclr", "psrset", "mulsh" and
+ "mulsh.h" instructions.
+ * mcore-dis.c (imsk array): Add masks for MULSH and OPSR
+ classes.
+ (print_insn_mcore): Add support for little endian targets.
+ Add support for MULSH and OPSR classes.
+
+2000-02-07 Nick Clifton <nickc@redhat.com>
+
+ * arm-dis.c (parse_arm_diassembler_option): Rename again.
+ Previous delat did not take.
+
+2000-02-03 Timothy Wall <twall@redhat.com>
+
+ * dis-buf.c (buffer_read_memory): Use octets_per_byte field
+ to adjust target address bounds checking and calculate the
+ appropriate octet offset into data.
+
+2000-01-27 Nick Clifton <nickc@redhat.com>
+
+ * arm-dis.c: (parse_disassembler_option): Rename to
+ parse_arm_disassembler_option and allow to be exported.
+
+ * disassemble.c (disassembler_usage): New function: Print out any
+ target specific disassembler options.
+ Call arm_disassembler_options() if the ARM architecture is being
+ supported.
+
+ * arm-dis.c (NUM_ELEM): Define this macro if not already
+ defined.
+ (arm_regname): New struct type for ARM register names.
+ (arm_toggle_regnames): Delete.
+ (parse_disassembler_option): Use register name structure.
+ (print_insn): New function: Combines duplicate code found in
+ print_insn_big_arm and print_insn_little_arm.
+ (print_insn_big_arm): Call print_insn.
+ (print_insn_little_arm): Call print_insn.
+ (print_arm_disassembler_options): Display list of supported,
+ ARM specific disassembler options.
+
+2000-01-27 Thomas de Lellis <tdel@windriver.com>
+
+ * arm-dis.c (printf_insn_big_arm): Treat ELF symbols with the
+ ARM_STT_16BIT flag as Thumb code symbols.
+
+ * arm-dis.c (printf_insn_little_arm): Ditto.
+
+2000-01-25 Thomas de Lellis <tdel@windriver.com>
+
+ * arm-dis.c (printf_insn_thumb): Prevent double dumping
+ of raw thumb instructions.
+
+2000-01-20 Nick Clifton <nickc@redhat.com>
+
+ * mcore-opc.h (mcore_table): Add "add" as an alias for "addu".
+
+2000-01-03 Nick Clifton <nickc@cygnus.com>
+
+ * arm-dis.c (streq): New macro.
+ (strneq): New macro.
+ (force_thumb): ew local variable.
+ (parse_disassembler_option): New function: Parse a single, ARM
+ specific disassembler command line switch.
+ (parse_disassembler_option): Call parse_disassembler_option to
+ parse individual command line switches.
+ (print_insn_big_arm): Check force_thumb.
+ (print_insn_little_arm): Check force_thumb.
+
+For older changes see ChangeLog-9899
+
+Local Variables:
+mode: change-log
+left-margin: 8
+fill-column: 74
+version-control: never
+End:
diff --git a/contrib/binutils/opcodes/ChangeLog-0203 b/contrib/binutils/opcodes/ChangeLog-0203
new file mode 100644
index 0000000..25ed8b5
--- /dev/null
+++ b/contrib/binutils/opcodes/ChangeLog-0203
@@ -0,0 +1,2110 @@
+2003-12-15 Christian Groessler <chris@groessler.org>
+
+ * z8k-dis.c (intr_names): Removed.
+ (print_intr, print_flags): New functions.
+ (unparse_instr): Use new functions.
+
+2003-12-15 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
+
+ * m32r-opc.c: Regenerate.
+
+2003-12-14 Mark Mitchell <mark@codesourcery.com>
+
+ * arm-opc.h (arm_opcodes): Put V6 instructions before XScale
+ instructions.
+
+2003-12-13 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * mmix-opc.c (mmix_opcodes): Use GO_INSN_BYTE, PUSHGO_INSN_BYTE,
+ SETL_INSN_BYTE, INCH_INSN_BYTE, INCMH_INSN_BYTE, INCML_INSN_BYTE
+ and SWYM_INSN_BYTE instead of raw numbers.
+
+2003-12-10 Zack Weinberg <zack@codesourcery.com>
+
+ * ppc-opc.c (MO): Make optional.
+ (RAO, RSO, SHO): New optional forms of RA, RS, SH operands.
+ (tlbwe): Accept for both PPC403 and BOOKE. Make all operands optional.
+
+2003-12-05 Ricardo Anguiano <anguiano@codesourcery.com>
+ Mark Mitchell <mark@codesourcery.com>
+ Richard Earnshaw <rearnsha@arm.com>
+
+ * arm-dis.c (print_arm_insn): Add 'W' macro.
+ * arm-opc.h (arm_opcodes): Add V6 instructions.
+ (thumb_opcodes): Likewise.
+
+2003-12-04 Alan Modra <amodra@bigpond.net.au>
+
+ * openrisc-asm.c: Regenerate.
+ * pj-opc.c: Update copyright date.
+
+2003-12-03 Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
+
+ * m32r-asm.c: Regenerate.
+ * m32r-desc.c: Regenerate.
+ * m32r-desc.h: Regenerate.
+ * m32r-dis.c: Regenerate.
+ * m32r-ibld.c: Regenerate.
+ * m32r-opc.c: Regenerate.
+ * m32r-opc.h: Regenerate.
+ * m32r-opinst.c: Regenerate.
+
+2003-12-02 Alexandre Oliva <aoliva@redhat.com>
+
+ * sh-opc.h: Add support for sh4a and no-fpu variants.
+ * sh-dis.c: Ditto.
+
+2003-12-02 Kazu Hirata <kazu@cs.umass.edu>
+
+ * alpha-opc.c: Remove ARGSUSED.
+ * i370-opc.c: Likewise.
+ * ppc-opc.c: Likewise.
+
+2003-12-02 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2003-11-28 Christian Groessler <chris@groessler.org>
+
+ * z8k-dis.c: Convert to ISO C90.
+ * z8kgen.c: Convert to ISO C90.
+ (opt): Move long opcode for "ldb rdb,imm8" after short one, now
+ the short one is created when assembling.
+ * z8k-opc.h: Regenerate with new z8kgen.c.
+
+2003-11-19 Kazu Hirata <kazu@cs.umass.edu>
+
+ * h8300-dis.c (print_colon_thingie): Remove.
+
+2003-11-18 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * mips-opc.c (mips_builtin_opcodes): Handle new macros: "lca" and
+ "dlca".
+
+2003-11-14 Nick Clifton <nickc@redhat.com>
+
+ * dis-init.c (init_disassemble_info): Initialise
+ symbol_is_valid field.
+ * dis-buf.c (generic_symbol_is_valid): New function. Always
+ returns TRUE.
+ * arm-dis.c (arm_symbol_is_valid): New function. Return FALSE
+ for ARM ELF mapping symbols.
+ * disassemble.c (disassemble_init_for_target): Set
+ symbol_is_valid field to arm_symbol_is_valid of the target is
+ an ARM.
+
+2003-11-05 H.J. Lu <hongjiu.lu@intel.com>
+
+ * m68k-opc.c (m68k_opcodes): Reorder "fmovel".
+
+2003-11-03 Daniel Jacobowitz <drow@mvista.com>
+
+ * arm-dis.c (print_arm_insn): Print "-" after "#".
+
+2003-10-30 Falk Hueffner <falk.hueffner@student.uni-tuebingen.de>
+
+ * alpha-opc.c: Add support for a second argument to RPCC.
+
+2003-10-27 Stephane Carrez <stcarrez@nerim.fr>
+
+ * m68hc11-dis.c: Convert to ISO C90 prototypes.
+
+2003-10-21 Peter Barada <pbarada@mail.wm.sps.mot.com>
+ Bernardo Innocenti <bernie@develer.com>
+
+ * m68k-dis.c: Add MCFv4/MCF5528x support.
+ * m68k-opc.c: Likewise.
+
+2003-10-10 Dave Brolley <brolley@redhat.com>
+
+ * frv-asm.c,frv-desc.c,frv-opc.c: Regenerated.
+
+2003-10-08 Dave Brolley <brolley@redhat.com>
+
+ * frv-desc.[ch], frv-opc.[ch]: Regenerated.
+
+2003-09-30 Bob Wilson <bob.wilson@acm.org>
+
+ * xtensa-dis.c (fetch_data): Remove numBytes parameter.
+ (print_insn_xtensa): Fix call to fetch_data.
+
+2003-09-30 Chris Demetriou <cgd@broadcom.com>
+
+ * mips-dis.c (mips_arch_choices): Add entry for "mips64r2"
+ (print_insn_args): Add handing for +E, +F, +G, and +H.
+ * mips-opc.c (I65): New define for MIPS64r2.
+ (mips_builtin_opcodes): Add "dext", "dextm", "dextu", "dins",
+ "dinsm", "dinsu", "drotl", "drotr", "drotr32", "drotrv", "dsbh",
+ and "dshd" for MIPS64r2. Adjust "dror", "dror32", and "drorv" to
+ be supported on MIPS64r2.
+
+2003-09-24 Dave Brolley <brolley@redhat.com>
+
+ * frv-desc.c, frv-opc.c, frv-opc.h: Regenerated.
+
+2003-09-14 Andreas Jaeger <aj@suse.de>
+
+ * i386-dis.c: Convert to ISO C90 prototypes.
+ * i370-dis.c: Likewise.
+ * i370-opc.c: Likewiwse.
+ * i960-dis.c: Likewise.
+ * ia64-opc.c: Likewise.
+
+2003-09-09 Dave Brolley <brolley@redhat.com>
+
+ * frv-desc.c: Regenerated.
+
+2003-09-08 Dave Brolley <brolley@redhat.com>
+
+ On behalf of Doug Evans <dje@sebabeach.org>
+ * Makefile.am (run-cgen): Pass new args archfile and opcfile
+ to cgen.sh.
+ (stamp-ip2k,stamp-m32r,stamp-fr30,stamp-frv,stamp-openrisc,
+ stamp-iq2000,stamp-xstormy16): Pass paths of .cpu and .opc files
+ to cgen.sh.
+ (stamp-frv): Delete hardcoded path spec workaround.
+ * Makefile.in: Regenerate.
+ * cgen.sh: New args archfile and opcfile. Pass on to cgen.
+
+2003-09-04 Nick Clifton <nickc@redhat.com>
+
+ * v850-dis.c (disassemble): Accept bfd_mach_v850e1.
+ * v850-opc.c (v850_opcodes): Add DBTRAP and DBRET instructions.
+
+2003-09-04 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc-dis.c (struct dis_private): New.
+ (powerpc_dialect): Make static. Accept -Many in addition to existing
+ options. Save dialect in dis_private.
+ (print_insn_big_powerpc): Retrieve dialect from dis_private.
+ (print_insn_little_powerpc): Likewise.
+ (print_insn_powerpc): Call powpc_dialect here. Remove unnecessary
+ efs/altivec check. Try harder to disassemble if given -Many.
+ * ppc-opc.c (insert_fxm): Expand comment.
+ (PPC, PPCCOM, PPC32, PPC64, PPCVEC): Remove PPC_OPCODE_ANY.
+ (POWER, POWER2, PPCPWR2, POWER32, COM, COM32, M601, PWRCOM): Likewise.
+ (POWER4): Remove PPCCOM.
+ (PPCONLY): Don't define. Update all occurrences to PPC.
+
+2003-09-03 Andrew Cagney <cagney@redhat.com>
+
+ * dis-init.c (init_disassemble_info): New file and function.
+ * Makefile.am (CFILES): Add "dis-init.c".
+ (libopcodes_la_SOURCES): Add "dis-init.c".
+ (dis-init.lo): Specify dependencies.
+ * Makefile.in: Regenerate.
+
+2003-09-03 Dave Brolley <brolley@redhat.com>
+
+ * frv-*: Regenerated.
+
+2003-09-02 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc-opc.c (powerpc_opcodes): Combine identical PPC403/BOOKE entries.
+ Move duplicate mnemonic entries together. Use RS instead of RT on
+ all mt*.
+ * ppc-dis.c: Convert to ISO C.
+
+2003-08-29 Dave Brolley <brolley@redhat.com>
+
+ * Makefile.am (stamp-frv): Copy frv.cpu and frv.opc from
+ $(srcdir)/../cpu temporarily when regenerating source files.
+ * Makefile.in: Regenerated.
+
+2003-08-19 Nick Clifton <nickc@redhat.com>
+
+ * arm-dis.c (print_insn_arm: case 'A'): Add code to
+ disassemble unindexed form of Addressing Mode 5.
+
+2003-08-19 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc-opc.c (PPC440): Define.
+ (powerpc_opcodes): Allow mac*, mul*, nmac*, dccci, dcread, iccci,
+ icread instructions when PPC440. Add dlmzb instruction.
+
+2003-08-14 Alan Modra <amodra@bigpond.net.au>
+
+ * dep-in.sed: Remove libintl.h.
+ * Makefile.am (POTFILES.in): Unset LC_COLLATE.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2003-08-07 Michael Meissner <gnu@the-meissners.org>
+
+ * cgen-asm.c (hash_insn_array): Remove PARAMS macro.
+ (hash_insn_list): Ditto.
+ (build_asm_hash_table): Ditto.
+ (cgen_set_parse_operand_fn): Prototype definition.
+ (cgen_init_parse_operand): Ditto.
+ (hash_insn_array): Ditto.
+ (hash_insn_list): Ditto.
+ (build_asm_hash_table): Ditto.
+ (cgen_asm_lookup_insn): Ditto.
+ (cgen_parse_keyword): Ditto.
+ (cgen_parse_signed_integer): Ditto.
+ (cgen_parse_unsigned_integer): Ditto.
+ (cgen_parse_address): Ditto.
+ (cgen_validate_signed_integer): Ditto.
+ (cgen_validate_unsigned_integer): Ditto.
+
+ * cgen-opc.c (hash_keyword_name): Remove PARAMS macro.
+ (hash_keyword_value): Ditto.
+ (build_keyword_hash_tables): Ditto.
+ (cgen_keyword_lookup_name): Prototype definition.
+ (cgen_keyword_lookup_value): Ditto.
+ (cgen_keyword_add): Ditto.
+ (cgen_keyword_search_init): Ditto.
+ (cgen_keyword_search_next): Ditto.
+ (hash_keyword_name): Ditto.
+ (hash_keyword_value): Ditto.
+ (build_keyword_hash_tables): Ditto.
+ (cgen_hw_lookup_by_name): Ditto.
+ (cgen_hw_lookup_by_num): Ditto.
+ (cgen_operand_lookup_by_name): Ditto.
+ (cgen_operand_lookup_by_num): Ditto.
+ (cgen_insn_count): Ditto.
+ (cgen_macro_insn_count): Ditto.
+ (cgen_get_insn_value): Ditto.
+ (cgen_put_insn_value): Ditto.
+ (cgen_lookup_insn): Ditto.
+ (cgen_get_insn_operands): Ditto.
+ (cgen_lookup_get_insn_operands): Ditto.
+ (cgen_set_signed_overflow_ok): Ditto.
+ (cgen_clear_signed_overflow_ok): Ditto.
+ (cgen_signed_overflow_ok_p): Ditto.
+
+ * cgen-dis.c (hash_insn_array): Remove PARAMS macro.
+ (hash_insn_list): Ditto.
+ (build_dis_hash_table): Ditto.
+ (count_decodable_bits): Ditto.
+ (add_insn_to_hash_chain): Ditto.
+ (count_decodable_bits): Prototype definition.
+ (add_insn_to_hash_chain): Ditto.
+ (hash_insn_array): Ditto.
+ (hash_insn_list): Ditto.
+ (build_dis_hash_table): Ditto.
+ (cgen_dis_lookup_insn): Ditto.
+
+ * cgen-asm.in (parse_insn_normal): Remove PARAMS macro.
+ (@arch@_cgen_build_insn_regex): Prototype definition.
+ (parse_insn_normal): Ditto.
+ (@arch@_cgen_assemble_insn): Ditto.
+ (@arch@_cgen_asm_hash_keywords): Ditto.
+
+ * cgen-dis.in (print_normal): Remove PARAMS macro. Use void *
+ instead of PTR.
+ (print_address): Ditto.
+ (print_keyword): Ditto.
+ (print_insn_normal): Ditto.
+ (print_insn): Ditto.
+ (default_print_insn): Ditto.
+ (read_insn): Ditto.
+ (print_normal): Prototype definition. Use void * instead of PTR.
+ (print_address): Ditto.
+ (print_keyword): Ditto.
+ (print_insn_normal): Ditto.
+ (read_insn): Ditto.
+ (print_insn): Ditto.
+ (default_print_insn): Ditto.
+ (print_insn_@arch@): Ditto.
+
+ * cgen-ibld.in (insert_normal): Remove PARAMS macro.
+ (insn_insn_normal): Ditto.
+ (extract_normal): Ditto.
+ (extract_insn_normal): Ditto.
+ (put_insn_int_value): Ditto.
+ (insert_1): Ditto.
+ (fill_cache): Ditto.
+ (extract_1): Ditto.
+ (insert_1): Prototype definition.
+ (insert_normal): Ditto.
+ (insert_insn_normal): Ditto.
+ (put_insn_int_value): Ditto.
+ (fill_cache): Ditto.
+ (extract_1): Ditto.
+ (extract_normal): Ditto.
+ (extract_insn_normal): Ditto.
+
+ * fr30-asm.c: Regenerate.
+ * fr30-dis.c: Ditto.
+ * fr30-ibld.c: Ditto.
+ * frv-asm.c: Ditto.
+ * frv-dis.c: Ditto.
+ * frv-ibld.c: Ditto.
+ * ip2k-asm.c: Ditto.
+ * ip2k-dis.c: Ditto.
+ * ip2k-ibld.c: Ditto.
+ * iq2000-asm.c: Ditto.
+ * iq2000-dis.c: Ditto.
+ * iq2000-ibld.c: Ditto.
+ * m32r-asm.c: Ditto.
+ * m32r-dis.c: Ditto.
+ * m32r-ibld.c: Ditto.
+ * openrisc-asm.c: Ditto.
+ * openrisc-dis.c: Ditto.
+ * openrisc-ibld.c: Ditto.
+ * xstormy16-asm.c: Ditto.
+ * xstormy16-dis.c: Ditto.
+ * xstormy16-ibld.c: Ditto.
+
+2003-08-06 Nick Clifton <nickc@redhat.com>
+
+ * po/fr.po: Updated French translation.
+
+2003-08-05 Nick Clifton <nickc@redhat.com>
+
+ * configure.in (ALL_LINGUAS): Add nl.
+ * configure: Regenerate.
+ * po/nl.po: New Dutch translation.
+
+2003-07-30 Jason Eckhardt <jle@rice.edu>
+
+ * i860-dis.c: Convert to ISO C90. Remove superflous prototypes.
+
+2003-07-30 Nick Clifton <nickc@redhat.com>
+
+ * po/ro.po: Updated Romanian translation.
+
+2003-07-29 Jakub Jelinek <jakub@redhat.com>
+
+ * ppc-opc.c (insert_mbe, extract_mbe): Shift 1L instead of 1 up.
+
+2003-07-24 Nick Clifton <nickc@redhat.com>
+
+ * po/fr.po: Updated French translation.
+
+2003-07-18 Nick Clifton <nickc@redhat.com>
+
+ * arm-dis.c (parse_arm_disassembler_option): Do not expect
+ option string to be NUL terminated.
+ (parse_disassembler_options): Allow options to be space or
+ comma separated.
+
+2003-07-17 Nick Clifton <nickc@redhat.com>
+
+ * po/es.po: New Spanish translation.
+ * po/sv.po: New Swedish translation.
+ * po/opcodes.pot: Regenerate.
+
+2003-07-15 Richard Sandiford <rsandifo@redhat.com>
+
+ * mips-dis.c (mips_arch_choices): Add rm7000 and rm9000 entries.
+
+2003-07-14 Nick Clifton <nickc@redhat.com>
+
+ * po/tr.po: Update with latest version.
+ * po/POTFILES.in: Regenerate.
+ * Makefile.in: Regenerate.
+
+2003-07-11 Alan Modra <amodra@bigpond.net.au>
+
+ * po/opcodes.pot: Regenerate.
+
+2003-07-09 Alexandre Oliva <aoliva@redhat.com>
+
+ 2000-05-25 Alexandre Oliva <aoliva@cygnus.com>
+ * m10300-dis.c (disassemble): Negate negative accumulator's shift.
+ 2000-05-24 Alexandre Oliva <aoliva@cygnus.com>
+ * m10300-dis.c (disassemble, case FSREG, FDREG): Don't assume
+ 32-bit longs when sign-extending operands.
+ 2000-04-20 Alexandre Oliva <aoliva@cygnus.com>
+ * m10300-opc.c: Remove MN10300_OPERAND_RELAX from all FSREGs.
+ * m10300-dis.c (HAVE_AM33_2): Define.
+ (disassemble): Use it.
+ (HAVE_AM33): Redefine.
+ (print_insn_mn10300): Fix mask for 5-byte extended insns.
+ 2000-04-01 Alexandre Oliva <aoliva@cygnus.com>
+ * m10300-opc.c: Renamed AM332 to AM33_2.
+ 2000-03-31 Alexandre Oliva <aoliva@cygnus.com>
+ * m10300-opc.c: Defined AM33 2.0 register operands. Added support
+ for AM33 2.0 `imm8,(abs16)' addressing mode for btst, bset and
+ bclr. Implemented `fbCC', `flCC', `dcpf' and all FP insns.
+ * m10300-dis.c (print_insn_mn10300): Recognize 5byte extended
+ insn code of AM33 2.0.
+ (disassemble): Recognize FMT_D3. Print out FP register names.
+
+2003-07-09 Chris Demetriou <cgd@broadcom.com>
+
+ * mips-dis.c (set_default_mips_dis_options): Get BFD from
+ the disassembler_info's section, rather than from the
+ disassembler_info's symbols pointer.
+
+2003-07-07 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc-opc.c: Remove NULL pointer checks. Formatting. Remove
+ extraneous ATTRIBUTE_UNUSED.
+ * ppc-dis.c (print_insn_powerpc): Always pass a valid address to
+ operand->extract.
+
+2003-07-04 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc-opc.c: Convert to C90, removing unnecessary prototypes and
+ casts. Formatting.
+
+ * ppc-opc.c: Remove PARAMS from prototypes.
+ (FXM4): Define.
+ (insert_fxm): New function, used by both FXM and FXM4.
+ (extract_fxm): Likewise.
+ (XFXFXM_MASK): Remove 1 << 20 term.
+ (powerpc_opcodes): Add Power4 version of "mfcr". Simplify "mtcr" mask.
+
+2003-07-01 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * s390-dis.c (s390_extract_operand): Add support for long displacements.
+ * s390-mkopc.c (s390_opcode_cpu_val): Add support for cpu type z990.
+ * s390-opc.c (D20_20): Add define for 20 bit displacements.
+ (INSTR_RRF_R0RR, INSTR_RSL_R0RD, INSTR_RSY_RRRD, INSTR_RSY_RURD,
+ INSTR_RSY_AARD, INSTR_RXY_RRRD, INSTR_RXY_FRRD, INSTR_SIY_URD): Add
+ new instruction formats.
+ (MASK_RRF_R0RR, MASK_RSL_R0RD, MASK_RSY_RRRD, MASK_RSY_RURD,
+ MASK_RSY_AARD, MASK_RXY_RRRD, MASK_RXY_FRRD, MASK_SIY_URD): Likewise.
+ (s390_opformats): Likewise.
+ * s390-opc.txt: Add new instructions for cpu type z990. Add missing
+ hfp instructions. Add missing instructions pgin, pgout and xsch.
+
+2003-06-23 H.J. Lu <hongjiu.lu@intel.com>
+
+ * i386-dis.c (PNI_Fixup): New. Fix up "mwait" and "monitor" in
+ Intel Precott New Instructions.
+ (PREGRP27): New. Added for "addsubpd" and "addsubps".
+ (PREGRP28): New. Added for "haddpd" and "haddps".
+ (PREGRP29): New. Added for "hsubpd" and "hsubps".
+ (PREGRP30): New. Added for "movsldup" and "movddup".
+ (PREGRP31): New. Added for "movshdup" and "movhpd".
+ (PREGRP32): New. Added for "lddqu".
+ (dis386_twobyte): Use PREGRP30 to replace the "movlpX" entry.
+ Use PREGRP31 to replace the "movhpX" entry. Use PREGRP28 for
+ entry 0x7c. Use PREGRP29 for entry 0x7d. Use PREGRP27 for
+ entry 0xd0. Use PREGRP32 for entry 0xf0.
+ (twobyte_has_modrm): Updated.
+ (twobyte_uses_SSE_prefix): Likewise.
+ (grps): Use PNI_Fixup in the "sidtQ" entry.
+ (prefix_user_table): Add PREGRP27, PREGRP28, PREGRP29, PREGRP30,
+ PREGRP31 and PREGRP32.
+ (float_mem): Use "fisttp{l||l|}" in entry 1 in opcode 0xdb.
+ Use "fisttpll" in entry 1 in opcode 0xdd.
+ Use "fisttp" in entry 1 in opcode 0xdf.
+
+2003-06-19 Christian Groessler <chris@groessler.org>
+
+ * z8k-dis.c (instr_data_s): Change tabl_index from long to int.
+ (print_insn_z8k): Correctly check return value from
+ z8k_lookup_instr call.
+ (unparse_instr): Handle CLASS_IRO case.
+ * z8kgen.c: Fix function definitions. Fix formatting.
+ (opt): Add brk opcode alias for non-simulator breakpoint. Add
+ missing and fix existing in/out and sin/sout opcode definitions.
+ (args): "@ri", "@ro" - add CLASS_IRO register usage for in/out
+ opcodes.
+ (internal): Check p->flags for non-zero before dereferencing it.
+ (gas): Add CLASS_IRO line. Insert new OPC_xxx lines for the added
+ opcodes and renumber the remaining lines repectively.
+ (main): Remove "-d" command line switch.
+ * z8k-opc.h: Regenerate with new z8kgen.c.
+
+2003-06-11 H.J. Lu <hongjiu.lu@intel.com>
+
+ * po/Make-in (DESTDIR): New.
+ (install-data-yes): Support $(DESTDIR).
+ (uninstall): Likewise.
+
+2003-06-11 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * po/POTFILES.in: Regenerate.
+
+2003-06-10 Doug Evans <dje@sebabeach.org>
+
+ * cgen-asm.in (@arch@_cgen_assemble_insn): CGEN_INSN_RELAX renamed to
+ CGEN_INSN_RELAXED.
+ * fr30-asm.c,fr30-desc.c,fr30-desc.h: Regenerate.
+ * frv-asm.c,frv-desc.c,frv-desc.h: Regenerate.
+ * ip2k-asm.c,ip2k-desc.c,ip2k-desc.h: Regenerate.
+ * iq2000-asm.c,iq2000-desc.c,iq2000-desc.h: Regenerate.
+ * m32r-asm.c,m32r-desc.c,m32r-desc.h,m32r-opc.c: Regenerate.
+ * openrisc-asm.c,openrisc-desc.c,openrisc-desc.h: Regenerate.
+ * xstormy16-asm.c,xstormy16-desc.c,xstormy16-desc.h: Regenerate.
+
+2003-06-10 Gary Hade <garyhade@us.ibm.com>
+ Alan Modra <amodra@bigpond.net.au>
+
+ * ppc-opc.c (DQ, RAQ, RSQ, RTQ): Define.
+ (insert_dq, extract_dq, insert_raq, insert_rtq, insert_rsq): New.
+ (powerpc_opcodes): Add "attn", "lq" and "stq".
+
+2003-06-10 Richard Sandiford <rsandifo@redhat.com>
+
+ * h8300-dis.c (bfd_h8_disassemble): Don't print brackets round
+ rts/l and rte/l register lists.
+
+2003-06-03 Nick Clifton <nickc@redhat.com>
+
+ * frv-desc.c: Regenerate.
+ * frv-opc.c: Regenerate.
+ * frv-asm.c: Regenerate.
+ * frv-desc.h: Regenerate.
+ * frv-dis.c: Regenerate.
+ * frv-ibld.c: Regenerate.
+ * frv-opc.h: Regenerate.
+ * po/opcodes.pot: Regenerate.
+
+2003-06-03 Michael Snyder <msnyder@redhat.com>
+ and Bernd Schmidt <bernds@redhat.com>
+ and Alexandre Oliva <aoliva@redhat.com>
+
+ * disassemble.c (disassembler): Add support for h8300sx.
+ * h8300-dis.c: Ditto.
+
+2003-06-03 Nick Clifton <nickc@redhat.com>
+
+ * frv-desc.c: Regenerate.
+ * frv-opc.c: Regenerate.
+
+ * aclocal.m4: Regenerate.
+ * config.in: Regenerate.
+ * configure: Regenerate.
+ * iq2000-asm.c: Regenerate.
+ * iq2000-desc.c: Regenerate.
+ * iq2000-desc.h: Regenerate.
+ * iq2000-dis.c: Regenerate.
+ * iq2000-ibld.c: Regenerate.
+ * iq2000-opc.c: Regenerate.
+ * iq2000-opc.h: Regenerate.
+ * po/POTFILES.in: Regenerate.
+ * po/opcodes.pot: Regenerate.
+
+2003-05-23 Jason Eckhardt <jle@rice.edu>
+
+ * i860-dis.c (crnames): Add bear, ccr, p0, p1, p2, p3.
+ (print_insn_i860): Grab 4 bits of the control register field
+ instead of 3.
+
+2003-05-18 Jason Eckhardt <jle@rice.edu>
+
+ * i860-dis.c (print_insn_i860): Instruction shrd has a dual bit,
+ print it.
+
+2003-05-17 Andreas Jaeger <aj@suse.de>
+
+ * Makefile.am (libopcodes_la_LIBADD): Add libbfd.la.
+ (libopcodes_la_DEPENDENCIES): Add libbfd.la.
+ * Makefile.in: Regenerated.
+
+2003-05-16 Nick Clifton <nickc@redhat.com>
+
+ * configure.in (ALL_LINGUAS): Add Romanian translation.
+ * configure: Regenerate.
+ * po/ro.po: New file: Romanian translation.
+
+2003-05-12 Dhananjay Deshpande <dhananjayd@kpitcummins.com>
+
+ * disassemble.c (disassembler): Add support for h8300hn and h8300sn.
+
+2003-05-09 Alan Modra <amodra@bigpond.net.au>
+
+ * i386-dis.c (print_insn): Test intel_syntax against (char) -1 in
+ case char is unsigned.
+
+2003-05-01 Christian Groessler <chris@groessler.org>
+
+ * z8k-dis.c (z8k_lookup_instr): Optimize FETCH_DATA calls.
+ (unpack_instr): Fix representation of segmented addresses.
+ (intr_name): Added, contains names of the parameters to the EI/DI
+ instructions.
+ (unparse_instr): Fix display of EI/DI parameters.
+
+2003-04-22 Doug Evans <dje@sebabeach.org>
+
+ * fr30-desc.c,fr30-desc.h,fr30-opc.c,fr30-opc.h: Regenerate.
+ * frv-desc.c,frv-desc.h,frv-opc.c,frv-opc.h: Regenerate.
+ * ip2k-desc.c,ip2k-desc.h,ip2k-opc.c,ip2k-opc.h: Regenerate.
+ * m32r-desc.c,m32r-desc.h,m32r-opc.c,m32r-opc.h: Regenerate.
+ * m32r-opinst.c: Regenerate.
+ * openrisc-desc.c,openrisc-desc.h,openrisc-opc.c,openrisc-opc.h: Regenerate.
+ * xstormy16-desc.c,xstormy16-desc.h,xstormy16-opc.c,xstormy16-opc.h: Regenerate.
+
+2003-04-15 Rohit Kumar Srivastava <rohits@kpitcummins.com>
+
+ * h8500-opc.c: Replace occurrances of 'Hitachi' with 'Renesas'.
+
+2003-04-07 James E Wilson <wilson@tuliptree.org>
+
+ * ia64-ic.tbl (fr-readers): Add mem-writers-fp.
+ * ia64-asmtab.c: Regenerate.
+
+2003-04-08 Alexandre Oliva <aoliva@redhat.com>
+
+ * mips-dis.c (mips_gpr_names_newabi): Reverted previous patch.
+
+2003-04-07 Alexandre Oliva <aoliva@redhat.com>
+
+ * mips-dis.c (mips_gpr_names_newabi): $12-$15 are named $t4-$t7.
+
+2003-04-04 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * tic4x-dis.c: Namespace cleanup. Replace s/c4x/tic4x and
+ s/c3x/tic3x/
+
+2003-04-01 Nick Clifton <nickc@redhat.com>
+
+ * arm-dis.c: Remove presence of (r) and (tm) symbols.
+ * arm-opc.h: Remove presence of (r) and (tm) symbols.
+
+2003-03-25 Stan Cox <scox@redhat.com>
+ Nick Clifton <nickc@redhat.com>
+
+ Contribute support for Intel's iWMMXt chip - an ARM variant:
+
+ * arm-dis.c (regnames): Add iWMMXt register names.
+ (set_iwmmxt_regnames): New function.
+ (print_insn_arm): Handle iWMMXt formatters.
+ * arm-opc.h: Document iWMMXt formatters.
+ (arm_opcod): Add iWMMXt instructions.
+
+2003-03-22 Doug Evans <dje@sebabeach.org>
+
+ * i386-dis.c (dis386): Recognize icebp (0xf1).
+
+2003-03-21 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * s390-dis.c (init_disasm): Rename S390_OPCODE_ESAME to
+ S390_OPCODE_ZARCH.
+ (print_insn_s390): Use new modes field of s390_opcodes.
+ * s390-mkopc.c (ARCHBITS_ESAONLY, ARCHBITS_ESA, ARCHBITS_ESAME): Remove.
+ (s390_opcode_mode_val, s390_opcode_cpu_val): New enums.
+ (struct op_struct): Remove archbits. Add mode_bits and min_cpu.
+ (insertOpcode): Replace archbits by min_cpu and mode_bits.
+ (dumpTable): Write mode_bits and min_cpu instead of archbits.
+ (main): Adapt to new format in s390-opcode.txt.
+ * s390-opc.c (s390_opformats): Replace archbits by min_cpu and
+ mode_bits.
+ * s390-opc.txt: Replace archbits by min_cpu and mode_bits.
+
+2003-03-17 Nick Clifton <nickc@redhat.com>
+
+ * ppc-opc.c: Fix formatting. Update copyright date.
+
+2003-03-14 Daniel Jacobowitz <drow@mvista.com>
+
+ * ppc-opc.c (powerpc_opcodes): Readd tlbre for PPC403.
+
+2003-02-25 Alan Modra <amodra@bigpond.net.au>
+
+ * hppa-dis.c: Formatting.
+
+2003-02-25 Matthew Wilcox <willy@debian.org>
+
+ * hppa-dis.c (print_insn_hppa): Implement fcnv instruction modifiers.
+
+ * hppa-dis.c (print_insn_hppa <2 bit space register>): Do not print
+ the space register when the value is zero.
+
+2003-02-23 Elias Athanasopoulos <elathan@phys.uoa.gr>
+
+ * mips-dis.c (print_mips_disassembler_options): Make 'i' unsigned,
+ use ARRAY_SIZE in loops.
+
+2003-02-12 Dave Brolley <brolley@redhat.com>
+
+ * fr30-desc.c: Regenerate.
+
+2003-02-06 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com>
+
+ * i386-dis.c (dq_mode, Edq): Define.
+ (dis386_twobyte): Correct movd operands.
+ (OP_E): Handle dq_mode case.
+
+2003-01-29 Henric Jungheim <henric@attbi.com>
+
+ * sparc-dis.c (print_insn_sparc): When examining values added in
+ to rs1, make sure that there are previous instructions.
+
+2003-01-23 Nick Clifton <nickc@redhat.com>
+
+ * Add sh2e support:
+
+ 2002-04-02 Alexandre Oliva <aoliva@redhat.com>
+
+ * sh-dis.c (print_insn_shx): Handle bfd_mach_sh2e.
+ * sh-opc.h (arch_sh2e, arch_sh2e_up): New.
+ (arch_sh2_up): Added sh2e.
+ (sh_table): Replaced all occurrences of arch_sh3e_up with
+ arch_sh2e_up, except in fsqrt.
+
+2003-01-23 Alan Modra <amodra@bigpond.net.au>
+
+ * sh64-dis.c: Include elf32-sh64.h.
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2003-01-17 Richard Henderson <rth@redhat.com>
+
+ * alpha-opc.c (alpha_opcodes): Add bugchk, rduniq, wruniq, gentrap
+ PAL entry points.
+
+2003-01-16 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * po/POTFILES.in: Regenerate.
+
+2003-01-08 Klee Dienes <kdienes@apple.com>
+
+ * Makefile.am (ALL_MACHINES): Add msp430-dis.lo.
+ * Makefile.in: Regenerate.
+
+2003-01-08 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc-opc.c (powerpc_macros <extrwi>): Accept a shift of 32.
+
+2002-01-02 Ben Elliston <bje@redhat.com>
+ Jeff Johnston <jjohnstn@redhat.com>
+
+ * iq2000-asm.c: New file.
+ * iq2000-desc.c: Likewise.
+ * iq2000-desc.h: Likewise.
+ * iq2000-dis.c: Likewise.
+ * iq2000-ibld.c: Likewise.
+ * iq2000-opc.c: Likewise.
+ * iq2000-opc.h: Likewise.
+ * Makefile.am (HFILES): Add iq2000-desc.h, iq2000-opc.h.
+ (CFILES): Add iq2000-asm.c, iq2000-desc.c, iq2000-dis.c,
+ iq2000-ibld.c, iq2000-opc.c.
+ (ALL_MACHINES): Add iq2000-asm.lo, iq2000-desc.lo, iq2000-dis.lo,
+ iq2000-ibld.lo, iq2000-opc.lo.
+ (CLEANFILES): Add stamp-iq2000.
+ (IQ2000_DEPS): New macro.
+ (stamp-iq2000): New target.
+ * Makefile.in: Regenerate.
+ * configure.in: Handle bfd_iq2000_arch.
+ * configure: Regenerate.
+
+2003-01-02 Chris Demetriou <cgd@broadcom.com>
+
+ * mips-dis.c (print_insn_args): Use position extracted by "+A"
+ to calculate size for "+B". Redo code for "+C" so it shares
+ the same style as "+A" and "+B" now do.
+
+2003-01-02 Chris Demetriou <cgd@broadcom.com>
+
+ * mips-dis.c: Update copyright years.
+ (print_insn_arg): Rename to...
+ (print_insn_args): This, returning void. Process the whole
+ string of args rather than a single one. Reindent.
+ (print_insn_mips): Update to match the above.
+
+2002-12-31 Chris Demetriou <cgd@broadcom.com>
+
+ * mips-opc.c (mips_builtin_opcodes): Move "di" into the
+ right order alphabetically, and make all hex constants use
+ lower-case letters.
+
+2002-12-31 Chris Demetriou <cgd@broadcom.com>
+
+ * mips-dis.c (mips_cp0sel_name): New structure.
+ (mips_cp0sel_names_mips3264, mips_cp0sel_names_mips3264r2)
+ (mips_cp0sel_names_sb1): New arrays.
+ (mips_arch_choice): New structure members "cp0sel_names" and
+ "cp0sel_names_len".
+ (mips_arch_choices): Add references to new cp0sel_names arrays
+ as appropriate, and make all existing entries reference
+ appropriate mips_XXX_names_numeric arrays rather than simply
+ using NULL.
+ (mips_cp0sel_names, mips_cp0sel_names_len): New variables.
+ (lookup_mips_cp0sel_name): New function.
+ (set_default_mips_dis_options): Set mips_cp0sel_names and
+ mips_cp0sel_names_len as appropriate. Remove now-unnecessary
+ checks for NULL register name arrays.
+ (parse_mips_dis_option): Likewise.
+ (print_insn_arg): Handle "+D" operand type.
+ * mips-opc.c (mips_builtin_opcodes): Add new "+D" variants
+ of mfc0, mtc0, dmfc0, and dmtc0 to print CP0+sel register
+ names symbolically.
+
+2002-12-30 Chris Demetriou <cgd@broadcom.com>
+
+ * mips-dis.c (mips_cp0_names_mips3264r2, mips_hwr_names_numeric)
+ (mips_hwr_names_mips3264r2): New arrays.
+ (mips_arch_choice): New "hwr_names" member.
+ (mips_arch_choices): Adjust for structure change, and add a new
+ entry for "mips32r2" ISA.
+ (mips_hwr_names): New variable.
+ (set_default_mips_dis_options): Set mips_hwr_names.
+ (parse_mips_dis_option): New "hwr-names" option which sets
+ mips_hwr_names, and adjust "reg-names=ARCH" to set mips_hwr_names.
+ (print_insn_arg): Change return type to "int"
+ and use that to indicate number of characters consumed.
+ Add support for "+" operand extension character, "+A", "+B",
+ "+C", and "K" operands.
+ (print_insn_mips): Adjust for changes to print_insn_arg.
+ (print_mips_disassembler_options): Adjust for "hwr-names"
+ addition and "reg-names" change.
+ * mips-opc (I33): New define (shorthand for INSN_ISA32R2).
+ (mips_builtin_opcodes): Note that "nop" and "ssnop" are special
+ forms of "sll". Add new MIPS32 Release 2 instructions: ehb,
+ di, ei, ext, ins, jr.hb, jalr.hb, mfhc1, mfhc2, mthc1, mthc2,
+ rdhwr, rdpgpr, seb, seh, synci, wrpgpr, wsbh.
+ Note that hardware rotate instructions (ror, rorv) can be
+ used on MIPS32 Release 2, and add the official mnemonics
+ for them (rotr, rotrv) and the similar "rotl" mnemonic for
+ left-rotate.
+
+2002-12-30 Dmitry Diky <diwil@mail.ru>
+
+ * configure.in: Add msp430 target.
+ * configure: Regenerate.
+ * disassemble.c: Add entry for msp430 disassembly.
+ * msp430-dis.c: New file: msp430 disassembler.
+
+2002-12-27 Chris Demetriou <cgd@broadcom.com>
+
+ * disassemble.c (disassembler_usage): Add invocation of
+ print_mips_disassembler_options.
+ * mips-dis.c: Include libiberty.h.
+ (print_mips_disassembler_options, set_default_mips_dis_options)
+ (parse_mips_dis_option, parse_mips_dis_options, choose_abi_by_name)
+ (choose_arch_by_name, choose_arch_by_number): New functions.
+ (mips_abi_choice, mips_arch_choice): New structures.
+ (mips32_reg_names, mips64_reg_names, reg_names): Remove.
+ (mips_gpr_names_numeric, mips_gpr_names_oldabi)
+ (mips_gpr_names_newabi, mips_fpr_names_numeric)
+ (mips_fpr_names_32, mips_fpr_names_n32, mips_fpr_names_64)
+ (mips_cp0_names_numeric, mips_cp0_names_mips3264)
+ (mips_cp0_names_sb1, mips_abi_choices, mips_arch_choices)
+ (mips_processor, mips_isa, mips_gpr_names, mips_fpr_names)
+ (mips_cp0_names): New variables.
+ (print_insn_args): Use new variables to print GPR, FPR, and CP0
+ register names.
+ (mips_isa_type): Remove.
+ (print_insn_mips): Remove ISA and CPU setup since it is now done...
+ (_print_insn_mips): Here. Remove register setup code, and
+ call set_default_mips_dis_options and parse_mips_dis_options
+ instead.
+ (print_mips16_insn_arg): Use mips_gpr_names instead of mips32_names.
+
+2002-12-23 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.in: Regenerate.
+
+2002-12-19 Nick Kelsey <nickk@ubicom.com>
+
+ * cgen-asm.c (cgen_parse_keyword): Added underscore to symbol character
+ check to fix false keyword trigger with names such as <keyword>_foo.
+
+2002-12-19 Doug Evans <dje@sebabeach.org>
+
+ * Makefile.am (CGEN_CPUS): New variable.
+ (run-cgen-all): New rule.
+ * Makefile.in: Regenerate.
+
+2002-12-18 Chris Demetriou <cgd@broadcom.com>
+
+ * mips-opc.c (mips_builtin_opcodes): Remove one "ror" and two
+ "dror" entries, and reorder the remaining "dror" and "ror" entries.
+
+2002-12-16 DJ Delorie <dj@delorie.com>
+
+ * xstormy16-asm.c (parse_immediate16): Add prototype.
+
+2002-12-16 Andrew MacLeod <amacleod@redhat.com>
+
+ * xstormy16-asm.c: Regenerate.
+
+2002-12-16 Alan Modra <amodra@bigpond.net.au>
+
+ * ns32k-dis.c (print_insn_ns32k): Constify "d", remove register
+ keyword.
+
+2002-12-13 Alan Modra <amodra@bigpond.net.au>
+
+ * h8500-opc.h (h8500_table): Add missing initializers to quiet
+ warnings.
+ * pj-dis.c (print_insn_pj): Adjust for pj_opc_info_t change.
+ * pj-opc.c (pj_opc_info): Add braces around union initializer.
+ * z8kgen.c: Include "libiberty.h".
+ (opt, args, toks): Fix initializer warnings.
+ (chewname): Make "name" a char **. Return mnemonic trimmed of
+ operands.
+ (gas): Improve emitted "DO NOT EDIT" warning. Format emitted
+ opcode_entry_type, and make "nicename" and "name" const. Make
+ z8k_table const too. Formatting. Generate idx as gas needs it.
+ * z8k-opc.h: Regenerate.
+
+2002-12-08 Stephane Carrez <stcarrez@nerim.fr>
+
+ * m68hc11-dis.c (print_indexed_operand): Fix PC-relative address
+ for 9 and 16-bit PC-relative addressing mode.
+
+2002-12-05 Aldy Hernandez <aldyh@redhat.com>
+
+ * ppc-opc.c: Delete evsabs, evsnabs, evsneg, evsadd, evssub,
+ evsmul, evsdiv, evscmpgt, evsgmplt, evststgt, evtstlt, evststeq,
+ evscfui, evscfsi, evscfuf, evscfsf, evsctui, evsctuiz, evsctsi,
+ evsctsiz, evsctuf, evsctsf, evmwhssfaa, evmwhssmaa, evmwhsmfaa,
+ evmwhsmiaa, evmwhusiaa, evmwhumiaa, evmwhssfan, evmwhssian,
+ evmwhsmfan, evmwhsmian, evmwhusian, evmwhumian, evmwhgssfaa,
+ evmwhgsmfaa, evmwhgsmiaa, evmwhgumiaa, evmwhgssfan, evmwhgsmfan,
+ evmwhgsmian, evmwhgumian.
+ (mftb): Add to opcode table.
+ (mtspefscr): Change RT to RS in opcode table.
+
+2002-12-05 Aldy Hernandez <aldyh@redhat.com>
+
+ * ppc-opc.c: Move mbar and msync up. Change mask for mbar and
+ msync.
+
+2002-12-04 David Mosberger <davidm@hpl.hp.com>
+
+ * ia64-opc-d.c (ia64_opcodes_d): Add "hint" instruction.
+ * ia64-opc-b.c: Add "hint.b" instruction.
+ * ia64-opc-f.c: Add "hint.f" instruction.
+ * ia64-opc-i.c: Add "hint.i" instruction.
+ * ia64-opc-m.c: Add "hint.m", "fc.i", "ld16", "st16", and
+ "cmp8xchg16" instructions.
+ * ia64-opc-x.c: Add "hint.x" instruction.
+
+ * ia64-opc.h (AR_CSD): New macro.
+
+ * ia64-ic.tbl: Update according to SDM2.1.
+ * ia64-raw.tbl: Ditto.
+ * ia64-waw.tbl: Ditto.
+
+ * ia64-gen.c (in_iclass): Handle "hint" like "nop".
+ (lookup_regindex): Recognize AR[FCR], AR[EFLAG], AR[CSD],
+ AR[SSD], AR[CFLG], AR[FSR], AR[FIR], and AR[FDR].
+ * ia64-asmtab.c: Regenerate.
+
+2002-11-25 Aldy Hernandez <aldyh@redhat.com>
+
+ * ppc-opc.c: Remove evmwlssf, evmwlssfa, evmwlsmf, evmwlsmfa,
+ evmwlssfaaw, evmwlsmfaaw, evmwlssfanw, evmwlsfanw.
+
+2002-12-04 Aldy Hernandez <aldyh@redhat.com>
+
+ * ppc-opc.c (PMRN): Remove.
+ (RA): Set to NB + 1.
+ (powerpc_opcodes): Change PMRN to SPR.
+ Change all RD to RS.
+ Change mftb to look like mftbl.
+ Move mftb before mftbl.
+ Add mfbbtar.
+ Add mtbbtar.
+ Change mfpmr to use PMR.
+ Change mtpmr to use PMR.
+ (RD): Remove.
+ (insert_ev2): Fix mask and shift.
+ (extract_ev2): Same.
+ (insert_ev4): Same.
+ (extract_ev4): Same.
+ (PMR): Define.
+ (extract_pmrn): Remove.
+ (insert_pmrn): Remove.
+
+2002-12-03 Richard Henderson <rth@redhat.com>
+
+ * ia64-opc-m.c: Add ld8.mov.
+ * ia64-asmtab.c: Regenerate.
+
+2002-12-02 Alan Modra <amodra@bigpond.net.au>
+
+ * arm-dis.c (print_insn_arm): Constify "insn". Formatting.
+ (print_insn_thumb): Likewise.
+ * h8500-dis.c (print_insn_h8500): Constify "opcode".
+ * mcore-dis.c (print_insn_mcore): Constify "op". Formatting.
+ * ns32k-dis.c (print_insn_arg <case 'F'>): Use a union to avoid
+ type-punned pointer warnings.
+ <case 'L'>: Likewise. Fix error message too.
+ * pdp11-dis.c (print_reg): Warning fix.
+ * sh-dis.c (print_movxy): Constify "op" param.
+ (print_insn_ddt): Constify sh_opcode_info vars.
+ (print_insn_ppi): Likewise.
+ (print_insn_sh): Likewise.
+ * tic30-dis.c (cnvt_tmsfloat_ieee): Use a union to avoid
+ type-punned pointer warnings.
+ * w65-dis.c (print_insn_w65): Constify "op".
+
+2002-12-01 Stephane Carrez <stcarrez@nerim.fr>
+
+ * m68hc11-dis.c (PC_REGNUM): Define.
+ (print_indexed_operand): Need an adjustment for some PC-relative
+ operand modes; print the final address of PC-relative modes.
+ (print_insn): Take into account movw/movb to adjust the PC-relative
+ operand addresses.
+
+2002-11-30 Alan Modra <amodra@bigpond.net.au>
+
+ *arm-dis.c, cris-dis.c, h8300-dis.c, mips-dis.c, mmix-dis.c, sh-dis.c,
+ sh64-dis.c, v850-dis.c: Replace boolean with bfd_boolean, true with
+ TRUE, false with FALSE. Simplify comparisons of bfd_boolean vars
+ with TRUE/FALSE. Formatting.
+
+2002-11-25 DJ Delorie <dj@redhat.com>
+
+ * xstormy16-opc.c: Regenerate.
+
+2002-11-25 Jim Wilson <wilson@redhat.com>
+
+ * ia64-dis.c (print_insn_ia64): Correct handling of IA64_OPND_TGT64.
+
+2002-11-15 DJ Delorie <dj@redhat.com>
+
+ * xstormy16-desc.c: Regenerate.
+ * xstormy16-opc.c: Regenerate.
+ * xstormy16-opc.h: Regenerate.
+
+2002-11-18 Klee Dienes <kdienes@apple.com>
+
+ * avr-dis.c: Include libiberty.h (for xmalloc).
+ (struct avr_opcodes_s): Remove 'bin_mask' field (it's
+ automatically computed in the init routine).
+ (AVR_INSN): No longer provide bin_mask field in initializer.
+ (avr_opcodes_s): Declare as const.
+ (print_insn_avr): Store the bin_mask field in a separate table
+ (allocated with xmalloc); iterate through it at the same time as
+ we iterate through the opcodes.
+
+2002-11-18 Klee Dienes <kdienes@apple.com>
+
+ * h8300-dis.c: Include libiberty.h (for xmalloc).
+ (struct h8_instruction): New type, used to wrap h8_opcodes with a
+ length field (computed at run-time).
+ (h8_instructions): New variable.
+ (bfd_h8_disassemble_init): Allocate the storage for
+ h8_instructions. Fill h8_instructions with pointers to the
+ appropriate opcode and the correct value for the length field.
+ (bfd_h8_disassemble): Iterate through h8_instructions instead of
+ h8_opcodes.
+
+2002-11-18 Klee Dienes <kdienes@apple.com>
+
+ * arc-opc.c (arc_ext_opcodes): Define.
+ (arc_ext_operands): Define.
+ * i386-dis.c (Suffix3DNow): Declare as const.
+ * arm-opc.h (arm_opcodes): Declare as const.
+ (thumb_opcodes): Declare as const.
+ * h8500-opc.h (h8500_table): Declare as const.
+ (h8500_table): Use a NULL for the opcode in the terminator, so
+ that code testing (opcode->name) behaves correctly.
+ * mcore-opc.h (mcore_table): Declare as const.
+ * sh-opc.h (sh_table): Declare as const.
+ * w65-opc.h (optable): Declare as const.
+ * z8k-opc.h (z8k_table): Declare as const.
+
+2002-11-18 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * tic4x-dis.c: Added support for enhanced and special insn.
+ (c4x_print_op): Added insn class 'i' and 'j'
+ (c4x_hash_opcode_special): Add to support special insn
+ (c4x_hash_opcode): Update to support the new opcode-list
+ format. Add support for the new special insns.
+ (c4x_disassemble): New opcode-list support.
+
+2002-11-16 Klee Dienes <kdienes@apple.com>
+
+ * m88k-dis.c: Include libiberty.h (for xmalloc).
+ (HASHTAB): New type, used to build instruction hash tables.
+ Contains a pointer to an INSTAB and a pointer to the next hash
+ chain entry.
+ (instructions): Move definition from m88k.h; remove initialization
+ of 'next' field.
+ (hashtable): Now an aray of pointer-to-HASHTAB, not INSTAB.
+ (printop): Mark pointer to OPSPEC as const.
+ (install): Remove; fold into init_disasm.
+ (m88kdis): Update to ihashtab_initialized to 1 after calling
+ init_disasm. entry_ptr now iterates through HASHTABs, not
+ INSTABs.
+ (init_disasm): Iterate through the instructions and add to
+ hashtable[].
+
+2002-11-16 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * tic4x-dis.c: (c4x_print_op): Add support for the new argument
+ format. Fix bug in 'N' register printer.
+
+2002-11-12 Segher Boessenkool <segher@koffie.nl>
+
+ * ppc-dis.c (print_insn_powerpc): Correct condition register display.
+
+2002-11-07 Aldy Hernandez <aldyh@redhat.com>
+
+ * ppc-opc.c (EVUIMM_4): Change bit size to 32.
+ (EVUIMM_2): Same.
+ (EVUIMM_8): Same.
+
+2002-11-07 Klee Dienes <kdienes@apple.com>
+
+ * Makefile.am (ia64-asmtab.c): Update to use the new '--srcdir'
+ argument to ia64-gen.
+ Regenerate dependencies for ia64-len.lo.
+ * Makefile.in: Regenerate.
+ * ia64-gen.c: Convert to use getopt(). Add the standard GNU
+ options, as well as '--srcdir', which controls the directory in
+ which ia64-gen looks for the sources it uses to generate the
+ output table. Add a 'const' to the declaration of the final
+ output table. Call xmalloc_set_program_name to set the program
+ name.
+ * ia64-asmtab.c: Regenerate.
+
+2002-11-07 Nick Clifton <nickc@redhat.com>
+
+ * ia64-gen.c: Fix comment formatting and compile time warnings.
+ * ia64-opc-a.c: Fix compile time warnings.
+ * ia64-opc-b.c: Likewise.
+ * ia64-opc-d.c: Likewise.
+ * ia64-opc-f.c: Likewise.
+ * ia64-opc-i.c: Likewise.
+ * ia64-opc-m.c: Likewise.
+ * ia64-opc-x.c: Likewise.
+
+2002-11-06 Aldy Hernandez <aldyh@redhat.com>
+
+ * ppc-opc.c: Change RD to RS for evmerge*.
+
+2002-10-07 Nathan Tallent <eraxxon@alumni.rice.edu>
+
+ * sparc-opc.c (sparc_opcodes) <fb, fba, fbe, fbz, fbg, fbge,
+ fbl, fble, fblg, fbn, fbne, fbnz, fbo, fbu, fbue, fbug, fbuge,
+ fbul, fbule>: Add conditional/unconditional branch
+ classification.
+
+2002-10-13 Stephane Carrez <stcarrez@nerim.fr>
+
+ * m68hc11-dis.c (print_insn): Treat bitmask and branch operands
+ at the end.
+
+2002-09-30 Gavin Romig-Koch <gavin@redhat.com>
+ Ken Raeburn <raeburn@cygnus.com>
+ Aldy Hernandez <aldyh@redhat.com>
+ Eric Christopher <echristo@redhat.com>
+ Richard Sandiford <rsandifo@redhat.com>
+
+ * mips-dis.c (print_insn_arg): Handle '[', ']', 'e' and '%'.
+ (mips_isa_type): Handle bfd_mach_mips4120, bfd_mach_mips5400
+ and bfd_mach_mips5500.
+ * mips-opc.c (V1): Include INSN_4111 and INSN_4120.
+ (N411, N412, N5, N54, N55): New convenience defines.
+ (mips_builtin_opcodes): Add vr4120, vr5400 and vr5500 opcodes.
+ Change dmadd16 and madd16 from V1 to N411.
+
+2002-09-26 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * mips-dis.c (print_insn_mips): Always allow disassembly of
+ 32-bit jalx opcode.
+
+2002-09-24 Nick Clifton <nickc@redhat.com>
+
+ * po/de.po: Updated German translation.
+
+2002-09-21 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * po/POTFILES.in: Regenerate.
+
+2002-09-20 Nick Clifton <nickc@redhat.com>
+
+ * ppc-opc.c (CRFD, CRFS): Add PPC_OPERAND_CR flag so that cr
+ register names are accepted.
+
+2002-09-17 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * tic4x-dis.c: Add function declarations and ATTRIBUTE_UNUSED.
+ Convert functions to K&R format.
+
+2002-09-13 Nick Clifton <nickc@redhat.com>
+
+ * ppc-opc.c (MFDEC2): Include Book-E.
+ (PPCCHLK64): New opcode mask.
+ (evsubw, evsubiw, evmr, evnot, isellt, iselgt, iseleq, mfpid,
+ mfcsrr0, mfcsrr1, mfdear, mfesr, mfivpr, mfusprg0, mftbl,
+ mftbu, mfpir, mfdbsr, mfdbcr0, mfdbcr1, mfdbcr2, mfiac1,
+ mfiac2, mfiac3, mfiac4, mfdac1, mfdac2, mfdvc1, mfdvc2, mftsr,
+ mftcr, mfivor0, mfivor1, mfivor2, mfivor3, mfivor4, mfivor5,
+ mfivor6, mfivor7, mfivor8, mfivor9, mfivor10, mfivor11,
+ mfivor12, mfivor13, mfivor14, mfivor15, mfbbear, mfmcsrr0,
+ mfmcsrr1, mfmcsr, mtpid, mtdecar, mtcsrr0, mtcsrr1, mtdear,
+ mtesr, mtivpr, mtusprg0, mtsprg4, mtsprg5, mtsprg6, mtsprg7,
+ mtdbsr, mtdbcr0, mtdbcr1, mtdbcr2, mtiac1, mtiac2, mtiac3,
+ mtiac4, mtdac1, mtdac2, mtdvc1, mtdvc2, mttsr, mttcr, mtivor0,
+ mtivor1, mtivor2, mtivor3, mtivor4, mtivor5, mtivor6, mtivor7,
+ mtivor8, mtivor9, mtivor10, mtivor11, mtivor12, mtivor13,
+ mtivor14, mtivor15, mtbbear, mtmcsrr0, mtmcsrr1, mtmcsr): New
+ Book-E instructions.
+ (evfsneg): Fix opcode value.
+ (dcbtstlse, dcbtlse, icblce, dcblce, icbtsle): Use PPCCHLK64
+ mask.
+ (mcrxr64, tlbivaxe, tlbsxe, tlbsxe.): Restrict to 64-bit
+ Book-E.
+ (extsw): Restrict to 64-bit PPC instruction sets.
+ (extsw.): Does not exist in 64-bit Book-E.
+ (powerpc_macro): Remove mftbl, mftbu and mftb Book-E macros as
+ they are no longer needed.
+
+2002-09-12 Gary Hade <garyhade@us.ibm.com>
+
+ * ppc-dis.c (powerpc_dialect): Add missing PPC_OPCODE_CLASSIC.
+
+2002-09-11 Nick Clifton <nickc@redhat.com>
+
+ * po/da.po: Updated Danish translation file.
+
+2002-09-04 Nick Clifton <nickc@redhat.com>
+
+ * ppc-opc.c (extsw, extsw.): Do not allow for the BookE32.
+
+2002-09-04 Nick Clifton <nickc@redhat.com>
+
+ * disassemble.c (disassembler_usage): Add invocation of
+ print_ppc_disassembler_options.
+ * ppc-dis.c (print_ppc_disassembler_options): New function.
+
+2002-09-04 Nick Clifton <nickc@redhat.com>
+
+ * ppc-opc.c: The BookE implementations of the TLBWE and TLBRE
+ instructions do not take any arguments.
+
+2002-09-02 Nick Clifton <nickc@redhat.com>
+
+ * v850-opc.c: Remove redundant references to V850EA architecture.
+
+2002-09-02 Alan Modra <amodra@bigpond.net.au>
+
+ * arc-opc.c: Include bfd.h.
+ (arc_get_opcode_mach): Subtract off base bfd_mach value.
+
+2002-08-30 Alan Modra <amodra@bigpond.net.au>
+
+ * v850-dis.c (disassemble): Remove bfd_mach_v850ea case.
+
+ * mips-dis.c (_print_insn_mips): Don't use hard-coded mach constants.
+
+2002-08-28 Svein E. Seldal <Svein.Seldal@solidas.com>
+
+ * configure.in: Added bfd_tic4x_arch.
+ * configure: Regenerate.
+ * Makefile.am: Added tic4x-dis.o target.
+ * Makefile.in: Regenerate.
+
+2002-08-28 Michael Hayes <m.hayes@elec.canterbury.ac.nz>
+
+ * disassemble.c: Added tic4x target and c4x
+ disassembler routine.
+ * tic4x-dis.c: New file.
+
+2002-08-16 Christian Groessler <chris@groessler.org>
+
+ * z8k-dis.c (unparse_instr): case CLASS_BA: Designate hex
+ values as those.
+ * z8kgen.c (opt): Fix definition of "in rd,imm16" opcode.
+ * z8k-opc.h: Regenerated with new z8kgen.c.
+
+2002-08-19 Elena Zannoni <ezannoni@redhat.com>
+
+ From matthew green <mrg@redhat.com>
+
+ * ppc-dis.c (powerpc_dialect): Support `-m500', `-m500x2' and
+ `-mefs'. Turn off AltiVec for E500 and efs.
+ (print_insn_powerpc): Don't print an AltiVec instruction if the
+ dialect is not efs.
+
+ * ppc-opc.c (insert_pmrn, extract_pmrn, insert_ev2, extract_ev2,
+ insert_ev4, extract_ev4, insert_ev8, extract_ev8): New functions
+ for extracting pmrn/evld/evstd/etc operands.
+ (CRB, CRFD, CRFS, DC, RD): New instruction fields.
+ (CT): Make this equal to RD + 1.
+ (PMRN): New operand.
+ (RA): Update.
+ (EVUIMM, EVUIMM_2, EVUIMM_4, EVUIMM_8): New operands.
+ (WS): Update.
+ (EVSEL, EVSEL_MASK): New instruction form and mask for EVSEL.
+ (ISEL, ISEL_MASK): New instruction form and mask for ISEL.
+ (XISEL, XISEL_MASK): New instruction form and mask for ISEL.
+ (CTX, CTX_MASK): New instruction form and mask for context cache
+ instructions.
+ (UCTX, UCTX_MASK): New instruction form and mask for user context
+ cache instructions.
+ (XC, XC_MASK, XUC, XUC_MASK): New instruction forms.
+ (CLASSIC): New define.
+ (PPCESPE): New define.
+ (PPCISEL, , PPCBRLK, PPCPMR, PPCCHLK, PPCRFMI): New
+ defines for integer select, cache control, branch
+ locking, power management, cache locking and machine check
+ APU instructions, respectively.
+ (efsabs, efsnabs, efsneg, efsadd, efssub, efsmul,
+ efsdiv, efscmpgt, efscmplt, efscmpeq, efststgt, efststlt,
+ efststeq, efscfui, efsctuiz, efscfsi, efscfuf, efscfsf,
+ efsctui, efsctsi, efsctsiz, efsctuf, efsctsf,
+ evaddw, evaddiw, evsubfw, evsubifw, evabs, evneg, evextsb,
+ evextsh, evrndw, evcntlzw, evcntlsw, brinc, evand, evandc, evor,
+ evorc, evxor, eveqv, evnand, evnor, evrlw, evrlwi, evslw, evslwi,
+ evsrws, evsrwu, evsrwis, evsrwiu, evsplati, evsplatfi, evmergehi,
+ evmergelo, evmergehilo, evmergelohi, evcmpgts, evcmpgtu, evcmplts,
+ evcmpltu, evcmpeq, evsel, evldd, evlddx, evldw, evldwx, evldh,
+ evldhx, evlwhe, evlwhex, evlwhou, evlwhoux, evlwhos, evlwhosx,
+ evlwwsplat, evlwwsplatx, evlwhsplat, evlwhsplatx, evlhhesplat,
+ evlhhesplatx, evlhousplat, evlhousplatx, evlhossplat, evlhossplatx,
+ evstdd, evstddx, evstdw, evstdwx, evstdh, evstdhx, evstwwe,
+ evstwwex, evstwwo, evstwwox, evstwhe, evstwhex, evstwho, evstwhox,
+ evfsabs, evfsnabs, evfsneg, evfsadd, evfssub, evfsmul, evfsdiv,
+ evfscmpgt, evfscmplt, evfscmpeq, evfststgt, evfststlt, evfststeq,
+ evfscfui, evfsctuiz, evfscfsi, evfscfuf, evfscfsf, evfsctui,
+ evfsctsi, evfsctsiz, evfsctuf, evfsctsf, evsabs, evsnabs, evsneg,
+ evsadd, evssub, evsmul, evsdiv, evscmpgt, evsgmplt, evsgmpeq,
+ evststgt, evststlt, evststeq, evscfui, evscfsi, evscfuf, evscfsf,
+ evsctui, evsctuiz, evsctsi, evsctsiz, evsctuf, evsctsf, evmhossf,
+ evmhossfa, evmhosmf, evmhosmfa, evmhosmi, evmhosmia, evmhoumi,
+ evmhoumia, evmhessf, evmhessfa, evmhesmf, evmhesmfa, evmhesmi,
+ evmhesmia, evmheumi, evmheumia, evmhossfaaw, evmhossiaaw,
+ evmhosmfaaw, evmhosmiaaw, evmhousiaaw, evmhoumiaaw, evmhessfaaw,
+ evmhessiaaw, evmhesmfaaw, evmhesmiaaw, evmheusiaaw, evmheumiaaw,
+ evmhossfanw, evmhossianw, evmhosmfanw, evmhosmianw, evmhousianw,
+ evmhoumianw, evmhessfanw, evmhessianw, evmhesmfanw, evmhesmianw,
+ evmheusianw, evmheumianw, evmhogsmfaa, evmhogsmiaa, evmhogumiaa,
+ evmhegsmfaa, evmhegsmiaa, evmhegumiaa, evmhogsmfan, evmhogsmian,
+ evmhogumian, evmhegsmfan, evmhegsmian, evmhegumian, evmwhssf,
+ evmwhssfa, evmwhssfaa, evmwhssmaa, evmwhsmfaa, evmwhsmiaa,
+ evmwhusiaa, evmwhumiaa, evmwhssfan, evmwhssian, evmwhsmfan,
+ evmwhsmian, evmwhusian, evmwhumian, evmwhgssfaa, evmwhgsmfaa,
+ evmwhgsmiaa, evmwhgumiaa, evmwhgssfan, evmwhgsmfan, evmwhgsmian,
+ evmwhgumian, evmwhsmf, evmwhsmfa, evmshsmi, evmshsmia, evmshumi,
+ evmshumia, evmmlssf, evmmlssfa, evmwlsmf, evmwlsmfa, evmwlumi,
+ evmwlumia, evmwlssfaaw, evmwlssiaaw, evmwlsmfaaw, evmwlsmiaaw,
+ evmwlusiaaw, evmwlumiaaw, evmwissfanw, evmwissianw, evmwlsmfanw,
+ evmwlsmianw, evmwlusianw, evmwlumianw, evmwssf, evmwssfa,
+ evmwsmf, evmwsmfa, evmwsmi, evmwsmia, evmwumi, evmwumia,
+ evmwssfaa, evmwsmfaa, evmwsmiaa, evmwumiaa, evmwssfan, evmwsmfan,
+ evmwsmian, evmwumian, evaddssiaaw, evaddsmiaaw, evaddusiaaw,
+ evaddumiaaw, evsubfssiaaw, evsubfsmiaaw, evsubfusiaaw,
+ evsubfumiaaw, evmra, evdivws, evdivws): New e500x2 Core Complex
+ instructions.
+ (rfmci): New machine check APU instruction.
+ (isel): New integer select APU instructino.
+ (icbtls, icbtlse, icblc, icblce, dcbtls, dcbtlse, dcbtstls,
+ dcbtstlse, dcblc, dcblce): New cache control APU instructions.
+ (mtspefscr, mfspefscr): New instructions.
+ (mfpmr, mtpmr): New performance monitor APU instructions.
+ (savecontext): New context cache APU instructions.
+ (bblels, bbelr): New branch locking APU instructions.
+ (bblels, bbelr): New instructions.
+ (mftbl, mftbu, mftb): Set as CLASSIC instructions. Add BOOKE alias.
+
+2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
+
+ * m68hc11-opc.c: Update call operand to accept the page definition.
+ Identify instructions that are branches and calls to generate a
+ RL_JUMP relocation.
+
+2002-08-13 Stephane Carrez <stcarrez@nerim.fr>
+
+ * m68hc11-dis.c (print_insn): Take into account 68HC12 memory
+ banks and fix disassembling of call instruction.
+ (print_indexed_operand): New param to tell whether
+ it was an indirect addressing operand (for disassembling call).
+
+2002-08-09 Nick Clifton <nickc@redhat.com>
+
+ * po/sv.po: Updated Swedish translation.
+
+2002-08-08 Maciej W. Rozycki <macro@ds2.pg.gda.pl>
+
+ * mips-opc.c (mips_builtin_opcodes): Remove "dla" and "la" as
+ aliases to "daddiu" and "addiu".
+
+2002-07-30 Nick Clifton <nickc@redhat.com>
+
+ * po/sv.po: Updated Swedish translation.
+
+2002-07-25 Nick Clifton <nickc@redhat.com>
+
+ * po/sv.po: Updated Swedish translation.
+ * po/es.po: Updated Spanish translation.
+ * po/pr_BR.po: Updated Brazilian Portuguese translation.
+ * po/tr.po: Updated Turkish translation.
+ * po/fr.po: Updated French translation.
+
+2002-07-24 Nick Clifton <nickc@redhat.com>
+
+ * po/sv.po: Updated Swedish translation.
+ * po/es.po: Updated Spanish translation.
+ * po/pr_BR.po: Updated Brazilian Portuguese translation.
+
+2002-07-23 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * po/POTFILES.in: Regenerate.
+
+2002-07-23 Nick Clifton <nickc@redhat.com>
+
+ * po/fr.po: Updated French translation.
+ * po/pr_BR.po: New Brazilian Portuguese translation.
+ * po/id.po: Updated Indonesian translation.
+ * configure.in (LINGUAS): Add pr_BR.
+ * configure: Regenerate.
+
+2002-07-18 Denis Chertykov <denisc@overta.ru>
+ Frank Ch. Eigler <fche@redhat.com>
+ Alan Lehotsky <alehotsky@cygnus.com>
+ matthew green <mrg@redhat.com>
+
+ * configure.in: Add support for ip2k.
+ * configure: Regenerate.
+ * Makefile.am: Add support for ip2k.
+ * Makefile.in: Regenerate.
+ * disassemble.c: Add support for ip2k.
+ * ip2k-asm.c: New generated file.
+ * ip2k-desc.c: New generated file.
+ * ip2k-desc.h: New generated file.
+ * ip2k-dis.c: New generated file.
+ * ip2k-ibld.c: New generated file.
+ * ip2k-opc.c: New generated file.
+ * ip2k-opc.h: New generated file.
+
+2002-07-17 David Mosberger <davidm@hpl.hp.com>
+
+ * ia64-opc-b.c (bWhc): New macro.
+ (mWhc): Ditto.
+ (OpPaWhcD): Ditto.
+ (ia64_opcodes_b): Correct patterns for indirect call
+ instructions to use 3-bit "wh" field.
+ * ia64-asmtab.c: Regnerate.
+
+2002-07-09 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * mips-dis.c (mips_isa_type): Add MIPS16 insn handling.
+ * mips-opc.c (I16): New define.
+ (mips_builtin_opcodes): Make jalx an I16 insn.
+
+2002-06-18 Dave Brolley <brolley@redhat.com>
+
+ * po/POTFILES.in: Add frv-*.[ch].
+ * disassemble.c (ARCH_frv): New macro.
+ (disassembler): Handle bfd_arch_frv.
+ * configure.in: Support frv_bfd_arch.
+ * Makefile.am (HFILES): Add frv-*.h.
+ (CFILES): Add frv-*.c
+ (ALL_MACHINES): Add frv-*.lo.
+ (CLEANFILES): Add stamp-frv.
+ (FRV_DEPS): New variable.
+ (stamp-frv): New target.
+ (frv-asm.lo): New target.
+ (frv-desc.lo): New target.
+ (frv-dis.lo): New target.
+ (frv-ibld.lo): New target.
+ (frv-opc.lo): New target.
+ (frv-*.[ch]): New files.
+
+2002-06-18 Ben Elliston <bje@redhat.com>
+
+ * Makefile.am (CGENDEPS): Remove unnecessary stamp-cgen.
+ * Makefile.in: Regenerate.
+
+2002-06-08 Alan Modra <amodra@bigpond.net.au>
+
+ * a29k-dis.c: Replace CONST with const.
+ * h8300-dis.c: Likewise.
+ * m68k-dis.c: Likewise.
+ * or32-dis.c: Likewise.
+ * sparc-dis.c: Likewise.
+
+2002-06-04 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * configure.in: Add "sh5*-*" to list of targets which include
+ sh64 support.
+ * configure: Regenerate.
+
+2002-05-31 Chris G. Demetriou <cgd@broadcom.com>
+
+ * mips-opc.c: Clean up a few whitespace issues, and sort a
+ few entries understanding that 'x' follows 'w' in the alphabet.
+
+2002-05-31 Chris G. Demetriou <cgd@broadcom.com>
+ Ed Satterthwaite <ehs@broadcom.com>
+
+ * mips-opc.c: Add support for SB-1 MDMX subset and extensions.
+
+2002-05-31 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * po/POTFILES.in: Regenerate.
+
+2002-05-30 Chris G. Demetriou <cgd@broadcom.com>
+ Ed Satterthwaite <ehs@broadcom.com>
+
+ * mips-dis.c (print_insn_arg): Add support for 'O', 'Q', 'X', 'Y',
+ and 'Z' formats, for MDMX.
+ (mips_isa_type): Add MDMX instructions to the ISA
+ bit mask for bfd_mach_mipsisa64.
+ * mips-opc.c: Add support for MDMX instructions.
+ (MX): New definition.
+
+ * mips-dis.c: Update copyright years to include 2002.
+
+2002-05-30 Diego Novillo <dnovillo@redhat.com>
+
+ * d10v-opc.c (d10v_opcodes): `btsti' does not modify its
+ arguments.
+
+2002-05-28 Kuang Hwa Lin <kuang@sbcglobal.net>
+
+ * configure.in: Add DLX configuraton support.
+ * configure: Regenerate.
+ * Makefile.am: Add DLX configuraton support.
+ * Makefile.in: Regenerate.
+ * disassemble.c: Add DLX support.
+ * dlx-dis.c: New file.
+
+2002-05-25 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am (sh-dis.lo): Don't put make commands in deps.
+ * Makefile.in: Regenerate.
+ * arc-dis.c: Use #include "" instead of <> for local header files.
+ * m68k-dis.c: Likewise.
+
+2002-05-22 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * Makefile.am (sh-dis.lo): Compile with @archdefs@.
+ * Makefile.in: regenerate.
+
+ * sh-dis.c (print_insn_sh): If coff and bfd_mach_sh, use arch_sh4
+ for disassembly.
+
+2002-05-22 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * mips-opc.c (mips_builtin_opcodes): Add drol, dror macros.
+
+2002-05-17 J"orn Rennecke <joern.rennecke@superh.com>
+
+ * disassemble.c (disassembler): Just use print_insn_sh for bfd_arch_sh.
+ * sh-dis.c (LITTLE_BIT): Delete.
+ (print_insn_sh, print_insn_shl): Deleted.
+ (print_insn_shx): Renamed to
+ (print_insn_sh). No longer static. Handle SHmedia instructions.
+ Use info->endian to determine endianness.
+ * sh64-dis.c (print_insn_sh64, print_insn_sh64l): Delete.
+ (print_insn_sh64x): No longer static. Renamed to
+ (print_insn_sh64). Removed pfun_compact and endian arguments.
+ If we got an uneven address to indicate SHmedia, adjust it.
+ Return -2 for SHcompact instructions.
+
+2002-05-17 Alan Modra <amodra@bigpond.net.au>
+
+ * acinclude.m4 (AM_INSTALL_LIBBFD): Fake to fool autotools.
+ * configure.in: Invoke AM_INSTALL_LIBBFD.
+ * Makefile.am (install-data-local): Move to..
+ (install_libopcodes): .. New target.
+ (uninstall_libopcodes): Likewise.
+ (install-bfdlibLTLIBRARIES): Likewise.
+ (uninstall-bfdlibLTLIBRARIES): Likewise.
+ (bfdlibdir): New.
+ (bfdincludedir): New.
+ (lib_LTLIBRARIES): Rename to bfdlib_LTLIBRARIES.
+ * aclocal.m4: Regenerate.
+ * configure: Regenerate.
+ * Makefile.in: Regenerate.
+
+2002-05-15 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * fr30-asm.c: Regenerate.
+ * fr30-desc.c: Regenerate.
+ * fr30-dis.c: Regenerate.
+ * m32r-asm.c: Regenerate.
+ * m32r-desc.c: Regenerate.
+ * m32r-dis.c: Regenerate.
+ * openrisc-asm.c: Regenerate.
+ * openrisc-desc.c: Regenerate.
+ * openrisc-dis.c: Regenerate.
+ * xstormy16-asm.c: Regenerate.
+ * xstormy16-desc.c: Regenerate.
+ * xstormy16-dis.c: Regenerate.
+
+2002-05-15 Thiemo Seufer <seufer@csv.ica.uni-stuttgart.de>
+
+ * mips-dis.c (is_newabi): EABI is not a NewABI.
+
+2002-05-13 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * configure.in (shle-*-*elf*): Include sh64 support.
+ * configure: Regenerate.
+
+2002-04-28 Jason Thorpe <thorpej@wasabisystems.com>
+
+ * vax-dis.c (print_insn_arg): Pass the insn info to print_insn_mode.
+ (print_insn_mode): Print some basic info about floating point values.
+
+2002-05-09 Anton Blanchard <anton@samba.org>
+
+ * ppc-opc.c: Add "tlbiel" for POWER4.
+
+2002-05-07 Graydon Hoare <graydon@redhat.com>
+
+ * cgen-dis.in: (print_insn_@arch@): Cache list of opened CPUs rather
+ than just most-recently-opened.
+
+2002-05-01 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc-opc.c: Add "tlbsx." and "tlbsxe." for booke.
+
+2002-04-24 Christian Groessler <chris@groessler.org>
+
+ * z8k-dis.c (print_insn_z8k): Set disassemble_info to 2
+ bytes_per_chunk, 6 bytes_per_line for nicer display of the hex
+ codes.
+ (z8k_lookup_instr): CLASS_IGNORE case added.
+ (output_instr): Don't print hex codes, they are already
+ printed.
+ (unpack_instr): ARG_NIM4 case added. ARG_NIM8 case
+ fixed. Support CLASS_BIT_1OR2 and CLASS_IGNORE cases.
+ (unparse_instr): Fix base and indexed addressing disassembly:
+ The index is inside the brackets.
+ * z8kgen.c (gas): Add ARG_NIM4 and CLASS_IGNORE defines.
+ (opt): Fix shift left/right arithmetic/logical byte defines:
+ The high byte of the immediate word is ignored by the
+ processor.
+ Fix n parameter of ldm opcodes: The opcode contains (n-1).
+ (args): Fix "n" entry.
+ (toks): Add "nim4" and "iiii" entries.
+ * z8k-opc.h: Regenerated with new z8kgen.c.
+
+2002-04-24 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/id.po: New Indonesian translation.
+ * configure.in (ALL_LIGUAS): Add id.po
+ * configure: Regenerate.
+
+2002-04-17 matthew green <mrg@redhat.com>
+
+ * ppc-opc.c (powerpc_opcode): Fix dssall operand list.
+
+2002-04-04 Alan Modra <amodra@bigpond.net.au>
+
+ * dep-in.sed: Cope with absolute paths.
+ * Makefile.am (dep.sed): Subst TOPDIR.
+ Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * ppc-opc.c: Whitespace.
+ * s390-dis.c: Fix copyright date.
+
+2002-03-23 matthew green <mrg@redhat.com>
+
+ * ppc-opc.c (vmaddfp): Fix operand order.
+
+2002-03-21 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+
+2002-03-21 Anton Blanchard <anton@samba.org>
+
+ * ppc-opc.c: Add optional field to mtmsrd.
+ (MTMSRD_L, XRLARB_MASK): Define.
+
+2002-03-18 Jan Hubicka <jh@suse.cz>
+
+ * i386-dis.c (prefix_name): Fix handling of 32bit address prefix
+ in 64bit mode.
+ (print_insn) Likewise.
+ (putop): Fix handling of 'E'
+ (OP_E, OP_OFF): handle 32bit addressing mode in 64bit.
+ (ptr_reg): Likewise.
+
+2002-03-18 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/fr.po: Updated version.
+
+2002-03-16 Chris Demetriou <cgd@broadcom.com>
+
+ * mips-opc.c (M3D): Tweak comment.
+ (mips_builtin_op): Add comment indicating that opcodes of the
+ same name must be placed together in the table, and sort
+ the "recip.fmt", "recip1.fmt", "recip2.fmt", "rsqrt.fmt",
+ "rsqrt1.fmt", and "rsqrt2.fmt" opcodes by name.
+
+2002-03-16 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * Makefile.am: Tidy up sh64 rules.
+ * Makefile.in: Regenerate.
+
+2002-03-15 Chris G. Demetriou <cgd@broadcom.com>
+
+ * mips-dis.c: Update copyright years.
+
+2002-03-15 Chris G. Demetriou <cgd@broadcom.com>
+
+ * mips-dis.c (mips_isa_type): Add MIPS3D instructions to the ISA
+ bit masks for bfd_mach_mips_sb1 and bfd_mach_mipsisa64. Add
+ comments for bfd_mach_mipsisa32 and bfd_mach_mipsisa64 that
+ indicate that they should dissassemble all applicable
+ MIPS-specified ASEs.
+ * mips-opc.c: Add support for MIPS-3D instructions.
+ (M3D): New definition.
+
+ * mips-opc.c: Update copyright years.
+
+2002-03-15 Chris G. Demetriou <cgd@broadcom.com>
+
+ * mips-opc.c (mips_builtin_opcodes): Sort bc<N> opcodes by name.
+
+2002-03-15 Chris Demetriou <cgd@broadcom.com>
+
+ * mips-dis.c (is_newabi): Fix ABI decoding.
+
+2002-03-14 Chris G. Demetriou <cgd@broadcom.com>
+
+ * mips-dis.c (mips_isa_type): Fix formatting of bfd_mach_mipsisa32
+ and bfd_mach_mipsisa64 cases to match the rest.
+
+2002-03-13 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/fr.po: Updated version.
+
+2002-03-13 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc-opc.c: Add optional `L' field to tlbie.
+ (XRTLRA_MASK): Define.
+
+2002-03-06 Chris Demetriou <cgd@broadcom.com>
+
+ * mips-opc.c (mips_builtin_opcodes): Mark "pref" as being
+ present on I4.
+
+ * mips-opc.c (mips_builtin_opcodes): Add "movn.ps" and "movz.ps".
+
+2002-03-05 Paul Koning <pkoning@equallogic.com>
+
+ * pdp11-opc.c: Fix "mark" operand type. Fix operand types
+ for float opcodes that take float operands. Add alternate
+ names (xxxD vs. xxxF) for float opcodes.
+ * pdp11-dis.c (print_operand): Clean up formatting for mode 67.
+ (print_foperand): New function to handle float opcode operands.
+ (print_insn_pdp11): Use print_foperand to disassemble float ops.
+
+2002-02-27 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/de.po: Updated.
+
+2002-02-26 Brian Gaeke <brg@dgate.org>
+
+ * Makefile.am (install-data-local): Install dis-asm.h.
+
+2002-02-26 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * configure.in (LINGUAS): Add de.po.
+ * configure: Regenerate.
+ * po/de.po: New file.
+
+2002-02-25 Alan Modra <amodra@bigpond.net.au>
+
+ * ppc-dis.c (powerpc_dialect): Handle power4 option.
+ * ppc-opc.c (insert_bdm): Correct description of "at" branch
+ hints. Test PPC_OPCODE_POWER4 to determine branch hint flavour.
+ (extract_bdm, insert_bdp, extract_bdp, valid_bo): Likewise.
+ (BOFM64, BOFP64, BOTM64, BOFP64): Rename to BOFM4, BOFP4 etc.
+ (BODNZM64, BODNZP64, BODZM64, BODZP64): Likewise.
+ (PPCCOM32, PPCCOM64): Delete.
+ (NOPOWER4, POWER4): Define.
+ (powerpc_opcodes): Replace occurences of PPCCOM32 with NOPOWER4,
+ and PPCCOM4 with POWER4 so that "at" style branch hint opcodes
+ are enabled for power4 rather than ppc64.
+
+2002-02-20 Tom Rix <trix@redhat.com>
+
+ * ppc-opc.c (powerpc_operands): Add WS field. Use for tlbre, tlbwe.
+
+2002-02-19 Martin Schwidefsky <schwidefsky@de.ibm.com>
+
+ * s390-dis.c (init_disasm): Use renamed architecture defines.
+
+2002-02-19 matthew green <mrg@redhat.com>
+
+ * ppc-opc.c (powerpc_dialect): Fix comment; BookE is not Motorola
+ specific.
+
+2002-02-18 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/tr.po: Updated translation.
+
+2002-02-15 Richard Henderson <rth@redhat.com>
+
+ * alpha-opc.c (alpha_opcodes): Fix thinko in ret pseudo
+ disassembly mask.
+
+2002-02-15 Richard Henderson <rth@redhat.com>
+
+ * alpha-opc.c (alpha_opcodes): Add simple pseudos for
+ lda, ldah, jmp, ret.
+
+2002-02-14 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/da.po: Updated translation.
+
+2002-02-12 Graydon Hoare <graydon@redhat.com>
+
+ * cgen-asm.in (parse_insn_normal): Change call from
+ @arch@_cgen_parse_operand to cd->parse_operand, to
+ facilitate CGEN_ASM_INIT_HOOK doing useful work.
+
+2002-02-11 Alexandre Oliva <aoliva@redhat.com>
+
+ * sparc-dis.c (print_insn_sparc): Make sure 0xFFFFFFFF is not
+ sign-extended.
+
+2002-02-11 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: "make dep-am".
+ * Makefile.in: Regenerate.
+ * aclocal.m4: Regenerate.
+ * config.in: Regenerate.
+ * configure: Regenerate.
+
+2002-02-10 Hans-Peter Nilsson <hp@bitrange.com>
+
+ * configure.in <bfd_sh_arc>: For sh-* and shl-*, enable sh64
+ support only for sh-*-*elf*, shl-*-*elf*, sh-*-linux* and
+ shl-*-linux*.
+ * configure: Regenerate.
+
+2002-02-10 Daniel Jacobowitz <drow@mvista.com>
+
+ * cgen-dis.c: Add prototypes for count_decodable_bits
+ and add_insn_to_hash_chain.
+
+2002-02-08 Alexandre Oliva <aoliva@redhat.com>
+
+ * configure.in <bfd_sh_arc>: Enable sh64 support on sh-*.
+ * configure: Rebuilt.
+
+2002-02-08 Ivan Guzvinec <ivang@opencores.org>
+
+ * or32-opc.c: Fix compile time warning messages.
+ * or32-dis.c: Fix compile time warning messages.
+
+2002-02-08 Alexandre Oliva <aoliva@redhat.com>
+
+ Contribute sh64-elf.
+ 2001-10-08 Nick Clifton <nickc@cambridge.redhat.com>
+ * sh64-opc.c: Regenerate.
+ 2001-03-13 DJ Delorie <dj@redhat.com>
+ * sh64-opc.h: Rename A_RESV_Fx to A_REUSE_PREV so that its
+ purpose is more obvious.
+ * sh64-opc.c (shmedia_table): Ditto.
+ * sh64-dis.c (initialize_shmedia_opcode_mask_table): Ditto.
+ (print_insn_shmedia): Ditto.
+ 2001-03-12 DJ Delorie <dj@redhat.com>
+ * sh64-opc.c: Adjust comments to reflect reality: replace bits
+ 3:0 with zeros (not "reserved"), replace "rrrrrr" with
+ "gggggg" for two-operand floating point opcodes. Remove
+ "fsina".
+ 2001-01-08 Hans-Peter Nilsson <hpn@cygnus.com>
+ * sh64-dis.c (print_insn_shmedia) <failing read_memory_func>:
+ Correct printing of .byte:s. Return number of printed bytes or
+ -1; never 0.
+ (print_insn_sh64x) <not CRT_SH5_ISA16>: Ditto. Print as .byte:s
+ to next four-byte-alignment if insn or data is not aligned.
+ 2001-01-06 Hans-Peter Nilsson <hpn@cygnus.com>
+ * sh64-dis.c: Update comments and fix comment formatting.
+ (initialize_shmedia_opcode_mask_table) <case A_IMMM>:
+ Abort instead of setting length to 0.
+ (crange_qsort_cmpb, crange_qsort_cmpl, crange_bsearch_cmpb,
+ crange_bsearch_cmpl, sh64_get_contents_type,
+ sh64_address_in_cranges): Move to bfd/elf32-sh64.c.
+ 2001-01-05 Hans-Peter Nilsson <hpn@cygnus.com>
+ * sh64-opc.c: Remove #if 0:d entries for instructions not found in
+ SH-5/ST50-023-04: fcosa.s, fsrra.s and prefo.
+ 2000-12-30 Hans-Peter Nilsson <hpn@cygnus.com>
+ * sh64-dis.c (print_insn_shmedia): Display MOVI/SHORI-formed
+ address with same prefix as SHcompact.
+ In the disassembler, use a .cranges section for linked executables.
+ * sh64-dis.c (SAVED_MOVI_R, SAVED_MOVI_IMM): Move to head of file
+ and update for using structure in info->private_data.
+ (struct sh64_disassemble_info): New.
+ (is_shmedia_p): Delete.
+ (crange_qsort_cmpb): New function.
+ (crange_qsort_cmpl, crange_bsearch_cmpb): New functions.
+ (crange_bsearch_cmpl, sh64_address_in_cranges): New functions.
+ (init_sh64_disasm_info, sh64_get_contents_type_disasm): New functions.
+ (sh64_get_contents_type, sh64_address_is_shmedia): New functions.
+ (print_insn_shmedia): Correct displaying of address after MOVI/SHORI
+ pair. Display addresses for linked executables only.
+ (print_insn_sh64x_media): Initialize info->private_data by calling
+ init_sh64_disasm_info.
+ (print_insn_sh64x): Ditto. Find out type of contents by calling
+ sh64_contents_type_disasm. Display data regions using ".long" and
+ ".byte" similar to unrecognized opcodes.
+ 2000-12-19 Hans-Peter Nilsson <hpn@cygnus.com>
+ * sh64-dis.c (is_shmedia_p): Check info->section and look for ISA
+ information in section flags before considering symbols. Don't
+ assume an info->mach setting of bfd_mach_sh5 means SHmedia code.
+ * configure.in (bfd_sh_arch): Check presence of sh64 insns by
+ matching $target $canon_targets instead of looking at the
+ now-removed -DINCLUDE_SHMEDIA in $targ_cflags.
+ * configure: Regenerate.
+ 2000-11-25 Hans-Peter Nilsson <hpn@cygnus.com>
+ * sh64-opc.c (shmedia_creg_table): New.
+ * sh64-opc.h (shmedia_creg_info): New type.
+ (shmedia_creg_table): Declare.
+ * sh64-dis.c (creg_name): New function.
+ (print_insn_shmedia): Use it.
+ * disassemble.c (disassembler) [ARCH_sh, INCLUDE_SHMEDIA]: Map
+ bfd_mach_sh5 to print_insn_sh64 if big-endian and to
+ print_insn_sh64l if little-endian.
+ * sh64-dis.c (print_insn_shmedia): Make r unsigned.
+ (print_insn_sh64l): New.
+ (print_insn_sh64x): New.
+ (print_insn_sh64x_media): New.
+ (print_insn_sh64): Break out code to print_insn_sh64x and
+ print_insn_sh64x_media.
+ 2000-11-24 Hans-Peter Nilsson <hpn@cygnus.com>
+ * sh64-opc.h: New file
+ * sh64-opc.c: New file
+ * sh64-dis.c: New file
+ * Makefile.am: Add sh64 targets.
+ (HFILES): Add sh64-opc.h.
+ (CFILES): Add sh64-opc.c and sh64-dis.c.
+ (ALL_MACHINES): Add sh64 files.
+ * Makefile.in: Regenerate.
+ * configure.in: Add support for sh64 to bfd_sh_arch.
+ * configure: Regenerate.
+ * disassemble.c [ARCH_all] (INCLUDE_SHMEDIA): Define.
+ (disassembler) [ARCH_sh, INCLUDE_SHMEDIA]: Map bfd_mach_sh5 to
+ print_insn_sh64.
+ * sh-dis.c (print_insn_shx): Handle bfd_mach_sh5 as arch_sh4.
+ * po/POTFILES.in: Regenerate.
+ * po/opcodes.pot: Regenerate.
+
+2002-02-04 Frank Ch. Eigler <fche@redhat.com>
+
+ * cgen-dis.in (print_insn_@arch@): Support disassemble_info.insn_sets.
+
+2002-02-04 Alexandre Oliva <aoliva@redhat.com>
+
+ * sh-opc.h (sh_arg_type): Added A_DISP_PC_ABS.
+
+2002-02-01 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am"
+ * Makefile.in: Regenerate.
+
+2002-01-31 Ivan Guzvinec <ivang@opencores.org>
+
+ * or32-dis.c: New file.
+ * or32-opc.c: New file.
+ * configure.in: Add support for or32.
+ * configure: Regenerate.
+ * Makefile.am: Add support for or32.
+ * Makefile.in: Regenerate.
+ * disassemble.c: Add support for or32.
+ * po/POTFILES.in: Regenerate.
+ * po/opcodes.pot: Regenerate.
+
+2002-01-27 Daniel Jacobowitz <drow@mvista.com>
+
+ * configure: Regenerated.
+
+2002-01-26 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/fr.po: Updated version.
+
+2002-01-25 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/es.po: Updated version.
+
+2002-01-24 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/da.po: New version.
+
+2002-01-23 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/da.po: New file: Spanish translation.
+ * configure.in (ALL_LINGUAS): Add da.
+ * configure: Regenerate.
+
+2002-01-22 Graydon Hoare <graydon@redhat.com>
+
+ * fr30-asm.c: Regenerate.
+ * fr30-desc.c: Likewise.
+ * fr30-desc.h: Likewise.
+ * fr30-dis.c: Likewise.
+ * fr30-ibld.c: Likewise.
+ * fr30-opc.c: Likewise.
+ * fr30-opc.h: Likewise.
+ * m32r-asm.c: Likewise.
+ * m32r-desc.c: Likewise.
+ * m32r-desc.h: Likewise.
+ * m32r-dis.c: Likewise.
+ * m32r-ibld.c: Likewise.
+ * m32r-opc.c: Likewise.
+ * m32r-opc.h: Likewise.
+ * m32r-opinst.c: Likewise.
+ * openrisc-asm.c: Likewise.
+ * openrisc-desc.c: Likewise.
+ * openrisc-desc.h: Likewise.
+ * openrisc-dis.c: Likewise.
+ * openrisc-ibld.c: Likewise.
+ * openrisc-opc.c: Likewise.
+ * openrisc-opc.h: Likewise.
+ * xstormy16-desc.c: Likewise.
+
+2002-01-22 Richard Henderson <rth@redhat.com>
+
+ * alpha-dis.c (print_insn_alpha): Also mask the base opcode for
+ comparison.
+
+2002-01-22 Alan Modra <amodra@bigpond.net.au>
+
+ * Makefile.am: Run "make dep-am".
+ * Makefile.in: Regenerate.
+ * po/POTFILES.in: Regenerate.
+
+2002-01-19 Richard Earnshaw <rearnsha@arm.com>
+
+ * arm-opc.h (arm_opcodes): Use generic rule %5?hb instead of %h.
+ * arm-dis.c (print_insn_arm): Don't handle 'h' case.
+
+2002-01-18 Keith Walker <keith.walker@arm.com>
+
+ * arm-opc.h (arm_opcodes): Add bxj instruction.
+
+2002-01-17 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/opcodes.pot: Regenerate.
+ * po/fr.po: Regenerate.
+ * po/sv.po: Regenerate.
+ * po/tr.po: Regenerate.
+
+2002-01-16 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/tr.po: Import new version.
+
+2002-01-15 Richard Earnshaw <rearnsha@arm.com>
+
+ * arm-opc.h (arm_opcodes): Add patterns for VFP instructions.
+ * arm-dis.c (print_insn_arm): Support new disassembly qualifiers for
+ VFP bitfields.
+
+2002-01-10 matthew green <mrg@redhat.com>
+
+ * xstormy16-asm.c: Regenerate.
+ * xstormy16-desc.c: Likewise.
+ * xstormy16-desc.h: Likewise.
+ * xstormy16-dis.c: Likewise.
+ * xstormy16-opc.c: Likewise.
+ * xstormy16-opc.h: Likewise.
+
+2002-01-07 Nick Clifton <nickc@cambridge.redhat.com>
+
+ * po/es.po: New file: Spanish translation.
+ * configure.in (ALL_LINGUAS): Add es.
+ * configure: Regenerate.
+
+For older changes see ChangeLog-0001
+
+Local Variables:
+mode: change-log
+left-margin: 8
+fill-column: 74
+version-control: never
+End:
diff --git a/contrib/binutils/opcodes/Makefile.am b/contrib/binutils/opcodes/Makefile.am
index bafdb57..ea621f2 100644
--- a/contrib/binutils/opcodes/Makefile.am
+++ b/contrib/binutils/opcodes/Makefile.am
@@ -30,6 +30,8 @@ HFILES = \
h8500-opc.h \
ia64-asmtab.h \
ia64-opc.h \
+ ip2k-desc.h ip2k-opc.h \
+ iq2000-desc.h iq2000-opc.h \
m32r-desc.h m32r-opc.h \
mcore-opc.h \
openrisc-desc.h openrisc-opc.h \
@@ -61,6 +63,7 @@ CFILES = \
d30v-opc.c \
dlx-dis.c \
dis-buf.c \
+ dis-init.c \
disassemble.c \
fr30-asm.c \
fr30-desc.c \
@@ -90,6 +93,16 @@ CFILES = \
ia64-opc.c \
ia64-gen.c \
ia64-asmtab.c \
+ ip2k-asm.c \
+ ip2k-desc.c \
+ ip2k-dis.c \
+ ip2k-ibld.c \
+ ip2k-opc.c \
+ iq2000-asm.c \
+ iq2000-desc.c \
+ iq2000-dis.c \
+ iq2000-ibld.c \
+ iq2000-opc.c \
m32r-asm.c \
m32r-desc.c \
m32r-dis.c \
@@ -134,6 +147,7 @@ CFILES = \
sparc-dis.c \
sparc-opc.c \
tic30-dis.c \
+ tic4x-dis.c \
tic54x-dis.c \
tic54x-opc.c \
tic80-dis.c \
@@ -147,6 +161,7 @@ CFILES = \
xstormy16-dis.c \
xstormy16-ibld.c \
xstormy16-opc.c \
+ xtensa-dis.c \
z8k-dis.c \
z8kgen.c
@@ -189,6 +204,16 @@ ALL_MACHINES = \
i960-dis.lo \
ia64-dis.lo \
ia64-opc.lo \
+ ip2k-asm.lo \
+ ip2k-desc.lo \
+ ip2k-dis.lo \
+ ip2k-ibld.lo \
+ ip2k-opc.lo \
+ iq2000-asm.lo \
+ iq2000-desc.lo \
+ iq2000-dis.lo \
+ iq2000-ibld.lo \
+ iq2000-opc.lo \
m32r-asm.lo \
m32r-desc.lo \
m32r-dis.lo \
@@ -210,6 +235,7 @@ ALL_MACHINES = \
mips16-opc.lo \
mmix-dis.lo \
mmix-opc.lo \
+ msp430-dis.lo \
ns32k-dis.lo \
openrisc-asm.lo \
openrisc-desc.lo \
@@ -232,6 +258,7 @@ ALL_MACHINES = \
sparc-dis.lo \
sparc-opc.lo \
tic30-dis.lo \
+ tic4x-dis.lo \
tic54x-dis.lo \
tic54x-opc.lo \
tic80-dis.lo \
@@ -245,6 +272,7 @@ ALL_MACHINES = \
xstormy16-dis.lo \
xstormy16-ibld.lo \
xstormy16-opc.lo \
+ xtensa-dis.lo \
z8k-dis.lo
OFILES = @BFD_MACHINES@
@@ -254,7 +282,12 @@ INCLUDES = -D_GNU_SOURCE -I. -I$(srcdir) -I../bfd -I$(INCDIR) -I$(BFDDIR) @HDEFI
disassemble.lo: disassemble.c $(INCDIR)/dis-asm.h
$(LIBTOOL) --mode=compile $(COMPILE) -c @archdefs@ $(srcdir)/disassemble.c
-libopcodes_la_SOURCES = dis-buf.c disassemble.c
+libopcodes_la_SOURCES = dis-buf.c disassemble.c dis-init.c
+# It's desirable to list ../bfd/libbfd.la in DEPENDENCIES and LIBADD.
+# Unfortunately this causes libtool to add -L$(libdir), referring to the
+# planned install directory of libbfd. This can cause us to pick up an
+# old version of libbfd, or to pick up libbfd for the wrong architecture
+# if host != build.
libopcodes_la_DEPENDENCIES = $(OFILES)
libopcodes_la_LIBADD = $(OFILES) @WIN32LIBADD@
libopcodes_la_LDFLAGS = -release $(VERSION) @WIN32LDFLAGS@
@@ -279,7 +312,7 @@ libopcodes.a: stamp-lib ; @true
POTFILES = $(HFILES) $(CFILES)
po/POTFILES.in: @MAINT@ Makefile
- for file in $(POTFILES); do echo $$file; done | sort > tmp \
+ for f in $(POTFILES); do echo $$f; done | LC_COLLATE= sort > tmp \
&& mv tmp $(srcdir)/po/POTFILES.in
# We should reconfigure whenever bfd/configure.in changes, because
@@ -312,8 +345,8 @@ uninstall_libopcodes:
rm -f $(DESTDIR)$(bfdincludedir)/dis-asm.h
CLEANFILES = \
- stamp-m32r stamp-fr30 stamp-frv stamp-openrisc \
- stamp-xstormy16 \
+ stamp-ip2k stamp-m32r stamp-fr30 stamp-frv stamp-openrisc \
+ stamp-iq2000 stamp-xstormy16 \
libopcodes.a stamp-lib dep.sed DEP DEPA DEP1 DEP2
@@ -329,52 +362,86 @@ CGENDEPS = \
$(CGENDIR)/opc-opinst.scm \
cgen-asm.in cgen-dis.in cgen-ibld.in
+CGEN_CPUS = fr30 frv ip2k m32r openrisc xstormy16
+
if CGEN_MAINT
+IP2K_DEPS = stamp-ip2k
M32R_DEPS = stamp-m32r
FR30_DEPS = stamp-fr30
FRV_DEPS = stamp-frv
OPENRISC_DEPS = stamp-openrisc
+IQ2000_DEPS = stamp-iq2000
XSTORMY16_DEPS = stamp-xstormy16
else
+IP2K_DEPS =
M32R_DEPS =
FR30_DEPS =
FRV_DEPS =
OPENRISC_DEPS =
+IQ2000_DEPS =
XSTORMY16_DEPS =
endif
run-cgen:
$(SHELL) $(srcdir)/cgen.sh opcodes $(srcdir) $(CGEN) \
- $(CGENDIR) "$(CGENFLAGS)" $(arch) $(prefix) \
- "$(options)" $(extrafiles)
+ $(CGENDIR) "$(CGENFLAGS)" $(arch) $(prefix) $(archfile) $(opcfile) \
+ "$(options)" "$(extrafiles)"
touch stamp-${prefix}
.PHONY: run-cgen
+# Maintainer utility rule to regenerate all cgen files.
+run-cgen-all:
+ for c in $(CGEN_CPUS) ; \
+ do \
+ $(MAKE) stamp-$$c || exit 1 ; \
+ done
+.PHONY: run-cgen-all
+
# For now, require developers to configure with --enable-cgen-maint.
+$(srcdir)/ip2k-desc.h $(srcdir)/ip2k-desc.c $(srcdir)/ip2k-opc.h $(srcdir)/ip2k-opc.c $(srcdir)/ip2k-ibld.c $(srcdir)/ip2k-asm.c $(srcdir)/ip2k-dis.c: $(IP2K_DEPS)
+ @true
+stamp-ip2k: $(CGENDEPS) $(CPUDIR)/ip2k.cpu $(CPUDIR)/ip2k.opc
+ $(MAKE) run-cgen arch=ip2k prefix=ip2k options= \
+ archfile=$(CPUDIR)/ip2k.cpu opcfile=$(CPUDIR)/ip2k.opc extrafiles=
+
$(srcdir)/m32r-desc.h $(srcdir)/m32r-desc.c $(srcdir)/m32r-opc.h $(srcdir)/m32r-opc.c $(srcdir)/m32r-ibld.c $(srcdir)/m32r-opinst.c $(srcdir)/m32r-asm.c $(srcdir)/m32r-dis.c: $(M32R_DEPS)
@true
stamp-m32r: $(CGENDEPS) $(CPUDIR)/m32r.cpu $(CPUDIR)/m32r.opc
- $(MAKE) run-cgen arch=m32r prefix=m32r options=opinst extrafiles=opinst
+ $(MAKE) run-cgen arch=m32r prefix=m32r options=opinst \
+ archfile=$(CPUDIR)/m32r.cpu opcfile=$(CPUDIR)/m32r.opc extrafiles=opinst
$(srcdir)/fr30-desc.h $(srcdir)/fr30-desc.c $(srcdir)/fr30-opc.h $(srcdir)/fr30-opc.c $(srcdir)/fr30-ibld.c $(srcdir)/fr30-asm.c $(srcdir)/fr30-dis.c: $(FR30_DEPS)
@true
stamp-fr30: $(CGENDEPS) $(CPUDIR)/fr30.cpu $(CPUDIR)/fr30.opc
- $(MAKE) run-cgen arch=fr30 prefix=fr30 options= extrafiles=
+ $(MAKE) run-cgen arch=fr30 prefix=fr30 options= \
+ archfile=$(CPUDIR)/fr30.cpu opcfile=$(CPUDIR)/fr30.opc extrafiles=
$(srcdir)/frv-desc.h $(srcdir)/frv-desc.c $(srcdir)/frv-opc.h $(srcdir)/frv-opc.c $(srcdir)/frv-ibld.c $(srcdir)/frv-asm.c $(srcdir)/frv-dis.c: $(FRV_DEPS)
@true
-stamp-frv: $(CGENDEPS) $(CPUDIR)/frv.cpu $(CPUDIR)/frv.opc
- $(MAKE) run-cgen arch=frv prefix=frv options= extrafiles=
+# .cpu and .opc files for frv are kept in a different directory, but cgen has no switch to specify that location, so
+# copy those file to the regular place.
+stamp-frv: $(CGENDEPS) $(srcdir)/../cpu/frv.cpu $(srcdir)/../cpu/frv.opc
+ $(MAKE) run-cgen arch=frv prefix=frv options= \
+ archfile=$(srcdir)/../cpu/frv.cpu opcfile=$(srcdir)/../cpu/frv.opc extrafiles=
$(srcdir)/openrisc-desc.h $(srcdir)/openrisc-desc.c $(srcdir)/openrisc-opc.h $(srcdir)/openrisc-opc.c $(srcdir)/openrisc-ibld.c $(srcdir)/openrisc-asm.c $(srcdir)/openrisc-dis.c: $(OPENRISC_DEPS)
@true
stamp-openrisc: $(CGENDEPS) $(CPUDIR)/openrisc.cpu $(CPUDIR)/openrisc.opc
- $(MAKE) run-cgen arch=openrisc prefix=openrisc options= extrafiles=
+ $(MAKE) run-cgen arch=openrisc prefix=openrisc options= \
+ archfile=$(CPUDIR)/openrisc.cpu opcfile=$(CPUDIR)/openrisc.opc extrafiles=
+
+$(srcdir)/iq2000-desc.h $(srcdir)/iq2000-desc.c $(srcdir)/iq2000-opc.h $(srcdir)/iq2000-opc.c $(srcdir)/iq2000-ibld.c $(srcdir)/iq2000-asm.c $(srcdir)/iq2000-dis.c: $(IQ2000_DEPS)
+ @true
+stamp-iq2000: $(CGENDEPS) $(CPUDIR)/iq2000.cpu $(CPUDIR)/iq2000.opc \
+ $(CPUDIR)/iq2000m.cpu $(CPUDIR)/iq10.cpu
+ $(MAKE) run-cgen arch=iq2000 prefix=iq2000 options= \
+ archfile=$(CPUDIR)/iq2000.cpu opcfile=$(CPUDIR)/iq2000.opc extrafiles=
$(srcdir)/xstormy16-desc.h $(srcdir)/xstormy16-desc.c $(srcdir)/xstormy16-opc.h $(srcdir)/xstormy16-opc.c $(srcdir)/xstormy16-ibld.c $(srcdir)/xstormy16-asm.c $(srcdir)/xstormy16-dis.c: $(XSTORMY16_DEPS)
@true
stamp-xstormy16: $(CGENDEPS) $(CPUDIR)/xstormy16.cpu $(CPUDIR)/xstormy16.opc
- $(MAKE) run-cgen arch=xstormy16 prefix=xstormy16 options= extrafiles=
+ $(MAKE) run-cgen arch=xstormy16 prefix=xstormy16 options= \
+ archfile=$(CPUDIR)/xstormy16.cpu opcfile=$(CPUDIR)/xstormy16.opc extrafiles=
ia64-gen: ia64-gen.o
$(LINK) ia64-gen.o $(LIBIBERTY)
@@ -383,7 +450,7 @@ ia64-gen.o: ia64-gen.c ia64-opc.c ia64-opc-a.c ia64-opc-b.c ia64-opc-f.c \
ia64-opc-i.c ia64-opc-m.c ia64-opc-d.c ia64-opc.h
ia64-asmtab.c: @MAINT@ ia64-gen ia64-ic.tbl ia64-raw.tbl ia64-waw.tbl ia64-war.tbl
- here=`pwd`; cd $(srcdir); $$here/ia64-gen > ia64-asmtab.c
+ ./ia64-gen --srcdir $(srcdir) > $(srcdir)/ia64-asmtab.c
s390-mkopc: s390-mkopc.c
$(CC_FOR_BUILD) -o s390-mkopc $(srcdir)/s390-mkopc.c
@@ -457,18 +524,18 @@ arc-dis.lo: arc-dis.c $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/arc.h \
$(INCDIR)/elf/reloc-macros.h opintl.h arc-dis.h arc-ext.h
arc-opc.lo: arc-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/opcode/arc.h
+ $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/opcode/arc.h
arc-ext.lo: arc-ext.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(BFD_H) $(INCDIR)/symcat.h arc-ext.h $(INCDIR)/libiberty.h
arm-dis.lo: arm-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h arm-opc.h \
$(INCDIR)/coff/internal.h $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h \
- opintl.h $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h \
- $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/elf/arm.h \
- $(INCDIR)/elf/reloc-macros.h
+ opintl.h $(INCDIR)/safe-ctype.h $(BFDDIR)/elf-bfd.h \
+ $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
+ $(INCDIR)/elf/arm.h $(INCDIR)/elf/reloc-macros.h
avr-dis.lo: avr-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h opintl.h \
- $(INCDIR)/opcode/avr.h
+ $(INCDIR)/libiberty.h $(INCDIR)/opcode/avr.h
cgen-asm.lo: cgen-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h $(BFD_H) \
$(INCDIR)/symcat.h $(INCDIR)/opcode/cgen.h opintl.h
@@ -495,6 +562,8 @@ dlx-dis.lo: dlx-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/opcode/dlx.h
dis-buf.lo: dis-buf.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h opintl.h
+dis-init.lo: dis-init.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h
disassemble.lo: disassemble.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h
fr30-asm.lo: fr30-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
@@ -503,36 +572,38 @@ fr30-asm.lo: fr30-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
fr30-desc.lo: fr30-desc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(BFD_H) $(INCDIR)/symcat.h fr30-desc.h $(INCDIR)/opcode/cgen.h \
- fr30-opc.h opintl.h $(INCDIR)/libiberty.h
+ fr30-opc.h opintl.h $(INCDIR)/libiberty.h $(INCDIR)/xregex.h \
+ $(INCDIR)/xregex2.h
fr30-dis.lo: fr30-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h fr30-desc.h \
- $(INCDIR)/opcode/cgen.h fr30-opc.h opintl.h
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/libiberty.h \
+ fr30-desc.h $(INCDIR)/opcode/cgen.h fr30-opc.h opintl.h
fr30-ibld.lo: fr30-ibld.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h fr30-desc.h \
$(INCDIR)/opcode/cgen.h fr30-opc.h opintl.h $(INCDIR)/safe-ctype.h
fr30-opc.lo: fr30-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(BFD_H) $(INCDIR)/symcat.h fr30-desc.h $(INCDIR)/opcode/cgen.h \
fr30-opc.h $(INCDIR)/libiberty.h
-frv-asm.lo: frv-asm.c sysdep.h config.h $(BFD_H) \
- $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h frv-desc.h \
- $(INCDIR)/opcode/cgen.h frv-opc.h opintl.h
-frv-desc.lo: frv-desc.c sysdep.h config.h $(BFD_H) \
- $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h frv-desc.h \
- $(INCDIR)/opcode/cgen.h frv-opc.h opintl.h
-frv-dis.lo: frv-dis.c sysdep.h config.h $(INCDIR)/dis-asm.h \
- $(BFD_H) $(INCDIR)/ansidecl.h \
- $(INCDIR)/symcat.h frv-desc.h $(INCDIR)/opcode/cgen.h \
- frv-opc.h opintl.h
-frv-ibld.lo: frv-ibld.c sysdep.h config.h $(INCDIR)/dis-asm.h \
- $(BFD_H) $(INCDIR)/ansidecl.h \
- $(INCDIR)/symcat.h frv-desc.h $(INCDIR)/opcode/cgen.h \
- frv-opc.h opintl.h
-frv-opc.lo: frv-opc.c sysdep.h config.h $(BFD_H) \
- $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h frv-desc.h \
- $(INCDIR)/opcode/cgen.h frv-opc.h
+frv-asm.lo: frv-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h frv-desc.h $(INCDIR)/opcode/cgen.h \
+ frv-opc.h opintl.h $(INCDIR)/xregex.h $(INCDIR)/xregex2.h \
+ $(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
+frv-desc.lo: frv-desc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h frv-desc.h $(INCDIR)/opcode/cgen.h \
+ frv-opc.h opintl.h $(INCDIR)/libiberty.h $(INCDIR)/xregex.h \
+ $(INCDIR)/xregex2.h
+frv-dis.lo: frv-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/libiberty.h \
+ frv-desc.h $(INCDIR)/opcode/cgen.h frv-opc.h opintl.h
+frv-ibld.lo: frv-ibld.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h frv-desc.h \
+ $(INCDIR)/opcode/cgen.h frv-opc.h opintl.h $(INCDIR)/safe-ctype.h
+frv-opc.lo: frv-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h frv-desc.h $(INCDIR)/opcode/cgen.h \
+ frv-opc.h $(INCDIR)/libiberty.h $(INCDIR)/elf/frv.h \
+ $(INCDIR)/elf/reloc-macros.h
h8300-dis.lo: h8300-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/opcode/h8300.h $(INCDIR)/dis-asm.h $(BFD_H) \
- $(INCDIR)/symcat.h opintl.h
+ $(INCDIR)/symcat.h opintl.h $(INCDIR)/libiberty.h
h8500-dis.lo: h8500-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
h8500-opc.h $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h \
opintl.h
@@ -567,21 +638,57 @@ ia64-opc.lo: ia64-opc.c $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
sysdep.h config.h ia64-asmtab.h $(INCDIR)/opcode/ia64.h \
$(BFD_H) $(INCDIR)/symcat.h ia64-asmtab.c
ia64-gen.lo: ia64-gen.c $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
- $(INCDIR)/safe-ctype.h sysdep.h config.h ia64-opc.h \
- $(INCDIR)/opcode/ia64.h $(BFD_H) $(INCDIR)/symcat.h \
+ $(INCDIR)/safe-ctype.h sysdep.h config.h $(INCDIR)/getopt.h \
+ ia64-opc.h $(INCDIR)/opcode/ia64.h $(BFD_H) $(INCDIR)/symcat.h \
ia64-opc-a.c ia64-opc-i.c ia64-opc-m.c ia64-opc-b.c \
ia64-opc-f.c ia64-opc-x.c ia64-opc-d.c
ia64-asmtab.lo: ia64-asmtab.c
+ip2k-asm.lo: ip2k-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h ip2k-desc.h $(INCDIR)/opcode/cgen.h \
+ ip2k-opc.h opintl.h $(INCDIR)/xregex.h $(INCDIR)/xregex2.h \
+ $(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
+ip2k-desc.lo: ip2k-desc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h ip2k-desc.h $(INCDIR)/opcode/cgen.h \
+ ip2k-opc.h opintl.h $(INCDIR)/libiberty.h $(INCDIR)/xregex.h \
+ $(INCDIR)/xregex2.h
+ip2k-dis.lo: ip2k-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/libiberty.h \
+ ip2k-desc.h $(INCDIR)/opcode/cgen.h ip2k-opc.h opintl.h
+ip2k-ibld.lo: ip2k-ibld.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h ip2k-desc.h \
+ $(INCDIR)/opcode/cgen.h ip2k-opc.h opintl.h $(INCDIR)/safe-ctype.h
+ip2k-opc.lo: ip2k-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h ip2k-desc.h $(INCDIR)/opcode/cgen.h \
+ ip2k-opc.h $(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
+iq2000-asm.lo: iq2000-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h iq2000-desc.h $(INCDIR)/opcode/cgen.h \
+ iq2000-opc.h opintl.h $(INCDIR)/xregex.h $(INCDIR)/xregex2.h \
+ $(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
+iq2000-desc.lo: iq2000-desc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h iq2000-desc.h $(INCDIR)/opcode/cgen.h \
+ iq2000-opc.h opintl.h $(INCDIR)/libiberty.h $(INCDIR)/xregex.h \
+ $(INCDIR)/xregex2.h
+iq2000-dis.lo: iq2000-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/libiberty.h \
+ iq2000-desc.h $(INCDIR)/opcode/cgen.h iq2000-opc.h \
+ opintl.h
+iq2000-ibld.lo: iq2000-ibld.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h iq2000-desc.h \
+ $(INCDIR)/opcode/cgen.h iq2000-opc.h opintl.h $(INCDIR)/safe-ctype.h
+iq2000-opc.lo: iq2000-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h iq2000-desc.h $(INCDIR)/opcode/cgen.h \
+ iq2000-opc.h $(INCDIR)/libiberty.h
m32r-asm.lo: m32r-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(BFD_H) $(INCDIR)/symcat.h m32r-desc.h $(INCDIR)/opcode/cgen.h \
m32r-opc.h opintl.h $(INCDIR)/xregex.h $(INCDIR)/xregex2.h \
$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
m32r-desc.lo: m32r-desc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(BFD_H) $(INCDIR)/symcat.h m32r-desc.h $(INCDIR)/opcode/cgen.h \
- m32r-opc.h opintl.h $(INCDIR)/libiberty.h
+ m32r-opc.h opintl.h $(INCDIR)/libiberty.h $(INCDIR)/xregex.h \
+ $(INCDIR)/xregex2.h
m32r-dis.lo: m32r-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h m32r-desc.h \
- $(INCDIR)/opcode/cgen.h m32r-opc.h opintl.h
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/libiberty.h \
+ m32r-desc.h $(INCDIR)/opcode/cgen.h m32r-opc.h opintl.h
m32r-ibld.lo: m32r-ibld.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h m32r-desc.h \
$(INCDIR)/opcode/cgen.h m32r-opc.h opintl.h $(INCDIR)/safe-ctype.h
@@ -603,14 +710,14 @@ m68k-opc.lo: m68k-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/opcode/m68k.h
m88k-dis.lo: m88k-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/opcode/m88k.h \
- opintl.h
+ opintl.h $(INCDIR)/libiberty.h
mcore-dis.lo: mcore-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
mcore-opc.h $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h
mips-dis.lo: mips-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/opcode/mips.h \
- opintl.h $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h \
- $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h \
- $(INCDIR)/elf/mips.h $(INCDIR)/elf/reloc-macros.h
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/libiberty.h \
+ $(INCDIR)/opcode/mips.h opintl.h $(BFDDIR)/elf-bfd.h \
+ $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
+ $(INCDIR)/bfdlink.h $(INCDIR)/elf/mips.h $(INCDIR)/elf/reloc-macros.h
mips-opc.lo: mips-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/opcode/mips.h
mips16-opc.lo: mips16-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
@@ -638,10 +745,12 @@ openrisc-asm.lo: openrisc-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
openrisc-desc.lo: openrisc-desc.c sysdep.h config.h \
$(INCDIR)/ansidecl.h $(BFD_H) $(INCDIR)/symcat.h openrisc-desc.h \
- $(INCDIR)/opcode/cgen.h openrisc-opc.h opintl.h $(INCDIR)/libiberty.h
+ $(INCDIR)/opcode/cgen.h openrisc-opc.h opintl.h $(INCDIR)/libiberty.h \
+ $(INCDIR)/xregex.h $(INCDIR)/xregex2.h
openrisc-dis.lo: openrisc-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h openrisc-desc.h \
- $(INCDIR)/opcode/cgen.h openrisc-opc.h opintl.h
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/libiberty.h \
+ openrisc-desc.h $(INCDIR)/opcode/cgen.h openrisc-opc.h \
+ opintl.h
openrisc-ibld.lo: openrisc-ibld.c sysdep.h config.h \
$(INCDIR)/ansidecl.h $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h \
openrisc-desc.h $(INCDIR)/opcode/cgen.h openrisc-opc.h \
@@ -678,7 +787,8 @@ sh64-dis.lo: sh64-dis.c $(INCDIR)/dis-asm.h $(BFD_H) \
$(INCDIR)/ansidecl.h $(INCDIR)/symcat.h sysdep.h config.h \
sh64-opc.h $(INCDIR)/libiberty.h $(BFDDIR)/elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
- $(INCDIR)/bfdlink.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h
+ $(INCDIR)/bfdlink.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
+ $(BFDDIR)/elf32-sh64.h
sh64-opc.lo: sh64-opc.c sh64-opc.h
sparc-dis.lo: sparc-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/opcode/sparc.h $(INCDIR)/dis-asm.h $(BFD_H) \
@@ -687,6 +797,8 @@ sparc-opc.lo: sparc-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/opcode/sparc.h
tic30-dis.lo: tic30-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/opcode/tic30.h
+tic4x-dis.lo: tic4x-dis.c $(INCDIR)/libiberty.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/opcode/tic4x.h
tic54x-dis.lo: tic54x-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/opcode/tic54x.h \
$(INCDIR)/coff/tic54x.h $(INCDIR)/coff/ti.h
@@ -713,11 +825,12 @@ xstormy16-asm.lo: xstormy16-asm.c sysdep.h config.h \
$(INCDIR)/xregex2.h $(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
xstormy16-desc.lo: xstormy16-desc.c sysdep.h config.h \
$(INCDIR)/ansidecl.h $(BFD_H) $(INCDIR)/symcat.h xstormy16-desc.h \
- $(INCDIR)/opcode/cgen.h xstormy16-opc.h opintl.h $(INCDIR)/libiberty.h
+ $(INCDIR)/opcode/cgen.h xstormy16-opc.h opintl.h $(INCDIR)/libiberty.h \
+ $(INCDIR)/xregex.h $(INCDIR)/xregex2.h
xstormy16-dis.lo: xstormy16-dis.c sysdep.h config.h \
$(INCDIR)/ansidecl.h $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h \
- xstormy16-desc.h $(INCDIR)/opcode/cgen.h xstormy16-opc.h \
- opintl.h
+ $(INCDIR)/libiberty.h xstormy16-desc.h $(INCDIR)/opcode/cgen.h \
+ xstormy16-opc.h opintl.h
xstormy16-ibld.lo: xstormy16-ibld.c sysdep.h config.h \
$(INCDIR)/ansidecl.h $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h \
xstormy16-desc.h $(INCDIR)/opcode/cgen.h xstormy16-opc.h \
@@ -725,7 +838,11 @@ xstormy16-ibld.lo: xstormy16-ibld.c sysdep.h config.h \
xstormy16-opc.lo: xstormy16-opc.c sysdep.h config.h \
$(INCDIR)/ansidecl.h $(BFD_H) $(INCDIR)/symcat.h xstormy16-desc.h \
$(INCDIR)/opcode/cgen.h xstormy16-opc.h $(INCDIR)/libiberty.h
+xtensa-dis.lo: xtensa-dis.c $(INCDIR)/xtensa-isa.h \
+ $(INCDIR)/ansidecl.h sysdep.h config.h $(INCDIR)/dis-asm.h \
+ $(BFD_H) $(INCDIR)/symcat.h
z8k-dis.lo: z8k-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h z8k-opc.h
-z8kgen.lo: z8kgen.c sysdep.h config.h $(INCDIR)/ansidecl.h
+z8kgen.lo: z8kgen.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h
# IF YOU PUT ANYTHING HERE IT WILL GO AWAY
diff --git a/contrib/binutils/opcodes/Makefile.in b/contrib/binutils/opcodes/Makefile.in
index b1b7ae1..559194d 100644
--- a/contrib/binutils/opcodes/Makefile.in
+++ b/contrib/binutils/opcodes/Makefile.in
@@ -1,6 +1,6 @@
-# Makefile.in generated automatically by automake 1.4-p5 from Makefile.am
+# Makefile.in generated automatically by automake 1.4 from Makefile.am
-# Copyright (C) 1994, 1995-8, 1999, 2001 Free Software Foundation, Inc.
+# Copyright (C) 1994, 1995-8, 1999 Free Software Foundation, Inc.
# This Makefile.in is free software; the Free Software Foundation
# gives unlimited permission to copy and/or distribute it,
# with or without modifications, as long as this notice is preserved.
@@ -140,6 +140,8 @@ HFILES = \
h8500-opc.h \
ia64-asmtab.h \
ia64-opc.h \
+ ip2k-desc.h ip2k-opc.h \
+ iq2000-desc.h iq2000-opc.h \
m32r-desc.h m32r-opc.h \
mcore-opc.h \
openrisc-desc.h openrisc-opc.h \
@@ -172,6 +174,7 @@ CFILES = \
d30v-opc.c \
dlx-dis.c \
dis-buf.c \
+ dis-init.c \
disassemble.c \
fr30-asm.c \
fr30-desc.c \
@@ -201,6 +204,16 @@ CFILES = \
ia64-opc.c \
ia64-gen.c \
ia64-asmtab.c \
+ ip2k-asm.c \
+ ip2k-desc.c \
+ ip2k-dis.c \
+ ip2k-ibld.c \
+ ip2k-opc.c \
+ iq2000-asm.c \
+ iq2000-desc.c \
+ iq2000-dis.c \
+ iq2000-ibld.c \
+ iq2000-opc.c \
m32r-asm.c \
m32r-desc.c \
m32r-dis.c \
@@ -245,6 +258,7 @@ CFILES = \
sparc-dis.c \
sparc-opc.c \
tic30-dis.c \
+ tic4x-dis.c \
tic54x-dis.c \
tic54x-opc.c \
tic80-dis.c \
@@ -258,6 +272,7 @@ CFILES = \
xstormy16-dis.c \
xstormy16-ibld.c \
xstormy16-opc.c \
+ xtensa-dis.c \
z8k-dis.c \
z8kgen.c
@@ -301,6 +316,16 @@ ALL_MACHINES = \
i960-dis.lo \
ia64-dis.lo \
ia64-opc.lo \
+ ip2k-asm.lo \
+ ip2k-desc.lo \
+ ip2k-dis.lo \
+ ip2k-ibld.lo \
+ ip2k-opc.lo \
+ iq2000-asm.lo \
+ iq2000-desc.lo \
+ iq2000-dis.lo \
+ iq2000-ibld.lo \
+ iq2000-opc.lo \
m32r-asm.lo \
m32r-desc.lo \
m32r-dis.lo \
@@ -322,6 +347,7 @@ ALL_MACHINES = \
mips16-opc.lo \
mmix-dis.lo \
mmix-opc.lo \
+ msp430-dis.lo \
ns32k-dis.lo \
openrisc-asm.lo \
openrisc-desc.lo \
@@ -344,6 +370,7 @@ ALL_MACHINES = \
sparc-dis.lo \
sparc-opc.lo \
tic30-dis.lo \
+ tic4x-dis.lo \
tic54x-dis.lo \
tic54x-opc.lo \
tic80-dis.lo \
@@ -357,6 +384,7 @@ ALL_MACHINES = \
xstormy16-dis.lo \
xstormy16-ibld.lo \
xstormy16-opc.lo \
+ xtensa-dis.lo \
z8k-dis.lo
@@ -364,7 +392,12 @@ OFILES = @BFD_MACHINES@
INCLUDES = -D_GNU_SOURCE -I. -I$(srcdir) -I../bfd -I$(INCDIR) -I$(BFDDIR) @HDEFINES@ -I$(srcdir)/../intl -I../intl
-libopcodes_la_SOURCES = dis-buf.c disassemble.c
+libopcodes_la_SOURCES = dis-buf.c disassemble.c dis-init.c
+# It's desirable to list ../bfd/libbfd.la in DEPENDENCIES and LIBADD.
+# Unfortunately this causes libtool to add -L$(libdir), referring to the
+# planned install directory of libbfd. This can cause us to pick up an
+# old version of libbfd, or to pick up libbfd for the wrong architecture
+# if host != build.
libopcodes_la_DEPENDENCIES = $(OFILES)
libopcodes_la_LIBADD = $(OFILES) @WIN32LIBADD@
libopcodes_la_LDFLAGS = -release $(VERSION) @WIN32LDFLAGS@
@@ -379,8 +412,8 @@ noinst_LIBRARIES = libopcodes.a
POTFILES = $(HFILES) $(CFILES)
CLEANFILES = \
- stamp-m32r stamp-fr30 stamp-frv stamp-openrisc \
- stamp-xstormy16 \
+ stamp-ip2k stamp-m32r stamp-fr30 stamp-frv stamp-openrisc \
+ stamp-iq2000 stamp-xstormy16 \
libopcodes.a stamp-lib dep.sed DEP DEPA DEP1 DEP2
@@ -396,6 +429,10 @@ CGENDEPS = \
$(CGENDIR)/opc-opinst.scm \
cgen-asm.in cgen-dis.in cgen-ibld.in
+
+CGEN_CPUS = fr30 frv ip2k m32r openrisc xstormy16
+@CGEN_MAINT_TRUE@IP2K_DEPS = @CGEN_MAINT_TRUE@stamp-ip2k
+@CGEN_MAINT_FALSE@IP2K_DEPS =
@CGEN_MAINT_TRUE@M32R_DEPS = @CGEN_MAINT_TRUE@stamp-m32r
@CGEN_MAINT_FALSE@M32R_DEPS =
@CGEN_MAINT_TRUE@FR30_DEPS = @CGEN_MAINT_TRUE@stamp-fr30
@@ -404,6 +441,8 @@ CGENDEPS = \
@CGEN_MAINT_FALSE@FRV_DEPS =
@CGEN_MAINT_TRUE@OPENRISC_DEPS = @CGEN_MAINT_TRUE@stamp-openrisc
@CGEN_MAINT_FALSE@OPENRISC_DEPS =
+@CGEN_MAINT_TRUE@IQ2000_DEPS = @CGEN_MAINT_TRUE@stamp-iq2000
+@CGEN_MAINT_FALSE@IQ2000_DEPS =
@CGEN_MAINT_TRUE@XSTORMY16_DEPS = @CGEN_MAINT_TRUE@stamp-xstormy16
@CGEN_MAINT_FALSE@XSTORMY16_DEPS =
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -422,7 +461,7 @@ libopcodes_a_SOURCES = libopcodes.a.c
libopcodes_a_OBJECTS = libopcodes.a.$(OBJEXT)
LTLIBRARIES = $(bfdlib_LTLIBRARIES)
-libopcodes_la_OBJECTS = dis-buf.lo disassemble.lo
+libopcodes_la_OBJECTS = dis-buf.lo disassemble.lo dis-init.lo
CFLAGS = @CFLAGS@
COMPILE = $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
LTCOMPILE = $(LIBTOOL) --mode=compile $(CC) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
@@ -583,7 +622,7 @@ maintainer-clean-recursive:
dot_seen=no; \
rev=''; list='$(SUBDIRS)'; for subdir in $$list; do \
rev="$$subdir $$rev"; \
- test "$$subdir" != "." || dot_seen=yes; \
+ test "$$subdir" = "." && dot_seen=yes; \
done; \
test "$$dot_seen" = "no" && rev=". $$rev"; \
target=`echo $@ | sed s/-recursive//`; \
@@ -807,7 +846,7 @@ stamp-lib: libopcodes.la
libopcodes.a: stamp-lib ; @true
po/POTFILES.in: @MAINT@ Makefile
- for file in $(POTFILES); do echo $$file; done | sort > tmp \
+ for f in $(POTFILES); do echo $$f; done | LC_COLLATE= sort > tmp \
&& mv tmp $(srcdir)/po/POTFILES.in
# We should reconfigure whenever bfd/configure.in changes, because
@@ -841,36 +880,64 @@ uninstall_libopcodes:
run-cgen:
$(SHELL) $(srcdir)/cgen.sh opcodes $(srcdir) $(CGEN) \
- $(CGENDIR) "$(CGENFLAGS)" $(arch) $(prefix) \
- "$(options)" $(extrafiles)
+ $(CGENDIR) "$(CGENFLAGS)" $(arch) $(prefix) $(archfile) $(opcfile) \
+ "$(options)" "$(extrafiles)"
touch stamp-${prefix}
.PHONY: run-cgen
+# Maintainer utility rule to regenerate all cgen files.
+run-cgen-all:
+ for c in $(CGEN_CPUS) ; \
+ do \
+ $(MAKE) stamp-$$c || exit 1 ; \
+ done
+.PHONY: run-cgen-all
+
# For now, require developers to configure with --enable-cgen-maint.
+$(srcdir)/ip2k-desc.h $(srcdir)/ip2k-desc.c $(srcdir)/ip2k-opc.h $(srcdir)/ip2k-opc.c $(srcdir)/ip2k-ibld.c $(srcdir)/ip2k-asm.c $(srcdir)/ip2k-dis.c: $(IP2K_DEPS)
+ @true
+stamp-ip2k: $(CGENDEPS) $(CPUDIR)/ip2k.cpu $(CPUDIR)/ip2k.opc
+ $(MAKE) run-cgen arch=ip2k prefix=ip2k options= \
+ archfile=$(CPUDIR)/ip2k.cpu opcfile=$(CPUDIR)/ip2k.opc extrafiles=
+
$(srcdir)/m32r-desc.h $(srcdir)/m32r-desc.c $(srcdir)/m32r-opc.h $(srcdir)/m32r-opc.c $(srcdir)/m32r-ibld.c $(srcdir)/m32r-opinst.c $(srcdir)/m32r-asm.c $(srcdir)/m32r-dis.c: $(M32R_DEPS)
@true
stamp-m32r: $(CGENDEPS) $(CPUDIR)/m32r.cpu $(CPUDIR)/m32r.opc
- $(MAKE) run-cgen arch=m32r prefix=m32r options=opinst extrafiles=opinst
+ $(MAKE) run-cgen arch=m32r prefix=m32r options=opinst \
+ archfile=$(CPUDIR)/m32r.cpu opcfile=$(CPUDIR)/m32r.opc extrafiles=opinst
$(srcdir)/fr30-desc.h $(srcdir)/fr30-desc.c $(srcdir)/fr30-opc.h $(srcdir)/fr30-opc.c $(srcdir)/fr30-ibld.c $(srcdir)/fr30-asm.c $(srcdir)/fr30-dis.c: $(FR30_DEPS)
@true
stamp-fr30: $(CGENDEPS) $(CPUDIR)/fr30.cpu $(CPUDIR)/fr30.opc
- $(MAKE) run-cgen arch=fr30 prefix=fr30 options= extrafiles=
+ $(MAKE) run-cgen arch=fr30 prefix=fr30 options= \
+ archfile=$(CPUDIR)/fr30.cpu opcfile=$(CPUDIR)/fr30.opc extrafiles=
$(srcdir)/frv-desc.h $(srcdir)/frv-desc.c $(srcdir)/frv-opc.h $(srcdir)/frv-opc.c $(srcdir)/frv-ibld.c $(srcdir)/frv-asm.c $(srcdir)/frv-dis.c: $(FRV_DEPS)
@true
-stamp-frv: $(CGENDEPS) $(CPUDIR)/frv.cpu $(CPUDIR)/frv.opc
- $(MAKE) run-cgen arch=frv prefix=frv options= extrafiles=
+# .cpu and .opc files for frv are kept in a different directory, but cgen has no switch to specify that location, so
+# copy those file to the regular place.
+stamp-frv: $(CGENDEPS) $(srcdir)/../cpu/frv.cpu $(srcdir)/../cpu/frv.opc
+ $(MAKE) run-cgen arch=frv prefix=frv options= \
+ archfile=$(srcdir)/../cpu/frv.cpu opcfile=$(srcdir)/../cpu/frv.opc extrafiles=
$(srcdir)/openrisc-desc.h $(srcdir)/openrisc-desc.c $(srcdir)/openrisc-opc.h $(srcdir)/openrisc-opc.c $(srcdir)/openrisc-ibld.c $(srcdir)/openrisc-asm.c $(srcdir)/openrisc-dis.c: $(OPENRISC_DEPS)
@true
stamp-openrisc: $(CGENDEPS) $(CPUDIR)/openrisc.cpu $(CPUDIR)/openrisc.opc
- $(MAKE) run-cgen arch=openrisc prefix=openrisc options= extrafiles=
+ $(MAKE) run-cgen arch=openrisc prefix=openrisc options= \
+ archfile=$(CPUDIR)/openrisc.cpu opcfile=$(CPUDIR)/openrisc.opc extrafiles=
+
+$(srcdir)/iq2000-desc.h $(srcdir)/iq2000-desc.c $(srcdir)/iq2000-opc.h $(srcdir)/iq2000-opc.c $(srcdir)/iq2000-ibld.c $(srcdir)/iq2000-asm.c $(srcdir)/iq2000-dis.c: $(IQ2000_DEPS)
+ @true
+stamp-iq2000: $(CGENDEPS) $(CPUDIR)/iq2000.cpu $(CPUDIR)/iq2000.opc \
+ $(CPUDIR)/iq2000m.cpu $(CPUDIR)/iq10.cpu
+ $(MAKE) run-cgen arch=iq2000 prefix=iq2000 options= \
+ archfile=$(CPUDIR)/iq2000.cpu opcfile=$(CPUDIR)/iq2000.opc extrafiles=
$(srcdir)/xstormy16-desc.h $(srcdir)/xstormy16-desc.c $(srcdir)/xstormy16-opc.h $(srcdir)/xstormy16-opc.c $(srcdir)/xstormy16-ibld.c $(srcdir)/xstormy16-asm.c $(srcdir)/xstormy16-dis.c: $(XSTORMY16_DEPS)
@true
stamp-xstormy16: $(CGENDEPS) $(CPUDIR)/xstormy16.cpu $(CPUDIR)/xstormy16.opc
- $(MAKE) run-cgen arch=xstormy16 prefix=xstormy16 options= extrafiles=
+ $(MAKE) run-cgen arch=xstormy16 prefix=xstormy16 options= \
+ archfile=$(CPUDIR)/xstormy16.cpu opcfile=$(CPUDIR)/xstormy16.opc extrafiles=
ia64-gen: ia64-gen.o
$(LINK) ia64-gen.o $(LIBIBERTY)
@@ -879,7 +946,7 @@ ia64-gen.o: ia64-gen.c ia64-opc.c ia64-opc-a.c ia64-opc-b.c ia64-opc-f.c \
ia64-opc-i.c ia64-opc-m.c ia64-opc-d.c ia64-opc.h
ia64-asmtab.c: @MAINT@ ia64-gen ia64-ic.tbl ia64-raw.tbl ia64-waw.tbl ia64-war.tbl
- here=`pwd`; cd $(srcdir); $$here/ia64-gen > ia64-asmtab.c
+ ./ia64-gen --srcdir $(srcdir) > $(srcdir)/ia64-asmtab.c
s390-mkopc: s390-mkopc.c
$(CC_FOR_BUILD) -o s390-mkopc $(srcdir)/s390-mkopc.c
@@ -953,18 +1020,18 @@ arc-dis.lo: arc-dis.c $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
$(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h $(INCDIR)/elf/arc.h \
$(INCDIR)/elf/reloc-macros.h opintl.h arc-dis.h arc-ext.h
arc-opc.lo: arc-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/opcode/arc.h
+ $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/opcode/arc.h
arc-ext.lo: arc-ext.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(BFD_H) $(INCDIR)/symcat.h arc-ext.h $(INCDIR)/libiberty.h
arm-dis.lo: arm-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h arm-opc.h \
$(INCDIR)/coff/internal.h $(BFDDIR)/libcoff.h $(INCDIR)/bfdlink.h \
- opintl.h $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h \
- $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/elf/arm.h \
- $(INCDIR)/elf/reloc-macros.h
+ opintl.h $(INCDIR)/safe-ctype.h $(BFDDIR)/elf-bfd.h \
+ $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
+ $(INCDIR)/elf/arm.h $(INCDIR)/elf/reloc-macros.h
avr-dis.lo: avr-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h opintl.h \
- $(INCDIR)/opcode/avr.h
+ $(INCDIR)/libiberty.h $(INCDIR)/opcode/avr.h
cgen-asm.lo: cgen-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h $(BFD_H) \
$(INCDIR)/symcat.h $(INCDIR)/opcode/cgen.h opintl.h
@@ -991,6 +1058,8 @@ dlx-dis.lo: dlx-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/opcode/dlx.h
dis-buf.lo: dis-buf.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h opintl.h
+dis-init.lo: dis-init.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h
disassemble.lo: disassemble.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h
fr30-asm.lo: fr30-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
@@ -999,36 +1068,38 @@ fr30-asm.lo: fr30-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
fr30-desc.lo: fr30-desc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(BFD_H) $(INCDIR)/symcat.h fr30-desc.h $(INCDIR)/opcode/cgen.h \
- fr30-opc.h opintl.h $(INCDIR)/libiberty.h
+ fr30-opc.h opintl.h $(INCDIR)/libiberty.h $(INCDIR)/xregex.h \
+ $(INCDIR)/xregex2.h
fr30-dis.lo: fr30-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h fr30-desc.h \
- $(INCDIR)/opcode/cgen.h fr30-opc.h opintl.h
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/libiberty.h \
+ fr30-desc.h $(INCDIR)/opcode/cgen.h fr30-opc.h opintl.h
fr30-ibld.lo: fr30-ibld.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h fr30-desc.h \
$(INCDIR)/opcode/cgen.h fr30-opc.h opintl.h $(INCDIR)/safe-ctype.h
fr30-opc.lo: fr30-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(BFD_H) $(INCDIR)/symcat.h fr30-desc.h $(INCDIR)/opcode/cgen.h \
fr30-opc.h $(INCDIR)/libiberty.h
-frv-asm.lo: frv-asm.c sysdep.h config.h $(BFD_H) \
- $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h frv-desc.h \
- $(INCDIR)/opcode/cgen.h frv-opc.h opintl.h
-frv-desc.lo: frv-desc.c sysdep.h config.h $(BFD_H) \
- $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h frv-desc.h \
- $(INCDIR)/opcode/cgen.h frv-opc.h opintl.h
-frv-dis.lo: frv-dis.c sysdep.h config.h $(INCDIR)/dis-asm.h \
- $(BFD_H) $(INCDIR)/ansidecl.h \
- $(INCDIR)/symcat.h frv-desc.h $(INCDIR)/opcode/cgen.h \
- frv-opc.h opintl.h
-frv-ibld.lo: frv-ibld.c sysdep.h config.h $(INCDIR)/dis-asm.h \
- $(BFD_H) $(INCDIR)/ansidecl.h \
- $(INCDIR)/symcat.h frv-desc.h $(INCDIR)/opcode/cgen.h \
- frv-opc.h opintl.h
-frv-opc.lo: frv-opc.c sysdep.h config.h $(BFD_H) \
- $(INCDIR)/ansidecl.h $(INCDIR)/symcat.h frv-desc.h \
- $(INCDIR)/opcode/cgen.h frv-opc.h
+frv-asm.lo: frv-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h frv-desc.h $(INCDIR)/opcode/cgen.h \
+ frv-opc.h opintl.h $(INCDIR)/xregex.h $(INCDIR)/xregex2.h \
+ $(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
+frv-desc.lo: frv-desc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h frv-desc.h $(INCDIR)/opcode/cgen.h \
+ frv-opc.h opintl.h $(INCDIR)/libiberty.h $(INCDIR)/xregex.h \
+ $(INCDIR)/xregex2.h
+frv-dis.lo: frv-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/libiberty.h \
+ frv-desc.h $(INCDIR)/opcode/cgen.h frv-opc.h opintl.h
+frv-ibld.lo: frv-ibld.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h frv-desc.h \
+ $(INCDIR)/opcode/cgen.h frv-opc.h opintl.h $(INCDIR)/safe-ctype.h
+frv-opc.lo: frv-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h frv-desc.h $(INCDIR)/opcode/cgen.h \
+ frv-opc.h $(INCDIR)/libiberty.h $(INCDIR)/elf/frv.h \
+ $(INCDIR)/elf/reloc-macros.h
h8300-dis.lo: h8300-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/opcode/h8300.h $(INCDIR)/dis-asm.h $(BFD_H) \
- $(INCDIR)/symcat.h opintl.h
+ $(INCDIR)/symcat.h opintl.h $(INCDIR)/libiberty.h
h8500-dis.lo: h8500-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
h8500-opc.h $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h \
opintl.h
@@ -1063,21 +1134,57 @@ ia64-opc.lo: ia64-opc.c $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
sysdep.h config.h ia64-asmtab.h $(INCDIR)/opcode/ia64.h \
$(BFD_H) $(INCDIR)/symcat.h ia64-asmtab.c
ia64-gen.lo: ia64-gen.c $(INCDIR)/ansidecl.h $(INCDIR)/libiberty.h \
- $(INCDIR)/safe-ctype.h sysdep.h config.h ia64-opc.h \
- $(INCDIR)/opcode/ia64.h $(BFD_H) $(INCDIR)/symcat.h \
+ $(INCDIR)/safe-ctype.h sysdep.h config.h $(INCDIR)/getopt.h \
+ ia64-opc.h $(INCDIR)/opcode/ia64.h $(BFD_H) $(INCDIR)/symcat.h \
ia64-opc-a.c ia64-opc-i.c ia64-opc-m.c ia64-opc-b.c \
ia64-opc-f.c ia64-opc-x.c ia64-opc-d.c
ia64-asmtab.lo: ia64-asmtab.c
+ip2k-asm.lo: ip2k-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h ip2k-desc.h $(INCDIR)/opcode/cgen.h \
+ ip2k-opc.h opintl.h $(INCDIR)/xregex.h $(INCDIR)/xregex2.h \
+ $(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
+ip2k-desc.lo: ip2k-desc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h ip2k-desc.h $(INCDIR)/opcode/cgen.h \
+ ip2k-opc.h opintl.h $(INCDIR)/libiberty.h $(INCDIR)/xregex.h \
+ $(INCDIR)/xregex2.h
+ip2k-dis.lo: ip2k-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/libiberty.h \
+ ip2k-desc.h $(INCDIR)/opcode/cgen.h ip2k-opc.h opintl.h
+ip2k-ibld.lo: ip2k-ibld.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h ip2k-desc.h \
+ $(INCDIR)/opcode/cgen.h ip2k-opc.h opintl.h $(INCDIR)/safe-ctype.h
+ip2k-opc.lo: ip2k-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h ip2k-desc.h $(INCDIR)/opcode/cgen.h \
+ ip2k-opc.h $(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
+iq2000-asm.lo: iq2000-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h iq2000-desc.h $(INCDIR)/opcode/cgen.h \
+ iq2000-opc.h opintl.h $(INCDIR)/xregex.h $(INCDIR)/xregex2.h \
+ $(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
+iq2000-desc.lo: iq2000-desc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h iq2000-desc.h $(INCDIR)/opcode/cgen.h \
+ iq2000-opc.h opintl.h $(INCDIR)/libiberty.h $(INCDIR)/xregex.h \
+ $(INCDIR)/xregex2.h
+iq2000-dis.lo: iq2000-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/libiberty.h \
+ iq2000-desc.h $(INCDIR)/opcode/cgen.h iq2000-opc.h \
+ opintl.h
+iq2000-ibld.lo: iq2000-ibld.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h iq2000-desc.h \
+ $(INCDIR)/opcode/cgen.h iq2000-opc.h opintl.h $(INCDIR)/safe-ctype.h
+iq2000-opc.lo: iq2000-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(BFD_H) $(INCDIR)/symcat.h iq2000-desc.h $(INCDIR)/opcode/cgen.h \
+ iq2000-opc.h $(INCDIR)/libiberty.h
m32r-asm.lo: m32r-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(BFD_H) $(INCDIR)/symcat.h m32r-desc.h $(INCDIR)/opcode/cgen.h \
m32r-opc.h opintl.h $(INCDIR)/xregex.h $(INCDIR)/xregex2.h \
$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
m32r-desc.lo: m32r-desc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(BFD_H) $(INCDIR)/symcat.h m32r-desc.h $(INCDIR)/opcode/cgen.h \
- m32r-opc.h opintl.h $(INCDIR)/libiberty.h
+ m32r-opc.h opintl.h $(INCDIR)/libiberty.h $(INCDIR)/xregex.h \
+ $(INCDIR)/xregex2.h
m32r-dis.lo: m32r-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h m32r-desc.h \
- $(INCDIR)/opcode/cgen.h m32r-opc.h opintl.h
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/libiberty.h \
+ m32r-desc.h $(INCDIR)/opcode/cgen.h m32r-opc.h opintl.h
m32r-ibld.lo: m32r-ibld.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h m32r-desc.h \
$(INCDIR)/opcode/cgen.h m32r-opc.h opintl.h $(INCDIR)/safe-ctype.h
@@ -1099,14 +1206,14 @@ m68k-opc.lo: m68k-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/opcode/m68k.h
m88k-dis.lo: m88k-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/opcode/m88k.h \
- opintl.h
+ opintl.h $(INCDIR)/libiberty.h
mcore-dis.lo: mcore-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
mcore-opc.h $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h
mips-dis.lo: mips-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/opcode/mips.h \
- opintl.h $(BFDDIR)/elf-bfd.h $(INCDIR)/elf/common.h \
- $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h $(INCDIR)/bfdlink.h \
- $(INCDIR)/elf/mips.h $(INCDIR)/elf/reloc-macros.h
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/libiberty.h \
+ $(INCDIR)/opcode/mips.h opintl.h $(BFDDIR)/elf-bfd.h \
+ $(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
+ $(INCDIR)/bfdlink.h $(INCDIR)/elf/mips.h $(INCDIR)/elf/reloc-macros.h
mips-opc.lo: mips-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/opcode/mips.h
mips16-opc.lo: mips16-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
@@ -1134,10 +1241,12 @@ openrisc-asm.lo: openrisc-asm.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
openrisc-desc.lo: openrisc-desc.c sysdep.h config.h \
$(INCDIR)/ansidecl.h $(BFD_H) $(INCDIR)/symcat.h openrisc-desc.h \
- $(INCDIR)/opcode/cgen.h openrisc-opc.h opintl.h $(INCDIR)/libiberty.h
+ $(INCDIR)/opcode/cgen.h openrisc-opc.h opintl.h $(INCDIR)/libiberty.h \
+ $(INCDIR)/xregex.h $(INCDIR)/xregex2.h
openrisc-dis.lo: openrisc-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
- $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h openrisc-desc.h \
- $(INCDIR)/opcode/cgen.h openrisc-opc.h opintl.h
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/libiberty.h \
+ openrisc-desc.h $(INCDIR)/opcode/cgen.h openrisc-opc.h \
+ opintl.h
openrisc-ibld.lo: openrisc-ibld.c sysdep.h config.h \
$(INCDIR)/ansidecl.h $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h \
openrisc-desc.h $(INCDIR)/opcode/cgen.h openrisc-opc.h \
@@ -1174,7 +1283,8 @@ sh64-dis.lo: sh64-dis.c $(INCDIR)/dis-asm.h $(BFD_H) \
$(INCDIR)/ansidecl.h $(INCDIR)/symcat.h sysdep.h config.h \
sh64-opc.h $(INCDIR)/libiberty.h $(BFDDIR)/elf-bfd.h \
$(INCDIR)/elf/common.h $(INCDIR)/elf/internal.h $(INCDIR)/elf/external.h \
- $(INCDIR)/bfdlink.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h
+ $(INCDIR)/bfdlink.h $(INCDIR)/elf/sh.h $(INCDIR)/elf/reloc-macros.h \
+ $(BFDDIR)/elf32-sh64.h
sh64-opc.lo: sh64-opc.c sh64-opc.h
sparc-dis.lo: sparc-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/opcode/sparc.h $(INCDIR)/dis-asm.h $(BFD_H) \
@@ -1183,6 +1293,8 @@ sparc-opc.lo: sparc-opc.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/opcode/sparc.h
tic30-dis.lo: tic30-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/opcode/tic30.h
+tic4x-dis.lo: tic4x-dis.c $(INCDIR)/libiberty.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/opcode/tic4x.h
tic54x-dis.lo: tic54x-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h $(INCDIR)/opcode/tic54x.h \
$(INCDIR)/coff/tic54x.h $(INCDIR)/coff/ti.h
@@ -1209,11 +1321,12 @@ xstormy16-asm.lo: xstormy16-asm.c sysdep.h config.h \
$(INCDIR)/xregex2.h $(INCDIR)/libiberty.h $(INCDIR)/safe-ctype.h
xstormy16-desc.lo: xstormy16-desc.c sysdep.h config.h \
$(INCDIR)/ansidecl.h $(BFD_H) $(INCDIR)/symcat.h xstormy16-desc.h \
- $(INCDIR)/opcode/cgen.h xstormy16-opc.h opintl.h $(INCDIR)/libiberty.h
+ $(INCDIR)/opcode/cgen.h xstormy16-opc.h opintl.h $(INCDIR)/libiberty.h \
+ $(INCDIR)/xregex.h $(INCDIR)/xregex2.h
xstormy16-dis.lo: xstormy16-dis.c sysdep.h config.h \
$(INCDIR)/ansidecl.h $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h \
- xstormy16-desc.h $(INCDIR)/opcode/cgen.h xstormy16-opc.h \
- opintl.h
+ $(INCDIR)/libiberty.h xstormy16-desc.h $(INCDIR)/opcode/cgen.h \
+ xstormy16-opc.h opintl.h
xstormy16-ibld.lo: xstormy16-ibld.c sysdep.h config.h \
$(INCDIR)/ansidecl.h $(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h \
xstormy16-desc.h $(INCDIR)/opcode/cgen.h xstormy16-opc.h \
@@ -1221,9 +1334,13 @@ xstormy16-ibld.lo: xstormy16-ibld.c sysdep.h config.h \
xstormy16-opc.lo: xstormy16-opc.c sysdep.h config.h \
$(INCDIR)/ansidecl.h $(BFD_H) $(INCDIR)/symcat.h xstormy16-desc.h \
$(INCDIR)/opcode/cgen.h xstormy16-opc.h $(INCDIR)/libiberty.h
+xtensa-dis.lo: xtensa-dis.c $(INCDIR)/xtensa-isa.h \
+ $(INCDIR)/ansidecl.h sysdep.h config.h $(INCDIR)/dis-asm.h \
+ $(BFD_H) $(INCDIR)/symcat.h
z8k-dis.lo: z8k-dis.c sysdep.h config.h $(INCDIR)/ansidecl.h \
$(INCDIR)/dis-asm.h $(BFD_H) $(INCDIR)/symcat.h z8k-opc.h
-z8kgen.lo: z8kgen.c sysdep.h config.h $(INCDIR)/ansidecl.h
+z8kgen.lo: z8kgen.c sysdep.h config.h $(INCDIR)/ansidecl.h \
+ $(INCDIR)/libiberty.h
# IF YOU PUT ANYTHING HERE IT WILL GO AWAY
# Tell versions [3.59,3.63) of GNU make to not export all variables.
diff --git a/contrib/binutils/opcodes/aclocal.m4 b/contrib/binutils/opcodes/aclocal.m4
index 184bf36..92732d3 100644
--- a/contrib/binutils/opcodes/aclocal.m4
+++ b/contrib/binutils/opcodes/aclocal.m4
@@ -35,6 +35,24 @@ AC_SUBST(bfdlibdir)
AC_SUBST(bfdincludedir)
])
+#serial 1
+# This test replaces the one in autoconf.
+# Currently this macro should have the same name as the autoconf macro
+# because gettext's gettext.m4 (distributed in the automake package)
+# still uses it. Otherwise, the use in gettext.m4 makes autoheader
+# give these diagnostics:
+# configure.in:556: AC_TRY_COMPILE was called before AC_ISC_POSIX
+# configure.in:556: AC_TRY_RUN was called before AC_ISC_POSIX
+
+undefine([AC_ISC_POSIX])
+
+AC_DEFUN([AC_ISC_POSIX],
+ [
+ dnl This test replaces the obsolescent AC_ISC_POSIX kludge.
+ AC_CHECK_LIB(cposix, strerror, [LIBS="$LIBS -lcposix"])
+ ]
+)
+
# Do all the work for Automake. This macro actually does too much --
# some checks are only needed if your package does certain things.
# But this isn't really a big deal.
diff --git a/contrib/binutils/opcodes/alpha-opc.c b/contrib/binutils/opcodes/alpha-opc.c
index 6cf7d4c..5371597 100644
--- a/contrib/binutils/opcodes/alpha-opc.c
+++ b/contrib/binutils/opcodes/alpha-opc.c
@@ -1,5 +1,5 @@
/* alpha-opc.c -- Alpha AXP opcode list
- Copyright 1996, 1997, 1998, 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1996, 1997, 1998, 1999, 2000, 2003 Free Software Foundation, Inc.
Contributed by Richard Henderson <rth@cygnus.com>,
patterned after the PPC opcode handling written by Ian Lance Taylor.
@@ -214,7 +214,6 @@ const unsigned alpha_num_operands = sizeof(alpha_operands)/sizeof(*alpha_operand
the RA field into the RB field, and the extraction function just
checks that the fields are the same. */
-/*ARGSUSED*/
static unsigned
insert_rba(insn, value, errmsg)
unsigned insn;
@@ -238,7 +237,6 @@ extract_rba(insn, invalid)
/* The same for the RC field */
-/*ARGSUSED*/
static unsigned
insert_rca(insn, value, errmsg)
unsigned insn;
@@ -262,7 +260,6 @@ extract_rca(insn, invalid)
/* Fake arguments in which the registers must be set to ZERO */
-/*ARGSUSED*/
static unsigned
insert_za(insn, value, errmsg)
unsigned insn;
@@ -282,7 +279,6 @@ extract_za(insn, invalid)
return 0;
}
-/*ARGSUSED*/
static unsigned
insert_zb(insn, value, errmsg)
unsigned insn;
@@ -302,7 +298,6 @@ extract_zb(insn, invalid)
return 0;
}
-/*ARGSUSED*/
static unsigned
insert_zc(insn, value, errmsg)
unsigned insn;
@@ -336,7 +331,6 @@ insert_bdisp(insn, value, errmsg)
return insn | ((value / 4) & 0x1FFFFF);
}
-/*ARGSUSED*/
static int
extract_bdisp(insn, invalid)
unsigned insn;
@@ -359,7 +353,6 @@ insert_jhint(insn, value, errmsg)
return insn | ((value / 4) & 0x3FFF);
}
-/*ARGSUSED*/
static int
extract_jhint(insn, invalid)
unsigned insn;
@@ -381,7 +374,6 @@ insert_ev6hwjhint(insn, value, errmsg)
return insn | ((value / 4) & 0x1FFF);
}
-/*ARGSUSED*/
static int
extract_ev6hwjhint(insn, invalid)
unsigned insn;
@@ -533,9 +525,13 @@ const struct alpha_opcode alpha_opcodes[] = {
{ "halt", SPCD(0x00,0x0000), BASE, ARG_NONE },
{ "draina", SPCD(0x00,0x0002), BASE, ARG_NONE },
{ "bpt", SPCD(0x00,0x0080), BASE, ARG_NONE },
+ { "bugchk", SPCD(0x00,0x0081), BASE, ARG_NONE },
{ "callsys", SPCD(0x00,0x0083), BASE, ARG_NONE },
{ "chmk", SPCD(0x00,0x0083), BASE, ARG_NONE },
{ "imb", SPCD(0x00,0x0086), BASE, ARG_NONE },
+ { "rduniq", SPCD(0x00,0x009e), BASE, ARG_NONE },
+ { "wruniq", SPCD(0x00,0x009f), BASE, ARG_NONE },
+ { "gentrap", SPCD(0x00,0x00aa), BASE, ARG_NONE },
{ "call_pal", PCD(0x00), BASE, ARG_PCD },
{ "pal", PCD(0x00), BASE, ARG_PCD }, /* alias */
@@ -1101,7 +1097,8 @@ const struct alpha_opcode alpha_opcodes[] = {
{ "wmb", MFC(0x18,0x4400), BASE, ARG_NONE },
{ "fetch", MFC(0x18,0x8000), BASE, { ZA, PRB } },
{ "fetch_m", MFC(0x18,0xA000), BASE, { ZA, PRB } },
- { "rpcc", MFC(0x18,0xC000), BASE, { RA } },
+ { "rpcc", MFC(0x18,0xC000), BASE, { RA, ZB } },
+ { "rpcc", MFC(0x18,0xC000), BASE, { RA, RB } }, /* ev6 una */
{ "rc", MFC(0x18,0xE000), BASE, { RA } },
{ "ecb", MFC(0x18,0xE800), BASE, { ZA, PRB } }, /* ev56 una */
{ "rs", MFC(0x18,0xF000), BASE, { RA } },
diff --git a/contrib/binutils/opcodes/arc-opc.c b/contrib/binutils/opcodes/arc-opc.c
index b7afb86..614fff0 100644
--- a/contrib/binutils/opcodes/arc-opc.c
+++ b/contrib/binutils/opcodes/arc-opc.c
@@ -20,6 +20,7 @@
#include "sysdep.h"
#include <stdio.h>
#include "ansidecl.h"
+#include "bfd.h"
#include "opcode/arc.h"
#define INSERT_FN(fn) \
@@ -65,6 +66,9 @@ enum operand {OP_NONE,OP_REG,OP_SHIMM,OP_LIMM};
enum operand ls_operand[OPERANDS];
+struct arc_opcode *arc_ext_opcodes;
+struct arc_ext_operand_value *arc_ext_operands;
+
#define LS_VALUE 0
#define LS_DEST 0
#define LS_BASE 1
@@ -513,7 +517,7 @@ arc_get_opcode_mach (bfd_mach, big_p)
ARC_MACH_7,
ARC_MACH_8
};
- return mach_type_map[bfd_mach] | (big_p ? ARC_MACH_BIG : 0);
+ return mach_type_map[bfd_mach - bfd_mach_arc_5] | (big_p ? ARC_MACH_BIG : 0);
}
/* Initialize any tables that need it.
diff --git a/contrib/binutils/opcodes/arm-dis.c b/contrib/binutils/opcodes/arm-dis.c
index f3785f2..e918daf 100644
--- a/contrib/binutils/opcodes/arm-dis.c
+++ b/contrib/binutils/opcodes/arm-dis.c
@@ -1,24 +1,24 @@
/* Instruction printing code for the ARM
- Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002
+ Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
Contributed by Richard Earnshaw (rwe@pegasus.esprit.ec.org)
Modification by James G. Smith (jsmith@cygnus.co.uk)
-This file is part of libopcodes.
+ This file is part of libopcodes.
-This program is free software; you can redistribute it and/or modify it under
-the terms of the GNU General Public License as published by the Free
-Software Foundation; either version 2 of the License, or (at your option)
-any later version.
+ This program is free software; you can redistribute it and/or modify it under
+ the terms of the GNU General Public License as published by the Free
+ Software Foundation; either version 2 of the License, or (at your option)
+ any later version.
-This program is distributed in the hope that it will be useful, but WITHOUT
-ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
-FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
-more details.
+ This program is distributed in the hope that it will be useful, but WITHOUT
+ ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
+ more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "sysdep.h"
#include "dis-asm.h"
@@ -27,6 +27,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "coff/internal.h"
#include "libcoff.h"
#include "opintl.h"
+#include "safe-ctype.h"
/* FIXME: This shouldn't be done here. */
#include "elf-bfd.h"
@@ -70,7 +71,21 @@ static arm_regname regnames[] =
{ "atpcs", "Select register names used in the ATPCS",
{ "a1", "a2", "a3", "a4", "v1", "v2", "v3", "v4", "v5", "v6", "v7", "v8", "IP", "SP", "LR", "PC" }},
{ "special-atpcs", "Select special register names used in the ATPCS",
- { "a1", "a2", "a3", "a4", "v1", "v2", "v3", "WR", "v5", "SB", "SL", "FP", "IP", "SP", "LR", "PC" }}
+ { "a1", "a2", "a3", "a4", "v1", "v2", "v3", "WR", "v5", "SB", "SL", "FP", "IP", "SP", "LR", "PC" }},
+ { "iwmmxt_regnames", "Select register names used on the Intel Wireless MMX technology coprocessor",
+ { "wr0", "wr1", "wr2", "wr3", "wr4", "wr5", "wr6", "wr7", "wr8", "wr9", "wr10", "wr11", "wr12", "wr13", "wr14", "wr15"}},
+ { "iwmmxt_Cregnames", "Select control register names used on the Intel Wireless MMX technology coprocessor",
+ {"wcid", "wcon", "wcssf", "wcasf", "reserved", "reserved", "reserved", "reserved", "wcgr0", "wcgr1", "wcgr2", "wcgr3", "reserved", "reserved", "reserved", "reserved"}}
+};
+
+static char * iwmmxt_wwnames[] =
+{"b", "h", "w", "d"};
+
+static char * iwmmxt_wwssnames[] =
+{"b", "bus", "b", "bss",
+ "h", "hus", "h", "hss",
+ "w", "wus", "w", "wss",
+ "d", "dus", "d", "dss"
};
/* Default to GCC register name set. */
@@ -79,25 +94,34 @@ static unsigned int regname_selected = 1;
#define NUM_ARM_REGNAMES NUM_ELEM (regnames)
#define arm_regnames regnames[regname_selected].reg_names
-static boolean force_thumb = false;
+static bfd_boolean force_thumb = FALSE;
static char * arm_fp_const[] =
{"0.0", "1.0", "2.0", "3.0", "4.0", "5.0", "0.5", "10.0"};
-static char * arm_shift[] =
+static char * arm_shift[] =
{"lsl", "lsr", "asr", "ror"};
/* Forward declarations. */
-static void arm_decode_shift PARAMS ((long, fprintf_ftype, void *));
-static int print_insn_arm PARAMS ((bfd_vma, struct disassemble_info *, long));
-static int print_insn_thumb PARAMS ((bfd_vma, struct disassemble_info *, long));
-static void parse_disassembler_options PARAMS ((char *));
-static int print_insn PARAMS ((bfd_vma, struct disassemble_info *, boolean));
-int get_arm_regname_num_options (void);
-int set_arm_regname_option (int option);
-int get_arm_regnames (int option, const char **setname,
- const char **setdescription,
- const char ***register_names);
+static void arm_decode_shift
+ PARAMS ((long, fprintf_ftype, void *));
+static int print_insn_arm
+ PARAMS ((bfd_vma, struct disassemble_info *, long));
+static int print_insn_thumb
+ PARAMS ((bfd_vma, struct disassemble_info *, long));
+static void parse_disassembler_options
+ PARAMS ((char *));
+static int print_insn
+ PARAMS ((bfd_vma, struct disassemble_info *, bfd_boolean));
+static int set_iwmmxt_regnames
+ PARAMS ((void));
+
+int get_arm_regname_num_options
+ PARAMS ((void));
+int set_arm_regname_option
+ PARAMS ((int));
+int get_arm_regnames
+ PARAMS ((int, const char **, const char **, const char ***));
/* Functions. */
int
@@ -135,14 +159,14 @@ arm_decode_shift (given, func, stream)
void * stream;
{
func (stream, "%s", arm_regnames[given & 0xf]);
-
+
if ((given & 0xff0) != 0)
{
if ((given & 0x10) == 0)
{
int amount = (given & 0xf80) >> 7;
int shift = (given & 0x60) >> 5;
-
+
if (amount == 0)
{
if (shift == 3)
@@ -150,10 +174,10 @@ arm_decode_shift (given, func, stream)
func (stream, ", rrx");
return;
}
-
+
amount = 32;
}
-
+
func (stream, ", %s #%d", arm_shift[shift], amount);
}
else
@@ -162,25 +186,49 @@ arm_decode_shift (given, func, stream)
}
}
+static int
+set_iwmmxt_regnames ()
+{
+ const char * setname;
+ const char * setdesc;
+ const char ** regnames;
+ int iwmmxt_regnames = 0;
+ int num_regnames = get_arm_regname_num_options ();
+
+ get_arm_regnames (iwmmxt_regnames, &setname,
+ &setdesc, &regnames);
+ while ((strcmp ("iwmmxt_regnames", setname))
+ && (iwmmxt_regnames < num_regnames))
+ get_arm_regnames (++iwmmxt_regnames, &setname, &setdesc, &regnames);
+
+ return iwmmxt_regnames;
+}
+
/* Print one instruction from PC on INFO->STREAM.
Return the size of the instruction (always 4 on ARM). */
static int
print_insn_arm (pc, info, given)
- bfd_vma pc;
- struct disassemble_info * info;
- long given;
+ bfd_vma pc;
+ struct disassemble_info *info;
+ long given;
{
- struct arm_opcode * insn;
- void * stream = info->stream;
- fprintf_ftype func = info->fprintf_func;
+ const struct arm_opcode *insn;
+ void *stream = info->stream;
+ fprintf_ftype func = info->fprintf_func;
+ static int iwmmxt_regnames = 0;
for (insn = arm_opcodes; insn->assembler; insn++)
{
+ if (insn->value == FIRST_IWMMXT_INSN
+ && info->mach != bfd_mach_arm_XScale
+ && info->mach != bfd_mach_arm_iWMMXt)
+ insn = insn + IWMMXT_INSN_COUNT;
+
if ((given & insn->mask) == insn->value)
{
char * c;
-
+
for (c = insn->assembler; *c; c++)
{
if (*c == '%')
@@ -196,14 +244,14 @@ print_insn_arm (pc, info, given)
&& ((given & 0x02000000) == 0))
{
int offset = given & 0xfff;
-
+
func (stream, "[pc");
-
+
if (given & 0x01000000)
{
if ((given & 0x00800000) == 0)
offset = - offset;
-
+
/* Pre-indexed. */
func (stream, ", #%d]", offset);
@@ -224,13 +272,13 @@ print_insn_arm (pc, info, given)
/* ie ignore the offset. */
offset = pc + 8;
}
-
+
func (stream, "\t; ");
info->print_address_func (offset, info);
}
else
{
- func (stream, "[%s",
+ func (stream, "[%s",
arm_regnames[(given >> 16) & 0xf]);
if ((given & 0x01000000) != 0)
{
@@ -238,7 +286,7 @@ print_insn_arm (pc, info, given)
{
int offset = given & 0xfff;
if (offset)
- func (stream, ", %s#%d",
+ func (stream, ", #%s%d",
(((given & 0x00800000) == 0)
? "-" : ""), offset);
}
@@ -250,7 +298,7 @@ print_insn_arm (pc, info, given)
arm_decode_shift (given, func, stream);
}
- func (stream, "]%s",
+ func (stream, "]%s",
((given & 0x00200000) != 0) ? "!" : "");
}
else
@@ -259,16 +307,16 @@ print_insn_arm (pc, info, given)
{
int offset = given & 0xfff;
if (offset)
- func (stream, "], %s#%d",
+ func (stream, "], #%s%d",
(((given & 0x00800000) == 0)
? "-" : ""), offset);
- else
+ else
func (stream, "]");
}
else
{
func (stream, "], %s",
- (((given & 0x00800000) == 0)
+ (((given & 0x00800000) == 0)
? "-" : ""));
arm_decode_shift (given, func, stream);
}
@@ -281,18 +329,18 @@ print_insn_arm (pc, info, given)
{
/* PC relative with immediate offset. */
int offset = ((given & 0xf00) >> 4) | (given & 0xf);
-
+
if ((given & 0x00800000) == 0)
offset = -offset;
-
+
func (stream, "[pc, #%d]\t; ", offset);
-
+
(*info->print_address_func)
(offset + pc + 8, info);
}
else
{
- func (stream, "[%s",
+ func (stream, "[%s",
arm_regnames[(given >> 16) & 0xf]);
if ((given & 0x01000000) != 0)
{
@@ -302,7 +350,7 @@ print_insn_arm (pc, info, given)
/* Immediate. */
int offset = ((given & 0xf00) >> 4) | (given & 0xf);
if (offset)
- func (stream, ", %s#%d",
+ func (stream, ", #%s%d",
(((given & 0x00800000) == 0)
? "-" : ""), offset);
}
@@ -315,7 +363,7 @@ print_insn_arm (pc, info, given)
arm_regnames[given & 0xf]);
}
- func (stream, "]%s",
+ func (stream, "]%s",
((given & 0x00200000) != 0) ? "!" : "");
}
else
@@ -326,10 +374,10 @@ print_insn_arm (pc, info, given)
/* Immediate. */
int offset = ((given & 0xf00) >> 4) | (given & 0xf);
if (offset)
- func (stream, "], %s#%d",
+ func (stream, "], #%s%d",
(((given & 0x00800000) == 0)
? "-" : ""), offset);
- else
+ else
func (stream, "]");
}
else
@@ -343,7 +391,7 @@ print_insn_arm (pc, info, given)
}
}
break;
-
+
case 'b':
(*info->print_address_func)
(BDISP (given) * 4 + pc + 8, info);
@@ -397,11 +445,13 @@ print_insn_arm (pc, info, given)
case 'A':
func (stream, "[%s", arm_regnames [(given >> 16) & 0xf]);
- if ((given & 0x01000000) != 0)
+
+ if ((given & (1 << 24)) != 0)
{
int offset = given & 0xff;
+
if (offset)
- func (stream, ", %s#%d]%s",
+ func (stream, ", #%s%d]%s",
((given & 0x00800000) == 0 ? "-" : ""),
offset * 4,
((given & 0x00200000) != 0 ? "!" : ""));
@@ -411,12 +461,18 @@ print_insn_arm (pc, info, given)
else
{
int offset = given & 0xff;
- if (offset)
- func (stream, "], %s#%d",
- ((given & 0x00800000) == 0 ? "-" : ""),
- offset * 4);
+
+ func (stream, "]");
+
+ if (given & (1 << 21))
+ {
+ if (offset)
+ func (stream, ", #%s%d",
+ ((given & 0x00800000) == 0 ? "-" : ""),
+ offset * 4);
+ }
else
- func (stream, "]");
+ func (stream, ", {%d}", offset);
}
break;
@@ -425,7 +481,7 @@ print_insn_arm (pc, info, given)
{
bfd_vma address;
bfd_vma offset = 0;
-
+
if (given & 0x00800000)
/* Is signed, hi bits should be ones. */
offset = (-1) ^ 0x00ffffff;
@@ -434,7 +490,7 @@ print_insn_arm (pc, info, given)
offset += given & 0x00ffffff;
offset <<= 2;
address = offset + pc + 8;
-
+
if (given & 0x01000000)
/* H bit allows addressing to 2-byte boundaries. */
address += 2;
@@ -490,7 +546,7 @@ print_insn_arm (pc, info, given)
func (stream, "3");
}
break;
-
+
case 'P':
switch (given & 0x00080080)
{
@@ -542,7 +598,7 @@ print_insn_arm (pc, info, given)
}
break;
- case '0': case '1': case '2': case '3': case '4':
+ case '0': case '1': case '2': case '3': case '4':
case '5': case '6': case '7': case '8': case '9':
{
int bitstart = *c++ - '0';
@@ -554,44 +610,54 @@ print_insn_arm (pc, info, given)
{
case '-':
c++;
-
+
while (*c >= '0' && *c <= '9')
bitend = (bitend * 10) + *c++ - '0';
-
+
if (!bitend)
abort ();
-
+
switch (*c)
{
case 'r':
{
long reg;
-
+
reg = given >> bitstart;
reg &= (2 << (bitend - bitstart)) - 1;
-
+
func (stream, "%s", arm_regnames[reg]);
}
break;
case 'd':
{
long reg;
-
+
reg = given >> bitstart;
reg &= (2 << (bitend - bitstart)) - 1;
-
+
func (stream, "%d", reg);
}
break;
- case 'x':
+ case 'W':
{
long reg;
reg = given >> bitstart;
reg &= (2 << (bitend - bitstart)) - 1;
+ func (stream, "%d", reg + 1);
+ }
+ break;
+ case 'x':
+ {
+ long reg;
+
+ reg = given >> bitstart;
+ reg &= (2 << (bitend - bitstart)) - 1;
+
func (stream, "0x%08x", reg);
-
+
/* Some SWI instructions have special
meanings. */
if ((given & 0x0fffffff) == 0x0FF00000)
@@ -603,20 +669,20 @@ print_insn_arm (pc, info, given)
case 'X':
{
long reg;
-
+
reg = given >> bitstart;
reg &= (2 << (bitend - bitstart)) - 1;
-
+
func (stream, "%01x", reg & 0xf);
}
break;
case 'f':
{
long reg;
-
+
reg = given >> bitstart;
reg &= (2 << (bitend - bitstart)) - 1;
-
+
if (reg > 7)
func (stream, "#%s",
arm_fp_const[reg & 7]);
@@ -624,6 +690,63 @@ print_insn_arm (pc, info, given)
func (stream, "f%d", reg);
}
break;
+
+ case 'w':
+ {
+ long reg;
+
+ if (bitstart != bitend)
+ {
+ reg = given >> bitstart;
+ reg &= (2 << (bitend - bitstart)) - 1;
+ if (bitend - bitstart == 1)
+ func (stream, "%s", iwmmxt_wwnames[reg]);
+ else
+ func (stream, "%s", iwmmxt_wwssnames[reg]);
+ }
+ else
+ {
+ reg = (((given >> 8) & 0x1) |
+ ((given >> 22) & 0x1));
+ func (stream, "%s", iwmmxt_wwnames[reg]);
+ }
+ }
+ break;
+
+ case 'g':
+ {
+ long reg;
+ int current_regnames;
+
+ if (! iwmmxt_regnames)
+ iwmmxt_regnames = set_iwmmxt_regnames ();
+ current_regnames = set_arm_regname_option
+ (iwmmxt_regnames);
+
+ reg = given >> bitstart;
+ reg &= (2 << (bitend - bitstart)) - 1;
+ func (stream, "%s", arm_regnames[reg]);
+ set_arm_regname_option (current_regnames);
+ }
+ break;
+
+ case 'G':
+ {
+ long reg;
+ int current_regnames;
+
+ if (! iwmmxt_regnames)
+ iwmmxt_regnames = set_iwmmxt_regnames ();
+ current_regnames = set_arm_regname_option
+ (iwmmxt_regnames + 1);
+
+ reg = given >> bitstart;
+ reg &= (2 << (bitend - bitstart)) - 1;
+ func (stream, "%s", arm_regnames[reg]);
+ set_arm_regname_option (current_regnames);
+ }
+ break;
+
default:
abort ();
}
@@ -677,7 +800,7 @@ print_insn_arm (pc, info, given)
}
break;
-
+
default:
abort ();
}
@@ -729,6 +852,54 @@ print_insn_arm (pc, info, given)
}
break;
+ case 'L':
+ switch (given & 0x00400100)
+ {
+ case 0x00000000: func (stream, "b"); break;
+ case 0x00400000: func (stream, "h"); break;
+ case 0x00000100: func (stream, "w"); break;
+ case 0x00400100: func (stream, "d"); break;
+ default:
+ break;
+ }
+ break;
+
+ case 'Z':
+ {
+ int value;
+ /* given (20, 23) | given (0, 3) */
+ value = ((given >> 16) & 0xf0) | (given & 0xf);
+ func (stream, "%d", value);
+ }
+ break;
+
+ case 'l':
+ /* This is like the 'A' operator, except that if
+ the width field "M" is zero, then the offset is
+ *not* multiplied by four. */
+ {
+ int offset = given & 0xff;
+ int multiplier = (given & 0x00000100) ? 4 : 1;
+
+ func (stream, "[%s", arm_regnames [(given >> 16) & 0xf]);
+
+ if (offset)
+ {
+ if ((given & 0x01000000) != 0)
+ func (stream, ", #%s%d]%s",
+ ((given & 0x00800000) == 0 ? "-" : ""),
+ offset * multiplier,
+ ((given & 0x00200000) != 0 ? "!" : ""));
+ else
+ func (stream, "], #%s%d",
+ ((given & 0x00800000) == 0 ? "-" : ""),
+ offset * multiplier);
+ }
+ else
+ func (stream, "]");
+ }
+ break;
+
default:
abort ();
}
@@ -748,13 +919,13 @@ print_insn_arm (pc, info, given)
static int
print_insn_thumb (pc, info, given)
- bfd_vma pc;
- struct disassemble_info * info;
- long given;
+ bfd_vma pc;
+ struct disassemble_info *info;
+ long given;
{
- struct thumb_opcode * insn;
- void * stream = info->stream;
- fprintf_ftype func = info->fprintf_func;
+ const struct thumb_opcode *insn;
+ void *stream = info->stream;
+ fprintf_ftype func = info->fprintf_func;
for (insn = thumb_opcodes; insn->assembler; insn++)
{
@@ -766,7 +937,7 @@ print_insn_thumb (pc, info, given)
if (!*c) /* Check for empty (not NULL) assembler string. */
{
long offset;
-
+
info->bytes_per_chunk = 4;
info->bytes_per_line = 4;
@@ -788,16 +959,16 @@ print_insn_thumb (pc, info, given)
{
info->bytes_per_chunk = 2;
info->bytes_per_line = 4;
-
+
given &= 0xffff;
-
+
for (; *c; c++)
{
if (*c == '%')
{
int domaskpc = 0;
int domasklr = 0;
-
+
switch (*++c)
{
case '%':
@@ -807,11 +978,11 @@ print_insn_thumb (pc, info, given)
case 'S':
{
long reg;
-
+
reg = (given >> 3) & 0x7;
if (given & (1 << 6))
reg += 8;
-
+
func (stream, "%s", arm_regnames[reg]);
}
break;
@@ -819,11 +990,11 @@ print_insn_thumb (pc, info, given)
case 'D':
{
long reg;
-
+
reg = given & 0x7;
if (given & (1 << 7))
reg += 8;
-
+
func (stream, "%s", arm_regnames[reg]);
}
break;
@@ -845,9 +1016,9 @@ print_insn_thumb (pc, info, given)
{
int started = 0;
int reg;
-
+
func (stream, "{");
-
+
/* It would be nice if we could spot
ranges, and generate the rS-rE format: */
for (reg = 0; (reg < 8); reg++)
@@ -879,12 +1050,12 @@ print_insn_thumb (pc, info, given)
break;
- case '0': case '1': case '2': case '3': case '4':
+ case '0': case '1': case '2': case '3': case '4':
case '5': case '6': case '7': case '8': case '9':
{
int bitstart = *c++ - '0';
int bitend = 0;
-
+
while (*c >= '0' && *c <= '9')
bitstart = (bitstart * 10) + *c++ - '0';
@@ -893,7 +1064,7 @@ print_insn_thumb (pc, info, given)
case '-':
{
long reg;
-
+
c++;
while (*c >= '0' && *c <= '9')
bitend = (bitend * 10) + *c++ - '0';
@@ -984,6 +1155,23 @@ print_insn_thumb (pc, info, given)
abort ();
}
+/* Disallow mapping symbols ($a, $b, $d, $t etc) from
+ being displayed in symbol relative addresses. */
+
+bfd_boolean
+arm_symbol_is_valid (asymbol * sym,
+ struct disassemble_info * info ATTRIBUTE_UNUSED)
+{
+ const char * name;
+
+ if (sym == NULL)
+ return FALSE;
+
+ name = bfd_asymbol_name (sym);
+
+ return (name && *name != '$');
+}
+
/* Parse an individual disassembler option. */
void
@@ -992,59 +1180,56 @@ parse_arm_disassembler_option (option)
{
if (option == NULL)
return;
-
+
if (strneq (option, "reg-names-", 10))
{
int i;
-
+
option += 10;
for (i = NUM_ARM_REGNAMES; i--;)
- if (streq (option, regnames[i].name))
+ if (strneq (option, regnames[i].name, strlen (regnames[i].name)))
{
regname_selected = i;
break;
}
-
+
if (i < 0)
+ /* XXX - should break 'option' at following delimiter. */
fprintf (stderr, _("Unrecognised register name set: %s\n"), option);
}
- else if (streq (option, "force-thumb"))
+ else if (strneq (option, "force-thumb", 11))
force_thumb = 1;
- else if (streq (option, "no-force-thumb"))
+ else if (strneq (option, "no-force-thumb", 14))
force_thumb = 0;
else
+ /* XXX - should break 'option' at following delimiter. */
fprintf (stderr, _("Unrecognised disassembler option: %s\n"), option);
-
+
return;
}
-/* Parse the string of disassembler options, spliting it at whitespaces. */
+/* Parse the string of disassembler options, spliting it at whitespaces
+ or commas. (Whitespace separators supported for backwards compatibility). */
static void
parse_disassembler_options (options)
char * options;
{
- char * space;
-
if (options == NULL)
return;
- do
+ while (*options)
{
- space = strchr (options, ' ');
-
- if (space)
- {
- * space = '\0';
- parse_arm_disassembler_option (options);
- * space = ' ';
- options = space + 1;
- }
- else
- parse_arm_disassembler_option (options);
+ parse_arm_disassembler_option (options);
+
+ /* Skip forward to next seperator. */
+ while ((*options) && (! ISSPACE (*options)) && (*options != ','))
+ ++ options;
+ /* Skip forward past seperators. */
+ while (ISSPACE (*options) || (*options == ','))
+ ++ options;
}
- while (space);
}
/* NOTE: There are no checks in these routines that
@@ -1054,7 +1239,7 @@ static int
print_insn (pc, info, little)
bfd_vma pc;
struct disassemble_info * info;
- boolean little;
+ bfd_boolean little;
{
unsigned char b[4];
long given;
@@ -1064,19 +1249,19 @@ print_insn (pc, info, little)
if (info->disassembler_options)
{
parse_disassembler_options (info->disassembler_options);
-
+
/* To avoid repeated parsing of these options, we remove them here. */
info->disassembler_options = NULL;
}
-
+
is_thumb = force_thumb;
-
+
if (!is_thumb && info->symbols != NULL)
{
if (bfd_asymbol_flavour (*info->symbols) == bfd_target_coff_flavour)
{
coff_symbol_type * cs;
-
+
cs = coffsymbol (*info->symbols);
is_thumb = ( cs->native->u.syment.n_sclass == C_THUMBEXT
|| cs->native->u.syment.n_sclass == C_THUMBSTAT
@@ -1088,14 +1273,14 @@ print_insn (pc, info, little)
{
elf_symbol_type * es;
unsigned int type;
-
+
es = *(elf_symbol_type **)(info->symbols);
type = ELF_ST_TYPE (es->internal_elf_sym.st_info);
-
+
is_thumb = (type == STT_ARM_TFUNC) || (type == STT_ARM_16BIT);
}
}
-
+
info->bytes_per_chunk = 4;
info->display_endian = little ? BFD_ENDIAN_LITTLE : BFD_ENDIAN_BIG;
@@ -1105,17 +1290,17 @@ print_insn (pc, info, little)
if (status != 0 && is_thumb)
{
info->bytes_per_chunk = 2;
-
+
status = info->read_memory_func (pc, (bfd_byte *) b, 2, info);
b[3] = b[2] = 0;
}
-
+
if (status != 0)
{
info->memory_error_func (status, pc, info);
return -1;
}
-
+
given = (b[0]) | (b[1] << 8) | (b[2] << 16) | (b[3] << 24);
}
else
@@ -1127,13 +1312,13 @@ print_insn (pc, info, little)
info->memory_error_func (status, pc, info);
return -1;
}
-
+
if (is_thumb)
{
if (pc & 0x2)
{
given = (b[2] << 8) | b[3];
-
+
status = info->read_memory_func
((pc + 4) & ~ 0x3, (bfd_byte *) b, 4, info);
if (status != 0)
@@ -1141,7 +1326,7 @@ print_insn (pc, info, little)
info->memory_error_func (status, pc + 4, info);
return -1;
}
-
+
given |= (b[0] << 24) | (b[1] << 16);
}
else
@@ -1150,7 +1335,7 @@ print_insn (pc, info, little)
else
given = (b[0] << 24) | (b[1] << 16) | (b[2] << 8) | (b[3]);
}
-
+
if (info->flags & INSN_HAS_RELOC)
/* If the instruction has a reloc associated with it, then
the offset field in the instruction will actually be the
@@ -1158,7 +1343,7 @@ print_insn (pc, info, little)
In such cases, we can ignore the pc when computing
addresses, since the addend is not currently pc-relative. */
pc = 0;
-
+
if (is_thumb)
status = print_insn_thumb (pc, info, given);
else
@@ -1172,7 +1357,7 @@ print_insn_big_arm (pc, info)
bfd_vma pc;
struct disassemble_info * info;
{
- return print_insn (pc, info, false);
+ return print_insn (pc, info, FALSE);
}
int
@@ -1180,7 +1365,7 @@ print_insn_little_arm (pc, info)
bfd_vma pc;
struct disassemble_info * info;
{
- return print_insn (pc, info, true);
+ return print_insn (pc, info, TRUE);
}
void
@@ -1191,7 +1376,7 @@ print_arm_disassembler_options (FILE * stream)
fprintf (stream, _("\n\
The following ARM specific disassembler options are supported for use with\n\
the -M switch:\n"));
-
+
for (i = NUM_ARM_REGNAMES; i--;)
fprintf (stream, " reg-names-%s %*c%s\n",
regnames[i].name,
diff --git a/contrib/binutils/opcodes/arm-opc.h b/contrib/binutils/opcodes/arm-opc.h
index 85f611d..574bc1f 100644
--- a/contrib/binutils/opcodes/arm-opc.h
+++ b/contrib/binutils/opcodes/arm-opc.h
@@ -1,6 +1,6 @@
/* Opcode table for the ARM.
- Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000
+ Copyright 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2003
Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
@@ -35,6 +35,7 @@ struct thumb_opcode
%<bitfield>d print the bitfield in decimal
%<bitfield>x print the bitfield in hex
%<bitfield>X print the bitfield as 1 hex digit without leading "0x"
+ %<bitfield>w print the bitfield plus one in decimal
%<bitfield>r print as an ARM register
%<bitfield>f print a floating point constant if >7 else a
floating point register
@@ -60,6 +61,13 @@ struct thumb_opcode
%m print register mask for ldm/stm instruction
%C print the PSR sub type.
%F print the COUNT field of a LFM/SFM instruction.
+IWMMXT specific format options:
+ %<bitfield>g print as an iWMMXt 64-bit register
+ %<bitfield>G print as an iWMMXt general purpose or control register
+ %<bitfield>w print as an iWMMXt width field - [bhwd]ss/us
+ %Z print the Immediate of a WSHUFH instruction.
+ %L print as an iWMMXt N/M width field.
+ %l like 'A' except use byte offsets for 'B' & 'H' versions
Thumb specific format options:
%D print Thumb register (bits 0..2 as high number if bit 7 set)
%S print Thumb register (bits 3..5 as high number if bit 6 set)
@@ -79,7 +87,7 @@ Thumb specific format options:
/* Note: There is a partial ordering in this table - it must be searched from
the top to obtain a correct match. */
-static struct arm_opcode arm_opcodes[] =
+static const struct arm_opcode arm_opcodes[] =
{
/* ARM instructions. */
{0xe1a00000, 0xffffffff, "nop\t\t\t(mov r0,r0)"},
@@ -90,6 +98,132 @@ static struct arm_opcode arm_opcodes[] =
{0x00800090, 0x0fa000f0, "%22?sumull%c%20's\t%12-15r, %16-19r, %0-3r, %8-11r"},
{0x00a00090, 0x0fa000f0, "%22?sumlal%c%20's\t%12-15r, %16-19r, %0-3r, %8-11r"},
+ /* ARM V6 instructions. */
+ {0xfc500000, 0xfff00000, "mrrc2\t%8-11d, %4-7d, %12-15r, %16-19r, cr%0-3d"},
+ {0xfc400000, 0xfff00000, "mcrr2\t%8-11d, %4-7d, %12-15r, %16-19r, cr%0-3d"},
+ {0xf1080000, 0xfffdfe3f, "cpsie\t%8'a%7'i%6'f"},
+ {0xf1080000, 0xfffdfe20, "cpsie\t%8'a%7'i%6'f,#%0-4d"},
+ {0xf10C0000, 0xfffdfe3f, "cpsid\t%8'a%7'i%6'f"},
+ {0xf10C0000, 0xfffdfe20, "cpsid\t%8'a%7'i%6'f,#%0-4d"},
+ {0xf1000000, 0xfff1fe20, "cps\t#%0-4d"},
+ {0x06800010, 0x0ff00ff0, "pkhbt%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06800010, 0x0ff00070, "pkhbt%c\t%12-15r, %16-19r, %0-3r, LSL #%7-11d"},
+ {0x06800050, 0x0ff00ff0, "pkhtb%c\t%12-15r, %16-19r, %0-3r, ASR #32"},
+ {0x06800050, 0x0ff00070, "pkhtb%c\t%12-15r, %16-19r, %0-3r, ASR #%7-11d"},
+ {0x01900f9f, 0x0ff00fff, "ldrex%c\tr%12-15d, [%16-19r]"},
+ {0x06200f10, 0x0ff00ff0, "qadd16%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06200f90, 0x0ff00ff0, "qadd8%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06200f30, 0x0ff00ff0, "qaddsubx%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06200f70, 0x0ff00ff0, "qsub16%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06200ff0, 0x0ff00ff0, "qsub8%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06200f50, 0x0ff00ff0, "qsubaddx%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06100f10, 0x0ff00ff0, "sadd16%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06100f90, 0x0ff00ff0, "sadd8%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06100f30, 0x0ff00ff0, "saddaddx%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06300f10, 0x0ff00ff0, "shadd16%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06300f90, 0x0ff00ff0, "shadd8%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06300f30, 0x0ff00ff0, "shaddsubx%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06300f70, 0x0ff00ff0, "shsub16%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06300ff0, 0x0ff00ff0, "shsub8%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06300f50, 0x0ff00ff0, "shsubaddx%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06100f70, 0x0ff00ff0, "ssub16%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06100ff0, 0x0ff00ff0, "ssub8%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06100f50, 0x0ff00ff0, "ssubaddx%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06500f10, 0x0ff00ff0, "uadd16%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06500f90, 0x0ff00ff0, "uadd8%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06500f30, 0x0ff00ff0, "uaddsubx%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06700f10, 0x0ff00ff0, "uhadd16%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06700f90, 0x0ff00ff0, "uhadd8%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06700f30, 0x0ff00ff0, "uhaddsubx%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06700f70, 0x0ff00ff0, "uhsub16%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06700ff0, 0x0ff00ff0, "uhsub8%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06700f50, 0x0ff00ff0, "uhsubaddx%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06600f10, 0x0ff00ff0, "uqadd16%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06600f90, 0x0ff00ff0, "uqadd8%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06600f30, 0x0ff00ff0, "uqaddsubx%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06600f70, 0x0ff00ff0, "uqsub16%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06600ff0, 0x0ff00ff0, "uqsub8%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06600f50, 0x0ff00ff0, "uqsubaddx%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06500f70, 0x0ff00ff0, "usub16%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06500ff0, 0x0ff00ff0, "usub8%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06500f50, 0x0ff00ff0, "usubaddx%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06bf0f30, 0x0fff0ff0, "rev%c\t\%12-15r, %0-3r"},
+ {0x06bf0fb0, 0x0fff0ff0, "rev16%c\t\%12-15r, %0-3r"},
+ {0x06ff0fb0, 0x0fff0ff0, "revsh%c\t\%12-15r, %0-3r"},
+ {0xf8100a00, 0xfe50ffff, "rfe%23?id%24?ba\t\%16-19r%21'!"},
+ {0x06bf0070, 0x0fff0ff0, "sxth%c %12-15r,%0-3r"},
+ {0x06bf0470, 0x0fff0ff0, "sxth%c %12-15r,%0-3r, ROR #8"},
+ {0x06bf0870, 0x0fff0ff0, "sxth%c %12-15r,%0-3r, ROR #16"},
+ {0x06bf0c70, 0x0fff0ff0, "sxth%c %12-15r,%0-3r, ROR #24"},
+ {0x068f0070, 0x0fff0ff0, "sxtb16%c %12-15r,%0-3r"},
+ {0x068f0470, 0x0fff0ff0, "sxtb16%c %12-15r,%0-3r, ROR #8"},
+ {0x068f0870, 0x0fff0ff0, "sxtb16%c %12-15r,%0-3r, ROR #16"},
+ {0x068f0c70, 0x0fff0ff0, "sxtb16%c %12-15r,%0-3r, ROR #24"},
+ {0x06af0070, 0x0fff0ff0, "sxtb%c %12-15r,%0-3r"},
+ {0x06af0470, 0x0fff0ff0, "sxtb%c %12-15r,%0-3r, ROR #8"},
+ {0x06af0870, 0x0fff0ff0, "sxtb%c %12-15r,%0-3r, ROR #16"},
+ {0x06af0c70, 0x0fff0ff0, "sxtb%c %12-15r,%0-3r, ROR #24"},
+ {0x06ff0070, 0x0fff0ff0, "uxth%c %12-15r,%0-3r"},
+ {0x06ff0470, 0x0fff0ff0, "uxth%c %12-15r,%0-3r, ROR #8"},
+ {0x06ff0870, 0x0fff0ff0, "uxth%c %12-15r,%0-3r, ROR #16"},
+ {0x06ff0c70, 0x0fff0ff0, "uxth%c %12-15r,%0-3r, ROR #24"},
+ {0x06cf0070, 0x0fff0ff0, "uxtb16%c %12-15r,%0-3r"},
+ {0x06cf0470, 0x0fff0ff0, "uxtb16%c %12-15r,%0-3r, ROR #8"},
+ {0x06cf0870, 0x0fff0ff0, "uxtb16%c %12-15r,%0-3r, ROR #16"},
+ {0x06cf0c70, 0x0fff0ff0, "uxtb16%c %12-15r,%0-3r, ROR #24"},
+ {0x06ef0070, 0x0fff0ff0, "uxtb%c %12-15r,%0-3r"},
+ {0x06ef0470, 0x0fff0ff0, "uxtb%c %12-15r,%0-3r, ROR #8"},
+ {0x06ef0870, 0x0fff0ff0, "uxtb%c %12-15r,%0-3r, ROR #16"},
+ {0x06ef0c70, 0x0fff0ff0, "uxtb%c %12-15r,%0-3r, ROR #24"},
+ {0x06b00070, 0x0ff00ff0, "sxtah%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06b00470, 0x0ff00ff0, "sxtah%c\t%12-15r, %16-19r, %0-3r, ROR #8"},
+ {0x06b00870, 0x0ff00ff0, "sxtah%c\t%12-15r, %16-19r, %0-3r, ROR #16"},
+ {0x06b00c70, 0x0ff00ff0, "sxtah%c\t%12-15r, %16-19r, %0-3r, ROR #24"},
+ {0x06800070, 0x0ff00ff0, "sxtab16%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06800470, 0x0ff00ff0, "sxtab16%c\t%12-15r, %16-19r, %0-3r, ROR #8"},
+ {0x06800870, 0x0ff00ff0, "sxtab16%c\t%12-15r, %16-19r, %0-3r, ROR #16"},
+ {0x06800c70, 0x0ff00ff0, "sxtab16%c\t%12-15r, %16-19r, %0-3r, ROR #24"},
+ {0x06a00070, 0x0ff00ff0, "sxtab%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06a00470, 0x0ff00ff0, "sxtab%c\t%12-15r, %16-19r, %0-3r, ROR #8"},
+ {0x06a00870, 0x0ff00ff0, "sxtab%c\t%12-15r, %16-19r, %0-3r, ROR #16"},
+ {0x06a00c70, 0x0ff00ff0, "sxtab%c\t%12-15r, %16-19r, %0-3r, ROR #24"},
+ {0x06f00070, 0x0ff00ff0, "uxtah%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06f00470, 0x0ff00ff0, "uxtah%c\t%12-15r, %16-19r, %0-3r, ROR #8"},
+ {0x06f00870, 0x0ff00ff0, "uxtah%c\t%12-15r, %16-19r, %0-3r, ROR #16"},
+ {0x06f00c70, 0x0ff00ff0, "uxtah%c\t%12-15r, %16-19r, %0-3r, ROR #24"},
+ {0x06c00070, 0x0ff00ff0, "uxtab16%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06c00470, 0x0ff00ff0, "uxtab16%c\t%12-15r, %16-19r, %0-3r, ROR #8"},
+ {0x06c00870, 0x0ff00ff0, "uxtab16%c\t%12-15r, %16-19r, %0-3r, ROR #16"},
+ {0x06c00c70, 0x0ff00ff0, "uxtab16%c\t%12-15r, %16-19r, %0-3r, ROR #24"},
+ {0x06e00070, 0x0ff00ff0, "uxtab%c\t%12-15r, %16-19r, %0-3r"},
+ {0x06e00470, 0x0ff00ff0, "uxtab%c\t%12-15r, %16-19r, %0-3r, ROR #8"},
+ {0x06e00870, 0x0ff00ff0, "uxtab%c\t%12-15r, %16-19r, %0-3r, ROR #16"},
+ {0x06e00c70, 0x0ff00ff0, "uxtab%c\t%12-15r, %16-19r, %0-3r, ROR #24"},
+ {0x068000b0, 0x0ff00ff0, "sel%c\t%12-15r, %16-19r, %0-3r"},
+ {0xf1010000, 0xfffffc00, "setend\t%9?ble"},
+ {0x0700f010, 0x0ff0f0d0, "smuad%5'x%c\t%16-19r, %0-3r, %8-11r"},
+ {0x0700f050, 0x0ff0f0d0, "smusd%5'x%c\t%16-19r, %0-3r, %8-11r"},
+ {0x07000010, 0x0ff000d0, "smlad%5'x%c\t%16-19r, %0-3r, %8-11r, %12-15r"},
+ {0x07400010, 0x0ff000d0, "smlald%5'x%c\t%12-15r, %16-19r, %0-3r, %8-11r"},
+ {0x07000050, 0x0ff000d0, "smlsd%5'x%c\t%16-19r, %0-3r, %8-11r, %12-15r"},
+ {0x07400050, 0x0ff000d0, "smlsld%5'x%c\t%12-15r, %16-19r, %0-3r, %8-11r"},
+ {0x0750f010, 0x0ff0f0d0, "smmul%5'r%c\t%16-19r, %0-3r, %8-11r"},
+ {0x07500010, 0x0ff000d0, "smmla%5'r%c\t%16-19r, %0-3r, %8-11r, %12-15r"},
+ {0x075000d0, 0x0ff000d0, "smmls%5'r%c\t%16-19r, %0-3r, %8-11r, %12-15r"},
+ {0xf84d0500, 0xfe5fffe0, "srs%23?id%24?ba\t#%0-4d%21'!"},
+ {0x06a00010, 0x0fe00ff0, "ssat%c\t%12-15r, #%16-20W, %0-3r"},
+ {0x06a00010, 0x0fe00070, "ssat%c\t%12-15r, #%16-20W, %0-3r, LSL #%7-11d"},
+ {0x06a00050, 0x0fe00070, "ssat%c\t%12-15r, #%16-20W, %0-3r, ASR #%7-11d"},
+ {0x06a00f30, 0x0ff00ff0, "ssat16%c\t%12-15r, #%16-19W, %0-3r"},
+ {0x01800f90, 0x0ff00ff0, "strex%c\t%12-15r, %0-3r, [%16-19r]"},
+ {0x00400090, 0x0ff000f0, "umaal%c\t%12-15r, %16-19r, %0-3r, %8-11r"},
+ {0x0780f010, 0x0ff0f0f0, "usad8%c\t%16-19r, %0-3r, %8-11r"},
+ {0x07800010, 0x0ff000f0, "usada8%c\t%16-19r, %0-3r, %8-11r, %12-15r"},
+ {0x06e00010, 0x0fe00ff0, "usat%c\t%12-15r, #%16-20d, %0-3r"},
+ {0x06e00010, 0x0fe00070, "usat%c\t%12-15r, #%16-20d, %0-3r, LSL #%7-11d"},
+ {0x06e00050, 0x0fe00070, "usat%c\t%12-15r, #%16-20d, %0-3r, ASR #%7-11d"},
+ {0x06e00f30, 0x0ff00ff0, "usat16%c\t%12-15r, #%16-19d, %0-3r"},
+
/* V5J instruction. */
{0x012fff20, 0x0ffffff0, "bxj%c\t%0-3r"},
@@ -101,6 +235,59 @@ static struct arm_opcode arm_opcodes[] =
{0x0c500000, 0x0ff00fff, "mra%c\t%12-15r, %16-19r, acc0"},
{0xf450f000, 0xfc70f000, "pld\t%a"},
+ /* Intel Wireless MMX technology instructions. */
+#define FIRST_IWMMXT_INSN 0x0e130130
+#define IWMMXT_INSN_COUNT 47
+ {0x0e130130, 0x0f3f0fff, "tandc%22-23w%c\t%12-15r"},
+ {0x0e400010, 0x0ff00f3f, "tbcst%6-7w%c\t%16-19g, %12-15r"},
+ {0x0e130170, 0x0f3f0ff8, "textrc%22-23w%c\t%12-15r, #%0-2d"},
+ {0x0e100070, 0x0f300ff0, "textrm%3?su%22-23w%c\t%12-15r, %16-19g, #%0-2d"},
+ {0x0e600010, 0x0ff00f38, "tinsr%6-7w%c\t%16-19g, %12-15r, #%0-2d"},
+ {0x0e000110, 0x0ff00fff, "tmcr%c\t%16-19G, %12-15r"},
+ {0x0c400000, 0x0ff00ff0, "tmcrr%c\t%0-3g, %12-15r, %16-19r"},
+ {0x0e2c0010, 0x0ffc0e10, "tmia%17?tb%16?tb%c\t%5-8g, %0-3r, %12-15r"},
+ {0x0e200010, 0x0fff0e10, "tmia%c\t%5-8g, %0-3r, %12-15r"},
+ {0x0e280010, 0x0fff0e10, "tmiaph%c\t%5-8g, %0-3r, %12-15r"},
+ {0x0e100030, 0x0f300fff, "tmovmsk%22-23w%c\t%12-15r, %16-19g"},
+ {0x0e100110, 0x0ff00ff0, "tmrc%c\t%12-15r, %16-19G"},
+ {0x0c500000, 0x0ff00ff0, "tmrrc%c\t%12-15r, %16-19r, %0-3g"},
+ {0x0e130150, 0x0f3f0fff, "torc%22-23w%c\t%12-15r"},
+ {0x0e0001c0, 0x0f300fff, "wacc%22-23w%c\t%12-15g, %16-19g"},
+ {0x0e000180, 0x0f000ff0, "wadd%20-23w%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e000020, 0x0f800ff0, "waligni%c\t%12-15g, %16-19g, %0-3g, #%20-22d"},
+ {0x0e800020, 0x0fc00ff0, "walignr%20-21d%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e200000, 0x0fe00ff0, "wand%20'n%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e800000, 0x0fa00ff0, "wavg2%22?hb%20'r%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e000060, 0x0f300ff0, "wcmpeq%22-23w%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e100060, 0x0f100ff0, "wcmpgt%21?su%22-23w%c\t%12-15g, %16-19g, %0-3g"},
+ {0xfc100100, 0xfe500f00, "wldrw\t%12-15G, %A"},
+ {0x0c100000, 0x0e100e00, "wldr%L%c\t%12-15g, %l"},
+ {0x0e400100, 0x0fc00ff0, "wmac%21?su%20'z%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e800100, 0x0fd00ff0, "wmadd%21?su%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e000160, 0x0f100ff0, "wmax%21?su%22-23w%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e100160, 0x0f100ff0, "wmin%21?su%22-23w%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e000100, 0x0fc00ff0, "wmul%21?su%20?ml%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e000000, 0x0ff00ff0, "wor%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e000080, 0x0f000ff0, "wpack%20-23w%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e300040, 0x0f300ff0, "wror%22-23w%8'g%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e300148, 0x0f300ffc, "wror%22-23w%8'g%c\t%12-15g, %16-19g, %0-3G"},
+ {0x0e000120, 0x0fa00ff0, "wsad%22?hb%20'z%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e0001e0, 0x0f000ff0, "wshufh%c\t%12-15g, %16-19g, #%Z"},
+ {0x0e100040, 0x0f300ff0, "wsll%22-23w%8'g%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e100148, 0x0f300ffc, "wsll%22-23w%8'g%c\t%12-15g, %16-19g, %0-3G"},
+ {0x0e000040, 0x0f300ff0, "wsra%22-23w%8'g%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e000148, 0x0f300ffc, "wsra%22-23w%8'g%c\t%12-15g, %16-19g, %0-3G"},
+ {0x0e200040, 0x0f300ff0, "wsrl%22-23w%8'g%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e200148, 0x0f300ffc, "wsrl%22-23w%8'g%c\t%12-15g, %16-19g, %0-3G"},
+ {0xfc000100, 0xfe500f00, "wstrw\t%12-15G, %A"},
+ {0x0c000000, 0x0e100e00, "wstr%L%c\t%12-15g, %l"},
+ {0x0e0001a0, 0x0f000ff0, "wsub%20-23w%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e0000c0, 0x0f100fff, "wunpckeh%21?su%22-23w%c\t%12-15g, %16-19g"},
+ {0x0e0000e0, 0x0f100fff, "wunpckel%21?su%22-23w%c\t%12-15g, %16-19g"},
+ {0x0e1000c0, 0x0f300ff0, "wunpckih%22-23w%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e1000e0, 0x0f300ff0, "wunpckil%22-23w%c\t%12-15g, %16-19g, %0-3g"},
+ {0x0e100000, 0x0ff00ff0, "wxor%c\t%12-15g, %16-19g, %0-3g"},
+
/* V5 Instructions. */
{0xe1200070, 0xfff000f0, "bkpt\t0x%16-19X%12-15X%8-11X%0-3X"},
{0xfa000000, 0xfe000000, "blx\t%B"},
@@ -141,9 +328,6 @@ static struct arm_opcode arm_opcodes[] =
{0x01200050, 0x0ff00ff0, "qsub%c\t%12-15r, %0-3r, %16-19r"},
{0x01600050, 0x0ff00ff0, "qdsub%c\t%12-15r, %0-3r, %16-19r"},
- {0x0c400000, 0x0ff00000, "mcrr%c\t%8-11d, %4-7d, %12-15r, %16-19r, cr%0-3d"},
- {0x0c500000, 0x0ff00000, "mrrc%c\t%8-11d, %4-7d, %12-15r, %16-19r, cr%0-3d"},
-
/* ARM Instructions. */
{0x00000090, 0x0e100090, "str%c%6's%5?hb\t%12-15r, %s"},
{0x00100090, 0x0e100090, "ldr%c%6's%5?hb\t%12-15r, %s"},
@@ -322,18 +506,18 @@ static struct arm_opcode arm_opcodes[] =
{0x0e100510, 0x0ff00fff, "cfmvr64l%c\t%12-15r, mvdx%16-19d"},
{0x0e000530, 0x0ff00fff, "cfmv64hr%c\tmvdx%16-19d, %12-15r"},
{0x0e100530, 0x0ff00fff, "cfmvr64h%c\t%12-15r, mvdx%16-19d"},
- {0x0e100610, 0x0ff0fff0, "cfmval32%c\tmvax%0-3d, mvfx%16-19d"},
- {0x0e000610, 0x0ff0fff0, "cfmv32al%c\tmvfx%0-3d, mvax%16-19d"},
- {0x0e100630, 0x0ff0fff0, "cfmvam32%c\tmvax%0-3d, mvfx%16-19d"},
- {0x0e000630, 0x0ff0fff0, "cfmv32am%c\tmvfx%0-3d, mvax%16-19d"},
- {0x0e100650, 0x0ff0fff0, "cfmvah32%c\tmvax%0-3d, mvfx%16-19d"},
- {0x0e000650, 0x0ff0fff0, "cfmv32ah%c\tmvfx%0-3d, mvax%16-19d"},
- {0x0e000670, 0x0ff0fff0, "cfmv32a%c\tmvfx%0-3d, mvax%16-19d"},
- {0x0e100670, 0x0ff0fff0, "cfmva32%c\tmvax%0-3d, mvfx%16-19d"},
- {0x0e000690, 0x0ff0fff0, "cfmv64a%c\tmvdx%0-3d, mvax%16-19d"},
- {0x0e100690, 0x0ff0fff0, "cfmva64%c\tmvax%0-3d, mvdx%16-19d"},
- {0x0e1006b0, 0x0ff0fff0, "cfmvsc32%c\tdspsc, mvfx%16-19d"},
- {0x0e0006b0, 0x0ff0fff0, "cfmv32sc%c\tmvfx%0-3d, dspsc"},
+ {0x0e200440, 0x0ff00fff, "cfmval32%c\tmvax%12-15d, mvfx%16-19d"},
+ {0x0e100440, 0x0ff00fff, "cfmv32al%c\tmvfx%12-15d, mvax%16-19d"},
+ {0x0e200460, 0x0ff00fff, "cfmvam32%c\tmvax%12-15d, mvfx%16-19d"},
+ {0x0e100460, 0x0ff00fff, "cfmv32am%c\tmvfx%12-15d, mvax%16-19d"},
+ {0x0e200480, 0x0ff00fff, "cfmvah32%c\tmvax%12-15d, mvfx%16-19d"},
+ {0x0e100480, 0x0ff00fff, "cfmv32ah%c\tmvfx%12-15d, mvax%16-19d"},
+ {0x0e2004a0, 0x0ff00fff, "cfmva32%c\tmvax%12-15d, mvfx%16-19d"},
+ {0x0e1004a0, 0x0ff00fff, "cfmv32a%c\tmvfx%12-15d, mvax%16-19d"},
+ {0x0e2004c0, 0x0ff00fff, "cfmva64%c\tmvax%12-15d, mvdx%16-19d"},
+ {0x0e1004c0, 0x0ff00fff, "cfmv64a%c\tmvdx%12-15d, mvax%16-19d"},
+ {0x0e2004e0, 0x0fff0fff, "cfmvsc32%c\tdspsc, mvdx%12-15d"},
+ {0x0e1004e0, 0x0fff0fff, "cfmv32sc%c\tmvdx%12-15d, dspsc"},
{0x0e000400, 0x0ff00fff, "cfcpys%c\tmvf%12-15d, mvf%16-19d"},
{0x0e000420, 0x0ff00fff, "cfcpyd%c\tmvd%12-15d, mvd%16-19d"},
{0x0e000460, 0x0ff00fff, "cfcvtsd%c\tmvd%12-15d, mvf%16-19d"},
@@ -382,6 +566,8 @@ static struct arm_opcode arm_opcodes[] =
{0x0e300600, 0x0ff00f00, "cfmsuba32%c\tmvax%5-7d, mvax%12-15d, mvfx%16-19d, mvfx%0-3d"},
/* Generic coprocessor instructions */
+ {0x0c400000, 0x0ff00000, "mcrr%c\t%8-11d, %4-7d, %12-15r, %16-19r, cr%0-3d"},
+ {0x0c500000, 0x0ff00000, "mrrc%c\t%8-11d, %4-7d, %12-15r, %16-19r, cr%0-3d"},
{0x0e000000, 0x0f000010, "cdp%c\t%8-11d, %20-23d, cr%12-15d, cr%16-19d, cr%0-3d, {%5-7d}"},
{0x0e100010, 0x0f100010, "mrc%c\t%8-11d, %21-23d, %12-15r, cr%16-19d, cr%0-3d, {%5-7d}"},
{0x0e000010, 0x0f100010, "mcr%c\t%8-11d, %21-23d, %12-15r, cr%16-19d, cr%0-3d, {%5-7d}"},
@@ -395,10 +581,23 @@ static struct arm_opcode arm_opcodes[] =
#define BDISP(x) ((((x) & 0xffffff) ^ 0x800000) - 0x800000) /* 26 bit */
-static struct thumb_opcode thumb_opcodes[] =
+static const struct thumb_opcode thumb_opcodes[] =
{
/* Thumb instructions. */
+ /* ARM V6. */
+ {0xb660, 0xfff8, "cpsie\t%2'a%1'i%0'f"},
+ {0xb670, 0xfff8, "cpsid\t%2'a%1'i%0'f"},
+ {0x4600, 0xffc0, "cpy\t%0-2r, %3-5r"},
+ {0xba00, 0xffc0, "rev\t%0-2r, %3-5r"},
+ {0xba40, 0xffc0, "rev16\t%0-2r, %3-5r"},
+ {0xbac0, 0xffc0, "revsh\t%0-2r, %3-5r"},
+ {0xb650, 0xfff7, "setend\t%3?ble\t"},
+ {0xb200, 0xffc0, "sxth\t%0-2r, %3-5r"},
+ {0xb240, 0xffc0, "sxtb\t%0-2r, %3-5r"},
+ {0xb280, 0xffc0, "uxth\t%0-2r, %3-5r"},
+ {0xb2c0, 0xffc0, "uxtb\t%0-2r, %3-5r"},
+
/* ARM V5 ISA extends Thumb. */
{0xbe00, 0xff00, "bkpt\t%0-7x"},
{0x4780, 0xff87, "blx\t%3-6r"}, /* note: 4 bit register number. */
diff --git a/contrib/binutils/opcodes/cgen-asm.c b/contrib/binutils/opcodes/cgen-asm.c
index 05b62bf..7231e2d 100644
--- a/contrib/binutils/opcodes/cgen-asm.c
+++ b/contrib/binutils/opcodes/cgen-asm.c
@@ -28,16 +28,14 @@
#include "opcode/cgen.h"
#include "opintl.h"
-static CGEN_INSN_LIST * hash_insn_array PARAMS ((CGEN_CPU_DESC, const CGEN_INSN *, int, int, CGEN_INSN_LIST **, CGEN_INSN_LIST *));
-static CGEN_INSN_LIST * hash_insn_list PARAMS ((CGEN_CPU_DESC, const CGEN_INSN_LIST *, CGEN_INSN_LIST **, CGEN_INSN_LIST *));
-static void build_asm_hash_table PARAMS ((CGEN_CPU_DESC));
+static CGEN_INSN_LIST * hash_insn_array (CGEN_CPU_DESC, const CGEN_INSN *, int, int, CGEN_INSN_LIST **, CGEN_INSN_LIST *);
+static CGEN_INSN_LIST * hash_insn_list (CGEN_CPU_DESC, const CGEN_INSN_LIST *, CGEN_INSN_LIST **, CGEN_INSN_LIST *);
+static void build_asm_hash_table (CGEN_CPU_DESC);
/* Set the cgen_parse_operand_fn callback. */
void
-cgen_set_parse_operand_fn (cd, fn)
- CGEN_CPU_DESC cd;
- cgen_parse_operand_fn fn;
+cgen_set_parse_operand_fn (CGEN_CPU_DESC cd, cgen_parse_operand_fn fn)
{
cd->parse_operand_fn = fn;
}
@@ -45,8 +43,7 @@ cgen_set_parse_operand_fn (cd, fn)
/* Called whenever starting to parse an insn. */
void
-cgen_init_parse_operand (cd)
- CGEN_CPU_DESC cd;
+cgen_init_parse_operand (CGEN_CPU_DESC cd)
{
/* This tells the callback to re-initialize. */
(void) (* cd->parse_operand_fn)
@@ -66,13 +63,12 @@ cgen_init_parse_operand (cd)
list and we want earlier ones to be prefered. */
static CGEN_INSN_LIST *
-hash_insn_array (cd, insns, count, entsize, htable, hentbuf)
- CGEN_CPU_DESC cd;
- const CGEN_INSN *insns;
- int count;
- int entsize ATTRIBUTE_UNUSED;
- CGEN_INSN_LIST **htable;
- CGEN_INSN_LIST *hentbuf;
+hash_insn_array (CGEN_CPU_DESC cd,
+ const CGEN_INSN *insns,
+ int count,
+ int entsize ATTRIBUTE_UNUSED,
+ CGEN_INSN_LIST **htable,
+ CGEN_INSN_LIST *hentbuf)
{
int i;
@@ -97,11 +93,10 @@ hash_insn_array (cd, insns, count, entsize, htable, hentbuf)
in a list. */
static CGEN_INSN_LIST *
-hash_insn_list (cd, insns, htable, hentbuf)
- CGEN_CPU_DESC cd;
- const CGEN_INSN_LIST *insns;
- CGEN_INSN_LIST **htable;
- CGEN_INSN_LIST *hentbuf;
+hash_insn_list (CGEN_CPU_DESC cd,
+ const CGEN_INSN_LIST *insns,
+ CGEN_INSN_LIST **htable,
+ CGEN_INSN_LIST *hentbuf)
{
const CGEN_INSN_LIST *ilist;
@@ -123,8 +118,7 @@ hash_insn_list (cd, insns, htable, hentbuf)
/* Build the assembler instruction hash table. */
static void
-build_asm_hash_table (cd)
- CGEN_CPU_DESC cd;
+build_asm_hash_table (CGEN_CPU_DESC cd)
{
int count = cgen_insn_count (cd) + cgen_macro_insn_count (cd);
CGEN_INSN_TABLE *insn_table = &cd->insn_table;
@@ -179,9 +173,7 @@ build_asm_hash_table (cd)
/* Return the first entry in the hash list for INSN. */
CGEN_INSN_LIST *
-cgen_asm_lookup_insn (cd, insn)
- CGEN_CPU_DESC cd;
- const char *insn;
+cgen_asm_lookup_insn (CGEN_CPU_DESC cd, const char *insn)
{
unsigned int hash;
@@ -201,11 +193,10 @@ cgen_asm_lookup_insn (cd, insn)
recording something in the keyword table]. */
const char *
-cgen_parse_keyword (cd, strp, keyword_table, valuep)
- CGEN_CPU_DESC cd ATTRIBUTE_UNUSED;
- const char **strp;
- CGEN_KEYWORD *keyword_table;
- long *valuep;
+cgen_parse_keyword (CGEN_CPU_DESC cd ATTRIBUTE_UNUSED,
+ const char **strp,
+ CGEN_KEYWORD *keyword_table,
+ long *valuep)
{
const CGEN_KEYWORD_ENTRY *ke;
char buf[256];
@@ -225,7 +216,9 @@ cgen_parse_keyword (cd, strp, keyword_table, valuep)
/* Allow letters, digits, and any special characters. */
while (((p - start) < (int) sizeof (buf))
&& *p
- && (ISALNUM (*p) || strchr (keyword_table->nonalpha_chars, *p)))
+ && (ISALNUM (*p)
+ || *p == '_'
+ || strchr (keyword_table->nonalpha_chars, *p)))
++p;
if (p - start >= (int) sizeof (buf))
@@ -260,11 +253,10 @@ cgen_parse_keyword (cd, strp, keyword_table, valuep)
cgen_parse_address. */
const char *
-cgen_parse_signed_integer (cd, strp, opindex, valuep)
- CGEN_CPU_DESC cd;
- const char **strp;
- int opindex;
- long *valuep;
+cgen_parse_signed_integer (CGEN_CPU_DESC cd,
+ const char **strp,
+ int opindex,
+ long *valuep)
{
bfd_vma value;
enum cgen_parse_operand_result result;
@@ -285,11 +277,10 @@ cgen_parse_signed_integer (cd, strp, opindex, valuep)
cgen_parse_address. */
const char *
-cgen_parse_unsigned_integer (cd, strp, opindex, valuep)
- CGEN_CPU_DESC cd;
- const char **strp;
- int opindex;
- unsigned long *valuep;
+cgen_parse_unsigned_integer (CGEN_CPU_DESC cd,
+ const char **strp,
+ int opindex,
+ unsigned long *valuep)
{
bfd_vma value;
enum cgen_parse_operand_result result;
@@ -307,13 +298,12 @@ cgen_parse_unsigned_integer (cd, strp, opindex, valuep)
/* Address parser. */
const char *
-cgen_parse_address (cd, strp, opindex, opinfo, resultp, valuep)
- CGEN_CPU_DESC cd;
- const char **strp;
- int opindex;
- int opinfo;
- enum cgen_parse_operand_result *resultp;
- bfd_vma *valuep;
+cgen_parse_address (CGEN_CPU_DESC cd,
+ const char **strp,
+ int opindex,
+ int opinfo,
+ enum cgen_parse_operand_result *resultp,
+ bfd_vma *valuep)
{
bfd_vma value;
enum cgen_parse_operand_result result_type;
@@ -335,8 +325,7 @@ cgen_parse_address (cd, strp, opindex, opinfo, resultp, valuep)
/* Signed integer validation routine. */
const char *
-cgen_validate_signed_integer (value, min, max)
- long value, min, max;
+cgen_validate_signed_integer (long value, long min, long max)
{
if (value < min || value > max)
{
@@ -356,8 +345,9 @@ cgen_validate_signed_integer (value, min, max)
cases where min != 0 (and max > LONG_MAX). */
const char *
-cgen_validate_unsigned_integer (value, min, max)
- unsigned long value, min, max;
+cgen_validate_unsigned_integer (unsigned long value,
+ unsigned long min,
+ unsigned long max)
{
if (value < min || value > max)
{
diff --git a/contrib/binutils/opcodes/cgen-asm.in b/contrib/binutils/opcodes/cgen-asm.in
index 525177c..420f640 100644
--- a/contrib/binutils/opcodes/cgen-asm.in
+++ b/contrib/binutils/opcodes/cgen-asm.in
@@ -43,7 +43,7 @@ along with this program; if not, write to the Free Software Foundation, Inc.,
#define max(a,b) ((a) > (b) ? (a) : (b))
static const char * parse_insn_normal
- PARAMS ((CGEN_CPU_DESC, const CGEN_INSN *, const char **, CGEN_FIELDS *));
+ (CGEN_CPU_DESC, const CGEN_INSN *, const char **, CGEN_FIELDS *);
/* -- assembler routines inserted here. */
@@ -60,8 +60,7 @@ static const char * parse_insn_normal
Returns NULL for success, an error message for failure. */
char *
-@arch@_cgen_build_insn_regex (insn)
- CGEN_INSN *insn;
+@arch@_cgen_build_insn_regex (CGEN_INSN *insn)
{
CGEN_OPCODE *opc = (CGEN_OPCODE *) CGEN_INSN_OPCODE (insn);
const char *mnem = CGEN_INSN_MNEMONIC (insn);
@@ -184,11 +183,10 @@ char *
Returns NULL for success, an error message for failure. */
static const char *
-parse_insn_normal (cd, insn, strp, fields)
- CGEN_CPU_DESC cd;
- const CGEN_INSN *insn;
- const char **strp;
- CGEN_FIELDS *fields;
+parse_insn_normal (CGEN_CPU_DESC cd,
+ const CGEN_INSN *insn,
+ const char **strp,
+ CGEN_FIELDS *fields)
{
/* ??? Runtime added insns not handled yet. */
const CGEN_SYNTAX *syntax = CGEN_INSN_SYNTAX (insn);
@@ -326,12 +324,11 @@ parse_insn_normal (cd, insn, strp, fields)
mind helps keep the design clean. */
const CGEN_INSN *
-@arch@_cgen_assemble_insn (cd, str, fields, buf, errmsg)
- CGEN_CPU_DESC cd;
- const char *str;
- CGEN_FIELDS *fields;
- CGEN_INSN_BYTES_PTR buf;
- char **errmsg;
+@arch@_cgen_assemble_insn (CGEN_CPU_DESC cd,
+ const char *str,
+ CGEN_FIELDS *fields,
+ CGEN_INSN_BYTES_PTR buf,
+ char **errmsg)
{
const char *start;
CGEN_INSN_LIST *ilist;
@@ -361,10 +358,10 @@ const CGEN_INSN *
if (! @arch@_cgen_insn_supported (cd, insn))
continue;
#endif
- /* If the RELAX attribute is set, this is an insn that shouldn't be
+ /* If the RELAXED attribute is set, this is an insn that shouldn't be
chosen immediately. Instead, it is used during assembler/linker
relaxation if possible. */
- if (CGEN_INSN_ATTR_VALUE (insn, CGEN_INSN_RELAX) != 0)
+ if (CGEN_INSN_ATTR_VALUE (insn, CGEN_INSN_RELAXED) != 0)
continue;
str = start;
@@ -435,9 +432,7 @@ const CGEN_INSN *
FIXME: Not currently used. */
void
-@arch@_cgen_asm_hash_keywords (cd, opvals)
- CGEN_CPU_DESC cd;
- CGEN_KEYWORD *opvals;
+@arch@_cgen_asm_hash_keywords (CGEN_CPU_DESC cd, CGEN_KEYWORD *opvals)
{
CGEN_KEYWORD_SEARCH search = cgen_keyword_search_init (opvals, NULL);
const CGEN_KEYWORD_ENTRY * ke;
diff --git a/contrib/binutils/opcodes/cgen-dis.c b/contrib/binutils/opcodes/cgen-dis.c
index 881ee14..ca621de 100644
--- a/contrib/binutils/opcodes/cgen-dis.c
+++ b/contrib/binutils/opcodes/cgen-dis.c
@@ -27,19 +27,18 @@
#include "symcat.h"
#include "opcode/cgen.h"
-static CGEN_INSN_LIST * hash_insn_array PARAMS ((CGEN_CPU_DESC, const CGEN_INSN *, int, int, CGEN_INSN_LIST **, CGEN_INSN_LIST *));
-static CGEN_INSN_LIST * hash_insn_list PARAMS ((CGEN_CPU_DESC, const CGEN_INSN_LIST *, CGEN_INSN_LIST **, CGEN_INSN_LIST *));
-static void build_dis_hash_table PARAMS ((CGEN_CPU_DESC));
-static int count_decodable_bits PARAMS ((const CGEN_INSN *));
-static void add_insn_to_hash_chain PARAMS ((CGEN_INSN_LIST *,
- const CGEN_INSN *,
- CGEN_INSN_LIST **,
- unsigned int));
+static CGEN_INSN_LIST * hash_insn_array (CGEN_CPU_DESC, const CGEN_INSN *, int, int, CGEN_INSN_LIST **, CGEN_INSN_LIST *);
+static CGEN_INSN_LIST * hash_insn_list (CGEN_CPU_DESC, const CGEN_INSN_LIST *, CGEN_INSN_LIST **, CGEN_INSN_LIST *);
+static void build_dis_hash_table (CGEN_CPU_DESC);
+static int count_decodable_bits (const CGEN_INSN *);
+static void add_insn_to_hash_chain (CGEN_INSN_LIST *,
+ const CGEN_INSN *,
+ CGEN_INSN_LIST **,
+ unsigned int);
/* Return the number of decodable bits in this insn. */
static int
-count_decodable_bits (insn)
- const CGEN_INSN *insn;
+count_decodable_bits (const CGEN_INSN *insn)
{
unsigned mask = CGEN_INSN_BASE_MASK (insn);
int bits = 0;
@@ -54,11 +53,10 @@ count_decodable_bits (insn)
/* Add an instruction to the hash chain. */
static void
-add_insn_to_hash_chain (hentbuf, insn, htable, hash)
- CGEN_INSN_LIST *hentbuf;
- const CGEN_INSN *insn;
- CGEN_INSN_LIST **htable;
- unsigned int hash;
+add_insn_to_hash_chain (CGEN_INSN_LIST *hentbuf,
+ const CGEN_INSN *insn,
+ CGEN_INSN_LIST **htable,
+ unsigned int hash)
{
CGEN_INSN_LIST *current_buf;
CGEN_INSN_LIST *previous_buf;
@@ -100,13 +98,12 @@ add_insn_to_hash_chain (hentbuf, insn, htable, hash)
list and we want earlier ones to be prefered. */
static CGEN_INSN_LIST *
-hash_insn_array (cd, insns, count, entsize, htable, hentbuf)
- CGEN_CPU_DESC cd;
- const CGEN_INSN * insns;
- int count;
- int entsize ATTRIBUTE_UNUSED;
- CGEN_INSN_LIST ** htable;
- CGEN_INSN_LIST * hentbuf;
+hash_insn_array (CGEN_CPU_DESC cd,
+ const CGEN_INSN * insns,
+ int count,
+ int entsize ATTRIBUTE_UNUSED,
+ CGEN_INSN_LIST ** htable,
+ CGEN_INSN_LIST * hentbuf)
{
int big_p = CGEN_CPU_ENDIAN (cd) == CGEN_ENDIAN_BIG;
int i;
@@ -141,11 +138,10 @@ hash_insn_array (cd, insns, count, entsize, htable, hentbuf)
in a list. */
static CGEN_INSN_LIST *
-hash_insn_list (cd, insns, htable, hentbuf)
- CGEN_CPU_DESC cd;
- const CGEN_INSN_LIST *insns;
- CGEN_INSN_LIST **htable;
- CGEN_INSN_LIST *hentbuf;
+hash_insn_list (CGEN_CPU_DESC cd,
+ const CGEN_INSN_LIST *insns,
+ CGEN_INSN_LIST **htable,
+ CGEN_INSN_LIST *hentbuf)
{
int big_p = CGEN_CPU_ENDIAN (cd) == CGEN_ENDIAN_BIG;
const CGEN_INSN_LIST *ilist;
@@ -177,8 +173,7 @@ hash_insn_list (cd, insns, htable, hentbuf)
/* Build the disassembler instruction hash table. */
static void
-build_dis_hash_table (cd)
- CGEN_CPU_DESC cd;
+build_dis_hash_table (CGEN_CPU_DESC cd)
{
int count = cgen_insn_count (cd) + cgen_macro_insn_count (cd);
CGEN_INSN_TABLE *insn_table = & cd->insn_table;
@@ -233,10 +228,7 @@ build_dis_hash_table (cd)
/* Return the first entry in the hash list for INSN. */
CGEN_INSN_LIST *
-cgen_dis_lookup_insn (cd, buf, value)
- CGEN_CPU_DESC cd;
- const char * buf;
- CGEN_INSN_INT value;
+cgen_dis_lookup_insn (CGEN_CPU_DESC cd, const char * buf, CGEN_INSN_INT value)
{
unsigned int hash;
diff --git a/contrib/binutils/opcodes/cgen-dis.in b/contrib/binutils/opcodes/cgen-dis.in
index 7c59340..1a3c0fa 100644
--- a/contrib/binutils/opcodes/cgen-dis.in
+++ b/contrib/binutils/opcodes/cgen-dis.in
@@ -4,7 +4,8 @@
THIS FILE IS MACHINE GENERATED WITH CGEN.
- the resultant file is machine generated, cgen-dis.in isn't
-Copyright 1996, 1997, 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002
+Free Software Foundation, Inc.
This file is part of the GNU Binutils and GDB, the GNU debugger.
@@ -31,6 +32,7 @@ along with this program; if not, write to the Free Software Foundation, Inc.,
#include "dis-asm.h"
#include "bfd.h"
#include "symcat.h"
+#include "libiberty.h"
#include "@prefix@-desc.h"
#include "@prefix@-opc.h"
#include "opintl.h"
@@ -39,34 +41,32 @@ along with this program; if not, write to the Free Software Foundation, Inc.,
#define UNKNOWN_INSN_MSG _("*unknown*")
static void print_normal
- PARAMS ((CGEN_CPU_DESC, PTR, long, unsigned int, bfd_vma, int));
+ (CGEN_CPU_DESC, void *, long, unsigned int, bfd_vma, int);
static void print_address
- PARAMS ((CGEN_CPU_DESC, PTR, bfd_vma, unsigned int, bfd_vma, int));
+ (CGEN_CPU_DESC, void *, bfd_vma, unsigned int, bfd_vma, int);
static void print_keyword
- PARAMS ((CGEN_CPU_DESC, PTR, CGEN_KEYWORD *, long, unsigned int));
+ (CGEN_CPU_DESC, void *, CGEN_KEYWORD *, long, unsigned int);
static void print_insn_normal
- PARAMS ((CGEN_CPU_DESC, PTR, const CGEN_INSN *, CGEN_FIELDS *,
- bfd_vma, int));
+ (CGEN_CPU_DESC, void *, const CGEN_INSN *, CGEN_FIELDS *, bfd_vma, int);
static int print_insn
- PARAMS ((CGEN_CPU_DESC, bfd_vma, disassemble_info *, char *, unsigned));
+ (CGEN_CPU_DESC, bfd_vma, disassemble_info *, char *, unsigned);
static int default_print_insn
- PARAMS ((CGEN_CPU_DESC, bfd_vma, disassemble_info *));
+ (CGEN_CPU_DESC, bfd_vma, disassemble_info *);
static int read_insn
- PARAMS ((CGEN_CPU_DESC, bfd_vma, disassemble_info *, char *, int,
- CGEN_EXTRACT_INFO *, unsigned long *));
+ (CGEN_CPU_DESC, bfd_vma, disassemble_info *, char *, int, CGEN_EXTRACT_INFO *,
+ unsigned long *);
/* -- disassembler routines inserted here */
/* Default print handler. */
static void
-print_normal (cd, dis_info, value, attrs, pc, length)
- CGEN_CPU_DESC cd ATTRIBUTE_UNUSED;
- PTR dis_info;
- long value;
- unsigned int attrs;
- bfd_vma pc ATTRIBUTE_UNUSED;
- int length ATTRIBUTE_UNUSED;
+print_normal (CGEN_CPU_DESC cd ATTRIBUTE_UNUSED,
+ void *dis_info,
+ long value,
+ unsigned int attrs,
+ bfd_vma pc ATTRIBUTE_UNUSED,
+ int length ATTRIBUTE_UNUSED)
{
disassemble_info *info = (disassemble_info *) dis_info;
@@ -86,13 +86,12 @@ print_normal (cd, dis_info, value, attrs, pc, length)
/* Default address handler. */
static void
-print_address (cd, dis_info, value, attrs, pc, length)
- CGEN_CPU_DESC cd ATTRIBUTE_UNUSED;
- PTR dis_info;
- bfd_vma value;
- unsigned int attrs;
- bfd_vma pc ATTRIBUTE_UNUSED;
- int length ATTRIBUTE_UNUSED;
+print_address (CGEN_CPU_DESC cd ATTRIBUTE_UNUSED,
+ void *dis_info,
+ bfd_vma value,
+ unsigned int attrs,
+ bfd_vma pc ATTRIBUTE_UNUSED,
+ int length ATTRIBUTE_UNUSED)
{
disassemble_info *info = (disassemble_info *) dis_info;
@@ -116,12 +115,11 @@ print_address (cd, dis_info, value, attrs, pc, length)
/* Keyword print handler. */
static void
-print_keyword (cd, dis_info, keyword_table, value, attrs)
- CGEN_CPU_DESC cd ATTRIBUTE_UNUSED;
- PTR dis_info;
- CGEN_KEYWORD *keyword_table;
- long value;
- unsigned int attrs ATTRIBUTE_UNUSED;
+print_keyword (CGEN_CPU_DESC cd ATTRIBUTE_UNUSED,
+ void *dis_info,
+ CGEN_KEYWORD *keyword_table,
+ long value,
+ unsigned int attrs ATTRIBUTE_UNUSED)
{
disassemble_info *info = (disassemble_info *) dis_info;
const CGEN_KEYWORD_ENTRY *ke;
@@ -135,17 +133,16 @@ print_keyword (cd, dis_info, keyword_table, value, attrs)
/* Default insn printer.
- DIS_INFO is defined as `PTR' so the disassembler needn't know anything
+ DIS_INFO is defined as `void *' so the disassembler needn't know anything
about disassemble_info. */
static void
-print_insn_normal (cd, dis_info, insn, fields, pc, length)
- CGEN_CPU_DESC cd;
- PTR dis_info;
- const CGEN_INSN *insn;
- CGEN_FIELDS *fields;
- bfd_vma pc;
- int length;
+print_insn_normal (CGEN_CPU_DESC cd,
+ void *dis_info,
+ const CGEN_INSN *insn,
+ CGEN_FIELDS *fields,
+ bfd_vma pc,
+ int length)
{
const CGEN_SYNTAX *syntax = CGEN_INSN_SYNTAX (insn);
disassemble_info *info = (disassemble_info *) dis_info;
@@ -177,14 +174,13 @@ print_insn_normal (cd, dis_info, insn, fields, pc, length)
Returns 0 if all is well, non-zero otherwise. */
static int
-read_insn (cd, pc, info, buf, buflen, ex_info, insn_value)
- CGEN_CPU_DESC cd ATTRIBUTE_UNUSED;
- bfd_vma pc;
- disassemble_info *info;
- char *buf;
- int buflen;
- CGEN_EXTRACT_INFO *ex_info;
- unsigned long *insn_value;
+read_insn (CGEN_CPU_DESC cd ATTRIBUTE_UNUSED,
+ bfd_vma pc,
+ disassemble_info *info,
+ char *buf,
+ int buflen,
+ CGEN_EXTRACT_INFO *ex_info,
+ unsigned long *insn_value)
{
int status = (*info->read_memory_func) (pc, buf, buflen, info);
if (status != 0)
@@ -208,12 +204,11 @@ read_insn (cd, pc, info, buf, buflen, ex_info, insn_value)
been called). */
static int
-print_insn (cd, pc, info, buf, buflen)
- CGEN_CPU_DESC cd;
- bfd_vma pc;
- disassemble_info *info;
- char *buf;
- unsigned int buflen;
+print_insn (CGEN_CPU_DESC cd,
+ bfd_vma pc,
+ disassemble_info *info,
+ char *buf,
+ unsigned int buflen)
{
CGEN_INSN_INT insn_value;
const CGEN_INSN_LIST *insn_list;
@@ -318,10 +313,7 @@ print_insn (cd, pc, info, buf, buflen)
#endif
static int
-default_print_insn (cd, pc, info)
- CGEN_CPU_DESC cd;
- bfd_vma pc;
- disassemble_info *info;
+default_print_insn (CGEN_CPU_DESC cd, bfd_vma pc, disassemble_info *info)
{
char buf[CGEN_MAX_INSN_SIZE];
int buflen;
@@ -360,9 +352,7 @@ typedef struct cpu_desc_list {
} cpu_desc_list;
int
-print_insn_@arch@ (pc, info)
- bfd_vma pc;
- disassemble_info *info;
+print_insn_@arch@ (bfd_vma pc, disassemble_info *info)
{
static cpu_desc_list *cd_list = 0;
cpu_desc_list *cl = 0;
diff --git a/contrib/binutils/opcodes/cgen-ibld.in b/contrib/binutils/opcodes/cgen-ibld.in
index d2bfd02..316f183 100644
--- a/contrib/binutils/opcodes/cgen-ibld.in
+++ b/contrib/binutils/opcodes/cgen-ibld.in
@@ -44,30 +44,29 @@ along with this program; if not, write to the Free Software Foundation, Inc.,
#define FLD(f) (fields->f)
static const char * insert_normal
- PARAMS ((CGEN_CPU_DESC, long, unsigned int, unsigned int, unsigned int,
- unsigned int, unsigned int, unsigned int, CGEN_INSN_BYTES_PTR));
+ (CGEN_CPU_DESC, long, unsigned int, unsigned int, unsigned int,
+ unsigned int, unsigned int, unsigned int, CGEN_INSN_BYTES_PTR);
static const char * insert_insn_normal
- PARAMS ((CGEN_CPU_DESC, const CGEN_INSN *,
- CGEN_FIELDS *, CGEN_INSN_BYTES_PTR, bfd_vma));
+ (CGEN_CPU_DESC, const CGEN_INSN *,
+ CGEN_FIELDS *, CGEN_INSN_BYTES_PTR, bfd_vma);
static int extract_normal
- PARAMS ((CGEN_CPU_DESC, CGEN_EXTRACT_INFO *, CGEN_INSN_INT,
- unsigned int, unsigned int, unsigned int, unsigned int,
- unsigned int, unsigned int, bfd_vma, long *));
+ (CGEN_CPU_DESC, CGEN_EXTRACT_INFO *, CGEN_INSN_INT,
+ unsigned int, unsigned int, unsigned int, unsigned int,
+ unsigned int, unsigned int, bfd_vma, long *);
static int extract_insn_normal
- PARAMS ((CGEN_CPU_DESC, const CGEN_INSN *, CGEN_EXTRACT_INFO *,
- CGEN_INSN_INT, CGEN_FIELDS *, bfd_vma));
+ (CGEN_CPU_DESC, const CGEN_INSN *, CGEN_EXTRACT_INFO *,
+ CGEN_INSN_INT, CGEN_FIELDS *, bfd_vma);
#if CGEN_INT_INSN_P
static void put_insn_int_value
- PARAMS ((CGEN_CPU_DESC, CGEN_INSN_BYTES_PTR, int, int, CGEN_INSN_INT));
+ (CGEN_CPU_DESC, CGEN_INSN_BYTES_PTR, int, int, CGEN_INSN_INT);
#endif
#if ! CGEN_INT_INSN_P
static CGEN_INLINE void insert_1
- PARAMS ((CGEN_CPU_DESC, unsigned long, int, int, int, unsigned char *));
+ (CGEN_CPU_DESC, unsigned long, int, int, int, unsigned char *);
static CGEN_INLINE int fill_cache
- PARAMS ((CGEN_CPU_DESC, CGEN_EXTRACT_INFO *, int, int, bfd_vma));
+ (CGEN_CPU_DESC, CGEN_EXTRACT_INFO *, int, int, bfd_vma);
static CGEN_INLINE long extract_1
- PARAMS ((CGEN_CPU_DESC, CGEN_EXTRACT_INFO *, int, int, int,
- unsigned char *, bfd_vma));
+ (CGEN_CPU_DESC, CGEN_EXTRACT_INFO *, int, int, int, unsigned char *, bfd_vma);
#endif
/* Operand insertion. */
@@ -77,11 +76,12 @@ static CGEN_INLINE long extract_1
/* Subroutine of insert_normal. */
static CGEN_INLINE void
-insert_1 (cd, value, start, length, word_length, bufp)
- CGEN_CPU_DESC cd;
- unsigned long value;
- int start,length,word_length;
- unsigned char *bufp;
+insert_1 (CGEN_CPU_DESC cd,
+ unsigned long value,
+ int start,
+ int length,
+ int word_length,
+ unsigned char *bufp)
{
unsigned long x,mask;
int shift;
@@ -118,13 +118,15 @@ insert_1 (cd, value, start, length, word_length, bufp)
necessary. */
static const char *
-insert_normal (cd, value, attrs, word_offset, start, length, word_length,
- total_length, buffer)
- CGEN_CPU_DESC cd;
- long value;
- unsigned int attrs;
- unsigned int word_offset, start, length, word_length, total_length;
- CGEN_INSN_BYTES_PTR buffer;
+insert_normal (CGEN_CPU_DESC cd,
+ long value,
+ unsigned int attrs,
+ unsigned int word_offset,
+ unsigned int start,
+ unsigned int length,
+ unsigned int word_length,
+ unsigned int total_length,
+ CGEN_INSN_BYTES_PTR buffer)
{
static char errbuf[100];
/* Written this way to avoid undefined behaviour. */
@@ -232,12 +234,11 @@ insert_normal (cd, value, attrs, word_offset, start, length, word_length,
The result is an error message or NULL if success. */
static const char *
-insert_insn_normal (cd, insn, fields, buffer, pc)
- CGEN_CPU_DESC cd;
- const CGEN_INSN * insn;
- CGEN_FIELDS * fields;
- CGEN_INSN_BYTES_PTR buffer;
- bfd_vma pc;
+insert_insn_normal (CGEN_CPU_DESC cd,
+ const CGEN_INSN * insn,
+ CGEN_FIELDS * fields,
+ CGEN_INSN_BYTES_PTR buffer,
+ bfd_vma pc)
{
const CGEN_SYNTAX *syntax = CGEN_INSN_SYNTAX (insn);
unsigned long value;
@@ -288,12 +289,11 @@ insert_insn_normal (cd, insn, fields, buffer, pc)
because it needs <prefix>-desc.h for CGEN_INT_INSN_P. */
static void
-put_insn_int_value (cd, buf, length, insn_length, value)
- CGEN_CPU_DESC cd ATTRIBUTE_UNUSED;
- CGEN_INSN_BYTES_PTR buf;
- int length;
- int insn_length;
- CGEN_INSN_INT value;
+put_insn_int_value (CGEN_CPU_DESC cd ATTRIBUTE_UNUSED,
+ CGEN_INSN_BYTES_PTR buf,
+ int length,
+ int insn_length,
+ CGEN_INSN_INT value)
{
/* For architectures with insns smaller than the base-insn-bitsize,
length may be too big. */
@@ -320,11 +320,11 @@ put_insn_int_value (cd, buf, length, insn_length, value)
Returns 1 for success, 0 for failure. */
static CGEN_INLINE int
-fill_cache (cd, ex_info, offset, bytes, pc)
- CGEN_CPU_DESC cd ATTRIBUTE_UNUSED;
- CGEN_EXTRACT_INFO *ex_info;
- int offset, bytes;
- bfd_vma pc;
+fill_cache (CGEN_CPU_DESC cd ATTRIBUTE_UNUSED,
+ CGEN_EXTRACT_INFO *ex_info,
+ int offset,
+ int bytes,
+ bfd_vma pc)
{
/* It's doubtful that the middle part has already been fetched so
we don't optimize that case. kiss. */
@@ -364,12 +364,13 @@ fill_cache (cd, ex_info, offset, bytes, pc)
/* Subroutine of extract_normal. */
static CGEN_INLINE long
-extract_1 (cd, ex_info, start, length, word_length, bufp, pc)
- CGEN_CPU_DESC cd;
- CGEN_EXTRACT_INFO *ex_info ATTRIBUTE_UNUSED;
- int start,length,word_length;
- unsigned char *bufp;
- bfd_vma pc ATTRIBUTE_UNUSED;
+extract_1 (CGEN_CPU_DESC cd,
+ CGEN_EXTRACT_INFO *ex_info ATTRIBUTE_UNUSED,
+ int start,
+ int length,
+ int word_length,
+ unsigned char *bufp,
+ bfd_vma pc ATTRIBUTE_UNUSED)
{
unsigned long x;
int shift;
@@ -408,23 +409,25 @@ extract_1 (cd, ex_info, start, length, word_length, bufp, pc)
necessary. */
static int
-extract_normal (cd, ex_info, insn_value, attrs, word_offset, start, length,
- word_length, total_length, pc, valuep)
- CGEN_CPU_DESC cd;
+extract_normal (CGEN_CPU_DESC cd,
#if ! CGEN_INT_INSN_P
- CGEN_EXTRACT_INFO *ex_info;
+ CGEN_EXTRACT_INFO *ex_info,
#else
- CGEN_EXTRACT_INFO *ex_info ATTRIBUTE_UNUSED;
+ CGEN_EXTRACT_INFO *ex_info ATTRIBUTE_UNUSED,
#endif
- CGEN_INSN_INT insn_value;
- unsigned int attrs;
- unsigned int word_offset, start, length, word_length, total_length;
+ CGEN_INSN_INT insn_value,
+ unsigned int attrs,
+ unsigned int word_offset,
+ unsigned int start,
+ unsigned int length,
+ unsigned int word_length,
+ unsigned int total_length,
#if ! CGEN_INT_INSN_P
- bfd_vma pc;
+ bfd_vma pc,
#else
- bfd_vma pc ATTRIBUTE_UNUSED;
+ bfd_vma pc ATTRIBUTE_UNUSED,
#endif
- long *valuep;
+ long *valuep)
{
long value, mask;
@@ -505,13 +508,12 @@ extract_normal (cd, ex_info, insn_value, attrs, word_offset, start, length,
been called). */
static int
-extract_insn_normal (cd, insn, ex_info, insn_value, fields, pc)
- CGEN_CPU_DESC cd;
- const CGEN_INSN *insn;
- CGEN_EXTRACT_INFO *ex_info;
- CGEN_INSN_INT insn_value;
- CGEN_FIELDS *fields;
- bfd_vma pc;
+extract_insn_normal (CGEN_CPU_DESC cd,
+ const CGEN_INSN *insn,
+ CGEN_EXTRACT_INFO *ex_info,
+ CGEN_INSN_INT insn_value,
+ CGEN_FIELDS *fields,
+ bfd_vma pc)
{
const CGEN_SYNTAX *syntax = CGEN_INSN_SYNTAX (insn);
const CGEN_SYNTAX_CHAR_TYPE *syn;
diff --git a/contrib/binutils/opcodes/cgen-opc.c b/contrib/binutils/opcodes/cgen-opc.c
index 06544ca..882b348 100644
--- a/contrib/binutils/opcodes/cgen-opc.c
+++ b/contrib/binutils/opcodes/cgen-opc.c
@@ -33,11 +33,11 @@
#endif
static unsigned int hash_keyword_name
- PARAMS ((const CGEN_KEYWORD *, const char *, int));
+ (const CGEN_KEYWORD *, const char *, int);
static unsigned int hash_keyword_value
- PARAMS ((const CGEN_KEYWORD *, unsigned int));
+ (const CGEN_KEYWORD *, unsigned int);
static void build_keyword_hash_tables
- PARAMS ((CGEN_KEYWORD *));
+ (CGEN_KEYWORD *);
/* Return number of hash table entries to use for N elements. */
#define KEYWORD_HASH_SIZE(n) ((n) <= 31 ? 17 : 31)
@@ -46,9 +46,7 @@ static void build_keyword_hash_tables
The result is the keyword entry or NULL if not found. */
const CGEN_KEYWORD_ENTRY *
-cgen_keyword_lookup_name (kt, name)
- CGEN_KEYWORD *kt;
- const char *name;
+cgen_keyword_lookup_name (CGEN_KEYWORD *kt, const char *name)
{
const CGEN_KEYWORD_ENTRY *ke;
const char *p,*n;
@@ -87,9 +85,7 @@ cgen_keyword_lookup_name (kt, name)
The result is the keyword entry or NULL if not found. */
const CGEN_KEYWORD_ENTRY *
-cgen_keyword_lookup_value (kt, value)
- CGEN_KEYWORD *kt;
- int value;
+cgen_keyword_lookup_value (CGEN_KEYWORD *kt, int value)
{
const CGEN_KEYWORD_ENTRY *ke;
@@ -111,9 +107,7 @@ cgen_keyword_lookup_value (kt, value)
/* Add an entry to a keyword table. */
void
-cgen_keyword_add (kt, ke)
- CGEN_KEYWORD *kt;
- CGEN_KEYWORD_ENTRY *ke;
+cgen_keyword_add (CGEN_KEYWORD *kt, CGEN_KEYWORD_ENTRY *ke)
{
unsigned int hash;
size_t i;
@@ -159,9 +153,7 @@ cgen_keyword_add (kt, ke)
It is passed to each call to cgen_keyword_search_next. */
CGEN_KEYWORD_SEARCH
-cgen_keyword_search_init (kt, spec)
- CGEN_KEYWORD *kt;
- const char *spec;
+cgen_keyword_search_init (CGEN_KEYWORD *kt, const char *spec)
{
CGEN_KEYWORD_SEARCH search;
@@ -183,8 +175,7 @@ cgen_keyword_search_init (kt, spec)
The result is the next entry or NULL if there are no more. */
const CGEN_KEYWORD_ENTRY *
-cgen_keyword_search_next (search)
- CGEN_KEYWORD_SEARCH *search;
+cgen_keyword_search_next (CGEN_KEYWORD_SEARCH *search)
{
/* Has search finished? */
if (search->current_hash == search->table->hash_table_size)
@@ -218,10 +209,9 @@ cgen_keyword_search_next (search)
If CASE_SENSITIVE_P is non-zero, return a case sensitive hash. */
static unsigned int
-hash_keyword_name (kt, name, case_sensitive_p)
- const CGEN_KEYWORD *kt;
- const char *name;
- int case_sensitive_p;
+hash_keyword_name (const CGEN_KEYWORD *kt,
+ const char *name,
+ int case_sensitive_p)
{
unsigned int hash;
@@ -237,9 +227,7 @@ hash_keyword_name (kt, name, case_sensitive_p)
/* Return first entry in hash chain for VALUE. */
static unsigned int
-hash_keyword_value (kt, value)
- const CGEN_KEYWORD *kt;
- unsigned int value;
+hash_keyword_value (const CGEN_KEYWORD *kt, unsigned int value)
{
return value % kt->hash_table_size;
}
@@ -249,8 +237,7 @@ hash_keyword_value (kt, value)
we're using the disassembler, but we keep things simple. */
static void
-build_keyword_hash_tables (kt)
- CGEN_KEYWORD *kt;
+build_keyword_hash_tables (CGEN_KEYWORD *kt)
{
int i;
/* Use the number of compiled in entries as an estimate for the
@@ -278,9 +265,7 @@ build_keyword_hash_tables (kt)
mach/isa. */
const CGEN_HW_ENTRY *
-cgen_hw_lookup_by_name (cd, name)
- CGEN_CPU_DESC cd;
- const char *name;
+cgen_hw_lookup_by_name (CGEN_CPU_DESC cd, const char *name)
{
unsigned int i;
const CGEN_HW_ENTRY **hw = cd->hw_table.entries;
@@ -298,9 +283,7 @@ cgen_hw_lookup_by_name (cd, name)
Returns NULL if HWNUM is not supported by the currently selected mach. */
const CGEN_HW_ENTRY *
-cgen_hw_lookup_by_num (cd, hwnum)
- CGEN_CPU_DESC cd;
- unsigned int hwnum;
+cgen_hw_lookup_by_num (CGEN_CPU_DESC cd, unsigned int hwnum)
{
unsigned int i;
const CGEN_HW_ENTRY **hw = cd->hw_table.entries;
@@ -320,9 +303,7 @@ cgen_hw_lookup_by_num (cd, hwnum)
mach/isa. */
const CGEN_OPERAND *
-cgen_operand_lookup_by_name (cd, name)
- CGEN_CPU_DESC cd;
- const char *name;
+cgen_operand_lookup_by_name (CGEN_CPU_DESC cd, const char *name)
{
unsigned int i;
const CGEN_OPERAND **op = cd->operand_table.entries;
@@ -341,9 +322,7 @@ cgen_operand_lookup_by_name (cd, name)
mach/isa. */
const CGEN_OPERAND *
-cgen_operand_lookup_by_num (cd, opnum)
- CGEN_CPU_DESC cd;
- int opnum;
+cgen_operand_lookup_by_num (CGEN_CPU_DESC cd, int opnum)
{
return cd->operand_table.entries[opnum];
}
@@ -353,8 +332,7 @@ cgen_operand_lookup_by_num (cd, opnum)
/* Return number of instructions. This includes any added at runtime. */
int
-cgen_insn_count (cd)
- CGEN_CPU_DESC cd;
+cgen_insn_count (CGEN_CPU_DESC cd)
{
int count = cd->insn_table.num_init_entries;
CGEN_INSN_LIST *rt_insns = cd->insn_table.new_entries;
@@ -369,8 +347,7 @@ cgen_insn_count (cd)
This includes any added at runtime. */
int
-cgen_macro_insn_count (cd)
- CGEN_CPU_DESC cd;
+cgen_macro_insn_count (CGEN_CPU_DESC cd)
{
int count = cd->macro_insn_table.num_init_entries;
CGEN_INSN_LIST *rt_insns = cd->macro_insn_table.new_entries;
@@ -384,10 +361,7 @@ cgen_macro_insn_count (cd)
/* Cover function to read and properly byteswap an insn value. */
CGEN_INSN_INT
-cgen_get_insn_value (cd, buf, length)
- CGEN_CPU_DESC cd;
- unsigned char *buf;
- int length;
+cgen_get_insn_value (CGEN_CPU_DESC cd, unsigned char *buf, int length)
{
int big_p = (cd->insn_endian == CGEN_ENDIAN_BIG);
int insn_chunk_bitsize = cd->insn_chunk_bitsize;
@@ -423,11 +397,10 @@ cgen_get_insn_value (cd, buf, length)
/* Cover function to store an insn value properly byteswapped. */
void
-cgen_put_insn_value (cd, buf, length, value)
- CGEN_CPU_DESC cd;
- unsigned char *buf;
- int length;
- CGEN_INSN_INT value;
+cgen_put_insn_value (CGEN_CPU_DESC cd,
+ unsigned char *buf,
+ int length,
+ CGEN_INSN_INT value)
{
int big_p = (cd->insn_endian == CGEN_ENDIAN_BIG);
int insn_chunk_bitsize = cd->insn_chunk_bitsize;
@@ -472,16 +445,14 @@ cgen_put_insn_value (cd, buf, length, value)
/* ??? Will need to be revisited for VLIW architectures. */
const CGEN_INSN *
-cgen_lookup_insn (cd, insn, insn_int_value, insn_bytes_value, length, fields,
- alias_p)
- CGEN_CPU_DESC cd;
- const CGEN_INSN *insn;
- CGEN_INSN_INT insn_int_value;
- /* ??? CGEN_INSN_BYTES would be a nice type name to use here. */
- unsigned char *insn_bytes_value;
- int length;
- CGEN_FIELDS *fields;
- int alias_p;
+cgen_lookup_insn (CGEN_CPU_DESC cd,
+ const CGEN_INSN *insn,
+ CGEN_INSN_INT insn_int_value,
+ /* ??? CGEN_INSN_BYTES would be a nice type name to use here. */
+ unsigned char *insn_bytes_value,
+ int length,
+ CGEN_FIELDS *fields,
+ int alias_p)
{
unsigned char *buf;
CGEN_INSN_INT base_insn;
@@ -571,11 +542,10 @@ cgen_lookup_insn (cd, insn, insn_int_value, insn_bytes_value, length, fields,
in. */
void
-cgen_get_insn_operands (cd, insn, fields, indices)
- CGEN_CPU_DESC cd;
- const CGEN_INSN *insn;
- const CGEN_FIELDS *fields;
- int *indices;
+cgen_get_insn_operands (CGEN_CPU_DESC cd,
+ const CGEN_INSN *insn,
+ const CGEN_FIELDS *fields,
+ int *indices)
{
const CGEN_OPINST *opinst;
int i;
@@ -603,16 +573,14 @@ cgen_get_insn_operands (cd, insn, fields, indices)
recognized. */
const CGEN_INSN *
-cgen_lookup_get_insn_operands (cd, insn, insn_int_value, insn_bytes_value,
- length, indices, fields)
- CGEN_CPU_DESC cd;
- const CGEN_INSN *insn;
- CGEN_INSN_INT insn_int_value;
- /* ??? CGEN_INSN_BYTES would be a nice type name to use here. */
- unsigned char *insn_bytes_value;
- int length;
- int *indices;
- CGEN_FIELDS *fields;
+cgen_lookup_get_insn_operands (CGEN_CPU_DESC cd,
+ const CGEN_INSN *insn,
+ CGEN_INSN_INT insn_int_value,
+ /* ??? CGEN_INSN_BYTES would be a nice type name to use here. */
+ unsigned char *insn_bytes_value,
+ int length,
+ int *indices,
+ CGEN_FIELDS *fields)
{
/* Pass non-zero for ALIAS_P only if INSN != NULL.
If INSN == NULL, we want a real insn. */
@@ -627,24 +595,21 @@ cgen_lookup_get_insn_operands (cd, insn, insn_int_value, insn_bytes_value,
/* Allow signed overflow of instruction fields. */
void
-cgen_set_signed_overflow_ok (cd)
- CGEN_CPU_DESC cd;
+cgen_set_signed_overflow_ok (CGEN_CPU_DESC cd)
{
cd->signed_overflow_ok_p = 1;
}
/* Generate an error message if a signed field in an instruction overflows. */
void
-cgen_clear_signed_overflow_ok (cd)
- CGEN_CPU_DESC cd;
+cgen_clear_signed_overflow_ok (CGEN_CPU_DESC cd)
{
cd->signed_overflow_ok_p = 0;
}
/* Will an error message be generated if a signed field in an instruction overflows ? */
unsigned int
-cgen_signed_overflow_ok_p (cd)
- CGEN_CPU_DESC cd;
+cgen_signed_overflow_ok_p (CGEN_CPU_DESC cd)
{
return cd->signed_overflow_ok_p;
}
diff --git a/contrib/binutils/opcodes/cgen.sh b/contrib/binutils/opcodes/cgen.sh
index a9483bd..5a340b6 100644
--- a/contrib/binutils/opcodes/cgen.sh
+++ b/contrib/binutils/opcodes/cgen.sh
@@ -23,11 +23,19 @@
# arch-asm.c, arch-dis.c, arch-opinst.c, arch-ibld.[ch].
#
# Usage:
-# cgen.sh action srcdir cgen cgendir cgenflags arch prefix options
+# cgen.sh action srcdir cgen cgendir cgenflags arch prefix \
+# arch-file opc-file options [extrafiles]
#
# ACTION is currently always "opcodes". It exists to be consistent with the
# simulator.
-# OPTIONS is comma separated list of options:
+# ARCH is the name of the architecture.
+# It is substituted into @arch@ and @ARCH@ in the generated files.
+# PREFIX is both the generated file prefix and is substituted into
+# @prefix@ in the generated files.
+# ARCH-FILE is the name of the .cpu file (including path).
+# OPC-FILE is the name of the .opc file (including path).
+# OPTIONS is comma separated list of options (???).
+# EXTRAFILES is a space separated list (1 arg still) of extra files to build:
# - opinst - arch-opinst.c is being made, causes semantic analysis
#
# We store the generated files in the source directory until we decide to
@@ -44,11 +52,13 @@ cgendir=$4
cgenflags=$5
arch=$6
prefix=$7
-options=$8
+archfile=$8
+opcfile=$9
+shift ; options=$9
# List of extra files to build.
# Values: opinst (only 1 extra file at present)
-extrafiles=$9
+shift ; extrafiles=$9
rootdir=${srcdir}/..
@@ -88,7 +98,8 @@ opcodes)
${cgenflags} \
-f "${options}" \
-m all \
- -a ${arch} \
+ -a ${archfile} \
+ -OPC ${opcfile} \
-H tmp-desc.h1 \
-C tmp-desc.c1 \
-O tmp-opc.h1 \
diff --git a/contrib/binutils/opcodes/config.in b/contrib/binutils/opcodes/config.in
index 6355be0..5caef55 100644
--- a/contrib/binutils/opcodes/config.in
+++ b/contrib/binutils/opcodes/config.in
@@ -25,9 +25,6 @@
/* Define to `long' if <sys/types.h> doesn't define. */
#undef off_t
-/* Define if you need to in order for stat and other things to work. */
-#undef _POSIX_SOURCE
-
/* Define to `unsigned' if <sys/types.h> doesn't define. */
#undef size_t
@@ -109,12 +106,6 @@
/* Define if you have the <sys/param.h> header file. */
#undef HAVE_SYS_PARAM_H
-/* Define if you have the <sys/stat.h> header file. */
-#undef HAVE_SYS_STAT_H
-
-/* Define if you have the <sys/types.h> header file. */
-#undef HAVE_SYS_TYPES_H
-
/* Define if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
diff --git a/contrib/binutils/opcodes/configure b/contrib/binutils/opcodes/configure
index 93dc228..4a95a9a 100755
--- a/contrib/binutils/opcodes/configure
+++ b/contrib/binutils/opcodes/configure
@@ -33,7 +33,7 @@ ac_help="$ac_help
--enable-maintainer-mode enable make rules and dependencies not useful
(and sometimes confusing) to the casual installer"
ac_help="$ac_help
- --install-libbfd controls installation of libbfd and related headers"
+ --enable-install-libbfd controls installation of libbfd and related headers"
ac_help="$ac_help
--disable-nls do not use Native Language Support"
ac_help="$ac_help
@@ -57,6 +57,7 @@ program_suffix=NONE
program_transform_name=s,x,x,
silent=
site=
+sitefile=
srcdir=
target=NONE
verbose=
@@ -171,6 +172,7 @@ Configuration:
--help print this message
--no-create do not create output files
--quiet, --silent do not print \`checking...' messages
+ --site-file=FILE use FILE as the site file
--version print the version of autoconf that created configure
Directory and file names:
--prefix=PREFIX install architecture-independent files in PREFIX
@@ -341,6 +343,11 @@ EOF
-site=* | --site=* | --sit=*)
site="$ac_optarg" ;;
+ -site-file | --site-file | --site-fil | --site-fi | --site-f)
+ ac_prev=sitefile ;;
+ -site-file=* | --site-file=* | --site-fil=* | --site-fi=* | --site-f=*)
+ sitefile="$ac_optarg" ;;
+
-srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
ac_prev=srcdir ;;
-srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
@@ -506,12 +513,16 @@ fi
srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
# Prefer explicitly selected file to automatically selected ones.
-if test -z "$CONFIG_SITE"; then
- if test "x$prefix" != xNONE; then
- CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
- else
- CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
+if test -z "$sitefile"; then
+ if test -z "$CONFIG_SITE"; then
+ if test "x$prefix" != xNONE; then
+ CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
+ else
+ CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
+ fi
fi
+else
+ CONFIG_SITE="$sitefile"
fi
for ac_site_file in $CONFIG_SITE; do
if test -r "$ac_site_file"; then
@@ -550,12 +561,12 @@ else
fi
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:554: checking for Cygwin environment" >&5
+echo "configure:565: checking for Cygwin environment" >&5
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 559 "configure"
+#line 570 "configure"
#include "confdefs.h"
int main() {
@@ -566,7 +577,7 @@ int main() {
return __CYGWIN__;
; return 0; }
EOF
-if { (eval echo configure:570: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:581: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_cygwin=yes
else
@@ -583,19 +594,19 @@ echo "$ac_t""$ac_cv_cygwin" 1>&6
CYGWIN=
test "$ac_cv_cygwin" = yes && CYGWIN=yes
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:587: checking for mingw32 environment" >&5
+echo "configure:598: checking for mingw32 environment" >&5
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 592 "configure"
+#line 603 "configure"
#include "confdefs.h"
int main() {
return __MINGW32__;
; return 0; }
EOF
-if { (eval echo configure:599: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:610: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_mingw32=yes
else
@@ -660,7 +671,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:664: checking host system type" >&5
+echo "configure:675: checking host system type" >&5
host_alias=$host
case "$host_alias" in
@@ -681,7 +692,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$host" 1>&6
echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:685: checking target system type" >&5
+echo "configure:696: checking target system type" >&5
target_alias=$target
case "$target_alias" in
@@ -699,7 +710,7 @@ target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
echo "$ac_t""$target" 1>&6
echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:703: checking build system type" >&5
+echo "configure:714: checking build system type" >&5
build_alias=$build
case "$build_alias" in
@@ -721,249 +732,49 @@ test "$host_alias" != "$target_alias" &&
NONENONEs,x,x, &&
program_prefix=${target_alias}-
-# Extract the first word of "gcc", so it can be a program name with args.
-set dummy gcc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:728: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_CC="gcc"
- break
- fi
- done
- IFS="$ac_save_ifs"
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
-
-if test -z "$CC"; then
- # Extract the first word of "cc", so it can be a program name with args.
-set dummy cc; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:758: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_prog_rejected=no
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
- ac_prog_rejected=yes
- continue
- fi
- ac_cv_prog_CC="cc"
- break
- fi
- done
- IFS="$ac_save_ifs"
-if test $ac_prog_rejected = yes; then
- # We found a bogon in the path, so make sure we never use it.
- set dummy $ac_cv_prog_CC
- shift
- if test $# -gt 0; then
- # We chose a different compiler from the bogus one.
- # However, it has the same basename, so the bogon will be chosen
- # first if we set CC to just the basename; use the full file name.
- shift
- set dummy "$ac_dir/$ac_word" "$@"
- shift
- ac_cv_prog_CC="$@"
- fi
-fi
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
- if test -z "$CC"; then
- case "`uname -s`" in
- *win32* | *WIN32*)
- # Extract the first word of "cl", so it can be a program name with args.
-set dummy cl; ac_word=$2
-echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:809: checking for $ac_word" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+ echo $ac_n "checking for strerror in -lcposix""... $ac_c" 1>&6
+echo "configure:738: checking for strerror in -lcposix" >&5
+ac_lib_var=`echo cposix'_'strerror | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
- if test -n "$CC"; then
- ac_cv_prog_CC="$CC" # Let the user override the test.
-else
- IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
- ac_dummy="$PATH"
- for ac_dir in $ac_dummy; do
- test -z "$ac_dir" && ac_dir=.
- if test -f $ac_dir/$ac_word; then
- ac_cv_prog_CC="cl"
- break
- fi
- done
- IFS="$ac_save_ifs"
-fi
-fi
-CC="$ac_cv_prog_CC"
-if test -n "$CC"; then
- echo "$ac_t""$CC" 1>&6
-else
- echo "$ac_t""no" 1>&6
-fi
- ;;
- esac
- fi
- test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
-fi
-
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:841: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
-
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-cat > conftest.$ac_ext << EOF
-
-#line 852 "configure"
+ ac_save_LIBS="$LIBS"
+LIBS="-lcposix $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 746 "configure"
#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error. */
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char strerror();
-main(){return(0);}
+int main() {
+strerror()
+; return 0; }
EOF
-if { (eval echo configure:857: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
- ac_cv_prog_cc_works=yes
- # If we can't run a trivial program, we are probably using a cross compiler.
- if (./conftest; exit) 2>/dev/null; then
- ac_cv_prog_cc_cross=no
- else
- ac_cv_prog_cc_cross=yes
- fi
+if { (eval echo configure:757: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ rm -rf conftest*
+ eval "ac_cv_lib_$ac_lib_var=yes"
else
echo "configure: failed program was:" >&5
cat conftest.$ac_ext >&5
- ac_cv_prog_cc_works=no
-fi
-rm -fr conftest*
-ac_ext=c
-# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
-ac_cpp='$CPP $CPPFLAGS'
-ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
-ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
-cross_compiling=$ac_cv_prog_cc_cross
-
-echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
-if test $ac_cv_prog_cc_works = no; then
- { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
-fi
-echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:883: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
-echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
-cross_compiling=$ac_cv_prog_cc_cross
-
-echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:888: checking whether we are using GNU C" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- cat > conftest.c <<EOF
-#ifdef __GNUC__
- yes;
-#endif
-EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:897: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
- ac_cv_prog_gcc=yes
-else
- ac_cv_prog_gcc=no
-fi
-fi
-
-echo "$ac_t""$ac_cv_prog_gcc" 1>&6
-
-if test $ac_cv_prog_gcc = yes; then
- GCC=yes
-else
- GCC=
-fi
-
-ac_test_CFLAGS="${CFLAGS+set}"
-ac_save_CFLAGS="$CFLAGS"
-CFLAGS=
-echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:916: checking whether ${CC-cc} accepts -g" >&5
-if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
-else
- echo 'void f(){}' > conftest.c
-if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
- ac_cv_prog_cc_g=yes
-else
- ac_cv_prog_cc_g=no
+ rm -rf conftest*
+ eval "ac_cv_lib_$ac_lib_var=no"
fi
rm -f conftest*
+LIBS="$ac_save_LIBS"
fi
-
-echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
-if test "$ac_test_CFLAGS" = set; then
- CFLAGS="$ac_save_CFLAGS"
-elif test $ac_cv_prog_cc_g = yes; then
- if test "$GCC" = yes; then
- CFLAGS="-g -O2"
- else
- CFLAGS="-g"
- fi
-else
- if test "$GCC" = yes; then
- CFLAGS="-O2"
- else
- CFLAGS=
- fi
-fi
-
-echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
-echo "configure:948: checking for POSIXized ISC" >&5
-if test -d /etc/conf/kconfig.d &&
- grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
-then
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
- ISC=yes # If later tests want to check for ISC.
- cat >> confdefs.h <<\EOF
-#define _POSIX_SOURCE 1
-EOF
-
- if test "$GCC" = yes; then
- CC="$CC -posix"
- else
- CC="$CC -Xp"
- fi
+ LIBS="$LIBS -lcposix"
else
echo "$ac_t""no" 1>&6
- ISC=
fi
+
+
# We currently only use the version number for the name of any shared
# library. For user convenience, we always use the same version
@@ -982,7 +793,7 @@ BFD_VERSION=`sed -n -e 's/^.._INIT_AUTOMAKE.*,[ ]*\([^ ]*\)[ ]*).*/\1/p' < ${
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:986: checking for a BSD compatible install" >&5
+echo "configure:797: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1035,7 +846,7 @@ test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:1039: checking whether build environment is sane" >&5
+echo "configure:850: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftestfile
@@ -1092,7 +903,7 @@ test "$program_suffix" != NONE &&
test "$program_transform_name" = "" && program_transform_name="s,x,x,"
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:1096: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:907: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1138,7 +949,7 @@ EOF
missing_dir=`cd $ac_aux_dir && pwd`
echo $ac_n "checking for working aclocal""... $ac_c" 1>&6
-echo "configure:1142: checking for working aclocal" >&5
+echo "configure:953: checking for working aclocal" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1151,7 +962,7 @@ else
fi
echo $ac_n "checking for working autoconf""... $ac_c" 1>&6
-echo "configure:1155: checking for working autoconf" >&5
+echo "configure:966: checking for working autoconf" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1164,7 +975,7 @@ else
fi
echo $ac_n "checking for working automake""... $ac_c" 1>&6
-echo "configure:1168: checking for working automake" >&5
+echo "configure:979: checking for working automake" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1177,7 +988,7 @@ else
fi
echo $ac_n "checking for working autoheader""... $ac_c" 1>&6
-echo "configure:1181: checking for working autoheader" >&5
+echo "configure:992: checking for working autoheader" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1190,7 +1001,7 @@ else
fi
echo $ac_n "checking for working makeinfo""... $ac_c" 1>&6
-echo "configure:1194: checking for working makeinfo" >&5
+echo "configure:1005: checking for working makeinfo" >&5
# Run test in a subshell; some versions of sh will print an error if
# an executable is not found, even if stderr is redirected.
# Redirect stdin to placate older versions of autoconf. Sigh.
@@ -1213,7 +1024,7 @@ fi
# Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
set dummy ${ac_tool_prefix}ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1217: checking for $ac_word" >&5
+echo "configure:1028: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1245,7 +1056,7 @@ fi
# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1249: checking for $ac_word" >&5
+echo "configure:1060: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1277,7 +1088,7 @@ if test -n "$ac_tool_prefix"; then
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1281: checking for $ac_word" >&5
+echo "configure:1092: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1380,6 +1191,228 @@ else
enable_fast_install=yes
fi
+# Extract the first word of "gcc", so it can be a program name with args.
+set dummy gcc; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:1198: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$CC"; then
+ ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_CC="gcc"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+CC="$ac_cv_prog_CC"
+if test -n "$CC"; then
+ echo "$ac_t""$CC" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+if test -z "$CC"; then
+ # Extract the first word of "cc", so it can be a program name with args.
+set dummy cc; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:1228: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$CC"; then
+ ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_prog_rejected=no
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
+ ac_prog_rejected=yes
+ continue
+ fi
+ ac_cv_prog_CC="cc"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+if test $ac_prog_rejected = yes; then
+ # We found a bogon in the path, so make sure we never use it.
+ set dummy $ac_cv_prog_CC
+ shift
+ if test $# -gt 0; then
+ # We chose a different compiler from the bogus one.
+ # However, it has the same basename, so the bogon will be chosen
+ # first if we set CC to just the basename; use the full file name.
+ shift
+ set dummy "$ac_dir/$ac_word" "$@"
+ shift
+ ac_cv_prog_CC="$@"
+ fi
+fi
+fi
+fi
+CC="$ac_cv_prog_CC"
+if test -n "$CC"; then
+ echo "$ac_t""$CC" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+
+ if test -z "$CC"; then
+ case "`uname -s`" in
+ *win32* | *WIN32*)
+ # Extract the first word of "cl", so it can be a program name with args.
+set dummy cl; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:1279: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ if test -n "$CC"; then
+ ac_cv_prog_CC="$CC" # Let the user override the test.
+else
+ IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS=":"
+ ac_dummy="$PATH"
+ for ac_dir in $ac_dummy; do
+ test -z "$ac_dir" && ac_dir=.
+ if test -f $ac_dir/$ac_word; then
+ ac_cv_prog_CC="cl"
+ break
+ fi
+ done
+ IFS="$ac_save_ifs"
+fi
+fi
+CC="$ac_cv_prog_CC"
+if test -n "$CC"; then
+ echo "$ac_t""$CC" 1>&6
+else
+ echo "$ac_t""no" 1>&6
+fi
+ ;;
+ esac
+ fi
+ test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
+fi
+
+echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
+echo "configure:1311: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+
+ac_ext=c
+# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
+ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
+cross_compiling=$ac_cv_prog_cc_cross
+
+cat > conftest.$ac_ext << EOF
+
+#line 1322 "configure"
+#include "confdefs.h"
+
+main(){return(0);}
+EOF
+if { (eval echo configure:1327: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ ac_cv_prog_cc_works=yes
+ # If we can't run a trivial program, we are probably using a cross compiler.
+ if (./conftest; exit) 2>/dev/null; then
+ ac_cv_prog_cc_cross=no
+ else
+ ac_cv_prog_cc_cross=yes
+ fi
+else
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+ ac_cv_prog_cc_works=no
+fi
+rm -fr conftest*
+ac_ext=c
+# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
+ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
+cross_compiling=$ac_cv_prog_cc_cross
+
+echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
+if test $ac_cv_prog_cc_works = no; then
+ { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
+fi
+echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
+echo "configure:1353: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
+cross_compiling=$ac_cv_prog_cc_cross
+
+echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
+echo "configure:1358: checking whether we are using GNU C" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ cat > conftest.c <<EOF
+#ifdef __GNUC__
+ yes;
+#endif
+EOF
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1367: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+ ac_cv_prog_gcc=yes
+else
+ ac_cv_prog_gcc=no
+fi
+fi
+
+echo "$ac_t""$ac_cv_prog_gcc" 1>&6
+
+if test $ac_cv_prog_gcc = yes; then
+ GCC=yes
+else
+ GCC=
+fi
+
+ac_test_CFLAGS="${CFLAGS+set}"
+ac_save_CFLAGS="$CFLAGS"
+CFLAGS=
+echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
+echo "configure:1386: checking whether ${CC-cc} accepts -g" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ echo 'void f(){}' > conftest.c
+if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
+ ac_cv_prog_cc_g=yes
+else
+ ac_cv_prog_cc_g=no
+fi
+rm -f conftest*
+
+fi
+
+echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
+if test "$ac_test_CFLAGS" = set; then
+ CFLAGS="$ac_save_CFLAGS"
+elif test $ac_cv_prog_cc_g = yes; then
+ if test "$GCC" = yes; then
+ CFLAGS="-g -O2"
+ else
+ CFLAGS="-g"
+ fi
+else
+ if test "$GCC" = yes; then
+ CFLAGS="-O2"
+ else
+ CFLAGS=
+ fi
+fi
+
# Check whether --with-gnu-ld or --without-gnu-ld was given.
if test "${with_gnu_ld+set}" = set; then
withval="$with_gnu_ld"
@@ -1392,7 +1425,7 @@ ac_prog=ld
if test "$GCC" = yes; then
# Check if gcc -print-prog-name=ld gives a path.
echo $ac_n "checking for ld used by GCC""... $ac_c" 1>&6
-echo "configure:1396: checking for ld used by GCC" >&5
+echo "configure:1429: checking for ld used by GCC" >&5
case $host in
*-*-mingw*)
# gcc leaves a trailing carriage return which upsets mingw
@@ -1422,10 +1455,10 @@ echo "configure:1396: checking for ld used by GCC" >&5
esac
elif test "$with_gnu_ld" = yes; then
echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
-echo "configure:1426: checking for GNU ld" >&5
+echo "configure:1459: checking for GNU ld" >&5
else
echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
-echo "configure:1429: checking for non-GNU ld" >&5
+echo "configure:1462: checking for non-GNU ld" >&5
fi
if eval "test \"`echo '$''{'lt_cv_path_LD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -1460,7 +1493,7 @@ else
fi
test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
-echo "configure:1464: checking if the linker ($LD) is GNU ld" >&5
+echo "configure:1497: checking if the linker ($LD) is GNU ld" >&5
if eval "test \"`echo '$''{'lt_cv_prog_gnu_ld'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1477,7 +1510,7 @@ with_gnu_ld=$lt_cv_prog_gnu_ld
echo $ac_n "checking for $LD option to reload object files""... $ac_c" 1>&6
-echo "configure:1481: checking for $LD option to reload object files" >&5
+echo "configure:1514: checking for $LD option to reload object files" >&5
if eval "test \"`echo '$''{'lt_cv_ld_reload_flag'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1489,7 +1522,7 @@ reload_flag=$lt_cv_ld_reload_flag
test -n "$reload_flag" && reload_flag=" $reload_flag"
echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
-echo "configure:1493: checking for BSD-compatible nm" >&5
+echo "configure:1526: checking for BSD-compatible nm" >&5
if eval "test \"`echo '$''{'lt_cv_path_NM'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1527,7 +1560,7 @@ NM="$lt_cv_path_NM"
echo "$ac_t""$NM" 1>&6
echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:1531: checking whether ln -s works" >&5
+echo "configure:1564: checking whether ln -s works" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1548,7 +1581,7 @@ else
fi
echo $ac_n "checking how to recognise dependant libraries""... $ac_c" 1>&6
-echo "configure:1552: checking how to recognise dependant libraries" >&5
+echo "configure:1585: checking how to recognise dependant libraries" >&5
if eval "test \"`echo '$''{'lt_cv_deplibs_check_method'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1658,7 +1691,7 @@ irix5* | irix6*)
# This must be Linux ELF.
linux-gnu*)
case $host_cpu in
- alpha* | hppa* | i*86 | powerpc* | sparc* | ia64* )
+ alpha* | mips* | hppa* | i*86 | powerpc* | sparc* | ia64* )
lt_cv_deplibs_check_method=pass_all ;;
*)
# glibc up to 2.1.1 does not perform some relocations on ARM
@@ -1721,13 +1754,13 @@ file_magic_cmd=$lt_cv_file_magic_cmd
deplibs_check_method=$lt_cv_deplibs_check_method
echo $ac_n "checking for object suffix""... $ac_c" 1>&6
-echo "configure:1725: checking for object suffix" >&5
+echo "configure:1758: checking for object suffix" >&5
if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
rm -f conftest*
echo 'int i = 1;' > conftest.$ac_ext
-if { (eval echo configure:1731: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1764: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
for ac_file in conftest.*; do
case $ac_file in
*.c) ;;
@@ -1747,7 +1780,7 @@ ac_objext=$ac_cv_objext
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:1751: checking for executable suffix" >&5
+echo "configure:1784: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1757,10 +1790,10 @@ else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:1761: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:1794: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
- *.c | *.o | *.obj) ;;
+ *.c | *.o | *.obj | *.ilk | *.pdb) ;;
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
esac
done
@@ -1784,7 +1817,7 @@ case $deplibs_check_method in
file_magic*)
if test "$file_magic_cmd" = '$MAGIC_CMD'; then
echo $ac_n "checking for ${ac_tool_prefix}file""... $ac_c" 1>&6
-echo "configure:1788: checking for ${ac_tool_prefix}file" >&5
+echo "configure:1821: checking for ${ac_tool_prefix}file" >&5
if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1846,7 +1879,7 @@ fi
if test -z "$lt_cv_path_MAGIC_CMD"; then
if test -n "$ac_tool_prefix"; then
echo $ac_n "checking for file""... $ac_c" 1>&6
-echo "configure:1850: checking for file" >&5
+echo "configure:1883: checking for file" >&5
if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1917,7 +1950,7 @@ esac
# Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
set dummy ${ac_tool_prefix}ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1921: checking for $ac_word" >&5
+echo "configure:1954: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1949,7 +1982,7 @@ if test -n "$ac_tool_prefix"; then
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1953: checking for $ac_word" >&5
+echo "configure:1986: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1984,7 +2017,7 @@ fi
# Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
set dummy ${ac_tool_prefix}strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1988: checking for $ac_word" >&5
+echo "configure:2021: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2016,7 +2049,7 @@ if test -n "$ac_tool_prefix"; then
# Extract the first word of "strip", so it can be a program name with args.
set dummy strip; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2020: checking for $ac_word" >&5
+echo "configure:2053: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2083,8 +2116,21 @@ test x"$pic_mode" = xno && libtool_flags="$libtool_flags --prefer-non-pic"
case $host in
*-*-irix6*)
# Find out which ABI we are using.
- echo '#line 2087 "configure"' > conftest.$ac_ext
- if { (eval echo configure:2088: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ echo '#line 2120 "configure"' > conftest.$ac_ext
+ if { (eval echo configure:2121: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ if test "$lt_cv_prog_gnu_ld" = yes; then
+ case `/usr/bin/file conftest.$ac_objext` in
+ *32-bit*)
+ LD="${LD-ld} -melf32bsmip"
+ ;;
+ *N32*)
+ LD="${LD-ld} -melf32bmipn32"
+ ;;
+ *64-bit*)
+ LD="${LD-ld} -melf64bmip"
+ ;;
+ esac
+ else
case `/usr/bin/file conftest.$ac_objext` in
*32-bit*)
LD="${LD-ld} -32"
@@ -2096,6 +2142,7 @@ case $host in
LD="${LD-ld} -64"
;;
esac
+ fi
fi
rm -rf conftest*
;;
@@ -2103,7 +2150,7 @@ case $host in
ia64-*-hpux*)
# Find out which ABI we are using.
echo 'int i;' > conftest.$ac_ext
- if { (eval echo configure:2107: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+ if { (eval echo configure:2154: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
case "`/usr/bin/file conftest.o`" in
*ELF-32*)
HPUX_IA64_MODE="32"
@@ -2121,7 +2168,7 @@ ia64-*-hpux*)
SAVE_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS -belf"
echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
-echo "configure:2125: checking whether the C compiler needs -belf" >&5
+echo "configure:2172: checking whether the C compiler needs -belf" >&5
if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2134,14 +2181,14 @@ ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$a
cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext <<EOF
-#line 2138 "configure"
+#line 2185 "configure"
#include "confdefs.h"
int main() {
; return 0; }
EOF
-if { (eval echo configure:2145: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2192: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
lt_cv_cc_needs_belf=yes
else
@@ -2309,7 +2356,7 @@ if test -z "$target" ; then
fi
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:2313: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:2360: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
@@ -2332,13 +2379,13 @@ fi
echo $ac_n "checking whether to install libbfd""... $ac_c" 1>&6
-echo "configure:2336: checking whether to install libbfd" >&5
+echo "configure:2383: checking whether to install libbfd" >&5
# Check whether --enable-install-libbfd or --disable-install-libbfd was given.
if test "${enable_install_libbfd+set}" = set; then
enableval="$enable_install_libbfd"
install_libbfd_p=$enableval
else
- if test "${host}" = "${target}" -o "$enable_shared" = "yes"; then
+ if test "${host}" = "${target}" || test "$enable_shared" = "yes"; then
install_libbfd_p=yes
else
install_libbfd_p=no
@@ -2369,7 +2416,7 @@ fi
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:2373: checking for executable suffix" >&5
+echo "configure:2420: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2379,10 +2426,10 @@ else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:2383: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:2430: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
- *.c | *.o | *.obj) ;;
+ *.c | *.o | *.obj | *.ilk | *.pdb) ;;
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
esac
done
@@ -2405,7 +2452,7 @@ ac_exeext=$EXEEXT
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2409: checking for $ac_word" >&5
+echo "configure:2456: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2435,7 +2482,7 @@ if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2439: checking for $ac_word" >&5
+echo "configure:2486: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2486,7 +2533,7 @@ fi
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2490: checking for $ac_word" >&5
+echo "configure:2537: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2518,7 +2565,7 @@ fi
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:2522: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:2569: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -2529,12 +2576,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
-#line 2533 "configure"
+#line 2580 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:2538: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2585: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
@@ -2560,12 +2607,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:2564: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:2611: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:2569: checking whether we are using GNU C" >&5
+echo "configure:2616: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2574,7 +2621,7 @@ else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2578: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2625: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
@@ -2593,7 +2640,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:2597: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:2644: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2625,9 +2672,9 @@ else
fi
-ALL_LINGUAS="fr sv tr es da de id pt_BR"
+ALL_LINGUAS="fr sv tr es da de id pt_BR ro nl"
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:2631: checking how to run the C preprocessor" >&5
+echo "configure:2678: checking how to run the C preprocessor" >&5
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
@@ -2642,13 +2689,13 @@ else
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp.
cat > conftest.$ac_ext <<EOF
-#line 2646 "configure"
+#line 2693 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2652: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2699: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -2659,13 +2706,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF
-#line 2663 "configure"
+#line 2710 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2669: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2716: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -2676,13 +2723,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -nologo -E"
cat > conftest.$ac_ext <<EOF
-#line 2680 "configure"
+#line 2727 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2686: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2733: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
@@ -2709,7 +2756,7 @@ echo "$ac_t""$CPP" 1>&6
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2713: checking for $ac_word" >&5
+echo "configure:2760: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2737,12 +2784,12 @@ else
fi
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:2741: checking for ANSI C header files" >&5
+echo "configure:2788: checking for ANSI C header files" >&5
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2746 "configure"
+#line 2793 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
@@ -2750,7 +2797,7 @@ else
#include <float.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2754: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2801: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -2767,7 +2814,7 @@ rm -f conftest*
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 2771 "configure"
+#line 2818 "configure"
#include "confdefs.h"
#include <string.h>
EOF
@@ -2785,7 +2832,7 @@ fi
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 2789 "configure"
+#line 2836 "configure"
#include "confdefs.h"
#include <stdlib.h>
EOF
@@ -2806,7 +2853,7 @@ if test "$cross_compiling" = yes; then
:
else
cat > conftest.$ac_ext <<EOF
-#line 2810 "configure"
+#line 2857 "configure"
#include "confdefs.h"
#include <ctype.h>
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -2817,7 +2864,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
exit (0); }
EOF
-if { (eval echo configure:2821: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2868: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
else
@@ -2841,12 +2888,12 @@ EOF
fi
echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:2845: checking for working const" >&5
+echo "configure:2892: checking for working const" >&5
if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2850 "configure"
+#line 2897 "configure"
#include "confdefs.h"
int main() {
@@ -2895,7 +2942,7 @@ ccp = (char const *const *) p;
; return 0; }
EOF
-if { (eval echo configure:2899: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2946: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_const=yes
else
@@ -2916,21 +2963,21 @@ EOF
fi
echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:2920: checking for inline" >&5
+echo "configure:2967: checking for inline" >&5
if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
cat > conftest.$ac_ext <<EOF
-#line 2927 "configure"
+#line 2974 "configure"
#include "confdefs.h"
int main() {
} $ac_kw foo() {
; return 0; }
EOF
-if { (eval echo configure:2934: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2981: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_inline=$ac_kw; break
else
@@ -2956,12 +3003,12 @@ EOF
esac
echo $ac_n "checking for off_t""... $ac_c" 1>&6
-echo "configure:2960: checking for off_t" >&5
+echo "configure:3007: checking for off_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2965 "configure"
+#line 3012 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -2989,12 +3036,12 @@ EOF
fi
echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:2993: checking for size_t" >&5
+echo "configure:3040: checking for size_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2998 "configure"
+#line 3045 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -3024,19 +3071,19 @@ fi
# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
# for constant arguments. Useless!
echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:3028: checking for working alloca.h" >&5
+echo "configure:3075: checking for working alloca.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3033 "configure"
+#line 3080 "configure"
#include "confdefs.h"
#include <alloca.h>
int main() {
char *p = alloca(2 * sizeof(int));
; return 0; }
EOF
-if { (eval echo configure:3040: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3087: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_header_alloca_h=yes
else
@@ -3057,12 +3104,12 @@ EOF
fi
echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:3061: checking for alloca" >&5
+echo "configure:3108: checking for alloca" >&5
if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3066 "configure"
+#line 3113 "configure"
#include "confdefs.h"
#ifdef __GNUC__
@@ -3090,7 +3137,7 @@ int main() {
char *p = (char *) alloca(1);
; return 0; }
EOF
-if { (eval echo configure:3094: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3141: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_func_alloca_works=yes
else
@@ -3122,12 +3169,12 @@ EOF
echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:3126: checking whether alloca needs Cray hooks" >&5
+echo "configure:3173: checking whether alloca needs Cray hooks" >&5
if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3131 "configure"
+#line 3178 "configure"
#include "confdefs.h"
#if defined(CRAY) && ! defined(CRAY2)
webecray
@@ -3152,12 +3199,12 @@ echo "$ac_t""$ac_cv_os_cray" 1>&6
if test $ac_cv_os_cray = yes; then
for ac_func in _getb67 GETB67 getb67; do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3156: checking for $ac_func" >&5
+echo "configure:3203: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3161 "configure"
+#line 3208 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3180,7 +3227,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3184: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3231: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3207,7 +3254,7 @@ done
fi
echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:3211: checking stack direction for C alloca" >&5
+echo "configure:3258: checking stack direction for C alloca" >&5
if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3215,7 +3262,7 @@ else
ac_cv_c_stack_direction=0
else
cat > conftest.$ac_ext <<EOF
-#line 3219 "configure"
+#line 3266 "configure"
#include "confdefs.h"
find_stack_direction ()
{
@@ -3234,7 +3281,7 @@ main ()
exit (find_stack_direction() < 0);
}
EOF
-if { (eval echo configure:3238: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3285: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_stack_direction=1
else
@@ -3255,21 +3302,21 @@ EOF
fi
-for ac_hdr in stdlib.h unistd.h sys/stat.h sys/types.h
+for ac_hdr in unistd.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3263: checking for $ac_hdr" >&5
+echo "configure:3310: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3268 "configure"
+#line 3315 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3273: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3320: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -3298,12 +3345,12 @@ done
for ac_func in getpagesize
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3302: checking for $ac_func" >&5
+echo "configure:3349: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3307 "configure"
+#line 3354 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3326,7 +3373,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3330: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3377: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3351,7 +3398,7 @@ fi
done
echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:3355: checking for working mmap" >&5
+echo "configure:3402: checking for working mmap" >&5
if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3359,7 +3406,7 @@ else
ac_cv_func_mmap_fixed_mapped=no
else
cat > conftest.$ac_ext <<EOF
-#line 3363 "configure"
+#line 3410 "configure"
#include "confdefs.h"
/* Thanks to Mike Haertel and Jim Avera for this test.
@@ -3387,24 +3434,11 @@ else
#include <fcntl.h>
#include <sys/mman.h>
-#if HAVE_SYS_TYPES_H
-# include <sys/types.h>
-#endif
-
-#if HAVE_STDLIB_H
-# include <stdlib.h>
-#endif
-
-#if HAVE_SYS_STAT_H
-# include <sys/stat.h>
-#endif
-
-#if HAVE_UNISTD_H
-# include <unistd.h>
-#endif
-
/* This mess was copied from the GNU getpagesize.h. */
#ifndef HAVE_GETPAGESIZE
+# ifdef HAVE_UNISTD_H
+# include <unistd.h>
+# endif
/* Assume that all systems that can run configure have sys/param.h. */
# ifndef HAVE_SYS_PARAM_H
@@ -3512,7 +3546,7 @@ main()
}
EOF
-if { (eval echo configure:3516: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3550: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_func_mmap_fixed_mapped=yes
else
@@ -3540,17 +3574,17 @@ unistd.h values.h sys/param.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3544: checking for $ac_hdr" >&5
+echo "configure:3578: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3549 "configure"
+#line 3583 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3554: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3588: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -3580,12 +3614,12 @@ done
__argz_count __argz_stringify __argz_next
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3584: checking for $ac_func" >&5
+echo "configure:3618: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3589 "configure"
+#line 3623 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3608,7 +3642,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3612: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3646: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3637,12 +3671,12 @@ done
for ac_func in stpcpy
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3641: checking for $ac_func" >&5
+echo "configure:3675: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3646 "configure"
+#line 3680 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3665,7 +3699,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3669: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3703: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3699,19 +3733,19 @@ EOF
if test $ac_cv_header_locale_h = yes; then
echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
-echo "configure:3703: checking for LC_MESSAGES" >&5
+echo "configure:3737: checking for LC_MESSAGES" >&5
if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3708 "configure"
+#line 3742 "configure"
#include "confdefs.h"
#include <locale.h>
int main() {
return LC_MESSAGES
; return 0; }
EOF
-if { (eval echo configure:3715: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3749: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
am_cv_val_LC_MESSAGES=yes
else
@@ -3732,7 +3766,7 @@ EOF
fi
fi
echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
-echo "configure:3736: checking whether NLS is requested" >&5
+echo "configure:3770: checking whether NLS is requested" >&5
# Check whether --enable-nls or --disable-nls was given.
if test "${enable_nls+set}" = set; then
enableval="$enable_nls"
@@ -3752,7 +3786,7 @@ fi
EOF
echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
-echo "configure:3756: checking whether included gettext is requested" >&5
+echo "configure:3790: checking whether included gettext is requested" >&5
# Check whether --with-included-gettext or --without-included-gettext was given.
if test "${with_included_gettext+set}" = set; then
withval="$with_included_gettext"
@@ -3771,17 +3805,17 @@ fi
ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
-echo "configure:3775: checking for libintl.h" >&5
+echo "configure:3809: checking for libintl.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3780 "configure"
+#line 3814 "configure"
#include "confdefs.h"
#include <libintl.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3785: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3819: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -3798,19 +3832,19 @@ fi
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
-echo "configure:3802: checking for gettext in libc" >&5
+echo "configure:3836: checking for gettext in libc" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3807 "configure"
+#line 3841 "configure"
#include "confdefs.h"
#include <libintl.h>
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:3814: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3848: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libc=yes
else
@@ -3826,7 +3860,7 @@ echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
if test "$gt_cv_func_gettext_libc" != "yes"; then
echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
-echo "configure:3830: checking for bindtextdomain in -lintl" >&5
+echo "configure:3864: checking for bindtextdomain in -lintl" >&5
ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -3834,7 +3868,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lintl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 3838 "configure"
+#line 3872 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -3845,7 +3879,7 @@ int main() {
bindtextdomain()
; return 0; }
EOF
-if { (eval echo configure:3849: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3883: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -3861,19 +3895,19 @@ fi
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
-echo "configure:3865: checking for gettext in libintl" >&5
+echo "configure:3899: checking for gettext in libintl" >&5
if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3870 "configure"
+#line 3904 "configure"
#include "confdefs.h"
int main() {
return (int) gettext ("")
; return 0; }
EOF
-if { (eval echo configure:3877: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3911: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
gt_cv_func_gettext_libintl=yes
else
@@ -3901,7 +3935,7 @@ EOF
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3905: checking for $ac_word" >&5
+echo "configure:3939: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3935,12 +3969,12 @@ fi
for ac_func in dcgettext
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3939: checking for $ac_func" >&5
+echo "configure:3973: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3944 "configure"
+#line 3978 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3963,7 +3997,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3967: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4001: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3990,7 +4024,7 @@ done
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3994: checking for $ac_word" >&5
+echo "configure:4028: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4026,7 +4060,7 @@ fi
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4030: checking for $ac_word" >&5
+echo "configure:4064: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4058,7 +4092,7 @@ else
fi
cat > conftest.$ac_ext <<EOF
-#line 4062 "configure"
+#line 4096 "configure"
#include "confdefs.h"
int main() {
@@ -4066,7 +4100,7 @@ extern int _nl_msg_cat_cntr;
return _nl_msg_cat_cntr
; return 0; }
EOF
-if { (eval echo configure:4070: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:4104: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
CATOBJEXT=.gmo
DATADIRNAME=share
@@ -4098,7 +4132,7 @@ fi
# Extract the first word of "msgfmt", so it can be a program name with args.
set dummy msgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4102: checking for $ac_word" >&5
+echo "configure:4136: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4132,7 +4166,7 @@ fi
# Extract the first word of "gmsgfmt", so it can be a program name with args.
set dummy gmsgfmt; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4136: checking for $ac_word" >&5
+echo "configure:4170: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4168,7 +4202,7 @@ fi
# Extract the first word of "xgettext", so it can be a program name with args.
set dummy xgettext; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4172: checking for $ac_word" >&5
+echo "configure:4206: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4258,7 +4292,7 @@ fi
LINGUAS=
else
echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
-echo "configure:4262: checking for catalogs to be installed" >&5
+echo "configure:4296: checking for catalogs to be installed" >&5
NEW_LINGUAS=
for lang in ${LINGUAS=$ALL_LINGUAS}; do
case "$ALL_LINGUAS" in
@@ -4286,17 +4320,17 @@ echo "configure:4262: checking for catalogs to be installed" >&5
if test "$CATOBJEXT" = ".cat"; then
ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
-echo "configure:4290: checking for linux/version.h" >&5
+echo "configure:4324: checking for linux/version.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4295 "configure"
+#line 4329 "configure"
#include "confdefs.h"
#include <linux/version.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4300: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4334: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -4374,7 +4408,7 @@ if test "x$cross_compiling" = "xno"; then
EXEEXT_FOR_BUILD='$(EXEEXT)'
else
echo $ac_n "checking for build system executable suffix""... $ac_c" 1>&6
-echo "configure:4378: checking for build system executable suffix" >&5
+echo "configure:4412: checking for build system executable suffix" >&5
if eval "test \"`echo '$''{'bfd_cv_build_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4411,7 +4445,7 @@ fi
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:4415: checking for a BSD compatible install" >&5
+echo "configure:4449: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -4468,17 +4502,17 @@ for ac_hdr in string.h strings.h stdlib.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:4472: checking for $ac_hdr" >&5
+echo "configure:4506: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4477 "configure"
+#line 4511 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4482: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4516: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -4614,6 +4648,8 @@ if test x${all_targets} = xfalse ; then
bfd_i860_arch) ta="$ta i860-dis.lo" ;;
bfd_i960_arch) ta="$ta i960-dis.lo" ;;
bfd_ia64_arch) ta="$ta ia64-dis.lo ia64-opc.lo" ;;
+ bfd_ip2k_arch) ta="$ta ip2k-asm.lo ip2k-desc.lo ip2k-dis.lo ip2k-ibld.lo ip2k-opc.lo" using_cgen=yes ;;
+ bfd_iq2000_arch) ta="$ta iq2000-asm.lo iq2000-desc.lo iq2000-dis.lo iq2000-ibld.lo iq2000-opc.lo" using_cgen=yes ;;
bfd_m32r_arch) ta="$ta m32r-asm.lo m32r-desc.lo m32r-dis.lo m32r-ibld.lo m32r-opc.lo m32r-opinst.lo" using_cgen=yes ;;
bfd_m68hc11_arch) ta="$ta m68hc11-dis.lo m68hc11-opc.lo" ;;
bfd_m68hc12_arch) ta="$ta m68hc11-dis.lo m68hc11-opc.lo" ;;
@@ -4624,6 +4660,7 @@ if test x${all_targets} = xfalse ; then
bfd_mmix_arch) ta="$ta mmix-dis.lo mmix-opc.lo" ;;
bfd_mn10200_arch) ta="$ta m10200-dis.lo m10200-opc.lo" ;;
bfd_mn10300_arch) ta="$ta m10300-dis.lo m10300-opc.lo" ;;
+ bfd_msp430_arch) ta="$ta msp430-dis.lo" ;;
bfd_ns32k_arch) ta="$ta ns32k-dis.lo" ;;
bfd_openrisc_arch) ta="$ta openrisc-asm.lo openrisc-desc.lo openrisc-dis.lo openrisc-ibld.lo openrisc-opc.lo" using_cgen=yes ;;
bfd_or32_arch) ta="$ta or32-dis.lo or32-opc.lo" using_cgen=yes ;;
@@ -4653,6 +4690,7 @@ if test x${all_targets} = xfalse ; then
bfd_sparc_arch) ta="$ta sparc-dis.lo sparc-opc.lo" ;;
bfd_tahoe_arch) ;;
bfd_tic30_arch) ta="$ta tic30-dis.lo" ;;
+ bfd_tic4x_arch) ta="$ta tic4x-dis.lo" ;;
bfd_tic54x_arch) ta="$ta tic54x-dis.lo tic54x-opc.lo" ;;
bfd_tic80_arch) ta="$ta tic80-dis.lo tic80-opc.lo" ;;
bfd_v850_arch) ta="$ta v850-opc.lo v850-dis.lo" ;;
@@ -4662,6 +4700,7 @@ if test x${all_targets} = xfalse ; then
bfd_w65_arch) ta="$ta w65-dis.lo" ;;
bfd_we32k_arch) ;;
bfd_xstormy16_arch) ta="$ta xstormy16-asm.lo xstormy16-desc.lo xstormy16-dis.lo xstormy16-ibld.lo xstormy16-opc.lo" using_cgen=yes ;;
+ bfd_xtensa_arch) ta="$ta xtensa-dis.lo" ;;
bfd_z8k_arch) ta="$ta z8k-dis.lo" ;;
bfd_frv_arch) ta="$ta frv-asm.lo frv-desc.lo frv-dis.lo frv-ibld.lo frv-opc.lo" using_cgen=yes ;;
@@ -4852,7 +4891,6 @@ s%@build_alias@%$build_alias%g
s%@build_cpu@%$build_cpu%g
s%@build_vendor@%$build_vendor%g
s%@build_os@%$build_os%g
-s%@CC@%$CC%g
s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
s%@INSTALL_DATA@%$INSTALL_DATA%g
@@ -4866,6 +4904,7 @@ s%@MAKEINFO@%$MAKEINFO%g
s%@SET_MAKE@%$SET_MAKE%g
s%@AR@%$AR%g
s%@RANLIB@%$RANLIB%g
+s%@CC@%$CC%g
s%@LN_S@%$LN_S%g
s%@OBJEXT@%$OBJEXT%g
s%@EXEEXT@%$EXEEXT%g
diff --git a/contrib/binutils/opcodes/configure.in b/contrib/binutils/opcodes/configure.in
index 3183bc7..8919924 100644
--- a/contrib/binutils/opcodes/configure.in
+++ b/contrib/binutils/opcodes/configure.in
@@ -78,7 +78,7 @@ AC_EXEEXT
AC_PROG_CC
-ALL_LINGUAS="fr sv tr es da de id pt_BR"
+ALL_LINGUAS="fr sv tr es da de id pt_BR ro nl"
CY_GNU_GETTEXT
. ${srcdir}/../bfd/configure.host
@@ -189,6 +189,8 @@ if test x${all_targets} = xfalse ; then
bfd_i860_arch) ta="$ta i860-dis.lo" ;;
bfd_i960_arch) ta="$ta i960-dis.lo" ;;
bfd_ia64_arch) ta="$ta ia64-dis.lo ia64-opc.lo" ;;
+ bfd_ip2k_arch) ta="$ta ip2k-asm.lo ip2k-desc.lo ip2k-dis.lo ip2k-ibld.lo ip2k-opc.lo" using_cgen=yes ;;
+ bfd_iq2000_arch) ta="$ta iq2000-asm.lo iq2000-desc.lo iq2000-dis.lo iq2000-ibld.lo iq2000-opc.lo" using_cgen=yes ;;
bfd_m32r_arch) ta="$ta m32r-asm.lo m32r-desc.lo m32r-dis.lo m32r-ibld.lo m32r-opc.lo m32r-opinst.lo" using_cgen=yes ;;
bfd_m68hc11_arch) ta="$ta m68hc11-dis.lo m68hc11-opc.lo" ;;
bfd_m68hc12_arch) ta="$ta m68hc11-dis.lo m68hc11-opc.lo" ;;
@@ -199,6 +201,7 @@ if test x${all_targets} = xfalse ; then
bfd_mmix_arch) ta="$ta mmix-dis.lo mmix-opc.lo" ;;
bfd_mn10200_arch) ta="$ta m10200-dis.lo m10200-opc.lo" ;;
bfd_mn10300_arch) ta="$ta m10300-dis.lo m10300-opc.lo" ;;
+ bfd_msp430_arch) ta="$ta msp430-dis.lo" ;;
bfd_ns32k_arch) ta="$ta ns32k-dis.lo" ;;
bfd_openrisc_arch) ta="$ta openrisc-asm.lo openrisc-desc.lo openrisc-dis.lo openrisc-ibld.lo openrisc-opc.lo" using_cgen=yes ;;
bfd_or32_arch) ta="$ta or32-dis.lo or32-opc.lo" using_cgen=yes ;;
@@ -228,6 +231,7 @@ if test x${all_targets} = xfalse ; then
bfd_sparc_arch) ta="$ta sparc-dis.lo sparc-opc.lo" ;;
bfd_tahoe_arch) ;;
bfd_tic30_arch) ta="$ta tic30-dis.lo" ;;
+ bfd_tic4x_arch) ta="$ta tic4x-dis.lo" ;;
bfd_tic54x_arch) ta="$ta tic54x-dis.lo tic54x-opc.lo" ;;
bfd_tic80_arch) ta="$ta tic80-dis.lo tic80-opc.lo" ;;
bfd_v850_arch) ta="$ta v850-opc.lo v850-dis.lo" ;;
@@ -237,6 +241,7 @@ if test x${all_targets} = xfalse ; then
bfd_w65_arch) ta="$ta w65-dis.lo" ;;
bfd_we32k_arch) ;;
bfd_xstormy16_arch) ta="$ta xstormy16-asm.lo xstormy16-desc.lo xstormy16-dis.lo xstormy16-ibld.lo xstormy16-opc.lo" using_cgen=yes ;;
+ bfd_xtensa_arch) ta="$ta xtensa-dis.lo" ;;
bfd_z8k_arch) ta="$ta z8k-dis.lo" ;;
bfd_frv_arch) ta="$ta frv-asm.lo frv-desc.lo frv-dis.lo frv-ibld.lo frv-opc.lo" using_cgen=yes ;;
diff --git a/contrib/binutils/opcodes/dep-in.sed b/contrib/binutils/opcodes/dep-in.sed
index e373d4c..94da2ad 100644
--- a/contrib/binutils/opcodes/dep-in.sed
+++ b/contrib/binutils/opcodes/dep-in.sed
@@ -10,6 +10,7 @@ s!@TOPDIR@/include!$(INCDIR)!g
s!@BFDDIR@!$(BFDDIR)!g
s!@TOPDIR@/bfd!$(BFDDIR)!g
s!@SRCDIR@/!!g
+s! \.\./intl/libintl\.h!!g
s/\\\n */ /g
diff --git a/contrib/binutils/opcodes/dis-buf.c b/contrib/binutils/opcodes/dis-buf.c
index 8f846a9..83fbfbd 100644
--- a/contrib/binutils/opcodes/dis-buf.c
+++ b/contrib/binutils/opcodes/dis-buf.c
@@ -107,7 +107,7 @@ generic_strcat_address (addr, buf, len)
}
#endif
-/* Just return the given address. */
+/* Just return true. */
int
generic_symbol_at_address (addr, info)
@@ -116,3 +116,12 @@ generic_symbol_at_address (addr, info)
{
return 1;
}
+
+/* Just return TRUE. */
+
+bfd_boolean
+generic_symbol_is_valid (asymbol * sym ATTRIBUTE_UNUSED,
+ struct disassemble_info *info ATTRIBUTE_UNUSED)
+{
+ return TRUE;
+}
diff --git a/contrib/binutils/opcodes/dis-init.c b/contrib/binutils/opcodes/dis-init.c
new file mode 100644
index 0000000..35a5ee7
--- /dev/null
+++ b/contrib/binutils/opcodes/dis-init.c
@@ -0,0 +1,43 @@
+/* Initialize "struct disassemble_info".
+
+ Copyright 2003 Free Software Foundation, Inc.
+
+ This program is free software; you can redistribute it and/or
+ modify it under the terms of the GNU General Public License as
+ published by the Free Software Foundation; either version 2 of the
+ License, or (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful, but
+ WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA. */
+
+#include "sysdep.h"
+#include "dis-asm.h"
+#include "bfd.h"
+
+void
+init_disassemble_info (struct disassemble_info *info, void *stream,
+ fprintf_ftype fprintf_func)
+{
+ memset (info, 0, sizeof (*info));
+
+ info->flavour = bfd_target_unknown_flavour;
+ info->arch = bfd_arch_unknown;
+ info->endian = BFD_ENDIAN_UNKNOWN;
+ info->octets_per_byte = 1;
+ info->fprintf_func = fprintf_func;
+ info->stream = stream;
+ info->read_memory_func = buffer_read_memory;
+ info->memory_error_func = perror_memory;
+ info->print_address_func = generic_print_address;
+ info->symbol_at_address_func = generic_symbol_at_address;
+ info->symbol_is_valid = generic_symbol_is_valid;
+ info->display_endian = BFD_ENDIAN_UNKNOWN;
+}
+
diff --git a/contrib/binutils/opcodes/disassemble.c b/contrib/binutils/opcodes/disassemble.c
index 7c586c7..d5b17be 100644
--- a/contrib/binutils/opcodes/disassemble.c
+++ b/contrib/binutils/opcodes/disassemble.c
@@ -36,6 +36,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define ARCH_i386
#define ARCH_i860
#define ARCH_i960
+#define ARCH_ip2k
#define ARCH_ia64
#define ARCH_fr30
#define ARCH_m32r
@@ -48,6 +49,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define ARCH_mmix
#define ARCH_mn10200
#define ARCH_mn10300
+#define ARCH_msp430
#define ARCH_ns32k
#define ARCH_openrisc
#define ARCH_or32
@@ -59,14 +61,17 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define ARCH_sh
#define ARCH_sparc
#define ARCH_tic30
+#define ARCH_tic4x
#define ARCH_tic54x
#define ARCH_tic80
#define ARCH_v850
#define ARCH_vax
#define ARCH_w65
#define ARCH_xstormy16
+#define ARCH_xtensa
#define ARCH_z8k
#define ARCH_frv
+#define ARCH_iq2000
#define INCLUDE_SHMEDIA
#endif
@@ -136,9 +141,12 @@ disassembler (abfd)
#endif
#ifdef ARCH_h8300
case bfd_arch_h8300:
- if (bfd_get_mach(abfd) == bfd_mach_h8300h)
+ if (bfd_get_mach (abfd) == bfd_mach_h8300h
+ || bfd_get_mach (abfd) == bfd_mach_h8300hn)
disassemble = print_insn_h8300h;
- else if (bfd_get_mach(abfd) == bfd_mach_h8300s)
+ else if (bfd_get_mach (abfd) == bfd_mach_h8300s
+ || bfd_get_mach (abfd) == bfd_mach_h8300sn
+ || bfd_get_mach (abfd) == bfd_mach_h8300sx)
disassemble = print_insn_h8300s;
else
disassemble = print_insn_h8300;
@@ -179,6 +187,11 @@ disassembler (abfd)
disassemble = print_insn_ia64;
break;
#endif
+#ifdef ARCH_ip2k
+ case bfd_arch_ip2k:
+ disassemble = print_insn_ip2k;
+ break;
+#endif
#ifdef ARCH_fr30
case bfd_arch_fr30:
disassemble = print_insn_fr30;
@@ -207,6 +220,11 @@ disassembler (abfd)
disassemble = print_insn_m88k;
break;
#endif
+#ifdef ARCH_msp430
+ case bfd_arch_msp430:
+ disassemble = print_insn_msp430;
+ break;
+#endif
#ifdef ARCH_ns32k
case bfd_arch_ns32k:
disassemble = print_insn_ns32k;
@@ -299,6 +317,11 @@ disassembler (abfd)
disassemble = print_insn_tic30;
break;
#endif
+#ifdef ARCH_tic4x
+ case bfd_arch_tic4x:
+ disassemble = print_insn_tic4x;
+ break;
+#endif
#ifdef ARCH_tic54x
case bfd_arch_tic54x:
disassemble = print_insn_tic54x;
@@ -324,6 +347,11 @@ disassembler (abfd)
disassemble = print_insn_xstormy16;
break;
#endif
+#ifdef ARCH_xtensa
+ case bfd_arch_xtensa:
+ disassemble = print_insn_xtensa;
+ break;
+#endif
#ifdef ARCH_z8k
case bfd_arch_z8k:
if (bfd_get_mach(abfd) == bfd_mach_z8001)
@@ -342,6 +370,11 @@ disassembler (abfd)
disassemble = print_insn_frv;
break;
#endif
+#ifdef ARCH_iq2000
+ case bfd_arch_iq2000:
+ disassemble = print_insn_iq2000;
+ break;
+#endif
default:
return 0;
}
@@ -355,9 +388,30 @@ disassembler_usage (stream)
#ifdef ARCH_arm
print_arm_disassembler_options (stream);
#endif
+#ifdef ARCH_mips
+ print_mips_disassembler_options (stream);
+#endif
#ifdef ARCH_powerpc
print_ppc_disassembler_options (stream);
#endif
return;
}
+
+void
+disassemble_init_for_target (struct disassemble_info * info)
+{
+ if (info == NULL)
+ return;
+
+ switch (info->arch)
+ {
+#ifdef ARCH_arm
+ case bfd_arch_arm:
+ info->symbol_is_valid = arm_symbol_is_valid;
+ break;
+#endif
+ default:
+ break;
+ }
+}
diff --git a/contrib/binutils/opcodes/i386-dis.c b/contrib/binutils/opcodes/i386-dis.c
index d2271d8..a71eb0c 100644
--- a/contrib/binutils/opcodes/i386-dis.c
+++ b/contrib/binutils/opcodes/i386-dis.c
@@ -1,7 +1,6 @@
/* Print i386 instructions for GDB, the GNU debugger.
Copyright 1988, 1989, 1991, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2001
- Free Software Foundation, Inc.
+ 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
This file is part of GDB.
@@ -24,6 +23,7 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
* July 1988
* modified by John Hassey (hassey@dg-rtp.dg.com)
* x86-64 support added by Jan Hubicka (jh@suse.cz)
+ * VIA PadLock support by Michal Ludvig (mludvig@suse.cz)
*/
/*
@@ -49,52 +49,58 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#define UNIXWARE_COMPAT 1
#endif
-static int fetch_data PARAMS ((struct disassemble_info *, bfd_byte *));
-static void ckprefix PARAMS ((void));
-static const char *prefix_name PARAMS ((int, int));
-static int print_insn PARAMS ((bfd_vma, disassemble_info *));
-static void dofloat PARAMS ((int));
-static void OP_ST PARAMS ((int, int));
-static void OP_STi PARAMS ((int, int));
-static int putop PARAMS ((const char *, int));
-static void oappend PARAMS ((const char *));
-static void append_seg PARAMS ((void));
-static void OP_indirE PARAMS ((int, int));
-static void print_operand_value PARAMS ((char *, int, bfd_vma));
-static void OP_E PARAMS ((int, int));
-static void OP_G PARAMS ((int, int));
-static bfd_vma get64 PARAMS ((void));
-static bfd_signed_vma get32 PARAMS ((void));
-static bfd_signed_vma get32s PARAMS ((void));
-static int get16 PARAMS ((void));
-static void set_op PARAMS ((bfd_vma, int));
-static void OP_REG PARAMS ((int, int));
-static void OP_IMREG PARAMS ((int, int));
-static void OP_I PARAMS ((int, int));
-static void OP_I64 PARAMS ((int, int));
-static void OP_sI PARAMS ((int, int));
-static void OP_J PARAMS ((int, int));
-static void OP_SEG PARAMS ((int, int));
-static void OP_DIR PARAMS ((int, int));
-static void OP_OFF PARAMS ((int, int));
-static void OP_OFF64 PARAMS ((int, int));
-static void ptr_reg PARAMS ((int, int));
-static void OP_ESreg PARAMS ((int, int));
-static void OP_DSreg PARAMS ((int, int));
-static void OP_C PARAMS ((int, int));
-static void OP_D PARAMS ((int, int));
-static void OP_T PARAMS ((int, int));
-static void OP_Rd PARAMS ((int, int));
-static void OP_MMX PARAMS ((int, int));
-static void OP_XMM PARAMS ((int, int));
-static void OP_EM PARAMS ((int, int));
-static void OP_EX PARAMS ((int, int));
-static void OP_MS PARAMS ((int, int));
-static void OP_XS PARAMS ((int, int));
-static void OP_3DNowSuffix PARAMS ((int, int));
-static void OP_SIMD_Suffix PARAMS ((int, int));
-static void SIMD_Fixup PARAMS ((int, int));
-static void BadOp PARAMS ((void));
+static int fetch_data (struct disassemble_info *, bfd_byte *);
+static void ckprefix (void);
+static const char *prefix_name (int, int);
+static int print_insn (bfd_vma, disassemble_info *);
+static void dofloat (int);
+static void OP_ST (int, int);
+static void OP_STi (int, int);
+static int putop (const char *, int);
+static void oappend (const char *);
+static void append_seg (void);
+static void OP_indirE (int, int);
+static void print_operand_value (char *, int, bfd_vma);
+static void OP_E (int, int);
+static void OP_G (int, int);
+static bfd_vma get64 (void);
+static bfd_signed_vma get32 (void);
+static bfd_signed_vma get32s (void);
+static int get16 (void);
+static void set_op (bfd_vma, int);
+static void OP_REG (int, int);
+static void OP_IMREG (int, int);
+static void OP_I (int, int);
+static void OP_I64 (int, int);
+static void OP_sI (int, int);
+static void OP_J (int, int);
+static void OP_SEG (int, int);
+static void OP_DIR (int, int);
+static void OP_OFF (int, int);
+static void OP_OFF64 (int, int);
+static void ptr_reg (int, int);
+static void OP_ESreg (int, int);
+static void OP_DSreg (int, int);
+static void OP_C (int, int);
+static void OP_D (int, int);
+static void OP_T (int, int);
+static void OP_Rd (int, int);
+static void OP_MMX (int, int);
+static void OP_XMM (int, int);
+static void OP_EM (int, int);
+static void OP_EX (int, int);
+static void OP_MS (int, int);
+static void OP_XS (int, int);
+static void OP_M (int, int);
+static void OP_0fae (int, int);
+static void OP_0f07 (int, int);
+static void NOP_Fixup (int, int);
+static void OP_3DNowSuffix (int, int);
+static void OP_SIMD_Suffix (int, int);
+static void SIMD_Fixup (int, int);
+static void PNI_Fixup (int, int);
+static void INVLPG_Fixup (int, int);
+static void BadOp (void);
struct dis_private {
/* Points to first byte not fetched. */
@@ -161,9 +167,7 @@ static int used_prefixes;
? 1 : fetch_data ((info), (addr)))
static int
-fetch_data (info, addr)
- struct disassemble_info *info;
- bfd_byte *addr;
+fetch_data (struct disassemble_info *info, bfd_byte *addr)
{
int status;
struct dis_private *priv = (struct dis_private *) info->private_data;
@@ -176,9 +180,9 @@ fetch_data (info, addr)
if (status != 0)
{
/* If we did manage to read at least one byte, then
- print_insn_i386 will do something sensible. Otherwise, print
- an error. We do that here because this is where we know
- STATUS. */
+ print_insn_i386 will do something sensible. Otherwise, print
+ an error. We do that here because this is where we know
+ STATUS. */
if (priv->max_fetched == priv->the_buffer)
(*info->memory_error_func) (status, start, info);
longjmp (priv->bailout, 1);
@@ -193,12 +197,13 @@ fetch_data (info, addr)
#define Eb OP_E, b_mode
#define Ev OP_E, v_mode
#define Ed OP_E, d_mode
+#define Edq OP_E, dq_mode
#define indirEb OP_indirE, b_mode
#define indirEv OP_indirE, v_mode
#define Ew OP_E, w_mode
#define Ma OP_E, v_mode
-#define M OP_E, 0 /* lea, lgdt, etc. */
-#define Mp OP_E, 0 /* 32 or 48 bit memory operand for LDS, LES etc */
+#define M OP_M, 0 /* lea, lgdt, etc. */
+#define Mp OP_M, 0 /* 32 or 48 bit memory operand for LDS, LES etc */
#define Gb OP_G, b_mode
#define Gv OP_G, v_mode
#define Gd OP_G, d_mode
@@ -291,7 +296,6 @@ fetch_data (info, addr)
#define EX OP_EX, v_mode
#define MS OP_MS, v_mode
#define XS OP_XS, v_mode
-#define None OP_E, 0
#define OPSUF OP_3DNowSuffix, 0
#define OPSIMD OP_SIMD_Suffix, 0
@@ -312,6 +316,7 @@ fetch_data (info, addr)
#define m_mode 7 /* d_mode in 32bit, q_mode in 64bit mode. */
#define cond_jump_mode 8
#define loop_jcxz_mode 9
+#define dq_mode 10 /* operand size depends on REX prefixes. */
#define es_reg 100
#define cs_reg 101
@@ -388,6 +393,7 @@ fetch_data (info, addr)
#define GRP13 NULL, NULL, USE_GROUPS, NULL, 20, NULL, 0
#define GRP14 NULL, NULL, USE_GROUPS, NULL, 21, NULL, 0
#define GRPAMD NULL, NULL, USE_GROUPS, NULL, 22, NULL, 0
+#define GRPPADLCK NULL, NULL, USE_GROUPS, NULL, 23, NULL, 0
#define PREGRP0 NULL, NULL, USE_PREFIX_USER_TABLE, NULL, 0, NULL, 0
#define PREGRP1 NULL, NULL, USE_PREFIX_USER_TABLE, NULL, 1, NULL, 0
@@ -416,10 +422,16 @@ fetch_data (info, addr)
#define PREGRP24 NULL, NULL, USE_PREFIX_USER_TABLE, NULL, 24, NULL, 0
#define PREGRP25 NULL, NULL, USE_PREFIX_USER_TABLE, NULL, 25, NULL, 0
#define PREGRP26 NULL, NULL, USE_PREFIX_USER_TABLE, NULL, 26, NULL, 0
+#define PREGRP27 NULL, NULL, USE_PREFIX_USER_TABLE, NULL, 27, NULL, 0
+#define PREGRP28 NULL, NULL, USE_PREFIX_USER_TABLE, NULL, 28, NULL, 0
+#define PREGRP29 NULL, NULL, USE_PREFIX_USER_TABLE, NULL, 29, NULL, 0
+#define PREGRP30 NULL, NULL, USE_PREFIX_USER_TABLE, NULL, 30, NULL, 0
+#define PREGRP31 NULL, NULL, USE_PREFIX_USER_TABLE, NULL, 31, NULL, 0
+#define PREGRP32 NULL, NULL, USE_PREFIX_USER_TABLE, NULL, 32, NULL, 0
#define X86_64_0 NULL, NULL, X86_64_SPECIAL, NULL, 0, NULL, 0
-typedef void (*op_rtn) PARAMS ((int bytemode, int sizeflag));
+typedef void (*op_rtn) (int bytemode, int sizeflag);
struct dis386 {
const char *name;
@@ -625,8 +637,7 @@ static const struct dis386 dis386[] = {
{ "movQ", Sw, Ev, XX },
{ "popU", Ev, XX, XX },
/* 90 */
- { "nop", XX, XX, XX },
- /* FIXME: NOP with REPz prefix is called PAUSE. */
+ { "nop", NOP_Fixup, 0, XX, XX },
{ "xchgS", RMeCX, eAX, XX },
{ "xchgS", RMeDX, eAX, XX },
{ "xchgS", RMeBX, eAX, XX },
@@ -735,7 +746,7 @@ static const struct dis386 dis386[] = {
{ "outS", indirDX, eAX, XX },
/* f0 */
{ "(bad)", XX, XX, XX }, /* lock prefix */
- { "(bad)", XX, XX, XX },
+ { "icebp", XX, XX, XX },
{ "(bad)", XX, XX, XX }, /* repne */
{ "(bad)", XX, XX, XX }, /* repz */
{ "hlt", XX, XX, XX },
@@ -775,11 +786,11 @@ static const struct dis386 dis386_twobyte[] = {
/* 10 */
{ PREGRP8 },
{ PREGRP9 },
- { "movlpX", XM, EX, SIMD_Fixup, 'h' }, /* really only 2 operands */
+ { PREGRP30 },
{ "movlpX", EX, XM, SIMD_Fixup, 'h' },
{ "unpcklpX", XM, EX, XX },
{ "unpckhpX", XM, EX, XX },
- { "movhpX", XM, EX, SIMD_Fixup, 'l' },
+ { PREGRP31 },
{ "movhpX", EX, XM, SIMD_Fixup, 'l' },
/* 18 */
{ GRP14 },
@@ -878,7 +889,7 @@ static const struct dis386 dis386_twobyte[] = {
{ "packssdw", MX, EM, XX },
{ PREGRP26 },
{ PREGRP24 },
- { "movd", MX, Ed, XX },
+ { "movd", MX, Edq, XX },
{ PREGRP19 },
/* 70 */
{ PREGRP22 },
@@ -894,8 +905,8 @@ static const struct dis386 dis386_twobyte[] = {
{ "(bad)", XX, XX, XX },
{ "(bad)", XX, XX, XX },
{ "(bad)", XX, XX, XX },
- { "(bad)", XX, XX, XX },
- { "(bad)", XX, XX, XX },
+ { PREGRP28 },
+ { PREGRP29 },
{ PREGRP23 },
{ PREGRP20 },
/* 80 */
@@ -942,7 +953,7 @@ static const struct dis386 dis386_twobyte[] = {
{ "shldS", Ev, Gv, Ib },
{ "shldS", Ev, Gv, CL },
{ "(bad)", XX, XX, XX },
- { "(bad)", XX, XX, XX },
+ { GRPPADLCK },
/* a8 */
{ "pushT", gs, XX, XX },
{ "popT", gs, XX, XX },
@@ -989,7 +1000,7 @@ static const struct dis386 dis386_twobyte[] = {
{ "bswap", RMeSI, XX, XX },
{ "bswap", RMeDI, XX, XX },
/* d0 */
- { "(bad)", XX, XX, XX },
+ { PREGRP27 },
{ "psrlw", MX, EM, XX },
{ "psrld", MX, EM, XX },
{ "psrlq", MX, EM, XX },
@@ -1025,7 +1036,7 @@ static const struct dis386 dis386_twobyte[] = {
{ "pmaxsw", MX, EM, XX },
{ "pxor", MX, EM, XX },
/* f0 */
- { "(bad)", XX, XX, XX },
+ { PREGRP32 },
{ "psllw", MX, EM, XX },
{ "pslld", MX, EM, XX },
{ "psllq", MX, EM, XX },
@@ -1077,15 +1088,15 @@ static const unsigned char twobyte_has_modrm[256] = {
/* 40 */ 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, /* 4f */
/* 50 */ 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, /* 5f */
/* 60 */ 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, /* 6f */
- /* 70 */ 1,1,1,1,1,1,1,0,0,0,0,0,0,0,1,1, /* 7f */
+ /* 70 */ 1,1,1,1,1,1,1,0,0,0,0,0,1,1,1,1, /* 7f */
/* 80 */ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* 8f */
/* 90 */ 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, /* 9f */
- /* a0 */ 0,0,0,1,1,1,0,0,0,0,0,1,1,1,1,1, /* af */
+ /* a0 */ 0,0,0,1,1,1,0,1,0,0,0,1,1,1,1,1, /* af */
/* b0 */ 1,1,1,1,1,1,1,1,0,0,1,1,1,1,1,1, /* bf */
/* c0 */ 1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,0, /* cf */
- /* d0 */ 0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, /* df */
+ /* d0 */ 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, /* df */
/* e0 */ 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1, /* ef */
- /* f0 */ 0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0 /* ff */
+ /* f0 */ 1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0 /* ff */
/* ------------------------------- */
/* 0 1 2 3 4 5 6 7 8 9 a b c d e f */
};
@@ -1094,21 +1105,21 @@ static const unsigned char twobyte_uses_SSE_prefix[256] = {
/* 0 1 2 3 4 5 6 7 8 9 a b c d e f */
/* ------------------------------- */
/* 00 */ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* 0f */
- /* 10 */ 1,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* 1f */
+ /* 10 */ 1,1,1,0,0,0,1,0,0,0,0,0,0,0,0,0, /* 1f */
/* 20 */ 0,0,0,0,0,0,0,0,0,0,1,0,1,1,0,0, /* 2f */
/* 30 */ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* 3f */
/* 40 */ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* 4f */
/* 50 */ 0,1,1,1,0,0,0,0,1,1,1,1,1,1,1,1, /* 5f */
/* 60 */ 0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1, /* 6f */
- /* 70 */ 1,0,0,0,0,0,0,0,0,0,0,0,0,0,1,1, /* 7f */
+ /* 70 */ 1,0,0,0,0,0,0,0,0,0,0,0,1,1,1,1, /* 7f */
/* 80 */ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* 8f */
/* 90 */ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* 9f */
/* a0 */ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* af */
/* b0 */ 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, /* bf */
/* c0 */ 0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0, /* cf */
- /* d0 */ 0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0, /* df */
+ /* d0 */ 1,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0, /* df */
/* e0 */ 0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0, /* ef */
- /* f0 */ 0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0 /* ff */
+ /* f0 */ 1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0 /* ff */
/* ------------------------------- */
/* 0 1 2 3 4 5 6 7 8 9 a b c d e f */
};
@@ -1348,13 +1359,13 @@ static const struct dis386 grps[][8] = {
/* GRP7 */
{
{ "sgdtQ", M, XX, XX },
- { "sidtQ", M, XX, XX },
+ { "sidtQ", PNI_Fixup, 0, XX, XX },
{ "lgdtQ", M, XX, XX },
{ "lidtQ", M, XX, XX },
{ "smswQ", Ev, XX, XX },
{ "(bad)", XX, XX, XX },
{ "lmsw", Ew, XX, XX },
- { "invlpg", Ew, XX, XX },
+ { "invlpg", INVLPG_Fixup, w_mode, XX, XX },
},
/* GRP8 */
{
@@ -1418,10 +1429,9 @@ static const struct dis386 grps[][8] = {
{ "ldmxcsr", Ev, XX, XX },
{ "stmxcsr", Ev, XX, XX },
{ "(bad)", XX, XX, XX },
- { "lfence", None, XX, XX },
- { "mfence", None, XX, XX },
- { "sfence", None, XX, XX },
- /* FIXME: the sfence with memory operand is clflush! */
+ { "lfence", OP_0fae, 0, XX, XX },
+ { "mfence", OP_0fae, 0, XX, XX },
+ { "clflush", OP_0fae, 0, XX, XX },
},
/* GRP14 */
{
@@ -1444,6 +1454,17 @@ static const struct dis386 grps[][8] = {
{ "(bad)", XX, XX, XX },
{ "(bad)", XX, XX, XX },
{ "(bad)", XX, XX, XX },
+ },
+ /* GRPPADLCK */
+ {
+ { "xstorerng", OP_0f07, 0, XX, XX },
+ { "xcryptecb", OP_0f07, 0, XX, XX },
+ { "xcryptcbc", OP_0f07, 0, XX, XX },
+ { "(bad)", OP_0f07, 0, XX, XX },
+ { "xcryptcfb", OP_0f07, 0, XX, XX },
+ { "xcryptofb", OP_0f07, 0, XX, XX },
+ { "(bad)", OP_0f07, 0, XX, XX },
+ { "(bad)", OP_0f07, 0, XX, XX },
}
};
@@ -1611,9 +1632,9 @@ static const struct dis386 prefix_user_table[][4] = {
},
/* PREGRP23 */
{
- { "movd", Ed, MX, XX },
+ { "movd", Edq, MX, XX },
{ "movq", XM, EX, XX },
- { "movd", Ed, XM, XX },
+ { "movd", Edq, XM, XX },
{ "(bad)", Ed, XM, XX },
},
/* PREGRP24 */
@@ -1637,6 +1658,48 @@ static const struct dis386 prefix_user_table[][4] = {
{ "punpcklqdq", XM, EX, XX },
{ "(bad)", XM, EX, XX },
},
+ /* PREGRP27 */
+ {
+ { "(bad)", MX, EX, XX },
+ { "(bad)", XM, EX, XX },
+ { "addsubpd", XM, EX, XX },
+ { "addsubps", XM, EX, XX },
+ },
+ /* PREGRP28 */
+ {
+ { "(bad)", MX, EX, XX },
+ { "(bad)", XM, EX, XX },
+ { "haddpd", XM, EX, XX },
+ { "haddps", XM, EX, XX },
+ },
+ /* PREGRP29 */
+ {
+ { "(bad)", MX, EX, XX },
+ { "(bad)", XM, EX, XX },
+ { "hsubpd", XM, EX, XX },
+ { "hsubps", XM, EX, XX },
+ },
+ /* PREGRP30 */
+ {
+ { "movlpX", XM, EX, SIMD_Fixup, 'h' }, /* really only 2 operands */
+ { "movsldup", XM, EX, XX },
+ { "movlpd", XM, EX, XX },
+ { "movddup", XM, EX, XX },
+ },
+ /* PREGRP31 */
+ {
+ { "movhpX", XM, EX, SIMD_Fixup, 'l' },
+ { "movshdup", XM, EX, XX },
+ { "movhpd", XM, EX, XX },
+ { "(bad)", XM, EX, XX },
+ },
+ /* PREGRP32 */
+ {
+ { "(bad)", XM, EX, XX },
+ { "(bad)", XM, EX, XX },
+ { "(bad)", XM, EX, XX },
+ { "lddqu", XM, M, XX },
+ },
};
static const struct dis386 x86_64_table[][2] = {
@@ -1649,7 +1712,7 @@ static const struct dis386 x86_64_table[][2] = {
#define INTERNAL_DISASSEMBLER_ERROR _("<internal disassembler error>")
static void
-ckprefix ()
+ckprefix (void)
{
int newrex;
rex = 0;
@@ -1747,9 +1810,7 @@ ckprefix ()
prefix byte. */
static const char *
-prefix_name (pref, sizeflag)
- int pref;
- int sizeflag;
+prefix_name (int pref, int sizeflag)
{
switch (pref)
{
@@ -1808,9 +1869,9 @@ prefix_name (pref, sizeflag)
return (sizeflag & DFLAG) ? "data16" : "data32";
case 0x67:
if (mode_64bit)
- return (sizeflag & AFLAG) ? "addr32" : "addr64";
+ return (sizeflag & AFLAG) ? "addr32" : "addr64";
else
- return ((sizeflag & AFLAG) && !mode_64bit) ? "addr16" : "addr32";
+ return ((sizeflag & AFLAG) && !mode_64bit) ? "addr16" : "addr32";
case FWAIT_OPCODE:
return "fwait";
default:
@@ -1843,9 +1904,7 @@ static char scale_char;
print_insn_i386_att and print_insn_i386_intel these functions can
disappear, and print_insn_i386 be merged into print_insn. */
int
-print_insn_i386_att (pc, info)
- bfd_vma pc;
- disassemble_info *info;
+print_insn_i386_att (bfd_vma pc, disassemble_info *info)
{
intel_syntax = 0;
@@ -1853,9 +1912,7 @@ print_insn_i386_att (pc, info)
}
int
-print_insn_i386_intel (pc, info)
- bfd_vma pc;
- disassemble_info *info;
+print_insn_i386_intel (bfd_vma pc, disassemble_info *info)
{
intel_syntax = 1;
@@ -1863,9 +1920,7 @@ print_insn_i386_intel (pc, info)
}
int
-print_insn_i386 (pc, info)
- bfd_vma pc;
- disassemble_info *info;
+print_insn_i386 (bfd_vma pc, disassemble_info *info)
{
intel_syntax = -1;
@@ -1873,9 +1928,7 @@ print_insn_i386 (pc, info)
}
static int
-print_insn (pc, info)
- bfd_vma pc;
- disassemble_info *info;
+print_insn (bfd_vma pc, disassemble_info *info)
{
const struct dis386 *dp;
int i;
@@ -1890,7 +1943,7 @@ print_insn (pc, info)
mode_64bit = (info->mach == bfd_mach_x86_64_intel_syntax
|| info->mach == bfd_mach_x86_64);
- if (intel_syntax == -1)
+ if (intel_syntax == (char) -1)
intel_syntax = (info->mach == bfd_mach_i386_i386_intel_syntax
|| info->mach == bfd_mach_x86_64_intel_syntax);
@@ -1984,7 +2037,7 @@ print_insn (pc, info)
puts most long word instructions on a single line. */
info->bytes_per_line = 7;
- info->private_data = (PTR) &priv;
+ info->private_data = &priv;
priv.max_fetched = priv.the_buffer;
priv.insn_start = pc;
@@ -2040,7 +2093,7 @@ print_insn (pc, info)
const char *name;
/* fwait not followed by floating point instruction. Print the
- first prefix, which is probably fwait itself. */
+ first prefix, which is probably fwait itself. */
name = prefix_name (priv.the_buffer[0], priv.orig_sizeflag);
if (name == NULL)
name = INTERNAL_DISASSEMBLER_ERROR;
@@ -2273,7 +2326,7 @@ static const char *float_mem[] = {
"fsubr{s||s|}",
"fdiv{s||s|}",
"fdivr{s||s|}",
- /* d9 */
+ /* d9 */
"fld{s||s|}",
"(bad)",
"fst{s||s|}",
@@ -2293,7 +2346,7 @@ static const char *float_mem[] = {
"fidivr{l||l|}",
/* db */
"fild{l||l|}",
- "(bad)",
+ "fisttp{l||l|}",
"fist{l||l|}",
"fistp{l||l|}",
"(bad)",
@@ -2311,7 +2364,7 @@ static const char *float_mem[] = {
"fdivr{l||l|}",
/* dd */
"fld{l||l|}",
- "(bad)",
+ "fisttpll",
"fst{l||l|}",
"fstp{l||l|}",
"frstor",
@@ -2329,7 +2382,7 @@ static const char *float_mem[] = {
"fidivr",
/* df */
"fild",
- "(bad)",
+ "fisttp",
"fist",
"fistp",
"fbld",
@@ -2505,8 +2558,7 @@ static char *fgrps[][8] = {
};
static void
-dofloat (sizeflag)
- int sizeflag;
+dofloat (int sizeflag)
{
const struct dis386 *dp;
unsigned char floatop;
@@ -2518,11 +2570,11 @@ dofloat (sizeflag)
putop (float_mem[(floatop - 0xd8) * 8 + reg], sizeflag);
obufp = op1out;
if (floatop == 0xdb)
- OP_E (x_mode, sizeflag);
+ OP_E (x_mode, sizeflag);
else if (floatop == 0xdd)
- OP_E (d_mode, sizeflag);
+ OP_E (d_mode, sizeflag);
else
- OP_E (v_mode, sizeflag);
+ OP_E (v_mode, sizeflag);
return;
}
/* Skip mod/rm byte. */
@@ -2552,17 +2604,13 @@ dofloat (sizeflag)
}
static void
-OP_ST (bytemode, sizeflag)
- int bytemode ATTRIBUTE_UNUSED;
- int sizeflag ATTRIBUTE_UNUSED;
+OP_ST (int bytemode ATTRIBUTE_UNUSED, int sizeflag ATTRIBUTE_UNUSED)
{
oappend ("%st");
}
static void
-OP_STi (bytemode, sizeflag)
- int bytemode ATTRIBUTE_UNUSED;
- int sizeflag ATTRIBUTE_UNUSED;
+OP_STi (int bytemode ATTRIBUTE_UNUSED, int sizeflag ATTRIBUTE_UNUSED)
{
sprintf (scratchbuf, "%%st(%d)", rm);
oappend (scratchbuf + intel_syntax);
@@ -2570,9 +2618,7 @@ OP_STi (bytemode, sizeflag)
/* Capital letters in template are macros. */
static int
-putop (template, sizeflag)
- const char *template;
- int sizeflag;
+putop (const char *template, int sizeflag)
{
const char *p;
int alt;
@@ -2617,14 +2663,14 @@ putop (template, sizeflag)
case '}':
break;
case 'A':
- if (intel_syntax)
- break;
+ if (intel_syntax)
+ break;
if (mod != 3 || (sizeflag & SUFFIX_ALWAYS))
*obufp++ = 'b';
break;
case 'B':
- if (intel_syntax)
- break;
+ if (intel_syntax)
+ break;
if (sizeflag & SUFFIX_ALWAYS)
*obufp++ = 'b';
break;
@@ -2642,8 +2688,8 @@ putop (template, sizeflag)
used_prefixes |= (prefixes & PREFIX_ADDR);
break;
case 'F':
- if (intel_syntax)
- break;
+ if (intel_syntax)
+ break;
if ((prefixes & PREFIX_ADDR) || (sizeflag & SUFFIX_ALWAYS))
{
if (sizeflag & AFLAG)
@@ -2654,8 +2700,8 @@ putop (template, sizeflag)
}
break;
case 'H':
- if (intel_syntax)
- break;
+ if (intel_syntax)
+ break;
if ((prefixes & (PREFIX_CS | PREFIX_DS)) == PREFIX_CS
|| (prefixes & (PREFIX_CS | PREFIX_DS)) == PREFIX_DS)
{
@@ -2669,8 +2715,8 @@ putop (template, sizeflag)
}
break;
case 'L':
- if (intel_syntax)
- break;
+ if (intel_syntax)
+ break;
if (sizeflag & SUFFIX_ALWAYS)
*obufp++ = 'l';
break;
@@ -2688,8 +2734,8 @@ putop (template, sizeflag)
*obufp++ = 'd';
break;
case 'T':
- if (intel_syntax)
- break;
+ if (intel_syntax)
+ break;
if (mode_64bit)
{
*obufp++ = 'q';
@@ -2697,8 +2743,8 @@ putop (template, sizeflag)
}
/* Fall through. */
case 'P':
- if (intel_syntax)
- break;
+ if (intel_syntax)
+ break;
if ((prefixes & PREFIX_DATA)
|| (rex & REX_MODE64)
|| (sizeflag & SUFFIX_ALWAYS))
@@ -2717,8 +2763,8 @@ putop (template, sizeflag)
}
break;
case 'U':
- if (intel_syntax)
- break;
+ if (intel_syntax)
+ break;
if (mode_64bit)
{
*obufp++ = 'q';
@@ -2726,8 +2772,8 @@ putop (template, sizeflag)
}
/* Fall through. */
case 'Q':
- if (intel_syntax)
- break;
+ if (intel_syntax)
+ break;
USED_REX (REX_MODE64);
if (mod != 3 || (sizeflag & SUFFIX_ALWAYS))
{
@@ -2745,7 +2791,7 @@ putop (template, sizeflag)
break;
case 'R':
USED_REX (REX_MODE64);
- if (intel_syntax)
+ if (intel_syntax)
{
if (rex & REX_MODE64)
{
@@ -2776,8 +2822,8 @@ putop (template, sizeflag)
used_prefixes |= (prefixes & PREFIX_DATA);
break;
case 'S':
- if (intel_syntax)
- break;
+ if (intel_syntax)
+ break;
if (sizeflag & SUFFIX_ALWAYS)
{
if (rex & REX_MODE64)
@@ -2797,11 +2843,11 @@ putop (template, sizeflag)
*obufp++ = 'd';
else
*obufp++ = 's';
- used_prefixes |= (prefixes & PREFIX_DATA);
+ used_prefixes |= (prefixes & PREFIX_DATA);
break;
case 'Y':
- if (intel_syntax)
- break;
+ if (intel_syntax)
+ break;
if (rex & REX_MODE64)
{
USED_REX (REX_MODE64);
@@ -2818,7 +2864,7 @@ putop (template, sizeflag)
*obufp++ = 'w';
else
*obufp++ = 'b';
- if (intel_syntax)
+ if (intel_syntax)
{
if (rex)
{
@@ -2845,15 +2891,14 @@ putop (template, sizeflag)
}
static void
-oappend (s)
- const char *s;
+oappend (const char *s)
{
strcpy (obufp, s);
obufp += strlen (s);
}
static void
-append_seg ()
+append_seg (void)
{
if (prefixes & PREFIX_CS)
{
@@ -2888,9 +2933,7 @@ append_seg ()
}
static void
-OP_indirE (bytemode, sizeflag)
- int bytemode;
- int sizeflag;
+OP_indirE (int bytemode, int sizeflag)
{
if (!intel_syntax)
oappend ("*");
@@ -2898,10 +2941,7 @@ OP_indirE (bytemode, sizeflag)
}
static void
-print_operand_value (buf, hex, disp)
- char *buf;
- int hex;
- bfd_vma disp;
+print_operand_value (char *buf, int hex, bfd_vma disp)
{
if (mode_64bit)
{
@@ -2958,9 +2998,7 @@ print_operand_value (buf, hex, disp)
}
static void
-OP_E (bytemode, sizeflag)
- int bytemode;
- int sizeflag;
+OP_E (int bytemode, int sizeflag)
{
bfd_vma disp;
int add = 0;
@@ -3000,20 +3038,17 @@ OP_E (bytemode, sizeflag)
oappend (names32[rm + add]);
break;
case v_mode:
+ case dq_mode:
USED_REX (REX_MODE64);
if (rex & REX_MODE64)
oappend (names64[rm + add]);
- else if (sizeflag & DFLAG)
+ else if ((sizeflag & DFLAG) || bytemode == dq_mode)
oappend (names32[rm + add]);
else
oappend (names16[rm + add]);
used_prefixes |= (prefixes & PREFIX_DATA);
break;
case 0:
- if (!(codep[-2] == 0xAE && codep[-1] == 0xF8 /* sfence */)
- && !(codep[-2] == 0xAE && codep[-1] == 0xF0 /* mfence */)
- && !(codep[-2] == 0xAE && codep[-1] == 0xe8 /* lfence */))
- BadOp (); /* bad sfence,lea,lds,les,lfs,lgs,lss modrm */
break;
default:
oappend (INTERNAL_DISASSEMBLER_ERROR);
@@ -3076,52 +3111,52 @@ OP_E (bytemode, sizeflag)
}
if (!intel_syntax)
- if (mod != 0 || (base & 7) == 5)
- {
+ if (mod != 0 || (base & 7) == 5)
+ {
print_operand_value (scratchbuf, !riprel, disp);
- oappend (scratchbuf);
+ oappend (scratchbuf);
if (riprel)
{
set_op (disp, 1);
oappend ("(%rip)");
}
- }
+ }
if (havebase || (havesib && (index != 4 || scale != 0)))
{
- if (intel_syntax)
- {
- switch (bytemode)
- {
- case b_mode:
- oappend ("BYTE PTR ");
- break;
- case w_mode:
- oappend ("WORD PTR ");
- break;
- case v_mode:
- oappend ("DWORD PTR ");
- break;
- case d_mode:
- oappend ("QWORD PTR ");
- break;
- case m_mode:
+ if (intel_syntax)
+ {
+ switch (bytemode)
+ {
+ case b_mode:
+ oappend ("BYTE PTR ");
+ break;
+ case w_mode:
+ oappend ("WORD PTR ");
+ break;
+ case v_mode:
+ oappend ("DWORD PTR ");
+ break;
+ case d_mode:
+ oappend ("QWORD PTR ");
+ break;
+ case m_mode:
if (mode_64bit)
oappend ("DWORD PTR ");
else
oappend ("QWORD PTR ");
break;
- case x_mode:
- oappend ("XWORD PTR ");
- break;
- default:
- break;
- }
- }
+ case x_mode:
+ oappend ("XWORD PTR ");
+ break;
+ default:
+ break;
+ }
+ }
*obufp++ = open_char;
if (intel_syntax && riprel)
oappend ("rip + ");
- *obufp = '\0';
+ *obufp = '\0';
USED_REX (REX_EXTZ);
if (!havesib && (rex & REX_EXTZ))
base += 8;
@@ -3132,41 +3167,37 @@ OP_E (bytemode, sizeflag)
{
if (index != 4)
{
- if (intel_syntax)
- {
- if (havebase)
- {
- *obufp++ = separator_char;
- *obufp = '\0';
- }
- sprintf (scratchbuf, "%s",
+ if (intel_syntax)
+ {
+ if (havebase)
+ {
+ *obufp++ = separator_char;
+ *obufp = '\0';
+ }
+ sprintf (scratchbuf, "%s",
mode_64bit && (sizeflag & AFLAG)
? names64[index] : names32[index]);
- }
- else
+ }
+ else
sprintf (scratchbuf, ",%s",
mode_64bit && (sizeflag & AFLAG)
? names64[index] : names32[index]);
oappend (scratchbuf);
}
- if (!intel_syntax
- || (intel_syntax
- && bytemode != b_mode
- && bytemode != w_mode
- && bytemode != v_mode))
- {
- *obufp++ = scale_char;
- *obufp = '\0';
- sprintf (scratchbuf, "%d", 1 << scale);
- oappend (scratchbuf);
- }
+ if (scale != 0 || (!intel_syntax && index != 4))
+ {
+ *obufp++ = scale_char;
+ *obufp = '\0';
+ sprintf (scratchbuf, "%d", 1 << scale);
+ oappend (scratchbuf);
+ }
}
- if (intel_syntax)
- if (mod != 0 || (base & 7) == 5)
- {
+ if (intel_syntax)
+ if (mod != 0 || (base & 7) == 5)
+ {
/* Don't print zero displacements. */
- if (disp != 0)
- {
+ if (disp != 0)
+ {
if ((bfd_signed_vma) disp > 0)
{
*obufp++ = '+';
@@ -3174,17 +3205,17 @@ OP_E (bytemode, sizeflag)
}
print_operand_value (scratchbuf, 0, disp);
- oappend (scratchbuf);
- }
- }
+ oappend (scratchbuf);
+ }
+ }
*obufp++ = close_char;
- *obufp = '\0';
+ *obufp = '\0';
}
else if (intel_syntax)
- {
- if (mod != 0 || (base & 7) == 5)
- {
+ {
+ if (mod != 0 || (base & 7) == 5)
+ {
if (prefixes & (PREFIX_CS | PREFIX_SS | PREFIX_DS
| PREFIX_ES | PREFIX_FS | PREFIX_GS))
;
@@ -3194,9 +3225,9 @@ OP_E (bytemode, sizeflag)
oappend (":");
}
print_operand_value (scratchbuf, 1, disp);
- oappend (scratchbuf);
- }
- }
+ oappend (scratchbuf);
+ }
+ }
}
else
{ /* 16 bit address mode */
@@ -3224,27 +3255,25 @@ OP_E (bytemode, sizeflag)
}
if (!intel_syntax)
- if (mod != 0 || (rm & 7) == 6)
- {
+ if (mod != 0 || (rm & 7) == 6)
+ {
print_operand_value (scratchbuf, 0, disp);
- oappend (scratchbuf);
- }
+ oappend (scratchbuf);
+ }
if (mod != 0 || (rm & 7) != 6)
{
*obufp++ = open_char;
- *obufp = '\0';
+ *obufp = '\0';
oappend (index16[rm + add]);
- *obufp++ = close_char;
- *obufp = '\0';
+ *obufp++ = close_char;
+ *obufp = '\0';
}
}
}
static void
-OP_G (bytemode, sizeflag)
- int bytemode;
- int sizeflag;
+OP_G (int bytemode, int sizeflag)
{
int add = 0;
USED_REX (REX_EXTX);
@@ -3285,7 +3314,7 @@ OP_G (bytemode, sizeflag)
}
static bfd_vma
-get64 ()
+get64 (void)
{
bfd_vma x;
#ifdef BFD64
@@ -3310,7 +3339,7 @@ get64 ()
}
static bfd_signed_vma
-get32 ()
+get32 (void)
{
bfd_signed_vma x = 0;
@@ -3323,7 +3352,7 @@ get32 ()
}
static bfd_signed_vma
-get32s ()
+get32s (void)
{
bfd_signed_vma x = 0;
@@ -3339,7 +3368,7 @@ get32s ()
}
static int
-get16 ()
+get16 (void)
{
int x = 0;
@@ -3350,9 +3379,7 @@ get16 ()
}
static void
-set_op (op, riprel)
- bfd_vma op;
- int riprel;
+set_op (bfd_vma op, int riprel)
{
op_index[op_ad] = op_ad;
if (mode_64bit)
@@ -3369,9 +3396,7 @@ set_op (op, riprel)
}
static void
-OP_REG (code, sizeflag)
- int code;
- int sizeflag;
+OP_REG (int code, int sizeflag)
{
const char *s;
int add = 0;
@@ -3383,9 +3408,9 @@ OP_REG (code, sizeflag)
{
case indir_dx_reg:
if (intel_syntax)
- s = "[dx]";
+ s = "[dx]";
else
- s = "(%dx)";
+ s = "(%dx)";
break;
case ax_reg: case cx_reg: case dx_reg: case bx_reg:
case sp_reg: case bp_reg: case si_reg: case di_reg:
@@ -3431,9 +3456,7 @@ OP_REG (code, sizeflag)
}
static void
-OP_IMREG (code, sizeflag)
- int code;
- int sizeflag;
+OP_IMREG (int code, int sizeflag)
{
const char *s;
@@ -3441,9 +3464,9 @@ OP_IMREG (code, sizeflag)
{
case indir_dx_reg:
if (intel_syntax)
- s = "[dx]";
+ s = "[dx]";
else
- s = "(%dx)";
+ s = "(%dx)";
break;
case ax_reg: case cx_reg: case dx_reg: case bx_reg:
case sp_reg: case bp_reg: case si_reg: case di_reg:
@@ -3480,9 +3503,7 @@ OP_IMREG (code, sizeflag)
}
static void
-OP_I (bytemode, sizeflag)
- int bytemode;
- int sizeflag;
+OP_I (int bytemode, int sizeflag)
{
bfd_signed_vma op;
bfd_signed_vma mask = -1;
@@ -3534,9 +3555,7 @@ OP_I (bytemode, sizeflag)
}
static void
-OP_I64 (bytemode, sizeflag)
- int bytemode;
- int sizeflag;
+OP_I64 (int bytemode, int sizeflag)
{
bfd_signed_vma op;
bfd_signed_vma mask = -1;
@@ -3587,9 +3606,7 @@ OP_I64 (bytemode, sizeflag)
}
static void
-OP_sI (bytemode, sizeflag)
- int bytemode;
- int sizeflag;
+OP_sI (int bytemode, int sizeflag)
{
bfd_signed_vma op;
bfd_signed_vma mask = -1;
@@ -3638,9 +3655,7 @@ OP_sI (bytemode, sizeflag)
}
static void
-OP_J (bytemode, sizeflag)
- int bytemode;
- int sizeflag;
+OP_J (int bytemode, int sizeflag)
{
bfd_vma disp;
bfd_vma mask = -1;
@@ -3676,17 +3691,13 @@ OP_J (bytemode, sizeflag)
}
static void
-OP_SEG (dummy, sizeflag)
- int dummy ATTRIBUTE_UNUSED;
- int sizeflag ATTRIBUTE_UNUSED;
+OP_SEG (int dummy ATTRIBUTE_UNUSED, int sizeflag ATTRIBUTE_UNUSED)
{
oappend (names_seg[reg]);
}
static void
-OP_DIR (dummy, sizeflag)
- int dummy ATTRIBUTE_UNUSED;
- int sizeflag;
+OP_DIR (int dummy ATTRIBUTE_UNUSED, int sizeflag)
{
int seg, offset;
@@ -3709,9 +3720,7 @@ OP_DIR (dummy, sizeflag)
}
static void
-OP_OFF (bytemode, sizeflag)
- int bytemode ATTRIBUTE_UNUSED;
- int sizeflag;
+OP_OFF (int bytemode ATTRIBUTE_UNUSED, int sizeflag)
{
bfd_vma off;
@@ -3725,7 +3734,7 @@ OP_OFF (bytemode, sizeflag)
if (intel_syntax)
{
if (!(prefixes & (PREFIX_CS | PREFIX_SS | PREFIX_DS
- | PREFIX_ES | PREFIX_FS | PREFIX_GS)))
+ | PREFIX_ES | PREFIX_FS | PREFIX_GS)))
{
oappend (names_seg[ds_reg - es_reg]);
oappend (":");
@@ -3736,9 +3745,7 @@ OP_OFF (bytemode, sizeflag)
}
static void
-OP_OFF64 (bytemode, sizeflag)
- int bytemode ATTRIBUTE_UNUSED;
- int sizeflag ATTRIBUTE_UNUSED;
+OP_OFF64 (int bytemode ATTRIBUTE_UNUSED, int sizeflag ATTRIBUTE_UNUSED)
{
bfd_vma off;
@@ -3755,7 +3762,7 @@ OP_OFF64 (bytemode, sizeflag)
if (intel_syntax)
{
if (!(prefixes & (PREFIX_CS | PREFIX_SS | PREFIX_DS
- | PREFIX_ES | PREFIX_FS | PREFIX_GS)))
+ | PREFIX_ES | PREFIX_FS | PREFIX_GS)))
{
oappend (names_seg[ds_reg - es_reg]);
oappend (":");
@@ -3766,9 +3773,7 @@ OP_OFF64 (bytemode, sizeflag)
}
static void
-ptr_reg (code, sizeflag)
- int code;
- int sizeflag;
+ptr_reg (int code, int sizeflag)
{
const char *s;
if (intel_syntax)
@@ -3780,9 +3785,9 @@ ptr_reg (code, sizeflag)
if (rex & REX_MODE64)
{
if (!(sizeflag & AFLAG))
- s = names32[code - eAX_reg];
+ s = names32[code - eAX_reg];
else
- s = names64[code - eAX_reg];
+ s = names64[code - eAX_reg];
}
else if (sizeflag & AFLAG)
s = names32[code - eAX_reg];
@@ -3796,18 +3801,14 @@ ptr_reg (code, sizeflag)
}
static void
-OP_ESreg (code, sizeflag)
- int code;
- int sizeflag;
+OP_ESreg (int code, int sizeflag)
{
oappend ("%es:" + intel_syntax);
ptr_reg (code, sizeflag);
}
static void
-OP_DSreg (code, sizeflag)
- int code;
- int sizeflag;
+OP_DSreg (int code, int sizeflag)
{
if ((prefixes
& (PREFIX_CS
@@ -3822,9 +3823,7 @@ OP_DSreg (code, sizeflag)
}
static void
-OP_C (dummy, sizeflag)
- int dummy ATTRIBUTE_UNUSED;
- int sizeflag ATTRIBUTE_UNUSED;
+OP_C (int dummy ATTRIBUTE_UNUSED, int sizeflag ATTRIBUTE_UNUSED)
{
int add = 0;
USED_REX (REX_EXTX);
@@ -3835,9 +3834,7 @@ OP_C (dummy, sizeflag)
}
static void
-OP_D (dummy, sizeflag)
- int dummy ATTRIBUTE_UNUSED;
- int sizeflag ATTRIBUTE_UNUSED;
+OP_D (int dummy ATTRIBUTE_UNUSED, int sizeflag ATTRIBUTE_UNUSED)
{
int add = 0;
USED_REX (REX_EXTX);
@@ -3851,18 +3848,14 @@ OP_D (dummy, sizeflag)
}
static void
-OP_T (dummy, sizeflag)
- int dummy ATTRIBUTE_UNUSED;
- int sizeflag ATTRIBUTE_UNUSED;
+OP_T (int dummy ATTRIBUTE_UNUSED, int sizeflag ATTRIBUTE_UNUSED)
{
sprintf (scratchbuf, "%%tr%d", reg);
oappend (scratchbuf + intel_syntax);
}
static void
-OP_Rd (bytemode, sizeflag)
- int bytemode;
- int sizeflag;
+OP_Rd (int bytemode, int sizeflag)
{
if (mod == 3)
OP_E (bytemode, sizeflag);
@@ -3871,9 +3864,7 @@ OP_Rd (bytemode, sizeflag)
}
static void
-OP_MMX (bytemode, sizeflag)
- int bytemode ATTRIBUTE_UNUSED;
- int sizeflag ATTRIBUTE_UNUSED;
+OP_MMX (int bytemode ATTRIBUTE_UNUSED, int sizeflag ATTRIBUTE_UNUSED)
{
int add = 0;
USED_REX (REX_EXTX);
@@ -3888,9 +3879,7 @@ OP_MMX (bytemode, sizeflag)
}
static void
-OP_XMM (bytemode, sizeflag)
- int bytemode ATTRIBUTE_UNUSED;
- int sizeflag ATTRIBUTE_UNUSED;
+OP_XMM (int bytemode ATTRIBUTE_UNUSED, int sizeflag ATTRIBUTE_UNUSED)
{
int add = 0;
USED_REX (REX_EXTX);
@@ -3901,9 +3890,7 @@ OP_XMM (bytemode, sizeflag)
}
static void
-OP_EM (bytemode, sizeflag)
- int bytemode;
- int sizeflag;
+OP_EM (int bytemode, int sizeflag)
{
int add = 0;
if (mod != 3)
@@ -3927,9 +3914,7 @@ OP_EM (bytemode, sizeflag)
}
static void
-OP_EX (bytemode, sizeflag)
- int bytemode;
- int sizeflag;
+OP_EX (int bytemode, int sizeflag)
{
int add = 0;
if (mod != 3)
@@ -3949,9 +3934,7 @@ OP_EX (bytemode, sizeflag)
}
static void
-OP_MS (bytemode, sizeflag)
- int bytemode;
- int sizeflag;
+OP_MS (int bytemode, int sizeflag)
{
if (mod == 3)
OP_EM (bytemode, sizeflag);
@@ -3960,9 +3943,7 @@ OP_MS (bytemode, sizeflag)
}
static void
-OP_XS (bytemode, sizeflag)
- int bytemode;
- int sizeflag;
+OP_XS (int bytemode, int sizeflag)
{
if (mod == 3)
OP_EX (bytemode, sizeflag);
@@ -3970,7 +3951,56 @@ OP_XS (bytemode, sizeflag)
BadOp ();
}
-static const char *Suffix3DNow[] = {
+static void
+OP_M (int bytemode, int sizeflag)
+{
+ if (mod == 3)
+ BadOp (); /* bad lea,lds,les,lfs,lgs,lss modrm */
+ else
+ OP_E (bytemode, sizeflag);
+}
+
+static void
+OP_0f07 (int bytemode, int sizeflag)
+{
+ if (mod != 3 || rm != 0)
+ BadOp ();
+ else
+ OP_E (bytemode, sizeflag);
+}
+
+static void
+OP_0fae (int bytemode, int sizeflag)
+{
+ if (mod == 3)
+ {
+ if (reg == 7)
+ strcpy (obuf + strlen (obuf) - sizeof ("clflush") + 1, "sfence");
+
+ if (reg < 5 || rm != 0)
+ {
+ BadOp (); /* bad sfence, mfence, or lfence */
+ return;
+ }
+ }
+ else if (reg != 7)
+ {
+ BadOp (); /* bad clflush */
+ return;
+ }
+
+ OP_E (bytemode, sizeflag);
+}
+
+static void
+NOP_Fixup (int bytemode ATTRIBUTE_UNUSED, int sizeflag ATTRIBUTE_UNUSED)
+{
+ /* NOP with REPZ prefix is called PAUSE. */
+ if (prefixes == PREFIX_REPZ)
+ strcpy (obuf, "pause");
+}
+
+static const char *const Suffix3DNow[] = {
/* 00 */ NULL, NULL, NULL, NULL,
/* 04 */ NULL, NULL, NULL, NULL,
/* 08 */ NULL, NULL, NULL, NULL,
@@ -4038,9 +4068,7 @@ static const char *Suffix3DNow[] = {
};
static void
-OP_3DNowSuffix (bytemode, sizeflag)
- int bytemode ATTRIBUTE_UNUSED;
- int sizeflag ATTRIBUTE_UNUSED;
+OP_3DNowSuffix (int bytemode ATTRIBUTE_UNUSED, int sizeflag ATTRIBUTE_UNUSED)
{
const char *mnemonic;
@@ -4076,9 +4104,7 @@ static const char *simd_cmp_op[] = {
};
static void
-OP_SIMD_Suffix (bytemode, sizeflag)
- int bytemode ATTRIBUTE_UNUSED;
- int sizeflag ATTRIBUTE_UNUSED;
+OP_SIMD_Suffix (int bytemode ATTRIBUTE_UNUSED, int sizeflag ATTRIBUTE_UNUSED)
{
unsigned int cmp_type;
@@ -4118,9 +4144,7 @@ OP_SIMD_Suffix (bytemode, sizeflag)
}
static void
-SIMD_Fixup (extrachar, sizeflag)
- int extrachar;
- int sizeflag ATTRIBUTE_UNUSED;
+SIMD_Fixup (int extrachar, int sizeflag ATTRIBUTE_UNUSED)
{
/* Change movlps/movhps to movhlps/movlhps for 2 register operand
forms of these instructions. */
@@ -4136,6 +4160,46 @@ SIMD_Fixup (extrachar, sizeflag)
}
static void
+PNI_Fixup (int extrachar ATTRIBUTE_UNUSED, int sizeflag)
+{
+ if (mod == 3 && reg == 1)
+ {
+ char *p = obuf + strlen (obuf);
+
+ /* Override "sidt". */
+ if (rm)
+ {
+ /* mwait %eax,%ecx */
+ strcpy (p - 4, "mwait %eax,%ecx");
+ }
+ else
+ {
+ /* monitor %eax,%ecx,%edx" */
+ strcpy (p - 4, "monitor %eax,%ecx,%edx");
+ }
+
+ codep++;
+ }
+ else
+ OP_E (0, sizeflag);
+}
+
+static void
+INVLPG_Fixup (int bytemode, int sizeflag)
+{
+ if (*codep == 0xf8)
+ {
+ char *p = obuf + strlen (obuf);
+
+ /* Override "invlpg". */
+ strcpy (p - 6, "swapgs");
+ codep++;
+ }
+ else
+ OP_E (bytemode, sizeflag);
+}
+
+static void
BadOp (void)
{
/* Throw away prefixes and 1st. opcode byte. */
diff --git a/contrib/binutils/opcodes/ia64-asmtab.c b/contrib/binutils/opcodes/ia64-asmtab.c
index f007f71..2465d39 100644
--- a/contrib/binutils/opcodes/ia64-asmtab.c
+++ b/contrib/binutils/opcodes/ia64-asmtab.c
@@ -1,37 +1,37 @@
-/* This file is automatically generated by ia64-gen. Do not edit! */
-static const char *ia64_strings[] = {
+/* This file is automatically generated by ia64-gen. Do not edit! */
+static const char * const ia64_strings[] = {
"", "0", "1", "a", "acq", "add", "addl", "addp4", "adds", "alloc", "and",
"andcm", "b", "bias", "br", "break", "brl", "brp", "bsw", "c", "call",
- "cexit", "chk", "cloop", "clr", "clrrrb", "cmp", "cmp4", "cmpxchg1",
- "cmpxchg2", "cmpxchg4", "cmpxchg8", "cond", "cover", "ctop", "czx1",
- "czx2", "d", "dep", "dpnt", "dptk", "e", "epc", "eq", "excl", "exit",
- "exp", "extr", "f", "fabs", "fadd", "famax", "famin", "fand", "fandcm",
- "fault", "fc", "fchkf", "fclass", "fclrf", "fcmp", "fcvt", "fetchadd4",
- "fetchadd8", "few", "fill", "flushrs", "fma", "fmax", "fmerge", "fmin",
- "fmix", "fmpy", "fms", "fneg", "fnegabs", "fnma", "fnmpy", "fnorm", "for",
- "fpabs", "fpack", "fpamax", "fpamin", "fpcmp", "fpcvt", "fpma", "fpmax",
- "fpmerge", "fpmin", "fpmpy", "fpms", "fpneg", "fpnegabs", "fpnma",
- "fpnmpy", "fprcpa", "fprsqrta", "frcpa", "frsqrta", "fselect", "fsetc",
- "fsub", "fswap", "fsxt", "fwb", "fx", "fxor", "fxu", "g", "ga", "ge",
- "getf", "geu", "gt", "gtu", "h", "hu", "i", "ia", "imp", "invala", "itc",
- "itr", "l", "ld1", "ld2", "ld4", "ld8", "ldf", "ldf8", "ldfd", "ldfe",
- "ldfp8", "ldfpd", "ldfps", "ldfs", "le", "leu", "lfetch", "loadrs",
- "loop", "lr", "lt", "ltu", "lu", "m", "many", "mf", "mix1", "mix2",
- "mix4", "mov", "movl", "mux1", "mux2", "nc", "ne", "neq", "nge", "ngt",
- "nl", "nle", "nlt", "nm", "nop", "nr", "ns", "nt1", "nt2", "nta", "nz",
- "or", "orcm", "ord", "pack2", "pack4", "padd1", "padd2", "padd4", "pavg1",
- "pavg2", "pavgsub1", "pavgsub2", "pcmp1", "pcmp2", "pcmp4", "pmax1",
- "pmax2", "pmin1", "pmin2", "pmpy2", "pmpyshr2", "popcnt", "pr", "probe",
- "psad1", "pshl2", "pshl4", "pshladd2", "pshr2", "pshr4", "pshradd2",
- "psub1", "psub2", "psub4", "ptc", "ptr", "r", "raz", "rel", "ret", "rfi",
- "rsm", "rum", "rw", "s", "s0", "s1", "s2", "s3", "sa", "se", "setf",
- "shl", "shladd", "shladdp4", "shr", "shrp", "sig", "spill", "spnt",
- "sptk", "srlz", "ssm", "sss", "st1", "st2", "st4", "st8", "stf", "stf8",
- "stfd", "stfe", "stfs", "sub", "sum", "sxt1", "sxt2", "sxt4", "sync",
- "tak", "tbit", "thash", "tnat", "tpa", "trunc", "ttag", "u", "unc",
- "unord", "unpack1", "unpack2", "unpack4", "uss", "uus", "uuu", "w",
- "wexit", "wtop", "x", "xchg1", "xchg2", "xchg4", "xchg8", "xf", "xma",
- "xmpy", "xor", "xuf", "z", "zxt1", "zxt2", "zxt4",
+ "cexit", "chk", "cloop", "clr", "clrrrb", "cmp", "cmp4", "cmp8xchg16",
+ "cmpxchg1", "cmpxchg2", "cmpxchg4", "cmpxchg8", "cond", "cover", "ctop",
+ "czx1", "czx2", "d", "dep", "dpnt", "dptk", "e", "epc", "eq", "excl",
+ "exit", "exp", "extr", "f", "fabs", "fadd", "famax", "famin", "fand",
+ "fandcm", "fault", "fc", "fchkf", "fclass", "fclrf", "fcmp", "fcvt",
+ "fetchadd4", "fetchadd8", "few", "fill", "flushrs", "fma", "fmax",
+ "fmerge", "fmin", "fmix", "fmpy", "fms", "fneg", "fnegabs", "fnma",
+ "fnmpy", "fnorm", "for", "fpabs", "fpack", "fpamax", "fpamin", "fpcmp",
+ "fpcvt", "fpma", "fpmax", "fpmerge", "fpmin", "fpmpy", "fpms", "fpneg",
+ "fpnegabs", "fpnma", "fpnmpy", "fprcpa", "fprsqrta", "frcpa", "frsqrta",
+ "fselect", "fsetc", "fsub", "fswap", "fsxt", "fwb", "fx", "fxor", "fxu",
+ "g", "ga", "ge", "getf", "geu", "gt", "gtu", "h", "hint", "hu", "i", "ia",
+ "imp", "invala", "itc", "itr", "l", "ld1", "ld16", "ld2", "ld4", "ld8",
+ "ldf", "ldf8", "ldfd", "ldfe", "ldfp8", "ldfpd", "ldfps", "ldfs", "le",
+ "leu", "lfetch", "loadrs", "loop", "lr", "lt", "ltu", "lu", "m", "many",
+ "mf", "mix1", "mix2", "mix4", "mov", "movl", "mux1", "mux2", "nc", "ne",
+ "neq", "nge", "ngt", "nl", "nle", "nlt", "nm", "nop", "nr", "ns", "nt1",
+ "nt2", "nta", "nz", "or", "orcm", "ord", "pack2", "pack4", "padd1",
+ "padd2", "padd4", "pavg1", "pavg2", "pavgsub1", "pavgsub2", "pcmp1",
+ "pcmp2", "pcmp4", "pmax1", "pmax2", "pmin1", "pmin2", "pmpy2", "pmpyshr2",
+ "popcnt", "pr", "probe", "psad1", "pshl2", "pshl4", "pshladd2", "pshr2",
+ "pshr4", "pshradd2", "psub1", "psub2", "psub4", "ptc", "ptr", "r", "raz",
+ "rel", "ret", "rfi", "rsm", "rum", "rw", "s", "s0", "s1", "s2", "s3",
+ "sa", "se", "setf", "shl", "shladd", "shladdp4", "shr", "shrp", "sig",
+ "spill", "spnt", "sptk", "srlz", "ssm", "sss", "st1", "st16", "st2",
+ "st4", "st8", "stf", "stf8", "stfd", "stfe", "stfs", "sub", "sum", "sxt1",
+ "sxt2", "sxt4", "sync", "tak", "tbit", "thash", "tnat", "tpa", "trunc",
+ "ttag", "u", "unc", "unord", "unpack1", "unpack2", "unpack4", "uss",
+ "uus", "uuu", "w", "wexit", "wtop", "x", "xchg1", "xchg2", "xchg4",
+ "xchg8", "xf", "xma", "xmpy", "xor", "xuf", "z", "zxt1", "zxt2", "zxt4",
};
static const struct ia64_dependency
@@ -39,8 +39,14 @@ dependencies[] = {
{ "ALAT", 0, 0, 0, -1, NULL, },
{ "AR[BSP]", 26, 0, 2, 17, NULL, },
{ "AR[BSPSTORE]", 26, 0, 2, 18, NULL, },
+ { "AR[CFLG]", 26, 0, 2, 27, NULL, },
{ "AR[CCV]", 26, 0, 2, 32, NULL, },
+ { "AR[CSD]", 26, 0, 2, 25, NULL, },
{ "AR[EC]", 26, 0, 2, 66, NULL, },
+ { "AR[EFLAG]", 26, 0, 2, 24, NULL, },
+ { "AR[FCR]", 26, 0, 2, 21, NULL, },
+ { "AR[FDR]", 26, 0, 2, 30, NULL, },
+ { "AR[FIR]", 26, 0, 2, 29, NULL, },
{ "AR[FPSR].sf0.controls", 30, 0, 2, -1, NULL, },
{ "AR[FPSR].sf1.controls", 30, 0, 2, -1, NULL, },
{ "AR[FPSR].sf2.controls", 30, 0, 2, -1, NULL, },
@@ -51,6 +57,7 @@ dependencies[] = {
{ "AR[FPSR].sf3.flags", 30, 0, 2, -1, NULL, },
{ "AR[FPSR].traps", 30, 0, 2, -1, NULL, },
{ "AR[FPSR].rv", 30, 0, 2, -1, NULL, },
+ { "AR[FSR]", 26, 0, 2, 28, NULL, },
{ "AR[ITC]", 26, 0, 2, 44, NULL, },
{ "AR[K%], % in 0 - 7", 1, 0, 2, -1, NULL, },
{ "AR[LC]", 26, 0, 2, 65, NULL, },
@@ -59,6 +66,7 @@ dependencies[] = {
{ "AR[PFS]", 26, 0, 0, 64, NULL, },
{ "AR[RNAT]", 26, 0, 2, 19, NULL, },
{ "AR[RSC]", 26, 0, 2, 16, NULL, },
+ { "AR[SSD]", 26, 0, 2, 26, NULL, },
{ "AR[UNAT]{%}, % in 0 - 63", 2, 0, 2, -1, NULL, },
{ "AR%, % in 8-15, 20, 22-23, 31, 33-35, 37-39, 41-43, 45-47, 67-111", 3, 0, 0, -1, NULL, },
{ "AR%, % in 48-63, 112-127", 4, 0, 2, -1, NULL, },
@@ -213,7 +221,13 @@ dependencies[] = {
{ "AR[BSP]", 26, 1, 2, 17, NULL, },
{ "AR[BSPSTORE]", 26, 1, 2, 18, NULL, },
{ "AR[CCV]", 26, 1, 2, 32, NULL, },
+ { "AR[CFLG]", 26, 1, 2, 27, NULL, },
+ { "AR[CSD]", 26, 1, 2, 25, NULL, },
{ "AR[EC]", 26, 1, 2, 66, NULL, },
+ { "AR[EFLAG]", 26, 1, 2, 24, NULL, },
+ { "AR[FCR]", 26, 1, 2, 21, NULL, },
+ { "AR[FDR]", 26, 1, 2, 30, NULL, },
+ { "AR[FIR]", 26, 1, 2, 29, NULL, },
{ "AR[FPSR].sf0.controls", 30, 1, 2, -1, NULL, },
{ "AR[FPSR].sf1.controls", 30, 1, 2, -1, NULL, },
{ "AR[FPSR].sf2.controls", 30, 1, 2, -1, NULL, },
@@ -232,6 +246,7 @@ dependencies[] = {
{ "AR[FPSR].sf3.flags", 30, 1, 2, -1, NULL, },
{ "AR[FPSR].rv", 30, 1, 2, -1, NULL, },
{ "AR[FPSR].traps", 30, 1, 2, -1, NULL, },
+ { "AR[FSR]", 26, 1, 2, 28, NULL, },
{ "AR[ITC]", 26, 1, 2, 44, NULL, },
{ "AR[K%], % in 0 - 7", 1, 1, 2, -1, NULL, },
{ "AR[LC]", 26, 1, 2, 65, NULL, },
@@ -356,1180 +371,1223 @@ dependencies[] = {
};
static const short dep0[] = {
- 88, 252, 2131, 2297,
+ 96, 267, 2139, 2312,
};
static const short dep1[] = {
- 32, 33, 88, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2297, 4127,
- 20605,
+ 40, 41, 96, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2312, 4135,
+ 20613,
};
static const short dep2[] = {
- 88, 252, 2157, 2158, 2160, 2161, 2163, 2164, 2166, 2314, 2317, 2318, 2321,
- 2322, 2325, 2326,
+ 96, 267, 2165, 2166, 2168, 2169, 2171, 2172, 2174, 2329, 2332, 2333, 2336,
+ 2337, 2340, 2341,
};
static const short dep3[] = {
- 32, 33, 88, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2314, 2317,
- 2318, 2321, 2322, 2325, 2326, 4127, 20605,
+ 40, 41, 96, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2329, 2332,
+ 2333, 2336, 2337, 2340, 2341, 4135, 20613,
};
static const short dep4[] = {
- 88, 252, 22637, 22638, 22640, 22641, 22643, 22644, 22646, 22794, 22797, 22798,
- 22801, 22802, 22805, 22806,
+ 96, 267, 22645, 22646, 22648, 22649, 22651, 22652, 22654, 22809, 22812, 22813,
+ 22816, 22817, 22820, 22821,
};
static const short dep5[] = {
- 32, 33, 88, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 4127, 20605,
- 22794, 22797, 22798, 22801, 22802, 22805, 22806,
+ 40, 41, 96, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 4135, 20613,
+ 22809, 22812, 22813, 22816, 22817, 22820, 22821,
};
static const short dep6[] = {
- 88, 252, 2157, 2158, 2160, 2161, 2163, 2164, 2166, 2314, 2315, 2317, 2319,
- 2321, 2323, 2325,
+ 96, 267, 2165, 2166, 2168, 2169, 2171, 2172, 2174, 2329, 2330, 2332, 2334,
+ 2336, 2338, 2340,
};
static const short dep7[] = {
- 32, 33, 88, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2314, 2315,
- 2318, 2319, 2322, 2323, 2326, 4127, 20605,
+ 40, 41, 96, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2329, 2330,
+ 2333, 2334, 2337, 2338, 2341, 4135, 20613,
};
static const short dep8[] = {
- 88, 252, 2157, 2158, 2160, 2161, 2163, 2164, 2166, 2314, 2316, 2318, 2320,
- 2322, 2324, 2326,
+ 96, 267, 2165, 2166, 2168, 2169, 2171, 2172, 2174, 2329, 2331, 2333, 2335,
+ 2337, 2339, 2341,
};
static const short dep9[] = {
- 32, 33, 88, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2314, 2316,
- 2317, 2320, 2321, 2324, 2325, 4127, 20605,
+ 40, 41, 96, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2329, 2331,
+ 2332, 2335, 2336, 2339, 2340, 4135, 20613,
};
static const short dep10[] = {
- 88, 252, 2157, 2158, 2160, 2161, 2163, 2164, 2166, 2314, 2315, 2316, 2317,
- 2318, 2319, 2320, 2321, 2322, 2323, 2324, 2325, 2326,
+ 96, 267, 2165, 2166, 2168, 2169, 2171, 2172, 2174, 2329, 2330, 2331, 2332,
+ 2333, 2334, 2335, 2336, 2337, 2338, 2339, 2340, 2341,
};
static const short dep11[] = {
- 32, 33, 88, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2314, 2315,
- 2316, 2317, 2318, 2319, 2320, 2321, 2322, 2323, 2324, 2325, 2326, 4127, 20605,
+ 40, 41, 96, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2329, 2330,
+ 2331, 2332, 2333, 2334, 2335, 2336, 2337, 2338, 2339, 2340, 2341, 4135, 20613,
};
static const short dep12[] = {
- 88, 252, 2364,
+ 96, 267, 2379,
};
static const short dep13[] = {
- 32, 33, 88, 148, 166, 167, 252, 2074, 2075, 2157, 2159, 2160, 2162, 2163,
- 2165, 2166, 4127,
+ 40, 41, 96, 156, 174, 175, 267, 2082, 2083, 2165, 2167, 2168, 2170, 2171,
+ 2173, 2174, 4135,
};
static const short dep14[] = {
- 88, 147, 252, 295, 2364, 28844, 28987,
+ 96, 155, 267, 310, 2379, 28852, 29002,
};
static const short dep15[] = {
- 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 21, 22,
- 23, 24, 25, 32, 33, 88, 136, 148, 166, 167, 252, 295, 2074, 2075, 2157, 2159,
- 2160, 2162, 2163, 2165, 2166, 4127, 28844, 28987,
+ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21,
+ 22, 23, 24, 25, 26, 28, 29, 30, 31, 32, 33, 40, 41, 96, 144, 156, 174, 175,
+ 267, 310, 2082, 2083, 2165, 2167, 2168, 2170, 2171, 2173, 2174, 4135, 28852,
+ 29002,
};
static const short dep16[] = {
- 1, 4, 32, 88, 126, 174, 177, 211, 252, 282, 2364, 28844, 28987,
+ 1, 6, 40, 96, 134, 182, 187, 226, 267, 297, 2379, 28852, 29002,
};
static const short dep17[] = {
- 1, 18, 20, 30, 32, 33, 88, 148, 150, 151, 166, 167, 174, 177, 211, 252, 282,
- 2074, 2075, 2157, 2159, 2160, 2162, 2163, 2165, 2166, 4127, 28844, 28987,
+ 1, 25, 27, 38, 40, 41, 96, 156, 158, 159, 174, 175, 182, 187, 226, 267, 297,
+ 2082, 2083, 2165, 2167, 2168, 2170, 2171, 2173, 2174, 4135, 28852, 29002,
};
static const short dep18[] = {
- 1, 32, 43, 88, 174, 211, 218, 252, 28844, 28987,
+ 1, 40, 51, 96, 182, 226, 233, 267, 28852, 29002,
};
static const short dep19[] = {
- 1, 30, 32, 33, 88, 145, 166, 174, 211, 218, 252, 4127, 28844, 28987,
+ 1, 38, 40, 41, 96, 153, 174, 182, 226, 233, 267, 4135, 28852, 29002,
};
static const short dep20[] = {
- 32, 88, 211, 252,
+ 40, 96, 226, 267,
};
static const short dep21[] = {
- 88, 166, 211, 252,
+ 96, 174, 226, 267,
};
static const short dep22[] = {
- 1, 32, 88, 120, 121, 123, 124, 125, 126, 127, 130, 131, 132, 133, 134, 135,
- 136, 137, 138, 139, 140, 142, 143, 144, 145, 146, 147, 148, 151, 152, 153,
- 154, 155, 156, 157, 158, 161, 162, 163, 164, 165, 166, 167, 168, 169, 174,
- 211, 252, 279, 280, 281, 282, 283, 284, 285, 286, 287, 288, 289, 290, 291,
- 292, 293, 294, 295, 296, 297, 298, 300, 301, 303, 304, 305, 306, 307, 308,
- 309, 310, 311, 312, 313, 28844, 28987,
+ 1, 40, 96, 128, 129, 131, 132, 133, 134, 135, 138, 139, 140, 141, 142, 143,
+ 144, 145, 146, 147, 148, 150, 151, 152, 153, 154, 155, 156, 159, 160, 161,
+ 162, 163, 164, 165, 166, 169, 170, 171, 172, 173, 174, 175, 176, 177, 182,
+ 226, 267, 294, 295, 296, 297, 298, 299, 300, 301, 302, 303, 304, 305, 306,
+ 307, 308, 309, 310, 311, 312, 313, 315, 316, 318, 319, 320, 321, 322, 323,
+ 324, 325, 326, 327, 328, 28852, 29002,
};
static const short dep23[] = {
- 1, 30, 32, 33, 42, 43, 47, 50, 64, 88, 126, 166, 174, 211, 252, 279, 280,
- 281, 282, 283, 284, 285, 286, 287, 288, 289, 290, 291, 292, 293, 294, 295,
- 296, 297, 298, 300, 301, 303, 304, 305, 306, 307, 308, 309, 310, 311, 312,
- 313, 4127, 28844, 28987,
+ 1, 38, 40, 41, 50, 51, 55, 58, 72, 96, 134, 174, 182, 226, 267, 294, 295,
+ 296, 297, 298, 299, 300, 301, 302, 303, 304, 305, 306, 307, 308, 309, 310,
+ 311, 312, 313, 315, 316, 318, 319, 320, 321, 322, 323, 324, 325, 326, 327,
+ 328, 4135, 28852, 29002,
};
static const short dep24[] = {
- 88, 125, 252, 281,
+ 96, 133, 267, 296,
};
static const short dep25[] = {
- 88, 126, 166, 252, 281,
+ 96, 134, 174, 267, 296,
};
static const short dep26[] = {
- 88, 126, 252, 282,
+ 96, 134, 267, 297,
};
static const short dep27[] = {
- 18, 19, 88, 89, 92, 96, 99, 126, 148, 166, 252, 282,
+ 25, 26, 96, 97, 100, 104, 107, 134, 156, 174, 267, 297,
};
static const short dep28[] = {
- 32, 33, 88, 166, 252, 2157, 2159, 2160, 2162, 2163, 2165, 2166, 4127,
+ 40, 41, 96, 174, 267, 2165, 2167, 2168, 2170, 2171, 2173, 2174, 4135,
};
static const short dep29[] = {
- 1, 18, 32, 88, 174, 199, 200, 211, 252, 2074, 2255, 2258, 2364, 28844, 28987,
+ 1, 25, 40, 96, 182, 214, 215, 226, 267, 2082, 2270, 2273, 2379, 28852, 29002,
};
static const short dep30[] = {
- 1, 4, 30, 32, 33, 88, 126, 148, 166, 167, 174, 199, 201, 211, 252, 2074, 2075,
- 2157, 2159, 2160, 2162, 2163, 2165, 2166, 2256, 2258, 4127, 28844, 28987,
+ 1, 6, 38, 40, 41, 96, 134, 156, 174, 175, 182, 214, 216, 226, 267, 2082, 2083,
+ 2165, 2167, 2168, 2170, 2171, 2173, 2174, 2271, 2273, 4135, 28852, 29002,
};
static const short dep31[] = {
- 88, 252,
+ 96, 267,
};
static const short dep32[] = {
- 88, 166, 252, 2074, 2076,
+ 96, 174, 267, 2082, 2084,
};
static const short dep33[] = {
- 32, 33, 88, 148, 166, 167, 252, 2157, 2159, 2160, 2162, 2163, 2165, 2166,
- 4127,
+ 40, 41, 96, 156, 174, 175, 267, 2165, 2167, 2168, 2170, 2171, 2173, 2174,
+ 4135,
};
static const short dep34[] = {
- 4, 29, 30, 31, 88, 116, 117, 177, 211, 252, 277, 278, 2364,
+ 6, 37, 38, 39, 96, 124, 125, 187, 226, 267, 292, 293, 2379,
};
static const short dep35[] = {
- 4, 29, 32, 33, 88, 148, 166, 167, 177, 211, 252, 277, 278, 316, 2157, 2159,
- 2160, 2162, 2163, 2165, 2166, 4127,
+ 6, 37, 40, 41, 96, 156, 174, 175, 187, 226, 267, 292, 293, 331, 2165, 2167,
+ 2168, 2170, 2171, 2173, 2174, 4135,
};
static const short dep36[] = {
- 17, 88, 198, 252, 2364,
+ 24, 96, 213, 267, 2379,
};
static const short dep37[] = {
- 17, 32, 33, 88, 148, 166, 167, 198, 252, 2157, 2159, 2160, 2162, 2163, 2165,
- 2166, 4127,
+ 24, 40, 41, 96, 156, 174, 175, 213, 267, 2165, 2167, 2168, 2170, 2171, 2173,
+ 2174, 4135,
};
static const short dep38[] = {
- 4, 17, 29, 30, 31, 88, 116, 117, 177, 198, 211, 252, 277, 278, 2364,
+ 6, 24, 37, 38, 39, 96, 124, 125, 187, 213, 226, 267, 292, 293, 2379,
};
static const short dep39[] = {
- 4, 17, 29, 32, 33, 88, 148, 166, 167, 177, 198, 211, 252, 277, 278, 316, 2157,
- 2159, 2160, 2162, 2163, 2165, 2166, 4127,
+ 6, 24, 37, 40, 41, 96, 156, 174, 175, 187, 213, 226, 267, 292, 293, 331, 2165,
+ 2167, 2168, 2170, 2171, 2173, 2174, 4135,
};
static const short dep40[] = {
- 1, 4, 30, 32, 33, 88, 126, 148, 166, 167, 174, 199, 201, 211, 252, 2157, 2159,
- 2160, 2162, 2163, 2165, 2166, 2256, 2258, 4127, 28844, 28987,
+ 1, 6, 38, 40, 41, 96, 134, 156, 174, 175, 182, 214, 216, 226, 267, 2165, 2167,
+ 2168, 2170, 2171, 2173, 2174, 2271, 2273, 4135, 28852, 29002,
};
static const short dep41[] = {
- 88, 166, 252,
+ 96, 174, 267,
};
static const short dep42[] = {
- 9, 88, 182, 183, 252, 2127, 2295, 18585, 18586, 18731, 18732, 18734, 18735,
- 22637, 22638, 22639, 22641, 22642, 22644, 22645, 22794, 22797, 22798, 22801,
- 22802, 22805, 22806,
+ 15, 96, 196, 197, 267, 2135, 2310, 18593, 18594, 18746, 18747, 18749, 18750,
+ 22645, 22646, 22647, 22649, 22650, 22652, 22653, 22809, 22812, 22813, 22816,
+ 22817, 22820, 22821,
};
static const short dep43[] = {
- 5, 13, 14, 32, 33, 88, 166, 182, 184, 252, 2126, 2127, 2128, 2157, 2158, 2161,
- 2164, 2295, 4127, 16516, 16518, 18731, 18733, 18734, 18736, 22794, 22797,
- 22798, 22801, 22802, 22805, 22806,
+ 11, 19, 20, 40, 41, 96, 174, 196, 198, 267, 2134, 2135, 2136, 2165, 2166,
+ 2169, 2172, 2310, 4135, 16524, 16526, 18746, 18748, 18749, 18751, 22809, 22812,
+ 22813, 22816, 22817, 22820, 22821,
};
static const short dep44[] = {
- 9, 10, 11, 12, 88, 182, 183, 185, 186, 188, 189, 191, 192, 252, 2127, 2295,
- 18585, 18586, 18731, 18732, 18734, 18735, 22637, 22638, 22639, 22641, 22642,
- 22644, 22645, 22794, 22797, 22798, 22801, 22802, 22805, 22806,
+ 15, 16, 17, 18, 96, 196, 197, 199, 200, 202, 203, 205, 206, 267, 2135, 2310,
+ 18593, 18594, 18746, 18747, 18749, 18750, 22645, 22646, 22647, 22649, 22650,
+ 22652, 22653, 22809, 22812, 22813, 22816, 22817, 22820, 22821,
};
static const short dep45[] = {
- 5, 6, 7, 8, 13, 14, 32, 33, 88, 166, 182, 184, 185, 187, 188, 190, 191, 193,
- 252, 2126, 2127, 2128, 2157, 2158, 2161, 2164, 2295, 4127, 16516, 16518, 18731,
- 18733, 18734, 18736, 22794, 22797, 22798, 22801, 22802, 22805, 22806,
+ 11, 12, 13, 14, 19, 20, 40, 41, 96, 174, 196, 198, 199, 201, 202, 204, 205,
+ 207, 267, 2134, 2135, 2136, 2165, 2166, 2169, 2172, 2310, 4135, 16524, 16526,
+ 18746, 18748, 18749, 18751, 22809, 22812, 22813, 22816, 22817, 22820, 22821,
+
};
static const short dep46[] = {
- 10, 88, 185, 186, 252, 2127, 2295, 18585, 18586, 18731, 18732, 18734, 18735,
- 22637, 22638, 22639, 22641, 22642, 22644, 22645, 22794, 22797, 22798, 22801,
- 22802, 22805, 22806,
+ 16, 96, 199, 200, 267, 2135, 2310, 18593, 18594, 18746, 18747, 18749, 18750,
+ 22645, 22646, 22647, 22649, 22650, 22652, 22653, 22809, 22812, 22813, 22816,
+ 22817, 22820, 22821,
};
static const short dep47[] = {
- 6, 13, 14, 32, 33, 88, 166, 185, 187, 252, 2126, 2127, 2128, 2157, 2158, 2161,
- 2164, 2295, 4127, 16516, 16518, 18731, 18733, 18734, 18736, 22794, 22797,
- 22798, 22801, 22802, 22805, 22806,
+ 12, 19, 20, 40, 41, 96, 174, 199, 201, 267, 2134, 2135, 2136, 2165, 2166,
+ 2169, 2172, 2310, 4135, 16524, 16526, 18746, 18748, 18749, 18751, 22809, 22812,
+ 22813, 22816, 22817, 22820, 22821,
};
static const short dep48[] = {
- 11, 88, 188, 189, 252, 2127, 2295, 18585, 18586, 18731, 18732, 18734, 18735,
- 22637, 22638, 22639, 22641, 22642, 22644, 22645, 22794, 22797, 22798, 22801,
- 22802, 22805, 22806,
+ 17, 96, 202, 203, 267, 2135, 2310, 18593, 18594, 18746, 18747, 18749, 18750,
+ 22645, 22646, 22647, 22649, 22650, 22652, 22653, 22809, 22812, 22813, 22816,
+ 22817, 22820, 22821,
};
static const short dep49[] = {
- 7, 13, 14, 32, 33, 88, 166, 188, 190, 252, 2126, 2127, 2128, 2157, 2158, 2161,
- 2164, 2295, 4127, 16516, 16518, 18731, 18733, 18734, 18736, 22794, 22797,
- 22798, 22801, 22802, 22805, 22806,
+ 13, 19, 20, 40, 41, 96, 174, 202, 204, 267, 2134, 2135, 2136, 2165, 2166,
+ 2169, 2172, 2310, 4135, 16524, 16526, 18746, 18748, 18749, 18751, 22809, 22812,
+ 22813, 22816, 22817, 22820, 22821,
};
static const short dep50[] = {
- 12, 88, 191, 192, 252, 2127, 2295, 18585, 18586, 18731, 18732, 18734, 18735,
- 22637, 22638, 22639, 22641, 22642, 22644, 22645, 22794, 22797, 22798, 22801,
- 22802, 22805, 22806,
+ 18, 96, 205, 206, 267, 2135, 2310, 18593, 18594, 18746, 18747, 18749, 18750,
+ 22645, 22646, 22647, 22649, 22650, 22652, 22653, 22809, 22812, 22813, 22816,
+ 22817, 22820, 22821,
};
static const short dep51[] = {
- 8, 13, 14, 32, 33, 88, 166, 191, 193, 252, 2126, 2127, 2128, 2157, 2158, 2161,
- 2164, 2295, 4127, 16516, 16518, 18731, 18733, 18734, 18736, 22794, 22797,
- 22798, 22801, 22802, 22805, 22806,
+ 14, 19, 20, 40, 41, 96, 174, 205, 207, 267, 2134, 2135, 2136, 2165, 2166,
+ 2169, 2172, 2310, 4135, 16524, 16526, 18746, 18748, 18749, 18751, 22809, 22812,
+ 22813, 22816, 22817, 22820, 22821,
};
static const short dep52[] = {
- 9, 88, 182, 183, 252, 2127, 2295, 18585, 18586, 18731, 18732, 18734, 18735,
+ 15, 96, 196, 197, 267, 2135, 2310, 18593, 18594, 18746, 18747, 18749, 18750,
};
static const short dep53[] = {
- 5, 13, 14, 32, 33, 88, 166, 182, 184, 252, 2126, 2127, 2128, 2157, 2158, 2161,
- 2164, 2295, 4127, 16516, 16518, 18731, 18733, 18734, 18736,
+ 11, 19, 20, 40, 41, 96, 174, 196, 198, 267, 2134, 2135, 2136, 2165, 2166,
+ 2169, 2172, 2310, 4135, 16524, 16526, 18746, 18748, 18749, 18751,
};
static const short dep54[] = {
- 9, 10, 11, 12, 88, 182, 183, 185, 186, 188, 189, 191, 192, 252, 2127, 2295,
- 18585, 18586, 18731, 18732, 18734, 18735,
+ 15, 16, 17, 18, 96, 196, 197, 199, 200, 202, 203, 205, 206, 267, 2135, 2310,
+ 18593, 18594, 18746, 18747, 18749, 18750,
};
static const short dep55[] = {
- 5, 6, 7, 8, 13, 14, 32, 33, 88, 166, 182, 184, 185, 187, 188, 190, 191, 193,
- 252, 2126, 2127, 2128, 2157, 2158, 2161, 2164, 2295, 4127, 16516, 16518, 18731,
- 18733, 18734, 18736,
+ 11, 12, 13, 14, 19, 20, 40, 41, 96, 174, 196, 198, 199, 201, 202, 204, 205,
+ 207, 267, 2134, 2135, 2136, 2165, 2166, 2169, 2172, 2310, 4135, 16524, 16526,
+ 18746, 18748, 18749, 18751,
};
static const short dep56[] = {
- 10, 88, 185, 186, 252, 2127, 2295, 18585, 18586, 18731, 18732, 18734, 18735,
+ 16, 96, 199, 200, 267, 2135, 2310, 18593, 18594, 18746, 18747, 18749, 18750,
};
static const short dep57[] = {
- 6, 13, 14, 32, 33, 88, 166, 185, 187, 252, 2126, 2127, 2128, 2157, 2158, 2161,
- 2164, 2295, 4127, 16516, 16518, 18731, 18733, 18734, 18736,
+ 12, 19, 20, 40, 41, 96, 174, 199, 201, 267, 2134, 2135, 2136, 2165, 2166,
+ 2169, 2172, 2310, 4135, 16524, 16526, 18746, 18748, 18749, 18751,
};
static const short dep58[] = {
- 11, 88, 188, 189, 252, 2127, 2295, 18585, 18586, 18731, 18732, 18734, 18735,
+ 17, 96, 202, 203, 267, 2135, 2310, 18593, 18594, 18746, 18747, 18749, 18750,
};
static const short dep59[] = {
- 7, 13, 14, 32, 33, 88, 166, 188, 190, 252, 2126, 2127, 2128, 2157, 2158, 2161,
- 2164, 2295, 4127, 16516, 16518, 18731, 18733, 18734, 18736,
+ 13, 19, 20, 40, 41, 96, 174, 202, 204, 267, 2134, 2135, 2136, 2165, 2166,
+ 2169, 2172, 2310, 4135, 16524, 16526, 18746, 18748, 18749, 18751,
};
static const short dep60[] = {
- 12, 88, 191, 192, 252, 2127, 2295, 18585, 18586, 18731, 18732, 18734, 18735,
+ 18, 96, 205, 206, 267, 2135, 2310, 18593, 18594, 18746, 18747, 18749, 18750,
};
static const short dep61[] = {
- 8, 13, 14, 32, 33, 88, 166, 191, 193, 252, 2126, 2127, 2128, 2157, 2158, 2161,
- 2164, 2295, 4127, 16516, 16518, 18731, 18733, 18734, 18736,
+ 14, 19, 20, 40, 41, 96, 174, 205, 207, 267, 2134, 2135, 2136, 2165, 2166,
+ 2169, 2172, 2310, 4135, 16524, 16526, 18746, 18748, 18749, 18751,
};
static const short dep62[] = {
- 88, 252, 2127, 2295, 18585, 18586, 18731, 18732, 18734, 18735,
+ 96, 267, 2135, 2310, 18593, 18594, 18746, 18747, 18749, 18750,
};
static const short dep63[] = {
- 32, 33, 88, 166, 252, 2126, 2127, 2128, 2157, 2158, 2161, 2164, 2295, 4127,
- 16516, 16518, 18731, 18733, 18734, 18736,
+ 40, 41, 96, 174, 267, 2134, 2135, 2136, 2165, 2166, 2169, 2172, 2310, 4135,
+ 16524, 16526, 18746, 18748, 18749, 18751,
};
static const short dep64[] = {
- 5, 88, 178, 252,
+ 11, 96, 192, 267,
};
static const short dep65[] = {
- 5, 32, 33, 88, 166, 178, 252, 2157, 2158, 2161, 2164, 4127,
+ 11, 40, 41, 96, 174, 192, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep66[] = {
- 5, 32, 33, 88, 166, 252, 2157, 2158, 2161, 2164, 4127,
+ 11, 40, 41, 96, 174, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep67[] = {
- 6, 88, 179, 252,
+ 12, 96, 193, 267,
};
static const short dep68[] = {
- 5, 32, 33, 88, 166, 179, 252, 2157, 2158, 2161, 2164, 4127,
+ 11, 40, 41, 96, 174, 193, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep69[] = {
- 7, 88, 180, 252,
+ 13, 96, 194, 267,
};
static const short dep70[] = {
- 5, 32, 33, 88, 166, 180, 252, 2157, 2158, 2161, 2164, 4127,
+ 11, 40, 41, 96, 174, 194, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep71[] = {
- 8, 88, 181, 252,
+ 14, 96, 195, 267,
};
static const short dep72[] = {
- 5, 32, 33, 88, 166, 181, 252, 2157, 2158, 2161, 2164, 4127,
+ 11, 40, 41, 96, 174, 195, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep73[] = {
- 9, 88, 183, 184, 252,
+ 15, 96, 197, 198, 267,
};
static const short dep74[] = {
- 32, 33, 88, 166, 183, 184, 252, 2157, 2158, 2161, 2164, 4127,
+ 40, 41, 96, 174, 197, 198, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep75[] = {
- 32, 33, 88, 166, 252, 2157, 2158, 2161, 2164, 4127,
+ 40, 41, 96, 174, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep76[] = {
- 10, 88, 186, 187, 252,
+ 16, 96, 200, 201, 267,
};
static const short dep77[] = {
- 32, 33, 88, 166, 186, 187, 252, 2157, 2158, 2161, 2164, 4127,
+ 40, 41, 96, 174, 200, 201, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep78[] = {
- 11, 88, 189, 190, 252,
+ 17, 96, 203, 204, 267,
};
static const short dep79[] = {
- 32, 33, 88, 166, 189, 190, 252, 2157, 2158, 2161, 2164, 4127,
+ 40, 41, 96, 174, 203, 204, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep80[] = {
- 12, 88, 192, 193, 252,
+ 18, 96, 206, 207, 267,
};
static const short dep81[] = {
- 32, 33, 88, 166, 192, 193, 252, 2157, 2158, 2161, 2164, 4127,
+ 40, 41, 96, 174, 206, 207, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep82[] = {
- 9, 13, 14, 32, 33, 88, 148, 166, 167, 252, 2157, 2158, 2161, 2164, 4127,
+ 15, 19, 20, 40, 41, 96, 156, 174, 175, 267, 2165, 2166, 2169, 2172, 4135,
+
};
static const short dep83[] = {
- 9, 10, 13, 14, 32, 33, 88, 148, 166, 167, 252, 2157, 2158, 2161, 2164, 4127,
+ 15, 16, 19, 20, 40, 41, 96, 156, 174, 175, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep84[] = {
- 9, 11, 13, 14, 32, 33, 88, 148, 166, 167, 252, 2157, 2158, 2161, 2164, 4127,
+ 15, 17, 19, 20, 40, 41, 96, 156, 174, 175, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep85[] = {
- 9, 12, 13, 14, 32, 33, 88, 148, 166, 167, 252, 2157, 2158, 2161, 2164, 4127,
+ 15, 18, 19, 20, 40, 41, 96, 156, 174, 175, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep86[] = {
- 9, 88, 182, 183, 252,
+ 15, 96, 196, 197, 267,
};
static const short dep87[] = {
- 5, 13, 14, 32, 33, 88, 166, 182, 184, 252, 2157, 2158, 2161, 2164, 4127,
+ 11, 19, 20, 40, 41, 96, 174, 196, 198, 267, 2165, 2166, 2169, 2172, 4135,
+
};
static const short dep88[] = {
- 9, 10, 11, 12, 88, 182, 183, 185, 186, 188, 189, 191, 192, 252,
+ 15, 16, 17, 18, 96, 196, 197, 199, 200, 202, 203, 205, 206, 267,
};
static const short dep89[] = {
- 5, 6, 7, 8, 13, 14, 32, 33, 88, 166, 182, 184, 185, 187, 188, 190, 191, 193,
- 252, 2157, 2158, 2161, 2164, 4127,
+ 11, 12, 13, 14, 19, 20, 40, 41, 96, 174, 196, 198, 199, 201, 202, 204, 205,
+ 207, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep90[] = {
- 10, 88, 185, 186, 252,
+ 16, 96, 199, 200, 267,
};
static const short dep91[] = {
- 6, 13, 14, 32, 33, 88, 166, 185, 187, 252, 2157, 2158, 2161, 2164, 4127,
+ 12, 19, 20, 40, 41, 96, 174, 199, 201, 267, 2165, 2166, 2169, 2172, 4135,
+
};
static const short dep92[] = {
- 11, 88, 188, 189, 252,
+ 17, 96, 202, 203, 267,
};
static const short dep93[] = {
- 7, 13, 14, 32, 33, 88, 166, 188, 190, 252, 2157, 2158, 2161, 2164, 4127,
+ 13, 19, 20, 40, 41, 96, 174, 202, 204, 267, 2165, 2166, 2169, 2172, 4135,
+
};
static const short dep94[] = {
- 12, 88, 191, 192, 252,
+ 18, 96, 205, 206, 267,
};
static const short dep95[] = {
- 8, 13, 14, 32, 33, 88, 166, 191, 193, 252, 2157, 2158, 2161, 2164, 4127,
+ 14, 19, 20, 40, 41, 96, 174, 205, 207, 267, 2165, 2166, 2169, 2172, 4135,
+
};
static const short dep96[] = {
- 9, 88, 182, 183, 252, 2157, 2158, 2159, 2161, 2162, 2164, 2165, 2314, 2317,
- 2318, 2321, 2322, 2325, 2326,
+ 15, 96, 196, 197, 267, 2165, 2166, 2167, 2169, 2170, 2172, 2173, 2329, 2332,
+ 2333, 2336, 2337, 2340, 2341,
};
static const short dep97[] = {
- 5, 13, 14, 32, 33, 88, 166, 182, 184, 252, 2126, 2127, 2128, 2157, 2158, 2161,
- 2164, 2314, 2317, 2318, 2321, 2322, 2325, 2326, 4127, 16516, 16518,
+ 11, 19, 20, 40, 41, 96, 174, 196, 198, 267, 2134, 2135, 2136, 2165, 2166,
+ 2169, 2172, 2329, 2332, 2333, 2336, 2337, 2340, 2341, 4135, 16524, 16526,
+
};
static const short dep98[] = {
- 9, 10, 11, 12, 88, 182, 183, 185, 186, 188, 189, 191, 192, 252, 2157, 2158,
- 2159, 2161, 2162, 2164, 2165, 2314, 2317, 2318, 2321, 2322, 2325, 2326,
+ 15, 16, 17, 18, 96, 196, 197, 199, 200, 202, 203, 205, 206, 267, 2165, 2166,
+ 2167, 2169, 2170, 2172, 2173, 2329, 2332, 2333, 2336, 2337, 2340, 2341,
};
static const short dep99[] = {
- 5, 6, 7, 8, 13, 14, 32, 33, 88, 166, 182, 184, 185, 187, 188, 190, 191, 193,
- 252, 2126, 2127, 2128, 2157, 2158, 2161, 2164, 2314, 2317, 2318, 2321, 2322,
- 2325, 2326, 4127, 16516, 16518,
+ 11, 12, 13, 14, 19, 20, 40, 41, 96, 174, 196, 198, 199, 201, 202, 204, 205,
+ 207, 267, 2134, 2135, 2136, 2165, 2166, 2169, 2172, 2329, 2332, 2333, 2336,
+ 2337, 2340, 2341, 4135, 16524, 16526,
};
static const short dep100[] = {
- 10, 88, 185, 186, 252, 2157, 2158, 2159, 2161, 2162, 2164, 2165, 2314, 2317,
- 2318, 2321, 2322, 2325, 2326,
+ 16, 96, 199, 200, 267, 2165, 2166, 2167, 2169, 2170, 2172, 2173, 2329, 2332,
+ 2333, 2336, 2337, 2340, 2341,
};
static const short dep101[] = {
- 6, 13, 14, 32, 33, 88, 166, 185, 187, 252, 2126, 2127, 2128, 2157, 2158, 2161,
- 2164, 2314, 2317, 2318, 2321, 2322, 2325, 2326, 4127, 16516, 16518,
+ 12, 19, 20, 40, 41, 96, 174, 199, 201, 267, 2134, 2135, 2136, 2165, 2166,
+ 2169, 2172, 2329, 2332, 2333, 2336, 2337, 2340, 2341, 4135, 16524, 16526,
+
};
static const short dep102[] = {
- 11, 88, 188, 189, 252, 2157, 2158, 2159, 2161, 2162, 2164, 2165, 2314, 2317,
- 2318, 2321, 2322, 2325, 2326,
+ 17, 96, 202, 203, 267, 2165, 2166, 2167, 2169, 2170, 2172, 2173, 2329, 2332,
+ 2333, 2336, 2337, 2340, 2341,
};
static const short dep103[] = {
- 7, 13, 14, 32, 33, 88, 166, 188, 190, 252, 2126, 2127, 2128, 2157, 2158, 2161,
- 2164, 2314, 2317, 2318, 2321, 2322, 2325, 2326, 4127, 16516, 16518,
+ 13, 19, 20, 40, 41, 96, 174, 202, 204, 267, 2134, 2135, 2136, 2165, 2166,
+ 2169, 2172, 2329, 2332, 2333, 2336, 2337, 2340, 2341, 4135, 16524, 16526,
+
};
static const short dep104[] = {
- 12, 88, 191, 192, 252, 2157, 2158, 2159, 2161, 2162, 2164, 2165, 2314, 2317,
- 2318, 2321, 2322, 2325, 2326,
+ 18, 96, 205, 206, 267, 2165, 2166, 2167, 2169, 2170, 2172, 2173, 2329, 2332,
+ 2333, 2336, 2337, 2340, 2341,
};
static const short dep105[] = {
- 8, 13, 14, 32, 33, 88, 166, 191, 193, 252, 2126, 2127, 2128, 2157, 2158, 2161,
- 2164, 2314, 2317, 2318, 2321, 2322, 2325, 2326, 4127, 16516, 16518,
+ 14, 19, 20, 40, 41, 96, 174, 205, 207, 267, 2134, 2135, 2136, 2165, 2166,
+ 2169, 2172, 2329, 2332, 2333, 2336, 2337, 2340, 2341, 4135, 16524, 16526,
+
};
static const short dep106[] = {
- 9, 88, 182, 183, 252, 22637, 22638, 22639, 22641, 22642, 22644, 22645, 22794,
- 22797, 22798, 22801, 22802, 22805, 22806,
+ 15, 96, 196, 197, 267, 22645, 22646, 22647, 22649, 22650, 22652, 22653, 22809,
+ 22812, 22813, 22816, 22817, 22820, 22821,
};
static const short dep107[] = {
- 5, 13, 14, 32, 33, 88, 166, 182, 184, 252, 2126, 2127, 2128, 2157, 2158, 2161,
- 2164, 4127, 16516, 16518, 22794, 22797, 22798, 22801, 22802, 22805, 22806,
-
+ 11, 19, 20, 40, 41, 96, 174, 196, 198, 267, 2134, 2135, 2136, 2165, 2166,
+ 2169, 2172, 4135, 16524, 16526, 22809, 22812, 22813, 22816, 22817, 22820,
+ 22821,
};
static const short dep108[] = {
- 9, 10, 11, 12, 88, 182, 183, 185, 186, 188, 189, 191, 192, 252, 22637, 22638,
- 22639, 22641, 22642, 22644, 22645, 22794, 22797, 22798, 22801, 22802, 22805,
- 22806,
+ 15, 16, 17, 18, 96, 196, 197, 199, 200, 202, 203, 205, 206, 267, 22645, 22646,
+ 22647, 22649, 22650, 22652, 22653, 22809, 22812, 22813, 22816, 22817, 22820,
+ 22821,
};
static const short dep109[] = {
- 5, 6, 7, 8, 13, 14, 32, 33, 88, 166, 182, 184, 185, 187, 188, 190, 191, 193,
- 252, 2126, 2127, 2128, 2157, 2158, 2161, 2164, 4127, 16516, 16518, 22794,
- 22797, 22798, 22801, 22802, 22805, 22806,
+ 11, 12, 13, 14, 19, 20, 40, 41, 96, 174, 196, 198, 199, 201, 202, 204, 205,
+ 207, 267, 2134, 2135, 2136, 2165, 2166, 2169, 2172, 4135, 16524, 16526, 22809,
+ 22812, 22813, 22816, 22817, 22820, 22821,
};
static const short dep110[] = {
- 10, 88, 185, 186, 252, 22637, 22638, 22639, 22641, 22642, 22644, 22645, 22794,
- 22797, 22798, 22801, 22802, 22805, 22806,
+ 16, 96, 199, 200, 267, 22645, 22646, 22647, 22649, 22650, 22652, 22653, 22809,
+ 22812, 22813, 22816, 22817, 22820, 22821,
};
static const short dep111[] = {
- 6, 13, 14, 32, 33, 88, 166, 185, 187, 252, 2126, 2127, 2128, 2157, 2158, 2161,
- 2164, 4127, 16516, 16518, 22794, 22797, 22798, 22801, 22802, 22805, 22806,
-
+ 12, 19, 20, 40, 41, 96, 174, 199, 201, 267, 2134, 2135, 2136, 2165, 2166,
+ 2169, 2172, 4135, 16524, 16526, 22809, 22812, 22813, 22816, 22817, 22820,
+ 22821,
};
static const short dep112[] = {
- 11, 88, 188, 189, 252, 22637, 22638, 22639, 22641, 22642, 22644, 22645, 22794,
- 22797, 22798, 22801, 22802, 22805, 22806,
+ 17, 96, 202, 203, 267, 22645, 22646, 22647, 22649, 22650, 22652, 22653, 22809,
+ 22812, 22813, 22816, 22817, 22820, 22821,
};
static const short dep113[] = {
- 7, 13, 14, 32, 33, 88, 166, 188, 190, 252, 2126, 2127, 2128, 2157, 2158, 2161,
- 2164, 4127, 16516, 16518, 22794, 22797, 22798, 22801, 22802, 22805, 22806,
-
+ 13, 19, 20, 40, 41, 96, 174, 202, 204, 267, 2134, 2135, 2136, 2165, 2166,
+ 2169, 2172, 4135, 16524, 16526, 22809, 22812, 22813, 22816, 22817, 22820,
+ 22821,
};
static const short dep114[] = {
- 12, 88, 191, 192, 252, 22637, 22638, 22639, 22641, 22642, 22644, 22645, 22794,
- 22797, 22798, 22801, 22802, 22805, 22806,
+ 18, 96, 205, 206, 267, 22645, 22646, 22647, 22649, 22650, 22652, 22653, 22809,
+ 22812, 22813, 22816, 22817, 22820, 22821,
};
static const short dep115[] = {
- 8, 13, 14, 32, 33, 88, 166, 191, 193, 252, 2126, 2127, 2128, 2157, 2158, 2161,
- 2164, 4127, 16516, 16518, 22794, 22797, 22798, 22801, 22802, 22805, 22806,
-
+ 14, 19, 20, 40, 41, 96, 174, 205, 207, 267, 2134, 2135, 2136, 2165, 2166,
+ 2169, 2172, 4135, 16524, 16526, 22809, 22812, 22813, 22816, 22817, 22820,
+ 22821,
};
static const short dep116[] = {
- 88, 252, 2157, 2158, 2159, 2161, 2162, 2164, 2165, 2314, 2317, 2318, 2321,
- 2322, 2325, 2326,
+ 96, 267, 2165, 2166, 2167, 2169, 2170, 2172, 2173, 2329, 2332, 2333, 2336,
+ 2337, 2340, 2341,
};
static const short dep117[] = {
- 32, 33, 88, 166, 252, 2126, 2127, 2128, 2157, 2158, 2161, 2164, 2314, 2317,
- 2318, 2321, 2322, 2325, 2326, 4127, 16516, 16518,
+ 40, 41, 96, 174, 267, 2134, 2135, 2136, 2165, 2166, 2169, 2172, 2329, 2332,
+ 2333, 2336, 2337, 2340, 2341, 4135, 16524, 16526,
};
static const short dep118[] = {
- 88, 252, 22637, 22638, 22639, 22641, 22642, 22644, 22645, 22794, 22797, 22798,
- 22801, 22802, 22805, 22806,
+ 96, 267, 22645, 22646, 22647, 22649, 22650, 22652, 22653, 22809, 22812, 22813,
+ 22816, 22817, 22820, 22821,
};
static const short dep119[] = {
- 32, 33, 88, 166, 252, 2126, 2127, 2128, 2157, 2158, 2161, 2164, 4127, 16516,
- 16518, 22794, 22797, 22798, 22801, 22802, 22805, 22806,
+ 40, 41, 96, 174, 267, 2134, 2135, 2136, 2165, 2166, 2169, 2172, 4135, 16524,
+ 16526, 22809, 22812, 22813, 22816, 22817, 22820, 22821,
};
static const short dep120[] = {
- 13, 14, 32, 33, 88, 166, 252, 2126, 2127, 2128, 2157, 2158, 2161, 2164, 2295,
- 4127, 16516, 16518, 18731, 18733, 18734, 18736,
+ 19, 20, 40, 41, 96, 174, 267, 2134, 2135, 2136, 2165, 2166, 2169, 2172, 2310,
+ 4135, 16524, 16526, 18746, 18748, 18749, 18751,
};
static const short dep121[] = {
- 32, 33, 88, 148, 166, 167, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164,
- 4127, 20605,
+ 40, 41, 96, 156, 174, 175, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172,
+ 4135, 20613,
};
static const short dep122[] = {
- 88, 252, 2075, 2076, 2256, 2257,
+ 96, 267, 2083, 2084, 2271, 2272,
};
static const short dep123[] = {
- 32, 33, 88, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2255, 2257,
- 4127, 20605,
+ 40, 41, 96, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2270, 2272,
+ 4135, 20613,
};
static const short dep124[] = {
- 32, 33, 88, 166, 252, 2074, 2076, 2157, 2158, 2161, 2164, 2297, 4127, 20605,
+ 40, 41, 96, 174, 267, 2082, 2084, 2165, 2166, 2169, 2172, 2312, 4135, 20613,
};
static const short dep125[] = {
- 88, 252, 14446, 14448, 14449, 14451, 14452, 14454, 14605, 14606, 14609, 14610,
- 14613, 14614,
+ 96, 267, 14454, 14456, 14457, 14459, 14460, 14462, 14620, 14621, 14624, 14625,
+ 14628, 14629,
};
static const short dep126[] = {
- 32, 33, 88, 166, 252, 2129, 2130, 2131, 4127, 14605, 14606, 14609, 14610,
- 14613, 14614, 20605, 24685, 24686, 24689, 24692,
+ 40, 41, 96, 174, 267, 2137, 2138, 2139, 4135, 14620, 14621, 14624, 14625,
+ 14628, 14629, 20613, 24693, 24694, 24697, 24700,
};
static const short dep127[] = {
- 88, 113, 115, 116, 118, 252, 273, 274, 277, 278,
+ 96, 121, 123, 124, 126, 267, 288, 289, 292, 293,
};
static const short dep128[] = {
- 32, 33, 88, 166, 252, 273, 274, 277, 278, 4127, 24685, 24686, 24689, 24692,
+ 40, 41, 96, 174, 267, 288, 289, 292, 293, 4135, 24693, 24694, 24697, 24700,
};
static const short dep129[] = {
- 32, 33, 88, 166, 252, 2157, 2158, 2161, 2164, 2297, 4127, 20605,
+ 40, 41, 96, 174, 267, 2165, 2166, 2169, 2172, 2312, 4135, 20613,
};
static const short dep130[] = {
- 32, 33, 88, 110, 113, 116, 166, 252, 2297, 4127, 20605, 24685,
+ 40, 41, 96, 118, 121, 124, 174, 267, 2312, 4135, 20613, 24693,
};
static const short dep131[] = {
- 4, 17, 19, 20, 88, 177, 198, 201, 252, 2073, 2254,
+ 6, 24, 26, 27, 96, 187, 213, 216, 267, 2081, 2269,
};
static const short dep132[] = {
- 32, 33, 88, 166, 177, 198, 200, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164,
- 2254, 4127, 20605,
+ 40, 41, 96, 174, 187, 213, 215, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172,
+ 2269, 4135, 20613,
};
static const short dep133[] = {
- 4, 17, 18, 19, 32, 33, 88, 166, 252, 2073, 2157, 2158, 2161, 2164, 2297, 4127,
- 20605,
+ 6, 24, 25, 26, 40, 41, 96, 174, 267, 2081, 2165, 2166, 2169, 2172, 2312, 4135,
+ 20613,
};
static const short dep134[] = {
- 0, 32, 33, 88, 148, 166, 167, 252, 2157, 2158, 2161, 2164, 4127,
+ 0, 40, 41, 96, 156, 174, 175, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep135[] = {
- 0, 88, 173, 252,
+ 0, 96, 181, 267,
};
static const short dep136[] = {
- 0, 32, 33, 88, 148, 166, 167, 173, 252, 2157, 2158, 2161, 2164, 4127,
+ 0, 40, 41, 96, 156, 174, 175, 181, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep137[] = {
- 32, 33, 88, 166, 173, 252, 2157, 2158, 2161, 2164, 4127,
+ 40, 41, 96, 174, 181, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep138[] = {
- 2, 21, 88, 175, 202, 252, 28844, 28987,
+ 2, 28, 96, 183, 217, 267, 28852, 29002,
};
static const short dep139[] = {
- 1, 2, 21, 22, 88, 160, 161, 166, 175, 202, 252, 28844, 28987,
+ 1, 2, 28, 29, 96, 168, 169, 174, 183, 217, 267, 28852, 29002,
};
static const short dep140[] = {
- 1, 21, 22, 30, 32, 33, 88, 160, 161, 166, 175, 202, 252, 4127, 28844, 28987,
+ 1, 28, 29, 38, 40, 41, 96, 168, 169, 174, 183, 217, 267, 4135, 28852, 29002,
};
static const short dep141[] = {
- 0, 32, 33, 88, 166, 173, 252, 2157, 2158, 2161, 2164, 4127,
+ 0, 40, 41, 96, 174, 181, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep142[] = {
- 1, 2, 3, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 21, 22, 23, 88, 174, 175,
- 176, 178, 179, 180, 181, 183, 184, 186, 187, 189, 190, 192, 193, 194, 195,
- 196, 202, 203, 204, 252, 2064, 2073, 2245, 2254, 28844, 28987,
+ 1, 2, 3, 4, 5, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22,
+ 28, 29, 30, 31, 96, 182, 183, 184, 185, 186, 188, 189, 190, 191, 192, 193,
+ 194, 195, 197, 198, 200, 201, 203, 204, 206, 207, 208, 209, 210, 211, 217,
+ 218, 219, 267, 2071, 2081, 2260, 2269, 28852, 29002,
};
static const short dep143[] = {
- 22, 32, 33, 88, 126, 166, 174, 175, 176, 178, 179, 180, 181, 183, 184, 186,
- 187, 189, 190, 192, 193, 194, 195, 196, 202, 203, 204, 252, 2129, 2130, 2131,
- 2157, 2158, 2161, 2164, 2245, 2254, 4127, 20605, 28844, 28987,
+ 29, 40, 41, 96, 134, 174, 182, 183, 184, 185, 186, 188, 189, 190, 191, 192,
+ 193, 194, 195, 197, 198, 200, 201, 203, 204, 206, 207, 208, 209, 210, 211,
+ 217, 218, 219, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2260, 2269,
+ 4135, 20613, 28852, 29002,
};
static const short dep144[] = {
- 88, 252, 14455, 14457, 14458, 14460, 14489, 14490, 14505, 14615, 14616, 14636,
- 14637, 14639, 14640, 14649,
+ 96, 267, 14463, 14465, 14466, 14468, 14497, 14498, 14513, 14630, 14631, 14651,
+ 14652, 14654, 14655, 14664,
};
static const short dep145[] = {
- 32, 33, 88, 165, 166, 252, 2157, 2158, 2161, 2164, 4127, 14615, 14616, 14636,
- 14637, 14639, 14640, 14649,
+ 40, 41, 96, 173, 174, 267, 2165, 2166, 2169, 2172, 4135, 14630, 14631, 14651,
+ 14652, 14654, 14655, 14664,
};
static const short dep146[] = {
- 14455, 14457, 14458, 14460, 14489, 14490, 14505, 14615, 14616, 14636, 14637,
- 14639, 14640, 14649,
+ 14463, 14465, 14466, 14468, 14497, 14498, 14513, 14630, 14631, 14651, 14652,
+ 14654, 14655, 14664,
};
static const short dep147[] = {
- 165, 14615, 14616, 14636, 14637, 14639, 14640, 14649,
+ 173, 14630, 14631, 14651, 14652, 14654, 14655, 14664,
};
static const short dep148[] = {
- 88, 252, 14456, 14457, 14459, 14460, 14468, 14469, 14470, 14471, 14472, 14473,
- 14474, 14475, 14477, 14480, 14481, 14489, 14490, 14491, 14492, 14493, 14498,
- 14499, 14500, 14501, 14505, 14615, 14616, 14622, 14623, 14624, 14625, 14627,
- 14629, 14636, 14637, 14639, 14640, 14641, 14642, 14645, 14646, 14649,
+ 96, 267, 14464, 14465, 14467, 14468, 14476, 14477, 14478, 14479, 14480, 14481,
+ 14482, 14483, 14485, 14488, 14489, 14497, 14498, 14499, 14500, 14501, 14506,
+ 14507, 14508, 14509, 14513, 14630, 14631, 14637, 14638, 14639, 14640, 14642,
+ 14644, 14651, 14652, 14654, 14655, 14656, 14657, 14660, 14661, 14664,
};
static const short dep149[] = {
- 32, 33, 64, 88, 126, 166, 252, 2157, 2158, 2161, 2164, 4127, 14615, 14616,
- 14622, 14623, 14624, 14625, 14627, 14629, 14636, 14637, 14639, 14640, 14641,
- 14642, 14645, 14646, 14649,
+ 40, 41, 72, 96, 134, 174, 267, 2165, 2166, 2169, 2172, 4135, 14630, 14631,
+ 14637, 14638, 14639, 14640, 14642, 14644, 14651, 14652, 14654, 14655, 14656,
+ 14657, 14660, 14661, 14664,
};
static const short dep150[] = {
- 1, 2, 3, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 21, 22, 23, 32, 33, 88, 126,
- 163, 166, 252, 2064, 2073, 2157, 2158, 2161, 2164, 2297, 4127, 20605, 28844,
-
+ 1, 2, 3, 4, 5, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22,
+ 28, 29, 30, 31, 40, 41, 96, 134, 171, 174, 267, 2071, 2081, 2165, 2166, 2169,
+ 2172, 2312, 4135, 20613, 28852,
};
static const short dep151[] = {
- 35, 36, 37, 38, 39, 40, 41, 42, 44, 45, 46, 47, 48, 49, 50, 52, 53, 54, 55,
- 56, 57, 59, 61, 62, 63, 64, 85, 87, 88, 213, 214, 215, 216, 217, 218, 219,
- 220, 221, 222, 223, 225, 226, 227, 228, 229, 231, 233, 234, 235, 251, 252,
- 2108, 2280,
+ 43, 44, 45, 46, 47, 48, 49, 50, 52, 53, 54, 55, 56, 57, 58, 60, 61, 62, 63,
+ 64, 65, 67, 69, 70, 71, 72, 93, 95, 96, 228, 229, 230, 231, 232, 233, 234,
+ 235, 236, 237, 238, 240, 241, 242, 243, 244, 246, 248, 249, 250, 266, 267,
+ 2116, 2295,
};
static const short dep152[] = {
- 32, 33, 87, 88, 126, 145, 166, 213, 214, 215, 216, 217, 218, 219, 220, 221,
- 222, 223, 225, 226, 227, 228, 229, 231, 233, 234, 235, 251, 252, 2129, 2130,
- 2131, 2157, 2158, 2161, 2164, 2280, 4127, 20605,
+ 40, 41, 95, 96, 134, 153, 174, 228, 229, 230, 231, 232, 233, 234, 235, 236,
+ 237, 238, 240, 241, 242, 243, 244, 246, 248, 249, 250, 266, 267, 2137, 2138,
+ 2139, 2165, 2166, 2169, 2172, 2295, 4135, 20613,
};
static const short dep153[] = {
- 51, 86, 88, 224, 251, 252, 2131, 2297,
+ 59, 94, 96, 239, 266, 267, 2139, 2312,
};
static const short dep154[] = {
- 32, 33, 35, 36, 38, 40, 41, 43, 44, 45, 46, 48, 49, 52, 53, 55, 56, 57, 58,
- 59, 61, 62, 63, 85, 86, 88, 126, 145, 166, 224, 251, 252, 2099, 2108, 2157,
- 2158, 2161, 2164, 2297, 4127, 20605,
+ 40, 41, 43, 44, 46, 48, 49, 51, 52, 53, 54, 56, 57, 60, 61, 63, 64, 65, 66,
+ 67, 69, 70, 71, 93, 94, 96, 134, 153, 174, 239, 266, 267, 2107, 2116, 2165,
+ 2166, 2169, 2172, 2312, 4135, 20613,
};
static const short dep155[] = {
- 2, 21, 33, 88, 175, 202, 211, 252, 2131, 2297, 28844, 28987,
+ 2, 28, 41, 96, 183, 217, 226, 267, 2139, 2312, 28852, 29002,
};
static const short dep156[] = {
- 2, 18, 19, 21, 22, 30, 32, 33, 88, 160, 161, 166, 175, 202, 211, 252, 2297,
- 4127, 20605, 28844, 28987,
+ 2, 25, 26, 28, 29, 38, 40, 41, 96, 168, 169, 174, 183, 217, 226, 267, 2312,
+ 4135, 20613, 28852, 29002,
};
static const short dep157[] = {
- 88, 120, 121, 123, 124, 128, 129, 132, 133, 134, 135, 136, 137, 138, 139,
- 141, 144, 145, 149, 150, 153, 154, 155, 156, 157, 159, 160, 162, 163, 164,
- 165, 167, 168, 169, 252, 279, 280, 284, 286, 287, 288, 289, 291, 293, 297,
- 300, 301, 303, 304, 305, 306, 308, 309, 310, 312, 313,
+ 96, 128, 129, 131, 132, 136, 137, 140, 141, 142, 143, 144, 145, 146, 147,
+ 149, 152, 153, 157, 158, 161, 162, 163, 164, 165, 167, 168, 170, 171, 172,
+ 173, 175, 176, 177, 267, 294, 295, 299, 301, 302, 303, 304, 306, 308, 312,
+ 315, 316, 318, 319, 320, 321, 323, 324, 325, 327, 328,
};
static const short dep158[] = {
- 32, 33, 64, 88, 126, 166, 252, 279, 280, 284, 286, 287, 288, 289, 291, 293,
- 297, 300, 301, 303, 304, 305, 306, 308, 309, 310, 312, 313, 2129, 2130, 2131,
- 2157, 2158, 2161, 2164, 4127, 20605,
+ 40, 41, 72, 96, 134, 174, 267, 294, 295, 299, 301, 302, 303, 304, 306, 308,
+ 312, 315, 316, 318, 319, 320, 321, 323, 324, 325, 327, 328, 2137, 2138, 2139,
+ 2165, 2166, 2169, 2172, 4135, 20613,
};
static const short dep159[] = {
- 88, 119, 121, 122, 124, 153, 154, 169, 252, 279, 280, 300, 301, 303, 304,
- 313,
+ 96, 127, 129, 130, 132, 161, 162, 177, 267, 294, 295, 315, 316, 318, 319,
+ 328,
};
static const short dep160[] = {
- 32, 33, 88, 165, 166, 252, 279, 280, 300, 301, 303, 304, 313, 2129, 2130,
- 2131, 2157, 2158, 2161, 2164, 4127, 20605,
+ 40, 41, 96, 173, 174, 267, 294, 295, 315, 316, 318, 319, 328, 2137, 2138,
+ 2139, 2165, 2166, 2169, 2172, 4135, 20613,
};
static const short dep161[] = {
- 32, 33, 88, 121, 124, 126, 129, 130, 133, 135, 137, 139, 141, 142, 144, 148,
- 149, 151, 152, 153, 154, 156, 157, 159, 161, 162, 164, 166, 168, 169, 252,
- 2157, 2158, 2161, 2164, 2297, 4127, 20605,
+ 40, 41, 96, 129, 132, 134, 137, 138, 141, 143, 145, 147, 149, 150, 152, 156,
+ 157, 159, 160, 161, 162, 164, 165, 167, 169, 170, 172, 174, 176, 177, 267,
+ 2165, 2166, 2169, 2172, 2312, 4135, 20613,
};
static const short dep162[] = {
- 32, 33, 88, 121, 124, 153, 154, 166, 169, 252, 2157, 2158, 2161, 2164, 2297,
- 4127, 20605,
+ 40, 41, 96, 129, 132, 161, 162, 174, 177, 267, 2165, 2166, 2169, 2172, 2312,
+ 4135, 20613,
};
static const short dep163[] = {
- 32, 33, 67, 68, 73, 75, 88, 102, 126, 155, 166, 170, 252, 2129, 2130, 2131,
- 2157, 2158, 2161, 2164, 2297, 4127, 20605,
+ 40, 41, 75, 76, 81, 83, 96, 110, 134, 163, 174, 178, 267, 2137, 2138, 2139,
+ 2165, 2166, 2169, 2172, 2312, 4135, 20613,
};
static const short dep164[] = {
- 32, 33, 67, 68, 73, 75, 88, 102, 126, 127, 128, 130, 131, 155, 166, 170, 252,
- 2129, 2130, 2131, 2157, 2158, 2161, 2164, 4127, 20605,
+ 40, 41, 75, 76, 81, 83, 96, 110, 134, 135, 136, 138, 139, 163, 174, 178, 267,
+ 2137, 2138, 2139, 2165, 2166, 2169, 2172, 4135, 20613,
};
static const short dep165[] = {
- 68, 69, 88, 92, 93, 239, 240, 252, 254, 255,
+ 76, 77, 96, 100, 101, 254, 255, 267, 269, 270,
};
static const short dep166[] = {
- 32, 33, 39, 54, 69, 71, 77, 88, 90, 93, 126, 145, 166, 170, 239, 240, 252,
- 254, 255, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 4127, 20605,
+ 40, 41, 47, 62, 77, 79, 85, 96, 98, 101, 134, 153, 174, 178, 254, 255, 267,
+ 269, 270, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 4135, 20613,
};
static const short dep167[] = {
- 32, 33, 39, 54, 69, 71, 88, 90, 93, 95, 97, 126, 145, 166, 170, 239, 240,
- 252, 254, 255, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 4127, 20605,
+ 40, 41, 47, 62, 77, 79, 96, 98, 101, 103, 105, 134, 153, 174, 178, 254, 255,
+ 267, 269, 270, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 4135, 20613,
};
static const short dep168[] = {
- 88, 252, 12458, 12459, 12602,
+ 96, 267, 12466, 12467, 12617,
};
static const short dep169[] = {
- 32, 33, 88, 126, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 4127,
- 12602, 20605,
+ 40, 41, 96, 134, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 4135,
+ 12617, 20613,
};
static const short dep170[] = {
- 88, 252, 6210, 6211, 6381,
+ 96, 267, 6218, 6219, 6396,
};
static const short dep171[] = {
- 32, 33, 88, 126, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 4127,
- 6381, 20605,
+ 40, 41, 96, 134, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 4135,
+ 6396, 20613,
};
static const short dep172[] = {
- 88, 252, 6228, 6394,
+ 96, 267, 6236, 6409,
};
static const short dep173[] = {
- 32, 33, 88, 126, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 4127,
- 6394, 20605,
+ 40, 41, 96, 134, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 4135,
+ 6409, 20613,
};
static const short dep174[] = {
- 88, 252, 6246, 6247, 6248, 6249, 6405, 6407, 8454,
+ 96, 267, 6254, 6255, 6256, 6257, 6420, 6422, 8469,
};
static const short dep175[] = {
- 32, 33, 88, 126, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 4127,
- 6249, 6406, 6407, 8295, 8453, 20605,
+ 40, 41, 96, 134, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 4135,
+ 6257, 6421, 6422, 8303, 8468, 20613,
};
static const short dep176[] = {
- 88, 252, 6250, 6251, 6408,
+ 96, 267, 6258, 6259, 6423,
};
static const short dep177[] = {
- 32, 33, 88, 126, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 4127,
- 6408, 20605,
+ 40, 41, 96, 134, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 4135,
+ 6423, 20613,
};
static const short dep178[] = {
- 88, 252, 6252, 6409,
+ 96, 267, 6260, 6424,
};
static const short dep179[] = {
- 32, 33, 88, 126, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 4127,
- 6409, 20605,
+ 40, 41, 96, 134, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 4135,
+ 6424, 20613,
};
static const short dep180[] = {
- 88, 252, 10341, 10500,
+ 96, 267, 10349, 10515,
};
static const short dep181[] = {
- 32, 33, 88, 126, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 4127,
- 10500, 20605,
+ 40, 41, 96, 134, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 4135,
+ 10515, 20613,
};
static const short dep182[] = {
- 68, 69, 73, 74, 88, 92, 93, 239, 240, 242, 243, 252, 254, 255,
+ 76, 77, 81, 82, 96, 100, 101, 254, 255, 257, 258, 267, 269, 270,
};
static const short dep183[] = {
- 32, 33, 39, 54, 69, 71, 74, 77, 88, 90, 93, 126, 145, 166, 170, 239, 240,
- 242, 244, 252, 254, 255, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 4127, 20605,
+ 40, 41, 47, 62, 77, 79, 82, 85, 96, 98, 101, 134, 153, 174, 178, 254, 255,
+ 257, 259, 267, 269, 270, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 4135, 20613,
};
static const short dep184[] = {
- 68, 69, 88, 92, 93, 95, 96, 239, 240, 252, 254, 255, 256, 257,
+ 76, 77, 96, 100, 101, 103, 104, 254, 255, 267, 269, 270, 271, 272,
};
static const short dep185[] = {
- 32, 33, 39, 54, 69, 71, 88, 90, 93, 95, 97, 126, 145, 166, 170, 239, 240,
- 252, 254, 255, 256, 257, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 4127, 20605,
+ 40, 41, 47, 62, 77, 79, 96, 98, 101, 103, 105, 134, 153, 174, 178, 254, 255,
+ 267, 269, 270, 271, 272, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 4135, 20613,
};
static const short dep186[] = {
- 32, 33, 88, 126, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2297,
- 4127, 12459, 20605,
+ 40, 41, 96, 134, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2312,
+ 4135, 12467, 20613,
};
static const short dep187[] = {
- 32, 33, 88, 126, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2297,
- 4127, 6210, 20605,
+ 40, 41, 96, 134, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2312,
+ 4135, 6218, 20613,
};
static const short dep188[] = {
- 32, 33, 88, 126, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2297,
- 4127, 6228, 20605,
+ 40, 41, 96, 134, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2312,
+ 4135, 6236, 20613,
};
static const short dep189[] = {
- 32, 33, 88, 126, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2297,
- 4127, 6248, 8294, 20605,
+ 40, 41, 96, 134, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2312,
+ 4135, 6256, 8302, 20613,
};
static const short dep190[] = {
- 32, 33, 88, 126, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2297,
- 4127, 6250, 20605,
+ 40, 41, 96, 134, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2312,
+ 4135, 6258, 20613,
};
static const short dep191[] = {
- 32, 33, 88, 126, 165, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164,
- 2297, 4127, 6251, 6252, 20605,
+ 40, 41, 96, 134, 173, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172,
+ 2312, 4135, 6259, 6260, 20613,
};
static const short dep192[] = {
- 32, 33, 88, 126, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2297,
- 4127, 10341, 20605,
+ 40, 41, 96, 134, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2312,
+ 4135, 10349, 20613,
};
static const short dep193[] = {
- 32, 33, 88, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2297, 4127,
- 6178, 20605,
+ 40, 41, 96, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2312, 4135,
+ 6186, 20613,
};
static const short dep194[] = {
- 68, 70, 71, 88, 89, 90, 91, 238, 239, 252, 253, 254,
+ 76, 78, 79, 96, 97, 98, 99, 253, 254, 267, 268, 269,
};
static const short dep195[] = {
- 32, 33, 69, 70, 74, 76, 88, 91, 93, 95, 98, 126, 166, 170, 238, 240, 252,
- 253, 255, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 4127, 20605,
+ 40, 41, 77, 78, 82, 84, 96, 99, 101, 103, 106, 134, 174, 178, 253, 255, 267,
+ 268, 270, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 4135, 20613,
};
static const short dep196[] = {
- 68, 70, 71, 72, 88, 89, 90, 91, 94, 238, 239, 241, 252, 253, 254,
+ 76, 78, 79, 80, 96, 97, 98, 99, 102, 253, 254, 256, 267, 268, 269,
};
static const short dep197[] = {
- 32, 33, 69, 70, 72, 74, 76, 88, 91, 93, 94, 95, 98, 126, 166, 170, 238, 240,
- 241, 252, 253, 255, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 4127, 20605,
+ 40, 41, 77, 78, 80, 82, 84, 96, 99, 101, 102, 103, 106, 134, 174, 178, 253,
+ 255, 256, 267, 268, 270, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 4135, 20613,
};
static const short dep198[] = {
- 68, 70, 71, 75, 76, 77, 88, 89, 90, 91, 238, 239, 244, 245, 252, 253, 254,
+ 76, 78, 79, 83, 84, 85, 96, 97, 98, 99, 253, 254, 259, 260, 267, 268, 269,
};
static const short dep199[] = {
- 32, 33, 69, 70, 74, 76, 88, 91, 93, 126, 166, 170, 238, 240, 243, 245, 252,
- 253, 255, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 4127, 20605,
+ 40, 41, 77, 78, 82, 84, 96, 99, 101, 134, 174, 178, 253, 255, 258, 260, 267,
+ 268, 270, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 4135, 20613,
};
static const short dep200[] = {
- 68, 70, 71, 88, 89, 90, 91, 97, 98, 99, 238, 239, 252, 253, 254, 257, 258,
+ 76, 78, 79, 96, 97, 98, 99, 105, 106, 107, 253, 254, 267, 268, 269, 272, 273,
};
static const short dep201[] = {
- 32, 33, 69, 70, 88, 91, 93, 95, 98, 126, 166, 170, 238, 240, 252, 253, 255,
- 256, 258, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 4127, 20605,
+ 40, 41, 77, 78, 96, 99, 101, 103, 106, 134, 174, 178, 253, 255, 267, 268,
+ 270, 271, 273, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 4135, 20613,
};
static const short dep202[] = {
- 32, 33, 38, 62, 88, 166, 170, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164,
- 2297, 4127, 20605,
+ 40, 41, 46, 70, 96, 174, 178, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172,
+ 2312, 4135, 20613,
};
static const short dep203[] = {
- 32, 33, 88, 166, 170, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2297,
- 4127, 20605,
+ 40, 41, 96, 174, 178, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2312,
+ 4135, 20613,
};
static const short dep204[] = {
- 32, 33, 68, 73, 75, 88, 126, 166, 170, 252, 2129, 2130, 2131, 2157, 2158,
- 2161, 2164, 2297, 4127, 20605,
+ 40, 41, 76, 81, 83, 96, 134, 174, 178, 267, 2137, 2138, 2139, 2165, 2166,
+ 2169, 2172, 2312, 4135, 20613,
};
static const short dep205[] = {
- 32, 33, 88, 148, 166, 167, 252, 2126, 2127, 2128, 2129, 2130, 2131, 2157,
- 2158, 2161, 2164, 4127, 16516, 16518, 20605,
+ 40, 41, 96, 156, 174, 175, 267, 2134, 2135, 2136, 2137, 2138, 2139, 2165,
+ 2166, 2169, 2172, 4135, 16524, 16526, 20613,
};
static const short dep206[] = {
- 32, 33, 68, 73, 75, 88, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164,
- 4127, 20605,
+ 40, 41, 76, 81, 83, 96, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172,
+ 4135, 20613,
};
static const short dep207[] = {
- 32, 33, 69, 70, 88, 91, 126, 166, 238, 240, 252, 253, 255, 2129, 2130, 2131,
- 2157, 2158, 2161, 2164, 4127, 20605,
+ 40, 41, 77, 78, 96, 99, 134, 174, 253, 255, 267, 268, 270, 2137, 2138, 2139,
+ 2165, 2166, 2169, 2172, 4135, 20613,
};
static const short dep208[] = {
- 32, 33, 67, 68, 73, 75, 88, 100, 102, 119, 120, 122, 123, 126, 127, 128, 130,
- 131, 138, 155, 166, 170, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2297,
- 4127, 20605,
+ 40, 41, 75, 76, 81, 83, 96, 108, 110, 127, 128, 130, 131, 134, 135, 136, 138,
+ 139, 146, 163, 174, 178, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2312,
+ 4135, 20613,
};
static const short dep209[] = {
- 32, 33, 36, 67, 68, 73, 75, 88, 100, 102, 119, 120, 122, 123, 126, 127, 128,
- 130, 131, 138, 140, 155, 166, 170, 252, 2129, 2130, 2131, 2157, 2158, 2161,
- 2164, 2297, 4127, 20605,
+ 5, 96, 186, 267, 2139, 2312,
};
static const short dep210[] = {
- 0, 88, 173, 252, 2131, 2297,
+ 40, 41, 75, 76, 81, 83, 96, 108, 110, 127, 128, 130, 131, 134, 135, 136, 138,
+ 139, 146, 163, 174, 178, 186, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172,
+ 2312, 4135, 20613,
};
static const short dep211[] = {
- 0, 32, 33, 67, 68, 73, 75, 88, 100, 102, 119, 120, 122, 123, 126, 127, 128,
- 130, 131, 138, 155, 166, 170, 173, 252, 2129, 2130, 2131, 2157, 2158, 2161,
- 2164, 2297, 4127, 20605,
+ 40, 41, 44, 75, 76, 81, 83, 96, 108, 110, 127, 128, 130, 131, 134, 135, 136,
+ 138, 139, 146, 148, 163, 174, 178, 267, 2137, 2138, 2139, 2165, 2166, 2169,
+ 2172, 2312, 4135, 20613,
};
static const short dep212[] = {
- 0, 32, 33, 36, 67, 68, 73, 75, 88, 100, 102, 119, 120, 122, 123, 126, 127,
- 128, 130, 131, 138, 140, 155, 166, 170, 173, 252, 2129, 2130, 2131, 2157,
- 2158, 2161, 2164, 2297, 4127, 20605,
+ 0, 96, 181, 267, 2139, 2312,
};
static const short dep213[] = {
- 23, 32, 33, 67, 68, 73, 75, 88, 100, 102, 119, 120, 122, 123, 126, 127, 128,
- 130, 131, 138, 155, 166, 170, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164,
- 2297, 4127, 20605,
+ 0, 40, 41, 75, 76, 81, 83, 96, 108, 110, 127, 128, 130, 131, 134, 135, 136,
+ 138, 139, 146, 163, 174, 178, 181, 267, 2137, 2138, 2139, 2165, 2166, 2169,
+ 2172, 2312, 4135, 20613,
};
static const short dep214[] = {
- 0, 88, 173, 252, 2297, 26706,
+ 0, 40, 41, 44, 75, 76, 81, 83, 96, 108, 110, 127, 128, 130, 131, 134, 135,
+ 136, 138, 139, 146, 148, 163, 174, 178, 181, 267, 2137, 2138, 2139, 2165,
+ 2166, 2169, 2172, 2312, 4135, 20613,
};
static const short dep215[] = {
- 0, 88, 100, 173, 252, 259,
+ 31, 40, 41, 75, 76, 81, 83, 96, 108, 110, 127, 128, 130, 131, 134, 135, 136,
+ 138, 139, 146, 163, 174, 178, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172,
+ 2312, 4135, 20613,
};
static const short dep216[] = {
- 0, 32, 33, 67, 68, 73, 75, 88, 102, 119, 120, 122, 123, 126, 127, 128, 130,
- 131, 138, 155, 166, 170, 173, 252, 259, 2129, 2130, 2131, 2157, 2158, 2161,
- 2164, 4127, 20605,
+ 0, 96, 181, 267, 2312, 26714,
};
static const short dep217[] = {
- 0, 23, 88, 100, 173, 204, 252, 259,
+ 0, 96, 108, 181, 267, 274,
};
static const short dep218[] = {
- 0, 32, 33, 67, 68, 73, 75, 88, 102, 119, 120, 122, 123, 126, 127, 128, 130,
- 131, 138, 155, 166, 170, 173, 204, 252, 259, 2129, 2130, 2131, 2157, 2158,
- 2161, 2164, 4127, 20605,
+ 0, 40, 41, 75, 76, 81, 83, 96, 110, 127, 128, 130, 131, 134, 135, 136, 138,
+ 139, 146, 163, 174, 178, 181, 267, 274, 2137, 2138, 2139, 2165, 2166, 2169,
+ 2172, 4135, 20613,
};
static const short dep219[] = {
- 0, 88, 100, 173, 252, 259, 2131, 2297,
+ 0, 5, 40, 41, 75, 76, 81, 83, 96, 110, 127, 128, 130, 131, 134, 135, 136,
+ 138, 139, 146, 163, 174, 178, 181, 267, 274, 2137, 2138, 2139, 2165, 2166,
+ 2169, 2172, 4135, 20613,
};
static const short dep220[] = {
- 0, 3, 32, 33, 67, 68, 73, 75, 88, 100, 102, 119, 120, 122, 123, 126, 127,
- 128, 130, 131, 138, 155, 166, 170, 173, 252, 259, 2129, 2130, 2131, 2157,
- 2158, 2161, 2164, 2297, 4127, 20605,
+ 0, 31, 96, 108, 181, 219, 267, 274,
};
static const short dep221[] = {
- 0, 32, 33, 67, 68, 73, 75, 88, 100, 102, 119, 120, 122, 123, 126, 127, 128,
- 130, 131, 138, 155, 166, 170, 173, 252, 259, 2129, 2130, 2131, 2157, 2158,
- 2161, 2164, 2297, 4127, 20605,
+ 0, 40, 41, 75, 76, 81, 83, 96, 110, 127, 128, 130, 131, 134, 135, 136, 138,
+ 139, 146, 163, 174, 178, 181, 219, 267, 274, 2137, 2138, 2139, 2165, 2166,
+ 2169, 2172, 4135, 20613,
};
static const short dep222[] = {
- 32, 33, 88, 166, 252, 2126, 2127, 2128, 2157, 2158, 2161, 2164, 2297, 4127,
- 16516, 16518, 20605,
+ 0, 96, 108, 181, 267, 274, 2139, 2312,
};
static const short dep223[] = {
- 0, 32, 33, 67, 68, 73, 75, 88, 102, 119, 120, 122, 123, 126, 127, 128, 130,
- 131, 138, 155, 166, 170, 173, 252, 259, 2129, 2130, 2131, 2157, 2158, 2161,
- 2164, 2297, 4127, 20605,
+ 0, 4, 40, 41, 75, 76, 81, 83, 96, 108, 110, 127, 128, 130, 131, 134, 135,
+ 136, 138, 139, 146, 163, 174, 178, 181, 267, 274, 2137, 2138, 2139, 2165,
+ 2166, 2169, 2172, 2312, 4135, 20613,
};
static const short dep224[] = {
- 0, 23, 88, 100, 173, 204, 252, 259, 2131, 2297,
+ 0, 4, 5, 40, 41, 75, 76, 81, 83, 96, 108, 110, 127, 128, 130, 131, 134, 135,
+ 136, 138, 139, 146, 163, 174, 178, 181, 267, 274, 2137, 2138, 2139, 2165,
+ 2166, 2169, 2172, 2312, 4135, 20613,
};
static const short dep225[] = {
- 0, 32, 33, 67, 68, 73, 75, 88, 102, 119, 120, 122, 123, 126, 127, 128, 130,
- 131, 138, 155, 166, 170, 173, 204, 252, 259, 2129, 2130, 2131, 2157, 2158,
- 2161, 2164, 2297, 4127, 20605,
+ 0, 40, 41, 75, 76, 81, 83, 96, 108, 110, 127, 128, 130, 131, 134, 135, 136,
+ 138, 139, 146, 163, 174, 178, 181, 267, 274, 2137, 2138, 2139, 2165, 2166,
+ 2169, 2172, 2312, 4135, 20613,
};
static const short dep226[] = {
- 32, 33, 67, 68, 73, 75, 88, 100, 102, 119, 120, 122, 123, 126, 127, 128, 130,
- 131, 138, 155, 166, 170, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2295,
- 4127, 16516, 16518, 18731, 18733, 18734, 18736, 20605,
+ 40, 41, 96, 174, 267, 2134, 2135, 2136, 2165, 2166, 2169, 2172, 2312, 4135,
+ 16524, 16526, 20613,
};
static const short dep227[] = {
- 32, 33, 36, 67, 68, 73, 75, 88, 100, 102, 119, 120, 122, 123, 126, 127, 128,
- 130, 131, 138, 140, 155, 166, 170, 252, 2129, 2130, 2131, 2157, 2158, 2161,
- 2164, 2295, 4127, 16516, 16518, 18731, 18733, 18734, 18736, 20605,
+ 0, 40, 41, 75, 76, 81, 83, 96, 110, 127, 128, 130, 131, 134, 135, 136, 138,
+ 139, 146, 163, 174, 178, 181, 267, 274, 2137, 2138, 2139, 2165, 2166, 2169,
+ 2172, 2312, 4135, 20613,
};
static const short dep228[] = {
- 0, 88, 173, 252, 2127, 2295, 18585, 18586, 18731, 18732, 18734, 18735,
+ 0, 31, 96, 108, 181, 219, 267, 274, 2139, 2312,
};
static const short dep229[] = {
- 0, 32, 33, 67, 68, 73, 75, 88, 100, 102, 119, 120, 122, 123, 126, 127, 128,
- 130, 131, 138, 155, 166, 170, 173, 252, 2129, 2130, 2131, 2157, 2158, 2161,
- 2164, 2295, 4127, 16516, 16518, 18731, 18733, 18734, 18736, 20605,
+ 0, 40, 41, 75, 76, 81, 83, 96, 110, 127, 128, 130, 131, 134, 135, 136, 138,
+ 139, 146, 163, 174, 178, 181, 219, 267, 274, 2137, 2138, 2139, 2165, 2166,
+ 2169, 2172, 2312, 4135, 20613,
};
static const short dep230[] = {
- 0, 32, 33, 36, 67, 68, 73, 75, 88, 100, 102, 119, 120, 122, 123, 126, 127,
- 128, 130, 131, 138, 140, 155, 166, 170, 173, 252, 2129, 2130, 2131, 2157,
- 2158, 2161, 2164, 2295, 4127, 16516, 16518, 18731, 18733, 18734, 18736, 20605,
-
+ 40, 41, 75, 76, 81, 83, 96, 108, 110, 127, 128, 130, 131, 134, 135, 136, 138,
+ 139, 146, 163, 174, 178, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2310,
+ 4135, 16524, 16526, 18746, 18748, 18749, 18751, 20613,
};
static const short dep231[] = {
- 0, 88, 173, 252, 2128, 2295, 18585, 18586, 18731, 18732, 18734, 18735,
+ 40, 41, 44, 75, 76, 81, 83, 96, 108, 110, 127, 128, 130, 131, 134, 135, 136,
+ 138, 139, 146, 148, 163, 174, 178, 267, 2137, 2138, 2139, 2165, 2166, 2169,
+ 2172, 2310, 4135, 16524, 16526, 18746, 18748, 18749, 18751, 20613,
};
static const short dep232[] = {
- 32, 33, 67, 88, 126, 140, 166, 252, 2157, 2158, 2161, 2164, 4127,
+ 0, 96, 181, 267, 2135, 2310, 18593, 18594, 18746, 18747, 18749, 18750,
};
static const short dep233[] = {
- 32, 33, 67, 88, 126, 127, 131, 140, 166, 252, 2157, 2158, 2161, 2164, 4127,
-
+ 0, 40, 41, 75, 76, 81, 83, 96, 108, 110, 127, 128, 130, 131, 134, 135, 136,
+ 138, 139, 146, 163, 174, 178, 181, 267, 2137, 2138, 2139, 2165, 2166, 2169,
+ 2172, 2310, 4135, 16524, 16526, 18746, 18748, 18749, 18751, 20613,
};
static const short dep234[] = {
- 32, 33, 67, 88, 126, 140, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164,
- 2297, 4127, 20605,
+ 0, 40, 41, 44, 75, 76, 81, 83, 96, 108, 110, 127, 128, 130, 131, 134, 135,
+ 136, 138, 139, 146, 148, 163, 174, 178, 181, 267, 2137, 2138, 2139, 2165,
+ 2166, 2169, 2172, 2310, 4135, 16524, 16526, 18746, 18748, 18749, 18751, 20613,
+
};
static const short dep235[] = {
- 32, 33, 67, 88, 126, 127, 131, 140, 166, 252, 2129, 2130, 2131, 2157, 2158,
- 2161, 2164, 2297, 4127, 20605,
+ 0, 96, 181, 267, 2136, 2310, 18593, 18594, 18746, 18747, 18749, 18750,
};
static const short dep236[] = {
- 32, 33, 88, 166, 252, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2295, 4127,
- 16516, 16518, 18731, 18733, 18734, 18736, 20605,
+ 0, 40, 41, 75, 76, 81, 83, 96, 110, 127, 128, 130, 131, 134, 135, 136, 138,
+ 139, 146, 163, 174, 178, 181, 267, 274, 2134, 2135, 2136, 2137, 2138, 2139,
+ 2165, 2166, 2169, 2172, 4135, 16524, 16526, 20613,
};
static const short dep237[] = {
- 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 17, 19, 20, 21, 22, 23,
- 88, 174, 175, 176, 177, 178, 179, 180, 181, 183, 184, 186, 187, 189, 190,
- 192, 193, 194, 195, 196, 198, 201, 202, 203, 204, 252, 2064, 2073, 2131, 2245,
- 2254, 2297, 28844, 28987,
+ 40, 41, 75, 96, 134, 148, 174, 267, 2165, 2166, 2169, 2172, 4135,
};
static const short dep238[] = {
- 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 17, 18, 19, 21, 22, 23,
- 32, 33, 88, 126, 163, 166, 174, 175, 176, 177, 178, 179, 180, 181, 183, 184,
- 186, 187, 189, 190, 192, 193, 194, 195, 196, 198, 200, 202, 203, 204, 252,
- 2064, 2073, 2129, 2130, 2131, 2157, 2158, 2161, 2164, 2245, 2254, 2297, 4127,
- 20605, 28844, 28987,
+ 40, 41, 75, 96, 134, 135, 139, 148, 174, 267, 2165, 2166, 2169, 2172, 4135,
+
+};
+
+static const short dep239[] = {
+ 40, 41, 75, 96, 134, 148, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172,
+ 2312, 4135, 20613,
+};
+
+static const short dep240[] = {
+ 40, 41, 75, 96, 134, 135, 139, 148, 174, 267, 2137, 2138, 2139, 2165, 2166,
+ 2169, 2172, 2312, 4135, 20613,
+};
+
+static const short dep241[] = {
+ 40, 41, 96, 174, 267, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2310, 4135,
+ 16524, 16526, 18746, 18748, 18749, 18751, 20613,
+};
+
+static const short dep242[] = {
+ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21,
+ 22, 24, 26, 27, 28, 29, 30, 31, 96, 182, 183, 184, 185, 186, 187, 188, 189,
+ 190, 191, 192, 193, 194, 195, 197, 198, 200, 201, 203, 204, 206, 207, 208,
+ 209, 210, 211, 213, 216, 217, 218, 219, 267, 2071, 2081, 2139, 2260, 2269,
+ 2312, 28852, 29002,
+};
+
+static const short dep243[] = {
+ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21,
+ 22, 24, 25, 26, 28, 29, 30, 31, 40, 41, 96, 134, 171, 174, 182, 183, 184,
+ 185, 186, 187, 188, 189, 190, 191, 192, 193, 194, 195, 197, 198, 200, 201,
+ 203, 204, 206, 207, 208, 209, 210, 211, 213, 215, 217, 218, 219, 267, 2071,
+ 2081, 2137, 2138, 2139, 2165, 2166, 2169, 2172, 2260, 2269, 2312, 4135, 20613,
+ 28852, 29002,
};
#define NELS(X) (sizeof(X)/sizeof(X[0]))
@@ -1660,30 +1718,34 @@ op_dependencies[] = {
{ NELS(dep206), dep206, NELS(dep31), dep31, },
{ NELS(dep207), dep207, NELS(dep194), dep194, },
{ NELS(dep208), dep208, NELS(dep0), dep0, },
- { NELS(dep209), dep209, NELS(dep0), dep0, },
- { NELS(dep211), dep211, NELS(dep210), dep210, },
- { NELS(dep212), dep212, NELS(dep210), dep210, },
- { NELS(dep213), dep213, NELS(dep0), dep0, },
- { NELS(dep211), dep211, NELS(dep214), dep214, },
- { NELS(dep216), dep216, NELS(dep215), dep215, },
+ { NELS(dep210), dep210, NELS(dep209), dep209, },
+ { NELS(dep211), dep211, NELS(dep0), dep0, },
+ { NELS(dep213), dep213, NELS(dep212), dep212, },
+ { NELS(dep214), dep214, NELS(dep212), dep212, },
+ { NELS(dep215), dep215, NELS(dep0), dep0, },
+ { NELS(dep213), dep213, NELS(dep216), dep216, },
{ NELS(dep218), dep218, NELS(dep217), dep217, },
- { NELS(dep220), dep220, NELS(dep219), dep219, },
- { NELS(dep221), dep221, NELS(dep219), dep219, },
- { NELS(dep222), dep222, NELS(dep0), dep0, },
- { NELS(dep223), dep223, NELS(dep219), dep219, },
- { NELS(dep225), dep225, NELS(dep224), dep224, },
- { NELS(dep226), dep226, NELS(dep62), dep62, },
- { NELS(dep227), dep227, NELS(dep62), dep62, },
+ { NELS(dep219), dep219, NELS(dep217), dep217, },
+ { NELS(dep221), dep221, NELS(dep220), dep220, },
+ { NELS(dep223), dep223, NELS(dep222), dep222, },
+ { NELS(dep224), dep224, NELS(dep222), dep222, },
+ { NELS(dep225), dep225, NELS(dep222), dep222, },
+ { NELS(dep226), dep226, NELS(dep0), dep0, },
+ { NELS(dep227), dep227, NELS(dep222), dep222, },
{ NELS(dep229), dep229, NELS(dep228), dep228, },
- { NELS(dep230), dep230, NELS(dep228), dep228, },
- { NELS(dep229), dep229, NELS(dep231), dep231, },
- { NELS(dep232), dep232, NELS(dep31), dep31, },
- { NELS(dep233), dep233, NELS(dep31), dep31, },
- { NELS(dep234), dep234, NELS(dep0), dep0, },
- { NELS(dep235), dep235, NELS(dep0), dep0, },
- { NELS(dep236), dep236, NELS(dep62), dep62, },
+ { NELS(dep230), dep230, NELS(dep62), dep62, },
+ { NELS(dep231), dep231, NELS(dep62), dep62, },
+ { NELS(dep233), dep233, NELS(dep232), dep232, },
+ { NELS(dep234), dep234, NELS(dep232), dep232, },
+ { NELS(dep233), dep233, NELS(dep235), dep235, },
+ { NELS(dep236), dep236, NELS(dep217), dep217, },
+ { NELS(dep237), dep237, NELS(dep31), dep31, },
+ { NELS(dep238), dep238, NELS(dep31), dep31, },
+ { NELS(dep239), dep239, NELS(dep0), dep0, },
+ { NELS(dep240), dep240, NELS(dep0), dep0, },
+ { NELS(dep241), dep241, NELS(dep62), dep62, },
{ 0, NULL, 0, NULL, },
- { NELS(dep238), dep238, NELS(dep237), dep237, },
+ { NELS(dep243), dep243, NELS(dep242), dep242, },
};
static const struct ia64_completer_table
@@ -1701,36 +1763,36 @@ completer_table[] = {
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
- { 0x0, 0x0, 0, 449, -1, 0, 1, 6 },
- { 0x0, 0x0, 0, 512, -1, 0, 1, 17 },
- { 0x0, 0x0, 0, -1, -1, 0, 1, 147 },
- { 0x0, 0x0, 0, 611, -1, 0, 1, 17 },
- { 0x0, 0x0, 0, 1815, -1, 0, 1, 10 },
+ { 0x0, 0x0, 0, 455, -1, 0, 1, 6 },
+ { 0x0, 0x0, 0, 518, -1, 0, 1, 17 },
+ { 0x0, 0x0, 0, -1, -1, 0, 1, 151 },
+ { 0x0, 0x0, 0, 617, -1, 0, 1, 17 },
+ { 0x0, 0x0, 0, 1836, -1, 0, 1, 10 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 9 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 13 },
{ 0x1, 0x1, 0, -1, -1, 13, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 33 },
- { 0x0, 0x0, 0, 1991, -1, 0, 1, 29 },
+ { 0x0, 0x0, 0, 2014, -1, 0, 1, 29 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 29 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 29 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 33 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 33 },
- { 0x0, 0x0, 0, -1, -1, 0, 1, 122 },
+ { 0x0, 0x0, 0, 958, -1, 0, 1, 122 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 44 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 40 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 78 },
- { 0x0, 0x0, 0, 1855, -1, 0, 1, 29 },
+ { 0x0, 0x0, 0, 1878, -1, 0, 1, 29 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 29 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 29 },
- { 0x0, 0x0, 0, 2034, -1, 0, 1, 29 },
- { 0x0, 0x0, 0, 1859, -1, 0, 1, 29 },
+ { 0x0, 0x0, 0, 2057, -1, 0, 1, 29 },
+ { 0x0, 0x0, 0, 1882, -1, 0, 1, 29 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 33 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 33 },
- { 0x0, 0x0, 0, 1861, -1, 0, 1, 29 },
- { 0x0, 0x0, 0, 2043, -1, 0, 1, 29 },
- { 0x0, 0x0, 0, 2046, -1, 0, 1, 29 },
+ { 0x0, 0x0, 0, 1884, -1, 0, 1, 29 },
+ { 0x0, 0x0, 0, 2066, -1, 0, 1, 29 },
+ { 0x0, 0x0, 0, 2069, -1, 0, 1, 29 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 33 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 33 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 33 },
@@ -1739,64 +1801,66 @@ completer_table[] = {
{ 0x0, 0x0, 0, -1, -1, 0, 1, 29 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 29 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 29 },
- { 0x0, 0x0, 0, 2068, -1, 0, 1, 29 },
+ { 0x0, 0x0, 0, 2091, -1, 0, 1, 29 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 29 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 33 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 33 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 29 },
- { 0x0, 0x0, 0, 2071, -1, 0, 1, 29 },
+ { 0x0, 0x0, 0, 2094, -1, 0, 1, 29 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 24 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 24 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 24 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 24 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 33 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 35 },
- { 0x0, 0x0, 0, 2079, -1, 0, 1, 29 },
- { 0x0, 0x0, 0, 1170, -1, 0, 1, 33 },
+ { 0x0, 0x0, 0, 2102, -1, 0, 1, 29 },
+ { 0x0, 0x0, 0, 1181, -1, 0, 1, 33 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 40 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 33 },
+ { 0x0, 0x0, 0, -1, -1, 0, 1, 151 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 77 },
- { 0x0, 0x0, 0, 1203, -1, 0, 1, 124 },
- { 0x0, 0x0, 0, 1212, -1, 0, 1, 124 },
- { 0x0, 0x0, 0, 1221, -1, 0, 1, 124 },
- { 0x0, 0x0, 0, 1230, -1, 0, 1, 124 },
- { 0x0, 0x0, 0, 1239, -1, 0, 1, 124 },
- { 0x0, 0x0, 0, 1248, -1, 0, 1, 124 },
- { 0x0, 0x0, 0, 1257, -1, 0, 1, 124 },
- { 0x0, 0x0, 0, 1266, -1, 0, 1, 124 },
- { 0x0, 0x0, 0, 1275, -1, 0, 1, 124 },
- { 0x0, 0x0, 0, 1285, -1, 0, 1, 124 },
- { 0x0, 0x0, 0, 1295, -1, 0, 1, 124 },
- { 0x0, 0x0, 0, 1305, -1, 0, 1, 124 },
- { 0x0, 0x0, 0, 1314, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1320, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1326, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1332, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1338, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1344, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1350, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1356, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1362, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1368, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1374, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1380, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1386, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1392, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1398, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1404, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1410, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1416, -1, 0, 1, 137 },
- { 0x0, 0x0, 0, 1420, -1, 0, 1, 142 },
- { 0x0, 0x0, 0, 1424, -1, 0, 1, 144 },
- { 0x0, 0x0, 0, 1428, -1, 0, 1, 144 },
+ { 0x0, 0x0, 0, 1216, -1, 0, 1, 124 },
+ { 0x0, 0x0, 0, 1225, -1, 0, 1, 124 },
+ { 0x0, 0x0, 0, 1234, -1, 0, 1, 124 },
+ { 0x0, 0x0, 0, 1236, -1, 0, 1, 125 },
+ { 0x0, 0x0, 0, 1245, -1, 0, 1, 124 },
+ { 0x0, 0x0, 0, 1254, -1, 0, 1, 124 },
+ { 0x0, 0x0, 0, 1263, -1, 0, 1, 124 },
+ { 0x0, 0x0, 0, 1272, -1, 0, 1, 124 },
+ { 0x0, 0x0, 0, 1281, -1, 0, 1, 124 },
+ { 0x0, 0x0, 0, 1290, -1, 0, 1, 124 },
+ { 0x0, 0x0, 0, 1300, -1, 0, 1, 124 },
+ { 0x0, 0x0, 0, 1310, -1, 0, 1, 124 },
+ { 0x0, 0x0, 0, 1320, -1, 0, 1, 124 },
+ { 0x0, 0x0, 0, 1329, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1335, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1341, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1347, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1353, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1359, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1365, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1371, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1377, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1383, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1389, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1395, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1401, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1407, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1413, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1419, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1425, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1431, -1, 0, 1, 140 },
+ { 0x0, 0x0, 0, 1435, -1, 0, 1, 146 },
+ { 0x0, 0x0, 0, 1439, -1, 0, 1, 148 },
+ { 0x0, 0x0, 0, 1443, -1, 0, 1, 148 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 79 },
- { 0x0, 0x0, 0, 250, -1, 0, 1, 40 },
+ { 0x0, 0x0, 0, 253, -1, 0, 1, 40 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 33 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 67 },
- { 0x1, 0x1, 0, 975, -1, 20, 1, 67 },
+ { 0x1, 0x1, 0, 984, -1, 20, 1, 67 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 68 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 69 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 70 },
@@ -1823,25 +1887,25 @@ completer_table[] = {
{ 0x0, 0x0, 0, -1, -1, 0, 1, 111 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 112 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 113 },
- { 0x0, 0x0, 0, -1, -1, 0, 1, 148 },
- { 0x0, 0x0, 0, -1, -1, 0, 1, 148 },
- { 0x0, 0x0, 0, -1, -1, 0, 1, 148 },
+ { 0x0, 0x0, 0, -1, -1, 0, 1, 152 },
+ { 0x0, 0x0, 0, -1, -1, 0, 1, 152 },
+ { 0x0, 0x0, 0, -1, -1, 0, 1, 152 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 71 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
- { 0x0, 0x0, 0, -1, -1, 0, 1, 147 },
+ { 0x0, 0x0, 0, -1, -1, 0, 1, 151 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
- { 0x0, 0x0, 0, 2371, -1, 0, 1, 0 },
- { 0x0, 0x0, 0, 2372, -1, 0, 1, 0 },
+ { 0x0, 0x0, 0, 2394, -1, 0, 1, 0 },
+ { 0x0, 0x0, 0, 2395, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
- { 0x0, 0x0, 0, 1827, -1, 0, 1, 0 },
- { 0x0, 0x0, 0, 1828, -1, 0, 1, 0 },
+ { 0x0, 0x0, 0, 1848, -1, 0, 1, 0 },
+ { 0x0, 0x0, 0, 1849, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
- { 0x0, 0x0, 0, 2386, -1, 0, 1, 0 },
+ { 0x0, 0x0, 0, 2409, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
@@ -1849,13 +1913,13 @@ completer_table[] = {
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
- { 0x0, 0x0, 0, 2387, -1, 0, 1, 0 },
- { 0x0, 0x0, 0, 2388, -1, 0, 1, 0 },
- { 0x0, 0x0, 0, 2389, -1, 0, 1, 0 },
- { 0x0, 0x0, 0, 2390, -1, 0, 1, 0 },
+ { 0x0, 0x0, 0, 2410, -1, 0, 1, 0 },
+ { 0x0, 0x0, 0, 2411, -1, 0, 1, 0 },
+ { 0x0, 0x0, 0, 2412, -1, 0, 1, 0 },
+ { 0x0, 0x0, 0, 2413, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
- { 0x0, 0x0, 0, 2373, -1, 0, 1, 0 },
- { 0x0, 0x0, 0, 2374, -1, 0, 1, 0 },
+ { 0x0, 0x0, 0, 2396, -1, 0, 1, 0 },
+ { 0x0, 0x0, 0, 2397, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 11 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 84 },
@@ -1865,25 +1929,26 @@ completer_table[] = {
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x1, 0x1, 0, -1, -1, 13, 1, 0 },
- { 0x0, 0x0, 0, 2392, -1, 0, 1, 0 },
+ { 0x0, 0x0, 0, 2415, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 84 },
- { 0x0, 0x0, 0, 1692, -1, 0, 1, 130 },
- { 0x0, 0x0, 0, 1694, -1, 0, 1, 135 },
- { 0x0, 0x0, 0, 1696, -1, 0, 1, 130 },
- { 0x0, 0x0, 0, 1698, -1, 0, 1, 135 },
- { 0x0, 0x0, 0, 1700, -1, 0, 1, 130 },
- { 0x0, 0x0, 0, 1702, -1, 0, 1, 135 },
- { 0x0, 0x0, 0, 1705, -1, 0, 1, 130 },
- { 0x0, 0x0, 0, 1708, -1, 0, 1, 135 },
- { 0x0, 0x0, 0, 1711, -1, 0, 1, 130 },
- { 0x0, 0x0, 0, 1712, -1, 0, 1, 130 },
- { 0x0, 0x0, 0, 1713, -1, 0, 1, 130 },
- { 0x0, 0x0, 0, 1714, -1, 0, 1, 130 },
- { 0x0, 0x0, 0, 1715, -1, 0, 1, 130 },
- { 0x0, 0x0, 0, 1716, -1, 0, 1, 130 },
- { 0x0, 0x0, 0, 1717, -1, 0, 1, 130 },
- { 0x0, 0x0, 0, 1718, -1, 0, 1, 130 },
+ { 0x0, 0x0, 0, 1711, -1, 0, 1, 131 },
+ { 0x0, 0x0, 0, 1713, -1, 0, 1, 138 },
+ { 0x0, 0x0, 0, 1715, -1, 0, 1, 132 },
+ { 0x0, 0x0, 0, 1717, -1, 0, 1, 131 },
+ { 0x0, 0x0, 0, 1719, -1, 0, 1, 138 },
+ { 0x0, 0x0, 0, 1721, -1, 0, 1, 131 },
+ { 0x0, 0x0, 0, 1723, -1, 0, 1, 138 },
+ { 0x0, 0x0, 0, 1726, -1, 0, 1, 131 },
+ { 0x0, 0x0, 0, 1729, -1, 0, 1, 138 },
+ { 0x0, 0x0, 0, 1732, -1, 0, 1, 145 },
+ { 0x0, 0x0, 0, 1733, -1, 0, 1, 145 },
+ { 0x0, 0x0, 0, 1734, -1, 0, 1, 145 },
+ { 0x0, 0x0, 0, 1735, -1, 0, 1, 145 },
+ { 0x0, 0x0, 0, 1736, -1, 0, 1, 145 },
+ { 0x0, 0x0, 0, 1737, -1, 0, 1, 145 },
+ { 0x0, 0x0, 0, 1738, -1, 0, 1, 145 },
+ { 0x0, 0x0, 0, 1739, -1, 0, 1, 145 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
@@ -1895,116 +1960,97 @@ completer_table[] = {
{ 0x0, 0x0, 0, -1, -1, 0, 1, 118 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 120 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 119 },
- { 0x0, 0x0, 0, 1429, -1, 0, 1, 133 },
- { 0x0, 0x0, 0, 1430, -1, 0, 1, 133 },
- { 0x0, 0x0, 0, 1431, -1, 0, 1, 133 },
- { 0x0, 0x0, 0, 1432, -1, 0, 1, 133 },
+ { 0x0, 0x0, 0, 1444, -1, 0, 1, 136 },
+ { 0x0, 0x0, 0, 1445, -1, 0, 1, 136 },
+ { 0x0, 0x0, 0, 1446, -1, 0, 1, 136 },
+ { 0x0, 0x0, 0, 1447, -1, 0, 1, 136 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
{ 0x0, 0x0, 0, -1, -1, 0, 1, 0 },
- { 0x0, 0x0, 1, 217, -1, 0, 1, 12 },
+ { 0x0, 0x0, 1, 220, -1, 0, 1, 12 },
{ 0x1, 0x1, 2, -1, -1, 27, 1, 12 },
- { 0x0, 0x0, 3, -1, 1112, 0, 0, -1 },
- { 0x0, 0x0, 3, -1, 1113, 0, 0, -1 },
- { 0x1, 0x1, 3, 2262, 1196, 33, 1, 126 },
- { 0x1, 0x1, 3, 2263, 1205, 33, 1, 126 },
- { 0x1, 0x1, 3, 2264, 1214, 33, 1, 126 },
- { 0x1, 0x1, 3, 2265, 1223, 33, 1, 126 },
- { 0x1, 0x1, 3, 2266, 1232, 33, 1, 126 },
- { 0x1, 0x1, 3, 2267, 1241, 33, 1, 126 },
- { 0x1, 0x1, 3, 2268, 1250, 33, 1, 126 },
- { 0x1, 0x1, 3, 2269, 1259, 33, 1, 126 },
- { 0x1, 0x1, 3, 2270, 1268, 33, 1, 126 },
- { 0x1, 0x1, 3, 2271, 1277, 33, 1, 126 },
- { 0x1, 0x1, 3, 2272, 1287, 33, 1, 126 },
- { 0x1, 0x1, 3, 2273, 1297, 33, 1, 126 },
- { 0x1, 0x1, 3, 2274, 1310, 33, 1, 139 },
- { 0x1, 0x1, 3, 2275, 1316, 33, 1, 139 },
- { 0x1, 0x1, 3, 2276, 1322, 33, 1, 139 },
- { 0x1, 0x1, 3, 2277, 1328, 33, 1, 139 },
- { 0x1, 0x1, 3, 2278, 1334, 33, 1, 139 },
- { 0x1, 0x1, 3, 2279, 1340, 33, 1, 139 },
- { 0x1, 0x1, 3, 2280, 1346, 33, 1, 139 },
- { 0x1, 0x1, 3, 2281, 1352, 33, 1, 139 },
- { 0x1, 0x1, 3, 2282, 1358, 33, 1, 139 },
- { 0x1, 0x1, 3, 2283, 1364, 33, 1, 139 },
- { 0x1, 0x1, 3, 2284, 1370, 33, 1, 139 },
- { 0x1, 0x1, 3, 2285, 1376, 33, 1, 139 },
- { 0x1, 0x1, 3, 2286, 1382, 33, 1, 139 },
- { 0x1, 0x1, 3, 2287, 1388, 33, 1, 139 },
- { 0x1, 0x1, 3, 2288, 1394, 33, 1, 139 },
- { 0x1, 0x1, 3, 2289, 1400, 33, 1, 139 },
- { 0x1, 0x1, 3, 2290, 1406, 33, 1, 139 },
- { 0x1, 0x1, 3, 2291, 1412, 33, 1, 139 },
+ { 0x0, 0x0, 3, -1, 1123, 0, 0, -1 },
+ { 0x0, 0x0, 3, -1, 1124, 0, 0, -1 },
+ { 0x1, 0x1, 3, 2285, 1209, 33, 1, 127 },
+ { 0x1, 0x1, 3, 2286, 1218, 33, 1, 127 },
+ { 0x1, 0x1, 3, 2287, 1227, 33, 1, 127 },
+ { 0x1, 0x1, 3, 2288, 1238, 33, 1, 127 },
+ { 0x1, 0x1, 3, 2289, 1247, 33, 1, 127 },
+ { 0x1, 0x1, 3, 2290, 1256, 33, 1, 127 },
+ { 0x1, 0x1, 3, 2291, 1265, 33, 1, 127 },
+ { 0x1, 0x1, 3, 2292, 1274, 33, 1, 127 },
+ { 0x1, 0x1, 3, 2293, 1283, 33, 1, 127 },
+ { 0x1, 0x1, 3, 2294, 1292, 33, 1, 127 },
+ { 0x1, 0x1, 3, 2295, 1302, 33, 1, 127 },
+ { 0x1, 0x1, 3, 2296, 1312, 33, 1, 127 },
+ { 0x1, 0x1, 3, 2297, 1325, 33, 1, 142 },
+ { 0x1, 0x1, 3, 2298, 1331, 33, 1, 142 },
+ { 0x1, 0x1, 3, 2299, 1337, 33, 1, 142 },
+ { 0x1, 0x1, 3, 2300, 1343, 33, 1, 142 },
+ { 0x1, 0x1, 3, 2301, 1349, 33, 1, 142 },
+ { 0x1, 0x1, 3, 2302, 1355, 33, 1, 142 },
+ { 0x1, 0x1, 3, 2303, 1361, 33, 1, 142 },
+ { 0x1, 0x1, 3, 2304, 1367, 33, 1, 142 },
+ { 0x1, 0x1, 3, 2305, 1373, 33, 1, 142 },
+ { 0x1, 0x1, 3, 2306, 1379, 33, 1, 142 },
+ { 0x1, 0x1, 3, 2307, 1385, 33, 1, 142 },
+ { 0x1, 0x1, 3, 2308, 1391, 33, 1, 142 },
+ { 0x1, 0x1, 3, 2309, 1397, 33, 1, 142 },
+ { 0x1, 0x1, 3, 2310, 1403, 33, 1, 142 },
+ { 0x1, 0x1, 3, 2311, 1409, 33, 1, 142 },
+ { 0x1, 0x1, 3, 2312, 1415, 33, 1, 142 },
+ { 0x1, 0x1, 3, 2313, 1421, 33, 1, 142 },
+ { 0x1, 0x1, 3, 2314, 1427, 33, 1, 142 },
{ 0x1, 0x1, 3, -1, -1, 27, 1, 40 },
- { 0x0, 0x0, 4, 1829, 1183, 0, 1, 132 },
- { 0x0, 0x0, 4, 1830, 1185, 0, 1, 132 },
- { 0x0, 0x0, 4, 1831, 1187, 0, 1, 132 },
- { 0x0, 0x0, 4, 1832, 1189, 0, 1, 132 },
- { 0x0, 0x0, 4, 1833, 1191, 0, 1, 133 },
- { 0x0, 0x0, 4, 1834, 1193, 0, 1, 133 },
- { 0x1, 0x1, 4, -1, 1200, 33, 1, 129 },
- { 0x5, 0x5, 4, 407, 1199, 32, 1, 124 },
- { 0x1, 0x1, 4, -1, 1209, 33, 1, 129 },
- { 0x5, 0x5, 4, 408, 1208, 32, 1, 124 },
- { 0x1, 0x1, 4, -1, 1218, 33, 1, 129 },
- { 0x5, 0x5, 4, 409, 1217, 32, 1, 124 },
- { 0x1, 0x1, 4, -1, 1227, 33, 1, 129 },
- { 0x5, 0x5, 4, 410, 1226, 32, 1, 124 },
- { 0x1, 0x1, 4, -1, 1236, 33, 1, 129 },
- { 0x5, 0x5, 4, 411, 1235, 32, 1, 124 },
- { 0x1, 0x1, 4, -1, 1245, 33, 1, 129 },
- { 0x5, 0x5, 4, 412, 1244, 32, 1, 124 },
- { 0x1, 0x1, 4, -1, 1254, 33, 1, 129 },
- { 0x5, 0x5, 4, 413, 1253, 32, 1, 124 },
- { 0x1, 0x1, 4, -1, 1263, 33, 1, 129 },
- { 0x5, 0x5, 4, 414, 1262, 32, 1, 124 },
- { 0x1, 0x1, 4, -1, 1272, 33, 1, 129 },
- { 0x5, 0x5, 4, 415, 1271, 32, 1, 124 },
- { 0x1, 0x1, 4, -1, 1282, 33, 1, 129 },
- { 0x5, 0x5, 4, 881, 1280, 32, 1, 124 },
- { 0x1, 0x1, 4, -1, 1292, 33, 1, 129 },
- { 0x5, 0x5, 4, 882, 1290, 32, 1, 124 },
- { 0x1, 0x1, 4, -1, 1302, 33, 1, 129 },
- { 0x5, 0x5, 4, 883, 1300, 32, 1, 124 },
- { 0x1, 0x21, 10, 1727, -1, 33, 1, 3 },
- { 0x200001, 0x200001, 10, 1728, -1, 12, 1, 3 },
- { 0x0, 0x0, 10, 1729, -1, 0, 1, 3 },
- { 0x1, 0x1, 10, 1730, -1, 12, 1, 3 },
- { 0x1, 0x1, 10, 1731, -1, 33, 1, 3 },
- { 0x200001, 0x200001, 10, 1732, -1, 12, 1, 3 },
- { 0x0, 0x0, 10, 346, -1, 0, 1, 3 },
- { 0x1, 0x1, 10, 1758, -1, 12, 1, 3 },
- { 0x1, 0x1, 10, 350, -1, 33, 1, 3 },
- { 0x200001, 0x200001, 10, 1760, -1, 12, 1, 3 },
- { 0x1, 0x21, 10, 1737, -1, 33, 1, 3 },
- { 0x200001, 0x200001, 10, 1738, -1, 12, 1, 3 },
- { 0x0, 0x0, 10, -1, 1767, 0, 0, -1 },
- { 0x0, 0x0, 10, -1, 1768, 0, 0, -1 },
- { 0x0, 0x0, 10, -1, 1769, 0, 0, -1 },
- { 0x0, 0x0, 10, -1, 1770, 0, 0, -1 },
- { 0x0, 0x0, 10, -1, 1771, 0, 0, -1 },
- { 0x0, 0x0, 10, -1, 1772, 0, 0, -1 },
- { 0x0, 0x0, 10, -1, 1773, 0, 0, -1 },
- { 0x0, 0x0, 10, -1, 1774, 0, 0, -1 },
- { 0x0, 0x0, 10, -1, 1775, 0, 0, -1 },
- { 0x0, 0x0, 10, -1, 1776, 0, 0, -1 },
- { 0x0, 0x0, 10, -1, 1777, 0, 0, -1 },
- { 0x0, 0x0, 10, -1, 1778, 0, 0, -1 },
- { 0x1, 0x21, 10, 1739, -1, 33, 1, 3 },
- { 0x200001, 0x200001, 10, 1740, -1, 12, 1, 3 },
- { 0x0, 0x0, 10, 1741, -1, 0, 1, 3 },
- { 0x1, 0x1, 10, 1742, -1, 12, 1, 3 },
- { 0x1, 0x1, 10, 1743, -1, 33, 1, 3 },
- { 0x200001, 0x200001, 10, 1744, -1, 12, 1, 3 },
- { 0x0, 0x0, 10, 370, -1, 0, 1, 3 },
- { 0x1, 0x1, 10, 1782, -1, 12, 1, 3 },
- { 0x1, 0x1, 10, 374, -1, 33, 1, 3 },
- { 0x200001, 0x200001, 10, 1784, -1, 12, 1, 3 },
- { 0x1, 0x21, 10, 1749, -1, 33, 1, 3 },
- { 0x200001, 0x200001, 10, 1750, -1, 12, 1, 3 },
+ { 0x0, 0x0, 4, 1850, 1194, 0, 1, 135 },
+ { 0x0, 0x0, 4, 1851, 1196, 0, 1, 134 },
+ { 0x0, 0x0, 4, 1852, 1198, 0, 1, 134 },
+ { 0x0, 0x0, 4, 1853, 1200, 0, 1, 134 },
+ { 0x0, 0x0, 4, 1854, 1202, 0, 1, 134 },
+ { 0x0, 0x0, 4, 1855, 1204, 0, 1, 136 },
+ { 0x0, 0x0, 4, 1856, 1206, 0, 1, 136 },
+ { 0x1, 0x1, 4, -1, 1213, 33, 1, 130 },
+ { 0x5, 0x5, 4, 413, 1212, 32, 1, 124 },
+ { 0x1, 0x1, 4, -1, 1222, 33, 1, 130 },
+ { 0x5, 0x5, 4, 414, 1221, 32, 1, 124 },
+ { 0x1, 0x1, 4, -1, 1231, 33, 1, 130 },
+ { 0x5, 0x5, 4, 415, 1230, 32, 1, 124 },
+ { 0x1, 0x1, 4, -1, 1235, 32, 1, 125 },
+ { 0x1, 0x1, 4, -1, 1242, 33, 1, 130 },
+ { 0x5, 0x5, 4, 416, 1241, 32, 1, 124 },
+ { 0x1, 0x1, 4, -1, 1251, 33, 1, 130 },
+ { 0x5, 0x5, 4, 417, 1250, 32, 1, 124 },
+ { 0x1, 0x1, 4, -1, 1260, 33, 1, 130 },
+ { 0x5, 0x5, 4, 418, 1259, 32, 1, 124 },
+ { 0x1, 0x1, 4, -1, 1269, 33, 1, 130 },
+ { 0x5, 0x5, 4, 419, 1268, 32, 1, 124 },
+ { 0x1, 0x1, 4, -1, 1278, 33, 1, 130 },
+ { 0x5, 0x5, 4, 420, 1277, 32, 1, 124 },
+ { 0x1, 0x1, 4, -1, 1287, 33, 1, 130 },
+ { 0x5, 0x5, 4, 421, 1286, 32, 1, 124 },
+ { 0x1, 0x1, 4, -1, 1297, 33, 1, 130 },
+ { 0x5, 0x5, 4, 888, 1295, 32, 1, 124 },
+ { 0x1, 0x1, 4, -1, 1307, 33, 1, 130 },
+ { 0x5, 0x5, 4, 889, 1305, 32, 1, 124 },
+ { 0x1, 0x1, 4, -1, 1317, 33, 1, 130 },
+ { 0x5, 0x5, 4, 890, 1315, 32, 1, 124 },
+ { 0x1, 0x21, 10, 1748, -1, 33, 1, 3 },
+ { 0x200001, 0x200001, 10, 1749, -1, 12, 1, 3 },
+ { 0x0, 0x0, 10, 1750, -1, 0, 1, 3 },
+ { 0x1, 0x1, 10, 1751, -1, 12, 1, 3 },
+ { 0x1, 0x1, 10, 1752, -1, 33, 1, 3 },
+ { 0x200001, 0x200001, 10, 1753, -1, 12, 1, 3 },
+ { 0x0, 0x0, 10, 351, -1, 0, 1, 3 },
+ { 0x1, 0x1, 10, 1779, -1, 12, 1, 3 },
+ { 0x1, 0x1, 10, 355, -1, 33, 1, 3 },
+ { 0x200001, 0x200001, 10, 1781, -1, 12, 1, 3 },
+ { 0x1, 0x21, 10, 1758, -1, 33, 1, 3 },
+ { 0x200001, 0x200001, 10, 1759, -1, 12, 1, 3 },
+ { 0x0, 0x0, 10, -1, 1788, 0, 0, -1 },
+ { 0x0, 0x0, 10, -1, 1789, 0, 0, -1 },
+ { 0x0, 0x0, 10, -1, 1790, 0, 0, -1 },
{ 0x0, 0x0, 10, -1, 1791, 0, 0, -1 },
{ 0x0, 0x0, 10, -1, 1792, 0, 0, -1 },
{ 0x0, 0x0, 10, -1, 1793, 0, 0, -1 },
@@ -2014,93 +2060,109 @@ completer_table[] = {
{ 0x0, 0x0, 10, -1, 1797, 0, 0, -1 },
{ 0x0, 0x0, 10, -1, 1798, 0, 0, -1 },
{ 0x0, 0x0, 10, -1, 1799, 0, 0, -1 },
- { 0x0, 0x0, 10, -1, 1800, 0, 0, -1 },
- { 0x0, 0x0, 10, -1, 1801, 0, 0, -1 },
- { 0x0, 0x0, 10, -1, 1802, 0, 0, -1 },
- { 0x1, 0x1, 10, 1751, -1, 36, 1, 3 },
- { 0x1000001, 0x1000001, 10, 1752, -1, 12, 1, 3 },
- { 0x0, 0x0, 10, -1, 1803, 0, 0, -1 },
- { 0x0, 0x0, 10, -1, 1805, 0, 0, -1 },
- { 0x1, 0x1, 10, 1753, -1, 36, 1, 3 },
- { 0x1000001, 0x1000001, 10, 1754, -1, 12, 1, 3 },
- { 0x0, 0x0, 10, -1, 1807, 0, 0, -1 },
- { 0x0, 0x0, 10, -1, 1809, 0, 0, -1 },
+ { 0x1, 0x21, 10, 1760, -1, 33, 1, 3 },
+ { 0x200001, 0x200001, 10, 1761, -1, 12, 1, 3 },
+ { 0x0, 0x0, 10, 1762, -1, 0, 1, 3 },
+ { 0x1, 0x1, 10, 1763, -1, 12, 1, 3 },
+ { 0x1, 0x1, 10, 1764, -1, 33, 1, 3 },
+ { 0x200001, 0x200001, 10, 1765, -1, 12, 1, 3 },
+ { 0x0, 0x0, 10, 375, -1, 0, 1, 3 },
+ { 0x1, 0x1, 10, 1803, -1, 12, 1, 3 },
+ { 0x1, 0x1, 10, 379, -1, 33, 1, 3 },
+ { 0x200001, 0x200001, 10, 1805, -1, 12, 1, 3 },
+ { 0x1, 0x21, 10, 1770, -1, 33, 1, 3 },
+ { 0x200001, 0x200001, 10, 1771, -1, 12, 1, 3 },
+ { 0x0, 0x0, 10, -1, 1812, 0, 0, -1 },
+ { 0x0, 0x0, 10, -1, 1813, 0, 0, -1 },
+ { 0x0, 0x0, 10, -1, 1814, 0, 0, -1 },
+ { 0x0, 0x0, 10, -1, 1815, 0, 0, -1 },
+ { 0x0, 0x0, 10, -1, 1816, 0, 0, -1 },
+ { 0x0, 0x0, 10, -1, 1817, 0, 0, -1 },
+ { 0x0, 0x0, 10, -1, 1818, 0, 0, -1 },
+ { 0x0, 0x0, 10, -1, 1819, 0, 0, -1 },
+ { 0x0, 0x0, 10, -1, 1820, 0, 0, -1 },
+ { 0x0, 0x0, 10, -1, 1821, 0, 0, -1 },
+ { 0x0, 0x0, 10, -1, 1822, 0, 0, -1 },
+ { 0x0, 0x0, 10, -1, 1823, 0, 0, -1 },
+ { 0x1, 0x1, 10, 1772, -1, 36, 1, 3 },
+ { 0x1000001, 0x1000001, 10, 1773, -1, 12, 1, 3 },
+ { 0x0, 0x0, 10, -1, 1824, 0, 0, -1 },
+ { 0x0, 0x0, 10, -1, 1826, 0, 0, -1 },
+ { 0x1, 0x1, 10, 1774, -1, 36, 1, 3 },
+ { 0x1000001, 0x1000001, 10, 1775, -1, 12, 1, 3 },
+ { 0x0, 0x0, 10, -1, 1828, 0, 0, -1 },
+ { 0x0, 0x0, 10, -1, 1830, 0, 0, -1 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
- { 0x0, 0x0, 11, 1755, -1, 0, 1, 3 },
- { 0x1, 0x1, 11, 1756, -1, 12, 1, 3 },
+ { 0x0, 0x0, 11, 1776, -1, 0, 1, 3 },
+ { 0x1, 0x1, 11, 1777, -1, 12, 1, 3 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
- { 0x1, 0x1, 11, 1733, -1, 12, 1, 3 },
+ { 0x1, 0x1, 11, 1754, -1, 12, 1, 3 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
- { 0x0, 0x0, 11, 288, -1, 0, 1, 3 },
+ { 0x0, 0x0, 11, 293, -1, 0, 1, 3 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
- { 0x200001, 0x200001, 11, 1735, -1, 12, 1, 3 },
+ { 0x200001, 0x200001, 11, 1756, -1, 12, 1, 3 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
- { 0x1, 0x1, 11, 290, -1, 33, 1, 3 },
- { 0x0, 0x0, 11, 1761, -1, 0, 1, 3 },
- { 0x1, 0x1, 11, 1762, -1, 12, 1, 3 },
- { 0x1, 0x1, 11, 1763, -1, 33, 1, 3 },
- { 0x200001, 0x200001, 11, 1764, -1, 12, 1, 3 },
+ { 0x1, 0x1, 11, 295, -1, 33, 1, 3 },
+ { 0x0, 0x0, 11, 1782, -1, 0, 1, 3 },
+ { 0x1, 0x1, 11, 1783, -1, 12, 1, 3 },
+ { 0x1, 0x1, 11, 1784, -1, 33, 1, 3 },
+ { 0x200001, 0x200001, 11, 1785, -1, 12, 1, 3 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
- { 0x0, 0x0, 11, 1765, -1, 0, 1, 3 },
- { 0x1, 0x1, 11, 1766, -1, 12, 1, 3 },
+ { 0x0, 0x0, 11, 1786, -1, 0, 1, 3 },
+ { 0x1, 0x1, 11, 1787, -1, 12, 1, 3 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
- { 0x0, 0x0, 11, 1779, -1, 0, 1, 3 },
- { 0x1, 0x1, 11, 1780, -1, 12, 1, 3 },
+ { 0x0, 0x0, 11, 1800, -1, 0, 1, 3 },
+ { 0x1, 0x1, 11, 1801, -1, 12, 1, 3 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
- { 0x1, 0x1, 11, 1745, -1, 12, 1, 3 },
+ { 0x1, 0x1, 11, 1766, -1, 12, 1, 3 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
- { 0x0, 0x0, 11, 312, -1, 0, 1, 3 },
+ { 0x0, 0x0, 11, 317, -1, 0, 1, 3 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
- { 0x200001, 0x200001, 11, 1747, -1, 12, 1, 3 },
+ { 0x200001, 0x200001, 11, 1768, -1, 12, 1, 3 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
- { 0x1, 0x1, 11, 314, -1, 33, 1, 3 },
- { 0x0, 0x0, 11, 1785, -1, 0, 1, 3 },
- { 0x1, 0x1, 11, 1786, -1, 12, 1, 3 },
- { 0x1, 0x1, 11, 1787, -1, 33, 1, 3 },
- { 0x200001, 0x200001, 11, 1788, -1, 12, 1, 3 },
+ { 0x1, 0x1, 11, 319, -1, 33, 1, 3 },
+ { 0x0, 0x0, 11, 1806, -1, 0, 1, 3 },
+ { 0x1, 0x1, 11, 1807, -1, 12, 1, 3 },
+ { 0x1, 0x1, 11, 1808, -1, 33, 1, 3 },
+ { 0x200001, 0x200001, 11, 1809, -1, 12, 1, 3 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
{ 0x2, 0x3, 11, -1, -1, 37, 1, 5 },
- { 0x0, 0x0, 11, 1789, -1, 0, 1, 3 },
- { 0x1, 0x1, 11, 1790, -1, 12, 1, 3 },
+ { 0x0, 0x0, 11, 1810, -1, 0, 1, 3 },
+ { 0x1, 0x1, 11, 1811, -1, 12, 1, 3 },
{ 0x1, 0x1, 11, -1, -1, 36, 1, 5 },
{ 0x1, 0x1, 11, -1, -1, 36, 1, 5 },
- { 0x1, 0x1, 11, 1804, -1, 36, 1, 3 },
- { 0x1000001, 0x1000001, 11, 1806, -1, 12, 1, 3 },
+ { 0x1, 0x1, 11, 1825, -1, 36, 1, 3 },
+ { 0x1000001, 0x1000001, 11, 1827, -1, 12, 1, 3 },
{ 0x1, 0x1, 11, -1, -1, 36, 1, 5 },
{ 0x1, 0x1, 11, -1, -1, 36, 1, 5 },
- { 0x1, 0x1, 11, 1808, -1, 36, 1, 3 },
- { 0x1000001, 0x1000001, 11, 1810, -1, 12, 1, 3 },
+ { 0x1, 0x1, 11, 1829, -1, 36, 1, 3 },
+ { 0x1000001, 0x1000001, 11, 1831, -1, 12, 1, 3 },
+ { 0x0, 0x0, 12, -1, -1, 0, 1, 14 },
{ 0x0, 0x0, 12, -1, -1, 0, 1, 14 },
{ 0x0, 0x0, 12, -1, -1, 0, 1, 14 },
- { 0x1, 0x1, 13, 258, 1198, 34, 1, 124 },
- { 0x1, 0x1, 13, 260, 1207, 34, 1, 124 },
- { 0x1, 0x1, 13, 262, 1216, 34, 1, 124 },
- { 0x1, 0x1, 13, 264, 1225, 34, 1, 124 },
- { 0x1, 0x1, 13, 266, 1234, 34, 1, 124 },
- { 0x1, 0x1, 13, 268, 1243, 34, 1, 124 },
- { 0x1, 0x1, 13, 270, 1252, 34, 1, 124 },
- { 0x1, 0x1, 13, 272, 1261, 34, 1, 124 },
- { 0x1, 0x1, 13, 274, 1270, 34, 1, 124 },
- { 0x1, 0x1, 13, 276, 1279, 34, 1, 124 },
- { 0x1, 0x1, 13, 278, 1289, 34, 1, 124 },
- { 0x1, 0x1, 13, 280, 1299, 34, 1, 124 },
- { 0x0, 0x0, 19, -1, 650, 0, 0, -1 },
- { 0x0, 0x0, 19, -1, 651, 0, 0, -1 },
- { 0x0, 0x0, 19, -1, 652, 0, 0, -1 },
- { 0x0, 0x0, 19, -1, 653, 0, 0, -1 },
- { 0x0, 0x0, 19, -1, 654, 0, 0, -1 },
- { 0x0, 0x0, 19, -1, 655, 0, 0, -1 },
+ { 0x1, 0x1, 13, 262, 1211, 34, 1, 124 },
+ { 0x1, 0x1, 13, 264, 1220, 34, 1, 124 },
+ { 0x1, 0x1, 13, 266, 1229, 34, 1, 124 },
+ { 0x1, 0x1, 13, 269, 1240, 34, 1, 124 },
+ { 0x1, 0x1, 13, 271, 1249, 34, 1, 124 },
+ { 0x1, 0x1, 13, 273, 1258, 34, 1, 124 },
+ { 0x1, 0x1, 13, 275, 1267, 34, 1, 124 },
+ { 0x1, 0x1, 13, 277, 1276, 34, 1, 124 },
+ { 0x1, 0x1, 13, 279, 1285, 34, 1, 124 },
+ { 0x1, 0x1, 13, 281, 1294, 34, 1, 124 },
+ { 0x1, 0x1, 13, 283, 1304, 34, 1, 124 },
+ { 0x1, 0x1, 13, 285, 1314, 34, 1, 124 },
{ 0x0, 0x0, 19, -1, 656, 0, 0, -1 },
{ 0x0, 0x0, 19, -1, 657, 0, 0, -1 },
{ 0x0, 0x0, 19, -1, 658, 0, 0, -1 },
@@ -2125,19 +2187,25 @@ completer_table[] = {
{ 0x0, 0x0, 19, -1, 677, 0, 0, -1 },
{ 0x0, 0x0, 19, -1, 678, 0, 0, -1 },
{ 0x0, 0x0, 19, -1, 679, 0, 0, -1 },
- { 0x0, 0x0, 20, -1, 2340, 0, 0, -1 },
- { 0x0, 0x0, 20, -1, 2341, 0, 0, -1 },
- { 0x0, 0x0, 20, -1, 2356, 0, 0, -1 },
- { 0x0, 0x0, 20, -1, 2357, 0, 0, -1 },
- { 0x0, 0x0, 20, -1, 2362, 0, 0, -1 },
+ { 0x0, 0x0, 19, -1, 680, 0, 0, -1 },
+ { 0x0, 0x0, 19, -1, 681, 0, 0, -1 },
+ { 0x0, 0x0, 19, -1, 682, 0, 0, -1 },
+ { 0x0, 0x0, 19, -1, 683, 0, 0, -1 },
+ { 0x0, 0x0, 19, -1, 684, 0, 0, -1 },
+ { 0x0, 0x0, 19, -1, 685, 0, 0, -1 },
{ 0x0, 0x0, 20, -1, 2363, 0, 0, -1 },
- { 0x0, 0x0, 21, 686, 2352, 0, 0, -1 },
- { 0x0, 0x0, 21, 687, 2354, 0, 0, -1 },
- { 0x0, 0x0, 23, -1, 2350, 0, 0, -1 },
- { 0x0, 0x0, 23, -1, 2351, 0, 0, -1 },
+ { 0x0, 0x0, 20, -1, 2364, 0, 0, -1 },
+ { 0x0, 0x0, 20, -1, 2379, 0, 0, -1 },
+ { 0x0, 0x0, 20, -1, 2380, 0, 0, -1 },
+ { 0x0, 0x0, 20, -1, 2385, 0, 0, -1 },
+ { 0x0, 0x0, 20, -1, 2386, 0, 0, -1 },
+ { 0x0, 0x0, 21, 692, 2375, 0, 0, -1 },
+ { 0x0, 0x0, 21, 693, 2377, 0, 0, -1 },
+ { 0x0, 0x0, 23, -1, 2373, 0, 0, -1 },
+ { 0x0, 0x0, 23, -1, 2374, 0, 0, -1 },
{ 0x1, 0x1, 24, -1, -1, 35, 1, 6 },
{ 0x1, 0x1, 24, -1, -1, 35, 1, 6 },
- { 0x1, 0x1, 24, 1045, -1, 35, 1, 6 },
+ { 0x1, 0x1, 24, 1055, -1, 35, 1, 6 },
{ 0x1, 0x1, 24, -1, -1, 35, 1, 6 },
{ 0x1, 0x1, 24, -1, -1, 35, 1, 6 },
{ 0x1, 0x1, 24, -1, -1, 35, 1, 6 },
@@ -2200,7 +2268,7 @@ completer_table[] = {
{ 0x1, 0x1, 24, -1, -1, 35, 1, 15 },
{ 0x1, 0x1, 24, -1, -1, 35, 1, 17 },
{ 0x1, 0x1, 24, -1, -1, 35, 1, 17 },
- { 0x1, 0x1, 24, 1066, -1, 35, 1, 17 },
+ { 0x1, 0x1, 24, 1076, -1, 35, 1, 17 },
{ 0x1, 0x1, 24, -1, -1, 35, 1, 17 },
{ 0x1, 0x1, 24, -1, -1, 35, 1, 17 },
{ 0x1, 0x1, 24, -1, -1, 35, 1, 17 },
@@ -2299,7 +2367,7 @@ completer_table[] = {
{ 0x1, 0x1, 24, -1, -1, 35, 1, 21 },
{ 0x1, 0x1, 24, -1, -1, 35, 1, 17 },
{ 0x1, 0x1, 24, -1, -1, 35, 1, 17 },
- { 0x1, 0x1, 24, 1099, -1, 35, 1, 17 },
+ { 0x1, 0x1, 24, 1109, -1, 35, 1, 17 },
{ 0x1, 0x1, 24, -1, -1, 35, 1, 17 },
{ 0x1, 0x1, 24, -1, -1, 35, 1, 17 },
{ 0x1, 0x1, 24, -1, -1, 35, 1, 17 },
@@ -2338,5100 +2406,5157 @@ completer_table[] = {
{ 0x1, 0x1, 24, -1, -1, 35, 1, 21 },
{ 0x1, 0x1, 24, -1, -1, 33, 1, 76 },
{ 0x1, 0x1, 24, -1, -1, 33, 1, 76 },
- { 0x1, 0x1, 24, 1114, 1201, 35, 1, 129 },
- { 0x1, 0x1, 24, 1115, 1210, 35, 1, 129 },
- { 0x1, 0x1, 24, 1116, 1219, 35, 1, 129 },
- { 0x1, 0x1, 24, 1117, 1228, 35, 1, 129 },
- { 0x1, 0x1, 24, 1118, 1237, 35, 1, 129 },
- { 0x1, 0x1, 24, 1119, 1246, 35, 1, 129 },
- { 0x1, 0x1, 24, 1120, 1255, 35, 1, 129 },
- { 0x1, 0x1, 24, 1121, 1264, 35, 1, 129 },
- { 0x1, 0x1, 24, 1122, 1273, 35, 1, 129 },
- { 0x1, 0x1, 24, 1123, 1283, 35, 1, 129 },
- { 0x1, 0x1, 24, 1124, 1293, 35, 1, 129 },
- { 0x1, 0x1, 24, 1125, 1303, 35, 1, 129 },
- { 0x1, 0x1, 24, 1126, 1312, 35, 1, 141 },
- { 0x1, 0x1, 24, 1127, 1318, 35, 1, 141 },
- { 0x1, 0x1, 24, 1128, 1324, 35, 1, 141 },
- { 0x1, 0x1, 24, 1129, 1330, 35, 1, 141 },
- { 0x1, 0x1, 24, 1130, 1336, 35, 1, 141 },
- { 0x1, 0x1, 24, 1131, 1342, 35, 1, 141 },
- { 0x1, 0x1, 24, 1132, 1348, 35, 1, 141 },
- { 0x1, 0x1, 24, 1133, 1354, 35, 1, 141 },
- { 0x1, 0x1, 24, 1134, 1360, 35, 1, 141 },
- { 0x1, 0x1, 24, 1135, 1366, 35, 1, 141 },
- { 0x1, 0x1, 24, 1136, 1372, 35, 1, 141 },
- { 0x1, 0x1, 24, 1137, 1378, 35, 1, 141 },
- { 0x1, 0x1, 24, 1138, 1384, 35, 1, 141 },
- { 0x1, 0x1, 24, 1139, 1390, 35, 1, 141 },
- { 0x1, 0x1, 24, 1140, 1396, 35, 1, 141 },
- { 0x1, 0x1, 24, 1141, 1402, 35, 1, 141 },
- { 0x1, 0x1, 24, 1142, 1408, 35, 1, 141 },
- { 0x1, 0x1, 24, 1143, 1414, 35, 1, 141 },
- { 0x0, 0x0, 32, 2334, 2332, 0, 0, -1 },
- { 0x0, 0x0, 32, 2337, 2335, 0, 0, -1 },
- { 0x0, 0x0, 32, 2343, 2342, 0, 0, -1 },
- { 0x0, 0x0, 32, 2345, 2344, 0, 0, -1 },
- { 0x0, 0x0, 32, 2359, 2358, 0, 0, -1 },
- { 0x0, 0x0, 32, 2361, 2360, 0, 0, -1 },
- { 0x0, 0x0, 34, -1, 2353, 0, 0, -1 },
- { 0x0, 0x0, 34, -1, 2355, 0, 0, -1 },
- { 0x1, 0x1, 37, -1, 1899, 37, 1, 29 },
- { 0x1, 0x1, 37, -1, 1934, 37, 1, 29 },
- { 0x0, 0x0, 37, -1, 1937, 0, 0, -1 },
- { 0x1, 0x1, 37, -1, -1, 37, 1, 29 },
- { 0x1, 0x1, 37, -1, 1942, 37, 1, 29 },
- { 0x0, 0x0, 37, -1, 1945, 0, 0, -1 },
- { 0x1, 0x1, 37, -1, -1, 37, 1, 29 },
- { 0x0, 0x0, 37, -1, 1948, 0, 0, -1 },
- { 0x1, 0x1, 37, -1, -1, 37, 1, 29 },
- { 0x1, 0x1, 37, -1, 1951, 37, 1, 29 },
- { 0x1, 0x1, 37, -1, 1954, 37, 1, 29 },
- { 0x1, 0x1, 37, -1, 1987, 37, 1, 29 },
- { 0x3, 0x3, 37, -1, -1, 30, 1, 134 },
- { 0x0, 0x0, 37, 951, -1, 0, 1, 95 },
- { 0x0, 0x0, 37, -1, -1, 0, 1, 104 },
- { 0x0, 0x0, 37, 957, -1, 0, 1, 116 },
- { 0x3, 0x3, 37, -1, -1, 30, 1, 146 },
- { 0x0, 0x0, 37, 958, -1, 0, 1, 40 },
- { 0x0, 0x0, 39, -1, 818, 0, 0, -1 },
- { 0x0, 0x0, 39, -1, 826, 0, 0, -1 },
- { 0x0, 0x0, 39, 960, 822, 0, 0, -1 },
- { 0x3, 0x3, 39, -1, 477, 33, 1, 6 },
- { 0x18000001, 0x18000001, 39, -1, 485, 6, 1, 7 },
- { 0x3, 0x3, 39, 961, 481, 33, 1, 6 },
- { 0x0, 0x0, 39, -1, 830, 0, 0, -1 },
- { 0x3, 0x3, 39, -1, 497, 33, 1, 8 },
- { 0x0, 0x0, 39, -1, 834, 0, 0, -1 },
- { 0x3, 0x3, 39, -1, 509, 33, 1, 15 },
- { 0x0, 0x0, 39, -1, 839, 0, 0, -1 },
- { 0x0, 0x0, 39, -1, 843, 0, 0, -1 },
- { 0x3, 0x3, 39, -1, 532, 33, 1, 17 },
- { 0x3, 0x3, 39, -1, 536, 33, 1, 17 },
- { 0x0, 0x0, 39, -1, 847, 0, 0, -1 },
- { 0x0, 0x0, 39, -1, 851, 0, 0, -1 },
- { 0x3, 0x3, 39, -1, 556, 33, 1, 18 },
- { 0x18000001, 0x18000001, 39, -1, 560, 6, 1, 18 },
- { 0x0, 0x0, 39, -1, 855, 0, 0, -1 },
- { 0x3, 0x3, 39, -1, 572, 33, 1, 19 },
- { 0x0, 0x0, 39, -1, 859, 0, 0, -1 },
- { 0x0, 0x0, 39, -1, 863, 0, 0, -1 },
- { 0x3, 0x3, 39, -1, 592, 33, 1, 20 },
- { 0x18000001, 0x18000001, 39, -1, 596, 6, 1, 20 },
- { 0x0, 0x0, 39, -1, 867, 0, 0, -1 },
- { 0x3, 0x3, 39, -1, 608, 33, 1, 21 },
- { 0x0, 0x0, 39, -1, 872, 0, 0, -1 },
- { 0x0, 0x0, 39, -1, 876, 0, 0, -1 },
- { 0x3, 0x3, 39, -1, 631, 33, 1, 17 },
- { 0x3, 0x3, 39, -1, 635, 33, 1, 17 },
- { 0x0, 0x0, 39, -1, 880, 0, 0, -1 },
- { 0x3, 0x3, 39, -1, 647, 33, 1, 21 },
- { 0x0, 0x0, 40, 706, 817, 0, 0, -1 },
- { 0x0, 0x0, 40, 707, 825, 0, 0, -1 },
- { 0x0, 0x0, 40, 708, 821, 0, 0, -1 },
- { 0x1, 0x1, 40, 709, 476, 34, 1, 6 },
- { 0x10000001, 0x10000001, 40, 710, 484, 6, 1, 7 },
- { 0x1, 0x1, 40, 711, 480, 34, 1, 6 },
- { 0x0, 0x0, 40, 712, 829, 0, 0, -1 },
- { 0x1, 0x1, 40, 713, 496, 34, 1, 8 },
- { 0x0, 0x0, 40, 714, 833, 0, 0, -1 },
- { 0x1, 0x1, 40, 715, 508, 34, 1, 15 },
- { 0x0, 0x0, 40, 716, 838, 0, 0, -1 },
- { 0x0, 0x0, 40, 717, 842, 0, 0, -1 },
- { 0x1, 0x1, 40, 718, 531, 34, 1, 17 },
- { 0x1, 0x1, 40, 719, 535, 34, 1, 17 },
- { 0x0, 0x0, 40, 720, 846, 0, 0, -1 },
- { 0x0, 0x0, 40, 721, 850, 0, 0, -1 },
- { 0x1, 0x1, 40, 722, 555, 34, 1, 18 },
- { 0x10000001, 0x10000001, 40, 723, 559, 6, 1, 18 },
- { 0x0, 0x0, 40, 724, 854, 0, 0, -1 },
- { 0x1, 0x1, 40, 725, 571, 34, 1, 19 },
- { 0x0, 0x0, 40, 726, 858, 0, 0, -1 },
- { 0x0, 0x0, 40, 727, 862, 0, 0, -1 },
- { 0x1, 0x1, 40, 728, 591, 34, 1, 20 },
- { 0x10000001, 0x10000001, 40, 729, 595, 6, 1, 20 },
- { 0x0, 0x0, 40, 730, 866, 0, 0, -1 },
- { 0x1, 0x1, 40, 731, 607, 34, 1, 21 },
- { 0x0, 0x0, 40, 732, 871, 0, 0, -1 },
- { 0x0, 0x0, 40, 733, 875, 0, 0, -1 },
- { 0x1, 0x1, 40, 734, 630, 34, 1, 17 },
- { 0x1, 0x1, 40, 735, 634, 34, 1, 17 },
- { 0x0, 0x0, 40, 736, 879, 0, 0, -1 },
- { 0x1, 0x1, 40, 737, 646, 34, 1, 21 },
- { 0x800001, 0x800001, 40, -1, 965, 4, 1, 16 },
- { 0x1, 0x1, 40, 1845, 963, 4, 1, 16 },
- { 0x1, 0x1, 40, 803, 968, 4, 1, 22 },
- { 0x2, 0x3, 40, -1, 973, 20, 1, 67 },
- { 0x1, 0x1, 40, 1846, 971, 21, 1, 67 },
- { 0x0, 0x0, 41, -1, -1, 0, 1, 80 },
- { 0x0, 0x0, 41, -1, -1, 0, 1, 80 },
- { 0x0, 0x0, 41, -1, -1, 0, 1, 123 },
- { 0x1, 0x1, 43, 1144, 281, 38, 1, 1 },
- { 0x0, 0x0, 43, -1, 340, 0, 0, -1 },
- { 0x1, 0x1, 43, 1147, 291, 38, 1, 1 },
- { 0x0, 0x0, 43, -1, 360, 0, 0, -1 },
- { 0x0, 0x0, 43, -1, 294, 0, 0, -1 },
- { 0x0, 0x0, 43, -1, 304, 0, 0, -1 },
- { 0x1, 0x1, 43, 1152, 305, 38, 1, 1 },
- { 0x0, 0x0, 43, -1, 364, 0, 0, -1 },
- { 0x1, 0x1, 43, 1155, 315, 38, 1, 1 },
- { 0x0, 0x0, 43, -1, 384, 0, 0, -1 },
- { 0x0, 0x0, 43, -1, 318, 0, 0, -1 },
- { 0x0, 0x0, 43, -1, 328, 0, 0, -1 },
- { 0x0, 0x0, 43, 1028, 1906, 0, 0, -1 },
- { 0x0, 0x0, 43, 1029, 2439, 0, 1, 54 },
- { 0x0, 0x0, 43, 1030, 1958, 0, 0, -1 },
- { 0x0, 0x0, 43, 1031, -1, 0, 1, 49 },
- { 0x0, 0x0, 43, 935, -1, 0, 1, 0 },
- { 0x0, 0x0, 43, 936, -1, 0, 1, 0 },
- { 0x0, 0x0, 43, 937, -1, 0, 1, 0 },
- { 0x1, 0x1, 44, -1, 1418, 30, 1, 143 },
- { 0x1, 0x1, 44, 808, 1417, 30, 1, 142 },
- { 0x1, 0x1, 44, -1, 1422, 30, 1, 145 },
- { 0x1, 0x1, 44, 809, 1421, 30, 1, 144 },
- { 0x1, 0x1, 44, -1, 1426, 30, 1, 145 },
- { 0x1, 0x1, 44, 810, 1425, 30, 1, 144 },
- { 0x3, 0x3, 45, -1, 969, 3, 1, 22 },
- { 0x1, 0x1, 46, 1866, -1, 30, 1, 134 },
- { 0x1, 0x1, 46, 1897, -1, 30, 1, 146 },
- { 0x0, 0x0, 48, -1, -1, 0, 1, 40 },
- { 0x0, 0x0, 48, -1, -1, 0, 1, 40 },
- { 0x1, 0x1, 55, -1, 1419, 31, 1, 143 },
- { 0x1, 0x1, 55, -1, 1423, 31, 1, 145 },
- { 0x1, 0x1, 55, -1, 1427, 31, 1, 145 },
- { 0x0, 0x0, 55, -1, -1, 0, 1, 94 },
- { 0x2, 0x3, 55, -1, -1, 27, 1, 94 },
- { 0x1, 0x1, 55, -1, -1, 28, 1, 94 },
- { 0x0, 0x0, 64, 13, 447, 0, 1, 6 },
- { 0x0, 0x0, 64, 1046, 450, 0, 1, 6 },
- { 0x1, 0x1, 64, 1047, 452, 33, 1, 6 },
- { 0x1, 0x1, 64, 1048, 454, 34, 1, 6 },
- { 0x3, 0x3, 64, 1049, 456, 33, 1, 6 },
- { 0x0, 0x0, 64, 1050, 458, 0, 1, 6 },
- { 0x1, 0x1, 64, 1051, 460, 33, 1, 6 },
- { 0x1, 0x1, 64, 1052, 462, 34, 1, 6 },
- { 0x3, 0x3, 64, 1053, 464, 33, 1, 6 },
- { 0x1, 0x1, 64, 1054, 466, 6, 1, 7 },
- { 0x8000001, 0x8000001, 64, 1055, 468, 6, 1, 7 },
- { 0x10000001, 0x10000001, 64, 1056, 470, 6, 1, 7 },
- { 0x18000001, 0x18000001, 64, 1057, 472, 6, 1, 7 },
- { 0x0, 0x0, 64, 1058, 486, 0, 1, 8 },
- { 0x1, 0x1, 64, 1059, 488, 33, 1, 8 },
- { 0x1, 0x1, 64, 1060, 490, 34, 1, 8 },
- { 0x3, 0x3, 64, 1061, 492, 33, 1, 8 },
- { 0x0, 0x0, 64, 1062, 498, 0, 1, 15 },
- { 0x1, 0x1, 64, 1063, 500, 33, 1, 15 },
- { 0x1, 0x1, 64, 1064, 502, 34, 1, 15 },
- { 0x3, 0x3, 64, 1065, 504, 33, 1, 15 },
- { 0x0, 0x0, 64, 14, 510, 0, 1, 17 },
- { 0x0, 0x0, 64, 1067, 513, 0, 1, 17 },
- { 0x1, 0x1, 64, 1068, 515, 33, 1, 17 },
- { 0x1, 0x1, 64, 1069, 517, 34, 1, 17 },
- { 0x3, 0x3, 64, 1070, 519, 33, 1, 17 },
- { 0x0, 0x0, 64, 1071, 521, 0, 1, 17 },
- { 0x1, 0x1, 64, 1072, 523, 33, 1, 17 },
- { 0x1, 0x1, 64, 1073, 525, 34, 1, 17 },
- { 0x3, 0x3, 64, 1074, 527, 33, 1, 17 },
- { 0x0, 0x0, 64, 1075, 537, 0, 1, 18 },
- { 0x1, 0x1, 64, 1076, 539, 33, 1, 18 },
- { 0x1, 0x1, 64, 1077, 541, 34, 1, 18 },
- { 0x3, 0x3, 64, 1078, 543, 33, 1, 18 },
- { 0x1, 0x1, 64, 1079, 545, 6, 1, 18 },
- { 0x8000001, 0x8000001, 64, 1080, 547, 6, 1, 18 },
- { 0x10000001, 0x10000001, 64, 1081, 549, 6, 1, 18 },
- { 0x18000001, 0x18000001, 64, 1082, 551, 6, 1, 18 },
- { 0x0, 0x0, 64, 1083, 561, 0, 1, 19 },
- { 0x1, 0x1, 64, 1084, 563, 33, 1, 19 },
- { 0x1, 0x1, 64, 1085, 565, 34, 1, 19 },
- { 0x3, 0x3, 64, 1086, 567, 33, 1, 19 },
- { 0x0, 0x0, 64, 1087, 573, 0, 1, 20 },
- { 0x1, 0x1, 64, 1088, 575, 33, 1, 20 },
- { 0x1, 0x1, 64, 1089, 577, 34, 1, 20 },
- { 0x3, 0x3, 64, 1090, 579, 33, 1, 20 },
- { 0x1, 0x1, 64, 1091, 581, 6, 1, 20 },
- { 0x8000001, 0x8000001, 64, 1092, 583, 6, 1, 20 },
- { 0x10000001, 0x10000001, 64, 1093, 585, 6, 1, 20 },
- { 0x18000001, 0x18000001, 64, 1094, 587, 6, 1, 20 },
- { 0x0, 0x0, 64, 1095, 597, 0, 1, 21 },
- { 0x1, 0x1, 64, 1096, 599, 33, 1, 21 },
- { 0x1, 0x1, 64, 1097, 601, 34, 1, 21 },
- { 0x3, 0x3, 64, 1098, 603, 33, 1, 21 },
- { 0x0, 0x0, 64, 16, 609, 0, 1, 17 },
- { 0x0, 0x0, 64, 1100, 612, 0, 1, 17 },
- { 0x1, 0x1, 64, 1101, 614, 33, 1, 17 },
- { 0x1, 0x1, 64, 1102, 616, 34, 1, 17 },
- { 0x3, 0x3, 64, 1103, 618, 33, 1, 17 },
- { 0x0, 0x0, 64, 1104, 620, 0, 1, 17 },
- { 0x1, 0x1, 64, 1105, 622, 33, 1, 17 },
- { 0x1, 0x1, 64, 1106, 624, 34, 1, 17 },
- { 0x3, 0x3, 64, 1107, 626, 33, 1, 17 },
- { 0x0, 0x0, 64, 1108, 636, 0, 1, 21 },
- { 0x1, 0x1, 64, 1109, 638, 33, 1, 21 },
- { 0x1, 0x1, 64, 1110, 640, 34, 1, 21 },
- { 0x3, 0x3, 64, 1111, 642, 33, 1, 21 },
- { 0x3, 0x3, 65, 416, 1281, 33, 1, 128 },
- { 0x3, 0x3, 65, 417, 1291, 33, 1, 128 },
- { 0x3, 0x3, 65, 418, 1301, 33, 1, 128 },
- { 0x0, 0x0, 65, -1, 1306, 0, 1, 137 },
- { 0x0, 0x0, 65, -1, 1307, 0, 1, 137 },
- { 0x0, 0x0, 65, -1, 1308, 0, 1, 137 },
- { 0x0, 0x0, 106, 891, 1930, 0, 0, -1 },
- { 0x0, 0x0, 106, 892, 2377, 0, 1, 29 },
- { 0x0, 0x0, 106, 893, 1971, 0, 0, -1 },
- { 0x0, 0x0, 106, 894, 2381, 0, 1, 29 },
- { 0x0, 0x0, 108, -1, 1932, 0, 0, -1 },
- { 0x1, 0x1, 108, -1, 2378, 27, 1, 29 },
- { 0x0, 0x0, 108, -1, 1973, 0, 0, -1 },
- { 0x1, 0x1, 108, -1, 2382, 27, 1, 29 },
- { 0x0, 0x0, 109, 896, -1, 0, 1, 115 },
- { 0x1, 0x1, 110, -1, -1, 27, 1, 115 },
- { 0x0, 0x0, 111, 914, 2400, 0, 1, 1 },
- { 0x0, 0x0, 111, 1015, 285, 0, 0, -1 },
- { 0x0, 0x0, 111, 992, 348, 0, 0, -1 },
- { 0x0, 0x0, 111, -1, 356, 0, 0, -1 },
- { 0x0, 0x0, 111, 915, 2408, 0, 1, 1 },
- { 0x0, 0x0, 111, -1, 298, 0, 0, -1 },
- { 0x0, 0x0, 111, 1020, 299, 0, 0, -1 },
- { 0x0, 0x0, 111, 916, 2420, 0, 1, 1 },
- { 0x0, 0x0, 111, 1022, 309, 0, 0, -1 },
- { 0x0, 0x0, 111, 999, 372, 0, 0, -1 },
- { 0x0, 0x0, 111, -1, 380, 0, 0, -1 },
- { 0x0, 0x0, 111, 1156, 2427, 0, 1, 1 },
- { 0x0, 0x0, 111, -1, 322, 0, 0, -1 },
- { 0x0, 0x0, 111, 1027, 323, 0, 0, -1 },
- { 0x0, 0x0, 111, -1, 1916, 0, 0, -1 },
- { 0x1, 0x9, 111, -1, 2446, 33, 1, 54 },
- { 0x2, 0x3, 111, 1169, 1967, 27, 1, 49 },
- { 0x1, 0x1, 113, 1145, 2401, 37, 1, 1 },
- { 0x1, 0x1, 113, 1148, 2409, 37, 1, 1 },
- { 0x1, 0x1, 113, 1153, 2421, 37, 1, 1 },
- { 0x0, 0x0, 113, -1, 2432, 0, 1, 1 },
- { 0x0, 0x0, 114, 938, 2398, 0, 1, 1 },
- { 0x0, 0x0, 114, 991, 283, 0, 0, -1 },
- { 0x0, 0x0, 114, -1, 352, 0, 0, -1 },
- { 0x0, 0x0, 114, 1017, 354, 0, 0, -1 },
- { 0x0, 0x0, 114, -1, 2407, 0, 1, 1 },
- { 0x0, 0x0, 114, 1019, 296, 0, 0, -1 },
- { 0x0, 0x0, 114, 996, 301, 0, 0, -1 },
- { 0x0, 0x0, 114, 940, 2418, 0, 1, 1 },
- { 0x0, 0x0, 114, 998, 307, 0, 0, -1 },
- { 0x0, 0x0, 114, -1, 376, 0, 0, -1 },
- { 0x0, 0x0, 114, 1024, 378, 0, 0, -1 },
- { 0x0, 0x0, 114, -1, 2426, 0, 1, 1 },
- { 0x0, 0x0, 114, 1026, 320, 0, 0, -1 },
- { 0x0, 0x0, 114, 1003, 325, 0, 0, -1 },
- { 0x0, 0x0, 114, 911, 1914, 0, 0, -1 },
- { 0x0, 0x0, 114, 912, 2445, 0, 1, 54 },
- { 0x0, 0x0, 114, 913, 1966, 0, 1, 49 },
- { 0x1, 0x1, 114, -1, -1, 27, 1, 0 },
- { 0x1, 0x1, 114, -1, -1, 27, 1, 0 },
- { 0x1, 0x1, 114, -1, -1, 27, 1, 0 },
- { 0x1, 0x1, 115, -1, 2399, 37, 1, 1 },
- { 0x0, 0x0, 115, -1, 2412, 0, 1, 1 },
- { 0x1, 0x1, 115, -1, 2419, 37, 1, 1 },
- { 0x0, 0x0, 115, -1, 2431, 0, 1, 1 },
- { 0x0, 0x0, 116, 985, -1, 0, 1, 0 },
- { 0x0, 0x0, 116, 986, -1, 0, 1, 0 },
- { 0x0, 0x0, 116, 987, -1, 0, 1, 0 },
- { 0x3, 0x3, 116, 947, -1, 34, 1, 33 },
- { 0x3, 0x3, 116, 948, -1, 34, 1, 40 },
- { 0x1, 0x1, 117, -1, -1, 35, 1, 33 },
- { 0x1, 0x1, 117, -1, -1, 35, 1, 40 },
- { 0x0, 0x0, 118, -1, -1, 0, 1, 40 },
- { 0x0, 0x0, 118, -1, -1, 0, 1, 66 },
- { 0x1, 0x1, 118, -1, -1, 27, 1, 96 },
- { 0x0, 0x0, 118, -1, -1, 0, 1, 105 },
- { 0x0, 0x0, 118, -1, -1, 0, 1, 73 },
- { 0x0, 0x0, 118, -1, -1, 0, 1, 73 },
- { 0x0, 0x0, 118, -1, -1, 0, 1, 74 },
- { 0x0, 0x0, 118, -1, -1, 0, 1, 40 },
- { 0x1, 0x1, 118, -1, -1, 27, 1, 117 },
- { 0x1, 0x1, 118, -1, -1, 27, 1, 40 },
- { 0x0, 0x0, 118, -1, -1, 0, 1, 40 },
- { 0x0, 0x0, 119, -1, 2333, 0, 0, -1 },
- { 0x0, 0x0, 119, -1, 2336, 0, 0, -1 },
- { 0x1, 0x1, 120, -1, -1, 35, 1, 16 },
- { 0x1, 0x1, 120, -1, -1, 35, 1, 16 },
- { 0x1, 0x1, 120, -1, -1, 35, 1, 16 },
- { 0x1, 0x1, 120, -1, -1, 35, 1, 16 },
- { 0x1, 0x1, 120, -1, -1, 35, 1, 22 },
- { 0x1, 0x1, 120, -1, -1, 35, 1, 22 },
- { 0x1, 0x1, 120, -1, -1, 35, 1, 22 },
- { 0x1, 0x1, 120, -1, -1, 35, 1, 22 },
- { 0x1, 0x1, 120, -1, -1, 23, 1, 67 },
- { 0x1, 0x1, 120, -1, -1, 23, 1, 67 },
- { 0x1, 0x1, 120, -1, -1, 23, 1, 67 },
- { 0x1, 0x1, 120, -1, -1, 23, 1, 67 },
- { 0x1, 0x1, 120, 773, -1, 23, 1, 67 },
- { 0x9, 0x9, 120, 774, -1, 20, 1, 67 },
- { 0x0, 0x0, 124, 1816, -1, 0, 1, 0 },
- { 0x0, 0x0, 124, 1817, -1, 0, 1, 0 },
- { 0x1, 0x1, 124, -1, -1, 28, 1, 33 },
- { 0x1, 0x1, 124, -1, -1, 27, 1, 33 },
- { 0x1, 0x1, 124, -1, -1, 29, 1, 0 },
- { 0x1, 0x1, 124, -1, -1, 29, 1, 0 },
- { 0x1, 0x1, 124, -1, -1, 29, 1, 0 },
- { 0x1, 0x1, 124, -1, -1, 29, 1, 0 },
- { 0x0, 0x0, 124, -1, -1, 0, 1, 114 },
- { 0x1, 0x1, 124, -1, -1, 29, 1, 0 },
- { 0x1, 0x1, 124, -1, -1, 29, 1, 0 },
- { 0x1, 0x1, 124, -1, -1, 29, 1, 0 },
- { 0x0, 0x0, 124, 945, -1, 0, 1, 33 },
- { 0x0, 0x0, 124, 1037, -1, 0, 1, 40 },
- { 0x0, 0x0, 137, 1008, 2396, 0, 1, 1 },
- { 0x0, 0x0, 137, 898, 284, 0, 0, -1 },
- { 0x0, 0x0, 137, 920, 289, 0, 0, -1 },
- { 0x0, 0x0, 137, 921, 353, 0, 0, -1 },
- { 0x0, 0x0, 137, -1, 2406, 0, 1, 1 },
- { 0x0, 0x0, 137, 923, 295, 0, 0, -1 },
- { 0x0, 0x0, 137, -1, 302, 0, 0, -1 },
- { 0x0, 0x0, 137, 1010, 2416, 0, 1, 1 },
- { 0x0, 0x0, 137, 905, 308, 0, 0, -1 },
- { 0x0, 0x0, 137, 927, 313, 0, 0, -1 },
- { 0x0, 0x0, 137, 928, 377, 0, 0, -1 },
- { 0x0, 0x0, 137, -1, 2425, 0, 1, 1 },
- { 0x0, 0x0, 137, 930, 319, 0, 0, -1 },
- { 0x0, 0x0, 137, -1, 326, 0, 0, -1 },
- { 0x0, 0x0, 137, 2463, 1910, 0, 0, -1 },
- { 0x1, 0x1, 137, 2464, 2441, 33, 1, 54 },
- { 0x0, 0x0, 137, 2465, 1960, 0, 0, -1 },
- { 0x1, 0x1, 137, 2466, -1, 28, 1, 49 },
- { 0x1, 0x1, 138, -1, 2397, 37, 1, 1 },
- { 0x0, 0x0, 138, -1, 2411, 0, 1, 1 },
- { 0x1, 0x1, 138, -1, 2417, 37, 1, 1 },
- { 0x0, 0x0, 138, -1, 2430, 0, 1, 1 },
- { 0x1, 0x1, 141, 772, 967, 3, 1, 22 },
- { 0x0, 0x0, 142, 1818, -1, 0, 1, 33 },
- { 0x0, 0x0, 143, 778, 2393, 0, 1, 1 },
- { 0x0, 0x0, 143, -1, 286, 0, 0, -1 },
- { 0x0, 0x0, 143, 899, 287, 0, 0, -1 },
- { 0x0, 0x0, 143, 900, 355, 0, 0, -1 },
- { 0x0, 0x0, 143, 780, 2403, 0, 1, 1 },
- { 0x0, 0x0, 143, 902, 297, 0, 0, -1 },
- { 0x0, 0x0, 143, 924, 300, 0, 0, -1 },
- { 0x0, 0x0, 143, 784, 2413, 0, 1, 1 },
- { 0x0, 0x0, 143, -1, 310, 0, 0, -1 },
- { 0x0, 0x0, 143, 906, 311, 0, 0, -1 },
- { 0x0, 0x0, 143, 907, 379, 0, 0, -1 },
- { 0x0, 0x0, 143, 786, 2423, 0, 1, 1 },
- { 0x0, 0x0, 143, 909, 321, 0, 0, -1 },
- { 0x0, 0x0, 143, 931, 324, 0, 0, -1 },
- { 0x0, 0x0, 143, 1004, 1908, 0, 0, -1 },
- { 0x1, 0x1, 143, 1005, 2440, 36, 1, 54 },
- { 0x0, 0x0, 143, 1006, 1959, 0, 0, -1 },
- { 0x1, 0x1, 143, 1007, -1, 27, 1, 49 },
- { 0x1, 0x1, 144, -1, 2395, 37, 1, 1 },
- { 0x1, 0x1, 144, -1, 2405, 37, 1, 1 },
- { 0x1, 0x1, 144, -1, 2415, 37, 1, 1 },
- { 0x0, 0x0, 144, -1, 2429, 0, 1, 1 },
- { 0x0, 0x0, 145, -1, -1, 0, 1, 33 },
- { 0x0, 0x0, 145, 946, -1, 0, 1, 40 },
- { 0x0, 0x0, 146, -1, -1, 0, 1, 40 },
- { 0x0, 0x0, 146, -1, -1, 0, 1, 66 },
- { 0x0, 0x0, 146, -1, 2433, 0, 1, 63 },
- { 0x0, 0x0, 146, -1, -1, 0, 1, 81 },
- { 0x0, 0x0, 146, -1, -1, 0, 1, 81 },
- { 0x0, 0x0, 146, -1, -1, 0, 1, 85 },
- { 0x0, 0x0, 146, -1, -1, 0, 1, 40 },
- { 0x1, 0x1, 147, -1, 448, 12, 1, 6 },
- { 0x1, 0x1, 147, -1, 451, 12, 1, 6 },
- { 0x200001, 0x200001, 147, -1, 453, 12, 1, 6 },
- { 0x400001, 0x400001, 147, -1, 455, 12, 1, 6 },
- { 0x600001, 0x600001, 147, -1, 457, 12, 1, 6 },
- { 0x1, 0x1, 147, -1, 459, 12, 1, 6 },
- { 0x200001, 0x200001, 147, -1, 461, 12, 1, 6 },
- { 0x400001, 0x400001, 147, -1, 463, 12, 1, 6 },
- { 0x600001, 0x600001, 147, -1, 465, 12, 1, 6 },
- { 0x41, 0x41, 147, -1, 467, 6, 1, 7 },
- { 0x8000041, 0x8000041, 147, -1, 469, 6, 1, 7 },
- { 0x10000041, 0x10000041, 147, -1, 471, 6, 1, 7 },
- { 0x18000041, 0x18000041, 147, -1, 473, 6, 1, 7 },
- { 0x1, 0x1, 147, -1, 487, 12, 1, 8 },
- { 0x200001, 0x200001, 147, -1, 489, 12, 1, 8 },
- { 0x400001, 0x400001, 147, -1, 491, 12, 1, 8 },
- { 0x600001, 0x600001, 147, -1, 493, 12, 1, 8 },
- { 0x1, 0x1, 147, -1, 499, 12, 1, 15 },
- { 0x200001, 0x200001, 147, -1, 501, 12, 1, 15 },
- { 0x400001, 0x400001, 147, -1, 503, 12, 1, 15 },
- { 0x600001, 0x600001, 147, -1, 505, 12, 1, 15 },
- { 0x1, 0x1, 147, -1, 511, 12, 1, 17 },
- { 0x1, 0x1, 147, -1, 514, 12, 1, 17 },
- { 0x200001, 0x200001, 147, -1, 516, 12, 1, 17 },
- { 0x400001, 0x400001, 147, -1, 518, 12, 1, 17 },
- { 0x600001, 0x600001, 147, -1, 520, 12, 1, 17 },
- { 0x1, 0x1, 147, -1, 522, 12, 1, 17 },
- { 0x200001, 0x200001, 147, -1, 524, 12, 1, 17 },
- { 0x400001, 0x400001, 147, -1, 526, 12, 1, 17 },
- { 0x600001, 0x600001, 147, -1, 528, 12, 1, 17 },
- { 0x1, 0x1, 147, -1, 538, 12, 1, 18 },
- { 0x200001, 0x200001, 147, -1, 540, 12, 1, 18 },
- { 0x400001, 0x400001, 147, -1, 542, 12, 1, 18 },
- { 0x600001, 0x600001, 147, -1, 544, 12, 1, 18 },
- { 0x41, 0x41, 147, -1, 546, 6, 1, 18 },
- { 0x8000041, 0x8000041, 147, -1, 548, 6, 1, 18 },
- { 0x10000041, 0x10000041, 147, -1, 550, 6, 1, 18 },
- { 0x18000041, 0x18000041, 147, -1, 552, 6, 1, 18 },
- { 0x1, 0x1, 147, -1, 562, 12, 1, 19 },
- { 0x200001, 0x200001, 147, -1, 564, 12, 1, 19 },
- { 0x400001, 0x400001, 147, -1, 566, 12, 1, 19 },
- { 0x600001, 0x600001, 147, -1, 568, 12, 1, 19 },
- { 0x1, 0x1, 147, -1, 574, 12, 1, 20 },
- { 0x200001, 0x200001, 147, -1, 576, 12, 1, 20 },
- { 0x400001, 0x400001, 147, -1, 578, 12, 1, 20 },
- { 0x600001, 0x600001, 147, -1, 580, 12, 1, 20 },
- { 0x41, 0x41, 147, -1, 582, 6, 1, 20 },
- { 0x8000041, 0x8000041, 147, -1, 584, 6, 1, 20 },
- { 0x10000041, 0x10000041, 147, -1, 586, 6, 1, 20 },
- { 0x18000041, 0x18000041, 147, -1, 588, 6, 1, 20 },
- { 0x1, 0x1, 147, -1, 598, 12, 1, 21 },
- { 0x200001, 0x200001, 147, -1, 600, 12, 1, 21 },
- { 0x400001, 0x400001, 147, -1, 602, 12, 1, 21 },
- { 0x600001, 0x600001, 147, -1, 604, 12, 1, 21 },
- { 0x1, 0x1, 147, -1, 610, 12, 1, 17 },
- { 0x1, 0x1, 147, -1, 613, 12, 1, 17 },
- { 0x200001, 0x200001, 147, -1, 615, 12, 1, 17 },
- { 0x400001, 0x400001, 147, -1, 617, 12, 1, 17 },
- { 0x600001, 0x600001, 147, -1, 619, 12, 1, 17 },
- { 0x1, 0x1, 147, -1, 621, 12, 1, 17 },
- { 0x200001, 0x200001, 147, -1, 623, 12, 1, 17 },
- { 0x400001, 0x400001, 147, -1, 625, 12, 1, 17 },
- { 0x600001, 0x600001, 147, -1, 627, 12, 1, 17 },
- { 0x1, 0x1, 147, -1, 637, 12, 1, 21 },
- { 0x200001, 0x200001, 147, -1, 639, 12, 1, 21 },
- { 0x400001, 0x400001, 147, -1, 641, 12, 1, 21 },
- { 0x600001, 0x600001, 147, -1, 643, 12, 1, 21 },
- { 0x0, 0x0, 156, 648, -1, 0, 1, 75 },
- { 0x0, 0x0, 156, 649, -1, 0, 1, 75 },
- { 0x9, 0x9, 156, -1, 1202, 32, 1, 129 },
- { 0x9, 0x9, 156, -1, 1211, 32, 1, 129 },
- { 0x9, 0x9, 156, -1, 1220, 32, 1, 129 },
- { 0x9, 0x9, 156, -1, 1229, 32, 1, 129 },
- { 0x9, 0x9, 156, -1, 1238, 32, 1, 129 },
- { 0x9, 0x9, 156, -1, 1247, 32, 1, 129 },
- { 0x9, 0x9, 156, -1, 1256, 32, 1, 129 },
- { 0x9, 0x9, 156, -1, 1265, 32, 1, 129 },
- { 0x9, 0x9, 156, -1, 1274, 32, 1, 129 },
- { 0x9, 0x9, 156, -1, 1284, 32, 1, 129 },
- { 0x9, 0x9, 156, -1, 1294, 32, 1, 129 },
- { 0x9, 0x9, 156, -1, 1304, 32, 1, 129 },
- { 0x9, 0x9, 156, -1, 1313, 32, 1, 141 },
- { 0x9, 0x9, 156, -1, 1319, 32, 1, 141 },
- { 0x9, 0x9, 156, -1, 1325, 32, 1, 141 },
- { 0x9, 0x9, 156, -1, 1331, 32, 1, 141 },
- { 0x9, 0x9, 156, -1, 1337, 32, 1, 141 },
- { 0x9, 0x9, 156, -1, 1343, 32, 1, 141 },
- { 0x9, 0x9, 156, -1, 1349, 32, 1, 141 },
- { 0x9, 0x9, 156, -1, 1355, 32, 1, 141 },
- { 0x9, 0x9, 156, -1, 1361, 32, 1, 141 },
- { 0x9, 0x9, 156, -1, 1367, 32, 1, 141 },
- { 0x9, 0x9, 156, -1, 1373, 32, 1, 141 },
- { 0x9, 0x9, 156, -1, 1379, 32, 1, 141 },
- { 0x9, 0x9, 156, -1, 1385, 32, 1, 141 },
- { 0x9, 0x9, 156, -1, 1391, 32, 1, 141 },
- { 0x9, 0x9, 156, -1, 1397, 32, 1, 141 },
- { 0x9, 0x9, 156, -1, 1403, 32, 1, 141 },
- { 0x9, 0x9, 156, -1, 1409, 32, 1, 141 },
- { 0x9, 0x9, 156, -1, 1415, 32, 1, 141 },
- { 0x0, 0x0, 157, 1032, 282, 0, 0, -1 },
- { 0x1, 0x1, 157, -1, 2402, 38, 1, 1 },
- { 0x0, 0x0, 157, 779, 339, 0, 0, -1 },
- { 0x0, 0x0, 157, 1033, 292, 0, 0, -1 },
- { 0x1, 0x1, 157, -1, 2410, 38, 1, 1 },
- { 0x0, 0x0, 157, 781, 359, 0, 0, -1 },
- { 0x0, 0x0, 157, 782, 293, 0, 0, -1 },
- { 0x0, 0x0, 157, 783, 303, 0, 0, -1 },
- { 0x0, 0x0, 157, 1034, 306, 0, 0, -1 },
- { 0x1, 0x1, 157, -1, 2422, 38, 1, 1 },
- { 0x0, 0x0, 157, 785, 363, 0, 0, -1 },
- { 0x0, 0x0, 157, -1, 316, 0, 0, -1 },
- { 0x1, 0x1, 157, -1, 2428, 38, 1, 1 },
- { 0x0, 0x0, 157, 787, 383, 0, 0, -1 },
- { 0x0, 0x0, 157, 788, 317, 0, 0, -1 },
- { 0x0, 0x0, 157, 789, 327, 0, 0, -1 },
- { 0x0, 0x0, 158, 1175, 1918, 0, 0, -1 },
- { 0x0, 0x0, 158, 1176, 2451, 0, 1, 54 },
- { 0x0, 0x0, 158, 1177, 1962, 0, 0, -1 },
- { 0x1, 0x1, 158, 1178, -1, 29, 1, 49 },
- { 0x0, 0x0, 159, -1, 1928, 0, 0, -1 },
- { 0x1, 0x9, 159, -1, 2458, 33, 1, 54 },
- { 0x6, 0x7, 159, -1, 1969, 27, 1, 49 },
- { 0x0, 0x0, 160, 1164, 1926, 0, 0, -1 },
- { 0x0, 0x0, 160, 1165, 2457, 0, 1, 54 },
- { 0x1, 0x1, 160, 1166, 1968, 29, 1, 49 },
- { 0x1, 0x1, 161, 1180, -1, 27, 1, 33 },
- { 0x0, 0x0, 162, 1811, 1922, 0, 0, -1 },
- { 0x1, 0x1, 162, 1812, 2453, 33, 1, 54 },
- { 0x0, 0x0, 162, 1813, 1964, 0, 0, -1 },
- { 0x3, 0x3, 162, 1814, -1, 28, 1, 49 },
- { 0x0, 0x0, 163, 1171, 1920, 0, 0, -1 },
- { 0x1, 0x1, 163, 1172, 2452, 36, 1, 54 },
- { 0x0, 0x0, 163, 1173, 1963, 0, 0, -1 },
- { 0x5, 0x5, 163, 1174, -1, 27, 1, 49 },
- { 0x0, 0x0, 164, -1, 2434, 0, 1, 63 },
- { 0x1, 0x1, 166, -1, -1, 28, 1, 33 },
- { 0x1, 0x1, 167, 2292, -1, 27, 1, 33 },
- { 0x1, 0x1, 167, 2293, -1, 27, 1, 33 },
- { 0x1, 0x1, 168, 1445, -1, 28, 1, 132 },
- { 0x1, 0x1, 168, 1446, -1, 28, 1, 132 },
- { 0x1, 0x1, 168, 1447, -1, 28, 1, 132 },
- { 0x1, 0x1, 168, 1448, -1, 28, 1, 132 },
- { 0x1, 0x1, 168, 1449, -1, 28, 1, 132 },
- { 0x1, 0x1, 168, 1450, -1, 28, 1, 132 },
- { 0x1, 0x1, 168, 1451, -1, 28, 1, 132 },
- { 0x1, 0x1, 168, 1452, -1, 28, 1, 132 },
- { 0x1, 0x1, 168, 1453, -1, 28, 1, 133 },
- { 0x1, 0x1, 168, 1454, -1, 28, 1, 133 },
- { 0x1, 0x1, 168, 1455, -1, 28, 1, 133 },
- { 0x1, 0x1, 168, 1456, -1, 28, 1, 133 },
- { 0x1, 0x1, 168, 1457, -1, 28, 1, 125 },
- { 0x1, 0x1, 168, 1458, -1, 28, 1, 126 },
- { 0x1, 0x1, 168, 1459, -1, 28, 1, 127 },
- { 0x1, 0x1, 168, 1460, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1461, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1462, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1463, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1464, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1465, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1466, -1, 28, 1, 125 },
- { 0x1, 0x1, 168, 1467, -1, 28, 1, 126 },
- { 0x1, 0x1, 168, 1468, -1, 28, 1, 127 },
- { 0x1, 0x1, 168, 1469, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1470, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1471, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1472, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1473, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1474, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1475, -1, 28, 1, 125 },
- { 0x1, 0x1, 168, 1476, -1, 28, 1, 126 },
- { 0x1, 0x1, 168, 1477, -1, 28, 1, 127 },
- { 0x1, 0x1, 168, 1478, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1479, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1480, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1481, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1482, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1483, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1484, -1, 28, 1, 125 },
- { 0x1, 0x1, 168, 1485, -1, 28, 1, 126 },
- { 0x1, 0x1, 168, 1486, -1, 28, 1, 127 },
- { 0x1, 0x1, 168, 1487, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1488, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1489, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1490, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1491, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1492, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1493, -1, 28, 1, 125 },
- { 0x1, 0x1, 168, 1494, -1, 28, 1, 126 },
- { 0x1, 0x1, 168, 1495, -1, 28, 1, 127 },
- { 0x1, 0x1, 168, 1496, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1497, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1498, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1499, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1500, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1501, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1502, -1, 28, 1, 125 },
- { 0x1, 0x1, 168, 1503, -1, 28, 1, 126 },
- { 0x1, 0x1, 168, 1504, -1, 28, 1, 127 },
- { 0x1, 0x1, 168, 1505, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1506, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1507, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1508, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1509, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1510, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1511, -1, 28, 1, 125 },
- { 0x1, 0x1, 168, 1512, -1, 28, 1, 126 },
- { 0x1, 0x1, 168, 1513, -1, 28, 1, 127 },
- { 0x1, 0x1, 168, 1514, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1515, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1516, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1517, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1518, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1519, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1520, -1, 28, 1, 125 },
- { 0x1, 0x1, 168, 1521, -1, 28, 1, 126 },
- { 0x1, 0x1, 168, 1522, -1, 28, 1, 127 },
- { 0x1, 0x1, 168, 1523, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1524, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1525, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1526, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1527, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1528, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1529, -1, 28, 1, 125 },
- { 0x1, 0x1, 168, 1530, -1, 28, 1, 126 },
- { 0x1, 0x1, 168, 1531, -1, 28, 1, 127 },
- { 0x1, 0x1, 168, 1532, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1533, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1534, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1535, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1536, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1537, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1538, -1, 28, 1, 125 },
- { 0x1, 0x1, 168, 1539, -1, 28, 1, 126 },
- { 0x1, 0x1, 168, 1540, -1, 28, 1, 127 },
- { 0x1, 0x1, 168, 1541, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1542, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1543, -1, 28, 1, 128 },
- { 0x1, 0x1, 168, 1544, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1545, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1546, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1547, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1548, -1, 28, 1, 125 },
- { 0x1, 0x1, 168, 1549, -1, 28, 1, 126 },
- { 0x1, 0x1, 168, 1550, -1, 28, 1, 127 },
- { 0x1, 0x1, 168, 1551, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1552, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1553, -1, 28, 1, 128 },
- { 0x1, 0x1, 168, 1554, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1555, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1556, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1557, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1558, -1, 28, 1, 125 },
- { 0x1, 0x1, 168, 1559, -1, 28, 1, 126 },
- { 0x1, 0x1, 168, 1560, -1, 28, 1, 127 },
- { 0x1, 0x1, 168, 1561, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1562, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1563, -1, 28, 1, 128 },
- { 0x1, 0x1, 168, 1564, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1565, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1566, -1, 28, 1, 129 },
- { 0x1, 0x1, 168, 1567, -1, 28, 1, 124 },
- { 0x1, 0x1, 168, 1568, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1569, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1570, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1571, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1572, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1573, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1574, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1575, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1576, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1577, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1578, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1579, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1580, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1581, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1582, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1583, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1584, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1585, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1586, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1587, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1588, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1589, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1590, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1591, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1592, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1593, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1594, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1595, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1596, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1597, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1598, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1599, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1600, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1601, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1602, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1603, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1604, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1605, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1606, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1607, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1608, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1609, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1610, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1611, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1612, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1613, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1614, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1615, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1616, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1617, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1618, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1619, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1620, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1621, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1622, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1623, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1624, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1625, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1626, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1627, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1628, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1629, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1630, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1631, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1632, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1633, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1634, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1635, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1636, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1637, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1638, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1639, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1640, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1641, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1642, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1643, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1644, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1645, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1646, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1647, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1648, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1649, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1650, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1651, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1652, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1653, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1654, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1655, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1656, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1657, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1658, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1659, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1660, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1661, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1662, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1663, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1664, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1665, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1666, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1667, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1668, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1669, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1670, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1671, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1672, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1673, -1, 28, 1, 138 },
- { 0x1, 0x1, 168, 1674, -1, 28, 1, 139 },
- { 0x1, 0x1, 168, 1675, -1, 28, 1, 140 },
- { 0x1, 0x1, 168, 1676, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1677, -1, 28, 1, 141 },
- { 0x1, 0x1, 168, 1678, -1, 28, 1, 137 },
- { 0x1, 0x1, 168, 1433, -1, 28, 1, 142 },
- { 0x1, 0x1, 168, 1434, -1, 28, 1, 143 },
- { 0x1, 0x1, 168, 1435, -1, 28, 1, 143 },
- { 0x1, 0x1, 168, 1436, -1, 28, 1, 142 },
- { 0x1, 0x1, 168, 1437, -1, 28, 1, 144 },
- { 0x1, 0x1, 168, 1438, -1, 28, 1, 145 },
- { 0x1, 0x1, 168, 1439, -1, 28, 1, 145 },
- { 0x1, 0x1, 168, 1440, -1, 28, 1, 144 },
- { 0x1, 0x1, 168, 1441, -1, 28, 1, 144 },
- { 0x1, 0x1, 168, 1442, -1, 28, 1, 145 },
- { 0x1, 0x1, 168, 1443, -1, 28, 1, 145 },
- { 0x1, 0x1, 168, 1444, -1, 28, 1, 144 },
- { 0x1, 0x1, 168, 1719, -1, 28, 1, 133 },
- { 0x1, 0x1, 168, 1720, -1, 28, 1, 133 },
- { 0x1, 0x1, 168, 1721, -1, 28, 1, 133 },
- { 0x1, 0x1, 168, 1722, -1, 28, 1, 133 },
- { 0x1, 0x1, 169, 1679, -1, 29, 1, 142 },
- { 0x1, 0x1, 169, 1680, -1, 29, 1, 143 },
- { 0x1, 0x1, 169, 1681, -1, 29, 1, 143 },
- { 0x1, 0x1, 169, 1682, -1, 29, 1, 142 },
- { 0x1, 0x1, 169, 1683, -1, 29, 1, 144 },
- { 0x1, 0x1, 169, 1684, -1, 29, 1, 145 },
- { 0x1, 0x1, 169, 1685, -1, 29, 1, 145 },
- { 0x1, 0x1, 169, 1686, -1, 29, 1, 144 },
- { 0x1, 0x1, 169, 1687, -1, 29, 1, 144 },
- { 0x1, 0x1, 169, 1688, -1, 29, 1, 145 },
- { 0x1, 0x1, 169, 1689, -1, 29, 1, 145 },
- { 0x1, 0x1, 169, 1690, -1, 29, 1, 144 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 132 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 132 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 132 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 132 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 132 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 132 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 132 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 132 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 133 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 133 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 133 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 133 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 125 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 126 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 127 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 257, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 1867, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 125 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 126 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 127 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 259, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 1868, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 125 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 126 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 127 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 261, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 1869, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 125 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 126 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 127 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 263, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 1870, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 125 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 126 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 127 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 265, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 1871, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 125 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 126 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 127 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 267, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 1872, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 125 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 126 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 127 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 269, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 1873, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 125 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 126 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 127 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 271, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 1874, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 125 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 126 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 127 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 273, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 1875, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 125 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 126 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 127 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 128 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 275, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 1876, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 125 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 126 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 127 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 128 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 277, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 1877, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 125 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 126 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 127 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 128 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 279, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 129 },
- { 0x3, 0x3, 170, 1878, -1, 28, 1, 124 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1879, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1880, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1881, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1882, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1883, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1884, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1885, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1886, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1887, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1888, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1889, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1890, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1891, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1892, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1893, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1894, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1895, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 138 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 139 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 140 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 141 },
- { 0x3, 0x3, 170, 1896, -1, 28, 1, 137 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 142 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 143 },
- { 0x3, 0x3, 170, 797, -1, 28, 1, 143 },
- { 0x3, 0x3, 170, 798, -1, 28, 1, 142 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 144 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 145 },
- { 0x3, 0x3, 170, 799, -1, 28, 1, 145 },
- { 0x3, 0x3, 170, 800, -1, 28, 1, 144 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 144 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 145 },
- { 0x3, 0x3, 170, 801, -1, 28, 1, 145 },
- { 0x3, 0x3, 170, 802, -1, 28, 1, 144 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, 1835, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 135 },
- { 0x3, 0x3, 170, 1836, -1, 28, 1, 135 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, 1837, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 135 },
- { 0x3, 0x3, 170, 1838, -1, 28, 1, 135 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, 1839, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 135 },
- { 0x3, 0x3, 170, 1840, -1, 28, 1, 135 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 131 },
- { 0x3, 0x3, 170, 1841, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 135 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 136 },
- { 0x3, 0x3, 170, 1842, -1, 28, 1, 135 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 130 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 133 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 133 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 133 },
- { 0x3, 0x3, 170, -1, -1, 28, 1, 133 },
- { 0x0, 0x0, 171, -1, 330, 0, 0, -1 },
- { 0x0, 0x0, 171, 2490, 2460, 0, 1, 1 },
- { 0x0, 0x0, 171, -1, 334, 0, 0, -1 },
- { 0x0, 0x0, 171, 2492, 2462, 0, 1, 1 },
- { 0x11, 0x31, 172, 2394, 337, 33, 1, 4 },
- { 0x2200001, 0x2200001, 172, -1, 338, 12, 1, 4 },
- { 0x1, 0x1, 172, -1, 341, 37, 1, 4 },
- { 0x2000001, 0x2000001, 172, -1, 342, 12, 1, 4 },
- { 0x11, 0x11, 172, -1, 343, 33, 1, 4 },
- { 0x2200001, 0x2200001, 172, -1, 344, 12, 1, 4 },
- { 0x1, 0x1, 172, 1757, 345, 37, 1, 4 },
- { 0x2000001, 0x2000001, 172, -1, 347, 12, 1, 4 },
- { 0x11, 0x11, 172, 1759, 349, 33, 1, 4 },
- { 0x2200001, 0x2200001, 172, -1, 351, 12, 1, 4 },
- { 0x11, 0x31, 172, 2404, 357, 33, 1, 4 },
- { 0x2200001, 0x2200001, 172, -1, 358, 12, 1, 4 },
- { 0x11, 0x31, 172, 2414, 361, 33, 1, 4 },
- { 0x2200001, 0x2200001, 172, -1, 362, 12, 1, 4 },
- { 0x1, 0x1, 172, -1, 365, 37, 1, 4 },
- { 0x2000001, 0x2000001, 172, -1, 366, 12, 1, 4 },
- { 0x11, 0x11, 172, -1, 367, 33, 1, 4 },
- { 0x2200001, 0x2200001, 172, -1, 368, 12, 1, 4 },
- { 0x1, 0x1, 172, 1781, 369, 37, 1, 4 },
- { 0x2000001, 0x2000001, 172, -1, 371, 12, 1, 4 },
- { 0x11, 0x11, 172, 1783, 373, 33, 1, 4 },
- { 0x2200001, 0x2200001, 172, -1, 375, 12, 1, 4 },
- { 0x11, 0x31, 172, 2424, 381, 33, 1, 4 },
- { 0x2200001, 0x2200001, 172, -1, 382, 12, 1, 4 },
- { 0x1, 0x1, 172, -1, 385, 33, 1, 4 },
- { 0x200001, 0x200001, 172, -1, 386, 12, 1, 4 },
- { 0x1, 0x1, 172, -1, 389, 33, 1, 4 },
- { 0x200001, 0x200001, 172, -1, 390, 12, 1, 4 },
- { 0x1, 0x1, 173, -1, -1, 37, 1, 4 },
- { 0x2000001, 0x2000001, 173, -1, -1, 12, 1, 4 },
- { 0x2000001, 0x2000001, 173, -1, -1, 12, 1, 4 },
- { 0x1, 0x1, 173, 1734, -1, 37, 1, 4 },
- { 0x2200001, 0x2200001, 173, -1, -1, 12, 1, 4 },
- { 0x11, 0x11, 173, 1736, -1, 33, 1, 4 },
- { 0x1, 0x1, 173, -1, -1, 37, 1, 4 },
- { 0x2000001, 0x2000001, 173, -1, -1, 12, 1, 4 },
- { 0x11, 0x11, 173, -1, -1, 33, 1, 4 },
- { 0x2200001, 0x2200001, 173, -1, -1, 12, 1, 4 },
- { 0x1, 0x1, 173, -1, -1, 37, 1, 4 },
- { 0x2000001, 0x2000001, 173, -1, -1, 12, 1, 4 },
- { 0x0, 0x0, 173, -1, -1, 0, 1, 5 },
- { 0x1, 0x1, 173, -1, -1, 12, 1, 5 },
- { 0x0, 0x0, 173, -1, -1, 0, 1, 5 },
- { 0x1, 0x1, 173, -1, -1, 12, 1, 5 },
- { 0x1, 0x1, 173, -1, -1, 33, 1, 5 },
- { 0x200001, 0x200001, 173, -1, -1, 12, 1, 5 },
- { 0x0, 0x0, 173, -1, -1, 0, 1, 5 },
- { 0x1, 0x1, 173, -1, -1, 12, 1, 5 },
- { 0x1, 0x1, 173, -1, -1, 33, 1, 5 },
- { 0x200001, 0x200001, 173, -1, -1, 12, 1, 5 },
- { 0x0, 0x0, 173, -1, -1, 0, 1, 5 },
- { 0x1, 0x1, 173, -1, -1, 12, 1, 5 },
- { 0x1, 0x1, 173, -1, -1, 37, 1, 4 },
- { 0x2000001, 0x2000001, 173, -1, -1, 12, 1, 4 },
- { 0x2000001, 0x2000001, 173, -1, -1, 12, 1, 4 },
- { 0x1, 0x1, 173, 1746, -1, 37, 1, 4 },
- { 0x2200001, 0x2200001, 173, -1, -1, 12, 1, 4 },
- { 0x11, 0x11, 173, 1748, -1, 33, 1, 4 },
- { 0x1, 0x1, 173, -1, -1, 37, 1, 4 },
- { 0x2000001, 0x2000001, 173, -1, -1, 12, 1, 4 },
- { 0x11, 0x11, 173, -1, -1, 33, 1, 4 },
- { 0x2200001, 0x2200001, 173, -1, -1, 12, 1, 4 },
- { 0x1, 0x1, 173, -1, -1, 37, 1, 4 },
- { 0x2000001, 0x2000001, 173, -1, -1, 12, 1, 4 },
- { 0x0, 0x0, 173, -1, -1, 0, 1, 5 },
- { 0x1, 0x1, 173, -1, -1, 12, 1, 5 },
- { 0x0, 0x0, 173, -1, -1, 0, 1, 5 },
- { 0x1, 0x1, 173, -1, -1, 12, 1, 5 },
- { 0x1, 0x1, 173, -1, -1, 33, 1, 5 },
- { 0x200001, 0x200001, 173, -1, -1, 12, 1, 5 },
- { 0x0, 0x0, 173, -1, -1, 0, 1, 5 },
- { 0x1, 0x1, 173, -1, -1, 12, 1, 5 },
- { 0x1, 0x1, 173, -1, -1, 33, 1, 5 },
- { 0x200001, 0x200001, 173, -1, -1, 12, 1, 5 },
- { 0x0, 0x0, 173, -1, -1, 0, 1, 5 },
- { 0x1, 0x1, 173, -1, -1, 12, 1, 5 },
- { 0x9, 0x9, 173, -1, -1, 33, 1, 5 },
- { 0x1, 0x1, 173, 331, -1, 33, 1, 4 },
- { 0x1200001, 0x1200001, 173, -1, -1, 12, 1, 5 },
- { 0x200001, 0x200001, 173, 332, -1, 12, 1, 4 },
- { 0x9, 0x9, 173, -1, -1, 33, 1, 5 },
- { 0x1, 0x1, 173, 335, -1, 33, 1, 4 },
- { 0x1200001, 0x1200001, 173, -1, -1, 12, 1, 5 },
- { 0x200001, 0x200001, 173, 336, -1, 12, 1, 4 },
- { 0x0, 0x0, 174, -1, 1924, 0, 0, -1 },
- { 0x9, 0x9, 174, -1, 2454, 33, 1, 49 },
- { 0x0, 0x0, 174, -1, 1965, 0, 0, -1 },
- { 0x7, 0x7, 174, -1, -1, 27, 1, 49 },
- { 0x1, 0x1, 194, -1, -1, 27, 1, 10 },
- { 0x1, 0x1, 208, -1, -1, 29, 1, 0 },
- { 0x1, 0x1, 208, -1, -1, 29, 1, 0 },
- { 0x2, 0x3, 208, 978, -1, 27, 1, 33 },
- { 0x0, 0x0, 208, 979, -1, 0, 1, 33 },
- { 0x0, 0x0, 208, 980, -1, 0, 1, 0 },
- { 0x0, 0x0, 208, 981, -1, 0, 1, 0 },
- { 0x0, 0x0, 208, 982, -1, 0, 1, 0 },
- { 0x0, 0x0, 208, 983, -1, 0, 1, 0 },
- { 0x0, 0x0, 208, 2476, -1, 0, 1, 93 },
- { 0x0, 0x0, 208, 2477, -1, 0, 1, 93 },
- { 0x0, 0x0, 208, 2478, 812, 0, 0, -1 },
- { 0x1, 0x1, 209, -1, -1, 27, 1, 0 },
- { 0x1, 0x1, 209, -1, -1, 27, 1, 0 },
- { 0x1, 0x1, 210, -1, 1184, 32, 1, 132 },
- { 0x1, 0x1, 210, -1, 1186, 32, 1, 132 },
- { 0x1, 0x1, 210, -1, 1188, 32, 1, 132 },
- { 0x1, 0x1, 210, -1, 1190, 32, 1, 132 },
- { 0x1, 0x1, 210, -1, 1192, 32, 1, 133 },
- { 0x1, 0x1, 210, -1, 1194, 32, 1, 133 },
- { 0x1, 0x1, 210, -1, 1691, 32, 1, 130 },
- { 0x1, 0x1, 210, -1, 1693, 32, 1, 135 },
- { 0x1, 0x1, 210, -1, 1695, 32, 1, 130 },
- { 0x1, 0x1, 210, -1, 1697, 32, 1, 135 },
- { 0x1, 0x1, 210, -1, 1699, 32, 1, 130 },
- { 0x1, 0x1, 210, -1, 1701, 32, 1, 135 },
- { 0x1, 0x1, 210, 2296, 1703, 32, 1, 130 },
- { 0x1, 0x1, 210, 2297, 1706, 32, 1, 135 },
- { 0x0, 0x0, 211, -1, 2338, 0, 0, -1 },
- { 0x0, 0x0, 211, -1, 2339, 0, 0, -1 },
- { 0x0, 0x0, 211, -1, 2364, 0, 0, -1 },
- { 0x5, 0x5, 211, -1, 2367, 20, 1, 67 },
- { 0x0, 0x0, 215, 1826, 811, 0, 0, -1 },
- { 0x0, 0x0, 216, -1, 950, 0, 0, -1 },
- { 0x0, 0x0, 216, -1, 1039, 0, 0, -1 },
- { 0x0, 0x0, 216, -1, -1, 0, 1, 121 },
- { 0x0, 0x0, 216, -1, -1, 0, 1, 66 },
- { 0x1, 0x1, 216, 688, 1898, 36, 1, 65 },
- { 0x1, 0x1, 216, 689, 1933, 36, 1, 65 },
- { 0x0, 0x0, 216, 690, 1936, 0, 0, -1 },
- { 0x1, 0x1, 216, 691, -1, 36, 1, 65 },
- { 0x0, 0x0, 216, 1181, -1, 0, 1, 33 },
- { 0x1, 0x1, 216, 692, 1941, 36, 1, 65 },
- { 0x0, 0x0, 216, 693, 1944, 0, 0, -1 },
- { 0x1, 0x1, 216, 694, -1, 36, 1, 65 },
- { 0x0, 0x0, 216, 695, 1947, 0, 0, -1 },
- { 0x1, 0x1, 216, 696, -1, 36, 1, 65 },
- { 0x1, 0x1, 216, 697, 1950, 36, 1, 65 },
- { 0x1, 0x1, 216, 698, 1953, 36, 1, 65 },
- { 0x0, 0x0, 216, 1182, -1, 0, 1, 33 },
- { 0x1, 0x1, 216, 699, 1986, 36, 1, 65 },
- { 0x1, 0x1, 216, 700, -1, 31, 1, 134 },
- { 0x1, 0x1, 216, 220, 1195, 32, 1, 125 },
- { 0x1, 0x1, 216, 221, 1204, 32, 1, 125 },
- { 0x1, 0x1, 216, 222, 1213, 32, 1, 125 },
- { 0x1, 0x1, 216, 223, 1222, 32, 1, 125 },
- { 0x1, 0x1, 216, 224, 1231, 32, 1, 125 },
- { 0x1, 0x1, 216, 225, 1240, 32, 1, 125 },
- { 0x1, 0x1, 216, 226, 1249, 32, 1, 125 },
- { 0x1, 0x1, 216, 227, 1258, 32, 1, 125 },
- { 0x1, 0x1, 216, 228, 1267, 32, 1, 125 },
- { 0x1, 0x1, 216, 229, 1276, 32, 1, 125 },
- { 0x1, 0x1, 216, 230, 1286, 32, 1, 125 },
- { 0x1, 0x1, 216, 231, 1296, 32, 1, 125 },
- { 0x1, 0x1, 216, 232, 1309, 32, 1, 138 },
- { 0x1, 0x1, 216, 233, 1315, 32, 1, 138 },
- { 0x1, 0x1, 216, 234, 1321, 32, 1, 138 },
- { 0x1, 0x1, 216, 235, 1327, 32, 1, 138 },
- { 0x1, 0x1, 216, 236, 1333, 32, 1, 138 },
- { 0x1, 0x1, 216, 237, 1339, 32, 1, 138 },
- { 0x1, 0x1, 216, 238, 1345, 32, 1, 138 },
- { 0x1, 0x1, 216, 239, 1351, 32, 1, 138 },
- { 0x1, 0x1, 216, 240, 1357, 32, 1, 138 },
- { 0x1, 0x1, 216, 241, 1363, 32, 1, 138 },
- { 0x1, 0x1, 216, 242, 1369, 32, 1, 138 },
- { 0x1, 0x1, 216, 243, 1375, 32, 1, 138 },
- { 0x1, 0x1, 216, 244, 1381, 32, 1, 138 },
- { 0x1, 0x1, 216, 245, 1387, 32, 1, 138 },
- { 0x1, 0x1, 216, 246, 1393, 32, 1, 138 },
- { 0x1, 0x1, 216, 247, 1399, 32, 1, 138 },
- { 0x1, 0x1, 216, 248, 1405, 32, 1, 138 },
- { 0x1, 0x1, 216, 249, 1411, 32, 1, 138 },
- { 0x1, 0x1, 216, 704, -1, 31, 1, 146 },
- { 0x0, 0x0, 217, 1989, -1, 0, 1, 65 },
- { 0x0, 0x0, 217, 1990, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 24, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 1992, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 1993, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 1994, -1, 0, 1, 44 },
- { 0x0, 0x0, 217, 1995, -1, 0, 1, 39 },
- { 0x1, 0x1, 217, 1996, -1, 12, 1, 58 },
- { 0x0, 0x0, 217, 1997, -1, 0, 1, 53 },
- { 0x1000001, 0x1000001, 217, 1998, -1, 12, 1, 58 },
- { 0x1, 0x1, 217, 1999, -1, 36, 1, 53 },
- { 0x200001, 0x200001, 217, 2000, -1, 12, 1, 58 },
- { 0x1, 0x1, 217, 2001, -1, 33, 1, 53 },
- { 0x1200001, 0x1200001, 217, 2002, -1, 12, 1, 48 },
- { 0x9, 0x9, 217, 2003, -1, 33, 1, 48 },
- { 0x1, 0x1, 217, 2004, -1, 12, 1, 58 },
- { 0x0, 0x0, 217, 2005, -1, 0, 1, 53 },
- { 0x200001, 0x1200001, 217, 2006, -1, 12, 1, 58 },
- { 0x1, 0x9, 217, 2007, -1, 33, 1, 53 },
- { 0x1, 0x1, 217, 2008, -1, 12, 1, 58 },
- { 0x0, 0x0, 217, 2009, -1, 0, 1, 53 },
- { 0x1000001, 0x1000001, 217, 2010, -1, 12, 1, 58 },
- { 0x1, 0x1, 217, 2011, -1, 36, 1, 53 },
- { 0x200001, 0x200001, 217, 2012, -1, 12, 1, 58 },
- { 0x1, 0x1, 217, 2013, -1, 33, 1, 53 },
- { 0x1200001, 0x1200001, 217, 2014, -1, 12, 1, 48 },
- { 0x9, 0x9, 217, 2015, -1, 33, 1, 48 },
- { 0x1, 0x1, 217, 2016, -1, 12, 1, 58 },
- { 0x0, 0x0, 217, 2017, -1, 0, 1, 53 },
- { 0x200001, 0x1200001, 217, 2018, -1, 12, 1, 58 },
- { 0x1, 0x9, 217, 2019, -1, 33, 1, 53 },
- { 0x1, 0x1, 217, 2020, -1, 28, 1, 28 },
- { 0x0, 0x0, 217, 2021, -1, 0, 1, 28 },
- { 0x3, 0x3, 217, 2022, -1, 27, 1, 28 },
- { 0x1, 0x1, 217, 2023, -1, 27, 1, 28 },
- { 0x0, 0x0, 217, 2024, -1, 0, 1, 65 },
- { 0x0, 0x0, 217, 2025, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 2026, -1, 0, 1, 28 },
- { 0x1, 0x1, 217, 2027, -1, 36, 1, 65 },
- { 0x1, 0x1, 217, 2028, -1, 37, 1, 28 },
- { 0x0, 0x0, 217, 2029, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 2030, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 2031, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 2032, -1, 0, 1, 65 },
- { 0x0, 0x0, 217, 2033, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 36, -1, 0, 1, 28 },
- { 0x1, 0x1, 217, 2035, -1, 36, 1, 65 },
- { 0x1, 0x1, 217, 2036, -1, 37, 1, 28 },
- { 0x0, 0x0, 217, 2037, -1, 0, 1, 28 },
- { 0x1, 0x1, 217, 2038, -1, 36, 1, 65 },
- { 0x1, 0x1, 217, 2039, -1, 37, 1, 28 },
- { 0x0, 0x0, 217, 2040, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 2041, -1, 0, 1, 65 },
- { 0x0, 0x0, 217, 2042, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 41, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 2044, -1, 0, 1, 65 },
- { 0x0, 0x0, 217, 2045, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 42, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 2047, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 2048, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 2049, -1, 0, 1, 48 },
- { 0x1, 0x1, 217, 2050, -1, 27, 1, 48 },
- { 0x1, 0x1, 217, 2051, -1, 28, 1, 48 },
- { 0x3, 0x3, 217, 2052, -1, 27, 1, 48 },
- { 0x1, 0x1, 217, 2053, -1, 29, 1, 48 },
- { 0x5, 0x5, 217, 2054, -1, 27, 1, 48 },
- { 0x3, 0x3, 217, 2055, -1, 28, 1, 48 },
- { 0x7, 0x7, 217, 2056, -1, 27, 1, 48 },
- { 0x0, 0x0, 217, 2057, -1, 0, 1, 48 },
- { 0x0, 0x0, 217, 2058, -1, 0, 1, 48 },
- { 0x0, 0x0, 217, 2059, -1, 0, 1, 48 },
- { 0x0, 0x0, 217, 2060, -1, 0, 1, 48 },
- { 0x1, 0x1, 217, 2061, -1, 28, 1, 28 },
- { 0x0, 0x0, 217, 2062, -1, 0, 1, 28 },
- { 0x3, 0x3, 217, 2063, -1, 27, 1, 28 },
- { 0x1, 0x1, 217, 2064, -1, 27, 1, 28 },
- { 0x0, 0x0, 217, 2065, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 2066, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 2067, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 51, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 2069, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 2070, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 56, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 2072, -1, 0, 1, 23 },
- { 0x0, 0x0, 217, 2073, -1, 0, 1, 23 },
- { 0x0, 0x0, 217, 2074, -1, 0, 1, 23 },
- { 0x0, 0x0, 217, 2075, -1, 0, 1, 23 },
- { 0x0, 0x0, 217, 2076, -1, 0, 1, 34 },
- { 0x0, 0x0, 217, 2077, -1, 0, 1, 65 },
- { 0x0, 0x0, 217, 2078, -1, 0, 1, 28 },
- { 0x0, 0x0, 217, 63, -1, 0, 1, 28 },
- { 0x1, 0x1, 218, 2080, -1, 34, 1, 65 },
- { 0x1, 0x1, 218, 2081, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2082, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2083, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2084, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2085, -1, 34, 1, 45 },
- { 0x1, 0x1, 218, 2086, -1, 34, 1, 41 },
- { 0x400001, 0x400001, 218, 2087, -1, 12, 1, 60 },
- { 0x1, 0x1, 218, 2088, -1, 34, 1, 55 },
- { 0x1400001, 0x1400001, 218, 2089, -1, 12, 1, 60 },
- { 0x5, 0x5, 218, 2090, -1, 34, 1, 55 },
- { 0x600001, 0x600001, 218, 2091, -1, 12, 1, 60 },
- { 0x3, 0x3, 218, 2092, -1, 33, 1, 55 },
- { 0x1600001, 0x1600001, 218, 2093, -1, 12, 1, 50 },
- { 0xb, 0xb, 218, 2094, -1, 33, 1, 50 },
- { 0x400001, 0x400001, 218, 2095, -1, 12, 1, 60 },
- { 0x1, 0x1, 218, 2096, -1, 34, 1, 55 },
- { 0x600001, 0x1600001, 218, 2097, -1, 12, 1, 60 },
- { 0x3, 0xb, 218, 2098, -1, 33, 1, 55 },
- { 0x400001, 0x400001, 218, 2099, -1, 12, 1, 60 },
- { 0x1, 0x1, 218, 2100, -1, 34, 1, 55 },
- { 0x1400001, 0x1400001, 218, 2101, -1, 12, 1, 60 },
- { 0x5, 0x5, 218, 2102, -1, 34, 1, 55 },
- { 0x600001, 0x600001, 218, 2103, -1, 12, 1, 60 },
- { 0x3, 0x3, 218, 2104, -1, 33, 1, 55 },
- { 0x1600001, 0x1600001, 218, 2105, -1, 12, 1, 50 },
- { 0xb, 0xb, 218, 2106, -1, 33, 1, 50 },
- { 0x400001, 0x400001, 218, 2107, -1, 12, 1, 60 },
- { 0x1, 0x1, 218, 2108, -1, 34, 1, 55 },
- { 0x600001, 0x1600001, 218, 2109, -1, 12, 1, 60 },
- { 0x3, 0xb, 218, 2110, -1, 33, 1, 55 },
- { 0x41, 0x41, 218, 2111, -1, 28, 1, 30 },
- { 0x1, 0x1, 218, 2112, -1, 34, 1, 30 },
- { 0x83, 0x83, 218, 2113, -1, 27, 1, 30 },
- { 0x81, 0x81, 218, 2114, -1, 27, 1, 30 },
- { 0x1, 0x1, 218, 2115, -1, 34, 1, 65 },
- { 0x1, 0x1, 218, 2116, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2117, -1, 34, 1, 30 },
- { 0x5, 0x5, 218, 2118, -1, 34, 1, 65 },
- { 0x9, 0x9, 218, 2119, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2120, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2121, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2122, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2123, -1, 34, 1, 65 },
- { 0x1, 0x1, 218, 2124, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2125, -1, 34, 1, 30 },
- { 0x5, 0x5, 218, 2126, -1, 34, 1, 65 },
- { 0x9, 0x9, 218, 2127, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2128, -1, 34, 1, 30 },
- { 0x5, 0x5, 218, 2129, -1, 34, 1, 65 },
- { 0x9, 0x9, 218, 2130, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2131, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2132, -1, 34, 1, 65 },
- { 0x1, 0x1, 218, 2133, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2134, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2135, -1, 34, 1, 65 },
- { 0x1, 0x1, 218, 2136, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2137, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2138, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2139, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2140, -1, 34, 1, 50 },
- { 0x81, 0x81, 218, 2141, -1, 27, 1, 50 },
- { 0x41, 0x41, 218, 2142, -1, 28, 1, 50 },
- { 0x83, 0x83, 218, 2143, -1, 27, 1, 50 },
- { 0x21, 0x21, 218, 2144, -1, 29, 1, 50 },
- { 0x85, 0x85, 218, 2145, -1, 27, 1, 50 },
- { 0x43, 0x43, 218, 2146, -1, 28, 1, 50 },
- { 0x87, 0x87, 218, 2147, -1, 27, 1, 50 },
- { 0x1, 0x1, 218, 2148, -1, 34, 1, 50 },
- { 0x1, 0x1, 218, 2149, -1, 34, 1, 50 },
- { 0x1, 0x1, 218, 2150, -1, 34, 1, 50 },
- { 0x1, 0x1, 218, 2151, -1, 34, 1, 50 },
- { 0x41, 0x41, 218, 2152, -1, 28, 1, 30 },
- { 0x1, 0x1, 218, 2153, -1, 34, 1, 30 },
- { 0x83, 0x83, 218, 2154, -1, 27, 1, 30 },
- { 0x81, 0x81, 218, 2155, -1, 27, 1, 30 },
- { 0x1, 0x1, 218, 2156, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2157, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2158, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2159, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2160, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2161, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2162, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2163, -1, 34, 1, 25 },
- { 0x1, 0x1, 218, 2164, -1, 34, 1, 25 },
- { 0x1, 0x1, 218, 2165, -1, 34, 1, 25 },
- { 0x1, 0x1, 218, 2166, -1, 34, 1, 25 },
- { 0x1, 0x1, 218, 2167, -1, 34, 1, 36 },
- { 0x1, 0x1, 218, 2168, -1, 34, 1, 65 },
- { 0x1, 0x1, 218, 2169, -1, 34, 1, 30 },
- { 0x1, 0x1, 218, 2170, -1, 34, 1, 30 },
- { 0x1, 0x1, 219, 2171, -1, 35, 1, 65 },
- { 0x1, 0x1, 219, 2172, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2173, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2174, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2175, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2176, -1, 35, 1, 46 },
- { 0x1, 0x1, 219, 2177, -1, 35, 1, 42 },
- { 0x800001, 0x800001, 219, 2178, -1, 12, 1, 61 },
- { 0x1, 0x1, 219, 2179, -1, 35, 1, 56 },
- { 0x1800001, 0x1800001, 219, 2180, -1, 12, 1, 61 },
- { 0x3, 0x3, 219, 2181, -1, 35, 1, 56 },
- { 0xa00001, 0xa00001, 219, 2182, -1, 12, 1, 61 },
- { 0x5, 0x5, 219, 2183, -1, 33, 1, 56 },
- { 0x1a00001, 0x1a00001, 219, 2184, -1, 12, 1, 51 },
- { 0xd, 0xd, 219, 2185, -1, 33, 1, 51 },
- { 0x800001, 0x800001, 219, 2186, -1, 12, 1, 61 },
- { 0x1, 0x1, 219, 2187, -1, 35, 1, 56 },
- { 0xa00001, 0x1a00001, 219, 2188, -1, 12, 1, 61 },
- { 0x5, 0xd, 219, 2189, -1, 33, 1, 56 },
- { 0x800001, 0x800001, 219, 2190, -1, 12, 1, 61 },
- { 0x1, 0x1, 219, 2191, -1, 35, 1, 56 },
- { 0x1800001, 0x1800001, 219, 2192, -1, 12, 1, 61 },
- { 0x3, 0x3, 219, 2193, -1, 35, 1, 56 },
- { 0xa00001, 0xa00001, 219, 2194, -1, 12, 1, 61 },
- { 0x5, 0x5, 219, 2195, -1, 33, 1, 56 },
- { 0x1a00001, 0x1a00001, 219, 2196, -1, 12, 1, 51 },
- { 0xd, 0xd, 219, 2197, -1, 33, 1, 51 },
- { 0x800001, 0x800001, 219, 2198, -1, 12, 1, 61 },
- { 0x1, 0x1, 219, 2199, -1, 35, 1, 56 },
- { 0xa00001, 0x1a00001, 219, 2200, -1, 12, 1, 61 },
- { 0x5, 0xd, 219, 2201, -1, 33, 1, 56 },
- { 0x81, 0x81, 219, 2202, -1, 28, 1, 31 },
- { 0x1, 0x1, 219, 2203, -1, 35, 1, 31 },
- { 0x103, 0x103, 219, 2204, -1, 27, 1, 31 },
- { 0x101, 0x101, 219, 2205, -1, 27, 1, 31 },
- { 0x1, 0x1, 219, 2206, -1, 35, 1, 65 },
- { 0x1, 0x1, 219, 2207, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2208, -1, 35, 1, 31 },
- { 0x3, 0x3, 219, 2209, -1, 35, 1, 65 },
- { 0x5, 0x5, 219, 2210, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2211, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2212, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2213, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2214, -1, 35, 1, 65 },
- { 0x1, 0x1, 219, 2215, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2216, -1, 35, 1, 31 },
- { 0x3, 0x3, 219, 2217, -1, 35, 1, 65 },
- { 0x5, 0x5, 219, 2218, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2219, -1, 35, 1, 31 },
- { 0x3, 0x3, 219, 2220, -1, 35, 1, 65 },
- { 0x5, 0x5, 219, 2221, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2222, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2223, -1, 35, 1, 65 },
- { 0x1, 0x1, 219, 2224, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2225, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2226, -1, 35, 1, 65 },
- { 0x1, 0x1, 219, 2227, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2228, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2229, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2230, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2231, -1, 35, 1, 51 },
- { 0x101, 0x101, 219, 2232, -1, 27, 1, 51 },
- { 0x81, 0x81, 219, 2233, -1, 28, 1, 51 },
- { 0x103, 0x103, 219, 2234, -1, 27, 1, 51 },
- { 0x41, 0x41, 219, 2235, -1, 29, 1, 51 },
- { 0x105, 0x105, 219, 2236, -1, 27, 1, 51 },
- { 0x83, 0x83, 219, 2237, -1, 28, 1, 51 },
- { 0x107, 0x107, 219, 2238, -1, 27, 1, 51 },
- { 0x1, 0x1, 219, 2239, -1, 35, 1, 51 },
- { 0x1, 0x1, 219, 2240, -1, 35, 1, 51 },
- { 0x1, 0x1, 219, 2241, -1, 35, 1, 51 },
- { 0x1, 0x1, 219, 2242, -1, 35, 1, 51 },
- { 0x81, 0x81, 219, 2243, -1, 28, 1, 31 },
- { 0x1, 0x1, 219, 2244, -1, 35, 1, 31 },
- { 0x103, 0x103, 219, 2245, -1, 27, 1, 31 },
- { 0x101, 0x101, 219, 2246, -1, 27, 1, 31 },
- { 0x1, 0x1, 219, 2247, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2248, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2249, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2250, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2251, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2252, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2253, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2254, -1, 35, 1, 26 },
- { 0x1, 0x1, 219, 2255, -1, 35, 1, 26 },
- { 0x1, 0x1, 219, 2256, -1, 35, 1, 26 },
- { 0x1, 0x1, 219, 2257, -1, 35, 1, 26 },
- { 0x1, 0x1, 219, 2258, -1, 35, 1, 37 },
- { 0x1, 0x1, 219, 2259, -1, 35, 1, 65 },
- { 0x1, 0x1, 219, 2260, -1, 35, 1, 31 },
- { 0x1, 0x1, 219, 2261, -1, 35, 1, 31 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 65 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, 1852, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 47 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 43 },
- { 0xc00001, 0xc00001, 220, -1, -1, 12, 1, 62 },
- { 0x3, 0x3, 220, 2435, -1, 34, 1, 57 },
- { 0x1c00001, 0x1c00001, 220, -1, -1, 12, 1, 62 },
- { 0x7, 0x7, 220, 2436, -1, 34, 1, 57 },
- { 0xe00001, 0xe00001, 220, -1, -1, 12, 1, 62 },
- { 0x7, 0x7, 220, 2437, -1, 33, 1, 57 },
- { 0x1e00001, 0x1e00001, 220, -1, -1, 12, 1, 52 },
- { 0xf, 0xf, 220, 2438, -1, 33, 1, 52 },
- { 0xc00001, 0xc00001, 220, -1, -1, 12, 1, 62 },
- { 0x3, 0x3, 220, 2443, -1, 34, 1, 57 },
- { 0xe00001, 0x1e00001, 220, -1, -1, 12, 1, 62 },
- { 0x7, 0xf, 220, 2444, -1, 33, 1, 57 },
- { 0xc00001, 0xc00001, 220, -1, -1, 12, 1, 62 },
- { 0x3, 0x3, 220, 2447, -1, 34, 1, 57 },
- { 0x1c00001, 0x1c00001, 220, -1, -1, 12, 1, 62 },
- { 0x7, 0x7, 220, 2448, -1, 34, 1, 57 },
- { 0xe00001, 0xe00001, 220, -1, -1, 12, 1, 62 },
- { 0x7, 0x7, 220, 2449, -1, 33, 1, 57 },
- { 0x1e00001, 0x1e00001, 220, -1, -1, 12, 1, 52 },
- { 0xf, 0xf, 220, 2450, -1, 33, 1, 52 },
- { 0xc00001, 0xc00001, 220, -1, -1, 12, 1, 62 },
- { 0x3, 0x3, 220, 2455, -1, 34, 1, 57 },
- { 0xe00001, 0x1e00001, 220, -1, -1, 12, 1, 62 },
- { 0x7, 0xf, 220, 2456, -1, 33, 1, 57 },
- { 0xc1, 0xc1, 220, -1, -1, 28, 1, 32 },
- { 0x3, 0x3, 220, 2375, -1, 34, 1, 32 },
- { 0x183, 0x183, 220, -1, -1, 27, 1, 32 },
- { 0x181, 0x181, 220, 2376, -1, 27, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 65 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, 1853, -1, 34, 1, 32 },
- { 0x7, 0x7, 220, -1, -1, 34, 1, 65 },
- { 0xb, 0xb, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, 1854, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 65 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, 1857, -1, 34, 1, 32 },
- { 0x7, 0x7, 220, -1, -1, 34, 1, 65 },
- { 0xb, 0xb, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, 1858, -1, 34, 1, 32 },
- { 0x7, 0x7, 220, -1, -1, 34, 1, 65 },
- { 0xb, 0xb, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, 1860, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 65 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, 1862, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 65 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, 1863, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 52 },
- { 0x181, 0x181, 220, -1, -1, 27, 1, 52 },
- { 0xc1, 0xc1, 220, -1, -1, 28, 1, 52 },
- { 0x183, 0x183, 220, -1, -1, 27, 1, 52 },
- { 0x61, 0x61, 220, -1, -1, 29, 1, 52 },
- { 0x185, 0x185, 220, -1, -1, 27, 1, 52 },
- { 0xc3, 0xc3, 220, -1, -1, 28, 1, 52 },
- { 0x187, 0x187, 220, -1, -1, 27, 1, 52 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 52 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 52 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 52 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 52 },
- { 0xc1, 0xc1, 220, -1, -1, 28, 1, 32 },
- { 0x3, 0x3, 220, 2379, -1, 34, 1, 32 },
- { 0x183, 0x183, 220, -1, -1, 27, 1, 32 },
- { 0x181, 0x181, 220, 2380, -1, 27, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 27 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 27 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 27 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 27 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 38 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 65 },
- { 0x3, 0x3, 220, -1, -1, 34, 1, 32 },
- { 0x3, 0x3, 220, 1865, -1, 34, 1, 32 },
- { 0x3, 0x3, 221, 395, 1197, 32, 1, 127 },
- { 0x3, 0x3, 221, 396, 1206, 32, 1, 127 },
- { 0x3, 0x3, 221, 397, 1215, 32, 1, 127 },
- { 0x3, 0x3, 221, 398, 1224, 32, 1, 127 },
- { 0x3, 0x3, 221, 399, 1233, 32, 1, 127 },
- { 0x3, 0x3, 221, 400, 1242, 32, 1, 127 },
- { 0x3, 0x3, 221, 401, 1251, 32, 1, 127 },
- { 0x3, 0x3, 221, 402, 1260, 32, 1, 127 },
- { 0x3, 0x3, 221, 403, 1269, 32, 1, 127 },
- { 0x3, 0x3, 221, 404, 1278, 32, 1, 127 },
- { 0x3, 0x3, 221, 405, 1288, 32, 1, 127 },
- { 0x3, 0x3, 221, 406, 1298, 32, 1, 127 },
- { 0x3, 0x3, 221, 419, 1311, 32, 1, 140 },
- { 0x3, 0x3, 221, 420, 1317, 32, 1, 140 },
- { 0x3, 0x3, 221, 421, 1323, 32, 1, 140 },
- { 0x3, 0x3, 221, 422, 1329, 32, 1, 140 },
- { 0x3, 0x3, 221, 423, 1335, 32, 1, 140 },
- { 0x3, 0x3, 221, 424, 1341, 32, 1, 140 },
- { 0x3, 0x3, 221, 425, 1347, 32, 1, 140 },
- { 0x3, 0x3, 221, 426, 1353, 32, 1, 140 },
- { 0x3, 0x3, 221, 427, 1359, 32, 1, 140 },
- { 0x3, 0x3, 221, 428, 1365, 32, 1, 140 },
- { 0x3, 0x3, 221, 429, 1371, 32, 1, 140 },
- { 0x3, 0x3, 221, 430, 1377, 32, 1, 140 },
- { 0x3, 0x3, 221, 431, 1383, 32, 1, 140 },
- { 0x3, 0x3, 221, 432, 1389, 32, 1, 140 },
- { 0x3, 0x3, 221, 433, 1395, 32, 1, 140 },
- { 0x3, 0x3, 221, 434, 1401, 32, 1, 140 },
- { 0x3, 0x3, 221, 435, 1407, 32, 1, 140 },
- { 0x3, 0x3, 221, 436, 1413, 32, 1, 140 },
- { 0x1, 0x1, 222, -1, -1, 28, 1, 33 },
- { 0x1, 0x1, 222, -1, -1, 28, 1, 33 },
- { 0x0, 0x0, 229, 804, -1, 0, 1, 134 },
- { 0x0, 0x0, 229, 805, -1, 0, 1, 146 },
- { 0x1, 0x1, 230, -1, 1704, 33, 1, 131 },
- { 0x1, 0x1, 230, -1, 1707, 33, 1, 136 },
- { 0x0, 0x0, 230, -1, 1709, 0, 1, 130 },
- { 0x0, 0x0, 230, -1, 1710, 0, 1, 130 },
- { 0x0, 0x0, 231, 738, 816, 0, 0, -1 },
- { 0x0, 0x0, 231, 739, 824, 0, 0, -1 },
- { 0x0, 0x0, 231, 740, 820, 0, 0, -1 },
- { 0x1, 0x1, 231, 741, 475, 33, 1, 6 },
- { 0x8000001, 0x8000001, 231, 742, 483, 6, 1, 7 },
- { 0x1, 0x1, 231, 743, 479, 33, 1, 6 },
- { 0x0, 0x0, 231, 744, 828, 0, 0, -1 },
- { 0x1, 0x1, 231, 745, 495, 33, 1, 8 },
- { 0x0, 0x0, 231, 746, 832, 0, 0, -1 },
- { 0x1, 0x1, 231, 747, 507, 33, 1, 15 },
- { 0x0, 0x0, 231, 748, 837, 0, 0, -1 },
- { 0x0, 0x0, 231, 749, 841, 0, 0, -1 },
- { 0x1, 0x1, 231, 750, 530, 33, 1, 17 },
- { 0x1, 0x1, 231, 751, 534, 33, 1, 17 },
- { 0x0, 0x0, 231, 752, 845, 0, 0, -1 },
- { 0x0, 0x0, 231, 753, 849, 0, 0, -1 },
- { 0x1, 0x1, 231, 754, 554, 33, 1, 18 },
- { 0x8000001, 0x8000001, 231, 755, 558, 6, 1, 18 },
- { 0x0, 0x0, 231, 756, 853, 0, 0, -1 },
- { 0x1, 0x1, 231, 757, 570, 33, 1, 19 },
- { 0x0, 0x0, 231, 758, 857, 0, 0, -1 },
- { 0x0, 0x0, 231, 759, 861, 0, 0, -1 },
- { 0x1, 0x1, 231, 760, 590, 33, 1, 20 },
- { 0x8000001, 0x8000001, 231, 761, 594, 6, 1, 20 },
- { 0x0, 0x0, 231, 762, 865, 0, 0, -1 },
- { 0x1, 0x1, 231, 763, 606, 33, 1, 21 },
- { 0x0, 0x0, 231, 764, 870, 0, 0, -1 },
- { 0x0, 0x0, 231, 765, 874, 0, 0, -1 },
- { 0x1, 0x1, 231, 766, 629, 33, 1, 17 },
- { 0x1, 0x1, 231, 767, 633, 33, 1, 17 },
- { 0x0, 0x0, 231, 768, 878, 0, 0, -1 },
- { 0x1, 0x1, 231, 769, 645, 33, 1, 21 },
- { 0x0, 0x0, 232, 2300, 815, 0, 0, -1 },
- { 0x0, 0x0, 232, 2301, 823, 0, 0, -1 },
- { 0x0, 0x0, 232, 2302, 819, 0, 0, -1 },
- { 0x0, 0x0, 232, 2303, 474, 0, 1, 6 },
- { 0x1, 0x1, 232, 2304, 482, 6, 1, 7 },
- { 0x0, 0x0, 232, 2305, 478, 0, 1, 6 },
- { 0x0, 0x0, 232, 2306, 827, 0, 0, -1 },
- { 0x0, 0x0, 232, 2307, 494, 0, 1, 8 },
- { 0x0, 0x0, 232, 2308, 831, 0, 0, -1 },
- { 0x0, 0x0, 232, 2309, 506, 0, 1, 15 },
- { 0x0, 0x0, 232, 2310, 836, 0, 0, -1 },
- { 0x0, 0x0, 232, 2311, 840, 0, 0, -1 },
- { 0x0, 0x0, 232, 2312, 529, 0, 1, 17 },
- { 0x0, 0x0, 232, 2313, 533, 0, 1, 17 },
- { 0x0, 0x0, 232, 2314, 844, 0, 0, -1 },
- { 0x0, 0x0, 232, 2315, 848, 0, 0, -1 },
- { 0x0, 0x0, 232, 2316, 553, 0, 1, 18 },
- { 0x1, 0x1, 232, 2317, 557, 6, 1, 18 },
- { 0x0, 0x0, 232, 2318, 852, 0, 0, -1 },
- { 0x0, 0x0, 232, 2319, 569, 0, 1, 19 },
- { 0x0, 0x0, 232, 2320, 856, 0, 0, -1 },
- { 0x0, 0x0, 232, 2321, 860, 0, 0, -1 },
- { 0x0, 0x0, 232, 2322, 589, 0, 1, 20 },
- { 0x1, 0x1, 232, 2323, 593, 6, 1, 20 },
- { 0x0, 0x0, 232, 2324, 864, 0, 0, -1 },
- { 0x0, 0x0, 232, 2325, 605, 0, 1, 21 },
- { 0x0, 0x0, 232, 2326, 869, 0, 0, -1 },
- { 0x0, 0x0, 232, 2327, 873, 0, 0, -1 },
- { 0x0, 0x0, 232, 2328, 628, 0, 1, 17 },
- { 0x0, 0x0, 232, 2329, 632, 0, 1, 17 },
- { 0x0, 0x0, 232, 2330, 877, 0, 0, -1 },
- { 0x0, 0x0, 232, 2331, 644, 0, 1, 21 },
- { 0x1, 0x1, 232, 770, 964, 27, 1, 16 },
- { 0x0, 0x0, 232, 771, 962, 0, 1, 16 },
- { 0x0, 0x0, 232, 1012, 966, 0, 1, 22 },
- { 0x0, 0x1, 232, 974, 972, 20, 1, 67 },
- { 0x0, 0x0, 232, 108, 970, 0, 1, 67 },
- { 0x1, 0x1, 235, -1, -1, 29, 1, 0 },
- { 0x0, 0x0, 235, -1, -1, 0, 1, 0 },
- { 0x1, 0x1, 235, 2472, -1, 27, 1, 0 },
- { 0x1, 0x1, 235, 2473, -1, 27, 1, 0 },
- { 0x1, 0x1, 235, 2474, -1, 27, 1, 0 },
- { 0x1, 0x1, 235, 2475, -1, 27, 1, 0 },
- { 0x0, 0x0, 256, -1, 1929, 0, 0, -1 },
- { 0x0, 0x0, 256, -1, 1931, 0, 0, -1 },
- { 0x1, 0x1, 256, -1, -1, 28, 1, 29 },
- { 0x1, 0x1, 256, -1, -1, 28, 1, 29 },
- { 0x0, 0x0, 256, -1, 1970, 0, 0, -1 },
- { 0x0, 0x0, 256, -1, 1972, 0, 0, -1 },
- { 0x1, 0x1, 256, -1, -1, 28, 1, 29 },
- { 0x1, 0x1, 256, -1, -1, 28, 1, 29 },
- { 0x0, 0x0, 258, 22, -1, 0, 1, 0 },
- { 0x0, 0x0, 258, -1, -1, 0, 1, 0 },
- { 0x0, 0x0, 258, -1, -1, 0, 1, 0 },
- { 0x0, 0x1, 258, -1, -1, 29, 1, 0 },
- { 0x0, 0x1, 258, -1, -1, 29, 1, 0 },
- { 0x0, 0x1, 258, -1, -1, 29, 1, 0 },
- { 0x0, 0x1, 258, -1, -1, 29, 1, 0 },
- { 0x0, 0x1, 258, -1, -1, 29, 1, 0 },
- { 0x0, 0x0, 258, 176, -1, 0, 1, 0 },
- { 0x0, 0x1, 258, -1, -1, 29, 1, 0 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 64 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 64 },
- { 0x0, 0x0, 259, -1, 1905, 0, 0, -1 },
- { 0x0, 0x0, 259, -1, 1907, 0, 0, -1 },
- { 0x0, 0x0, 259, -1, 1909, 0, 0, -1 },
- { 0x0, 0x0, 259, -1, 1911, 0, 0, -1 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 59 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 59 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 59 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 49 },
- { 0x0, 0x0, 259, -1, 1913, 0, 0, -1 },
- { 0x0, 0x0, 259, -1, 1915, 0, 0, -1 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 59 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 59 },
- { 0x0, 0x0, 259, -1, 1917, 0, 0, -1 },
- { 0x0, 0x0, 259, -1, 1919, 0, 0, -1 },
- { 0x0, 0x0, 259, -1, 1921, 0, 0, -1 },
- { 0x0, 0x0, 259, -1, 1923, 0, 0, -1 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 59 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 59 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 59 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 49 },
- { 0x0, 0x0, 259, -1, 1925, 0, 0, -1 },
- { 0x0, 0x0, 259, -1, 1927, 0, 0, -1 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 59 },
- { 0x1, 0x1, 259, -1, -1, 12, 1, 59 },
- { 0x1, 0x1, 259, 329, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, 387, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, 333, -1, 12, 1, 2 },
- { 0x1, 0x1, 259, 391, -1, 12, 1, 2 },
- { 0x0, 0x0, 260, -1, 1912, 0, 0, -1 },
- { 0x9, 0x9, 260, -1, 2442, 33, 1, 49 },
- { 0x0, 0x0, 260, 1162, 1961, 0, 0, -1 },
- { 0x3, 0x3, 260, 1163, -1, 27, 1, 49 },
- { 0x0, 0x0, 264, 2369, -1, 0, 1, 0 },
- { 0x3, 0x3, 265, -1, -1, 27, 1, 0 },
- { 0x3, 0x3, 265, -1, -1, 27, 1, 0 },
- { 0x3, 0x3, 265, -1, -1, 27, 1, 0 },
- { 0x3, 0x3, 265, -1, -1, 27, 1, 0 },
- { 0x1, 0x1, 266, 2468, -1, 28, 1, 0 },
- { 0x1, 0x1, 266, 2469, -1, 28, 1, 0 },
- { 0x1, 0x1, 266, 2470, -1, 28, 1, 0 },
- { 0x1, 0x1, 266, 2471, -1, 28, 1, 0 },
- { 0x1, 0x1, 267, -1, -1, 27, 1, 93 },
- { 0x1, 0x1, 267, -1, -1, 27, 1, 93 },
- { 0x0, 0x0, 267, -1, 813, 0, 0, -1 },
- { 0x0, 0x0, 268, 2481, 2346, 0, 0, -1 },
- { 0x0, 0x0, 268, 2482, 2348, 0, 0, -1 },
- { 0x0, 0x0, 269, -1, 2347, 0, 0, -1 },
- { 0x0, 0x0, 269, -1, 2349, 0, 0, -1 },
- { 0x0, 0x0, 270, -1, -1, 0, 1, 40 },
- { 0x0, 0x0, 270, -1, -1, 0, 1, 40 },
- { 0x0, 0x0, 275, -1, -1, 0, 1, 33 },
- { 0x0, 0x0, 279, -1, 1935, 0, 1, 29 },
- { 0x0, 0x0, 280, -1, -1, 0, 1, 0 },
- { 0x0, 0x0, 280, -1, -1, 0, 1, 71 },
- { 0x0, 0x0, 280, 1723, 2459, 0, 1, 1 },
- { 0x0, 0x0, 280, -1, 388, 0, 0, -1 },
- { 0x0, 0x0, 280, 1725, 2461, 0, 1, 1 },
- { 0x0, 0x0, 280, -1, 392, 0, 0, -1 },
+ { 0x1, 0x1, 24, 1125, 1214, 35, 1, 130 },
+ { 0x1, 0x1, 24, 1126, 1223, 35, 1, 130 },
+ { 0x1, 0x1, 24, 1127, 1232, 35, 1, 130 },
+ { 0x1, 0x1, 24, 1128, 1243, 35, 1, 130 },
+ { 0x1, 0x1, 24, 1129, 1252, 35, 1, 130 },
+ { 0x1, 0x1, 24, 1130, 1261, 35, 1, 130 },
+ { 0x1, 0x1, 24, 1131, 1270, 35, 1, 130 },
+ { 0x1, 0x1, 24, 1132, 1279, 35, 1, 130 },
+ { 0x1, 0x1, 24, 1133, 1288, 35, 1, 130 },
+ { 0x1, 0x1, 24, 1134, 1298, 35, 1, 130 },
+ { 0x1, 0x1, 24, 1135, 1308, 35, 1, 130 },
+ { 0x1, 0x1, 24, 1136, 1318, 35, 1, 130 },
+ { 0x1, 0x1, 24, 1137, 1327, 35, 1, 144 },
+ { 0x1, 0x1, 24, 1138, 1333, 35, 1, 144 },
+ { 0x1, 0x1, 24, 1139, 1339, 35, 1, 144 },
+ { 0x1, 0x1, 24, 1140, 1345, 35, 1, 144 },
+ { 0x1, 0x1, 24, 1141, 1351, 35, 1, 144 },
+ { 0x1, 0x1, 24, 1142, 1357, 35, 1, 144 },
+ { 0x1, 0x1, 24, 1143, 1363, 35, 1, 144 },
+ { 0x1, 0x1, 24, 1144, 1369, 35, 1, 144 },
+ { 0x1, 0x1, 24, 1145, 1375, 35, 1, 144 },
+ { 0x1, 0x1, 24, 1146, 1381, 35, 1, 144 },
+ { 0x1, 0x1, 24, 1147, 1387, 35, 1, 144 },
+ { 0x1, 0x1, 24, 1148, 1393, 35, 1, 144 },
+ { 0x1, 0x1, 24, 1149, 1399, 35, 1, 144 },
+ { 0x1, 0x1, 24, 1150, 1405, 35, 1, 144 },
+ { 0x1, 0x1, 24, 1151, 1411, 35, 1, 144 },
+ { 0x1, 0x1, 24, 1152, 1417, 35, 1, 144 },
+ { 0x1, 0x1, 24, 1153, 1423, 35, 1, 144 },
+ { 0x1, 0x1, 24, 1154, 1429, 35, 1, 144 },
+ { 0x0, 0x0, 33, 2357, 2355, 0, 0, -1 },
+ { 0x0, 0x0, 33, 2360, 2358, 0, 0, -1 },
+ { 0x0, 0x0, 33, 2366, 2365, 0, 0, -1 },
+ { 0x0, 0x0, 33, 2368, 2367, 0, 0, -1 },
+ { 0x0, 0x0, 33, 2382, 2381, 0, 0, -1 },
+ { 0x0, 0x0, 33, 2384, 2383, 0, 0, -1 },
+ { 0x0, 0x0, 35, -1, 2376, 0, 0, -1 },
+ { 0x0, 0x0, 35, -1, 2378, 0, 0, -1 },
+ { 0x1, 0x1, 38, -1, 1922, 37, 1, 29 },
+ { 0x1, 0x1, 38, -1, 1957, 37, 1, 29 },
+ { 0x0, 0x0, 38, -1, 1960, 0, 0, -1 },
+ { 0x1, 0x1, 38, -1, -1, 37, 1, 29 },
+ { 0x1, 0x1, 38, -1, 1965, 37, 1, 29 },
+ { 0x0, 0x0, 38, -1, 1968, 0, 0, -1 },
+ { 0x1, 0x1, 38, -1, -1, 37, 1, 29 },
+ { 0x0, 0x0, 38, -1, 1971, 0, 0, -1 },
+ { 0x1, 0x1, 38, -1, -1, 37, 1, 29 },
+ { 0x1, 0x1, 38, -1, 1974, 37, 1, 29 },
+ { 0x1, 0x1, 38, -1, 1977, 37, 1, 29 },
+ { 0x1, 0x1, 38, -1, 2010, 37, 1, 29 },
+ { 0x3, 0x3, 38, -1, -1, 30, 1, 137 },
+ { 0x0, 0x0, 38, 960, -1, 0, 1, 95 },
+ { 0x0, 0x0, 38, -1, -1, 0, 1, 104 },
+ { 0x0, 0x0, 38, 966, -1, 0, 1, 116 },
+ { 0x3, 0x3, 38, -1, -1, 30, 1, 150 },
+ { 0x0, 0x0, 38, 967, -1, 0, 1, 40 },
+ { 0x0, 0x0, 40, -1, 825, 0, 0, -1 },
+ { 0x0, 0x0, 40, -1, 833, 0, 0, -1 },
+ { 0x0, 0x0, 40, 969, 829, 0, 0, -1 },
+ { 0x3, 0x3, 40, -1, 483, 33, 1, 6 },
+ { 0x18000001, 0x18000001, 40, -1, 491, 6, 1, 7 },
+ { 0x3, 0x3, 40, 970, 487, 33, 1, 6 },
+ { 0x0, 0x0, 40, -1, 837, 0, 0, -1 },
+ { 0x3, 0x3, 40, -1, 503, 33, 1, 8 },
+ { 0x0, 0x0, 40, -1, 841, 0, 0, -1 },
+ { 0x3, 0x3, 40, -1, 515, 33, 1, 15 },
+ { 0x0, 0x0, 40, -1, 846, 0, 0, -1 },
+ { 0x0, 0x0, 40, -1, 850, 0, 0, -1 },
+ { 0x3, 0x3, 40, -1, 538, 33, 1, 17 },
+ { 0x3, 0x3, 40, -1, 542, 33, 1, 17 },
+ { 0x0, 0x0, 40, -1, 854, 0, 0, -1 },
+ { 0x0, 0x0, 40, -1, 858, 0, 0, -1 },
+ { 0x3, 0x3, 40, -1, 562, 33, 1, 18 },
+ { 0x18000001, 0x18000001, 40, -1, 566, 6, 1, 18 },
+ { 0x0, 0x0, 40, -1, 862, 0, 0, -1 },
+ { 0x3, 0x3, 40, -1, 578, 33, 1, 19 },
+ { 0x0, 0x0, 40, -1, 866, 0, 0, -1 },
+ { 0x0, 0x0, 40, -1, 870, 0, 0, -1 },
+ { 0x3, 0x3, 40, -1, 598, 33, 1, 20 },
+ { 0x18000001, 0x18000001, 40, -1, 602, 6, 1, 20 },
+ { 0x0, 0x0, 40, -1, 874, 0, 0, -1 },
+ { 0x3, 0x3, 40, -1, 614, 33, 1, 21 },
+ { 0x0, 0x0, 40, -1, 879, 0, 0, -1 },
+ { 0x0, 0x0, 40, -1, 883, 0, 0, -1 },
+ { 0x3, 0x3, 40, -1, 637, 33, 1, 17 },
+ { 0x3, 0x3, 40, -1, 641, 33, 1, 17 },
+ { 0x0, 0x0, 40, -1, 887, 0, 0, -1 },
+ { 0x3, 0x3, 40, -1, 653, 33, 1, 21 },
+ { 0x0, 0x0, 41, 712, 824, 0, 0, -1 },
+ { 0x0, 0x0, 41, 713, 832, 0, 0, -1 },
+ { 0x0, 0x0, 41, 714, 828, 0, 0, -1 },
+ { 0x1, 0x1, 41, 715, 482, 34, 1, 6 },
+ { 0x10000001, 0x10000001, 41, 716, 490, 6, 1, 7 },
+ { 0x1, 0x1, 41, 717, 486, 34, 1, 6 },
+ { 0x0, 0x0, 41, 718, 836, 0, 0, -1 },
+ { 0x1, 0x1, 41, 719, 502, 34, 1, 8 },
+ { 0x0, 0x0, 41, 720, 840, 0, 0, -1 },
+ { 0x1, 0x1, 41, 721, 514, 34, 1, 15 },
+ { 0x0, 0x0, 41, 722, 845, 0, 0, -1 },
+ { 0x0, 0x0, 41, 723, 849, 0, 0, -1 },
+ { 0x1, 0x1, 41, 724, 537, 34, 1, 17 },
+ { 0x1, 0x1, 41, 725, 541, 34, 1, 17 },
+ { 0x0, 0x0, 41, 726, 853, 0, 0, -1 },
+ { 0x0, 0x0, 41, 727, 857, 0, 0, -1 },
+ { 0x1, 0x1, 41, 728, 561, 34, 1, 18 },
+ { 0x10000001, 0x10000001, 41, 729, 565, 6, 1, 18 },
+ { 0x0, 0x0, 41, 730, 861, 0, 0, -1 },
+ { 0x1, 0x1, 41, 731, 577, 34, 1, 19 },
+ { 0x0, 0x0, 41, 732, 865, 0, 0, -1 },
+ { 0x0, 0x0, 41, 733, 869, 0, 0, -1 },
+ { 0x1, 0x1, 41, 734, 597, 34, 1, 20 },
+ { 0x10000001, 0x10000001, 41, 735, 601, 6, 1, 20 },
+ { 0x0, 0x0, 41, 736, 873, 0, 0, -1 },
+ { 0x1, 0x1, 41, 737, 613, 34, 1, 21 },
+ { 0x0, 0x0, 41, 738, 878, 0, 0, -1 },
+ { 0x0, 0x0, 41, 739, 882, 0, 0, -1 },
+ { 0x1, 0x1, 41, 740, 636, 34, 1, 17 },
+ { 0x1, 0x1, 41, 741, 640, 34, 1, 17 },
+ { 0x0, 0x0, 41, 742, 886, 0, 0, -1 },
+ { 0x1, 0x1, 41, 743, 652, 34, 1, 21 },
+ { 0x800001, 0x800001, 41, -1, 974, 4, 1, 16 },
+ { 0x1, 0x1, 41, 1868, 972, 4, 1, 16 },
+ { 0x1, 0x1, 41, 809, 977, 4, 1, 22 },
+ { 0x2, 0x3, 41, -1, 982, 20, 1, 67 },
+ { 0x1, 0x1, 41, 1869, 980, 21, 1, 67 },
+ { 0x0, 0x0, 42, -1, -1, 0, 1, 80 },
+ { 0x0, 0x0, 42, -1, -1, 0, 1, 80 },
+ { 0x0, 0x0, 42, -1, -1, 0, 1, 123 },
+ { 0x1, 0x1, 44, 1155, 286, 38, 1, 1 },
+ { 0x0, 0x0, 44, -1, 345, 0, 0, -1 },
+ { 0x1, 0x1, 44, 1158, 296, 38, 1, 1 },
+ { 0x0, 0x0, 44, -1, 365, 0, 0, -1 },
+ { 0x0, 0x0, 44, -1, 299, 0, 0, -1 },
+ { 0x0, 0x0, 44, -1, 309, 0, 0, -1 },
+ { 0x1, 0x1, 44, 1163, 310, 38, 1, 1 },
+ { 0x0, 0x0, 44, -1, 369, 0, 0, -1 },
+ { 0x1, 0x1, 44, 1166, 320, 38, 1, 1 },
+ { 0x0, 0x0, 44, -1, 389, 0, 0, -1 },
+ { 0x0, 0x0, 44, -1, 323, 0, 0, -1 },
+ { 0x0, 0x0, 44, -1, 333, 0, 0, -1 },
+ { 0x0, 0x0, 44, 1037, 1929, 0, 0, -1 },
+ { 0x0, 0x0, 44, 1038, 2462, 0, 1, 54 },
+ { 0x0, 0x0, 44, 1039, 1981, 0, 0, -1 },
+ { 0x0, 0x0, 44, 1040, -1, 0, 1, 49 },
+ { 0x0, 0x0, 44, 942, -1, 0, 1, 0 },
+ { 0x0, 0x0, 44, 943, -1, 0, 1, 0 },
+ { 0x0, 0x0, 44, 944, -1, 0, 1, 0 },
+ { 0x1, 0x1, 45, -1, 1433, 30, 1, 147 },
+ { 0x1, 0x1, 45, 815, 1432, 30, 1, 146 },
+ { 0x1, 0x1, 45, -1, 1437, 30, 1, 149 },
+ { 0x1, 0x1, 45, 816, 1436, 30, 1, 148 },
+ { 0x1, 0x1, 45, -1, 1441, 30, 1, 149 },
+ { 0x1, 0x1, 45, 817, 1440, 30, 1, 148 },
+ { 0x3, 0x3, 46, -1, 978, 3, 1, 22 },
+ { 0x1, 0x1, 47, 1889, -1, 30, 1, 137 },
+ { 0x1, 0x1, 47, 1920, -1, 30, 1, 150 },
+ { 0x0, 0x0, 49, -1, -1, 0, 1, 40 },
+ { 0x0, 0x0, 49, -1, -1, 0, 1, 40 },
+ { 0x0, 0x0, 49, -1, -1, 0, 1, 40 },
+ { 0x1, 0x1, 56, -1, 1434, 31, 1, 147 },
+ { 0x1, 0x1, 56, -1, 1438, 31, 1, 149 },
+ { 0x1, 0x1, 56, -1, 1442, 31, 1, 149 },
+ { 0x0, 0x0, 56, -1, -1, 0, 1, 94 },
+ { 0x2, 0x3, 56, -1, -1, 27, 1, 94 },
+ { 0x1, 0x1, 56, -1, -1, 28, 1, 94 },
+ { 0x0, 0x0, 65, 13, 453, 0, 1, 6 },
+ { 0x0, 0x0, 65, 1056, 456, 0, 1, 6 },
+ { 0x1, 0x1, 65, 1057, 458, 33, 1, 6 },
+ { 0x1, 0x1, 65, 1058, 460, 34, 1, 6 },
+ { 0x3, 0x3, 65, 1059, 462, 33, 1, 6 },
+ { 0x0, 0x0, 65, 1060, 464, 0, 1, 6 },
+ { 0x1, 0x1, 65, 1061, 466, 33, 1, 6 },
+ { 0x1, 0x1, 65, 1062, 468, 34, 1, 6 },
+ { 0x3, 0x3, 65, 1063, 470, 33, 1, 6 },
+ { 0x1, 0x1, 65, 1064, 472, 6, 1, 7 },
+ { 0x8000001, 0x8000001, 65, 1065, 474, 6, 1, 7 },
+ { 0x10000001, 0x10000001, 65, 1066, 476, 6, 1, 7 },
+ { 0x18000001, 0x18000001, 65, 1067, 478, 6, 1, 7 },
+ { 0x0, 0x0, 65, 1068, 492, 0, 1, 8 },
+ { 0x1, 0x1, 65, 1069, 494, 33, 1, 8 },
+ { 0x1, 0x1, 65, 1070, 496, 34, 1, 8 },
+ { 0x3, 0x3, 65, 1071, 498, 33, 1, 8 },
+ { 0x0, 0x0, 65, 1072, 504, 0, 1, 15 },
+ { 0x1, 0x1, 65, 1073, 506, 33, 1, 15 },
+ { 0x1, 0x1, 65, 1074, 508, 34, 1, 15 },
+ { 0x3, 0x3, 65, 1075, 510, 33, 1, 15 },
+ { 0x0, 0x0, 65, 14, 516, 0, 1, 17 },
+ { 0x0, 0x0, 65, 1077, 519, 0, 1, 17 },
+ { 0x1, 0x1, 65, 1078, 521, 33, 1, 17 },
+ { 0x1, 0x1, 65, 1079, 523, 34, 1, 17 },
+ { 0x3, 0x3, 65, 1080, 525, 33, 1, 17 },
+ { 0x0, 0x0, 65, 1081, 527, 0, 1, 17 },
+ { 0x1, 0x1, 65, 1082, 529, 33, 1, 17 },
+ { 0x1, 0x1, 65, 1083, 531, 34, 1, 17 },
+ { 0x3, 0x3, 65, 1084, 533, 33, 1, 17 },
+ { 0x0, 0x0, 65, 1085, 543, 0, 1, 18 },
+ { 0x1, 0x1, 65, 1086, 545, 33, 1, 18 },
+ { 0x1, 0x1, 65, 1087, 547, 34, 1, 18 },
+ { 0x3, 0x3, 65, 1088, 549, 33, 1, 18 },
+ { 0x1, 0x1, 65, 1089, 551, 6, 1, 18 },
+ { 0x8000001, 0x8000001, 65, 1090, 553, 6, 1, 18 },
+ { 0x10000001, 0x10000001, 65, 1091, 555, 6, 1, 18 },
+ { 0x18000001, 0x18000001, 65, 1092, 557, 6, 1, 18 },
+ { 0x0, 0x0, 65, 1093, 567, 0, 1, 19 },
+ { 0x1, 0x1, 65, 1094, 569, 33, 1, 19 },
+ { 0x1, 0x1, 65, 1095, 571, 34, 1, 19 },
+ { 0x3, 0x3, 65, 1096, 573, 33, 1, 19 },
+ { 0x0, 0x0, 65, 1097, 579, 0, 1, 20 },
+ { 0x1, 0x1, 65, 1098, 581, 33, 1, 20 },
+ { 0x1, 0x1, 65, 1099, 583, 34, 1, 20 },
+ { 0x3, 0x3, 65, 1100, 585, 33, 1, 20 },
+ { 0x1, 0x1, 65, 1101, 587, 6, 1, 20 },
+ { 0x8000001, 0x8000001, 65, 1102, 589, 6, 1, 20 },
+ { 0x10000001, 0x10000001, 65, 1103, 591, 6, 1, 20 },
+ { 0x18000001, 0x18000001, 65, 1104, 593, 6, 1, 20 },
+ { 0x0, 0x0, 65, 1105, 603, 0, 1, 21 },
+ { 0x1, 0x1, 65, 1106, 605, 33, 1, 21 },
+ { 0x1, 0x1, 65, 1107, 607, 34, 1, 21 },
+ { 0x3, 0x3, 65, 1108, 609, 33, 1, 21 },
+ { 0x0, 0x0, 65, 16, 615, 0, 1, 17 },
+ { 0x0, 0x0, 65, 1110, 618, 0, 1, 17 },
+ { 0x1, 0x1, 65, 1111, 620, 33, 1, 17 },
+ { 0x1, 0x1, 65, 1112, 622, 34, 1, 17 },
+ { 0x3, 0x3, 65, 1113, 624, 33, 1, 17 },
+ { 0x0, 0x0, 65, 1114, 626, 0, 1, 17 },
+ { 0x1, 0x1, 65, 1115, 628, 33, 1, 17 },
+ { 0x1, 0x1, 65, 1116, 630, 34, 1, 17 },
+ { 0x3, 0x3, 65, 1117, 632, 33, 1, 17 },
+ { 0x0, 0x0, 65, 1118, 642, 0, 1, 21 },
+ { 0x1, 0x1, 65, 1119, 644, 33, 1, 21 },
+ { 0x1, 0x1, 65, 1120, 646, 34, 1, 21 },
+ { 0x3, 0x3, 65, 1121, 648, 33, 1, 21 },
+ { 0x3, 0x3, 66, 422, 1296, 33, 1, 129 },
+ { 0x3, 0x3, 66, 423, 1306, 33, 1, 129 },
+ { 0x3, 0x3, 66, 424, 1316, 33, 1, 129 },
+ { 0x0, 0x0, 66, -1, 1321, 0, 1, 140 },
+ { 0x0, 0x0, 66, -1, 1322, 0, 1, 140 },
+ { 0x0, 0x0, 66, -1, 1323, 0, 1, 140 },
+ { 0x0, 0x0, 107, 898, 1953, 0, 0, -1 },
+ { 0x0, 0x0, 107, 899, 2400, 0, 1, 29 },
+ { 0x0, 0x0, 107, 900, 1994, 0, 0, -1 },
+ { 0x0, 0x0, 107, 901, 2404, 0, 1, 29 },
+ { 0x0, 0x0, 109, -1, 1955, 0, 0, -1 },
+ { 0x1, 0x1, 109, -1, 2401, 27, 1, 29 },
+ { 0x0, 0x0, 109, -1, 1996, 0, 0, -1 },
+ { 0x1, 0x1, 109, -1, 2405, 27, 1, 29 },
+ { 0x0, 0x0, 110, 903, -1, 0, 1, 115 },
+ { 0x1, 0x1, 111, -1, -1, 27, 1, 115 },
+ { 0x0, 0x0, 112, 921, 2423, 0, 1, 1 },
+ { 0x0, 0x0, 112, 1024, 290, 0, 0, -1 },
+ { 0x0, 0x0, 112, 1001, 353, 0, 0, -1 },
+ { 0x0, 0x0, 112, -1, 361, 0, 0, -1 },
+ { 0x0, 0x0, 112, 922, 2431, 0, 1, 1 },
+ { 0x0, 0x0, 112, -1, 303, 0, 0, -1 },
+ { 0x0, 0x0, 112, 1029, 304, 0, 0, -1 },
+ { 0x0, 0x0, 112, 923, 2443, 0, 1, 1 },
+ { 0x0, 0x0, 112, 1031, 314, 0, 0, -1 },
+ { 0x0, 0x0, 112, 1008, 377, 0, 0, -1 },
+ { 0x0, 0x0, 112, -1, 385, 0, 0, -1 },
+ { 0x0, 0x0, 112, 1167, 2450, 0, 1, 1 },
+ { 0x0, 0x0, 112, -1, 327, 0, 0, -1 },
+ { 0x0, 0x0, 112, 1036, 328, 0, 0, -1 },
+ { 0x0, 0x0, 112, -1, 1939, 0, 0, -1 },
+ { 0x1, 0x9, 112, -1, 2469, 33, 1, 54 },
+ { 0x2, 0x3, 112, 1180, 1990, 27, 1, 49 },
+ { 0x1, 0x1, 114, 1156, 2424, 37, 1, 1 },
+ { 0x1, 0x1, 114, 1159, 2432, 37, 1, 1 },
+ { 0x1, 0x1, 114, 1164, 2444, 37, 1, 1 },
+ { 0x0, 0x0, 114, -1, 2455, 0, 1, 1 },
+ { 0x0, 0x0, 115, 945, 2421, 0, 1, 1 },
+ { 0x0, 0x0, 115, 1000, 288, 0, 0, -1 },
+ { 0x0, 0x0, 115, -1, 357, 0, 0, -1 },
+ { 0x0, 0x0, 115, 1026, 359, 0, 0, -1 },
+ { 0x0, 0x0, 115, -1, 2430, 0, 1, 1 },
+ { 0x0, 0x0, 115, 1028, 301, 0, 0, -1 },
+ { 0x0, 0x0, 115, 1005, 306, 0, 0, -1 },
+ { 0x0, 0x0, 115, 947, 2441, 0, 1, 1 },
+ { 0x0, 0x0, 115, 1007, 312, 0, 0, -1 },
+ { 0x0, 0x0, 115, -1, 381, 0, 0, -1 },
+ { 0x0, 0x0, 115, 1033, 383, 0, 0, -1 },
+ { 0x0, 0x0, 115, -1, 2449, 0, 1, 1 },
+ { 0x0, 0x0, 115, 1035, 325, 0, 0, -1 },
+ { 0x0, 0x0, 115, 1012, 330, 0, 0, -1 },
+ { 0x0, 0x0, 115, 918, 1937, 0, 0, -1 },
+ { 0x0, 0x0, 115, 919, 2468, 0, 1, 54 },
+ { 0x0, 0x0, 115, 920, 1989, 0, 1, 49 },
+ { 0x1, 0x1, 115, -1, -1, 27, 1, 0 },
+ { 0x1, 0x1, 115, -1, -1, 27, 1, 0 },
+ { 0x1, 0x1, 115, -1, -1, 27, 1, 0 },
+ { 0x1, 0x1, 116, -1, 2422, 37, 1, 1 },
+ { 0x0, 0x0, 116, -1, 2435, 0, 1, 1 },
+ { 0x1, 0x1, 116, -1, 2442, 37, 1, 1 },
+ { 0x0, 0x0, 116, -1, 2454, 0, 1, 1 },
+ { 0x0, 0x0, 117, 994, -1, 0, 1, 0 },
+ { 0x0, 0x0, 117, 995, -1, 0, 1, 0 },
+ { 0x0, 0x0, 117, 996, -1, 0, 1, 0 },
+ { 0x3, 0x3, 117, 954, -1, 34, 1, 33 },
+ { 0x3, 0x3, 117, 955, -1, 34, 1, 40 },
+ { 0x1, 0x1, 119, -1, -1, 35, 1, 33 },
+ { 0x1, 0x1, 119, -1, -1, 35, 1, 40 },
+ { 0x0, 0x0, 120, -1, -1, 0, 1, 40 },
+ { 0x0, 0x0, 120, -1, -1, 0, 1, 66 },
+ { 0x1, 0x1, 120, -1, -1, 36, 1, 122 },
+ { 0x0, 0x0, 120, -1, -1, 0, 1, 40 },
+ { 0x1, 0x1, 120, -1, -1, 27, 1, 96 },
+ { 0x0, 0x0, 120, -1, -1, 0, 1, 105 },
+ { 0x0, 0x0, 120, -1, -1, 0, 1, 73 },
+ { 0x0, 0x0, 120, -1, -1, 0, 1, 73 },
+ { 0x0, 0x0, 120, -1, -1, 0, 1, 74 },
+ { 0x0, 0x0, 120, -1, -1, 0, 1, 40 },
+ { 0x1, 0x1, 120, -1, -1, 27, 1, 117 },
+ { 0x1, 0x1, 120, -1, -1, 27, 1, 40 },
+ { 0x0, 0x0, 120, -1, -1, 0, 1, 40 },
+ { 0x0, 0x0, 121, -1, 2356, 0, 0, -1 },
+ { 0x0, 0x0, 121, -1, 2359, 0, 0, -1 },
+ { 0x1, 0x1, 122, -1, -1, 35, 1, 16 },
+ { 0x1, 0x1, 122, -1, -1, 35, 1, 16 },
+ { 0x1, 0x1, 122, -1, -1, 35, 1, 16 },
+ { 0x1, 0x1, 122, -1, -1, 35, 1, 16 },
+ { 0x1, 0x1, 122, -1, -1, 35, 1, 22 },
+ { 0x1, 0x1, 122, -1, -1, 35, 1, 22 },
+ { 0x1, 0x1, 122, -1, -1, 35, 1, 22 },
+ { 0x1, 0x1, 122, -1, -1, 35, 1, 22 },
+ { 0x1, 0x1, 122, -1, -1, 23, 1, 67 },
+ { 0x1, 0x1, 122, -1, -1, 23, 1, 67 },
+ { 0x1, 0x1, 122, -1, -1, 23, 1, 67 },
+ { 0x1, 0x1, 122, -1, -1, 23, 1, 67 },
+ { 0x1, 0x1, 122, 779, -1, 23, 1, 67 },
+ { 0x9, 0x9, 122, 780, -1, 20, 1, 67 },
+ { 0x0, 0x0, 126, 1837, -1, 0, 1, 0 },
+ { 0x0, 0x0, 126, 1838, -1, 0, 1, 0 },
+ { 0x1, 0x1, 126, -1, -1, 28, 1, 33 },
+ { 0x1, 0x1, 126, -1, -1, 27, 1, 33 },
+ { 0x1, 0x1, 126, -1, -1, 29, 1, 0 },
+ { 0x1, 0x1, 126, -1, -1, 29, 1, 0 },
+ { 0x1, 0x1, 126, -1, -1, 29, 1, 0 },
+ { 0x1, 0x1, 126, -1, -1, 29, 1, 0 },
+ { 0x0, 0x0, 126, -1, -1, 0, 1, 114 },
+ { 0x1, 0x1, 126, -1, -1, 29, 1, 0 },
+ { 0x1, 0x1, 126, -1, -1, 29, 1, 0 },
+ { 0x1, 0x1, 126, -1, -1, 29, 1, 0 },
+ { 0x0, 0x0, 126, 952, -1, 0, 1, 33 },
+ { 0x0, 0x0, 126, 1046, -1, 0, 1, 40 },
+ { 0x0, 0x0, 140, 1017, 2419, 0, 1, 1 },
+ { 0x0, 0x0, 140, 905, 289, 0, 0, -1 },
+ { 0x0, 0x0, 140, 927, 294, 0, 0, -1 },
+ { 0x0, 0x0, 140, 928, 358, 0, 0, -1 },
+ { 0x0, 0x0, 140, -1, 2429, 0, 1, 1 },
+ { 0x0, 0x0, 140, 930, 300, 0, 0, -1 },
+ { 0x0, 0x0, 140, -1, 307, 0, 0, -1 },
+ { 0x0, 0x0, 140, 1019, 2439, 0, 1, 1 },
+ { 0x0, 0x0, 140, 912, 313, 0, 0, -1 },
+ { 0x0, 0x0, 140, 934, 318, 0, 0, -1 },
+ { 0x0, 0x0, 140, 935, 382, 0, 0, -1 },
+ { 0x0, 0x0, 140, -1, 2448, 0, 1, 1 },
+ { 0x0, 0x0, 140, 937, 324, 0, 0, -1 },
+ { 0x0, 0x0, 140, -1, 331, 0, 0, -1 },
+ { 0x0, 0x0, 140, 2486, 1933, 0, 0, -1 },
+ { 0x1, 0x1, 140, 2487, 2464, 33, 1, 54 },
+ { 0x0, 0x0, 140, 2488, 1983, 0, 0, -1 },
+ { 0x1, 0x1, 140, 2489, -1, 28, 1, 49 },
+ { 0x1, 0x1, 141, -1, 2420, 37, 1, 1 },
+ { 0x0, 0x0, 141, -1, 2434, 0, 1, 1 },
+ { 0x1, 0x1, 141, -1, 2440, 37, 1, 1 },
+ { 0x0, 0x0, 141, -1, 2453, 0, 1, 1 },
+ { 0x1, 0x1, 144, 778, 976, 3, 1, 22 },
+ { 0x0, 0x0, 145, 1839, -1, 0, 1, 33 },
+ { 0x0, 0x0, 146, 784, 2416, 0, 1, 1 },
+ { 0x0, 0x0, 146, -1, 291, 0, 0, -1 },
+ { 0x0, 0x0, 146, 906, 292, 0, 0, -1 },
+ { 0x0, 0x0, 146, 907, 360, 0, 0, -1 },
+ { 0x0, 0x0, 146, 786, 2426, 0, 1, 1 },
+ { 0x0, 0x0, 146, 909, 302, 0, 0, -1 },
+ { 0x0, 0x0, 146, 931, 305, 0, 0, -1 },
+ { 0x0, 0x0, 146, 790, 2436, 0, 1, 1 },
+ { 0x0, 0x0, 146, -1, 315, 0, 0, -1 },
+ { 0x0, 0x0, 146, 913, 316, 0, 0, -1 },
+ { 0x0, 0x0, 146, 914, 384, 0, 0, -1 },
+ { 0x0, 0x0, 146, 792, 2446, 0, 1, 1 },
+ { 0x0, 0x0, 146, 916, 326, 0, 0, -1 },
+ { 0x0, 0x0, 146, 938, 329, 0, 0, -1 },
+ { 0x0, 0x0, 146, 1013, 1931, 0, 0, -1 },
+ { 0x1, 0x1, 146, 1014, 2463, 36, 1, 54 },
+ { 0x0, 0x0, 146, 1015, 1982, 0, 0, -1 },
+ { 0x1, 0x1, 146, 1016, -1, 27, 1, 49 },
+ { 0x1, 0x1, 147, -1, 2418, 37, 1, 1 },
+ { 0x1, 0x1, 147, -1, 2428, 37, 1, 1 },
+ { 0x1, 0x1, 147, -1, 2438, 37, 1, 1 },
+ { 0x0, 0x0, 147, -1, 2452, 0, 1, 1 },
+ { 0x0, 0x0, 148, -1, -1, 0, 1, 33 },
+ { 0x0, 0x0, 148, 953, -1, 0, 1, 40 },
+ { 0x0, 0x0, 149, -1, -1, 0, 1, 40 },
+ { 0x0, 0x0, 149, -1, -1, 0, 1, 66 },
+ { 0x0, 0x0, 149, -1, 2456, 0, 1, 63 },
+ { 0x0, 0x0, 149, -1, -1, 0, 1, 40 },
+ { 0x0, 0x0, 149, -1, -1, 0, 1, 81 },
+ { 0x0, 0x0, 149, -1, -1, 0, 1, 81 },
+ { 0x0, 0x0, 149, -1, -1, 0, 1, 85 },
+ { 0x0, 0x0, 149, -1, -1, 0, 1, 40 },
+ { 0x1, 0x1, 150, -1, 454, 12, 1, 6 },
+ { 0x1, 0x1, 150, -1, 457, 12, 1, 6 },
+ { 0x200001, 0x200001, 150, -1, 459, 12, 1, 6 },
+ { 0x400001, 0x400001, 150, -1, 461, 12, 1, 6 },
+ { 0x600001, 0x600001, 150, -1, 463, 12, 1, 6 },
+ { 0x1, 0x1, 150, -1, 465, 12, 1, 6 },
+ { 0x200001, 0x200001, 150, -1, 467, 12, 1, 6 },
+ { 0x400001, 0x400001, 150, -1, 469, 12, 1, 6 },
+ { 0x600001, 0x600001, 150, -1, 471, 12, 1, 6 },
+ { 0x41, 0x41, 150, -1, 473, 6, 1, 7 },
+ { 0x8000041, 0x8000041, 150, -1, 475, 6, 1, 7 },
+ { 0x10000041, 0x10000041, 150, -1, 477, 6, 1, 7 },
+ { 0x18000041, 0x18000041, 150, -1, 479, 6, 1, 7 },
+ { 0x1, 0x1, 150, -1, 493, 12, 1, 8 },
+ { 0x200001, 0x200001, 150, -1, 495, 12, 1, 8 },
+ { 0x400001, 0x400001, 150, -1, 497, 12, 1, 8 },
+ { 0x600001, 0x600001, 150, -1, 499, 12, 1, 8 },
+ { 0x1, 0x1, 150, -1, 505, 12, 1, 15 },
+ { 0x200001, 0x200001, 150, -1, 507, 12, 1, 15 },
+ { 0x400001, 0x400001, 150, -1, 509, 12, 1, 15 },
+ { 0x600001, 0x600001, 150, -1, 511, 12, 1, 15 },
+ { 0x1, 0x1, 150, -1, 517, 12, 1, 17 },
+ { 0x1, 0x1, 150, -1, 520, 12, 1, 17 },
+ { 0x200001, 0x200001, 150, -1, 522, 12, 1, 17 },
+ { 0x400001, 0x400001, 150, -1, 524, 12, 1, 17 },
+ { 0x600001, 0x600001, 150, -1, 526, 12, 1, 17 },
+ { 0x1, 0x1, 150, -1, 528, 12, 1, 17 },
+ { 0x200001, 0x200001, 150, -1, 530, 12, 1, 17 },
+ { 0x400001, 0x400001, 150, -1, 532, 12, 1, 17 },
+ { 0x600001, 0x600001, 150, -1, 534, 12, 1, 17 },
+ { 0x1, 0x1, 150, -1, 544, 12, 1, 18 },
+ { 0x200001, 0x200001, 150, -1, 546, 12, 1, 18 },
+ { 0x400001, 0x400001, 150, -1, 548, 12, 1, 18 },
+ { 0x600001, 0x600001, 150, -1, 550, 12, 1, 18 },
+ { 0x41, 0x41, 150, -1, 552, 6, 1, 18 },
+ { 0x8000041, 0x8000041, 150, -1, 554, 6, 1, 18 },
+ { 0x10000041, 0x10000041, 150, -1, 556, 6, 1, 18 },
+ { 0x18000041, 0x18000041, 150, -1, 558, 6, 1, 18 },
+ { 0x1, 0x1, 150, -1, 568, 12, 1, 19 },
+ { 0x200001, 0x200001, 150, -1, 570, 12, 1, 19 },
+ { 0x400001, 0x400001, 150, -1, 572, 12, 1, 19 },
+ { 0x600001, 0x600001, 150, -1, 574, 12, 1, 19 },
+ { 0x1, 0x1, 150, -1, 580, 12, 1, 20 },
+ { 0x200001, 0x200001, 150, -1, 582, 12, 1, 20 },
+ { 0x400001, 0x400001, 150, -1, 584, 12, 1, 20 },
+ { 0x600001, 0x600001, 150, -1, 586, 12, 1, 20 },
+ { 0x41, 0x41, 150, -1, 588, 6, 1, 20 },
+ { 0x8000041, 0x8000041, 150, -1, 590, 6, 1, 20 },
+ { 0x10000041, 0x10000041, 150, -1, 592, 6, 1, 20 },
+ { 0x18000041, 0x18000041, 150, -1, 594, 6, 1, 20 },
+ { 0x1, 0x1, 150, -1, 604, 12, 1, 21 },
+ { 0x200001, 0x200001, 150, -1, 606, 12, 1, 21 },
+ { 0x400001, 0x400001, 150, -1, 608, 12, 1, 21 },
+ { 0x600001, 0x600001, 150, -1, 610, 12, 1, 21 },
+ { 0x1, 0x1, 150, -1, 616, 12, 1, 17 },
+ { 0x1, 0x1, 150, -1, 619, 12, 1, 17 },
+ { 0x200001, 0x200001, 150, -1, 621, 12, 1, 17 },
+ { 0x400001, 0x400001, 150, -1, 623, 12, 1, 17 },
+ { 0x600001, 0x600001, 150, -1, 625, 12, 1, 17 },
+ { 0x1, 0x1, 150, -1, 627, 12, 1, 17 },
+ { 0x200001, 0x200001, 150, -1, 629, 12, 1, 17 },
+ { 0x400001, 0x400001, 150, -1, 631, 12, 1, 17 },
+ { 0x600001, 0x600001, 150, -1, 633, 12, 1, 17 },
+ { 0x1, 0x1, 150, -1, 643, 12, 1, 21 },
+ { 0x200001, 0x200001, 150, -1, 645, 12, 1, 21 },
+ { 0x400001, 0x400001, 150, -1, 647, 12, 1, 21 },
+ { 0x600001, 0x600001, 150, -1, 649, 12, 1, 21 },
+ { 0x0, 0x0, 155, -1, -1, 0, 1, 124 },
+ { 0x0, 0x0, 159, 654, -1, 0, 1, 75 },
+ { 0x0, 0x0, 159, 655, -1, 0, 1, 75 },
+ { 0x9, 0x9, 159, -1, 1215, 32, 1, 130 },
+ { 0x9, 0x9, 159, -1, 1224, 32, 1, 130 },
+ { 0x9, 0x9, 159, -1, 1233, 32, 1, 130 },
+ { 0x9, 0x9, 159, -1, 1244, 32, 1, 130 },
+ { 0x9, 0x9, 159, -1, 1253, 32, 1, 130 },
+ { 0x9, 0x9, 159, -1, 1262, 32, 1, 130 },
+ { 0x9, 0x9, 159, -1, 1271, 32, 1, 130 },
+ { 0x9, 0x9, 159, -1, 1280, 32, 1, 130 },
+ { 0x9, 0x9, 159, -1, 1289, 32, 1, 130 },
+ { 0x9, 0x9, 159, -1, 1299, 32, 1, 130 },
+ { 0x9, 0x9, 159, -1, 1309, 32, 1, 130 },
+ { 0x9, 0x9, 159, -1, 1319, 32, 1, 130 },
+ { 0x9, 0x9, 159, -1, 1328, 32, 1, 144 },
+ { 0x9, 0x9, 159, -1, 1334, 32, 1, 144 },
+ { 0x9, 0x9, 159, -1, 1340, 32, 1, 144 },
+ { 0x9, 0x9, 159, -1, 1346, 32, 1, 144 },
+ { 0x9, 0x9, 159, -1, 1352, 32, 1, 144 },
+ { 0x9, 0x9, 159, -1, 1358, 32, 1, 144 },
+ { 0x9, 0x9, 159, -1, 1364, 32, 1, 144 },
+ { 0x9, 0x9, 159, -1, 1370, 32, 1, 144 },
+ { 0x9, 0x9, 159, -1, 1376, 32, 1, 144 },
+ { 0x9, 0x9, 159, -1, 1382, 32, 1, 144 },
+ { 0x9, 0x9, 159, -1, 1388, 32, 1, 144 },
+ { 0x9, 0x9, 159, -1, 1394, 32, 1, 144 },
+ { 0x9, 0x9, 159, -1, 1400, 32, 1, 144 },
+ { 0x9, 0x9, 159, -1, 1406, 32, 1, 144 },
+ { 0x9, 0x9, 159, -1, 1412, 32, 1, 144 },
+ { 0x9, 0x9, 159, -1, 1418, 32, 1, 144 },
+ { 0x9, 0x9, 159, -1, 1424, 32, 1, 144 },
+ { 0x9, 0x9, 159, -1, 1430, 32, 1, 144 },
+ { 0x0, 0x0, 160, 1041, 287, 0, 0, -1 },
+ { 0x1, 0x1, 160, -1, 2425, 38, 1, 1 },
+ { 0x0, 0x0, 160, 785, 344, 0, 0, -1 },
+ { 0x0, 0x0, 160, 1042, 297, 0, 0, -1 },
+ { 0x1, 0x1, 160, -1, 2433, 38, 1, 1 },
+ { 0x0, 0x0, 160, 787, 364, 0, 0, -1 },
+ { 0x0, 0x0, 160, 788, 298, 0, 0, -1 },
+ { 0x0, 0x0, 160, 789, 308, 0, 0, -1 },
+ { 0x0, 0x0, 160, 1043, 311, 0, 0, -1 },
+ { 0x1, 0x1, 160, -1, 2445, 38, 1, 1 },
+ { 0x0, 0x0, 160, 791, 368, 0, 0, -1 },
+ { 0x0, 0x0, 160, -1, 321, 0, 0, -1 },
+ { 0x1, 0x1, 160, -1, 2451, 38, 1, 1 },
+ { 0x0, 0x0, 160, 793, 388, 0, 0, -1 },
+ { 0x0, 0x0, 160, 794, 322, 0, 0, -1 },
+ { 0x0, 0x0, 160, 795, 332, 0, 0, -1 },
+ { 0x0, 0x0, 161, 1186, 1941, 0, 0, -1 },
+ { 0x0, 0x0, 161, 1187, 2474, 0, 1, 54 },
+ { 0x0, 0x0, 161, 1188, 1985, 0, 0, -1 },
+ { 0x1, 0x1, 161, 1189, -1, 29, 1, 49 },
+ { 0x0, 0x0, 162, -1, 1951, 0, 0, -1 },
+ { 0x1, 0x9, 162, -1, 2481, 33, 1, 54 },
+ { 0x6, 0x7, 162, -1, 1992, 27, 1, 49 },
+ { 0x0, 0x0, 163, 1175, 1949, 0, 0, -1 },
+ { 0x0, 0x0, 163, 1176, 2480, 0, 1, 54 },
+ { 0x1, 0x1, 163, 1177, 1991, 29, 1, 49 },
+ { 0x1, 0x1, 164, 1191, -1, 27, 1, 33 },
+ { 0x0, 0x0, 165, 1832, 1945, 0, 0, -1 },
+ { 0x1, 0x1, 165, 1833, 2476, 33, 1, 54 },
+ { 0x0, 0x0, 165, 1834, 1987, 0, 0, -1 },
+ { 0x3, 0x3, 165, 1835, -1, 28, 1, 49 },
+ { 0x0, 0x0, 166, 1182, 1943, 0, 0, -1 },
+ { 0x1, 0x1, 166, 1183, 2475, 36, 1, 54 },
+ { 0x0, 0x0, 166, 1184, 1986, 0, 0, -1 },
+ { 0x5, 0x5, 166, 1185, -1, 27, 1, 49 },
+ { 0x0, 0x0, 167, -1, 2457, 0, 1, 63 },
+ { 0x1, 0x1, 169, -1, -1, 28, 1, 33 },
+ { 0x1, 0x1, 170, 2315, -1, 27, 1, 33 },
+ { 0x1, 0x1, 170, 2316, -1, 27, 1, 33 },
+ { 0x1, 0x1, 171, 1460, -1, 28, 1, 135 },
+ { 0x1, 0x1, 171, 1461, -1, 28, 1, 135 },
+ { 0x1, 0x1, 171, 1462, -1, 28, 1, 134 },
+ { 0x1, 0x1, 171, 1463, -1, 28, 1, 134 },
+ { 0x1, 0x1, 171, 1464, -1, 28, 1, 134 },
+ { 0x1, 0x1, 171, 1465, -1, 28, 1, 134 },
+ { 0x1, 0x1, 171, 1466, -1, 28, 1, 134 },
+ { 0x1, 0x1, 171, 1467, -1, 28, 1, 134 },
+ { 0x1, 0x1, 171, 1468, -1, 28, 1, 134 },
+ { 0x1, 0x1, 171, 1469, -1, 28, 1, 134 },
+ { 0x1, 0x1, 171, 1470, -1, 28, 1, 136 },
+ { 0x1, 0x1, 171, 1471, -1, 28, 1, 136 },
+ { 0x1, 0x1, 171, 1472, -1, 28, 1, 136 },
+ { 0x1, 0x1, 171, 1473, -1, 28, 1, 136 },
+ { 0x1, 0x1, 171, 1474, -1, 28, 1, 126 },
+ { 0x1, 0x1, 171, 1475, -1, 28, 1, 127 },
+ { 0x1, 0x1, 171, 1476, -1, 28, 1, 128 },
+ { 0x1, 0x1, 171, 1477, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1478, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1479, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1480, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1481, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1482, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1483, -1, 28, 1, 126 },
+ { 0x1, 0x1, 171, 1484, -1, 28, 1, 127 },
+ { 0x1, 0x1, 171, 1485, -1, 28, 1, 128 },
+ { 0x1, 0x1, 171, 1486, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1487, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1488, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1489, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1490, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1491, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1492, -1, 28, 1, 126 },
+ { 0x1, 0x1, 171, 1493, -1, 28, 1, 127 },
+ { 0x1, 0x1, 171, 1494, -1, 28, 1, 128 },
+ { 0x1, 0x1, 171, 1495, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1496, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1497, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1498, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1499, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1500, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1501, -1, 28, 1, 125 },
+ { 0x1, 0x1, 171, 1502, -1, 28, 1, 125 },
+ { 0x1, 0x1, 171, 1503, -1, 28, 1, 126 },
+ { 0x1, 0x1, 171, 1504, -1, 28, 1, 127 },
+ { 0x1, 0x1, 171, 1505, -1, 28, 1, 128 },
+ { 0x1, 0x1, 171, 1506, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1507, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1508, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1509, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1510, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1511, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1512, -1, 28, 1, 126 },
+ { 0x1, 0x1, 171, 1513, -1, 28, 1, 127 },
+ { 0x1, 0x1, 171, 1514, -1, 28, 1, 128 },
+ { 0x1, 0x1, 171, 1515, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1516, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1517, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1518, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1519, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1520, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1521, -1, 28, 1, 126 },
+ { 0x1, 0x1, 171, 1522, -1, 28, 1, 127 },
+ { 0x1, 0x1, 171, 1523, -1, 28, 1, 128 },
+ { 0x1, 0x1, 171, 1524, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1525, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1526, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1527, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1528, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1529, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1530, -1, 28, 1, 126 },
+ { 0x1, 0x1, 171, 1531, -1, 28, 1, 127 },
+ { 0x1, 0x1, 171, 1532, -1, 28, 1, 128 },
+ { 0x1, 0x1, 171, 1533, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1534, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1535, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1536, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1537, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1538, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1539, -1, 28, 1, 126 },
+ { 0x1, 0x1, 171, 1540, -1, 28, 1, 127 },
+ { 0x1, 0x1, 171, 1541, -1, 28, 1, 128 },
+ { 0x1, 0x1, 171, 1542, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1543, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1544, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1545, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1546, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1547, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1548, -1, 28, 1, 126 },
+ { 0x1, 0x1, 171, 1549, -1, 28, 1, 127 },
+ { 0x1, 0x1, 171, 1550, -1, 28, 1, 128 },
+ { 0x1, 0x1, 171, 1551, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1552, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1553, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1554, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1555, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1556, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1557, -1, 28, 1, 126 },
+ { 0x1, 0x1, 171, 1558, -1, 28, 1, 127 },
+ { 0x1, 0x1, 171, 1559, -1, 28, 1, 128 },
+ { 0x1, 0x1, 171, 1560, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1561, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1562, -1, 28, 1, 129 },
+ { 0x1, 0x1, 171, 1563, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1564, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1565, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1566, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1567, -1, 28, 1, 126 },
+ { 0x1, 0x1, 171, 1568, -1, 28, 1, 127 },
+ { 0x1, 0x1, 171, 1569, -1, 28, 1, 128 },
+ { 0x1, 0x1, 171, 1570, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1571, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1572, -1, 28, 1, 129 },
+ { 0x1, 0x1, 171, 1573, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1574, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1575, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1576, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1577, -1, 28, 1, 126 },
+ { 0x1, 0x1, 171, 1578, -1, 28, 1, 127 },
+ { 0x1, 0x1, 171, 1579, -1, 28, 1, 128 },
+ { 0x1, 0x1, 171, 1580, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1581, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1582, -1, 28, 1, 129 },
+ { 0x1, 0x1, 171, 1583, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1584, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1585, -1, 28, 1, 130 },
+ { 0x1, 0x1, 171, 1586, -1, 28, 1, 124 },
+ { 0x1, 0x1, 171, 1587, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1588, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1589, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1590, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1591, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1592, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1593, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1594, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1595, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1596, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1597, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1598, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1599, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1600, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1601, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1602, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1603, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1604, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1605, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1606, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1607, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1608, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1609, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1610, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1611, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1612, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1613, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1614, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1615, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1616, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1617, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1618, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1619, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1620, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1621, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1622, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1623, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1624, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1625, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1626, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1627, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1628, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1629, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1630, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1631, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1632, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1633, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1634, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1635, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1636, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1637, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1638, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1639, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1640, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1641, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1642, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1643, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1644, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1645, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1646, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1647, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1648, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1649, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1650, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1651, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1652, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1653, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1654, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1655, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1656, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1657, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1658, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1659, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1660, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1661, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1662, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1663, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1664, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1665, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1666, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1667, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1668, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1669, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1670, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1671, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1672, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1673, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1674, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1675, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1676, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1677, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1678, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1679, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1680, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1681, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1682, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1683, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1684, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1685, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1686, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1687, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1688, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1689, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1690, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1691, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1692, -1, 28, 1, 141 },
+ { 0x1, 0x1, 171, 1693, -1, 28, 1, 142 },
+ { 0x1, 0x1, 171, 1694, -1, 28, 1, 143 },
+ { 0x1, 0x1, 171, 1695, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1696, -1, 28, 1, 144 },
+ { 0x1, 0x1, 171, 1697, -1, 28, 1, 140 },
+ { 0x1, 0x1, 171, 1448, -1, 28, 1, 146 },
+ { 0x1, 0x1, 171, 1449, -1, 28, 1, 147 },
+ { 0x1, 0x1, 171, 1450, -1, 28, 1, 147 },
+ { 0x1, 0x1, 171, 1451, -1, 28, 1, 146 },
+ { 0x1, 0x1, 171, 1452, -1, 28, 1, 148 },
+ { 0x1, 0x1, 171, 1453, -1, 28, 1, 149 },
+ { 0x1, 0x1, 171, 1454, -1, 28, 1, 149 },
+ { 0x1, 0x1, 171, 1455, -1, 28, 1, 148 },
+ { 0x1, 0x1, 171, 1456, -1, 28, 1, 148 },
+ { 0x1, 0x1, 171, 1457, -1, 28, 1, 149 },
+ { 0x1, 0x1, 171, 1458, -1, 28, 1, 149 },
+ { 0x1, 0x1, 171, 1459, -1, 28, 1, 148 },
+ { 0x1, 0x1, 171, 1740, -1, 28, 1, 136 },
+ { 0x1, 0x1, 171, 1741, -1, 28, 1, 136 },
+ { 0x1, 0x1, 171, 1742, -1, 28, 1, 136 },
+ { 0x1, 0x1, 171, 1743, -1, 28, 1, 136 },
+ { 0x1, 0x1, 172, 1698, -1, 29, 1, 146 },
+ { 0x1, 0x1, 172, 1699, -1, 29, 1, 147 },
+ { 0x1, 0x1, 172, 1700, -1, 29, 1, 147 },
+ { 0x1, 0x1, 172, 1701, -1, 29, 1, 146 },
+ { 0x1, 0x1, 172, 1702, -1, 29, 1, 148 },
+ { 0x1, 0x1, 172, 1703, -1, 29, 1, 149 },
+ { 0x1, 0x1, 172, 1704, -1, 29, 1, 149 },
+ { 0x1, 0x1, 172, 1705, -1, 29, 1, 148 },
+ { 0x1, 0x1, 172, 1706, -1, 29, 1, 148 },
+ { 0x1, 0x1, 172, 1707, -1, 29, 1, 149 },
+ { 0x1, 0x1, 172, 1708, -1, 29, 1, 149 },
+ { 0x1, 0x1, 172, 1709, -1, 29, 1, 148 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 135 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 135 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 134 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 134 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 134 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 134 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 134 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 134 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 134 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 134 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 136 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 136 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 136 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 136 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 126 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 127 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 128 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 261, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 1890, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 126 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 127 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 128 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 263, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 1891, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 126 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 127 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 128 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 265, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 1892, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 125 },
+ { 0x3, 0x3, 173, 267, -1, 28, 1, 125 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 126 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 127 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 128 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 268, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 1893, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 126 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 127 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 128 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 270, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 1894, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 126 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 127 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 128 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 272, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 1895, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 126 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 127 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 128 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 274, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 1896, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 126 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 127 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 128 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 276, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 1897, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 126 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 127 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 128 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 278, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 1898, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 126 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 127 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 128 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 129 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 280, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 1899, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 126 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 127 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 128 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 129 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 282, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 1900, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 126 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 127 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 128 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 129 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 284, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 130 },
+ { 0x3, 0x3, 173, 1901, -1, 28, 1, 124 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1902, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1903, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1904, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1905, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1906, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1907, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1908, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1909, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1910, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1911, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1912, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1913, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1914, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1915, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1916, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1917, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1918, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 141 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 142 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 143 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 144 },
+ { 0x3, 0x3, 173, 1919, -1, 28, 1, 140 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 146 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 147 },
+ { 0x3, 0x3, 173, 803, -1, 28, 1, 147 },
+ { 0x3, 0x3, 173, 804, -1, 28, 1, 146 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 148 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 149 },
+ { 0x3, 0x3, 173, 805, -1, 28, 1, 149 },
+ { 0x3, 0x3, 173, 806, -1, 28, 1, 148 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 148 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 149 },
+ { 0x3, 0x3, 173, 807, -1, 28, 1, 149 },
+ { 0x3, 0x3, 173, 808, -1, 28, 1, 148 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 131 },
+ { 0x3, 0x3, 173, 1857, -1, 28, 1, 131 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 138 },
+ { 0x3, 0x3, 173, 1858, -1, 28, 1, 138 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 132 },
+ { 0x3, 0x3, 173, 1859, -1, 28, 1, 132 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 131 },
+ { 0x3, 0x3, 173, 1860, -1, 28, 1, 131 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 138 },
+ { 0x3, 0x3, 173, 1861, -1, 28, 1, 138 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 131 },
+ { 0x3, 0x3, 173, 1862, -1, 28, 1, 131 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 138 },
+ { 0x3, 0x3, 173, 1863, -1, 28, 1, 138 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 131 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 133 },
+ { 0x3, 0x3, 173, 1864, -1, 28, 1, 131 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 138 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 139 },
+ { 0x3, 0x3, 173, 1865, -1, 28, 1, 138 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 145 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 145 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 145 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 145 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 145 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 145 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 145 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 145 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 145 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 145 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 136 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 136 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 136 },
+ { 0x3, 0x3, 173, -1, -1, 28, 1, 136 },
+ { 0x0, 0x0, 174, -1, 335, 0, 0, -1 },
+ { 0x0, 0x0, 174, 2514, 2483, 0, 1, 1 },
+ { 0x0, 0x0, 174, -1, 339, 0, 0, -1 },
+ { 0x0, 0x0, 174, 2516, 2485, 0, 1, 1 },
+ { 0x11, 0x31, 175, 2417, 342, 33, 1, 4 },
+ { 0x2200001, 0x2200001, 175, -1, 343, 12, 1, 4 },
+ { 0x1, 0x1, 175, -1, 346, 37, 1, 4 },
+ { 0x2000001, 0x2000001, 175, -1, 347, 12, 1, 4 },
+ { 0x11, 0x11, 175, -1, 348, 33, 1, 4 },
+ { 0x2200001, 0x2200001, 175, -1, 349, 12, 1, 4 },
+ { 0x1, 0x1, 175, 1778, 350, 37, 1, 4 },
+ { 0x2000001, 0x2000001, 175, -1, 352, 12, 1, 4 },
+ { 0x11, 0x11, 175, 1780, 354, 33, 1, 4 },
+ { 0x2200001, 0x2200001, 175, -1, 356, 12, 1, 4 },
+ { 0x11, 0x31, 175, 2427, 362, 33, 1, 4 },
+ { 0x2200001, 0x2200001, 175, -1, 363, 12, 1, 4 },
+ { 0x11, 0x31, 175, 2437, 366, 33, 1, 4 },
+ { 0x2200001, 0x2200001, 175, -1, 367, 12, 1, 4 },
+ { 0x1, 0x1, 175, -1, 370, 37, 1, 4 },
+ { 0x2000001, 0x2000001, 175, -1, 371, 12, 1, 4 },
+ { 0x11, 0x11, 175, -1, 372, 33, 1, 4 },
+ { 0x2200001, 0x2200001, 175, -1, 373, 12, 1, 4 },
+ { 0x1, 0x1, 175, 1802, 374, 37, 1, 4 },
+ { 0x2000001, 0x2000001, 175, -1, 376, 12, 1, 4 },
+ { 0x11, 0x11, 175, 1804, 378, 33, 1, 4 },
+ { 0x2200001, 0x2200001, 175, -1, 380, 12, 1, 4 },
+ { 0x11, 0x31, 175, 2447, 386, 33, 1, 4 },
+ { 0x2200001, 0x2200001, 175, -1, 387, 12, 1, 4 },
+ { 0x1, 0x1, 175, -1, 390, 33, 1, 4 },
+ { 0x200001, 0x200001, 175, -1, 391, 12, 1, 4 },
+ { 0x1, 0x1, 175, -1, 394, 33, 1, 4 },
+ { 0x200001, 0x200001, 175, -1, 395, 12, 1, 4 },
+ { 0x1, 0x1, 176, -1, -1, 37, 1, 4 },
+ { 0x2000001, 0x2000001, 176, -1, -1, 12, 1, 4 },
+ { 0x2000001, 0x2000001, 176, -1, -1, 12, 1, 4 },
+ { 0x1, 0x1, 176, 1755, -1, 37, 1, 4 },
+ { 0x2200001, 0x2200001, 176, -1, -1, 12, 1, 4 },
+ { 0x11, 0x11, 176, 1757, -1, 33, 1, 4 },
+ { 0x1, 0x1, 176, -1, -1, 37, 1, 4 },
+ { 0x2000001, 0x2000001, 176, -1, -1, 12, 1, 4 },
+ { 0x11, 0x11, 176, -1, -1, 33, 1, 4 },
+ { 0x2200001, 0x2200001, 176, -1, -1, 12, 1, 4 },
+ { 0x1, 0x1, 176, -1, -1, 37, 1, 4 },
+ { 0x2000001, 0x2000001, 176, -1, -1, 12, 1, 4 },
+ { 0x0, 0x0, 176, -1, -1, 0, 1, 5 },
+ { 0x1, 0x1, 176, -1, -1, 12, 1, 5 },
+ { 0x0, 0x0, 176, -1, -1, 0, 1, 5 },
+ { 0x1, 0x1, 176, -1, -1, 12, 1, 5 },
+ { 0x1, 0x1, 176, -1, -1, 33, 1, 5 },
+ { 0x200001, 0x200001, 176, -1, -1, 12, 1, 5 },
+ { 0x0, 0x0, 176, -1, -1, 0, 1, 5 },
+ { 0x1, 0x1, 176, -1, -1, 12, 1, 5 },
+ { 0x1, 0x1, 176, -1, -1, 33, 1, 5 },
+ { 0x200001, 0x200001, 176, -1, -1, 12, 1, 5 },
+ { 0x0, 0x0, 176, -1, -1, 0, 1, 5 },
+ { 0x1, 0x1, 176, -1, -1, 12, 1, 5 },
+ { 0x1, 0x1, 176, -1, -1, 37, 1, 4 },
+ { 0x2000001, 0x2000001, 176, -1, -1, 12, 1, 4 },
+ { 0x2000001, 0x2000001, 176, -1, -1, 12, 1, 4 },
+ { 0x1, 0x1, 176, 1767, -1, 37, 1, 4 },
+ { 0x2200001, 0x2200001, 176, -1, -1, 12, 1, 4 },
+ { 0x11, 0x11, 176, 1769, -1, 33, 1, 4 },
+ { 0x1, 0x1, 176, -1, -1, 37, 1, 4 },
+ { 0x2000001, 0x2000001, 176, -1, -1, 12, 1, 4 },
+ { 0x11, 0x11, 176, -1, -1, 33, 1, 4 },
+ { 0x2200001, 0x2200001, 176, -1, -1, 12, 1, 4 },
+ { 0x1, 0x1, 176, -1, -1, 37, 1, 4 },
+ { 0x2000001, 0x2000001, 176, -1, -1, 12, 1, 4 },
+ { 0x0, 0x0, 176, -1, -1, 0, 1, 5 },
+ { 0x1, 0x1, 176, -1, -1, 12, 1, 5 },
+ { 0x0, 0x0, 176, -1, -1, 0, 1, 5 },
+ { 0x1, 0x1, 176, -1, -1, 12, 1, 5 },
+ { 0x1, 0x1, 176, -1, -1, 33, 1, 5 },
+ { 0x200001, 0x200001, 176, -1, -1, 12, 1, 5 },
+ { 0x0, 0x0, 176, -1, -1, 0, 1, 5 },
+ { 0x1, 0x1, 176, -1, -1, 12, 1, 5 },
+ { 0x1, 0x1, 176, -1, -1, 33, 1, 5 },
+ { 0x200001, 0x200001, 176, -1, -1, 12, 1, 5 },
+ { 0x0, 0x0, 176, -1, -1, 0, 1, 5 },
+ { 0x1, 0x1, 176, -1, -1, 12, 1, 5 },
+ { 0x9, 0x9, 176, -1, -1, 33, 1, 5 },
+ { 0x1, 0x1, 176, 336, -1, 33, 1, 4 },
+ { 0x1200001, 0x1200001, 176, -1, -1, 12, 1, 5 },
+ { 0x200001, 0x200001, 176, 337, -1, 12, 1, 4 },
+ { 0x9, 0x9, 176, -1, -1, 33, 1, 5 },
+ { 0x1, 0x1, 176, 340, -1, 33, 1, 4 },
+ { 0x1200001, 0x1200001, 176, -1, -1, 12, 1, 5 },
+ { 0x200001, 0x200001, 176, 341, -1, 12, 1, 4 },
+ { 0x0, 0x0, 177, -1, 1947, 0, 0, -1 },
+ { 0x9, 0x9, 177, -1, 2477, 33, 1, 49 },
+ { 0x0, 0x0, 177, -1, 1988, 0, 0, -1 },
+ { 0x7, 0x7, 177, -1, -1, 27, 1, 49 },
+ { 0x1, 0x1, 197, -1, -1, 27, 1, 10 },
+ { 0x1, 0x1, 211, -1, -1, 29, 1, 0 },
+ { 0x1, 0x1, 211, -1, -1, 29, 1, 0 },
+ { 0x2, 0x3, 211, 987, -1, 27, 1, 33 },
+ { 0x0, 0x0, 211, 988, -1, 0, 1, 33 },
+ { 0x0, 0x0, 211, 989, -1, 0, 1, 0 },
+ { 0x0, 0x0, 211, 990, -1, 0, 1, 0 },
+ { 0x0, 0x0, 211, 991, -1, 0, 1, 0 },
+ { 0x0, 0x0, 211, 992, -1, 0, 1, 0 },
+ { 0x0, 0x0, 211, 2499, -1, 0, 1, 93 },
+ { 0x0, 0x0, 211, 2500, -1, 0, 1, 93 },
+ { 0x0, 0x0, 211, 2501, 819, 0, 0, -1 },
+ { 0x1, 0x1, 212, -1, -1, 27, 1, 0 },
+ { 0x1, 0x1, 212, -1, -1, 27, 1, 0 },
+ { 0x1, 0x1, 213, -1, 1195, 32, 1, 135 },
+ { 0x1, 0x1, 213, -1, 1197, 32, 1, 134 },
+ { 0x1, 0x1, 213, -1, 1199, 32, 1, 134 },
+ { 0x1, 0x1, 213, -1, 1201, 32, 1, 134 },
+ { 0x1, 0x1, 213, -1, 1203, 32, 1, 134 },
+ { 0x1, 0x1, 213, -1, 1205, 32, 1, 136 },
+ { 0x1, 0x1, 213, -1, 1207, 32, 1, 136 },
+ { 0x1, 0x1, 213, -1, 1710, 32, 1, 131 },
+ { 0x1, 0x1, 213, -1, 1712, 32, 1, 138 },
+ { 0x1, 0x1, 213, -1, 1714, 32, 1, 132 },
+ { 0x1, 0x1, 213, -1, 1716, 32, 1, 131 },
+ { 0x1, 0x1, 213, -1, 1718, 32, 1, 138 },
+ { 0x1, 0x1, 213, -1, 1720, 32, 1, 131 },
+ { 0x1, 0x1, 213, -1, 1722, 32, 1, 138 },
+ { 0x1, 0x1, 213, 2319, 1724, 32, 1, 131 },
+ { 0x1, 0x1, 213, 2320, 1727, 32, 1, 138 },
+ { 0x0, 0x0, 214, -1, 2361, 0, 0, -1 },
+ { 0x0, 0x0, 214, -1, 2362, 0, 0, -1 },
+ { 0x0, 0x0, 214, -1, 2387, 0, 0, -1 },
+ { 0x5, 0x5, 214, -1, 2390, 20, 1, 67 },
+ { 0x0, 0x0, 218, 1847, 818, 0, 0, -1 },
+ { 0x0, 0x0, 219, -1, 957, 0, 0, -1 },
+ { 0x0, 0x0, 219, -1, 1048, 0, 0, -1 },
+ { 0x0, 0x0, 219, -1, -1, 0, 1, 121 },
+ { 0x0, 0x0, 219, -1, -1, 0, 1, 66 },
+ { 0x1, 0x1, 219, 694, 1921, 36, 1, 65 },
+ { 0x1, 0x1, 219, 695, 1956, 36, 1, 65 },
+ { 0x0, 0x0, 219, 696, 1959, 0, 0, -1 },
+ { 0x1, 0x1, 219, 697, -1, 36, 1, 65 },
+ { 0x0, 0x0, 219, 1192, -1, 0, 1, 33 },
+ { 0x1, 0x1, 219, 698, 1964, 36, 1, 65 },
+ { 0x0, 0x0, 219, 699, 1967, 0, 0, -1 },
+ { 0x1, 0x1, 219, 700, -1, 36, 1, 65 },
+ { 0x0, 0x0, 219, 701, 1970, 0, 0, -1 },
+ { 0x1, 0x1, 219, 702, -1, 36, 1, 65 },
+ { 0x1, 0x1, 219, 703, 1973, 36, 1, 65 },
+ { 0x1, 0x1, 219, 704, 1976, 36, 1, 65 },
+ { 0x0, 0x0, 219, 1193, -1, 0, 1, 33 },
+ { 0x1, 0x1, 219, 705, 2009, 36, 1, 65 },
+ { 0x1, 0x1, 219, 706, -1, 31, 1, 137 },
+ { 0x1, 0x1, 219, 223, 1208, 32, 1, 126 },
+ { 0x1, 0x1, 219, 224, 1217, 32, 1, 126 },
+ { 0x1, 0x1, 219, 225, 1226, 32, 1, 126 },
+ { 0x1, 0x1, 219, 226, 1237, 32, 1, 126 },
+ { 0x1, 0x1, 219, 227, 1246, 32, 1, 126 },
+ { 0x1, 0x1, 219, 228, 1255, 32, 1, 126 },
+ { 0x1, 0x1, 219, 229, 1264, 32, 1, 126 },
+ { 0x1, 0x1, 219, 230, 1273, 32, 1, 126 },
+ { 0x1, 0x1, 219, 231, 1282, 32, 1, 126 },
+ { 0x1, 0x1, 219, 232, 1291, 32, 1, 126 },
+ { 0x1, 0x1, 219, 233, 1301, 32, 1, 126 },
+ { 0x1, 0x1, 219, 234, 1311, 32, 1, 126 },
+ { 0x1, 0x1, 219, 235, 1324, 32, 1, 141 },
+ { 0x1, 0x1, 219, 236, 1330, 32, 1, 141 },
+ { 0x1, 0x1, 219, 237, 1336, 32, 1, 141 },
+ { 0x1, 0x1, 219, 238, 1342, 32, 1, 141 },
+ { 0x1, 0x1, 219, 239, 1348, 32, 1, 141 },
+ { 0x1, 0x1, 219, 240, 1354, 32, 1, 141 },
+ { 0x1, 0x1, 219, 241, 1360, 32, 1, 141 },
+ { 0x1, 0x1, 219, 242, 1366, 32, 1, 141 },
+ { 0x1, 0x1, 219, 243, 1372, 32, 1, 141 },
+ { 0x1, 0x1, 219, 244, 1378, 32, 1, 141 },
+ { 0x1, 0x1, 219, 245, 1384, 32, 1, 141 },
+ { 0x1, 0x1, 219, 246, 1390, 32, 1, 141 },
+ { 0x1, 0x1, 219, 247, 1396, 32, 1, 141 },
+ { 0x1, 0x1, 219, 248, 1402, 32, 1, 141 },
+ { 0x1, 0x1, 219, 249, 1408, 32, 1, 141 },
+ { 0x1, 0x1, 219, 250, 1414, 32, 1, 141 },
+ { 0x1, 0x1, 219, 251, 1420, 32, 1, 141 },
+ { 0x1, 0x1, 219, 252, 1426, 32, 1, 141 },
+ { 0x1, 0x1, 219, 710, -1, 31, 1, 150 },
+ { 0x0, 0x0, 220, 2012, -1, 0, 1, 65 },
+ { 0x0, 0x0, 220, 2013, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 24, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 2015, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 2016, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 2017, -1, 0, 1, 44 },
+ { 0x0, 0x0, 220, 2018, -1, 0, 1, 39 },
+ { 0x1, 0x1, 220, 2019, -1, 12, 1, 58 },
+ { 0x0, 0x0, 220, 2020, -1, 0, 1, 53 },
+ { 0x1000001, 0x1000001, 220, 2021, -1, 12, 1, 58 },
+ { 0x1, 0x1, 220, 2022, -1, 36, 1, 53 },
+ { 0x200001, 0x200001, 220, 2023, -1, 12, 1, 58 },
+ { 0x1, 0x1, 220, 2024, -1, 33, 1, 53 },
+ { 0x1200001, 0x1200001, 220, 2025, -1, 12, 1, 48 },
+ { 0x9, 0x9, 220, 2026, -1, 33, 1, 48 },
+ { 0x1, 0x1, 220, 2027, -1, 12, 1, 58 },
+ { 0x0, 0x0, 220, 2028, -1, 0, 1, 53 },
+ { 0x200001, 0x1200001, 220, 2029, -1, 12, 1, 58 },
+ { 0x1, 0x9, 220, 2030, -1, 33, 1, 53 },
+ { 0x1, 0x1, 220, 2031, -1, 12, 1, 58 },
+ { 0x0, 0x0, 220, 2032, -1, 0, 1, 53 },
+ { 0x1000001, 0x1000001, 220, 2033, -1, 12, 1, 58 },
+ { 0x1, 0x1, 220, 2034, -1, 36, 1, 53 },
+ { 0x200001, 0x200001, 220, 2035, -1, 12, 1, 58 },
+ { 0x1, 0x1, 220, 2036, -1, 33, 1, 53 },
+ { 0x1200001, 0x1200001, 220, 2037, -1, 12, 1, 48 },
+ { 0x9, 0x9, 220, 2038, -1, 33, 1, 48 },
+ { 0x1, 0x1, 220, 2039, -1, 12, 1, 58 },
+ { 0x0, 0x0, 220, 2040, -1, 0, 1, 53 },
+ { 0x200001, 0x1200001, 220, 2041, -1, 12, 1, 58 },
+ { 0x1, 0x9, 220, 2042, -1, 33, 1, 53 },
+ { 0x1, 0x1, 220, 2043, -1, 28, 1, 28 },
+ { 0x0, 0x0, 220, 2044, -1, 0, 1, 28 },
+ { 0x3, 0x3, 220, 2045, -1, 27, 1, 28 },
+ { 0x1, 0x1, 220, 2046, -1, 27, 1, 28 },
+ { 0x0, 0x0, 220, 2047, -1, 0, 1, 65 },
+ { 0x0, 0x0, 220, 2048, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 2049, -1, 0, 1, 28 },
+ { 0x1, 0x1, 220, 2050, -1, 36, 1, 65 },
+ { 0x1, 0x1, 220, 2051, -1, 37, 1, 28 },
+ { 0x0, 0x0, 220, 2052, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 2053, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 2054, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 2055, -1, 0, 1, 65 },
+ { 0x0, 0x0, 220, 2056, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 36, -1, 0, 1, 28 },
+ { 0x1, 0x1, 220, 2058, -1, 36, 1, 65 },
+ { 0x1, 0x1, 220, 2059, -1, 37, 1, 28 },
+ { 0x0, 0x0, 220, 2060, -1, 0, 1, 28 },
+ { 0x1, 0x1, 220, 2061, -1, 36, 1, 65 },
+ { 0x1, 0x1, 220, 2062, -1, 37, 1, 28 },
+ { 0x0, 0x0, 220, 2063, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 2064, -1, 0, 1, 65 },
+ { 0x0, 0x0, 220, 2065, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 41, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 2067, -1, 0, 1, 65 },
+ { 0x0, 0x0, 220, 2068, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 42, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 2070, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 2071, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 2072, -1, 0, 1, 48 },
+ { 0x1, 0x1, 220, 2073, -1, 27, 1, 48 },
+ { 0x1, 0x1, 220, 2074, -1, 28, 1, 48 },
+ { 0x3, 0x3, 220, 2075, -1, 27, 1, 48 },
+ { 0x1, 0x1, 220, 2076, -1, 29, 1, 48 },
+ { 0x5, 0x5, 220, 2077, -1, 27, 1, 48 },
+ { 0x3, 0x3, 220, 2078, -1, 28, 1, 48 },
+ { 0x7, 0x7, 220, 2079, -1, 27, 1, 48 },
+ { 0x0, 0x0, 220, 2080, -1, 0, 1, 48 },
+ { 0x0, 0x0, 220, 2081, -1, 0, 1, 48 },
+ { 0x0, 0x0, 220, 2082, -1, 0, 1, 48 },
+ { 0x0, 0x0, 220, 2083, -1, 0, 1, 48 },
+ { 0x1, 0x1, 220, 2084, -1, 28, 1, 28 },
+ { 0x0, 0x0, 220, 2085, -1, 0, 1, 28 },
+ { 0x3, 0x3, 220, 2086, -1, 27, 1, 28 },
+ { 0x1, 0x1, 220, 2087, -1, 27, 1, 28 },
+ { 0x0, 0x0, 220, 2088, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 2089, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 2090, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 51, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 2092, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 2093, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 56, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 2095, -1, 0, 1, 23 },
+ { 0x0, 0x0, 220, 2096, -1, 0, 1, 23 },
+ { 0x0, 0x0, 220, 2097, -1, 0, 1, 23 },
+ { 0x0, 0x0, 220, 2098, -1, 0, 1, 23 },
+ { 0x0, 0x0, 220, 2099, -1, 0, 1, 34 },
+ { 0x0, 0x0, 220, 2100, -1, 0, 1, 65 },
+ { 0x0, 0x0, 220, 2101, -1, 0, 1, 28 },
+ { 0x0, 0x0, 220, 63, -1, 0, 1, 28 },
+ { 0x1, 0x1, 221, 2103, -1, 34, 1, 65 },
+ { 0x1, 0x1, 221, 2104, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2105, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2106, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2107, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2108, -1, 34, 1, 45 },
+ { 0x1, 0x1, 221, 2109, -1, 34, 1, 41 },
+ { 0x400001, 0x400001, 221, 2110, -1, 12, 1, 60 },
+ { 0x1, 0x1, 221, 2111, -1, 34, 1, 55 },
+ { 0x1400001, 0x1400001, 221, 2112, -1, 12, 1, 60 },
+ { 0x5, 0x5, 221, 2113, -1, 34, 1, 55 },
+ { 0x600001, 0x600001, 221, 2114, -1, 12, 1, 60 },
+ { 0x3, 0x3, 221, 2115, -1, 33, 1, 55 },
+ { 0x1600001, 0x1600001, 221, 2116, -1, 12, 1, 50 },
+ { 0xb, 0xb, 221, 2117, -1, 33, 1, 50 },
+ { 0x400001, 0x400001, 221, 2118, -1, 12, 1, 60 },
+ { 0x1, 0x1, 221, 2119, -1, 34, 1, 55 },
+ { 0x600001, 0x1600001, 221, 2120, -1, 12, 1, 60 },
+ { 0x3, 0xb, 221, 2121, -1, 33, 1, 55 },
+ { 0x400001, 0x400001, 221, 2122, -1, 12, 1, 60 },
+ { 0x1, 0x1, 221, 2123, -1, 34, 1, 55 },
+ { 0x1400001, 0x1400001, 221, 2124, -1, 12, 1, 60 },
+ { 0x5, 0x5, 221, 2125, -1, 34, 1, 55 },
+ { 0x600001, 0x600001, 221, 2126, -1, 12, 1, 60 },
+ { 0x3, 0x3, 221, 2127, -1, 33, 1, 55 },
+ { 0x1600001, 0x1600001, 221, 2128, -1, 12, 1, 50 },
+ { 0xb, 0xb, 221, 2129, -1, 33, 1, 50 },
+ { 0x400001, 0x400001, 221, 2130, -1, 12, 1, 60 },
+ { 0x1, 0x1, 221, 2131, -1, 34, 1, 55 },
+ { 0x600001, 0x1600001, 221, 2132, -1, 12, 1, 60 },
+ { 0x3, 0xb, 221, 2133, -1, 33, 1, 55 },
+ { 0x41, 0x41, 221, 2134, -1, 28, 1, 30 },
+ { 0x1, 0x1, 221, 2135, -1, 34, 1, 30 },
+ { 0x83, 0x83, 221, 2136, -1, 27, 1, 30 },
+ { 0x81, 0x81, 221, 2137, -1, 27, 1, 30 },
+ { 0x1, 0x1, 221, 2138, -1, 34, 1, 65 },
+ { 0x1, 0x1, 221, 2139, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2140, -1, 34, 1, 30 },
+ { 0x5, 0x5, 221, 2141, -1, 34, 1, 65 },
+ { 0x9, 0x9, 221, 2142, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2143, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2144, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2145, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2146, -1, 34, 1, 65 },
+ { 0x1, 0x1, 221, 2147, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2148, -1, 34, 1, 30 },
+ { 0x5, 0x5, 221, 2149, -1, 34, 1, 65 },
+ { 0x9, 0x9, 221, 2150, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2151, -1, 34, 1, 30 },
+ { 0x5, 0x5, 221, 2152, -1, 34, 1, 65 },
+ { 0x9, 0x9, 221, 2153, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2154, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2155, -1, 34, 1, 65 },
+ { 0x1, 0x1, 221, 2156, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2157, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2158, -1, 34, 1, 65 },
+ { 0x1, 0x1, 221, 2159, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2160, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2161, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2162, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2163, -1, 34, 1, 50 },
+ { 0x81, 0x81, 221, 2164, -1, 27, 1, 50 },
+ { 0x41, 0x41, 221, 2165, -1, 28, 1, 50 },
+ { 0x83, 0x83, 221, 2166, -1, 27, 1, 50 },
+ { 0x21, 0x21, 221, 2167, -1, 29, 1, 50 },
+ { 0x85, 0x85, 221, 2168, -1, 27, 1, 50 },
+ { 0x43, 0x43, 221, 2169, -1, 28, 1, 50 },
+ { 0x87, 0x87, 221, 2170, -1, 27, 1, 50 },
+ { 0x1, 0x1, 221, 2171, -1, 34, 1, 50 },
+ { 0x1, 0x1, 221, 2172, -1, 34, 1, 50 },
+ { 0x1, 0x1, 221, 2173, -1, 34, 1, 50 },
+ { 0x1, 0x1, 221, 2174, -1, 34, 1, 50 },
+ { 0x41, 0x41, 221, 2175, -1, 28, 1, 30 },
+ { 0x1, 0x1, 221, 2176, -1, 34, 1, 30 },
+ { 0x83, 0x83, 221, 2177, -1, 27, 1, 30 },
+ { 0x81, 0x81, 221, 2178, -1, 27, 1, 30 },
+ { 0x1, 0x1, 221, 2179, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2180, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2181, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2182, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2183, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2184, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2185, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2186, -1, 34, 1, 25 },
+ { 0x1, 0x1, 221, 2187, -1, 34, 1, 25 },
+ { 0x1, 0x1, 221, 2188, -1, 34, 1, 25 },
+ { 0x1, 0x1, 221, 2189, -1, 34, 1, 25 },
+ { 0x1, 0x1, 221, 2190, -1, 34, 1, 36 },
+ { 0x1, 0x1, 221, 2191, -1, 34, 1, 65 },
+ { 0x1, 0x1, 221, 2192, -1, 34, 1, 30 },
+ { 0x1, 0x1, 221, 2193, -1, 34, 1, 30 },
+ { 0x1, 0x1, 222, 2194, -1, 35, 1, 65 },
+ { 0x1, 0x1, 222, 2195, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2196, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2197, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2198, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2199, -1, 35, 1, 46 },
+ { 0x1, 0x1, 222, 2200, -1, 35, 1, 42 },
+ { 0x800001, 0x800001, 222, 2201, -1, 12, 1, 61 },
+ { 0x1, 0x1, 222, 2202, -1, 35, 1, 56 },
+ { 0x1800001, 0x1800001, 222, 2203, -1, 12, 1, 61 },
+ { 0x3, 0x3, 222, 2204, -1, 35, 1, 56 },
+ { 0xa00001, 0xa00001, 222, 2205, -1, 12, 1, 61 },
+ { 0x5, 0x5, 222, 2206, -1, 33, 1, 56 },
+ { 0x1a00001, 0x1a00001, 222, 2207, -1, 12, 1, 51 },
+ { 0xd, 0xd, 222, 2208, -1, 33, 1, 51 },
+ { 0x800001, 0x800001, 222, 2209, -1, 12, 1, 61 },
+ { 0x1, 0x1, 222, 2210, -1, 35, 1, 56 },
+ { 0xa00001, 0x1a00001, 222, 2211, -1, 12, 1, 61 },
+ { 0x5, 0xd, 222, 2212, -1, 33, 1, 56 },
+ { 0x800001, 0x800001, 222, 2213, -1, 12, 1, 61 },
+ { 0x1, 0x1, 222, 2214, -1, 35, 1, 56 },
+ { 0x1800001, 0x1800001, 222, 2215, -1, 12, 1, 61 },
+ { 0x3, 0x3, 222, 2216, -1, 35, 1, 56 },
+ { 0xa00001, 0xa00001, 222, 2217, -1, 12, 1, 61 },
+ { 0x5, 0x5, 222, 2218, -1, 33, 1, 56 },
+ { 0x1a00001, 0x1a00001, 222, 2219, -1, 12, 1, 51 },
+ { 0xd, 0xd, 222, 2220, -1, 33, 1, 51 },
+ { 0x800001, 0x800001, 222, 2221, -1, 12, 1, 61 },
+ { 0x1, 0x1, 222, 2222, -1, 35, 1, 56 },
+ { 0xa00001, 0x1a00001, 222, 2223, -1, 12, 1, 61 },
+ { 0x5, 0xd, 222, 2224, -1, 33, 1, 56 },
+ { 0x81, 0x81, 222, 2225, -1, 28, 1, 31 },
+ { 0x1, 0x1, 222, 2226, -1, 35, 1, 31 },
+ { 0x103, 0x103, 222, 2227, -1, 27, 1, 31 },
+ { 0x101, 0x101, 222, 2228, -1, 27, 1, 31 },
+ { 0x1, 0x1, 222, 2229, -1, 35, 1, 65 },
+ { 0x1, 0x1, 222, 2230, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2231, -1, 35, 1, 31 },
+ { 0x3, 0x3, 222, 2232, -1, 35, 1, 65 },
+ { 0x5, 0x5, 222, 2233, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2234, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2235, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2236, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2237, -1, 35, 1, 65 },
+ { 0x1, 0x1, 222, 2238, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2239, -1, 35, 1, 31 },
+ { 0x3, 0x3, 222, 2240, -1, 35, 1, 65 },
+ { 0x5, 0x5, 222, 2241, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2242, -1, 35, 1, 31 },
+ { 0x3, 0x3, 222, 2243, -1, 35, 1, 65 },
+ { 0x5, 0x5, 222, 2244, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2245, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2246, -1, 35, 1, 65 },
+ { 0x1, 0x1, 222, 2247, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2248, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2249, -1, 35, 1, 65 },
+ { 0x1, 0x1, 222, 2250, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2251, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2252, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2253, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2254, -1, 35, 1, 51 },
+ { 0x101, 0x101, 222, 2255, -1, 27, 1, 51 },
+ { 0x81, 0x81, 222, 2256, -1, 28, 1, 51 },
+ { 0x103, 0x103, 222, 2257, -1, 27, 1, 51 },
+ { 0x41, 0x41, 222, 2258, -1, 29, 1, 51 },
+ { 0x105, 0x105, 222, 2259, -1, 27, 1, 51 },
+ { 0x83, 0x83, 222, 2260, -1, 28, 1, 51 },
+ { 0x107, 0x107, 222, 2261, -1, 27, 1, 51 },
+ { 0x1, 0x1, 222, 2262, -1, 35, 1, 51 },
+ { 0x1, 0x1, 222, 2263, -1, 35, 1, 51 },
+ { 0x1, 0x1, 222, 2264, -1, 35, 1, 51 },
+ { 0x1, 0x1, 222, 2265, -1, 35, 1, 51 },
+ { 0x81, 0x81, 222, 2266, -1, 28, 1, 31 },
+ { 0x1, 0x1, 222, 2267, -1, 35, 1, 31 },
+ { 0x103, 0x103, 222, 2268, -1, 27, 1, 31 },
+ { 0x101, 0x101, 222, 2269, -1, 27, 1, 31 },
+ { 0x1, 0x1, 222, 2270, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2271, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2272, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2273, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2274, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2275, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2276, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2277, -1, 35, 1, 26 },
+ { 0x1, 0x1, 222, 2278, -1, 35, 1, 26 },
+ { 0x1, 0x1, 222, 2279, -1, 35, 1, 26 },
+ { 0x1, 0x1, 222, 2280, -1, 35, 1, 26 },
+ { 0x1, 0x1, 222, 2281, -1, 35, 1, 37 },
+ { 0x1, 0x1, 222, 2282, -1, 35, 1, 65 },
+ { 0x1, 0x1, 222, 2283, -1, 35, 1, 31 },
+ { 0x1, 0x1, 222, 2284, -1, 35, 1, 31 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 65 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, 1875, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 47 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 43 },
+ { 0xc00001, 0xc00001, 223, -1, -1, 12, 1, 62 },
+ { 0x3, 0x3, 223, 2458, -1, 34, 1, 57 },
+ { 0x1c00001, 0x1c00001, 223, -1, -1, 12, 1, 62 },
+ { 0x7, 0x7, 223, 2459, -1, 34, 1, 57 },
+ { 0xe00001, 0xe00001, 223, -1, -1, 12, 1, 62 },
+ { 0x7, 0x7, 223, 2460, -1, 33, 1, 57 },
+ { 0x1e00001, 0x1e00001, 223, -1, -1, 12, 1, 52 },
+ { 0xf, 0xf, 223, 2461, -1, 33, 1, 52 },
+ { 0xc00001, 0xc00001, 223, -1, -1, 12, 1, 62 },
+ { 0x3, 0x3, 223, 2466, -1, 34, 1, 57 },
+ { 0xe00001, 0x1e00001, 223, -1, -1, 12, 1, 62 },
+ { 0x7, 0xf, 223, 2467, -1, 33, 1, 57 },
+ { 0xc00001, 0xc00001, 223, -1, -1, 12, 1, 62 },
+ { 0x3, 0x3, 223, 2470, -1, 34, 1, 57 },
+ { 0x1c00001, 0x1c00001, 223, -1, -1, 12, 1, 62 },
+ { 0x7, 0x7, 223, 2471, -1, 34, 1, 57 },
+ { 0xe00001, 0xe00001, 223, -1, -1, 12, 1, 62 },
+ { 0x7, 0x7, 223, 2472, -1, 33, 1, 57 },
+ { 0x1e00001, 0x1e00001, 223, -1, -1, 12, 1, 52 },
+ { 0xf, 0xf, 223, 2473, -1, 33, 1, 52 },
+ { 0xc00001, 0xc00001, 223, -1, -1, 12, 1, 62 },
+ { 0x3, 0x3, 223, 2478, -1, 34, 1, 57 },
+ { 0xe00001, 0x1e00001, 223, -1, -1, 12, 1, 62 },
+ { 0x7, 0xf, 223, 2479, -1, 33, 1, 57 },
+ { 0xc1, 0xc1, 223, -1, -1, 28, 1, 32 },
+ { 0x3, 0x3, 223, 2398, -1, 34, 1, 32 },
+ { 0x183, 0x183, 223, -1, -1, 27, 1, 32 },
+ { 0x181, 0x181, 223, 2399, -1, 27, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 65 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, 1876, -1, 34, 1, 32 },
+ { 0x7, 0x7, 223, -1, -1, 34, 1, 65 },
+ { 0xb, 0xb, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, 1877, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 65 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, 1880, -1, 34, 1, 32 },
+ { 0x7, 0x7, 223, -1, -1, 34, 1, 65 },
+ { 0xb, 0xb, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, 1881, -1, 34, 1, 32 },
+ { 0x7, 0x7, 223, -1, -1, 34, 1, 65 },
+ { 0xb, 0xb, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, 1883, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 65 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, 1885, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 65 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, 1886, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 52 },
+ { 0x181, 0x181, 223, -1, -1, 27, 1, 52 },
+ { 0xc1, 0xc1, 223, -1, -1, 28, 1, 52 },
+ { 0x183, 0x183, 223, -1, -1, 27, 1, 52 },
+ { 0x61, 0x61, 223, -1, -1, 29, 1, 52 },
+ { 0x185, 0x185, 223, -1, -1, 27, 1, 52 },
+ { 0xc3, 0xc3, 223, -1, -1, 28, 1, 52 },
+ { 0x187, 0x187, 223, -1, -1, 27, 1, 52 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 52 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 52 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 52 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 52 },
+ { 0xc1, 0xc1, 223, -1, -1, 28, 1, 32 },
+ { 0x3, 0x3, 223, 2402, -1, 34, 1, 32 },
+ { 0x183, 0x183, 223, -1, -1, 27, 1, 32 },
+ { 0x181, 0x181, 223, 2403, -1, 27, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 27 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 27 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 27 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 27 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 38 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 65 },
+ { 0x3, 0x3, 223, -1, -1, 34, 1, 32 },
+ { 0x3, 0x3, 223, 1888, -1, 34, 1, 32 },
+ { 0x3, 0x3, 224, 401, 1210, 32, 1, 128 },
+ { 0x3, 0x3, 224, 402, 1219, 32, 1, 128 },
+ { 0x3, 0x3, 224, 403, 1228, 32, 1, 128 },
+ { 0x3, 0x3, 224, 404, 1239, 32, 1, 128 },
+ { 0x3, 0x3, 224, 405, 1248, 32, 1, 128 },
+ { 0x3, 0x3, 224, 406, 1257, 32, 1, 128 },
+ { 0x3, 0x3, 224, 407, 1266, 32, 1, 128 },
+ { 0x3, 0x3, 224, 408, 1275, 32, 1, 128 },
+ { 0x3, 0x3, 224, 409, 1284, 32, 1, 128 },
+ { 0x3, 0x3, 224, 410, 1293, 32, 1, 128 },
+ { 0x3, 0x3, 224, 411, 1303, 32, 1, 128 },
+ { 0x3, 0x3, 224, 412, 1313, 32, 1, 128 },
+ { 0x3, 0x3, 224, 425, 1326, 32, 1, 143 },
+ { 0x3, 0x3, 224, 426, 1332, 32, 1, 143 },
+ { 0x3, 0x3, 224, 427, 1338, 32, 1, 143 },
+ { 0x3, 0x3, 224, 428, 1344, 32, 1, 143 },
+ { 0x3, 0x3, 224, 429, 1350, 32, 1, 143 },
+ { 0x3, 0x3, 224, 430, 1356, 32, 1, 143 },
+ { 0x3, 0x3, 224, 431, 1362, 32, 1, 143 },
+ { 0x3, 0x3, 224, 432, 1368, 32, 1, 143 },
+ { 0x3, 0x3, 224, 433, 1374, 32, 1, 143 },
+ { 0x3, 0x3, 224, 434, 1380, 32, 1, 143 },
+ { 0x3, 0x3, 224, 435, 1386, 32, 1, 143 },
+ { 0x3, 0x3, 224, 436, 1392, 32, 1, 143 },
+ { 0x3, 0x3, 224, 437, 1398, 32, 1, 143 },
+ { 0x3, 0x3, 224, 438, 1404, 32, 1, 143 },
+ { 0x3, 0x3, 224, 439, 1410, 32, 1, 143 },
+ { 0x3, 0x3, 224, 440, 1416, 32, 1, 143 },
+ { 0x3, 0x3, 224, 441, 1422, 32, 1, 143 },
+ { 0x3, 0x3, 224, 442, 1428, 32, 1, 143 },
+ { 0x1, 0x1, 225, -1, -1, 28, 1, 33 },
+ { 0x1, 0x1, 225, -1, -1, 28, 1, 33 },
+ { 0x0, 0x0, 232, 810, -1, 0, 1, 137 },
+ { 0x0, 0x0, 232, 811, -1, 0, 1, 150 },
+ { 0x1, 0x1, 233, -1, 1725, 33, 1, 133 },
+ { 0x1, 0x1, 233, -1, 1728, 33, 1, 139 },
+ { 0x0, 0x0, 233, -1, 1730, 0, 1, 145 },
+ { 0x0, 0x0, 233, -1, 1731, 0, 1, 145 },
+ { 0x0, 0x0, 234, 744, 823, 0, 0, -1 },
+ { 0x0, 0x0, 234, 745, 831, 0, 0, -1 },
+ { 0x0, 0x0, 234, 746, 827, 0, 0, -1 },
+ { 0x1, 0x1, 234, 747, 481, 33, 1, 6 },
+ { 0x8000001, 0x8000001, 234, 748, 489, 6, 1, 7 },
+ { 0x1, 0x1, 234, 749, 485, 33, 1, 6 },
+ { 0x0, 0x0, 234, 750, 835, 0, 0, -1 },
+ { 0x1, 0x1, 234, 751, 501, 33, 1, 8 },
+ { 0x0, 0x0, 234, 752, 839, 0, 0, -1 },
+ { 0x1, 0x1, 234, 753, 513, 33, 1, 15 },
+ { 0x0, 0x0, 234, 754, 844, 0, 0, -1 },
+ { 0x0, 0x0, 234, 755, 848, 0, 0, -1 },
+ { 0x1, 0x1, 234, 756, 536, 33, 1, 17 },
+ { 0x1, 0x1, 234, 757, 540, 33, 1, 17 },
+ { 0x0, 0x0, 234, 758, 852, 0, 0, -1 },
+ { 0x0, 0x0, 234, 759, 856, 0, 0, -1 },
+ { 0x1, 0x1, 234, 760, 560, 33, 1, 18 },
+ { 0x8000001, 0x8000001, 234, 761, 564, 6, 1, 18 },
+ { 0x0, 0x0, 234, 762, 860, 0, 0, -1 },
+ { 0x1, 0x1, 234, 763, 576, 33, 1, 19 },
+ { 0x0, 0x0, 234, 764, 864, 0, 0, -1 },
+ { 0x0, 0x0, 234, 765, 868, 0, 0, -1 },
+ { 0x1, 0x1, 234, 766, 596, 33, 1, 20 },
+ { 0x8000001, 0x8000001, 234, 767, 600, 6, 1, 20 },
+ { 0x0, 0x0, 234, 768, 872, 0, 0, -1 },
+ { 0x1, 0x1, 234, 769, 612, 33, 1, 21 },
+ { 0x0, 0x0, 234, 770, 877, 0, 0, -1 },
+ { 0x0, 0x0, 234, 771, 881, 0, 0, -1 },
+ { 0x1, 0x1, 234, 772, 635, 33, 1, 17 },
+ { 0x1, 0x1, 234, 773, 639, 33, 1, 17 },
+ { 0x0, 0x0, 234, 774, 885, 0, 0, -1 },
+ { 0x1, 0x1, 234, 775, 651, 33, 1, 21 },
+ { 0x0, 0x0, 235, 2323, 822, 0, 0, -1 },
+ { 0x0, 0x0, 235, 2324, 830, 0, 0, -1 },
+ { 0x0, 0x0, 235, 2325, 826, 0, 0, -1 },
+ { 0x0, 0x0, 235, 2326, 480, 0, 1, 6 },
+ { 0x1, 0x1, 235, 2327, 488, 6, 1, 7 },
+ { 0x0, 0x0, 235, 2328, 484, 0, 1, 6 },
+ { 0x0, 0x0, 235, 2329, 834, 0, 0, -1 },
+ { 0x0, 0x0, 235, 2330, 500, 0, 1, 8 },
+ { 0x0, 0x0, 235, 2331, 838, 0, 0, -1 },
+ { 0x0, 0x0, 235, 2332, 512, 0, 1, 15 },
+ { 0x0, 0x0, 235, 2333, 843, 0, 0, -1 },
+ { 0x0, 0x0, 235, 2334, 847, 0, 0, -1 },
+ { 0x0, 0x0, 235, 2335, 535, 0, 1, 17 },
+ { 0x0, 0x0, 235, 2336, 539, 0, 1, 17 },
+ { 0x0, 0x0, 235, 2337, 851, 0, 0, -1 },
+ { 0x0, 0x0, 235, 2338, 855, 0, 0, -1 },
+ { 0x0, 0x0, 235, 2339, 559, 0, 1, 18 },
+ { 0x1, 0x1, 235, 2340, 563, 6, 1, 18 },
+ { 0x0, 0x0, 235, 2341, 859, 0, 0, -1 },
+ { 0x0, 0x0, 235, 2342, 575, 0, 1, 19 },
+ { 0x0, 0x0, 235, 2343, 863, 0, 0, -1 },
+ { 0x0, 0x0, 235, 2344, 867, 0, 0, -1 },
+ { 0x0, 0x0, 235, 2345, 595, 0, 1, 20 },
+ { 0x1, 0x1, 235, 2346, 599, 6, 1, 20 },
+ { 0x0, 0x0, 235, 2347, 871, 0, 0, -1 },
+ { 0x0, 0x0, 235, 2348, 611, 0, 1, 21 },
+ { 0x0, 0x0, 235, 2349, 876, 0, 0, -1 },
+ { 0x0, 0x0, 235, 2350, 880, 0, 0, -1 },
+ { 0x0, 0x0, 235, 2351, 634, 0, 1, 17 },
+ { 0x0, 0x0, 235, 2352, 638, 0, 1, 17 },
+ { 0x0, 0x0, 235, 2353, 884, 0, 0, -1 },
+ { 0x0, 0x0, 235, 2354, 650, 0, 1, 21 },
+ { 0x1, 0x1, 235, 776, 973, 27, 1, 16 },
+ { 0x0, 0x0, 235, 777, 971, 0, 1, 16 },
+ { 0x0, 0x0, 235, 1021, 975, 0, 1, 22 },
+ { 0x0, 0x1, 235, 983, 981, 20, 1, 67 },
+ { 0x0, 0x0, 235, 110, 979, 0, 1, 67 },
+ { 0x1, 0x1, 238, -1, -1, 29, 1, 0 },
+ { 0x0, 0x0, 238, -1, -1, 0, 1, 0 },
+ { 0x1, 0x1, 238, 2495, -1, 27, 1, 0 },
+ { 0x1, 0x1, 238, 2496, -1, 27, 1, 0 },
+ { 0x1, 0x1, 238, 2497, -1, 27, 1, 0 },
+ { 0x1, 0x1, 238, 2498, -1, 27, 1, 0 },
+ { 0x0, 0x0, 260, -1, 1952, 0, 0, -1 },
+ { 0x0, 0x0, 260, -1, 1954, 0, 0, -1 },
+ { 0x1, 0x1, 260, -1, -1, 28, 1, 29 },
+ { 0x1, 0x1, 260, -1, -1, 28, 1, 29 },
+ { 0x0, 0x0, 260, -1, 1993, 0, 0, -1 },
+ { 0x0, 0x0, 260, -1, 1995, 0, 0, -1 },
+ { 0x1, 0x1, 260, -1, -1, 28, 1, 29 },
+ { 0x1, 0x1, 260, -1, -1, 28, 1, 29 },
+ { 0x0, 0x0, 262, 22, -1, 0, 1, 0 },
+ { 0x0, 0x0, 262, -1, -1, 0, 1, 0 },
+ { 0x0, 0x0, 262, -1, -1, 0, 1, 0 },
+ { 0x0, 0x1, 262, -1, -1, 29, 1, 0 },
+ { 0x0, 0x1, 262, -1, -1, 29, 1, 0 },
+ { 0x0, 0x1, 262, -1, -1, 29, 1, 0 },
+ { 0x0, 0x1, 262, -1, -1, 29, 1, 0 },
+ { 0x0, 0x1, 262, -1, -1, 29, 1, 0 },
+ { 0x0, 0x0, 262, 178, -1, 0, 1, 0 },
+ { 0x0, 0x1, 262, -1, -1, 29, 1, 0 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 64 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 64 },
+ { 0x0, 0x0, 263, -1, 1928, 0, 0, -1 },
+ { 0x0, 0x0, 263, -1, 1930, 0, 0, -1 },
+ { 0x0, 0x0, 263, -1, 1932, 0, 0, -1 },
+ { 0x0, 0x0, 263, -1, 1934, 0, 0, -1 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 59 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 59 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 59 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 49 },
+ { 0x0, 0x0, 263, -1, 1936, 0, 0, -1 },
+ { 0x0, 0x0, 263, -1, 1938, 0, 0, -1 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 59 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 59 },
+ { 0x0, 0x0, 263, -1, 1940, 0, 0, -1 },
+ { 0x0, 0x0, 263, -1, 1942, 0, 0, -1 },
+ { 0x0, 0x0, 263, -1, 1944, 0, 0, -1 },
+ { 0x0, 0x0, 263, -1, 1946, 0, 0, -1 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 59 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 59 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 59 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 49 },
+ { 0x0, 0x0, 263, -1, 1948, 0, 0, -1 },
+ { 0x0, 0x0, 263, -1, 1950, 0, 0, -1 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 59 },
+ { 0x1, 0x1, 263, -1, -1, 12, 1, 59 },
+ { 0x1, 0x1, 263, 334, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, 392, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, 338, -1, 12, 1, 2 },
+ { 0x1, 0x1, 263, 396, -1, 12, 1, 2 },
+ { 0x0, 0x0, 264, -1, 1935, 0, 0, -1 },
+ { 0x9, 0x9, 264, -1, 2465, 33, 1, 49 },
+ { 0x0, 0x0, 264, 1173, 1984, 0, 0, -1 },
+ { 0x3, 0x3, 264, 1174, -1, 27, 1, 49 },
+ { 0x0, 0x0, 268, 2392, -1, 0, 1, 0 },
+ { 0x3, 0x3, 269, -1, -1, 27, 1, 0 },
+ { 0x3, 0x3, 269, -1, -1, 27, 1, 0 },
+ { 0x3, 0x3, 269, -1, -1, 27, 1, 0 },
+ { 0x3, 0x3, 269, -1, -1, 27, 1, 0 },
+ { 0x1, 0x1, 270, 2491, -1, 28, 1, 0 },
+ { 0x1, 0x1, 270, 2492, -1, 28, 1, 0 },
+ { 0x1, 0x1, 270, 2493, -1, 28, 1, 0 },
+ { 0x1, 0x1, 270, 2494, -1, 28, 1, 0 },
+ { 0x1, 0x1, 271, -1, -1, 27, 1, 93 },
+ { 0x1, 0x1, 271, -1, -1, 27, 1, 93 },
+ { 0x0, 0x0, 271, -1, 820, 0, 0, -1 },
+ { 0x0, 0x0, 272, 2504, 2369, 0, 0, -1 },
+ { 0x0, 0x0, 272, 2505, 2371, 0, 0, -1 },
+ { 0x0, 0x0, 273, -1, 2370, 0, 0, -1 },
+ { 0x0, 0x0, 273, -1, 2372, 0, 0, -1 },
+ { 0x0, 0x0, 274, -1, -1, 0, 1, 40 },
+ { 0x0, 0x0, 274, -1, -1, 0, 1, 40 },
+ { 0x0, 0x0, 274, -1, -1, 0, 1, 40 },
+ { 0x0, 0x0, 279, -1, -1, 0, 1, 33 },
+ { 0x0, 0x0, 283, -1, 1958, 0, 1, 29 },
+ { 0x0, 0x0, 284, -1, -1, 0, 1, 0 },
+ { 0x0, 0x0, 284, -1, -1, 0, 1, 71 },
+ { 0x0, 0x0, 284, 1744, 2482, 0, 1, 1 },
+ { 0x0, 0x0, 284, -1, 393, 0, 0, -1 },
+ { 0x0, 0x0, 284, 1746, 2484, 0, 1, 1 },
+ { 0x0, 0x0, 284, -1, 397, 0, 0, -1 },
};
static const struct ia64_main_table
main_table[] = {
- { 5, 1, 1, 0x0000010000000000ull, 0x000001eff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 0, },
- { 5, 1, 1, 0x0000010008000000ull, 0x000001eff8000000ull, { 23, 24, 25, 3, 0 }, 0x0, 1, },
- { 5, 7, 1, 0x0000000000000000ull, 0x0000000000000000ull, { 23, 65, 26, 0, 0 }, 0x0, 2, },
- { 5, 7, 1, 0x0000000000000000ull, 0x0000000000000000ull, { 23, 62, 25, 0, 0 }, 0x0, 3, },
- { 6, 1, 1, 0x0000012000000000ull, 0x000001e000000000ull, { 23, 65, 26, 0, 0 }, 0x0, 4, },
- { 7, 1, 1, 0x0000010040000000ull, 0x000001eff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 5, },
- { 7, 1, 1, 0x0000010c00000000ull, 0x000001ee00000000ull, { 23, 62, 25, 0, 0 }, 0x0, 6, },
- { 8, 1, 1, 0x0000010800000000ull, 0x000001ee00000000ull, { 23, 62, 25, 0, 0 }, 0x0, 7, },
- { 9, 3, 1, 0x0000002c00000000ull, 0x000001ee00000000ull, { 23, 2, 51, 52, 53 }, 0x221, 8, },
- { 10, 1, 1, 0x0000010060000000ull, 0x000001eff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 9, },
- { 10, 1, 1, 0x0000010160000000ull, 0x000001eff8000000ull, { 23, 54, 25, 0, 0 }, 0x0, 10, },
- { 11, 1, 1, 0x0000010068000000ull, 0x000001eff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 11, },
- { 11, 1, 1, 0x0000010168000000ull, 0x000001eff8000000ull, { 23, 54, 25, 0, 0 }, 0x0, 12, },
- { 14, 4, 0, 0x0000000100000000ull, 0x000001eff80011ffull, { 15, 0, 0, 0, 0 }, 0x40, 814, },
- { 14, 4, 0, 0x0000000100000000ull, 0x000001eff80011c0ull, { 15, 0, 0, 0, 0 }, 0x0, 680, },
- { 14, 4, 0, 0x0000000100000000ull, 0x000001eff80011c0ull, { 15, 0, 0, 0, 0 }, 0x40, 681, },
- { 14, 4, 0, 0x0000000108000100ull, 0x000001eff80011c0ull, { 15, 0, 0, 0, 0 }, 0x200, 1843, },
- { 14, 4, 0, 0x0000000108000100ull, 0x000001eff80011c0ull, { 15, 0, 0, 0, 0 }, 0x240, 1844, },
- { 14, 4, 1, 0x0000002100000000ull, 0x000001ef00001000ull, { 14, 15, 0, 0, 0 }, 0x0, 437, },
- { 14, 4, 1, 0x0000002100000000ull, 0x000001ef00001000ull, { 14, 15, 0, 0, 0 }, 0x40, 438, },
- { 14, 4, 0, 0x0000008000000000ull, 0x000001ee000011ffull, { 80, 0, 0, 0, 0 }, 0x40, 835, },
- { 14, 4, 0, 0x0000008000000000ull, 0x000001ee000011c0ull, { 80, 0, 0, 0, 0 }, 0x0, 682, },
- { 14, 4, 0, 0x0000008000000000ull, 0x000001ee000011c0ull, { 80, 0, 0, 0, 0 }, 0x40, 683, },
- { 14, 4, 0, 0x0000008000000080ull, 0x000001ee000011c0ull, { 80, 0, 0, 0, 0 }, 0x210, 2479, },
- { 14, 4, 0, 0x0000008000000080ull, 0x000001ee000011c0ull, { 80, 0, 0, 0, 0 }, 0x250, 2480, },
- { 14, 4, 0, 0x0000008000000140ull, 0x000001ee000011c0ull, { 80, 0, 0, 0, 0 }, 0x30, 445, },
- { 14, 4, 0, 0x0000008000000140ull, 0x000001ee000011c0ull, { 80, 0, 0, 0, 0 }, 0x70, 446, },
- { 14, 4, 0, 0x0000008000000180ull, 0x000001ee000011c0ull, { 80, 0, 0, 0, 0 }, 0x230, 443, },
- { 14, 4, 0, 0x0000008000000180ull, 0x000001ee000011c0ull, { 80, 0, 0, 0, 0 }, 0x270, 444, },
- { 14, 4, 1, 0x000000a000000000ull, 0x000001ee00001000ull, { 14, 80, 0, 0, 0 }, 0x0, 439, },
- { 14, 4, 1, 0x000000a000000000ull, 0x000001ee00001000ull, { 14, 80, 0, 0, 0 }, 0x40, 440, },
- { 15, 4, 0, 0x0000000000000000ull, 0x000001e1f8000000ull, { 64, 0, 0, 0, 0 }, 0x0, 393, },
- { 15, 5, 0, 0x0000000000000000ull, 0x000001e3f8000000ull, { 64, 0, 0, 0, 0 }, 0x0, 806, },
- { 15, 2, 0, 0x0000000000000000ull, 0x000001eff8000000ull, { 64, 0, 0, 0, 0 }, 0x2, 949, },
- { 15, 3, 0, 0x0000000000000000ull, 0x000001eff8000000ull, { 64, 0, 0, 0, 0 }, 0x0, 1038, },
- { 15, 6, 0, 0x0000000000000000ull, 0x000001eff8000000ull, { 68, 0, 0, 0, 0 }, 0x0, 2483, },
- { 15, 7, 0, 0x0000000000000000ull, 0x0000000000000000ull, { 64, 0, 0, 0, 0 }, 0x0, 15, },
- { 16, 6, 0, 0x0000018000000000ull, 0x000001ee000011ffull, { 81, 0, 0, 0, 0 }, 0x40, 868, },
- { 16, 6, 0, 0x0000018000000000ull, 0x000001ee000011c0ull, { 81, 0, 0, 0, 0 }, 0x0, 684, },
- { 16, 6, 0, 0x0000018000000000ull, 0x000001ee000011c0ull, { 81, 0, 0, 0, 0 }, 0x40, 685, },
- { 16, 6, 1, 0x000001a000000000ull, 0x000001ee00001000ull, { 14, 81, 0, 0, 0 }, 0x0, 441, },
- { 16, 6, 1, 0x000001a000000000ull, 0x000001ee00001000ull, { 14, 81, 0, 0, 0 }, 0x40, 442, },
- { 17, 4, 0, 0x0000004080000000ull, 0x000001e9f8000018ull, { 15, 76, 0, 0, 0 }, 0x20, 2365, },
- { 17, 4, 0, 0x000000e000000000ull, 0x000001e800000018ull, { 80, 76, 0, 0, 0 }, 0x20, 2366, },
- { 18, 4, 0, 0x0000000060000000ull, 0x000001e1f8000000ull, { 0, 0, 0, 0, 0 }, 0x2c, 216, },
- { 22, 2, 0, 0x0000000200000000ull, 0x000001ee00000000ull, { 24, 79, 0, 0, 0 }, 0x0, 1848, },
- { 22, 3, 0, 0x0000000800000000ull, 0x000001ee00000000ull, { 23, 80, 0, 0, 0 }, 0x0, 218, },
- { 22, 3, 0, 0x0000000c00000000ull, 0x000001ee00000000ull, { 17, 80, 0, 0, 0 }, 0x0, 219, },
- { 22, 3, 0, 0x0000002200000000ull, 0x000001ee00000000ull, { 24, 79, 0, 0, 0 }, 0x0, 1849, },
- { 22, 3, 0, 0x0000002600000000ull, 0x000001ee00000000ull, { 18, 79, 0, 0, 0 }, 0x0, 1850, },
- { 22, 7, 0, 0x0000000000000000ull, 0x0000000000000000ull, { 24, 79, 0, 0, 0 }, 0x0, 1851, },
+ { 5, 1, 1, 0x0000010000000000ull, 0x000001eff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 0, },
+ { 5, 1, 1, 0x0000010008000000ull, 0x000001eff8000000ull, { 24, 25, 26, 4, 0 }, 0x0, 1, },
+ { 5, 7, 1, 0x0000000000000000ull, 0x0000000000000000ull, { 24, 66, 27, 0, 0 }, 0x0, 2, },
+ { 5, 7, 1, 0x0000000000000000ull, 0x0000000000000000ull, { 24, 63, 26, 0, 0 }, 0x0, 3, },
+ { 6, 1, 1, 0x0000012000000000ull, 0x000001e000000000ull, { 24, 66, 27, 0, 0 }, 0x0, 4, },
+ { 7, 1, 1, 0x0000010040000000ull, 0x000001eff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 5, },
+ { 7, 1, 1, 0x0000010c00000000ull, 0x000001ee00000000ull, { 24, 63, 26, 0, 0 }, 0x0, 6, },
+ { 8, 1, 1, 0x0000010800000000ull, 0x000001ee00000000ull, { 24, 63, 26, 0, 0 }, 0x0, 7, },
+ { 9, 3, 1, 0x0000002c00000000ull, 0x000001ee00000000ull, { 24, 3, 52, 53, 54 }, 0x221, 8, },
+ { 10, 1, 1, 0x0000010060000000ull, 0x000001eff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 9, },
+ { 10, 1, 1, 0x0000010160000000ull, 0x000001eff8000000ull, { 24, 55, 26, 0, 0 }, 0x0, 10, },
+ { 11, 1, 1, 0x0000010068000000ull, 0x000001eff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 11, },
+ { 11, 1, 1, 0x0000010168000000ull, 0x000001eff8000000ull, { 24, 55, 26, 0, 0 }, 0x0, 12, },
+ { 14, 4, 0, 0x0000000100000000ull, 0x000001eff80011ffull, { 16, 0, 0, 0, 0 }, 0x40, 821, },
+ { 14, 4, 0, 0x0000000100000000ull, 0x000001eff80011c0ull, { 16, 0, 0, 0, 0 }, 0x0, 686, },
+ { 14, 4, 0, 0x0000000100000000ull, 0x000001eff80011c0ull, { 16, 0, 0, 0, 0 }, 0x40, 687, },
+ { 14, 4, 0, 0x0000000108000100ull, 0x000001eff80011c0ull, { 16, 0, 0, 0, 0 }, 0x200, 1866, },
+ { 14, 4, 0, 0x0000000108000100ull, 0x000001eff80011c0ull, { 16, 0, 0, 0, 0 }, 0x240, 1867, },
+ { 14, 4, 1, 0x0000002100000000ull, 0x000001ef00001000ull, { 15, 16, 0, 0, 0 }, 0x0, 443, },
+ { 14, 4, 1, 0x0000002100000000ull, 0x000001ef00001000ull, { 15, 16, 0, 0, 0 }, 0x40, 444, },
+ { 14, 4, 0, 0x0000008000000000ull, 0x000001ee000011ffull, { 81, 0, 0, 0, 0 }, 0x40, 842, },
+ { 14, 4, 0, 0x0000008000000000ull, 0x000001ee000011c0ull, { 81, 0, 0, 0, 0 }, 0x0, 688, },
+ { 14, 4, 0, 0x0000008000000000ull, 0x000001ee000011c0ull, { 81, 0, 0, 0, 0 }, 0x40, 689, },
+ { 14, 4, 0, 0x0000008000000080ull, 0x000001ee000011c0ull, { 81, 0, 0, 0, 0 }, 0x210, 2502, },
+ { 14, 4, 0, 0x0000008000000080ull, 0x000001ee000011c0ull, { 81, 0, 0, 0, 0 }, 0x250, 2503, },
+ { 14, 4, 0, 0x0000008000000140ull, 0x000001ee000011c0ull, { 81, 0, 0, 0, 0 }, 0x30, 451, },
+ { 14, 4, 0, 0x0000008000000140ull, 0x000001ee000011c0ull, { 81, 0, 0, 0, 0 }, 0x70, 452, },
+ { 14, 4, 0, 0x0000008000000180ull, 0x000001ee000011c0ull, { 81, 0, 0, 0, 0 }, 0x230, 449, },
+ { 14, 4, 0, 0x0000008000000180ull, 0x000001ee000011c0ull, { 81, 0, 0, 0, 0 }, 0x270, 450, },
+ { 14, 4, 1, 0x000000a000000000ull, 0x000001ee00001000ull, { 15, 81, 0, 0, 0 }, 0x0, 445, },
+ { 14, 4, 1, 0x000000a000000000ull, 0x000001ee00001000ull, { 15, 81, 0, 0, 0 }, 0x40, 446, },
+ { 15, 4, 0, 0x0000000000000000ull, 0x000001e1f8000000ull, { 65, 0, 0, 0, 0 }, 0x0, 398, },
+ { 15, 5, 0, 0x0000000000000000ull, 0x000001e3f8000000ull, { 65, 0, 0, 0, 0 }, 0x0, 812, },
+ { 15, 2, 0, 0x0000000000000000ull, 0x000001eff8000000ull, { 65, 0, 0, 0, 0 }, 0x2, 956, },
+ { 15, 3, 0, 0x0000000000000000ull, 0x000001eff8000000ull, { 65, 0, 0, 0, 0 }, 0x0, 1047, },
+ { 15, 6, 0, 0x0000000000000000ull, 0x000001eff8000000ull, { 69, 0, 0, 0, 0 }, 0x0, 2506, },
+ { 15, 7, 0, 0x0000000000000000ull, 0x0000000000000000ull, { 65, 0, 0, 0, 0 }, 0x0, 15, },
+ { 16, 6, 0, 0x0000018000000000ull, 0x000001ee000011ffull, { 82, 0, 0, 0, 0 }, 0x40, 875, },
+ { 16, 6, 0, 0x0000018000000000ull, 0x000001ee000011c0ull, { 82, 0, 0, 0, 0 }, 0x0, 690, },
+ { 16, 6, 0, 0x0000018000000000ull, 0x000001ee000011c0ull, { 82, 0, 0, 0, 0 }, 0x40, 691, },
+ { 16, 6, 1, 0x000001a000000000ull, 0x000001ee00001000ull, { 15, 82, 0, 0, 0 }, 0x0, 447, },
+ { 16, 6, 1, 0x000001a000000000ull, 0x000001ee00001000ull, { 15, 82, 0, 0, 0 }, 0x40, 448, },
+ { 17, 4, 0, 0x0000004080000000ull, 0x000001e9f8000018ull, { 16, 77, 0, 0, 0 }, 0x20, 2388, },
+ { 17, 4, 0, 0x000000e000000000ull, 0x000001e800000018ull, { 81, 77, 0, 0, 0 }, 0x20, 2389, },
+ { 18, 4, 0, 0x0000000060000000ull, 0x000001e1f8000000ull, { 0, 0, 0, 0, 0 }, 0x2c, 219, },
+ { 22, 2, 0, 0x0000000200000000ull, 0x000001ee00000000ull, { 25, 80, 0, 0, 0 }, 0x0, 1871, },
+ { 22, 3, 0, 0x0000000800000000ull, 0x000001ee00000000ull, { 24, 81, 0, 0, 0 }, 0x0, 221, },
+ { 22, 3, 0, 0x0000000c00000000ull, 0x000001ee00000000ull, { 18, 81, 0, 0, 0 }, 0x0, 222, },
+ { 22, 3, 0, 0x0000002200000000ull, 0x000001ee00000000ull, { 25, 80, 0, 0, 0 }, 0x0, 1872, },
+ { 22, 3, 0, 0x0000002600000000ull, 0x000001ee00000000ull, { 19, 80, 0, 0, 0 }, 0x0, 1873, },
+ { 22, 7, 0, 0x0000000000000000ull, 0x0000000000000000ull, { 25, 80, 0, 0, 0 }, 0x0, 1874, },
{ 25, 4, 0, 0x0000000020000000ull, 0x000001e1f8000000ull, { 0, 0, 0, 0, 0 }, 0x224, 17, },
- { 26, 1, 2, 0x0000018000000000ull, 0x000001fe00001000ull, { 21, 22, 24, 25, 0 }, 0x0, 1014, },
- { 26, 1, 2, 0x0000018000000000ull, 0x000001fe00001000ull, { 22, 21, 25, 24, 0 }, 0x0, 990, },
- { 26, 1, 2, 0x0000018000000000ull, 0x000001fe00001000ull, { 21, 22, 25, 24, 0 }, 0x0, 918, },
- { 26, 1, 2, 0x0000018000000000ull, 0x000001fe00001000ull, { 22, 21, 24, 25, 0 }, 0x0, 897, },
- { 26, 1, 2, 0x0000018200000000ull, 0x000001fe00001000ull, { 21, 22, 24, 25, 0 }, 0x40, 1146, },
- { 26, 1, 2, 0x0000019000000000ull, 0x000001fe00001000ull, { 21, 22, 6, 25, 0 }, 0x0, 919, },
- { 26, 1, 2, 0x0000019000000000ull, 0x000001fe00001000ull, { 21, 22, 25, 6, 0 }, 0x40, 1016, },
- { 26, 1, 2, 0x0000019000000000ull, 0x000001fe00001000ull, { 21, 22, 6, 25, 0 }, 0x40, 993, },
- { 26, 1, 2, 0x0000018800000000ull, 0x000001ee00001000ull, { 21, 22, 54, 25, 0 }, 0x0, 1018, },
- { 26, 1, 2, 0x0000018800000000ull, 0x000001ee00001000ull, { 21, 22, 56, 25, 0 }, 0x0, 994, },
- { 26, 1, 2, 0x0000018800000000ull, 0x000001ee00001000ull, { 22, 21, 56, 25, 0 }, 0x0, 922, },
- { 26, 1, 2, 0x0000018800000000ull, 0x000001ee00001000ull, { 22, 21, 54, 25, 0 }, 0x0, 901, },
- { 26, 1, 2, 0x0000018a00000000ull, 0x000001ee00001000ull, { 21, 22, 54, 25, 0 }, 0x40, 1149, },
- { 26, 1, 2, 0x000001a800000000ull, 0x000001ee00001000ull, { 21, 22, 58, 25, 0 }, 0x0, 1009, },
- { 26, 1, 2, 0x000001a800000000ull, 0x000001ee00001000ull, { 22, 21, 58, 25, 0 }, 0x0, 939, },
- { 26, 1, 2, 0x000001c200000000ull, 0x000001fe00001000ull, { 22, 21, 24, 25, 0 }, 0x40, 1150, },
- { 26, 1, 2, 0x000001d000000000ull, 0x000001fe00001000ull, { 22, 21, 6, 25, 0 }, 0x40, 995, },
- { 26, 1, 2, 0x000001d000000000ull, 0x000001fe00001000ull, { 22, 21, 25, 6, 0 }, 0x40, 903, },
- { 26, 1, 2, 0x000001ca00000000ull, 0x000001ee00001000ull, { 22, 21, 54, 25, 0 }, 0x40, 1151, },
- { 27, 1, 2, 0x0000018400000000ull, 0x000001fe00001000ull, { 21, 22, 24, 25, 0 }, 0x0, 1021, },
- { 27, 1, 2, 0x0000018400000000ull, 0x000001fe00001000ull, { 22, 21, 25, 24, 0 }, 0x0, 997, },
- { 27, 1, 2, 0x0000018400000000ull, 0x000001fe00001000ull, { 21, 22, 25, 24, 0 }, 0x0, 925, },
- { 27, 1, 2, 0x0000018400000000ull, 0x000001fe00001000ull, { 22, 21, 24, 25, 0 }, 0x0, 904, },
- { 27, 1, 2, 0x0000018600000000ull, 0x000001fe00001000ull, { 21, 22, 24, 25, 0 }, 0x40, 1154, },
- { 27, 1, 2, 0x0000019400000000ull, 0x000001fe00001000ull, { 21, 22, 6, 25, 0 }, 0x0, 926, },
- { 27, 1, 2, 0x0000019400000000ull, 0x000001fe00001000ull, { 21, 22, 25, 6, 0 }, 0x40, 1023, },
- { 27, 1, 2, 0x0000019400000000ull, 0x000001fe00001000ull, { 21, 22, 6, 25, 0 }, 0x40, 1000, },
- { 27, 1, 2, 0x0000018c00000000ull, 0x000001ee00001000ull, { 21, 22, 54, 25, 0 }, 0x0, 1025, },
- { 27, 1, 2, 0x0000018c00000000ull, 0x000001ee00001000ull, { 21, 22, 56, 25, 0 }, 0x0, 1001, },
- { 27, 1, 2, 0x0000018c00000000ull, 0x000001ee00001000ull, { 22, 21, 56, 25, 0 }, 0x0, 929, },
- { 27, 1, 2, 0x0000018c00000000ull, 0x000001ee00001000ull, { 22, 21, 54, 25, 0 }, 0x0, 908, },
- { 27, 1, 2, 0x0000018e00000000ull, 0x000001ee00001000ull, { 21, 22, 54, 25, 0 }, 0x40, 1157, },
- { 27, 1, 2, 0x000001ac00000000ull, 0x000001ee00001000ull, { 21, 22, 55, 25, 0 }, 0x0, 1035, },
- { 27, 1, 2, 0x000001ac00000000ull, 0x000001ee00001000ull, { 21, 22, 57, 25, 0 }, 0x0, 1011, },
- { 27, 1, 2, 0x000001ac00000000ull, 0x000001ee00001000ull, { 22, 21, 57, 25, 0 }, 0x0, 941, },
- { 27, 1, 2, 0x000001ac00000000ull, 0x000001ee00001000ull, { 22, 21, 55, 25, 0 }, 0x0, 917, },
- { 27, 1, 2, 0x000001c600000000ull, 0x000001fe00001000ull, { 22, 21, 24, 25, 0 }, 0x40, 1158, },
- { 27, 1, 2, 0x000001d400000000ull, 0x000001fe00001000ull, { 22, 21, 6, 25, 0 }, 0x40, 1002, },
- { 27, 1, 2, 0x000001d400000000ull, 0x000001fe00001000ull, { 22, 21, 25, 6, 0 }, 0x40, 910, },
- { 27, 1, 2, 0x000001ce00000000ull, 0x000001ee00001000ull, { 22, 21, 54, 25, 0 }, 0x40, 1159, },
- { 28, 3, 1, 0x0000008008000000ull, 0x000001fff8000000ull, { 23, 32, 24, 1, 0 }, 0x0, 251, },
- { 29, 3, 1, 0x0000008048000000ull, 0x000001fff8000000ull, { 23, 32, 24, 1, 0 }, 0x0, 252, },
- { 30, 3, 1, 0x0000008088000000ull, 0x000001fff8000000ull, { 23, 32, 24, 1, 0 }, 0x0, 253, },
- { 31, 3, 1, 0x00000080c8000000ull, 0x000001fff8000000ull, { 23, 32, 24, 1, 0 }, 0x0, 254, },
- { 33, 4, 0, 0x0000000010000000ull, 0x000001e1f8000000ull, { 0, 0, 0, 0, 0 }, 0x224, 18, },
- { 35, 2, 1, 0x00000000c0000000ull, 0x000001eff8000000ull, { 23, 25, 0, 0, 0 }, 0x0, 976, },
- { 36, 2, 1, 0x00000000c8000000ull, 0x000001eff8000000ull, { 23, 25, 0, 0, 0 }, 0x0, 977, },
- { 38, 2, 1, 0x0000008000000000ull, 0x000001e000000000ull, { 23, 24, 25, 46, 71 }, 0x0, 19, },
- { 38, 2, 1, 0x000000a600000000ull, 0x000001ee04000000ull, { 23, 24, 44, 72, 0 }, 0x0, 2487, },
- { 38, 2, 1, 0x000000a604000000ull, 0x000001ee04000000ull, { 23, 54, 44, 72, 0 }, 0x0, 2488, },
- { 38, 2, 1, 0x000000ae00000000ull, 0x000001ee00000000ull, { 23, 47, 25, 45, 72 }, 0x0, 20, },
- { 42, 4, 0, 0x0000000080000000ull, 0x000001e1f8000000ull, { 0, 0, 0, 0, 0 }, 0x20, 21, },
- { 47, 2, 1, 0x000000a400000000ull, 0x000001ee00002000ull, { 23, 25, 75, 72, 0 }, 0x0, 2383, },
- { 49, 5, 1, 0x0000000080000000ull, 0x000001e3f80fe000ull, { 17, 19, 0, 0, 0 }, 0x40, 23, },
- { 50, 5, 1, 0x0000010008000000ull, 0x000001fff8000000ull, { 17, 19, 18, 0, 0 }, 0x40, 1900, },
- { 51, 5, 1, 0x00000000b8000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 1901, },
- { 51, 5, 1, 0x00000000b8000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x40, 25, },
- { 52, 5, 1, 0x00000000b0000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 1902, },
- { 52, 5, 1, 0x00000000b0000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x40, 26, },
- { 53, 5, 1, 0x0000000160000000ull, 0x000001e3f8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 27, },
- { 54, 5, 1, 0x0000000168000000ull, 0x000001e3f8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 28, },
- { 56, 3, 0, 0x0000002180000000ull, 0x000001eff8000000ull, { 25, 0, 0, 0, 0 }, 0x0, 29, },
- { 57, 5, 0, 0x0000000040000000ull, 0x000001eff8000000ull, { 78, 0, 0, 0, 0 }, 0x0, 1903, },
- { 57, 5, 0, 0x0000000040000000ull, 0x000001eff8000000ull, { 78, 0, 0, 0, 0 }, 0x40, 30, },
- { 58, 5, 2, 0x000000a000000000ull, 0x000001e000001000ull, { 21, 22, 18, 59, 0 }, 0x0, 1040, },
- { 58, 5, 2, 0x000000a000000000ull, 0x000001e000001000ull, { 22, 21, 18, 59, 0 }, 0x40, 1179, },
- { 59, 5, 0, 0x0000000028000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x0, 1904, },
- { 59, 5, 0, 0x0000000028000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x40, 31, },
- { 60, 5, 2, 0x0000008000000000ull, 0x000001fe00001000ull, { 21, 22, 18, 19, 0 }, 0x0, 790, },
- { 60, 5, 2, 0x0000008000000000ull, 0x000001fe00001000ull, { 21, 22, 18, 19, 0 }, 0x40, 791, },
- { 60, 5, 2, 0x0000009000000000ull, 0x000001fe00001000ull, { 21, 22, 19, 18, 0 }, 0x0, 932, },
- { 60, 5, 2, 0x0000009000000000ull, 0x000001fe00001000ull, { 21, 22, 19, 18, 0 }, 0x40, 933, },
- { 60, 5, 2, 0x0000008000000000ull, 0x000001fe00001000ull, { 22, 21, 18, 19, 0 }, 0x0, 1160, },
- { 60, 5, 2, 0x0000008000000000ull, 0x000001fe00001000ull, { 22, 21, 18, 19, 0 }, 0x40, 1161, },
- { 60, 5, 2, 0x0000009000000000ull, 0x000001fe00001000ull, { 22, 21, 19, 18, 0 }, 0x0, 1167, },
- { 60, 5, 2, 0x0000009000000000ull, 0x000001fe00001000ull, { 22, 21, 19, 18, 0 }, 0x40, 1168, },
- { 61, 5, 1, 0x00000000c0000000ull, 0x000001eff8000000ull, { 17, 18, 0, 0, 0 }, 0x0, 887, },
- { 61, 5, 1, 0x00000000c0000000ull, 0x000001eff8000000ull, { 17, 18, 0, 0, 0 }, 0x40, 888, },
- { 61, 5, 1, 0x00000000e0000000ull, 0x000001e3f8000000ull, { 17, 18, 0, 0, 0 }, 0x0, 2485, },
- { 61, 5, 1, 0x0000010008000000ull, 0x000001fff80fe000ull, { 17, 19, 0, 0, 0 }, 0x40, 2486, },
- { 62, 3, 1, 0x0000008488000000ull, 0x000001fff8000000ull, { 23, 32, 70, 0, 0 }, 0x0, 255, },
- { 63, 3, 1, 0x00000084c8000000ull, 0x000001fff8000000ull, { 23, 32, 70, 0, 0 }, 0x0, 256, },
- { 66, 3, 0, 0x0000000060000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x21, 32, },
- { 67, 5, 1, 0x0000010000000000ull, 0x000001fc00000000ull, { 17, 19, 20, 18, 0 }, 0x0, 1938, },
- { 67, 5, 1, 0x0000010000000000ull, 0x000001fc00000000ull, { 17, 19, 20, 18, 0 }, 0x40, 33, },
- { 68, 5, 1, 0x00000000a8000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 1939, },
- { 68, 5, 1, 0x00000000a8000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x40, 34, },
- { 69, 5, 1, 0x0000000080000000ull, 0x000001e3f8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 1856, },
- { 70, 5, 1, 0x00000000a0000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 1940, },
- { 70, 5, 1, 0x00000000a0000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x40, 35, },
- { 71, 5, 1, 0x00000001c8000000ull, 0x000001e3f8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 1013, },
- { 72, 5, 1, 0x0000010000000000ull, 0x000001fc000fe000ull, { 17, 19, 20, 0, 0 }, 0x40, 1943, },
- { 73, 5, 1, 0x0000014000000000ull, 0x000001fc00000000ull, { 17, 19, 20, 18, 0 }, 0x0, 1946, },
- { 73, 5, 1, 0x0000014000000000ull, 0x000001fc00000000ull, { 17, 19, 20, 18, 0 }, 0x40, 37, },
- { 74, 5, 1, 0x0000000088000000ull, 0x000001e3f8000000ull, { 17, 19, 0, 0, 0 }, 0xc0, 38, },
- { 75, 5, 1, 0x0000000088000000ull, 0x000001e3f80fe000ull, { 17, 19, 0, 0, 0 }, 0x40, 39, },
- { 76, 5, 1, 0x0000018000000000ull, 0x000001fc00000000ull, { 17, 19, 20, 18, 0 }, 0x0, 1949, },
- { 76, 5, 1, 0x0000018000000000ull, 0x000001fc00000000ull, { 17, 19, 20, 18, 0 }, 0x40, 40, },
- { 77, 5, 1, 0x0000018000000000ull, 0x000001fc000fe000ull, { 17, 19, 20, 0, 0 }, 0x40, 1952, },
- { 78, 5, 1, 0x0000010008000000ull, 0x000001fff80fe000ull, { 17, 19, 0, 0, 0 }, 0x40, 1955, },
- { 79, 5, 1, 0x0000000170000000ull, 0x000001e3f8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 43, },
- { 80, 5, 1, 0x0000002080000000ull, 0x000001e3f80fe000ull, { 17, 19, 0, 0, 0 }, 0x40, 44, },
- { 81, 5, 1, 0x0000000140000000ull, 0x000001e3f8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 45, },
- { 82, 5, 1, 0x00000020b8000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 1956, },
- { 82, 5, 1, 0x00000020b8000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x40, 46, },
- { 83, 5, 1, 0x00000020b0000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 1957, },
- { 83, 5, 1, 0x00000020b0000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x40, 47, },
- { 84, 5, 1, 0x0000002180000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 792, },
- { 84, 5, 1, 0x0000002180000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x40, 793, },
- { 84, 5, 1, 0x0000002188000000ull, 0x000001eff8000000ull, { 17, 19, 18, 0, 0 }, 0x40, 934, },
- { 85, 5, 1, 0x00000020c0000000ull, 0x000001eff8000000ull, { 17, 18, 0, 0, 0 }, 0x0, 889, },
- { 85, 5, 1, 0x00000020c0000000ull, 0x000001eff8000000ull, { 17, 18, 0, 0, 0 }, 0x40, 890, },
- { 86, 5, 1, 0x0000013000000000ull, 0x000001fc00000000ull, { 17, 19, 20, 18, 0 }, 0x0, 1974, },
- { 86, 5, 1, 0x0000013000000000ull, 0x000001fc00000000ull, { 17, 19, 20, 18, 0 }, 0x40, 48, },
- { 87, 5, 1, 0x00000020a8000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 1975, },
- { 87, 5, 1, 0x00000020a8000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x40, 49, },
- { 88, 5, 1, 0x0000002080000000ull, 0x000001e3f8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 1864, },
- { 89, 5, 1, 0x00000020a0000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 1976, },
- { 89, 5, 1, 0x00000020a0000000ull, 0x000001eff8000000ull, { 17, 18, 19, 0, 0 }, 0x40, 50, },
- { 90, 5, 1, 0x0000013000000000ull, 0x000001fc000fe000ull, { 17, 19, 20, 0, 0 }, 0x40, 1977, },
- { 91, 5, 1, 0x0000017000000000ull, 0x000001fc00000000ull, { 17, 19, 20, 18, 0 }, 0x0, 1978, },
- { 91, 5, 1, 0x0000017000000000ull, 0x000001fc00000000ull, { 17, 19, 20, 18, 0 }, 0x40, 52, },
- { 92, 5, 1, 0x0000002088000000ull, 0x000001e3f8000000ull, { 17, 19, 0, 0, 0 }, 0xc0, 53, },
- { 93, 5, 1, 0x0000002088000000ull, 0x000001e3f80fe000ull, { 17, 19, 0, 0, 0 }, 0x40, 54, },
- { 94, 5, 1, 0x000001b000000000ull, 0x000001fc00000000ull, { 17, 19, 20, 18, 0 }, 0x0, 1979, },
- { 94, 5, 1, 0x000001b000000000ull, 0x000001fc00000000ull, { 17, 19, 20, 18, 0 }, 0x40, 55, },
- { 95, 5, 1, 0x000001b000000000ull, 0x000001fc000fe000ull, { 17, 19, 20, 0, 0 }, 0x40, 1980, },
- { 96, 5, 2, 0x0000002200000000ull, 0x000001fe00000000ull, { 17, 22, 18, 19, 0 }, 0x0, 1981, },
- { 96, 5, 2, 0x0000002200000000ull, 0x000001fe00000000ull, { 17, 22, 18, 19, 0 }, 0x40, 57, },
- { 97, 5, 2, 0x0000003200000000ull, 0x000001fe00000000ull, { 17, 22, 19, 0, 0 }, 0x0, 1982, },
- { 97, 5, 2, 0x0000003200000000ull, 0x000001fe00000000ull, { 17, 22, 19, 0, 0 }, 0x40, 58, },
- { 98, 5, 2, 0x0000000200000000ull, 0x000001fe00000000ull, { 17, 22, 18, 19, 0 }, 0x0, 1983, },
- { 98, 5, 2, 0x0000000200000000ull, 0x000001fe00000000ull, { 17, 22, 18, 19, 0 }, 0x40, 59, },
- { 99, 5, 2, 0x0000001200000000ull, 0x000001fe00000000ull, { 17, 22, 19, 0, 0 }, 0x0, 1984, },
- { 99, 5, 2, 0x0000001200000000ull, 0x000001fe00000000ull, { 17, 22, 19, 0, 0 }, 0x40, 60, },
- { 100, 5, 1, 0x000001c000000000ull, 0x000001f000000000ull, { 17, 19, 20, 18, 0 }, 0x0, 61, },
- { 101, 5, 0, 0x0000000020000000ull, 0x000001eff8000000ull, { 49, 50, 0, 0, 0 }, 0x0, 1985, },
- { 101, 5, 0, 0x0000000020000000ull, 0x000001eff8000000ull, { 49, 50, 0, 0, 0 }, 0x40, 62, },
- { 102, 5, 1, 0x0000014008000000ull, 0x000001fff8000000ull, { 17, 19, 18, 0, 0 }, 0x40, 1988, },
- { 103, 5, 1, 0x00000001a0000000ull, 0x000001e3f8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 64, },
- { 104, 5, 1, 0x00000001e0000000ull, 0x000001e3f8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 1819, },
- { 105, 3, 0, 0x0000000100000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x0, 65, },
- { 107, 5, 1, 0x0000000178000000ull, 0x000001e3f8000000ull, { 17, 18, 19, 0, 0 }, 0x0, 66, },
- { 112, 3, 1, 0x0000008708000000ull, 0x000001ffc8000000ull, { 23, 18, 0, 0, 0 }, 0x0, 2294, },
- { 121, 3, 0, 0x0000000080000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x0, 67, },
- { 121, 3, 0, 0x0000000090000000ull, 0x000001eff8000000ull, { 23, 0, 0, 0, 0 }, 0x0, 775, },
- { 121, 3, 0, 0x0000000098000000ull, 0x000001eff8000000ull, { 17, 0, 0, 0, 0 }, 0x0, 776, },
- { 122, 3, 0, 0x0000002170000000ull, 0x000001eff8000000ull, { 24, 0, 0, 0, 0 }, 0xc, 701, },
- { 123, 3, 1, 0x0000002070000000ull, 0x000001eff8000000ull, { 29, 24, 0, 0, 0 }, 0x8, 702, },
- { 123, 3, 1, 0x0000002078000000ull, 0x000001eff8000000ull, { 30, 24, 0, 0, 0 }, 0x8, 952, },
- { 125, 3, 1, 0x0000008000000000ull, 0x000001fff8000000ull, { 23, 32, 0, 0, 0 }, 0x0, 68, },
- { 125, 3, 1, 0x0000009000000000ull, 0x000001fff8000000ull, { 23, 32, 24, 0, 0 }, 0x400, 69, },
- { 125, 3, 1, 0x000000a000000000ull, 0x000001eff0000000ull, { 23, 32, 61, 0, 0 }, 0x400, 70, },
- { 126, 3, 1, 0x0000008040000000ull, 0x000001fff8000000ull, { 23, 32, 0, 0, 0 }, 0x0, 71, },
- { 126, 3, 1, 0x0000009040000000ull, 0x000001fff8000000ull, { 23, 32, 24, 0, 0 }, 0x400, 72, },
- { 126, 3, 1, 0x000000a040000000ull, 0x000001eff0000000ull, { 23, 32, 61, 0, 0 }, 0x400, 73, },
- { 127, 3, 1, 0x0000008080000000ull, 0x000001fff8000000ull, { 23, 32, 0, 0, 0 }, 0x0, 74, },
- { 127, 3, 1, 0x0000009080000000ull, 0x000001fff8000000ull, { 23, 32, 24, 0, 0 }, 0x400, 75, },
- { 127, 3, 1, 0x000000a080000000ull, 0x000001eff0000000ull, { 23, 32, 61, 0, 0 }, 0x400, 76, },
- { 128, 3, 1, 0x00000080c0000000ull, 0x000001fff8000000ull, { 23, 32, 0, 0, 0 }, 0x0, 77, },
- { 128, 3, 1, 0x00000090c0000000ull, 0x000001fff8000000ull, { 23, 32, 24, 0, 0 }, 0x400, 78, },
- { 128, 3, 1, 0x000000a0c0000000ull, 0x000001eff0000000ull, { 23, 32, 61, 0, 0 }, 0x400, 79, },
- { 129, 3, 1, 0x000000c6c0000000ull, 0x000001fff8000000ull, { 17, 32, 0, 0, 0 }, 0x0, 884, },
- { 129, 3, 1, 0x000000d6c0000000ull, 0x000001fff8000000ull, { 17, 32, 24, 0, 0 }, 0x400, 885, },
- { 129, 3, 1, 0x000000e6c0000000ull, 0x000001eff0000000ull, { 17, 32, 61, 0, 0 }, 0x400, 886, },
- { 130, 3, 1, 0x000000c040000000ull, 0x000001fff8000000ull, { 17, 32, 0, 0, 0 }, 0x0, 80, },
- { 130, 3, 1, 0x000000d040000000ull, 0x000001fff8000000ull, { 17, 32, 24, 0, 0 }, 0x400, 81, },
- { 130, 3, 1, 0x000000e040000000ull, 0x000001eff0000000ull, { 17, 32, 61, 0, 0 }, 0x400, 82, },
- { 131, 3, 1, 0x000000c0c0000000ull, 0x000001fff8000000ull, { 17, 32, 0, 0, 0 }, 0x0, 83, },
- { 131, 3, 1, 0x000000d0c0000000ull, 0x000001fff8000000ull, { 17, 32, 24, 0, 0 }, 0x400, 84, },
- { 131, 3, 1, 0x000000e0c0000000ull, 0x000001eff0000000ull, { 17, 32, 61, 0, 0 }, 0x400, 85, },
- { 132, 3, 1, 0x000000c000000000ull, 0x000001fff8000000ull, { 17, 32, 0, 0, 0 }, 0x0, 86, },
- { 132, 3, 1, 0x000000d000000000ull, 0x000001fff8000000ull, { 17, 32, 24, 0, 0 }, 0x400, 87, },
- { 132, 3, 1, 0x000000e000000000ull, 0x000001eff0000000ull, { 17, 32, 61, 0, 0 }, 0x400, 88, },
- { 133, 3, 2, 0x000000c048000000ull, 0x000001fff8000000ull, { 17, 18, 32, 0, 0 }, 0x0, 89, },
- { 133, 3, 2, 0x000000d048000000ull, 0x000001fff8000000ull, { 17, 18, 32, 5, 0 }, 0x400, 90, },
- { 134, 3, 2, 0x000000c0c8000000ull, 0x000001fff8000000ull, { 17, 18, 32, 0, 0 }, 0x0, 91, },
- { 134, 3, 2, 0x000000d0c8000000ull, 0x000001fff8000000ull, { 17, 18, 32, 5, 0 }, 0x400, 92, },
- { 135, 3, 2, 0x000000c088000000ull, 0x000001fff8000000ull, { 17, 18, 32, 0, 0 }, 0x0, 93, },
- { 135, 3, 2, 0x000000d088000000ull, 0x000001fff8000000ull, { 17, 18, 32, 4, 0 }, 0x400, 94, },
- { 136, 3, 1, 0x000000c080000000ull, 0x000001fff8000000ull, { 17, 32, 0, 0, 0 }, 0x0, 95, },
- { 136, 3, 1, 0x000000d080000000ull, 0x000001fff8000000ull, { 17, 32, 24, 0, 0 }, 0x400, 96, },
- { 136, 3, 1, 0x000000e080000000ull, 0x000001eff0000000ull, { 17, 32, 61, 0, 0 }, 0x400, 97, },
- { 139, 3, 0, 0x000000cb00000000ull, 0x000001fff8000000ull, { 32, 0, 0, 0, 0 }, 0x0, 98, },
- { 139, 3, 0, 0x000000db00000000ull, 0x000001fff8000000ull, { 32, 24, 0, 0, 0 }, 0x400, 99, },
- { 139, 3, 0, 0x000000eb00000000ull, 0x000001eff0000000ull, { 32, 61, 0, 0, 0 }, 0x400, 100, },
- { 140, 3, 0, 0x0000000050000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x21, 101, },
- { 148, 3, 0, 0x0000000110000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x0, 102, },
- { 149, 2, 1, 0x000000e880000000ull, 0x000001fff0000000ull, { 23, 24, 25, 0, 0 }, 0x0, 1820, },
- { 150, 2, 1, 0x000000ea80000000ull, 0x000001fff0000000ull, { 23, 24, 25, 0, 0 }, 0x0, 1821, },
- { 151, 2, 1, 0x000000f880000000ull, 0x000001fff0000000ull, { 23, 24, 25, 0, 0 }, 0x0, 1822, },
- { 152, 1, 1, 0x0000010800000000ull, 0x000001fff80fe000ull, { 23, 25, 0, 0, 0 }, 0x0, 103, },
- { 152, 1, 1, 0x0000010800000000ull, 0x000001ee07f00000ull, { 23, 62, 0, 0, 0 }, 0x40, 104, },
- { 152, 1, 1, 0x0000012000000000ull, 0x000001e000300000ull, { 23, 65, 0, 0, 0 }, 0x40, 105, },
- { 152, 5, 1, 0x0000000080000000ull, 0x000001e3f8000000ull, { 17, 19, 0, 0, 0 }, 0xc0, 106, },
- { 152, 2, 1, 0x0000000e00100000ull, 0x000001ee00f00000ull, { 14, 24, 0, 0, 0 }, 0x40, 107, },
- { 152, 2, 1, 0x0000000e00000000ull, 0x000001ee00f00000ull, { 14, 24, 77, 0, 0 }, 0x0, 2368, },
- { 152, 2, 1, 0x0000000188000000ull, 0x000001eff8000000ull, { 23, 15, 0, 0, 0 }, 0x0, 109, },
- { 152, 2, 1, 0x0000000600000000ull, 0x000001ee00000000ull, { 8, 24, 63, 0, 0 }, 0x0, 110, },
- { 152, 2, 1, 0x0000000400000000ull, 0x000001ee00000000ull, { 9, 67, 0, 0, 0 }, 0x0, 111, },
- { 152, 2, 1, 0x0000000180000000ull, 0x000001eff8000000ull, { 23, 7, 0, 0, 0 }, 0x0, 112, },
- { 152, 2, 1, 0x0000000198000000ull, 0x000001eff8000000ull, { 23, 8, 0, 0, 0 }, 0x0, 113, },
- { 152, 2, 1, 0x0000000150000000ull, 0x000001eff8000000ull, { 13, 24, 0, 0, 0 }, 0x0, 953, },
- { 152, 2, 1, 0x0000000050000000ull, 0x000001eff8000000ull, { 13, 54, 0, 0, 0 }, 0x0, 954, },
- { 152, 2, 1, 0x0000000190000000ull, 0x000001eff8000000ull, { 23, 13, 0, 0, 0 }, 0x0, 955, },
- { 152, 3, 1, 0x0000000140000000ull, 0x000001eff8000000ull, { 13, 54, 0, 0, 0 }, 0x0, 1041, },
- { 152, 3, 1, 0x0000002150000000ull, 0x000001eff8000000ull, { 13, 24, 0, 0, 0 }, 0x0, 1042, },
- { 152, 3, 1, 0x0000002110000000ull, 0x000001eff8000000ull, { 23, 13, 0, 0, 0 }, 0x0, 1043, },
- { 152, 3, 1, 0x0000002160000000ull, 0x000001eff8000000ull, { 16, 24, 0, 0, 0 }, 0x8, 114, },
- { 152, 3, 1, 0x0000002120000000ull, 0x000001eff8000000ull, { 23, 16, 0, 0, 0 }, 0x8, 115, },
- { 152, 3, 1, 0x0000002168000000ull, 0x000001eff8000000ull, { 11, 24, 0, 0, 0 }, 0x8, 116, },
- { 152, 3, 1, 0x0000002148000000ull, 0x000001eff8000000ull, { 12, 24, 0, 0, 0 }, 0x0, 117, },
- { 152, 3, 1, 0x0000002128000000ull, 0x000001eff8000000ull, { 23, 10, 0, 0, 0 }, 0x8, 118, },
- { 152, 3, 1, 0x0000002108000000ull, 0x000001eff8000000ull, { 23, 12, 0, 0, 0 }, 0x0, 119, },
- { 152, 3, 1, 0x0000002000000000ull, 0x000001eff8000000ull, { 37, 24, 0, 0, 0 }, 0x8, 120, },
- { 152, 3, 1, 0x0000002008000000ull, 0x000001eff8000000ull, { 28, 24, 0, 0, 0 }, 0x8, 121, },
- { 152, 3, 1, 0x0000002010000000ull, 0x000001eff8000000ull, { 31, 24, 0, 0, 0 }, 0x8, 122, },
- { 152, 3, 1, 0x0000002018000000ull, 0x000001eff8000000ull, { 34, 24, 0, 0, 0 }, 0x8, 123, },
- { 152, 3, 1, 0x0000002020000000ull, 0x000001eff8000000ull, { 35, 24, 0, 0, 0 }, 0x8, 124, },
- { 152, 3, 1, 0x0000002028000000ull, 0x000001eff8000000ull, { 36, 24, 0, 0, 0 }, 0x8, 125, },
- { 152, 3, 1, 0x0000002030000000ull, 0x000001eff8000000ull, { 33, 24, 0, 0, 0 }, 0x8, 126, },
- { 152, 3, 1, 0x0000002080000000ull, 0x000001eff8000000ull, { 23, 37, 0, 0, 0 }, 0x8, 127, },
- { 152, 3, 1, 0x0000002088000000ull, 0x000001eff8000000ull, { 23, 28, 0, 0, 0 }, 0x8, 128, },
- { 152, 3, 1, 0x0000002090000000ull, 0x000001eff8000000ull, { 23, 31, 0, 0, 0 }, 0x8, 129, },
- { 152, 3, 1, 0x0000002098000000ull, 0x000001eff8000000ull, { 23, 34, 0, 0, 0 }, 0x8, 130, },
- { 152, 3, 1, 0x00000020a0000000ull, 0x000001eff8000000ull, { 23, 35, 0, 0, 0 }, 0x8, 131, },
- { 152, 3, 1, 0x00000020a8000000ull, 0x000001eff8000000ull, { 23, 36, 0, 0, 0 }, 0x0, 132, },
- { 152, 3, 1, 0x00000020b0000000ull, 0x000001eff8000000ull, { 23, 33, 0, 0, 0 }, 0x8, 133, },
- { 152, 3, 1, 0x00000020b8000000ull, 0x000001eff8000000ull, { 23, 27, 0, 0, 0 }, 0x0, 134, },
- { 152, 7, 1, 0x0000000000000000ull, 0x0000000000000000ull, { 23, 13, 0, 0, 0 }, 0x0, 135, },
- { 152, 7, 1, 0x0000000000000000ull, 0x0000000000000000ull, { 13, 54, 0, 0, 0 }, 0x0, 136, },
- { 152, 7, 1, 0x0000000000000000ull, 0x0000000000000000ull, { 13, 24, 0, 0, 0 }, 0x0, 137, },
- { 153, 6, 1, 0x000000c000000000ull, 0x000001e000100000ull, { 23, 69, 0, 0, 0 }, 0x0, 138, },
- { 154, 2, 1, 0x000000eca0000000ull, 0x000001fff0000000ull, { 23, 24, 73, 0, 0 }, 0x0, 139, },
- { 155, 2, 1, 0x000000eea0000000ull, 0x000001fff0000000ull, { 23, 24, 74, 0, 0 }, 0x0, 140, },
- { 165, 4, 0, 0x0000004000000000ull, 0x000001e1f8000000ull, { 64, 0, 0, 0, 0 }, 0x0, 394, },
- { 165, 5, 0, 0x0000000008000000ull, 0x000001e3f8000000ull, { 64, 0, 0, 0, 0 }, 0x0, 807, },
- { 165, 2, 0, 0x0000000008000000ull, 0x000001eff8000000ull, { 64, 0, 0, 0, 0 }, 0x2, 956, },
- { 165, 3, 0, 0x0000000008000000ull, 0x000001eff8000000ull, { 64, 0, 0, 0, 0 }, 0x0, 1044, },
- { 165, 6, 0, 0x0000000008000000ull, 0x000001eff8000000ull, { 68, 0, 0, 0, 0 }, 0x0, 2484, },
- { 165, 7, 0, 0x0000000000000000ull, 0x0000000000000000ull, { 64, 0, 0, 0, 0 }, 0x0, 141, },
- { 172, 1, 1, 0x0000010070000000ull, 0x000001eff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 142, },
- { 172, 1, 1, 0x0000010170000000ull, 0x000001eff8000000ull, { 23, 54, 25, 0, 0 }, 0x0, 143, },
- { 175, 2, 1, 0x000000ea00000000ull, 0x000001fff0000000ull, { 23, 24, 25, 0, 0 }, 0x0, 2467, },
- { 176, 2, 1, 0x000000f820000000ull, 0x000001fff0000000ull, { 23, 24, 25, 0, 0 }, 0x0, 2370, },
- { 177, 1, 1, 0x0000010400000000ull, 0x000001fff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 144, },
- { 178, 1, 1, 0x0000010600000000ull, 0x000001fff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 145, },
- { 179, 1, 1, 0x0000011400000000ull, 0x000001fff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 146, },
- { 180, 1, 1, 0x0000010450000000ull, 0x000001fff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 147, },
- { 181, 1, 1, 0x0000010650000000ull, 0x000001fff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 148, },
- { 182, 1, 1, 0x0000010470000000ull, 0x000001fff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 149, },
- { 183, 1, 1, 0x0000010670000000ull, 0x000001fff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 150, },
- { 184, 1, 1, 0x0000010520000000ull, 0x000001fff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 794, },
- { 185, 1, 1, 0x0000010720000000ull, 0x000001fff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 795, },
- { 186, 1, 1, 0x0000011520000000ull, 0x000001fff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 796, },
- { 187, 2, 1, 0x000000e850000000ull, 0x000001fff0000000ull, { 23, 24, 25, 0, 0 }, 0x0, 2384, },
- { 188, 2, 1, 0x000000ea70000000ull, 0x000001fff0000000ull, { 23, 24, 25, 0, 0 }, 0x0, 151, },
- { 189, 2, 1, 0x000000e810000000ull, 0x000001fff0000000ull, { 23, 24, 25, 0, 0 }, 0x0, 2385, },
- { 190, 2, 1, 0x000000ea30000000ull, 0x000001fff0000000ull, { 23, 24, 25, 0, 0 }, 0x0, 152, },
- { 191, 2, 1, 0x000000ead0000000ull, 0x000001fff0000000ull, { 23, 24, 25, 0, 0 }, 0x0, 1823, },
- { 192, 2, 1, 0x000000e230000000ull, 0x000001ff30000000ull, { 23, 24, 25, 41, 0 }, 0x0, 153, },
- { 193, 2, 1, 0x000000e690000000ull, 0x000001fff0000000ull, { 23, 25, 0, 0, 0 }, 0x0, 154, },
- { 195, 3, 1, 0x00000021c0000000ull, 0x000001eff8000000ull, { 23, 25, 24, 0, 0 }, 0x0, 1824, },
- { 195, 3, 1, 0x00000020c0000000ull, 0x000001eff8000000ull, { 23, 25, 48, 0, 0 }, 0x0, 1825, },
- { 195, 3, 0, 0x0000002188000000ull, 0x000001eff8000000ull, { 25, 48, 0, 0, 0 }, 0x0, 1847, },
- { 196, 2, 1, 0x000000e8b0000000ull, 0x000001fff0000000ull, { 23, 24, 25, 0, 0 }, 0x0, 155, },
- { 197, 2, 1, 0x000000e240000000ull, 0x000001fff0000000ull, { 23, 24, 25, 0, 0 }, 0x0, 156, },
- { 197, 2, 1, 0x000000ee50000000ull, 0x000001fff0000000ull, { 23, 24, 38, 0, 0 }, 0x0, 157, },
- { 198, 2, 1, 0x000000f040000000ull, 0x000001fff0000000ull, { 23, 24, 25, 0, 0 }, 0x0, 158, },
- { 198, 2, 1, 0x000000fc50000000ull, 0x000001fff0000000ull, { 23, 24, 38, 0, 0 }, 0x0, 159, },
- { 199, 1, 1, 0x0000010680000000ull, 0x000001ffe0000000ull, { 23, 24, 40, 25, 0 }, 0x0, 160, },
- { 200, 2, 1, 0x000000e220000000ull, 0x000001fff0000000ull, { 23, 25, 24, 0, 0 }, 0x0, 161, },
- { 200, 2, 1, 0x000000e630000000ull, 0x000001fff0000000ull, { 23, 25, 42, 0, 0 }, 0x0, 162, },
- { 201, 2, 1, 0x000000f020000000ull, 0x000001fff0000000ull, { 23, 25, 24, 0, 0 }, 0x0, 163, },
- { 201, 2, 1, 0x000000f430000000ull, 0x000001fff0000000ull, { 23, 25, 42, 0, 0 }, 0x0, 164, },
- { 202, 1, 1, 0x00000106c0000000ull, 0x000001ffe0000000ull, { 23, 24, 40, 25, 0 }, 0x0, 165, },
- { 203, 1, 1, 0x0000010420000000ull, 0x000001fff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 166, },
- { 204, 1, 1, 0x0000010620000000ull, 0x000001fff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 167, },
- { 205, 1, 1, 0x0000011420000000ull, 0x000001fff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 168, },
- { 206, 3, 0, 0x0000002048000000ull, 0x000001eff8000000ull, { 25, 24, 0, 0, 0 }, 0x8, 984, },
- { 206, 3, 0, 0x0000002050000000ull, 0x000001eff8000000ull, { 25, 24, 0, 0, 0 }, 0xc, 895, },
- { 206, 3, 0, 0x00000021a0000000ull, 0x000001eff8000000ull, { 25, 0, 0, 0, 0 }, 0x8, 777, },
- { 207, 3, 0, 0x0000002060000000ull, 0x000001eff8000000ull, { 25, 24, 0, 0, 0 }, 0x8, 703, },
- { 212, 4, 0, 0x0000000040000000ull, 0x000001e1f8000000ull, { 0, 0, 0, 0, 0 }, 0x22c, 169, },
- { 213, 3, 0, 0x0000000038000000ull, 0x000001ee78000000ull, { 66, 0, 0, 0, 0 }, 0x8, 170, },
- { 214, 3, 0, 0x0000000028000000ull, 0x000001ee78000000ull, { 66, 0, 0, 0, 0 }, 0x0, 171, },
- { 223, 3, 1, 0x000000c708000000ull, 0x000001ffc8000000ull, { 17, 24, 0, 0, 0 }, 0x0, 2295, },
- { 224, 2, 1, 0x000000a600000000ull, 0x000001ee04000000ull, { 23, 24, 44, 0, 0 }, 0x140, 172, },
- { 224, 2, 1, 0x000000f240000000ull, 0x000001fff0000000ull, { 23, 24, 25, 0, 0 }, 0x0, 173, },
- { 225, 1, 1, 0x0000010080000000ull, 0x000001efe0000000ull, { 23, 24, 39, 25, 0 }, 0x0, 174, },
- { 226, 1, 1, 0x00000100c0000000ull, 0x000001efe0000000ull, { 23, 24, 39, 25, 0 }, 0x0, 175, },
- { 227, 2, 1, 0x000000a400000000ull, 0x000001ee00002000ull, { 23, 25, 75, 0, 0 }, 0x140, 2391, },
- { 227, 2, 1, 0x000000f220000000ull, 0x000001fff0000000ull, { 23, 25, 24, 0, 0 }, 0x0, 177, },
- { 228, 2, 1, 0x000000ac00000000ull, 0x000001ee00000000ull, { 23, 24, 25, 43, 0 }, 0x0, 178, },
- { 233, 3, 0, 0x0000000180000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x0, 705, },
- { 234, 3, 0, 0x0000000030000000ull, 0x000001ee78000000ull, { 66, 0, 0, 0, 0 }, 0x8, 179, },
- { 236, 3, 1, 0x0000008c00000000ull, 0x000001fff8000000ull, { 32, 24, 0, 0, 0 }, 0x0, 180, },
- { 236, 3, 1, 0x000000ac00000000ull, 0x000001eff0000000ull, { 32, 24, 60, 0, 0 }, 0x400, 181, },
- { 237, 3, 1, 0x0000008c40000000ull, 0x000001fff8000000ull, { 32, 24, 0, 0, 0 }, 0x0, 182, },
- { 237, 3, 1, 0x000000ac40000000ull, 0x000001eff0000000ull, { 32, 24, 60, 0, 0 }, 0x400, 183, },
- { 238, 3, 1, 0x0000008c80000000ull, 0x000001fff8000000ull, { 32, 24, 0, 0, 0 }, 0x0, 184, },
- { 238, 3, 1, 0x000000ac80000000ull, 0x000001eff0000000ull, { 32, 24, 60, 0, 0 }, 0x400, 185, },
- { 239, 3, 1, 0x0000008cc0000000ull, 0x000001fff8000000ull, { 32, 24, 0, 0, 0 }, 0x0, 186, },
- { 239, 3, 1, 0x000000acc0000000ull, 0x000001eff0000000ull, { 32, 24, 60, 0, 0 }, 0x400, 187, },
- { 240, 3, 1, 0x000000cec0000000ull, 0x000001fff8000000ull, { 32, 18, 0, 0, 0 }, 0x0, 2298, },
- { 240, 3, 1, 0x000000eec0000000ull, 0x000001eff0000000ull, { 32, 18, 60, 0, 0 }, 0x400, 2299, },
- { 241, 3, 1, 0x000000cc40000000ull, 0x000001fff8000000ull, { 32, 18, 0, 0, 0 }, 0x0, 188, },
- { 241, 3, 1, 0x000000ec40000000ull, 0x000001eff0000000ull, { 32, 18, 60, 0, 0 }, 0x400, 189, },
- { 242, 3, 1, 0x000000ccc0000000ull, 0x000001fff8000000ull, { 32, 18, 0, 0, 0 }, 0x0, 190, },
- { 242, 3, 1, 0x000000ecc0000000ull, 0x000001eff0000000ull, { 32, 18, 60, 0, 0 }, 0x400, 191, },
- { 243, 3, 1, 0x000000cc00000000ull, 0x000001fff8000000ull, { 32, 18, 0, 0, 0 }, 0x0, 192, },
- { 243, 3, 1, 0x000000ec00000000ull, 0x000001eff0000000ull, { 32, 18, 60, 0, 0 }, 0x400, 193, },
- { 244, 3, 1, 0x000000cc80000000ull, 0x000001fff8000000ull, { 32, 18, 0, 0, 0 }, 0x0, 194, },
- { 244, 3, 1, 0x000000ec80000000ull, 0x000001eff0000000ull, { 32, 18, 60, 0, 0 }, 0x400, 195, },
- { 245, 1, 1, 0x0000010028000000ull, 0x000001eff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 196, },
- { 245, 1, 1, 0x0000010020000000ull, 0x000001eff8000000ull, { 23, 24, 25, 3, 0 }, 0x0, 197, },
- { 245, 1, 1, 0x0000010128000000ull, 0x000001eff8000000ull, { 23, 54, 25, 0, 0 }, 0x0, 198, },
- { 246, 3, 0, 0x0000000020000000ull, 0x000001ee78000000ull, { 66, 0, 0, 0, 0 }, 0x0, 199, },
- { 247, 2, 1, 0x00000000a0000000ull, 0x000001eff8000000ull, { 23, 25, 0, 0, 0 }, 0x0, 200, },
- { 248, 2, 1, 0x00000000a8000000ull, 0x000001eff8000000ull, { 23, 25, 0, 0, 0 }, 0x0, 201, },
- { 249, 2, 1, 0x00000000b0000000ull, 0x000001eff8000000ull, { 23, 25, 0, 0, 0 }, 0x0, 202, },
- { 250, 3, 0, 0x0000000198000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x0, 959, },
- { 251, 3, 1, 0x00000020f8000000ull, 0x000001eff8000000ull, { 23, 25, 0, 0, 0 }, 0x8, 203, },
- { 252, 2, 2, 0x000000a000000000ull, 0x000001fe00003000ull, { 21, 22, 25, 75, 0 }, 0x0, 2489, },
- { 252, 2, 2, 0x000000a000000000ull, 0x000001fe00003000ull, { 22, 21, 25, 75, 0 }, 0x40, 1724, },
- { 253, 3, 1, 0x00000020d0000000ull, 0x000001eff8000000ull, { 23, 25, 0, 0, 0 }, 0x0, 204, },
- { 254, 2, 2, 0x000000a000002000ull, 0x000001fe00003000ull, { 21, 22, 25, 0, 0 }, 0x0, 2491, },
- { 254, 2, 2, 0x000000a000002000ull, 0x000001fe00003000ull, { 22, 21, 25, 0, 0 }, 0x40, 1726, },
- { 255, 3, 1, 0x00000020f0000000ull, 0x000001eff8000000ull, { 23, 25, 0, 0, 0 }, 0x8, 205, },
- { 257, 3, 1, 0x00000020d8000000ull, 0x000001eff8000000ull, { 23, 25, 0, 0, 0 }, 0x0, 206, },
- { 261, 2, 1, 0x000000e840000000ull, 0x000001fff0000000ull, { 23, 24, 25, 0, 0 }, 0x0, 942, },
- { 262, 2, 1, 0x000000ea40000000ull, 0x000001fff0000000ull, { 23, 24, 25, 0, 0 }, 0x0, 943, },
- { 263, 2, 1, 0x000000f840000000ull, 0x000001fff0000000ull, { 23, 24, 25, 0, 0 }, 0x0, 944, },
- { 271, 3, 1, 0x0000008208000000ull, 0x000001fff8000000ull, { 23, 32, 24, 0, 0 }, 0x0, 207, },
- { 272, 3, 1, 0x0000008248000000ull, 0x000001fff8000000ull, { 23, 32, 24, 0, 0 }, 0x0, 208, },
- { 273, 3, 1, 0x0000008288000000ull, 0x000001fff8000000ull, { 23, 32, 24, 0, 0 }, 0x0, 209, },
- { 274, 3, 1, 0x00000082c8000000ull, 0x000001fff8000000ull, { 23, 32, 24, 0, 0 }, 0x0, 210, },
- { 276, 5, 1, 0x000001d000000000ull, 0x000001fc00000000ull, { 17, 19, 20, 18, 0 }, 0x0, 988, },
- { 276, 5, 1, 0x000001d000000000ull, 0x000001fc00000000ull, { 17, 19, 20, 18, 0 }, 0x40, 1036, },
- { 277, 5, 1, 0x000001d000000000ull, 0x000001fc000fe000ull, { 17, 19, 20, 0, 0 }, 0x40, 989, },
- { 278, 1, 1, 0x0000010078000000ull, 0x000001eff8000000ull, { 23, 24, 25, 0, 0 }, 0x0, 211, },
- { 278, 1, 1, 0x0000010178000000ull, 0x000001eff8000000ull, { 23, 54, 25, 0, 0 }, 0x0, 212, },
- { 281, 2, 1, 0x0000000080000000ull, 0x000001eff8000000ull, { 23, 25, 0, 0, 0 }, 0x0, 213, },
- { 282, 2, 1, 0x0000000088000000ull, 0x000001eff8000000ull, { 23, 25, 0, 0, 0 }, 0x0, 214, },
- { 283, 2, 1, 0x0000000090000000ull, 0x000001eff8000000ull, { 23, 25, 0, 0, 0 }, 0x0, 215, },
+ { 26, 1, 2, 0x0000018000000000ull, 0x000001fe00001000ull, { 22, 23, 25, 26, 0 }, 0x0, 1023, },
+ { 26, 1, 2, 0x0000018000000000ull, 0x000001fe00001000ull, { 23, 22, 26, 25, 0 }, 0x0, 999, },
+ { 26, 1, 2, 0x0000018000000000ull, 0x000001fe00001000ull, { 22, 23, 26, 25, 0 }, 0x0, 925, },
+ { 26, 1, 2, 0x0000018000000000ull, 0x000001fe00001000ull, { 23, 22, 25, 26, 0 }, 0x0, 904, },
+ { 26, 1, 2, 0x0000018200000000ull, 0x000001fe00001000ull, { 22, 23, 25, 26, 0 }, 0x40, 1157, },
+ { 26, 1, 2, 0x0000019000000000ull, 0x000001fe00001000ull, { 22, 23, 7, 26, 0 }, 0x0, 926, },
+ { 26, 1, 2, 0x0000019000000000ull, 0x000001fe00001000ull, { 22, 23, 26, 7, 0 }, 0x40, 1025, },
+ { 26, 1, 2, 0x0000019000000000ull, 0x000001fe00001000ull, { 22, 23, 7, 26, 0 }, 0x40, 1002, },
+ { 26, 1, 2, 0x0000018800000000ull, 0x000001ee00001000ull, { 22, 23, 55, 26, 0 }, 0x0, 1027, },
+ { 26, 1, 2, 0x0000018800000000ull, 0x000001ee00001000ull, { 22, 23, 57, 26, 0 }, 0x0, 1003, },
+ { 26, 1, 2, 0x0000018800000000ull, 0x000001ee00001000ull, { 23, 22, 57, 26, 0 }, 0x0, 929, },
+ { 26, 1, 2, 0x0000018800000000ull, 0x000001ee00001000ull, { 23, 22, 55, 26, 0 }, 0x0, 908, },
+ { 26, 1, 2, 0x0000018a00000000ull, 0x000001ee00001000ull, { 22, 23, 55, 26, 0 }, 0x40, 1160, },
+ { 26, 1, 2, 0x000001a800000000ull, 0x000001ee00001000ull, { 22, 23, 59, 26, 0 }, 0x0, 1018, },
+ { 26, 1, 2, 0x000001a800000000ull, 0x000001ee00001000ull, { 23, 22, 59, 26, 0 }, 0x0, 946, },
+ { 26, 1, 2, 0x000001c200000000ull, 0x000001fe00001000ull, { 23, 22, 25, 26, 0 }, 0x40, 1161, },
+ { 26, 1, 2, 0x000001d000000000ull, 0x000001fe00001000ull, { 23, 22, 7, 26, 0 }, 0x40, 1004, },
+ { 26, 1, 2, 0x000001d000000000ull, 0x000001fe00001000ull, { 23, 22, 26, 7, 0 }, 0x40, 910, },
+ { 26, 1, 2, 0x000001ca00000000ull, 0x000001ee00001000ull, { 23, 22, 55, 26, 0 }, 0x40, 1162, },
+ { 27, 1, 2, 0x0000018400000000ull, 0x000001fe00001000ull, { 22, 23, 25, 26, 0 }, 0x0, 1030, },
+ { 27, 1, 2, 0x0000018400000000ull, 0x000001fe00001000ull, { 23, 22, 26, 25, 0 }, 0x0, 1006, },
+ { 27, 1, 2, 0x0000018400000000ull, 0x000001fe00001000ull, { 22, 23, 26, 25, 0 }, 0x0, 932, },
+ { 27, 1, 2, 0x0000018400000000ull, 0x000001fe00001000ull, { 23, 22, 25, 26, 0 }, 0x0, 911, },
+ { 27, 1, 2, 0x0000018600000000ull, 0x000001fe00001000ull, { 22, 23, 25, 26, 0 }, 0x40, 1165, },
+ { 27, 1, 2, 0x0000019400000000ull, 0x000001fe00001000ull, { 22, 23, 7, 26, 0 }, 0x0, 933, },
+ { 27, 1, 2, 0x0000019400000000ull, 0x000001fe00001000ull, { 22, 23, 26, 7, 0 }, 0x40, 1032, },
+ { 27, 1, 2, 0x0000019400000000ull, 0x000001fe00001000ull, { 22, 23, 7, 26, 0 }, 0x40, 1009, },
+ { 27, 1, 2, 0x0000018c00000000ull, 0x000001ee00001000ull, { 22, 23, 55, 26, 0 }, 0x0, 1034, },
+ { 27, 1, 2, 0x0000018c00000000ull, 0x000001ee00001000ull, { 22, 23, 57, 26, 0 }, 0x0, 1010, },
+ { 27, 1, 2, 0x0000018c00000000ull, 0x000001ee00001000ull, { 23, 22, 57, 26, 0 }, 0x0, 936, },
+ { 27, 1, 2, 0x0000018c00000000ull, 0x000001ee00001000ull, { 23, 22, 55, 26, 0 }, 0x0, 915, },
+ { 27, 1, 2, 0x0000018e00000000ull, 0x000001ee00001000ull, { 22, 23, 55, 26, 0 }, 0x40, 1168, },
+ { 27, 1, 2, 0x000001ac00000000ull, 0x000001ee00001000ull, { 22, 23, 56, 26, 0 }, 0x0, 1044, },
+ { 27, 1, 2, 0x000001ac00000000ull, 0x000001ee00001000ull, { 22, 23, 58, 26, 0 }, 0x0, 1020, },
+ { 27, 1, 2, 0x000001ac00000000ull, 0x000001ee00001000ull, { 23, 22, 58, 26, 0 }, 0x0, 948, },
+ { 27, 1, 2, 0x000001ac00000000ull, 0x000001ee00001000ull, { 23, 22, 56, 26, 0 }, 0x0, 924, },
+ { 27, 1, 2, 0x000001c600000000ull, 0x000001fe00001000ull, { 23, 22, 25, 26, 0 }, 0x40, 1169, },
+ { 27, 1, 2, 0x000001d400000000ull, 0x000001fe00001000ull, { 23, 22, 7, 26, 0 }, 0x40, 1011, },
+ { 27, 1, 2, 0x000001d400000000ull, 0x000001fe00001000ull, { 23, 22, 26, 7, 0 }, 0x40, 917, },
+ { 27, 1, 2, 0x000001ce00000000ull, 0x000001ee00001000ull, { 23, 22, 55, 26, 0 }, 0x40, 1170, },
+ { 28, 3, 1, 0x0000008808000000ull, 0x000001fff8000000ull, { 24, 33, 25, 1, 2 }, 0x0, 254, },
+ { 29, 3, 1, 0x0000008008000000ull, 0x000001fff8000000ull, { 24, 33, 25, 2, 0 }, 0x0, 255, },
+ { 30, 3, 1, 0x0000008048000000ull, 0x000001fff8000000ull, { 24, 33, 25, 2, 0 }, 0x0, 256, },
+ { 31, 3, 1, 0x0000008088000000ull, 0x000001fff8000000ull, { 24, 33, 25, 2, 0 }, 0x0, 257, },
+ { 32, 3, 1, 0x00000080c8000000ull, 0x000001fff8000000ull, { 24, 33, 25, 2, 0 }, 0x0, 258, },
+ { 34, 4, 0, 0x0000000010000000ull, 0x000001e1f8000000ull, { 0, 0, 0, 0, 0 }, 0x224, 18, },
+ { 36, 2, 1, 0x00000000c0000000ull, 0x000001eff8000000ull, { 24, 26, 0, 0, 0 }, 0x0, 985, },
+ { 37, 2, 1, 0x00000000c8000000ull, 0x000001eff8000000ull, { 24, 26, 0, 0, 0 }, 0x0, 986, },
+ { 39, 2, 1, 0x0000008000000000ull, 0x000001e000000000ull, { 24, 25, 26, 47, 72 }, 0x0, 19, },
+ { 39, 2, 1, 0x000000a600000000ull, 0x000001ee04000000ull, { 24, 25, 45, 73, 0 }, 0x0, 2511, },
+ { 39, 2, 1, 0x000000a604000000ull, 0x000001ee04000000ull, { 24, 55, 45, 73, 0 }, 0x0, 2512, },
+ { 39, 2, 1, 0x000000ae00000000ull, 0x000001ee00000000ull, { 24, 48, 26, 46, 73 }, 0x0, 20, },
+ { 43, 4, 0, 0x0000000080000000ull, 0x000001e1f8000000ull, { 0, 0, 0, 0, 0 }, 0x20, 21, },
+ { 48, 2, 1, 0x000000a400000000ull, 0x000001ee00002000ull, { 24, 26, 76, 73, 0 }, 0x0, 2406, },
+ { 50, 5, 1, 0x0000000080000000ull, 0x000001e3f80fe000ull, { 18, 20, 0, 0, 0 }, 0x40, 23, },
+ { 51, 5, 1, 0x0000010008000000ull, 0x000001fff8000000ull, { 18, 20, 19, 0, 0 }, 0x40, 1923, },
+ { 52, 5, 1, 0x00000000b8000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 1924, },
+ { 52, 5, 1, 0x00000000b8000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x40, 25, },
+ { 53, 5, 1, 0x00000000b0000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 1925, },
+ { 53, 5, 1, 0x00000000b0000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x40, 26, },
+ { 54, 5, 1, 0x0000000160000000ull, 0x000001e3f8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 27, },
+ { 55, 5, 1, 0x0000000168000000ull, 0x000001e3f8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 28, },
+ { 57, 3, 0, 0x0000002180000000ull, 0x000001fff8000000ull, { 26, 0, 0, 0, 0 }, 0x0, 29, },
+ { 58, 5, 0, 0x0000000040000000ull, 0x000001eff8000000ull, { 79, 0, 0, 0, 0 }, 0x0, 1926, },
+ { 58, 5, 0, 0x0000000040000000ull, 0x000001eff8000000ull, { 79, 0, 0, 0, 0 }, 0x40, 30, },
+ { 59, 5, 2, 0x000000a000000000ull, 0x000001e000001000ull, { 22, 23, 19, 60, 0 }, 0x0, 1049, },
+ { 59, 5, 2, 0x000000a000000000ull, 0x000001e000001000ull, { 23, 22, 19, 60, 0 }, 0x40, 1190, },
+ { 60, 5, 0, 0x0000000028000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x0, 1927, },
+ { 60, 5, 0, 0x0000000028000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x40, 31, },
+ { 61, 5, 2, 0x0000008000000000ull, 0x000001fe00001000ull, { 22, 23, 19, 20, 0 }, 0x0, 796, },
+ { 61, 5, 2, 0x0000008000000000ull, 0x000001fe00001000ull, { 22, 23, 19, 20, 0 }, 0x40, 797, },
+ { 61, 5, 2, 0x0000009000000000ull, 0x000001fe00001000ull, { 22, 23, 20, 19, 0 }, 0x0, 939, },
+ { 61, 5, 2, 0x0000009000000000ull, 0x000001fe00001000ull, { 22, 23, 20, 19, 0 }, 0x40, 940, },
+ { 61, 5, 2, 0x0000008000000000ull, 0x000001fe00001000ull, { 23, 22, 19, 20, 0 }, 0x0, 1171, },
+ { 61, 5, 2, 0x0000008000000000ull, 0x000001fe00001000ull, { 23, 22, 19, 20, 0 }, 0x40, 1172, },
+ { 61, 5, 2, 0x0000009000000000ull, 0x000001fe00001000ull, { 23, 22, 20, 19, 0 }, 0x0, 1178, },
+ { 61, 5, 2, 0x0000009000000000ull, 0x000001fe00001000ull, { 23, 22, 20, 19, 0 }, 0x40, 1179, },
+ { 62, 5, 1, 0x00000000c0000000ull, 0x000001eff8000000ull, { 18, 19, 0, 0, 0 }, 0x0, 894, },
+ { 62, 5, 1, 0x00000000c0000000ull, 0x000001eff8000000ull, { 18, 19, 0, 0, 0 }, 0x40, 895, },
+ { 62, 5, 1, 0x00000000e0000000ull, 0x000001e3f8000000ull, { 18, 19, 0, 0, 0 }, 0x0, 2509, },
+ { 62, 5, 1, 0x0000010008000000ull, 0x000001fff80fe000ull, { 18, 20, 0, 0, 0 }, 0x40, 2510, },
+ { 63, 3, 1, 0x0000008488000000ull, 0x000001fff8000000ull, { 24, 33, 71, 0, 0 }, 0x0, 259, },
+ { 64, 3, 1, 0x00000084c8000000ull, 0x000001fff8000000ull, { 24, 33, 71, 0, 0 }, 0x0, 260, },
+ { 67, 3, 0, 0x0000000060000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x21, 32, },
+ { 68, 5, 1, 0x0000010000000000ull, 0x000001fc00000000ull, { 18, 20, 21, 19, 0 }, 0x0, 1961, },
+ { 68, 5, 1, 0x0000010000000000ull, 0x000001fc00000000ull, { 18, 20, 21, 19, 0 }, 0x40, 33, },
+ { 69, 5, 1, 0x00000000a8000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 1962, },
+ { 69, 5, 1, 0x00000000a8000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x40, 34, },
+ { 70, 5, 1, 0x0000000080000000ull, 0x000001e3f8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 1879, },
+ { 71, 5, 1, 0x00000000a0000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 1963, },
+ { 71, 5, 1, 0x00000000a0000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x40, 35, },
+ { 72, 5, 1, 0x00000001c8000000ull, 0x000001e3f8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 1022, },
+ { 73, 5, 1, 0x0000010000000000ull, 0x000001fc000fe000ull, { 18, 20, 21, 0, 0 }, 0x40, 1966, },
+ { 74, 5, 1, 0x0000014000000000ull, 0x000001fc00000000ull, { 18, 20, 21, 19, 0 }, 0x0, 1969, },
+ { 74, 5, 1, 0x0000014000000000ull, 0x000001fc00000000ull, { 18, 20, 21, 19, 0 }, 0x40, 37, },
+ { 75, 5, 1, 0x0000000088000000ull, 0x000001e3f8000000ull, { 18, 20, 0, 0, 0 }, 0xc0, 38, },
+ { 76, 5, 1, 0x0000000088000000ull, 0x000001e3f80fe000ull, { 18, 20, 0, 0, 0 }, 0x40, 39, },
+ { 77, 5, 1, 0x0000018000000000ull, 0x000001fc00000000ull, { 18, 20, 21, 19, 0 }, 0x0, 1972, },
+ { 77, 5, 1, 0x0000018000000000ull, 0x000001fc00000000ull, { 18, 20, 21, 19, 0 }, 0x40, 40, },
+ { 78, 5, 1, 0x0000018000000000ull, 0x000001fc000fe000ull, { 18, 20, 21, 0, 0 }, 0x40, 1975, },
+ { 79, 5, 1, 0x0000010008000000ull, 0x000001fff80fe000ull, { 18, 20, 0, 0, 0 }, 0x40, 1978, },
+ { 80, 5, 1, 0x0000000170000000ull, 0x000001e3f8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 43, },
+ { 81, 5, 1, 0x0000002080000000ull, 0x000001e3f80fe000ull, { 18, 20, 0, 0, 0 }, 0x40, 44, },
+ { 82, 5, 1, 0x0000000140000000ull, 0x000001e3f8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 45, },
+ { 83, 5, 1, 0x00000020b8000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 1979, },
+ { 83, 5, 1, 0x00000020b8000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x40, 46, },
+ { 84, 5, 1, 0x00000020b0000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 1980, },
+ { 84, 5, 1, 0x00000020b0000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x40, 47, },
+ { 85, 5, 1, 0x0000002180000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 798, },
+ { 85, 5, 1, 0x0000002180000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x40, 799, },
+ { 85, 5, 1, 0x0000002188000000ull, 0x000001eff8000000ull, { 18, 20, 19, 0, 0 }, 0x40, 941, },
+ { 86, 5, 1, 0x00000020c0000000ull, 0x000001eff8000000ull, { 18, 19, 0, 0, 0 }, 0x0, 896, },
+ { 86, 5, 1, 0x00000020c0000000ull, 0x000001eff8000000ull, { 18, 19, 0, 0, 0 }, 0x40, 897, },
+ { 87, 5, 1, 0x0000013000000000ull, 0x000001fc00000000ull, { 18, 20, 21, 19, 0 }, 0x0, 1997, },
+ { 87, 5, 1, 0x0000013000000000ull, 0x000001fc00000000ull, { 18, 20, 21, 19, 0 }, 0x40, 48, },
+ { 88, 5, 1, 0x00000020a8000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 1998, },
+ { 88, 5, 1, 0x00000020a8000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x40, 49, },
+ { 89, 5, 1, 0x0000002080000000ull, 0x000001e3f8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 1887, },
+ { 90, 5, 1, 0x00000020a0000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 1999, },
+ { 90, 5, 1, 0x00000020a0000000ull, 0x000001eff8000000ull, { 18, 19, 20, 0, 0 }, 0x40, 50, },
+ { 91, 5, 1, 0x0000013000000000ull, 0x000001fc000fe000ull, { 18, 20, 21, 0, 0 }, 0x40, 2000, },
+ { 92, 5, 1, 0x0000017000000000ull, 0x000001fc00000000ull, { 18, 20, 21, 19, 0 }, 0x0, 2001, },
+ { 92, 5, 1, 0x0000017000000000ull, 0x000001fc00000000ull, { 18, 20, 21, 19, 0 }, 0x40, 52, },
+ { 93, 5, 1, 0x0000002088000000ull, 0x000001e3f8000000ull, { 18, 20, 0, 0, 0 }, 0xc0, 53, },
+ { 94, 5, 1, 0x0000002088000000ull, 0x000001e3f80fe000ull, { 18, 20, 0, 0, 0 }, 0x40, 54, },
+ { 95, 5, 1, 0x000001b000000000ull, 0x000001fc00000000ull, { 18, 20, 21, 19, 0 }, 0x0, 2002, },
+ { 95, 5, 1, 0x000001b000000000ull, 0x000001fc00000000ull, { 18, 20, 21, 19, 0 }, 0x40, 55, },
+ { 96, 5, 1, 0x000001b000000000ull, 0x000001fc000fe000ull, { 18, 20, 21, 0, 0 }, 0x40, 2003, },
+ { 97, 5, 2, 0x0000002200000000ull, 0x000001fe00000000ull, { 18, 23, 19, 20, 0 }, 0x0, 2004, },
+ { 97, 5, 2, 0x0000002200000000ull, 0x000001fe00000000ull, { 18, 23, 19, 20, 0 }, 0x40, 57, },
+ { 98, 5, 2, 0x0000003200000000ull, 0x000001fe00000000ull, { 18, 23, 20, 0, 0 }, 0x0, 2005, },
+ { 98, 5, 2, 0x0000003200000000ull, 0x000001fe00000000ull, { 18, 23, 20, 0, 0 }, 0x40, 58, },
+ { 99, 5, 2, 0x0000000200000000ull, 0x000001fe00000000ull, { 18, 23, 19, 20, 0 }, 0x0, 2006, },
+ { 99, 5, 2, 0x0000000200000000ull, 0x000001fe00000000ull, { 18, 23, 19, 20, 0 }, 0x40, 59, },
+ { 100, 5, 2, 0x0000001200000000ull, 0x000001fe00000000ull, { 18, 23, 20, 0, 0 }, 0x0, 2007, },
+ { 100, 5, 2, 0x0000001200000000ull, 0x000001fe00000000ull, { 18, 23, 20, 0, 0 }, 0x40, 60, },
+ { 101, 5, 1, 0x000001c000000000ull, 0x000001f000000000ull, { 18, 20, 21, 19, 0 }, 0x0, 61, },
+ { 102, 5, 0, 0x0000000020000000ull, 0x000001eff8000000ull, { 50, 51, 0, 0, 0 }, 0x0, 2008, },
+ { 102, 5, 0, 0x0000000020000000ull, 0x000001eff8000000ull, { 50, 51, 0, 0, 0 }, 0x40, 62, },
+ { 103, 5, 1, 0x0000014008000000ull, 0x000001fff8000000ull, { 18, 20, 19, 0, 0 }, 0x40, 2011, },
+ { 104, 5, 1, 0x00000001a0000000ull, 0x000001e3f8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 64, },
+ { 105, 5, 1, 0x00000001e0000000ull, 0x000001e3f8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 1840, },
+ { 106, 3, 0, 0x0000000100000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x0, 65, },
+ { 108, 5, 1, 0x0000000178000000ull, 0x000001e3f8000000ull, { 18, 19, 20, 0, 0 }, 0x0, 66, },
+ { 113, 3, 1, 0x0000008708000000ull, 0x000001ffc8000000ull, { 24, 19, 0, 0, 0 }, 0x0, 2317, },
+ { 118, 4, 0, 0x0000004008000000ull, 0x000001e1f8000000ull, { 65, 0, 0, 0, 0 }, 0x0, 399, },
+ { 118, 5, 0, 0x000000000c000000ull, 0x000001e3fc000000ull, { 65, 0, 0, 0, 0 }, 0x0, 813, },
+ { 118, 2, 0, 0x000000000c000000ull, 0x000001effc000000ull, { 65, 0, 0, 0, 0 }, 0x2, 959, },
+ { 118, 3, 0, 0x000000000c000000ull, 0x000001effc000000ull, { 65, 0, 0, 0, 0 }, 0x0, 1050, },
+ { 118, 6, 0, 0x000000000c000000ull, 0x000001effc000000ull, { 69, 0, 0, 0, 0 }, 0x0, 2507, },
+ { 118, 7, 0, 0x0000000000000000ull, 0x0000000000000000ull, { 65, 0, 0, 0, 0 }, 0x0, 67, },
+ { 123, 3, 0, 0x0000000080000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x0, 68, },
+ { 123, 3, 0, 0x0000000090000000ull, 0x000001eff8000000ull, { 24, 0, 0, 0, 0 }, 0x0, 781, },
+ { 123, 3, 0, 0x0000000098000000ull, 0x000001eff8000000ull, { 18, 0, 0, 0, 0 }, 0x0, 782, },
+ { 124, 3, 0, 0x0000002170000000ull, 0x000001eff8000000ull, { 25, 0, 0, 0, 0 }, 0xc, 707, },
+ { 125, 3, 1, 0x0000002070000000ull, 0x000001eff8000000ull, { 30, 25, 0, 0, 0 }, 0x8, 708, },
+ { 125, 3, 1, 0x0000002078000000ull, 0x000001eff8000000ull, { 31, 25, 0, 0, 0 }, 0x8, 961, },
+ { 127, 3, 1, 0x0000008000000000ull, 0x000001fff8000000ull, { 24, 33, 0, 0, 0 }, 0x0, 69, },
+ { 127, 3, 1, 0x0000009000000000ull, 0x000001fff8000000ull, { 24, 33, 25, 0, 0 }, 0x400, 70, },
+ { 127, 3, 1, 0x000000a000000000ull, 0x000001eff0000000ull, { 24, 33, 62, 0, 0 }, 0x400, 71, },
+ { 128, 3, 2, 0x0000008a08000000ull, 0x000001fff8000000ull, { 24, 1, 33, 0, 0 }, 0x0, 72, },
+ { 129, 3, 1, 0x0000008040000000ull, 0x000001fff8000000ull, { 24, 33, 0, 0, 0 }, 0x0, 73, },
+ { 129, 3, 1, 0x0000009040000000ull, 0x000001fff8000000ull, { 24, 33, 25, 0, 0 }, 0x400, 74, },
+ { 129, 3, 1, 0x000000a040000000ull, 0x000001eff0000000ull, { 24, 33, 62, 0, 0 }, 0x400, 75, },
+ { 130, 3, 1, 0x0000008080000000ull, 0x000001fff8000000ull, { 24, 33, 0, 0, 0 }, 0x0, 76, },
+ { 130, 3, 1, 0x0000009080000000ull, 0x000001fff8000000ull, { 24, 33, 25, 0, 0 }, 0x400, 77, },
+ { 130, 3, 1, 0x000000a080000000ull, 0x000001eff0000000ull, { 24, 33, 62, 0, 0 }, 0x400, 78, },
+ { 131, 3, 1, 0x00000080c0000000ull, 0x000001fff8000000ull, { 24, 33, 0, 0, 0 }, 0x0, 79, },
+ { 131, 3, 1, 0x00000080c0000000ull, 0x000001fff8000000ull, { 24, 33, 83, 0, 0 }, 0x0, 1122, },
+ { 131, 3, 1, 0x00000090c0000000ull, 0x000001fff8000000ull, { 24, 33, 25, 0, 0 }, 0x400, 80, },
+ { 131, 3, 1, 0x000000a0c0000000ull, 0x000001eff0000000ull, { 24, 33, 62, 0, 0 }, 0x400, 81, },
+ { 132, 3, 1, 0x000000c6c0000000ull, 0x000001fff8000000ull, { 18, 33, 0, 0, 0 }, 0x0, 891, },
+ { 132, 3, 1, 0x000000d6c0000000ull, 0x000001fff8000000ull, { 18, 33, 25, 0, 0 }, 0x400, 892, },
+ { 132, 3, 1, 0x000000e6c0000000ull, 0x000001eff0000000ull, { 18, 33, 62, 0, 0 }, 0x400, 893, },
+ { 133, 3, 1, 0x000000c040000000ull, 0x000001fff8000000ull, { 18, 33, 0, 0, 0 }, 0x0, 82, },
+ { 133, 3, 1, 0x000000d040000000ull, 0x000001fff8000000ull, { 18, 33, 25, 0, 0 }, 0x400, 83, },
+ { 133, 3, 1, 0x000000e040000000ull, 0x000001eff0000000ull, { 18, 33, 62, 0, 0 }, 0x400, 84, },
+ { 134, 3, 1, 0x000000c0c0000000ull, 0x000001fff8000000ull, { 18, 33, 0, 0, 0 }, 0x0, 85, },
+ { 134, 3, 1, 0x000000d0c0000000ull, 0x000001fff8000000ull, { 18, 33, 25, 0, 0 }, 0x400, 86, },
+ { 134, 3, 1, 0x000000e0c0000000ull, 0x000001eff0000000ull, { 18, 33, 62, 0, 0 }, 0x400, 87, },
+ { 135, 3, 1, 0x000000c000000000ull, 0x000001fff8000000ull, { 18, 33, 0, 0, 0 }, 0x0, 88, },
+ { 135, 3, 1, 0x000000d000000000ull, 0x000001fff8000000ull, { 18, 33, 25, 0, 0 }, 0x400, 89, },
+ { 135, 3, 1, 0x000000e000000000ull, 0x000001eff0000000ull, { 18, 33, 62, 0, 0 }, 0x400, 90, },
+ { 136, 3, 2, 0x000000c048000000ull, 0x000001fff8000000ull, { 18, 19, 33, 0, 0 }, 0x0, 91, },
+ { 136, 3, 2, 0x000000d048000000ull, 0x000001fff8000000ull, { 18, 19, 33, 6, 0 }, 0x400, 92, },
+ { 137, 3, 2, 0x000000c0c8000000ull, 0x000001fff8000000ull, { 18, 19, 33, 0, 0 }, 0x0, 93, },
+ { 137, 3, 2, 0x000000d0c8000000ull, 0x000001fff8000000ull, { 18, 19, 33, 6, 0 }, 0x400, 94, },
+ { 138, 3, 2, 0x000000c088000000ull, 0x000001fff8000000ull, { 18, 19, 33, 0, 0 }, 0x0, 95, },
+ { 138, 3, 2, 0x000000d088000000ull, 0x000001fff8000000ull, { 18, 19, 33, 5, 0 }, 0x400, 96, },
+ { 139, 3, 1, 0x000000c080000000ull, 0x000001fff8000000ull, { 18, 33, 0, 0, 0 }, 0x0, 97, },
+ { 139, 3, 1, 0x000000d080000000ull, 0x000001fff8000000ull, { 18, 33, 25, 0, 0 }, 0x400, 98, },
+ { 139, 3, 1, 0x000000e080000000ull, 0x000001eff0000000ull, { 18, 33, 62, 0, 0 }, 0x400, 99, },
+ { 142, 3, 0, 0x000000cb00000000ull, 0x000001fff8000000ull, { 33, 0, 0, 0, 0 }, 0x0, 100, },
+ { 142, 3, 0, 0x000000db00000000ull, 0x000001fff8000000ull, { 33, 25, 0, 0, 0 }, 0x400, 101, },
+ { 142, 3, 0, 0x000000eb00000000ull, 0x000001eff0000000ull, { 33, 62, 0, 0, 0 }, 0x400, 102, },
+ { 143, 3, 0, 0x0000000050000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x21, 103, },
+ { 151, 3, 0, 0x0000000110000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x0, 104, },
+ { 152, 2, 1, 0x000000e880000000ull, 0x000001fff0000000ull, { 24, 25, 26, 0, 0 }, 0x0, 1841, },
+ { 153, 2, 1, 0x000000ea80000000ull, 0x000001fff0000000ull, { 24, 25, 26, 0, 0 }, 0x0, 1842, },
+ { 154, 2, 1, 0x000000f880000000ull, 0x000001fff0000000ull, { 24, 25, 26, 0, 0 }, 0x0, 1843, },
+ { 155, 1, 1, 0x0000010800000000ull, 0x000001fff80fe000ull, { 24, 26, 0, 0, 0 }, 0x0, 105, },
+ { 155, 1, 1, 0x0000010800000000ull, 0x000001ee07f00000ull, { 24, 63, 0, 0, 0 }, 0x40, 106, },
+ { 155, 1, 1, 0x0000012000000000ull, 0x000001e000300000ull, { 24, 66, 0, 0, 0 }, 0x40, 107, },
+ { 155, 5, 1, 0x0000000080000000ull, 0x000001e3f8000000ull, { 18, 20, 0, 0, 0 }, 0xc0, 108, },
+ { 155, 2, 1, 0x0000000e00100000ull, 0x000001ee00f00000ull, { 15, 25, 0, 0, 0 }, 0x40, 109, },
+ { 155, 2, 1, 0x0000000e00000000ull, 0x000001ee00f00000ull, { 15, 25, 78, 0, 0 }, 0x0, 2391, },
+ { 155, 2, 1, 0x0000000188000000ull, 0x000001eff8000000ull, { 24, 16, 0, 0, 0 }, 0x0, 111, },
+ { 155, 2, 1, 0x0000000600000000ull, 0x000001ee00000000ull, { 9, 25, 64, 0, 0 }, 0x0, 112, },
+ { 155, 2, 1, 0x0000000400000000ull, 0x000001ee00000000ull, { 10, 68, 0, 0, 0 }, 0x0, 113, },
+ { 155, 2, 1, 0x0000000180000000ull, 0x000001eff8000000ull, { 24, 8, 0, 0, 0 }, 0x0, 114, },
+ { 155, 2, 1, 0x0000000198000000ull, 0x000001eff8000000ull, { 24, 9, 0, 0, 0 }, 0x0, 115, },
+ { 155, 2, 1, 0x0000000150000000ull, 0x000001eff8000000ull, { 14, 25, 0, 0, 0 }, 0x0, 962, },
+ { 155, 2, 1, 0x0000000050000000ull, 0x000001eff8000000ull, { 14, 55, 0, 0, 0 }, 0x0, 963, },
+ { 155, 2, 1, 0x0000000190000000ull, 0x000001eff8000000ull, { 24, 14, 0, 0, 0 }, 0x0, 964, },
+ { 155, 3, 1, 0x0000000140000000ull, 0x000001eff8000000ull, { 14, 55, 0, 0, 0 }, 0x0, 1051, },
+ { 155, 3, 1, 0x0000002150000000ull, 0x000001eff8000000ull, { 14, 25, 0, 0, 0 }, 0x0, 1052, },
+ { 155, 3, 1, 0x0000002110000000ull, 0x000001eff8000000ull, { 24, 14, 0, 0, 0 }, 0x0, 1053, },
+ { 155, 3, 1, 0x0000002160000000ull, 0x000001eff8000000ull, { 17, 25, 0, 0, 0 }, 0x8, 116, },
+ { 155, 3, 1, 0x0000002120000000ull, 0x000001eff8000000ull, { 24, 17, 0, 0, 0 }, 0x8, 117, },
+ { 155, 3, 1, 0x0000002168000000ull, 0x000001eff8000000ull, { 12, 25, 0, 0, 0 }, 0x8, 118, },
+ { 155, 3, 1, 0x0000002148000000ull, 0x000001eff8000000ull, { 13, 25, 0, 0, 0 }, 0x0, 119, },
+ { 155, 3, 1, 0x0000002128000000ull, 0x000001eff8000000ull, { 24, 11, 0, 0, 0 }, 0x8, 120, },
+ { 155, 3, 1, 0x0000002108000000ull, 0x000001eff8000000ull, { 24, 13, 0, 0, 0 }, 0x0, 121, },
+ { 155, 3, 1, 0x0000002000000000ull, 0x000001eff8000000ull, { 38, 25, 0, 0, 0 }, 0x8, 122, },
+ { 155, 3, 1, 0x0000002008000000ull, 0x000001eff8000000ull, { 29, 25, 0, 0, 0 }, 0x8, 123, },
+ { 155, 3, 1, 0x0000002010000000ull, 0x000001eff8000000ull, { 32, 25, 0, 0, 0 }, 0x8, 124, },
+ { 155, 3, 1, 0x0000002018000000ull, 0x000001eff8000000ull, { 35, 25, 0, 0, 0 }, 0x8, 125, },
+ { 155, 3, 1, 0x0000002020000000ull, 0x000001eff8000000ull, { 36, 25, 0, 0, 0 }, 0x8, 126, },
+ { 155, 3, 1, 0x0000002028000000ull, 0x000001eff8000000ull, { 37, 25, 0, 0, 0 }, 0x8, 127, },
+ { 155, 3, 1, 0x0000002030000000ull, 0x000001eff8000000ull, { 34, 25, 0, 0, 0 }, 0x8, 128, },
+ { 155, 3, 1, 0x0000002080000000ull, 0x000001eff8000000ull, { 24, 38, 0, 0, 0 }, 0x8, 129, },
+ { 155, 3, 1, 0x0000002088000000ull, 0x000001eff8000000ull, { 24, 29, 0, 0, 0 }, 0x8, 130, },
+ { 155, 3, 1, 0x0000002090000000ull, 0x000001eff8000000ull, { 24, 32, 0, 0, 0 }, 0x8, 131, },
+ { 155, 3, 1, 0x0000002098000000ull, 0x000001eff8000000ull, { 24, 35, 0, 0, 0 }, 0x8, 132, },
+ { 155, 3, 1, 0x00000020a0000000ull, 0x000001eff8000000ull, { 24, 36, 0, 0, 0 }, 0x8, 133, },
+ { 155, 3, 1, 0x00000020a8000000ull, 0x000001eff8000000ull, { 24, 37, 0, 0, 0 }, 0x0, 134, },
+ { 155, 3, 1, 0x00000020b0000000ull, 0x000001eff8000000ull, { 24, 34, 0, 0, 0 }, 0x8, 135, },
+ { 155, 3, 1, 0x00000020b8000000ull, 0x000001eff8000000ull, { 24, 28, 0, 0, 0 }, 0x0, 136, },
+ { 155, 7, 1, 0x0000000000000000ull, 0x0000000000000000ull, { 24, 14, 0, 0, 0 }, 0x0, 137, },
+ { 155, 7, 1, 0x0000000000000000ull, 0x0000000000000000ull, { 14, 55, 0, 0, 0 }, 0x0, 138, },
+ { 155, 7, 1, 0x0000000000000000ull, 0x0000000000000000ull, { 14, 25, 0, 0, 0 }, 0x0, 139, },
+ { 156, 6, 1, 0x000000c000000000ull, 0x000001e000100000ull, { 24, 70, 0, 0, 0 }, 0x0, 140, },
+ { 157, 2, 1, 0x000000eca0000000ull, 0x000001fff0000000ull, { 24, 25, 74, 0, 0 }, 0x0, 141, },
+ { 158, 2, 1, 0x000000eea0000000ull, 0x000001fff0000000ull, { 24, 25, 75, 0, 0 }, 0x0, 142, },
+ { 168, 4, 0, 0x0000004000000000ull, 0x000001e1f8000000ull, { 65, 0, 0, 0, 0 }, 0x0, 400, },
+ { 168, 5, 0, 0x0000000008000000ull, 0x000001e3fc000000ull, { 65, 0, 0, 0, 0 }, 0x0, 814, },
+ { 168, 2, 0, 0x0000000008000000ull, 0x000001effc000000ull, { 65, 0, 0, 0, 0 }, 0x2, 965, },
+ { 168, 3, 0, 0x0000000008000000ull, 0x000001effc000000ull, { 65, 0, 0, 0, 0 }, 0x0, 1054, },
+ { 168, 6, 0, 0x0000000008000000ull, 0x000001effc000000ull, { 69, 0, 0, 0, 0 }, 0x0, 2508, },
+ { 168, 7, 0, 0x0000000000000000ull, 0x0000000000000000ull, { 65, 0, 0, 0, 0 }, 0x0, 143, },
+ { 175, 1, 1, 0x0000010070000000ull, 0x000001eff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 144, },
+ { 175, 1, 1, 0x0000010170000000ull, 0x000001eff8000000ull, { 24, 55, 26, 0, 0 }, 0x0, 145, },
+ { 178, 2, 1, 0x000000ea00000000ull, 0x000001fff0000000ull, { 24, 25, 26, 0, 0 }, 0x0, 2490, },
+ { 179, 2, 1, 0x000000f820000000ull, 0x000001fff0000000ull, { 24, 25, 26, 0, 0 }, 0x0, 2393, },
+ { 180, 1, 1, 0x0000010400000000ull, 0x000001fff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 146, },
+ { 181, 1, 1, 0x0000010600000000ull, 0x000001fff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 147, },
+ { 182, 1, 1, 0x0000011400000000ull, 0x000001fff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 148, },
+ { 183, 1, 1, 0x0000010450000000ull, 0x000001fff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 149, },
+ { 184, 1, 1, 0x0000010650000000ull, 0x000001fff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 150, },
+ { 185, 1, 1, 0x0000010470000000ull, 0x000001fff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 151, },
+ { 186, 1, 1, 0x0000010670000000ull, 0x000001fff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 152, },
+ { 187, 1, 1, 0x0000010520000000ull, 0x000001fff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 800, },
+ { 188, 1, 1, 0x0000010720000000ull, 0x000001fff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 801, },
+ { 189, 1, 1, 0x0000011520000000ull, 0x000001fff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 802, },
+ { 190, 2, 1, 0x000000e850000000ull, 0x000001fff0000000ull, { 24, 25, 26, 0, 0 }, 0x0, 2407, },
+ { 191, 2, 1, 0x000000ea70000000ull, 0x000001fff0000000ull, { 24, 25, 26, 0, 0 }, 0x0, 153, },
+ { 192, 2, 1, 0x000000e810000000ull, 0x000001fff0000000ull, { 24, 25, 26, 0, 0 }, 0x0, 2408, },
+ { 193, 2, 1, 0x000000ea30000000ull, 0x000001fff0000000ull, { 24, 25, 26, 0, 0 }, 0x0, 154, },
+ { 194, 2, 1, 0x000000ead0000000ull, 0x000001fff0000000ull, { 24, 25, 26, 0, 0 }, 0x0, 1844, },
+ { 195, 2, 1, 0x000000e230000000ull, 0x000001ff30000000ull, { 24, 25, 26, 42, 0 }, 0x0, 155, },
+ { 196, 2, 1, 0x000000e690000000ull, 0x000001fff0000000ull, { 24, 26, 0, 0, 0 }, 0x0, 156, },
+ { 198, 3, 1, 0x00000021c0000000ull, 0x000001eff8000000ull, { 24, 26, 25, 0, 0 }, 0x0, 1845, },
+ { 198, 3, 1, 0x00000020c0000000ull, 0x000001eff8000000ull, { 24, 26, 49, 0, 0 }, 0x0, 1846, },
+ { 198, 3, 0, 0x0000002188000000ull, 0x000001eff8000000ull, { 26, 49, 0, 0, 0 }, 0x0, 1870, },
+ { 199, 2, 1, 0x000000e8b0000000ull, 0x000001fff0000000ull, { 24, 25, 26, 0, 0 }, 0x0, 157, },
+ { 200, 2, 1, 0x000000e240000000ull, 0x000001fff0000000ull, { 24, 25, 26, 0, 0 }, 0x0, 158, },
+ { 200, 2, 1, 0x000000ee50000000ull, 0x000001fff0000000ull, { 24, 25, 39, 0, 0 }, 0x0, 159, },
+ { 201, 2, 1, 0x000000f040000000ull, 0x000001fff0000000ull, { 24, 25, 26, 0, 0 }, 0x0, 160, },
+ { 201, 2, 1, 0x000000fc50000000ull, 0x000001fff0000000ull, { 24, 25, 39, 0, 0 }, 0x0, 161, },
+ { 202, 1, 1, 0x0000010680000000ull, 0x000001ffe0000000ull, { 24, 25, 41, 26, 0 }, 0x0, 162, },
+ { 203, 2, 1, 0x000000e220000000ull, 0x000001fff0000000ull, { 24, 26, 25, 0, 0 }, 0x0, 163, },
+ { 203, 2, 1, 0x000000e630000000ull, 0x000001fff0000000ull, { 24, 26, 43, 0, 0 }, 0x0, 164, },
+ { 204, 2, 1, 0x000000f020000000ull, 0x000001fff0000000ull, { 24, 26, 25, 0, 0 }, 0x0, 165, },
+ { 204, 2, 1, 0x000000f430000000ull, 0x000001fff0000000ull, { 24, 26, 43, 0, 0 }, 0x0, 166, },
+ { 205, 1, 1, 0x00000106c0000000ull, 0x000001ffe0000000ull, { 24, 25, 41, 26, 0 }, 0x0, 167, },
+ { 206, 1, 1, 0x0000010420000000ull, 0x000001fff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 168, },
+ { 207, 1, 1, 0x0000010620000000ull, 0x000001fff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 169, },
+ { 208, 1, 1, 0x0000011420000000ull, 0x000001fff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 170, },
+ { 209, 3, 0, 0x0000002048000000ull, 0x000001eff8000000ull, { 26, 25, 0, 0, 0 }, 0x8, 993, },
+ { 209, 3, 0, 0x0000002050000000ull, 0x000001eff8000000ull, { 26, 25, 0, 0, 0 }, 0xc, 902, },
+ { 209, 3, 0, 0x00000021a0000000ull, 0x000001eff8000000ull, { 26, 0, 0, 0, 0 }, 0x8, 783, },
+ { 210, 3, 0, 0x0000002060000000ull, 0x000001eff8000000ull, { 26, 25, 0, 0, 0 }, 0x8, 709, },
+ { 215, 4, 0, 0x0000000040000000ull, 0x000001e1f8000000ull, { 0, 0, 0, 0, 0 }, 0x22c, 171, },
+ { 216, 3, 0, 0x0000000038000000ull, 0x000001ee78000000ull, { 67, 0, 0, 0, 0 }, 0x8, 172, },
+ { 217, 3, 0, 0x0000000028000000ull, 0x000001ee78000000ull, { 67, 0, 0, 0, 0 }, 0x0, 173, },
+ { 226, 3, 1, 0x000000c708000000ull, 0x000001ffc8000000ull, { 18, 25, 0, 0, 0 }, 0x0, 2318, },
+ { 227, 2, 1, 0x000000a600000000ull, 0x000001ee04000000ull, { 24, 25, 45, 0, 0 }, 0x140, 174, },
+ { 227, 2, 1, 0x000000f240000000ull, 0x000001fff0000000ull, { 24, 25, 26, 0, 0 }, 0x0, 175, },
+ { 228, 1, 1, 0x0000010080000000ull, 0x000001efe0000000ull, { 24, 25, 40, 26, 0 }, 0x0, 176, },
+ { 229, 1, 1, 0x00000100c0000000ull, 0x000001efe0000000ull, { 24, 25, 40, 26, 0 }, 0x0, 177, },
+ { 230, 2, 1, 0x000000a400000000ull, 0x000001ee00002000ull, { 24, 26, 76, 0, 0 }, 0x140, 2414, },
+ { 230, 2, 1, 0x000000f220000000ull, 0x000001fff0000000ull, { 24, 26, 25, 0, 0 }, 0x0, 179, },
+ { 231, 2, 1, 0x000000ac00000000ull, 0x000001ee00000000ull, { 24, 25, 26, 44, 0 }, 0x0, 180, },
+ { 236, 3, 0, 0x0000000180000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x0, 711, },
+ { 237, 3, 0, 0x0000000030000000ull, 0x000001ee78000000ull, { 67, 0, 0, 0, 0 }, 0x8, 181, },
+ { 239, 3, 1, 0x0000008c00000000ull, 0x000001fff8000000ull, { 33, 25, 0, 0, 0 }, 0x0, 182, },
+ { 239, 3, 1, 0x000000ac00000000ull, 0x000001eff0000000ull, { 33, 25, 61, 0, 0 }, 0x400, 183, },
+ { 240, 3, 1, 0x0000008c08000000ull, 0x000001fff8000000ull, { 33, 25, 1, 0, 0 }, 0x0, 184, },
+ { 241, 3, 1, 0x0000008c40000000ull, 0x000001fff8000000ull, { 33, 25, 0, 0, 0 }, 0x0, 185, },
+ { 241, 3, 1, 0x000000ac40000000ull, 0x000001eff0000000ull, { 33, 25, 61, 0, 0 }, 0x400, 186, },
+ { 242, 3, 1, 0x0000008c80000000ull, 0x000001fff8000000ull, { 33, 25, 0, 0, 0 }, 0x0, 187, },
+ { 242, 3, 1, 0x000000ac80000000ull, 0x000001eff0000000ull, { 33, 25, 61, 0, 0 }, 0x400, 188, },
+ { 243, 3, 1, 0x0000008cc0000000ull, 0x000001fff8000000ull, { 33, 25, 0, 0, 0 }, 0x0, 189, },
+ { 243, 3, 1, 0x000000acc0000000ull, 0x000001eff0000000ull, { 33, 25, 61, 0, 0 }, 0x400, 190, },
+ { 244, 3, 1, 0x000000cec0000000ull, 0x000001fff8000000ull, { 33, 19, 0, 0, 0 }, 0x0, 2321, },
+ { 244, 3, 1, 0x000000eec0000000ull, 0x000001eff0000000ull, { 33, 19, 61, 0, 0 }, 0x400, 2322, },
+ { 245, 3, 1, 0x000000cc40000000ull, 0x000001fff8000000ull, { 33, 19, 0, 0, 0 }, 0x0, 191, },
+ { 245, 3, 1, 0x000000ec40000000ull, 0x000001eff0000000ull, { 33, 19, 61, 0, 0 }, 0x400, 192, },
+ { 246, 3, 1, 0x000000ccc0000000ull, 0x000001fff8000000ull, { 33, 19, 0, 0, 0 }, 0x0, 193, },
+ { 246, 3, 1, 0x000000ecc0000000ull, 0x000001eff0000000ull, { 33, 19, 61, 0, 0 }, 0x400, 194, },
+ { 247, 3, 1, 0x000000cc00000000ull, 0x000001fff8000000ull, { 33, 19, 0, 0, 0 }, 0x0, 195, },
+ { 247, 3, 1, 0x000000ec00000000ull, 0x000001eff0000000ull, { 33, 19, 61, 0, 0 }, 0x400, 196, },
+ { 248, 3, 1, 0x000000cc80000000ull, 0x000001fff8000000ull, { 33, 19, 0, 0, 0 }, 0x0, 197, },
+ { 248, 3, 1, 0x000000ec80000000ull, 0x000001eff0000000ull, { 33, 19, 61, 0, 0 }, 0x400, 198, },
+ { 249, 1, 1, 0x0000010028000000ull, 0x000001eff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 199, },
+ { 249, 1, 1, 0x0000010020000000ull, 0x000001eff8000000ull, { 24, 25, 26, 4, 0 }, 0x0, 200, },
+ { 249, 1, 1, 0x0000010128000000ull, 0x000001eff8000000ull, { 24, 55, 26, 0, 0 }, 0x0, 201, },
+ { 250, 3, 0, 0x0000000020000000ull, 0x000001ee78000000ull, { 67, 0, 0, 0, 0 }, 0x0, 202, },
+ { 251, 2, 1, 0x00000000a0000000ull, 0x000001eff8000000ull, { 24, 26, 0, 0, 0 }, 0x0, 203, },
+ { 252, 2, 1, 0x00000000a8000000ull, 0x000001eff8000000ull, { 24, 26, 0, 0, 0 }, 0x0, 204, },
+ { 253, 2, 1, 0x00000000b0000000ull, 0x000001eff8000000ull, { 24, 26, 0, 0, 0 }, 0x0, 205, },
+ { 254, 3, 0, 0x0000000198000000ull, 0x000001eff8000000ull, { 0, 0, 0, 0, 0 }, 0x0, 968, },
+ { 255, 3, 1, 0x00000020f8000000ull, 0x000001eff8000000ull, { 24, 26, 0, 0, 0 }, 0x8, 206, },
+ { 256, 2, 2, 0x000000a000000000ull, 0x000001fe00003000ull, { 22, 23, 26, 76, 0 }, 0x0, 2513, },
+ { 256, 2, 2, 0x000000a000000000ull, 0x000001fe00003000ull, { 23, 22, 26, 76, 0 }, 0x40, 1745, },
+ { 257, 3, 1, 0x00000020d0000000ull, 0x000001eff8000000ull, { 24, 26, 0, 0, 0 }, 0x0, 207, },
+ { 258, 2, 2, 0x000000a000002000ull, 0x000001fe00003000ull, { 22, 23, 26, 0, 0 }, 0x0, 2515, },
+ { 258, 2, 2, 0x000000a000002000ull, 0x000001fe00003000ull, { 23, 22, 26, 0, 0 }, 0x40, 1747, },
+ { 259, 3, 1, 0x00000020f0000000ull, 0x000001eff8000000ull, { 24, 26, 0, 0, 0 }, 0x8, 208, },
+ { 261, 3, 1, 0x00000020d8000000ull, 0x000001eff8000000ull, { 24, 26, 0, 0, 0 }, 0x0, 209, },
+ { 265, 2, 1, 0x000000e840000000ull, 0x000001fff0000000ull, { 24, 25, 26, 0, 0 }, 0x0, 949, },
+ { 266, 2, 1, 0x000000ea40000000ull, 0x000001fff0000000ull, { 24, 25, 26, 0, 0 }, 0x0, 950, },
+ { 267, 2, 1, 0x000000f840000000ull, 0x000001fff0000000ull, { 24, 25, 26, 0, 0 }, 0x0, 951, },
+ { 275, 3, 1, 0x0000008208000000ull, 0x000001fff8000000ull, { 24, 33, 25, 0, 0 }, 0x0, 210, },
+ { 276, 3, 1, 0x0000008248000000ull, 0x000001fff8000000ull, { 24, 33, 25, 0, 0 }, 0x0, 211, },
+ { 277, 3, 1, 0x0000008288000000ull, 0x000001fff8000000ull, { 24, 33, 25, 0, 0 }, 0x0, 212, },
+ { 278, 3, 1, 0x00000082c8000000ull, 0x000001fff8000000ull, { 24, 33, 25, 0, 0 }, 0x0, 213, },
+ { 280, 5, 1, 0x000001d000000000ull, 0x000001fc00000000ull, { 18, 20, 21, 19, 0 }, 0x0, 997, },
+ { 280, 5, 1, 0x000001d000000000ull, 0x000001fc00000000ull, { 18, 20, 21, 19, 0 }, 0x40, 1045, },
+ { 281, 5, 1, 0x000001d000000000ull, 0x000001fc000fe000ull, { 18, 20, 21, 0, 0 }, 0x40, 998, },
+ { 282, 1, 1, 0x0000010078000000ull, 0x000001eff8000000ull, { 24, 25, 26, 0, 0 }, 0x0, 214, },
+ { 282, 1, 1, 0x0000010178000000ull, 0x000001eff8000000ull, { 24, 55, 26, 0, 0 }, 0x0, 215, },
+ { 285, 2, 1, 0x0000000080000000ull, 0x000001eff8000000ull, { 24, 26, 0, 0, 0 }, 0x0, 216, },
+ { 286, 2, 1, 0x0000000088000000ull, 0x000001eff8000000ull, { 24, 26, 0, 0, 0 }, 0x0, 217, },
+ { 287, 2, 1, 0x0000000090000000ull, 0x000001eff8000000ull, { 24, 26, 0, 0, 0 }, 0x0, 218, },
};
static const char dis_table[] = {
-0xa0, 0xc2, 0xa0, 0xa0, 0x2c, 0xc0, 0xa0, 0x2a, 0xc0, 0xa0, 0x1a, 0x70,
-0x98, 0xb0, 0x01, 0x40, 0x90, 0x50, 0x90, 0x28, 0x24, 0x31, 0x48, 0x24,
-0x31, 0x40, 0x90, 0x28, 0x24, 0x31, 0x38, 0x24, 0x31, 0x30, 0x90, 0x50,
-0x90, 0x28, 0x24, 0x31, 0x20, 0x24, 0x31, 0x18, 0x90, 0x28, 0x24, 0x31,
-0x10, 0x24, 0x31, 0x08, 0xa8, 0x0b, 0x28, 0x15, 0x00, 0x97, 0x00, 0x95,
-0xa8, 0x9a, 0x98, 0x05, 0x18, 0x90, 0xf8, 0x90, 0x80, 0x90, 0x40, 0x80,
-0xa4, 0x21, 0x18, 0x34, 0x26, 0x80, 0xa4, 0x2e, 0xc0, 0x35, 0xdd, 0x90,
-0x50, 0x90, 0x28, 0x80, 0x35, 0xd3, 0x80, 0x34, 0x0a, 0x81, 0x33, 0xa6,
-0x90, 0xe0, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x20, 0x30, 0x34, 0x07, 0xa4,
-0x1d, 0x28, 0x34, 0x04, 0x90, 0x38, 0xa4, 0x30, 0xc0, 0x36, 0x1e, 0xa4,
-0x30, 0x68, 0x36, 0x12, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x2f, 0x40, 0x35,
-0xf3, 0xa4, 0x2f, 0x18, 0x35, 0xee, 0x80, 0xa4, 0x20, 0x10, 0x34, 0x03,
-0x92, 0x18, 0x91, 0xc0, 0x80, 0x91, 0x80, 0x90, 0xf8, 0xdb, 0x84, 0x60,
-0xea, 0x40, 0xc0, 0xc0, 0x80, 0xa4, 0x3a, 0x70, 0x8c, 0x3b, 0xd0, 0x84,
-0x37, 0x84, 0xc0, 0xc0, 0x80, 0xa4, 0x3a, 0x60, 0x8c, 0x3b, 0xb0, 0x84,
-0x37, 0x82, 0xd3, 0x82, 0x40, 0x50, 0xc0, 0xc0, 0x81, 0x37, 0x36, 0x50,
-0xc0, 0xc0, 0x81, 0x37, 0x34, 0xa4, 0x1d, 0x38, 0x33, 0xa8, 0x80, 0x90,
-0x28, 0x80, 0x33, 0xa4, 0x80, 0x34, 0x0c, 0x81, 0x90, 0x38, 0xa4, 0x20,
-0x98, 0x34, 0x0f, 0xa4, 0x20, 0x68, 0x34, 0x09, 0xc0, 0x40, 0x10, 0x10,
-0x90, 0x38, 0xa4, 0x1d, 0x10, 0x33, 0xa3, 0xa4, 0x1d, 0x00, 0x33, 0xa1,
-0x18, 0x24, 0x21, 0x10, 0x83, 0x90, 0xa8, 0xd3, 0x82, 0xc0, 0xc0, 0xc0,
-0x80, 0xa4, 0x3a, 0x40, 0x37, 0x6e, 0xc0, 0xc0, 0x80, 0xa4, 0x3a, 0x30,
-0x37, 0x6a, 0xd3, 0x82, 0x40, 0x50, 0xc0, 0xc0, 0x81, 0x37, 0x30, 0x50,
-0xc0, 0xc0, 0x81, 0x37, 0x2e, 0x92, 0xb8, 0x99, 0x84, 0x20, 0x88, 0x90,
-0x78, 0x90, 0x50, 0x10, 0x10, 0x80, 0xa4, 0x2e, 0xb8, 0x35, 0xdc, 0x82,
-0x35, 0xd2, 0x90, 0x80, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x30, 0xb8, 0x36,
-0x1d, 0xa4, 0x30, 0x60, 0x36, 0x11, 0x80, 0x90, 0x38, 0xa4, 0x2f, 0x38,
-0x35, 0xf2, 0xa4, 0x2f, 0x10, 0x35, 0xed, 0x83, 0x90, 0xa8, 0xd3, 0x82,
-0xc0, 0xc0, 0xc0, 0x80, 0xa4, 0x3a, 0x10, 0x37, 0x62, 0xc0, 0xc0, 0x80,
-0xa4, 0x3a, 0x00, 0x37, 0x5e, 0xd3, 0x82, 0x40, 0x50, 0xc0, 0xc0, 0x81,
-0x37, 0x2a, 0x50, 0xc0, 0xc0, 0x81, 0x37, 0x28, 0x18, 0x24, 0x20, 0x90,
-0x83, 0x90, 0xa8, 0xd3, 0x82, 0xc0, 0xc0, 0xc0, 0x80, 0xa4, 0x39, 0xe0,
-0x37, 0x56, 0xc0, 0xc0, 0x80, 0xa4, 0x39, 0xd0, 0x37, 0x52, 0xd3, 0x82,
-0x40, 0x50, 0xc0, 0xc0, 0x81, 0x37, 0x24, 0x50, 0xc0, 0xc0, 0x81, 0x37,
-0x22, 0x94, 0x50, 0x92, 0xf8, 0x99, 0x84, 0x1d, 0x68, 0x90, 0x78, 0x90,
-0x50, 0x10, 0x10, 0x80, 0xa4, 0x2e, 0xb0, 0x35, 0xdb, 0x82, 0x35, 0xd1,
-0x90, 0x80, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x30, 0xb0, 0x36, 0x1c, 0xa4,
-0x30, 0x58, 0x36, 0x10, 0x80, 0x90, 0x38, 0xa4, 0x2f, 0x30, 0x35, 0xf1,
-0xa4, 0x2f, 0x08, 0x35, 0xec, 0x83, 0x90, 0xe8, 0xd3, 0x83, 0xc0, 0xc0,
-0xc0, 0x80, 0xa4, 0x3a, 0x80, 0x8c, 0x3b, 0xf0, 0x84, 0x37, 0x86, 0xc0,
-0xc0, 0x80, 0xa4, 0x3a, 0x68, 0x8c, 0x3b, 0xc0, 0x84, 0x37, 0x83, 0xd3,
-0x82, 0x40, 0x50, 0xc0, 0xc0, 0x81, 0x37, 0x38, 0x50, 0xc0, 0xc0, 0x81,
-0x37, 0x35, 0x18, 0x24, 0x1d, 0x60, 0x83, 0x90, 0xa8, 0xd3, 0x82, 0xc0,
-0xc0, 0xc0, 0x80, 0xa4, 0x3a, 0x50, 0x37, 0x72, 0xc0, 0xc0, 0x80, 0xa4,
-0x3a, 0x38, 0x37, 0x6c, 0xd3, 0x82, 0x40, 0x50, 0xc0, 0xc0, 0x81, 0x37,
-0x32, 0x50, 0xc0, 0xc0, 0x81, 0x37, 0x2f, 0x92, 0xb8, 0x99, 0x84, 0x1d,
-0x58, 0x90, 0x78, 0x90, 0x50, 0x10, 0x10, 0x80, 0xa4, 0x2e, 0xa8, 0x35,
-0xda, 0x82, 0x35, 0xd0, 0x90, 0x80, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x30,
-0xa8, 0x36, 0x1b, 0xa4, 0x30, 0x50, 0x36, 0x0f, 0x80, 0x90, 0x38, 0xa4,
-0x2f, 0x28, 0x35, 0xf0, 0xa4, 0x2f, 0x00, 0x35, 0xeb, 0x83, 0x90, 0xa8,
-0xd3, 0x82, 0xc0, 0xc0, 0xc0, 0x80, 0xa4, 0x3a, 0x20, 0x37, 0x66, 0xc0,
-0xc0, 0x80, 0xa4, 0x3a, 0x08, 0x37, 0x60, 0xd3, 0x82, 0x40, 0x50, 0xc0,
-0xc0, 0x81, 0x37, 0x2c, 0x50, 0xc0, 0xc0, 0x81, 0x37, 0x29, 0x18, 0x20,
-0x01, 0x48, 0x83, 0x90, 0xa8, 0xd3, 0x82, 0xc0, 0xc0, 0xc0, 0x80, 0xa4,
-0x39, 0xf0, 0x37, 0x5a, 0xc0, 0xc0, 0x80, 0xa4, 0x39, 0xd8, 0x37, 0x54,
-0xd3, 0x82, 0x40, 0x50, 0xc0, 0xc0, 0x81, 0x37, 0x26, 0x50, 0xc0, 0xc0,
-0x81, 0x37, 0x23, 0xda, 0x06, 0xe0, 0xea, 0x80, 0x90, 0x60, 0x90, 0x38,
-0xa4, 0x21, 0x00, 0x34, 0x1e, 0x80, 0x34, 0x1b, 0x90, 0x38, 0xa4, 0x20,
-0xa8, 0x34, 0x19, 0x80, 0x34, 0x16, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x20,
-0xe8, 0x34, 0x1f, 0x80, 0x34, 0x1c, 0x90, 0x38, 0xa4, 0x20, 0xc0, 0x34,
-0x1a, 0x80, 0x34, 0x17, 0xc8, 0x40, 0x18, 0x00, 0x91, 0x38, 0x90, 0x40,
-0x82, 0xa4, 0x2e, 0x70, 0x35, 0xcf, 0x90, 0xc0, 0x80, 0x90, 0x90, 0x90,
-0x48, 0xc9, 0xe1, 0x82, 0x00, 0x85, 0x36, 0x07, 0xc9, 0xe1, 0x81, 0x40,
-0x85, 0x36, 0x04, 0x80, 0x36, 0x03, 0x10, 0x10, 0x81, 0x35, 0xdf, 0x90,
-0xa8, 0x10, 0x10, 0x90, 0x28, 0x81, 0x35, 0xfd, 0x90, 0x38, 0xa4, 0x2f,
-0xc0, 0x35, 0xf9, 0xa4, 0x2f, 0xb0, 0x35, 0xf7, 0x90, 0x70, 0x10, 0x10,
-0x90, 0x38, 0xa4, 0x2f, 0xd8, 0x35, 0xfc, 0x80, 0x35, 0xfa, 0x90, 0x60,
-0x90, 0x28, 0x24, 0x30, 0x10, 0xa4, 0x30, 0x00, 0x36, 0x01, 0x80, 0xa4,
-0x2f, 0xf0, 0x35, 0xff, 0x80, 0x90, 0xf8, 0x90, 0x90, 0x90, 0x50, 0x90,
-0x28, 0x80, 0x37, 0x1a, 0x80, 0x37, 0x21, 0x80, 0xa4, 0x38, 0xf8, 0x37,
-0x20, 0x90, 0x28, 0x81, 0x37, 0x1e, 0x80, 0xa4, 0x38, 0xe0, 0x37, 0x1d,
-0x83, 0x37, 0x1b, 0x98, 0xb0, 0x01, 0x40, 0x90, 0x50, 0x90, 0x28, 0x24,
-0x2e, 0x60, 0x24, 0x2e, 0x58, 0x90, 0x28, 0x24, 0x2e, 0x50, 0x24, 0x2e,
-0x48, 0x90, 0x50, 0x90, 0x28, 0x24, 0x2e, 0x38, 0x24, 0x2e, 0x30, 0x90,
-0x28, 0x24, 0x2e, 0x28, 0x24, 0x2e, 0x20, 0xa8, 0x09, 0x00, 0x0e, 0x20,
-0x96, 0x48, 0x95, 0xe8, 0x93, 0x38, 0x91, 0xa0, 0x90, 0xd0, 0x90, 0x70,
-0x90, 0x38, 0xa4, 0x1c, 0x88, 0x33, 0x92, 0xa4, 0x1c, 0x78, 0x33, 0x90,
-0x90, 0x38, 0xa4, 0x1c, 0x68, 0x33, 0x8e, 0x80, 0x33, 0x8c, 0x90, 0x60,
-0x90, 0x28, 0x24, 0x1c, 0x28, 0xa4, 0x1c, 0x18, 0x33, 0x84, 0x90, 0x38,
-0xa4, 0x1c, 0x08, 0x33, 0x82, 0xa4, 0x1c, 0x50, 0x33, 0x8b, 0x90, 0xe0,
-0x90, 0x70, 0x90, 0x38, 0xa4, 0x1c, 0x40, 0x33, 0x89, 0xa4, 0x1c, 0x30,
-0x33, 0x87, 0x90, 0x38, 0xa4, 0x2d, 0xd8, 0x35, 0xc1, 0xa4, 0x2d, 0x78,
-0x35, 0xb5, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x2a, 0xb0, 0x35, 0x62, 0xa4,
-0x2a, 0x80, 0x35, 0x5c, 0x10, 0x10, 0xa4, 0x1b, 0xf8, 0x33, 0x80, 0x99,
-0x60, 0x02, 0x70, 0x90, 0x90, 0x90, 0x50, 0x90, 0x28, 0x24, 0x1c, 0xb8,
-0x80, 0x33, 0x9e, 0x80, 0xa4, 0x1c, 0xc0, 0x33, 0x9c, 0x90, 0x50, 0x90,
-0x28, 0x24, 0x1c, 0xc8, 0x80, 0x33, 0x9f, 0x90, 0x38, 0xa4, 0x1c, 0xd0,
-0x33, 0x9d, 0xa4, 0x1c, 0x98, 0x33, 0x94, 0x90, 0xe0, 0x90, 0x70, 0x90,
-0x38, 0xa4, 0x2d, 0x08, 0x35, 0xa9, 0xa4, 0x2c, 0x68, 0x35, 0x96, 0x90,
-0x38, 0xa4, 0x2c, 0x00, 0x35, 0x87, 0xa4, 0x2b, 0x70, 0x35, 0x76, 0x81,
-0xa4, 0x1c, 0xa8, 0x33, 0x96, 0xe4, 0xa1, 0xc5, 0x00, 0x37, 0x16, 0x18,
-0x24, 0x1b, 0xf0, 0xe4, 0xe1, 0xc3, 0x80, 0x37, 0x10, 0x92, 0x40, 0x91,
-0x08, 0x10, 0x10, 0x90, 0x80, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x2d, 0xd0,
-0x35, 0xc0, 0xa4, 0x2d, 0x70, 0x35, 0xb4, 0x80, 0x90, 0x38, 0xa4, 0x2a,
-0xa8, 0x35, 0x61, 0xa4, 0x2a, 0x78, 0x35, 0x5b, 0x18, 0x20, 0x00, 0xf8,
-0x80, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x2c, 0xf8, 0x35, 0xa8, 0xa4, 0x2c,
-0x60, 0x35, 0x94, 0x90, 0x38, 0xa4, 0x2b, 0xf0, 0x35, 0x86, 0xa4, 0x2b,
-0x68, 0x35, 0x74, 0xe4, 0xa1, 0xc2, 0x00, 0x37, 0x0a, 0x18, 0x24, 0x1b,
-0xe8, 0xe4, 0xe1, 0xc0, 0x80, 0x37, 0x04, 0x92, 0x90, 0x92, 0x40, 0x91,
-0x08, 0x10, 0x10, 0x90, 0x80, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x2d, 0xc8,
-0x35, 0xbf, 0xa4, 0x2d, 0x68, 0x35, 0xb3, 0x80, 0x90, 0x38, 0xa4, 0x2a,
-0xa0, 0x35, 0x60, 0xa4, 0x2a, 0x70, 0x35, 0x5a, 0x18, 0x20, 0x00, 0xf8,
-0x80, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x2c, 0xe8, 0x35, 0xa7, 0xa4, 0x2c,
-0x58, 0x35, 0x92, 0x90, 0x38, 0xa4, 0x2b, 0xe0, 0x35, 0x85, 0xa4, 0x2b,
-0x60, 0x35, 0x72, 0xe4, 0xa1, 0xc5, 0x40, 0x37, 0x18, 0x10, 0x10, 0xe4,
-0xe1, 0xc3, 0xc0, 0x37, 0x12, 0x92, 0x50, 0x99, 0x1c, 0x1c, 0xd8, 0x10,
-0x10, 0x90, 0x80, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x2d, 0xc0, 0x35, 0xbe,
-0xa4, 0x2d, 0x60, 0x35, 0xb2, 0x80, 0x90, 0x38, 0xa4, 0x2a, 0x98, 0x35,
-0x5f, 0xa4, 0x2a, 0x68, 0x35, 0x59, 0x18, 0x20, 0x00, 0xf8, 0x80, 0x90,
-0x70, 0x90, 0x38, 0xa4, 0x2c, 0xd8, 0x35, 0xa6, 0xa4, 0x2c, 0x50, 0x35,
-0x90, 0x90, 0x38, 0xa4, 0x2b, 0xd0, 0x35, 0x84, 0xa4, 0x2b, 0x58, 0x35,
-0x70, 0xe4, 0xa1, 0xc2, 0x40, 0x37, 0x0c, 0x10, 0x10, 0xe4, 0xe1, 0xc0,
-0xc0, 0x37, 0x06, 0xc0, 0x40, 0x80, 0x10, 0x10, 0x81, 0x90, 0x90, 0x90,
-0x48, 0xc9, 0xe1, 0x59, 0x80, 0x85, 0x35, 0x6a, 0xc9, 0xe1, 0x5a, 0x00,
-0x85, 0x35, 0x67, 0x80, 0x35, 0x65, 0x80, 0xd8, 0x47, 0x80, 0x0d, 0xc0,
-0xc0, 0x80, 0x10, 0x10, 0x82, 0x90, 0x58, 0xd5, 0x81, 0x80, 0x80, 0x37,
-0x00, 0x80, 0x36, 0xfe, 0xd5, 0x81, 0x80, 0x80, 0x36, 0xfc, 0x80, 0x36,
-0xfa, 0xc0, 0x80, 0x10, 0x10, 0x82, 0x90, 0x58, 0xd5, 0x81, 0x80, 0x80,
-0x37, 0x01, 0x80, 0x36, 0xff, 0xd5, 0x81, 0x80, 0x80, 0x36, 0xfd, 0x80,
-0x36, 0xfb, 0xc0, 0x80, 0x84, 0x36, 0xf9, 0xa0, 0x56, 0x50, 0xa0, 0x40,
-0x70, 0xa8, 0x1d, 0x40, 0x33, 0x18, 0xa0, 0x12, 0x38, 0xa0, 0x0b, 0x48,
-0x96, 0x00, 0x9a, 0xf0, 0x05, 0xc0, 0x91, 0x70, 0x90, 0xb8, 0x90, 0x70,
-0x90, 0x38, 0xa4, 0x14, 0x50, 0x33, 0x7c, 0xa4, 0x14, 0x60, 0x33, 0x7b,
-0x10, 0x10, 0xa4, 0x14, 0x58, 0x33, 0x7a, 0x90, 0x70, 0x90, 0x38, 0xa4,
-0x14, 0x20, 0x33, 0x61, 0xa4, 0x14, 0x30, 0x33, 0x60, 0x10, 0x10, 0xa4,
-0x14, 0x28, 0x33, 0x5f, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13,
-0xf0, 0x33, 0x46, 0xa4, 0x14, 0x00, 0x33, 0x45, 0x10, 0x10, 0xa4, 0x13,
-0xf8, 0x33, 0x44, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0xc0, 0x33, 0x2b,
-0xa4, 0x13, 0xd0, 0x33, 0x2a, 0x10, 0x10, 0xa4, 0x13, 0xc8, 0x33, 0x29,
-0x91, 0x70, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x14, 0x38, 0x33,
-0x77, 0xa4, 0x14, 0x48, 0x33, 0x79, 0x10, 0x10, 0xa4, 0x14, 0x40, 0x33,
-0x78, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x14, 0x08, 0x33, 0x5c, 0xa4, 0x14,
-0x18, 0x33, 0x5e, 0x10, 0x10, 0xa4, 0x14, 0x10, 0x33, 0x5d, 0x90, 0xb8,
-0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0xd8, 0x33, 0x41, 0xa4, 0x13, 0xe8,
-0x33, 0x43, 0x10, 0x10, 0xa4, 0x13, 0xe0, 0x33, 0x42, 0x90, 0x70, 0x90,
-0x38, 0xa4, 0x13, 0xa8, 0x33, 0x26, 0xa4, 0x13, 0xb8, 0x33, 0x28, 0x10,
-0x10, 0xa4, 0x13, 0xb0, 0x33, 0x27, 0xe4, 0xe1, 0x4f, 0xc0, 0x35, 0x49,
-0x9a, 0xf0, 0x05, 0x00, 0x91, 0x70, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38,
-0xa4, 0x13, 0xa0, 0x33, 0x74, 0xa4, 0x13, 0x98, 0x33, 0x76, 0x10, 0x10,
-0xa4, 0x13, 0x90, 0x33, 0x75, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0x88,
-0x33, 0x59, 0xa4, 0x13, 0x80, 0x33, 0x5b, 0x10, 0x10, 0xa4, 0x13, 0x78,
-0x33, 0x5a, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0x70, 0x33,
-0x3e, 0xa4, 0x13, 0x68, 0x33, 0x40, 0x10, 0x10, 0xa4, 0x13, 0x60, 0x33,
-0x3f, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0x58, 0x33, 0x23, 0xa4, 0x13,
-0x50, 0x33, 0x25, 0x10, 0x10, 0xa4, 0x13, 0x48, 0x33, 0x24, 0x91, 0x10,
-0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x71, 0x80, 0x33, 0x73,
-0x10, 0x10, 0x80, 0x33, 0x72, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x56,
-0x80, 0x33, 0x58, 0x10, 0x10, 0x80, 0x33, 0x57, 0x90, 0x88, 0x90, 0x50,
-0x90, 0x28, 0x80, 0x33, 0x3b, 0x80, 0x33, 0x3d, 0x10, 0x10, 0x80, 0x33,
-0x3c, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x20, 0x80, 0x33, 0x22, 0x10,
-0x10, 0x80, 0x33, 0x21, 0xe4, 0xe1, 0x3d, 0x40, 0x35, 0x09, 0x95, 0x40,
-0x9a, 0x90, 0x05, 0x00, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28,
-0x80, 0x33, 0x6e, 0x80, 0x33, 0x70, 0x10, 0x10, 0x80, 0x33, 0x6f, 0x90,
-0x50, 0x90, 0x28, 0x80, 0x33, 0x53, 0x80, 0x33, 0x55, 0x10, 0x10, 0x80,
-0x33, 0x54, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0x30, 0x33,
-0x38, 0xa4, 0x13, 0x40, 0x33, 0x3a, 0x10, 0x10, 0xa4, 0x13, 0x38, 0x33,
-0x39, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0x00, 0x33, 0x1d, 0xa4, 0x13,
-0x10, 0x33, 0x1f, 0x10, 0x10, 0xa4, 0x13, 0x08, 0x33, 0x1e, 0x91, 0x10,
-0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x6b, 0x80, 0x33, 0x6d,
-0x10, 0x10, 0x80, 0x33, 0x6c, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x50,
-0x80, 0x33, 0x52, 0x10, 0x10, 0x80, 0x33, 0x51, 0x90, 0xb8, 0x90, 0x70,
-0x90, 0x38, 0xa4, 0x13, 0x18, 0x33, 0x35, 0xa4, 0x13, 0x28, 0x33, 0x37,
-0x10, 0x10, 0xa4, 0x13, 0x20, 0x33, 0x36, 0x90, 0x70, 0x90, 0x38, 0xa4,
-0x12, 0xe8, 0x33, 0x1a, 0xa4, 0x12, 0xf8, 0x33, 0x1c, 0x10, 0x10, 0xa4,
-0x12, 0xf0, 0x33, 0x1b, 0xe4, 0xe1, 0x4f, 0x40, 0x35, 0x47, 0x98, 0xb8,
-0x01, 0x68, 0x10, 0x10, 0x10, 0x10, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33,
-0x17, 0x80, 0x33, 0x19, 0x10, 0x10, 0x80, 0x33, 0x18, 0x90, 0x60, 0x90,
-0x30, 0x60, 0xa0, 0x97, 0x00, 0x60, 0xa0, 0x96, 0xc0, 0x90, 0x30, 0x60,
-0xa0, 0x96, 0x80, 0x60, 0xa0, 0x96, 0x40, 0xe4, 0xe1, 0x3c, 0x40, 0x35,
-0x05, 0x96, 0xe8, 0x94, 0x80, 0x9a, 0x30, 0x04, 0x40, 0x91, 0x10, 0x90,
-0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x65, 0x80, 0x33, 0x6a, 0x10,
-0x10, 0x80, 0x33, 0x69, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x4a, 0x80,
-0x33, 0x4f, 0x10, 0x10, 0x80, 0x33, 0x4e, 0x90, 0x88, 0x90, 0x50, 0x90,
-0x28, 0x80, 0x33, 0x2f, 0x80, 0x33, 0x34, 0x10, 0x10, 0x80, 0x33, 0x33,
-0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x11, 0x80, 0x33, 0x16, 0x10, 0x10,
-0x80, 0x33, 0x15, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80,
-0x33, 0x62, 0x80, 0x33, 0x64, 0x10, 0x10, 0x80, 0x33, 0x63, 0x90, 0x50,
-0x90, 0x28, 0x80, 0x33, 0x47, 0x80, 0x33, 0x49, 0x10, 0x10, 0x80, 0x33,
-0x48, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x2c, 0x80, 0x33,
-0x2e, 0x10, 0x10, 0x80, 0x33, 0x2d, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33,
-0x0e, 0x80, 0x33, 0x10, 0x10, 0x10, 0x80, 0x33, 0x0f, 0xe4, 0xe1, 0x4e,
-0xc0, 0x35, 0x45, 0x88, 0x02, 0x28, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50,
-0x90, 0x28, 0x80, 0x33, 0x66, 0x80, 0x33, 0x68, 0x10, 0x10, 0x80, 0x33,
-0x67, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x4b, 0x80, 0x33, 0x4d, 0x10,
-0x10, 0x80, 0x33, 0x4c, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33,
-0x30, 0x80, 0x33, 0x32, 0x10, 0x10, 0x80, 0x33, 0x31, 0x90, 0x50, 0x90,
-0x28, 0x80, 0x33, 0x12, 0x80, 0x33, 0x14, 0x10, 0x10, 0x80, 0x33, 0x13,
-0xe4, 0xe1, 0x3b, 0x40, 0x35, 0x01, 0x93, 0x40, 0x99, 0x90, 0x03, 0x00,
-0x90, 0xc0, 0x90, 0x60, 0x90, 0x28, 0x81, 0x32, 0x9e, 0x10, 0x10, 0x80,
-0x32, 0x9d, 0x90, 0x28, 0x81, 0x32, 0x9a, 0x10, 0x10, 0x80, 0x32, 0x99,
-0x90, 0x60, 0x90, 0x28, 0x81, 0x32, 0x96, 0x10, 0x10, 0x80, 0x32, 0x95,
-0x90, 0x28, 0x81, 0x32, 0x92, 0x10, 0x10, 0x80, 0x32, 0x91, 0x90, 0xc0,
-0x90, 0x60, 0x90, 0x28, 0x81, 0x32, 0x9b, 0x10, 0x10, 0x80, 0x32, 0x9c,
-0x90, 0x28, 0x81, 0x32, 0x97, 0x10, 0x10, 0x80, 0x32, 0x98, 0x90, 0x60,
-0x90, 0x28, 0x81, 0x32, 0x93, 0x10, 0x10, 0x80, 0x32, 0x94, 0x90, 0x28,
-0x81, 0x32, 0x8f, 0x10, 0x10, 0x80, 0x32, 0x90, 0xe4, 0xe1, 0x4e, 0x40,
-0x35, 0x43, 0x88, 0x00, 0x88, 0x10, 0x10, 0x10, 0x10, 0x90, 0x28, 0x81,
-0x32, 0x8d, 0x10, 0x10, 0x80, 0x32, 0x8e, 0xe4, 0xe1, 0x3a, 0x40, 0x34,
-0xfd, 0xa0, 0x0e, 0x80, 0xa0, 0x09, 0x08, 0x94, 0x80, 0x9a, 0x30, 0x04,
-0x40, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x0d,
-0x80, 0x33, 0x0c, 0x10, 0x10, 0x80, 0x33, 0x0b, 0x90, 0x50, 0x90, 0x28,
-0x80, 0x32, 0xf2, 0x80, 0x32, 0xf1, 0x10, 0x10, 0x80, 0x32, 0xf0, 0x90,
-0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xd7, 0x80, 0x32, 0xd6, 0x10,
-0x10, 0x80, 0x32, 0xd5, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xbc, 0x80,
-0x32, 0xbb, 0x10, 0x10, 0x80, 0x32, 0xba, 0x91, 0x10, 0x90, 0x88, 0x90,
-0x50, 0x90, 0x28, 0x80, 0x33, 0x08, 0x80, 0x33, 0x0a, 0x10, 0x10, 0x80,
-0x33, 0x09, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xed, 0x80, 0x32, 0xef,
-0x10, 0x10, 0x80, 0x32, 0xee, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80,
-0x32, 0xd2, 0x80, 0x32, 0xd4, 0x10, 0x10, 0x80, 0x32, 0xd3, 0x90, 0x50,
-0x90, 0x28, 0x80, 0x32, 0xb7, 0x80, 0x32, 0xb9, 0x10, 0x10, 0x80, 0x32,
-0xb8, 0xe4, 0xe1, 0x47, 0x40, 0x35, 0x31, 0x9a, 0x30, 0x04, 0x40, 0x91,
-0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x05, 0x80, 0x33,
-0x07, 0x10, 0x10, 0x80, 0x33, 0x06, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32,
-0xea, 0x80, 0x32, 0xec, 0x10, 0x10, 0x80, 0x32, 0xeb, 0x90, 0x88, 0x90,
-0x50, 0x90, 0x28, 0x80, 0x32, 0xcf, 0x80, 0x32, 0xd1, 0x10, 0x10, 0x80,
-0x32, 0xd0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xb4, 0x80, 0x32, 0xb6,
-0x10, 0x10, 0x80, 0x32, 0xb5, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90,
-0x28, 0x80, 0x33, 0x02, 0x80, 0x33, 0x04, 0x10, 0x10, 0x80, 0x33, 0x03,
-0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xe7, 0x80, 0x32, 0xe9, 0x10, 0x10,
-0x80, 0x32, 0xe8, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xcc,
-0x80, 0x32, 0xce, 0x10, 0x10, 0x80, 0x32, 0xcd, 0x90, 0x50, 0x90, 0x28,
-0x80, 0x32, 0xb1, 0x80, 0x32, 0xb3, 0x10, 0x10, 0x80, 0x32, 0xb2, 0xe4,
-0xe1, 0x36, 0xc0, 0x34, 0xe5, 0x94, 0x80, 0x9a, 0x30, 0x04, 0x40, 0x91,
-0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xff, 0x80, 0x33,
-0x01, 0x10, 0x10, 0x80, 0x33, 0x00, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32,
-0xe4, 0x80, 0x32, 0xe6, 0x10, 0x10, 0x80, 0x32, 0xe5, 0x90, 0x88, 0x90,
-0x50, 0x90, 0x28, 0x80, 0x32, 0xc9, 0x80, 0x32, 0xcb, 0x10, 0x10, 0x80,
-0x32, 0xca, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xae, 0x80, 0x32, 0xb0,
-0x10, 0x10, 0x80, 0x32, 0xaf, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90,
-0x28, 0x80, 0x32, 0xfc, 0x80, 0x32, 0xfe, 0x10, 0x10, 0x80, 0x32, 0xfd,
-0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xe1, 0x80, 0x32, 0xe3, 0x10, 0x10,
-0x80, 0x32, 0xe2, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xc6,
-0x80, 0x32, 0xc8, 0x10, 0x10, 0x80, 0x32, 0xc7, 0x90, 0x50, 0x90, 0x28,
-0x80, 0x32, 0xab, 0x80, 0x32, 0xad, 0x10, 0x10, 0x80, 0x32, 0xac, 0xe4,
-0xe1, 0x46, 0x40, 0x35, 0x2d, 0x88, 0x00, 0xb0, 0x10, 0x10, 0x10, 0x10,
-0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xa8, 0x80, 0x32, 0xaa, 0x10, 0x10,
-0x80, 0x32, 0xa9, 0xe4, 0xe1, 0x36, 0x40, 0x34, 0xe3, 0x96, 0xe8, 0x94,
-0x80, 0x9a, 0x30, 0x04, 0x40, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90,
-0x28, 0x80, 0x32, 0xf6, 0x80, 0x32, 0xfb, 0x10, 0x10, 0x80, 0x32, 0xfa,
-0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xdb, 0x80, 0x32, 0xe0, 0x10, 0x10,
-0x80, 0x32, 0xdf, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xc0,
-0x80, 0x32, 0xc5, 0x10, 0x10, 0x80, 0x32, 0xc4, 0x90, 0x50, 0x90, 0x28,
-0x80, 0x32, 0xa2, 0x80, 0x32, 0xa7, 0x10, 0x10, 0x80, 0x32, 0xa6, 0x91,
-0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xf3, 0x80, 0x32,
-0xf5, 0x10, 0x10, 0x80, 0x32, 0xf4, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32,
-0xd8, 0x80, 0x32, 0xda, 0x10, 0x10, 0x80, 0x32, 0xd9, 0x90, 0x88, 0x90,
-0x50, 0x90, 0x28, 0x80, 0x32, 0xbd, 0x80, 0x32, 0xbf, 0x10, 0x10, 0x80,
-0x32, 0xbe, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0x9f, 0x80, 0x32, 0xa1,
-0x10, 0x10, 0x80, 0x32, 0xa0, 0xe4, 0xe1, 0x45, 0x40, 0x35, 0x29, 0x88,
-0x02, 0x28, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32,
-0xf7, 0x80, 0x32, 0xf9, 0x10, 0x10, 0x80, 0x32, 0xf8, 0x90, 0x50, 0x90,
-0x28, 0x80, 0x32, 0xdc, 0x80, 0x32, 0xde, 0x10, 0x10, 0x80, 0x32, 0xdd,
-0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xc1, 0x80, 0x32, 0xc3,
-0x10, 0x10, 0x80, 0x32, 0xc2, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xa3,
-0x80, 0x32, 0xa5, 0x10, 0x10, 0x80, 0x32, 0xa4, 0xe4, 0xe1, 0x35, 0xc0,
-0x34, 0xe1, 0x90, 0x40, 0xe5, 0x21, 0x44, 0x40, 0x35, 0x25, 0xe5, 0x21,
-0x35, 0x40, 0x34, 0xdf, 0x9e, 0xb4, 0x20, 0x08, 0x93, 0x70, 0x91, 0xd8,
-0xd5, 0x07, 0x80, 0xd0, 0xc4, 0x40, 0x90, 0x48, 0x80, 0x8c, 0x37, 0x58,
-0x84, 0x36, 0xf5, 0xa4, 0x35, 0x38, 0x36, 0xbf, 0x90, 0x28, 0x24, 0x34,
-0x78, 0xa4, 0x32, 0xf8, 0x36, 0x77, 0xd0, 0xc4, 0x40, 0x90, 0x48, 0x80,
-0x8c, 0x37, 0x38, 0x84, 0x36, 0xf3, 0xa4, 0x35, 0x28, 0x36, 0xbd, 0x90,
-0x28, 0x24, 0x34, 0x68, 0xa4, 0x32, 0xe8, 0x36, 0x75, 0xd5, 0x06, 0x80,
-0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xdf, 0xa4, 0x35, 0x08, 0x36,
-0xb9, 0x90, 0x28, 0x24, 0x34, 0x48, 0xa4, 0x32, 0xc8, 0x36, 0x71, 0xd0,
-0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xdb, 0xa4, 0x34, 0xf8, 0x36, 0xb7,
-0x90, 0x28, 0x24, 0x34, 0x38, 0xa4, 0x32, 0xb8, 0x36, 0x6f, 0x91, 0x98,
-0xd5, 0x06, 0x80, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xd3, 0xa4,
-0x34, 0xd8, 0x36, 0xb3, 0x90, 0x28, 0x24, 0x34, 0x18, 0xa4, 0x32, 0x98,
-0x36, 0x6b, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xcf, 0xa4, 0x34,
-0xc8, 0x36, 0xb1, 0x90, 0x28, 0x24, 0x34, 0x08, 0xa4, 0x32, 0x88, 0x36,
-0x69, 0xd5, 0x06, 0x80, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xc7,
-0xa4, 0x34, 0xa8, 0x36, 0xad, 0x90, 0x28, 0x24, 0x33, 0xe8, 0xa4, 0x32,
-0x68, 0x36, 0x65, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xc3, 0xa4,
-0x34, 0x98, 0x36, 0xab, 0x90, 0x28, 0x24, 0x33, 0xd8, 0xa4, 0x32, 0x58,
-0x36, 0x63, 0x93, 0x70, 0x91, 0xd8, 0xd5, 0x07, 0x80, 0xd0, 0xc4, 0x40,
-0x90, 0x48, 0x80, 0x8c, 0x37, 0x78, 0x84, 0x36, 0xf7, 0xa4, 0x35, 0x48,
-0x36, 0xc1, 0x90, 0x28, 0x24, 0x34, 0x88, 0xa4, 0x33, 0x08, 0x36, 0x79,
-0xd0, 0xc4, 0x40, 0x90, 0x48, 0x80, 0x8c, 0x37, 0x48, 0x84, 0x36, 0xf4,
-0xa4, 0x35, 0x30, 0x36, 0xbe, 0x90, 0x28, 0x24, 0x34, 0x70, 0xa4, 0x32,
-0xf0, 0x36, 0x76, 0xd5, 0x06, 0x80, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80,
-0x36, 0xe3, 0xa4, 0x35, 0x18, 0x36, 0xbb, 0x90, 0x28, 0x24, 0x34, 0x58,
-0xa4, 0x32, 0xd8, 0x36, 0x73, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36,
-0xdd, 0xa4, 0x35, 0x00, 0x36, 0xb8, 0x90, 0x28, 0x24, 0x34, 0x40, 0xa4,
-0x32, 0xc0, 0x36, 0x70, 0x91, 0x98, 0xd5, 0x06, 0x80, 0xd0, 0xc3, 0x40,
-0x90, 0x28, 0x80, 0x36, 0xd7, 0xa4, 0x34, 0xe8, 0x36, 0xb5, 0x90, 0x28,
-0x24, 0x34, 0x28, 0xa4, 0x32, 0xa8, 0x36, 0x6d, 0xd0, 0xc3, 0x40, 0x90,
-0x28, 0x80, 0x36, 0xd1, 0xa4, 0x34, 0xd0, 0x36, 0xb2, 0x90, 0x28, 0x24,
-0x34, 0x10, 0xa4, 0x32, 0x90, 0x36, 0x6a, 0xd5, 0x06, 0x80, 0xd0, 0xc3,
-0x40, 0x90, 0x28, 0x80, 0x36, 0xcb, 0xa4, 0x34, 0xb8, 0x36, 0xaf, 0x90,
-0x28, 0x24, 0x33, 0xf8, 0xa4, 0x32, 0x78, 0x36, 0x67, 0xd0, 0xc3, 0x40,
-0x90, 0x28, 0x80, 0x36, 0xc5, 0xa4, 0x34, 0xa0, 0x36, 0xac, 0x90, 0x28,
-0x24, 0x33, 0xe0, 0xa4, 0x32, 0x60, 0x36, 0x64, 0x99, 0x08, 0x01, 0xf0,
-0x81, 0x90, 0x78, 0xd4, 0xc2, 0x00, 0xa4, 0x1f, 0xb0, 0x33, 0xee, 0xa4,
-0x1f, 0x30, 0x33, 0xde, 0xd4, 0xc2, 0x00, 0xa4, 0x1f, 0x40, 0x33, 0xf0,
-0xa4, 0x1e, 0xc0, 0x33, 0xe0, 0x81, 0x90, 0x78, 0xd4, 0xc2, 0x00, 0xa4,
-0x1f, 0x60, 0x33, 0xf4, 0xa4, 0x1e, 0xe0, 0x33, 0xe4, 0xd4, 0xc2, 0x00,
-0xa4, 0x1f, 0x50, 0x33, 0xf2, 0xa4, 0x1e, 0xd0, 0x33, 0xe2, 0xa8, 0x0b,
-0x18, 0x13, 0xa8, 0x96, 0x80, 0x93, 0x40, 0x99, 0x90, 0x03, 0x00, 0x90,
-0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0xb8, 0x32, 0x58, 0x24, 0x12,
-0xb0, 0x90, 0x38, 0xa4, 0x11, 0xe0, 0x32, 0x3d, 0x24, 0x11, 0xd8, 0x90,
-0x60, 0x90, 0x38, 0xa4, 0x11, 0x08, 0x32, 0x22, 0x24, 0x11, 0x00, 0x90,
-0x38, 0xa4, 0x10, 0x30, 0x32, 0x07, 0x24, 0x10, 0x28, 0x90, 0xc0, 0x90,
-0x60, 0x90, 0x38, 0xa4, 0x12, 0xa8, 0x32, 0x53, 0x24, 0x12, 0xa0, 0x90,
-0x38, 0xa4, 0x11, 0xd0, 0x32, 0x38, 0x24, 0x11, 0xc8, 0x90, 0x60, 0x90,
-0x38, 0xa4, 0x10, 0xf8, 0x32, 0x1d, 0x24, 0x10, 0xf0, 0x90, 0x38, 0xa4,
-0x10, 0x20, 0x32, 0x02, 0x24, 0x10, 0x18, 0xe4, 0xe1, 0x91, 0x40, 0x36,
-0x47, 0x99, 0x90, 0x03, 0x00, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4,
-0x12, 0x90, 0x32, 0x50, 0x24, 0x12, 0x88, 0x90, 0x38, 0xa4, 0x11, 0xb8,
-0x32, 0x35, 0x24, 0x11, 0xb0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0xe0,
-0x32, 0x1a, 0x24, 0x10, 0xd8, 0x90, 0x38, 0xa4, 0x10, 0x08, 0x31, 0xff,
-0x24, 0x10, 0x00, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x78,
-0x32, 0x4d, 0x24, 0x12, 0x70, 0x90, 0x38, 0xa4, 0x11, 0xa0, 0x32, 0x32,
-0x24, 0x11, 0x98, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0xc8, 0x32, 0x17,
-0x24, 0x10, 0xc0, 0x90, 0x38, 0xa4, 0x0f, 0xf0, 0x31, 0xfc, 0x24, 0x0f,
-0xe8, 0xe4, 0xe1, 0x8f, 0xc0, 0x36, 0x41, 0x93, 0x78, 0x99, 0x90, 0x03,
-0x00, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x60, 0x32, 0x4a,
-0x24, 0x12, 0x58, 0x90, 0x38, 0xa4, 0x11, 0x88, 0x32, 0x2f, 0x24, 0x11,
-0x80, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0xb0, 0x32, 0x14, 0x24, 0x10,
-0xa8, 0x90, 0x38, 0xa4, 0x0f, 0xd8, 0x31, 0xf9, 0x24, 0x0f, 0xd0, 0x90,
-0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x48, 0x32, 0x47, 0x24, 0x12,
-0x40, 0x90, 0x38, 0xa4, 0x11, 0x70, 0x32, 0x2c, 0x24, 0x11, 0x68, 0x90,
-0x60, 0x90, 0x38, 0xa4, 0x10, 0x98, 0x32, 0x11, 0x24, 0x10, 0x90, 0x90,
-0x38, 0xa4, 0x0f, 0xc0, 0x31, 0xf6, 0x24, 0x0f, 0xb8, 0xec, 0xa0, 0xff,
-0x00, 0x02, 0x00, 0x33, 0xfe, 0xa4, 0x31, 0xc8, 0x36, 0x3b, 0x88, 0x00,
-0x88, 0x10, 0x10, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x0f, 0xa8, 0x31, 0xf3,
-0x24, 0x0f, 0xa0, 0xe9, 0x60, 0xfe, 0x40, 0x02, 0x00, 0x33, 0xfa, 0xe3,
-0x61, 0x8c, 0xc0, 0x36, 0x35, 0x95, 0x08, 0x93, 0x40, 0x99, 0x90, 0x03,
-0x00, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x30, 0x32, 0x41,
-0x24, 0x12, 0x28, 0x90, 0x38, 0xa4, 0x11, 0x58, 0x32, 0x26, 0x24, 0x11,
-0x50, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0x80, 0x32, 0x0b, 0x24, 0x10,
-0x78, 0x90, 0x38, 0xa4, 0x0f, 0x90, 0x31, 0xed, 0x24, 0x0f, 0x88, 0x90,
-0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x00, 0x32, 0x3e, 0x24, 0x11,
-0xf8, 0x90, 0x38, 0xa4, 0x11, 0x28, 0x32, 0x23, 0x24, 0x11, 0x20, 0x90,
-0x60, 0x90, 0x38, 0xa4, 0x10, 0x50, 0x32, 0x08, 0x24, 0x10, 0x48, 0x90,
-0x38, 0xa4, 0x0f, 0x60, 0x31, 0xea, 0x24, 0x0f, 0x58, 0xe4, 0xe1, 0x91,
-0x80, 0x36, 0x49, 0x88, 0x01, 0x88, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38,
-0xa4, 0x12, 0x20, 0x32, 0x42, 0x24, 0x12, 0x18, 0x90, 0x38, 0xa4, 0x11,
-0x48, 0x32, 0x27, 0x24, 0x11, 0x40, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10,
-0x70, 0x32, 0x0c, 0x24, 0x10, 0x68, 0x90, 0x38, 0xa4, 0x0f, 0x80, 0x31,
-0xee, 0x24, 0x0f, 0x78, 0xe4, 0xe1, 0x90, 0x00, 0x36, 0x43, 0x92, 0xd0,
-0x99, 0x50, 0x02, 0x80, 0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31,
-0xe9, 0x24, 0x0f, 0x40, 0x90, 0x28, 0x80, 0x31, 0xe5, 0x24, 0x0f, 0x20,
-0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0xe1, 0x24, 0x0f, 0x00, 0x90, 0x28,
-0x80, 0x31, 0xdd, 0x24, 0x0e, 0xe0, 0x90, 0xa0, 0x90, 0x50, 0x90, 0x28,
-0x80, 0x31, 0xe6, 0x24, 0x0f, 0x38, 0x90, 0x28, 0x80, 0x31, 0xe2, 0x24,
-0x0f, 0x18, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0xde, 0x24, 0x0e, 0xf8,
-0x90, 0x28, 0x80, 0x31, 0xda, 0x24, 0x0e, 0xd8, 0xec, 0xe1, 0x8e, 0xa1,
-0x00, 0x00, 0x36, 0x3d, 0x88, 0x00, 0x78, 0x10, 0x10, 0x10, 0x10, 0x90,
-0x28, 0x80, 0x31, 0xd8, 0x24, 0x0e, 0xc8, 0xec, 0xe1, 0x8d, 0x20, 0xfe,
-0x00, 0x36, 0x37, 0xe5, 0xa1, 0x34, 0xc0, 0x34, 0xd1, 0xa0, 0x2a, 0x10,
-0xa8, 0x16, 0x60, 0x29, 0xd8, 0xa0, 0x0c, 0x48, 0xa0, 0x0a, 0xc8, 0x95,
-0x60, 0x92, 0xb0, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80,
-0x31, 0xa1, 0x80, 0x31, 0xa0, 0x10, 0x10, 0x80, 0x31, 0x9f, 0x90, 0x70,
-0x90, 0x38, 0xa4, 0x08, 0x98, 0x31, 0xb3, 0xa4, 0x08, 0x90, 0x31, 0xb2,
-0x10, 0x10, 0xa4, 0x08, 0x88, 0x31, 0xb1, 0x90, 0xb8, 0x90, 0x70, 0x90,
-0x38, 0xa4, 0x09, 0xb8, 0x31, 0xd7, 0xa4, 0x09, 0xb0, 0x31, 0xd6, 0x10,
-0x10, 0xa4, 0x09, 0xa8, 0x31, 0xd5, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09,
-0x28, 0x31, 0xc5, 0xa4, 0x09, 0x20, 0x31, 0xc4, 0x10, 0x10, 0xa4, 0x09,
-0x18, 0x31, 0xc3, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80,
-0x31, 0x9c, 0x80, 0x31, 0x9e, 0x10, 0x10, 0x80, 0x31, 0x9d, 0x90, 0x70,
-0x90, 0x38, 0xa4, 0x08, 0x70, 0x31, 0xae, 0xa4, 0x08, 0x80, 0x31, 0xb0,
-0x10, 0x10, 0xa4, 0x08, 0x78, 0x31, 0xaf, 0x90, 0xb8, 0x90, 0x70, 0x90,
-0x38, 0xa4, 0x09, 0x90, 0x31, 0xd2, 0xa4, 0x09, 0xa0, 0x31, 0xd4, 0x10,
-0x10, 0xa4, 0x09, 0x98, 0x31, 0xd3, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09,
-0x00, 0x31, 0xc0, 0xa4, 0x09, 0x10, 0x31, 0xc2, 0x10, 0x10, 0xa4, 0x09,
-0x08, 0x31, 0xc1, 0x92, 0xb0, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90,
-0x28, 0x80, 0x31, 0x99, 0x80, 0x31, 0x9b, 0x10, 0x10, 0x80, 0x31, 0x9a,
-0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0x58, 0x31, 0xab, 0xa4, 0x08, 0x68,
-0x31, 0xad, 0x10, 0x10, 0xa4, 0x08, 0x60, 0x31, 0xac, 0x90, 0xb8, 0x90,
-0x70, 0x90, 0x38, 0xa4, 0x09, 0x78, 0x31, 0xcf, 0xa4, 0x09, 0x88, 0x31,
-0xd1, 0x10, 0x10, 0xa4, 0x09, 0x80, 0x31, 0xd0, 0x90, 0x70, 0x90, 0x38,
-0xa4, 0x08, 0xe8, 0x31, 0xbd, 0xa4, 0x08, 0xf8, 0x31, 0xbf, 0x10, 0x10,
-0xa4, 0x08, 0xf0, 0x31, 0xbe, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90,
-0x28, 0x80, 0x31, 0x96, 0x80, 0x31, 0x98, 0x10, 0x10, 0x80, 0x31, 0x97,
-0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0x40, 0x31, 0xa8, 0xa4, 0x08, 0x50,
-0x31, 0xaa, 0x10, 0x10, 0xa4, 0x08, 0x48, 0x31, 0xa9, 0x90, 0xb8, 0x90,
-0x70, 0x90, 0x38, 0xa4, 0x09, 0x60, 0x31, 0xcc, 0xa4, 0x09, 0x70, 0x31,
-0xce, 0x10, 0x10, 0xa4, 0x09, 0x68, 0x31, 0xcd, 0x90, 0x70, 0x90, 0x38,
-0xa4, 0x08, 0xd0, 0x31, 0xba, 0xa4, 0x08, 0xe0, 0x31, 0xbc, 0x10, 0x10,
-0xa4, 0x08, 0xd8, 0x31, 0xbb, 0x10, 0x10, 0x90, 0xa8, 0x10, 0x10, 0x10,
-0x10, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x8d, 0x80, 0x31, 0x8f, 0x10,
-0x10, 0x80, 0x31, 0x8e, 0x90, 0x60, 0x90, 0x30, 0x60, 0xa0, 0x2a, 0xc0,
-0x60, 0xa0, 0x2a, 0x80, 0x90, 0x30, 0x60, 0xa0, 0x2a, 0x40, 0x60, 0xa0,
-0x2a, 0x00, 0x97, 0xf0, 0x95, 0x60, 0x92, 0xb0, 0x91, 0x40, 0x90, 0x88,
-0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x93, 0x80, 0x31, 0x95, 0x10, 0x10,
-0x80, 0x31, 0x94, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0x28, 0x31, 0xa5,
-0xa4, 0x08, 0x38, 0x31, 0xa7, 0x10, 0x10, 0xa4, 0x08, 0x30, 0x31, 0xa6,
-0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09, 0x48, 0x31, 0xc9, 0xa4,
-0x09, 0x58, 0x31, 0xcb, 0x10, 0x10, 0xa4, 0x09, 0x50, 0x31, 0xca, 0x90,
-0x70, 0x90, 0x38, 0xa4, 0x08, 0xb8, 0x31, 0xb7, 0xa4, 0x08, 0xc8, 0x31,
-0xb9, 0x10, 0x10, 0xa4, 0x08, 0xc0, 0x31, 0xb8, 0x91, 0x40, 0x90, 0x88,
-0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x90, 0x80, 0x31, 0x92, 0x10, 0x10,
-0x80, 0x31, 0x91, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0x10, 0x31, 0xa2,
-0xa4, 0x08, 0x20, 0x31, 0xa4, 0x10, 0x10, 0xa4, 0x08, 0x18, 0x31, 0xa3,
-0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09, 0x30, 0x31, 0xc6, 0xa4,
-0x09, 0x40, 0x31, 0xc8, 0x10, 0x10, 0xa4, 0x09, 0x38, 0x31, 0xc7, 0x90,
-0x70, 0x90, 0x38, 0xa4, 0x08, 0xa0, 0x31, 0xb4, 0xa4, 0x08, 0xb0, 0x31,
-0xb6, 0x10, 0x10, 0xa4, 0x08, 0xa8, 0x31, 0xb5, 0x10, 0x10, 0x91, 0x40,
-0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0xcb, 0x80, 0x30, 0xca,
-0x90, 0x28, 0x80, 0x30, 0xc9, 0x80, 0x30, 0xc8, 0x90, 0x50, 0x90, 0x28,
-0x80, 0x30, 0xc4, 0x80, 0x30, 0xc7, 0x90, 0x28, 0x80, 0x30, 0xc6, 0x80,
-0x30, 0xc5, 0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0xbc, 0x80,
-0x30, 0xc3, 0x90, 0x28, 0x80, 0x30, 0xc2, 0x80, 0x30, 0xc1, 0x90, 0x50,
-0x90, 0x28, 0x80, 0x30, 0xbd, 0x80, 0x30, 0xc0, 0x90, 0x28, 0x80, 0x30,
-0xbf, 0x80, 0x30, 0xbe, 0x91, 0x88, 0x80, 0x90, 0xc0, 0x90, 0x60, 0x90,
-0x28, 0x81, 0x31, 0x3b, 0x10, 0x10, 0x80, 0x31, 0x3a, 0x90, 0x28, 0x81,
-0x31, 0x3d, 0x10, 0x10, 0x80, 0x31, 0x3c, 0x90, 0x60, 0x90, 0x28, 0x81,
-0x31, 0x41, 0x10, 0x10, 0x80, 0x31, 0x40, 0x90, 0x28, 0x81, 0x31, 0x3f,
-0x10, 0x10, 0x80, 0x31, 0x3e, 0x80, 0x10, 0x10, 0x10, 0x10, 0x90, 0x28,
-0x81, 0x31, 0x38, 0x10, 0x10, 0x80, 0x31, 0x39, 0xa0, 0x0b, 0x90, 0xa0,
-0x0a, 0xc8, 0x95, 0x60, 0x92, 0xb0, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50,
-0x90, 0x28, 0x80, 0x31, 0x56, 0x80, 0x31, 0x55, 0x10, 0x10, 0x80, 0x31,
-0x54, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0xe8, 0x31, 0x68, 0xa4, 0x06,
-0xe0, 0x31, 0x67, 0x10, 0x10, 0xa4, 0x06, 0xd8, 0x31, 0x66, 0x90, 0xb8,
-0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0x08, 0x31, 0x8c, 0xa4, 0x08, 0x00,
-0x31, 0x8b, 0x10, 0x10, 0xa4, 0x07, 0xf8, 0x31, 0x8a, 0x90, 0x70, 0x90,
-0x38, 0xa4, 0x07, 0x78, 0x31, 0x7a, 0xa4, 0x07, 0x70, 0x31, 0x79, 0x10,
-0x10, 0xa4, 0x07, 0x68, 0x31, 0x78, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50,
-0x90, 0x28, 0x80, 0x31, 0x51, 0x80, 0x31, 0x53, 0x10, 0x10, 0x80, 0x31,
-0x52, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0xc0, 0x31, 0x63, 0xa4, 0x06,
-0xd0, 0x31, 0x65, 0x10, 0x10, 0xa4, 0x06, 0xc8, 0x31, 0x64, 0x90, 0xb8,
-0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0xe0, 0x31, 0x87, 0xa4, 0x07, 0xf0,
-0x31, 0x89, 0x10, 0x10, 0xa4, 0x07, 0xe8, 0x31, 0x88, 0x90, 0x70, 0x90,
-0x38, 0xa4, 0x07, 0x50, 0x31, 0x75, 0xa4, 0x07, 0x60, 0x31, 0x77, 0x10,
-0x10, 0xa4, 0x07, 0x58, 0x31, 0x76, 0x92, 0xb0, 0x91, 0x40, 0x90, 0x88,
-0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x4e, 0x80, 0x31, 0x50, 0x10, 0x10,
-0x80, 0x31, 0x4f, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0xa8, 0x31, 0x60,
-0xa4, 0x06, 0xb8, 0x31, 0x62, 0x10, 0x10, 0xa4, 0x06, 0xb0, 0x31, 0x61,
-0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0xc8, 0x31, 0x84, 0xa4,
-0x07, 0xd8, 0x31, 0x86, 0x10, 0x10, 0xa4, 0x07, 0xd0, 0x31, 0x85, 0x90,
-0x70, 0x90, 0x38, 0xa4, 0x07, 0x38, 0x31, 0x72, 0xa4, 0x07, 0x48, 0x31,
-0x74, 0x10, 0x10, 0xa4, 0x07, 0x40, 0x31, 0x73, 0x91, 0x40, 0x90, 0x88,
-0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x4b, 0x80, 0x31, 0x4d, 0x10, 0x10,
-0x80, 0x31, 0x4c, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0x90, 0x31, 0x5d,
-0xa4, 0x06, 0xa0, 0x31, 0x5f, 0x10, 0x10, 0xa4, 0x06, 0x98, 0x31, 0x5e,
-0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0xb0, 0x31, 0x81, 0xa4,
-0x07, 0xc0, 0x31, 0x83, 0x10, 0x10, 0xa4, 0x07, 0xb8, 0x31, 0x82, 0x90,
-0x70, 0x90, 0x38, 0xa4, 0x07, 0x20, 0x31, 0x6f, 0xa4, 0x07, 0x30, 0x31,
-0x71, 0x10, 0x10, 0xa4, 0x07, 0x28, 0x31, 0x70, 0x10, 0x10, 0x80, 0x10,
-0x10, 0x10, 0x10, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x42, 0x80, 0x31,
-0x44, 0x10, 0x10, 0x80, 0x31, 0x43, 0x80, 0x95, 0x60, 0x92, 0xb0, 0x91,
-0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x48, 0x80, 0x31,
-0x4a, 0x10, 0x10, 0x80, 0x31, 0x49, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06,
-0x78, 0x31, 0x5a, 0xa4, 0x06, 0x88, 0x31, 0x5c, 0x10, 0x10, 0xa4, 0x06,
-0x80, 0x31, 0x5b, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0x98,
-0x31, 0x7e, 0xa4, 0x07, 0xa8, 0x31, 0x80, 0x10, 0x10, 0xa4, 0x07, 0xa0,
-0x31, 0x7f, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0x08, 0x31, 0x6c, 0xa4,
-0x07, 0x18, 0x31, 0x6e, 0x10, 0x10, 0xa4, 0x07, 0x10, 0x31, 0x6d, 0x91,
-0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x45, 0x80, 0x31,
-0x47, 0x10, 0x10, 0x80, 0x31, 0x46, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06,
-0x60, 0x31, 0x57, 0xa4, 0x06, 0x70, 0x31, 0x59, 0x10, 0x10, 0xa4, 0x06,
-0x68, 0x31, 0x58, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0x80,
-0x31, 0x7b, 0xa4, 0x07, 0x90, 0x31, 0x7d, 0x10, 0x10, 0xa4, 0x07, 0x88,
-0x31, 0x7c, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0xf0, 0x31, 0x69, 0xa4,
-0x07, 0x00, 0x31, 0x6b, 0x10, 0x10, 0xa4, 0x06, 0xf8, 0x31, 0x6a, 0x10,
-0x10, 0x91, 0x40, 0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0xbb,
-0x80, 0x30, 0xba, 0x90, 0x28, 0x80, 0x30, 0xb9, 0x80, 0x30, 0xb8, 0x90,
-0x50, 0x90, 0x28, 0x80, 0x30, 0xb4, 0x80, 0x30, 0xb7, 0x90, 0x28, 0x80,
-0x30, 0xb6, 0x80, 0x30, 0xb5, 0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 0x80,
-0x30, 0xac, 0x80, 0x30, 0xb3, 0x90, 0x28, 0x80, 0x30, 0xb2, 0x80, 0x30,
-0xb1, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0xad, 0x80, 0x30, 0xb0, 0x90,
-0x28, 0x80, 0x30, 0xaf, 0x80, 0x30, 0xae, 0xc3, 0xc0, 0x30, 0x42, 0x9c,
-0xe8, 0x07, 0x60, 0x91, 0x90, 0x90, 0xf0, 0x10, 0x10, 0x80, 0x88, 0x00,
-0x80, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0xbc, 0x80, 0x33, 0xbd, 0x81,
-0x33, 0xb3, 0xd0, 0x41, 0x80, 0x24, 0x1e, 0xb0, 0x24, 0x1e, 0xb8, 0x10,
-0x10, 0x80, 0x90, 0x58, 0x80, 0x90, 0x28, 0x24, 0x1d, 0xb0, 0x24, 0x1d,
-0xb8, 0x81, 0x24, 0x1d, 0x70, 0x92, 0x68, 0x91, 0x00, 0x80, 0x90, 0x90,
-0x90, 0x30, 0x80, 0x24, 0x1e, 0x20, 0x90, 0x38, 0xa4, 0x1e, 0x18, 0x33,
-0xca, 0x80, 0x33, 0xc9, 0x80, 0x90, 0x28, 0x80, 0x33, 0xd3, 0xa4, 0x1e,
-0x00, 0x33, 0xd2, 0x80, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x28, 0x80, 0x33,
-0xcd, 0xa4, 0x1e, 0x10, 0x33, 0xcc, 0x90, 0x28, 0x80, 0x33, 0xc8, 0xa4,
-0x1e, 0x08, 0x33, 0xc7, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0xd1, 0x80,
-0x33, 0xd0, 0x90, 0x28, 0x24, 0x1e, 0xa8, 0x24, 0x1e, 0xa0, 0x90, 0x58,
-0x80, 0x10, 0x10, 0x80, 0x10, 0x10, 0x80, 0x33, 0xbf, 0x80, 0x90, 0x40,
-0x10, 0x10, 0x80, 0x24, 0x1d, 0x80, 0x80, 0x10, 0x10, 0x80, 0x33, 0xbe,
-0x91, 0x58, 0x91, 0x00, 0x90, 0x80, 0x81, 0x90, 0x50, 0x90, 0x28, 0x80,
-0x33, 0xba, 0x80, 0x33, 0xbb, 0x81, 0x33, 0xb2, 0x81, 0x90, 0x50, 0x90,
-0x28, 0x80, 0x33, 0xb8, 0x80, 0x33, 0xb9, 0x81, 0x33, 0xb1, 0x83, 0x90,
-0x28, 0x24, 0x1d, 0xa0, 0x24, 0x1d, 0xa8, 0x90, 0xe8, 0x81, 0x90, 0x88,
-0x90, 0x38, 0x10, 0x10, 0x80, 0x33, 0xcb, 0x90, 0x28, 0x80, 0x33, 0xc6,
-0x80, 0x33, 0xc5, 0x80, 0x90, 0x28, 0x80, 0x33, 0xcf, 0x80, 0x33, 0xce,
-0x82, 0x10, 0x10, 0x80, 0x24, 0x1d, 0x78, 0x97, 0x10, 0x9e, 0x10, 0x06,
-0x98, 0x93, 0x00, 0x91, 0x80, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4,
-0x03, 0x80, 0x30, 0x71, 0x24, 0x03, 0x78, 0x90, 0x38, 0xa4, 0x04, 0x10,
-0x30, 0x83, 0x24, 0x04, 0x08, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x05, 0x30,
-0x30, 0xa7, 0x24, 0x05, 0x28, 0x90, 0x38, 0xa4, 0x04, 0xa0, 0x30, 0x95,
-0x24, 0x04, 0x98, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x03, 0x70,
-0x30, 0x6c, 0x24, 0x03, 0x68, 0x90, 0x38, 0xa4, 0x04, 0x00, 0x30, 0x7e,
-0x24, 0x03, 0xf8, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x05, 0x20, 0x30, 0xa2,
-0x24, 0x05, 0x18, 0x90, 0x38, 0xa4, 0x04, 0x90, 0x30, 0x90, 0x24, 0x04,
-0x88, 0x91, 0x80, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x03, 0x58,
-0x30, 0x69, 0x24, 0x03, 0x50, 0x90, 0x38, 0xa4, 0x03, 0xe8, 0x30, 0x7b,
-0x24, 0x03, 0xe0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x05, 0x08, 0x30, 0x9f,
-0x24, 0x05, 0x00, 0x90, 0x38, 0xa4, 0x04, 0x78, 0x30, 0x8d, 0x24, 0x04,
-0x70, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x03, 0x40, 0x30, 0x66,
-0x24, 0x03, 0x38, 0x90, 0x38, 0xa4, 0x03, 0xd0, 0x30, 0x78, 0x24, 0x03,
-0xc8, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x04, 0xf0, 0x30, 0x9c, 0x24, 0x04,
-0xe8, 0x90, 0x38, 0xa4, 0x04, 0x60, 0x30, 0x8a, 0x24, 0x04, 0x58, 0x10,
-0x10, 0x80, 0x10, 0x10, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x02, 0xf8, 0x30,
-0x5d, 0x24, 0x02, 0xf0, 0xd7, 0x42, 0x00, 0xa4, 0x31, 0x78, 0x36, 0x31,
-0xa4, 0x31, 0x58, 0x36, 0x2d, 0x9c, 0xe0, 0x06, 0x90, 0x93, 0x00, 0x91,
-0x80, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x03, 0x28, 0x30, 0x63,
-0x24, 0x03, 0x20, 0x90, 0x38, 0xa4, 0x03, 0xb8, 0x30, 0x75, 0x24, 0x03,
-0xb0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x04, 0xd8, 0x30, 0x99, 0x24, 0x04,
-0xd0, 0x90, 0x38, 0xa4, 0x04, 0x48, 0x30, 0x87, 0x24, 0x04, 0x40, 0x90,
-0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x03, 0x10, 0x30, 0x60, 0x24, 0x03,
-0x08, 0x90, 0x38, 0xa4, 0x03, 0xa0, 0x30, 0x72, 0x24, 0x03, 0x98, 0x90,
-0x60, 0x90, 0x38, 0xa4, 0x04, 0xc0, 0x30, 0x96, 0x24, 0x04, 0xb8, 0x90,
-0x38, 0xa4, 0x04, 0x30, 0x30, 0x84, 0x24, 0x04, 0x28, 0x10, 0x10, 0x90,
-0xe0, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x02, 0x88, 0x30, 0x52, 0xa4, 0x02,
-0x78, 0x30, 0x50, 0x90, 0x38, 0xa4, 0x02, 0x70, 0x30, 0x4b, 0xa4, 0x02,
-0x60, 0x30, 0x4d, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x02, 0x50, 0x30, 0x43,
-0xa4, 0x02, 0x40, 0x30, 0x49, 0x90, 0x38, 0xa4, 0x02, 0x38, 0x30, 0x44,
-0xa4, 0x02, 0x28, 0x30, 0x46, 0x91, 0x48, 0x80, 0x90, 0xa0, 0x90, 0x50,
-0x90, 0x28, 0x80, 0x30, 0x56, 0x24, 0x02, 0xa8, 0x90, 0x28, 0x80, 0x30,
-0x58, 0x24, 0x02, 0xb8, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0x5c, 0x24,
-0x02, 0xd8, 0x90, 0x28, 0x80, 0x30, 0x5a, 0x24, 0x02, 0xc8, 0x80, 0x10,
-0x10, 0x10, 0x10, 0x90, 0x28, 0x80, 0x30, 0x53, 0x24, 0x02, 0xa0, 0xd7,
-0x42, 0x00, 0xa4, 0x31, 0x80, 0x36, 0x32, 0xa4, 0x31, 0x60, 0x36, 0x2e,
-0xa0, 0x14, 0x90, 0xa0, 0x10, 0xb8, 0xa0, 0x0c, 0x88, 0x9e, 0x88, 0x09,
-0xd0, 0x94, 0xf0, 0x90, 0xb0, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 0xc9,
-0xe1, 0x2c, 0x40, 0x85, 0x34, 0xcd, 0xcb, 0x61, 0x25, 0x00, 0x85, 0x34,
-0xa3, 0x9a, 0x00, 0x03, 0xf8, 0x91, 0x98, 0x80, 0x91, 0x10, 0x90, 0xa0,
-0x90, 0x68, 0x90, 0x20, 0x38, 0x96, 0xc9, 0xe2, 0x25, 0x00, 0x85, 0x34,
-0xcb, 0xa4, 0x44, 0x90, 0x38, 0x93, 0x90, 0x38, 0xa4, 0x44, 0x58, 0x38,
-0x8c, 0xa4, 0x44, 0x48, 0x38, 0x8a, 0x90, 0x48, 0x10, 0x10, 0xa4, 0x44,
-0x10, 0x38, 0x83, 0x10, 0x10, 0x80, 0x38, 0x7f, 0x81, 0x10, 0x10, 0x80,
-0xa4, 0x43, 0xe0, 0x38, 0x7d, 0x91, 0xb0, 0x91, 0x60, 0x90, 0xe0, 0x90,
-0x70, 0x90, 0x38, 0xa4, 0x44, 0x80, 0x38, 0x91, 0xa4, 0x44, 0x70, 0x38,
-0x8f, 0x90, 0x38, 0xa4, 0x44, 0x38, 0x38, 0x88, 0xa4, 0x44, 0x28, 0x38,
-0x86, 0x90, 0x48, 0x10, 0x10, 0xa4, 0x44, 0x00, 0x38, 0x81, 0x10, 0x10,
-0x80, 0x38, 0x7e, 0x90, 0x28, 0x80, 0x38, 0x77, 0x80, 0x38, 0x76, 0x81,
-0x10, 0x10, 0x80, 0xa4, 0x43, 0xd0, 0x38, 0x7b, 0xcb, 0x61, 0x24, 0xc0,
-0x85, 0x34, 0xa2, 0x90, 0xd8, 0x88, 0x00, 0x90, 0x84, 0x90, 0x38, 0xc1,
-0xc0, 0x85, 0x38, 0x9a, 0xc9, 0xe1, 0x2c, 0x00, 0x85, 0x34, 0xc9, 0xcb,
-0x61, 0x24, 0x80, 0x85, 0x34, 0xa1, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10,
-0xc9, 0xe1, 0x2b, 0xc0, 0x85, 0x34, 0xc7, 0xcb, 0x61, 0x24, 0x40, 0x85,
-0x34, 0xa0, 0x91, 0xf8, 0x90, 0xb0, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10,
-0xc9, 0xe1, 0x2b, 0x40, 0x85, 0x34, 0xc3, 0xcb, 0x61, 0x23, 0xc0, 0x85,
-0x34, 0x9e, 0x88, 0x01, 0x00, 0x90, 0xa0, 0x81, 0x90, 0x70, 0x80, 0x90,
-0x20, 0x38, 0x8d, 0xc9, 0xe1, 0x2b, 0x00, 0x85, 0x34, 0xc1, 0x81, 0x38,
-0x84, 0x81, 0x10, 0x10, 0x80, 0xa4, 0x43, 0xc0, 0x38, 0x79, 0xcb, 0x61,
-0x23, 0x80, 0x85, 0x34, 0x9d, 0x90, 0xb0, 0x88, 0x00, 0x68, 0x84, 0x10,
-0x10, 0xc9, 0xe1, 0x2a, 0xc0, 0x85, 0x34, 0xbf, 0xcb, 0x61, 0x23, 0x40,
-0x85, 0x34, 0x9c, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 0xc9, 0xe1, 0x2a,
-0x80, 0x85, 0x34, 0xbd, 0xcb, 0x61, 0x23, 0x00, 0x85, 0x34, 0x9b, 0x92,
-0x38, 0x81, 0x91, 0x68, 0x91, 0x18, 0x90, 0x80, 0x90, 0x40, 0x80, 0xa4,
-0x45, 0x48, 0x38, 0xaa, 0x80, 0xa4, 0x45, 0x40, 0x38, 0xa7, 0x90, 0x28,
-0x81, 0x38, 0xa6, 0x90, 0x38, 0xa4, 0x45, 0x20, 0x38, 0xa5, 0xa4, 0x45,
-0x10, 0x38, 0xa3, 0x90, 0x28, 0x80, 0x38, 0xa1, 0x80, 0x38, 0xa0, 0x80,
-0x90, 0x40, 0x10, 0x10, 0x80, 0x24, 0x44, 0xf8, 0x10, 0x10, 0x90, 0x38,
-0xa4, 0x44, 0xe8, 0x38, 0x9e, 0xa4, 0x44, 0xd8, 0x38, 0x9c, 0x90, 0x50,
-0x80, 0xc9, 0xa2, 0x26, 0x00, 0x85, 0x38, 0x99, 0x80, 0x38, 0x97, 0x9a,
-0xd0, 0x03, 0xe0, 0x91, 0x60, 0x90, 0xb0, 0x88, 0x00, 0x68, 0x84, 0x10,
-0x10, 0xc9, 0xe1, 0x2a, 0x00, 0x85, 0x34, 0xb9, 0xcb, 0x61, 0x22, 0x80,
-0x85, 0x34, 0x99, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 0xc9, 0xe1, 0x29,
-0xc0, 0x85, 0x34, 0xb7, 0xcb, 0x61, 0x22, 0x40, 0x85, 0x34, 0x98, 0x90,
-0xb0, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 0xc9, 0xe1, 0x29, 0x80, 0x85,
-0x34, 0xb5, 0xcb, 0x61, 0x22, 0x00, 0x85, 0x34, 0x97, 0x88, 0x00, 0x68,
-0x84, 0x10, 0x10, 0xc9, 0xe1, 0x29, 0x40, 0x85, 0x34, 0xb3, 0xcb, 0x61,
-0x21, 0xc0, 0x85, 0x34, 0x96, 0x90, 0x90, 0x90, 0x48, 0xcb, 0xa1, 0x20,
-0x00, 0x85, 0x34, 0x85, 0xcb, 0xa1, 0x1f, 0xc0, 0x85, 0x34, 0x84, 0x90,
-0x48, 0xcb, 0xa1, 0x1f, 0x80, 0x85, 0x34, 0x83, 0xcb, 0xa1, 0x1f, 0x40,
-0x85, 0x34, 0x82, 0xcb, 0xa2, 0x1d, 0x00, 0x80, 0x38, 0x75, 0x92, 0x40,
-0x91, 0x20, 0x90, 0x90, 0x90, 0x48, 0x8c, 0x23, 0x60, 0x84, 0x24, 0x23,
-0xd8, 0x8c, 0x23, 0x58, 0x84, 0x24, 0x23, 0xd0, 0x90, 0x48, 0x8c, 0x23,
-0x50, 0x84, 0x24, 0x23, 0xc8, 0x8c, 0x23, 0x48, 0x84, 0x24, 0x23, 0xc0,
-0x90, 0x90, 0x90, 0x48, 0x8c, 0x23, 0x38, 0x84, 0x24, 0x23, 0xb0, 0x8c,
-0x23, 0x30, 0x84, 0x24, 0x23, 0xa8, 0x90, 0x48, 0x8c, 0x23, 0x28, 0x84,
-0x24, 0x23, 0xa0, 0x8c, 0x23, 0x20, 0x84, 0x24, 0x23, 0x98, 0x91, 0x20,
-0x90, 0x90, 0x90, 0x48, 0x8c, 0x23, 0x10, 0x84, 0x24, 0x23, 0x88, 0x8c,
-0x23, 0x08, 0x84, 0x24, 0x23, 0x80, 0x90, 0x48, 0x8c, 0x23, 0x00, 0x84,
-0x24, 0x23, 0x78, 0x8c, 0x22, 0xf8, 0x84, 0x24, 0x23, 0x70, 0x90, 0x38,
-0xa4, 0x22, 0xe0, 0x34, 0x5d, 0xa4, 0x22, 0xd0, 0x34, 0x5b, 0xa0, 0x0f,
-0x50, 0xa0, 0x09, 0x08, 0x9a, 0x30, 0x04, 0x40, 0x91, 0x90, 0x90, 0xc8,
-0x98, 0x50, 0x00, 0x80, 0xe5, 0x22, 0x1c, 0x00, 0x38, 0x6c, 0xe5, 0x22,
-0x18, 0x00, 0x38, 0x6a, 0xcb, 0x61, 0x12, 0x40, 0x85, 0x34, 0x58, 0x98,
-0x50, 0x00, 0x80, 0xe5, 0x22, 0x14, 0x00, 0x38, 0x4c, 0xe5, 0x22, 0x10,
-0x00, 0x38, 0x4a, 0xcb, 0x61, 0x12, 0x00, 0x85, 0x34, 0x57, 0x90, 0x48,
-0xcb, 0xa1, 0x11, 0xc0, 0x85, 0x34, 0x56, 0xcb, 0xa1, 0x11, 0x80, 0x85,
-0x34, 0x55, 0x91, 0x90, 0x90, 0xc8, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x22,
-0x09, 0x00, 0x38, 0x30, 0xe5, 0x22, 0x03, 0x00, 0x38, 0x18, 0xcb, 0x61,
-0x11, 0x00, 0x85, 0x34, 0x53, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x21, 0xfd,
-0x00, 0x38, 0x00, 0xe5, 0x21, 0xf7, 0x00, 0x37, 0xe8, 0xcb, 0x61, 0x10,
-0xc0, 0x85, 0x34, 0x52, 0x90, 0x48, 0xcb, 0xa1, 0x10, 0x80, 0x85, 0x34,
-0x51, 0xcb, 0xa1, 0x10, 0x40, 0x85, 0x34, 0x50, 0x92, 0x20, 0x91, 0x30,
-0x90, 0xb8, 0xd5, 0x03, 0x00, 0xc0, 0xc0, 0x81, 0x8c, 0x01, 0xa0, 0x84,
-0x30, 0x3e, 0xc0, 0xc0, 0x81, 0x8c, 0x01, 0x80, 0x84, 0x30, 0x3c, 0xd5,
-0x02, 0x00, 0xc0, 0xc0, 0x81, 0x30, 0x28, 0xc0, 0xc0, 0x81, 0x30, 0x24,
-0x90, 0x78, 0xd5, 0x02, 0x00, 0xc0, 0xc0, 0x81, 0x30, 0x1c, 0xc0, 0xc0,
-0x81, 0x30, 0x18, 0xd5, 0x02, 0x00, 0xc0, 0xc0, 0x81, 0x30, 0x10, 0xc0,
-0xc0, 0x81, 0x30, 0x0c, 0x91, 0x70, 0x90, 0xd8, 0xd5, 0x03, 0x80, 0xc8,
-0xe1, 0xf3, 0x00, 0x81, 0x8c, 0x01, 0xc0, 0x84, 0x30, 0x40, 0xc8, 0xe1,
-0xf4, 0x00, 0x81, 0x8c, 0x01, 0x90, 0x84, 0x30, 0x3d, 0xd5, 0x02, 0x80,
-0xc8, 0xe1, 0xf2, 0x80, 0x81, 0x30, 0x2c, 0xc8, 0xe1, 0xef, 0x80, 0x81,
-0x30, 0x26, 0x90, 0x98, 0xd5, 0x02, 0x80, 0xc8, 0xe1, 0xe9, 0x80, 0x81,
-0x30, 0x20, 0xc8, 0xe1, 0xea, 0x80, 0x81, 0x30, 0x1a, 0xd5, 0x02, 0x80,
-0xc8, 0xe1, 0xe9, 0x00, 0x81, 0x30, 0x14, 0xc8, 0xe1, 0xe6, 0x00, 0x81,
-0x30, 0x0e, 0x9a, 0x30, 0x04, 0x40, 0x91, 0x90, 0x90, 0xc8, 0x98, 0x50,
-0x00, 0x80, 0xe5, 0x22, 0x16, 0x00, 0x38, 0x54, 0xe5, 0x22, 0x17, 0x00,
-0x38, 0x66, 0xcb, 0x61, 0x0f, 0xc0, 0x85, 0x34, 0x4e, 0x98, 0x50, 0x00,
-0x80, 0xe5, 0x22, 0x0e, 0x00, 0x38, 0x34, 0xe5, 0x22, 0x0f, 0x00, 0x38,
-0x46, 0xcb, 0x61, 0x0f, 0x80, 0x85, 0x34, 0x4d, 0x90, 0x48, 0xcb, 0xa1,
-0x0f, 0x40, 0x85, 0x34, 0x4c, 0xcb, 0xa1, 0x0f, 0x00, 0x85, 0x34, 0x4b,
-0x91, 0x90, 0x90, 0xc8, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x22, 0x07, 0x00,
-0x38, 0x28, 0xe5, 0x22, 0x01, 0x00, 0x38, 0x10, 0xcb, 0x61, 0x0d, 0x40,
-0x85, 0x34, 0x3a, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x21, 0xfb, 0x00, 0x37,
-0xf8, 0xe5, 0x21, 0xf5, 0x00, 0x37, 0xe0, 0xcb, 0x61, 0x0d, 0x00, 0x85,
-0x34, 0x39, 0x90, 0x48, 0xcb, 0xa1, 0x0c, 0xc0, 0x85, 0x34, 0x38, 0xcb,
-0xa1, 0x0c, 0x80, 0x85, 0x34, 0x37, 0x91, 0x00, 0x90, 0x80, 0x90, 0x40,
-0xe5, 0x20, 0x02, 0x40, 0x30, 0x0a, 0xe5, 0x20, 0x01, 0x80, 0x30, 0x07,
-0x90, 0x40, 0xe5, 0x20, 0x00, 0xc0, 0x30, 0x04, 0xe5, 0x20, 0x00, 0x00,
-0x30, 0x01, 0x90, 0x80, 0x90, 0x40, 0xe5, 0x21, 0xed, 0x00, 0x37, 0xae,
-0xe5, 0x21, 0xee, 0x40, 0x37, 0xc4, 0x90, 0x40, 0xe5, 0x21, 0xe3, 0x80,
-0x37, 0x88, 0xe5, 0x21, 0xe4, 0xc0, 0x37, 0x9e, 0x80, 0x99, 0x28, 0x02,
-0xf0, 0x8c, 0x21, 0x48, 0x90, 0x80, 0x90, 0x40, 0xe5, 0x22, 0x19, 0x00,
-0x38, 0x62, 0xe5, 0x22, 0x17, 0x80, 0x38, 0x68, 0x90, 0x40, 0xe5, 0x22,
-0x11, 0x00, 0x38, 0x42, 0xe5, 0x22, 0x0f, 0x80, 0x38, 0x48, 0x91, 0x48,
-0x90, 0xc8, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x22, 0x08, 0x00, 0x38, 0x2c,
-0xe5, 0x22, 0x02, 0x00, 0x38, 0x14, 0xcb, 0x61, 0x0b, 0x00, 0x85, 0x34,
-0x30, 0x90, 0x40, 0xe5, 0x21, 0xfc, 0x00, 0x37, 0xfc, 0xe5, 0x21, 0xf6,
-0x00, 0x37, 0xe4, 0x90, 0x48, 0xcb, 0xa1, 0x0a, 0x80, 0x85, 0x34, 0x2e,
-0xcb, 0xa1, 0x0a, 0xc0, 0x85, 0x34, 0x2f, 0x10, 0x10, 0x90, 0x80, 0x90,
-0x40, 0xe5, 0x21, 0xf0, 0x80, 0x37, 0xc0, 0xe5, 0x21, 0xef, 0x00, 0x37,
-0xc8, 0x90, 0x40, 0xe5, 0x21, 0xe7, 0x00, 0x37, 0x9a, 0xe5, 0x21, 0xe5,
-0x80, 0x37, 0xa2,
+0xa0, 0xc4, 0xd8, 0xa0, 0x2d, 0x88, 0xa0, 0x2b, 0x70, 0xa0, 0x1a, 0xb0,
+0x98, 0xb0, 0x01, 0x40, 0x90, 0x50, 0x90, 0x28, 0x24, 0x31, 0xf8, 0x24,
+0x31, 0xf0, 0x90, 0x28, 0x24, 0x31, 0xe8, 0x24, 0x31, 0xe0, 0x90, 0x50,
+0x90, 0x28, 0x24, 0x31, 0xd0, 0x24, 0x31, 0xc8, 0x90, 0x28, 0x24, 0x31,
+0xc0, 0x24, 0x31, 0xb8, 0xa8, 0x0b, 0x48, 0x15, 0x20, 0x97, 0x20, 0x95,
+0xc8, 0x9a, 0xb8, 0x05, 0x38, 0x91, 0x18, 0x90, 0xa0, 0x90, 0x60, 0x80,
+0x90, 0x20, 0x34, 0x3c, 0xa4, 0x21, 0xb0, 0x34, 0x39, 0x80, 0xa4, 0x2f,
+0x70, 0x35, 0xf3, 0x90, 0x50, 0x90, 0x28, 0x80, 0x35, 0xe9, 0x80, 0x34,
+0x1d, 0x81, 0x33, 0xb9, 0x90, 0xe0, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x20,
+0xc8, 0x34, 0x1a, 0xa4, 0x1d, 0xc0, 0x34, 0x17, 0x90, 0x38, 0xa4, 0x31,
+0x70, 0x36, 0x34, 0xa4, 0x31, 0x18, 0x36, 0x28, 0x90, 0x70, 0x90, 0x38,
+0xa4, 0x2f, 0xf0, 0x36, 0x09, 0xa4, 0x2f, 0xc8, 0x36, 0x04, 0x80, 0xa4,
+0x20, 0xa8, 0x34, 0x16, 0x92, 0x18, 0x91, 0xc0, 0x80, 0x91, 0x80, 0x90,
+0xf8, 0xdb, 0x84, 0x60, 0xef, 0x00, 0xc0, 0xc0, 0x80, 0xa4, 0x3b, 0x28,
+0x8c, 0x3c, 0x88, 0x84, 0x37, 0x9b, 0xc0, 0xc0, 0x80, 0xa4, 0x3b, 0x18,
+0x8c, 0x3c, 0x68, 0x84, 0x37, 0x99, 0xd3, 0x82, 0x40, 0x50, 0xc0, 0xc0,
+0x81, 0x37, 0x4d, 0x50, 0xc0, 0xc0, 0x81, 0x37, 0x4b, 0xa4, 0x1d, 0xd0,
+0x33, 0xbb, 0x80, 0x90, 0x28, 0x80, 0x33, 0xb7, 0x80, 0x34, 0x1f, 0x81,
+0x90, 0x38, 0xa4, 0x21, 0x30, 0x34, 0x22, 0xa4, 0x21, 0x00, 0x34, 0x1c,
+0xc0, 0x40, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x1d, 0xa8, 0x33, 0xb6, 0xa4,
+0x1d, 0x98, 0x33, 0xb4, 0x18, 0x24, 0x21, 0xa8, 0x83, 0x90, 0xa8, 0xd3,
+0x82, 0xc0, 0xc0, 0xc0, 0x80, 0xa4, 0x3a, 0xf8, 0x37, 0x85, 0xc0, 0xc0,
+0x80, 0xa4, 0x3a, 0xe8, 0x37, 0x81, 0xd3, 0x82, 0x40, 0x50, 0xc0, 0xc0,
+0x81, 0x37, 0x47, 0x50, 0xc0, 0xc0, 0x81, 0x37, 0x45, 0x92, 0xb8, 0x99,
+0x84, 0x21, 0x20, 0x90, 0x78, 0x90, 0x50, 0x10, 0x10, 0x80, 0xa4, 0x2f,
+0x68, 0x35, 0xf2, 0x82, 0x35, 0xe8, 0x90, 0x80, 0x10, 0x10, 0x90, 0x38,
+0xa4, 0x31, 0x68, 0x36, 0x33, 0xa4, 0x31, 0x10, 0x36, 0x27, 0x80, 0x90,
+0x38, 0xa4, 0x2f, 0xe8, 0x36, 0x08, 0xa4, 0x2f, 0xc0, 0x36, 0x03, 0x83,
+0x90, 0xa8, 0xd3, 0x82, 0xc0, 0xc0, 0xc0, 0x80, 0xa4, 0x3a, 0xc8, 0x37,
+0x79, 0xc0, 0xc0, 0x80, 0xa4, 0x3a, 0xb8, 0x37, 0x75, 0xd3, 0x82, 0x40,
+0x50, 0xc0, 0xc0, 0x81, 0x37, 0x41, 0x50, 0xc0, 0xc0, 0x81, 0x37, 0x3f,
+0x18, 0x24, 0x21, 0x28, 0x83, 0x90, 0xa8, 0xd3, 0x82, 0xc0, 0xc0, 0xc0,
+0x80, 0xa4, 0x3a, 0x98, 0x37, 0x6d, 0xc0, 0xc0, 0x80, 0xa4, 0x3a, 0x88,
+0x37, 0x69, 0xd3, 0x82, 0x40, 0x50, 0xc0, 0xc0, 0x81, 0x37, 0x3b, 0x50,
+0xc0, 0xc0, 0x81, 0x37, 0x39, 0x94, 0x50, 0x92, 0xf8, 0x99, 0x84, 0x1e,
+0x00, 0x90, 0x78, 0x90, 0x50, 0x10, 0x10, 0x80, 0xa4, 0x2f, 0x60, 0x35,
+0xf1, 0x82, 0x35, 0xe7, 0x90, 0x80, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x31,
+0x60, 0x36, 0x32, 0xa4, 0x31, 0x08, 0x36, 0x26, 0x80, 0x90, 0x38, 0xa4,
+0x2f, 0xe0, 0x36, 0x07, 0xa4, 0x2f, 0xb8, 0x36, 0x02, 0x83, 0x90, 0xe8,
+0xd3, 0x83, 0xc0, 0xc0, 0xc0, 0x80, 0xa4, 0x3b, 0x38, 0x8c, 0x3c, 0xa8,
+0x84, 0x37, 0x9d, 0xc0, 0xc0, 0x80, 0xa4, 0x3b, 0x20, 0x8c, 0x3c, 0x78,
+0x84, 0x37, 0x9a, 0xd3, 0x82, 0x40, 0x50, 0xc0, 0xc0, 0x81, 0x37, 0x4f,
+0x50, 0xc0, 0xc0, 0x81, 0x37, 0x4c, 0x18, 0x24, 0x1d, 0xf8, 0x83, 0x90,
+0xa8, 0xd3, 0x82, 0xc0, 0xc0, 0xc0, 0x80, 0xa4, 0x3b, 0x08, 0x37, 0x89,
+0xc0, 0xc0, 0x80, 0xa4, 0x3a, 0xf0, 0x37, 0x83, 0xd3, 0x82, 0x40, 0x50,
+0xc0, 0xc0, 0x81, 0x37, 0x49, 0x50, 0xc0, 0xc0, 0x81, 0x37, 0x46, 0x92,
+0xb8, 0x99, 0x84, 0x1d, 0xf0, 0x90, 0x78, 0x90, 0x50, 0x10, 0x10, 0x80,
+0xa4, 0x2f, 0x58, 0x35, 0xf0, 0x82, 0x35, 0xe6, 0x90, 0x80, 0x10, 0x10,
+0x90, 0x38, 0xa4, 0x31, 0x58, 0x36, 0x31, 0xa4, 0x31, 0x00, 0x36, 0x25,
+0x80, 0x90, 0x38, 0xa4, 0x2f, 0xd8, 0x36, 0x06, 0xa4, 0x2f, 0xb0, 0x36,
+0x01, 0x83, 0x90, 0xa8, 0xd3, 0x82, 0xc0, 0xc0, 0xc0, 0x80, 0xa4, 0x3a,
+0xd8, 0x37, 0x7d, 0xc0, 0xc0, 0x80, 0xa4, 0x3a, 0xc0, 0x37, 0x77, 0xd3,
+0x82, 0x40, 0x50, 0xc0, 0xc0, 0x81, 0x37, 0x43, 0x50, 0xc0, 0xc0, 0x81,
+0x37, 0x40, 0x18, 0x20, 0x01, 0x48, 0x83, 0x90, 0xa8, 0xd3, 0x82, 0xc0,
+0xc0, 0xc0, 0x80, 0xa4, 0x3a, 0xa8, 0x37, 0x71, 0xc0, 0xc0, 0x80, 0xa4,
+0x3a, 0x90, 0x37, 0x6b, 0xd3, 0x82, 0x40, 0x50, 0xc0, 0xc0, 0x81, 0x37,
+0x3d, 0x50, 0xc0, 0xc0, 0x81, 0x37, 0x3a, 0xda, 0x06, 0xe0, 0xef, 0x40,
+0x90, 0x60, 0x90, 0x38, 0xa4, 0x21, 0x98, 0x34, 0x31, 0x80, 0x34, 0x2e,
+0x90, 0x38, 0xa4, 0x21, 0x40, 0x34, 0x2c, 0x80, 0x34, 0x29, 0x90, 0x60,
+0x90, 0x38, 0xa4, 0x21, 0x80, 0x34, 0x32, 0x80, 0x34, 0x2f, 0x90, 0x38,
+0xa4, 0x21, 0x58, 0x34, 0x2d, 0x80, 0x34, 0x2a, 0xc8, 0x40, 0x19, 0x00,
+0x91, 0x58, 0x90, 0x60, 0x82, 0x90, 0x20, 0x35, 0xe5, 0xa4, 0x2f, 0x18,
+0x35, 0xe4, 0x90, 0xc0, 0x80, 0x90, 0x90, 0x90, 0x48, 0xc9, 0xe1, 0x87,
+0x80, 0x85, 0x36, 0x1d, 0xc9, 0xe1, 0x86, 0xc0, 0x85, 0x36, 0x1a, 0x80,
+0x36, 0x19, 0x10, 0x10, 0x81, 0x35, 0xf5, 0x90, 0xa8, 0x10, 0x10, 0x90,
+0x28, 0x81, 0x36, 0x13, 0x90, 0x38, 0xa4, 0x30, 0x70, 0x36, 0x0f, 0xa4,
+0x30, 0x60, 0x36, 0x0d, 0x90, 0x70, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x30,
+0x88, 0x36, 0x12, 0x80, 0x36, 0x10, 0x90, 0x60, 0x90, 0x28, 0x24, 0x30,
+0xc0, 0xa4, 0x30, 0xb0, 0x36, 0x17, 0x80, 0xa4, 0x30, 0xa0, 0x36, 0x15,
+0x80, 0x90, 0xf8, 0x90, 0x90, 0x90, 0x50, 0x90, 0x28, 0x80, 0x37, 0x31,
+0x80, 0x37, 0x38, 0x80, 0xa4, 0x39, 0xb0, 0x37, 0x37, 0x90, 0x28, 0x81,
+0x37, 0x35, 0x80, 0xa4, 0x39, 0x98, 0x37, 0x34, 0x83, 0x37, 0x32, 0x98,
+0xe8, 0x01, 0xb0, 0x90, 0x88, 0x90, 0x60, 0xa4, 0x2f, 0x08, 0x10, 0x10,
+0x10, 0x10, 0x83, 0x33, 0x8f, 0x24, 0x2f, 0x00, 0x90, 0x28, 0x24, 0x2e,
+0xf8, 0x24, 0x2e, 0xf0, 0x90, 0x88, 0x90, 0x60, 0xa4, 0x2e, 0xe0, 0x10,
+0x10, 0x10, 0x10, 0x83, 0x33, 0x8e, 0x24, 0x2e, 0xd8, 0x90, 0x28, 0x24,
+0x2e, 0xd0, 0x24, 0x2e, 0xc8, 0xa8, 0x09, 0x00, 0x0e, 0x20, 0x96, 0x48,
+0x95, 0xe8, 0x93, 0x38, 0x91, 0xa0, 0x90, 0xd0, 0x90, 0x70, 0x90, 0x38,
+0xa4, 0x1d, 0x20, 0x33, 0xa5, 0xa4, 0x1d, 0x10, 0x33, 0xa3, 0x90, 0x38,
+0xa4, 0x1d, 0x00, 0x33, 0xa1, 0x80, 0x33, 0x9f, 0x90, 0x60, 0x90, 0x28,
+0x24, 0x1c, 0xc0, 0xa4, 0x1c, 0xb0, 0x33, 0x97, 0x90, 0x38, 0xa4, 0x1c,
+0xa0, 0x33, 0x95, 0xa4, 0x1c, 0xe8, 0x33, 0x9e, 0x90, 0xe0, 0x90, 0x70,
+0x90, 0x38, 0xa4, 0x1c, 0xd8, 0x33, 0x9c, 0xa4, 0x1c, 0xc8, 0x33, 0x9a,
+0x90, 0x38, 0xa4, 0x2e, 0x80, 0x35, 0xd6, 0xa4, 0x2e, 0x20, 0x35, 0xca,
+0x90, 0x70, 0x90, 0x38, 0xa4, 0x2b, 0x60, 0x35, 0x78, 0xa4, 0x2b, 0x30,
+0x35, 0x72, 0x10, 0x10, 0xa4, 0x1c, 0x90, 0x33, 0x93, 0x99, 0x60, 0x02,
+0x70, 0x90, 0x90, 0x90, 0x50, 0x90, 0x28, 0x24, 0x1d, 0x50, 0x80, 0x33,
+0xb1, 0x80, 0xa4, 0x1d, 0x58, 0x33, 0xaf, 0x90, 0x50, 0x90, 0x28, 0x24,
+0x1d, 0x60, 0x80, 0x33, 0xb2, 0x90, 0x38, 0xa4, 0x1d, 0x68, 0x33, 0xb0,
+0xa4, 0x1d, 0x30, 0x33, 0xa7, 0x90, 0xe0, 0x90, 0x70, 0x90, 0x38, 0xa4,
+0x2d, 0xb8, 0x35, 0xbf, 0xa4, 0x2d, 0x18, 0x35, 0xac, 0x90, 0x38, 0xa4,
+0x2c, 0xb0, 0x35, 0x9d, 0xa4, 0x2c, 0x20, 0x35, 0x8c, 0x81, 0xa4, 0x1d,
+0x40, 0x33, 0xa9, 0xe4, 0xa1, 0xca, 0xc0, 0x37, 0x2d, 0x18, 0x24, 0x1c,
+0x88, 0xe4, 0xe1, 0xc9, 0x40, 0x37, 0x27, 0x92, 0x40, 0x91, 0x08, 0x10,
+0x10, 0x90, 0x80, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x2e, 0x78, 0x35, 0xd5,
+0xa4, 0x2e, 0x18, 0x35, 0xc9, 0x80, 0x90, 0x38, 0xa4, 0x2b, 0x58, 0x35,
+0x77, 0xa4, 0x2b, 0x28, 0x35, 0x71, 0x18, 0x20, 0x00, 0xf8, 0x80, 0x90,
+0x70, 0x90, 0x38, 0xa4, 0x2d, 0xa8, 0x35, 0xbe, 0xa4, 0x2d, 0x10, 0x35,
+0xaa, 0x90, 0x38, 0xa4, 0x2c, 0xa0, 0x35, 0x9c, 0xa4, 0x2c, 0x18, 0x35,
+0x8a, 0xe4, 0xa1, 0xc7, 0xc0, 0x37, 0x21, 0x18, 0x24, 0x1c, 0x80, 0xe4,
+0xe1, 0xc6, 0x40, 0x37, 0x1b, 0x92, 0x90, 0x92, 0x40, 0x91, 0x08, 0x10,
+0x10, 0x90, 0x80, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x2e, 0x70, 0x35, 0xd4,
+0xa4, 0x2e, 0x10, 0x35, 0xc8, 0x80, 0x90, 0x38, 0xa4, 0x2b, 0x50, 0x35,
+0x76, 0xa4, 0x2b, 0x20, 0x35, 0x70, 0x18, 0x20, 0x00, 0xf8, 0x80, 0x90,
+0x70, 0x90, 0x38, 0xa4, 0x2d, 0x98, 0x35, 0xbd, 0xa4, 0x2d, 0x08, 0x35,
+0xa8, 0x90, 0x38, 0xa4, 0x2c, 0x90, 0x35, 0x9b, 0xa4, 0x2c, 0x10, 0x35,
+0x88, 0xe4, 0xa1, 0xcb, 0x00, 0x37, 0x2f, 0x10, 0x10, 0xe4, 0xe1, 0xc9,
+0x80, 0x37, 0x29, 0x92, 0x50, 0x99, 0x1c, 0x1d, 0x70, 0x10, 0x10, 0x90,
+0x80, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x2e, 0x68, 0x35, 0xd3, 0xa4, 0x2e,
+0x08, 0x35, 0xc7, 0x80, 0x90, 0x38, 0xa4, 0x2b, 0x48, 0x35, 0x75, 0xa4,
+0x2b, 0x18, 0x35, 0x6f, 0x18, 0x20, 0x00, 0xf8, 0x80, 0x90, 0x70, 0x90,
+0x38, 0xa4, 0x2d, 0x88, 0x35, 0xbc, 0xa4, 0x2d, 0x00, 0x35, 0xa6, 0x90,
+0x38, 0xa4, 0x2c, 0x80, 0x35, 0x9a, 0xa4, 0x2c, 0x08, 0x35, 0x86, 0xe4,
+0xa1, 0xc8, 0x00, 0x37, 0x23, 0x10, 0x10, 0xe4, 0xe1, 0xc6, 0x80, 0x37,
+0x1d, 0xc0, 0x40, 0x80, 0x10, 0x10, 0x81, 0x90, 0x90, 0x90, 0x48, 0xc9,
+0xe1, 0x5f, 0x00, 0x85, 0x35, 0x80, 0xc9, 0xe1, 0x5f, 0x80, 0x85, 0x35,
+0x7d, 0x80, 0x35, 0x7b, 0x80, 0xd8, 0x47, 0x80, 0x0d, 0xc0, 0xc0, 0x80,
+0x10, 0x10, 0x82, 0x90, 0x58, 0xd5, 0x81, 0x80, 0x80, 0x37, 0x17, 0x80,
+0x37, 0x15, 0xd5, 0x81, 0x80, 0x80, 0x37, 0x13, 0x80, 0x37, 0x11, 0xc0,
+0x80, 0x10, 0x10, 0x82, 0x90, 0x58, 0xd5, 0x81, 0x80, 0x80, 0x37, 0x18,
+0x80, 0x37, 0x16, 0xd5, 0x81, 0x80, 0x80, 0x37, 0x14, 0x80, 0x37, 0x12,
+0xc0, 0x80, 0x83, 0xa4, 0x38, 0x78, 0x37, 0x10, 0xa0, 0x57, 0xc0, 0xa0,
+0x41, 0xe0, 0xa8, 0x1e, 0xb0, 0x34, 0x88, 0xa0, 0x12, 0x38, 0xa0, 0x0b,
+0x48, 0x96, 0x00, 0x9a, 0xf0, 0x05, 0xc0, 0x91, 0x70, 0x90, 0xb8, 0x90,
+0x70, 0x90, 0x38, 0xa4, 0x14, 0x80, 0x33, 0x8d, 0xa4, 0x14, 0x90, 0x33,
+0x8c, 0x10, 0x10, 0xa4, 0x14, 0x88, 0x33, 0x8b, 0x90, 0x70, 0x90, 0x38,
+0xa4, 0x14, 0x50, 0x33, 0x72, 0xa4, 0x14, 0x60, 0x33, 0x71, 0x10, 0x10,
+0xa4, 0x14, 0x58, 0x33, 0x70, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4,
+0x14, 0x20, 0x33, 0x57, 0xa4, 0x14, 0x30, 0x33, 0x56, 0x10, 0x10, 0xa4,
+0x14, 0x28, 0x33, 0x55, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0xf0, 0x33,
+0x3b, 0xa4, 0x14, 0x00, 0x33, 0x3a, 0x10, 0x10, 0xa4, 0x13, 0xf8, 0x33,
+0x39, 0x91, 0x70, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x14, 0x68,
+0x33, 0x88, 0xa4, 0x14, 0x78, 0x33, 0x8a, 0x10, 0x10, 0xa4, 0x14, 0x70,
+0x33, 0x89, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x14, 0x38, 0x33, 0x6d, 0xa4,
+0x14, 0x48, 0x33, 0x6f, 0x10, 0x10, 0xa4, 0x14, 0x40, 0x33, 0x6e, 0x90,
+0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x14, 0x08, 0x33, 0x52, 0xa4, 0x14,
+0x18, 0x33, 0x54, 0x10, 0x10, 0xa4, 0x14, 0x10, 0x33, 0x53, 0x90, 0x70,
+0x90, 0x38, 0xa4, 0x13, 0xd8, 0x33, 0x36, 0xa4, 0x13, 0xe8, 0x33, 0x38,
+0x10, 0x10, 0xa4, 0x13, 0xe0, 0x33, 0x37, 0xe4, 0xe1, 0x55, 0x40, 0x35,
+0x5f, 0x9a, 0xf0, 0x05, 0x00, 0x91, 0x70, 0x90, 0xb8, 0x90, 0x70, 0x90,
+0x38, 0xa4, 0x13, 0xa0, 0x33, 0x85, 0xa4, 0x13, 0x98, 0x33, 0x87, 0x10,
+0x10, 0xa4, 0x13, 0x90, 0x33, 0x86, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13,
+0x88, 0x33, 0x6a, 0xa4, 0x13, 0x80, 0x33, 0x6c, 0x10, 0x10, 0xa4, 0x13,
+0x78, 0x33, 0x6b, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0x70,
+0x33, 0x4f, 0xa4, 0x13, 0x68, 0x33, 0x51, 0x10, 0x10, 0xa4, 0x13, 0x60,
+0x33, 0x50, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0x58, 0x33, 0x33, 0xa4,
+0x13, 0x50, 0x33, 0x35, 0x10, 0x10, 0xa4, 0x13, 0x48, 0x33, 0x34, 0x91,
+0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x82, 0x80, 0x33,
+0x84, 0x10, 0x10, 0x80, 0x33, 0x83, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33,
+0x67, 0x80, 0x33, 0x69, 0x10, 0x10, 0x80, 0x33, 0x68, 0x90, 0x88, 0x90,
+0x50, 0x90, 0x28, 0x80, 0x33, 0x4c, 0x80, 0x33, 0x4e, 0x10, 0x10, 0x80,
+0x33, 0x4d, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x30, 0x80, 0x33, 0x32,
+0x10, 0x10, 0x80, 0x33, 0x31, 0xe4, 0xe1, 0x42, 0xc0, 0x35, 0x1f, 0x95,
+0x40, 0x9a, 0x90, 0x05, 0x00, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90,
+0x28, 0x80, 0x33, 0x7f, 0x80, 0x33, 0x81, 0x10, 0x10, 0x80, 0x33, 0x80,
+0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x64, 0x80, 0x33, 0x66, 0x10, 0x10,
+0x80, 0x33, 0x65, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0x30,
+0x33, 0x49, 0xa4, 0x13, 0x40, 0x33, 0x4b, 0x10, 0x10, 0xa4, 0x13, 0x38,
+0x33, 0x4a, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0x00, 0x33, 0x2d, 0xa4,
+0x13, 0x10, 0x33, 0x2f, 0x10, 0x10, 0xa4, 0x13, 0x08, 0x33, 0x2e, 0x91,
+0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x7c, 0x80, 0x33,
+0x7e, 0x10, 0x10, 0x80, 0x33, 0x7d, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33,
+0x61, 0x80, 0x33, 0x63, 0x10, 0x10, 0x80, 0x33, 0x62, 0x90, 0xb8, 0x90,
+0x70, 0x90, 0x38, 0xa4, 0x13, 0x18, 0x33, 0x46, 0xa4, 0x13, 0x28, 0x33,
+0x48, 0x10, 0x10, 0xa4, 0x13, 0x20, 0x33, 0x47, 0x90, 0x70, 0x90, 0x38,
+0xa4, 0x12, 0xe8, 0x33, 0x2a, 0xa4, 0x12, 0xf8, 0x33, 0x2c, 0x10, 0x10,
+0xa4, 0x12, 0xf0, 0x33, 0x2b, 0xe4, 0xe1, 0x54, 0xc0, 0x35, 0x5d, 0x98,
+0xb8, 0x01, 0x68, 0x10, 0x10, 0x10, 0x10, 0x90, 0x50, 0x90, 0x28, 0x80,
+0x33, 0x27, 0x80, 0x33, 0x29, 0x10, 0x10, 0x80, 0x33, 0x28, 0x90, 0x60,
+0x90, 0x30, 0x60, 0xa0, 0x97, 0x00, 0x60, 0xa0, 0x96, 0xc0, 0x90, 0x30,
+0x60, 0xa0, 0x96, 0x80, 0x60, 0xa0, 0x96, 0x40, 0xe4, 0xe1, 0x41, 0xc0,
+0x35, 0x1b, 0xa0, 0x08, 0x08, 0x94, 0xe0, 0x9a, 0x60, 0x04, 0xa0, 0x91,
+0x40, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0xc0, 0x33, 0x76,
+0xa4, 0x13, 0xd0, 0x33, 0x7b, 0x10, 0x10, 0xa4, 0x13, 0xc8, 0x33, 0x7a,
+0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x5b, 0x80, 0x33, 0x60, 0x10, 0x10,
+0x80, 0x33, 0x5f, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x40,
+0x80, 0x33, 0x45, 0x10, 0x10, 0x80, 0x33, 0x44, 0x90, 0x50, 0x90, 0x28,
+0x80, 0x33, 0x21, 0x80, 0x33, 0x26, 0x10, 0x10, 0x80, 0x33, 0x25, 0x91,
+0x40, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x13, 0xa8, 0x33, 0x73,
+0xa4, 0x13, 0xb8, 0x33, 0x75, 0x10, 0x10, 0xa4, 0x13, 0xb0, 0x33, 0x74,
+0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x58, 0x80, 0x33, 0x5a, 0x10, 0x10,
+0x80, 0x33, 0x59, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x3d,
+0x80, 0x33, 0x3f, 0x10, 0x10, 0x80, 0x33, 0x3e, 0x90, 0x50, 0x90, 0x28,
+0x80, 0x33, 0x1e, 0x80, 0x33, 0x20, 0x10, 0x10, 0x80, 0x33, 0x1f, 0xe4,
+0xe1, 0x54, 0x40, 0x35, 0x5b, 0x9a, 0x60, 0x02, 0xe0, 0x91, 0x40, 0x90,
+0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x18, 0xe8, 0x33, 0x77, 0xa4, 0x18,
+0xe0, 0x33, 0x79, 0x10, 0x10, 0xa4, 0x18, 0xd8, 0x33, 0x78, 0x90, 0x50,
+0x90, 0x28, 0x80, 0x33, 0x5c, 0x80, 0x33, 0x5e, 0x10, 0x10, 0x80, 0x33,
+0x5d, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x41, 0x80, 0x33,
+0x43, 0x10, 0x10, 0x80, 0x33, 0x42, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33,
+0x22, 0x80, 0x33, 0x24, 0x10, 0x10, 0x80, 0x33, 0x23, 0x81, 0x90, 0x50,
+0x90, 0x28, 0x24, 0x18, 0xc0, 0x24, 0x18, 0xd0, 0x10, 0x10, 0x24, 0x18,
+0xc8, 0xe4, 0xe1, 0x40, 0xc0, 0x35, 0x17, 0x93, 0x90, 0x99, 0xb8, 0x03,
+0x50, 0x90, 0xe8, 0x90, 0x88, 0x90, 0x40, 0x80, 0xa4, 0x14, 0xb0, 0x32,
+0xa8, 0x10, 0x10, 0xa4, 0x14, 0xa8, 0x32, 0xa7, 0x90, 0x28, 0x81, 0x32,
+0xa4, 0x10, 0x10, 0x80, 0x32, 0xa3, 0x90, 0x60, 0x90, 0x28, 0x81, 0x32,
+0xa0, 0x10, 0x10, 0x80, 0x32, 0x9f, 0x90, 0x28, 0x81, 0x32, 0x9c, 0x10,
+0x10, 0x80, 0x32, 0x9b, 0x90, 0xe8, 0x90, 0x88, 0x90, 0x40, 0x80, 0xa4,
+0x14, 0x98, 0x32, 0xa5, 0x10, 0x10, 0xa4, 0x14, 0xa0, 0x32, 0xa6, 0x90,
+0x28, 0x81, 0x32, 0xa1, 0x10, 0x10, 0x80, 0x32, 0xa2, 0x90, 0x60, 0x90,
+0x28, 0x81, 0x32, 0x9d, 0x10, 0x10, 0x80, 0x32, 0x9e, 0x90, 0x28, 0x81,
+0x32, 0x99, 0x10, 0x10, 0x80, 0x32, 0x9a, 0xe4, 0xe1, 0x53, 0xc0, 0x35,
+0x59, 0x88, 0x00, 0x88, 0x10, 0x10, 0x10, 0x10, 0x90, 0x28, 0x81, 0x32,
+0x97, 0x10, 0x10, 0x80, 0x32, 0x98, 0xe4, 0xe1, 0x3f, 0xc0, 0x35, 0x13,
+0xa0, 0x0e, 0x80, 0xa0, 0x09, 0x08, 0x94, 0x80, 0x9a, 0x30, 0x04, 0x40,
+0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x17, 0x80,
+0x33, 0x16, 0x10, 0x10, 0x80, 0x33, 0x15, 0x90, 0x50, 0x90, 0x28, 0x80,
+0x32, 0xfc, 0x80, 0x32, 0xfb, 0x10, 0x10, 0x80, 0x32, 0xfa, 0x90, 0x88,
+0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xe1, 0x80, 0x32, 0xe0, 0x10, 0x10,
+0x80, 0x32, 0xdf, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xc6, 0x80, 0x32,
+0xc5, 0x10, 0x10, 0x80, 0x32, 0xc4, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50,
+0x90, 0x28, 0x80, 0x33, 0x12, 0x80, 0x33, 0x14, 0x10, 0x10, 0x80, 0x33,
+0x13, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xf7, 0x80, 0x32, 0xf9, 0x10,
+0x10, 0x80, 0x32, 0xf8, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32,
+0xdc, 0x80, 0x32, 0xde, 0x10, 0x10, 0x80, 0x32, 0xdd, 0x90, 0x50, 0x90,
+0x28, 0x80, 0x32, 0xc1, 0x80, 0x32, 0xc3, 0x10, 0x10, 0x80, 0x32, 0xc2,
+0xe4, 0xe1, 0x4c, 0xc0, 0x35, 0x47, 0x9a, 0x30, 0x04, 0x40, 0x91, 0x10,
+0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x0f, 0x80, 0x33, 0x11,
+0x10, 0x10, 0x80, 0x33, 0x10, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xf4,
+0x80, 0x32, 0xf6, 0x10, 0x10, 0x80, 0x32, 0xf5, 0x90, 0x88, 0x90, 0x50,
+0x90, 0x28, 0x80, 0x32, 0xd9, 0x80, 0x32, 0xdb, 0x10, 0x10, 0x80, 0x32,
+0xda, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xbe, 0x80, 0x32, 0xc0, 0x10,
+0x10, 0x80, 0x32, 0xbf, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28,
+0x80, 0x33, 0x0c, 0x80, 0x33, 0x0e, 0x10, 0x10, 0x80, 0x33, 0x0d, 0x90,
+0x50, 0x90, 0x28, 0x80, 0x32, 0xf1, 0x80, 0x32, 0xf3, 0x10, 0x10, 0x80,
+0x32, 0xf2, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xd6, 0x80,
+0x32, 0xd8, 0x10, 0x10, 0x80, 0x32, 0xd7, 0x90, 0x50, 0x90, 0x28, 0x80,
+0x32, 0xbb, 0x80, 0x32, 0xbd, 0x10, 0x10, 0x80, 0x32, 0xbc, 0xe4, 0xe1,
+0x3c, 0x40, 0x34, 0xfb, 0x94, 0x80, 0x9a, 0x30, 0x04, 0x40, 0x91, 0x10,
+0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x09, 0x80, 0x33, 0x0b,
+0x10, 0x10, 0x80, 0x33, 0x0a, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xee,
+0x80, 0x32, 0xf0, 0x10, 0x10, 0x80, 0x32, 0xef, 0x90, 0x88, 0x90, 0x50,
+0x90, 0x28, 0x80, 0x32, 0xd3, 0x80, 0x32, 0xd5, 0x10, 0x10, 0x80, 0x32,
+0xd4, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xb8, 0x80, 0x32, 0xba, 0x10,
+0x10, 0x80, 0x32, 0xb9, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28,
+0x80, 0x33, 0x06, 0x80, 0x33, 0x08, 0x10, 0x10, 0x80, 0x33, 0x07, 0x90,
+0x50, 0x90, 0x28, 0x80, 0x32, 0xeb, 0x80, 0x32, 0xed, 0x10, 0x10, 0x80,
+0x32, 0xec, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xd0, 0x80,
+0x32, 0xd2, 0x10, 0x10, 0x80, 0x32, 0xd1, 0x90, 0x50, 0x90, 0x28, 0x80,
+0x32, 0xb5, 0x80, 0x32, 0xb7, 0x10, 0x10, 0x80, 0x32, 0xb6, 0xe4, 0xe1,
+0x4b, 0xc0, 0x35, 0x43, 0x88, 0x00, 0xb0, 0x10, 0x10, 0x10, 0x10, 0x90,
+0x50, 0x90, 0x28, 0x80, 0x32, 0xb2, 0x80, 0x32, 0xb4, 0x10, 0x10, 0x80,
+0x32, 0xb3, 0xe4, 0xe1, 0x3b, 0xc0, 0x34, 0xf9, 0x96, 0xe8, 0x94, 0x80,
+0x9a, 0x30, 0x04, 0x40, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28,
+0x80, 0x33, 0x00, 0x80, 0x33, 0x05, 0x10, 0x10, 0x80, 0x33, 0x04, 0x90,
+0x50, 0x90, 0x28, 0x80, 0x32, 0xe5, 0x80, 0x32, 0xea, 0x10, 0x10, 0x80,
+0x32, 0xe9, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xca, 0x80,
+0x32, 0xcf, 0x10, 0x10, 0x80, 0x32, 0xce, 0x90, 0x50, 0x90, 0x28, 0x80,
+0x32, 0xac, 0x80, 0x32, 0xb1, 0x10, 0x10, 0x80, 0x32, 0xb0, 0x91, 0x10,
+0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xfd, 0x80, 0x32, 0xff,
+0x10, 0x10, 0x80, 0x32, 0xfe, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xe2,
+0x80, 0x32, 0xe4, 0x10, 0x10, 0x80, 0x32, 0xe3, 0x90, 0x88, 0x90, 0x50,
+0x90, 0x28, 0x80, 0x32, 0xc7, 0x80, 0x32, 0xc9, 0x10, 0x10, 0x80, 0x32,
+0xc8, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xa9, 0x80, 0x32, 0xab, 0x10,
+0x10, 0x80, 0x32, 0xaa, 0xe4, 0xe1, 0x4a, 0xc0, 0x35, 0x3f, 0x88, 0x02,
+0x28, 0x91, 0x10, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0x01,
+0x80, 0x33, 0x03, 0x10, 0x10, 0x80, 0x33, 0x02, 0x90, 0x50, 0x90, 0x28,
+0x80, 0x32, 0xe6, 0x80, 0x32, 0xe8, 0x10, 0x10, 0x80, 0x32, 0xe7, 0x90,
+0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xcb, 0x80, 0x32, 0xcd, 0x10,
+0x10, 0x80, 0x32, 0xcc, 0x90, 0x50, 0x90, 0x28, 0x80, 0x32, 0xad, 0x80,
+0x32, 0xaf, 0x10, 0x10, 0x80, 0x32, 0xae, 0xe4, 0xe1, 0x3b, 0x40, 0x34,
+0xf7, 0x90, 0x40, 0xe5, 0x21, 0x49, 0xc0, 0x35, 0x3b, 0xe5, 0x21, 0x3a,
+0xc0, 0x34, 0xf5, 0x9e, 0xb4, 0x20, 0xa0, 0x93, 0x70, 0x91, 0xd8, 0xd5,
+0x07, 0x80, 0xd0, 0xc4, 0x40, 0x90, 0x48, 0x80, 0x8c, 0x38, 0x08, 0x84,
+0x37, 0x0b, 0xa4, 0x35, 0xe8, 0x36, 0xd5, 0x90, 0x28, 0x24, 0x35, 0x28,
+0xa4, 0x33, 0xa8, 0x36, 0x8d, 0xd0, 0xc4, 0x40, 0x90, 0x48, 0x80, 0x8c,
+0x37, 0xe8, 0x84, 0x37, 0x09, 0xa4, 0x35, 0xd8, 0x36, 0xd3, 0x90, 0x28,
+0x24, 0x35, 0x18, 0xa4, 0x33, 0x98, 0x36, 0x8b, 0xd5, 0x06, 0x80, 0xd0,
+0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xf5, 0xa4, 0x35, 0xb8, 0x36, 0xcf,
+0x90, 0x28, 0x24, 0x34, 0xf8, 0xa4, 0x33, 0x78, 0x36, 0x87, 0xd0, 0xc3,
+0x40, 0x90, 0x28, 0x80, 0x36, 0xf1, 0xa4, 0x35, 0xa8, 0x36, 0xcd, 0x90,
+0x28, 0x24, 0x34, 0xe8, 0xa4, 0x33, 0x68, 0x36, 0x85, 0x91, 0x98, 0xd5,
+0x06, 0x80, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xe9, 0xa4, 0x35,
+0x88, 0x36, 0xc9, 0x90, 0x28, 0x24, 0x34, 0xc8, 0xa4, 0x33, 0x48, 0x36,
+0x81, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xe5, 0xa4, 0x35, 0x78,
+0x36, 0xc7, 0x90, 0x28, 0x24, 0x34, 0xb8, 0xa4, 0x33, 0x38, 0x36, 0x7f,
+0xd5, 0x06, 0x80, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xdd, 0xa4,
+0x35, 0x58, 0x36, 0xc3, 0x90, 0x28, 0x24, 0x34, 0x98, 0xa4, 0x33, 0x18,
+0x36, 0x7b, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xd9, 0xa4, 0x35,
+0x48, 0x36, 0xc1, 0x90, 0x28, 0x24, 0x34, 0x88, 0xa4, 0x33, 0x08, 0x36,
+0x79, 0x93, 0x70, 0x91, 0xd8, 0xd5, 0x07, 0x80, 0xd0, 0xc4, 0x40, 0x90,
+0x48, 0x80, 0x8c, 0x38, 0x28, 0x84, 0x37, 0x0d, 0xa4, 0x35, 0xf8, 0x36,
+0xd7, 0x90, 0x28, 0x24, 0x35, 0x38, 0xa4, 0x33, 0xb8, 0x36, 0x8f, 0xd0,
+0xc4, 0x40, 0x90, 0x48, 0x80, 0x8c, 0x37, 0xf8, 0x84, 0x37, 0x0a, 0xa4,
+0x35, 0xe0, 0x36, 0xd4, 0x90, 0x28, 0x24, 0x35, 0x20, 0xa4, 0x33, 0xa0,
+0x36, 0x8c, 0xd5, 0x06, 0x80, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36,
+0xf9, 0xa4, 0x35, 0xc8, 0x36, 0xd1, 0x90, 0x28, 0x24, 0x35, 0x08, 0xa4,
+0x33, 0x88, 0x36, 0x89, 0xd0, 0xc3, 0x40, 0x90, 0x28, 0x80, 0x36, 0xf3,
+0xa4, 0x35, 0xb0, 0x36, 0xce, 0x90, 0x28, 0x24, 0x34, 0xf0, 0xa4, 0x33,
+0x70, 0x36, 0x86, 0x91, 0x98, 0xd5, 0x06, 0x80, 0xd0, 0xc3, 0x40, 0x90,
+0x28, 0x80, 0x36, 0xed, 0xa4, 0x35, 0x98, 0x36, 0xcb, 0x90, 0x28, 0x24,
+0x34, 0xd8, 0xa4, 0x33, 0x58, 0x36, 0x83, 0xd0, 0xc3, 0x40, 0x90, 0x28,
+0x80, 0x36, 0xe7, 0xa4, 0x35, 0x80, 0x36, 0xc8, 0x90, 0x28, 0x24, 0x34,
+0xc0, 0xa4, 0x33, 0x40, 0x36, 0x80, 0xd5, 0x06, 0x80, 0xd0, 0xc3, 0x40,
+0x90, 0x28, 0x80, 0x36, 0xe1, 0xa4, 0x35, 0x68, 0x36, 0xc5, 0x90, 0x28,
+0x24, 0x34, 0xa8, 0xa4, 0x33, 0x28, 0x36, 0x7d, 0xd0, 0xc3, 0x40, 0x90,
+0x28, 0x80, 0x36, 0xdb, 0xa4, 0x35, 0x50, 0x36, 0xc2, 0x90, 0x28, 0x24,
+0x34, 0x90, 0xa4, 0x33, 0x10, 0x36, 0x7a, 0x99, 0x08, 0x01, 0xf0, 0x81,
+0x90, 0x78, 0xd4, 0xc2, 0x00, 0xa4, 0x20, 0x48, 0x34, 0x01, 0xa4, 0x1f,
+0xc8, 0x33, 0xf1, 0xd4, 0xc2, 0x00, 0xa4, 0x1f, 0xd8, 0x34, 0x03, 0xa4,
+0x1f, 0x58, 0x33, 0xf3, 0x81, 0x90, 0x78, 0xd4, 0xc2, 0x00, 0xa4, 0x1f,
+0xf8, 0x34, 0x07, 0xa4, 0x1f, 0x78, 0x33, 0xf7, 0xd4, 0xc2, 0x00, 0xa4,
+0x1f, 0xe8, 0x34, 0x05, 0xa4, 0x1f, 0x68, 0x33, 0xf5, 0xa8, 0x0b, 0x18,
+0x13, 0xa8, 0x96, 0x80, 0x93, 0x40, 0x99, 0x90, 0x03, 0x00, 0x90, 0xc0,
+0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0xb8, 0x32, 0x58, 0x24, 0x12, 0xb0,
+0x90, 0x38, 0xa4, 0x11, 0xe0, 0x32, 0x3d, 0x24, 0x11, 0xd8, 0x90, 0x60,
+0x90, 0x38, 0xa4, 0x11, 0x08, 0x32, 0x22, 0x24, 0x11, 0x00, 0x90, 0x38,
+0xa4, 0x10, 0x30, 0x32, 0x07, 0x24, 0x10, 0x28, 0x90, 0xc0, 0x90, 0x60,
+0x90, 0x38, 0xa4, 0x12, 0xa8, 0x32, 0x53, 0x24, 0x12, 0xa0, 0x90, 0x38,
+0xa4, 0x11, 0xd0, 0x32, 0x38, 0x24, 0x11, 0xc8, 0x90, 0x60, 0x90, 0x38,
+0xa4, 0x10, 0xf8, 0x32, 0x1d, 0x24, 0x10, 0xf0, 0x90, 0x38, 0xa4, 0x10,
+0x20, 0x32, 0x02, 0x24, 0x10, 0x18, 0xe4, 0xe1, 0x96, 0xc0, 0x36, 0x5d,
+0x99, 0x90, 0x03, 0x00, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12,
+0x90, 0x32, 0x50, 0x24, 0x12, 0x88, 0x90, 0x38, 0xa4, 0x11, 0xb8, 0x32,
+0x35, 0x24, 0x11, 0xb0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0xe0, 0x32,
+0x1a, 0x24, 0x10, 0xd8, 0x90, 0x38, 0xa4, 0x10, 0x08, 0x31, 0xff, 0x24,
+0x10, 0x00, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x78, 0x32,
+0x4d, 0x24, 0x12, 0x70, 0x90, 0x38, 0xa4, 0x11, 0xa0, 0x32, 0x32, 0x24,
+0x11, 0x98, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0xc8, 0x32, 0x17, 0x24,
+0x10, 0xc0, 0x90, 0x38, 0xa4, 0x0f, 0xf0, 0x31, 0xfc, 0x24, 0x0f, 0xe8,
+0xe4, 0xe1, 0x95, 0x40, 0x36, 0x57, 0x93, 0x78, 0x99, 0x90, 0x03, 0x00,
+0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x60, 0x32, 0x4a, 0x24,
+0x12, 0x58, 0x90, 0x38, 0xa4, 0x11, 0x88, 0x32, 0x2f, 0x24, 0x11, 0x80,
+0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0xb0, 0x32, 0x14, 0x24, 0x10, 0xa8,
+0x90, 0x38, 0xa4, 0x0f, 0xd8, 0x31, 0xf9, 0x24, 0x0f, 0xd0, 0x90, 0xc0,
+0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x48, 0x32, 0x47, 0x24, 0x12, 0x40,
+0x90, 0x38, 0xa4, 0x11, 0x70, 0x32, 0x2c, 0x24, 0x11, 0x68, 0x90, 0x60,
+0x90, 0x38, 0xa4, 0x10, 0x98, 0x32, 0x11, 0x24, 0x10, 0x90, 0x90, 0x38,
+0xa4, 0x0f, 0xc0, 0x31, 0xf6, 0x24, 0x0f, 0xb8, 0xec, 0xa1, 0x03, 0xc0,
+0x02, 0x00, 0x34, 0x11, 0xa4, 0x32, 0x78, 0x36, 0x51, 0x88, 0x00, 0x88,
+0x10, 0x10, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x0f, 0xa8, 0x31, 0xf3, 0x24,
+0x0f, 0xa0, 0xe9, 0x61, 0x03, 0x00, 0x02, 0x00, 0x34, 0x0d, 0xe3, 0x61,
+0x92, 0x40, 0x36, 0x4b, 0x95, 0x08, 0x93, 0x40, 0x99, 0x90, 0x03, 0x00,
+0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x30, 0x32, 0x41, 0x24,
+0x12, 0x28, 0x90, 0x38, 0xa4, 0x11, 0x58, 0x32, 0x26, 0x24, 0x11, 0x50,
+0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0x80, 0x32, 0x0b, 0x24, 0x10, 0x78,
+0x90, 0x38, 0xa4, 0x0f, 0x90, 0x31, 0xed, 0x24, 0x0f, 0x88, 0x90, 0xc0,
+0x90, 0x60, 0x90, 0x38, 0xa4, 0x12, 0x00, 0x32, 0x3e, 0x24, 0x11, 0xf8,
+0x90, 0x38, 0xa4, 0x11, 0x28, 0x32, 0x23, 0x24, 0x11, 0x20, 0x90, 0x60,
+0x90, 0x38, 0xa4, 0x10, 0x50, 0x32, 0x08, 0x24, 0x10, 0x48, 0x90, 0x38,
+0xa4, 0x0f, 0x60, 0x31, 0xea, 0x24, 0x0f, 0x58, 0xe4, 0xe1, 0x97, 0x00,
+0x36, 0x5f, 0x88, 0x01, 0x88, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4,
+0x12, 0x20, 0x32, 0x42, 0x24, 0x12, 0x18, 0x90, 0x38, 0xa4, 0x11, 0x48,
+0x32, 0x27, 0x24, 0x11, 0x40, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x10, 0x70,
+0x32, 0x0c, 0x24, 0x10, 0x68, 0x90, 0x38, 0xa4, 0x0f, 0x80, 0x31, 0xee,
+0x24, 0x0f, 0x78, 0xe4, 0xe1, 0x95, 0x80, 0x36, 0x59, 0x92, 0xd0, 0x99,
+0x50, 0x02, 0x80, 0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0xe9,
+0x24, 0x0f, 0x40, 0x90, 0x28, 0x80, 0x31, 0xe5, 0x24, 0x0f, 0x20, 0x90,
+0x50, 0x90, 0x28, 0x80, 0x31, 0xe1, 0x24, 0x0f, 0x00, 0x90, 0x28, 0x80,
+0x31, 0xdd, 0x24, 0x0e, 0xe0, 0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 0x80,
+0x31, 0xe6, 0x24, 0x0f, 0x38, 0x90, 0x28, 0x80, 0x31, 0xe2, 0x24, 0x0f,
+0x18, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0xde, 0x24, 0x0e, 0xf8, 0x90,
+0x28, 0x80, 0x31, 0xda, 0x24, 0x0e, 0xd8, 0xec, 0xe1, 0x94, 0x21, 0x04,
+0xc0, 0x36, 0x53, 0x88, 0x00, 0x78, 0x10, 0x10, 0x10, 0x10, 0x90, 0x28,
+0x80, 0x31, 0xd8, 0x24, 0x0e, 0xc8, 0xec, 0xe1, 0x92, 0xa1, 0x02, 0xc0,
+0x36, 0x4d, 0xe5, 0xa1, 0x3a, 0x40, 0x34, 0xe7, 0xa0, 0x2a, 0x10, 0xa8,
+0x16, 0x60, 0x29, 0xd8, 0xa0, 0x0c, 0x48, 0xa0, 0x0a, 0xc8, 0x95, 0x60,
+0x92, 0xb0, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31,
+0xa1, 0x80, 0x31, 0xa0, 0x10, 0x10, 0x80, 0x31, 0x9f, 0x90, 0x70, 0x90,
+0x38, 0xa4, 0x08, 0x98, 0x31, 0xb3, 0xa4, 0x08, 0x90, 0x31, 0xb2, 0x10,
+0x10, 0xa4, 0x08, 0x88, 0x31, 0xb1, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38,
+0xa4, 0x09, 0xb8, 0x31, 0xd7, 0xa4, 0x09, 0xb0, 0x31, 0xd6, 0x10, 0x10,
+0xa4, 0x09, 0xa8, 0x31, 0xd5, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09, 0x28,
+0x31, 0xc5, 0xa4, 0x09, 0x20, 0x31, 0xc4, 0x10, 0x10, 0xa4, 0x09, 0x18,
+0x31, 0xc3, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31,
+0x9c, 0x80, 0x31, 0x9e, 0x10, 0x10, 0x80, 0x31, 0x9d, 0x90, 0x70, 0x90,
+0x38, 0xa4, 0x08, 0x70, 0x31, 0xae, 0xa4, 0x08, 0x80, 0x31, 0xb0, 0x10,
+0x10, 0xa4, 0x08, 0x78, 0x31, 0xaf, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38,
+0xa4, 0x09, 0x90, 0x31, 0xd2, 0xa4, 0x09, 0xa0, 0x31, 0xd4, 0x10, 0x10,
+0xa4, 0x09, 0x98, 0x31, 0xd3, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09, 0x00,
+0x31, 0xc0, 0xa4, 0x09, 0x10, 0x31, 0xc2, 0x10, 0x10, 0xa4, 0x09, 0x08,
+0x31, 0xc1, 0x92, 0xb0, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28,
+0x80, 0x31, 0x99, 0x80, 0x31, 0x9b, 0x10, 0x10, 0x80, 0x31, 0x9a, 0x90,
+0x70, 0x90, 0x38, 0xa4, 0x08, 0x58, 0x31, 0xab, 0xa4, 0x08, 0x68, 0x31,
+0xad, 0x10, 0x10, 0xa4, 0x08, 0x60, 0x31, 0xac, 0x90, 0xb8, 0x90, 0x70,
+0x90, 0x38, 0xa4, 0x09, 0x78, 0x31, 0xcf, 0xa4, 0x09, 0x88, 0x31, 0xd1,
+0x10, 0x10, 0xa4, 0x09, 0x80, 0x31, 0xd0, 0x90, 0x70, 0x90, 0x38, 0xa4,
+0x08, 0xe8, 0x31, 0xbd, 0xa4, 0x08, 0xf8, 0x31, 0xbf, 0x10, 0x10, 0xa4,
+0x08, 0xf0, 0x31, 0xbe, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90, 0x28,
+0x80, 0x31, 0x96, 0x80, 0x31, 0x98, 0x10, 0x10, 0x80, 0x31, 0x97, 0x90,
+0x70, 0x90, 0x38, 0xa4, 0x08, 0x40, 0x31, 0xa8, 0xa4, 0x08, 0x50, 0x31,
+0xaa, 0x10, 0x10, 0xa4, 0x08, 0x48, 0x31, 0xa9, 0x90, 0xb8, 0x90, 0x70,
+0x90, 0x38, 0xa4, 0x09, 0x60, 0x31, 0xcc, 0xa4, 0x09, 0x70, 0x31, 0xce,
+0x10, 0x10, 0xa4, 0x09, 0x68, 0x31, 0xcd, 0x90, 0x70, 0x90, 0x38, 0xa4,
+0x08, 0xd0, 0x31, 0xba, 0xa4, 0x08, 0xe0, 0x31, 0xbc, 0x10, 0x10, 0xa4,
+0x08, 0xd8, 0x31, 0xbb, 0x10, 0x10, 0x90, 0xa8, 0x10, 0x10, 0x10, 0x10,
+0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x8d, 0x80, 0x31, 0x8f, 0x10, 0x10,
+0x80, 0x31, 0x8e, 0x90, 0x60, 0x90, 0x30, 0x60, 0xa0, 0x2a, 0xc0, 0x60,
+0xa0, 0x2a, 0x80, 0x90, 0x30, 0x60, 0xa0, 0x2a, 0x40, 0x60, 0xa0, 0x2a,
+0x00, 0x97, 0xf0, 0x95, 0x60, 0x92, 0xb0, 0x91, 0x40, 0x90, 0x88, 0x90,
+0x50, 0x90, 0x28, 0x80, 0x31, 0x93, 0x80, 0x31, 0x95, 0x10, 0x10, 0x80,
+0x31, 0x94, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0x28, 0x31, 0xa5, 0xa4,
+0x08, 0x38, 0x31, 0xa7, 0x10, 0x10, 0xa4, 0x08, 0x30, 0x31, 0xa6, 0x90,
+0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09, 0x48, 0x31, 0xc9, 0xa4, 0x09,
+0x58, 0x31, 0xcb, 0x10, 0x10, 0xa4, 0x09, 0x50, 0x31, 0xca, 0x90, 0x70,
+0x90, 0x38, 0xa4, 0x08, 0xb8, 0x31, 0xb7, 0xa4, 0x08, 0xc8, 0x31, 0xb9,
+0x10, 0x10, 0xa4, 0x08, 0xc0, 0x31, 0xb8, 0x91, 0x40, 0x90, 0x88, 0x90,
+0x50, 0x90, 0x28, 0x80, 0x31, 0x90, 0x80, 0x31, 0x92, 0x10, 0x10, 0x80,
+0x31, 0x91, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x08, 0x10, 0x31, 0xa2, 0xa4,
+0x08, 0x20, 0x31, 0xa4, 0x10, 0x10, 0xa4, 0x08, 0x18, 0x31, 0xa3, 0x90,
+0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x09, 0x30, 0x31, 0xc6, 0xa4, 0x09,
+0x40, 0x31, 0xc8, 0x10, 0x10, 0xa4, 0x09, 0x38, 0x31, 0xc7, 0x90, 0x70,
+0x90, 0x38, 0xa4, 0x08, 0xa0, 0x31, 0xb4, 0xa4, 0x08, 0xb0, 0x31, 0xb6,
+0x10, 0x10, 0xa4, 0x08, 0xa8, 0x31, 0xb5, 0x10, 0x10, 0x91, 0x40, 0x90,
+0xa0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0xcb, 0x80, 0x30, 0xca, 0x90,
+0x28, 0x80, 0x30, 0xc9, 0x80, 0x30, 0xc8, 0x90, 0x50, 0x90, 0x28, 0x80,
+0x30, 0xc4, 0x80, 0x30, 0xc7, 0x90, 0x28, 0x80, 0x30, 0xc6, 0x80, 0x30,
+0xc5, 0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0xbc, 0x80, 0x30,
+0xc3, 0x90, 0x28, 0x80, 0x30, 0xc2, 0x80, 0x30, 0xc1, 0x90, 0x50, 0x90,
+0x28, 0x80, 0x30, 0xbd, 0x80, 0x30, 0xc0, 0x90, 0x28, 0x80, 0x30, 0xbf,
+0x80, 0x30, 0xbe, 0x91, 0x88, 0x80, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x28,
+0x81, 0x31, 0x3b, 0x10, 0x10, 0x80, 0x31, 0x3a, 0x90, 0x28, 0x81, 0x31,
+0x3d, 0x10, 0x10, 0x80, 0x31, 0x3c, 0x90, 0x60, 0x90, 0x28, 0x81, 0x31,
+0x41, 0x10, 0x10, 0x80, 0x31, 0x40, 0x90, 0x28, 0x81, 0x31, 0x3f, 0x10,
+0x10, 0x80, 0x31, 0x3e, 0x80, 0x10, 0x10, 0x10, 0x10, 0x90, 0x28, 0x81,
+0x31, 0x38, 0x10, 0x10, 0x80, 0x31, 0x39, 0xa0, 0x0b, 0x90, 0xa0, 0x0a,
+0xc8, 0x95, 0x60, 0x92, 0xb0, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90,
+0x28, 0x80, 0x31, 0x56, 0x80, 0x31, 0x55, 0x10, 0x10, 0x80, 0x31, 0x54,
+0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0xe8, 0x31, 0x68, 0xa4, 0x06, 0xe0,
+0x31, 0x67, 0x10, 0x10, 0xa4, 0x06, 0xd8, 0x31, 0x66, 0x90, 0xb8, 0x90,
+0x70, 0x90, 0x38, 0xa4, 0x08, 0x08, 0x31, 0x8c, 0xa4, 0x08, 0x00, 0x31,
+0x8b, 0x10, 0x10, 0xa4, 0x07, 0xf8, 0x31, 0x8a, 0x90, 0x70, 0x90, 0x38,
+0xa4, 0x07, 0x78, 0x31, 0x7a, 0xa4, 0x07, 0x70, 0x31, 0x79, 0x10, 0x10,
+0xa4, 0x07, 0x68, 0x31, 0x78, 0x91, 0x40, 0x90, 0x88, 0x90, 0x50, 0x90,
+0x28, 0x80, 0x31, 0x51, 0x80, 0x31, 0x53, 0x10, 0x10, 0x80, 0x31, 0x52,
+0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0xc0, 0x31, 0x63, 0xa4, 0x06, 0xd0,
+0x31, 0x65, 0x10, 0x10, 0xa4, 0x06, 0xc8, 0x31, 0x64, 0x90, 0xb8, 0x90,
+0x70, 0x90, 0x38, 0xa4, 0x07, 0xe0, 0x31, 0x87, 0xa4, 0x07, 0xf0, 0x31,
+0x89, 0x10, 0x10, 0xa4, 0x07, 0xe8, 0x31, 0x88, 0x90, 0x70, 0x90, 0x38,
+0xa4, 0x07, 0x50, 0x31, 0x75, 0xa4, 0x07, 0x60, 0x31, 0x77, 0x10, 0x10,
+0xa4, 0x07, 0x58, 0x31, 0x76, 0x92, 0xb0, 0x91, 0x40, 0x90, 0x88, 0x90,
+0x50, 0x90, 0x28, 0x80, 0x31, 0x4e, 0x80, 0x31, 0x50, 0x10, 0x10, 0x80,
+0x31, 0x4f, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0xa8, 0x31, 0x60, 0xa4,
+0x06, 0xb8, 0x31, 0x62, 0x10, 0x10, 0xa4, 0x06, 0xb0, 0x31, 0x61, 0x90,
+0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0xc8, 0x31, 0x84, 0xa4, 0x07,
+0xd8, 0x31, 0x86, 0x10, 0x10, 0xa4, 0x07, 0xd0, 0x31, 0x85, 0x90, 0x70,
+0x90, 0x38, 0xa4, 0x07, 0x38, 0x31, 0x72, 0xa4, 0x07, 0x48, 0x31, 0x74,
+0x10, 0x10, 0xa4, 0x07, 0x40, 0x31, 0x73, 0x91, 0x40, 0x90, 0x88, 0x90,
+0x50, 0x90, 0x28, 0x80, 0x31, 0x4b, 0x80, 0x31, 0x4d, 0x10, 0x10, 0x80,
+0x31, 0x4c, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0x90, 0x31, 0x5d, 0xa4,
+0x06, 0xa0, 0x31, 0x5f, 0x10, 0x10, 0xa4, 0x06, 0x98, 0x31, 0x5e, 0x90,
+0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0xb0, 0x31, 0x81, 0xa4, 0x07,
+0xc0, 0x31, 0x83, 0x10, 0x10, 0xa4, 0x07, 0xb8, 0x31, 0x82, 0x90, 0x70,
+0x90, 0x38, 0xa4, 0x07, 0x20, 0x31, 0x6f, 0xa4, 0x07, 0x30, 0x31, 0x71,
+0x10, 0x10, 0xa4, 0x07, 0x28, 0x31, 0x70, 0x10, 0x10, 0x80, 0x10, 0x10,
+0x10, 0x10, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x42, 0x80, 0x31, 0x44,
+0x10, 0x10, 0x80, 0x31, 0x43, 0x80, 0x95, 0x60, 0x92, 0xb0, 0x91, 0x40,
+0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x48, 0x80, 0x31, 0x4a,
+0x10, 0x10, 0x80, 0x31, 0x49, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0x78,
+0x31, 0x5a, 0xa4, 0x06, 0x88, 0x31, 0x5c, 0x10, 0x10, 0xa4, 0x06, 0x80,
+0x31, 0x5b, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0x98, 0x31,
+0x7e, 0xa4, 0x07, 0xa8, 0x31, 0x80, 0x10, 0x10, 0xa4, 0x07, 0xa0, 0x31,
+0x7f, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0x08, 0x31, 0x6c, 0xa4, 0x07,
+0x18, 0x31, 0x6e, 0x10, 0x10, 0xa4, 0x07, 0x10, 0x31, 0x6d, 0x91, 0x40,
+0x90, 0x88, 0x90, 0x50, 0x90, 0x28, 0x80, 0x31, 0x45, 0x80, 0x31, 0x47,
+0x10, 0x10, 0x80, 0x31, 0x46, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0x60,
+0x31, 0x57, 0xa4, 0x06, 0x70, 0x31, 0x59, 0x10, 0x10, 0xa4, 0x06, 0x68,
+0x31, 0x58, 0x90, 0xb8, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x07, 0x80, 0x31,
+0x7b, 0xa4, 0x07, 0x90, 0x31, 0x7d, 0x10, 0x10, 0xa4, 0x07, 0x88, 0x31,
+0x7c, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x06, 0xf0, 0x31, 0x69, 0xa4, 0x07,
+0x00, 0x31, 0x6b, 0x10, 0x10, 0xa4, 0x06, 0xf8, 0x31, 0x6a, 0x10, 0x10,
+0x91, 0x40, 0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0xbb, 0x80,
+0x30, 0xba, 0x90, 0x28, 0x80, 0x30, 0xb9, 0x80, 0x30, 0xb8, 0x90, 0x50,
+0x90, 0x28, 0x80, 0x30, 0xb4, 0x80, 0x30, 0xb7, 0x90, 0x28, 0x80, 0x30,
+0xb6, 0x80, 0x30, 0xb5, 0x90, 0xa0, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30,
+0xac, 0x80, 0x30, 0xb3, 0x90, 0x28, 0x80, 0x30, 0xb2, 0x80, 0x30, 0xb1,
+0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0xad, 0x80, 0x30, 0xb0, 0x90, 0x28,
+0x80, 0x30, 0xaf, 0x80, 0x30, 0xae, 0xc3, 0xc0, 0x30, 0x42, 0x9c, 0xe8,
+0x07, 0x60, 0x91, 0x90, 0x90, 0xf0, 0x10, 0x10, 0x80, 0x88, 0x00, 0x80,
+0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0xcf, 0x80, 0x33, 0xd0, 0x81, 0x33,
+0xc6, 0xd0, 0x41, 0x80, 0x24, 0x1f, 0x48, 0x24, 0x1f, 0x50, 0x10, 0x10,
+0x80, 0x90, 0x58, 0x80, 0x90, 0x28, 0x24, 0x1e, 0x48, 0x24, 0x1e, 0x50,
+0x81, 0x24, 0x1e, 0x08, 0x92, 0x68, 0x91, 0x00, 0x80, 0x90, 0x90, 0x90,
+0x30, 0x80, 0x24, 0x1e, 0xb8, 0x90, 0x38, 0xa4, 0x1e, 0xb0, 0x33, 0xdd,
+0x80, 0x33, 0xdc, 0x80, 0x90, 0x28, 0x80, 0x33, 0xe6, 0xa4, 0x1e, 0x98,
+0x33, 0xe5, 0x80, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x28, 0x80, 0x33, 0xe0,
+0xa4, 0x1e, 0xa8, 0x33, 0xdf, 0x90, 0x28, 0x80, 0x33, 0xdb, 0xa4, 0x1e,
+0xa0, 0x33, 0xda, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33, 0xe4, 0x80, 0x33,
+0xe3, 0x90, 0x28, 0x24, 0x1f, 0x40, 0x24, 0x1f, 0x38, 0x90, 0x58, 0x80,
+0x10, 0x10, 0x80, 0x10, 0x10, 0x80, 0x33, 0xd2, 0x80, 0x90, 0x40, 0x10,
+0x10, 0x80, 0x24, 0x1e, 0x18, 0x80, 0x10, 0x10, 0x80, 0x33, 0xd1, 0x91,
+0x58, 0x91, 0x00, 0x90, 0x80, 0x81, 0x90, 0x50, 0x90, 0x28, 0x80, 0x33,
+0xcd, 0x80, 0x33, 0xce, 0x81, 0x33, 0xc5, 0x81, 0x90, 0x50, 0x90, 0x28,
+0x80, 0x33, 0xcb, 0x80, 0x33, 0xcc, 0x81, 0x33, 0xc4, 0x83, 0x90, 0x28,
+0x24, 0x1e, 0x38, 0x24, 0x1e, 0x40, 0x90, 0xe8, 0x81, 0x90, 0x88, 0x90,
+0x38, 0x10, 0x10, 0x80, 0x33, 0xde, 0x90, 0x28, 0x80, 0x33, 0xd9, 0x80,
+0x33, 0xd8, 0x80, 0x90, 0x28, 0x80, 0x33, 0xe2, 0x80, 0x33, 0xe1, 0x82,
+0x10, 0x10, 0x80, 0x24, 0x1e, 0x10, 0x97, 0x10, 0x9e, 0x10, 0x06, 0x98,
+0x93, 0x00, 0x91, 0x80, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x03,
+0x80, 0x30, 0x71, 0x24, 0x03, 0x78, 0x90, 0x38, 0xa4, 0x04, 0x10, 0x30,
+0x83, 0x24, 0x04, 0x08, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x05, 0x30, 0x30,
+0xa7, 0x24, 0x05, 0x28, 0x90, 0x38, 0xa4, 0x04, 0xa0, 0x30, 0x95, 0x24,
+0x04, 0x98, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x03, 0x70, 0x30,
+0x6c, 0x24, 0x03, 0x68, 0x90, 0x38, 0xa4, 0x04, 0x00, 0x30, 0x7e, 0x24,
+0x03, 0xf8, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x05, 0x20, 0x30, 0xa2, 0x24,
+0x05, 0x18, 0x90, 0x38, 0xa4, 0x04, 0x90, 0x30, 0x90, 0x24, 0x04, 0x88,
+0x91, 0x80, 0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x03, 0x58, 0x30,
+0x69, 0x24, 0x03, 0x50, 0x90, 0x38, 0xa4, 0x03, 0xe8, 0x30, 0x7b, 0x24,
+0x03, 0xe0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x05, 0x08, 0x30, 0x9f, 0x24,
+0x05, 0x00, 0x90, 0x38, 0xa4, 0x04, 0x78, 0x30, 0x8d, 0x24, 0x04, 0x70,
+0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x03, 0x40, 0x30, 0x66, 0x24,
+0x03, 0x38, 0x90, 0x38, 0xa4, 0x03, 0xd0, 0x30, 0x78, 0x24, 0x03, 0xc8,
+0x90, 0x60, 0x90, 0x38, 0xa4, 0x04, 0xf0, 0x30, 0x9c, 0x24, 0x04, 0xe8,
+0x90, 0x38, 0xa4, 0x04, 0x60, 0x30, 0x8a, 0x24, 0x04, 0x58, 0x10, 0x10,
+0x80, 0x10, 0x10, 0x10, 0x10, 0x90, 0x38, 0xa4, 0x02, 0xf8, 0x30, 0x5d,
+0x24, 0x02, 0xf0, 0xd7, 0x42, 0x00, 0xa4, 0x32, 0x28, 0x36, 0x47, 0xa4,
+0x32, 0x08, 0x36, 0x43, 0x9c, 0xe0, 0x06, 0x90, 0x93, 0x00, 0x91, 0x80,
+0x90, 0xc0, 0x90, 0x60, 0x90, 0x38, 0xa4, 0x03, 0x28, 0x30, 0x63, 0x24,
+0x03, 0x20, 0x90, 0x38, 0xa4, 0x03, 0xb8, 0x30, 0x75, 0x24, 0x03, 0xb0,
+0x90, 0x60, 0x90, 0x38, 0xa4, 0x04, 0xd8, 0x30, 0x99, 0x24, 0x04, 0xd0,
+0x90, 0x38, 0xa4, 0x04, 0x48, 0x30, 0x87, 0x24, 0x04, 0x40, 0x90, 0xc0,
+0x90, 0x60, 0x90, 0x38, 0xa4, 0x03, 0x10, 0x30, 0x60, 0x24, 0x03, 0x08,
+0x90, 0x38, 0xa4, 0x03, 0xa0, 0x30, 0x72, 0x24, 0x03, 0x98, 0x90, 0x60,
+0x90, 0x38, 0xa4, 0x04, 0xc0, 0x30, 0x96, 0x24, 0x04, 0xb8, 0x90, 0x38,
+0xa4, 0x04, 0x30, 0x30, 0x84, 0x24, 0x04, 0x28, 0x10, 0x10, 0x90, 0xe0,
+0x90, 0x70, 0x90, 0x38, 0xa4, 0x02, 0x88, 0x30, 0x52, 0xa4, 0x02, 0x78,
+0x30, 0x50, 0x90, 0x38, 0xa4, 0x02, 0x70, 0x30, 0x4b, 0xa4, 0x02, 0x60,
+0x30, 0x4d, 0x90, 0x70, 0x90, 0x38, 0xa4, 0x02, 0x50, 0x30, 0x43, 0xa4,
+0x02, 0x40, 0x30, 0x49, 0x90, 0x38, 0xa4, 0x02, 0x38, 0x30, 0x44, 0xa4,
+0x02, 0x28, 0x30, 0x46, 0x91, 0x48, 0x80, 0x90, 0xa0, 0x90, 0x50, 0x90,
+0x28, 0x80, 0x30, 0x56, 0x24, 0x02, 0xa8, 0x90, 0x28, 0x80, 0x30, 0x58,
+0x24, 0x02, 0xb8, 0x90, 0x50, 0x90, 0x28, 0x80, 0x30, 0x5c, 0x24, 0x02,
+0xd8, 0x90, 0x28, 0x80, 0x30, 0x5a, 0x24, 0x02, 0xc8, 0x80, 0x10, 0x10,
+0x10, 0x10, 0x90, 0x28, 0x80, 0x30, 0x53, 0x24, 0x02, 0xa0, 0xd7, 0x42,
+0x00, 0xa4, 0x32, 0x30, 0x36, 0x48, 0xa4, 0x32, 0x10, 0x36, 0x44, 0xa0,
+0x14, 0x90, 0xa0, 0x10, 0xb8, 0xa0, 0x0c, 0x88, 0x9e, 0x88, 0x09, 0xd0,
+0x94, 0xf0, 0x90, 0xb0, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 0xc9, 0xe1,
+0x31, 0xc0, 0x85, 0x34, 0xe3, 0xcb, 0x61, 0x2a, 0x80, 0x85, 0x34, 0xb9,
+0x9a, 0x00, 0x03, 0xf8, 0x91, 0x98, 0x80, 0x91, 0x10, 0x90, 0xa0, 0x90,
+0x68, 0x90, 0x20, 0x38, 0xad, 0xc9, 0xe2, 0x2a, 0xc0, 0x85, 0x34, 0xe1,
+0xa4, 0x45, 0x48, 0x38, 0xaa, 0x90, 0x38, 0xa4, 0x45, 0x10, 0x38, 0xa3,
+0xa4, 0x45, 0x00, 0x38, 0xa1, 0x90, 0x48, 0x10, 0x10, 0xa4, 0x44, 0xc8,
+0x38, 0x9a, 0x10, 0x10, 0x80, 0x38, 0x96, 0x81, 0x10, 0x10, 0x80, 0xa4,
+0x44, 0x98, 0x38, 0x94, 0x91, 0xb0, 0x91, 0x60, 0x90, 0xe0, 0x90, 0x70,
+0x90, 0x38, 0xa4, 0x45, 0x38, 0x38, 0xa8, 0xa4, 0x45, 0x28, 0x38, 0xa6,
+0x90, 0x38, 0xa4, 0x44, 0xf0, 0x38, 0x9f, 0xa4, 0x44, 0xe0, 0x38, 0x9d,
+0x90, 0x48, 0x10, 0x10, 0xa4, 0x44, 0xb8, 0x38, 0x98, 0x10, 0x10, 0x80,
+0x38, 0x95, 0x90, 0x28, 0x80, 0x38, 0x8e, 0x80, 0x38, 0x8d, 0x81, 0x10,
+0x10, 0x80, 0xa4, 0x44, 0x88, 0x38, 0x92, 0xcb, 0x61, 0x2a, 0x40, 0x85,
+0x34, 0xb8, 0x90, 0xd8, 0x88, 0x00, 0x90, 0x84, 0x90, 0x38, 0xc1, 0xc0,
+0x85, 0x38, 0xb1, 0xc9, 0xe1, 0x31, 0x80, 0x85, 0x34, 0xdf, 0xcb, 0x61,
+0x2a, 0x00, 0x85, 0x34, 0xb7, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 0xc9,
+0xe1, 0x31, 0x40, 0x85, 0x34, 0xdd, 0xcb, 0x61, 0x29, 0xc0, 0x85, 0x34,
+0xb6, 0x91, 0xf8, 0x90, 0xb0, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 0xc9,
+0xe1, 0x30, 0xc0, 0x85, 0x34, 0xd9, 0xcb, 0x61, 0x29, 0x40, 0x85, 0x34,
+0xb4, 0x88, 0x01, 0x00, 0x90, 0xa0, 0x81, 0x90, 0x70, 0x80, 0x90, 0x20,
+0x38, 0xa4, 0xc9, 0xe1, 0x30, 0x80, 0x85, 0x34, 0xd7, 0x81, 0x38, 0x9b,
+0x81, 0x10, 0x10, 0x80, 0xa4, 0x44, 0x78, 0x38, 0x90, 0xcb, 0x61, 0x29,
+0x00, 0x85, 0x34, 0xb3, 0x90, 0xb0, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10,
+0xc9, 0xe1, 0x30, 0x40, 0x85, 0x34, 0xd5, 0xcb, 0x61, 0x28, 0xc0, 0x85,
+0x34, 0xb2, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 0xc9, 0xe1, 0x30, 0x00,
+0x85, 0x34, 0xd3, 0xcb, 0x61, 0x28, 0x80, 0x85, 0x34, 0xb1, 0x92, 0x38,
+0x81, 0x91, 0x68, 0x91, 0x18, 0x90, 0x80, 0x90, 0x40, 0x80, 0xa4, 0x46,
+0x00, 0x38, 0xc1, 0x80, 0xa4, 0x45, 0xf8, 0x38, 0xbe, 0x90, 0x28, 0x81,
+0x38, 0xbd, 0x90, 0x38, 0xa4, 0x45, 0xd8, 0x38, 0xbc, 0xa4, 0x45, 0xc8,
+0x38, 0xba, 0x90, 0x28, 0x80, 0x38, 0xb8, 0x80, 0x38, 0xb7, 0x80, 0x90,
+0x40, 0x10, 0x10, 0x80, 0x24, 0x45, 0xb0, 0x10, 0x10, 0x90, 0x38, 0xa4,
+0x45, 0xa0, 0x38, 0xb5, 0xa4, 0x45, 0x90, 0x38, 0xb3, 0x90, 0x50, 0x80,
+0xc9, 0xa2, 0x2b, 0xc0, 0x85, 0x38, 0xb0, 0x80, 0x38, 0xae, 0x9a, 0xd0,
+0x03, 0xe0, 0x91, 0x60, 0x90, 0xb0, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10,
+0xc9, 0xe1, 0x2f, 0x80, 0x85, 0x34, 0xcf, 0xcb, 0x61, 0x28, 0x00, 0x85,
+0x34, 0xaf, 0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 0xc9, 0xe1, 0x2f, 0x40,
+0x85, 0x34, 0xcd, 0xcb, 0x61, 0x27, 0xc0, 0x85, 0x34, 0xae, 0x90, 0xb0,
+0x88, 0x00, 0x68, 0x84, 0x10, 0x10, 0xc9, 0xe1, 0x2f, 0x00, 0x85, 0x34,
+0xcb, 0xcb, 0x61, 0x27, 0x80, 0x85, 0x34, 0xad, 0x88, 0x00, 0x68, 0x84,
+0x10, 0x10, 0xc9, 0xe1, 0x2e, 0xc0, 0x85, 0x34, 0xc9, 0xcb, 0x61, 0x27,
+0x40, 0x85, 0x34, 0xac, 0x90, 0x90, 0x90, 0x48, 0xcb, 0xa1, 0x25, 0x80,
+0x85, 0x34, 0x9b, 0xcb, 0xa1, 0x25, 0x40, 0x85, 0x34, 0x9a, 0x90, 0x48,
+0xcb, 0xa1, 0x25, 0x00, 0x85, 0x34, 0x99, 0xcb, 0xa1, 0x24, 0xc0, 0x85,
+0x34, 0x98, 0xcb, 0xa2, 0x22, 0xc0, 0x80, 0x38, 0x8c, 0x92, 0x40, 0x91,
+0x20, 0x90, 0x90, 0x90, 0x48, 0x8c, 0x24, 0x10, 0x84, 0x24, 0x24, 0x88,
+0x8c, 0x24, 0x08, 0x84, 0x24, 0x24, 0x80, 0x90, 0x48, 0x8c, 0x24, 0x00,
+0x84, 0x24, 0x24, 0x78, 0x8c, 0x23, 0xf8, 0x84, 0x24, 0x24, 0x70, 0x90,
+0x90, 0x90, 0x48, 0x8c, 0x23, 0xe8, 0x84, 0x24, 0x24, 0x60, 0x8c, 0x23,
+0xe0, 0x84, 0x24, 0x24, 0x58, 0x90, 0x48, 0x8c, 0x23, 0xd8, 0x84, 0x24,
+0x24, 0x50, 0x8c, 0x23, 0xd0, 0x84, 0x24, 0x24, 0x48, 0x91, 0x20, 0x90,
+0x90, 0x90, 0x48, 0x8c, 0x23, 0xc0, 0x84, 0x24, 0x24, 0x38, 0x8c, 0x23,
+0xb8, 0x84, 0x24, 0x24, 0x30, 0x90, 0x48, 0x8c, 0x23, 0xb0, 0x84, 0x24,
+0x24, 0x28, 0x8c, 0x23, 0xa8, 0x84, 0x24, 0x24, 0x20, 0x90, 0x38, 0xa4,
+0x23, 0x90, 0x34, 0x73, 0xa4, 0x23, 0x80, 0x34, 0x71, 0xa0, 0x0f, 0x50,
+0xa0, 0x09, 0x08, 0x9a, 0x30, 0x04, 0x40, 0x91, 0x90, 0x90, 0xc8, 0x98,
+0x50, 0x00, 0x80, 0xe5, 0x22, 0x21, 0xc0, 0x38, 0x83, 0xe5, 0x22, 0x1d,
+0xc0, 0x38, 0x81, 0xcb, 0x61, 0x17, 0xc0, 0x85, 0x34, 0x6e, 0x98, 0x50,
+0x00, 0x80, 0xe5, 0x22, 0x19, 0xc0, 0x38, 0x63, 0xe5, 0x22, 0x15, 0xc0,
+0x38, 0x61, 0xcb, 0x61, 0x17, 0x80, 0x85, 0x34, 0x6d, 0x90, 0x48, 0xcb,
+0xa1, 0x17, 0x40, 0x85, 0x34, 0x6c, 0xcb, 0xa1, 0x17, 0x00, 0x85, 0x34,
+0x6b, 0x91, 0x90, 0x90, 0xc8, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x22, 0x0e,
+0xc0, 0x38, 0x47, 0xe5, 0x22, 0x08, 0xc0, 0x38, 0x2f, 0xcb, 0x61, 0x16,
+0x80, 0x85, 0x34, 0x69, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x22, 0x02, 0xc0,
+0x38, 0x17, 0xe5, 0x21, 0xfc, 0xc0, 0x37, 0xff, 0xcb, 0x61, 0x16, 0x40,
+0x85, 0x34, 0x68, 0x90, 0x48, 0xcb, 0xa1, 0x16, 0x00, 0x85, 0x34, 0x67,
+0xcb, 0xa1, 0x15, 0xc0, 0x85, 0x34, 0x66, 0x92, 0x20, 0x91, 0x30, 0x90,
+0xb8, 0xd5, 0x03, 0x00, 0xc0, 0xc0, 0x81, 0x8c, 0x01, 0xa0, 0x84, 0x30,
+0x3e, 0xc0, 0xc0, 0x81, 0x8c, 0x01, 0x80, 0x84, 0x30, 0x3c, 0xd5, 0x02,
+0x00, 0xc0, 0xc0, 0x81, 0x30, 0x28, 0xc0, 0xc0, 0x81, 0x30, 0x24, 0x90,
+0x78, 0xd5, 0x02, 0x00, 0xc0, 0xc0, 0x81, 0x30, 0x1c, 0xc0, 0xc0, 0x81,
+0x30, 0x18, 0xd5, 0x02, 0x00, 0xc0, 0xc0, 0x81, 0x30, 0x10, 0xc0, 0xc0,
+0x81, 0x30, 0x0c, 0x91, 0x70, 0x90, 0xd8, 0xd5, 0x03, 0x80, 0xc8, 0xe1,
+0xf8, 0xc0, 0x81, 0x8c, 0x01, 0xc0, 0x84, 0x30, 0x40, 0xc8, 0xe1, 0xf9,
+0xc0, 0x81, 0x8c, 0x01, 0x90, 0x84, 0x30, 0x3d, 0xd5, 0x02, 0x80, 0xc8,
+0xe1, 0xf8, 0x40, 0x81, 0x30, 0x2c, 0xc8, 0xe1, 0xf5, 0x40, 0x81, 0x30,
+0x26, 0x90, 0x98, 0xd5, 0x02, 0x80, 0xc8, 0xe1, 0xef, 0x40, 0x81, 0x30,
+0x20, 0xc8, 0xe1, 0xf0, 0x40, 0x81, 0x30, 0x1a, 0xd5, 0x02, 0x80, 0xc8,
+0xe1, 0xee, 0xc0, 0x81, 0x30, 0x14, 0xc8, 0xe1, 0xeb, 0xc0, 0x81, 0x30,
+0x0e, 0x9a, 0x30, 0x04, 0x40, 0x91, 0x90, 0x90, 0xc8, 0x98, 0x50, 0x00,
+0x80, 0xe5, 0x22, 0x1b, 0xc0, 0x38, 0x6b, 0xe5, 0x22, 0x1c, 0xc0, 0x38,
+0x7d, 0xcb, 0x61, 0x15, 0x40, 0x85, 0x34, 0x64, 0x98, 0x50, 0x00, 0x80,
+0xe5, 0x22, 0x13, 0xc0, 0x38, 0x4b, 0xe5, 0x22, 0x14, 0xc0, 0x38, 0x5d,
+0xcb, 0x61, 0x15, 0x00, 0x85, 0x34, 0x63, 0x90, 0x48, 0xcb, 0xa1, 0x14,
+0xc0, 0x85, 0x34, 0x62, 0xcb, 0xa1, 0x14, 0x80, 0x85, 0x34, 0x61, 0x91,
+0x90, 0x90, 0xc8, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x22, 0x0c, 0xc0, 0x38,
+0x3f, 0xe5, 0x22, 0x06, 0xc0, 0x38, 0x27, 0xcb, 0x61, 0x12, 0xc0, 0x85,
+0x34, 0x50, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x22, 0x00, 0xc0, 0x38, 0x0f,
+0xe5, 0x21, 0xfa, 0xc0, 0x37, 0xf7, 0xcb, 0x61, 0x12, 0x80, 0x85, 0x34,
+0x4f, 0x90, 0x48, 0xcb, 0xa1, 0x12, 0x40, 0x85, 0x34, 0x4e, 0xcb, 0xa1,
+0x12, 0x00, 0x85, 0x34, 0x4d, 0x91, 0x00, 0x90, 0x80, 0x90, 0x40, 0xe5,
+0x20, 0x02, 0x40, 0x30, 0x0a, 0xe5, 0x20, 0x01, 0x80, 0x30, 0x07, 0x90,
+0x40, 0xe5, 0x20, 0x00, 0xc0, 0x30, 0x04, 0xe5, 0x20, 0x00, 0x00, 0x30,
+0x01, 0x90, 0x80, 0x90, 0x40, 0xe5, 0x21, 0xf2, 0xc0, 0x37, 0xc5, 0xe5,
+0x21, 0xf4, 0x00, 0x37, 0xdb, 0x90, 0x40, 0xe5, 0x21, 0xe9, 0x40, 0x37,
+0x9f, 0xe5, 0x21, 0xea, 0x80, 0x37, 0xb5, 0x80, 0x99, 0x28, 0x02, 0xf0,
+0x8c, 0x21, 0xf8, 0x90, 0x80, 0x90, 0x40, 0xe5, 0x22, 0x1e, 0xc0, 0x38,
+0x79, 0xe5, 0x22, 0x1d, 0x40, 0x38, 0x7f, 0x90, 0x40, 0xe5, 0x22, 0x16,
+0xc0, 0x38, 0x59, 0xe5, 0x22, 0x15, 0x40, 0x38, 0x5f, 0x91, 0x48, 0x90,
+0xc8, 0x98, 0x50, 0x00, 0x80, 0xe5, 0x22, 0x0d, 0xc0, 0x38, 0x43, 0xe5,
+0x22, 0x07, 0xc0, 0x38, 0x2b, 0xcb, 0x61, 0x10, 0x80, 0x85, 0x34, 0x46,
+0x90, 0x40, 0xe5, 0x22, 0x01, 0xc0, 0x38, 0x13, 0xe5, 0x21, 0xfb, 0xc0,
+0x37, 0xfb, 0x90, 0x48, 0xcb, 0xa1, 0x10, 0x00, 0x85, 0x34, 0x44, 0xcb,
+0xa1, 0x10, 0x40, 0x85, 0x34, 0x45, 0x10, 0x10, 0x90, 0x80, 0x90, 0x40,
+0xe5, 0x21, 0xf6, 0x40, 0x37, 0xd7, 0xe5, 0x21, 0xf4, 0xc0, 0x37, 0xdf,
+0x90, 0x40, 0xe5, 0x21, 0xec, 0xc0, 0x37, 0xb1, 0xe5, 0x21, 0xeb, 0x40,
+0x37, 0xb9,
};
static const struct ia64_dis_names ia64_dis_names[] = {
-{ 0x51, 40, 0, 9 },
-{ 0x31, 40, 1, 19 },
-{ 0x11, 41, 0, 18 },
-{ 0x29, 40, 0, 11 },
-{ 0x19, 40, 1, 23 },
-{ 0x9, 41, 0, 22 },
-{ 0x15, 40, 0, 13 },
-{ 0xd, 40, 1, 27 },
-{ 0x5, 41, 0, 26 },
-{ 0xb, 40, 0, 15 },
-{ 0x7, 40, 1, 31 },
-{ 0x3, 41, 0, 30 },
-{ 0x51, 38, 1, 57 },
-{ 0x50, 38, 0, 33 },
-{ 0xd1, 38, 1, 56 },
-{ 0xd0, 38, 0, 32 },
-{ 0x31, 38, 1, 67 },
-{ 0x30, 38, 1, 43 },
-{ 0x11, 39, 1, 66 },
-{ 0x10, 39, 0, 42 },
-{ 0x71, 38, 1, 65 },
-{ 0x70, 38, 1, 41 },
-{ 0x31, 39, 1, 64 },
-{ 0x30, 39, 0, 40 },
-{ 0x29, 38, 1, 59 },
-{ 0x28, 38, 0, 35 },
-{ 0x69, 38, 1, 58 },
-{ 0x68, 38, 0, 34 },
-{ 0x19, 38, 1, 71 },
-{ 0x18, 38, 1, 47 },
-{ 0x9, 39, 1, 70 },
-{ 0x8, 39, 0, 46 },
-{ 0x39, 38, 1, 69 },
-{ 0x38, 38, 1, 45 },
-{ 0x19, 39, 1, 68 },
-{ 0x18, 39, 0, 44 },
-{ 0x15, 38, 1, 61 },
-{ 0x14, 38, 0, 37 },
-{ 0x35, 38, 1, 60 },
-{ 0x34, 38, 0, 36 },
-{ 0xd, 38, 1, 75 },
-{ 0xc, 38, 1, 51 },
-{ 0x5, 39, 1, 74 },
-{ 0x4, 39, 0, 50 },
-{ 0x1d, 38, 1, 73 },
-{ 0x1c, 38, 1, 49 },
-{ 0xd, 39, 1, 72 },
-{ 0xc, 39, 0, 48 },
-{ 0xb, 38, 1, 63 },
-{ 0xa, 38, 0, 39 },
-{ 0x1b, 38, 1, 62 },
-{ 0x1a, 38, 0, 38 },
-{ 0x7, 38, 1, 79 },
-{ 0x6, 38, 1, 55 },
-{ 0x3, 39, 1, 78 },
-{ 0x2, 39, 0, 54 },
-{ 0xf, 38, 1, 77 },
-{ 0xe, 38, 1, 53 },
-{ 0x7, 39, 1, 76 },
-{ 0x6, 39, 0, 52 },
-{ 0x8, 37, 0, 81 },
-{ 0x18, 37, 0, 80 },
-{ 0x1, 37, 1, 85 },
-{ 0x2, 37, 0, 84 },
-{ 0x3, 37, 1, 83 },
-{ 0x4, 37, 0, 82 },
-{ 0x1, 284, 0, 86 },
-{ 0x20, 237, 0, 96 },
-{ 0x220, 237, 0, 92 },
-{ 0x1220, 237, 0, 89 },
-{ 0xa20, 237, 0, 90 },
-{ 0x620, 237, 0, 91 },
-{ 0x120, 237, 0, 93 },
-{ 0xa0, 237, 0, 94 },
-{ 0x60, 237, 0, 95 },
-{ 0x10, 237, 0, 100 },
-{ 0x90, 237, 0, 97 },
-{ 0x50, 237, 0, 98 },
-{ 0x30, 237, 0, 99 },
-{ 0x8, 237, 0, 101 },
-{ 0x4, 237, 0, 102 },
-{ 0x2, 237, 0, 103 },
-{ 0x1, 237, 0, 104 },
-{ 0x1, 357, 0, 106 },
-{ 0x3, 357, 0, 105 },
-{ 0x2, 363, 0, 107 },
-{ 0x1, 363, 0, 108 },
-{ 0x2, 359, 0, 109 },
-{ 0x1, 359, 0, 110 },
-{ 0x2, 361, 0, 111 },
-{ 0x1, 361, 0, 112 },
-{ 0x2, 365, 0, 113 },
-{ 0x1, 365, 0, 114 },
-{ 0x1, 216, 0, 141 },
-{ 0x5, 216, 0, 139 },
-{ 0x3, 216, 0, 140 },
-{ 0x140, 225, 0, 117 },
-{ 0x540, 225, 0, 115 },
-{ 0x340, 225, 0, 116 },
-{ 0xc0, 225, 0, 129 },
-{ 0x2c0, 225, 0, 127 },
-{ 0x1c0, 225, 0, 128 },
-{ 0x20, 225, 0, 144 },
-{ 0xa0, 225, 0, 142 },
-{ 0x60, 225, 0, 143 },
-{ 0x10, 225, 0, 156 },
-{ 0x50, 225, 0, 154 },
-{ 0x30, 225, 0, 155 },
-{ 0x8, 225, 0, 168 },
-{ 0x28, 225, 0, 166 },
-{ 0x18, 225, 0, 167 },
-{ 0x4, 225, 0, 178 },
-{ 0x2, 225, 0, 179 },
-{ 0x1, 225, 0, 180 },
-{ 0x140, 219, 0, 120 },
-{ 0x540, 219, 0, 118 },
-{ 0x340, 219, 0, 119 },
-{ 0xc0, 219, 0, 132 },
-{ 0x2c0, 219, 0, 130 },
-{ 0x1c0, 219, 0, 131 },
-{ 0x20, 219, 0, 147 },
-{ 0xa0, 219, 0, 145 },
-{ 0x60, 219, 0, 146 },
-{ 0x10, 219, 0, 159 },
-{ 0x50, 219, 0, 157 },
-{ 0x30, 219, 0, 158 },
-{ 0x8, 219, 0, 171 },
-{ 0x28, 219, 0, 169 },
-{ 0x18, 219, 0, 170 },
-{ 0x4, 219, 0, 181 },
-{ 0x2, 219, 0, 182 },
-{ 0x1, 219, 0, 183 },
-{ 0x140, 222, 0, 123 },
-{ 0x540, 222, 0, 121 },
-{ 0x340, 222, 0, 122 },
-{ 0xc0, 222, 0, 135 },
-{ 0x2c0, 222, 0, 133 },
-{ 0x1c0, 222, 0, 134 },
-{ 0x20, 222, 0, 150 },
-{ 0xa0, 222, 0, 148 },
-{ 0x60, 222, 0, 149 },
-{ 0x10, 222, 0, 162 },
-{ 0x50, 222, 0, 160 },
-{ 0x30, 222, 0, 161 },
-{ 0x8, 222, 0, 174 },
-{ 0x28, 222, 0, 172 },
-{ 0x18, 222, 0, 173 },
-{ 0x4, 222, 0, 184 },
-{ 0x2, 222, 0, 185 },
-{ 0x1, 222, 0, 186 },
-{ 0x140, 234, 0, 126 },
-{ 0x540, 234, 0, 124 },
-{ 0x340, 234, 0, 125 },
-{ 0xc0, 234, 0, 138 },
-{ 0x2c0, 234, 0, 136 },
-{ 0x1c0, 234, 0, 137 },
-{ 0x20, 234, 0, 153 },
-{ 0xa0, 234, 0, 151 },
-{ 0x60, 234, 0, 152 },
-{ 0x10, 234, 0, 165 },
-{ 0x50, 234, 0, 163 },
-{ 0x30, 234, 0, 164 },
-{ 0x8, 234, 0, 177 },
-{ 0x28, 234, 0, 175 },
-{ 0x18, 234, 0, 176 },
-{ 0x4, 234, 0, 187 },
-{ 0x2, 234, 0, 188 },
-{ 0x1, 234, 0, 189 },
-{ 0x8, 338, 0, 190 },
-{ 0x4, 338, 0, 191 },
-{ 0x2, 338, 0, 192 },
-{ 0x1, 338, 0, 193 },
-{ 0x20, 236, 0, 201 },
-{ 0x220, 236, 0, 197 },
-{ 0x1220, 236, 0, 194 },
-{ 0xa20, 236, 0, 195 },
-{ 0x620, 236, 0, 196 },
-{ 0x120, 236, 0, 198 },
-{ 0xa0, 236, 0, 199 },
-{ 0x60, 236, 0, 200 },
-{ 0x10, 236, 0, 205 },
-{ 0x90, 236, 0, 202 },
-{ 0x50, 236, 0, 203 },
-{ 0x30, 236, 0, 204 },
-{ 0x8, 236, 0, 206 },
-{ 0x4, 236, 0, 207 },
-{ 0x2, 236, 0, 208 },
-{ 0x1, 236, 0, 209 },
-{ 0x20, 235, 0, 217 },
-{ 0x220, 235, 0, 213 },
-{ 0x1220, 235, 0, 210 },
-{ 0xa20, 235, 0, 211 },
-{ 0x620, 235, 0, 212 },
-{ 0x120, 235, 0, 214 },
-{ 0xa0, 235, 0, 215 },
-{ 0x60, 235, 0, 216 },
-{ 0x10, 235, 0, 221 },
-{ 0x90, 235, 0, 218 },
-{ 0x50, 235, 0, 219 },
-{ 0x30, 235, 0, 220 },
-{ 0x8, 235, 0, 222 },
-{ 0x4, 235, 0, 223 },
-{ 0x2, 235, 0, 224 },
-{ 0x1, 235, 0, 225 },
-{ 0x140, 227, 0, 228 },
-{ 0x540, 227, 0, 226 },
-{ 0x340, 227, 0, 227 },
-{ 0xc0, 227, 0, 237 },
-{ 0x2c0, 227, 0, 235 },
-{ 0x1c0, 227, 0, 236 },
-{ 0x20, 227, 0, 246 },
-{ 0xa0, 227, 0, 244 },
-{ 0x60, 227, 0, 245 },
-{ 0x10, 227, 0, 255 },
-{ 0x50, 227, 0, 253 },
-{ 0x30, 227, 0, 254 },
-{ 0x8, 227, 0, 264 },
-{ 0x28, 227, 0, 262 },
-{ 0x18, 227, 0, 263 },
-{ 0x4, 227, 0, 271 },
-{ 0x2, 227, 0, 272 },
-{ 0x1, 227, 0, 273 },
-{ 0x140, 229, 0, 231 },
-{ 0x540, 229, 0, 229 },
-{ 0x340, 229, 0, 230 },
-{ 0xc0, 229, 0, 240 },
-{ 0x2c0, 229, 0, 238 },
-{ 0x1c0, 229, 0, 239 },
-{ 0x20, 229, 0, 249 },
-{ 0xa0, 229, 0, 247 },
-{ 0x60, 229, 0, 248 },
-{ 0x10, 229, 0, 258 },
-{ 0x50, 229, 0, 256 },
-{ 0x30, 229, 0, 257 },
-{ 0x8, 229, 0, 267 },
-{ 0x28, 229, 0, 265 },
-{ 0x18, 229, 0, 266 },
-{ 0x4, 229, 0, 274 },
-{ 0x2, 229, 0, 275 },
-{ 0x1, 229, 0, 276 },
-{ 0x140, 231, 0, 234 },
-{ 0x540, 231, 0, 232 },
-{ 0x340, 231, 0, 233 },
-{ 0xc0, 231, 0, 243 },
-{ 0x2c0, 231, 0, 241 },
-{ 0x1c0, 231, 0, 242 },
-{ 0x20, 231, 0, 252 },
-{ 0xa0, 231, 0, 250 },
-{ 0x60, 231, 0, 251 },
-{ 0x10, 231, 0, 261 },
-{ 0x50, 231, 0, 259 },
-{ 0x30, 231, 0, 260 },
-{ 0x8, 231, 0, 270 },
-{ 0x28, 231, 0, 268 },
-{ 0x18, 231, 0, 269 },
-{ 0x4, 231, 0, 277 },
-{ 0x2, 231, 0, 278 },
-{ 0x1, 231, 0, 279 },
-{ 0x140, 226, 0, 282 },
-{ 0x540, 226, 0, 280 },
-{ 0x340, 226, 0, 281 },
-{ 0xc0, 226, 0, 291 },
-{ 0x2c0, 226, 0, 289 },
-{ 0x1c0, 226, 0, 290 },
-{ 0x20, 226, 0, 300 },
-{ 0xa0, 226, 0, 298 },
-{ 0x60, 226, 0, 299 },
-{ 0x10, 226, 0, 309 },
-{ 0x50, 226, 0, 307 },
-{ 0x30, 226, 0, 308 },
-{ 0x8, 226, 0, 318 },
-{ 0x28, 226, 0, 316 },
-{ 0x18, 226, 0, 317 },
-{ 0x4, 226, 0, 325 },
-{ 0x2, 226, 0, 326 },
-{ 0x1, 226, 0, 327 },
-{ 0x140, 228, 0, 285 },
-{ 0x540, 228, 0, 283 },
-{ 0x340, 228, 0, 284 },
-{ 0xc0, 228, 0, 294 },
-{ 0x2c0, 228, 0, 292 },
-{ 0x1c0, 228, 0, 293 },
-{ 0x20, 228, 0, 303 },
-{ 0xa0, 228, 0, 301 },
-{ 0x60, 228, 0, 302 },
-{ 0x10, 228, 0, 312 },
-{ 0x50, 228, 0, 310 },
-{ 0x30, 228, 0, 311 },
-{ 0x8, 228, 0, 321 },
-{ 0x28, 228, 0, 319 },
-{ 0x18, 228, 0, 320 },
-{ 0x4, 228, 0, 328 },
-{ 0x2, 228, 0, 329 },
-{ 0x1, 228, 0, 330 },
-{ 0x140, 230, 0, 288 },
-{ 0x540, 230, 0, 286 },
-{ 0x340, 230, 0, 287 },
-{ 0xc0, 230, 0, 297 },
-{ 0x2c0, 230, 0, 295 },
-{ 0x1c0, 230, 0, 296 },
-{ 0x20, 230, 0, 306 },
-{ 0xa0, 230, 0, 304 },
-{ 0x60, 230, 0, 305 },
-{ 0x10, 230, 0, 315 },
-{ 0x50, 230, 0, 313 },
-{ 0x30, 230, 0, 314 },
-{ 0x8, 230, 0, 324 },
-{ 0x28, 230, 0, 322 },
-{ 0x18, 230, 0, 323 },
-{ 0x4, 230, 0, 331 },
-{ 0x2, 230, 0, 332 },
-{ 0x1, 230, 0, 333 },
-{ 0x1, 356, 0, 335 },
-{ 0x3, 356, 0, 334 },
-{ 0x2, 362, 0, 336 },
-{ 0x1, 362, 0, 337 },
-{ 0x2, 358, 0, 338 },
-{ 0x1, 358, 0, 339 },
-{ 0x2, 360, 0, 340 },
-{ 0x1, 360, 0, 341 },
-{ 0x2, 364, 0, 342 },
-{ 0x1, 364, 0, 343 },
-{ 0x1, 215, 0, 370 },
-{ 0x5, 215, 0, 368 },
-{ 0x3, 215, 0, 369 },
-{ 0x140, 224, 0, 346 },
-{ 0x540, 224, 0, 344 },
-{ 0x340, 224, 0, 345 },
-{ 0xc0, 224, 0, 358 },
-{ 0x2c0, 224, 0, 356 },
-{ 0x1c0, 224, 0, 357 },
-{ 0x20, 224, 0, 373 },
-{ 0xa0, 224, 0, 371 },
-{ 0x60, 224, 0, 372 },
-{ 0x10, 224, 0, 385 },
-{ 0x50, 224, 0, 383 },
-{ 0x30, 224, 0, 384 },
-{ 0x8, 224, 0, 397 },
-{ 0x28, 224, 0, 395 },
-{ 0x18, 224, 0, 396 },
-{ 0x4, 224, 0, 407 },
-{ 0x2, 224, 0, 408 },
-{ 0x1, 224, 0, 409 },
-{ 0x140, 218, 0, 349 },
-{ 0x540, 218, 0, 347 },
-{ 0x340, 218, 0, 348 },
-{ 0xc0, 218, 0, 361 },
-{ 0x2c0, 218, 0, 359 },
-{ 0x1c0, 218, 0, 360 },
-{ 0x20, 218, 0, 376 },
-{ 0xa0, 218, 0, 374 },
-{ 0x60, 218, 0, 375 },
-{ 0x10, 218, 0, 388 },
-{ 0x50, 218, 0, 386 },
-{ 0x30, 218, 0, 387 },
-{ 0x8, 218, 0, 400 },
-{ 0x28, 218, 0, 398 },
-{ 0x18, 218, 0, 399 },
-{ 0x4, 218, 0, 410 },
-{ 0x2, 218, 0, 411 },
-{ 0x1, 218, 0, 412 },
-{ 0x140, 221, 0, 352 },
-{ 0x540, 221, 0, 350 },
-{ 0x340, 221, 0, 351 },
-{ 0xc0, 221, 0, 364 },
-{ 0x2c0, 221, 0, 362 },
-{ 0x1c0, 221, 0, 363 },
-{ 0x20, 221, 0, 379 },
-{ 0xa0, 221, 0, 377 },
-{ 0x60, 221, 0, 378 },
-{ 0x10, 221, 0, 391 },
-{ 0x50, 221, 0, 389 },
-{ 0x30, 221, 0, 390 },
-{ 0x8, 221, 0, 403 },
-{ 0x28, 221, 0, 401 },
-{ 0x18, 221, 0, 402 },
-{ 0x4, 221, 0, 413 },
-{ 0x2, 221, 0, 414 },
-{ 0x1, 221, 0, 415 },
-{ 0x140, 233, 0, 355 },
-{ 0x540, 233, 0, 353 },
-{ 0x340, 233, 0, 354 },
-{ 0xc0, 233, 0, 367 },
-{ 0x2c0, 233, 0, 365 },
-{ 0x1c0, 233, 0, 366 },
-{ 0x20, 233, 0, 382 },
-{ 0xa0, 233, 0, 380 },
-{ 0x60, 233, 0, 381 },
-{ 0x10, 233, 0, 394 },
-{ 0x50, 233, 0, 392 },
-{ 0x30, 233, 0, 393 },
-{ 0x8, 233, 0, 406 },
-{ 0x28, 233, 0, 404 },
-{ 0x18, 233, 0, 405 },
-{ 0x4, 233, 0, 416 },
-{ 0x2, 233, 0, 417 },
-{ 0x1, 233, 0, 418 },
-{ 0x1, 214, 0, 445 },
-{ 0x5, 214, 0, 443 },
-{ 0x3, 214, 0, 444 },
-{ 0x140, 223, 0, 421 },
-{ 0x540, 223, 0, 419 },
-{ 0x340, 223, 0, 420 },
-{ 0xc0, 223, 0, 433 },
-{ 0x2c0, 223, 0, 431 },
-{ 0x1c0, 223, 0, 432 },
-{ 0x20, 223, 0, 448 },
-{ 0xa0, 223, 0, 446 },
-{ 0x60, 223, 0, 447 },
-{ 0x10, 223, 0, 460 },
-{ 0x50, 223, 0, 458 },
-{ 0x30, 223, 0, 459 },
-{ 0x8, 223, 0, 472 },
-{ 0x28, 223, 0, 470 },
-{ 0x18, 223, 0, 471 },
-{ 0x4, 223, 0, 482 },
-{ 0x2, 223, 0, 483 },
-{ 0x1, 223, 0, 484 },
-{ 0x140, 217, 0, 424 },
-{ 0x540, 217, 0, 422 },
-{ 0x340, 217, 0, 423 },
-{ 0xc0, 217, 0, 436 },
-{ 0x2c0, 217, 0, 434 },
-{ 0x1c0, 217, 0, 435 },
-{ 0x20, 217, 0, 451 },
-{ 0xa0, 217, 0, 449 },
-{ 0x60, 217, 0, 450 },
-{ 0x10, 217, 0, 463 },
-{ 0x50, 217, 0, 461 },
-{ 0x30, 217, 0, 462 },
-{ 0x8, 217, 0, 475 },
-{ 0x28, 217, 0, 473 },
-{ 0x18, 217, 0, 474 },
-{ 0x4, 217, 0, 485 },
-{ 0x2, 217, 0, 486 },
-{ 0x1, 217, 0, 487 },
-{ 0x140, 220, 0, 427 },
-{ 0x540, 220, 0, 425 },
-{ 0x340, 220, 0, 426 },
-{ 0xc0, 220, 0, 439 },
-{ 0x2c0, 220, 0, 437 },
-{ 0x1c0, 220, 0, 438 },
-{ 0x20, 220, 0, 454 },
-{ 0xa0, 220, 0, 452 },
-{ 0x60, 220, 0, 453 },
-{ 0x10, 220, 0, 466 },
-{ 0x50, 220, 0, 464 },
-{ 0x30, 220, 0, 465 },
-{ 0x8, 220, 0, 478 },
-{ 0x28, 220, 0, 476 },
-{ 0x18, 220, 0, 477 },
-{ 0x4, 220, 0, 488 },
-{ 0x2, 220, 0, 489 },
-{ 0x1, 220, 0, 490 },
-{ 0x140, 232, 0, 430 },
-{ 0x540, 232, 0, 428 },
-{ 0x340, 232, 0, 429 },
-{ 0xc0, 232, 0, 442 },
-{ 0x2c0, 232, 0, 440 },
-{ 0x1c0, 232, 0, 441 },
-{ 0x20, 232, 0, 457 },
-{ 0xa0, 232, 0, 455 },
-{ 0x60, 232, 0, 456 },
-{ 0x10, 232, 0, 469 },
-{ 0x50, 232, 0, 467 },
-{ 0x30, 232, 0, 468 },
-{ 0x8, 232, 0, 481 },
-{ 0x28, 232, 0, 479 },
-{ 0x18, 232, 0, 480 },
-{ 0x4, 232, 0, 491 },
-{ 0x2, 232, 0, 492 },
-{ 0x1, 232, 0, 493 },
-{ 0x8, 355, 0, 495 },
-{ 0x18, 355, 0, 494 },
-{ 0x4, 355, 0, 497 },
-{ 0xc, 355, 0, 496 },
-{ 0x2, 355, 0, 504 },
-{ 0x1, 355, 0, 505 },
-{ 0x4, 353, 0, 499 },
-{ 0xc, 353, 0, 498 },
-{ 0x2, 353, 0, 506 },
-{ 0x1, 353, 0, 507 },
-{ 0x4, 351, 0, 501 },
-{ 0xc, 351, 0, 500 },
-{ 0x2, 351, 0, 508 },
-{ 0x1, 351, 0, 509 },
-{ 0x4, 349, 0, 503 },
-{ 0xc, 349, 0, 502 },
-{ 0x2, 349, 0, 510 },
-{ 0x1, 349, 0, 511 },
-{ 0xa00, 213, 0, 526 },
-{ 0x2a00, 213, 0, 524 },
-{ 0x1a00, 213, 0, 525 },
-{ 0x600, 213, 0, 538 },
-{ 0x2600, 213, 0, 514 },
-{ 0xa600, 213, 0, 512 },
-{ 0x6600, 213, 0, 513 },
-{ 0x1600, 213, 0, 536 },
-{ 0xe00, 213, 0, 537 },
-{ 0x100, 213, 0, 550 },
-{ 0x500, 213, 0, 548 },
-{ 0x300, 213, 0, 549 },
-{ 0x80, 213, 0, 553 },
-{ 0x280, 213, 0, 551 },
-{ 0x180, 213, 0, 552 },
-{ 0x40, 213, 0, 565 },
-{ 0x140, 213, 0, 563 },
-{ 0xc0, 213, 0, 564 },
-{ 0x20, 213, 0, 577 },
-{ 0xa0, 213, 0, 575 },
-{ 0x60, 213, 0, 576 },
-{ 0x10, 213, 0, 589 },
-{ 0x50, 213, 0, 587 },
-{ 0x30, 213, 0, 588 },
-{ 0x8, 213, 0, 601 },
-{ 0x28, 213, 0, 599 },
-{ 0x18, 213, 0, 600 },
-{ 0x4, 213, 0, 611 },
-{ 0x2, 213, 0, 612 },
-{ 0x1, 213, 0, 613 },
-{ 0x500, 210, 0, 529 },
-{ 0x1500, 210, 0, 527 },
-{ 0xd00, 210, 0, 528 },
-{ 0x300, 210, 0, 541 },
-{ 0x1300, 210, 0, 517 },
-{ 0x5300, 210, 0, 515 },
-{ 0x3300, 210, 0, 516 },
-{ 0xb00, 210, 0, 539 },
-{ 0x700, 210, 0, 540 },
-{ 0x80, 210, 0, 556 },
-{ 0x280, 210, 0, 554 },
-{ 0x180, 210, 0, 555 },
-{ 0x40, 210, 0, 568 },
-{ 0x140, 210, 0, 566 },
-{ 0xc0, 210, 0, 567 },
-{ 0x20, 210, 0, 580 },
-{ 0xa0, 210, 0, 578 },
-{ 0x60, 210, 0, 579 },
-{ 0x10, 210, 0, 592 },
-{ 0x50, 210, 0, 590 },
-{ 0x30, 210, 0, 591 },
-{ 0x8, 210, 0, 604 },
-{ 0x28, 210, 0, 602 },
-{ 0x18, 210, 0, 603 },
-{ 0x4, 210, 0, 614 },
-{ 0x2, 210, 0, 615 },
-{ 0x1, 210, 0, 616 },
-{ 0x500, 207, 0, 532 },
-{ 0x1500, 207, 0, 530 },
-{ 0xd00, 207, 0, 531 },
-{ 0x300, 207, 0, 544 },
-{ 0x1300, 207, 0, 520 },
-{ 0x5300, 207, 0, 518 },
-{ 0x3300, 207, 0, 519 },
-{ 0xb00, 207, 0, 542 },
-{ 0x700, 207, 0, 543 },
-{ 0x80, 207, 0, 559 },
-{ 0x280, 207, 0, 557 },
-{ 0x180, 207, 0, 558 },
-{ 0x40, 207, 0, 571 },
-{ 0x140, 207, 0, 569 },
-{ 0xc0, 207, 0, 570 },
-{ 0x20, 207, 0, 583 },
-{ 0xa0, 207, 0, 581 },
-{ 0x60, 207, 0, 582 },
-{ 0x10, 207, 0, 595 },
-{ 0x50, 207, 0, 593 },
-{ 0x30, 207, 0, 594 },
-{ 0x8, 207, 0, 607 },
-{ 0x28, 207, 0, 605 },
-{ 0x18, 207, 0, 606 },
-{ 0x4, 207, 0, 617 },
-{ 0x2, 207, 0, 618 },
-{ 0x1, 207, 0, 619 },
-{ 0x500, 204, 0, 535 },
-{ 0x1500, 204, 0, 533 },
-{ 0xd00, 204, 0, 534 },
-{ 0x300, 204, 0, 547 },
-{ 0x1300, 204, 0, 523 },
-{ 0x5300, 204, 0, 521 },
-{ 0x3300, 204, 0, 522 },
-{ 0xb00, 204, 0, 545 },
-{ 0x700, 204, 0, 546 },
-{ 0x80, 204, 0, 562 },
-{ 0x280, 204, 0, 560 },
-{ 0x180, 204, 0, 561 },
-{ 0x40, 204, 0, 574 },
-{ 0x140, 204, 0, 572 },
-{ 0xc0, 204, 0, 573 },
-{ 0x20, 204, 0, 586 },
-{ 0xa0, 204, 0, 584 },
-{ 0x60, 204, 0, 585 },
-{ 0x10, 204, 0, 598 },
-{ 0x50, 204, 0, 596 },
-{ 0x30, 204, 0, 597 },
-{ 0x8, 204, 0, 610 },
-{ 0x28, 204, 0, 608 },
-{ 0x18, 204, 0, 609 },
-{ 0x4, 204, 0, 620 },
-{ 0x2, 204, 0, 621 },
-{ 0x1, 204, 0, 622 },
-{ 0x8, 195, 0, 623 },
-{ 0x4, 195, 0, 624 },
-{ 0x2, 195, 0, 625 },
-{ 0x1, 195, 0, 626 },
-{ 0x2, 133, 0, 629 },
-{ 0xa, 133, 0, 627 },
-{ 0x6, 133, 0, 628 },
-{ 0x1, 133, 0, 635 },
-{ 0x5, 133, 0, 633 },
-{ 0x3, 133, 0, 634 },
-{ 0x2, 132, 0, 632 },
-{ 0xa, 132, 0, 630 },
-{ 0x6, 132, 0, 631 },
-{ 0x1, 132, 0, 638 },
-{ 0x5, 132, 0, 636 },
-{ 0x3, 132, 0, 637 },
-{ 0x4, 388, 0, 639 },
-{ 0x2, 388, 0, 640 },
-{ 0x1, 388, 0, 641 },
-{ 0x4, 387, 0, 642 },
-{ 0x2, 387, 0, 643 },
-{ 0x1, 387, 0, 644 },
-{ 0x4, 386, 0, 645 },
-{ 0x2, 386, 0, 646 },
-{ 0x1, 386, 0, 647 },
-{ 0x4, 385, 0, 648 },
-{ 0x2, 385, 0, 649 },
-{ 0x1, 385, 0, 650 },
-{ 0x2, 95, 0, 653 },
-{ 0xa, 95, 0, 651 },
-{ 0x6, 95, 0, 652 },
-{ 0x1, 95, 0, 665 },
-{ 0x5, 95, 0, 663 },
-{ 0x3, 95, 0, 664 },
-{ 0x2, 94, 0, 656 },
-{ 0xa, 94, 0, 654 },
-{ 0x6, 94, 0, 655 },
-{ 0x1, 94, 0, 668 },
-{ 0x5, 94, 0, 666 },
-{ 0x3, 94, 0, 667 },
-{ 0x2, 93, 0, 659 },
-{ 0xa, 93, 0, 657 },
-{ 0x6, 93, 0, 658 },
-{ 0x1, 93, 0, 671 },
-{ 0x5, 93, 0, 669 },
-{ 0x3, 93, 0, 670 },
-{ 0x2, 92, 0, 662 },
-{ 0xa, 92, 0, 660 },
-{ 0x6, 92, 0, 661 },
-{ 0x1, 92, 0, 674 },
-{ 0x5, 92, 0, 672 },
-{ 0x3, 92, 0, 673 },
-{ 0x8, 354, 0, 676 },
-{ 0x18, 354, 0, 675 },
-{ 0x4, 354, 0, 678 },
-{ 0xc, 354, 0, 677 },
-{ 0x2, 354, 0, 685 },
-{ 0x1, 354, 0, 686 },
-{ 0x4, 352, 0, 680 },
-{ 0xc, 352, 0, 679 },
-{ 0x2, 352, 0, 687 },
-{ 0x1, 352, 0, 688 },
-{ 0x4, 350, 0, 682 },
-{ 0xc, 350, 0, 681 },
-{ 0x2, 350, 0, 689 },
-{ 0x1, 350, 0, 690 },
-{ 0x4, 348, 0, 684 },
-{ 0xc, 348, 0, 683 },
-{ 0x2, 348, 0, 691 },
-{ 0x1, 348, 0, 692 },
-{ 0xa00, 212, 0, 707 },
-{ 0x2a00, 212, 0, 705 },
-{ 0x1a00, 212, 0, 706 },
-{ 0x600, 212, 0, 719 },
-{ 0x2600, 212, 0, 695 },
-{ 0xa600, 212, 0, 693 },
-{ 0x6600, 212, 0, 694 },
-{ 0x1600, 212, 0, 717 },
-{ 0xe00, 212, 0, 718 },
-{ 0x100, 212, 0, 731 },
-{ 0x500, 212, 0, 729 },
-{ 0x300, 212, 0, 730 },
-{ 0x80, 212, 0, 734 },
-{ 0x280, 212, 0, 732 },
-{ 0x180, 212, 0, 733 },
-{ 0x40, 212, 0, 746 },
-{ 0x140, 212, 0, 744 },
-{ 0xc0, 212, 0, 745 },
-{ 0x20, 212, 0, 758 },
-{ 0xa0, 212, 0, 756 },
-{ 0x60, 212, 0, 757 },
-{ 0x10, 212, 0, 770 },
-{ 0x50, 212, 0, 768 },
-{ 0x30, 212, 0, 769 },
-{ 0x8, 212, 0, 782 },
-{ 0x28, 212, 0, 780 },
-{ 0x18, 212, 0, 781 },
-{ 0x4, 212, 0, 792 },
-{ 0x2, 212, 0, 793 },
-{ 0x1, 212, 0, 794 },
-{ 0x500, 209, 0, 710 },
-{ 0x1500, 209, 0, 708 },
-{ 0xd00, 209, 0, 709 },
-{ 0x300, 209, 0, 722 },
-{ 0x1300, 209, 0, 698 },
-{ 0x5300, 209, 0, 696 },
-{ 0x3300, 209, 0, 697 },
-{ 0xb00, 209, 0, 720 },
-{ 0x700, 209, 0, 721 },
-{ 0x80, 209, 0, 737 },
-{ 0x280, 209, 0, 735 },
-{ 0x180, 209, 0, 736 },
-{ 0x40, 209, 0, 749 },
-{ 0x140, 209, 0, 747 },
-{ 0xc0, 209, 0, 748 },
-{ 0x20, 209, 0, 761 },
-{ 0xa0, 209, 0, 759 },
-{ 0x60, 209, 0, 760 },
-{ 0x10, 209, 0, 773 },
-{ 0x50, 209, 0, 771 },
-{ 0x30, 209, 0, 772 },
-{ 0x8, 209, 0, 785 },
-{ 0x28, 209, 0, 783 },
-{ 0x18, 209, 0, 784 },
-{ 0x4, 209, 0, 795 },
-{ 0x2, 209, 0, 796 },
-{ 0x1, 209, 0, 797 },
-{ 0x500, 206, 0, 713 },
-{ 0x1500, 206, 0, 711 },
-{ 0xd00, 206, 0, 712 },
-{ 0x300, 206, 0, 725 },
-{ 0x1300, 206, 0, 701 },
-{ 0x5300, 206, 0, 699 },
-{ 0x3300, 206, 0, 700 },
-{ 0xb00, 206, 0, 723 },
-{ 0x700, 206, 0, 724 },
-{ 0x80, 206, 0, 740 },
-{ 0x280, 206, 0, 738 },
-{ 0x180, 206, 0, 739 },
-{ 0x40, 206, 0, 752 },
-{ 0x140, 206, 0, 750 },
-{ 0xc0, 206, 0, 751 },
-{ 0x20, 206, 0, 764 },
-{ 0xa0, 206, 0, 762 },
-{ 0x60, 206, 0, 763 },
-{ 0x10, 206, 0, 776 },
-{ 0x50, 206, 0, 774 },
-{ 0x30, 206, 0, 775 },
-{ 0x8, 206, 0, 788 },
-{ 0x28, 206, 0, 786 },
-{ 0x18, 206, 0, 787 },
-{ 0x4, 206, 0, 798 },
-{ 0x2, 206, 0, 799 },
-{ 0x1, 206, 0, 800 },
-{ 0x500, 203, 0, 716 },
-{ 0x1500, 203, 0, 714 },
-{ 0xd00, 203, 0, 715 },
-{ 0x300, 203, 0, 728 },
-{ 0x1300, 203, 0, 704 },
-{ 0x5300, 203, 0, 702 },
-{ 0x3300, 203, 0, 703 },
-{ 0xb00, 203, 0, 726 },
-{ 0x700, 203, 0, 727 },
-{ 0x80, 203, 0, 743 },
-{ 0x280, 203, 0, 741 },
-{ 0x180, 203, 0, 742 },
-{ 0x40, 203, 0, 755 },
-{ 0x140, 203, 0, 753 },
-{ 0xc0, 203, 0, 754 },
-{ 0x20, 203, 0, 767 },
-{ 0xa0, 203, 0, 765 },
-{ 0x60, 203, 0, 766 },
-{ 0x10, 203, 0, 779 },
-{ 0x50, 203, 0, 777 },
-{ 0x30, 203, 0, 778 },
-{ 0x8, 203, 0, 791 },
-{ 0x28, 203, 0, 789 },
-{ 0x18, 203, 0, 790 },
-{ 0x4, 203, 0, 801 },
-{ 0x2, 203, 0, 802 },
-{ 0x1, 203, 0, 803 },
-{ 0xa00, 211, 0, 818 },
-{ 0x2a00, 211, 0, 816 },
-{ 0x1a00, 211, 0, 817 },
-{ 0x600, 211, 0, 830 },
-{ 0x2600, 211, 0, 806 },
-{ 0xa600, 211, 0, 804 },
-{ 0x6600, 211, 0, 805 },
-{ 0x1600, 211, 0, 828 },
-{ 0xe00, 211, 0, 829 },
-{ 0x100, 211, 0, 842 },
-{ 0x500, 211, 0, 840 },
-{ 0x300, 211, 0, 841 },
-{ 0x80, 211, 0, 845 },
-{ 0x280, 211, 0, 843 },
-{ 0x180, 211, 0, 844 },
-{ 0x40, 211, 0, 857 },
-{ 0x140, 211, 0, 855 },
-{ 0xc0, 211, 0, 856 },
-{ 0x20, 211, 0, 869 },
-{ 0xa0, 211, 0, 867 },
-{ 0x60, 211, 0, 868 },
-{ 0x10, 211, 0, 881 },
-{ 0x50, 211, 0, 879 },
-{ 0x30, 211, 0, 880 },
-{ 0x8, 211, 0, 893 },
-{ 0x28, 211, 0, 891 },
-{ 0x18, 211, 0, 892 },
-{ 0x4, 211, 0, 903 },
-{ 0x2, 211, 0, 904 },
-{ 0x1, 211, 0, 905 },
-{ 0x500, 208, 0, 821 },
-{ 0x1500, 208, 0, 819 },
-{ 0xd00, 208, 0, 820 },
-{ 0x300, 208, 0, 833 },
-{ 0x1300, 208, 0, 809 },
-{ 0x5300, 208, 0, 807 },
-{ 0x3300, 208, 0, 808 },
-{ 0xb00, 208, 0, 831 },
-{ 0x700, 208, 0, 832 },
-{ 0x80, 208, 0, 848 },
-{ 0x280, 208, 0, 846 },
-{ 0x180, 208, 0, 847 },
-{ 0x40, 208, 0, 860 },
-{ 0x140, 208, 0, 858 },
-{ 0xc0, 208, 0, 859 },
-{ 0x20, 208, 0, 872 },
-{ 0xa0, 208, 0, 870 },
-{ 0x60, 208, 0, 871 },
-{ 0x10, 208, 0, 884 },
-{ 0x50, 208, 0, 882 },
-{ 0x30, 208, 0, 883 },
-{ 0x8, 208, 0, 896 },
-{ 0x28, 208, 0, 894 },
-{ 0x18, 208, 0, 895 },
-{ 0x4, 208, 0, 906 },
-{ 0x2, 208, 0, 907 },
-{ 0x1, 208, 0, 908 },
-{ 0x500, 205, 0, 824 },
-{ 0x1500, 205, 0, 822 },
-{ 0xd00, 205, 0, 823 },
-{ 0x300, 205, 0, 836 },
-{ 0x1300, 205, 0, 812 },
-{ 0x5300, 205, 0, 810 },
-{ 0x3300, 205, 0, 811 },
-{ 0xb00, 205, 0, 834 },
-{ 0x700, 205, 0, 835 },
-{ 0x80, 205, 0, 851 },
-{ 0x280, 205, 0, 849 },
-{ 0x180, 205, 0, 850 },
-{ 0x40, 205, 0, 863 },
-{ 0x140, 205, 0, 861 },
-{ 0xc0, 205, 0, 862 },
-{ 0x20, 205, 0, 875 },
-{ 0xa0, 205, 0, 873 },
-{ 0x60, 205, 0, 874 },
-{ 0x10, 205, 0, 887 },
-{ 0x50, 205, 0, 885 },
-{ 0x30, 205, 0, 886 },
-{ 0x8, 205, 0, 899 },
-{ 0x28, 205, 0, 897 },
-{ 0x18, 205, 0, 898 },
-{ 0x4, 205, 0, 909 },
-{ 0x2, 205, 0, 910 },
-{ 0x1, 205, 0, 911 },
-{ 0x500, 202, 0, 827 },
-{ 0x1500, 202, 0, 825 },
-{ 0xd00, 202, 0, 826 },
-{ 0x300, 202, 0, 839 },
-{ 0x1300, 202, 0, 815 },
-{ 0x5300, 202, 0, 813 },
-{ 0x3300, 202, 0, 814 },
-{ 0xb00, 202, 0, 837 },
-{ 0x700, 202, 0, 838 },
-{ 0x80, 202, 0, 854 },
-{ 0x280, 202, 0, 852 },
-{ 0x180, 202, 0, 853 },
-{ 0x40, 202, 0, 866 },
-{ 0x140, 202, 0, 864 },
-{ 0xc0, 202, 0, 865 },
-{ 0x20, 202, 0, 878 },
-{ 0xa0, 202, 0, 876 },
-{ 0x60, 202, 0, 877 },
-{ 0x10, 202, 0, 890 },
-{ 0x50, 202, 0, 888 },
-{ 0x30, 202, 0, 889 },
-{ 0x8, 202, 0, 902 },
-{ 0x28, 202, 0, 900 },
-{ 0x18, 202, 0, 901 },
-{ 0x4, 202, 0, 912 },
-{ 0x2, 202, 0, 913 },
-{ 0x1, 202, 0, 914 },
-{ 0x1, 49, 0, 917 },
-{ 0x3, 48, 0, 918 },
-{ 0x1, 374, 0, 919 },
-{ 0x1, 380, 0, 920 },
-{ 0x2, 334, 0, 923 },
-{ 0x1, 334, 0, 924 },
-{ 0x2, 332, 0, 925 },
-{ 0x1, 332, 0, 926 },
-{ 0x1, 331, 0, 927 },
-{ 0x1, 276, 0, 932 },
-{ 0x1, 275, 0, 933 },
-{ 0x1, 274, 0, 934 },
-{ 0x1, 273, 0, 935 },
-{ 0x1, 201, 0, 936 },
-{ 0x1, 200, 0, 937 },
-{ 0x1, 272, 0, 938 },
-{ 0x1, 271, 0, 939 },
-{ 0x1, 270, 0, 940 },
-{ 0x1, 269, 0, 941 },
-{ 0x1, 268, 0, 942 },
-{ 0x1, 267, 0, 943 },
-{ 0x1, 266, 0, 944 },
-{ 0x2, 199, 0, 945 },
-{ 0x1, 199, 0, 946 },
-{ 0x2, 314, 0, 952 },
-{ 0x1, 314, 0, 953 },
-{ 0x1, 265, 0, 954 },
-{ 0x1, 264, 0, 955 },
-{ 0x1, 263, 0, 956 },
-{ 0x1, 262, 0, 957 },
-{ 0x1, 8, 0, 958 },
-{ 0x1, 261, 0, 959 },
-{ 0x1, 260, 0, 960 },
-{ 0x1, 259, 0, 961 },
-{ 0x1, 258, 0, 962 },
-{ 0x1, 336, 0, 963 },
-{ 0x1, 347, 0, 964 },
-{ 0x1, 337, 0, 965 },
-{ 0x1, 369, 0, 966 },
-{ 0x1, 257, 0, 969 },
-{ 0x1, 198, 0, 970 },
-{ 0x1, 134, 0, 973 },
-{ 0x2, 239, 0, 977 },
-{ 0x1, 239, 0, 978 },
-{ 0x1, 193, 0, 979 },
-{ 0x5, 47, 0, 981 },
-{ 0x3, 47, 0, 982 },
-{ 0x5, 46, 0, 983 },
-{ 0x3, 46, 0, 984 },
-{ 0x1, 313, 0, 985 },
-{ 0x1, 321, 0, 986 },
-{ 0x1, 319, 0, 987 },
-{ 0x1, 340, 0, 988 },
-{ 0x1, 320, 0, 989 },
-{ 0x1, 318, 0, 990 },
-{ 0x2, 326, 0, 991 },
-{ 0x1, 326, 0, 993 },
-{ 0x2, 324, 0, 992 },
-{ 0x1, 324, 0, 994 },
-{ 0x2, 344, 0, 995 },
-{ 0x1, 344, 0, 998 },
-{ 0x2, 325, 0, 996 },
-{ 0x1, 325, 0, 999 },
-{ 0x2, 323, 0, 997 },
-{ 0x1, 323, 0, 1000 },
-{ 0x1, 286, 0, 1001 },
-{ 0x1, 285, 0, 1002 },
-{ 0x1, 317, 0, 1003 },
-{ 0x1, 308, 0, 1004 },
-{ 0x1, 310, 0, 1005 },
-{ 0x1, 307, 0, 1006 },
-{ 0x1, 309, 0, 1007 },
-{ 0x2, 384, 0, 1008 },
-{ 0x1, 384, 0, 1011 },
-{ 0x2, 383, 0, 1009 },
-{ 0x1, 383, 0, 1012 },
-{ 0x2, 382, 0, 1010 },
-{ 0x1, 382, 0, 1013 },
-{ 0x1, 296, 0, 1014 },
-{ 0x2, 295, 0, 1015 },
-{ 0x1, 295, 0, 1016 },
-{ 0x2, 242, 0, 1017 },
-{ 0x1, 242, 0, 1020 },
-{ 0x2, 241, 0, 1018 },
-{ 0x1, 241, 0, 1021 },
-{ 0x2, 240, 0, 1019 },
-{ 0x1, 240, 0, 1022 },
-{ 0x2, 311, 0, 1023 },
-{ 0x1, 311, 0, 1024 },
-{ 0x2, 312, 0, 1025 },
-{ 0x1, 312, 0, 1026 },
-{ 0xa, 378, 1, 1032 },
-{ 0xa, 379, 0, 1031 },
-{ 0x1a, 378, 1, 1028 },
-{ 0x32, 379, 0, 1027 },
-{ 0x6, 378, 1, 1036 },
-{ 0x6, 379, 0, 1035 },
-{ 0x1, 378, 1, 1042 },
-{ 0x1, 379, 0, 1041 },
-{ 0x9, 378, 1, 1034 },
-{ 0x9, 379, 0, 1033 },
-{ 0x19, 378, 1, 1030 },
-{ 0x31, 379, 0, 1029 },
-{ 0x5, 378, 1, 1038 },
-{ 0x5, 379, 0, 1037 },
-{ 0x3, 378, 1, 1040 },
-{ 0x3, 379, 0, 1039 },
-{ 0xa, 375, 1, 1048 },
-{ 0xa, 376, 0, 1047 },
-{ 0x1a, 375, 1, 1044 },
-{ 0x32, 376, 0, 1043 },
-{ 0x6, 375, 1, 1052 },
-{ 0x6, 376, 0, 1051 },
-{ 0x1, 375, 1, 1058 },
-{ 0x1, 376, 0, 1057 },
-{ 0x9, 375, 1, 1050 },
-{ 0x9, 376, 0, 1049 },
-{ 0x19, 375, 1, 1046 },
-{ 0x31, 376, 0, 1045 },
-{ 0x5, 375, 1, 1054 },
-{ 0x5, 376, 0, 1053 },
-{ 0x3, 375, 1, 1056 },
-{ 0x3, 376, 0, 1055 },
-{ 0x1, 102, 0, 1059 },
-{ 0x1, 101, 0, 1060 },
-{ 0x1, 339, 1, 1062 },
-{ 0x1, 100, 0, 1061 },
-{ 0x2, 343, 1, 1064 },
-{ 0x2, 104, 0, 1063 },
-{ 0x1, 343, 1, 1066 },
-{ 0x1, 104, 0, 1065 },
-{ 0x1, 345, 0, 1067 },
-{ 0x1, 99, 0, 1068 },
-{ 0x2, 98, 0, 1069 },
-{ 0x2, 97, 0, 1070 },
-{ 0x1, 396, 1, 1076 },
-{ 0x1, 197, 0, 971 },
-{ 0x1, 395, 0, 1077 },
-{ 0x1, 394, 1, 1078 },
-{ 0x1, 196, 0, 980 },
-{ 0x1, 256, 0, 1079 },
-{ 0x1, 255, 1, 1080 },
-{ 0x1, 238, 0, 972 },
-{ 0x1, 254, 0, 1081 },
-{ 0x1, 253, 1, 1082 },
-{ 0x1, 373, 0, 974 },
-{ 0x1, 252, 1, 1083 },
-{ 0x1, 346, 0, 976 },
-{ 0x1, 251, 0, 1084 },
-{ 0x1, 250, 0, 1085 },
-{ 0x1, 249, 1, 1086 },
-{ 0x2, 346, 0, 975 },
-{ 0x10, 248, 0, 1090 },
-{ 0x90, 248, 0, 1088 },
-{ 0x190, 248, 0, 1087 },
-{ 0x50, 248, 0, 1089 },
-{ 0x30, 248, 0, 1092 },
-{ 0x70, 248, 0, 1091 },
-{ 0x8, 248, 0, 1094 },
-{ 0x18, 248, 0, 1093 },
-{ 0x4, 248, 0, 1095 },
-{ 0x1, 248, 0, 1098 },
-{ 0x3, 248, 0, 1097 },
-{ 0x1, 247, 1, 1099 },
-{ 0x2, 248, 0, 1096 },
-{ 0x3, 45, 0, 1100 },
-{ 0x1, 289, 1, 1101 },
-{ 0x1, 290, 1, 967 },
-{ 0x1, 291, 0, 87 },
-{ 0x1, 33, 1, 1102 },
-{ 0x1, 34, 1, 968 },
-{ 0x1, 35, 0, 88 },
-{ 0x1, 187, 0, 1103 },
-{ 0x4, 389, 0, 1104 },
-{ 0x2, 389, 0, 1105 },
-{ 0x1, 389, 1, 1107 },
-{ 0x1, 390, 0, 1106 },
-{ 0x8, 391, 0, 1108 },
-{ 0x4, 391, 0, 1109 },
-{ 0x1, 391, 1, 1111 },
-{ 0x2, 391, 0, 1110 },
-{ 0x8, 176, 0, 1112 },
-{ 0x4, 176, 0, 1113 },
-{ 0x2, 176, 0, 1114 },
-{ 0x1, 176, 1, 1116 },
-{ 0x1, 177, 0, 1115 },
-{ 0x10, 178, 0, 1117 },
-{ 0x8, 178, 0, 1118 },
-{ 0x4, 178, 0, 1119 },
-{ 0x1, 178, 1, 1121 },
-{ 0x2, 178, 0, 1120 },
-{ 0x220, 148, 0, 1122 },
-{ 0x120, 148, 0, 1123 },
-{ 0xa0, 148, 0, 1124 },
-{ 0x60, 148, 1, 1126 },
-{ 0x4, 149, 0, 1125 },
-{ 0x110, 148, 0, 1132 },
-{ 0x90, 148, 0, 1133 },
-{ 0x50, 148, 0, 1134 },
-{ 0x30, 148, 1, 1136 },
-{ 0x2, 149, 0, 1135 },
-{ 0x8, 148, 0, 1137 },
-{ 0x4, 148, 0, 1138 },
-{ 0x2, 148, 0, 1139 },
-{ 0x1, 148, 1, 1141 },
-{ 0x1, 149, 0, 1140 },
-{ 0x440, 150, 0, 1127 },
-{ 0x240, 150, 0, 1128 },
-{ 0x140, 150, 0, 1129 },
-{ 0xc0, 150, 1, 1131 },
-{ 0x40, 150, 0, 1130 },
-{ 0x220, 150, 0, 1142 },
-{ 0x120, 150, 0, 1143 },
-{ 0xa0, 150, 0, 1144 },
-{ 0x60, 150, 1, 1146 },
-{ 0x20, 150, 0, 1145 },
-{ 0x10, 150, 0, 1147 },
-{ 0x8, 150, 0, 1148 },
-{ 0x4, 150, 0, 1149 },
-{ 0x1, 150, 1, 1151 },
-{ 0x2, 150, 0, 1150 },
-{ 0x8, 172, 0, 1152 },
-{ 0x4, 172, 0, 1153 },
-{ 0x2, 172, 0, 1154 },
-{ 0x1, 172, 1, 1156 },
-{ 0x1, 173, 0, 1155 },
-{ 0x220, 144, 0, 1157 },
-{ 0x120, 144, 0, 1158 },
-{ 0xa0, 144, 0, 1159 },
-{ 0x60, 144, 1, 1161 },
-{ 0x4, 145, 0, 1160 },
-{ 0x110, 144, 0, 1167 },
-{ 0x90, 144, 0, 1168 },
-{ 0x50, 144, 0, 1169 },
-{ 0x30, 144, 1, 1171 },
-{ 0x2, 145, 0, 1170 },
-{ 0x8, 144, 0, 1172 },
-{ 0x4, 144, 0, 1173 },
-{ 0x2, 144, 0, 1174 },
-{ 0x1, 144, 1, 1176 },
-{ 0x1, 145, 0, 1175 },
-{ 0x440, 190, 0, 1162 },
-{ 0x240, 190, 0, 1163 },
-{ 0x140, 190, 0, 1164 },
-{ 0xc0, 190, 1, 1166 },
-{ 0x40, 190, 0, 1165 },
-{ 0x220, 190, 0, 1177 },
-{ 0x120, 190, 0, 1178 },
-{ 0xa0, 190, 0, 1179 },
-{ 0x60, 190, 1, 1181 },
-{ 0x20, 190, 0, 1180 },
-{ 0x10, 190, 0, 1182 },
-{ 0x8, 190, 0, 1183 },
-{ 0x4, 190, 0, 1184 },
-{ 0x1, 190, 1, 1186 },
-{ 0x2, 190, 0, 1185 },
-{ 0x8, 164, 0, 1187 },
-{ 0x4, 164, 0, 1188 },
-{ 0x2, 164, 0, 1189 },
-{ 0x1, 164, 1, 1191 },
-{ 0x1, 165, 0, 1190 },
-{ 0x10, 171, 0, 1192 },
-{ 0x8, 171, 0, 1193 },
-{ 0x4, 171, 0, 1194 },
-{ 0x1, 171, 1, 1196 },
-{ 0x2, 171, 0, 1195 },
-{ 0x220, 135, 0, 1197 },
-{ 0x120, 135, 0, 1198 },
-{ 0xa0, 135, 0, 1199 },
-{ 0x60, 135, 1, 1201 },
-{ 0x4, 136, 0, 1200 },
-{ 0x110, 135, 0, 1222 },
-{ 0x90, 135, 0, 1223 },
-{ 0x50, 135, 0, 1224 },
-{ 0x30, 135, 1, 1226 },
-{ 0x2, 136, 0, 1225 },
-{ 0x8, 135, 0, 1227 },
-{ 0x4, 135, 0, 1228 },
-{ 0x2, 135, 0, 1229 },
-{ 0x1, 135, 1, 1231 },
-{ 0x1, 136, 0, 1230 },
-{ 0x440, 143, 0, 1202 },
-{ 0x240, 143, 0, 1203 },
-{ 0x140, 143, 0, 1204 },
-{ 0xc0, 143, 1, 1206 },
-{ 0x40, 143, 0, 1205 },
-{ 0x220, 143, 0, 1232 },
-{ 0x120, 143, 0, 1233 },
-{ 0xa0, 143, 0, 1234 },
-{ 0x60, 143, 1, 1236 },
-{ 0x20, 143, 0, 1235 },
-{ 0x10, 143, 0, 1237 },
-{ 0x8, 143, 0, 1238 },
-{ 0x4, 143, 0, 1239 },
-{ 0x1, 143, 1, 1241 },
-{ 0x2, 143, 0, 1240 },
-{ 0x440, 106, 0, 1207 },
-{ 0x240, 106, 0, 1208 },
-{ 0x140, 106, 0, 1209 },
-{ 0xc0, 106, 1, 1211 },
-{ 0x40, 106, 0, 1210 },
-{ 0x220, 106, 0, 1242 },
-{ 0x120, 106, 0, 1243 },
-{ 0xa0, 106, 0, 1244 },
-{ 0x60, 106, 1, 1246 },
-{ 0x20, 106, 0, 1245 },
-{ 0x10, 106, 0, 1247 },
-{ 0x8, 106, 0, 1248 },
-{ 0x1, 106, 1, 1251 },
-{ 0x2, 106, 0, 1250 },
-{ 0x440, 151, 1, 1217 },
-{ 0x441, 131, 0, 1212 },
-{ 0x240, 151, 1, 1218 },
-{ 0x241, 131, 0, 1213 },
-{ 0x140, 151, 1, 1219 },
-{ 0x141, 131, 0, 1214 },
-{ 0xc0, 151, 1, 1221 },
-{ 0x40, 151, 1, 1220 },
-{ 0xc1, 131, 1, 1216 },
-{ 0x41, 131, 0, 1215 },
-{ 0x220, 151, 1, 1262 },
-{ 0x221, 131, 0, 1252 },
-{ 0x120, 151, 1, 1263 },
-{ 0x121, 131, 0, 1253 },
-{ 0xa0, 151, 1, 1264 },
-{ 0xa1, 131, 0, 1254 },
-{ 0x60, 151, 1, 1266 },
-{ 0x20, 151, 1, 1265 },
-{ 0x61, 131, 1, 1256 },
-{ 0x21, 131, 0, 1255 },
-{ 0x10, 151, 1, 1267 },
-{ 0x11, 131, 0, 1257 },
-{ 0x8, 151, 1, 1268 },
-{ 0x9, 131, 0, 1258 },
-{ 0x4, 151, 1, 1269 },
-{ 0x5, 131, 0, 1259 },
-{ 0x1, 151, 1, 1271 },
-{ 0x2, 151, 1, 1270 },
-{ 0x3, 131, 1, 1261 },
-{ 0x1, 131, 0, 1260 },
-{ 0x1, 116, 1, 1275 },
-{ 0x1, 117, 0, 1274 },
-{ 0x3, 116, 1, 1273 },
-{ 0x3, 117, 0, 1272 },
-{ 0x1108, 120, 1, 1356 },
-{ 0x1108, 124, 0, 1276 },
-{ 0x908, 120, 1, 1357 },
-{ 0x908, 124, 0, 1277 },
-{ 0x508, 120, 1, 1358 },
-{ 0x508, 124, 0, 1278 },
-{ 0x308, 120, 1, 1360 },
-{ 0x18, 121, 1, 1359 },
-{ 0x308, 124, 1, 1280 },
-{ 0x18, 125, 0, 1279 },
-{ 0x88, 120, 1, 1376 },
-{ 0x88, 124, 0, 1316 },
-{ 0x48, 120, 1, 1377 },
-{ 0x48, 124, 0, 1317 },
-{ 0x28, 120, 1, 1378 },
-{ 0x28, 124, 0, 1318 },
-{ 0x18, 120, 1, 1380 },
-{ 0x8, 121, 1, 1379 },
-{ 0x18, 124, 1, 1320 },
-{ 0x8, 125, 0, 1319 },
-{ 0x884, 120, 1, 1361 },
-{ 0x442, 122, 1, 1306 },
-{ 0x884, 124, 1, 1291 },
-{ 0x442, 126, 0, 1281 },
-{ 0x484, 120, 1, 1362 },
-{ 0x242, 122, 1, 1307 },
-{ 0x484, 124, 1, 1292 },
-{ 0x242, 126, 0, 1282 },
-{ 0x284, 120, 1, 1363 },
-{ 0x142, 122, 1, 1308 },
-{ 0x284, 124, 1, 1293 },
-{ 0x142, 126, 0, 1283 },
-{ 0x184, 120, 1, 1365 },
-{ 0xc, 121, 1, 1364 },
-{ 0xc2, 122, 1, 1310 },
-{ 0x6, 123, 1, 1309 },
-{ 0x184, 124, 1, 1295 },
-{ 0xc, 125, 1, 1294 },
-{ 0xc2, 126, 1, 1285 },
-{ 0x6, 127, 0, 1284 },
-{ 0x44, 120, 1, 1381 },
-{ 0x22, 122, 1, 1346 },
-{ 0x44, 124, 1, 1331 },
-{ 0x22, 126, 0, 1321 },
-{ 0x24, 120, 1, 1382 },
-{ 0x12, 122, 1, 1347 },
-{ 0x24, 124, 1, 1332 },
-{ 0x12, 126, 0, 1322 },
-{ 0x14, 120, 1, 1383 },
-{ 0xa, 122, 1, 1348 },
-{ 0x14, 124, 1, 1333 },
-{ 0xa, 126, 0, 1323 },
-{ 0xc, 120, 1, 1385 },
-{ 0x4, 121, 1, 1384 },
-{ 0x6, 122, 1, 1350 },
-{ 0x2, 123, 1, 1349 },
-{ 0xc, 124, 1, 1335 },
-{ 0x4, 125, 1, 1334 },
-{ 0x6, 126, 1, 1325 },
-{ 0x2, 127, 0, 1324 },
-{ 0x442, 120, 1, 1366 },
-{ 0x221, 122, 1, 1311 },
-{ 0x442, 124, 1, 1296 },
-{ 0x221, 126, 0, 1286 },
-{ 0x242, 120, 1, 1367 },
-{ 0x121, 122, 1, 1312 },
-{ 0x242, 124, 1, 1297 },
-{ 0x121, 126, 0, 1287 },
-{ 0x142, 120, 1, 1368 },
-{ 0xa1, 122, 1, 1313 },
-{ 0x142, 124, 1, 1298 },
-{ 0xa1, 126, 0, 1288 },
-{ 0xc2, 120, 1, 1370 },
-{ 0x6, 121, 1, 1369 },
-{ 0x61, 122, 1, 1315 },
-{ 0x3, 123, 1, 1314 },
-{ 0xc2, 124, 1, 1300 },
-{ 0x6, 125, 1, 1299 },
-{ 0x61, 126, 1, 1290 },
-{ 0x3, 127, 0, 1289 },
-{ 0x22, 120, 1, 1386 },
-{ 0x11, 122, 1, 1351 },
-{ 0x22, 124, 1, 1336 },
-{ 0x11, 126, 0, 1326 },
-{ 0x12, 120, 1, 1387 },
-{ 0x9, 122, 1, 1352 },
-{ 0x12, 124, 1, 1337 },
-{ 0x9, 126, 0, 1327 },
-{ 0xa, 120, 1, 1388 },
-{ 0x5, 122, 1, 1353 },
-{ 0xa, 124, 1, 1338 },
-{ 0x5, 126, 0, 1328 },
-{ 0x6, 120, 1, 1390 },
-{ 0x2, 121, 1, 1389 },
-{ 0x3, 122, 1, 1355 },
-{ 0x1, 123, 1, 1354 },
-{ 0x6, 124, 1, 1340 },
-{ 0x2, 125, 1, 1339 },
-{ 0x3, 126, 1, 1330 },
-{ 0x1, 127, 0, 1329 },
-{ 0x221, 120, 1, 1371 },
-{ 0x221, 124, 0, 1301 },
-{ 0x121, 120, 1, 1372 },
-{ 0x121, 124, 0, 1302 },
-{ 0xa1, 120, 1, 1373 },
-{ 0xa1, 124, 0, 1303 },
-{ 0x61, 120, 1, 1375 },
-{ 0x3, 121, 1, 1374 },
-{ 0x61, 124, 1, 1305 },
-{ 0x3, 125, 0, 1304 },
-{ 0x11, 120, 1, 1391 },
-{ 0x11, 124, 0, 1341 },
-{ 0x9, 120, 1, 1392 },
-{ 0x9, 124, 0, 1342 },
-{ 0x5, 120, 1, 1393 },
-{ 0x5, 124, 0, 1343 },
-{ 0x3, 120, 1, 1395 },
-{ 0x1, 121, 1, 1394 },
-{ 0x3, 124, 1, 1345 },
-{ 0x1, 125, 0, 1344 },
-{ 0x442, 162, 0, 1396 },
-{ 0x242, 162, 0, 1397 },
-{ 0x142, 162, 0, 1398 },
-{ 0xc2, 162, 1, 1400 },
-{ 0x6, 163, 1, 1399 },
-{ 0x1, 381, 0, 921 },
-{ 0x22, 162, 0, 1406 },
-{ 0x12, 162, 0, 1407 },
-{ 0xa, 162, 0, 1408 },
-{ 0x6, 162, 1, 1410 },
-{ 0x2, 163, 1, 1409 },
-{ 0x2, 315, 0, 950 },
-{ 0x221, 162, 0, 1401 },
-{ 0x121, 162, 0, 1402 },
-{ 0xa1, 162, 0, 1403 },
-{ 0x61, 162, 1, 1405 },
-{ 0x3, 163, 1, 1404 },
-{ 0x1, 377, 0, 922 },
-{ 0x11, 162, 0, 1411 },
-{ 0x9, 162, 0, 1412 },
-{ 0x5, 162, 0, 1413 },
-{ 0x3, 162, 1, 1415 },
-{ 0x1, 163, 1, 1414 },
-{ 0x1, 315, 0, 951 },
-{ 0x4, 168, 0, 1416 },
-{ 0x1, 168, 0, 1418 },
-{ 0x1, 175, 0, 1419 },
-{ 0x1, 174, 1, 1420 },
-{ 0x2, 168, 0, 1417 },
-{ 0x1, 153, 0, 1421 },
-{ 0x880, 159, 0, 1422 },
-{ 0x480, 159, 0, 1423 },
-{ 0x280, 159, 0, 1424 },
-{ 0x180, 159, 1, 1426 },
-{ 0x80, 160, 0, 1425 },
-{ 0x440, 159, 1, 1437 },
-{ 0x88, 161, 0, 1427 },
-{ 0x240, 159, 1, 1438 },
-{ 0x48, 161, 0, 1428 },
-{ 0x140, 159, 1, 1439 },
-{ 0x28, 161, 0, 1429 },
-{ 0xc0, 159, 1, 1441 },
-{ 0x40, 160, 1, 1440 },
-{ 0x18, 161, 1, 1431 },
-{ 0x8, 161, 0, 1430 },
-{ 0x220, 159, 1, 1442 },
-{ 0x44, 161, 0, 1432 },
-{ 0x120, 159, 1, 1443 },
-{ 0x24, 161, 0, 1433 },
-{ 0xa0, 159, 1, 1444 },
-{ 0x14, 161, 0, 1434 },
-{ 0x60, 159, 1, 1446 },
-{ 0x20, 160, 1, 1445 },
-{ 0xc, 161, 1, 1436 },
-{ 0x4, 161, 0, 1435 },
-{ 0x110, 159, 0, 1447 },
-{ 0x90, 159, 0, 1448 },
-{ 0x50, 159, 0, 1449 },
-{ 0x30, 159, 1, 1451 },
-{ 0x10, 160, 1, 1450 },
-{ 0x1, 333, 0, 915 },
-{ 0x88, 159, 0, 1452 },
-{ 0x48, 159, 0, 1453 },
-{ 0x28, 159, 0, 1454 },
-{ 0x18, 159, 1, 1456 },
-{ 0x8, 160, 1, 1455 },
-{ 0xc, 316, 0, 947 },
-{ 0x44, 159, 1, 1467 },
-{ 0x22, 161, 0, 1457 },
-{ 0x24, 159, 1, 1468 },
-{ 0x12, 161, 0, 1458 },
-{ 0x14, 159, 1, 1469 },
-{ 0xa, 161, 0, 1459 },
-{ 0xc, 159, 1, 1471 },
-{ 0x4, 160, 1, 1470 },
-{ 0x6, 161, 1, 1461 },
-{ 0x2, 161, 1, 1460 },
-{ 0x6, 316, 0, 948 },
-{ 0x22, 159, 1, 1472 },
-{ 0x11, 161, 0, 1462 },
-{ 0x12, 159, 1, 1473 },
-{ 0x9, 161, 0, 1463 },
-{ 0xa, 159, 1, 1474 },
-{ 0x5, 161, 0, 1464 },
-{ 0x6, 159, 1, 1476 },
-{ 0x2, 160, 1, 1475 },
-{ 0x3, 161, 1, 1466 },
-{ 0x1, 161, 1, 1465 },
-{ 0x3, 316, 0, 949 },
-{ 0x11, 159, 0, 1477 },
-{ 0x9, 159, 0, 1478 },
-{ 0x5, 159, 0, 1479 },
-{ 0x3, 159, 1, 1481 },
-{ 0x1, 160, 1, 1480 },
-{ 0x1, 113, 0, 916 },
-{ 0x8, 155, 0, 1482 },
-{ 0x4, 155, 0, 1483 },
-{ 0x2, 155, 0, 1484 },
-{ 0x1, 155, 1, 1486 },
-{ 0x1, 156, 1, 1485 },
-{ 0x1, 280, 0, 928 },
-{ 0x8, 157, 0, 1487 },
-{ 0x4, 157, 0, 1488 },
-{ 0x2, 157, 0, 1489 },
-{ 0x1, 157, 1, 1491 },
-{ 0x1, 158, 1, 1490 },
-{ 0x1, 279, 0, 929 },
-{ 0x8, 166, 0, 1492 },
-{ 0x4, 166, 0, 1493 },
-{ 0x2, 166, 0, 1494 },
-{ 0x1, 166, 1, 1496 },
-{ 0x1, 167, 1, 1495 },
-{ 0x1, 278, 0, 930 },
-{ 0x8, 169, 0, 1497 },
-{ 0x4, 169, 0, 1498 },
-{ 0x2, 169, 0, 1499 },
-{ 0x1, 169, 1, 1501 },
-{ 0x1, 170, 1, 1500 },
-{ 0x1, 277, 0, 931 },
-{ 0x8, 181, 0, 1502 },
-{ 0x4, 181, 0, 1503 },
-{ 0x2, 181, 0, 1504 },
-{ 0x1, 181, 1, 1506 },
-{ 0x1, 182, 0, 1505 },
-{ 0x8, 179, 0, 1507 },
-{ 0x4, 179, 0, 1508 },
-{ 0x2, 179, 0, 1509 },
-{ 0x1, 179, 1, 1511 },
-{ 0x1, 180, 0, 1510 },
-{ 0x1, 288, 0, 1512 },
-{ 0x1, 32, 0, 1513 },
-{ 0x8, 114, 0, 1514 },
-{ 0x4, 114, 0, 1515 },
-{ 0x2, 114, 0, 1516 },
-{ 0x1, 114, 1, 1518 },
-{ 0x1, 115, 0, 1517 },
-{ 0x8, 118, 0, 1519 },
-{ 0x4, 118, 0, 1520 },
-{ 0x2, 118, 0, 1521 },
-{ 0x1, 118, 1, 1523 },
-{ 0x1, 119, 0, 1522 },
-{ 0x8, 188, 0, 1524 },
-{ 0x4, 188, 0, 1525 },
-{ 0x2, 188, 0, 1526 },
-{ 0x1, 188, 1, 1528 },
-{ 0x1, 189, 0, 1527 },
-{ 0x1, 130, 0, 1529 },
-{ 0x442, 128, 0, 1530 },
-{ 0x242, 128, 0, 1531 },
-{ 0x142, 128, 0, 1532 },
-{ 0xc2, 128, 1, 1534 },
-{ 0x6, 129, 0, 1533 },
-{ 0x22, 128, 0, 1540 },
-{ 0x12, 128, 0, 1541 },
-{ 0xa, 128, 0, 1542 },
-{ 0x6, 128, 1, 1544 },
-{ 0x2, 129, 1, 1543 },
-{ 0x1, 98, 0, 1071 },
-{ 0x221, 128, 0, 1535 },
-{ 0x121, 128, 0, 1536 },
-{ 0xa1, 128, 0, 1537 },
-{ 0x61, 128, 1, 1539 },
-{ 0x3, 129, 0, 1538 },
-{ 0x11, 128, 0, 1545 },
-{ 0x9, 128, 0, 1546 },
-{ 0x5, 128, 0, 1547 },
-{ 0x3, 128, 1, 1549 },
-{ 0x1, 129, 1, 1548 },
-{ 0x1, 97, 0, 1072 },
-{ 0x1, 194, 0, 1550 },
-{ 0x1, 152, 0, 1551 },
-{ 0x1, 112, 0, 1552 },
-{ 0x1, 111, 0, 1553 },
-{ 0x4, 191, 0, 1554 },
-{ 0x2, 191, 0, 1555 },
-{ 0x1, 191, 0, 1556 },
-{ 0x1, 154, 0, 1557 },
-{ 0x2, 192, 0, 1558 },
-{ 0x1, 192, 0, 1559 },
-{ 0x4, 142, 0, 1560 },
-{ 0x2, 142, 0, 1561 },
-{ 0x1, 142, 0, 1562 },
-{ 0x4, 139, 0, 1563 },
-{ 0x1, 147, 0, 1566 },
-{ 0x1, 146, 1, 1567 },
-{ 0x2, 139, 0, 1564 },
-{ 0x1, 105, 0, 1568 },
-{ 0x1, 246, 1, 1569 },
-{ 0x1, 139, 0, 1565 },
-{ 0x8, 107, 0, 1570 },
-{ 0x4, 107, 0, 1571 },
-{ 0x2, 107, 0, 1572 },
-{ 0x1, 107, 1, 1574 },
-{ 0x1, 108, 0, 1573 },
-{ 0x8, 109, 0, 1575 },
-{ 0x4, 109, 0, 1576 },
-{ 0x2, 109, 0, 1577 },
-{ 0x1, 109, 1, 1579 },
-{ 0x1, 110, 1, 1578 },
-{ 0x1, 372, 0, 1073 },
-{ 0x8, 137, 0, 1580 },
-{ 0x4, 137, 0, 1581 },
-{ 0x2, 137, 0, 1582 },
-{ 0x1, 137, 1, 1584 },
-{ 0x1, 138, 1, 1583 },
-{ 0x1, 371, 0, 1074 },
-{ 0x8, 140, 0, 1585 },
+{ 0x51, 40, 0, 10 },
+{ 0x31, 40, 1, 20 },
+{ 0x11, 41, 0, 19 },
+{ 0x29, 40, 0, 12 },
+{ 0x19, 40, 1, 24 },
+{ 0x9, 41, 0, 23 },
+{ 0x15, 40, 0, 14 },
+{ 0xd, 40, 1, 28 },
+{ 0x5, 41, 0, 27 },
+{ 0xb, 40, 0, 16 },
+{ 0x7, 40, 1, 32 },
+{ 0x3, 41, 0, 31 },
+{ 0x51, 38, 1, 58 },
+{ 0x50, 38, 0, 34 },
+{ 0xd1, 38, 1, 57 },
+{ 0xd0, 38, 0, 33 },
+{ 0x31, 38, 1, 68 },
+{ 0x30, 38, 1, 44 },
+{ 0x11, 39, 1, 67 },
+{ 0x10, 39, 0, 43 },
+{ 0x71, 38, 1, 66 },
+{ 0x70, 38, 1, 42 },
+{ 0x31, 39, 1, 65 },
+{ 0x30, 39, 0, 41 },
+{ 0x29, 38, 1, 60 },
+{ 0x28, 38, 0, 36 },
+{ 0x69, 38, 1, 59 },
+{ 0x68, 38, 0, 35 },
+{ 0x19, 38, 1, 72 },
+{ 0x18, 38, 1, 48 },
+{ 0x9, 39, 1, 71 },
+{ 0x8, 39, 0, 47 },
+{ 0x39, 38, 1, 70 },
+{ 0x38, 38, 1, 46 },
+{ 0x19, 39, 1, 69 },
+{ 0x18, 39, 0, 45 },
+{ 0x15, 38, 1, 62 },
+{ 0x14, 38, 0, 38 },
+{ 0x35, 38, 1, 61 },
+{ 0x34, 38, 0, 37 },
+{ 0xd, 38, 1, 76 },
+{ 0xc, 38, 1, 52 },
+{ 0x5, 39, 1, 75 },
+{ 0x4, 39, 0, 51 },
+{ 0x1d, 38, 1, 74 },
+{ 0x1c, 38, 1, 50 },
+{ 0xd, 39, 1, 73 },
+{ 0xc, 39, 0, 49 },
+{ 0xb, 38, 1, 64 },
+{ 0xa, 38, 0, 40 },
+{ 0x1b, 38, 1, 63 },
+{ 0x1a, 38, 0, 39 },
+{ 0x7, 38, 1, 80 },
+{ 0x6, 38, 1, 56 },
+{ 0x3, 39, 1, 79 },
+{ 0x2, 39, 0, 55 },
+{ 0xf, 38, 1, 78 },
+{ 0xe, 38, 1, 54 },
+{ 0x7, 39, 1, 77 },
+{ 0x6, 39, 0, 53 },
+{ 0x8, 37, 0, 82 },
+{ 0x18, 37, 0, 81 },
+{ 0x1, 37, 1, 86 },
+{ 0x2, 37, 0, 85 },
+{ 0x3, 37, 1, 84 },
+{ 0x4, 37, 0, 83 },
+{ 0x1, 293, 0, 87 },
+{ 0x20, 246, 0, 98 },
+{ 0x220, 246, 0, 94 },
+{ 0x1220, 246, 0, 91 },
+{ 0xa20, 246, 0, 92 },
+{ 0x620, 246, 0, 93 },
+{ 0x120, 246, 0, 95 },
+{ 0xa0, 246, 0, 96 },
+{ 0x60, 246, 0, 97 },
+{ 0x10, 246, 0, 102 },
+{ 0x90, 246, 0, 99 },
+{ 0x50, 246, 0, 100 },
+{ 0x30, 246, 0, 101 },
+{ 0x8, 246, 0, 103 },
+{ 0x4, 246, 0, 104 },
+{ 0x2, 246, 0, 105 },
+{ 0x1, 246, 0, 106 },
+{ 0x1, 367, 0, 108 },
+{ 0x3, 367, 0, 107 },
+{ 0x2, 373, 0, 109 },
+{ 0x1, 373, 0, 110 },
+{ 0x2, 369, 0, 111 },
+{ 0x1, 369, 0, 112 },
+{ 0x2, 371, 0, 113 },
+{ 0x1, 371, 0, 114 },
+{ 0x2, 375, 0, 115 },
+{ 0x1, 375, 0, 116 },
+{ 0x1, 225, 0, 143 },
+{ 0x5, 225, 0, 141 },
+{ 0x3, 225, 0, 142 },
+{ 0x140, 234, 0, 119 },
+{ 0x540, 234, 0, 117 },
+{ 0x340, 234, 0, 118 },
+{ 0xc0, 234, 0, 131 },
+{ 0x2c0, 234, 0, 129 },
+{ 0x1c0, 234, 0, 130 },
+{ 0x20, 234, 0, 146 },
+{ 0xa0, 234, 0, 144 },
+{ 0x60, 234, 0, 145 },
+{ 0x10, 234, 0, 158 },
+{ 0x50, 234, 0, 156 },
+{ 0x30, 234, 0, 157 },
+{ 0x8, 234, 0, 170 },
+{ 0x28, 234, 0, 168 },
+{ 0x18, 234, 0, 169 },
+{ 0x4, 234, 0, 180 },
+{ 0x2, 234, 0, 181 },
+{ 0x1, 234, 0, 182 },
+{ 0x140, 228, 0, 122 },
+{ 0x540, 228, 0, 120 },
+{ 0x340, 228, 0, 121 },
+{ 0xc0, 228, 0, 134 },
+{ 0x2c0, 228, 0, 132 },
+{ 0x1c0, 228, 0, 133 },
+{ 0x20, 228, 0, 149 },
+{ 0xa0, 228, 0, 147 },
+{ 0x60, 228, 0, 148 },
+{ 0x10, 228, 0, 161 },
+{ 0x50, 228, 0, 159 },
+{ 0x30, 228, 0, 160 },
+{ 0x8, 228, 0, 173 },
+{ 0x28, 228, 0, 171 },
+{ 0x18, 228, 0, 172 },
+{ 0x4, 228, 0, 183 },
+{ 0x2, 228, 0, 184 },
+{ 0x1, 228, 0, 185 },
+{ 0x140, 231, 0, 125 },
+{ 0x540, 231, 0, 123 },
+{ 0x340, 231, 0, 124 },
+{ 0xc0, 231, 0, 137 },
+{ 0x2c0, 231, 0, 135 },
+{ 0x1c0, 231, 0, 136 },
+{ 0x20, 231, 0, 152 },
+{ 0xa0, 231, 0, 150 },
+{ 0x60, 231, 0, 151 },
+{ 0x10, 231, 0, 164 },
+{ 0x50, 231, 0, 162 },
+{ 0x30, 231, 0, 163 },
+{ 0x8, 231, 0, 176 },
+{ 0x28, 231, 0, 174 },
+{ 0x18, 231, 0, 175 },
+{ 0x4, 231, 0, 186 },
+{ 0x2, 231, 0, 187 },
+{ 0x1, 231, 0, 188 },
+{ 0x140, 243, 0, 128 },
+{ 0x540, 243, 0, 126 },
+{ 0x340, 243, 0, 127 },
+{ 0xc0, 243, 0, 140 },
+{ 0x2c0, 243, 0, 138 },
+{ 0x1c0, 243, 0, 139 },
+{ 0x20, 243, 0, 155 },
+{ 0xa0, 243, 0, 153 },
+{ 0x60, 243, 0, 154 },
+{ 0x10, 243, 0, 167 },
+{ 0x50, 243, 0, 165 },
+{ 0x30, 243, 0, 166 },
+{ 0x8, 243, 0, 179 },
+{ 0x28, 243, 0, 177 },
+{ 0x18, 243, 0, 178 },
+{ 0x4, 243, 0, 189 },
+{ 0x2, 243, 0, 190 },
+{ 0x1, 243, 0, 191 },
+{ 0x8, 347, 0, 192 },
+{ 0x4, 347, 0, 193 },
+{ 0x2, 347, 0, 194 },
+{ 0x1, 347, 0, 195 },
+{ 0x20, 245, 0, 203 },
+{ 0x220, 245, 0, 199 },
+{ 0x1220, 245, 0, 196 },
+{ 0xa20, 245, 0, 197 },
+{ 0x620, 245, 0, 198 },
+{ 0x120, 245, 0, 200 },
+{ 0xa0, 245, 0, 201 },
+{ 0x60, 245, 0, 202 },
+{ 0x10, 245, 0, 207 },
+{ 0x90, 245, 0, 204 },
+{ 0x50, 245, 0, 205 },
+{ 0x30, 245, 0, 206 },
+{ 0x8, 245, 0, 208 },
+{ 0x4, 245, 0, 209 },
+{ 0x2, 245, 0, 210 },
+{ 0x1, 245, 0, 211 },
+{ 0x20, 244, 0, 219 },
+{ 0x220, 244, 0, 215 },
+{ 0x1220, 244, 0, 212 },
+{ 0xa20, 244, 0, 213 },
+{ 0x620, 244, 0, 214 },
+{ 0x120, 244, 0, 216 },
+{ 0xa0, 244, 0, 217 },
+{ 0x60, 244, 0, 218 },
+{ 0x10, 244, 0, 223 },
+{ 0x90, 244, 0, 220 },
+{ 0x50, 244, 0, 221 },
+{ 0x30, 244, 0, 222 },
+{ 0x8, 244, 0, 224 },
+{ 0x4, 244, 0, 225 },
+{ 0x2, 244, 0, 226 },
+{ 0x1, 244, 0, 227 },
+{ 0x140, 236, 0, 230 },
+{ 0x540, 236, 0, 228 },
+{ 0x340, 236, 0, 229 },
+{ 0xc0, 236, 0, 239 },
+{ 0x2c0, 236, 0, 237 },
+{ 0x1c0, 236, 0, 238 },
+{ 0x20, 236, 0, 248 },
+{ 0xa0, 236, 0, 246 },
+{ 0x60, 236, 0, 247 },
+{ 0x10, 236, 0, 257 },
+{ 0x50, 236, 0, 255 },
+{ 0x30, 236, 0, 256 },
+{ 0x8, 236, 0, 266 },
+{ 0x28, 236, 0, 264 },
+{ 0x18, 236, 0, 265 },
+{ 0x4, 236, 0, 273 },
+{ 0x2, 236, 0, 274 },
+{ 0x1, 236, 0, 275 },
+{ 0x140, 238, 0, 233 },
+{ 0x540, 238, 0, 231 },
+{ 0x340, 238, 0, 232 },
+{ 0xc0, 238, 0, 242 },
+{ 0x2c0, 238, 0, 240 },
+{ 0x1c0, 238, 0, 241 },
+{ 0x20, 238, 0, 251 },
+{ 0xa0, 238, 0, 249 },
+{ 0x60, 238, 0, 250 },
+{ 0x10, 238, 0, 260 },
+{ 0x50, 238, 0, 258 },
+{ 0x30, 238, 0, 259 },
+{ 0x8, 238, 0, 269 },
+{ 0x28, 238, 0, 267 },
+{ 0x18, 238, 0, 268 },
+{ 0x4, 238, 0, 276 },
+{ 0x2, 238, 0, 277 },
+{ 0x1, 238, 0, 278 },
+{ 0x140, 240, 0, 236 },
+{ 0x540, 240, 0, 234 },
+{ 0x340, 240, 0, 235 },
+{ 0xc0, 240, 0, 245 },
+{ 0x2c0, 240, 0, 243 },
+{ 0x1c0, 240, 0, 244 },
+{ 0x20, 240, 0, 254 },
+{ 0xa0, 240, 0, 252 },
+{ 0x60, 240, 0, 253 },
+{ 0x10, 240, 0, 263 },
+{ 0x50, 240, 0, 261 },
+{ 0x30, 240, 0, 262 },
+{ 0x8, 240, 0, 272 },
+{ 0x28, 240, 0, 270 },
+{ 0x18, 240, 0, 271 },
+{ 0x4, 240, 0, 279 },
+{ 0x2, 240, 0, 280 },
+{ 0x1, 240, 0, 281 },
+{ 0x140, 235, 0, 284 },
+{ 0x540, 235, 0, 282 },
+{ 0x340, 235, 0, 283 },
+{ 0xc0, 235, 0, 293 },
+{ 0x2c0, 235, 0, 291 },
+{ 0x1c0, 235, 0, 292 },
+{ 0x20, 235, 0, 302 },
+{ 0xa0, 235, 0, 300 },
+{ 0x60, 235, 0, 301 },
+{ 0x10, 235, 0, 311 },
+{ 0x50, 235, 0, 309 },
+{ 0x30, 235, 0, 310 },
+{ 0x8, 235, 0, 320 },
+{ 0x28, 235, 0, 318 },
+{ 0x18, 235, 0, 319 },
+{ 0x4, 235, 0, 327 },
+{ 0x2, 235, 0, 328 },
+{ 0x1, 235, 0, 329 },
+{ 0x140, 237, 0, 287 },
+{ 0x540, 237, 0, 285 },
+{ 0x340, 237, 0, 286 },
+{ 0xc0, 237, 0, 296 },
+{ 0x2c0, 237, 0, 294 },
+{ 0x1c0, 237, 0, 295 },
+{ 0x20, 237, 0, 305 },
+{ 0xa0, 237, 0, 303 },
+{ 0x60, 237, 0, 304 },
+{ 0x10, 237, 0, 314 },
+{ 0x50, 237, 0, 312 },
+{ 0x30, 237, 0, 313 },
+{ 0x8, 237, 0, 323 },
+{ 0x28, 237, 0, 321 },
+{ 0x18, 237, 0, 322 },
+{ 0x4, 237, 0, 330 },
+{ 0x2, 237, 0, 331 },
+{ 0x1, 237, 0, 332 },
+{ 0x140, 239, 0, 290 },
+{ 0x540, 239, 0, 288 },
+{ 0x340, 239, 0, 289 },
+{ 0xc0, 239, 0, 299 },
+{ 0x2c0, 239, 0, 297 },
+{ 0x1c0, 239, 0, 298 },
+{ 0x20, 239, 0, 308 },
+{ 0xa0, 239, 0, 306 },
+{ 0x60, 239, 0, 307 },
+{ 0x10, 239, 0, 317 },
+{ 0x50, 239, 0, 315 },
+{ 0x30, 239, 0, 316 },
+{ 0x8, 239, 0, 326 },
+{ 0x28, 239, 0, 324 },
+{ 0x18, 239, 0, 325 },
+{ 0x4, 239, 0, 333 },
+{ 0x2, 239, 0, 334 },
+{ 0x1, 239, 0, 335 },
+{ 0x1, 366, 0, 337 },
+{ 0x3, 366, 0, 336 },
+{ 0x2, 372, 0, 338 },
+{ 0x1, 372, 0, 339 },
+{ 0x2, 368, 0, 340 },
+{ 0x1, 368, 0, 341 },
+{ 0x2, 370, 0, 342 },
+{ 0x1, 370, 0, 343 },
+{ 0x2, 374, 0, 344 },
+{ 0x1, 374, 0, 345 },
+{ 0x1, 224, 0, 372 },
+{ 0x5, 224, 0, 370 },
+{ 0x3, 224, 0, 371 },
+{ 0x140, 233, 0, 348 },
+{ 0x540, 233, 0, 346 },
+{ 0x340, 233, 0, 347 },
+{ 0xc0, 233, 0, 360 },
+{ 0x2c0, 233, 0, 358 },
+{ 0x1c0, 233, 0, 359 },
+{ 0x20, 233, 0, 375 },
+{ 0xa0, 233, 0, 373 },
+{ 0x60, 233, 0, 374 },
+{ 0x10, 233, 0, 387 },
+{ 0x50, 233, 0, 385 },
+{ 0x30, 233, 0, 386 },
+{ 0x8, 233, 0, 399 },
+{ 0x28, 233, 0, 397 },
+{ 0x18, 233, 0, 398 },
+{ 0x4, 233, 0, 409 },
+{ 0x2, 233, 0, 410 },
+{ 0x1, 233, 0, 411 },
+{ 0x140, 227, 0, 351 },
+{ 0x540, 227, 0, 349 },
+{ 0x340, 227, 0, 350 },
+{ 0xc0, 227, 0, 363 },
+{ 0x2c0, 227, 0, 361 },
+{ 0x1c0, 227, 0, 362 },
+{ 0x20, 227, 0, 378 },
+{ 0xa0, 227, 0, 376 },
+{ 0x60, 227, 0, 377 },
+{ 0x10, 227, 0, 390 },
+{ 0x50, 227, 0, 388 },
+{ 0x30, 227, 0, 389 },
+{ 0x8, 227, 0, 402 },
+{ 0x28, 227, 0, 400 },
+{ 0x18, 227, 0, 401 },
+{ 0x4, 227, 0, 412 },
+{ 0x2, 227, 0, 413 },
+{ 0x1, 227, 0, 414 },
+{ 0x140, 230, 0, 354 },
+{ 0x540, 230, 0, 352 },
+{ 0x340, 230, 0, 353 },
+{ 0xc0, 230, 0, 366 },
+{ 0x2c0, 230, 0, 364 },
+{ 0x1c0, 230, 0, 365 },
+{ 0x20, 230, 0, 381 },
+{ 0xa0, 230, 0, 379 },
+{ 0x60, 230, 0, 380 },
+{ 0x10, 230, 0, 393 },
+{ 0x50, 230, 0, 391 },
+{ 0x30, 230, 0, 392 },
+{ 0x8, 230, 0, 405 },
+{ 0x28, 230, 0, 403 },
+{ 0x18, 230, 0, 404 },
+{ 0x4, 230, 0, 415 },
+{ 0x2, 230, 0, 416 },
+{ 0x1, 230, 0, 417 },
+{ 0x140, 242, 0, 357 },
+{ 0x540, 242, 0, 355 },
+{ 0x340, 242, 0, 356 },
+{ 0xc0, 242, 0, 369 },
+{ 0x2c0, 242, 0, 367 },
+{ 0x1c0, 242, 0, 368 },
+{ 0x20, 242, 0, 384 },
+{ 0xa0, 242, 0, 382 },
+{ 0x60, 242, 0, 383 },
+{ 0x10, 242, 0, 396 },
+{ 0x50, 242, 0, 394 },
+{ 0x30, 242, 0, 395 },
+{ 0x8, 242, 0, 408 },
+{ 0x28, 242, 0, 406 },
+{ 0x18, 242, 0, 407 },
+{ 0x4, 242, 0, 418 },
+{ 0x2, 242, 0, 419 },
+{ 0x1, 242, 0, 420 },
+{ 0x1, 223, 0, 447 },
+{ 0x5, 223, 0, 445 },
+{ 0x3, 223, 0, 446 },
+{ 0x140, 232, 0, 423 },
+{ 0x540, 232, 0, 421 },
+{ 0x340, 232, 0, 422 },
+{ 0xc0, 232, 0, 435 },
+{ 0x2c0, 232, 0, 433 },
+{ 0x1c0, 232, 0, 434 },
+{ 0x20, 232, 0, 450 },
+{ 0xa0, 232, 0, 448 },
+{ 0x60, 232, 0, 449 },
+{ 0x10, 232, 0, 462 },
+{ 0x50, 232, 0, 460 },
+{ 0x30, 232, 0, 461 },
+{ 0x8, 232, 0, 474 },
+{ 0x28, 232, 0, 472 },
+{ 0x18, 232, 0, 473 },
+{ 0x4, 232, 0, 484 },
+{ 0x2, 232, 0, 485 },
+{ 0x1, 232, 0, 486 },
+{ 0x140, 226, 0, 426 },
+{ 0x540, 226, 0, 424 },
+{ 0x340, 226, 0, 425 },
+{ 0xc0, 226, 0, 438 },
+{ 0x2c0, 226, 0, 436 },
+{ 0x1c0, 226, 0, 437 },
+{ 0x20, 226, 0, 453 },
+{ 0xa0, 226, 0, 451 },
+{ 0x60, 226, 0, 452 },
+{ 0x10, 226, 0, 465 },
+{ 0x50, 226, 0, 463 },
+{ 0x30, 226, 0, 464 },
+{ 0x8, 226, 0, 477 },
+{ 0x28, 226, 0, 475 },
+{ 0x18, 226, 0, 476 },
+{ 0x4, 226, 0, 487 },
+{ 0x2, 226, 0, 488 },
+{ 0x1, 226, 0, 489 },
+{ 0x140, 229, 0, 429 },
+{ 0x540, 229, 0, 427 },
+{ 0x340, 229, 0, 428 },
+{ 0xc0, 229, 0, 441 },
+{ 0x2c0, 229, 0, 439 },
+{ 0x1c0, 229, 0, 440 },
+{ 0x20, 229, 0, 456 },
+{ 0xa0, 229, 0, 454 },
+{ 0x60, 229, 0, 455 },
+{ 0x10, 229, 0, 468 },
+{ 0x50, 229, 0, 466 },
+{ 0x30, 229, 0, 467 },
+{ 0x8, 229, 0, 480 },
+{ 0x28, 229, 0, 478 },
+{ 0x18, 229, 0, 479 },
+{ 0x4, 229, 0, 490 },
+{ 0x2, 229, 0, 491 },
+{ 0x1, 229, 0, 492 },
+{ 0x140, 241, 0, 432 },
+{ 0x540, 241, 0, 430 },
+{ 0x340, 241, 0, 431 },
+{ 0xc0, 241, 0, 444 },
+{ 0x2c0, 241, 0, 442 },
+{ 0x1c0, 241, 0, 443 },
+{ 0x20, 241, 0, 459 },
+{ 0xa0, 241, 0, 457 },
+{ 0x60, 241, 0, 458 },
+{ 0x10, 241, 0, 471 },
+{ 0x50, 241, 0, 469 },
+{ 0x30, 241, 0, 470 },
+{ 0x8, 241, 0, 483 },
+{ 0x28, 241, 0, 481 },
+{ 0x18, 241, 0, 482 },
+{ 0x4, 241, 0, 493 },
+{ 0x2, 241, 0, 494 },
+{ 0x1, 241, 0, 495 },
+{ 0x8, 365, 0, 497 },
+{ 0x18, 365, 0, 496 },
+{ 0x4, 365, 0, 499 },
+{ 0xc, 365, 0, 498 },
+{ 0x2, 365, 0, 506 },
+{ 0x1, 365, 0, 507 },
+{ 0x4, 363, 0, 501 },
+{ 0xc, 363, 0, 500 },
+{ 0x2, 363, 0, 508 },
+{ 0x1, 363, 0, 509 },
+{ 0x4, 361, 0, 503 },
+{ 0xc, 361, 0, 502 },
+{ 0x2, 361, 0, 510 },
+{ 0x1, 361, 0, 511 },
+{ 0x4, 358, 0, 505 },
+{ 0xc, 358, 0, 504 },
+{ 0x2, 358, 0, 512 },
+{ 0x1, 358, 0, 513 },
+{ 0xa00, 222, 0, 528 },
+{ 0x2a00, 222, 0, 526 },
+{ 0x1a00, 222, 0, 527 },
+{ 0x600, 222, 0, 540 },
+{ 0x2600, 222, 0, 516 },
+{ 0xa600, 222, 0, 514 },
+{ 0x6600, 222, 0, 515 },
+{ 0x1600, 222, 0, 538 },
+{ 0xe00, 222, 0, 539 },
+{ 0x100, 222, 0, 552 },
+{ 0x500, 222, 0, 550 },
+{ 0x300, 222, 0, 551 },
+{ 0x80, 222, 0, 555 },
+{ 0x280, 222, 0, 553 },
+{ 0x180, 222, 0, 554 },
+{ 0x40, 222, 0, 567 },
+{ 0x140, 222, 0, 565 },
+{ 0xc0, 222, 0, 566 },
+{ 0x20, 222, 0, 579 },
+{ 0xa0, 222, 0, 577 },
+{ 0x60, 222, 0, 578 },
+{ 0x10, 222, 0, 591 },
+{ 0x50, 222, 0, 589 },
+{ 0x30, 222, 0, 590 },
+{ 0x8, 222, 0, 603 },
+{ 0x28, 222, 0, 601 },
+{ 0x18, 222, 0, 602 },
+{ 0x4, 222, 0, 613 },
+{ 0x2, 222, 0, 614 },
+{ 0x1, 222, 0, 615 },
+{ 0x500, 218, 0, 531 },
+{ 0x1500, 218, 0, 529 },
+{ 0xd00, 218, 0, 530 },
+{ 0x300, 218, 0, 543 },
+{ 0x1300, 218, 0, 519 },
+{ 0x5300, 218, 0, 517 },
+{ 0x3300, 218, 0, 518 },
+{ 0xb00, 218, 0, 541 },
+{ 0x700, 218, 0, 542 },
+{ 0x80, 218, 0, 558 },
+{ 0x280, 218, 0, 556 },
+{ 0x180, 218, 0, 557 },
+{ 0x40, 218, 0, 570 },
+{ 0x140, 218, 0, 568 },
+{ 0xc0, 218, 0, 569 },
+{ 0x20, 218, 0, 582 },
+{ 0xa0, 218, 0, 580 },
+{ 0x60, 218, 0, 581 },
+{ 0x10, 218, 0, 594 },
+{ 0x50, 218, 0, 592 },
+{ 0x30, 218, 0, 593 },
+{ 0x8, 218, 0, 606 },
+{ 0x28, 218, 0, 604 },
+{ 0x18, 218, 0, 605 },
+{ 0x4, 218, 0, 616 },
+{ 0x2, 218, 0, 617 },
+{ 0x1, 218, 0, 618 },
+{ 0x500, 215, 0, 534 },
+{ 0x1500, 215, 0, 532 },
+{ 0xd00, 215, 0, 533 },
+{ 0x300, 215, 0, 546 },
+{ 0x1300, 215, 0, 522 },
+{ 0x5300, 215, 0, 520 },
+{ 0x3300, 215, 0, 521 },
+{ 0xb00, 215, 0, 544 },
+{ 0x700, 215, 0, 545 },
+{ 0x80, 215, 0, 561 },
+{ 0x280, 215, 0, 559 },
+{ 0x180, 215, 0, 560 },
+{ 0x40, 215, 0, 573 },
+{ 0x140, 215, 0, 571 },
+{ 0xc0, 215, 0, 572 },
+{ 0x20, 215, 0, 585 },
+{ 0xa0, 215, 0, 583 },
+{ 0x60, 215, 0, 584 },
+{ 0x10, 215, 0, 597 },
+{ 0x50, 215, 0, 595 },
+{ 0x30, 215, 0, 596 },
+{ 0x8, 215, 0, 609 },
+{ 0x28, 215, 0, 607 },
+{ 0x18, 215, 0, 608 },
+{ 0x4, 215, 0, 619 },
+{ 0x2, 215, 0, 620 },
+{ 0x1, 215, 0, 621 },
+{ 0x500, 211, 0, 537 },
+{ 0x1500, 211, 0, 535 },
+{ 0xd00, 211, 0, 536 },
+{ 0x300, 211, 0, 549 },
+{ 0x1300, 211, 0, 525 },
+{ 0x5300, 211, 0, 523 },
+{ 0x3300, 211, 0, 524 },
+{ 0xb00, 211, 0, 547 },
+{ 0x700, 211, 0, 548 },
+{ 0x80, 211, 0, 564 },
+{ 0x280, 211, 0, 562 },
+{ 0x180, 211, 0, 563 },
+{ 0x40, 211, 0, 576 },
+{ 0x140, 211, 0, 574 },
+{ 0xc0, 211, 0, 575 },
+{ 0x20, 211, 0, 588 },
+{ 0xa0, 211, 0, 586 },
+{ 0x60, 211, 0, 587 },
+{ 0x10, 211, 0, 600 },
+{ 0x50, 211, 0, 598 },
+{ 0x30, 211, 0, 599 },
+{ 0x8, 211, 0, 612 },
+{ 0x28, 211, 0, 610 },
+{ 0x18, 211, 0, 611 },
+{ 0x4, 211, 0, 622 },
+{ 0x2, 211, 0, 623 },
+{ 0x1, 211, 0, 624 },
+{ 0x8, 196, 0, 625 },
+{ 0x4, 196, 0, 626 },
+{ 0x2, 196, 0, 627 },
+{ 0x1, 196, 0, 628 },
+{ 0x2, 134, 0, 631 },
+{ 0xa, 134, 0, 629 },
+{ 0x6, 134, 0, 630 },
+{ 0x1, 134, 0, 637 },
+{ 0x5, 134, 0, 635 },
+{ 0x3, 134, 0, 636 },
+{ 0x2, 133, 0, 634 },
+{ 0xa, 133, 0, 632 },
+{ 0x6, 133, 0, 633 },
+{ 0x1, 133, 0, 640 },
+{ 0x5, 133, 0, 638 },
+{ 0x3, 133, 0, 639 },
+{ 0x4, 398, 0, 641 },
+{ 0x2, 398, 0, 642 },
+{ 0x1, 398, 0, 643 },
+{ 0x4, 397, 0, 644 },
+{ 0x2, 397, 0, 645 },
+{ 0x1, 397, 0, 646 },
+{ 0x4, 396, 0, 647 },
+{ 0x2, 396, 0, 648 },
+{ 0x1, 396, 0, 649 },
+{ 0x4, 395, 0, 650 },
+{ 0x2, 395, 0, 651 },
+{ 0x1, 395, 0, 652 },
+{ 0x2, 92, 0, 655 },
+{ 0xa, 92, 0, 653 },
+{ 0x6, 92, 0, 654 },
+{ 0x1, 92, 0, 670 },
+{ 0x5, 92, 0, 668 },
+{ 0x3, 92, 0, 669 },
+{ 0x2, 96, 0, 658 },
+{ 0xa, 96, 0, 656 },
+{ 0x6, 96, 0, 657 },
+{ 0x1, 96, 0, 673 },
+{ 0x5, 96, 0, 671 },
+{ 0x3, 96, 0, 672 },
+{ 0x2, 95, 0, 661 },
+{ 0xa, 95, 0, 659 },
+{ 0x6, 95, 0, 660 },
+{ 0x1, 95, 0, 676 },
+{ 0x5, 95, 0, 674 },
+{ 0x3, 95, 0, 675 },
+{ 0x2, 94, 0, 664 },
+{ 0xa, 94, 0, 662 },
+{ 0x6, 94, 0, 663 },
+{ 0x1, 94, 0, 679 },
+{ 0x5, 94, 0, 677 },
+{ 0x3, 94, 0, 678 },
+{ 0x2, 93, 0, 667 },
+{ 0xa, 93, 0, 665 },
+{ 0x6, 93, 0, 666 },
+{ 0x1, 93, 0, 682 },
+{ 0x5, 93, 0, 680 },
+{ 0x3, 93, 0, 681 },
+{ 0x4, 359, 0, 686 },
+{ 0xc, 359, 0, 685 },
+{ 0x2, 359, 0, 695 },
+{ 0x1, 359, 0, 696 },
+{ 0x8, 364, 0, 684 },
+{ 0x18, 364, 0, 683 },
+{ 0x4, 364, 0, 688 },
+{ 0xc, 364, 0, 687 },
+{ 0x2, 364, 0, 697 },
+{ 0x1, 364, 0, 698 },
+{ 0x4, 362, 0, 690 },
+{ 0xc, 362, 0, 689 },
+{ 0x2, 362, 0, 699 },
+{ 0x1, 362, 0, 700 },
+{ 0x4, 360, 0, 692 },
+{ 0xc, 360, 0, 691 },
+{ 0x2, 360, 0, 701 },
+{ 0x1, 360, 0, 702 },
+{ 0x4, 357, 0, 694 },
+{ 0xc, 357, 0, 693 },
+{ 0x2, 357, 0, 703 },
+{ 0x1, 357, 0, 704 },
+{ 0xa00, 221, 0, 719 },
+{ 0x2a00, 221, 0, 717 },
+{ 0x1a00, 221, 0, 718 },
+{ 0x600, 221, 0, 731 },
+{ 0x2600, 221, 0, 707 },
+{ 0xa600, 221, 0, 705 },
+{ 0x6600, 221, 0, 706 },
+{ 0x1600, 221, 0, 729 },
+{ 0xe00, 221, 0, 730 },
+{ 0x100, 221, 0, 743 },
+{ 0x500, 221, 0, 741 },
+{ 0x300, 221, 0, 742 },
+{ 0x80, 221, 0, 746 },
+{ 0x280, 221, 0, 744 },
+{ 0x180, 221, 0, 745 },
+{ 0x40, 221, 0, 758 },
+{ 0x140, 221, 0, 756 },
+{ 0xc0, 221, 0, 757 },
+{ 0x20, 221, 0, 770 },
+{ 0xa0, 221, 0, 768 },
+{ 0x60, 221, 0, 769 },
+{ 0x10, 221, 0, 782 },
+{ 0x50, 221, 0, 780 },
+{ 0x30, 221, 0, 781 },
+{ 0x8, 221, 0, 794 },
+{ 0x28, 221, 0, 792 },
+{ 0x18, 221, 0, 793 },
+{ 0x4, 221, 0, 804 },
+{ 0x2, 221, 0, 805 },
+{ 0x1, 221, 0, 806 },
+{ 0x500, 217, 0, 722 },
+{ 0x1500, 217, 0, 720 },
+{ 0xd00, 217, 0, 721 },
+{ 0x300, 217, 0, 734 },
+{ 0x1300, 217, 0, 710 },
+{ 0x5300, 217, 0, 708 },
+{ 0x3300, 217, 0, 709 },
+{ 0xb00, 217, 0, 732 },
+{ 0x700, 217, 0, 733 },
+{ 0x80, 217, 0, 749 },
+{ 0x280, 217, 0, 747 },
+{ 0x180, 217, 0, 748 },
+{ 0x40, 217, 0, 761 },
+{ 0x140, 217, 0, 759 },
+{ 0xc0, 217, 0, 760 },
+{ 0x20, 217, 0, 773 },
+{ 0xa0, 217, 0, 771 },
+{ 0x60, 217, 0, 772 },
+{ 0x10, 217, 0, 785 },
+{ 0x50, 217, 0, 783 },
+{ 0x30, 217, 0, 784 },
+{ 0x8, 217, 0, 797 },
+{ 0x28, 217, 0, 795 },
+{ 0x18, 217, 0, 796 },
+{ 0x4, 217, 0, 807 },
+{ 0x2, 217, 0, 808 },
+{ 0x1, 217, 0, 809 },
+{ 0x500, 214, 0, 725 },
+{ 0x1500, 214, 0, 723 },
+{ 0xd00, 214, 0, 724 },
+{ 0x300, 214, 0, 737 },
+{ 0x1300, 214, 0, 713 },
+{ 0x5300, 214, 0, 711 },
+{ 0x3300, 214, 0, 712 },
+{ 0xb00, 214, 0, 735 },
+{ 0x700, 214, 0, 736 },
+{ 0x80, 214, 0, 752 },
+{ 0x280, 214, 0, 750 },
+{ 0x180, 214, 0, 751 },
+{ 0x40, 214, 0, 764 },
+{ 0x140, 214, 0, 762 },
+{ 0xc0, 214, 0, 763 },
+{ 0x20, 214, 0, 776 },
+{ 0xa0, 214, 0, 774 },
+{ 0x60, 214, 0, 775 },
+{ 0x10, 214, 0, 788 },
+{ 0x50, 214, 0, 786 },
+{ 0x30, 214, 0, 787 },
+{ 0x8, 214, 0, 800 },
+{ 0x28, 214, 0, 798 },
+{ 0x18, 214, 0, 799 },
+{ 0x4, 214, 0, 810 },
+{ 0x2, 214, 0, 811 },
+{ 0x1, 214, 0, 812 },
+{ 0x500, 210, 0, 728 },
+{ 0x1500, 210, 0, 726 },
+{ 0xd00, 210, 0, 727 },
+{ 0x300, 210, 0, 740 },
+{ 0x1300, 210, 0, 716 },
+{ 0x5300, 210, 0, 714 },
+{ 0x3300, 210, 0, 715 },
+{ 0xb00, 210, 0, 738 },
+{ 0x700, 210, 0, 739 },
+{ 0x80, 210, 0, 755 },
+{ 0x280, 210, 0, 753 },
+{ 0x180, 210, 0, 754 },
+{ 0x40, 210, 0, 767 },
+{ 0x140, 210, 0, 765 },
+{ 0xc0, 210, 0, 766 },
+{ 0x20, 210, 0, 779 },
+{ 0xa0, 210, 0, 777 },
+{ 0x60, 210, 0, 778 },
+{ 0x10, 210, 0, 791 },
+{ 0x50, 210, 0, 789 },
+{ 0x30, 210, 0, 790 },
+{ 0x8, 210, 0, 803 },
+{ 0x28, 210, 0, 801 },
+{ 0x18, 210, 0, 802 },
+{ 0x4, 210, 0, 813 },
+{ 0x2, 210, 0, 814 },
+{ 0x1, 210, 0, 815 },
+{ 0x8, 212, 0, 858 },
+{ 0x28, 212, 0, 856 },
+{ 0x18, 212, 0, 857 },
+{ 0x4, 212, 0, 919 },
+{ 0x2, 212, 0, 920 },
+{ 0x1, 212, 0, 921 },
+{ 0xa00, 219, 0, 831 },
+{ 0x2a00, 219, 0, 829 },
+{ 0x1a00, 219, 0, 830 },
+{ 0x600, 219, 0, 843 },
+{ 0x2600, 219, 0, 819 },
+{ 0xa600, 219, 0, 817 },
+{ 0x6600, 219, 0, 818 },
+{ 0x1600, 219, 0, 841 },
+{ 0xe00, 219, 0, 842 },
+{ 0x100, 219, 0, 855 },
+{ 0x500, 219, 0, 853 },
+{ 0x300, 219, 0, 854 },
+{ 0x80, 219, 0, 861 },
+{ 0x280, 219, 0, 859 },
+{ 0x180, 219, 0, 860 },
+{ 0x40, 219, 0, 873 },
+{ 0x140, 219, 0, 871 },
+{ 0xc0, 219, 0, 872 },
+{ 0x20, 219, 0, 885 },
+{ 0xa0, 219, 0, 883 },
+{ 0x60, 219, 0, 884 },
+{ 0x10, 219, 0, 897 },
+{ 0x50, 219, 0, 895 },
+{ 0x30, 219, 0, 896 },
+{ 0x8, 219, 0, 909 },
+{ 0x28, 219, 0, 907 },
+{ 0x18, 219, 0, 908 },
+{ 0x4, 219, 0, 922 },
+{ 0x2, 219, 0, 923 },
+{ 0x1, 219, 1, 924 },
+{ 0x1, 220, 0, 816 },
+{ 0x500, 216, 0, 834 },
+{ 0x1500, 216, 0, 832 },
+{ 0xd00, 216, 0, 833 },
+{ 0x300, 216, 0, 846 },
+{ 0x1300, 216, 0, 822 },
+{ 0x5300, 216, 0, 820 },
+{ 0x3300, 216, 0, 821 },
+{ 0xb00, 216, 0, 844 },
+{ 0x700, 216, 0, 845 },
+{ 0x80, 216, 0, 864 },
+{ 0x280, 216, 0, 862 },
+{ 0x180, 216, 0, 863 },
+{ 0x40, 216, 0, 876 },
+{ 0x140, 216, 0, 874 },
+{ 0xc0, 216, 0, 875 },
+{ 0x20, 216, 0, 888 },
+{ 0xa0, 216, 0, 886 },
+{ 0x60, 216, 0, 887 },
+{ 0x10, 216, 0, 900 },
+{ 0x50, 216, 0, 898 },
+{ 0x30, 216, 0, 899 },
+{ 0x8, 216, 0, 912 },
+{ 0x28, 216, 0, 910 },
+{ 0x18, 216, 0, 911 },
+{ 0x4, 216, 0, 925 },
+{ 0x2, 216, 0, 926 },
+{ 0x1, 216, 0, 927 },
+{ 0x500, 213, 0, 837 },
+{ 0x1500, 213, 0, 835 },
+{ 0xd00, 213, 0, 836 },
+{ 0x300, 213, 0, 849 },
+{ 0x1300, 213, 0, 825 },
+{ 0x5300, 213, 0, 823 },
+{ 0x3300, 213, 0, 824 },
+{ 0xb00, 213, 0, 847 },
+{ 0x700, 213, 0, 848 },
+{ 0x80, 213, 0, 867 },
+{ 0x280, 213, 0, 865 },
+{ 0x180, 213, 0, 866 },
+{ 0x40, 213, 0, 879 },
+{ 0x140, 213, 0, 877 },
+{ 0xc0, 213, 0, 878 },
+{ 0x20, 213, 0, 891 },
+{ 0xa0, 213, 0, 889 },
+{ 0x60, 213, 0, 890 },
+{ 0x10, 213, 0, 903 },
+{ 0x50, 213, 0, 901 },
+{ 0x30, 213, 0, 902 },
+{ 0x8, 213, 0, 915 },
+{ 0x28, 213, 0, 913 },
+{ 0x18, 213, 0, 914 },
+{ 0x4, 213, 0, 928 },
+{ 0x2, 213, 0, 929 },
+{ 0x1, 213, 0, 930 },
+{ 0x500, 209, 0, 840 },
+{ 0x1500, 209, 0, 838 },
+{ 0xd00, 209, 0, 839 },
+{ 0x300, 209, 0, 852 },
+{ 0x1300, 209, 0, 828 },
+{ 0x5300, 209, 0, 826 },
+{ 0x3300, 209, 0, 827 },
+{ 0xb00, 209, 0, 850 },
+{ 0x700, 209, 0, 851 },
+{ 0x80, 209, 0, 870 },
+{ 0x280, 209, 0, 868 },
+{ 0x180, 209, 0, 869 },
+{ 0x40, 209, 0, 882 },
+{ 0x140, 209, 0, 880 },
+{ 0xc0, 209, 0, 881 },
+{ 0x20, 209, 0, 894 },
+{ 0xa0, 209, 0, 892 },
+{ 0x60, 209, 0, 893 },
+{ 0x10, 209, 0, 906 },
+{ 0x50, 209, 0, 904 },
+{ 0x30, 209, 0, 905 },
+{ 0x8, 209, 0, 918 },
+{ 0x28, 209, 0, 916 },
+{ 0x18, 209, 0, 917 },
+{ 0x4, 209, 0, 931 },
+{ 0x2, 209, 0, 932 },
+{ 0x1, 209, 0, 933 },
+{ 0x2, 114, 0, 935 },
+{ 0x1, 114, 0, 936 },
+{ 0x1, 49, 0, 937 },
+{ 0x3, 48, 0, 938 },
+{ 0x1, 384, 0, 939 },
+{ 0x1, 390, 0, 940 },
+{ 0x2, 343, 0, 943 },
+{ 0x1, 343, 0, 944 },
+{ 0x2, 341, 0, 945 },
+{ 0x1, 341, 0, 946 },
+{ 0x1, 340, 0, 947 },
+{ 0x1, 285, 0, 952 },
+{ 0x1, 284, 0, 953 },
+{ 0x1, 283, 0, 954 },
+{ 0x1, 282, 0, 955 },
+{ 0x1, 208, 0, 956 },
+{ 0x1, 207, 0, 957 },
+{ 0x1, 281, 0, 958 },
+{ 0x1, 280, 0, 959 },
+{ 0x1, 279, 0, 960 },
+{ 0x1, 278, 0, 961 },
+{ 0x1, 277, 0, 962 },
+{ 0x1, 276, 0, 963 },
+{ 0x1, 275, 0, 964 },
+{ 0x2, 206, 0, 965 },
+{ 0x1, 206, 0, 966 },
+{ 0x2, 323, 0, 972 },
+{ 0x1, 323, 0, 973 },
+{ 0x1, 274, 0, 974 },
+{ 0x1, 273, 0, 975 },
+{ 0x1, 272, 0, 976 },
+{ 0x1, 271, 0, 977 },
+{ 0x1, 8, 0, 978 },
+{ 0x1, 270, 0, 979 },
+{ 0x1, 269, 0, 980 },
+{ 0x1, 268, 0, 981 },
+{ 0x1, 267, 0, 982 },
+{ 0x1, 345, 0, 983 },
+{ 0x1, 356, 0, 984 },
+{ 0x1, 346, 0, 985 },
+{ 0x1, 379, 0, 986 },
+{ 0x1, 266, 0, 990 },
+{ 0x1, 205, 0, 991 },
+{ 0x1, 135, 0, 994 },
+{ 0x2, 248, 0, 998 },
+{ 0x1, 248, 0, 999 },
+{ 0x1, 194, 0, 1000 },
+{ 0x5, 47, 0, 1002 },
+{ 0x3, 47, 0, 1003 },
+{ 0x5, 46, 0, 1004 },
+{ 0x3, 46, 0, 1005 },
+{ 0x1, 322, 0, 1006 },
+{ 0x1, 330, 0, 1007 },
+{ 0x1, 328, 0, 1008 },
+{ 0x1, 349, 0, 1009 },
+{ 0x1, 329, 0, 1010 },
+{ 0x1, 327, 0, 1011 },
+{ 0x2, 335, 0, 1012 },
+{ 0x1, 335, 0, 1014 },
+{ 0x2, 333, 0, 1013 },
+{ 0x1, 333, 0, 1015 },
+{ 0x2, 353, 0, 1016 },
+{ 0x1, 353, 0, 1019 },
+{ 0x2, 334, 0, 1017 },
+{ 0x1, 334, 0, 1020 },
+{ 0x2, 332, 0, 1018 },
+{ 0x1, 332, 0, 1021 },
+{ 0x1, 295, 0, 1022 },
+{ 0x1, 294, 0, 1023 },
+{ 0x1, 326, 0, 1024 },
+{ 0x1, 317, 0, 1025 },
+{ 0x1, 319, 0, 1026 },
+{ 0x1, 316, 0, 1027 },
+{ 0x1, 318, 0, 1028 },
+{ 0x2, 394, 0, 1029 },
+{ 0x1, 394, 0, 1032 },
+{ 0x2, 393, 0, 1030 },
+{ 0x1, 393, 0, 1033 },
+{ 0x2, 392, 0, 1031 },
+{ 0x1, 392, 0, 1034 },
+{ 0x1, 305, 0, 1035 },
+{ 0x2, 304, 0, 1036 },
+{ 0x1, 304, 0, 1037 },
+{ 0x2, 251, 0, 1038 },
+{ 0x1, 251, 0, 1041 },
+{ 0x2, 250, 0, 1039 },
+{ 0x1, 250, 0, 1042 },
+{ 0x2, 249, 0, 1040 },
+{ 0x1, 249, 0, 1043 },
+{ 0x2, 320, 0, 1044 },
+{ 0x1, 320, 0, 1045 },
+{ 0x2, 321, 0, 1046 },
+{ 0x1, 321, 0, 1047 },
+{ 0xa, 388, 1, 1053 },
+{ 0xa, 389, 0, 1052 },
+{ 0x1a, 388, 1, 1049 },
+{ 0x32, 389, 0, 1048 },
+{ 0x6, 388, 1, 1057 },
+{ 0x6, 389, 0, 1056 },
+{ 0x1, 388, 1, 1063 },
+{ 0x1, 389, 0, 1062 },
+{ 0x9, 388, 1, 1055 },
+{ 0x9, 389, 0, 1054 },
+{ 0x19, 388, 1, 1051 },
+{ 0x31, 389, 0, 1050 },
+{ 0x5, 388, 1, 1059 },
+{ 0x5, 389, 0, 1058 },
+{ 0x3, 388, 1, 1061 },
+{ 0x3, 389, 0, 1060 },
+{ 0xa, 385, 1, 1069 },
+{ 0xa, 386, 0, 1068 },
+{ 0x1a, 385, 1, 1065 },
+{ 0x32, 386, 0, 1064 },
+{ 0x6, 385, 1, 1073 },
+{ 0x6, 386, 0, 1072 },
+{ 0x1, 385, 1, 1079 },
+{ 0x1, 386, 0, 1078 },
+{ 0x9, 385, 1, 1071 },
+{ 0x9, 386, 0, 1070 },
+{ 0x19, 385, 1, 1067 },
+{ 0x31, 386, 0, 1066 },
+{ 0x5, 385, 1, 1075 },
+{ 0x5, 386, 0, 1074 },
+{ 0x3, 385, 1, 1077 },
+{ 0x3, 386, 0, 1076 },
+{ 0x1, 103, 0, 1080 },
+{ 0x1, 102, 0, 1081 },
+{ 0x1, 348, 1, 1083 },
+{ 0x1, 101, 0, 1082 },
+{ 0x2, 352, 1, 1085 },
+{ 0x2, 105, 0, 1084 },
+{ 0x1, 352, 1, 1087 },
+{ 0x1, 105, 0, 1086 },
+{ 0x1, 354, 0, 1088 },
+{ 0x1, 100, 0, 1089 },
+{ 0x2, 99, 0, 1090 },
+{ 0x2, 98, 0, 1091 },
+{ 0x1, 406, 1, 1097 },
+{ 0x1, 204, 0, 992 },
+{ 0x1, 405, 0, 1098 },
+{ 0x1, 404, 1, 1099 },
+{ 0x1, 203, 0, 1001 },
+{ 0x1, 265, 0, 1100 },
+{ 0x1, 264, 1, 1101 },
+{ 0x1, 247, 0, 993 },
+{ 0x1, 263, 0, 1102 },
+{ 0x1, 262, 1, 1103 },
+{ 0x1, 383, 0, 995 },
+{ 0x1, 261, 1, 1104 },
+{ 0x1, 355, 0, 997 },
+{ 0x1, 260, 0, 1105 },
+{ 0x1, 259, 0, 1106 },
+{ 0x1, 258, 1, 1107 },
+{ 0x2, 355, 0, 996 },
+{ 0x10, 257, 0, 1111 },
+{ 0x90, 257, 0, 1109 },
+{ 0x190, 257, 0, 1108 },
+{ 0x50, 257, 0, 1110 },
+{ 0x30, 257, 0, 1113 },
+{ 0x70, 257, 0, 1112 },
+{ 0x8, 257, 0, 1115 },
+{ 0x18, 257, 0, 1114 },
+{ 0x4, 257, 0, 1116 },
+{ 0x1, 257, 0, 1119 },
+{ 0x3, 257, 0, 1118 },
+{ 0x1, 256, 1, 1120 },
+{ 0x2, 257, 0, 1117 },
+{ 0x3, 45, 0, 1121 },
+{ 0x1, 199, 1, 1122 },
+{ 0x1, 200, 1, 987 },
+{ 0x1, 201, 0, 88 },
+{ 0x1, 298, 1, 1123 },
+{ 0x1, 299, 1, 988 },
+{ 0x1, 300, 0, 89 },
+{ 0x1, 33, 1, 1124 },
+{ 0x1, 34, 1, 989 },
+{ 0x1, 35, 0, 90 },
+{ 0x1, 188, 0, 1125 },
+{ 0x4, 399, 0, 1126 },
+{ 0x2, 399, 0, 1127 },
+{ 0x1, 399, 1, 1129 },
+{ 0x1, 400, 0, 1128 },
+{ 0x8, 401, 0, 1130 },
+{ 0x4, 401, 0, 1131 },
+{ 0x1, 401, 1, 1133 },
+{ 0x2, 401, 0, 1132 },
+{ 0x8, 177, 0, 1134 },
+{ 0x4, 177, 0, 1135 },
+{ 0x2, 177, 0, 1136 },
+{ 0x1, 177, 1, 1138 },
+{ 0x1, 178, 0, 1137 },
+{ 0x10, 179, 0, 1139 },
+{ 0x8, 179, 0, 1140 },
+{ 0x4, 179, 0, 1141 },
+{ 0x1, 179, 1, 1143 },
+{ 0x2, 179, 0, 1142 },
+{ 0x220, 149, 0, 1144 },
+{ 0x120, 149, 0, 1145 },
+{ 0xa0, 149, 0, 1146 },
+{ 0x60, 149, 1, 1148 },
+{ 0x4, 150, 0, 1147 },
+{ 0x110, 149, 0, 1154 },
+{ 0x90, 149, 0, 1155 },
+{ 0x50, 149, 0, 1156 },
+{ 0x30, 149, 1, 1158 },
+{ 0x2, 150, 0, 1157 },
+{ 0x8, 149, 0, 1159 },
+{ 0x4, 149, 0, 1160 },
+{ 0x2, 149, 0, 1161 },
+{ 0x1, 149, 1, 1163 },
+{ 0x1, 150, 0, 1162 },
+{ 0x440, 151, 0, 1149 },
+{ 0x240, 151, 0, 1150 },
+{ 0x140, 151, 0, 1151 },
+{ 0xc0, 151, 1, 1153 },
+{ 0x40, 151, 0, 1152 },
+{ 0x220, 151, 0, 1164 },
+{ 0x120, 151, 0, 1165 },
+{ 0xa0, 151, 0, 1166 },
+{ 0x60, 151, 1, 1168 },
+{ 0x20, 151, 0, 1167 },
+{ 0x10, 151, 0, 1169 },
+{ 0x8, 151, 0, 1170 },
+{ 0x4, 151, 0, 1171 },
+{ 0x1, 151, 1, 1173 },
+{ 0x2, 151, 0, 1172 },
+{ 0x8, 173, 0, 1174 },
+{ 0x4, 173, 0, 1175 },
+{ 0x2, 173, 0, 1176 },
+{ 0x1, 173, 1, 1178 },
+{ 0x1, 174, 0, 1177 },
+{ 0x220, 145, 0, 1179 },
+{ 0x120, 145, 0, 1180 },
+{ 0xa0, 145, 0, 1181 },
+{ 0x60, 145, 1, 1183 },
+{ 0x4, 146, 0, 1182 },
+{ 0x110, 145, 0, 1189 },
+{ 0x90, 145, 0, 1190 },
+{ 0x50, 145, 0, 1191 },
+{ 0x30, 145, 1, 1193 },
+{ 0x2, 146, 0, 1192 },
+{ 0x8, 145, 0, 1194 },
+{ 0x4, 145, 0, 1195 },
+{ 0x2, 145, 0, 1196 },
+{ 0x1, 145, 1, 1198 },
+{ 0x1, 146, 0, 1197 },
+{ 0x440, 191, 0, 1184 },
+{ 0x240, 191, 0, 1185 },
+{ 0x140, 191, 0, 1186 },
+{ 0xc0, 191, 1, 1188 },
+{ 0x40, 191, 0, 1187 },
+{ 0x220, 191, 0, 1199 },
+{ 0x120, 191, 0, 1200 },
+{ 0xa0, 191, 0, 1201 },
+{ 0x60, 191, 1, 1203 },
+{ 0x20, 191, 0, 1202 },
+{ 0x10, 191, 0, 1204 },
+{ 0x8, 191, 0, 1205 },
+{ 0x4, 191, 0, 1206 },
+{ 0x1, 191, 1, 1208 },
+{ 0x2, 191, 0, 1207 },
+{ 0x8, 165, 0, 1209 },
+{ 0x4, 165, 0, 1210 },
+{ 0x2, 165, 0, 1211 },
+{ 0x1, 165, 1, 1213 },
+{ 0x1, 166, 0, 1212 },
+{ 0x10, 172, 0, 1214 },
+{ 0x8, 172, 0, 1215 },
+{ 0x4, 172, 0, 1216 },
+{ 0x1, 172, 1, 1218 },
+{ 0x2, 172, 0, 1217 },
+{ 0x220, 136, 0, 1219 },
+{ 0x120, 136, 0, 1220 },
+{ 0xa0, 136, 0, 1221 },
+{ 0x60, 136, 1, 1223 },
+{ 0x4, 137, 0, 1222 },
+{ 0x110, 136, 0, 1244 },
+{ 0x90, 136, 0, 1245 },
+{ 0x50, 136, 0, 1246 },
+{ 0x30, 136, 1, 1248 },
+{ 0x2, 137, 0, 1247 },
+{ 0x8, 136, 0, 1249 },
+{ 0x4, 136, 0, 1250 },
+{ 0x2, 136, 0, 1251 },
+{ 0x1, 136, 1, 1253 },
+{ 0x1, 137, 0, 1252 },
+{ 0x440, 144, 0, 1224 },
+{ 0x240, 144, 0, 1225 },
+{ 0x140, 144, 0, 1226 },
+{ 0xc0, 144, 1, 1228 },
+{ 0x40, 144, 0, 1227 },
+{ 0x220, 144, 0, 1254 },
+{ 0x120, 144, 0, 1255 },
+{ 0xa0, 144, 0, 1256 },
+{ 0x60, 144, 1, 1258 },
+{ 0x20, 144, 0, 1257 },
+{ 0x10, 144, 0, 1259 },
+{ 0x8, 144, 0, 1260 },
+{ 0x4, 144, 0, 1261 },
+{ 0x1, 144, 1, 1263 },
+{ 0x2, 144, 0, 1262 },
+{ 0x440, 107, 0, 1229 },
+{ 0x240, 107, 0, 1230 },
+{ 0x140, 107, 0, 1231 },
+{ 0xc0, 107, 1, 1233 },
+{ 0x40, 107, 0, 1232 },
+{ 0x220, 107, 0, 1264 },
+{ 0x120, 107, 0, 1265 },
+{ 0xa0, 107, 0, 1266 },
+{ 0x60, 107, 1, 1268 },
+{ 0x20, 107, 0, 1267 },
+{ 0x10, 107, 0, 1269 },
+{ 0x8, 107, 0, 1270 },
+{ 0x1, 107, 1, 1273 },
+{ 0x2, 107, 0, 1272 },
+{ 0x440, 152, 1, 1239 },
+{ 0x441, 132, 0, 1234 },
+{ 0x240, 152, 1, 1240 },
+{ 0x241, 132, 0, 1235 },
+{ 0x140, 152, 1, 1241 },
+{ 0x141, 132, 0, 1236 },
+{ 0xc0, 152, 1, 1243 },
+{ 0x40, 152, 1, 1242 },
+{ 0xc1, 132, 1, 1238 },
+{ 0x41, 132, 0, 1237 },
+{ 0x220, 152, 1, 1284 },
+{ 0x221, 132, 0, 1274 },
+{ 0x120, 152, 1, 1285 },
+{ 0x121, 132, 0, 1275 },
+{ 0xa0, 152, 1, 1286 },
+{ 0xa1, 132, 0, 1276 },
+{ 0x60, 152, 1, 1288 },
+{ 0x20, 152, 1, 1287 },
+{ 0x61, 132, 1, 1278 },
+{ 0x21, 132, 0, 1277 },
+{ 0x10, 152, 1, 1289 },
+{ 0x11, 132, 0, 1279 },
+{ 0x8, 152, 1, 1290 },
+{ 0x9, 132, 0, 1280 },
+{ 0x4, 152, 1, 1291 },
+{ 0x5, 132, 0, 1281 },
+{ 0x1, 152, 1, 1293 },
+{ 0x2, 152, 1, 1292 },
+{ 0x3, 132, 1, 1283 },
+{ 0x1, 132, 0, 1282 },
+{ 0x1, 117, 1, 1297 },
+{ 0x1, 118, 0, 1296 },
+{ 0x3, 117, 1, 1295 },
+{ 0x3, 118, 0, 1294 },
+{ 0x1108, 121, 1, 1378 },
+{ 0x1108, 125, 0, 1298 },
+{ 0x908, 121, 1, 1379 },
+{ 0x908, 125, 0, 1299 },
+{ 0x508, 121, 1, 1380 },
+{ 0x508, 125, 0, 1300 },
+{ 0x308, 121, 1, 1382 },
+{ 0x18, 122, 1, 1381 },
+{ 0x308, 125, 1, 1302 },
+{ 0x18, 126, 0, 1301 },
+{ 0x88, 121, 1, 1398 },
+{ 0x88, 125, 0, 1338 },
+{ 0x48, 121, 1, 1399 },
+{ 0x48, 125, 0, 1339 },
+{ 0x28, 121, 1, 1400 },
+{ 0x28, 125, 0, 1340 },
+{ 0x18, 121, 1, 1402 },
+{ 0x8, 122, 1, 1401 },
+{ 0x18, 125, 1, 1342 },
+{ 0x8, 126, 0, 1341 },
+{ 0x884, 121, 1, 1383 },
+{ 0x442, 123, 1, 1328 },
+{ 0x884, 125, 1, 1313 },
+{ 0x442, 127, 0, 1303 },
+{ 0x484, 121, 1, 1384 },
+{ 0x242, 123, 1, 1329 },
+{ 0x484, 125, 1, 1314 },
+{ 0x242, 127, 0, 1304 },
+{ 0x284, 121, 1, 1385 },
+{ 0x142, 123, 1, 1330 },
+{ 0x284, 125, 1, 1315 },
+{ 0x142, 127, 0, 1305 },
+{ 0x184, 121, 1, 1387 },
+{ 0xc, 122, 1, 1386 },
+{ 0xc2, 123, 1, 1332 },
+{ 0x6, 124, 1, 1331 },
+{ 0x184, 125, 1, 1317 },
+{ 0xc, 126, 1, 1316 },
+{ 0xc2, 127, 1, 1307 },
+{ 0x6, 128, 0, 1306 },
+{ 0x44, 121, 1, 1403 },
+{ 0x22, 123, 1, 1368 },
+{ 0x44, 125, 1, 1353 },
+{ 0x22, 127, 0, 1343 },
+{ 0x24, 121, 1, 1404 },
+{ 0x12, 123, 1, 1369 },
+{ 0x24, 125, 1, 1354 },
+{ 0x12, 127, 0, 1344 },
+{ 0x14, 121, 1, 1405 },
+{ 0xa, 123, 1, 1370 },
+{ 0x14, 125, 1, 1355 },
+{ 0xa, 127, 0, 1345 },
+{ 0xc, 121, 1, 1407 },
+{ 0x4, 122, 1, 1406 },
+{ 0x6, 123, 1, 1372 },
+{ 0x2, 124, 1, 1371 },
+{ 0xc, 125, 1, 1357 },
+{ 0x4, 126, 1, 1356 },
+{ 0x6, 127, 1, 1347 },
+{ 0x2, 128, 0, 1346 },
+{ 0x442, 121, 1, 1388 },
+{ 0x221, 123, 1, 1333 },
+{ 0x442, 125, 1, 1318 },
+{ 0x221, 127, 0, 1308 },
+{ 0x242, 121, 1, 1389 },
+{ 0x121, 123, 1, 1334 },
+{ 0x242, 125, 1, 1319 },
+{ 0x121, 127, 0, 1309 },
+{ 0x142, 121, 1, 1390 },
+{ 0xa1, 123, 1, 1335 },
+{ 0x142, 125, 1, 1320 },
+{ 0xa1, 127, 0, 1310 },
+{ 0xc2, 121, 1, 1392 },
+{ 0x6, 122, 1, 1391 },
+{ 0x61, 123, 1, 1337 },
+{ 0x3, 124, 1, 1336 },
+{ 0xc2, 125, 1, 1322 },
+{ 0x6, 126, 1, 1321 },
+{ 0x61, 127, 1, 1312 },
+{ 0x3, 128, 0, 1311 },
+{ 0x22, 121, 1, 1408 },
+{ 0x11, 123, 1, 1373 },
+{ 0x22, 125, 1, 1358 },
+{ 0x11, 127, 0, 1348 },
+{ 0x12, 121, 1, 1409 },
+{ 0x9, 123, 1, 1374 },
+{ 0x12, 125, 1, 1359 },
+{ 0x9, 127, 0, 1349 },
+{ 0xa, 121, 1, 1410 },
+{ 0x5, 123, 1, 1375 },
+{ 0xa, 125, 1, 1360 },
+{ 0x5, 127, 0, 1350 },
+{ 0x6, 121, 1, 1412 },
+{ 0x2, 122, 1, 1411 },
+{ 0x3, 123, 1, 1377 },
+{ 0x1, 124, 1, 1376 },
+{ 0x6, 125, 1, 1362 },
+{ 0x2, 126, 1, 1361 },
+{ 0x3, 127, 1, 1352 },
+{ 0x1, 128, 0, 1351 },
+{ 0x221, 121, 1, 1393 },
+{ 0x221, 125, 0, 1323 },
+{ 0x121, 121, 1, 1394 },
+{ 0x121, 125, 0, 1324 },
+{ 0xa1, 121, 1, 1395 },
+{ 0xa1, 125, 0, 1325 },
+{ 0x61, 121, 1, 1397 },
+{ 0x3, 122, 1, 1396 },
+{ 0x61, 125, 1, 1327 },
+{ 0x3, 126, 0, 1326 },
+{ 0x11, 121, 1, 1413 },
+{ 0x11, 125, 0, 1363 },
+{ 0x9, 121, 1, 1414 },
+{ 0x9, 125, 0, 1364 },
+{ 0x5, 121, 1, 1415 },
+{ 0x5, 125, 0, 1365 },
+{ 0x3, 121, 1, 1417 },
+{ 0x1, 122, 1, 1416 },
+{ 0x3, 125, 1, 1367 },
+{ 0x1, 126, 0, 1366 },
+{ 0x442, 163, 0, 1418 },
+{ 0x242, 163, 0, 1419 },
+{ 0x142, 163, 0, 1420 },
+{ 0xc2, 163, 1, 1422 },
+{ 0x6, 164, 1, 1421 },
+{ 0x1, 391, 0, 941 },
+{ 0x22, 163, 0, 1428 },
+{ 0x12, 163, 0, 1429 },
+{ 0xa, 163, 0, 1430 },
+{ 0x6, 163, 1, 1432 },
+{ 0x2, 164, 1, 1431 },
+{ 0x2, 324, 0, 970 },
+{ 0x221, 163, 0, 1423 },
+{ 0x121, 163, 0, 1424 },
+{ 0xa1, 163, 0, 1425 },
+{ 0x61, 163, 1, 1427 },
+{ 0x3, 164, 1, 1426 },
+{ 0x1, 387, 0, 942 },
+{ 0x11, 163, 0, 1433 },
+{ 0x9, 163, 0, 1434 },
+{ 0x5, 163, 0, 1435 },
+{ 0x3, 163, 1, 1437 },
+{ 0x1, 164, 1, 1436 },
+{ 0x1, 324, 0, 971 },
+{ 0x4, 169, 0, 1438 },
+{ 0x1, 169, 0, 1440 },
+{ 0x1, 176, 0, 1441 },
+{ 0x1, 175, 1, 1442 },
+{ 0x2, 169, 0, 1439 },
+{ 0x1, 154, 0, 1443 },
+{ 0x880, 160, 0, 1444 },
+{ 0x480, 160, 0, 1445 },
+{ 0x280, 160, 0, 1446 },
+{ 0x180, 160, 1, 1448 },
+{ 0x80, 161, 0, 1447 },
+{ 0x440, 160, 1, 1459 },
+{ 0x88, 162, 0, 1449 },
+{ 0x240, 160, 1, 1460 },
+{ 0x48, 162, 0, 1450 },
+{ 0x140, 160, 1, 1461 },
+{ 0x28, 162, 0, 1451 },
+{ 0xc0, 160, 1, 1463 },
+{ 0x40, 161, 1, 1462 },
+{ 0x18, 162, 1, 1453 },
+{ 0x8, 162, 0, 1452 },
+{ 0x220, 160, 1, 1464 },
+{ 0x44, 162, 0, 1454 },
+{ 0x120, 160, 1, 1465 },
+{ 0x24, 162, 0, 1455 },
+{ 0xa0, 160, 1, 1466 },
+{ 0x14, 162, 0, 1456 },
+{ 0x60, 160, 1, 1468 },
+{ 0x20, 161, 1, 1467 },
+{ 0xc, 162, 1, 1458 },
+{ 0x4, 162, 0, 1457 },
+{ 0x110, 160, 0, 1469 },
+{ 0x90, 160, 0, 1470 },
+{ 0x50, 160, 0, 1471 },
+{ 0x30, 160, 1, 1473 },
+{ 0x10, 161, 1, 1472 },
+{ 0x1, 342, 0, 934 },
+{ 0x88, 160, 0, 1474 },
+{ 0x48, 160, 0, 1475 },
+{ 0x28, 160, 0, 1476 },
+{ 0x18, 160, 1, 1478 },
+{ 0x8, 161, 1, 1477 },
+{ 0xc, 325, 0, 967 },
+{ 0x44, 160, 1, 1489 },
+{ 0x22, 162, 0, 1479 },
+{ 0x24, 160, 1, 1490 },
+{ 0x12, 162, 0, 1480 },
+{ 0x14, 160, 1, 1491 },
+{ 0xa, 162, 0, 1481 },
+{ 0xc, 160, 1, 1493 },
+{ 0x4, 161, 1, 1492 },
+{ 0x6, 162, 1, 1483 },
+{ 0x2, 162, 1, 1482 },
+{ 0x6, 325, 0, 968 },
+{ 0x22, 160, 1, 1494 },
+{ 0x11, 162, 0, 1484 },
+{ 0x12, 160, 1, 1495 },
+{ 0x9, 162, 0, 1485 },
+{ 0xa, 160, 1, 1496 },
+{ 0x5, 162, 0, 1486 },
+{ 0x6, 160, 1, 1498 },
+{ 0x2, 161, 1, 1497 },
+{ 0x3, 162, 1, 1488 },
+{ 0x1, 162, 1, 1487 },
+{ 0x3, 325, 0, 969 },
+{ 0x11, 160, 0, 1499 },
+{ 0x9, 160, 0, 1500 },
+{ 0x5, 160, 0, 1501 },
+{ 0x3, 160, 1, 1503 },
+{ 0x1, 161, 0, 1502 },
+{ 0x8, 156, 0, 1504 },
+{ 0x4, 156, 0, 1505 },
+{ 0x2, 156, 0, 1506 },
+{ 0x1, 156, 1, 1508 },
+{ 0x1, 157, 1, 1507 },
+{ 0x1, 289, 0, 948 },
+{ 0x8, 158, 0, 1509 },
+{ 0x4, 158, 0, 1510 },
+{ 0x2, 158, 0, 1511 },
+{ 0x1, 158, 1, 1513 },
+{ 0x1, 159, 1, 1512 },
+{ 0x1, 288, 0, 949 },
+{ 0x8, 167, 0, 1514 },
+{ 0x4, 167, 0, 1515 },
+{ 0x2, 167, 0, 1516 },
+{ 0x1, 167, 1, 1518 },
+{ 0x1, 168, 1, 1517 },
+{ 0x1, 287, 0, 950 },
+{ 0x8, 170, 0, 1519 },
+{ 0x4, 170, 0, 1520 },
+{ 0x2, 170, 0, 1521 },
+{ 0x1, 170, 1, 1523 },
+{ 0x1, 171, 1, 1522 },
+{ 0x1, 286, 0, 951 },
+{ 0x8, 182, 0, 1524 },
+{ 0x4, 182, 0, 1525 },
+{ 0x2, 182, 0, 1526 },
+{ 0x1, 182, 1, 1528 },
+{ 0x1, 183, 0, 1527 },
+{ 0x8, 180, 0, 1529 },
+{ 0x4, 180, 0, 1530 },
+{ 0x2, 180, 0, 1531 },
+{ 0x1, 180, 1, 1533 },
+{ 0x1, 181, 0, 1532 },
+{ 0x1, 198, 0, 1534 },
+{ 0x1, 297, 0, 1535 },
+{ 0x1, 32, 0, 1536 },
+{ 0x8, 115, 0, 1537 },
+{ 0x4, 115, 0, 1538 },
+{ 0x2, 115, 0, 1539 },
+{ 0x1, 115, 1, 1541 },
+{ 0x1, 116, 0, 1540 },
+{ 0x8, 119, 0, 1542 },
+{ 0x4, 119, 0, 1543 },
+{ 0x2, 119, 0, 1544 },
+{ 0x1, 119, 1, 1546 },
+{ 0x1, 120, 0, 1545 },
+{ 0x8, 189, 0, 1547 },
+{ 0x4, 189, 0, 1548 },
+{ 0x2, 189, 0, 1549 },
+{ 0x1, 189, 1, 1551 },
+{ 0x1, 190, 0, 1550 },
+{ 0x1, 131, 0, 1552 },
+{ 0x442, 129, 0, 1553 },
+{ 0x242, 129, 0, 1554 },
+{ 0x142, 129, 0, 1555 },
+{ 0xc2, 129, 1, 1557 },
+{ 0x6, 130, 0, 1556 },
+{ 0x22, 129, 0, 1563 },
+{ 0x12, 129, 0, 1564 },
+{ 0xa, 129, 0, 1565 },
+{ 0x6, 129, 1, 1567 },
+{ 0x2, 130, 1, 1566 },
+{ 0x1, 99, 0, 1092 },
+{ 0x221, 129, 0, 1558 },
+{ 0x121, 129, 0, 1559 },
+{ 0xa1, 129, 0, 1560 },
+{ 0x61, 129, 1, 1562 },
+{ 0x3, 130, 0, 1561 },
+{ 0x11, 129, 0, 1568 },
+{ 0x9, 129, 0, 1569 },
+{ 0x5, 129, 0, 1570 },
+{ 0x3, 129, 1, 1572 },
+{ 0x1, 130, 1, 1571 },
+{ 0x1, 98, 0, 1093 },
+{ 0x1, 195, 0, 1573 },
+{ 0x1, 153, 0, 1574 },
+{ 0x1, 113, 0, 1575 },
+{ 0x1, 112, 0, 1576 },
+{ 0x4, 192, 0, 1577 },
+{ 0x2, 192, 0, 1578 },
+{ 0x1, 192, 0, 1579 },
+{ 0x1, 155, 0, 1580 },
+{ 0x2, 193, 0, 1581 },
+{ 0x1, 193, 0, 1582 },
+{ 0x4, 143, 0, 1583 },
+{ 0x2, 143, 0, 1584 },
+{ 0x1, 143, 0, 1585 },
{ 0x4, 140, 0, 1586 },
+{ 0x1, 148, 0, 1589 },
+{ 0x1, 147, 1, 1590 },
{ 0x2, 140, 0, 1587 },
-{ 0x1, 140, 1, 1589 },
-{ 0x1, 141, 1, 1588 },
-{ 0x1, 370, 0, 1075 },
-{ 0x8, 185, 0, 1590 },
-{ 0x4, 185, 0, 1591 },
-{ 0x2, 185, 0, 1592 },
-{ 0x1, 185, 1, 1594 },
-{ 0x1, 186, 0, 1593 },
-{ 0x8, 183, 0, 1595 },
-{ 0x4, 183, 0, 1596 },
-{ 0x2, 183, 0, 1597 },
-{ 0x1, 183, 1, 1599 },
-{ 0x1, 184, 0, 1598 },
-{ 0x8, 43, 0, 1604 },
-{ 0x18, 43, 0, 1600 },
-{ 0x4, 43, 0, 1605 },
-{ 0xc, 43, 0, 1601 },
-{ 0x2, 43, 0, 1606 },
-{ 0x6, 43, 0, 1602 },
-{ 0x1, 43, 0, 1607 },
-{ 0x3, 43, 0, 1603 },
-{ 0x51, 29, 0, 1609 },
-{ 0xd1, 29, 0, 1608 },
-{ 0x31, 29, 1, 1619 },
-{ 0x11, 30, 0, 1618 },
-{ 0x71, 29, 1, 1617 },
-{ 0x31, 30, 0, 1616 },
-{ 0x29, 29, 0, 1611 },
-{ 0x69, 29, 0, 1610 },
-{ 0x19, 29, 1, 1623 },
-{ 0x9, 30, 0, 1622 },
-{ 0x39, 29, 1, 1621 },
-{ 0x19, 30, 0, 1620 },
-{ 0x15, 29, 0, 1613 },
-{ 0x35, 29, 0, 1612 },
-{ 0xd, 29, 1, 1627 },
-{ 0x5, 30, 0, 1626 },
-{ 0x1d, 29, 1, 1625 },
-{ 0xd, 30, 0, 1624 },
-{ 0xb, 29, 0, 1615 },
-{ 0x1b, 29, 0, 1614 },
-{ 0x7, 29, 1, 1631 },
-{ 0x3, 30, 0, 1630 },
-{ 0xf, 29, 1, 1629 },
-{ 0x7, 30, 0, 1628 },
-{ 0xa2, 27, 0, 1633 },
-{ 0x1a2, 27, 0, 1632 },
-{ 0x62, 27, 1, 1643 },
-{ 0x22, 28, 0, 1642 },
-{ 0xe2, 27, 1, 1641 },
-{ 0x62, 28, 0, 1640 },
-{ 0x52, 27, 0, 1635 },
-{ 0xd2, 27, 0, 1634 },
-{ 0x32, 27, 1, 1647 },
-{ 0x12, 28, 0, 1646 },
-{ 0x72, 27, 1, 1645 },
-{ 0x32, 28, 0, 1644 },
-{ 0x2a, 27, 0, 1637 },
-{ 0x6a, 27, 0, 1636 },
-{ 0x1a, 27, 1, 1651 },
-{ 0xa, 28, 0, 1650 },
-{ 0x3a, 27, 1, 1649 },
-{ 0x1a, 28, 0, 1648 },
-{ 0x16, 27, 0, 1639 },
-{ 0x36, 27, 0, 1638 },
-{ 0xe, 27, 1, 1655 },
-{ 0x6, 28, 0, 1654 },
-{ 0x1e, 27, 1, 1653 },
-{ 0xe, 28, 0, 1652 },
-{ 0x51, 27, 0, 1657 },
-{ 0xd1, 27, 0, 1656 },
-{ 0x31, 27, 1, 1667 },
-{ 0x11, 28, 0, 1666 },
-{ 0x71, 27, 1, 1665 },
-{ 0x31, 28, 0, 1664 },
-{ 0x29, 27, 0, 1659 },
-{ 0x69, 27, 0, 1658 },
-{ 0x19, 27, 1, 1671 },
-{ 0x9, 28, 0, 1670 },
-{ 0x39, 27, 1, 1669 },
-{ 0x19, 28, 0, 1668 },
-{ 0x15, 27, 0, 1661 },
-{ 0x35, 27, 0, 1660 },
-{ 0xd, 27, 1, 1675 },
-{ 0x5, 28, 0, 1674 },
-{ 0x1d, 27, 1, 1673 },
-{ 0xd, 28, 0, 1672 },
-{ 0xb, 27, 0, 1663 },
-{ 0x1b, 27, 0, 1662 },
-{ 0x7, 27, 1, 1679 },
-{ 0x3, 28, 0, 1678 },
-{ 0xf, 27, 1, 1677 },
-{ 0x7, 28, 0, 1676 },
-{ 0x51, 25, 0, 1681 },
-{ 0xd1, 25, 0, 1680 },
-{ 0x31, 25, 1, 1691 },
-{ 0x11, 26, 0, 1690 },
-{ 0x71, 25, 1, 1689 },
-{ 0x31, 26, 0, 1688 },
-{ 0x29, 25, 0, 1683 },
-{ 0x69, 25, 0, 1682 },
-{ 0x19, 25, 1, 1695 },
-{ 0x9, 26, 0, 1694 },
-{ 0x39, 25, 1, 1693 },
-{ 0x19, 26, 0, 1692 },
-{ 0x15, 25, 0, 1685 },
-{ 0x35, 25, 0, 1684 },
-{ 0xd, 25, 1, 1699 },
-{ 0x5, 26, 0, 1698 },
-{ 0x1d, 25, 1, 1697 },
-{ 0xd, 26, 0, 1696 },
-{ 0xb, 25, 0, 1687 },
-{ 0x1b, 25, 0, 1686 },
-{ 0x7, 25, 1, 1703 },
-{ 0x3, 26, 0, 1702 },
-{ 0xf, 25, 1, 1701 },
-{ 0x7, 26, 0, 1700 },
-{ 0xa2, 23, 0, 1705 },
-{ 0x1a2, 23, 0, 1704 },
-{ 0x62, 23, 1, 1715 },
-{ 0x22, 24, 0, 1714 },
-{ 0xe2, 23, 1, 1713 },
-{ 0x62, 24, 0, 1712 },
-{ 0x52, 23, 0, 1707 },
-{ 0xd2, 23, 0, 1706 },
-{ 0x32, 23, 1, 1719 },
-{ 0x12, 24, 0, 1718 },
-{ 0x72, 23, 1, 1717 },
-{ 0x32, 24, 0, 1716 },
-{ 0x2a, 23, 0, 1709 },
-{ 0x6a, 23, 0, 1708 },
-{ 0x1a, 23, 1, 1723 },
-{ 0xa, 24, 0, 1722 },
-{ 0x3a, 23, 1, 1721 },
-{ 0x1a, 24, 0, 1720 },
-{ 0x16, 23, 0, 1711 },
-{ 0x36, 23, 0, 1710 },
-{ 0xe, 23, 1, 1727 },
-{ 0x6, 24, 0, 1726 },
-{ 0x1e, 23, 1, 1725 },
-{ 0xe, 24, 0, 1724 },
-{ 0x51, 23, 0, 1729 },
-{ 0xd1, 23, 0, 1728 },
-{ 0x31, 23, 1, 1739 },
-{ 0x11, 24, 0, 1738 },
-{ 0x71, 23, 1, 1737 },
-{ 0x31, 24, 0, 1736 },
-{ 0x29, 23, 0, 1731 },
-{ 0x69, 23, 0, 1730 },
-{ 0x19, 23, 1, 1743 },
-{ 0x9, 24, 0, 1742 },
-{ 0x39, 23, 1, 1741 },
-{ 0x19, 24, 0, 1740 },
-{ 0x15, 23, 0, 1733 },
-{ 0x35, 23, 0, 1732 },
-{ 0xd, 23, 1, 1747 },
-{ 0x5, 24, 0, 1746 },
-{ 0x1d, 23, 1, 1745 },
-{ 0xd, 24, 0, 1744 },
-{ 0xb, 23, 0, 1735 },
-{ 0x1b, 23, 0, 1734 },
-{ 0x7, 23, 1, 1751 },
-{ 0x3, 24, 0, 1750 },
-{ 0xf, 23, 1, 1749 },
-{ 0x7, 24, 0, 1748 },
-{ 0x51, 21, 1, 1777 },
-{ 0x50, 21, 0, 1753 },
-{ 0xd1, 21, 1, 1776 },
-{ 0xd0, 21, 0, 1752 },
-{ 0x31, 21, 1, 1787 },
-{ 0x30, 21, 1, 1763 },
-{ 0x11, 22, 1, 1786 },
-{ 0x10, 22, 0, 1762 },
-{ 0x71, 21, 1, 1785 },
-{ 0x70, 21, 1, 1761 },
-{ 0x31, 22, 1, 1784 },
-{ 0x30, 22, 0, 1760 },
-{ 0x29, 21, 1, 1779 },
-{ 0x28, 21, 0, 1755 },
-{ 0x69, 21, 1, 1778 },
-{ 0x68, 21, 0, 1754 },
-{ 0x19, 21, 1, 1791 },
-{ 0x18, 21, 1, 1767 },
-{ 0x9, 22, 1, 1790 },
-{ 0x8, 22, 0, 1766 },
-{ 0x39, 21, 1, 1789 },
-{ 0x38, 21, 1, 1765 },
-{ 0x19, 22, 1, 1788 },
-{ 0x18, 22, 0, 1764 },
-{ 0x15, 21, 1, 1781 },
-{ 0x14, 21, 0, 1757 },
-{ 0x35, 21, 1, 1780 },
-{ 0x34, 21, 0, 1756 },
-{ 0xd, 21, 1, 1795 },
-{ 0xc, 21, 1, 1771 },
-{ 0x5, 22, 1, 1794 },
-{ 0x4, 22, 0, 1770 },
-{ 0x1d, 21, 1, 1793 },
-{ 0x1c, 21, 1, 1769 },
-{ 0xd, 22, 1, 1792 },
-{ 0xc, 22, 0, 1768 },
-{ 0xb, 21, 1, 1783 },
-{ 0xa, 21, 0, 1759 },
-{ 0x1b, 21, 1, 1782 },
-{ 0x1a, 21, 0, 1758 },
-{ 0x7, 21, 1, 1799 },
-{ 0x6, 21, 1, 1775 },
-{ 0x3, 22, 1, 1798 },
-{ 0x2, 22, 0, 1774 },
-{ 0xf, 21, 1, 1797 },
-{ 0xe, 21, 1, 1773 },
-{ 0x7, 22, 1, 1796 },
-{ 0x6, 22, 0, 1772 },
-{ 0x8, 20, 0, 1801 },
-{ 0x18, 20, 0, 1800 },
-{ 0x1, 20, 1, 1805 },
-{ 0x2, 20, 0, 1804 },
-{ 0x3, 20, 1, 1803 },
-{ 0x4, 20, 0, 1802 },
-{ 0x1, 287, 0, 1806 },
-{ 0x14, 42, 0, 1809 },
-{ 0x34, 42, 0, 1807 },
-{ 0xc, 42, 0, 1810 },
-{ 0x1c, 42, 0, 1808 },
-{ 0x2, 42, 0, 1813 },
-{ 0x6, 42, 0, 1811 },
-{ 0x1, 42, 0, 1814 },
-{ 0x3, 42, 0, 1812 },
-{ 0x51, 18, 0, 1816 },
-{ 0xd1, 18, 0, 1815 },
-{ 0x31, 18, 1, 1826 },
-{ 0x11, 19, 0, 1825 },
-{ 0x71, 18, 1, 1824 },
-{ 0x31, 19, 0, 1823 },
-{ 0x29, 18, 0, 1818 },
-{ 0x69, 18, 0, 1817 },
-{ 0x19, 18, 1, 1830 },
-{ 0x9, 19, 0, 1829 },
-{ 0x39, 18, 1, 1828 },
-{ 0x19, 19, 0, 1827 },
-{ 0x15, 18, 0, 1820 },
-{ 0x35, 18, 0, 1819 },
-{ 0xd, 18, 1, 1834 },
-{ 0x5, 19, 0, 1833 },
-{ 0x1d, 18, 1, 1832 },
-{ 0xd, 19, 0, 1831 },
-{ 0xb, 18, 0, 1822 },
-{ 0x1b, 18, 0, 1821 },
-{ 0x7, 18, 1, 1838 },
-{ 0x3, 19, 0, 1837 },
-{ 0xf, 18, 1, 1836 },
-{ 0x7, 19, 0, 1835 },
-{ 0x1, 31, 0, 1839 },
-{ 0x1, 103, 0, 1840 },
-{ 0x2, 44, 0, 1841 },
-{ 0x1, 44, 0, 1842 },
-{ 0x1, 335, 0, 1843 },
-{ 0x2, 51, 0, 1844 },
-{ 0x1, 51, 0, 1845 },
-{ 0x1, 96, 0, 1846 },
-{ 0x51, 16, 0, 1848 },
-{ 0xd1, 16, 0, 1847 },
-{ 0x31, 16, 1, 1858 },
-{ 0x11, 17, 0, 1857 },
-{ 0x71, 16, 1, 1856 },
-{ 0x31, 17, 0, 1855 },
-{ 0x29, 16, 0, 1850 },
-{ 0x69, 16, 0, 1849 },
-{ 0x19, 16, 1, 1862 },
-{ 0x9, 17, 0, 1861 },
-{ 0x39, 16, 1, 1860 },
-{ 0x19, 17, 0, 1859 },
-{ 0x15, 16, 0, 1852 },
-{ 0x35, 16, 0, 1851 },
-{ 0xd, 16, 1, 1866 },
-{ 0x5, 17, 0, 1865 },
-{ 0x1d, 16, 1, 1864 },
-{ 0xd, 17, 0, 1863 },
-{ 0xb, 16, 0, 1854 },
-{ 0x1b, 16, 0, 1853 },
-{ 0x7, 16, 1, 1870 },
-{ 0x3, 17, 0, 1869 },
-{ 0xf, 16, 1, 1868 },
-{ 0x7, 17, 0, 1867 },
-{ 0xa20, 14, 0, 1872 },
-{ 0x1a20, 14, 0, 1871 },
-{ 0x620, 14, 1, 1882 },
-{ 0x220, 15, 0, 1881 },
-{ 0xe20, 14, 1, 1880 },
-{ 0x620, 15, 0, 1879 },
-{ 0x520, 14, 0, 1874 },
-{ 0xd20, 14, 0, 1873 },
-{ 0x320, 14, 1, 1886 },
-{ 0x120, 15, 0, 1885 },
-{ 0x720, 14, 1, 1884 },
-{ 0x320, 15, 0, 1883 },
-{ 0x2a0, 14, 0, 1876 },
-{ 0x6a0, 14, 0, 1875 },
-{ 0x1a0, 14, 1, 1890 },
-{ 0xa0, 15, 0, 1889 },
-{ 0x3a0, 14, 1, 1888 },
-{ 0x1a0, 15, 0, 1887 },
-{ 0x160, 14, 0, 1878 },
-{ 0x360, 14, 0, 1877 },
-{ 0xe0, 14, 1, 1894 },
-{ 0x60, 15, 0, 1893 },
-{ 0x1e0, 14, 1, 1892 },
-{ 0xe0, 15, 0, 1891 },
-{ 0x51, 14, 1, 1920 },
-{ 0x50, 14, 0, 1896 },
-{ 0xd1, 14, 1, 1919 },
-{ 0xd0, 14, 0, 1895 },
-{ 0x31, 14, 1, 1930 },
-{ 0x30, 14, 1, 1906 },
-{ 0x11, 15, 1, 1929 },
-{ 0x10, 15, 0, 1905 },
-{ 0x71, 14, 1, 1928 },
-{ 0x70, 14, 1, 1904 },
-{ 0x31, 15, 1, 1927 },
-{ 0x30, 15, 0, 1903 },
-{ 0x29, 14, 1, 1922 },
-{ 0x28, 14, 0, 1898 },
-{ 0x69, 14, 1, 1921 },
-{ 0x68, 14, 0, 1897 },
-{ 0x19, 14, 1, 1934 },
-{ 0x18, 14, 1, 1910 },
-{ 0x9, 15, 1, 1933 },
-{ 0x8, 15, 0, 1909 },
-{ 0x39, 14, 1, 1932 },
-{ 0x38, 14, 1, 1908 },
-{ 0x19, 15, 1, 1931 },
-{ 0x18, 15, 0, 1907 },
-{ 0x15, 14, 1, 1924 },
-{ 0x14, 14, 0, 1900 },
-{ 0x35, 14, 1, 1923 },
-{ 0x34, 14, 0, 1899 },
-{ 0xd, 14, 1, 1938 },
-{ 0xc, 14, 1, 1914 },
-{ 0x5, 15, 1, 1937 },
-{ 0x4, 15, 0, 1913 },
-{ 0x1d, 14, 1, 1936 },
-{ 0x1c, 14, 1, 1912 },
-{ 0xd, 15, 1, 1935 },
-{ 0xc, 15, 0, 1911 },
-{ 0xb, 14, 1, 1926 },
-{ 0xa, 14, 0, 1902 },
-{ 0x1b, 14, 1, 1925 },
-{ 0x1a, 14, 0, 1901 },
-{ 0x7, 14, 1, 1942 },
-{ 0x6, 14, 1, 1918 },
-{ 0x3, 15, 1, 1941 },
-{ 0x2, 15, 0, 1917 },
-{ 0xf, 14, 1, 1940 },
-{ 0xe, 14, 1, 1916 },
-{ 0x7, 15, 1, 1939 },
-{ 0x6, 15, 0, 1915 },
-{ 0x8, 13, 0, 1944 },
-{ 0x18, 13, 0, 1943 },
-{ 0x1, 13, 1, 1948 },
-{ 0x2, 13, 0, 1947 },
-{ 0x3, 13, 1, 1946 },
-{ 0x4, 13, 0, 1945 },
-{ 0x1, 84, 1, 2024 },
-{ 0x1, 85, 1, 2023 },
-{ 0x1, 86, 1, 2022 },
-{ 0x1, 87, 1, 2021 },
-{ 0x39, 40, 1, 21 },
-{ 0x19, 41, 0, 20 },
-{ 0x3, 84, 1, 2020 },
-{ 0x3, 85, 1, 2019 },
-{ 0x3, 86, 1, 2018 },
-{ 0x3, 87, 1, 2017 },
-{ 0x69, 40, 0, 10 },
-{ 0x14, 79, 1, 2014 },
-{ 0xa, 83, 1, 2013 },
-{ 0xd1, 40, 0, 8 },
-{ 0x34, 79, 1, 1950 },
-{ 0xe, 91, 0, 1949 },
-{ 0xc, 79, 1, 2094 },
-{ 0x6, 83, 0, 2093 },
-{ 0x2, 79, 1, 1956 },
-{ 0x2, 82, 0, 1955 },
-{ 0x12, 79, 1, 1954 },
-{ 0x6, 82, 0, 1953 },
-{ 0xa, 79, 1, 2016 },
-{ 0x5, 83, 1, 2015 },
-{ 0x71, 40, 1, 17 },
-{ 0x31, 41, 0, 16 },
-{ 0x1a, 79, 1, 1952 },
-{ 0x7, 91, 0, 1951 },
-{ 0x6, 79, 1, 2096 },
-{ 0x3, 83, 0, 2095 },
-{ 0x1, 79, 1, 2104 },
-{ 0x1, 80, 1, 2103 },
-{ 0x1, 81, 1, 2102 },
-{ 0x1, 82, 0, 2101 },
-{ 0x3, 79, 1, 2100 },
-{ 0x3, 80, 1, 2099 },
-{ 0x3, 81, 1, 2098 },
-{ 0x3, 82, 0, 2097 },
-{ 0x8, 60, 1, 2036 },
-{ 0x2, 63, 1, 2033 },
-{ 0x1, 65, 1, 2035 },
-{ 0x1, 66, 1, 2034 },
-{ 0xf, 40, 1, 29 },
-{ 0x7, 41, 0, 28 },
-{ 0x18, 60, 1, 2032 },
-{ 0x6, 63, 1, 2029 },
-{ 0x3, 65, 1, 2031 },
-{ 0x3, 66, 1, 2030 },
-{ 0x1b, 40, 0, 14 },
-{ 0x14, 60, 1, 2026 },
-{ 0xa, 64, 1, 2025 },
-{ 0x35, 40, 0, 12 },
-{ 0x34, 60, 1, 1958 },
-{ 0xe, 70, 0, 1957 },
-{ 0xc, 60, 1, 2106 },
-{ 0x6, 64, 0, 2105 },
-{ 0x2, 60, 1, 1964 },
-{ 0x4, 63, 0, 1963 },
-{ 0x12, 60, 1, 1962 },
-{ 0xc, 63, 0, 1961 },
-{ 0xa, 60, 1, 2028 },
-{ 0x5, 64, 1, 2027 },
-{ 0x1d, 40, 1, 25 },
-{ 0xd, 41, 0, 24 },
-{ 0x1a, 60, 1, 1960 },
-{ 0x7, 70, 0, 1959 },
-{ 0x6, 60, 1, 2108 },
-{ 0x3, 64, 0, 2107 },
-{ 0x1, 60, 1, 2116 },
-{ 0x1, 61, 1, 2115 },
-{ 0x1, 62, 1, 2114 },
-{ 0x1, 63, 0, 2113 },
-{ 0x3, 60, 1, 2112 },
-{ 0x3, 61, 1, 2111 },
-{ 0x3, 62, 1, 2110 },
-{ 0x3, 63, 0, 2109 },
-{ 0x28, 76, 1, 2040 },
-{ 0x44, 77, 1, 2037 },
-{ 0x88, 77, 1, 2039 },
-{ 0x28, 78, 0, 2038 },
-{ 0x68, 76, 1, 1968 },
-{ 0x188, 77, 1, 1967 },
-{ 0x38, 89, 1, 1966 },
-{ 0x38, 90, 0, 1965 },
-{ 0x18, 76, 1, 2120 },
-{ 0x14, 77, 1, 2117 },
-{ 0x28, 77, 1, 2119 },
-{ 0x18, 78, 0, 2118 },
-{ 0x14, 76, 1, 2044 },
-{ 0x24, 77, 1, 2043 },
-{ 0x48, 77, 1, 2041 },
-{ 0x14, 78, 0, 2042 },
-{ 0x34, 76, 1, 1972 },
-{ 0x64, 77, 1, 1971 },
-{ 0x1c, 89, 1, 1970 },
-{ 0x1c, 90, 0, 1969 },
-{ 0xc, 76, 1, 2124 },
-{ 0xc, 77, 1, 2123 },
-{ 0x18, 77, 1, 2121 },
-{ 0xc, 78, 0, 2122 },
-{ 0xa, 76, 1, 2048 },
-{ 0x11, 77, 1, 2045 },
-{ 0x22, 77, 1, 2047 },
-{ 0xa, 78, 0, 2046 },
-{ 0x1a, 76, 1, 1976 },
-{ 0x62, 77, 1, 1975 },
-{ 0xe, 89, 1, 1974 },
-{ 0xe, 90, 0, 1973 },
-{ 0x6, 76, 1, 2128 },
-{ 0x5, 77, 1, 2125 },
-{ 0xa, 77, 1, 2127 },
-{ 0x6, 78, 0, 2126 },
-{ 0x5, 76, 1, 2052 },
-{ 0x9, 77, 1, 2051 },
-{ 0x12, 77, 1, 2049 },
-{ 0x5, 78, 0, 2050 },
-{ 0xd, 76, 1, 1980 },
-{ 0x19, 77, 1, 1979 },
-{ 0x7, 89, 1, 1978 },
-{ 0x7, 90, 0, 1977 },
-{ 0x3, 76, 1, 2132 },
-{ 0x3, 77, 1, 2131 },
-{ 0x6, 77, 1, 2129 },
-{ 0x3, 78, 0, 2130 },
-{ 0x28, 57, 1, 2056 },
-{ 0x44, 58, 1, 2053 },
-{ 0x88, 58, 1, 2055 },
-{ 0x28, 59, 0, 2054 },
-{ 0x68, 57, 1, 1984 },
-{ 0x188, 58, 1, 1983 },
-{ 0x38, 68, 1, 1982 },
-{ 0x38, 69, 0, 1981 },
-{ 0x18, 57, 1, 2136 },
-{ 0x14, 58, 1, 2133 },
-{ 0x28, 58, 1, 2135 },
-{ 0x18, 59, 0, 2134 },
-{ 0x14, 57, 1, 2060 },
-{ 0x24, 58, 1, 2059 },
-{ 0x48, 58, 1, 2057 },
-{ 0x14, 59, 0, 2058 },
-{ 0x34, 57, 1, 1988 },
-{ 0x64, 58, 1, 1987 },
-{ 0x1c, 68, 1, 1986 },
-{ 0x1c, 69, 0, 1985 },
-{ 0xc, 57, 1, 2140 },
-{ 0xc, 58, 1, 2139 },
-{ 0x18, 58, 1, 2137 },
-{ 0xc, 59, 0, 2138 },
-{ 0xa, 57, 1, 2064 },
-{ 0x11, 58, 1, 2061 },
-{ 0x22, 58, 1, 2063 },
-{ 0xa, 59, 0, 2062 },
-{ 0x1a, 57, 1, 1992 },
-{ 0x62, 58, 1, 1991 },
-{ 0xe, 68, 1, 1990 },
-{ 0xe, 69, 0, 1989 },
-{ 0x6, 57, 1, 2144 },
-{ 0x5, 58, 1, 2141 },
-{ 0xa, 58, 1, 2143 },
-{ 0x6, 59, 0, 2142 },
-{ 0x5, 57, 1, 2068 },
-{ 0x9, 58, 1, 2067 },
-{ 0x12, 58, 1, 2065 },
-{ 0x5, 59, 0, 2066 },
-{ 0xd, 57, 1, 1996 },
-{ 0x19, 58, 1, 1995 },
-{ 0x7, 68, 1, 1994 },
-{ 0x7, 69, 0, 1993 },
-{ 0x3, 57, 1, 2148 },
-{ 0x3, 58, 1, 2147 },
-{ 0x6, 58, 1, 2145 },
-{ 0x3, 59, 0, 2146 },
-{ 0x8, 71, 1, 2080 },
-{ 0x2, 72, 1, 2079 },
-{ 0x2, 73, 1, 2078 },
-{ 0x2, 74, 0, 2077 },
-{ 0x18, 71, 1, 2076 },
-{ 0x6, 72, 1, 2075 },
-{ 0x6, 73, 1, 2074 },
-{ 0x6, 74, 0, 2073 },
-{ 0x14, 71, 1, 2070 },
-{ 0xa, 75, 0, 2069 },
-{ 0x34, 71, 1, 1998 },
-{ 0xe, 88, 0, 1997 },
-{ 0xc, 71, 1, 2150 },
-{ 0x6, 75, 0, 2149 },
-{ 0x2, 71, 1, 2004 },
-{ 0x4, 74, 0, 2003 },
-{ 0x12, 71, 1, 2002 },
-{ 0xc, 74, 0, 2001 },
-{ 0xa, 71, 1, 2072 },
-{ 0x5, 75, 0, 2071 },
-{ 0x1a, 71, 1, 2000 },
-{ 0x7, 88, 0, 1999 },
-{ 0x6, 71, 1, 2152 },
-{ 0x3, 75, 0, 2151 },
-{ 0x1, 71, 1, 2160 },
-{ 0x1, 72, 1, 2159 },
-{ 0x1, 73, 1, 2158 },
-{ 0x1, 74, 0, 2157 },
-{ 0x3, 71, 1, 2156 },
-{ 0x3, 72, 1, 2155 },
-{ 0x3, 73, 1, 2154 },
-{ 0x3, 74, 0, 2153 },
-{ 0x8, 52, 1, 2092 },
-{ 0x2, 53, 1, 2091 },
-{ 0x2, 54, 1, 2090 },
-{ 0x2, 55, 0, 2089 },
-{ 0x18, 52, 1, 2088 },
-{ 0x6, 53, 1, 2087 },
-{ 0x6, 54, 1, 2086 },
-{ 0x6, 55, 0, 2085 },
-{ 0x14, 52, 1, 2082 },
-{ 0xa, 56, 0, 2081 },
-{ 0x34, 52, 1, 2006 },
-{ 0xe, 67, 0, 2005 },
-{ 0xc, 52, 1, 2162 },
-{ 0x6, 56, 0, 2161 },
-{ 0x2, 52, 1, 2012 },
-{ 0x4, 55, 0, 2011 },
-{ 0x12, 52, 1, 2010 },
-{ 0xc, 55, 0, 2009 },
-{ 0xa, 52, 1, 2084 },
-{ 0x5, 56, 0, 2083 },
-{ 0x1a, 52, 1, 2008 },
-{ 0x7, 67, 0, 2007 },
-{ 0x6, 52, 1, 2164 },
-{ 0x3, 56, 0, 2163 },
-{ 0x1, 52, 1, 2172 },
-{ 0x1, 53, 1, 2171 },
-{ 0x1, 54, 1, 2170 },
-{ 0x1, 55, 0, 2169 },
-{ 0x3, 52, 1, 2168 },
-{ 0x3, 53, 1, 2167 },
-{ 0x3, 54, 1, 2166 },
-{ 0x3, 55, 0, 2165 },
-{ 0x1, 4, 0, 2173 },
-{ 0x1, 245, 0, 2174 },
-{ 0x1, 327, 0, 2175 },
-{ 0x1, 322, 0, 2176 },
-{ 0x2, 306, 0, 2177 },
-{ 0x1, 306, 0, 2180 },
-{ 0x2, 305, 0, 2178 },
-{ 0x1, 305, 0, 2181 },
-{ 0x2, 304, 0, 2179 },
-{ 0x1, 304, 0, 2182 },
-{ 0x1, 303, 0, 2183 },
-{ 0x1, 302, 0, 2184 },
-{ 0x2, 301, 0, 2185 },
-{ 0x1, 301, 0, 2187 },
-{ 0x2, 300, 0, 2186 },
-{ 0x1, 300, 0, 2188 },
-{ 0x1, 330, 0, 2195 },
-{ 0x8, 329, 0, 2189 },
-{ 0x4, 329, 0, 2191 },
-{ 0x2, 329, 0, 2193 },
-{ 0x1, 329, 0, 2196 },
-{ 0x8, 328, 0, 2190 },
-{ 0x4, 328, 0, 2192 },
-{ 0x2, 328, 0, 2194 },
-{ 0x1, 328, 0, 2197 },
-{ 0x1, 299, 0, 2204 },
-{ 0x8, 298, 0, 2198 },
-{ 0x4, 298, 0, 2200 },
-{ 0x2, 298, 0, 2202 },
-{ 0x1, 298, 0, 2205 },
-{ 0x8, 297, 0, 2199 },
-{ 0x4, 297, 0, 2201 },
-{ 0x2, 297, 1, 2203 },
-{ 0x4, 106, 0, 1249 },
-{ 0x1, 297, 0, 2206 },
-{ 0x1, 6, 0, 2207 },
-{ 0x1, 7, 0, 2208 },
-{ 0x1, 244, 0, 2209 },
-{ 0x1, 243, 0, 2210 },
-{ 0x1, 393, 0, 2211 },
-{ 0x1, 294, 0, 2212 },
-{ 0x1, 12, 0, 2213 },
-{ 0x1, 10, 0, 2214 },
-{ 0x1, 368, 0, 2215 },
-{ 0x1, 342, 0, 2216 },
-{ 0x1, 341, 0, 2217 },
-{ 0x1, 392, 0, 2218 },
-{ 0x1, 293, 0, 2219 },
-{ 0x1, 11, 0, 2220 },
-{ 0x1, 9, 0, 2221 },
-{ 0x1, 5, 0, 2222 },
-{ 0x1, 367, 0, 2223 },
-{ 0x1, 366, 0, 2224 },
-{ 0x1, 1, 0, 2225 },
-{ 0x1, 0, 0, 2226 },
+{ 0x1, 106, 0, 1591 },
+{ 0x1, 255, 1, 1592 },
+{ 0x1, 140, 0, 1588 },
+{ 0x8, 108, 0, 1593 },
+{ 0x4, 108, 0, 1594 },
+{ 0x2, 108, 0, 1595 },
+{ 0x1, 108, 1, 1597 },
+{ 0x1, 109, 0, 1596 },
+{ 0x8, 110, 0, 1598 },
+{ 0x4, 110, 0, 1599 },
+{ 0x2, 110, 0, 1600 },
+{ 0x1, 110, 1, 1602 },
+{ 0x1, 111, 1, 1601 },
+{ 0x1, 382, 0, 1094 },
+{ 0x8, 138, 0, 1603 },
+{ 0x4, 138, 0, 1604 },
+{ 0x2, 138, 0, 1605 },
+{ 0x1, 138, 1, 1607 },
+{ 0x1, 139, 1, 1606 },
+{ 0x1, 381, 0, 1095 },
+{ 0x8, 141, 0, 1608 },
+{ 0x4, 141, 0, 1609 },
+{ 0x2, 141, 0, 1610 },
+{ 0x1, 141, 1, 1612 },
+{ 0x1, 142, 1, 1611 },
+{ 0x1, 380, 0, 1096 },
+{ 0x8, 186, 0, 1613 },
+{ 0x4, 186, 0, 1614 },
+{ 0x2, 186, 0, 1615 },
+{ 0x1, 186, 1, 1617 },
+{ 0x1, 187, 0, 1616 },
+{ 0x8, 184, 0, 1618 },
+{ 0x4, 184, 0, 1619 },
+{ 0x2, 184, 0, 1620 },
+{ 0x1, 184, 1, 1622 },
+{ 0x1, 185, 0, 1621 },
+{ 0x8, 43, 0, 1627 },
+{ 0x18, 43, 0, 1623 },
+{ 0x4, 43, 0, 1628 },
+{ 0xc, 43, 0, 1624 },
+{ 0x2, 43, 0, 1629 },
+{ 0x6, 43, 0, 1625 },
+{ 0x1, 43, 0, 1630 },
+{ 0x3, 43, 0, 1626 },
+{ 0x51, 29, 0, 1632 },
+{ 0xd1, 29, 0, 1631 },
+{ 0x31, 29, 1, 1642 },
+{ 0x11, 30, 0, 1641 },
+{ 0x71, 29, 1, 1640 },
+{ 0x31, 30, 0, 1639 },
+{ 0x29, 29, 0, 1634 },
+{ 0x69, 29, 0, 1633 },
+{ 0x19, 29, 1, 1646 },
+{ 0x9, 30, 0, 1645 },
+{ 0x39, 29, 1, 1644 },
+{ 0x19, 30, 0, 1643 },
+{ 0x15, 29, 0, 1636 },
+{ 0x35, 29, 0, 1635 },
+{ 0xd, 29, 1, 1650 },
+{ 0x5, 30, 0, 1649 },
+{ 0x1d, 29, 1, 1648 },
+{ 0xd, 30, 0, 1647 },
+{ 0xb, 29, 0, 1638 },
+{ 0x1b, 29, 0, 1637 },
+{ 0x7, 29, 1, 1654 },
+{ 0x3, 30, 0, 1653 },
+{ 0xf, 29, 1, 1652 },
+{ 0x7, 30, 0, 1651 },
+{ 0xa2, 27, 0, 1656 },
+{ 0x1a2, 27, 0, 1655 },
+{ 0x62, 27, 1, 1666 },
+{ 0x22, 28, 0, 1665 },
+{ 0xe2, 27, 1, 1664 },
+{ 0x62, 28, 0, 1663 },
+{ 0x52, 27, 0, 1658 },
+{ 0xd2, 27, 0, 1657 },
+{ 0x32, 27, 1, 1670 },
+{ 0x12, 28, 0, 1669 },
+{ 0x72, 27, 1, 1668 },
+{ 0x32, 28, 0, 1667 },
+{ 0x2a, 27, 0, 1660 },
+{ 0x6a, 27, 0, 1659 },
+{ 0x1a, 27, 1, 1674 },
+{ 0xa, 28, 0, 1673 },
+{ 0x3a, 27, 1, 1672 },
+{ 0x1a, 28, 0, 1671 },
+{ 0x16, 27, 0, 1662 },
+{ 0x36, 27, 0, 1661 },
+{ 0xe, 27, 1, 1678 },
+{ 0x6, 28, 0, 1677 },
+{ 0x1e, 27, 1, 1676 },
+{ 0xe, 28, 0, 1675 },
+{ 0x51, 27, 0, 1680 },
+{ 0xd1, 27, 0, 1679 },
+{ 0x31, 27, 1, 1690 },
+{ 0x11, 28, 0, 1689 },
+{ 0x71, 27, 1, 1688 },
+{ 0x31, 28, 0, 1687 },
+{ 0x29, 27, 0, 1682 },
+{ 0x69, 27, 0, 1681 },
+{ 0x19, 27, 1, 1694 },
+{ 0x9, 28, 0, 1693 },
+{ 0x39, 27, 1, 1692 },
+{ 0x19, 28, 0, 1691 },
+{ 0x15, 27, 0, 1684 },
+{ 0x35, 27, 0, 1683 },
+{ 0xd, 27, 1, 1698 },
+{ 0x5, 28, 0, 1697 },
+{ 0x1d, 27, 1, 1696 },
+{ 0xd, 28, 0, 1695 },
+{ 0xb, 27, 0, 1686 },
+{ 0x1b, 27, 0, 1685 },
+{ 0x7, 27, 1, 1702 },
+{ 0x3, 28, 0, 1701 },
+{ 0xf, 27, 1, 1700 },
+{ 0x7, 28, 0, 1699 },
+{ 0x51, 25, 0, 1704 },
+{ 0xd1, 25, 0, 1703 },
+{ 0x31, 25, 1, 1714 },
+{ 0x11, 26, 0, 1713 },
+{ 0x71, 25, 1, 1712 },
+{ 0x31, 26, 0, 1711 },
+{ 0x29, 25, 0, 1706 },
+{ 0x69, 25, 0, 1705 },
+{ 0x19, 25, 1, 1718 },
+{ 0x9, 26, 0, 1717 },
+{ 0x39, 25, 1, 1716 },
+{ 0x19, 26, 0, 1715 },
+{ 0x15, 25, 0, 1708 },
+{ 0x35, 25, 0, 1707 },
+{ 0xd, 25, 1, 1722 },
+{ 0x5, 26, 0, 1721 },
+{ 0x1d, 25, 1, 1720 },
+{ 0xd, 26, 0, 1719 },
+{ 0xb, 25, 0, 1710 },
+{ 0x1b, 25, 0, 1709 },
+{ 0x7, 25, 1, 1726 },
+{ 0x3, 26, 0, 1725 },
+{ 0xf, 25, 1, 1724 },
+{ 0x7, 26, 0, 1723 },
+{ 0xa2, 23, 0, 1728 },
+{ 0x1a2, 23, 0, 1727 },
+{ 0x62, 23, 1, 1738 },
+{ 0x22, 24, 0, 1737 },
+{ 0xe2, 23, 1, 1736 },
+{ 0x62, 24, 0, 1735 },
+{ 0x52, 23, 0, 1730 },
+{ 0xd2, 23, 0, 1729 },
+{ 0x32, 23, 1, 1742 },
+{ 0x12, 24, 0, 1741 },
+{ 0x72, 23, 1, 1740 },
+{ 0x32, 24, 0, 1739 },
+{ 0x2a, 23, 0, 1732 },
+{ 0x6a, 23, 0, 1731 },
+{ 0x1a, 23, 1, 1746 },
+{ 0xa, 24, 0, 1745 },
+{ 0x3a, 23, 1, 1744 },
+{ 0x1a, 24, 0, 1743 },
+{ 0x16, 23, 0, 1734 },
+{ 0x36, 23, 0, 1733 },
+{ 0xe, 23, 1, 1750 },
+{ 0x6, 24, 0, 1749 },
+{ 0x1e, 23, 1, 1748 },
+{ 0xe, 24, 0, 1747 },
+{ 0x51, 23, 0, 1752 },
+{ 0xd1, 23, 0, 1751 },
+{ 0x31, 23, 1, 1762 },
+{ 0x11, 24, 0, 1761 },
+{ 0x71, 23, 1, 1760 },
+{ 0x31, 24, 0, 1759 },
+{ 0x29, 23, 0, 1754 },
+{ 0x69, 23, 0, 1753 },
+{ 0x19, 23, 1, 1766 },
+{ 0x9, 24, 0, 1765 },
+{ 0x39, 23, 1, 1764 },
+{ 0x19, 24, 0, 1763 },
+{ 0x15, 23, 0, 1756 },
+{ 0x35, 23, 0, 1755 },
+{ 0xd, 23, 1, 1770 },
+{ 0x5, 24, 0, 1769 },
+{ 0x1d, 23, 1, 1768 },
+{ 0xd, 24, 0, 1767 },
+{ 0xb, 23, 0, 1758 },
+{ 0x1b, 23, 0, 1757 },
+{ 0x7, 23, 1, 1774 },
+{ 0x3, 24, 0, 1773 },
+{ 0xf, 23, 1, 1772 },
+{ 0x7, 24, 0, 1771 },
+{ 0x51, 21, 1, 1800 },
+{ 0x50, 21, 0, 1776 },
+{ 0xd1, 21, 1, 1799 },
+{ 0xd0, 21, 0, 1775 },
+{ 0x31, 21, 1, 1810 },
+{ 0x30, 21, 1, 1786 },
+{ 0x11, 22, 1, 1809 },
+{ 0x10, 22, 0, 1785 },
+{ 0x71, 21, 1, 1808 },
+{ 0x70, 21, 1, 1784 },
+{ 0x31, 22, 1, 1807 },
+{ 0x30, 22, 0, 1783 },
+{ 0x29, 21, 1, 1802 },
+{ 0x28, 21, 0, 1778 },
+{ 0x69, 21, 1, 1801 },
+{ 0x68, 21, 0, 1777 },
+{ 0x19, 21, 1, 1814 },
+{ 0x18, 21, 1, 1790 },
+{ 0x9, 22, 1, 1813 },
+{ 0x8, 22, 0, 1789 },
+{ 0x39, 21, 1, 1812 },
+{ 0x38, 21, 1, 1788 },
+{ 0x19, 22, 1, 1811 },
+{ 0x18, 22, 0, 1787 },
+{ 0x15, 21, 1, 1804 },
+{ 0x14, 21, 0, 1780 },
+{ 0x35, 21, 1, 1803 },
+{ 0x34, 21, 0, 1779 },
+{ 0xd, 21, 1, 1818 },
+{ 0xc, 21, 1, 1794 },
+{ 0x5, 22, 1, 1817 },
+{ 0x4, 22, 0, 1793 },
+{ 0x1d, 21, 1, 1816 },
+{ 0x1c, 21, 1, 1792 },
+{ 0xd, 22, 1, 1815 },
+{ 0xc, 22, 0, 1791 },
+{ 0xb, 21, 1, 1806 },
+{ 0xa, 21, 0, 1782 },
+{ 0x1b, 21, 1, 1805 },
+{ 0x1a, 21, 0, 1781 },
+{ 0x7, 21, 1, 1822 },
+{ 0x6, 21, 1, 1798 },
+{ 0x3, 22, 1, 1821 },
+{ 0x2, 22, 0, 1797 },
+{ 0xf, 21, 1, 1820 },
+{ 0xe, 21, 1, 1796 },
+{ 0x7, 22, 1, 1819 },
+{ 0x6, 22, 0, 1795 },
+{ 0x8, 20, 0, 1824 },
+{ 0x18, 20, 0, 1823 },
+{ 0x1, 20, 1, 1828 },
+{ 0x2, 20, 0, 1827 },
+{ 0x3, 20, 1, 1826 },
+{ 0x4, 20, 0, 1825 },
+{ 0x1, 197, 0, 1829 },
+{ 0x1, 296, 0, 1830 },
+{ 0x14, 42, 0, 1833 },
+{ 0x34, 42, 0, 1831 },
+{ 0xc, 42, 0, 1834 },
+{ 0x1c, 42, 0, 1832 },
+{ 0x2, 42, 0, 1837 },
+{ 0x6, 42, 0, 1835 },
+{ 0x1, 42, 0, 1838 },
+{ 0x3, 42, 0, 1836 },
+{ 0x51, 18, 0, 1840 },
+{ 0xd1, 18, 0, 1839 },
+{ 0x31, 18, 1, 1850 },
+{ 0x11, 19, 0, 1849 },
+{ 0x71, 18, 1, 1848 },
+{ 0x31, 19, 0, 1847 },
+{ 0x29, 18, 0, 1842 },
+{ 0x69, 18, 0, 1841 },
+{ 0x19, 18, 1, 1854 },
+{ 0x9, 19, 0, 1853 },
+{ 0x39, 18, 1, 1852 },
+{ 0x19, 19, 0, 1851 },
+{ 0x15, 18, 0, 1844 },
+{ 0x35, 18, 0, 1843 },
+{ 0xd, 18, 1, 1858 },
+{ 0x5, 19, 0, 1857 },
+{ 0x1d, 18, 1, 1856 },
+{ 0xd, 19, 0, 1855 },
+{ 0xb, 18, 0, 1846 },
+{ 0x1b, 18, 0, 1845 },
+{ 0x7, 18, 1, 1862 },
+{ 0x3, 19, 0, 1861 },
+{ 0xf, 18, 1, 1860 },
+{ 0x7, 19, 0, 1859 },
+{ 0x1, 31, 0, 1863 },
+{ 0x1, 104, 0, 1864 },
+{ 0x2, 44, 0, 1865 },
+{ 0x1, 44, 0, 1866 },
+{ 0x1, 344, 0, 1867 },
+{ 0x2, 51, 0, 1868 },
+{ 0x1, 51, 0, 1869 },
+{ 0x1, 97, 0, 1870 },
+{ 0x51, 16, 0, 1872 },
+{ 0xd1, 16, 0, 1871 },
+{ 0x31, 16, 1, 1882 },
+{ 0x11, 17, 0, 1881 },
+{ 0x71, 16, 1, 1880 },
+{ 0x31, 17, 0, 1879 },
+{ 0x29, 16, 0, 1874 },
+{ 0x69, 16, 0, 1873 },
+{ 0x19, 16, 1, 1886 },
+{ 0x9, 17, 0, 1885 },
+{ 0x39, 16, 1, 1884 },
+{ 0x19, 17, 0, 1883 },
+{ 0x15, 16, 0, 1876 },
+{ 0x35, 16, 0, 1875 },
+{ 0xd, 16, 1, 1890 },
+{ 0x5, 17, 0, 1889 },
+{ 0x1d, 16, 1, 1888 },
+{ 0xd, 17, 0, 1887 },
+{ 0xb, 16, 0, 1878 },
+{ 0x1b, 16, 0, 1877 },
+{ 0x7, 16, 1, 1894 },
+{ 0x3, 17, 0, 1893 },
+{ 0xf, 16, 1, 1892 },
+{ 0x7, 17, 0, 1891 },
+{ 0xa20, 14, 0, 1896 },
+{ 0x1a20, 14, 0, 1895 },
+{ 0x620, 14, 1, 1906 },
+{ 0x220, 15, 0, 1905 },
+{ 0xe20, 14, 1, 1904 },
+{ 0x620, 15, 0, 1903 },
+{ 0x520, 14, 0, 1898 },
+{ 0xd20, 14, 0, 1897 },
+{ 0x320, 14, 1, 1910 },
+{ 0x120, 15, 0, 1909 },
+{ 0x720, 14, 1, 1908 },
+{ 0x320, 15, 0, 1907 },
+{ 0x2a0, 14, 0, 1900 },
+{ 0x6a0, 14, 0, 1899 },
+{ 0x1a0, 14, 1, 1914 },
+{ 0xa0, 15, 0, 1913 },
+{ 0x3a0, 14, 1, 1912 },
+{ 0x1a0, 15, 0, 1911 },
+{ 0x160, 14, 0, 1902 },
+{ 0x360, 14, 0, 1901 },
+{ 0xe0, 14, 1, 1918 },
+{ 0x60, 15, 0, 1917 },
+{ 0x1e0, 14, 1, 1916 },
+{ 0xe0, 15, 0, 1915 },
+{ 0x51, 14, 1, 1944 },
+{ 0x50, 14, 0, 1920 },
+{ 0xd1, 14, 1, 1943 },
+{ 0xd0, 14, 0, 1919 },
+{ 0x31, 14, 1, 1954 },
+{ 0x30, 14, 1, 1930 },
+{ 0x11, 15, 1, 1953 },
+{ 0x10, 15, 0, 1929 },
+{ 0x71, 14, 1, 1952 },
+{ 0x70, 14, 1, 1928 },
+{ 0x31, 15, 1, 1951 },
+{ 0x30, 15, 0, 1927 },
+{ 0x29, 14, 1, 1946 },
+{ 0x28, 14, 0, 1922 },
+{ 0x69, 14, 1, 1945 },
+{ 0x68, 14, 0, 1921 },
+{ 0x19, 14, 1, 1958 },
+{ 0x18, 14, 1, 1934 },
+{ 0x9, 15, 1, 1957 },
+{ 0x8, 15, 0, 1933 },
+{ 0x39, 14, 1, 1956 },
+{ 0x38, 14, 1, 1932 },
+{ 0x19, 15, 1, 1955 },
+{ 0x18, 15, 0, 1931 },
+{ 0x15, 14, 1, 1948 },
+{ 0x14, 14, 0, 1924 },
+{ 0x35, 14, 1, 1947 },
+{ 0x34, 14, 0, 1923 },
+{ 0xd, 14, 1, 1962 },
+{ 0xc, 14, 1, 1938 },
+{ 0x5, 15, 1, 1961 },
+{ 0x4, 15, 0, 1937 },
+{ 0x1d, 14, 1, 1960 },
+{ 0x1c, 14, 1, 1936 },
+{ 0xd, 15, 1, 1959 },
+{ 0xc, 15, 0, 1935 },
+{ 0xb, 14, 1, 1950 },
+{ 0xa, 14, 0, 1926 },
+{ 0x1b, 14, 1, 1949 },
+{ 0x1a, 14, 0, 1925 },
+{ 0x7, 14, 1, 1966 },
+{ 0x6, 14, 1, 1942 },
+{ 0x3, 15, 1, 1965 },
+{ 0x2, 15, 0, 1941 },
+{ 0xf, 14, 1, 1964 },
+{ 0xe, 14, 1, 1940 },
+{ 0x7, 15, 1, 1963 },
+{ 0x6, 15, 0, 1939 },
+{ 0x8, 13, 0, 1968 },
+{ 0x18, 13, 0, 1967 },
+{ 0x1, 13, 1, 1972 },
+{ 0x2, 13, 0, 1971 },
+{ 0x3, 13, 1, 1970 },
+{ 0x4, 13, 0, 1969 },
+{ 0x1, 84, 1, 2048 },
+{ 0x1, 85, 1, 2047 },
+{ 0x1, 86, 1, 2046 },
+{ 0x1, 87, 1, 2045 },
+{ 0x39, 40, 1, 22 },
+{ 0x19, 41, 0, 21 },
+{ 0x3, 84, 1, 2044 },
+{ 0x3, 85, 1, 2043 },
+{ 0x3, 86, 1, 2042 },
+{ 0x3, 87, 1, 2041 },
+{ 0x69, 40, 0, 11 },
+{ 0x14, 79, 1, 2038 },
+{ 0xa, 83, 1, 2037 },
+{ 0xd1, 40, 0, 9 },
+{ 0x34, 79, 1, 1974 },
+{ 0xe, 91, 0, 1973 },
+{ 0xc, 79, 1, 2118 },
+{ 0x6, 83, 0, 2117 },
+{ 0x2, 79, 1, 1980 },
+{ 0x2, 82, 0, 1979 },
+{ 0x12, 79, 1, 1978 },
+{ 0x6, 82, 0, 1977 },
+{ 0xa, 79, 1, 2040 },
+{ 0x5, 83, 1, 2039 },
+{ 0x71, 40, 1, 18 },
+{ 0x31, 41, 0, 17 },
+{ 0x1a, 79, 1, 1976 },
+{ 0x7, 91, 0, 1975 },
+{ 0x6, 79, 1, 2120 },
+{ 0x3, 83, 0, 2119 },
+{ 0x1, 79, 1, 2128 },
+{ 0x1, 80, 1, 2127 },
+{ 0x1, 81, 1, 2126 },
+{ 0x1, 82, 0, 2125 },
+{ 0x3, 79, 1, 2124 },
+{ 0x3, 80, 1, 2123 },
+{ 0x3, 81, 1, 2122 },
+{ 0x3, 82, 0, 2121 },
+{ 0x8, 60, 1, 2060 },
+{ 0x2, 63, 1, 2057 },
+{ 0x1, 65, 1, 2059 },
+{ 0x1, 66, 1, 2058 },
+{ 0xf, 40, 1, 30 },
+{ 0x7, 41, 0, 29 },
+{ 0x18, 60, 1, 2056 },
+{ 0x6, 63, 1, 2053 },
+{ 0x3, 65, 1, 2055 },
+{ 0x3, 66, 1, 2054 },
+{ 0x1b, 40, 0, 15 },
+{ 0x14, 60, 1, 2050 },
+{ 0xa, 64, 1, 2049 },
+{ 0x35, 40, 0, 13 },
+{ 0x34, 60, 1, 1982 },
+{ 0xe, 70, 0, 1981 },
+{ 0xc, 60, 1, 2130 },
+{ 0x6, 64, 0, 2129 },
+{ 0x2, 60, 1, 1988 },
+{ 0x4, 63, 0, 1987 },
+{ 0x12, 60, 1, 1986 },
+{ 0xc, 63, 0, 1985 },
+{ 0xa, 60, 1, 2052 },
+{ 0x5, 64, 1, 2051 },
+{ 0x1d, 40, 1, 26 },
+{ 0xd, 41, 0, 25 },
+{ 0x1a, 60, 1, 1984 },
+{ 0x7, 70, 0, 1983 },
+{ 0x6, 60, 1, 2132 },
+{ 0x3, 64, 0, 2131 },
+{ 0x1, 60, 1, 2140 },
+{ 0x1, 61, 1, 2139 },
+{ 0x1, 62, 1, 2138 },
+{ 0x1, 63, 0, 2137 },
+{ 0x3, 60, 1, 2136 },
+{ 0x3, 61, 1, 2135 },
+{ 0x3, 62, 1, 2134 },
+{ 0x3, 63, 0, 2133 },
+{ 0x28, 76, 1, 2064 },
+{ 0x44, 77, 1, 2061 },
+{ 0x88, 77, 1, 2063 },
+{ 0x28, 78, 0, 2062 },
+{ 0x68, 76, 1, 1992 },
+{ 0x188, 77, 1, 1991 },
+{ 0x38, 89, 1, 1990 },
+{ 0x38, 90, 0, 1989 },
+{ 0x18, 76, 1, 2144 },
+{ 0x14, 77, 1, 2141 },
+{ 0x28, 77, 1, 2143 },
+{ 0x18, 78, 0, 2142 },
+{ 0x14, 76, 1, 2068 },
+{ 0x24, 77, 1, 2067 },
+{ 0x48, 77, 1, 2065 },
+{ 0x14, 78, 0, 2066 },
+{ 0x34, 76, 1, 1996 },
+{ 0x64, 77, 1, 1995 },
+{ 0x1c, 89, 1, 1994 },
+{ 0x1c, 90, 0, 1993 },
+{ 0xc, 76, 1, 2148 },
+{ 0xc, 77, 1, 2147 },
+{ 0x18, 77, 1, 2145 },
+{ 0xc, 78, 0, 2146 },
+{ 0xa, 76, 1, 2072 },
+{ 0x11, 77, 1, 2069 },
+{ 0x22, 77, 1, 2071 },
+{ 0xa, 78, 0, 2070 },
+{ 0x1a, 76, 1, 2000 },
+{ 0x62, 77, 1, 1999 },
+{ 0xe, 89, 1, 1998 },
+{ 0xe, 90, 0, 1997 },
+{ 0x6, 76, 1, 2152 },
+{ 0x5, 77, 1, 2149 },
+{ 0xa, 77, 1, 2151 },
+{ 0x6, 78, 0, 2150 },
+{ 0x5, 76, 1, 2076 },
+{ 0x9, 77, 1, 2075 },
+{ 0x12, 77, 1, 2073 },
+{ 0x5, 78, 0, 2074 },
+{ 0xd, 76, 1, 2004 },
+{ 0x19, 77, 1, 2003 },
+{ 0x7, 89, 1, 2002 },
+{ 0x7, 90, 0, 2001 },
+{ 0x3, 76, 1, 2156 },
+{ 0x3, 77, 1, 2155 },
+{ 0x6, 77, 1, 2153 },
+{ 0x3, 78, 0, 2154 },
+{ 0x28, 57, 1, 2080 },
+{ 0x44, 58, 1, 2077 },
+{ 0x88, 58, 1, 2079 },
+{ 0x28, 59, 0, 2078 },
+{ 0x68, 57, 1, 2008 },
+{ 0x188, 58, 1, 2007 },
+{ 0x38, 68, 1, 2006 },
+{ 0x38, 69, 0, 2005 },
+{ 0x18, 57, 1, 2160 },
+{ 0x14, 58, 1, 2157 },
+{ 0x28, 58, 1, 2159 },
+{ 0x18, 59, 0, 2158 },
+{ 0x14, 57, 1, 2084 },
+{ 0x24, 58, 1, 2083 },
+{ 0x48, 58, 1, 2081 },
+{ 0x14, 59, 0, 2082 },
+{ 0x34, 57, 1, 2012 },
+{ 0x64, 58, 1, 2011 },
+{ 0x1c, 68, 1, 2010 },
+{ 0x1c, 69, 0, 2009 },
+{ 0xc, 57, 1, 2164 },
+{ 0xc, 58, 1, 2163 },
+{ 0x18, 58, 1, 2161 },
+{ 0xc, 59, 0, 2162 },
+{ 0xa, 57, 1, 2088 },
+{ 0x11, 58, 1, 2085 },
+{ 0x22, 58, 1, 2087 },
+{ 0xa, 59, 0, 2086 },
+{ 0x1a, 57, 1, 2016 },
+{ 0x62, 58, 1, 2015 },
+{ 0xe, 68, 1, 2014 },
+{ 0xe, 69, 0, 2013 },
+{ 0x6, 57, 1, 2168 },
+{ 0x5, 58, 1, 2165 },
+{ 0xa, 58, 1, 2167 },
+{ 0x6, 59, 0, 2166 },
+{ 0x5, 57, 1, 2092 },
+{ 0x9, 58, 1, 2091 },
+{ 0x12, 58, 1, 2089 },
+{ 0x5, 59, 0, 2090 },
+{ 0xd, 57, 1, 2020 },
+{ 0x19, 58, 1, 2019 },
+{ 0x7, 68, 1, 2018 },
+{ 0x7, 69, 0, 2017 },
+{ 0x3, 57, 1, 2172 },
+{ 0x3, 58, 1, 2171 },
+{ 0x6, 58, 1, 2169 },
+{ 0x3, 59, 0, 2170 },
+{ 0x8, 71, 1, 2104 },
+{ 0x2, 72, 1, 2103 },
+{ 0x2, 73, 1, 2102 },
+{ 0x2, 74, 0, 2101 },
+{ 0x18, 71, 1, 2100 },
+{ 0x6, 72, 1, 2099 },
+{ 0x6, 73, 1, 2098 },
+{ 0x6, 74, 0, 2097 },
+{ 0x14, 71, 1, 2094 },
+{ 0xa, 75, 0, 2093 },
+{ 0x34, 71, 1, 2022 },
+{ 0xe, 88, 0, 2021 },
+{ 0xc, 71, 1, 2174 },
+{ 0x6, 75, 0, 2173 },
+{ 0x2, 71, 1, 2028 },
+{ 0x4, 74, 0, 2027 },
+{ 0x12, 71, 1, 2026 },
+{ 0xc, 74, 0, 2025 },
+{ 0xa, 71, 1, 2096 },
+{ 0x5, 75, 0, 2095 },
+{ 0x1a, 71, 1, 2024 },
+{ 0x7, 88, 0, 2023 },
+{ 0x6, 71, 1, 2176 },
+{ 0x3, 75, 0, 2175 },
+{ 0x1, 71, 1, 2184 },
+{ 0x1, 72, 1, 2183 },
+{ 0x1, 73, 1, 2182 },
+{ 0x1, 74, 0, 2181 },
+{ 0x3, 71, 1, 2180 },
+{ 0x3, 72, 1, 2179 },
+{ 0x3, 73, 1, 2178 },
+{ 0x3, 74, 0, 2177 },
+{ 0x8, 52, 1, 2116 },
+{ 0x2, 53, 1, 2115 },
+{ 0x2, 54, 1, 2114 },
+{ 0x2, 55, 0, 2113 },
+{ 0x18, 52, 1, 2112 },
+{ 0x6, 53, 1, 2111 },
+{ 0x6, 54, 1, 2110 },
+{ 0x6, 55, 0, 2109 },
+{ 0x14, 52, 1, 2106 },
+{ 0xa, 56, 0, 2105 },
+{ 0x34, 52, 1, 2030 },
+{ 0xe, 67, 0, 2029 },
+{ 0xc, 52, 1, 2186 },
+{ 0x6, 56, 0, 2185 },
+{ 0x2, 52, 1, 2036 },
+{ 0x4, 55, 0, 2035 },
+{ 0x12, 52, 1, 2034 },
+{ 0xc, 55, 0, 2033 },
+{ 0xa, 52, 1, 2108 },
+{ 0x5, 56, 0, 2107 },
+{ 0x1a, 52, 1, 2032 },
+{ 0x7, 67, 0, 2031 },
+{ 0x6, 52, 1, 2188 },
+{ 0x3, 56, 0, 2187 },
+{ 0x1, 52, 1, 2196 },
+{ 0x1, 53, 1, 2195 },
+{ 0x1, 54, 1, 2194 },
+{ 0x1, 55, 0, 2193 },
+{ 0x3, 52, 1, 2192 },
+{ 0x3, 53, 1, 2191 },
+{ 0x3, 54, 1, 2190 },
+{ 0x3, 55, 0, 2189 },
+{ 0x1, 4, 0, 2197 },
+{ 0x1, 254, 0, 2198 },
+{ 0x1, 336, 0, 2199 },
+{ 0x1, 331, 0, 2200 },
+{ 0x2, 315, 0, 2201 },
+{ 0x1, 315, 0, 2204 },
+{ 0x2, 314, 0, 2202 },
+{ 0x1, 314, 0, 2205 },
+{ 0x2, 313, 0, 2203 },
+{ 0x1, 313, 0, 2206 },
+{ 0x1, 312, 0, 2207 },
+{ 0x1, 311, 0, 2208 },
+{ 0x2, 310, 0, 2209 },
+{ 0x1, 310, 0, 2211 },
+{ 0x2, 309, 0, 2210 },
+{ 0x1, 309, 0, 2212 },
+{ 0x1, 339, 0, 2219 },
+{ 0x8, 338, 0, 2213 },
+{ 0x4, 338, 0, 2215 },
+{ 0x2, 338, 0, 2217 },
+{ 0x1, 338, 0, 2220 },
+{ 0x8, 337, 0, 2214 },
+{ 0x4, 337, 0, 2216 },
+{ 0x2, 337, 0, 2218 },
+{ 0x1, 337, 0, 2221 },
+{ 0x1, 308, 0, 2228 },
+{ 0x8, 307, 0, 2222 },
+{ 0x4, 307, 0, 2224 },
+{ 0x2, 307, 0, 2226 },
+{ 0x1, 307, 0, 2229 },
+{ 0x8, 306, 0, 2223 },
+{ 0x4, 306, 0, 2225 },
+{ 0x2, 306, 1, 2227 },
+{ 0x4, 107, 0, 1271 },
+{ 0x1, 306, 0, 2230 },
+{ 0x1, 6, 0, 2231 },
+{ 0x1, 7, 0, 2232 },
+{ 0x1, 253, 0, 2233 },
+{ 0x1, 252, 0, 2234 },
+{ 0x1, 403, 0, 2235 },
+{ 0x1, 303, 0, 2236 },
+{ 0x1, 12, 0, 2237 },
+{ 0x1, 10, 0, 2238 },
+{ 0x1, 378, 0, 2239 },
+{ 0x1, 351, 0, 2240 },
+{ 0x1, 350, 0, 2241 },
+{ 0x1, 402, 0, 2242 },
+{ 0x1, 302, 0, 2243 },
+{ 0x1, 11, 0, 2244 },
+{ 0x1, 9, 0, 2245 },
+{ 0x1, 5, 0, 2246 },
+{ 0x1, 377, 0, 2247 },
+{ 0x1, 376, 0, 2248 },
+{ 0x1, 1, 0, 2249 },
+{ 0x1, 0, 0, 2250 },
};
diff --git a/contrib/binutils/opcodes/ia64-dis.c b/contrib/binutils/opcodes/ia64-dis.c
index f9add91..4c63815 100644
--- a/contrib/binutils/opcodes/ia64-dis.c
+++ b/contrib/binutils/opcodes/ia64-dis.c
@@ -167,10 +167,10 @@ print_insn_ia64 (bfd_vma memaddr, struct disassemble_info *info)
}
else if (odesc - elf64_ia64_operands == IA64_OPND_TGT64)
{
- /* 60-bit immedate for long branches. */
+ /* 60-bit immediate for long branches. */
value = (((insn >> 13) & 0xfffff)
| (((insn >> 36) & 1) << 59)
- | (slot[1] << 20)) << 4;
+ | (((slot[1] >> 2) & 0x7fffffffffLL) << 20)) << 4;
}
else
{
diff --git a/contrib/binutils/opcodes/ia64-gen.c b/contrib/binutils/opcodes/ia64-gen.c
index 6443c7c..a4e2cec 100644
--- a/contrib/binutils/opcodes/ia64-gen.c
+++ b/contrib/binutils/opcodes/ia64-gen.c
@@ -1,5 +1,5 @@
/* ia64-gen.c -- Generate a shrunk set of opcode tables
- Copyright 1999, 2000, 2001 Free Software Foundation, Inc.
+ Copyright 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
Written by Bob Manson, Cygnus Solutions, <manson@cygnus.com>
This file is part of GDB, GAS, and the GNU binutils.
@@ -30,16 +30,17 @@
required.
The resource table is constructed based on some text dependency tables,
- which are also easier to maintain than the final representation.
-
-*/
+ which are also easier to maintain than the final representation. */
#include <stdio.h>
+#include <stdarg.h>
+#include <errno.h>
#include "ansidecl.h"
#include "libiberty.h"
#include "safe-ctype.h"
#include "sysdep.h"
+#include "getopt.h"
#include "ia64-opc.h"
#include "ia64-opc-a.c"
#include "ia64-opc-i.c"
@@ -49,49 +50,54 @@
#include "ia64-opc-x.c"
#include "ia64-opc-d.c"
+#include <libintl.h>
+#define _(String) gettext (String)
+
+const char * program_name = NULL;
int debug = 0;
#define tmalloc(X) (X *) xmalloc (sizeof (X))
/* The main opcode table entry. Each entry is a unique combination of
name and flags (no two entries in the table compare as being equal
- via opcodes_eq). */
+ via opcodes_eq). */
struct main_entry
{
/* The base name of this opcode. The names of its completers are
- appended to it to generate the full instruction name. */
+ appended to it to generate the full instruction name. */
struct string_entry *name;
/* The base opcode entry. Which one to use is a fairly arbitrary choice;
- it uses the first one passed to add_opcode_entry. */
+ it uses the first one passed to add_opcode_entry. */
struct ia64_opcode *opcode;
- /* The list of completers that can be applied to this opcode. */
+ /* The list of completers that can be applied to this opcode. */
struct completer_entry *completers;
- /* Next entry in the chain. */
+ /* Next entry in the chain. */
struct main_entry *next;
- /* Index in the main table. */
+ /* Index in the main table. */
int main_index;
} *maintable, **ordered_table;
+
int otlen = 0;
int ottotlen = 0;
int opcode_count = 0;
-/* The set of possible completers for an opcode. */
+/* The set of possible completers for an opcode. */
struct completer_entry
{
- /* This entry's index in the ia64_completer_table[] array. */
+ /* This entry's index in the ia64_completer_table[] array. */
int num;
- /* The name of the completer. */
+ /* The name of the completer. */
struct string_entry *name;
- /* This entry's parent. */
+ /* This entry's parent. */
struct completer_entry *parent;
/* Set if this is a terminal completer (occurs at the end of an
- opcode). */
+ opcode). */
int is_terminal;
- /* An alternative completer. */
+ /* An alternative completer. */
struct completer_entry *alternative;
/* Additional completers that can be appended to this one. */
@@ -100,53 +106,53 @@ struct completer_entry
/* Before compute_completer_bits () is invoked, this contains the actual
instruction opcode for this combination of opcode and completers.
Afterwards, it contains those bits that are different from its
- parent opcode. */
+ parent opcode. */
ia64_insn bits;
/* Bits set to 1 correspond to those bits in this completer's opcode
that are different from its parent completer's opcode (or from
the base opcode if the entry is the root of the opcode's completer
- list). This field is filled in by compute_completer_bits (). */
+ list). This field is filled in by compute_completer_bits (). */
ia64_insn mask;
- /* Index into the opcode dependency list, or -1 if none. */
+ /* Index into the opcode dependency list, or -1 if none. */
int dependencies;
/* Remember the order encountered in the opcode tables. */
int order;
};
-/* One entry in the disassembler name table. */
+/* One entry in the disassembler name table. */
struct disent
{
- /* The index into the ia64_name_dis array for this entry. */
+ /* The index into the ia64_name_dis array for this entry. */
int ournum;
- /* The index into the main_table[] array. */
+ /* The index into the main_table[] array. */
int insn;
- /* The disassmbly priority of this entry. */
+ /* The disassmbly priority of this entry. */
int priority;
- /* The completer_index value for this entry. */
+ /* The completer_index value for this entry. */
int completer_index;
- /* How many other entries share this decode. */
+ /* How many other entries share this decode. */
int nextcnt;
- /* The next entry sharing the same decode. */
+ /* The next entry sharing the same decode. */
struct disent *nexte;
- /* The next entry in the name list. */
+ /* The next entry in the name list. */
struct disent *next_ent;
} *disinsntable = NULL;
/* A state machine that will eventually be used to generate the
- disassembler table. */
+ disassembler table. */
struct bittree
{
struct disent *disent;
- struct bittree *bits[3]; /* 0, 1, and X (don't care) */
+ struct bittree *bits[3]; /* 0, 1, and X (don't care). */
int bits_to_skip;
int skip_flag;
} *bittree;
@@ -154,62 +160,63 @@ struct bittree
/* The string table contains all opcodes and completers sorted in
alphabetical order. */
-/* One entry in the string table. */
+/* One entry in the string table. */
struct string_entry
{
- /* The index in the ia64_strings[] array for this entry. */
+ /* The index in the ia64_strings[] array for this entry. */
int num;
- /* And the string. */
+ /* And the string. */
char *s;
} **string_table = NULL;
+
int strtablen = 0;
int strtabtotlen = 0;
-/* resource dependency entries */
+/* Resource dependency entries. */
struct rdep
{
- char *name; /* resource name */
+ char *name; /* Resource name. */
unsigned
- mode:2, /* RAW, WAW, or WAR */
- semantics:3; /* dependency semantics */
- char *extra; /* additional semantics info */
+ mode:2, /* RAW, WAW, or WAR. */
+ semantics:3; /* Dependency semantics. */
+ char *extra; /* Additional semantics info. */
int nchks;
- int total_chks; /* total #of terminal insns */
- int *chks; /* insn classes which read (RAW), write
- (WAW), or write (WAR) this rsrc */
- int *chknotes; /* dependency notes for each class */
+ int total_chks; /* Total #of terminal insns. */
+ int *chks; /* Insn classes which read (RAW), write
+ (WAW), or write (WAR) this rsrc. */
+ int *chknotes; /* Dependency notes for each class. */
int nregs;
- int total_regs; /* total #of terminal insns */
- int *regs; /* insn class which write (RAW), write2
- (WAW), or read (WAR) this rsrc */
- int *regnotes; /* dependency notes for each class */
+ int total_regs; /* Total #of terminal insns. */
+ int *regs; /* Insn class which write (RAW), write2
+ (WAW), or read (WAR) this rsrc. */
+ int *regnotes; /* Dependency notes for each class. */
- int waw_special; /* special WAW dependency note */
+ int waw_special; /* Special WAW dependency note. */
} **rdeps = NULL;
static int rdepslen = 0;
static int rdepstotlen = 0;
-/* array of all instruction classes */
+/* Array of all instruction classes. */
struct iclass
{
- char *name; /* instruction class name */
- int is_class; /* is a class, not a terminal */
+ char *name; /* Instruction class name. */
+ int is_class; /* Is a class, not a terminal. */
int nsubs;
- int *subs; /* other classes within this class */
+ int *subs; /* Other classes within this class. */
int nxsubs;
- int xsubs[4]; /* exclusions */
- char *comment; /* optional comment */
- int note; /* optional note */
- int terminal_resolved; /* did we match this with anything? */
- int orphan; /* detect class orphans */
+ int xsubs[4]; /* Exclusions. */
+ char *comment; /* Optional comment. */
+ int note; /* Optional note. */
+ int terminal_resolved; /* Did we match this with anything? */
+ int orphan; /* Detect class orphans. */
} **ics = NULL;
static int iclen = 0;
static int ictotlen = 0;
-/* an opcode dependency (chk/reg pair of dependency lists) */
+/* An opcode dependency (chk/reg pair of dependency lists). */
struct opdep
{
int chk; /* index into dlists */
@@ -219,7 +226,7 @@ struct opdep
static int opdeplen = 0;
static int opdeptotlen = 0;
-/* a generic list of dependencies w/notes encoded. these may be shared. */
+/* A generic list of dependencies w/notes encoded. These may be shared. */
struct deplist
{
int len;
@@ -229,7 +236,81 @@ struct deplist
static int dlistlen = 0;
static int dlisttotlen = 0;
-/* add NAME to the resource table, where TYPE is RAW or WAW */
+
+static void fail (const char *, ...);
+static void warn (const char *, ...);
+static struct rdep * insert_resource (const char *, enum ia64_dependency_mode);
+static int deplist_equals (struct deplist *, struct deplist *);
+static short insert_deplist (int, unsigned short *);
+static short insert_dependencies (int, unsigned short *, int, unsigned short *);
+static void mark_used (struct iclass *, int);
+static int fetch_insn_class (const char *, int);
+static int sub_compare (const void *, const void *);
+static void load_insn_classes (void);
+static void parse_resource_users (const char *, int **, int *, int **);
+static int parse_semantics (char *);
+static void add_dep (const char *, const char *, const char *, int, int, char *, int);
+static void load_depfile (const char *, enum ia64_dependency_mode);
+static void load_dependencies (void);
+static int irf_operand (int, const char *);
+static int in_iclass_mov_x (struct ia64_opcode *, struct iclass *, const char *, const char *);
+static int in_iclass (struct ia64_opcode *, struct iclass *, const char *, const char *, int *);
+static int lookup_regindex (const char *, int);
+static int lookup_specifier (const char *);
+static void print_dependency_table (void);
+static struct string_entry * insert_string (char *);
+static void gen_dis_table (struct bittree *);
+static void print_dis_table (void);
+static void generate_disassembler (void);
+static void print_string_table (void);
+static int completer_entries_eq (struct completer_entry *, struct completer_entry *);
+static struct completer_entry * insert_gclist (struct completer_entry *);
+static int get_prefix_len (const char *);
+static void compute_completer_bits (struct main_entry *, struct completer_entry *);
+static void collapse_redundant_completers (void);
+static int insert_opcode_dependencies (struct ia64_opcode *, struct completer_entry *);
+static void insert_completer_entry (struct ia64_opcode *, struct main_entry *, int);
+static void print_completer_entry (struct completer_entry *);
+static void print_completer_table (void);
+static int opcodes_eq (struct ia64_opcode *, struct ia64_opcode *);
+static void add_opcode_entry (struct ia64_opcode *);
+static void print_main_table (void);
+static void shrink (struct ia64_opcode *);
+static void print_version (void);
+static void usage (FILE *, int);
+static void finish_distable (void);
+static void insert_bit_table_ent (struct bittree *, int, ia64_insn, ia64_insn, int, int, int);
+static void add_dis_entry (struct bittree *, ia64_insn, ia64_insn, int, struct completer_entry *, int);
+static void compact_distree (struct bittree *);
+static struct bittree * make_bittree_entry (void);
+static struct disent * add_dis_table_ent (struct disent *, int, int, int);
+
+
+static void
+fail (const char *message, ...)
+{
+ va_list args;
+
+ va_start (args, message);
+ fprintf (stderr, _("%s: Error: "), program_name);
+ vfprintf (stderr, message, args);
+ va_end (args);
+ xexit (1);
+}
+
+static void
+warn (const char *message, ...)
+{
+ va_list args;
+
+ va_start (args, message);
+
+ fprintf (stderr, _("%s: Warning: "), program_name);
+ vfprintf (stderr, message, args);
+ va_end (args);
+}
+
+/* Add NAME to the resource table, where TYPE is RAW or WAW. */
static struct rdep *
insert_resource (const char *name, enum ia64_dependency_mode type)
{
@@ -248,7 +329,7 @@ insert_resource (const char *name, enum ia64_dependency_mode type)
return rdeps[rdepslen++];
}
-/* are the lists of dependency indexes equivalent? */
+/* Are the lists of dependency indexes equivalent? */
static int
deplist_equals (struct deplist *d1, struct deplist *d2)
{
@@ -257,55 +338,48 @@ deplist_equals (struct deplist *d1, struct deplist *d2)
if (d1->len != d2->len)
return 0;
- for (i=0;i < d1->len;i++)
- {
- if (d1->deps[i] != d2->deps[i])
- return 0;
- }
+ for (i = 0; i < d1->len; i++)
+ if (d1->deps[i] != d2->deps[i])
+ return 0;
return 1;
}
-/* add the list of dependencies to the list of dependency lists */
+/* Add the list of dependencies to the list of dependency lists. */
static short
-insert_deplist(int count, unsigned short *deps)
+insert_deplist (int count, unsigned short *deps)
{
- /* sort the list, then see if an equivalent list exists already.
- this results in a much smaller set of dependency lists
- */
+ /* Sort the list, then see if an equivalent list exists already.
+ this results in a much smaller set of dependency lists. */
struct deplist *list;
char set[0x10000];
int i;
- memset ((void *)set, 0, sizeof(set));
- for (i=0;i < count;i++)
+ memset ((void *)set, 0, sizeof (set));
+ for (i = 0; i < count; i++)
set[deps[i]] = 1;
+
count = 0;
- for (i=0;i < (int)sizeof(set);i++)
+ for (i = 0; i < (int) sizeof (set); i++)
if (set[i])
++count;
- list = tmalloc(struct deplist);
+ list = tmalloc (struct deplist);
list->len = count;
- list->deps = (unsigned short *)malloc (sizeof(unsigned short) * count);
- for (i=0, count=0;i < (int)sizeof(set);i++)
- {
- if (set[i])
- {
- list->deps[count++] = i;
- }
- }
+ list->deps = (unsigned short *) malloc (sizeof (unsigned short) * count);
- /* does this list exist already? */
- for (i=0;i < dlistlen;i++)
- {
- if (deplist_equals (list, dlists[i]))
- {
- free (list->deps);
- free (list);
- return i;
- }
- }
+ for (i = 0, count = 0; i < (int) sizeof (set); i++)
+ if (set[i])
+ list->deps[count++] = i;
+
+ /* Does this list exist already? */
+ for (i = 0; i < dlistlen; i++)
+ if (deplist_equals (list, dlists[i]))
+ {
+ free (list->deps);
+ free (list);
+ return i;
+ }
if (dlistlen == dlisttotlen)
{
@@ -318,7 +392,7 @@ insert_deplist(int count, unsigned short *deps)
return dlistlen++;
}
-/* add the given pair of dependency lists to the opcode dependency list */
+/* Add the given pair of dependency lists to the opcode dependency list. */
static short
insert_dependencies (int nchks, unsigned short *chks,
int nregs, unsigned short *regs)
@@ -333,13 +407,12 @@ insert_dependencies (int nchks, unsigned short *chks,
if (nchks > 0)
chkind = insert_deplist (nchks, chks);
- for (i=0;i < opdeplen;i++)
- {
- if (opdeps[i]->chk == chkind
- && opdeps[i]->reg == regind)
- return i;
- }
- pair = tmalloc(struct opdep);
+ for (i = 0; i < opdeplen; i++)
+ if (opdeps[i]->chk == chkind
+ && opdeps[i]->reg == regind)
+ return i;
+
+ pair = tmalloc (struct opdep);
pair->chk = chkind;
pair->reg = regind;
@@ -363,20 +436,17 @@ mark_used (struct iclass *ic, int clear_terminals)
if (clear_terminals)
ic->terminal_resolved = 1;
- for (i=0;i < ic->nsubs;i++)
- {
- mark_used (ics[ic->subs[i]], clear_terminals);
- }
- for (i=0;i < ic->nxsubs;i++)
- {
- mark_used (ics[ic->xsubs[i]], clear_terminals);
- }
+ for (i = 0; i < ic->nsubs; i++)
+ mark_used (ics[ic->subs[i]], clear_terminals);
+
+ for (i = 0; i < ic->nxsubs; i++)
+ mark_used (ics[ic->xsubs[i]], clear_terminals);
}
-/* look up an instruction class; if CREATE make a new one if none found;
- returns the index into the insn class array */
+/* Look up an instruction class; if CREATE make a new one if none found;
+ returns the index into the insn class array. */
static int
-fetch_insn_class(const char *full_name, int create)
+fetch_insn_class (const char *full_name, int create)
{
char *name;
char *notestr;
@@ -414,14 +484,14 @@ fetch_insn_class(const char *full_name, int create)
if (notestr)
{
char *nextnotestr;
+
note = atoi (notestr + 1);
if ((nextnotestr = strchr (notestr + 1, '+')) != NULL)
{
if (strcmp (notestr, "+1+13") == 0)
note = 13;
else if (!xsect || nextnotestr < xsect)
- fprintf (stderr, "Warning: multiple note %s not handled\n",
- notestr);
+ warn (_("multiple note %s not handled\n"), notestr);
}
}
@@ -436,8 +506,8 @@ fetch_insn_class(const char *full_name, int create)
*comment = 0;
}
- for (i=0;i < iclen;i++)
- if (strcmp(name, ics[i]->name) == 0
+ for (i = 0; i < iclen; i++)
+ if (strcmp (name, ics[i]->name) == 0
&& ((comment == NULL && ics[i]->comment == NULL)
|| (comment != NULL && ics[i]->comment != NULL
&& strncmp (ics[i]->comment, comment,
@@ -448,40 +518,44 @@ fetch_insn_class(const char *full_name, int create)
if (!create)
return -1;
- /* doesn't exist, so make a new one */
+ /* Doesn't exist, so make a new one. */
if (iclen == ictotlen)
{
ictotlen += 20;
ics = (struct iclass **)
- xrealloc(ics, (ictotlen)*sizeof(struct iclass *));
+ xrealloc (ics, (ictotlen) * sizeof (struct iclass *));
}
+
ind = iclen++;
- ics[ind] = tmalloc(struct iclass);
- memset((void *)ics[ind], 0, sizeof(struct iclass));
- ics[ind]->name = xstrdup(name);
+ ics[ind] = tmalloc (struct iclass);
+ memset ((void *)ics[ind], 0, sizeof (struct iclass));
+ ics[ind]->name = xstrdup (name);
ics[ind]->is_class = is_class;
ics[ind]->orphan = 1;
if (comment)
{
ics[ind]->comment = xstrdup (comment + 1);
- ics[ind]->comment[strlen(ics[ind]->comment)-1] = 0;
+ ics[ind]->comment[strlen (ics[ind]->comment)-1] = 0;
}
+
if (notestr)
ics[ind]->note = note;
- /* if it's a composite class, there's a comment or note, look for an
- existing class or terminal with the same name. */
+ /* If it's a composite class, there's a comment or note, look for an
+ existing class or terminal with the same name. */
if ((xsect || comment || notestr) && is_class)
{
/* First, populate with the class we're based on. */
char *subname = name;
+
if (xsect)
*xsect = 0;
else if (comment)
*comment = 0;
else if (notestr)
*notestr = 0;
+
ics[ind]->nsubs = 1;
ics[ind]->subs = tmalloc(int);
ics[ind]->subs[0] = fetch_insn_class (subname, 1);;
@@ -490,6 +564,7 @@ fetch_insn_class(const char *full_name, int create)
while (xsect)
{
char *subname = xsect + 1;
+
xsect = strchr (subname, '\\');
if (xsect)
*xsect = 0;
@@ -501,8 +576,8 @@ fetch_insn_class(const char *full_name, int create)
return ind;
}
-/* for sorting a class's sub-class list only; make sure classes appear before
- terminals */
+/* For sorting a class's sub-class list only; make sure classes appear before
+ terminals. */
static int
sub_compare (const void *e1, const void *e2)
{
@@ -521,41 +596,39 @@ sub_compare (const void *e1, const void *e2)
}
static void
-load_insn_classes()
+load_insn_classes (void)
{
- FILE *fp = fopen("ia64-ic.tbl", "r");
+ FILE *fp = fopen ("ia64-ic.tbl", "r");
char buf[2048];
- if (fp == NULL){
- fprintf (stderr, "Can't find ia64-ic.tbl for reading\n");
- exit(1);
- }
+ if (fp == NULL)
+ fail (_("can't find ia64-ic.tbl for reading\n"));
- /* discard first line */
+ /* Discard first line. */
fgets (buf, sizeof(buf), fp);
- while (!feof(fp))
+ while (!feof (fp))
{
int iclass;
char *name;
char *tmp;
- if (fgets (buf, sizeof(buf), fp) == NULL)
+ if (fgets (buf, sizeof (buf), fp) == NULL)
break;
- while (ISSPACE (buf[strlen(buf)-1]))
- buf[strlen(buf)-1] = '\0';
+ while (ISSPACE (buf[strlen (buf) - 1]))
+ buf[strlen (buf) - 1] = '\0';
name = tmp = buf;
while (*tmp != ';')
{
++tmp;
- if (tmp == buf + sizeof(buf))
+ if (tmp == buf + sizeof (buf))
abort ();
}
*tmp++ = '\0';
- iclass = fetch_insn_class(name, 1);
+ iclass = fetch_insn_class (name, 1);
ics[iclass]->is_class = 1;
if (strcmp (name, "none") == 0)
@@ -565,7 +638,7 @@ load_insn_classes()
continue;
}
- /* for this class, record all sub-classes */
+ /* For this class, record all sub-classes. */
while (*tmp)
{
char *subname;
@@ -574,44 +647,43 @@ load_insn_classes()
while (*tmp && ISSPACE (*tmp))
{
++tmp;
- if (tmp == buf + sizeof(buf))
- abort();
+ if (tmp == buf + sizeof (buf))
+ abort ();
}
subname = tmp;
while (*tmp && *tmp != ',')
{
++tmp;
- if (tmp == buf + sizeof(buf))
- abort();
+ if (tmp == buf + sizeof (buf))
+ abort ();
}
if (*tmp == ',')
*tmp++ = '\0';
ics[iclass]->subs = (int *)
- xrealloc((void *)ics[iclass]->subs,
- (ics[iclass]->nsubs+1)*sizeof(int));
+ xrealloc ((void *)ics[iclass]->subs,
+ (ics[iclass]->nsubs + 1) * sizeof (int));
- sub = fetch_insn_class(subname, 1);
+ sub = fetch_insn_class (subname, 1);
ics[iclass]->subs = (int *)
- xrealloc(ics[iclass]->subs, (ics[iclass]->nsubs+1)*sizeof(int));
+ xrealloc (ics[iclass]->subs, (ics[iclass]->nsubs + 1) * sizeof (int));
ics[iclass]->subs[ics[iclass]->nsubs++] = sub;
}
- /* make sure classes come before terminals */
+
+ /* Make sure classes come before terminals. */
qsort ((void *)ics[iclass]->subs,
ics[iclass]->nsubs, sizeof(int), sub_compare);
}
- fclose(fp);
+ fclose (fp);
if (debug)
- {
- printf ("%d classes\n", iclen);
- }
+ printf ("%d classes\n", iclen);
}
-/* extract the insn classes from the given line */
+/* Extract the insn classes from the given line. */
static void
-parse_resource_users(ref, usersp, nusersp, notesp)
- char *ref;
+parse_resource_users (ref, usersp, nusersp, notesp)
+ const char *ref;
int **usersp;
int *nusersp;
int **notesp;
@@ -641,53 +713,49 @@ parse_resource_users(ref, usersp, nusersp, notesp)
c = *tmp;
*tmp++ = '\0';
- xsect = strchr(name, '\\');
- if ((notestr = strstr(name, "+")) != NULL)
+ xsect = strchr (name, '\\');
+ if ((notestr = strstr (name, "+")) != NULL)
{
char *nextnotestr;
+
note = atoi (notestr + 1);
if ((nextnotestr = strchr (notestr + 1, '+')) != NULL)
{
- /* note 13 always implies note 1 */
+ /* Note 13 always implies note 1. */
if (strcmp (notestr, "+1+13") == 0)
note = 13;
else if (!xsect || nextnotestr < xsect)
- fprintf (stderr, "Warning: multiple note %s not handled\n",
- notestr);
+ warn (_("multiple note %s not handled\n"), notestr);
}
if (!xsect)
*notestr = '\0';
}
else
note = 0;
-
+
/* All classes are created when the insn class table is parsed;
Individual instructions might not appear until the dependency tables
are read. Only create new classes if it's *not* an insn class,
or if it's a composite class (which wouldn't necessarily be in the IC
- table).
- */
- if (strncmp(name, "IC:", 3) != 0 || xsect != NULL)
+ table). */
+ if (strncmp (name, "IC:", 3) != 0 || xsect != NULL)
create = 1;
- iclass = fetch_insn_class(name, create);
+ iclass = fetch_insn_class (name, create);
if (iclass != -1)
{
users = (int *)
- xrealloc ((void *)users,(count+1)*sizeof(int));
+ xrealloc ((void *) users,(count + 1) * sizeof (int));
notes = (int *)
- xrealloc ((void *)notes,(count+1)*sizeof(int));
+ xrealloc ((void *) notes,(count + 1) * sizeof (int));
notes[count] = note;
users[count++] = iclass;
mark_used (ics[iclass], 0);
}
- else
- {
- if (debug)
- printf("Class %s not found\n", name);
- }
+ else if (debug)
+ printf("Class %s not found\n", name);
}
- /* update the return values */
+ /* Update the return values. */
*usersp = users;
*nusersp = count;
*notesp = notes;
@@ -723,10 +791,10 @@ add_dep (const char *name, const char *chk, const char *reg,
struct rdep *rs;
rs = insert_resource (name, mode);
- parse_resource_users (chk, &rs->chks, &rs->nchks,
- &rs->chknotes);
- parse_resource_users (reg, &rs->regs, &rs->nregs,
- &rs->regnotes);
+
+ parse_resource_users (chk, &rs->chks, &rs->nchks, &rs->chknotes);
+ parse_resource_users (reg, &rs->regs, &rs->nregs, &rs->regnotes);
+
rs->semantics = semantics;
rs->extra = extra;
rs->waw_special = flag;
@@ -735,16 +803,14 @@ add_dep (const char *name, const char *chk, const char *reg,
static void
load_depfile (const char *filename, enum ia64_dependency_mode mode)
{
- FILE *fp = fopen(filename, "r");
+ FILE *fp = fopen (filename, "r");
char buf[1024];
- if (fp == NULL){
- fprintf (stderr, "Can't find %s for reading\n", filename);
- exit(1);
- }
+ if (fp == NULL)
+ fail (_("can't find %s for reading\n"), filename);
- fgets(buf, sizeof(buf), fp);
- while (!feof(fp))
+ fgets (buf, sizeof(buf), fp);
+ while (!feof (fp))
{
char *name, *tmp;
int semantics;
@@ -754,8 +820,8 @@ load_depfile (const char *filename, enum ia64_dependency_mode mode)
if (fgets (buf, sizeof(buf), fp) == NULL)
break;
- while (ISSPACE (buf[strlen(buf)-1]))
- buf[strlen(buf)-1] = '\0';
+ while (ISSPACE (buf[strlen (buf) - 1]))
+ buf[strlen (buf) - 1] = '\0';
name = tmp = buf;
while (*tmp != ';')
@@ -783,7 +849,7 @@ load_depfile (const char *filename, enum ia64_dependency_mode mode)
/* For WAW entries, if the chks and regs differ, we need to enter the
entries in both positions so that the tables will be parsed properly,
- without a lot of extra work */
+ without a lot of extra work. */
if (mode == IA64_DV_WAW && strcmp (regp, chkp) != 0)
{
add_dep (name, chkp, regp, semantics, mode, extra, 0);
@@ -794,21 +860,21 @@ load_depfile (const char *filename, enum ia64_dependency_mode mode)
add_dep (name, chkp, regp, semantics, mode, extra, 0);
}
}
- fclose(fp);
+ fclose (fp);
}
static void
-load_dependencies()
+load_dependencies (void)
{
load_depfile ("ia64-raw.tbl", IA64_DV_RAW);
load_depfile ("ia64-waw.tbl", IA64_DV_WAW);
load_depfile ("ia64-war.tbl", IA64_DV_WAR);
if (debug)
- printf ("%d RAW/WAW/WAR dependencies\n", rdepslen);
+ printf ("%d RAW/WAW/WAR dependencies\n", rdepslen);
}
-/* is the given operand an indirect register file operand? */
+/* Is the given operand an indirect register file operand? */
static int
irf_operand (int op, const char *field)
{
@@ -832,8 +898,8 @@ irf_operand (int op, const char *field)
}
}
-/* handle mov_ar, mov_br, mov_cr, mov_indirect, mov_ip, mov_pr, mov_psr, and
- mov_um insn classes */
+/* Handle mov_ar, mov_br, mov_cr, mov_indirect, mov_ip, mov_pr, mov_psr, and
+ mov_um insn classes. */
static int
in_iclass_mov_x (struct ia64_opcode *idesc, struct iclass *ic,
const char *format, const char *field)
@@ -947,11 +1013,10 @@ in_iclass_mov_x (struct ia64_opcode *idesc, struct iclass *ic,
return 0;
}
-
-/* is the given opcode in the given insn class? */
+/* Is the given opcode in the given insn class? */
static int
-in_iclass(struct ia64_opcode *idesc, struct iclass *ic,
- const char *format, const char *field, int *notep)
+in_iclass (struct ia64_opcode *idesc, struct iclass *ic,
+ const char *format, const char *field, int *notep)
{
int i;
int resolved = 0;
@@ -960,15 +1025,14 @@ in_iclass(struct ia64_opcode *idesc, struct iclass *ic,
{
if (!strncmp (ic->comment, "Format", 6))
{
- /* assume that the first format seen is the most restrictive, and
- only keep a later one if it looks like it's more restrictive. */
+ /* Assume that the first format seen is the most restrictive, and
+ only keep a later one if it looks like it's more restrictive. */
if (format)
{
if (strlen (ic->comment) < strlen (format))
{
- fprintf (stderr, "Warning: most recent format '%s'\n"
- "appears more restrictive than '%s'\n",
- ic->comment, format);
+ warn (_("most recent format '%s'\nappears more restrictive than '%s'\n"),
+ ic->comment, format);
format = ic->comment;
}
}
@@ -978,15 +1042,15 @@ in_iclass(struct ia64_opcode *idesc, struct iclass *ic,
else if (!strncmp (ic->comment, "Field", 5))
{
if (field)
- fprintf (stderr, "Overlapping field %s->%s\n",
- ic->comment, field);
+ warn (_("overlapping field %s->%s\n"),
+ ic->comment, field);
field = ic->comment;
}
}
- /* an insn class matches anything that is the same followed by completers,
+ /* An insn class matches anything that is the same followed by completers,
except when the absence and presence of completers constitutes different
- instructions */
+ instructions. */
if (ic->nsubs == 0 && ic->nxsubs == 0)
{
int is_mov = strncmp (idesc->name, "mov", 3) == 0;
@@ -997,26 +1061,26 @@ in_iclass(struct ia64_opcode *idesc, struct iclass *ic,
&& (idesc->name[len] == '\0'
|| idesc->name[len] == '.'));
- /* all break and nop variations must match exactly */
+ /* All break, nop, and hint variations must match exactly. */
if (resolved &&
(strcmp (ic->name, "break") == 0
- || strcmp (ic->name, "nop") == 0))
+ || strcmp (ic->name, "nop") == 0
+ || strcmp (ic->name, "hint") == 0))
resolved = strcmp (ic->name, idesc->name) == 0;
- /* assume restrictions in the FORMAT/FIELD negate resolution,
- unless specifically allowed by clauses in this block */
+ /* Assume restrictions in the FORMAT/FIELD negate resolution,
+ unless specifically allowed by clauses in this block. */
if (resolved && field)
{
- /* check Field(sf)==sN against opcode sN */
+ /* Check Field(sf)==sN against opcode sN. */
if (strstr(field, "(sf)==") != NULL)
{
char *sf;
+
if ((sf = strstr (idesc->name, ".s")) != 0)
- {
- resolved = strcmp (sf + 1, strstr (field, "==") + 2) == 0;
- }
+ resolved = strcmp (sf + 1, strstr (field, "==") + 2) == 0;
}
- /* check Field(lftype)==XXX */
+ /* Check Field(lftype)==XXX. */
else if (strstr (field, "(lftype)") != NULL)
{
if (strstr (idesc->name, "fault") != NULL)
@@ -1024,7 +1088,7 @@ in_iclass(struct ia64_opcode *idesc, struct iclass *ic,
else
resolved = strstr (field, "fault") == NULL;
}
- /* handle Field(ctype)==XXX */
+ /* Handle Field(ctype)==XXX. */
else if (strstr (field, "(ctype)") != NULL)
{
if (strstr (idesc->name, "or.andcm"))
@@ -1045,6 +1109,7 @@ in_iclass(struct ia64_opcode *idesc, struct iclass *ic,
resolved = strcmp (field, "Field(ctype)==") == 0;
}
}
+
if (resolved && format)
{
if (strncmp (idesc->name, "dep", 3) == 0
@@ -1075,8 +1140,8 @@ in_iclass(struct ia64_opcode *idesc, struct iclass *ic,
resolved = 0;
}
- /* misc brl variations ('.cond' is optional);
- plain brl matches brl.cond */
+ /* Misc brl variations ('.cond' is optional);
+ plain brl matches brl.cond. */
if (!resolved
&& (strcmp (idesc->name, "brl") == 0
|| strncmp (idesc->name, "brl.", 4) == 0)
@@ -1085,7 +1150,7 @@ in_iclass(struct ia64_opcode *idesc, struct iclass *ic,
resolved = 1;
}
- /* misc br variations ('.cond' is optional) */
+ /* Misc br variations ('.cond' is optional). */
if (!resolved
&& (strcmp (idesc->name, "br") == 0
|| strncmp (idesc->name, "br.", 3) == 0)
@@ -1100,81 +1165,77 @@ in_iclass(struct ia64_opcode *idesc, struct iclass *ic,
resolved = 1;
}
- /* probe variations */
+ /* probe variations. */
if (!resolved && strncmp (idesc->name, "probe", 5) == 0)
{
resolved = strcmp (ic->name, "probe") == 0
&& !((strstr (idesc->name, "fault") != NULL)
^ (format && strstr (format, "M40") != NULL));
}
- /* mov variations */
+
+ /* mov variations. */
if (!resolved && is_mov)
{
if (plain_mov)
{
- /* mov alias for fmerge */
+ /* mov alias for fmerge. */
if (strcmp (ic->name, "fmerge") == 0)
{
resolved = idesc->operands[0] == IA64_OPND_F1
&& idesc->operands[1] == IA64_OPND_F3;
}
- /* mov alias for adds (r3 or imm14) */
+ /* mov alias for adds (r3 or imm14). */
else if (strcmp (ic->name, "adds") == 0)
{
resolved = (idesc->operands[0] == IA64_OPND_R1
&& (idesc->operands[1] == IA64_OPND_R3
|| (idesc->operands[1] == IA64_OPND_IMM14)));
}
- /* mov alias for addl */
+ /* mov alias for addl. */
else if (strcmp (ic->name, "addl") == 0)
{
resolved = idesc->operands[0] == IA64_OPND_R1
&& idesc->operands[1] == IA64_OPND_IMM22;
}
}
- /* some variants of mov and mov.[im] */
+
+ /* Some variants of mov and mov.[im]. */
if (!resolved && strncmp (ic->name, "mov_", 4) == 0)
- {
- resolved = in_iclass_mov_x (idesc, ic, format, field);
- }
+ resolved = in_iclass_mov_x (idesc, ic, format, field);
}
- /* keep track of this so we can flag any insn classes which aren't
- mapped onto at least one real insn */
+ /* Keep track of this so we can flag any insn classes which aren't
+ mapped onto at least one real insn. */
if (resolved)
- {
- ic->terminal_resolved = 1;
- }
+ ic->terminal_resolved = 1;
}
- else for (i=0;i < ic->nsubs;i++)
+ else for (i = 0; i < ic->nsubs; i++)
{
- if (in_iclass(idesc, ics[ic->subs[i]], format, field, notep))
+ if (in_iclass (idesc, ics[ic->subs[i]], format, field, notep))
{
int j;
- for (j=0;j < ic->nxsubs;j++)
- {
- if (in_iclass(idesc, ics[ic->xsubs[j]], NULL, NULL, NULL))
- return 0;
- }
+
+ for (j = 0; j < ic->nxsubs; j++)
+ if (in_iclass (idesc, ics[ic->xsubs[j]], NULL, NULL, NULL))
+ return 0;
+
if (debug > 1)
- printf ("%s is in IC %s\n",
- idesc->name, ic->name);
+ printf ("%s is in IC %s\n", idesc->name, ic->name);
+
resolved = 1;
break;
}
}
- /* If it's in this IC, add the IC note (if any) to the insn */
+ /* If it's in this IC, add the IC note (if any) to the insn. */
if (resolved)
{
if (ic->note && notep)
{
if (*notep && *notep != ic->note)
- {
- fprintf (stderr, "Warning: overwriting note %d with note %d"
- "(IC:%s)\n",
- *notep, ic->note, ic->name);
- }
+ warn (_("overwriting note %d with note %d (IC:%s)\n"),
+ *notep, ic->note, ic->name);
+
*notep = ic->note;
}
}
@@ -1197,6 +1258,22 @@ lookup_regindex (const char *name, int specifier)
return 18;
else if (strstr (name, "[RNAT]"))
return 19;
+ else if (strstr (name, "[FCR]"))
+ return 21;
+ else if (strstr (name, "[EFLAG]"))
+ return 24;
+ else if (strstr (name, "[CSD]"))
+ return 25;
+ else if (strstr (name, "[SSD]"))
+ return 26;
+ else if (strstr (name, "[CFLG]"))
+ return 27;
+ else if (strstr (name, "[FSR]"))
+ return 28;
+ else if (strstr (name, "[FIR]"))
+ return 29;
+ else if (strstr (name, "[FDR]"))
+ return 30;
else if (strstr (name, "[CCV]"))
return 32;
else if (strstr (name, "[ITC]"))
@@ -1355,8 +1432,8 @@ lookup_specifier (const char *name)
if (strstr (name, "PR%, % in 16 ") != NULL)
return IA64_RS_PRr;
- fprintf (stderr, "Warning! Don't know how to specify %% dependency %s\n",
- name);
+ warn (_("don't know how to specify %% dependency %s\n"),
+ name);
}
else if (strchr (name, '#'))
{
@@ -1377,8 +1454,8 @@ lookup_specifier (const char *name)
if (strstr (name, "RR#") != NULL)
return IA64_RS_RR;
- fprintf (stderr, "Warning! Don't know how to specify # dependency %s\n",
- name);
+ warn (_("Don't know how to specify # dependency %s\n"),
+ name);
}
else if (strncmp (name, "AR[FPSR]", 8) == 0)
return IA64_RS_AR_FPSR;
@@ -1402,7 +1479,7 @@ lookup_specifier (const char *name)
return IA64_RS_ANY;
}
-void
+static void
print_dependency_table ()
{
int i, j;
@@ -1415,58 +1492,59 @@ print_dependency_table ()
{
if (!ics[i]->nsubs)
{
- fprintf (stderr, "Warning: IC:%s", ics[i]->name);
if (ics[i]->comment)
- fprintf (stderr, "[%s]", ics[i]->comment);
- fprintf (stderr, " has no terminals or sub-classes\n");
+ warn (_("IC:%s [%s] has no terminals or sub-classes\n"),
+ ics[i]->name, ics[i]->comment);
+ else
+ warn (_("IC:%s has no terminals or sub-classes\n"),
+ ics[i]->name);
}
}
else
{
if (!ics[i]->terminal_resolved && !ics[i]->orphan)
{
- fprintf(stderr, "Warning: no insns mapped directly to "
- "terminal IC %s", ics[i]->name);
if (ics[i]->comment)
- fprintf(stderr, "[%s] ", ics[i]->comment);
- fprintf(stderr, "\n");
+ warn (_("no insns mapped directly to terminal IC %s [%s]"),
+ ics[i]->name, ics[i]->comment);
+ else
+ warn (_("no insns mapped directly to terminal IC %s\n"),
+ ics[i]->name);
}
}
}
- for (i=0;i < iclen;i++)
+ for (i = 0; i < iclen; i++)
{
if (ics[i]->orphan)
{
mark_used (ics[i], 1);
- fprintf (stderr, "Warning: class %s is defined but not used\n",
- ics[i]->name);
+ warn (_("class %s is defined but not used\n"),
+ ics[i]->name);
}
}
- if (debug > 1) for (i=0;i < rdepslen;i++)
- {
- static const char *mode_str[] = { "RAW", "WAW", "WAR" };
- if (rdeps[i]->total_chks == 0)
- {
- fprintf (stderr, "Warning: rsrc %s (%s) has no chks%s\n",
- rdeps[i]->name, mode_str[rdeps[i]->mode],
- rdeps[i]->total_regs ? "" : " or regs");
- }
- else if (rdeps[i]->total_regs == 0)
- {
- fprintf (stderr, "Warning: rsrc %s (%s) has no regs\n",
- rdeps[i]->name, mode_str[rdeps[i]->mode]);
- }
- }
+ if (debug > 1)
+ for (i = 0; i < rdepslen; i++)
+ {
+ static const char *mode_str[] = { "RAW", "WAW", "WAR" };
+
+ if (rdeps[i]->total_chks == 0)
+ warn (_("Warning: rsrc %s (%s) has no chks%s\n"),
+ rdeps[i]->name, mode_str[rdeps[i]->mode],
+ rdeps[i]->total_regs ? "" : " or regs");
+ else if (rdeps[i]->total_regs == 0)
+ warn (_("rsrc %s (%s) has no regs\n"),
+ rdeps[i]->name, mode_str[rdeps[i]->mode]);
+ }
}
- /* the dependencies themselves */
+ /* The dependencies themselves. */
printf ("static const struct ia64_dependency\ndependencies[] = {\n");
- for (i=0;i < rdepslen;i++)
+ for (i = 0; i < rdepslen; i++)
{
/* '%', '#', AR[], CR[], or PSR. indicates we need to specify the actual
- resource used */
+ resource used. */
int specifier = lookup_specifier (rdeps[i]->name);
int regindex = lookup_regindex (rdeps[i]->name, specifier);
@@ -1481,7 +1559,7 @@ print_dependency_table ()
}
printf ("};\n\n");
- /* and dependency lists */
+ /* And dependency lists. */
for (i=0;i < dlistlen;i++)
{
int len = 2;
@@ -1498,11 +1576,11 @@ print_dependency_table ()
printf ("\n};\n\n");
}
- /* and opcode dependency list */
+ /* And opcode dependency list. */
printf ("#define NELS(X) (sizeof(X)/sizeof(X[0]))\n");
printf ("static const struct ia64_opcode_dependency\n");
printf ("op_dependencies[] = {\n");
- for (i=0;i < opdeplen;i++)
+ for (i = 0; i < opdeplen; i++)
{
printf (" { ");
if (opdeps[i]->chk == -1)
@@ -1519,11 +1597,9 @@ print_dependency_table ()
}
-/* Add STR to the string table. */
-
+/* Add STR to the string table. */
static struct string_entry *
-insert_string (str)
- char *str;
+insert_string (char *str)
{
int start = 0, end = strtablen;
int i, x;
@@ -1546,13 +1622,9 @@ insert_string (str)
}
if (strcmp (str, string_table[strtablen - 1]->s) > 0)
- {
- i = end;
- }
+ i = end;
else if (strcmp (str, string_table[0]->s) < 0)
- {
- i = 0;
- }
+ i = 0;
else
{
while (1)
@@ -1561,52 +1633,43 @@ insert_string (str)
i = (start + end) / 2;
c = strcmp (str, string_table[i]->s);
+
if (c < 0)
- {
- end = i - 1;
- }
+ end = i - 1;
else if (c == 0)
- {
- return string_table[i];
- }
+ return string_table[i];
else
- {
- start = i + 1;
- }
+ start = i + 1;
+
if (start > end)
- {
- break;
- }
+ break;
}
}
+
for (; i > 0 && i < strtablen; i--)
- {
- if (strcmp (str, string_table[i - 1]->s) > 0)
- {
- break;
- }
- }
+ if (strcmp (str, string_table[i - 1]->s) > 0)
+ break;
+
for (; i < strtablen; i++)
- {
- if (strcmp (str, string_table[i]->s) < 0)
- {
- break;
- }
- }
+ if (strcmp (str, string_table[i]->s) < 0)
+ break;
+
for (x = strtablen - 1; x >= i; x--)
{
string_table[x + 1] = string_table[x];
string_table[x + 1]->num = x + 1;
}
+
string_table[i] = tmalloc (struct string_entry);
string_table[i]->s = xstrdup (str);
string_table[i]->num = i;
strtablen++;
+
return string_table[i];
}
-struct bittree *
-make_bittree_entry ()
+static struct bittree *
+make_bittree_entry (void)
{
struct bittree *res = tmalloc (struct bittree);
@@ -1618,8 +1681,9 @@ make_bittree_entry ()
res->bits_to_skip = 0;
return res;
}
+
-struct disent *
+static struct disent *
add_dis_table_ent (which, insn, order, completer_index)
struct disent *which;
int insn;
@@ -1635,9 +1699,8 @@ add_dis_table_ent (which, insn, order, completer_index)
ent->nextcnt++;
while (ent->nexte != NULL)
- {
- ent = ent->nexte;
- }
+ ent = ent->nexte;
+
ent = (ent->nexte = tmalloc (struct disent));
}
else
@@ -1661,7 +1724,7 @@ add_dis_table_ent (which, insn, order, completer_index)
return which;
}
-void
+static void
finish_distable ()
{
struct disent *ent = disinsntable;
@@ -1675,7 +1738,7 @@ finish_distable ()
}
}
-void
+static void
insert_bit_table_ent (curr_ent, bit, opcode, mask,
opcodenum, order, completer_index)
struct bittree *curr_ent;
@@ -1702,13 +1765,10 @@ insert_bit_table_ent (curr_ent, bit, opcode, mask,
m = ((ia64_insn) 1) << bit;
if (mask & m)
- {
- b = (opcode & m) ? 1 : 0;
- }
+ b = (opcode & m) ? 1 : 0;
else
- {
- b = 2;
- }
+ b = 2;
+
next = curr_ent->bits[b];
if (next == NULL)
{
@@ -1719,7 +1779,7 @@ insert_bit_table_ent (curr_ent, bit, opcode, mask,
completer_index);
}
-void
+static void
add_dis_entry (first, opcode, mask, opcodenum, ent, completer_index)
struct bittree *first;
ia64_insn opcode;
@@ -1729,15 +1789,14 @@ add_dis_entry (first, opcode, mask, opcodenum, ent, completer_index)
int completer_index;
{
if (completer_index & (1 << 20))
- {
- abort ();
- }
+ abort ();
while (ent != NULL)
{
ia64_insn newopcode = (opcode & (~ ent->mask)) | ent->bits;
add_dis_entry (first, newopcode, mask, opcodenum, ent->addl_entries,
(completer_index << 1) | 1);
+
if (ent->is_terminal)
{
insert_bit_table_ent (bittree, 40, newopcode, mask,
@@ -1749,8 +1808,8 @@ add_dis_entry (first, opcode, mask, opcodenum, ent, completer_index)
}
}
-/* This optimization pass combines multiple "don't care" nodes. */
-void
+/* This optimization pass combines multiple "don't care" nodes. */
+static void
compact_distree (ent)
struct bittree *ent;
{
@@ -1790,10 +1849,9 @@ compact_distree (ent)
for (x = 0; x < 3; x++)
{
struct bittree *i = ent->bits[x];
+
if (i != NULL)
- {
- compact_distree (i);
- }
+ compact_distree (i);
}
}
@@ -1803,7 +1861,7 @@ static int tot_insn_list_len = 0;
/* Generate the disassembler state machine corresponding to the tree
in ENT. */
-void
+static void
gen_dis_table (ent)
struct bittree *ent;
{
@@ -1813,47 +1871,37 @@ gen_dis_table (ent)
int totbits = bitsused;
int needed_bytes;
int zero_count = 0;
- int zero_dest = 0; /* initialize this with 0 to keep gcc quiet... */
+ int zero_dest = 0; /* Initialize this with 0 to keep gcc quiet... */
/* If this is a terminal entry, there's no point in skipping any
- bits. */
+ bits. */
if (ent->skip_flag && ent->bits[0] == NULL && ent->bits[1] == NULL &&
ent->bits[2] == NULL)
{
if (ent->disent == NULL)
- {
- abort ();
- }
+ abort ();
else
- {
- ent->skip_flag = 0;
- }
+ ent->skip_flag = 0;
}
/* Calculate the amount of space needed for this entry, or at least
- a conservatively large approximation. */
+ a conservatively large approximation. */
if (ent->skip_flag)
- {
- totbits += 5;
- }
+ totbits += 5;
+
for (x = 1; x < 3; x++)
- {
- if (ent->bits[x] != NULL)
- {
- totbits += 16;
- }
- }
+ if (ent->bits[x] != NULL)
+ totbits += 16;
if (ent->disent != NULL)
{
if (ent->bits[2] != NULL)
- {
- abort ();
- }
+ abort ();
+
totbits += 16;
}
- /* Now allocate the space. */
+ /* Now allocate the space. */
needed_bytes = (totbits + 7) / 8;
if ((needed_bytes + insn_list_len) > tot_insn_list_len)
{
@@ -1865,7 +1913,7 @@ gen_dis_table (ent)
memset (insn_list + our_offset, 0, needed_bytes);
/* Encode the skip entry by setting bit 6 set in the state op field,
- and store the # of bits to skip immediately after. */
+ and store the # of bits to skip immediately after. */
if (ent->skip_flag)
{
bitsused += 5;
@@ -1878,8 +1926,7 @@ gen_dis_table (ent)
&& (ENT)->disent == NULL && (ENT)->skip_flag == 0)
/* Store an "if (bit is zero)" instruction by setting bit 7 in the
- state op field. */
-
+ state op field. */
if (ent->bits[0] != NULL)
{
struct bittree *nent = ent->bits[0];
@@ -1929,14 +1976,10 @@ gen_dis_table (ent)
i = NULL;
}
else
- {
- idest = insn_list_len - our_offset;
- }
+ idest = insn_list_len - our_offset;
}
else
- {
- idest = ent->disent->ournum;
- }
+ idest = ent->disent->ournum;
/* If the destination offset for the if (bit is 1) test is less
than 256 bytes away, we can store it as 8-bits instead of 16;
@@ -1946,8 +1989,7 @@ gen_dis_table (ent)
Note that branchings within the table are relative, and
there are no branches that branch past our instruction yet
- so we do not need to adjust any other offsets. */
-
+ so we do not need to adjust any other offsets. */
if (x == 1)
{
if (idest <= 256)
@@ -1965,9 +2007,7 @@ gen_dis_table (ent)
idest--;
}
else
- {
- insn_list[our_offset] |= 0x20;
- }
+ insn_list[our_offset] |= 0x20;
}
else
{
@@ -1996,74 +2036,58 @@ gen_dis_table (ent)
idest &= ~32768;
}
else
- {
- insn_list[our_offset] |= 0x08;
- }
+ insn_list[our_offset] |= 0x08;
}
+
if (debug)
{
int id = idest;
if (i == NULL)
- {
- id |= 32768;
- }
+ id |= 32768;
else if (! (id & 32768))
- {
- id += our_offset;
- }
+ id += our_offset;
+
if (x == 1)
- {
- printf ("%d: if (1) goto %d\n", our_offset, id);
- }
+ printf ("%d: if (1) goto %d\n", our_offset, id);
else
- {
- printf ("%d: try %d\n", our_offset, id);
- }
+ printf ("%d: try %d\n", our_offset, id);
}
- /* Store the address of the entry being branched to. */
+ /* Store the address of the entry being branched to. */
while (currbits >= 0)
{
char *byte = insn_list + our_offset + bitsused / 8;
if (idest & (1 << currbits))
- {
- *byte |= (1 << (7 - (bitsused % 8)));
- }
+ *byte |= (1 << (7 - (bitsused % 8)));
+
bitsused++;
currbits--;
}
- /* Now generate the states for the entry being branched to. */
+ /* Now generate the states for the entry being branched to. */
if (i != NULL)
- {
- gen_dis_table (i);
- }
-
+ gen_dis_table (i);
}
}
+
if (debug)
{
if (ent->skip_flag)
- {
- printf ("%d: skipping %d\n", our_offset, ent->bits_to_skip);
- }
+ printf ("%d: skipping %d\n", our_offset, ent->bits_to_skip);
if (ent->bits[0] != NULL)
- {
- printf ("%d: if (0:%d) goto %d\n", our_offset, zero_count + 1,
- zero_dest);
- }
+ printf ("%d: if (0:%d) goto %d\n", our_offset, zero_count + 1,
+ zero_dest);
}
+
if (bitsused != totbits)
- {
- abort ();
- }
+ abort ();
}
-void
-print_dis_table ()
+static void
+print_dis_table (void)
{
int x;
struct disent *cent = disinsntable;
@@ -2072,9 +2096,8 @@ print_dis_table ()
for (x = 0; x < insn_list_len; x++)
{
if ((x > 0) && ((x % 12) == 0))
- {
- printf ("\n");
- }
+ printf ("\n");
+
printf ("0x%02x, ", insn_list[x]);
}
printf ("\n};\n\n");
@@ -2096,24 +2119,22 @@ print_dis_table ()
printf ("};\n\n");
}
-void
-generate_disassembler ()
+static void
+generate_disassembler (void)
{
int i;
bittree = make_bittree_entry ();
- for (i=0; i < otlen;i++)
+ for (i = 0; i < otlen; i++)
{
struct main_entry *ptr = ordered_table[i];
if (ptr->opcode->type != IA64_TYPE_DYN)
- {
- add_dis_entry (bittree,
- ptr->opcode->opcode, ptr->opcode->mask,
- ptr->main_index,
- ptr->completers, 1);
- }
+ add_dis_entry (bittree,
+ ptr->opcode->opcode, ptr->opcode->mask,
+ ptr->main_index,
+ ptr->completers, 1);
}
compact_distree (bittree);
@@ -2123,25 +2144,26 @@ generate_disassembler ()
print_dis_table ();
}
-void
-print_string_table ()
+static void
+print_string_table (void)
{
int x;
char lbuf[80], buf[80];
int blen = 0;
- printf ("static const char *ia64_strings[] = {\n");
+ printf ("static const char * const ia64_strings[] = {\n");
lbuf[0] = '\0';
+
for (x = 0; x < strtablen; x++)
{
int len;
if (strlen (string_table[x]->s) > 75)
- {
- abort ();
- }
+ abort ();
+
sprintf (buf, " \"%s\",", string_table[x]->s);
len = strlen (buf);
+
if ((blen + len) > 75)
{
printf (" %s\n", lbuf);
@@ -2151,10 +2173,10 @@ print_string_table ()
strcat (lbuf, buf);
blen += len;
}
+
if (blen > 0)
- {
- printf (" %s\n", lbuf);
- }
+ printf (" %s\n", lbuf);
+
printf ("};\n\n");
}
@@ -2162,9 +2184,9 @@ static struct completer_entry **glist;
static int glistlen = 0;
static int glisttotlen = 0;
-/* If the completer trees ENT1 and ENT2 are equal, return 1. */
+/* If the completer trees ENT1 and ENT2 are equal, return 1. */
-int
+static int
completer_entries_eq (ent1, ent2)
struct completer_entry *ent1, *ent2;
{
@@ -2176,25 +2198,23 @@ completer_entries_eq (ent1, ent2)
|| ent1->is_terminal != ent2->is_terminal
|| ent1->dependencies != ent2->dependencies
|| ent1->order != ent2->order)
- {
- return 0;
- }
+ return 0;
+
if (! completer_entries_eq (ent1->addl_entries, ent2->addl_entries))
- {
- return 0;
- }
+ return 0;
+
ent1 = ent1->alternative;
ent2 = ent2->alternative;
}
+
return ent1 == ent2;
}
/* Insert ENT into the global list of completers and return it. If an
equivalent entry (according to completer_entries_eq) already exists,
- it is returned instead. */
-struct completer_entry *
-insert_gclist (ent)
- struct completer_entry *ent;
+ it is returned instead. */
+static struct completer_entry *
+insert_gclist (struct completer_entry *ent)
{
if (ent != NULL)
{
@@ -2223,13 +2243,9 @@ insert_gclist (ent)
}
if (ent->name->num < glist[0]->name->num)
- {
- i = 0;
- }
+ i = 0;
else if (ent->name->num > glist[end - 1]->name->num)
- {
- i = end;
- }
+ i = end;
else
{
int c;
@@ -2238,62 +2254,50 @@ insert_gclist (ent)
{
i = (start + end) / 2;
c = ent->name->num - glist[i]->name->num;
+
if (c < 0)
- {
- end = i - 1;
- }
+ end = i - 1;
else if (c == 0)
{
while (i > 0
&& ent->name->num == glist[i - 1]->name->num)
- {
- i--;
- }
+ i--;
+
break;
}
else
- {
- start = i + 1;
- }
+ start = i + 1;
+
if (start > end)
- {
- break;
- }
+ break;
}
+
if (c == 0)
{
while (i < glistlen)
{
if (ent->name->num != glist[i]->name->num)
- {
- break;
- }
+ break;
+
if (completer_entries_eq (ent, glist[i]))
- {
- return glist[i];
- }
+ return glist[i];
+
i++;
}
}
}
+
for (; i > 0 && i < glistlen; i--)
- {
- if (ent->name->num >= glist[i - 1]->name->num)
- {
- break;
- }
- }
+ if (ent->name->num >= glist[i - 1]->name->num)
+ break;
+
for (; i < glistlen; i++)
- {
- if (ent->name->num < glist[i]->name->num)
- {
- break;
- }
- }
+ if (ent->name->num < glist[i]->name->num)
+ break;
+
for (x = glistlen - 1; x >= i; x--)
- {
- glist[x + 1] = glist[x];
- }
+ glist[x + 1] = glist[x];
+
glist[i] = ent;
glistlen++;
}
@@ -2307,19 +2311,13 @@ get_prefix_len (name)
char *c;
if (name[0] == '\0')
- {
- return 0;
- }
+ return 0;
c = strchr (name, '.');
if (c != NULL)
- {
- return c - name;
- }
+ return c - name;
else
- {
- return strlen (name);
- }
+ return strlen (name);
}
static void
@@ -2340,30 +2338,21 @@ compute_completer_bits (ment, ent)
int x;
while (p != NULL && ! p->is_terminal)
- {
- p = p->parent;
- }
+ p = p->parent;
if (p != NULL)
- {
- p_bits = p->bits;
- }
+ p_bits = p->bits;
else
- {
- p_bits = ment->opcode->opcode;
- }
+ p_bits = ment->opcode->opcode;
for (x = 0; x < 64; x++)
{
ia64_insn m = ((ia64_insn) 1) << x;
+
if ((p_bits & m) != (our_bits & m))
- {
- mask |= m;
- }
+ mask |= m;
else
- {
- our_bits &= ~m;
- }
+ our_bits &= ~m;
}
ent->bits = our_bits;
ent->mask = mask;
@@ -2379,9 +2368,9 @@ compute_completer_bits (ment, ent)
}
/* Find identical completer trees that are used in different
- instructions and collapse their entries. */
-void
-collapse_redundant_completers ()
+ instructions and collapse their entries. */
+static void
+collapse_redundant_completers (void)
{
struct main_entry *ptr;
int x;
@@ -2389,43 +2378,39 @@ collapse_redundant_completers ()
for (ptr = maintable; ptr != NULL; ptr = ptr->next)
{
if (ptr->completers == NULL)
- {
- abort ();
- }
+ abort ();
+
compute_completer_bits (ptr, ptr->completers);
ptr->completers = insert_gclist (ptr->completers);
}
/* The table has been finalized, now number the indexes. */
for (x = 0; x < glistlen; x++)
- {
- glist[x]->num = x;
- }
+ glist[x]->num = x;
}
-/* attach two lists of dependencies to each opcode.
+/* Attach two lists of dependencies to each opcode.
1) all resources which, when already marked in use, conflict with this
opcode (chks)
2) all resources which must be marked in use when this opcode is used
- (regs)
-*/
-int
+ (regs). */
+static int
insert_opcode_dependencies (opc, cmp)
struct ia64_opcode *opc;
struct completer_entry *cmp ATTRIBUTE_UNUSED;
{
- /* note all resources which point to this opcode. rfi has the most chks
- (79) and cmpxchng has the most regs (54) so 100 here should be enough */
+ /* Note all resources which point to this opcode. rfi has the most chks
+ (79) and cmpxchng has the most regs (54) so 100 here should be enough. */
int i;
int nregs = 0;
unsigned short regs[256];
int nchks = 0;
unsigned short chks[256];
- /* flag insns for which no class matched; there should be none */
+ /* Flag insns for which no class matched; there should be none. */
int no_class_found = 1;
- for (i=0;i < rdepslen;i++)
+ for (i = 0; i < rdepslen; i++)
{
struct rdep *rs = rdeps[i];
int j;
@@ -2441,21 +2426,19 @@ insert_opcode_dependencies (opc, cmp)
if (in_iclass (opc, ics[rs->regs[j]], NULL, NULL, &ic_note))
{
- /* We can ignore ic_note 11 for non PR resources */
+ /* We can ignore ic_note 11 for non PR resources. */
if (ic_note == 11 && strncmp (rs->name, "PR", 2) != 0)
ic_note = 0;
if (ic_note != 0 && rs->regnotes[j] != 0
&& ic_note != rs->regnotes[j]
&& !(ic_note == 11 && rs->regnotes[j] == 1))
- fprintf (stderr, "Warning: IC note %d in opcode %s (IC:%s)"
- " conflicts with resource %s note %d\n",
- ic_note, opc->name, ics[rs->regs[j]]->name,
- rs->name, rs->regnotes[j]);
+ warn (_("IC note %d in opcode %s (IC:%s) conflicts with resource %s note %d\n"),
+ ic_note, opc->name, ics[rs->regs[j]]->name,
+ rs->name, rs->regnotes[j]);
/* Instruction class notes override resource notes.
So far, only note 11 applies to an IC instead of a resource,
- and note 11 implies note 1.
- */
+ and note 11 implies note 1. */
if (ic_note)
regs[nregs++] = RDEP(ic_note, i);
else
@@ -2464,23 +2447,23 @@ insert_opcode_dependencies (opc, cmp)
++rs->total_regs;
}
}
- for (j=0;j < rs->nchks;j++)
+
+ for (j = 0; j < rs->nchks; j++)
{
int ic_note = 0;
if (in_iclass (opc, ics[rs->chks[j]], NULL, NULL, &ic_note))
{
- /* We can ignore ic_note 11 for non PR resources */
+ /* We can ignore ic_note 11 for non PR resources. */
if (ic_note == 11 && strncmp (rs->name, "PR", 2) != 0)
ic_note = 0;
if (ic_note != 0 && rs->chknotes[j] != 0
&& ic_note != rs->chknotes[j]
&& !(ic_note == 11 && rs->chknotes[j] == 1))
- fprintf (stderr, "Warning: IC note %d for opcode %s (IC:%s)"
- " conflicts with resource %s note %d\n",
- ic_note, opc->name, ics[rs->chks[j]]->name,
- rs->name, rs->chknotes[j]);
+ warn (_("IC note %d for opcode %s (IC:%s) conflicts with resource %s note %d\n"),
+ ic_note, opc->name, ics[rs->chks[j]]->name,
+ rs->name, rs->chknotes[j]);
if (ic_note)
chks[nchks++] = RDEP(ic_note, i);
else
@@ -2492,14 +2475,14 @@ insert_opcode_dependencies (opc, cmp)
}
if (no_class_found)
- fprintf (stderr, "Warning: opcode %s has no class (ops %d %d %d)\n",
- opc->name,
- opc->operands[0], opc->operands[1], opc->operands[2]);
+ warn (_("opcode %s has no class (ops %d %d %d)\n"),
+ opc->name,
+ opc->operands[0], opc->operands[1], opc->operands[2]);
return insert_dependencies (nchks, chks, nregs, regs);
}
-void
+static void
insert_completer_entry (opc, tabent, order)
struct ia64_opcode *opc;
struct main_entry *tabent;
@@ -2511,15 +2494,13 @@ insert_completer_entry (opc, tabent, order)
int at_end = 0;
if (strlen (opc->name) > 128)
- {
- abort ();
- }
+ abort ();
+
strcpy (pcopy, opc->name);
prefix = pcopy + get_prefix_len (pcopy);
+
if (prefix[0] != '\0')
- {
- prefix++;
- }
+ prefix++;
while (! at_end)
{
@@ -2541,13 +2522,13 @@ insert_completer_entry (opc, tabent, order)
break;
}
else
- {
- ptr = &((*ptr)->alternative);
- }
+ ptr = &((*ptr)->alternative);
}
+
if (need_new_ent)
{
struct completer_entry *nent = tmalloc (struct completer_entry);
+
nent->name = sent;
nent->parent = parent;
nent->addl_entries = NULL;
@@ -2566,9 +2547,7 @@ insert_completer_entry (opc, tabent, order)
}
if ((*ptr)->is_terminal)
- {
- abort ();
- }
+ abort ();
(*ptr)->is_terminal = 1;
(*ptr)->mask = (ia64_insn)-1;
@@ -2577,7 +2556,7 @@ insert_completer_entry (opc, tabent, order)
(*ptr)->order = order;
}
-void
+static void
print_completer_entry (ent)
struct completer_entry *ent;
{
@@ -2592,10 +2571,9 @@ print_completer_entry (ent)
mask = mask >> 1;
bits = bits >> 1;
}
+
if (bits & 0xffffffff00000000LL)
- {
- abort ();
- }
+ abort ();
}
printf (" { 0x%x, 0x%x, %d, %d, %d, %d, %d, %d },\n",
@@ -2609,20 +2587,18 @@ print_completer_entry (ent)
ent->dependencies);
}
-void
+static void
print_completer_table ()
{
int x;
printf ("static const struct ia64_completer_table\ncompleter_table[] = {\n");
for (x = 0; x < glistlen; x++)
- {
- print_completer_entry (glist[x]);
- }
+ print_completer_entry (glist[x]);
printf ("};\n\n");
}
-int
+static int
opcodes_eq (opc1, opc2)
struct ia64_opcode *opc1;
struct ia64_opcode *opc2;
@@ -2633,26 +2609,22 @@ opcodes_eq (opc1, opc2)
if ((opc1->mask != opc2->mask) || (opc1->type != opc2->type)
|| (opc1->num_outputs != opc2->num_outputs)
|| (opc1->flags != opc2->flags))
- {
- return 0;
- }
+ return 0;
+
for (x = 0; x < 5; x++)
- {
- if (opc1->operands[x] != opc2->operands[x])
- {
- return 0;
- }
- }
+ if (opc1->operands[x] != opc2->operands[x])
+ return 0;
+
plen1 = get_prefix_len (opc1->name);
plen2 = get_prefix_len (opc2->name);
+
if (plen1 == plen2 && (memcmp (opc1->name, opc2->name, plen1) == 0))
- {
- return 1;
- }
+ return 1;
+
return 0;
}
-void
+static void
add_opcode_entry (opc)
struct ia64_opcode *opc;
{
@@ -2662,9 +2634,8 @@ add_opcode_entry (opc)
int found_it = 0;
if (strlen (opc->name) > 128)
- {
- abort ();
- }
+ abort ();
+
place = &maintable;
strcpy (prefix, opc->name);
prefix[get_prefix_len (prefix)] = '\0';
@@ -2672,7 +2643,7 @@ add_opcode_entry (opc)
/* Walk the list of opcode table entries. If it's a new
instruction, allocate and fill in a new entry. Note
- the main table is alphabetical by opcode name. */
+ the main table is alphabetical by opcode name. */
while (*place != NULL)
{
@@ -2683,9 +2654,8 @@ add_opcode_entry (opc)
break;
}
if ((*place)->name->num > name->num)
- {
- break;
- }
+ break;
+
place = &((*place)->next);
}
if (! found_it)
@@ -2710,8 +2680,8 @@ add_opcode_entry (opc)
insert_completer_entry (opc, *place, opcode_count++);
}
-void
-print_main_table ()
+static void
+print_main_table (void)
{
struct main_entry *ptr = maintable;
int index = 0;
@@ -2742,30 +2712,85 @@ print_main_table ()
printf ("};\n\n");
}
-void
+static void
shrink (table)
struct ia64_opcode *table;
{
int curr_opcode;
for (curr_opcode = 0; table[curr_opcode].name != NULL; curr_opcode++)
- {
- add_opcode_entry (table + curr_opcode);
- }
+ add_opcode_entry (table + curr_opcode);
}
+
+/* Program options. */
+#define OPTION_SRCDIR 200
+
+struct option long_options[] =
+{
+ {"srcdir", required_argument, NULL, OPTION_SRCDIR},
+ {"debug", no_argument, NULL, 'd'},
+ {"version", no_argument, NULL, 'V'},
+ {"help", no_argument, NULL, 'h'},
+ {0, no_argument, NULL, 0}
+};
+
+static void
+print_version (void)
+{
+ printf ("%s: version 1.0\n", program_name);
+ xexit (0);
+}
+
+static void
+usage (FILE * stream, int status)
+{
+ fprintf (stream, "Usage: %s [-V | --version] [-d | --debug] [--srcdir=dirname] [--help]\n",
+ program_name);
+ xexit (status);
+}
+
int
-main (argc, argv)
- int argc;
- char **argv ATTRIBUTE_UNUSED;
+main (int argc, char **argv)
{
- if (argc > 1)
- {
- debug = 1;
- }
+ extern int chdir (char *);
+ char *srcdir = NULL;
+ int c;
+
+ program_name = *argv;
+ xmalloc_set_program_name (program_name);
+
+ while ((c = getopt_long (argc, argv, "vVdh", long_options, 0)) != EOF)
+ switch (c)
+ {
+ case OPTION_SRCDIR:
+ srcdir = optarg;
+ break;
+ case 'V':
+ case 'v':
+ print_version ();
+ break;
+ case 'd':
+ debug = 1;
+ break;
+ case 'h':
+ case '?':
+ usage (stderr, 0);
+ default:
+ case 0:
+ break;
+ }
+
+ if (optind != argc)
+ usage (stdout, 1);
+
+ if (srcdir != NULL)
+ if (chdir (srcdir) != 0)
+ fail (_("unable to change directory to \"%s\", errno = %s\n"),
+ srcdir, strerror (errno));
- load_insn_classes();
- load_dependencies();
+ load_insn_classes ();
+ load_dependencies ();
shrink (ia64_opcodes_a);
shrink (ia64_opcodes_b);
@@ -2777,7 +2802,7 @@ main (argc, argv)
collapse_redundant_completers ();
- printf ("/* This file is automatically generated by ia64-gen. Do not edit! */\n");
+ printf ("/* This file is automatically generated by ia64-gen. Do not edit! */\n");
print_string_table ();
print_dependency_table ();
print_completer_table ();
diff --git a/contrib/binutils/opcodes/ia64-ic.tbl b/contrib/binutils/opcodes/ia64-ic.tbl
index 115a276..45e3bd5 100644
--- a/contrib/binutils/opcodes/ia64-ic.tbl
+++ b/contrib/binutils/opcodes/ia64-ic.tbl
@@ -3,7 +3,7 @@ all; IC:predicatable-instructions, IC:unpredicatable-instructions
branches; IC:indirect-brs, IC:ip-rel-brs
cfm-readers; IC:fr-readers, IC:fr-writers, IC:gr-readers, IC:gr-writers, IC:mod-sched-brs, IC:predicatable-instructions, IC:pr-writers, alloc, br.call, brl.call, br.ret, cover, loadrs, rfi, IC:chk-a, invala.e
chk-a; chk.a.clr, chk.a.nc
-cmpxchg; cmpxchg1, cmpxchg2, cmpxchg4, cmpxchg8
+cmpxchg; cmpxchg1, cmpxchg2, cmpxchg4, cmpxchg8, cmp8xchg16
czx; czx1, czx2
fcmp-s0; fcmp[Field(sf)==s0]
fcmp-s1; fcmp[Field(sf)==s1]
@@ -20,7 +20,7 @@ fpcmp-s0; fpcmp[Field(sf)==s0]
fpcmp-s1; fpcmp[Field(sf)==s1]
fpcmp-s2; fpcmp[Field(sf)==s2]
fpcmp-s3; fpcmp[Field(sf)==s3]
-fr-readers; IC:fp-arith, IC:fp-non-arith, IC:pr-writers-fp, chk.s[Format in {M21}], getf
+fr-readers; IC:fp-arith, IC:fp-non-arith, IC:pr-writers-fp, chk.s[Format in {M21}], getf, IC:mem-writers-fp
fr-writers; IC:fp-arith, IC:fp-non-arith\fclass, IC:mem-readers-fp, setf
gr-readers; IC:gr-readers-writers, IC:mem-readers, IC:mem-writers, chk.s, cmp, cmp4, fc, itc.i, itc.d, itr.i, itr.d, IC:mov-to-AR-gr, IC:mov-to-BR, IC:mov-to-CR, IC:mov-to-IND, IC:mov-from-IND, IC:mov-to-PR-allreg, IC:mov-to-PSR-l, IC:mov-to-PSR-um, IC:probe-all, ptc.e, ptc.g, ptc.ga, ptc.l, ptr.i, ptr.d, setf, tbit, tnat
gr-readers-writers; IC:mov-from-IND, add, addl, addp4, adds, and, andcm, IC:czx, dep\dep[Format in {I13}], extr, IC:mem-readers-int, IC:ld-all-postinc, IC:lfetch-postinc, IC:mix, IC:mux, or, IC:pack, IC:padd, IC:pavg, IC:pavgsub, IC:pcmp, IC:pmax, IC:pmin, IC:pmpy, IC:pmpyshr, popcnt, IC:probe-nofault, IC:psad, IC:pshl, IC:pshladd, IC:pshr, IC:pshradd, IC:psub, shl, shladd, shladdp4, shr, shrp, IC:st-postinc, sub, IC:sxt, tak, thash, tpa, ttag, IC:unpack, xor, IC:zxt
@@ -29,7 +29,7 @@ indirect-brp; brp[Format in {B7}]
indirect-brs; br.call[Format in {B5}], br.cond[Format in {B4}], br.ia, br.ret
invala-all; invala[Format in {M24}], invala.e
ip-rel-brs; IC:mod-sched-brs, br.call[Format in {B3}], brl.call, brl.cond, br.cond[Format in {B1}], br.cloop
-ld; ld1, ld2, ld4, ld8, ld8.fill
+ld; ld1, ld2, ld4, ld8, ld8.fill, ld16
ld-a; ld1.a, ld2.a, ld4.a, ld8.a
ld-all-postinc; IC:ld[Format in {M2 M3}], IC:ldfp[Format in {M12}], IC:ldf[Format in {M7 M8}]
ld-c; IC:ld-c-nc, IC:ld-c-clr
@@ -71,8 +71,15 @@ mov-from-AR; IC:mov-from-AR-M, IC:mov-from-AR-I, IC:mov-from-AR-IM
mov-from-AR-BSP; IC:mov-from-AR-M[Field(ar3) == BSP]
mov-from-AR-BSPSTORE; IC:mov-from-AR-M[Field(ar3) == BSPSTORE]
mov-from-AR-CCV; IC:mov-from-AR-M[Field(ar3) == CCV]
+mov-from-AR-CFLG; IC:mov-from-AR-M[Field(ar3) == CFLG]
+mov-from-AR-CSD; IC:mov-from-AR-M[Field(ar3) == CSD]
mov-from-AR-EC; IC:mov-from-AR-I[Field(ar3) == EC]
+mov-from-AR-EFLAG; IC:mov-from-AR-M[Field(ar3) == EFLAG]
+mov-from-AR-FCR; IC:mov-from-AR-M[Field(ar3) == FCR]
+mov-from-AR-FDR; IC:mov-from-AR-M[Field(ar3) == FDR]
+mov-from-AR-FIR; IC:mov-from-AR-M[Field(ar3) == FIR]
mov-from-AR-FPSR; IC:mov-from-AR-M[Field(ar3) == FPSR]
+mov-from-AR-FSR; IC:mov-from-AR-M[Field(ar3) == FSR]
mov-from-AR-I; mov_ar[Format in {I28}]
mov-from-AR-ig; IC:mov-from-AR-IM[Field(ar3) in {48-63 112-127}]
mov-from-AR-IM; mov_ar[Format in {I28 M31}]
@@ -84,6 +91,7 @@ mov-from-AR-PFS; IC:mov-from-AR-I[Field(ar3) == PFS]
mov-from-AR-RNAT; IC:mov-from-AR-M[Field(ar3) == RNAT]
mov-from-AR-RSC; IC:mov-from-AR-M[Field(ar3) == RSC]
mov-from-AR-rv; IC:none
+mov-from-AR-SSD; IC:mov-from-AR-M[Field(ar3) == SSD]
mov-from-AR-UNAT; IC:mov-from-AR-M[Field(ar3) == UNAT]
mov-from-BR; mov_br[Format in {I22}]
mov-from-CR; mov_cr[Format in {M33}]
@@ -129,8 +137,15 @@ mov-to-AR; IC:mov-to-AR-M, IC:mov-to-AR-I
mov-to-AR-BSP; IC:mov-to-AR-M[Field(ar3) == BSP]
mov-to-AR-BSPSTORE; IC:mov-to-AR-M[Field(ar3) == BSPSTORE]
mov-to-AR-CCV; IC:mov-to-AR-M[Field(ar3) == CCV]
+mov-to-AR-CFLG; IC:mov-to-AR-M[Field(ar3) == CFLG]
+mov-to-AR-CSD; IC:mov-to-AR-M[Field(ar3) == CSD]
mov-to-AR-EC; IC:mov-to-AR-I[Field(ar3) == EC]
+mov-to-AR-EFLAG; IC:mov-to-AR-M[Field(ar3) == EFLAG]
+mov-to-AR-FCR; IC:mov-to-AR-M[Field(ar3) == FCR]
+mov-to-AR-FDR; IC:mov-to-AR-M[Field(ar3) == FDR]
+mov-to-AR-FIR; IC:mov-to-AR-M[Field(ar3) == FIR]
mov-to-AR-FPSR; IC:mov-to-AR-M[Field(ar3) == FPSR]
+mov-to-AR-FSR; IC:mov-to-AR-M[Field(ar3) == FSR]
mov-to-AR-gr; IC:mov-to-AR-M[Format in {M29}], IC:mov-to-AR-I[Format in {I26}]
mov-to-AR-I; mov_ar[Format in {I26 I27}]
mov-to-AR-ig; IC:mov-to-AR-IM[Field(ar3) in {48-63 112-127}]
@@ -142,6 +157,7 @@ mov-to-AR-M; mov_ar[Format in {M29 M30}]
mov-to-AR-PFS; IC:mov-to-AR-I[Field(ar3) == PFS]
mov-to-AR-RNAT; IC:mov-to-AR-M[Field(ar3) == RNAT]
mov-to-AR-RSC; IC:mov-to-AR-M[Field(ar3) == RSC]
+mov-to-AR-SSD; IC:mov-to-AR-M[Field(ar3) == SSD]
mov-to-AR-UNAT; IC:mov-to-AR-M[Field(ar3) == UNAT]
mov-to-BR; mov_br[Format in {I21}]
mov-to-CR; mov_cr[Format in {M32}]
@@ -200,8 +216,8 @@ pr-gen-writers-int; cmp, cmp4, tbit, tnat
pr-norm-writers-fp; IC:pr-gen-writers-fp[Field(ctype)==]
pr-norm-writers-int; IC:pr-gen-writers-int[Field(ctype)==]
pr-or-writers; IC:pr-gen-writers-int[Field(ctype) in {or orcm}], IC:pr-gen-writers-int[Field(ctype) in {or.andcm and.orcm}]
-pr-readers-br; br.call, br.cond, brl.call, brl.cond, br.ret, br.wexit, br.wtop, break.b, nop.b, IC:ReservedBQP
-pr-readers-nobr-nomovpr; add, addl, addp4, adds, and, andcm, break.f, break.i, break.m, break.x, chk.s, IC:chk-a, cmp, cmp4, IC:cmpxchg, IC:czx, dep, extr, IC:fp-arith, IC:fp-non-arith, fc, fchkf, fclrf, fcmp, IC:fetchadd, fpcmp, fsetc, fwb, getf, IC:invala-all, itc.i, itc.d, itr.i, itr.d, IC:ld, IC:ldf, IC:ldfp, IC:lfetch-all, mf, IC:mix, IC:mov-from-AR-M, IC:mov-from-AR-IM, IC:mov-from-AR-I, IC:mov-to-AR-M, IC:mov-to-AR-I, IC:mov-to-AR-IM, IC:mov-to-BR, IC:mov-from-BR, IC:mov-to-CR, IC:mov-from-CR, IC:mov-to-IND, IC:mov-from-IND, IC:mov-ip, IC:mov-to-PSR-l, IC:mov-to-PSR-um, IC:mov-from-PSR, IC:mov-from-PSR-um, movl, IC:mux, nop.f, nop.i, nop.m, nop.x, or, IC:pack, IC:padd, IC:pavg, IC:pavgsub, IC:pcmp, IC:pmax, IC:pmin, IC:pmpy, IC:pmpyshr, popcnt, IC:probe-all, IC:psad, IC:pshl, IC:pshladd, IC:pshr, IC:pshradd, IC:psub, ptc.e, ptc.g, ptc.ga, ptc.l, ptr.d, ptr.i, IC:ReservedQP, rsm, setf, shl, shladd, shladdp4, shr, shrp, srlz.i, srlz.d, ssm, IC:st, IC:stf, sub, sum, IC:sxt, sync, tak, tbit, thash, tnat, tpa, ttag, IC:unpack, IC:xchg, xma, xmpy, xor, IC:zxt
+pr-readers-br; br.call, br.cond, brl.call, brl.cond, br.ret, br.wexit, br.wtop, break.b, hint.b, nop.b, IC:ReservedBQP
+pr-readers-nobr-nomovpr; add, addl, addp4, adds, and, andcm, break.f, break.i, break.m, break.x, chk.s, IC:chk-a, cmp, cmp4, IC:cmpxchg, IC:czx, dep, extr, IC:fp-arith, IC:fp-non-arith, fc, fchkf, fclrf, fcmp, IC:fetchadd, fpcmp, fsetc, fwb, getf, hint.f, hint.i, hint.m, hint.x, IC:invala-all, itc.i, itc.d, itr.i, itr.d, IC:ld, IC:ldf, IC:ldfp, IC:lfetch-all, mf, IC:mix, IC:mov-from-AR-M, IC:mov-from-AR-IM, IC:mov-from-AR-I, IC:mov-to-AR-M, IC:mov-to-AR-I, IC:mov-to-AR-IM, IC:mov-to-BR, IC:mov-from-BR, IC:mov-to-CR, IC:mov-from-CR, IC:mov-to-IND, IC:mov-from-IND, IC:mov-ip, IC:mov-to-PSR-l, IC:mov-to-PSR-um, IC:mov-from-PSR, IC:mov-from-PSR-um, movl, IC:mux, nop.f, nop.i, nop.m, nop.x, or, IC:pack, IC:padd, IC:pavg, IC:pavgsub, IC:pcmp, IC:pmax, IC:pmin, IC:pmpy, IC:pmpyshr, popcnt, IC:probe-all, IC:psad, IC:pshl, IC:pshladd, IC:pshr, IC:pshradd, IC:psub, ptc.e, ptc.g, ptc.ga, ptc.l, ptr.d, ptr.i, IC:ReservedQP, rsm, setf, shl, shladd, shladdp4, shr, shrp, srlz.i, srlz.d, ssm, IC:st, IC:stf, sub, sum, IC:sxt, sync, tak, tbit, thash, tnat, tpa, ttag, IC:unpack, IC:xchg, xma, xmpy, xor, IC:zxt
pr-unc-writers-fp; IC:pr-gen-writers-fp[Field(ctype)==unc]+11, fprcpa+11, fprsqrta+11, frcpa+11, frsqrta+11
pr-unc-writers-int; IC:pr-gen-writers-int[Field(ctype)==unc]+11
pr-writers; IC:pr-writers-int, IC:pr-writers-fp
@@ -222,7 +238,7 @@ ReservedBQP; -+15
ReservedQP; -+16
rse-readers; alloc, br.call, br.ia, br.ret, brl.call, cover, flushrs, loadrs, IC:mov-from-AR-BSP, IC:mov-from-AR-BSPSTORE, IC:mov-to-AR-BSPSTORE, IC:mov-from-AR-RNAT, IC:mov-to-AR-RNAT, rfi
rse-writers; alloc, br.call, br.ia, br.ret, brl.call, cover, flushrs, loadrs, IC:mov-to-AR-BSPSTORE, rfi
-st; st1, st2, st4, st8, st8.spill
+st; st1, st2, st4, st8, st8.spill, st16
st-postinc; IC:stf[Format in {M10}], IC:st[Format in {M5}]
stf; stfs, stfd, stfe, stf8, stf.spill
sxt; sxt1, sxt2, sxt4
diff --git a/contrib/binutils/opcodes/ia64-opc-a.c b/contrib/binutils/opcodes/ia64-opc-a.c
index 27d7637..c9e3162 100644
--- a/contrib/binutils/opcodes/ia64-opc-a.c
+++ b/contrib/binutils/opcodes/ia64-opc-a.c
@@ -1,5 +1,5 @@
/* ia64-opc-a.c -- IA-64 `A' opcode table.
- Copyright 1998, 1999, 2000, 2001 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc.
Contributed by David Mosberger-Tang <davidm@hpl.hp.com>
This file is part of GDB, GAS, and the GNU binutils.
@@ -82,292 +82,296 @@
(bOp (a) | bX2a (b) | bZa (c) | bZb (d) | bX4 (e) | bX2b (f)), \
(mOp | mX2a | mZa | mZb | mX4 | mX2b)
+/* Used to initialise unused fields in ia64_opcode struct,
+ in order to stop gcc from complaining. */
+#define EMPTY 0,0,NULL
+
struct ia64_opcode ia64_opcodes_a[] =
{
- /* A-type instruction encodings (sorted according to major opcode) */
+ /* A-type instruction encodings (sorted according to major opcode). */
- {"add", A, OpX2aVeX4X2b (8, 0, 0, 0, 0), {R1, R2, R3}},
- {"add", A, OpX2aVeX4X2b (8, 0, 0, 0, 1), {R1, R2, R3, C1}},
- {"sub", A, OpX2aVeX4X2b (8, 0, 0, 1, 1), {R1, R2, R3}},
- {"sub", A, OpX2aVeX4X2b (8, 0, 0, 1, 0), {R1, R2, R3, C1}},
- {"addp4", A, OpX2aVeX4X2b (8, 0, 0, 2, 0), {R1, R2, R3}},
- {"and", A, OpX2aVeX4X2b (8, 0, 0, 3, 0), {R1, R2, R3}},
- {"andcm", A, OpX2aVeX4X2b (8, 0, 0, 3, 1), {R1, R2, R3}},
- {"or", A, OpX2aVeX4X2b (8, 0, 0, 3, 2), {R1, R2, R3}},
- {"xor", A, OpX2aVeX4X2b (8, 0, 0, 3, 3), {R1, R2, R3}},
- {"shladd", A, OpX2aVeX4 (8, 0, 0, 4), {R1, R2, CNT2a, R3}},
- {"shladdp4", A, OpX2aVeX4 (8, 0, 0, 6), {R1, R2, CNT2a, R3}},
- {"sub", A, OpX2aVeX4X2b (8, 0, 0, 9, 1), {R1, IMM8, R3}},
- {"and", A, OpX2aVeX4X2b (8, 0, 0, 0xb, 0), {R1, IMM8, R3}},
- {"andcm", A, OpX2aVeX4X2b (8, 0, 0, 0xb, 1), {R1, IMM8, R3}},
- {"or", A, OpX2aVeX4X2b (8, 0, 0, 0xb, 2), {R1, IMM8, R3}},
- {"xor", A, OpX2aVeX4X2b (8, 0, 0, 0xb, 3), {R1, IMM8, R3}},
- {"mov", A, OpX2aVeImm14 (8, 2, 0, 0), {R1, R3}},
- {"mov", A, OpX2aVeR3a (8, 2, 0, 0), {R1, IMM14}, PSEUDO},
- {"adds", A, OpX2aVe (8, 2, 0), {R1, IMM14, R3}},
- {"addp4", A, OpX2aVe (8, 3, 0), {R1, IMM14, R3}},
- {"padd1", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 0, 0), {R1, R2, R3}},
- {"padd2", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 0, 0), {R1, R2, R3}},
- {"padd4", A, OpX2aZaZbX4X2b (8, 1, 1, 0, 0, 0), {R1, R2, R3}},
- {"padd1.sss", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 0, 1), {R1, R2, R3}},
- {"padd2.sss", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 0, 1), {R1, R2, R3}},
- {"padd1.uuu", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 0, 2), {R1, R2, R3}},
- {"padd2.uuu", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 0, 2), {R1, R2, R3}},
- {"padd1.uus", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 0, 3), {R1, R2, R3}},
- {"padd2.uus", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 0, 3), {R1, R2, R3}},
- {"psub1", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 1, 0), {R1, R2, R3}},
- {"psub2", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 1, 0), {R1, R2, R3}},
- {"psub4", A, OpX2aZaZbX4X2b (8, 1, 1, 0, 1, 0), {R1, R2, R3}},
- {"psub1.sss", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 1, 1), {R1, R2, R3}},
- {"psub2.sss", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 1, 1), {R1, R2, R3}},
- {"psub1.uuu", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 1, 2), {R1, R2, R3}},
- {"psub2.uuu", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 1, 2), {R1, R2, R3}},
- {"psub1.uus", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 1, 3), {R1, R2, R3}},
- {"psub2.uus", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 1, 3), {R1, R2, R3}},
- {"pavg1", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 2, 2), {R1, R2, R3}},
- {"pavg2", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 2, 2), {R1, R2, R3}},
- {"pavg1.raz", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 2, 3), {R1, R2, R3}},
- {"pavg2.raz", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 2, 3), {R1, R2, R3}},
- {"pavgsub1", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 3, 2), {R1, R2, R3}},
- {"pavgsub2", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 3, 2), {R1, R2, R3}},
- {"pcmp1.eq", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 9, 0), {R1, R2, R3}},
- {"pcmp2.eq", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 9, 0), {R1, R2, R3}},
- {"pcmp4.eq", A, OpX2aZaZbX4X2b (8, 1, 1, 0, 9, 0), {R1, R2, R3}},
- {"pcmp1.gt", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 9, 1), {R1, R2, R3}},
- {"pcmp2.gt", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 9, 1), {R1, R2, R3}},
- {"pcmp4.gt", A, OpX2aZaZbX4X2b (8, 1, 1, 0, 9, 1), {R1, R2, R3}},
- {"pshladd2", A, OpX2aZaZbX4 (8, 1, 0, 1, 4), {R1, R2, CNT2b, R3}},
- {"pshradd2", A, OpX2aZaZbX4 (8, 1, 0, 1, 6), {R1, R2, CNT2b, R3}},
+ {"add", A, OpX2aVeX4X2b (8, 0, 0, 0, 0), {R1, R2, R3}, EMPTY},
+ {"add", A, OpX2aVeX4X2b (8, 0, 0, 0, 1), {R1, R2, R3, C1}, EMPTY},
+ {"sub", A, OpX2aVeX4X2b (8, 0, 0, 1, 1), {R1, R2, R3}, EMPTY},
+ {"sub", A, OpX2aVeX4X2b (8, 0, 0, 1, 0), {R1, R2, R3, C1}, EMPTY},
+ {"addp4", A, OpX2aVeX4X2b (8, 0, 0, 2, 0), {R1, R2, R3}, EMPTY},
+ {"and", A, OpX2aVeX4X2b (8, 0, 0, 3, 0), {R1, R2, R3}, EMPTY},
+ {"andcm", A, OpX2aVeX4X2b (8, 0, 0, 3, 1), {R1, R2, R3}, EMPTY},
+ {"or", A, OpX2aVeX4X2b (8, 0, 0, 3, 2), {R1, R2, R3}, EMPTY},
+ {"xor", A, OpX2aVeX4X2b (8, 0, 0, 3, 3), {R1, R2, R3}, EMPTY},
+ {"shladd", A, OpX2aVeX4 (8, 0, 0, 4), {R1, R2, CNT2a, R3}, EMPTY},
+ {"shladdp4", A, OpX2aVeX4 (8, 0, 0, 6), {R1, R2, CNT2a, R3}, EMPTY},
+ {"sub", A, OpX2aVeX4X2b (8, 0, 0, 9, 1), {R1, IMM8, R3}, EMPTY},
+ {"and", A, OpX2aVeX4X2b (8, 0, 0, 0xb, 0), {R1, IMM8, R3}, EMPTY},
+ {"andcm", A, OpX2aVeX4X2b (8, 0, 0, 0xb, 1), {R1, IMM8, R3}, EMPTY},
+ {"or", A, OpX2aVeX4X2b (8, 0, 0, 0xb, 2), {R1, IMM8, R3}, EMPTY},
+ {"xor", A, OpX2aVeX4X2b (8, 0, 0, 0xb, 3), {R1, IMM8, R3}, EMPTY},
+ {"mov", A, OpX2aVeImm14 (8, 2, 0, 0), {R1, R3}, EMPTY},
+ {"mov", A, OpX2aVeR3a (8, 2, 0, 0), {R1, IMM14}, PSEUDO, 0, NULL},
+ {"adds", A, OpX2aVe (8, 2, 0), {R1, IMM14, R3}, EMPTY},
+ {"addp4", A, OpX2aVe (8, 3, 0), {R1, IMM14, R3}, EMPTY},
+ {"padd1", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 0, 0), {R1, R2, R3}, EMPTY},
+ {"padd2", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 0, 0), {R1, R2, R3}, EMPTY},
+ {"padd4", A, OpX2aZaZbX4X2b (8, 1, 1, 0, 0, 0), {R1, R2, R3}, EMPTY},
+ {"padd1.sss", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 0, 1), {R1, R2, R3}, EMPTY},
+ {"padd2.sss", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 0, 1), {R1, R2, R3}, EMPTY},
+ {"padd1.uuu", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 0, 2), {R1, R2, R3}, EMPTY},
+ {"padd2.uuu", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 0, 2), {R1, R2, R3}, EMPTY},
+ {"padd1.uus", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 0, 3), {R1, R2, R3}, EMPTY},
+ {"padd2.uus", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 0, 3), {R1, R2, R3}, EMPTY},
+ {"psub1", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 1, 0), {R1, R2, R3}, EMPTY},
+ {"psub2", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 1, 0), {R1, R2, R3}, EMPTY},
+ {"psub4", A, OpX2aZaZbX4X2b (8, 1, 1, 0, 1, 0), {R1, R2, R3}, EMPTY},
+ {"psub1.sss", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 1, 1), {R1, R2, R3}, EMPTY},
+ {"psub2.sss", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 1, 1), {R1, R2, R3}, EMPTY},
+ {"psub1.uuu", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 1, 2), {R1, R2, R3}, EMPTY},
+ {"psub2.uuu", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 1, 2), {R1, R2, R3}, EMPTY},
+ {"psub1.uus", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 1, 3), {R1, R2, R3}, EMPTY},
+ {"psub2.uus", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 1, 3), {R1, R2, R3}, EMPTY},
+ {"pavg1", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 2, 2), {R1, R2, R3}, EMPTY},
+ {"pavg2", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 2, 2), {R1, R2, R3}, EMPTY},
+ {"pavg1.raz", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 2, 3), {R1, R2, R3}, EMPTY},
+ {"pavg2.raz", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 2, 3), {R1, R2, R3}, EMPTY},
+ {"pavgsub1", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 3, 2), {R1, R2, R3}, EMPTY},
+ {"pavgsub2", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 3, 2), {R1, R2, R3}, EMPTY},
+ {"pcmp1.eq", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 9, 0), {R1, R2, R3}, EMPTY},
+ {"pcmp2.eq", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 9, 0), {R1, R2, R3}, EMPTY},
+ {"pcmp4.eq", A, OpX2aZaZbX4X2b (8, 1, 1, 0, 9, 0), {R1, R2, R3}, EMPTY},
+ {"pcmp1.gt", A, OpX2aZaZbX4X2b (8, 1, 0, 0, 9, 1), {R1, R2, R3}, EMPTY},
+ {"pcmp2.gt", A, OpX2aZaZbX4X2b (8, 1, 0, 1, 9, 1), {R1, R2, R3}, EMPTY},
+ {"pcmp4.gt", A, OpX2aZaZbX4X2b (8, 1, 1, 0, 9, 1), {R1, R2, R3}, EMPTY},
+ {"pshladd2", A, OpX2aZaZbX4 (8, 1, 0, 1, 4), {R1, R2, CNT2b, R3}, EMPTY},
+ {"pshradd2", A, OpX2aZaZbX4 (8, 1, 0, 1, 6), {R1, R2, CNT2b, R3}, EMPTY},
- {"mov", A, OpR3b (9, 0), {R1, IMM22}, PSEUDO},
- {"addl", A, Op (9), {R1, IMM22, R3_2}},
+ {"mov", A, OpR3b (9, 0), {R1, IMM22}, PSEUDO, 0, NULL},
+ {"addl", A, Op (9), {R1, IMM22, R3_2}, EMPTY},
- {"cmp.lt", A2, OpX2TbTaC (0xc, 0, 0, 0, 0), {P1, P2, R2, R3}},
- {"cmp.le", A2, OpX2TbTaC (0xc, 0, 0, 0, 0), {P2, P1, R3, R2}},
- {"cmp.gt", A2, OpX2TbTaC (0xc, 0, 0, 0, 0), {P1, P2, R3, R2}},
- {"cmp.ge", A2, OpX2TbTaC (0xc, 0, 0, 0, 0), {P2, P1, R2, R3}},
- {"cmp.lt.unc", A2, OpX2TbTaC (0xc, 0, 0, 0, 1), {P1, P2, R2, R3}},
- {"cmp.le.unc", A2, OpX2TbTaC (0xc, 0, 0, 0, 1), {P2, P1, R3, R2}},
- {"cmp.gt.unc", A2, OpX2TbTaC (0xc, 0, 0, 0, 1), {P1, P2, R3, R2}},
- {"cmp.ge.unc", A2, OpX2TbTaC (0xc, 0, 0, 0, 1), {P2, P1, R2, R3}},
- {"cmp.eq.and", A2, OpX2TbTaC (0xc, 0, 0, 1, 0), {P1, P2, R2, R3}},
- {"cmp.ne.andcm", A2, OpX2TbTaC (0xc, 0, 0, 1, 0), {P1, P2, R2, R3}, PSEUDO},
- {"cmp.ne.and", A2, OpX2TbTaC (0xc, 0, 0, 1, 1), {P1, P2, R2, R3}},
- {"cmp.eq.andcm", A2, OpX2TbTaC (0xc, 0, 0, 1, 1), {P1, P2, R2, R3}, PSEUDO},
- {"cmp4.lt", A2, OpX2TbTaC (0xc, 1, 0, 0, 0), {P1, P2, R2, R3}},
- {"cmp4.le", A2, OpX2TbTaC (0xc, 1, 0, 0, 0), {P2, P1, R3, R2}},
- {"cmp4.gt", A2, OpX2TbTaC (0xc, 1, 0, 0, 0), {P1, P2, R3, R2}},
- {"cmp4.ge", A2, OpX2TbTaC (0xc, 1, 0, 0, 0), {P2, P1, R2, R3}},
- {"cmp4.lt.unc", A2, OpX2TbTaC (0xc, 1, 0, 0, 1), {P1, P2, R2, R3}},
- {"cmp4.le.unc", A2, OpX2TbTaC (0xc, 1, 0, 0, 1), {P2, P1, R3, R2}},
- {"cmp4.gt.unc", A2, OpX2TbTaC (0xc, 1, 0, 0, 1), {P1, P2, R3, R2}},
- {"cmp4.ge.unc", A2, OpX2TbTaC (0xc, 1, 0, 0, 1), {P2, P1, R2, R3}},
- {"cmp4.eq.and", A2, OpX2TbTaC (0xc, 1, 0, 1, 0), {P1, P2, R2, R3}},
- {"cmp4.ne.andcm", A2, OpX2TbTaC (0xc, 1, 0, 1, 0), {P1, P2, R2, R3}, PSEUDO},
- {"cmp4.ne.and", A2, OpX2TbTaC (0xc, 1, 0, 1, 1), {P1, P2, R2, R3}},
- {"cmp4.eq.andcm", A2, OpX2TbTaC (0xc, 1, 0, 1, 1), {P1, P2, R2, R3}, PSEUDO},
- {"cmp.gt.and", A2, OpX2TbTaC (0xc, 0, 1, 0, 0), {P1, P2, GR0, R3}},
- {"cmp.lt.and", A2, OpX2TbTaC (0xc, 0, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.le.andcm", A2, OpX2TbTaC (0xc, 0, 1, 0, 0), {P1, P2, GR0, R3}, PSEUDO},
- {"cmp.ge.andcm", A2, OpX2TbTaC (0xc, 0, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.le.and", A2, OpX2TbTaC (0xc, 0, 1, 0, 1), {P1, P2, GR0, R3}},
- {"cmp.ge.and", A2, OpX2TbTaC (0xc, 0, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.gt.andcm", A2, OpX2TbTaC (0xc, 0, 1, 0, 1), {P1, P2, GR0, R3}, PSEUDO},
- {"cmp.lt.andcm", A2, OpX2TbTaC (0xc, 0, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.ge.and", A2, OpX2TbTaC (0xc, 0, 1, 1, 0), {P1, P2, GR0, R3}},
- {"cmp.le.and", A2, OpX2TbTaC (0xc, 0, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.lt.andcm", A2, OpX2TbTaC (0xc, 0, 1, 1, 0), {P1, P2, GR0, R3}, PSEUDO},
- {"cmp.gt.andcm", A2, OpX2TbTaC (0xc, 0, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.lt.and", A2, OpX2TbTaC (0xc, 0, 1, 1, 1), {P1, P2, GR0, R3}},
- {"cmp.gt.and", A2, OpX2TbTaC (0xc, 0, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.ge.andcm", A2, OpX2TbTaC (0xc, 0, 1, 1, 1), {P1, P2, GR0, R3}, PSEUDO},
- {"cmp.le.andcm", A2, OpX2TbTaC (0xc, 0, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.gt.and", A2, OpX2TbTaC (0xc, 1, 1, 0, 0), {P1, P2, GR0, R3}},
- {"cmp4.lt.and", A2, OpX2TbTaC (0xc, 1, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.le.andcm", A2, OpX2TbTaC (0xc, 1, 1, 0, 0), {P1, P2, GR0, R3}, PSEUDO},
- {"cmp4.ge.andcm", A2, OpX2TbTaC (0xc, 1, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.le.and", A2, OpX2TbTaC (0xc, 1, 1, 0, 1), {P1, P2, GR0, R3}},
- {"cmp4.ge.and", A2, OpX2TbTaC (0xc, 1, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.gt.andcm", A2, OpX2TbTaC (0xc, 1, 1, 0, 1), {P1, P2, GR0, R3}, PSEUDO},
- {"cmp4.lt.andcm", A2, OpX2TbTaC (0xc, 1, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.ge.and", A2, OpX2TbTaC (0xc, 1, 1, 1, 0), {P1, P2, GR0, R3}},
- {"cmp4.le.and", A2, OpX2TbTaC (0xc, 1, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.lt.andcm", A2, OpX2TbTaC (0xc, 1, 1, 1, 0), {P1, P2, GR0, R3}, PSEUDO},
- {"cmp4.gt.andcm", A2, OpX2TbTaC (0xc, 1, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.lt.and", A2, OpX2TbTaC (0xc, 1, 1, 1, 1), {P1, P2, GR0, R3}},
- {"cmp4.gt.and", A2, OpX2TbTaC (0xc, 1, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.ge.andcm", A2, OpX2TbTaC (0xc, 1, 1, 1, 1), {P1, P2, GR0, R3}, PSEUDO},
- {"cmp4.le.andcm", A2, OpX2TbTaC (0xc, 1, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.lt", A2, OpX2TaC (0xc, 2, 0, 0), {P1, P2, IMM8, R3}},
- {"cmp.le", A2, OpX2TaC (0xc, 2, 0, 0), {P1, P2, IMM8M1, R3}},
- {"cmp.gt", A2, OpX2TaC (0xc, 2, 0, 0), {P2, P1, IMM8M1, R3}},
- {"cmp.ge", A2, OpX2TaC (0xc, 2, 0, 0), {P2, P1, IMM8, R3}},
- {"cmp.lt.unc", A2, OpX2TaC (0xc, 2, 0, 1), {P1, P2, IMM8, R3}},
- {"cmp.le.unc", A2, OpX2TaC (0xc, 2, 0, 1), {P1, P2, IMM8M1, R3}},
- {"cmp.gt.unc", A2, OpX2TaC (0xc, 2, 0, 1), {P2, P1, IMM8M1, R3}},
- {"cmp.ge.unc", A2, OpX2TaC (0xc, 2, 0, 1), {P2, P1, IMM8, R3}},
- {"cmp.eq.and", A2, OpX2TaC (0xc, 2, 1, 0), {P1, P2, IMM8, R3}},
- {"cmp.ne.andcm", A2, OpX2TaC (0xc, 2, 1, 0), {P1, P2, IMM8, R3}, PSEUDO},
- {"cmp.ne.and", A2, OpX2TaC (0xc, 2, 1, 1), {P1, P2, IMM8, R3}},
- {"cmp.eq.andcm", A2, OpX2TaC (0xc, 2, 1, 1), {P1, P2, IMM8, R3}, PSEUDO},
- {"cmp4.lt", A2, OpX2TaC (0xc, 3, 0, 0), {P1, P2, IMM8, R3}},
- {"cmp4.le", A2, OpX2TaC (0xc, 3, 0, 0), {P1, P2, IMM8M1, R3}},
- {"cmp4.gt", A2, OpX2TaC (0xc, 3, 0, 0), {P2, P1, IMM8M1, R3}},
- {"cmp4.ge", A2, OpX2TaC (0xc, 3, 0, 0), {P2, P1, IMM8, R3}},
- {"cmp4.lt.unc", A2, OpX2TaC (0xc, 3, 0, 1), {P1, P2, IMM8, R3}},
- {"cmp4.le.unc", A2, OpX2TaC (0xc, 3, 0, 1), {P1, P2, IMM8M1, R3}},
- {"cmp4.gt.unc", A2, OpX2TaC (0xc, 3, 0, 1), {P2, P1, IMM8M1, R3}},
- {"cmp4.ge.unc", A2, OpX2TaC (0xc, 3, 0, 1), {P2, P1, IMM8, R3}},
- {"cmp4.eq.and", A2, OpX2TaC (0xc, 3, 1, 0), {P1, P2, IMM8, R3}},
- {"cmp4.ne.andcm", A2, OpX2TaC (0xc, 3, 1, 0), {P1, P2, IMM8, R3}, PSEUDO},
- {"cmp4.ne.and", A2, OpX2TaC (0xc, 3, 1, 1), {P1, P2, IMM8, R3}},
- {"cmp4.eq.andcm", A2, OpX2TaC (0xc, 3, 1, 1), {P1, P2, IMM8, R3}, PSEUDO},
- {"cmp.ltu", A2, OpX2TbTaC (0xd, 0, 0, 0, 0), {P1, P2, R2, R3}},
- {"cmp.leu", A2, OpX2TbTaC (0xd, 0, 0, 0, 0), {P2, P1, R3, R2}},
- {"cmp.gtu", A2, OpX2TbTaC (0xd, 0, 0, 0, 0), {P1, P2, R3, R2}},
- {"cmp.geu", A2, OpX2TbTaC (0xd, 0, 0, 0, 0), {P2, P1, R2, R3}},
- {"cmp.ltu.unc", A2, OpX2TbTaC (0xd, 0, 0, 0, 1), {P1, P2, R2, R3}},
- {"cmp.leu.unc", A2, OpX2TbTaC (0xd, 0, 0, 0, 1), {P2, P1, R3, R2}},
- {"cmp.gtu.unc", A2, OpX2TbTaC (0xd, 0, 0, 0, 1), {P1, P2, R3, R2}},
- {"cmp.geu.unc", A2, OpX2TbTaC (0xd, 0, 0, 0, 1), {P2, P1, R2, R3}},
- {"cmp.eq.or", A2, OpX2TbTaC (0xd, 0, 0, 1, 0), {P1, P2, R2, R3}},
- {"cmp.ne.orcm", A2, OpX2TbTaC (0xd, 0, 0, 1, 0), {P1, P2, R2, R3}, PSEUDO},
- {"cmp.ne.or", A2, OpX2TbTaC (0xd, 0, 0, 1, 1), {P1, P2, R2, R3}},
- {"cmp.eq.orcm", A2, OpX2TbTaC (0xd, 0, 0, 1, 1), {P1, P2, R2, R3}, PSEUDO},
- {"cmp4.ltu", A2, OpX2TbTaC (0xd, 1, 0, 0, 0), {P1, P2, R2, R3}},
- {"cmp4.leu", A2, OpX2TbTaC (0xd, 1, 0, 0, 0), {P2, P1, R3, R2}},
- {"cmp4.gtu", A2, OpX2TbTaC (0xd, 1, 0, 0, 0), {P1, P2, R3, R2}},
- {"cmp4.geu", A2, OpX2TbTaC (0xd, 1, 0, 0, 0), {P2, P1, R2, R3}},
- {"cmp4.ltu.unc", A2, OpX2TbTaC (0xd, 1, 0, 0, 1), {P1, P2, R2, R3}},
- {"cmp4.leu.unc", A2, OpX2TbTaC (0xd, 1, 0, 0, 1), {P2, P1, R3, R2}},
- {"cmp4.gtu.unc", A2, OpX2TbTaC (0xd, 1, 0, 0, 1), {P1, P2, R3, R2}},
- {"cmp4.geu.unc", A2, OpX2TbTaC (0xd, 1, 0, 0, 1), {P2, P1, R2, R3}},
- {"cmp4.eq.or", A2, OpX2TbTaC (0xd, 1, 0, 1, 0), {P1, P2, R2, R3}},
- {"cmp4.ne.orcm", A2, OpX2TbTaC (0xd, 1, 0, 1, 0), {P1, P2, R2, R3}, PSEUDO},
- {"cmp4.ne.or", A2, OpX2TbTaC (0xd, 1, 0, 1, 1), {P1, P2, R2, R3}},
- {"cmp4.eq.orcm", A2, OpX2TbTaC (0xd, 1, 0, 1, 1), {P1, P2, R2, R3}, PSEUDO},
- {"cmp.gt.or", A2, OpX2TbTaC (0xd, 0, 1, 0, 0), {P1, P2, GR0, R3}},
- {"cmp.lt.or", A2, OpX2TbTaC (0xd, 0, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.le.orcm", A2, OpX2TbTaC (0xd, 0, 1, 0, 0), {P1, P2, GR0, R3}, PSEUDO},
- {"cmp.ge.orcm", A2, OpX2TbTaC (0xd, 0, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.le.or", A2, OpX2TbTaC (0xd, 0, 1, 0, 1), {P1, P2, GR0, R3}},
- {"cmp.ge.or", A2, OpX2TbTaC (0xd, 0, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.gt.orcm", A2, OpX2TbTaC (0xd, 0, 1, 0, 1), {P1, P2, GR0, R3}, PSEUDO},
- {"cmp.lt.orcm", A2, OpX2TbTaC (0xd, 0, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.ge.or", A2, OpX2TbTaC (0xd, 0, 1, 1, 0), {P1, P2, GR0, R3}},
- {"cmp.le.or", A2, OpX2TbTaC (0xd, 0, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.lt.orcm", A2, OpX2TbTaC (0xd, 0, 1, 1, 0), {P1, P2, GR0, R3}, PSEUDO},
- {"cmp.gt.orcm", A2, OpX2TbTaC (0xd, 0, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.lt.or", A2, OpX2TbTaC (0xd, 0, 1, 1, 1), {P1, P2, GR0, R3}},
- {"cmp.gt.or", A2, OpX2TbTaC (0xd, 0, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.ge.orcm", A2, OpX2TbTaC (0xd, 0, 1, 1, 1), {P1, P2, GR0, R3}, PSEUDO},
- {"cmp.le.orcm", A2, OpX2TbTaC (0xd, 0, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.gt.or", A2, OpX2TbTaC (0xd, 1, 1, 0, 0), {P1, P2, GR0, R3}},
- {"cmp4.lt.or", A2, OpX2TbTaC (0xd, 1, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.le.orcm", A2, OpX2TbTaC (0xd, 1, 1, 0, 0), {P1, P2, GR0, R3}, PSEUDO},
- {"cmp4.ge.orcm", A2, OpX2TbTaC (0xd, 1, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.le.or", A2, OpX2TbTaC (0xd, 1, 1, 0, 1), {P1, P2, GR0, R3}},
- {"cmp4.ge.or", A2, OpX2TbTaC (0xd, 1, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.gt.orcm", A2, OpX2TbTaC (0xd, 1, 1, 0, 1), {P1, P2, GR0, R3}, PSEUDO},
- {"cmp4.lt.orcm", A2, OpX2TbTaC (0xd, 1, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.ge.or", A2, OpX2TbTaC (0xd, 1, 1, 1, 0), {P1, P2, GR0, R3}},
- {"cmp4.le.or", A2, OpX2TbTaC (0xd, 1, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.lt.orcm", A2, OpX2TbTaC (0xd, 1, 1, 1, 0), {P1, P2, GR0, R3}, PSEUDO},
- {"cmp4.gt.orcm", A2, OpX2TbTaC (0xd, 1, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.lt.or", A2, OpX2TbTaC (0xd, 1, 1, 1, 1), {P1, P2, GR0, R3}},
- {"cmp4.gt.or", A2, OpX2TbTaC (0xd, 1, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.ge.orcm", A2, OpX2TbTaC (0xd, 1, 1, 1, 1), {P1, P2, GR0, R3}, PSEUDO},
- {"cmp4.le.orcm", A2, OpX2TbTaC (0xd, 1, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.ltu", A2, OpX2TaC (0xd, 2, 0, 0), {P1, P2, IMM8, R3}},
- {"cmp.leu", A2, OpX2TaC (0xd, 2, 0, 0), {P1, P2, IMM8M1U8, R3}},
- {"cmp.gtu", A2, OpX2TaC (0xd, 2, 0, 0), {P2, P1, IMM8M1U8, R3}},
- {"cmp.geu", A2, OpX2TaC (0xd, 2, 0, 0), {P2, P1, IMM8, R3}},
- {"cmp.ltu.unc", A2, OpX2TaC (0xd, 2, 0, 1), {P1, P2, IMM8, R3}},
- {"cmp.leu.unc", A2, OpX2TaC (0xd, 2, 0, 1), {P1, P2, IMM8M1U8, R3}},
- {"cmp.gtu.unc", A2, OpX2TaC (0xd, 2, 0, 1), {P2, P1, IMM8M1U8, R3}},
- {"cmp.geu.unc", A2, OpX2TaC (0xd, 2, 0, 1), {P2, P1, IMM8, R3}},
- {"cmp.eq.or", A2, OpX2TaC (0xd, 2, 1, 0), {P1, P2, IMM8, R3}},
- {"cmp.ne.orcm", A2, OpX2TaC (0xd, 2, 1, 0), {P1, P2, IMM8, R3}, PSEUDO},
- {"cmp.ne.or", A2, OpX2TaC (0xd, 2, 1, 1), {P1, P2, IMM8, R3}},
- {"cmp.eq.orcm", A2, OpX2TaC (0xd, 2, 1, 1), {P1, P2, IMM8, R3}, PSEUDO},
- {"cmp4.ltu", A2, OpX2TaC (0xd, 3, 0, 0), {P1, P2, IMM8U4, R3}},
- {"cmp4.leu", A2, OpX2TaC (0xd, 3, 0, 0), {P1, P2, IMM8M1U4, R3}},
- {"cmp4.gtu", A2, OpX2TaC (0xd, 3, 0, 0), {P2, P1, IMM8M1U4, R3}},
- {"cmp4.geu", A2, OpX2TaC (0xd, 3, 0, 0), {P2, P1, IMM8U4, R3}},
- {"cmp4.ltu.unc", A2, OpX2TaC (0xd, 3, 0, 1), {P1, P2, IMM8U4, R3}},
- {"cmp4.leu.unc", A2, OpX2TaC (0xd, 3, 0, 1), {P1, P2, IMM8M1U4, R3}},
- {"cmp4.gtu.unc", A2, OpX2TaC (0xd, 3, 0, 1), {P2, P1, IMM8M1U4, R3}},
- {"cmp4.geu.unc", A2, OpX2TaC (0xd, 3, 0, 1), {P2, P1, IMM8U4, R3}},
- {"cmp4.eq.or", A2, OpX2TaC (0xd, 3, 1, 0), {P1, P2, IMM8, R3}},
- {"cmp4.ne.orcm", A2, OpX2TaC (0xd, 3, 1, 0), {P1, P2, IMM8, R3}, PSEUDO},
- {"cmp4.ne.or", A2, OpX2TaC (0xd, 3, 1, 1), {P1, P2, IMM8, R3}},
- {"cmp4.eq.orcm", A2, OpX2TaC (0xd, 3, 1, 1), {P1, P2, IMM8, R3}, PSEUDO},
- {"cmp.eq", A2, OpX2TbTaC (0xe, 0, 0, 0, 0), {P1, P2, R2, R3}},
- {"cmp.ne", A2, OpX2TbTaC (0xe, 0, 0, 0, 0), {P2, P1, R2, R3}},
- {"cmp.eq.unc", A2, OpX2TbTaC (0xe, 0, 0, 0, 1), {P1, P2, R2, R3}},
- {"cmp.ne.unc", A2, OpX2TbTaC (0xe, 0, 0, 0, 1), {P2, P1, R2, R3}},
- {"cmp.eq.or.andcm", A2, OpX2TbTaC (0xe, 0, 0, 1, 0), {P1, P2, R2, R3}},
- {"cmp.ne.and.orcm", A2, OpX2TbTaC (0xe, 0, 0, 1, 0), {P2, P1, R2, R3}, PSEUDO},
- {"cmp.ne.or.andcm", A2, OpX2TbTaC (0xe, 0, 0, 1, 1), {P1, P2, R2, R3}},
- {"cmp.eq.and.orcm", A2, OpX2TbTaC (0xe, 0, 0, 1, 1), {P2, P1, R2, R3}, PSEUDO},
- {"cmp4.eq", A2, OpX2TbTaC (0xe, 1, 0, 0, 0), {P1, P2, R2, R3}},
- {"cmp4.ne", A2, OpX2TbTaC (0xe, 1, 0, 0, 0), {P2, P1, R2, R3}},
- {"cmp4.eq.unc", A2, OpX2TbTaC (0xe, 1, 0, 0, 1), {P1, P2, R2, R3}},
- {"cmp4.ne.unc", A2, OpX2TbTaC (0xe, 1, 0, 0, 1), {P2, P1, R2, R3}},
- {"cmp4.eq.or.andcm", A2, OpX2TbTaC (0xe, 1, 0, 1, 0), {P1, P2, R2, R3}},
- {"cmp4.ne.and.orcm", A2, OpX2TbTaC (0xe, 1, 0, 1, 0), {P2, P1, R2, R3}, PSEUDO},
- {"cmp4.ne.or.andcm", A2, OpX2TbTaC (0xe, 1, 0, 1, 1), {P1, P2, R2, R3}},
- {"cmp4.eq.and.orcm", A2, OpX2TbTaC (0xe, 1, 0, 1, 1), {P2, P1, R2, R3}, PSEUDO},
- {"cmp.gt.or.andcm", A2, OpX2TbTaC (0xe, 0, 1, 0, 0), {P1, P2, GR0, R3}},
- {"cmp.lt.or.andcm", A2, OpX2TbTaC (0xe, 0, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.le.and.orcm", A2, OpX2TbTaC (0xe, 0, 1, 0, 0), {P2, P1, GR0, R3}, PSEUDO},
- {"cmp.ge.and.orcm", A2, OpX2TbTaC (0xe, 0, 1, 0, 0), {P2, P1, R3, GR0}, PSEUDO},
- {"cmp.le.or.andcm", A2, OpX2TbTaC (0xe, 0, 1, 0, 1), {P1, P2, GR0, R3}},
- {"cmp.ge.or.andcm", A2, OpX2TbTaC (0xe, 0, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.gt.and.orcm", A2, OpX2TbTaC (0xe, 0, 1, 0, 1), {P2, P1, GR0, R3}, PSEUDO},
- {"cmp.lt.and.orcm", A2, OpX2TbTaC (0xe, 0, 1, 0, 1), {P2, P1, R3, GR0}, PSEUDO},
- {"cmp.ge.or.andcm", A2, OpX2TbTaC (0xe, 0, 1, 1, 0), {P1, P2, GR0, R3}},
- {"cmp.le.or.andcm", A2, OpX2TbTaC (0xe, 0, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.lt.and.orcm", A2, OpX2TbTaC (0xe, 0, 1, 1, 0), {P2, P1, GR0, R3}, PSEUDO},
- {"cmp.gt.and.orcm", A2, OpX2TbTaC (0xe, 0, 1, 1, 0), {P2, P1, R3, GR0}, PSEUDO},
- {"cmp.lt.or.andcm", A2, OpX2TbTaC (0xe, 0, 1, 1, 1), {P1, P2, GR0, R3}},
- {"cmp.gt.or.andcm", A2, OpX2TbTaC (0xe, 0, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp.ge.and.orcm", A2, OpX2TbTaC (0xe, 0, 1, 1, 1), {P2, P1, GR0, R3}, PSEUDO},
- {"cmp.le.and.orcm", A2, OpX2TbTaC (0xe, 0, 1, 1, 1), {P2, P1, R3, GR0}, PSEUDO},
- {"cmp4.gt.or.andcm", A2, OpX2TbTaC (0xe, 1, 1, 0, 0), {P1, P2, GR0, R3}},
- {"cmp4.lt.or.andcm", A2, OpX2TbTaC (0xe, 1, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.le.and.orcm", A2, OpX2TbTaC (0xe, 1, 1, 0, 0), {P2, P1, GR0, R3}, PSEUDO},
- {"cmp4.ge.and.orcm", A2, OpX2TbTaC (0xe, 1, 1, 0, 0), {P2, P1, R3, GR0}, PSEUDO},
- {"cmp4.le.or.andcm", A2, OpX2TbTaC (0xe, 1, 1, 0, 1), {P1, P2, GR0, R3}},
- {"cmp4.ge.or.andcm", A2, OpX2TbTaC (0xe, 1, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.gt.and.orcm", A2, OpX2TbTaC (0xe, 1, 1, 0, 1), {P2, P1, GR0, R3}, PSEUDO},
- {"cmp4.lt.and.orcm", A2, OpX2TbTaC (0xe, 1, 1, 0, 1), {P2, P1, R3, GR0}, PSEUDO},
- {"cmp4.ge.or.andcm", A2, OpX2TbTaC (0xe, 1, 1, 1, 0), {P1, P2, GR0, R3}},
- {"cmp4.le.or.andcm", A2, OpX2TbTaC (0xe, 1, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.lt.and.orcm", A2, OpX2TbTaC (0xe, 1, 1, 1, 0), {P2, P1, GR0, R3}, PSEUDO},
- {"cmp4.gt.and.orcm", A2, OpX2TbTaC (0xe, 1, 1, 1, 0), {P2, P1, R3, GR0}, PSEUDO},
- {"cmp4.lt.or.andcm", A2, OpX2TbTaC (0xe, 1, 1, 1, 1), {P1, P2, GR0, R3}},
- {"cmp4.gt.or.andcm", A2, OpX2TbTaC (0xe, 1, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO},
- {"cmp4.ge.and.orcm", A2, OpX2TbTaC (0xe, 1, 1, 1, 1), {P2, P1, GR0, R3}, PSEUDO},
- {"cmp4.le.and.orcm", A2, OpX2TbTaC (0xe, 1, 1, 1, 1), {P2, P1, R3, GR0}, PSEUDO},
- {"cmp.eq", A2, OpX2TaC (0xe, 2, 0, 0), {P1, P2, IMM8, R3}},
- {"cmp.ne", A2, OpX2TaC (0xe, 2, 0, 0), {P2, P1, IMM8, R3}},
- {"cmp.eq.unc", A2, OpX2TaC (0xe, 2, 0, 1), {P1, P2, IMM8, R3}},
- {"cmp.ne.unc", A2, OpX2TaC (0xe, 2, 0, 1), {P2, P1, IMM8, R3}},
- {"cmp.eq.or.andcm", A2, OpX2TaC (0xe, 2, 1, 0), {P1, P2, IMM8, R3}},
- {"cmp.ne.and.orcm", A2, OpX2TaC (0xe, 2, 1, 0), {P2, P1, IMM8, R3}, PSEUDO},
- {"cmp.ne.or.andcm", A2, OpX2TaC (0xe, 2, 1, 1), {P1, P2, IMM8, R3}},
- {"cmp.eq.and.orcm", A2, OpX2TaC (0xe, 2, 1, 1), {P2, P1, IMM8, R3}, PSEUDO},
- {"cmp4.eq", A2, OpX2TaC (0xe, 3, 0, 0), {P1, P2, IMM8, R3}},
- {"cmp4.ne", A2, OpX2TaC (0xe, 3, 0, 0), {P2, P1, IMM8, R3}},
- {"cmp4.eq.unc", A2, OpX2TaC (0xe, 3, 0, 1), {P1, P2, IMM8, R3}},
- {"cmp4.ne.unc", A2, OpX2TaC (0xe, 3, 0, 1), {P2, P1, IMM8, R3}},
- {"cmp4.eq.or.andcm", A2, OpX2TaC (0xe, 3, 1, 0), {P1, P2, IMM8, R3}},
- {"cmp4.ne.and.orcm", A2, OpX2TaC (0xe, 3, 1, 0), {P2, P1, IMM8, R3}, PSEUDO},
- {"cmp4.ne.or.andcm", A2, OpX2TaC (0xe, 3, 1, 1), {P1, P2, IMM8, R3}},
- {"cmp4.eq.and.orcm", A2, OpX2TaC (0xe, 3, 1, 1), {P2, P1, IMM8, R3}, PSEUDO},
+ {"cmp.lt", A2, OpX2TbTaC (0xc, 0, 0, 0, 0), {P1, P2, R2, R3}, EMPTY},
+ {"cmp.le", A2, OpX2TbTaC (0xc, 0, 0, 0, 0), {P2, P1, R3, R2}, EMPTY},
+ {"cmp.gt", A2, OpX2TbTaC (0xc, 0, 0, 0, 0), {P1, P2, R3, R2}, EMPTY},
+ {"cmp.ge", A2, OpX2TbTaC (0xc, 0, 0, 0, 0), {P2, P1, R2, R3}, EMPTY},
+ {"cmp.lt.unc", A2, OpX2TbTaC (0xc, 0, 0, 0, 1), {P1, P2, R2, R3}, EMPTY},
+ {"cmp.le.unc", A2, OpX2TbTaC (0xc, 0, 0, 0, 1), {P2, P1, R3, R2}, EMPTY},
+ {"cmp.gt.unc", A2, OpX2TbTaC (0xc, 0, 0, 0, 1), {P1, P2, R3, R2}, EMPTY},
+ {"cmp.ge.unc", A2, OpX2TbTaC (0xc, 0, 0, 0, 1), {P2, P1, R2, R3}, EMPTY},
+ {"cmp.eq.and", A2, OpX2TbTaC (0xc, 0, 0, 1, 0), {P1, P2, R2, R3}, EMPTY},
+ {"cmp.ne.andcm", A2, OpX2TbTaC (0xc, 0, 0, 1, 0), {P1, P2, R2, R3}, PSEUDO, 0, NULL},
+ {"cmp.ne.and", A2, OpX2TbTaC (0xc, 0, 0, 1, 1), {P1, P2, R2, R3}, EMPTY},
+ {"cmp.eq.andcm", A2, OpX2TbTaC (0xc, 0, 0, 1, 1), {P1, P2, R2, R3}, PSEUDO, 0, NULL},
+ {"cmp4.lt", A2, OpX2TbTaC (0xc, 1, 0, 0, 0), {P1, P2, R2, R3}, EMPTY},
+ {"cmp4.le", A2, OpX2TbTaC (0xc, 1, 0, 0, 0), {P2, P1, R3, R2}, EMPTY},
+ {"cmp4.gt", A2, OpX2TbTaC (0xc, 1, 0, 0, 0), {P1, P2, R3, R2}, EMPTY},
+ {"cmp4.ge", A2, OpX2TbTaC (0xc, 1, 0, 0, 0), {P2, P1, R2, R3}, EMPTY},
+ {"cmp4.lt.unc", A2, OpX2TbTaC (0xc, 1, 0, 0, 1), {P1, P2, R2, R3}, EMPTY},
+ {"cmp4.le.unc", A2, OpX2TbTaC (0xc, 1, 0, 0, 1), {P2, P1, R3, R2}, EMPTY},
+ {"cmp4.gt.unc", A2, OpX2TbTaC (0xc, 1, 0, 0, 1), {P1, P2, R3, R2}, EMPTY},
+ {"cmp4.ge.unc", A2, OpX2TbTaC (0xc, 1, 0, 0, 1), {P2, P1, R2, R3}, EMPTY},
+ {"cmp4.eq.and", A2, OpX2TbTaC (0xc, 1, 0, 1, 0), {P1, P2, R2, R3}, EMPTY},
+ {"cmp4.ne.andcm", A2, OpX2TbTaC (0xc, 1, 0, 1, 0), {P1, P2, R2, R3}, PSEUDO, 0, NULL},
+ {"cmp4.ne.and", A2, OpX2TbTaC (0xc, 1, 0, 1, 1), {P1, P2, R2, R3}, EMPTY},
+ {"cmp4.eq.andcm", A2, OpX2TbTaC (0xc, 1, 0, 1, 1), {P1, P2, R2, R3}, PSEUDO, 0, NULL},
+ {"cmp.gt.and", A2, OpX2TbTaC (0xc, 0, 1, 0, 0), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp.lt.and", A2, OpX2TbTaC (0xc, 0, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.le.andcm", A2, OpX2TbTaC (0xc, 0, 1, 0, 0), {P1, P2, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp.ge.andcm", A2, OpX2TbTaC (0xc, 0, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.le.and", A2, OpX2TbTaC (0xc, 0, 1, 0, 1), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp.ge.and", A2, OpX2TbTaC (0xc, 0, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.gt.andcm", A2, OpX2TbTaC (0xc, 0, 1, 0, 1), {P1, P2, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp.lt.andcm", A2, OpX2TbTaC (0xc, 0, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.ge.and", A2, OpX2TbTaC (0xc, 0, 1, 1, 0), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp.le.and", A2, OpX2TbTaC (0xc, 0, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.lt.andcm", A2, OpX2TbTaC (0xc, 0, 1, 1, 0), {P1, P2, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp.gt.andcm", A2, OpX2TbTaC (0xc, 0, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.lt.and", A2, OpX2TbTaC (0xc, 0, 1, 1, 1), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp.gt.and", A2, OpX2TbTaC (0xc, 0, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.ge.andcm", A2, OpX2TbTaC (0xc, 0, 1, 1, 1), {P1, P2, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp.le.andcm", A2, OpX2TbTaC (0xc, 0, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.gt.and", A2, OpX2TbTaC (0xc, 1, 1, 0, 0), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp4.lt.and", A2, OpX2TbTaC (0xc, 1, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.le.andcm", A2, OpX2TbTaC (0xc, 1, 1, 0, 0), {P1, P2, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp4.ge.andcm", A2, OpX2TbTaC (0xc, 1, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.le.and", A2, OpX2TbTaC (0xc, 1, 1, 0, 1), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp4.ge.and", A2, OpX2TbTaC (0xc, 1, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.gt.andcm", A2, OpX2TbTaC (0xc, 1, 1, 0, 1), {P1, P2, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp4.lt.andcm", A2, OpX2TbTaC (0xc, 1, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.ge.and", A2, OpX2TbTaC (0xc, 1, 1, 1, 0), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp4.le.and", A2, OpX2TbTaC (0xc, 1, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.lt.andcm", A2, OpX2TbTaC (0xc, 1, 1, 1, 0), {P1, P2, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp4.gt.andcm", A2, OpX2TbTaC (0xc, 1, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.lt.and", A2, OpX2TbTaC (0xc, 1, 1, 1, 1), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp4.gt.and", A2, OpX2TbTaC (0xc, 1, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.ge.andcm", A2, OpX2TbTaC (0xc, 1, 1, 1, 1), {P1, P2, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp4.le.andcm", A2, OpX2TbTaC (0xc, 1, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.lt", A2, OpX2TaC (0xc, 2, 0, 0), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp.le", A2, OpX2TaC (0xc, 2, 0, 0), {P1, P2, IMM8M1, R3}, EMPTY},
+ {"cmp.gt", A2, OpX2TaC (0xc, 2, 0, 0), {P2, P1, IMM8M1, R3}, EMPTY},
+ {"cmp.ge", A2, OpX2TaC (0xc, 2, 0, 0), {P2, P1, IMM8, R3}, EMPTY},
+ {"cmp.lt.unc", A2, OpX2TaC (0xc, 2, 0, 1), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp.le.unc", A2, OpX2TaC (0xc, 2, 0, 1), {P1, P2, IMM8M1, R3}, EMPTY},
+ {"cmp.gt.unc", A2, OpX2TaC (0xc, 2, 0, 1), {P2, P1, IMM8M1, R3}, EMPTY},
+ {"cmp.ge.unc", A2, OpX2TaC (0xc, 2, 0, 1), {P2, P1, IMM8, R3}, EMPTY},
+ {"cmp.eq.and", A2, OpX2TaC (0xc, 2, 1, 0), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp.ne.andcm", A2, OpX2TaC (0xc, 2, 1, 0), {P1, P2, IMM8, R3}, PSEUDO, 0, NULL},
+ {"cmp.ne.and", A2, OpX2TaC (0xc, 2, 1, 1), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp.eq.andcm", A2, OpX2TaC (0xc, 2, 1, 1), {P1, P2, IMM8, R3}, PSEUDO, 0, NULL},
+ {"cmp4.lt", A2, OpX2TaC (0xc, 3, 0, 0), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp4.le", A2, OpX2TaC (0xc, 3, 0, 0), {P1, P2, IMM8M1, R3}, EMPTY},
+ {"cmp4.gt", A2, OpX2TaC (0xc, 3, 0, 0), {P2, P1, IMM8M1, R3}, EMPTY},
+ {"cmp4.ge", A2, OpX2TaC (0xc, 3, 0, 0), {P2, P1, IMM8, R3}, EMPTY},
+ {"cmp4.lt.unc", A2, OpX2TaC (0xc, 3, 0, 1), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp4.le.unc", A2, OpX2TaC (0xc, 3, 0, 1), {P1, P2, IMM8M1, R3}, EMPTY},
+ {"cmp4.gt.unc", A2, OpX2TaC (0xc, 3, 0, 1), {P2, P1, IMM8M1, R3}, EMPTY},
+ {"cmp4.ge.unc", A2, OpX2TaC (0xc, 3, 0, 1), {P2, P1, IMM8, R3}, EMPTY},
+ {"cmp4.eq.and", A2, OpX2TaC (0xc, 3, 1, 0), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp4.ne.andcm", A2, OpX2TaC (0xc, 3, 1, 0), {P1, P2, IMM8, R3}, PSEUDO, 0, NULL},
+ {"cmp4.ne.and", A2, OpX2TaC (0xc, 3, 1, 1), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp4.eq.andcm", A2, OpX2TaC (0xc, 3, 1, 1), {P1, P2, IMM8, R3}, PSEUDO, 0, NULL},
+ {"cmp.ltu", A2, OpX2TbTaC (0xd, 0, 0, 0, 0), {P1, P2, R2, R3}, EMPTY},
+ {"cmp.leu", A2, OpX2TbTaC (0xd, 0, 0, 0, 0), {P2, P1, R3, R2}, EMPTY},
+ {"cmp.gtu", A2, OpX2TbTaC (0xd, 0, 0, 0, 0), {P1, P2, R3, R2}, EMPTY},
+ {"cmp.geu", A2, OpX2TbTaC (0xd, 0, 0, 0, 0), {P2, P1, R2, R3}, EMPTY},
+ {"cmp.ltu.unc", A2, OpX2TbTaC (0xd, 0, 0, 0, 1), {P1, P2, R2, R3}, EMPTY},
+ {"cmp.leu.unc", A2, OpX2TbTaC (0xd, 0, 0, 0, 1), {P2, P1, R3, R2}, EMPTY},
+ {"cmp.gtu.unc", A2, OpX2TbTaC (0xd, 0, 0, 0, 1), {P1, P2, R3, R2}, EMPTY},
+ {"cmp.geu.unc", A2, OpX2TbTaC (0xd, 0, 0, 0, 1), {P2, P1, R2, R3}, EMPTY},
+ {"cmp.eq.or", A2, OpX2TbTaC (0xd, 0, 0, 1, 0), {P1, P2, R2, R3}, EMPTY},
+ {"cmp.ne.orcm", A2, OpX2TbTaC (0xd, 0, 0, 1, 0), {P1, P2, R2, R3}, PSEUDO, 0, NULL},
+ {"cmp.ne.or", A2, OpX2TbTaC (0xd, 0, 0, 1, 1), {P1, P2, R2, R3}, EMPTY},
+ {"cmp.eq.orcm", A2, OpX2TbTaC (0xd, 0, 0, 1, 1), {P1, P2, R2, R3}, PSEUDO, 0, NULL},
+ {"cmp4.ltu", A2, OpX2TbTaC (0xd, 1, 0, 0, 0), {P1, P2, R2, R3}, EMPTY},
+ {"cmp4.leu", A2, OpX2TbTaC (0xd, 1, 0, 0, 0), {P2, P1, R3, R2}, EMPTY},
+ {"cmp4.gtu", A2, OpX2TbTaC (0xd, 1, 0, 0, 0), {P1, P2, R3, R2}, EMPTY},
+ {"cmp4.geu", A2, OpX2TbTaC (0xd, 1, 0, 0, 0), {P2, P1, R2, R3}, EMPTY},
+ {"cmp4.ltu.unc", A2, OpX2TbTaC (0xd, 1, 0, 0, 1), {P1, P2, R2, R3}, EMPTY},
+ {"cmp4.leu.unc", A2, OpX2TbTaC (0xd, 1, 0, 0, 1), {P2, P1, R3, R2}, EMPTY},
+ {"cmp4.gtu.unc", A2, OpX2TbTaC (0xd, 1, 0, 0, 1), {P1, P2, R3, R2}, EMPTY},
+ {"cmp4.geu.unc", A2, OpX2TbTaC (0xd, 1, 0, 0, 1), {P2, P1, R2, R3}, EMPTY},
+ {"cmp4.eq.or", A2, OpX2TbTaC (0xd, 1, 0, 1, 0), {P1, P2, R2, R3}, EMPTY},
+ {"cmp4.ne.orcm", A2, OpX2TbTaC (0xd, 1, 0, 1, 0), {P1, P2, R2, R3}, PSEUDO, 0, NULL},
+ {"cmp4.ne.or", A2, OpX2TbTaC (0xd, 1, 0, 1, 1), {P1, P2, R2, R3}, EMPTY},
+ {"cmp4.eq.orcm", A2, OpX2TbTaC (0xd, 1, 0, 1, 1), {P1, P2, R2, R3}, PSEUDO, 0, NULL},
+ {"cmp.gt.or", A2, OpX2TbTaC (0xd, 0, 1, 0, 0), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp.lt.or", A2, OpX2TbTaC (0xd, 0, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.le.orcm", A2, OpX2TbTaC (0xd, 0, 1, 0, 0), {P1, P2, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp.ge.orcm", A2, OpX2TbTaC (0xd, 0, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.le.or", A2, OpX2TbTaC (0xd, 0, 1, 0, 1), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp.ge.or", A2, OpX2TbTaC (0xd, 0, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.gt.orcm", A2, OpX2TbTaC (0xd, 0, 1, 0, 1), {P1, P2, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp.lt.orcm", A2, OpX2TbTaC (0xd, 0, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.ge.or", A2, OpX2TbTaC (0xd, 0, 1, 1, 0), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp.le.or", A2, OpX2TbTaC (0xd, 0, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.lt.orcm", A2, OpX2TbTaC (0xd, 0, 1, 1, 0), {P1, P2, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp.gt.orcm", A2, OpX2TbTaC (0xd, 0, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.lt.or", A2, OpX2TbTaC (0xd, 0, 1, 1, 1), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp.gt.or", A2, OpX2TbTaC (0xd, 0, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.ge.orcm", A2, OpX2TbTaC (0xd, 0, 1, 1, 1), {P1, P2, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp.le.orcm", A2, OpX2TbTaC (0xd, 0, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.gt.or", A2, OpX2TbTaC (0xd, 1, 1, 0, 0), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp4.lt.or", A2, OpX2TbTaC (0xd, 1, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.le.orcm", A2, OpX2TbTaC (0xd, 1, 1, 0, 0), {P1, P2, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp4.ge.orcm", A2, OpX2TbTaC (0xd, 1, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.le.or", A2, OpX2TbTaC (0xd, 1, 1, 0, 1), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp4.ge.or", A2, OpX2TbTaC (0xd, 1, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.gt.orcm", A2, OpX2TbTaC (0xd, 1, 1, 0, 1), {P1, P2, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp4.lt.orcm", A2, OpX2TbTaC (0xd, 1, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.ge.or", A2, OpX2TbTaC (0xd, 1, 1, 1, 0), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp4.le.or", A2, OpX2TbTaC (0xd, 1, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.lt.orcm", A2, OpX2TbTaC (0xd, 1, 1, 1, 0), {P1, P2, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp4.gt.orcm", A2, OpX2TbTaC (0xd, 1, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.lt.or", A2, OpX2TbTaC (0xd, 1, 1, 1, 1), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp4.gt.or", A2, OpX2TbTaC (0xd, 1, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.ge.orcm", A2, OpX2TbTaC (0xd, 1, 1, 1, 1), {P1, P2, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp4.le.orcm", A2, OpX2TbTaC (0xd, 1, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.ltu", A2, OpX2TaC (0xd, 2, 0, 0), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp.leu", A2, OpX2TaC (0xd, 2, 0, 0), {P1, P2, IMM8M1U8, R3}, EMPTY},
+ {"cmp.gtu", A2, OpX2TaC (0xd, 2, 0, 0), {P2, P1, IMM8M1U8, R3}, EMPTY},
+ {"cmp.geu", A2, OpX2TaC (0xd, 2, 0, 0), {P2, P1, IMM8, R3}, EMPTY},
+ {"cmp.ltu.unc", A2, OpX2TaC (0xd, 2, 0, 1), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp.leu.unc", A2, OpX2TaC (0xd, 2, 0, 1), {P1, P2, IMM8M1U8, R3}, EMPTY},
+ {"cmp.gtu.unc", A2, OpX2TaC (0xd, 2, 0, 1), {P2, P1, IMM8M1U8, R3}, EMPTY},
+ {"cmp.geu.unc", A2, OpX2TaC (0xd, 2, 0, 1), {P2, P1, IMM8, R3}, EMPTY},
+ {"cmp.eq.or", A2, OpX2TaC (0xd, 2, 1, 0), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp.ne.orcm", A2, OpX2TaC (0xd, 2, 1, 0), {P1, P2, IMM8, R3}, PSEUDO, 0, NULL},
+ {"cmp.ne.or", A2, OpX2TaC (0xd, 2, 1, 1), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp.eq.orcm", A2, OpX2TaC (0xd, 2, 1, 1), {P1, P2, IMM8, R3}, PSEUDO, 0, NULL},
+ {"cmp4.ltu", A2, OpX2TaC (0xd, 3, 0, 0), {P1, P2, IMM8U4, R3}, EMPTY},
+ {"cmp4.leu", A2, OpX2TaC (0xd, 3, 0, 0), {P1, P2, IMM8M1U4, R3}, EMPTY},
+ {"cmp4.gtu", A2, OpX2TaC (0xd, 3, 0, 0), {P2, P1, IMM8M1U4, R3}, EMPTY},
+ {"cmp4.geu", A2, OpX2TaC (0xd, 3, 0, 0), {P2, P1, IMM8U4, R3}, EMPTY},
+ {"cmp4.ltu.unc", A2, OpX2TaC (0xd, 3, 0, 1), {P1, P2, IMM8U4, R3}, EMPTY},
+ {"cmp4.leu.unc", A2, OpX2TaC (0xd, 3, 0, 1), {P1, P2, IMM8M1U4, R3}, EMPTY},
+ {"cmp4.gtu.unc", A2, OpX2TaC (0xd, 3, 0, 1), {P2, P1, IMM8M1U4, R3}, EMPTY},
+ {"cmp4.geu.unc", A2, OpX2TaC (0xd, 3, 0, 1), {P2, P1, IMM8U4, R3}, EMPTY},
+ {"cmp4.eq.or", A2, OpX2TaC (0xd, 3, 1, 0), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp4.ne.orcm", A2, OpX2TaC (0xd, 3, 1, 0), {P1, P2, IMM8, R3}, PSEUDO, 0, NULL},
+ {"cmp4.ne.or", A2, OpX2TaC (0xd, 3, 1, 1), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp4.eq.orcm", A2, OpX2TaC (0xd, 3, 1, 1), {P1, P2, IMM8, R3}, PSEUDO, 0, NULL},
+ {"cmp.eq", A2, OpX2TbTaC (0xe, 0, 0, 0, 0), {P1, P2, R2, R3}, EMPTY},
+ {"cmp.ne", A2, OpX2TbTaC (0xe, 0, 0, 0, 0), {P2, P1, R2, R3}, EMPTY},
+ {"cmp.eq.unc", A2, OpX2TbTaC (0xe, 0, 0, 0, 1), {P1, P2, R2, R3}, EMPTY},
+ {"cmp.ne.unc", A2, OpX2TbTaC (0xe, 0, 0, 0, 1), {P2, P1, R2, R3}, EMPTY},
+ {"cmp.eq.or.andcm", A2, OpX2TbTaC (0xe, 0, 0, 1, 0), {P1, P2, R2, R3}, EMPTY},
+ {"cmp.ne.and.orcm", A2, OpX2TbTaC (0xe, 0, 0, 1, 0), {P2, P1, R2, R3}, PSEUDO, 0, NULL},
+ {"cmp.ne.or.andcm", A2, OpX2TbTaC (0xe, 0, 0, 1, 1), {P1, P2, R2, R3}, EMPTY},
+ {"cmp.eq.and.orcm", A2, OpX2TbTaC (0xe, 0, 0, 1, 1), {P2, P1, R2, R3}, PSEUDO, 0, NULL},
+ {"cmp4.eq", A2, OpX2TbTaC (0xe, 1, 0, 0, 0), {P1, P2, R2, R3}, EMPTY},
+ {"cmp4.ne", A2, OpX2TbTaC (0xe, 1, 0, 0, 0), {P2, P1, R2, R3}, EMPTY},
+ {"cmp4.eq.unc", A2, OpX2TbTaC (0xe, 1, 0, 0, 1), {P1, P2, R2, R3}, EMPTY},
+ {"cmp4.ne.unc", A2, OpX2TbTaC (0xe, 1, 0, 0, 1), {P2, P1, R2, R3}, EMPTY},
+ {"cmp4.eq.or.andcm", A2, OpX2TbTaC (0xe, 1, 0, 1, 0), {P1, P2, R2, R3}, EMPTY},
+ {"cmp4.ne.and.orcm", A2, OpX2TbTaC (0xe, 1, 0, 1, 0), {P2, P1, R2, R3}, PSEUDO, 0, NULL},
+ {"cmp4.ne.or.andcm", A2, OpX2TbTaC (0xe, 1, 0, 1, 1), {P1, P2, R2, R3}, EMPTY},
+ {"cmp4.eq.and.orcm", A2, OpX2TbTaC (0xe, 1, 0, 1, 1), {P2, P1, R2, R3}, PSEUDO, 0, NULL},
+ {"cmp.gt.or.andcm", A2, OpX2TbTaC (0xe, 0, 1, 0, 0), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp.lt.or.andcm", A2, OpX2TbTaC (0xe, 0, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.le.and.orcm", A2, OpX2TbTaC (0xe, 0, 1, 0, 0), {P2, P1, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp.ge.and.orcm", A2, OpX2TbTaC (0xe, 0, 1, 0, 0), {P2, P1, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.le.or.andcm", A2, OpX2TbTaC (0xe, 0, 1, 0, 1), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp.ge.or.andcm", A2, OpX2TbTaC (0xe, 0, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.gt.and.orcm", A2, OpX2TbTaC (0xe, 0, 1, 0, 1), {P2, P1, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp.lt.and.orcm", A2, OpX2TbTaC (0xe, 0, 1, 0, 1), {P2, P1, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.ge.or.andcm", A2, OpX2TbTaC (0xe, 0, 1, 1, 0), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp.le.or.andcm", A2, OpX2TbTaC (0xe, 0, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.lt.and.orcm", A2, OpX2TbTaC (0xe, 0, 1, 1, 0), {P2, P1, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp.gt.and.orcm", A2, OpX2TbTaC (0xe, 0, 1, 1, 0), {P2, P1, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.lt.or.andcm", A2, OpX2TbTaC (0xe, 0, 1, 1, 1), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp.gt.or.andcm", A2, OpX2TbTaC (0xe, 0, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.ge.and.orcm", A2, OpX2TbTaC (0xe, 0, 1, 1, 1), {P2, P1, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp.le.and.orcm", A2, OpX2TbTaC (0xe, 0, 1, 1, 1), {P2, P1, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.gt.or.andcm", A2, OpX2TbTaC (0xe, 1, 1, 0, 0), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp4.lt.or.andcm", A2, OpX2TbTaC (0xe, 1, 1, 0, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.le.and.orcm", A2, OpX2TbTaC (0xe, 1, 1, 0, 0), {P2, P1, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp4.ge.and.orcm", A2, OpX2TbTaC (0xe, 1, 1, 0, 0), {P2, P1, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.le.or.andcm", A2, OpX2TbTaC (0xe, 1, 1, 0, 1), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp4.ge.or.andcm", A2, OpX2TbTaC (0xe, 1, 1, 0, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.gt.and.orcm", A2, OpX2TbTaC (0xe, 1, 1, 0, 1), {P2, P1, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp4.lt.and.orcm", A2, OpX2TbTaC (0xe, 1, 1, 0, 1), {P2, P1, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.ge.or.andcm", A2, OpX2TbTaC (0xe, 1, 1, 1, 0), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp4.le.or.andcm", A2, OpX2TbTaC (0xe, 1, 1, 1, 0), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.lt.and.orcm", A2, OpX2TbTaC (0xe, 1, 1, 1, 0), {P2, P1, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp4.gt.and.orcm", A2, OpX2TbTaC (0xe, 1, 1, 1, 0), {P2, P1, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.lt.or.andcm", A2, OpX2TbTaC (0xe, 1, 1, 1, 1), {P1, P2, GR0, R3}, EMPTY},
+ {"cmp4.gt.or.andcm", A2, OpX2TbTaC (0xe, 1, 1, 1, 1), {P1, P2, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp4.ge.and.orcm", A2, OpX2TbTaC (0xe, 1, 1, 1, 1), {P2, P1, GR0, R3}, PSEUDO, 0, NULL},
+ {"cmp4.le.and.orcm", A2, OpX2TbTaC (0xe, 1, 1, 1, 1), {P2, P1, R3, GR0}, PSEUDO, 0, NULL},
+ {"cmp.eq", A2, OpX2TaC (0xe, 2, 0, 0), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp.ne", A2, OpX2TaC (0xe, 2, 0, 0), {P2, P1, IMM8, R3}, EMPTY},
+ {"cmp.eq.unc", A2, OpX2TaC (0xe, 2, 0, 1), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp.ne.unc", A2, OpX2TaC (0xe, 2, 0, 1), {P2, P1, IMM8, R3}, EMPTY},
+ {"cmp.eq.or.andcm", A2, OpX2TaC (0xe, 2, 1, 0), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp.ne.and.orcm", A2, OpX2TaC (0xe, 2, 1, 0), {P2, P1, IMM8, R3}, PSEUDO, 0, NULL},
+ {"cmp.ne.or.andcm", A2, OpX2TaC (0xe, 2, 1, 1), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp.eq.and.orcm", A2, OpX2TaC (0xe, 2, 1, 1), {P2, P1, IMM8, R3}, PSEUDO, 0, NULL},
+ {"cmp4.eq", A2, OpX2TaC (0xe, 3, 0, 0), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp4.ne", A2, OpX2TaC (0xe, 3, 0, 0), {P2, P1, IMM8, R3}, EMPTY},
+ {"cmp4.eq.unc", A2, OpX2TaC (0xe, 3, 0, 1), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp4.ne.unc", A2, OpX2TaC (0xe, 3, 0, 1), {P2, P1, IMM8, R3}, EMPTY},
+ {"cmp4.eq.or.andcm", A2, OpX2TaC (0xe, 3, 1, 0), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp4.ne.and.orcm", A2, OpX2TaC (0xe, 3, 1, 0), {P2, P1, IMM8, R3}, PSEUDO, 0, NULL},
+ {"cmp4.ne.or.andcm", A2, OpX2TaC (0xe, 3, 1, 1), {P1, P2, IMM8, R3}, EMPTY},
+ {"cmp4.eq.and.orcm", A2, OpX2TaC (0xe, 3, 1, 1), {P2, P1, IMM8, R3}, PSEUDO, 0, NULL},
- {0}
+ {NULL, 0, 0, 0, 0, {0}, 0, 0, NULL}
};
#undef A
@@ -410,3 +414,4 @@ struct ia64_opcode ia64_opcodes_a[] =
#undef OpX2TaC
#undef OpX2aZaZbX4
#undef OpX2aZaZbX4X2b
+#undef EMPTY
diff --git a/contrib/binutils/opcodes/ia64-opc-b.c b/contrib/binutils/opcodes/ia64-opc-b.c
index 9a4a850..fc57ab6 100644
--- a/contrib/binutils/opcodes/ia64-opc-b.c
+++ b/contrib/binutils/opcodes/ia64-opc-b.c
@@ -1,5 +1,5 @@
/* ia64-opc-b.c -- IA-64 `B' opcode table.
- Copyright 1998, 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2002 Free Software Foundation, Inc.
Contributed by David Mosberger-Tang <davidm@hpl.hp.com>
This file is part of GDB, GAS, and the GNU binutils.
@@ -69,12 +69,16 @@
(bOp (a) | bX6 (b) | bIh (c) | bWhb (d)), \
(mOp | mX6 | mIh | mWhb)
+/* Used to initialise unused fields in ia64_opcode struct,
+ in order to stop gcc from complaining. */
+#define EMPTY 0,0,NULL
+
struct ia64_opcode ia64_opcodes_b[] =
{
/* B-type instruction encodings (sorted according to major opcode) */
#define BR(a,b) \
- B0, OpX6BtypePaWhaDPr (0, 0x20, 0, a, 0, b, 0), {B2}, PSEUDO
+ B0, OpX6BtypePaWhaDPr (0, 0x20, 0, a, 0, b, 0), {B2}, PSEUDO, 0, NULL
{"br.few", BR (0, 0)},
{"br", BR (0, 0)},
{"br.few.clr", BR (0, 1)},
@@ -83,23 +87,25 @@ struct ia64_opcode ia64_opcodes_b[] =
{"br.many.clr", BR (1, 1)},
#undef BR
-#define BR(a,b,c,d,e) B0, OpX6BtypePaWhaD (0, a, b, c, d, e), {B2}
+#define BR(a,b,c,d,e) B0, OpX6BtypePaWhaD (0, a, b, c, d, e), {B2}, EMPTY
+#define BRP(a,b,c,d,e) B0, OpX6BtypePaWhaD (0, a, b, c, d, e), {B2}, PSEUDO, 0, NULL
+#define BRT(a,b,c,d,e,f) B0, OpX6BtypePaWhaD (0, a, b, c, d, e), {B2}, f, 0, NULL
{"br.cond.sptk.few", BR (0x20, 0, 0, 0, 0)},
- {"br.cond.sptk", BR (0x20, 0, 0, 0, 0), PSEUDO},
+ {"br.cond.sptk", BRP (0x20, 0, 0, 0, 0)},
{"br.cond.sptk.few.clr", BR (0x20, 0, 0, 0, 1)},
- {"br.cond.sptk.clr", BR (0x20, 0, 0, 0, 1), PSEUDO},
+ {"br.cond.sptk.clr", BRP (0x20, 0, 0, 0, 1)},
{"br.cond.spnt.few", BR (0x20, 0, 0, 1, 0)},
- {"br.cond.spnt", BR (0x20, 0, 0, 1, 0), PSEUDO},
+ {"br.cond.spnt", BRP (0x20, 0, 0, 1, 0)},
{"br.cond.spnt.few.clr", BR (0x20, 0, 0, 1, 1)},
- {"br.cond.spnt.clr", BR (0x20, 0, 0, 1, 1), PSEUDO},
+ {"br.cond.spnt.clr", BRP (0x20, 0, 0, 1, 1)},
{"br.cond.dptk.few", BR (0x20, 0, 0, 2, 0)},
- {"br.cond.dptk", BR (0x20, 0, 0, 2, 0), PSEUDO},
+ {"br.cond.dptk", BRP (0x20, 0, 0, 2, 0)},
{"br.cond.dptk.few.clr", BR (0x20, 0, 0, 2, 1)},
- {"br.cond.dptk.clr", BR (0x20, 0, 0, 2, 1), PSEUDO},
+ {"br.cond.dptk.clr", BRP (0x20, 0, 0, 2, 1)},
{"br.cond.dpnt.few", BR (0x20, 0, 0, 3, 0)},
- {"br.cond.dpnt", BR (0x20, 0, 0, 3, 0), PSEUDO},
+ {"br.cond.dpnt", BRP (0x20, 0, 0, 3, 0)},
{"br.cond.dpnt.few.clr", BR (0x20, 0, 0, 3, 1)},
- {"br.cond.dpnt.clr", BR (0x20, 0, 0, 3, 1), PSEUDO},
+ {"br.cond.dpnt.clr", BRP (0x20, 0, 0, 3, 1)},
{"br.cond.sptk.many", BR (0x20, 0, 1, 0, 0)},
{"br.cond.sptk.many.clr", BR (0x20, 0, 1, 0, 1)},
{"br.cond.spnt.many", BR (0x20, 0, 1, 1, 0)},
@@ -109,21 +115,21 @@ struct ia64_opcode ia64_opcodes_b[] =
{"br.cond.dpnt.many", BR (0x20, 0, 1, 3, 0)},
{"br.cond.dpnt.many.clr", BR (0x20, 0, 1, 3, 1)},
{"br.sptk.few", BR (0x20, 0, 0, 0, 0)},
- {"br.sptk", BR (0x20, 0, 0, 0, 0), PSEUDO},
+ {"br.sptk", BRP (0x20, 0, 0, 0, 0)},
{"br.sptk.few.clr", BR (0x20, 0, 0, 0, 1)},
- {"br.sptk.clr", BR (0x20, 0, 0, 0, 1), PSEUDO},
+ {"br.sptk.clr", BRP (0x20, 0, 0, 0, 1)},
{"br.spnt.few", BR (0x20, 0, 0, 1, 0)},
- {"br.spnt", BR (0x20, 0, 0, 1, 0), PSEUDO},
+ {"br.spnt", BRP (0x20, 0, 0, 1, 0)},
{"br.spnt.few.clr", BR (0x20, 0, 0, 1, 1)},
- {"br.spnt.clr", BR (0x20, 0, 0, 1, 1), PSEUDO},
+ {"br.spnt.clr", BRP (0x20, 0, 0, 1, 1)},
{"br.dptk.few", BR (0x20, 0, 0, 2, 0)},
- {"br.dptk", BR (0x20, 0, 0, 2, 0), PSEUDO},
+ {"br.dptk", BRP (0x20, 0, 0, 2, 0)},
{"br.dptk.few.clr", BR (0x20, 0, 0, 2, 1)},
- {"br.dptk.clr", BR (0x20, 0, 0, 2, 1), PSEUDO},
+ {"br.dptk.clr", BRP (0x20, 0, 0, 2, 1)},
{"br.dpnt.few", BR (0x20, 0, 0, 3, 0)},
- {"br.dpnt", BR (0x20, 0, 0, 3, 0), PSEUDO},
+ {"br.dpnt", BRP (0x20, 0, 0, 3, 0)},
{"br.dpnt.few.clr", BR (0x20, 0, 0, 3, 1)},
- {"br.dpnt.clr", BR (0x20, 0, 0, 3, 1), PSEUDO},
+ {"br.dpnt.clr", BRP (0x20, 0, 0, 3, 1)},
{"br.sptk.many", BR (0x20, 0, 1, 0, 0)},
{"br.sptk.many.clr", BR (0x20, 0, 1, 0, 1)},
{"br.spnt.many", BR (0x20, 0, 1, 1, 0)},
@@ -133,21 +139,21 @@ struct ia64_opcode ia64_opcodes_b[] =
{"br.dpnt.many", BR (0x20, 0, 1, 3, 0)},
{"br.dpnt.many.clr", BR (0x20, 0, 1, 3, 1)},
{"br.ia.sptk.few", BR (0x20, 1, 0, 0, 0)},
- {"br.ia.sptk", BR (0x20, 1, 0, 0, 0), PSEUDO},
+ {"br.ia.sptk", BRP (0x20, 1, 0, 0, 0)},
{"br.ia.sptk.few.clr", BR (0x20, 1, 0, 0, 1)},
- {"br.ia.sptk.clr", BR (0x20, 1, 0, 0, 1), PSEUDO},
+ {"br.ia.sptk.clr", BRP (0x20, 1, 0, 0, 1)},
{"br.ia.spnt.few", BR (0x20, 1, 0, 1, 0)},
- {"br.ia.spnt", BR (0x20, 1, 0, 1, 0), PSEUDO},
+ {"br.ia.spnt", BRP (0x20, 1, 0, 1, 0)},
{"br.ia.spnt.few.clr", BR (0x20, 1, 0, 1, 1)},
- {"br.ia.spnt.clr", BR (0x20, 1, 0, 1, 1), PSEUDO},
+ {"br.ia.spnt.clr", BRP (0x20, 1, 0, 1, 1)},
{"br.ia.dptk.few", BR (0x20, 1, 0, 2, 0)},
- {"br.ia.dptk", BR (0x20, 1, 0, 2, 0), PSEUDO},
+ {"br.ia.dptk", BRP (0x20, 1, 0, 2, 0)},
{"br.ia.dptk.few.clr", BR (0x20, 1, 0, 2, 1)},
- {"br.ia.dptk.clr", BR (0x20, 1, 0, 2, 1), PSEUDO},
+ {"br.ia.dptk.clr", BRP (0x20, 1, 0, 2, 1)},
{"br.ia.dpnt.few", BR (0x20, 1, 0, 3, 0)},
- {"br.ia.dpnt", BR (0x20, 1, 0, 3, 0), PSEUDO},
+ {"br.ia.dpnt", BRP (0x20, 1, 0, 3, 0)},
{"br.ia.dpnt.few.clr", BR (0x20, 1, 0, 3, 1)},
- {"br.ia.dpnt.clr", BR (0x20, 1, 0, 3, 1), PSEUDO},
+ {"br.ia.dpnt.clr", BRP (0x20, 1, 0, 3, 1)},
{"br.ia.sptk.many", BR (0x20, 1, 1, 0, 0)},
{"br.ia.sptk.many.clr", BR (0x20, 1, 1, 0, 1)},
{"br.ia.spnt.many", BR (0x20, 1, 1, 1, 0)},
@@ -156,69 +162,71 @@ struct ia64_opcode ia64_opcodes_b[] =
{"br.ia.dptk.many.clr", BR (0x20, 1, 1, 2, 1)},
{"br.ia.dpnt.many", BR (0x20, 1, 1, 3, 0)},
{"br.ia.dpnt.many.clr", BR (0x20, 1, 1, 3, 1)},
- {"br.ret.sptk.few", BR (0x21, 4, 0, 0, 0), MOD_RRBS},
- {"br.ret.sptk", BR (0x21, 4, 0, 0, 0), PSEUDO | MOD_RRBS},
- {"br.ret.sptk.few.clr", BR (0x21, 4, 0, 0, 1), MOD_RRBS},
- {"br.ret.sptk.clr", BR (0x21, 4, 0, 0, 1), PSEUDO | MOD_RRBS},
- {"br.ret.spnt.few", BR (0x21, 4, 0, 1, 0), MOD_RRBS},
- {"br.ret.spnt", BR (0x21, 4, 0, 1, 0), PSEUDO | MOD_RRBS},
- {"br.ret.spnt.few.clr", BR (0x21, 4, 0, 1, 1), MOD_RRBS},
- {"br.ret.spnt.clr", BR (0x21, 4, 0, 1, 1), PSEUDO | MOD_RRBS},
- {"br.ret.dptk.few", BR (0x21, 4, 0, 2, 0), MOD_RRBS},
- {"br.ret.dptk", BR (0x21, 4, 0, 2, 0), PSEUDO | MOD_RRBS},
- {"br.ret.dptk.few.clr", BR (0x21, 4, 0, 2, 1), MOD_RRBS},
- {"br.ret.dptk.clr", BR (0x21, 4, 0, 2, 1), PSEUDO | MOD_RRBS},
- {"br.ret.dpnt.few", BR (0x21, 4, 0, 3, 0), MOD_RRBS},
- {"br.ret.dpnt", BR (0x21, 4, 0, 3, 0), PSEUDO | MOD_RRBS},
- {"br.ret.dpnt.few.clr", BR (0x21, 4, 0, 3, 1), MOD_RRBS},
- {"br.ret.dpnt.clr", BR (0x21, 4, 0, 3, 1), PSEUDO | MOD_RRBS},
- {"br.ret.sptk.many", BR (0x21, 4, 1, 0, 0), MOD_RRBS},
- {"br.ret.sptk.many.clr", BR (0x21, 4, 1, 0, 1), MOD_RRBS},
- {"br.ret.spnt.many", BR (0x21, 4, 1, 1, 0), MOD_RRBS},
- {"br.ret.spnt.many.clr", BR (0x21, 4, 1, 1, 1), MOD_RRBS},
- {"br.ret.dptk.many", BR (0x21, 4, 1, 2, 0), MOD_RRBS},
- {"br.ret.dptk.many.clr", BR (0x21, 4, 1, 2, 1), MOD_RRBS},
- {"br.ret.dpnt.many", BR (0x21, 4, 1, 3, 0), MOD_RRBS},
- {"br.ret.dpnt.many.clr", BR (0x21, 4, 1, 3, 1), MOD_RRBS},
+ {"br.ret.sptk.few", BRT (0x21, 4, 0, 0, 0, MOD_RRBS)},
+ {"br.ret.sptk", BRT (0x21, 4, 0, 0, 0, PSEUDO | MOD_RRBS)},
+ {"br.ret.sptk.few.clr", BRT (0x21, 4, 0, 0, 1, MOD_RRBS)},
+ {"br.ret.sptk.clr", BRT (0x21, 4, 0, 0, 1, PSEUDO | MOD_RRBS)},
+ {"br.ret.spnt.few", BRT (0x21, 4, 0, 1, 0, MOD_RRBS)},
+ {"br.ret.spnt", BRT (0x21, 4, 0, 1, 0, PSEUDO | MOD_RRBS)},
+ {"br.ret.spnt.few.clr", BRT (0x21, 4, 0, 1, 1, MOD_RRBS)},
+ {"br.ret.spnt.clr", BRT (0x21, 4, 0, 1, 1, PSEUDO | MOD_RRBS)},
+ {"br.ret.dptk.few", BRT (0x21, 4, 0, 2, 0, MOD_RRBS)},
+ {"br.ret.dptk", BRT (0x21, 4, 0, 2, 0, PSEUDO | MOD_RRBS)},
+ {"br.ret.dptk.few.clr", BRT (0x21, 4, 0, 2, 1, MOD_RRBS)},
+ {"br.ret.dptk.clr", BRT (0x21, 4, 0, 2, 1, PSEUDO | MOD_RRBS)},
+ {"br.ret.dpnt.few", BRT (0x21, 4, 0, 3, 0, MOD_RRBS)},
+ {"br.ret.dpnt", BRT (0x21, 4, 0, 3, 0, PSEUDO | MOD_RRBS)},
+ {"br.ret.dpnt.few.clr", BRT (0x21, 4, 0, 3, 1, MOD_RRBS)},
+ {"br.ret.dpnt.clr", BRT (0x21, 4, 0, 3, 1, PSEUDO | MOD_RRBS)},
+ {"br.ret.sptk.many", BRT (0x21, 4, 1, 0, 0, MOD_RRBS)},
+ {"br.ret.sptk.many.clr", BRT (0x21, 4, 1, 0, 1, MOD_RRBS)},
+ {"br.ret.spnt.many", BRT (0x21, 4, 1, 1, 0, MOD_RRBS)},
+ {"br.ret.spnt.many.clr", BRT (0x21, 4, 1, 1, 1, MOD_RRBS)},
+ {"br.ret.dptk.many", BRT (0x21, 4, 1, 2, 0, MOD_RRBS)},
+ {"br.ret.dptk.many.clr", BRT (0x21, 4, 1, 2, 1, MOD_RRBS)},
+ {"br.ret.dpnt.many", BRT (0x21, 4, 1, 3, 0, MOD_RRBS)},
+ {"br.ret.dpnt.many.clr", BRT (0x21, 4, 1, 3, 1, MOD_RRBS)},
#undef BR
+#undef BRP
+#undef BRT
- {"cover", B0, OpX6 (0, 0x02), {0, }, NO_PRED | LAST | MOD_RRBS},
- {"clrrrb", B0, OpX6 (0, 0x04), {0, }, NO_PRED | LAST | MOD_RRBS},
- {"clrrrb.pr", B0, OpX6 (0, 0x05), {0, }, NO_PRED | LAST | MOD_RRBS},
- {"rfi", B0, OpX6 (0, 0x08), {0, }, NO_PRED | LAST | PRIV | MOD_RRBS},
- {"bsw.0", B0, OpX6 (0, 0x0c), {0, }, NO_PRED | LAST | PRIV},
- {"bsw.1", B0, OpX6 (0, 0x0d), {0, }, NO_PRED | LAST | PRIV},
- {"epc", B0, OpX6 (0, 0x10), {0, }, NO_PRED},
+ {"cover", B0, OpX6 (0, 0x02), {0, }, NO_PRED | LAST | MOD_RRBS, 0, NULL},
+ {"clrrrb", B0, OpX6 (0, 0x04), {0, }, NO_PRED | LAST | MOD_RRBS, 0, NULL},
+ {"clrrrb.pr", B0, OpX6 (0, 0x05), {0, }, NO_PRED | LAST | MOD_RRBS, 0, NULL},
+ {"rfi", B0, OpX6 (0, 0x08), {0, }, NO_PRED | LAST | PRIV | MOD_RRBS, 0, NULL},
+ {"bsw.0", B0, OpX6 (0, 0x0c), {0, }, NO_PRED | LAST | PRIV, 0, NULL},
+ {"bsw.1", B0, OpX6 (0, 0x0d), {0, }, NO_PRED | LAST | PRIV, 0, NULL},
+ {"epc", B0, OpX6 (0, 0x10), {0, }, NO_PRED, 0, NULL},
- {"break.b", B0, OpX6 (0, 0x00), {IMMU21}},
+ {"break.b", B0, OpX6 (0, 0x00), {IMMU21}, EMPTY},
- {"br.call.sptk.few", B, OpPaWhcD (1, 0, 1, 0), {B1, B2}},
- {"br.call.sptk", B, OpPaWhcD (1, 0, 1, 0), {B1, B2}, PSEUDO},
- {"br.call.sptk.few.clr", B, OpPaWhcD (1, 0, 1, 1), {B1, B2}},
- {"br.call.sptk.clr", B, OpPaWhcD (1, 0, 1, 1), {B1, B2}, PSEUDO},
- {"br.call.spnt.few", B, OpPaWhcD (1, 0, 3, 0), {B1, B2}},
- {"br.call.spnt", B, OpPaWhcD (1, 0, 3, 0), {B1, B2}, PSEUDO},
- {"br.call.spnt.few.clr", B, OpPaWhcD (1, 0, 3, 1), {B1, B2}},
- {"br.call.spnt.clr", B, OpPaWhcD (1, 0, 3, 1), {B1, B2}, PSEUDO},
- {"br.call.dptk.few", B, OpPaWhcD (1, 0, 5, 0), {B1, B2}},
- {"br.call.dptk", B, OpPaWhcD (1, 0, 5, 0), {B1, B2}, PSEUDO},
- {"br.call.dptk.few.clr", B, OpPaWhcD (1, 0, 5, 1), {B1, B2}},
- {"br.call.dptk.clr", B, OpPaWhcD (1, 0, 5, 1), {B1, B2}, PSEUDO},
- {"br.call.dpnt.few", B, OpPaWhcD (1, 0, 7, 0), {B1, B2}},
- {"br.call.dpnt", B, OpPaWhcD (1, 0, 7, 0), {B1, B2}, PSEUDO},
- {"br.call.dpnt.few.clr", B, OpPaWhcD (1, 0, 7, 1), {B1, B2}},
- {"br.call.dpnt.clr", B, OpPaWhcD (1, 0, 7, 1), {B1, B2}, PSEUDO},
- {"br.call.sptk.many", B, OpPaWhcD (1, 1, 1, 0), {B1, B2}},
- {"br.call.sptk.many.clr", B, OpPaWhcD (1, 1, 1, 1), {B1, B2}},
- {"br.call.spnt.many", B, OpPaWhcD (1, 1, 3, 0), {B1, B2}},
- {"br.call.spnt.many.clr", B, OpPaWhcD (1, 1, 3, 1), {B1, B2}},
- {"br.call.dptk.many", B, OpPaWhcD (1, 1, 5, 0), {B1, B2}},
- {"br.call.dptk.many.clr", B, OpPaWhcD (1, 1, 5, 1), {B1, B2}},
- {"br.call.dpnt.many", B, OpPaWhcD (1, 1, 7, 0), {B1, B2}},
- {"br.call.dpnt.many.clr", B, OpPaWhcD (1, 1, 7, 1), {B1, B2}},
+ {"br.call.sptk.few", B, OpPaWhcD (1, 0, 1, 0), {B1, B2}, EMPTY},
+ {"br.call.sptk", B, OpPaWhcD (1, 0, 1, 0), {B1, B2}, PSEUDO, 0, NULL},
+ {"br.call.sptk.few.clr", B, OpPaWhcD (1, 0, 1, 1), {B1, B2}, EMPTY},
+ {"br.call.sptk.clr", B, OpPaWhcD (1, 0, 1, 1), {B1, B2}, PSEUDO, 0, NULL},
+ {"br.call.spnt.few", B, OpPaWhcD (1, 0, 3, 0), {B1, B2}, EMPTY},
+ {"br.call.spnt", B, OpPaWhcD (1, 0, 3, 0), {B1, B2}, PSEUDO, 0, NULL},
+ {"br.call.spnt.few.clr", B, OpPaWhcD (1, 0, 3, 1), {B1, B2}, EMPTY},
+ {"br.call.spnt.clr", B, OpPaWhcD (1, 0, 3, 1), {B1, B2}, PSEUDO, 0, NULL},
+ {"br.call.dptk.few", B, OpPaWhcD (1, 0, 5, 0), {B1, B2}, EMPTY},
+ {"br.call.dptk", B, OpPaWhcD (1, 0, 5, 0), {B1, B2}, PSEUDO, 0, NULL},
+ {"br.call.dptk.few.clr", B, OpPaWhcD (1, 0, 5, 1), {B1, B2}, EMPTY},
+ {"br.call.dptk.clr", B, OpPaWhcD (1, 0, 5, 1), {B1, B2}, PSEUDO, 0, NULL},
+ {"br.call.dpnt.few", B, OpPaWhcD (1, 0, 7, 0), {B1, B2}, EMPTY},
+ {"br.call.dpnt", B, OpPaWhcD (1, 0, 7, 0), {B1, B2}, PSEUDO, 0, NULL},
+ {"br.call.dpnt.few.clr", B, OpPaWhcD (1, 0, 7, 1), {B1, B2}, EMPTY},
+ {"br.call.dpnt.clr", B, OpPaWhcD (1, 0, 7, 1), {B1, B2}, PSEUDO, 0, NULL},
+ {"br.call.sptk.many", B, OpPaWhcD (1, 1, 1, 0), {B1, B2}, EMPTY},
+ {"br.call.sptk.many.clr", B, OpPaWhcD (1, 1, 1, 1), {B1, B2}, EMPTY},
+ {"br.call.spnt.many", B, OpPaWhcD (1, 1, 3, 0), {B1, B2}, EMPTY},
+ {"br.call.spnt.many.clr", B, OpPaWhcD (1, 1, 3, 1), {B1, B2}, EMPTY},
+ {"br.call.dptk.many", B, OpPaWhcD (1, 1, 5, 0), {B1, B2}, EMPTY},
+ {"br.call.dptk.many.clr", B, OpPaWhcD (1, 1, 5, 1), {B1, B2}, EMPTY},
+ {"br.call.dpnt.many", B, OpPaWhcD (1, 1, 7, 0), {B1, B2}, EMPTY},
+ {"br.call.dpnt.many.clr", B, OpPaWhcD (1, 1, 7, 1), {B1, B2}, EMPTY},
#define BRP(a,b,c) \
- B0, OpX6IhWhb (2, a, b, c), {B2, TAG13}, NO_PRED
+ B0, OpX6IhWhb (2, a, b, c), {B2, TAG13}, NO_PRED, 0, NULL
{"brp.sptk", BRP (0x10, 0, 0)},
{"brp.dptk", BRP (0x10, 0, 2)},
{"brp.sptk.imp", BRP (0x10, 1, 0)},
@@ -229,10 +237,11 @@ struct ia64_opcode ia64_opcodes_b[] =
{"brp.ret.dptk.imp", BRP (0x11, 1, 2)},
#undef BRP
- {"nop.b", B0, OpX6 (2, 0x00), {IMMU21}},
+ {"nop.b", B0, OpX6 (2, 0x00), {IMMU21}, EMPTY},
+ {"hint.b", B0, OpX6 (2, 0x01), {IMMU21}, EMPTY},
#define BR(a,b) \
- B0, OpBtypePaWhaDPr (4, 0, a, 0, b, 0), {TGT25c}, PSEUDO
+ B0, OpBtypePaWhaDPr (4, 0, a, 0, b, 0), {TGT25c}, PSEUDO, 0, NULL
{"br.few", BR (0, 0)},
{"br", BR (0, 0)},
{"br.few.clr", BR (0, 1)},
@@ -242,23 +251,25 @@ struct ia64_opcode ia64_opcodes_b[] =
#undef BR
#define BR(a,b,c) \
- B0, OpBtypePaWhaD (4, 0, a, b, c), {TGT25c}
+ B0, OpBtypePaWhaD (4, 0, a, b, c), {TGT25c}, EMPTY
+#define BRP(a,b,c) \
+ B0, OpBtypePaWhaD (4, 0, a, b, c), {TGT25c}, PSEUDO, 0, NULL
{"br.cond.sptk.few", BR (0, 0, 0)},
- {"br.cond.sptk", BR (0, 0, 0), PSEUDO},
+ {"br.cond.sptk", BRP (0, 0, 0)},
{"br.cond.sptk.few.clr", BR (0, 0, 1)},
- {"br.cond.sptk.clr", BR (0, 0, 1), PSEUDO},
+ {"br.cond.sptk.clr", BRP (0, 0, 1)},
{"br.cond.spnt.few", BR (0, 1, 0)},
- {"br.cond.spnt", BR (0, 1, 0), PSEUDO},
+ {"br.cond.spnt", BRP (0, 1, 0)},
{"br.cond.spnt.few.clr", BR (0, 1, 1)},
- {"br.cond.spnt.clr", BR (0, 1, 1), PSEUDO},
+ {"br.cond.spnt.clr", BRP (0, 1, 1)},
{"br.cond.dptk.few", BR (0, 2, 0)},
- {"br.cond.dptk", BR (0, 2, 0), PSEUDO},
+ {"br.cond.dptk", BRP (0, 2, 0)},
{"br.cond.dptk.few.clr", BR (0, 2, 1)},
- {"br.cond.dptk.clr", BR (0, 2, 1), PSEUDO},
+ {"br.cond.dptk.clr", BRP (0, 2, 1)},
{"br.cond.dpnt.few", BR (0, 3, 0)},
- {"br.cond.dpnt", BR (0, 3, 0), PSEUDO},
+ {"br.cond.dpnt", BRP (0, 3, 0)},
{"br.cond.dpnt.few.clr", BR (0, 3, 1)},
- {"br.cond.dpnt.clr", BR (0, 3, 1), PSEUDO},
+ {"br.cond.dpnt.clr", BRP (0, 3, 1)},
{"br.cond.sptk.many", BR (1, 0, 0)},
{"br.cond.sptk.many.clr", BR (1, 0, 1)},
{"br.cond.spnt.many", BR (1, 1, 0)},
@@ -268,21 +279,21 @@ struct ia64_opcode ia64_opcodes_b[] =
{"br.cond.dpnt.many", BR (1, 3, 0)},
{"br.cond.dpnt.many.clr", BR (1, 3, 1)},
{"br.sptk.few", BR (0, 0, 0)},
- {"br.sptk", BR (0, 0, 0), PSEUDO},
+ {"br.sptk", BRP (0, 0, 0)},
{"br.sptk.few.clr", BR (0, 0, 1)},
- {"br.sptk.clr", BR (0, 0, 1), PSEUDO},
+ {"br.sptk.clr", BRP (0, 0, 1)},
{"br.spnt.few", BR (0, 1, 0)},
- {"br.spnt", BR (0, 1, 0), PSEUDO},
+ {"br.spnt", BRP (0, 1, 0)},
{"br.spnt.few.clr", BR (0, 1, 1)},
- {"br.spnt.clr", BR (0, 1, 1), PSEUDO},
+ {"br.spnt.clr", BRP (0, 1, 1)},
{"br.dptk.few", BR (0, 2, 0)},
- {"br.dptk", BR (0, 2, 0), PSEUDO},
+ {"br.dptk", BRP (0, 2, 0)},
{"br.dptk.few.clr", BR (0, 2, 1)},
- {"br.dptk.clr", BR (0, 2, 1), PSEUDO},
+ {"br.dptk.clr", BRP (0, 2, 1)},
{"br.dpnt.few", BR (0, 3, 0)},
- {"br.dpnt", BR (0, 3, 0), PSEUDO},
+ {"br.dpnt", BRP (0, 3, 0)},
{"br.dpnt.few.clr", BR (0, 3, 1)},
- {"br.dpnt.clr", BR (0, 3, 1), PSEUDO},
+ {"br.dpnt.clr", BRP (0, 3, 1)},
{"br.sptk.many", BR (1, 0, 0)},
{"br.sptk.many.clr", BR (1, 0, 1)},
{"br.spnt.many", BR (1, 1, 0)},
@@ -292,77 +303,80 @@ struct ia64_opcode ia64_opcodes_b[] =
{"br.dpnt.many", BR (1, 3, 0)},
{"br.dpnt.many.clr", BR (1, 3, 1)},
#undef BR
+#undef BRP
-#define BR(a,b,c,d) \
- B0, OpBtypePaWhaD (4, a, b, c, d), {TGT25c}, SLOT2
- {"br.wexit.sptk.few", BR (2, 0, 0, 0) | MOD_RRBS},
- {"br.wexit.sptk", BR (2, 0, 0, 0) | PSEUDO | MOD_RRBS},
- {"br.wexit.sptk.few.clr", BR (2, 0, 0, 1) | MOD_RRBS},
- {"br.wexit.sptk.clr", BR (2, 0, 0, 1) | PSEUDO | MOD_RRBS},
- {"br.wexit.spnt.few", BR (2, 0, 1, 0) | MOD_RRBS},
- {"br.wexit.spnt", BR (2, 0, 1, 0) | PSEUDO | MOD_RRBS},
- {"br.wexit.spnt.few.clr", BR (2, 0, 1, 1) | MOD_RRBS},
- {"br.wexit.spnt.clr", BR (2, 0, 1, 1) | PSEUDO | MOD_RRBS},
- {"br.wexit.dptk.few", BR (2, 0, 2, 0) | MOD_RRBS},
- {"br.wexit.dptk", BR (2, 0, 2, 0) | PSEUDO | MOD_RRBS},
- {"br.wexit.dptk.few.clr", BR (2, 0, 2, 1) | MOD_RRBS},
- {"br.wexit.dptk.clr", BR (2, 0, 2, 1) | PSEUDO | MOD_RRBS},
- {"br.wexit.dpnt.few", BR (2, 0, 3, 0) | MOD_RRBS},
- {"br.wexit.dpnt", BR (2, 0, 3, 0) | PSEUDO | MOD_RRBS},
- {"br.wexit.dpnt.few.clr", BR (2, 0, 3, 1) | MOD_RRBS},
- {"br.wexit.dpnt.clr", BR (2, 0, 3, 1) | PSEUDO | MOD_RRBS},
- {"br.wexit.sptk.many", BR (2, 1, 0, 0) | MOD_RRBS},
- {"br.wexit.sptk.many.clr", BR (2, 1, 0, 1) | MOD_RRBS},
- {"br.wexit.spnt.many", BR (2, 1, 1, 0) | MOD_RRBS},
- {"br.wexit.spnt.many.clr", BR (2, 1, 1, 1) | MOD_RRBS},
- {"br.wexit.dptk.many", BR (2, 1, 2, 0) | MOD_RRBS},
- {"br.wexit.dptk.many.clr", BR (2, 1, 2, 1) | MOD_RRBS},
- {"br.wexit.dpnt.many", BR (2, 1, 3, 0) | MOD_RRBS},
- {"br.wexit.dpnt.many.clr", BR (2, 1, 3, 1) | MOD_RRBS},
- {"br.wtop.sptk.few", BR (3, 0, 0, 0) | MOD_RRBS},
- {"br.wtop.sptk", BR (3, 0, 0, 0) | PSEUDO | MOD_RRBS},
- {"br.wtop.sptk.few.clr", BR (3, 0, 0, 1) | MOD_RRBS},
- {"br.wtop.sptk.clr", BR (3, 0, 0, 1) | PSEUDO | MOD_RRBS},
- {"br.wtop.spnt.few", BR (3, 0, 1, 0) | MOD_RRBS},
- {"br.wtop.spnt", BR (3, 0, 1, 0) | PSEUDO | MOD_RRBS},
- {"br.wtop.spnt.few.clr", BR (3, 0, 1, 1) | MOD_RRBS},
- {"br.wtop.spnt.clr", BR (3, 0, 1, 1) | PSEUDO | MOD_RRBS},
- {"br.wtop.dptk.few", BR (3, 0, 2, 0) | MOD_RRBS},
- {"br.wtop.dptk", BR (3, 0, 2, 0) | PSEUDO | MOD_RRBS},
- {"br.wtop.dptk.few.clr", BR (3, 0, 2, 1) | MOD_RRBS},
- {"br.wtop.dptk.clr", BR (3, 0, 2, 1) | PSEUDO | MOD_RRBS},
- {"br.wtop.dpnt.few", BR (3, 0, 3, 0) | MOD_RRBS},
- {"br.wtop.dpnt", BR (3, 0, 3, 0) | PSEUDO | MOD_RRBS},
- {"br.wtop.dpnt.few.clr", BR (3, 0, 3, 1) | MOD_RRBS},
- {"br.wtop.dpnt.clr", BR (3, 0, 3, 1) | PSEUDO | MOD_RRBS},
- {"br.wtop.sptk.many", BR (3, 1, 0, 0) | MOD_RRBS},
- {"br.wtop.sptk.many.clr", BR (3, 1, 0, 1) | MOD_RRBS},
- {"br.wtop.spnt.many", BR (3, 1, 1, 0) | MOD_RRBS},
- {"br.wtop.spnt.many.clr", BR (3, 1, 1, 1) | MOD_RRBS},
- {"br.wtop.dptk.many", BR (3, 1, 2, 0) | MOD_RRBS},
- {"br.wtop.dptk.many.clr", BR (3, 1, 2, 1) | MOD_RRBS},
- {"br.wtop.dpnt.many", BR (3, 1, 3, 0) | MOD_RRBS},
- {"br.wtop.dpnt.many.clr", BR (3, 1, 3, 1) | MOD_RRBS},
+#define BR(a,b,c,d, e) \
+ B0, OpBtypePaWhaD (4, a, b, c, d), {TGT25c}, SLOT2 | e, 0, NULL
+ {"br.wexit.sptk.few", BR (2, 0, 0, 0, MOD_RRBS)},
+ {"br.wexit.sptk", BR (2, 0, 0, 0, PSEUDO | MOD_RRBS)},
+ {"br.wexit.sptk.few.clr", BR (2, 0, 0, 1, MOD_RRBS)},
+ {"br.wexit.sptk.clr", BR (2, 0, 0, 1, PSEUDO | MOD_RRBS)},
+ {"br.wexit.spnt.few", BR (2, 0, 1, 0, MOD_RRBS)},
+ {"br.wexit.spnt", BR (2, 0, 1, 0, PSEUDO | MOD_RRBS)},
+ {"br.wexit.spnt.few.clr", BR (2, 0, 1, 1, MOD_RRBS)},
+ {"br.wexit.spnt.clr", BR (2, 0, 1, 1, PSEUDO | MOD_RRBS)},
+ {"br.wexit.dptk.few", BR (2, 0, 2, 0, MOD_RRBS)},
+ {"br.wexit.dptk", BR (2, 0, 2, 0, PSEUDO | MOD_RRBS)},
+ {"br.wexit.dptk.few.clr", BR (2, 0, 2, 1, MOD_RRBS)},
+ {"br.wexit.dptk.clr", BR (2, 0, 2, 1, PSEUDO | MOD_RRBS)},
+ {"br.wexit.dpnt.few", BR (2, 0, 3, 0, MOD_RRBS)},
+ {"br.wexit.dpnt", BR (2, 0, 3, 0, PSEUDO | MOD_RRBS)},
+ {"br.wexit.dpnt.few.clr", BR (2, 0, 3, 1, MOD_RRBS)},
+ {"br.wexit.dpnt.clr", BR (2, 0, 3, 1, PSEUDO | MOD_RRBS)},
+ {"br.wexit.sptk.many", BR (2, 1, 0, 0, MOD_RRBS)},
+ {"br.wexit.sptk.many.clr", BR (2, 1, 0, 1, MOD_RRBS)},
+ {"br.wexit.spnt.many", BR (2, 1, 1, 0, MOD_RRBS)},
+ {"br.wexit.spnt.many.clr", BR (2, 1, 1, 1, MOD_RRBS)},
+ {"br.wexit.dptk.many", BR (2, 1, 2, 0, MOD_RRBS)},
+ {"br.wexit.dptk.many.clr", BR (2, 1, 2, 1, MOD_RRBS)},
+ {"br.wexit.dpnt.many", BR (2, 1, 3, 0, MOD_RRBS)},
+ {"br.wexit.dpnt.many.clr", BR (2, 1, 3, 1, MOD_RRBS)},
+ {"br.wtop.sptk.few", BR (3, 0, 0, 0, MOD_RRBS)},
+ {"br.wtop.sptk", BR (3, 0, 0, 0, PSEUDO | MOD_RRBS)},
+ {"br.wtop.sptk.few.clr", BR (3, 0, 0, 1, MOD_RRBS)},
+ {"br.wtop.sptk.clr", BR (3, 0, 0, 1, PSEUDO | MOD_RRBS)},
+ {"br.wtop.spnt.few", BR (3, 0, 1, 0, MOD_RRBS)},
+ {"br.wtop.spnt", BR (3, 0, 1, 0, PSEUDO | MOD_RRBS)},
+ {"br.wtop.spnt.few.clr", BR (3, 0, 1, 1, MOD_RRBS)},
+ {"br.wtop.spnt.clr", BR (3, 0, 1, 1, PSEUDO | MOD_RRBS)},
+ {"br.wtop.dptk.few", BR (3, 0, 2, 0, MOD_RRBS)},
+ {"br.wtop.dptk", BR (3, 0, 2, 0, PSEUDO | MOD_RRBS)},
+ {"br.wtop.dptk.few.clr", BR (3, 0, 2, 1, MOD_RRBS)},
+ {"br.wtop.dptk.clr", BR (3, 0, 2, 1, PSEUDO | MOD_RRBS)},
+ {"br.wtop.dpnt.few", BR (3, 0, 3, 0, MOD_RRBS)},
+ {"br.wtop.dpnt", BR (3, 0, 3, 0, PSEUDO | MOD_RRBS)},
+ {"br.wtop.dpnt.few.clr", BR (3, 0, 3, 1, MOD_RRBS)},
+ {"br.wtop.dpnt.clr", BR (3, 0, 3, 1, PSEUDO | MOD_RRBS)},
+ {"br.wtop.sptk.many", BR (3, 1, 0, 0, MOD_RRBS)},
+ {"br.wtop.sptk.many.clr", BR (3, 1, 0, 1, MOD_RRBS)},
+ {"br.wtop.spnt.many", BR (3, 1, 1, 0, MOD_RRBS)},
+ {"br.wtop.spnt.many.clr", BR (3, 1, 1, 1, MOD_RRBS)},
+ {"br.wtop.dptk.many", BR (3, 1, 2, 0, MOD_RRBS)},
+ {"br.wtop.dptk.many.clr", BR (3, 1, 2, 1, MOD_RRBS)},
+ {"br.wtop.dpnt.many", BR (3, 1, 3, 0, MOD_RRBS)},
+ {"br.wtop.dpnt.many.clr", BR (3, 1, 3, 1, MOD_RRBS)},
#undef BR
#define BR(a,b,c,d) \
- B0, OpBtypePaWhaD (4, a, b, c, d), {TGT25c}, SLOT2 | NO_PRED
+ B0, OpBtypePaWhaD (4, a, b, c, d), {TGT25c}, SLOT2 | NO_PRED, 0, NULL
+#define BRT(a,b,c,d,e) \
+ B0, OpBtypePaWhaD (4, a, b, c, d), {TGT25c}, SLOT2 | NO_PRED | e, 0, NULL
{"br.cloop.sptk.few", BR (5, 0, 0, 0)},
- {"br.cloop.sptk", BR (5, 0, 0, 0) | PSEUDO},
+ {"br.cloop.sptk", BRT (5, 0, 0, 0, PSEUDO)},
{"br.cloop.sptk.few.clr", BR (5, 0, 0, 1)},
- {"br.cloop.sptk.clr", BR (5, 0, 0, 1) | PSEUDO},
+ {"br.cloop.sptk.clr", BRT (5, 0, 0, 1, PSEUDO)},
{"br.cloop.spnt.few", BR (5, 0, 1, 0)},
- {"br.cloop.spnt", BR (5, 0, 1, 0) | PSEUDO},
+ {"br.cloop.spnt", BRT (5, 0, 1, 0, PSEUDO)},
{"br.cloop.spnt.few.clr", BR (5, 0, 1, 1)},
- {"br.cloop.spnt.clr", BR (5, 0, 1, 1) | PSEUDO},
+ {"br.cloop.spnt.clr", BRT (5, 0, 1, 1, PSEUDO)},
{"br.cloop.dptk.few", BR (5, 0, 2, 0)},
- {"br.cloop.dptk", BR (5, 0, 2, 0) | PSEUDO},
+ {"br.cloop.dptk", BRT (5, 0, 2, 0, PSEUDO)},
{"br.cloop.dptk.few.clr", BR (5, 0, 2, 1)},
- {"br.cloop.dptk.clr", BR (5, 0, 2, 1) | PSEUDO},
+ {"br.cloop.dptk.clr", BRT (5, 0, 2, 1, PSEUDO)},
{"br.cloop.dpnt.few", BR (5, 0, 3, 0)},
- {"br.cloop.dpnt", BR (5, 0, 3, 0) | PSEUDO},
+ {"br.cloop.dpnt", BRT (5, 0, 3, 0, PSEUDO)},
{"br.cloop.dpnt.few.clr", BR (5, 0, 3, 1)},
- {"br.cloop.dpnt.clr", BR (5, 0, 3, 1) | PSEUDO},
+ {"br.cloop.dpnt.clr", BRT (5, 0, 3, 1, PSEUDO)},
{"br.cloop.sptk.many", BR (5, 1, 0, 0)},
{"br.cloop.sptk.many.clr", BR (5, 1, 0, 1)},
{"br.cloop.spnt.many", BR (5, 1, 1, 0)},
@@ -371,87 +385,85 @@ struct ia64_opcode ia64_opcodes_b[] =
{"br.cloop.dptk.many.clr", BR (5, 1, 2, 1)},
{"br.cloop.dpnt.many", BR (5, 1, 3, 0)},
{"br.cloop.dpnt.many.clr", BR (5, 1, 3, 1)},
- {"br.cexit.sptk.few", BR (6, 0, 0, 0) | MOD_RRBS},
- {"br.cexit.sptk", BR (6, 0, 0, 0) | PSEUDO | MOD_RRBS},
- {"br.cexit.sptk.few.clr", BR (6, 0, 0, 1) | MOD_RRBS},
- {"br.cexit.sptk.clr", BR (6, 0, 0, 1) | PSEUDO | MOD_RRBS},
- {"br.cexit.spnt.few", BR (6, 0, 1, 0) | MOD_RRBS},
- {"br.cexit.spnt", BR (6, 0, 1, 0) | PSEUDO | MOD_RRBS},
- {"br.cexit.spnt.few.clr", BR (6, 0, 1, 1) | MOD_RRBS},
- {"br.cexit.spnt.clr", BR (6, 0, 1, 1) | PSEUDO | MOD_RRBS},
- {"br.cexit.dptk.few", BR (6, 0, 2, 0) | MOD_RRBS},
- {"br.cexit.dptk", BR (6, 0, 2, 0) | PSEUDO | MOD_RRBS},
- {"br.cexit.dptk.few.clr", BR (6, 0, 2, 1) | MOD_RRBS},
- {"br.cexit.dptk.clr", BR (6, 0, 2, 1) | PSEUDO | MOD_RRBS},
- {"br.cexit.dpnt.few", BR (6, 0, 3, 0) | MOD_RRBS},
- {"br.cexit.dpnt", BR (6, 0, 3, 0) | PSEUDO | MOD_RRBS},
- {"br.cexit.dpnt.few.clr", BR (6, 0, 3, 1) | MOD_RRBS},
- {"br.cexit.dpnt.clr", BR (6, 0, 3, 1) | PSEUDO | MOD_RRBS},
- {"br.cexit.sptk.many", BR (6, 1, 0, 0) | MOD_RRBS},
- {"br.cexit.sptk.many.clr", BR (6, 1, 0, 1) | MOD_RRBS},
- {"br.cexit.spnt.many", BR (6, 1, 1, 0) | MOD_RRBS},
- {"br.cexit.spnt.many.clr", BR (6, 1, 1, 1) | MOD_RRBS},
- {"br.cexit.dptk.many", BR (6, 1, 2, 0) | MOD_RRBS},
- {"br.cexit.dptk.many.clr", BR (6, 1, 2, 1) | MOD_RRBS},
- {"br.cexit.dpnt.many", BR (6, 1, 3, 0) | MOD_RRBS},
- {"br.cexit.dpnt.many.clr", BR (6, 1, 3, 1) | MOD_RRBS},
- {"br.ctop.sptk.few", BR (7, 0, 0, 0) | MOD_RRBS},
- {"br.ctop.sptk", BR (7, 0, 0, 0) | PSEUDO | MOD_RRBS},
- {"br.ctop.sptk.few.clr", BR (7, 0, 0, 1) | MOD_RRBS},
- {"br.ctop.sptk.clr", BR (7, 0, 0, 1) | PSEUDO | MOD_RRBS},
- {"br.ctop.spnt.few", BR (7, 0, 1, 0) | MOD_RRBS},
- {"br.ctop.spnt", BR (7, 0, 1, 0) | PSEUDO | MOD_RRBS},
- {"br.ctop.spnt.few.clr", BR (7, 0, 1, 1) | MOD_RRBS},
- {"br.ctop.spnt.clr", BR (7, 0, 1, 1) | PSEUDO | MOD_RRBS},
- {"br.ctop.dptk.few", BR (7, 0, 2, 0) | MOD_RRBS},
- {"br.ctop.dptk", BR (7, 0, 2, 0) | PSEUDO | MOD_RRBS},
- {"br.ctop.dptk.few.clr", BR (7, 0, 2, 1) | MOD_RRBS},
- {"br.ctop.dptk.clr", BR (7, 0, 2, 1) | PSEUDO | MOD_RRBS},
- {"br.ctop.dpnt.few", BR (7, 0, 3, 0) | MOD_RRBS},
- {"br.ctop.dpnt", BR (7, 0, 3, 0) | PSEUDO | MOD_RRBS},
- {"br.ctop.dpnt.few.clr", BR (7, 0, 3, 1) | MOD_RRBS},
- {"br.ctop.dpnt.clr", BR (7, 0, 3, 1) | PSEUDO | MOD_RRBS},
- {"br.ctop.sptk.many", BR (7, 1, 0, 0) | MOD_RRBS},
- {"br.ctop.sptk.many.clr", BR (7, 1, 0, 1) | MOD_RRBS},
- {"br.ctop.spnt.many", BR (7, 1, 1, 0) | MOD_RRBS},
- {"br.ctop.spnt.many.clr", BR (7, 1, 1, 1) | MOD_RRBS},
- {"br.ctop.dptk.many", BR (7, 1, 2, 0) | MOD_RRBS},
- {"br.ctop.dptk.many.clr", BR (7, 1, 2, 1) | MOD_RRBS},
- {"br.ctop.dpnt.many", BR (7, 1, 3, 0) | MOD_RRBS},
- {"br.ctop.dpnt.many.clr", BR (7, 1, 3, 1) | MOD_RRBS},
-
-#undef BR
-#define BR(a,b,c,d) \
- B0, OpBtypePaWhaD (4, a, b, c, d), {TGT25c}, SLOT2
- {"br.call.sptk.few", B, OpPaWhaD (5, 0, 0, 0), {B1, TGT25c}},
- {"br.call.sptk", B, OpPaWhaD (5, 0, 0, 0), {B1, TGT25c}, PSEUDO},
- {"br.call.sptk.few.clr", B, OpPaWhaD (5, 0, 0, 1), {B1, TGT25c}},
- {"br.call.sptk.clr", B, OpPaWhaD (5, 0, 0, 1), {B1, TGT25c}, PSEUDO},
- {"br.call.spnt.few", B, OpPaWhaD (5, 0, 1, 0), {B1, TGT25c}},
- {"br.call.spnt", B, OpPaWhaD (5, 0, 1, 0), {B1, TGT25c}, PSEUDO},
- {"br.call.spnt.few.clr", B, OpPaWhaD (5, 0, 1, 1), {B1, TGT25c}},
- {"br.call.spnt.clr", B, OpPaWhaD (5, 0, 1, 1), {B1, TGT25c}, PSEUDO},
- {"br.call.dptk.few", B, OpPaWhaD (5, 0, 2, 0), {B1, TGT25c}},
- {"br.call.dptk", B, OpPaWhaD (5, 0, 2, 0), {B1, TGT25c}, PSEUDO},
- {"br.call.dptk.few.clr", B, OpPaWhaD (5, 0, 2, 1), {B1, TGT25c}},
- {"br.call.dptk.clr", B, OpPaWhaD (5, 0, 2, 1), {B1, TGT25c}, PSEUDO},
- {"br.call.dpnt.few", B, OpPaWhaD (5, 0, 3, 0), {B1, TGT25c}},
- {"br.call.dpnt", B, OpPaWhaD (5, 0, 3, 0), {B1, TGT25c}, PSEUDO},
- {"br.call.dpnt.few.clr", B, OpPaWhaD (5, 0, 3, 1), {B1, TGT25c}},
- {"br.call.dpnt.clr", B, OpPaWhaD (5, 0, 3, 1), {B1, TGT25c}, PSEUDO},
- {"br.call.sptk.many", B, OpPaWhaD (5, 1, 0, 0), {B1, TGT25c}},
- {"br.call.sptk.many.clr", B, OpPaWhaD (5, 1, 0, 1), {B1, TGT25c}},
- {"br.call.spnt.many", B, OpPaWhaD (5, 1, 1, 0), {B1, TGT25c}},
- {"br.call.spnt.many.clr", B, OpPaWhaD (5, 1, 1, 1), {B1, TGT25c}},
- {"br.call.dptk.many", B, OpPaWhaD (5, 1, 2, 0), {B1, TGT25c}},
- {"br.call.dptk.many.clr", B, OpPaWhaD (5, 1, 2, 1), {B1, TGT25c}},
- {"br.call.dpnt.many", B, OpPaWhaD (5, 1, 3, 0), {B1, TGT25c}},
- {"br.call.dpnt.many.clr", B, OpPaWhaD (5, 1, 3, 1), {B1, TGT25c}},
+ {"br.cexit.sptk.few", BRT (6, 0, 0, 0, MOD_RRBS)},
+ {"br.cexit.sptk", BRT (6, 0, 0, 0, PSEUDO | MOD_RRBS)},
+ {"br.cexit.sptk.few.clr", BRT (6, 0, 0, 1, MOD_RRBS)},
+ {"br.cexit.sptk.clr", BRT (6, 0, 0, 1, PSEUDO | MOD_RRBS)},
+ {"br.cexit.spnt.few", BRT (6, 0, 1, 0, MOD_RRBS)},
+ {"br.cexit.spnt", BRT (6, 0, 1, 0, PSEUDO | MOD_RRBS)},
+ {"br.cexit.spnt.few.clr", BRT (6, 0, 1, 1, MOD_RRBS)},
+ {"br.cexit.spnt.clr", BRT (6, 0, 1, 1, PSEUDO | MOD_RRBS)},
+ {"br.cexit.dptk.few", BRT (6, 0, 2, 0, MOD_RRBS)},
+ {"br.cexit.dptk", BRT (6, 0, 2, 0, PSEUDO | MOD_RRBS)},
+ {"br.cexit.dptk.few.clr", BRT (6, 0, 2, 1, MOD_RRBS)},
+ {"br.cexit.dptk.clr", BRT (6, 0, 2, 1, PSEUDO | MOD_RRBS)},
+ {"br.cexit.dpnt.few", BRT (6, 0, 3, 0, MOD_RRBS)},
+ {"br.cexit.dpnt", BRT (6, 0, 3, 0, PSEUDO | MOD_RRBS)},
+ {"br.cexit.dpnt.few.clr", BRT (6, 0, 3, 1, MOD_RRBS)},
+ {"br.cexit.dpnt.clr", BRT (6, 0, 3, 1, PSEUDO | MOD_RRBS)},
+ {"br.cexit.sptk.many", BRT (6, 1, 0, 0, MOD_RRBS)},
+ {"br.cexit.sptk.many.clr", BRT (6, 1, 0, 1, MOD_RRBS)},
+ {"br.cexit.spnt.many", BRT (6, 1, 1, 0, MOD_RRBS)},
+ {"br.cexit.spnt.many.clr", BRT (6, 1, 1, 1, MOD_RRBS)},
+ {"br.cexit.dptk.many", BRT (6, 1, 2, 0, MOD_RRBS)},
+ {"br.cexit.dptk.many.clr", BRT (6, 1, 2, 1, MOD_RRBS)},
+ {"br.cexit.dpnt.many", BRT (6, 1, 3, 0, MOD_RRBS)},
+ {"br.cexit.dpnt.many.clr", BRT (6, 1, 3, 1, MOD_RRBS)},
+ {"br.ctop.sptk.few", BRT (7, 0, 0, 0, MOD_RRBS)},
+ {"br.ctop.sptk", BRT (7, 0, 0, 0, PSEUDO | MOD_RRBS)},
+ {"br.ctop.sptk.few.clr", BRT (7, 0, 0, 1, MOD_RRBS)},
+ {"br.ctop.sptk.clr", BRT (7, 0, 0, 1, PSEUDO | MOD_RRBS)},
+ {"br.ctop.spnt.few", BRT (7, 0, 1, 0, MOD_RRBS)},
+ {"br.ctop.spnt", BRT (7, 0, 1, 0, PSEUDO | MOD_RRBS)},
+ {"br.ctop.spnt.few.clr", BRT (7, 0, 1, 1, MOD_RRBS)},
+ {"br.ctop.spnt.clr", BRT (7, 0, 1, 1, PSEUDO | MOD_RRBS)},
+ {"br.ctop.dptk.few", BRT (7, 0, 2, 0, MOD_RRBS)},
+ {"br.ctop.dptk", BRT (7, 0, 2, 0, PSEUDO | MOD_RRBS)},
+ {"br.ctop.dptk.few.clr", BRT (7, 0, 2, 1, MOD_RRBS)},
+ {"br.ctop.dptk.clr", BRT (7, 0, 2, 1, PSEUDO | MOD_RRBS)},
+ {"br.ctop.dpnt.few", BRT (7, 0, 3, 0, MOD_RRBS)},
+ {"br.ctop.dpnt", BRT (7, 0, 3, 0, PSEUDO | MOD_RRBS)},
+ {"br.ctop.dpnt.few.clr", BRT (7, 0, 3, 1, MOD_RRBS)},
+ {"br.ctop.dpnt.clr", BRT (7, 0, 3, 1, PSEUDO | MOD_RRBS)},
+ {"br.ctop.sptk.many", BRT (7, 1, 0, 0, MOD_RRBS)},
+ {"br.ctop.sptk.many.clr", BRT (7, 1, 0, 1, MOD_RRBS)},
+ {"br.ctop.spnt.many", BRT (7, 1, 1, 0, MOD_RRBS)},
+ {"br.ctop.spnt.many.clr", BRT (7, 1, 1, 1, MOD_RRBS)},
+ {"br.ctop.dptk.many", BRT (7, 1, 2, 0, MOD_RRBS)},
+ {"br.ctop.dptk.many.clr", BRT (7, 1, 2, 1, MOD_RRBS)},
+ {"br.ctop.dpnt.many", BRT (7, 1, 3, 0, MOD_RRBS)},
+ {"br.ctop.dpnt.many.clr", BRT (7, 1, 3, 1, MOD_RRBS)},
#undef BR
+#undef BRT
+
+ {"br.call.sptk.few", B, OpPaWhaD (5, 0, 0, 0), {B1, TGT25c}, EMPTY},
+ {"br.call.sptk", B, OpPaWhaD (5, 0, 0, 0), {B1, TGT25c}, PSEUDO, 0, NULL},
+ {"br.call.sptk.few.clr", B, OpPaWhaD (5, 0, 0, 1), {B1, TGT25c}, EMPTY},
+ {"br.call.sptk.clr", B, OpPaWhaD (5, 0, 0, 1), {B1, TGT25c}, PSEUDO, 0, NULL},
+ {"br.call.spnt.few", B, OpPaWhaD (5, 0, 1, 0), {B1, TGT25c}, EMPTY},
+ {"br.call.spnt", B, OpPaWhaD (5, 0, 1, 0), {B1, TGT25c}, PSEUDO, 0, NULL},
+ {"br.call.spnt.few.clr", B, OpPaWhaD (5, 0, 1, 1), {B1, TGT25c}, EMPTY},
+ {"br.call.spnt.clr", B, OpPaWhaD (5, 0, 1, 1), {B1, TGT25c}, PSEUDO, 0, NULL},
+ {"br.call.dptk.few", B, OpPaWhaD (5, 0, 2, 0), {B1, TGT25c}, EMPTY},
+ {"br.call.dptk", B, OpPaWhaD (5, 0, 2, 0), {B1, TGT25c}, PSEUDO, 0, NULL},
+ {"br.call.dptk.few.clr", B, OpPaWhaD (5, 0, 2, 1), {B1, TGT25c}, EMPTY},
+ {"br.call.dptk.clr", B, OpPaWhaD (5, 0, 2, 1), {B1, TGT25c}, PSEUDO, 0, NULL},
+ {"br.call.dpnt.few", B, OpPaWhaD (5, 0, 3, 0), {B1, TGT25c}, EMPTY},
+ {"br.call.dpnt", B, OpPaWhaD (5, 0, 3, 0), {B1, TGT25c}, PSEUDO, 0, NULL},
+ {"br.call.dpnt.few.clr", B, OpPaWhaD (5, 0, 3, 1), {B1, TGT25c}, EMPTY},
+ {"br.call.dpnt.clr", B, OpPaWhaD (5, 0, 3, 1), {B1, TGT25c}, PSEUDO, 0, NULL},
+ {"br.call.sptk.many", B, OpPaWhaD (5, 1, 0, 0), {B1, TGT25c}, EMPTY},
+ {"br.call.sptk.many.clr", B, OpPaWhaD (5, 1, 0, 1), {B1, TGT25c}, EMPTY},
+ {"br.call.spnt.many", B, OpPaWhaD (5, 1, 1, 0), {B1, TGT25c}, EMPTY},
+ {"br.call.spnt.many.clr", B, OpPaWhaD (5, 1, 1, 1), {B1, TGT25c}, EMPTY},
+ {"br.call.dptk.many", B, OpPaWhaD (5, 1, 2, 0), {B1, TGT25c}, EMPTY},
+ {"br.call.dptk.many.clr", B, OpPaWhaD (5, 1, 2, 1), {B1, TGT25c}, EMPTY},
+ {"br.call.dpnt.many", B, OpPaWhaD (5, 1, 3, 0), {B1, TGT25c}, EMPTY},
+ {"br.call.dpnt.many.clr", B, OpPaWhaD (5, 1, 3, 1), {B1, TGT25c}, EMPTY},
- /* branch predict */
+ /* Branch predict. */
#define BRP(a,b) \
- B0, OpIhWhb (7, a, b), {TGT25c, TAG13}, NO_PRED
+ B0, OpIhWhb (7, a, b), {TGT25c, TAG13}, NO_PRED, 0, NULL
{"brp.sptk", BRP (0, 0)},
{"brp.loop", BRP (0, 1)},
{"brp.dptk", BRP (0, 2)},
@@ -462,7 +474,7 @@ struct ia64_opcode ia64_opcodes_b[] =
{"brp.exit.imp", BRP (1, 3)},
#undef BRP
- {0}
+ {NULL, 0, 0, 0, 0, {0}, 0, 0, NULL}
};
#undef B0
@@ -494,3 +506,4 @@ struct ia64_opcode ia64_opcodes_b[] =
#undef OpX6BtypePaWhaDPr
#undef OpIhWhb
#undef OpX6IhWhb
+#undef EMPTY
diff --git a/contrib/binutils/opcodes/ia64-opc-d.c b/contrib/binutils/opcodes/ia64-opc-d.c
index 27390f5..d916085 100644
--- a/contrib/binutils/opcodes/ia64-opc-d.c
+++ b/contrib/binutils/opcodes/ia64-opc-d.c
@@ -1,14 +1,34 @@
+/* ia64-opc-d.c -- IA-64 `D' opcode table.
+ Copyright 1998, 1999, 2000, 2002 Free Software Foundation, Inc.
+ Contributed by David Mosberger-Tang <davidm@hpl.hp.com>
+
+ This file is part of GDB, GAS, and the GNU binutils.
+
+ GDB, GAS, and the GNU binutils are free software; you can redistribute
+ them and/or modify them under the terms of the GNU General Public
+ License as published by the Free Software Foundation; either version
+ 2, or (at your option) any later version.
+
+ GDB, GAS, and the GNU binutils are distributed in the hope that they
+ will be useful, but WITHOUT ANY WARRANTY; without even the implied
+ warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
+ the GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this file; see the file COPYING. If not, write to the
+ Free Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA. */
+
struct ia64_opcode ia64_opcodes_d[] =
{
- {"add", IA64_TYPE_DYN, 1, 0, 0,
- {IA64_OPND_R1, IA64_OPND_IMM22, IA64_OPND_R3_2}},
- {"add", IA64_TYPE_DYN, 1, 0, 0,
- {IA64_OPND_R1, IA64_OPND_IMM14, IA64_OPND_R3}},
- {"break", IA64_TYPE_DYN, 0, 0, 0, {IA64_OPND_IMMU21}},
- {"chk.s", IA64_TYPE_DYN, 0, 0, 0, {IA64_OPND_R2, IA64_OPND_TGT25b}},
- {"mov", IA64_TYPE_DYN, 1, 0, 0, {IA64_OPND_R1, IA64_OPND_AR3}},
- {"mov", IA64_TYPE_DYN, 1, 0, 0, {IA64_OPND_AR3, IA64_OPND_IMM8}},
- {"mov", IA64_TYPE_DYN, 1, 0, 0, {IA64_OPND_AR3, IA64_OPND_R2}},
- {"nop", IA64_TYPE_DYN, 0, 0, 0, {IA64_OPND_IMMU21}},
- {0}
+ {"add", IA64_TYPE_DYN, 1, 0, 0, {IA64_OPND_R1, IA64_OPND_IMM22, IA64_OPND_R3_2}, 0, 0, NULL},
+ {"add", IA64_TYPE_DYN, 1, 0, 0, {IA64_OPND_R1, IA64_OPND_IMM14, IA64_OPND_R3}, 0, 0, NULL},
+ {"break", IA64_TYPE_DYN, 0, 0, 0, {IA64_OPND_IMMU21}, 0, 0, NULL},
+ {"chk.s", IA64_TYPE_DYN, 0, 0, 0, {IA64_OPND_R2, IA64_OPND_TGT25b}, 0, 0, NULL},
+ {"hint", IA64_TYPE_DYN, 0, 0, 0, {IA64_OPND_IMMU21}, 0, 0, NULL},
+ {"mov", IA64_TYPE_DYN, 1, 0, 0, {IA64_OPND_R1, IA64_OPND_AR3}, 0, 0, NULL},
+ {"mov", IA64_TYPE_DYN, 1, 0, 0, {IA64_OPND_AR3, IA64_OPND_IMM8}, 0, 0, NULL},
+ {"mov", IA64_TYPE_DYN, 1, 0, 0, {IA64_OPND_AR3, IA64_OPND_R2}, 0, 0, NULL},
+ {"nop", IA64_TYPE_DYN, 0, 0, 0, {IA64_OPND_IMMU21}, 0, 0, NULL},
+ {NULL, 0, 0, 0, 0, {0}, 0, 0, NULL}
};
diff --git a/contrib/binutils/opcodes/ia64-opc-f.c b/contrib/binutils/opcodes/ia64-opc-f.c
index 2f898c6..89dbcde 100644
--- a/contrib/binutils/opcodes/ia64-opc-f.c
+++ b/contrib/binutils/opcodes/ia64-opc-f.c
@@ -1,5 +1,5 @@
/* ia64-opc-f.c -- IA-64 `F' opcode table.
- Copyright 1998, 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2002 Free Software Foundation, Inc.
Contributed by David Mosberger-Tang <davidm@hpl.hp.com>
This file is part of GDB, GAS, and the GNU binutils.
@@ -36,6 +36,7 @@
#define bXb(x) (((ia64_insn) ((x) & 0x1)) << 33)
#define bX2(x) (((ia64_insn) ((x) & 0x3)) << 34)
#define bX6(x) (((ia64_insn) ((x) & 0x3f)) << 27)
+#define bY(x) (((ia64_insn) ((x) & 0x1)) << 26)
#define mF2 bF2 (-1)
#define mF4 bF4 (-1)
@@ -48,6 +49,7 @@
#define mXb bXb (-1)
#define mX2 bX2 (-1)
#define mX6 bX6 (-1)
+#define mY bY (-1)
#define OpXa(a,b) (bOp (a) | bXa (b)), (mOp | mXa)
#define OpXaSf(a,b,c) (bOp (a) | bXa (b) | bSf (c)), (mOp | mXa | mSf)
@@ -69,542 +71,549 @@
(bOp (a) | bXb (b) | bQ (c) | bSf (d)), (mOp | mXb | mQ | mSf)
#define OpXbX6(a,b,c) \
(bOp (a) | bXb (b) | bX6 (c)), (mOp | mXb | mX6)
+#define OpXbX6Y(a,b,c,d) \
+ (bOp (a) | bXb (b) | bX6 (c) | bY (d)), (mOp | mXb | mX6 | mY)
#define OpXbX6F2(a,b,c,d) \
(bOp (a) | bXb (b) | bX6 (c) | bF2 (d)), (mOp | mXb | mX6 | mF2)
#define OpXbX6Sf(a,b,c,d) \
(bOp (a) | bXb (b) | bX6 (c) | bSf (d)), (mOp | mXb | mX6 | mSf)
+/* Used to initialise unused fields in ia64_opcode struct,
+ in order to stop gcc from complaining. */
+#define EMPTY 0,0,NULL
+
struct ia64_opcode ia64_opcodes_f[] =
{
- /* F-type instruction encodings (sorted according to major opcode) */
-
- {"frcpa.s0", f2, OpXbQSf (0, 1, 0, 0), {F1, P2, F2, F3}},
- {"frcpa", f2, OpXbQSf (0, 1, 0, 0), {F1, P2, F2, F3}, PSEUDO},
- {"frcpa.s1", f2, OpXbQSf (0, 1, 0, 1), {F1, P2, F2, F3}},
- {"frcpa.s2", f2, OpXbQSf (0, 1, 0, 2), {F1, P2, F2, F3}},
- {"frcpa.s3", f2, OpXbQSf (0, 1, 0, 3), {F1, P2, F2, F3}},
-
- {"frsqrta.s0", f2, OpXbQSf (0, 1, 1, 0), {F1, P2, F3}},
- {"frsqrta", f2, OpXbQSf (0, 1, 1, 0), {F1, P2, F3}, PSEUDO},
- {"frsqrta.s1", f2, OpXbQSf (0, 1, 1, 1), {F1, P2, F3}},
- {"frsqrta.s2", f2, OpXbQSf (0, 1, 1, 2), {F1, P2, F3}},
- {"frsqrta.s3", f2, OpXbQSf (0, 1, 1, 3), {F1, P2, F3}},
-
- {"fmin.s0", f, OpXbX6Sf (0, 0, 0x14, 0), {F1, F2, F3}},
- {"fmin", f, OpXbX6Sf (0, 0, 0x14, 0), {F1, F2, F3}, PSEUDO},
- {"fmin.s1", f, OpXbX6Sf (0, 0, 0x14, 1), {F1, F2, F3}},
- {"fmin.s2", f, OpXbX6Sf (0, 0, 0x14, 2), {F1, F2, F3}},
- {"fmin.s3", f, OpXbX6Sf (0, 0, 0x14, 3), {F1, F2, F3}},
- {"fmax.s0", f, OpXbX6Sf (0, 0, 0x15, 0), {F1, F2, F3}},
- {"fmax", f, OpXbX6Sf (0, 0, 0x15, 0), {F1, F2, F3}, PSEUDO},
- {"fmax.s1", f, OpXbX6Sf (0, 0, 0x15, 1), {F1, F2, F3}},
- {"fmax.s2", f, OpXbX6Sf (0, 0, 0x15, 2), {F1, F2, F3}},
- {"fmax.s3", f, OpXbX6Sf (0, 0, 0x15, 3), {F1, F2, F3}},
- {"famin.s0", f, OpXbX6Sf (0, 0, 0x16, 0), {F1, F2, F3}},
- {"famin", f, OpXbX6Sf (0, 0, 0x16, 0), {F1, F2, F3}, PSEUDO},
- {"famin.s1", f, OpXbX6Sf (0, 0, 0x16, 1), {F1, F2, F3}},
- {"famin.s2", f, OpXbX6Sf (0, 0, 0x16, 2), {F1, F2, F3}},
- {"famin.s3", f, OpXbX6Sf (0, 0, 0x16, 3), {F1, F2, F3}},
- {"famax.s0", f, OpXbX6Sf (0, 0, 0x17, 0), {F1, F2, F3}},
- {"famax", f, OpXbX6Sf (0, 0, 0x17, 0), {F1, F2, F3}, PSEUDO},
- {"famax.s1", f, OpXbX6Sf (0, 0, 0x17, 1), {F1, F2, F3}},
- {"famax.s2", f, OpXbX6Sf (0, 0, 0x17, 2), {F1, F2, F3}},
- {"famax.s3", f, OpXbX6Sf (0, 0, 0x17, 3), {F1, F2, F3}},
-
- {"mov", f, OpXbX6 (0, 0, 0x10), {F1, F3}, PSEUDO | F2_EQ_F3},
- {"fabs", f, OpXbX6F2 (0, 0, 0x10, 0), {F1, F3}, PSEUDO},
- {"fneg", f, OpXbX6 (0, 0, 0x11), {F1, F3}, PSEUDO | F2_EQ_F3},
- {"fnegabs", f, OpXbX6F2 (0, 0, 0x11, 0), {F1, F3}, PSEUDO},
- {"fmerge.s", f, OpXbX6 (0, 0, 0x10), {F1, F2, F3}},
- {"fmerge.ns", f, OpXbX6 (0, 0, 0x11), {F1, F2, F3}},
-
- {"fmerge.se", f, OpXbX6 (0, 0, 0x12), {F1, F2, F3}},
- {"fmix.lr", f, OpXbX6 (0, 0, 0x39), {F1, F2, F3}},
- {"fmix.r", f, OpXbX6 (0, 0, 0x3a), {F1, F2, F3}},
- {"fmix.l", f, OpXbX6 (0, 0, 0x3b), {F1, F2, F3}},
- {"fsxt.r", f, OpXbX6 (0, 0, 0x3c), {F1, F2, F3}},
- {"fsxt.l", f, OpXbX6 (0, 0, 0x3d), {F1, F2, F3}},
- {"fpack", f, OpXbX6 (0, 0, 0x28), {F1, F2, F3}},
- {"fswap", f, OpXbX6 (0, 0, 0x34), {F1, F2, F3}},
- {"fswap.nl", f, OpXbX6 (0, 0, 0x35), {F1, F2, F3}},
- {"fswap.nr", f, OpXbX6 (0, 0, 0x36), {F1, F2, F3}},
- {"fand", f, OpXbX6 (0, 0, 0x2c), {F1, F2, F3}},
- {"fandcm", f, OpXbX6 (0, 0, 0x2d), {F1, F2, F3}},
- {"for", f, OpXbX6 (0, 0, 0x2e), {F1, F2, F3}},
- {"fxor", f, OpXbX6 (0, 0, 0x2f), {F1, F2, F3}},
-
- {"fcvt.fx.s0", f, OpXbX6Sf (0, 0, 0x18, 0), {F1, F2}},
- {"fcvt.fx", f, OpXbX6Sf (0, 0, 0x18, 0), {F1, F2}, PSEUDO},
- {"fcvt.fx.s1", f, OpXbX6Sf (0, 0, 0x18, 1), {F1, F2}},
- {"fcvt.fx.s2", f, OpXbX6Sf (0, 0, 0x18, 2), {F1, F2}},
- {"fcvt.fx.s3", f, OpXbX6Sf (0, 0, 0x18, 3), {F1, F2}},
- {"fcvt.fxu.s0", f, OpXbX6Sf (0, 0, 0x19, 0), {F1, F2}},
- {"fcvt.fxu", f, OpXbX6Sf (0, 0, 0x19, 0), {F1, F2}, PSEUDO},
- {"fcvt.fxu.s1", f, OpXbX6Sf (0, 0, 0x19, 1), {F1, F2}},
- {"fcvt.fxu.s2", f, OpXbX6Sf (0, 0, 0x19, 2), {F1, F2}},
- {"fcvt.fxu.s3", f, OpXbX6Sf (0, 0, 0x19, 3), {F1, F2}},
- {"fcvt.fx.trunc.s0", f, OpXbX6Sf (0, 0, 0x1a, 0), {F1, F2}},
- {"fcvt.fx.trunc", f, OpXbX6Sf (0, 0, 0x1a, 0), {F1, F2}, PSEUDO},
- {"fcvt.fx.trunc.s1", f, OpXbX6Sf (0, 0, 0x1a, 1), {F1, F2}},
- {"fcvt.fx.trunc.s2", f, OpXbX6Sf (0, 0, 0x1a, 2), {F1, F2}},
- {"fcvt.fx.trunc.s3", f, OpXbX6Sf (0, 0, 0x1a, 3), {F1, F2}},
- {"fcvt.fxu.trunc.s0", f, OpXbX6Sf (0, 0, 0x1b, 0), {F1, F2}},
- {"fcvt.fxu.trunc", f, OpXbX6Sf (0, 0, 0x1b, 0), {F1, F2}, PSEUDO},
- {"fcvt.fxu.trunc.s1", f, OpXbX6Sf (0, 0, 0x1b, 1), {F1, F2}},
- {"fcvt.fxu.trunc.s2", f, OpXbX6Sf (0, 0, 0x1b, 2), {F1, F2}},
- {"fcvt.fxu.trunc.s3", f, OpXbX6Sf (0, 0, 0x1b, 3), {F1, F2}},
-
- {"fcvt.xf", f, OpXbX6 (0, 0, 0x1c), {F1, F2}},
-
- {"fsetc.s0", f0, OpXbX6Sf (0, 0, 0x04, 0), {IMMU7a, IMMU7b}},
- {"fsetc", f0, OpXbX6Sf (0, 0, 0x04, 0), {IMMU7a, IMMU7b}, PSEUDO},
- {"fsetc.s1", f0, OpXbX6Sf (0, 0, 0x04, 1), {IMMU7a, IMMU7b}},
- {"fsetc.s2", f0, OpXbX6Sf (0, 0, 0x04, 2), {IMMU7a, IMMU7b}},
- {"fsetc.s3", f0, OpXbX6Sf (0, 0, 0x04, 3), {IMMU7a, IMMU7b}},
- {"fclrf.s0", f0, OpXbX6Sf (0, 0, 0x05, 0)},
- {"fclrf", f0, OpXbX6Sf (0, 0, 0x05, 0), {0}, PSEUDO},
- {"fclrf.s1", f0, OpXbX6Sf (0, 0, 0x05, 1)},
- {"fclrf.s2", f0, OpXbX6Sf (0, 0, 0x05, 2)},
- {"fclrf.s3", f0, OpXbX6Sf (0, 0, 0x05, 3)},
- {"fchkf.s0", f0, OpXbX6Sf (0, 0, 0x08, 0), {TGT25}},
- {"fchkf", f0, OpXbX6Sf (0, 0, 0x08, 0), {TGT25}, PSEUDO},
- {"fchkf.s1", f0, OpXbX6Sf (0, 0, 0x08, 1), {TGT25}},
- {"fchkf.s2", f0, OpXbX6Sf (0, 0, 0x08, 2), {TGT25}},
- {"fchkf.s3", f0, OpXbX6Sf (0, 0, 0x08, 3), {TGT25}},
-
- {"break.f", f0, OpXbX6 (0, 0, 0x00), {IMMU21}},
- {"nop.f", f0, OpXbX6 (0, 0, 0x01), {IMMU21}},
-
- {"fprcpa.s0", f2, OpXbQSf (1, 1, 0, 0), {F1, P2, F2, F3}},
- {"fprcpa", f2, OpXbQSf (1, 1, 0, 0), {F1, P2, F2, F3}, PSEUDO},
- {"fprcpa.s1", f2, OpXbQSf (1, 1, 0, 1), {F1, P2, F2, F3}},
- {"fprcpa.s2", f2, OpXbQSf (1, 1, 0, 2), {F1, P2, F2, F3}},
- {"fprcpa.s3", f2, OpXbQSf (1, 1, 0, 3), {F1, P2, F2, F3}},
-
- {"fprsqrta.s0", f2, OpXbQSf (1, 1, 1, 0), {F1, P2, F3}},
- {"fprsqrta", f2, OpXbQSf (1, 1, 1, 0), {F1, P2, F3}, PSEUDO},
- {"fprsqrta.s1", f2, OpXbQSf (1, 1, 1, 1), {F1, P2, F3}},
- {"fprsqrta.s2", f2, OpXbQSf (1, 1, 1, 2), {F1, P2, F3}},
- {"fprsqrta.s3", f2, OpXbQSf (1, 1, 1, 3), {F1, P2, F3}},
-
- {"fpmin.s0", f, OpXbX6Sf (1, 0, 0x14, 0), {F1, F2, F3}},
- {"fpmin", f, OpXbX6Sf (1, 0, 0x14, 0), {F1, F2, F3}, PSEUDO},
- {"fpmin.s1", f, OpXbX6Sf (1, 0, 0x14, 1), {F1, F2, F3}},
- {"fpmin.s2", f, OpXbX6Sf (1, 0, 0x14, 2), {F1, F2, F3}},
- {"fpmin.s3", f, OpXbX6Sf (1, 0, 0x14, 3), {F1, F2, F3}},
- {"fpmax.s0", f, OpXbX6Sf (1, 0, 0x15, 0), {F1, F2, F3}},
- {"fpmax", f, OpXbX6Sf (1, 0, 0x15, 0), {F1, F2, F3}, PSEUDO},
- {"fpmax.s1", f, OpXbX6Sf (1, 0, 0x15, 1), {F1, F2, F3}},
- {"fpmax.s2", f, OpXbX6Sf (1, 0, 0x15, 2), {F1, F2, F3}},
- {"fpmax.s3", f, OpXbX6Sf (1, 0, 0x15, 3), {F1, F2, F3}},
- {"fpamin.s0", f, OpXbX6Sf (1, 0, 0x16, 0), {F1, F2, F3}},
- {"fpamin", f, OpXbX6Sf (1, 0, 0x16, 0), {F1, F2, F3}, PSEUDO},
- {"fpamin.s1", f, OpXbX6Sf (1, 0, 0x16, 1), {F1, F2, F3}},
- {"fpamin.s2", f, OpXbX6Sf (1, 0, 0x16, 2), {F1, F2, F3}},
- {"fpamin.s3", f, OpXbX6Sf (1, 0, 0x16, 3), {F1, F2, F3}},
- {"fpamax.s0", f, OpXbX6Sf (1, 0, 0x17, 0), {F1, F2, F3}},
- {"fpamax", f, OpXbX6Sf (1, 0, 0x17, 0), {F1, F2, F3}, PSEUDO},
- {"fpamax.s1", f, OpXbX6Sf (1, 0, 0x17, 1), {F1, F2, F3}},
- {"fpamax.s2", f, OpXbX6Sf (1, 0, 0x17, 2), {F1, F2, F3}},
- {"fpamax.s3", f, OpXbX6Sf (1, 0, 0x17, 3), {F1, F2, F3}},
-
- {"fpcmp.eq.s0", f, OpXbX6Sf (1, 0, 0x30, 0), {F1, F2, F3}},
- {"fpcmp.eq", f, OpXbX6Sf (1, 0, 0x30, 0), {F1, F2, F3}, PSEUDO},
- {"fpcmp.eq.s1", f, OpXbX6Sf (1, 0, 0x30, 1), {F1, F2, F3}},
- {"fpcmp.eq.s2", f, OpXbX6Sf (1, 0, 0x30, 2), {F1, F2, F3}},
- {"fpcmp.eq.s3", f, OpXbX6Sf (1, 0, 0x30, 3), {F1, F2, F3}},
- {"fpcmp.lt.s0", f, OpXbX6Sf (1, 0, 0x31, 0), {F1, F2, F3}},
- {"fpcmp.lt", f, OpXbX6Sf (1, 0, 0x31, 0), {F1, F2, F3}, PSEUDO},
- {"fpcmp.lt.s1", f, OpXbX6Sf (1, 0, 0x31, 1), {F1, F2, F3}},
- {"fpcmp.lt.s2", f, OpXbX6Sf (1, 0, 0x31, 2), {F1, F2, F3}},
- {"fpcmp.lt.s3", f, OpXbX6Sf (1, 0, 0x31, 3), {F1, F2, F3}},
- {"fpcmp.le.s0", f, OpXbX6Sf (1, 0, 0x32, 0), {F1, F2, F3}},
- {"fpcmp.le", f, OpXbX6Sf (1, 0, 0x32, 0), {F1, F2, F3}, PSEUDO},
- {"fpcmp.le.s1", f, OpXbX6Sf (1, 0, 0x32, 1), {F1, F2, F3}},
- {"fpcmp.le.s2", f, OpXbX6Sf (1, 0, 0x32, 2), {F1, F2, F3}},
- {"fpcmp.le.s3", f, OpXbX6Sf (1, 0, 0x32, 3), {F1, F2, F3}},
- {"fpcmp.gt.s0", f, OpXbX6Sf (1, 0, 0x31, 0), {F1, F3, F2}, PSEUDO},
- {"fpcmp.gt", f, OpXbX6Sf (1, 0, 0x31, 0), {F1, F3, F2}, PSEUDO},
- {"fpcmp.gt.s1", f, OpXbX6Sf (1, 0, 0x31, 1), {F1, F3, F2}, PSEUDO},
- {"fpcmp.gt.s2", f, OpXbX6Sf (1, 0, 0x31, 2), {F1, F3, F2}, PSEUDO},
- {"fpcmp.gt.s3", f, OpXbX6Sf (1, 0, 0x31, 3), {F1, F3, F2}, PSEUDO},
- {"fpcmp.ge.s0", f, OpXbX6Sf (1, 0, 0x32, 0), {F1, F3, F2}, PSEUDO},
- {"fpcmp.ge", f, OpXbX6Sf (1, 0, 0x32, 0), {F1, F3, F2}, PSEUDO},
- {"fpcmp.ge.s1", f, OpXbX6Sf (1, 0, 0x32, 1), {F1, F3, F2}, PSEUDO},
- {"fpcmp.ge.s2", f, OpXbX6Sf (1, 0, 0x32, 2), {F1, F3, F2}, PSEUDO},
- {"fpcmp.ge.s3", f, OpXbX6Sf (1, 0, 0x32, 3), {F1, F3, F2}, PSEUDO},
- {"fpcmp.unord.s0", f, OpXbX6Sf (1, 0, 0x33, 0), {F1, F2, F3}},
- {"fpcmp.unord", f, OpXbX6Sf (1, 0, 0x33, 0), {F1, F2, F3}, PSEUDO},
- {"fpcmp.unord.s1", f, OpXbX6Sf (1, 0, 0x33, 1), {F1, F2, F3}},
- {"fpcmp.unord.s2", f, OpXbX6Sf (1, 0, 0x33, 2), {F1, F2, F3}},
- {"fpcmp.unord.s3", f, OpXbX6Sf (1, 0, 0x33, 3), {F1, F2, F3}},
- {"fpcmp.neq.s0", f, OpXbX6Sf (1, 0, 0x34, 0), {F1, F2, F3}},
- {"fpcmp.neq", f, OpXbX6Sf (1, 0, 0x34, 0), {F1, F2, F3}, PSEUDO},
- {"fpcmp.neq.s1", f, OpXbX6Sf (1, 0, 0x34, 1), {F1, F2, F3}},
- {"fpcmp.neq.s2", f, OpXbX6Sf (1, 0, 0x34, 2), {F1, F2, F3}},
- {"fpcmp.neq.s3", f, OpXbX6Sf (1, 0, 0x34, 3), {F1, F2, F3}},
- {"fpcmp.nlt.s0", f, OpXbX6Sf (1, 0, 0x35, 0), {F1, F2, F3}},
- {"fpcmp.nlt", f, OpXbX6Sf (1, 0, 0x35, 0), {F1, F2, F3}, PSEUDO},
- {"fpcmp.nlt.s1", f, OpXbX6Sf (1, 0, 0x35, 1), {F1, F2, F3}},
- {"fpcmp.nlt.s2", f, OpXbX6Sf (1, 0, 0x35, 2), {F1, F2, F3}},
- {"fpcmp.nlt.s3", f, OpXbX6Sf (1, 0, 0x35, 3), {F1, F2, F3}},
- {"fpcmp.nle.s0", f, OpXbX6Sf (1, 0, 0x36, 0), {F1, F2, F3}},
- {"fpcmp.nle", f, OpXbX6Sf (1, 0, 0x36, 0), {F1, F2, F3}, PSEUDO},
- {"fpcmp.nle.s1", f, OpXbX6Sf (1, 0, 0x36, 1), {F1, F2, F3}},
- {"fpcmp.nle.s2", f, OpXbX6Sf (1, 0, 0x36, 2), {F1, F2, F3}},
- {"fpcmp.nle.s3", f, OpXbX6Sf (1, 0, 0x36, 3), {F1, F2, F3}},
- {"fpcmp.ngt.s0", f, OpXbX6Sf (1, 0, 0x35, 0), {F1, F3, F2}, PSEUDO},
- {"fpcmp.ngt", f, OpXbX6Sf (1, 0, 0x35, 0), {F1, F3, F2}, PSEUDO},
- {"fpcmp.ngt.s1", f, OpXbX6Sf (1, 0, 0x35, 1), {F1, F3, F2}, PSEUDO},
- {"fpcmp.ngt.s2", f, OpXbX6Sf (1, 0, 0x35, 2), {F1, F3, F2}, PSEUDO},
- {"fpcmp.ngt.s3", f, OpXbX6Sf (1, 0, 0x35, 3), {F1, F3, F2}, PSEUDO},
- {"fpcmp.nge.s0", f, OpXbX6Sf (1, 0, 0x36, 0), {F1, F3, F2}, PSEUDO},
- {"fpcmp.nge", f, OpXbX6Sf (1, 0, 0x36, 0), {F1, F3, F2}, PSEUDO},
- {"fpcmp.nge.s1", f, OpXbX6Sf (1, 0, 0x36, 1), {F1, F3, F2}, PSEUDO},
- {"fpcmp.nge.s2", f, OpXbX6Sf (1, 0, 0x36, 2), {F1, F3, F2}, PSEUDO},
- {"fpcmp.nge.s3", f, OpXbX6Sf (1, 0, 0x36, 3), {F1, F3, F2}, PSEUDO},
- {"fpcmp.ord.s0", f, OpXbX6Sf (1, 0, 0x37, 0), {F1, F2, F3}},
- {"fpcmp.ord", f, OpXbX6Sf (1, 0, 0x37, 0), {F1, F2, F3}, PSEUDO},
- {"fpcmp.ord.s1", f, OpXbX6Sf (1, 0, 0x37, 1), {F1, F2, F3}},
- {"fpcmp.ord.s2", f, OpXbX6Sf (1, 0, 0x37, 2), {F1, F2, F3}},
- {"fpcmp.ord.s3", f, OpXbX6Sf (1, 0, 0x37, 3), {F1, F2, F3}},
-
- {"fpabs", f, OpXbX6F2 (1, 0, 0x10, 0), {F1, F3}, PSEUDO},
- {"fpneg", f, OpXbX6 (1, 0, 0x11), {F1, F3}, PSEUDO | F2_EQ_F3},
- {"fpnegabs", f, OpXbX6F2 (1, 0, 0x11, 0), {F1, F3}, PSEUDO},
- {"fpmerge.s", f, OpXbX6 (1, 0, 0x10), {F1, F2, F3}},
- {"fpmerge.ns", f, OpXbX6 (1, 0, 0x11), {F1, F2, F3}},
- {"fpmerge.se", f, OpXbX6 (1, 0, 0x12), {F1, F2, F3}},
-
- {"fpcvt.fx.s0", f, OpXbX6Sf (1, 0, 0x18, 0), {F1, F2}},
- {"fpcvt.fx", f, OpXbX6Sf (1, 0, 0x18, 0), {F1, F2}, PSEUDO},
- {"fpcvt.fx.s1", f, OpXbX6Sf (1, 0, 0x18, 1), {F1, F2}},
- {"fpcvt.fx.s2", f, OpXbX6Sf (1, 0, 0x18, 2), {F1, F2}},
- {"fpcvt.fx.s3", f, OpXbX6Sf (1, 0, 0x18, 3), {F1, F2}},
- {"fpcvt.fxu.s0", f, OpXbX6Sf (1, 0, 0x19, 0), {F1, F2}},
- {"fpcvt.fxu", f, OpXbX6Sf (1, 0, 0x19, 0), {F1, F2}, PSEUDO},
- {"fpcvt.fxu.s1", f, OpXbX6Sf (1, 0, 0x19, 1), {F1, F2}},
- {"fpcvt.fxu.s2", f, OpXbX6Sf (1, 0, 0x19, 2), {F1, F2}},
- {"fpcvt.fxu.s3", f, OpXbX6Sf (1, 0, 0x19, 3), {F1, F2}},
- {"fpcvt.fx.trunc.s0", f, OpXbX6Sf (1, 0, 0x1a, 0), {F1, F2}},
- {"fpcvt.fx.trunc", f, OpXbX6Sf (1, 0, 0x1a, 0), {F1, F2}, PSEUDO},
- {"fpcvt.fx.trunc.s1", f, OpXbX6Sf (1, 0, 0x1a, 1), {F1, F2}},
- {"fpcvt.fx.trunc.s2", f, OpXbX6Sf (1, 0, 0x1a, 2), {F1, F2}},
- {"fpcvt.fx.trunc.s3", f, OpXbX6Sf (1, 0, 0x1a, 3), {F1, F2}},
- {"fpcvt.fxu.trunc.s0", f, OpXbX6Sf (1, 0, 0x1b, 0), {F1, F2}},
- {"fpcvt.fxu.trunc", f, OpXbX6Sf (1, 0, 0x1b, 0), {F1, F2}, PSEUDO},
- {"fpcvt.fxu.trunc.s1", f, OpXbX6Sf (1, 0, 0x1b, 1), {F1, F2}},
- {"fpcvt.fxu.trunc.s2", f, OpXbX6Sf (1, 0, 0x1b, 2), {F1, F2}},
- {"fpcvt.fxu.trunc.s3", f, OpXbX6Sf (1, 0, 0x1b, 3), {F1, F2}},
-
- {"fcmp.eq.s0", f2, OpRaRbTaSf (4, 0, 0, 0, 0), {P1, P2, F2, F3}},
- {"fcmp.eq", f2, OpRaRbTaSf (4, 0, 0, 0, 0), {P1, P2, F2, F3}, PSEUDO},
- {"fcmp.eq.s1", f2, OpRaRbTaSf (4, 0, 0, 0, 1), {P1, P2, F2, F3}},
- {"fcmp.eq.s2", f2, OpRaRbTaSf (4, 0, 0, 0, 2), {P1, P2, F2, F3}},
- {"fcmp.eq.s3", f2, OpRaRbTaSf (4, 0, 0, 0, 3), {P1, P2, F2, F3}},
- {"fcmp.lt.s0", f2, OpRaRbTaSf (4, 0, 1, 0, 0), {P1, P2, F2, F3}},
- {"fcmp.lt", f2, OpRaRbTaSf (4, 0, 1, 0, 0), {P1, P2, F2, F3}, PSEUDO},
- {"fcmp.lt.s1", f2, OpRaRbTaSf (4, 0, 1, 0, 1), {P1, P2, F2, F3}},
- {"fcmp.lt.s2", f2, OpRaRbTaSf (4, 0, 1, 0, 2), {P1, P2, F2, F3}},
- {"fcmp.lt.s3", f2, OpRaRbTaSf (4, 0, 1, 0, 3), {P1, P2, F2, F3}},
- {"fcmp.le.s0", f2, OpRaRbTaSf (4, 1, 0, 0, 0), {P1, P2, F2, F3}},
- {"fcmp.le", f2, OpRaRbTaSf (4, 1, 0, 0, 0), {P1, P2, F2, F3}, PSEUDO},
- {"fcmp.le.s1", f2, OpRaRbTaSf (4, 1, 0, 0, 1), {P1, P2, F2, F3}},
- {"fcmp.le.s2", f2, OpRaRbTaSf (4, 1, 0, 0, 2), {P1, P2, F2, F3}},
- {"fcmp.le.s3", f2, OpRaRbTaSf (4, 1, 0, 0, 3), {P1, P2, F2, F3}},
- {"fcmp.unord.s0", f2, OpRaRbTaSf (4, 1, 1, 0, 0), {P1, P2, F2, F3}},
- {"fcmp.unord", f2, OpRaRbTaSf (4, 1, 1, 0, 0), {P1, P2, F2, F3}, PSEUDO},
- {"fcmp.unord.s1", f2, OpRaRbTaSf (4, 1, 1, 0, 1), {P1, P2, F2, F3}},
- {"fcmp.unord.s2", f2, OpRaRbTaSf (4, 1, 1, 0, 2), {P1, P2, F2, F3}},
- {"fcmp.unord.s3", f2, OpRaRbTaSf (4, 1, 1, 0, 3), {P1, P2, F2, F3}},
- {"fcmp.eq.unc.s0", f2, OpRaRbTaSf (4, 0, 0, 1, 0), {P1, P2, F2, F3}},
- {"fcmp.eq.unc", f2, OpRaRbTaSf (4, 0, 0, 1, 0), {P1, P2, F2, F3}, PSEUDO},
- {"fcmp.eq.unc.s1", f2, OpRaRbTaSf (4, 0, 0, 1, 1), {P1, P2, F2, F3}},
- {"fcmp.eq.unc.s2", f2, OpRaRbTaSf (4, 0, 0, 1, 2), {P1, P2, F2, F3}},
- {"fcmp.eq.unc.s3", f2, OpRaRbTaSf (4, 0, 0, 1, 3), {P1, P2, F2, F3}},
- {"fcmp.lt.unc.s0", f2, OpRaRbTaSf (4, 0, 1, 1, 0), {P1, P2, F2, F3}},
- {"fcmp.lt.unc", f2, OpRaRbTaSf (4, 0, 1, 1, 0), {P1, P2, F2, F3}, PSEUDO},
- {"fcmp.lt.unc.s1", f2, OpRaRbTaSf (4, 0, 1, 1, 1), {P1, P2, F2, F3}},
- {"fcmp.lt.unc.s2", f2, OpRaRbTaSf (4, 0, 1, 1, 2), {P1, P2, F2, F3}},
- {"fcmp.lt.unc.s3", f2, OpRaRbTaSf (4, 0, 1, 1, 3), {P1, P2, F2, F3}},
- {"fcmp.le.unc.s0", f2, OpRaRbTaSf (4, 1, 0, 1, 0), {P1, P2, F2, F3}},
- {"fcmp.le.unc", f2, OpRaRbTaSf (4, 1, 0, 1, 0), {P1, P2, F2, F3}, PSEUDO},
- {"fcmp.le.unc.s1", f2, OpRaRbTaSf (4, 1, 0, 1, 1), {P1, P2, F2, F3}},
- {"fcmp.le.unc.s2", f2, OpRaRbTaSf (4, 1, 0, 1, 2), {P1, P2, F2, F3}},
- {"fcmp.le.unc.s3", f2, OpRaRbTaSf (4, 1, 0, 1, 3), {P1, P2, F2, F3}},
- {"fcmp.unord.unc.s0", f2, OpRaRbTaSf (4, 1, 1, 1, 0), {P1, P2, F2, F3}},
- {"fcmp.unord.unc", f2, OpRaRbTaSf (4, 1, 1, 1, 0), {P1, P2, F2, F3}, PSEUDO},
- {"fcmp.unord.unc.s1", f2, OpRaRbTaSf (4, 1, 1, 1, 1), {P1, P2, F2, F3}},
- {"fcmp.unord.unc.s2", f2, OpRaRbTaSf (4, 1, 1, 1, 2), {P1, P2, F2, F3}},
- {"fcmp.unord.unc.s3", f2, OpRaRbTaSf (4, 1, 1, 1, 3), {P1, P2, F2, F3}},
+ /* F-type instruction encodings (sorted according to major opcode). */
+
+ {"frcpa.s0", f2, OpXbQSf (0, 1, 0, 0), {F1, P2, F2, F3}, EMPTY},
+ {"frcpa", f2, OpXbQSf (0, 1, 0, 0), {F1, P2, F2, F3}, PSEUDO, 0, NULL},
+ {"frcpa.s1", f2, OpXbQSf (0, 1, 0, 1), {F1, P2, F2, F3}, EMPTY},
+ {"frcpa.s2", f2, OpXbQSf (0, 1, 0, 2), {F1, P2, F2, F3}, EMPTY},
+ {"frcpa.s3", f2, OpXbQSf (0, 1, 0, 3), {F1, P2, F2, F3}, EMPTY},
+
+ {"frsqrta.s0", f2, OpXbQSf (0, 1, 1, 0), {F1, P2, F3}, EMPTY},
+ {"frsqrta", f2, OpXbQSf (0, 1, 1, 0), {F1, P2, F3}, PSEUDO, 0, NULL},
+ {"frsqrta.s1", f2, OpXbQSf (0, 1, 1, 1), {F1, P2, F3}, EMPTY},
+ {"frsqrta.s2", f2, OpXbQSf (0, 1, 1, 2), {F1, P2, F3}, EMPTY},
+ {"frsqrta.s3", f2, OpXbQSf (0, 1, 1, 3), {F1, P2, F3}, EMPTY},
+
+ {"fmin.s0", f, OpXbX6Sf (0, 0, 0x14, 0), {F1, F2, F3}, EMPTY},
+ {"fmin", f, OpXbX6Sf (0, 0, 0x14, 0), {F1, F2, F3}, PSEUDO, 0, NULL},
+ {"fmin.s1", f, OpXbX6Sf (0, 0, 0x14, 1), {F1, F2, F3}, EMPTY},
+ {"fmin.s2", f, OpXbX6Sf (0, 0, 0x14, 2), {F1, F2, F3}, EMPTY},
+ {"fmin.s3", f, OpXbX6Sf (0, 0, 0x14, 3), {F1, F2, F3}, EMPTY},
+ {"fmax.s0", f, OpXbX6Sf (0, 0, 0x15, 0), {F1, F2, F3}, EMPTY},
+ {"fmax", f, OpXbX6Sf (0, 0, 0x15, 0), {F1, F2, F3}, PSEUDO, 0, NULL},
+ {"fmax.s1", f, OpXbX6Sf (0, 0, 0x15, 1), {F1, F2, F3}, EMPTY},
+ {"fmax.s2", f, OpXbX6Sf (0, 0, 0x15, 2), {F1, F2, F3}, EMPTY},
+ {"fmax.s3", f, OpXbX6Sf (0, 0, 0x15, 3), {F1, F2, F3}, EMPTY},
+ {"famin.s0", f, OpXbX6Sf (0, 0, 0x16, 0), {F1, F2, F3}, EMPTY},
+ {"famin", f, OpXbX6Sf (0, 0, 0x16, 0), {F1, F2, F3}, PSEUDO, 0, NULL},
+ {"famin.s1", f, OpXbX6Sf (0, 0, 0x16, 1), {F1, F2, F3}, EMPTY},
+ {"famin.s2", f, OpXbX6Sf (0, 0, 0x16, 2), {F1, F2, F3}, EMPTY},
+ {"famin.s3", f, OpXbX6Sf (0, 0, 0x16, 3), {F1, F2, F3}, EMPTY},
+ {"famax.s0", f, OpXbX6Sf (0, 0, 0x17, 0), {F1, F2, F3}, EMPTY},
+ {"famax", f, OpXbX6Sf (0, 0, 0x17, 0), {F1, F2, F3}, PSEUDO, 0, NULL},
+ {"famax.s1", f, OpXbX6Sf (0, 0, 0x17, 1), {F1, F2, F3}, EMPTY},
+ {"famax.s2", f, OpXbX6Sf (0, 0, 0x17, 2), {F1, F2, F3}, EMPTY},
+ {"famax.s3", f, OpXbX6Sf (0, 0, 0x17, 3), {F1, F2, F3}, EMPTY},
+
+ {"mov", f, OpXbX6 (0, 0, 0x10), {F1, F3}, PSEUDO | F2_EQ_F3, 0, NULL},
+ {"fabs", f, OpXbX6F2 (0, 0, 0x10, 0), {F1, F3}, PSEUDO, 0, NULL},
+ {"fneg", f, OpXbX6 (0, 0, 0x11), {F1, F3}, PSEUDO | F2_EQ_F3, 0, NULL},
+ {"fnegabs", f, OpXbX6F2 (0, 0, 0x11, 0), {F1, F3}, PSEUDO, 0, NULL},
+ {"fmerge.s", f, OpXbX6 (0, 0, 0x10), {F1, F2, F3}, EMPTY},
+ {"fmerge.ns", f, OpXbX6 (0, 0, 0x11), {F1, F2, F3}, EMPTY},
+
+ {"fmerge.se", f, OpXbX6 (0, 0, 0x12), {F1, F2, F3}, EMPTY},
+ {"fmix.lr", f, OpXbX6 (0, 0, 0x39), {F1, F2, F3}, EMPTY},
+ {"fmix.r", f, OpXbX6 (0, 0, 0x3a), {F1, F2, F3}, EMPTY},
+ {"fmix.l", f, OpXbX6 (0, 0, 0x3b), {F1, F2, F3}, EMPTY},
+ {"fsxt.r", f, OpXbX6 (0, 0, 0x3c), {F1, F2, F3}, EMPTY},
+ {"fsxt.l", f, OpXbX6 (0, 0, 0x3d), {F1, F2, F3}, EMPTY},
+ {"fpack", f, OpXbX6 (0, 0, 0x28), {F1, F2, F3}, EMPTY},
+ {"fswap", f, OpXbX6 (0, 0, 0x34), {F1, F2, F3}, EMPTY},
+ {"fswap.nl", f, OpXbX6 (0, 0, 0x35), {F1, F2, F3}, EMPTY},
+ {"fswap.nr", f, OpXbX6 (0, 0, 0x36), {F1, F2, F3}, EMPTY},
+ {"fand", f, OpXbX6 (0, 0, 0x2c), {F1, F2, F3}, EMPTY},
+ {"fandcm", f, OpXbX6 (0, 0, 0x2d), {F1, F2, F3}, EMPTY},
+ {"for", f, OpXbX6 (0, 0, 0x2e), {F1, F2, F3}, EMPTY},
+ {"fxor", f, OpXbX6 (0, 0, 0x2f), {F1, F2, F3}, EMPTY},
+
+ {"fcvt.fx.s0", f, OpXbX6Sf (0, 0, 0x18, 0), {F1, F2}, EMPTY},
+ {"fcvt.fx", f, OpXbX6Sf (0, 0, 0x18, 0), {F1, F2}, PSEUDO, 0, NULL},
+ {"fcvt.fx.s1", f, OpXbX6Sf (0, 0, 0x18, 1), {F1, F2}, EMPTY},
+ {"fcvt.fx.s2", f, OpXbX6Sf (0, 0, 0x18, 2), {F1, F2}, EMPTY},
+ {"fcvt.fx.s3", f, OpXbX6Sf (0, 0, 0x18, 3), {F1, F2}, EMPTY},
+ {"fcvt.fxu.s0", f, OpXbX6Sf (0, 0, 0x19, 0), {F1, F2}, EMPTY},
+ {"fcvt.fxu", f, OpXbX6Sf (0, 0, 0x19, 0), {F1, F2}, PSEUDO, 0, NULL},
+ {"fcvt.fxu.s1", f, OpXbX6Sf (0, 0, 0x19, 1), {F1, F2}, EMPTY},
+ {"fcvt.fxu.s2", f, OpXbX6Sf (0, 0, 0x19, 2), {F1, F2}, EMPTY},
+ {"fcvt.fxu.s3", f, OpXbX6Sf (0, 0, 0x19, 3), {F1, F2}, EMPTY},
+ {"fcvt.fx.trunc.s0", f, OpXbX6Sf (0, 0, 0x1a, 0), {F1, F2}, EMPTY},
+ {"fcvt.fx.trunc", f, OpXbX6Sf (0, 0, 0x1a, 0), {F1, F2}, PSEUDO, 0, NULL},
+ {"fcvt.fx.trunc.s1", f, OpXbX6Sf (0, 0, 0x1a, 1), {F1, F2}, EMPTY},
+ {"fcvt.fx.trunc.s2", f, OpXbX6Sf (0, 0, 0x1a, 2), {F1, F2}, EMPTY},
+ {"fcvt.fx.trunc.s3", f, OpXbX6Sf (0, 0, 0x1a, 3), {F1, F2}, EMPTY},
+ {"fcvt.fxu.trunc.s0", f, OpXbX6Sf (0, 0, 0x1b, 0), {F1, F2}, EMPTY},
+ {"fcvt.fxu.trunc", f, OpXbX6Sf (0, 0, 0x1b, 0), {F1, F2}, PSEUDO, 0, NULL},
+ {"fcvt.fxu.trunc.s1", f, OpXbX6Sf (0, 0, 0x1b, 1), {F1, F2}, EMPTY},
+ {"fcvt.fxu.trunc.s2", f, OpXbX6Sf (0, 0, 0x1b, 2), {F1, F2}, EMPTY},
+ {"fcvt.fxu.trunc.s3", f, OpXbX6Sf (0, 0, 0x1b, 3), {F1, F2}, EMPTY},
+
+ {"fcvt.xf", f, OpXbX6 (0, 0, 0x1c), {F1, F2}, EMPTY},
+
+ {"fsetc.s0", f0, OpXbX6Sf (0, 0, 0x04, 0), {IMMU7a, IMMU7b}, EMPTY},
+ {"fsetc", f0, OpXbX6Sf (0, 0, 0x04, 0), {IMMU7a, IMMU7b}, PSEUDO, 0, NULL},
+ {"fsetc.s1", f0, OpXbX6Sf (0, 0, 0x04, 1), {IMMU7a, IMMU7b}, EMPTY},
+ {"fsetc.s2", f0, OpXbX6Sf (0, 0, 0x04, 2), {IMMU7a, IMMU7b}, EMPTY},
+ {"fsetc.s3", f0, OpXbX6Sf (0, 0, 0x04, 3), {IMMU7a, IMMU7b}, EMPTY},
+ {"fclrf.s0", f0, OpXbX6Sf (0, 0, 0x05, 0), {}, EMPTY},
+ {"fclrf", f0, OpXbX6Sf (0, 0, 0x05, 0), {0}, PSEUDO, 0, NULL},
+ {"fclrf.s1", f0, OpXbX6Sf (0, 0, 0x05, 1), {}, EMPTY},
+ {"fclrf.s2", f0, OpXbX6Sf (0, 0, 0x05, 2), {}, EMPTY},
+ {"fclrf.s3", f0, OpXbX6Sf (0, 0, 0x05, 3), {}, EMPTY},
+ {"fchkf.s0", f0, OpXbX6Sf (0, 0, 0x08, 0), {TGT25}, EMPTY},
+ {"fchkf", f0, OpXbX6Sf (0, 0, 0x08, 0), {TGT25}, PSEUDO, 0, NULL},
+ {"fchkf.s1", f0, OpXbX6Sf (0, 0, 0x08, 1), {TGT25}, EMPTY},
+ {"fchkf.s2", f0, OpXbX6Sf (0, 0, 0x08, 2), {TGT25}, EMPTY},
+ {"fchkf.s3", f0, OpXbX6Sf (0, 0, 0x08, 3), {TGT25}, EMPTY},
+
+ {"break.f", f0, OpXbX6 (0, 0, 0x00), {IMMU21}, EMPTY},
+ {"nop.f", f0, OpXbX6Y (0, 0, 0x01, 0), {IMMU21}, EMPTY},
+ {"hint.f", f0, OpXbX6Y (0, 0, 0x01, 1), {IMMU21}, EMPTY},
+
+ {"fprcpa.s0", f2, OpXbQSf (1, 1, 0, 0), {F1, P2, F2, F3}, EMPTY},
+ {"fprcpa", f2, OpXbQSf (1, 1, 0, 0), {F1, P2, F2, F3}, PSEUDO, 0, NULL},
+ {"fprcpa.s1", f2, OpXbQSf (1, 1, 0, 1), {F1, P2, F2, F3}, EMPTY},
+ {"fprcpa.s2", f2, OpXbQSf (1, 1, 0, 2), {F1, P2, F2, F3}, EMPTY},
+ {"fprcpa.s3", f2, OpXbQSf (1, 1, 0, 3), {F1, P2, F2, F3}, EMPTY},
+
+ {"fprsqrta.s0", f2, OpXbQSf (1, 1, 1, 0), {F1, P2, F3}, EMPTY},
+ {"fprsqrta", f2, OpXbQSf (1, 1, 1, 0), {F1, P2, F3}, PSEUDO, 0, NULL},
+ {"fprsqrta.s1", f2, OpXbQSf (1, 1, 1, 1), {F1, P2, F3}, EMPTY},
+ {"fprsqrta.s2", f2, OpXbQSf (1, 1, 1, 2), {F1, P2, F3}, EMPTY},
+ {"fprsqrta.s3", f2, OpXbQSf (1, 1, 1, 3), {F1, P2, F3}, EMPTY},
+
+ {"fpmin.s0", f, OpXbX6Sf (1, 0, 0x14, 0), {F1, F2, F3}, EMPTY},
+ {"fpmin", f, OpXbX6Sf (1, 0, 0x14, 0), {F1, F2, F3}, PSEUDO, 0, NULL},
+ {"fpmin.s1", f, OpXbX6Sf (1, 0, 0x14, 1), {F1, F2, F3}, EMPTY},
+ {"fpmin.s2", f, OpXbX6Sf (1, 0, 0x14, 2), {F1, F2, F3}, EMPTY},
+ {"fpmin.s3", f, OpXbX6Sf (1, 0, 0x14, 3), {F1, F2, F3}, EMPTY},
+ {"fpmax.s0", f, OpXbX6Sf (1, 0, 0x15, 0), {F1, F2, F3}, EMPTY},
+ {"fpmax", f, OpXbX6Sf (1, 0, 0x15, 0), {F1, F2, F3}, PSEUDO, 0, NULL},
+ {"fpmax.s1", f, OpXbX6Sf (1, 0, 0x15, 1), {F1, F2, F3}, EMPTY},
+ {"fpmax.s2", f, OpXbX6Sf (1, 0, 0x15, 2), {F1, F2, F3}, EMPTY},
+ {"fpmax.s3", f, OpXbX6Sf (1, 0, 0x15, 3), {F1, F2, F3}, EMPTY},
+ {"fpamin.s0", f, OpXbX6Sf (1, 0, 0x16, 0), {F1, F2, F3}, EMPTY},
+ {"fpamin", f, OpXbX6Sf (1, 0, 0x16, 0), {F1, F2, F3}, PSEUDO, 0, NULL},
+ {"fpamin.s1", f, OpXbX6Sf (1, 0, 0x16, 1), {F1, F2, F3}, EMPTY},
+ {"fpamin.s2", f, OpXbX6Sf (1, 0, 0x16, 2), {F1, F2, F3}, EMPTY},
+ {"fpamin.s3", f, OpXbX6Sf (1, 0, 0x16, 3), {F1, F2, F3}, EMPTY},
+ {"fpamax.s0", f, OpXbX6Sf (1, 0, 0x17, 0), {F1, F2, F3}, EMPTY},
+ {"fpamax", f, OpXbX6Sf (1, 0, 0x17, 0), {F1, F2, F3}, PSEUDO, 0, NULL},
+ {"fpamax.s1", f, OpXbX6Sf (1, 0, 0x17, 1), {F1, F2, F3}, EMPTY},
+ {"fpamax.s2", f, OpXbX6Sf (1, 0, 0x17, 2), {F1, F2, F3}, EMPTY},
+ {"fpamax.s3", f, OpXbX6Sf (1, 0, 0x17, 3), {F1, F2, F3}, EMPTY},
+
+ {"fpcmp.eq.s0", f, OpXbX6Sf (1, 0, 0x30, 0), {F1, F2, F3}, EMPTY},
+ {"fpcmp.eq", f, OpXbX6Sf (1, 0, 0x30, 0), {F1, F2, F3}, PSEUDO, 0, NULL},
+ {"fpcmp.eq.s1", f, OpXbX6Sf (1, 0, 0x30, 1), {F1, F2, F3}, EMPTY},
+ {"fpcmp.eq.s2", f, OpXbX6Sf (1, 0, 0x30, 2), {F1, F2, F3}, EMPTY},
+ {"fpcmp.eq.s3", f, OpXbX6Sf (1, 0, 0x30, 3), {F1, F2, F3}, EMPTY},
+ {"fpcmp.lt.s0", f, OpXbX6Sf (1, 0, 0x31, 0), {F1, F2, F3}, EMPTY},
+ {"fpcmp.lt", f, OpXbX6Sf (1, 0, 0x31, 0), {F1, F2, F3}, PSEUDO, 0, NULL},
+ {"fpcmp.lt.s1", f, OpXbX6Sf (1, 0, 0x31, 1), {F1, F2, F3}, EMPTY},
+ {"fpcmp.lt.s2", f, OpXbX6Sf (1, 0, 0x31, 2), {F1, F2, F3}, EMPTY},
+ {"fpcmp.lt.s3", f, OpXbX6Sf (1, 0, 0x31, 3), {F1, F2, F3}, EMPTY},
+ {"fpcmp.le.s0", f, OpXbX6Sf (1, 0, 0x32, 0), {F1, F2, F3}, EMPTY},
+ {"fpcmp.le", f, OpXbX6Sf (1, 0, 0x32, 0), {F1, F2, F3}, PSEUDO, 0, NULL},
+ {"fpcmp.le.s1", f, OpXbX6Sf (1, 0, 0x32, 1), {F1, F2, F3}, EMPTY},
+ {"fpcmp.le.s2", f, OpXbX6Sf (1, 0, 0x32, 2), {F1, F2, F3}, EMPTY},
+ {"fpcmp.le.s3", f, OpXbX6Sf (1, 0, 0x32, 3), {F1, F2, F3}, EMPTY},
+ {"fpcmp.gt.s0", f, OpXbX6Sf (1, 0, 0x31, 0), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.gt", f, OpXbX6Sf (1, 0, 0x31, 0), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.gt.s1", f, OpXbX6Sf (1, 0, 0x31, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.gt.s2", f, OpXbX6Sf (1, 0, 0x31, 2), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.gt.s3", f, OpXbX6Sf (1, 0, 0x31, 3), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.ge.s0", f, OpXbX6Sf (1, 0, 0x32, 0), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.ge", f, OpXbX6Sf (1, 0, 0x32, 0), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.ge.s1", f, OpXbX6Sf (1, 0, 0x32, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.ge.s2", f, OpXbX6Sf (1, 0, 0x32, 2), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.ge.s3", f, OpXbX6Sf (1, 0, 0x32, 3), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.unord.s0", f, OpXbX6Sf (1, 0, 0x33, 0), {F1, F2, F3}, EMPTY},
+ {"fpcmp.unord", f, OpXbX6Sf (1, 0, 0x33, 0), {F1, F2, F3}, PSEUDO, 0, NULL},
+ {"fpcmp.unord.s1", f, OpXbX6Sf (1, 0, 0x33, 1), {F1, F2, F3}, EMPTY},
+ {"fpcmp.unord.s2", f, OpXbX6Sf (1, 0, 0x33, 2), {F1, F2, F3}, EMPTY},
+ {"fpcmp.unord.s3", f, OpXbX6Sf (1, 0, 0x33, 3), {F1, F2, F3}, EMPTY},
+ {"fpcmp.neq.s0", f, OpXbX6Sf (1, 0, 0x34, 0), {F1, F2, F3}, EMPTY},
+ {"fpcmp.neq", f, OpXbX6Sf (1, 0, 0x34, 0), {F1, F2, F3}, PSEUDO, 0, NULL},
+ {"fpcmp.neq.s1", f, OpXbX6Sf (1, 0, 0x34, 1), {F1, F2, F3}, EMPTY},
+ {"fpcmp.neq.s2", f, OpXbX6Sf (1, 0, 0x34, 2), {F1, F2, F3}, EMPTY},
+ {"fpcmp.neq.s3", f, OpXbX6Sf (1, 0, 0x34, 3), {F1, F2, F3}, EMPTY},
+ {"fpcmp.nlt.s0", f, OpXbX6Sf (1, 0, 0x35, 0), {F1, F2, F3}, EMPTY},
+ {"fpcmp.nlt", f, OpXbX6Sf (1, 0, 0x35, 0), {F1, F2, F3}, PSEUDO, 0, NULL},
+ {"fpcmp.nlt.s1", f, OpXbX6Sf (1, 0, 0x35, 1), {F1, F2, F3}, EMPTY},
+ {"fpcmp.nlt.s2", f, OpXbX6Sf (1, 0, 0x35, 2), {F1, F2, F3}, EMPTY},
+ {"fpcmp.nlt.s3", f, OpXbX6Sf (1, 0, 0x35, 3), {F1, F2, F3}, EMPTY},
+ {"fpcmp.nle.s0", f, OpXbX6Sf (1, 0, 0x36, 0), {F1, F2, F3}, EMPTY},
+ {"fpcmp.nle", f, OpXbX6Sf (1, 0, 0x36, 0), {F1, F2, F3}, PSEUDO, 0, NULL},
+ {"fpcmp.nle.s1", f, OpXbX6Sf (1, 0, 0x36, 1), {F1, F2, F3}, EMPTY},
+ {"fpcmp.nle.s2", f, OpXbX6Sf (1, 0, 0x36, 2), {F1, F2, F3}, EMPTY},
+ {"fpcmp.nle.s3", f, OpXbX6Sf (1, 0, 0x36, 3), {F1, F2, F3}, EMPTY},
+ {"fpcmp.ngt.s0", f, OpXbX6Sf (1, 0, 0x35, 0), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.ngt", f, OpXbX6Sf (1, 0, 0x35, 0), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.ngt.s1", f, OpXbX6Sf (1, 0, 0x35, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.ngt.s2", f, OpXbX6Sf (1, 0, 0x35, 2), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.ngt.s3", f, OpXbX6Sf (1, 0, 0x35, 3), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.nge.s0", f, OpXbX6Sf (1, 0, 0x36, 0), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.nge", f, OpXbX6Sf (1, 0, 0x36, 0), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.nge.s1", f, OpXbX6Sf (1, 0, 0x36, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.nge.s2", f, OpXbX6Sf (1, 0, 0x36, 2), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.nge.s3", f, OpXbX6Sf (1, 0, 0x36, 3), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fpcmp.ord.s0", f, OpXbX6Sf (1, 0, 0x37, 0), {F1, F2, F3}, EMPTY},
+ {"fpcmp.ord", f, OpXbX6Sf (1, 0, 0x37, 0), {F1, F2, F3}, PSEUDO, 0, NULL},
+ {"fpcmp.ord.s1", f, OpXbX6Sf (1, 0, 0x37, 1), {F1, F2, F3}, EMPTY},
+ {"fpcmp.ord.s2", f, OpXbX6Sf (1, 0, 0x37, 2), {F1, F2, F3}, EMPTY},
+ {"fpcmp.ord.s3", f, OpXbX6Sf (1, 0, 0x37, 3), {F1, F2, F3}, EMPTY},
+
+ {"fpabs", f, OpXbX6F2 (1, 0, 0x10, 0), {F1, F3}, PSEUDO, 0, NULL},
+ {"fpneg", f, OpXbX6 (1, 0, 0x11), {F1, F3}, PSEUDO | F2_EQ_F3, 0, NULL},
+ {"fpnegabs", f, OpXbX6F2 (1, 0, 0x11, 0), {F1, F3}, PSEUDO, 0, NULL},
+ {"fpmerge.s", f, OpXbX6 (1, 0, 0x10), {F1, F2, F3}, EMPTY},
+ {"fpmerge.ns", f, OpXbX6 (1, 0, 0x11), {F1, F2, F3}, EMPTY},
+ {"fpmerge.se", f, OpXbX6 (1, 0, 0x12), {F1, F2, F3}, EMPTY},
+
+ {"fpcvt.fx.s0", f, OpXbX6Sf (1, 0, 0x18, 0), {F1, F2}, EMPTY},
+ {"fpcvt.fx", f, OpXbX6Sf (1, 0, 0x18, 0), {F1, F2}, PSEUDO, 0, NULL},
+ {"fpcvt.fx.s1", f, OpXbX6Sf (1, 0, 0x18, 1), {F1, F2}, EMPTY},
+ {"fpcvt.fx.s2", f, OpXbX6Sf (1, 0, 0x18, 2), {F1, F2}, EMPTY},
+ {"fpcvt.fx.s3", f, OpXbX6Sf (1, 0, 0x18, 3), {F1, F2}, EMPTY},
+ {"fpcvt.fxu.s0", f, OpXbX6Sf (1, 0, 0x19, 0), {F1, F2}, EMPTY},
+ {"fpcvt.fxu", f, OpXbX6Sf (1, 0, 0x19, 0), {F1, F2}, PSEUDO, 0, NULL},
+ {"fpcvt.fxu.s1", f, OpXbX6Sf (1, 0, 0x19, 1), {F1, F2}, EMPTY},
+ {"fpcvt.fxu.s2", f, OpXbX6Sf (1, 0, 0x19, 2), {F1, F2}, EMPTY},
+ {"fpcvt.fxu.s3", f, OpXbX6Sf (1, 0, 0x19, 3), {F1, F2}, EMPTY},
+ {"fpcvt.fx.trunc.s0", f, OpXbX6Sf (1, 0, 0x1a, 0), {F1, F2}, EMPTY},
+ {"fpcvt.fx.trunc", f, OpXbX6Sf (1, 0, 0x1a, 0), {F1, F2}, PSEUDO, 0, NULL},
+ {"fpcvt.fx.trunc.s1", f, OpXbX6Sf (1, 0, 0x1a, 1), {F1, F2}, EMPTY},
+ {"fpcvt.fx.trunc.s2", f, OpXbX6Sf (1, 0, 0x1a, 2), {F1, F2}, EMPTY},
+ {"fpcvt.fx.trunc.s3", f, OpXbX6Sf (1, 0, 0x1a, 3), {F1, F2}, EMPTY},
+ {"fpcvt.fxu.trunc.s0", f, OpXbX6Sf (1, 0, 0x1b, 0), {F1, F2}, EMPTY},
+ {"fpcvt.fxu.trunc", f, OpXbX6Sf (1, 0, 0x1b, 0), {F1, F2}, PSEUDO, 0, NULL},
+ {"fpcvt.fxu.trunc.s1", f, OpXbX6Sf (1, 0, 0x1b, 1), {F1, F2}, EMPTY},
+ {"fpcvt.fxu.trunc.s2", f, OpXbX6Sf (1, 0, 0x1b, 2), {F1, F2}, EMPTY},
+ {"fpcvt.fxu.trunc.s3", f, OpXbX6Sf (1, 0, 0x1b, 3), {F1, F2}, EMPTY},
+
+ {"fcmp.eq.s0", f2, OpRaRbTaSf (4, 0, 0, 0, 0), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.eq", f2, OpRaRbTaSf (4, 0, 0, 0, 0), {P1, P2, F2, F3}, PSEUDO, 0, NULL},
+ {"fcmp.eq.s1", f2, OpRaRbTaSf (4, 0, 0, 0, 1), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.eq.s2", f2, OpRaRbTaSf (4, 0, 0, 0, 2), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.eq.s3", f2, OpRaRbTaSf (4, 0, 0, 0, 3), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.lt.s0", f2, OpRaRbTaSf (4, 0, 1, 0, 0), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.lt", f2, OpRaRbTaSf (4, 0, 1, 0, 0), {P1, P2, F2, F3}, PSEUDO, 0, NULL},
+ {"fcmp.lt.s1", f2, OpRaRbTaSf (4, 0, 1, 0, 1), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.lt.s2", f2, OpRaRbTaSf (4, 0, 1, 0, 2), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.lt.s3", f2, OpRaRbTaSf (4, 0, 1, 0, 3), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.le.s0", f2, OpRaRbTaSf (4, 1, 0, 0, 0), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.le", f2, OpRaRbTaSf (4, 1, 0, 0, 0), {P1, P2, F2, F3}, PSEUDO, 0, NULL},
+ {"fcmp.le.s1", f2, OpRaRbTaSf (4, 1, 0, 0, 1), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.le.s2", f2, OpRaRbTaSf (4, 1, 0, 0, 2), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.le.s3", f2, OpRaRbTaSf (4, 1, 0, 0, 3), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.unord.s0", f2, OpRaRbTaSf (4, 1, 1, 0, 0), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.unord", f2, OpRaRbTaSf (4, 1, 1, 0, 0), {P1, P2, F2, F3}, PSEUDO, 0, NULL},
+ {"fcmp.unord.s1", f2, OpRaRbTaSf (4, 1, 1, 0, 1), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.unord.s2", f2, OpRaRbTaSf (4, 1, 1, 0, 2), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.unord.s3", f2, OpRaRbTaSf (4, 1, 1, 0, 3), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.eq.unc.s0", f2, OpRaRbTaSf (4, 0, 0, 1, 0), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.eq.unc", f2, OpRaRbTaSf (4, 0, 0, 1, 0), {P1, P2, F2, F3}, PSEUDO, 0, NULL},
+ {"fcmp.eq.unc.s1", f2, OpRaRbTaSf (4, 0, 0, 1, 1), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.eq.unc.s2", f2, OpRaRbTaSf (4, 0, 0, 1, 2), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.eq.unc.s3", f2, OpRaRbTaSf (4, 0, 0, 1, 3), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.lt.unc.s0", f2, OpRaRbTaSf (4, 0, 1, 1, 0), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.lt.unc", f2, OpRaRbTaSf (4, 0, 1, 1, 0), {P1, P2, F2, F3}, PSEUDO, 0, NULL},
+ {"fcmp.lt.unc.s1", f2, OpRaRbTaSf (4, 0, 1, 1, 1), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.lt.unc.s2", f2, OpRaRbTaSf (4, 0, 1, 1, 2), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.lt.unc.s3", f2, OpRaRbTaSf (4, 0, 1, 1, 3), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.le.unc.s0", f2, OpRaRbTaSf (4, 1, 0, 1, 0), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.le.unc", f2, OpRaRbTaSf (4, 1, 0, 1, 0), {P1, P2, F2, F3}, PSEUDO, 0, NULL},
+ {"fcmp.le.unc.s1", f2, OpRaRbTaSf (4, 1, 0, 1, 1), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.le.unc.s2", f2, OpRaRbTaSf (4, 1, 0, 1, 2), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.le.unc.s3", f2, OpRaRbTaSf (4, 1, 0, 1, 3), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.unord.unc.s0", f2, OpRaRbTaSf (4, 1, 1, 1, 0), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.unord.unc", f2, OpRaRbTaSf (4, 1, 1, 1, 0), {P1, P2, F2, F3}, PSEUDO, 0, NULL},
+ {"fcmp.unord.unc.s1", f2, OpRaRbTaSf (4, 1, 1, 1, 1), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.unord.unc.s2", f2, OpRaRbTaSf (4, 1, 1, 1, 2), {P1, P2, F2, F3}, EMPTY},
+ {"fcmp.unord.unc.s3", f2, OpRaRbTaSf (4, 1, 1, 1, 3), {P1, P2, F2, F3}, EMPTY},
/* pseudo-ops of the above */
- {"fcmp.gt.s0", f2, OpRaRbTaSf (4, 0, 1, 0, 0), {P1, P2, F3, F2}},
- {"fcmp.gt", f2, OpRaRbTaSf (4, 0, 1, 0, 0), {P1, P2, F3, F2}, PSEUDO},
- {"fcmp.gt.s1", f2, OpRaRbTaSf (4, 0, 1, 0, 1), {P1, P2, F3, F2}},
- {"fcmp.gt.s2", f2, OpRaRbTaSf (4, 0, 1, 0, 2), {P1, P2, F3, F2}},
- {"fcmp.gt.s3", f2, OpRaRbTaSf (4, 0, 1, 0, 3), {P1, P2, F3, F2}},
- {"fcmp.ge.s0", f2, OpRaRbTaSf (4, 1, 0, 0, 0), {P1, P2, F3, F2}},
- {"fcmp.ge", f2, OpRaRbTaSf (4, 1, 0, 0, 0), {P1, P2, F3, F2}, PSEUDO},
- {"fcmp.ge.s1", f2, OpRaRbTaSf (4, 1, 0, 0, 1), {P1, P2, F3, F2}},
- {"fcmp.ge.s2", f2, OpRaRbTaSf (4, 1, 0, 0, 2), {P1, P2, F3, F2}},
- {"fcmp.ge.s3", f2, OpRaRbTaSf (4, 1, 0, 0, 3), {P1, P2, F3, F2}},
- {"fcmp.neq.s0", f2, OpRaRbTaSf (4, 0, 0, 0, 0), {P2, P1, F2, F3}},
- {"fcmp.neq", f2, OpRaRbTaSf (4, 0, 0, 0, 0), {P2, P1, F2, F3}, PSEUDO},
- {"fcmp.neq.s1", f2, OpRaRbTaSf (4, 0, 0, 0, 1), {P2, P1, F2, F3}},
- {"fcmp.neq.s2", f2, OpRaRbTaSf (4, 0, 0, 0, 2), {P2, P1, F2, F3}},
- {"fcmp.neq.s3", f2, OpRaRbTaSf (4, 0, 0, 0, 3), {P2, P1, F2, F3}},
- {"fcmp.nlt.s0", f2, OpRaRbTaSf (4, 0, 1, 0, 0), {P2, P1, F2, F3}},
- {"fcmp.nlt", f2, OpRaRbTaSf (4, 0, 1, 0, 0), {P2, P1, F2, F3}, PSEUDO},
- {"fcmp.nlt.s1", f2, OpRaRbTaSf (4, 0, 1, 0, 1), {P2, P1, F2, F3}},
- {"fcmp.nlt.s2", f2, OpRaRbTaSf (4, 0, 1, 0, 2), {P2, P1, F2, F3}},
- {"fcmp.nlt.s3", f2, OpRaRbTaSf (4, 0, 1, 0, 3), {P2, P1, F2, F3}},
- {"fcmp.nle.s0", f2, OpRaRbTaSf (4, 1, 0, 0, 0), {P2, P1, F2, F3}},
- {"fcmp.nle", f2, OpRaRbTaSf (4, 1, 0, 0, 0), {P2, P1, F2, F3}, PSEUDO},
- {"fcmp.nle.s1", f2, OpRaRbTaSf (4, 1, 0, 0, 1), {P2, P1, F2, F3}},
- {"fcmp.nle.s2", f2, OpRaRbTaSf (4, 1, 0, 0, 2), {P2, P1, F2, F3}},
- {"fcmp.nle.s3", f2, OpRaRbTaSf (4, 1, 0, 0, 3), {P2, P1, F2, F3}},
- {"fcmp.ngt.s0", f2, OpRaRbTaSf (4, 0, 1, 0, 0), {P2, P1, F3, F2}},
- {"fcmp.ngt", f2, OpRaRbTaSf (4, 0, 1, 0, 0), {P2, P1, F3, F2}, PSEUDO},
- {"fcmp.ngt.s1", f2, OpRaRbTaSf (4, 0, 1, 0, 1), {P2, P1, F3, F2}},
- {"fcmp.ngt.s2", f2, OpRaRbTaSf (4, 0, 1, 0, 2), {P2, P1, F3, F2}},
- {"fcmp.ngt.s3", f2, OpRaRbTaSf (4, 0, 1, 0, 3), {P2, P1, F3, F2}},
- {"fcmp.nge.s0", f2, OpRaRbTaSf (4, 1, 0, 0, 0), {P2, P1, F3, F2}},
- {"fcmp.nge", f2, OpRaRbTaSf (4, 1, 0, 0, 0), {P2, P1, F3, F2}, PSEUDO},
- {"fcmp.nge.s1", f2, OpRaRbTaSf (4, 1, 0, 0, 1), {P2, P1, F3, F2}},
- {"fcmp.nge.s2", f2, OpRaRbTaSf (4, 1, 0, 0, 2), {P2, P1, F3, F2}},
- {"fcmp.nge.s3", f2, OpRaRbTaSf (4, 1, 0, 0, 3), {P2, P1, F3, F2}},
- {"fcmp.ord.s0", f2, OpRaRbTaSf (4, 1, 1, 0, 0), {P2, P1, F2, F3}},
- {"fcmp.ord", f2, OpRaRbTaSf (4, 1, 1, 0, 0), {P2, P1, F2, F3}, PSEUDO},
- {"fcmp.ord.s1", f2, OpRaRbTaSf (4, 1, 1, 0, 1), {P2, P1, F2, F3}},
- {"fcmp.ord.s2", f2, OpRaRbTaSf (4, 1, 1, 0, 2), {P2, P1, F2, F3}},
- {"fcmp.ord.s3", f2, OpRaRbTaSf (4, 1, 1, 0, 3), {P2, P1, F2, F3}},
- {"fcmp.gt.unc.s0", f2, OpRaRbTaSf (4, 0, 1, 1, 0), {P1, P2, F3, F2}},
- {"fcmp.gt.unc", f2, OpRaRbTaSf (4, 0, 1, 1, 0), {P1, P2, F3, F2}, PSEUDO},
- {"fcmp.gt.unc.s1", f2, OpRaRbTaSf (4, 0, 1, 1, 1), {P1, P2, F3, F2}},
- {"fcmp.gt.unc.s2", f2, OpRaRbTaSf (4, 0, 1, 1, 2), {P1, P2, F3, F2}},
- {"fcmp.gt.unc.s3", f2, OpRaRbTaSf (4, 0, 1, 1, 3), {P1, P2, F3, F2}},
- {"fcmp.ge.unc.s0", f2, OpRaRbTaSf (4, 1, 0, 1, 0), {P1, P2, F3, F2}},
- {"fcmp.ge.unc", f2, OpRaRbTaSf (4, 1, 0, 1, 0), {P1, P2, F3, F2}, PSEUDO},
- {"fcmp.ge.unc.s1", f2, OpRaRbTaSf (4, 1, 0, 1, 1), {P1, P2, F3, F2}},
- {"fcmp.ge.unc.s2", f2, OpRaRbTaSf (4, 1, 0, 1, 2), {P1, P2, F3, F2}},
- {"fcmp.ge.unc.s3", f2, OpRaRbTaSf (4, 1, 0, 1, 3), {P1, P2, F3, F2}},
- {"fcmp.neq.unc.s0", f2, OpRaRbTaSf (4, 0, 0, 1, 0), {P2, P1, F2, F3}},
- {"fcmp.neq.unc", f2, OpRaRbTaSf (4, 0, 0, 1, 0), {P2, P1, F2, F3}, PSEUDO},
- {"fcmp.neq.unc.s1", f2, OpRaRbTaSf (4, 0, 0, 1, 1), {P2, P1, F2, F3}},
- {"fcmp.neq.unc.s2", f2, OpRaRbTaSf (4, 0, 0, 1, 2), {P2, P1, F2, F3}},
- {"fcmp.neq.unc.s3", f2, OpRaRbTaSf (4, 0, 0, 1, 3), {P2, P1, F2, F3}},
- {"fcmp.nlt.unc.s0", f2, OpRaRbTaSf (4, 0, 1, 1, 0), {P2, P1, F2, F3}},
- {"fcmp.nlt.unc", f2, OpRaRbTaSf (4, 0, 1, 1, 0), {P2, P1, F2, F3}, PSEUDO},
- {"fcmp.nlt.unc.s1", f2, OpRaRbTaSf (4, 0, 1, 1, 1), {P2, P1, F2, F3}},
- {"fcmp.nlt.unc.s2", f2, OpRaRbTaSf (4, 0, 1, 1, 2), {P2, P1, F2, F3}},
- {"fcmp.nlt.unc.s3", f2, OpRaRbTaSf (4, 0, 1, 1, 3), {P2, P1, F2, F3}},
- {"fcmp.nle.unc.s0", f2, OpRaRbTaSf (4, 1, 0, 1, 0), {P2, P1, F2, F3}},
- {"fcmp.nle.unc", f2, OpRaRbTaSf (4, 1, 0, 1, 0), {P2, P1, F2, F3}, PSEUDO},
- {"fcmp.nle.unc.s1", f2, OpRaRbTaSf (4, 1, 0, 1, 1), {P2, P1, F2, F3}},
- {"fcmp.nle.unc.s2", f2, OpRaRbTaSf (4, 1, 0, 1, 2), {P2, P1, F2, F3}},
- {"fcmp.nle.unc.s3", f2, OpRaRbTaSf (4, 1, 0, 1, 3), {P2, P1, F2, F3}},
- {"fcmp.ngt.unc.s0", f2, OpRaRbTaSf (4, 0, 1, 1, 0), {P2, P1, F3, F2}},
- {"fcmp.ngt.unc", f2, OpRaRbTaSf (4, 0, 1, 1, 0), {P2, P1, F3, F2}, PSEUDO},
- {"fcmp.ngt.unc.s1", f2, OpRaRbTaSf (4, 0, 1, 1, 1), {P2, P1, F3, F2}},
- {"fcmp.ngt.unc.s2", f2, OpRaRbTaSf (4, 0, 1, 1, 2), {P2, P1, F3, F2}},
- {"fcmp.ngt.unc.s3", f2, OpRaRbTaSf (4, 0, 1, 1, 3), {P2, P1, F3, F2}},
- {"fcmp.nge.unc.s0", f2, OpRaRbTaSf (4, 1, 0, 1, 0), {P2, P1, F3, F2}},
- {"fcmp.nge.unc", f2, OpRaRbTaSf (4, 1, 0, 1, 0), {P2, P1, F3, F2}, PSEUDO},
- {"fcmp.nge.unc.s1", f2, OpRaRbTaSf (4, 1, 0, 1, 1), {P2, P1, F3, F2}},
- {"fcmp.nge.unc.s2", f2, OpRaRbTaSf (4, 1, 0, 1, 2), {P2, P1, F3, F2}},
- {"fcmp.nge.unc.s3", f2, OpRaRbTaSf (4, 1, 0, 1, 3), {P2, P1, F3, F2}},
- {"fcmp.ord.unc.s0", f2, OpRaRbTaSf (4, 1, 1, 1, 0), {P2, P1, F2, F3}},
- {"fcmp.ord.unc", f2, OpRaRbTaSf (4, 1, 1, 1, 0), {P2, P1, F2, F3}, PSEUDO},
- {"fcmp.ord.unc.s1", f2, OpRaRbTaSf (4, 1, 1, 1, 1), {P2, P1, F2, F3}},
- {"fcmp.ord.unc.s2", f2, OpRaRbTaSf (4, 1, 1, 1, 2), {P2, P1, F2, F3}},
- {"fcmp.ord.unc.s3", f2, OpRaRbTaSf (4, 1, 1, 1, 3), {P2, P1, F2, F3}},
-
- {"fclass.m", f2, OpTa (5, 0), {P1, P2, F2, IMMU9}},
- {"fclass.nm", f2, OpTa (5, 0), {P2, P1, F2, IMMU9}, PSEUDO},
- {"fclass.m.unc", f2, OpTa (5, 1), {P1, P2, F2, IMMU9}},
- {"fclass.nm.unc", f2, OpTa (5, 1), {P2, P1, F2, IMMU9}, PSEUDO},
+ {"fcmp.gt.s0", f2, OpRaRbTaSf (4, 0, 1, 0, 0), {P1, P2, F3, F2}, EMPTY},
+ {"fcmp.gt", f2, OpRaRbTaSf (4, 0, 1, 0, 0), {P1, P2, F3, F2}, PSEUDO, 0, NULL},
+ {"fcmp.gt.s1", f2, OpRaRbTaSf (4, 0, 1, 0, 1), {P1, P2, F3, F2}, EMPTY},
+ {"fcmp.gt.s2", f2, OpRaRbTaSf (4, 0, 1, 0, 2), {P1, P2, F3, F2}, EMPTY},
+ {"fcmp.gt.s3", f2, OpRaRbTaSf (4, 0, 1, 0, 3), {P1, P2, F3, F2}, EMPTY},
+ {"fcmp.ge.s0", f2, OpRaRbTaSf (4, 1, 0, 0, 0), {P1, P2, F3, F2}, EMPTY},
+ {"fcmp.ge", f2, OpRaRbTaSf (4, 1, 0, 0, 0), {P1, P2, F3, F2}, PSEUDO, 0, NULL},
+ {"fcmp.ge.s1", f2, OpRaRbTaSf (4, 1, 0, 0, 1), {P1, P2, F3, F2}, EMPTY},
+ {"fcmp.ge.s2", f2, OpRaRbTaSf (4, 1, 0, 0, 2), {P1, P2, F3, F2}, EMPTY},
+ {"fcmp.ge.s3", f2, OpRaRbTaSf (4, 1, 0, 0, 3), {P1, P2, F3, F2}, EMPTY},
+ {"fcmp.neq.s0", f2, OpRaRbTaSf (4, 0, 0, 0, 0), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.neq", f2, OpRaRbTaSf (4, 0, 0, 0, 0), {P2, P1, F2, F3}, PSEUDO, 0, NULL},
+ {"fcmp.neq.s1", f2, OpRaRbTaSf (4, 0, 0, 0, 1), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.neq.s2", f2, OpRaRbTaSf (4, 0, 0, 0, 2), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.neq.s3", f2, OpRaRbTaSf (4, 0, 0, 0, 3), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.nlt.s0", f2, OpRaRbTaSf (4, 0, 1, 0, 0), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.nlt", f2, OpRaRbTaSf (4, 0, 1, 0, 0), {P2, P1, F2, F3}, PSEUDO, 0, NULL},
+ {"fcmp.nlt.s1", f2, OpRaRbTaSf (4, 0, 1, 0, 1), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.nlt.s2", f2, OpRaRbTaSf (4, 0, 1, 0, 2), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.nlt.s3", f2, OpRaRbTaSf (4, 0, 1, 0, 3), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.nle.s0", f2, OpRaRbTaSf (4, 1, 0, 0, 0), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.nle", f2, OpRaRbTaSf (4, 1, 0, 0, 0), {P2, P1, F2, F3}, PSEUDO, 0, NULL},
+ {"fcmp.nle.s1", f2, OpRaRbTaSf (4, 1, 0, 0, 1), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.nle.s2", f2, OpRaRbTaSf (4, 1, 0, 0, 2), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.nle.s3", f2, OpRaRbTaSf (4, 1, 0, 0, 3), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.ngt.s0", f2, OpRaRbTaSf (4, 0, 1, 0, 0), {P2, P1, F3, F2}, EMPTY},
+ {"fcmp.ngt", f2, OpRaRbTaSf (4, 0, 1, 0, 0), {P2, P1, F3, F2}, PSEUDO, 0, NULL},
+ {"fcmp.ngt.s1", f2, OpRaRbTaSf (4, 0, 1, 0, 1), {P2, P1, F3, F2}, EMPTY},
+ {"fcmp.ngt.s2", f2, OpRaRbTaSf (4, 0, 1, 0, 2), {P2, P1, F3, F2}, EMPTY},
+ {"fcmp.ngt.s3", f2, OpRaRbTaSf (4, 0, 1, 0, 3), {P2, P1, F3, F2}, EMPTY},
+ {"fcmp.nge.s0", f2, OpRaRbTaSf (4, 1, 0, 0, 0), {P2, P1, F3, F2}, EMPTY},
+ {"fcmp.nge", f2, OpRaRbTaSf (4, 1, 0, 0, 0), {P2, P1, F3, F2}, PSEUDO, 0, NULL},
+ {"fcmp.nge.s1", f2, OpRaRbTaSf (4, 1, 0, 0, 1), {P2, P1, F3, F2}, EMPTY},
+ {"fcmp.nge.s2", f2, OpRaRbTaSf (4, 1, 0, 0, 2), {P2, P1, F3, F2}, EMPTY},
+ {"fcmp.nge.s3", f2, OpRaRbTaSf (4, 1, 0, 0, 3), {P2, P1, F3, F2}, EMPTY},
+ {"fcmp.ord.s0", f2, OpRaRbTaSf (4, 1, 1, 0, 0), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.ord", f2, OpRaRbTaSf (4, 1, 1, 0, 0), {P2, P1, F2, F3}, PSEUDO, 0, NULL},
+ {"fcmp.ord.s1", f2, OpRaRbTaSf (4, 1, 1, 0, 1), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.ord.s2", f2, OpRaRbTaSf (4, 1, 1, 0, 2), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.ord.s3", f2, OpRaRbTaSf (4, 1, 1, 0, 3), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.gt.unc.s0", f2, OpRaRbTaSf (4, 0, 1, 1, 0), {P1, P2, F3, F2}, EMPTY},
+ {"fcmp.gt.unc", f2, OpRaRbTaSf (4, 0, 1, 1, 0), {P1, P2, F3, F2}, PSEUDO, 0, NULL},
+ {"fcmp.gt.unc.s1", f2, OpRaRbTaSf (4, 0, 1, 1, 1), {P1, P2, F3, F2}, EMPTY},
+ {"fcmp.gt.unc.s2", f2, OpRaRbTaSf (4, 0, 1, 1, 2), {P1, P2, F3, F2}, EMPTY},
+ {"fcmp.gt.unc.s3", f2, OpRaRbTaSf (4, 0, 1, 1, 3), {P1, P2, F3, F2}, EMPTY},
+ {"fcmp.ge.unc.s0", f2, OpRaRbTaSf (4, 1, 0, 1, 0), {P1, P2, F3, F2}, EMPTY},
+ {"fcmp.ge.unc", f2, OpRaRbTaSf (4, 1, 0, 1, 0), {P1, P2, F3, F2}, PSEUDO, 0, NULL},
+ {"fcmp.ge.unc.s1", f2, OpRaRbTaSf (4, 1, 0, 1, 1), {P1, P2, F3, F2}, EMPTY},
+ {"fcmp.ge.unc.s2", f2, OpRaRbTaSf (4, 1, 0, 1, 2), {P1, P2, F3, F2}, EMPTY},
+ {"fcmp.ge.unc.s3", f2, OpRaRbTaSf (4, 1, 0, 1, 3), {P1, P2, F3, F2}, EMPTY},
+ {"fcmp.neq.unc.s0", f2, OpRaRbTaSf (4, 0, 0, 1, 0), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.neq.unc", f2, OpRaRbTaSf (4, 0, 0, 1, 0), {P2, P1, F2, F3}, PSEUDO, 0, NULL},
+ {"fcmp.neq.unc.s1", f2, OpRaRbTaSf (4, 0, 0, 1, 1), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.neq.unc.s2", f2, OpRaRbTaSf (4, 0, 0, 1, 2), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.neq.unc.s3", f2, OpRaRbTaSf (4, 0, 0, 1, 3), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.nlt.unc.s0", f2, OpRaRbTaSf (4, 0, 1, 1, 0), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.nlt.unc", f2, OpRaRbTaSf (4, 0, 1, 1, 0), {P2, P1, F2, F3}, PSEUDO, 0, NULL},
+ {"fcmp.nlt.unc.s1", f2, OpRaRbTaSf (4, 0, 1, 1, 1), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.nlt.unc.s2", f2, OpRaRbTaSf (4, 0, 1, 1, 2), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.nlt.unc.s3", f2, OpRaRbTaSf (4, 0, 1, 1, 3), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.nle.unc.s0", f2, OpRaRbTaSf (4, 1, 0, 1, 0), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.nle.unc", f2, OpRaRbTaSf (4, 1, 0, 1, 0), {P2, P1, F2, F3}, PSEUDO, 0, NULL},
+ {"fcmp.nle.unc.s1", f2, OpRaRbTaSf (4, 1, 0, 1, 1), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.nle.unc.s2", f2, OpRaRbTaSf (4, 1, 0, 1, 2), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.nle.unc.s3", f2, OpRaRbTaSf (4, 1, 0, 1, 3), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.ngt.unc.s0", f2, OpRaRbTaSf (4, 0, 1, 1, 0), {P2, P1, F3, F2}, EMPTY},
+ {"fcmp.ngt.unc", f2, OpRaRbTaSf (4, 0, 1, 1, 0), {P2, P1, F3, F2}, PSEUDO, 0, NULL},
+ {"fcmp.ngt.unc.s1", f2, OpRaRbTaSf (4, 0, 1, 1, 1), {P2, P1, F3, F2}, EMPTY},
+ {"fcmp.ngt.unc.s2", f2, OpRaRbTaSf (4, 0, 1, 1, 2), {P2, P1, F3, F2}, EMPTY},
+ {"fcmp.ngt.unc.s3", f2, OpRaRbTaSf (4, 0, 1, 1, 3), {P2, P1, F3, F2}, EMPTY},
+ {"fcmp.nge.unc.s0", f2, OpRaRbTaSf (4, 1, 0, 1, 0), {P2, P1, F3, F2}, EMPTY},
+ {"fcmp.nge.unc", f2, OpRaRbTaSf (4, 1, 0, 1, 0), {P2, P1, F3, F2}, PSEUDO, 0, NULL},
+ {"fcmp.nge.unc.s1", f2, OpRaRbTaSf (4, 1, 0, 1, 1), {P2, P1, F3, F2}, EMPTY},
+ {"fcmp.nge.unc.s2", f2, OpRaRbTaSf (4, 1, 0, 1, 2), {P2, P1, F3, F2}, EMPTY},
+ {"fcmp.nge.unc.s3", f2, OpRaRbTaSf (4, 1, 0, 1, 3), {P2, P1, F3, F2}, EMPTY},
+ {"fcmp.ord.unc.s0", f2, OpRaRbTaSf (4, 1, 1, 1, 0), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.ord.unc", f2, OpRaRbTaSf (4, 1, 1, 1, 0), {P2, P1, F2, F3}, PSEUDO, 0, NULL},
+ {"fcmp.ord.unc.s1", f2, OpRaRbTaSf (4, 1, 1, 1, 1), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.ord.unc.s2", f2, OpRaRbTaSf (4, 1, 1, 1, 2), {P2, P1, F2, F3}, EMPTY},
+ {"fcmp.ord.unc.s3", f2, OpRaRbTaSf (4, 1, 1, 1, 3), {P2, P1, F2, F3}, EMPTY},
+
+ {"fclass.m", f2, OpTa (5, 0), {P1, P2, F2, IMMU9}, EMPTY},
+ {"fclass.nm", f2, OpTa (5, 0), {P2, P1, F2, IMMU9}, PSEUDO, 0, NULL},
+ {"fclass.m.unc", f2, OpTa (5, 1), {P1, P2, F2, IMMU9}, EMPTY},
+ {"fclass.nm.unc", f2, OpTa (5, 1), {P2, P1, F2, IMMU9}, PSEUDO, 0, NULL},
/* note: fnorm and fcvt.xuf have identical encodings! */
- {"fnorm.s0", f, OpXaSfF2F4 (0x8, 0, 0, 0, 1), {F1, F3}, PSEUDO},
- {"fnorm", f, OpXaSfF2F4 (0x8, 0, 0, 0, 1), {F1, F3}, PSEUDO},
- {"fnorm.s1", f, OpXaSfF2F4 (0x8, 0, 1, 0, 1), {F1, F3}, PSEUDO},
- {"fnorm.s2", f, OpXaSfF2F4 (0x8, 0, 2, 0, 1), {F1, F3}, PSEUDO},
- {"fnorm.s3", f, OpXaSfF2F4 (0x8, 0, 3, 0, 1), {F1, F3}, PSEUDO},
- {"fnorm.s.s0", f, OpXaSfF2F4 (0x8, 1, 0, 0, 1), {F1, F3}, PSEUDO},
- {"fnorm.s", f, OpXaSfF2F4 (0x8, 1, 0, 0, 1), {F1, F3}, PSEUDO},
- {"fnorm.s.s1", f, OpXaSfF2F4 (0x8, 1, 1, 0, 1), {F1, F3}, PSEUDO},
- {"fnorm.s.s2", f, OpXaSfF2F4 (0x8, 1, 2, 0, 1), {F1, F3}, PSEUDO},
- {"fnorm.s.s3", f, OpXaSfF2F4 (0x8, 1, 3, 0, 1), {F1, F3}, PSEUDO},
- {"fcvt.xuf.s0", f, OpXaSfF2F4 (0x8, 0, 0, 0, 1), {F1, F3}, PSEUDO},
- {"fcvt.xuf", f, OpXaSfF2F4 (0x8, 0, 0, 0, 1), {F1, F3}, PSEUDO},
- {"fcvt.xuf.s1", f, OpXaSfF2F4 (0x8, 0, 1, 0, 1), {F1, F3}, PSEUDO},
- {"fcvt.xuf.s2", f, OpXaSfF2F4 (0x8, 0, 2, 0, 1), {F1, F3}, PSEUDO},
- {"fcvt.xuf.s3", f, OpXaSfF2F4 (0x8, 0, 3, 0, 1), {F1, F3}, PSEUDO},
- {"fcvt.xuf.s.s0", f, OpXaSfF2F4 (0x8, 1, 0, 0, 1), {F1, F3}, PSEUDO},
- {"fcvt.xuf.s", f, OpXaSfF2F4 (0x8, 1, 0, 0, 1), {F1, F3}, PSEUDO},
- {"fcvt.xuf.s.s1", f, OpXaSfF2F4 (0x8, 1, 1, 0, 1), {F1, F3}, PSEUDO},
- {"fcvt.xuf.s.s2", f, OpXaSfF2F4 (0x8, 1, 2, 0, 1), {F1, F3}, PSEUDO},
- {"fcvt.xuf.s.s3", f, OpXaSfF2F4 (0x8, 1, 3, 0, 1), {F1, F3}, PSEUDO},
- {"fadd.s0", f, OpXaSfF4 (0x8, 0, 0, 1), {F1, F3, F2}, PSEUDO},
- {"fadd", f, OpXaSfF4 (0x8, 0, 0, 1), {F1, F3, F2}, PSEUDO},
- {"fadd.s1", f, OpXaSfF4 (0x8, 0, 1, 1), {F1, F3, F2}, PSEUDO},
- {"fadd.s2", f, OpXaSfF4 (0x8, 0, 2, 1), {F1, F3, F2}, PSEUDO},
- {"fadd.s3", f, OpXaSfF4 (0x8, 0, 3, 1), {F1, F3, F2}, PSEUDO},
- {"fadd.s.s0", f, OpXaSfF4 (0x8, 1, 0, 1), {F1, F3, F2}, PSEUDO},
- {"fadd.s", f, OpXaSfF4 (0x8, 1, 0, 1), {F1, F3, F2}, PSEUDO},
- {"fadd.s.s1", f, OpXaSfF4 (0x8, 1, 1, 1), {F1, F3, F2}, PSEUDO},
- {"fadd.s.s2", f, OpXaSfF4 (0x8, 1, 2, 1), {F1, F3, F2}, PSEUDO},
- {"fadd.s.s3", f, OpXaSfF4 (0x8, 1, 3, 1), {F1, F3, F2}, PSEUDO},
- {"fmpy.s0", f, OpXaSfF2 (0x8, 0, 0, 0), {F1, F3, F4}, PSEUDO},
- {"fmpy", f, OpXaSfF2 (0x8, 0, 0, 0), {F1, F3, F4}, PSEUDO},
- {"fmpy.s1", f, OpXaSfF2 (0x8, 0, 1, 0), {F1, F3, F4}, PSEUDO},
- {"fmpy.s2", f, OpXaSfF2 (0x8, 0, 2, 0), {F1, F3, F4}, PSEUDO},
- {"fmpy.s3", f, OpXaSfF2 (0x8, 0, 3, 0), {F1, F3, F4}, PSEUDO},
- {"fmpy.s.s0", f, OpXaSfF2 (0x8, 1, 0, 0), {F1, F3, F4}, PSEUDO},
- {"fmpy.s", f, OpXaSfF2 (0x8, 1, 0, 0), {F1, F3, F4}, PSEUDO},
- {"fmpy.s.s1", f, OpXaSfF2 (0x8, 1, 1, 0), {F1, F3, F4}, PSEUDO},
- {"fmpy.s.s2", f, OpXaSfF2 (0x8, 1, 2, 0), {F1, F3, F4}, PSEUDO},
- {"fmpy.s.s3", f, OpXaSfF2 (0x8, 1, 3, 0), {F1, F3, F4}, PSEUDO},
- {"fma.s0", f, OpXaSf (0x8, 0, 0), {F1, F3, F4, F2}},
- {"fma", f, OpXaSf (0x8, 0, 0), {F1, F3, F4, F2}, PSEUDO},
- {"fma.s1", f, OpXaSf (0x8, 0, 1), {F1, F3, F4, F2}},
- {"fma.s2", f, OpXaSf (0x8, 0, 2), {F1, F3, F4, F2}},
- {"fma.s3", f, OpXaSf (0x8, 0, 3), {F1, F3, F4, F2}},
- {"fma.s.s0", f, OpXaSf (0x8, 1, 0), {F1, F3, F4, F2}},
- {"fma.s", f, OpXaSf (0x8, 1, 0), {F1, F3, F4, F2}, PSEUDO},
- {"fma.s.s1", f, OpXaSf (0x8, 1, 1), {F1, F3, F4, F2}},
- {"fma.s.s2", f, OpXaSf (0x8, 1, 2), {F1, F3, F4, F2}},
- {"fma.s.s3", f, OpXaSf (0x8, 1, 3), {F1, F3, F4, F2}},
-
- {"fnorm.d.s0", f, OpXaSfF2F4 (0x9, 0, 0, 0, 1), {F1, F3}, PSEUDO},
- {"fnorm.d", f, OpXaSfF2F4 (0x9, 0, 0, 0, 1), {F1, F3}, PSEUDO},
- {"fnorm.d.s1", f, OpXaSfF2F4 (0x9, 0, 1, 0, 1), {F1, F3}, PSEUDO},
- {"fnorm.d.s2", f, OpXaSfF2F4 (0x9, 0, 2, 0, 1), {F1, F3}, PSEUDO},
- {"fnorm.d.s3", f, OpXaSfF2F4 (0x9, 0, 3, 0, 1), {F1, F3}, PSEUDO},
- {"fcvt.xuf.d.s0", f, OpXaSfF2F4 (0x9, 0, 0, 0, 1), {F1, F3}, PSEUDO},
- {"fcvt.xuf.d", f, OpXaSfF2F4 (0x9, 0, 0, 0, 1), {F1, F3}, PSEUDO},
- {"fcvt.xuf.d.s1", f, OpXaSfF2F4 (0x9, 0, 1, 0, 1), {F1, F3}, PSEUDO},
- {"fcvt.xuf.d.s2", f, OpXaSfF2F4 (0x9, 0, 2, 0, 1), {F1, F3}, PSEUDO},
- {"fcvt.xuf.d.s3", f, OpXaSfF2F4 (0x9, 0, 3, 0, 1), {F1, F3}, PSEUDO},
- {"fadd.d.s0", f, OpXaSfF4 (0x9, 0, 0, 1), {F1, F3, F2}, PSEUDO},
- {"fadd.d", f, OpXaSfF4 (0x9, 0, 0, 1), {F1, F3, F2}, PSEUDO},
- {"fadd.d.s1", f, OpXaSfF4 (0x9, 0, 1, 1), {F1, F3, F2}, PSEUDO},
- {"fadd.d.s2", f, OpXaSfF4 (0x9, 0, 2, 1), {F1, F3, F2}, PSEUDO},
- {"fadd.d.s3", f, OpXaSfF4 (0x9, 0, 3, 1), {F1, F3, F2}, PSEUDO},
- {"fmpy.d.s0", f, OpXaSfF2 (0x9, 0, 0, 0), {F1, F3, F4}, PSEUDO},
- {"fmpy.d", f, OpXaSfF2 (0x9, 0, 0, 0), {F1, F3, F4}, PSEUDO},
- {"fmpy.d.s1", f, OpXaSfF2 (0x9, 0, 1, 0), {F1, F3, F4}, PSEUDO},
- {"fmpy.d.s2", f, OpXaSfF2 (0x9, 0, 2, 0), {F1, F3, F4}, PSEUDO},
- {"fmpy.d.s3", f, OpXaSfF2 (0x9, 0, 3, 0), {F1, F3, F4}, PSEUDO},
- {"fma.d.s0", f, OpXaSf (0x9, 0, 0), {F1, F3, F4, F2}},
- {"fma.d", f, OpXaSf (0x9, 0, 0), {F1, F3, F4, F2}, PSEUDO},
- {"fma.d.s1", f, OpXaSf (0x9, 0, 1), {F1, F3, F4, F2}},
- {"fma.d.s2", f, OpXaSf (0x9, 0, 2), {F1, F3, F4, F2}},
- {"fma.d.s3", f, OpXaSf (0x9, 0, 3), {F1, F3, F4, F2}},
-
- {"fpmpy.s0", f, OpXaSfF2 (0x9, 1, 0, 0), {F1, F3, F4}, PSEUDO},
- {"fpmpy", f, OpXaSfF2 (0x9, 1, 0, 0), {F1, F3, F4}, PSEUDO},
- {"fpmpy.s1", f, OpXaSfF2 (0x9, 1, 1, 0), {F1, F3, F4}, PSEUDO},
- {"fpmpy.s2", f, OpXaSfF2 (0x9, 1, 2, 0), {F1, F3, F4}, PSEUDO},
- {"fpmpy.s3", f, OpXaSfF2 (0x9, 1, 3, 0), {F1, F3, F4}, PSEUDO},
- {"fpma.s0", f, OpXaSf (0x9, 1, 0), {F1, F3, F4, F2}},
- {"fpma", f, OpXaSf (0x9, 1, 0), {F1, F3, F4, F2}, PSEUDO},
- {"fpma.s1", f, OpXaSf (0x9, 1, 1), {F1, F3, F4, F2}},
- {"fpma.s2", f, OpXaSf (0x9, 1, 2), {F1, F3, F4, F2}},
- {"fpma.s3", f, OpXaSf (0x9, 1, 3), {F1, F3, F4, F2}},
-
- {"fsub.s0", f, OpXaSfF4 (0xa, 0, 0, 1), {F1, F3, F2}, PSEUDO},
- {"fsub", f, OpXaSfF4 (0xa, 0, 0, 1), {F1, F3, F2}, PSEUDO},
- {"fsub.s1", f, OpXaSfF4 (0xa, 0, 1, 1), {F1, F3, F2}, PSEUDO},
- {"fsub.s2", f, OpXaSfF4 (0xa, 0, 2, 1), {F1, F3, F2}, PSEUDO},
- {"fsub.s3", f, OpXaSfF4 (0xa, 0, 3, 1), {F1, F3, F2}, PSEUDO},
- {"fsub.s.s0", f, OpXaSfF4 (0xa, 1, 0, 1), {F1, F3, F2}, PSEUDO},
- {"fsub.s", f, OpXaSfF4 (0xa, 1, 0, 1), {F1, F3, F2}, PSEUDO},
- {"fsub.s.s1", f, OpXaSfF4 (0xa, 1, 1, 1), {F1, F3, F2}, PSEUDO},
- {"fsub.s.s2", f, OpXaSfF4 (0xa, 1, 2, 1), {F1, F3, F2}, PSEUDO},
- {"fsub.s.s3", f, OpXaSfF4 (0xa, 1, 3, 1), {F1, F3, F2}, PSEUDO},
- {"fms.s0", f, OpXaSf (0xa, 0, 0), {F1, F3, F4, F2}},
- {"fms", f, OpXaSf (0xa, 0, 0), {F1, F3, F4, F2}, PSEUDO},
- {"fms.s1", f, OpXaSf (0xa, 0, 1), {F1, F3, F4, F2}},
- {"fms.s2", f, OpXaSf (0xa, 0, 2), {F1, F3, F4, F2}},
- {"fms.s3", f, OpXaSf (0xa, 0, 3), {F1, F3, F4, F2}},
- {"fms.s.s0", f, OpXaSf (0xa, 1, 0), {F1, F3, F4, F2}},
- {"fms.s", f, OpXaSf (0xa, 1, 0), {F1, F3, F4, F2}, PSEUDO},
- {"fms.s.s1", f, OpXaSf (0xa, 1, 1), {F1, F3, F4, F2}},
- {"fms.s.s2", f, OpXaSf (0xa, 1, 2), {F1, F3, F4, F2}},
- {"fms.s.s3", f, OpXaSf (0xa, 1, 3), {F1, F3, F4, F2}},
- {"fsub.d.s0", f, OpXaSfF4 (0xb, 0, 0, 1), {F1, F3, F2}, PSEUDO},
- {"fsub.d", f, OpXaSfF4 (0xb, 0, 0, 1), {F1, F3, F2}, PSEUDO},
- {"fsub.d.s1", f, OpXaSfF4 (0xb, 0, 1, 1), {F1, F3, F2}, PSEUDO},
- {"fsub.d.s2", f, OpXaSfF4 (0xb, 0, 2, 1), {F1, F3, F2}, PSEUDO},
- {"fsub.d.s3", f, OpXaSfF4 (0xb, 0, 3, 1), {F1, F3, F2}, PSEUDO},
- {"fms.d.s0", f, OpXaSf (0xb, 0, 0), {F1, F3, F4, F2}},
- {"fms.d", f, OpXaSf (0xb, 0, 0), {F1, F3, F4, F2}, PSEUDO},
- {"fms.d.s1", f, OpXaSf (0xb, 0, 1), {F1, F3, F4, F2}},
- {"fms.d.s2", f, OpXaSf (0xb, 0, 2), {F1, F3, F4, F2}},
- {"fms.d.s3", f, OpXaSf (0xb, 0, 3), {F1, F3, F4, F2}},
-
- {"fpms.s0", f, OpXaSf (0xb, 1, 0), {F1, F3, F4, F2}},
- {"fpms", f, OpXaSf (0xb, 1, 0), {F1, F3, F4, F2}, PSEUDO},
- {"fpms.s1", f, OpXaSf (0xb, 1, 1), {F1, F3, F4, F2}},
- {"fpms.s2", f, OpXaSf (0xb, 1, 2), {F1, F3, F4, F2}},
- {"fpms.s3", f, OpXaSf (0xb, 1, 3), {F1, F3, F4, F2}},
-
- {"fnmpy.s0", f, OpXaSfF2 (0xc, 0, 0, 0), {F1, F3, F4}, PSEUDO},
- {"fnmpy", f, OpXaSfF2 (0xc, 0, 0, 0), {F1, F3, F4}, PSEUDO},
- {"fnmpy.s1", f, OpXaSfF2 (0xc, 0, 1, 0), {F1, F3, F4}, PSEUDO},
- {"fnmpy.s2", f, OpXaSfF2 (0xc, 0, 2, 0), {F1, F3, F4}, PSEUDO},
- {"fnmpy.s3", f, OpXaSfF2 (0xc, 0, 3, 0), {F1, F3, F4}, PSEUDO},
- {"fnmpy.s.s0", f, OpXaSfF2 (0xc, 1, 0, 0), {F1, F3, F4}, PSEUDO},
- {"fnmpy.s", f, OpXaSfF2 (0xc, 1, 0, 0), {F1, F3, F4}, PSEUDO},
- {"fnmpy.s.s1", f, OpXaSfF2 (0xc, 1, 1, 0), {F1, F3, F4}, PSEUDO},
- {"fnmpy.s.s2", f, OpXaSfF2 (0xc, 1, 2, 0), {F1, F3, F4}, PSEUDO},
- {"fnmpy.s.s3", f, OpXaSfF2 (0xc, 1, 3, 0), {F1, F3, F4}, PSEUDO},
- {"fnma.s0", f, OpXaSf (0xc, 0, 0), {F1, F3, F4, F2}},
- {"fnma", f, OpXaSf (0xc, 0, 0), {F1, F3, F4, F2}, PSEUDO},
- {"fnma.s1", f, OpXaSf (0xc, 0, 1), {F1, F3, F4, F2}},
- {"fnma.s2", f, OpXaSf (0xc, 0, 2), {F1, F3, F4, F2}},
- {"fnma.s3", f, OpXaSf (0xc, 0, 3), {F1, F3, F4, F2}},
- {"fnma.s.s0", f, OpXaSf (0xc, 1, 0), {F1, F3, F4, F2}},
- {"fnma.s", f, OpXaSf (0xc, 1, 0), {F1, F3, F4, F2}, PSEUDO},
- {"fnma.s.s1", f, OpXaSf (0xc, 1, 1), {F1, F3, F4, F2}},
- {"fnma.s.s2", f, OpXaSf (0xc, 1, 2), {F1, F3, F4, F2}},
- {"fnma.s.s3", f, OpXaSf (0xc, 1, 3), {F1, F3, F4, F2}},
- {"fnmpy.d.s0", f, OpXaSfF2 (0xd, 0, 0, 0), {F1, F3, F4}, PSEUDO},
- {"fnmpy.d", f, OpXaSfF2 (0xd, 0, 0, 0), {F1, F3, F4}, PSEUDO},
- {"fnmpy.d.s1", f, OpXaSfF2 (0xd, 0, 1, 0), {F1, F3, F4}, PSEUDO},
- {"fnmpy.d.s2", f, OpXaSfF2 (0xd, 0, 2, 0), {F1, F3, F4}, PSEUDO},
- {"fnmpy.d.s3", f, OpXaSfF2 (0xd, 0, 3, 0), {F1, F3, F4}, PSEUDO},
- {"fnma.d.s0", f, OpXaSf (0xd, 0, 0), {F1, F3, F4, F2}},
- {"fnma.d", f, OpXaSf (0xd, 0, 0), {F1, F3, F4, F2}, PSEUDO},
- {"fnma.d.s1", f, OpXaSf (0xd, 0, 1), {F1, F3, F4, F2}},
- {"fnma.d.s2", f, OpXaSf (0xd, 0, 2), {F1, F3, F4, F2}},
- {"fnma.d.s3", f, OpXaSf (0xd, 0, 3), {F1, F3, F4, F2}},
-
- {"fpnmpy.s0", f, OpXaSfF2 (0xd, 1, 0, 0), {F1, F3, F4}, PSEUDO},
- {"fpnmpy", f, OpXaSfF2 (0xd, 1, 0, 0), {F1, F3, F4}, PSEUDO},
- {"fpnmpy.s1", f, OpXaSfF2 (0xd, 1, 1, 0), {F1, F3, F4}, PSEUDO},
- {"fpnmpy.s2", f, OpXaSfF2 (0xd, 1, 2, 0), {F1, F3, F4}, PSEUDO},
- {"fpnmpy.s3", f, OpXaSfF2 (0xd, 1, 3, 0), {F1, F3, F4}, PSEUDO},
- {"fpnma.s0", f, OpXaSf (0xd, 1, 0), {F1, F3, F4, F2}},
- {"fpnma", f, OpXaSf (0xd, 1, 0), {F1, F3, F4, F2}, PSEUDO},
- {"fpnma.s1", f, OpXaSf (0xd, 1, 1), {F1, F3, F4, F2}},
- {"fpnma.s2", f, OpXaSf (0xd, 1, 2), {F1, F3, F4, F2}},
- {"fpnma.s3", f, OpXaSf (0xd, 1, 3), {F1, F3, F4, F2}},
-
- {"xmpy.l", f, OpXaX2F2 (0xe, 1, 0, 0), {F1, F3, F4}, PSEUDO},
- {"xmpy.lu", f, OpXaX2F2 (0xe, 1, 0, 0), {F1, F3, F4}, PSEUDO},
- {"xmpy.h", f, OpXaX2F2 (0xe, 1, 3, 0), {F1, F3, F4}, PSEUDO},
- {"xmpy.hu", f, OpXaX2F2 (0xe, 1, 2, 0), {F1, F3, F4}, PSEUDO},
- {"xma.l", f, OpXaX2 (0xe, 1, 0), {F1, F3, F4, F2}},
- {"xma.lu", f, OpXaX2 (0xe, 1, 0), {F1, F3, F4, F2}, PSEUDO},
- {"xma.h", f, OpXaX2 (0xe, 1, 3), {F1, F3, F4, F2}},
- {"xma.hu", f, OpXaX2 (0xe, 1, 2), {F1, F3, F4, F2}},
-
- {"fselect", f, OpXa (0xe, 0), {F1, F3, F4, F2}},
-
- {0}
+ {"fnorm.s0", f, OpXaSfF2F4 (0x8, 0, 0, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fnorm", f, OpXaSfF2F4 (0x8, 0, 0, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fnorm.s1", f, OpXaSfF2F4 (0x8, 0, 1, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fnorm.s2", f, OpXaSfF2F4 (0x8, 0, 2, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fnorm.s3", f, OpXaSfF2F4 (0x8, 0, 3, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fnorm.s.s0", f, OpXaSfF2F4 (0x8, 1, 0, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fnorm.s", f, OpXaSfF2F4 (0x8, 1, 0, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fnorm.s.s1", f, OpXaSfF2F4 (0x8, 1, 1, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fnorm.s.s2", f, OpXaSfF2F4 (0x8, 1, 2, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fnorm.s.s3", f, OpXaSfF2F4 (0x8, 1, 3, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fcvt.xuf.s0", f, OpXaSfF2F4 (0x8, 0, 0, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fcvt.xuf", f, OpXaSfF2F4 (0x8, 0, 0, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fcvt.xuf.s1", f, OpXaSfF2F4 (0x8, 0, 1, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fcvt.xuf.s2", f, OpXaSfF2F4 (0x8, 0, 2, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fcvt.xuf.s3", f, OpXaSfF2F4 (0x8, 0, 3, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fcvt.xuf.s.s0", f, OpXaSfF2F4 (0x8, 1, 0, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fcvt.xuf.s", f, OpXaSfF2F4 (0x8, 1, 0, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fcvt.xuf.s.s1", f, OpXaSfF2F4 (0x8, 1, 1, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fcvt.xuf.s.s2", f, OpXaSfF2F4 (0x8, 1, 2, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fcvt.xuf.s.s3", f, OpXaSfF2F4 (0x8, 1, 3, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fadd.s0", f, OpXaSfF4 (0x8, 0, 0, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fadd", f, OpXaSfF4 (0x8, 0, 0, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fadd.s1", f, OpXaSfF4 (0x8, 0, 1, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fadd.s2", f, OpXaSfF4 (0x8, 0, 2, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fadd.s3", f, OpXaSfF4 (0x8, 0, 3, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fadd.s.s0", f, OpXaSfF4 (0x8, 1, 0, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fadd.s", f, OpXaSfF4 (0x8, 1, 0, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fadd.s.s1", f, OpXaSfF4 (0x8, 1, 1, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fadd.s.s2", f, OpXaSfF4 (0x8, 1, 2, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fadd.s.s3", f, OpXaSfF4 (0x8, 1, 3, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fmpy.s0", f, OpXaSfF2 (0x8, 0, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fmpy", f, OpXaSfF2 (0x8, 0, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fmpy.s1", f, OpXaSfF2 (0x8, 0, 1, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fmpy.s2", f, OpXaSfF2 (0x8, 0, 2, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fmpy.s3", f, OpXaSfF2 (0x8, 0, 3, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fmpy.s.s0", f, OpXaSfF2 (0x8, 1, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fmpy.s", f, OpXaSfF2 (0x8, 1, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fmpy.s.s1", f, OpXaSfF2 (0x8, 1, 1, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fmpy.s.s2", f, OpXaSfF2 (0x8, 1, 2, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fmpy.s.s3", f, OpXaSfF2 (0x8, 1, 3, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fma.s0", f, OpXaSf (0x8, 0, 0), {F1, F3, F4, F2}, EMPTY},
+ {"fma", f, OpXaSf (0x8, 0, 0), {F1, F3, F4, F2}, PSEUDO, 0, NULL},
+ {"fma.s1", f, OpXaSf (0x8, 0, 1), {F1, F3, F4, F2}, EMPTY},
+ {"fma.s2", f, OpXaSf (0x8, 0, 2), {F1, F3, F4, F2}, EMPTY},
+ {"fma.s3", f, OpXaSf (0x8, 0, 3), {F1, F3, F4, F2}, EMPTY},
+ {"fma.s.s0", f, OpXaSf (0x8, 1, 0), {F1, F3, F4, F2}, EMPTY},
+ {"fma.s", f, OpXaSf (0x8, 1, 0), {F1, F3, F4, F2}, PSEUDO, 0, NULL},
+ {"fma.s.s1", f, OpXaSf (0x8, 1, 1), {F1, F3, F4, F2}, EMPTY},
+ {"fma.s.s2", f, OpXaSf (0x8, 1, 2), {F1, F3, F4, F2}, EMPTY},
+ {"fma.s.s3", f, OpXaSf (0x8, 1, 3), {F1, F3, F4, F2}, EMPTY},
+
+ {"fnorm.d.s0", f, OpXaSfF2F4 (0x9, 0, 0, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fnorm.d", f, OpXaSfF2F4 (0x9, 0, 0, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fnorm.d.s1", f, OpXaSfF2F4 (0x9, 0, 1, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fnorm.d.s2", f, OpXaSfF2F4 (0x9, 0, 2, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fnorm.d.s3", f, OpXaSfF2F4 (0x9, 0, 3, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fcvt.xuf.d.s0", f, OpXaSfF2F4 (0x9, 0, 0, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fcvt.xuf.d", f, OpXaSfF2F4 (0x9, 0, 0, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fcvt.xuf.d.s1", f, OpXaSfF2F4 (0x9, 0, 1, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fcvt.xuf.d.s2", f, OpXaSfF2F4 (0x9, 0, 2, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fcvt.xuf.d.s3", f, OpXaSfF2F4 (0x9, 0, 3, 0, 1), {F1, F3}, PSEUDO, 0, NULL},
+ {"fadd.d.s0", f, OpXaSfF4 (0x9, 0, 0, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fadd.d", f, OpXaSfF4 (0x9, 0, 0, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fadd.d.s1", f, OpXaSfF4 (0x9, 0, 1, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fadd.d.s2", f, OpXaSfF4 (0x9, 0, 2, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fadd.d.s3", f, OpXaSfF4 (0x9, 0, 3, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fmpy.d.s0", f, OpXaSfF2 (0x9, 0, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fmpy.d", f, OpXaSfF2 (0x9, 0, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fmpy.d.s1", f, OpXaSfF2 (0x9, 0, 1, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fmpy.d.s2", f, OpXaSfF2 (0x9, 0, 2, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fmpy.d.s3", f, OpXaSfF2 (0x9, 0, 3, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fma.d.s0", f, OpXaSf (0x9, 0, 0), {F1, F3, F4, F2}, EMPTY},
+ {"fma.d", f, OpXaSf (0x9, 0, 0), {F1, F3, F4, F2}, PSEUDO, 0, NULL},
+ {"fma.d.s1", f, OpXaSf (0x9, 0, 1), {F1, F3, F4, F2}, EMPTY},
+ {"fma.d.s2", f, OpXaSf (0x9, 0, 2), {F1, F3, F4, F2}, EMPTY},
+ {"fma.d.s3", f, OpXaSf (0x9, 0, 3), {F1, F3, F4, F2}, EMPTY},
+
+ {"fpmpy.s0", f, OpXaSfF2 (0x9, 1, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fpmpy", f, OpXaSfF2 (0x9, 1, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fpmpy.s1", f, OpXaSfF2 (0x9, 1, 1, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fpmpy.s2", f, OpXaSfF2 (0x9, 1, 2, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fpmpy.s3", f, OpXaSfF2 (0x9, 1, 3, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fpma.s0", f, OpXaSf (0x9, 1, 0), {F1, F3, F4, F2}, EMPTY},
+ {"fpma", f, OpXaSf (0x9, 1, 0), {F1, F3, F4, F2}, PSEUDO, 0, NULL},
+ {"fpma.s1", f, OpXaSf (0x9, 1, 1), {F1, F3, F4, F2}, EMPTY},
+ {"fpma.s2", f, OpXaSf (0x9, 1, 2), {F1, F3, F4, F2}, EMPTY},
+ {"fpma.s3", f, OpXaSf (0x9, 1, 3), {F1, F3, F4, F2}, EMPTY},
+
+ {"fsub.s0", f, OpXaSfF4 (0xa, 0, 0, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fsub", f, OpXaSfF4 (0xa, 0, 0, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fsub.s1", f, OpXaSfF4 (0xa, 0, 1, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fsub.s2", f, OpXaSfF4 (0xa, 0, 2, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fsub.s3", f, OpXaSfF4 (0xa, 0, 3, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fsub.s.s0", f, OpXaSfF4 (0xa, 1, 0, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fsub.s", f, OpXaSfF4 (0xa, 1, 0, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fsub.s.s1", f, OpXaSfF4 (0xa, 1, 1, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fsub.s.s2", f, OpXaSfF4 (0xa, 1, 2, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fsub.s.s3", f, OpXaSfF4 (0xa, 1, 3, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fms.s0", f, OpXaSf (0xa, 0, 0), {F1, F3, F4, F2}, EMPTY},
+ {"fms", f, OpXaSf (0xa, 0, 0), {F1, F3, F4, F2}, PSEUDO, 0, NULL},
+ {"fms.s1", f, OpXaSf (0xa, 0, 1), {F1, F3, F4, F2}, EMPTY},
+ {"fms.s2", f, OpXaSf (0xa, 0, 2), {F1, F3, F4, F2}, EMPTY},
+ {"fms.s3", f, OpXaSf (0xa, 0, 3), {F1, F3, F4, F2}, EMPTY},
+ {"fms.s.s0", f, OpXaSf (0xa, 1, 0), {F1, F3, F4, F2}, EMPTY},
+ {"fms.s", f, OpXaSf (0xa, 1, 0), {F1, F3, F4, F2}, PSEUDO, 0, NULL},
+ {"fms.s.s1", f, OpXaSf (0xa, 1, 1), {F1, F3, F4, F2}, EMPTY},
+ {"fms.s.s2", f, OpXaSf (0xa, 1, 2), {F1, F3, F4, F2}, EMPTY},
+ {"fms.s.s3", f, OpXaSf (0xa, 1, 3), {F1, F3, F4, F2}, EMPTY},
+ {"fsub.d.s0", f, OpXaSfF4 (0xb, 0, 0, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fsub.d", f, OpXaSfF4 (0xb, 0, 0, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fsub.d.s1", f, OpXaSfF4 (0xb, 0, 1, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fsub.d.s2", f, OpXaSfF4 (0xb, 0, 2, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fsub.d.s3", f, OpXaSfF4 (0xb, 0, 3, 1), {F1, F3, F2}, PSEUDO, 0, NULL},
+ {"fms.d.s0", f, OpXaSf (0xb, 0, 0), {F1, F3, F4, F2}, EMPTY},
+ {"fms.d", f, OpXaSf (0xb, 0, 0), {F1, F3, F4, F2}, PSEUDO, 0, NULL},
+ {"fms.d.s1", f, OpXaSf (0xb, 0, 1), {F1, F3, F4, F2}, EMPTY},
+ {"fms.d.s2", f, OpXaSf (0xb, 0, 2), {F1, F3, F4, F2}, EMPTY},
+ {"fms.d.s3", f, OpXaSf (0xb, 0, 3), {F1, F3, F4, F2}, EMPTY},
+
+ {"fpms.s0", f, OpXaSf (0xb, 1, 0), {F1, F3, F4, F2}, EMPTY},
+ {"fpms", f, OpXaSf (0xb, 1, 0), {F1, F3, F4, F2}, PSEUDO, 0, NULL},
+ {"fpms.s1", f, OpXaSf (0xb, 1, 1), {F1, F3, F4, F2}, EMPTY},
+ {"fpms.s2", f, OpXaSf (0xb, 1, 2), {F1, F3, F4, F2}, EMPTY},
+ {"fpms.s3", f, OpXaSf (0xb, 1, 3), {F1, F3, F4, F2}, EMPTY},
+
+ {"fnmpy.s0", f, OpXaSfF2 (0xc, 0, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fnmpy", f, OpXaSfF2 (0xc, 0, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fnmpy.s1", f, OpXaSfF2 (0xc, 0, 1, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fnmpy.s2", f, OpXaSfF2 (0xc, 0, 2, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fnmpy.s3", f, OpXaSfF2 (0xc, 0, 3, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fnmpy.s.s0", f, OpXaSfF2 (0xc, 1, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fnmpy.s", f, OpXaSfF2 (0xc, 1, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fnmpy.s.s1", f, OpXaSfF2 (0xc, 1, 1, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fnmpy.s.s2", f, OpXaSfF2 (0xc, 1, 2, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fnmpy.s.s3", f, OpXaSfF2 (0xc, 1, 3, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fnma.s0", f, OpXaSf (0xc, 0, 0), {F1, F3, F4, F2}, EMPTY},
+ {"fnma", f, OpXaSf (0xc, 0, 0), {F1, F3, F4, F2}, PSEUDO, 0, NULL},
+ {"fnma.s1", f, OpXaSf (0xc, 0, 1), {F1, F3, F4, F2}, EMPTY},
+ {"fnma.s2", f, OpXaSf (0xc, 0, 2), {F1, F3, F4, F2}, EMPTY},
+ {"fnma.s3", f, OpXaSf (0xc, 0, 3), {F1, F3, F4, F2}, EMPTY},
+ {"fnma.s.s0", f, OpXaSf (0xc, 1, 0), {F1, F3, F4, F2}, EMPTY},
+ {"fnma.s", f, OpXaSf (0xc, 1, 0), {F1, F3, F4, F2}, PSEUDO, 0, NULL},
+ {"fnma.s.s1", f, OpXaSf (0xc, 1, 1), {F1, F3, F4, F2}, EMPTY},
+ {"fnma.s.s2", f, OpXaSf (0xc, 1, 2), {F1, F3, F4, F2}, EMPTY},
+ {"fnma.s.s3", f, OpXaSf (0xc, 1, 3), {F1, F3, F4, F2}, EMPTY},
+ {"fnmpy.d.s0", f, OpXaSfF2 (0xd, 0, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fnmpy.d", f, OpXaSfF2 (0xd, 0, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fnmpy.d.s1", f, OpXaSfF2 (0xd, 0, 1, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fnmpy.d.s2", f, OpXaSfF2 (0xd, 0, 2, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fnmpy.d.s3", f, OpXaSfF2 (0xd, 0, 3, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fnma.d.s0", f, OpXaSf (0xd, 0, 0), {F1, F3, F4, F2}, EMPTY},
+ {"fnma.d", f, OpXaSf (0xd, 0, 0), {F1, F3, F4, F2}, PSEUDO, 0, NULL},
+ {"fnma.d.s1", f, OpXaSf (0xd, 0, 1), {F1, F3, F4, F2}, EMPTY},
+ {"fnma.d.s2", f, OpXaSf (0xd, 0, 2), {F1, F3, F4, F2}, EMPTY},
+ {"fnma.d.s3", f, OpXaSf (0xd, 0, 3), {F1, F3, F4, F2}, EMPTY},
+
+ {"fpnmpy.s0", f, OpXaSfF2 (0xd, 1, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fpnmpy", f, OpXaSfF2 (0xd, 1, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fpnmpy.s1", f, OpXaSfF2 (0xd, 1, 1, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fpnmpy.s2", f, OpXaSfF2 (0xd, 1, 2, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fpnmpy.s3", f, OpXaSfF2 (0xd, 1, 3, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"fpnma.s0", f, OpXaSf (0xd, 1, 0), {F1, F3, F4, F2}, EMPTY},
+ {"fpnma", f, OpXaSf (0xd, 1, 0), {F1, F3, F4, F2}, PSEUDO, 0, NULL},
+ {"fpnma.s1", f, OpXaSf (0xd, 1, 1), {F1, F3, F4, F2}, EMPTY},
+ {"fpnma.s2", f, OpXaSf (0xd, 1, 2), {F1, F3, F4, F2}, EMPTY},
+ {"fpnma.s3", f, OpXaSf (0xd, 1, 3), {F1, F3, F4, F2}, EMPTY},
+
+ {"xmpy.l", f, OpXaX2F2 (0xe, 1, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"xmpy.lu", f, OpXaX2F2 (0xe, 1, 0, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"xmpy.h", f, OpXaX2F2 (0xe, 1, 3, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"xmpy.hu", f, OpXaX2F2 (0xe, 1, 2, 0), {F1, F3, F4}, PSEUDO, 0, NULL},
+ {"xma.l", f, OpXaX2 (0xe, 1, 0), {F1, F3, F4, F2}, EMPTY},
+ {"xma.lu", f, OpXaX2 (0xe, 1, 0), {F1, F3, F4, F2}, PSEUDO, 0, NULL},
+ {"xma.h", f, OpXaX2 (0xe, 1, 3), {F1, F3, F4, F2}, EMPTY},
+ {"xma.hu", f, OpXaX2 (0xe, 1, 2), {F1, F3, F4, F2}, EMPTY},
+
+ {"fselect", f, OpXa (0xe, 0), {F1, F3, F4, F2}, EMPTY},
+
+ {NULL, 0, 0, 0, 0, {0}, 0, 0, NULL}
};
#undef f0
@@ -644,3 +653,4 @@ struct ia64_opcode ia64_opcodes_f[] =
#undef OpXbX6
#undef OpXbX6F2
#undef OpXbX6Sf
+#undef EMPTY
diff --git a/contrib/binutils/opcodes/ia64-opc-i.c b/contrib/binutils/opcodes/ia64-opc-i.c
index 899e651..86440f7 100644
--- a/contrib/binutils/opcodes/ia64-opc-i.c
+++ b/contrib/binutils/opcodes/ia64-opc-i.c
@@ -1,5 +1,5 @@
/* ia64-opc-i.c -- IA-64 `I' opcode table.
- Copyright 1998, 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2002 Free Software Foundation, Inc.
Contributed by David Mosberger-Tang <davidm@hpl.hp.com>
This file is part of GDB, GAS, and the GNU binutils.
@@ -86,6 +86,8 @@
#define OpX3(a,b) (bOp (a) | bX3 (b)), (mOp | mX3)
#define OpX3X6(a,b,c) (bOp (a) | bX3 (b) | bX6(c)), \
(mOp | mX3 | mX6)
+#define OpX3X6Yb(a,b,c,d) (bOp (a) | bX3 (b) | bX6(c) | bYb(d)), \
+ (mOp | mX3 | mX6 | mYb)
#define OpX3XbIhWh(a,b,c,d,e) \
(bOp (a) | bX3 (b) | bXb (c) | bIh (d) | bWh (e)), \
(mOp | mX3 | mXb | mIh | mWh)
@@ -93,17 +95,22 @@
(bOp (a) | bX3 (b) | bXb (c) | bIh (d) | bWh (e) | bTag13 (f)), \
(mOp | mX3 | mXb | mIh | mWh | mTag13)
+/* Used to initialise unused fields in ia64_opcode struct,
+ in order to stop gcc from complaining. */
+#define EMPTY 0,0,NULL
+
struct ia64_opcode ia64_opcodes_i[] =
{
- /* I-type instruction encodings (sorted according to major opcode) */
+ /* I-type instruction encodings (sorted according to major opcode). */
- {"break.i", I0, OpX3X6 (0, 0, 0x00), {IMMU21}, X_IN_MLX},
- {"nop.i", I0, OpX3X6 (0, 0, 0x01), {IMMU21}, X_IN_MLX},
- {"chk.s.i", I0, OpX3 (0, 1), {R2, TGT25b}},
+ {"break.i", I0, OpX3X6 (0, 0, 0x00), {IMMU21}, X_IN_MLX, 0, NULL},
+ {"nop.i", I0, OpX3X6Yb (0, 0, 0x01, 0), {IMMU21}, X_IN_MLX, 0, NULL},
+ {"hint.i", I0, OpX3X6Yb (0, 0, 0x01, 1), {IMMU21}, X_IN_MLX, 0, NULL},
+ {"chk.s.i", I0, OpX3 (0, 1), {R2, TGT25b}, EMPTY},
- {"mov", I, OpX3XbIhWhTag13 (0, 7, 0, 0, 1, 0), {B1, R2}, PSEUDO},
+ {"mov", I, OpX3XbIhWhTag13 (0, 7, 0, 0, 1, 0), {B1, R2}, PSEUDO, 0, NULL},
#define MOV(a,b,c,d) \
- I, OpX3XbIhWh (0, a, b, c, d), {B1, R2, TAG13b}
+ I, OpX3XbIhWh (0, a, b, c, d), {B1, R2, TAG13b}, EMPTY
{"mov.sptk", MOV (7, 0, 0, 0)},
{"mov.sptk.imp", MOV (7, 0, 1, 0)},
{"mov", MOV (7, 0, 0, 1)},
@@ -117,46 +124,46 @@ struct ia64_opcode ia64_opcodes_i[] =
{"mov.ret.dptk", MOV (7, 1, 0, 2)},
{"mov.ret.dptk.imp", MOV (7, 1, 1, 2)},
#undef MOV
- {"mov", I, OpX3X6 (0, 0, 0x31), {R1, B2}},
- {"mov", I, OpX3 (0, 3), {PR, R2, IMM17}},
- {"mov", I, OpX3 (0, 2), {PR_ROT, IMM44}},
- {"mov", I, OpX3X6 (0, 0, 0x30), {R1, IP}},
- {"mov", I, OpX3X6 (0, 0, 0x33), {R1, PR}},
- {"mov.i", I, OpX3X6 (0, 0, 0x2a), {AR3, R2}},
- {"mov.i", I, OpX3X6 (0, 0, 0x0a), {AR3, IMM8}},
- {"mov.i", I, OpX3X6 (0, 0, 0x32), {R1, AR3}},
- {"zxt1", I, OpX3X6 (0, 0, 0x10), {R1, R3}},
- {"zxt2", I, OpX3X6 (0, 0, 0x11), {R1, R3}},
- {"zxt4", I, OpX3X6 (0, 0, 0x12), {R1, R3}},
- {"sxt1", I, OpX3X6 (0, 0, 0x14), {R1, R3}},
- {"sxt2", I, OpX3X6 (0, 0, 0x15), {R1, R3}},
- {"sxt4", I, OpX3X6 (0, 0, 0x16), {R1, R3}},
- {"czx1.l", I, OpX3X6 (0, 0, 0x18), {R1, R3}},
- {"czx2.l", I, OpX3X6 (0, 0, 0x19), {R1, R3}},
- {"czx1.r", I, OpX3X6 (0, 0, 0x1c), {R1, R3}},
- {"czx2.r", I, OpX3X6 (0, 0, 0x1d), {R1, R3}},
+ {"mov", I, OpX3X6 (0, 0, 0x31), {R1, B2}, EMPTY},
+ {"mov", I, OpX3 (0, 3), {PR, R2, IMM17}, EMPTY},
+ {"mov", I, OpX3 (0, 2), {PR_ROT, IMM44}, EMPTY},
+ {"mov", I, OpX3X6 (0, 0, 0x30), {R1, IP}, EMPTY},
+ {"mov", I, OpX3X6 (0, 0, 0x33), {R1, PR}, EMPTY},
+ {"mov.i", I, OpX3X6 (0, 0, 0x2a), {AR3, R2}, EMPTY},
+ {"mov.i", I, OpX3X6 (0, 0, 0x0a), {AR3, IMM8}, EMPTY},
+ {"mov.i", I, OpX3X6 (0, 0, 0x32), {R1, AR3}, EMPTY},
+ {"zxt1", I, OpX3X6 (0, 0, 0x10), {R1, R3}, EMPTY},
+ {"zxt2", I, OpX3X6 (0, 0, 0x11), {R1, R3}, EMPTY},
+ {"zxt4", I, OpX3X6 (0, 0, 0x12), {R1, R3}, EMPTY},
+ {"sxt1", I, OpX3X6 (0, 0, 0x14), {R1, R3}, EMPTY},
+ {"sxt2", I, OpX3X6 (0, 0, 0x15), {R1, R3}, EMPTY},
+ {"sxt4", I, OpX3X6 (0, 0, 0x16), {R1, R3}, EMPTY},
+ {"czx1.l", I, OpX3X6 (0, 0, 0x18), {R1, R3}, EMPTY},
+ {"czx2.l", I, OpX3X6 (0, 0, 0x19), {R1, R3}, EMPTY},
+ {"czx1.r", I, OpX3X6 (0, 0, 0x1c), {R1, R3}, EMPTY},
+ {"czx2.r", I, OpX3X6 (0, 0, 0x1d), {R1, R3}, EMPTY},
- {"dep", I, Op (4), {R1, R2, R3, CPOS6c, LEN4}},
+ {"dep", I, Op (4), {R1, R2, R3, CPOS6c, LEN4}, EMPTY},
- {"shrp", I, OpX2X (5, 3, 0), {R1, R2, R3, CNT6}},
+ {"shrp", I, OpX2X (5, 3, 0), {R1, R2, R3, CNT6}, EMPTY},
{"shr.u", I, OpX2XYa (5, 1, 0, 0), {R1, R3, POS6},
- PSEUDO | LEN_EQ_64MCNT},
- {"extr.u", I, OpX2XYa (5, 1, 0, 0), {R1, R3, POS6, LEN6}},
+ PSEUDO | LEN_EQ_64MCNT, 0, NULL},
+ {"extr.u", I, OpX2XYa (5, 1, 0, 0), {R1, R3, POS6, LEN6}, EMPTY},
{"shr", I, OpX2XYa (5, 1, 0, 1), {R1, R3, POS6},
- PSEUDO | LEN_EQ_64MCNT},
- {"extr", I, OpX2XYa (5, 1, 0, 1), {R1, R3, POS6, LEN6}},
+ PSEUDO | LEN_EQ_64MCNT, 0, NULL},
+ {"extr", I, OpX2XYa (5, 1, 0, 1), {R1, R3, POS6, LEN6}, EMPTY},
{"shl", I, OpX2XYb (5, 1, 1, 0), {R1, R2, CPOS6a},
- PSEUDO | LEN_EQ_64MCNT},
- {"dep.z", I, OpX2XYb (5, 1, 1, 0), {R1, R2, CPOS6a, LEN6}},
- {"dep.z", I, OpX2XYb (5, 1, 1, 1), {R1, IMM8, CPOS6a, LEN6}},
- {"dep", I, OpX2X (5, 3, 1), {R1, IMM1, R3, CPOS6b, LEN6}},
+ PSEUDO | LEN_EQ_64MCNT, 0, NULL},
+ {"dep.z", I, OpX2XYb (5, 1, 1, 0), {R1, R2, CPOS6a, LEN6}, EMPTY},
+ {"dep.z", I, OpX2XYb (5, 1, 1, 1), {R1, IMM8, CPOS6a, LEN6}, EMPTY},
+ {"dep", I, OpX2X (5, 3, 1), {R1, IMM1, R3, CPOS6b, LEN6}, EMPTY},
#define TBIT(a,b,c,d) \
- I2, OpX2TaTbYaC (5, 0, a, b, c, d), {P1, P2, R3, POS6}
+ I2, OpX2TaTbYaC (5, 0, a, b, c, d), {P1, P2, R3, POS6}, EMPTY
#define TBITCM(a,b,c,d) \
- I2, OpX2TaTbYaC (5, 0, a, b, c, d), {P2, P1, R3, POS6}, PSEUDO
+ I2, OpX2TaTbYaC (5, 0, a, b, c, d), {P2, P1, R3, POS6}, PSEUDO, 0, NULL
{"tbit.z", TBIT (0, 0, 0, 0)},
{"tbit.nz", TBITCM (0, 0, 0, 0)},
{"tbit.z.unc", TBIT (0, 0, 0, 1)},
@@ -175,9 +182,9 @@ struct ia64_opcode ia64_opcodes_i[] =
{"tbit.z.and.orcm", TBITCM (1, 1, 0, 1)},
#undef TBIT
#define TNAT(a,b,c,d) \
- I2, OpX2TaTbYaC (5, 0, a, b, c, d), {P1, P2, R3}
+ I2, OpX2TaTbYaC (5, 0, a, b, c, d), {P1, P2, R3}, EMPTY
#define TNATCM(a,b,c,d) \
- I2, OpX2TaTbYaC (5, 0, a, b, c, d), {P2, P1, R3}, PSEUDO
+ I2, OpX2TaTbYaC (5, 0, a, b, c, d), {P2, P1, R3}, PSEUDO, 0, NULL
{"tnat.z", TNAT (0, 0, 1, 0)},
{"tnat.nz", TNATCM (0, 0, 1, 0)},
{"tnat.z.unc", TNAT (0, 0, 1, 1)},
@@ -196,50 +203,50 @@ struct ia64_opcode ia64_opcodes_i[] =
{"tnat.z.and.orcm", TNATCM (1, 1, 1, 1)},
#undef TNAT
- {"pmpyshr2", I, OpZaZbVeX2aX2b (7, 0, 1, 0, 0, 3), {R1, R2, R3, CNT2c}},
- {"pmpyshr2.u", I, OpZaZbVeX2aX2b (7, 0, 1, 0, 0, 1), {R1, R2, R3, CNT2c}},
- {"pmpy2.r", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 1, 3), {R1, R2, R3}},
- {"pmpy2.l", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 3, 3), {R1, R2, R3}},
- {"mix1.r", I, OpZaZbVeX2aX2bX2c (7, 0, 0, 0, 2, 0, 2), {R1, R2, R3}},
- {"mix2.r", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 0, 2), {R1, R2, R3}},
- {"mix4.r", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 2, 0, 2), {R1, R2, R3}},
- {"mix1.l", I, OpZaZbVeX2aX2bX2c (7, 0, 0, 0, 2, 2, 2), {R1, R2, R3}},
- {"mix2.l", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 2, 2), {R1, R2, R3}},
- {"mix4.l", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 2, 2, 2), {R1, R2, R3}},
- {"pack2.uss", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 0, 0), {R1, R2, R3}},
- {"pack2.sss", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 2, 0), {R1, R2, R3}},
- {"pack4.sss", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 2, 2, 0), {R1, R2, R3}},
- {"unpack1.h", I, OpZaZbVeX2aX2bX2c (7, 0, 0, 0, 2, 0, 1), {R1, R2, R3}},
- {"unpack2.h", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 0, 1), {R1, R2, R3}},
- {"unpack4.h", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 2, 0, 1), {R1, R2, R3}},
- {"unpack1.l", I, OpZaZbVeX2aX2bX2c (7, 0, 0, 0, 2, 2, 1), {R1, R2, R3}},
- {"unpack2.l", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 2, 1), {R1, R2, R3}},
- {"unpack4.l", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 2, 2, 1), {R1, R2, R3}},
- {"pmin1.u", I, OpZaZbVeX2aX2bX2c (7, 0, 0, 0, 2, 1, 0), {R1, R2, R3}},
- {"pmax1.u", I, OpZaZbVeX2aX2bX2c (7, 0, 0, 0, 2, 1, 1), {R1, R2, R3}},
- {"pmin2", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 3, 0), {R1, R2, R3}},
- {"pmax2", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 3, 1), {R1, R2, R3}},
- {"psad1", I, OpZaZbVeX2aX2bX2c (7, 0, 0, 0, 2, 3, 2), {R1, R2, R3}},
- {"mux1", I, OpZaZbVeX2aX2bX2c (7, 0, 0, 0, 3, 2, 2), {R1, R2, MBTYPE4}},
- {"mux2", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 3, 2, 2), {R1, R2, MHTYPE8}},
- {"pshr2", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 0, 2, 0), {R1, R3, R2}},
- {"pshr4", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 0, 2, 0), {R1, R3, R2}},
- {"shr", I, OpZaZbVeX2aX2bX2c (7, 1, 1, 0, 0, 2, 0), {R1, R3, R2}},
- {"pshr2.u", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 0, 0, 0), {R1, R3, R2}},
- {"pshr4.u", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 0, 0, 0), {R1, R3, R2}},
- {"shr.u", I, OpZaZbVeX2aX2bX2c (7, 1, 1, 0, 0, 0, 0), {R1, R3, R2}},
- {"pshr2", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 1, 3, 0), {R1, R3, CNT5}},
- {"pshr4", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 1, 3, 0), {R1, R3, CNT5}},
- {"pshr2.u", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 1, 1, 0), {R1, R3, CNT5}},
- {"pshr4.u", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 1, 1, 0), {R1, R3, CNT5}},
- {"pshl2", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 0, 0, 1), {R1, R2, R3}},
- {"pshl4", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 0, 0, 1), {R1, R2, R3}},
- {"shl", I, OpZaZbVeX2aX2bX2c (7, 1, 1, 0, 0, 0, 1), {R1, R2, R3}},
- {"pshl2", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 3, 1, 1), {R1, R2, CCNT5}},
- {"pshl4", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 3, 1, 1), {R1, R2, CCNT5}},
- {"popcnt", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 1, 1, 2), {R1, R3}},
+ {"pmpyshr2", I, OpZaZbVeX2aX2b (7, 0, 1, 0, 0, 3), {R1, R2, R3, CNT2c}, EMPTY},
+ {"pmpyshr2.u", I, OpZaZbVeX2aX2b (7, 0, 1, 0, 0, 1), {R1, R2, R3, CNT2c}, EMPTY},
+ {"pmpy2.r", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 1, 3), {R1, R2, R3}, EMPTY},
+ {"pmpy2.l", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 3, 3), {R1, R2, R3}, EMPTY},
+ {"mix1.r", I, OpZaZbVeX2aX2bX2c (7, 0, 0, 0, 2, 0, 2), {R1, R2, R3}, EMPTY},
+ {"mix2.r", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 0, 2), {R1, R2, R3}, EMPTY},
+ {"mix4.r", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 2, 0, 2), {R1, R2, R3}, EMPTY},
+ {"mix1.l", I, OpZaZbVeX2aX2bX2c (7, 0, 0, 0, 2, 2, 2), {R1, R2, R3}, EMPTY},
+ {"mix2.l", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 2, 2), {R1, R2, R3}, EMPTY},
+ {"mix4.l", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 2, 2, 2), {R1, R2, R3}, EMPTY},
+ {"pack2.uss", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 0, 0), {R1, R2, R3}, EMPTY},
+ {"pack2.sss", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 2, 0), {R1, R2, R3}, EMPTY},
+ {"pack4.sss", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 2, 2, 0), {R1, R2, R3}, EMPTY},
+ {"unpack1.h", I, OpZaZbVeX2aX2bX2c (7, 0, 0, 0, 2, 0, 1), {R1, R2, R3}, EMPTY},
+ {"unpack2.h", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 0, 1), {R1, R2, R3}, EMPTY},
+ {"unpack4.h", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 2, 0, 1), {R1, R2, R3}, EMPTY},
+ {"unpack1.l", I, OpZaZbVeX2aX2bX2c (7, 0, 0, 0, 2, 2, 1), {R1, R2, R3}, EMPTY},
+ {"unpack2.l", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 2, 1), {R1, R2, R3}, EMPTY},
+ {"unpack4.l", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 2, 2, 1), {R1, R2, R3}, EMPTY},
+ {"pmin1.u", I, OpZaZbVeX2aX2bX2c (7, 0, 0, 0, 2, 1, 0), {R1, R2, R3}, EMPTY},
+ {"pmax1.u", I, OpZaZbVeX2aX2bX2c (7, 0, 0, 0, 2, 1, 1), {R1, R2, R3}, EMPTY},
+ {"pmin2", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 3, 0), {R1, R2, R3}, EMPTY},
+ {"pmax2", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 2, 3, 1), {R1, R2, R3}, EMPTY},
+ {"psad1", I, OpZaZbVeX2aX2bX2c (7, 0, 0, 0, 2, 3, 2), {R1, R2, R3}, EMPTY},
+ {"mux1", I, OpZaZbVeX2aX2bX2c (7, 0, 0, 0, 3, 2, 2), {R1, R2, MBTYPE4}, EMPTY},
+ {"mux2", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 3, 2, 2), {R1, R2, MHTYPE8}, EMPTY},
+ {"pshr2", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 0, 2, 0), {R1, R3, R2}, EMPTY},
+ {"pshr4", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 0, 2, 0), {R1, R3, R2}, EMPTY},
+ {"shr", I, OpZaZbVeX2aX2bX2c (7, 1, 1, 0, 0, 2, 0), {R1, R3, R2}, EMPTY},
+ {"pshr2.u", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 0, 0, 0), {R1, R3, R2}, EMPTY},
+ {"pshr4.u", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 0, 0, 0), {R1, R3, R2}, EMPTY},
+ {"shr.u", I, OpZaZbVeX2aX2bX2c (7, 1, 1, 0, 0, 0, 0), {R1, R3, R2}, EMPTY},
+ {"pshr2", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 1, 3, 0), {R1, R3, CNT5}, EMPTY},
+ {"pshr4", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 1, 3, 0), {R1, R3, CNT5}, EMPTY},
+ {"pshr2.u", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 1, 1, 0), {R1, R3, CNT5}, EMPTY},
+ {"pshr4.u", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 1, 1, 0), {R1, R3, CNT5}, EMPTY},
+ {"pshl2", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 0, 0, 1), {R1, R2, R3}, EMPTY},
+ {"pshl4", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 0, 0, 1), {R1, R2, R3}, EMPTY},
+ {"shl", I, OpZaZbVeX2aX2bX2c (7, 1, 1, 0, 0, 0, 1), {R1, R2, R3}, EMPTY},
+ {"pshl2", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 3, 1, 1), {R1, R2, CCNT5}, EMPTY},
+ {"pshl4", I, OpZaZbVeX2aX2bX2c (7, 1, 0, 0, 3, 1, 1), {R1, R2, CCNT5}, EMPTY},
+ {"popcnt", I, OpZaZbVeX2aX2bX2c (7, 0, 1, 0, 1, 1, 2), {R1, R3}, EMPTY},
- {0}
+ {NULL, 0, 0, 0, 0, {0}, 0, 0, NULL}
};
#undef I0
@@ -294,3 +301,4 @@ struct ia64_opcode ia64_opcodes_i[] =
#undef OpX3X6
#undef OpX3XbIhWh
#undef OpX3XbIhWhTag13
+#undef EMPTY
diff --git a/contrib/binutils/opcodes/ia64-opc-m.c b/contrib/binutils/opcodes/ia64-opc-m.c
index bc09816..8e9454b 100644
--- a/contrib/binutils/opcodes/ia64-opc-m.c
+++ b/contrib/binutils/opcodes/ia64-opc-m.c
@@ -1,5 +1,5 @@
/* ia64-opc-m.c -- IA-64 `M' opcode table.
- Copyright 1998, 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2002 Free Software Foundation, Inc.
Contributed by David Mosberger-Tang <davidm@hpl.hp.com>
This file is part of GDB, GAS, and the GNU binutils.
@@ -33,6 +33,8 @@
#define bX4(x) (((ia64_insn) ((x) & 0xf)) << 27)
#define bX6a(x) (((ia64_insn) ((x) & 0x3f)) << 30)
#define bX6b(x) (((ia64_insn) ((x) & 0x3f)) << 27)
+#define bX7(x) (((ia64_insn) ((x) & 0x1)) << 36) /* note: alias for bM() */
+#define bY(x) (((ia64_insn) ((x) & 0x1)) << 26)
#define bHint(x) (((ia64_insn) ((x) & 0x3)) << 28)
#define mM bM (-1)
@@ -42,15 +44,21 @@
#define mX4 bX4 (-1)
#define mX6a bX6a (-1)
#define mX6b bX6b (-1)
+#define mX7 bX7 (-1)
+#define mY bY (-1)
#define mHint bHint (-1)
#define OpX3(a,b) (bOp (a) | bX3 (b)), (mOp | mX3)
#define OpX3X6b(a,b,c) (bOp (a) | bX3 (b) | bX6b (c)), \
(mOp | mX3 | mX6b)
+#define OpX3X6bX7(a,b,c,d) (bOp (a) | bX3 (b) | bX6b (c) | bX7 (d)), \
+ (mOp | mX3 | mX6b | mX7)
#define OpX3X4(a,b,c) (bOp (a) | bX3 (b) | bX4 (c)), \
(mOp | mX3 | mX4)
#define OpX3X4X2(a,b,c,d) (bOp (a) | bX3 (b) | bX4 (c) | bX2 (d)), \
(mOp | mX3 | mX4 | mX2)
+#define OpX3X4X2Y(a,b,c,d,e) (bOp (a) | bX3 (b) | bX4 (c) | bX2 (d) | bY (e)), \
+ (mOp | mX3 | mX4 | mX2 | mY)
#define OpX6aHint(a,b,c) (bOp (a) | bX6a (b) | bHint (c)), \
(mOp | mX6a | mHint)
#define OpXX6aHint(a,b,c,d) (bOp (a) | bX (b) | bX6a (c) | bHint (d)), \
@@ -61,208 +69,224 @@
(bOp (a) | bM (b) | bX (c) | bX6a (d) | bHint (e)), \
(mOp | mM | mX | mX6a | mHint)
+/* Used to initialise unused fields in ia64_opcode struct,
+ in order to stop gcc from complaining. */
+#define EMPTY 0,0,NULL
+
struct ia64_opcode ia64_opcodes_m[] =
{
- /* M-type instruction encodings (sorted according to major opcode) */
+ /* M-type instruction encodings (sorted according to major opcode). */
- {"chk.a.nc", M0, OpX3 (0, 4), {R1, TGT25c}},
- {"chk.a.clr", M0, OpX3 (0, 5), {R1, TGT25c}},
- {"chk.a.nc", M0, OpX3 (0, 6), {F1, TGT25c}},
- {"chk.a.clr", M0, OpX3 (0, 7), {F1, TGT25c}},
+ {"chk.a.nc", M0, OpX3 (0, 4), {R1, TGT25c}, EMPTY},
+ {"chk.a.clr", M0, OpX3 (0, 5), {R1, TGT25c}, EMPTY},
+ {"chk.a.nc", M0, OpX3 (0, 6), {F1, TGT25c}, EMPTY},
+ {"chk.a.clr", M0, OpX3 (0, 7), {F1, TGT25c}, EMPTY},
- {"invala", M0, OpX3X4X2 (0, 0, 0, 1)},
- {"fwb", M0, OpX3X4X2 (0, 0, 0, 2)},
- {"mf", M0, OpX3X4X2 (0, 0, 2, 2)},
- {"mf.a", M0, OpX3X4X2 (0, 0, 3, 2)},
- {"srlz.d", M0, OpX3X4X2 (0, 0, 0, 3)},
- {"srlz.i", M0, OpX3X4X2 (0, 0, 1, 3)},
- {"sync.i", M0, OpX3X4X2 (0, 0, 3, 3)},
- {"flushrs", M0, OpX3X4X2 (0, 0, 0xc, 0), {0, }, FIRST | NO_PRED},
- {"loadrs", M0, OpX3X4X2 (0, 0, 0xa, 0), {0, }, FIRST | NO_PRED},
- {"invala.e", M0, OpX3X4X2 (0, 0, 2, 1), {R1}},
- {"invala.e", M0, OpX3X4X2 (0, 0, 3, 1), {F1}},
- {"mov.m", M, OpX3X4X2 (0, 0, 8, 2), {AR3, IMM8}},
+ {"invala", M0, OpX3X4X2 (0, 0, 0, 1), {}, EMPTY},
+ {"fwb", M0, OpX3X4X2 (0, 0, 0, 2), {}, EMPTY},
+ {"mf", M0, OpX3X4X2 (0, 0, 2, 2), {}, EMPTY},
+ {"mf.a", M0, OpX3X4X2 (0, 0, 3, 2), {}, EMPTY},
+ {"srlz.d", M0, OpX3X4X2 (0, 0, 0, 3), {}, EMPTY},
+ {"srlz.i", M0, OpX3X4X2 (0, 0, 1, 3), {}, EMPTY},
+ {"sync.i", M0, OpX3X4X2 (0, 0, 3, 3), {}, EMPTY},
+ {"flushrs", M0, OpX3X4X2 (0, 0, 0xc, 0), {}, FIRST | NO_PRED, 0, NULL},
+ {"loadrs", M0, OpX3X4X2 (0, 0, 0xa, 0), {}, FIRST | NO_PRED, 0, NULL},
+ {"invala.e", M0, OpX3X4X2 (0, 0, 2, 1), {R1}, EMPTY},
+ {"invala.e", M0, OpX3X4X2 (0, 0, 3, 1), {F1}, EMPTY},
+ {"mov.m", M, OpX3X4X2 (0, 0, 8, 2), {AR3, IMM8}, EMPTY},
- {"break.m", M0, OpX3X4X2 (0, 0, 0, 0), {IMMU21}},
- {"nop.m", M0, OpX3X4X2 (0, 0, 1, 0), {IMMU21}},
+ {"break.m", M0, OpX3X4X2 (0, 0, 0, 0), {IMMU21}, EMPTY},
+ {"nop.m", M0, OpX3X4X2Y (0, 0, 1, 0, 0), {IMMU21}, EMPTY},
+ {"hint.m", M0, OpX3X4X2Y (0, 0, 1, 0, 1), {IMMU21}, EMPTY},
- {"sum", M0, OpX3X4 (0, 0, 4), {IMMU24}},
- {"rum", M0, OpX3X4 (0, 0, 5), {IMMU24}},
- {"ssm", M0, OpX3X4 (0, 0, 6), {IMMU24}, PRIV},
- {"rsm", M0, OpX3X4 (0, 0, 7), {IMMU24}, PRIV},
+ {"sum", M0, OpX3X4 (0, 0, 4), {IMMU24}, EMPTY},
+ {"rum", M0, OpX3X4 (0, 0, 5), {IMMU24}, EMPTY},
+ {"ssm", M0, OpX3X4 (0, 0, 6), {IMMU24}, PRIV, 0, NULL},
+ {"rsm", M0, OpX3X4 (0, 0, 7), {IMMU24}, PRIV, 0, NULL},
- {"mov.m", M, OpX3X6b (1, 0, 0x2a), {AR3, R2}},
- {"mov.m", M, OpX3X6b (1, 0, 0x22), {R1, AR3}},
- {"mov", M, OpX3X6b (1, 0, 0x2c), {CR3, R2}, PRIV},
- {"mov", M, OpX3X6b (1, 0, 0x24), {R1, CR3}, PRIV},
+ {"mov.m", M, OpX3X6b (1, 0, 0x2a), {AR3, R2}, EMPTY},
+ {"mov.m", M, OpX3X6b (1, 0, 0x22), {R1, AR3}, EMPTY},
+ {"mov", M, OpX3X6b (1, 0, 0x2c), {CR3, R2}, PRIV, 0, NULL},
+ {"mov", M, OpX3X6b (1, 0, 0x24), {R1, CR3}, PRIV, 0, NULL},
- {"alloc", M, OpX3 (1, 6), {R1, AR_PFS, SOF, SOL, SOR}, FIRST|NO_PRED|MOD_RRBS},
+ {"alloc", M, OpX3 (1, 6), {R1, AR_PFS, SOF, SOL, SOR}, FIRST|NO_PRED|MOD_RRBS, 0, NULL},
- {"mov", M, OpX3X6b (1, 0, 0x2d), {PSR_L, R2}, PRIV},
- {"mov", M, OpX3X6b (1, 0, 0x29), {PSR_UM, R2}},
- {"mov", M, OpX3X6b (1, 0, 0x25), {R1, PSR}, PRIV},
- {"mov", M, OpX3X6b (1, 0, 0x21), {R1, PSR_UM}},
- {"probe.r", M, OpX3X6b (1, 0, 0x38), {R1, R3, R2}},
- {"probe.w", M, OpX3X6b (1, 0, 0x39), {R1, R3, R2}},
- {"probe.r", M, OpX3X6b (1, 0, 0x18), {R1, R3, IMMU2}},
- {"probe.w", M, OpX3X6b (1, 0, 0x19), {R1, R3, IMMU2}},
- {"probe.rw.fault", M0, OpX3X6b (1, 0, 0x31), {R3, IMMU2}},
- {"probe.r.fault", M0, OpX3X6b (1, 0, 0x32), {R3, IMMU2}},
- {"probe.w.fault", M0, OpX3X6b (1, 0, 0x33), {R3, IMMU2}},
- {"itc.d", M0, OpX3X6b (1, 0, 0x2e), {R2}, LAST | PRIV},
- {"itc.i", M0, OpX3X6b (1, 0, 0x2f), {R2}, LAST | PRIV},
+ {"mov", M, OpX3X6b (1, 0, 0x2d), {PSR_L, R2}, PRIV, 0, NULL},
+ {"mov", M, OpX3X6b (1, 0, 0x29), {PSR_UM, R2}, EMPTY},
+ {"mov", M, OpX3X6b (1, 0, 0x25), {R1, PSR}, PRIV, 0, NULL},
+ {"mov", M, OpX3X6b (1, 0, 0x21), {R1, PSR_UM}, EMPTY},
+ {"probe.r", M, OpX3X6b (1, 0, 0x38), {R1, R3, R2}, EMPTY},
+ {"probe.w", M, OpX3X6b (1, 0, 0x39), {R1, R3, R2}, EMPTY},
+ {"probe.r", M, OpX3X6b (1, 0, 0x18), {R1, R3, IMMU2}, EMPTY},
+ {"probe.w", M, OpX3X6b (1, 0, 0x19), {R1, R3, IMMU2}, EMPTY},
+ {"probe.rw.fault", M0, OpX3X6b (1, 0, 0x31), {R3, IMMU2}, EMPTY},
+ {"probe.r.fault", M0, OpX3X6b (1, 0, 0x32), {R3, IMMU2}, EMPTY},
+ {"probe.w.fault", M0, OpX3X6b (1, 0, 0x33), {R3, IMMU2}, EMPTY},
+ {"itc.d", M0, OpX3X6b (1, 0, 0x2e), {R2}, LAST | PRIV, 0, NULL},
+ {"itc.i", M0, OpX3X6b (1, 0, 0x2f), {R2}, LAST | PRIV, 0, NULL},
- {"mov", M, OpX3X6b (1, 0, 0x00), {RR_R3, R2}, PRIV},
- {"mov", M, OpX3X6b (1, 0, 0x01), {DBR_R3, R2}, PRIV},
- {"mov", M, OpX3X6b (1, 0, 0x02), {IBR_R3, R2}, PRIV},
- {"mov", M, OpX3X6b (1, 0, 0x03), {PKR_R3, R2}, PRIV},
- {"mov", M, OpX3X6b (1, 0, 0x04), {PMC_R3, R2}, PRIV},
- {"mov", M, OpX3X6b (1, 0, 0x05), {PMD_R3, R2}, PRIV},
- {"mov", M, OpX3X6b (1, 0, 0x06), {MSR_R3, R2}, PRIV},
- {"itr.d", M, OpX3X6b (1, 0, 0x0e), {DTR_R3, R2}, PRIV},
- {"itr.i", M, OpX3X6b (1, 0, 0x0f), {ITR_R3, R2}, PRIV},
+ {"mov", M, OpX3X6b (1, 0, 0x00), {RR_R3, R2}, PRIV, 0, NULL},
+ {"mov", M, OpX3X6b (1, 0, 0x01), {DBR_R3, R2}, PRIV, 0, NULL},
+ {"mov", M, OpX3X6b (1, 0, 0x02), {IBR_R3, R2}, PRIV, 0, NULL},
+ {"mov", M, OpX3X6b (1, 0, 0x03), {PKR_R3, R2}, PRIV, 0, NULL},
+ {"mov", M, OpX3X6b (1, 0, 0x04), {PMC_R3, R2}, PRIV, 0, NULL},
+ {"mov", M, OpX3X6b (1, 0, 0x05), {PMD_R3, R2}, PRIV, 0, NULL},
+ {"mov", M, OpX3X6b (1, 0, 0x06), {MSR_R3, R2}, PRIV, 0, NULL},
+ {"itr.d", M, OpX3X6b (1, 0, 0x0e), {DTR_R3, R2}, PRIV, 0, NULL},
+ {"itr.i", M, OpX3X6b (1, 0, 0x0f), {ITR_R3, R2}, PRIV, 0, NULL},
- {"mov", M, OpX3X6b (1, 0, 0x10), {R1, RR_R3}, PRIV},
- {"mov", M, OpX3X6b (1, 0, 0x11), {R1, DBR_R3}, PRIV},
- {"mov", M, OpX3X6b (1, 0, 0x12), {R1, IBR_R3}, PRIV},
- {"mov", M, OpX3X6b (1, 0, 0x13), {R1, PKR_R3}, PRIV},
- {"mov", M, OpX3X6b (1, 0, 0x14), {R1, PMC_R3}, PRIV},
- {"mov", M, OpX3X6b (1, 0, 0x15), {R1, PMD_R3}},
- {"mov", M, OpX3X6b (1, 0, 0x16), {R1, MSR_R3}, PRIV},
- {"mov", M, OpX3X6b (1, 0, 0x17), {R1, CPUID_R3}},
+ {"mov", M, OpX3X6b (1, 0, 0x10), {R1, RR_R3}, PRIV, 0, NULL},
+ {"mov", M, OpX3X6b (1, 0, 0x11), {R1, DBR_R3}, PRIV, 0, NULL},
+ {"mov", M, OpX3X6b (1, 0, 0x12), {R1, IBR_R3}, PRIV, 0, NULL},
+ {"mov", M, OpX3X6b (1, 0, 0x13), {R1, PKR_R3}, PRIV, 0, NULL},
+ {"mov", M, OpX3X6b (1, 0, 0x14), {R1, PMC_R3}, PRIV, 0, NULL},
+ {"mov", M, OpX3X6b (1, 0, 0x15), {R1, PMD_R3}, EMPTY},
+ {"mov", M, OpX3X6b (1, 0, 0x16), {R1, MSR_R3}, PRIV, 0, NULL},
+ {"mov", M, OpX3X6b (1, 0, 0x17), {R1, CPUID_R3}, EMPTY},
- {"ptc.l", M0, OpX3X6b (1, 0, 0x09), {R3, R2}, PRIV},
- {"ptc.g", M0, OpX3X6b (1, 0, 0x0a), {R3, R2}, LAST | PRIV},
- {"ptc.ga", M0, OpX3X6b (1, 0, 0x0b), {R3, R2}, LAST | PRIV},
- {"ptr.d", M0, OpX3X6b (1, 0, 0x0c), {R3, R2}, PRIV},
- {"ptr.i", M0, OpX3X6b (1, 0, 0x0d), {R3, R2}, PRIV},
+ {"ptc.l", M0, OpX3X6b (1, 0, 0x09), {R3, R2}, PRIV, 0, NULL},
+ {"ptc.g", M0, OpX3X6b (1, 0, 0x0a), {R3, R2}, LAST | PRIV, 0, NULL},
+ {"ptc.ga", M0, OpX3X6b (1, 0, 0x0b), {R3, R2}, LAST | PRIV, 0, NULL},
+ {"ptr.d", M0, OpX3X6b (1, 0, 0x0c), {R3, R2}, PRIV, 0, NULL},
+ {"ptr.i", M0, OpX3X6b (1, 0, 0x0d), {R3, R2}, PRIV, 0, NULL},
- {"thash", M, OpX3X6b (1, 0, 0x1a), {R1, R3}},
- {"ttag", M, OpX3X6b (1, 0, 0x1b), {R1, R3}},
- {"tpa", M, OpX3X6b (1, 0, 0x1e), {R1, R3}, PRIV},
- {"tak", M, OpX3X6b (1, 0, 0x1f), {R1, R3}, PRIV},
+ {"thash", M, OpX3X6b (1, 0, 0x1a), {R1, R3}, EMPTY},
+ {"ttag", M, OpX3X6b (1, 0, 0x1b), {R1, R3}, EMPTY},
+ {"tpa", M, OpX3X6b (1, 0, 0x1e), {R1, R3}, PRIV, 0, NULL},
+ {"tak", M, OpX3X6b (1, 0, 0x1f), {R1, R3}, PRIV, 0, NULL},
- {"chk.s.m", M0, OpX3 (1, 1), {R2, TGT25b}},
- {"chk.s", M0, OpX3 (1, 3), {F2, TGT25b}},
+ {"chk.s.m", M0, OpX3 (1, 1), {R2, TGT25b}, EMPTY},
+ {"chk.s", M0, OpX3 (1, 3), {F2, TGT25b}, EMPTY},
- {"fc", M0, OpX3X6b (1, 0, 0x30), {R3}},
- {"ptc.e", M0, OpX3X6b (1, 0, 0x34), {R3}, PRIV},
+ {"fc", M0, OpX3X6bX7 (1, 0, 0x30, 0), {R3}, EMPTY},
+ {"fc.i", M0, OpX3X6bX7 (1, 0, 0x30, 1), {R3}, EMPTY},
+ {"ptc.e", M0, OpX3X6b (1, 0, 0x34), {R3}, PRIV, 0, NULL},
/* integer load */
- {"ld1", M, OpMXX6aHint (4, 0, 0, 0x00, 0), {R1, MR3}},
- {"ld1.nt1", M, OpMXX6aHint (4, 0, 0, 0x00, 1), {R1, MR3}},
- {"ld1.nta", M, OpMXX6aHint (4, 0, 0, 0x00, 3), {R1, MR3}},
- {"ld2", M, OpMXX6aHint (4, 0, 0, 0x01, 0), {R1, MR3}},
- {"ld2.nt1", M, OpMXX6aHint (4, 0, 0, 0x01, 1), {R1, MR3}},
- {"ld2.nta", M, OpMXX6aHint (4, 0, 0, 0x01, 3), {R1, MR3}},
- {"ld4", M, OpMXX6aHint (4, 0, 0, 0x02, 0), {R1, MR3}},
- {"ld4.nt1", M, OpMXX6aHint (4, 0, 0, 0x02, 1), {R1, MR3}},
- {"ld4.nta", M, OpMXX6aHint (4, 0, 0, 0x02, 3), {R1, MR3}},
- {"ld8", M, OpMXX6aHint (4, 0, 0, 0x03, 0), {R1, MR3}},
- {"ld8.nt1", M, OpMXX6aHint (4, 0, 0, 0x03, 1), {R1, MR3}},
- {"ld8.nta", M, OpMXX6aHint (4, 0, 0, 0x03, 3), {R1, MR3}},
- {"ld1.s", M, OpMXX6aHint (4, 0, 0, 0x04, 0), {R1, MR3}},
- {"ld1.s.nt1", M, OpMXX6aHint (4, 0, 0, 0x04, 1), {R1, MR3}},
- {"ld1.s.nta", M, OpMXX6aHint (4, 0, 0, 0x04, 3), {R1, MR3}},
- {"ld2.s", M, OpMXX6aHint (4, 0, 0, 0x05, 0), {R1, MR3}},
- {"ld2.s.nt1", M, OpMXX6aHint (4, 0, 0, 0x05, 1), {R1, MR3}},
- {"ld2.s.nta", M, OpMXX6aHint (4, 0, 0, 0x05, 3), {R1, MR3}},
- {"ld4.s", M, OpMXX6aHint (4, 0, 0, 0x06, 0), {R1, MR3}},
- {"ld4.s.nt1", M, OpMXX6aHint (4, 0, 0, 0x06, 1), {R1, MR3}},
- {"ld4.s.nta", M, OpMXX6aHint (4, 0, 0, 0x06, 3), {R1, MR3}},
- {"ld8.s", M, OpMXX6aHint (4, 0, 0, 0x07, 0), {R1, MR3}},
- {"ld8.s.nt1", M, OpMXX6aHint (4, 0, 0, 0x07, 1), {R1, MR3}},
- {"ld8.s.nta", M, OpMXX6aHint (4, 0, 0, 0x07, 3), {R1, MR3}},
- {"ld1.a", M, OpMXX6aHint (4, 0, 0, 0x08, 0), {R1, MR3}},
- {"ld1.a.nt1", M, OpMXX6aHint (4, 0, 0, 0x08, 1), {R1, MR3}},
- {"ld1.a.nta", M, OpMXX6aHint (4, 0, 0, 0x08, 3), {R1, MR3}},
- {"ld2.a", M, OpMXX6aHint (4, 0, 0, 0x09, 0), {R1, MR3}},
- {"ld2.a.nt1", M, OpMXX6aHint (4, 0, 0, 0x09, 1), {R1, MR3}},
- {"ld2.a.nta", M, OpMXX6aHint (4, 0, 0, 0x09, 3), {R1, MR3}},
- {"ld4.a", M, OpMXX6aHint (4, 0, 0, 0x0a, 0), {R1, MR3}},
- {"ld4.a.nt1", M, OpMXX6aHint (4, 0, 0, 0x0a, 1), {R1, MR3}},
- {"ld4.a.nta", M, OpMXX6aHint (4, 0, 0, 0x0a, 3), {R1, MR3}},
- {"ld8.a", M, OpMXX6aHint (4, 0, 0, 0x0b, 0), {R1, MR3}},
- {"ld8.a.nt1", M, OpMXX6aHint (4, 0, 0, 0x0b, 1), {R1, MR3}},
- {"ld8.a.nta", M, OpMXX6aHint (4, 0, 0, 0x0b, 3), {R1, MR3}},
- {"ld1.sa", M, OpMXX6aHint (4, 0, 0, 0x0c, 0), {R1, MR3}},
- {"ld1.sa.nt1", M, OpMXX6aHint (4, 0, 0, 0x0c, 1), {R1, MR3}},
- {"ld1.sa.nta", M, OpMXX6aHint (4, 0, 0, 0x0c, 3), {R1, MR3}},
- {"ld2.sa", M, OpMXX6aHint (4, 0, 0, 0x0d, 0), {R1, MR3}},
- {"ld2.sa.nt1", M, OpMXX6aHint (4, 0, 0, 0x0d, 1), {R1, MR3}},
- {"ld2.sa.nta", M, OpMXX6aHint (4, 0, 0, 0x0d, 3), {R1, MR3}},
- {"ld4.sa", M, OpMXX6aHint (4, 0, 0, 0x0e, 0), {R1, MR3}},
- {"ld4.sa.nt1", M, OpMXX6aHint (4, 0, 0, 0x0e, 1), {R1, MR3}},
- {"ld4.sa.nta", M, OpMXX6aHint (4, 0, 0, 0x0e, 3), {R1, MR3}},
- {"ld8.sa", M, OpMXX6aHint (4, 0, 0, 0x0f, 0), {R1, MR3}},
- {"ld8.sa.nt1", M, OpMXX6aHint (4, 0, 0, 0x0f, 1), {R1, MR3}},
- {"ld8.sa.nta", M, OpMXX6aHint (4, 0, 0, 0x0f, 3), {R1, MR3}},
- {"ld1.bias", M, OpMXX6aHint (4, 0, 0, 0x10, 0), {R1, MR3}},
- {"ld1.bias.nt1", M, OpMXX6aHint (4, 0, 0, 0x10, 1), {R1, MR3}},
- {"ld1.bias.nta", M, OpMXX6aHint (4, 0, 0, 0x10, 3), {R1, MR3}},
- {"ld2.bias", M, OpMXX6aHint (4, 0, 0, 0x11, 0), {R1, MR3}},
- {"ld2.bias.nt1", M, OpMXX6aHint (4, 0, 0, 0x11, 1), {R1, MR3}},
- {"ld2.bias.nta", M, OpMXX6aHint (4, 0, 0, 0x11, 3), {R1, MR3}},
- {"ld4.bias", M, OpMXX6aHint (4, 0, 0, 0x12, 0), {R1, MR3}},
- {"ld4.bias.nt1", M, OpMXX6aHint (4, 0, 0, 0x12, 1), {R1, MR3}},
- {"ld4.bias.nta", M, OpMXX6aHint (4, 0, 0, 0x12, 3), {R1, MR3}},
- {"ld8.bias", M, OpMXX6aHint (4, 0, 0, 0x13, 0), {R1, MR3}},
- {"ld8.bias.nt1", M, OpMXX6aHint (4, 0, 0, 0x13, 1), {R1, MR3}},
- {"ld8.bias.nta", M, OpMXX6aHint (4, 0, 0, 0x13, 3), {R1, MR3}},
- {"ld1.acq", M, OpMXX6aHint (4, 0, 0, 0x14, 0), {R1, MR3}},
- {"ld1.acq.nt1", M, OpMXX6aHint (4, 0, 0, 0x14, 1), {R1, MR3}},
- {"ld1.acq.nta", M, OpMXX6aHint (4, 0, 0, 0x14, 3), {R1, MR3}},
- {"ld2.acq", M, OpMXX6aHint (4, 0, 0, 0x15, 0), {R1, MR3}},
- {"ld2.acq.nt1", M, OpMXX6aHint (4, 0, 0, 0x15, 1), {R1, MR3}},
- {"ld2.acq.nta", M, OpMXX6aHint (4, 0, 0, 0x15, 3), {R1, MR3}},
- {"ld4.acq", M, OpMXX6aHint (4, 0, 0, 0x16, 0), {R1, MR3}},
- {"ld4.acq.nt1", M, OpMXX6aHint (4, 0, 0, 0x16, 1), {R1, MR3}},
- {"ld4.acq.nta", M, OpMXX6aHint (4, 0, 0, 0x16, 3), {R1, MR3}},
- {"ld8.acq", M, OpMXX6aHint (4, 0, 0, 0x17, 0), {R1, MR3}},
- {"ld8.acq.nt1", M, OpMXX6aHint (4, 0, 0, 0x17, 1), {R1, MR3}},
- {"ld8.acq.nta", M, OpMXX6aHint (4, 0, 0, 0x17, 3), {R1, MR3}},
- {"ld8.fill", M, OpMXX6aHint (4, 0, 0, 0x1b, 0), {R1, MR3}},
- {"ld8.fill.nt1", M, OpMXX6aHint (4, 0, 0, 0x1b, 1), {R1, MR3}},
- {"ld8.fill.nta", M, OpMXX6aHint (4, 0, 0, 0x1b, 3), {R1, MR3}},
- {"ld1.c.clr", M, OpMXX6aHint (4, 0, 0, 0x20, 0), {R1, MR3}},
- {"ld1.c.clr.nt1", M, OpMXX6aHint (4, 0, 0, 0x20, 1), {R1, MR3}},
- {"ld1.c.clr.nta", M, OpMXX6aHint (4, 0, 0, 0x20, 3), {R1, MR3}},
- {"ld2.c.clr", M, OpMXX6aHint (4, 0, 0, 0x21, 0), {R1, MR3}},
- {"ld2.c.clr.nt1", M, OpMXX6aHint (4, 0, 0, 0x21, 1), {R1, MR3}},
- {"ld2.c.clr.nta", M, OpMXX6aHint (4, 0, 0, 0x21, 3), {R1, MR3}},
- {"ld4.c.clr", M, OpMXX6aHint (4, 0, 0, 0x22, 0), {R1, MR3}},
- {"ld4.c.clr.nt1", M, OpMXX6aHint (4, 0, 0, 0x22, 1), {R1, MR3}},
- {"ld4.c.clr.nta", M, OpMXX6aHint (4, 0, 0, 0x22, 3), {R1, MR3}},
- {"ld8.c.clr", M, OpMXX6aHint (4, 0, 0, 0x23, 0), {R1, MR3}},
- {"ld8.c.clr.nt1", M, OpMXX6aHint (4, 0, 0, 0x23, 1), {R1, MR3}},
- {"ld8.c.clr.nta", M, OpMXX6aHint (4, 0, 0, 0x23, 3), {R1, MR3}},
- {"ld1.c.nc", M, OpMXX6aHint (4, 0, 0, 0x24, 0), {R1, MR3}},
- {"ld1.c.nc.nt1", M, OpMXX6aHint (4, 0, 0, 0x24, 1), {R1, MR3}},
- {"ld1.c.nc.nta", M, OpMXX6aHint (4, 0, 0, 0x24, 3), {R1, MR3}},
- {"ld2.c.nc", M, OpMXX6aHint (4, 0, 0, 0x25, 0), {R1, MR3}},
- {"ld2.c.nc.nt1", M, OpMXX6aHint (4, 0, 0, 0x25, 1), {R1, MR3}},
- {"ld2.c.nc.nta", M, OpMXX6aHint (4, 0, 0, 0x25, 3), {R1, MR3}},
- {"ld4.c.nc", M, OpMXX6aHint (4, 0, 0, 0x26, 0), {R1, MR3}},
- {"ld4.c.nc.nt1", M, OpMXX6aHint (4, 0, 0, 0x26, 1), {R1, MR3}},
- {"ld4.c.nc.nta", M, OpMXX6aHint (4, 0, 0, 0x26, 3), {R1, MR3}},
- {"ld8.c.nc", M, OpMXX6aHint (4, 0, 0, 0x27, 0), {R1, MR3}},
- {"ld8.c.nc.nt1", M, OpMXX6aHint (4, 0, 0, 0x27, 1), {R1, MR3}},
- {"ld8.c.nc.nta", M, OpMXX6aHint (4, 0, 0, 0x27, 3), {R1, MR3}},
- {"ld1.c.clr.acq", M, OpMXX6aHint (4, 0, 0, 0x28, 0), {R1, MR3}},
- {"ld1.c.clr.acq.nt1", M, OpMXX6aHint (4, 0, 0, 0x28, 1), {R1, MR3}},
- {"ld1.c.clr.acq.nta", M, OpMXX6aHint (4, 0, 0, 0x28, 3), {R1, MR3}},
- {"ld2.c.clr.acq", M, OpMXX6aHint (4, 0, 0, 0x29, 0), {R1, MR3}},
- {"ld2.c.clr.acq.nt1", M, OpMXX6aHint (4, 0, 0, 0x29, 1), {R1, MR3}},
- {"ld2.c.clr.acq.nta", M, OpMXX6aHint (4, 0, 0, 0x29, 3), {R1, MR3}},
- {"ld4.c.clr.acq", M, OpMXX6aHint (4, 0, 0, 0x2a, 0), {R1, MR3}},
- {"ld4.c.clr.acq.nt1", M, OpMXX6aHint (4, 0, 0, 0x2a, 1), {R1, MR3}},
- {"ld4.c.clr.acq.nta", M, OpMXX6aHint (4, 0, 0, 0x2a, 3), {R1, MR3}},
- {"ld8.c.clr.acq", M, OpMXX6aHint (4, 0, 0, 0x2b, 0), {R1, MR3}},
- {"ld8.c.clr.acq.nt1", M, OpMXX6aHint (4, 0, 0, 0x2b, 1), {R1, MR3}},
- {"ld8.c.clr.acq.nta", M, OpMXX6aHint (4, 0, 0, 0x2b, 3), {R1, MR3}},
+ {"ld1", M, OpMXX6aHint (4, 0, 0, 0x00, 0), {R1, MR3}, EMPTY},
+ {"ld1.nt1", M, OpMXX6aHint (4, 0, 0, 0x00, 1), {R1, MR3}, EMPTY},
+ {"ld1.nta", M, OpMXX6aHint (4, 0, 0, 0x00, 3), {R1, MR3}, EMPTY},
+ {"ld2", M, OpMXX6aHint (4, 0, 0, 0x01, 0), {R1, MR3}, EMPTY},
+ {"ld2.nt1", M, OpMXX6aHint (4, 0, 0, 0x01, 1), {R1, MR3}, EMPTY},
+ {"ld2.nta", M, OpMXX6aHint (4, 0, 0, 0x01, 3), {R1, MR3}, EMPTY},
+ {"ld4", M, OpMXX6aHint (4, 0, 0, 0x02, 0), {R1, MR3}, EMPTY},
+ {"ld4.nt1", M, OpMXX6aHint (4, 0, 0, 0x02, 1), {R1, MR3}, EMPTY},
+ {"ld4.nta", M, OpMXX6aHint (4, 0, 0, 0x02, 3), {R1, MR3}, EMPTY},
+ {"ld8", M, OpMXX6aHint (4, 0, 0, 0x03, 0), {R1, MR3}, EMPTY},
+ {"ld8.nt1", M, OpMXX6aHint (4, 0, 0, 0x03, 1), {R1, MR3}, EMPTY},
+ {"ld8.nta", M, OpMXX6aHint (4, 0, 0, 0x03, 3), {R1, MR3}, EMPTY},
+ {"ld16", M2, OpMXX6aHint (4, 0, 1, 0x28, 0), {R1, AR_CSD, MR3}, EMPTY},
+ {"ld16.nt1", M2, OpMXX6aHint (4, 0, 1, 0x28, 1), {R1, AR_CSD, MR3}, EMPTY},
+ {"ld16.nta", M2, OpMXX6aHint (4, 0, 1, 0x28, 3), {R1, AR_CSD, MR3}, EMPTY},
+ {"ld1.s", M, OpMXX6aHint (4, 0, 0, 0x04, 0), {R1, MR3}, EMPTY},
+ {"ld1.s.nt1", M, OpMXX6aHint (4, 0, 0, 0x04, 1), {R1, MR3}, EMPTY},
+ {"ld1.s.nta", M, OpMXX6aHint (4, 0, 0, 0x04, 3), {R1, MR3}, EMPTY},
+ {"ld2.s", M, OpMXX6aHint (4, 0, 0, 0x05, 0), {R1, MR3}, EMPTY},
+ {"ld2.s.nt1", M, OpMXX6aHint (4, 0, 0, 0x05, 1), {R1, MR3}, EMPTY},
+ {"ld2.s.nta", M, OpMXX6aHint (4, 0, 0, 0x05, 3), {R1, MR3}, EMPTY},
+ {"ld4.s", M, OpMXX6aHint (4, 0, 0, 0x06, 0), {R1, MR3}, EMPTY},
+ {"ld4.s.nt1", M, OpMXX6aHint (4, 0, 0, 0x06, 1), {R1, MR3}, EMPTY},
+ {"ld4.s.nta", M, OpMXX6aHint (4, 0, 0, 0x06, 3), {R1, MR3}, EMPTY},
+ {"ld8.s", M, OpMXX6aHint (4, 0, 0, 0x07, 0), {R1, MR3}, EMPTY},
+ {"ld8.s.nt1", M, OpMXX6aHint (4, 0, 0, 0x07, 1), {R1, MR3}, EMPTY},
+ {"ld8.s.nta", M, OpMXX6aHint (4, 0, 0, 0x07, 3), {R1, MR3}, EMPTY},
+ {"ld1.a", M, OpMXX6aHint (4, 0, 0, 0x08, 0), {R1, MR3}, EMPTY},
+ {"ld1.a.nt1", M, OpMXX6aHint (4, 0, 0, 0x08, 1), {R1, MR3}, EMPTY},
+ {"ld1.a.nta", M, OpMXX6aHint (4, 0, 0, 0x08, 3), {R1, MR3}, EMPTY},
+ {"ld2.a", M, OpMXX6aHint (4, 0, 0, 0x09, 0), {R1, MR3}, EMPTY},
+ {"ld2.a.nt1", M, OpMXX6aHint (4, 0, 0, 0x09, 1), {R1, MR3}, EMPTY},
+ {"ld2.a.nta", M, OpMXX6aHint (4, 0, 0, 0x09, 3), {R1, MR3}, EMPTY},
+ {"ld4.a", M, OpMXX6aHint (4, 0, 0, 0x0a, 0), {R1, MR3}, EMPTY},
+ {"ld4.a.nt1", M, OpMXX6aHint (4, 0, 0, 0x0a, 1), {R1, MR3}, EMPTY},
+ {"ld4.a.nta", M, OpMXX6aHint (4, 0, 0, 0x0a, 3), {R1, MR3}, EMPTY},
+ {"ld8.a", M, OpMXX6aHint (4, 0, 0, 0x0b, 0), {R1, MR3}, EMPTY},
+ {"ld8.a.nt1", M, OpMXX6aHint (4, 0, 0, 0x0b, 1), {R1, MR3}, EMPTY},
+ {"ld8.a.nta", M, OpMXX6aHint (4, 0, 0, 0x0b, 3), {R1, MR3}, EMPTY},
+ {"ld1.sa", M, OpMXX6aHint (4, 0, 0, 0x0c, 0), {R1, MR3}, EMPTY},
+ {"ld1.sa.nt1", M, OpMXX6aHint (4, 0, 0, 0x0c, 1), {R1, MR3}, EMPTY},
+ {"ld1.sa.nta", M, OpMXX6aHint (4, 0, 0, 0x0c, 3), {R1, MR3}, EMPTY},
+ {"ld2.sa", M, OpMXX6aHint (4, 0, 0, 0x0d, 0), {R1, MR3}, EMPTY},
+ {"ld2.sa.nt1", M, OpMXX6aHint (4, 0, 0, 0x0d, 1), {R1, MR3}, EMPTY},
+ {"ld2.sa.nta", M, OpMXX6aHint (4, 0, 0, 0x0d, 3), {R1, MR3}, EMPTY},
+ {"ld4.sa", M, OpMXX6aHint (4, 0, 0, 0x0e, 0), {R1, MR3}, EMPTY},
+ {"ld4.sa.nt1", M, OpMXX6aHint (4, 0, 0, 0x0e, 1), {R1, MR3}, EMPTY},
+ {"ld4.sa.nta", M, OpMXX6aHint (4, 0, 0, 0x0e, 3), {R1, MR3}, EMPTY},
+ {"ld8.sa", M, OpMXX6aHint (4, 0, 0, 0x0f, 0), {R1, MR3}, EMPTY},
+ {"ld8.sa.nt1", M, OpMXX6aHint (4, 0, 0, 0x0f, 1), {R1, MR3}, EMPTY},
+ {"ld8.sa.nta", M, OpMXX6aHint (4, 0, 0, 0x0f, 3), {R1, MR3}, EMPTY},
+ {"ld1.bias", M, OpMXX6aHint (4, 0, 0, 0x10, 0), {R1, MR3}, EMPTY},
+ {"ld1.bias.nt1", M, OpMXX6aHint (4, 0, 0, 0x10, 1), {R1, MR3}, EMPTY},
+ {"ld1.bias.nta", M, OpMXX6aHint (4, 0, 0, 0x10, 3), {R1, MR3}, EMPTY},
+ {"ld2.bias", M, OpMXX6aHint (4, 0, 0, 0x11, 0), {R1, MR3}, EMPTY},
+ {"ld2.bias.nt1", M, OpMXX6aHint (4, 0, 0, 0x11, 1), {R1, MR3}, EMPTY},
+ {"ld2.bias.nta", M, OpMXX6aHint (4, 0, 0, 0x11, 3), {R1, MR3}, EMPTY},
+ {"ld4.bias", M, OpMXX6aHint (4, 0, 0, 0x12, 0), {R1, MR3}, EMPTY},
+ {"ld4.bias.nt1", M, OpMXX6aHint (4, 0, 0, 0x12, 1), {R1, MR3}, EMPTY},
+ {"ld4.bias.nta", M, OpMXX6aHint (4, 0, 0, 0x12, 3), {R1, MR3}, EMPTY},
+ {"ld8.bias", M, OpMXX6aHint (4, 0, 0, 0x13, 0), {R1, MR3}, EMPTY},
+ {"ld8.bias.nt1", M, OpMXX6aHint (4, 0, 0, 0x13, 1), {R1, MR3}, EMPTY},
+ {"ld8.bias.nta", M, OpMXX6aHint (4, 0, 0, 0x13, 3), {R1, MR3}, EMPTY},
+ {"ld1.acq", M, OpMXX6aHint (4, 0, 0, 0x14, 0), {R1, MR3}, EMPTY},
+ {"ld1.acq.nt1", M, OpMXX6aHint (4, 0, 0, 0x14, 1), {R1, MR3}, EMPTY},
+ {"ld1.acq.nta", M, OpMXX6aHint (4, 0, 0, 0x14, 3), {R1, MR3}, EMPTY},
+ {"ld2.acq", M, OpMXX6aHint (4, 0, 0, 0x15, 0), {R1, MR3}, EMPTY},
+ {"ld2.acq.nt1", M, OpMXX6aHint (4, 0, 0, 0x15, 1), {R1, MR3}, EMPTY},
+ {"ld2.acq.nta", M, OpMXX6aHint (4, 0, 0, 0x15, 3), {R1, MR3}, EMPTY},
+ {"ld4.acq", M, OpMXX6aHint (4, 0, 0, 0x16, 0), {R1, MR3}, EMPTY},
+ {"ld4.acq.nt1", M, OpMXX6aHint (4, 0, 0, 0x16, 1), {R1, MR3}, EMPTY},
+ {"ld4.acq.nta", M, OpMXX6aHint (4, 0, 0, 0x16, 3), {R1, MR3}, EMPTY},
+ {"ld8.acq", M, OpMXX6aHint (4, 0, 0, 0x17, 0), {R1, MR3}, EMPTY},
+ {"ld8.acq.nt1", M, OpMXX6aHint (4, 0, 0, 0x17, 1), {R1, MR3}, EMPTY},
+ {"ld8.acq.nta", M, OpMXX6aHint (4, 0, 0, 0x17, 3), {R1, MR3}, EMPTY},
+ {"ld16.acq", M2, OpMXX6aHint (4, 0, 1, 0x2c, 0), {R1, AR_CSD, MR3}, EMPTY},
+ {"ld16.acq.nt1", M2, OpMXX6aHint (4, 0, 1, 0x2c, 1), {R1, AR_CSD, MR3}, EMPTY},
+ {"ld16.acq.nta", M2, OpMXX6aHint (4, 0, 1, 0x2c, 3), {R1, AR_CSD, MR3}, EMPTY},
+ {"ld8.fill", M, OpMXX6aHint (4, 0, 0, 0x1b, 0), {R1, MR3}, EMPTY},
+ {"ld8.fill.nt1", M, OpMXX6aHint (4, 0, 0, 0x1b, 1), {R1, MR3}, EMPTY},
+ {"ld8.fill.nta", M, OpMXX6aHint (4, 0, 0, 0x1b, 3), {R1, MR3}, EMPTY},
+ {"ld1.c.clr", M, OpMXX6aHint (4, 0, 0, 0x20, 0), {R1, MR3}, EMPTY},
+ {"ld1.c.clr.nt1", M, OpMXX6aHint (4, 0, 0, 0x20, 1), {R1, MR3}, EMPTY},
+ {"ld1.c.clr.nta", M, OpMXX6aHint (4, 0, 0, 0x20, 3), {R1, MR3}, EMPTY},
+ {"ld2.c.clr", M, OpMXX6aHint (4, 0, 0, 0x21, 0), {R1, MR3}, EMPTY},
+ {"ld2.c.clr.nt1", M, OpMXX6aHint (4, 0, 0, 0x21, 1), {R1, MR3}, EMPTY},
+ {"ld2.c.clr.nta", M, OpMXX6aHint (4, 0, 0, 0x21, 3), {R1, MR3}, EMPTY},
+ {"ld4.c.clr", M, OpMXX6aHint (4, 0, 0, 0x22, 0), {R1, MR3}, EMPTY},
+ {"ld4.c.clr.nt1", M, OpMXX6aHint (4, 0, 0, 0x22, 1), {R1, MR3}, EMPTY},
+ {"ld4.c.clr.nta", M, OpMXX6aHint (4, 0, 0, 0x22, 3), {R1, MR3}, EMPTY},
+ {"ld8.c.clr", M, OpMXX6aHint (4, 0, 0, 0x23, 0), {R1, MR3}, EMPTY},
+ {"ld8.c.clr.nt1", M, OpMXX6aHint (4, 0, 0, 0x23, 1), {R1, MR3}, EMPTY},
+ {"ld8.c.clr.nta", M, OpMXX6aHint (4, 0, 0, 0x23, 3), {R1, MR3}, EMPTY},
+ {"ld1.c.nc", M, OpMXX6aHint (4, 0, 0, 0x24, 0), {R1, MR3}, EMPTY},
+ {"ld1.c.nc.nt1", M, OpMXX6aHint (4, 0, 0, 0x24, 1), {R1, MR3}, EMPTY},
+ {"ld1.c.nc.nta", M, OpMXX6aHint (4, 0, 0, 0x24, 3), {R1, MR3}, EMPTY},
+ {"ld2.c.nc", M, OpMXX6aHint (4, 0, 0, 0x25, 0), {R1, MR3}, EMPTY},
+ {"ld2.c.nc.nt1", M, OpMXX6aHint (4, 0, 0, 0x25, 1), {R1, MR3}, EMPTY},
+ {"ld2.c.nc.nta", M, OpMXX6aHint (4, 0, 0, 0x25, 3), {R1, MR3}, EMPTY},
+ {"ld4.c.nc", M, OpMXX6aHint (4, 0, 0, 0x26, 0), {R1, MR3}, EMPTY},
+ {"ld4.c.nc.nt1", M, OpMXX6aHint (4, 0, 0, 0x26, 1), {R1, MR3}, EMPTY},
+ {"ld4.c.nc.nta", M, OpMXX6aHint (4, 0, 0, 0x26, 3), {R1, MR3}, EMPTY},
+ {"ld8.c.nc", M, OpMXX6aHint (4, 0, 0, 0x27, 0), {R1, MR3}, EMPTY},
+ {"ld8.c.nc.nt1", M, OpMXX6aHint (4, 0, 0, 0x27, 1), {R1, MR3}, EMPTY},
+ {"ld8.c.nc.nta", M, OpMXX6aHint (4, 0, 0, 0x27, 3), {R1, MR3}, EMPTY},
+ {"ld1.c.clr.acq", M, OpMXX6aHint (4, 0, 0, 0x28, 0), {R1, MR3}, EMPTY},
+ {"ld1.c.clr.acq.nt1", M, OpMXX6aHint (4, 0, 0, 0x28, 1), {R1, MR3}, EMPTY},
+ {"ld1.c.clr.acq.nta", M, OpMXX6aHint (4, 0, 0, 0x28, 3), {R1, MR3}, EMPTY},
+ {"ld2.c.clr.acq", M, OpMXX6aHint (4, 0, 0, 0x29, 0), {R1, MR3}, EMPTY},
+ {"ld2.c.clr.acq.nt1", M, OpMXX6aHint (4, 0, 0, 0x29, 1), {R1, MR3}, EMPTY},
+ {"ld2.c.clr.acq.nta", M, OpMXX6aHint (4, 0, 0, 0x29, 3), {R1, MR3}, EMPTY},
+ {"ld4.c.clr.acq", M, OpMXX6aHint (4, 0, 0, 0x2a, 0), {R1, MR3}, EMPTY},
+ {"ld4.c.clr.acq.nt1", M, OpMXX6aHint (4, 0, 0, 0x2a, 1), {R1, MR3}, EMPTY},
+ {"ld4.c.clr.acq.nta", M, OpMXX6aHint (4, 0, 0, 0x2a, 3), {R1, MR3}, EMPTY},
+ {"ld8.c.clr.acq", M, OpMXX6aHint (4, 0, 0, 0x2b, 0), {R1, MR3}, EMPTY},
+ {"ld8.c.clr.acq.nt1", M, OpMXX6aHint (4, 0, 0, 0x2b, 1), {R1, MR3}, EMPTY},
+ {"ld8.c.clr.acq.nta", M, OpMXX6aHint (4, 0, 0, 0x2b, 3), {R1, MR3}, EMPTY},
+
+ /* Pseudo-op that generates ldxmov relocation. */
+ {"ld8.mov", M, OpMXX6aHint (4, 0, 0, 0x03, 0),
+ {R1, MR3, IA64_OPND_LDXMOV}, EMPTY},
- /* integer load w/increment by register */
-#define LDINCREG(c,h) M, OpMXX6aHint (4, 1, 0, c, h), {R1, MR3, R2}, POSTINC,
+ /* Integer load w/increment by register. */
+#define LDINCREG(c,h) M, OpMXX6aHint (4, 1, 0, c, h), {R1, MR3, R2}, POSTINC, 0, NULL
{"ld1", LDINCREG (0x00, 0)},
{"ld1.nt1", LDINCREG (0x00, 1)},
{"ld1.nta", LDINCREG (0x00, 3)},
@@ -376,26 +400,31 @@ struct ia64_opcode ia64_opcodes_m[] =
{"ld8.c.clr.acq.nta", LDINCREG (0x2b, 3)},
#undef LDINCREG
- {"st1", M, OpMXX6aHint (4, 0, 0, 0x30, 0), {MR3, R2}},
- {"st1.nta", M, OpMXX6aHint (4, 0, 0, 0x30, 3), {MR3, R2}},
- {"st2", M, OpMXX6aHint (4, 0, 0, 0x31, 0), {MR3, R2}},
- {"st2.nta", M, OpMXX6aHint (4, 0, 0, 0x31, 3), {MR3, R2}},
- {"st4", M, OpMXX6aHint (4, 0, 0, 0x32, 0), {MR3, R2}},
- {"st4.nta", M, OpMXX6aHint (4, 0, 0, 0x32, 3), {MR3, R2}},
- {"st8", M, OpMXX6aHint (4, 0, 0, 0x33, 0), {MR3, R2}},
- {"st8.nta", M, OpMXX6aHint (4, 0, 0, 0x33, 3), {MR3, R2}},
- {"st1.rel", M, OpMXX6aHint (4, 0, 0, 0x34, 0), {MR3, R2}},
- {"st1.rel.nta", M, OpMXX6aHint (4, 0, 0, 0x34, 3), {MR3, R2}},
- {"st2.rel", M, OpMXX6aHint (4, 0, 0, 0x35, 0), {MR3, R2}},
- {"st2.rel.nta", M, OpMXX6aHint (4, 0, 0, 0x35, 3), {MR3, R2}},
- {"st4.rel", M, OpMXX6aHint (4, 0, 0, 0x36, 0), {MR3, R2}},
- {"st4.rel.nta", M, OpMXX6aHint (4, 0, 0, 0x36, 3), {MR3, R2}},
- {"st8.rel", M, OpMXX6aHint (4, 0, 0, 0x37, 0), {MR3, R2}},
- {"st8.rel.nta", M, OpMXX6aHint (4, 0, 0, 0x37, 3), {MR3, R2}},
- {"st8.spill", M, OpMXX6aHint (4, 0, 0, 0x3b, 0), {MR3, R2}},
- {"st8.spill.nta", M, OpMXX6aHint (4, 0, 0, 0x3b, 3), {MR3, R2}},
+ {"st1", M, OpMXX6aHint (4, 0, 0, 0x30, 0), {MR3, R2}, EMPTY},
+ {"st1.nta", M, OpMXX6aHint (4, 0, 0, 0x30, 3), {MR3, R2}, EMPTY},
+ {"st2", M, OpMXX6aHint (4, 0, 0, 0x31, 0), {MR3, R2}, EMPTY},
+ {"st2.nta", M, OpMXX6aHint (4, 0, 0, 0x31, 3), {MR3, R2}, EMPTY},
+ {"st4", M, OpMXX6aHint (4, 0, 0, 0x32, 0), {MR3, R2}, EMPTY},
+ {"st4.nta", M, OpMXX6aHint (4, 0, 0, 0x32, 3), {MR3, R2}, EMPTY},
+ {"st8", M, OpMXX6aHint (4, 0, 0, 0x33, 0), {MR3, R2}, EMPTY},
+ {"st8.nta", M, OpMXX6aHint (4, 0, 0, 0x33, 3), {MR3, R2}, EMPTY},
+ {"st16", M, OpMXX6aHint (4, 0, 1, 0x30, 0), {MR3, R2, AR_CSD}, EMPTY},
+ {"st16.nta", M, OpMXX6aHint (4, 0, 1, 0x30, 3), {MR3, R2, AR_CSD}, EMPTY},
+ {"st1.rel", M, OpMXX6aHint (4, 0, 0, 0x34, 0), {MR3, R2}, EMPTY},
+ {"st1.rel.nta", M, OpMXX6aHint (4, 0, 0, 0x34, 3), {MR3, R2}, EMPTY},
+ {"st2.rel", M, OpMXX6aHint (4, 0, 0, 0x35, 0), {MR3, R2}, EMPTY},
+ {"st2.rel.nta", M, OpMXX6aHint (4, 0, 0, 0x35, 3), {MR3, R2}, EMPTY},
+ {"st4.rel", M, OpMXX6aHint (4, 0, 0, 0x36, 0), {MR3, R2}, EMPTY},
+ {"st4.rel.nta", M, OpMXX6aHint (4, 0, 0, 0x36, 3), {MR3, R2}, EMPTY},
+ {"st8.rel", M, OpMXX6aHint (4, 0, 0, 0x37, 0), {MR3, R2}, EMPTY},
+ {"st8.rel.nta", M, OpMXX6aHint (4, 0, 0, 0x37, 3), {MR3, R2}, EMPTY},
+ {"st16.rel", M, OpMXX6aHint (4, 0, 1, 0x34, 0), {MR3, R2, AR_CSD}, EMPTY},
+ {"st16.rel.nta", M, OpMXX6aHint (4, 0, 1, 0x34, 3), {MR3, R2, AR_CSD}, EMPTY},
+ {"st8.spill", M, OpMXX6aHint (4, 0, 0, 0x3b, 0), {MR3, R2}, EMPTY},
+ {"st8.spill.nta", M, OpMXX6aHint (4, 0, 0, 0x3b, 3), {MR3, R2}, EMPTY},
-#define CMPXCHG(c,h) M, OpMXX6aHint (4, 0, 1, c, h), {R1, MR3, R2, AR_CCV}
+#define CMPXCHG(c,h) M, OpMXX6aHint (4, 0, 1, c, h), {R1, MR3, R2, AR_CCV}, EMPTY
+#define CMPXCHG16(c,h) M, OpMXX6aHint (4, 0, 1, c, h), {R1, MR3, R2, AR_CSD, AR_CCV}, EMPTY
{"cmpxchg1.acq", CMPXCHG (0x00, 0)},
{"cmpxchg1.acq.nt1", CMPXCHG (0x00, 1)},
{"cmpxchg1.acq.nta", CMPXCHG (0x00, 3)},
@@ -408,6 +437,9 @@ struct ia64_opcode ia64_opcodes_m[] =
{"cmpxchg8.acq", CMPXCHG (0x03, 0)},
{"cmpxchg8.acq.nt1", CMPXCHG (0x03, 1)},
{"cmpxchg8.acq.nta", CMPXCHG (0x03, 3)},
+ {"cmp8xchg16.acq", CMPXCHG16 (0x20, 0)},
+ {"cmp8xchg16.acq.nt1", CMPXCHG16 (0x20, 1)},
+ {"cmp8xchg16.acq.nta", CMPXCHG16 (0x20, 3)},
{"cmpxchg1.rel", CMPXCHG (0x04, 0)},
{"cmpxchg1.rel.nt1", CMPXCHG (0x04, 1)},
{"cmpxchg1.rel.nta", CMPXCHG (0x04, 3)},
@@ -420,40 +452,44 @@ struct ia64_opcode ia64_opcodes_m[] =
{"cmpxchg8.rel", CMPXCHG (0x07, 0)},
{"cmpxchg8.rel.nt1", CMPXCHG (0x07, 1)},
{"cmpxchg8.rel.nta", CMPXCHG (0x07, 3)},
+ {"cmp8xchg16.rel", CMPXCHG16 (0x24, 0)},
+ {"cmp8xchg16.rel.nt1", CMPXCHG16 (0x24, 1)},
+ {"cmp8xchg16.rel.nta", CMPXCHG16 (0x24, 3)},
#undef CMPXCHG
- {"xchg1", M, OpMXX6aHint (4, 0, 1, 0x08, 0), {R1, MR3, R2}},
- {"xchg1.nt1", M, OpMXX6aHint (4, 0, 1, 0x08, 1), {R1, MR3, R2}},
- {"xchg1.nta", M, OpMXX6aHint (4, 0, 1, 0x08, 3), {R1, MR3, R2}},
- {"xchg2", M, OpMXX6aHint (4, 0, 1, 0x09, 0), {R1, MR3, R2}},
- {"xchg2.nt1", M, OpMXX6aHint (4, 0, 1, 0x09, 1), {R1, MR3, R2}},
- {"xchg2.nta", M, OpMXX6aHint (4, 0, 1, 0x09, 3), {R1, MR3, R2}},
- {"xchg4", M, OpMXX6aHint (4, 0, 1, 0x0a, 0), {R1, MR3, R2}},
- {"xchg4.nt1", M, OpMXX6aHint (4, 0, 1, 0x0a, 1), {R1, MR3, R2}},
- {"xchg4.nta", M, OpMXX6aHint (4, 0, 1, 0x0a, 3), {R1, MR3, R2}},
- {"xchg8", M, OpMXX6aHint (4, 0, 1, 0x0b, 0), {R1, MR3, R2}},
- {"xchg8.nt1", M, OpMXX6aHint (4, 0, 1, 0x0b, 1), {R1, MR3, R2}},
- {"xchg8.nta", M, OpMXX6aHint (4, 0, 1, 0x0b, 3), {R1, MR3, R2}},
+#undef CMPXCHG16
+ {"xchg1", M, OpMXX6aHint (4, 0, 1, 0x08, 0), {R1, MR3, R2}, EMPTY},
+ {"xchg1.nt1", M, OpMXX6aHint (4, 0, 1, 0x08, 1), {R1, MR3, R2}, EMPTY},
+ {"xchg1.nta", M, OpMXX6aHint (4, 0, 1, 0x08, 3), {R1, MR3, R2}, EMPTY},
+ {"xchg2", M, OpMXX6aHint (4, 0, 1, 0x09, 0), {R1, MR3, R2}, EMPTY},
+ {"xchg2.nt1", M, OpMXX6aHint (4, 0, 1, 0x09, 1), {R1, MR3, R2}, EMPTY},
+ {"xchg2.nta", M, OpMXX6aHint (4, 0, 1, 0x09, 3), {R1, MR3, R2}, EMPTY},
+ {"xchg4", M, OpMXX6aHint (4, 0, 1, 0x0a, 0), {R1, MR3, R2}, EMPTY},
+ {"xchg4.nt1", M, OpMXX6aHint (4, 0, 1, 0x0a, 1), {R1, MR3, R2}, EMPTY},
+ {"xchg4.nta", M, OpMXX6aHint (4, 0, 1, 0x0a, 3), {R1, MR3, R2}, EMPTY},
+ {"xchg8", M, OpMXX6aHint (4, 0, 1, 0x0b, 0), {R1, MR3, R2}, EMPTY},
+ {"xchg8.nt1", M, OpMXX6aHint (4, 0, 1, 0x0b, 1), {R1, MR3, R2}, EMPTY},
+ {"xchg8.nta", M, OpMXX6aHint (4, 0, 1, 0x0b, 3), {R1, MR3, R2}, EMPTY},
- {"fetchadd4.acq", M, OpMXX6aHint (4, 0, 1, 0x12, 0), {R1, MR3, INC3}},
- {"fetchadd4.acq.nt1", M, OpMXX6aHint (4, 0, 1, 0x12, 1), {R1, MR3, INC3}},
- {"fetchadd4.acq.nta", M, OpMXX6aHint (4, 0, 1, 0x12, 3), {R1, MR3, INC3}},
- {"fetchadd8.acq", M, OpMXX6aHint (4, 0, 1, 0x13, 0), {R1, MR3, INC3}},
- {"fetchadd8.acq.nt1", M, OpMXX6aHint (4, 0, 1, 0x13, 1), {R1, MR3, INC3}},
- {"fetchadd8.acq.nta", M, OpMXX6aHint (4, 0, 1, 0x13, 3), {R1, MR3, INC3}},
- {"fetchadd4.rel", M, OpMXX6aHint (4, 0, 1, 0x16, 0), {R1, MR3, INC3}},
- {"fetchadd4.rel.nt1", M, OpMXX6aHint (4, 0, 1, 0x16, 1), {R1, MR3, INC3}},
- {"fetchadd4.rel.nta", M, OpMXX6aHint (4, 0, 1, 0x16, 3), {R1, MR3, INC3}},
- {"fetchadd8.rel", M, OpMXX6aHint (4, 0, 1, 0x17, 0), {R1, MR3, INC3}},
- {"fetchadd8.rel.nt1", M, OpMXX6aHint (4, 0, 1, 0x17, 1), {R1, MR3, INC3}},
- {"fetchadd8.rel.nta", M, OpMXX6aHint (4, 0, 1, 0x17, 3), {R1, MR3, INC3}},
+ {"fetchadd4.acq", M, OpMXX6aHint (4, 0, 1, 0x12, 0), {R1, MR3, INC3}, EMPTY},
+ {"fetchadd4.acq.nt1", M, OpMXX6aHint (4, 0, 1, 0x12, 1), {R1, MR3, INC3}, EMPTY},
+ {"fetchadd4.acq.nta", M, OpMXX6aHint (4, 0, 1, 0x12, 3), {R1, MR3, INC3}, EMPTY},
+ {"fetchadd8.acq", M, OpMXX6aHint (4, 0, 1, 0x13, 0), {R1, MR3, INC3}, EMPTY},
+ {"fetchadd8.acq.nt1", M, OpMXX6aHint (4, 0, 1, 0x13, 1), {R1, MR3, INC3}, EMPTY},
+ {"fetchadd8.acq.nta", M, OpMXX6aHint (4, 0, 1, 0x13, 3), {R1, MR3, INC3}, EMPTY},
+ {"fetchadd4.rel", M, OpMXX6aHint (4, 0, 1, 0x16, 0), {R1, MR3, INC3}, EMPTY},
+ {"fetchadd4.rel.nt1", M, OpMXX6aHint (4, 0, 1, 0x16, 1), {R1, MR3, INC3}, EMPTY},
+ {"fetchadd4.rel.nta", M, OpMXX6aHint (4, 0, 1, 0x16, 3), {R1, MR3, INC3}, EMPTY},
+ {"fetchadd8.rel", M, OpMXX6aHint (4, 0, 1, 0x17, 0), {R1, MR3, INC3}, EMPTY},
+ {"fetchadd8.rel.nt1", M, OpMXX6aHint (4, 0, 1, 0x17, 1), {R1, MR3, INC3}, EMPTY},
+ {"fetchadd8.rel.nta", M, OpMXX6aHint (4, 0, 1, 0x17, 3), {R1, MR3, INC3}, EMPTY},
- {"getf.sig", M, OpMXX6a (4, 0, 1, 0x1c), {R1, F2}},
- {"getf.exp", M, OpMXX6a (4, 0, 1, 0x1d), {R1, F2}},
- {"getf.s", M, OpMXX6a (4, 0, 1, 0x1e), {R1, F2}},
- {"getf.d", M, OpMXX6a (4, 0, 1, 0x1f), {R1, F2}},
+ {"getf.sig", M, OpMXX6a (4, 0, 1, 0x1c), {R1, F2}, EMPTY},
+ {"getf.exp", M, OpMXX6a (4, 0, 1, 0x1d), {R1, F2}, EMPTY},
+ {"getf.s", M, OpMXX6a (4, 0, 1, 0x1e), {R1, F2}, EMPTY},
+ {"getf.d", M, OpMXX6a (4, 0, 1, 0x1f), {R1, F2}, EMPTY},
- /* integer load w/increment by immediate */
-#define LDINCIMMED(c,h) M, OpX6aHint (5, c, h), {R1, MR3, IMM9b}, POSTINC
+ /* Integer load w/increment by immediate. */
+#define LDINCIMMED(c,h) M, OpX6aHint (5, c, h), {R1, MR3, IMM9b}, POSTINC, 0, NULL
{"ld1", LDINCIMMED (0x00, 0)},
{"ld1.nt1", LDINCIMMED (0x00, 1)},
{"ld1.nta", LDINCIMMED (0x00, 3)},
@@ -567,8 +603,8 @@ struct ia64_opcode ia64_opcodes_m[] =
{"ld8.c.clr.acq.nta", LDINCIMMED (0x2b, 3)},
#undef LDINCIMMED
- /* store w/increment by immediate */
-#define STINCIMMED(c,h) M, OpX6aHint (5, c, h), {MR3, R2, IMM9a}, POSTINC
+ /* Store w/increment by immediate. */
+#define STINCIMMED(c,h) M, OpX6aHint (5, c, h), {MR3, R2, IMM9a}, POSTINC, 0, NULL
{"st1", STINCIMMED (0x30, 0)},
{"st1.nta", STINCIMMED (0x30, 3)},
{"st2", STINCIMMED (0x31, 0)},
@@ -589,85 +625,85 @@ struct ia64_opcode ia64_opcodes_m[] =
{"st8.spill.nta", STINCIMMED (0x3b, 3)},
#undef STINCIMMED
- /* floating-point load */
- {"ldfs", M, OpMXX6aHint (6, 0, 0, 0x02, 0), {F1, MR3}},
- {"ldfs.nt1", M, OpMXX6aHint (6, 0, 0, 0x02, 1), {F1, MR3}},
- {"ldfs.nta", M, OpMXX6aHint (6, 0, 0, 0x02, 3), {F1, MR3}},
- {"ldfd", M, OpMXX6aHint (6, 0, 0, 0x03, 0), {F1, MR3}},
- {"ldfd.nt1", M, OpMXX6aHint (6, 0, 0, 0x03, 1), {F1, MR3}},
- {"ldfd.nta", M, OpMXX6aHint (6, 0, 0, 0x03, 3), {F1, MR3}},
- {"ldf8", M, OpMXX6aHint (6, 0, 0, 0x01, 0), {F1, MR3}},
- {"ldf8.nt1", M, OpMXX6aHint (6, 0, 0, 0x01, 1), {F1, MR3}},
- {"ldf8.nta", M, OpMXX6aHint (6, 0, 0, 0x01, 3), {F1, MR3}},
- {"ldfe", M, OpMXX6aHint (6, 0, 0, 0x00, 0), {F1, MR3}},
- {"ldfe.nt1", M, OpMXX6aHint (6, 0, 0, 0x00, 1), {F1, MR3}},
- {"ldfe.nta", M, OpMXX6aHint (6, 0, 0, 0x00, 3), {F1, MR3}},
- {"ldfs.s", M, OpMXX6aHint (6, 0, 0, 0x06, 0), {F1, MR3}},
- {"ldfs.s.nt1", M, OpMXX6aHint (6, 0, 0, 0x06, 1), {F1, MR3}},
- {"ldfs.s.nta", M, OpMXX6aHint (6, 0, 0, 0x06, 3), {F1, MR3}},
- {"ldfd.s", M, OpMXX6aHint (6, 0, 0, 0x07, 0), {F1, MR3}},
- {"ldfd.s.nt1", M, OpMXX6aHint (6, 0, 0, 0x07, 1), {F1, MR3}},
- {"ldfd.s.nta", M, OpMXX6aHint (6, 0, 0, 0x07, 3), {F1, MR3}},
- {"ldf8.s", M, OpMXX6aHint (6, 0, 0, 0x05, 0), {F1, MR3}},
- {"ldf8.s.nt1", M, OpMXX6aHint (6, 0, 0, 0x05, 1), {F1, MR3}},
- {"ldf8.s.nta", M, OpMXX6aHint (6, 0, 0, 0x05, 3), {F1, MR3}},
- {"ldfe.s", M, OpMXX6aHint (6, 0, 0, 0x04, 0), {F1, MR3}},
- {"ldfe.s.nt1", M, OpMXX6aHint (6, 0, 0, 0x04, 1), {F1, MR3}},
- {"ldfe.s.nta", M, OpMXX6aHint (6, 0, 0, 0x04, 3), {F1, MR3}},
- {"ldfs.a", M, OpMXX6aHint (6, 0, 0, 0x0a, 0), {F1, MR3}},
- {"ldfs.a.nt1", M, OpMXX6aHint (6, 0, 0, 0x0a, 1), {F1, MR3}},
- {"ldfs.a.nta", M, OpMXX6aHint (6, 0, 0, 0x0a, 3), {F1, MR3}},
- {"ldfd.a", M, OpMXX6aHint (6, 0, 0, 0x0b, 0), {F1, MR3}},
- {"ldfd.a.nt1", M, OpMXX6aHint (6, 0, 0, 0x0b, 1), {F1, MR3}},
- {"ldfd.a.nta", M, OpMXX6aHint (6, 0, 0, 0x0b, 3), {F1, MR3}},
- {"ldf8.a", M, OpMXX6aHint (6, 0, 0, 0x09, 0), {F1, MR3}},
- {"ldf8.a.nt1", M, OpMXX6aHint (6, 0, 0, 0x09, 1), {F1, MR3}},
- {"ldf8.a.nta", M, OpMXX6aHint (6, 0, 0, 0x09, 3), {F1, MR3}},
- {"ldfe.a", M, OpMXX6aHint (6, 0, 0, 0x08, 0), {F1, MR3}},
- {"ldfe.a.nt1", M, OpMXX6aHint (6, 0, 0, 0x08, 1), {F1, MR3}},
- {"ldfe.a.nta", M, OpMXX6aHint (6, 0, 0, 0x08, 3), {F1, MR3}},
- {"ldfs.sa", M, OpMXX6aHint (6, 0, 0, 0x0e, 0), {F1, MR3}},
- {"ldfs.sa.nt1", M, OpMXX6aHint (6, 0, 0, 0x0e, 1), {F1, MR3}},
- {"ldfs.sa.nta", M, OpMXX6aHint (6, 0, 0, 0x0e, 3), {F1, MR3}},
- {"ldfd.sa", M, OpMXX6aHint (6, 0, 0, 0x0f, 0), {F1, MR3}},
- {"ldfd.sa.nt1", M, OpMXX6aHint (6, 0, 0, 0x0f, 1), {F1, MR3}},
- {"ldfd.sa.nta", M, OpMXX6aHint (6, 0, 0, 0x0f, 3), {F1, MR3}},
- {"ldf8.sa", M, OpMXX6aHint (6, 0, 0, 0x0d, 0), {F1, MR3}},
- {"ldf8.sa.nt1", M, OpMXX6aHint (6, 0, 0, 0x0d, 1), {F1, MR3}},
- {"ldf8.sa.nta", M, OpMXX6aHint (6, 0, 0, 0x0d, 3), {F1, MR3}},
- {"ldfe.sa", M, OpMXX6aHint (6, 0, 0, 0x0c, 0), {F1, MR3}},
- {"ldfe.sa.nt1", M, OpMXX6aHint (6, 0, 0, 0x0c, 1), {F1, MR3}},
- {"ldfe.sa.nta", M, OpMXX6aHint (6, 0, 0, 0x0c, 3), {F1, MR3}},
- {"ldf.fill", M, OpMXX6aHint (6, 0, 0, 0x1b, 0), {F1, MR3}},
- {"ldf.fill.nt1", M, OpMXX6aHint (6, 0, 0, 0x1b, 1), {F1, MR3}},
- {"ldf.fill.nta", M, OpMXX6aHint (6, 0, 0, 0x1b, 3), {F1, MR3}},
- {"ldfs.c.clr", M, OpMXX6aHint (6, 0, 0, 0x22, 0), {F1, MR3}},
- {"ldfs.c.clr.nt1", M, OpMXX6aHint (6, 0, 0, 0x22, 1), {F1, MR3}},
- {"ldfs.c.clr.nta", M, OpMXX6aHint (6, 0, 0, 0x22, 3), {F1, MR3}},
- {"ldfd.c.clr", M, OpMXX6aHint (6, 0, 0, 0x23, 0), {F1, MR3}},
- {"ldfd.c.clr.nt1", M, OpMXX6aHint (6, 0, 0, 0x23, 1), {F1, MR3}},
- {"ldfd.c.clr.nta", M, OpMXX6aHint (6, 0, 0, 0x23, 3), {F1, MR3}},
- {"ldf8.c.clr", M, OpMXX6aHint (6, 0, 0, 0x21, 0), {F1, MR3}},
- {"ldf8.c.clr.nt1", M, OpMXX6aHint (6, 0, 0, 0x21, 1), {F1, MR3}},
- {"ldf8.c.clr.nta", M, OpMXX6aHint (6, 0, 0, 0x21, 3), {F1, MR3}},
- {"ldfe.c.clr", M, OpMXX6aHint (6, 0, 0, 0x20, 0), {F1, MR3}},
- {"ldfe.c.clr.nt1", M, OpMXX6aHint (6, 0, 0, 0x20, 1), {F1, MR3}},
- {"ldfe.c.clr.nta", M, OpMXX6aHint (6, 0, 0, 0x20, 3), {F1, MR3}},
- {"ldfs.c.nc", M, OpMXX6aHint (6, 0, 0, 0x26, 0), {F1, MR3}},
- {"ldfs.c.nc.nt1", M, OpMXX6aHint (6, 0, 0, 0x26, 1), {F1, MR3}},
- {"ldfs.c.nc.nta", M, OpMXX6aHint (6, 0, 0, 0x26, 3), {F1, MR3}},
- {"ldfd.c.nc", M, OpMXX6aHint (6, 0, 0, 0x27, 0), {F1, MR3}},
- {"ldfd.c.nc.nt1", M, OpMXX6aHint (6, 0, 0, 0x27, 1), {F1, MR3}},
- {"ldfd.c.nc.nta", M, OpMXX6aHint (6, 0, 0, 0x27, 3), {F1, MR3}},
- {"ldf8.c.nc", M, OpMXX6aHint (6, 0, 0, 0x25, 0), {F1, MR3}},
- {"ldf8.c.nc.nt1", M, OpMXX6aHint (6, 0, 0, 0x25, 1), {F1, MR3}},
- {"ldf8.c.nc.nta", M, OpMXX6aHint (6, 0, 0, 0x25, 3), {F1, MR3}},
- {"ldfe.c.nc", M, OpMXX6aHint (6, 0, 0, 0x24, 0), {F1, MR3}},
- {"ldfe.c.nc.nt1", M, OpMXX6aHint (6, 0, 0, 0x24, 1), {F1, MR3}},
- {"ldfe.c.nc.nta", M, OpMXX6aHint (6, 0, 0, 0x24, 3), {F1, MR3}},
+ /* Floating-point load. */
+ {"ldfs", M, OpMXX6aHint (6, 0, 0, 0x02, 0), {F1, MR3}, EMPTY},
+ {"ldfs.nt1", M, OpMXX6aHint (6, 0, 0, 0x02, 1), {F1, MR3}, EMPTY},
+ {"ldfs.nta", M, OpMXX6aHint (6, 0, 0, 0x02, 3), {F1, MR3}, EMPTY},
+ {"ldfd", M, OpMXX6aHint (6, 0, 0, 0x03, 0), {F1, MR3}, EMPTY},
+ {"ldfd.nt1", M, OpMXX6aHint (6, 0, 0, 0x03, 1), {F1, MR3}, EMPTY},
+ {"ldfd.nta", M, OpMXX6aHint (6, 0, 0, 0x03, 3), {F1, MR3}, EMPTY},
+ {"ldf8", M, OpMXX6aHint (6, 0, 0, 0x01, 0), {F1, MR3}, EMPTY},
+ {"ldf8.nt1", M, OpMXX6aHint (6, 0, 0, 0x01, 1), {F1, MR3}, EMPTY},
+ {"ldf8.nta", M, OpMXX6aHint (6, 0, 0, 0x01, 3), {F1, MR3}, EMPTY},
+ {"ldfe", M, OpMXX6aHint (6, 0, 0, 0x00, 0), {F1, MR3}, EMPTY},
+ {"ldfe.nt1", M, OpMXX6aHint (6, 0, 0, 0x00, 1), {F1, MR3}, EMPTY},
+ {"ldfe.nta", M, OpMXX6aHint (6, 0, 0, 0x00, 3), {F1, MR3}, EMPTY},
+ {"ldfs.s", M, OpMXX6aHint (6, 0, 0, 0x06, 0), {F1, MR3}, EMPTY},
+ {"ldfs.s.nt1", M, OpMXX6aHint (6, 0, 0, 0x06, 1), {F1, MR3}, EMPTY},
+ {"ldfs.s.nta", M, OpMXX6aHint (6, 0, 0, 0x06, 3), {F1, MR3}, EMPTY},
+ {"ldfd.s", M, OpMXX6aHint (6, 0, 0, 0x07, 0), {F1, MR3}, EMPTY},
+ {"ldfd.s.nt1", M, OpMXX6aHint (6, 0, 0, 0x07, 1), {F1, MR3}, EMPTY},
+ {"ldfd.s.nta", M, OpMXX6aHint (6, 0, 0, 0x07, 3), {F1, MR3}, EMPTY},
+ {"ldf8.s", M, OpMXX6aHint (6, 0, 0, 0x05, 0), {F1, MR3}, EMPTY},
+ {"ldf8.s.nt1", M, OpMXX6aHint (6, 0, 0, 0x05, 1), {F1, MR3}, EMPTY},
+ {"ldf8.s.nta", M, OpMXX6aHint (6, 0, 0, 0x05, 3), {F1, MR3}, EMPTY},
+ {"ldfe.s", M, OpMXX6aHint (6, 0, 0, 0x04, 0), {F1, MR3}, EMPTY},
+ {"ldfe.s.nt1", M, OpMXX6aHint (6, 0, 0, 0x04, 1), {F1, MR3}, EMPTY},
+ {"ldfe.s.nta", M, OpMXX6aHint (6, 0, 0, 0x04, 3), {F1, MR3}, EMPTY},
+ {"ldfs.a", M, OpMXX6aHint (6, 0, 0, 0x0a, 0), {F1, MR3}, EMPTY},
+ {"ldfs.a.nt1", M, OpMXX6aHint (6, 0, 0, 0x0a, 1), {F1, MR3}, EMPTY},
+ {"ldfs.a.nta", M, OpMXX6aHint (6, 0, 0, 0x0a, 3), {F1, MR3}, EMPTY},
+ {"ldfd.a", M, OpMXX6aHint (6, 0, 0, 0x0b, 0), {F1, MR3}, EMPTY},
+ {"ldfd.a.nt1", M, OpMXX6aHint (6, 0, 0, 0x0b, 1), {F1, MR3}, EMPTY},
+ {"ldfd.a.nta", M, OpMXX6aHint (6, 0, 0, 0x0b, 3), {F1, MR3}, EMPTY},
+ {"ldf8.a", M, OpMXX6aHint (6, 0, 0, 0x09, 0), {F1, MR3}, EMPTY},
+ {"ldf8.a.nt1", M, OpMXX6aHint (6, 0, 0, 0x09, 1), {F1, MR3}, EMPTY},
+ {"ldf8.a.nta", M, OpMXX6aHint (6, 0, 0, 0x09, 3), {F1, MR3}, EMPTY},
+ {"ldfe.a", M, OpMXX6aHint (6, 0, 0, 0x08, 0), {F1, MR3}, EMPTY},
+ {"ldfe.a.nt1", M, OpMXX6aHint (6, 0, 0, 0x08, 1), {F1, MR3}, EMPTY},
+ {"ldfe.a.nta", M, OpMXX6aHint (6, 0, 0, 0x08, 3), {F1, MR3}, EMPTY},
+ {"ldfs.sa", M, OpMXX6aHint (6, 0, 0, 0x0e, 0), {F1, MR3}, EMPTY},
+ {"ldfs.sa.nt1", M, OpMXX6aHint (6, 0, 0, 0x0e, 1), {F1, MR3}, EMPTY},
+ {"ldfs.sa.nta", M, OpMXX6aHint (6, 0, 0, 0x0e, 3), {F1, MR3}, EMPTY},
+ {"ldfd.sa", M, OpMXX6aHint (6, 0, 0, 0x0f, 0), {F1, MR3}, EMPTY},
+ {"ldfd.sa.nt1", M, OpMXX6aHint (6, 0, 0, 0x0f, 1), {F1, MR3}, EMPTY},
+ {"ldfd.sa.nta", M, OpMXX6aHint (6, 0, 0, 0x0f, 3), {F1, MR3}, EMPTY},
+ {"ldf8.sa", M, OpMXX6aHint (6, 0, 0, 0x0d, 0), {F1, MR3}, EMPTY},
+ {"ldf8.sa.nt1", M, OpMXX6aHint (6, 0, 0, 0x0d, 1), {F1, MR3}, EMPTY},
+ {"ldf8.sa.nta", M, OpMXX6aHint (6, 0, 0, 0x0d, 3), {F1, MR3}, EMPTY},
+ {"ldfe.sa", M, OpMXX6aHint (6, 0, 0, 0x0c, 0), {F1, MR3}, EMPTY},
+ {"ldfe.sa.nt1", M, OpMXX6aHint (6, 0, 0, 0x0c, 1), {F1, MR3}, EMPTY},
+ {"ldfe.sa.nta", M, OpMXX6aHint (6, 0, 0, 0x0c, 3), {F1, MR3}, EMPTY},
+ {"ldf.fill", M, OpMXX6aHint (6, 0, 0, 0x1b, 0), {F1, MR3}, EMPTY},
+ {"ldf.fill.nt1", M, OpMXX6aHint (6, 0, 0, 0x1b, 1), {F1, MR3}, EMPTY},
+ {"ldf.fill.nta", M, OpMXX6aHint (6, 0, 0, 0x1b, 3), {F1, MR3}, EMPTY},
+ {"ldfs.c.clr", M, OpMXX6aHint (6, 0, 0, 0x22, 0), {F1, MR3}, EMPTY},
+ {"ldfs.c.clr.nt1", M, OpMXX6aHint (6, 0, 0, 0x22, 1), {F1, MR3}, EMPTY},
+ {"ldfs.c.clr.nta", M, OpMXX6aHint (6, 0, 0, 0x22, 3), {F1, MR3}, EMPTY},
+ {"ldfd.c.clr", M, OpMXX6aHint (6, 0, 0, 0x23, 0), {F1, MR3}, EMPTY},
+ {"ldfd.c.clr.nt1", M, OpMXX6aHint (6, 0, 0, 0x23, 1), {F1, MR3}, EMPTY},
+ {"ldfd.c.clr.nta", M, OpMXX6aHint (6, 0, 0, 0x23, 3), {F1, MR3}, EMPTY},
+ {"ldf8.c.clr", M, OpMXX6aHint (6, 0, 0, 0x21, 0), {F1, MR3}, EMPTY},
+ {"ldf8.c.clr.nt1", M, OpMXX6aHint (6, 0, 0, 0x21, 1), {F1, MR3}, EMPTY},
+ {"ldf8.c.clr.nta", M, OpMXX6aHint (6, 0, 0, 0x21, 3), {F1, MR3}, EMPTY},
+ {"ldfe.c.clr", M, OpMXX6aHint (6, 0, 0, 0x20, 0), {F1, MR3}, EMPTY},
+ {"ldfe.c.clr.nt1", M, OpMXX6aHint (6, 0, 0, 0x20, 1), {F1, MR3}, EMPTY},
+ {"ldfe.c.clr.nta", M, OpMXX6aHint (6, 0, 0, 0x20, 3), {F1, MR3}, EMPTY},
+ {"ldfs.c.nc", M, OpMXX6aHint (6, 0, 0, 0x26, 0), {F1, MR3}, EMPTY},
+ {"ldfs.c.nc.nt1", M, OpMXX6aHint (6, 0, 0, 0x26, 1), {F1, MR3}, EMPTY},
+ {"ldfs.c.nc.nta", M, OpMXX6aHint (6, 0, 0, 0x26, 3), {F1, MR3}, EMPTY},
+ {"ldfd.c.nc", M, OpMXX6aHint (6, 0, 0, 0x27, 0), {F1, MR3}, EMPTY},
+ {"ldfd.c.nc.nt1", M, OpMXX6aHint (6, 0, 0, 0x27, 1), {F1, MR3}, EMPTY},
+ {"ldfd.c.nc.nta", M, OpMXX6aHint (6, 0, 0, 0x27, 3), {F1, MR3}, EMPTY},
+ {"ldf8.c.nc", M, OpMXX6aHint (6, 0, 0, 0x25, 0), {F1, MR3}, EMPTY},
+ {"ldf8.c.nc.nt1", M, OpMXX6aHint (6, 0, 0, 0x25, 1), {F1, MR3}, EMPTY},
+ {"ldf8.c.nc.nta", M, OpMXX6aHint (6, 0, 0, 0x25, 3), {F1, MR3}, EMPTY},
+ {"ldfe.c.nc", M, OpMXX6aHint (6, 0, 0, 0x24, 0), {F1, MR3}, EMPTY},
+ {"ldfe.c.nc.nt1", M, OpMXX6aHint (6, 0, 0, 0x24, 1), {F1, MR3}, EMPTY},
+ {"ldfe.c.nc.nta", M, OpMXX6aHint (6, 0, 0, 0x24, 3), {F1, MR3}, EMPTY},
- /* floating-point load w/increment by register */
-#define FLDINCREG(c,h) M, OpMXX6aHint (6, 1, 0, c, h), {F1, MR3, R2}, POSTINC
+ /* Floating-point load w/increment by register. */
+#define FLDINCREG(c,h) M, OpMXX6aHint (6, 1, 0, c, h), {F1, MR3, R2}, POSTINC, 0, NULL
{"ldfs", FLDINCREG (0x02, 0)},
{"ldfs.nt1", FLDINCREG (0x02, 1)},
{"ldfs.nta", FLDINCREG (0x02, 3)},
@@ -745,76 +781,76 @@ struct ia64_opcode ia64_opcodes_m[] =
{"ldfe.c.nc.nta", FLDINCREG (0x24, 3)},
#undef FLDINCREG
- /* floating-point store */
- {"stfs", M, OpMXX6aHint (6, 0, 0, 0x32, 0), {MR3, F2}},
- {"stfs.nta", M, OpMXX6aHint (6, 0, 0, 0x32, 3), {MR3, F2}},
- {"stfd", M, OpMXX6aHint (6, 0, 0, 0x33, 0), {MR3, F2}},
- {"stfd.nta", M, OpMXX6aHint (6, 0, 0, 0x33, 3), {MR3, F2}},
- {"stf8", M, OpMXX6aHint (6, 0, 0, 0x31, 0), {MR3, F2}},
- {"stf8.nta", M, OpMXX6aHint (6, 0, 0, 0x31, 3), {MR3, F2}},
- {"stfe", M, OpMXX6aHint (6, 0, 0, 0x30, 0), {MR3, F2}},
- {"stfe.nta", M, OpMXX6aHint (6, 0, 0, 0x30, 3), {MR3, F2}},
- {"stf.spill", M, OpMXX6aHint (6, 0, 0, 0x3b, 0), {MR3, F2}},
- {"stf.spill.nta", M, OpMXX6aHint (6, 0, 0, 0x3b, 3), {MR3, F2}},
+ /* Floating-point store. */
+ {"stfs", M, OpMXX6aHint (6, 0, 0, 0x32, 0), {MR3, F2}, EMPTY},
+ {"stfs.nta", M, OpMXX6aHint (6, 0, 0, 0x32, 3), {MR3, F2}, EMPTY},
+ {"stfd", M, OpMXX6aHint (6, 0, 0, 0x33, 0), {MR3, F2}, EMPTY},
+ {"stfd.nta", M, OpMXX6aHint (6, 0, 0, 0x33, 3), {MR3, F2}, EMPTY},
+ {"stf8", M, OpMXX6aHint (6, 0, 0, 0x31, 0), {MR3, F2}, EMPTY},
+ {"stf8.nta", M, OpMXX6aHint (6, 0, 0, 0x31, 3), {MR3, F2}, EMPTY},
+ {"stfe", M, OpMXX6aHint (6, 0, 0, 0x30, 0), {MR3, F2}, EMPTY},
+ {"stfe.nta", M, OpMXX6aHint (6, 0, 0, 0x30, 3), {MR3, F2}, EMPTY},
+ {"stf.spill", M, OpMXX6aHint (6, 0, 0, 0x3b, 0), {MR3, F2}, EMPTY},
+ {"stf.spill.nta", M, OpMXX6aHint (6, 0, 0, 0x3b, 3), {MR3, F2}, EMPTY},
- /* floating-point load pair */
- {"ldfps", M2, OpMXX6aHint (6, 0, 1, 0x02, 0), {F1, F2, MR3}},
- {"ldfps.nt1", M2, OpMXX6aHint (6, 0, 1, 0x02, 1), {F1, F2, MR3}},
- {"ldfps.nta", M2, OpMXX6aHint (6, 0, 1, 0x02, 3), {F1, F2, MR3}},
- {"ldfpd", M2, OpMXX6aHint (6, 0, 1, 0x03, 0), {F1, F2, MR3}},
- {"ldfpd.nt1", M2, OpMXX6aHint (6, 0, 1, 0x03, 1), {F1, F2, MR3}},
- {"ldfpd.nta", M2, OpMXX6aHint (6, 0, 1, 0x03, 3), {F1, F2, MR3}},
- {"ldfp8", M2, OpMXX6aHint (6, 0, 1, 0x01, 0), {F1, F2, MR3}},
- {"ldfp8.nt1", M2, OpMXX6aHint (6, 0, 1, 0x01, 1), {F1, F2, MR3}},
- {"ldfp8.nta", M2, OpMXX6aHint (6, 0, 1, 0x01, 3), {F1, F2, MR3}},
- {"ldfps.s", M2, OpMXX6aHint (6, 0, 1, 0x06, 0), {F1, F2, MR3}},
- {"ldfps.s.nt1", M2, OpMXX6aHint (6, 0, 1, 0x06, 1), {F1, F2, MR3}},
- {"ldfps.s.nta", M2, OpMXX6aHint (6, 0, 1, 0x06, 3), {F1, F2, MR3}},
- {"ldfpd.s", M2, OpMXX6aHint (6, 0, 1, 0x07, 0), {F1, F2, MR3}},
- {"ldfpd.s.nt1", M2, OpMXX6aHint (6, 0, 1, 0x07, 1), {F1, F2, MR3}},
- {"ldfpd.s.nta", M2, OpMXX6aHint (6, 0, 1, 0x07, 3), {F1, F2, MR3}},
- {"ldfp8.s", M2, OpMXX6aHint (6, 0, 1, 0x05, 0), {F1, F2, MR3}},
- {"ldfp8.s.nt1", M2, OpMXX6aHint (6, 0, 1, 0x05, 1), {F1, F2, MR3}},
- {"ldfp8.s.nta", M2, OpMXX6aHint (6, 0, 1, 0x05, 3), {F1, F2, MR3}},
- {"ldfps.a", M2, OpMXX6aHint (6, 0, 1, 0x0a, 0), {F1, F2, MR3}},
- {"ldfps.a.nt1", M2, OpMXX6aHint (6, 0, 1, 0x0a, 1), {F1, F2, MR3}},
- {"ldfps.a.nta", M2, OpMXX6aHint (6, 0, 1, 0x0a, 3), {F1, F2, MR3}},
- {"ldfpd.a", M2, OpMXX6aHint (6, 0, 1, 0x0b, 0), {F1, F2, MR3}},
- {"ldfpd.a.nt1", M2, OpMXX6aHint (6, 0, 1, 0x0b, 1), {F1, F2, MR3}},
- {"ldfpd.a.nta", M2, OpMXX6aHint (6, 0, 1, 0x0b, 3), {F1, F2, MR3}},
- {"ldfp8.a", M2, OpMXX6aHint (6, 0, 1, 0x09, 0), {F1, F2, MR3}},
- {"ldfp8.a.nt1", M2, OpMXX6aHint (6, 0, 1, 0x09, 1), {F1, F2, MR3}},
- {"ldfp8.a.nta", M2, OpMXX6aHint (6, 0, 1, 0x09, 3), {F1, F2, MR3}},
- {"ldfps.sa", M2, OpMXX6aHint (6, 0, 1, 0x0e, 0), {F1, F2, MR3}},
- {"ldfps.sa.nt1", M2, OpMXX6aHint (6, 0, 1, 0x0e, 1), {F1, F2, MR3}},
- {"ldfps.sa.nta", M2, OpMXX6aHint (6, 0, 1, 0x0e, 3), {F1, F2, MR3}},
- {"ldfpd.sa", M2, OpMXX6aHint (6, 0, 1, 0x0f, 0), {F1, F2, MR3}},
- {"ldfpd.sa.nt1", M2, OpMXX6aHint (6, 0, 1, 0x0f, 1), {F1, F2, MR3}},
- {"ldfpd.sa.nta", M2, OpMXX6aHint (6, 0, 1, 0x0f, 3), {F1, F2, MR3}},
- {"ldfp8.sa", M2, OpMXX6aHint (6, 0, 1, 0x0d, 0), {F1, F2, MR3}},
- {"ldfp8.sa.nt1", M2, OpMXX6aHint (6, 0, 1, 0x0d, 1), {F1, F2, MR3}},
- {"ldfp8.sa.nta", M2, OpMXX6aHint (6, 0, 1, 0x0d, 3), {F1, F2, MR3}},
- {"ldfps.c.clr", M2, OpMXX6aHint (6, 0, 1, 0x22, 0), {F1, F2, MR3}},
- {"ldfps.c.clr.nt1", M2, OpMXX6aHint (6, 0, 1, 0x22, 1), {F1, F2, MR3}},
- {"ldfps.c.clr.nta", M2, OpMXX6aHint (6, 0, 1, 0x22, 3), {F1, F2, MR3}},
- {"ldfpd.c.clr", M2, OpMXX6aHint (6, 0, 1, 0x23, 0), {F1, F2, MR3}},
- {"ldfpd.c.clr.nt1", M2, OpMXX6aHint (6, 0, 1, 0x23, 1), {F1, F2, MR3}},
- {"ldfpd.c.clr.nta", M2, OpMXX6aHint (6, 0, 1, 0x23, 3), {F1, F2, MR3}},
- {"ldfp8.c.clr", M2, OpMXX6aHint (6, 0, 1, 0x21, 0), {F1, F2, MR3}},
- {"ldfp8.c.clr.nt1", M2, OpMXX6aHint (6, 0, 1, 0x21, 1), {F1, F2, MR3}},
- {"ldfp8.c.clr.nta", M2, OpMXX6aHint (6, 0, 1, 0x21, 3), {F1, F2, MR3}},
- {"ldfps.c.nc", M2, OpMXX6aHint (6, 0, 1, 0x26, 0), {F1, F2, MR3}},
- {"ldfps.c.nc.nt1", M2, OpMXX6aHint (6, 0, 1, 0x26, 1), {F1, F2, MR3}},
- {"ldfps.c.nc.nta", M2, OpMXX6aHint (6, 0, 1, 0x26, 3), {F1, F2, MR3}},
- {"ldfpd.c.nc", M2, OpMXX6aHint (6, 0, 1, 0x27, 0), {F1, F2, MR3}},
- {"ldfpd.c.nc.nt1", M2, OpMXX6aHint (6, 0, 1, 0x27, 1), {F1, F2, MR3}},
- {"ldfpd.c.nc.nta", M2, OpMXX6aHint (6, 0, 1, 0x27, 3), {F1, F2, MR3}},
- {"ldfp8.c.nc", M2, OpMXX6aHint (6, 0, 1, 0x25, 0), {F1, F2, MR3}},
- {"ldfp8.c.nc.nt1", M2, OpMXX6aHint (6, 0, 1, 0x25, 1), {F1, F2, MR3}},
- {"ldfp8.c.nc.nta", M2, OpMXX6aHint (6, 0, 1, 0x25, 3), {F1, F2, MR3}},
+ /* Floating-point load pair. */
+ {"ldfps", M2, OpMXX6aHint (6, 0, 1, 0x02, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfps.nt1", M2, OpMXX6aHint (6, 0, 1, 0x02, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfps.nta", M2, OpMXX6aHint (6, 0, 1, 0x02, 3), {F1, F2, MR3}, EMPTY},
+ {"ldfpd", M2, OpMXX6aHint (6, 0, 1, 0x03, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfpd.nt1", M2, OpMXX6aHint (6, 0, 1, 0x03, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfpd.nta", M2, OpMXX6aHint (6, 0, 1, 0x03, 3), {F1, F2, MR3}, EMPTY},
+ {"ldfp8", M2, OpMXX6aHint (6, 0, 1, 0x01, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfp8.nt1", M2, OpMXX6aHint (6, 0, 1, 0x01, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfp8.nta", M2, OpMXX6aHint (6, 0, 1, 0x01, 3), {F1, F2, MR3}, EMPTY},
+ {"ldfps.s", M2, OpMXX6aHint (6, 0, 1, 0x06, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfps.s.nt1", M2, OpMXX6aHint (6, 0, 1, 0x06, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfps.s.nta", M2, OpMXX6aHint (6, 0, 1, 0x06, 3), {F1, F2, MR3}, EMPTY},
+ {"ldfpd.s", M2, OpMXX6aHint (6, 0, 1, 0x07, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfpd.s.nt1", M2, OpMXX6aHint (6, 0, 1, 0x07, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfpd.s.nta", M2, OpMXX6aHint (6, 0, 1, 0x07, 3), {F1, F2, MR3}, EMPTY},
+ {"ldfp8.s", M2, OpMXX6aHint (6, 0, 1, 0x05, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfp8.s.nt1", M2, OpMXX6aHint (6, 0, 1, 0x05, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfp8.s.nta", M2, OpMXX6aHint (6, 0, 1, 0x05, 3), {F1, F2, MR3}, EMPTY},
+ {"ldfps.a", M2, OpMXX6aHint (6, 0, 1, 0x0a, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfps.a.nt1", M2, OpMXX6aHint (6, 0, 1, 0x0a, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfps.a.nta", M2, OpMXX6aHint (6, 0, 1, 0x0a, 3), {F1, F2, MR3}, EMPTY},
+ {"ldfpd.a", M2, OpMXX6aHint (6, 0, 1, 0x0b, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfpd.a.nt1", M2, OpMXX6aHint (6, 0, 1, 0x0b, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfpd.a.nta", M2, OpMXX6aHint (6, 0, 1, 0x0b, 3), {F1, F2, MR3}, EMPTY},
+ {"ldfp8.a", M2, OpMXX6aHint (6, 0, 1, 0x09, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfp8.a.nt1", M2, OpMXX6aHint (6, 0, 1, 0x09, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfp8.a.nta", M2, OpMXX6aHint (6, 0, 1, 0x09, 3), {F1, F2, MR3}, EMPTY},
+ {"ldfps.sa", M2, OpMXX6aHint (6, 0, 1, 0x0e, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfps.sa.nt1", M2, OpMXX6aHint (6, 0, 1, 0x0e, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfps.sa.nta", M2, OpMXX6aHint (6, 0, 1, 0x0e, 3), {F1, F2, MR3}, EMPTY},
+ {"ldfpd.sa", M2, OpMXX6aHint (6, 0, 1, 0x0f, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfpd.sa.nt1", M2, OpMXX6aHint (6, 0, 1, 0x0f, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfpd.sa.nta", M2, OpMXX6aHint (6, 0, 1, 0x0f, 3), {F1, F2, MR3}, EMPTY},
+ {"ldfp8.sa", M2, OpMXX6aHint (6, 0, 1, 0x0d, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfp8.sa.nt1", M2, OpMXX6aHint (6, 0, 1, 0x0d, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfp8.sa.nta", M2, OpMXX6aHint (6, 0, 1, 0x0d, 3), {F1, F2, MR3}, EMPTY},
+ {"ldfps.c.clr", M2, OpMXX6aHint (6, 0, 1, 0x22, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfps.c.clr.nt1", M2, OpMXX6aHint (6, 0, 1, 0x22, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfps.c.clr.nta", M2, OpMXX6aHint (6, 0, 1, 0x22, 3), {F1, F2, MR3}, EMPTY},
+ {"ldfpd.c.clr", M2, OpMXX6aHint (6, 0, 1, 0x23, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfpd.c.clr.nt1", M2, OpMXX6aHint (6, 0, 1, 0x23, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfpd.c.clr.nta", M2, OpMXX6aHint (6, 0, 1, 0x23, 3), {F1, F2, MR3}, EMPTY},
+ {"ldfp8.c.clr", M2, OpMXX6aHint (6, 0, 1, 0x21, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfp8.c.clr.nt1", M2, OpMXX6aHint (6, 0, 1, 0x21, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfp8.c.clr.nta", M2, OpMXX6aHint (6, 0, 1, 0x21, 3), {F1, F2, MR3}, EMPTY},
+ {"ldfps.c.nc", M2, OpMXX6aHint (6, 0, 1, 0x26, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfps.c.nc.nt1", M2, OpMXX6aHint (6, 0, 1, 0x26, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfps.c.nc.nta", M2, OpMXX6aHint (6, 0, 1, 0x26, 3), {F1, F2, MR3}, EMPTY},
+ {"ldfpd.c.nc", M2, OpMXX6aHint (6, 0, 1, 0x27, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfpd.c.nc.nt1", M2, OpMXX6aHint (6, 0, 1, 0x27, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfpd.c.nc.nta", M2, OpMXX6aHint (6, 0, 1, 0x27, 3), {F1, F2, MR3}, EMPTY},
+ {"ldfp8.c.nc", M2, OpMXX6aHint (6, 0, 1, 0x25, 0), {F1, F2, MR3}, EMPTY},
+ {"ldfp8.c.nc.nt1", M2, OpMXX6aHint (6, 0, 1, 0x25, 1), {F1, F2, MR3}, EMPTY},
+ {"ldfp8.c.nc.nta", M2, OpMXX6aHint (6, 0, 1, 0x25, 3), {F1, F2, MR3}, EMPTY},
- /* floating-point load pair w/increment by immediate */
-#define LD(a,b,c) M2, OpMXX6aHint (6, 1, 1, a, b), {F1, F2, MR3, c}, POSTINC
+ /* Floating-point load pair w/increment by immediate. */
+#define LD(a,b,c) M2, OpMXX6aHint (6, 1, 1, a, b), {F1, F2, MR3, c}, POSTINC, 0, NULL
{"ldfps", LD (0x02, 0, C8)},
{"ldfps.nt1", LD (0x02, 1, C8)},
{"ldfps.nta", LD (0x02, 3, C8)},
@@ -871,26 +907,26 @@ struct ia64_opcode ia64_opcodes_m[] =
{"ldfp8.c.nc.nta", LD (0x25, 3, C16)},
#undef LD
- /* line prefetch */
- {"lfetch", M0, OpMXX6aHint (6, 0, 0, 0x2c, 0), {MR3}},
- {"lfetch.nt1", M0, OpMXX6aHint (6, 0, 0, 0x2c, 1), {MR3}},
- {"lfetch.nt2", M0, OpMXX6aHint (6, 0, 0, 0x2c, 2), {MR3}},
- {"lfetch.nta", M0, OpMXX6aHint (6, 0, 0, 0x2c, 3), {MR3}},
- {"lfetch.excl", M0, OpMXX6aHint (6, 0, 0, 0x2d, 0), {MR3}},
- {"lfetch.excl.nt1", M0, OpMXX6aHint (6, 0, 0, 0x2d, 1), {MR3}},
- {"lfetch.excl.nt2", M0, OpMXX6aHint (6, 0, 0, 0x2d, 2), {MR3}},
- {"lfetch.excl.nta", M0, OpMXX6aHint (6, 0, 0, 0x2d, 3), {MR3}},
- {"lfetch.fault", M0, OpMXX6aHint (6, 0, 0, 0x2e, 0), {MR3}},
- {"lfetch.fault.nt1", M0, OpMXX6aHint (6, 0, 0, 0x2e, 1), {MR3}},
- {"lfetch.fault.nt2", M0, OpMXX6aHint (6, 0, 0, 0x2e, 2), {MR3}},
- {"lfetch.fault.nta", M0, OpMXX6aHint (6, 0, 0, 0x2e, 3), {MR3}},
- {"lfetch.fault.excl", M0, OpMXX6aHint (6, 0, 0, 0x2f, 0), {MR3}},
- {"lfetch.fault.excl.nt1", M0, OpMXX6aHint (6, 0, 0, 0x2f, 1), {MR3}},
- {"lfetch.fault.excl.nt2", M0, OpMXX6aHint (6, 0, 0, 0x2f, 2), {MR3}},
- {"lfetch.fault.excl.nta", M0, OpMXX6aHint (6, 0, 0, 0x2f, 3), {MR3}},
+ /* Line prefetch. */
+ {"lfetch", M0, OpMXX6aHint (6, 0, 0, 0x2c, 0), {MR3}, EMPTY},
+ {"lfetch.nt1", M0, OpMXX6aHint (6, 0, 0, 0x2c, 1), {MR3}, EMPTY},
+ {"lfetch.nt2", M0, OpMXX6aHint (6, 0, 0, 0x2c, 2), {MR3}, EMPTY},
+ {"lfetch.nta", M0, OpMXX6aHint (6, 0, 0, 0x2c, 3), {MR3}, EMPTY},
+ {"lfetch.excl", M0, OpMXX6aHint (6, 0, 0, 0x2d, 0), {MR3}, EMPTY},
+ {"lfetch.excl.nt1", M0, OpMXX6aHint (6, 0, 0, 0x2d, 1), {MR3}, EMPTY},
+ {"lfetch.excl.nt2", M0, OpMXX6aHint (6, 0, 0, 0x2d, 2), {MR3}, EMPTY},
+ {"lfetch.excl.nta", M0, OpMXX6aHint (6, 0, 0, 0x2d, 3), {MR3}, EMPTY},
+ {"lfetch.fault", M0, OpMXX6aHint (6, 0, 0, 0x2e, 0), {MR3}, EMPTY},
+ {"lfetch.fault.nt1", M0, OpMXX6aHint (6, 0, 0, 0x2e, 1), {MR3}, EMPTY},
+ {"lfetch.fault.nt2", M0, OpMXX6aHint (6, 0, 0, 0x2e, 2), {MR3}, EMPTY},
+ {"lfetch.fault.nta", M0, OpMXX6aHint (6, 0, 0, 0x2e, 3), {MR3}, EMPTY},
+ {"lfetch.fault.excl", M0, OpMXX6aHint (6, 0, 0, 0x2f, 0), {MR3}, EMPTY},
+ {"lfetch.fault.excl.nt1", M0, OpMXX6aHint (6, 0, 0, 0x2f, 1), {MR3}, EMPTY},
+ {"lfetch.fault.excl.nt2", M0, OpMXX6aHint (6, 0, 0, 0x2f, 2), {MR3}, EMPTY},
+ {"lfetch.fault.excl.nta", M0, OpMXX6aHint (6, 0, 0, 0x2f, 3), {MR3}, EMPTY},
- /* line prefetch w/increment by register */
-#define LFETCHINCREG(c,h) M0, OpMXX6aHint (6, 1, 0, c, h), {MR3, R2}, POSTINC
+ /* Line prefetch w/increment by register. */
+#define LFETCHINCREG(c,h) M0, OpMXX6aHint (6, 1, 0, c, h), {MR3, R2}, POSTINC, 0, NULL
{"lfetch", LFETCHINCREG (0x2c, 0)},
{"lfetch.nt1", LFETCHINCREG (0x2c, 1)},
{"lfetch.nt2", LFETCHINCREG (0x2c, 2)},
@@ -909,14 +945,14 @@ struct ia64_opcode ia64_opcodes_m[] =
{"lfetch.fault.excl.nta", LFETCHINCREG (0x2f, 3)},
#undef LFETCHINCREG
- /* semaphore operations */
- {"setf.sig", M, OpMXX6a (6, 0, 1, 0x1c), {F1, R2}},
- {"setf.exp", M, OpMXX6a (6, 0, 1, 0x1d), {F1, R2}},
- {"setf.s", M, OpMXX6a (6, 0, 1, 0x1e), {F1, R2}},
- {"setf.d", M, OpMXX6a (6, 0, 1, 0x1f), {F1, R2}},
+ /* Semaphore operations. */
+ {"setf.sig", M, OpMXX6a (6, 0, 1, 0x1c), {F1, R2}, EMPTY},
+ {"setf.exp", M, OpMXX6a (6, 0, 1, 0x1d), {F1, R2}, EMPTY},
+ {"setf.s", M, OpMXX6a (6, 0, 1, 0x1e), {F1, R2}, EMPTY},
+ {"setf.d", M, OpMXX6a (6, 0, 1, 0x1f), {F1, R2}, EMPTY},
- /* floating-point load w/increment by immediate */
-#define FLDINCIMMED(c,h) M, OpX6aHint (7, c, h), {F1, MR3, IMM9b}, POSTINC
+ /* Floating-point load w/increment by immediate. */
+#define FLDINCIMMED(c,h) M, OpX6aHint (7, c, h), {F1, MR3, IMM9b}, POSTINC, 0, NULL
{"ldfs", FLDINCIMMED (0x02, 0)},
{"ldfs.nt1", FLDINCIMMED (0x02, 1)},
{"ldfs.nta", FLDINCIMMED (0x02, 3)},
@@ -994,8 +1030,8 @@ struct ia64_opcode ia64_opcodes_m[] =
{"ldfe.c.nc.nta", FLDINCIMMED (0x24, 3)},
#undef FLDINCIMMED
- /* floating-point store w/increment by immediate */
-#define FSTINCIMMED(c,h) M, OpX6aHint (7, c, h), {MR3, F2, IMM9a}, POSTINC
+ /* Floating-point store w/increment by immediate. */
+#define FSTINCIMMED(c,h) M, OpX6aHint (7, c, h), {MR3, F2, IMM9a}, POSTINC, 0, NULL
{"stfs", FSTINCIMMED (0x32, 0)},
{"stfs.nta", FSTINCIMMED (0x32, 3)},
{"stfd", FSTINCIMMED (0x33, 0)},
@@ -1008,8 +1044,8 @@ struct ia64_opcode ia64_opcodes_m[] =
{"stf.spill.nta", FSTINCIMMED (0x3b, 3)},
#undef FSTINCIMMED
- /* line prefetch w/increment by immediate */
-#define LFETCHINCIMMED(c,h) M0, OpX6aHint (7, c, h), {MR3, IMM9b}, POSTINC
+ /* Line prefetch w/increment by immediate. */
+#define LFETCHINCIMMED(c,h) M0, OpX6aHint (7, c, h), {MR3, IMM9b}, POSTINC, 0, NULL
{"lfetch", LFETCHINCIMMED (0x2c, 0)},
{"lfetch.nt1", LFETCHINCIMMED (0x2c, 1)},
{"lfetch.nt2", LFETCHINCIMMED (0x2c, 2)},
@@ -1028,7 +1064,7 @@ struct ia64_opcode ia64_opcodes_m[] =
{"lfetch.fault.excl.nta", LFETCHINCIMMED (0x2f, 3)},
#undef LFETCHINCIMMED
- {0}
+ {NULL, 0, 0, 0, 0, {0}, 0, 0, NULL}
};
#undef M0
@@ -1058,3 +1094,4 @@ struct ia64_opcode ia64_opcodes_m[] =
#undef OpXX6aHint
#undef OpMXX6a
#undef OpMXX6aHint
+#undef EMPTY
diff --git a/contrib/binutils/opcodes/ia64-opc-x.c b/contrib/binutils/opcodes/ia64-opc-x.c
index 5f382fd..e1d4345 100644
--- a/contrib/binutils/opcodes/ia64-opc-x.c
+++ b/contrib/binutils/opcodes/ia64-opc-x.c
@@ -1,5 +1,5 @@
/* ia64-opc-x.c -- IA-64 `X' opcode table.
- Copyright 1998, 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1998, 1999, 2000, 2002 Free Software Foundation, Inc.
Contributed by Timothy Wall <twall@cygnus.com>
This file is part of GDB, GAS, and the GNU binutils.
@@ -21,11 +21,11 @@
#include "ia64-opc.h"
-/* identify the specific X-unit type */
+/* Identify the specific X-unit type. */
#define X0 IA64_TYPE_X, 0
#define X IA64_TYPE_X, 1
-/* instruction bit fields: */
+/* Instruction bit fields: */
#define bBtype(x) (((ia64_insn) ((x) & 0x7)) << 6)
#define bD(x) (((ia64_insn) ((x) & 0x1)) << 35)
#define bPa(x) (((ia64_insn) ((x) & 0x1)) << 12)
@@ -34,6 +34,7 @@
#define bWha(x) (((ia64_insn) ((x) & 0x3)) << 33)
#define bX3(x) (((ia64_insn) ((x) & 0x7)) << 33)
#define bX6(x) (((ia64_insn) ((x) & 0x3f)) << 27)
+#define bY(x) (((ia64_insn) ((x) & 0x1)) << 26)
#define mBtype bBtype (-1)
#define mD bD (-1)
@@ -43,9 +44,12 @@
#define mWha bWha (-1)
#define mX3 bX3 (-1)
#define mX6 bX6 (-1)
+#define mY bY (-1)
#define OpX3X6(a,b,c) (bOp (a) | bX3 (b) | bX6(c)), \
(mOp | mX3 | mX6)
+#define OpX3X6Y(a,b,c,d) (bOp (a) | bX3 (b) | bX6(c) | bY(d)), \
+ (mOp | mX3 | mX6 | mY)
#define OpVc(a,b) (bOp (a) | bVc (b)), (mOp | mVc)
#define OpPaWhaD(a,b,c,d) \
(bOp (a) | bPa (b) | bWha (c) | bD (d)), (mOp | mPa | mWha | mD)
@@ -58,36 +62,39 @@
struct ia64_opcode ia64_opcodes_x[] =
{
- {"break.x", X0, OpX3X6 (0, 0, 0x00), {IMMU62}},
- {"nop.x", X0, OpX3X6 (0, 0, 0x01), {IMMU62}},
- {"movl", X, OpVc (6, 0), {R1, IMMU64}},
+ {"break.x", X0, OpX3X6 (0, 0, 0x00), {IMMU62}, 0, 0, NULL},
+ {"nop.x", X0, OpX3X6Y (0, 0, 0x01, 0), {IMMU62}, 0, 0, NULL},
+ {"hint.x", X0, OpX3X6Y (0, 0, 0x01, 1), {IMMU62}, 0, 0, NULL},
+ {"movl", X, OpVc (6, 0), {R1, IMMU64}, 0, 0, NULL},
#define BRL(a,b) \
- X0, OpBtypePaWhaDPr (0xC, 0, a, 0, b, 0), {TGT64}, 0
- {"brl.few", BRL (0, 0) | PSEUDO},
- {"brl", BRL (0, 0) | PSEUDO},
- {"brl.few.clr", BRL (0, 1) | PSEUDO},
- {"brl.clr", BRL (0, 1) | PSEUDO},
- {"brl.many", BRL (1, 0) | PSEUDO},
- {"brl.many.clr", BRL (1, 1) | PSEUDO},
+ X0, OpBtypePaWhaDPr (0xC, 0, a, 0, b, 0), {TGT64}, PSEUDO, 0, NULL
+ {"brl.few", BRL (0, 0)},
+ {"brl", BRL (0, 0)},
+ {"brl.few.clr", BRL (0, 1)},
+ {"brl.clr", BRL (0, 1)},
+ {"brl.many", BRL (1, 0)},
+ {"brl.many.clr", BRL (1, 1)},
#undef BRL
#define BRL(a,b,c) \
- X0, OpBtypePaWhaD (0xC, 0, a, b, c), {TGT64}, 0
+ X0, OpBtypePaWhaD (0xC, 0, a, b, c), {TGT64}, 0, 0, NULL
+#define BRLP(a,b,c) \
+ X0, OpBtypePaWhaD (0xC, 0, a, b, c), {TGT64}, PSEUDO, 0, NULL
{"brl.cond.sptk.few", BRL (0, 0, 0)},
- {"brl.cond.sptk", BRL (0, 0, 0) | PSEUDO},
+ {"brl.cond.sptk", BRLP (0, 0, 0)},
{"brl.cond.sptk.few.clr", BRL (0, 0, 1)},
- {"brl.cond.sptk.clr", BRL (0, 0, 1) | PSEUDO},
+ {"brl.cond.sptk.clr", BRLP (0, 0, 1)},
{"brl.cond.spnt.few", BRL (0, 1, 0)},
- {"brl.cond.spnt", BRL (0, 1, 0) | PSEUDO},
+ {"brl.cond.spnt", BRLP (0, 1, 0)},
{"brl.cond.spnt.few.clr", BRL (0, 1, 1)},
- {"brl.cond.spnt.clr", BRL (0, 1, 1) | PSEUDO},
+ {"brl.cond.spnt.clr", BRLP (0, 1, 1)},
{"brl.cond.dptk.few", BRL (0, 2, 0)},
- {"brl.cond.dptk", BRL (0, 2, 0) | PSEUDO},
+ {"brl.cond.dptk", BRLP (0, 2, 0)},
{"brl.cond.dptk.few.clr", BRL (0, 2, 1)},
- {"brl.cond.dptk.clr", BRL (0, 2, 1) | PSEUDO},
+ {"brl.cond.dptk.clr", BRLP (0, 2, 1)},
{"brl.cond.dpnt.few", BRL (0, 3, 0)},
- {"brl.cond.dpnt", BRL (0, 3, 0) | PSEUDO},
+ {"brl.cond.dpnt", BRLP (0, 3, 0)},
{"brl.cond.dpnt.few.clr", BRL (0, 3, 1)},
- {"brl.cond.dpnt.clr", BRL (0, 3, 1) | PSEUDO},
+ {"brl.cond.dpnt.clr", BRLP (0, 3, 1)},
{"brl.cond.sptk.many", BRL (1, 0, 0)},
{"brl.cond.sptk.many.clr", BRL (1, 0, 1)},
{"brl.cond.spnt.many", BRL (1, 1, 0)},
@@ -97,21 +104,21 @@ struct ia64_opcode ia64_opcodes_x[] =
{"brl.cond.dpnt.many", BRL (1, 3, 0)},
{"brl.cond.dpnt.many.clr", BRL (1, 3, 1)},
{"brl.sptk.few", BRL (0, 0, 0)},
- {"brl.sptk", BRL (0, 0, 0) | PSEUDO},
+ {"brl.sptk", BRLP (0, 0, 0)},
{"brl.sptk.few.clr", BRL (0, 0, 1)},
- {"brl.sptk.clr", BRL (0, 0, 1) | PSEUDO},
+ {"brl.sptk.clr", BRLP (0, 0, 1)},
{"brl.spnt.few", BRL (0, 1, 0)},
- {"brl.spnt", BRL (0, 1, 0) | PSEUDO},
+ {"brl.spnt", BRLP (0, 1, 0)},
{"brl.spnt.few.clr", BRL (0, 1, 1)},
- {"brl.spnt.clr", BRL (0, 1, 1) | PSEUDO},
+ {"brl.spnt.clr", BRLP (0, 1, 1)},
{"brl.dptk.few", BRL (0, 2, 0)},
- {"brl.dptk", BRL (0, 2, 0) | PSEUDO},
+ {"brl.dptk", BRLP (0, 2, 0)},
{"brl.dptk.few.clr", BRL (0, 2, 1)},
- {"brl.dptk.clr", BRL (0, 2, 1) | PSEUDO},
+ {"brl.dptk.clr", BRLP (0, 2, 1)},
{"brl.dpnt.few", BRL (0, 3, 0)},
- {"brl.dpnt", BRL (0, 3, 0) | PSEUDO},
+ {"brl.dpnt", BRLP (0, 3, 0)},
{"brl.dpnt.few.clr", BRL (0, 3, 1)},
- {"brl.dpnt.clr", BRL (0, 3, 1) | PSEUDO},
+ {"brl.dpnt.clr", BRLP (0, 3, 1)},
{"brl.sptk.many", BRL (1, 0, 0)},
{"brl.sptk.many.clr", BRL (1, 0, 1)},
{"brl.spnt.many", BRL (1, 1, 0)},
@@ -121,23 +128,25 @@ struct ia64_opcode ia64_opcodes_x[] =
{"brl.dpnt.many", BRL (1, 3, 0)},
{"brl.dpnt.many.clr", BRL (1, 3, 1)},
#undef BRL
-#define BRL(a,b,c) X, OpPaWhaD (0xD, a, b, c), {B1, TGT64}, 0
+#undef BRLP
+#define BRL(a,b,c) X, OpPaWhaD (0xD, a, b, c), {B1, TGT64}, 0, 0, NULL
+#define BRLP(a,b,c) X, OpPaWhaD (0xD, a, b, c), {B1, TGT64}, PSEUDO, 0, NULL
{"brl.call.sptk.few", BRL (0, 0, 0)},
- {"brl.call.sptk", BRL (0, 0, 0) | PSEUDO},
+ {"brl.call.sptk", BRLP (0, 0, 0)},
{"brl.call.sptk.few.clr", BRL (0, 0, 1)},
- {"brl.call.sptk.clr", BRL (0, 0, 1) | PSEUDO},
+ {"brl.call.sptk.clr", BRLP (0, 0, 1)},
{"brl.call.spnt.few", BRL (0, 1, 0)},
- {"brl.call.spnt", BRL (0, 1, 0) | PSEUDO},
+ {"brl.call.spnt", BRLP (0, 1, 0)},
{"brl.call.spnt.few.clr", BRL (0, 1, 1)},
- {"brl.call.spnt.clr", BRL (0, 1, 1) | PSEUDO},
+ {"brl.call.spnt.clr", BRLP (0, 1, 1)},
{"brl.call.dptk.few", BRL (0, 2, 0)},
- {"brl.call.dptk", BRL (0, 2, 0) | PSEUDO},
+ {"brl.call.dptk", BRLP (0, 2, 0)},
{"brl.call.dptk.few.clr", BRL (0, 2, 1)},
- {"brl.call.dptk.clr", BRL (0, 2, 1) | PSEUDO},
+ {"brl.call.dptk.clr", BRLP (0, 2, 1)},
{"brl.call.dpnt.few", BRL (0, 3, 0)},
- {"brl.call.dpnt", BRL (0, 3, 0) | PSEUDO},
+ {"brl.call.dpnt", BRLP (0, 3, 0)},
{"brl.call.dpnt.few.clr", BRL (0, 3, 1)},
- {"brl.call.dpnt.clr", BRL (0, 3, 1) | PSEUDO},
+ {"brl.call.dpnt.clr", BRLP (0, 3, 1)},
{"brl.call.sptk.many", BRL (1, 0, 0)},
{"brl.call.sptk.many.clr", BRL (1, 0, 1)},
{"brl.call.spnt.many", BRL (1, 1, 0)},
@@ -147,7 +156,8 @@ struct ia64_opcode ia64_opcodes_x[] =
{"brl.call.dpnt.many", BRL (1, 3, 0)},
{"brl.call.dpnt.many.clr", BRL (1, 3, 1)},
#undef BRL
- {0}
+#undef BRLP
+ {NULL, 0, 0, 0, 0, {0}, 0, 0, NULL}
};
#undef X0
diff --git a/contrib/binutils/opcodes/ia64-opc.c b/contrib/binutils/opcodes/ia64-opc.c
index 9726381..fc90213 100644
--- a/contrib/binutils/opcodes/ia64-opc.c
+++ b/contrib/binutils/opcodes/ia64-opc.c
@@ -1,5 +1,5 @@
/* ia64-opc.c -- Functions to access the compacted opcode table
- Copyright 1999, 2000 Free Software Foundation, Inc.
+ Copyright 1999, 2000, 2003 Free Software Foundation, Inc.
Written by Bob Manson of Cygnus Solutions, <manson@cygnus.com>
This file is part of GDB, GAS, and the GNU binutils.
@@ -25,19 +25,19 @@
#include "ia64-asmtab.h"
#include "ia64-asmtab.c"
-static void get_opc_prefix PARAMS ((const char **, char *));
-static short int find_string_ent PARAMS ((const char *));
-static short int find_main_ent PARAMS ((short int));
-static short int find_completer PARAMS ((short int, short int, const char *));
-static ia64_insn apply_completer PARAMS ((ia64_insn, int));
-static int extract_op_bits PARAMS ((int, int, int));
-static int extract_op PARAMS ((int, int *, unsigned int *));
-static int opcode_verify PARAMS ((ia64_insn, int, enum ia64_insn_type));
-static int locate_opcode_ent PARAMS ((ia64_insn, enum ia64_insn_type));
+static void get_opc_prefix (const char **, char *);
+static short int find_string_ent (const char *);
+static short int find_main_ent (short int);
+static short int find_completer (short int, short int, const char *);
+static ia64_insn apply_completer (ia64_insn, int);
+static int extract_op_bits (int, int, int);
+static int extract_op (int, int *, unsigned int *);
+static int opcode_verify (ia64_insn, int, enum ia64_insn_type);
+static int locate_opcode_ent (ia64_insn, enum ia64_insn_type);
static struct ia64_opcode *make_ia64_opcode
- PARAMS ((ia64_insn, const char *, int, int));
+ (ia64_insn, const char *, int, int);
static struct ia64_opcode *ia64_find_matching_opcode
- PARAMS ((const char *, short int));
+ (const char *, short int);
const struct ia64_templ_desc ia64_templ_desc[16] =
{
@@ -65,9 +65,7 @@ const struct ia64_templ_desc ia64_templ_desc[16] =
of the opcode, or at the NUL character. */
static void
-get_opc_prefix (ptr, dest)
- const char **ptr;
- char *dest;
+get_opc_prefix (const char **ptr, char *dest)
{
char *c = strchr (*ptr, '.');
if (c != NULL)
@@ -89,8 +87,7 @@ get_opc_prefix (ptr, dest)
STR; return -1 if one does not exist. */
static short
-find_string_ent (str)
- const char *str;
+find_string_ent (const char *str)
{
short start = 0;
short end = sizeof (ia64_strings) / sizeof (const char *);
@@ -124,8 +121,7 @@ find_string_ent (str)
return -1 if one does not exist. */
static short
-find_main_ent (nameindex)
- short nameindex;
+find_main_ent (short nameindex)
{
short start = 0;
short end = sizeof (main_table) / sizeof (struct ia64_main_table);
@@ -164,10 +160,7 @@ find_main_ent (nameindex)
return -1 if one does not exist. */
static short
-find_completer (main_ent, prev_completer, name)
- short main_ent;
- short prev_completer;
- const char *name;
+find_completer (short main_ent, short prev_completer, const char *name)
{
short name_index = find_string_ent (name);
@@ -200,9 +193,7 @@ find_completer (main_ent, prev_completer, name)
return the result. */
static ia64_insn
-apply_completer (opcode, completer_index)
- ia64_insn opcode;
- int completer_index;
+apply_completer (ia64_insn opcode, int completer_index)
{
ia64_insn mask = completer_table[completer_index].mask;
ia64_insn bits = completer_table[completer_index].bits;
@@ -220,10 +211,7 @@ apply_completer (opcode, completer_index)
first byte in OP_POINTER.) */
static int
-extract_op_bits (op_pointer, bitoffset, bits)
- int op_pointer;
- int bitoffset;
- int bits;
+extract_op_bits (int op_pointer, int bitoffset, int bits)
{
int res = 0;
@@ -259,10 +247,7 @@ extract_op_bits (op_pointer, bitoffset, bits)
state entry in bits is returned. */
static int
-extract_op (op_pointer, opval, op)
- int op_pointer;
- int *opval;
- unsigned int *op;
+extract_op (int op_pointer, int *opval, unsigned int *op)
{
int oplen = 5;
@@ -317,10 +302,7 @@ extract_op (op_pointer, opval, op)
PLACE matches OPCODE and is of type TYPE. */
static int
-opcode_verify (opcode, place, type)
- ia64_insn opcode;
- int place;
- enum ia64_insn_type type;
+opcode_verify (ia64_insn opcode, int place, enum ia64_insn_type type)
{
if (main_table[place].opcode_type != type)
{
@@ -364,9 +346,7 @@ opcode_verify (opcode, place, type)
priority. */
static int
-locate_opcode_ent (opcode, type)
- ia64_insn opcode;
- enum ia64_insn_type type;
+locate_opcode_ent (ia64_insn opcode, enum ia64_insn_type type)
{
int currtest[41];
int bitpos[41];
@@ -545,11 +525,7 @@ locate_opcode_ent (opcode, type)
/* Construct an ia64_opcode entry based on OPCODE, NAME and PLACE. */
static struct ia64_opcode *
-make_ia64_opcode (opcode, name, place, depind)
- ia64_insn opcode;
- const char *name;
- int place;
- int depind;
+make_ia64_opcode (ia64_insn opcode, const char *name, int place, int depind)
{
struct ia64_opcode *res =
(struct ia64_opcode *) xmalloc (sizeof (struct ia64_opcode));
@@ -572,9 +548,7 @@ make_ia64_opcode (opcode, name, place, depind)
/* Determine the ia64_opcode entry for the opcode specified by INSN
and TYPE. If a valid entry is not found, return NULL. */
struct ia64_opcode *
-ia64_dis_opcode (insn, type)
- ia64_insn insn;
- enum ia64_insn_type type;
+ia64_dis_opcode (ia64_insn insn, enum ia64_insn_type type)
{
int disent = locate_opcode_ent (insn, type);
@@ -633,9 +607,7 @@ ia64_dis_opcode (insn, type)
matches NAME. Return NULL if one is not found. */
static struct ia64_opcode *
-ia64_find_matching_opcode (name, place)
- const char *name;
- short place;
+ia64_find_matching_opcode (const char *name, short place)
{
char op[129];
const char *suffix;
@@ -696,8 +668,7 @@ ia64_find_matching_opcode (name, place)
release any resources used by the returned entry. */
struct ia64_opcode *
-ia64_find_next_opcode (prev_ent)
- struct ia64_opcode *prev_ent;
+ia64_find_next_opcode (struct ia64_opcode *prev_ent)
{
return ia64_find_matching_opcode (prev_ent->name,
prev_ent->ent_index + 1);
@@ -710,8 +681,7 @@ ia64_find_next_opcode (prev_ent)
release any resources used by the returned entry. */
struct ia64_opcode *
-ia64_find_opcode (name)
- const char *name;
+ia64_find_opcode (const char *name)
{
char op[129];
const char *suffix;
@@ -741,16 +711,14 @@ ia64_find_opcode (name)
/* Free any resources used by ENT. */
void
-ia64_free_opcode (ent)
- struct ia64_opcode *ent;
+ia64_free_opcode (struct ia64_opcode *ent)
{
free ((void *)ent->name);
free (ent);
}
const struct ia64_dependency *
-ia64_find_dependency (index)
- int index;
+ia64_find_dependency (int index)
{
index = DEP(index);
diff --git a/contrib/binutils/opcodes/ia64-opc.h b/contrib/binutils/opcodes/ia64-opc.h
index b721cb8..f9476d8 100644
--- a/contrib/binutils/opcodes/ia64-opc.h
+++ b/contrib/binutils/opcodes/ia64-opc.h
@@ -44,6 +44,7 @@
#define AR_CCV IA64_OPND_AR_CCV
#define AR_PFS IA64_OPND_AR_PFS
+#define AR_CSD IA64_OPND_AR_CSD
#define C1 IA64_OPND_C1
#define C8 IA64_OPND_C8
#define C16 IA64_OPND_C16
diff --git a/contrib/binutils/opcodes/ia64-raw.tbl b/contrib/binutils/opcodes/ia64-raw.tbl
index ec35888..476721c 100644
--- a/contrib/binutils/opcodes/ia64-raw.tbl
+++ b/contrib/binutils/opcodes/ia64-raw.tbl
@@ -2,8 +2,14 @@ Resource Name; Writers; Readers; Semantics of Dependency
ALAT; chk.a.clr, IC:mem-readers-alat, IC:mem-writers, IC:invala-all; IC:mem-readers-alat, IC:mem-writers, IC:chk-a, invala.e; none
AR[BSP]; br.call, brl.call, br.ret, cover, IC:mov-to-AR-BSPSTORE, rfi; br.call, brl.call, br.ia, br.ret, cover, flushrs, loadrs, IC:mov-from-AR-BSP, rfi; impliedF
AR[BSPSTORE]; alloc, loadrs, flushrs, IC:mov-to-AR-BSPSTORE; alloc, br.ia, flushrs, IC:mov-from-AR-BSPSTORE; impliedF
+AR[CFLG]; IC:mov-to-AR-CFLG; br.ia, IC:mov-from-AR-CFLG; impliedF
AR[CCV]; IC:mov-to-AR-CCV; br.ia, IC:cmpxchg, IC:mov-from-AR-CCV; impliedF
+AR[CSD]; ld16, IC:mov-to-AR-CSD; br.ia, cmp8xchg16, IC:mov-from-AR-CSD, st16; impliedF
AR[EC]; IC:mod-sched-brs, br.ret, IC:mov-to-AR-EC; br.call, brl.call, br.ia, IC:mod-sched-brs, IC:mov-from-AR-EC; impliedF
+AR[EFLAG]; IC:mov-to-AR-EFLAG; br.ia, IC:mov-from-AR-EFLAG; impliedF
+AR[FCR]; IC:mov-to-AR-FCR; br.ia, IC:mov-from-AR-FCR; impliedF
+AR[FDR]; IC:mov-to-AR-FDR; br.ia, IC:mov-from-AR-FDR; impliedF
+AR[FIR]; IC:mov-to-AR-FIR; br.ia, IC:mov-from-AR-FIR; impliedF
AR[FPSR].sf0.controls; IC:mov-to-AR-FPSR, fsetc.s0; br.ia, IC:fp-arith-s0, IC:fcmp-s0, IC:fpcmp-s0, fsetc, IC:mov-from-AR-FPSR; impliedF
AR[FPSR].sf1.controls; IC:mov-to-AR-FPSR, fsetc.s1; br.ia, IC:fp-arith-s1, IC:fcmp-s1, IC:fpcmp-s1, IC:mov-from-AR-FPSR; impliedF
AR[FPSR].sf2.controls; IC:mov-to-AR-FPSR, fsetc.s2; br.ia, IC:fp-arith-s2, IC:fcmp-s2, IC:fpcmp-s2, IC:mov-from-AR-FPSR; impliedF
@@ -14,6 +20,7 @@ AR[FPSR].sf2.flags; IC:fp-arith-s2, fclrf.s2, IC:fcmp-s2, IC:fpcmp-s2, IC:mov-to
AR[FPSR].sf3.flags; IC:fp-arith-s3, fclrf.s3, IC:fcmp-s3, IC:fpcmp-s3, IC:mov-to-AR-FPSR; br.ia, fchkf.s3, IC:mov-from-AR-FPSR; impliedF
AR[FPSR].traps; IC:mov-to-AR-FPSR; br.ia, IC:fp-arith, fchkf, fcmp, fpcmp, IC:mov-from-AR-FPSR; impliedF
AR[FPSR].rv; IC:mov-to-AR-FPSR; br.ia, IC:fp-arith, fchkf, fcmp, fpcmp, IC:mov-from-AR-FPSR; impliedF
+AR[FSR]; IC:mov-to-AR-FSR; br.ia, IC:mov-from-AR-FSR; impliedF
AR[ITC]; IC:mov-to-AR-ITC; br.ia, IC:mov-from-AR-ITC; impliedF
AR[K%], % in 0 - 7; IC:mov-to-AR-K+1; br.ia, IC:mov-from-AR-K+1; impliedF
AR[LC]; IC:mod-sched-brs-counted, IC:mov-to-AR-LC; br.ia, IC:mod-sched-brs-counted, IC:mov-from-AR-LC; impliedF
@@ -22,6 +29,7 @@ AR[PFS]; IC:mov-to-AR-PFS; alloc, br.ia, epc, IC:mov-from-AR-PFS; impliedF
AR[PFS]; IC:mov-to-AR-PFS; br.ret; none
AR[RNAT]; alloc, flushrs, loadrs, IC:mov-to-AR-RNAT, IC:mov-to-AR-BSPSTORE; alloc, br.ia, flushrs, loadrs, IC:mov-from-AR-RNAT; impliedF
AR[RSC]; IC:mov-to-AR-RSC; alloc, br.ia, flushrs, loadrs, IC:mov-from-AR-RSC, IC:mov-from-AR-BSPSTORE, IC:mov-to-AR-RNAT, IC:mov-from-AR-RNAT, IC:mov-to-AR-BSPSTORE; impliedF
+AR[SSD]; IC:mov-to-AR-SSD; br.ia, IC:mov-from-AR-SSD; impliedF
AR[UNAT]{%}, % in 0 - 63; IC:mov-to-AR-UNAT, st8.spill; br.ia, ld8.fill, IC:mov-from-AR-UNAT; impliedF
AR%, % in 8-15, 20, 22-23, 31, 33-35, 37-39, 41-43, 45-47, 67-111; IC:none; br.ia, IC:mov-from-AR-rv+1; none
AR%, % in 48-63, 112-127; IC:mov-to-AR-ig+1; br.ia, IC:mov-from-AR-ig+1; impliedF
diff --git a/contrib/binutils/opcodes/ia64-waw.tbl b/contrib/binutils/opcodes/ia64-waw.tbl
index c8a3365..98daebf 100644
--- a/contrib/binutils/opcodes/ia64-waw.tbl
+++ b/contrib/binutils/opcodes/ia64-waw.tbl
@@ -3,7 +3,13 @@ ALAT; IC:mem-readers-alat, IC:mem-writers, chk.a.clr, IC:invala-all; IC:mem-read
AR[BSP]; br.call, brl.call, br.ret, cover, IC:mov-to-AR-BSPSTORE, rfi; br.call, brl.call, br.ret, cover, IC:mov-to-AR-BSPSTORE, rfi; impliedF
AR[BSPSTORE]; alloc, loadrs, flushrs, IC:mov-to-AR-BSPSTORE; alloc, loadrs, flushrs, IC:mov-to-AR-BSPSTORE; impliedF
AR[CCV]; IC:mov-to-AR-CCV; IC:mov-to-AR-CCV; impliedF
+AR[CFLG]; IC:mov-to-AR-CFLG; IC:mov-to-AR-CFLG; impliedF
+AR[CSD]; ld16, IC:mov-to-AR-CSD; ld16, IC:mov-to-AR-CSD; impliedF
AR[EC]; br.ret, IC:mod-sched-brs, IC:mov-to-AR-EC; br.ret, IC:mod-sched-brs, IC:mov-to-AR-EC; impliedF
+AR[EFLAG]; mov-to-AR-EFLAG; mov-to-AR-EFLAG; impliedF
+AR[FCR]; mov-to-AR-FCR; mov-to-AR-FCR; impliedF
+AR[FDR]; mov-to-AR-FDR; mov-to-AR-FDR; impliedF
+AR[FIR]; mov-to-AR-FIR; mov-to-AR-FIR; impliedF
AR[FPSR].sf0.controls; IC:mov-to-AR-FPSR, fsetc.s0; IC:mov-to-AR-FPSR, fsetc.s0; impliedF
AR[FPSR].sf1.controls; IC:mov-to-AR-FPSR, fsetc.s1; IC:mov-to-AR-FPSR, fsetc.s1; impliedF
AR[FPSR].sf2.controls; IC:mov-to-AR-FPSR, fsetc.s2; IC:mov-to-AR-FPSR, fsetc.s2; impliedF
@@ -18,6 +24,7 @@ AR[FPSR].sf3.flags; IC:fp-arith-s3, IC:fcmp-s3, IC:fpcmp-s3; IC:fp-arith-s3, IC:
AR[FPSR].sf3.flags; fclrf.s3, IC:fcmp-s3, IC:fp-arith-s3, IC:fpcmp-s3, IC:mov-to-AR-FPSR; fclrf.s3, IC:mov-to-AR-FPSR; impliedF
AR[FPSR].rv; IC:mov-to-AR-FPSR; IC:mov-to-AR-FPSR; impliedF
AR[FPSR].traps; IC:mov-to-AR-FPSR; IC:mov-to-AR-FPSR; impliedF
+AR[FSR]; IC:mov-to-AR-FSR; IC:mov-to-AR-FSR; impliedF
AR[ITC]; IC:mov-to-AR-ITC; IC:mov-to-AR-ITC; impliedF
AR[K%], % in 0 - 7; IC:mov-to-AR-K+1; IC:mov-to-AR-K+1; impliedF
AR[LC]; IC:mod-sched-brs-counted, IC:mov-to-AR-LC; IC:mod-sched-brs-counted, IC:mov-to-AR-LC; impliedF
diff --git a/contrib/binutils/opcodes/po/Make-in b/contrib/binutils/opcodes/po/Make-in
index 0552db1..6176dbf 100644
--- a/contrib/binutils/opcodes/po/Make-in
+++ b/contrib/binutils/opcodes/po/Make-in
@@ -24,6 +24,8 @@ gnulocaledir = $(prefix)/share/locale
gettextsrcdir = $(prefix)/share/gettext/po
subdir = po
+DESTDIR =
+
INSTALL = @INSTALL@
INSTALL_DATA = @INSTALL_DATA@
MKINSTALLDIRS = @MKINSTALLDIRS@
@@ -111,9 +113,9 @@ install-data: install-data-@USE_NLS@
install-data-no: all
install-data-yes: all
if test -r $(MKINSTALLDIRS); then \
- $(MKINSTALLDIRS) $(datadir); \
+ $(MKINSTALLDIRS) $(DESTDIR)$(datadir); \
else \
- $(top_srcdir)/mkinstalldirs $(datadir); \
+ $(top_srcdir)/mkinstalldirs $(DESTDIR)$(datadir); \
fi
@catalogs='$(CATALOGS)'; \
for cat in $$catalogs; do \
@@ -123,7 +125,7 @@ install-data-yes: all
*) destdir=$(localedir);; \
esac; \
lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
- dir=$$destdir/$$lang/LC_MESSAGES; \
+ dir=$(DESTDIR)$$destdir/$$lang/LC_MESSAGES; \
if test -r $(MKINSTALLDIRS); then \
$(MKINSTALLDIRS) $$dir; \
else \
@@ -153,12 +155,12 @@ install-data-yes: all
done
if test "$(PACKAGE)" = "gettext"; then \
if test -r $(MKINSTALLDIRS); then \
- $(MKINSTALLDIRS) $(gettextsrcdir); \
+ $(MKINSTALLDIRS) $(DESTDIR)$(gettextsrcdir); \
else \
- $(top_srcdir)/mkinstalldirs $(gettextsrcdir); \
+ $(top_srcdir)/mkinstalldirs $(DESTDIR)$(gettextsrcdir); \
fi; \
$(INSTALL_DATA) $(srcdir)/Makefile.in.in \
- $(gettextsrcdir)/Makefile.in.in; \
+ $(DESTDIR)$(gettextsrcdir)/Makefile.in.in; \
else \
: ; \
fi
@@ -171,12 +173,12 @@ uninstall:
for cat in $$catalogs; do \
cat=`basename $$cat`; \
lang=`echo $$cat | sed 's/\$(CATOBJEXT)$$//'`; \
- rm -f $(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
- rm -f $(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
- rm -f $(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
- rm -f $(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
+ rm -f $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
+ rm -f $(DESTDIR)$(localedir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
+ rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT); \
+ rm -f $(DESTDIR)$(gnulocaledir)/$$lang/LC_MESSAGES/$(PACKAGE)$(INSTOBJEXT).m; \
done
- rm -f $(gettextsrcdir)/po-Makefile.in.in
+ rm -f $(DESTDIR)$(gettextsrcdir)/po-Makefile.in.in
check: all
diff --git a/contrib/binutils/opcodes/po/POTFILES.in b/contrib/binutils/opcodes/po/POTFILES.in
index 9851ce8..333c612 100644
--- a/contrib/binutils/opcodes/po/POTFILES.in
+++ b/contrib/binutils/opcodes/po/POTFILES.in
@@ -16,8 +16,9 @@ d10v-dis.c
d10v-opc.c
d30v-dis.c
d30v-opc.c
-dis-buf.c
disassemble.c
+dis-buf.c
+dis-init.c
dlx-dis.c
fr30-asm.c
fr30-desc.c
@@ -48,12 +49,26 @@ ia64-dis.c
ia64-gen.c
ia64-opc-a.c
ia64-opc-b.c
+ia64-opc.c
ia64-opc-d.c
ia64-opc-f.c
+ia64-opc.h
ia64-opc-i.c
ia64-opc-m.c
-ia64-opc.c
-ia64-opc.h
+ip2k-asm.c
+ip2k-desc.c
+ip2k-desc.h
+ip2k-dis.c
+ip2k-ibld.c
+ip2k-opc.c
+ip2k-opc.h
+iq2000-asm.c
+iq2000-desc.c
+iq2000-desc.h
+iq2000-dis.c
+iq2000-ibld.c
+iq2000-opc.c
+iq2000-opc.h
m10200-dis.c
m10200-opc.c
m10300-dis.c
@@ -73,9 +88,9 @@ m68k-opc.c
m88k-dis.c
mcore-dis.c
mcore-opc.h
+mips16-opc.c
mips-dis.c
mips-opc.c
-mips16-opc.c
mmix-dis.c
mmix-opc.c
ns32k-dis.c
@@ -97,15 +112,16 @@ ppc-opc.c
s390-dis.c
s390-mkopc.c
s390-opc.c
-sh-dis.c
-sh-opc.h
sh64-dis.c
sh64-opc.c
sh64-opc.h
+sh-dis.c
+sh-opc.h
sparc-dis.c
sparc-opc.c
sysdep.h
tic30-dis.c
+tic4x-dis.c
tic54x-dis.c
tic54x-opc.c
tic80-dis.c
@@ -122,6 +138,7 @@ xstormy16-dis.c
xstormy16-ibld.c
xstormy16-opc.c
xstormy16-opc.h
+xtensa-dis.c
z8k-dis.c
-z8k-opc.h
z8kgen.c
+z8k-opc.h
diff --git a/contrib/binutils/opcodes/po/opcodes.pot b/contrib/binutils/opcodes/po/opcodes.pot
index 575d860..15fdff0 100644
--- a/contrib/binutils/opcodes/po/opcodes.pot
+++ b/contrib/binutils/opcodes/po/opcodes.pot
@@ -1,13 +1,12 @@
# SOME DESCRIPTIVE TITLE.
-# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
-# This file is distributed under the same license as the PACKAGE package.
+# Copyright (C) YEAR Free Software Foundation, Inc.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: PACKAGE VERSION\n"
-"POT-Creation-Date: 2002-10-30 10:07-0500\n"
+"POT-Creation-Date: 2003-07-17 14:54+0100\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -27,47 +26,47 @@ msgstr ""
msgid "Illegal limm reference in last instruction!\n"
msgstr ""
-#: arm-dis.c:507
+#: arm-dis.c:554
msgid "<illegal precision>"
msgstr ""
-#: arm-dis.c:1010
+#: arm-dis.c:1162
#, c-format
msgid "Unrecognised register name set: %s\n"
msgstr ""
-#: arm-dis.c:1017
+#: arm-dis.c:1169
#, c-format
msgid "Unrecognised disassembler option: %s\n"
msgstr ""
-#: arm-dis.c:1191
+#: arm-dis.c:1343
msgid ""
"\n"
"The following ARM specific disassembler options are supported for use with\n"
"the -M switch:\n"
msgstr ""
-#: avr-dis.c:118 avr-dis.c:128
+#: avr-dis.c:117 avr-dis.c:127
msgid "undefined"
msgstr ""
-#: avr-dis.c:180
+#: avr-dis.c:179
msgid "Internal disassembler error"
msgstr ""
-#: avr-dis.c:228
+#: avr-dis.c:227
#, c-format
msgid "unknown constraint `%c'"
msgstr ""
-#: cgen-asm.c:346 fr30-ibld.c:195 frv-ibld.c:195 m32r-ibld.c:195
-#: openrisc-ibld.c:195 xstormy16-ibld.c:195
+#: cgen-asm.c:348 fr30-ibld.c:195 frv-ibld.c:195 ip2k-ibld.c:195
+#: iq2000-ibld.c:195 m32r-ibld.c:195 openrisc-ibld.c:195 xstormy16-ibld.c:195
#, c-format
msgid "operand out of range (%ld not between %ld and %ld)"
msgstr ""
-#: cgen-asm.c:367
+#: cgen-asm.c:369
#, c-format
msgid "operand out of range (%lu not between %lu and %lu)"
msgstr ""
@@ -88,128 +87,134 @@ msgstr ""
msgid "Address 0x%x is out of bounds.\n"
msgstr ""
-#: fr30-asm.c:323 frv-asm.c:595 m32r-asm.c:325 openrisc-asm.c:244
-#: xstormy16-asm.c:231
+#: fr30-asm.c:323 frv-asm.c:626 ip2k-asm.c:574 iq2000-asm.c:460 m32r-asm.c:325
+#: openrisc-asm.c:244 xstormy16-asm.c:284
#, c-format
msgid "Unrecognized field %d while parsing.\n"
msgstr ""
-#: fr30-asm.c:373 frv-asm.c:645 m32r-asm.c:375 openrisc-asm.c:294
-#: xstormy16-asm.c:281
+#: fr30-asm.c:373 frv-asm.c:676 ip2k-asm.c:624 iq2000-asm.c:510 m32r-asm.c:375
+#: openrisc-asm.c:294 xstormy16-asm.c:334
msgid "missing mnemonic in syntax string"
msgstr ""
#. We couldn't parse it.
-#: fr30-asm.c:509 fr30-asm.c:513 fr30-asm.c:600 fr30-asm.c:702 frv-asm.c:781
-#: frv-asm.c:785 frv-asm.c:872 frv-asm.c:974 m32r-asm.c:511 m32r-asm.c:515
+#: fr30-asm.c:509 fr30-asm.c:513 fr30-asm.c:600 fr30-asm.c:702 frv-asm.c:812
+#: frv-asm.c:816 frv-asm.c:903 frv-asm.c:1005 ip2k-asm.c:760 ip2k-asm.c:764
+#: ip2k-asm.c:851 ip2k-asm.c:953 iq2000-asm.c:646 iq2000-asm.c:650
+#: iq2000-asm.c:737 iq2000-asm.c:839 m32r-asm.c:511 m32r-asm.c:515
#: m32r-asm.c:602 m32r-asm.c:704 openrisc-asm.c:430 openrisc-asm.c:434
-#: openrisc-asm.c:521 openrisc-asm.c:623 xstormy16-asm.c:417
-#: xstormy16-asm.c:421 xstormy16-asm.c:508 xstormy16-asm.c:610
+#: openrisc-asm.c:521 openrisc-asm.c:623 xstormy16-asm.c:470
+#: xstormy16-asm.c:474 xstormy16-asm.c:561 xstormy16-asm.c:663
msgid "unrecognized instruction"
msgstr ""
-#: fr30-asm.c:556 frv-asm.c:828 m32r-asm.c:558 openrisc-asm.c:477
-#: xstormy16-asm.c:464
+#: fr30-asm.c:556 frv-asm.c:859 ip2k-asm.c:807 iq2000-asm.c:693 m32r-asm.c:558
+#: openrisc-asm.c:477 xstormy16-asm.c:517
#, c-format
msgid "syntax error (expected char `%c', found `%c')"
msgstr ""
-#: fr30-asm.c:566 frv-asm.c:838 m32r-asm.c:568 openrisc-asm.c:487
-#: xstormy16-asm.c:474
+#: fr30-asm.c:566 frv-asm.c:869 ip2k-asm.c:817 iq2000-asm.c:703 m32r-asm.c:568
+#: openrisc-asm.c:487 xstormy16-asm.c:527
#, c-format
msgid "syntax error (expected char `%c', found end of instruction)"
msgstr ""
-#: fr30-asm.c:594 frv-asm.c:866 m32r-asm.c:596 openrisc-asm.c:515
-#: xstormy16-asm.c:502
+#: fr30-asm.c:594 frv-asm.c:897 ip2k-asm.c:845 iq2000-asm.c:731 m32r-asm.c:596
+#: openrisc-asm.c:515 xstormy16-asm.c:555
msgid "junk at end of line"
msgstr ""
-#: fr30-asm.c:701 frv-asm.c:973 m32r-asm.c:703 openrisc-asm.c:622
-#: xstormy16-asm.c:609
+#: fr30-asm.c:701 frv-asm.c:1004 ip2k-asm.c:952 iq2000-asm.c:838
+#: m32r-asm.c:703 openrisc-asm.c:622 xstormy16-asm.c:662
msgid "unrecognized form of instruction"
msgstr ""
-#: fr30-asm.c:713 frv-asm.c:985 m32r-asm.c:715 openrisc-asm.c:634
-#: xstormy16-asm.c:621
+#: fr30-asm.c:713 frv-asm.c:1016 ip2k-asm.c:964 iq2000-asm.c:850
+#: m32r-asm.c:715 openrisc-asm.c:634 xstormy16-asm.c:674
#, c-format
msgid "bad instruction `%.50s...'"
msgstr ""
-#: fr30-asm.c:716 frv-asm.c:988 m32r-asm.c:718 openrisc-asm.c:637
-#: xstormy16-asm.c:624
+#: fr30-asm.c:716 frv-asm.c:1019 ip2k-asm.c:967 iq2000-asm.c:853
+#: m32r-asm.c:718 openrisc-asm.c:637 xstormy16-asm.c:677
#, c-format
msgid "bad instruction `%.50s'"
msgstr ""
#. Default text to print if an instruction isn't recognized.
-#: fr30-dis.c:39 frv-dis.c:39 m32r-dis.c:39 mmix-dis.c:282 openrisc-dis.c:39
-#: xstormy16-dis.c:39
+#: fr30-dis.c:41 frv-dis.c:41 ip2k-dis.c:41 iq2000-dis.c:41 m32r-dis.c:41
+#: mmix-dis.c:284 openrisc-dis.c:41 xstormy16-dis.c:41
msgid "*unknown*"
msgstr ""
-#: fr30-dis.c:318 frv-dis.c:360 m32r-dis.c:249 openrisc-dis.c:136
-#: xstormy16-dis.c:169
+#: fr30-dis.c:320 frv-dis.c:371 ip2k-dis.c:329 iq2000-dis.c:192 m32r-dis.c:251
+#: openrisc-dis.c:138 xstormy16-dis.c:171
#, c-format
msgid "Unrecognized field %d while printing insn.\n"
msgstr ""
-#: fr30-ibld.c:166 frv-ibld.c:166 m32r-ibld.c:166 openrisc-ibld.c:166
-#: xstormy16-ibld.c:166
+#: fr30-ibld.c:166 frv-ibld.c:166 ip2k-ibld.c:166 iq2000-ibld.c:166
+#: m32r-ibld.c:166 openrisc-ibld.c:166 xstormy16-ibld.c:166
#, c-format
msgid "operand out of range (%ld not between %ld and %lu)"
msgstr ""
-#: fr30-ibld.c:179 frv-ibld.c:179 m32r-ibld.c:179 openrisc-ibld.c:179
-#: xstormy16-ibld.c:179
+#: fr30-ibld.c:179 frv-ibld.c:179 ip2k-ibld.c:179 iq2000-ibld.c:179
+#: m32r-ibld.c:179 openrisc-ibld.c:179 xstormy16-ibld.c:179
#, c-format
msgid "operand out of range (%lu not between 0 and %lu)"
msgstr ""
-#: fr30-ibld.c:730 frv-ibld.c:820 m32r-ibld.c:659 openrisc-ibld.c:633
-#: xstormy16-ibld.c:678
+#: fr30-ibld.c:730 frv-ibld.c:829 ip2k-ibld.c:607 iq2000-ibld.c:713
+#: m32r-ibld.c:659 openrisc-ibld.c:633 xstormy16-ibld.c:678
#, c-format
msgid "Unrecognized field %d while building insn.\n"
msgstr ""
-#: fr30-ibld.c:937 frv-ibld.c:1103 m32r-ibld.c:792 openrisc-ibld.c:735
-#: xstormy16-ibld.c:826
+#: fr30-ibld.c:937 frv-ibld.c:1121 ip2k-ibld.c:684 iq2000-ibld.c:890
+#: m32r-ibld.c:792 openrisc-ibld.c:735 xstormy16-ibld.c:826
#, c-format
msgid "Unrecognized field %d while decoding insn.\n"
msgstr ""
-#: fr30-ibld.c:1086 frv-ibld.c:1348 m32r-ibld.c:902 openrisc-ibld.c:815
-#: xstormy16-ibld.c:939
+#: fr30-ibld.c:1086 frv-ibld.c:1375 ip2k-ibld.c:761 iq2000-ibld.c:1024
+#: m32r-ibld.c:902 openrisc-ibld.c:815 xstormy16-ibld.c:939
#, c-format
msgid "Unrecognized field %d while getting int operand.\n"
msgstr ""
-#: fr30-ibld.c:1215 frv-ibld.c:1573 m32r-ibld.c:992 openrisc-ibld.c:875
-#: xstormy16-ibld.c:1032
+#: fr30-ibld.c:1215 frv-ibld.c:1609 ip2k-ibld.c:818 iq2000-ibld.c:1138
+#: m32r-ibld.c:992 openrisc-ibld.c:875 xstormy16-ibld.c:1032
#, c-format
msgid "Unrecognized field %d while getting vma operand.\n"
msgstr ""
-#: fr30-ibld.c:1349 frv-ibld.c:1807 m32r-ibld.c:1090 openrisc-ibld.c:944
-#: xstormy16-ibld.c:1134
+#: fr30-ibld.c:1349 frv-ibld.c:1852 ip2k-ibld.c:880 iq2000-ibld.c:1261
+#: m32r-ibld.c:1090 openrisc-ibld.c:944 xstormy16-ibld.c:1134
#, c-format
msgid "Unrecognized field %d while setting int operand.\n"
msgstr ""
-#: fr30-ibld.c:1471 frv-ibld.c:2029 m32r-ibld.c:1176 openrisc-ibld.c:1001
-#: xstormy16-ibld.c:1224
+#: fr30-ibld.c:1471 frv-ibld.c:2083 ip2k-ibld.c:930 iq2000-ibld.c:1372
+#: m32r-ibld.c:1176 openrisc-ibld.c:1001 xstormy16-ibld.c:1224
#, c-format
msgid "Unrecognized field %d while setting vma operand.\n"
msgstr ""
-#: h8300-dis.c:385
+#: frv-asm.c:365
+msgid "register number must be even"
+msgstr ""
+
+#: h8300-dis.c:377
#, c-format
-msgid "Hmmmm %x"
+msgid "Hmmmm 0x%x"
msgstr ""
-#: h8300-dis.c:396
+#: h8300-dis.c:760
#, c-format
-msgid "Don't understand %x \n"
+msgid "Don't understand 0x%x \n"
msgstr ""
#: h8500-dis.c:143
@@ -223,10 +228,185 @@ msgstr ""
msgid "%02x\t\t*unknown*"
msgstr ""
-#: i386-dis.c:1649
+#: i386-dis.c:1699
msgid "<internal disassembler error>"
msgstr ""
+#: ia64-gen.c:295
+#, c-format
+msgid "%s: Error: "
+msgstr ""
+
+#: ia64-gen.c:308
+#, c-format
+msgid "%s: Warning: "
+msgstr ""
+
+#: ia64-gen.c:494 ia64-gen.c:728
+#, c-format
+msgid "multiple note %s not handled\n"
+msgstr ""
+
+#: ia64-gen.c:605
+msgid "can't find ia64-ic.tbl for reading\n"
+msgstr ""
+
+#: ia64-gen.c:810
+#, c-format
+msgid "can't find %s for reading\n"
+msgstr ""
+
+#: ia64-gen.c:1034
+#, c-format
+msgid ""
+"most recent format '%s'\n"
+"appears more restrictive than '%s'\n"
+msgstr ""
+
+#: ia64-gen.c:1045
+#, c-format
+msgid "overlapping field %s->%s\n"
+msgstr ""
+
+#: ia64-gen.c:1236
+#, c-format
+msgid "overwriting note %d with note %d (IC:%s)\n"
+msgstr ""
+
+#: ia64-gen.c:1435
+#, c-format
+msgid "don't know how to specify %% dependency %s\n"
+msgstr ""
+
+#: ia64-gen.c:1457
+#, c-format
+msgid "Don't know how to specify # dependency %s\n"
+msgstr ""
+
+#: ia64-gen.c:1496
+#, c-format
+msgid "IC:%s [%s] has no terminals or sub-classes\n"
+msgstr ""
+
+#: ia64-gen.c:1499
+#, c-format
+msgid "IC:%s has no terminals or sub-classes\n"
+msgstr ""
+
+#: ia64-gen.c:1508
+#, c-format
+msgid "no insns mapped directly to terminal IC %s [%s]"
+msgstr ""
+
+#: ia64-gen.c:1511
+#, c-format
+msgid "no insns mapped directly to terminal IC %s\n"
+msgstr ""
+
+#: ia64-gen.c:1522
+#, c-format
+msgid "class %s is defined but not used\n"
+msgstr ""
+
+#: ia64-gen.c:1533
+#, c-format
+msgid "Warning: rsrc %s (%s) has no chks%s\n"
+msgstr ""
+
+#: ia64-gen.c:1537
+#, c-format
+msgid "rsrc %s (%s) has no regs\n"
+msgstr ""
+
+#: ia64-gen.c:2436
+#, c-format
+msgid "IC note %d in opcode %s (IC:%s) conflicts with resource %s note %d\n"
+msgstr ""
+
+#: ia64-gen.c:2464
+#, c-format
+msgid "IC note %d for opcode %s (IC:%s) conflicts with resource %s note %d\n"
+msgstr ""
+
+#: ia64-gen.c:2478
+#, c-format
+msgid "opcode %s has no class (ops %d %d %d)\n"
+msgstr ""
+
+#: ia64-gen.c:2789
+#, c-format
+msgid "unable to change directory to \"%s\", errno = %s\n"
+msgstr ""
+
+#. We've been passed a w. Return with an error message so that
+#. cgen will try the next parsing option.
+#: ip2k-asm.c:92
+msgid "W keyword invalid in FR operand slot."
+msgstr ""
+
+#. Invalid offset present.
+#: ip2k-asm.c:122
+msgid "offset(IP) is not a valid form"
+msgstr ""
+
+#. Found something there in front of (DP) but it's out
+#. of range.
+#: ip2k-asm.c:175
+msgid "(DP) offset out of range."
+msgstr ""
+
+#. Found something there in front of (SP) but it's out
+#. of range.
+#: ip2k-asm.c:221
+msgid "(SP) offset out of range."
+msgstr ""
+
+#: ip2k-asm.c:241
+msgid "illegal use of parentheses"
+msgstr ""
+
+#: ip2k-asm.c:248
+msgid "operand out of range (not between 1 and 255)"
+msgstr ""
+
+#. Something is very wrong. opindex has to be one of the above.
+#: ip2k-asm.c:273
+msgid "parse_addr16: invalid opindex."
+msgstr ""
+
+#: ip2k-asm.c:353
+msgid "Byte address required. - must be even."
+msgstr ""
+
+#: ip2k-asm.c:362
+msgid "cgen_parse_address returned a symbol. Literal required."
+msgstr ""
+
+#: ip2k-asm.c:420
+#, c-format
+msgid "%operator operand is not a symbol"
+msgstr ""
+
+#: ip2k-asm.c:474
+msgid "Attempt to find bit index of 0"
+msgstr ""
+
+#: iq2000-asm.c:110 iq2000-asm.c:141
+msgid "immediate value cannot be register"
+msgstr ""
+
+#: iq2000-asm.c:120 iq2000-asm.c:151
+msgid "immediate value out of range"
+msgstr ""
+
+#: iq2000-asm.c:180
+msgid "21-bit offset out of range"
+msgstr ""
+
+#: iq2000-asm.c:205 iq2000-asm.c:235 iq2000-asm.c:272 iq2000-asm.c:305
+msgid "missing `)'"
+msgstr ""
+
#: m10200-dis.c:199
#, c-format
msgid "unknown\t0x%02x"
@@ -237,7 +417,7 @@ msgstr ""
msgid "unknown\t0x%04lx"
msgstr ""
-#: m10300-dis.c:685
+#: m10300-dis.c:766
#, c-format
msgid "unknown\t0x%04x"
msgstr ""
@@ -252,21 +432,99 @@ msgstr ""
msgid "<function code %d>"
msgstr ""
-#: m88k-dis.c:255
+#: m88k-dis.c:746
#, c-format
msgid "# <dis error: %08x>"
msgstr ""
-#: mips-dis.c:337
+#: mips-dis.c:703
+msgid "# internal error, incomplete extension sequence (+)"
+msgstr ""
+
+#: mips-dis.c:746
+#, c-format
+msgid "# internal error, undefined extension sequence (+%c)"
+msgstr ""
+
+#: mips-dis.c:1004
#, c-format
msgid "# internal error, undefined modifier(%c)"
msgstr ""
-#: mips-dis.c:1209
+#: mips-dis.c:1755
#, c-format
msgid "# internal disassembler error, unrecognised modifier (%c)"
msgstr ""
+#: mips-dis.c:1767
+msgid ""
+"\n"
+"The following MIPS specific disassembler options are supported for use\n"
+"with the -M switch (multiple options should be separated by commas):\n"
+msgstr ""
+
+#: mips-dis.c:1771
+msgid ""
+"\n"
+" gpr-names=ABI Print GPR names according to specified ABI.\n"
+" Default: based on binary being disassembled.\n"
+msgstr ""
+
+#: mips-dis.c:1775
+msgid ""
+"\n"
+" fpr-names=ABI Print FPR names according to specified ABI.\n"
+" Default: numeric.\n"
+msgstr ""
+
+#: mips-dis.c:1779
+msgid ""
+"\n"
+" cp0-names=ARCH Print CP0 register names according to\n"
+" specified architecture.\n"
+" Default: based on binary being disassembled.\n"
+msgstr ""
+
+#: mips-dis.c:1784
+msgid ""
+"\n"
+" hwr-names=ARCH Print HWR names according to specified \n"
+"\t\t\t architecture.\n"
+" Default: based on binary being disassembled.\n"
+msgstr ""
+
+#: mips-dis.c:1789
+msgid ""
+"\n"
+" reg-names=ABI Print GPR and FPR names according to\n"
+" specified ABI.\n"
+msgstr ""
+
+#: mips-dis.c:1793
+msgid ""
+"\n"
+" reg-names=ARCH Print CP0 register and HWR names according to\n"
+" specified architecture.\n"
+msgstr ""
+
+#: mips-dis.c:1797
+msgid ""
+"\n"
+" For the options above, the following values are supported for \"ABI\":\n"
+" "
+msgstr ""
+
+#: mips-dis.c:1802 mips-dis.c:1810 mips-dis.c:1812
+msgid "\n"
+msgstr ""
+
+#: mips-dis.c:1804
+msgid ""
+"\n"
+" For the options above, The following values are supported for \"ARCH\":\n"
+" "
+msgstr ""
+
#: mmix-dis.c:34
#, c-format
msgid "Bad case %d (%s) in %s:%d\n"
@@ -281,7 +539,7 @@ msgstr ""
msgid "(unknown)"
msgstr ""
-#: mmix-dis.c:517
+#: mmix-dis.c:519
#, c-format
msgid "*unknown operands type: %d*"
msgstr ""
@@ -292,76 +550,116 @@ msgstr ""
#. * aoffsetp by since whatever generated this is broken
#. * anyway!
#.
-#: ns32k-dis.c:628
+#: ns32k-dis.c:631
msgid "$<undefined>"
msgstr ""
-#: ppc-opc.c:777 ppc-opc.c:810
+#: ppc-opc.c:781 ppc-opc.c:809
msgid "invalid conditional option"
msgstr ""
-#: ppc-opc.c:812
+#: ppc-opc.c:811
msgid "attempt to set y bit when using + or - modifier"
msgstr ""
-#: ppc-opc.c:844 ppc-opc.c:896
+#: ppc-opc.c:840
+msgid "offset not a multiple of 16"
+msgstr ""
+
+#: ppc-opc.c:860
+msgid "offset not a multiple of 2"
+msgstr ""
+
+#: ppc-opc.c:862
+msgid "offset greater than 62"
+msgstr ""
+
+#: ppc-opc.c:881 ppc-opc.c:927 ppc-opc.c:975
msgid "offset not a multiple of 4"
msgstr ""
-#: ppc-opc.c:869
+#: ppc-opc.c:883
+msgid "offset greater than 124"
+msgstr ""
+
+#: ppc-opc.c:902
+msgid "offset not a multiple of 8"
+msgstr ""
+
+#: ppc-opc.c:904
+msgid "offset greater than 248"
+msgstr ""
+
+#: ppc-opc.c:950
msgid "offset not between -2048 and 2047"
msgstr ""
-#: ppc-opc.c:894
+#: ppc-opc.c:973
msgid "offset not between -8192 and 8191"
msgstr ""
-#: ppc-opc.c:922
+#: ppc-opc.c:1011
+msgid "ignoring invalid mfcr mask"
+msgstr ""
+
+#: ppc-opc.c:1059
msgid "ignoring least significant bits in branch offset"
msgstr ""
-#: ppc-opc.c:956 ppc-opc.c:993
+#: ppc-opc.c:1090 ppc-opc.c:1125
msgid "illegal bitmask"
msgstr ""
-#: ppc-opc.c:1066
+#: ppc-opc.c:1192
msgid "value out of range"
msgstr ""
-#: ppc-opc.c:1142
+#: ppc-opc.c:1262
msgid "index register in load range"
msgstr ""
-#: ppc-opc.c:1158
+#: ppc-opc.c:1279
+msgid "source and target register operands must be different"
+msgstr ""
+
+#: ppc-opc.c:1294
msgid "invalid register operand when updating"
msgstr ""
-#. Mark as non-valid instruction
-#: sparc-dis.c:750
+#: ppc-opc.c:1335
+msgid "target register operand must be even"
+msgstr ""
+
+#: ppc-opc.c:1350
+msgid "source register operand must be even"
+msgstr ""
+
+#. Mark as non-valid instruction.
+#: sparc-dis.c:760
msgid "unknown"
msgstr ""
-#: sparc-dis.c:825
+#: sparc-dis.c:835
#, c-format
msgid "Internal error: bad sparc-opcode.h: \"%s\", %#.8lx, %#.8lx\n"
msgstr ""
-#: sparc-dis.c:836
+#: sparc-dis.c:846
#, c-format
msgid "Internal error: bad sparc-opcode.h: \"%s\", %#.8lx, %#.8lx\n"
msgstr ""
-#: sparc-dis.c:885
+#: sparc-dis.c:895
#, c-format
msgid "Internal error: bad sparc-opcode.h: \"%s\" == \"%s\"\n"
msgstr ""
-#: v850-dis.c:224
+#: v850-dis.c:221
#, c-format
msgid "unknown operand shift: %x\n"
msgstr ""
-#: v850-dis.c:236
+#: v850-dis.c:233
#, c-format
msgid "unknown pop reg: %d\n"
msgstr ""
@@ -415,30 +713,42 @@ msgstr ""
msgid "immediate value must be even"
msgstr ""
-#: xstormy16-asm.c:74
+#: xstormy16-asm.c:76
msgid "Bad register in preincrement"
msgstr ""
-#: xstormy16-asm.c:79
+#: xstormy16-asm.c:81
msgid "Bad register in postincrement"
msgstr ""
-#: xstormy16-asm.c:81
+#: xstormy16-asm.c:83
msgid "Bad register name"
msgstr ""
-#: xstormy16-asm.c:85
+#: xstormy16-asm.c:87
msgid "Label conflicts with register name"
msgstr ""
-#: xstormy16-asm.c:89
+#: xstormy16-asm.c:91
msgid "Label conflicts with `Rx'"
msgstr ""
-#: xstormy16-asm.c:91
+#: xstormy16-asm.c:93
msgid "Bad immediate expression"
msgstr ""
-#: xstormy16-asm.c:120
+#: xstormy16-asm.c:115
+msgid "No relocation for small immediate"
+msgstr ""
+
+#: xstormy16-asm.c:125
msgid "Small operand was not an immediate number"
msgstr ""
+
+#: xstormy16-asm.c:164
+msgid "Operand is not a symbol"
+msgstr ""
+
+#: xstormy16-asm.c:172
+msgid "Syntax error: No trailing ')'"
+msgstr ""
diff --git a/contrib/binutils/opcodes/ppc-dis.c b/contrib/binutils/opcodes/ppc-dis.c
index 35726ae..4d48b9d 100644
--- a/contrib/binutils/opcodes/ppc-dis.c
+++ b/contrib/binutils/opcodes/ppc-dis.c
@@ -1,5 +1,6 @@
/* ppc-dis.c -- Disassemble PowerPC instructions
- Copyright 1994, 1995, 2000, 2001, 2002 Free Software Foundation, Inc.
+ Copyright 1994, 1995, 2000, 2001, 2002, 2003, 2004
+ Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support
This file is part of GDB, GAS, and the GNU binutils.
@@ -29,18 +30,19 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
in both big and little endian mode and also for the POWER (RS/6000)
chip. */
-static int print_insn_powerpc PARAMS ((bfd_vma, struct disassemble_info *,
- int bigendian, int dialect));
+static int print_insn_powerpc (bfd_vma, struct disassemble_info *, int, int);
-static int powerpc_dialect PARAMS ((struct disassemble_info *));
+struct dis_private {
+ /* Stash the result of parsing disassembler_options here. */
+ int dialect;
+};
/* Determine which set of machines to disassemble for. PPC403/601 or
BookE. For convenience, also disassemble instructions supported
by the AltiVec vector unit. */
-int
-powerpc_dialect(info)
- struct disassemble_info *info;
+static int
+powerpc_dialect (struct disassemble_info *info)
{
int dialect = PPC_OPCODE_PPC | PPC_OPCODE_ALTIVEC;
@@ -48,17 +50,39 @@ powerpc_dialect(info)
dialect |= PPC_OPCODE_64;
if (info->disassembler_options
- && (strcmp (info->disassembler_options, "booke") == 0
- || strcmp (info->disassembler_options, "booke32") == 0
- || strcmp (info->disassembler_options, "booke64") == 0))
+ && strstr (info->disassembler_options, "booke") != NULL)
dialect |= PPC_OPCODE_BOOKE | PPC_OPCODE_BOOKE64;
- else
- dialect |= PPC_OPCODE_403 | PPC_OPCODE_601;
+ else if ((info->mach == bfd_mach_ppc_e500)
+ || (info->disassembler_options
+ && strstr (info->disassembler_options, "e500") != NULL))
+ {
+ dialect |= PPC_OPCODE_BOOKE
+ | PPC_OPCODE_SPE | PPC_OPCODE_ISEL
+ | PPC_OPCODE_EFS | PPC_OPCODE_BRLOCK
+ | PPC_OPCODE_PMR | PPC_OPCODE_CACHELCK
+ | PPC_OPCODE_RFMCI;
+ /* efs* and AltiVec conflict. */
+ dialect &= ~PPC_OPCODE_ALTIVEC;
+ }
+ else if (info->disassembler_options
+ && strstr (info->disassembler_options, "efs") != NULL)
+ {
+ dialect |= PPC_OPCODE_EFS;
+ /* efs* and AltiVec conflict. */
+ dialect &= ~PPC_OPCODE_ALTIVEC;
+ }
+ else
+ dialect |= (PPC_OPCODE_403 | PPC_OPCODE_601 | PPC_OPCODE_CLASSIC
+ | PPC_OPCODE_COMMON);
if (info->disassembler_options
- && strcmp (info->disassembler_options, "power4") == 0)
+ && strstr (info->disassembler_options, "power4") != NULL)
dialect |= PPC_OPCODE_POWER4;
+ if (info->disassembler_options
+ && strstr (info->disassembler_options, "any") != NULL)
+ dialect |= PPC_OPCODE_ANY;
+
if (info->disassembler_options)
{
if (strstr (info->disassembler_options, "32") != NULL)
@@ -67,35 +91,32 @@ powerpc_dialect(info)
dialect |= PPC_OPCODE_64;
}
+ ((struct dis_private *) &info->private_data)->dialect = dialect;
return dialect;
}
/* Print a big endian PowerPC instruction. */
int
-print_insn_big_powerpc (memaddr, info)
- bfd_vma memaddr;
- struct disassemble_info *info;
+print_insn_big_powerpc (bfd_vma memaddr, struct disassemble_info *info)
{
- return print_insn_powerpc (memaddr, info, 1, powerpc_dialect(info));
+ int dialect = ((struct dis_private *) &info->private_data)->dialect;
+ return print_insn_powerpc (memaddr, info, 1, dialect);
}
/* Print a little endian PowerPC instruction. */
int
-print_insn_little_powerpc (memaddr, info)
- bfd_vma memaddr;
- struct disassemble_info *info;
+print_insn_little_powerpc (bfd_vma memaddr, struct disassemble_info *info)
{
- return print_insn_powerpc (memaddr, info, 0, powerpc_dialect(info));
+ int dialect = ((struct dis_private *) &info->private_data)->dialect;
+ return print_insn_powerpc (memaddr, info, 0, dialect);
}
/* Print a POWER (RS/6000) instruction. */
int
-print_insn_rs6000 (memaddr, info)
- bfd_vma memaddr;
- struct disassemble_info *info;
+print_insn_rs6000 (bfd_vma memaddr, struct disassemble_info *info)
{
return print_insn_powerpc (memaddr, info, 1, PPC_OPCODE_POWER);
}
@@ -103,11 +124,10 @@ print_insn_rs6000 (memaddr, info)
/* Print a PowerPC or POWER instruction. */
static int
-print_insn_powerpc (memaddr, info, bigendian, dialect)
- bfd_vma memaddr;
- struct disassemble_info *info;
- int bigendian;
- int dialect;
+print_insn_powerpc (bfd_vma memaddr,
+ struct disassemble_info *info,
+ int bigendian,
+ int dialect)
{
bfd_byte buffer[4];
int status;
@@ -116,6 +136,9 @@ print_insn_powerpc (memaddr, info, bigendian, dialect)
const struct powerpc_opcode *opcode_end;
unsigned long op;
+ if (dialect == 0)
+ dialect = powerpc_dialect (info);
+
status = (*info->read_memory_func) (memaddr, buffer, 4, info);
if (status != 0)
{
@@ -134,6 +157,7 @@ print_insn_powerpc (memaddr, info, bigendian, dialect)
/* Find the first match in the opcode table. We could speed this up
a bit by doing a binary search on the major opcode. */
opcode_end = powerpc_opcodes + powerpc_num_opcodes;
+ again:
for (opcode = powerpc_opcodes; opcode < opcode_end; opcode++)
{
unsigned long table_op;
@@ -167,9 +191,10 @@ print_insn_powerpc (memaddr, info, bigendian, dialect)
continue;
/* The instruction is valid. */
- (*info->fprintf_func) (info->stream, "%s", opcode->name);
if (opcode->operands[0] != 0)
- (*info->fprintf_func) (info->stream, "\t");
+ (*info->fprintf_func) (info->stream, "%-7s ", opcode->name);
+ else
+ (*info->fprintf_func) (info->stream, "%s", opcode->name);
/* Now extract and print the operands. */
need_comma = 0;
@@ -188,7 +213,7 @@ print_insn_powerpc (memaddr, info, bigendian, dialect)
/* Extract the value from the instruction. */
if (operand->extract)
- value = (*operand->extract) (insn, dialect, (int *) NULL);
+ value = (*operand->extract) (insn, dialect, &invalid);
else
{
value = (insn >> operand->shift) & ((1 << operand->bits) - 1);
@@ -211,7 +236,8 @@ print_insn_powerpc (memaddr, info, bigendian, dialect)
}
/* Print the operand as directed by the flags. */
- if ((operand->flags & PPC_OPERAND_GPR) != 0)
+ if ((operand->flags & PPC_OPERAND_GPR) != 0
+ || ((operand->flags & PPC_OPERAND_GPR_0) != 0 && value != 0))
(*info->fprintf_func) (info->stream, "r%ld", value);
else if ((operand->flags & PPC_OPERAND_FPR) != 0)
(*info->fprintf_func) (info->stream, "f%ld", value);
@@ -236,14 +262,9 @@ print_insn_powerpc (memaddr, info, bigendian, dialect)
cr = value >> 2;
if (cr != 0)
- (*info->fprintf_func) (info->stream, "4*cr%d", cr);
+ (*info->fprintf_func) (info->stream, "4*cr%d+", cr);
cc = value & 3;
- if (cc != 0)
- {
- if (cr != 0)
- (*info->fprintf_func) (info->stream, "+");
- (*info->fprintf_func) (info->stream, "%s", cbnames[cc]);
- }
+ (*info->fprintf_func) (info->stream, "%s", cbnames[cc]);
}
}
@@ -266,6 +287,12 @@ print_insn_powerpc (memaddr, info, bigendian, dialect)
return 4;
}
+ if ((dialect & PPC_OPCODE_ANY) != 0)
+ {
+ dialect = ~PPC_OPCODE_ANY;
+ goto again;
+ }
+
/* We could not find a match. */
(*info->fprintf_func) (info->stream, ".long 0x%lx", insn);
@@ -273,13 +300,15 @@ print_insn_powerpc (memaddr, info, bigendian, dialect)
}
void
-print_ppc_disassembler_options (FILE * stream)
+print_ppc_disassembler_options (FILE *stream)
{
fprintf (stream, "\n\
The following PPC specific disassembler options are supported for use with\n\
the -M switch:\n");
-
+
fprintf (stream, " booke|booke32|booke64 Disassemble the BookE instructions\n");
+ fprintf (stream, " e500|e500x2 Disassemble the e500 instructions\n");
+ fprintf (stream, " efs Disassemble the EFS instructions\n");
fprintf (stream, " power4 Disassemble the Power4 instructions\n");
fprintf (stream, " 32 Do not disassemble 64-bit instructions\n");
fprintf (stream, " 64 Allow disassembly of 64-bit instructions\n");
diff --git a/contrib/binutils/opcodes/ppc-opc.c b/contrib/binutils/opcodes/ppc-opc.c
index 98ca1d2..2d0dee5 100644
--- a/contrib/binutils/opcodes/ppc-opc.c
+++ b/contrib/binutils/opcodes/ppc-opc.c
@@ -1,24 +1,24 @@
/* ppc-opc.c -- PowerPC opcode list
- Copyright 1994, 1995, 1996, 1997, 1998, 2000, 2001, 2002
+ Copyright 1994, 1995, 1996, 1997, 1998, 2000, 2001, 2002, 2003, 2004
Free Software Foundation, Inc.
Written by Ian Lance Taylor, Cygnus Support
-This file is part of GDB, GAS, and the GNU binutils.
+ This file is part of GDB, GAS, and the GNU binutils.
-GDB, GAS, and the GNU binutils are free software; you can redistribute
-them and/or modify them under the terms of the GNU General Public
-License as published by the Free Software Foundation; either version
-2, or (at your option) any later version.
+ GDB, GAS, and the GNU binutils are free software; you can redistribute
+ them and/or modify them under the terms of the GNU General Public
+ License as published by the Free Software Foundation; either version
+ 2, or (at your option) any later version.
-GDB, GAS, and the GNU binutils are distributed in the hope that they
-will be useful, but WITHOUT ANY WARRANTY; without even the implied
-warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
-the GNU General Public License for more details.
+ GDB, GAS, and the GNU binutils are distributed in the hope that they
+ will be useful, but WITHOUT ANY WARRANTY; without even the implied
+ warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
+ the GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this file; see the file COPYING. If not, write to the Free
-Software Foundation, 59 Temple Place - Suite 330, Boston, MA
-02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this file; see the file COPYING. If not, write to the Free
+ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
+ 02111-1307, USA. */
#include <stdio.h>
#include "sysdep.h"
@@ -38,90 +38,60 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
/* Local insertion and extraction functions. */
-static unsigned long insert_bat
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_bat
- PARAMS ((unsigned long, int, int *));
-static unsigned long insert_bba
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_bba
- PARAMS ((unsigned long, int, int *));
-static unsigned long insert_bd
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_bd
- PARAMS ((unsigned long, int, int *));
-static unsigned long insert_bdm
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_bdm
- PARAMS ((unsigned long, int, int *));
-static unsigned long insert_bdp
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_bdp
- PARAMS ((unsigned long, int, int *));
-static int valid_bo
- PARAMS ((long, int));
-static unsigned long insert_bo
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_bo
- PARAMS ((unsigned long, int, int *));
-static unsigned long insert_boe
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_boe
- PARAMS ((unsigned long, int, int *));
-static unsigned long insert_ds
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_ds
- PARAMS ((unsigned long, int, int *));
-static unsigned long insert_de
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_de
- PARAMS ((unsigned long, int, int *));
-static unsigned long insert_des
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_des
- PARAMS ((unsigned long, int, int *));
-static unsigned long insert_li
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_li
- PARAMS ((unsigned long, int, int *));
-static unsigned long insert_mbe
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_mbe
- PARAMS ((unsigned long, int, int *));
-static unsigned long insert_mb6
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_mb6
- PARAMS ((unsigned long, int, int *));
-static unsigned long insert_nb
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_nb
- PARAMS ((unsigned long, int, int *));
-static unsigned long insert_nsi
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_nsi
- PARAMS ((unsigned long, int, int *));
-static unsigned long insert_ral
- PARAMS ((unsigned long, long, int, const char **));
-static unsigned long insert_ram
- PARAMS ((unsigned long, long, int, const char **));
-static unsigned long insert_ras
- PARAMS ((unsigned long, long, int, const char **));
-static unsigned long insert_rbs
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_rbs
- PARAMS ((unsigned long, int, int *));
-static unsigned long insert_sh6
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_sh6
- PARAMS ((unsigned long, int, int *));
-static unsigned long insert_spr
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_spr
- PARAMS ((unsigned long, int, int *));
-static unsigned long insert_tbr
- PARAMS ((unsigned long, long, int, const char **));
-static long extract_tbr
- PARAMS ((unsigned long, int, int *));
+static unsigned long insert_bat (unsigned long, long, int, const char **);
+static long extract_bat (unsigned long, int, int *);
+static unsigned long insert_bba (unsigned long, long, int, const char **);
+static long extract_bba (unsigned long, int, int *);
+static unsigned long insert_bd (unsigned long, long, int, const char **);
+static long extract_bd (unsigned long, int, int *);
+static unsigned long insert_bdm (unsigned long, long, int, const char **);
+static long extract_bdm (unsigned long, int, int *);
+static unsigned long insert_bdp (unsigned long, long, int, const char **);
+static long extract_bdp (unsigned long, int, int *);
+static unsigned long insert_bo (unsigned long, long, int, const char **);
+static long extract_bo (unsigned long, int, int *);
+static unsigned long insert_boe (unsigned long, long, int, const char **);
+static long extract_boe (unsigned long, int, int *);
+static unsigned long insert_dq (unsigned long, long, int, const char **);
+static long extract_dq (unsigned long, int, int *);
+static unsigned long insert_ds (unsigned long, long, int, const char **);
+static long extract_ds (unsigned long, int, int *);
+static unsigned long insert_de (unsigned long, long, int, const char **);
+static long extract_de (unsigned long, int, int *);
+static unsigned long insert_des (unsigned long, long, int, const char **);
+static long extract_des (unsigned long, int, int *);
+static unsigned long insert_fxm (unsigned long, long, int, const char **);
+static long extract_fxm (unsigned long, int, int *);
+static unsigned long insert_li (unsigned long, long, int, const char **);
+static long extract_li (unsigned long, int, int *);
+static unsigned long insert_mbe (unsigned long, long, int, const char **);
+static long extract_mbe (unsigned long, int, int *);
+static unsigned long insert_mb6 (unsigned long, long, int, const char **);
+static long extract_mb6 (unsigned long, int, int *);
+static unsigned long insert_nb (unsigned long, long, int, const char **);
+static long extract_nb (unsigned long, int, int *);
+static unsigned long insert_nsi (unsigned long, long, int, const char **);
+static long extract_nsi (unsigned long, int, int *);
+static unsigned long insert_ral (unsigned long, long, int, const char **);
+static unsigned long insert_ram (unsigned long, long, int, const char **);
+static unsigned long insert_raq (unsigned long, long, int, const char **);
+static unsigned long insert_ras (unsigned long, long, int, const char **);
+static unsigned long insert_rbs (unsigned long, long, int, const char **);
+static long extract_rbs (unsigned long, int, int *);
+static unsigned long insert_rsq (unsigned long, long, int, const char **);
+static unsigned long insert_rtq (unsigned long, long, int, const char **);
+static unsigned long insert_sh6 (unsigned long, long, int, const char **);
+static long extract_sh6 (unsigned long, int, int *);
+static unsigned long insert_spr (unsigned long, long, int, const char **);
+static long extract_spr (unsigned long, int, int *);
+static unsigned long insert_tbr (unsigned long, long, int, const char **);
+static long extract_tbr (unsigned long, int, int *);
+static unsigned long insert_ev2 (unsigned long, long, int, const char **);
+static long extract_ev2 (unsigned long, int, int *);
+static unsigned long insert_ev4 (unsigned long, long, int, const char **);
+static long extract_ev4 (unsigned long, int, int *);
+static unsigned long insert_ev8 (unsigned long, long, int, const char **);
+static long extract_ev8 (unsigned long, int, int *);
/* The operands table.
@@ -235,8 +205,20 @@ const struct powerpc_operand powerpc_operands[] =
#define CR BT + 1
{ 3, 18, 0, 0, PPC_OPERAND_CR | PPC_OPERAND_OPTIONAL },
+ /* The CRB field in an X form instruction. */
+#define CRB CR + 1
+ { 5, 6, 0, 0, 0 },
+
+ /* The CRFD field in an X form instruction. */
+#define CRFD CRB + 1
+ { 3, 23, 0, 0, PPC_OPERAND_CR },
+
+ /* The CRFS field in an X form instruction. */
+#define CRFS CRFD + 1
+ { 3, 0, 0, 0, PPC_OPERAND_CR },
+
/* The CT field in an X form instruction. */
-#define CT CR + 1
+#define CT CRFS + 1
{ 5, 21, 0, 0, PPC_OPERAND_OPTIONAL },
/* The D field in a D form instruction. This is a displacement off
@@ -255,9 +237,15 @@ const struct powerpc_operand powerpc_operands[] =
#define DES DE + 1
{ 14, 0, insert_des, extract_des, PPC_OPERAND_PARENS | PPC_OPERAND_SIGNED },
+ /* The DQ field in a DQ form instruction. This is like D, but the
+ lower four bits are forced to zero. */
+#define DQ DES + 1
+ { 16, 0, insert_dq, extract_dq,
+ PPC_OPERAND_PARENS | PPC_OPERAND_SIGNED | PPC_OPERAND_DQ },
+
/* The DS field in a DS form instruction. This is like D, but the
lower two bits are forced to zero. */
-#define DS DES + 1
+#define DS DQ + 1
{ 16, 0, insert_ds, extract_ds,
PPC_OPERAND_PARENS | PPC_OPERAND_SIGNED | PPC_OPERAND_DS },
@@ -301,10 +289,14 @@ const struct powerpc_operand powerpc_operands[] =
/* The FXM field in an XFX instruction. */
#define FXM FRS + 1
#define FXM_MASK (0xff << 12)
- { 8, 12, 0, 0, 0 },
+ { 8, 12, insert_fxm, extract_fxm, 0 },
+
+ /* Power4 version for mfcr. */
+#define FXM4 FXM + 1
+ { 8, 12, insert_fxm, extract_fxm, PPC_OPERAND_OPTIONAL },
/* The L field in a D or X form instruction. */
-#define L FXM + 1
+#define L FXM4 + 1
{ 1, 21, 0, 0, PPC_OPERAND_OPTIONAL },
/* The LEV field in a POWER SC form instruction. */
@@ -352,7 +344,7 @@ const struct powerpc_operand powerpc_operands[] =
/* The MO field in an mbar instruction. */
#define MO MB6 + 1
- { 5, 21, 0, 0, 0 },
+ { 5, 21, 0, 0, PPC_OPERAND_OPTIONAL },
/* The NB field in an X form instruction. The value 32 is stored as
0. */
@@ -365,30 +357,43 @@ const struct powerpc_operand powerpc_operands[] =
{ 16, 0, insert_nsi, extract_nsi,
PPC_OPERAND_NEGATIVE | PPC_OPERAND_SIGNED },
- /* The RA field in an D, DS, X, XO, M, or MDS form instruction. */
+ /* The RA field in an D, DS, DQ, X, XO, M, or MDS form instruction. */
#define RA NSI + 1
#define RA_MASK (0x1f << 16)
{ 5, 16, 0, 0, PPC_OPERAND_GPR },
+ /* As above, but 0 in the RA field means zero, not r0. */
+#define RA0 RA + 1
+ { 5, 16, 0, 0, PPC_OPERAND_GPR_0 },
+
+ /* The RA field in the DQ form lq instruction, which has special
+ value restrictions. */
+#define RAQ RA0 + 1
+ { 5, 16, insert_raq, 0, PPC_OPERAND_GPR_0 },
+
/* The RA field in a D or X form instruction which is an updating
load, which means that the RA field may not be zero and may not
equal the RT field. */
-#define RAL RA + 1
- { 5, 16, insert_ral, 0, PPC_OPERAND_GPR },
+#define RAL RAQ + 1
+ { 5, 16, insert_ral, 0, PPC_OPERAND_GPR_0 },
/* The RA field in an lmw instruction, which has special value
restrictions. */
#define RAM RAL + 1
- { 5, 16, insert_ram, 0, PPC_OPERAND_GPR },
+ { 5, 16, insert_ram, 0, PPC_OPERAND_GPR_0 },
/* The RA field in a D or X form instruction which is an updating
store or an updating floating point load, which means that the RA
field may not be zero. */
#define RAS RAM + 1
- { 5, 16, insert_ras, 0, PPC_OPERAND_GPR },
+ { 5, 16, insert_ras, 0, PPC_OPERAND_GPR_0 },
+
+ /* The RA field of the tlbwe instruction, which is optional. */
+#define RAOPT RAS + 1
+ { 5, 16, 0, 0, PPC_OPERAND_GPR | PPC_OPERAND_OPTIONAL },
/* The RB field in an X, XO, M, or MDS form instruction. */
-#define RB RAS + 1
+#define RB RAOPT + 1
#define RB_MASK (0x1f << 11)
{ 5, 11, 0, 0, PPC_OPERAND_GPR },
@@ -406,8 +411,22 @@ const struct powerpc_operand powerpc_operands[] =
#define RT_MASK (0x1f << 21)
{ 5, 21, 0, 0, PPC_OPERAND_GPR },
+ /* The RS field of the DS form stq instruction, which has special
+ value restrictions. */
+#define RSQ RS + 1
+ { 5, 21, insert_rsq, 0, PPC_OPERAND_GPR_0 },
+
+ /* The RT field of the DQ form lq instruction, which has special
+ value restrictions. */
+#define RTQ RSQ + 1
+ { 5, 21, insert_rtq, 0, PPC_OPERAND_GPR_0 },
+
+ /* The RS field of the tlbwe instruction, which is optional. */
+#define RSO RTQ + 1
+ { 5, 21, 0, 0, PPC_OPERAND_GPR | PPC_OPERAND_OPTIONAL },
+
/* The SH field in an X or M form instruction. */
-#define SH RS + 1
+#define SH RSO + 1
#define SH_MASK (0x1f << 11)
{ 5, 11, 0, 0, 0 },
@@ -416,8 +435,12 @@ const struct powerpc_operand powerpc_operands[] =
#define SH6_MASK ((0x1f << 11) | (1 << 1))
{ 6, 1, insert_sh6, extract_sh6, 0 },
+ /* The SH field of the tlbwe instruction, which is optional. */
+#define SHO SH6 + 1
+ { 5, 11,0, 0, PPC_OPERAND_OPTIONAL },
+
/* The SI field in a D form instruction. */
-#define SI SH6 + 1
+#define SI SHO + 1
{ 16, 0, 0, 0, PPC_OPERAND_SIGNED },
/* The SI field in a D form instruction when we accept a wide range
@@ -428,6 +451,7 @@ const struct powerpc_operand powerpc_operands[] =
/* The SPR field in an XFX form instruction. This is flipped--the
lower 5 bits are stored in the upper 5 and vice- versa. */
#define SPR SISIGNOPT + 1
+#define PMR SPR
#define SPR_MASK (0x3ff << 11)
{ 10, 11, insert_spr, extract_spr, 0 },
@@ -472,41 +496,57 @@ const struct powerpc_operand powerpc_operands[] =
#define UI U + 1
{ 16, 0, 0, 0, 0 },
- /* The VA field in a VA, VX or VXR form instruction. */
+ /* The VA field in a VA, VX or VXR form instruction. */
#define VA UI + 1
#define VA_MASK (0x1f << 16)
{ 5, 16, 0, 0, PPC_OPERAND_VR },
- /* The VB field in a VA, VX or VXR form instruction. */
+ /* The VB field in a VA, VX or VXR form instruction. */
#define VB VA + 1
#define VB_MASK (0x1f << 11)
{ 5, 11, 0, 0, PPC_OPERAND_VR },
- /* The VC field in a VA form instruction. */
+ /* The VC field in a VA form instruction. */
#define VC VB + 1
#define VC_MASK (0x1f << 6)
{ 5, 6, 0, 0, PPC_OPERAND_VR },
- /* The VD or VS field in a VA, VX, VXR or X form instruction. */
+ /* The VD or VS field in a VA, VX, VXR or X form instruction. */
#define VD VC + 1
#define VS VD
#define VD_MASK (0x1f << 21)
{ 5, 21, 0, 0, PPC_OPERAND_VR },
- /* The SIMM field in a VX form instruction. */
+ /* The SIMM field in a VX form instruction. */
#define SIMM VD + 1
{ 5, 16, 0, 0, PPC_OPERAND_SIGNED},
- /* The UIMM field in a VX form instruction. */
+ /* The UIMM field in a VX form instruction. */
#define UIMM SIMM + 1
{ 5, 16, 0, 0, 0 },
- /* The SHB field in a VA form instruction. */
+ /* The SHB field in a VA form instruction. */
#define SHB UIMM + 1
{ 4, 6, 0, 0, 0 },
+ /* The other UIMM field in a EVX form instruction. */
+#define EVUIMM SHB + 1
+ { 5, 11, 0, 0, 0 },
+
+ /* The other UIMM field in a half word EVX form instruction. */
+#define EVUIMM_2 EVUIMM + 1
+ { 32, 11, insert_ev2, extract_ev2, PPC_OPERAND_PARENS },
+
+ /* The other UIMM field in a word EVX form instruction. */
+#define EVUIMM_4 EVUIMM_2 + 1
+ { 32, 11, insert_ev4, extract_ev4, PPC_OPERAND_PARENS },
+
+ /* The other UIMM field in a double EVX form instruction. */
+#define EVUIMM_8 EVUIMM_4 + 1
+ { 32, 11, insert_ev8, extract_ev8, PPC_OPERAND_PARENS },
+
/* The WS field. */
-#define WS SHB + 1
+#define WS EVUIMM_8 + 1
#define WS_MASK (0x7 << 11)
{ 3, 11, 0, 0, 0 },
@@ -524,25 +564,21 @@ const struct powerpc_operand powerpc_operands[] =
and the extraction function just checks that the fields are the
same. */
-/*ARGSUSED*/
static unsigned long
-insert_bat (insn, value, dialect, errmsg)
- unsigned long insn;
- long value ATTRIBUTE_UNUSED;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg ATTRIBUTE_UNUSED;
+insert_bat (unsigned long insn,
+ long value ATTRIBUTE_UNUSED,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg ATTRIBUTE_UNUSED)
{
return insn | (((insn >> 21) & 0x1f) << 16);
}
static long
-extract_bat (insn, dialect, invalid)
- unsigned long insn;
- int dialect ATTRIBUTE_UNUSED;
- int *invalid;
+extract_bat (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid)
{
- if (invalid != (int *) NULL
- && ((insn >> 21) & 0x1f) != ((insn >> 16) & 0x1f))
+ if (((insn >> 21) & 0x1f) != ((insn >> 16) & 0x1f))
*invalid = 1;
return 0;
}
@@ -553,25 +589,21 @@ extract_bat (insn, dialect, invalid)
and the extraction function just checks that the fields are the
same. */
-/*ARGSUSED*/
static unsigned long
-insert_bba (insn, value, dialect, errmsg)
- unsigned long insn;
- long value ATTRIBUTE_UNUSED;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg ATTRIBUTE_UNUSED;
+insert_bba (unsigned long insn,
+ long value ATTRIBUTE_UNUSED,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg ATTRIBUTE_UNUSED)
{
return insn | (((insn >> 16) & 0x1f) << 11);
}
static long
-extract_bba (insn, dialect, invalid)
- unsigned long insn;
- int dialect ATTRIBUTE_UNUSED;
- int *invalid;
+extract_bba (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid)
{
- if (invalid != (int *) NULL
- && ((insn >> 16) & 0x1f) != ((insn >> 11) & 0x1f))
+ if (((insn >> 16) & 0x1f) != ((insn >> 11) & 0x1f))
*invalid = 1;
return 0;
}
@@ -579,23 +611,19 @@ extract_bba (insn, dialect, invalid)
/* The BD field in a B form instruction. The lower two bits are
forced to zero. */
-/*ARGSUSED*/
static unsigned long
-insert_bd (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg ATTRIBUTE_UNUSED;
+insert_bd (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg ATTRIBUTE_UNUSED)
{
return insn | (value & 0xfffc);
}
-/*ARGSUSED*/
static long
-extract_bd (insn, dialect, invalid)
- unsigned long insn;
- int dialect ATTRIBUTE_UNUSED;
- int *invalid ATTRIBUTE_UNUSED;
+extract_bd (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid ATTRIBUTE_UNUSED)
{
return ((insn & 0xfffc) ^ 0x8000) - 0x8000;
}
@@ -613,13 +641,11 @@ extract_bd (insn, dialect, invalid)
in BO field, the "a" bit is 00010 for branch on CR(BI) and 01000
for branch on CTR. We only handle the taken/not-taken hint here. */
-/*ARGSUSED*/
static unsigned long
-insert_bdm (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect;
- const char **errmsg ATTRIBUTE_UNUSED;
+insert_bdm (unsigned long insn,
+ long value,
+ int dialect,
+ const char **errmsg ATTRIBUTE_UNUSED)
{
if ((dialect & PPC_OPCODE_POWER4) == 0)
{
@@ -637,25 +663,22 @@ insert_bdm (insn, value, dialect, errmsg)
}
static long
-extract_bdm (insn, dialect, invalid)
- unsigned long insn;
- int dialect;
- int *invalid;
+extract_bdm (unsigned long insn,
+ int dialect,
+ int *invalid)
{
- if (invalid != (int *) NULL)
+ if ((dialect & PPC_OPCODE_POWER4) == 0)
{
- if ((dialect & PPC_OPCODE_POWER4) == 0)
- {
- if (((insn & (1 << 21)) == 0) != ((insn & (1 << 15)) == 0))
- *invalid = 1;
- }
- else
- {
- if ((insn & (0x17 << 21)) != (0x06 << 21)
- && (insn & (0x1d << 21)) != (0x18 << 21))
- *invalid = 1;
- }
+ if (((insn & (1 << 21)) == 0) != ((insn & (1 << 15)) == 0))
+ *invalid = 1;
+ }
+ else
+ {
+ if ((insn & (0x17 << 21)) != (0x06 << 21)
+ && (insn & (0x1d << 21)) != (0x18 << 21))
+ *invalid = 1;
}
+
return ((insn & 0xfffc) ^ 0x8000) - 0x8000;
}
@@ -663,13 +686,11 @@ extract_bdm (insn, dialect, invalid)
This is like BDM, above, except that the branch is expected to be
taken. */
-/*ARGSUSED*/
static unsigned long
-insert_bdp (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect;
- const char **errmsg ATTRIBUTE_UNUSED;
+insert_bdp (unsigned long insn,
+ long value,
+ int dialect,
+ const char **errmsg ATTRIBUTE_UNUSED)
{
if ((dialect & PPC_OPCODE_POWER4) == 0)
{
@@ -687,34 +708,29 @@ insert_bdp (insn, value, dialect, errmsg)
}
static long
-extract_bdp (insn, dialect, invalid)
- unsigned long insn;
- int dialect;
- int *invalid;
+extract_bdp (unsigned long insn,
+ int dialect,
+ int *invalid)
{
- if (invalid != (int *) NULL)
+ if ((dialect & PPC_OPCODE_POWER4) == 0)
{
- if ((dialect & PPC_OPCODE_POWER4) == 0)
- {
- if (((insn & (1 << 21)) == 0) == ((insn & (1 << 15)) == 0))
- *invalid = 1;
- }
- else
- {
- if ((insn & (0x17 << 21)) != (0x07 << 21)
- && (insn & (0x1d << 21)) != (0x19 << 21))
- *invalid = 1;
- }
+ if (((insn & (1 << 21)) == 0) == ((insn & (1 << 15)) == 0))
+ *invalid = 1;
+ }
+ else
+ {
+ if ((insn & (0x17 << 21)) != (0x07 << 21)
+ && (insn & (0x1d << 21)) != (0x19 << 21))
+ *invalid = 1;
}
+
return ((insn & 0xfffc) ^ 0x8000) - 0x8000;
}
/* Check for legal values of a BO field. */
static int
-valid_bo (value, dialect)
- long value;
- int dialect;
+valid_bo (long value, int dialect)
{
if ((dialect & PPC_OPCODE_POWER4) == 0)
{
@@ -766,29 +782,25 @@ valid_bo (value, dialect)
the field to an illegal value. */
static unsigned long
-insert_bo (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect;
- const char **errmsg;
+insert_bo (unsigned long insn,
+ long value,
+ int dialect,
+ const char **errmsg)
{
- if (errmsg != (const char **) NULL
- && ! valid_bo (value, dialect))
+ if (!valid_bo (value, dialect))
*errmsg = _("invalid conditional option");
return insn | ((value & 0x1f) << 21);
}
static long
-extract_bo (insn, dialect, invalid)
- unsigned long insn;
- int dialect;
- int *invalid;
+extract_bo (unsigned long insn,
+ int dialect,
+ int *invalid)
{
long value;
value = (insn >> 21) & 0x1f;
- if (invalid != (int *) NULL
- && ! valid_bo (value, dialect))
+ if (!valid_bo (value, dialect))
*invalid = 1;
return value;
}
@@ -798,137 +810,262 @@ extract_bo (insn, dialect, invalid)
extracting it, we force it to be even. */
static unsigned long
-insert_boe (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect;
- const char **errmsg;
+insert_boe (unsigned long insn,
+ long value,
+ int dialect,
+ const char **errmsg)
{
- if (errmsg != (const char **) NULL)
- {
- if (! valid_bo (value, dialect))
- *errmsg = _("invalid conditional option");
- else if ((value & 1) != 0)
- *errmsg = _("attempt to set y bit when using + or - modifier");
- }
+ if (!valid_bo (value, dialect))
+ *errmsg = _("invalid conditional option");
+ else if ((value & 1) != 0)
+ *errmsg = _("attempt to set y bit when using + or - modifier");
+
return insn | ((value & 0x1f) << 21);
}
static long
-extract_boe (insn, dialect, invalid)
- unsigned long insn;
- int dialect;
- int *invalid;
+extract_boe (unsigned long insn,
+ int dialect,
+ int *invalid)
{
long value;
value = (insn >> 21) & 0x1f;
- if (invalid != (int *) NULL
- && ! valid_bo (value, dialect))
+ if (!valid_bo (value, dialect))
*invalid = 1;
return value & 0x1e;
}
+/* The DQ field in a DQ form instruction. This is like D, but the
+ lower four bits are forced to zero. */
+
+static unsigned long
+insert_dq (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg)
+{
+ if ((value & 0xf) != 0)
+ *errmsg = _("offset not a multiple of 16");
+ return insn | (value & 0xfff0);
+}
+
+static long
+extract_dq (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid ATTRIBUTE_UNUSED)
+{
+ return ((insn & 0xfff0) ^ 0x8000) - 0x8000;
+}
+
+static unsigned long
+insert_ev2 (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg)
+{
+ if ((value & 1) != 0)
+ *errmsg = _("offset not a multiple of 2");
+ if ((value > 62) != 0)
+ *errmsg = _("offset greater than 62");
+ return insn | ((value & 0x3e) << 10);
+}
+
+static long
+extract_ev2 (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid ATTRIBUTE_UNUSED)
+{
+ return (insn >> 10) & 0x3e;
+}
+
+static unsigned long
+insert_ev4 (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg)
+{
+ if ((value & 3) != 0)
+ *errmsg = _("offset not a multiple of 4");
+ if ((value > 124) != 0)
+ *errmsg = _("offset greater than 124");
+ return insn | ((value & 0x7c) << 9);
+}
+
+static long
+extract_ev4 (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid ATTRIBUTE_UNUSED)
+{
+ return (insn >> 9) & 0x7c;
+}
+
+static unsigned long
+insert_ev8 (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg)
+{
+ if ((value & 7) != 0)
+ *errmsg = _("offset not a multiple of 8");
+ if ((value > 248) != 0)
+ *errmsg = _("offset greater than 248");
+ return insn | ((value & 0xf8) << 8);
+}
+
+static long
+extract_ev8 (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid ATTRIBUTE_UNUSED)
+{
+ return (insn >> 8) & 0xf8;
+}
+
/* The DS field in a DS form instruction. This is like D, but the
lower two bits are forced to zero. */
-/*ARGSUSED*/
static unsigned long
-insert_ds (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg;
+insert_ds (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg)
{
- if ((value & 3) != 0 && errmsg != NULL)
+ if ((value & 3) != 0)
*errmsg = _("offset not a multiple of 4");
return insn | (value & 0xfffc);
}
-/*ARGSUSED*/
static long
-extract_ds (insn, dialect, invalid)
- unsigned long insn;
- int dialect ATTRIBUTE_UNUSED;
- int *invalid ATTRIBUTE_UNUSED;
+extract_ds (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid ATTRIBUTE_UNUSED)
{
return ((insn & 0xfffc) ^ 0x8000) - 0x8000;
}
/* The DE field in a DE form instruction. */
-/*ARGSUSED*/
static unsigned long
-insert_de (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg;
+insert_de (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg)
{
- if ((value > 2047 || value < -2048) && errmsg != NULL)
+ if (value > 2047 || value < -2048)
*errmsg = _("offset not between -2048 and 2047");
return insn | ((value << 4) & 0xfff0);
}
-/*ARGSUSED*/
static long
-extract_de (insn, dialect, invalid)
- unsigned long insn;
- int dialect ATTRIBUTE_UNUSED;
- int *invalid ATTRIBUTE_UNUSED;
+extract_de (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid ATTRIBUTE_UNUSED)
{
return (insn & 0xfff0) >> 4;
}
/* The DES field in a DES form instruction. */
-/*ARGSUSED*/
static unsigned long
-insert_des (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg;
+insert_des (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg)
{
- if ((value > 8191 || value < -8192) && errmsg != NULL)
+ if (value > 8191 || value < -8192)
*errmsg = _("offset not between -8192 and 8191");
- else if ((value & 3) != 0 && errmsg != NULL)
+ else if ((value & 3) != 0)
*errmsg = _("offset not a multiple of 4");
return insn | ((value << 2) & 0xfff0);
}
-/*ARGSUSED*/
static long
-extract_des (insn, dialect, invalid)
- unsigned long insn;
- int dialect ATTRIBUTE_UNUSED;
- int *invalid ATTRIBUTE_UNUSED;
+extract_des (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid ATTRIBUTE_UNUSED)
{
return (((insn >> 2) & 0x3ffc) ^ 0x2000) - 0x2000;
}
+/* FXM mask in mfcr and mtcrf instructions. */
+
+static unsigned long
+insert_fxm (unsigned long insn,
+ long value,
+ int dialect,
+ const char **errmsg)
+{
+ /* If the optional field on mfcr is missing that means we want to use
+ the old form of the instruction that moves the whole cr. In that
+ case we'll have VALUE zero. There doesn't seem to be a way to
+ distinguish this from the case where someone writes mfcr %r3,0. */
+ if (value == 0)
+ ;
+
+ /* If only one bit of the FXM field is set, we can use the new form
+ of the instruction, which is faster. Unlike the Power4 branch hint
+ encoding, this is not backward compatible. */
+ else if ((dialect & PPC_OPCODE_POWER4) != 0 && (value & -value) == value)
+ insn |= 1 << 20;
+
+ /* Any other value on mfcr is an error. */
+ else if ((insn & (0x3ff << 1)) == 19 << 1)
+ {
+ *errmsg = _("ignoring invalid mfcr mask");
+ value = 0;
+ }
+
+ return insn | ((value & 0xff) << 12);
+}
+
+static long
+extract_fxm (unsigned long insn,
+ int dialect,
+ int *invalid)
+{
+ long mask = (insn >> 12) & 0xff;
+
+ /* Is this a Power4 insn? */
+ if ((insn & (1 << 20)) != 0)
+ {
+ if ((dialect & PPC_OPCODE_POWER4) == 0)
+ *invalid = 1;
+ else
+ {
+ /* Exactly one bit of MASK should be set. */
+ if (mask == 0 || (mask & -mask) != mask)
+ *invalid = 1;
+ }
+ }
+
+ /* Check that non-power4 form of mfcr has a zero MASK. */
+ else if ((insn & (0x3ff << 1)) == 19 << 1)
+ {
+ if (mask != 0)
+ *invalid = 1;
+ }
+
+ return mask;
+}
+
/* The LI field in an I form instruction. The lower two bits are
forced to zero. */
-/*ARGSUSED*/
static unsigned long
-insert_li (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg;
+insert_li (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg)
{
- if ((value & 3) != 0 && errmsg != (const char **) NULL)
+ if ((value & 3) != 0)
*errmsg = _("ignoring least significant bits in branch offset");
return insn | (value & 0x3fffffc);
}
-/*ARGSUSED*/
static long
-extract_li (insn, dialect, invalid)
- unsigned long insn;
- int dialect ATTRIBUTE_UNUSED;
- int *invalid ATTRIBUTE_UNUSED;
+extract_li (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid ATTRIBUTE_UNUSED)
{
return ((insn & 0x3fffffc) ^ 0x2000000) - 0x2000000;
}
@@ -939,11 +1076,10 @@ extract_li (insn, dialect, invalid)
instruction which uses a field of this type. */
static unsigned long
-insert_mbe (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg;
+insert_mbe (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg)
{
unsigned long uval, mask;
int mb, me, mx, count, last;
@@ -952,8 +1088,7 @@ insert_mbe (insn, value, dialect, errmsg)
if (uval == 0)
{
- if (errmsg != (const char **) NULL)
- *errmsg = _("illegal bitmask");
+ *errmsg = _("illegal bitmask");
return insn;
}
@@ -969,7 +1104,7 @@ insert_mbe (insn, value, dialect, errmsg)
/* me: location of last 1->0 transition */
/* count: # transitions */
- for (mx = 0, mask = (long) 1 << 31; mx < 32; ++mx, mask >>= 1)
+ for (mx = 0, mask = 1L << 31; mx < 32; ++mx, mask >>= 1)
{
if ((uval & mask) && !last)
{
@@ -988,26 +1123,21 @@ insert_mbe (insn, value, dialect, errmsg)
me = 32;
if (count != 2 && (count != 0 || ! last))
- {
- if (errmsg != (const char **) NULL)
- *errmsg = _("illegal bitmask");
- }
+ *errmsg = _("illegal bitmask");
return insn | (mb << 6) | ((me - 1) << 1);
}
static long
-extract_mbe (insn, dialect, invalid)
- unsigned long insn;
- int dialect ATTRIBUTE_UNUSED;
- int *invalid;
+extract_mbe (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid)
{
long ret;
int mb, me;
int i;
- if (invalid != (int *) NULL)
- *invalid = 1;
+ *invalid = 1;
mb = (insn >> 6) & 0x1f;
me = (insn >> 1) & 0x1f;
@@ -1015,15 +1145,15 @@ extract_mbe (insn, dialect, invalid)
{
ret = 0;
for (i = mb; i <= me; i++)
- ret |= (long) 1 << (31 - i);
+ ret |= 1L << (31 - i);
}
else if (mb == me + 1)
ret = ~0;
else /* (mb > me + 1) */
{
- ret = ~ (long) 0;
+ ret = ~0;
for (i = me + 1; i < mb; i++)
- ret &= ~ ((long) 1 << (31 - i));
+ ret &= ~(1L << (31 - i));
}
return ret;
}
@@ -1031,23 +1161,19 @@ extract_mbe (insn, dialect, invalid)
/* The MB or ME field in an MD or MDS form instruction. The high bit
is wrapped to the low end. */
-/*ARGSUSED*/
static unsigned long
-insert_mb6 (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg ATTRIBUTE_UNUSED;
+insert_mb6 (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg ATTRIBUTE_UNUSED)
{
return insn | ((value & 0x1f) << 6) | (value & 0x20);
}
-/*ARGSUSED*/
static long
-extract_mb6 (insn, dialect, invalid)
- unsigned long insn;
- int dialect ATTRIBUTE_UNUSED;
- int *invalid ATTRIBUTE_UNUSED;
+extract_mb6 (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid ATTRIBUTE_UNUSED)
{
return ((insn >> 6) & 0x1f) | (insn & 0x20);
}
@@ -1056,11 +1182,10 @@ extract_mb6 (insn, dialect, invalid)
0. */
static unsigned long
-insert_nb (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg;
+insert_nb (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg)
{
if (value < 0 || value > 32)
*errmsg = _("value out of range");
@@ -1069,12 +1194,10 @@ insert_nb (insn, value, dialect, errmsg)
return insn | ((value & 0x1f) << 11);
}
-/*ARGSUSED*/
static long
-extract_nb (insn, dialect, invalid)
- unsigned long insn;
- int dialect ATTRIBUTE_UNUSED;
- int *invalid ATTRIBUTE_UNUSED;
+extract_nb (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid ATTRIBUTE_UNUSED)
{
long ret;
@@ -1089,26 +1212,22 @@ extract_nb (insn, dialect, invalid)
invalid, since we never want to recognize an instruction which uses
a field of this type. */
-/*ARGSUSED*/
static unsigned long
-insert_nsi (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg ATTRIBUTE_UNUSED;
+insert_nsi (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg ATTRIBUTE_UNUSED)
{
- return insn | ((- value) & 0xffff);
+ return insn | (-value & 0xffff);
}
static long
-extract_nsi (insn, dialect, invalid)
- unsigned long insn;
- int dialect ATTRIBUTE_UNUSED;
- int *invalid;
+extract_nsi (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid)
{
- if (invalid != (int *) NULL)
- *invalid = 1;
- return - (((insn & 0xffff) ^ 0x8000) - 0x8000);
+ *invalid = 1;
+ return -(((insn & 0xffff) ^ 0x8000) - 0x8000);
}
/* The RA field in a D or X form instruction which is an updating
@@ -1116,11 +1235,10 @@ extract_nsi (insn, dialect, invalid)
equal the RT field. */
static unsigned long
-insert_ral (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg;
+insert_ral (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg)
{
if (value == 0
|| (unsigned long) value == ((insn >> 21) & 0x1f))
@@ -1132,27 +1250,41 @@ insert_ral (insn, value, dialect, errmsg)
restrictions. */
static unsigned long
-insert_ram (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg;
+insert_ram (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg)
{
if ((unsigned long) value >= ((insn >> 21) & 0x1f))
*errmsg = _("index register in load range");
return insn | ((value & 0x1f) << 16);
}
+/* The RA field in the DQ form lq instruction, which has special
+ value restrictions. */
+
+static unsigned long
+insert_raq (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg)
+{
+ long rtvalue = (insn & RT_MASK) >> 21;
+
+ if (value == rtvalue)
+ *errmsg = _("source and target register operands must be different");
+ return insn | ((value & 0x1f) << 16);
+}
+
/* The RA field in a D or X form instruction which is an updating
store or an updating floating point load, which means that the RA
field may not be zero. */
static unsigned long
-insert_ras (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg;
+insert_ras (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg)
{
if (value == 0)
*errmsg = _("invalid register operand when updating");
@@ -1165,48 +1297,68 @@ insert_ras (insn, value, dialect, errmsg)
function just copies the BT field into the BA field, and the
extraction function just checks that the fields are the same. */
-/*ARGSUSED*/
static unsigned long
-insert_rbs (insn, value, dialect, errmsg)
- unsigned long insn;
- long value ATTRIBUTE_UNUSED;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg ATTRIBUTE_UNUSED;
+insert_rbs (unsigned long insn,
+ long value ATTRIBUTE_UNUSED,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg ATTRIBUTE_UNUSED)
{
return insn | (((insn >> 21) & 0x1f) << 11);
}
static long
-extract_rbs (insn, dialect, invalid)
- unsigned long insn;
- int dialect ATTRIBUTE_UNUSED;
- int *invalid;
+extract_rbs (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid)
{
- if (invalid != (int *) NULL
- && ((insn >> 21) & 0x1f) != ((insn >> 11) & 0x1f))
+ if (((insn >> 21) & 0x1f) != ((insn >> 11) & 0x1f))
*invalid = 1;
return 0;
}
+/* The RT field of the DQ form lq instruction, which has special
+ value restrictions. */
+
+static unsigned long
+insert_rtq (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg)
+{
+ if ((value & 1) != 0)
+ *errmsg = _("target register operand must be even");
+ return insn | ((value & 0x1f) << 21);
+}
+
+/* The RS field of the DS form stq instruction, which has special
+ value restrictions. */
+
+static unsigned long
+insert_rsq (unsigned long insn,
+ long value ATTRIBUTE_UNUSED,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg)
+{
+ if ((value & 1) != 0)
+ *errmsg = _("source register operand must be even");
+ return insn | ((value & 0x1f) << 21);
+}
+
/* The SH field in an MD form instruction. This is split. */
-/*ARGSUSED*/
static unsigned long
-insert_sh6 (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg ATTRIBUTE_UNUSED;
+insert_sh6 (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg ATTRIBUTE_UNUSED)
{
return insn | ((value & 0x1f) << 11) | ((value & 0x20) >> 4);
}
-/*ARGSUSED*/
static long
-extract_sh6 (insn, dialect, invalid)
- unsigned long insn;
- int dialect ATTRIBUTE_UNUSED;
- int *invalid ATTRIBUTE_UNUSED;
+extract_sh6 (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid ATTRIBUTE_UNUSED)
{
return ((insn >> 11) & 0x1f) | ((insn << 4) & 0x20);
}
@@ -1215,20 +1367,18 @@ extract_sh6 (insn, dialect, invalid)
lower 5 bits are stored in the upper 5 and vice- versa. */
static unsigned long
-insert_spr (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg ATTRIBUTE_UNUSED;
+insert_spr (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg ATTRIBUTE_UNUSED)
{
return insn | ((value & 0x1f) << 16) | ((value & 0x3e0) << 6);
}
static long
-extract_spr (insn, dialect, invalid)
- unsigned long insn;
- int dialect ATTRIBUTE_UNUSED;
- int *invalid ATTRIBUTE_UNUSED;
+extract_spr (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid ATTRIBUTE_UNUSED)
{
return ((insn >> 16) & 0x1f) | ((insn >> 6) & 0x3e0);
}
@@ -1244,11 +1394,10 @@ extract_spr (insn, dialect, invalid)
#define TB (268)
static unsigned long
-insert_tbr (insn, value, dialect, errmsg)
- unsigned long insn;
- long value;
- int dialect ATTRIBUTE_UNUSED;
- const char **errmsg ATTRIBUTE_UNUSED;
+insert_tbr (unsigned long insn,
+ long value,
+ int dialect ATTRIBUTE_UNUSED,
+ const char **errmsg ATTRIBUTE_UNUSED)
{
if (value == 0)
value = TB;
@@ -1256,10 +1405,9 @@ insert_tbr (insn, value, dialect, errmsg)
}
static long
-extract_tbr (insn, dialect, invalid)
- unsigned long insn;
- int dialect ATTRIBUTE_UNUSED;
- int *invalid ATTRIBUTE_UNUSED;
+extract_tbr (unsigned long insn,
+ int dialect ATTRIBUTE_UNUSED,
+ int *invalid ATTRIBUTE_UNUSED)
{
long ret;
@@ -1332,6 +1480,14 @@ extract_tbr (insn, dialect, invalid)
#define BBOYBI_MASK (BBOYCB_MASK | BI_MASK)
#define BBOATBI_MASK (BBOAT2CB_MASK | BI_MASK)
+/* An Context form instruction. */
+#define CTX(op, xop) (OP (op) | (((unsigned long)(xop)) & 0x7))
+#define CTX_MASK CTX(0x3f, 0x7)
+
+/* An User Context form instruction. */
+#define UCTX(op, xop) (OP (op) | (((unsigned long)(xop)) & 0x1f))
+#define UCTX_MASK UCTX(0x3f, 0x1f)
+
/* The main opcode mask with the RA field clear. */
#define DRA_MASK (OP_MASK | RA_MASK)
@@ -1343,6 +1499,10 @@ extract_tbr (insn, dialect, invalid)
#define DEO(op, xop) (OP (op) | ((xop) & 0xf))
#define DE_MASK DEO (0x3e, 0xf)
+/* An EVSEL form instruction. */
+#define EVSEL(op, xop) (OP (op) | (((unsigned long)(xop)) & 0xff) << 3)
+#define EVSEL_MASK EVSEL(0x3f, 0xff)
+
/* An M form instruction. */
#define M(op, rc) (OP (op) | ((rc) & 1))
#define M_MASK M (0x3f, 1)
@@ -1377,22 +1537,22 @@ extract_tbr (insn, dialect, invalid)
#define SC(op, sa, lk) (OP (op) | ((((unsigned long)(sa)) & 1) << 1) | ((lk) & 1))
#define SC_MASK (OP_MASK | (((unsigned long)0x3ff) << 16) | (((unsigned long)1) << 1) | 1)
-/* An VX form instruction. */
+/* An VX form instruction. */
#define VX(op, xop) (OP (op) | (((unsigned long)(xop)) & 0x7ff))
-/* The mask for an VX form instruction. */
+/* The mask for an VX form instruction. */
#define VX_MASK VX(0x3f, 0x7ff)
-/* An VA form instruction. */
+/* An VA form instruction. */
#define VXA(op, xop) (OP (op) | (((unsigned long)(xop)) & 0x03f))
-/* The mask for an VA form instruction. */
+/* The mask for an VA form instruction. */
#define VXA_MASK VXA(0x3f, 0x3f)
-/* An VXR form instruction. */
+/* An VXR form instruction. */
#define VXR(op, xop, rc) (OP (op) | (((rc) & 1) << 10) | (((unsigned long)(xop)) & 0x3ff))
-/* The mask for a VXR form instruction. */
+/* The mask for a VXR form instruction. */
#define VXR_MASK VXR(0x3f, 0x3ff, 1)
/* An X form instruction. */
@@ -1416,7 +1576,7 @@ extract_tbr (insn, dialect, invalid)
/* An X_MASK with the RA and RB fields fixed. */
#define XRARB_MASK (X_MASK | RA_MASK | RB_MASK)
-/* An XRARB_MASK, but with the L bit clear. */
+/* An XRARB_MASK, but with the L bit clear. */
#define XRLARB_MASK (XRARB_MASK & ~((unsigned long) 1 << 16))
/* An X_MASK with the RT and RA fields fixed. */
@@ -1457,6 +1617,10 @@ extract_tbr (insn, dialect, invalid)
#define XFL(op, xop, rc) (OP (op) | ((((unsigned long)(xop)) & 0x3ff) << 1) | (((unsigned long)(rc)) & 1))
#define XFL_MASK (XFL (0x3f, 0x3ff, 1) | (((unsigned long)1) << 25) | (((unsigned long)1) << 16))
+/* An X form isel instruction. */
+#define XISEL(op, xop) (OP (op) | ((((unsigned long)(xop)) & 0x1f) << 1))
+#define XISEL_MASK XISEL(0x3f, 0x1f)
+
/* An XL form instruction with the LK field set to 0. */
#define XL(op, xop) (OP (op) | ((((unsigned long)(xop)) & 0x3ff) << 1))
@@ -1506,7 +1670,7 @@ extract_tbr (insn, dialect, invalid)
#define XS_MASK XS (0x3f, 0x1ff, 1)
/* A mask for the FXM version of an XFX form instruction. */
-#define XFXFXM_MASK (X_MASK | (((unsigned long)1) << 20) | (((unsigned long)1) << 11))
+#define XFXFXM_MASK (X_MASK | (1 << 11))
/* An XFX form instruction with the FXM field filled in. */
#define XFXM(op, xop, fxm) \
@@ -1528,6 +1692,10 @@ extract_tbr (insn, dialect, invalid)
/* An X form instruction with everything filled in except the E field. */
#define XE_MASK (0xffff7fff)
+/* An X form user context instruction. */
+#define XUC(op, xop) (OP (op) | (((unsigned long)(xop)) & 0x1f))
+#define XUC_MASK XUC(0x3f, 0x1f)
+
/* The BO encodings used in extended conditional branch mnemonics. */
#define BODNZF (0x0)
#define BODNZFP (0x1)
@@ -1585,30 +1753,39 @@ extract_tbr (insn, dialect, invalid)
/* Smaller names for the flags so each entry in the opcodes table will
fit on a single line. */
#undef PPC
-#define PPC PPC_OPCODE_PPC | PPC_OPCODE_ANY
-#define PPCCOM PPC_OPCODE_PPC | PPC_OPCODE_COMMON | PPC_OPCODE_ANY
+#define PPC PPC_OPCODE_PPC
+#define PPCCOM PPC_OPCODE_PPC | PPC_OPCODE_COMMON
#define NOPOWER4 PPC_OPCODE_NOPOWER4 | PPCCOM
-#define POWER4 PPC_OPCODE_POWER4 | PPCCOM
-#define PPC32 PPC_OPCODE_32 | PPC_OPCODE_PPC | PPC_OPCODE_ANY
-#define PPC64 PPC_OPCODE_64 | PPC_OPCODE_PPC | PPC_OPCODE_ANY
-#define PPCONLY PPC_OPCODE_PPC
+#define POWER4 PPC_OPCODE_POWER4
+#define PPC32 PPC_OPCODE_32 | PPC_OPCODE_PPC
+#define PPC64 PPC_OPCODE_64 | PPC_OPCODE_PPC
#define PPC403 PPC_OPCODE_403
#define PPC405 PPC403
+#define PPC440 PPC_OPCODE_440
#define PPC750 PPC
#define PPC860 PPC
-#define PPCVEC PPC_OPCODE_ALTIVEC | PPC_OPCODE_ANY | PPC_OPCODE_PPC
-#define POWER PPC_OPCODE_POWER | PPC_OPCODE_ANY
-#define POWER2 PPC_OPCODE_POWER | PPC_OPCODE_POWER2 | PPC_OPCODE_ANY
-#define PPCPWR2 PPC_OPCODE_PPC | PPC_OPCODE_POWER | PPC_OPCODE_POWER2 | PPC_OPCODE_ANY
-#define POWER32 PPC_OPCODE_POWER | PPC_OPCODE_ANY | PPC_OPCODE_32
-#define COM PPC_OPCODE_POWER | PPC_OPCODE_PPC | PPC_OPCODE_COMMON | PPC_OPCODE_ANY
-#define COM32 PPC_OPCODE_POWER | PPC_OPCODE_PPC | PPC_OPCODE_COMMON | PPC_OPCODE_ANY | PPC_OPCODE_32
-#define M601 PPC_OPCODE_POWER | PPC_OPCODE_601 | PPC_OPCODE_ANY
-#define PWRCOM PPC_OPCODE_POWER | PPC_OPCODE_601 | PPC_OPCODE_COMMON | PPC_OPCODE_ANY
+#define PPCVEC PPC_OPCODE_ALTIVEC
+#define POWER PPC_OPCODE_POWER
+#define POWER2 PPC_OPCODE_POWER | PPC_OPCODE_POWER2
+#define PPCPWR2 PPC_OPCODE_PPC | PPC_OPCODE_POWER | PPC_OPCODE_POWER2
+#define POWER32 PPC_OPCODE_POWER | PPC_OPCODE_32
+#define COM PPC_OPCODE_POWER | PPC_OPCODE_PPC | PPC_OPCODE_COMMON
+#define COM32 PPC_OPCODE_POWER | PPC_OPCODE_PPC | PPC_OPCODE_COMMON | PPC_OPCODE_32
+#define M601 PPC_OPCODE_POWER | PPC_OPCODE_601
+#define PWRCOM PPC_OPCODE_POWER | PPC_OPCODE_601 | PPC_OPCODE_COMMON
#define MFDEC1 PPC_OPCODE_POWER
-#define MFDEC2 PPC_OPCODE_PPC | PPC_OPCODE_601
+#define MFDEC2 PPC_OPCODE_PPC | PPC_OPCODE_601 | PPC_OPCODE_BOOKE
#define BOOKE PPC_OPCODE_BOOKE
#define BOOKE64 PPC_OPCODE_BOOKE64
+#define CLASSIC PPC_OPCODE_CLASSIC
+#define PPCSPE PPC_OPCODE_SPE
+#define PPCISEL PPC_OPCODE_ISEL
+#define PPCEFS PPC_OPCODE_EFS
+#define PPCBRLK PPC_OPCODE_BRLOCK
+#define PPCPMR PPC_OPCODE_PMR
+#define PPCCHLK PPC_OPCODE_CACHELCK
+#define PPCCHLK64 PPC_OPCODE_CACHELCK | PPC_OPCODE_BOOKE64
+#define PPCRFMCI PPC_OPCODE_RFMCI
/* The opcode table.
@@ -1629,6 +1806,7 @@ extract_tbr (insn, dialect, invalid)
sorted by major opcode. */
const struct powerpc_opcode powerpc_opcodes[] = {
+{ "attn", X(0,256), X_MASK, POWER4, { 0 } },
{ "tdlgti", OPTO(2,TOLGT), OPTO_MASK, PPC64, { RA, SI } },
{ "tdllti", OPTO(2,TOLLT), OPTO_MASK, PPC64, { RA, SI } },
{ "tdeqi", OPTO(2,TOEQ), OPTO_MASK, PPC64, { RA, SI } },
@@ -1676,90 +1854,90 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "twi", OP(3), OP_MASK, PPCCOM, { TO, RA, SI } },
{ "ti", OP(3), OP_MASK, PWRCOM, { TO, RA, SI } },
-{ "macchw", XO(4,172,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "macchw.", XO(4,172,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "macchwo", XO(4,172,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "macchwo.", XO(4,172,1,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "macchws", XO(4,236,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "macchws.", XO(4,236,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "macchwso", XO(4,236,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "macchwso.", XO(4,236,1,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "macchwsu", XO(4,204,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "macchwsu.", XO(4,204,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "macchwsuo", XO(4,204,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "macchwsuo.", XO(4,204,1,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "macchwu", XO(4,140,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "macchwu.", XO(4,140,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "macchwuo", XO(4,140,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "macchwuo.", XO(4,140,1,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "machhw", XO(4,44,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "machhw.", XO(4,44,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "machhwo", XO(4,44,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "machhwo.", XO(4,44,1,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "machhws", XO(4,108,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "machhws.", XO(4,108,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "machhwso", XO(4,108,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "machhwso.", XO(4,108,1,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "machhwsu", XO(4,76,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "machhwsu.", XO(4,76,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "machhwsuo", XO(4,76,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "machhwsuo.", XO(4,76,1,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "machhwu", XO(4,12,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "machhwu.", XO(4,12,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "machhwuo", XO(4,12,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "machhwuo.", XO(4,12,1,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "maclhw", XO(4,428,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "maclhw.", XO(4,428,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "maclhwo", XO(4,428,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "maclhwo.", XO(4,428,1,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "maclhws", XO(4,492,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "maclhws.", XO(4,492,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "maclhwso", XO(4,492,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "maclhwso.", XO(4,492,1,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "maclhwsu", XO(4,460,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "maclhwsu.", XO(4,460,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "maclhwsuo", XO(4,460,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "maclhwsuo.", XO(4,460,1,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "maclhwu", XO(4,396,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "maclhwu.", XO(4,396,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "maclhwuo", XO(4,396,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "maclhwuo.", XO(4,396,1,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "mulchw", XRC(4,168,0), X_MASK, PPC405, { RT, RA, RB } },
-{ "mulchw.", XRC(4,168,1), X_MASK, PPC405, { RT, RA, RB } },
-{ "mulchwu", XRC(4,136,0), X_MASK, PPC405, { RT, RA, RB } },
-{ "mulchwu.", XRC(4,136,1), X_MASK, PPC405, { RT, RA, RB } },
-{ "mulhhw", XRC(4,40,0), X_MASK, PPC405, { RT, RA, RB } },
-{ "mulhhw.", XRC(4,40,1), X_MASK, PPC405, { RT, RA, RB } },
-{ "mulhhwu", XRC(4,8,0), X_MASK, PPC405, { RT, RA, RB } },
-{ "mulhhwu.", XRC(4,8,1), X_MASK, PPC405, { RT, RA, RB } },
-{ "mullhw", XRC(4,424,0), X_MASK, PPC405, { RT, RA, RB } },
-{ "mullhw.", XRC(4,424,1), X_MASK, PPC405, { RT, RA, RB } },
-{ "mullhwu", XRC(4,392,0), X_MASK, PPC405, { RT, RA, RB } },
-{ "mullhwu.", XRC(4,392,1), X_MASK, PPC405, { RT, RA, RB } },
-{ "nmacchw", XO(4,174,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmacchw.", XO(4,174,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmacchwo", XO(4,174,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmacchwo.", XO(4,174,1,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmacchws", XO(4,238,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmacchws.", XO(4,238,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmacchwso", XO(4,238,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmacchwso.", XO(4,238,1,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmachhw", XO(4,46,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmachhw.", XO(4,46,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmachhwo", XO(4,46,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmachhwo.", XO(4,46,1,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmachhws", XO(4,110,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmachhws.", XO(4,110,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmachhwso", XO(4,110,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmachhwso.", XO(4,110,1,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmaclhw", XO(4,430,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmaclhw.", XO(4,430,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmaclhwo", XO(4,430,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmaclhwo.", XO(4,430,1,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmaclhws", XO(4,494,0,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmaclhws.", XO(4,494,0,1), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmaclhwso", XO(4,494,1,0), XO_MASK, PPC405, { RT, RA, RB } },
-{ "nmaclhwso.", XO(4,494,1,1), XO_MASK, PPC405, { RT, RA, RB } },
+{ "macchw", XO(4,172,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "macchw.", XO(4,172,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "macchwo", XO(4,172,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "macchwo.", XO(4,172,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "macchws", XO(4,236,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "macchws.", XO(4,236,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "macchwso", XO(4,236,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "macchwso.", XO(4,236,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "macchwsu", XO(4,204,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "macchwsu.", XO(4,204,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "macchwsuo", XO(4,204,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "macchwsuo.", XO(4,204,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "macchwu", XO(4,140,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "macchwu.", XO(4,140,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "macchwuo", XO(4,140,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "macchwuo.", XO(4,140,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "machhw", XO(4,44,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "machhw.", XO(4,44,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "machhwo", XO(4,44,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "machhwo.", XO(4,44,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "machhws", XO(4,108,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "machhws.", XO(4,108,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "machhwso", XO(4,108,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "machhwso.", XO(4,108,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "machhwsu", XO(4,76,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "machhwsu.", XO(4,76,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "machhwsuo", XO(4,76,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "machhwsuo.", XO(4,76,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "machhwu", XO(4,12,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "machhwu.", XO(4,12,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "machhwuo", XO(4,12,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "machhwuo.", XO(4,12,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "maclhw", XO(4,428,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "maclhw.", XO(4,428,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "maclhwo", XO(4,428,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "maclhwo.", XO(4,428,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "maclhws", XO(4,492,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "maclhws.", XO(4,492,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "maclhwso", XO(4,492,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "maclhwso.", XO(4,492,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "maclhwsu", XO(4,460,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "maclhwsu.", XO(4,460,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "maclhwsuo", XO(4,460,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "maclhwsuo.", XO(4,460,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "maclhwu", XO(4,396,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "maclhwu.", XO(4,396,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "maclhwuo", XO(4,396,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "maclhwuo.", XO(4,396,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "mulchw", XRC(4,168,0), X_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "mulchw.", XRC(4,168,1), X_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "mulchwu", XRC(4,136,0), X_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "mulchwu.", XRC(4,136,1), X_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "mulhhw", XRC(4,40,0), X_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "mulhhw.", XRC(4,40,1), X_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "mulhhwu", XRC(4,8,0), X_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "mulhhwu.", XRC(4,8,1), X_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "mullhw", XRC(4,424,0), X_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "mullhw.", XRC(4,424,1), X_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "mullhwu", XRC(4,392,0), X_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "mullhwu.", XRC(4,392,1), X_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmacchw", XO(4,174,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmacchw.", XO(4,174,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmacchwo", XO(4,174,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmacchwo.", XO(4,174,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmacchws", XO(4,238,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmacchws.", XO(4,238,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmacchwso", XO(4,238,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmacchwso.", XO(4,238,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmachhw", XO(4,46,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmachhw.", XO(4,46,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmachhwo", XO(4,46,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmachhwo.", XO(4,46,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmachhws", XO(4,110,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmachhws.", XO(4,110,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmachhwso", XO(4,110,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmachhwso.", XO(4,110,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmaclhw", XO(4,430,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmaclhw.", XO(4,430,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmaclhwo", XO(4,430,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmaclhwo.", XO(4,430,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmaclhws", XO(4,494,0,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmaclhws.", XO(4,494,0,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmaclhwso", XO(4,494,1,0), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
+{ "nmaclhwso.", XO(4,494,1,1), XO_MASK, PPC405|PPC440, { RT, RA, RB } },
{ "mfvscr", VX(4, 1540), VX_MASK, PPCVEC, { VD } },
{ "mtvscr", VX(4, 1604), VX_MASK, PPCVEC, { VB } },
{ "vaddcuw", VX(4, 384), VX_MASK, PPCVEC, { VD, VA, VB } },
@@ -1918,6 +2096,254 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "vupklsh", VX(4, 718), VX_MASK, PPCVEC, { VD, VB } },
{ "vxor", VX(4, 1220), VX_MASK, PPCVEC, { VD, VA, VB } },
+{ "evaddw", VX(4, 512), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evaddiw", VX(4, 514), VX_MASK, PPCSPE, { RS, RB, UIMM } },
+{ "evsubfw", VX(4, 516), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evsubw", VX(4, 516), VX_MASK, PPCSPE, { RS, RB, RA } },
+{ "evsubifw", VX(4, 518), VX_MASK, PPCSPE, { RS, UIMM, RB } },
+{ "evsubiw", VX(4, 518), VX_MASK, PPCSPE, { RS, RB, UIMM } },
+{ "evabs", VX(4, 520), VX_MASK, PPCSPE, { RS, RA } },
+{ "evneg", VX(4, 521), VX_MASK, PPCSPE, { RS, RA } },
+{ "evextsb", VX(4, 522), VX_MASK, PPCSPE, { RS, RA } },
+{ "evextsh", VX(4, 523), VX_MASK, PPCSPE, { RS, RA } },
+{ "evrndw", VX(4, 524), VX_MASK, PPCSPE, { RS, RA } },
+{ "evcntlzw", VX(4, 525), VX_MASK, PPCSPE, { RS, RA } },
+{ "evcntlsw", VX(4, 526), VX_MASK, PPCSPE, { RS, RA } },
+
+{ "brinc", VX(4, 527), VX_MASK, PPCSPE, { RS, RA, RB } },
+
+{ "evand", VX(4, 529), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evandc", VX(4, 530), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmr", VX(4, 535), VX_MASK, PPCSPE, { RS, RA, BBA } },
+{ "evor", VX(4, 535), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evorc", VX(4, 539), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evxor", VX(4, 534), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "eveqv", VX(4, 537), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evnand", VX(4, 542), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evnot", VX(4, 536), VX_MASK, PPCSPE, { RS, RA, BBA } },
+{ "evnor", VX(4, 536), VX_MASK, PPCSPE, { RS, RA, RB } },
+
+{ "evrlw", VX(4, 552), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evrlwi", VX(4, 554), VX_MASK, PPCSPE, { RS, RA, EVUIMM } },
+{ "evslw", VX(4, 548), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evslwi", VX(4, 550), VX_MASK, PPCSPE, { RS, RA, EVUIMM } },
+{ "evsrws", VX(4, 545), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evsrwu", VX(4, 544), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evsrwis", VX(4, 547), VX_MASK, PPCSPE, { RS, RA, EVUIMM } },
+{ "evsrwiu", VX(4, 546), VX_MASK, PPCSPE, { RS, RA, EVUIMM } },
+{ "evsplati", VX(4, 553), VX_MASK, PPCSPE, { RS, SIMM } },
+{ "evsplatfi", VX(4, 555), VX_MASK, PPCSPE, { RS, SIMM } },
+{ "evmergehi", VX(4, 556), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmergelo", VX(4, 557), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmergehilo",VX(4,558), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmergelohi",VX(4,559), VX_MASK, PPCSPE, { RS, RA, RB } },
+
+{ "evcmpgts", VX(4, 561), VX_MASK, PPCSPE, { CRFD, RA, RB } },
+{ "evcmpgtu", VX(4, 560), VX_MASK, PPCSPE, { CRFD, RA, RB } },
+{ "evcmplts", VX(4, 563), VX_MASK, PPCSPE, { CRFD, RA, RB } },
+{ "evcmpltu", VX(4, 562), VX_MASK, PPCSPE, { CRFD, RA, RB } },
+{ "evcmpeq", VX(4, 564), VX_MASK, PPCSPE, { CRFD, RA, RB } },
+{ "evsel", EVSEL(4,79),EVSEL_MASK, PPCSPE, { RS, RA, RB, CRFS } },
+
+{ "evldd", VX(4, 769), VX_MASK, PPCSPE, { RS, EVUIMM_8, RA } },
+{ "evlddx", VX(4, 768), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evldw", VX(4, 771), VX_MASK, PPCSPE, { RS, EVUIMM_8, RA } },
+{ "evldwx", VX(4, 770), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evldh", VX(4, 773), VX_MASK, PPCSPE, { RS, EVUIMM_8, RA } },
+{ "evldhx", VX(4, 772), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evlwhe", VX(4, 785), VX_MASK, PPCSPE, { RS, EVUIMM_4, RA } },
+{ "evlwhex", VX(4, 784), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evlwhou", VX(4, 789), VX_MASK, PPCSPE, { RS, EVUIMM_4, RA } },
+{ "evlwhoux", VX(4, 788), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evlwhos", VX(4, 791), VX_MASK, PPCSPE, { RS, EVUIMM_4, RA } },
+{ "evlwhosx", VX(4, 790), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evlwwsplat",VX(4, 793), VX_MASK, PPCSPE, { RS, EVUIMM_4, RA } },
+{ "evlwwsplatx",VX(4, 792), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evlwhsplat",VX(4, 797), VX_MASK, PPCSPE, { RS, EVUIMM_4, RA } },
+{ "evlwhsplatx",VX(4, 796), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evlhhesplat",VX(4, 777), VX_MASK, PPCSPE, { RS, EVUIMM_2, RA } },
+{ "evlhhesplatx",VX(4, 776), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evlhhousplat",VX(4, 781), VX_MASK, PPCSPE, { RS, EVUIMM_2, RA } },
+{ "evlhhousplatx",VX(4, 780), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evlhhossplat",VX(4, 783), VX_MASK, PPCSPE, { RS, EVUIMM_2, RA } },
+{ "evlhhossplatx",VX(4, 782), VX_MASK, PPCSPE, { RS, RA, RB } },
+
+{ "evstdd", VX(4, 801), VX_MASK, PPCSPE, { RS, EVUIMM_8, RA } },
+{ "evstddx", VX(4, 800), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evstdw", VX(4, 803), VX_MASK, PPCSPE, { RS, EVUIMM_8, RA } },
+{ "evstdwx", VX(4, 802), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evstdh", VX(4, 805), VX_MASK, PPCSPE, { RS, EVUIMM_8, RA } },
+{ "evstdhx", VX(4, 804), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evstwwe", VX(4, 825), VX_MASK, PPCSPE, { RS, EVUIMM_4, RA } },
+{ "evstwwex", VX(4, 824), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evstwwo", VX(4, 829), VX_MASK, PPCSPE, { RS, EVUIMM_4, RA } },
+{ "evstwwox", VX(4, 828), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evstwhe", VX(4, 817), VX_MASK, PPCSPE, { RS, EVUIMM_4, RA } },
+{ "evstwhex", VX(4, 816), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evstwho", VX(4, 821), VX_MASK, PPCSPE, { RS, EVUIMM_4, RA } },
+{ "evstwhox", VX(4, 820), VX_MASK, PPCSPE, { RS, RA, RB } },
+
+{ "evfsabs", VX(4, 644), VX_MASK, PPCSPE, { RS, RA } },
+{ "evfsnabs", VX(4, 645), VX_MASK, PPCSPE, { RS, RA } },
+{ "evfsneg", VX(4, 646), VX_MASK, PPCSPE, { RS, RA } },
+{ "evfsadd", VX(4, 640), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evfssub", VX(4, 641), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evfsmul", VX(4, 648), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evfsdiv", VX(4, 649), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evfscmpgt", VX(4, 652), VX_MASK, PPCSPE, { CRFD, RA, RB } },
+{ "evfscmplt", VX(4, 653), VX_MASK, PPCSPE, { CRFD, RA, RB } },
+{ "evfscmpeq", VX(4, 654), VX_MASK, PPCSPE, { CRFD, RA, RB } },
+{ "evfststgt", VX(4, 668), VX_MASK, PPCSPE, { CRFD, RA, RB } },
+{ "evfststlt", VX(4, 669), VX_MASK, PPCSPE, { CRFD, RA, RB } },
+{ "evfststeq", VX(4, 670), VX_MASK, PPCSPE, { CRFD, RA, RB } },
+{ "evfscfui", VX(4, 656), VX_MASK, PPCSPE, { RS, RB } },
+{ "evfsctuiz", VX(4, 664), VX_MASK, PPCSPE, { RS, RB } },
+{ "evfscfsi", VX(4, 657), VX_MASK, PPCSPE, { RS, RB } },
+{ "evfscfuf", VX(4, 658), VX_MASK, PPCSPE, { RS, RB } },
+{ "evfscfsf", VX(4, 659), VX_MASK, PPCSPE, { RS, RB } },
+{ "evfsctui", VX(4, 660), VX_MASK, PPCSPE, { RS, RB } },
+{ "evfsctsi", VX(4, 661), VX_MASK, PPCSPE, { RS, RB } },
+{ "evfsctsiz", VX(4, 666), VX_MASK, PPCSPE, { RS, RB } },
+{ "evfsctuf", VX(4, 662), VX_MASK, PPCSPE, { RS, RB } },
+{ "evfsctsf", VX(4, 663), VX_MASK, PPCSPE, { RS, RB } },
+
+{ "efsabs", VX(4, 708), VX_MASK, PPCEFS, { RS, RA } },
+{ "efsnabs", VX(4, 709), VX_MASK, PPCEFS, { RS, RA } },
+{ "efsneg", VX(4, 710), VX_MASK, PPCEFS, { RS, RA } },
+{ "efsadd", VX(4, 704), VX_MASK, PPCEFS, { RS, RA, RB } },
+{ "efssub", VX(4, 705), VX_MASK, PPCEFS, { RS, RA, RB } },
+{ "efsmul", VX(4, 712), VX_MASK, PPCEFS, { RS, RA, RB } },
+{ "efsdiv", VX(4, 713), VX_MASK, PPCEFS, { RS, RA, RB } },
+{ "efscmpgt", VX(4, 716), VX_MASK, PPCEFS, { CRFD, RA, RB } },
+{ "efscmplt", VX(4, 717), VX_MASK, PPCEFS, { CRFD, RA, RB } },
+{ "efscmpeq", VX(4, 718), VX_MASK, PPCEFS, { CRFD, RA, RB } },
+{ "efststgt", VX(4, 732), VX_MASK, PPCEFS, { CRFD, RA, RB } },
+{ "efststlt", VX(4, 733), VX_MASK, PPCEFS, { CRFD, RA, RB } },
+{ "efststeq", VX(4, 734), VX_MASK, PPCEFS, { CRFD, RA, RB } },
+{ "efscfui", VX(4, 720), VX_MASK, PPCEFS, { RS, RB } },
+{ "efsctuiz", VX(4, 728), VX_MASK, PPCEFS, { RS, RB } },
+{ "efscfsi", VX(4, 721), VX_MASK, PPCEFS, { RS, RB } },
+{ "efscfuf", VX(4, 722), VX_MASK, PPCEFS, { RS, RB } },
+{ "efscfsf", VX(4, 723), VX_MASK, PPCEFS, { RS, RB } },
+{ "efsctui", VX(4, 724), VX_MASK, PPCEFS, { RS, RB } },
+{ "efsctsi", VX(4, 725), VX_MASK, PPCEFS, { RS, RB } },
+{ "efsctsiz", VX(4, 730), VX_MASK, PPCEFS, { RS, RB } },
+{ "efsctuf", VX(4, 726), VX_MASK, PPCEFS, { RS, RB } },
+{ "efsctsf", VX(4, 727), VX_MASK, PPCEFS, { RS, RB } },
+
+{ "evmhossf", VX(4, 1031), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhossfa", VX(4, 1063), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhosmf", VX(4, 1039), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhosmfa", VX(4, 1071), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhosmi", VX(4, 1037), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhosmia", VX(4, 1069), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhoumi", VX(4, 1036), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhoumia", VX(4, 1068), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhessf", VX(4, 1027), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhessfa", VX(4, 1059), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhesmf", VX(4, 1035), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhesmfa", VX(4, 1067), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhesmi", VX(4, 1033), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhesmia", VX(4, 1065), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmheumi", VX(4, 1032), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmheumia", VX(4, 1064), VX_MASK, PPCSPE, { RS, RA, RB } },
+
+{ "evmhossfaaw",VX(4, 1287), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhossiaaw",VX(4, 1285), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhosmfaaw",VX(4, 1295), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhosmiaaw",VX(4, 1293), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhousiaaw",VX(4, 1284), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhoumiaaw",VX(4, 1292), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhessfaaw",VX(4, 1283), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhessiaaw",VX(4, 1281), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhesmfaaw",VX(4, 1291), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhesmiaaw",VX(4, 1289), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmheusiaaw",VX(4, 1280), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmheumiaaw",VX(4, 1288), VX_MASK, PPCSPE, { RS, RA, RB } },
+
+{ "evmhossfanw",VX(4, 1415), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhossianw",VX(4, 1413), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhosmfanw",VX(4, 1423), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhosmianw",VX(4, 1421), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhousianw",VX(4, 1412), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhoumianw",VX(4, 1420), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhessfanw",VX(4, 1411), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhessianw",VX(4, 1409), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhesmfanw",VX(4, 1419), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhesmianw",VX(4, 1417), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmheusianw",VX(4, 1408), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmheumianw",VX(4, 1416), VX_MASK, PPCSPE, { RS, RA, RB } },
+
+{ "evmhogsmfaa",VX(4, 1327), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhogsmiaa",VX(4, 1325), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhogumiaa",VX(4, 1324), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhegsmfaa",VX(4, 1323), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhegsmiaa",VX(4, 1321), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhegumiaa",VX(4, 1320), VX_MASK, PPCSPE, { RS, RA, RB } },
+
+{ "evmhogsmfan",VX(4, 1455), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhogsmian",VX(4, 1453), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhogumian",VX(4, 1452), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhegsmfan",VX(4, 1451), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhegsmian",VX(4, 1449), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmhegumian",VX(4, 1448), VX_MASK, PPCSPE, { RS, RA, RB } },
+
+{ "evmwhssf", VX(4, 1095), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwhssfa", VX(4, 1127), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwhsmf", VX(4, 1103), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwhsmfa", VX(4, 1135), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwhsmi", VX(4, 1101), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwhsmia", VX(4, 1133), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwhumi", VX(4, 1100), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwhumia", VX(4, 1132), VX_MASK, PPCSPE, { RS, RA, RB } },
+
+{ "evmwlumi", VX(4, 1096), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwlumia", VX(4, 1128), VX_MASK, PPCSPE, { RS, RA, RB } },
+
+{ "evmwlssiaaw",VX(4, 1345), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwlsmiaaw",VX(4, 1353), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwlusiaaw",VX(4, 1344), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwlumiaaw",VX(4, 1352), VX_MASK, PPCSPE, { RS, RA, RB } },
+
+{ "evmwlssianw",VX(4, 1473), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwlsmianw",VX(4, 1481), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwlusianw",VX(4, 1472), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwlumianw",VX(4, 1480), VX_MASK, PPCSPE, { RS, RA, RB } },
+
+{ "evmwssf", VX(4, 1107), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwssfa", VX(4, 1139), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwsmf", VX(4, 1115), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwsmfa", VX(4, 1147), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwsmi", VX(4, 1113), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwsmia", VX(4, 1145), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwumi", VX(4, 1112), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwumia", VX(4, 1144), VX_MASK, PPCSPE, { RS, RA, RB } },
+
+{ "evmwssfaa", VX(4, 1363), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwsmfaa", VX(4, 1371), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwsmiaa", VX(4, 1369), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwumiaa", VX(4, 1368), VX_MASK, PPCSPE, { RS, RA, RB } },
+
+{ "evmwssfan", VX(4, 1491), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwsmfan", VX(4, 1499), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwsmian", VX(4, 1497), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evmwumian", VX(4, 1496), VX_MASK, PPCSPE, { RS, RA, RB } },
+
+{ "evaddssiaaw",VX(4, 1217), VX_MASK, PPCSPE, { RS, RA } },
+{ "evaddsmiaaw",VX(4, 1225), VX_MASK, PPCSPE, { RS, RA } },
+{ "evaddusiaaw",VX(4, 1216), VX_MASK, PPCSPE, { RS, RA } },
+{ "evaddumiaaw",VX(4, 1224), VX_MASK, PPCSPE, { RS, RA } },
+
+{ "evsubfssiaaw",VX(4, 1219), VX_MASK, PPCSPE, { RS, RA } },
+{ "evsubfsmiaaw",VX(4, 1227), VX_MASK, PPCSPE, { RS, RA } },
+{ "evsubfusiaaw",VX(4, 1218), VX_MASK, PPCSPE, { RS, RA } },
+{ "evsubfumiaaw",VX(4, 1226), VX_MASK, PPCSPE, { RS, RA } },
+
+{ "evmra", VX(4, 1220), VX_MASK, PPCSPE, { RS, RA } },
+
+{ "evdivws", VX(4, 1222), VX_MASK, PPCSPE, { RS, RA, RB } },
+{ "evdivwu", VX(4, 1223), VX_MASK, PPCSPE, { RS, RA, RB } },
+
{ "mulli", OP(7), OP_MASK, PPCCOM, { RT, RA, SI } },
{ "muli", OP(7), OP_MASK, PWRCOM, { RT, RA, SI } },
@@ -1933,12 +2359,12 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "cmplwi", OPL(10,0), OPL_MASK, PPCCOM, { OBF, RA, UI } },
{ "cmpldi", OPL(10,1), OPL_MASK, PPC64, { OBF, RA, UI } },
-{ "cmpli", OP(10), OP_MASK, PPCONLY, { BF, L, RA, UI } },
+{ "cmpli", OP(10), OP_MASK, PPC, { BF, L, RA, UI } },
{ "cmpli", OP(10), OP_MASK, PWRCOM, { BF, RA, UI } },
{ "cmpwi", OPL(11,0), OPL_MASK, PPCCOM, { OBF, RA, SI } },
{ "cmpdi", OPL(11,1), OPL_MASK, PPC64, { OBF, RA, SI } },
-{ "cmpi", OP(11), OP_MASK, PPCONLY, { BF, L, RA, SI } },
+{ "cmpi", OP(11), OP_MASK, PPC, { BF, L, RA, SI } },
{ "cmpi", OP(11), OP_MASK, PWRCOM, { BF, RA, SI } },
{ "addic", OP(12), OP_MASK, PPCCOM, { RT, RA, SI } },
@@ -1951,45 +2377,45 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "li", OP(14), DRA_MASK, PPCCOM, { RT, SI } },
{ "lil", OP(14), DRA_MASK, PWRCOM, { RT, SI } },
-{ "addi", OP(14), OP_MASK, PPCCOM, { RT, RA, SI } },
-{ "cal", OP(14), OP_MASK, PWRCOM, { RT, D, RA } },
-{ "subi", OP(14), OP_MASK, PPCCOM, { RT, RA, NSI } },
-{ "la", OP(14), OP_MASK, PPCCOM, { RT, D, RA } },
+{ "addi", OP(14), OP_MASK, PPCCOM, { RT, RA0, SI } },
+{ "cal", OP(14), OP_MASK, PWRCOM, { RT, D, RA0 } },
+{ "subi", OP(14), OP_MASK, PPCCOM, { RT, RA0, NSI } },
+{ "la", OP(14), OP_MASK, PPCCOM, { RT, D, RA0 } },
{ "lis", OP(15), DRA_MASK, PPCCOM, { RT, SISIGNOPT } },
{ "liu", OP(15), DRA_MASK, PWRCOM, { RT, SISIGNOPT } },
-{ "addis", OP(15), OP_MASK, PPCCOM, { RT,RA,SISIGNOPT } },
-{ "cau", OP(15), OP_MASK, PWRCOM, { RT,RA,SISIGNOPT } },
-{ "subis", OP(15), OP_MASK, PPCCOM, { RT, RA, NSI } },
-
-{ "bdnz-", BBO(16,BODNZ,0,0), BBOATBI_MASK, PPCCOM, { BDM } },
-{ "bdnz+", BBO(16,BODNZ,0,0), BBOATBI_MASK, PPCCOM, { BDP } },
-{ "bdnz", BBO(16,BODNZ,0,0), BBOATBI_MASK, PPCCOM, { BD } },
-{ "bdn", BBO(16,BODNZ,0,0), BBOATBI_MASK, PWRCOM, { BD } },
-{ "bdnzl-", BBO(16,BODNZ,0,1), BBOATBI_MASK, PPCCOM, { BDM } },
-{ "bdnzl+", BBO(16,BODNZ,0,1), BBOATBI_MASK, PPCCOM, { BDP } },
-{ "bdnzl", BBO(16,BODNZ,0,1), BBOATBI_MASK, PPCCOM, { BD } },
-{ "bdnl", BBO(16,BODNZ,0,1), BBOATBI_MASK, PWRCOM, { BD } },
-{ "bdnza-", BBO(16,BODNZ,1,0), BBOATBI_MASK, PPCCOM, { BDMA } },
-{ "bdnza+", BBO(16,BODNZ,1,0), BBOATBI_MASK, PPCCOM, { BDPA } },
-{ "bdnza", BBO(16,BODNZ,1,0), BBOATBI_MASK, PPCCOM, { BDA } },
-{ "bdna", BBO(16,BODNZ,1,0), BBOATBI_MASK, PWRCOM, { BDA } },
-{ "bdnzla-", BBO(16,BODNZ,1,1), BBOATBI_MASK, PPCCOM, { BDMA } },
-{ "bdnzla+", BBO(16,BODNZ,1,1), BBOATBI_MASK, PPCCOM, { BDPA } },
-{ "bdnzla", BBO(16,BODNZ,1,1), BBOATBI_MASK, PPCCOM, { BDA } },
-{ "bdnla", BBO(16,BODNZ,1,1), BBOATBI_MASK, PWRCOM, { BDA } },
-{ "bdz-", BBO(16,BODZ,0,0), BBOATBI_MASK, PPCCOM, { BDM } },
-{ "bdz+", BBO(16,BODZ,0,0), BBOATBI_MASK, PPCCOM, { BDP } },
-{ "bdz", BBO(16,BODZ,0,0), BBOATBI_MASK, COM, { BD } },
-{ "bdzl-", BBO(16,BODZ,0,1), BBOATBI_MASK, PPCCOM, { BDM } },
-{ "bdzl+", BBO(16,BODZ,0,1), BBOATBI_MASK, PPCCOM, { BDP } },
-{ "bdzl", BBO(16,BODZ,0,1), BBOATBI_MASK, COM, { BD } },
-{ "bdza-", BBO(16,BODZ,1,0), BBOATBI_MASK, PPCCOM, { BDMA } },
-{ "bdza+", BBO(16,BODZ,1,0), BBOATBI_MASK, PPCCOM, { BDPA } },
-{ "bdza", BBO(16,BODZ,1,0), BBOATBI_MASK, COM, { BDA } },
-{ "bdzla-", BBO(16,BODZ,1,1), BBOATBI_MASK, PPCCOM, { BDMA } },
-{ "bdzla+", BBO(16,BODZ,1,1), BBOATBI_MASK, PPCCOM, { BDPA } },
-{ "bdzla", BBO(16,BODZ,1,1), BBOATBI_MASK, COM, { BDA } },
+{ "addis", OP(15), OP_MASK, PPCCOM, { RT,RA0,SISIGNOPT } },
+{ "cau", OP(15), OP_MASK, PWRCOM, { RT,RA0,SISIGNOPT } },
+{ "subis", OP(15), OP_MASK, PPCCOM, { RT, RA0, NSI } },
+
+{ "bdnz-", BBO(16,BODNZ,0,0), BBOATBI_MASK, PPCCOM, { BDM } },
+{ "bdnz+", BBO(16,BODNZ,0,0), BBOATBI_MASK, PPCCOM, { BDP } },
+{ "bdnz", BBO(16,BODNZ,0,0), BBOATBI_MASK, PPCCOM, { BD } },
+{ "bdn", BBO(16,BODNZ,0,0), BBOATBI_MASK, PWRCOM, { BD } },
+{ "bdnzl-", BBO(16,BODNZ,0,1), BBOATBI_MASK, PPCCOM, { BDM } },
+{ "bdnzl+", BBO(16,BODNZ,0,1), BBOATBI_MASK, PPCCOM, { BDP } },
+{ "bdnzl", BBO(16,BODNZ,0,1), BBOATBI_MASK, PPCCOM, { BD } },
+{ "bdnl", BBO(16,BODNZ,0,1), BBOATBI_MASK, PWRCOM, { BD } },
+{ "bdnza-", BBO(16,BODNZ,1,0), BBOATBI_MASK, PPCCOM, { BDMA } },
+{ "bdnza+", BBO(16,BODNZ,1,0), BBOATBI_MASK, PPCCOM, { BDPA } },
+{ "bdnza", BBO(16,BODNZ,1,0), BBOATBI_MASK, PPCCOM, { BDA } },
+{ "bdna", BBO(16,BODNZ,1,0), BBOATBI_MASK, PWRCOM, { BDA } },
+{ "bdnzla-", BBO(16,BODNZ,1,1), BBOATBI_MASK, PPCCOM, { BDMA } },
+{ "bdnzla+", BBO(16,BODNZ,1,1), BBOATBI_MASK, PPCCOM, { BDPA } },
+{ "bdnzla", BBO(16,BODNZ,1,1), BBOATBI_MASK, PPCCOM, { BDA } },
+{ "bdnla", BBO(16,BODNZ,1,1), BBOATBI_MASK, PWRCOM, { BDA } },
+{ "bdz-", BBO(16,BODZ,0,0), BBOATBI_MASK, PPCCOM, { BDM } },
+{ "bdz+", BBO(16,BODZ,0,0), BBOATBI_MASK, PPCCOM, { BDP } },
+{ "bdz", BBO(16,BODZ,0,0), BBOATBI_MASK, COM, { BD } },
+{ "bdzl-", BBO(16,BODZ,0,1), BBOATBI_MASK, PPCCOM, { BDM } },
+{ "bdzl+", BBO(16,BODZ,0,1), BBOATBI_MASK, PPCCOM, { BDP } },
+{ "bdzl", BBO(16,BODZ,0,1), BBOATBI_MASK, COM, { BD } },
+{ "bdza-", BBO(16,BODZ,1,0), BBOATBI_MASK, PPCCOM, { BDMA } },
+{ "bdza+", BBO(16,BODZ,1,0), BBOATBI_MASK, PPCCOM, { BDPA } },
+{ "bdza", BBO(16,BODZ,1,0), BBOATBI_MASK, COM, { BDA } },
+{ "bdzla-", BBO(16,BODZ,1,1), BBOATBI_MASK, PPCCOM, { BDMA } },
+{ "bdzla+", BBO(16,BODZ,1,1), BBOATBI_MASK, PPCCOM, { BDPA } },
+{ "bdzla", BBO(16,BODZ,1,1), BBOATBI_MASK, COM, { BDA } },
{ "blt-", BBOCB(16,BOT,CBLT,0,0), BBOATCB_MASK, PPCCOM, { CR, BDM } },
{ "blt+", BBOCB(16,BOT,CBLT,0,0), BBOATCB_MASK, PPCCOM, { CR, BDP } },
{ "blt", BBOCB(16,BOT,CBLT,0,0), BBOATCB_MASK, COM, { CR, BD } },
@@ -2238,7 +2664,7 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "ba", B(18,1,0), B_MASK, COM, { LIA } },
{ "bla", B(18,1,1), B_MASK, COM, { LIA } },
-{ "mcrf", XL(19,0), XLBB_MASK|(3<<21)|(3<<16), COM, { BF, BFA } },
+{ "mcrf", XL(19,0), XLBB_MASK|(3 << 21)|(3 << 16), COM, { BF, BFA } },
{ "blr", XLO(19,BOU,16,0), XLBOBIBB_MASK, PPCCOM, { 0 } },
{ "br", XLO(19,BOU,16,0), XLBOBIBB_MASK, PWRCOM, { 0 } },
@@ -2246,186 +2672,186 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "brl", XLO(19,BOU,16,1), XLBOBIBB_MASK, PWRCOM, { 0 } },
{ "bdnzlr", XLO(19,BODNZ,16,0), XLBOBIBB_MASK, PPCCOM, { 0 } },
{ "bdnzlr-", XLO(19,BODNZ,16,0), XLBOBIBB_MASK, NOPOWER4, { 0 } },
-{ "bdnzlr+", XLO(19,BODNZP,16,0), XLBOBIBB_MASK, NOPOWER4, { 0 } },
{ "bdnzlr-", XLO(19,BODNZM4,16,0), XLBOBIBB_MASK, POWER4, { 0 } },
+{ "bdnzlr+", XLO(19,BODNZP,16,0), XLBOBIBB_MASK, NOPOWER4, { 0 } },
{ "bdnzlr+", XLO(19,BODNZP4,16,0), XLBOBIBB_MASK, POWER4, { 0 } },
{ "bdnzlrl", XLO(19,BODNZ,16,1), XLBOBIBB_MASK, PPCCOM, { 0 } },
{ "bdnzlrl-",XLO(19,BODNZ,16,1), XLBOBIBB_MASK, NOPOWER4, { 0 } },
-{ "bdnzlrl+",XLO(19,BODNZP,16,1), XLBOBIBB_MASK, NOPOWER4, { 0 } },
{ "bdnzlrl-",XLO(19,BODNZM4,16,1), XLBOBIBB_MASK, POWER4, { 0 } },
+{ "bdnzlrl+",XLO(19,BODNZP,16,1), XLBOBIBB_MASK, NOPOWER4, { 0 } },
{ "bdnzlrl+",XLO(19,BODNZP4,16,1), XLBOBIBB_MASK, POWER4, { 0 } },
{ "bdzlr", XLO(19,BODZ,16,0), XLBOBIBB_MASK, PPCCOM, { 0 } },
{ "bdzlr-", XLO(19,BODZ,16,0), XLBOBIBB_MASK, NOPOWER4, { 0 } },
-{ "bdzlr+", XLO(19,BODZP,16,0), XLBOBIBB_MASK, NOPOWER4, { 0 } },
{ "bdzlr-", XLO(19,BODZM4,16,0), XLBOBIBB_MASK, POWER4, { 0 } },
+{ "bdzlr+", XLO(19,BODZP,16,0), XLBOBIBB_MASK, NOPOWER4, { 0 } },
{ "bdzlr+", XLO(19,BODZP4,16,0), XLBOBIBB_MASK, POWER4, { 0 } },
{ "bdzlrl", XLO(19,BODZ,16,1), XLBOBIBB_MASK, PPCCOM, { 0 } },
{ "bdzlrl-", XLO(19,BODZ,16,1), XLBOBIBB_MASK, NOPOWER4, { 0 } },
-{ "bdzlrl+", XLO(19,BODZP,16,1), XLBOBIBB_MASK, NOPOWER4, { 0 } },
{ "bdzlrl-", XLO(19,BODZM4,16,1), XLBOBIBB_MASK, POWER4, { 0 } },
+{ "bdzlrl+", XLO(19,BODZP,16,1), XLBOBIBB_MASK, NOPOWER4, { 0 } },
{ "bdzlrl+", XLO(19,BODZP4,16,1), XLBOBIBB_MASK, POWER4, { 0 } },
{ "bltlr", XLOCB(19,BOT,CBLT,16,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bltlr-", XLOCB(19,BOT,CBLT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bltlr+", XLOCB(19,BOTP,CBLT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bltlr-", XLOCB(19,BOTM4,CBLT,16,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bltlr+", XLOCB(19,BOTP,CBLT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bltlr+", XLOCB(19,BOTP4,CBLT,16,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bltr", XLOCB(19,BOT,CBLT,16,0), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "bltlrl", XLOCB(19,BOT,CBLT,16,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bltlrl-", XLOCB(19,BOT,CBLT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bltlrl+", XLOCB(19,BOTP,CBLT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bltlrl-", XLOCB(19,BOTM4,CBLT,16,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bltlrl+", XLOCB(19,BOTP,CBLT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bltlrl+", XLOCB(19,BOTP4,CBLT,16,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bltrl", XLOCB(19,BOT,CBLT,16,1), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "bgtlr", XLOCB(19,BOT,CBGT,16,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bgtlr-", XLOCB(19,BOT,CBGT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bgtlr+", XLOCB(19,BOTP,CBGT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bgtlr-", XLOCB(19,BOTM4,CBGT,16,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bgtlr+", XLOCB(19,BOTP,CBGT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bgtlr+", XLOCB(19,BOTP4,CBGT,16,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bgtr", XLOCB(19,BOT,CBGT,16,0), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "bgtlrl", XLOCB(19,BOT,CBGT,16,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bgtlrl-", XLOCB(19,BOT,CBGT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bgtlrl+", XLOCB(19,BOTP,CBGT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bgtlrl-", XLOCB(19,BOTM4,CBGT,16,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bgtlrl+", XLOCB(19,BOTP,CBGT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bgtlrl+", XLOCB(19,BOTP4,CBGT,16,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bgtrl", XLOCB(19,BOT,CBGT,16,1), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "beqlr", XLOCB(19,BOT,CBEQ,16,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "beqlr-", XLOCB(19,BOT,CBEQ,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "beqlr+", XLOCB(19,BOTP,CBEQ,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "beqlr-", XLOCB(19,BOTM4,CBEQ,16,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "beqlr+", XLOCB(19,BOTP,CBEQ,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "beqlr+", XLOCB(19,BOTP4,CBEQ,16,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "beqr", XLOCB(19,BOT,CBEQ,16,0), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "beqlrl", XLOCB(19,BOT,CBEQ,16,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "beqlrl-", XLOCB(19,BOT,CBEQ,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "beqlrl+", XLOCB(19,BOTP,CBEQ,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "beqlrl-", XLOCB(19,BOTM4,CBEQ,16,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "beqlrl+", XLOCB(19,BOTP,CBEQ,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "beqlrl+", XLOCB(19,BOTP4,CBEQ,16,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "beqrl", XLOCB(19,BOT,CBEQ,16,1), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "bsolr", XLOCB(19,BOT,CBSO,16,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bsolr-", XLOCB(19,BOT,CBSO,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bsolr+", XLOCB(19,BOTP,CBSO,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bsolr-", XLOCB(19,BOTM4,CBSO,16,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bsolr+", XLOCB(19,BOTP,CBSO,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bsolr+", XLOCB(19,BOTP4,CBSO,16,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bsor", XLOCB(19,BOT,CBSO,16,0), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "bsolrl", XLOCB(19,BOT,CBSO,16,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bsolrl-", XLOCB(19,BOT,CBSO,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bsolrl+", XLOCB(19,BOTP,CBSO,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bsolrl-", XLOCB(19,BOTM4,CBSO,16,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bsolrl+", XLOCB(19,BOTP,CBSO,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bsolrl+", XLOCB(19,BOTP4,CBSO,16,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bsorl", XLOCB(19,BOT,CBSO,16,1), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "bunlr", XLOCB(19,BOT,CBSO,16,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bunlr-", XLOCB(19,BOT,CBSO,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bunlr+", XLOCB(19,BOTP,CBSO,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bunlr-", XLOCB(19,BOTM4,CBSO,16,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bunlr+", XLOCB(19,BOTP,CBSO,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bunlr+", XLOCB(19,BOTP4,CBSO,16,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bunlrl", XLOCB(19,BOT,CBSO,16,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bunlrl-", XLOCB(19,BOT,CBSO,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bunlrl+", XLOCB(19,BOTP,CBSO,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bunlrl-", XLOCB(19,BOTM4,CBSO,16,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bunlrl+", XLOCB(19,BOTP,CBSO,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bunlrl+", XLOCB(19,BOTP4,CBSO,16,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bgelr", XLOCB(19,BOF,CBLT,16,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bgelr-", XLOCB(19,BOF,CBLT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bgelr+", XLOCB(19,BOFP,CBLT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bgelr-", XLOCB(19,BOFM4,CBLT,16,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bgelr+", XLOCB(19,BOFP,CBLT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bgelr+", XLOCB(19,BOFP4,CBLT,16,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bger", XLOCB(19,BOF,CBLT,16,0), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "bgelrl", XLOCB(19,BOF,CBLT,16,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bgelrl-", XLOCB(19,BOF,CBLT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bgelrl+", XLOCB(19,BOFP,CBLT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bgelrl-", XLOCB(19,BOFM4,CBLT,16,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bgelrl+", XLOCB(19,BOFP,CBLT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bgelrl+", XLOCB(19,BOFP4,CBLT,16,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bgerl", XLOCB(19,BOF,CBLT,16,1), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "bnllr", XLOCB(19,BOF,CBLT,16,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnllr-", XLOCB(19,BOF,CBLT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnllr+", XLOCB(19,BOFP,CBLT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnllr-", XLOCB(19,BOFM4,CBLT,16,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnllr+", XLOCB(19,BOFP,CBLT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnllr+", XLOCB(19,BOFP4,CBLT,16,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bnlr", XLOCB(19,BOF,CBLT,16,0), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "bnllrl", XLOCB(19,BOF,CBLT,16,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnllrl-", XLOCB(19,BOF,CBLT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnllrl+", XLOCB(19,BOFP,CBLT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnllrl-", XLOCB(19,BOFM4,CBLT,16,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnllrl+", XLOCB(19,BOFP,CBLT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnllrl+", XLOCB(19,BOFP4,CBLT,16,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bnlrl", XLOCB(19,BOF,CBLT,16,1), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "blelr", XLOCB(19,BOF,CBGT,16,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "blelr-", XLOCB(19,BOF,CBGT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "blelr+", XLOCB(19,BOFP,CBGT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "blelr-", XLOCB(19,BOFM4,CBGT,16,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "blelr+", XLOCB(19,BOFP,CBGT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "blelr+", XLOCB(19,BOFP4,CBGT,16,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bler", XLOCB(19,BOF,CBGT,16,0), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "blelrl", XLOCB(19,BOF,CBGT,16,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "blelrl-", XLOCB(19,BOF,CBGT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "blelrl+", XLOCB(19,BOFP,CBGT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "blelrl-", XLOCB(19,BOFM4,CBGT,16,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "blelrl+", XLOCB(19,BOFP,CBGT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "blelrl+", XLOCB(19,BOFP4,CBGT,16,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "blerl", XLOCB(19,BOF,CBGT,16,1), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "bnglr", XLOCB(19,BOF,CBGT,16,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnglr-", XLOCB(19,BOF,CBGT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnglr+", XLOCB(19,BOFP,CBGT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnglr-", XLOCB(19,BOFM4,CBGT,16,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnglr+", XLOCB(19,BOFP,CBGT,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnglr+", XLOCB(19,BOFP4,CBGT,16,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bngr", XLOCB(19,BOF,CBGT,16,0), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "bnglrl", XLOCB(19,BOF,CBGT,16,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnglrl-", XLOCB(19,BOF,CBGT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnglrl+", XLOCB(19,BOFP,CBGT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnglrl-", XLOCB(19,BOFM4,CBGT,16,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnglrl+", XLOCB(19,BOFP,CBGT,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnglrl+", XLOCB(19,BOFP4,CBGT,16,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bngrl", XLOCB(19,BOF,CBGT,16,1), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "bnelr", XLOCB(19,BOF,CBEQ,16,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnelr-", XLOCB(19,BOF,CBEQ,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnelr+", XLOCB(19,BOFP,CBEQ,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnelr-", XLOCB(19,BOFM4,CBEQ,16,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnelr+", XLOCB(19,BOFP,CBEQ,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnelr+", XLOCB(19,BOFP4,CBEQ,16,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bner", XLOCB(19,BOF,CBEQ,16,0), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "bnelrl", XLOCB(19,BOF,CBEQ,16,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnelrl-", XLOCB(19,BOF,CBEQ,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnelrl+", XLOCB(19,BOFP,CBEQ,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnelrl-", XLOCB(19,BOFM4,CBEQ,16,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnelrl+", XLOCB(19,BOFP,CBEQ,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnelrl+", XLOCB(19,BOFP4,CBEQ,16,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bnerl", XLOCB(19,BOF,CBEQ,16,1), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "bnslr", XLOCB(19,BOF,CBSO,16,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnslr-", XLOCB(19,BOF,CBSO,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnslr+", XLOCB(19,BOFP,CBSO,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnslr-", XLOCB(19,BOFM4,CBSO,16,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnslr+", XLOCB(19,BOFP,CBSO,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnslr+", XLOCB(19,BOFP4,CBSO,16,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bnsr", XLOCB(19,BOF,CBSO,16,0), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "bnslrl", XLOCB(19,BOF,CBSO,16,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnslrl-", XLOCB(19,BOF,CBSO,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnslrl+", XLOCB(19,BOFP,CBSO,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnslrl-", XLOCB(19,BOFM4,CBSO,16,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnslrl+", XLOCB(19,BOFP,CBSO,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnslrl+", XLOCB(19,BOFP4,CBSO,16,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bnsrl", XLOCB(19,BOF,CBSO,16,1), XLBOCBBB_MASK, PWRCOM, { CR } },
{ "bnulr", XLOCB(19,BOF,CBSO,16,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnulr-", XLOCB(19,BOF,CBSO,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnulr+", XLOCB(19,BOFP,CBSO,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnulr-", XLOCB(19,BOFM4,CBSO,16,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnulr+", XLOCB(19,BOFP,CBSO,16,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnulr+", XLOCB(19,BOFP4,CBSO,16,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bnulrl", XLOCB(19,BOF,CBSO,16,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnulrl-", XLOCB(19,BOF,CBSO,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnulrl+", XLOCB(19,BOFP,CBSO,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnulrl-", XLOCB(19,BOFM4,CBSO,16,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnulrl+", XLOCB(19,BOFP,CBSO,16,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnulrl+", XLOCB(19,BOFP4,CBSO,16,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "btlr", XLO(19,BOT,16,0), XLBOBB_MASK, PPCCOM, { BI } },
{ "btlr-", XLO(19,BOT,16,0), XLBOBB_MASK, NOPOWER4, { BI } },
-{ "btlr+", XLO(19,BOTP,16,0), XLBOBB_MASK, NOPOWER4, { BI } },
{ "btlr-", XLO(19,BOTM4,16,0), XLBOBB_MASK, POWER4, { BI } },
+{ "btlr+", XLO(19,BOTP,16,0), XLBOBB_MASK, NOPOWER4, { BI } },
{ "btlr+", XLO(19,BOTP4,16,0), XLBOBB_MASK, POWER4, { BI } },
{ "bbtr", XLO(19,BOT,16,0), XLBOBB_MASK, PWRCOM, { BI } },
{ "btlrl", XLO(19,BOT,16,1), XLBOBB_MASK, PPCCOM, { BI } },
{ "btlrl-", XLO(19,BOT,16,1), XLBOBB_MASK, NOPOWER4, { BI } },
-{ "btlrl+", XLO(19,BOTP,16,1), XLBOBB_MASK, NOPOWER4, { BI } },
{ "btlrl-", XLO(19,BOTM4,16,1), XLBOBB_MASK, POWER4, { BI } },
+{ "btlrl+", XLO(19,BOTP,16,1), XLBOBB_MASK, NOPOWER4, { BI } },
{ "btlrl+", XLO(19,BOTP4,16,1), XLBOBB_MASK, POWER4, { BI } },
{ "bbtrl", XLO(19,BOT,16,1), XLBOBB_MASK, PWRCOM, { BI } },
{ "bflr", XLO(19,BOF,16,0), XLBOBB_MASK, PPCCOM, { BI } },
{ "bflr-", XLO(19,BOF,16,0), XLBOBB_MASK, NOPOWER4, { BI } },
-{ "bflr+", XLO(19,BOFP,16,0), XLBOBB_MASK, NOPOWER4, { BI } },
{ "bflr-", XLO(19,BOFM4,16,0), XLBOBB_MASK, POWER4, { BI } },
+{ "bflr+", XLO(19,BOFP,16,0), XLBOBB_MASK, NOPOWER4, { BI } },
{ "bflr+", XLO(19,BOFP4,16,0), XLBOBB_MASK, POWER4, { BI } },
{ "bbfr", XLO(19,BOF,16,0), XLBOBB_MASK, PWRCOM, { BI } },
{ "bflrl", XLO(19,BOF,16,1), XLBOBB_MASK, PPCCOM, { BI } },
{ "bflrl-", XLO(19,BOF,16,1), XLBOBB_MASK, NOPOWER4, { BI } },
-{ "bflrl+", XLO(19,BOFP,16,1), XLBOBB_MASK, NOPOWER4, { BI } },
{ "bflrl-", XLO(19,BOFM4,16,1), XLBOBB_MASK, POWER4, { BI } },
+{ "bflrl+", XLO(19,BOFP,16,1), XLBOBB_MASK, NOPOWER4, { BI } },
{ "bflrl+", XLO(19,BOFP4,16,1), XLBOBB_MASK, POWER4, { BI } },
{ "bbfrl", XLO(19,BOF,16,1), XLBOBB_MASK, PWRCOM, { BI } },
{ "bdnztlr", XLO(19,BODNZT,16,0), XLBOBB_MASK, PPCCOM, { BI } },
@@ -2467,10 +2893,10 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "crnot", XL(19,33), XL_MASK, PPCCOM, { BT, BA, BBA } },
{ "crnor", XL(19,33), XL_MASK, COM, { BT, BA, BB } },
+{ "rfmci", X(19,38), 0xffffffff, PPCRFMCI, { 0 } },
{ "rfi", XL(19,50), 0xffffffff, COM, { 0 } },
-{ "rfci", XL(19,51), 0xffffffff, PPC403, { 0 } },
-{ "rfci", XL(19,51), 0xffffffff, BOOKE, { 0 } },
+{ "rfci", XL(19,51), 0xffffffff, PPC403 | BOOKE, { 0 } },
{ "rfsvc", XL(19,82), 0xffffffff, POWER, { 0 } },
@@ -2498,143 +2924,143 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "bctrl", XLO(19,BOU,528,1), XLBOBIBB_MASK, COM, { 0 } },
{ "bltctr", XLOCB(19,BOT,CBLT,528,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bltctr-", XLOCB(19,BOT,CBLT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bltctr+", XLOCB(19,BOTP,CBLT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bltctr-", XLOCB(19,BOTM4,CBLT,528,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bltctr+", XLOCB(19,BOTP,CBLT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bltctr+", XLOCB(19,BOTP4,CBLT,528,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bltctrl", XLOCB(19,BOT,CBLT,528,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bltctrl-",XLOCB(19,BOT,CBLT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bltctrl+",XLOCB(19,BOTP,CBLT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bltctrl-",XLOCB(19,BOTM4,CBLT,528,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bltctrl+",XLOCB(19,BOTP,CBLT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bltctrl+",XLOCB(19,BOTP4,CBLT,528,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bgtctr", XLOCB(19,BOT,CBGT,528,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bgtctr-", XLOCB(19,BOT,CBGT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bgtctr+", XLOCB(19,BOTP,CBGT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bgtctr-", XLOCB(19,BOTM4,CBGT,528,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bgtctr+", XLOCB(19,BOTP,CBGT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bgtctr+", XLOCB(19,BOTP4,CBGT,528,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bgtctrl", XLOCB(19,BOT,CBGT,528,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bgtctrl-",XLOCB(19,BOT,CBGT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bgtctrl+",XLOCB(19,BOTP,CBGT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bgtctrl-",XLOCB(19,BOTM4,CBGT,528,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bgtctrl+",XLOCB(19,BOTP,CBGT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bgtctrl+",XLOCB(19,BOTP4,CBGT,528,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "beqctr", XLOCB(19,BOT,CBEQ,528,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "beqctr-", XLOCB(19,BOT,CBEQ,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "beqctr+", XLOCB(19,BOTP,CBEQ,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "beqctr-", XLOCB(19,BOTM4,CBEQ,528,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "beqctr+", XLOCB(19,BOTP,CBEQ,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "beqctr+", XLOCB(19,BOTP4,CBEQ,528,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "beqctrl", XLOCB(19,BOT,CBEQ,528,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "beqctrl-",XLOCB(19,BOT,CBEQ,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "beqctrl+",XLOCB(19,BOTP,CBEQ,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "beqctrl-",XLOCB(19,BOTM4,CBEQ,528,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "beqctrl+",XLOCB(19,BOTP,CBEQ,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "beqctrl+",XLOCB(19,BOTP4,CBEQ,528,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bsoctr", XLOCB(19,BOT,CBSO,528,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bsoctr-", XLOCB(19,BOT,CBSO,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bsoctr+", XLOCB(19,BOTP,CBSO,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bsoctr-", XLOCB(19,BOTM4,CBSO,528,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bsoctr+", XLOCB(19,BOTP,CBSO,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bsoctr+", XLOCB(19,BOTP4,CBSO,528,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bsoctrl", XLOCB(19,BOT,CBSO,528,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bsoctrl-",XLOCB(19,BOT,CBSO,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bsoctrl+",XLOCB(19,BOTP,CBSO,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bsoctrl-",XLOCB(19,BOTM4,CBSO,528,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bsoctrl+",XLOCB(19,BOTP,CBSO,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bsoctrl+",XLOCB(19,BOTP4,CBSO,528,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bunctr", XLOCB(19,BOT,CBSO,528,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bunctr-", XLOCB(19,BOT,CBSO,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bunctr+", XLOCB(19,BOTP,CBSO,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bunctr-", XLOCB(19,BOTM4,CBSO,528,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bunctr+", XLOCB(19,BOTP,CBSO,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bunctr+", XLOCB(19,BOTP4,CBSO,528,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bunctrl", XLOCB(19,BOT,CBSO,528,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bunctrl-",XLOCB(19,BOT,CBSO,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bunctrl+",XLOCB(19,BOTP,CBSO,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bunctrl-",XLOCB(19,BOTM4,CBSO,528,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bunctrl+",XLOCB(19,BOTP,CBSO,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bunctrl+",XLOCB(19,BOTP4,CBSO,528,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bgectr", XLOCB(19,BOF,CBLT,528,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bgectr-", XLOCB(19,BOF,CBLT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bgectr+", XLOCB(19,BOFP,CBLT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bgectr-", XLOCB(19,BOFM4,CBLT,528,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bgectr+", XLOCB(19,BOFP,CBLT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bgectr+", XLOCB(19,BOFP4,CBLT,528,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bgectrl", XLOCB(19,BOF,CBLT,528,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bgectrl-",XLOCB(19,BOF,CBLT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bgectrl+",XLOCB(19,BOFP,CBLT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bgectrl-",XLOCB(19,BOFM4,CBLT,528,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bgectrl+",XLOCB(19,BOFP,CBLT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bgectrl+",XLOCB(19,BOFP4,CBLT,528,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bnlctr", XLOCB(19,BOF,CBLT,528,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnlctr-", XLOCB(19,BOF,CBLT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnlctr+", XLOCB(19,BOFP,CBLT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnlctr-", XLOCB(19,BOFM4,CBLT,528,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnlctr+", XLOCB(19,BOFP,CBLT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnlctr+", XLOCB(19,BOFP4,CBLT,528,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bnlctrl", XLOCB(19,BOF,CBLT,528,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnlctrl-",XLOCB(19,BOF,CBLT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnlctrl+",XLOCB(19,BOFP,CBLT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnlctrl-",XLOCB(19,BOFM4,CBLT,528,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnlctrl+",XLOCB(19,BOFP,CBLT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnlctrl+",XLOCB(19,BOFP4,CBLT,528,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "blectr", XLOCB(19,BOF,CBGT,528,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "blectr-", XLOCB(19,BOF,CBGT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "blectr+", XLOCB(19,BOFP,CBGT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "blectr-", XLOCB(19,BOFM4,CBGT,528,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "blectr+", XLOCB(19,BOFP,CBGT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "blectr+", XLOCB(19,BOFP4,CBGT,528,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "blectrl", XLOCB(19,BOF,CBGT,528,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "blectrl-",XLOCB(19,BOF,CBGT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "blectrl+",XLOCB(19,BOFP,CBGT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "blectrl-",XLOCB(19,BOFM4,CBGT,528,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "blectrl+",XLOCB(19,BOFP,CBGT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "blectrl+",XLOCB(19,BOFP4,CBGT,528,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bngctr", XLOCB(19,BOF,CBGT,528,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bngctr-", XLOCB(19,BOF,CBGT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bngctr+", XLOCB(19,BOFP,CBGT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bngctr-", XLOCB(19,BOFM4,CBGT,528,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bngctr+", XLOCB(19,BOFP,CBGT,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bngctr+", XLOCB(19,BOFP4,CBGT,528,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bngctrl", XLOCB(19,BOF,CBGT,528,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bngctrl-",XLOCB(19,BOF,CBGT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bngctrl+",XLOCB(19,BOFP,CBGT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bngctrl-",XLOCB(19,BOFM4,CBGT,528,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bngctrl+",XLOCB(19,BOFP,CBGT,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bngctrl+",XLOCB(19,BOFP4,CBGT,528,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bnectr", XLOCB(19,BOF,CBEQ,528,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnectr-", XLOCB(19,BOF,CBEQ,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnectr+", XLOCB(19,BOFP,CBEQ,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnectr-", XLOCB(19,BOFM4,CBEQ,528,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnectr+", XLOCB(19,BOFP,CBEQ,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnectr+", XLOCB(19,BOFP4,CBEQ,528,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bnectrl", XLOCB(19,BOF,CBEQ,528,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnectrl-",XLOCB(19,BOF,CBEQ,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnectrl+",XLOCB(19,BOFP,CBEQ,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnectrl-",XLOCB(19,BOFM4,CBEQ,528,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnectrl+",XLOCB(19,BOFP,CBEQ,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnectrl+",XLOCB(19,BOFP4,CBEQ,528,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bnsctr", XLOCB(19,BOF,CBSO,528,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnsctr-", XLOCB(19,BOF,CBSO,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnsctr+", XLOCB(19,BOFP,CBSO,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnsctr-", XLOCB(19,BOFM4,CBSO,528,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnsctr+", XLOCB(19,BOFP,CBSO,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnsctr+", XLOCB(19,BOFP4,CBSO,528,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bnsctrl", XLOCB(19,BOF,CBSO,528,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnsctrl-",XLOCB(19,BOF,CBSO,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnsctrl+",XLOCB(19,BOFP,CBSO,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnsctrl-",XLOCB(19,BOFM4,CBSO,528,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnsctrl+",XLOCB(19,BOFP,CBSO,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnsctrl+",XLOCB(19,BOFP4,CBSO,528,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "bnuctr", XLOCB(19,BOF,CBSO,528,0), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnuctr-", XLOCB(19,BOF,CBSO,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnuctr+", XLOCB(19,BOFP,CBSO,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnuctr-", XLOCB(19,BOFM4,CBSO,528,0), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnuctr+", XLOCB(19,BOFP,CBSO,528,0), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnuctr+", XLOCB(19,BOFP4,CBSO,528,0), XLBOCBBB_MASK, POWER4, { CR } },
{ "bnuctrl", XLOCB(19,BOF,CBSO,528,1), XLBOCBBB_MASK, PPCCOM, { CR } },
{ "bnuctrl-",XLOCB(19,BOF,CBSO,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
-{ "bnuctrl+",XLOCB(19,BOFP,CBSO,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnuctrl-",XLOCB(19,BOFM4,CBSO,528,1), XLBOCBBB_MASK, POWER4, { CR } },
+{ "bnuctrl+",XLOCB(19,BOFP,CBSO,528,1), XLBOCBBB_MASK, NOPOWER4, { CR } },
{ "bnuctrl+",XLOCB(19,BOFP4,CBSO,528,1), XLBOCBBB_MASK, POWER4, { CR } },
{ "btctr", XLO(19,BOT,528,0), XLBOBB_MASK, PPCCOM, { BI } },
{ "btctr-", XLO(19,BOT,528,0), XLBOBB_MASK, NOPOWER4, { BI } },
-{ "btctr+", XLO(19,BOTP,528,0), XLBOBB_MASK, NOPOWER4, { BI } },
{ "btctr-", XLO(19,BOTM4,528,0), XLBOBB_MASK, POWER4, { BI } },
+{ "btctr+", XLO(19,BOTP,528,0), XLBOBB_MASK, NOPOWER4, { BI } },
{ "btctr+", XLO(19,BOTP4,528,0), XLBOBB_MASK, POWER4, { BI } },
{ "btctrl", XLO(19,BOT,528,1), XLBOBB_MASK, PPCCOM, { BI } },
{ "btctrl-", XLO(19,BOT,528,1), XLBOBB_MASK, NOPOWER4, { BI } },
-{ "btctrl+", XLO(19,BOTP,528,1), XLBOBB_MASK, NOPOWER4, { BI } },
{ "btctrl-", XLO(19,BOTM4,528,1), XLBOBB_MASK, POWER4, { BI } },
+{ "btctrl+", XLO(19,BOTP,528,1), XLBOBB_MASK, NOPOWER4, { BI } },
{ "btctrl+", XLO(19,BOTP4,528,1), XLBOBB_MASK, POWER4, { BI } },
{ "bfctr", XLO(19,BOF,528,0), XLBOBB_MASK, PPCCOM, { BI } },
{ "bfctr-", XLO(19,BOF,528,0), XLBOBB_MASK, NOPOWER4, { BI } },
-{ "bfctr+", XLO(19,BOFP,528,0), XLBOBB_MASK, NOPOWER4, { BI } },
{ "bfctr-", XLO(19,BOFM4,528,0), XLBOBB_MASK, POWER4, { BI } },
+{ "bfctr+", XLO(19,BOFP,528,0), XLBOBB_MASK, NOPOWER4, { BI } },
{ "bfctr+", XLO(19,BOFP4,528,0), XLBOBB_MASK, POWER4, { BI } },
{ "bfctrl", XLO(19,BOF,528,1), XLBOBB_MASK, PPCCOM, { BI } },
{ "bfctrl-", XLO(19,BOF,528,1), XLBOBB_MASK, NOPOWER4, { BI } },
-{ "bfctrl+", XLO(19,BOFP,528,1), XLBOBB_MASK, NOPOWER4, { BI } },
{ "bfctrl-", XLO(19,BOFM4,528,1), XLBOBB_MASK, POWER4, { BI } },
+{ "bfctrl+", XLO(19,BOFP,528,1), XLBOBB_MASK, NOPOWER4, { BI } },
{ "bfctrl+", XLO(19,BOFP4,528,1), XLBOBB_MASK, POWER4, { BI } },
{ "bcctr", XLLK(19,528,0), XLYBB_MASK, PPCCOM, { BO, BI } },
{ "bcctr-", XLYLK(19,528,0,0), XLYBB_MASK, PPCCOM, { BOE, BI } },
@@ -2722,7 +3148,7 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "cmpw", XCMPL(31,0,0), XCMPL_MASK, PPCCOM, { OBF, RA, RB } },
{ "cmpd", XCMPL(31,0,1), XCMPL_MASK, PPC64, { OBF, RA, RB } },
-{ "cmp", X(31,0), XCMP_MASK, PPCONLY, { BF, L, RA, RB } },
+{ "cmp", X(31,0), XCMP_MASK, PPC, { BF, L, RA, RB } },
{ "cmp", X(31,0), XCMPL_MASK, PWRCOM, { BF, RA, RB } },
{ "twlgt", XTO(31,4,TOLGT), XTO_MASK, PPCCOM, { RA, RB } },
@@ -2785,15 +3211,22 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "mulhwu", XO(31,11,0,0), XO_MASK, PPC, { RT, RA, RB } },
{ "mulhwu.", XO(31,11,0,1), XO_MASK, PPC, { RT, RA, RB } },
-{ "mfcr", X(31,19), XRARB_MASK, COM, { RT } },
+{ "isellt", X(31,15), X_MASK, PPCISEL, { RT, RA, RB } },
+{ "iselgt", X(31,47), X_MASK, PPCISEL, { RT, RA, RB } },
+{ "iseleq", X(31,79), X_MASK, PPCISEL, { RT, RA, RB } },
+{ "isel", XISEL(31,15), XISEL_MASK, PPCISEL, { RT, RA, RB, CRB } },
-{ "lwarx", X(31,20), X_MASK, PPC, { RT, RA, RB } },
+{ "mfcr", X(31,19), XRARB_MASK, NOPOWER4, { RT } },
+{ "mfcr", X(31,19), XFXFXM_MASK, POWER4, { RT, FXM4 } },
-{ "ldx", X(31,21), X_MASK, PPC64, { RT, RA, RB } },
+{ "lwarx", X(31,20), X_MASK, PPC, { RT, RA0, RB } },
+
+{ "ldx", X(31,21), X_MASK, PPC64, { RT, RA0, RB } },
{ "icbt", X(31,22), X_MASK, BOOKE, { CT, RA, RB } },
+{ "icbt", X(31,262), XRT_MASK, PPC403, { RA, RB } },
-{ "lwzx", X(31,23), X_MASK, PPCCOM, { RT, RA, RB } },
+{ "lwzx", X(31,23), X_MASK, PPCCOM, { RT, RA0, RB } },
{ "lx", X(31,23), X_MASK, PWRCOM, { RT, RA, RB } },
{ "slw", XRC(31,24,0), X_MASK, PPCCOM, { RA, RS, RB } },
@@ -2817,11 +3250,11 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "icbte", X(31,30), X_MASK, BOOKE64, { CT, RA, RB } },
-{ "lwzxe", X(31,31), X_MASK, BOOKE64, { RT, RA, RB } },
+{ "lwzxe", X(31,31), X_MASK, BOOKE64, { RT, RA0, RB } },
{ "cmplw", XCMPL(31,32,0), XCMPL_MASK, PPCCOM, { OBF, RA, RB } },
{ "cmpld", XCMPL(31,32,1), XCMPL_MASK, PPC64, { OBF, RA, RB } },
-{ "cmpl", X(31,32), XCMP_MASK, PPCONLY, { BF, L, RA, RB } },
+{ "cmpl", X(31,32), XCMP_MASK, PPC, { BF, L, RA, RB } },
{ "cmpl", X(31,32), XCMPL_MASK, PWRCOM, { BF, RA, RB } },
{ "subf", XO(31,40,0,0), XO_MASK, PPC, { RT, RA, RB } },
@@ -2872,19 +3305,22 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "mulhw", XO(31,75,0,0), XO_MASK, PPC, { RT, RA, RB } },
{ "mulhw.", XO(31,75,0,1), XO_MASK, PPC, { RT, RA, RB } },
+{ "dlmzb", XRC(31,78,0), X_MASK, PPC403|PPC440, { RA, RS, RB } },
+{ "dlmzb.", XRC(31,78,1), X_MASK, PPC403|PPC440, { RA, RS, RB } },
+
{ "mtsrd", X(31,82), XRB_MASK|(1<<20), PPC64, { SR, RS } },
{ "mfmsr", X(31,83), XRARB_MASK, COM, { RT } },
-{ "ldarx", X(31,84), X_MASK, PPC64, { RT, RA, RB } },
+{ "ldarx", X(31,84), X_MASK, PPC64, { RT, RA0, RB } },
{ "dcbf", X(31,86), XRT_MASK, PPC, { RA, RB } },
-{ "lbzx", X(31,87), X_MASK, COM, { RT, RA, RB } },
+{ "lbzx", X(31,87), X_MASK, COM, { RT, RA0, RB } },
{ "dcbfe", X(31,94), XRT_MASK, BOOKE64, { RA, RB } },
-{ "lbzxe", X(31,95), X_MASK, BOOKE64, { RT, RA, RB } },
+{ "lbzxe", X(31,95), X_MASK, BOOKE64, { RT, RA0, RB } },
{ "neg", XO(31,104,0,0), XORB_MASK, COM, { RT, RA } },
{ "neg.", XO(31,104,0,1), XORB_MASK, COM, { RT, RA } },
@@ -2907,12 +3343,13 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "not.", XRC(31,124,1), X_MASK, COM, { RA, RS, RBS } },
{ "nor.", XRC(31,124,1), X_MASK, COM, { RA, RS, RB } },
-{ "lwarxe", X(31,126), X_MASK, BOOKE64, { RT, RA, RB } },
+{ "lwarxe", X(31,126), X_MASK, BOOKE64, { RT, RA0, RB } },
{ "lbzuxe", X(31,127), X_MASK, BOOKE64, { RT, RAL, RB } },
-{ "wrtee", X(31,131), XRARB_MASK, PPC403, { RS } },
-{ "wrtee", X(31,131), XRARB_MASK, BOOKE, { RS } },
+{ "wrtee", X(31,131), XRARB_MASK, PPC403 | BOOKE, { RS } },
+
+{ "dcbtstls",X(31,134), X_MASK, PPCCHLK, { CT, RA, RB }},
{ "subfe", XO(31,136,0,0), XO_MASK, PPCCOM, { RT, RA, RB } },
{ "sfe", XO(31,136,0,0), XO_MASK, PWRCOM, { RT, RA, RB } },
@@ -2932,21 +3369,23 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "addeo.", XO(31,138,1,1), XO_MASK, PPCCOM, { RT, RA, RB } },
{ "aeo.", XO(31,138,1,1), XO_MASK, PWRCOM, { RT, RA, RB } },
-{ "mtcr", XFXM(31,144,0xff), XFXFXM_MASK|FXM_MASK, COM, { RS }},
+{ "dcbtstlse",X(31,142),X_MASK, PPCCHLK64, { CT, RA, RB }},
+
+{ "mtcr", XFXM(31,144,0xff), XRARB_MASK, COM, { RS }},
{ "mtcrf", X(31,144), XFXFXM_MASK, COM, { FXM, RS } },
{ "mtmsr", X(31,146), XRARB_MASK, COM, { RS } },
-{ "stdx", X(31,149), X_MASK, PPC64, { RS, RA, RB } },
+{ "stdx", X(31,149), X_MASK, PPC64, { RS, RA0, RB } },
-{ "stwcx.", XRC(31,150,1), X_MASK, PPC, { RS, RA, RB } },
+{ "stwcx.", XRC(31,150,1), X_MASK, PPC, { RS, RA0, RB } },
-{ "stwx", X(31,151), X_MASK, PPCCOM, { RS, RA, RB } },
+{ "stwx", X(31,151), X_MASK, PPCCOM, { RS, RA0, RB } },
{ "stx", X(31,151), X_MASK, PWRCOM, { RS, RA, RB } },
-{ "stwcxe.", XRC(31,158,1), X_MASK, BOOKE64, { RS, RA, RB } },
+{ "stwcxe.", XRC(31,158,1), X_MASK, BOOKE64, { RS, RA0, RB } },
-{ "stwxe", X(31,159), X_MASK, BOOKE64, { RS, RA, RB } },
+{ "stwxe", X(31,159), X_MASK, BOOKE64, { RS, RA0, RB } },
{ "slq", XRC(31,152,0), X_MASK, M601, { RA, RS, RB } },
{ "slq.", XRC(31,152,1), X_MASK, M601, { RA, RS, RB } },
@@ -2954,15 +3393,17 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "sle", XRC(31,153,0), X_MASK, M601, { RA, RS, RB } },
{ "sle.", XRC(31,153,1), X_MASK, M601, { RA, RS, RB } },
-{ "wrteei", X(31,163), XE_MASK, PPC403, { E } },
-{ "wrteei", X(31,163), XE_MASK, BOOKE, { E } },
+{ "wrteei", X(31,163), XE_MASK, PPC403 | BOOKE, { E } },
+
+{ "dcbtls", X(31,166), X_MASK, PPCCHLK, { CT, RA, RB }},
+{ "dcbtlse", X(31,174), X_MASK, PPCCHLK64, { CT, RA, RB }},
{ "mtmsrd", X(31,178), XRLARB_MASK, PPC64, { RS, MTMSRD_L } },
{ "stdux", X(31,181), X_MASK, PPC64, { RS, RAS, RB } },
{ "stwux", X(31,183), X_MASK, PPCCOM, { RS, RAS, RB } },
-{ "stux", X(31,183), X_MASK, PWRCOM, { RS, RA, RB } },
+{ "stux", X(31,183), X_MASK, PWRCOM, { RS, RA0, RB } },
{ "sliq", XRC(31,184,0), X_MASK, M601, { RA, RS, SH } },
{ "sliq.", XRC(31,184,1), X_MASK, M601, { RA, RS, SH } },
@@ -2989,9 +3430,9 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "mtsr", X(31,210), XRB_MASK|(1<<20), COM32, { SR, RS } },
-{ "stdcx.", XRC(31,214,1), X_MASK, PPC64, { RS, RA, RB } },
+{ "stdcx.", XRC(31,214,1), X_MASK, PPC64, { RS, RA0, RB } },
-{ "stbx", X(31,215), X_MASK, COM, { RS, RA, RB } },
+{ "stbx", X(31,215), X_MASK, COM, { RS, RA0, RB } },
{ "sllq", XRC(31,216,0), X_MASK, M601, { RA, RS, RB } },
{ "sllq.", XRC(31,216,1), X_MASK, M601, { RA, RS, RB } },
@@ -2999,7 +3440,9 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "sleq", XRC(31,217,0), X_MASK, M601, { RA, RS, RB } },
{ "sleq.", XRC(31,217,1), X_MASK, M601, { RA, RS, RB } },
-{ "stbxe", X(31,223), X_MASK, BOOKE64, { RS, RA, RB } },
+{ "stbxe", X(31,223), X_MASK, BOOKE64, { RS, RA0, RB } },
+
+{ "icblc", X(31,230), X_MASK, PPCCHLK, { CT, RA, RB }},
{ "subfme", XO(31,232,0,0), XORB_MASK, PPCCOM, { RT, RA } },
{ "sfme", XO(31,232,0,0), XORB_MASK, PWRCOM, { RT, RA } },
@@ -3033,10 +3476,11 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "mullwo.", XO(31,235,1,1), XO_MASK, PPCCOM, { RT, RA, RB } },
{ "mulso.", XO(31,235,1,1), XO_MASK, PWRCOM, { RT, RA, RB } },
+{ "icblce", X(31,238), X_MASK, PPCCHLK64, { CT, RA, RB }},
{ "mtsrin", X(31,242), XRA_MASK, PPC32, { RS, RB } },
{ "mtsri", X(31,242), XRA_MASK, POWER32, { RS, RB } },
-{ "dcbtst", X(31,246), XRT_MASK, PPC, { CT, RA, RB } },
+{ "dcbtst", X(31,246), X_MASK, PPC, { CT, RA, RB } },
{ "stbux", X(31,247), X_MASK, COM, { RS, RAS, RB } },
@@ -3049,8 +3493,6 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "mfdcrx", X(31,259), X_MASK, BOOKE, { RS, RA } },
-{ "icbt", X(31,262), XRT_MASK, PPC403, { RA, RB } },
-
{ "doz", XO(31,264,0,0), XO_MASK, M601, { RT, RA, RB } },
{ "doz.", XO(31,264,0,1), XO_MASK, M601, { RT, RA, RB } },
{ "dozo", XO(31,264,1,0), XO_MASK, M601, { RT, RA, RB } },
@@ -3072,19 +3514,19 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "lscbx", XRC(31,277,0), X_MASK, M601, { RT, RA, RB } },
{ "lscbx.", XRC(31,277,1), X_MASK, M601, { RT, RA, RB } },
-{ "dcbt", X(31,278), XRT_MASK, PPC, { CT, RA, RB } },
+{ "dcbt", X(31,278), X_MASK, PPC, { CT, RA, RB } },
-{ "lhzx", X(31,279), X_MASK, COM, { RT, RA, RB } },
+{ "lhzx", X(31,279), X_MASK, COM, { RT, RA0, RB } },
{ "eqv", XRC(31,284,0), X_MASK, COM, { RA, RS, RB } },
{ "eqv.", XRC(31,284,1), X_MASK, COM, { RA, RS, RB } },
{ "dcbte", X(31,286), X_MASK, BOOKE64, { CT, RA, RB } },
-{ "lhzxe", X(31,287), X_MASK, BOOKE64, { RT, RA, RB } },
+{ "lhzxe", X(31,287), X_MASK, BOOKE64, { RT, RA0, RB } },
{ "tlbie", X(31,306), XRTLRA_MASK, PPC, { RB, L } },
-{ "tlbi", X(31,306), XRT_MASK, POWER, { RA, RB } },
+{ "tlbi", X(31,306), XRT_MASK, POWER, { RA0, RB } },
{ "eciwx", X(31,310), X_MASK, PPC, { RT, RA, RB } },
@@ -3095,19 +3537,19 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "lhzuxe", X(31,319), X_MASK, BOOKE64, { RT, RAL, RB } },
-{ "mfexisr", XSPR(31,323,64), XSPR_MASK, PPC403, { RT } },
-{ "mfexier", XSPR(31,323,66), XSPR_MASK, PPC403, { RT } },
-{ "mfbr0", XSPR(31,323,128), XSPR_MASK, PPC403, { RT } },
-{ "mfbr1", XSPR(31,323,129), XSPR_MASK, PPC403, { RT } },
-{ "mfbr2", XSPR(31,323,130), XSPR_MASK, PPC403, { RT } },
-{ "mfbr3", XSPR(31,323,131), XSPR_MASK, PPC403, { RT } },
-{ "mfbr4", XSPR(31,323,132), XSPR_MASK, PPC403, { RT } },
-{ "mfbr5", XSPR(31,323,133), XSPR_MASK, PPC403, { RT } },
-{ "mfbr6", XSPR(31,323,134), XSPR_MASK, PPC403, { RT } },
-{ "mfbr7", XSPR(31,323,135), XSPR_MASK, PPC403, { RT } },
-{ "mfbear", XSPR(31,323,144), XSPR_MASK, PPC403, { RT } },
-{ "mfbesr", XSPR(31,323,145), XSPR_MASK, PPC403, { RT } },
-{ "mfiocr", XSPR(31,323,160), XSPR_MASK, PPC403, { RT } },
+{ "mfexisr", XSPR(31,323,64), XSPR_MASK, PPC403, { RT } },
+{ "mfexier", XSPR(31,323,66), XSPR_MASK, PPC403, { RT } },
+{ "mfbr0", XSPR(31,323,128), XSPR_MASK, PPC403, { RT } },
+{ "mfbr1", XSPR(31,323,129), XSPR_MASK, PPC403, { RT } },
+{ "mfbr2", XSPR(31,323,130), XSPR_MASK, PPC403, { RT } },
+{ "mfbr3", XSPR(31,323,131), XSPR_MASK, PPC403, { RT } },
+{ "mfbr4", XSPR(31,323,132), XSPR_MASK, PPC403, { RT } },
+{ "mfbr5", XSPR(31,323,133), XSPR_MASK, PPC403, { RT } },
+{ "mfbr6", XSPR(31,323,134), XSPR_MASK, PPC403, { RT } },
+{ "mfbr7", XSPR(31,323,135), XSPR_MASK, PPC403, { RT } },
+{ "mfbear", XSPR(31,323,144), XSPR_MASK, PPC403, { RT } },
+{ "mfbesr", XSPR(31,323,145), XSPR_MASK, PPC403, { RT } },
+{ "mfiocr", XSPR(31,323,160), XSPR_MASK, PPC403, { RT } },
{ "mfdmacr0", XSPR(31,323,192), XSPR_MASK, PPC403, { RT } },
{ "mfdmact0", XSPR(31,323,193), XSPR_MASK, PPC403, { RT } },
{ "mfdmada0", XSPR(31,323,194), XSPR_MASK, PPC403, { RT } },
@@ -3128,106 +3570,176 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "mfdmada3", XSPR(31,323,218), XSPR_MASK, PPC403, { RT } },
{ "mfdmasa3", XSPR(31,323,219), XSPR_MASK, PPC403, { RT } },
{ "mfdmacc3", XSPR(31,323,220), XSPR_MASK, PPC403, { RT } },
-{ "mfdmasr", XSPR(31,323,224), XSPR_MASK, PPC403, { RT } },
-{ "mfdcr", X(31,323), X_MASK, PPC403, { RT, SPR } },
-{ "mfdcr", X(31,323), X_MASK, BOOKE, { RT, SPR } },
+{ "mfdmasr", XSPR(31,323,224), XSPR_MASK, PPC403, { RT } },
+{ "mfdcr", X(31,323), X_MASK, PPC403 | BOOKE, { RT, SPR } },
{ "div", XO(31,331,0,0), XO_MASK, M601, { RT, RA, RB } },
{ "div.", XO(31,331,0,1), XO_MASK, M601, { RT, RA, RB } },
{ "divo", XO(31,331,1,0), XO_MASK, M601, { RT, RA, RB } },
{ "divo.", XO(31,331,1,1), XO_MASK, M601, { RT, RA, RB } },
-{ "mfmq", XSPR(31,339,0), XSPR_MASK, M601, { RT } },
-{ "mfxer", XSPR(31,339,1), XSPR_MASK, COM, { RT } },
-{ "mfrtcu", XSPR(31,339,4), XSPR_MASK, COM, { RT } },
-{ "mfrtcl", XSPR(31,339,5), XSPR_MASK, COM, { RT } },
-{ "mfdec", XSPR(31,339,6), XSPR_MASK, MFDEC1, { RT } },
-{ "mflr", XSPR(31,339,8), XSPR_MASK, COM, { RT } },
-{ "mfctr", XSPR(31,339,9), XSPR_MASK, COM, { RT } },
-{ "mftid", XSPR(31,339,17), XSPR_MASK, POWER, { RT } },
-{ "mfdsisr", XSPR(31,339,18), XSPR_MASK, COM, { RT } },
-{ "mfdar", XSPR(31,339,19), XSPR_MASK, COM, { RT } },
-{ "mfdec", XSPR(31,339,22), XSPR_MASK, MFDEC2, { RT } },
-{ "mfsdr0", XSPR(31,339,24), XSPR_MASK, POWER, { RT } },
-{ "mfsdr1", XSPR(31,339,25), XSPR_MASK, COM, { RT } },
-{ "mfsrr0", XSPR(31,339,26), XSPR_MASK, COM, { RT } },
-{ "mfsrr1", XSPR(31,339,27), XSPR_MASK, COM, { RT } },
-{ "mfcmpa", XSPR(31,339,144), XSPR_MASK, PPC860, { RT } },
-{ "mfcmpb", XSPR(31,339,145), XSPR_MASK, PPC860, { RT } },
-{ "mfcmpc", XSPR(31,339,146), XSPR_MASK, PPC860, { RT } },
-{ "mfcmpd", XSPR(31,339,147), XSPR_MASK, PPC860, { RT } },
-{ "mficr", XSPR(31,339,148), XSPR_MASK, PPC860, { RT } },
-{ "mfder", XSPR(31,339,149), XSPR_MASK, PPC860, { RT } },
-{ "mfcounta", XSPR(31,339,150), XSPR_MASK, PPC860, { RT } },
-{ "mfcountb", XSPR(31,339,151), XSPR_MASK, PPC860, { RT } },
-{ "mfcmpe", XSPR(31,339,152), XSPR_MASK, PPC860, { RT } },
-{ "mfcmpf", XSPR(31,339,153), XSPR_MASK, PPC860, { RT } },
-{ "mfcmpg", XSPR(31,339,154), XSPR_MASK, PPC860, { RT } },
-{ "mfcmph", XSPR(31,339,155), XSPR_MASK, PPC860, { RT } },
-{ "mflctrl1", XSPR(31,339,156), XSPR_MASK, PPC860, { RT } },
-{ "mflctrl2", XSPR(31,339,157), XSPR_MASK, PPC860, { RT } },
-{ "mfictrl", XSPR(31,339,158), XSPR_MASK, PPC860, { RT } },
-{ "mfbar", XSPR(31,339,159), XSPR_MASK, PPC860, { RT } },
-{ "mfvrsave", XSPR(31,339,256), XSPR_MASK, PPCVEC, { RT } },
-{ "mfsprg4", XSPR(31,339,260), XSPR_MASK, PPC405, { RT } },
-{ "mfsprg5", XSPR(31,339,261), XSPR_MASK, PPC405, { RT } },
-{ "mfsprg6", XSPR(31,339,262), XSPR_MASK, PPC405, { RT } },
-{ "mfsprg7", XSPR(31,339,263), XSPR_MASK, PPC405, { RT } },
-{ "mfsprg", XSPR(31,339,272), XSPRG_MASK, PPC, { RT, SPRG } },
-{ "mfsprg0", XSPR(31,339,272), XSPR_MASK, PPC, { RT } },
-{ "mfsprg1", XSPR(31,339,273), XSPR_MASK, PPC, { RT } },
-{ "mfsprg2", XSPR(31,339,274), XSPR_MASK, PPC, { RT } },
-{ "mfsprg3", XSPR(31,339,275), XSPR_MASK, PPC, { RT } },
-{ "mfasr", XSPR(31,339,280), XSPR_MASK, PPC64, { RT } },
-{ "mfear", XSPR(31,339,282), XSPR_MASK, PPC, { RT } },
-{ "mfpvr", XSPR(31,339,287), XSPR_MASK, PPC, { RT } },
-{ "mfibatu", XSPR(31,339,528), XSPRBAT_MASK, PPC, { RT, SPRBAT } },
-{ "mfibatl", XSPR(31,339,529), XSPRBAT_MASK, PPC, { RT, SPRBAT } },
-{ "mfdbatu", XSPR(31,339,536), XSPRBAT_MASK, PPC, { RT, SPRBAT } },
-{ "mfdbatl", XSPR(31,339,537), XSPRBAT_MASK, PPC, { RT, SPRBAT } },
-{ "mfic_cst", XSPR(31,339,560), XSPR_MASK, PPC860, { RT } },
-{ "mfic_adr", XSPR(31,339,561), XSPR_MASK, PPC860, { RT } },
-{ "mfic_dat", XSPR(31,339,562), XSPR_MASK, PPC860, { RT } },
-{ "mfdc_cst", XSPR(31,339,568), XSPR_MASK, PPC860, { RT } },
-{ "mfdc_adr", XSPR(31,339,569), XSPR_MASK, PPC860, { RT } },
-{ "mfdc_dat", XSPR(31,339,570), XSPR_MASK, PPC860, { RT } },
-{ "mfdpdr", XSPR(31,339,630), XSPR_MASK, PPC860, { RT } },
-{ "mfdpir", XSPR(31,339,631), XSPR_MASK, PPC860, { RT } },
-{ "mfimmr", XSPR(31,339,638), XSPR_MASK, PPC860, { RT } },
-{ "mfmi_ctr", XSPR(31,339,784), XSPR_MASK, PPC860, { RT } },
-{ "mfmi_ap", XSPR(31,339,786), XSPR_MASK, PPC860, { RT } },
-{ "mfmi_epn", XSPR(31,339,787), XSPR_MASK, PPC860, { RT } },
-{ "mfmi_twc", XSPR(31,339,789), XSPR_MASK, PPC860, { RT } },
-{ "mfmi_rpn", XSPR(31,339,790), XSPR_MASK, PPC860, { RT } },
-{ "mfmd_ctr", XSPR(31,339,792), XSPR_MASK, PPC860, { RT } },
-{ "mfm_casid",XSPR(31,339,793), XSPR_MASK, PPC860, { RT } },
-{ "mfmd_ap", XSPR(31,339,794), XSPR_MASK, PPC860, { RT } },
-{ "mfmd_epn", XSPR(31,339,795), XSPR_MASK, PPC860, { RT } },
-{ "mfmd_twb", XSPR(31,339,796), XSPR_MASK, PPC860, { RT } },
-{ "mfmd_twc", XSPR(31,339,797), XSPR_MASK, PPC860, { RT } },
-{ "mfmd_rpn", XSPR(31,339,798), XSPR_MASK, PPC860, { RT } },
-{ "mfm_tw", XSPR(31,339,799), XSPR_MASK, PPC860, { RT } },
-{ "mfmi_dbcam",XSPR(31,339,816), XSPR_MASK, PPC860, { RT } },
-{ "mfmi_dbram0",XSPR(31,339,817), XSPR_MASK, PPC860, { RT } },
-{ "mfmi_dbram1",XSPR(31,339,818), XSPR_MASK, PPC860, { RT } },
-{ "mfmd_dbcam", XSPR(31,339,824), XSPR_MASK, PPC860, { RT } },
-{ "mfmd_dbram0",XSPR(31,339,825), XSPR_MASK, PPC860, { RT } },
-{ "mfmd_dbram1",XSPR(31,339,826), XSPR_MASK, PPC860, { RT } },
-{ "mfzpr", XSPR(31,339,944), XSPR_MASK, PPC403, { RT } },
-{ "mfpid", XSPR(31,339,945), XSPR_MASK, PPC403, { RT } },
-{ "mfccr0", XSPR(31,339,947), XSPR_MASK, PPC405, { RT } },
-{ "mficdbdr", XSPR(31,339,979), XSPR_MASK, PPC403, { RT } },
-{ "mfummcr0", XSPR(31,339,936), XSPR_MASK, PPC750, { RT } },
-{ "mfupmc1", XSPR(31,339,937), XSPR_MASK, PPC750, { RT } },
-{ "mfupmc2", XSPR(31,339,938), XSPR_MASK, PPC750, { RT } },
-{ "mfusia", XSPR(31,339,939), XSPR_MASK, PPC750, { RT } },
-{ "mfummcr1", XSPR(31,339,940), XSPR_MASK, PPC750, { RT } },
-{ "mfupmc3", XSPR(31,339,941), XSPR_MASK, PPC750, { RT } },
-{ "mfupmc4", XSPR(31,339,942), XSPR_MASK, PPC750, { RT } },
+{ "mfpmr", X(31,334), X_MASK, PPCPMR, { RT, PMR }},
+
+{ "mfmq", XSPR(31,339,0), XSPR_MASK, M601, { RT } },
+{ "mfxer", XSPR(31,339,1), XSPR_MASK, COM, { RT } },
+{ "mfrtcu", XSPR(31,339,4), XSPR_MASK, COM, { RT } },
+{ "mfrtcl", XSPR(31,339,5), XSPR_MASK, COM, { RT } },
+{ "mfdec", XSPR(31,339,6), XSPR_MASK, MFDEC1, { RT } },
+{ "mfdec", XSPR(31,339,22), XSPR_MASK, MFDEC2, { RT } },
+{ "mflr", XSPR(31,339,8), XSPR_MASK, COM, { RT } },
+{ "mfctr", XSPR(31,339,9), XSPR_MASK, COM, { RT } },
+{ "mftid", XSPR(31,339,17), XSPR_MASK, POWER, { RT } },
+{ "mfdsisr", XSPR(31,339,18), XSPR_MASK, COM, { RT } },
+{ "mfdar", XSPR(31,339,19), XSPR_MASK, COM, { RT } },
+{ "mfsdr0", XSPR(31,339,24), XSPR_MASK, POWER, { RT } },
+{ "mfsdr1", XSPR(31,339,25), XSPR_MASK, COM, { RT } },
+{ "mfsrr0", XSPR(31,339,26), XSPR_MASK, COM, { RT } },
+{ "mfsrr1", XSPR(31,339,27), XSPR_MASK, COM, { RT } },
+{ "mfpid", XSPR(31,339,48), XSPR_MASK, BOOKE, { RT } },
+{ "mfpid", XSPR(31,339,945), XSPR_MASK, PPC403, { RT } },
+{ "mfcsrr0", XSPR(31,339,58), XSPR_MASK, BOOKE, { RT } },
+{ "mfcsrr1", XSPR(31,339,59), XSPR_MASK, BOOKE, { RT } },
+{ "mfdear", XSPR(31,339,61), XSPR_MASK, BOOKE, { RT } },
+{ "mfdear", XSPR(31,339,981), XSPR_MASK, PPC403, { RT } },
+{ "mfesr", XSPR(31,339,62), XSPR_MASK, BOOKE, { RT } },
+{ "mfesr", XSPR(31,339,980), XSPR_MASK, PPC403, { RT } },
+{ "mfivpr", XSPR(31,339,63), XSPR_MASK, BOOKE, { RT } },
+{ "mfcmpa", XSPR(31,339,144), XSPR_MASK, PPC860, { RT } },
+{ "mfcmpb", XSPR(31,339,145), XSPR_MASK, PPC860, { RT } },
+{ "mfcmpc", XSPR(31,339,146), XSPR_MASK, PPC860, { RT } },
+{ "mfcmpd", XSPR(31,339,147), XSPR_MASK, PPC860, { RT } },
+{ "mficr", XSPR(31,339,148), XSPR_MASK, PPC860, { RT } },
+{ "mfder", XSPR(31,339,149), XSPR_MASK, PPC860, { RT } },
+{ "mfcounta", XSPR(31,339,150), XSPR_MASK, PPC860, { RT } },
+{ "mfcountb", XSPR(31,339,151), XSPR_MASK, PPC860, { RT } },
+{ "mfcmpe", XSPR(31,339,152), XSPR_MASK, PPC860, { RT } },
+{ "mfcmpf", XSPR(31,339,153), XSPR_MASK, PPC860, { RT } },
+{ "mfcmpg", XSPR(31,339,154), XSPR_MASK, PPC860, { RT } },
+{ "mfcmph", XSPR(31,339,155), XSPR_MASK, PPC860, { RT } },
+{ "mflctrl1", XSPR(31,339,156), XSPR_MASK, PPC860, { RT } },
+{ "mflctrl2", XSPR(31,339,157), XSPR_MASK, PPC860, { RT } },
+{ "mfictrl", XSPR(31,339,158), XSPR_MASK, PPC860, { RT } },
+{ "mfbar", XSPR(31,339,159), XSPR_MASK, PPC860, { RT } },
+{ "mfvrsave", XSPR(31,339,256), XSPR_MASK, PPCVEC, { RT } },
+{ "mfusprg0", XSPR(31,339,256), XSPR_MASK, BOOKE, { RT } },
+{ "mfsprg4", XSPR(31,339,260), XSPR_MASK, PPC405, { RT } },
+{ "mfsprg4", XSPR(31,339,260), XSPR_MASK, BOOKE, { RT } },
+{ "mfsprg5", XSPR(31,339,261), XSPR_MASK, PPC405, { RT } },
+{ "mfsprg5", XSPR(31,339,261), XSPR_MASK, BOOKE, { RT } },
+{ "mfsprg6", XSPR(31,339,262), XSPR_MASK, PPC405, { RT } },
+{ "mfsprg6", XSPR(31,339,262), XSPR_MASK, BOOKE, { RT } },
+{ "mfsprg7", XSPR(31,339,263), XSPR_MASK, PPC405, { RT } },
+{ "mfsprg7", XSPR(31,339,263), XSPR_MASK, BOOKE, { RT } },
+{ "mftb", X(31,371), X_MASK, CLASSIC, { RT, TBR } },
+{ "mftb", XSPR(31,339,268), XSPR_MASK, BOOKE, { RT } },
+{ "mftbl", XSPR(31,371,268), XSPR_MASK, CLASSIC, { RT } },
+{ "mftbl", XSPR(31,339,268), XSPR_MASK, BOOKE, { RT } },
+{ "mftbu", XSPR(31,371,269), XSPR_MASK, CLASSIC, { RT } },
+{ "mftbu", XSPR(31,339,269), XSPR_MASK, BOOKE, { RT } },
+{ "mfsprg", XSPR(31,339,272), XSPRG_MASK, PPC, { RT, SPRG } },
+{ "mfsprg0", XSPR(31,339,272), XSPR_MASK, PPC, { RT } },
+{ "mfsprg1", XSPR(31,339,273), XSPR_MASK, PPC, { RT } },
+{ "mfsprg2", XSPR(31,339,274), XSPR_MASK, PPC, { RT } },
+{ "mfsprg3", XSPR(31,339,275), XSPR_MASK, PPC, { RT } },
+{ "mfasr", XSPR(31,339,280), XSPR_MASK, PPC64, { RT } },
+{ "mfear", XSPR(31,339,282), XSPR_MASK, PPC, { RT } },
+{ "mfpir", XSPR(31,339,286), XSPR_MASK, BOOKE, { RT } },
+{ "mfpvr", XSPR(31,339,287), XSPR_MASK, PPC, { RT } },
+{ "mfdbsr", XSPR(31,339,304), XSPR_MASK, BOOKE, { RT } },
+{ "mfdbsr", XSPR(31,339,1008), XSPR_MASK, PPC403, { RT } },
+{ "mfdbcr0", XSPR(31,339,308), XSPR_MASK, BOOKE, { RT } },
+{ "mfdbcr0", XSPR(31,339,1010), XSPR_MASK, PPC405, { RT } },
+{ "mfdbcr1", XSPR(31,339,309), XSPR_MASK, BOOKE, { RT } },
+{ "mfdbcr1", XSPR(31,339,957), XSPR_MASK, PPC405, { RT } },
+{ "mfdbcr2", XSPR(31,339,310), XSPR_MASK, BOOKE, { RT } },
+{ "mfiac1", XSPR(31,339,312), XSPR_MASK, BOOKE, { RT } },
+{ "mfiac1", XSPR(31,339,1012), XSPR_MASK, PPC403, { RT } },
+{ "mfiac2", XSPR(31,339,313), XSPR_MASK, BOOKE, { RT } },
+{ "mfiac2", XSPR(31,339,1013), XSPR_MASK, PPC403, { RT } },
+{ "mfiac3", XSPR(31,339,314), XSPR_MASK, BOOKE, { RT } },
{ "mfiac3", XSPR(31,339,948), XSPR_MASK, PPC405, { RT } },
+{ "mfiac4", XSPR(31,339,315), XSPR_MASK, BOOKE, { RT } },
{ "mfiac4", XSPR(31,339,949), XSPR_MASK, PPC405, { RT } },
+{ "mfdac1", XSPR(31,339,316), XSPR_MASK, BOOKE, { RT } },
+{ "mfdac1", XSPR(31,339,1014), XSPR_MASK, PPC403, { RT } },
+{ "mfdac2", XSPR(31,339,317), XSPR_MASK, BOOKE, { RT } },
+{ "mfdac2", XSPR(31,339,1015), XSPR_MASK, PPC403, { RT } },
+{ "mfdvc1", XSPR(31,339,318), XSPR_MASK, BOOKE, { RT } },
{ "mfdvc1", XSPR(31,339,950), XSPR_MASK, PPC405, { RT } },
+{ "mfdvc2", XSPR(31,339,319), XSPR_MASK, BOOKE, { RT } },
{ "mfdvc2", XSPR(31,339,951), XSPR_MASK, PPC405, { RT } },
+{ "mftsr", XSPR(31,339,336), XSPR_MASK, BOOKE, { RT } },
+{ "mftsr", XSPR(31,339,984), XSPR_MASK, PPC403, { RT } },
+{ "mftcr", XSPR(31,339,340), XSPR_MASK, BOOKE, { RT } },
+{ "mftcr", XSPR(31,339,986), XSPR_MASK, PPC403, { RT } },
+{ "mfivor0", XSPR(31,339,400), XSPR_MASK, BOOKE, { RT } },
+{ "mfivor1", XSPR(31,339,401), XSPR_MASK, BOOKE, { RT } },
+{ "mfivor2", XSPR(31,339,402), XSPR_MASK, BOOKE, { RT } },
+{ "mfivor3", XSPR(31,339,403), XSPR_MASK, BOOKE, { RT } },
+{ "mfivor4", XSPR(31,339,404), XSPR_MASK, BOOKE, { RT } },
+{ "mfivor5", XSPR(31,339,405), XSPR_MASK, BOOKE, { RT } },
+{ "mfivor6", XSPR(31,339,406), XSPR_MASK, BOOKE, { RT } },
+{ "mfivor7", XSPR(31,339,407), XSPR_MASK, BOOKE, { RT } },
+{ "mfivor8", XSPR(31,339,408), XSPR_MASK, BOOKE, { RT } },
+{ "mfivor9", XSPR(31,339,409), XSPR_MASK, BOOKE, { RT } },
+{ "mfivor10", XSPR(31,339,410), XSPR_MASK, BOOKE, { RT } },
+{ "mfivor11", XSPR(31,339,411), XSPR_MASK, BOOKE, { RT } },
+{ "mfivor12", XSPR(31,339,412), XSPR_MASK, BOOKE, { RT } },
+{ "mfivor13", XSPR(31,339,413), XSPR_MASK, BOOKE, { RT } },
+{ "mfivor14", XSPR(31,339,414), XSPR_MASK, BOOKE, { RT } },
+{ "mfivor15", XSPR(31,339,415), XSPR_MASK, BOOKE, { RT } },
+{ "mfspefscr", XSPR(31,339,512), XSPR_MASK, PPCSPE, { RT } },
+{ "mfbbear", XSPR(31,339,513), XSPR_MASK, PPCBRLK, { RT } },
+{ "mfbbtar", XSPR(31,339,514), XSPR_MASK, PPCBRLK, { RT } },
+{ "mfivor32", XSPR(31,339,528), XSPR_MASK, PPCSPE, { RT } },
+{ "mfivor33", XSPR(31,339,529), XSPR_MASK, PPCSPE, { RT } },
+{ "mfivor34", XSPR(31,339,530), XSPR_MASK, PPCSPE, { RT } },
+{ "mfivor35", XSPR(31,339,531), XSPR_MASK, PPCPMR, { RT } },
+{ "mfibatu", XSPR(31,339,528), XSPRBAT_MASK, PPC, { RT, SPRBAT } },
+{ "mfibatl", XSPR(31,339,529), XSPRBAT_MASK, PPC, { RT, SPRBAT } },
+{ "mfdbatu", XSPR(31,339,536), XSPRBAT_MASK, PPC, { RT, SPRBAT } },
+{ "mfdbatl", XSPR(31,339,537), XSPRBAT_MASK, PPC, { RT, SPRBAT } },
+{ "mfic_cst", XSPR(31,339,560), XSPR_MASK, PPC860, { RT } },
+{ "mfic_adr", XSPR(31,339,561), XSPR_MASK, PPC860, { RT } },
+{ "mfic_dat", XSPR(31,339,562), XSPR_MASK, PPC860, { RT } },
+{ "mfdc_cst", XSPR(31,339,568), XSPR_MASK, PPC860, { RT } },
+{ "mfdc_adr", XSPR(31,339,569), XSPR_MASK, PPC860, { RT } },
+{ "mfmcsrr0", XSPR(31,339,570), XSPR_MASK, PPCRFMCI, { RT } },
+{ "mfdc_dat", XSPR(31,339,570), XSPR_MASK, PPC860, { RT } },
+{ "mfmcsrr1", XSPR(31,339,571), XSPR_MASK, PPCRFMCI, { RT } },
+{ "mfmcsr", XSPR(31,339,572), XSPR_MASK, PPCRFMCI, { RT } },
+{ "mfmcar", XSPR(31,339,573), XSPR_MASK, PPCRFMCI, { RT } },
+{ "mfdpdr", XSPR(31,339,630), XSPR_MASK, PPC860, { RT } },
+{ "mfdpir", XSPR(31,339,631), XSPR_MASK, PPC860, { RT } },
+{ "mfimmr", XSPR(31,339,638), XSPR_MASK, PPC860, { RT } },
+{ "mfmi_ctr", XSPR(31,339,784), XSPR_MASK, PPC860, { RT } },
+{ "mfmi_ap", XSPR(31,339,786), XSPR_MASK, PPC860, { RT } },
+{ "mfmi_epn", XSPR(31,339,787), XSPR_MASK, PPC860, { RT } },
+{ "mfmi_twc", XSPR(31,339,789), XSPR_MASK, PPC860, { RT } },
+{ "mfmi_rpn", XSPR(31,339,790), XSPR_MASK, PPC860, { RT } },
+{ "mfmd_ctr", XSPR(31,339,792), XSPR_MASK, PPC860, { RT } },
+{ "mfm_casid", XSPR(31,339,793), XSPR_MASK, PPC860, { RT } },
+{ "mfmd_ap", XSPR(31,339,794), XSPR_MASK, PPC860, { RT } },
+{ "mfmd_epn", XSPR(31,339,795), XSPR_MASK, PPC860, { RT } },
+{ "mfmd_twb", XSPR(31,339,796), XSPR_MASK, PPC860, { RT } },
+{ "mfmd_twc", XSPR(31,339,797), XSPR_MASK, PPC860, { RT } },
+{ "mfmd_rpn", XSPR(31,339,798), XSPR_MASK, PPC860, { RT } },
+{ "mfm_tw", XSPR(31,339,799), XSPR_MASK, PPC860, { RT } },
+{ "mfmi_dbcam", XSPR(31,339,816), XSPR_MASK, PPC860, { RT } },
+{ "mfmi_dbram0",XSPR(31,339,817), XSPR_MASK, PPC860, { RT } },
+{ "mfmi_dbram1",XSPR(31,339,818), XSPR_MASK, PPC860, { RT } },
+{ "mfmd_dbcam", XSPR(31,339,824), XSPR_MASK, PPC860, { RT } },
+{ "mfmd_dbram0",XSPR(31,339,825), XSPR_MASK, PPC860, { RT } },
+{ "mfmd_dbram1",XSPR(31,339,826), XSPR_MASK, PPC860, { RT } },
+{ "mfummcr0", XSPR(31,339,936), XSPR_MASK, PPC750, { RT } },
+{ "mfupmc1", XSPR(31,339,937), XSPR_MASK, PPC750, { RT } },
+{ "mfupmc2", XSPR(31,339,938), XSPR_MASK, PPC750, { RT } },
+{ "mfusia", XSPR(31,339,939), XSPR_MASK, PPC750, { RT } },
+{ "mfummcr1", XSPR(31,339,940), XSPR_MASK, PPC750, { RT } },
+{ "mfupmc3", XSPR(31,339,941), XSPR_MASK, PPC750, { RT } },
+{ "mfupmc4", XSPR(31,339,942), XSPR_MASK, PPC750, { RT } },
+{ "mfzpr", XSPR(31,339,944), XSPR_MASK, PPC403, { RT } },
+{ "mfccr0", XSPR(31,339,947), XSPR_MASK, PPC405, { RT } },
{ "mfmmcr0", XSPR(31,339,952), XSPR_MASK, PPC750, { RT } },
{ "mfpmc1", XSPR(31,339,953), XSPR_MASK, PPC750, { RT } },
{ "mfsgr", XSPR(31,339,953), XSPR_MASK, PPC403, { RT } },
@@ -3238,51 +3750,41 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "mfmmcr1", XSPR(31,339,956), XSPR_MASK, PPC750, { RT } },
{ "mfsu0r", XSPR(31,339,956), XSPR_MASK, PPC405, { RT } },
{ "mfpmc3", XSPR(31,339,957), XSPR_MASK, PPC750, { RT } },
-{ "mfdbcr1", XSPR(31,339,957), XSPR_MASK, PPC405, { RT } },
{ "mfpmc4", XSPR(31,339,958), XSPR_MASK, PPC750, { RT } },
-{ "mfesr", XSPR(31,339,980), XSPR_MASK, PPC403, { RT } },
-{ "mfdear", XSPR(31,339,981), XSPR_MASK, PPC403, { RT } },
-{ "mfevpr", XSPR(31,339,982), XSPR_MASK, PPC403, { RT } },
-{ "mfcdbcr", XSPR(31,339,983), XSPR_MASK, PPC403, { RT } },
-{ "mftsr", XSPR(31,339,984), XSPR_MASK, PPC403, { RT } },
-{ "mftcr", XSPR(31,339,986), XSPR_MASK, PPC403, { RT } },
-{ "mfpit", XSPR(31,339,987), XSPR_MASK, PPC403, { RT } },
-{ "mftbhi", XSPR(31,339,988), XSPR_MASK, PPC403, { RT } },
-{ "mftblo", XSPR(31,339,989), XSPR_MASK, PPC403, { RT } },
-{ "mfsrr2", XSPR(31,339,990), XSPR_MASK, PPC403, { RT } },
-{ "mfsrr3", XSPR(31,339,991), XSPR_MASK, PPC403, { RT } },
-{ "mfdbsr", XSPR(31,339,1008), XSPR_MASK, PPC403, { RT } },
-{ "mfdbcr0", XSPR(31,339,1010), XSPR_MASK, PPC405, { RT } },
-{ "mfiac1", XSPR(31,339,1012), XSPR_MASK, PPC403, { RT } },
-{ "mfiac2", XSPR(31,339,1013), XSPR_MASK, PPC403, { RT } },
-{ "mfdac1", XSPR(31,339,1014), XSPR_MASK, PPC403, { RT } },
-{ "mfdac2", XSPR(31,339,1015), XSPR_MASK, PPC403, { RT } },
-{ "mfdccr", XSPR(31,339,1018), XSPR_MASK, PPC403, { RT } },
-{ "mficcr", XSPR(31,339,1019), XSPR_MASK, PPC403, { RT } },
-{ "mfpbl1", XSPR(31,339,1020), XSPR_MASK, PPC403, { RT } },
-{ "mfpbu1", XSPR(31,339,1021), XSPR_MASK, PPC403, { RT } },
-{ "mfpbl2", XSPR(31,339,1022), XSPR_MASK, PPC403, { RT } },
-{ "mfpbu2", XSPR(31,339,1023), XSPR_MASK, PPC403, { RT } },
-{ "mfl2cr", XSPR(31,339,1017), XSPR_MASK, PPC750, { RT } },
-{ "mfictc", XSPR(31,339,1019), XSPR_MASK, PPC750, { RT } },
-{ "mfthrm1", XSPR(31,339,1020), XSPR_MASK, PPC750, { RT } },
-{ "mfthrm2", XSPR(31,339,1021), XSPR_MASK, PPC750, { RT } },
-{ "mfthrm3", XSPR(31,339,1022), XSPR_MASK, PPC750, { RT } },
-{ "mfspr", X(31,339), X_MASK, COM, { RT, SPR } },
-
-{ "lwax", X(31,341), X_MASK, PPC64, { RT, RA, RB } },
+{ "mficdbdr", XSPR(31,339,979), XSPR_MASK, PPC403, { RT } },
+{ "mfevpr", XSPR(31,339,982), XSPR_MASK, PPC403, { RT } },
+{ "mfcdbcr", XSPR(31,339,983), XSPR_MASK, PPC403, { RT } },
+{ "mfpit", XSPR(31,339,987), XSPR_MASK, PPC403, { RT } },
+{ "mftbhi", XSPR(31,339,988), XSPR_MASK, PPC403, { RT } },
+{ "mftblo", XSPR(31,339,989), XSPR_MASK, PPC403, { RT } },
+{ "mfsrr2", XSPR(31,339,990), XSPR_MASK, PPC403, { RT } },
+{ "mfsrr3", XSPR(31,339,991), XSPR_MASK, PPC403, { RT } },
+{ "mfl2cr", XSPR(31,339,1017), XSPR_MASK, PPC750, { RT } },
+{ "mfdccr", XSPR(31,339,1018), XSPR_MASK, PPC403, { RT } },
+{ "mficcr", XSPR(31,339,1019), XSPR_MASK, PPC403, { RT } },
+{ "mfictc", XSPR(31,339,1019), XSPR_MASK, PPC750, { RT } },
+{ "mfpbl1", XSPR(31,339,1020), XSPR_MASK, PPC403, { RT } },
+{ "mfthrm1", XSPR(31,339,1020), XSPR_MASK, PPC750, { RT } },
+{ "mfpbu1", XSPR(31,339,1021), XSPR_MASK, PPC403, { RT } },
+{ "mfthrm2", XSPR(31,339,1021), XSPR_MASK, PPC750, { RT } },
+{ "mfpbl2", XSPR(31,339,1022), XSPR_MASK, PPC403, { RT } },
+{ "mfthrm3", XSPR(31,339,1022), XSPR_MASK, PPC750, { RT } },
+{ "mfpbu2", XSPR(31,339,1023), XSPR_MASK, PPC403, { RT } },
+{ "mfspr", X(31,339), X_MASK, COM, { RT, SPR } },
+
+{ "lwax", X(31,341), X_MASK, PPC64, { RT, RA0, RB } },
{ "dst", XDSS(31,342,0), XDSS_MASK, PPCVEC, { RA, RB, STRM } },
{ "dstt", XDSS(31,342,1), XDSS_MASK, PPCVEC, { RA, RB, STRM } },
-{ "lhax", X(31,343), X_MASK, COM, { RT, RA, RB } },
+{ "lhax", X(31,343), X_MASK, COM, { RT, RA0, RB } },
-{ "lhaxe", X(31,351), X_MASK, BOOKE64, { RT, RA, RB } },
+{ "lhaxe", X(31,351), X_MASK, BOOKE64, { RT, RA0, RB } },
{ "dstst", XDSS(31,374,0), XDSS_MASK, PPCVEC, { RA, RB, STRM } },
{ "dststt", XDSS(31,374,1), XDSS_MASK, PPCVEC, { RA, RB, STRM } },
-{ "dccci", X(31,454), XRT_MASK, PPC403, { RA, RB } },
+{ "dccci", X(31,454), XRT_MASK, PPC403|PPC440, { RA, RB } },
{ "abs", XO(31,360,0,0), XORB_MASK, M601, { RT, RA } },
{ "abs.", XO(31,360,0,1), XORB_MASK, M601, { RT, RA } },
@@ -3296,10 +3798,6 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "tlbia", X(31,370), 0xffffffff, PPC, { 0 } },
-{ "mftbl", XSPR(31,371,268), XSPR_MASK, PPC, { RT } },
-{ "mftbu", XSPR(31,371,269), XSPR_MASK, PPC, { RT } },
-{ "mftb", X(31,371), X_MASK, PPC, { RT, TBR } },
-
{ "lwaux", X(31,373), X_MASK, PPC64, { RT, RAL, RB } },
{ "lhaux", X(31,375), X_MASK, COM, { RT, RAL, RB } },
@@ -3308,15 +3806,19 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "mtdcrx", X(31,387), X_MASK, BOOKE, { RA, RS } },
+{ "dcblc", X(31,390), X_MASK, PPCCHLK, { CT, RA, RB }},
+
{ "subfe64", XO(31,392,0,0), XO_MASK, BOOKE64, { RT, RA, RB } },
{ "subfe64o",XO(31,392,1,0), XO_MASK, BOOKE64, { RT, RA, RB } },
{ "adde64", XO(31,394,0,0), XO_MASK, BOOKE64, { RT, RA, RB } },
{ "adde64o", XO(31,394,1,0), XO_MASK, BOOKE64, { RT, RA, RB } },
+{ "dcblce", X(31,398), X_MASK, PPCCHLK64, { CT, RA, RB }},
+
{ "slbmte", X(31,402), XRA_MASK, PPC64, { RS, RB } },
-{ "sthx", X(31,407), X_MASK, COM, { RS, RA, RB } },
+{ "sthx", X(31,407), X_MASK, COM, { RS, RA0, RB } },
{ "lfqx", X(31,791), X_MASK, POWER2, { FRT, RA, RB } },
@@ -3332,7 +3834,7 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "sradi", XS(31,413,0), XS_MASK, PPC64, { RA, RS, SH6 } },
{ "sradi.", XS(31,413,1), XS_MASK, PPC64, { RA, RS, SH6 } },
-{ "sthxe", X(31,415), X_MASK, BOOKE64, { RS, RA, RB } },
+{ "sthxe", X(31,415), X_MASK, BOOKE64, { RS, RA0, RB } },
{ "slbie", X(31,434), XRTRA_MASK, PPC64, { RB } },
@@ -3347,42 +3849,41 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "mr.", XRC(31,444,1), X_MASK, COM, { RA, RS, RBS } },
{ "or.", XRC(31,444,1), X_MASK, COM, { RA, RS, RB } },
-{ "mtexisr", XSPR(31,451,64), XSPR_MASK, PPC403, { RT } },
-{ "mtexier", XSPR(31,451,66), XSPR_MASK, PPC403, { RT } },
-{ "mtbr0", XSPR(31,451,128), XSPR_MASK, PPC403, { RT } },
-{ "mtbr1", XSPR(31,451,129), XSPR_MASK, PPC403, { RT } },
-{ "mtbr2", XSPR(31,451,130), XSPR_MASK, PPC403, { RT } },
-{ "mtbr3", XSPR(31,451,131), XSPR_MASK, PPC403, { RT } },
-{ "mtbr4", XSPR(31,451,132), XSPR_MASK, PPC403, { RT } },
-{ "mtbr5", XSPR(31,451,133), XSPR_MASK, PPC403, { RT } },
-{ "mtbr6", XSPR(31,451,134), XSPR_MASK, PPC403, { RT } },
-{ "mtbr7", XSPR(31,451,135), XSPR_MASK, PPC403, { RT } },
-{ "mtbear", XSPR(31,451,144), XSPR_MASK, PPC403, { RT } },
-{ "mtbesr", XSPR(31,451,145), XSPR_MASK, PPC403, { RT } },
-{ "mtiocr", XSPR(31,451,160), XSPR_MASK, PPC403, { RT } },
-{ "mtdmacr0", XSPR(31,451,192), XSPR_MASK, PPC403, { RT } },
-{ "mtdmact0", XSPR(31,451,193), XSPR_MASK, PPC403, { RT } },
-{ "mtdmada0", XSPR(31,451,194), XSPR_MASK, PPC403, { RT } },
-{ "mtdmasa0", XSPR(31,451,195), XSPR_MASK, PPC403, { RT } },
-{ "mtdmacc0", XSPR(31,451,196), XSPR_MASK, PPC403, { RT } },
-{ "mtdmacr1", XSPR(31,451,200), XSPR_MASK, PPC403, { RT } },
-{ "mtdmact1", XSPR(31,451,201), XSPR_MASK, PPC403, { RT } },
-{ "mtdmada1", XSPR(31,451,202), XSPR_MASK, PPC403, { RT } },
-{ "mtdmasa1", XSPR(31,451,203), XSPR_MASK, PPC403, { RT } },
-{ "mtdmacc1", XSPR(31,451,204), XSPR_MASK, PPC403, { RT } },
-{ "mtdmacr2", XSPR(31,451,208), XSPR_MASK, PPC403, { RT } },
-{ "mtdmact2", XSPR(31,451,209), XSPR_MASK, PPC403, { RT } },
-{ "mtdmada2", XSPR(31,451,210), XSPR_MASK, PPC403, { RT } },
-{ "mtdmasa2", XSPR(31,451,211), XSPR_MASK, PPC403, { RT } },
-{ "mtdmacc2", XSPR(31,451,212), XSPR_MASK, PPC403, { RT } },
-{ "mtdmacr3", XSPR(31,451,216), XSPR_MASK, PPC403, { RT } },
-{ "mtdmact3", XSPR(31,451,217), XSPR_MASK, PPC403, { RT } },
-{ "mtdmada3", XSPR(31,451,218), XSPR_MASK, PPC403, { RT } },
-{ "mtdmasa3", XSPR(31,451,219), XSPR_MASK, PPC403, { RT } },
-{ "mtdmacc3", XSPR(31,451,220), XSPR_MASK, PPC403, { RT } },
-{ "mtdmasr", XSPR(31,451,224), XSPR_MASK, PPC403, { RT } },
-{ "mtdcr", X(31,451), X_MASK, PPC403, { SPR, RS } },
-{ "mtdcr", X(31,451), X_MASK, BOOKE, { SPR, RS } },
+{ "mtexisr", XSPR(31,451,64), XSPR_MASK, PPC403, { RS } },
+{ "mtexier", XSPR(31,451,66), XSPR_MASK, PPC403, { RS } },
+{ "mtbr0", XSPR(31,451,128), XSPR_MASK, PPC403, { RS } },
+{ "mtbr1", XSPR(31,451,129), XSPR_MASK, PPC403, { RS } },
+{ "mtbr2", XSPR(31,451,130), XSPR_MASK, PPC403, { RS } },
+{ "mtbr3", XSPR(31,451,131), XSPR_MASK, PPC403, { RS } },
+{ "mtbr4", XSPR(31,451,132), XSPR_MASK, PPC403, { RS } },
+{ "mtbr5", XSPR(31,451,133), XSPR_MASK, PPC403, { RS } },
+{ "mtbr6", XSPR(31,451,134), XSPR_MASK, PPC403, { RS } },
+{ "mtbr7", XSPR(31,451,135), XSPR_MASK, PPC403, { RS } },
+{ "mtbear", XSPR(31,451,144), XSPR_MASK, PPC403, { RS } },
+{ "mtbesr", XSPR(31,451,145), XSPR_MASK, PPC403, { RS } },
+{ "mtiocr", XSPR(31,451,160), XSPR_MASK, PPC403, { RS } },
+{ "mtdmacr0", XSPR(31,451,192), XSPR_MASK, PPC403, { RS } },
+{ "mtdmact0", XSPR(31,451,193), XSPR_MASK, PPC403, { RS } },
+{ "mtdmada0", XSPR(31,451,194), XSPR_MASK, PPC403, { RS } },
+{ "mtdmasa0", XSPR(31,451,195), XSPR_MASK, PPC403, { RS } },
+{ "mtdmacc0", XSPR(31,451,196), XSPR_MASK, PPC403, { RS } },
+{ "mtdmacr1", XSPR(31,451,200), XSPR_MASK, PPC403, { RS } },
+{ "mtdmact1", XSPR(31,451,201), XSPR_MASK, PPC403, { RS } },
+{ "mtdmada1", XSPR(31,451,202), XSPR_MASK, PPC403, { RS } },
+{ "mtdmasa1", XSPR(31,451,203), XSPR_MASK, PPC403, { RS } },
+{ "mtdmacc1", XSPR(31,451,204), XSPR_MASK, PPC403, { RS } },
+{ "mtdmacr2", XSPR(31,451,208), XSPR_MASK, PPC403, { RS } },
+{ "mtdmact2", XSPR(31,451,209), XSPR_MASK, PPC403, { RS } },
+{ "mtdmada2", XSPR(31,451,210), XSPR_MASK, PPC403, { RS } },
+{ "mtdmasa2", XSPR(31,451,211), XSPR_MASK, PPC403, { RS } },
+{ "mtdmacc2", XSPR(31,451,212), XSPR_MASK, PPC403, { RS } },
+{ "mtdmacr3", XSPR(31,451,216), XSPR_MASK, PPC403, { RS } },
+{ "mtdmact3", XSPR(31,451,217), XSPR_MASK, PPC403, { RS } },
+{ "mtdmada3", XSPR(31,451,218), XSPR_MASK, PPC403, { RS } },
+{ "mtdmasa3", XSPR(31,451,219), XSPR_MASK, PPC403, { RS } },
+{ "mtdmacc3", XSPR(31,451,220), XSPR_MASK, PPC403, { RS } },
+{ "mtdmasr", XSPR(31,451,224), XSPR_MASK, PPC403, { RS } },
+{ "mtdcr", X(31,451), X_MASK, PPC403 | BOOKE, { SPR, RS } },
{ "subfze64",XO(31,456,0,0), XORB_MASK, BOOKE64, { RT, RA } },
{ "subfze64o",XO(31,456,1,0), XORB_MASK, BOOKE64, { RT, RA } },
@@ -3400,110 +3901,158 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "divwuo", XO(31,459,1,0), XO_MASK, PPC, { RT, RA, RB } },
{ "divwuo.", XO(31,459,1,1), XO_MASK, PPC, { RT, RA, RB } },
-{ "mtmq", XSPR(31,467,0), XSPR_MASK, M601, { RS } },
-{ "mtxer", XSPR(31,467,1), XSPR_MASK, COM, { RS } },
-{ "mtlr", XSPR(31,467,8), XSPR_MASK, COM, { RS } },
-{ "mtctr", XSPR(31,467,9), XSPR_MASK, COM, { RS } },
-{ "mttid", XSPR(31,467,17), XSPR_MASK, POWER, { RS } },
-{ "mtdsisr", XSPR(31,467,18), XSPR_MASK, COM, { RS } },
-{ "mtdar", XSPR(31,467,19), XSPR_MASK, COM, { RS } },
-{ "mtrtcu", XSPR(31,467,20), XSPR_MASK, COM, { RS } },
-{ "mtrtcl", XSPR(31,467,21), XSPR_MASK, COM, { RS } },
-{ "mtdec", XSPR(31,467,22), XSPR_MASK, COM, { RS } },
-{ "mtsdr0", XSPR(31,467,24), XSPR_MASK, POWER, { RS } },
-{ "mtsdr1", XSPR(31,467,25), XSPR_MASK, COM, { RS } },
-{ "mtsrr0", XSPR(31,467,26), XSPR_MASK, COM, { RS } },
-{ "mtsrr1", XSPR(31,467,27), XSPR_MASK, COM, { RS } },
-{ "mtcmpa", XSPR(31,467,144), XSPR_MASK, PPC860, { RT } },
-{ "mtcmpb", XSPR(31,467,145), XSPR_MASK, PPC860, { RT } },
-{ "mtcmpc", XSPR(31,467,146), XSPR_MASK, PPC860, { RT } },
-{ "mtcmpd", XSPR(31,467,147), XSPR_MASK, PPC860, { RT } },
-{ "mticr", XSPR(31,467,148), XSPR_MASK, PPC860, { RT } },
-{ "mtder", XSPR(31,467,149), XSPR_MASK, PPC860, { RT } },
-{ "mtcounta", XSPR(31,467,150), XSPR_MASK, PPC860, { RT } },
-{ "mtcountb", XSPR(31,467,151), XSPR_MASK, PPC860, { RT } },
-{ "mtcmpe", XSPR(31,467,152), XSPR_MASK, PPC860, { RT } },
-{ "mtcmpf", XSPR(31,467,153), XSPR_MASK, PPC860, { RT } },
-{ "mtcmpg", XSPR(31,467,154), XSPR_MASK, PPC860, { RT } },
-{ "mtcmph", XSPR(31,467,155), XSPR_MASK, PPC860, { RT } },
-{ "mtlctrl1", XSPR(31,467,156), XSPR_MASK, PPC860, { RT } },
-{ "mtlctrl2", XSPR(31,467,157), XSPR_MASK, PPC860, { RT } },
-{ "mtictrl", XSPR(31,467,158), XSPR_MASK, PPC860, { RT } },
-{ "mtbar", XSPR(31,467,159), XSPR_MASK, PPC860, { RT } },
-{ "mtvrsave",XSPR(31,467,256), XSPR_MASK, PPCVEC, { RT } },
-{ "mtsprg", XSPR(31,467,272), XSPRG_MASK, PPC, { SPRG, RS } },
-{ "mtsprg0", XSPR(31,467,272), XSPR_MASK, PPC, { RT } },
-{ "mtsprg1", XSPR(31,467,273), XSPR_MASK, PPC, { RT } },
-{ "mtsprg2", XSPR(31,467,274), XSPR_MASK, PPC, { RT } },
-{ "mtsprg3", XSPR(31,467,275), XSPR_MASK, PPC, { RT } },
-{ "mtsprg4", XSPR(31,467,276), XSPR_MASK, PPC405, { RT } },
-{ "mtsprg5", XSPR(31,467,277), XSPR_MASK, PPC405, { RT } },
-{ "mtsprg6", XSPR(31,467,278), XSPR_MASK, PPC405, { RT } },
-{ "mtsprg7", XSPR(31,467,279), XSPR_MASK, PPC405, { RT } },
-{ "mtasr", XSPR(31,467,280), XSPR_MASK, PPC64, { RS } },
-{ "mtear", XSPR(31,467,282), XSPR_MASK, PPC, { RS } },
-{ "mttbl", XSPR(31,467,284), XSPR_MASK, PPC, { RS } },
-{ "mttbu", XSPR(31,467,285), XSPR_MASK, PPC, { RS } },
-{ "mtibatu", XSPR(31,467,528), XSPRBAT_MASK, PPC, { SPRBAT, RS } },
-{ "mtibatl", XSPR(31,467,529), XSPRBAT_MASK, PPC, { SPRBAT, RS } },
-{ "mtdbatu", XSPR(31,467,536), XSPRBAT_MASK, PPC, { SPRBAT, RS } },
-{ "mtdbatl", XSPR(31,467,537), XSPRBAT_MASK, PPC, { SPRBAT, RS } },
-{ "mtzpr", XSPR(31,467,944), XSPR_MASK, PPC403, { RT } },
-{ "mtpid", XSPR(31,467,945), XSPR_MASK, PPC403, { RT } },
-{ "mtccr0", XSPR(31,467,947), XSPR_MASK, PPC405, { RT } },
-{ "mtiac3", XSPR(31,467,948), XSPR_MASK, PPC405, { RT } },
-{ "mtiac4", XSPR(31,467,949), XSPR_MASK, PPC405, { RT } },
-{ "mtdvc1", XSPR(31,467,950), XSPR_MASK, PPC405, { RT } },
-{ "mtdvc2", XSPR(31,467,951), XSPR_MASK, PPC405, { RT } },
-{ "mtsgr", XSPR(31,467,953), XSPR_MASK, PPC403, { RT } },
-{ "mtdcwr", XSPR(31,467,954), XSPR_MASK, PPC403, { RT } },
-{ "mtsler", XSPR(31,467,955), XSPR_MASK, PPC405, { RT } },
-{ "mtsu0r", XSPR(31,467,956), XSPR_MASK, PPC405, { RT } },
-{ "mtdbcr1", XSPR(31,467,957), XSPR_MASK, PPC405, { RT } },
-{ "mticdbdr",XSPR(31,467,979), XSPR_MASK, PPC403, { RT } },
-{ "mtesr", XSPR(31,467,980), XSPR_MASK, PPC403, { RT } },
-{ "mtdear", XSPR(31,467,981), XSPR_MASK, PPC403, { RT } },
-{ "mtevpr", XSPR(31,467,982), XSPR_MASK, PPC403, { RT } },
-{ "mtcdbcr", XSPR(31,467,983), XSPR_MASK, PPC403, { RT } },
-{ "mttsr", XSPR(31,467,984), XSPR_MASK, PPC403, { RT } },
-{ "mttcr", XSPR(31,467,986), XSPR_MASK, PPC403, { RT } },
-{ "mtpit", XSPR(31,467,987), XSPR_MASK, PPC403, { RT } },
-{ "mttbhi", XSPR(31,467,988), XSPR_MASK, PPC403, { RT } },
-{ "mttblo", XSPR(31,467,989), XSPR_MASK, PPC403, { RT } },
-{ "mtsrr2", XSPR(31,467,990), XSPR_MASK, PPC403, { RT } },
-{ "mtsrr3", XSPR(31,467,991), XSPR_MASK, PPC403, { RT } },
-{ "mtdbsr", XSPR(31,467,1008), XSPR_MASK, PPC403, { RT } },
-{ "mtdbcr0", XSPR(31,467,1010), XSPR_MASK, PPC405, { RT } },
-{ "mtiac1", XSPR(31,467,1012), XSPR_MASK, PPC403, { RT } },
-{ "mtiac2", XSPR(31,467,1013), XSPR_MASK, PPC403, { RT } },
-{ "mtdac1", XSPR(31,467,1014), XSPR_MASK, PPC403, { RT } },
-{ "mtdac2", XSPR(31,467,1015), XSPR_MASK, PPC403, { RT } },
-{ "mtdccr", XSPR(31,467,1018), XSPR_MASK, PPC403, { RT } },
-{ "mticcr", XSPR(31,467,1019), XSPR_MASK, PPC403, { RT } },
-{ "mtpbl1", XSPR(31,467,1020), XSPR_MASK, PPC403, { RT } },
-{ "mtpbu1", XSPR(31,467,1021), XSPR_MASK, PPC403, { RT } },
-{ "mtpbl2", XSPR(31,467,1022), XSPR_MASK, PPC403, { RT } },
-{ "mtpbu2", XSPR(31,467,1023), XSPR_MASK, PPC403, { RT } },
-{ "mtummcr0", XSPR(31,467,936), XSPR_MASK, PPC750, { RT } },
-{ "mtupmc1", XSPR(31,467,937), XSPR_MASK, PPC750, { RT } },
-{ "mtupmc2", XSPR(31,467,938), XSPR_MASK, PPC750, { RT } },
-{ "mtusia", XSPR(31,467,939), XSPR_MASK, PPC750, { RT } },
-{ "mtummcr1", XSPR(31,467,940), XSPR_MASK, PPC750, { RT } },
-{ "mtupmc3", XSPR(31,467,941), XSPR_MASK, PPC750, { RT } },
-{ "mtupmc4", XSPR(31,467,942), XSPR_MASK, PPC750, { RT } },
-{ "mtmmcr0", XSPR(31,467,952), XSPR_MASK, PPC750, { RT } },
-{ "mtpmc1", XSPR(31,467,953), XSPR_MASK, PPC750, { RT } },
-{ "mtpmc2", XSPR(31,467,954), XSPR_MASK, PPC750, { RT } },
-{ "mtsia", XSPR(31,467,955), XSPR_MASK, PPC750, { RT } },
-{ "mtmmcr1", XSPR(31,467,956), XSPR_MASK, PPC750, { RT } },
-{ "mtpmc3", XSPR(31,467,957), XSPR_MASK, PPC750, { RT } },
-{ "mtpmc4", XSPR(31,467,958), XSPR_MASK, PPC750, { RT } },
-{ "mtl2cr", XSPR(31,467,1017), XSPR_MASK, PPC750, { RT } },
-{ "mtictc", XSPR(31,467,1019), XSPR_MASK, PPC750, { RT } },
-{ "mtthrm1", XSPR(31,467,1020), XSPR_MASK, PPC750, { RT } },
-{ "mtthrm2", XSPR(31,467,1021), XSPR_MASK, PPC750, { RT } },
-{ "mtthrm3", XSPR(31,467,1022), XSPR_MASK, PPC750, { RT } },
-{ "mtspr", X(31,467), X_MASK, COM, { SPR, RS } },
+{ "mtmq", XSPR(31,467,0), XSPR_MASK, M601, { RS } },
+{ "mtxer", XSPR(31,467,1), XSPR_MASK, COM, { RS } },
+{ "mtlr", XSPR(31,467,8), XSPR_MASK, COM, { RS } },
+{ "mtctr", XSPR(31,467,9), XSPR_MASK, COM, { RS } },
+{ "mttid", XSPR(31,467,17), XSPR_MASK, POWER, { RS } },
+{ "mtdsisr", XSPR(31,467,18), XSPR_MASK, COM, { RS } },
+{ "mtdar", XSPR(31,467,19), XSPR_MASK, COM, { RS } },
+{ "mtrtcu", XSPR(31,467,20), XSPR_MASK, COM, { RS } },
+{ "mtrtcl", XSPR(31,467,21), XSPR_MASK, COM, { RS } },
+{ "mtdec", XSPR(31,467,22), XSPR_MASK, COM, { RS } },
+{ "mtsdr0", XSPR(31,467,24), XSPR_MASK, POWER, { RS } },
+{ "mtsdr1", XSPR(31,467,25), XSPR_MASK, COM, { RS } },
+{ "mtsrr0", XSPR(31,467,26), XSPR_MASK, COM, { RS } },
+{ "mtsrr1", XSPR(31,467,27), XSPR_MASK, COM, { RS } },
+{ "mtpid", XSPR(31,467,48), XSPR_MASK, BOOKE, { RS } },
+{ "mtpid", XSPR(31,467,945), XSPR_MASK, PPC403, { RS } },
+{ "mtdecar", XSPR(31,467,54), XSPR_MASK, BOOKE, { RS } },
+{ "mtcsrr0", XSPR(31,467,58), XSPR_MASK, BOOKE, { RS } },
+{ "mtcsrr1", XSPR(31,467,59), XSPR_MASK, BOOKE, { RS } },
+{ "mtdear", XSPR(31,467,61), XSPR_MASK, BOOKE, { RS } },
+{ "mtdear", XSPR(31,467,981), XSPR_MASK, PPC403, { RS } },
+{ "mtesr", XSPR(31,467,62), XSPR_MASK, BOOKE, { RS } },
+{ "mtesr", XSPR(31,467,980), XSPR_MASK, PPC403, { RS } },
+{ "mtivpr", XSPR(31,467,63), XSPR_MASK, BOOKE, { RS } },
+{ "mtcmpa", XSPR(31,467,144), XSPR_MASK, PPC860, { RS } },
+{ "mtcmpb", XSPR(31,467,145), XSPR_MASK, PPC860, { RS } },
+{ "mtcmpc", XSPR(31,467,146), XSPR_MASK, PPC860, { RS } },
+{ "mtcmpd", XSPR(31,467,147), XSPR_MASK, PPC860, { RS } },
+{ "mticr", XSPR(31,467,148), XSPR_MASK, PPC860, { RS } },
+{ "mtder", XSPR(31,467,149), XSPR_MASK, PPC860, { RS } },
+{ "mtcounta", XSPR(31,467,150), XSPR_MASK, PPC860, { RS } },
+{ "mtcountb", XSPR(31,467,151), XSPR_MASK, PPC860, { RS } },
+{ "mtcmpe", XSPR(31,467,152), XSPR_MASK, PPC860, { RS } },
+{ "mtcmpf", XSPR(31,467,153), XSPR_MASK, PPC860, { RS } },
+{ "mtcmpg", XSPR(31,467,154), XSPR_MASK, PPC860, { RS } },
+{ "mtcmph", XSPR(31,467,155), XSPR_MASK, PPC860, { RS } },
+{ "mtlctrl1", XSPR(31,467,156), XSPR_MASK, PPC860, { RS } },
+{ "mtlctrl2", XSPR(31,467,157), XSPR_MASK, PPC860, { RS } },
+{ "mtictrl", XSPR(31,467,158), XSPR_MASK, PPC860, { RS } },
+{ "mtbar", XSPR(31,467,159), XSPR_MASK, PPC860, { RS } },
+{ "mtvrsave", XSPR(31,467,256), XSPR_MASK, PPCVEC, { RS } },
+{ "mtusprg0", XSPR(31,467,256), XSPR_MASK, BOOKE, { RS } },
+{ "mtsprg", XSPR(31,467,272), XSPRG_MASK,PPC, { SPRG, RS } },
+{ "mtsprg0", XSPR(31,467,272), XSPR_MASK, PPC, { RS } },
+{ "mtsprg1", XSPR(31,467,273), XSPR_MASK, PPC, { RS } },
+{ "mtsprg2", XSPR(31,467,274), XSPR_MASK, PPC, { RS } },
+{ "mtsprg3", XSPR(31,467,275), XSPR_MASK, PPC, { RS } },
+{ "mtsprg4", XSPR(31,467,276), XSPR_MASK, PPC405 | BOOKE, { RS } },
+{ "mtsprg5", XSPR(31,467,277), XSPR_MASK, PPC405 | BOOKE, { RS } },
+{ "mtsprg6", XSPR(31,467,278), XSPR_MASK, PPC405 | BOOKE, { RS } },
+{ "mtsprg7", XSPR(31,467,279), XSPR_MASK, PPC405 | BOOKE, { RS } },
+{ "mtasr", XSPR(31,467,280), XSPR_MASK, PPC64, { RS } },
+{ "mtear", XSPR(31,467,282), XSPR_MASK, PPC, { RS } },
+{ "mttbl", XSPR(31,467,284), XSPR_MASK, PPC, { RS } },
+{ "mttbu", XSPR(31,467,285), XSPR_MASK, PPC, { RS } },
+{ "mtdbsr", XSPR(31,467,304), XSPR_MASK, BOOKE, { RS } },
+{ "mtdbsr", XSPR(31,467,1008), XSPR_MASK, PPC403, { RS } },
+{ "mtdbcr0", XSPR(31,467,308), XSPR_MASK, BOOKE, { RS } },
+{ "mtdbcr0", XSPR(31,467,1010), XSPR_MASK, PPC405, { RS } },
+{ "mtdbcr1", XSPR(31,467,309), XSPR_MASK, BOOKE, { RS } },
+{ "mtdbcr1", XSPR(31,467,957), XSPR_MASK, PPC405, { RS } },
+{ "mtdbcr2", XSPR(31,467,310), XSPR_MASK, BOOKE, { RS } },
+{ "mtiac1", XSPR(31,467,312), XSPR_MASK, BOOKE, { RS } },
+{ "mtiac1", XSPR(31,467,1012), XSPR_MASK, PPC403, { RS } },
+{ "mtiac2", XSPR(31,467,313), XSPR_MASK, BOOKE, { RS } },
+{ "mtiac2", XSPR(31,467,1013), XSPR_MASK, PPC403, { RS } },
+{ "mtiac3", XSPR(31,467,314), XSPR_MASK, BOOKE, { RS } },
+{ "mtiac3", XSPR(31,467,948), XSPR_MASK, PPC405, { RS } },
+{ "mtiac4", XSPR(31,467,315), XSPR_MASK, BOOKE, { RS } },
+{ "mtiac4", XSPR(31,467,949), XSPR_MASK, PPC405, { RS } },
+{ "mtdac1", XSPR(31,467,316), XSPR_MASK, BOOKE, { RS } },
+{ "mtdac1", XSPR(31,467,1014), XSPR_MASK, PPC403, { RS } },
+{ "mtdac2", XSPR(31,467,317), XSPR_MASK, BOOKE, { RS } },
+{ "mtdac2", XSPR(31,467,1015), XSPR_MASK, PPC403, { RS } },
+{ "mtdvc1", XSPR(31,467,318), XSPR_MASK, BOOKE, { RS } },
+{ "mtdvc1", XSPR(31,467,950), XSPR_MASK, PPC405, { RS } },
+{ "mtdvc2", XSPR(31,467,319), XSPR_MASK, BOOKE, { RS } },
+{ "mtdvc2", XSPR(31,467,951), XSPR_MASK, PPC405, { RS } },
+{ "mttsr", XSPR(31,467,336), XSPR_MASK, BOOKE, { RS } },
+{ "mttsr", XSPR(31,467,984), XSPR_MASK, PPC403, { RS } },
+{ "mttcr", XSPR(31,467,340), XSPR_MASK, BOOKE, { RS } },
+{ "mttcr", XSPR(31,467,986), XSPR_MASK, PPC403, { RS } },
+{ "mtivor0", XSPR(31,467,400), XSPR_MASK, BOOKE, { RS } },
+{ "mtivor1", XSPR(31,467,401), XSPR_MASK, BOOKE, { RS } },
+{ "mtivor2", XSPR(31,467,402), XSPR_MASK, BOOKE, { RS } },
+{ "mtivor3", XSPR(31,467,403), XSPR_MASK, BOOKE, { RS } },
+{ "mtivor4", XSPR(31,467,404), XSPR_MASK, BOOKE, { RS } },
+{ "mtivor5", XSPR(31,467,405), XSPR_MASK, BOOKE, { RS } },
+{ "mtivor6", XSPR(31,467,406), XSPR_MASK, BOOKE, { RS } },
+{ "mtivor7", XSPR(31,467,407), XSPR_MASK, BOOKE, { RS } },
+{ "mtivor8", XSPR(31,467,408), XSPR_MASK, BOOKE, { RS } },
+{ "mtivor9", XSPR(31,467,409), XSPR_MASK, BOOKE, { RS } },
+{ "mtivor10", XSPR(31,467,410), XSPR_MASK, BOOKE, { RS } },
+{ "mtivor11", XSPR(31,467,411), XSPR_MASK, BOOKE, { RS } },
+{ "mtivor12", XSPR(31,467,412), XSPR_MASK, BOOKE, { RS } },
+{ "mtivor13", XSPR(31,467,413), XSPR_MASK, BOOKE, { RS } },
+{ "mtivor14", XSPR(31,467,414), XSPR_MASK, BOOKE, { RS } },
+{ "mtivor15", XSPR(31,467,415), XSPR_MASK, BOOKE, { RS } },
+{ "mtspefscr", XSPR(31,467,512), XSPR_MASK, PPCSPE, { RS } },
+{ "mtbbear", XSPR(31,467,513), XSPR_MASK, PPCBRLK, { RS } },
+{ "mtbbtar", XSPR(31,467,514), XSPR_MASK, PPCBRLK, { RS } },
+{ "mtivor32", XSPR(31,467,528), XSPR_MASK, PPCSPE, { RS } },
+{ "mtivor33", XSPR(31,467,529), XSPR_MASK, PPCSPE, { RS } },
+{ "mtivor34", XSPR(31,467,530), XSPR_MASK, PPCSPE, { RS } },
+{ "mtivor35", XSPR(31,467,531), XSPR_MASK, PPCPMR, { RS } },
+{ "mtibatu", XSPR(31,467,528), XSPRBAT_MASK, PPC, { SPRBAT, RS } },
+{ "mtibatl", XSPR(31,467,529), XSPRBAT_MASK, PPC, { SPRBAT, RS } },
+{ "mtdbatu", XSPR(31,467,536), XSPRBAT_MASK, PPC, { SPRBAT, RS } },
+{ "mtdbatl", XSPR(31,467,537), XSPRBAT_MASK, PPC, { SPRBAT, RS } },
+{ "mtmcsrr0", XSPR(31,467,570), XSPR_MASK, PPCRFMCI, { RS } },
+{ "mtmcsrr1", XSPR(31,467,571), XSPR_MASK, PPCRFMCI, { RS } },
+{ "mtmcsr", XSPR(31,467,572), XSPR_MASK, PPCRFMCI, { RS } },
+{ "mtummcr0", XSPR(31,467,936), XSPR_MASK, PPC750, { RS } },
+{ "mtupmc1", XSPR(31,467,937), XSPR_MASK, PPC750, { RS } },
+{ "mtupmc2", XSPR(31,467,938), XSPR_MASK, PPC750, { RS } },
+{ "mtusia", XSPR(31,467,939), XSPR_MASK, PPC750, { RS } },
+{ "mtummcr1", XSPR(31,467,940), XSPR_MASK, PPC750, { RS } },
+{ "mtupmc3", XSPR(31,467,941), XSPR_MASK, PPC750, { RS } },
+{ "mtupmc4", XSPR(31,467,942), XSPR_MASK, PPC750, { RS } },
+{ "mtzpr", XSPR(31,467,944), XSPR_MASK, PPC403, { RS } },
+{ "mtccr0", XSPR(31,467,947), XSPR_MASK, PPC405, { RS } },
+{ "mtmmcr0", XSPR(31,467,952), XSPR_MASK, PPC750, { RS } },
+{ "mtsgr", XSPR(31,467,953), XSPR_MASK, PPC403, { RS } },
+{ "mtpmc1", XSPR(31,467,953), XSPR_MASK, PPC750, { RS } },
+{ "mtdcwr", XSPR(31,467,954), XSPR_MASK, PPC403, { RS } },
+{ "mtpmc2", XSPR(31,467,954), XSPR_MASK, PPC750, { RS } },
+{ "mtsler", XSPR(31,467,955), XSPR_MASK, PPC405, { RS } },
+{ "mtsia", XSPR(31,467,955), XSPR_MASK, PPC750, { RS } },
+{ "mtsu0r", XSPR(31,467,956), XSPR_MASK, PPC405, { RS } },
+{ "mtmmcr1", XSPR(31,467,956), XSPR_MASK, PPC750, { RS } },
+{ "mtpmc3", XSPR(31,467,957), XSPR_MASK, PPC750, { RS } },
+{ "mtpmc4", XSPR(31,467,958), XSPR_MASK, PPC750, { RS } },
+{ "mticdbdr", XSPR(31,467,979), XSPR_MASK, PPC403, { RS } },
+{ "mtevpr", XSPR(31,467,982), XSPR_MASK, PPC403, { RS } },
+{ "mtcdbcr", XSPR(31,467,983), XSPR_MASK, PPC403, { RS } },
+{ "mtpit", XSPR(31,467,987), XSPR_MASK, PPC403, { RS } },
+{ "mttbhi", XSPR(31,467,988), XSPR_MASK, PPC403, { RS } },
+{ "mttblo", XSPR(31,467,989), XSPR_MASK, PPC403, { RS } },
+{ "mtsrr2", XSPR(31,467,990), XSPR_MASK, PPC403, { RS } },
+{ "mtsrr3", XSPR(31,467,991), XSPR_MASK, PPC403, { RS } },
+{ "mtl2cr", XSPR(31,467,1017), XSPR_MASK, PPC750, { RS } },
+{ "mtdccr", XSPR(31,467,1018), XSPR_MASK, PPC403, { RS } },
+{ "mticcr", XSPR(31,467,1019), XSPR_MASK, PPC403, { RS } },
+{ "mtictc", XSPR(31,467,1019), XSPR_MASK, PPC750, { RS } },
+{ "mtpbl1", XSPR(31,467,1020), XSPR_MASK, PPC403, { RS } },
+{ "mtthrm1", XSPR(31,467,1020), XSPR_MASK, PPC750, { RS } },
+{ "mtpbu1", XSPR(31,467,1021), XSPR_MASK, PPC403, { RS } },
+{ "mtthrm2", XSPR(31,467,1021), XSPR_MASK, PPC750, { RS } },
+{ "mtpbl2", XSPR(31,467,1022), XSPR_MASK, PPC403, { RS } },
+{ "mtthrm3", XSPR(31,467,1022), XSPR_MASK, PPC750, { RS } },
+{ "mtpbu2", XSPR(31,467,1023), XSPR_MASK, PPC403, { RS } },
+{ "mtspr", X(31,467), X_MASK, COM, { SPR, RS } },
{ "dcbi", X(31,470), XRT_MASK, PPC, { RA, RB } },
@@ -3512,7 +4061,11 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "dcbie", X(31,478), XRT_MASK, BOOKE64, { RA, RB } },
-{ "dcread", X(31,486), X_MASK, PPC403, { RT, RA, RB }},
+{ "dcread", X(31,486), X_MASK, PPC403|PPC440, { RT, RA, RB }},
+
+{ "mtpmr", X(31,462), X_MASK, PPCPMR, { PMR, RS }},
+
+{ "icbtls", X(31,486), X_MASK, PPCCHLK, { CT, RA, RB }},
{ "nabs", XO(31,488,0,0), XORB_MASK, M601, { RT, RA } },
{ "subfme64",XO(31,488,0,0), XORB_MASK, BOOKE64, { RT, RA } },
@@ -3534,6 +4087,8 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "divwo", XO(31,491,1,0), XO_MASK, PPC, { RT, RA, RB } },
{ "divwo.", XO(31,491,1,1), XO_MASK, PPC, { RT, RA, RB } },
+{ "icbtlse", X(31,494), X_MASK, PPCCHLK64, { CT, RA, RB }},
+
{ "slbia", X(31,498), 0xffffffff, PPC64, { 0 } },
{ "cli", X(31,502), XRB_MASK, POWER, { RT, RA } },
@@ -3542,17 +4097,18 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "mcrxr", X(31,512), XRARB_MASK|(3<<21), COM, { BF } },
-{ "mcrxr64", X(31,544), XRARB_MASK|(3<<21), BOOKE, { BF } },
+{ "bblels", X(31,518), X_MASK, PPCBRLK, { 0 }},
+{ "mcrxr64", X(31,544), XRARB_MASK|(3<<21), BOOKE64, { BF } },
{ "clcs", X(31,531), XRB_MASK, M601, { RT, RA } },
-{ "lswx", X(31,533), X_MASK, PPCCOM, { RT, RA, RB } },
+{ "lswx", X(31,533), X_MASK, PPCCOM, { RT, RA0, RB } },
{ "lsx", X(31,533), X_MASK, PWRCOM, { RT, RA, RB } },
-{ "lwbrx", X(31,534), X_MASK, PPCCOM, { RT, RA, RB } },
+{ "lwbrx", X(31,534), X_MASK, PPCCOM, { RT, RA0, RB } },
{ "lbrx", X(31,534), X_MASK, PWRCOM, { RT, RA, RB } },
-{ "lfsx", X(31,535), X_MASK, COM, { FRT, RA, RB } },
+{ "lfsx", X(31,535), X_MASK, COM, { FRT, RA0, RB } },
{ "srw", XRC(31,536,0), X_MASK, PPCCOM, { RA, RS, RB } },
{ "sr", XRC(31,536,0), X_MASK, PWRCOM, { RA, RS, RB } },
@@ -3568,9 +4124,11 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "maskir", XRC(31,541,0), X_MASK, M601, { RA, RS, RB } },
{ "maskir.", XRC(31,541,1), X_MASK, M601, { RA, RS, RB } },
-{ "lwbrxe", X(31,542), X_MASK, BOOKE64, { RT, RA, RB } },
+{ "lwbrxe", X(31,542), X_MASK, BOOKE64, { RT, RA0, RB } },
+
+{ "lfsxe", X(31,543), X_MASK, BOOKE64, { FRT, RA0, RB } },
-{ "lfsxe", X(31,543), X_MASK, BOOKE64, { FRT, RA, RB } },
+{ "bbelr", X(31,550), X_MASK, PPCBRLK, { 0 }},
{ "tlbsync", X(31,566), 0xffffffff, PPC, { 0 } },
@@ -3580,18 +4138,18 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "mfsr", X(31,595), XRB_MASK|(1<<20), COM32, { RT, SR } },
-{ "lswi", X(31,597), X_MASK, PPCCOM, { RT, RA, NB } },
-{ "lsi", X(31,597), X_MASK, PWRCOM, { RT, RA, NB } },
+{ "lswi", X(31,597), X_MASK, PPCCOM, { RT, RA0, NB } },
+{ "lsi", X(31,597), X_MASK, PWRCOM, { RT, RA0, NB } },
-{ "lwsync", XSYNC(31,598,1), 0xffffffff, PPCONLY, { 0 } },
+{ "lwsync", XSYNC(31,598,1), 0xffffffff, PPC, { 0 } },
{ "ptesync", XSYNC(31,598,2), 0xffffffff, PPC64, { 0 } },
+{ "msync", X(31,598), 0xffffffff, BOOKE, { 0 } },
{ "sync", X(31,598), XSYNC_MASK, PPCCOM, { LS } },
{ "dcs", X(31,598), 0xffffffff, PWRCOM, { 0 } },
-{ "msync", X(31,598), 0xf80007fe, BOOKE, { 0 } },
-{ "lfdx", X(31,599), X_MASK, COM, { FRT, RA, RB } },
+{ "lfdx", X(31,599), X_MASK, COM, { FRT, RA0, RB } },
-{ "lfdxe", X(31,607), X_MASK, BOOKE64, { FRT, RA, RB } },
+{ "lfdxe", X(31,607), X_MASK, BOOKE64, { FRT, RA0, RB } },
{ "mfsri", X(31,627), X_MASK, PWRCOM, { RT, RA, RB } },
@@ -3603,13 +4161,13 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "mfsrin", X(31,659), XRA_MASK, PPC32, { RT, RB } },
-{ "stswx", X(31,661), X_MASK, PPCCOM, { RS, RA, RB } },
-{ "stsx", X(31,661), X_MASK, PWRCOM, { RS, RA, RB } },
+{ "stswx", X(31,661), X_MASK, PPCCOM, { RS, RA0, RB } },
+{ "stsx", X(31,661), X_MASK, PWRCOM, { RS, RA0, RB } },
-{ "stwbrx", X(31,662), X_MASK, PPCCOM, { RS, RA, RB } },
-{ "stbrx", X(31,662), X_MASK, PWRCOM, { RS, RA, RB } },
+{ "stwbrx", X(31,662), X_MASK, PPCCOM, { RS, RA0, RB } },
+{ "stbrx", X(31,662), X_MASK, PWRCOM, { RS, RA0, RB } },
-{ "stfsx", X(31,663), X_MASK, COM, { FRS, RA, RB } },
+{ "stfsx", X(31,663), X_MASK, COM, { FRS, RA0, RB } },
{ "srq", XRC(31,664,0), X_MASK, M601, { RA, RS, RB } },
{ "srq.", XRC(31,664,1), X_MASK, M601, { RA, RS, RB } },
@@ -3617,9 +4175,9 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "sre", XRC(31,665,0), X_MASK, M601, { RA, RS, RB } },
{ "sre.", XRC(31,665,1), X_MASK, M601, { RA, RS, RB } },
-{ "stwbrxe", X(31,670), X_MASK, BOOKE64, { RS, RA, RB } },
+{ "stwbrxe", X(31,670), X_MASK, BOOKE64, { RS, RA0, RB } },
-{ "stfsxe", X(31,671), X_MASK, BOOKE64, { FRS, RA, RB } },
+{ "stfsxe", X(31,671), X_MASK, BOOKE64, { FRS, RA0, RB } },
{ "stfsux", X(31,695), X_MASK, COM, { FRS, RAS, RB } },
@@ -3628,10 +4186,10 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "stfsuxe", X(31,703), X_MASK, BOOKE64, { FRS, RAS, RB } },
-{ "stswi", X(31,725), X_MASK, PPCCOM, { RS, RA, NB } },
-{ "stsi", X(31,725), X_MASK, PWRCOM, { RS, RA, NB } },
+{ "stswi", X(31,725), X_MASK, PPCCOM, { RS, RA0, NB } },
+{ "stsi", X(31,725), X_MASK, PWRCOM, { RS, RA0, NB } },
-{ "stfdx", X(31,727), X_MASK, COM, { FRS, RA, RB } },
+{ "stfdx", X(31,727), X_MASK, COM, { FRS, RA0, RB } },
{ "srlq", XRC(31,728,0), X_MASK, M601, { RA, RS, RB } },
{ "srlq.", XRC(31,728,1), X_MASK, M601, { RA, RS, RB } },
@@ -3639,10 +4197,9 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "sreq", XRC(31,729,0), X_MASK, M601, { RA, RS, RB } },
{ "sreq.", XRC(31,729,1), X_MASK, M601, { RA, RS, RB } },
-{ "stfdxe", X(31,735), X_MASK, BOOKE64, { FRS, RA, RB } },
+{ "stfdxe", X(31,735), X_MASK, BOOKE64, { FRS, RA0, RB } },
-{ "dcba", X(31,758), XRT_MASK, PPC405, { RA, RB } },
-{ "dcba", X(31,758), XRT_MASK, BOOKE, { RA, RB } },
+{ "dcba", X(31,758), XRT_MASK, PPC405 | BOOKE, { RA, RB } },
{ "stfdux", X(31,759), X_MASK, COM, { FRS, RAS, RB } },
@@ -3654,9 +4211,9 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "stfduxe", X(31,767), X_MASK, BOOKE64, { FRS, RAS, RB } },
{ "tlbivax", X(31,786), XRT_MASK, BOOKE, { RA, RB } },
-{ "tlbivaxe",X(31,787), XRT_MASK, BOOKE, { RA, RB } },
+{ "tlbivaxe",X(31,787), XRT_MASK, BOOKE64, { RA, RB } },
-{ "lhbrx", X(31,790), X_MASK, COM, { RT, RA, RB } },
+{ "lhbrx", X(31,790), X_MASK, COM, { RT, RA0, RB } },
{ "sraw", XRC(31,792,0), X_MASK, PPCCOM, { RA, RS, RB } },
{ "sra", XRC(31,792,0), X_MASK, PWRCOM, { RA, RS, RB } },
@@ -3666,10 +4223,10 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "srad", XRC(31,794,0), X_MASK, PPC64, { RA, RS, RB } },
{ "srad.", XRC(31,794,1), X_MASK, PPC64, { RA, RS, RB } },
-{ "lhbrxe", X(31,798), X_MASK, BOOKE64, { RT, RA, RB } },
+{ "lhbrxe", X(31,798), X_MASK, BOOKE64, { RT, RA0, RB } },
-{ "ldxe", X(31,799), X_MASK, BOOKE64, { RT, RA, RB } },
-{ "lduxe", X(31,831), X_MASK, BOOKE64, { RT, RA, RB } },
+{ "ldxe", X(31,799), X_MASK, BOOKE64, { RT, RA0, RB } },
+{ "lduxe", X(31,831), X_MASK, BOOKE64, { RT, RA0, RB } },
{ "rac", X(31,818), X_MASK, PWRCOM, { RT, RA, RB } },
@@ -3683,20 +4240,19 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "slbmfev", X(31,851), XRA_MASK, PPC64, { RT, RB } },
+{ "mbar", X(31,854), X_MASK, BOOKE, { MO } },
{ "eieio", X(31,854), 0xffffffff, PPC, { 0 } },
-{ "mbar", X(31,854), 0xffffffff, BOOKE, { MO } },
-
-{ "tlbsx", XRC(31,914,0), X_MASK, PPC403, { RT, RA, RB } },
-{ "tlbsx.", XRC(31,914,1), X_MASK, PPC403, { RT, RA, RB } },
{ "tlbsx", XRC(31,914,0), X_MASK, BOOKE, { RA, RB } },
+{ "tlbsx", XRC(31,914,0), X_MASK, PPC403, { RT, RA, RB } },
{ "tlbsx.", XRC(31,914,1), X_MASK, BOOKE, { RA, RB } },
-{ "tlbsxe", XRC(31,915,0), X_MASK, BOOKE, { RA, RB } },
-{ "tlbsxe.", XRC(31,915,1), X_MASK, BOOKE, { RA, RB } },
+{ "tlbsx.", XRC(31,914,1), X_MASK, PPC403, { RT, RA, RB } },
+{ "tlbsxe", XRC(31,915,0), X_MASK, BOOKE64, { RA, RB } },
+{ "tlbsxe.", XRC(31,915,1), X_MASK, BOOKE64, { RA, RB } },
{ "slbmfee", X(31,915), XRA_MASK, PPC64, { RT, RB } },
-{ "sthbrx", X(31,918), X_MASK, COM, { RS, RA, RB } },
+{ "sthbrx", X(31,918), X_MASK, COM, { RS, RA0, RB } },
{ "sraq", XRC(31,920,0), X_MASK, M601, { RA, RS, RB } },
{ "sraq.", XRC(31,920,1), X_MASK, M601, { RA, RS, RB } },
@@ -3709,14 +4265,14 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "extsh.", XRC(31,922,1), XRB_MASK, PPCCOM, { RA, RS } },
{ "exts.", XRC(31,922,1), XRB_MASK, PWRCOM, { RA, RS } },
-{ "sthbrxe", X(31,926), X_MASK, BOOKE64, { RS, RA, RB } },
-
-{ "stdxe", X(31,927), X_MASK, BOOKE64, { RS, RA, RB } },
+{ "sthbrxe", X(31,926), X_MASK, BOOKE64, { RS, RA0, RB } },
-{ "tlbre", X(31,946), X_MASK, BOOKE, { 0 } },
+{ "stdxe", X(31,927), X_MASK, BOOKE64, { RS, RA0, RB } },
{ "tlbrehi", XTLB(31,946,0), XTLB_MASK, PPC403, { RT, RA } },
{ "tlbrelo", XTLB(31,946,1), XTLB_MASK, PPC403, { RT, RA } },
+{ "tlbre", X(31,946), X_MASK, BOOKE, { 0 } },
+{ "tlbre", X(31,946), X_MASK, PPC403, { RS, RA, SH } },
{ "sraiq", XRC(31,952,0), X_MASK, M601, { RA, RS, SH } },
{ "sraiq.", XRC(31,952,1), X_MASK, M601, { RA, RS, SH } },
@@ -3726,27 +4282,24 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "stduxe", X(31,959), X_MASK, BOOKE64, { RS, RAS, RB } },
-{ "iccci", X(31,966), XRT_MASK, PPC403, { RA, RB } },
-
-{ "tlbwe", X(31,978), X_MASK, BOOKE, { 0 } },
-
-{ "tlbld", X(31,978), XRTRA_MASK, PPC, { RB } },
+{ "iccci", X(31,966), XRT_MASK, PPC403|PPC440, { RA, RB } },
{ "tlbwehi", XTLB(31,978,0), XTLB_MASK, PPC403, { RT, RA } },
{ "tlbwelo", XTLB(31,978,1), XTLB_MASK, PPC403, { RT, RA } },
-{ "tlbwe", X(31,978), X_MASK, PPC403, { RS, RA, SH } },
+{ "tlbwe", X(31,978), X_MASK, PPC403|BOOKE, { RSO, RAOPT, SHO } },
+{ "tlbld", X(31,978), XRTRA_MASK, PPC, { RB } },
{ "icbi", X(31,982), XRT_MASK, PPC, { RA, RB } },
-{ "stfiwx", X(31,983), X_MASK, PPC, { FRS, RA, RB } },
+{ "stfiwx", X(31,983), X_MASK, PPC, { FRS, RA0, RB } },
-{ "extsw", XRC(31,986,0), XRB_MASK, PPC | BOOKE64, { RA, RS } },
-{ "extsw.", XRC(31,986,1), XRB_MASK, PPC | BOOKE64, { RA, RS } },
+{ "extsw", XRC(31,986,0), XRB_MASK, PPC64 | BOOKE64,{ RA, RS } },
+{ "extsw.", XRC(31,986,1), XRB_MASK, PPC64, { RA, RS } },
-{ "icread", X(31,998), XRT_MASK, PPC403, { RA, RB } },
+{ "icread", X(31,998), XRT_MASK, PPC403|PPC440, { RA, RB } },
{ "icbie", X(31,990), XRT_MASK, BOOKE64, { RA, RB } },
-{ "stfiwxe", X(31,991), X_MASK, BOOKE64, { FRS, RA, RB } },
+{ "stfiwxe", X(31,991), X_MASK, BOOKE64, { FRS, RA0, RB } },
{ "tlbli", X(31,1010), XRTRA_MASK, PPC, { RB } },
@@ -3768,84 +4321,86 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "stvx", X(31, 231), X_MASK, PPCVEC, { VS, RA, RB } },
{ "stvxl", X(31, 487), X_MASK, PPCVEC, { VS, RA, RB } },
-{ "lwz", OP(32), OP_MASK, PPCCOM, { RT, D, RA } },
-{ "l", OP(32), OP_MASK, PWRCOM, { RT, D, RA } },
+{ "lwz", OP(32), OP_MASK, PPCCOM, { RT, D, RA0 } },
+{ "l", OP(32), OP_MASK, PWRCOM, { RT, D, RA0 } },
{ "lwzu", OP(33), OP_MASK, PPCCOM, { RT, D, RAL } },
-{ "lu", OP(33), OP_MASK, PWRCOM, { RT, D, RA } },
+{ "lu", OP(33), OP_MASK, PWRCOM, { RT, D, RA0 } },
-{ "lbz", OP(34), OP_MASK, COM, { RT, D, RA } },
+{ "lbz", OP(34), OP_MASK, COM, { RT, D, RA0 } },
{ "lbzu", OP(35), OP_MASK, COM, { RT, D, RAL } },
-{ "stw", OP(36), OP_MASK, PPCCOM, { RS, D, RA } },
-{ "st", OP(36), OP_MASK, PWRCOM, { RS, D, RA } },
+{ "stw", OP(36), OP_MASK, PPCCOM, { RS, D, RA0 } },
+{ "st", OP(36), OP_MASK, PWRCOM, { RS, D, RA0 } },
{ "stwu", OP(37), OP_MASK, PPCCOM, { RS, D, RAS } },
-{ "stu", OP(37), OP_MASK, PWRCOM, { RS, D, RA } },
+{ "stu", OP(37), OP_MASK, PWRCOM, { RS, D, RA0 } },
-{ "stb", OP(38), OP_MASK, COM, { RS, D, RA } },
+{ "stb", OP(38), OP_MASK, COM, { RS, D, RA0 } },
{ "stbu", OP(39), OP_MASK, COM, { RS, D, RAS } },
-{ "lhz", OP(40), OP_MASK, COM, { RT, D, RA } },
+{ "lhz", OP(40), OP_MASK, COM, { RT, D, RA0 } },
{ "lhzu", OP(41), OP_MASK, COM, { RT, D, RAL } },
-{ "lha", OP(42), OP_MASK, COM, { RT, D, RA } },
+{ "lha", OP(42), OP_MASK, COM, { RT, D, RA0 } },
{ "lhau", OP(43), OP_MASK, COM, { RT, D, RAL } },
-{ "sth", OP(44), OP_MASK, COM, { RS, D, RA } },
+{ "sth", OP(44), OP_MASK, COM, { RS, D, RA0 } },
{ "sthu", OP(45), OP_MASK, COM, { RS, D, RAS } },
{ "lmw", OP(46), OP_MASK, PPCCOM, { RT, D, RAM } },
-{ "lm", OP(46), OP_MASK, PWRCOM, { RT, D, RA } },
+{ "lm", OP(46), OP_MASK, PWRCOM, { RT, D, RA0 } },
-{ "stmw", OP(47), OP_MASK, PPCCOM, { RS, D, RA } },
-{ "stm", OP(47), OP_MASK, PWRCOM, { RS, D, RA } },
+{ "stmw", OP(47), OP_MASK, PPCCOM, { RS, D, RA0 } },
+{ "stm", OP(47), OP_MASK, PWRCOM, { RS, D, RA0 } },
-{ "lfs", OP(48), OP_MASK, COM, { FRT, D, RA } },
+{ "lfs", OP(48), OP_MASK, COM, { FRT, D, RA0 } },
{ "lfsu", OP(49), OP_MASK, COM, { FRT, D, RAS } },
-{ "lfd", OP(50), OP_MASK, COM, { FRT, D, RA } },
+{ "lfd", OP(50), OP_MASK, COM, { FRT, D, RA0 } },
{ "lfdu", OP(51), OP_MASK, COM, { FRT, D, RAS } },
-{ "stfs", OP(52), OP_MASK, COM, { FRS, D, RA } },
+{ "stfs", OP(52), OP_MASK, COM, { FRS, D, RA0 } },
{ "stfsu", OP(53), OP_MASK, COM, { FRS, D, RAS } },
-{ "stfd", OP(54), OP_MASK, COM, { FRS, D, RA } },
+{ "stfd", OP(54), OP_MASK, COM, { FRS, D, RA0 } },
{ "stfdu", OP(55), OP_MASK, COM, { FRS, D, RAS } },
-{ "lfq", OP(56), OP_MASK, POWER2, { FRT, D, RA } },
+{ "lq", OP(56), OP_MASK, POWER4, { RTQ, DQ, RAQ } },
+
+{ "lfq", OP(56), OP_MASK, POWER2, { FRT, D, RA0 } },
-{ "lfqu", OP(57), OP_MASK, POWER2, { FRT, D, RA } },
+{ "lfqu", OP(57), OP_MASK, POWER2, { FRT, D, RA0 } },
-{ "lbze", DEO(58,0), DE_MASK, BOOKE64, { RT, DE, RA } },
+{ "lbze", DEO(58,0), DE_MASK, BOOKE64, { RT, DE, RA0 } },
{ "lbzue", DEO(58,1), DE_MASK, BOOKE64, { RT, DE, RAL } },
-{ "lhze", DEO(58,2), DE_MASK, BOOKE64, { RT, DE, RA } },
+{ "lhze", DEO(58,2), DE_MASK, BOOKE64, { RT, DE, RA0 } },
{ "lhzue", DEO(58,3), DE_MASK, BOOKE64, { RT, DE, RAL } },
-{ "lhae", DEO(58,4), DE_MASK, BOOKE64, { RT, DE, RA } },
+{ "lhae", DEO(58,4), DE_MASK, BOOKE64, { RT, DE, RA0 } },
{ "lhaue", DEO(58,5), DE_MASK, BOOKE64, { RT, DE, RAL } },
-{ "lwze", DEO(58,6), DE_MASK, BOOKE64, { RT, DE, RA } },
+{ "lwze", DEO(58,6), DE_MASK, BOOKE64, { RT, DE, RA0 } },
{ "lwzue", DEO(58,7), DE_MASK, BOOKE64, { RT, DE, RAL } },
-{ "stbe", DEO(58,8), DE_MASK, BOOKE64, { RS, DE, RA } },
+{ "stbe", DEO(58,8), DE_MASK, BOOKE64, { RS, DE, RA0 } },
{ "stbue", DEO(58,9), DE_MASK, BOOKE64, { RS, DE, RAS } },
-{ "sthe", DEO(58,10), DE_MASK, BOOKE64, { RS, DE, RA } },
+{ "sthe", DEO(58,10), DE_MASK, BOOKE64, { RS, DE, RA0 } },
{ "sthue", DEO(58,11), DE_MASK, BOOKE64, { RS, DE, RAS } },
-{ "stwe", DEO(58,14), DE_MASK, BOOKE64, { RS, DE, RA } },
+{ "stwe", DEO(58,14), DE_MASK, BOOKE64, { RS, DE, RA0 } },
{ "stwue", DEO(58,15), DE_MASK, BOOKE64, { RS, DE, RAS } },
-{ "ld", DSO(58,0), DS_MASK, PPC64, { RT, DS, RA } },
+{ "ld", DSO(58,0), DS_MASK, PPC64, { RT, DS, RA0 } },
{ "ldu", DSO(58,1), DS_MASK, PPC64, { RT, DS, RAL } },
-{ "lwa", DSO(58,2), DS_MASK, PPC64, { RT, DS, RA } },
+{ "lwa", DSO(58,2), DS_MASK, PPC64, { RT, DS, RA0 } },
{ "fdivs", A(59,18,0), AFRC_MASK, PPC, { FRT, FRA, FRB } },
{ "fdivs.", A(59,18,1), AFRC_MASK, PPC, { FRT, FRA, FRB } },
@@ -3881,23 +4436,25 @@ const struct powerpc_opcode powerpc_opcodes[] = {
{ "stfqu", OP(61), OP_MASK, POWER2, { FRS, D, RA } },
-{ "lde", DEO(62,0), DE_MASK, BOOKE64, { RT, DES, RA } },
-{ "ldue", DEO(62,1), DE_MASK, BOOKE64, { RT, DES, RA } },
-{ "lfse", DEO(62,4), DE_MASK, BOOKE64, { FRT, DES, RA } },
+{ "lde", DEO(62,0), DE_MASK, BOOKE64, { RT, DES, RA0 } },
+{ "ldue", DEO(62,1), DE_MASK, BOOKE64, { RT, DES, RA0 } },
+{ "lfse", DEO(62,4), DE_MASK, BOOKE64, { FRT, DES, RA0 } },
{ "lfsue", DEO(62,5), DE_MASK, BOOKE64, { FRT, DES, RAS } },
-{ "lfde", DEO(62,6), DE_MASK, BOOKE64, { FRT, DES, RA } },
+{ "lfde", DEO(62,6), DE_MASK, BOOKE64, { FRT, DES, RA0 } },
{ "lfdue", DEO(62,7), DE_MASK, BOOKE64, { FRT, DES, RAS } },
-{ "stde", DEO(62,8), DE_MASK, BOOKE64, { RS, DES, RA } },
+{ "stde", DEO(62,8), DE_MASK, BOOKE64, { RS, DES, RA0 } },
{ "stdue", DEO(62,9), DE_MASK, BOOKE64, { RS, DES, RAS } },
-{ "stfse", DEO(62,12), DE_MASK, BOOKE64, { FRS, DES, RA } },
+{ "stfse", DEO(62,12), DE_MASK, BOOKE64, { FRS, DES, RA0 } },
{ "stfsue", DEO(62,13), DE_MASK, BOOKE64, { FRS, DES, RAS } },
-{ "stfde", DEO(62,14), DE_MASK, BOOKE64, { FRS, DES, RA } },
+{ "stfde", DEO(62,14), DE_MASK, BOOKE64, { FRS, DES, RA0 } },
{ "stfdue", DEO(62,15), DE_MASK, BOOKE64, { FRS, DES, RAS } },
-{ "std", DSO(62,0), DS_MASK, PPC64, { RS, DS, RA } },
+{ "std", DSO(62,0), DS_MASK, PPC64, { RS, DS, RA0 } },
{ "stdu", DSO(62,1), DS_MASK, PPC64, { RS, DS, RAS } },
+{ "stq", DSO(62,2), DS_MASK, POWER4, { RSQ, DS, RA0 } },
+
{ "fcmpu", X(63,0), X_MASK|(3<<21), COM, { BF, FRA, FRB } },
{ "frsp", XRC(63,12,0), XRA_MASK, COM, { FRT, FRB } },
@@ -4039,8 +4596,8 @@ const struct powerpc_macro powerpc_macros[] = {
{ "extlwi", 4, PPCCOM, "rlwinm %0,%1,%3,0,(%2)-1" },
{ "extlwi.", 4, PPCCOM, "rlwinm. %0,%1,%3,0,(%2)-1" },
-{ "extrwi", 4, PPCCOM, "rlwinm %0,%1,(%2)+(%3),32-(%2),31" },
-{ "extrwi.", 4, PPCCOM, "rlwinm. %0,%1,(%2)+(%3),32-(%2),31" },
+{ "extrwi", 4, PPCCOM, "rlwinm %0,%1,((%2)+(%3))&((%2)+(%3)<>32),32-(%2),31" },
+{ "extrwi.", 4, PPCCOM, "rlwinm. %0,%1,((%2)+(%3))&((%2)+(%3)<>32),32-(%2),31" },
{ "inslwi", 4, PPCCOM, "rlwimi %0,%1,(-(%3)!31)&((%3)|31),%3,(%2)+(%3)-1" },
{ "inslwi.", 4, PPCCOM, "rlwimi. %0,%1,(-(%3)!31)&((%3)|31),%3,(%2)+(%3)-1"},
{ "insrwi", 4, PPCCOM, "rlwimi %0,%1,32-((%2)+(%3)),%3,(%2)+(%3)-1" },
@@ -4059,7 +4616,6 @@ const struct powerpc_macro powerpc_macros[] = {
{ "clrrwi.", 3, PPCCOM, "rlwinm. %0,%1,0,0,31-(%2)" },
{ "clrlslwi",4, PPCCOM, "rlwinm %0,%1,%3,(%2)-(%3),31-(%3)" },
{ "clrlslwi.",4, PPCCOM, "rlwinm. %0,%1,%3,(%2)-(%3),31-(%3)" },
-
};
const int powerpc_num_macros =
diff --git a/contrib/binutils/opcodes/s390-dis.c b/contrib/binutils/opcodes/s390-dis.c
index 8745a89..42f5151 100644
--- a/contrib/binutils/opcodes/s390-dis.c
+++ b/contrib/binutils/opcodes/s390-dis.c
@@ -57,7 +57,7 @@ init_disasm (info)
current_arch_mask = 1 << S390_OPCODE_ESA;
break;
case bfd_mach_s390_64:
- current_arch_mask = 1 << S390_OPCODE_ESAME;
+ current_arch_mask = 1 << S390_OPCODE_ZARCH;
break;
default:
abort ();
@@ -89,6 +89,10 @@ s390_extract_operand (insn, operand)
val >>= -bits;
val &= ((1U << (operand->bits - 1)) << 1) - 1;
+ /* Check for special long displacement case. */
+ if (operand->bits == 20 && operand->shift == 20)
+ val = (val & 0xff) << 12 | (val & 0xfff00) >> 8;
+
/* Sign extend value if the operand is signed or pc relative. */
if ((operand->flags & (S390_OPERAND_SIGNED | S390_OPERAND_PCREL))
&& (val & (1U << (operand->bits - 1))))
@@ -161,7 +165,7 @@ print_insn_s390 (memaddr, info)
const unsigned char *opindex;
/* Check architecture. */
- if (!(opcode->architecture & current_arch_mask))
+ if (!(opcode->modes & current_arch_mask))
continue;
/* Check signature of the opcode. */
if ((buffer[1] & opcode->mask[1]) != opcode->opcode[1]
diff --git a/contrib/binutils/opcodes/s390-mkopc.c b/contrib/binutils/opcodes/s390-mkopc.c
index d79ff81..34188e62 100644
--- a/contrib/binutils/opcodes/s390-mkopc.c
+++ b/contrib/binutils/opcodes/s390-mkopc.c
@@ -23,21 +23,29 @@
#include <stdlib.h>
#include <string.h>
-/* ARCHBITS_ESA and ARCH_ESAME correspond to the bit numbers defined
- by s390_opcode_arch_val in include/opcode/s390.h:
- ARCHBITS_ESAONLY = (1<<S390_OPCODE_ESA)
- ARCHBITS_ESA = (1<<S390_OPCODE_ESA) + (1<<S390_OPCODE_ESAME)
- ARCHBITS_ESA = (1<<S390_OPCODE_ESAME). */
-#define ARCHBITS_ESAONLY 1
-#define ARCHBITS_ESA 3
-#define ARCHBITS_ESAME 2
+/* Taken from opcodes/s390.h */
+enum s390_opcode_mode_val
+ {
+ S390_OPCODE_ESA = 0,
+ S390_OPCODE_ZARCH
+ };
+
+enum s390_opcode_cpu_val
+ {
+ S390_OPCODE_G5 = 0,
+ S390_OPCODE_G6,
+ S390_OPCODE_Z900,
+ S390_OPCODE_Z990
+ };
struct op_struct
{
char opcode[16];
char mnemonic[16];
char format[16];
- int archbits;
+ int mode_bits;
+ int min_cpu;
+
unsigned long long sort_value;
int no_nibbles;
};
@@ -57,7 +65,8 @@ createTable (void)
/* `insertOpcode': insert an op_struct into sorted opcode array. */
static void
-insertOpcode (char *opcode, char *mnemonic, char *format, int archbits)
+insertOpcode (char *opcode, char *mnemonic, char *format,
+ int min_cpu, int mode_bits)
{
char *str;
unsigned long long sort_value;
@@ -87,6 +96,7 @@ insertOpcode (char *opcode, char *mnemonic, char *format, int archbits)
str ++;
}
sort_value <<= 4*(16 - ix);
+ sort_value += (min_cpu << 8) + mode_bits;
no_nibbles = ix;
for (ix = 0; ix < no_ops; ix++)
if (sort_value > op_array[ix].sort_value)
@@ -98,7 +108,8 @@ insertOpcode (char *opcode, char *mnemonic, char *format, int archbits)
strcpy(op_array[ix].format, format);
op_array[ix].sort_value = sort_value;
op_array[ix].no_nibbles = no_nibbles;
- op_array[ix].archbits = archbits;
+ op_array[ix].min_cpu = min_cpu;
+ op_array[ix].mode_bits = mode_bits;
no_ops++;
}
@@ -136,7 +147,8 @@ dumpTable (void)
op_array[ix].no_nibbles*4, op_array[ix].opcode);
printf ("MASK_%s, INSTR_%s, ",
op_array[ix].format, op_array[ix].format);
- printf ("%i}", op_array[ix].archbits);
+ printf ("%i, ", op_array[ix].mode_bits);
+ printf ("%i}", op_array[ix].min_cpu);
if (ix < no_ops-1)
printf (",\n");
else
@@ -162,24 +174,52 @@ main (void)
char mnemonic[16];
char format[16];
char description[64];
- char archtag[16];
- int archbits;
+ char cpu_string[16];
+ char modes_string[16];
+ int min_cpu;
+ int mode_bits;
+ char *str;
if (currentLine[0] == '#')
continue;
memset (opcode, 0, 8);
- if (sscanf (currentLine, "%15s %15s %15s \"%[^\"]\" %15s",
- opcode, mnemonic, format, description, archtag) == 5)
+ if (sscanf (currentLine, "%15s %15s %15s \"%[^\"]\" %15s %15s",
+ opcode, mnemonic, format, description,
+ cpu_string, modes_string) == 6)
{
- if (strcmp (archtag, "esaonly") == 0)
- archbits = ARCHBITS_ESAONLY;
- else if (strcmp (archtag, "esa") == 0)
- archbits = ARCHBITS_ESA;
- else if (strcmp (archtag, "esame") == 0)
- archbits = ARCHBITS_ESAME;
- else
- archbits = 0;
- insertOpcode (opcode, mnemonic, format, archbits);
+ if (strcmp (cpu_string, "g5") == 0)
+ min_cpu = S390_OPCODE_G5;
+ else if (strcmp (cpu_string, "g6") == 0)
+ min_cpu = S390_OPCODE_G6;
+ else if (strcmp (cpu_string, "z900") == 0)
+ min_cpu = S390_OPCODE_Z900;
+ else if (strcmp (cpu_string, "z990") == 0)
+ min_cpu = S390_OPCODE_Z990;
+ else {
+ fprintf (stderr, "Couldn't parse cpu string %s\n", cpu_string);
+ exit (1);
+ }
+
+ str = modes_string;
+ mode_bits = 0;
+ do {
+ if (strncmp (str, "esa", 3) == 0
+ && (str[3] == 0 || str[3] == ',')) {
+ mode_bits |= 1 << S390_OPCODE_ESA;
+ str += 3;
+ } else if (strncmp (str, "zarch", 5) == 0
+ && (str[5] == 0 || str[5] == ',')) {
+ mode_bits |= 1 << S390_OPCODE_ZARCH;
+ str += 5;
+ } else {
+ fprintf (stderr, "Couldn't parse modes string %s\n",
+ modes_string);
+ exit (1);
+ }
+ if (*str == ',')
+ str++;
+ } while (*str != 0);
+ insertOpcode (opcode, mnemonic, format, min_cpu, mode_bits);
}
else
fprintf (stderr, "Couldn't scan line %s\n", currentLine);
diff --git a/contrib/binutils/opcodes/s390-opc.c b/contrib/binutils/opcodes/s390-opc.c
index 7cd8231..1a4b276 100644
--- a/contrib/binutils/opcodes/s390-opc.c
+++ b/contrib/binutils/opcodes/s390-opc.c
@@ -98,33 +98,35 @@ const struct s390_operand s390_operands[] =
{ 12, 20, S390_OPERAND_DISP },
#define D_36 25 /* Displacement starting at position 36 */
{ 12, 36, S390_OPERAND_DISP },
+#define D20_20 26 /* 20 bit displacement starting at 20 */
+ { 20, 20, S390_OPERAND_DISP|S390_OPERAND_SIGNED },
-#define L4_8 26 /* 4 bit length starting at position 8 */
+#define L4_8 27 /* 4 bit length starting at position 8 */
{ 4, 8, S390_OPERAND_LENGTH },
-#define L4_12 27 /* 4 bit length starting at position 12 */
+#define L4_12 28 /* 4 bit length starting at position 12 */
{ 4, 12, S390_OPERAND_LENGTH },
-#define L8_8 28 /* 8 bit length starting at position 8 */
+#define L8_8 29 /* 8 bit length starting at position 8 */
{ 8, 8, S390_OPERAND_LENGTH },
-#define U4_8 29 /* 4 bit unsigned value starting at 8 */
+#define U4_8 30 /* 4 bit unsigned value starting at 8 */
{ 4, 8, 0 },
-#define U4_12 30 /* 4 bit unsigned value starting at 12 */
+#define U4_12 31 /* 4 bit unsigned value starting at 12 */
{ 4, 12, 0 },
-#define U4_16 31 /* 4 bit unsigned value starting at 16 */
+#define U4_16 32 /* 4 bit unsigned value starting at 16 */
{ 4, 16, 0 },
-#define U4_20 32 /* 4 bit unsigned value starting at 20 */
+#define U4_20 33 /* 4 bit unsigned value starting at 20 */
{ 4, 20, 0 },
-#define U8_8 33 /* 8 bit unsigned value starting at 8 */
+#define U8_8 34 /* 8 bit unsigned value starting at 8 */
{ 8, 8, 0 },
-#define U8_16 34 /* 8 bit unsigned value starting at 16 */
+#define U8_16 35 /* 8 bit unsigned value starting at 16 */
{ 8, 16, 0 },
-#define I16_16 35 /* 16 bit signed value starting at 16 */
+#define I16_16 36 /* 16 bit signed value starting at 16 */
{ 16, 16, S390_OPERAND_SIGNED },
-#define U16_16 36 /* 16 bit unsigned value starting at 16 */
+#define U16_16 37 /* 16 bit unsigned value starting at 16 */
{ 16, 16, 0 },
-#define J16_16 37 /* PC relative jump offset at 16 */
+#define J16_16 38 /* PC relative jump offset at 16 */
{ 16, 16, S390_OPERAND_PCREL },
-#define J32_16 38 /* PC relative long offset at 16 */
+#define J32_16 39 /* PC relative long offset at 16 */
{ 32, 16, S390_OPERAND_PCREL }
};
@@ -194,6 +196,7 @@ const struct s390_operand s390_operands[] =
#define INSTR_RRF_F0FF 4, { F_16,F_24,F_28,0,0,0 } /* e.g. madbr */
#define INSTR_RRF_FUFF 4, { F_24,F_16,F_28,U4_20,0,0 } /* e.g. didbr */
#define INSTR_RRF_RURR 4, { R_24,R_28,R_16,U4_20,0,0 } /* e.g. .insn */
+#define INSTR_RRF_R0RR 4, { R_24,R_28,R_16,0,0,0 } /* e.g. idte */
#define INSTR_RRF_U0FF 4, { F_24,U4_16,F_28,0,0,0 } /* e.g. cfxbr */
#define INSTR_RRF_U0FR 4, { F_24,U4_16,R_28,0,0,0 } /* e.g. cfebr */
#define INSTR_RRF_U0FR 4, { F_24,U4_16,R_28,0,0,0 } /* e.g. cfxbr */
@@ -205,7 +208,11 @@ const struct s390_operand s390_operands[] =
#define INSTR_RR_UR 2, { U4_8,R_12,0,0,0,0 } /* e.g. bcr */
#define INSTR_RSE_RRRD 6, { R_8,R_12,D_20,B_16,0,0 } /* e.g. lmh */
#define INSTR_RSE_RURD 6, { R_8,U4_12,D_20,B_16,0,0 } /* e.g. icmh */
+#define INSTR_RSL_R0RD 6, { R_8,D_20,B_16,0,0,0 } /* e.g. tp */
#define INSTR_RSI_RRP 4, { R_8,R_12,J16_16,0,0,0 } /* e.g. brxh */
+#define INSTR_RSY_RRRD 6, { R_8,R_12,D20_20,B_16,0,0 } /* e.g. stmy */
+#define INSTR_RSY_RURD 6, { R_8,U4_12,D20_20,B_16,0,0 } /* e.g. icmh */
+#define INSTR_RSY_AARD 6, { A_8,A_12,D20_20,B_16,0,0 } /* e.g. lamy */
#define INSTR_RS_AARD 4, { A_8,A_12,D_20,B_16,0,0 } /* e.g. lam */
#define INSTR_RS_CCRD 4, { C_8,C_12,D_20,B_16,0,0 } /* e.g. lctl */
#define INSTR_RS_R0RD 4, { R_8,D_20,B_16,0,0,0 } /* e.g. sll */
@@ -215,11 +222,14 @@ const struct s390_operand s390_operands[] =
#define INSTR_RXE_RRRD 6, { R_8,D_20,X_12,B_16,0,0 } /* e.g. lg */
#define INSTR_RXF_FRRDF 6, { F_32,F_8,D_20,X_12,B_16,0 } /* e.g. madb */
#define INSTR_RXF_RRRDR 6, { R_32,R_8,D_20,X_12,B_16,0 } /* e.g. .insn */
+#define INSTR_RXY_RRRD 6, { R_8,D20_20,X_12,B_16,0,0 } /* e.g. ly */
+#define INSTR_RXY_FRRD 6, { F_8,D20_20,X_12,B_16,0,0 } /* e.g. ley */
#define INSTR_RX_0RRD 4, { D_20,X_12,B_16,0,0,0 } /* e.g. be */
#define INSTR_RX_FRRD 4, { F_8,D_20,X_12,B_16,0,0 } /* e.g. ae */
#define INSTR_RX_RRRD 4, { R_8,D_20,X_12,B_16,0,0 } /* e.g. l */
#define INSTR_RX_URRD 4, { U4_8,D_20,X_12,B_16,0,0 } /* e.g. bc */
#define INSTR_SI_URD 4, { D_20,B_16,U8_8,0,0,0 } /* e.g. cli */
+#define INSTR_SIY_URD 6, { D20_20,B_16,U8_8,0,0,0 } /* e.g. tmy */
#define INSTR_SSE_RDRD 6, { D_20,B_16,D_36,B_32,0,0 } /* e.g. mvsdk */
#define INSTR_SS_L0RDRD 6, { D_20,L8_8,B_16,D_36,B_32,0 } /* e.g. mvc */
#define INSTR_SS_LIRDRD 6, { D_20,L4_8,B_16,D_36,B_32,U4_12 } /* e.g. srp */
@@ -253,6 +263,7 @@ const struct s390_operand s390_operands[] =
#define MASK_RRF_F0FF { 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00 }
#define MASK_RRF_FUFF { 0xff, 0xff, 0x00, 0x00, 0x00, 0x00 }
#define MASK_RRF_RURR { 0xff, 0xff, 0x00, 0x00, 0x00, 0x00 }
+#define MASK_RRF_R0RR { 0xff, 0xff, 0x00, 0x00, 0x00, 0x00 }
#define MASK_RRF_U0FF { 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00 }
#define MASK_RRF_U0FR { 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00 }
#define MASK_RRF_U0FR { 0xff, 0xff, 0x0f, 0x00, 0x00, 0x00 }
@@ -264,21 +275,28 @@ const struct s390_operand s390_operands[] =
#define MASK_RR_UR { 0xff, 0x00, 0x00, 0x00, 0x00, 0x00 }
#define MASK_RSE_RRRD { 0xff, 0x00, 0x00, 0x00, 0x00, 0xff }
#define MASK_RSE_RURD { 0xff, 0x00, 0x00, 0x00, 0x00, 0xff }
+#define MASK_RSL_R0RD { 0xff, 0x00, 0x00, 0x00, 0x00, 0xff }
#define MASK_RSI_RRP { 0xff, 0x00, 0x00, 0x00, 0x00, 0x00 }
#define MASK_RS_AARD { 0xff, 0x00, 0x00, 0x00, 0x00, 0x00 }
#define MASK_RS_CCRD { 0xff, 0x00, 0x00, 0x00, 0x00, 0x00 }
#define MASK_RS_R0RD { 0xff, 0x0f, 0x00, 0x00, 0x00, 0x00 }
#define MASK_RS_RRRD { 0xff, 0x00, 0x00, 0x00, 0x00, 0x00 }
#define MASK_RS_RURD { 0xff, 0x00, 0x00, 0x00, 0x00, 0x00 }
+#define MASK_RSY_RRRD { 0xff, 0x00, 0x00, 0x00, 0x00, 0xff }
+#define MASK_RSY_RURD { 0xff, 0x00, 0x00, 0x00, 0x00, 0xff }
+#define MASK_RSY_AARD { 0xff, 0x00, 0x00, 0x00, 0x00, 0xff }
#define MASK_RXE_FRRD { 0xff, 0x00, 0x00, 0x00, 0x00, 0xff }
#define MASK_RXE_RRRD { 0xff, 0x00, 0x00, 0x00, 0x00, 0xff }
#define MASK_RXF_FRRDF { 0xff, 0x00, 0x00, 0x00, 0x00, 0xff }
#define MASK_RXF_RRRDR { 0xff, 0x00, 0x00, 0x00, 0x00, 0xff }
+#define MASK_RXY_RRRD { 0xff, 0x00, 0x00, 0x00, 0x00, 0xff }
+#define MASK_RXY_FRRD { 0xff, 0x00, 0x00, 0x00, 0x00, 0xff }
#define MASK_RX_0RRD { 0xff, 0xf0, 0x00, 0x00, 0x00, 0x00 }
#define MASK_RX_FRRD { 0xff, 0x00, 0x00, 0x00, 0x00, 0x00 }
#define MASK_RX_RRRD { 0xff, 0x00, 0x00, 0x00, 0x00, 0x00 }
#define MASK_RX_URRD { 0xff, 0x00, 0x00, 0x00, 0x00, 0x00 }
#define MASK_SI_URD { 0xff, 0x00, 0x00, 0x00, 0x00, 0x00 }
+#define MASK_SIY_URD { 0xff, 0x00, 0x00, 0x00, 0x00, 0xff }
#define MASK_SSE_RDRD { 0xff, 0xff, 0x00, 0x00, 0x00, 0x00 }
#define MASK_SS_L0RDRD { 0xff, 0x00, 0x00, 0x00, 0x00, 0x00 }
#define MASK_SS_LIRDRD { 0xff, 0x00, 0x00, 0x00, 0x00, 0x00 }
@@ -293,23 +311,26 @@ const struct s390_operand s390_operands[] =
const struct s390_opcode s390_opformats[] =
{
- { "e", OP8(0x00LL), MASK_E, INSTR_E, 3 },
- { "ri", OP8(0x00LL), MASK_RI_RI, INSTR_RI_RI, 3 },
- { "rie", OP8(0x00LL), MASK_RIE_RRP, INSTR_RIE_RRP, 3 },
- { "ril", OP8(0x00LL), MASK_RIL_RP, INSTR_RIL_RP, 3 },
- { "rr", OP8(0x00LL), MASK_RR_RR, INSTR_RR_RR, 3 },
- { "rre", OP8(0x00LL), MASK_RRE_RR, INSTR_RRE_RR, 3 },
- { "rrf", OP8(0x00LL), MASK_RRF_RURR, INSTR_RRF_RURR, 3 },
- { "rs", OP8(0x00LL), MASK_RS_RRRD, INSTR_RS_RRRD, 3 },
- { "rse", OP8(0x00LL), MASK_RSE_RRRD, INSTR_RSE_RRRD, 3 },
- { "rsi", OP8(0x00LL), MASK_RSI_RRP, INSTR_RSI_RRP, 3 },
- { "rx", OP8(0x00LL), MASK_RX_RRRD, INSTR_RX_RRRD, 3 },
- { "rxe", OP8(0x00LL), MASK_RXE_RRRD, INSTR_RXE_RRRD, 3 },
- { "rxf", OP8(0x00LL), MASK_RXF_RRRDR, INSTR_RXF_RRRDR,3 },
- { "s", OP8(0x00LL), MASK_S_RD, INSTR_S_RD, 3 },
- { "si", OP8(0x00LL), MASK_SI_URD, INSTR_SI_URD, 3 },
- { "ss", OP8(0x00LL), MASK_SS_RRRDRD, INSTR_SS_RRRDRD,3 },
- { "sse", OP8(0x00LL), MASK_SSE_RDRD, INSTR_SSE_RDRD, 3 },
+ { "e", OP8(0x00LL), MASK_E, INSTR_E, 3, 0 },
+ { "ri", OP8(0x00LL), MASK_RI_RI, INSTR_RI_RI, 3, 0 },
+ { "rie", OP8(0x00LL), MASK_RIE_RRP, INSTR_RIE_RRP, 3, 0 },
+ { "ril", OP8(0x00LL), MASK_RIL_RP, INSTR_RIL_RP, 3, 0 },
+ { "rr", OP8(0x00LL), MASK_RR_RR, INSTR_RR_RR, 3, 0 },
+ { "rre", OP8(0x00LL), MASK_RRE_RR, INSTR_RRE_RR, 3, 0 },
+ { "rrf", OP8(0x00LL), MASK_RRF_RURR, INSTR_RRF_RURR, 3, 0 },
+ { "rs", OP8(0x00LL), MASK_RS_RRRD, INSTR_RS_RRRD, 3, 0 },
+ { "rse", OP8(0x00LL), MASK_RSE_RRRD, INSTR_RSE_RRRD, 3, 0 },
+ { "rsi", OP8(0x00LL), MASK_RSI_RRP, INSTR_RSI_RRP, 3, 0 },
+ { "rsy", OP8(0x00LL), MASK_RSY_RRRD, INSTR_RSY_RRRD, 3, 3 },
+ { "rx", OP8(0x00LL), MASK_RX_RRRD, INSTR_RX_RRRD, 3, 0 },
+ { "rxe", OP8(0x00LL), MASK_RXE_RRRD, INSTR_RXE_RRRD, 3, 0 },
+ { "rxf", OP8(0x00LL), MASK_RXF_RRRDR, INSTR_RXF_RRRDR,3, 0 },
+ { "rxy", OP8(0x00LL), MASK_RXY_RRRD, INSTR_RXY_RRRD, 3, 3 },
+ { "s", OP8(0x00LL), MASK_S_RD, INSTR_S_RD, 3, 0 },
+ { "si", OP8(0x00LL), MASK_SI_URD, INSTR_SI_URD, 3, 0 },
+ { "siy", OP8(0x00LL), MASK_SIY_URD, INSTR_SIY_URD, 3, 3 },
+ { "ss", OP8(0x00LL), MASK_SS_RRRDRD, INSTR_SS_RRRDRD,3, 0 },
+ { "sse", OP8(0x00LL), MASK_SSE_RDRD, INSTR_SSE_RDRD, 3, 0 },
};
const int s390_num_opformats =
diff --git a/contrib/binutils/opcodes/s390-opc.txt b/contrib/binutils/opcodes/s390-opc.txt
index ddcf089..be08c82 100644
--- a/contrib/binutils/opcodes/s390-opc.txt
+++ b/contrib/binutils/opcodes/s390-opc.txt
@@ -1,626 +1,793 @@
# S/390 opcodes list. Use s390-mkopc to convert it into the opcode table.
# Copyright 2000, 2001 Free Software Foundation, Inc.
# Contributed by Martin Schwidefsky (schwidefsky@de.ibm.com).
-5a a RX_RRRD "add" esa
-6a ad RX_FRRD "add normalized (long)" esa
-2a adr RR_FF "add normalized (long)" esa
-7a ae RX_FRRD "add normalized (short)" esa
-3a aer RR_FF "add normalized (short)" esa
-4a ah RX_RRRD "add halfword" esa
-5e al RX_RRRD "add logical" esa
-1e alr RR_RR "add logical" esa
-fa ap SS_LLRDRD "add decimal" esa
-1a ar RR_RR "add" esa
-7e au RX_FRRD "add unnormalized (short)" esa
-3e aur RR_FF "add unnormalized (short)" esa
-6e aw RX_FRRD "add unnormalized (long)" esa
-2e awr RR_FF "add unnormalized (long)" esa
-36 axr RR_FF "add normalized" esa
-b240 bakr RRE_RR "branch and stack" esa
-45 bal RX_RRRD "branch and link" esa
-05 balr RR_RR "branch and link" esa
-4d bas RX_RRRD "branch and save" esa
-0d basr RR_RR "branch and save" esa
-0c bassm RR_RR "branch and save and set mode" esa
-47 bc RX_URRD "branch on condition" esa
-07 bcr RR_UR "branch on condition" esa
-46 bct RX_RRRD "branch on count" esa
-06 bctr RR_RR "branch on count" esa
-b258 bsg RRE_RR "branch in subspace group" esa
-0b bsm RR_RR "branch and set mode" esa
-86 bxh RS_RRRD "branch on index high" esa
-87 bxle RS_RRRD "branch on index low or equal" esa
-59 c RX_RRRD "compare" esa
-69 cd RX_FRRD "compare (long)" esa
-29 cdr RR_FF "compare (long)" esa
-bb cds RS_RRRD "compare double and swap" esa
-79 ce RX_FRRD "compare (short)" esa
-39 cer RR_FF "compare (short)" esa
-b21a cfc S_RD "compare and form codeword" esa
-49 ch RX_RRRD "compare halfword" esa
-55 cl RX_RRRD "compare logical" esa
-d5 clc SS_L0RDRD "compare logical" esa
-0f clcl RR_RR "compare logical long" esa
-95 cli SI_URD "compare logical" esa
-bd clm RS_RURD "compare logical characters under mask" esa
-15 clr RR_RR "compare logical" esa
-b25d clst RRE_RR "compare logical string" esa
-b263 cmpsc RRE_RR "compression call" esa
-f9 cp SS_LLRDRD "compare decimal" esa
-b24d cpya RRE_AA "copy access" esa
-19 cr RR_RR "compare" esa
-ba cs RS_RRRD "compare and swap" esa
-b230 csch S_00 "clear subchannel" esa
-b257 cuse RRE_RR "compare until substring equal" esa
-b250 csp RRE_RR "compare and swap and purge" esa
-4f cvb RX_RRRD "convert to binary" esa
-4e cvd RX_RRRD "convert to decimal" esa
-5d d RX_RRRD "divide" esa
-6d dd RX_FRRD "divide (long)" esa
-2d ddr RR_FF "divide (long)" esa
-7d de RX_FRRD "divide (short)" esa
-3d der RR_FF "divide (short)" esa
-83 diag RS_RRRD "diagnose" esa
-fd dp SS_LLRDRD "divide decimal" esa
-1d dr RR_RR "divide" esa
-b22d dxr RRE_F0 "divide (ext.)" esa
-b24f ear RRE_RA "extract access" esa
-de ed SS_L0RDRD "edit" esa
-df edmk SS_L0RDRD "edit and mark" esa
-b226 epar RRE_R0 "extract primary ASN" esa
-b249 ereg RRE_RR "extract stacked registers" esa
-b227 esar RRE_R0 "extract secondary ASN" esa
-b24a esta RRE_RR "extract stacked state" esa
-44 ex RX_RRRD "execute" esa
-24 hdr RR_FF "halve (long)" esa
-34 her RR_FF "halve (short)" esa
-b231 hsch S_00 "halt subchannel" esa
-b224 iac RRE_R0 "insert address space control" esa
-43 ic RX_RRRD "insert character" esa
-bf icm RS_RURD "insert characters under mask" esa
-b20b ipk S_00 "insert PSW key" esa
-b222 ipm RRE_R0 "insert program mask" esa
-b221 ipte RRE_RR "invalidate page table entry" esa
-b229 iske RRE_RR "insert storage key extended" esa
-b223 ivsk RRE_RR "insert virtual storage key" esa
-58 l RX_RRRD "load" esa
-41 la RX_RRRD "load address" esa
-51 lae RX_RRRD "load address extended" esa
-9a lam RS_AARD "load access multiple" esa
-e500 lasp SSE_RDRD "load address space parameters" esa
-23 lcdr RR_FF "load complement (long)" esa
-33 lcer RR_FF "load complement (short)" esa
-13 lcr RR_RR "load complement" esa
-b7 lctl RS_CCRD "load control" esa
-68 ld RX_FRRD "load (long)" esa
-28 ldr RR_FF "load (long)" esa
-78 le RX_FRRD "load (short)" esa
-38 ler RR_FF "load (short)" esa
-48 lh RX_RRRD "load halfword" esa
-98 lm RS_RRRD "load multiple" esa
-21 lndr RR_FF "load negative (long)" esa
-31 lner RR_FF "load negative (short)" esa
-11 lnr RR_RR "load negative" esa
-20 lpdr RR_FF "load positive (long)" esa
-30 lper RR_FF "load positive (short)" esa
-10 lpr RR_RR "load positive" esa
-82 lpsw S_RD "load PSW" esa
-18 lr RR_RR "load" esa
-b1 lra RX_RRRD "load real address" esa
-25 lrdr RR_FF "load rounded (ext. to long)" esa
-35 lrer RR_FF "load rounded (long to short)" esa
-22 ltdr RR_FF "load and test (long)" esa
-32 lter RR_FF "load and test (short)" esa
-12 ltr RR_RR "load and test" esa
-b24b lura RRE_RR "load using real address" esa
-5c m RX_RRRD "multiply" esa
-af mc SI_URD "monitor call" esa
-6c md RX_FRRD "multiply (long)" esa
-2c mdr RR_FF "multiply (long)" esa
-7c me RX_FRRD "multiply (short to long)" esa
-3c mer RR_FF "multiply (short to long)" esa
-4c mh RX_RRRD "multiply halfword" esa
-fc mp SS_LLRDRD "multiply decimal" esa
-1c mr RR_RR "multiply" esa
-b232 msch S_RD "modify subchannel" esa
-b247 msta RRE_R0 "modify stacked state" esa
-d2 mvc SS_L0RDRD "move" esa
-e50f mvcdk SSE_RDRD "move with destination key" esa
-e8 mvcin SS_L0RDRD "move inverse" esa
-d9 mvck SS_RRRDRD "move with key" esa
-0e mvcl RR_RR "move long" esa
-da mvcp SS_RRRDRD "move to primary" esa
-db mvcs SS_RRRDRD "move to secondary" esa
-e50e mvcsk SSE_RDRD "move with source key" esa
-92 mvi SI_URD "move" esa
-d1 mvn SS_L0RDRD "move numerics" esa
-f1 mvo SS_LLRDRD "move with offset" esa
-b254 mvpg RRE_RR "move page" esa
-b255 mvst RRE_RR "move string" esa
-d3 mvz SS_L0RDRD "move zones" esa
-67 mxd RX_FRRD "multiply (long to ext.)" esa
-27 mxdr RR_FF "multiply (long to ext.)" esa
-26 mxr RR_FF "multiply (ext.)" esa
-54 n RX_RRRD "AND" esa
-d4 nc SS_L0RDRD "AND" esa
-94 ni SI_URD "AND" esa
-14 nr RR_RR "AND" esa
-56 o RX_RRRD "OR" esa
-d6 oc SS_L0RDRD "OR" esa
-96 oi SI_URD "OR" esa
-16 or RR_RR "OR" esa
-f2 pack SS_LLRDRD "pack" esa
-b248 palb RRE_00 "purge ALB" esa
-b218 pc S_RD "program call" esa
-0101 pr E "program return" esa
-b228 pt RRE_RR "program transfer" esa
-b20d ptlb S_00 "purge TLB" esa
-b23b rchp S_00 "reset channel path" esa
-b22a rrbe RRE_RR "reset reference bit extended" esa
-b238 rsch S_00 "resume subchannel" esa
-5b s RX_RRRD "subtract" esa
-b219 sac S_RD "set address space control" esa
-b279 sacf S_RD "set address space control fast" esa
-b237 sal S_00 "set address limit" esa
-b24e sar RRE_AR "set access" esa
-b23c schm S_00 "set channel monitor" esa
-b204 sck S_RD "set clock" esa
-b206 sckc S_RD "set clock comparator" esa
-6b sd RX_FRRD "subtract normalized (long)" esa
-2b sdr RR_FF "subtract normalized (long)" esa
-7b se RX_FRRD "subtract normalized (short)" esa
-3b ser RR_FF "subtract normalized (short)" esa
-4b sh RX_RRRD "subtract halfword" esa
-b214 sie S_RD "start interpretive execution" esa
-ae sigp RS_RRRD "signal processor" esa
-5f sl RX_RRRD "subtract logical" esa
-8b sla RS_R0RD "shift left single" esa
-8f slda RS_R0RD "shift left double (long)" esa
-8d sldl RS_R0RD "shift left double logical (long)" esa
-89 sll RS_R0RD "shift left single logical" esa
-1f slr RR_RR "subtract logical" esa
-fb sp SS_LLRDRD "subtract decimal" esa
-b20a spka S_RD "set PSW key from address" esa
-04 spm RR_R0 "set program mask" esa
-b208 spt S_RD "set CPU timer" esa
-b210 spx S_RD "set prefix" esa
-b244 sqdr RRE_F0 "square root (long)" esa
-b245 sqer RRE_F0 "square root (short)" esa
-1b sr RR_RR "subtract" esa
-8a sra RS_R0RD "shift right single" esa
-8e srda RS_R0RD "shift right double (long)" esa
-8c srdl RS_R0RD "shift right double logical (long)" esa
-88 srl RS_R0RD "shift right single logical" esa
-f0 srp SS_LIRDRD "shift and round decimal" esa
-b25e srst RRE_RR "search string" esa
-b225 ssar RRE_R0 "set secondary ASN" esa
-b233 ssch S_RD "start subchannel" esa
-b22b sske RRE_RR "set storage key extended" esa
-80 ssm S_RD "set system mask" esa
-50 st RX_RRRD "store" esa
-9b stam RS_AARD "store access multiple" esa
-b212 stap S_RD "store CPU address" esa
-42 stc RX_RRRD "store character" esa
-b205 stck S_RD "store clock" esa
-b207 stckc S_RD "store clock comparator" esa
-be stcm RS_RURD "store characters under mask" esa
-b23a stcps S_RD "store channel path status" esa
-b239 stcrw S_RD "store channel report word" esa
-b6 stctl RS_CCRD "store control" esa
-60 std RX_FRRD "store (long)" esa
-70 ste RX_FRRD "store (short)" esa
-40 sth RX_RRRD "store halfword" esa
-b202 stidp S_RD "store CPU id" esa
-90 stm RS_RRRD "store multiple" esa
-ac stnsm SI_URD "store then AND system mask" esa
-ad stosm SI_URD "store then OR system mask" esa
-b209 stpt S_RD "store CPU timer" esa
-b211 stpx S_RD "store prefix" esa
-b234 stsch S_RD "store subchannel" esa
-b246 stura RRE_RR "store using real address" esa
-7f su RX_FRRD "subtract unnormalized (short)" esa
-3f sur RR_FF "subtract unnormalized (short)" esa
-0a svc RR_U0 "supervisor call" esa
-6f sw RX_FRRD "subtract unnormalized (long)" esa
-2f swr RR_FF "subtract unnormalized (long)" esa
-37 sxr RR_FF "subtract normalized (ext.)" esa
-b24c tar RRE_AR "test access" esa
-b22c tb RRE_0R "test block" esa
-91 tm SI_URD "test under mask" esa
-b236 tpi S_RD "test pending interruption" esa
-e501 tprot SSE_RDRD "test protection" esa
-dc tr SS_L0RDRD "translate" esa
-99 trace RS_RRRD "trace" esa
-dd trt SS_L0RDRD "translate and test" esa
-93 ts S_RD "test and set" esa
-b235 tsch S_RD "test subchannel" esa
-f3 unpk SS_LLRDRD "unpack" esa
-0102 upt E "update tree" esa
-57 x RX_RRRD "exclusive OR" esa
-d7 xc SS_L0RDRD "exclusive OR" esa
-97 xi SI_URD "exclusive OR" esa
-17 xr RR_RR "exclusive OR" esa
-f8 zap SS_LLRDRD "zero and add" esa
-a70a ahi RI_RI "add halfword immediate" esa
-84 brxh RSI_RRP "branch relative on index high" esa
-85 brxle RSI_RRP "branch relative on index low or equal" esa
-a705 bras RI_RP "branch relative and save" esa
-a704 brc RI_UP "branch relative on condition" esa
-a706 brct RI_RP "branch relative on count" esa
-b241 cksm RRE_RR "checksum" esa
-a70e chi RI_RI "compare halfword immediate" esa
-a9 clcle RS_RRRD "compare logical long extended" esa
-a708 lhi RI_RI "load halfword immediate" esa
-a8 mvcle RS_RRRD "move long extended" esa
-a70c mhi RI_RI "multiply halfword immediate" esa
-b252 msr RRE_RR "multiply single" esa
-71 ms RX_RRRD "multiply single" esa
-a700 tmh RI_RU "test under mask high" esa
-a701 tml RI_RU "test under mask low" esa
-0700 nopr RR_0R "no operation" esa
-0710 bor RR_0R "branch on overflow / if ones" esa
-0720 bhr RR_0R "branch on high" esa
-0720 bpr RR_0R "branch on plus" esa
-0730 bnler RR_0R "branch on not low or equal" esa
-0740 blr RR_0R "branch on low" esa
-0740 bmr RR_0R "branch on minus / if mixed" esa
-0750 bnher RR_0R "branch on not high or equal" esa
-0760 blhr RR_0R "branch on low or high" esa
-0770 bner RR_0R "branch on not equal" esa
-0770 bnzr RR_0R "branch on not zero / if not zeros" esa
-0780 ber RR_0R "branch on equal" esa
-0780 bzr RR_0R "branch on zero / if zeros" esa
-0790 bnlhr RR_0R "branch on not low or high" esa
-07a0 bher RR_0R "branch on high or equal" esa
-07b0 bnlr RR_0R "branch on not low" esa
-07b0 bnmr RR_0R "branch on not minus / if not mixed" esa
-07c0 bler RR_0R "brach on low or equal" esa
-07d0 bnhr RR_0R "branch on not high" esa
-07d0 bnpr RR_0R "branch on not plus" esa
-07e0 bnor RR_0R "branch on not overflow / if not ones" esa
-07f0 br RR_0R "unconditional branch" esa
-4700 nop RX_0RRD "no operation" esa
-4710 bo RX_0RRD "branch on overflow / if ones" esa
-4720 bh RX_0RRD "branch on high" esa
-4720 bp RX_0RRD "branch on plus" esa
-4730 bnle RX_0RRD "branch on not low or equal" esa
-4740 bl RX_0RRD "branch on low" esa
-4740 bm RX_0RRD "branch on minus / if mixed" esa
-4750 bnhe RX_0RRD "branch on not high or equal" esa
-4760 blh RX_0RRD "branch on low or high" esa
-4770 bne RX_0RRD "branch on not equal" esa
-4770 bnz RX_0RRD "branch on not zero / if not zeros" esa
-4780 be RX_0RRD "branch on equal" esa
-4780 bz RX_0RRD "branch on zero / if zeros" esa
-4790 bnlh RX_0RRD "branch on not low or high" esa
-47a0 bhe RX_0RRD "branch on high or equal" esa
-47b0 bnl RX_0RRD "branch on not low" esa
-47b0 bnm RX_0RRD "branch on not minus / if not mixed" esa
-47c0 ble RX_0RRD "branch on low or equal" esa
-47d0 bnh RX_0RRD "branch on not high" esa
-47d0 bnp RX_0RRD "branch on not plus" esa
-47e0 bno RX_0RRD "branch on not overflow / if not ones" esa
-47f0 b RX_0RRD "unconditional branch" esa
-a714 jo RI_0P "jump on overflow / if ones" esa
-a724 jh RI_0P "jump on A high" esa
-a724 jp RI_0P "jump on plus" esa
-a734 jnle RI_0P "jump on not low or equal" esa
-a744 jl RI_0P "jump on A low" esa
-a744 jm RI_0P "jump on minus / if mixed" esa
-a754 jnhe RI_0P "jump on not high or equal" esa
-a764 jlh RI_0P "jump on low or high" esa
-a774 jne RI_0P "jump on A not equal B" esa
-a774 jnz RI_0P "jump on not zero / if not zeros" esa
-a784 je RI_0P "jump on A equal B" esa
-a784 jz RI_0P "jump on zero / if zeros" esa
-a794 jnlh RI_0P "jump on not low or high" esa
-a7a4 jhe RI_0P "jump on high or equal" esa
-a7b4 jnl RI_0P "jump on A not low" esa
-a7b4 jnm RI_0P "jump on not minus / if not mixed" esa
-a7c4 jle RI_0P "jump on low or equal" esa
-a7d4 jnh RI_0P "jump on A not high" esa
-a7d4 jnp RI_0P "jump on not plus" esa
-a7e4 jno RI_0P "jump on not overflow / if not ones" esa
-a7f4 j RI_0P "jump" esa
-b34a axbr RRE_FF "add extended bfp" esa
-b31a adbr RRE_FF "add long bfp" esa
-ed000000001a adb RXE_FRRD "add long bfp" esa
-b30a aebr RRE_FF "add short bfp" esa
-ed000000000a aeb RXE_FRRD "add short bfp" esa
-b349 cxbr RRE_FF "compare extended bfp" esa
-b319 cdbr RRE_FF "compare long bfp" esa
-ed0000000019 cdb RXE_FRRD "compare long bfp" esa
-b309 cebr RRE_FF "compare short bfp" esa
-ed0000000009 ceb RXE_FRRD "compare short bfp" esa
-b348 kxbr RRE_FF "compare and signal extended bfp" esa
-b318 kdbr RRE_FF "compare and signal long bfp" esa
-ed0000000018 kdb RXE_FRRD "compare and signal long bfp" esa
-b308 kebr RRE_FF "compare and signal short bfp" esa
-ed0000000008 keb RXE_FRRD "compare and signal short bfp" esa
-b396 cxfbr RRE_RF "convert from fixed 32 to extended bfp" esa
-b395 cdfbr RRE_RF "convert from fixed 32 to long bfp" esa
-b394 cefbr RRE_RF "convert from fixed 32 to short bfp" esa
-b39a cfxbr RRF_U0FR "convert to fixed extended bfp to 32" esa
-b399 cfdbr RRF_U0FR "convert to fixed long bfp to 32" esa
-b398 cfebr RRF_U0FR "convert to fixed short bfp to 32" esa
-b34d dxbr RRE_FF "divide extended bfp" esa
-b31d ddbr RRE_FF "divide long bfp" esa
-ed000000001d ddb RXE_FRRD "divide long bfp" esa
-b30d debr RRE_FF "divide short bfp" esa
-ed000000000d deb RXE_FRRD "divide short bfp" esa
-b35b didbr RRF_FUFF "divide to integer long bfp" esa
-b353 diebr RRF_FUFF "divide to integer short bfp" esa
-b38c efpc RRE_RR "extract fpc" esa
-b342 ltxbr RRE_FF "load and test extended bfp" esa
-b312 ltdbr RRE_FF "load and test long bfp" esa
-b302 ltebr RRE_FF "load and test short bfp" esa
-b343 lcxbr RRE_FF "load complement extended bfp" esa
-b313 lcdbr RRE_FF "load complement long bfp" esa
-b303 lcebr RRE_FF "load complement short bfp" esa
-b347 fixbr RRF_U0FF "load fp integer extended bfp" esa
-b35f fidbr RRF_U0FF "load fp integer long bfp" esa
-b357 fiebr RRF_U0FF "load fp integer short bfp" esa
-b29d lfpc S_RD "load fpc" esa
-b305 lxdbr RRE_FF "load lengthened long to extended bfp" esa
-ed0000000005 lxdb RXE_FRRD "load lengthened long to extended bfp" esa
-b306 lxebr RRE_FF "load lengthened short to extended bfp" esa
-ed0000000006 lxeb RXE_FRRD "load lengthened short to extended bfp" esa
-b304 ldebr RRE_FF "load lengthened short to long bfp" esa
-ed0000000004 ldeb RXE_FRRD "load lengthened short to long bfp" esa
-b341 lnxbr RRE_FF "load negative extended bfp" esa
-b311 lndbr RRE_FF "load negative long bfp" esa
-b301 lnebr RRE_FF "load negative short bfp" esa
-b340 lpxbr RRE_FF "load positive extended bfp" esa
-b310 lpdbr RRE_FF "load positive long bfp" esa
-b300 lpebr RRE_FF "load positive short bfp" esa
-b345 ldxbr RRE_FF "load rounded extended to long bfp" esa
-b346 lexbr RRE_FF "load rounded extended to short bfp" esa
-b344 ledbr RRE_FF "load rounded long to short bfp" esa
-b34c mxbr RRE_FF "multiply extended bfp" esa
-b31c mdbr RRE_FF "multiply long bfp" esa
-ed000000001c mdb RXE_FRRD "multiply long bfp" esa
-b307 mxdbr RRE_FF "multiply long to extended bfp" esa
-ed0000000007 mxdb RXE_FRRD "multiply long to extended bfp" esa
-b317 meebr RRE_FF "multiply short bfp" esa
-ed0000000017 meeb RXE_FRRD "multiply short bfp" esa
-b30c mdebr RRE_FF "multiply short to long bfp" esa
-ed000000000c mdeb RXE_FRRD "multiply short to long bfp" esa
-b31e madbr RRF_F0FF "multiply and add long bfp" esa
-ed000000001e madb RXF_FRRDF "multiply and add long bfp" esa
-b30e maebr RRF_F0FF "multiply and add short bfp" esa
-ed000000000e maeb RXF_FRRDF "multiply and add short bfp" esa
-b31f msdbr RRF_F0FF "multiply and subtract long bfp" esa
-ed000000001f msdb RXF_FRRDF "multiply and subtract long bfp" esa
-b30f msebr RRF_F0FF "multiply and subtract short bfp" esa
-ed000000000f mseb RXF_FRRDF "multiply and subtract short bfp" esa
-b384 sfpc RRE_RR "set fpc" esa
-b299 srnm S_RD "set rounding mode" esa
-b316 sqxbr RRE_FF "square root extended bfp" esa
-b315 sqdbr RRE_FF "square root long bfp" esa
-ed0000000015 sqdb RXE_FRRD "square root long bfp" esa
-b314 sqebr RRE_FF "square root short bfp" esa
-ed0000000014 sqeb RXE_FRRD "square root short bfp" esa
-b29c stfpc S_RD "store fpc" esa
-b34b sxbr RRE_FF "subtract extended bfp" esa
-b31b sdbr RRE_FF "subtract long bfp" esa
-ed000000001b sdb RXE_FRRD "subtract long bfp" esa
-b30b sebr RRE_FF "subtract short bfp" esa
-ed000000000b seb RXE_FRRD "subtract short bfp" esa
-ed0000000012 tcxb RXE_FRRD "test data class extended bfp" esa
-ed0000000011 tcdb RXE_FRRD "test data class long bfp" esa
-ed0000000010 tceb RXE_FRRD "test data class short bfp" esa
-b274 siga S_RD "signal adapter" esa
-# are the following instructions confidential ??
-b2a6 cuutf RRE_RR "convert unicode to utf-8" esa
-b2a7 cutfu RRE_RR "convert utf-8 to unicode" esa
-ee plo SS_RRRDRD2 "perform locked operation" esa
-b25a bsa RRE_RR "branch and set authority" esa
-b277 rp S_RD "resume program" esa
-0107 sckpf E "set clock programmable field" esa
-b27d stsi S_RD "store system information" esa
-01ff trap2 E "trap" esa
-b2ff trap4 S_RD "trap4" esa
+5a a RX_RRRD "add" g5 esa,zarch
+6a ad RX_FRRD "add normalized (long)" g5 esa,zarch
+2a adr RR_FF "add normalized (long)" g5 esa,zarch
+7a ae RX_FRRD "add normalized (short)" g5 esa,zarch
+3a aer RR_FF "add normalized (short)" g5 esa,zarch
+4a ah RX_RRRD "add halfword" g5 esa,zarch
+5e al RX_RRRD "add logical" g5 esa,zarch
+1e alr RR_RR "add logical" g5 esa,zarch
+fa ap SS_LLRDRD "add decimal" g5 esa,zarch
+1a ar RR_RR "add" g5 esa,zarch
+7e au RX_FRRD "add unnormalized (short)" g5 esa,zarch
+3e aur RR_FF "add unnormalized (short)" g5 esa,zarch
+6e aw RX_FRRD "add unnormalized (long)" g5 esa,zarch
+2e awr RR_FF "add unnormalized (long)" g5 esa,zarch
+36 axr RR_FF "add normalized" g5 esa,zarch
+b240 bakr RRE_RR "branch and stack" g5 esa,zarch
+45 bal RX_RRRD "branch and link" g5 esa,zarch
+05 balr RR_RR "branch and link" g5 esa,zarch
+4d bas RX_RRRD "branch and save" g5 esa,zarch
+0d basr RR_RR "branch and save" g5 esa,zarch
+0c bassm RR_RR "branch and save and set mode" g5 esa,zarch
+47 bc RX_URRD "branch on condition" g5 esa,zarch
+07 bcr RR_UR "branch on condition" g5 esa,zarch
+46 bct RX_RRRD "branch on count" g5 esa,zarch
+06 bctr RR_RR "branch on count" g5 esa,zarch
+b258 bsg RRE_RR "branch in subspace group" g5 esa,zarch
+0b bsm RR_RR "branch and set mode" g5 esa,zarch
+86 bxh RS_RRRD "branch on index high" g5 esa,zarch
+87 bxle RS_RRRD "branch on index low or equal" g5 esa,zarch
+59 c RX_RRRD "compare" g5 esa,zarch
+69 cd RX_FRRD "compare (long)" g5 esa,zarch
+29 cdr RR_FF "compare (long)" g5 esa,zarch
+bb cds RS_RRRD "compare double and swap" g5 esa,zarch
+79 ce RX_FRRD "compare (short)" g5 esa,zarch
+39 cer RR_FF "compare (short)" g5 esa,zarch
+b21a cfc S_RD "compare and form codeword" g5 esa,zarch
+49 ch RX_RRRD "compare halfword" g5 esa,zarch
+55 cl RX_RRRD "compare logical" g5 esa,zarch
+d5 clc SS_L0RDRD "compare logical" g5 esa,zarch
+0f clcl RR_RR "compare logical long" g5 esa,zarch
+95 cli SI_URD "compare logical" g5 esa,zarch
+bd clm RS_RURD "compare logical characters under mask" g5 esa,zarch
+15 clr RR_RR "compare logical" g5 esa,zarch
+b25d clst RRE_RR "compare logical string" g5 esa,zarch
+b263 cmpsc RRE_RR "compression call" g5 esa,zarch
+f9 cp SS_LLRDRD "compare decimal" g5 esa,zarch
+b24d cpya RRE_AA "copy access" g5 esa,zarch
+19 cr RR_RR "compare" g5 esa,zarch
+ba cs RS_RRRD "compare and swap" g5 esa,zarch
+b230 csch S_00 "clear subchannel" g5 esa,zarch
+b257 cuse RRE_RR "compare until substring equal" g5 esa,zarch
+b250 csp RRE_RR "compare and swap and purge" g5 esa,zarch
+4f cvb RX_RRRD "convert to binary" g5 esa,zarch
+4e cvd RX_RRRD "convert to decimal" g5 esa,zarch
+5d d RX_RRRD "divide" g5 esa,zarch
+6d dd RX_FRRD "divide (long)" g5 esa,zarch
+2d ddr RR_FF "divide (long)" g5 esa,zarch
+7d de RX_FRRD "divide (short)" g5 esa,zarch
+3d der RR_FF "divide (short)" g5 esa,zarch
+83 diag RS_RRRD "diagnose" g5 esa,zarch
+fd dp SS_LLRDRD "divide decimal" g5 esa,zarch
+1d dr RR_RR "divide" g5 esa,zarch
+b22d dxr RRE_F0 "divide (ext.)" g5 esa,zarch
+b24f ear RRE_RA "extract access" g5 esa,zarch
+de ed SS_L0RDRD "edit" g5 esa,zarch
+df edmk SS_L0RDRD "edit and mark" g5 esa,zarch
+b226 epar RRE_R0 "extract primary ASN" g5 esa,zarch
+b249 ereg RRE_RR "extract stacked registers" g5 esa,zarch
+b227 esar RRE_R0 "extract secondary ASN" g5 esa,zarch
+b24a esta RRE_RR "extract stacked state" g5 esa,zarch
+44 ex RX_RRRD "execute" g5 esa,zarch
+24 hdr RR_FF "halve (long)" g5 esa,zarch
+34 her RR_FF "halve (short)" g5 esa,zarch
+b231 hsch S_00 "halt subchannel" g5 esa,zarch
+b224 iac RRE_R0 "insert address space control" g5 esa,zarch
+43 ic RX_RRRD "insert character" g5 esa,zarch
+bf icm RS_RURD "insert characters under mask" g5 esa,zarch
+b20b ipk S_00 "insert PSW key" g5 esa,zarch
+b222 ipm RRE_R0 "insert program mask" g5 esa,zarch
+b221 ipte RRE_RR "invalidate page table entry" g5 esa,zarch
+b229 iske RRE_RR "insert storage key extended" g5 esa,zarch
+b223 ivsk RRE_RR "insert virtual storage key" g5 esa,zarch
+58 l RX_RRRD "load" g5 esa,zarch
+41 la RX_RRRD "load address" g5 esa,zarch
+51 lae RX_RRRD "load address extended" g5 esa,zarch
+9a lam RS_AARD "load access multiple" g5 esa,zarch
+e500 lasp SSE_RDRD "load address space parameters" g5 esa,zarch
+23 lcdr RR_FF "load complement (long)" g5 esa,zarch
+33 lcer RR_FF "load complement (short)" g5 esa,zarch
+13 lcr RR_RR "load complement" g5 esa,zarch
+b7 lctl RS_CCRD "load control" g5 esa,zarch
+68 ld RX_FRRD "load (long)" g5 esa,zarch
+28 ldr RR_FF "load (long)" g5 esa,zarch
+78 le RX_FRRD "load (short)" g5 esa,zarch
+38 ler RR_FF "load (short)" g5 esa,zarch
+48 lh RX_RRRD "load halfword" g5 esa,zarch
+98 lm RS_RRRD "load multiple" g5 esa,zarch
+21 lndr RR_FF "load negative (long)" g5 esa,zarch
+31 lner RR_FF "load negative (short)" g5 esa,zarch
+11 lnr RR_RR "load negative" g5 esa,zarch
+20 lpdr RR_FF "load positive (long)" g5 esa,zarch
+30 lper RR_FF "load positive (short)" g5 esa,zarch
+10 lpr RR_RR "load positive" g5 esa,zarch
+82 lpsw S_RD "load PSW" g5 esa,zarch
+18 lr RR_RR "load" g5 esa,zarch
+b1 lra RX_RRRD "load real address" g5 esa,zarch
+25 lrdr RR_FF "load rounded (ext. to long)" g5 esa,zarch
+35 lrer RR_FF "load rounded (long to short)" g5 esa,zarch
+25 ldxr RR_FF "load rounded (ext. to long)" g5 esa,zarch
+35 ledr RR_FF "load rounded (long to short)" g5 esa,zarch
+22 ltdr RR_FF "load and test (long)" g5 esa,zarch
+32 lter RR_FF "load and test (short)" g5 esa,zarch
+12 ltr RR_RR "load and test" g5 esa,zarch
+b24b lura RRE_RR "load using real address" g5 esa,zarch
+5c m RX_RRRD "multiply" g5 esa,zarch
+af mc SI_URD "monitor call" g5 esa,zarch
+6c md RX_FRRD "multiply (long)" g5 esa,zarch
+2c mdr RR_FF "multiply (long)" g5 esa,zarch
+7c me RX_FRRD "multiply (short to long)" g5 esa,zarch
+7c mde RX_FRRD "multiply (short to long)" g5 esa,zarch
+3c mer RR_FF "multiply (short to long)" g5 esa,zarch
+3c mder RR_FF "multiply short to long hfp" g5 esa,zarch
+4c mh RX_RRRD "multiply halfword" g5 esa,zarch
+fc mp SS_LLRDRD "multiply decimal" g5 esa,zarch
+1c mr RR_RR "multiply" g5 esa,zarch
+b232 msch S_RD "modify subchannel" g5 esa,zarch
+b247 msta RRE_R0 "modify stacked state" g5 esa,zarch
+d2 mvc SS_L0RDRD "move" g5 esa,zarch
+e50f mvcdk SSE_RDRD "move with destination key" g5 esa,zarch
+e8 mvcin SS_L0RDRD "move inverse" g5 esa,zarch
+d9 mvck SS_RRRDRD "move with key" g5 esa,zarch
+0e mvcl RR_RR "move long" g5 esa,zarch
+da mvcp SS_RRRDRD "move to primary" g5 esa,zarch
+db mvcs SS_RRRDRD "move to secondary" g5 esa,zarch
+e50e mvcsk SSE_RDRD "move with source key" g5 esa,zarch
+92 mvi SI_URD "move" g5 esa,zarch
+d1 mvn SS_L0RDRD "move numerics" g5 esa,zarch
+f1 mvo SS_LLRDRD "move with offset" g5 esa,zarch
+b254 mvpg RRE_RR "move page" g5 esa,zarch
+b255 mvst RRE_RR "move string" g5 esa,zarch
+d3 mvz SS_L0RDRD "move zones" g5 esa,zarch
+67 mxd RX_FRRD "multiply (long to ext.)" g5 esa,zarch
+27 mxdr RR_FF "multiply (long to ext.)" g5 esa,zarch
+26 mxr RR_FF "multiply (ext.)" g5 esa,zarch
+54 n RX_RRRD "AND" g5 esa,zarch
+d4 nc SS_L0RDRD "AND" g5 esa,zarch
+94 ni SI_URD "AND" g5 esa,zarch
+14 nr RR_RR "AND" g5 esa,zarch
+56 o RX_RRRD "OR" g5 esa,zarch
+d6 oc SS_L0RDRD "OR" g5 esa,zarch
+96 oi SI_URD "OR" g5 esa,zarch
+16 or RR_RR "OR" g5 esa,zarch
+f2 pack SS_LLRDRD "pack" g5 esa,zarch
+b248 palb RRE_00 "purge ALB" g5 esa,zarch
+b218 pc S_RD "program call" g5 esa,zarch
+0101 pr E "program return" g5 esa,zarch
+b228 pt RRE_RR "program transfer" g5 esa,zarch
+b20d ptlb S_00 "purge TLB" g5 esa,zarch
+b23b rchp S_00 "reset channel path" g5 esa,zarch
+b22a rrbe RRE_RR "reset reference bit extended" g5 esa,zarch
+b238 rsch S_00 "resume subchannel" g5 esa,zarch
+5b s RX_RRRD "subtract" g5 esa,zarch
+b219 sac S_RD "set address space control" g5 esa,zarch
+b279 sacf S_RD "set address space control fast" g5 esa,zarch
+b237 sal S_00 "set address limit" g5 esa,zarch
+b24e sar RRE_AR "set access" g5 esa,zarch
+b23c schm S_00 "set channel monitor" g5 esa,zarch
+b204 sck S_RD "set clock" g5 esa,zarch
+b206 sckc S_RD "set clock comparator" g5 esa,zarch
+6b sd RX_FRRD "subtract normalized (long)" g5 esa,zarch
+2b sdr RR_FF "subtract normalized (long)" g5 esa,zarch
+7b se RX_FRRD "subtract normalized (short)" g5 esa,zarch
+3b ser RR_FF "subtract normalized (short)" g5 esa,zarch
+4b sh RX_RRRD "subtract halfword" g5 esa,zarch
+b214 sie S_RD "start interpretive execution" g5 esa,zarch
+ae sigp RS_RRRD "signal processor" g5 esa,zarch
+5f sl RX_RRRD "subtract logical" g5 esa,zarch
+8b sla RS_R0RD "shift left single" g5 esa,zarch
+8f slda RS_R0RD "shift left double (long)" g5 esa,zarch
+8d sldl RS_R0RD "shift left double logical (long)" g5 esa,zarch
+89 sll RS_R0RD "shift left single logical" g5 esa,zarch
+1f slr RR_RR "subtract logical" g5 esa,zarch
+fb sp SS_LLRDRD "subtract decimal" g5 esa,zarch
+b20a spka S_RD "set PSW key from address" g5 esa,zarch
+04 spm RR_R0 "set program mask" g5 esa,zarch
+b208 spt S_RD "set CPU timer" g5 esa,zarch
+b210 spx S_RD "set prefix" g5 esa,zarch
+b244 sqdr RRE_F0 "square root (long)" g5 esa,zarch
+b245 sqer RRE_F0 "square root (short)" g5 esa,zarch
+1b sr RR_RR "subtract" g5 esa,zarch
+8a sra RS_R0RD "shift right single" g5 esa,zarch
+8e srda RS_R0RD "shift right double (long)" g5 esa,zarch
+8c srdl RS_R0RD "shift right double logical (long)" g5 esa,zarch
+88 srl RS_R0RD "shift right single logical" g5 esa,zarch
+f0 srp SS_LIRDRD "shift and round decimal" g5 esa,zarch
+b25e srst RRE_RR "search string" g5 esa,zarch
+b225 ssar RRE_R0 "set secondary ASN" g5 esa,zarch
+b233 ssch S_RD "start subchannel" g5 esa,zarch
+b22b sske RRE_RR "set storage key extended" g5 esa,zarch
+80 ssm S_RD "set system mask" g5 esa,zarch
+50 st RX_RRRD "store" g5 esa,zarch
+9b stam RS_AARD "store access multiple" g5 esa,zarch
+b212 stap S_RD "store CPU address" g5 esa,zarch
+42 stc RX_RRRD "store character" g5 esa,zarch
+b205 stck S_RD "store clock" g5 esa,zarch
+b207 stckc S_RD "store clock comparator" g5 esa,zarch
+be stcm RS_RURD "store characters under mask" g5 esa,zarch
+b23a stcps S_RD "store channel path status" g5 esa,zarch
+b239 stcrw S_RD "store channel report word" g5 esa,zarch
+b6 stctl RS_CCRD "store control" g5 esa,zarch
+60 std RX_FRRD "store (long)" g5 esa,zarch
+70 ste RX_FRRD "store (short)" g5 esa,zarch
+40 sth RX_RRRD "store halfword" g5 esa,zarch
+b202 stidp S_RD "store CPU id" g5 esa,zarch
+90 stm RS_RRRD "store multiple" g5 esa,zarch
+ac stnsm SI_URD "store then AND system mask" g5 esa,zarch
+ad stosm SI_URD "store then OR system mask" g5 esa,zarch
+b209 stpt S_RD "store CPU timer" g5 esa,zarch
+b211 stpx S_RD "store prefix" g5 esa,zarch
+b234 stsch S_RD "store subchannel" g5 esa,zarch
+b246 stura RRE_RR "store using real address" g5 esa,zarch
+7f su RX_FRRD "subtract unnormalized (short)" g5 esa,zarch
+3f sur RR_FF "subtract unnormalized (short)" g5 esa,zarch
+0a svc RR_U0 "supervisor call" g5 esa,zarch
+6f sw RX_FRRD "subtract unnormalized (long)" g5 esa,zarch
+2f swr RR_FF "subtract unnormalized (long)" g5 esa,zarch
+37 sxr RR_FF "subtract normalized (ext.)" g5 esa,zarch
+b24c tar RRE_AR "test access" g5 esa,zarch
+b22c tb RRE_0R "test block" g5 esa,zarch
+91 tm SI_URD "test under mask" g5 esa,zarch
+b236 tpi S_RD "test pending interruption" g5 esa,zarch
+e501 tprot SSE_RDRD "test protection" g5 esa,zarch
+dc tr SS_L0RDRD "translate" g5 esa,zarch
+99 trace RS_RRRD "trace" g5 esa,zarch
+dd trt SS_L0RDRD "translate and test" g5 esa,zarch
+93 ts S_RD "test and set" g5 esa,zarch
+b235 tsch S_RD "test subchannel" g5 esa,zarch
+f3 unpk SS_LLRDRD "unpack" g5 esa,zarch
+0102 upt E "update tree" g5 esa,zarch
+57 x RX_RRRD "exclusive OR" g5 esa,zarch
+d7 xc SS_L0RDRD "exclusive OR" g5 esa,zarch
+97 xi SI_URD "exclusive OR" g5 esa,zarch
+17 xr RR_RR "exclusive OR" g5 esa,zarch
+f8 zap SS_LLRDRD "zero and add" g5 esa,zarch
+a70a ahi RI_RI "add halfword immediate" g5 esa,zarch
+84 brxh RSI_RRP "branch relative on index high" g5 esa,zarch
+85 brxle RSI_RRP "branch relative on index low or equal" g5 esa,zarch
+a705 bras RI_RP "branch relative and save" g5 esa,zarch
+a704 brc RI_UP "branch relative on condition" g5 esa,zarch
+a706 brct RI_RP "branch relative on count" g5 esa,zarch
+b241 cksm RRE_RR "checksum" g5 esa,zarch
+a70e chi RI_RI "compare halfword immediate" g5 esa,zarch
+a9 clcle RS_RRRD "compare logical long extended" g5 esa,zarch
+a708 lhi RI_RI "load halfword immediate" g5 esa,zarch
+a8 mvcle RS_RRRD "move long extended" g5 esa,zarch
+a70c mhi RI_RI "multiply halfword immediate" g5 esa,zarch
+b252 msr RRE_RR "multiply single" g5 esa,zarch
+71 ms RX_RRRD "multiply single" g5 esa,zarch
+a700 tmh RI_RU "test under mask high" g5 esa,zarch
+a701 tml RI_RU "test under mask low" g5 esa,zarch
+0700 nopr RR_0R "no operation" g5 esa,zarch
+0710 bor RR_0R "branch on overflow / if ones" g5 esa,zarch
+0720 bhr RR_0R "branch on high" g5 esa,zarch
+0720 bpr RR_0R "branch on plus" g5 esa,zarch
+0730 bnler RR_0R "branch on not low or equal" g5 esa,zarch
+0740 blr RR_0R "branch on low" g5 esa,zarch
+0740 bmr RR_0R "branch on minus / if mixed" g5 esa,zarch
+0750 bnher RR_0R "branch on not high or equal" g5 esa,zarch
+0760 blhr RR_0R "branch on low or high" g5 esa,zarch
+0770 bner RR_0R "branch on not equal" g5 esa,zarch
+0770 bnzr RR_0R "branch on not zero / if not zeros" g5 esa,zarch
+0780 ber RR_0R "branch on equal" g5 esa,zarch
+0780 bzr RR_0R "branch on zero / if zeros" g5 esa,zarch
+0790 bnlhr RR_0R "branch on not low or high" g5 esa,zarch
+07a0 bher RR_0R "branch on high or equal" g5 esa,zarch
+07b0 bnlr RR_0R "branch on not low" g5 esa,zarch
+07b0 bnmr RR_0R "branch on not minus / if not mixed" g5 esa,zarch
+07c0 bler RR_0R "brach on low or equal" g5 esa,zarch
+07d0 bnhr RR_0R "branch on not high" g5 esa,zarch
+07d0 bnpr RR_0R "branch on not plus" g5 esa,zarch
+07e0 bnor RR_0R "branch on not overflow / if not ones" g5 esa,zarch
+07f0 br RR_0R "unconditional branch" g5 esa,zarch
+4700 nop RX_0RRD "no operation" g5 esa,zarch
+4710 bo RX_0RRD "branch on overflow / if ones" g5 esa,zarch
+4720 bh RX_0RRD "branch on high" g5 esa,zarch
+4720 bp RX_0RRD "branch on plus" g5 esa,zarch
+4730 bnle RX_0RRD "branch on not low or equal" g5 esa,zarch
+4740 bl RX_0RRD "branch on low" g5 esa,zarch
+4740 bm RX_0RRD "branch on minus / if mixed" g5 esa,zarch
+4750 bnhe RX_0RRD "branch on not high or equal" g5 esa,zarch
+4760 blh RX_0RRD "branch on low or high" g5 esa,zarch
+4770 bne RX_0RRD "branch on not equal" g5 esa,zarch
+4770 bnz RX_0RRD "branch on not zero / if not zeros" g5 esa,zarch
+4780 be RX_0RRD "branch on equal" g5 esa,zarch
+4780 bz RX_0RRD "branch on zero / if zeros" g5 esa,zarch
+4790 bnlh RX_0RRD "branch on not low or high" g5 esa,zarch
+47a0 bhe RX_0RRD "branch on high or equal" g5 esa,zarch
+47b0 bnl RX_0RRD "branch on not low" g5 esa,zarch
+47b0 bnm RX_0RRD "branch on not minus / if not mixed" g5 esa,zarch
+47c0 ble RX_0RRD "branch on low or equal" g5 esa,zarch
+47d0 bnh RX_0RRD "branch on not high" g5 esa,zarch
+47d0 bnp RX_0RRD "branch on not plus" g5 esa,zarch
+47e0 bno RX_0RRD "branch on not overflow / if not ones" g5 esa,zarch
+47f0 b RX_0RRD "unconditional branch" g5 esa,zarch
+a714 jo RI_0P "jump on overflow / if ones" g5 esa,zarch
+a724 jh RI_0P "jump on A high" g5 esa,zarch
+a724 jp RI_0P "jump on plus" g5 esa,zarch
+a734 jnle RI_0P "jump on not low or equal" g5 esa,zarch
+a744 jl RI_0P "jump on A low" g5 esa,zarch
+a744 jm RI_0P "jump on minus / if mixed" g5 esa,zarch
+a754 jnhe RI_0P "jump on not high or equal" g5 esa,zarch
+a764 jlh RI_0P "jump on low or high" g5 esa,zarch
+a774 jne RI_0P "jump on A not equal B" g5 esa,zarch
+a774 jnz RI_0P "jump on not zero / if not zeros" g5 esa,zarch
+a784 je RI_0P "jump on A equal B" g5 esa,zarch
+a784 jz RI_0P "jump on zero / if zeros" g5 esa,zarch
+a794 jnlh RI_0P "jump on not low or high" g5 esa,zarch
+a7a4 jhe RI_0P "jump on high or equal" g5 esa,zarch
+a7b4 jnl RI_0P "jump on A not low" g5 esa,zarch
+a7b4 jnm RI_0P "jump on not minus / if not mixed" g5 esa,zarch
+a7c4 jle RI_0P "jump on low or equal" g5 esa,zarch
+a7d4 jnh RI_0P "jump on A not high" g5 esa,zarch
+a7d4 jnp RI_0P "jump on not plus" g5 esa,zarch
+a7e4 jno RI_0P "jump on not overflow / if not ones" g5 esa,zarch
+a7f4 j RI_0P "jump" g5 esa,zarch
+b34a axbr RRE_FF "add extended bfp" g5 esa,zarch
+b31a adbr RRE_FF "add long bfp" g5 esa,zarch
+ed000000001a adb RXE_FRRD "add long bfp" g5 esa,zarch
+b30a aebr RRE_FF "add short bfp" g5 esa,zarch
+ed000000000a aeb RXE_FRRD "add short bfp" g5 esa,zarch
+b349 cxbr RRE_FF "compare extended bfp" g5 esa,zarch
+b319 cdbr RRE_FF "compare long bfp" g5 esa,zarch
+ed0000000019 cdb RXE_FRRD "compare long bfp" g5 esa,zarch
+b309 cebr RRE_FF "compare short bfp" g5 esa,zarch
+ed0000000009 ceb RXE_FRRD "compare short bfp" g5 esa,zarch
+b348 kxbr RRE_FF "compare and signal extended bfp" g5 esa,zarch
+b318 kdbr RRE_FF "compare and signal long bfp" g5 esa,zarch
+ed0000000018 kdb RXE_FRRD "compare and signal long bfp" g5 esa,zarch
+b308 kebr RRE_FF "compare and signal short bfp" g5 esa,zarch
+ed0000000008 keb RXE_FRRD "compare and signal short bfp" g5 esa,zarch
+b396 cxfbr RRE_RF "convert from fixed 32 to extended bfp" g5 esa,zarch
+b395 cdfbr RRE_RF "convert from fixed 32 to long bfp" g5 esa,zarch
+b394 cefbr RRE_RF "convert from fixed 32 to short bfp" g5 esa,zarch
+b39a cfxbr RRF_U0FR "convert to fixed extended bfp to 32" g5 esa,zarch
+b399 cfdbr RRF_U0FR "convert to fixed long bfp to 32" g5 esa,zarch
+b398 cfebr RRF_U0FR "convert to fixed short bfp to 32" g5 esa,zarch
+b34d dxbr RRE_FF "divide extended bfp" g5 esa,zarch
+b31d ddbr RRE_FF "divide long bfp" g5 esa,zarch
+ed000000001d ddb RXE_FRRD "divide long bfp" g5 esa,zarch
+b30d debr RRE_FF "divide short bfp" g5 esa,zarch
+ed000000000d deb RXE_FRRD "divide short bfp" g5 esa,zarch
+b35b didbr RRF_FUFF "divide to integer long bfp" g5 esa,zarch
+b353 diebr RRF_FUFF "divide to integer short bfp" g5 esa,zarch
+b38c efpc RRE_RR "extract fpc" g5 esa,zarch
+b342 ltxbr RRE_FF "load and test extended bfp" g5 esa,zarch
+b312 ltdbr RRE_FF "load and test long bfp" g5 esa,zarch
+b302 ltebr RRE_FF "load and test short bfp" g5 esa,zarch
+b343 lcxbr RRE_FF "load complement extended bfp" g5 esa,zarch
+b313 lcdbr RRE_FF "load complement long bfp" g5 esa,zarch
+b303 lcebr RRE_FF "load complement short bfp" g5 esa,zarch
+b347 fixbr RRF_U0FF "load fp integer extended bfp" g5 esa,zarch
+b35f fidbr RRF_U0FF "load fp integer long bfp" g5 esa,zarch
+b357 fiebr RRF_U0FF "load fp integer short bfp" g5 esa,zarch
+b29d lfpc S_RD "load fpc" g5 esa,zarch
+b305 lxdbr RRE_FF "load lengthened long to extended bfp" g5 esa,zarch
+ed0000000005 lxdb RXE_FRRD "load lengthened long to extended bfp" g5 esa,zarch
+b306 lxebr RRE_FF "load lengthened short to extended bfp" g5 esa,zarch
+ed0000000006 lxeb RXE_FRRD "load lengthened short to extended bfp" g5 esa,zarch
+b304 ldebr RRE_FF "load lengthened short to long bfp" g5 esa,zarch
+ed0000000004 ldeb RXE_FRRD "load lengthened short to long bfp" g5 esa,zarch
+b341 lnxbr RRE_FF "load negative extended bfp" g5 esa,zarch
+b311 lndbr RRE_FF "load negative long bfp" g5 esa,zarch
+b301 lnebr RRE_FF "load negative short bfp" g5 esa,zarch
+b340 lpxbr RRE_FF "load positive extended bfp" g5 esa,zarch
+b310 lpdbr RRE_FF "load positive long bfp" g5 esa,zarch
+b300 lpebr RRE_FF "load positive short bfp" g5 esa,zarch
+b345 ldxbr RRE_FF "load rounded extended to long bfp" g5 esa,zarch
+b346 lexbr RRE_FF "load rounded extended to short bfp" g5 esa,zarch
+b344 ledbr RRE_FF "load rounded long to short bfp" g5 esa,zarch
+b34c mxbr RRE_FF "multiply extended bfp" g5 esa,zarch
+b31c mdbr RRE_FF "multiply long bfp" g5 esa,zarch
+ed000000001c mdb RXE_FRRD "multiply long bfp" g5 esa,zarch
+b307 mxdbr RRE_FF "multiply long to extended bfp" g5 esa,zarch
+ed0000000007 mxdb RXE_FRRD "multiply long to extended bfp" g5 esa,zarch
+b317 meebr RRE_FF "multiply short bfp" g5 esa,zarch
+ed0000000017 meeb RXE_FRRD "multiply short bfp" g5 esa,zarch
+b30c mdebr RRE_FF "multiply short to long bfp" g5 esa,zarch
+ed000000000c mdeb RXE_FRRD "multiply short to long bfp" g5 esa,zarch
+b31e madbr RRF_F0FF "multiply and add long bfp" g5 esa,zarch
+ed000000001e madb RXF_FRRDF "multiply and add long bfp" g5 esa,zarch
+b30e maebr RRF_F0FF "multiply and add short bfp" g5 esa,zarch
+ed000000000e maeb RXF_FRRDF "multiply and add short bfp" g5 esa,zarch
+b31f msdbr RRF_F0FF "multiply and subtract long bfp" g5 esa,zarch
+ed000000001f msdb RXF_FRRDF "multiply and subtract long bfp" g5 esa,zarch
+b30f msebr RRF_F0FF "multiply and subtract short bfp" g5 esa,zarch
+ed000000000f mseb RXF_FRRDF "multiply and subtract short bfp" g5 esa,zarch
+b384 sfpc RRE_RR "set fpc" g5 esa,zarch
+b299 srnm S_RD "set rounding mode" g5 esa,zarch
+b316 sqxbr RRE_FF "square root extended bfp" g5 esa,zarch
+b315 sqdbr RRE_FF "square root long bfp" g5 esa,zarch
+ed0000000015 sqdb RXE_FRRD "square root long bfp" g5 esa,zarch
+b314 sqebr RRE_FF "square root short bfp" g5 esa,zarch
+ed0000000014 sqeb RXE_FRRD "square root short bfp" g5 esa,zarch
+b29c stfpc S_RD "store fpc" g5 esa,zarch
+b34b sxbr RRE_FF "subtract extended bfp" g5 esa,zarch
+b31b sdbr RRE_FF "subtract long bfp" g5 esa,zarch
+ed000000001b sdb RXE_FRRD "subtract long bfp" g5 esa,zarch
+b30b sebr RRE_FF "subtract short bfp" g5 esa,zarch
+ed000000000b seb RXE_FRRD "subtract short bfp" g5 esa,zarch
+ed0000000012 tcxb RXE_FRRD "test data class extended bfp" g5 esa,zarch
+ed0000000011 tcdb RXE_FRRD "test data class long bfp" g5 esa,zarch
+ed0000000010 tceb RXE_FRRD "test data class short bfp" g5 esa,zarch
+b274 siga S_RD "signal adapter" g5 esa,zarch
+b2a6 cuutf RRE_RR "convert unicode to utf-8" g5 esa,zarch
+b2a7 cutfu RRE_RR "convert utf-8 to unicode" g5 esa,zarch
+ee plo SS_RRRDRD2 "perform locked operation" g5 esa,zarch
+b25a bsa RRE_RR "branch and set authority" g5 esa,zarch
+b277 rp S_RD "resume program" g5 esa,zarch
+0107 sckpf E "set clock programmable field" g5 esa,zarch
+b27d stsi S_RD "store system information" g5 esa,zarch
+01ff trap2 E "trap" g5 esa,zarch
+b2ff trap4 S_RD "trap4" g5 esa,zarch
+a700 tmlh RI_RU "test under mask low high" g5 esa,zarch
+a701 tmll RI_RU "test under mask low low" g5 esa,zarch
+b278 stcke S_RD "store clock extended" g5 esa,zarch
+b2a5 tre RRE_RR "translate extended" g5 esa,zarch
+eb000000008e mvclu RSE_RRRD "move long unicode" g5 esa,zarch
+e9 pka SS_L0RDRD "pack ascii" g5 esa,zarch
+e1 pku SS_L0RDRD "pack unicode" g5 esa,zarch
+b993 troo RRE_RR "translate one to one" g5 esa,zarch
+b992 trot RRE_RR "translate one to two" g5 esa,zarch
+b991 trto RRE_RR "translate two to one" g5 esa,zarch
+b990 trtt RRE_RR "translate two to two" g5 esa,zarch
+ea unpka SS_L0RDRD "unpack ascii" g5 esa,zarch
+e2 unpku SS_L0RDRD "unpack unicode" g5 esa,zarch
+b358 thder RRE_RR "convert short bfp to long hfp" g5 esa,zarch
+b359 thdr RRE_RR "convert long bfp to long hfp" g5 esa,zarch
+b350 tbedr RRF_U0FF "convert long hfp to short bfp" g5 esa,zarch
+b351 tbdr RRF_U0FF "convert long hfp to long bfp" g5 esa,zarch
+b374 lzer RRE_R0 "load short zero" g5 esa,zarch
+b375 lzdr RRE_R0 "load long zero" g5 esa,zarch
+b376 lzxr RRE_R0 "load extended zero" g5 esa,zarch
# Here are the new esame instructions:
-b946 bctgr RRE_RR "branch on count 64" esame
-b900 lpgr RRE_RR "load positive 64" esame
-b910 lpgfr RRE_RR "load positive 64<32" esame
-b901 lngr RRE_RR "load negative 64" esame
-b911 lngfr RRE_RR "load negative 64<32" esame
-b902 ltgr RRE_RR "load and test 64" esame
-b912 ltgfr RRE_RR "load and test 64<32" esame
-b903 lcgr RRE_RR "load complement 64" esame
-b913 lcgfr RRE_RR "load complement 64<32" esame
-b980 ngr RRE_RR "and 64" esame
-b921 clgr RRE_RR "compare logical 64" esame
-b931 clgfr RRE_RR "compare logical 64<32" esame
-b981 ogr RRE_RR "or 64" esame
-b982 xgr RRE_RR "exclusive or 64" esame
-b904 lgr RRE_RR "load 64" esame
-b914 lgfr RRE_RR "load 64<32" esame
-b920 cgr RRE_RR "compare 64" esame
-b930 cgfr RRE_RR "compare 64<32" esame
-b908 agr RRE_RR "add 64" esame
-b918 agfr RRE_RR "add 64<32" esame
-b909 sgr RRE_RR "subtract 64" esame
-b919 sgfr RRE_RR "subtract 64<32" esame
-b90a algr RRE_RR "add logical 64" esame
-b91a algfr RRE_RR "add logical 64<32" esame
-b90b slgr RRE_RR "subtract logical 64" esame
-b91b slgfr RRE_RR "subtract logical 64<32" esame
-e30000000046 bctg RXE_RRRD "branch on count 64" esame
-e3000000002e cvdg RXE_RRRD "convert to decimal 64" esame
-e3000000000e cvbg RXE_RRRD "convert to binary 64" esame
-e30000000024 stg RXE_RRRD "store 64" esame
-e30000000080 ng RXE_RRRD "and 64" esame
-e30000000021 clg RXE_RRRD "compare logical 64" esame
-e30000000031 clgf RXE_RRRD "comparee logical 64<32" esame
-e30000000081 og RXE_RRRD "or 64" esame
-e30000000082 xg RXE_RRRD "exclusive or 64" esame
-e30000000004 lg RXE_RRRD "load 64" esame
-e30000000014 lgf RXE_RRRD "load 64<32" esame
-e30000000015 lgh RXE_RRRD "load halfword 64" esame
-e30000000020 cg RXE_RRRD "compare 64" esame
-e30000000030 cgf RXE_RRRD "compare 64<32" esame
-e30000000008 ag RXE_RRRD "add 64" esame
-e30000000018 agf RXE_RRRD "add 64<32" esame
-e30000000009 sg RXE_RRRD "subtract 64" esame
-e30000000019 sgf RXE_RRRD "subtract 64<32" esame
-e3000000000a alg RXE_RRRD "add logical 64" esame
-e3000000001a algf RXE_RRRD "add logical 64<32" esame
-e3000000000b slg RXE_RRRD "subtract logical 64" esame
-e3000000001b slgf RXE_RRRD "subtract logical 64<32" esame
-e3000000000c msg RXE_RRRD "multiply single 64" esame
-e3000000001c msgf RXE_RRRD "multiply single 64<32" esame
-ec0000000044 brxhg RIE_RRP "branch relative on index high 64" esame
-ec0000000045 brxlg RIE_RRP "branch relative on index low or equal 64" esame
-eb0000000044 bxhg RSE_RRRD "branch on index high 64" esame
-eb0000000045 bxleg RSE_RRRD "branch on index low or equal 64" esame
-eb000000000c srlg RSE_RRRD "shift right single logical 64" esame
-eb000000000d sllg RSE_RRRD "shift left single logical 64" esame
-eb000000000a srag RSE_RRRD "shift right single 64" esame
-eb000000000b slag RSE_RRRD "shift left single 64" esame
-eb0000000024 stmg RSE_RRRD "store multiple 64" esame
-eb0000000026 stmh RSE_RRRD "store multiple high" esame
-eb0000000004 lmg RSE_RRRD "load multiple 64" esame
-eb0000000096 lmh RSE_RRRD "load multiple high" esame
-ef lmd SS_RRRDRD3 "load multiple disjoint" esame
-eb000000000f tracg RSE_RRRD "trace 64" esame
-e30000000003 lrag RXE_RRRD "load real address 64" esame
-e50000000002 strag SSE_RDRD "store read address" esame
-eb0000000025 stctg RSE_RRRD "store control 64" esame
-eb000000002f lctlg RSE_RRRD "load control 64" esame
-eb0000000030 csg RSE_RRRD "compare and swap 64" esame
-eb000000003e cdsg RSE_RRRD "compare double and swap 64" esame
-eb0000000020 clmh RSE_RURD "compare logical characters under mask high" esame
-eb000000002c stcmh RSE_RURD "store characters under mask high" esame
-eb0000000080 icmh RSE_RURD "insert characters under mask high" esame
-a700 tmlh RI_RU "test under mask low high" esame
-a702 tmhh RI_RU "test under mask high high" esame
-a701 tmll RI_RU "test under mask low low" esame
-a703 tmhl RI_RU "test under mask high low" esame
-c004 brcl RIL_UP "branch relative on condition long" esame
-c014 jgo RIL_0P "jump long on overflow / if ones" esame
-c024 jgh RIL_0P "jump long on high" esame
-c024 jgp RIL_0P "jump long on plus" esame
-c034 jgnle RIL_0P "jump long on not low or equal" esame
-c044 jgl RIL_0P "jump long on low" esame
-c044 jgm RIL_0P "jump long on minus / if mixed" esame
-c054 jgnhe RIL_0P "jump long on not high or equal" esame
-c064 jglh RIL_0P "jump long on low or high" esame
-c074 jgne RIL_0P "jump long on not equal" esame
-c074 jgnz RIL_0P "jump long on not zero / if not zeros" esame
-c084 jge RIL_0P "jump long on equal" esame
-c084 jgz RIL_0P "jump long on zero / if zeros" esame
-c094 jgnlh RIL_0P "jump long on not low or high" esame
-c0a4 jghe RIL_0P "jump long on high or equal" esame
-c0b4 jgnl RIL_0P "jump long on not low" esame
-c0b4 jgnm RIL_0P "jump long on not minus / if not mixed" esame
-c0c4 jgle RIL_0P "jump long on low or equal" esame
-c0d4 jgnh RIL_0P "jump long on not high" esame
-c0d4 jgnp RIL_0P "jump long on not plus" esame
-c0e4 jgno RIL_0P "jump long on not overflow / if not ones" esame
-c0f4 jg RIL_0P "jump long" esame
-c005 brasl RIL_RP "branch relative and save long" esame
-a707 brctg RI_RP "branch relative on count 64" esame
-a709 lghi RI_RI "load halfword immediate 64" esame
-a70b aghi RI_RI "add halfword immediate 64" esame
-a70d mghi RI_RI "multiply halfword immediate 64" esame
-a70f cghi RI_RI "compare halfword immediate 64" esame
-b925 sturg RRE_RR "store using real address 64" esame
-b90e eregg RRE_RR "extract stacked registers 64" esame
-b905 lurag RRE_RR "load using real address 64" esame
-b90c msgr RRE_RR "multiply single 64" esame
-b91c msgfr RRE_RR "multiply single 64<32" esame
-b3a4 cegbr RRE_RR "convert from fixed 64 to short bfp" esame
-b3a5 cdgbr RRE_RR "convert from fixed 64 to long bfp" esame
-b3a6 cxgbr RRE_RR "convert from fixed 64 to extended bfp" esame
-b3a8 cgebr RRF_U0FR "convert to fixed short bfd to 64" esame
-b3a9 cgdbr RRF_U0FR "convert to fixed long bfp to 64" esame
-b3aa cgxbr RRF_U0FR "convert to fixed extended bfp to 64" esame
-b3c4 cegr RRE_RR "convert from fixed 64 to short hfp" esame
-b3c5 cdgr RRE_RR "convert from fixed 64 to long hfp" esame
-b3c6 cxgr RRE_RR "convert from fixed 64 to extended hfp" esame
-b3c8 cger RRF_U0FR "convert to fixed short hfp to 64" esame
-b3c9 cgdr RRF_U0FR "convert to fixed long hfp to 64" esame
-b3ca cgxr RRF_U0FR "convert to fixed extended hfp to 64" esame
-010b tam E "test addressing mode" esame
-010c sam24 E "set addressing mode 24" esame
-010d sam31 E "set addressing mode 31" esame
-010e sam64 E "set addressing mode 64" esame
-a500 iihh RI_RU "insert immediate high high" esame
-a501 iihl RI_RU "insert immediate high low" esame
-a502 iilh RI_RU "insert immediate low high" esame
-a503 iill RI_RU "insert immediate low low" esame
-a504 nihh RI_RU "and immediate high high" esame
-a505 nihl RI_RU "and immediate high low" esame
-a506 nilh RI_RU "and immediate low high" esame
-a507 nill RI_RU "and immediate low low" esame
-a508 oihh RI_RU "or immediate high high" esame
-a509 oihl RI_RU "or immediate high low" esame
-a50a oilh RI_RU "or immediate low high" esame
-a50b oill RI_RU "or immediate low low" esame
-a50c llihh RI_RU "load logical immediate high high" esame
-a50d llihl RI_RU "load logical immediate high low" esame
-a50e llilh RI_RU "load logical immediate low high" esame
-a50f llill RI_RU "load logical immediate low low" esame
-b2b1 stfl S_RD "store facility list" esame
-b2b2 lpswe S_RD "load psw extended" esame
-b90d dsgr RRE_RR "divide single 64" esame
-b90f lrvgr RRE_RR "load reversed 64" esame
-b916 llgfr RRE_RR "load logical 64<32" esame
-b917 llgtr RRE_RR "load logical thirty one bits" esame
-b91d dsgfr RRE_RR "divide single 64<32" esame
-b91f lrvr RRE_RR "load reversed 32" esame
-b986 mlgr RRE_RR "multiply logical 64" esame
-b987 dlgr RRE_RR "divide logical 64" esame
-b988 alcgr RRE_RR "add logical with carry 64" esame
-b989 slbgr RRE_RR "subtract logical with borrow 64" esame
-b98d epsw RRE_RR "extract psw" esame
-b996 mlr RRE_RR "multiply logical 32" esame
-b997 dlr RRE_RR "divide logical 32" esame
-b998 alcr RRE_RR "add logical with carry 32" esame
-b999 slbr RRE_RR "subtract logical with borrow 32" esame
-b99d esea RRE_R0 "extract and set extended authority" esame
-c000 larl RIL_RP "load address relative long" esame
-e3000000000d dsg RXE_RRRD "divide single 64" esame
-e3000000000f lrvg RXE_RRRD "load reversed 64" esame
-e30000000016 llgf RXE_RRRD "load logical 64<32" esame
-e30000000017 llgt RXE_RRRD "load logical thirty one bits" esame
-e3000000001d dsgf RXE_RRRD "divide single 64<32" esame
-e3000000001e lrv RXE_RRRD "load reversed 32" esame
-e3000000001f lrvh RXE_RRRD "load reversed 16" esame
-e3000000002f strvg RXE_RRRD "store reversed 64" esame
-e3000000003e strv RXE_RRRD "store reversed 32" esame
-e3000000003f strvh RXE_RRRD "store reversed 64" esame
-e30000000086 mlg RXE_RRRD "multiply logical 64" esame
-e30000000087 dlg RXE_RRRD "divide logical 64" esame
-e30000000088 alcg RXE_RRRD "add logical with carry 64" esame
-e30000000089 slbg RXE_RRRD "subtract logical with borrow 64" esame
-e3000000008e stpq RXE_RRRD "store pair to quadword" esame
-e3000000008f lpq RXE_RRRD "load pair from quadword" esame
-e30000000096 ml RXE_RRRD "multiply logical 32" esame
-e30000000097 dl RXE_RRRD "divide logical 32" esame
-e30000000098 alc RXE_RRRD "add logical with carry 32" esame
-e30000000099 slb RXE_RRRD "subtract logical with borrow 32" esame
-e30000000090 llgc RXE_RRRD "load logical character" esame
-e30000000091 llgh RXE_RRRD "load logical halfword" esame
-eb000000001c rllg RSE_RRRD "rotate left single logical 64" esame
-eb000000001d rll RSE_RRRD "rotate left single logical 32" esame
-b278 stcke S_RD "store clock extended" esame
-b2a5 tre RRE_RR "translate extended" esame
-eb000000008e mvclu RSE_RRRD "move long unicode" esame
-e9 pka SS_L0RDRD "pack ascii" esame
-e1 pku SS_L0RDRD "pack unicode" esame
-b993 troo RRE_RR "translate one to one" esame
-b992 trot RRE_RR "translate one to two" esame
-b991 trto RRE_RR "translate two to one" esame
-b990 trtt RRE_RR "translate two to two" esame
-ea unpka SS_L0RDRD "unpack ascii" esame
-e2 unpku SS_L0RDRD "unpack unicode" esame
-b358 thder RRE_RR "convert short bfp to long hfp" esame
-b359 thdr RRE_RR "convert long bfp to long hfp" esame
-b350 tbedr RRF_U0FF "convert long hfp to short bfp" esame
-b351 tbdr RRF_U0FF "convert long hfp to long bfp" esame
-b374 lzer RRE_R0 "load short zero" esame
-b375 lzdr RRE_R0 "load long zero" esame
-b376 lzxr RRE_R0 "load extended zero" esame
+b946 bctgr RRE_RR "branch on count 64" z900 zarch
+b900 lpgr RRE_RR "load positive 64" z900 zarch
+b910 lpgfr RRE_RR "load positive 64<32" z900 zarch
+b901 lngr RRE_RR "load negative 64" z900 zarch
+b911 lngfr RRE_RR "load negative 64<32" z900 zarch
+b902 ltgr RRE_RR "load and test 64" z900 zarch
+b912 ltgfr RRE_RR "load and test 64<32" z900 zarch
+b903 lcgr RRE_RR "load complement 64" z900 zarch
+b913 lcgfr RRE_RR "load complement 64<32" z900 zarch
+b980 ngr RRE_RR "and 64" z900 zarch
+b921 clgr RRE_RR "compare logical 64" z900 zarch
+b931 clgfr RRE_RR "compare logical 64<32" z900 zarch
+b981 ogr RRE_RR "or 64" z900 zarch
+b982 xgr RRE_RR "exclusive or 64" z900 zarch
+b904 lgr RRE_RR "load 64" z900 zarch
+b914 lgfr RRE_RR "load 64<32" z900 zarch
+b920 cgr RRE_RR "compare 64" z900 zarch
+b930 cgfr RRE_RR "compare 64<32" z900 zarch
+b908 agr RRE_RR "add 64" z900 zarch
+b918 agfr RRE_RR "add 64<32" z900 zarch
+b909 sgr RRE_RR "subtract 64" z900 zarch zarch
+b919 sgfr RRE_RR "subtract 64<32" z900 zarch
+b90a algr RRE_RR "add logical 64" z900 zarch
+b91a algfr RRE_RR "add logical 64<32" z900 zarch
+b90b slgr RRE_RR "subtract logical 64" z900 zarch
+b91b slgfr RRE_RR "subtract logical 64<32" z900 zarch
+e30000000046 bctg RXE_RRRD "branch on count 64" z900 zarch
+e3000000002e cvdg RXE_RRRD "convert to decimal 64" z900 zarch
+e3000000000e cvbg RXE_RRRD "convert to binary 64" z900 zarch
+e30000000024 stg RXE_RRRD "store 64" z900 zarch
+e30000000080 ng RXE_RRRD "and 64" z900 zarch
+e30000000021 clg RXE_RRRD "compare logical 64" z900 zarch
+e30000000031 clgf RXE_RRRD "comparee logical 64<32" z900 zarch
+e30000000081 og RXE_RRRD "or 64" z900 zarch
+e30000000082 xg RXE_RRRD "exclusive or 64" z900 zarch
+e30000000004 lg RXE_RRRD "load 64" z900 zarch
+e30000000014 lgf RXE_RRRD "load 64<32" z900 zarch
+e30000000015 lgh RXE_RRRD "load halfword 64" z900 zarch
+e30000000020 cg RXE_RRRD "compare 64" z900 zarch
+e30000000030 cgf RXE_RRRD "compare 64<32" z900 zarch
+e30000000008 ag RXE_RRRD "add 64" z900 zarch
+e30000000018 agf RXE_RRRD "add 64<32" z900 zarch
+e30000000009 sg RXE_RRRD "subtract 64" z900 zarch
+e30000000019 sgf RXE_RRRD "subtract 64<32" z900 zarch
+e3000000000a alg RXE_RRRD "add logical 64" z900 zarch
+e3000000001a algf RXE_RRRD "add logical 64<32" z900 zarch
+e3000000000b slg RXE_RRRD "subtract logical 64" z900 zarch
+e3000000001b slgf RXE_RRRD "subtract logical 64<32" z900 zarch
+e3000000000c msg RXE_RRRD "multiply single 64" z900 zarch
+e3000000001c msgf RXE_RRRD "multiply single 64<32" z900 zarch
+ec0000000044 brxhg RIE_RRP "branch relative on index high 64" z900 zarch
+ec0000000045 brxlg RIE_RRP "branch relative on index low or equal 64" z900 zarch
+eb0000000044 bxhg RSE_RRRD "branch on index high 64" z900 zarch
+eb0000000045 bxleg RSE_RRRD "branch on index low or equal 64" z900 zarch
+eb000000000c srlg RSE_RRRD "shift right single logical 64" z900 zarch
+eb000000000d sllg RSE_RRRD "shift left single logical 64" z900 zarch
+eb000000000a srag RSE_RRRD "shift right single 64" z900 zarch
+eb000000000b slag RSE_RRRD "shift left single 64" z900 zarch
+eb0000000024 stmg RSE_RRRD "store multiple 64" z900 zarch
+eb0000000026 stmh RSE_RRRD "store multiple high" z900 zarch
+eb0000000004 lmg RSE_RRRD "load multiple 64" z900 zarch
+eb0000000096 lmh RSE_RRRD "load multiple high" z900 zarch
+ef lmd SS_RRRDRD3 "load multiple disjoint" z900 zarch
+eb000000000f tracg RSE_RRRD "trace 64" z900 zarch
+e30000000003 lrag RXE_RRRD "load real address 64" z900 zarch
+e50000000002 strag SSE_RDRD "store read address" z900 zarch
+eb0000000025 stctg RSE_RRRD "store control 64" z900 zarch
+eb000000002f lctlg RSE_RRRD "load control 64" z900 zarch
+eb0000000030 csg RSE_RRRD "compare and swap 64" z900 zarch
+eb000000003e cdsg RSE_RRRD "compare double and swap 64" z900 zarch
+eb0000000020 clmh RSE_RURD "compare logical characters under mask high" z900 zarch
+eb000000002c stcmh RSE_RURD "store characters under mask high" z900 zarch
+eb0000000080 icmh RSE_RURD "insert characters under mask high" z900 zarch
+a702 tmhh RI_RU "test under mask high high" z900 zarch
+a703 tmhl RI_RU "test under mask high low" z900 zarch
+c004 brcl RIL_UP "branch relative on condition long" z900 esa,zarch
+c014 jgo RIL_0P "jump long on overflow / if ones" z900 esa,zarch
+c024 jgh RIL_0P "jump long on high" z900 esa,zarch
+c024 jgp RIL_0P "jump long on plus" z900 esa,zarch
+c034 jgnle RIL_0P "jump long on not low or equal" z900 esa,zarch
+c044 jgl RIL_0P "jump long on low" z900 esa,zarch
+c044 jgm RIL_0P "jump long on minus / if mixed" z900 esa,zarch
+c054 jgnhe RIL_0P "jump long on not high or equal" z900 esa,zarch
+c064 jglh RIL_0P "jump long on low or high" z900 esa,zarch
+c074 jgne RIL_0P "jump long on not equal" z900 esa,zarch
+c074 jgnz RIL_0P "jump long on not zero / if not zeros" z900 esa,zarch
+c084 jge RIL_0P "jump long on equal" z900 esa,zarch
+c084 jgz RIL_0P "jump long on zero / if zeros" z900 esa,zarch
+c094 jgnlh RIL_0P "jump long on not low or high" z900 esa,zarch
+c0a4 jghe RIL_0P "jump long on high or equal" z900 esa,zarch
+c0b4 jgnl RIL_0P "jump long on not low" z900 esa,zarch
+c0b4 jgnm RIL_0P "jump long on not minus / if not mixed" z900 esa,zarch
+c0c4 jgle RIL_0P "jump long on low or equal" z900 esa,zarch
+c0d4 jgnh RIL_0P "jump long on not high" z900 esa,zarch
+c0d4 jgnp RIL_0P "jump long on not plus" z900 esa,zarch
+c0e4 jgno RIL_0P "jump long on not overflow / if not ones" z900 esa,zarch
+c0f4 jg RIL_0P "jump long" z900 esa,zarch
+c005 brasl RIL_RP "branch relative and save long" z900 esa,zarch
+a707 brctg RI_RP "branch relative on count 64" z900 zarch
+a709 lghi RI_RI "load halfword immediate 64" z900 zarch
+a70b aghi RI_RI "add halfword immediate 64" z900 zarch
+a70d mghi RI_RI "multiply halfword immediate 64" z900 zarch
+a70f cghi RI_RI "compare halfword immediate 64" z900 zarch
+b925 sturg RRE_RR "store using real address 64" z900 zarch
+b90e eregg RRE_RR "extract stacked registers 64" z900 zarch
+b905 lurag RRE_RR "load using real address 64" z900 zarch
+b90c msgr RRE_RR "multiply single 64" z900 zarch
+b91c msgfr RRE_RR "multiply single 64<32" z900 zarch
+b3a4 cegbr RRE_RR "convert from fixed 64 to short bfp" z900 zarch
+b3a5 cdgbr RRE_RR "convert from fixed 64 to long bfp" z900 zarch
+b3a6 cxgbr RRE_RR "convert from fixed 64 to extended bfp" z900 zarch
+b3a8 cgebr RRF_U0FR "convert to fixed short bfd to 64" z900 zarch
+b3a9 cgdbr RRF_U0FR "convert to fixed long bfp to 64" z900 zarch
+b3aa cgxbr RRF_U0FR "convert to fixed extended bfp to 64" z900 zarch
+b3c4 cegr RRE_RR "convert from fixed 64 to short hfp" z900 zarch
+b3c5 cdgr RRE_RR "convert from fixed 64 to long hfp" z900 zarch
+b3c6 cxgr RRE_RR "convert from fixed 64 to extended hfp" z900 zarch
+b3c8 cger RRF_U0FR "convert to fixed short hfp to 64" z900 zarch
+b3c9 cgdr RRF_U0FR "convert to fixed long hfp to 64" z900 zarch
+b3ca cgxr RRF_U0FR "convert to fixed extended hfp to 64" z900 zarch
+010b tam E "test addressing mode" z900 esa,zarch
+010c sam24 E "set addressing mode 24" z900 esa,zarch
+010d sam31 E "set addressing mode 31" z900 esa,zarch
+010e sam64 E "set addressing mode 64" z900 zarch
+a500 iihh RI_RU "insert immediate high high" z900 zarch
+a501 iihl RI_RU "insert immediate high low" z900 zarch
+a502 iilh RI_RU "insert immediate low high" z900 zarch
+a503 iill RI_RU "insert immediate low low" z900 zarch
+a504 nihh RI_RU "and immediate high high" z900 zarch
+a505 nihl RI_RU "and immediate high low" z900 zarch
+a506 nilh RI_RU "and immediate low high" z900 zarch
+a507 nill RI_RU "and immediate low low" z900 zarch
+a508 oihh RI_RU "or immediate high high" z900 zarch
+a509 oihl RI_RU "or immediate high low" z900 zarch
+a50a oilh RI_RU "or immediate low high" z900 zarch
+a50b oill RI_RU "or immediate low low" z900 zarch
+a50c llihh RI_RU "load logical immediate high high" z900 zarch
+a50d llihl RI_RU "load logical immediate high low" z900 zarch
+a50e llilh RI_RU "load logical immediate low high" z900 zarch
+a50f llill RI_RU "load logical immediate low low" z900 zarch
+b2b1 stfl S_RD "store facility list" z900 esa,zarch
+b2b2 lpswe S_RD "load psw extended" z900 zarch
+b90d dsgr RRE_RR "divide single 64" z900 zarch
+b90f lrvgr RRE_RR "load reversed 64" z900 zarch
+b916 llgfr RRE_RR "load logical 64<32" z900 zarch
+b917 llgtr RRE_RR "load logical thirty one bits" z900 zarch
+b91d dsgfr RRE_RR "divide single 64<32" z900 zarch
+b91f lrvr RRE_RR "load reversed 32" z900 esa,zarch
+b986 mlgr RRE_RR "multiply logical 64" z900 zarch
+b987 dlgr RRE_RR "divide logical 64" z900 zarch
+b988 alcgr RRE_RR "add logical with carry 64" z900 zarch
+b989 slbgr RRE_RR "subtract logical with borrow 64" z900 zarch
+b98d epsw RRE_RR "extract psw" z900 esa,zarch
+b996 mlr RRE_RR "multiply logical 32" z900 esa,zarch
+b997 dlr RRE_RR "divide logical 32" z900 esa,zarch
+b998 alcr RRE_RR "add logical with carry 32" z900 esa,zarch
+b999 slbr RRE_RR "subtract logical with borrow 32" z900 esa,zarch
+b99d esea RRE_R0 "extract and set extended authority" z900 zarch
+c000 larl RIL_RP "load address relative long" z900 esa,zarch
+e3000000000d dsg RXE_RRRD "divide single 64" z900 zarch
+e3000000000f lrvg RXE_RRRD "load reversed 64" z900 zarch
+e30000000016 llgf RXE_RRRD "load logical 64<32" z900 zarch
+e30000000017 llgt RXE_RRRD "load logical thirty one bits" z900 zarch
+e3000000001d dsgf RXE_RRRD "divide single 64<32" z900 zarch
+e3000000001e lrv RXE_RRRD "load reversed 32" z900 esa,zarch
+e3000000001f lrvh RXE_RRRD "load reversed 16" z900 esa,zarch
+e3000000002f strvg RXE_RRRD "store reversed 64" z900 zarch
+e3000000003e strv RXE_RRRD "store reversed 32" z900 esa,zarch
+e3000000003f strvh RXE_RRRD "store reversed 64" z900 esa,zarch
+e30000000086 mlg RXE_RRRD "multiply logical 64" z900 zarch
+e30000000087 dlg RXE_RRRD "divide logical 64" z900 zarch
+e30000000088 alcg RXE_RRRD "add logical with carry 64" z900 zarch
+e30000000089 slbg RXE_RRRD "subtract logical with borrow 64" z900 zarch
+e3000000008e stpq RXE_RRRD "store pair to quadword" z900 zarch
+e3000000008f lpq RXE_RRRD "load pair from quadword" z900 zarch
+e30000000096 ml RXE_RRRD "multiply logical 32" z900 esa,zarch
+e30000000097 dl RXE_RRRD "divide logical 32" z900 esa,zarch
+e30000000098 alc RXE_RRRD "add logical with carry 32" z900 esa,zarch
+e30000000099 slb RXE_RRRD "subtract logical with borrow 32" z900 esa,zarch
+e30000000090 llgc RXE_RRRD "load logical character" z900 zarch
+e30000000091 llgh RXE_RRRD "load logical halfword" z900 zarch
+eb000000001c rllg RSE_RRRD "rotate left single logical 64" z900 zarch
+eb000000001d rll RSE_RRRD "rotate left single logical 32" z900 esa,zarch
+b369 cxr RRE_FF "compare extended hfp" g5 esa,zarch
+b3b6 cxfr RRE_RF "convert from fixed 32 to extended hfp" g5 esa,zarch
+b3b5 cdfr RRE_RF "convert from fixed 32 to long hfp" g5 esa,zarch
+b3b4 cefr RRE_RF "convert from fixed 32 to short hfp" g5 esa,zarch
+b3ba cfxr RRF_U0FR "convert to fixed extended hfp to 32" z900 zarch
+b3b9 cfdr RRF_U0FR "convert to fixed long hfp to 32" z900 zarch
+b3b8 cfer RRF_U0FR "convert to fixed short hfp to 32" z900 zarch
+b362 ltxr RRE_FF "load and test extended hfp" g5 esa,zarch
+b363 lcxr RRE_FF "load complement extended hfp" g5 esa,zarch
+b367 fixr RRF_U0FF "load fp integer extended hfp" g5 esa,zarch
+b37f fidr RRF_U0FF "load fp integer long hfp" g5 esa,zarch
+b377 fier RRF_U0FF "load fp integer short hfp" g5 esa,zarch
+b325 lxdr RRE_FF "load lengthened long to extended hfp" g5 esa,zarch
+ed0000000025 lxd RXE_FRRD "load lengthened long to extended hfp" g5 esa,zarch
+b326 lxer RRE_FF "load lengthened short to extended hfp" g5 esa,zarch
+ed0000000026 lxe RXE_FRRD "load lengthened short to extended hfp" g5 esa,zarch
+b324 lder RRE_FF "load lengthened short to long hfp" g5 esa,zarch
+ed0000000024 lde RXE_FRRD "load lengthened short to long hfp" g5 esa,zarch
+b361 lnxr RRE_FF "load negative long hfp" g5 esa,zarch
+b360 lpxr RRE_FF "load positive long hfp" g5 esa,zarch
+b366 lexr RRE_FF "load rounded extended to short hfp" g5 esa,zarch
+35 ledr RR_FF "load rounded long to short hfp" g5 esa,zarch
+b337 meer RRE_FF "multiply short hfp" g5 esa,zarch
+ed0000000037 mee RXE_FRRD "multiply short hfp" g5 esa,zarch
+b336 sqxr RRE_FF "square root extended hfp" g5 esa,zarch
+ed0000000034 sqe RXE_FRRD "square root short hfp" g5 esa,zarch
+b263 cmpsc RRE_RR "compression call" g5 esa,zarch
+eb00000000c0 tp RSL_R0RD "test decimal" g5 esa,zarch
+b365 lxr RRE_RR "load extended hfp" g5 esa,zarch
+b22e pgin RRE_RR "page in" g5 esa,zarch
+b22f pgout RRE_RR "page out" g5 esa,zarch
+b276 xsch S_00 "cancel subchannel" g5 esa,zarch
+# New long displacement instructions on z990
+e3000000005a ay RXY_RRRD "add with long offset" z990 zarch
+e3000000007a ahy RXY_RRRD "add halfword with long offset" z990 zarch
+e3000000005e aly RXY_RRRD "add logical with long offset" z990 zarch
+eb0000000054 niy SIY_URD "and immediate with long offset" z990 zarch
+e30000000054 ny RXY_RRRD "and with long offset" z990 zarch
+e30000000059 cy RXY_RRRD "compare with long offset" z990 zarch
+eb0000000014 csy RSY_RRRD "compare and swap with long offset" z990 zarch
+eb0000000031 cdsy RSY_RRRD "compare double and swap with long offset" z990 zarch
+e30000000079 chy RXY_RRRD "compare halfword with long offset" z990 zarch
+e30000000055 cly RXY_RRRD "compare logical with long offset" z990 zarch
+eb0000000055 cliy SIY_URD "compare logical immediate with long offset" z990 zarch
+eb0000000021 clmy RSY_RURD "compare logical characters under mask with long offset" z990 zarch
+e30000000006 cvby RXY_RRRD "convert to binary with long offset" z990 zarch
+e30000000026 cvdy RXY_RRRD "convert to decimal with long offset" z990 zarch
+eb0000000057 xiy SIY_URD "exclusive or immediate with long offset" z990 zarch
+e30000000057 xy RXY_RRRD "exclusive or with long offset" z990 zarch
+e30000000073 icy RXY_RRRD "insert character with long offset" z990 zarch
+eb0000000081 icmy RSY_RURD "insert characters with long offset" z990 zarch
+ed0000000065 ldy RXY_FRRD "load (long) with long offset" z990 zarch
+ed0000000064 ley RXY_FRRD "load (short) with long offset" z990 zarch
+e30000000058 ly RXY_RRRD "load with long offset" z990 zarch
+eb000000009a lamy RSY_AARD "load access multiple" z990 zarch
+e30000000071 lay RXY_RRRD "load address with long offset" z990 zarch
+e30000000076 lb RXY_RRRD "load byte with long offset" z990 zarch
+e30000000077 lgb RXY_RRRD "load byte with long offset 64" z990 zarch
+e30000000078 lhy RXY_RRRD "load halfword with long offset" z990 zarch
+eb0000000098 lmy RSY_RRRD "load multiple with long offset" z990 zarch
+e30000000013 lray RXY_RRRD "load real address with long offset" z990 zarch
+eb0000000052 mviy SIY_URD "move immediate with long offset" z990 zarch
+e30000000051 msy RXY_RRRD "multiply single with long offset" z990 zarch
+eb0000000056 oiy SIY_URD "or immediate with long offset" z990 zarch
+e30000000056 oy RXY_RRRD "or with long offset" z990 zarch
+ed0000000067 stdy RXY_FRRD "load (long) with long offset" z990 zarch
+ed0000000066 stey RXY_FRRD "load (short) with long offset" z990 zarch
+e30000000050 sty RXY_RRRD "store with long offset" z990 zarch
+eb000000009b stamy RSY_AARD "store access multiple with long offset" z990 zarch
+e30000000072 stcy RXY_RRRD "store character with long offset" z990 zarch
+eb000000002d stcmy RSY_RURD "store characters under mask with long offset" z990 zarch
+e30000000070 sthy RXY_RRRD "store halfword with long offset" z990 zarch
+eb0000000090 stmy RSY_RRRD "store multiple with long offset" z990 zarch
+e3000000005b sy RXY_RRRD "subtract with long offset" z990 zarch
+e3000000007b shy RXY_RRRD "subtract halfword with long offset" z990 zarch
+e3000000005f sly RXY_RRRD "subtract logical with long offset" z990 zarch
+eb0000000051 tmy SIY_URD "test under mask with long offset" z990 zarch
+# 'old' instructions extended to long displacement
+# these instructions are entered into the opcode table twice.
+e30000000003 lrag RXY_RRRD "load real address with long offset 64" z990 zarch
+e30000000004 lg RXY_RRRD " load 64" z990 zarch
+e30000000008 ag RXY_RRRD "add with long offset 64" z990 zarch
+e30000000009 sg RXY_RRRD "subtract with long offset 64" z990 zarch
+e3000000000a alg RXY_RRRD "add logical with long offset 64" z990 zarch
+e3000000000b slg RXY_RRRD "subtract logical with long offset 64" z990 zarch
+e3000000000c msg RXY_RRRD "multiply single with long offset 64" z990 zarch
+e3000000000d dsg RXY_RRRD "divide single 64" z990 zarch
+e3000000000e cvbg RXY_RRRD "convert to binary with long offset 64" z990 zarch
+e3000000000f lrvg RXY_RRRD "load reversed 64" z990 zarch
+e30000000014 lgf RXY_RRRD "load 64<32" z990 zarch
+e30000000015 lgh RXY_RRRD "load halfword 64" z990 zarch
+e30000000016 llgf RXY_RRRD "load logical 64<32" z990 zarch
+e30000000017 llgt RXY_RRRD "load logical thirty one bits" z990 zarch
+e30000000018 agf RXY_RRRD "add with long offset 64<32" z990 zarch
+e30000000019 sgf RXY_RRRD "subtract with long offset 64<32" z990 zarch
+e3000000001a algf RXY_RRRD "add logical with long offset 64<32" z990 zarch
+e3000000001b slgf RXY_RRRD "subtract logical with long offset 64<32" z990 zarch
+e3000000001c msgf RXY_RRRD "multiply single with long offset 64<32" z990 zarch
+e3000000001d dsgf RXY_RRRD "divide single 64<32" z990 zarch
+e3000000001e lrv RXY_RRRD "load reversed 32" z990 zarch
+e3000000001f lrvh RXY_RRRD "load reversed 16" z990 zarch
+e30000000020 cg RXY_RRRD "compare with long offset 64" z990 zarch
+e30000000021 clg RXY_RRRD "compare logical with long offset 64" z990 zarch
+e30000000024 stg RXY_RRRD "store with long offset 64" z990 zarch
+e3000000002e cvdg RXY_RRRD "convert to decimal with long offset 64" z990 zarch
+e3000000002f strvg RXY_RRRD "store reversed 64" z990 zarch
+e30000000030 cgf RXY_RRRD "compare with long offset 64<32" z990 zarch
+e30000000031 clgf RXY_RRRD "compare logical with long offset 64<32" z990 zarch
+e3000000003e strv RXY_RRRD "store reversed 32" z990 zarch
+e3000000003f strvh RXY_RRRD "store reversed 64" z990 zarch
+e30000000046 bctg RXY_RRRD "branch on count 64" z990 zarch
+e30000000080 ng RXY_RRRD "and with long offset 64" z990 zarch
+e30000000081 og RXY_RRRD "or with long offset 64" z990 zarch
+e30000000082 xg RXY_RRRD "exclusive or with long offset 64" z990 zarch
+e30000000086 mlg RXY_RRRD "multiply logical 64" z990 zarch
+e30000000087 dlg RXY_RRRD "divide logical 64" z990 zarch
+e30000000088 alcg RXY_RRRD "add logical with carry 64" z990 zarch
+e30000000089 slbg RXY_RRRD "subtract logical with borrow 64" z990 zarch
+e3000000008e stpq RXY_RRRD "store pair to quadword" z990 zarch
+e3000000008f lpq RXY_RRRD "load pair from quadword" z990 zarch
+e30000000090 llgc RXY_RRRD "load logical character" z990 zarch
+e30000000091 llgh RXY_RRRD "load logical halfword" z990 zarch
+e30000000096 ml RXY_RRRD "multiply logical 32" z990 zarch
+e30000000097 dl RXY_RRRD "divide logical 32" z990 zarch
+e30000000098 alc RXY_RRRD "add logical with carry 32" z990 zarch
+e30000000099 slb RXY_RRRD "subtract logical with borrow 32" z990 zarch
+eb0000000004 lmg RSY_RRRD "load multiple with long offset 64" z990 zarch
+eb000000000a srag RSY_RRRD "shift right single 64" z990 zarch
+eb000000000b slag RSY_RRRD "shift left single 64" z990 zarch
+eb000000000c srlg RSY_RRRD "shift right single logical 64" z990 zarch
+eb000000000d sllg RSY_RRRD "shift left single logical 64" z990 zarch
+eb000000000f tracg RSY_RRRD "trace 64" z990 zarch
+eb000000001c rllg RSY_RRRD "rotate left single logical 64" z990 zarch
+eb000000001d rll RSY_RRRD "rotate left single logical 32" z990 zarch
+eb0000000020 clmh RSY_RURD "compare logical characters under mask high with long offset" z990 zarch
+eb0000000024 stmg RSY_RRRD "store multiple with long offset 64" z990 zarch
+eb0000000025 stctg RSY_RRRD "store control 64" z990 zarch
+eb0000000026 stmh RSY_RRRD "store multiple high" z990 zarch
+eb000000002c stcmh RSY_RURD "store characters under mask high with long offset" z990 zarch
+eb000000002f lctlg RSY_RRRD "load control 64" z990 zarch
+eb0000000030 csg RSY_RRRD "compare and swap with long offset 64" z990 zarch
+eb000000003e cdsg RSY_RRRD "compare double and swap with long offset 64" z990 zarch
+eb0000000044 bxhg RSY_RRRD "branch on index high 64" z990 zarch
+eb0000000045 bxleg RSY_RRRD "branch on index low or equal 64" z990 zarch
+eb0000000080 icmh RSY_RURD "insert characters under mask high with long offset" z990 zarch
+eb000000008e mvclu RSY_RRRD "move long unicode" z990 zarch
+eb000000008f clclu RSY_RRRD "compare logical long unicode with long offset" z990 zarch
+eb0000000096 lmh RSY_RRRD "load multiple high" z990 zarch
+# new z990 instructions
+b98a cspg RRE_RR "compare and swap and purge" z990 zarch
+b98e idte RRF_R0RR "invalidate dat table entry" z990 zarch
+b33e madr RRF_F0FF "multiply and add long hfp" z990 esa,zarch
+ed000000003e mad RXF_FRRDF "multiply and add long hfp" z990 esa,zarch
+b32e maer RRF_F0FF "multiply and add short hfp" z990 esa,zarch
+ed000000002e mae RXF_FRRDF "multiply and add shoft hfp" z990 esa,zarch
+b33f msdr RRF_F0FF "multiply and subtract long hfp" z990 esa,zarch
+ed000000003f msd RXF_FRRDF "multiply and subtract long hfp" z990 esa,zarch
+b32f mser RRF_F0FF "mutliply and subtract short hfp" z990 esa,zarch
+ed000000002f mse RXF_FRRDF "multiply and subttract short hfp" z990 esa,zarch
+b92e km RRE_RR "cipher message" z990 esa,zarch
+b92f kmc RRE_RR "cipher message with chaining" z990 esa,zarch
+b93e kimd RRE_RR "compute intermediate message digest" z990 esa,zarch
+b93f klmd RRE_RR "compute last message digest" z990 esa,zarch
+b91e kmac RRE_RR "compute message authentication code" z990 esa,zarch
diff --git a/contrib/binutils/opcodes/sh-dis.c b/contrib/binutils/opcodes/sh-dis.c
index 24d4b41..2512f96 100644
--- a/contrib/binutils/opcodes/sh-dis.c
+++ b/contrib/binutils/opcodes/sh-dis.c
@@ -1,20 +1,20 @@
/* Disassemble SH instructions.
- Copyright 1993, 1994, 1995, 1997, 1998, 2000, 2001
+ Copyright 1993, 1994, 1995, 1997, 1998, 2000, 2001, 2002, 2003
Free Software Foundation, Inc.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include <stdio.h>
#include "sysdep.h"
@@ -24,15 +24,19 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include "sh-opc.h"
#include "dis-asm.h"
+#ifdef ARCH_all
+#define INCLUDE_SHMEDIA
+#endif
+
static void print_movxy
- PARAMS ((sh_opcode_info *, int, int, fprintf_ftype, void *));
+ PARAMS ((const sh_opcode_info *, int, int, fprintf_ftype, void *));
static void print_insn_ddt PARAMS ((int, struct disassemble_info *));
static void print_dsp_reg PARAMS ((int, fprintf_ftype, void *));
static void print_insn_ppi PARAMS ((int, struct disassemble_info *));
static void
print_movxy (op, rn, rm, fprintf_fn, stream)
- sh_opcode_info *op;
+ const sh_opcode_info *op;
int rn, rm;
fprintf_ftype fprintf_fn;
void *stream;
@@ -45,18 +49,28 @@ print_movxy (op, rn, rm, fprintf_fn, stream)
switch (op->arg[n])
{
case A_IND_N:
+ case AX_IND_N:
+ case AXY_IND_N:
+ case AY_IND_N:
+ case AYX_IND_N:
fprintf_fn (stream, "@r%d", rn);
break;
case A_INC_N:
+ case AX_INC_N:
+ case AXY_INC_N:
+ case AY_INC_N:
+ case AYX_INC_N:
fprintf_fn (stream, "@r%d+", rn);
break;
- case A_PMOD_N:
+ case AX_PMOD_N:
+ case AXY_PMOD_N:
fprintf_fn (stream, "@r%d+r8", rn);
break;
- case A_PMODY_N:
+ case AY_PMOD_N:
+ case AYX_PMOD_N:
fprintf_fn (stream, "@r%d+r9", rn);
break;
- case DSP_REG_M:
+ case DSP_REG_A_M:
fprintf_fn (stream, "a%c", '0' + rm);
break;
case DSP_REG_X:
@@ -65,6 +79,26 @@ print_movxy (op, rn, rm, fprintf_fn, stream)
case DSP_REG_Y:
fprintf_fn (stream, "y%c", '0' + rm);
break;
+ case DSP_REG_AX:
+ fprintf_fn (stream, "%c%c",
+ (rm & 1) ? 'x' : 'a',
+ (rm & 2) ? '1' : '0');
+ break;
+ case DSP_REG_XY:
+ fprintf_fn (stream, "%c%c",
+ (rm & 1) ? 'y' : 'x',
+ (rm & 2) ? '1' : '0');
+ break;
+ case DSP_REG_AY:
+ fprintf_fn (stream, "%c%c",
+ (rm & 2) ? 'y' : 'a',
+ (rm & 1) ? '1' : '0');
+ break;
+ case DSP_REG_YX:
+ fprintf_fn (stream, "%c%c",
+ (rm & 2) ? 'x' : 'y',
+ (rm & 1) ? '1' : '0');
+ break;
default:
abort ();
}
@@ -98,11 +132,45 @@ print_insn_ddt (insn, info)
/* Check if either the x or y part is invalid. */
if (((insn & 0xc) == 0 && (insn & 0x2a0))
|| ((insn & 3) == 0 && (insn & 0x150)))
- fprintf_fn (stream, ".word 0x%x", insn);
+ if (info->mach != bfd_mach_sh_dsp
+ && info->mach != bfd_mach_sh3_dsp)
+ {
+ static const sh_opcode_info *first_movx, *first_movy;
+ const sh_opcode_info *op;
+ int is_movy;
+
+ if (! first_movx)
+ {
+ for (first_movx = sh_table; first_movx->nibbles[1] != MOVX_NOPY;)
+ first_movx++;
+ for (first_movy = first_movx; first_movy->nibbles[1] != MOVY_NOPX;)
+ first_movy++;
+ }
+
+ is_movy = ((insn & 3) != 0);
+
+ if (is_movy)
+ op = first_movy;
+ else
+ op = first_movx;
+
+ while (op->nibbles[2] != (unsigned) ((insn >> 4) & 3)
+ || op->nibbles[3] != (unsigned) (insn & 0xf))
+ op++;
+
+ print_movxy (op,
+ (4 * ((insn & (is_movy ? 0x200 : 0x100)) == 0)
+ + 2 * is_movy
+ + 1 * ((insn & (is_movy ? 0x100 : 0x200)) != 0)),
+ (insn >> 6) & 3,
+ fprintf_fn, stream);
+ }
+ else
+ fprintf_fn (stream, ".word 0x%x", insn);
else
{
- static sh_opcode_info *first_movx, *first_movy;
- sh_opcode_info *opx, *opy;
+ static const sh_opcode_info *first_movx, *first_movy;
+ const sh_opcode_info *opx, *opy;
unsigned int insn_x, insn_y;
if (! first_movx)
@@ -187,8 +255,9 @@ print_insn_ppi (field_b, info)
fprintf_ftype fprintf_fn = info->fprintf_func;
void *stream = info->stream;
unsigned int nib1, nib2, nib3;
+ unsigned int altnib1, nib4;
char *dc = NULL;
- sh_opcode_info *op;
+ const sh_opcode_info *op;
if ((field_b & 0xe800) == 0)
{
@@ -213,6 +282,16 @@ print_insn_ppi (field_b, info)
sy_tab[(field_b >> 4) & 3],
du_tab[(field_b >> 0) & 3]);
}
+ else if ((field_b & 0xf0) == 0x10
+ && info->mach != bfd_mach_sh_dsp
+ && info->mach != bfd_mach_sh3_dsp)
+ {
+ fprintf_fn (stream, "pclr %s \t", du_tab[(field_b >> 0) & 3]);
+ }
+ else if ((field_b & 0xf3) != 0)
+ {
+ fprintf_fn (stream, ".word 0x%x\t", field_b);
+ }
fprintf_fn (stream, "pmuls%c%s,%s,%s",
field_b & 0x2000 ? ' ' : '\t',
se_tab[(field_b >> 10) & 3],
@@ -224,6 +303,7 @@ print_insn_ppi (field_b, info)
nib1 = PPIC;
nib2 = field_b >> 12 & 0xf;
nib3 = field_b >> 8 & 0xf;
+ nib4 = field_b >> 4 & 0xf;
switch (nib3 & 0x3)
{
case 0:
@@ -242,14 +322,41 @@ print_insn_ppi (field_b, info)
nib3 -= 2;
break;
}
+ if (nib1 == PPI3)
+ altnib1 = PPI3NC;
+ else
+ altnib1 = nib1;
for (op = sh_table; op->name; op++)
{
- if (op->nibbles[1] == nib1
+ if ((op->nibbles[1] == nib1 || op->nibbles[1] == altnib1)
&& op->nibbles[2] == nib2
&& op->nibbles[3] == nib3)
{
int n;
+ switch (op->nibbles[4])
+ {
+ case HEX_0:
+ break;
+ case HEX_XX00:
+ if ((nib4 & 3) != 0)
+ continue;
+ break;
+ case HEX_1:
+ if ((nib4 & 3) != 1)
+ continue;
+ break;
+ case HEX_00YY:
+ if ((nib4 & 0xc) != 0)
+ continue;
+ break;
+ case HEX_4:
+ if ((nib4 & 0xc) != 4)
+ continue;
+ break;
+ default:
+ abort ();
+ }
fprintf_fn (stream, "%s%s\t", dc, op->name);
for (n = 0; n < 3 && op->arg[n] != A_END; n++)
{
@@ -290,11 +397,11 @@ print_insn_sh (memaddr, info)
{
fprintf_ftype fprintf_fn = info->fprintf_func;
void *stream = info->stream;
- unsigned char insn[2];
+ unsigned char insn[4];
unsigned char nibs[4];
int status;
bfd_vma relmask = ~(bfd_vma) 0;
- sh_opcode_info *op;
+ const sh_opcode_info *op;
int target_arch;
switch (info->mach)
@@ -311,6 +418,9 @@ print_insn_sh (memaddr, info)
case bfd_mach_sh2:
target_arch = arch_sh2;
break;
+ case bfd_mach_sh2e:
+ target_arch = arch_sh2e;
+ break;
case bfd_mach_sh_dsp:
target_arch = arch_sh_dsp;
break;
@@ -324,8 +434,16 @@ print_insn_sh (memaddr, info)
target_arch = arch_sh3e;
break;
case bfd_mach_sh4:
+ case bfd_mach_sh4_nofpu:
target_arch = arch_sh4;
break;
+ case bfd_mach_sh4a:
+ case bfd_mach_sh4a_nofpu:
+ target_arch = arch_sh4a;
+ break;
+ case bfd_mach_sh4al_dsp:
+ target_arch = arch_sh4al_dsp;
+ break;
case bfd_mach_sh5:
#ifdef INCLUDE_SHMEDIA
status = print_insn_sh64 (memaddr, info);
@@ -459,12 +577,21 @@ print_insn_sh (memaddr, info)
case IMM1_8BY4:
imm = ((nibs[2] << 4) | nibs[3]) << 2;
goto ok;
+ case REG_N_D:
+ if ((nibs[n] & 1) != 0)
+ goto fail;
+ /* fall through */
case REG_N:
rn = nibs[n];
break;
case REG_M:
rm = nibs[n];
break;
+ case REG_N_B01:
+ if ((nibs[n] & 0x3) != 1 /* binary 01 */)
+ goto fail;
+ rn = (nibs[n] & 0xc) >> 2;
+ break;
case REG_NM:
rn = (nibs[n] & 0xc) >> 2;
rm = (nibs[n] & 0x3);
@@ -507,18 +634,21 @@ print_insn_sh (memaddr, info)
fprintf_fn (stream, "r%d", rn);
break;
case A_INC_N:
+ case AS_INC_N:
fprintf_fn (stream, "@r%d+", rn);
break;
case A_DEC_N:
+ case AS_DEC_N:
fprintf_fn (stream, "@-r%d", rn);
break;
case A_IND_N:
+ case AS_IND_N:
fprintf_fn (stream, "@r%d", rn);
break;
case A_DISP_REG_N:
fprintf_fn (stream, "@(%d,r%d)", imm, rn);
break;
- case A_PMOD_N:
+ case AS_PMOD_N:
fprintf_fn (stream, "@r%d+r8", rn);
break;
case A_REG_M:
diff --git a/contrib/binutils/opcodes/sh-opc.h b/contrib/binutils/opcodes/sh-opc.h
index abdc464..0ef1fab 100644
--- a/contrib/binutils/opcodes/sh-opc.h
+++ b/contrib/binutils/opcodes/sh-opc.h
@@ -1,177 +1,222 @@
/* Definitions for SH opcodes.
- Copyright 1993, 1994, 1995, 1997, 1999, 2000
+ Copyright 1993, 1994, 1995, 1997, 1999, 2000, 2003
Free Software Foundation, Inc.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
-
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
-
-typedef enum {
- HEX_0,
- HEX_1,
- HEX_2,
- HEX_3,
- HEX_4,
- HEX_5,
- HEX_6,
- HEX_7,
- HEX_8,
- HEX_9,
- HEX_A,
- HEX_B,
- HEX_C,
- HEX_D,
- HEX_E,
- HEX_F,
- REG_N,
- REG_M,
- SDT_REG_N,
- REG_NM,
- REG_B,
- BRANCH_12,
- BRANCH_8,
- IMM0_4,
- IMM0_4BY2,
- IMM0_4BY4,
- IMM1_4,
- IMM1_4BY2,
- IMM1_4BY4,
- PCRELIMM_8BY2,
- PCRELIMM_8BY4,
- IMM0_8,
- IMM0_8BY2,
- IMM0_8BY4,
- IMM1_8,
- IMM1_8BY2,
- IMM1_8BY4,
- PPI,
- NOPX,
- NOPY,
- MOVX,
- MOVY,
- PSH,
- PMUL,
- PPI3,
- PDC,
- PPIC,
- REPEAT
-} sh_nibble_type;
-
-typedef enum {
- A_END,
- A_BDISP12,
- A_BDISP8,
- A_DEC_M,
- A_DEC_N,
- A_DISP_GBR,
- A_PC,
- A_DISP_PC,
- A_DISP_PC_ABS,
- A_DISP_REG_M,
- A_DISP_REG_N,
- A_GBR,
- A_IMM,
- A_INC_M,
- A_INC_N,
- A_IND_M,
- A_IND_N,
- A_PMOD_N,
- A_PMODY_N,
- A_IND_R0_REG_M,
- A_IND_R0_REG_N,
- A_MACH,
- A_MACL,
- A_PR,
- A_R0,
- A_R0_GBR,
- A_REG_M,
- A_REG_N,
- A_REG_B,
- A_SR,
- A_VBR,
- A_MOD,
- A_RE,
- A_RS,
- A_DSR,
- DSP_REG_M,
- DSP_REG_N,
- DSP_REG_X,
- DSP_REG_Y,
- DSP_REG_E,
- DSP_REG_F,
- DSP_REG_G,
- A_A0,
- A_X0,
- A_X1,
- A_Y0,
- A_Y1,
- A_SSR,
- A_SPC,
- A_SGR,
- A_DBR,
- F_REG_N,
- F_REG_M,
- D_REG_N,
- D_REG_M,
- X_REG_N, /* Only used for argument parsing */
- X_REG_M, /* Only used for argument parsing */
- DX_REG_N,
- DX_REG_M,
- V_REG_N,
- V_REG_M,
- XMTRX_M4,
- F_FR0,
- FPUL_N,
- FPUL_M,
- FPSCR_N,
- FPSCR_M
-} sh_arg_type;
-
-typedef enum {
- A_A1_NUM = 5,
- A_A0_NUM = 7,
- A_X0_NUM, A_X1_NUM, A_Y0_NUM, A_Y1_NUM,
- A_M0_NUM, A_A1G_NUM, A_M1_NUM, A_A0G_NUM
-} sh_dsp_reg_nums;
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+
+typedef enum
+ {
+ HEX_0,
+ HEX_1,
+ HEX_2,
+ HEX_3,
+ HEX_4,
+ HEX_5,
+ HEX_6,
+ HEX_7,
+ HEX_8,
+ HEX_9,
+ HEX_A,
+ HEX_B,
+ HEX_C,
+ HEX_D,
+ HEX_E,
+ HEX_F,
+ HEX_XX00,
+ HEX_00YY,
+ REG_N,
+ REG_N_D, /* nnn0 */
+ REG_N_B01, /* nn01 */
+ REG_M,
+ SDT_REG_N,
+ REG_NM,
+ REG_B,
+ BRANCH_12,
+ BRANCH_8,
+ IMM0_4,
+ IMM0_4BY2,
+ IMM0_4BY4,
+ IMM1_4,
+ IMM1_4BY2,
+ IMM1_4BY4,
+ PCRELIMM_8BY2,
+ PCRELIMM_8BY4,
+ IMM0_8,
+ IMM0_8BY2,
+ IMM0_8BY4,
+ IMM1_8,
+ IMM1_8BY2,
+ IMM1_8BY4,
+ PPI,
+ NOPX,
+ NOPY,
+ MOVX,
+ MOVY,
+ MOVX_NOPY,
+ MOVY_NOPX,
+ PSH,
+ PMUL,
+ PPI3,
+ PPI3NC,
+ PDC,
+ PPIC,
+ REPEAT
+ }
+sh_nibble_type;
+
+typedef enum
+ {
+ A_END,
+ A_BDISP12,
+ A_BDISP8,
+ A_DEC_M,
+ A_DEC_N,
+ A_DISP_GBR,
+ A_PC,
+ A_DISP_PC,
+ A_DISP_PC_ABS,
+ A_DISP_REG_M,
+ A_DISP_REG_N,
+ A_GBR,
+ A_IMM,
+ A_INC_M,
+ A_INC_N,
+ A_IND_M,
+ A_IND_N,
+ A_IND_R0_REG_M,
+ A_IND_R0_REG_N,
+ A_MACH,
+ A_MACL,
+ A_PR,
+ A_R0,
+ A_R0_GBR,
+ A_REG_M,
+ A_REG_N,
+ A_REG_B,
+ A_SR,
+ A_VBR,
+ A_MOD,
+ A_RE,
+ A_RS,
+ A_DSR,
+ DSP_REG_M,
+ DSP_REG_N,
+ DSP_REG_X,
+ DSP_REG_Y,
+ DSP_REG_E,
+ DSP_REG_F,
+ DSP_REG_G,
+ DSP_REG_A_M,
+ DSP_REG_AX,
+ DSP_REG_XY,
+ DSP_REG_AY,
+ DSP_REG_YX,
+ AX_INC_N,
+ AY_INC_N,
+ AXY_INC_N,
+ AYX_INC_N,
+ AX_IND_N,
+ AY_IND_N,
+ AXY_IND_N,
+ AYX_IND_N,
+ AX_PMOD_N,
+ AXY_PMOD_N,
+ AY_PMOD_N,
+ AYX_PMOD_N,
+ AS_DEC_N,
+ AS_INC_N,
+ AS_IND_N,
+ AS_PMOD_N,
+ A_A0,
+ A_X0,
+ A_X1,
+ A_Y0,
+ A_Y1,
+ A_SSR,
+ A_SPC,
+ A_SGR,
+ A_DBR,
+ F_REG_N,
+ F_REG_M,
+ D_REG_N,
+ D_REG_M,
+ X_REG_N, /* Only used for argument parsing. */
+ X_REG_M, /* Only used for argument parsing. */
+ DX_REG_N,
+ DX_REG_M,
+ V_REG_N,
+ V_REG_M,
+ XMTRX_M4,
+ F_FR0,
+ FPUL_N,
+ FPUL_M,
+ FPSCR_N,
+ FPSCR_M
+ }
+sh_arg_type;
+
+typedef enum
+ {
+ A_A1_NUM = 5,
+ A_A0_NUM = 7,
+ A_X0_NUM, A_X1_NUM, A_Y0_NUM, A_Y1_NUM,
+ A_M0_NUM, A_A1G_NUM, A_M1_NUM, A_A0G_NUM
+ }
+sh_dsp_reg_nums;
#define arch_sh1 0x0001
#define arch_sh2 0x0002
#define arch_sh3 0x0004
#define arch_sh3e 0x0008
#define arch_sh4 0x0010
+#define arch_sh2e 0x0020
+#define arch_sh4a 0x0040
#define arch_sh_dsp 0x0100
#define arch_sh3_dsp 0x0200
-
-#define arch_sh1_up (arch_sh1 | arch_sh2_up)
-#define arch_sh2_up (arch_sh2 | arch_sh3_up | arch_sh_dsp)
-#define arch_sh3_up (arch_sh3 | arch_sh3e_up | arch_sh3_dsp)
+#define arch_sh4al_dsp 0x0400
+#define arch_sh4_nofpu 0x1000
+#define arch_sh4a_nofpu 0x2000
+
+#define arch_sh1_up (arch_sh1 | arch_sh2_up)
+#define arch_sh2_up (arch_sh2 | arch_sh2e_up | arch_sh3_up | arch_sh_dsp)
+#define arch_sh2e_up (arch_sh2e | arch_sh3e_up)
+#define arch_sh3_up (arch_sh3 | arch_sh3e_up | arch_sh3_dsp_up \
+ | arch_sh4_nofp_up)
#define arch_sh3e_up (arch_sh3e | arch_sh4_up)
-#define arch_sh4_up arch_sh4
+#define arch_sh4_up (arch_sh4 | arch_sh4a_up)
+#define arch_sh4a_up (arch_sh4a)
#define arch_sh_dsp_up (arch_sh_dsp | arch_sh3_dsp_up)
-#define arch_sh3_dsp_up arch_sh3_dsp
+#define arch_sh3_dsp_up (arch_sh3_dsp | arch_sh4al_dsp_up)
+#define arch_sh4al_dsp_up (arch_sh4al_dsp)
+
+#define arch_sh4_nofp_up (arch_sh4_nofpu | arch_sh4_up | arch_sh4a_nofp_up)
+#define arch_sh4a_nofp_up (arch_sh4a_nofpu | arch_sh4a_up | arch_sh4al_dsp_up)
-typedef struct {
+typedef struct
+{
char *name;
sh_arg_type arg[4];
- sh_nibble_type nibbles[4];
+ sh_nibble_type nibbles[5];
int arch;
} sh_opcode_info;
#ifdef DEFINE_TABLE
-sh_opcode_info sh_table[] = {
-
+const sh_opcode_info sh_table[] =
+ {
/* 0111nnnni8*1.... add #<imm>,<REG_N> */{"add",{A_IMM,A_REG_N},{HEX_7,REG_N,IMM0_8}, arch_sh1_up},
/* 0011nnnnmmmm1100 add <REG_M>,<REG_N> */{"add",{ A_REG_M,A_REG_N},{HEX_3,REG_N,REG_M,HEX_C}, arch_sh1_up},
@@ -202,6 +247,8 @@ sh_opcode_info sh_table[] = {
/* 10001111i8p1.... bf/s <bdisp8> */{"bf/s",{A_BDISP8},{HEX_8,HEX_F,BRANCH_8}, arch_sh2_up},
+/* 0000000010001000 clrdmxy */{"clrdmxy",{0},{HEX_0,HEX_0,HEX_8,HEX_8}, arch_sh4al_dsp_up},
+
/* 0000000000101000 clrmac */{"clrmac",{0},{HEX_0,HEX_0,HEX_2,HEX_8}, arch_sh1_up},
/* 0000000001001000 clrs */{"clrs",{0},{HEX_0,HEX_0,HEX_4,HEX_8}, arch_sh1_up},
@@ -240,6 +287,8 @@ sh_opcode_info sh_table[] = {
/* 0110nnnnmmmm1101 extu.w <REG_M>,<REG_N>*/{"extu.w",{ A_REG_M,A_REG_N},{HEX_6,REG_N,REG_M,HEX_D}, arch_sh1_up},
+/* 0000nnnn11100011 icbi @<REG_N> */{"icbi",{A_IND_N},{HEX_0,REG_N,HEX_E,HEX_3}, arch_sh4a_nofp_up},
+
/* 0100nnnn00101011 jmp @<REG_N> */{"jmp",{A_IND_N},{HEX_4,REG_N,HEX_2,HEX_B}, arch_sh1_up},
/* 0100nnnn00001011 jsr @<REG_N> */{"jsr",{A_IND_N},{HEX_4,REG_N,HEX_0,HEX_B}, arch_sh1_up},
@@ -260,7 +309,7 @@ sh_opcode_info sh_table[] = {
/* 0100nnnn01001110 ldc <REG_N>,SPC */{"ldc",{A_REG_N,A_SPC},{HEX_4,REG_N,HEX_4,HEX_E}, arch_sh3_up},
-/* 0100nnnn11111010 ldc <REG_N>,DBR */{"ldc",{A_REG_N,A_DBR},{HEX_4,REG_N,HEX_F,HEX_A}, arch_sh4_up},
+/* 0100nnnn11111010 ldc <REG_N>,DBR */{"ldc",{A_REG_N,A_DBR},{HEX_4,REG_N,HEX_F,HEX_A}, arch_sh4_nofp_up},
/* 0100nnnn1xxx1110 ldc <REG_N>,Rn_BANK */{"ldc",{A_REG_N,A_REG_B},{HEX_4,REG_N,REG_B,HEX_E}, arch_sh3_up},
@@ -280,10 +329,13 @@ sh_opcode_info sh_table[] = {
/* 0100nnnn01000111 ldc.l @<REG_N>+,SPC */{"ldc.l",{A_INC_N,A_SPC},{HEX_4,REG_N,HEX_4,HEX_7}, arch_sh3_up},
-/* 0100nnnn11110110 ldc.l @<REG_N>+,DBR */{"ldc.l",{A_INC_N,A_DBR},{HEX_4,REG_N,HEX_F,HEX_6}, arch_sh4_up},
+/* 0100nnnn11110110 ldc.l @<REG_N>+,DBR */{"ldc.l",{A_INC_N,A_DBR},{HEX_4,REG_N,HEX_F,HEX_6}, arch_sh4_nofp_up},
/* 0100nnnn1xxx0111 ldc.l <REG_N>,Rn_BANK */{"ldc.l",{A_INC_N,A_REG_B},{HEX_4,REG_N,REG_B,HEX_7}, arch_sh3_up},
+/* 0100mmmm00110100 ldrc <REG_M> */{"ldrc",{A_REG_M},{HEX_4,REG_M,HEX_3,HEX_4}, arch_sh4al_dsp_up},
+/* 10001010i8*1.... ldrc #<imm> */{"ldrc",{A_IMM},{HEX_8,HEX_A,IMM0_8}, arch_sh4al_dsp_up},
+
/* 10001110i8p2.... ldre @(<disp>,PC) */{"ldre",{A_DISP_PC},{HEX_8,HEX_E,PCRELIMM_8BY2}, arch_sh_dsp_up},
/* 10001100i8p2.... ldrs @(<disp>,PC) */{"ldrs",{A_DISP_PC},{HEX_8,HEX_C,PCRELIMM_8BY2}, arch_sh_dsp_up},
@@ -306,9 +358,9 @@ sh_opcode_info sh_table[] = {
/* 0100nnnn10111010 lds <REG_N>,Y1 */{"lds",{A_REG_N,A_Y1},{HEX_4,REG_N,HEX_B,HEX_A}, arch_sh_dsp_up},
-/* 0100nnnn01011010 lds <REG_N>,FPUL */{"lds",{A_REG_M,FPUL_N},{HEX_4,REG_M,HEX_5,HEX_A}, arch_sh3e_up},
-
-/* 0100nnnn01101010 lds <REG_M>,FPSCR */{"lds",{A_REG_M,FPSCR_N},{HEX_4,REG_M,HEX_6,HEX_A}, arch_sh3e_up},
+/* 0100nnnn01011010 lds <REG_N>,FPUL */{"lds",{A_REG_M,FPUL_N},{HEX_4,REG_M,HEX_5,HEX_A}, arch_sh2e_up},
+
+/* 0100nnnn01101010 lds <REG_M>,FPSCR */{"lds",{A_REG_M,FPSCR_N},{HEX_4,REG_M,HEX_6,HEX_A}, arch_sh2e_up},
/* 0100nnnn00000110 lds.l @<REG_N>+,MACH*/{"lds.l",{A_INC_N,A_MACH},{HEX_4,REG_N,HEX_0,HEX_6}, arch_sh1_up},
@@ -328,9 +380,9 @@ sh_opcode_info sh_table[] = {
/* 0100nnnn10110110 lds.l @<REG_N>+,Y1 */{"lds.l",{A_INC_N,A_Y1},{HEX_4,REG_N,HEX_B,HEX_6}, arch_sh_dsp_up},
-/* 0100nnnn01010110 lds.l @<REG_M>+,FPUL*/{"lds.l",{A_INC_M,FPUL_N},{HEX_4,REG_M,HEX_5,HEX_6}, arch_sh3e_up},
-
-/* 0100nnnn01100110 lds.l @<REG_M>+,FPSCR*/{"lds.l",{A_INC_M,FPSCR_N},{HEX_4,REG_M,HEX_6,HEX_6}, arch_sh3e_up},
+/* 0100nnnn01010110 lds.l @<REG_M>+,FPUL*/{"lds.l",{A_INC_M,FPUL_N},{HEX_4,REG_M,HEX_5,HEX_6}, arch_sh2e_up},
+
+/* 0100nnnn01100110 lds.l @<REG_M>+,FPSCR*/{"lds.l",{A_INC_M,FPSCR_N},{HEX_4,REG_M,HEX_6,HEX_6}, arch_sh2e_up},
/* 0000000000111000 ldtlb */{"ldtlb",{0},{HEX_0,HEX_0,HEX_3,HEX_8}, arch_sh3_up},
@@ -405,11 +457,16 @@ sh_opcode_info sh_table[] = {
/* 11000001i8*2.... mov.w R0,@(<disp>,GBR)*/{"mov.w",{A_R0,A_DISP_GBR},{HEX_C,HEX_1,IMM1_8BY2}, arch_sh1_up},
/* 11000111i8p4.... mova @(<disp>,PC),R0*/{"mova",{A_DISP_PC,A_R0},{HEX_C,HEX_7,PCRELIMM_8BY4}, arch_sh1_up},
-/* 0000nnnn11000011 movca.l R0,@<REG_N> */{"movca.l",{A_R0,A_IND_N},{HEX_0,REG_N,HEX_C,HEX_3}, arch_sh4_up},
+/* 0000nnnn11000011 movca.l R0,@<REG_N> */{"movca.l",{A_R0,A_IND_N},{HEX_0,REG_N,HEX_C,HEX_3}, arch_sh4_nofp_up},
+/* 0000nnnn01110011 movco.l r0,@<REG_N> */{"movco.l",{A_R0,A_IND_N},{HEX_0,REG_N,HEX_7,HEX_3}, arch_sh4a_nofp_up},
+/* 0000mmmm01100011 movli.l @<REG_M>,r0 */{"movli.l",{A_IND_M,A_R0},{HEX_0,REG_M,HEX_6,HEX_3}, arch_sh4a_nofp_up},
/* 0000nnnn00101001 movt <REG_N> */{"movt",{A_REG_N},{HEX_0,REG_N,HEX_2,HEX_9}, arch_sh1_up},
+/* 0100mmmm10101001 movua.l @<REG_M>,r0 */{"movua.l",{A_IND_M,A_R0},{HEX_4,REG_M,HEX_A,HEX_9}, arch_sh4a_nofp_up},
+/* 0100mmmm11101001 movua.l @<REG_M>+,r0 */{"movua.l",{A_INC_M,A_R0},{HEX_4,REG_M,HEX_E,HEX_9}, arch_sh4a_nofp_up},
+
/* 0010nnnnmmmm1111 muls.w <REG_M>,<REG_N>*/{"muls.w",{ A_REG_M,A_REG_N},{HEX_2,REG_N,REG_M,HEX_F}, arch_sh1_up},
/* 0010nnnnmmmm1111 muls <REG_M>,<REG_N>*/{"muls",{ A_REG_M,A_REG_N},{HEX_2,REG_N,REG_M,HEX_F}, arch_sh1_up},
@@ -425,11 +482,11 @@ sh_opcode_info sh_table[] = {
/* 0000000000001001 nop */{"nop",{0},{HEX_0,HEX_0,HEX_0,HEX_9}, arch_sh1_up},
/* 0110nnnnmmmm0111 not <REG_M>,<REG_N> */{"not",{ A_REG_M,A_REG_N},{HEX_6,REG_N,REG_M,HEX_7}, arch_sh1_up},
-/* 0000nnnn10010011 ocbi @<REG_N> */{"ocbi",{A_IND_N},{HEX_0,REG_N,HEX_9,HEX_3}, arch_sh4_up},
+/* 0000nnnn10010011 ocbi @<REG_N> */{"ocbi",{A_IND_N},{HEX_0,REG_N,HEX_9,HEX_3}, arch_sh4_nofp_up},
-/* 0000nnnn10100011 ocbp @<REG_N> */{"ocbp",{A_IND_N},{HEX_0,REG_N,HEX_A,HEX_3}, arch_sh4_up},
+/* 0000nnnn10100011 ocbp @<REG_N> */{"ocbp",{A_IND_N},{HEX_0,REG_N,HEX_A,HEX_3}, arch_sh4_nofp_up},
-/* 0000nnnn10110011 ocbwb @<REG_N> */{"ocbwb",{A_IND_N},{HEX_0,REG_N,HEX_B,HEX_3}, arch_sh4_up},
+/* 0000nnnn10110011 ocbwb @<REG_N> */{"ocbwb",{A_IND_N},{HEX_0,REG_N,HEX_B,HEX_3}, arch_sh4_nofp_up},
/* 11001011i8*1.... or #<imm>,R0 */{"or",{A_IMM,A_R0},{HEX_C,HEX_B,IMM0_8}, arch_sh1_up},
@@ -438,7 +495,9 @@ sh_opcode_info sh_table[] = {
/* 11001111i8*1.... or.b #<imm>,@(R0,GBR)*/{"or.b",{A_IMM,A_R0_GBR},{HEX_C,HEX_F,IMM0_8}, arch_sh1_up},
-/* 0000nnnn10000011 pref @<REG_N> */{"pref",{A_IND_N},{HEX_0,REG_N,HEX_8,HEX_3}, arch_sh4_up},
+/* 0000nnnn10000011 pref @<REG_N> */{"pref",{A_IND_N},{HEX_0,REG_N,HEX_8,HEX_3}, arch_sh4_nofp_up},
+
+/* 0000nnnn11010011 prefi @<REG_N> */{"prefi",{A_IND_N},{HEX_0,REG_N,HEX_D,HEX_3}, arch_sh4a_nofp_up},
/* 0100nnnn00100100 rotcl <REG_N> */{"rotcl",{A_REG_N},{HEX_4,REG_N,HEX_2,HEX_4}, arch_sh1_up},
@@ -452,6 +511,9 @@ sh_opcode_info sh_table[] = {
/* 0000000000001011 rts */{"rts",{0},{HEX_0,HEX_0,HEX_0,HEX_B}, arch_sh1_up},
+/* 0000000010011000 setdmx */{"setdmx",{0},{HEX_0,HEX_0,HEX_9,HEX_8}, arch_sh4al_dsp_up},
+/* 0000000011001000 setdmy */{"setdmy",{0},{HEX_0,HEX_0,HEX_C,HEX_8}, arch_sh4al_dsp_up},
+
/* 0000000001011000 sets */{"sets",{0},{HEX_0,HEX_0,HEX_5,HEX_8}, arch_sh1_up},
/* 0000000000011000 sett */{"sett",{0},{HEX_0,HEX_0,HEX_1,HEX_8}, arch_sh1_up},
@@ -505,9 +567,9 @@ sh_opcode_info sh_table[] = {
/* 0000nnnn01000010 stc SPC,<REG_N> */{"stc",{A_SPC,A_REG_N},{HEX_0,REG_N,HEX_4,HEX_2}, arch_sh3_up},
-/* 0000nnnn00111010 stc SGR,<REG_N> */{"stc",{A_SGR,A_REG_N},{HEX_0,REG_N,HEX_3,HEX_A}, arch_sh4_up},
+/* 0000nnnn00111010 stc SGR,<REG_N> */{"stc",{A_SGR,A_REG_N},{HEX_0,REG_N,HEX_3,HEX_A}, arch_sh4_nofp_up},
-/* 0000nnnn11111010 stc DBR,<REG_N> */{"stc",{A_DBR,A_REG_N},{HEX_0,REG_N,HEX_F,HEX_A}, arch_sh4_up},
+/* 0000nnnn11111010 stc DBR,<REG_N> */{"stc",{A_DBR,A_REG_N},{HEX_0,REG_N,HEX_F,HEX_A}, arch_sh4_nofp_up},
/* 0000nnnn1xxx0010 stc Rn_BANK,<REG_N> */{"stc",{A_REG_B,A_REG_N},{HEX_0,REG_N,REG_B,HEX_2}, arch_sh3_up},
@@ -527,9 +589,9 @@ sh_opcode_info sh_table[] = {
/* 0100nnnn00010011 stc.l GBR,@-<REG_N> */{"stc.l",{A_GBR,A_DEC_N},{HEX_4,REG_N,HEX_1,HEX_3}, arch_sh1_up},
-/* 0100nnnn00110010 stc.l SGR,@-<REG_N> */{"stc.l",{A_SGR,A_DEC_N},{HEX_4,REG_N,HEX_3,HEX_2}, arch_sh4_up},
+/* 0100nnnn00110010 stc.l SGR,@-<REG_N> */{"stc.l",{A_SGR,A_DEC_N},{HEX_4,REG_N,HEX_3,HEX_2}, arch_sh4_nofp_up},
-/* 0100nnnn11110010 stc.l DBR,@-<REG_N> */{"stc.l",{A_DBR,A_DEC_N},{HEX_4,REG_N,HEX_F,HEX_2}, arch_sh4_up},
+/* 0100nnnn11110010 stc.l DBR,@-<REG_N> */{"stc.l",{A_DBR,A_DEC_N},{HEX_4,REG_N,HEX_F,HEX_2}, arch_sh4_nofp_up},
/* 0100nnnn1xxx0011 stc.l Rn_BANK,@-<REG_N> */{"stc.l",{A_REG_B,A_DEC_N},{HEX_4,REG_N,REG_B,HEX_3}, arch_sh3_up},
@@ -551,9 +613,9 @@ sh_opcode_info sh_table[] = {
/* 0000nnnn10111010 sts Y1,<REG_N> */{"sts",{A_Y1,A_REG_N},{HEX_0,REG_N,HEX_B,HEX_A}, arch_sh_dsp_up},
-/* 0000nnnn01011010 sts FPUL,<REG_N> */{"sts",{FPUL_M,A_REG_N},{HEX_0,REG_N,HEX_5,HEX_A}, arch_sh3e_up},
-
-/* 0000nnnn01101010 sts FPSCR,<REG_N> */{"sts",{FPSCR_M,A_REG_N},{HEX_0,REG_N,HEX_6,HEX_A}, arch_sh3e_up},
+/* 0000nnnn01011010 sts FPUL,<REG_N> */{"sts",{FPUL_M,A_REG_N},{HEX_0,REG_N,HEX_5,HEX_A}, arch_sh2e_up},
+
+/* 0000nnnn01101010 sts FPSCR,<REG_N> */{"sts",{FPSCR_M,A_REG_N},{HEX_0,REG_N,HEX_6,HEX_A}, arch_sh2e_up},
/* 0100nnnn00000010 sts.l MACH,@-<REG_N>*/{"sts.l",{A_MACH,A_DEC_N},{HEX_4,REG_N,HEX_0,HEX_2}, arch_sh1_up},
@@ -573,9 +635,9 @@ sh_opcode_info sh_table[] = {
/* 0100nnnn10110110 sts.l Y1,@-<REG_N> */{"sts.l",{A_Y1,A_DEC_N},{HEX_4,REG_N,HEX_B,HEX_2}, arch_sh_dsp_up},
-/* 0100nnnn01010010 sts.l FPUL,@-<REG_N>*/{"sts.l",{FPUL_M,A_DEC_N},{HEX_4,REG_N,HEX_5,HEX_2}, arch_sh3e_up},
-
-/* 0100nnnn01100010 sts.l FPSCR,@-<REG_N>*/{"sts.l",{FPSCR_M,A_DEC_N},{HEX_4,REG_N,HEX_6,HEX_2}, arch_sh3e_up},
+/* 0100nnnn01010010 sts.l FPUL,@-<REG_N>*/{"sts.l",{FPUL_M,A_DEC_N},{HEX_4,REG_N,HEX_5,HEX_2}, arch_sh2e_up},
+
+/* 0100nnnn01100010 sts.l FPSCR,@-<REG_N>*/{"sts.l",{FPSCR_M,A_DEC_N},{HEX_4,REG_N,HEX_6,HEX_2}, arch_sh2e_up},
/* 0011nnnnmmmm1000 sub <REG_M>,<REG_N> */{"sub",{ A_REG_M,A_REG_N},{HEX_3,REG_N,REG_M,HEX_8}, arch_sh1_up},
@@ -587,6 +649,8 @@ sh_opcode_info sh_table[] = {
/* 0110nnnnmmmm1001 swap.w <REG_M>,<REG_N>*/{"swap.w",{ A_REG_M,A_REG_N},{HEX_6,REG_N,REG_M,HEX_9}, arch_sh1_up},
+/* 0000000010101011 synco */{"synco",{0},{HEX_0,HEX_0,HEX_A,HEX_B}, arch_sh4a_nofp_up},
+
/* 0100nnnn00011011 tas.b @<REG_N> */{"tas.b",{A_IND_N},{HEX_4,REG_N,HEX_1,HEX_B}, arch_sh1_up},
/* 11000011i8*1.... trapa #<imm> */{"trapa",{A_IMM},{HEX_C,HEX_3,IMM0_8}, arch_sh1_up},
@@ -625,7 +689,7 @@ sh_opcode_info sh_table[] = {
/* 111101nnmmmm0010 movs.w @<REG_N>+,<DSP_REG_M> */ {"movs.w",{A_INC_N,DSP_REG_M},{HEX_F,SDT_REG_N,REG_M,HEX_8}, arch_sh_dsp_up},
-/* 111101nnmmmm0011 movs.w @<REG_N>+r8,<DSP_REG_M> */ {"movs.w",{A_PMOD_N,DSP_REG_M},{HEX_F,SDT_REG_N,REG_M,HEX_C}, arch_sh_dsp_up},
+/* 111101nnmmmm0011 movs.w @<REG_N>+r8,<DSP_REG_M> */ {"movs.w",{AS_PMOD_N,DSP_REG_M},{HEX_F,SDT_REG_N,REG_M,HEX_C}, arch_sh_dsp_up},
/* 111101nnmmmm0100 movs.w <DSP_REG_M>,@-<REG_N> */ {"movs.w",{DSP_REG_M,A_DEC_N},{HEX_F,SDT_REG_N,REG_M,HEX_1}, arch_sh_dsp_up},
@@ -633,7 +697,7 @@ sh_opcode_info sh_table[] = {
/* 111101nnmmmm0110 movs.w <DSP_REG_M>,@<REG_N>+ */ {"movs.w",{DSP_REG_M,A_INC_N},{HEX_F,SDT_REG_N,REG_M,HEX_9}, arch_sh_dsp_up},
-/* 111101nnmmmm0111 movs.w <DSP_REG_M>,@<REG_N>+r8 */ {"movs.w",{DSP_REG_M,A_PMOD_N},{HEX_F,SDT_REG_N,REG_M,HEX_D}, arch_sh_dsp_up},
+/* 111101nnmmmm0111 movs.w <DSP_REG_M>,@<REG_N>+r8 */ {"movs.w",{DSP_REG_M,AS_PMOD_N},{HEX_F,SDT_REG_N,REG_M,HEX_D}, arch_sh_dsp_up},
/* 111101nnmmmm1000 movs.l @-<REG_N>,<DSP_REG_M> */ {"movs.l",{A_DEC_N,DSP_REG_M},{HEX_F,SDT_REG_N,REG_M,HEX_2}, arch_sh_dsp_up},
@@ -641,7 +705,7 @@ sh_opcode_info sh_table[] = {
/* 111101nnmmmm1010 movs.l @<REG_N>+,<DSP_REG_M> */ {"movs.l",{A_INC_N,DSP_REG_M},{HEX_F,SDT_REG_N,REG_M,HEX_A}, arch_sh_dsp_up},
-/* 111101nnmmmm1011 movs.l @<REG_N>+r8,<DSP_REG_M> */ {"movs.l",{A_PMOD_N,DSP_REG_M},{HEX_F,SDT_REG_N,REG_M,HEX_E}, arch_sh_dsp_up},
+/* 111101nnmmmm1011 movs.l @<REG_N>+r8,<DSP_REG_M> */ {"movs.l",{AS_PMOD_N,DSP_REG_M},{HEX_F,SDT_REG_N,REG_M,HEX_E}, arch_sh_dsp_up},
/* 111101nnmmmm1100 movs.l <DSP_REG_M>,@-<REG_N> */ {"movs.l",{DSP_REG_M,A_DEC_N},{HEX_F,SDT_REG_N,REG_M,HEX_3}, arch_sh_dsp_up},
@@ -649,22 +713,51 @@ sh_opcode_info sh_table[] = {
/* 111101nnmmmm1110 movs.l <DSP_REG_M>,@<REG_N>+ */ {"movs.l",{DSP_REG_M,A_INC_N},{HEX_F,SDT_REG_N,REG_M,HEX_B}, arch_sh_dsp_up},
-/* 111101nnmmmm1111 movs.l <DSP_REG_M>,@<REG_N>+r8 */ {"movs.l",{DSP_REG_M,A_PMOD_N},{HEX_F,SDT_REG_N,REG_M,HEX_F}, arch_sh_dsp_up},
+/* 111101nnmmmm1111 movs.l <DSP_REG_M>,@<REG_N>+r8 */ {"movs.l",{DSP_REG_M,AS_PMOD_N},{HEX_F,SDT_REG_N,REG_M,HEX_F}, arch_sh_dsp_up},
/* 0*0*0*00** nopx */ {"nopx",{0},{PPI,NOPX}, arch_sh_dsp_up},
/* *0*0*0**00 nopy */ {"nopy",{0},{PPI,NOPY}, arch_sh_dsp_up},
-/* n*m*0*01** movx.w @<REG_N>,<DSP_REG_X> */ {"movx.w",{A_IND_N,DSP_REG_X},{PPI,MOVX,HEX_1}, arch_sh_dsp_up},
-/* n*m*0*10** movx.w @<REG_N>+,<DSP_REG_X> */ {"movx.w",{A_INC_N,DSP_REG_X},{PPI,MOVX,HEX_2}, arch_sh_dsp_up},
-/* n*m*0*11** movx.w @<REG_N>+r8,<DSP_REG_X> */ {"movx.w",{A_PMOD_N,DSP_REG_X},{PPI,MOVX,HEX_3}, arch_sh_dsp_up},
-/* n*m*1*01** movx.w <DSP_REG_M>,@<REG_N> */ {"movx.w",{DSP_REG_M,A_IND_N},{PPI,MOVX,HEX_9}, arch_sh_dsp_up},
-/* n*m*1*10** movx.w <DSP_REG_M>,@<REG_N>+ */ {"movx.w",{DSP_REG_M,A_INC_N},{PPI,MOVX,HEX_A}, arch_sh_dsp_up},
-/* n*m*1*11** movx.w <DSP_REG_M>,@<REG_N>+r8 */ {"movx.w",{DSP_REG_M,A_PMOD_N},{PPI,MOVX,HEX_B}, arch_sh_dsp_up},
-/* *n*m*0**01 movy.w @<REG_N>,<DSP_REG_Y> */ {"movy.w",{A_IND_N,DSP_REG_Y},{PPI,MOVY,HEX_1}, arch_sh_dsp_up},
-/* *n*m*0**10 movy.w @<REG_N>+,<DSP_REG_Y> */ {"movy.w",{A_INC_N,DSP_REG_Y},{PPI,MOVY,HEX_2}, arch_sh_dsp_up},
-/* *n*m*0**11 movy.w @<REG_N>+r9,<DSP_REG_Y> */ {"movy.w",{A_PMODY_N,DSP_REG_Y},{PPI,MOVY,HEX_3}, arch_sh_dsp_up},
-/* *n*m*1**01 movy.w <DSP_REG_M>,@<REG_N> */ {"movy.w",{DSP_REG_M,A_IND_N},{PPI,MOVY,HEX_9}, arch_sh_dsp_up},
-/* *n*m*1**10 movy.w <DSP_REG_M>,@<REG_N>+ */ {"movy.w",{DSP_REG_M,A_INC_N},{PPI,MOVY,HEX_A}, arch_sh_dsp_up},
-/* *n*m*1**11 movy.w <DSP_REG_M>,@<REG_N>+r9 */ {"movy.w",{DSP_REG_M,A_PMODY_N},{PPI,MOVY,HEX_B}, arch_sh_dsp_up},
+/* n*m*0*01** movx.w @<REG_N>,<DSP_REG_X> */ {"movx.w",{AX_IND_N,DSP_REG_X},{PPI,MOVX,HEX_1}, arch_sh_dsp_up},
+/* n*m*0*10** movx.w @<REG_N>+,<DSP_REG_X> */ {"movx.w",{AX_INC_N,DSP_REG_X},{PPI,MOVX,HEX_2}, arch_sh_dsp_up},
+/* n*m*0*11** movx.w @<REG_N>+r8,<DSP_REG_X> */ {"movx.w",{AX_PMOD_N,DSP_REG_X},{PPI,MOVX,HEX_3}, arch_sh_dsp_up},
+/* n*m*1*01** movx.w <DSP_REG_M>,@<REG_N> */ {"movx.w",{DSP_REG_A_M,AX_IND_N},{PPI,MOVX,HEX_9}, arch_sh_dsp_up},
+/* n*m*1*10** movx.w <DSP_REG_M>,@<REG_N>+ */ {"movx.w",{DSP_REG_A_M,AX_INC_N},{PPI,MOVX,HEX_A}, arch_sh_dsp_up},
+/* n*m*1*11** movx.w <DSP_REG_M>,@<REG_N>+r8 */ {"movx.w",{DSP_REG_A_M,AX_PMOD_N},{PPI,MOVX,HEX_B}, arch_sh_dsp_up},
+
+/* nnmm000100 movx.w @<REG_Axy>,<DSP_REG_XY> */ {"movx.w",{AXY_IND_N,DSP_REG_XY},{PPI,MOVX_NOPY,HEX_0,HEX_4}, arch_sh4al_dsp_up},
+/* nnmm001000 movx.w @<REG_Axy>+,<DSP_REG_XY> */{"movx.w",{AXY_INC_N,DSP_REG_XY},{PPI,MOVX_NOPY,HEX_0,HEX_8}, arch_sh4al_dsp_up},
+/* nnmm001100 movx.w @<REG_Axy>+r8,<DSP_REG_XY> */{"movx.w",{AXY_PMOD_N,DSP_REG_XY},{PPI,MOVX_NOPY,HEX_0,HEX_C}, arch_sh4al_dsp_up},
+/* nnmm100100 movx.w <DSP_REG_AX>,@<REG_Axy> */ {"movx.w",{DSP_REG_AX,AXY_IND_N},{PPI,MOVX_NOPY,HEX_2,HEX_4}, arch_sh4al_dsp_up},
+/* nnmm101000 movx.w <DSP_REG_AX>,@<REG_Axy>+ */{"movx.w",{DSP_REG_AX,AXY_INC_N},{PPI,MOVX_NOPY,HEX_2,HEX_8}, arch_sh4al_dsp_up},
+/* nnmm101100 movx.w <DSP_REG_AX>,@<REG_Axy>+r8 */{"movx.w",{DSP_REG_AX,AXY_PMOD_N},{PPI,MOVX_NOPY,HEX_2,HEX_C}, arch_sh4al_dsp_up},
+
+/* nnmm010100 movx.l @<REG_Axy>,<DSP_REG_XY> */ {"movx.l",{AXY_IND_N,DSP_REG_XY},{PPI,MOVX_NOPY,HEX_1,HEX_4}, arch_sh4al_dsp_up},
+/* nnmm011000 movx.l @<REG_Axy>+,<DSP_REG_XY> */{"movx.l",{AXY_INC_N,DSP_REG_XY},{PPI,MOVX_NOPY,HEX_1,HEX_8}, arch_sh4al_dsp_up},
+/* nnmm011100 movx.l @<REG_Axy>+r8,<DSP_REG_XY> */{"movx.l",{AXY_PMOD_N,DSP_REG_XY},{PPI,MOVX_NOPY,HEX_1,HEX_C}, arch_sh4al_dsp_up},
+/* nnmm110100 movx.l <DSP_REG_AX>,@<REG_Axy> */ {"movx.l",{DSP_REG_AX,AXY_IND_N},{PPI,MOVX_NOPY,HEX_3,HEX_4}, arch_sh4al_dsp_up},
+/* nnmm111000 movx.l <DSP_REG_AX>,@<REG_Axy>+ */{"movx.l",{DSP_REG_AX,AXY_INC_N},{PPI,MOVX_NOPY,HEX_3,HEX_8}, arch_sh4al_dsp_up},
+/* nnmm111100 movx.l <DSP_REG_AX>,@<REG_Axy>+r8 */{"movx.l",{DSP_REG_AX,AXY_PMOD_N},{PPI,MOVX_NOPY,HEX_3,HEX_C}, arch_sh4al_dsp_up},
+
+/* *n*m*0**01 movy.w @<REG_N>,<DSP_REG_Y> */ {"movy.w",{AY_IND_N,DSP_REG_Y},{PPI,MOVY,HEX_1}, arch_sh_dsp_up},
+/* *n*m*0**10 movy.w @<REG_N>+,<DSP_REG_Y> */ {"movy.w",{AY_INC_N,DSP_REG_Y},{PPI,MOVY,HEX_2}, arch_sh_dsp_up},
+/* *n*m*0**11 movy.w @<REG_N>+r9,<DSP_REG_Y> */ {"movy.w",{AY_PMOD_N,DSP_REG_Y},{PPI,MOVY,HEX_3}, arch_sh_dsp_up},
+/* *n*m*1**01 movy.w <DSP_REG_M>,@<REG_N> */ {"movy.w",{DSP_REG_A_M,AY_IND_N},{PPI,MOVY,HEX_9}, arch_sh_dsp_up},
+/* *n*m*1**10 movy.w <DSP_REG_M>,@<REG_N>+ */ {"movy.w",{DSP_REG_A_M,AY_INC_N},{PPI,MOVY,HEX_A}, arch_sh_dsp_up},
+/* *n*m*1**11 movy.w <DSP_REG_M>,@<REG_N>+r9 */ {"movy.w",{DSP_REG_A_M,AY_PMOD_N},{PPI,MOVY,HEX_B}, arch_sh_dsp_up},
+
+/* nnmm000001 movy.w @<REG_Ayx>,<DSP_REG_YX> */ {"movy.w",{AYX_IND_N,DSP_REG_YX},{PPI,MOVY_NOPX,HEX_0,HEX_1}, arch_sh4al_dsp_up},
+/* nnmm000010 movy.w @<REG_Ayx>+,<DSP_REG_YX> */{"movy.w",{AYX_INC_N,DSP_REG_YX},{PPI,MOVY_NOPX,HEX_0,HEX_2}, arch_sh4al_dsp_up},
+/* nnmm000011 movy.w @<REG_Ayx>+r8,<DSP_REG_YX> */{"movy.w",{AYX_PMOD_N,DSP_REG_YX},{PPI,MOVY_NOPX,HEX_0,HEX_3}, arch_sh4al_dsp_up},
+/* nnmm010001 movy.w <DSP_REG_AY>,@<REG_Ayx> */ {"movy.w",{DSP_REG_AY,AYX_IND_N},{PPI,MOVY_NOPX,HEX_1,HEX_1}, arch_sh4al_dsp_up},
+/* nnmm010010 movy.w <DSP_REG_AY>,@<REG_Ayx>+ */{"movy.w",{DSP_REG_AY,AYX_INC_N},{PPI,MOVY_NOPX,HEX_1,HEX_2}, arch_sh4al_dsp_up},
+/* nnmm010011 movy.w <DSP_REG_AY>,@<REG_Ayx>+r8 */{"movy.w",{DSP_REG_AY,AYX_PMOD_N},{PPI,MOVY_NOPX,HEX_1,HEX_3}, arch_sh4al_dsp_up},
+
+/* nnmm100001 movy.l @<REG_Ayx>,<DSP_REG_YX> */ {"movy.l",{AYX_IND_N,DSP_REG_YX},{PPI,MOVY_NOPX,HEX_2,HEX_1}, arch_sh4al_dsp_up},
+/* nnmm100010 movy.l @<REG_Ayx>+,<DSP_REG_YX> */{"movy.l",{AYX_INC_N,DSP_REG_YX},{PPI,MOVY_NOPX,HEX_2,HEX_2}, arch_sh4al_dsp_up},
+/* nnmm100011 movy.l @<REG_Ayx>+r8,<DSP_REG_YX> */{"movy.l",{AYX_PMOD_N,DSP_REG_YX},{PPI,MOVY_NOPX,HEX_2,HEX_3}, arch_sh4al_dsp_up},
+/* nnmm110001 movy.l <DSP_REG_AY>,@<REG_Ayx> */ {"movy.l",{DSP_REG_AY,AYX_IND_N},{PPI,MOVY_NOPX,HEX_3,HEX_1}, arch_sh4al_dsp_up},
+/* nnmm110010 movy.l <DSP_REG_AY>,@<REG_Ayx>+ */{"movy.l",{DSP_REG_AY,AYX_INC_N},{PPI,MOVY_NOPX,HEX_3,HEX_2}, arch_sh4al_dsp_up},
+/* nnmm110011 movy.l <DSP_REG_AY>,@<REG_Ayx>+r8 */{"movy.l",{DSP_REG_AY,AYX_PMOD_N},{PPI,MOVY_NOPX,HEX_3,HEX_3}, arch_sh4al_dsp_up},
/* 01aaeeffxxyyggnn pmuls Se,Sf,Dg */ {"pmuls",{DSP_REG_E,DSP_REG_F,DSP_REG_G},{PPI,PMUL}, arch_sh_dsp_up},
/* 10100000xxyynnnn psubc <DSP_REG_X>,<DSP_REG_Y>,<DSP_REG_N> */
@@ -678,13 +771,21 @@ sh_opcode_info sh_table[] = {
/* 10110100xxyynnnn pwad <DSP_REG_X>,<DSP_REG_Y>,<DSP_REG_N> */
{"pwad", {DSP_REG_X,DSP_REG_Y,DSP_REG_N},{PPI,PPI3,HEX_B,HEX_4}, arch_sh_dsp_up},
/* 10001000xxyynnnn pabs <DSP_REG_X>,<DSP_REG_N> */
-{"pabs", {DSP_REG_X,DSP_REG_N},{PPI,PPI3,HEX_8,HEX_8}, arch_sh_dsp_up},
+{"pabs", {DSP_REG_X,DSP_REG_N},{PPI,PPI3NC,HEX_8,HEX_8}, arch_sh_dsp_up},
+/* 1000100!xx01nnnn pabs <DSP_REG_X>,<DSP_REG_N> */
+{"pabs", {DSP_REG_X,DSP_REG_N},{PPI,PPIC,HEX_8,HEX_9,HEX_1}, arch_sh4al_dsp_up},
/* 10101000xxyynnnn pabs <DSP_REG_Y>,<DSP_REG_N> */
-{"pabs", {DSP_REG_Y,DSP_REG_N},{PPI,PPI3,HEX_A,HEX_8}, arch_sh_dsp_up},
+{"pabs", {DSP_REG_Y,DSP_REG_N},{PPI,PPI3NC,HEX_A,HEX_8}, arch_sh_dsp_up},
+/* 1010100!01yynnnn pabs <DSP_REG_Y>,<DSP_REG_N> */
+{"pabs", {DSP_REG_Y,DSP_REG_N},{PPI,PPIC,HEX_A,HEX_9,HEX_4}, arch_sh4al_dsp_up},
/* 10011000xxyynnnn prnd <DSP_REG_X>,<DSP_REG_N> */
-{"prnd", {DSP_REG_X,DSP_REG_N},{PPI,PPI3,HEX_9,HEX_8}, arch_sh_dsp_up},
+{"prnd", {DSP_REG_X,DSP_REG_N},{PPI,PPI3NC,HEX_9,HEX_8}, arch_sh_dsp_up},
+/* 1001100!xx01nnnn prnd <DSP_REG_X>,<DSP_REG_N> */
+{"prnd", {DSP_REG_X,DSP_REG_N},{PPI,PPIC,HEX_9,HEX_9,HEX_1}, arch_sh4al_dsp_up},
/* 10111000xxyynnnn prnd <DSP_REG_Y>,<DSP_REG_N> */
-{"prnd", {DSP_REG_Y,DSP_REG_N},{PPI,PPI3,HEX_B,HEX_8}, arch_sh_dsp_up},
+{"prnd", {DSP_REG_Y,DSP_REG_N},{PPI,PPI3NC,HEX_B,HEX_8}, arch_sh_dsp_up},
+/* 1011100!01yynnnn prnd <DSP_REG_Y>,<DSP_REG_N> */
+{"prnd", {DSP_REG_Y,DSP_REG_N},{PPI,PPIC,HEX_B,HEX_9,HEX_4}, arch_sh4al_dsp_up},
{"dct",{0},{PPI,PDC,HEX_1}, arch_sh_dsp_up},
{"dcf",{0},{PPI,PDC,HEX_2}, arch_sh_dsp_up},
@@ -697,6 +798,8 @@ sh_opcode_info sh_table[] = {
/* 00010iiiiiiinnnn psha #<imm>,<DSP_REG_N> */ {"psha",{A_IMM,DSP_REG_N},{PPI,PSH,HEX_1}, arch_sh_dsp_up},
/* 10100001xxyynnnn psub <DSP_REG_X>,<DSP_REG_Y>,<DSP_REG_N> */
{"psub", {DSP_REG_X,DSP_REG_Y,DSP_REG_N},{PPI,PPIC,HEX_A,HEX_1}, arch_sh_dsp_up},
+/* 10000101xxyynnnn psub <DSP_REG_Y>,<DSP_REG_X>,<DSP_REG_N> */
+{"psub", {DSP_REG_Y,DSP_REG_X,DSP_REG_N},{PPI,PPIC,HEX_8,HEX_5}, arch_sh4al_dsp_up},
/* 10110001xxyynnnn padd <DSP_REG_X>,<DSP_REG_Y>,<DSP_REG_N> */
{"padd", {DSP_REG_X,DSP_REG_Y,DSP_REG_N},{PPI,PPIC,HEX_B,HEX_1}, arch_sh_dsp_up},
/* 10010101xxyynnnn pand <DSP_REG_X>,<DSP_REG_Y>,<DSP_REG_N> */
@@ -709,16 +812,16 @@ sh_opcode_info sh_table[] = {
{"pdec", {DSP_REG_X,DSP_REG_N},{PPI,PPIC,HEX_8,HEX_9}, arch_sh_dsp_up},
/* 10101001xxyynnnn pdec <DSP_REG_Y>,<DSP_REG_N> */
{"pdec", {DSP_REG_Y,DSP_REG_N},{PPI,PPIC,HEX_A,HEX_9}, arch_sh_dsp_up},
-/* 10011001xxyynnnn pinc <DSP_REG_X>,<DSP_REG_N> */
-{"pinc", {DSP_REG_X,DSP_REG_N},{PPI,PPIC,HEX_9,HEX_9}, arch_sh_dsp_up},
-/* 10111001xxyynnnn pinc <DSP_REG_Y>,<DSP_REG_N> */
-{"pinc", {DSP_REG_Y,DSP_REG_N},{PPI,PPIC,HEX_B,HEX_9}, arch_sh_dsp_up},
+/* 10011001xx00nnnn pinc <DSP_REG_X>,<DSP_REG_N> */
+{"pinc", {DSP_REG_X,DSP_REG_N},{PPI,PPIC,HEX_9,HEX_9,HEX_XX00}, arch_sh_dsp_up},
+/* 1011100100yynnnn pinc <DSP_REG_Y>,<DSP_REG_N> */
+{"pinc", {DSP_REG_Y,DSP_REG_N},{PPI,PPIC,HEX_B,HEX_9,HEX_00YY}, arch_sh_dsp_up},
/* 10001101xxyynnnn pclr <DSP_REG_N> */
{"pclr", {DSP_REG_N},{PPI,PPIC,HEX_8,HEX_D}, arch_sh_dsp_up},
-/* 10011101xxyynnnn pdmsb <DSP_REG_X>,<DSP_REG_N> */
-{"pdmsb", {DSP_REG_X,DSP_REG_N},{PPI,PPIC,HEX_9,HEX_D}, arch_sh_dsp_up},
-/* 10111101xxyynnnn pdmsb <DSP_REG_Y>,<DSP_REG_N> */
-{"pdmsb", {DSP_REG_Y,DSP_REG_N},{PPI,PPIC,HEX_B,HEX_D}, arch_sh_dsp_up},
+/* 10011101xx00nnnn pdmsb <DSP_REG_X>,<DSP_REG_N> */
+{"pdmsb", {DSP_REG_X,DSP_REG_N},{PPI,PPIC,HEX_9,HEX_D,HEX_XX00}, arch_sh_dsp_up},
+/* 1011110100yynnnn pdmsb <DSP_REG_Y>,<DSP_REG_N> */
+{"pdmsb", {DSP_REG_Y,DSP_REG_N},{PPI,PPIC,HEX_B,HEX_D,HEX_00YY}, arch_sh_dsp_up},
/* 11001001xxyynnnn pneg <DSP_REG_X>,<DSP_REG_N> */
{"pneg", {DSP_REG_X,DSP_REG_N},{PPI,PPIC,HEX_C,HEX_9}, arch_sh_dsp_up},
/* 11101001xxyynnnn pneg <DSP_REG_Y>,<DSP_REG_N> */
@@ -735,106 +838,116 @@ sh_opcode_info sh_table[] = {
{"plds", {DSP_REG_N,A_MACH},{PPI,PPIC,HEX_E,HEX_D}, arch_sh_dsp_up},
/* 11111101xxyynnnn plds <DSP_REG_N>,MACL */
{"plds", {DSP_REG_N,A_MACL},{PPI,PPIC,HEX_F,HEX_D}, arch_sh_dsp_up},
+/* 10011101xx01zzzz pswap <DSP_REG_X>,<DSP_REG_N> */
+{"pswap", {DSP_REG_X,DSP_REG_N},{PPI,PPIC,HEX_9,HEX_D,HEX_1}, arch_sh4al_dsp_up},
+/* 1011110101yyzzzz pswap <DSP_REG_Y>,<DSP_REG_N> */
+{"pswap", {DSP_REG_Y,DSP_REG_N},{PPI,PPIC,HEX_B,HEX_D,HEX_4}, arch_sh4al_dsp_up},
-/* 1111nnnn01011101 fabs <F_REG_N> */{"fabs",{F_REG_N},{HEX_F,REG_N,HEX_5,HEX_D}, arch_sh3e_up},
-/* 1111nnnn01011101 fabs <D_REG_N> */{"fabs",{D_REG_N},{HEX_F,REG_N,HEX_5,HEX_D}, arch_sh4_up},
+/* 1111nnnn01011101 fabs <F_REG_N> */{"fabs",{F_REG_N},{HEX_F,REG_N,HEX_5,HEX_D}, arch_sh2e_up},
+/* 1111nnn001011101 fabs <D_REG_N> */{"fabs",{D_REG_N},{HEX_F,REG_N,HEX_5,HEX_D}, arch_sh4_up},
-/* 1111nnnnmmmm0000 fadd <F_REG_M>,<F_REG_N>*/{"fadd",{F_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_0}, arch_sh3e_up},
+/* 1111nnnnmmmm0000 fadd <F_REG_M>,<F_REG_N>*/{"fadd",{F_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_0}, arch_sh2e_up},
/* 1111nnn0mmm00000 fadd <D_REG_M>,<D_REG_N>*/{"fadd",{D_REG_M,D_REG_N},{HEX_F,REG_N,REG_M,HEX_0}, arch_sh4_up},
-/* 1111nnnnmmmm0100 fcmp/eq <F_REG_M>,<F_REG_N>*/{"fcmp/eq",{F_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_4}, arch_sh3e_up},
+/* 1111nnnnmmmm0100 fcmp/eq <F_REG_M>,<F_REG_N>*/{"fcmp/eq",{F_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_4}, arch_sh2e_up},
/* 1111nnn0mmm00100 fcmp/eq <D_REG_M>,<D_REG_N>*/{"fcmp/eq",{D_REG_M,D_REG_N},{HEX_F,REG_N,REG_M,HEX_4}, arch_sh4_up},
-/* 1111nnnnmmmm0101 fcmp/gt <F_REG_M>,<F_REG_N>*/{"fcmp/gt",{F_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_5}, arch_sh3e_up},
+/* 1111nnnnmmmm0101 fcmp/gt <F_REG_M>,<F_REG_N>*/{"fcmp/gt",{F_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_5}, arch_sh2e_up},
/* 1111nnn0mmm00101 fcmp/gt <D_REG_M>,<D_REG_N>*/{"fcmp/gt",{D_REG_M,D_REG_N},{HEX_F,REG_N,REG_M,HEX_5}, arch_sh4_up},
-/* 1111nnn010111101 fcnvds <D_REG_N>,FPUL*/{"fcnvds",{D_REG_N,FPUL_M},{HEX_F,REG_N,HEX_B,HEX_D}, arch_sh4_up},
+/* 1111nnn010111101 fcnvds <D_REG_N>,FPUL*/{"fcnvds",{D_REG_N,FPUL_M},{HEX_F,REG_N_D,HEX_B,HEX_D}, arch_sh4_up},
-/* 1111nnn010101101 fcnvsd FPUL,<D_REG_N>*/{"fcnvsd",{FPUL_M,D_REG_N},{HEX_F,REG_N,HEX_A,HEX_D}, arch_sh4_up},
+/* 1111nnn010101101 fcnvsd FPUL,<D_REG_N>*/{"fcnvsd",{FPUL_M,D_REG_N},{HEX_F,REG_N_D,HEX_A,HEX_D}, arch_sh4_up},
-/* 1111nnnnmmmm0011 fdiv <F_REG_M>,<F_REG_N>*/{"fdiv",{F_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_3}, arch_sh3e_up},
+/* 1111nnnnmmmm0011 fdiv <F_REG_M>,<F_REG_N>*/{"fdiv",{F_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_3}, arch_sh2e_up},
/* 1111nnn0mmm00011 fdiv <D_REG_M>,<D_REG_N>*/{"fdiv",{D_REG_M,D_REG_N},{HEX_F,REG_N,REG_M,HEX_3}, arch_sh4_up},
/* 1111nnmm11101101 fipr <V_REG_M>,<V_REG_N>*/{"fipr",{V_REG_M,V_REG_N},{HEX_F,REG_NM,HEX_E,HEX_D}, arch_sh4_up},
-/* 1111nnnn10001101 fldi0 <F_REG_N> */{"fldi0",{F_REG_N},{HEX_F,REG_N,HEX_8,HEX_D}, arch_sh3e_up},
+/* 1111nnnn10001101 fldi0 <F_REG_N> */{"fldi0",{F_REG_N},{HEX_F,REG_N,HEX_8,HEX_D}, arch_sh2e_up},
-/* 1111nnnn10011101 fldi1 <F_REG_N> */{"fldi1",{F_REG_N},{HEX_F,REG_N,HEX_9,HEX_D}, arch_sh3e_up},
+/* 1111nnnn10011101 fldi1 <F_REG_N> */{"fldi1",{F_REG_N},{HEX_F,REG_N,HEX_9,HEX_D}, arch_sh2e_up},
-/* 1111nnnn00011101 flds <F_REG_N>,FPUL*/{"flds",{F_REG_N,FPUL_M},{HEX_F,REG_N,HEX_1,HEX_D}, arch_sh3e_up},
+/* 1111nnnn00011101 flds <F_REG_N>,FPUL*/{"flds",{F_REG_N,FPUL_M},{HEX_F,REG_N,HEX_1,HEX_D}, arch_sh2e_up},
-/* 1111nnnn00101101 float FPUL,<F_REG_N>*/{"float",{FPUL_M,F_REG_N},{HEX_F,REG_N,HEX_2,HEX_D}, arch_sh3e_up},
-/* 1111nnnn00101101 float FPUL,<D_REG_N>*/{"float",{FPUL_M,D_REG_N},{HEX_F,REG_N,HEX_2,HEX_D}, arch_sh4_up},
+/* 1111nnnn00101101 float FPUL,<F_REG_N>*/{"float",{FPUL_M,F_REG_N},{HEX_F,REG_N,HEX_2,HEX_D}, arch_sh2e_up},
+/* 1111nnn000101101 float FPUL,<D_REG_N>*/{"float",{FPUL_M,D_REG_N},{HEX_F,REG_N,HEX_2,HEX_D}, arch_sh4_up},
-/* 1111nnnnmmmm1110 fmac FR0,<F_REG_M>,<F_REG_N>*/{"fmac",{F_FR0,F_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_E}, arch_sh3e_up},
+/* 1111nnnnmmmm1110 fmac FR0,<F_REG_M>,<F_REG_N>*/{"fmac",{F_FR0,F_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_E}, arch_sh2e_up},
-/* 1111nnnnmmmm1100 fmov <F_REG_M>,<F_REG_N>*/{"fmov",{F_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_C}, arch_sh3e_up},
-/* 1111nnnnmmmm1100 fmov <DX_REG_M>,<DX_REG_N>*/{"fmov",{DX_REG_M,DX_REG_N},{HEX_F,REG_N,REG_M,HEX_C}, arch_sh4_up},
+/* 1111nnnnmmmm1100 fmov <F_REG_M>,<F_REG_N>*/{"fmov",{F_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_C}, arch_sh2e_up},
+/* 1111nnn1mmmm1100 fmov <DX_REG_M>,<DX_REG_N>*/{"fmov",{DX_REG_M,DX_REG_N},{HEX_F,REG_N,REG_M,HEX_C}, arch_sh4_up},
-/* 1111nnnnmmmm1000 fmov @<REG_M>,<F_REG_N>*/{"fmov",{A_IND_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_8}, arch_sh3e_up},
-/* 1111nnnnmmmm1000 fmov @<REG_M>,<DX_REG_N>*/{"fmov",{A_IND_M,DX_REG_N},{HEX_F,REG_N,REG_M,HEX_8}, arch_sh4_up},
+/* 1111nnnnmmmm1000 fmov @<REG_M>,<F_REG_N>*/{"fmov",{A_IND_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_8}, arch_sh2e_up},
+/* 1111nnn1mmmm1000 fmov @<REG_M>,<DX_REG_N>*/{"fmov",{A_IND_M,DX_REG_N},{HEX_F,REG_N,REG_M,HEX_8}, arch_sh4_up},
-/* 1111nnnnmmmm1010 fmov <F_REG_M>,@<REG_N>*/{"fmov",{F_REG_M,A_IND_N},{HEX_F,REG_N,REG_M,HEX_A}, arch_sh3e_up},
-/* 1111nnnnmmmm1010 fmov <DX_REG_M>,@<REG_N>*/{"fmov",{DX_REG_M,A_IND_N},{HEX_F,REG_N,REG_M,HEX_A}, arch_sh4_up},
+/* 1111nnnnmmmm1010 fmov <F_REG_M>,@<REG_N>*/{"fmov",{F_REG_M,A_IND_N},{HEX_F,REG_N,REG_M,HEX_A}, arch_sh2e_up},
+/* 1111nnnnmmm11010 fmov <DX_REG_M>,@<REG_N>*/{"fmov",{DX_REG_M,A_IND_N},{HEX_F,REG_N,REG_M,HEX_A}, arch_sh4_up},
-/* 1111nnnnmmmm1001 fmov @<REG_M>+,<F_REG_N>*/{"fmov",{A_INC_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_9}, arch_sh3e_up},
-/* 1111nnnnmmmm1001 fmov @<REG_M>+,<DX_REG_N>*/{"fmov",{A_INC_M,DX_REG_N},{HEX_F,REG_N,REG_M,HEX_9}, arch_sh4_up},
+/* 1111nnnnmmmm1001 fmov @<REG_M>+,<F_REG_N>*/{"fmov",{A_INC_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_9}, arch_sh2e_up},
+/* 1111nnn1mmmm1001 fmov @<REG_M>+,<DX_REG_N>*/{"fmov",{A_INC_M,DX_REG_N},{HEX_F,REG_N,REG_M,HEX_9}, arch_sh4_up},
-/* 1111nnnnmmmm1011 fmov <F_REG_M>,@-<REG_N>*/{"fmov",{F_REG_M,A_DEC_N},{HEX_F,REG_N,REG_M,HEX_B}, arch_sh3e_up},
-/* 1111nnnnmmmm1011 fmov <DX_REG_M>,@-<REG_N>*/{"fmov",{DX_REG_M,A_DEC_N},{HEX_F,REG_N,REG_M,HEX_B}, arch_sh4_up},
+/* 1111nnnnmmmm1011 fmov <F_REG_M>,@-<REG_N>*/{"fmov",{F_REG_M,A_DEC_N},{HEX_F,REG_N,REG_M,HEX_B}, arch_sh2e_up},
+/* 1111nnnnmmm11011 fmov <DX_REG_M>,@-<REG_N>*/{"fmov",{DX_REG_M,A_DEC_N},{HEX_F,REG_N,REG_M,HEX_B}, arch_sh4_up},
-/* 1111nnnnmmmm0110 fmov @(R0,<REG_M>),<F_REG_N>*/{"fmov",{A_IND_R0_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_6}, arch_sh3e_up},
-/* 1111nnnnmmmm0110 fmov @(R0,<REG_M>),<DX_REG_N>*/{"fmov",{A_IND_R0_REG_M,DX_REG_N},{HEX_F,REG_N,REG_M,HEX_6}, arch_sh4_up},
+/* 1111nnnnmmmm0110 fmov @(R0,<REG_M>),<F_REG_N>*/{"fmov",{A_IND_R0_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_6}, arch_sh2e_up},
+/* 1111nnn1mmmm0110 fmov @(R0,<REG_M>),<DX_REG_N>*/{"fmov",{A_IND_R0_REG_M,DX_REG_N},{HEX_F,REG_N,REG_M,HEX_6}, arch_sh4_up},
-/* 1111nnnnmmmm0111 fmov <F_REG_M>,@(R0,<REG_N>)*/{"fmov",{F_REG_M,A_IND_R0_REG_N},{HEX_F,REG_N,REG_M,HEX_7}, arch_sh3e_up},
-/* 1111nnnnmmmm0111 fmov <DX_REG_M>,@(R0,<REG_N>)*/{"fmov",{DX_REG_M,A_IND_R0_REG_N},{HEX_F,REG_N,REG_M,HEX_7}, arch_sh4_up},
+/* 1111nnnnmmmm0111 fmov <F_REG_M>,@(R0,<REG_N>)*/{"fmov",{F_REG_M,A_IND_R0_REG_N},{HEX_F,REG_N,REG_M,HEX_7}, arch_sh2e_up},
+/* 1111nnnnmmm10111 fmov <DX_REG_M>,@(R0,<REG_N>)*/{"fmov",{DX_REG_M,A_IND_R0_REG_N},{HEX_F,REG_N,REG_M,HEX_7}, arch_sh4_up},
-/* 1111nnnnmmmm1000 fmov.d @<REG_M>,<DX_REG_N>*/{"fmov.d",{A_IND_M,DX_REG_N},{HEX_F,REG_N,REG_M,HEX_8}, arch_sh4_up},
+/* 1111nnn1mmmm1000 fmov.d @<REG_M>,<DX_REG_N>*/{"fmov.d",{A_IND_M,DX_REG_N},{HEX_F,REG_N,REG_M,HEX_8}, arch_sh4_up},
-/* 1111nnnnmmmm1010 fmov.d <DX_REG_M>,@<REG_N>*/{"fmov.d",{DX_REG_M,A_IND_N},{HEX_F,REG_N,REG_M,HEX_A}, arch_sh4_up},
+/* 1111nnnnmmm11010 fmov.d <DX_REG_M>,@<REG_N>*/{"fmov.d",{DX_REG_M,A_IND_N},{HEX_F,REG_N,REG_M,HEX_A}, arch_sh4_up},
-/* 1111nnnnmmmm1001 fmov.d @<REG_M>+,<DX_REG_N>*/{"fmov.d",{A_INC_M,DX_REG_N},{HEX_F,REG_N,REG_M,HEX_9}, arch_sh4_up},
+/* 1111nnn1mmmm1001 fmov.d @<REG_M>+,<DX_REG_N>*/{"fmov.d",{A_INC_M,DX_REG_N},{HEX_F,REG_N,REG_M,HEX_9}, arch_sh4_up},
-/* 1111nnnnmmmm1011 fmov.d <DX_REG_M>,@-<REG_N>*/{"fmov.d",{DX_REG_M,A_DEC_N},{HEX_F,REG_N,REG_M,HEX_B}, arch_sh4_up},
+/* 1111nnnnmmm11011 fmov.d <DX_REG_M>,@-<REG_N>*/{"fmov.d",{DX_REG_M,A_DEC_N},{HEX_F,REG_N,REG_M,HEX_B}, arch_sh4_up},
-/* 1111nnnnmmmm0110 fmov.d @(R0,<REG_M>),<DX_REG_N>*/{"fmov.d",{A_IND_R0_REG_M,DX_REG_N},{HEX_F,REG_N,REG_M,HEX_6}, arch_sh4_up},
+/* 1111nnn1mmmm0110 fmov.d @(R0,<REG_M>),<DX_REG_N>*/{"fmov.d",{A_IND_R0_REG_M,DX_REG_N},{HEX_F,REG_N,REG_M,HEX_6}, arch_sh4_up},
-/* 1111nnnnmmmm0111 fmov.d <DX_REG_M>,@(R0,<REG_N>)*/{"fmov.d",{DX_REG_M,A_IND_R0_REG_N},{HEX_F,REG_N,REG_M,HEX_7}, arch_sh4_up},
+/* 1111nnnnmmm10111 fmov.d <DX_REG_M>,@(R0,<REG_N>)*/{"fmov.d",{DX_REG_M,A_IND_R0_REG_N},{HEX_F,REG_N,REG_M,HEX_7}, arch_sh4_up},
-/* 1111nnnnmmmm1000 fmov.s @<REG_M>,<F_REG_N>*/{"fmov.s",{A_IND_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_8}, arch_sh3e_up},
+/* 1111nnnnmmmm1000 fmov.s @<REG_M>,<F_REG_N>*/{"fmov.s",{A_IND_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_8}, arch_sh2e_up},
-/* 1111nnnnmmmm1010 fmov.s <F_REG_M>,@<REG_N>*/{"fmov.s",{F_REG_M,A_IND_N},{HEX_F,REG_N,REG_M,HEX_A}, arch_sh3e_up},
+/* 1111nnnnmmmm1010 fmov.s <F_REG_M>,@<REG_N>*/{"fmov.s",{F_REG_M,A_IND_N},{HEX_F,REG_N,REG_M,HEX_A}, arch_sh2e_up},
-/* 1111nnnnmmmm1001 fmov.s @<REG_M>+,<F_REG_N>*/{"fmov.s",{A_INC_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_9}, arch_sh3e_up},
+/* 1111nnnnmmmm1001 fmov.s @<REG_M>+,<F_REG_N>*/{"fmov.s",{A_INC_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_9}, arch_sh2e_up},
-/* 1111nnnnmmmm1011 fmov.s <F_REG_M>,@-<REG_N>*/{"fmov.s",{F_REG_M,A_DEC_N},{HEX_F,REG_N,REG_M,HEX_B}, arch_sh3e_up},
+/* 1111nnnnmmmm1011 fmov.s <F_REG_M>,@-<REG_N>*/{"fmov.s",{F_REG_M,A_DEC_N},{HEX_F,REG_N,REG_M,HEX_B}, arch_sh2e_up},
-/* 1111nnnnmmmm0110 fmov.s @(R0,<REG_M>),<F_REG_N>*/{"fmov.s",{A_IND_R0_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_6}, arch_sh3e_up},
+/* 1111nnnnmmmm0110 fmov.s @(R0,<REG_M>),<F_REG_N>*/{"fmov.s",{A_IND_R0_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_6}, arch_sh2e_up},
-/* 1111nnnnmmmm0111 fmov.s <F_REG_M>,@(R0,<REG_N>)*/{"fmov.s",{F_REG_M,A_IND_R0_REG_N},{HEX_F,REG_N,REG_M,HEX_7}, arch_sh3e_up},
+/* 1111nnnnmmmm0111 fmov.s <F_REG_M>,@(R0,<REG_N>)*/{"fmov.s",{F_REG_M,A_IND_R0_REG_N},{HEX_F,REG_N,REG_M,HEX_7}, arch_sh2e_up},
-/* 1111nnnnmmmm0010 fmul <F_REG_M>,<F_REG_N>*/{"fmul",{F_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_2}, arch_sh3e_up},
+/* 1111nnnnmmmm0010 fmul <F_REG_M>,<F_REG_N>*/{"fmul",{F_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_2}, arch_sh2e_up},
/* 1111nnn0mmm00010 fmul <D_REG_M>,<D_REG_N>*/{"fmul",{D_REG_M,D_REG_N},{HEX_F,REG_N,REG_M,HEX_2}, arch_sh4_up},
-/* 1111nnnn01001101 fneg <F_REG_N> */{"fneg",{F_REG_N},{HEX_F,REG_N,HEX_4,HEX_D}, arch_sh3e_up},
-/* 1111nnnn01001101 fneg <D_REG_N> */{"fneg",{D_REG_N},{HEX_F,REG_N,HEX_4,HEX_D}, arch_sh4_up},
+/* 1111nnnn01001101 fneg <F_REG_N> */{"fneg",{F_REG_N},{HEX_F,REG_N,HEX_4,HEX_D}, arch_sh2e_up},
+/* 1111nnn001001101 fneg <D_REG_N> */{"fneg",{D_REG_N},{HEX_F,REG_N,HEX_4,HEX_D}, arch_sh4_up},
+
+/* 1111011111111101 fpchg */{"fpchg",{0},{HEX_F,HEX_7,HEX_F,HEX_D}, arch_sh4a_up},
/* 1111101111111101 frchg */{"frchg",{0},{HEX_F,HEX_B,HEX_F,HEX_D}, arch_sh4_up},
+/* 1111nnn011111101 fsca FPUL,<D_REG_N> */{"fsca",{FPUL_M,D_REG_N},{HEX_F,REG_N_D,HEX_F,HEX_D}, arch_sh4_up},
+
/* 1111001111111101 fschg */{"fschg",{0},{HEX_F,HEX_3,HEX_F,HEX_D}, arch_sh4_up},
/* 1111nnnn01101101 fsqrt <F_REG_N> */{"fsqrt",{F_REG_N},{HEX_F,REG_N,HEX_6,HEX_D}, arch_sh3e_up},
-/* 1111nnnn01101101 fsqrt <D_REG_N> */{"fsqrt",{D_REG_N},{HEX_F,REG_N,HEX_6,HEX_D}, arch_sh4_up},
+/* 1111nnn001101101 fsqrt <D_REG_N> */{"fsqrt",{D_REG_N},{HEX_F,REG_N,HEX_6,HEX_D}, arch_sh4_up},
+
+/* 1111nnnn01111101 fsrra <F_REG_N> */{"fsrra",{F_REG_N},{HEX_F,REG_N,HEX_7,HEX_D}, arch_sh4_up},
-/* 1111nnnn00001101 fsts FPUL,<F_REG_N>*/{"fsts",{FPUL_M,F_REG_N},{HEX_F,REG_N,HEX_0,HEX_D}, arch_sh3e_up},
+/* 1111nnnn00001101 fsts FPUL,<F_REG_N>*/{"fsts",{FPUL_M,F_REG_N},{HEX_F,REG_N,HEX_0,HEX_D}, arch_sh2e_up},
-/* 1111nnnnmmmm0001 fsub <F_REG_M>,<F_REG_N>*/{"fsub",{F_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_1}, arch_sh3e_up},
+/* 1111nnnnmmmm0001 fsub <F_REG_M>,<F_REG_N>*/{"fsub",{F_REG_M,F_REG_N},{HEX_F,REG_N,REG_M,HEX_1}, arch_sh2e_up},
/* 1111nnn0mmm00001 fsub <D_REG_M>,<D_REG_N>*/{"fsub",{D_REG_M,D_REG_N},{HEX_F,REG_N,REG_M,HEX_1}, arch_sh4_up},
-/* 1111nnnn00111101 ftrc <F_REG_N>,FPUL*/{"ftrc",{F_REG_N,FPUL_M},{HEX_F,REG_N,HEX_3,HEX_D}, arch_sh3e_up},
+/* 1111nnnn00111101 ftrc <F_REG_N>,FPUL*/{"ftrc",{F_REG_N,FPUL_M},{HEX_F,REG_N,HEX_3,HEX_D}, arch_sh2e_up},
/* 1111nnnn00111101 ftrc <D_REG_N>,FPUL*/{"ftrc",{D_REG_N,FPUL_M},{HEX_F,REG_N,HEX_3,HEX_D}, arch_sh4_up},
-/* 1111nn0111111101 ftrv XMTRX_M4,<V_REG_n>*/{"ftrv",{XMTRX_M4,V_REG_N},{HEX_F,REG_NM,HEX_F,HEX_D}, arch_sh4_up},
+/* 1111nn0111111101 ftrv XMTRX_M4,<V_REG_n>*/{"ftrv",{XMTRX_M4,V_REG_N},{HEX_F,REG_N_B01,HEX_F,HEX_D}, arch_sh4_up},
{ 0, {0}, {0}, 0 }
};
diff --git a/contrib/binutils/opcodes/sparc-dis.c b/contrib/binutils/opcodes/sparc-dis.c
index 47ebb31..6f360c6 100644
--- a/contrib/binutils/opcodes/sparc-dis.c
+++ b/contrib/binutils/opcodes/sparc-dis.c
@@ -1,20 +1,20 @@
/* Print SPARC instructions.
Copyright 1989, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000, 2002 Free Software Foundation, Inc.
+ 2000, 2002, 2003, 2004 Free Software Foundation, Inc.
-This program is free software; you can redistribute it and/or modify
-it under the terms of the GNU General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
-(at your option) any later version.
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
-This program is distributed in the hope that it will be useful,
-but WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-GNU General Public License for more details.
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
-You should have received a copy of the GNU General Public License
-along with this program; if not, write to the Free Software
-Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
+ You should have received a copy of the GNU General Public License
+ along with this program; if not, write to the Free Software
+ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
#include <stdio.h>
@@ -46,7 +46,8 @@ static const struct sparc_opcode **sorted_opcodes;
static int opcode_bits[4] = { 0x01c00000, 0x0, 0x01f80000, 0x01f80000 };
#define HASH_INSN(INSN) \
((((INSN) >> 24) & 0xc0) | (((INSN) & opcode_bits[((INSN) >> 30) & 3]) >> 19))
-struct opcode_hash {
+struct opcode_hash
+{
struct opcode_hash *next;
const struct sparc_opcode *opcode;
};
@@ -223,7 +224,7 @@ print_insn_sparc (memaddr, info)
static int opcodes_initialized = 0;
/* bfd mach number of last call. */
static unsigned long current_mach = 0;
- bfd_vma (*getword) PARAMS ((const unsigned char *));
+ bfd_vma (*getword) (const void *);
if (!opcodes_initialized
|| info->mach != current_mach)
@@ -257,7 +258,7 @@ print_insn_sparc (memaddr, info)
}
/* On SPARClite variants such as DANlite (sparc86x), instructions
- are always big-endian even when the machine is in little-endian mode. */
+ are always big-endian even when the machine is in little-endian mode. */
if (info->endian == BFD_ENDIAN_BIG || info->mach == bfd_mach_sparc_sparclite)
getword = bfd_getb32;
else
@@ -265,10 +266,10 @@ print_insn_sparc (memaddr, info)
insn = getword (buffer);
- info->insn_info_valid = 1; /* We do return this info */
- info->insn_type = dis_nonbranch; /* Assume non branch insn */
- info->branch_delay_insns = 0; /* Assume no delay */
- info->target = 0; /* Assume no target known */
+ info->insn_info_valid = 1; /* We do return this info. */
+ info->insn_type = dis_nonbranch; /* Assume non branch insn. */
+ info->branch_delay_insns = 0; /* Assume no delay. */
+ info->target = 0; /* Assume no target known. */
for (op = opcode_hash_table[HASH_INSN (insn)]; op; op = op->next)
{
@@ -316,32 +317,34 @@ print_insn_sparc (memaddr, info)
if (opcode->args[0] != ',')
(*info->fprintf_func) (stream, " ");
+
for (s = opcode->args; *s != '\0'; ++s)
{
while (*s == ',')
{
(*info->fprintf_func) (stream, ",");
++s;
- switch (*s) {
- case 'a':
- (*info->fprintf_func) (stream, "a");
- is_annulled = 1;
- ++s;
- continue;
- case 'N':
- (*info->fprintf_func) (stream, "pn");
- ++s;
- continue;
-
- case 'T':
- (*info->fprintf_func) (stream, "pt");
- ++s;
- continue;
-
- default:
- break;
- } /* switch on arg */
- } /* while there are comma started args */
+ switch (*s)
+ {
+ case 'a':
+ (*info->fprintf_func) (stream, "a");
+ is_annulled = 1;
+ ++s;
+ continue;
+ case 'N':
+ (*info->fprintf_func) (stream, "pn");
+ ++s;
+ continue;
+
+ case 'T':
+ (*info->fprintf_func) (stream, "pt");
+ ++s;
+ continue;
+
+ default:
+ break;
+ }
+ }
(*info->fprintf_func) (stream, " ");
@@ -682,26 +685,33 @@ print_insn_sparc (memaddr, info)
unsigned long prev_insn;
int errcode;
- errcode =
- (*info->read_memory_func)
+ if (memaddr >= 4)
+ errcode =
+ (*info->read_memory_func)
(memaddr - 4, buffer, sizeof (buffer), info);
+ else
+ errcode = 1;
+
prev_insn = getword (buffer);
if (errcode == 0)
{
/* If it is a delayed branch, we need to look at the
instruction before the delayed branch. This handles
- sequences such as
+ sequences such as:
sethi %o1, %hi(_foo), %o1
call _printf
- or %o1, %lo(_foo), %o1
- */
+ or %o1, %lo(_foo), %o1 */
if (is_delayed_branch (prev_insn))
{
- errcode = (*info->read_memory_func)
- (memaddr - 8, buffer, sizeof (buffer), info);
+ if (memaddr >= 8)
+ errcode = (*info->read_memory_func)
+ (memaddr - 8, buffer, sizeof (buffer), info);
+ else
+ errcode = 1;
+
prev_insn = getword (buffer);
}
}
@@ -746,7 +756,7 @@ print_insn_sparc (memaddr, info)
}
}
- info->insn_type = dis_noninsn; /* Mark as non-valid instruction */
+ info->insn_type = dis_noninsn; /* Mark as non-valid instruction. */
(*info->fprintf_func) (stream, _("unknown"));
return sizeof (buffer);
}
diff --git a/contrib/binutils/opcodes/sparc-opc.c b/contrib/binutils/opcodes/sparc-opc.c
index 0010232..22f18fa 100644
--- a/contrib/binutils/opcodes/sparc-opc.c
+++ b/contrib/binutils/opcodes/sparc-opc.c
@@ -1,6 +1,6 @@
/* Table of opcodes for the sparc.
Copyright 1989, 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
- 2000
+ 2000, 2002, 2004
Free Software Foundation, Inc.
This file is part of the BFD library.
@@ -1525,17 +1525,17 @@ CONDFC ("fbule", "cb013", 0xe, F_CONDBR),
{ "fstoi", F3F(2, 0x34, 0x0d1), F3F(~2, ~0x34, ~0x0d1)|RS1_G0, "f,g", F_FLOAT, v6 },
{ "fqtoi", F3F(2, 0x34, 0x0d3), F3F(~2, ~0x34, ~0x0d3)|RS1_G0, "R,g", F_FLOAT, v8 },
-{ "fdtox", F3F(2, 0x34, 0x082), F3F(~2, ~0x34, ~0x082)|RS1_G0, "B,g", F_FLOAT, v9 },
-{ "fstox", F3F(2, 0x34, 0x081), F3F(~2, ~0x34, ~0x081)|RS1_G0, "f,g", F_FLOAT, v9 },
-{ "fqtox", F3F(2, 0x34, 0x083), F3F(~2, ~0x34, ~0x083)|RS1_G0, "R,g", F_FLOAT, v9 },
+{ "fdtox", F3F(2, 0x34, 0x082), F3F(~2, ~0x34, ~0x082)|RS1_G0, "B,H", F_FLOAT, v9 },
+{ "fstox", F3F(2, 0x34, 0x081), F3F(~2, ~0x34, ~0x081)|RS1_G0, "f,H", F_FLOAT, v9 },
+{ "fqtox", F3F(2, 0x34, 0x083), F3F(~2, ~0x34, ~0x083)|RS1_G0, "R,H", F_FLOAT, v9 },
{ "fitod", F3F(2, 0x34, 0x0c8), F3F(~2, ~0x34, ~0x0c8)|RS1_G0, "f,H", F_FLOAT, v6 },
{ "fitos", F3F(2, 0x34, 0x0c4), F3F(~2, ~0x34, ~0x0c4)|RS1_G0, "f,g", F_FLOAT, v6 },
{ "fitoq", F3F(2, 0x34, 0x0cc), F3F(~2, ~0x34, ~0x0cc)|RS1_G0, "f,J", F_FLOAT, v8 },
-{ "fxtod", F3F(2, 0x34, 0x088), F3F(~2, ~0x34, ~0x088)|RS1_G0, "f,H", F_FLOAT, v9 },
-{ "fxtos", F3F(2, 0x34, 0x084), F3F(~2, ~0x34, ~0x084)|RS1_G0, "f,g", F_FLOAT, v9 },
-{ "fxtoq", F3F(2, 0x34, 0x08c), F3F(~2, ~0x34, ~0x08c)|RS1_G0, "f,J", F_FLOAT, v9 },
+{ "fxtod", F3F(2, 0x34, 0x088), F3F(~2, ~0x34, ~0x088)|RS1_G0, "B,H", F_FLOAT, v9 },
+{ "fxtos", F3F(2, 0x34, 0x084), F3F(~2, ~0x34, ~0x084)|RS1_G0, "B,g", F_FLOAT, v9 },
+{ "fxtoq", F3F(2, 0x34, 0x08c), F3F(~2, ~0x34, ~0x08c)|RS1_G0, "B,J", F_FLOAT, v9 },
{ "fdtoq", F3F(2, 0x34, 0x0ce), F3F(~2, ~0x34, ~0x0ce)|RS1_G0, "B,J", F_FLOAT, v8 },
{ "fdtos", F3F(2, 0x34, 0x0c6), F3F(~2, ~0x34, ~0x0c6)|RS1_G0, "B,g", F_FLOAT, v6 },
diff --git a/contrib/binutils/symlink-tree b/contrib/binutils/symlink-tree
index 5b18cab..22132c7 100755
--- a/contrib/binutils/symlink-tree
+++ b/contrib/binutils/symlink-tree
@@ -1,6 +1,31 @@
#!/bin/sh
# Create a symlink tree.
#
+# Copyright (C) 1995, 2000, 2003 Free Software Foundation, Inc.
+#
+# This file is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place - Suite 330,
+# Boston, MA 02111-1307, USA.
+#
+# As a special exception to the GNU General Public License, if you
+# distribute this file as part of a program that contains a
+# configuration script generated by Autoconf, you may include it under
+# the same distribution terms that you use for the rest of that program.
+#
+# Please report bugs to <gcc-bugs@gnu.org>
+# and send patches to <gcc-patches@gnu.org>.
+
# Syntax: symlink-tree srcdir "ignore1 ignore2 ..."
#
# where srcdir is the directory to create a symlink tree to,
OpenPOWER on IntegriCloud